From 8e15af04e2ddfc5358ca074e13e72693699a791f Mon Sep 17 00:00:00 2001 From: Jolie Rabideau Date: Wed, 20 Nov 2024 14:49:28 -0500 Subject: [PATCH 01/18] Add sidebar, add settings card, fix settings and start project settings --- .../src/hello-world/contributions/menus.json | 6 - lib/papi-dts/papi.d.ts | 3 +- lib/platform-bible-react/dist/index.cjs | 540 +- lib/platform-bible-react/dist/index.cjs.map | 2 +- lib/platform-bible-react/dist/index.d.ts | 26 +- lib/platform-bible-react/dist/index.js | 8966 ++++++++++------- lib/platform-bible-react/dist/index.js.map | 2 +- lib/platform-bible-react/package.json | 3 +- .../settings-card.component.tsx | 24 + ...tings-sidebar-content-search.component.tsx | 36 + .../settings-sidebar.component.tsx | 80 + ...b-navigation-content-search.component.tsx} | 6 +- .../src/components/hooks/use-mobile.tsx | 19 + .../src/components/shadcn-ui/sheet.tsx | 131 + .../src/components/shadcn-ui/sidebar.tsx | 747 ++ .../src/components/shadcn-ui/skeleton.tsx | 13 + .../src/components/shadcn-ui/tooltip.tsx | 28 + lib/platform-bible-react/src/index.ts | 9 +- .../pages/components/advanced.component.tsx | 4 +- .../pages/components/basics.component.tsx | 8 + .../basics/sidebar.examples.component.tsx | 70 + lib/platform-bible-react/tailwind.config.ts | 26 +- package-lock.json | 566 +- src/declarations/papi-shared-types.ts | 3 +- src/extension-host/data/menu.data.json | 9 +- .../platform-dock-layout-storage.util.ts | 12 +- ...roject-or-user-settings-list.component.tsx | 15 +- .../settings-components/setting.component.tsx | 8 +- .../settings-tabs/settings-tab.component.scss | 5 + .../settings-tabs/settings-tab.component.tsx | 243 +- .../services/web-view.service-host.ts | 29 +- 31 files changed, 7461 insertions(+), 4178 deletions(-) create mode 100644 lib/platform-bible-react/src/components/advanced/settings-components/settings-card.component.tsx create mode 100644 lib/platform-bible-react/src/components/advanced/settings-components/settings-sidebar-content-search.component.tsx create mode 100644 lib/platform-bible-react/src/components/advanced/settings-components/settings-sidebar.component.tsx rename lib/platform-bible-react/src/components/advanced/{navigation-content-search.component.tsx => tab-navigation-content-search.component.tsx} (92%) create mode 100644 lib/platform-bible-react/src/components/hooks/use-mobile.tsx create mode 100644 lib/platform-bible-react/src/components/shadcn-ui/sheet.tsx create mode 100644 lib/platform-bible-react/src/components/shadcn-ui/sidebar.tsx create mode 100644 lib/platform-bible-react/src/components/shadcn-ui/skeleton.tsx create mode 100644 lib/platform-bible-react/src/components/shadcn-ui/tooltip.tsx create mode 100644 lib/platform-bible-react/src/preview/pages/components/basics/sidebar.examples.component.tsx diff --git a/extensions/src/hello-world/contributions/menus.json b/extensions/src/hello-world/contributions/menus.json index a24114cef5..b72d3794a9 100644 --- a/extensions/src/hello-world/contributions/menus.json +++ b/extensions/src/hello-world/contributions/menus.json @@ -83,12 +83,6 @@ "group": "helloWorld.viewGroup", "order": 1, "command": "helloWorld.openViewerByWebViewId" - }, - { - "label": "%webView_openProjectSettings%", - "group": "helloWorld.projectGroup", - "order": 3, - "command": "platform.openProjectSettings" } ] } diff --git a/lib/papi-dts/papi.d.ts b/lib/papi-dts/papi.d.ts index ddd542881b..b48f6b1d84 100644 --- a/lib/papi-dts/papi.d.ts +++ b/lib/papi-dts/papi.d.ts @@ -2898,8 +2898,7 @@ declare module 'papi-shared-types' { 'platform.quit': () => Promise; /** Restart the application */ 'platform.restart': () => Promise; - 'platform.openProjectSettings': (webViewId: string) => Promise; - 'platform.openUserSettings': () => Promise; + 'platform.openSettings': (webViewId?: string) => Promise; 'test.addMany': (...nums: number[]) => number; 'test.throwErrorExtensionHost': (message: string) => void; } diff --git a/lib/platform-bible-react/dist/index.cjs b/lib/platform-bible-react/dist/index.cjs index 6da3874bc9..1b24c512de 100644 --- a/lib/platform-bible-react/dist/index.cjs +++ b/lib/platform-bible-react/dist/index.cjs @@ -1,23 +1,23 @@ -"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const a=require("react/jsx-runtime"),v=require("react"),te=require("lucide-react"),ot=require("clsx"),Wi=require("tailwind-merge"),Gs=require("@radix-ui/react-dropdown-menu"),W=require("platform-bible-utils"),Ki=require("@radix-ui/react-slot"),Qn=require("class-variance-authority"),Ji=require("@radix-ui/react-label"),Zi=require("@radix-ui/react-radio-group"),Qi=require("@radix-ui/react-popover"),je=require("cmdk"),el=require("@radix-ui/react-dialog"),Ne=require("@tanstack/react-table"),tl=require("@radix-ui/react-select"),nl=require("@radix-ui/react-checkbox"),rl=require("@radix-ui/react-toggle-group"),ol=require("@radix-ui/react-toggle"),sl=require("@radix-ui/react-tabs"),al=require("@radix-ui/react-separator"),Ar=require("@mui/styled-engine"),Ie=require("@mui/material"),sn=require("react-dom"),Us=require("sonner"),il=require("@radix-ui/react-slider"),ll=require("@radix-ui/react-switch"),cl=require("markdown-to-jsx");function ke(e){const t=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(e){for(const n in e)if(n!=="default"){const r=Object.getOwnPropertyDescriptor(e,n);Object.defineProperty(t,n,r.get?r:{enumerable:!0,get:()=>e[n]})}}return t.default=e,Object.freeze(t)}const M=ke(v),pe=ke(Gs),qs=ke(Ji),hn=ke(Zi),gn=ke(Qi),Xe=ke(el),ge=ke(tl),Br=ke(nl),er=ke(rl),Hs=ke(ol),Oe=ke(sl),Xs=ke(al),dl=ke(sn),an=ke(il),Vr=ke(ll);const ul=Wi.extendTailwindMerge({prefix:"tw-"});function S(...e){return ul(ot.clsx(e))}const qt=v.forwardRef(({className:e,type:t,...n},r)=>a.jsx("input",{type:t,className:S("pr-twp tw-flex tw-h-10 tw-rounded-md tw-border tw-border-input tw-bg-background tw-px-3 tw-py-2 tw-text-sm tw-ring-offset-background file:tw-border-0 file:tw-bg-transparent file:tw-text-sm file:tw-font-medium file:tw-text-foreground placeholder:tw-text-muted-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-cursor-not-allowed disabled:tw-opacity-50",e),ref:r,...n}));qt.displayName="Input";const pl=v.forwardRef(({handleSearch:e,handleKeyDown:t,handleOnClick:n,handleSubmit:r,...o},s)=>a.jsxs("div",{className:"tw-relative",children:[a.jsx(qt,{...o,type:"text",className:"tw-box-border tw-gap-2.5 tw-rounded-lg tw-border tw-border-solid tw-bg-background tw-py-2 tw-pl-4 tw-pr-3 tw-font-medium tw-shadow-none tw-outline-none",onChange:i=>e(i.target.value),onKeyDown:i=>{i.key==="Enter"&&r(),t(i)},onClick:n,ref:s}),a.jsx(te.History,{className:"tw-absolute tw-right-3 tw-top-1/2 tw-h-4 tw-w-4 tw--translate-y-1/2 tw-transform tw-cursor-pointer tw-text-muted-foreground",onClick:()=>{console.log("back in history")}})]}));var wl=Object.defineProperty,fl=(e,t,n)=>t in e?wl(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,ne=(e,t,n)=>fl(e,typeof t!="symbol"?t+"":t,n);const gt=["GEN","EXO","LEV","NUM","DEU","JOS","JDG","RUT","1SA","2SA","1KI","2KI","1CH","2CH","EZR","NEH","EST","JOB","PSA","PRO","ECC","SNG","ISA","JER","LAM","EZK","DAN","HOS","JOL","AMO","OBA","JON","MIC","NAM","HAB","ZEP","HAG","ZEC","MAL","MAT","MRK","LUK","JHN","ACT","ROM","1CO","2CO","GAL","EPH","PHP","COL","1TH","2TH","1TI","2TI","TIT","PHM","HEB","JAS","1PE","2PE","1JN","2JN","3JN","JUD","REV","TOB","JDT","ESG","WIS","SIR","BAR","LJE","S3Y","SUS","BEL","1MA","2MA","3MA","4MA","1ES","2ES","MAN","PS2","ODA","PSS","JSA","JDB","TBS","SST","DNT","BLT","XXA","XXB","XXC","XXD","XXE","XXF","XXG","FRT","BAK","OTH","3ES","EZA","5EZ","6EZ","INT","CNC","GLO","TDX","NDX","DAG","PS3","2BA","LBA","JUB","ENO","1MQ","2MQ","3MQ","REP","4BA","LAO"],Jr=["XXA","XXB","XXC","XXD","XXE","XXF","XXG","FRT","BAK","OTH","INT","CNC","GLO","TDX","NDX"],Ys=["Genesis","Exodus","Leviticus","Numbers","Deuteronomy","Joshua","Judges","Ruth","1 Samuel","2 Samuel","1 Kings","2 Kings","1 Chronicles","2 Chronicles","Ezra","Nehemiah","Esther (Hebrew)","Job","Psalms","Proverbs","Ecclesiastes","Song of Songs","Isaiah","Jeremiah","Lamentations","Ezekiel","Daniel (Hebrew)","Hosea","Joel","Amos","Obadiah","Jonah","Micah","Nahum","Habakkuk","Zephaniah","Haggai","Zechariah","Malachi","Matthew","Mark","Luke","John","Acts","Romans","1 Corinthians","2 Corinthians","Galatians","Ephesians","Philippians","Colossians","1 Thessalonians","2 Thessalonians","1 Timothy","2 Timothy","Titus","Philemon","Hebrews","James","1 Peter","2 Peter","1 John","2 John","3 John","Jude","Revelation","Tobit","Judith","Esther Greek","Wisdom of Solomon","Sirach (Ecclesiasticus)","Baruch","Letter of Jeremiah","Song of 3 Young Men","Susanna","Bel and the Dragon","1 Maccabees","2 Maccabees","3 Maccabees","4 Maccabees","1 Esdras (Greek)","2 Esdras (Latin)","Prayer of Manasseh","Psalm 151","Odes","Psalms of Solomon","Joshua A. *obsolete*","Judges B. *obsolete*","Tobit S. *obsolete*","Susanna Th. *obsolete*","Daniel Th. *obsolete*","Bel Th. *obsolete*","Extra A","Extra B","Extra C","Extra D","Extra E","Extra F","Extra G","Front Matter","Back Matter","Other Matter","3 Ezra *obsolete*","Apocalypse of Ezra","5 Ezra (Latin Prologue)","6 Ezra (Latin Epilogue)","Introduction","Concordance ","Glossary ","Topical Index","Names Index","Daniel Greek","Psalms 152-155","2 Baruch (Apocalypse)","Letter of Baruch","Jubilees","Enoch","1 Meqabyan","2 Meqabyan","3 Meqabyan","Reproof (Proverbs 25-31)","4 Baruch (Rest of Baruch)","Laodiceans"],Wo=El();function Ht(e,t=!0){return t&&(e=e.toUpperCase()),e in Wo?Wo[e]:0}function Zr(e){return Ht(e)>0}function ml(e){const t=typeof e=="string"?Ht(e):e;return t>=40&&t<=66}function hl(e){return(typeof e=="string"?Ht(e):e)<=39}function Ws(e){return e<=66}function gl(e){const t=typeof e=="string"?Ht(e):e;return Zs(t)&&!Ws(t)}function*bl(){for(let e=1;e<=gt.length;e++)yield e}const vl=1,Ks=gt.length;function yl(){return["XXA","XXB","XXC","XXD","XXE","XXF","XXG"]}function Qr(e,t="***"){const n=e-1;return n<0||n>=gt.length?t:gt[n]}function Js(e){return e<=0||e>Ks?"******":Ys[e-1]}function xl(e){return Js(Ht(e))}function Zs(e){const t=typeof e=="number"?Qr(e):e;return Zr(t)&&!Jr.includes(t)}function Nl(e){const t=typeof e=="number"?Qr(e):e;return Zr(t)&&Jr.includes(t)}function kl(e){return Ys[e-1].includes("*obsolete*")}function El(){const e={};for(let t=0;t(e[e.Unknown=0]="Unknown",e[e.Original=1]="Original",e[e.Septuagint=2]="Septuagint",e[e.Vulgate=3]="Vulgate",e[e.English=4]="English",e[e.RussianProtestant=5]="RussianProtestant",e[e.RussianOrthodox=6]="RussianOrthodox",e))(qe||{});const Pe=class{constructor(t){if(ne(this,"name"),ne(this,"fullPath"),ne(this,"isPresent"),ne(this,"hasVerseSegments"),ne(this,"isCustomized"),ne(this,"baseVersification"),ne(this,"scriptureBooks"),ne(this,"_type"),t==null)throw new Error("Argument undefined");typeof t=="string"?(this.name=t,this._type=qe[t]):(this._type=t,this.name=qe[t])}get type(){return this._type}equals(t){return!t.type||!this.type?!1:t.type===this.type}};ne(Pe,"Original",new Pe(qe.Original)),ne(Pe,"Septuagint",new Pe(qe.Septuagint)),ne(Pe,"Vulgate",new Pe(qe.Vulgate)),ne(Pe,"English",new Pe(qe.English)),ne(Pe,"RussianProtestant",new Pe(qe.RussianProtestant)),ne(Pe,"RussianOrthodox",new Pe(qe.RussianOrthodox));let ut=Pe;function Ko(e,t){const n=t[0];for(let r=1;r(e[e.Valid=0]="Valid",e[e.UnknownVersification=1]="UnknownVersification",e[e.OutOfRange=2]="OutOfRange",e[e.VerseOutOfOrder=3]="VerseOutOfOrder",e[e.VerseRepeated=4]="VerseRepeated",e))(Qs||{});const Se=class re{constructor(t,n,r,o){if(ne(this,"firstChapter"),ne(this,"lastChapter"),ne(this,"lastVerse"),ne(this,"hasSegmentsDefined"),ne(this,"text"),ne(this,"BBBCCCVVVS"),ne(this,"longHashCode"),ne(this,"versification"),ne(this,"rtlMark","‏"),ne(this,"_bookNum",0),ne(this,"_chapterNum",0),ne(this,"_verseNum",0),ne(this,"_verse"),r==null&&o==null)if(t!=null&&typeof t=="string"){const s=t,i=n!=null&&n instanceof ut?n:void 0;this.setEmpty(i),this.parse(s)}else if(t!=null&&typeof t=="number"){const s=n!=null&&n instanceof ut?n:void 0;this.setEmpty(s),this._verseNum=t%re.chapterDigitShifter,this._chapterNum=Math.floor(t%re.bookDigitShifter/re.chapterDigitShifter),this._bookNum=Math.floor(t/re.bookDigitShifter)}else if(n==null)if(t!=null&&t instanceof re){const s=t;this._bookNum=s.bookNum,this._chapterNum=s.chapterNum,this._verseNum=s.verseNum,this._verse=s.verse,this.versification=s.versification}else{if(t==null)return;const s=t instanceof ut?t:re.defaultVersification;this.setEmpty(s)}else throw new Error("VerseRef constructor not supported.");else if(t!=null&&n!=null&&r!=null)if(typeof t=="string"&&typeof n=="string"&&typeof r=="string")this.setEmpty(o),this.updateInternal(t,n,r);else if(typeof t=="number"&&typeof n=="number"&&typeof r=="number")this._bookNum=t,this._chapterNum=n,this._verseNum=r,this.versification=o??re.defaultVersification;else throw new Error("VerseRef constructor not supported.");else throw new Error("VerseRef constructor not supported.")}static isVerseParseable(t){return t.length>0&&"0123456789".includes(t[0])&&!t.endsWith(this.verseRangeSeparator)&&!t.endsWith(this.verseSequenceIndicator)}static tryParse(t){let n;try{return n=new re(t),{success:!0,verseRef:n}}catch(r){if(r instanceof en)return n=new re,{success:!1,verseRef:n};throw r}}static getBBBCCCVVV(t,n,r){return t%re.bcvMaxValue*re.bookDigitShifter+(n>=0?n%re.bcvMaxValue*re.chapterDigitShifter:0)+(r>=0?r%re.bcvMaxValue:0)}static fromJSON(t){const{book:n,chapterNum:r,verseNum:o,verse:s,versificationStr:i}=t,l=s||o.toString();let c;return i&&(c=new ut(i)),n?new re(n,r.toString(),l,c):new re}static tryGetVerseNum(t){let n;if(!t)return n=-1,{success:!0,vNum:n};n=0;let r;for(let o=0;o"9")return o===0&&(n=-1),{success:!1,vNum:n};if(n=n*10+ +r-0,n>re.bcvMaxValue)return n=-1,{success:!1,vNum:n}}return{success:!0,vNum:n}}get isDefault(){return this.bookNum===0&&this.chapterNum===0&&this.verseNum===0&&this.versification==null}get hasMultiple(){return this._verse!=null&&(this._verse.includes(re.verseRangeSeparator)||this._verse.includes(re.verseSequenceIndicator))}get book(){return se.bookNumberToId(this.bookNum,"")}set book(t){this.bookNum=se.bookIdToNumber(t)}get chapter(){return this.isDefault||this._chapterNum<0?"":this._chapterNum.toString()}set chapter(t){const n=+t;this._chapterNum=Number.isInteger(n)?n:-1}get verse(){return this._verse!=null?this._verse:this.isDefault||this._verseNum<0?"":this._verseNum.toString()}set verse(t){const{success:n,vNum:r}=re.tryGetVerseNum(t);this._verse=n?void 0:t.replace(this.rtlMark,""),this._verseNum=r,!(this._verseNum>=0)&&({vNum:this._verseNum}=re.tryGetVerseNum(this._verse))}get bookNum(){return this._bookNum}set bookNum(t){if(t<=0||t>se.lastBook)throw new en("BookNum must be greater than zero and less than or equal to last book");this._bookNum=t}get chapterNum(){return this._chapterNum}set chapterNum(t){this.chapterNum=t}get verseNum(){return this._verseNum}set verseNum(t){this._verseNum=t}get versificationStr(){var t;return(t=this.versification)==null?void 0:t.name}set versificationStr(t){this.versification=this.versification!=null?new ut(t):void 0}get valid(){return this.validStatus===0}get validStatus(){return this.validateVerse(re.verseRangeSeparators,re.verseSequenceIndicators)}get BBBCCC(){return re.getBBBCCCVVV(this._bookNum,this._chapterNum,0)}get BBBCCCVVV(){return re.getBBBCCCVVV(this._bookNum,this._chapterNum,this._verseNum)}get isExcluded(){return!1}parse(t){if(t=t.replace(this.rtlMark,""),t.includes("/")){const s=t.split("/");if(t=s[0],s.length>1)try{const i=+s[1].trim();this.versification=new ut(qe[i])}catch{throw new en("Invalid reference : "+t)}}const n=t.trim().split(" ");if(n.length!==2)throw new en("Invalid reference : "+t);const r=n[1].split(":"),o=+r[0];if(r.length!==2||se.bookIdToNumber(n[0])===0||!Number.isInteger(o)||o<0||!re.isVerseParseable(r[1]))throw new en("Invalid reference : "+t);this.updateInternal(n[0],r[0],r[1])}simplify(){this._verse=void 0}clone(){return new re(this)}toString(){const t=this.book;return t===""?"":`${t} ${this.chapter}:${this.verse}`}toJSON(){let t=this.verse;(t===""||t===this.verseNum.toString())&&(t=void 0);const n={book:this.book,chapterNum:this.chapterNum,verseNum:this.verseNum,verse:t,versificationStr:this.versificationStr};return t||delete n.verse,n}equals(t){return t instanceof re?t._bookNum===this._bookNum&&t._chapterNum===this._chapterNum&&t._verseNum===this._verseNum&&t.verse===this.verse&&(t.versification==null&&this.versification==null||t.versification!=null&&this.versification!=null&&t.versification.equals(this.versification)):!1}allVerses(t=!1,n=re.verseRangeSeparators,r=re.verseSequenceIndicators){if(this._verse==null||this.chapterNum<=0)return[this.clone()];const o=[],s=Ko(this._verse,r);for(const i of s.map(l=>Ko(l,n))){const l=this.clone();l.verse=i[0];const c=l.verseNum;if(o.push(l),i.length>1){const d=this.clone();if(d.verse=i[1],!t)for(let u=c+1;ui)return 3;if(r===i)return 4;r=i}return 0}get internalValid(){return this.versification==null?1:this._bookNum<=0||this._bookNum>se.lastBook?2:(se.isCanonical(this._bookNum),0)}setEmpty(t=re.defaultVersification){this._bookNum=0,this._chapterNum=-1,this._verse=void 0,this.versification=t}updateInternal(t,n,r){this.bookNum=se.bookIdToNumber(t),this.chapter=n,this.verse=r}};ne(Se,"defaultVersification",ut.English),ne(Se,"verseRangeSeparator","-"),ne(Se,"verseSequenceIndicator",","),ne(Se,"verseRangeSeparators",[Se.verseRangeSeparator]),ne(Se,"verseSequenceIndicators",[Se.verseSequenceIndicator]),ne(Se,"chapterDigitShifter",1e3),ne(Se,"bookDigitShifter",Se.chapterDigitShifter*Se.chapterDigitShifter),ne(Se,"bcvMaxValue",Se.chapterDigitShifter-1),ne(Se,"ValidStatusType",Qs);class en extends Error{}const tr=pe.Root,eo=pe.Trigger,ea=pe.Group,Sl=pe.Portal,Tl=pe.Sub,Cl=pe.RadioGroup,ta=v.forwardRef(({className:e,inset:t,children:n,...r},o)=>a.jsxs(pe.SubTrigger,{ref:o,className:S("tw-flex tw-cursor-default tw-select-none tw-items-center tw-rounded-sm tw-px-2 tw-py-1.5 tw-text-sm tw-outline-none focus:tw-bg-accent data-[state=open]:tw-bg-accent",t&&"tw-pl-8",e),...r,children:[n,a.jsx(te.ChevronRight,{className:"tw-ml-auto tw-h-4 tw-w-4"})]}));ta.displayName=pe.SubTrigger.displayName;const na=v.forwardRef(({className:e,...t},n)=>a.jsx(pe.SubContent,{ref:n,className:S("tw-z-50 tw-min-w-[8rem] tw-overflow-hidden tw-rounded-md tw-border tw-bg-popover tw-p-1 tw-text-popover-foreground tw-shadow-lg data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0 data-[state=closed]:tw-zoom-out-95 data-[state=open]:tw-zoom-in-95 data-[side=bottom]:tw-slide-in-from-top-2 data-[side=left]:tw-slide-in-from-right-2 data-[side=right]:tw-slide-in-from-left-2 data-[side=top]:tw-slide-in-from-bottom-2",e),...t}));na.displayName=pe.SubContent.displayName;const Nn=v.forwardRef(({className:e,sideOffset:t=4,...n},r)=>a.jsx(pe.Portal,{children:a.jsx(pe.Content,{ref:r,sideOffset:t,className:S("pr-twp tw-z-50 tw-min-w-[8rem] tw-overflow-hidden tw-rounded-md tw-border tw-bg-popover tw-p-1 tw-text-popover-foreground tw-shadow-md data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0 data-[state=closed]:tw-zoom-out-95 data-[state=open]:tw-zoom-in-95 data-[side=bottom]:tw-slide-in-from-top-2 data-[side=left]:tw-slide-in-from-right-2 data-[side=right]:tw-slide-in-from-left-2 data-[side=top]:tw-slide-in-from-bottom-2",e),...n})}));Nn.displayName=pe.Content.displayName;const to=v.forwardRef(({className:e,inset:t,...n},r)=>a.jsx(pe.Item,{ref:r,className:S("tw-cursor-default tw-select-none tw-items-center tw-rounded-sm tw-px-2 tw-py-1.5 tw-text-sm tw-outline-none tw-transition-colors focus:tw-bg-accent data-[disabled]:tw-pointer-events-none data-[disabled]:tw-opacity-50",t&&"tw-pl-8",e),...n}));to.displayName=pe.Item.displayName;const nr=v.forwardRef(({className:e,children:t,checked:n,...r},o)=>a.jsxs(pe.CheckboxItem,{ref:o,className:S("tw-relative tw-flex tw-cursor-default tw-select-none tw-items-center tw-rounded-sm tw-py-1.5 tw-pl-8 tw-pr-2 tw-text-sm tw-outline-none tw-transition-colors focus:tw-bg-accent focus:tw-text-accent-foreground data-[disabled]:tw-pointer-events-none data-[disabled]:tw-opacity-50",e),checked:n,...r,children:[a.jsx("span",{className:"tw-absolute tw-left-2 tw-flex tw-h-3.5 tw-w-3.5 tw-items-center tw-justify-center",children:a.jsx(pe.ItemIndicator,{children:a.jsx(te.Check,{className:"tw-h-4 tw-w-4"})})}),t]}));nr.displayName=pe.CheckboxItem.displayName;const no=v.forwardRef(({className:e,children:t,...n},r)=>a.jsxs(pe.RadioItem,{ref:r,className:S("tw-relative tw-flex tw-cursor-default tw-select-none tw-items-center tw-rounded-sm tw-py-1.5 tw-pl-8 tw-pr-2 tw-text-sm tw-outline-none tw-transition-colors focus:tw-bg-accent focus:tw-text-accent-foreground data-[disabled]:tw-pointer-events-none data-[disabled]:tw-opacity-50",e),...n,children:[a.jsx("span",{className:"tw-absolute tw-left-2 tw-flex tw-h-3.5 tw-w-3.5 tw-items-center tw-justify-center",children:a.jsx(pe.ItemIndicator,{children:a.jsx(te.Circle,{className:"tw-h-2 tw-w-2 tw-fill-current"})})}),t]}));no.displayName=pe.RadioItem.displayName;const Xt=v.forwardRef(({className:e,inset:t,...n},r)=>a.jsx(pe.Label,{ref:r,className:S("tw-px-2 tw-py-1.5 tw-text-sm tw-font-semibold",t&&"tw-pl-8",e),...n}));Xt.displayName=pe.Label.displayName;const kn=v.forwardRef(({className:e,...t},n)=>a.jsx(pe.Separator,{ref:n,className:S("tw--mx-1 tw-my-1 tw-h-px tw-bg-muted",e),...t}));kn.displayName=pe.Separator.displayName;function ra({className:e,...t}){return a.jsx("span",{className:S("tw-ml-auto tw-text-xs tw-tracking-widest tw-opacity-60",e),...t})}ra.displayName="DropdownMenuShortcut";const jl=v.forwardRef(({bookId:e,handleSelectBook:t,isSelected:n,handleHighlightBook:r,handleKeyDown:o,bookType:s,children:i},l)=>a.jsxs(to,{ref:l,textValue:e,className:S("tw-mx-1 tw-px-1 tw-font-normal tw-text-foreground/80",{"tw-bg-amber-50 tw-text-yellow-900 data-[highlighted]:tw-bg-amber-100":n}),onSelect:c=>{c.preventDefault(),t()},onKeyDown:c=>{o(c)},onFocus:r,onMouseMove:r,children:[a.jsx("span",{className:S("tw-border-b-0 tw-border-l-2 tw-border-r-0 tw-border-t-0 tw-border-solid tw-px-2",{"tw-font-bold":n,"tw-border-l-red-200":s.toLowerCase()==="ot","tw-border-l-purple-200":s.toLowerCase()==="nt","tw-border-l-indigo-200":s.toLowerCase()==="dc"}),children:se.bookIdToEnglishName(e)}),n&&a.jsx("div",{children:i})]},e));function Ol({handleSelectChapter:e,endChapter:t,activeChapter:n,highlightedChapter:r,handleHighlightedChapter:o}){const s=Array.from({length:t},(l,c)=>c+1),i=v.useCallback(l=>{o(l)},[o]);return a.jsx("div",{className:S("tw-flex tw-flex-wrap tw-items-start tw-justify-start tw-self-stretch"),children:s.map(l=>a.jsx("div",{className:S("tw-box-content tw-flex tw-h-4 tw-w-4 tw-cursor-pointer tw-items-center tw-justify-end tw-rounded-md tw-p-2 tw-text-amber-800",{"tw-font-semibold tw-text-amber-900":l===n,"tw-bg-amber-200":l===r}),onClick:c=>{c.preventDefault(),c.stopPropagation(),e(l)},role:"button",onKeyDown:c=>{c.key==="Enter"&&e(l)},tabIndex:0,onMouseMove:()=>i(l),children:l},l))})}function Rl({handleSort:e,handleLocationHistory:t,handleBookmarks:n}){return a.jsxs(Xt,{className:"tw-flex tw-justify-between",children:[a.jsx("p",{className:"tw-inline-block tw-align-middle",children:"Go To"}),a.jsxs("div",{className:"tw-flex tw-items-center",children:[a.jsx(te.ArrowDownWideNarrow,{onClick:e,className:"tw-m-2 tw-h-4 tw-w-4 tw-cursor-pointer tw-gap-2"}),a.jsx(te.Clock,{onClick:t,className:"tw-m-2 tw-h-4 tw-w-4 tw-cursor-pointer tw-gap-2"}),a.jsx(te.Bookmark,{onClick:n,className:"tw-m-2 tw-h-4 tw-w-4 tw-cursor-pointer tw-gap-2"})]})]})}const un=se.allBookIds,Pl={OT:"Old Testament",NT:"New Testament",DC:"Deuterocanon"},Jo=["OT","NT","DC"],_l=32+32+32,Il=[/^(\w+)$/i,/^(\w+)(?:\s(\d+))$/i,/^(\w+)(?:\s(\d+):(\d+))$/i],$l=e=>({OT:un.filter(n=>se.isBookOT(n)),NT:un.filter(n=>se.isBookNT(n)),DC:un.filter(n=>se.isBookDC(n))})[e],tn=e=>W.getChaptersForBook(se.bookIdToNumber(e));function Ml(){return un.map(t=>se.bookIdToEnglishName(t))}function Dl(e){return Ml().includes(e)}function Al(e){const t=e.toLowerCase().replace(/^\w/,n=>n.toUpperCase());if(Dl(t))return un.find(r=>se.bookIdToEnglishName(r)===t)}function Bl({scrRef:e,handleSubmit:t}){const[n,r]=v.useState(""),[o,s]=v.useState(se.bookNumberToId(e.bookNum)),[i,l]=v.useState(e.chapterNum??0),[c,d]=v.useState(se.bookNumberToId(e.bookNum)),[u,m]=v.useState(!1),[w,b]=v.useState(u),y=v.useRef(void 0),f=v.useRef(void 0),h=v.useRef(void 0),E=v.useCallback(N=>$l(N).filter(D=>{const $=se.bookIdToEnglishName(D).toLowerCase(),J=n.replace(/[^a-zA-Z]/g,"").toLowerCase();return $.includes(J)||D.toLowerCase().includes(J)}),[n]),I=N=>{r(N)},j=v.useRef(!1),k=v.useCallback(N=>{if(j.current){j.current=!1;return}m(N)},[]),g=v.useCallback((N,D,$,J)=>{if(l(se.bookNumberToId(e.bookNum)!==N?1:e.chapterNum),D||tn(N)===-1){t({bookNum:se.bookIdToNumber(N),chapterNum:$||1,verseNum:J||1}),m(!1),r("");return}s(o!==N?N:""),m(!D)},[t,e.bookNum,e.chapterNum,o]),P=N=>{N<=0||N>tn(o)||g(o,!0,N)},V=v.useCallback(()=>{Il.forEach(N=>{const D=n.match(N);if(D){const[$,J=void 0,Y=void 0]=D.slice(1),z=Al($);(se.isBookIdValid($)||z)&&g(z??$,!0,J?parseInt(J,10):1,Y?parseInt(Y,10):1)}})},[g,n]),U=v.useCallback(N=>{u?(N.key==="ArrowDown"||N.key==="ArrowUp")&&(typeof h<"u"&&h.current!==null?h.current.focus():typeof f<"u"&&f.current!==null&&f.current.focus(),N.preventDefault()):m(!0)},[u]),T=N=>{const{key:D}=N;D==="ArrowRight"||D==="ArrowLeft"||D==="ArrowDown"||D==="ArrowUp"||D==="Enter"||(y.current.dispatchEvent(new KeyboardEvent("keydown",{key:D})),y.current.focus())},R=N=>{const{key:D}=N;if(c===o){if(D==="Enter"){N.preventDefault(),g(o,!0,i);return}let $=0;if(D==="ArrowRight")if(i1)$=-1;else{N.preventDefault();return}else D==="ArrowDown"?$=6:D==="ArrowUp"&&($=-6);i+$<=0||i+$>tn(c)?l(0):$!==0&&(l(i+$),N.preventDefault())}};return v.useEffect(()=>{o===c?o===se.bookNumberToId(e.bookNum)?l(e.chapterNum):l(1):l(0)},[c,e.bookNum,e.chapterNum,o]),v.useLayoutEffect(()=>{b(u)},[u]),v.useLayoutEffect(()=>{const N=setTimeout(()=>{if(w&&f.current&&h.current){const $=h.current.offsetTop-_l;f.current.scrollTo({top:$,behavior:"instant"})}},10);return()=>{clearTimeout(N)}},[w]),a.jsx("div",{className:"pr-twp tw-flex",children:a.jsxs(tr,{modal:!1,open:u,onOpenChange:k,children:[a.jsx(eo,{asChild:!0,children:a.jsx(pl,{ref:y,value:n,handleSearch:I,handleKeyDown:U,handleOnClick:()=>{s(se.bookNumberToId(e.bookNum)),d(se.bookNumberToId(e.bookNum)),l(e.chapterNum>0?e.chapterNum:0),m(!0),y.current.focus()},onFocus:()=>{j.current=!0},handleSubmit:V,placeholder:`${se.bookNumberToEnglishName(e.bookNum)} ${e.chapterNum}:${e.verseNum}`})}),a.jsxs(Nn,{className:"tw-m-1 tw-overflow-y-auto tw-p-0 tw-font-normal tw-text-foreground/80",style:{width:"233px",maxHeight:"500px",zIndex:"250"},onKeyDown:T,align:"start",ref:f,children:[a.jsx(Rl,{handleSort:()=>console.log("sorting"),handleLocationHistory:()=>console.log("location history"),handleBookmarks:()=>console.log("bookmarks")}),Jo.map((N,D)=>E(N).length>0&&a.jsxs("div",{children:[a.jsx(Xt,{className:"tw-font-semibold tw-text-foreground/80",children:Pl[N]}),E(N).map($=>a.jsx("div",{children:a.jsx(jl,{bookId:$,handleSelectBook:()=>g($,!1),isSelected:o===$,handleHighlightBook:()=>d($),handleKeyDown:R,bookType:N,ref:J=>{o===$&&(h.current=J)},children:a.jsx(Ol,{handleSelectChapter:P,endChapter:tn($),activeChapter:e.bookNum===se.bookIdToNumber($)?e.chapterNum:0,highlightedChapter:i,handleHighlightedChapter:J=>{l(J)}})})},$)),Jo.length-1!==D?a.jsx(kn,{}):void 0]},N))]})]})})}const oa=Qn.cva("pr-twp tw-inline-flex tw-items-center tw-justify-center tw-whitespace-nowrap tw-rounded-md tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-colors focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50",{variants:{variant:{default:"tw-bg-primary tw-text-primary-foreground hover:tw-bg-primary/90",destructive:"tw-bg-destructive tw-text-destructive-foreground hover:tw-bg-destructive/90",outline:"tw-border tw-border-input tw-bg-background hover:tw-bg-accent hover:tw-text-accent-foreground",secondary:"tw-bg-secondary tw-text-secondary-foreground hover:tw-bg-secondary/80",ghost:"hover:tw-bg-accent hover:tw-text-accent-foreground",link:"tw-text-primary tw-underline-offset-4 hover:tw-underline"},size:{default:"tw-h-10 tw-px-4 tw-py-2",sm:"tw-h-9 tw-rounded-md tw-px-3",lg:"tw-h-11 tw-rounded-md tw-px-8",icon:"tw-h-10 tw-w-10"}},defaultVariants:{variant:"default",size:"default"}}),he=v.forwardRef(({className:e,variant:t,size:n,asChild:r=!1,...o},s)=>{const i=r?Ki.Slot:"button";return a.jsx(i,{className:S(oa({variant:t,size:n,className:e})),ref:s,...o})});he.displayName="Button";const Vl=Qn.cva("tw-text-sm tw-font-medium tw-leading-none peer-disabled:tw-cursor-not-allowed peer-disabled:tw-opacity-70"),Ue=v.forwardRef(({className:e,...t},n)=>a.jsx(qs.Root,{ref:n,className:S("pr-twp",Vl(),e),...t}));Ue.displayName=qs.Root.displayName;const ro=v.forwardRef(({className:e,...t},n)=>a.jsx(hn.Root,{className:S("pr-twp tw-grid tw-gap-2",e),...t,ref:n}));ro.displayName=hn.Root.displayName;const qn=v.forwardRef(({className:e,...t},n)=>a.jsx(hn.Item,{ref:n,className:S("pr-twp tw-aspect-square tw-h-4 tw-w-4 tw-rounded-full tw-border tw-border-primary tw-text-primary tw-ring-offset-background focus:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-cursor-not-allowed disabled:tw-opacity-50",e),...t,children:a.jsx(hn.Indicator,{className:"tw-flex tw-items-center tw-justify-center",children:a.jsx(te.Circle,{className:"tw-h-2.5 tw-w-2.5 tw-fill-current tw-text-current"})})}));qn.displayName=hn.Item.displayName;const Ll=gn.Root,Fl=gn.Trigger,sa=v.forwardRef(({className:e,align:t="center",sideOffset:n=4,...r},o)=>a.jsx(gn.Portal,{children:a.jsx(gn.Content,{ref:o,align:t,sideOffset:n,className:S("pr-twp tw-z-50 tw-w-72 tw-rounded-md tw-border tw-bg-popover tw-p-4 tw-text-popover-foreground tw-shadow-md tw-outline-none data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0 data-[state=closed]:tw-zoom-out-95 data-[state=open]:tw-zoom-in-95 data-[side=bottom]:tw-slide-in-from-top-2 data-[side=left]:tw-slide-in-from-right-2 data-[side=right]:tw-slide-in-from-left-2 data-[side=top]:tw-slide-in-from-bottom-2",e),...r})}));sa.displayName=gn.Content.displayName;const zl=Xe.Portal,aa=v.forwardRef(({className:e,...t},n)=>a.jsx(Xe.Overlay,{ref:n,className:S("tw-fixed tw-inset-0 tw-z-50 tw-bg-black/80 data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0",e),...t}));aa.displayName=Xe.Overlay.displayName;const Gl=v.forwardRef(({className:e,children:t,...n},r)=>a.jsxs(zl,{children:[a.jsx(aa,{}),a.jsxs(Xe.Content,{ref:r,className:S("tw-fixed tw-left-[50%] tw-top-[50%] tw-z-50 tw-grid tw-w-full tw-max-w-lg tw-translate-x-[-50%] tw-translate-y-[-50%] tw-gap-4 tw-border tw-bg-background tw-p-6 tw-shadow-lg tw-duration-200 data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0 data-[state=closed]:tw-zoom-out-95 data-[state=open]:tw-zoom-in-95 data-[state=closed]:tw-slide-out-to-left-1/2 data-[state=closed]:tw-slide-out-to-top-[48%] data-[state=open]:tw-slide-in-from-left-1/2 data-[state=open]:tw-slide-in-from-top-[48%] sm:tw-rounded-lg",e),...n,children:[t,a.jsxs(Xe.Close,{className:"tw-absolute tw-right-4 tw-top-4 tw-rounded-sm tw-opacity-70 tw-ring-offset-background tw-transition-opacity hover:tw-opacity-100 focus:tw-outline-none focus:tw-ring-2 focus:tw-ring-ring focus:tw-ring-offset-2 disabled:tw-pointer-events-none data-[state=open]:tw-bg-accent data-[state=open]:tw-text-muted-foreground",children:[a.jsx(te.X,{className:"tw-h-4 tw-w-4"}),a.jsx("span",{className:"tw-sr-only",children:"Close"})]})]})]}));Gl.displayName=Xe.Content.displayName;const Ul=v.forwardRef(({className:e,...t},n)=>a.jsx(Xe.Title,{ref:n,className:S("tw-text-lg tw-font-semibold tw-leading-none tw-tracking-tight",e),...t}));Ul.displayName=Xe.Title.displayName;const ql=v.forwardRef(({className:e,...t},n)=>a.jsx(Xe.Description,{ref:n,className:S("tw-text-sm tw-text-muted-foreground",e),...t}));ql.displayName=Xe.Description.displayName;const ia=v.forwardRef(({className:e,...t},n)=>a.jsx(je.Command,{ref:n,className:S("tw-flex tw-h-full tw-w-full tw-flex-col tw-overflow-hidden tw-rounded-md tw-bg-popover tw-text-popover-foreground",e),...t}));ia.displayName=je.Command.displayName;const la=v.forwardRef(({className:e,...t},n)=>a.jsxs("div",{className:"tw-flex tw-items-center tw-border-b tw-px-3",children:[a.jsx(te.Search,{className:"tw-me-2 tw-h-4 tw-w-4 tw-shrink-0 tw-opacity-50"}),a.jsx(je.Command.Input,{ref:n,className:S("tw-flex tw-h-11 tw-w-full tw-rounded-md tw-bg-transparent tw-py-3 tw-text-sm tw-outline-none placeholder:tw-text-muted-foreground disabled:tw-cursor-not-allowed disabled:tw-opacity-50",e),...t})]}));la.displayName=je.Command.Input.displayName;const ca=v.forwardRef(({className:e,...t},n)=>a.jsx(je.Command.List,{ref:n,className:S("tw-max-h-[300px] tw-overflow-y-auto tw-overflow-x-hidden",e),...t}));ca.displayName=je.Command.List.displayName;const da=v.forwardRef((e,t)=>a.jsx(je.Command.Empty,{ref:t,className:"tw-py-6 tw-text-center tw-text-sm",...e}));da.displayName=je.Command.Empty.displayName;const Hl=v.forwardRef(({className:e,...t},n)=>a.jsx(je.Command.Group,{ref:n,className:S("tw-overflow-hidden tw-p-1 tw-text-foreground [&_[cmdk-group-heading]]:tw-px-2 [&_[cmdk-group-heading]]:tw-py-1.5 [&_[cmdk-group-heading]]:tw-text-xs [&_[cmdk-group-heading]]:tw-font-medium [&_[cmdk-group-heading]]:tw-text-muted-foreground",e),...t}));Hl.displayName=je.Command.Group.displayName;const Xl=v.forwardRef(({className:e,...t},n)=>a.jsx(je.Command.Separator,{ref:n,className:S("tw--mx-1 tw-h-px tw-bg-border",e),...t}));Xl.displayName=je.Command.Separator.displayName;const ua=v.forwardRef(({className:e,...t},n)=>a.jsx(je.Command.Item,{ref:n,className:S("tw-relative tw-flex tw-cursor-default tw-select-none tw-items-center tw-rounded-sm tw-px-2 tw-py-1.5 tw-text-sm tw-outline-none data-[disabled=true]:tw-pointer-events-none data-[selected=true]:tw-bg-accent data-[selected=true]:tw-text-accent-foreground data-[disabled=true]:tw-opacity-50",e),...t}));ua.displayName=je.Command.Item.displayName;function Yl(e){return typeof e=="string"?e:typeof e=="number"?e.toString():e.label}function Lr({id:e,options:t=[],className:n,value:r,onChange:o=()=>{},getOptionLabel:s=Yl,buttonPlaceholder:i="",textPlaceholder:l="",commandEmptyMessage:c="No option found",buttonVariant:d="outline",dir:u="ltr",isDisabled:m=!1,...w}){const[b,y]=v.useState(!1);return a.jsxs(Ll,{open:b,onOpenChange:y,...w,children:[a.jsx(Fl,{asChild:!0,children:a.jsxs(he,{variant:d,role:"combobox","aria-expanded":b,id:e,className:S("tw-w-[200px] tw-justify-between",n),disabled:m,children:[a.jsx("span",{className:"tw-overflow-hidden tw-text-ellipsis tw-whitespace-nowrap",children:r?s(r):i}),a.jsx(te.ChevronsUpDown,{className:"tw-ms-2 tw-h-4 tw-w-4 tw-shrink-0 tw-opacity-50"})]})}),a.jsx(sa,{className:"tw-w-[200px] tw-p-0",dir:u,children:a.jsxs(ia,{children:[a.jsx(la,{dir:u,placeholder:l,className:"tw-text-inherit"}),a.jsx(da,{children:c}),a.jsx(ca,{children:t.map(f=>a.jsxs(ua,{value:s(f),onSelect:()=>{o(f),y(!1)},children:[a.jsx(te.Check,{className:S("tw-me-2 tw-h-4 tw-w-4",{"tw-opacity-0":!r||s(r)!==s(f)})}),s(f)]},s(f)))})]})})]})}function pa({startChapter:e,endChapter:t,handleSelectStartChapter:n,handleSelectEndChapter:r,isDisabled:o=!1,chapterCount:s}){const i=v.useMemo(()=>Array.from({length:s},(d,u)=>u+1),[s]),l=d=>{n(d),d>t&&r(d)},c=d=>{r(d),dd.toString(),value:e},"start chapter"),a.jsx(Ue,{htmlFor:"end-chapters-combobox",children:"to"}),a.jsx(Lr,{isDisabled:o,onChange:c,className:"tw-ml-2 tw-w-20",options:i,getOptionLabel:d=>d.toString(),value:t},"end chapter")]})}var wa=(e=>(e.CURRENT_BOOK="current book",e.CHOOSE_BOOKS="choose books",e))(wa||{});const Wl=Object.freeze(["%webView_bookSelector_currentBook%","%webView_bookSelector_choose%","%webView_bookSelector_chooseBooks%"]),kr=(e,t)=>e[t]??t;function Kl({handleBookSelectionModeChange:e,currentBookName:t,onSelectBooks:n,selectedBookIds:r,chapterCount:o,endChapter:s,handleSelectEndChapter:i,startChapter:l,handleSelectStartChapter:c,localizedStrings:d}){const u=kr(d,"%webView_bookSelector_currentBook%"),m=kr(d,"%webView_bookSelector_choose%"),w=kr(d,"%webView_bookSelector_chooseBooks%"),[b,y]=v.useState("current book"),f=h=>{y(h),e(h)};return a.jsx(ro,{className:"pr-twp tw-flex",value:b,onValueChange:h=>f(h),children:a.jsxs("div",{className:"tw-flex tw-w-full tw-flex-col tw-gap-4",children:[a.jsxs("div",{className:"tw-grid tw-grid-cols-[25%,25%,50%]",children:[a.jsxs("div",{className:"tw-flex tw-items-center",children:[a.jsx(qn,{value:"current book"}),a.jsx(Ue,{className:"tw-ml-1",children:u})]}),a.jsx(Ue,{className:"tw-flex tw-items-center",children:t}),a.jsx("div",{className:"tw-flex tw-items-center tw-justify-end",children:a.jsx(pa,{isDisabled:b==="choose books",handleSelectStartChapter:c,handleSelectEndChapter:i,chapterCount:o,startChapter:l,endChapter:s})})]}),a.jsxs("div",{className:"tw-grid tw-grid-cols-[25%,50%,25%]",children:[a.jsxs("div",{className:"tw-flex tw-items-center",children:[a.jsx(qn,{value:"choose books"}),a.jsx(Ue,{className:"tw-ml-1",children:w})]}),a.jsx(Ue,{className:"tw-flex tw-items-center",children:r.map(h=>se.bookIdToEnglishName(h)).join(", ")}),a.jsx(he,{disabled:b==="current book",onClick:()=>n(),children:m})]})]})})}function Jl({table:e}){return a.jsxs(tr,{children:[a.jsx(Gs.DropdownMenuTrigger,{asChild:!0,children:a.jsxs(he,{variant:"outline",size:"sm",className:"tw-ml-auto tw-hidden tw-h-8 lg:tw-flex",children:[a.jsx(te.FilterIcon,{className:"tw-mr-2 tw-h-4 tw-w-4"}),"View"]})}),a.jsxs(Nn,{align:"end",className:"tw-w-[150px]",children:[a.jsx(Xt,{children:"Toggle columns"}),a.jsx(kn,{}),e.getAllColumns().filter(t=>t.getCanHide()).map(t=>a.jsx(nr,{className:"tw-capitalize",checked:t.getIsVisible(),onCheckedChange:n=>t.toggleVisibility(!!n),children:t.id},t.id))]})]})}const Dt=ge.Root,fa=ge.Group,At=ge.Value,bt=v.forwardRef(({className:e,children:t,...n},r)=>a.jsxs(ge.Trigger,{ref:r,className:S("tw-flex tw-h-10 tw-w-full tw-items-center tw-justify-between tw-rounded-md tw-border tw-border-input tw-bg-background tw-px-3 tw-py-2 tw-text-sm tw-ring-offset-background placeholder:tw-text-muted-foreground focus:tw-outline-none focus:tw-ring-2 focus:tw-ring-ring focus:tw-ring-offset-2 disabled:tw-cursor-not-allowed disabled:tw-opacity-50 [&>span]:tw-line-clamp-1",e),...n,children:[t,a.jsx(ge.Icon,{asChild:!0,children:a.jsx(te.ChevronDown,{className:"tw-h-4 tw-w-4 tw-opacity-50"})})]}));bt.displayName=ge.Trigger.displayName;const oo=v.forwardRef(({className:e,...t},n)=>a.jsx(ge.ScrollUpButton,{ref:n,className:S("tw-flex tw-cursor-default tw-items-center tw-justify-center tw-py-1",e),...t,children:a.jsx(te.ChevronUp,{className:"tw-h-4 tw-w-4"})}));oo.displayName=ge.ScrollUpButton.displayName;const so=v.forwardRef(({className:e,...t},n)=>a.jsx(ge.ScrollDownButton,{ref:n,className:S("tw-flex tw-cursor-default tw-items-center tw-justify-center tw-py-1",e),...t,children:a.jsx(te.ChevronDown,{className:"tw-h-4 tw-w-4"})}));so.displayName=ge.ScrollDownButton.displayName;const vt=v.forwardRef(({className:e,children:t,position:n="popper",...r},o)=>a.jsx(ge.Portal,{children:a.jsxs(ge.Content,{ref:o,className:S("pr-twp tw-relative tw-z-50 tw-max-h-96 tw-min-w-[8rem] tw-overflow-hidden tw-rounded-md tw-border tw-bg-popover tw-text-popover-foreground tw-shadow-md data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0 data-[state=closed]:tw-zoom-out-95 data-[state=open]:tw-zoom-in-95 data-[side=bottom]:tw-slide-in-from-top-2 data-[side=left]:tw-slide-in-from-right-2 data-[side=right]:tw-slide-in-from-left-2 data-[side=top]:tw-slide-in-from-bottom-2",n==="popper"&&"data-[side=bottom]:tw-translate-y-1 data-[side=left]:tw--translate-x-1 data-[side=right]:tw-translate-x-1 data-[side=top]:tw--translate-y-1",e),position:n,...r,children:[a.jsx(oo,{}),a.jsx(ge.Viewport,{className:S("tw-p-1",n==="popper"&&"tw-h-[var(--radix-select-trigger-height)] tw-w-full tw-min-w-[var(--radix-select-trigger-width)]"),children:t}),a.jsx(so,{})]})}));vt.displayName=ge.Content.displayName;const ma=v.forwardRef(({className:e,...t},n)=>a.jsx(ge.Label,{ref:n,className:S("tw-py-1.5 tw-pl-8 tw-pr-2 tw-text-sm tw-font-semibold",e),...t}));ma.displayName=ge.Label.displayName;const De=v.forwardRef(({className:e,children:t,...n},r)=>a.jsxs(ge.Item,{ref:r,className:S("tw-relative tw-flex tw-w-full tw-cursor-default tw-select-none tw-items-center tw-rounded-sm tw-py-1.5 tw-pl-8 tw-pr-2 tw-text-sm tw-outline-none focus:tw-bg-accent focus:tw-text-accent-foreground data-[disabled]:tw-pointer-events-none data-[disabled]:tw-opacity-50",e),...n,children:[a.jsx("span",{className:"tw-absolute tw-left-2 tw-flex tw-h-3.5 tw-w-3.5 tw-items-center tw-justify-center",children:a.jsx(ge.ItemIndicator,{children:a.jsx(te.Check,{className:"tw-h-4 tw-w-4"})})}),a.jsx(ge.ItemText,{children:t})]}));De.displayName=ge.Item.displayName;const ha=v.forwardRef(({className:e,...t},n)=>a.jsx(ge.Separator,{ref:n,className:S("tw--mx-1 tw-my-1 tw-h-px tw-bg-muted",e),...t}));ha.displayName=ge.Separator.displayName;function Zl({table:e}){return a.jsx("div",{className:"tw-flex tw-items-center tw-justify-between tw-px-2 tw-pb-3 tw-pt-3",children:a.jsxs("div",{className:"tw-flex tw-items-center tw-space-x-6 lg:tw-space-x-8",children:[a.jsxs("div",{className:"tw-flex-1 tw-text-sm tw-text-muted-foreground",children:[e.getFilteredSelectedRowModel().rows.length," of"," ",e.getFilteredRowModel().rows.length," row(s) selected"]}),a.jsxs("div",{className:"tw-flex tw-items-center tw-space-x-2",children:[a.jsx("p",{className:"tw-text-nowrap tw-text-sm tw-font-medium",children:"Rows per page"}),a.jsxs(Dt,{value:`${e.getState().pagination.pageSize}`,onValueChange:t=>{e.setPageSize(Number(t))},children:[a.jsx(bt,{className:"tw-h-8 tw-w-[70px]",children:a.jsx(At,{placeholder:e.getState().pagination.pageSize})}),a.jsx(vt,{side:"top",children:[10,20,30,40,50].map(t=>a.jsx(De,{value:`${t}`,children:t},t))})]})]}),a.jsxs("div",{className:"tw-flex tw-w-[100px] tw-items-center tw-justify-center tw-text-sm tw-font-medium",children:["Page ",e.getState().pagination.pageIndex+1," of ",e.getPageCount()]}),a.jsxs("div",{className:"tw-flex tw-items-center tw-space-x-2",children:[a.jsxs(he,{variant:"outline",size:"icon",className:"tw-hidden tw-h-8 tw-w-8 tw-p-0 lg:tw-flex",onClick:()=>e.setPageIndex(0),disabled:!e.getCanPreviousPage(),children:[a.jsx("span",{className:"tw-sr-only",children:"Go to first page"}),a.jsx(te.ArrowLeftIcon,{className:"tw-h-4 tw-w-4"})]}),a.jsxs(he,{variant:"outline",size:"icon",className:"tw-h-8 tw-w-8 tw-p-0",onClick:()=>e.previousPage(),disabled:!e.getCanPreviousPage(),children:[a.jsx("span",{className:"tw-sr-only",children:"Go to previous page"}),a.jsx(te.ChevronLeftIcon,{className:"tw-h-4 tw-w-4"})]}),a.jsxs(he,{variant:"outline",size:"icon",className:"tw-h-8 tw-w-8 tw-p-0",onClick:()=>e.nextPage(),disabled:!e.getCanNextPage(),children:[a.jsx("span",{className:"tw-sr-only",children:"Go to next page"}),a.jsx(te.ChevronRightIcon,{className:"tw-h-4 tw-w-4"})]}),a.jsxs(he,{variant:"outline",size:"icon",className:"tw-hidden tw-h-8 tw-w-8 tw-p-0 lg:tw-flex",onClick:()=>e.setPageIndex(e.getPageCount()-1),disabled:!e.getCanNextPage(),children:[a.jsx("span",{className:"tw-sr-only",children:"Go to last page"}),a.jsx(te.ArrowRightIcon,{className:"tw-h-4 tw-w-4"})]})]})]})})}const En=v.forwardRef(({className:e,stickyHeader:t,...n},r)=>a.jsx("div",{className:S("pr-twp tw-relative tw-w-full",{"tw-overflow-auto":!t}),children:a.jsx("table",{ref:r,className:S("tw-w-full tw-caption-bottom tw-text-sm",e),...n})}));En.displayName="Table";const Sn=v.forwardRef(({className:e,stickyHeader:t,...n},r)=>a.jsx("thead",{ref:r,className:S({"tw-sticky tw-top-[-1px] tw-bg-background tw-drop-shadow-sm":t},"[&_tr]:tw-border-b",e),...n}));Sn.displayName="TableHeader";const Tn=v.forwardRef(({className:e,...t},n)=>a.jsx("tbody",{ref:n,className:S("[&_tr:last-child]:tw-border-0",e),...t}));Tn.displayName="TableBody";const ga=v.forwardRef(({className:e,...t},n)=>a.jsx("tfoot",{ref:n,className:S("tw-border-t tw-bg-muted/50 tw-font-medium [&>tr]:last:tw-border-b-0",e),...t}));ga.displayName="TableFooter";const Ze=v.forwardRef(({className:e,...t},n)=>a.jsx("tr",{ref:n,className:S("tw-border-b tw-transition-colors hover:tw-bg-muted/50 data-[state=selected]:tw-bg-muted",e),...t}));Ze.displayName="TableRow";const Bt=v.forwardRef(({className:e,...t},n)=>a.jsx("th",{ref:n,className:S("tw-h-12 tw-px-4 tw-text-start tw-align-middle tw-font-medium tw-text-muted-foreground [&:has([role=checkbox])]:tw-pe-0",e),...t}));Bt.displayName="TableHead";const yt=v.forwardRef(({className:e,...t},n)=>a.jsx("td",{ref:n,className:S("tw-p-4 tw-align-middle [&:has([role=checkbox])]:tw-pe-0",e),...t}));yt.displayName="TableCell";const ba=v.forwardRef(({className:e,...t},n)=>a.jsx("caption",{ref:n,className:S("tw-mt-4 tw-text-sm tw-text-muted-foreground",e),...t}));ba.displayName="TableCaption";function va({columns:e,data:t,enablePagination:n=!1,showPaginationControls:r=!1,showColumnVisibilityControls:o=!1,stickyHeader:s=!1,onRowClickHandler:i=()=>{}}){var h;const[l,c]=v.useState([]),[d,u]=v.useState([]),[m,w]=v.useState({}),[b,y]=v.useState({}),f=Ne.useReactTable({data:t,columns:e,getCoreRowModel:Ne.getCoreRowModel(),...n&&{getPaginationRowModel:Ne.getPaginationRowModel()},onSortingChange:c,getSortedRowModel:Ne.getSortedRowModel(),onColumnFiltersChange:u,getFilteredRowModel:Ne.getFilteredRowModel(),onColumnVisibilityChange:w,onRowSelectionChange:y,state:{sorting:l,columnFilters:d,columnVisibility:m,rowSelection:b}});return a.jsxs("div",{className:"pr-twp",children:[o&&a.jsx(Jl,{table:f}),a.jsxs(En,{stickyHeader:s,children:[a.jsx(Sn,{stickyHeader:s,children:f.getHeaderGroups().map(E=>a.jsx(Ze,{children:E.headers.map(I=>a.jsx(Bt,{children:I.isPlaceholder?void 0:Ne.flexRender(I.column.columnDef.header,I.getContext())},I.id))},E.id))}),a.jsx(Tn,{children:(h=f.getRowModel().rows)!=null&&h.length?f.getRowModel().rows.map(E=>a.jsx(Ze,{onClick:()=>i(E,f),"data-state":E.getIsSelected()&&"selected",children:E.getVisibleCells().map(I=>a.jsx(yt,{children:Ne.flexRender(I.column.columnDef.cell,I.getContext())},I.id))},E.id)):a.jsx(Ze,{children:a.jsx(yt,{colSpan:e.length,className:"tw-h-24 tw-text-center",children:"No results."})})})]}),n&&a.jsxs("div",{className:"tw-flex tw-items-center tw-justify-end tw-space-x-2 tw-py-4",children:[a.jsx(he,{variant:"outline",size:"sm",onClick:()=>f.previousPage(),disabled:!f.getCanPreviousPage(),children:"Previous"}),a.jsx(he,{variant:"outline",size:"sm",onClick:()=>f.nextPage(),disabled:!f.getCanNextPage(),children:"Next"})]}),n&&r&&a.jsx(Zl,{table:f})]})}function Ql({occurrenceData:e,setScriptureReference:t,localizedStrings:n}){const r=n["%webView_inventory_occurrences_table_header_reference%"],o=n["%webView_inventory_occurrences_table_header_occurrence%"],s=v.useMemo(()=>{const i=[];return e.forEach(l=>{i.some(c=>W.deepEqual(c,l))||i.push(l)}),i},[e]);return a.jsxs(En,{stickyHeader:!0,children:[a.jsx(Sn,{stickyHeader:!0,children:a.jsxs(Ze,{children:[a.jsx(Bt,{children:r}),a.jsx(Bt,{children:o})]})}),a.jsx(Tn,{children:s.length>0&&s.map(i=>a.jsxs(Ze,{onClick:()=>{t(i.reference)},children:[a.jsx(yt,{children:`${se.bookNumberToEnglishName(i.reference.bookNum)} ${i.reference.chapterNum}:${i.reference.verseNum}`}),a.jsx(yt,{children:i.text})]},`${i.reference.bookNum} ${i.reference.chapterNum}:${i.reference.verseNum}-${i.text}`))})]})}const rr=v.forwardRef(({className:e,...t},n)=>a.jsx(Br.Root,{ref:n,className:S("tw-peer pr-twp tw-h-4 tw-w-4 tw-shrink-0 tw-rounded-sm tw-border tw-border-primary tw-ring-offset-background focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-cursor-not-allowed disabled:tw-opacity-50 data-[state=checked]:tw-bg-primary data-[state=checked]:tw-text-primary-foreground",e),...t,children:a.jsx(Br.Indicator,{className:S("tw-flex tw-items-center tw-justify-center tw-text-current"),children:a.jsx(te.Check,{className:"tw-h-4 tw-w-4"})})}));rr.displayName=Br.Root.displayName;const ya=e=>e.split(/(?:\r?\n|\r)|(?=(?:\\(?:v|c|id)))/g),Fr=e=>{const t=/^\\[vc]\s+(\d+)/,n=e.match(t);if(n)return+n[1]},xa=e=>{const t=e.match(/^\\id\s+([A-Za-z]+)/);return t?se.bookIdToNumber(t[1]):0},Na=(e,t,n)=>n.includes(e)?"unapproved":t.includes(e)?"approved":"unknown",ka=Qn.cva("pr-twp tw-inline-flex tw-items-center tw-justify-center tw-rounded-md tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-colors hover:tw-bg-muted hover:tw-text-muted-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50 data-[state=on]:tw-bg-accent data-[state=on]:tw-text-accent-foreground",{variants:{variant:{default:"tw-bg-transparent",outline:"tw-border tw-border-input tw-bg-transparent hover:tw-bg-accent hover:tw-text-accent-foreground"},size:{default:"tw-h-10 tw-px-3",sm:"tw-h-9 tw-px-2.5",lg:"tw-h-11 tw-px-5"}},defaultVariants:{variant:"default",size:"default"}}),ec=v.forwardRef(({className:e,variant:t,size:n,...r},o)=>a.jsx(Hs.Root,{ref:o,className:S(ka({variant:t,size:n,className:e})),...r}));ec.displayName=Hs.Root.displayName;const Ea=v.createContext({size:"default",variant:"default"}),ao=v.forwardRef(({className:e,variant:t,size:n,children:r,...o},s)=>a.jsx(er.Root,{ref:s,className:S("pr-twp tw-flex tw-items-center tw-justify-center tw-gap-1",e),...o,children:a.jsx(Ea.Provider,{value:{variant:t,size:n},children:r})}));ao.displayName=er.Root.displayName;const pn=v.forwardRef(({className:e,children:t,variant:n,size:r,...o},s)=>{const i=v.useContext(Ea);return a.jsx(er.Item,{ref:s,className:S(ka({variant:i.variant||n,size:i.size||r}),e),...o,children:t})});pn.displayName=er.Item.displayName;const or=e=>e==="asc"?a.jsx(te.ArrowUpIcon,{className:"tw-ms-2 tw-h-4 tw-w-4"}):e==="desc"?a.jsx(te.ArrowDownIcon,{className:"tw-ms-2 tw-h-4 tw-w-4"}):a.jsx(te.ArrowUpDownIcon,{className:"tw-ms-2 tw-h-4 tw-w-4"}),tc=e=>({accessorKey:"item",accessorFn:t=>t.items[0],header:({column:t})=>a.jsxs(he,{variant:"ghost",onClick:()=>t.toggleSorting(void 0),children:[e,or(t.getIsSorted())]})}),nc=(e,t)=>({accessorKey:`item${t}`,accessorFn:n=>n.items[t],header:({column:n})=>a.jsxs(he,{variant:"ghost",onClick:()=>n.toggleSorting(void 0),children:[e,or(n.getIsSorted())]})}),rc=e=>({accessorKey:"count",header:({column:t})=>a.jsx("div",{className:"tw-flex tw-justify-end tw-tabular-nums",children:a.jsxs(he,{variant:"ghost",onClick:()=>t.toggleSorting(void 0),children:[e,or(t.getIsSorted())]})}),cell:({row:t})=>a.jsx("div",{className:"tw-flex tw-justify-end",children:t.getValue("count")})}),Er=(e,t,n,r,o,s)=>{let i=[...n];e.forEach(c=>{t==="approved"?i.includes(c)||i.push(c):i=i.filter(d=>d!==c)}),r(i);let l=[...o];e.forEach(c=>{t==="unapproved"?l.includes(c)||l.push(c):l=l.filter(d=>d!==c)}),s(l)},oc=(e,t,n,r,o)=>({accessorKey:"status",header:({column:s})=>a.jsx("div",{className:"tw-flex tw-justify-center",children:a.jsxs(he,{variant:"ghost",onClick:()=>s.toggleSorting(void 0),children:[e,or(s.getIsSorted())]})}),cell:({row:s})=>{const i=s.getValue("status"),l=s.getValue("item");return a.jsxs(ao,{value:i,variant:"outline",type:"single",children:[a.jsx(pn,{onClick:()=>Er([l],"approved",t,n,r,o),value:"approved",children:a.jsx(te.CircleCheckIcon,{})}),a.jsx(pn,{onClick:()=>Er([l],"unapproved",t,n,r,o),value:"unapproved",children:a.jsx(te.CircleXIcon,{})}),a.jsx(pn,{onClick:()=>Er([l],"unknown",t,n,r,o),value:"unknown",children:a.jsx(te.CircleHelpIcon,{})})]})}}),sc=Object.freeze(["%webView_inventory_all%","%webView_inventory_approved%","%webView_inventory_unapproved%","%webView_inventory_unknown%","%webView_inventory_scope_currentBook%","%webView_inventory_scope_chapter%","%webView_inventory_scope_verse%","%webView_inventory_filter_text%","%webView_inventory_show_additional_items%","%webView_inventory_occurrences_table_header_reference%","%webView_inventory_occurrences_table_header_occurrence%"]),ac=(e,t,n)=>{let r=e;return t!=="all"&&(r=r.filter(o=>t==="approved"&&o.status==="approved"||t==="unapproved"&&o.status==="unapproved"||t==="unknown"&&o.status==="unknown")),n!==""&&(r=r.filter(o=>o.items[0].includes(n))),r},ic=(e,t,n,r,o)=>{if(!e)return[];const s=[];let i=t.bookNum,l=t.chapterNum,c=t.verseNum;return ya(e).forEach(u=>{u.startsWith("\\id")&&(i=xa(u),l=0,c=0),u.startsWith("\\c")&&(l=Fr(u),c=0),u.startsWith("\\v")&&(c=Fr(u),l===0&&(l=t.chapterNum));let m=o.exec(u)??void 0;for(;m;){const w=[];m.forEach(h=>w.push(h));const b=m.index,y=s.find(h=>W.deepEqual(h.items,w)),f={reference:{bookNum:i!==void 0?i:-1,chapterNum:l!==void 0?l:-1,verseNum:c!==void 0?c:-1},text:W.substring(u,Math.max(0,b-25),Math.min(b+25,u.length))};if(y)y.count+=1,y.occurrences.push(f);else{const h={items:w,count:1,status:Na(w[0],n,r),occurrences:[f]};s.push(h)}m=o.exec(u)??void 0}}),s},Je=(e,t)=>e[t]??t;function lc({scriptureReference:e,setScriptureReference:t,localizedStrings:n,extractItems:r,additionalItemsLabels:o,approvedItems:s,unapprovedItems:i,text:l,scope:c,onScopeChange:d,columns:u}){const m=Je(n,"%webView_inventory_all%"),w=Je(n,"%webView_inventory_approved%"),b=Je(n,"%webView_inventory_unapproved%"),y=Je(n,"%webView_inventory_unknown%"),f=Je(n,"%webView_inventory_scope_currentBook%"),h=Je(n,"%webView_inventory_scope_chapter%"),E=Je(n,"%webView_inventory_scope_verse%"),I=Je(n,"%webView_inventory_filter_text%"),j=Je(n,"%webView_inventory_show_additional_items%"),[k,g]=v.useState(!1),[P,V]=v.useState("all"),[U,T]=v.useState(""),[R,N]=v.useState([]),D=v.useMemo(()=>l?r instanceof RegExp?ic(l,e,s,i,r):r(l,e,s,i):[],[l,r,e,s,i]),$=v.useMemo(()=>{if(k)return D;const x=[];return D.forEach(C=>{const L=C.items[0],F=x.find(B=>B.items[0]===L);F?(F.count+=C.count,F.occurrences=F.occurrences.concat(C.occurrences)):x.push({items:[L],count:C.count,occurrences:C.occurrences,status:C.status})}),x},[k,D]),J=v.useMemo(()=>ac($,P,U),[$,P,U]),Y=v.useMemo(()=>{var L,F;if(!k)return u;const x=(L=o==null?void 0:o.tableHeaders)==null?void 0:L.length;if(!x)return u;const C=[];for(let B=0;B{N([])},[J]);const z=(x,C)=>{C.setRowSelection(()=>{const L={};return L[x.index]=!0,L}),N(x.original.items)},ee=x=>{if(x==="book"||x==="chapter"||x==="verse")d(x);else throw new Error(`Invalid scope value: ${x}`)},ae=x=>{if(x==="all"||x==="approved"||x==="unapproved"||x==="unknown")V(x);else throw new Error(`Invalid status filter value: ${x}`)},oe=v.useMemo(()=>{if($.length===0||R.length===0)return[];const x=$.filter(C=>W.deepEqual(k?C.items:[C.items[0]],R));if(x.length>1)throw new Error("Selected item is not unique");return x[0].occurrences},[R,k,$]);return a.jsxs("div",{className:"pr-twp tw-flex tw-h-full tw-flex-col",children:[a.jsxs("div",{className:"tw-flex tw-items-stretch",children:[a.jsxs(Dt,{onValueChange:x=>ae(x),defaultValue:P,children:[a.jsx(bt,{className:"tw-m-1",children:a.jsx(At,{placeholder:"Select filter"})}),a.jsxs(vt,{children:[a.jsx(De,{value:"all",children:m}),a.jsx(De,{value:"approved",children:w}),a.jsx(De,{value:"unapproved",children:b}),a.jsx(De,{value:"unknown",children:y})]})]}),a.jsxs(Dt,{onValueChange:x=>ee(x),defaultValue:c,children:[a.jsx(bt,{className:"tw-m-1",children:a.jsx(At,{placeholder:"Select scope"})}),a.jsxs(vt,{children:[a.jsx(De,{value:"book",children:f}),a.jsx(De,{value:"chapter",children:h}),a.jsx(De,{value:"verse",children:E})]})]}),a.jsx(qt,{className:"tw-m-1 tw-rounded-md tw-border",placeholder:I,value:U,onChange:x=>{T(x.target.value)}}),o&&a.jsxs("div",{className:"tw-m-1 tw-flex tw-items-center tw-rounded-md tw-border",children:[a.jsx(rr,{className:"tw-m-1",checked:k,onCheckedChange:x=>{N([]),g(x)}}),a.jsx(Ue,{className:"tw-m-1 tw-flex-shrink-0 tw-whitespace-nowrap",children:(o==null?void 0:o.checkboxText)??j})]})]}),a.jsx("div",{className:"tw-m-1 tw-flex-1 tw-overflow-auto tw-rounded-md tw-border",children:a.jsx(va,{columns:Y,data:J,onRowClickHandler:z,stickyHeader:!0})}),oe.length>0&&a.jsx("div",{className:"tw-m-1 tw-flex-1 tw-overflow-auto tw-rounded-md tw-border",children:a.jsx(Ql,{occurrenceData:oe,setScriptureReference:t,localizedStrings:n})})]})}function Sa({onSearch:e,placeholder:t,isFullWidth:n}){const[r,o]=v.useState(""),s=i=>{o(i),e(i)};return a.jsx(qt,{className:S("tw-flex tw-h-10 tw-rounded-md tw-border tw-border-input tw-bg-background tw-px-3 tw-py-2 tw-text-sm tw-ring-offset-background file:tw-border-0 file:tw-bg-transparent file:tw-text-sm file:tw-font-medium placeholder:tw-text-muted-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-[color:hsl(240,5%,64.9%)] focus-visible:tw-ring-offset-2 disabled:tw-cursor-not-allowed disabled:tw-opacity-50",{"tw-w-full":n}),placeholder:t,value:r,onChange:i=>s(i.target.value)})}const io=v.forwardRef(({className:e,...t},n)=>a.jsx(Oe.Root,{orientation:"vertical",ref:n,className:S("tw-flex tw-gap-1 tw-rounded-md tw-text-muted-foreground",e),...t}));io.displayName=Oe.List.displayName;const lo=v.forwardRef(({className:e,...t},n)=>a.jsx(Oe.List,{ref:n,className:S("tw-flex-fit tw-mlk-items-center tw-w-[124px] tw-justify-center tw-rounded-md tw-bg-muted tw-p-1 tw-text-muted-foreground",e),...t}));lo.displayName=Oe.List.displayName;const Ta=v.forwardRef(({className:e,...t},n)=>a.jsx(Oe.Trigger,{ref:n,...t,className:S("overflow-clip tw-inline-flex tw-w-[116px] tw-cursor-pointer tw-items-center tw-justify-center tw-break-words tw-rounded-sm tw-border-0 tw-bg-muted tw-px-3 tw-py-1.5 tw-text-sm tw-font-medium tw-text-inherit tw-ring-offset-background tw-transition-all hover:tw-text-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50 data-[state=active]:tw-bg-background data-[state=active]:tw-text-foreground data-[state=active]:tw-shadow-sm",e)})),co=v.forwardRef(({className:e,...t},n)=>a.jsx(Oe.Content,{ref:n,className:S("tw-ms-5 tw-flex-grow tw-text-foreground tw-ring-offset-background focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2",e),...t}));co.displayName=Oe.Content.displayName;function cc({tabList:e,onSearch:t,searchPlaceholder:n,headerTitle:r,isSearchBarFullWidth:o=!1,direction:s="ltr"}){return a.jsxs("div",{className:"pr-twp",children:[a.jsxs("div",{className:"tw-sticky tw-top-0 tw-space-y-2 tw-pb-2",children:[r?a.jsx("h1",{children:r}):"",a.jsx(Sa,{isFullWidth:o,onSearch:t,placeholder:n})]}),a.jsxs(io,{dir:s,children:[a.jsx(lo,{children:e.map(i=>a.jsx(Ta,{value:i.value,children:i.value},i.key))}),e.map(i=>a.jsx(co,{value:i.value,children:i.content},i.key))]})]})}const rt="scrBook",dc="scrRef",pt="source",uc="details",pc="Scripture Reference",wc="Scripture Book",Ca="Type",fc="Details";function mc(e,t){const n=t??!1;return[{accessorFn:r=>`${se.bookNumberToId(r.start.bookNum)} ${r.start.chapterNum}:${r.start.verseNum}`,id:rt,header:(e==null?void 0:e.scriptureReferenceColumnName)??pc,cell:r=>{const o=r.row.original;return r.row.getIsGrouped()?se.bookNumberToEnglishName(o.start.bookNum):r.row.groupingColumnId===rt?W.formatScrRef(o.start):void 0},getGroupingValue:r=>r.start.bookNum,sortingFn:(r,o)=>W.compareScrRefs(r.original.start,o.original.start),enableGrouping:!0},{accessorFn:r=>W.formatScrRef(r.start),id:dc,header:void 0,cell:r=>{const o=r.row.original;return r.row.getIsGrouped()?void 0:W.formatScrRef(o.start)},sortingFn:(r,o)=>W.compareScrRefs(r.original.start,o.original.start),enableGrouping:!1},{accessorFn:r=>r.source.displayName,id:pt,header:n?(e==null?void 0:e.typeColumnName)??Ca:void 0,cell:r=>n||r.row.getIsGrouped()?r.getValue():void 0,getGroupingValue:r=>r.source.id,sortingFn:(r,o)=>r.original.source.displayName.localeCompare(o.original.source.displayName),enableGrouping:!0},{accessorFn:r=>r.detail,id:uc,header:(e==null?void 0:e.detailsColumnName)??fc,cell:r=>r.getValue(),enableGrouping:!1}]}const hc=e=>{if(!("offset"in e.start))throw new Error("No offset available in range start");if(e.end&&!("offset"in e.end))throw new Error("No offset available in range end");const{offset:t}=e.start;let n=0;return e.end&&({offset:n}=e.end),!e.end||W.compareScrRefs(e.start,e.end)===0?`${W.scrRefToBBBCCCVVV(e.start)}+${t}`:`${W.scrRefToBBBCCCVVV(e.start)}+${t}-${W.scrRefToBBBCCCVVV(e.end)}+${n}`},Zo=e=>`${hc({start:e.start,end:e.end})} ${e.source.displayName} ${e.detail}`;function gc({sources:e,showColumnHeaders:t=!1,showSourceColumn:n=!1,scriptureReferenceColumnName:r,scriptureBookGroupName:o,typeColumnName:s,detailsColumnName:i,onRowSelected:l,direction:c="ltr"}){const[d,u]=v.useState([]),[m,w]=v.useState([{id:rt,desc:!1}]),[b,y]=v.useState({}),f=v.useMemo(()=>e.flatMap(T=>T.data.map(R=>({...R,source:T.source}))),[e]),h=v.useMemo(()=>mc({scriptureReferenceColumnName:r,typeColumnName:s,detailsColumnName:i},n),[r,s,i,n]);v.useEffect(()=>{d.includes(pt)?w([{id:pt,desc:!1},{id:rt,desc:!1}]):w([{id:rt,desc:!1}])},[d]);const E=Ne.useReactTable({data:f,columns:h,state:{grouping:d,sorting:m,rowSelection:b},onGroupingChange:u,onSortingChange:w,onRowSelectionChange:y,getExpandedRowModel:Ne.getExpandedRowModel(),getGroupedRowModel:Ne.getGroupedRowModel(),getCoreRowModel:Ne.getCoreRowModel(),getSortedRowModel:Ne.getSortedRowModel(),getRowId:Zo,autoResetExpanded:!1,enableMultiRowSelection:!1,enableSubRowSelection:!1});v.useEffect(()=>{if(l){const T=E.getSelectedRowModel().rowsById,R=Object.keys(T);if(R.length===1){const N=f.find(D=>Zo(D)===R[0])||void 0;N&&l(N)}}},[b,f,l,E]);const I=o??wc,j=s??Ca,k=[{label:"No Grouping",value:[]},{label:`Group by ${I}`,value:[rt]},{label:`Group by ${j}`,value:[pt]},{label:`Group by ${I} and ${j}`,value:[rt,pt]},{label:`Group by ${j} and ${I}`,value:[pt,rt]}],g=T=>{u(JSON.parse(T))},P=(T,R)=>{!T.getIsGrouped()&&!T.getIsSelected()&&T.getToggleSelectedHandler()(R)},V=(T,R)=>T.getIsGrouped()?"":S("banded-row",R%2===0?"even":"odd"),U=(T,R,N)=>{if(!((T==null?void 0:T.length)===0||R.depth{g(T)},children:[a.jsx(bt,{className:"tw-mb-1 tw-mt-2",children:a.jsx(At,{})}),a.jsx(vt,{position:"item-aligned",children:a.jsx(fa,{children:k.map(T=>a.jsx(De,{value:JSON.stringify(T.value),children:T.label},T.label))})})]}),a.jsxs(En,{className:"tw-relative tw-flex tw-flex-col tw-overflow-y-auto tw-p-0",children:[t&&a.jsx(Sn,{children:E.getHeaderGroups().map(T=>a.jsx(Ze,{children:T.headers.filter(R=>R.column.columnDef.header).map(R=>a.jsx(Bt,{colSpan:R.colSpan,className:"top-0 tw-sticky",children:R.isPlaceholder?void 0:a.jsxs("div",{children:[R.column.getCanGroup()?a.jsx(he,{variant:"ghost",title:`Toggle grouping by ${R.column.columnDef.header}`,onClick:R.column.getToggleGroupingHandler(),type:"button",children:R.column.getIsGrouped()?"🛑":"👊 "}):void 0," ",Ne.flexRender(R.column.columnDef.header,R.getContext())]})},R.id))},T.id))}),a.jsx(Tn,{children:E.getRowModel().rows.map((T,R)=>a.jsx(Ze,{"data-state":T.getIsSelected()?"selected":"",className:S(V(T,R)),onClick:N=>P(T,N),children:T.getVisibleCells().map(N=>{if(!(N.getIsPlaceholder()||N.column.columnDef.enableGrouping&&!N.getIsGrouped()&&(N.column.columnDef.id!==pt||!n)))return a.jsx(yt,{className:S(N.column.columnDef.id,"tw-p-[1px]",U(d,T,N)),children:(()=>N.getIsGrouped()?a.jsxs(he,{variant:"link",onClick:T.getToggleExpandedHandler(),type:"button",children:[T.getIsExpanded()&&a.jsx(te.ChevronDown,{}),!T.getIsExpanded()&&(c==="ltr"?a.jsx(te.ChevronRight,{}):a.jsx(te.ChevronLeft,{}))," ",Ne.flexRender(N.column.columnDef.cell,N.getContext())," (",T.subRows.length,")"]}):Ne.flexRender(N.column.columnDef.cell,N.getContext()))()},N.id)})},T.id))})]})]})}const Sr={[W.getLocalizeKeyForScrollGroupId("undefined")]:"Ø",[W.getLocalizeKeyForScrollGroupId(0)]:"A",[W.getLocalizeKeyForScrollGroupId(1)]:"B",[W.getLocalizeKeyForScrollGroupId(2)]:"C",[W.getLocalizeKeyForScrollGroupId(3)]:"D",[W.getLocalizeKeyForScrollGroupId(4)]:"E",[W.getLocalizeKeyForScrollGroupId(5)]:"F",[W.getLocalizeKeyForScrollGroupId(6)]:"G",[W.getLocalizeKeyForScrollGroupId(7)]:"H",[W.getLocalizeKeyForScrollGroupId(8)]:"I",[W.getLocalizeKeyForScrollGroupId(9)]:"J",[W.getLocalizeKeyForScrollGroupId(10)]:"K",[W.getLocalizeKeyForScrollGroupId(11)]:"L",[W.getLocalizeKeyForScrollGroupId(12)]:"M",[W.getLocalizeKeyForScrollGroupId(13)]:"N",[W.getLocalizeKeyForScrollGroupId(14)]:"O",[W.getLocalizeKeyForScrollGroupId(15)]:"P",[W.getLocalizeKeyForScrollGroupId(16)]:"Q",[W.getLocalizeKeyForScrollGroupId(17)]:"R",[W.getLocalizeKeyForScrollGroupId(18)]:"S",[W.getLocalizeKeyForScrollGroupId(19)]:"T",[W.getLocalizeKeyForScrollGroupId(20)]:"U",[W.getLocalizeKeyForScrollGroupId(21)]:"V",[W.getLocalizeKeyForScrollGroupId(22)]:"W",[W.getLocalizeKeyForScrollGroupId(23)]:"X",[W.getLocalizeKeyForScrollGroupId(24)]:"Y",[W.getLocalizeKeyForScrollGroupId(25)]:"Z"};function bc({availableScrollGroupIds:e,scrollGroupId:t,onChangeScrollGroupId:n,localizedStrings:r={}}){const o={...Sr,...Object.fromEntries(Object.entries(r).map(([s,i])=>[s,s===i&&s in Sr?Sr[s]:i]))};return a.jsxs(Dt,{value:`${t}`,onValueChange:s=>n(s==="undefined"?void 0:parseInt(s,10)),children:[a.jsx(bt,{className:"pr-twp tw-w-auto",children:a.jsx(At,{placeholder:o[W.getLocalizeKeyForScrollGroupId(t)]??t})}),a.jsx(vt,{style:{zIndex:250},children:e.map(s=>a.jsx(De,{value:`${s}`,children:o[W.getLocalizeKeyForScrollGroupId(s)]},`${s}`))})]})}const uo=v.forwardRef(({className:e,orientation:t="horizontal",decorative:n=!0,...r},o)=>a.jsx(Xs.Root,{ref:o,decorative:n,orientation:t,className:S("pr-twp tw-shrink-0 tw-bg-border",t==="horizontal"?"tw-h-[1px] tw-w-full":"tw-h-full tw-w-[1px]",e),...r}));uo.displayName=Xs.Root.displayName;function vc({children:e}){return a.jsx("div",{className:"pr-twp tw-grid",children:e})}function yc({primary:e,secondary:t,children:n,isLoading:r=!1,loadingMessage:o}){return a.jsxs("div",{className:"tw-flex tw-items-center tw-justify-between tw-space-x-4 tw-py-2",children:[a.jsxs("div",{children:[a.jsx("p",{className:"tw-text-sm tw-font-medium tw-leading-none",children:e}),a.jsx("p",{className:"tw-whitespace-normal tw-break-words tw-text-sm tw-text-muted-foreground",children:t})]}),r?a.jsx("p",{className:"tw-text-sm tw-text-muted-foreground",children:o}):a.jsx("div",{children:n})]})}function xc({primary:e,secondary:t,includeSeparator:n=!1}){return a.jsxs("div",{className:"tw-space-y-4 tw-py-2",children:[a.jsxs("div",{children:[a.jsx("h3",{className:"tw-text-lg tw-font-medium",children:e}),a.jsx("p",{className:"tw-text-sm tw-text-muted-foreground",children:t})]}),n?a.jsx(uo,{}):""]})}function Nc({id:e,className:t,listItems:n,selectedListItems:r,handleSelectListItem:o,createLabel:s}){return a.jsx("div",{id:e,className:t,children:n.map(i=>a.jsxs("div",{className:"tw-m-2 tw-flex tw-items-center",children:[a.jsx(rr,{className:"tw-mr-2 tw-align-middle",checked:r.includes(i),onCheckedChange:l=>o(i,l)}),a.jsx(Ue,{children:s?s(i):i})]},i))})}function kc(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}function Ec(e){if(e.__esModule)return e;var t=e.default;if(typeof t=="function"){var n=function r(){return this instanceof r?Reflect.construct(t,arguments,this.constructor):t.apply(this,arguments)};n.prototype=t.prototype}else n={};return Object.defineProperty(n,"__esModule",{value:!0}),Object.keys(e).forEach(function(r){var o=Object.getOwnPropertyDescriptor(e,r);Object.defineProperty(n,r,o.get?o:{enumerable:!0,get:function(){return e[r]}})}),n}var po={},ja={exports:{}};(function(e){function t(n){return n&&n.__esModule?n:{default:n}}e.exports=t,e.exports.__esModule=!0,e.exports.default=e.exports})(ja);var Sc=ja.exports,Tr={};function wo(e,t){return process.env.NODE_ENV==="production"?()=>null:function(...r){return e(...r)||t(...r)}}function O(){return O=Object.assign?Object.assign.bind():function(e){for(var t=1;t{t[n]=Oa(e[n])}),t}function Qe(e,t,n={clone:!0}){const r=n.clone?O({},e):e;return mt(e)&&mt(t)&&Object.keys(t).forEach(o=>{o!=="__proto__"&&(mt(t[o])&&o in e&&mt(e[o])?r[o]=Qe(e[o],t[o],n):n.clone?r[o]=mt(t[o])?Oa(t[o]):t[o]:r[o]=t[o])}),r}var zr={exports:{}},An={exports:{}},ie={};/** @license React v16.13.1 +"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const a=require("react/jsx-runtime"),g=require("react"),Q=require("lucide-react"),ot=require("clsx"),ml=require("tailwind-merge"),Za=require("@radix-ui/react-dropdown-menu"),W=require("platform-bible-utils"),Ht=require("@radix-ui/react-slot"),Xt=require("class-variance-authority"),hl=require("@radix-ui/react-label"),gl=require("@radix-ui/react-radio-group"),bl=require("@radix-ui/react-popover"),Oe=require("cmdk"),vl=require("@radix-ui/react-dialog"),Se=require("@tanstack/react-table"),xl=require("@radix-ui/react-select"),yl=require("@radix-ui/react-checkbox"),Nl=require("@radix-ui/react-toggle-group"),kl=require("@radix-ui/react-toggle"),Sl=require("@radix-ui/react-tabs"),El=require("@radix-ui/react-separator"),jl=require("@radix-ui/react-tooltip"),Te=require("@mui/material"),Fr=require("@mui/styled-engine"),ln=require("react-dom"),Qa=require("sonner"),Tl=require("@radix-ui/react-slider"),Cl=require("@radix-ui/react-switch"),Rl=require("markdown-to-jsx");function ke(e){const t=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(e){for(const n in e)if(n!=="default"){const r=Object.getOwnPropertyDescriptor(e,n);Object.defineProperty(t,n,r.get?r:{enumerable:!0,get:()=>e[n]})}}return t.default=e,Object.freeze(t)}const M=ke(g),pe=ke(Za),es=ke(hl),bn=ke(gl),vn=ke(bl),be=ke(vl),ge=ke(xl),Gr=ke(yl),nr=ke(Nl),ts=ke(kl),_e=ke(Sl),ns=ke(El),Sn=ke(jl),Ol=ke(ln),cn=ke(Tl),Ur=ke(Cl);const _l=ml.extendTailwindMerge({prefix:"tw-"});function N(...e){return _l(ot.clsx(e))}const St=g.forwardRef(({className:e,type:t,...n},r)=>a.jsx("input",{type:t,className:N("pr-twp tw-flex tw-h-10 tw-rounded-md tw-border tw-border-input tw-bg-background tw-px-3 tw-py-2 tw-text-sm tw-ring-offset-background file:tw-border-0 file:tw-bg-transparent file:tw-text-sm file:tw-font-medium file:tw-text-foreground placeholder:tw-text-muted-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-cursor-not-allowed disabled:tw-opacity-50",e),ref:r,...n}));St.displayName="Input";const Pl=g.forwardRef(({handleSearch:e,handleKeyDown:t,handleOnClick:n,handleSubmit:r,...o},s)=>a.jsxs("div",{className:"tw-relative",children:[a.jsx(St,{...o,type:"text",className:"tw-box-border tw-gap-2.5 tw-rounded-lg tw-border tw-border-solid tw-bg-background tw-py-2 tw-pl-4 tw-pr-3 tw-font-medium tw-shadow-none tw-outline-none",onChange:i=>e(i.target.value),onKeyDown:i=>{i.key==="Enter"&&r(),t(i)},onClick:n,ref:s}),a.jsx(Q.History,{className:"tw-absolute tw-right-3 tw-top-1/2 tw-h-4 tw-w-4 tw--translate-y-1/2 tw-transform tw-cursor-pointer tw-text-muted-foreground",onClick:()=>{console.log("back in history")}})]}));var Il=Object.defineProperty,Ml=(e,t,n)=>t in e?Il(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,ne=(e,t,n)=>Ml(e,typeof t!="symbol"?t+"":t,n);const gt=["GEN","EXO","LEV","NUM","DEU","JOS","JDG","RUT","1SA","2SA","1KI","2KI","1CH","2CH","EZR","NEH","EST","JOB","PSA","PRO","ECC","SNG","ISA","JER","LAM","EZK","DAN","HOS","JOL","AMO","OBA","JON","MIC","NAM","HAB","ZEP","HAG","ZEC","MAL","MAT","MRK","LUK","JHN","ACT","ROM","1CO","2CO","GAL","EPH","PHP","COL","1TH","2TH","1TI","2TI","TIT","PHM","HEB","JAS","1PE","2PE","1JN","2JN","3JN","JUD","REV","TOB","JDT","ESG","WIS","SIR","BAR","LJE","S3Y","SUS","BEL","1MA","2MA","3MA","4MA","1ES","2ES","MAN","PS2","ODA","PSS","JSA","JDB","TBS","SST","DNT","BLT","XXA","XXB","XXC","XXD","XXE","XXF","XXG","FRT","BAK","OTH","3ES","EZA","5EZ","6EZ","INT","CNC","GLO","TDX","NDX","DAG","PS3","2BA","LBA","JUB","ENO","1MQ","2MQ","3MQ","REP","4BA","LAO"],no=["XXA","XXB","XXC","XXD","XXE","XXF","XXG","FRT","BAK","OTH","INT","CNC","GLO","TDX","NDX"],rs=["Genesis","Exodus","Leviticus","Numbers","Deuteronomy","Joshua","Judges","Ruth","1 Samuel","2 Samuel","1 Kings","2 Kings","1 Chronicles","2 Chronicles","Ezra","Nehemiah","Esther (Hebrew)","Job","Psalms","Proverbs","Ecclesiastes","Song of Songs","Isaiah","Jeremiah","Lamentations","Ezekiel","Daniel (Hebrew)","Hosea","Joel","Amos","Obadiah","Jonah","Micah","Nahum","Habakkuk","Zephaniah","Haggai","Zechariah","Malachi","Matthew","Mark","Luke","John","Acts","Romans","1 Corinthians","2 Corinthians","Galatians","Ephesians","Philippians","Colossians","1 Thessalonians","2 Thessalonians","1 Timothy","2 Timothy","Titus","Philemon","Hebrews","James","1 Peter","2 Peter","1 John","2 John","3 John","Jude","Revelation","Tobit","Judith","Esther Greek","Wisdom of Solomon","Sirach (Ecclesiasticus)","Baruch","Letter of Jeremiah","Song of 3 Young Men","Susanna","Bel and the Dragon","1 Maccabees","2 Maccabees","3 Maccabees","4 Maccabees","1 Esdras (Greek)","2 Esdras (Latin)","Prayer of Manasseh","Psalm 151","Odes","Psalms of Solomon","Joshua A. *obsolete*","Judges B. *obsolete*","Tobit S. *obsolete*","Susanna Th. *obsolete*","Daniel Th. *obsolete*","Bel Th. *obsolete*","Extra A","Extra B","Extra C","Extra D","Extra E","Extra F","Extra G","Front Matter","Back Matter","Other Matter","3 Ezra *obsolete*","Apocalypse of Ezra","5 Ezra (Latin Prologue)","6 Ezra (Latin Epilogue)","Introduction","Concordance ","Glossary ","Topical Index","Names Index","Daniel Greek","Psalms 152-155","2 Baruch (Apocalypse)","Letter of Baruch","Jubilees","Enoch","1 Meqabyan","2 Meqabyan","3 Meqabyan","Reproof (Proverbs 25-31)","4 Baruch (Rest of Baruch)","Laodiceans"],ra=Ul();function Yt(e,t=!0){return t&&(e=e.toUpperCase()),e in ra?ra[e]:0}function ro(e){return Yt(e)>0}function $l(e){const t=typeof e=="string"?Yt(e):e;return t>=40&&t<=66}function Dl(e){return(typeof e=="string"?Yt(e):e)<=39}function os(e){return e<=66}function Al(e){const t=typeof e=="string"?Yt(e):e;return is(t)&&!os(t)}function*Bl(){for(let e=1;e<=gt.length;e++)yield e}const Vl=1,as=gt.length;function zl(){return["XXA","XXB","XXC","XXD","XXE","XXF","XXG"]}function oo(e,t="***"){const n=e-1;return n<0||n>=gt.length?t:gt[n]}function ss(e){return e<=0||e>as?"******":rs[e-1]}function Ll(e){return ss(Yt(e))}function is(e){const t=typeof e=="number"?oo(e):e;return ro(t)&&!no.includes(t)}function Fl(e){const t=typeof e=="number"?oo(e):e;return ro(t)&&no.includes(t)}function Gl(e){return rs[e-1].includes("*obsolete*")}function Ul(){const e={};for(let t=0;t(e[e.Unknown=0]="Unknown",e[e.Original=1]="Original",e[e.Septuagint=2]="Septuagint",e[e.Vulgate=3]="Vulgate",e[e.English=4]="English",e[e.RussianProtestant=5]="RussianProtestant",e[e.RussianOrthodox=6]="RussianOrthodox",e))(He||{});const Ie=class{constructor(t){if(ne(this,"name"),ne(this,"fullPath"),ne(this,"isPresent"),ne(this,"hasVerseSegments"),ne(this,"isCustomized"),ne(this,"baseVersification"),ne(this,"scriptureBooks"),ne(this,"_type"),t==null)throw new Error("Argument undefined");typeof t=="string"?(this.name=t,this._type=He[t]):(this._type=t,this.name=He[t])}get type(){return this._type}equals(t){return!t.type||!this.type?!1:t.type===this.type}};ne(Ie,"Original",new Ie(He.Original)),ne(Ie,"Septuagint",new Ie(He.Septuagint)),ne(Ie,"Vulgate",new Ie(He.Vulgate)),ne(Ie,"English",new Ie(He.English)),ne(Ie,"RussianProtestant",new Ie(He.RussianProtestant)),ne(Ie,"RussianOrthodox",new Ie(He.RussianOrthodox));let ut=Ie;function oa(e,t){const n=t[0];for(let r=1;r(e[e.Valid=0]="Valid",e[e.UnknownVersification=1]="UnknownVersification",e[e.OutOfRange=2]="OutOfRange",e[e.VerseOutOfOrder=3]="VerseOutOfOrder",e[e.VerseRepeated=4]="VerseRepeated",e))(ls||{});const je=class re{constructor(t,n,r,o){if(ne(this,"firstChapter"),ne(this,"lastChapter"),ne(this,"lastVerse"),ne(this,"hasSegmentsDefined"),ne(this,"text"),ne(this,"BBBCCCVVVS"),ne(this,"longHashCode"),ne(this,"versification"),ne(this,"rtlMark","‏"),ne(this,"_bookNum",0),ne(this,"_chapterNum",0),ne(this,"_verseNum",0),ne(this,"_verse"),r==null&&o==null)if(t!=null&&typeof t=="string"){const s=t,i=n!=null&&n instanceof ut?n:void 0;this.setEmpty(i),this.parse(s)}else if(t!=null&&typeof t=="number"){const s=n!=null&&n instanceof ut?n:void 0;this.setEmpty(s),this._verseNum=t%re.chapterDigitShifter,this._chapterNum=Math.floor(t%re.bookDigitShifter/re.chapterDigitShifter),this._bookNum=Math.floor(t/re.bookDigitShifter)}else if(n==null)if(t!=null&&t instanceof re){const s=t;this._bookNum=s.bookNum,this._chapterNum=s.chapterNum,this._verseNum=s.verseNum,this._verse=s.verse,this.versification=s.versification}else{if(t==null)return;const s=t instanceof ut?t:re.defaultVersification;this.setEmpty(s)}else throw new Error("VerseRef constructor not supported.");else if(t!=null&&n!=null&&r!=null)if(typeof t=="string"&&typeof n=="string"&&typeof r=="string")this.setEmpty(o),this.updateInternal(t,n,r);else if(typeof t=="number"&&typeof n=="number"&&typeof r=="number")this._bookNum=t,this._chapterNum=n,this._verseNum=r,this.versification=o??re.defaultVersification;else throw new Error("VerseRef constructor not supported.");else throw new Error("VerseRef constructor not supported.")}static isVerseParseable(t){return t.length>0&&"0123456789".includes(t[0])&&!t.endsWith(this.verseRangeSeparator)&&!t.endsWith(this.verseSequenceIndicator)}static tryParse(t){let n;try{return n=new re(t),{success:!0,verseRef:n}}catch(r){if(r instanceof nn)return n=new re,{success:!1,verseRef:n};throw r}}static getBBBCCCVVV(t,n,r){return t%re.bcvMaxValue*re.bookDigitShifter+(n>=0?n%re.bcvMaxValue*re.chapterDigitShifter:0)+(r>=0?r%re.bcvMaxValue:0)}static fromJSON(t){const{book:n,chapterNum:r,verseNum:o,verse:s,versificationStr:i}=t,l=s||o.toString();let c;return i&&(c=new ut(i)),n?new re(n,r.toString(),l,c):new re}static tryGetVerseNum(t){let n;if(!t)return n=-1,{success:!0,vNum:n};n=0;let r;for(let o=0;o"9")return o===0&&(n=-1),{success:!1,vNum:n};if(n=n*10+ +r-0,n>re.bcvMaxValue)return n=-1,{success:!1,vNum:n}}return{success:!0,vNum:n}}get isDefault(){return this.bookNum===0&&this.chapterNum===0&&this.verseNum===0&&this.versification==null}get hasMultiple(){return this._verse!=null&&(this._verse.includes(re.verseRangeSeparator)||this._verse.includes(re.verseSequenceIndicator))}get book(){return ae.bookNumberToId(this.bookNum,"")}set book(t){this.bookNum=ae.bookIdToNumber(t)}get chapter(){return this.isDefault||this._chapterNum<0?"":this._chapterNum.toString()}set chapter(t){const n=+t;this._chapterNum=Number.isInteger(n)?n:-1}get verse(){return this._verse!=null?this._verse:this.isDefault||this._verseNum<0?"":this._verseNum.toString()}set verse(t){const{success:n,vNum:r}=re.tryGetVerseNum(t);this._verse=n?void 0:t.replace(this.rtlMark,""),this._verseNum=r,!(this._verseNum>=0)&&({vNum:this._verseNum}=re.tryGetVerseNum(this._verse))}get bookNum(){return this._bookNum}set bookNum(t){if(t<=0||t>ae.lastBook)throw new nn("BookNum must be greater than zero and less than or equal to last book");this._bookNum=t}get chapterNum(){return this._chapterNum}set chapterNum(t){this.chapterNum=t}get verseNum(){return this._verseNum}set verseNum(t){this._verseNum=t}get versificationStr(){var t;return(t=this.versification)==null?void 0:t.name}set versificationStr(t){this.versification=this.versification!=null?new ut(t):void 0}get valid(){return this.validStatus===0}get validStatus(){return this.validateVerse(re.verseRangeSeparators,re.verseSequenceIndicators)}get BBBCCC(){return re.getBBBCCCVVV(this._bookNum,this._chapterNum,0)}get BBBCCCVVV(){return re.getBBBCCCVVV(this._bookNum,this._chapterNum,this._verseNum)}get isExcluded(){return!1}parse(t){if(t=t.replace(this.rtlMark,""),t.includes("/")){const s=t.split("/");if(t=s[0],s.length>1)try{const i=+s[1].trim();this.versification=new ut(He[i])}catch{throw new nn("Invalid reference : "+t)}}const n=t.trim().split(" ");if(n.length!==2)throw new nn("Invalid reference : "+t);const r=n[1].split(":"),o=+r[0];if(r.length!==2||ae.bookIdToNumber(n[0])===0||!Number.isInteger(o)||o<0||!re.isVerseParseable(r[1]))throw new nn("Invalid reference : "+t);this.updateInternal(n[0],r[0],r[1])}simplify(){this._verse=void 0}clone(){return new re(this)}toString(){const t=this.book;return t===""?"":`${t} ${this.chapter}:${this.verse}`}toJSON(){let t=this.verse;(t===""||t===this.verseNum.toString())&&(t=void 0);const n={book:this.book,chapterNum:this.chapterNum,verseNum:this.verseNum,verse:t,versificationStr:this.versificationStr};return t||delete n.verse,n}equals(t){return t instanceof re?t._bookNum===this._bookNum&&t._chapterNum===this._chapterNum&&t._verseNum===this._verseNum&&t.verse===this.verse&&(t.versification==null&&this.versification==null||t.versification!=null&&this.versification!=null&&t.versification.equals(this.versification)):!1}allVerses(t=!1,n=re.verseRangeSeparators,r=re.verseSequenceIndicators){if(this._verse==null||this.chapterNum<=0)return[this.clone()];const o=[],s=oa(this._verse,r);for(const i of s.map(l=>oa(l,n))){const l=this.clone();l.verse=i[0];const c=l.verseNum;if(o.push(l),i.length>1){const d=this.clone();if(d.verse=i[1],!t)for(let u=c+1;ui)return 3;if(r===i)return 4;r=i}return 0}get internalValid(){return this.versification==null?1:this._bookNum<=0||this._bookNum>ae.lastBook?2:(ae.isCanonical(this._bookNum),0)}setEmpty(t=re.defaultVersification){this._bookNum=0,this._chapterNum=-1,this._verse=void 0,this.versification=t}updateInternal(t,n,r){this.bookNum=ae.bookIdToNumber(t),this.chapter=n,this.verse=r}};ne(je,"defaultVersification",ut.English),ne(je,"verseRangeSeparator","-"),ne(je,"verseSequenceIndicator",","),ne(je,"verseRangeSeparators",[je.verseRangeSeparator]),ne(je,"verseSequenceIndicators",[je.verseSequenceIndicator]),ne(je,"chapterDigitShifter",1e3),ne(je,"bookDigitShifter",je.chapterDigitShifter*je.chapterDigitShifter),ne(je,"bcvMaxValue",je.chapterDigitShifter-1),ne(je,"ValidStatusType",ls);class nn extends Error{}const rr=pe.Root,ao=pe.Trigger,cs=pe.Group,ql=pe.Portal,Hl=pe.Sub,Xl=pe.RadioGroup,ds=g.forwardRef(({className:e,inset:t,children:n,...r},o)=>a.jsxs(pe.SubTrigger,{ref:o,className:N("tw-flex tw-cursor-default tw-select-none tw-items-center tw-rounded-sm tw-px-2 tw-py-1.5 tw-text-sm tw-outline-none focus:tw-bg-accent data-[state=open]:tw-bg-accent",t&&"tw-pl-8",e),...r,children:[n,a.jsx(Q.ChevronRight,{className:"tw-ml-auto tw-h-4 tw-w-4"})]}));ds.displayName=pe.SubTrigger.displayName;const us=g.forwardRef(({className:e,...t},n)=>a.jsx(pe.SubContent,{ref:n,className:N("tw-z-50 tw-min-w-[8rem] tw-overflow-hidden tw-rounded-md tw-border tw-bg-popover tw-p-1 tw-text-popover-foreground tw-shadow-lg data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0 data-[state=closed]:tw-zoom-out-95 data-[state=open]:tw-zoom-in-95 data-[side=bottom]:tw-slide-in-from-top-2 data-[side=left]:tw-slide-in-from-right-2 data-[side=right]:tw-slide-in-from-left-2 data-[side=top]:tw-slide-in-from-bottom-2",e),...t}));us.displayName=pe.SubContent.displayName;const En=g.forwardRef(({className:e,sideOffset:t=4,...n},r)=>a.jsx(pe.Portal,{children:a.jsx(pe.Content,{ref:r,sideOffset:t,className:N("pr-twp tw-z-50 tw-min-w-[8rem] tw-overflow-hidden tw-rounded-md tw-border tw-bg-popover tw-p-1 tw-text-popover-foreground tw-shadow-md data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0 data-[state=closed]:tw-zoom-out-95 data-[state=open]:tw-zoom-in-95 data-[side=bottom]:tw-slide-in-from-top-2 data-[side=left]:tw-slide-in-from-right-2 data-[side=right]:tw-slide-in-from-left-2 data-[side=top]:tw-slide-in-from-bottom-2",e),...n})}));En.displayName=pe.Content.displayName;const so=g.forwardRef(({className:e,inset:t,...n},r)=>a.jsx(pe.Item,{ref:r,className:N("tw-cursor-default tw-select-none tw-items-center tw-rounded-sm tw-px-2 tw-py-1.5 tw-text-sm tw-outline-none tw-transition-colors focus:tw-bg-accent data-[disabled]:tw-pointer-events-none data-[disabled]:tw-opacity-50",t&&"tw-pl-8",e),...n}));so.displayName=pe.Item.displayName;const or=g.forwardRef(({className:e,children:t,checked:n,...r},o)=>a.jsxs(pe.CheckboxItem,{ref:o,className:N("tw-relative tw-flex tw-cursor-default tw-select-none tw-items-center tw-rounded-sm tw-py-1.5 tw-pl-8 tw-pr-2 tw-text-sm tw-outline-none tw-transition-colors focus:tw-bg-accent focus:tw-text-accent-foreground data-[disabled]:tw-pointer-events-none data-[disabled]:tw-opacity-50",e),checked:n,...r,children:[a.jsx("span",{className:"tw-absolute tw-left-2 tw-flex tw-h-3.5 tw-w-3.5 tw-items-center tw-justify-center",children:a.jsx(pe.ItemIndicator,{children:a.jsx(Q.Check,{className:"tw-h-4 tw-w-4"})})}),t]}));or.displayName=pe.CheckboxItem.displayName;const io=g.forwardRef(({className:e,children:t,...n},r)=>a.jsxs(pe.RadioItem,{ref:r,className:N("tw-relative tw-flex tw-cursor-default tw-select-none tw-items-center tw-rounded-sm tw-py-1.5 tw-pl-8 tw-pr-2 tw-text-sm tw-outline-none tw-transition-colors focus:tw-bg-accent focus:tw-text-accent-foreground data-[disabled]:tw-pointer-events-none data-[disabled]:tw-opacity-50",e),...n,children:[a.jsx("span",{className:"tw-absolute tw-left-2 tw-flex tw-h-3.5 tw-w-3.5 tw-items-center tw-justify-center",children:a.jsx(pe.ItemIndicator,{children:a.jsx(Q.Circle,{className:"tw-h-2 tw-w-2 tw-fill-current"})})}),t]}));io.displayName=pe.RadioItem.displayName;const Wt=g.forwardRef(({className:e,inset:t,...n},r)=>a.jsx(pe.Label,{ref:r,className:N("tw-px-2 tw-py-1.5 tw-text-sm tw-font-semibold",t&&"tw-pl-8",e),...n}));Wt.displayName=pe.Label.displayName;const jn=g.forwardRef(({className:e,...t},n)=>a.jsx(pe.Separator,{ref:n,className:N("tw--mx-1 tw-my-1 tw-h-px tw-bg-muted",e),...t}));jn.displayName=pe.Separator.displayName;function ps({className:e,...t}){return a.jsx("span",{className:N("tw-ml-auto tw-text-xs tw-tracking-widest tw-opacity-60",e),...t})}ps.displayName="DropdownMenuShortcut";const Yl=g.forwardRef(({bookId:e,handleSelectBook:t,isSelected:n,handleHighlightBook:r,handleKeyDown:o,bookType:s,children:i},l)=>a.jsxs(so,{ref:l,textValue:e,className:N("tw-mx-1 tw-px-1 tw-font-normal tw-text-foreground/80",{"tw-bg-amber-50 tw-text-yellow-900 data-[highlighted]:tw-bg-amber-100":n}),onSelect:c=>{c.preventDefault(),t()},onKeyDown:c=>{o(c)},onFocus:r,onMouseMove:r,children:[a.jsx("span",{className:N("tw-border-b-0 tw-border-l-2 tw-border-r-0 tw-border-t-0 tw-border-solid tw-px-2",{"tw-font-bold":n,"tw-border-l-red-200":s.toLowerCase()==="ot","tw-border-l-purple-200":s.toLowerCase()==="nt","tw-border-l-indigo-200":s.toLowerCase()==="dc"}),children:ae.bookIdToEnglishName(e)}),n&&a.jsx("div",{children:i})]},e));function Wl({handleSelectChapter:e,endChapter:t,activeChapter:n,highlightedChapter:r,handleHighlightedChapter:o}){const s=Array.from({length:t},(l,c)=>c+1),i=g.useCallback(l=>{o(l)},[o]);return a.jsx("div",{className:N("tw-flex tw-flex-wrap tw-items-start tw-justify-start tw-self-stretch"),children:s.map(l=>a.jsx("div",{className:N("tw-box-content tw-flex tw-h-4 tw-w-4 tw-cursor-pointer tw-items-center tw-justify-end tw-rounded-md tw-p-2 tw-text-amber-800",{"tw-font-semibold tw-text-amber-900":l===n,"tw-bg-amber-200":l===r}),onClick:c=>{c.preventDefault(),c.stopPropagation(),e(l)},role:"button",onKeyDown:c=>{c.key==="Enter"&&e(l)},tabIndex:0,onMouseMove:()=>i(l),children:l},l))})}function Kl({handleSort:e,handleLocationHistory:t,handleBookmarks:n}){return a.jsxs(Wt,{className:"tw-flex tw-justify-between",children:[a.jsx("p",{className:"tw-inline-block tw-align-middle",children:"Go To"}),a.jsxs("div",{className:"tw-flex tw-items-center",children:[a.jsx(Q.ArrowDownWideNarrow,{onClick:e,className:"tw-m-2 tw-h-4 tw-w-4 tw-cursor-pointer tw-gap-2"}),a.jsx(Q.Clock,{onClick:t,className:"tw-m-2 tw-h-4 tw-w-4 tw-cursor-pointer tw-gap-2"}),a.jsx(Q.Bookmark,{onClick:n,className:"tw-m-2 tw-h-4 tw-w-4 tw-cursor-pointer tw-gap-2"})]})]})}const wn=ae.allBookIds,Jl={OT:"Old Testament",NT:"New Testament",DC:"Deuterocanon"},aa=["OT","NT","DC"],Zl=32+32+32,Ql=[/^(\w+)$/i,/^(\w+)(?:\s(\d+))$/i,/^(\w+)(?:\s(\d+):(\d+))$/i],ec=e=>({OT:wn.filter(n=>ae.isBookOT(n)),NT:wn.filter(n=>ae.isBookNT(n)),DC:wn.filter(n=>ae.isBookDC(n))})[e],rn=e=>W.getChaptersForBook(ae.bookIdToNumber(e));function tc(){return wn.map(t=>ae.bookIdToEnglishName(t))}function nc(e){return tc().includes(e)}function rc(e){const t=e.toLowerCase().replace(/^\w/,n=>n.toUpperCase());if(nc(t))return wn.find(r=>ae.bookIdToEnglishName(r)===t)}function oc({scrRef:e,handleSubmit:t}){const[n,r]=g.useState(""),[o,s]=g.useState(ae.bookNumberToId(e.bookNum)),[i,l]=g.useState(e.chapterNum??0),[c,d]=g.useState(ae.bookNumberToId(e.bookNum)),[u,m]=g.useState(!1),[w,b]=g.useState(u),x=g.useRef(void 0),f=g.useRef(void 0),h=g.useRef(void 0),S=g.useCallback(k=>ec(k).filter(D=>{const $=ae.bookIdToEnglishName(D).toLowerCase(),J=n.replace(/[^a-zA-Z]/g,"").toLowerCase();return $.includes(J)||D.toLowerCase().includes(J)}),[n]),R=k=>{r(k)},j=g.useRef(!1),E=g.useCallback(k=>{if(j.current){j.current=!1;return}m(k)},[]),v=g.useCallback((k,D,$,J)=>{if(l(ae.bookNumberToId(e.bookNum)!==k?1:e.chapterNum),D||rn(k)===-1){t({bookNum:ae.bookIdToNumber(k),chapterNum:$||1,verseNum:J||1}),m(!1),r("");return}s(o!==k?k:""),m(!D)},[t,e.bookNum,e.chapterNum,o]),P=k=>{k<=0||k>rn(o)||v(o,!0,k)},V=g.useCallback(()=>{Ql.forEach(k=>{const D=n.match(k);if(D){const[$,J=void 0,Y=void 0]=D.slice(1),F=rc($);(ae.isBookIdValid($)||F)&&v(F??$,!0,J?parseInt(J,10):1,Y?parseInt(Y,10):1)}})},[v,n]),U=g.useCallback(k=>{u?(k.key==="ArrowDown"||k.key==="ArrowUp")&&(typeof h<"u"&&h.current!==null?h.current.focus():typeof f<"u"&&f.current!==null&&f.current.focus(),k.preventDefault()):m(!0)},[u]),T=k=>{const{key:D}=k;D==="ArrowRight"||D==="ArrowLeft"||D==="ArrowDown"||D==="ArrowUp"||D==="Enter"||(x.current.dispatchEvent(new KeyboardEvent("keydown",{key:D})),x.current.focus())},_=k=>{const{key:D}=k;if(c===o){if(D==="Enter"){k.preventDefault(),v(o,!0,i);return}let $=0;if(D==="ArrowRight")if(i1)$=-1;else{k.preventDefault();return}else D==="ArrowDown"?$=6:D==="ArrowUp"&&($=-6);i+$<=0||i+$>rn(c)?l(0):$!==0&&(l(i+$),k.preventDefault())}};return g.useEffect(()=>{o===c?o===ae.bookNumberToId(e.bookNum)?l(e.chapterNum):l(1):l(0)},[c,e.bookNum,e.chapterNum,o]),g.useLayoutEffect(()=>{b(u)},[u]),g.useLayoutEffect(()=>{const k=setTimeout(()=>{if(w&&f.current&&h.current){const $=h.current.offsetTop-Zl;f.current.scrollTo({top:$,behavior:"instant"})}},10);return()=>{clearTimeout(k)}},[w]),a.jsx("div",{className:"pr-twp tw-flex",children:a.jsxs(rr,{modal:!1,open:u,onOpenChange:E,children:[a.jsx(ao,{asChild:!0,children:a.jsx(Pl,{ref:x,value:n,handleSearch:R,handleKeyDown:U,handleOnClick:()=>{s(ae.bookNumberToId(e.bookNum)),d(ae.bookNumberToId(e.bookNum)),l(e.chapterNum>0?e.chapterNum:0),m(!0),x.current.focus()},onFocus:()=>{j.current=!0},handleSubmit:V,placeholder:`${ae.bookNumberToEnglishName(e.bookNum)} ${e.chapterNum}:${e.verseNum}`})}),a.jsxs(En,{className:"tw-m-1 tw-overflow-y-auto tw-p-0 tw-font-normal tw-text-foreground/80",style:{width:"233px",maxHeight:"500px",zIndex:"250"},onKeyDown:T,align:"start",ref:f,children:[a.jsx(Kl,{handleSort:()=>console.log("sorting"),handleLocationHistory:()=>console.log("location history"),handleBookmarks:()=>console.log("bookmarks")}),aa.map((k,D)=>S(k).length>0&&a.jsxs("div",{children:[a.jsx(Wt,{className:"tw-font-semibold tw-text-foreground/80",children:Jl[k]}),S(k).map($=>a.jsx("div",{children:a.jsx(Yl,{bookId:$,handleSelectBook:()=>v($,!1),isSelected:o===$,handleHighlightBook:()=>d($),handleKeyDown:_,bookType:k,ref:J=>{o===$&&(h.current=J)},children:a.jsx(Wl,{handleSelectChapter:P,endChapter:rn($),activeChapter:e.bookNum===ae.bookIdToNumber($)?e.chapterNum:0,highlightedChapter:i,handleHighlightedChapter:J=>{l(J)}})})},$)),aa.length-1!==D?a.jsx(jn,{}):void 0]},k))]})]})})}const ws=Xt.cva("pr-twp tw-inline-flex tw-items-center tw-justify-center tw-whitespace-nowrap tw-rounded-md tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-colors focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50",{variants:{variant:{default:"tw-bg-primary tw-text-primary-foreground hover:tw-bg-primary/90",destructive:"tw-bg-destructive tw-text-destructive-foreground hover:tw-bg-destructive/90",outline:"tw-border tw-border-input tw-bg-background hover:tw-bg-accent hover:tw-text-accent-foreground",secondary:"tw-bg-secondary tw-text-secondary-foreground hover:tw-bg-secondary/80",ghost:"hover:tw-bg-accent hover:tw-text-accent-foreground",link:"tw-text-primary tw-underline-offset-4 hover:tw-underline"},size:{default:"tw-h-10 tw-px-4 tw-py-2",sm:"tw-h-9 tw-rounded-md tw-px-3",lg:"tw-h-11 tw-rounded-md tw-px-8",icon:"tw-h-10 tw-w-10"}},defaultVariants:{variant:"default",size:"default"}}),fe=g.forwardRef(({className:e,variant:t,size:n,asChild:r=!1,...o},s)=>{const i=r?Ht.Slot:"button";return a.jsx(i,{className:N(ws({variant:t,size:n,className:e})),ref:s,...o})});fe.displayName="Button";const ac=Xt.cva("tw-text-sm tw-font-medium tw-leading-none peer-disabled:tw-cursor-not-allowed peer-disabled:tw-opacity-70"),qe=g.forwardRef(({className:e,...t},n)=>a.jsx(es.Root,{ref:n,className:N("pr-twp",ac(),e),...t}));qe.displayName=es.Root.displayName;const lo=g.forwardRef(({className:e,...t},n)=>a.jsx(bn.Root,{className:N("pr-twp tw-grid tw-gap-2",e),...t,ref:n}));lo.displayName=bn.Root.displayName;const Yn=g.forwardRef(({className:e,...t},n)=>a.jsx(bn.Item,{ref:n,className:N("pr-twp tw-aspect-square tw-h-4 tw-w-4 tw-rounded-full tw-border tw-border-primary tw-text-primary tw-ring-offset-background focus:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-cursor-not-allowed disabled:tw-opacity-50",e),...t,children:a.jsx(bn.Indicator,{className:"tw-flex tw-items-center tw-justify-center",children:a.jsx(Q.Circle,{className:"tw-h-2.5 tw-w-2.5 tw-fill-current tw-text-current"})})}));Yn.displayName=bn.Item.displayName;const sc=vn.Root,ic=vn.Trigger,fs=g.forwardRef(({className:e,align:t="center",sideOffset:n=4,...r},o)=>a.jsx(vn.Portal,{children:a.jsx(vn.Content,{ref:o,align:t,sideOffset:n,className:N("pr-twp tw-z-50 tw-w-72 tw-rounded-md tw-border tw-bg-popover tw-p-4 tw-text-popover-foreground tw-shadow-md tw-outline-none data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0 data-[state=closed]:tw-zoom-out-95 data-[state=open]:tw-zoom-in-95 data-[side=bottom]:tw-slide-in-from-top-2 data-[side=left]:tw-slide-in-from-right-2 data-[side=right]:tw-slide-in-from-left-2 data-[side=top]:tw-slide-in-from-bottom-2",e),...r})}));fs.displayName=vn.Content.displayName;const lc=be.Portal,ms=g.forwardRef(({className:e,...t},n)=>a.jsx(be.Overlay,{ref:n,className:N("tw-fixed tw-inset-0 tw-z-50 tw-bg-black/80 data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0",e),...t}));ms.displayName=be.Overlay.displayName;const cc=g.forwardRef(({className:e,children:t,...n},r)=>a.jsxs(lc,{children:[a.jsx(ms,{}),a.jsxs(be.Content,{ref:r,className:N("tw-fixed tw-left-[50%] tw-top-[50%] tw-z-50 tw-grid tw-w-full tw-max-w-lg tw-translate-x-[-50%] tw-translate-y-[-50%] tw-gap-4 tw-border tw-bg-background tw-p-6 tw-shadow-lg tw-duration-200 data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0 data-[state=closed]:tw-zoom-out-95 data-[state=open]:tw-zoom-in-95 data-[state=closed]:tw-slide-out-to-left-1/2 data-[state=closed]:tw-slide-out-to-top-[48%] data-[state=open]:tw-slide-in-from-left-1/2 data-[state=open]:tw-slide-in-from-top-[48%] sm:tw-rounded-lg",e),...n,children:[t,a.jsxs(be.Close,{className:"tw-absolute tw-right-4 tw-top-4 tw-rounded-sm tw-opacity-70 tw-ring-offset-background tw-transition-opacity hover:tw-opacity-100 focus:tw-outline-none focus:tw-ring-2 focus:tw-ring-ring focus:tw-ring-offset-2 disabled:tw-pointer-events-none data-[state=open]:tw-bg-accent data-[state=open]:tw-text-muted-foreground",children:[a.jsx(Q.X,{className:"tw-h-4 tw-w-4"}),a.jsx("span",{className:"tw-sr-only",children:"Close"})]})]})]}));cc.displayName=be.Content.displayName;const dc=g.forwardRef(({className:e,...t},n)=>a.jsx(be.Title,{ref:n,className:N("tw-text-lg tw-font-semibold tw-leading-none tw-tracking-tight",e),...t}));dc.displayName=be.Title.displayName;const uc=g.forwardRef(({className:e,...t},n)=>a.jsx(be.Description,{ref:n,className:N("tw-text-sm tw-text-muted-foreground",e),...t}));uc.displayName=be.Description.displayName;const hs=g.forwardRef(({className:e,...t},n)=>a.jsx(Oe.Command,{ref:n,className:N("tw-flex tw-h-full tw-w-full tw-flex-col tw-overflow-hidden tw-rounded-md tw-bg-popover tw-text-popover-foreground",e),...t}));hs.displayName=Oe.Command.displayName;const gs=g.forwardRef(({className:e,...t},n)=>a.jsxs("div",{className:"tw-flex tw-items-center tw-border-b tw-px-3",children:[a.jsx(Q.Search,{className:"tw-me-2 tw-h-4 tw-w-4 tw-shrink-0 tw-opacity-50"}),a.jsx(Oe.Command.Input,{ref:n,className:N("tw-flex tw-h-11 tw-w-full tw-rounded-md tw-bg-transparent tw-py-3 tw-text-sm tw-outline-none placeholder:tw-text-muted-foreground disabled:tw-cursor-not-allowed disabled:tw-opacity-50",e),...t})]}));gs.displayName=Oe.Command.Input.displayName;const bs=g.forwardRef(({className:e,...t},n)=>a.jsx(Oe.Command.List,{ref:n,className:N("tw-max-h-[300px] tw-overflow-y-auto tw-overflow-x-hidden",e),...t}));bs.displayName=Oe.Command.List.displayName;const vs=g.forwardRef((e,t)=>a.jsx(Oe.Command.Empty,{ref:t,className:"tw-py-6 tw-text-center tw-text-sm",...e}));vs.displayName=Oe.Command.Empty.displayName;const pc=g.forwardRef(({className:e,...t},n)=>a.jsx(Oe.Command.Group,{ref:n,className:N("tw-overflow-hidden tw-p-1 tw-text-foreground [&_[cmdk-group-heading]]:tw-px-2 [&_[cmdk-group-heading]]:tw-py-1.5 [&_[cmdk-group-heading]]:tw-text-xs [&_[cmdk-group-heading]]:tw-font-medium [&_[cmdk-group-heading]]:tw-text-muted-foreground",e),...t}));pc.displayName=Oe.Command.Group.displayName;const wc=g.forwardRef(({className:e,...t},n)=>a.jsx(Oe.Command.Separator,{ref:n,className:N("tw--mx-1 tw-h-px tw-bg-border",e),...t}));wc.displayName=Oe.Command.Separator.displayName;const xs=g.forwardRef(({className:e,...t},n)=>a.jsx(Oe.Command.Item,{ref:n,className:N("tw-relative tw-flex tw-cursor-default tw-select-none tw-items-center tw-rounded-sm tw-px-2 tw-py-1.5 tw-text-sm tw-outline-none data-[disabled=true]:tw-pointer-events-none data-[selected=true]:tw-bg-accent data-[selected=true]:tw-text-accent-foreground data-[disabled=true]:tw-opacity-50",e),...t}));xs.displayName=Oe.Command.Item.displayName;function fc(e){return typeof e=="string"?e:typeof e=="number"?e.toString():e.label}function qr({id:e,options:t=[],className:n,value:r,onChange:o=()=>{},getOptionLabel:s=fc,buttonPlaceholder:i="",textPlaceholder:l="",commandEmptyMessage:c="No option found",buttonVariant:d="outline",dir:u="ltr",isDisabled:m=!1,...w}){const[b,x]=g.useState(!1);return a.jsxs(sc,{open:b,onOpenChange:x,...w,children:[a.jsx(ic,{asChild:!0,children:a.jsxs(fe,{variant:d,role:"combobox","aria-expanded":b,id:e,className:N("tw-w-[200px] tw-justify-between",n),disabled:m,children:[a.jsx("span",{className:"tw-overflow-hidden tw-text-ellipsis tw-whitespace-nowrap",children:r?s(r):i}),a.jsx(Q.ChevronsUpDown,{className:"tw-ms-2 tw-h-4 tw-w-4 tw-shrink-0 tw-opacity-50"})]})}),a.jsx(fs,{className:"tw-w-[200px] tw-p-0",dir:u,children:a.jsxs(hs,{children:[a.jsx(gs,{dir:u,placeholder:l,className:"tw-text-inherit"}),a.jsx(vs,{children:c}),a.jsx(bs,{children:t.map(f=>a.jsxs(xs,{value:s(f),onSelect:()=>{o(f),x(!1)},children:[a.jsx(Q.Check,{className:N("tw-me-2 tw-h-4 tw-w-4",{"tw-opacity-0":!r||s(r)!==s(f)})}),s(f)]},s(f)))})]})})]})}function ys({startChapter:e,endChapter:t,handleSelectStartChapter:n,handleSelectEndChapter:r,isDisabled:o=!1,chapterCount:s}){const i=g.useMemo(()=>Array.from({length:s},(d,u)=>u+1),[s]),l=d=>{n(d),d>t&&r(d)},c=d=>{r(d),dd.toString(),value:e},"start chapter"),a.jsx(qe,{htmlFor:"end-chapters-combobox",children:"to"}),a.jsx(qr,{isDisabled:o,onChange:c,className:"tw-ml-2 tw-w-20",options:i,getOptionLabel:d=>d.toString(),value:t},"end chapter")]})}var Ns=(e=>(e.CURRENT_BOOK="current book",e.CHOOSE_BOOKS="choose books",e))(Ns||{});const mc=Object.freeze(["%webView_bookSelector_currentBook%","%webView_bookSelector_choose%","%webView_bookSelector_chooseBooks%"]),Tr=(e,t)=>e[t]??t;function hc({handleBookSelectionModeChange:e,currentBookName:t,onSelectBooks:n,selectedBookIds:r,chapterCount:o,endChapter:s,handleSelectEndChapter:i,startChapter:l,handleSelectStartChapter:c,localizedStrings:d}){const u=Tr(d,"%webView_bookSelector_currentBook%"),m=Tr(d,"%webView_bookSelector_choose%"),w=Tr(d,"%webView_bookSelector_chooseBooks%"),[b,x]=g.useState("current book"),f=h=>{x(h),e(h)};return a.jsx(lo,{className:"pr-twp tw-flex",value:b,onValueChange:h=>f(h),children:a.jsxs("div",{className:"tw-flex tw-w-full tw-flex-col tw-gap-4",children:[a.jsxs("div",{className:"tw-grid tw-grid-cols-[25%,25%,50%]",children:[a.jsxs("div",{className:"tw-flex tw-items-center",children:[a.jsx(Yn,{value:"current book"}),a.jsx(qe,{className:"tw-ml-1",children:u})]}),a.jsx(qe,{className:"tw-flex tw-items-center",children:t}),a.jsx("div",{className:"tw-flex tw-items-center tw-justify-end",children:a.jsx(ys,{isDisabled:b==="choose books",handleSelectStartChapter:c,handleSelectEndChapter:i,chapterCount:o,startChapter:l,endChapter:s})})]}),a.jsxs("div",{className:"tw-grid tw-grid-cols-[25%,50%,25%]",children:[a.jsxs("div",{className:"tw-flex tw-items-center",children:[a.jsx(Yn,{value:"choose books"}),a.jsx(qe,{className:"tw-ml-1",children:w})]}),a.jsx(qe,{className:"tw-flex tw-items-center",children:r.map(h=>ae.bookIdToEnglishName(h)).join(", ")}),a.jsx(fe,{disabled:b==="current book",onClick:()=>n(),children:m})]})]})})}function gc({table:e}){return a.jsxs(rr,{children:[a.jsx(Za.DropdownMenuTrigger,{asChild:!0,children:a.jsxs(fe,{variant:"outline",size:"sm",className:"tw-ml-auto tw-hidden tw-h-8 lg:tw-flex",children:[a.jsx(Q.FilterIcon,{className:"tw-mr-2 tw-h-4 tw-w-4"}),"View"]})}),a.jsxs(En,{align:"end",className:"tw-w-[150px]",children:[a.jsx(Wt,{children:"Toggle columns"}),a.jsx(jn,{}),e.getAllColumns().filter(t=>t.getCanHide()).map(t=>a.jsx(or,{className:"tw-capitalize",checked:t.getIsVisible(),onCheckedChange:n=>t.toggleVisibility(!!n),children:t.id},t.id))]})]})}const At=ge.Root,ks=ge.Group,Bt=ge.Value,bt=g.forwardRef(({className:e,children:t,...n},r)=>a.jsxs(ge.Trigger,{ref:r,className:N("tw-flex tw-h-10 tw-w-full tw-items-center tw-justify-between tw-rounded-md tw-border tw-border-input tw-bg-background tw-px-3 tw-py-2 tw-text-sm tw-ring-offset-background placeholder:tw-text-muted-foreground focus:tw-outline-none focus:tw-ring-2 focus:tw-ring-ring focus:tw-ring-offset-2 disabled:tw-cursor-not-allowed disabled:tw-opacity-50 [&>span]:tw-line-clamp-1",e),...n,children:[t,a.jsx(ge.Icon,{asChild:!0,children:a.jsx(Q.ChevronDown,{className:"tw-h-4 tw-w-4 tw-opacity-50"})})]}));bt.displayName=ge.Trigger.displayName;const co=g.forwardRef(({className:e,...t},n)=>a.jsx(ge.ScrollUpButton,{ref:n,className:N("tw-flex tw-cursor-default tw-items-center tw-justify-center tw-py-1",e),...t,children:a.jsx(Q.ChevronUp,{className:"tw-h-4 tw-w-4"})}));co.displayName=ge.ScrollUpButton.displayName;const uo=g.forwardRef(({className:e,...t},n)=>a.jsx(ge.ScrollDownButton,{ref:n,className:N("tw-flex tw-cursor-default tw-items-center tw-justify-center tw-py-1",e),...t,children:a.jsx(Q.ChevronDown,{className:"tw-h-4 tw-w-4"})}));uo.displayName=ge.ScrollDownButton.displayName;const vt=g.forwardRef(({className:e,children:t,position:n="popper",...r},o)=>a.jsx(ge.Portal,{children:a.jsxs(ge.Content,{ref:o,className:N("pr-twp tw-relative tw-z-50 tw-max-h-96 tw-min-w-[8rem] tw-overflow-hidden tw-rounded-md tw-border tw-bg-popover tw-text-popover-foreground tw-shadow-md data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0 data-[state=closed]:tw-zoom-out-95 data-[state=open]:tw-zoom-in-95 data-[side=bottom]:tw-slide-in-from-top-2 data-[side=left]:tw-slide-in-from-right-2 data-[side=right]:tw-slide-in-from-left-2 data-[side=top]:tw-slide-in-from-bottom-2",n==="popper"&&"data-[side=bottom]:tw-translate-y-1 data-[side=left]:tw--translate-x-1 data-[side=right]:tw-translate-x-1 data-[side=top]:tw--translate-y-1",e),position:n,...r,children:[a.jsx(co,{}),a.jsx(ge.Viewport,{className:N("tw-p-1",n==="popper"&&"tw-h-[var(--radix-select-trigger-height)] tw-w-full tw-min-w-[var(--radix-select-trigger-width)]"),children:t}),a.jsx(uo,{})]})}));vt.displayName=ge.Content.displayName;const Ss=g.forwardRef(({className:e,...t},n)=>a.jsx(ge.Label,{ref:n,className:N("tw-py-1.5 tw-pl-8 tw-pr-2 tw-text-sm tw-font-semibold",e),...t}));Ss.displayName=ge.Label.displayName;const Ae=g.forwardRef(({className:e,children:t,...n},r)=>a.jsxs(ge.Item,{ref:r,className:N("tw-relative tw-flex tw-w-full tw-cursor-default tw-select-none tw-items-center tw-rounded-sm tw-py-1.5 tw-pl-8 tw-pr-2 tw-text-sm tw-outline-none focus:tw-bg-accent focus:tw-text-accent-foreground data-[disabled]:tw-pointer-events-none data-[disabled]:tw-opacity-50",e),...n,children:[a.jsx("span",{className:"tw-absolute tw-left-2 tw-flex tw-h-3.5 tw-w-3.5 tw-items-center tw-justify-center",children:a.jsx(ge.ItemIndicator,{children:a.jsx(Q.Check,{className:"tw-h-4 tw-w-4"})})}),a.jsx(ge.ItemText,{children:t})]}));Ae.displayName=ge.Item.displayName;const Es=g.forwardRef(({className:e,...t},n)=>a.jsx(ge.Separator,{ref:n,className:N("tw--mx-1 tw-my-1 tw-h-px tw-bg-muted",e),...t}));Es.displayName=ge.Separator.displayName;function bc({table:e}){return a.jsx("div",{className:"tw-flex tw-items-center tw-justify-between tw-px-2 tw-pb-3 tw-pt-3",children:a.jsxs("div",{className:"tw-flex tw-items-center tw-space-x-6 lg:tw-space-x-8",children:[a.jsxs("div",{className:"tw-flex-1 tw-text-sm tw-text-muted-foreground",children:[e.getFilteredSelectedRowModel().rows.length," of"," ",e.getFilteredRowModel().rows.length," row(s) selected"]}),a.jsxs("div",{className:"tw-flex tw-items-center tw-space-x-2",children:[a.jsx("p",{className:"tw-text-nowrap tw-text-sm tw-font-medium",children:"Rows per page"}),a.jsxs(At,{value:`${e.getState().pagination.pageSize}`,onValueChange:t=>{e.setPageSize(Number(t))},children:[a.jsx(bt,{className:"tw-h-8 tw-w-[70px]",children:a.jsx(Bt,{placeholder:e.getState().pagination.pageSize})}),a.jsx(vt,{side:"top",children:[10,20,30,40,50].map(t=>a.jsx(Ae,{value:`${t}`,children:t},t))})]})]}),a.jsxs("div",{className:"tw-flex tw-w-[100px] tw-items-center tw-justify-center tw-text-sm tw-font-medium",children:["Page ",e.getState().pagination.pageIndex+1," of ",e.getPageCount()]}),a.jsxs("div",{className:"tw-flex tw-items-center tw-space-x-2",children:[a.jsxs(fe,{variant:"outline",size:"icon",className:"tw-hidden tw-h-8 tw-w-8 tw-p-0 lg:tw-flex",onClick:()=>e.setPageIndex(0),disabled:!e.getCanPreviousPage(),children:[a.jsx("span",{className:"tw-sr-only",children:"Go to first page"}),a.jsx(Q.ArrowLeftIcon,{className:"tw-h-4 tw-w-4"})]}),a.jsxs(fe,{variant:"outline",size:"icon",className:"tw-h-8 tw-w-8 tw-p-0",onClick:()=>e.previousPage(),disabled:!e.getCanPreviousPage(),children:[a.jsx("span",{className:"tw-sr-only",children:"Go to previous page"}),a.jsx(Q.ChevronLeftIcon,{className:"tw-h-4 tw-w-4"})]}),a.jsxs(fe,{variant:"outline",size:"icon",className:"tw-h-8 tw-w-8 tw-p-0",onClick:()=>e.nextPage(),disabled:!e.getCanNextPage(),children:[a.jsx("span",{className:"tw-sr-only",children:"Go to next page"}),a.jsx(Q.ChevronRightIcon,{className:"tw-h-4 tw-w-4"})]}),a.jsxs(fe,{variant:"outline",size:"icon",className:"tw-hidden tw-h-8 tw-w-8 tw-p-0 lg:tw-flex",onClick:()=>e.setPageIndex(e.getPageCount()-1),disabled:!e.getCanNextPage(),children:[a.jsx("span",{className:"tw-sr-only",children:"Go to last page"}),a.jsx(Q.ArrowRightIcon,{className:"tw-h-4 tw-w-4"})]})]})]})})}const Tn=g.forwardRef(({className:e,stickyHeader:t,...n},r)=>a.jsx("div",{className:N("pr-twp tw-relative tw-w-full",{"tw-overflow-auto":!t}),children:a.jsx("table",{ref:r,className:N("tw-w-full tw-caption-bottom tw-text-sm",e),...n})}));Tn.displayName="Table";const Cn=g.forwardRef(({className:e,stickyHeader:t,...n},r)=>a.jsx("thead",{ref:r,className:N({"tw-sticky tw-top-[-1px] tw-bg-background tw-drop-shadow-sm":t},"[&_tr]:tw-border-b",e),...n}));Cn.displayName="TableHeader";const Rn=g.forwardRef(({className:e,...t},n)=>a.jsx("tbody",{ref:n,className:N("[&_tr:last-child]:tw-border-0",e),...t}));Rn.displayName="TableBody";const js=g.forwardRef(({className:e,...t},n)=>a.jsx("tfoot",{ref:n,className:N("tw-border-t tw-bg-muted/50 tw-font-medium [&>tr]:last:tw-border-b-0",e),...t}));js.displayName="TableFooter";const Ze=g.forwardRef(({className:e,...t},n)=>a.jsx("tr",{ref:n,className:N("tw-border-b tw-transition-colors hover:tw-bg-muted/50 data-[state=selected]:tw-bg-muted",e),...t}));Ze.displayName="TableRow";const Vt=g.forwardRef(({className:e,...t},n)=>a.jsx("th",{ref:n,className:N("tw-h-12 tw-px-4 tw-text-start tw-align-middle tw-font-medium tw-text-muted-foreground [&:has([role=checkbox])]:tw-pe-0",e),...t}));Vt.displayName="TableHead";const xt=g.forwardRef(({className:e,...t},n)=>a.jsx("td",{ref:n,className:N("tw-p-4 tw-align-middle [&:has([role=checkbox])]:tw-pe-0",e),...t}));xt.displayName="TableCell";const Ts=g.forwardRef(({className:e,...t},n)=>a.jsx("caption",{ref:n,className:N("tw-mt-4 tw-text-sm tw-text-muted-foreground",e),...t}));Ts.displayName="TableCaption";function Cs({columns:e,data:t,enablePagination:n=!1,showPaginationControls:r=!1,showColumnVisibilityControls:o=!1,stickyHeader:s=!1,onRowClickHandler:i=()=>{}}){var h;const[l,c]=g.useState([]),[d,u]=g.useState([]),[m,w]=g.useState({}),[b,x]=g.useState({}),f=Se.useReactTable({data:t,columns:e,getCoreRowModel:Se.getCoreRowModel(),...n&&{getPaginationRowModel:Se.getPaginationRowModel()},onSortingChange:c,getSortedRowModel:Se.getSortedRowModel(),onColumnFiltersChange:u,getFilteredRowModel:Se.getFilteredRowModel(),onColumnVisibilityChange:w,onRowSelectionChange:x,state:{sorting:l,columnFilters:d,columnVisibility:m,rowSelection:b}});return a.jsxs("div",{className:"pr-twp",children:[o&&a.jsx(gc,{table:f}),a.jsxs(Tn,{stickyHeader:s,children:[a.jsx(Cn,{stickyHeader:s,children:f.getHeaderGroups().map(S=>a.jsx(Ze,{children:S.headers.map(R=>a.jsx(Vt,{children:R.isPlaceholder?void 0:Se.flexRender(R.column.columnDef.header,R.getContext())},R.id))},S.id))}),a.jsx(Rn,{children:(h=f.getRowModel().rows)!=null&&h.length?f.getRowModel().rows.map(S=>a.jsx(Ze,{onClick:()=>i(S,f),"data-state":S.getIsSelected()&&"selected",children:S.getVisibleCells().map(R=>a.jsx(xt,{children:Se.flexRender(R.column.columnDef.cell,R.getContext())},R.id))},S.id)):a.jsx(Ze,{children:a.jsx(xt,{colSpan:e.length,className:"tw-h-24 tw-text-center",children:"No results."})})})]}),n&&a.jsxs("div",{className:"tw-flex tw-items-center tw-justify-end tw-space-x-2 tw-py-4",children:[a.jsx(fe,{variant:"outline",size:"sm",onClick:()=>f.previousPage(),disabled:!f.getCanPreviousPage(),children:"Previous"}),a.jsx(fe,{variant:"outline",size:"sm",onClick:()=>f.nextPage(),disabled:!f.getCanNextPage(),children:"Next"})]}),n&&r&&a.jsx(bc,{table:f})]})}function vc({occurrenceData:e,setScriptureReference:t,localizedStrings:n}){const r=n["%webView_inventory_occurrences_table_header_reference%"],o=n["%webView_inventory_occurrences_table_header_occurrence%"],s=g.useMemo(()=>{const i=[];return e.forEach(l=>{i.some(c=>W.deepEqual(c,l))||i.push(l)}),i},[e]);return a.jsxs(Tn,{stickyHeader:!0,children:[a.jsx(Cn,{stickyHeader:!0,children:a.jsxs(Ze,{children:[a.jsx(Vt,{children:r}),a.jsx(Vt,{children:o})]})}),a.jsx(Rn,{children:s.length>0&&s.map(i=>a.jsxs(Ze,{onClick:()=>{t(i.reference)},children:[a.jsx(xt,{children:`${ae.bookNumberToEnglishName(i.reference.bookNum)} ${i.reference.chapterNum}:${i.reference.verseNum}`}),a.jsx(xt,{children:i.text})]},`${i.reference.bookNum} ${i.reference.chapterNum}:${i.reference.verseNum}-${i.text}`))})]})}const ar=g.forwardRef(({className:e,...t},n)=>a.jsx(Gr.Root,{ref:n,className:N("tw-peer pr-twp tw-h-4 tw-w-4 tw-shrink-0 tw-rounded-sm tw-border tw-border-primary tw-ring-offset-background focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-cursor-not-allowed disabled:tw-opacity-50 data-[state=checked]:tw-bg-primary data-[state=checked]:tw-text-primary-foreground",e),...t,children:a.jsx(Gr.Indicator,{className:N("tw-flex tw-items-center tw-justify-center tw-text-current"),children:a.jsx(Q.Check,{className:"tw-h-4 tw-w-4"})})}));ar.displayName=Gr.Root.displayName;const Rs=e=>e.split(/(?:\r?\n|\r)|(?=(?:\\(?:v|c|id)))/g),Hr=e=>{const t=/^\\[vc]\s+(\d+)/,n=e.match(t);if(n)return+n[1]},Os=e=>{const t=e.match(/^\\id\s+([A-Za-z]+)/);return t?ae.bookIdToNumber(t[1]):0},_s=(e,t,n)=>n.includes(e)?"unapproved":t.includes(e)?"approved":"unknown",Ps=Xt.cva("pr-twp tw-inline-flex tw-items-center tw-justify-center tw-rounded-md tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-colors hover:tw-bg-muted hover:tw-text-muted-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50 data-[state=on]:tw-bg-accent data-[state=on]:tw-text-accent-foreground",{variants:{variant:{default:"tw-bg-transparent",outline:"tw-border tw-border-input tw-bg-transparent hover:tw-bg-accent hover:tw-text-accent-foreground"},size:{default:"tw-h-10 tw-px-3",sm:"tw-h-9 tw-px-2.5",lg:"tw-h-11 tw-px-5"}},defaultVariants:{variant:"default",size:"default"}}),xc=g.forwardRef(({className:e,variant:t,size:n,...r},o)=>a.jsx(ts.Root,{ref:o,className:N(Ps({variant:t,size:n,className:e})),...r}));xc.displayName=ts.Root.displayName;const Is=g.createContext({size:"default",variant:"default"}),po=g.forwardRef(({className:e,variant:t,size:n,children:r,...o},s)=>a.jsx(nr.Root,{ref:s,className:N("pr-twp tw-flex tw-items-center tw-justify-center tw-gap-1",e),...o,children:a.jsx(Is.Provider,{value:{variant:t,size:n},children:r})}));po.displayName=nr.Root.displayName;const fn=g.forwardRef(({className:e,children:t,variant:n,size:r,...o},s)=>{const i=g.useContext(Is);return a.jsx(nr.Item,{ref:s,className:N(Ps({variant:i.variant||n,size:i.size||r}),e),...o,children:t})});fn.displayName=nr.Item.displayName;const sr=e=>e==="asc"?a.jsx(Q.ArrowUpIcon,{className:"tw-ms-2 tw-h-4 tw-w-4"}):e==="desc"?a.jsx(Q.ArrowDownIcon,{className:"tw-ms-2 tw-h-4 tw-w-4"}):a.jsx(Q.ArrowUpDownIcon,{className:"tw-ms-2 tw-h-4 tw-w-4"}),yc=e=>({accessorKey:"item",accessorFn:t=>t.items[0],header:({column:t})=>a.jsxs(fe,{variant:"ghost",onClick:()=>t.toggleSorting(void 0),children:[e,sr(t.getIsSorted())]})}),Nc=(e,t)=>({accessorKey:`item${t}`,accessorFn:n=>n.items[t],header:({column:n})=>a.jsxs(fe,{variant:"ghost",onClick:()=>n.toggleSorting(void 0),children:[e,sr(n.getIsSorted())]})}),kc=e=>({accessorKey:"count",header:({column:t})=>a.jsx("div",{className:"tw-flex tw-justify-end tw-tabular-nums",children:a.jsxs(fe,{variant:"ghost",onClick:()=>t.toggleSorting(void 0),children:[e,sr(t.getIsSorted())]})}),cell:({row:t})=>a.jsx("div",{className:"tw-flex tw-justify-end",children:t.getValue("count")})}),Cr=(e,t,n,r,o,s)=>{let i=[...n];e.forEach(c=>{t==="approved"?i.includes(c)||i.push(c):i=i.filter(d=>d!==c)}),r(i);let l=[...o];e.forEach(c=>{t==="unapproved"?l.includes(c)||l.push(c):l=l.filter(d=>d!==c)}),s(l)},Sc=(e,t,n,r,o)=>({accessorKey:"status",header:({column:s})=>a.jsx("div",{className:"tw-flex tw-justify-center",children:a.jsxs(fe,{variant:"ghost",onClick:()=>s.toggleSorting(void 0),children:[e,sr(s.getIsSorted())]})}),cell:({row:s})=>{const i=s.getValue("status"),l=s.getValue("item");return a.jsxs(po,{value:i,variant:"outline",type:"single",children:[a.jsx(fn,{onClick:()=>Cr([l],"approved",t,n,r,o),value:"approved",children:a.jsx(Q.CircleCheckIcon,{})}),a.jsx(fn,{onClick:()=>Cr([l],"unapproved",t,n,r,o),value:"unapproved",children:a.jsx(Q.CircleXIcon,{})}),a.jsx(fn,{onClick:()=>Cr([l],"unknown",t,n,r,o),value:"unknown",children:a.jsx(Q.CircleHelpIcon,{})})]})}}),Ec=Object.freeze(["%webView_inventory_all%","%webView_inventory_approved%","%webView_inventory_unapproved%","%webView_inventory_unknown%","%webView_inventory_scope_currentBook%","%webView_inventory_scope_chapter%","%webView_inventory_scope_verse%","%webView_inventory_filter_text%","%webView_inventory_show_additional_items%","%webView_inventory_occurrences_table_header_reference%","%webView_inventory_occurrences_table_header_occurrence%"]),jc=(e,t,n)=>{let r=e;return t!=="all"&&(r=r.filter(o=>t==="approved"&&o.status==="approved"||t==="unapproved"&&o.status==="unapproved"||t==="unknown"&&o.status==="unknown")),n!==""&&(r=r.filter(o=>o.items[0].includes(n))),r},Tc=(e,t,n,r,o)=>{if(!e)return[];const s=[];let i=t.bookNum,l=t.chapterNum,c=t.verseNum;return Rs(e).forEach(u=>{u.startsWith("\\id")&&(i=Os(u),l=0,c=0),u.startsWith("\\c")&&(l=Hr(u),c=0),u.startsWith("\\v")&&(c=Hr(u),l===0&&(l=t.chapterNum));let m=o.exec(u)??void 0;for(;m;){const w=[];m.forEach(h=>w.push(h));const b=m.index,x=s.find(h=>W.deepEqual(h.items,w)),f={reference:{bookNum:i!==void 0?i:-1,chapterNum:l!==void 0?l:-1,verseNum:c!==void 0?c:-1},text:W.substring(u,Math.max(0,b-25),Math.min(b+25,u.length))};if(x)x.count+=1,x.occurrences.push(f);else{const h={items:w,count:1,status:_s(w[0],n,r),occurrences:[f]};s.push(h)}m=o.exec(u)??void 0}}),s},Je=(e,t)=>e[t]??t;function Cc({scriptureReference:e,setScriptureReference:t,localizedStrings:n,extractItems:r,additionalItemsLabels:o,approvedItems:s,unapprovedItems:i,text:l,scope:c,onScopeChange:d,columns:u}){const m=Je(n,"%webView_inventory_all%"),w=Je(n,"%webView_inventory_approved%"),b=Je(n,"%webView_inventory_unapproved%"),x=Je(n,"%webView_inventory_unknown%"),f=Je(n,"%webView_inventory_scope_currentBook%"),h=Je(n,"%webView_inventory_scope_chapter%"),S=Je(n,"%webView_inventory_scope_verse%"),R=Je(n,"%webView_inventory_filter_text%"),j=Je(n,"%webView_inventory_show_additional_items%"),[E,v]=g.useState(!1),[P,V]=g.useState("all"),[U,T]=g.useState(""),[_,k]=g.useState([]),D=g.useMemo(()=>l?r instanceof RegExp?Tc(l,e,s,i,r):r(l,e,s,i):[],[l,r,e,s,i]),$=g.useMemo(()=>{if(E)return D;const y=[];return D.forEach(C=>{const z=C.items[0],L=y.find(B=>B.items[0]===z);L?(L.count+=C.count,L.occurrences=L.occurrences.concat(C.occurrences)):y.push({items:[z],count:C.count,occurrences:C.occurrences,status:C.status})}),y},[E,D]),J=g.useMemo(()=>jc($,P,U),[$,P,U]),Y=g.useMemo(()=>{var z,L;if(!E)return u;const y=(z=o==null?void 0:o.tableHeaders)==null?void 0:z.length;if(!y)return u;const C=[];for(let B=0;B{k([])},[J]);const F=(y,C)=>{C.setRowSelection(()=>{const z={};return z[y.index]=!0,z}),k(y.original.items)},te=y=>{if(y==="book"||y==="chapter"||y==="verse")d(y);else throw new Error(`Invalid scope value: ${y}`)},se=y=>{if(y==="all"||y==="approved"||y==="unapproved"||y==="unknown")V(y);else throw new Error(`Invalid status filter value: ${y}`)},oe=g.useMemo(()=>{if($.length===0||_.length===0)return[];const y=$.filter(C=>W.deepEqual(E?C.items:[C.items[0]],_));if(y.length>1)throw new Error("Selected item is not unique");return y[0].occurrences},[_,E,$]);return a.jsxs("div",{className:"pr-twp tw-flex tw-h-full tw-flex-col",children:[a.jsxs("div",{className:"tw-flex tw-items-stretch",children:[a.jsxs(At,{onValueChange:y=>se(y),defaultValue:P,children:[a.jsx(bt,{className:"tw-m-1",children:a.jsx(Bt,{placeholder:"Select filter"})}),a.jsxs(vt,{children:[a.jsx(Ae,{value:"all",children:m}),a.jsx(Ae,{value:"approved",children:w}),a.jsx(Ae,{value:"unapproved",children:b}),a.jsx(Ae,{value:"unknown",children:x})]})]}),a.jsxs(At,{onValueChange:y=>te(y),defaultValue:c,children:[a.jsx(bt,{className:"tw-m-1",children:a.jsx(Bt,{placeholder:"Select scope"})}),a.jsxs(vt,{children:[a.jsx(Ae,{value:"book",children:f}),a.jsx(Ae,{value:"chapter",children:h}),a.jsx(Ae,{value:"verse",children:S})]})]}),a.jsx(St,{className:"tw-m-1 tw-rounded-md tw-border",placeholder:R,value:U,onChange:y=>{T(y.target.value)}}),o&&a.jsxs("div",{className:"tw-m-1 tw-flex tw-items-center tw-rounded-md tw-border",children:[a.jsx(ar,{className:"tw-m-1",checked:E,onCheckedChange:y=>{k([]),v(y)}}),a.jsx(qe,{className:"tw-m-1 tw-flex-shrink-0 tw-whitespace-nowrap",children:(o==null?void 0:o.checkboxText)??j})]})]}),a.jsx("div",{className:"tw-m-1 tw-flex-1 tw-overflow-auto tw-rounded-md tw-border",children:a.jsx(Cs,{columns:Y,data:J,onRowClickHandler:F,stickyHeader:!0})}),oe.length>0&&a.jsx("div",{className:"tw-m-1 tw-flex-1 tw-overflow-auto tw-rounded-md tw-border",children:a.jsx(vc,{occurrenceData:oe,setScriptureReference:t,localizedStrings:n})})]})}function Ms({onSearch:e,placeholder:t,isFullWidth:n}){const[r,o]=g.useState(""),s=i=>{o(i),e(i)};return a.jsx(St,{className:N("tw-flex tw-h-10 tw-rounded-md tw-border tw-border-input tw-bg-background tw-px-3 tw-py-2 tw-text-sm tw-ring-offset-background file:tw-border-0 file:tw-bg-transparent file:tw-text-sm file:tw-font-medium placeholder:tw-text-muted-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-[color:hsl(240,5%,64.9%)] focus-visible:tw-ring-offset-2 disabled:tw-cursor-not-allowed disabled:tw-opacity-50",{"tw-w-full":n}),placeholder:t,value:r,onChange:i=>s(i.target.value)})}const wo=g.forwardRef(({className:e,...t},n)=>a.jsx(_e.Root,{orientation:"vertical",ref:n,className:N("tw-flex tw-gap-1 tw-rounded-md tw-text-muted-foreground",e),...t}));wo.displayName=_e.List.displayName;const fo=g.forwardRef(({className:e,...t},n)=>a.jsx(_e.List,{ref:n,className:N("tw-flex-fit tw-mlk-items-center tw-w-[124px] tw-justify-center tw-rounded-md tw-bg-muted tw-p-1 tw-text-muted-foreground",e),...t}));fo.displayName=_e.List.displayName;const $s=g.forwardRef(({className:e,...t},n)=>a.jsx(_e.Trigger,{ref:n,...t,className:N("overflow-clip tw-inline-flex tw-w-[116px] tw-cursor-pointer tw-items-center tw-justify-center tw-break-words tw-rounded-sm tw-border-0 tw-bg-muted tw-px-3 tw-py-1.5 tw-text-sm tw-font-medium tw-text-inherit tw-ring-offset-background tw-transition-all hover:tw-text-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50 data-[state=active]:tw-bg-background data-[state=active]:tw-text-foreground data-[state=active]:tw-shadow-sm",e)})),mo=g.forwardRef(({className:e,...t},n)=>a.jsx(_e.Content,{ref:n,className:N("tw-ms-5 tw-flex-grow tw-text-foreground tw-ring-offset-background focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2",e),...t}));mo.displayName=_e.Content.displayName;function Rc({tabList:e,onSearch:t,searchPlaceholder:n,headerTitle:r,isSearchBarFullWidth:o=!1,direction:s="ltr"}){return a.jsxs("div",{className:"pr-twp",children:[a.jsxs("div",{className:"tw-sticky tw-top-0 tw-space-y-2 tw-pb-2",children:[r?a.jsx("h1",{children:r}):"",a.jsx(Ms,{isFullWidth:o,onSearch:t,placeholder:n})]}),a.jsxs(wo,{dir:s,children:[a.jsx(fo,{children:e.map(i=>a.jsx($s,{value:i.value,children:i.value},i.key))}),e.map(i=>a.jsx(mo,{value:i.value,children:i.content},i.key))]})]})}const ir=g.forwardRef(({className:e,orientation:t="horizontal",decorative:n=!0,...r},o)=>a.jsx(ns.Root,{ref:o,decorative:n,orientation:t,className:N("pr-twp tw-shrink-0 tw-bg-border",t==="horizontal"?"tw-h-[1px] tw-w-full":"tw-h-full tw-w-[1px]",e),...r}));ir.displayName=ns.Root.displayName;const Oc=be.Root,_c=be.Portal,Ds=M.forwardRef(({className:e,...t},n)=>a.jsx(be.Overlay,{className:N("tw-fixed tw-inset-0 tw-z-50 tw-bg-black/80 data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0",e),...t,ref:n}));Ds.displayName=be.Overlay.displayName;const Pc=Xt.cva("pr-twp tw-fixed tw-z-50 tw-gap-4 tw-bg-background tw-p-6 tw-shadow-lg tw-transition tw-ease-in-out data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-duration-300 data-[state=open]:tw-duration-500",{variants:{side:{top:"tw-inset-x-0 tw-top-0 tw-border-b data-[state=closed]:tw-slide-out-to-top data-[state=open]:tw-slide-in-from-top",bottom:"tw-inset-x-0 tw-bottom-0 tw-border-t data-[state=closed]:tw-slide-out-to-bottom data-[state=open]:tw-slide-in-from-bottom",left:"tw-inset-y-0 tw-left-0 tw-h-full tw-w-3/4 tw-border-r data-[state=closed]:tw-slide-out-to-left data-[state=open]:tw-slide-in-from-left sm:tw-max-w-sm",right:"tw-inset-y-0 tw-right-0 tw-h-full tw-w-3/4 tw- tw-border-l data-[state=closed]:tw-slide-out-to-right data-[state=open]:tw-slide-in-from-right sm:tw-max-w-sm"}},defaultVariants:{side:"right"}}),As=M.forwardRef(({side:e="right",className:t,children:n,...r},o)=>a.jsxs(_c,{children:[a.jsx(Ds,{}),a.jsxs(be.Content,{ref:o,className:N(Pc({side:e}),t),...r,children:[n,a.jsxs(be.Close,{className:"tw-absolute tw-right-4 tw-top-4 tw-rounded-sm tw-opacity-70 tw-ring-offset-background tw-transition-opacity hover:tw-opacity-100 focus:tw-outline-none focus:tw-ring-2 focus:tw-ring-ring focus:tw-ring-offset-2 disabled:tw-pointer-events-none data-[state=open]:tw-bg-secondary",children:[a.jsx(Q.X,{className:"tw-h-4 tw-w-4"}),a.jsx("span",{className:"tw-sr-only",children:"Close"})]})]})]}));As.displayName=be.Content.displayName;const Ic=M.forwardRef(({className:e,...t},n)=>a.jsx(be.Title,{ref:n,className:N("tw-text-lg tw-font-semibold tw-text-foreground",e),...t}));Ic.displayName=be.Title.displayName;const Mc=M.forwardRef(({className:e,...t},n)=>a.jsx(be.Description,{ref:n,className:N("tw-text-sm tw-text-muted-foreground",e),...t}));Mc.displayName=be.Description.displayName;function sa({className:e,...t}){return a.jsx("div",{className:N("pr-twp tw-animate-pulse tw-rounded-md tw-bg-muted",e),...t})}const $c=Sn.Provider,Dc=Sn.Root,Ac=Sn.Trigger,Bs=g.forwardRef(({className:e,sideOffset:t=4,...n},r)=>a.jsx(Sn.Content,{ref:r,sideOffset:t,className:N("pr-twp tw-z-50 tw-overflow-hidden tw-rounded-md tw-border tw-bg-popover tw-px-3 tw-py-1.5 tw-text-sm tw-text-popover-foreground tw-shadow-md tw-animate-in tw-fade-in-0 tw-zoom-in-95 data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=closed]:tw-zoom-out-95 data-[side=bottom]:tw-slide-in-from-top-2 data-[side=left]:tw-slide-in-from-right-2 data-[side=right]:tw-slide-in-from-left-2 data-[side=top]:tw-slide-in-from-bottom-2",e),...n}));Bs.displayName=Sn.Content.displayName;const Rr=768;function Bc(){const[e,t]=M.useState(void 0);return M.useEffect(()=>{const n=window.matchMedia(`(max-width: ${Rr-1}px)`),r=()=>{t(window.innerWidthn.removeEventListener("change",r)},[]),!!e}const Vc="sidebar:state",zc=60*60*24*7,Lc="16rem",Fc="18rem",Gc="3rem",Uc="b",Vs=g.createContext(void 0);function lr(){const e=g.useContext(Vs);if(!e)throw new Error("useSidebar must be used within a SidebarProvider.");return e}const zs=g.forwardRef(({defaultOpen:e=!0,open:t,onOpenChange:n,className:r,style:o,children:s,...i},l)=>{const c=Bc(),[d,u]=g.useState(!1),[m,w]=g.useState(e),b=t??m,x=g.useCallback(R=>{const j=typeof R=="function"?R(b):R;n?n(j):w(j),document.cookie=`${Vc}=${j}; path=/; max-age=${zc}`},[n,b]),f=g.useCallback(()=>c?u(R=>!R):x(R=>!R),[c,x,u]);g.useEffect(()=>{const R=j=>{j.key===Uc&&(j.metaKey||j.ctrlKey)&&(j.preventDefault(),f())};return window.addEventListener("keydown",R),()=>window.removeEventListener("keydown",R)},[f]);const h=b?"expanded":"collapsed",S=g.useMemo(()=>({state:h,open:b,setOpen:x,isMobile:c,openMobile:d,setOpenMobile:u,toggleSidebar:f}),[h,b,x,c,d,u,f]);return a.jsx(Vs.Provider,{value:S,children:a.jsx($c,{delayDuration:0,children:a.jsx("div",{style:{"--sidebar-width":Lc,"--sidebar-width-icon":Gc,...o},className:N("tw-group/sidebar-wrapper pr-twp tw-flex tw-min-h-svh tw-w-full has-[[data-variant=inset]]:tw-bg-sidebar",r),ref:l,...i,children:s})})})});zs.displayName="SidebarProvider";const Ls=g.forwardRef(({side:e="left",variant:t="sidebar",collapsible:n="offcanvas",className:r,children:o,...s},i)=>{const{isMobile:l,state:c,openMobile:d,setOpenMobile:u}=lr();return n==="none"?a.jsx("div",{className:N("tw-flex tw-h-full tw-w-[--sidebar-width] tw-flex-col tw-bg-sidebar tw-text-sidebar-foreground",r),ref:i,...s,children:o}):l?a.jsx(Oc,{open:d,onOpenChange:u,...s,children:a.jsx(As,{"data-sidebar":"sidebar","data-mobile":"true",className:"tw-w-[--sidebar-width] tw-bg-sidebar tw-p-0 tw-text-sidebar-foreground [&>button]:tw-hidden",style:{"--sidebar-width":Fc},side:e,children:a.jsx("div",{className:"tw-flex tw-h-full tw-w-full tw-flex-col",children:o})})}):a.jsxs("div",{ref:i,className:"tw-group tw-peer tw-hidden tw-text-sidebar-foreground md:tw-block","data-state":c,"data-collapsible":c==="collapsed"?n:"","data-variant":t,"data-side":e,children:[a.jsx("div",{className:N("tw-relative tw-h-svh tw-w-[--sidebar-width] tw-bg-transparent tw-transition-[width] tw-duration-200 tw-ease-linear","group-data-[collapsible=offcanvas]:tw-w-0","group-data-[side=right]:tw-rotate-180",t==="floating"||t==="inset"?"group-data-[collapsible=icon]:tw-w-[calc(var(--sidebar-width-icon)_+_theme(spacing.4))]":"group-data-[collapsible=icon]:tw-w-[--sidebar-width-icon]")}),a.jsx("div",{className:N("tw-absolute tw-inset-y-0 tw-z-10 tw-hidden tw-h-svh tw-w-[--sidebar-width] tw-transition-[left,right,width] tw-duration-200 tw-ease-linear md:tw-flex",e==="left"?"tw-left-0 group-data-[collapsible=offcanvas]:tw-left-[calc(var(--sidebar-width)*-1)]":"tw-right-0 group-data-[collapsible=offcanvas]:tw-right-[calc(var(--sidebar-width)*-1)]",t==="floating"||t==="inset"?"tw-p-2 group-data-[collapsible=icon]:tw-w-[calc(var(--sidebar-width-icon)_+_theme(spacing.4)_+2px)]":"group-data-[collapsible=icon]:tw-w-[--sidebar-width-icon] group-data-[side=left]:tw-border-r group-data-[side=right]:tw-border-l",r),...s,children:a.jsx("div",{"data-sidebar":"sidebar",className:"tw-flex tw-h-full tw-w-full tw-flex-col tw-bg-sidebar group-data-[variant=floating]:tw-rounded-lg group-data-[variant=floating]:tw-border group-data-[variant=floating]:tw-border-sidebar-border group-data-[variant=floating]:tw-shadow",children:o})})]})});Ls.displayName="Sidebar";const qc=g.forwardRef(({className:e,onClick:t,...n},r)=>{const{toggleSidebar:o}=lr();return a.jsxs(fe,{ref:r,"data-sidebar":"trigger",variant:"ghost",size:"icon",className:N("tw-h-7 tw-w-7",e),onClick:s=>{t==null||t(s),o()},...n,children:[a.jsx(Q.PanelLeft,{}),a.jsx("span",{className:"tw-sr-only",children:"Toggle Sidebar"})]})});qc.displayName="SidebarTrigger";const Hc=g.forwardRef(({className:e,...t},n)=>{const{toggleSidebar:r}=lr();return a.jsx("button",{type:"button",ref:n,"data-sidebar":"rail","aria-label":"Toggle Sidebar",tabIndex:-1,onClick:r,title:"Toggle Sidebar",className:N("tw-absolute tw-inset-y-0 tw-z-20 tw-hidden tw-w-4 tw--translate-x-1/2 tw-transition-all tw-ease-linear after:tw-absolute after:tw-inset-y-0 after:tw-left-1/2 after:tw-w-[2px] hover:after:tw-bg-sidebar-border group-data-[side=left]:tw--right-4 group-data-[side=right]:tw-left-0 sm:tw-flex","[[data-side=left]_&]:tw-cursor-w-resize [[data-side=right]_&]:tw-cursor-e-resize","[[data-side=left][data-state=collapsed]_&]:tw-cursor-e-resize [[data-side=right][data-state=collapsed]_&]:tw-cursor-w-resize","group-data-[collapsible=offcanvas]:tw-translate-x-0 group-data-[collapsible=offcanvas]:after:tw-left-full group-data-[collapsible=offcanvas]:hover:tw-bg-sidebar","[[data-side=left][data-collapsible=offcanvas]_&]:tw--right-2","[[data-side=right][data-collapsible=offcanvas]_&]:tw--left-2",e),...t})});Hc.displayName="SidebarRail";const Fs=g.forwardRef(({className:e,...t},n)=>a.jsx("main",{ref:n,className:N("tw-relative tw-flex tw-min-h-svh tw-flex-1 tw-flex-col tw-bg-background","peer-data-[variant=inset]:tw-min-h-[calc(100svh-theme(spacing.4))] md:peer-data-[variant=inset]:tw-m-2 md:peer-data-[state=collapsed]:peer-data-[variant=inset]:tw-ml-2 md:peer-data-[variant=inset]:tw-ml-0 md:peer-data-[variant=inset]:tw-rounded-xl md:peer-data-[variant=inset]:tw-shadow",e),...t}));Fs.displayName="SidebarInset";const Xc=g.forwardRef(({className:e,...t},n)=>a.jsx(St,{ref:n,"data-sidebar":"input",className:N("tw-h-8 tw-w-full tw-bg-background tw-shadow-none focus-visible:tw-ring-2 focus-visible:tw-ring-sidebar-ring",e),...t}));Xc.displayName="SidebarInput";const Yc=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,"data-sidebar":"header",className:N("tw-flex tw-flex-col tw-gap-2 tw-p-2",e),...t}));Yc.displayName="SidebarHeader";const Wc=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,"data-sidebar":"footer",className:N("tw-flex tw-flex-col tw-gap-2 tw-p-2",e),...t}));Wc.displayName="SidebarFooter";const Kc=g.forwardRef(({className:e,...t},n)=>a.jsx(ir,{ref:n,"data-sidebar":"separator",className:N("tw-mx-2 tw-w-auto tw-bg-sidebar-border",e),...t}));Kc.displayName="SidebarSeparator";const Gs=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,"data-sidebar":"content",className:N("tw-flex tw-min-h-0 tw-flex-1 tw-flex-col tw-gap-2 tw-overflow-auto group-data-[collapsible=icon]:tw-overflow-hidden",e),...t}));Gs.displayName="SidebarContent";const Us=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,"data-sidebar":"group",className:N("tw-relative tw-flex tw-w-full tw-min-w-0 tw-flex-col tw-p-2",e),...t}));Us.displayName="SidebarGroup";const qs=g.forwardRef(({className:e,asChild:t=!1,...n},r)=>{const o=t?Ht.Slot:"div";return a.jsx(o,{ref:r,"data-sidebar":"group-label",className:N("tw-flex tw-h-8 tw-shrink-0 tw-items-center tw-rounded-md tw-px-2 tw-text-xs tw-font-medium tw-text-sidebar-foreground/70 tw-outline-none tw-ring-sidebar-ring tw-transition-[margin,opa] tw-duration-200 tw-ease-linear focus-visible:tw-ring-2 [&>svg]:tw-size-4 [&>svg]:tw-shrink-0","group-data-[collapsible=icon]:tw--mt-8 group-data-[collapsible=icon]:tw-opacity-0",e),...n})});qs.displayName="SidebarGroupLabel";const Jc=g.forwardRef(({className:e,asChild:t=!1,...n},r)=>{const o=t?Ht.Slot:"button";return a.jsx(o,{ref:r,"data-sidebar":"group-action",className:N("tw-absolute tw-right-3 tw-top-3.5 tw-flex tw-aspect-square tw-w-5 tw-items-center tw-justify-center tw-rounded-md tw-p-0 tw-text-sidebar-foreground tw-outline-none tw-ring-sidebar-ring tw-transition-transform hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground focus-visible:tw-ring-2 [&>svg]:tw-size-4 [&>svg]:tw-shrink-0","after:tw-absolute after:tw--inset-2 after:md:tw-hidden","group-data-[collapsible=icon]:tw-hidden",e),...n})});Jc.displayName="SidebarGroupAction";const Hs=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,"data-sidebar":"group-content",className:N("tw-w-full tw-text-sm",e),...t}));Hs.displayName="SidebarGroupContent";const Xs=g.forwardRef(({className:e,...t},n)=>a.jsx("ul",{ref:n,"data-sidebar":"menu",className:N("tw-flex tw-w-full tw-min-w-0 tw-flex-col tw-gap-1",e),...t}));Xs.displayName="SidebarMenu";const Ys=g.forwardRef(({className:e,...t},n)=>a.jsx("li",{ref:n,"data-sidebar":"menu-item",className:N("tw-group/menu-item tw-relative",e),...t}));Ys.displayName="SidebarMenuItem";const Zc=Xt.cva("tw-peer/menu-button tw-flex tw-w-full tw-items-center tw-gap-2 tw-overflow-hidden tw-rounded-md tw-p-2 tw-text-left tw-text-sm tw-outline-none tw-ring-sidebar-ring tw-transition-[width,height,padding] hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground focus-visible:tw-ring-2 active:tw-bg-sidebar-accent active:tw-text-sidebar-accent-foreground disabled:tw-pointer-events-none disabled:tw-opacity-50 tw-group-has-[[data-sidebar=menu-action]]/menu-item:pr-8 aria-disabled:tw-pointer-events-none aria-disabled:tw-opacity-50 data-[active=true]:tw-bg-sidebar-accent data-[active=true]:tw-font-medium data-[active=true]:tw-text-sidebar-accent-foreground data-[state=open]:hover:tw-bg-sidebar-accent data-[state=open]:hover:tw-text-sidebar-accent-foreground group-data-[collapsible=icon]:tw-!size-8 group-data-[collapsible=icon]:tw-!p-2 [&>span:last-child]:tw-truncate [&>svg]:tw-size-4 [&>svg]:tw-shrink-0",{variants:{variant:{default:"hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground",outline:"tw-bg-background tw-shadow-[0_0_0_1px_hsl(var(--sidebar-border))] hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground hover:tw-shadow-[0_0_0_1px_hsl(var(--sidebar-accent))]"},size:{default:"tw-h-8 tw-text-sm",sm:"tw-h-7 tw-text-xs",lg:"tw-h-12 tw-text-sm group-data-[collapsible=icon]:tw-!p-0"}},defaultVariants:{variant:"default",size:"default"}}),Ws=g.forwardRef(({asChild:e=!1,isActive:t=!1,variant:n="default",size:r="default",tooltip:o,className:s,...i},l)=>{const c=e?Ht.Slot:"button",{isMobile:d,state:u}=lr(),m=a.jsx(c,{ref:l,"data-sidebar":"menu-button","data-size":r,"data-active":t,className:N(Zc({variant:n,size:r}),s),...i});return o?(typeof o=="string"&&(o={children:o}),a.jsxs(Dc,{children:[a.jsx(Ac,{asChild:!0,children:m}),a.jsx(Bs,{side:"right",align:"center",hidden:u!=="collapsed"||d,...o})]})):m});Ws.displayName="SidebarMenuButton";const Qc=g.forwardRef(({className:e,asChild:t=!1,showOnHover:n=!1,...r},o)=>{const s=t?Ht.Slot:"button";return a.jsx(s,{ref:o,"data-sidebar":"menu-action",className:N("tw-peer-hover/menu-button:text-sidebar-accent-foreground tw-absolute tw-right-1 tw-top-1.5 tw-flex tw-aspect-square tw-w-5 tw-items-center tw-justify-center tw-rounded-md tw-p-0 tw-text-sidebar-foreground tw-outline-none tw-ring-sidebar-ring tw-transition-transform hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground focus-visible:tw-ring-2 [&>svg]:tw-size-4 [&>svg]:tw-shrink-0","after:tw-absolute after:tw--inset-2 after:md:tw-hidden","tw-peer-data-[size=sm]/menu-button:top-1","tw-peer-data-[size=default]/menu-button:top-1.5","tw-peer-data-[size=lg]/menu-button:top-2.5","group-data-[collapsible=icon]:tw-hidden",n&&"tw-group-focus-within/menu-item:opacity-100 tw-group-hover/menu-item:opacity-100 tw-peer-data-[active=true]/menu-button:text-sidebar-accent-foreground data-[state=open]:tw-opacity-100 md:tw-opacity-0",e),...r})});Qc.displayName="SidebarMenuAction";const ed=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,"data-sidebar":"menu-badge",className:N("tw-pointer-events-none tw-absolute tw-right-1 tw-flex tw-h-5 tw-min-w-5 tw-select-none tw-items-center tw-justify-center tw-rounded-md tw-px-1 tw-text-xs tw-font-medium tw-tabular-nums tw-text-sidebar-foreground","tw-peer-hover/menu-button:text-sidebar-accent-foreground tw-peer-data-[active=true]/menu-button:text-sidebar-accent-foreground","tw-peer-data-[size=sm]/menu-button:top-1","tw-peer-data-[size=default]/menu-button:top-1.5","tw-peer-data-[size=lg]/menu-button:top-2.5","group-data-[collapsible=icon]:tw-hidden",e),...t}));ed.displayName="SidebarMenuBadge";const td=g.forwardRef(({className:e,showIcon:t=!1,...n},r)=>{const o=g.useMemo(()=>`${Math.floor(Math.random()*40)+50}%`,[]);return a.jsxs("div",{ref:r,"data-sidebar":"menu-skeleton",className:N("tw-flex tw-h-8 tw-items-center tw-gap-2 tw-rounded-md tw-px-2",e),...n,children:[t&&a.jsx(sa,{className:"tw-size-4 tw-rounded-md","data-sidebar":"menu-skeleton-icon"}),a.jsx(sa,{className:"tw-h-4 tw-max-w-[--skeleton-width] tw-flex-1","data-sidebar":"menu-skeleton-text",style:{"--skeleton-width":o}})]})});td.displayName="SidebarMenuSkeleton";const nd=g.forwardRef(({className:e,...t},n)=>a.jsx("ul",{ref:n,"data-sidebar":"menu-sub",className:N("tw-mx-3.5 tw-flex tw-min-w-0 tw-translate-x-px tw-flex-col tw-gap-1 tw-border-l tw-border-sidebar-border tw-px-2.5 tw-py-0.5","group-data-[collapsible=icon]:tw-hidden",e),...t}));nd.displayName="SidebarMenuSub";const rd=g.forwardRef(({...e},t)=>a.jsx("li",{ref:t,...e}));rd.displayName="SidebarMenuSubItem";const od=g.forwardRef(({asChild:e=!1,size:t="md",isActive:n,className:r,...o},s)=>{const i=e?Ht.Slot:"a";return a.jsx(i,{ref:s,"data-sidebar":"menu-sub-button","data-size":t,"data-active":n,className:N("tw-flex tw-h-7 tw-min-w-0 tw--translate-x-px tw-items-center tw-gap-2 tw-overflow-hidden tw-rounded-md tw-px-2 tw-text-sidebar-foreground tw-outline-none tw-ring-sidebar-ring hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground focus-visible:tw-ring-2 active:tw-bg-sidebar-accent active:tw-text-sidebar-accent-foreground disabled:tw-pointer-events-none disabled:tw-opacity-50 aria-disabled:tw-pointer-events-none aria-disabled:tw-opacity-50 [&>span:last-child]:tw-truncate [&>svg]:tw-size-4 [&>svg]:tw-shrink-0 [&>svg]:tw-text-sidebar-accent-foreground","data-[active=true]:tw-bg-sidebar-accent data-[active=true]:tw-text-sidebar-accent-foreground",t==="sm"&&"tw-text-xs",t==="md"&&"tw-text-sm","group-data-[collapsible=icon]:tw-hidden",r),...o})});od.displayName="SidebarMenuSubButton";function Ks({id:e,extensionLabels:t,handleSelectSidebarItem:n}){const[r,o]=g.useState(),s=(i,l)=>{o(i),n(i,l)};return a.jsx(Ls,{id:e,collapsible:"offcanvas",variant:"sidebar",children:a.jsx(Gs,{children:a.jsxs(Us,{children:[a.jsx(qs,{children:"Extensions"}),a.jsx(Hs,{children:a.jsx(Xs,{children:t.map(i=>a.jsx(Ys,{children:a.jsx(Ws,{onClick:()=>s(i,!1),isActive:i===r,children:i})},i))})})]})})})}function ad({direction:e="ltr",extensionLabels:t,children:n,handleSelectSidebarItem:r}){return a.jsxs(zs,{dir:e,children:[a.jsx(Ks,{extensionLabels:t,handleSelectSidebarItem:r}),a.jsx(Fs,{children:n})]})}const rt="scrBook",sd="scrRef",pt="source",id="details",ld="Scripture Reference",cd="Scripture Book",Js="Type",dd="Details";function ud(e,t){const n=t??!1;return[{accessorFn:r=>`${ae.bookNumberToId(r.start.bookNum)} ${r.start.chapterNum}:${r.start.verseNum}`,id:rt,header:(e==null?void 0:e.scriptureReferenceColumnName)??ld,cell:r=>{const o=r.row.original;return r.row.getIsGrouped()?ae.bookNumberToEnglishName(o.start.bookNum):r.row.groupingColumnId===rt?W.formatScrRef(o.start):void 0},getGroupingValue:r=>r.start.bookNum,sortingFn:(r,o)=>W.compareScrRefs(r.original.start,o.original.start),enableGrouping:!0},{accessorFn:r=>W.formatScrRef(r.start),id:sd,header:void 0,cell:r=>{const o=r.row.original;return r.row.getIsGrouped()?void 0:W.formatScrRef(o.start)},sortingFn:(r,o)=>W.compareScrRefs(r.original.start,o.original.start),enableGrouping:!1},{accessorFn:r=>r.source.displayName,id:pt,header:n?(e==null?void 0:e.typeColumnName)??Js:void 0,cell:r=>n||r.row.getIsGrouped()?r.getValue():void 0,getGroupingValue:r=>r.source.id,sortingFn:(r,o)=>r.original.source.displayName.localeCompare(o.original.source.displayName),enableGrouping:!0},{accessorFn:r=>r.detail,id,header:(e==null?void 0:e.detailsColumnName)??dd,cell:r=>r.getValue(),enableGrouping:!1}]}const pd=e=>{if(!("offset"in e.start))throw new Error("No offset available in range start");if(e.end&&!("offset"in e.end))throw new Error("No offset available in range end");const{offset:t}=e.start;let n=0;return e.end&&({offset:n}=e.end),!e.end||W.compareScrRefs(e.start,e.end)===0?`${W.scrRefToBBBCCCVVV(e.start)}+${t}`:`${W.scrRefToBBBCCCVVV(e.start)}+${t}-${W.scrRefToBBBCCCVVV(e.end)}+${n}`},ia=e=>`${pd({start:e.start,end:e.end})} ${e.source.displayName} ${e.detail}`;function wd({sources:e,showColumnHeaders:t=!1,showSourceColumn:n=!1,scriptureReferenceColumnName:r,scriptureBookGroupName:o,typeColumnName:s,detailsColumnName:i,onRowSelected:l,direction:c="ltr"}){const[d,u]=g.useState([]),[m,w]=g.useState([{id:rt,desc:!1}]),[b,x]=g.useState({}),f=g.useMemo(()=>e.flatMap(T=>T.data.map(_=>({..._,source:T.source}))),[e]),h=g.useMemo(()=>ud({scriptureReferenceColumnName:r,typeColumnName:s,detailsColumnName:i},n),[r,s,i,n]);g.useEffect(()=>{d.includes(pt)?w([{id:pt,desc:!1},{id:rt,desc:!1}]):w([{id:rt,desc:!1}])},[d]);const S=Se.useReactTable({data:f,columns:h,state:{grouping:d,sorting:m,rowSelection:b},onGroupingChange:u,onSortingChange:w,onRowSelectionChange:x,getExpandedRowModel:Se.getExpandedRowModel(),getGroupedRowModel:Se.getGroupedRowModel(),getCoreRowModel:Se.getCoreRowModel(),getSortedRowModel:Se.getSortedRowModel(),getRowId:ia,autoResetExpanded:!1,enableMultiRowSelection:!1,enableSubRowSelection:!1});g.useEffect(()=>{if(l){const T=S.getSelectedRowModel().rowsById,_=Object.keys(T);if(_.length===1){const k=f.find(D=>ia(D)===_[0])||void 0;k&&l(k)}}},[b,f,l,S]);const R=o??cd,j=s??Js,E=[{label:"No Grouping",value:[]},{label:`Group by ${R}`,value:[rt]},{label:`Group by ${j}`,value:[pt]},{label:`Group by ${R} and ${j}`,value:[rt,pt]},{label:`Group by ${j} and ${R}`,value:[pt,rt]}],v=T=>{u(JSON.parse(T))},P=(T,_)=>{!T.getIsGrouped()&&!T.getIsSelected()&&T.getToggleSelectedHandler()(_)},V=(T,_)=>T.getIsGrouped()?"":N("banded-row",_%2===0?"even":"odd"),U=(T,_,k)=>{if(!((T==null?void 0:T.length)===0||_.depth{v(T)},children:[a.jsx(bt,{className:"tw-mb-1 tw-mt-2",children:a.jsx(Bt,{})}),a.jsx(vt,{position:"item-aligned",children:a.jsx(ks,{children:E.map(T=>a.jsx(Ae,{value:JSON.stringify(T.value),children:T.label},T.label))})})]}),a.jsxs(Tn,{className:"tw-relative tw-flex tw-flex-col tw-overflow-y-auto tw-p-0",children:[t&&a.jsx(Cn,{children:S.getHeaderGroups().map(T=>a.jsx(Ze,{children:T.headers.filter(_=>_.column.columnDef.header).map(_=>a.jsx(Vt,{colSpan:_.colSpan,className:"top-0 tw-sticky",children:_.isPlaceholder?void 0:a.jsxs("div",{children:[_.column.getCanGroup()?a.jsx(fe,{variant:"ghost",title:`Toggle grouping by ${_.column.columnDef.header}`,onClick:_.column.getToggleGroupingHandler(),type:"button",children:_.column.getIsGrouped()?"🛑":"👊 "}):void 0," ",Se.flexRender(_.column.columnDef.header,_.getContext())]})},_.id))},T.id))}),a.jsx(Rn,{children:S.getRowModel().rows.map((T,_)=>a.jsx(Ze,{"data-state":T.getIsSelected()?"selected":"",className:N(V(T,_)),onClick:k=>P(T,k),children:T.getVisibleCells().map(k=>{if(!(k.getIsPlaceholder()||k.column.columnDef.enableGrouping&&!k.getIsGrouped()&&(k.column.columnDef.id!==pt||!n)))return a.jsx(xt,{className:N(k.column.columnDef.id,"tw-p-[1px]",U(d,T,k)),children:(()=>k.getIsGrouped()?a.jsxs(fe,{variant:"link",onClick:T.getToggleExpandedHandler(),type:"button",children:[T.getIsExpanded()&&a.jsx(Q.ChevronDown,{}),!T.getIsExpanded()&&(c==="ltr"?a.jsx(Q.ChevronRight,{}):a.jsx(Q.ChevronLeft,{}))," ",Se.flexRender(k.column.columnDef.cell,k.getContext())," (",T.subRows.length,")"]}):Se.flexRender(k.column.columnDef.cell,k.getContext()))()},k.id)})},T.id))})]})]})}const Or={[W.getLocalizeKeyForScrollGroupId("undefined")]:"Ø",[W.getLocalizeKeyForScrollGroupId(0)]:"A",[W.getLocalizeKeyForScrollGroupId(1)]:"B",[W.getLocalizeKeyForScrollGroupId(2)]:"C",[W.getLocalizeKeyForScrollGroupId(3)]:"D",[W.getLocalizeKeyForScrollGroupId(4)]:"E",[W.getLocalizeKeyForScrollGroupId(5)]:"F",[W.getLocalizeKeyForScrollGroupId(6)]:"G",[W.getLocalizeKeyForScrollGroupId(7)]:"H",[W.getLocalizeKeyForScrollGroupId(8)]:"I",[W.getLocalizeKeyForScrollGroupId(9)]:"J",[W.getLocalizeKeyForScrollGroupId(10)]:"K",[W.getLocalizeKeyForScrollGroupId(11)]:"L",[W.getLocalizeKeyForScrollGroupId(12)]:"M",[W.getLocalizeKeyForScrollGroupId(13)]:"N",[W.getLocalizeKeyForScrollGroupId(14)]:"O",[W.getLocalizeKeyForScrollGroupId(15)]:"P",[W.getLocalizeKeyForScrollGroupId(16)]:"Q",[W.getLocalizeKeyForScrollGroupId(17)]:"R",[W.getLocalizeKeyForScrollGroupId(18)]:"S",[W.getLocalizeKeyForScrollGroupId(19)]:"T",[W.getLocalizeKeyForScrollGroupId(20)]:"U",[W.getLocalizeKeyForScrollGroupId(21)]:"V",[W.getLocalizeKeyForScrollGroupId(22)]:"W",[W.getLocalizeKeyForScrollGroupId(23)]:"X",[W.getLocalizeKeyForScrollGroupId(24)]:"Y",[W.getLocalizeKeyForScrollGroupId(25)]:"Z"};function fd({availableScrollGroupIds:e,scrollGroupId:t,onChangeScrollGroupId:n,localizedStrings:r={}}){const o={...Or,...Object.fromEntries(Object.entries(r).map(([s,i])=>[s,s===i&&s in Or?Or[s]:i]))};return a.jsxs(At,{value:`${t}`,onValueChange:s=>n(s==="undefined"?void 0:parseInt(s,10)),children:[a.jsx(bt,{className:"pr-twp tw-w-auto",children:a.jsx(Bt,{placeholder:o[W.getLocalizeKeyForScrollGroupId(t)]??t})}),a.jsx(vt,{style:{zIndex:250},children:e.map(s=>a.jsx(Ae,{value:`${s}`,children:o[W.getLocalizeKeyForScrollGroupId(s)]},`${s}`))})]})}function md({children:e}){return a.jsx("div",{className:"pr-twp tw-grid",children:e})}function hd({primary:e,secondary:t,children:n,isLoading:r=!1,loadingMessage:o}){return a.jsxs("div",{className:"tw-flex tw-items-center tw-justify-between tw-space-x-4 tw-py-2",children:[a.jsxs("div",{children:[a.jsx("p",{className:"tw-text-sm tw-font-medium tw-leading-none",children:e}),a.jsx("p",{className:"tw-whitespace-normal tw-break-words tw-text-sm tw-text-muted-foreground",children:t})]}),r?a.jsx("p",{className:"tw-text-sm tw-text-muted-foreground",children:o}):a.jsx("div",{children:n})]})}function gd({primary:e,secondary:t,includeSeparator:n=!1}){return a.jsxs("div",{className:"tw-space-y-4 tw-py-2",children:[a.jsxs("div",{children:[a.jsx("h3",{className:"tw-text-lg tw-font-medium",children:e}),a.jsx("p",{className:"tw-text-sm tw-text-muted-foreground",children:t})]}),n?a.jsx(ir,{}):""]})}const ho=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,className:N("pr-twp tw-rounded-lg tw-border tw-bg-card tw-text-card-foreground tw-shadow-sm",e),...t}));ho.displayName="Card";const go=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,className:N("pr-twp tw-flex tw-flex-col tw-space-y-1.5 tw-p-6",e),...t}));go.displayName="CardHeader";const bo=g.forwardRef(({className:e,...t},n)=>a.jsx("h3",{ref:n,className:N("pr-twp tw-text-2xl tw-font-semibold tw-leading-none tw-tracking-tight",e),...t,children:t.children}));bo.displayName="CardTitle";const vo=g.forwardRef(({className:e,...t},n)=>a.jsx("p",{ref:n,className:N("pr-twp tw-text-sm tw-text-muted-foreground",e),...t}));vo.displayName="CardDescription";const Zs=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,className:N("pr-twp tw-p-6 tw-pt-0",e),...t}));Zs.displayName="CardContent";const Qs=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,className:N("pr-twp tw-flex tw-items-center tw-p-6 tw-pt-0",e),...t}));Qs.displayName="CardFooter";function bd({settingsGroupLabel:e,settingsGroupDescription:t,children:n}){return a.jsxs(ho,{children:[a.jsxs(go,{children:[a.jsx(bo,{children:e}),a.jsx(vo,{children:t})]}),a.jsx(Te.CardContent,{className:"tw-space-y-4",children:n})]})}function vd({id:e,className:t,listItems:n,selectedListItems:r,handleSelectListItem:o,createLabel:s}){return a.jsx("div",{id:e,className:t,children:n.map(i=>a.jsxs("div",{className:"tw-m-2 tw-flex tw-items-center",children:[a.jsx(ar,{className:"tw-mr-2 tw-align-middle",checked:r.includes(i),onCheckedChange:l=>o(i,l)}),a.jsx(qe,{children:s?s(i):i})]},i))})}function xd(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}function yd(e){if(e.__esModule)return e;var t=e.default;if(typeof t=="function"){var n=function r(){return this instanceof r?Reflect.construct(t,arguments,this.constructor):t.apply(this,arguments)};n.prototype=t.prototype}else n={};return Object.defineProperty(n,"__esModule",{value:!0}),Object.keys(e).forEach(function(r){var o=Object.getOwnPropertyDescriptor(e,r);Object.defineProperty(n,r,o.get?o:{enumerable:!0,get:function(){return e[r]}})}),n}var xo={},ei={exports:{}};(function(e){function t(n){return n&&n.__esModule?n:{default:n}}e.exports=t,e.exports.__esModule=!0,e.exports.default=e.exports})(ei);var Nd=ei.exports,_r={};function yo(e,t){return process.env.NODE_ENV==="production"?()=>null:function(...r){return e(...r)||t(...r)}}function O(){return O=Object.assign?Object.assign.bind():function(e){for(var t=1;t{t[n]=ti(e[n])}),t}function Qe(e,t,n={clone:!0}){const r=n.clone?O({},e):e;return mt(e)&&mt(t)&&Object.keys(t).forEach(o=>{o!=="__proto__"&&(mt(t[o])&&o in e&&mt(e[o])?r[o]=Qe(e[o],t[o],n):n.clone?r[o]=mt(t[o])?ti(t[o]):t[o]:r[o]=t[o])}),r}var Xr={exports:{}},zn={exports:{}},ie={};/** @license React v16.13.1 * react-is.production.min.js * * Copyright (c) Facebook, Inc. and its affiliates. * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. - */var Qo;function Tc(){if(Qo)return ie;Qo=1;var e=typeof Symbol=="function"&&Symbol.for,t=e?Symbol.for("react.element"):60103,n=e?Symbol.for("react.portal"):60106,r=e?Symbol.for("react.fragment"):60107,o=e?Symbol.for("react.strict_mode"):60108,s=e?Symbol.for("react.profiler"):60114,i=e?Symbol.for("react.provider"):60109,l=e?Symbol.for("react.context"):60110,c=e?Symbol.for("react.async_mode"):60111,d=e?Symbol.for("react.concurrent_mode"):60111,u=e?Symbol.for("react.forward_ref"):60112,m=e?Symbol.for("react.suspense"):60113,w=e?Symbol.for("react.suspense_list"):60120,b=e?Symbol.for("react.memo"):60115,y=e?Symbol.for("react.lazy"):60116,f=e?Symbol.for("react.block"):60121,h=e?Symbol.for("react.fundamental"):60117,E=e?Symbol.for("react.responder"):60118,I=e?Symbol.for("react.scope"):60119;function j(g){if(typeof g=="object"&&g!==null){var P=g.$$typeof;switch(P){case t:switch(g=g.type,g){case c:case d:case r:case s:case o:case m:return g;default:switch(g=g&&g.$$typeof,g){case l:case u:case y:case b:case i:return g;default:return P}}case n:return P}}}function k(g){return j(g)===d}return ie.AsyncMode=c,ie.ConcurrentMode=d,ie.ContextConsumer=l,ie.ContextProvider=i,ie.Element=t,ie.ForwardRef=u,ie.Fragment=r,ie.Lazy=y,ie.Memo=b,ie.Portal=n,ie.Profiler=s,ie.StrictMode=o,ie.Suspense=m,ie.isAsyncMode=function(g){return k(g)||j(g)===c},ie.isConcurrentMode=k,ie.isContextConsumer=function(g){return j(g)===l},ie.isContextProvider=function(g){return j(g)===i},ie.isElement=function(g){return typeof g=="object"&&g!==null&&g.$$typeof===t},ie.isForwardRef=function(g){return j(g)===u},ie.isFragment=function(g){return j(g)===r},ie.isLazy=function(g){return j(g)===y},ie.isMemo=function(g){return j(g)===b},ie.isPortal=function(g){return j(g)===n},ie.isProfiler=function(g){return j(g)===s},ie.isStrictMode=function(g){return j(g)===o},ie.isSuspense=function(g){return j(g)===m},ie.isValidElementType=function(g){return typeof g=="string"||typeof g=="function"||g===r||g===d||g===s||g===o||g===m||g===w||typeof g=="object"&&g!==null&&(g.$$typeof===y||g.$$typeof===b||g.$$typeof===i||g.$$typeof===l||g.$$typeof===u||g.$$typeof===h||g.$$typeof===E||g.$$typeof===I||g.$$typeof===f)},ie.typeOf=j,ie}var le={};/** @license React v16.13.1 + */var la;function kd(){if(la)return ie;la=1;var e=typeof Symbol=="function"&&Symbol.for,t=e?Symbol.for("react.element"):60103,n=e?Symbol.for("react.portal"):60106,r=e?Symbol.for("react.fragment"):60107,o=e?Symbol.for("react.strict_mode"):60108,s=e?Symbol.for("react.profiler"):60114,i=e?Symbol.for("react.provider"):60109,l=e?Symbol.for("react.context"):60110,c=e?Symbol.for("react.async_mode"):60111,d=e?Symbol.for("react.concurrent_mode"):60111,u=e?Symbol.for("react.forward_ref"):60112,m=e?Symbol.for("react.suspense"):60113,w=e?Symbol.for("react.suspense_list"):60120,b=e?Symbol.for("react.memo"):60115,x=e?Symbol.for("react.lazy"):60116,f=e?Symbol.for("react.block"):60121,h=e?Symbol.for("react.fundamental"):60117,S=e?Symbol.for("react.responder"):60118,R=e?Symbol.for("react.scope"):60119;function j(v){if(typeof v=="object"&&v!==null){var P=v.$$typeof;switch(P){case t:switch(v=v.type,v){case c:case d:case r:case s:case o:case m:return v;default:switch(v=v&&v.$$typeof,v){case l:case u:case x:case b:case i:return v;default:return P}}case n:return P}}}function E(v){return j(v)===d}return ie.AsyncMode=c,ie.ConcurrentMode=d,ie.ContextConsumer=l,ie.ContextProvider=i,ie.Element=t,ie.ForwardRef=u,ie.Fragment=r,ie.Lazy=x,ie.Memo=b,ie.Portal=n,ie.Profiler=s,ie.StrictMode=o,ie.Suspense=m,ie.isAsyncMode=function(v){return E(v)||j(v)===c},ie.isConcurrentMode=E,ie.isContextConsumer=function(v){return j(v)===l},ie.isContextProvider=function(v){return j(v)===i},ie.isElement=function(v){return typeof v=="object"&&v!==null&&v.$$typeof===t},ie.isForwardRef=function(v){return j(v)===u},ie.isFragment=function(v){return j(v)===r},ie.isLazy=function(v){return j(v)===x},ie.isMemo=function(v){return j(v)===b},ie.isPortal=function(v){return j(v)===n},ie.isProfiler=function(v){return j(v)===s},ie.isStrictMode=function(v){return j(v)===o},ie.isSuspense=function(v){return j(v)===m},ie.isValidElementType=function(v){return typeof v=="string"||typeof v=="function"||v===r||v===d||v===s||v===o||v===m||v===w||typeof v=="object"&&v!==null&&(v.$$typeof===x||v.$$typeof===b||v.$$typeof===i||v.$$typeof===l||v.$$typeof===u||v.$$typeof===h||v.$$typeof===S||v.$$typeof===R||v.$$typeof===f)},ie.typeOf=j,ie}var le={};/** @license React v16.13.1 * react-is.development.js * * Copyright (c) Facebook, Inc. and its affiliates. * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. - */var es;function Cc(){return es||(es=1,process.env.NODE_ENV!=="production"&&function(){var e=typeof Symbol=="function"&&Symbol.for,t=e?Symbol.for("react.element"):60103,n=e?Symbol.for("react.portal"):60106,r=e?Symbol.for("react.fragment"):60107,o=e?Symbol.for("react.strict_mode"):60108,s=e?Symbol.for("react.profiler"):60114,i=e?Symbol.for("react.provider"):60109,l=e?Symbol.for("react.context"):60110,c=e?Symbol.for("react.async_mode"):60111,d=e?Symbol.for("react.concurrent_mode"):60111,u=e?Symbol.for("react.forward_ref"):60112,m=e?Symbol.for("react.suspense"):60113,w=e?Symbol.for("react.suspense_list"):60120,b=e?Symbol.for("react.memo"):60115,y=e?Symbol.for("react.lazy"):60116,f=e?Symbol.for("react.block"):60121,h=e?Symbol.for("react.fundamental"):60117,E=e?Symbol.for("react.responder"):60118,I=e?Symbol.for("react.scope"):60119;function j(_){return typeof _=="string"||typeof _=="function"||_===r||_===d||_===s||_===o||_===m||_===w||typeof _=="object"&&_!==null&&(_.$$typeof===y||_.$$typeof===b||_.$$typeof===i||_.$$typeof===l||_.$$typeof===u||_.$$typeof===h||_.$$typeof===E||_.$$typeof===I||_.$$typeof===f)}function k(_){if(typeof _=="object"&&_!==null){var ye=_.$$typeof;switch(ye){case t:var A=_.type;switch(A){case c:case d:case r:case s:case o:case m:return A;default:var ve=A&&A.$$typeof;switch(ve){case l:case u:case y:case b:case i:return ve;default:return ye}}case n:return ye}}}var g=c,P=d,V=l,U=i,T=t,R=u,N=r,D=y,$=b,J=n,Y=s,z=o,ee=m,ae=!1;function oe(_){return ae||(ae=!0,console.warn("The ReactIs.isAsyncMode() alias has been deprecated, and will be removed in React 17+. Update your code to use ReactIs.isConcurrentMode() instead. It has the exact same API.")),x(_)||k(_)===c}function x(_){return k(_)===d}function C(_){return k(_)===l}function L(_){return k(_)===i}function F(_){return typeof _=="object"&&_!==null&&_.$$typeof===t}function B(_){return k(_)===u}function X(_){return k(_)===r}function q(_){return k(_)===y}function H(_){return k(_)===b}function G(_){return k(_)===n}function K(_){return k(_)===s}function Z(_){return k(_)===o}function ue(_){return k(_)===m}le.AsyncMode=g,le.ConcurrentMode=P,le.ContextConsumer=V,le.ContextProvider=U,le.Element=T,le.ForwardRef=R,le.Fragment=N,le.Lazy=D,le.Memo=$,le.Portal=J,le.Profiler=Y,le.StrictMode=z,le.Suspense=ee,le.isAsyncMode=oe,le.isConcurrentMode=x,le.isContextConsumer=C,le.isContextProvider=L,le.isElement=F,le.isForwardRef=B,le.isFragment=X,le.isLazy=q,le.isMemo=H,le.isPortal=G,le.isProfiler=K,le.isStrictMode=Z,le.isSuspense=ue,le.isValidElementType=j,le.typeOf=k}()),le}var ts;function Ra(){return ts||(ts=1,process.env.NODE_ENV==="production"?An.exports=Tc():An.exports=Cc()),An.exports}/* + */var ca;function Sd(){return ca||(ca=1,process.env.NODE_ENV!=="production"&&function(){var e=typeof Symbol=="function"&&Symbol.for,t=e?Symbol.for("react.element"):60103,n=e?Symbol.for("react.portal"):60106,r=e?Symbol.for("react.fragment"):60107,o=e?Symbol.for("react.strict_mode"):60108,s=e?Symbol.for("react.profiler"):60114,i=e?Symbol.for("react.provider"):60109,l=e?Symbol.for("react.context"):60110,c=e?Symbol.for("react.async_mode"):60111,d=e?Symbol.for("react.concurrent_mode"):60111,u=e?Symbol.for("react.forward_ref"):60112,m=e?Symbol.for("react.suspense"):60113,w=e?Symbol.for("react.suspense_list"):60120,b=e?Symbol.for("react.memo"):60115,x=e?Symbol.for("react.lazy"):60116,f=e?Symbol.for("react.block"):60121,h=e?Symbol.for("react.fundamental"):60117,S=e?Symbol.for("react.responder"):60118,R=e?Symbol.for("react.scope"):60119;function j(I){return typeof I=="string"||typeof I=="function"||I===r||I===d||I===s||I===o||I===m||I===w||typeof I=="object"&&I!==null&&(I.$$typeof===x||I.$$typeof===b||I.$$typeof===i||I.$$typeof===l||I.$$typeof===u||I.$$typeof===h||I.$$typeof===S||I.$$typeof===R||I.$$typeof===f)}function E(I){if(typeof I=="object"&&I!==null){var ye=I.$$typeof;switch(ye){case t:var A=I.type;switch(A){case c:case d:case r:case s:case o:case m:return A;default:var xe=A&&A.$$typeof;switch(xe){case l:case u:case x:case b:case i:return xe;default:return ye}}case n:return ye}}}var v=c,P=d,V=l,U=i,T=t,_=u,k=r,D=x,$=b,J=n,Y=s,F=o,te=m,se=!1;function oe(I){return se||(se=!0,console.warn("The ReactIs.isAsyncMode() alias has been deprecated, and will be removed in React 17+. Update your code to use ReactIs.isConcurrentMode() instead. It has the exact same API.")),y(I)||E(I)===c}function y(I){return E(I)===d}function C(I){return E(I)===l}function z(I){return E(I)===i}function L(I){return typeof I=="object"&&I!==null&&I.$$typeof===t}function B(I){return E(I)===u}function X(I){return E(I)===r}function q(I){return E(I)===x}function H(I){return E(I)===b}function G(I){return E(I)===n}function K(I){return E(I)===s}function Z(I){return E(I)===o}function ue(I){return E(I)===m}le.AsyncMode=v,le.ConcurrentMode=P,le.ContextConsumer=V,le.ContextProvider=U,le.Element=T,le.ForwardRef=_,le.Fragment=k,le.Lazy=D,le.Memo=$,le.Portal=J,le.Profiler=Y,le.StrictMode=F,le.Suspense=te,le.isAsyncMode=oe,le.isConcurrentMode=y,le.isContextConsumer=C,le.isContextProvider=z,le.isElement=L,le.isForwardRef=B,le.isFragment=X,le.isLazy=q,le.isMemo=H,le.isPortal=G,le.isProfiler=K,le.isStrictMode=Z,le.isSuspense=ue,le.isValidElementType=j,le.typeOf=E}()),le}var da;function ni(){return da||(da=1,process.env.NODE_ENV==="production"?zn.exports=kd():zn.exports=Sd()),zn.exports}/* object-assign (c) Sindre Sorhus @license MIT -*/var Cr,ns;function jc(){if(ns)return Cr;ns=1;var e=Object.getOwnPropertySymbols,t=Object.prototype.hasOwnProperty,n=Object.prototype.propertyIsEnumerable;function r(s){if(s==null)throw new TypeError("Object.assign cannot be called with null or undefined");return Object(s)}function o(){try{if(!Object.assign)return!1;var s=new String("abc");if(s[5]="de",Object.getOwnPropertyNames(s)[0]==="5")return!1;for(var i={},l=0;l<10;l++)i["_"+String.fromCharCode(l)]=l;var c=Object.getOwnPropertyNames(i).map(function(u){return i[u]});if(c.join("")!=="0123456789")return!1;var d={};return"abcdefghijklmnopqrst".split("").forEach(function(u){d[u]=u}),Object.keys(Object.assign({},d)).join("")==="abcdefghijklmnopqrst"}catch{return!1}}return Cr=o()?Object.assign:function(s,i){for(var l,c=r(s),d,u=1;u1?s("Invalid arguments supplied to oneOf, expected an array, got "+arguments.length+" arguments. A common mistake is to write oneOf(x, y, z) instead of oneOf([x, y, z])."):s("Invalid argument supplied to oneOf, expected an array.")),i;function C(L,F,B,X,q){for(var H=L[F],G=0;G0?", expected one of type ["+K.join(", ")+"]":"";return new f("Invalid "+H+" `"+G+"` supplied to "+("`"+q+"`"+ye+"."))}return h(F)}function R(){function x(C,L,F,B,X){return J(C[L])?null:new f("Invalid "+B+" `"+X+"` supplied to "+("`"+F+"`, expected a ReactNode."))}return h(x)}function N(x,C,L,F,B){return new f((x||"React class")+": "+C+" type `"+L+"."+F+"` is invalid; it must be a function, usually from the `prop-types` package, but received `"+B+"`.")}function D(x){function C(L,F,B,X,q){var H=L[F],G=z(H);if(G!=="object")return new f("Invalid "+X+" `"+q+"` of type `"+G+"` "+("supplied to `"+B+"`, expected `object`."));for(var K in x){var Z=x[K];if(typeof Z!="function")return N(B,X,q,K,ee(Z));var ue=Z(H,K,B,X,q+"."+K,n);if(ue)return ue}return null}return h(C)}function $(x){function C(L,F,B,X,q){var H=L[F],G=z(H);if(G!=="object")return new f("Invalid "+X+" `"+q+"` of type `"+G+"` "+("supplied to `"+B+"`, expected `object`."));var K=t({},L[F],x);for(var Z in K){var ue=x[Z];if(r(x,Z)&&typeof ue!="function")return N(B,X,q,Z,ee(ue));if(!ue)return new f("Invalid "+X+" `"+q+"` key `"+Z+"` supplied to `"+B+"`.\nBad object: "+JSON.stringify(L[F],null," ")+` -Valid keys: `+JSON.stringify(Object.keys(x),null," "));var _=ue(H,Z,B,X,q+"."+Z,n);if(_)return _}return null}return h(C)}function J(x){switch(typeof x){case"number":case"string":case"undefined":return!0;case"boolean":return!x;case"object":if(Array.isArray(x))return x.every(J);if(x===null||l(x))return!0;var C=m(x);if(C){var L=C.call(x),F;if(C!==x.entries){for(;!(F=L.next()).done;)if(!J(F.value))return!1}else for(;!(F=L.next()).done;){var B=F.value;if(B&&!J(B[1]))return!1}}else return!1;return!0;default:return!1}}function Y(x,C){return x==="symbol"?!0:C?C["@@toStringTag"]==="Symbol"||typeof Symbol=="function"&&C instanceof Symbol:!1}function z(x){var C=typeof x;return Array.isArray(x)?"array":x instanceof RegExp?"object":Y(C,x)?"symbol":C}function ee(x){if(typeof x>"u"||x===null)return""+x;var C=z(x);if(C==="object"){if(x instanceof Date)return"date";if(x instanceof RegExp)return"regexp"}return C}function ae(x){var C=ee(x);switch(C){case"array":case"object":return"an "+C;case"boolean":case"date":case"regexp":return"a "+C;default:return C}}function oe(x){return!x.constructor||!x.constructor.name?w:x.constructor.name}return b.checkPropTypes=o,b.resetWarningCache=o.resetWarningCache,b.PropTypes=b,b},Pr}var _r,is;function Pc(){if(is)return _r;is=1;var e=fo();function t(){}function n(){}return n.resetWarningCache=t,_r=function(){function r(i,l,c,d,u,m){if(m!==e){var w=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types");throw w.name="Invariant Violation",w}}r.isRequired=r;function o(){return r}var s={array:r,bigint:r,bool:r,func:r,number:r,object:r,string:r,symbol:r,any:r,arrayOf:o,element:r,elementType:r,instanceOf:o,node:r,objectOf:o,oneOf:o,oneOfType:o,shape:o,exact:o,checkPropTypes:n,resetWarningCache:t};return s.PropTypes=s,s},_r}if(process.env.NODE_ENV!=="production"){var _c=Ra(),Ic=!0;zr.exports=Rc()(_c.isElement,Ic)}else zr.exports=Pc()();var $c=zr.exports;const p=kc($c);function Mc(e){const{prototype:t={}}=e;return!!t.isReactComponent}function _a(e,t,n,r,o){const s=e[t],i=o||t;if(s==null||typeof window>"u")return null;let l;const c=s.type;return typeof c=="function"&&!Mc(c)&&(l="Did you accidentally use a plain function component for an element instead?"),l!==void 0?new Error(`Invalid ${r} \`${i}\` supplied to \`${n}\`. Expected an element that can hold a ref. ${l} For more information see https://mui.com/r/caveat-with-refs-guide`):null}const Ia=wo(p.element,_a);Ia.isRequired=wo(p.element.isRequired,_a);const $a=Ia,Dc="exact-prop: ​";function Ac(e){return process.env.NODE_ENV==="production"?e:O({},e,{[Dc]:t=>{const n=Object.keys(t).filter(r=>!e.hasOwnProperty(r));return n.length>0?new Error(`The following props are not supported: ${n.map(r=>`\`${r}\``).join(", ")}. Please remove them.`):null}})}function Vt(e){let t="https://mui.com/production-error/?code="+e;for(let n=1;n1?s("Invalid arguments supplied to oneOf, expected an array, got "+arguments.length+" arguments. A common mistake is to write oneOf(x, y, z) instead of oneOf([x, y, z])."):s("Invalid argument supplied to oneOf, expected an array.")),i;function C(z,L,B,X,q){for(var H=z[L],G=0;G0?", expected one of type ["+K.join(", ")+"]":"";return new f("Invalid "+H+" `"+G+"` supplied to "+("`"+q+"`"+ye+"."))}return h(L)}function _(){function y(C,z,L,B,X){return J(C[z])?null:new f("Invalid "+B+" `"+X+"` supplied to "+("`"+L+"`, expected a ReactNode."))}return h(y)}function k(y,C,z,L,B){return new f((y||"React class")+": "+C+" type `"+z+"."+L+"` is invalid; it must be a function, usually from the `prop-types` package, but received `"+B+"`.")}function D(y){function C(z,L,B,X,q){var H=z[L],G=F(H);if(G!=="object")return new f("Invalid "+X+" `"+q+"` of type `"+G+"` "+("supplied to `"+B+"`, expected `object`."));for(var K in y){var Z=y[K];if(typeof Z!="function")return k(B,X,q,K,te(Z));var ue=Z(H,K,B,X,q+"."+K,n);if(ue)return ue}return null}return h(C)}function $(y){function C(z,L,B,X,q){var H=z[L],G=F(H);if(G!=="object")return new f("Invalid "+X+" `"+q+"` of type `"+G+"` "+("supplied to `"+B+"`, expected `object`."));var K=t({},z[L],y);for(var Z in K){var ue=y[Z];if(r(y,Z)&&typeof ue!="function")return k(B,X,q,Z,te(ue));if(!ue)return new f("Invalid "+X+" `"+q+"` key `"+Z+"` supplied to `"+B+"`.\nBad object: "+JSON.stringify(z[L],null," ")+` +Valid keys: `+JSON.stringify(Object.keys(y),null," "));var I=ue(H,Z,B,X,q+"."+Z,n);if(I)return I}return null}return h(C)}function J(y){switch(typeof y){case"number":case"string":case"undefined":return!0;case"boolean":return!y;case"object":if(Array.isArray(y))return y.every(J);if(y===null||l(y))return!0;var C=m(y);if(C){var z=C.call(y),L;if(C!==y.entries){for(;!(L=z.next()).done;)if(!J(L.value))return!1}else for(;!(L=z.next()).done;){var B=L.value;if(B&&!J(B[1]))return!1}}else return!1;return!0;default:return!1}}function Y(y,C){return y==="symbol"?!0:C?C["@@toStringTag"]==="Symbol"||typeof Symbol=="function"&&C instanceof Symbol:!1}function F(y){var C=typeof y;return Array.isArray(y)?"array":y instanceof RegExp?"object":Y(C,y)?"symbol":C}function te(y){if(typeof y>"u"||y===null)return""+y;var C=F(y);if(C==="object"){if(y instanceof Date)return"date";if(y instanceof RegExp)return"regexp"}return C}function se(y){var C=te(y);switch(C){case"array":case"object":return"an "+C;case"boolean":case"date":case"regexp":return"a "+C;default:return C}}function oe(y){return!y.constructor||!y.constructor.name?w:y.constructor.name}return b.checkPropTypes=o,b.resetWarningCache=o.resetWarningCache,b.PropTypes=b,b},Dr}var Ar,ha;function Cd(){if(ha)return Ar;ha=1;var e=No();function t(){}function n(){}return n.resetWarningCache=t,Ar=function(){function r(i,l,c,d,u,m){if(m!==e){var w=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types");throw w.name="Invariant Violation",w}}r.isRequired=r;function o(){return r}var s={array:r,bigint:r,bool:r,func:r,number:r,object:r,string:r,symbol:r,any:r,arrayOf:o,element:r,elementType:r,instanceOf:o,node:r,objectOf:o,oneOf:o,oneOfType:o,shape:o,exact:o,checkPropTypes:n,resetWarningCache:t};return s.PropTypes=s,s},Ar}if(process.env.NODE_ENV!=="production"){var Rd=ni(),Od=!0;Xr.exports=Td()(Rd.isElement,Od)}else Xr.exports=Cd()();var _d=Xr.exports;const p=xd(_d);function Pd(e){const{prototype:t={}}=e;return!!t.isReactComponent}function oi(e,t,n,r,o){const s=e[t],i=o||t;if(s==null||typeof window>"u")return null;let l;const c=s.type;return typeof c=="function"&&!Pd(c)&&(l="Did you accidentally use a plain function component for an element instead?"),l!==void 0?new Error(`Invalid ${r} \`${i}\` supplied to \`${n}\`. Expected an element that can hold a ref. ${l} For more information see https://mui.com/r/caveat-with-refs-guide`):null}const ai=yo(p.element,oi);ai.isRequired=yo(p.element.isRequired,oi);const si=ai,Id="exact-prop: ​";function Md(e){return process.env.NODE_ENV==="production"?e:O({},e,{[Id]:t=>{const n=Object.keys(t).filter(r=>!e.hasOwnProperty(r));return n.length>0?new Error(`The following props are not supported: ${n.map(r=>`\`${r}\``).join(", ")}. Please remove them.`):null}})}function zt(e){let t="https://mui.com/production-error/?code="+e;for(let n=1;nn==null?t:function(...o){t.apply(this,o),n.apply(this,o)},()=>{})}function qc(e,t=166){let n;function r(...o){const s=()=>{e.apply(this,o)};clearTimeout(n),n=setTimeout(s,t)}return r.clear=()=>{clearTimeout(n)},r}function Hc(e,t){return process.env.NODE_ENV==="production"?()=>null:(n,r,o,s,i)=>{const l=o||"<>",c=i||r;return typeof n[r]<"u"?new Error(`The ${s} \`${c}\` of \`${l}\` is deprecated. ${t}`):null}}function Xc(e,t){var n,r;return M.isValidElement(e)&&t.indexOf((n=e.type.muiName)!=null?n:(r=e.type)==null||(r=r._payload)==null||(r=r.value)==null?void 0:r.muiName)!==-1}function Hn(e){return e&&e.ownerDocument||document}function Yc(e){return Hn(e).defaultView||window}function Wc(e,t){if(process.env.NODE_ENV==="production")return()=>null;const n=t?O({},t.propTypes):null;return o=>(s,i,l,c,d,...u)=>{const m=d||i,w=n==null?void 0:n[m];if(w){const b=w(s,i,l,c,d,...u);if(b)return b}return typeof s[i]<"u"&&!s[o]?new Error(`The prop \`${m}\` of \`${e}\` can only be used together with the \`${o}\` prop.`):null}}function Xn(e,t){typeof e=="function"?e(t):e&&(e.current=t)}const Kc=typeof window<"u"?M.useLayoutEffect:M.useEffect,Lt=Kc;let ps=0;function Jc(e){const[t,n]=M.useState(e),r=e||t;return M.useEffect(()=>{t==null&&(ps+=1,n(`mui-${ps}`))},[t]),r}const ws=M["useId".toString()];function Aa(e){if(ws!==void 0){const t=ws();return e??t}return Jc(e)}function Zc(e,t,n,r,o){if(process.env.NODE_ENV==="production")return null;const s=o||t;return typeof e[t]<"u"?new Error(`The prop \`${s}\` is not supported. Please remove it.`):null}function Ba({controlled:e,default:t,name:n,state:r="value"}){const{current:o}=M.useRef(e!==void 0),[s,i]=M.useState(t),l=o?e:s;if(process.env.NODE_ENV!=="production"){M.useEffect(()=>{o!==(e!==void 0)&&console.error([`MUI: A component is changing the ${o?"":"un"}controlled ${r} state of ${n} to be ${o?"un":""}controlled.`,"Elements should not switch from uncontrolled to controlled (or vice versa).",`Decide between using a controlled or uncontrolled ${n} element for the lifetime of the component.`,"The nature of the state is determined during the first render. It's considered controlled if the value is not `undefined`.","More info: https://fb.me/react-controlled-components"].join(` + */var ba;function Dd(){return ba||(ba=1,process.env.NODE_ENV!=="production"&&function(){var e=Symbol.for("react.element"),t=Symbol.for("react.portal"),n=Symbol.for("react.fragment"),r=Symbol.for("react.strict_mode"),o=Symbol.for("react.profiler"),s=Symbol.for("react.provider"),i=Symbol.for("react.context"),l=Symbol.for("react.server_context"),c=Symbol.for("react.forward_ref"),d=Symbol.for("react.suspense"),u=Symbol.for("react.suspense_list"),m=Symbol.for("react.memo"),w=Symbol.for("react.lazy"),b=Symbol.for("react.offscreen"),x=!1,f=!1,h=!1,S=!1,R=!1,j;j=Symbol.for("react.module.reference");function E(A){return!!(typeof A=="string"||typeof A=="function"||A===n||A===o||R||A===r||A===d||A===u||S||A===b||x||f||h||typeof A=="object"&&A!==null&&(A.$$typeof===w||A.$$typeof===m||A.$$typeof===s||A.$$typeof===i||A.$$typeof===c||A.$$typeof===j||A.getModuleId!==void 0))}function v(A){if(typeof A=="object"&&A!==null){var xe=A.$$typeof;switch(xe){case e:var Ge=A.type;switch(Ge){case n:case o:case r:case d:case u:return Ge;default:var lt=Ge&&Ge.$$typeof;switch(lt){case l:case i:case c:case w:case m:case s:return lt;default:return xe}}case t:return xe}}}var P=i,V=s,U=e,T=c,_=n,k=w,D=m,$=t,J=o,Y=r,F=d,te=u,se=!1,oe=!1;function y(A){return se||(se=!0,console.warn("The ReactIs.isAsyncMode() alias has been deprecated, and will be removed in React 18+.")),!1}function C(A){return oe||(oe=!0,console.warn("The ReactIs.isConcurrentMode() alias has been deprecated, and will be removed in React 18+.")),!1}function z(A){return v(A)===i}function L(A){return v(A)===s}function B(A){return typeof A=="object"&&A!==null&&A.$$typeof===e}function X(A){return v(A)===c}function q(A){return v(A)===n}function H(A){return v(A)===w}function G(A){return v(A)===m}function K(A){return v(A)===t}function Z(A){return v(A)===o}function ue(A){return v(A)===r}function I(A){return v(A)===d}function ye(A){return v(A)===u}de.ContextConsumer=P,de.ContextProvider=V,de.Element=U,de.ForwardRef=T,de.Fragment=_,de.Lazy=k,de.Memo=D,de.Portal=$,de.Profiler=J,de.StrictMode=Y,de.Suspense=F,de.SuspenseList=te,de.isAsyncMode=y,de.isConcurrentMode=C,de.isContextConsumer=z,de.isContextProvider=L,de.isElement=B,de.isForwardRef=X,de.isFragment=q,de.isLazy=H,de.isMemo=G,de.isPortal=K,de.isProfiler=Z,de.isStrictMode=ue,de.isSuspense=I,de.isSuspenseList=ye,de.isValidElementType=E,de.typeOf=v}()),de}process.env.NODE_ENV==="production"?Yr.exports=$d():Yr.exports=Dd();var va=Yr.exports;const Ad=/^\s*function(?:\s|\s*\/\*.*\*\/\s*)+([^(\s/]*)\s*/;function Bd(e){const t=`${e}`.match(Ad);return t&&t[1]||""}function ii(e,t=""){return e.displayName||e.name||Bd(e)||t}function xa(e,t,n){const r=ii(t);return e.displayName||(r!==""?`${n}(${r})`:n)}function Vd(e){if(e!=null){if(typeof e=="string")return e;if(typeof e=="function")return ii(e,"Component");if(typeof e=="object")switch(e.$$typeof){case va.ForwardRef:return xa(e,e.render,"ForwardRef");case va.Memo:return xa(e,e.type,"memo");default:return}}}function xn(e,t,n,r,o){if(process.env.NODE_ENV==="production")return null;const s=e[t],i=o||t;return s==null?null:s&&s.nodeType!==1?new Error(`Invalid ${r} \`${i}\` supplied to \`${n}\`. Expected an HTMLElement.`):null}const zd=p.oneOfType([p.func,p.object]),li=zd;function Ye(e){if(typeof e!="string")throw new Error(process.env.NODE_ENV!=="production"?"MUI: `capitalize(string)` expects a string argument.":zt(7));return e.charAt(0).toUpperCase()+e.slice(1)}function Ld(...e){return e.reduce((t,n)=>n==null?t:function(...o){t.apply(this,o),n.apply(this,o)},()=>{})}function Fd(e,t=166){let n;function r(...o){const s=()=>{e.apply(this,o)};clearTimeout(n),n=setTimeout(s,t)}return r.clear=()=>{clearTimeout(n)},r}function Gd(e,t){return process.env.NODE_ENV==="production"?()=>null:(n,r,o,s,i)=>{const l=o||"<>",c=i||r;return typeof n[r]<"u"?new Error(`The ${s} \`${c}\` of \`${l}\` is deprecated. ${t}`):null}}function Ud(e,t){var n,r;return M.isValidElement(e)&&t.indexOf((n=e.type.muiName)!=null?n:(r=e.type)==null||(r=r._payload)==null||(r=r.value)==null?void 0:r.muiName)!==-1}function Wn(e){return e&&e.ownerDocument||document}function qd(e){return Wn(e).defaultView||window}function Hd(e,t){if(process.env.NODE_ENV==="production")return()=>null;const n=t?O({},t.propTypes):null;return o=>(s,i,l,c,d,...u)=>{const m=d||i,w=n==null?void 0:n[m];if(w){const b=w(s,i,l,c,d,...u);if(b)return b}return typeof s[i]<"u"&&!s[o]?new Error(`The prop \`${m}\` of \`${e}\` can only be used together with the \`${o}\` prop.`):null}}function Kn(e,t){typeof e=="function"?e(t):e&&(e.current=t)}const Xd=typeof window<"u"?M.useLayoutEffect:M.useEffect,Lt=Xd;let ya=0;function Yd(e){const[t,n]=M.useState(e),r=e||t;return M.useEffect(()=>{t==null&&(ya+=1,n(`mui-${ya}`))},[t]),r}const Na=M["useId".toString()];function ci(e){if(Na!==void 0){const t=Na();return e??t}return Yd(e)}function Wd(e,t,n,r,o){if(process.env.NODE_ENV==="production")return null;const s=o||t;return typeof e[t]<"u"?new Error(`The prop \`${s}\` is not supported. Please remove it.`):null}function di({controlled:e,default:t,name:n,state:r="value"}){const{current:o}=M.useRef(e!==void 0),[s,i]=M.useState(t),l=o?e:s;if(process.env.NODE_ENV!=="production"){M.useEffect(()=>{o!==(e!==void 0)&&console.error([`MUI: A component is changing the ${o?"":"un"}controlled ${r} state of ${n} to be ${o?"un":""}controlled.`,"Elements should not switch from uncontrolled to controlled (or vice versa).",`Decide between using a controlled or uncontrolled ${n} element for the lifetime of the component.`,"The nature of the state is determined during the first render. It's considered controlled if the value is not `undefined`.","More info: https://fb.me/react-controlled-components"].join(` `))},[r,n,e]);const{current:d}=M.useRef(t);M.useEffect(()=>{!o&&d!==t&&console.error([`MUI: A component is changing the default ${r} state of an uncontrolled ${n} after being initialized. To suppress this warning opt to use a controlled ${n}.`].join(` -`))},[JSON.stringify(t)])}const c=M.useCallback(d=>{o||i(d)},[]);return[l,c]}function Ur(e){const t=M.useRef(e);return Lt(()=>{t.current=e}),M.useRef((...n)=>(0,t.current)(...n)).current}function xt(...e){return M.useMemo(()=>e.every(t=>t==null)?null:t=>{e.forEach(n=>{Xn(n,t)})},e)}const fs={};function Qc(e,t){const n=M.useRef(fs);return n.current===fs&&(n.current=e(t)),n}const ed=[];function td(e){M.useEffect(e,ed)}class Cn{constructor(){this.currentId=null,this.clear=()=>{this.currentId!==null&&(clearTimeout(this.currentId),this.currentId=null)},this.disposeEffect=()=>this.clear}static create(){return new Cn}start(t,n){this.clear(),this.currentId=setTimeout(()=>{this.currentId=null,n()},t)}}function ln(){const e=Qc(Cn.create).current;return td(e.disposeEffect),e}let sr=!0,qr=!1;const nd=new Cn,rd={text:!0,search:!0,url:!0,tel:!0,email:!0,password:!0,number:!0,date:!0,month:!0,week:!0,time:!0,datetime:!0,"datetime-local":!0};function od(e){const{type:t,tagName:n}=e;return!!(n==="INPUT"&&rd[t]&&!e.readOnly||n==="TEXTAREA"&&!e.readOnly||e.isContentEditable)}function sd(e){e.metaKey||e.altKey||e.ctrlKey||(sr=!0)}function Ir(){sr=!1}function ad(){this.visibilityState==="hidden"&&qr&&(sr=!0)}function id(e){e.addEventListener("keydown",sd,!0),e.addEventListener("mousedown",Ir,!0),e.addEventListener("pointerdown",Ir,!0),e.addEventListener("touchstart",Ir,!0),e.addEventListener("visibilitychange",ad,!0)}function ld(e){const{target:t}=e;try{return t.matches(":focus-visible")}catch{}return sr||od(t)}function Va(){const e=M.useCallback(o=>{o!=null&&id(o.ownerDocument)},[]),t=M.useRef(!1);function n(){return t.current?(qr=!0,nd.start(100,()=>{qr=!1}),t.current=!1,!0):!1}function r(o){return ld(o)?(t.current=!0,!0):!1}return{isFocusVisibleRef:t,onFocus:r,onBlur:n,ref:e}}function La(e,t){const n=O({},t);return Object.keys(e).forEach(r=>{if(r.toString().match(/^(components|slots)$/))n[r]=O({},e[r],n[r]);else if(r.toString().match(/^(componentsProps|slotProps)$/)){const o=e[r]||{},s=t[r];n[r]={},!s||!Object.keys(s)?n[r]=o:!o||!Object.keys(o)?n[r]=s:(n[r]=O({},s),Object.keys(o).forEach(i=>{n[r][i]=La(o[i],s[i])}))}else n[r]===void 0&&(n[r]=e[r])}),n}function mo(e,t,n=void 0){const r={};return Object.keys(e).forEach(o=>{r[o]=e[o].reduce((s,i)=>{if(i){const l=t(i);l!==""&&s.push(l),n&&n[i]&&s.push(n[i])}return s},[]).join(" ")}),r}const ms=e=>e,cd=()=>{let e=ms;return{configure(t){e=t},generate(t){return e(t)},reset(){e=ms}}},dd=cd(),Fa=dd,za={active:"active",checked:"checked",completed:"completed",disabled:"disabled",error:"error",expanded:"expanded",focused:"focused",focusVisible:"focusVisible",open:"open",readOnly:"readOnly",required:"required",selected:"selected"};function ar(e,t,n="Mui"){const r=za[t];return r?`${n}-${r}`:`${Fa.generate(e)}-${t}`}function Ga(e,t,n="Mui"){const r={};return t.forEach(o=>{r[o]=ar(e,o,n)}),r}function ud(e,t=Number.MIN_SAFE_INTEGER,n=Number.MAX_SAFE_INTEGER){return Math.max(t,Math.min(e,n))}function xe(e,t){if(e==null)return{};var n={},r=Object.keys(e),o,s;for(s=0;s=0)&&(n[o]=e[o]);return n}const pd=["values","unit","step"],wd=e=>{const t=Object.keys(e).map(n=>({key:n,val:e[n]}))||[];return t.sort((n,r)=>n.val-r.val),t.reduce((n,r)=>O({},n,{[r.key]:r.val}),{})};function fd(e){const{values:t={xs:0,sm:600,md:900,lg:1200,xl:1536},unit:n="px",step:r=5}=e,o=xe(e,pd),s=wd(t),i=Object.keys(s);function l(w){return`@media (min-width:${typeof t[w]=="number"?t[w]:w}${n})`}function c(w){return`@media (max-width:${(typeof t[w]=="number"?t[w]:w)-r/100}${n})`}function d(w,b){const y=i.indexOf(b);return`@media (min-width:${typeof t[w]=="number"?t[w]:w}${n}) and (max-width:${(y!==-1&&typeof t[i[y]]=="number"?t[i[y]]:b)-r/100}${n})`}function u(w){return i.indexOf(w)+1`@media (min-width:${ho[e]}px)`};function et(e,t,n){const r=e.theme||{};if(Array.isArray(t)){const s=r.breakpoints||hs;return t.reduce((i,l,c)=>(i[s.up(s.keys[c])]=n(t[c]),i),{})}if(typeof t=="object"){const s=r.breakpoints||hs;return Object.keys(t).reduce((i,l)=>{if(Object.keys(s.values||ho).indexOf(l)!==-1){const c=s.up(l);i[c]=n(t[l],l)}else{const c=l;i[c]=t[c]}return i},{})}return n(t)}function bd(e={}){var t;return((t=e.keys)==null?void 0:t.reduce((r,o)=>{const s=e.up(o);return r[s]={},r},{}))||{}}function vd(e,t){return e.reduce((n,r)=>{const o=n[r];return(!o||Object.keys(o).length===0)&&delete n[r],n},t)}function ir(e,t,n=!0){if(!t||typeof t!="string")return null;if(e&&e.vars&&n){const r=`vars.${t}`.split(".").reduce((o,s)=>o&&o[s]?o[s]:null,e);if(r!=null)return r}return t.split(".").reduce((r,o)=>r&&r[o]!=null?r[o]:null,e)}function Yn(e,t,n,r=n){let o;return typeof e=="function"?o=e(n):Array.isArray(e)?o=e[n]||r:o=ir(e,n)||r,t&&(o=t(o,r,e)),o}function be(e){const{prop:t,cssProperty:n=e.prop,themeKey:r,transform:o}=e,s=i=>{if(i[t]==null)return null;const l=i[t],c=i.theme,d=ir(c,r)||{};return et(i,l,m=>{let w=Yn(d,o,m);return m===w&&typeof m=="string"&&(w=Yn(d,o,`${t}${m==="default"?"":Ye(m)}`,m)),n===!1?w:{[n]:w}})};return s.propTypes=process.env.NODE_ENV!=="production"?{[t]:at}:{},s.filterProps=[t],s}function yd(e){const t={};return n=>(t[n]===void 0&&(t[n]=e(n)),t[n])}const xd={m:"margin",p:"padding"},Nd={t:"Top",r:"Right",b:"Bottom",l:"Left",x:["Left","Right"],y:["Top","Bottom"]},gs={marginX:"mx",marginY:"my",paddingX:"px",paddingY:"py"},kd=yd(e=>{if(e.length>2)if(gs[e])e=gs[e];else return[e];const[t,n]=e.split(""),r=xd[t],o=Nd[n]||"";return Array.isArray(o)?o.map(s=>r+s):[r+o]}),lr=["m","mt","mr","mb","ml","mx","my","margin","marginTop","marginRight","marginBottom","marginLeft","marginX","marginY","marginInline","marginInlineStart","marginInlineEnd","marginBlock","marginBlockStart","marginBlockEnd"],cr=["p","pt","pr","pb","pl","px","py","padding","paddingTop","paddingRight","paddingBottom","paddingLeft","paddingX","paddingY","paddingInline","paddingInlineStart","paddingInlineEnd","paddingBlock","paddingBlockStart","paddingBlockEnd"],Ed=[...lr,...cr];function jn(e,t,n,r){var o;const s=(o=ir(e,t,!1))!=null?o:n;return typeof s=="number"?i=>typeof i=="string"?i:(process.env.NODE_ENV!=="production"&&typeof i!="number"&&console.error(`MUI: Expected ${r} argument to be a number or a string, got ${i}.`),s*i):Array.isArray(s)?i=>typeof i=="string"?i:(process.env.NODE_ENV!=="production"&&(Number.isInteger(i)?i>s.length-1&&console.error([`MUI: The value provided (${i}) overflows.`,`The supported values are: ${JSON.stringify(s)}.`,`${i} > ${s.length-1}, you need to add the missing values.`].join(` +`))},[JSON.stringify(t)])}const c=M.useCallback(d=>{o||i(d)},[]);return[l,c]}function Wr(e){const t=M.useRef(e);return Lt(()=>{t.current=e}),M.useRef((...n)=>(0,t.current)(...n)).current}function yt(...e){return M.useMemo(()=>e.every(t=>t==null)?null:t=>{e.forEach(n=>{Kn(n,t)})},e)}const ka={};function Kd(e,t){const n=M.useRef(ka);return n.current===ka&&(n.current=e(t)),n}const Jd=[];function Zd(e){M.useEffect(e,Jd)}class On{constructor(){this.currentId=null,this.clear=()=>{this.currentId!==null&&(clearTimeout(this.currentId),this.currentId=null)},this.disposeEffect=()=>this.clear}static create(){return new On}start(t,n){this.clear(),this.currentId=setTimeout(()=>{this.currentId=null,n()},t)}}function dn(){const e=Kd(On.create).current;return Zd(e.disposeEffect),e}let cr=!0,Kr=!1;const Qd=new On,eu={text:!0,search:!0,url:!0,tel:!0,email:!0,password:!0,number:!0,date:!0,month:!0,week:!0,time:!0,datetime:!0,"datetime-local":!0};function tu(e){const{type:t,tagName:n}=e;return!!(n==="INPUT"&&eu[t]&&!e.readOnly||n==="TEXTAREA"&&!e.readOnly||e.isContentEditable)}function nu(e){e.metaKey||e.altKey||e.ctrlKey||(cr=!0)}function Br(){cr=!1}function ru(){this.visibilityState==="hidden"&&Kr&&(cr=!0)}function ou(e){e.addEventListener("keydown",nu,!0),e.addEventListener("mousedown",Br,!0),e.addEventListener("pointerdown",Br,!0),e.addEventListener("touchstart",Br,!0),e.addEventListener("visibilitychange",ru,!0)}function au(e){const{target:t}=e;try{return t.matches(":focus-visible")}catch{}return cr||tu(t)}function ui(){const e=M.useCallback(o=>{o!=null&&ou(o.ownerDocument)},[]),t=M.useRef(!1);function n(){return t.current?(Kr=!0,Qd.start(100,()=>{Kr=!1}),t.current=!1,!0):!1}function r(o){return au(o)?(t.current=!0,!0):!1}return{isFocusVisibleRef:t,onFocus:r,onBlur:n,ref:e}}function pi(e,t){const n=O({},t);return Object.keys(e).forEach(r=>{if(r.toString().match(/^(components|slots)$/))n[r]=O({},e[r],n[r]);else if(r.toString().match(/^(componentsProps|slotProps)$/)){const o=e[r]||{},s=t[r];n[r]={},!s||!Object.keys(s)?n[r]=o:!o||!Object.keys(o)?n[r]=s:(n[r]=O({},s),Object.keys(o).forEach(i=>{n[r][i]=pi(o[i],s[i])}))}else n[r]===void 0&&(n[r]=e[r])}),n}function ko(e,t,n=void 0){const r={};return Object.keys(e).forEach(o=>{r[o]=e[o].reduce((s,i)=>{if(i){const l=t(i);l!==""&&s.push(l),n&&n[i]&&s.push(n[i])}return s},[]).join(" ")}),r}const Sa=e=>e,su=()=>{let e=Sa;return{configure(t){e=t},generate(t){return e(t)},reset(){e=Sa}}},iu=su(),wi=iu,fi={active:"active",checked:"checked",completed:"completed",disabled:"disabled",error:"error",expanded:"expanded",focused:"focused",focusVisible:"focusVisible",open:"open",readOnly:"readOnly",required:"required",selected:"selected"};function dr(e,t,n="Mui"){const r=fi[t];return r?`${n}-${r}`:`${wi.generate(e)}-${t}`}function mi(e,t,n="Mui"){const r={};return t.forEach(o=>{r[o]=dr(e,o,n)}),r}function lu(e,t=Number.MIN_SAFE_INTEGER,n=Number.MAX_SAFE_INTEGER){return Math.max(t,Math.min(e,n))}function Ne(e,t){if(e==null)return{};var n={},r=Object.keys(e),o,s;for(s=0;s=0)&&(n[o]=e[o]);return n}const cu=["values","unit","step"],du=e=>{const t=Object.keys(e).map(n=>({key:n,val:e[n]}))||[];return t.sort((n,r)=>n.val-r.val),t.reduce((n,r)=>O({},n,{[r.key]:r.val}),{})};function uu(e){const{values:t={xs:0,sm:600,md:900,lg:1200,xl:1536},unit:n="px",step:r=5}=e,o=Ne(e,cu),s=du(t),i=Object.keys(s);function l(w){return`@media (min-width:${typeof t[w]=="number"?t[w]:w}${n})`}function c(w){return`@media (max-width:${(typeof t[w]=="number"?t[w]:w)-r/100}${n})`}function d(w,b){const x=i.indexOf(b);return`@media (min-width:${typeof t[w]=="number"?t[w]:w}${n}) and (max-width:${(x!==-1&&typeof t[i[x]]=="number"?t[i[x]]:b)-r/100}${n})`}function u(w){return i.indexOf(w)+1`@media (min-width:${So[e]}px)`};function et(e,t,n){const r=e.theme||{};if(Array.isArray(t)){const s=r.breakpoints||Ea;return t.reduce((i,l,c)=>(i[s.up(s.keys[c])]=n(t[c]),i),{})}if(typeof t=="object"){const s=r.breakpoints||Ea;return Object.keys(t).reduce((i,l)=>{if(Object.keys(s.values||So).indexOf(l)!==-1){const c=s.up(l);i[c]=n(t[l],l)}else{const c=l;i[c]=t[c]}return i},{})}return n(t)}function mu(e={}){var t;return((t=e.keys)==null?void 0:t.reduce((r,o)=>{const s=e.up(o);return r[s]={},r},{}))||{}}function hu(e,t){return e.reduce((n,r)=>{const o=n[r];return(!o||Object.keys(o).length===0)&&delete n[r],n},t)}function ur(e,t,n=!0){if(!t||typeof t!="string")return null;if(e&&e.vars&&n){const r=`vars.${t}`.split(".").reduce((o,s)=>o&&o[s]?o[s]:null,e);if(r!=null)return r}return t.split(".").reduce((r,o)=>r&&r[o]!=null?r[o]:null,e)}function Jn(e,t,n,r=n){let o;return typeof e=="function"?o=e(n):Array.isArray(e)?o=e[n]||r:o=ur(e,n)||r,t&&(o=t(o,r,e)),o}function ve(e){const{prop:t,cssProperty:n=e.prop,themeKey:r,transform:o}=e,s=i=>{if(i[t]==null)return null;const l=i[t],c=i.theme,d=ur(c,r)||{};return et(i,l,m=>{let w=Jn(d,o,m);return m===w&&typeof m=="string"&&(w=Jn(d,o,`${t}${m==="default"?"":Ye(m)}`,m)),n===!1?w:{[n]:w}})};return s.propTypes=process.env.NODE_ENV!=="production"?{[t]:st}:{},s.filterProps=[t],s}function gu(e){const t={};return n=>(t[n]===void 0&&(t[n]=e(n)),t[n])}const bu={m:"margin",p:"padding"},vu={t:"Top",r:"Right",b:"Bottom",l:"Left",x:["Left","Right"],y:["Top","Bottom"]},ja={marginX:"mx",marginY:"my",paddingX:"px",paddingY:"py"},xu=gu(e=>{if(e.length>2)if(ja[e])e=ja[e];else return[e];const[t,n]=e.split(""),r=bu[t],o=vu[n]||"";return Array.isArray(o)?o.map(s=>r+s):[r+o]}),pr=["m","mt","mr","mb","ml","mx","my","margin","marginTop","marginRight","marginBottom","marginLeft","marginX","marginY","marginInline","marginInlineStart","marginInlineEnd","marginBlock","marginBlockStart","marginBlockEnd"],wr=["p","pt","pr","pb","pl","px","py","padding","paddingTop","paddingRight","paddingBottom","paddingLeft","paddingX","paddingY","paddingInline","paddingInlineStart","paddingInlineEnd","paddingBlock","paddingBlockStart","paddingBlockEnd"],yu=[...pr,...wr];function _n(e,t,n,r){var o;const s=(o=ur(e,t,!1))!=null?o:n;return typeof s=="number"?i=>typeof i=="string"?i:(process.env.NODE_ENV!=="production"&&typeof i!="number"&&console.error(`MUI: Expected ${r} argument to be a number or a string, got ${i}.`),s*i):Array.isArray(s)?i=>typeof i=="string"?i:(process.env.NODE_ENV!=="production"&&(Number.isInteger(i)?i>s.length-1&&console.error([`MUI: The value provided (${i}) overflows.`,`The supported values are: ${JSON.stringify(s)}.`,`${i} > ${s.length-1}, you need to add the missing values.`].join(` `)):console.error([`MUI: The \`theme.${t}\` array type cannot be combined with non integer values.You should either use an integer value that can be used as index, or define the \`theme.${t}\` as a number.`].join(` `))),s[i]):typeof s=="function"?s:(process.env.NODE_ENV!=="production"&&console.error([`MUI: The \`theme.${t}\` value (${s}) is invalid.`,"It should be a number, an array or a function."].join(` -`)),()=>{})}function Ua(e){return jn(e,"spacing",8,"spacing")}function On(e,t){if(typeof t=="string"||t==null)return t;const n=Math.abs(t),r=e(n);return t>=0?r:typeof r=="number"?-r:`-${r}`}function Sd(e,t){return n=>e.reduce((r,o)=>(r[o]=On(t,n),r),{})}function Td(e,t,n,r){if(t.indexOf(n)===-1)return null;const o=kd(n),s=Sd(o,r),i=e[n];return et(e,i,s)}function qa(e,t){const n=Ua(e.theme);return Object.keys(e).map(r=>Td(e,t,r,n)).reduce(wn,{})}function fe(e){return qa(e,lr)}fe.propTypes=process.env.NODE_ENV!=="production"?lr.reduce((e,t)=>(e[t]=at,e),{}):{};fe.filterProps=lr;function me(e){return qa(e,cr)}me.propTypes=process.env.NODE_ENV!=="production"?cr.reduce((e,t)=>(e[t]=at,e),{}):{};me.filterProps=cr;process.env.NODE_ENV!=="production"&&Ed.reduce((e,t)=>(e[t]=at,e),{});function Cd(e=8){if(e.mui)return e;const t=Ua({spacing:e}),n=(...r)=>(process.env.NODE_ENV!=="production"&&(r.length<=4||console.error(`MUI: Too many arguments provided, expected between 0 and 4, got ${r.length}`)),(r.length===0?[1]:r).map(s=>{const i=t(s);return typeof i=="number"?`${i}px`:i}).join(" "));return n.mui=!0,n}function dr(...e){const t=e.reduce((r,o)=>(o.filterProps.forEach(s=>{r[s]=o}),r),{}),n=r=>Object.keys(r).reduce((o,s)=>t[s]?wn(o,t[s](r)):o,{});return n.propTypes=process.env.NODE_ENV!=="production"?e.reduce((r,o)=>Object.assign(r,o.propTypes),{}):{},n.filterProps=e.reduce((r,o)=>r.concat(o.filterProps),[]),n}function Ae(e){return typeof e!="number"?e:`${e}px solid`}function Fe(e,t){return be({prop:e,themeKey:"borders",transform:t})}const jd=Fe("border",Ae),Od=Fe("borderTop",Ae),Rd=Fe("borderRight",Ae),Pd=Fe("borderBottom",Ae),_d=Fe("borderLeft",Ae),Id=Fe("borderColor"),$d=Fe("borderTopColor"),Md=Fe("borderRightColor"),Dd=Fe("borderBottomColor"),Ad=Fe("borderLeftColor"),Bd=Fe("outline",Ae),Vd=Fe("outlineColor"),ur=e=>{if(e.borderRadius!==void 0&&e.borderRadius!==null){const t=jn(e.theme,"shape.borderRadius",4,"borderRadius"),n=r=>({borderRadius:On(t,r)});return et(e,e.borderRadius,n)}return null};ur.propTypes=process.env.NODE_ENV!=="production"?{borderRadius:at}:{};ur.filterProps=["borderRadius"];dr(jd,Od,Rd,Pd,_d,Id,$d,Md,Dd,Ad,ur,Bd,Vd);const pr=e=>{if(e.gap!==void 0&&e.gap!==null){const t=jn(e.theme,"spacing",8,"gap"),n=r=>({gap:On(t,r)});return et(e,e.gap,n)}return null};pr.propTypes=process.env.NODE_ENV!=="production"?{gap:at}:{};pr.filterProps=["gap"];const wr=e=>{if(e.columnGap!==void 0&&e.columnGap!==null){const t=jn(e.theme,"spacing",8,"columnGap"),n=r=>({columnGap:On(t,r)});return et(e,e.columnGap,n)}return null};wr.propTypes=process.env.NODE_ENV!=="production"?{columnGap:at}:{};wr.filterProps=["columnGap"];const fr=e=>{if(e.rowGap!==void 0&&e.rowGap!==null){const t=jn(e.theme,"spacing",8,"rowGap"),n=r=>({rowGap:On(t,r)});return et(e,e.rowGap,n)}return null};fr.propTypes=process.env.NODE_ENV!=="production"?{rowGap:at}:{};fr.filterProps=["rowGap"];const Ld=be({prop:"gridColumn"}),Fd=be({prop:"gridRow"}),zd=be({prop:"gridAutoFlow"}),Gd=be({prop:"gridAutoColumns"}),Ud=be({prop:"gridAutoRows"}),qd=be({prop:"gridTemplateColumns"}),Hd=be({prop:"gridTemplateRows"}),Xd=be({prop:"gridTemplateAreas"}),Yd=be({prop:"gridArea"});dr(pr,wr,fr,Ld,Fd,zd,Gd,Ud,qd,Hd,Xd,Yd);function Mt(e,t){return t==="grey"?t:e}const Wd=be({prop:"color",themeKey:"palette",transform:Mt}),Kd=be({prop:"bgcolor",cssProperty:"backgroundColor",themeKey:"palette",transform:Mt}),Jd=be({prop:"backgroundColor",themeKey:"palette",transform:Mt});dr(Wd,Kd,Jd);function _e(e){return e<=1&&e!==0?`${e*100}%`:e}const Zd=be({prop:"width",transform:_e}),go=e=>{if(e.maxWidth!==void 0&&e.maxWidth!==null){const t=n=>{var r,o;const s=((r=e.theme)==null||(r=r.breakpoints)==null||(r=r.values)==null?void 0:r[n])||ho[n];return s?((o=e.theme)==null||(o=o.breakpoints)==null?void 0:o.unit)!=="px"?{maxWidth:`${s}${e.theme.breakpoints.unit}`}:{maxWidth:s}:{maxWidth:_e(n)}};return et(e,e.maxWidth,t)}return null};go.filterProps=["maxWidth"];const Qd=be({prop:"minWidth",transform:_e}),eu=be({prop:"height",transform:_e}),tu=be({prop:"maxHeight",transform:_e}),nu=be({prop:"minHeight",transform:_e});be({prop:"size",cssProperty:"width",transform:_e});be({prop:"size",cssProperty:"height",transform:_e});const ru=be({prop:"boxSizing"});dr(Zd,go,Qd,eu,tu,nu,ru);const ou={border:{themeKey:"borders",transform:Ae},borderTop:{themeKey:"borders",transform:Ae},borderRight:{themeKey:"borders",transform:Ae},borderBottom:{themeKey:"borders",transform:Ae},borderLeft:{themeKey:"borders",transform:Ae},borderColor:{themeKey:"palette"},borderTopColor:{themeKey:"palette"},borderRightColor:{themeKey:"palette"},borderBottomColor:{themeKey:"palette"},borderLeftColor:{themeKey:"palette"},outline:{themeKey:"borders",transform:Ae},outlineColor:{themeKey:"palette"},borderRadius:{themeKey:"shape.borderRadius",style:ur},color:{themeKey:"palette",transform:Mt},bgcolor:{themeKey:"palette",cssProperty:"backgroundColor",transform:Mt},backgroundColor:{themeKey:"palette",transform:Mt},p:{style:me},pt:{style:me},pr:{style:me},pb:{style:me},pl:{style:me},px:{style:me},py:{style:me},padding:{style:me},paddingTop:{style:me},paddingRight:{style:me},paddingBottom:{style:me},paddingLeft:{style:me},paddingX:{style:me},paddingY:{style:me},paddingInline:{style:me},paddingInlineStart:{style:me},paddingInlineEnd:{style:me},paddingBlock:{style:me},paddingBlockStart:{style:me},paddingBlockEnd:{style:me},m:{style:fe},mt:{style:fe},mr:{style:fe},mb:{style:fe},ml:{style:fe},mx:{style:fe},my:{style:fe},margin:{style:fe},marginTop:{style:fe},marginRight:{style:fe},marginBottom:{style:fe},marginLeft:{style:fe},marginX:{style:fe},marginY:{style:fe},marginInline:{style:fe},marginInlineStart:{style:fe},marginInlineEnd:{style:fe},marginBlock:{style:fe},marginBlockStart:{style:fe},marginBlockEnd:{style:fe},displayPrint:{cssProperty:!1,transform:e=>({"@media print":{display:e}})},display:{},overflow:{},textOverflow:{},visibility:{},whiteSpace:{},flexBasis:{},flexDirection:{},flexWrap:{},justifyContent:{},alignItems:{},alignContent:{},order:{},flex:{},flexGrow:{},flexShrink:{},alignSelf:{},justifyItems:{},justifySelf:{},gap:{style:pr},rowGap:{style:fr},columnGap:{style:wr},gridColumn:{},gridRow:{},gridAutoFlow:{},gridAutoColumns:{},gridAutoRows:{},gridTemplateColumns:{},gridTemplateRows:{},gridTemplateAreas:{},gridArea:{},position:{},zIndex:{themeKey:"zIndex"},top:{},right:{},bottom:{},left:{},boxShadow:{themeKey:"shadows"},width:{transform:_e},maxWidth:{style:go},minWidth:{transform:_e},height:{transform:_e},maxHeight:{transform:_e},minHeight:{transform:_e},boxSizing:{},fontFamily:{themeKey:"typography"},fontSize:{themeKey:"typography"},fontStyle:{themeKey:"typography"},fontWeight:{themeKey:"typography"},letterSpacing:{},textTransform:{},lineHeight:{},textAlign:{},typography:{cssProperty:!1,themeKey:"typography"}},bo=ou;function su(...e){const t=e.reduce((r,o)=>r.concat(Object.keys(o)),[]),n=new Set(t);return e.every(r=>n.size===Object.keys(r).length)}function au(e,t){return typeof e=="function"?e(t):e}function iu(){function e(n,r,o,s){const i={[n]:r,theme:o},l=s[n];if(!l)return{[n]:r};const{cssProperty:c=n,themeKey:d,transform:u,style:m}=l;if(r==null)return null;if(d==="typography"&&r==="inherit")return{[n]:r};const w=ir(o,d)||{};return m?m(i):et(i,r,y=>{let f=Yn(w,u,y);return y===f&&typeof y=="string"&&(f=Yn(w,u,`${n}${y==="default"?"":Ye(y)}`,y)),c===!1?f:{[c]:f}})}function t(n){var r;const{sx:o,theme:s={}}=n||{};if(!o)return null;const i=(r=s.unstable_sxConfig)!=null?r:bo;function l(c){let d=c;if(typeof c=="function")d=c(s);else if(typeof c!="object")return c;if(!d)return null;const u=bd(s.breakpoints),m=Object.keys(u);let w=u;return Object.keys(d).forEach(b=>{const y=au(d[b],s);if(y!=null)if(typeof y=="object")if(i[b])w=wn(w,e(b,y,s,i));else{const f=et({theme:s},y,h=>({[b]:h}));su(f,y)?w[b]=t({sx:y,theme:s}):w=wn(w,f)}else w=wn(w,e(b,y,s,i))}),vd(m,w)}return Array.isArray(o)?o.map(l):l(o)}return t}const Ha=iu();Ha.filterProps=["sx"];const vo=Ha;function lu(e,t){const n=this;return n.vars&&typeof n.getColorSchemeSelector=="function"?{[n.getColorSchemeSelector(e).replace(/(\[[^\]]+\])/,"*:where($1)")]:t}:n.palette.mode===e?t:{}}const cu=["breakpoints","palette","spacing","shape"];function yo(e={},...t){const{breakpoints:n={},palette:r={},spacing:o,shape:s={}}=e,i=xe(e,cu),l=fd(n),c=Cd(o);let d=Qe({breakpoints:l,direction:"ltr",components:{},palette:O({mode:"light"},r),spacing:c,shape:O({},hd,s)},i);return d.applyStyles=lu,d=t.reduce((u,m)=>Qe(u,m),d),d.unstable_sxConfig=O({},bo,i==null?void 0:i.unstable_sxConfig),d.unstable_sx=function(m){return vo({sx:m,theme:this})},d}function du(e){return Object.keys(e).length===0}function Xa(e=null){const t=M.useContext(Ar.ThemeContext);return!t||du(t)?e:t}const uu=yo();function Ya(e=uu){return Xa(e)}const pu=["ownerState"],wu=["variants"],fu=["name","slot","skipVariantsResolver","skipSx","overridesResolver"];function mu(e){return Object.keys(e).length===0}function hu(e){return typeof e=="string"&&e.charCodeAt(0)>96}function zn(e){return e!=="ownerState"&&e!=="theme"&&e!=="sx"&&e!=="as"}const gu=yo(),bs=e=>e&&e.charAt(0).toLowerCase()+e.slice(1);function Bn({defaultTheme:e,theme:t,themeId:n}){return mu(t)?e:t[n]||t}function bu(e){return e?(t,n)=>n[e]:null}function Gn(e,t){let{ownerState:n}=t,r=xe(t,pu);const o=typeof e=="function"?e(O({ownerState:n},r)):e;if(Array.isArray(o))return o.flatMap(s=>Gn(s,O({ownerState:n},r)));if(o&&typeof o=="object"&&Array.isArray(o.variants)){const{variants:s=[]}=o;let l=xe(o,wu);return s.forEach(c=>{let d=!0;typeof c.props=="function"?d=c.props(O({ownerState:n},r,n)):Object.keys(c.props).forEach(u=>{(n==null?void 0:n[u])!==c.props[u]&&r[u]!==c.props[u]&&(d=!1)}),d&&(Array.isArray(l)||(l=[l]),l.push(typeof c.style=="function"?c.style(O({ownerState:n},r,n)):c.style))}),l}return o}function vu(e={}){const{themeId:t,defaultTheme:n=gu,rootShouldForwardProp:r=zn,slotShouldForwardProp:o=zn}=e,s=i=>vo(O({},i,{theme:Bn(O({},i,{defaultTheme:n,themeId:t}))}));return s.__mui_systemSx=!0,(i,l={})=>{Ar.internal_processStyles(i,g=>g.filter(P=>!(P!=null&&P.__mui_systemSx)));const{name:c,slot:d,skipVariantsResolver:u,skipSx:m,overridesResolver:w=bu(bs(d))}=l,b=xe(l,fu),y=u!==void 0?u:d&&d!=="Root"&&d!=="root"||!1,f=m||!1;let h;process.env.NODE_ENV!=="production"&&c&&(h=`${c}-${bs(d||"Root")}`);let E=zn;d==="Root"||d==="root"?E=r:d?E=o:hu(i)&&(E=void 0);const I=Ar(i,O({shouldForwardProp:E,label:h},b)),j=g=>typeof g=="function"&&g.__emotion_real!==g||mt(g)?P=>Gn(g,O({},P,{theme:Bn({theme:P.theme,defaultTheme:n,themeId:t})})):g,k=(g,...P)=>{let V=j(g);const U=P?P.map(j):[];c&&w&&U.push(N=>{const D=Bn(O({},N,{defaultTheme:n,themeId:t}));if(!D.components||!D.components[c]||!D.components[c].styleOverrides)return null;const $=D.components[c].styleOverrides,J={};return Object.entries($).forEach(([Y,z])=>{J[Y]=Gn(z,O({},N,{theme:D}))}),w(N,J)}),c&&!y&&U.push(N=>{var D;const $=Bn(O({},N,{defaultTheme:n,themeId:t})),J=$==null||(D=$.components)==null||(D=D[c])==null?void 0:D.variants;return Gn({variants:J},O({},N,{theme:$}))}),f||U.push(s);const T=U.length-P.length;if(Array.isArray(g)&&T>0){const N=new Array(T).fill("");V=[...g,...N],V.raw=[...g.raw,...N]}const R=I(V,...U);if(process.env.NODE_ENV!=="production"){let N;c&&(N=`${c}${Ye(d||"")}`),N===void 0&&(N=`Styled(${zc(i)})`),R.displayName=N}return i.muiName&&(R.muiName=i.muiName),R};return I.withConfig&&(k.withConfig=I.withConfig),k}}function yu(e){const{theme:t,name:n,props:r}=e;return!t||!t.components||!t.components[n]||!t.components[n].defaultProps?r:La(t.components[n].defaultProps,r)}function xu({props:e,name:t,defaultTheme:n,themeId:r}){let o=Ya(n);return r&&(o=o[r]||o),yu({theme:o,name:t,props:e})}function xo(e,t=0,n=1){return process.env.NODE_ENV!=="production"&&(en)&&console.error(`MUI: The value provided ${e} is out of range [${t}, ${n}].`),ud(e,t,n)}function Nu(e){e=e.slice(1);const t=new RegExp(`.{1,${e.length>=6?2:1}}`,"g");let n=e.match(t);return n&&n[0].length===1&&(n=n.map(r=>r+r)),n?`rgb${n.length===4?"a":""}(${n.map((r,o)=>o<3?parseInt(r,16):Math.round(parseInt(r,16)/255*1e3)/1e3).join(", ")})`:""}function Nt(e){if(e.type)return e;if(e.charAt(0)==="#")return Nt(Nu(e));const t=e.indexOf("("),n=e.substring(0,t);if(["rgb","rgba","hsl","hsla","color"].indexOf(n)===-1)throw new Error(process.env.NODE_ENV!=="production"?`MUI: Unsupported \`${e}\` color. -The following formats are supported: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color().`:Vt(9,e));let r=e.substring(t+1,e.length-1),o;if(n==="color"){if(r=r.split(" "),o=r.shift(),r.length===4&&r[3].charAt(0)==="/"&&(r[3]=r[3].slice(1)),["srgb","display-p3","a98-rgb","prophoto-rgb","rec-2020"].indexOf(o)===-1)throw new Error(process.env.NODE_ENV!=="production"?`MUI: unsupported \`${o}\` color space. -The following color spaces are supported: srgb, display-p3, a98-rgb, prophoto-rgb, rec-2020.`:Vt(10,o))}else r=r.split(",");return r=r.map(s=>parseFloat(s)),{type:n,values:r,colorSpace:o}}function mr(e){const{type:t,colorSpace:n}=e;let{values:r}=e;return t.indexOf("rgb")!==-1?r=r.map((o,s)=>s<3?parseInt(o,10):o):t.indexOf("hsl")!==-1&&(r[1]=`${r[1]}%`,r[2]=`${r[2]}%`),t.indexOf("color")!==-1?r=`${n} ${r.join(" ")}`:r=`${r.join(", ")}`,`${t}(${r})`}function ku(e){e=Nt(e);const{values:t}=e,n=t[0],r=t[1]/100,o=t[2]/100,s=r*Math.min(o,1-o),i=(d,u=(d+n/30)%12)=>o-s*Math.max(Math.min(u-3,9-u,1),-1);let l="rgb";const c=[Math.round(i(0)*255),Math.round(i(8)*255),Math.round(i(4)*255)];return e.type==="hsla"&&(l+="a",c.push(t[3])),mr({type:l,values:c})}function vs(e){e=Nt(e);let t=e.type==="hsl"||e.type==="hsla"?Nt(ku(e)).values:e.values;return t=t.map(n=>(e.type!=="color"&&(n/=255),n<=.03928?n/12.92:((n+.055)/1.055)**2.4)),Number((.2126*t[0]+.7152*t[1]+.0722*t[2]).toFixed(3))}function ys(e,t){const n=vs(e),r=vs(t);return(Math.max(n,r)+.05)/(Math.min(n,r)+.05)}function Wa(e,t){return e=Nt(e),t=xo(t),(e.type==="rgb"||e.type==="hsl")&&(e.type+="a"),e.type==="color"?e.values[3]=`/${t}`:e.values[3]=t,mr(e)}function Eu(e,t){if(e=Nt(e),t=xo(t),e.type.indexOf("hsl")!==-1)e.values[2]*=1-t;else if(e.type.indexOf("rgb")!==-1||e.type.indexOf("color")!==-1)for(let n=0;n<3;n+=1)e.values[n]*=1-t;return mr(e)}function Su(e,t){if(e=Nt(e),t=xo(t),e.type.indexOf("hsl")!==-1)e.values[2]+=(100-e.values[2])*t;else if(e.type.indexOf("rgb")!==-1)for(let n=0;n<3;n+=1)e.values[n]+=(255-e.values[n])*t;else if(e.type.indexOf("color")!==-1)for(let n=0;n<3;n+=1)e.values[n]+=(1-e.values[n])*t;return mr(e)}function Tu(e,t){return O({toolbar:{minHeight:56,[e.up("xs")]:{"@media (orientation: landscape)":{minHeight:48}},[e.up("sm")]:{minHeight:64}}},t)}const Cu={black:"#000",white:"#fff"},vn=Cu,ju={50:"#fafafa",100:"#f5f5f5",200:"#eeeeee",300:"#e0e0e0",400:"#bdbdbd",500:"#9e9e9e",600:"#757575",700:"#616161",800:"#424242",900:"#212121",A100:"#f5f5f5",A200:"#eeeeee",A400:"#bdbdbd",A700:"#616161"},Ou=ju,Ru={50:"#f3e5f5",100:"#e1bee7",200:"#ce93d8",300:"#ba68c8",400:"#ab47bc",500:"#9c27b0",600:"#8e24aa",700:"#7b1fa2",800:"#6a1b9a",900:"#4a148c",A100:"#ea80fc",A200:"#e040fb",A400:"#d500f9",A700:"#aa00ff"},jt=Ru,Pu={50:"#ffebee",100:"#ffcdd2",200:"#ef9a9a",300:"#e57373",400:"#ef5350",500:"#f44336",600:"#e53935",700:"#d32f2f",800:"#c62828",900:"#b71c1c",A100:"#ff8a80",A200:"#ff5252",A400:"#ff1744",A700:"#d50000"},Ot=Pu,_u={50:"#fff3e0",100:"#ffe0b2",200:"#ffcc80",300:"#ffb74d",400:"#ffa726",500:"#ff9800",600:"#fb8c00",700:"#f57c00",800:"#ef6c00",900:"#e65100",A100:"#ffd180",A200:"#ffab40",A400:"#ff9100",A700:"#ff6d00"},nn=_u,Iu={50:"#e3f2fd",100:"#bbdefb",200:"#90caf9",300:"#64b5f6",400:"#42a5f5",500:"#2196f3",600:"#1e88e5",700:"#1976d2",800:"#1565c0",900:"#0d47a1",A100:"#82b1ff",A200:"#448aff",A400:"#2979ff",A700:"#2962ff"},Rt=Iu,$u={50:"#e1f5fe",100:"#b3e5fc",200:"#81d4fa",300:"#4fc3f7",400:"#29b6f6",500:"#03a9f4",600:"#039be5",700:"#0288d1",800:"#0277bd",900:"#01579b",A100:"#80d8ff",A200:"#40c4ff",A400:"#00b0ff",A700:"#0091ea"},Pt=$u,Mu={50:"#e8f5e9",100:"#c8e6c9",200:"#a5d6a7",300:"#81c784",400:"#66bb6a",500:"#4caf50",600:"#43a047",700:"#388e3c",800:"#2e7d32",900:"#1b5e20",A100:"#b9f6ca",A200:"#69f0ae",A400:"#00e676",A700:"#00c853"},_t=Mu,Du=["mode","contrastThreshold","tonalOffset"],xs={text:{primary:"rgba(0, 0, 0, 0.87)",secondary:"rgba(0, 0, 0, 0.6)",disabled:"rgba(0, 0, 0, 0.38)"},divider:"rgba(0, 0, 0, 0.12)",background:{paper:vn.white,default:vn.white},action:{active:"rgba(0, 0, 0, 0.54)",hover:"rgba(0, 0, 0, 0.04)",hoverOpacity:.04,selected:"rgba(0, 0, 0, 0.08)",selectedOpacity:.08,disabled:"rgba(0, 0, 0, 0.26)",disabledBackground:"rgba(0, 0, 0, 0.12)",disabledOpacity:.38,focus:"rgba(0, 0, 0, 0.12)",focusOpacity:.12,activatedOpacity:.12}},$r={text:{primary:vn.white,secondary:"rgba(255, 255, 255, 0.7)",disabled:"rgba(255, 255, 255, 0.5)",icon:"rgba(255, 255, 255, 0.5)"},divider:"rgba(255, 255, 255, 0.12)",background:{paper:"#121212",default:"#121212"},action:{active:vn.white,hover:"rgba(255, 255, 255, 0.08)",hoverOpacity:.08,selected:"rgba(255, 255, 255, 0.16)",selectedOpacity:.16,disabled:"rgba(255, 255, 255, 0.3)",disabledBackground:"rgba(255, 255, 255, 0.12)",disabledOpacity:.38,focus:"rgba(255, 255, 255, 0.12)",focusOpacity:.12,activatedOpacity:.24}};function Ns(e,t,n,r){const o=r.light||r,s=r.dark||r*1.5;e[t]||(e.hasOwnProperty(n)?e[t]=e[n]:t==="light"?e.light=Su(e.main,o):t==="dark"&&(e.dark=Eu(e.main,s)))}function Au(e="light"){return e==="dark"?{main:Rt[200],light:Rt[50],dark:Rt[400]}:{main:Rt[700],light:Rt[400],dark:Rt[800]}}function Bu(e="light"){return e==="dark"?{main:jt[200],light:jt[50],dark:jt[400]}:{main:jt[500],light:jt[300],dark:jt[700]}}function Vu(e="light"){return e==="dark"?{main:Ot[500],light:Ot[300],dark:Ot[700]}:{main:Ot[700],light:Ot[400],dark:Ot[800]}}function Lu(e="light"){return e==="dark"?{main:Pt[400],light:Pt[300],dark:Pt[700]}:{main:Pt[700],light:Pt[500],dark:Pt[900]}}function Fu(e="light"){return e==="dark"?{main:_t[400],light:_t[300],dark:_t[700]}:{main:_t[800],light:_t[500],dark:_t[900]}}function zu(e="light"){return e==="dark"?{main:nn[400],light:nn[300],dark:nn[700]}:{main:"#ed6c02",light:nn[500],dark:nn[900]}}function Gu(e){const{mode:t="light",contrastThreshold:n=3,tonalOffset:r=.2}=e,o=xe(e,Du),s=e.primary||Au(t),i=e.secondary||Bu(t),l=e.error||Vu(t),c=e.info||Lu(t),d=e.success||Fu(t),u=e.warning||zu(t);function m(f){const h=ys(f,$r.text.primary)>=n?$r.text.primary:xs.text.primary;if(process.env.NODE_ENV!=="production"){const E=ys(f,h);E<3&&console.error([`MUI: The contrast ratio of ${E}:1 for ${h} on ${f}`,"falls below the WCAG recommended absolute minimum contrast ratio of 3:1.","https://www.w3.org/TR/2008/REC-WCAG20-20081211/#visual-audio-contrast-contrast"].join(` -`))}return h}const w=({color:f,name:h,mainShade:E=500,lightShade:I=300,darkShade:j=700})=>{if(f=O({},f),!f.main&&f[E]&&(f.main=f[E]),!f.hasOwnProperty("main"))throw new Error(process.env.NODE_ENV!=="production"?`MUI: The color${h?` (${h})`:""} provided to augmentColor(color) is invalid. -The color object needs to have a \`main\` property or a \`${E}\` property.`:Vt(11,h?` (${h})`:"",E));if(typeof f.main!="string")throw new Error(process.env.NODE_ENV!=="production"?`MUI: The color${h?` (${h})`:""} provided to augmentColor(color) is invalid. +`)),()=>{})}function hi(e){return _n(e,"spacing",8,"spacing")}function Pn(e,t){if(typeof t=="string"||t==null)return t;const n=Math.abs(t),r=e(n);return t>=0?r:typeof r=="number"?-r:`-${r}`}function Nu(e,t){return n=>e.reduce((r,o)=>(r[o]=Pn(t,n),r),{})}function ku(e,t,n,r){if(t.indexOf(n)===-1)return null;const o=xu(n),s=Nu(o,r),i=e[n];return et(e,i,s)}function gi(e,t){const n=hi(e.theme);return Object.keys(e).map(r=>ku(e,t,r,n)).reduce(mn,{})}function me(e){return gi(e,pr)}me.propTypes=process.env.NODE_ENV!=="production"?pr.reduce((e,t)=>(e[t]=st,e),{}):{};me.filterProps=pr;function he(e){return gi(e,wr)}he.propTypes=process.env.NODE_ENV!=="production"?wr.reduce((e,t)=>(e[t]=st,e),{}):{};he.filterProps=wr;process.env.NODE_ENV!=="production"&&yu.reduce((e,t)=>(e[t]=st,e),{});function Su(e=8){if(e.mui)return e;const t=hi({spacing:e}),n=(...r)=>(process.env.NODE_ENV!=="production"&&(r.length<=4||console.error(`MUI: Too many arguments provided, expected between 0 and 4, got ${r.length}`)),(r.length===0?[1]:r).map(s=>{const i=t(s);return typeof i=="number"?`${i}px`:i}).join(" "));return n.mui=!0,n}function fr(...e){const t=e.reduce((r,o)=>(o.filterProps.forEach(s=>{r[s]=o}),r),{}),n=r=>Object.keys(r).reduce((o,s)=>t[s]?mn(o,t[s](r)):o,{});return n.propTypes=process.env.NODE_ENV!=="production"?e.reduce((r,o)=>Object.assign(r,o.propTypes),{}):{},n.filterProps=e.reduce((r,o)=>r.concat(o.filterProps),[]),n}function Be(e){return typeof e!="number"?e:`${e}px solid`}function Fe(e,t){return ve({prop:e,themeKey:"borders",transform:t})}const Eu=Fe("border",Be),ju=Fe("borderTop",Be),Tu=Fe("borderRight",Be),Cu=Fe("borderBottom",Be),Ru=Fe("borderLeft",Be),Ou=Fe("borderColor"),_u=Fe("borderTopColor"),Pu=Fe("borderRightColor"),Iu=Fe("borderBottomColor"),Mu=Fe("borderLeftColor"),$u=Fe("outline",Be),Du=Fe("outlineColor"),mr=e=>{if(e.borderRadius!==void 0&&e.borderRadius!==null){const t=_n(e.theme,"shape.borderRadius",4,"borderRadius"),n=r=>({borderRadius:Pn(t,r)});return et(e,e.borderRadius,n)}return null};mr.propTypes=process.env.NODE_ENV!=="production"?{borderRadius:st}:{};mr.filterProps=["borderRadius"];fr(Eu,ju,Tu,Cu,Ru,Ou,_u,Pu,Iu,Mu,mr,$u,Du);const hr=e=>{if(e.gap!==void 0&&e.gap!==null){const t=_n(e.theme,"spacing",8,"gap"),n=r=>({gap:Pn(t,r)});return et(e,e.gap,n)}return null};hr.propTypes=process.env.NODE_ENV!=="production"?{gap:st}:{};hr.filterProps=["gap"];const gr=e=>{if(e.columnGap!==void 0&&e.columnGap!==null){const t=_n(e.theme,"spacing",8,"columnGap"),n=r=>({columnGap:Pn(t,r)});return et(e,e.columnGap,n)}return null};gr.propTypes=process.env.NODE_ENV!=="production"?{columnGap:st}:{};gr.filterProps=["columnGap"];const br=e=>{if(e.rowGap!==void 0&&e.rowGap!==null){const t=_n(e.theme,"spacing",8,"rowGap"),n=r=>({rowGap:Pn(t,r)});return et(e,e.rowGap,n)}return null};br.propTypes=process.env.NODE_ENV!=="production"?{rowGap:st}:{};br.filterProps=["rowGap"];const Au=ve({prop:"gridColumn"}),Bu=ve({prop:"gridRow"}),Vu=ve({prop:"gridAutoFlow"}),zu=ve({prop:"gridAutoColumns"}),Lu=ve({prop:"gridAutoRows"}),Fu=ve({prop:"gridTemplateColumns"}),Gu=ve({prop:"gridTemplateRows"}),Uu=ve({prop:"gridTemplateAreas"}),qu=ve({prop:"gridArea"});fr(hr,gr,br,Au,Bu,Vu,zu,Lu,Fu,Gu,Uu,qu);function Dt(e,t){return t==="grey"?t:e}const Hu=ve({prop:"color",themeKey:"palette",transform:Dt}),Xu=ve({prop:"bgcolor",cssProperty:"backgroundColor",themeKey:"palette",transform:Dt}),Yu=ve({prop:"backgroundColor",themeKey:"palette",transform:Dt});fr(Hu,Xu,Yu);function Me(e){return e<=1&&e!==0?`${e*100}%`:e}const Wu=ve({prop:"width",transform:Me}),Eo=e=>{if(e.maxWidth!==void 0&&e.maxWidth!==null){const t=n=>{var r,o;const s=((r=e.theme)==null||(r=r.breakpoints)==null||(r=r.values)==null?void 0:r[n])||So[n];return s?((o=e.theme)==null||(o=o.breakpoints)==null?void 0:o.unit)!=="px"?{maxWidth:`${s}${e.theme.breakpoints.unit}`}:{maxWidth:s}:{maxWidth:Me(n)}};return et(e,e.maxWidth,t)}return null};Eo.filterProps=["maxWidth"];const Ku=ve({prop:"minWidth",transform:Me}),Ju=ve({prop:"height",transform:Me}),Zu=ve({prop:"maxHeight",transform:Me}),Qu=ve({prop:"minHeight",transform:Me});ve({prop:"size",cssProperty:"width",transform:Me});ve({prop:"size",cssProperty:"height",transform:Me});const ep=ve({prop:"boxSizing"});fr(Wu,Eo,Ku,Ju,Zu,Qu,ep);const tp={border:{themeKey:"borders",transform:Be},borderTop:{themeKey:"borders",transform:Be},borderRight:{themeKey:"borders",transform:Be},borderBottom:{themeKey:"borders",transform:Be},borderLeft:{themeKey:"borders",transform:Be},borderColor:{themeKey:"palette"},borderTopColor:{themeKey:"palette"},borderRightColor:{themeKey:"palette"},borderBottomColor:{themeKey:"palette"},borderLeftColor:{themeKey:"palette"},outline:{themeKey:"borders",transform:Be},outlineColor:{themeKey:"palette"},borderRadius:{themeKey:"shape.borderRadius",style:mr},color:{themeKey:"palette",transform:Dt},bgcolor:{themeKey:"palette",cssProperty:"backgroundColor",transform:Dt},backgroundColor:{themeKey:"palette",transform:Dt},p:{style:he},pt:{style:he},pr:{style:he},pb:{style:he},pl:{style:he},px:{style:he},py:{style:he},padding:{style:he},paddingTop:{style:he},paddingRight:{style:he},paddingBottom:{style:he},paddingLeft:{style:he},paddingX:{style:he},paddingY:{style:he},paddingInline:{style:he},paddingInlineStart:{style:he},paddingInlineEnd:{style:he},paddingBlock:{style:he},paddingBlockStart:{style:he},paddingBlockEnd:{style:he},m:{style:me},mt:{style:me},mr:{style:me},mb:{style:me},ml:{style:me},mx:{style:me},my:{style:me},margin:{style:me},marginTop:{style:me},marginRight:{style:me},marginBottom:{style:me},marginLeft:{style:me},marginX:{style:me},marginY:{style:me},marginInline:{style:me},marginInlineStart:{style:me},marginInlineEnd:{style:me},marginBlock:{style:me},marginBlockStart:{style:me},marginBlockEnd:{style:me},displayPrint:{cssProperty:!1,transform:e=>({"@media print":{display:e}})},display:{},overflow:{},textOverflow:{},visibility:{},whiteSpace:{},flexBasis:{},flexDirection:{},flexWrap:{},justifyContent:{},alignItems:{},alignContent:{},order:{},flex:{},flexGrow:{},flexShrink:{},alignSelf:{},justifyItems:{},justifySelf:{},gap:{style:hr},rowGap:{style:br},columnGap:{style:gr},gridColumn:{},gridRow:{},gridAutoFlow:{},gridAutoColumns:{},gridAutoRows:{},gridTemplateColumns:{},gridTemplateRows:{},gridTemplateAreas:{},gridArea:{},position:{},zIndex:{themeKey:"zIndex"},top:{},right:{},bottom:{},left:{},boxShadow:{themeKey:"shadows"},width:{transform:Me},maxWidth:{style:Eo},minWidth:{transform:Me},height:{transform:Me},maxHeight:{transform:Me},minHeight:{transform:Me},boxSizing:{},fontFamily:{themeKey:"typography"},fontSize:{themeKey:"typography"},fontStyle:{themeKey:"typography"},fontWeight:{themeKey:"typography"},letterSpacing:{},textTransform:{},lineHeight:{},textAlign:{},typography:{cssProperty:!1,themeKey:"typography"}},jo=tp;function np(...e){const t=e.reduce((r,o)=>r.concat(Object.keys(o)),[]),n=new Set(t);return e.every(r=>n.size===Object.keys(r).length)}function rp(e,t){return typeof e=="function"?e(t):e}function op(){function e(n,r,o,s){const i={[n]:r,theme:o},l=s[n];if(!l)return{[n]:r};const{cssProperty:c=n,themeKey:d,transform:u,style:m}=l;if(r==null)return null;if(d==="typography"&&r==="inherit")return{[n]:r};const w=ur(o,d)||{};return m?m(i):et(i,r,x=>{let f=Jn(w,u,x);return x===f&&typeof x=="string"&&(f=Jn(w,u,`${n}${x==="default"?"":Ye(x)}`,x)),c===!1?f:{[c]:f}})}function t(n){var r;const{sx:o,theme:s={}}=n||{};if(!o)return null;const i=(r=s.unstable_sxConfig)!=null?r:jo;function l(c){let d=c;if(typeof c=="function")d=c(s);else if(typeof c!="object")return c;if(!d)return null;const u=mu(s.breakpoints),m=Object.keys(u);let w=u;return Object.keys(d).forEach(b=>{const x=rp(d[b],s);if(x!=null)if(typeof x=="object")if(i[b])w=mn(w,e(b,x,s,i));else{const f=et({theme:s},x,h=>({[b]:h}));np(f,x)?w[b]=t({sx:x,theme:s}):w=mn(w,f)}else w=mn(w,e(b,x,s,i))}),hu(m,w)}return Array.isArray(o)?o.map(l):l(o)}return t}const bi=op();bi.filterProps=["sx"];const To=bi;function ap(e,t){const n=this;return n.vars&&typeof n.getColorSchemeSelector=="function"?{[n.getColorSchemeSelector(e).replace(/(\[[^\]]+\])/,"*:where($1)")]:t}:n.palette.mode===e?t:{}}const sp=["breakpoints","palette","spacing","shape"];function Co(e={},...t){const{breakpoints:n={},palette:r={},spacing:o,shape:s={}}=e,i=Ne(e,sp),l=uu(n),c=Su(o);let d=Qe({breakpoints:l,direction:"ltr",components:{},palette:O({mode:"light"},r),spacing:c,shape:O({},wu,s)},i);return d.applyStyles=ap,d=t.reduce((u,m)=>Qe(u,m),d),d.unstable_sxConfig=O({},jo,i==null?void 0:i.unstable_sxConfig),d.unstable_sx=function(m){return To({sx:m,theme:this})},d}function ip(e){return Object.keys(e).length===0}function vi(e=null){const t=M.useContext(Fr.ThemeContext);return!t||ip(t)?e:t}const lp=Co();function xi(e=lp){return vi(e)}const cp=["ownerState"],dp=["variants"],up=["name","slot","skipVariantsResolver","skipSx","overridesResolver"];function pp(e){return Object.keys(e).length===0}function wp(e){return typeof e=="string"&&e.charCodeAt(0)>96}function qn(e){return e!=="ownerState"&&e!=="theme"&&e!=="sx"&&e!=="as"}const fp=Co(),Ta=e=>e&&e.charAt(0).toLowerCase()+e.slice(1);function Ln({defaultTheme:e,theme:t,themeId:n}){return pp(t)?e:t[n]||t}function mp(e){return e?(t,n)=>n[e]:null}function Hn(e,t){let{ownerState:n}=t,r=Ne(t,cp);const o=typeof e=="function"?e(O({ownerState:n},r)):e;if(Array.isArray(o))return o.flatMap(s=>Hn(s,O({ownerState:n},r)));if(o&&typeof o=="object"&&Array.isArray(o.variants)){const{variants:s=[]}=o;let l=Ne(o,dp);return s.forEach(c=>{let d=!0;typeof c.props=="function"?d=c.props(O({ownerState:n},r,n)):Object.keys(c.props).forEach(u=>{(n==null?void 0:n[u])!==c.props[u]&&r[u]!==c.props[u]&&(d=!1)}),d&&(Array.isArray(l)||(l=[l]),l.push(typeof c.style=="function"?c.style(O({ownerState:n},r,n)):c.style))}),l}return o}function hp(e={}){const{themeId:t,defaultTheme:n=fp,rootShouldForwardProp:r=qn,slotShouldForwardProp:o=qn}=e,s=i=>To(O({},i,{theme:Ln(O({},i,{defaultTheme:n,themeId:t}))}));return s.__mui_systemSx=!0,(i,l={})=>{Fr.internal_processStyles(i,v=>v.filter(P=>!(P!=null&&P.__mui_systemSx)));const{name:c,slot:d,skipVariantsResolver:u,skipSx:m,overridesResolver:w=mp(Ta(d))}=l,b=Ne(l,up),x=u!==void 0?u:d&&d!=="Root"&&d!=="root"||!1,f=m||!1;let h;process.env.NODE_ENV!=="production"&&c&&(h=`${c}-${Ta(d||"Root")}`);let S=qn;d==="Root"||d==="root"?S=r:d?S=o:wp(i)&&(S=void 0);const R=Fr(i,O({shouldForwardProp:S,label:h},b)),j=v=>typeof v=="function"&&v.__emotion_real!==v||mt(v)?P=>Hn(v,O({},P,{theme:Ln({theme:P.theme,defaultTheme:n,themeId:t})})):v,E=(v,...P)=>{let V=j(v);const U=P?P.map(j):[];c&&w&&U.push(k=>{const D=Ln(O({},k,{defaultTheme:n,themeId:t}));if(!D.components||!D.components[c]||!D.components[c].styleOverrides)return null;const $=D.components[c].styleOverrides,J={};return Object.entries($).forEach(([Y,F])=>{J[Y]=Hn(F,O({},k,{theme:D}))}),w(k,J)}),c&&!x&&U.push(k=>{var D;const $=Ln(O({},k,{defaultTheme:n,themeId:t})),J=$==null||(D=$.components)==null||(D=D[c])==null?void 0:D.variants;return Hn({variants:J},O({},k,{theme:$}))}),f||U.push(s);const T=U.length-P.length;if(Array.isArray(v)&&T>0){const k=new Array(T).fill("");V=[...v,...k],V.raw=[...v.raw,...k]}const _=R(V,...U);if(process.env.NODE_ENV!=="production"){let k;c&&(k=`${c}${Ye(d||"")}`),k===void 0&&(k=`Styled(${Vd(i)})`),_.displayName=k}return i.muiName&&(_.muiName=i.muiName),_};return R.withConfig&&(E.withConfig=R.withConfig),E}}function gp(e){const{theme:t,name:n,props:r}=e;return!t||!t.components||!t.components[n]||!t.components[n].defaultProps?r:pi(t.components[n].defaultProps,r)}function bp({props:e,name:t,defaultTheme:n,themeId:r}){let o=xi(n);return r&&(o=o[r]||o),gp({theme:o,name:t,props:e})}function Ro(e,t=0,n=1){return process.env.NODE_ENV!=="production"&&(en)&&console.error(`MUI: The value provided ${e} is out of range [${t}, ${n}].`),lu(e,t,n)}function vp(e){e=e.slice(1);const t=new RegExp(`.{1,${e.length>=6?2:1}}`,"g");let n=e.match(t);return n&&n[0].length===1&&(n=n.map(r=>r+r)),n?`rgb${n.length===4?"a":""}(${n.map((r,o)=>o<3?parseInt(r,16):Math.round(parseInt(r,16)/255*1e3)/1e3).join(", ")})`:""}function Nt(e){if(e.type)return e;if(e.charAt(0)==="#")return Nt(vp(e));const t=e.indexOf("("),n=e.substring(0,t);if(["rgb","rgba","hsl","hsla","color"].indexOf(n)===-1)throw new Error(process.env.NODE_ENV!=="production"?`MUI: Unsupported \`${e}\` color. +The following formats are supported: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color().`:zt(9,e));let r=e.substring(t+1,e.length-1),o;if(n==="color"){if(r=r.split(" "),o=r.shift(),r.length===4&&r[3].charAt(0)==="/"&&(r[3]=r[3].slice(1)),["srgb","display-p3","a98-rgb","prophoto-rgb","rec-2020"].indexOf(o)===-1)throw new Error(process.env.NODE_ENV!=="production"?`MUI: unsupported \`${o}\` color space. +The following color spaces are supported: srgb, display-p3, a98-rgb, prophoto-rgb, rec-2020.`:zt(10,o))}else r=r.split(",");return r=r.map(s=>parseFloat(s)),{type:n,values:r,colorSpace:o}}function vr(e){const{type:t,colorSpace:n}=e;let{values:r}=e;return t.indexOf("rgb")!==-1?r=r.map((o,s)=>s<3?parseInt(o,10):o):t.indexOf("hsl")!==-1&&(r[1]=`${r[1]}%`,r[2]=`${r[2]}%`),t.indexOf("color")!==-1?r=`${n} ${r.join(" ")}`:r=`${r.join(", ")}`,`${t}(${r})`}function xp(e){e=Nt(e);const{values:t}=e,n=t[0],r=t[1]/100,o=t[2]/100,s=r*Math.min(o,1-o),i=(d,u=(d+n/30)%12)=>o-s*Math.max(Math.min(u-3,9-u,1),-1);let l="rgb";const c=[Math.round(i(0)*255),Math.round(i(8)*255),Math.round(i(4)*255)];return e.type==="hsla"&&(l+="a",c.push(t[3])),vr({type:l,values:c})}function Ca(e){e=Nt(e);let t=e.type==="hsl"||e.type==="hsla"?Nt(xp(e)).values:e.values;return t=t.map(n=>(e.type!=="color"&&(n/=255),n<=.03928?n/12.92:((n+.055)/1.055)**2.4)),Number((.2126*t[0]+.7152*t[1]+.0722*t[2]).toFixed(3))}function Ra(e,t){const n=Ca(e),r=Ca(t);return(Math.max(n,r)+.05)/(Math.min(n,r)+.05)}function yi(e,t){return e=Nt(e),t=Ro(t),(e.type==="rgb"||e.type==="hsl")&&(e.type+="a"),e.type==="color"?e.values[3]=`/${t}`:e.values[3]=t,vr(e)}function yp(e,t){if(e=Nt(e),t=Ro(t),e.type.indexOf("hsl")!==-1)e.values[2]*=1-t;else if(e.type.indexOf("rgb")!==-1||e.type.indexOf("color")!==-1)for(let n=0;n<3;n+=1)e.values[n]*=1-t;return vr(e)}function Np(e,t){if(e=Nt(e),t=Ro(t),e.type.indexOf("hsl")!==-1)e.values[2]+=(100-e.values[2])*t;else if(e.type.indexOf("rgb")!==-1)for(let n=0;n<3;n+=1)e.values[n]+=(255-e.values[n])*t;else if(e.type.indexOf("color")!==-1)for(let n=0;n<3;n+=1)e.values[n]+=(1-e.values[n])*t;return vr(e)}function kp(e,t){return O({toolbar:{minHeight:56,[e.up("xs")]:{"@media (orientation: landscape)":{minHeight:48}},[e.up("sm")]:{minHeight:64}}},t)}const Sp={black:"#000",white:"#fff"},yn=Sp,Ep={50:"#fafafa",100:"#f5f5f5",200:"#eeeeee",300:"#e0e0e0",400:"#bdbdbd",500:"#9e9e9e",600:"#757575",700:"#616161",800:"#424242",900:"#212121",A100:"#f5f5f5",A200:"#eeeeee",A400:"#bdbdbd",A700:"#616161"},jp=Ep,Tp={50:"#f3e5f5",100:"#e1bee7",200:"#ce93d8",300:"#ba68c8",400:"#ab47bc",500:"#9c27b0",600:"#8e24aa",700:"#7b1fa2",800:"#6a1b9a",900:"#4a148c",A100:"#ea80fc",A200:"#e040fb",A400:"#d500f9",A700:"#aa00ff"},Rt=Tp,Cp={50:"#ffebee",100:"#ffcdd2",200:"#ef9a9a",300:"#e57373",400:"#ef5350",500:"#f44336",600:"#e53935",700:"#d32f2f",800:"#c62828",900:"#b71c1c",A100:"#ff8a80",A200:"#ff5252",A400:"#ff1744",A700:"#d50000"},Ot=Cp,Rp={50:"#fff3e0",100:"#ffe0b2",200:"#ffcc80",300:"#ffb74d",400:"#ffa726",500:"#ff9800",600:"#fb8c00",700:"#f57c00",800:"#ef6c00",900:"#e65100",A100:"#ffd180",A200:"#ffab40",A400:"#ff9100",A700:"#ff6d00"},on=Rp,Op={50:"#e3f2fd",100:"#bbdefb",200:"#90caf9",300:"#64b5f6",400:"#42a5f5",500:"#2196f3",600:"#1e88e5",700:"#1976d2",800:"#1565c0",900:"#0d47a1",A100:"#82b1ff",A200:"#448aff",A400:"#2979ff",A700:"#2962ff"},_t=Op,_p={50:"#e1f5fe",100:"#b3e5fc",200:"#81d4fa",300:"#4fc3f7",400:"#29b6f6",500:"#03a9f4",600:"#039be5",700:"#0288d1",800:"#0277bd",900:"#01579b",A100:"#80d8ff",A200:"#40c4ff",A400:"#00b0ff",A700:"#0091ea"},Pt=_p,Pp={50:"#e8f5e9",100:"#c8e6c9",200:"#a5d6a7",300:"#81c784",400:"#66bb6a",500:"#4caf50",600:"#43a047",700:"#388e3c",800:"#2e7d32",900:"#1b5e20",A100:"#b9f6ca",A200:"#69f0ae",A400:"#00e676",A700:"#00c853"},It=Pp,Ip=["mode","contrastThreshold","tonalOffset"],Oa={text:{primary:"rgba(0, 0, 0, 0.87)",secondary:"rgba(0, 0, 0, 0.6)",disabled:"rgba(0, 0, 0, 0.38)"},divider:"rgba(0, 0, 0, 0.12)",background:{paper:yn.white,default:yn.white},action:{active:"rgba(0, 0, 0, 0.54)",hover:"rgba(0, 0, 0, 0.04)",hoverOpacity:.04,selected:"rgba(0, 0, 0, 0.08)",selectedOpacity:.08,disabled:"rgba(0, 0, 0, 0.26)",disabledBackground:"rgba(0, 0, 0, 0.12)",disabledOpacity:.38,focus:"rgba(0, 0, 0, 0.12)",focusOpacity:.12,activatedOpacity:.12}},Vr={text:{primary:yn.white,secondary:"rgba(255, 255, 255, 0.7)",disabled:"rgba(255, 255, 255, 0.5)",icon:"rgba(255, 255, 255, 0.5)"},divider:"rgba(255, 255, 255, 0.12)",background:{paper:"#121212",default:"#121212"},action:{active:yn.white,hover:"rgba(255, 255, 255, 0.08)",hoverOpacity:.08,selected:"rgba(255, 255, 255, 0.16)",selectedOpacity:.16,disabled:"rgba(255, 255, 255, 0.3)",disabledBackground:"rgba(255, 255, 255, 0.12)",disabledOpacity:.38,focus:"rgba(255, 255, 255, 0.12)",focusOpacity:.12,activatedOpacity:.24}};function _a(e,t,n,r){const o=r.light||r,s=r.dark||r*1.5;e[t]||(e.hasOwnProperty(n)?e[t]=e[n]:t==="light"?e.light=Np(e.main,o):t==="dark"&&(e.dark=yp(e.main,s)))}function Mp(e="light"){return e==="dark"?{main:_t[200],light:_t[50],dark:_t[400]}:{main:_t[700],light:_t[400],dark:_t[800]}}function $p(e="light"){return e==="dark"?{main:Rt[200],light:Rt[50],dark:Rt[400]}:{main:Rt[500],light:Rt[300],dark:Rt[700]}}function Dp(e="light"){return e==="dark"?{main:Ot[500],light:Ot[300],dark:Ot[700]}:{main:Ot[700],light:Ot[400],dark:Ot[800]}}function Ap(e="light"){return e==="dark"?{main:Pt[400],light:Pt[300],dark:Pt[700]}:{main:Pt[700],light:Pt[500],dark:Pt[900]}}function Bp(e="light"){return e==="dark"?{main:It[400],light:It[300],dark:It[700]}:{main:It[800],light:It[500],dark:It[900]}}function Vp(e="light"){return e==="dark"?{main:on[400],light:on[300],dark:on[700]}:{main:"#ed6c02",light:on[500],dark:on[900]}}function zp(e){const{mode:t="light",contrastThreshold:n=3,tonalOffset:r=.2}=e,o=Ne(e,Ip),s=e.primary||Mp(t),i=e.secondary||$p(t),l=e.error||Dp(t),c=e.info||Ap(t),d=e.success||Bp(t),u=e.warning||Vp(t);function m(f){const h=Ra(f,Vr.text.primary)>=n?Vr.text.primary:Oa.text.primary;if(process.env.NODE_ENV!=="production"){const S=Ra(f,h);S<3&&console.error([`MUI: The contrast ratio of ${S}:1 for ${h} on ${f}`,"falls below the WCAG recommended absolute minimum contrast ratio of 3:1.","https://www.w3.org/TR/2008/REC-WCAG20-20081211/#visual-audio-contrast-contrast"].join(` +`))}return h}const w=({color:f,name:h,mainShade:S=500,lightShade:R=300,darkShade:j=700})=>{if(f=O({},f),!f.main&&f[S]&&(f.main=f[S]),!f.hasOwnProperty("main"))throw new Error(process.env.NODE_ENV!=="production"?`MUI: The color${h?` (${h})`:""} provided to augmentColor(color) is invalid. +The color object needs to have a \`main\` property or a \`${S}\` property.`:zt(11,h?` (${h})`:"",S));if(typeof f.main!="string")throw new Error(process.env.NODE_ENV!=="production"?`MUI: The color${h?` (${h})`:""} provided to augmentColor(color) is invalid. \`color.main\` should be a string, but \`${JSON.stringify(f.main)}\` was provided instead. Did you intend to use one of the following approaches? @@ -55,16 +55,16 @@ const theme1 = createTheme({ palette: { const theme2 = createTheme({ palette: { primary: { main: green[500] }, -} });`:Vt(12,h?` (${h})`:"",JSON.stringify(f.main)));return Ns(f,"light",I,r),Ns(f,"dark",j,r),f.contrastText||(f.contrastText=m(f.main)),f},b={dark:$r,light:xs};return process.env.NODE_ENV!=="production"&&(b[t]||console.error(`MUI: The palette mode \`${t}\` is not supported.`)),Qe(O({common:O({},vn),mode:t,primary:w({color:s,name:"primary"}),secondary:w({color:i,name:"secondary",mainShade:"A400",lightShade:"A200",darkShade:"A700"}),error:w({color:l,name:"error"}),warning:w({color:u,name:"warning"}),info:w({color:c,name:"info"}),success:w({color:d,name:"success"}),grey:Ou,contrastThreshold:n,getContrastText:m,augmentColor:w,tonalOffset:r},b[t]),o)}const Uu=["fontFamily","fontSize","fontWeightLight","fontWeightRegular","fontWeightMedium","fontWeightBold","htmlFontSize","allVariants","pxToRem"];function qu(e){return Math.round(e*1e5)/1e5}const ks={textTransform:"uppercase"},Es='"Roboto", "Helvetica", "Arial", sans-serif';function Hu(e,t){const n=typeof t=="function"?t(e):t,{fontFamily:r=Es,fontSize:o=14,fontWeightLight:s=300,fontWeightRegular:i=400,fontWeightMedium:l=500,fontWeightBold:c=700,htmlFontSize:d=16,allVariants:u,pxToRem:m}=n,w=xe(n,Uu);process.env.NODE_ENV!=="production"&&(typeof o!="number"&&console.error("MUI: `fontSize` is required to be a number."),typeof d!="number"&&console.error("MUI: `htmlFontSize` is required to be a number."));const b=o/14,y=m||(E=>`${E/d*b}rem`),f=(E,I,j,k,g)=>O({fontFamily:r,fontWeight:E,fontSize:y(I),lineHeight:j},r===Es?{letterSpacing:`${qu(k/I)}em`}:{},g,u),h={h1:f(s,96,1.167,-1.5),h2:f(s,60,1.2,-.5),h3:f(i,48,1.167,0),h4:f(i,34,1.235,.25),h5:f(i,24,1.334,0),h6:f(l,20,1.6,.15),subtitle1:f(i,16,1.75,.15),subtitle2:f(l,14,1.57,.1),body1:f(i,16,1.5,.15),body2:f(i,14,1.43,.15),button:f(l,14,1.75,.4,ks),caption:f(i,12,1.66,.4),overline:f(i,12,2.66,1,ks),inherit:{fontFamily:"inherit",fontWeight:"inherit",fontSize:"inherit",lineHeight:"inherit",letterSpacing:"inherit"}};return Qe(O({htmlFontSize:d,pxToRem:y,fontFamily:r,fontSize:o,fontWeightLight:s,fontWeightRegular:i,fontWeightMedium:l,fontWeightBold:c},h),w,{clone:!1})}const Xu=.2,Yu=.14,Wu=.12;function we(...e){return[`${e[0]}px ${e[1]}px ${e[2]}px ${e[3]}px rgba(0,0,0,${Xu})`,`${e[4]}px ${e[5]}px ${e[6]}px ${e[7]}px rgba(0,0,0,${Yu})`,`${e[8]}px ${e[9]}px ${e[10]}px ${e[11]}px rgba(0,0,0,${Wu})`].join(",")}const Ku=["none",we(0,2,1,-1,0,1,1,0,0,1,3,0),we(0,3,1,-2,0,2,2,0,0,1,5,0),we(0,3,3,-2,0,3,4,0,0,1,8,0),we(0,2,4,-1,0,4,5,0,0,1,10,0),we(0,3,5,-1,0,5,8,0,0,1,14,0),we(0,3,5,-1,0,6,10,0,0,1,18,0),we(0,4,5,-2,0,7,10,1,0,2,16,1),we(0,5,5,-3,0,8,10,1,0,3,14,2),we(0,5,6,-3,0,9,12,1,0,3,16,2),we(0,6,6,-3,0,10,14,1,0,4,18,3),we(0,6,7,-4,0,11,15,1,0,4,20,3),we(0,7,8,-4,0,12,17,2,0,5,22,4),we(0,7,8,-4,0,13,19,2,0,5,24,4),we(0,7,9,-4,0,14,21,2,0,5,26,4),we(0,8,9,-5,0,15,22,2,0,6,28,5),we(0,8,10,-5,0,16,24,2,0,6,30,5),we(0,8,11,-5,0,17,26,2,0,6,32,5),we(0,9,11,-5,0,18,28,2,0,7,34,6),we(0,9,12,-6,0,19,29,2,0,7,36,6),we(0,10,13,-6,0,20,31,3,0,8,38,7),we(0,10,13,-6,0,21,33,3,0,8,40,7),we(0,10,14,-6,0,22,35,3,0,8,42,7),we(0,11,14,-7,0,23,36,3,0,9,44,8),we(0,11,15,-7,0,24,38,3,0,9,46,8)],Ju=Ku,Zu=["duration","easing","delay"],Qu={easeInOut:"cubic-bezier(0.4, 0, 0.2, 1)",easeOut:"cubic-bezier(0.0, 0, 0.2, 1)",easeIn:"cubic-bezier(0.4, 0, 1, 1)",sharp:"cubic-bezier(0.4, 0, 0.6, 1)"},ep={shortest:150,shorter:200,short:250,standard:300,complex:375,enteringScreen:225,leavingScreen:195};function Ss(e){return`${Math.round(e)}ms`}function tp(e){if(!e)return 0;const t=e/36;return Math.round((4+15*t**.25+t/5)*10)}function np(e){const t=O({},Qu,e.easing),n=O({},ep,e.duration);return O({getAutoHeightDuration:tp,create:(o=["all"],s={})=>{const{duration:i=n.standard,easing:l=t.easeInOut,delay:c=0}=s,d=xe(s,Zu);if(process.env.NODE_ENV!=="production"){const u=w=>typeof w=="string",m=w=>!isNaN(parseFloat(w));!u(o)&&!Array.isArray(o)&&console.error('MUI: Argument "props" must be a string or Array.'),!m(i)&&!u(i)&&console.error(`MUI: Argument "duration" must be a number or a string but found ${i}.`),u(l)||console.error('MUI: Argument "easing" must be a string.'),!m(c)&&!u(c)&&console.error('MUI: Argument "delay" must be a number or a string.'),typeof s!="object"&&console.error(["MUI: Secong argument of transition.create must be an object.","Arguments should be either `create('prop1', options)` or `create(['prop1', 'prop2'], options)`"].join(` -`)),Object.keys(d).length!==0&&console.error(`MUI: Unrecognized argument(s) [${Object.keys(d).join(",")}].`)}return(Array.isArray(o)?o:[o]).map(u=>`${u} ${typeof i=="string"?i:Ss(i)} ${l} ${typeof c=="string"?c:Ss(c)}`).join(",")}},e,{easing:t,duration:n})}const rp={mobileStepper:1e3,fab:1050,speedDial:1050,appBar:1100,drawer:1200,modal:1300,snackbar:1400,tooltip:1500},op=rp,sp=["breakpoints","mixins","spacing","palette","transitions","typography","shape"];function ap(e={},...t){const{mixins:n={},palette:r={},transitions:o={},typography:s={}}=e,i=xe(e,sp);if(e.vars)throw new Error(process.env.NODE_ENV!=="production"?"MUI: `vars` is a private field used for CSS variables support.\nPlease use another name.":Vt(18));const l=Gu(r),c=yo(e);let d=Qe(c,{mixins:Tu(c.breakpoints,n),palette:l,shadows:Ju.slice(),typography:Hu(l,s),transitions:np(o),zIndex:O({},op)});if(d=Qe(d,i),d=t.reduce((u,m)=>Qe(u,m),d),process.env.NODE_ENV!=="production"){const u=["active","checked","completed","disabled","error","expanded","focused","focusVisible","required","selected"],m=(w,b)=>{let y;for(y in w){const f=w[y];if(u.indexOf(y)!==-1&&Object.keys(f).length>0){if(process.env.NODE_ENV!=="production"){const h=ar("",y);console.error([`MUI: The \`${b}\` component increases the CSS specificity of the \`${y}\` internal state.`,"You can not override it like this: ",JSON.stringify(w,null,2),"",`Instead, you need to use the '&.${h}' syntax:`,JSON.stringify({root:{[`&.${h}`]:f}},null,2),"","https://mui.com/r/state-classes-guide"].join(` -`))}w[y]={}}}};Object.keys(d.components).forEach(w=>{const b=d.components[w].styleOverrides;b&&w.indexOf("Mui")===0&&m(b,w)})}return d.unstable_sxConfig=O({},bo,i==null?void 0:i.unstable_sxConfig),d.unstable_sx=function(m){return vo({sx:m,theme:this})},d}const ip=ap(),No=ip,ko="$$material";function Eo({props:e,name:t}){return xu({props:e,name:t,defaultTheme:No,themeId:ko})}const lp=e=>zn(e)&&e!=="classes",cp=vu({themeId:ko,defaultTheme:No,rootShouldForwardProp:lp}),Rn=cp;function dp(e){return ar("MuiSvgIcon",e)}Ga("MuiSvgIcon",["root","colorPrimary","colorSecondary","colorAction","colorError","colorDisabled","fontSizeInherit","fontSizeSmall","fontSizeMedium","fontSizeLarge"]);const up=["children","className","color","component","fontSize","htmlColor","inheritViewBox","titleAccess","viewBox"],pp=e=>{const{color:t,fontSize:n,classes:r}=e,o={root:["root",t!=="inherit"&&`color${Ye(t)}`,`fontSize${Ye(n)}`]};return mo(o,dp,r)},wp=Rn("svg",{name:"MuiSvgIcon",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.root,n.color!=="inherit"&&t[`color${Ye(n.color)}`],t[`fontSize${Ye(n.fontSize)}`]]}})(({theme:e,ownerState:t})=>{var n,r,o,s,i,l,c,d,u,m,w,b,y;return{userSelect:"none",width:"1em",height:"1em",display:"inline-block",fill:t.hasSvgAsChild?void 0:"currentColor",flexShrink:0,transition:(n=e.transitions)==null||(r=n.create)==null?void 0:r.call(n,"fill",{duration:(o=e.transitions)==null||(o=o.duration)==null?void 0:o.shorter}),fontSize:{inherit:"inherit",small:((s=e.typography)==null||(i=s.pxToRem)==null?void 0:i.call(s,20))||"1.25rem",medium:((l=e.typography)==null||(c=l.pxToRem)==null?void 0:c.call(l,24))||"1.5rem",large:((d=e.typography)==null||(u=d.pxToRem)==null?void 0:u.call(d,35))||"2.1875rem"}[t.fontSize],color:(m=(w=(e.vars||e).palette)==null||(w=w[t.color])==null?void 0:w.main)!=null?m:{action:(b=(e.vars||e).palette)==null||(b=b.action)==null?void 0:b.active,disabled:(y=(e.vars||e).palette)==null||(y=y.action)==null?void 0:y.disabled,inherit:void 0}[t.color]}}),So=M.forwardRef(function(t,n){const r=Eo({props:t,name:"MuiSvgIcon"}),{children:o,className:s,color:i="inherit",component:l="svg",fontSize:c="medium",htmlColor:d,inheritViewBox:u=!1,titleAccess:m,viewBox:w="0 0 24 24"}=r,b=xe(r,up),y=M.isValidElement(o)&&o.type==="svg",f=O({},r,{color:i,component:l,fontSize:c,instanceFontSize:t.fontSize,inheritViewBox:u,viewBox:w,hasSvgAsChild:y}),h={};u||(h.viewBox=w);const E=pp(f);return a.jsxs(wp,O({as:l,className:ot(E.root,s),focusable:"false",color:d,"aria-hidden":m?void 0:!0,role:m?"img":void 0,ref:n},h,b,y&&o.props,{ownerState:f,children:[y?o.props.children:o,m?a.jsx("title",{children:m}):null]}))});process.env.NODE_ENV!=="production"&&(So.propTypes={children:p.node,classes:p.object,className:p.string,color:p.oneOfType([p.oneOf(["inherit","action","disabled","primary","secondary","error","info","success","warning"]),p.string]),component:p.elementType,fontSize:p.oneOfType([p.oneOf(["inherit","large","medium","small"]),p.string]),htmlColor:p.string,inheritViewBox:p.bool,shapeRendering:p.string,sx:p.oneOfType([p.arrayOf(p.oneOfType([p.func,p.object,p.bool])),p.func,p.object]),titleAccess:p.string,viewBox:p.string});So.muiName="SvgIcon";const Ts=So;function Ka(e,t){function n(r,o){return a.jsx(Ts,O({"data-testid":`${t}Icon`,ref:o},r,{children:e}))}return process.env.NODE_ENV!=="production"&&(n.displayName=`${t}Icon`),n.muiName=Ts.muiName,M.memo(M.forwardRef(n))}const fp={configure:e=>{process.env.NODE_ENV!=="production"&&console.warn(["MUI: `ClassNameGenerator` import from `@mui/material/utils` is outdated and might cause unexpected issues.","","You should use `import { unstable_ClassNameGenerator } from '@mui/material/className'` instead","","The detail of the issue: https://github.com/mui/material-ui/issues/30011#issuecomment-1024993401","","The updated documentation: https://mui.com/guides/classname-generator/"].join(` -`)),Fa.configure(e)}},mp=Object.freeze(Object.defineProperty({__proto__:null,capitalize:Ye,createChainedFunction:Uc,createSvgIcon:Ka,debounce:qc,deprecatedPropType:Hc,isMuiElement:Xc,ownerDocument:Hn,ownerWindow:Yc,requirePropFactory:Wc,setRef:Xn,unstable_ClassNameGenerator:fp,unstable_useEnhancedEffect:Lt,unstable_useId:Aa,unsupportedProp:Zc,useControlled:Ba,useEventCallback:Ur,useForkRef:xt,useIsFocusVisible:Va},Symbol.toStringTag,{value:"Module"})),hp=Ec(mp);var Cs;function gp(){return Cs||(Cs=1,function(e){"use client";Object.defineProperty(e,"__esModule",{value:!0}),Object.defineProperty(e,"default",{enumerable:!0,get:function(){return t.createSvgIcon}});var t=hp}(Tr)),Tr}var bp=Sc;Object.defineProperty(po,"__esModule",{value:!0});var Ja=po.default=void 0,vp=bp(gp()),yp=a;Ja=po.default=(0,vp.default)((0,yp.jsx)("path",{d:"m10 17 5-5-5-5z"}),"ArrowRight");function xp(e){return typeof e=="string"}function cn(e,t,n){return e===void 0||xp(e)?t:O({},t,{ownerState:O({},t.ownerState,n)})}const Np={disableDefaultClasses:!1},kp=M.createContext(Np);function Ep(e){const{disableDefaultClasses:t}=M.useContext(kp);return n=>t?"":e(n)}function Sp(e,t=[]){if(e===void 0)return{};const n={};return Object.keys(e).filter(r=>r.match(/^on[A-Z]/)&&typeof e[r]=="function"&&!t.includes(r)).forEach(r=>{n[r]=e[r]}),n}function Tp(e,t,n){return typeof e=="function"?e(t,n):e}function js(e){if(e===void 0)return{};const t={};return Object.keys(e).filter(n=>!(n.match(/^on[A-Z]/)&&typeof e[n]=="function")).forEach(n=>{t[n]=e[n]}),t}function Cp(e){const{getSlotProps:t,additionalProps:n,externalSlotProps:r,externalForwardedProps:o,className:s}=e;if(!t){const b=ot(n==null?void 0:n.className,s,o==null?void 0:o.className,r==null?void 0:r.className),y=O({},n==null?void 0:n.style,o==null?void 0:o.style,r==null?void 0:r.style),f=O({},n,o,r);return b.length>0&&(f.className=b),Object.keys(y).length>0&&(f.style=y),{props:f,internalRef:void 0}}const i=Sp(O({},o,r)),l=js(r),c=js(o),d=t(i),u=ot(d==null?void 0:d.className,n==null?void 0:n.className,s,o==null?void 0:o.className,r==null?void 0:r.className),m=O({},d==null?void 0:d.style,n==null?void 0:n.style,o==null?void 0:o.style,r==null?void 0:r.style),w=O({},d,n,c,l);return u.length>0&&(w.className=u),Object.keys(m).length>0&&(w.style=m),{props:w,internalRef:d.ref}}const jp=["elementType","externalSlotProps","ownerState","skipResolvingSlotProps"];function Op(e){var t;const{elementType:n,externalSlotProps:r,ownerState:o,skipResolvingSlotProps:s=!1}=e,i=xe(e,jp),l=s?{}:Tp(r,o),{props:c,internalRef:d}=Cp(O({},i,{externalSlotProps:l})),u=xt(d,l==null?void 0:l.ref,(t=e.additionalProps)==null?void 0:t.ref);return cn(n,O({},c,{ref:u}),o)}const Za="base";function Rp(e){return`${Za}--${e}`}function Pp(e,t){return`${Za}-${e}-${t}`}function Qa(e,t){const n=za[t];return n?Rp(n):Pp(e,t)}function _p(e,t){const n={};return t.forEach(r=>{n[r]=Qa(e,r)}),n}function Ip(e){return typeof e=="function"?e():e}const Wn=M.forwardRef(function(t,n){const{children:r,container:o,disablePortal:s=!1}=t,[i,l]=M.useState(null),c=xt(M.isValidElement(r)?r.ref:null,n);if(Lt(()=>{s||l(Ip(o)||document.body)},[o,s]),Lt(()=>{if(i&&!s)return Xn(n,i),()=>{Xn(n,null)}},[n,i,s]),s){if(M.isValidElement(r)){const d={ref:c};return M.cloneElement(r,d)}return a.jsx(M.Fragment,{children:r})}return a.jsx(M.Fragment,{children:i&&dl.createPortal(r,i)})});process.env.NODE_ENV!=="production"&&(Wn.propTypes={children:p.node,container:p.oneOfType([bn,p.func]),disablePortal:p.bool});process.env.NODE_ENV!=="production"&&(Wn["propTypes"]=Ac(Wn.propTypes));var Te="top",Ve="bottom",Le="right",Ce="left",To="auto",Pn=[Te,Ve,Le,Ce],Ft="start",yn="end",$p="clippingParents",ei="viewport",rn="popper",Mp="reference",Os=Pn.reduce(function(e,t){return e.concat([t+"-"+Ft,t+"-"+yn])},[]),ti=[].concat(Pn,[To]).reduce(function(e,t){return e.concat([t,t+"-"+Ft,t+"-"+yn])},[]),Dp="beforeRead",Ap="read",Bp="afterRead",Vp="beforeMain",Lp="main",Fp="afterMain",zp="beforeWrite",Gp="write",Up="afterWrite",qp=[Dp,Ap,Bp,Vp,Lp,Fp,zp,Gp,Up];function We(e){return e?(e.nodeName||"").toLowerCase():null}function $e(e){if(e==null)return window;if(e.toString()!=="[object Window]"){var t=e.ownerDocument;return t&&t.defaultView||window}return e}function kt(e){var t=$e(e).Element;return e instanceof t||e instanceof Element}function Be(e){var t=$e(e).HTMLElement;return e instanceof t||e instanceof HTMLElement}function Co(e){if(typeof ShadowRoot>"u")return!1;var t=$e(e).ShadowRoot;return e instanceof t||e instanceof ShadowRoot}function Hp(e){var t=e.state;Object.keys(t.elements).forEach(function(n){var r=t.styles[n]||{},o=t.attributes[n]||{},s=t.elements[n];!Be(s)||!We(s)||(Object.assign(s.style,r),Object.keys(o).forEach(function(i){var l=o[i];l===!1?s.removeAttribute(i):s.setAttribute(i,l===!0?"":l)}))})}function Xp(e){var t=e.state,n={popper:{position:t.options.strategy,left:"0",top:"0",margin:"0"},arrow:{position:"absolute"},reference:{}};return Object.assign(t.elements.popper.style,n.popper),t.styles=n,t.elements.arrow&&Object.assign(t.elements.arrow.style,n.arrow),function(){Object.keys(t.elements).forEach(function(r){var o=t.elements[r],s=t.attributes[r]||{},i=Object.keys(t.styles.hasOwnProperty(r)?t.styles[r]:n[r]),l=i.reduce(function(c,d){return c[d]="",c},{});!Be(o)||!We(o)||(Object.assign(o.style,l),Object.keys(s).forEach(function(c){o.removeAttribute(c)}))})}}const Yp={name:"applyStyles",enabled:!0,phase:"write",fn:Hp,effect:Xp,requires:["computeStyles"]};function He(e){return e.split("-")[0]}var ht=Math.max,Kn=Math.min,zt=Math.round;function Hr(){var e=navigator.userAgentData;return e!=null&&e.brands&&Array.isArray(e.brands)?e.brands.map(function(t){return t.brand+"/"+t.version}).join(" "):navigator.userAgent}function ni(){return!/^((?!chrome|android).)*safari/i.test(Hr())}function Gt(e,t,n){t===void 0&&(t=!1),n===void 0&&(n=!1);var r=e.getBoundingClientRect(),o=1,s=1;t&&Be(e)&&(o=e.offsetWidth>0&&zt(r.width)/e.offsetWidth||1,s=e.offsetHeight>0&&zt(r.height)/e.offsetHeight||1);var i=kt(e)?$e(e):window,l=i.visualViewport,c=!ni()&&n,d=(r.left+(c&&l?l.offsetLeft:0))/o,u=(r.top+(c&&l?l.offsetTop:0))/s,m=r.width/o,w=r.height/s;return{width:m,height:w,top:u,right:d+m,bottom:u+w,left:d,x:d,y:u}}function jo(e){var t=Gt(e),n=e.offsetWidth,r=e.offsetHeight;return Math.abs(t.width-n)<=1&&(n=t.width),Math.abs(t.height-r)<=1&&(r=t.height),{x:e.offsetLeft,y:e.offsetTop,width:n,height:r}}function ri(e,t){var n=t.getRootNode&&t.getRootNode();if(e.contains(t))return!0;if(n&&Co(n)){var r=t;do{if(r&&e.isSameNode(r))return!0;r=r.parentNode||r.host}while(r)}return!1}function tt(e){return $e(e).getComputedStyle(e)}function Wp(e){return["table","td","th"].indexOf(We(e))>=0}function it(e){return((kt(e)?e.ownerDocument:e.document)||window.document).documentElement}function hr(e){return We(e)==="html"?e:e.assignedSlot||e.parentNode||(Co(e)?e.host:null)||it(e)}function Rs(e){return!Be(e)||tt(e).position==="fixed"?null:e.offsetParent}function Kp(e){var t=/firefox/i.test(Hr()),n=/Trident/i.test(Hr());if(n&&Be(e)){var r=tt(e);if(r.position==="fixed")return null}var o=hr(e);for(Co(o)&&(o=o.host);Be(o)&&["html","body"].indexOf(We(o))<0;){var s=tt(o);if(s.transform!=="none"||s.perspective!=="none"||s.contain==="paint"||["transform","perspective"].indexOf(s.willChange)!==-1||t&&s.willChange==="filter"||t&&s.filter&&s.filter!=="none")return o;o=o.parentNode}return null}function _n(e){for(var t=$e(e),n=Rs(e);n&&Wp(n)&&tt(n).position==="static";)n=Rs(n);return n&&(We(n)==="html"||We(n)==="body"&&tt(n).position==="static")?t:n||Kp(e)||t}function Oo(e){return["top","bottom"].indexOf(e)>=0?"x":"y"}function fn(e,t,n){return ht(e,Kn(t,n))}function Jp(e,t,n){var r=fn(e,t,n);return r>n?n:r}function oi(){return{top:0,right:0,bottom:0,left:0}}function si(e){return Object.assign({},oi(),e)}function ai(e,t){return t.reduce(function(n,r){return n[r]=e,n},{})}var Zp=function(t,n){return t=typeof t=="function"?t(Object.assign({},n.rects,{placement:n.placement})):t,si(typeof t!="number"?t:ai(t,Pn))};function Qp(e){var t,n=e.state,r=e.name,o=e.options,s=n.elements.arrow,i=n.modifiersData.popperOffsets,l=He(n.placement),c=Oo(l),d=[Ce,Le].indexOf(l)>=0,u=d?"height":"width";if(!(!s||!i)){var m=Zp(o.padding,n),w=jo(s),b=c==="y"?Te:Ce,y=c==="y"?Ve:Le,f=n.rects.reference[u]+n.rects.reference[c]-i[c]-n.rects.popper[u],h=i[c]-n.rects.reference[c],E=_n(s),I=E?c==="y"?E.clientHeight||0:E.clientWidth||0:0,j=f/2-h/2,k=m[b],g=I-w[u]-m[y],P=I/2-w[u]/2+j,V=fn(k,P,g),U=c;n.modifiersData[r]=(t={},t[U]=V,t.centerOffset=V-P,t)}}function ew(e){var t=e.state,n=e.options,r=n.element,o=r===void 0?"[data-popper-arrow]":r;o!=null&&(typeof o=="string"&&(o=t.elements.popper.querySelector(o),!o)||ri(t.elements.popper,o)&&(t.elements.arrow=o))}const tw={name:"arrow",enabled:!0,phase:"main",fn:Qp,effect:ew,requires:["popperOffsets"],requiresIfExists:["preventOverflow"]};function Ut(e){return e.split("-")[1]}var nw={top:"auto",right:"auto",bottom:"auto",left:"auto"};function rw(e,t){var n=e.x,r=e.y,o=t.devicePixelRatio||1;return{x:zt(n*o)/o||0,y:zt(r*o)/o||0}}function Ps(e){var t,n=e.popper,r=e.popperRect,o=e.placement,s=e.variation,i=e.offsets,l=e.position,c=e.gpuAcceleration,d=e.adaptive,u=e.roundOffsets,m=e.isFixed,w=i.x,b=w===void 0?0:w,y=i.y,f=y===void 0?0:y,h=typeof u=="function"?u({x:b,y:f}):{x:b,y:f};b=h.x,f=h.y;var E=i.hasOwnProperty("x"),I=i.hasOwnProperty("y"),j=Ce,k=Te,g=window;if(d){var P=_n(n),V="clientHeight",U="clientWidth";if(P===$e(n)&&(P=it(n),tt(P).position!=="static"&&l==="absolute"&&(V="scrollHeight",U="scrollWidth")),P=P,o===Te||(o===Ce||o===Le)&&s===yn){k=Ve;var T=m&&P===g&&g.visualViewport?g.visualViewport.height:P[V];f-=T-r.height,f*=c?1:-1}if(o===Ce||(o===Te||o===Ve)&&s===yn){j=Le;var R=m&&P===g&&g.visualViewport?g.visualViewport.width:P[U];b-=R-r.width,b*=c?1:-1}}var N=Object.assign({position:l},d&&nw),D=u===!0?rw({x:b,y:f},$e(n)):{x:b,y:f};if(b=D.x,f=D.y,c){var $;return Object.assign({},N,($={},$[k]=I?"0":"",$[j]=E?"0":"",$.transform=(g.devicePixelRatio||1)<=1?"translate("+b+"px, "+f+"px)":"translate3d("+b+"px, "+f+"px, 0)",$))}return Object.assign({},N,(t={},t[k]=I?f+"px":"",t[j]=E?b+"px":"",t.transform="",t))}function ow(e){var t=e.state,n=e.options,r=n.gpuAcceleration,o=r===void 0?!0:r,s=n.adaptive,i=s===void 0?!0:s,l=n.roundOffsets,c=l===void 0?!0:l,d={placement:He(t.placement),variation:Ut(t.placement),popper:t.elements.popper,popperRect:t.rects.popper,gpuAcceleration:o,isFixed:t.options.strategy==="fixed"};t.modifiersData.popperOffsets!=null&&(t.styles.popper=Object.assign({},t.styles.popper,Ps(Object.assign({},d,{offsets:t.modifiersData.popperOffsets,position:t.options.strategy,adaptive:i,roundOffsets:c})))),t.modifiersData.arrow!=null&&(t.styles.arrow=Object.assign({},t.styles.arrow,Ps(Object.assign({},d,{offsets:t.modifiersData.arrow,position:"absolute",adaptive:!1,roundOffsets:c})))),t.attributes.popper=Object.assign({},t.attributes.popper,{"data-popper-placement":t.placement})}const sw={name:"computeStyles",enabled:!0,phase:"beforeWrite",fn:ow,data:{}};var Vn={passive:!0};function aw(e){var t=e.state,n=e.instance,r=e.options,o=r.scroll,s=o===void 0?!0:o,i=r.resize,l=i===void 0?!0:i,c=$e(t.elements.popper),d=[].concat(t.scrollParents.reference,t.scrollParents.popper);return s&&d.forEach(function(u){u.addEventListener("scroll",n.update,Vn)}),l&&c.addEventListener("resize",n.update,Vn),function(){s&&d.forEach(function(u){u.removeEventListener("scroll",n.update,Vn)}),l&&c.removeEventListener("resize",n.update,Vn)}}const iw={name:"eventListeners",enabled:!0,phase:"write",fn:function(){},effect:aw,data:{}};var lw={left:"right",right:"left",bottom:"top",top:"bottom"};function Un(e){return e.replace(/left|right|bottom|top/g,function(t){return lw[t]})}var cw={start:"end",end:"start"};function _s(e){return e.replace(/start|end/g,function(t){return cw[t]})}function Ro(e){var t=$e(e),n=t.pageXOffset,r=t.pageYOffset;return{scrollLeft:n,scrollTop:r}}function Po(e){return Gt(it(e)).left+Ro(e).scrollLeft}function dw(e,t){var n=$e(e),r=it(e),o=n.visualViewport,s=r.clientWidth,i=r.clientHeight,l=0,c=0;if(o){s=o.width,i=o.height;var d=ni();(d||!d&&t==="fixed")&&(l=o.offsetLeft,c=o.offsetTop)}return{width:s,height:i,x:l+Po(e),y:c}}function uw(e){var t,n=it(e),r=Ro(e),o=(t=e.ownerDocument)==null?void 0:t.body,s=ht(n.scrollWidth,n.clientWidth,o?o.scrollWidth:0,o?o.clientWidth:0),i=ht(n.scrollHeight,n.clientHeight,o?o.scrollHeight:0,o?o.clientHeight:0),l=-r.scrollLeft+Po(e),c=-r.scrollTop;return tt(o||n).direction==="rtl"&&(l+=ht(n.clientWidth,o?o.clientWidth:0)-s),{width:s,height:i,x:l,y:c}}function _o(e){var t=tt(e),n=t.overflow,r=t.overflowX,o=t.overflowY;return/auto|scroll|overlay|hidden/.test(n+o+r)}function ii(e){return["html","body","#document"].indexOf(We(e))>=0?e.ownerDocument.body:Be(e)&&_o(e)?e:ii(hr(e))}function mn(e,t){var n;t===void 0&&(t=[]);var r=ii(e),o=r===((n=e.ownerDocument)==null?void 0:n.body),s=$e(r),i=o?[s].concat(s.visualViewport||[],_o(r)?r:[]):r,l=t.concat(i);return o?l:l.concat(mn(hr(i)))}function Xr(e){return Object.assign({},e,{left:e.x,top:e.y,right:e.x+e.width,bottom:e.y+e.height})}function pw(e,t){var n=Gt(e,!1,t==="fixed");return n.top=n.top+e.clientTop,n.left=n.left+e.clientLeft,n.bottom=n.top+e.clientHeight,n.right=n.left+e.clientWidth,n.width=e.clientWidth,n.height=e.clientHeight,n.x=n.left,n.y=n.top,n}function Is(e,t,n){return t===ei?Xr(dw(e,n)):kt(t)?pw(t,n):Xr(uw(it(e)))}function ww(e){var t=mn(hr(e)),n=["absolute","fixed"].indexOf(tt(e).position)>=0,r=n&&Be(e)?_n(e):e;return kt(r)?t.filter(function(o){return kt(o)&&ri(o,r)&&We(o)!=="body"}):[]}function fw(e,t,n,r){var o=t==="clippingParents"?ww(e):[].concat(t),s=[].concat(o,[n]),i=s[0],l=s.reduce(function(c,d){var u=Is(e,d,r);return c.top=ht(u.top,c.top),c.right=Kn(u.right,c.right),c.bottom=Kn(u.bottom,c.bottom),c.left=ht(u.left,c.left),c},Is(e,i,r));return l.width=l.right-l.left,l.height=l.bottom-l.top,l.x=l.left,l.y=l.top,l}function li(e){var t=e.reference,n=e.element,r=e.placement,o=r?He(r):null,s=r?Ut(r):null,i=t.x+t.width/2-n.width/2,l=t.y+t.height/2-n.height/2,c;switch(o){case Te:c={x:i,y:t.y-n.height};break;case Ve:c={x:i,y:t.y+t.height};break;case Le:c={x:t.x+t.width,y:l};break;case Ce:c={x:t.x-n.width,y:l};break;default:c={x:t.x,y:t.y}}var d=o?Oo(o):null;if(d!=null){var u=d==="y"?"height":"width";switch(s){case Ft:c[d]=c[d]-(t[u]/2-n[u]/2);break;case yn:c[d]=c[d]+(t[u]/2-n[u]/2);break}}return c}function xn(e,t){t===void 0&&(t={});var n=t,r=n.placement,o=r===void 0?e.placement:r,s=n.strategy,i=s===void 0?e.strategy:s,l=n.boundary,c=l===void 0?$p:l,d=n.rootBoundary,u=d===void 0?ei:d,m=n.elementContext,w=m===void 0?rn:m,b=n.altBoundary,y=b===void 0?!1:b,f=n.padding,h=f===void 0?0:f,E=si(typeof h!="number"?h:ai(h,Pn)),I=w===rn?Mp:rn,j=e.rects.popper,k=e.elements[y?I:w],g=fw(kt(k)?k:k.contextElement||it(e.elements.popper),c,u,i),P=Gt(e.elements.reference),V=li({reference:P,element:j,strategy:"absolute",placement:o}),U=Xr(Object.assign({},j,V)),T=w===rn?U:P,R={top:g.top-T.top+E.top,bottom:T.bottom-g.bottom+E.bottom,left:g.left-T.left+E.left,right:T.right-g.right+E.right},N=e.modifiersData.offset;if(w===rn&&N){var D=N[o];Object.keys(R).forEach(function($){var J=[Le,Ve].indexOf($)>=0?1:-1,Y=[Te,Ve].indexOf($)>=0?"y":"x";R[$]+=D[Y]*J})}return R}function mw(e,t){t===void 0&&(t={});var n=t,r=n.placement,o=n.boundary,s=n.rootBoundary,i=n.padding,l=n.flipVariations,c=n.allowedAutoPlacements,d=c===void 0?ti:c,u=Ut(r),m=u?l?Os:Os.filter(function(y){return Ut(y)===u}):Pn,w=m.filter(function(y){return d.indexOf(y)>=0});w.length===0&&(w=m);var b=w.reduce(function(y,f){return y[f]=xn(e,{placement:f,boundary:o,rootBoundary:s,padding:i})[He(f)],y},{});return Object.keys(b).sort(function(y,f){return b[y]-b[f]})}function hw(e){if(He(e)===To)return[];var t=Un(e);return[_s(e),t,_s(t)]}function gw(e){var t=e.state,n=e.options,r=e.name;if(!t.modifiersData[r]._skip){for(var o=n.mainAxis,s=o===void 0?!0:o,i=n.altAxis,l=i===void 0?!0:i,c=n.fallbackPlacements,d=n.padding,u=n.boundary,m=n.rootBoundary,w=n.altBoundary,b=n.flipVariations,y=b===void 0?!0:b,f=n.allowedAutoPlacements,h=t.options.placement,E=He(h),I=E===h,j=c||(I||!y?[Un(h)]:hw(h)),k=[h].concat(j).reduce(function(B,X){return B.concat(He(X)===To?mw(t,{placement:X,boundary:u,rootBoundary:m,padding:d,flipVariations:y,allowedAutoPlacements:f}):X)},[]),g=t.rects.reference,P=t.rects.popper,V=new Map,U=!0,T=k[0],R=0;R=0,Y=J?"width":"height",z=xn(t,{placement:N,boundary:u,rootBoundary:m,altBoundary:w,padding:d}),ee=J?$?Le:Ce:$?Ve:Te;g[Y]>P[Y]&&(ee=Un(ee));var ae=Un(ee),oe=[];if(s&&oe.push(z[D]<=0),l&&oe.push(z[ee]<=0,z[ae]<=0),oe.every(function(B){return B})){T=N,U=!1;break}V.set(N,oe)}if(U)for(var x=y?3:1,C=function(X){var q=k.find(function(H){var G=V.get(H);if(G)return G.slice(0,X).every(function(K){return K})});if(q)return T=q,"break"},L=x;L>0;L--){var F=C(L);if(F==="break")break}t.placement!==T&&(t.modifiersData[r]._skip=!0,t.placement=T,t.reset=!0)}}const bw={name:"flip",enabled:!0,phase:"main",fn:gw,requiresIfExists:["offset"],data:{_skip:!1}};function $s(e,t,n){return n===void 0&&(n={x:0,y:0}),{top:e.top-t.height-n.y,right:e.right-t.width+n.x,bottom:e.bottom-t.height+n.y,left:e.left-t.width-n.x}}function Ms(e){return[Te,Le,Ve,Ce].some(function(t){return e[t]>=0})}function vw(e){var t=e.state,n=e.name,r=t.rects.reference,o=t.rects.popper,s=t.modifiersData.preventOverflow,i=xn(t,{elementContext:"reference"}),l=xn(t,{altBoundary:!0}),c=$s(i,r),d=$s(l,o,s),u=Ms(c),m=Ms(d);t.modifiersData[n]={referenceClippingOffsets:c,popperEscapeOffsets:d,isReferenceHidden:u,hasPopperEscaped:m},t.attributes.popper=Object.assign({},t.attributes.popper,{"data-popper-reference-hidden":u,"data-popper-escaped":m})}const yw={name:"hide",enabled:!0,phase:"main",requiresIfExists:["preventOverflow"],fn:vw};function xw(e,t,n){var r=He(e),o=[Ce,Te].indexOf(r)>=0?-1:1,s=typeof n=="function"?n(Object.assign({},t,{placement:e})):n,i=s[0],l=s[1];return i=i||0,l=(l||0)*o,[Ce,Le].indexOf(r)>=0?{x:l,y:i}:{x:i,y:l}}function Nw(e){var t=e.state,n=e.options,r=e.name,o=n.offset,s=o===void 0?[0,0]:o,i=ti.reduce(function(u,m){return u[m]=xw(m,t.rects,s),u},{}),l=i[t.placement],c=l.x,d=l.y;t.modifiersData.popperOffsets!=null&&(t.modifiersData.popperOffsets.x+=c,t.modifiersData.popperOffsets.y+=d),t.modifiersData[r]=i}const kw={name:"offset",enabled:!0,phase:"main",requires:["popperOffsets"],fn:Nw};function Ew(e){var t=e.state,n=e.name;t.modifiersData[n]=li({reference:t.rects.reference,element:t.rects.popper,strategy:"absolute",placement:t.placement})}const Sw={name:"popperOffsets",enabled:!0,phase:"read",fn:Ew,data:{}};function Tw(e){return e==="x"?"y":"x"}function Cw(e){var t=e.state,n=e.options,r=e.name,o=n.mainAxis,s=o===void 0?!0:o,i=n.altAxis,l=i===void 0?!1:i,c=n.boundary,d=n.rootBoundary,u=n.altBoundary,m=n.padding,w=n.tether,b=w===void 0?!0:w,y=n.tetherOffset,f=y===void 0?0:y,h=xn(t,{boundary:c,rootBoundary:d,padding:m,altBoundary:u}),E=He(t.placement),I=Ut(t.placement),j=!I,k=Oo(E),g=Tw(k),P=t.modifiersData.popperOffsets,V=t.rects.reference,U=t.rects.popper,T=typeof f=="function"?f(Object.assign({},t.rects,{placement:t.placement})):f,R=typeof T=="number"?{mainAxis:T,altAxis:T}:Object.assign({mainAxis:0,altAxis:0},T),N=t.modifiersData.offset?t.modifiersData.offset[t.placement]:null,D={x:0,y:0};if(P){if(s){var $,J=k==="y"?Te:Ce,Y=k==="y"?Ve:Le,z=k==="y"?"height":"width",ee=P[k],ae=ee+h[J],oe=ee-h[Y],x=b?-U[z]/2:0,C=I===Ft?V[z]:U[z],L=I===Ft?-U[z]:-V[z],F=t.elements.arrow,B=b&&F?jo(F):{width:0,height:0},X=t.modifiersData["arrow#persistent"]?t.modifiersData["arrow#persistent"].padding:oi(),q=X[J],H=X[Y],G=fn(0,V[z],B[z]),K=j?V[z]/2-x-G-q-R.mainAxis:C-G-q-R.mainAxis,Z=j?-V[z]/2+x+G+H+R.mainAxis:L+G+H+R.mainAxis,ue=t.elements.arrow&&_n(t.elements.arrow),_=ue?k==="y"?ue.clientTop||0:ue.clientLeft||0:0,ye=($=N==null?void 0:N[k])!=null?$:0,A=ee+K-ye-_,ve=ee+Z-ye,ze=fn(b?Kn(ae,A):ae,ee,b?ht(oe,ve):oe);P[k]=ze,D[k]=ze-ee}if(l){var lt,Ee=k==="x"?Te:Ce,In=k==="x"?Ve:Le,Ge=P[g],Et=g==="y"?"height":"width",ct=Ge+h[Ee],St=Ge-h[In],Tt=[Te,Ce].indexOf(E)!==-1,Ct=(lt=N==null?void 0:N[g])!=null?lt:0,dt=Tt?ct:Ge-V[Et]-U[Et]-Ct+R.altAxis,Wt=Tt?Ge+V[Et]+U[Et]-Ct-R.altAxis:St,$n=b&&Tt?Jp(dt,Ge,Wt):fn(b?dt:ct,Ge,b?Wt:St);P[g]=$n,D[g]=$n-Ge}t.modifiersData[r]=D}}const jw={name:"preventOverflow",enabled:!0,phase:"main",fn:Cw,requiresIfExists:["offset"]};function Ow(e){return{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}}function Rw(e){return e===$e(e)||!Be(e)?Ro(e):Ow(e)}function Pw(e){var t=e.getBoundingClientRect(),n=zt(t.width)/e.offsetWidth||1,r=zt(t.height)/e.offsetHeight||1;return n!==1||r!==1}function _w(e,t,n){n===void 0&&(n=!1);var r=Be(t),o=Be(t)&&Pw(t),s=it(t),i=Gt(e,o,n),l={scrollLeft:0,scrollTop:0},c={x:0,y:0};return(r||!r&&!n)&&((We(t)!=="body"||_o(s))&&(l=Rw(t)),Be(t)?(c=Gt(t,!0),c.x+=t.clientLeft,c.y+=t.clientTop):s&&(c.x=Po(s))),{x:i.left+l.scrollLeft-c.x,y:i.top+l.scrollTop-c.y,width:i.width,height:i.height}}function Iw(e){var t=new Map,n=new Set,r=[];e.forEach(function(s){t.set(s.name,s)});function o(s){n.add(s.name);var i=[].concat(s.requires||[],s.requiresIfExists||[]);i.forEach(function(l){if(!n.has(l)){var c=t.get(l);c&&o(c)}}),r.push(s)}return e.forEach(function(s){n.has(s.name)||o(s)}),r}function $w(e){var t=Iw(e);return qp.reduce(function(n,r){return n.concat(t.filter(function(o){return o.phase===r}))},[])}function Mw(e){var t;return function(){return t||(t=new Promise(function(n){Promise.resolve().then(function(){t=void 0,n(e())})})),t}}function Dw(e){var t=e.reduce(function(n,r){var o=n[r.name];return n[r.name]=o?Object.assign({},o,r,{options:Object.assign({},o.options,r.options),data:Object.assign({},o.data,r.data)}):r,n},{});return Object.keys(t).map(function(n){return t[n]})}var Ds={placement:"bottom",modifiers:[],strategy:"absolute"};function As(){for(var e=arguments.length,t=new Array(e),n=0;nmo({root:["root"]},Ep(Lw)),Hw={},Xw=M.forwardRef(function(t,n){var r;const{anchorEl:o,children:s,direction:i,disablePortal:l,modifiers:c,open:d,placement:u,popperOptions:m,popperRef:w,slotProps:b={},slots:y={},TransitionProps:f}=t,h=xe(t,Fw),E=M.useRef(null),I=xt(E,n),j=M.useRef(null),k=xt(j,w),g=M.useRef(k);Lt(()=>{g.current=k},[k]),M.useImperativeHandle(w,()=>j.current,[]);const P=Gw(u,i),[V,U]=M.useState(P),[T,R]=M.useState(Jn(o));M.useEffect(()=>{j.current&&j.current.forceUpdate()}),M.useEffect(()=>{o&&R(Jn(o))},[o]),Lt(()=>{if(!T||!d)return;const Y=ae=>{U(ae.placement)};if(process.env.NODE_ENV!=="production"&&T&&gr(T)&&T.nodeType===1){const ae=T.getBoundingClientRect();process.env.NODE_ENV!=="test"&&ae.top===0&&ae.left===0&&ae.right===0&&ae.bottom===0&&console.warn(["MUI: The `anchorEl` prop provided to the component is invalid.","The anchor element should be part of the document layout.","Make sure the element is present in the document or that it's not display none."].join(` -`))}let z=[{name:"preventOverflow",options:{altBoundary:l}},{name:"flip",options:{altBoundary:l}},{name:"onUpdate",enabled:!0,phase:"afterWrite",fn:({state:ae})=>{Y(ae)}}];c!=null&&(z=z.concat(c)),m&&m.modifiers!=null&&(z=z.concat(m.modifiers));const ee=Vw(T,E.current,O({placement:P},m,{modifiers:z}));return g.current(ee),()=>{ee.destroy(),g.current(null)}},[T,l,c,d,m,P]);const N={placement:V};f!==null&&(N.TransitionProps=f);const D=qw(),$=(r=y.root)!=null?r:"div",J=Op({elementType:$,externalSlotProps:b.root,externalForwardedProps:h,additionalProps:{role:"tooltip",ref:I},ownerState:t,className:D.root});return a.jsx($,O({},J,{children:typeof s=="function"?s(N):s}))}),di=M.forwardRef(function(t,n){const{anchorEl:r,children:o,container:s,direction:i="ltr",disablePortal:l=!1,keepMounted:c=!1,modifiers:d,open:u,placement:m="bottom",popperOptions:w=Hw,popperRef:b,style:y,transition:f=!1,slotProps:h={},slots:E={}}=t,I=xe(t,zw),[j,k]=M.useState(!0),g=()=>{k(!1)},P=()=>{k(!0)};if(!c&&!u&&(!f||j))return null;let V;if(s)V=s;else if(r){const R=Jn(r);V=R&&gr(R)?Hn(R).body:Hn(null).body}const U=!u&&c&&(!f||j)?"none":void 0,T=f?{in:u,onEnter:g,onExited:P}:void 0;return a.jsx(Wn,{disablePortal:l,container:V,children:a.jsx(Xw,O({anchorEl:r,direction:i,disablePortal:l,modifiers:d,ref:n,open:f?!j:u,placement:m,popperOptions:w,popperRef:b,slotProps:h,slots:E},I,{style:O({position:"fixed",top:0,left:0,display:U},y),TransitionProps:T,children:o}))})});process.env.NODE_ENV!=="production"&&(di.propTypes={anchorEl:wo(p.oneOfType([bn,p.object,p.func]),e=>{if(e.open){const t=Jn(e.anchorEl);if(t&&gr(t)&&t.nodeType===1){const n=t.getBoundingClientRect();if(process.env.NODE_ENV!=="test"&&n.top===0&&n.left===0&&n.right===0&&n.bottom===0)return new Error(["MUI: The `anchorEl` prop provided to the component is invalid.","The anchor element should be part of the document layout.","Make sure the element is present in the document or that it's not display none."].join(` -`))}else if(!t||typeof t.getBoundingClientRect!="function"||Uw(t)&&t.contextElement!=null&&t.contextElement.nodeType!==1)return new Error(["MUI: The `anchorEl` prop provided to the component is invalid.","It should be an HTML element instance or a virtualElement ","(https://popper.js.org/docs/v2/virtual-elements/)."].join(` -`))}return null}),children:p.oneOfType([p.node,p.func]),container:p.oneOfType([bn,p.func]),direction:p.oneOf(["ltr","rtl"]),disablePortal:p.bool,keepMounted:p.bool,modifiers:p.arrayOf(p.shape({data:p.object,effect:p.func,enabled:p.bool,fn:p.func,name:p.any,options:p.object,phase:p.oneOf(["afterMain","afterRead","afterWrite","beforeMain","beforeRead","beforeWrite","main","read","write"]),requires:p.arrayOf(p.string),requiresIfExists:p.arrayOf(p.string)})),open:p.bool.isRequired,placement:p.oneOf(["auto-end","auto-start","auto","bottom-end","bottom-start","bottom","left-end","left-start","left","right-end","right-start","right","top-end","top-start","top"]),popperOptions:p.shape({modifiers:p.array,onFirstUpdate:p.func,placement:p.oneOf(["auto-end","auto-start","auto","bottom-end","bottom-start","bottom","left-end","left-start","left","right-end","right-start","right","top-end","top-start","top"]),strategy:p.oneOf(["absolute","fixed"])}),popperRef:Da,slotProps:p.shape({root:p.oneOfType([p.func,p.object])}),slots:p.shape({root:p.elementType}),transition:p.bool});function ui(){const e=Ya(No);return process.env.NODE_ENV!=="production"&&M.useDebugValue(e),e[ko]||e}function Yr(e,t){return Yr=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,o){return r.__proto__=o,r},Yr(e,t)}function Yw(e,t){e.prototype=Object.create(t.prototype),e.prototype.constructor=e,Yr(e,t)}const Bs={disabled:!1};var Ww=process.env.NODE_ENV!=="production"?p.oneOfType([p.number,p.shape({enter:p.number,exit:p.number,appear:p.number}).isRequired]):null;process.env.NODE_ENV!=="production"&&p.oneOfType([p.string,p.shape({enter:p.string,exit:p.string,active:p.string}),p.shape({enter:p.string,enterDone:p.string,enterActive:p.string,exit:p.string,exitDone:p.string,exitActive:p.string})]);const pi=v.createContext(null);var Kw=function(t){return t.scrollTop},dn="unmounted",wt="exited",ft="entering",$t="entered",Wr="exiting",nt=function(e){Yw(t,e);function t(r,o){var s;s=e.call(this,r,o)||this;var i=o,l=i&&!i.isMounting?r.enter:r.appear,c;return s.appearStatus=null,r.in?l?(c=wt,s.appearStatus=ft):c=$t:r.unmountOnExit||r.mountOnEnter?c=dn:c=wt,s.state={status:c},s.nextCallback=null,s}t.getDerivedStateFromProps=function(o,s){var i=o.in;return i&&s.status===dn?{status:wt}:null};var n=t.prototype;return n.componentDidMount=function(){this.updateStatus(!0,this.appearStatus)},n.componentDidUpdate=function(o){var s=null;if(o!==this.props){var i=this.state.status;this.props.in?i!==ft&&i!==$t&&(s=ft):(i===ft||i===$t)&&(s=Wr)}this.updateStatus(!1,s)},n.componentWillUnmount=function(){this.cancelNextCallback()},n.getTimeouts=function(){var o=this.props.timeout,s,i,l;return s=i=l=o,o!=null&&typeof o!="number"&&(s=o.exit,i=o.enter,l=o.appear!==void 0?o.appear:i),{exit:s,enter:i,appear:l}},n.updateStatus=function(o,s){if(o===void 0&&(o=!1),s!==null)if(this.cancelNextCallback(),s===ft){if(this.props.unmountOnExit||this.props.mountOnEnter){var i=this.props.nodeRef?this.props.nodeRef.current:sn.findDOMNode(this);i&&Kw(i)}this.performEnter(o)}else this.performExit();else this.props.unmountOnExit&&this.state.status===wt&&this.setState({status:dn})},n.performEnter=function(o){var s=this,i=this.props.enter,l=this.context?this.context.isMounting:o,c=this.props.nodeRef?[l]:[sn.findDOMNode(this),l],d=c[0],u=c[1],m=this.getTimeouts(),w=l?m.appear:m.enter;if(!o&&!i||Bs.disabled){this.safeSetState({status:$t},function(){s.props.onEntered(d)});return}this.props.onEnter(d,u),this.safeSetState({status:ft},function(){s.props.onEntering(d,u),s.onTransitionEnd(w,function(){s.safeSetState({status:$t},function(){s.props.onEntered(d,u)})})})},n.performExit=function(){var o=this,s=this.props.exit,i=this.getTimeouts(),l=this.props.nodeRef?void 0:sn.findDOMNode(this);if(!s||Bs.disabled){this.safeSetState({status:wt},function(){o.props.onExited(l)});return}this.props.onExit(l),this.safeSetState({status:Wr},function(){o.props.onExiting(l),o.onTransitionEnd(i.exit,function(){o.safeSetState({status:wt},function(){o.props.onExited(l)})})})},n.cancelNextCallback=function(){this.nextCallback!==null&&(this.nextCallback.cancel(),this.nextCallback=null)},n.safeSetState=function(o,s){s=this.setNextCallback(s),this.setState(o,s)},n.setNextCallback=function(o){var s=this,i=!0;return this.nextCallback=function(l){i&&(i=!1,s.nextCallback=null,o(l))},this.nextCallback.cancel=function(){i=!1},this.nextCallback},n.onTransitionEnd=function(o,s){this.setNextCallback(s);var i=this.props.nodeRef?this.props.nodeRef.current:sn.findDOMNode(this),l=o==null&&!this.props.addEndListener;if(!i||l){setTimeout(this.nextCallback,0);return}if(this.props.addEndListener){var c=this.props.nodeRef?[this.nextCallback]:[i,this.nextCallback],d=c[0],u=c[1];this.props.addEndListener(d,u)}o!=null&&setTimeout(this.nextCallback,o)},n.render=function(){var o=this.state.status;if(o===dn)return null;var s=this.props,i=s.children;s.in,s.mountOnEnter,s.unmountOnExit,s.appear,s.enter,s.exit,s.timeout,s.addEndListener,s.onEnter,s.onEntering,s.onEntered,s.onExit,s.onExiting,s.onExited,s.nodeRef;var l=xe(s,["children","in","mountOnEnter","unmountOnExit","appear","enter","exit","timeout","addEndListener","onEnter","onEntering","onEntered","onExit","onExiting","onExited","nodeRef"]);return v.createElement(pi.Provider,{value:null},typeof i=="function"?i(o,l):v.cloneElement(v.Children.only(i),l))},t}(v.Component);nt.contextType=pi;nt.propTypes=process.env.NODE_ENV!=="production"?{nodeRef:p.shape({current:typeof Element>"u"?p.any:function(e,t,n,r,o,s){var i=e[t];return p.instanceOf(i&&"ownerDocument"in i?i.ownerDocument.defaultView.Element:Element)(e,t,n,r,o,s)}}),children:p.oneOfType([p.func.isRequired,p.element.isRequired]).isRequired,in:p.bool,mountOnEnter:p.bool,unmountOnExit:p.bool,appear:p.bool,enter:p.bool,exit:p.bool,timeout:function(t){var n=Ww;t.addEndListener||(n=n.isRequired);for(var r=arguments.length,o=new Array(r>1?r-1:0),s=1;se.scrollTop;function Vs(e,t){var n,r;const{timeout:o,easing:s,style:i={}}=e;return{duration:(n=i.transitionDuration)!=null?n:typeof o=="number"?o:o[t.mode]||0,easing:(r=i.transitionTimingFunction)!=null?r:typeof s=="object"?s[t.mode]:s,delay:i.transitionDelay}}const Qw=["addEndListener","appear","children","easing","in","onEnter","onEntered","onEntering","onExit","onExited","onExiting","style","timeout","TransitionComponent"];function Kr(e){return`scale(${e}, ${e**2})`}const ef={entering:{opacity:1,transform:Kr(1)},entered:{opacity:1,transform:"none"}},Mr=typeof navigator<"u"&&/^((?!chrome|android).)*(safari|mobile)/i.test(navigator.userAgent)&&/(os |version\/)15(.|_)4/i.test(navigator.userAgent),Io=M.forwardRef(function(t,n){const{addEndListener:r,appear:o=!0,children:s,easing:i,in:l,onEnter:c,onEntered:d,onEntering:u,onExit:m,onExited:w,onExiting:b,style:y,timeout:f="auto",TransitionComponent:h=Jw}=t,E=xe(t,Qw),I=ln(),j=M.useRef(),k=ui(),g=M.useRef(null),P=xt(g,s.ref,n),V=Y=>z=>{if(Y){const ee=g.current;z===void 0?Y(ee):Y(ee,z)}},U=V(u),T=V((Y,z)=>{Zw(Y);const{duration:ee,delay:ae,easing:oe}=Vs({style:y,timeout:f,easing:i},{mode:"enter"});let x;f==="auto"?(x=k.transitions.getAutoHeightDuration(Y.clientHeight),j.current=x):x=ee,Y.style.transition=[k.transitions.create("opacity",{duration:x,delay:ae}),k.transitions.create("transform",{duration:Mr?x:x*.666,delay:ae,easing:oe})].join(","),c&&c(Y,z)}),R=V(d),N=V(b),D=V(Y=>{const{duration:z,delay:ee,easing:ae}=Vs({style:y,timeout:f,easing:i},{mode:"exit"});let oe;f==="auto"?(oe=k.transitions.getAutoHeightDuration(Y.clientHeight),j.current=oe):oe=z,Y.style.transition=[k.transitions.create("opacity",{duration:oe,delay:ee}),k.transitions.create("transform",{duration:Mr?oe:oe*.666,delay:Mr?ee:ee||oe*.333,easing:ae})].join(","),Y.style.opacity=0,Y.style.transform=Kr(.75),m&&m(Y)}),$=V(w),J=Y=>{f==="auto"&&I.start(j.current||0,Y),r&&r(g.current,Y)};return a.jsx(h,O({appear:o,in:l,nodeRef:g,onEnter:T,onEntered:R,onEntering:U,onExit:D,onExited:$,onExiting:N,addEndListener:J,timeout:f==="auto"?null:f},E,{children:(Y,z)=>M.cloneElement(s,O({style:O({opacity:0,transform:Kr(.75),visibility:Y==="exited"&&!l?"hidden":void 0},ef[Y],y,s.props.style),ref:P},z))}))});process.env.NODE_ENV!=="production"&&(Io.propTypes={addEndListener:p.func,appear:p.bool,children:$a.isRequired,easing:p.oneOfType([p.shape({enter:p.string,exit:p.string}),p.string]),in:p.bool,onEnter:p.func,onEntered:p.func,onEntering:p.func,onExit:p.func,onExited:p.func,onExiting:p.func,style:p.object,timeout:p.oneOfType([p.oneOf(["auto"]),p.number,p.shape({appear:p.number,enter:p.number,exit:p.number})])});Io.muiSupportAuto=!0;const Ls=Io,tf=["anchorEl","component","components","componentsProps","container","disablePortal","keepMounted","modifiers","open","placement","popperOptions","popperRef","transition","slots","slotProps"],nf=Rn(di,{name:"MuiPopper",slot:"Root",overridesResolver:(e,t)=>t.root})({}),wi=M.forwardRef(function(t,n){var r;const o=Xa(),s=Eo({props:t,name:"MuiPopper"}),{anchorEl:i,component:l,components:c,componentsProps:d,container:u,disablePortal:m,keepMounted:w,modifiers:b,open:y,placement:f,popperOptions:h,popperRef:E,transition:I,slots:j,slotProps:k}=s,g=xe(s,tf),P=(r=j==null?void 0:j.root)!=null?r:c==null?void 0:c.Root,V=O({anchorEl:i,container:u,disablePortal:m,keepMounted:w,modifiers:b,open:y,placement:f,popperOptions:h,popperRef:E,transition:I},g);return a.jsx(nf,O({as:l,direction:o==null?void 0:o.direction,slots:{root:P},slotProps:k??d},V,{ref:n}))});process.env.NODE_ENV!=="production"&&(wi.propTypes={anchorEl:p.oneOfType([bn,p.object,p.func]),children:p.oneOfType([p.node,p.func]),component:p.elementType,components:p.shape({Root:p.elementType}),componentsProps:p.shape({root:p.oneOfType([p.func,p.object])}),container:p.oneOfType([bn,p.func]),disablePortal:p.bool,keepMounted:p.bool,modifiers:p.arrayOf(p.shape({data:p.object,effect:p.func,enabled:p.bool,fn:p.func,name:p.any,options:p.object,phase:p.oneOf(["afterMain","afterRead","afterWrite","beforeMain","beforeRead","beforeWrite","main","read","write"]),requires:p.arrayOf(p.string),requiresIfExists:p.arrayOf(p.string)})),open:p.bool.isRequired,placement:p.oneOf(["auto-end","auto-start","auto","bottom-end","bottom-start","bottom","left-end","left-start","left","right-end","right-start","right","top-end","top-start","top"]),popperOptions:p.shape({modifiers:p.array,onFirstUpdate:p.func,placement:p.oneOf(["auto-end","auto-start","auto","bottom-end","bottom-start","bottom","left-end","left-start","left","right-end","right-start","right","top-end","top-start","top"]),strategy:p.oneOf(["absolute","fixed"])}),popperRef:Da,slotProps:p.shape({root:p.oneOfType([p.func,p.object])}),slots:p.shape({root:p.elementType}),sx:p.oneOfType([p.arrayOf(p.oneOfType([p.func,p.object,p.bool])),p.func,p.object]),transition:p.bool});const fi=wi;function rf(e){return ar("MuiTooltip",e)}const of=Ga("MuiTooltip",["popper","popperInteractive","popperArrow","popperClose","tooltip","tooltipArrow","touch","tooltipPlacementLeft","tooltipPlacementRight","tooltipPlacementTop","tooltipPlacementBottom","arrow"]),st=of,sf=["arrow","children","classes","components","componentsProps","describeChild","disableFocusListener","disableHoverListener","disableInteractive","disableTouchListener","enterDelay","enterNextDelay","enterTouchDelay","followCursor","id","leaveDelay","leaveTouchDelay","onClose","onOpen","open","placement","PopperComponent","PopperProps","slotProps","slots","title","TransitionComponent","TransitionProps"];function af(e){return Math.round(e*1e5)/1e5}const lf=e=>{const{classes:t,disableInteractive:n,arrow:r,touch:o,placement:s}=e,i={popper:["popper",!n&&"popperInteractive",r&&"popperArrow"],tooltip:["tooltip",r&&"tooltipArrow",o&&"touch",`tooltipPlacement${Ye(s.split("-")[0])}`],arrow:["arrow"]};return mo(i,rf,t)},cf=Rn(fi,{name:"MuiTooltip",slot:"Popper",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.popper,!n.disableInteractive&&t.popperInteractive,n.arrow&&t.popperArrow,!n.open&&t.popperClose]}})(({theme:e,ownerState:t,open:n})=>O({zIndex:(e.vars||e).zIndex.tooltip,pointerEvents:"none"},!t.disableInteractive&&{pointerEvents:"auto"},!n&&{pointerEvents:"none"},t.arrow&&{[`&[data-popper-placement*="bottom"] .${st.arrow}`]:{top:0,marginTop:"-0.71em","&::before":{transformOrigin:"0 100%"}},[`&[data-popper-placement*="top"] .${st.arrow}`]:{bottom:0,marginBottom:"-0.71em","&::before":{transformOrigin:"100% 0"}},[`&[data-popper-placement*="right"] .${st.arrow}`]:O({},t.isRtl?{right:0,marginRight:"-0.71em"}:{left:0,marginLeft:"-0.71em"},{height:"1em",width:"0.71em","&::before":{transformOrigin:"100% 100%"}}),[`&[data-popper-placement*="left"] .${st.arrow}`]:O({},t.isRtl?{left:0,marginLeft:"-0.71em"}:{right:0,marginRight:"-0.71em"},{height:"1em",width:"0.71em","&::before":{transformOrigin:"0 0"}})})),df=Rn("div",{name:"MuiTooltip",slot:"Tooltip",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.tooltip,n.touch&&t.touch,n.arrow&&t.tooltipArrow,t[`tooltipPlacement${Ye(n.placement.split("-")[0])}`]]}})(({theme:e,ownerState:t})=>O({backgroundColor:e.vars?e.vars.palette.Tooltip.bg:Wa(e.palette.grey[700],.92),borderRadius:(e.vars||e).shape.borderRadius,color:(e.vars||e).palette.common.white,fontFamily:e.typography.fontFamily,padding:"4px 8px",fontSize:e.typography.pxToRem(11),maxWidth:300,margin:2,wordWrap:"break-word",fontWeight:e.typography.fontWeightMedium},t.arrow&&{position:"relative",margin:0},t.touch&&{padding:"8px 16px",fontSize:e.typography.pxToRem(14),lineHeight:`${af(16/14)}em`,fontWeight:e.typography.fontWeightRegular},{[`.${st.popper}[data-popper-placement*="left"] &`]:O({transformOrigin:"right center"},t.isRtl?O({marginLeft:"14px"},t.touch&&{marginLeft:"24px"}):O({marginRight:"14px"},t.touch&&{marginRight:"24px"})),[`.${st.popper}[data-popper-placement*="right"] &`]:O({transformOrigin:"left center"},t.isRtl?O({marginRight:"14px"},t.touch&&{marginRight:"24px"}):O({marginLeft:"14px"},t.touch&&{marginLeft:"24px"})),[`.${st.popper}[data-popper-placement*="top"] &`]:O({transformOrigin:"center bottom",marginBottom:"14px"},t.touch&&{marginBottom:"24px"}),[`.${st.popper}[data-popper-placement*="bottom"] &`]:O({transformOrigin:"center top",marginTop:"14px"},t.touch&&{marginTop:"24px"})})),uf=Rn("span",{name:"MuiTooltip",slot:"Arrow",overridesResolver:(e,t)=>t.arrow})(({theme:e})=>({overflow:"hidden",position:"absolute",width:"1em",height:"0.71em",boxSizing:"border-box",color:e.vars?e.vars.palette.Tooltip.bg:Wa(e.palette.grey[700],.9),"&::before":{content:'""',margin:"auto",display:"block",width:"100%",height:"100%",backgroundColor:"currentColor",transform:"rotate(45deg)"}}));let Ln=!1;const Fs=new Cn;let on={x:0,y:0};function Fn(e,t){return n=>{t&&t(n),e(n)}}const mi=M.forwardRef(function(t,n){var r,o,s,i,l,c,d,u,m,w,b,y,f,h,E,I,j,k,g;const P=Eo({props:t,name:"MuiTooltip"}),{arrow:V=!1,children:U,components:T={},componentsProps:R={},describeChild:N=!1,disableFocusListener:D=!1,disableHoverListener:$=!1,disableInteractive:J=!1,disableTouchListener:Y=!1,enterDelay:z=100,enterNextDelay:ee=0,enterTouchDelay:ae=700,followCursor:oe=!1,id:x,leaveDelay:C=0,leaveTouchDelay:L=1500,onClose:F,onOpen:B,open:X,placement:q="bottom",PopperComponent:H,PopperProps:G={},slotProps:K={},slots:Z={},title:ue,TransitionComponent:_=Ls,TransitionProps:ye}=P,A=xe(P,sf),ve=M.isValidElement(U)?U:a.jsx("span",{children:U}),ze=ui(),lt=ze.direction==="rtl",[Ee,In]=M.useState(),[Ge,Et]=M.useState(null),ct=M.useRef(!1),St=J||oe,Tt=ln(),Ct=ln(),dt=ln(),Wt=ln(),[$n,Mo]=Ba({controlled:X,default:!1,name:"Tooltip",state:"open"});let Ke=$n;if(process.env.NODE_ENV!=="production"){const{current:Q}=M.useRef(X!==void 0);M.useEffect(()=>{Ee&&Ee.disabled&&!Q&&ue!==""&&Ee.tagName.toLowerCase()==="button"&&console.error(["MUI: You are providing a disabled `button` child to the Tooltip component.","A disabled element does not fire events.","Tooltip needs to listen to the child element's events to display the title.","","Add a simple wrapper element, such as a `span`."].join(` -`))},[ue,Ee,Q])}const br=Aa(x),Kt=M.useRef(),Mn=Ur(()=>{Kt.current!==void 0&&(document.body.style.WebkitUserSelect=Kt.current,Kt.current=void 0),Wt.clear()});M.useEffect(()=>Mn,[Mn]);const Do=Q=>{Fs.clear(),Ln=!0,Mo(!0),B&&!Ke&&B(Q)},Dn=Ur(Q=>{Fs.start(800+C,()=>{Ln=!1}),Mo(!1),F&&Ke&&F(Q),Tt.start(ze.transitions.duration.shortest,()=>{ct.current=!1})}),vr=Q=>{ct.current&&Q.type!=="touchstart"||(Ee&&Ee.removeAttribute("title"),Ct.clear(),dt.clear(),z||Ln&&ee?Ct.start(Ln?ee:z,()=>{Do(Q)}):Do(Q))},Ao=Q=>{Ct.clear(),dt.start(C,()=>{Dn(Q)})},{isFocusVisibleRef:Bo,onBlur:Ai,onFocus:Bi,ref:Vi}=Va(),[,Vo]=M.useState(!1),Lo=Q=>{Ai(Q),Bo.current===!1&&(Vo(!1),Ao(Q))},Fo=Q=>{Ee||In(Q.currentTarget),Bi(Q),Bo.current===!0&&(Vo(!0),vr(Q))},zo=Q=>{ct.current=!0;const Re=ve.props;Re.onTouchStart&&Re.onTouchStart(Q)},Go=vr,Uo=Ao,Li=Q=>{zo(Q),dt.clear(),Tt.clear(),Mn(),Kt.current=document.body.style.WebkitUserSelect,document.body.style.WebkitUserSelect="none",Wt.start(ae,()=>{document.body.style.WebkitUserSelect=Kt.current,vr(Q)})},Fi=Q=>{ve.props.onTouchEnd&&ve.props.onTouchEnd(Q),Mn(),dt.start(L,()=>{Dn(Q)})};M.useEffect(()=>{if(!Ke)return;function Q(Re){(Re.key==="Escape"||Re.key==="Esc")&&Dn(Re)}return document.addEventListener("keydown",Q),()=>{document.removeEventListener("keydown",Q)}},[Dn,Ke]);const zi=xt(ve.ref,Vi,In,n);!ue&&ue!==0&&(Ke=!1);const yr=M.useRef(),Gi=Q=>{const Re=ve.props;Re.onMouseMove&&Re.onMouseMove(Q),on={x:Q.clientX,y:Q.clientY},yr.current&&yr.current.update()},Jt={},xr=typeof ue=="string";N?(Jt.title=!Ke&&xr&&!$?ue:null,Jt["aria-describedby"]=Ke?br:null):(Jt["aria-label"]=xr?ue:null,Jt["aria-labelledby"]=Ke&&!xr?br:null);const Me=O({},Jt,A,ve.props,{className:ot(A.className,ve.props.className),onTouchStart:zo,ref:zi},oe?{onMouseMove:Gi}:{});process.env.NODE_ENV!=="production"&&(Me["data-mui-internal-clone-element"]=!0,M.useEffect(()=>{Ee&&!Ee.getAttribute("data-mui-internal-clone-element")&&console.error(["MUI: The `children` component of the Tooltip is not forwarding its props correctly.","Please make sure that props are spread on the same element that the ref is applied to."].join(` -`))},[Ee]));const Zt={};Y||(Me.onTouchStart=Li,Me.onTouchEnd=Fi),$||(Me.onMouseOver=Fn(Go,Me.onMouseOver),Me.onMouseLeave=Fn(Uo,Me.onMouseLeave),St||(Zt.onMouseOver=Go,Zt.onMouseLeave=Uo)),D||(Me.onFocus=Fn(Fo,Me.onFocus),Me.onBlur=Fn(Lo,Me.onBlur),St||(Zt.onFocus=Fo,Zt.onBlur=Lo)),process.env.NODE_ENV!=="production"&&ve.props.title&&console.error(["MUI: You have provided a `title` prop to the child of .",`Remove this title prop \`${ve.props.title}\` or the Tooltip component.`].join(` -`));const Ui=M.useMemo(()=>{var Q;let Re=[{name:"arrow",enabled:!!Ge,options:{element:Ge,padding:4}}];return(Q=G.popperOptions)!=null&&Q.modifiers&&(Re=Re.concat(G.popperOptions.modifiers)),O({},G.popperOptions,{modifiers:Re})},[Ge,G]),Qt=O({},P,{isRtl:lt,arrow:V,disableInteractive:St,placement:q,PopperComponentProp:H,touch:ct.current}),Nr=lf(Qt),qo=(r=(o=Z.popper)!=null?o:T.Popper)!=null?r:cf,Ho=(s=(i=(l=Z.transition)!=null?l:T.Transition)!=null?i:_)!=null?s:Ls,Xo=(c=(d=Z.tooltip)!=null?d:T.Tooltip)!=null?c:df,Yo=(u=(m=Z.arrow)!=null?m:T.Arrow)!=null?u:uf,qi=cn(qo,O({},G,(w=K.popper)!=null?w:R.popper,{className:ot(Nr.popper,G==null?void 0:G.className,(b=(y=K.popper)!=null?y:R.popper)==null?void 0:b.className)}),Qt),Hi=cn(Ho,O({},ye,(f=K.transition)!=null?f:R.transition),Qt),Xi=cn(Xo,O({},(h=K.tooltip)!=null?h:R.tooltip,{className:ot(Nr.tooltip,(E=(I=K.tooltip)!=null?I:R.tooltip)==null?void 0:E.className)}),Qt),Yi=cn(Yo,O({},(j=K.arrow)!=null?j:R.arrow,{className:ot(Nr.arrow,(k=(g=K.arrow)!=null?g:R.arrow)==null?void 0:k.className)}),Qt);return a.jsxs(M.Fragment,{children:[M.cloneElement(ve,Me),a.jsx(qo,O({as:H??fi,placement:q,anchorEl:oe?{getBoundingClientRect:()=>({top:on.y,left:on.x,right:on.x,bottom:on.y,width:0,height:0})}:Ee,popperRef:yr,open:Ee?Ke:!1,id:br,transition:!0},Zt,qi,{popperOptions:Ui,children:({TransitionProps:Q})=>a.jsx(Ho,O({timeout:ze.transitions.duration.shorter},Q,Hi,{children:a.jsxs(Xo,O({},Xi,{children:[ue,V?a.jsx(Yo,O({},Yi,{ref:Et})):null]}))}))}))]})});process.env.NODE_ENV!=="production"&&(mi.propTypes={arrow:p.bool,children:$a.isRequired,classes:p.object,className:p.string,components:p.shape({Arrow:p.elementType,Popper:p.elementType,Tooltip:p.elementType,Transition:p.elementType}),componentsProps:p.shape({arrow:p.object,popper:p.object,tooltip:p.object,transition:p.object}),describeChild:p.bool,disableFocusListener:p.bool,disableHoverListener:p.bool,disableInteractive:p.bool,disableTouchListener:p.bool,enterDelay:p.number,enterNextDelay:p.number,enterTouchDelay:p.number,followCursor:p.bool,id:p.string,leaveDelay:p.number,leaveTouchDelay:p.number,onClose:p.func,onOpen:p.func,open:p.bool,placement:p.oneOf(["bottom-end","bottom-start","bottom","left-end","left-start","left","right-end","right-start","right","top-end","top-start","top"]),PopperComponent:p.elementType,PopperProps:p.object,slotProps:p.shape({arrow:p.object,popper:p.object,tooltip:p.object,transition:p.object}),slots:p.shape({arrow:p.elementType,popper:p.elementType,tooltip:p.elementType,transition:p.elementType}),sx:p.oneOfType([p.arrayOf(p.oneOfType([p.func,p.object,p.bool])),p.func,p.object]),title:p.node,TransitionComponent:p.elementType,TransitionProps:p.object});const pf=mi;function zs(e,t,n){return e?a.jsx(Ie.ListItemIcon,{className:`papi-menu-icon-${n?"leading":"trailing"}`,children:a.jsx("img",{src:e,alt:`${n?"Leading":"Trailing"} icon for ${t}`})}):void 0}function $o(e){const{onClick:t,label:n,tooltip:r,allowForLeadingIcons:o=!0,iconPathBefore:s=void 0,iconPathAfter:i=void 0,hasAutoFocus:l=!1,className:c,isDisabled:d=!1,isDense:u=!0,isSubMenuParent:m=!1,hasDisabledGutters:w=!1,hasDivider:b=!1,focusVisibleClassName:y,id:f,children:h}=e,E=a.jsx(Ie.MenuItem,{sx:{lineHeight:.8},autoFocus:l,className:c,disabled:d,dense:u,disableGutters:w,divider:b,focusVisibleClassName:y,onClick:t,id:f,children:n?a.jsxs(a.Fragment,{children:[zs(s,n,!0),a.jsx(Ie.ListItemText,{primary:n,inset:!s&&o}),m?a.jsx(Ie.ListItemIcon,{className:"papi-menu-icon-trailing",children:a.jsx(Ja,{})}):zs(i,n,!1)]}):h});return r?a.jsx(pf,{title:r,placement:"right",children:a.jsx("div",{children:E})}):E}function hi(e){return Object.entries(e.groups).map(([n,r])=>({id:n,group:r}))}function wf(e){const[t,n]=v.useState(void 0),{parentMenuItem:r,parentItemProps:o,menuDefinition:s}=e,i=d=>{n(d.currentTarget)},l=()=>{n(void 0)},c=()=>{let d=hi(s).filter(u=>"menuItem"in u.group);if(!(r!=null&&r.id))throw new Error("A valid parent menu item is required for submenus.");return d=d.filter(u=>"menuItem"in u.group&&u.group.menuItem===r.id),a.jsx(gi,{...e,includedGroups:d})};return a.jsxs(a.Fragment,{children:[a.jsx($o,{onClick:i,...o,isSubMenuParent:!0}),a.jsx(Ie.Menu,{anchorEl:t,open:!!t,onClose:l,anchorOrigin:{vertical:"top",horizontal:"right"},transformOrigin:{vertical:"top",horizontal:"left"},children:c()},r.id)]})}const ff=(e,t)=>t.filter(o=>o.group===e).sort((o,s)=>(o.order||0)-(s.order||0));function gi(e){const{menuDefinition:t,onClick:n,commandHandler:r,includedGroups:o}=e,{items:s,allowForLeadingIcons:i}=v.useMemo(()=>{const u=o&&o.length>0?o:hi(t).filter(y=>!("menuItem"in y.group)),m=Object.values(u).sort((y,f)=>(y.group.order||0)-(f.group.order||0)),w=[];m.forEach(y=>{ff(y.id,t.items).forEach(f=>w.push({item:f,isLastItemInGroup:!1})),w.length>0&&(w[w.length-1].isLastItemInGroup=!0)}),w.length>0&&(w[w.length-1].isLastItemInGroup=!1);const b=w.some(y=>"iconPathBefore"in y.item&&y.item.iconPathBefore);return{items:w,allowForLeadingIcons:b}},[o,t]),l=({item:u,isLastItemInGroup:m})=>({className:"papi-menu-item",label:u.label,tooltip:u.tooltip,iconPathBefore:"iconPathBefore"in u?u.iconPathBefore:void 0,iconPathAfter:"iconPathAfter"in u?u.iconPathAfter:void 0,hasDivider:m,allowForLeadingIcons:i}),[c]=s;if(!c)return a.jsx("div",{});const d=c.item.group;return a.jsx("div",{role:"menu","aria-label":d,children:s.map((u,m)=>{const{item:w}=u,b=l(u);if("command"in w){const y=w.group+m;return a.jsx($o,{onClick:f=>{n==null||n(f),r(w)},...b},y)}return a.jsx(wf,{parentMenuItem:w,parentItemProps:b,...e},d+w.id)})},d)}function mf(e){const{menuDefinition:t,columnId:n}=e;let s=Object.entries(t.groups).map(([i,l])=>({id:i,group:l})).filter(i=>"column"in i.group);return n&&"columns"in t&&t.columns[n]&&(s=s.filter(i=>"column"in i.group&&i.group.column===n)),a.jsx(gi,{...e,includedGroups:s})}function hf({commandHandler:e,menuDefinition:t,id:n,metadata:r,onClick:o,className:s}){return a.jsxs(Ie.Grid,{id:n,item:!0,xs:"auto",role:"menu","aria-label":n,className:`papi-menu-column ${s??""}`,children:[a.jsx("h3",{"aria-label":r.label,className:`papi-menu-column-header ${s??""}`,children:r.label}),a.jsx(Ie.List,{id:n,dense:!0,className:s??"",children:a.jsx(mf,{commandHandler:e,menuDefinition:t,columnId:n,onClick:o})})]})}function bi({commandHandler:e,className:t,multiColumnMenu:n,id:r}){const{columns:o}=n,s=v.useMemo(()=>{const i=new Map;return Object.getOwnPropertyNames(o).forEach(l=>{if(l==="isExtensible")return;const c=l,d=o[c];typeof d=="object"&&typeof d.order=="number"&&!Number.isNaN(d.order)?i.set(d.order,{id:c,metadata:d}):console.warn(`Property ${l} (${typeof d}) on menu ${r} is not a valid column and is being ignored. This might indicate data corruption`)}),Array.from(i.values()).sort((l,c)=>(l.metadata.order||0)-(c.metadata.order||0))},[o,r]);return a.jsx(Ie.Grid,{container:!0,spacing:0,className:`papi-multi-column-menu ${t??""}`,columns:s.length,role:"menu","aria-label":"GridMenu",id:r,children:s.map((i,l)=>a.jsx(hf,{commandHandler:e,menuDefinition:n,...i,className:t},l))})}function gf(e){return{preserveValue:!0,...e}}const Zn=(e,t,n={})=>{const r=v.useRef(t);r.current=t;const o=v.useRef(n);o.current=gf(o.current);const[s,i]=v.useState(()=>r.current),[l,c]=v.useState(!0);return v.useEffect(()=>{let d=!0;return c(!!e),(async()=>{if(e){const u=await e();d&&(i(()=>u),c(!1))}})(),()=>{d=!1,o.current.preserveValue||i(()=>r.current)}},[e]),[s,l]},bf=Ka(a.jsx("path",{d:"M3 18h18v-2H3zm0-5h18v-2H3zm0-7v2h18V6z"}),"Menu");function vi({menuProvider:e,normalMenu:t,fullMenu:n,commandHandler:r,containerRef:o,className:s,ariaLabelPrefix:i,children:l}){const[c,d]=v.useState(!1),[u,m]=v.useState(!1),w=v.useCallback(()=>{c&&d(!1),m(!1)},[c]),b=v.useCallback(k=>{k.stopPropagation(),d(g=>{const P=!g;return P&&k.shiftKey?m(!0):P||m(!1),P})},[]),y=v.useCallback(k=>(w(),r(k)),[r,w]),[f,h]=v.useState({top:1,left:1});v.useEffect(()=>{if(c){const k=o==null?void 0:o.current;if(k){const g=k.getBoundingClientRect(),P=window.scrollY,V=window.scrollX,U=g.top+P+k.clientHeight,T=g.left+V;h({top:U,left:T})}}},[c,o]);const[E]=Zn(v.useCallback(async()=>(e==null?void 0:e(!1))??t,[e,t,c]),t),[I]=Zn(v.useCallback(async()=>(e==null?void 0:e(!0))??n??E,[e,n,E,c]),n??E),j=u&&I?I:E;return a.jsxs(a.Fragment,{children:[a.jsx(Ie.IconButton,{sx:{paddingTop:0,paddingBottom:0},edge:"start",className:`papi-menuButton ${s??""}`,color:"inherit","aria-label":`${i??""} menu button`,onClick:b,children:l??a.jsx(bf,{})}),a.jsx(Ie.Drawer,{className:`papi-menu-drawer ${s??""}`,anchor:"left",variant:"temporary",open:c,onClose:w,PaperProps:{className:"papi-menu-drawer-paper",style:{top:f.top,left:f.left}},children:j?a.jsx(bi,{className:s,id:`${i??""} main menu`,commandHandler:y,multiColumnMenu:j}):void 0})]})}function vf({id:e,label:t,isDisabled:n=!1,tooltip:r,isTooltipSuppressed:o=!1,adjustMarginToAlignToEdge:s=!1,size:i="medium",className:l,onClick:c,children:d}){return a.jsx(Ie.IconButton,{id:e,disabled:n,edge:s,size:i,"aria-label":t,title:o?void 0:r??t,className:`papi-icon-button ${l??""}`,onClick:c,children:d})}const Yt=v.forwardRef(({className:e,...t},n)=>a.jsx(te.LoaderCircle,{size:35,className:S("tw-animate-spin",e),...t,ref:n}));Yt.displayName="Spinner";function yf({id:e,isDisabled:t=!1,hasError:n=!1,isFullWidth:r=!1,helperText:o,label:s,placeholder:i,isRequired:l=!1,className:c,defaultValue:d,value:u,onChange:m,onFocus:w,onBlur:b}){return a.jsxs("div",{className:S("tw-inline-grid tw-items-center tw-gap-1.5",{"tw-w-full":r}),children:[a.jsx(Ue,{htmlFor:e,className:S({"tw-text-red-600":n,"tw-hidden":!s}),children:`${s}${l?"*":""}`}),a.jsx(qt,{id:e,disabled:t,placeholder:i,required:l,className:S(c,{"tw-border-red-600":n}),defaultValue:d,value:u,onChange:m,onFocus:w,onBlur:b}),a.jsx("p",{className:S({"tw-hidden":!o}),children:o})]})}function xf({menuProvider:e,commandHandler:t,className:n,id:r,children:o}){const s=v.useRef(void 0);return a.jsx("div",{ref:s,style:{position:"relative"},children:a.jsx(Ie.AppBar,{position:"static",id:r,children:a.jsxs(Ie.Toolbar,{className:S("tw-bg-muted tw-text-muted-foreground",n),variant:"dense",children:[e?a.jsx(vi,{commandHandler:t,containerRef:s,menuProvider:e}):void 0,o?a.jsx("div",{className:"papi-toolbar-children",children:o}):void 0]})})})}const Nf=Qn.cva("tw-relative tw-w-full tw-rounded-lg tw-border tw-p-4 [&>svg~*]:tw-pl-7 [&>svg+div]:tw-translate-y-[-3px] [&>svg]:tw-absolute [&>svg]:tw-left-4 [&>svg]:tw-top-4 [&>svg]:tw-text-foreground",{variants:{variant:{default:"tw-bg-background tw-text-foreground",destructive:"tw-border-destructive/50 tw-text-destructive dark:tw-border-destructive [&>svg]:tw-text-destructive"}},defaultVariants:{variant:"default"}}),yi=v.forwardRef(({className:e,variant:t,...n},r)=>a.jsx("div",{ref:r,role:"alert",className:S(Nf({variant:t}),e),...n}));yi.displayName="Alert";const xi=v.forwardRef(({className:e,...t},n)=>a.jsxs("h5",{ref:n,className:S("tw-mb-1 tw-font-medium tw-leading-none tw-tracking-tight",e),...t,children:[t.children," "]}));xi.displayName="AlertTitle";const Ni=v.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,className:S("tw-text-sm [&_p]:tw-leading-relaxed",e),...t}));Ni.displayName="AlertDescription";const ki=v.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,className:S("pr-twp tw-rounded-lg tw-border tw-bg-card tw-text-card-foreground tw-shadow-sm",e),...t}));ki.displayName="Card";const Ei=v.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,className:S("pr-twp tw-flex tw-flex-col tw-space-y-1.5 tw-p-6",e),...t}));Ei.displayName="CardHeader";const Si=v.forwardRef(({className:e,...t},n)=>a.jsx("h3",{ref:n,className:S("pr-twp tw-text-2xl tw-font-semibold tw-leading-none tw-tracking-tight",e),...t,children:t.children}));Si.displayName="CardTitle";const Ti=v.forwardRef(({className:e,...t},n)=>a.jsx("p",{ref:n,className:S("pr-twp tw-text-sm tw-text-muted-foreground",e),...t}));Ti.displayName="CardDescription";const Ci=v.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,className:S("pr-twp tw-p-6 tw-pt-0",e),...t}));Ci.displayName="CardContent";const ji=v.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,className:S("pr-twp tw-flex tw-items-center tw-p-6 tw-pt-0",e),...t}));ji.displayName="CardFooter";function kf({...e}){return a.jsx(Us.Toaster,{className:"tw-toaster tw-group",toastOptions:{classNames:{toast:"group toast group-[.toaster]:bg-background group-[.toaster]:text-foreground group-[.toaster]:border-border group-[.toaster]:shadow-lg",description:"group-[.toast]:text-muted-foreground",actionButton:"group-[.toast]:bg-primary group-[.toast]:text-primary-foreground",cancelButton:"group-[.toast]:bg-muted group-[.toast]:text-muted-foreground"}},...e})}const Oi=v.forwardRef(({className:e,...t},n)=>a.jsxs(an.Root,{ref:n,className:S("pr-twp tw-relative tw-flex tw-w-full tw-touch-none tw-select-none tw-items-center",e),...t,children:[a.jsx(an.Track,{className:"tw-relative tw-h-2 tw-w-full tw-grow tw-overflow-hidden tw-rounded-full tw-bg-secondary",children:a.jsx(an.Range,{className:"tw-absolute tw-h-full tw-bg-primary"})}),a.jsx(an.Thumb,{className:"tw-block tw-h-5 tw-w-5 tw-rounded-full tw-border-2 tw-border-primary tw-bg-background tw-ring-offset-background tw-transition-colors focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50"})]}));Oi.displayName=an.Root.displayName;const Ri=v.forwardRef(({className:e,...t},n)=>a.jsx(Vr.Root,{className:S("tw-peer pr-twp tw-inline-flex tw-h-6 tw-w-11 tw-shrink-0 tw-cursor-pointer tw-items-center tw-rounded-full tw-border-2 tw-border-transparent tw-transition-colors focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 focus-visible:tw-ring-offset-background disabled:tw-cursor-not-allowed disabled:tw-opacity-50 data-[state=checked]:tw-bg-primary data-[state=unchecked]:tw-bg-input",e),...t,ref:n,children:a.jsx(Vr.Thumb,{className:S("pr-twp tw-pointer-events-none tw-block tw-h-5 tw-w-5 tw-rounded-full tw-bg-background tw-shadow-lg tw-ring-0 tw-transition-transform data-[state=checked]:tw-translate-x-5 data-[state=unchecked]:tw-translate-x-0")})}));Ri.displayName=Vr.Root.displayName;const Ef=Oe.Root,Pi=v.forwardRef(({className:e,...t},n)=>a.jsx(Oe.List,{ref:n,className:S("tw-inline-flex tw-h-10 tw-items-center tw-justify-center tw-rounded-md tw-bg-muted tw-p-1 tw-text-muted-foreground",e),...t}));Pi.displayName=Oe.List.displayName;const _i=v.forwardRef(({className:e,...t},n)=>a.jsx(Oe.Trigger,{ref:n,className:S("tw-inline-flex tw-items-center tw-justify-center tw-whitespace-nowrap tw-rounded-sm tw-px-3 tw-py-1.5 tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-all hover:tw-text-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50 data-[state=active]:tw-bg-background data-[state=active]:tw-text-foreground data-[state=active]:tw-shadow-sm",e),...t}));_i.displayName=Oe.Trigger.displayName;const Ii=v.forwardRef(({className:e,...t},n)=>a.jsx(Oe.Content,{ref:n,className:S("tw-mt-2 tw-ring-offset-background focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2",e),...t}));Ii.displayName=Oe.Content.displayName;function Sf({isInstalling:e,handleClick:t,buttonText:n,className:r,...o}){return a.jsx(he,{className:S("tw-h-8 tw-rounded-md tw-text-white tw-transition tw-duration-300 tw-ease-in-out hover:tw-bg-blue-700",{"tw-cursor-not-allowed tw-bg-blue-700":e,"tw-bg-blue-600":!e,"tw-bg-white tw-text-blue-600 hover:tw-text-white":!n,"tw-w-20":n},r),onClick:t,...o,children:e?a.jsx(Yt,{size:15}):a.jsxs(a.Fragment,{children:[a.jsx(te.Download,{size:25,className:S("tw-h-4 tw-w-4",{"tw-mr-1":n})}),n]})})}function Tf({isEnabling:e,handleClick:t,className:n,...r}){return a.jsx(he,{className:S("tw-h-8 tw-rounded-md tw-bg-blue-600 tw-px-4 tw-text-white tw-transition tw-duration-300 tw-ease-in-out hover:tw-bg-blue-700",{"tw-cursor-not-allowed tw-bg-blue-700":e},n),onClick:t,...r,children:e?a.jsxs(a.Fragment,{children:[a.jsx(Yt,{size:15,className:"tw-mr-1 tw-text-white"}),"Enabling..."]}):"Enable"})}function Cf({isDisabling:e,handleClick:t,className:n,...r}){return a.jsx(he,{className:S("tw-h-8 tw-rounded-md tw-bg-gray-300 tw-text-black tw-transition tw-duration-300 tw-ease-in-out hover:tw-bg-gray-400",{"tw-cursor-not-allowed tw-bg-gray-400":e},n),onClick:t,...r,children:e?a.jsxs(a.Fragment,{children:[a.jsx(Yt,{size:15,className:"tw-mr-1 tw-text-black"}),"Disabling..."]}):"Disable"})}function jf({isUpdating:e,handleClick:t,className:n,...r}){return a.jsx(he,{className:S("tw-h-8 tw-rounded-md tw-bg-blue-600 tw-px-4 tw-text-white tw-transition tw-duration-300 tw-ease-in-out hover:tw-bg-blue-700 hover:tw-text-white",{"tw-cursor-not-allowed tw-bg-blue-700":e},n),onClick:t,...r,children:e?a.jsxs(a.Fragment,{children:[a.jsx(Yt,{size:15,className:"tw-mr-1 tw-text-white"}),"Updating..."]}):"Update"})}function Of({id:e,markdown:t,className:n,anchorTarget:r}){const o=v.useMemo(()=>({overrides:{a:{props:{target:r}}}}),[r]);return a.jsx("div",{id:e,className:S("pr-twp tw-prose",n),children:a.jsx(cl,{options:o,children:t})})}const $i=v.forwardRef((e,t)=>a.jsxs(he,{ref:t,className:"tw-rounded-md tw-border tw-border-dashed tw-border-gray-400 tw-bg-white tw-px-4 tw-py-2 tw-text-black tw-transition tw-duration-300 tw-ease-in-out hover:tw-border-blue-600 hover:tw-bg-white hover:tw-text-blue-600",...e,children:[a.jsx(te.Filter,{size:16,className:"tw-mr-2 tw-h-4 tw-w-4 tw-text-gray-700 hover:tw-text-blue-600"}),"Filter",a.jsx(te.ChevronDown,{size:16,className:"tw-ml-2 tw-h-4 tw-w-4 tw-text-gray-700 hover:tw-text-blue-600"})]}));var Mi=(e=>(e[e.Check=0]="Check",e[e.Radio=1]="Radio",e))(Mi||{});function Rf({id:e,groups:t}){return a.jsx("div",{id:e,children:a.jsxs(tr,{children:[a.jsx(eo,{asChild:!0,children:a.jsx($i,{})}),a.jsx(Nn,{children:t.map(n=>a.jsxs("div",{children:[a.jsx(Xt,{children:n.label}),a.jsx(ea,{children:n.items.map(r=>a.jsx("div",{children:r.itemType===0?a.jsx(nr,{onClick:r.onClick,children:r.label}):a.jsx(no,{onClick:r.onClick,value:r.label,children:r.label})},r.label))}),a.jsx(kn,{})]},n.label))})]})})}function Pf({id:e,message:t}){return a.jsx("div",{id:e,className:"tw-mb-20 tw-mt-20 tw-flex tw-items-center tw-justify-center",children:a.jsx("div",{className:"tw-w-3/4 tw-rounded-lg tw-bg-gray-100 tw-p-8 tw-text-center",children:a.jsx("p",{className:"tw-text-lg tw-text-gray-800",children:t})})})}function _f({id:e,category:t,downloads:n,languages:r,moreInfoUrl:o}){const s=new W.NumberFormat("en",{notation:"compact",compactDisplay:"short"}).format(Object.values(n).reduce((l,c)=>l+c,0)),i=()=>{window.scrollTo(0,document.body.scrollHeight)};return a.jsxs("div",{id:e,className:"tw-flex tw-flex-wrap tw-items-start tw-space-x-4 tw-border-b tw-border-t tw-bg-white tw-pb-4 tw-pt-4",children:[a.jsxs("div",{className:"tw-flex tw-flex-col tw-items-center",children:[a.jsx("div",{className:"tw-flex tw-items-center tw-rounded-md tw-bg-gray-100 tw-px-2 tw-py-1",children:a.jsx("span",{className:"tw-text-xs tw-font-semibold tw-text-gray-700",children:t})}),a.jsx("span",{className:"tw-text-xs tw-text-gray-500",children:"CATEGORY"})]}),a.jsx("div",{className:"tw-mx-2 tw-h-10 tw-border-l tw-border-gray-300"}),a.jsxs("div",{className:"tw-flex tw-flex-col tw-items-center",children:[a.jsxs("div",{className:"tw-flex tw-items-center tw-rounded-md tw-bg-gray-100 tw-px-2 tw-py-1",children:[a.jsx(te.User,{className:"tw-mr-1 tw-h-4 tw-w-4"}),a.jsx("span",{className:"tw-text-xs tw-font-semibold tw-text-gray-700",children:s})]}),a.jsx("span",{className:"tw-text-xs tw-text-gray-500",children:"USERS"})]}),a.jsx("div",{className:"tw-mx-2 tw-h-10 tw-border-l tw-border-gray-300"}),a.jsxs("div",{className:"tw-flex tw-flex-col tw-items-center",children:[a.jsx("div",{className:"tw-flex tw-items-center",children:r.slice(0,3).map(l=>a.jsx("span",{className:"tw-ml-1 tw-rounded-md tw-bg-gray-100 tw-px-2 tw-py-1 tw-text-xs tw-font-semibold tw-text-gray-700",children:l.toUpperCase()},l))}),r.length>3&&a.jsxs("button",{type:"button",onClick:()=>i(),className:"tw-text-xs tw-text-gray-500 tw-underline",children:["+",r.length-3," more languages"]})]}),a.jsx("div",{className:"tw-mx-2 tw-h-10 tw-border-l tw-border-gray-300"}),a.jsxs("div",{className:"tw-ml-auto tw-flex tw-flex-col tw-space-y-2",children:[a.jsxs("a",{href:o,target:"_blank",rel:"noreferrer",className:"tw-flex tw-items-center tw-text-xs tw-font-semibold tw-text-gray-500 tw-underline",children:["Website",a.jsx(te.Link,{className:"tw-ml-1 tw-inline tw-h-4 tw-w-4"})]}),a.jsxs("a",{href:"https://example.com",target:"_blank",rel:"noreferrer",className:"tw-flex tw-items-center tw-text-xs tw-font-semibold tw-text-gray-500 tw-underline",children:["Support",a.jsx(te.CircleHelp,{className:"tw-ml-1 tw-inline tw-h-4 tw-w-4"})]})]})]})}function Di({id:e,versionHistory:t}){const[n,r]=v.useState(!1),o=new Date;function s(l){const c=new Date(l),d=new Date(o.getTime()-c.getTime()),u=d.getUTCFullYear()-1970,m=d.getUTCMonth(),w=d.getUTCDate()-1;let b="";return u>0?b=`${u.toString()} year${u===1?"":"s"} ago`:m>0?b=`${m.toString()} month${m===1?"":"s"} ago`:w===0?b="today":b=`${w.toString()} day${w===1?"":"s"} ago`,b}const i=Object.entries(t).sort((l,c)=>c[0].localeCompare(l[0]));return a.jsxs("div",{id:e,children:[a.jsx("h3",{className:"tw-text-md tw-font-semibold",children:"What`s New"}),a.jsx("ul",{className:"tw-list-disc tw-pl-5 tw-pr-4 tw-text-xs tw-text-gray-600",children:(n?i:i.slice(0,5)).map(l=>a.jsxs("div",{className:"tw-mt-3 tw-flex tw-justify-between",children:[a.jsx("div",{className:"tw-text-gray-600",children:a.jsx("li",{className:"tw-prose tw-text-xs",children:a.jsx("span",{children:l[1].description})})}),a.jsxs("div",{className:"tw-justify-end tw-text-right",children:[a.jsxs("div",{children:["Version ",l[0]]}),a.jsx("div",{children:s(l[1].date)})]})]},l[0]))}),i.length>5&&a.jsx("button",{type:"button",onClick:()=>r(!n),className:"tw-text-xs tw-text-gray-500 tw-underline",children:n?"Show Less Version History":"Show All Version History"})]})}function If({id:e,publisherDisplayName:t,fileSize:n,locales:r,versionHistory:o}){const s=v.useMemo(()=>W.formatBytes(n),[n]),l=(c=>{const d=new Intl.DisplayNames(navigator.language,{type:"language"});return c.map(u=>d.of(u))})(r);return a.jsx("div",{id:e,className:"tw-border-t tw-pb-4 tw-pt-4",children:a.jsxs("div",{className:"tw-md:flex-row tw-md:space-x-8 tw-flex tw-flex-col tw-space-x-0",children:[a.jsx(Di,{versionHistory:o}),a.jsx("div",{className:"tw-md:border-t-0 tw-md:border-l tw-md-h-auto tw-md-ml-8 tw-mt-4 tw-border-t tw-border-gray-300"}),a.jsxs("div",{className:"tw-md:mt-0 tw-mt-4 tw-flex-1 tw-space-y-3",children:[a.jsx("h2",{className:"tw-text-md tw-font-semibold",children:"Information"}),a.jsxs("div",{className:"tw-flex tw-items-start tw-justify-between tw-pr-4 tw-text-xs tw-text-gray-600",children:[a.jsxs("p",{className:"tw-flex tw-flex-col tw-justify-start",children:[a.jsx("span",{className:"tw-mb-2",children:"Publisher"}),a.jsx("span",{className:"tw-font-semibold",children:t}),a.jsx("span",{className:"tw-mb-2 tw-mt-4",children:"Size"}),a.jsx("span",{className:"tw-font-semibold",children:s})]}),a.jsx("div",{className:"tw-flex tw-w-3/4 tw-items-center tw-justify-between tw-text-xs tw-text-gray-600",children:a.jsxs("p",{className:"tw-flex tw-flex-col tw-justify-start",children:[a.jsx("span",{className:"tw-mb-2",children:"Languages"}),a.jsx("span",{className:"tw-font-semibold",children:l.join(", ")})]})})]})]})]})})}const $f=(e,t)=>{v.useEffect(()=>{if(!e)return()=>{};const n=e(t);return()=>{n()}},[e,t])},Dr=()=>!1,Mf=(e,t)=>{const[n]=Zn(v.useCallback(async()=>{if(!e)return Dr;const r=await Promise.resolve(e(t));return async()=>r()},[t,e]),Dr,{preserveValue:!1});v.useEffect(()=>()=>{n!==Dr&&n()},[n])};Object.defineProperty(exports,"sonner",{enumerable:!0,get:()=>Us.toast});exports.Alert=yi;exports.AlertDescription=Ni;exports.AlertTitle=xi;exports.BOOK_SELECTOR_STRING_KEYS=Wl;exports.BookChapterControl=Bl;exports.BookSelectionMode=wa;exports.BookSelector=Kl;exports.Button=he;exports.Card=ki;exports.CardContent=Ci;exports.CardDescription=Ti;exports.CardFooter=ji;exports.CardHeader=Ei;exports.CardTitle=Si;exports.ChapterRangeSelector=pa;exports.Checkbox=rr;exports.Checklist=Nc;exports.ComboBox=Lr;exports.DataTable=va;exports.DisableButton=Cf;exports.DropdownMenu=tr;exports.DropdownMenuCheckboxItem=nr;exports.DropdownMenuContent=Nn;exports.DropdownMenuGroup=ea;exports.DropdownMenuItem=to;exports.DropdownMenuItemType=Mi;exports.DropdownMenuLabel=Xt;exports.DropdownMenuPortal=Sl;exports.DropdownMenuRadioGroup=Cl;exports.DropdownMenuRadioItem=no;exports.DropdownMenuSeparator=kn;exports.DropdownMenuShortcut=ra;exports.DropdownMenuSub=Tl;exports.DropdownMenuSubContent=na;exports.DropdownMenuSubTrigger=ta;exports.DropdownMenuTrigger=eo;exports.EnableButton=Tf;exports.FilterButton=$i;exports.FilterDropdown=Rf;exports.Footer=If;exports.GridMenu=bi;exports.HamburgerMenuButton=vi;exports.INVENTORY_STRING_KEYS=sc;exports.IconButton=vf;exports.Input=qt;exports.InstallButton=Sf;exports.Inventory=lc;exports.Label=Ue;exports.MarkdownRenderer=Of;exports.MenuItem=$o;exports.MoreInfo=_f;exports.NavigationContentSearch=cc;exports.NoExtensionsFound=Pf;exports.RadioGroup=ro;exports.RadioGroupItem=qn;exports.ScriptureResultsViewer=gc;exports.ScrollGroupSelector=bc;exports.SearchBar=Sa;exports.Select=Dt;exports.SelectContent=vt;exports.SelectGroup=fa;exports.SelectItem=De;exports.SelectLabel=ma;exports.SelectScrollDownButton=so;exports.SelectScrollUpButton=oo;exports.SelectSeparator=ha;exports.SelectTrigger=bt;exports.SelectValue=At;exports.Separator=uo;exports.SettingsList=vc;exports.SettingsListHeader=xc;exports.SettingsListItem=yc;exports.Slider=Oi;exports.Sonner=kf;exports.Spinner=Yt;exports.Switch=Ri;exports.Table=En;exports.TableBody=Tn;exports.TableCaption=ba;exports.TableCell=yt;exports.TableFooter=ga;exports.TableHead=Bt;exports.TableHeader=Sn;exports.TableRow=Ze;exports.Tabs=Ef;exports.TabsContent=Ii;exports.TabsList=Pi;exports.TabsTrigger=_i;exports.TextField=yf;exports.ToggleGroup=ao;exports.ToggleGroupItem=pn;exports.Toolbar=xf;exports.UpdateButton=jf;exports.VersionHistory=Di;exports.VerticalTabs=io;exports.VerticalTabsContent=co;exports.VerticalTabsList=lo;exports.VerticalTabsTrigger=Ta;exports.buttonVariants=oa;exports.cn=S;exports.getBookNumFromId=xa;exports.getLinesFromUSFM=ya;exports.getNumberFromUSFM=Fr;exports.getStatusForItem=Na;exports.inventoryCountColumn=rc;exports.inventoryItemColumn=tc;exports.inventoryStatusColumn=oc;exports.useEvent=$f;exports.useEventAsync=Mf;exports.usePromise=Zn;function Df(e,t="top"){if(!e||typeof document>"u")return;const n=document.head||document.querySelector("head"),r=n.querySelector(":first-child"),o=document.createElement("style");o.appendChild(document.createTextNode(e)),t==="top"&&r?n.insertBefore(o,r):n.appendChild(o)}Df(`*, ::before, ::after { +} });`:zt(12,h?` (${h})`:"",JSON.stringify(f.main)));return _a(f,"light",R,r),_a(f,"dark",j,r),f.contrastText||(f.contrastText=m(f.main)),f},b={dark:Vr,light:Oa};return process.env.NODE_ENV!=="production"&&(b[t]||console.error(`MUI: The palette mode \`${t}\` is not supported.`)),Qe(O({common:O({},yn),mode:t,primary:w({color:s,name:"primary"}),secondary:w({color:i,name:"secondary",mainShade:"A400",lightShade:"A200",darkShade:"A700"}),error:w({color:l,name:"error"}),warning:w({color:u,name:"warning"}),info:w({color:c,name:"info"}),success:w({color:d,name:"success"}),grey:jp,contrastThreshold:n,getContrastText:m,augmentColor:w,tonalOffset:r},b[t]),o)}const Lp=["fontFamily","fontSize","fontWeightLight","fontWeightRegular","fontWeightMedium","fontWeightBold","htmlFontSize","allVariants","pxToRem"];function Fp(e){return Math.round(e*1e5)/1e5}const Pa={textTransform:"uppercase"},Ia='"Roboto", "Helvetica", "Arial", sans-serif';function Gp(e,t){const n=typeof t=="function"?t(e):t,{fontFamily:r=Ia,fontSize:o=14,fontWeightLight:s=300,fontWeightRegular:i=400,fontWeightMedium:l=500,fontWeightBold:c=700,htmlFontSize:d=16,allVariants:u,pxToRem:m}=n,w=Ne(n,Lp);process.env.NODE_ENV!=="production"&&(typeof o!="number"&&console.error("MUI: `fontSize` is required to be a number."),typeof d!="number"&&console.error("MUI: `htmlFontSize` is required to be a number."));const b=o/14,x=m||(S=>`${S/d*b}rem`),f=(S,R,j,E,v)=>O({fontFamily:r,fontWeight:S,fontSize:x(R),lineHeight:j},r===Ia?{letterSpacing:`${Fp(E/R)}em`}:{},v,u),h={h1:f(s,96,1.167,-1.5),h2:f(s,60,1.2,-.5),h3:f(i,48,1.167,0),h4:f(i,34,1.235,.25),h5:f(i,24,1.334,0),h6:f(l,20,1.6,.15),subtitle1:f(i,16,1.75,.15),subtitle2:f(l,14,1.57,.1),body1:f(i,16,1.5,.15),body2:f(i,14,1.43,.15),button:f(l,14,1.75,.4,Pa),caption:f(i,12,1.66,.4),overline:f(i,12,2.66,1,Pa),inherit:{fontFamily:"inherit",fontWeight:"inherit",fontSize:"inherit",lineHeight:"inherit",letterSpacing:"inherit"}};return Qe(O({htmlFontSize:d,pxToRem:x,fontFamily:r,fontSize:o,fontWeightLight:s,fontWeightRegular:i,fontWeightMedium:l,fontWeightBold:c},h),w,{clone:!1})}const Up=.2,qp=.14,Hp=.12;function we(...e){return[`${e[0]}px ${e[1]}px ${e[2]}px ${e[3]}px rgba(0,0,0,${Up})`,`${e[4]}px ${e[5]}px ${e[6]}px ${e[7]}px rgba(0,0,0,${qp})`,`${e[8]}px ${e[9]}px ${e[10]}px ${e[11]}px rgba(0,0,0,${Hp})`].join(",")}const Xp=["none",we(0,2,1,-1,0,1,1,0,0,1,3,0),we(0,3,1,-2,0,2,2,0,0,1,5,0),we(0,3,3,-2,0,3,4,0,0,1,8,0),we(0,2,4,-1,0,4,5,0,0,1,10,0),we(0,3,5,-1,0,5,8,0,0,1,14,0),we(0,3,5,-1,0,6,10,0,0,1,18,0),we(0,4,5,-2,0,7,10,1,0,2,16,1),we(0,5,5,-3,0,8,10,1,0,3,14,2),we(0,5,6,-3,0,9,12,1,0,3,16,2),we(0,6,6,-3,0,10,14,1,0,4,18,3),we(0,6,7,-4,0,11,15,1,0,4,20,3),we(0,7,8,-4,0,12,17,2,0,5,22,4),we(0,7,8,-4,0,13,19,2,0,5,24,4),we(0,7,9,-4,0,14,21,2,0,5,26,4),we(0,8,9,-5,0,15,22,2,0,6,28,5),we(0,8,10,-5,0,16,24,2,0,6,30,5),we(0,8,11,-5,0,17,26,2,0,6,32,5),we(0,9,11,-5,0,18,28,2,0,7,34,6),we(0,9,12,-6,0,19,29,2,0,7,36,6),we(0,10,13,-6,0,20,31,3,0,8,38,7),we(0,10,13,-6,0,21,33,3,0,8,40,7),we(0,10,14,-6,0,22,35,3,0,8,42,7),we(0,11,14,-7,0,23,36,3,0,9,44,8),we(0,11,15,-7,0,24,38,3,0,9,46,8)],Yp=Xp,Wp=["duration","easing","delay"],Kp={easeInOut:"cubic-bezier(0.4, 0, 0.2, 1)",easeOut:"cubic-bezier(0.0, 0, 0.2, 1)",easeIn:"cubic-bezier(0.4, 0, 1, 1)",sharp:"cubic-bezier(0.4, 0, 0.6, 1)"},Jp={shortest:150,shorter:200,short:250,standard:300,complex:375,enteringScreen:225,leavingScreen:195};function Ma(e){return`${Math.round(e)}ms`}function Zp(e){if(!e)return 0;const t=e/36;return Math.round((4+15*t**.25+t/5)*10)}function Qp(e){const t=O({},Kp,e.easing),n=O({},Jp,e.duration);return O({getAutoHeightDuration:Zp,create:(o=["all"],s={})=>{const{duration:i=n.standard,easing:l=t.easeInOut,delay:c=0}=s,d=Ne(s,Wp);if(process.env.NODE_ENV!=="production"){const u=w=>typeof w=="string",m=w=>!isNaN(parseFloat(w));!u(o)&&!Array.isArray(o)&&console.error('MUI: Argument "props" must be a string or Array.'),!m(i)&&!u(i)&&console.error(`MUI: Argument "duration" must be a number or a string but found ${i}.`),u(l)||console.error('MUI: Argument "easing" must be a string.'),!m(c)&&!u(c)&&console.error('MUI: Argument "delay" must be a number or a string.'),typeof s!="object"&&console.error(["MUI: Secong argument of transition.create must be an object.","Arguments should be either `create('prop1', options)` or `create(['prop1', 'prop2'], options)`"].join(` +`)),Object.keys(d).length!==0&&console.error(`MUI: Unrecognized argument(s) [${Object.keys(d).join(",")}].`)}return(Array.isArray(o)?o:[o]).map(u=>`${u} ${typeof i=="string"?i:Ma(i)} ${l} ${typeof c=="string"?c:Ma(c)}`).join(",")}},e,{easing:t,duration:n})}const ew={mobileStepper:1e3,fab:1050,speedDial:1050,appBar:1100,drawer:1200,modal:1300,snackbar:1400,tooltip:1500},tw=ew,nw=["breakpoints","mixins","spacing","palette","transitions","typography","shape"];function rw(e={},...t){const{mixins:n={},palette:r={},transitions:o={},typography:s={}}=e,i=Ne(e,nw);if(e.vars)throw new Error(process.env.NODE_ENV!=="production"?"MUI: `vars` is a private field used for CSS variables support.\nPlease use another name.":zt(18));const l=zp(r),c=Co(e);let d=Qe(c,{mixins:kp(c.breakpoints,n),palette:l,shadows:Yp.slice(),typography:Gp(l,s),transitions:Qp(o),zIndex:O({},tw)});if(d=Qe(d,i),d=t.reduce((u,m)=>Qe(u,m),d),process.env.NODE_ENV!=="production"){const u=["active","checked","completed","disabled","error","expanded","focused","focusVisible","required","selected"],m=(w,b)=>{let x;for(x in w){const f=w[x];if(u.indexOf(x)!==-1&&Object.keys(f).length>0){if(process.env.NODE_ENV!=="production"){const h=dr("",x);console.error([`MUI: The \`${b}\` component increases the CSS specificity of the \`${x}\` internal state.`,"You can not override it like this: ",JSON.stringify(w,null,2),"",`Instead, you need to use the '&.${h}' syntax:`,JSON.stringify({root:{[`&.${h}`]:f}},null,2),"","https://mui.com/r/state-classes-guide"].join(` +`))}w[x]={}}}};Object.keys(d.components).forEach(w=>{const b=d.components[w].styleOverrides;b&&w.indexOf("Mui")===0&&m(b,w)})}return d.unstable_sxConfig=O({},jo,i==null?void 0:i.unstable_sxConfig),d.unstable_sx=function(m){return To({sx:m,theme:this})},d}const ow=rw(),Oo=ow,_o="$$material";function Po({props:e,name:t}){return bp({props:e,name:t,defaultTheme:Oo,themeId:_o})}const aw=e=>qn(e)&&e!=="classes",sw=hp({themeId:_o,defaultTheme:Oo,rootShouldForwardProp:aw}),In=sw;function iw(e){return dr("MuiSvgIcon",e)}mi("MuiSvgIcon",["root","colorPrimary","colorSecondary","colorAction","colorError","colorDisabled","fontSizeInherit","fontSizeSmall","fontSizeMedium","fontSizeLarge"]);const lw=["children","className","color","component","fontSize","htmlColor","inheritViewBox","titleAccess","viewBox"],cw=e=>{const{color:t,fontSize:n,classes:r}=e,o={root:["root",t!=="inherit"&&`color${Ye(t)}`,`fontSize${Ye(n)}`]};return ko(o,iw,r)},dw=In("svg",{name:"MuiSvgIcon",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.root,n.color!=="inherit"&&t[`color${Ye(n.color)}`],t[`fontSize${Ye(n.fontSize)}`]]}})(({theme:e,ownerState:t})=>{var n,r,o,s,i,l,c,d,u,m,w,b,x;return{userSelect:"none",width:"1em",height:"1em",display:"inline-block",fill:t.hasSvgAsChild?void 0:"currentColor",flexShrink:0,transition:(n=e.transitions)==null||(r=n.create)==null?void 0:r.call(n,"fill",{duration:(o=e.transitions)==null||(o=o.duration)==null?void 0:o.shorter}),fontSize:{inherit:"inherit",small:((s=e.typography)==null||(i=s.pxToRem)==null?void 0:i.call(s,20))||"1.25rem",medium:((l=e.typography)==null||(c=l.pxToRem)==null?void 0:c.call(l,24))||"1.5rem",large:((d=e.typography)==null||(u=d.pxToRem)==null?void 0:u.call(d,35))||"2.1875rem"}[t.fontSize],color:(m=(w=(e.vars||e).palette)==null||(w=w[t.color])==null?void 0:w.main)!=null?m:{action:(b=(e.vars||e).palette)==null||(b=b.action)==null?void 0:b.active,disabled:(x=(e.vars||e).palette)==null||(x=x.action)==null?void 0:x.disabled,inherit:void 0}[t.color]}}),Io=M.forwardRef(function(t,n){const r=Po({props:t,name:"MuiSvgIcon"}),{children:o,className:s,color:i="inherit",component:l="svg",fontSize:c="medium",htmlColor:d,inheritViewBox:u=!1,titleAccess:m,viewBox:w="0 0 24 24"}=r,b=Ne(r,lw),x=M.isValidElement(o)&&o.type==="svg",f=O({},r,{color:i,component:l,fontSize:c,instanceFontSize:t.fontSize,inheritViewBox:u,viewBox:w,hasSvgAsChild:x}),h={};u||(h.viewBox=w);const S=cw(f);return a.jsxs(dw,O({as:l,className:ot(S.root,s),focusable:"false",color:d,"aria-hidden":m?void 0:!0,role:m?"img":void 0,ref:n},h,b,x&&o.props,{ownerState:f,children:[x?o.props.children:o,m?a.jsx("title",{children:m}):null]}))});process.env.NODE_ENV!=="production"&&(Io.propTypes={children:p.node,classes:p.object,className:p.string,color:p.oneOfType([p.oneOf(["inherit","action","disabled","primary","secondary","error","info","success","warning"]),p.string]),component:p.elementType,fontSize:p.oneOfType([p.oneOf(["inherit","large","medium","small"]),p.string]),htmlColor:p.string,inheritViewBox:p.bool,shapeRendering:p.string,sx:p.oneOfType([p.arrayOf(p.oneOfType([p.func,p.object,p.bool])),p.func,p.object]),titleAccess:p.string,viewBox:p.string});Io.muiName="SvgIcon";const $a=Io;function Ni(e,t){function n(r,o){return a.jsx($a,O({"data-testid":`${t}Icon`,ref:o},r,{children:e}))}return process.env.NODE_ENV!=="production"&&(n.displayName=`${t}Icon`),n.muiName=$a.muiName,M.memo(M.forwardRef(n))}const uw={configure:e=>{process.env.NODE_ENV!=="production"&&console.warn(["MUI: `ClassNameGenerator` import from `@mui/material/utils` is outdated and might cause unexpected issues.","","You should use `import { unstable_ClassNameGenerator } from '@mui/material/className'` instead","","The detail of the issue: https://github.com/mui/material-ui/issues/30011#issuecomment-1024993401","","The updated documentation: https://mui.com/guides/classname-generator/"].join(` +`)),wi.configure(e)}},pw=Object.freeze(Object.defineProperty({__proto__:null,capitalize:Ye,createChainedFunction:Ld,createSvgIcon:Ni,debounce:Fd,deprecatedPropType:Gd,isMuiElement:Ud,ownerDocument:Wn,ownerWindow:qd,requirePropFactory:Hd,setRef:Kn,unstable_ClassNameGenerator:uw,unstable_useEnhancedEffect:Lt,unstable_useId:ci,unsupportedProp:Wd,useControlled:di,useEventCallback:Wr,useForkRef:yt,useIsFocusVisible:ui},Symbol.toStringTag,{value:"Module"})),ww=yd(pw);var Da;function fw(){return Da||(Da=1,function(e){"use client";Object.defineProperty(e,"__esModule",{value:!0}),Object.defineProperty(e,"default",{enumerable:!0,get:function(){return t.createSvgIcon}});var t=ww}(_r)),_r}var mw=Nd;Object.defineProperty(xo,"__esModule",{value:!0});var ki=xo.default=void 0,hw=mw(fw()),gw=a;ki=xo.default=(0,hw.default)((0,gw.jsx)("path",{d:"m10 17 5-5-5-5z"}),"ArrowRight");function bw(e){return typeof e=="string"}function un(e,t,n){return e===void 0||bw(e)?t:O({},t,{ownerState:O({},t.ownerState,n)})}const vw={disableDefaultClasses:!1},xw=M.createContext(vw);function yw(e){const{disableDefaultClasses:t}=M.useContext(xw);return n=>t?"":e(n)}function Nw(e,t=[]){if(e===void 0)return{};const n={};return Object.keys(e).filter(r=>r.match(/^on[A-Z]/)&&typeof e[r]=="function"&&!t.includes(r)).forEach(r=>{n[r]=e[r]}),n}function kw(e,t,n){return typeof e=="function"?e(t,n):e}function Aa(e){if(e===void 0)return{};const t={};return Object.keys(e).filter(n=>!(n.match(/^on[A-Z]/)&&typeof e[n]=="function")).forEach(n=>{t[n]=e[n]}),t}function Sw(e){const{getSlotProps:t,additionalProps:n,externalSlotProps:r,externalForwardedProps:o,className:s}=e;if(!t){const b=ot(n==null?void 0:n.className,s,o==null?void 0:o.className,r==null?void 0:r.className),x=O({},n==null?void 0:n.style,o==null?void 0:o.style,r==null?void 0:r.style),f=O({},n,o,r);return b.length>0&&(f.className=b),Object.keys(x).length>0&&(f.style=x),{props:f,internalRef:void 0}}const i=Nw(O({},o,r)),l=Aa(r),c=Aa(o),d=t(i),u=ot(d==null?void 0:d.className,n==null?void 0:n.className,s,o==null?void 0:o.className,r==null?void 0:r.className),m=O({},d==null?void 0:d.style,n==null?void 0:n.style,o==null?void 0:o.style,r==null?void 0:r.style),w=O({},d,n,c,l);return u.length>0&&(w.className=u),Object.keys(m).length>0&&(w.style=m),{props:w,internalRef:d.ref}}const Ew=["elementType","externalSlotProps","ownerState","skipResolvingSlotProps"];function jw(e){var t;const{elementType:n,externalSlotProps:r,ownerState:o,skipResolvingSlotProps:s=!1}=e,i=Ne(e,Ew),l=s?{}:kw(r,o),{props:c,internalRef:d}=Sw(O({},i,{externalSlotProps:l})),u=yt(d,l==null?void 0:l.ref,(t=e.additionalProps)==null?void 0:t.ref);return un(n,O({},c,{ref:u}),o)}const Si="base";function Tw(e){return`${Si}--${e}`}function Cw(e,t){return`${Si}-${e}-${t}`}function Ei(e,t){const n=fi[t];return n?Tw(n):Cw(e,t)}function Rw(e,t){const n={};return t.forEach(r=>{n[r]=Ei(e,r)}),n}function Ow(e){return typeof e=="function"?e():e}const Zn=M.forwardRef(function(t,n){const{children:r,container:o,disablePortal:s=!1}=t,[i,l]=M.useState(null),c=yt(M.isValidElement(r)?r.ref:null,n);if(Lt(()=>{s||l(Ow(o)||document.body)},[o,s]),Lt(()=>{if(i&&!s)return Kn(n,i),()=>{Kn(n,null)}},[n,i,s]),s){if(M.isValidElement(r)){const d={ref:c};return M.cloneElement(r,d)}return a.jsx(M.Fragment,{children:r})}return a.jsx(M.Fragment,{children:i&&Ol.createPortal(r,i)})});process.env.NODE_ENV!=="production"&&(Zn.propTypes={children:p.node,container:p.oneOfType([xn,p.func]),disablePortal:p.bool});process.env.NODE_ENV!=="production"&&(Zn["propTypes"]=Md(Zn.propTypes));var Ce="top",ze="bottom",Le="right",Re="left",Mo="auto",Mn=[Ce,ze,Le,Re],Ft="start",Nn="end",_w="clippingParents",ji="viewport",an="popper",Pw="reference",Ba=Mn.reduce(function(e,t){return e.concat([t+"-"+Ft,t+"-"+Nn])},[]),Ti=[].concat(Mn,[Mo]).reduce(function(e,t){return e.concat([t,t+"-"+Ft,t+"-"+Nn])},[]),Iw="beforeRead",Mw="read",$w="afterRead",Dw="beforeMain",Aw="main",Bw="afterMain",Vw="beforeWrite",zw="write",Lw="afterWrite",Fw=[Iw,Mw,$w,Dw,Aw,Bw,Vw,zw,Lw];function We(e){return e?(e.nodeName||"").toLowerCase():null}function $e(e){if(e==null)return window;if(e.toString()!=="[object Window]"){var t=e.ownerDocument;return t&&t.defaultView||window}return e}function kt(e){var t=$e(e).Element;return e instanceof t||e instanceof Element}function Ve(e){var t=$e(e).HTMLElement;return e instanceof t||e instanceof HTMLElement}function $o(e){if(typeof ShadowRoot>"u")return!1;var t=$e(e).ShadowRoot;return e instanceof t||e instanceof ShadowRoot}function Gw(e){var t=e.state;Object.keys(t.elements).forEach(function(n){var r=t.styles[n]||{},o=t.attributes[n]||{},s=t.elements[n];!Ve(s)||!We(s)||(Object.assign(s.style,r),Object.keys(o).forEach(function(i){var l=o[i];l===!1?s.removeAttribute(i):s.setAttribute(i,l===!0?"":l)}))})}function Uw(e){var t=e.state,n={popper:{position:t.options.strategy,left:"0",top:"0",margin:"0"},arrow:{position:"absolute"},reference:{}};return Object.assign(t.elements.popper.style,n.popper),t.styles=n,t.elements.arrow&&Object.assign(t.elements.arrow.style,n.arrow),function(){Object.keys(t.elements).forEach(function(r){var o=t.elements[r],s=t.attributes[r]||{},i=Object.keys(t.styles.hasOwnProperty(r)?t.styles[r]:n[r]),l=i.reduce(function(c,d){return c[d]="",c},{});!Ve(o)||!We(o)||(Object.assign(o.style,l),Object.keys(s).forEach(function(c){o.removeAttribute(c)}))})}}const qw={name:"applyStyles",enabled:!0,phase:"write",fn:Gw,effect:Uw,requires:["computeStyles"]};function Xe(e){return e.split("-")[0]}var ht=Math.max,Qn=Math.min,Gt=Math.round;function Jr(){var e=navigator.userAgentData;return e!=null&&e.brands&&Array.isArray(e.brands)?e.brands.map(function(t){return t.brand+"/"+t.version}).join(" "):navigator.userAgent}function Ci(){return!/^((?!chrome|android).)*safari/i.test(Jr())}function Ut(e,t,n){t===void 0&&(t=!1),n===void 0&&(n=!1);var r=e.getBoundingClientRect(),o=1,s=1;t&&Ve(e)&&(o=e.offsetWidth>0&&Gt(r.width)/e.offsetWidth||1,s=e.offsetHeight>0&&Gt(r.height)/e.offsetHeight||1);var i=kt(e)?$e(e):window,l=i.visualViewport,c=!Ci()&&n,d=(r.left+(c&&l?l.offsetLeft:0))/o,u=(r.top+(c&&l?l.offsetTop:0))/s,m=r.width/o,w=r.height/s;return{width:m,height:w,top:u,right:d+m,bottom:u+w,left:d,x:d,y:u}}function Do(e){var t=Ut(e),n=e.offsetWidth,r=e.offsetHeight;return Math.abs(t.width-n)<=1&&(n=t.width),Math.abs(t.height-r)<=1&&(r=t.height),{x:e.offsetLeft,y:e.offsetTop,width:n,height:r}}function Ri(e,t){var n=t.getRootNode&&t.getRootNode();if(e.contains(t))return!0;if(n&&$o(n)){var r=t;do{if(r&&e.isSameNode(r))return!0;r=r.parentNode||r.host}while(r)}return!1}function tt(e){return $e(e).getComputedStyle(e)}function Hw(e){return["table","td","th"].indexOf(We(e))>=0}function it(e){return((kt(e)?e.ownerDocument:e.document)||window.document).documentElement}function xr(e){return We(e)==="html"?e:e.assignedSlot||e.parentNode||($o(e)?e.host:null)||it(e)}function Va(e){return!Ve(e)||tt(e).position==="fixed"?null:e.offsetParent}function Xw(e){var t=/firefox/i.test(Jr()),n=/Trident/i.test(Jr());if(n&&Ve(e)){var r=tt(e);if(r.position==="fixed")return null}var o=xr(e);for($o(o)&&(o=o.host);Ve(o)&&["html","body"].indexOf(We(o))<0;){var s=tt(o);if(s.transform!=="none"||s.perspective!=="none"||s.contain==="paint"||["transform","perspective"].indexOf(s.willChange)!==-1||t&&s.willChange==="filter"||t&&s.filter&&s.filter!=="none")return o;o=o.parentNode}return null}function $n(e){for(var t=$e(e),n=Va(e);n&&Hw(n)&&tt(n).position==="static";)n=Va(n);return n&&(We(n)==="html"||We(n)==="body"&&tt(n).position==="static")?t:n||Xw(e)||t}function Ao(e){return["top","bottom"].indexOf(e)>=0?"x":"y"}function hn(e,t,n){return ht(e,Qn(t,n))}function Yw(e,t,n){var r=hn(e,t,n);return r>n?n:r}function Oi(){return{top:0,right:0,bottom:0,left:0}}function _i(e){return Object.assign({},Oi(),e)}function Pi(e,t){return t.reduce(function(n,r){return n[r]=e,n},{})}var Ww=function(t,n){return t=typeof t=="function"?t(Object.assign({},n.rects,{placement:n.placement})):t,_i(typeof t!="number"?t:Pi(t,Mn))};function Kw(e){var t,n=e.state,r=e.name,o=e.options,s=n.elements.arrow,i=n.modifiersData.popperOffsets,l=Xe(n.placement),c=Ao(l),d=[Re,Le].indexOf(l)>=0,u=d?"height":"width";if(!(!s||!i)){var m=Ww(o.padding,n),w=Do(s),b=c==="y"?Ce:Re,x=c==="y"?ze:Le,f=n.rects.reference[u]+n.rects.reference[c]-i[c]-n.rects.popper[u],h=i[c]-n.rects.reference[c],S=$n(s),R=S?c==="y"?S.clientHeight||0:S.clientWidth||0:0,j=f/2-h/2,E=m[b],v=R-w[u]-m[x],P=R/2-w[u]/2+j,V=hn(E,P,v),U=c;n.modifiersData[r]=(t={},t[U]=V,t.centerOffset=V-P,t)}}function Jw(e){var t=e.state,n=e.options,r=n.element,o=r===void 0?"[data-popper-arrow]":r;o!=null&&(typeof o=="string"&&(o=t.elements.popper.querySelector(o),!o)||Ri(t.elements.popper,o)&&(t.elements.arrow=o))}const Zw={name:"arrow",enabled:!0,phase:"main",fn:Kw,effect:Jw,requires:["popperOffsets"],requiresIfExists:["preventOverflow"]};function qt(e){return e.split("-")[1]}var Qw={top:"auto",right:"auto",bottom:"auto",left:"auto"};function ef(e,t){var n=e.x,r=e.y,o=t.devicePixelRatio||1;return{x:Gt(n*o)/o||0,y:Gt(r*o)/o||0}}function za(e){var t,n=e.popper,r=e.popperRect,o=e.placement,s=e.variation,i=e.offsets,l=e.position,c=e.gpuAcceleration,d=e.adaptive,u=e.roundOffsets,m=e.isFixed,w=i.x,b=w===void 0?0:w,x=i.y,f=x===void 0?0:x,h=typeof u=="function"?u({x:b,y:f}):{x:b,y:f};b=h.x,f=h.y;var S=i.hasOwnProperty("x"),R=i.hasOwnProperty("y"),j=Re,E=Ce,v=window;if(d){var P=$n(n),V="clientHeight",U="clientWidth";if(P===$e(n)&&(P=it(n),tt(P).position!=="static"&&l==="absolute"&&(V="scrollHeight",U="scrollWidth")),P=P,o===Ce||(o===Re||o===Le)&&s===Nn){E=ze;var T=m&&P===v&&v.visualViewport?v.visualViewport.height:P[V];f-=T-r.height,f*=c?1:-1}if(o===Re||(o===Ce||o===ze)&&s===Nn){j=Le;var _=m&&P===v&&v.visualViewport?v.visualViewport.width:P[U];b-=_-r.width,b*=c?1:-1}}var k=Object.assign({position:l},d&&Qw),D=u===!0?ef({x:b,y:f},$e(n)):{x:b,y:f};if(b=D.x,f=D.y,c){var $;return Object.assign({},k,($={},$[E]=R?"0":"",$[j]=S?"0":"",$.transform=(v.devicePixelRatio||1)<=1?"translate("+b+"px, "+f+"px)":"translate3d("+b+"px, "+f+"px, 0)",$))}return Object.assign({},k,(t={},t[E]=R?f+"px":"",t[j]=S?b+"px":"",t.transform="",t))}function tf(e){var t=e.state,n=e.options,r=n.gpuAcceleration,o=r===void 0?!0:r,s=n.adaptive,i=s===void 0?!0:s,l=n.roundOffsets,c=l===void 0?!0:l,d={placement:Xe(t.placement),variation:qt(t.placement),popper:t.elements.popper,popperRect:t.rects.popper,gpuAcceleration:o,isFixed:t.options.strategy==="fixed"};t.modifiersData.popperOffsets!=null&&(t.styles.popper=Object.assign({},t.styles.popper,za(Object.assign({},d,{offsets:t.modifiersData.popperOffsets,position:t.options.strategy,adaptive:i,roundOffsets:c})))),t.modifiersData.arrow!=null&&(t.styles.arrow=Object.assign({},t.styles.arrow,za(Object.assign({},d,{offsets:t.modifiersData.arrow,position:"absolute",adaptive:!1,roundOffsets:c})))),t.attributes.popper=Object.assign({},t.attributes.popper,{"data-popper-placement":t.placement})}const nf={name:"computeStyles",enabled:!0,phase:"beforeWrite",fn:tf,data:{}};var Fn={passive:!0};function rf(e){var t=e.state,n=e.instance,r=e.options,o=r.scroll,s=o===void 0?!0:o,i=r.resize,l=i===void 0?!0:i,c=$e(t.elements.popper),d=[].concat(t.scrollParents.reference,t.scrollParents.popper);return s&&d.forEach(function(u){u.addEventListener("scroll",n.update,Fn)}),l&&c.addEventListener("resize",n.update,Fn),function(){s&&d.forEach(function(u){u.removeEventListener("scroll",n.update,Fn)}),l&&c.removeEventListener("resize",n.update,Fn)}}const of={name:"eventListeners",enabled:!0,phase:"write",fn:function(){},effect:rf,data:{}};var af={left:"right",right:"left",bottom:"top",top:"bottom"};function Xn(e){return e.replace(/left|right|bottom|top/g,function(t){return af[t]})}var sf={start:"end",end:"start"};function La(e){return e.replace(/start|end/g,function(t){return sf[t]})}function Bo(e){var t=$e(e),n=t.pageXOffset,r=t.pageYOffset;return{scrollLeft:n,scrollTop:r}}function Vo(e){return Ut(it(e)).left+Bo(e).scrollLeft}function lf(e,t){var n=$e(e),r=it(e),o=n.visualViewport,s=r.clientWidth,i=r.clientHeight,l=0,c=0;if(o){s=o.width,i=o.height;var d=Ci();(d||!d&&t==="fixed")&&(l=o.offsetLeft,c=o.offsetTop)}return{width:s,height:i,x:l+Vo(e),y:c}}function cf(e){var t,n=it(e),r=Bo(e),o=(t=e.ownerDocument)==null?void 0:t.body,s=ht(n.scrollWidth,n.clientWidth,o?o.scrollWidth:0,o?o.clientWidth:0),i=ht(n.scrollHeight,n.clientHeight,o?o.scrollHeight:0,o?o.clientHeight:0),l=-r.scrollLeft+Vo(e),c=-r.scrollTop;return tt(o||n).direction==="rtl"&&(l+=ht(n.clientWidth,o?o.clientWidth:0)-s),{width:s,height:i,x:l,y:c}}function zo(e){var t=tt(e),n=t.overflow,r=t.overflowX,o=t.overflowY;return/auto|scroll|overlay|hidden/.test(n+o+r)}function Ii(e){return["html","body","#document"].indexOf(We(e))>=0?e.ownerDocument.body:Ve(e)&&zo(e)?e:Ii(xr(e))}function gn(e,t){var n;t===void 0&&(t=[]);var r=Ii(e),o=r===((n=e.ownerDocument)==null?void 0:n.body),s=$e(r),i=o?[s].concat(s.visualViewport||[],zo(r)?r:[]):r,l=t.concat(i);return o?l:l.concat(gn(xr(i)))}function Zr(e){return Object.assign({},e,{left:e.x,top:e.y,right:e.x+e.width,bottom:e.y+e.height})}function df(e,t){var n=Ut(e,!1,t==="fixed");return n.top=n.top+e.clientTop,n.left=n.left+e.clientLeft,n.bottom=n.top+e.clientHeight,n.right=n.left+e.clientWidth,n.width=e.clientWidth,n.height=e.clientHeight,n.x=n.left,n.y=n.top,n}function Fa(e,t,n){return t===ji?Zr(lf(e,n)):kt(t)?df(t,n):Zr(cf(it(e)))}function uf(e){var t=gn(xr(e)),n=["absolute","fixed"].indexOf(tt(e).position)>=0,r=n&&Ve(e)?$n(e):e;return kt(r)?t.filter(function(o){return kt(o)&&Ri(o,r)&&We(o)!=="body"}):[]}function pf(e,t,n,r){var o=t==="clippingParents"?uf(e):[].concat(t),s=[].concat(o,[n]),i=s[0],l=s.reduce(function(c,d){var u=Fa(e,d,r);return c.top=ht(u.top,c.top),c.right=Qn(u.right,c.right),c.bottom=Qn(u.bottom,c.bottom),c.left=ht(u.left,c.left),c},Fa(e,i,r));return l.width=l.right-l.left,l.height=l.bottom-l.top,l.x=l.left,l.y=l.top,l}function Mi(e){var t=e.reference,n=e.element,r=e.placement,o=r?Xe(r):null,s=r?qt(r):null,i=t.x+t.width/2-n.width/2,l=t.y+t.height/2-n.height/2,c;switch(o){case Ce:c={x:i,y:t.y-n.height};break;case ze:c={x:i,y:t.y+t.height};break;case Le:c={x:t.x+t.width,y:l};break;case Re:c={x:t.x-n.width,y:l};break;default:c={x:t.x,y:t.y}}var d=o?Ao(o):null;if(d!=null){var u=d==="y"?"height":"width";switch(s){case Ft:c[d]=c[d]-(t[u]/2-n[u]/2);break;case Nn:c[d]=c[d]+(t[u]/2-n[u]/2);break}}return c}function kn(e,t){t===void 0&&(t={});var n=t,r=n.placement,o=r===void 0?e.placement:r,s=n.strategy,i=s===void 0?e.strategy:s,l=n.boundary,c=l===void 0?_w:l,d=n.rootBoundary,u=d===void 0?ji:d,m=n.elementContext,w=m===void 0?an:m,b=n.altBoundary,x=b===void 0?!1:b,f=n.padding,h=f===void 0?0:f,S=_i(typeof h!="number"?h:Pi(h,Mn)),R=w===an?Pw:an,j=e.rects.popper,E=e.elements[x?R:w],v=pf(kt(E)?E:E.contextElement||it(e.elements.popper),c,u,i),P=Ut(e.elements.reference),V=Mi({reference:P,element:j,strategy:"absolute",placement:o}),U=Zr(Object.assign({},j,V)),T=w===an?U:P,_={top:v.top-T.top+S.top,bottom:T.bottom-v.bottom+S.bottom,left:v.left-T.left+S.left,right:T.right-v.right+S.right},k=e.modifiersData.offset;if(w===an&&k){var D=k[o];Object.keys(_).forEach(function($){var J=[Le,ze].indexOf($)>=0?1:-1,Y=[Ce,ze].indexOf($)>=0?"y":"x";_[$]+=D[Y]*J})}return _}function wf(e,t){t===void 0&&(t={});var n=t,r=n.placement,o=n.boundary,s=n.rootBoundary,i=n.padding,l=n.flipVariations,c=n.allowedAutoPlacements,d=c===void 0?Ti:c,u=qt(r),m=u?l?Ba:Ba.filter(function(x){return qt(x)===u}):Mn,w=m.filter(function(x){return d.indexOf(x)>=0});w.length===0&&(w=m);var b=w.reduce(function(x,f){return x[f]=kn(e,{placement:f,boundary:o,rootBoundary:s,padding:i})[Xe(f)],x},{});return Object.keys(b).sort(function(x,f){return b[x]-b[f]})}function ff(e){if(Xe(e)===Mo)return[];var t=Xn(e);return[La(e),t,La(t)]}function mf(e){var t=e.state,n=e.options,r=e.name;if(!t.modifiersData[r]._skip){for(var o=n.mainAxis,s=o===void 0?!0:o,i=n.altAxis,l=i===void 0?!0:i,c=n.fallbackPlacements,d=n.padding,u=n.boundary,m=n.rootBoundary,w=n.altBoundary,b=n.flipVariations,x=b===void 0?!0:b,f=n.allowedAutoPlacements,h=t.options.placement,S=Xe(h),R=S===h,j=c||(R||!x?[Xn(h)]:ff(h)),E=[h].concat(j).reduce(function(B,X){return B.concat(Xe(X)===Mo?wf(t,{placement:X,boundary:u,rootBoundary:m,padding:d,flipVariations:x,allowedAutoPlacements:f}):X)},[]),v=t.rects.reference,P=t.rects.popper,V=new Map,U=!0,T=E[0],_=0;_=0,Y=J?"width":"height",F=kn(t,{placement:k,boundary:u,rootBoundary:m,altBoundary:w,padding:d}),te=J?$?Le:Re:$?ze:Ce;v[Y]>P[Y]&&(te=Xn(te));var se=Xn(te),oe=[];if(s&&oe.push(F[D]<=0),l&&oe.push(F[te]<=0,F[se]<=0),oe.every(function(B){return B})){T=k,U=!1;break}V.set(k,oe)}if(U)for(var y=x?3:1,C=function(X){var q=E.find(function(H){var G=V.get(H);if(G)return G.slice(0,X).every(function(K){return K})});if(q)return T=q,"break"},z=y;z>0;z--){var L=C(z);if(L==="break")break}t.placement!==T&&(t.modifiersData[r]._skip=!0,t.placement=T,t.reset=!0)}}const hf={name:"flip",enabled:!0,phase:"main",fn:mf,requiresIfExists:["offset"],data:{_skip:!1}};function Ga(e,t,n){return n===void 0&&(n={x:0,y:0}),{top:e.top-t.height-n.y,right:e.right-t.width+n.x,bottom:e.bottom-t.height+n.y,left:e.left-t.width-n.x}}function Ua(e){return[Ce,Le,ze,Re].some(function(t){return e[t]>=0})}function gf(e){var t=e.state,n=e.name,r=t.rects.reference,o=t.rects.popper,s=t.modifiersData.preventOverflow,i=kn(t,{elementContext:"reference"}),l=kn(t,{altBoundary:!0}),c=Ga(i,r),d=Ga(l,o,s),u=Ua(c),m=Ua(d);t.modifiersData[n]={referenceClippingOffsets:c,popperEscapeOffsets:d,isReferenceHidden:u,hasPopperEscaped:m},t.attributes.popper=Object.assign({},t.attributes.popper,{"data-popper-reference-hidden":u,"data-popper-escaped":m})}const bf={name:"hide",enabled:!0,phase:"main",requiresIfExists:["preventOverflow"],fn:gf};function vf(e,t,n){var r=Xe(e),o=[Re,Ce].indexOf(r)>=0?-1:1,s=typeof n=="function"?n(Object.assign({},t,{placement:e})):n,i=s[0],l=s[1];return i=i||0,l=(l||0)*o,[Re,Le].indexOf(r)>=0?{x:l,y:i}:{x:i,y:l}}function xf(e){var t=e.state,n=e.options,r=e.name,o=n.offset,s=o===void 0?[0,0]:o,i=Ti.reduce(function(u,m){return u[m]=vf(m,t.rects,s),u},{}),l=i[t.placement],c=l.x,d=l.y;t.modifiersData.popperOffsets!=null&&(t.modifiersData.popperOffsets.x+=c,t.modifiersData.popperOffsets.y+=d),t.modifiersData[r]=i}const yf={name:"offset",enabled:!0,phase:"main",requires:["popperOffsets"],fn:xf};function Nf(e){var t=e.state,n=e.name;t.modifiersData[n]=Mi({reference:t.rects.reference,element:t.rects.popper,strategy:"absolute",placement:t.placement})}const kf={name:"popperOffsets",enabled:!0,phase:"read",fn:Nf,data:{}};function Sf(e){return e==="x"?"y":"x"}function Ef(e){var t=e.state,n=e.options,r=e.name,o=n.mainAxis,s=o===void 0?!0:o,i=n.altAxis,l=i===void 0?!1:i,c=n.boundary,d=n.rootBoundary,u=n.altBoundary,m=n.padding,w=n.tether,b=w===void 0?!0:w,x=n.tetherOffset,f=x===void 0?0:x,h=kn(t,{boundary:c,rootBoundary:d,padding:m,altBoundary:u}),S=Xe(t.placement),R=qt(t.placement),j=!R,E=Ao(S),v=Sf(E),P=t.modifiersData.popperOffsets,V=t.rects.reference,U=t.rects.popper,T=typeof f=="function"?f(Object.assign({},t.rects,{placement:t.placement})):f,_=typeof T=="number"?{mainAxis:T,altAxis:T}:Object.assign({mainAxis:0,altAxis:0},T),k=t.modifiersData.offset?t.modifiersData.offset[t.placement]:null,D={x:0,y:0};if(P){if(s){var $,J=E==="y"?Ce:Re,Y=E==="y"?ze:Le,F=E==="y"?"height":"width",te=P[E],se=te+h[J],oe=te-h[Y],y=b?-U[F]/2:0,C=R===Ft?V[F]:U[F],z=R===Ft?-U[F]:-V[F],L=t.elements.arrow,B=b&&L?Do(L):{width:0,height:0},X=t.modifiersData["arrow#persistent"]?t.modifiersData["arrow#persistent"].padding:Oi(),q=X[J],H=X[Y],G=hn(0,V[F],B[F]),K=j?V[F]/2-y-G-q-_.mainAxis:C-G-q-_.mainAxis,Z=j?-V[F]/2+y+G+H+_.mainAxis:z+G+H+_.mainAxis,ue=t.elements.arrow&&$n(t.elements.arrow),I=ue?E==="y"?ue.clientTop||0:ue.clientLeft||0:0,ye=($=k==null?void 0:k[E])!=null?$:0,A=te+K-ye-I,xe=te+Z-ye,Ge=hn(b?Qn(se,A):se,te,b?ht(oe,xe):oe);P[E]=Ge,D[E]=Ge-te}if(l){var lt,Ee=E==="x"?Ce:Re,Dn=E==="x"?ze:Le,Ue=P[v],Et=v==="y"?"height":"width",ct=Ue+h[Ee],jt=Ue-h[Dn],Tt=[Ce,Re].indexOf(S)!==-1,Ct=(lt=k==null?void 0:k[v])!=null?lt:0,dt=Tt?ct:Ue-V[Et]-U[Et]-Ct+_.altAxis,Jt=Tt?Ue+V[Et]+U[Et]-Ct-_.altAxis:jt,An=b&&Tt?Yw(dt,Ue,Jt):hn(b?dt:ct,Ue,b?Jt:jt);P[v]=An,D[v]=An-Ue}t.modifiersData[r]=D}}const jf={name:"preventOverflow",enabled:!0,phase:"main",fn:Ef,requiresIfExists:["offset"]};function Tf(e){return{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}}function Cf(e){return e===$e(e)||!Ve(e)?Bo(e):Tf(e)}function Rf(e){var t=e.getBoundingClientRect(),n=Gt(t.width)/e.offsetWidth||1,r=Gt(t.height)/e.offsetHeight||1;return n!==1||r!==1}function Of(e,t,n){n===void 0&&(n=!1);var r=Ve(t),o=Ve(t)&&Rf(t),s=it(t),i=Ut(e,o,n),l={scrollLeft:0,scrollTop:0},c={x:0,y:0};return(r||!r&&!n)&&((We(t)!=="body"||zo(s))&&(l=Cf(t)),Ve(t)?(c=Ut(t,!0),c.x+=t.clientLeft,c.y+=t.clientTop):s&&(c.x=Vo(s))),{x:i.left+l.scrollLeft-c.x,y:i.top+l.scrollTop-c.y,width:i.width,height:i.height}}function _f(e){var t=new Map,n=new Set,r=[];e.forEach(function(s){t.set(s.name,s)});function o(s){n.add(s.name);var i=[].concat(s.requires||[],s.requiresIfExists||[]);i.forEach(function(l){if(!n.has(l)){var c=t.get(l);c&&o(c)}}),r.push(s)}return e.forEach(function(s){n.has(s.name)||o(s)}),r}function Pf(e){var t=_f(e);return Fw.reduce(function(n,r){return n.concat(t.filter(function(o){return o.phase===r}))},[])}function If(e){var t;return function(){return t||(t=new Promise(function(n){Promise.resolve().then(function(){t=void 0,n(e())})})),t}}function Mf(e){var t=e.reduce(function(n,r){var o=n[r.name];return n[r.name]=o?Object.assign({},o,r,{options:Object.assign({},o.options,r.options),data:Object.assign({},o.data,r.data)}):r,n},{});return Object.keys(t).map(function(n){return t[n]})}var qa={placement:"bottom",modifiers:[],strategy:"absolute"};function Ha(){for(var e=arguments.length,t=new Array(e),n=0;nko({root:["root"]},yw(Bf)),Uf={},qf=M.forwardRef(function(t,n){var r;const{anchorEl:o,children:s,direction:i,disablePortal:l,modifiers:c,open:d,placement:u,popperOptions:m,popperRef:w,slotProps:b={},slots:x={},TransitionProps:f}=t,h=Ne(t,Vf),S=M.useRef(null),R=yt(S,n),j=M.useRef(null),E=yt(j,w),v=M.useRef(E);Lt(()=>{v.current=E},[E]),M.useImperativeHandle(w,()=>j.current,[]);const P=Lf(u,i),[V,U]=M.useState(P),[T,_]=M.useState(er(o));M.useEffect(()=>{j.current&&j.current.forceUpdate()}),M.useEffect(()=>{o&&_(er(o))},[o]),Lt(()=>{if(!T||!d)return;const Y=se=>{U(se.placement)};if(process.env.NODE_ENV!=="production"&&T&&yr(T)&&T.nodeType===1){const se=T.getBoundingClientRect();process.env.NODE_ENV!=="test"&&se.top===0&&se.left===0&&se.right===0&&se.bottom===0&&console.warn(["MUI: The `anchorEl` prop provided to the component is invalid.","The anchor element should be part of the document layout.","Make sure the element is present in the document or that it's not display none."].join(` +`))}let F=[{name:"preventOverflow",options:{altBoundary:l}},{name:"flip",options:{altBoundary:l}},{name:"onUpdate",enabled:!0,phase:"afterWrite",fn:({state:se})=>{Y(se)}}];c!=null&&(F=F.concat(c)),m&&m.modifiers!=null&&(F=F.concat(m.modifiers));const te=Af(T,S.current,O({placement:P},m,{modifiers:F}));return v.current(te),()=>{te.destroy(),v.current(null)}},[T,l,c,d,m,P]);const k={placement:V};f!==null&&(k.TransitionProps=f);const D=Gf(),$=(r=x.root)!=null?r:"div",J=jw({elementType:$,externalSlotProps:b.root,externalForwardedProps:h,additionalProps:{role:"tooltip",ref:R},ownerState:t,className:D.root});return a.jsx($,O({},J,{children:typeof s=="function"?s(k):s}))}),Di=M.forwardRef(function(t,n){const{anchorEl:r,children:o,container:s,direction:i="ltr",disablePortal:l=!1,keepMounted:c=!1,modifiers:d,open:u,placement:m="bottom",popperOptions:w=Uf,popperRef:b,style:x,transition:f=!1,slotProps:h={},slots:S={}}=t,R=Ne(t,zf),[j,E]=M.useState(!0),v=()=>{E(!1)},P=()=>{E(!0)};if(!c&&!u&&(!f||j))return null;let V;if(s)V=s;else if(r){const _=er(r);V=_&&yr(_)?Wn(_).body:Wn(null).body}const U=!u&&c&&(!f||j)?"none":void 0,T=f?{in:u,onEnter:v,onExited:P}:void 0;return a.jsx(Zn,{disablePortal:l,container:V,children:a.jsx(qf,O({anchorEl:r,direction:i,disablePortal:l,modifiers:d,ref:n,open:f?!j:u,placement:m,popperOptions:w,popperRef:b,slotProps:h,slots:S},R,{style:O({position:"fixed",top:0,left:0,display:U},x),TransitionProps:T,children:o}))})});process.env.NODE_ENV!=="production"&&(Di.propTypes={anchorEl:yo(p.oneOfType([xn,p.object,p.func]),e=>{if(e.open){const t=er(e.anchorEl);if(t&&yr(t)&&t.nodeType===1){const n=t.getBoundingClientRect();if(process.env.NODE_ENV!=="test"&&n.top===0&&n.left===0&&n.right===0&&n.bottom===0)return new Error(["MUI: The `anchorEl` prop provided to the component is invalid.","The anchor element should be part of the document layout.","Make sure the element is present in the document or that it's not display none."].join(` +`))}else if(!t||typeof t.getBoundingClientRect!="function"||Ff(t)&&t.contextElement!=null&&t.contextElement.nodeType!==1)return new Error(["MUI: The `anchorEl` prop provided to the component is invalid.","It should be an HTML element instance or a virtualElement ","(https://popper.js.org/docs/v2/virtual-elements/)."].join(` +`))}return null}),children:p.oneOfType([p.node,p.func]),container:p.oneOfType([xn,p.func]),direction:p.oneOf(["ltr","rtl"]),disablePortal:p.bool,keepMounted:p.bool,modifiers:p.arrayOf(p.shape({data:p.object,effect:p.func,enabled:p.bool,fn:p.func,name:p.any,options:p.object,phase:p.oneOf(["afterMain","afterRead","afterWrite","beforeMain","beforeRead","beforeWrite","main","read","write"]),requires:p.arrayOf(p.string),requiresIfExists:p.arrayOf(p.string)})),open:p.bool.isRequired,placement:p.oneOf(["auto-end","auto-start","auto","bottom-end","bottom-start","bottom","left-end","left-start","left","right-end","right-start","right","top-end","top-start","top"]),popperOptions:p.shape({modifiers:p.array,onFirstUpdate:p.func,placement:p.oneOf(["auto-end","auto-start","auto","bottom-end","bottom-start","bottom","left-end","left-start","left","right-end","right-start","right","top-end","top-start","top"]),strategy:p.oneOf(["absolute","fixed"])}),popperRef:li,slotProps:p.shape({root:p.oneOfType([p.func,p.object])}),slots:p.shape({root:p.elementType}),transition:p.bool});function Ai(){const e=xi(Oo);return process.env.NODE_ENV!=="production"&&M.useDebugValue(e),e[_o]||e}function Qr(e,t){return Qr=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,o){return r.__proto__=o,r},Qr(e,t)}function Hf(e,t){e.prototype=Object.create(t.prototype),e.prototype.constructor=e,Qr(e,t)}const Xa={disabled:!1};var Xf=process.env.NODE_ENV!=="production"?p.oneOfType([p.number,p.shape({enter:p.number,exit:p.number,appear:p.number}).isRequired]):null;process.env.NODE_ENV!=="production"&&p.oneOfType([p.string,p.shape({enter:p.string,exit:p.string,active:p.string}),p.shape({enter:p.string,enterDone:p.string,enterActive:p.string,exit:p.string,exitDone:p.string,exitActive:p.string})]);const Bi=g.createContext(null);var Yf=function(t){return t.scrollTop},pn="unmounted",wt="exited",ft="entering",$t="entered",eo="exiting",nt=function(e){Hf(t,e);function t(r,o){var s;s=e.call(this,r,o)||this;var i=o,l=i&&!i.isMounting?r.enter:r.appear,c;return s.appearStatus=null,r.in?l?(c=wt,s.appearStatus=ft):c=$t:r.unmountOnExit||r.mountOnEnter?c=pn:c=wt,s.state={status:c},s.nextCallback=null,s}t.getDerivedStateFromProps=function(o,s){var i=o.in;return i&&s.status===pn?{status:wt}:null};var n=t.prototype;return n.componentDidMount=function(){this.updateStatus(!0,this.appearStatus)},n.componentDidUpdate=function(o){var s=null;if(o!==this.props){var i=this.state.status;this.props.in?i!==ft&&i!==$t&&(s=ft):(i===ft||i===$t)&&(s=eo)}this.updateStatus(!1,s)},n.componentWillUnmount=function(){this.cancelNextCallback()},n.getTimeouts=function(){var o=this.props.timeout,s,i,l;return s=i=l=o,o!=null&&typeof o!="number"&&(s=o.exit,i=o.enter,l=o.appear!==void 0?o.appear:i),{exit:s,enter:i,appear:l}},n.updateStatus=function(o,s){if(o===void 0&&(o=!1),s!==null)if(this.cancelNextCallback(),s===ft){if(this.props.unmountOnExit||this.props.mountOnEnter){var i=this.props.nodeRef?this.props.nodeRef.current:ln.findDOMNode(this);i&&Yf(i)}this.performEnter(o)}else this.performExit();else this.props.unmountOnExit&&this.state.status===wt&&this.setState({status:pn})},n.performEnter=function(o){var s=this,i=this.props.enter,l=this.context?this.context.isMounting:o,c=this.props.nodeRef?[l]:[ln.findDOMNode(this),l],d=c[0],u=c[1],m=this.getTimeouts(),w=l?m.appear:m.enter;if(!o&&!i||Xa.disabled){this.safeSetState({status:$t},function(){s.props.onEntered(d)});return}this.props.onEnter(d,u),this.safeSetState({status:ft},function(){s.props.onEntering(d,u),s.onTransitionEnd(w,function(){s.safeSetState({status:$t},function(){s.props.onEntered(d,u)})})})},n.performExit=function(){var o=this,s=this.props.exit,i=this.getTimeouts(),l=this.props.nodeRef?void 0:ln.findDOMNode(this);if(!s||Xa.disabled){this.safeSetState({status:wt},function(){o.props.onExited(l)});return}this.props.onExit(l),this.safeSetState({status:eo},function(){o.props.onExiting(l),o.onTransitionEnd(i.exit,function(){o.safeSetState({status:wt},function(){o.props.onExited(l)})})})},n.cancelNextCallback=function(){this.nextCallback!==null&&(this.nextCallback.cancel(),this.nextCallback=null)},n.safeSetState=function(o,s){s=this.setNextCallback(s),this.setState(o,s)},n.setNextCallback=function(o){var s=this,i=!0;return this.nextCallback=function(l){i&&(i=!1,s.nextCallback=null,o(l))},this.nextCallback.cancel=function(){i=!1},this.nextCallback},n.onTransitionEnd=function(o,s){this.setNextCallback(s);var i=this.props.nodeRef?this.props.nodeRef.current:ln.findDOMNode(this),l=o==null&&!this.props.addEndListener;if(!i||l){setTimeout(this.nextCallback,0);return}if(this.props.addEndListener){var c=this.props.nodeRef?[this.nextCallback]:[i,this.nextCallback],d=c[0],u=c[1];this.props.addEndListener(d,u)}o!=null&&setTimeout(this.nextCallback,o)},n.render=function(){var o=this.state.status;if(o===pn)return null;var s=this.props,i=s.children;s.in,s.mountOnEnter,s.unmountOnExit,s.appear,s.enter,s.exit,s.timeout,s.addEndListener,s.onEnter,s.onEntering,s.onEntered,s.onExit,s.onExiting,s.onExited,s.nodeRef;var l=Ne(s,["children","in","mountOnEnter","unmountOnExit","appear","enter","exit","timeout","addEndListener","onEnter","onEntering","onEntered","onExit","onExiting","onExited","nodeRef"]);return g.createElement(Bi.Provider,{value:null},typeof i=="function"?i(o,l):g.cloneElement(g.Children.only(i),l))},t}(g.Component);nt.contextType=Bi;nt.propTypes=process.env.NODE_ENV!=="production"?{nodeRef:p.shape({current:typeof Element>"u"?p.any:function(e,t,n,r,o,s){var i=e[t];return p.instanceOf(i&&"ownerDocument"in i?i.ownerDocument.defaultView.Element:Element)(e,t,n,r,o,s)}}),children:p.oneOfType([p.func.isRequired,p.element.isRequired]).isRequired,in:p.bool,mountOnEnter:p.bool,unmountOnExit:p.bool,appear:p.bool,enter:p.bool,exit:p.bool,timeout:function(t){var n=Xf;t.addEndListener||(n=n.isRequired);for(var r=arguments.length,o=new Array(r>1?r-1:0),s=1;se.scrollTop;function Ya(e,t){var n,r;const{timeout:o,easing:s,style:i={}}=e;return{duration:(n=i.transitionDuration)!=null?n:typeof o=="number"?o:o[t.mode]||0,easing:(r=i.transitionTimingFunction)!=null?r:typeof s=="object"?s[t.mode]:s,delay:i.transitionDelay}}const Jf=["addEndListener","appear","children","easing","in","onEnter","onEntered","onEntering","onExit","onExited","onExiting","style","timeout","TransitionComponent"];function to(e){return`scale(${e}, ${e**2})`}const Zf={entering:{opacity:1,transform:to(1)},entered:{opacity:1,transform:"none"}},zr=typeof navigator<"u"&&/^((?!chrome|android).)*(safari|mobile)/i.test(navigator.userAgent)&&/(os |version\/)15(.|_)4/i.test(navigator.userAgent),Lo=M.forwardRef(function(t,n){const{addEndListener:r,appear:o=!0,children:s,easing:i,in:l,onEnter:c,onEntered:d,onEntering:u,onExit:m,onExited:w,onExiting:b,style:x,timeout:f="auto",TransitionComponent:h=Wf}=t,S=Ne(t,Jf),R=dn(),j=M.useRef(),E=Ai(),v=M.useRef(null),P=yt(v,s.ref,n),V=Y=>F=>{if(Y){const te=v.current;F===void 0?Y(te):Y(te,F)}},U=V(u),T=V((Y,F)=>{Kf(Y);const{duration:te,delay:se,easing:oe}=Ya({style:x,timeout:f,easing:i},{mode:"enter"});let y;f==="auto"?(y=E.transitions.getAutoHeightDuration(Y.clientHeight),j.current=y):y=te,Y.style.transition=[E.transitions.create("opacity",{duration:y,delay:se}),E.transitions.create("transform",{duration:zr?y:y*.666,delay:se,easing:oe})].join(","),c&&c(Y,F)}),_=V(d),k=V(b),D=V(Y=>{const{duration:F,delay:te,easing:se}=Ya({style:x,timeout:f,easing:i},{mode:"exit"});let oe;f==="auto"?(oe=E.transitions.getAutoHeightDuration(Y.clientHeight),j.current=oe):oe=F,Y.style.transition=[E.transitions.create("opacity",{duration:oe,delay:te}),E.transitions.create("transform",{duration:zr?oe:oe*.666,delay:zr?te:te||oe*.333,easing:se})].join(","),Y.style.opacity=0,Y.style.transform=to(.75),m&&m(Y)}),$=V(w),J=Y=>{f==="auto"&&R.start(j.current||0,Y),r&&r(v.current,Y)};return a.jsx(h,O({appear:o,in:l,nodeRef:v,onEnter:T,onEntered:_,onEntering:U,onExit:D,onExited:$,onExiting:k,addEndListener:J,timeout:f==="auto"?null:f},S,{children:(Y,F)=>M.cloneElement(s,O({style:O({opacity:0,transform:to(.75),visibility:Y==="exited"&&!l?"hidden":void 0},Zf[Y],x,s.props.style),ref:P},F))}))});process.env.NODE_ENV!=="production"&&(Lo.propTypes={addEndListener:p.func,appear:p.bool,children:si.isRequired,easing:p.oneOfType([p.shape({enter:p.string,exit:p.string}),p.string]),in:p.bool,onEnter:p.func,onEntered:p.func,onEntering:p.func,onExit:p.func,onExited:p.func,onExiting:p.func,style:p.object,timeout:p.oneOfType([p.oneOf(["auto"]),p.number,p.shape({appear:p.number,enter:p.number,exit:p.number})])});Lo.muiSupportAuto=!0;const Wa=Lo,Qf=["anchorEl","component","components","componentsProps","container","disablePortal","keepMounted","modifiers","open","placement","popperOptions","popperRef","transition","slots","slotProps"],em=In(Di,{name:"MuiPopper",slot:"Root",overridesResolver:(e,t)=>t.root})({}),Vi=M.forwardRef(function(t,n){var r;const o=vi(),s=Po({props:t,name:"MuiPopper"}),{anchorEl:i,component:l,components:c,componentsProps:d,container:u,disablePortal:m,keepMounted:w,modifiers:b,open:x,placement:f,popperOptions:h,popperRef:S,transition:R,slots:j,slotProps:E}=s,v=Ne(s,Qf),P=(r=j==null?void 0:j.root)!=null?r:c==null?void 0:c.Root,V=O({anchorEl:i,container:u,disablePortal:m,keepMounted:w,modifiers:b,open:x,placement:f,popperOptions:h,popperRef:S,transition:R},v);return a.jsx(em,O({as:l,direction:o==null?void 0:o.direction,slots:{root:P},slotProps:E??d},V,{ref:n}))});process.env.NODE_ENV!=="production"&&(Vi.propTypes={anchorEl:p.oneOfType([xn,p.object,p.func]),children:p.oneOfType([p.node,p.func]),component:p.elementType,components:p.shape({Root:p.elementType}),componentsProps:p.shape({root:p.oneOfType([p.func,p.object])}),container:p.oneOfType([xn,p.func]),disablePortal:p.bool,keepMounted:p.bool,modifiers:p.arrayOf(p.shape({data:p.object,effect:p.func,enabled:p.bool,fn:p.func,name:p.any,options:p.object,phase:p.oneOf(["afterMain","afterRead","afterWrite","beforeMain","beforeRead","beforeWrite","main","read","write"]),requires:p.arrayOf(p.string),requiresIfExists:p.arrayOf(p.string)})),open:p.bool.isRequired,placement:p.oneOf(["auto-end","auto-start","auto","bottom-end","bottom-start","bottom","left-end","left-start","left","right-end","right-start","right","top-end","top-start","top"]),popperOptions:p.shape({modifiers:p.array,onFirstUpdate:p.func,placement:p.oneOf(["auto-end","auto-start","auto","bottom-end","bottom-start","bottom","left-end","left-start","left","right-end","right-start","right","top-end","top-start","top"]),strategy:p.oneOf(["absolute","fixed"])}),popperRef:li,slotProps:p.shape({root:p.oneOfType([p.func,p.object])}),slots:p.shape({root:p.elementType}),sx:p.oneOfType([p.arrayOf(p.oneOfType([p.func,p.object,p.bool])),p.func,p.object]),transition:p.bool});const zi=Vi;function tm(e){return dr("MuiTooltip",e)}const nm=mi("MuiTooltip",["popper","popperInteractive","popperArrow","popperClose","tooltip","tooltipArrow","touch","tooltipPlacementLeft","tooltipPlacementRight","tooltipPlacementTop","tooltipPlacementBottom","arrow"]),at=nm,rm=["arrow","children","classes","components","componentsProps","describeChild","disableFocusListener","disableHoverListener","disableInteractive","disableTouchListener","enterDelay","enterNextDelay","enterTouchDelay","followCursor","id","leaveDelay","leaveTouchDelay","onClose","onOpen","open","placement","PopperComponent","PopperProps","slotProps","slots","title","TransitionComponent","TransitionProps"];function om(e){return Math.round(e*1e5)/1e5}const am=e=>{const{classes:t,disableInteractive:n,arrow:r,touch:o,placement:s}=e,i={popper:["popper",!n&&"popperInteractive",r&&"popperArrow"],tooltip:["tooltip",r&&"tooltipArrow",o&&"touch",`tooltipPlacement${Ye(s.split("-")[0])}`],arrow:["arrow"]};return ko(i,tm,t)},sm=In(zi,{name:"MuiTooltip",slot:"Popper",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.popper,!n.disableInteractive&&t.popperInteractive,n.arrow&&t.popperArrow,!n.open&&t.popperClose]}})(({theme:e,ownerState:t,open:n})=>O({zIndex:(e.vars||e).zIndex.tooltip,pointerEvents:"none"},!t.disableInteractive&&{pointerEvents:"auto"},!n&&{pointerEvents:"none"},t.arrow&&{[`&[data-popper-placement*="bottom"] .${at.arrow}`]:{top:0,marginTop:"-0.71em","&::before":{transformOrigin:"0 100%"}},[`&[data-popper-placement*="top"] .${at.arrow}`]:{bottom:0,marginBottom:"-0.71em","&::before":{transformOrigin:"100% 0"}},[`&[data-popper-placement*="right"] .${at.arrow}`]:O({},t.isRtl?{right:0,marginRight:"-0.71em"}:{left:0,marginLeft:"-0.71em"},{height:"1em",width:"0.71em","&::before":{transformOrigin:"100% 100%"}}),[`&[data-popper-placement*="left"] .${at.arrow}`]:O({},t.isRtl?{left:0,marginLeft:"-0.71em"}:{right:0,marginRight:"-0.71em"},{height:"1em",width:"0.71em","&::before":{transformOrigin:"0 0"}})})),im=In("div",{name:"MuiTooltip",slot:"Tooltip",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.tooltip,n.touch&&t.touch,n.arrow&&t.tooltipArrow,t[`tooltipPlacement${Ye(n.placement.split("-")[0])}`]]}})(({theme:e,ownerState:t})=>O({backgroundColor:e.vars?e.vars.palette.Tooltip.bg:yi(e.palette.grey[700],.92),borderRadius:(e.vars||e).shape.borderRadius,color:(e.vars||e).palette.common.white,fontFamily:e.typography.fontFamily,padding:"4px 8px",fontSize:e.typography.pxToRem(11),maxWidth:300,margin:2,wordWrap:"break-word",fontWeight:e.typography.fontWeightMedium},t.arrow&&{position:"relative",margin:0},t.touch&&{padding:"8px 16px",fontSize:e.typography.pxToRem(14),lineHeight:`${om(16/14)}em`,fontWeight:e.typography.fontWeightRegular},{[`.${at.popper}[data-popper-placement*="left"] &`]:O({transformOrigin:"right center"},t.isRtl?O({marginLeft:"14px"},t.touch&&{marginLeft:"24px"}):O({marginRight:"14px"},t.touch&&{marginRight:"24px"})),[`.${at.popper}[data-popper-placement*="right"] &`]:O({transformOrigin:"left center"},t.isRtl?O({marginRight:"14px"},t.touch&&{marginRight:"24px"}):O({marginLeft:"14px"},t.touch&&{marginLeft:"24px"})),[`.${at.popper}[data-popper-placement*="top"] &`]:O({transformOrigin:"center bottom",marginBottom:"14px"},t.touch&&{marginBottom:"24px"}),[`.${at.popper}[data-popper-placement*="bottom"] &`]:O({transformOrigin:"center top",marginTop:"14px"},t.touch&&{marginTop:"24px"})})),lm=In("span",{name:"MuiTooltip",slot:"Arrow",overridesResolver:(e,t)=>t.arrow})(({theme:e})=>({overflow:"hidden",position:"absolute",width:"1em",height:"0.71em",boxSizing:"border-box",color:e.vars?e.vars.palette.Tooltip.bg:yi(e.palette.grey[700],.9),"&::before":{content:'""',margin:"auto",display:"block",width:"100%",height:"100%",backgroundColor:"currentColor",transform:"rotate(45deg)"}}));let Gn=!1;const Ka=new On;let sn={x:0,y:0};function Un(e,t){return n=>{t&&t(n),e(n)}}const Li=M.forwardRef(function(t,n){var r,o,s,i,l,c,d,u,m,w,b,x,f,h,S,R,j,E,v;const P=Po({props:t,name:"MuiTooltip"}),{arrow:V=!1,children:U,components:T={},componentsProps:_={},describeChild:k=!1,disableFocusListener:D=!1,disableHoverListener:$=!1,disableInteractive:J=!1,disableTouchListener:Y=!1,enterDelay:F=100,enterNextDelay:te=0,enterTouchDelay:se=700,followCursor:oe=!1,id:y,leaveDelay:C=0,leaveTouchDelay:z=1500,onClose:L,onOpen:B,open:X,placement:q="bottom",PopperComponent:H,PopperProps:G={},slotProps:K={},slots:Z={},title:ue,TransitionComponent:I=Wa,TransitionProps:ye}=P,A=Ne(P,rm),xe=M.isValidElement(U)?U:a.jsx("span",{children:U}),Ge=Ai(),lt=Ge.direction==="rtl",[Ee,Dn]=M.useState(),[Ue,Et]=M.useState(null),ct=M.useRef(!1),jt=J||oe,Tt=dn(),Ct=dn(),dt=dn(),Jt=dn(),[An,Go]=di({controlled:X,default:!1,name:"Tooltip",state:"open"});let Ke=An;if(process.env.NODE_ENV!=="production"){const{current:ee}=M.useRef(X!==void 0);M.useEffect(()=>{Ee&&Ee.disabled&&!ee&&ue!==""&&Ee.tagName.toLowerCase()==="button"&&console.error(["MUI: You are providing a disabled `button` child to the Tooltip component.","A disabled element does not fire events.","Tooltip needs to listen to the child element's events to display the title.","","Add a simple wrapper element, such as a `span`."].join(` +`))},[ue,Ee,ee])}const Nr=ci(y),Zt=M.useRef(),Bn=Wr(()=>{Zt.current!==void 0&&(document.body.style.WebkitUserSelect=Zt.current,Zt.current=void 0),Jt.clear()});M.useEffect(()=>Bn,[Bn]);const Uo=ee=>{Ka.clear(),Gn=!0,Go(!0),B&&!Ke&&B(ee)},Vn=Wr(ee=>{Ka.start(800+C,()=>{Gn=!1}),Go(!1),L&&Ke&&L(ee),Tt.start(Ge.transitions.duration.shortest,()=>{ct.current=!1})}),kr=ee=>{ct.current&&ee.type!=="touchstart"||(Ee&&Ee.removeAttribute("title"),Ct.clear(),dt.clear(),F||Gn&&te?Ct.start(Gn?te:F,()=>{Uo(ee)}):Uo(ee))},qo=ee=>{Ct.clear(),dt.start(C,()=>{Vn(ee)})},{isFocusVisibleRef:Ho,onBlur:rl,onFocus:ol,ref:al}=ui(),[,Xo]=M.useState(!1),Yo=ee=>{rl(ee),Ho.current===!1&&(Xo(!1),qo(ee))},Wo=ee=>{Ee||Dn(ee.currentTarget),ol(ee),Ho.current===!0&&(Xo(!0),kr(ee))},Ko=ee=>{ct.current=!0;const Pe=xe.props;Pe.onTouchStart&&Pe.onTouchStart(ee)},Jo=kr,Zo=qo,sl=ee=>{Ko(ee),dt.clear(),Tt.clear(),Bn(),Zt.current=document.body.style.WebkitUserSelect,document.body.style.WebkitUserSelect="none",Jt.start(se,()=>{document.body.style.WebkitUserSelect=Zt.current,kr(ee)})},il=ee=>{xe.props.onTouchEnd&&xe.props.onTouchEnd(ee),Bn(),dt.start(z,()=>{Vn(ee)})};M.useEffect(()=>{if(!Ke)return;function ee(Pe){(Pe.key==="Escape"||Pe.key==="Esc")&&Vn(Pe)}return document.addEventListener("keydown",ee),()=>{document.removeEventListener("keydown",ee)}},[Vn,Ke]);const ll=yt(xe.ref,al,Dn,n);!ue&&ue!==0&&(Ke=!1);const Sr=M.useRef(),cl=ee=>{const Pe=xe.props;Pe.onMouseMove&&Pe.onMouseMove(ee),sn={x:ee.clientX,y:ee.clientY},Sr.current&&Sr.current.update()},Qt={},Er=typeof ue=="string";k?(Qt.title=!Ke&&Er&&!$?ue:null,Qt["aria-describedby"]=Ke?Nr:null):(Qt["aria-label"]=Er?ue:null,Qt["aria-labelledby"]=Ke&&!Er?Nr:null);const De=O({},Qt,A,xe.props,{className:ot(A.className,xe.props.className),onTouchStart:Ko,ref:ll},oe?{onMouseMove:cl}:{});process.env.NODE_ENV!=="production"&&(De["data-mui-internal-clone-element"]=!0,M.useEffect(()=>{Ee&&!Ee.getAttribute("data-mui-internal-clone-element")&&console.error(["MUI: The `children` component of the Tooltip is not forwarding its props correctly.","Please make sure that props are spread on the same element that the ref is applied to."].join(` +`))},[Ee]));const en={};Y||(De.onTouchStart=sl,De.onTouchEnd=il),$||(De.onMouseOver=Un(Jo,De.onMouseOver),De.onMouseLeave=Un(Zo,De.onMouseLeave),jt||(en.onMouseOver=Jo,en.onMouseLeave=Zo)),D||(De.onFocus=Un(Wo,De.onFocus),De.onBlur=Un(Yo,De.onBlur),jt||(en.onFocus=Wo,en.onBlur=Yo)),process.env.NODE_ENV!=="production"&&xe.props.title&&console.error(["MUI: You have provided a `title` prop to the child of .",`Remove this title prop \`${xe.props.title}\` or the Tooltip component.`].join(` +`));const dl=M.useMemo(()=>{var ee;let Pe=[{name:"arrow",enabled:!!Ue,options:{element:Ue,padding:4}}];return(ee=G.popperOptions)!=null&&ee.modifiers&&(Pe=Pe.concat(G.popperOptions.modifiers)),O({},G.popperOptions,{modifiers:Pe})},[Ue,G]),tn=O({},P,{isRtl:lt,arrow:V,disableInteractive:jt,placement:q,PopperComponentProp:H,touch:ct.current}),jr=am(tn),Qo=(r=(o=Z.popper)!=null?o:T.Popper)!=null?r:sm,ea=(s=(i=(l=Z.transition)!=null?l:T.Transition)!=null?i:I)!=null?s:Wa,ta=(c=(d=Z.tooltip)!=null?d:T.Tooltip)!=null?c:im,na=(u=(m=Z.arrow)!=null?m:T.Arrow)!=null?u:lm,ul=un(Qo,O({},G,(w=K.popper)!=null?w:_.popper,{className:ot(jr.popper,G==null?void 0:G.className,(b=(x=K.popper)!=null?x:_.popper)==null?void 0:b.className)}),tn),pl=un(ea,O({},ye,(f=K.transition)!=null?f:_.transition),tn),wl=un(ta,O({},(h=K.tooltip)!=null?h:_.tooltip,{className:ot(jr.tooltip,(S=(R=K.tooltip)!=null?R:_.tooltip)==null?void 0:S.className)}),tn),fl=un(na,O({},(j=K.arrow)!=null?j:_.arrow,{className:ot(jr.arrow,(E=(v=K.arrow)!=null?v:_.arrow)==null?void 0:E.className)}),tn);return a.jsxs(M.Fragment,{children:[M.cloneElement(xe,De),a.jsx(Qo,O({as:H??zi,placement:q,anchorEl:oe?{getBoundingClientRect:()=>({top:sn.y,left:sn.x,right:sn.x,bottom:sn.y,width:0,height:0})}:Ee,popperRef:Sr,open:Ee?Ke:!1,id:Nr,transition:!0},en,ul,{popperOptions:dl,children:({TransitionProps:ee})=>a.jsx(ea,O({timeout:Ge.transitions.duration.shorter},ee,pl,{children:a.jsxs(ta,O({},wl,{children:[ue,V?a.jsx(na,O({},fl,{ref:Et})):null]}))}))}))]})});process.env.NODE_ENV!=="production"&&(Li.propTypes={arrow:p.bool,children:si.isRequired,classes:p.object,className:p.string,components:p.shape({Arrow:p.elementType,Popper:p.elementType,Tooltip:p.elementType,Transition:p.elementType}),componentsProps:p.shape({arrow:p.object,popper:p.object,tooltip:p.object,transition:p.object}),describeChild:p.bool,disableFocusListener:p.bool,disableHoverListener:p.bool,disableInteractive:p.bool,disableTouchListener:p.bool,enterDelay:p.number,enterNextDelay:p.number,enterTouchDelay:p.number,followCursor:p.bool,id:p.string,leaveDelay:p.number,leaveTouchDelay:p.number,onClose:p.func,onOpen:p.func,open:p.bool,placement:p.oneOf(["bottom-end","bottom-start","bottom","left-end","left-start","left","right-end","right-start","right","top-end","top-start","top"]),PopperComponent:p.elementType,PopperProps:p.object,slotProps:p.shape({arrow:p.object,popper:p.object,tooltip:p.object,transition:p.object}),slots:p.shape({arrow:p.elementType,popper:p.elementType,tooltip:p.elementType,transition:p.elementType}),sx:p.oneOfType([p.arrayOf(p.oneOfType([p.func,p.object,p.bool])),p.func,p.object]),title:p.node,TransitionComponent:p.elementType,TransitionProps:p.object});const cm=Li;function Ja(e,t,n){return e?a.jsx(Te.ListItemIcon,{className:`papi-menu-icon-${n?"leading":"trailing"}`,children:a.jsx("img",{src:e,alt:`${n?"Leading":"Trailing"} icon for ${t}`})}):void 0}function Fo(e){const{onClick:t,label:n,tooltip:r,allowForLeadingIcons:o=!0,iconPathBefore:s=void 0,iconPathAfter:i=void 0,hasAutoFocus:l=!1,className:c,isDisabled:d=!1,isDense:u=!0,isSubMenuParent:m=!1,hasDisabledGutters:w=!1,hasDivider:b=!1,focusVisibleClassName:x,id:f,children:h}=e,S=a.jsx(Te.MenuItem,{sx:{lineHeight:.8},autoFocus:l,className:c,disabled:d,dense:u,disableGutters:w,divider:b,focusVisibleClassName:x,onClick:t,id:f,children:n?a.jsxs(a.Fragment,{children:[Ja(s,n,!0),a.jsx(Te.ListItemText,{primary:n,inset:!s&&o}),m?a.jsx(Te.ListItemIcon,{className:"papi-menu-icon-trailing",children:a.jsx(ki,{})}):Ja(i,n,!1)]}):h});return r?a.jsx(cm,{title:r,placement:"right",children:a.jsx("div",{children:S})}):S}function Fi(e){return Object.entries(e.groups).map(([n,r])=>({id:n,group:r}))}function dm(e){const[t,n]=g.useState(void 0),{parentMenuItem:r,parentItemProps:o,menuDefinition:s}=e,i=d=>{n(d.currentTarget)},l=()=>{n(void 0)},c=()=>{let d=Fi(s).filter(u=>"menuItem"in u.group);if(!(r!=null&&r.id))throw new Error("A valid parent menu item is required for submenus.");return d=d.filter(u=>"menuItem"in u.group&&u.group.menuItem===r.id),a.jsx(Gi,{...e,includedGroups:d})};return a.jsxs(a.Fragment,{children:[a.jsx(Fo,{onClick:i,...o,isSubMenuParent:!0}),a.jsx(Te.Menu,{anchorEl:t,open:!!t,onClose:l,anchorOrigin:{vertical:"top",horizontal:"right"},transformOrigin:{vertical:"top",horizontal:"left"},children:c()},r.id)]})}const um=(e,t)=>t.filter(o=>o.group===e).sort((o,s)=>(o.order||0)-(s.order||0));function Gi(e){const{menuDefinition:t,onClick:n,commandHandler:r,includedGroups:o}=e,{items:s,allowForLeadingIcons:i}=g.useMemo(()=>{const u=o&&o.length>0?o:Fi(t).filter(x=>!("menuItem"in x.group)),m=Object.values(u).sort((x,f)=>(x.group.order||0)-(f.group.order||0)),w=[];m.forEach(x=>{um(x.id,t.items).forEach(f=>w.push({item:f,isLastItemInGroup:!1})),w.length>0&&(w[w.length-1].isLastItemInGroup=!0)}),w.length>0&&(w[w.length-1].isLastItemInGroup=!1);const b=w.some(x=>"iconPathBefore"in x.item&&x.item.iconPathBefore);return{items:w,allowForLeadingIcons:b}},[o,t]),l=({item:u,isLastItemInGroup:m})=>({className:"papi-menu-item",label:u.label,tooltip:u.tooltip,iconPathBefore:"iconPathBefore"in u?u.iconPathBefore:void 0,iconPathAfter:"iconPathAfter"in u?u.iconPathAfter:void 0,hasDivider:m,allowForLeadingIcons:i}),[c]=s;if(!c)return a.jsx("div",{});const d=c.item.group;return a.jsx("div",{role:"menu","aria-label":d,children:s.map((u,m)=>{const{item:w}=u,b=l(u);if("command"in w){const x=w.group+m;return a.jsx(Fo,{onClick:f=>{n==null||n(f),r(w)},...b},x)}return a.jsx(dm,{parentMenuItem:w,parentItemProps:b,...e},d+w.id)})},d)}function pm(e){const{menuDefinition:t,columnId:n}=e;let s=Object.entries(t.groups).map(([i,l])=>({id:i,group:l})).filter(i=>"column"in i.group);return n&&"columns"in t&&t.columns[n]&&(s=s.filter(i=>"column"in i.group&&i.group.column===n)),a.jsx(Gi,{...e,includedGroups:s})}function wm({commandHandler:e,menuDefinition:t,id:n,metadata:r,onClick:o,className:s}){return a.jsxs(Te.Grid,{id:n,item:!0,xs:"auto",role:"menu","aria-label":n,className:`papi-menu-column ${s??""}`,children:[a.jsx("h3",{"aria-label":r.label,className:`papi-menu-column-header ${s??""}`,children:r.label}),a.jsx(Te.List,{id:n,dense:!0,className:s??"",children:a.jsx(pm,{commandHandler:e,menuDefinition:t,columnId:n,onClick:o})})]})}function Ui({commandHandler:e,className:t,multiColumnMenu:n,id:r}){const{columns:o}=n,s=g.useMemo(()=>{const i=new Map;return Object.getOwnPropertyNames(o).forEach(l=>{if(l==="isExtensible")return;const c=l,d=o[c];typeof d=="object"&&typeof d.order=="number"&&!Number.isNaN(d.order)?i.set(d.order,{id:c,metadata:d}):console.warn(`Property ${l} (${typeof d}) on menu ${r} is not a valid column and is being ignored. This might indicate data corruption`)}),Array.from(i.values()).sort((l,c)=>(l.metadata.order||0)-(c.metadata.order||0))},[o,r]);return a.jsx(Te.Grid,{container:!0,spacing:0,className:`papi-multi-column-menu ${t??""}`,columns:s.length,role:"menu","aria-label":"GridMenu",id:r,children:s.map((i,l)=>a.jsx(wm,{commandHandler:e,menuDefinition:n,...i,className:t},l))})}function fm(e){return{preserveValue:!0,...e}}const tr=(e,t,n={})=>{const r=g.useRef(t);r.current=t;const o=g.useRef(n);o.current=fm(o.current);const[s,i]=g.useState(()=>r.current),[l,c]=g.useState(!0);return g.useEffect(()=>{let d=!0;return c(!!e),(async()=>{if(e){const u=await e();d&&(i(()=>u),c(!1))}})(),()=>{d=!1,o.current.preserveValue||i(()=>r.current)}},[e]),[s,l]},mm=Ni(a.jsx("path",{d:"M3 18h18v-2H3zm0-5h18v-2H3zm0-7v2h18V6z"}),"Menu");function qi({menuProvider:e,normalMenu:t,fullMenu:n,commandHandler:r,containerRef:o,className:s,ariaLabelPrefix:i,children:l}){const[c,d]=g.useState(!1),[u,m]=g.useState(!1),w=g.useCallback(()=>{c&&d(!1),m(!1)},[c]),b=g.useCallback(E=>{E.stopPropagation(),d(v=>{const P=!v;return P&&E.shiftKey?m(!0):P||m(!1),P})},[]),x=g.useCallback(E=>(w(),r(E)),[r,w]),[f,h]=g.useState({top:1,left:1});g.useEffect(()=>{if(c){const E=o==null?void 0:o.current;if(E){const v=E.getBoundingClientRect(),P=window.scrollY,V=window.scrollX,U=v.top+P+E.clientHeight,T=v.left+V;h({top:U,left:T})}}},[c,o]);const[S]=tr(g.useCallback(async()=>(e==null?void 0:e(!1))??t,[e,t,c]),t),[R]=tr(g.useCallback(async()=>(e==null?void 0:e(!0))??n??S,[e,n,S,c]),n??S),j=u&&R?R:S;return a.jsxs(a.Fragment,{children:[a.jsx(Te.IconButton,{sx:{paddingTop:0,paddingBottom:0},edge:"start",className:`papi-menuButton ${s??""}`,color:"inherit","aria-label":`${i??""} menu button`,onClick:b,children:l??a.jsx(mm,{})}),a.jsx(Te.Drawer,{className:`papi-menu-drawer ${s??""}`,anchor:"left",variant:"temporary",open:c,onClose:w,PaperProps:{className:"papi-menu-drawer-paper",style:{top:f.top,left:f.left}},children:j?a.jsx(Ui,{className:s,id:`${i??""} main menu`,commandHandler:x,multiColumnMenu:j}):void 0})]})}function hm({id:e,label:t,isDisabled:n=!1,tooltip:r,isTooltipSuppressed:o=!1,adjustMarginToAlignToEdge:s=!1,size:i="medium",className:l,onClick:c,children:d}){return a.jsx(Te.IconButton,{id:e,disabled:n,edge:s,size:i,"aria-label":t,title:o?void 0:r??t,className:`papi-icon-button ${l??""}`,onClick:c,children:d})}const Kt=g.forwardRef(({className:e,...t},n)=>a.jsx(Q.LoaderCircle,{size:35,className:N("tw-animate-spin",e),...t,ref:n}));Kt.displayName="Spinner";function gm({id:e,isDisabled:t=!1,hasError:n=!1,isFullWidth:r=!1,helperText:o,label:s,placeholder:i,isRequired:l=!1,className:c,defaultValue:d,value:u,onChange:m,onFocus:w,onBlur:b}){return a.jsxs("div",{className:N("tw-inline-grid tw-items-center tw-gap-1.5",{"tw-w-full":r}),children:[a.jsx(qe,{htmlFor:e,className:N({"tw-text-red-600":n,"tw-hidden":!s}),children:`${s}${l?"*":""}`}),a.jsx(St,{id:e,disabled:t,placeholder:i,required:l,className:N(c,{"tw-border-red-600":n}),defaultValue:d,value:u,onChange:m,onFocus:w,onBlur:b}),a.jsx("p",{className:N({"tw-hidden":!o}),children:o})]})}function bm({menuProvider:e,commandHandler:t,className:n,id:r,children:o}){const s=g.useRef(void 0);return a.jsx("div",{ref:s,style:{position:"relative"},children:a.jsx(Te.AppBar,{position:"static",id:r,children:a.jsxs(Te.Toolbar,{className:N("tw-bg-muted tw-text-muted-foreground",n),variant:"dense",children:[e?a.jsx(qi,{commandHandler:t,containerRef:s,menuProvider:e}):void 0,o?a.jsx("div",{className:"papi-toolbar-children",children:o}):void 0]})})})}const vm=Xt.cva("tw-relative tw-w-full tw-rounded-lg tw-border tw-p-4 [&>svg~*]:tw-pl-7 [&>svg+div]:tw-translate-y-[-3px] [&>svg]:tw-absolute [&>svg]:tw-left-4 [&>svg]:tw-top-4 [&>svg]:tw-text-foreground",{variants:{variant:{default:"tw-bg-background tw-text-foreground",destructive:"tw-border-destructive/50 tw-text-destructive dark:tw-border-destructive [&>svg]:tw-text-destructive"}},defaultVariants:{variant:"default"}}),Hi=g.forwardRef(({className:e,variant:t,...n},r)=>a.jsx("div",{ref:r,role:"alert",className:N(vm({variant:t}),e),...n}));Hi.displayName="Alert";const Xi=g.forwardRef(({className:e,...t},n)=>a.jsxs("h5",{ref:n,className:N("tw-mb-1 tw-font-medium tw-leading-none tw-tracking-tight",e),...t,children:[t.children," "]}));Xi.displayName="AlertTitle";const Yi=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,className:N("tw-text-sm [&_p]:tw-leading-relaxed",e),...t}));Yi.displayName="AlertDescription";function xm({...e}){return a.jsx(Qa.Toaster,{className:"tw-toaster tw-group",toastOptions:{classNames:{toast:"group toast group-[.toaster]:bg-background group-[.toaster]:text-foreground group-[.toaster]:border-border group-[.toaster]:shadow-lg",description:"group-[.toast]:text-muted-foreground",actionButton:"group-[.toast]:bg-primary group-[.toast]:text-primary-foreground",cancelButton:"group-[.toast]:bg-muted group-[.toast]:text-muted-foreground"}},...e})}const Wi=g.forwardRef(({className:e,...t},n)=>a.jsxs(cn.Root,{ref:n,className:N("pr-twp tw-relative tw-flex tw-w-full tw-touch-none tw-select-none tw-items-center",e),...t,children:[a.jsx(cn.Track,{className:"tw-relative tw-h-2 tw-w-full tw-grow tw-overflow-hidden tw-rounded-full tw-bg-secondary",children:a.jsx(cn.Range,{className:"tw-absolute tw-h-full tw-bg-primary"})}),a.jsx(cn.Thumb,{className:"tw-block tw-h-5 tw-w-5 tw-rounded-full tw-border-2 tw-border-primary tw-bg-background tw-ring-offset-background tw-transition-colors focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50"})]}));Wi.displayName=cn.Root.displayName;const Ki=g.forwardRef(({className:e,...t},n)=>a.jsx(Ur.Root,{className:N("tw-peer pr-twp tw-inline-flex tw-h-6 tw-w-11 tw-shrink-0 tw-cursor-pointer tw-items-center tw-rounded-full tw-border-2 tw-border-transparent tw-transition-colors focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 focus-visible:tw-ring-offset-background disabled:tw-cursor-not-allowed disabled:tw-opacity-50 data-[state=checked]:tw-bg-primary data-[state=unchecked]:tw-bg-input",e),...t,ref:n,children:a.jsx(Ur.Thumb,{className:N("pr-twp tw-pointer-events-none tw-block tw-h-5 tw-w-5 tw-rounded-full tw-bg-background tw-shadow-lg tw-ring-0 tw-transition-transform data-[state=checked]:tw-translate-x-5 data-[state=unchecked]:tw-translate-x-0")})}));Ki.displayName=Ur.Root.displayName;const ym=_e.Root,Ji=g.forwardRef(({className:e,...t},n)=>a.jsx(_e.List,{ref:n,className:N("tw-inline-flex tw-h-10 tw-items-center tw-justify-center tw-rounded-md tw-bg-muted tw-p-1 tw-text-muted-foreground",e),...t}));Ji.displayName=_e.List.displayName;const Zi=g.forwardRef(({className:e,...t},n)=>a.jsx(_e.Trigger,{ref:n,className:N("tw-inline-flex tw-items-center tw-justify-center tw-whitespace-nowrap tw-rounded-sm tw-px-3 tw-py-1.5 tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-all hover:tw-text-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50 data-[state=active]:tw-bg-background data-[state=active]:tw-text-foreground data-[state=active]:tw-shadow-sm",e),...t}));Zi.displayName=_e.Trigger.displayName;const Qi=g.forwardRef(({className:e,...t},n)=>a.jsx(_e.Content,{ref:n,className:N("tw-mt-2 tw-ring-offset-background focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2",e),...t}));Qi.displayName=_e.Content.displayName;function Nm({isInstalling:e,handleClick:t,buttonText:n,className:r,...o}){return a.jsx(fe,{className:N("tw-h-8 tw-rounded-md tw-text-white tw-transition tw-duration-300 tw-ease-in-out hover:tw-bg-blue-700",{"tw-cursor-not-allowed tw-bg-blue-700":e,"tw-bg-blue-600":!e,"tw-bg-white tw-text-blue-600 hover:tw-text-white":!n,"tw-w-20":n},r),onClick:t,...o,children:e?a.jsx(Kt,{size:15}):a.jsxs(a.Fragment,{children:[a.jsx(Q.Download,{size:25,className:N("tw-h-4 tw-w-4",{"tw-mr-1":n})}),n]})})}function km({isEnabling:e,handleClick:t,className:n,...r}){return a.jsx(fe,{className:N("tw-h-8 tw-rounded-md tw-bg-blue-600 tw-px-4 tw-text-white tw-transition tw-duration-300 tw-ease-in-out hover:tw-bg-blue-700",{"tw-cursor-not-allowed tw-bg-blue-700":e},n),onClick:t,...r,children:e?a.jsxs(a.Fragment,{children:[a.jsx(Kt,{size:15,className:"tw-mr-1 tw-text-white"}),"Enabling..."]}):"Enable"})}function Sm({isDisabling:e,handleClick:t,className:n,...r}){return a.jsx(fe,{className:N("tw-h-8 tw-rounded-md tw-bg-gray-300 tw-text-black tw-transition tw-duration-300 tw-ease-in-out hover:tw-bg-gray-400",{"tw-cursor-not-allowed tw-bg-gray-400":e},n),onClick:t,...r,children:e?a.jsxs(a.Fragment,{children:[a.jsx(Kt,{size:15,className:"tw-mr-1 tw-text-black"}),"Disabling..."]}):"Disable"})}function Em({isUpdating:e,handleClick:t,className:n,...r}){return a.jsx(fe,{className:N("tw-h-8 tw-rounded-md tw-bg-blue-600 tw-px-4 tw-text-white tw-transition tw-duration-300 tw-ease-in-out hover:tw-bg-blue-700 hover:tw-text-white",{"tw-cursor-not-allowed tw-bg-blue-700":e},n),onClick:t,...r,children:e?a.jsxs(a.Fragment,{children:[a.jsx(Kt,{size:15,className:"tw-mr-1 tw-text-white"}),"Updating..."]}):"Update"})}function jm({id:e,markdown:t,className:n,anchorTarget:r}){const o=g.useMemo(()=>({overrides:{a:{props:{target:r}}}}),[r]);return a.jsx("div",{id:e,className:N("pr-twp tw-prose",n),children:a.jsx(Rl,{options:o,children:t})})}const el=g.forwardRef((e,t)=>a.jsxs(fe,{ref:t,className:"tw-rounded-md tw-border tw-border-dashed tw-border-gray-400 tw-bg-white tw-px-4 tw-py-2 tw-text-black tw-transition tw-duration-300 tw-ease-in-out hover:tw-border-blue-600 hover:tw-bg-white hover:tw-text-blue-600",...e,children:[a.jsx(Q.Filter,{size:16,className:"tw-mr-2 tw-h-4 tw-w-4 tw-text-gray-700 hover:tw-text-blue-600"}),"Filter",a.jsx(Q.ChevronDown,{size:16,className:"tw-ml-2 tw-h-4 tw-w-4 tw-text-gray-700 hover:tw-text-blue-600"})]}));var tl=(e=>(e[e.Check=0]="Check",e[e.Radio=1]="Radio",e))(tl||{});function Tm({id:e,groups:t}){return a.jsx("div",{id:e,children:a.jsxs(rr,{children:[a.jsx(ao,{asChild:!0,children:a.jsx(el,{})}),a.jsx(En,{children:t.map(n=>a.jsxs("div",{children:[a.jsx(Wt,{children:n.label}),a.jsx(cs,{children:n.items.map(r=>a.jsx("div",{children:r.itemType===0?a.jsx(or,{onClick:r.onClick,children:r.label}):a.jsx(io,{onClick:r.onClick,value:r.label,children:r.label})},r.label))}),a.jsx(jn,{})]},n.label))})]})})}function Cm({id:e,message:t}){return a.jsx("div",{id:e,className:"tw-mb-20 tw-mt-20 tw-flex tw-items-center tw-justify-center",children:a.jsx("div",{className:"tw-w-3/4 tw-rounded-lg tw-bg-gray-100 tw-p-8 tw-text-center",children:a.jsx("p",{className:"tw-text-lg tw-text-gray-800",children:t})})})}function Rm({id:e,category:t,downloads:n,languages:r,moreInfoUrl:o}){const s=new W.NumberFormat("en",{notation:"compact",compactDisplay:"short"}).format(Object.values(n).reduce((l,c)=>l+c,0)),i=()=>{window.scrollTo(0,document.body.scrollHeight)};return a.jsxs("div",{id:e,className:"tw-flex tw-flex-wrap tw-items-start tw-space-x-4 tw-border-b tw-border-t tw-bg-white tw-pb-4 tw-pt-4",children:[a.jsxs("div",{className:"tw-flex tw-flex-col tw-items-center",children:[a.jsx("div",{className:"tw-flex tw-items-center tw-rounded-md tw-bg-gray-100 tw-px-2 tw-py-1",children:a.jsx("span",{className:"tw-text-xs tw-font-semibold tw-text-gray-700",children:t})}),a.jsx("span",{className:"tw-text-xs tw-text-gray-500",children:"CATEGORY"})]}),a.jsx("div",{className:"tw-mx-2 tw-h-10 tw-border-l tw-border-gray-300"}),a.jsxs("div",{className:"tw-flex tw-flex-col tw-items-center",children:[a.jsxs("div",{className:"tw-flex tw-items-center tw-rounded-md tw-bg-gray-100 tw-px-2 tw-py-1",children:[a.jsx(Q.User,{className:"tw-mr-1 tw-h-4 tw-w-4"}),a.jsx("span",{className:"tw-text-xs tw-font-semibold tw-text-gray-700",children:s})]}),a.jsx("span",{className:"tw-text-xs tw-text-gray-500",children:"USERS"})]}),a.jsx("div",{className:"tw-mx-2 tw-h-10 tw-border-l tw-border-gray-300"}),a.jsxs("div",{className:"tw-flex tw-flex-col tw-items-center",children:[a.jsx("div",{className:"tw-flex tw-items-center",children:r.slice(0,3).map(l=>a.jsx("span",{className:"tw-ml-1 tw-rounded-md tw-bg-gray-100 tw-px-2 tw-py-1 tw-text-xs tw-font-semibold tw-text-gray-700",children:l.toUpperCase()},l))}),r.length>3&&a.jsxs("button",{type:"button",onClick:()=>i(),className:"tw-text-xs tw-text-gray-500 tw-underline",children:["+",r.length-3," more languages"]})]}),a.jsx("div",{className:"tw-mx-2 tw-h-10 tw-border-l tw-border-gray-300"}),a.jsxs("div",{className:"tw-ml-auto tw-flex tw-flex-col tw-space-y-2",children:[a.jsxs("a",{href:o,target:"_blank",rel:"noreferrer",className:"tw-flex tw-items-center tw-text-xs tw-font-semibold tw-text-gray-500 tw-underline",children:["Website",a.jsx(Q.Link,{className:"tw-ml-1 tw-inline tw-h-4 tw-w-4"})]}),a.jsxs("a",{href:"https://example.com",target:"_blank",rel:"noreferrer",className:"tw-flex tw-items-center tw-text-xs tw-font-semibold tw-text-gray-500 tw-underline",children:["Support",a.jsx(Q.CircleHelp,{className:"tw-ml-1 tw-inline tw-h-4 tw-w-4"})]})]})]})}function nl({id:e,versionHistory:t}){const[n,r]=g.useState(!1),o=new Date;function s(l){const c=new Date(l),d=new Date(o.getTime()-c.getTime()),u=d.getUTCFullYear()-1970,m=d.getUTCMonth(),w=d.getUTCDate()-1;let b="";return u>0?b=`${u.toString()} year${u===1?"":"s"} ago`:m>0?b=`${m.toString()} month${m===1?"":"s"} ago`:w===0?b="today":b=`${w.toString()} day${w===1?"":"s"} ago`,b}const i=Object.entries(t).sort((l,c)=>c[0].localeCompare(l[0]));return a.jsxs("div",{id:e,children:[a.jsx("h3",{className:"tw-text-md tw-font-semibold",children:"What`s New"}),a.jsx("ul",{className:"tw-list-disc tw-pl-5 tw-pr-4 tw-text-xs tw-text-gray-600",children:(n?i:i.slice(0,5)).map(l=>a.jsxs("div",{className:"tw-mt-3 tw-flex tw-justify-between",children:[a.jsx("div",{className:"tw-text-gray-600",children:a.jsx("li",{className:"tw-prose tw-text-xs",children:a.jsx("span",{children:l[1].description})})}),a.jsxs("div",{className:"tw-justify-end tw-text-right",children:[a.jsxs("div",{children:["Version ",l[0]]}),a.jsx("div",{children:s(l[1].date)})]})]},l[0]))}),i.length>5&&a.jsx("button",{type:"button",onClick:()=>r(!n),className:"tw-text-xs tw-text-gray-500 tw-underline",children:n?"Show Less Version History":"Show All Version History"})]})}function Om({id:e,publisherDisplayName:t,fileSize:n,locales:r,versionHistory:o}){const s=g.useMemo(()=>W.formatBytes(n),[n]),l=(c=>{const d=new Intl.DisplayNames(navigator.language,{type:"language"});return c.map(u=>d.of(u))})(r);return a.jsx("div",{id:e,className:"tw-border-t tw-pb-4 tw-pt-4",children:a.jsxs("div",{className:"tw-md:flex-row tw-md:space-x-8 tw-flex tw-flex-col tw-space-x-0",children:[a.jsx(nl,{versionHistory:o}),a.jsx("div",{className:"tw-md:border-t-0 tw-md:border-l tw-md-h-auto tw-md-ml-8 tw-mt-4 tw-border-t tw-border-gray-300"}),a.jsxs("div",{className:"tw-md:mt-0 tw-mt-4 tw-flex-1 tw-space-y-3",children:[a.jsx("h2",{className:"tw-text-md tw-font-semibold",children:"Information"}),a.jsxs("div",{className:"tw-flex tw-items-start tw-justify-between tw-pr-4 tw-text-xs tw-text-gray-600",children:[a.jsxs("p",{className:"tw-flex tw-flex-col tw-justify-start",children:[a.jsx("span",{className:"tw-mb-2",children:"Publisher"}),a.jsx("span",{className:"tw-font-semibold",children:t}),a.jsx("span",{className:"tw-mb-2 tw-mt-4",children:"Size"}),a.jsx("span",{className:"tw-font-semibold",children:s})]}),a.jsx("div",{className:"tw-flex tw-w-3/4 tw-items-center tw-justify-between tw-text-xs tw-text-gray-600",children:a.jsxs("p",{className:"tw-flex tw-flex-col tw-justify-start",children:[a.jsx("span",{className:"tw-mb-2",children:"Languages"}),a.jsx("span",{className:"tw-font-semibold",children:l.join(", ")})]})})]})]})]})})}const _m=(e,t)=>{g.useEffect(()=>{if(!e)return()=>{};const n=e(t);return()=>{n()}},[e,t])},Lr=()=>!1,Pm=(e,t)=>{const[n]=tr(g.useCallback(async()=>{if(!e)return Lr;const r=await Promise.resolve(e(t));return async()=>r()},[t,e]),Lr,{preserveValue:!1});g.useEffect(()=>()=>{n!==Lr&&n()},[n])};Object.defineProperty(exports,"sonner",{enumerable:!0,get:()=>Qa.toast});exports.Alert=Hi;exports.AlertDescription=Yi;exports.AlertTitle=Xi;exports.BOOK_SELECTOR_STRING_KEYS=mc;exports.BookChapterControl=oc;exports.BookSelectionMode=Ns;exports.BookSelector=hc;exports.Button=fe;exports.Card=ho;exports.CardContent=Zs;exports.CardDescription=vo;exports.CardFooter=Qs;exports.CardHeader=go;exports.CardTitle=bo;exports.ChapterRangeSelector=ys;exports.Checkbox=ar;exports.Checklist=vd;exports.ComboBox=qr;exports.DataTable=Cs;exports.DisableButton=Sm;exports.DropdownMenu=rr;exports.DropdownMenuCheckboxItem=or;exports.DropdownMenuContent=En;exports.DropdownMenuGroup=cs;exports.DropdownMenuItem=so;exports.DropdownMenuItemType=tl;exports.DropdownMenuLabel=Wt;exports.DropdownMenuPortal=ql;exports.DropdownMenuRadioGroup=Xl;exports.DropdownMenuRadioItem=io;exports.DropdownMenuSeparator=jn;exports.DropdownMenuShortcut=ps;exports.DropdownMenuSub=Hl;exports.DropdownMenuSubContent=us;exports.DropdownMenuSubTrigger=ds;exports.DropdownMenuTrigger=ao;exports.EnableButton=km;exports.FilterButton=el;exports.FilterDropdown=Tm;exports.Footer=Om;exports.GridMenu=Ui;exports.HamburgerMenuButton=qi;exports.INVENTORY_STRING_KEYS=Ec;exports.IconButton=hm;exports.Input=St;exports.InstallButton=Nm;exports.Inventory=Cc;exports.Label=qe;exports.MarkdownRenderer=jm;exports.MenuItem=Fo;exports.MoreInfo=Rm;exports.NavigationContentSearch=Rc;exports.NoExtensionsFound=Cm;exports.RadioGroup=lo;exports.RadioGroupItem=Yn;exports.ScriptureResultsViewer=wd;exports.ScrollGroupSelector=fd;exports.SearchBar=Ms;exports.Select=At;exports.SelectContent=vt;exports.SelectGroup=ks;exports.SelectItem=Ae;exports.SelectLabel=Ss;exports.SelectScrollDownButton=uo;exports.SelectScrollUpButton=co;exports.SelectSeparator=Es;exports.SelectTrigger=bt;exports.SelectValue=Bt;exports.Separator=ir;exports.SettingsCard=bd;exports.SettingsList=md;exports.SettingsListHeader=gd;exports.SettingsListItem=hd;exports.SettingsSidebar=Ks;exports.SettingsSidebarContentSearch=ad;exports.Slider=Wi;exports.Sonner=xm;exports.Spinner=Kt;exports.Switch=Ki;exports.Table=Tn;exports.TableBody=Rn;exports.TableCaption=Ts;exports.TableCell=xt;exports.TableFooter=js;exports.TableHead=Vt;exports.TableHeader=Cn;exports.TableRow=Ze;exports.Tabs=ym;exports.TabsContent=Qi;exports.TabsList=Ji;exports.TabsTrigger=Zi;exports.TextField=gm;exports.ToggleGroup=po;exports.ToggleGroupItem=fn;exports.Toolbar=bm;exports.UpdateButton=Em;exports.VersionHistory=nl;exports.VerticalTabs=wo;exports.VerticalTabsContent=mo;exports.VerticalTabsList=fo;exports.VerticalTabsTrigger=$s;exports.buttonVariants=ws;exports.cn=N;exports.getBookNumFromId=Os;exports.getLinesFromUSFM=Rs;exports.getNumberFromUSFM=Hr;exports.getStatusForItem=_s;exports.inventoryCountColumn=kc;exports.inventoryItemColumn=yc;exports.inventoryStatusColumn=Sc;exports.useEvent=_m;exports.useEventAsync=Pm;exports.usePromise=tr;function Im(e,t="top"){if(!e||typeof document>"u")return;const n=document.head||document.querySelector("head"),r=n.querySelector(":first-child"),o=document.createElement("style");o.appendChild(document.createTextNode(e)),t==="top"&&r?n.insertBefore(o,r):n.appendChild(o)}Im(`*, ::before, ::after { --tw-border-spacing-x: 0; --tw-border-spacing-y: 0; --tw-translate-x: 0; @@ -1134,13 +1134,23 @@ video:where(.pr-twp,.pr-twp *) { .tw-inset-0 { inset: 0px; } +.tw-inset-x-0 { + left: 0px; + right: 0px; +} .tw-inset-y-0 { top: 0px; bottom: 0px; } +.tw-bottom-0 { + bottom: 0px; +} .tw-bottom-2 { bottom: 0.5rem; } +.tw-left-0 { + left: 0px; +} .tw-left-2 { left: 0.5rem; } @@ -1150,6 +1160,12 @@ video:where(.pr-twp,.pr-twp *) { .tw-left-\\[50\\%\\] { left: 50%; } +.tw-right-0 { + right: 0px; +} +.tw-right-1 { + right: 0.25rem; +} .tw-right-3 { right: 0.75rem; } @@ -1159,12 +1175,18 @@ video:where(.pr-twp,.pr-twp *) { .tw-top-0 { top: 0px; } +.tw-top-1\\.5 { + top: 0.375rem; +} .tw-top-1\\/2 { top: 50%; } .tw-top-2\\.5 { top: 0.625rem; } +.tw-top-3\\.5 { + top: 0.875rem; +} .tw-top-4 { top: 1rem; } @@ -1177,6 +1199,9 @@ video:where(.pr-twp,.pr-twp *) { .tw-z-10 { z-index: 10; } +.tw-z-20 { + z-index: 20; +} .tw-z-30 { z-index: 30; } @@ -1204,6 +1229,10 @@ video:where(.pr-twp,.pr-twp *) { margin-left: 0.5rem; margin-right: 0.5rem; } +.tw-mx-3\\.5 { + margin-left: 0.875rem; + margin-right: 0.875rem; +} .tw-my-1 { margin-top: 0.25rem; margin-bottom: 0.25rem; @@ -1300,6 +1329,10 @@ video:where(.pr-twp,.pr-twp *) { .tw-aspect-square { aspect-ratio: 1 / 1; } +.tw-size-4 { + width: 1rem; + height: 1rem; +} .tw-h-1\\/2 { height: 50%; } @@ -1375,6 +1408,9 @@ video:where(.pr-twp,.pr-twp *) { .tw-h-px { height: 1px; } +.tw-h-svh { + height: 100svh; +} .tw-max-h-80 { max-height: 20rem; } @@ -1384,6 +1420,12 @@ video:where(.pr-twp,.pr-twp *) { .tw-max-h-\\[300px\\] { max-height: 300px; } +.tw-min-h-0 { + min-height: 0px; +} +.tw-min-h-svh { + min-height: 100svh; +} .tw-w-0 { width: 0px; } @@ -1426,6 +1468,9 @@ video:where(.pr-twp,.pr-twp *) { .tw-w-6 { width: 1.5rem; } +.tw-w-7 { + width: 1.75rem; +} .tw-w-72 { width: 18rem; } @@ -1435,6 +1480,9 @@ video:where(.pr-twp,.pr-twp *) { .tw-w-9 { width: 2.25rem; } +.tw-w-\\[--sidebar-width\\] { + width: var(--sidebar-width); +} .tw-w-\\[1\\.2rem\\] { width: 1.2rem; } @@ -1468,6 +1516,12 @@ video:where(.pr-twp,.pr-twp *) { .tw-w-full { width: 100%; } +.tw-min-w-0 { + min-width: 0px; +} +.tw-min-w-5 { + min-width: 1.25rem; +} .tw-min-w-\\[8rem\\] { min-width: 8rem; } @@ -1477,6 +1531,9 @@ video:where(.pr-twp,.pr-twp *) { .tw-max-w-64 { max-width: 16rem; } +.tw-max-w-\\[--skeleton-width\\] { + max-width: var(--skeleton-width); +} .tw-max-w-lg { max-width: 32rem; } @@ -1498,6 +1555,14 @@ video:where(.pr-twp,.pr-twp *) { .tw-caption-bottom { caption-side: bottom; } +.tw--translate-x-1\\/2 { + --tw-translate-x: -50%; + transform: translate(var(--tw-translate-x), var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y)); +} +.tw--translate-x-px { + --tw-translate-x: -1px; + transform: translate(var(--tw-translate-x), var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y)); +} .tw--translate-y-1\\/2 { --tw-translate-y: -50%; transform: translate(var(--tw-translate-x), var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y)); @@ -1506,6 +1571,10 @@ video:where(.pr-twp,.pr-twp *) { --tw-translate-x: -50%; transform: translate(var(--tw-translate-x), var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y)); } +.tw-translate-x-px { + --tw-translate-x: 1px; + transform: translate(var(--tw-translate-x), var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y)); +} .tw-translate-y-\\[-50\\%\\] { --tw-translate-y: -50%; transform: translate(var(--tw-translate-x), var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y)); @@ -1531,6 +1600,15 @@ video:where(.pr-twp,.pr-twp *) { .tw-transform { transform: translate(var(--tw-translate-x), var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y)); } +@keyframes tw-pulse { + + 50% { + opacity: .5; + } +} +.tw-animate-pulse { + animation: tw-pulse 2s cubic-bezier(0.4, 0, 0.6, 1) infinite; +} @keyframes tw-spin { to { @@ -1766,6 +1844,9 @@ video:where(.pr-twp,.pr-twp *) { .tw-border-l-2 { border-left-width: 2px; } +.tw-border-r { + border-right-width: 1px; +} .tw-border-r-0 { border-right-width: 0px; } @@ -1810,6 +1891,9 @@ video:where(.pr-twp,.pr-twp *) { --tw-border-opacity: 1; border-color: rgb(220 38 38 / var(--tw-border-opacity)); } +.tw-border-sidebar-border { + border-color: hsl(var(--sidebar-border)); +} .tw-border-transparent { border-color: transparent; } @@ -1927,6 +2011,12 @@ video:where(.pr-twp,.pr-twp *) { .tw-bg-secondary-foreground { background-color: hsl(var(--secondary-foreground)); } +.tw-bg-sidebar { + background-color: hsl(var(--sidebar-background)); +} +.tw-bg-sidebar-border { + background-color: hsl(var(--sidebar-border)); +} .tw-bg-transparent { background-color: transparent; } @@ -1994,6 +2084,10 @@ video:where(.pr-twp,.pr-twp *) { padding-left: 2rem; padding-right: 2rem; } +.tw-py-0\\.5 { + padding-top: 0.125rem; + padding-bottom: 0.125rem; +} .tw-py-1 { padding-top: 0.25rem; padding-bottom: 0.25rem; @@ -2066,6 +2160,9 @@ video:where(.pr-twp,.pr-twp *) { .tw-pt-4 { padding-top: 1rem; } +.tw-text-left { + text-align: left; +} .tw-text-center { text-align: center; } @@ -2224,6 +2321,12 @@ video:where(.pr-twp,.pr-twp *) { .tw-text-secondary-foreground { color: hsl(var(--secondary-foreground)); } +.tw-text-sidebar-foreground { + color: hsl(var(--sidebar-foreground)); +} +.tw-text-sidebar-foreground\\/70 { + color: hsl(var(--sidebar-foreground) / 0.7); +} .tw-text-slate-900 { --tw-text-opacity: 1; color: rgb(15 23 42 / var(--tw-text-opacity)); @@ -2254,6 +2357,11 @@ video:where(.pr-twp,.pr-twp *) { .tw-opacity-70 { opacity: 0.7; } +.tw-shadow-\\[0_0_0_1px_hsl\\(var\\(--sidebar-border\\)\\)\\] { + --tw-shadow: 0 0 0 1px hsl(var(--sidebar-border)); + --tw-shadow-colored: 0 0 0 1px var(--tw-shadow-color); + box-shadow: var(--tw-ring-offset-shadow, 0 0 #0000), var(--tw-ring-shadow, 0 0 #0000), var(--tw-shadow); +} .tw-shadow-lg { --tw-shadow: 0 10px 15px -3px rgb(0 0 0 / 0.1), 0 4px 6px -4px rgb(0 0 0 / 0.1); --tw-shadow-colored: 0 10px 15px -3px var(--tw-shadow-color), 0 4px 6px -4px var(--tw-shadow-color); @@ -2283,6 +2391,9 @@ video:where(.pr-twp,.pr-twp *) { --tw-ring-shadow: var(--tw-ring-inset) 0 0 0 calc(0px + var(--tw-ring-offset-width)) var(--tw-ring-color); box-shadow: var(--tw-ring-offset-shadow), var(--tw-ring-shadow), var(--tw-shadow, 0 0 #0000); } +.tw-ring-sidebar-ring { + --tw-ring-color: hsl(var(--sidebar-ring)); +} .tw-ring-offset-background { --tw-ring-offset-color: hsl(var(--background)); } @@ -2295,6 +2406,26 @@ video:where(.pr-twp,.pr-twp *) { transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1); transition-duration: 150ms; } +.tw-transition-\\[left\\,right\\,width\\] { + transition-property: left,right,width; + transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1); + transition-duration: 150ms; +} +.tw-transition-\\[margin\\,opa\\] { + transition-property: margin,opa; + transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1); + transition-duration: 150ms; +} +.tw-transition-\\[width\\,height\\,padding\\] { + transition-property: width,height,padding; + transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1); + transition-duration: 150ms; +} +.tw-transition-\\[width\\] { + transition-property: width; + transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1); + transition-duration: 150ms; +} .tw-transition-all { transition-property: all; transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1); @@ -2324,6 +2455,9 @@ video:where(.pr-twp,.pr-twp *) { .tw-ease-in-out { transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1); } +.tw-ease-linear { + transition-timing-function: linear; +} @keyframes enter { from { @@ -2338,6 +2472,21 @@ video:where(.pr-twp,.pr-twp *) { transform: translate3d(var(--tw-exit-translate-x, 0), var(--tw-exit-translate-y, 0), 0) scale3d(var(--tw-exit-scale, 1), var(--tw-exit-scale, 1), var(--tw-exit-scale, 1)) rotate(var(--tw-exit-rotate, 0)); } } +.tw-animate-in { + animation-name: enter; + animation-duration: 150ms; + --tw-enter-opacity: initial; + --tw-enter-scale: initial; + --tw-enter-rotate: initial; + --tw-enter-translate-x: initial; + --tw-enter-translate-y: initial; +} +.tw-fade-in-0 { + --tw-enter-opacity: 0; +} +.tw-zoom-in-95 { + --tw-enter-scale: .95; +} .tw-duration-200 { animation-duration: 200ms; } @@ -2347,6 +2496,9 @@ video:where(.pr-twp,.pr-twp *) { .tw-ease-in-out { animation-timing-function: cubic-bezier(0.4, 0, 0.2, 1); } +.tw-ease-linear { + animation-timing-function: linear; +} /* #region shared with https://github.com/paranext/paranext-extension-template/blob/main/tailwind.css */ @@ -2381,6 +2533,32 @@ video:where(.pr-twp,.pr-twp *) { color: hsl(var(--muted-foreground)); } +.after\\:tw-absolute::after { + content: var(--tw-content); + position: absolute; +} + +.after\\:tw--inset-2::after { + content: var(--tw-content); + inset: -0.5rem; +} + +.after\\:tw-inset-y-0::after { + content: var(--tw-content); + top: 0px; + bottom: 0px; +} + +.after\\:tw-left-1\\/2::after { + content: var(--tw-content); + left: 50%; +} + +.after\\:tw-w-\\[2px\\]::after { + content: var(--tw-content); + width: 2px; +} + .hover\\:tw-border-blue-600:hover { --tw-border-opacity: 1; border-color: rgb(37 99 235 / var(--tw-border-opacity)); @@ -2420,6 +2598,10 @@ video:where(.pr-twp,.pr-twp *) { background-color: hsl(var(--secondary) / 0.8); } +.hover\\:tw-bg-sidebar-accent:hover { + background-color: hsl(var(--sidebar-accent)); +} + .hover\\:tw-bg-white:hover { --tw-bg-opacity: 1; background-color: rgb(255 255 255 / var(--tw-bg-opacity)); @@ -2442,6 +2624,10 @@ video:where(.pr-twp,.pr-twp *) { color: hsl(var(--muted-foreground)); } +.hover\\:tw-text-sidebar-accent-foreground:hover { + color: hsl(var(--sidebar-accent-foreground)); +} + .hover\\:tw-text-white:hover { --tw-text-opacity: 1; color: rgb(255 255 255 / var(--tw-text-opacity)); @@ -2455,6 +2641,17 @@ video:where(.pr-twp,.pr-twp *) { opacity: 1; } +.hover\\:tw-shadow-\\[0_0_0_1px_hsl\\(var\\(--sidebar-accent\\)\\)\\]:hover { + --tw-shadow: 0 0 0 1px hsl(var(--sidebar-accent)); + --tw-shadow-colored: 0 0 0 1px var(--tw-shadow-color); + box-shadow: var(--tw-ring-offset-shadow, 0 0 #0000), var(--tw-ring-shadow, 0 0 #0000), var(--tw-shadow); +} + +.hover\\:after\\:tw-bg-sidebar-border:hover::after { + content: var(--tw-content); + background-color: hsl(var(--sidebar-border)); +} + .focus\\:tw-bg-accent:focus { background-color: hsl(var(--accent)); } @@ -2502,6 +2699,10 @@ video:where(.pr-twp,.pr-twp *) { --tw-ring-color: hsl(var(--ring)); } +.focus-visible\\:tw-ring-sidebar-ring:focus-visible { + --tw-ring-color: hsl(var(--sidebar-ring)); +} + .focus-visible\\:tw-ring-offset-2:focus-visible { --tw-ring-offset-width: 2px; } @@ -2510,6 +2711,14 @@ video:where(.pr-twp,.pr-twp *) { --tw-ring-offset-color: hsl(var(--background)); } +.active\\:tw-bg-sidebar-accent:active { + background-color: hsl(var(--sidebar-accent)); +} + +.active\\:tw-text-sidebar-accent-foreground:active { + color: hsl(var(--sidebar-accent-foreground)); +} + .disabled\\:tw-pointer-events-none:disabled { pointer-events: none; } @@ -2534,6 +2743,18 @@ video:where(.pr-twp,.pr-twp *) { opacity: 0.7; } +.has-\\[\\[data-variant\\=inset\\]\\]\\:tw-bg-sidebar:has([data-variant=inset]) { + background-color: hsl(var(--sidebar-background)); +} + +.aria-disabled\\:tw-pointer-events-none[aria-disabled="true"] { + pointer-events: none; +} + +.aria-disabled\\:tw-opacity-50[aria-disabled="true"] { + opacity: 0.5; +} + .data-\\[disabled\\=true\\]\\:tw-pointer-events-none[data-disabled="true"] { pointer-events: none; } @@ -2572,6 +2793,10 @@ video:where(.pr-twp,.pr-twp *) { transform: translate(var(--tw-translate-x), var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y)); } +.data-\\[active\\=true\\]\\:tw-bg-sidebar-accent[data-active="true"] { + background-color: hsl(var(--sidebar-accent)); +} + .data-\\[highlighted\\]\\:tw-bg-amber-100[data-highlighted] { --tw-bg-opacity: 1; background-color: rgb(254 243 199 / var(--tw-bg-opacity)); @@ -2597,6 +2822,10 @@ video:where(.pr-twp,.pr-twp *) { background-color: hsl(var(--accent)); } +.data-\\[state\\=open\\]\\:tw-bg-secondary[data-state="open"] { + background-color: hsl(var(--secondary)); +} + .data-\\[state\\=selected\\]\\:tw-bg-muted[data-state="selected"] { background-color: hsl(var(--muted)); } @@ -2605,6 +2834,14 @@ video:where(.pr-twp,.pr-twp *) { background-color: hsl(var(--input)); } +.data-\\[active\\=true\\]\\:tw-font-medium[data-active="true"] { + font-weight: 500; +} + +.data-\\[active\\=true\\]\\:tw-text-sidebar-accent-foreground[data-active="true"] { + color: hsl(var(--sidebar-accent-foreground)); +} + .data-\\[selected\\=true\\]\\:tw-text-accent-foreground[data-selected="true"] { color: hsl(var(--accent-foreground)); } @@ -2633,12 +2870,24 @@ video:where(.pr-twp,.pr-twp *) { opacity: 0.5; } +.data-\\[state\\=open\\]\\:tw-opacity-100[data-state="open"] { + opacity: 1; +} + .data-\\[state\\=active\\]\\:tw-shadow-sm[data-state="active"] { --tw-shadow: 0 1px 2px 0 rgb(0 0 0 / 0.05); --tw-shadow-colored: 0 1px 2px 0 var(--tw-shadow-color); box-shadow: var(--tw-ring-offset-shadow, 0 0 #0000), var(--tw-ring-shadow, 0 0 #0000), var(--tw-shadow); } +.data-\\[state\\=closed\\]\\:tw-duration-300[data-state="closed"] { + transition-duration: 300ms; +} + +.data-\\[state\\=open\\]\\:tw-duration-500[data-state="open"] { + transition-duration: 500ms; +} + .data-\\[state\\=open\\]\\:tw-animate-in[data-state="open"] { animation-name: enter; animation-duration: 150ms; @@ -2691,22 +2940,167 @@ video:where(.pr-twp,.pr-twp *) { --tw-enter-translate-y: 0.5rem; } +.data-\\[state\\=closed\\]\\:tw-slide-out-to-bottom[data-state="closed"] { + --tw-exit-translate-y: 100%; +} + +.data-\\[state\\=closed\\]\\:tw-slide-out-to-left[data-state="closed"] { + --tw-exit-translate-x: -100%; +} + .data-\\[state\\=closed\\]\\:tw-slide-out-to-left-1\\/2[data-state="closed"] { --tw-exit-translate-x: -50%; } +.data-\\[state\\=closed\\]\\:tw-slide-out-to-right[data-state="closed"] { + --tw-exit-translate-x: 100%; +} + +.data-\\[state\\=closed\\]\\:tw-slide-out-to-top[data-state="closed"] { + --tw-exit-translate-y: -100%; +} + .data-\\[state\\=closed\\]\\:tw-slide-out-to-top-\\[48\\%\\][data-state="closed"] { --tw-exit-translate-y: -48%; } +.data-\\[state\\=open\\]\\:tw-slide-in-from-bottom[data-state="open"] { + --tw-enter-translate-y: 100%; +} + +.data-\\[state\\=open\\]\\:tw-slide-in-from-left[data-state="open"] { + --tw-enter-translate-x: -100%; +} + .data-\\[state\\=open\\]\\:tw-slide-in-from-left-1\\/2[data-state="open"] { --tw-enter-translate-x: -50%; } +.data-\\[state\\=open\\]\\:tw-slide-in-from-right[data-state="open"] { + --tw-enter-translate-x: 100%; +} + +.data-\\[state\\=open\\]\\:tw-slide-in-from-top[data-state="open"] { + --tw-enter-translate-y: -100%; +} + .data-\\[state\\=open\\]\\:tw-slide-in-from-top-\\[48\\%\\][data-state="open"] { --tw-enter-translate-y: -48%; } +.data-\\[state\\=closed\\]\\:tw-duration-300[data-state="closed"] { + animation-duration: 300ms; +} + +.data-\\[state\\=open\\]\\:tw-duration-500[data-state="open"] { + animation-duration: 500ms; +} + +.data-\\[state\\=open\\]\\:hover\\:tw-bg-sidebar-accent:hover[data-state="open"] { + background-color: hsl(var(--sidebar-accent)); +} + +.data-\\[state\\=open\\]\\:hover\\:tw-text-sidebar-accent-foreground:hover[data-state="open"] { + color: hsl(var(--sidebar-accent-foreground)); +} + +.tw-group[data-collapsible="offcanvas"] .group-data-\\[collapsible\\=offcanvas\\]\\:tw-left-\\[calc\\(var\\(--sidebar-width\\)\\*-1\\)\\] { + left: calc(var(--sidebar-width) * -1); +} + +.tw-group[data-collapsible="offcanvas"] .group-data-\\[collapsible\\=offcanvas\\]\\:tw-right-\\[calc\\(var\\(--sidebar-width\\)\\*-1\\)\\] { + right: calc(var(--sidebar-width) * -1); +} + +.tw-group[data-side="left"] .group-data-\\[side\\=left\\]\\:tw--right-4 { + right: -1rem; +} + +.tw-group[data-side="right"] .group-data-\\[side\\=right\\]\\:tw-left-0 { + left: 0px; +} + +.tw-group[data-collapsible="icon"] .group-data-\\[collapsible\\=icon\\]\\:tw--mt-8 { + margin-top: -2rem; +} + +.tw-group[data-collapsible="icon"] .group-data-\\[collapsible\\=icon\\]\\:tw-hidden { + display: none; +} + +.tw-group[data-collapsible="icon"] .group-data-\\[collapsible\\=icon\\]\\:tw-w-\\[--sidebar-width-icon\\] { + width: var(--sidebar-width-icon); +} + +.tw-group[data-collapsible="icon"] .group-data-\\[collapsible\\=icon\\]\\:tw-w-\\[calc\\(var\\(--sidebar-width-icon\\)_\\+_theme\\(spacing\\.4\\)\\)\\] { + width: calc(var(--sidebar-width-icon) + 1rem); +} + +.tw-group[data-collapsible="icon"] .group-data-\\[collapsible\\=icon\\]\\:tw-w-\\[calc\\(var\\(--sidebar-width-icon\\)_\\+_theme\\(spacing\\.4\\)_\\+2px\\)\\] { + width: calc(var(--sidebar-width-icon) + 1rem + 2px); +} + +.tw-group[data-collapsible="offcanvas"] .group-data-\\[collapsible\\=offcanvas\\]\\:tw-w-0 { + width: 0px; +} + +.tw-group[data-collapsible="offcanvas"] .group-data-\\[collapsible\\=offcanvas\\]\\:tw-translate-x-0 { + --tw-translate-x: 0px; + transform: translate(var(--tw-translate-x), var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y)); +} + +.tw-group[data-side="right"] .group-data-\\[side\\=right\\]\\:tw-rotate-180 { + --tw-rotate: 180deg; + transform: translate(var(--tw-translate-x), var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y)); +} + +.tw-group[data-collapsible="icon"] .group-data-\\[collapsible\\=icon\\]\\:tw-overflow-hidden { + overflow: hidden; +} + +.tw-group[data-variant="floating"] .group-data-\\[variant\\=floating\\]\\:tw-rounded-lg { + border-radius: var(--radius); +} + +.tw-group[data-variant="floating"] .group-data-\\[variant\\=floating\\]\\:tw-border { + border-width: 1px; +} + +.tw-group[data-side="left"] .group-data-\\[side\\=left\\]\\:tw-border-r { + border-right-width: 1px; +} + +.tw-group[data-side="right"] .group-data-\\[side\\=right\\]\\:tw-border-l { + border-left-width: 1px; +} + +.tw-group[data-variant="floating"] .group-data-\\[variant\\=floating\\]\\:tw-border-sidebar-border { + border-color: hsl(var(--sidebar-border)); +} + +.tw-group[data-collapsible="icon"] .group-data-\\[collapsible\\=icon\\]\\:tw-opacity-0 { + opacity: 0; +} + +.tw-group[data-variant="floating"] .group-data-\\[variant\\=floating\\]\\:tw-shadow { + --tw-shadow: 0 1px 3px 0 rgb(0 0 0 / 0.1), 0 1px 2px -1px rgb(0 0 0 / 0.1); + --tw-shadow-colored: 0 1px 3px 0 var(--tw-shadow-color), 0 1px 2px -1px var(--tw-shadow-color); + box-shadow: var(--tw-ring-offset-shadow, 0 0 #0000), var(--tw-ring-shadow, 0 0 #0000), var(--tw-shadow); +} + +.tw-group[data-collapsible="offcanvas"] .group-data-\\[collapsible\\=offcanvas\\]\\:after\\:tw-left-full::after { + content: var(--tw-content); + left: 100%; +} + +.tw-group[data-collapsible="offcanvas"] .group-data-\\[collapsible\\=offcanvas\\]\\:hover\\:tw-bg-sidebar:hover { + background-color: hsl(var(--sidebar-background)); +} + +.tw-peer[data-variant="inset"] ~ .peer-data-\\[variant\\=inset\\]\\:tw-min-h-\\[calc\\(100svh-theme\\(spacing\\.4\\)\\)\\] { + min-height: calc(100svh - 1rem); +} + @media (min-width: 640px) { .sm\\:tw-not-sr-only { @@ -2740,6 +3134,10 @@ video:where(.pr-twp,.pr-twp *) { display: none; } + .sm\\:tw-max-w-sm { + max-width: 24rem; + } + .sm\\:tw-grid-cols-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); } @@ -2805,6 +3203,10 @@ video:where(.pr-twp,.pr-twp *) { @media (min-width: 768px) { + .md\\:tw-block { + display: block; + } + .md\\:tw-inline { display: inline; } @@ -2845,6 +3247,37 @@ video:where(.pr-twp,.pr-twp *) { font-size: 1rem; line-height: 1.5rem; } + + .md\\:tw-opacity-0 { + opacity: 0; + } + + .after\\:md\\:tw-hidden::after { + content: var(--tw-content); + display: none; + } + + .tw-peer[data-variant="inset"] ~ .md\\:peer-data-\\[variant\\=inset\\]\\:tw-m-2 { + margin: 0.5rem; + } + + .tw-peer[data-state="collapsed"][data-variant="inset"] ~ .md\\:peer-data-\\[state\\=collapsed\\]\\:peer-data-\\[variant\\=inset\\]\\:tw-ml-2 { + margin-left: 0.5rem; + } + + .tw-peer[data-variant="inset"] ~ .md\\:peer-data-\\[variant\\=inset\\]\\:tw-ml-0 { + margin-left: 0px; + } + + .tw-peer[data-variant="inset"] ~ .md\\:peer-data-\\[variant\\=inset\\]\\:tw-rounded-xl { + border-radius: 0.75rem; + } + + .tw-peer[data-variant="inset"] ~ .md\\:peer-data-\\[variant\\=inset\\]\\:tw-shadow { + --tw-shadow: 0 1px 3px 0 rgb(0 0 0 / 0.1), 0 1px 2px -1px rgb(0 0 0 / 0.1); + --tw-shadow-colored: 0 1px 3px 0 var(--tw-shadow-color), 0 1px 2px -1px var(--tw-shadow-color); + box-shadow: var(--tw-ring-offset-shadow, 0 0 #0000), var(--tw-ring-shadow, 0 0 #0000), var(--tw-shadow); + } } @media (min-width: 1024px) { @@ -2947,6 +3380,16 @@ video:where(.pr-twp,.pr-twp *) { padding-inline-end: 0px; } +.\\[\\&\\>button\\]\\:tw-hidden>button { + display: none; +} + +.\\[\\&\\>span\\:last-child\\]\\:tw-truncate>span:last-child { + overflow: hidden; + text-overflow: ellipsis; + white-space: nowrap; +} + .\\[\\&\\>span\\]\\:tw-line-clamp-1>span { overflow: hidden; display: -webkit-box; @@ -2971,6 +3414,15 @@ video:where(.pr-twp,.pr-twp *) { top: 1rem; } +.\\[\\&\\>svg\\]\\:tw-size-4>svg { + width: 1rem; + height: 1rem; +} + +.\\[\\&\\>svg\\]\\:tw-shrink-0>svg { + flex-shrink: 0; +} + .\\[\\&\\>svg\\]\\:tw-text-destructive>svg { color: hsl(var(--destructive)); } @@ -2979,6 +3431,10 @@ video:where(.pr-twp,.pr-twp *) { color: hsl(var(--foreground)); } +.\\[\\&\\>svg\\]\\:tw-text-sidebar-accent-foreground>svg { + color: hsl(var(--sidebar-accent-foreground)); +} + .\\[\\&\\>svg\\~\\*\\]\\:tw-pl-7>svg~* { padding-left: 1.75rem; } @@ -3060,6 +3516,37 @@ video:where(.pr-twp,.pr-twp *) { .\\[\\&_tr\\]\\:tw-border-b tr { border-bottom-width: 1px; } + +[data-side=left][data-collapsible=offcanvas] .\\[\\[data-side\\=left\\]\\[data-collapsible\\=offcanvas\\]_\\&\\]\\:tw--right-2 { + right: -0.5rem; +} + +[data-side=left][data-state=collapsed] .\\[\\[data-side\\=left\\]\\[data-state\\=collapsed\\]_\\&\\]\\:tw-cursor-e-resize { + cursor: e-resize; +} + +[data-side=left] .\\[\\[data-side\\=left\\]_\\&\\]\\:tw-cursor-w-resize { + cursor: w-resize; +} + +[data-side=right][data-collapsible=offcanvas] .\\[\\[data-side\\=right\\]\\[data-collapsible\\=offcanvas\\]_\\&\\]\\:tw--left-2 { + left: -0.5rem; +} + +[data-side=right][data-state=collapsed] .\\[\\[data-side\\=right\\]\\[data-state\\=collapsed\\]_\\&\\]\\:tw-cursor-w-resize { + cursor: w-resize; +} + +[data-side=right] .\\[\\[data-side\\=right\\]_\\&\\]\\:tw-cursor-e-resize { + cursor: e-resize; +} +.banded-row:hover { + cursor: pointer; +} + +.banded-row[data-state='selected']:hover { + cursor: default; +} .papi-multi-column-menu { background-color: rgb(222, 222, 222); display: flex; @@ -3133,13 +3620,6 @@ video:where(.pr-twp,.pr-twp *) { max-width: 24px; max-height: 24px; } -.banded-row:hover { - cursor: pointer; -} - -.banded-row[data-state='selected']:hover { - cursor: default; -} .papi-menu-drawer-paper { height: fit-content !important; position: absolute !important; diff --git a/lib/platform-bible-react/dist/index.cjs.map b/lib/platform-bible-react/dist/index.cjs.map index fee52d5ada..d7fc7fa0ed 100644 --- a/lib/platform-bible-react/dist/index.cjs.map +++ b/lib/platform-bible-react/dist/index.cjs.map @@ -1 +1 @@ -{"version":3,"file":"index.cjs","sources":["../src/utils/shadcn-ui.util.ts","../src/components/shadcn-ui/input.tsx","../src/components/advanced/book-chapter-control/book-chapter-input.component.tsx","../../../node_modules/@sillsdev/scripture/dist/index.es.js","../src/components/shadcn-ui/dropdown-menu.tsx","../src/components/advanced/book-chapter-control/book-menu-item.component.tsx","../src/components/advanced/book-chapter-control/chapter-select.component.tsx","../src/components/advanced/book-chapter-control/go-to-menu-item.component.tsx","../src/components/advanced/book-chapter-control/book-chapter-control.component.tsx","../src/components/shadcn-ui/button.tsx","../src/components/shadcn-ui/label.tsx","../src/components/shadcn-ui/radio-group.tsx","../src/components/shadcn-ui/popover.tsx","../src/components/shadcn-ui/dialog.tsx","../src/components/shadcn-ui/command.tsx","../src/components/basics/combo-box.component.tsx","../src/components/basics/chapter-range-selector.component.tsx","../src/components/advanced/book-selector.component.tsx","../src/components/advanced/data-table/data-table-column-toggle.component.tsx","../src/components/shadcn-ui/select.tsx","../src/components/advanced/data-table/data-table-pagination.component.tsx","../src/components/shadcn-ui/table.tsx","../src/components/advanced/data-table/data-table.component.tsx","../src/components/advanced/inventory/occurrences-table.component.tsx","../src/components/shadcn-ui/checkbox.tsx","../src/components/advanced/inventory/inventory-utils.ts","../src/components/shadcn-ui/toggle.tsx","../src/components/shadcn-ui/toggle-group.tsx","../src/components/advanced/inventory/inventory-columns.tsx","../src/components/advanced/inventory/inventory.component.tsx","../src/components/basics/search-bar.component.tsx","../src/components/basics/tabs-vertical.tsx","../src/components/advanced/navigation-content-search.component.tsx","../src/components/advanced/scripture-results-viewer/scripture-results-viewer.component.tsx","../src/components/advanced/scroll-group-selector.component.tsx","../src/components/shadcn-ui/separator.tsx","../src/components/advanced/settings-components/settings-list.component.tsx","../src/components/basics/checklist.component.tsx","../../../node_modules/@babel/runtime/helpers/interopRequireDefault.js","../../../node_modules/@mui/utils/chainPropTypes/chainPropTypes.js","../../../node_modules/@babel/runtime/helpers/esm/extends.js","../../../node_modules/@mui/utils/deepmerge/deepmerge.js","../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.production.min.js","../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.development.js","../../../node_modules/prop-types/node_modules/react-is/index.js","../../../node_modules/object-assign/index.js","../../../node_modules/prop-types/lib/ReactPropTypesSecret.js","../../../node_modules/prop-types/lib/has.js","../../../node_modules/prop-types/checkPropTypes.js","../../../node_modules/prop-types/factoryWithTypeCheckers.js","../../../node_modules/prop-types/factoryWithThrowingShims.js","../../../node_modules/prop-types/index.js","../../../node_modules/@mui/utils/elementAcceptingRef/elementAcceptingRef.js","../../../node_modules/@mui/utils/exactProp/exactProp.js","../../../node_modules/@mui/utils/formatMuiErrorMessage/formatMuiErrorMessage.js","../../../node_modules/react-is/cjs/react-is.production.min.js","../../../node_modules/react-is/cjs/react-is.development.js","../../../node_modules/react-is/index.js","../../../node_modules/@mui/utils/getDisplayName/getDisplayName.js","../../../node_modules/@mui/utils/HTMLElementType/HTMLElementType.js","../../../node_modules/@mui/utils/refType/refType.js","../../../node_modules/@mui/utils/capitalize/capitalize.js","../../../node_modules/@mui/utils/createChainedFunction/createChainedFunction.js","../../../node_modules/@mui/utils/debounce/debounce.js","../../../node_modules/@mui/utils/deprecatedPropType/deprecatedPropType.js","../../../node_modules/@mui/utils/isMuiElement/isMuiElement.js","../../../node_modules/@mui/utils/ownerDocument/ownerDocument.js","../../../node_modules/@mui/utils/ownerWindow/ownerWindow.js","../../../node_modules/@mui/utils/requirePropFactory/requirePropFactory.js","../../../node_modules/@mui/utils/setRef/setRef.js","../../../node_modules/@mui/utils/useEnhancedEffect/useEnhancedEffect.js","../../../node_modules/@mui/utils/useId/useId.js","../../../node_modules/@mui/utils/unsupportedProp/unsupportedProp.js","../../../node_modules/@mui/utils/useControlled/useControlled.js","../../../node_modules/@mui/utils/useEventCallback/useEventCallback.js","../../../node_modules/@mui/utils/useForkRef/useForkRef.js","../../../node_modules/@mui/utils/useLazyRef/useLazyRef.js","../../../node_modules/@mui/utils/useOnMount/useOnMount.js","../../../node_modules/@mui/utils/useTimeout/useTimeout.js","../../../node_modules/@mui/utils/useIsFocusVisible/useIsFocusVisible.js","../../../node_modules/@mui/utils/resolveProps/resolveProps.js","../../../node_modules/@mui/utils/composeClasses/composeClasses.js","../../../node_modules/@mui/utils/ClassNameGenerator/ClassNameGenerator.js","../../../node_modules/@mui/utils/generateUtilityClass/generateUtilityClass.js","../../../node_modules/@mui/utils/generateUtilityClasses/generateUtilityClasses.js","../../../node_modules/@mui/utils/clamp/clamp.js","../../../node_modules/@babel/runtime/helpers/esm/objectWithoutPropertiesLoose.js","../../../node_modules/@mui/system/esm/createTheme/createBreakpoints.js","../../../node_modules/@mui/system/esm/createTheme/shape.js","../../../node_modules/@mui/system/esm/responsivePropType.js","../../../node_modules/@mui/system/esm/merge.js","../../../node_modules/@mui/system/esm/breakpoints.js","../../../node_modules/@mui/system/esm/style.js","../../../node_modules/@mui/system/esm/memoize.js","../../../node_modules/@mui/system/esm/spacing.js","../../../node_modules/@mui/system/esm/createTheme/createSpacing.js","../../../node_modules/@mui/system/esm/compose.js","../../../node_modules/@mui/system/esm/borders.js","../../../node_modules/@mui/system/esm/cssGrid.js","../../../node_modules/@mui/system/esm/palette.js","../../../node_modules/@mui/system/esm/sizing.js","../../../node_modules/@mui/system/esm/styleFunctionSx/defaultSxConfig.js","../../../node_modules/@mui/system/esm/styleFunctionSx/styleFunctionSx.js","../../../node_modules/@mui/system/esm/createTheme/applyStyles.js","../../../node_modules/@mui/system/esm/createTheme/createTheme.js","../../../node_modules/@mui/system/esm/useThemeWithoutDefault.js","../../../node_modules/@mui/system/esm/useTheme.js","../../../node_modules/@mui/system/esm/createStyled.js","../../../node_modules/@mui/system/esm/useThemeProps/getThemeProps.js","../../../node_modules/@mui/system/esm/useThemeProps/useThemeProps.js","../../../node_modules/@mui/system/esm/colorManipulator.js","../../../node_modules/@mui/material/styles/createMixins.js","../../../node_modules/@mui/material/colors/common.js","../../../node_modules/@mui/material/colors/grey.js","../../../node_modules/@mui/material/colors/purple.js","../../../node_modules/@mui/material/colors/red.js","../../../node_modules/@mui/material/colors/orange.js","../../../node_modules/@mui/material/colors/blue.js","../../../node_modules/@mui/material/colors/lightBlue.js","../../../node_modules/@mui/material/colors/green.js","../../../node_modules/@mui/material/styles/createPalette.js","../../../node_modules/@mui/material/styles/createTypography.js","../../../node_modules/@mui/material/styles/shadows.js","../../../node_modules/@mui/material/styles/createTransitions.js","../../../node_modules/@mui/material/styles/zIndex.js","../../../node_modules/@mui/material/styles/createTheme.js","../../../node_modules/@mui/material/styles/defaultTheme.js","../../../node_modules/@mui/material/styles/identifier.js","../../../node_modules/@mui/material/styles/useThemeProps.js","../../../node_modules/@mui/material/styles/styled.js","../../../node_modules/@mui/material/SvgIcon/svgIconClasses.js","../../../node_modules/@mui/material/SvgIcon/SvgIcon.js","../../../node_modules/@mui/material/utils/createSvgIcon.js","../../../node_modules/@mui/material/utils/index.js","../../../node_modules/@mui/icons-material/utils/createSvgIcon.js","../../../node_modules/@mui/icons-material/ArrowRight.js","../../../node_modules/@mui/base/utils/isHostComponent.js","../../../node_modules/@mui/base/utils/appendOwnerState.js","../../../node_modules/@mui/base/utils/ClassNameConfigurator.js","../../../node_modules/@mui/base/utils/extractEventHandlers.js","../../../node_modules/@mui/base/utils/resolveComponentProps.js","../../../node_modules/@mui/base/utils/omitEventHandlers.js","../../../node_modules/@mui/base/utils/mergeSlotProps.js","../../../node_modules/@mui/base/utils/useSlotProps.js","../../../node_modules/@mui/base/generateUtilityClass/index.js","../../../node_modules/@mui/base/generateUtilityClasses/index.js","../../../node_modules/@mui/base/Portal/Portal.js","../../../node_modules/@popperjs/core/lib/enums.js","../../../node_modules/@popperjs/core/lib/dom-utils/getNodeName.js","../../../node_modules/@popperjs/core/lib/dom-utils/getWindow.js","../../../node_modules/@popperjs/core/lib/dom-utils/instanceOf.js","../../../node_modules/@popperjs/core/lib/modifiers/applyStyles.js","../../../node_modules/@popperjs/core/lib/utils/getBasePlacement.js","../../../node_modules/@popperjs/core/lib/utils/math.js","../../../node_modules/@popperjs/core/lib/utils/userAgent.js","../../../node_modules/@popperjs/core/lib/dom-utils/isLayoutViewport.js","../../../node_modules/@popperjs/core/lib/dom-utils/getBoundingClientRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/getLayoutRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/contains.js","../../../node_modules/@popperjs/core/lib/dom-utils/getComputedStyle.js","../../../node_modules/@popperjs/core/lib/dom-utils/isTableElement.js","../../../node_modules/@popperjs/core/lib/dom-utils/getDocumentElement.js","../../../node_modules/@popperjs/core/lib/dom-utils/getParentNode.js","../../../node_modules/@popperjs/core/lib/dom-utils/getOffsetParent.js","../../../node_modules/@popperjs/core/lib/utils/getMainAxisFromPlacement.js","../../../node_modules/@popperjs/core/lib/utils/within.js","../../../node_modules/@popperjs/core/lib/utils/getFreshSideObject.js","../../../node_modules/@popperjs/core/lib/utils/mergePaddingObject.js","../../../node_modules/@popperjs/core/lib/utils/expandToHashMap.js","../../../node_modules/@popperjs/core/lib/modifiers/arrow.js","../../../node_modules/@popperjs/core/lib/utils/getVariation.js","../../../node_modules/@popperjs/core/lib/modifiers/computeStyles.js","../../../node_modules/@popperjs/core/lib/modifiers/eventListeners.js","../../../node_modules/@popperjs/core/lib/utils/getOppositePlacement.js","../../../node_modules/@popperjs/core/lib/utils/getOppositeVariationPlacement.js","../../../node_modules/@popperjs/core/lib/dom-utils/getWindowScroll.js","../../../node_modules/@popperjs/core/lib/dom-utils/getWindowScrollBarX.js","../../../node_modules/@popperjs/core/lib/dom-utils/getViewportRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/getDocumentRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/isScrollParent.js","../../../node_modules/@popperjs/core/lib/dom-utils/getScrollParent.js","../../../node_modules/@popperjs/core/lib/dom-utils/listScrollParents.js","../../../node_modules/@popperjs/core/lib/utils/rectToClientRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/getClippingRect.js","../../../node_modules/@popperjs/core/lib/utils/computeOffsets.js","../../../node_modules/@popperjs/core/lib/utils/detectOverflow.js","../../../node_modules/@popperjs/core/lib/utils/computeAutoPlacement.js","../../../node_modules/@popperjs/core/lib/modifiers/flip.js","../../../node_modules/@popperjs/core/lib/modifiers/hide.js","../../../node_modules/@popperjs/core/lib/modifiers/offset.js","../../../node_modules/@popperjs/core/lib/modifiers/popperOffsets.js","../../../node_modules/@popperjs/core/lib/utils/getAltAxis.js","../../../node_modules/@popperjs/core/lib/modifiers/preventOverflow.js","../../../node_modules/@popperjs/core/lib/dom-utils/getHTMLElementScroll.js","../../../node_modules/@popperjs/core/lib/dom-utils/getNodeScroll.js","../../../node_modules/@popperjs/core/lib/dom-utils/getCompositeRect.js","../../../node_modules/@popperjs/core/lib/utils/orderModifiers.js","../../../node_modules/@popperjs/core/lib/utils/debounce.js","../../../node_modules/@popperjs/core/lib/utils/mergeByName.js","../../../node_modules/@popperjs/core/lib/createPopper.js","../../../node_modules/@popperjs/core/lib/popper.js","../../../node_modules/@mui/base/Popper/popperClasses.js","../../../node_modules/@mui/base/Popper/Popper.js","../../../node_modules/@mui/material/styles/useTheme.js","../../../node_modules/@babel/runtime/helpers/esm/setPrototypeOf.js","../../../node_modules/@babel/runtime/helpers/esm/inheritsLoose.js","../../../node_modules/react-transition-group/esm/config.js","../../../node_modules/react-transition-group/esm/utils/PropTypes.js","../../../node_modules/react-transition-group/esm/TransitionGroupContext.js","../../../node_modules/react-transition-group/esm/utils/reflow.js","../../../node_modules/react-transition-group/esm/Transition.js","../../../node_modules/@mui/material/transitions/utils.js","../../../node_modules/@mui/material/Grow/Grow.js","../../../node_modules/@mui/material/Popper/Popper.js","../../../node_modules/@mui/material/Tooltip/tooltipClasses.js","../../../node_modules/@mui/material/Tooltip/Tooltip.js","../src/components/mui/menu-item.component.tsx","../src/components/mui/grouped-menu-item-list.component.tsx","../src/components/mui/top-level-menu.component.tsx","../src/components/mui/grid-menu.component.tsx","../src/hooks/use-promise.hook.ts","../../../node_modules/@mui/icons-material/esm/Menu.js","../src/components/mui/hamburger-menu-button.component.tsx","../src/components/mui/icon-button.component.tsx","../src/components/basics/spinner.component.tsx","../src/components/basics/text-field.component.tsx","../src/components/mui/toolbar.component.tsx","../src/components/shadcn-ui/alert.tsx","../src/components/shadcn-ui/card.tsx","../src/components/shadcn-ui/sonner.tsx","../src/components/shadcn-ui/slider.tsx","../src/components/shadcn-ui/switch.tsx","../src/components/shadcn-ui/tabs.tsx","../src/components/advanced/extension-marketplace/buttons/install-button.component.tsx","../src/components/advanced/extension-marketplace/buttons/enable-button.component.tsx","../src/components/advanced/extension-marketplace/buttons/disable-button.component.tsx","../src/components/advanced/extension-marketplace/buttons/update-button.component.tsx","../src/components/advanced/extension-marketplace/markdown-renderer.component.tsx","../src/components/advanced/extension-marketplace/buttons/filter-button.component.tsx","../src/components/advanced/extension-marketplace/filter-dropdown.component.tsx","../src/components/advanced/extension-marketplace/no-extensions-found.component.tsx","../src/components/advanced/extension-marketplace/more-info.component.tsx","../src/components/advanced/extension-marketplace/version-history.component.tsx","../src/components/advanced/extension-marketplace/footer.component.tsx","../src/hooks/use-event.hook.ts","../src/hooks/use-event-async.hook.ts"],"sourcesContent":["import { type ClassValue, clsx } from 'clsx';\nimport { extendTailwindMerge } from 'tailwind-merge';\n\nconst twMergeCustom = extendTailwindMerge({ prefix: 'tw-' });\n\n/**\n * Tailwind and CSS class application helper function. Uses\n * [`clsx`](https://www.npmjs.com/package/clsx) to make it easy to apply classes conditionally using\n * object syntax, and uses [`tailwind-merge`](https://www.npmjs.com/package/tailwind-merge) to make\n * it easy to merge/overwrite Tailwind classes in a programmer-logic-friendly way.\n *\n * Note: `tailwind-merge` is configured to use the prefix `tw-`, so you must use the same prefix\n * with any Tailwind classes you use with this function to successfully overwrite other Tailwind\n * classes. `platform-bible-react` is configured to use `tw-` as its Tailwind prefix, so any\n * Tailwind classes you pass into `platform-bible-react` components will be compared using the `tw-`\n * prefix.\n *\n * This function was popularized by\n * [shadcn/ui](https://ui.shadcn.com/docs/installation/manual#add-a-cn-helper). See [ByteGrad's\n * explanation video](https://www.youtube.com/watch?v=re2JFITR7TI) for more information.\n *\n * @example\n *\n * ```typescript\n * const borderShouldBeBlue = true;\n * const textShouldBeRed = true;\n * const heightShouldBe20 = false;\n * const classString = cn(\n * 'tw-bg-primary tw-h-10 tw-text-primary-foreground',\n * 'tw-bg-secondary',\n * {\n * 'tw-border-blue-500': borderShouldBeBlue,\n * 'tw-text-red-500': textShouldBeRed,\n * 'tw-h-20': heightShouldBe20,\n * },\n * 'some-class',\n * );\n * ```\n *\n * The resulting `classString` is `'tw-h-10 tw-bg-secondary tw-border-blue-500 tw-text-red-500\n * some-class'`\n *\n * - Notice that `'tw-bg-secondary'`, specified later, overwrote `'tw-bg-primary'`, specified earlier,\n * because they are Tailwind classes that affect the same css property\n * - Notice that `'tw-text-red-500'`, specified later, overwrote `'tw-text-primary-foreground'`,\n * specified earlier, because they are Tailwind classes that affect the same css property\n * - Notice that `'tw-h-20'`, specified later, did not overwrite `'tw-h-10'`, specified earlier,\n * because `'tw-h-20'` is part of a conditional class object and its value evaluated to `false`;\n * therefore it was not applied\n * - Notice that `'some-class'` was applied. This function is not limited only to Tailwind classes.\n *\n *\n * @param inputs Class strings or `clsx` conditional class objects to merge. Tailwind classes\n * specified later in the arguments overwrite similar Tailwind classes specified earlier in the\n * arguments\n * @returns Class string containing all applicable classes from the arguments based on the rules\n * described above\n */\n// shadcn/ui uses this export in its boilerplate code\n// eslint-disable-next-line import/prefer-default-export\nexport function cn(...inputs: ClassValue[]) {\n return twMergeCustom(clsx(inputs));\n}\n","import React from 'react';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport interface InputProps extends React.InputHTMLAttributes {}\n\nexport const Input = React.forwardRef(\n ({ className, type, ...props }, ref) => {\n return (\n \n );\n },\n);\nInput.displayName = 'Input';\n","import { FocusEventHandler, forwardRef, KeyboardEvent, MouseEventHandler } from 'react';\nimport { History } from 'lucide-react';\nimport { Input as ShadInput } from '@/components/shadcn-ui/input';\n\nexport type BookChapterInputProps = {\n handleSearch: (searchString: string) => void;\n handleKeyDown: (event: KeyboardEvent) => void;\n handleOnClick: MouseEventHandler;\n handleSubmit: () => void;\n onFocus?: FocusEventHandler;\n value: string;\n placeholder: string;\n};\n\n// Shadcn Input sets type to \"button\"- HAVE to prop spread before setting type\nconst BookChapterInput = forwardRef(\n (\n { handleSearch, handleKeyDown, handleOnClick, handleSubmit, ...props }: BookChapterInputProps,\n ref,\n ) => {\n return (\n
\n handleSearch(event.target.value)}\n onKeyDown={(e) => {\n if (e.key === 'Enter') {\n handleSubmit();\n }\n handleKeyDown(e);\n }}\n onClick={handleOnClick}\n ref={ref}\n />\n {\n // eslint-disable-next-line no-console\n console.log('back in history');\n }}\n />\n
\n );\n },\n);\n\nexport default BookChapterInput;\n","var P = Object.defineProperty;\nvar R = (t, e, s) => e in t ? P(t, e, { enumerable: !0, configurable: !0, writable: !0, value: s }) : t[e] = s;\nvar n = (t, e, s) => R(t, typeof e != \"symbol\" ? e + \"\" : e, s);\nclass _ {\n constructor() {\n n(this, \"books\");\n n(this, \"firstSelectedBookNum\");\n n(this, \"lastSelectedBookNum\");\n n(this, \"count\");\n n(this, \"selectedBookNumbers\");\n n(this, \"selectedBookIds\");\n }\n}\nconst N = [\n \"GEN\",\n \"EXO\",\n \"LEV\",\n \"NUM\",\n \"DEU\",\n \"JOS\",\n \"JDG\",\n \"RUT\",\n \"1SA\",\n \"2SA\",\n // 10\n \"1KI\",\n \"2KI\",\n \"1CH\",\n \"2CH\",\n \"EZR\",\n \"NEH\",\n \"EST\",\n \"JOB\",\n \"PSA\",\n \"PRO\",\n // 20\n \"ECC\",\n \"SNG\",\n \"ISA\",\n \"JER\",\n \"LAM\",\n \"EZK\",\n \"DAN\",\n \"HOS\",\n \"JOL\",\n \"AMO\",\n // 30\n \"OBA\",\n \"JON\",\n \"MIC\",\n \"NAM\",\n \"HAB\",\n \"ZEP\",\n \"HAG\",\n \"ZEC\",\n \"MAL\",\n \"MAT\",\n // 40\n \"MRK\",\n \"LUK\",\n \"JHN\",\n \"ACT\",\n \"ROM\",\n \"1CO\",\n \"2CO\",\n \"GAL\",\n \"EPH\",\n \"PHP\",\n // 50\n \"COL\",\n \"1TH\",\n \"2TH\",\n \"1TI\",\n \"2TI\",\n \"TIT\",\n \"PHM\",\n \"HEB\",\n \"JAS\",\n \"1PE\",\n // 60\n \"2PE\",\n \"1JN\",\n \"2JN\",\n \"3JN\",\n \"JUD\",\n \"REV\",\n \"TOB\",\n \"JDT\",\n \"ESG\",\n \"WIS\",\n // 70\n \"SIR\",\n \"BAR\",\n \"LJE\",\n \"S3Y\",\n \"SUS\",\n \"BEL\",\n \"1MA\",\n \"2MA\",\n \"3MA\",\n \"4MA\",\n // 80\n \"1ES\",\n \"2ES\",\n \"MAN\",\n \"PS2\",\n \"ODA\",\n \"PSS\",\n \"JSA\",\n // actual variant text for JOS, now in LXA text\n \"JDB\",\n // actual variant text for JDG, now in LXA text\n \"TBS\",\n // actual variant text for TOB, now in LXA text\n \"SST\",\n // actual variant text for SUS, now in LXA text // 90\n \"DNT\",\n // actual variant text for DAN, now in LXA text\n \"BLT\",\n // actual variant text for BEL, now in LXA text\n \"XXA\",\n \"XXB\",\n \"XXC\",\n \"XXD\",\n \"XXE\",\n \"XXF\",\n \"XXG\",\n \"FRT\",\n // 100\n \"BAK\",\n \"OTH\",\n \"3ES\",\n // Used previously but really should be 2ES\n \"EZA\",\n // Used to be called 4ES, but not actually in any known project\n \"5EZ\",\n // Used to be called 5ES, but not actually in any known project\n \"6EZ\",\n // Used to be called 6ES, but not actually in any known project\n \"INT\",\n \"CNC\",\n \"GLO\",\n \"TDX\",\n // 110\n \"NDX\",\n \"DAG\",\n \"PS3\",\n \"2BA\",\n \"LBA\",\n \"JUB\",\n \"ENO\",\n \"1MQ\",\n \"2MQ\",\n \"3MQ\",\n // 120\n \"REP\",\n \"4BA\",\n \"LAO\"\n], B = [\n \"XXA\",\n \"XXB\",\n \"XXC\",\n \"XXD\",\n \"XXE\",\n \"XXF\",\n \"XXG\",\n \"FRT\",\n \"BAK\",\n \"OTH\",\n \"INT\",\n \"CNC\",\n \"GLO\",\n \"TDX\",\n \"NDX\"\n], O = [\n \"Genesis\",\n \"Exodus\",\n \"Leviticus\",\n \"Numbers\",\n \"Deuteronomy\",\n \"Joshua\",\n \"Judges\",\n \"Ruth\",\n \"1 Samuel\",\n \"2 Samuel\",\n \"1 Kings\",\n \"2 Kings\",\n \"1 Chronicles\",\n \"2 Chronicles\",\n \"Ezra\",\n \"Nehemiah\",\n \"Esther (Hebrew)\",\n \"Job\",\n \"Psalms\",\n \"Proverbs\",\n \"Ecclesiastes\",\n \"Song of Songs\",\n \"Isaiah\",\n \"Jeremiah\",\n \"Lamentations\",\n \"Ezekiel\",\n \"Daniel (Hebrew)\",\n \"Hosea\",\n \"Joel\",\n \"Amos\",\n \"Obadiah\",\n \"Jonah\",\n \"Micah\",\n \"Nahum\",\n \"Habakkuk\",\n \"Zephaniah\",\n \"Haggai\",\n \"Zechariah\",\n \"Malachi\",\n \"Matthew\",\n \"Mark\",\n \"Luke\",\n \"John\",\n \"Acts\",\n \"Romans\",\n \"1 Corinthians\",\n \"2 Corinthians\",\n \"Galatians\",\n \"Ephesians\",\n \"Philippians\",\n \"Colossians\",\n \"1 Thessalonians\",\n \"2 Thessalonians\",\n \"1 Timothy\",\n \"2 Timothy\",\n \"Titus\",\n \"Philemon\",\n \"Hebrews\",\n \"James\",\n \"1 Peter\",\n \"2 Peter\",\n \"1 John\",\n \"2 John\",\n \"3 John\",\n \"Jude\",\n \"Revelation\",\n \"Tobit\",\n \"Judith\",\n \"Esther Greek\",\n \"Wisdom of Solomon\",\n \"Sirach (Ecclesiasticus)\",\n \"Baruch\",\n \"Letter of Jeremiah\",\n \"Song of 3 Young Men\",\n \"Susanna\",\n \"Bel and the Dragon\",\n \"1 Maccabees\",\n \"2 Maccabees\",\n \"3 Maccabees\",\n \"4 Maccabees\",\n \"1 Esdras (Greek)\",\n \"2 Esdras (Latin)\",\n \"Prayer of Manasseh\",\n \"Psalm 151\",\n \"Odes\",\n \"Psalms of Solomon\",\n // WARNING, if you change the spelling of the *obsolete* tag be sure to update\n // IsObsolete routine\n \"Joshua A. *obsolete*\",\n \"Judges B. *obsolete*\",\n \"Tobit S. *obsolete*\",\n \"Susanna Th. *obsolete*\",\n \"Daniel Th. *obsolete*\",\n \"Bel Th. *obsolete*\",\n \"Extra A\",\n \"Extra B\",\n \"Extra C\",\n \"Extra D\",\n \"Extra E\",\n \"Extra F\",\n \"Extra G\",\n \"Front Matter\",\n \"Back Matter\",\n \"Other Matter\",\n \"3 Ezra *obsolete*\",\n \"Apocalypse of Ezra\",\n \"5 Ezra (Latin Prologue)\",\n \"6 Ezra (Latin Epilogue)\",\n \"Introduction\",\n \"Concordance \",\n \"Glossary \",\n \"Topical Index\",\n \"Names Index\",\n \"Daniel Greek\",\n \"Psalms 152-155\",\n \"2 Baruch (Apocalypse)\",\n \"Letter of Baruch\",\n \"Jubilees\",\n \"Enoch\",\n \"1 Meqabyan\",\n \"2 Meqabyan\",\n \"3 Meqabyan\",\n \"Reproof (Proverbs 25-31)\",\n \"4 Baruch (Rest of Baruch)\",\n \"Laodiceans\"\n], S = K();\nfunction g(t, e = !0) {\n return e && (t = t.toUpperCase()), t in S ? S[t] : 0;\n}\nfunction k(t) {\n return g(t) > 0;\n}\nfunction x(t) {\n const e = typeof t == \"string\" ? g(t) : t;\n return e >= 40 && e <= 66;\n}\nfunction T(t) {\n return (typeof t == \"string\" ? g(t) : t) <= 39;\n}\nfunction X(t) {\n return t <= 66;\n}\nfunction V(t) {\n const e = typeof t == \"string\" ? g(t) : t;\n return w(e) && !X(e);\n}\nfunction* L() {\n for (let t = 1; t <= N.length; t++) yield t;\n}\nconst G = 1, A = N.length;\nfunction H() {\n return [\"XXA\", \"XXB\", \"XXC\", \"XXD\", \"XXE\", \"XXF\", \"XXG\"];\n}\nfunction C(t, e = \"***\") {\n const s = t - 1;\n return s < 0 || s >= N.length ? e : N[s];\n}\nfunction I(t) {\n return t <= 0 || t > A ? \"******\" : O[t - 1];\n}\nfunction y(t) {\n return I(g(t));\n}\nfunction w(t) {\n const e = typeof t == \"number\" ? C(t) : t;\n return k(e) && !B.includes(e);\n}\nfunction q(t) {\n const e = typeof t == \"number\" ? C(t) : t;\n return k(e) && B.includes(e);\n}\nfunction U(t) {\n return O[t - 1].includes(\"*obsolete*\");\n}\nfunction K() {\n const t = {};\n for (let e = 0; e < N.length; e++)\n t[N[e]] = e + 1;\n return t;\n}\nconst m = {\n allBookIds: N,\n nonCanonicalIds: B,\n bookIdToNumber: g,\n isBookIdValid: k,\n isBookNT: x,\n isBookOT: T,\n isBookOTNT: X,\n isBookDC: V,\n allBookNumbers: L,\n firstBook: G,\n lastBook: A,\n extraBooks: H,\n bookNumberToId: C,\n bookNumberToEnglishName: I,\n bookIdToEnglishName: y,\n isCanonical: w,\n isExtraMaterial: q,\n isObsolete: U\n};\nvar l = /* @__PURE__ */ ((t) => (t[t.Unknown = 0] = \"Unknown\", t[t.Original = 1] = \"Original\", t[t.Septuagint = 2] = \"Septuagint\", t[t.Vulgate = 3] = \"Vulgate\", t[t.English = 4] = \"English\", t[t.RussianProtestant = 5] = \"RussianProtestant\", t[t.RussianOrthodox = 6] = \"RussianOrthodox\", t))(l || {});\nconst h = class h {\n // private versInfo: Versification;\n constructor(e) {\n n(this, \"name\");\n n(this, \"fullPath\");\n n(this, \"isPresent\");\n n(this, \"hasVerseSegments\");\n n(this, \"isCustomized\");\n n(this, \"baseVersification\");\n n(this, \"scriptureBooks\");\n n(this, \"_type\");\n if (e == null)\n throw new Error(\"Argument undefined\");\n typeof e == \"string\" ? (this.name = e, this._type = l[e]) : (this._type = e, this.name = l[e]);\n }\n get type() {\n return this._type;\n }\n equals(e) {\n return !e.type || !this.type ? !1 : e.type === this.type;\n }\n};\nn(h, \"Original\", new h(l.Original)), n(h, \"Septuagint\", new h(l.Septuagint)), n(h, \"Vulgate\", new h(l.Vulgate)), n(h, \"English\", new h(l.English)), n(h, \"RussianProtestant\", new h(l.RussianProtestant)), n(h, \"RussianOrthodox\", new h(l.RussianOrthodox));\nlet c = h;\nfunction E(t, e) {\n const s = e[0];\n for (let r = 1; r < e.length; r++)\n t = t.split(e[r]).join(s);\n return t.split(s);\n}\nvar D = /* @__PURE__ */ ((t) => (t[t.Valid = 0] = \"Valid\", t[t.UnknownVersification = 1] = \"UnknownVersification\", t[t.OutOfRange = 2] = \"OutOfRange\", t[t.VerseOutOfOrder = 3] = \"VerseOutOfOrder\", t[t.VerseRepeated = 4] = \"VerseRepeated\", t))(D || {});\nconst i = class i {\n constructor(e, s, r, a) {\n /** Not yet implemented. */\n n(this, \"firstChapter\");\n /** Not yet implemented. */\n n(this, \"lastChapter\");\n /** Not yet implemented. */\n n(this, \"lastVerse\");\n /** Not yet implemented. */\n n(this, \"hasSegmentsDefined\");\n /** Not yet implemented. */\n n(this, \"text\");\n /** Not yet implemented. */\n n(this, \"BBBCCCVVVS\");\n /** Not yet implemented. */\n n(this, \"longHashCode\");\n /** The versification of the reference. */\n n(this, \"versification\");\n n(this, \"rtlMark\", \"‏\");\n n(this, \"_bookNum\", 0);\n n(this, \"_chapterNum\", 0);\n n(this, \"_verseNum\", 0);\n n(this, \"_verse\");\n if (r == null && a == null)\n if (e != null && typeof e == \"string\") {\n const o = e, u = s != null && s instanceof c ? s : void 0;\n this.setEmpty(u), this.parse(o);\n } else if (e != null && typeof e == \"number\") {\n const o = s != null && s instanceof c ? s : void 0;\n this.setEmpty(o), this._verseNum = e % i.chapterDigitShifter, this._chapterNum = Math.floor(\n e % i.bookDigitShifter / i.chapterDigitShifter\n ), this._bookNum = Math.floor(e / i.bookDigitShifter);\n } else if (s == null)\n if (e != null && e instanceof i) {\n const o = e;\n this._bookNum = o.bookNum, this._chapterNum = o.chapterNum, this._verseNum = o.verseNum, this._verse = o.verse, this.versification = o.versification;\n } else {\n if (e == null) return;\n const o = e instanceof c ? e : i.defaultVersification;\n this.setEmpty(o);\n }\n else\n throw new Error(\"VerseRef constructor not supported.\");\n else if (e != null && s != null && r != null)\n if (typeof e == \"string\" && typeof s == \"string\" && typeof r == \"string\")\n this.setEmpty(a), this.updateInternal(e, s, r);\n else if (typeof e == \"number\" && typeof s == \"number\" && typeof r == \"number\")\n this._bookNum = e, this._chapterNum = s, this._verseNum = r, this.versification = a ?? i.defaultVersification;\n else\n throw new Error(\"VerseRef constructor not supported.\");\n else\n throw new Error(\"VerseRef constructor not supported.\");\n }\n /**\n * Determines if the verse string is in a valid format (does not consider versification).\n */\n static isVerseParseable(e) {\n return e.length > 0 && \"0123456789\".includes(e[0]) && !e.endsWith(this.verseRangeSeparator) && !e.endsWith(this.verseSequenceIndicator);\n }\n /**\n * Tries to parse the specified string into a verse reference.\n * @param str - The string to attempt to parse.\n * @returns success: `true` if the specified string was successfully parsed, `false` otherwise.\n * @returns verseRef: The result of the parse if successful, or empty VerseRef if it failed\n */\n static tryParse(e) {\n let s;\n try {\n return s = new i(e), { success: !0, verseRef: s };\n } catch (r) {\n if (r instanceof v)\n return s = new i(), { success: !1, verseRef: s };\n throw r;\n }\n }\n /**\n * Gets the reference as a comparable integer where the book, chapter, and verse each occupy 3\n * digits.\n * @param bookNum - Book number (this is 1-based, not an index).\n * @param chapterNum - Chapter number.\n * @param verseNum - Verse number.\n * @returns The reference as a comparable integer where the book, chapter, and verse each occupy 3\n * digits.\n */\n static getBBBCCCVVV(e, s, r) {\n return e % i.bcvMaxValue * i.bookDigitShifter + (s >= 0 ? s % i.bcvMaxValue * i.chapterDigitShifter : 0) + (r >= 0 ? r % i.bcvMaxValue : 0);\n }\n /**\n * Deserializes a serialized VerseRef.\n * @param serializedVerseRef - Serialized VerseRef to create from.\n * @returns the deserialized VerseRef.\n */\n static fromJSON(e) {\n const { book: s, chapterNum: r, verseNum: a, verse: o, versificationStr: u } = e, f = o || a.toString();\n let d;\n return u && (d = new c(u)), s ? new i(s, r.toString(), f, d) : new i();\n }\n /**\n * Parses a verse string and gets the leading numeric portion as a number.\n * @param verseStr - verse string to parse\n * @returns true if the entire string could be parsed as a single, simple verse number (1-999);\n * false if the verse string represented a verse bridge, contained segment letters, or was invalid\n */\n static tryGetVerseNum(e) {\n let s;\n if (!e)\n return s = -1, { success: !0, vNum: s };\n s = 0;\n let r;\n for (let a = 0; a < e.length; a++) {\n if (r = e[a], r < \"0\" || r > \"9\")\n return a === 0 && (s = -1), { success: !1, vNum: s };\n if (s = s * 10 + +r - 0, s > i.bcvMaxValue)\n return s = -1, { success: !1, vNum: s };\n }\n return { success: !0, vNum: s };\n }\n /**\n * Checks to see if a VerseRef hasn't been set - all values are the default.\n */\n get isDefault() {\n return this.bookNum === 0 && this.chapterNum === 0 && this.verseNum === 0 && this.versification == null;\n }\n /**\n * Gets whether the verse contains multiple verses.\n */\n get hasMultiple() {\n return this._verse != null && (this._verse.includes(i.verseRangeSeparator) || this._verse.includes(i.verseSequenceIndicator));\n }\n /**\n * Gets or sets the book of the reference. Book is the 3-letter abbreviation in capital letters,\n * e.g. `'MAT'`.\n */\n get book() {\n return m.bookNumberToId(this.bookNum, \"\");\n }\n set book(e) {\n this.bookNum = m.bookIdToNumber(e);\n }\n /**\n * Gets or sets the chapter of the reference,. e.g. `'3'`.\n */\n get chapter() {\n return this.isDefault || this._chapterNum < 0 ? \"\" : this._chapterNum.toString();\n }\n set chapter(e) {\n const s = +e;\n this._chapterNum = Number.isInteger(s) ? s : -1;\n }\n /**\n * Gets or sets the verse of the reference, including range, segments, and sequences, e.g. `'4'`,\n * or `'4b-5a, 7'`.\n */\n get verse() {\n return this._verse != null ? this._verse : this.isDefault || this._verseNum < 0 ? \"\" : this._verseNum.toString();\n }\n set verse(e) {\n const { success: s, vNum: r } = i.tryGetVerseNum(e);\n this._verse = s ? void 0 : e.replace(this.rtlMark, \"\"), this._verseNum = r, !(this._verseNum >= 0) && ({ vNum: this._verseNum } = i.tryGetVerseNum(this._verse));\n }\n /**\n * Get or set Book based on book number, e.g. `42`.\n */\n get bookNum() {\n return this._bookNum;\n }\n set bookNum(e) {\n if (e <= 0 || e > m.lastBook)\n throw new v(\n \"BookNum must be greater than zero and less than or equal to last book\"\n );\n this._bookNum = e;\n }\n /**\n * Gets or sets the chapter number, e.g. `3`. `-1` if not valid.\n */\n get chapterNum() {\n return this._chapterNum;\n }\n set chapterNum(e) {\n this.chapterNum = e;\n }\n /**\n * Gets or sets verse start number, e.g. `4`. `-1` if not valid.\n */\n get verseNum() {\n return this._verseNum;\n }\n set verseNum(e) {\n this._verseNum = e;\n }\n /**\n * String representing the versification (should ONLY be used for serialization/deserialization).\n *\n * @remarks This is for backwards compatibility when ScrVers was an enumeration.\n */\n get versificationStr() {\n var e;\n return (e = this.versification) == null ? void 0 : e.name;\n }\n set versificationStr(e) {\n this.versification = this.versification != null ? new c(e) : void 0;\n }\n /**\n * Determines if the reference is valid.\n */\n get valid() {\n return this.validStatus === 0;\n }\n /**\n * Get the valid status for this reference.\n */\n get validStatus() {\n return this.validateVerse(i.verseRangeSeparators, i.verseSequenceIndicators);\n }\n /**\n * Gets the reference as a comparable integer where the book,\n * chapter, and verse each occupy three digits and the verse is 0.\n */\n get BBBCCC() {\n return i.getBBBCCCVVV(this._bookNum, this._chapterNum, 0);\n }\n /**\n * Gets the reference as a comparable integer where the book,\n * chapter, and verse each occupy three digits. If verse is not null\n * (i.e., this reference represents a complex reference with verse\n * segments or bridge) this cannot be used for an exact comparison.\n */\n get BBBCCCVVV() {\n return i.getBBBCCCVVV(this._bookNum, this._chapterNum, this._verseNum);\n }\n /**\n * Gets whether the verse is defined as an excluded verse in the versification.\n * Does not handle verse ranges.\n */\n // eslint-disable-next-line @typescript-eslint/class-literal-property-style\n get isExcluded() {\n return !1;\n }\n /**\n * Parses the reference in the specified string.\n * Optionally versification can follow reference as in GEN 3:11/4\n * Throw an exception if\n * - invalid book name\n * - chapter number is missing or not a number\n * - verse number is missing or does not start with a number\n * - versification is invalid\n * @param verseStr - string to parse e.g. 'MAT 3:11'\n */\n parse(e) {\n if (e = e.replace(this.rtlMark, \"\"), e.includes(\"/\")) {\n const o = e.split(\"/\");\n if (e = o[0], o.length > 1)\n try {\n const u = +o[1].trim();\n this.versification = new c(l[u]);\n } catch {\n throw new v(\"Invalid reference : \" + e);\n }\n }\n const s = e.trim().split(\" \");\n if (s.length !== 2)\n throw new v(\"Invalid reference : \" + e);\n const r = s[1].split(\":\"), a = +r[0];\n if (r.length !== 2 || m.bookIdToNumber(s[0]) === 0 || !Number.isInteger(a) || a < 0 || !i.isVerseParseable(r[1]))\n throw new v(\"Invalid reference : \" + e);\n this.updateInternal(s[0], r[0], r[1]);\n }\n /**\n * Simplifies this verse ref so that it has no bridging of verses or\n * verse segments like `'1a'`.\n */\n simplify() {\n this._verse = void 0;\n }\n /**\n * Makes a clone of the reference.\n *\n * @returns The cloned VerseRef.\n */\n clone() {\n return new i(this);\n }\n toString() {\n const e = this.book;\n return e === \"\" ? \"\" : `${e} ${this.chapter}:${this.verse}`;\n }\n toJSON() {\n let e = this.verse;\n (e === \"\" || e === this.verseNum.toString()) && (e = void 0);\n const s = {\n book: this.book,\n chapterNum: this.chapterNum,\n verseNum: this.verseNum,\n verse: e,\n versificationStr: this.versificationStr\n };\n return e || delete s.verse, s;\n }\n /**\n * Compares this `VerseRef` with supplied one.\n * @param verseRef - object to compare this one to.\n * @returns `true` if this `VerseRef` is equal to the supplied one, `false` otherwise.\n */\n equals(e) {\n return e instanceof i ? e._bookNum === this._bookNum && e._chapterNum === this._chapterNum && e._verseNum === this._verseNum && e.verse === this.verse && (e.versification == null && this.versification == null || e.versification != null && this.versification != null && e.versification.equals(this.versification)) : !1;\n }\n /**\n * Enumerate all individual verses contained in a VerseRef.\n * Verse ranges are indicated by \"-\" and consecutive verses by \",\"s.\n * Examples:\n * GEN 1:2 returns GEN 1:2\n * GEN 1:1a-3b,5 returns GEN 1:1a, GEN 1:2, GEN 1:3b, GEN 1:5\n * GEN 1:2a-2c returns //! ??????\n *\n * @param specifiedVersesOnly - if set to true return only verses that are\n * explicitly specified only, not verses within a range. Defaults to `false`.\n * @param verseRangeSeparators - Verse range separators.\n * Defaults to `VerseRef.verseRangeSeparators`.\n * @param verseSequenceSeparators - Verse sequence separators.\n * Defaults to `VerseRef.verseSequenceIndicators`.\n * @returns An array of all single verse references in this VerseRef.\n */\n allVerses(e = !1, s = i.verseRangeSeparators, r = i.verseSequenceIndicators) {\n if (this._verse == null || this.chapterNum <= 0)\n return [this.clone()];\n const a = [], o = E(this._verse, r);\n for (const u of o.map((f) => E(f, s))) {\n const f = this.clone();\n f.verse = u[0];\n const d = f.verseNum;\n if (a.push(f), u.length > 1) {\n const b = this.clone();\n if (b.verse = u[1], !e)\n for (let p = d + 1; p < b.verseNum; p++) {\n const J = new i(\n this._bookNum,\n this._chapterNum,\n p,\n this.versification\n );\n this.isExcluded || a.push(J);\n }\n a.push(b);\n }\n }\n return a;\n }\n /**\n * Validates a verse number using the supplied separators rather than the defaults.\n */\n validateVerse(e, s) {\n if (!this.verse)\n return this.internalValid;\n let r = 0;\n for (const a of this.allVerses(!0, e, s)) {\n const o = a.internalValid;\n if (o !== 0)\n return o;\n const u = a.BBBCCCVVV;\n if (r > u)\n return 3;\n if (r === u)\n return 4;\n r = u;\n }\n return 0;\n }\n /**\n * Gets whether a single verse reference is valid.\n */\n get internalValid() {\n return this.versification == null ? 1 : this._bookNum <= 0 || this._bookNum > m.lastBook ? 2 : (m.isCanonical(this._bookNum), 0);\n }\n setEmpty(e = i.defaultVersification) {\n this._bookNum = 0, this._chapterNum = -1, this._verse = void 0, this.versification = e;\n }\n updateInternal(e, s, r) {\n this.bookNum = m.bookIdToNumber(e), this.chapter = s, this.verse = r;\n }\n};\nn(i, \"defaultVersification\", c.English), n(i, \"verseRangeSeparator\", \"-\"), n(i, \"verseSequenceIndicator\", \",\"), n(i, \"verseRangeSeparators\", [i.verseRangeSeparator]), n(i, \"verseSequenceIndicators\", [i.verseSequenceIndicator]), n(i, \"chapterDigitShifter\", 1e3), n(i, \"bookDigitShifter\", i.chapterDigitShifter * i.chapterDigitShifter), n(i, \"bcvMaxValue\", i.chapterDigitShifter - 1), /**\n * The valid status of the VerseRef.\n */\nn(i, \"ValidStatusType\", D);\nlet M = i;\nclass v extends Error {\n}\nexport {\n _ as BookSet,\n m as Canon,\n c as ScrVers,\n l as ScrVersType,\n M as VerseRef,\n v as VerseRefException\n};\n//# sourceMappingURL=index.es.js.map\n","import React from 'react';\nimport * as DropdownMenuPrimitive from '@radix-ui/react-dropdown-menu';\nimport { Check, ChevronRight, Circle } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport const DropdownMenu = DropdownMenuPrimitive.Root;\n\nexport const DropdownMenuTrigger = DropdownMenuPrimitive.Trigger;\n\nexport const DropdownMenuGroup = DropdownMenuPrimitive.Group;\n\nexport const DropdownMenuPortal = DropdownMenuPrimitive.Portal;\n\nexport const DropdownMenuSub = DropdownMenuPrimitive.Sub;\n\nexport const DropdownMenuRadioGroup = DropdownMenuPrimitive.RadioGroup;\n\nexport type DropdownMenuSubTriggerProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.SubTrigger\n> & {\n className?: string;\n inset?: boolean;\n};\n\nexport type DropdownMenuSubContentProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.SubContent\n> & {\n className?: string;\n};\n\nexport type DropdownMenuContentProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Content\n> & {\n className?: string;\n sideOffset?: number;\n};\n\nexport type DropdownMenuItemProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Item\n> & {\n className?: string;\n inset?: boolean;\n};\n\nexport type DropdownMenuCheckboxItemProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.CheckboxItem\n> & {\n className?: string;\n checked?: boolean;\n};\n\nexport type DropdownMenuRadioItemProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.RadioItem\n> & {\n className?: string;\n};\n\nexport type DropdownMenuLabelProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Label\n> & {\n className?: string;\n inset?: boolean;\n};\n\nexport type DropdownMenuSeparatorProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Separator\n> & {\n className?: string;\n};\n\nexport type DropdownMenuShortcutProps = React.HTMLAttributes & {\n className?: string;\n};\n\nexport const DropdownMenuSubTrigger = React.forwardRef<\n React.ElementRef,\n DropdownMenuSubTriggerProps\n>(({ className, inset, children, ...props }, ref) => (\n \n {children}\n \n \n));\nDropdownMenuSubTrigger.displayName = DropdownMenuPrimitive.SubTrigger.displayName;\n\nexport const DropdownMenuSubContent = React.forwardRef<\n React.ElementRef,\n DropdownMenuSubContentProps\n>(({ className, ...props }, ref) => (\n \n));\nDropdownMenuSubContent.displayName = DropdownMenuPrimitive.SubContent.displayName;\n\nexport const DropdownMenuContent = React.forwardRef<\n React.ElementRef,\n DropdownMenuContentProps\n>(({ className, sideOffset = 4, ...props }, ref) => (\n \n \n \n));\nDropdownMenuContent.displayName = DropdownMenuPrimitive.Content.displayName;\n\n/**\n * TODO: fix: direction is not automatically handled by this component, so that shortcuts are\n * display always to the right\n */\nexport const DropdownMenuItem = React.forwardRef<\n React.ElementRef,\n DropdownMenuItemProps\n>(({ className, inset, ...props }, ref) => (\n \n));\nDropdownMenuItem.displayName = DropdownMenuPrimitive.Item.displayName;\n\nexport const DropdownMenuCheckboxItem = React.forwardRef<\n React.ElementRef,\n DropdownMenuCheckboxItemProps\n>(({ className, children, checked, ...props }, ref) => (\n \n \n \n \n \n \n {children}\n \n));\nDropdownMenuCheckboxItem.displayName = DropdownMenuPrimitive.CheckboxItem.displayName;\n\nexport const DropdownMenuRadioItem = React.forwardRef<\n React.ElementRef,\n DropdownMenuRadioItemProps\n>(({ className, children, ...props }, ref) => (\n \n \n \n \n \n \n {children}\n \n));\nDropdownMenuRadioItem.displayName = DropdownMenuPrimitive.RadioItem.displayName;\n\nexport const DropdownMenuLabel = React.forwardRef<\n React.ElementRef,\n DropdownMenuLabelProps\n>(({ className, inset, ...props }, ref) => (\n \n));\nDropdownMenuLabel.displayName = DropdownMenuPrimitive.Label.displayName;\n\nexport const DropdownMenuSeparator = React.forwardRef<\n React.ElementRef,\n DropdownMenuSeparatorProps\n>(({ className, ...props }, ref) => (\n \n));\nDropdownMenuSeparator.displayName = DropdownMenuPrimitive.Separator.displayName;\n\nexport function DropdownMenuShortcut({ className, ...props }: DropdownMenuShortcutProps) {\n return (\n \n );\n}\nDropdownMenuShortcut.displayName = 'DropdownMenuShortcut';\n","import { Canon } from '@sillsdev/scripture';\nimport { PropsWithChildren, KeyboardEvent, forwardRef } from 'react';\nimport { DropdownMenuItem as ShadDropdownMenuItem } from '@/components/shadcn-ui/dropdown-menu';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport type BookType = 'OT' | 'NT' | 'DC';\n\ntype BookMenuItemProps = PropsWithChildren<{\n /** String id of book */\n bookId: string;\n /** Callback to run when a book menu item is selected */\n handleSelectBook: () => void;\n /** Indicates if this menu item is currently selected */\n isSelected: boolean;\n /** Function that is called upon highlighting a book in the dropdown menu */\n handleHighlightBook: () => void;\n /**\n * Function that is called on pressing a key\n *\n * @param event Event that contains information about the key stroke\n */\n handleKeyDown: (event: KeyboardEvent) => void;\n /**\n * Type of book associated with this menu item, coordinates color labels ? Mock up has the labels\n * coordinated to genre\n */\n bookType: BookType;\n}>;\n\nconst BookMenuItem = forwardRef(\n (\n {\n bookId,\n handleSelectBook,\n isSelected,\n handleHighlightBook,\n handleKeyDown,\n bookType,\n children,\n }: BookMenuItemProps,\n ref,\n ) => {\n return (\n {\n // preventDefault() here prevents the entire dropdown menu from closing when selecting this item\n event.preventDefault();\n handleSelectBook();\n }}\n onKeyDown={(event: KeyboardEvent) => {\n handleKeyDown(event);\n }}\n onFocus={handleHighlightBook}\n onMouseMove={handleHighlightBook}\n >\n \n {Canon.bookIdToEnglishName(bookId)}\n \n {isSelected &&
{children}
}\n \n );\n },\n);\n\nexport default BookMenuItem;\n","import { cn } from '@/utils/shadcn-ui.util';\nimport { useCallback } from 'react';\n\nexport type ChapterSelectProps = {\n /**\n * Callback to run when a chapter div is selected\n *\n * @param chapterNumber Number of the chapter that has been selected\n */\n handleSelectChapter: (chapterNumber: number) => void;\n /** The highest chapter number in the book (of course equal to number of chapters in the book) */\n endChapter: number;\n /** The chapter number that is currently selected */\n activeChapter: number;\n /** The chapter number that is currently highlighted using keyboard or mouse navigation */\n highlightedChapter: number;\n /**\n * Callback to run when a chapter is highlighted by the user\n *\n * @param chapterNumber The chapter that is highlighted\n */\n handleHighlightedChapter: (chapterNumber: number) => void;\n};\n\nfunction ChapterSelect({\n handleSelectChapter,\n endChapter,\n activeChapter,\n highlightedChapter,\n handleHighlightedChapter,\n}: ChapterSelectProps) {\n const chapters = Array.from({ length: endChapter }, (_, i) => i + 1);\n\n const handleMouse = useCallback(\n (chapterNumber: number) => {\n handleHighlightedChapter(chapterNumber);\n },\n [handleHighlightedChapter],\n );\n\n return (\n
\n {chapters.map((chapter) => (\n {\n event.preventDefault();\n event.stopPropagation();\n handleSelectChapter(chapter);\n }}\n role=\"button\"\n onKeyDown={(event) => {\n if (event.key === 'Enter') {\n handleSelectChapter(chapter);\n }\n }}\n tabIndex={0}\n onMouseMove={() => handleMouse(chapter)}\n >\n {chapter}\n
\n ))}\n \n );\n}\n\nexport default ChapterSelect;\n","import { DropdownMenuLabel as ShadDropdownMenuLabel } from '@/components/shadcn-ui/dropdown-menu';\nimport { Bookmark, Clock, ArrowDownWideNarrow } from 'lucide-react';\n\nexport type GoToMenuItemProps = {\n handleSort: () => void;\n handleLocationHistory: () => void;\n handleBookmarks: () => void;\n};\n\nfunction GoToMenuItem({ handleSort, handleLocationHistory, handleBookmarks }: GoToMenuItemProps) {\n return (\n \n

Go To

\n
\n \n \n \n
\n
\n );\n}\n\nexport default GoToMenuItem;\n","import BookChapterInput from '@/components/advanced/book-chapter-control/book-chapter-input.component';\nimport BookMenuItem, {\n BookType,\n} from '@/components/advanced/book-chapter-control/book-menu-item.component';\nimport ChapterSelect from '@/components/advanced/book-chapter-control/chapter-select.component';\nimport GoToMenuItem from '@/components/advanced/book-chapter-control/go-to-menu-item.component';\nimport {\n DropdownMenu as ShadDropdownMenu,\n DropdownMenuContent as ShadDropdownMenuContent,\n DropdownMenuLabel as ShadDropdownMenuLabel,\n DropdownMenuSeparator as ShadDropdownMenuSeparator,\n DropdownMenuTrigger as ShadDropdownMenuTrigger,\n} from '@/components/shadcn-ui/dropdown-menu';\nimport { Canon } from '@sillsdev/scripture';\nimport { ScriptureReference, getChaptersForBook } from 'platform-bible-utils';\nimport {\n KeyboardEvent as ReactKeyboardEvent,\n useCallback,\n useEffect,\n useLayoutEffect,\n useRef,\n useState,\n} from 'react';\n\ntype BookTypeLabels = {\n [bookType in BookType]: string;\n};\ntype BookChapterControlProps = {\n scrRef: ScriptureReference;\n handleSubmit: (scrRef: ScriptureReference) => void;\n};\n\nconst ALL_BOOK_IDS = Canon.allBookIds;\nconst BOOK_TYPE_LABELS: BookTypeLabels = {\n OT: 'Old Testament',\n NT: 'New Testament',\n DC: 'Deuterocanon',\n};\nconst BOOK_TYPE_ARRAY: BookType[] = ['OT', 'NT', 'DC'];\n// This is the height of three menu items to offset scrolling to the selected menu item\n// If you use menuItemRef.clientHeight- includes height of chapter div which is too big\nconst SCROLL_OFFSET = 32 + 32 + 32;\nconst SEARCH_QUERY_FORMATS = [\n /^(\\w+)$/i, // Matches a single word (book name or id)\n /^(\\w+)(?:\\s(\\d+))$/i, // Matches a word followed by a chapter number\n /^(\\w+)(?:\\s(\\d+):(\\d+))$/i, // Matches a word followed by a chapter and verse number\n];\nconst fetchGroupedBooks = (bookType: BookType) => {\n const groupedBooks = {\n OT: ALL_BOOK_IDS.filter((bookId) => Canon.isBookOT(bookId)),\n NT: ALL_BOOK_IDS.filter((bookId) => Canon.isBookNT(bookId)),\n DC: ALL_BOOK_IDS.filter((bookId) => Canon.isBookDC(bookId)),\n };\n return groupedBooks[bookType];\n};\nconst fetchEndChapter = (bookId: string) => {\n // getChaptersForBook returns -1 if not found in scrBookData\n // scrBookData only includes OT and NT, so all DC will return -1\n return getChaptersForBook(Canon.bookIdToNumber(bookId));\n};\n\n/**\n * Gets all of the English names from book ids\n *\n * @returns String[]\n */\nfunction getAllEnglishNames(): string[] {\n const allEnglishNames = ALL_BOOK_IDS.map((bookId) => {\n return Canon.bookIdToEnglishName(bookId);\n });\n return allEnglishNames;\n}\n\n/**\n * Determines if bookName is in allEnglishNames\n *\n * @param bookName Book English name\n * @returns True if bookName is included, false otherwise\n */\nfunction isValidBookEnglishName(bookName: string): boolean {\n return getAllEnglishNames().includes(bookName);\n}\n\n/**\n * Gets a bookId from given English name\n *\n * @param bookName Book English name\n * @returns BookId of provided bookName, undefined otherwise\n */\nfunction getBookIdFromEnglishName(bookName: string): string | undefined {\n // Convert bookName to lowercase and then capitalize the first letter\n const formattedBookName = bookName.toLowerCase().replace(/^\\w/, (c) => c.toUpperCase());\n\n if (isValidBookEnglishName(formattedBookName)) {\n const matchingBookId = ALL_BOOK_IDS.find((bookId) => {\n return Canon.bookIdToEnglishName(bookId) === formattedBookName;\n });\n return matchingBookId;\n }\n\n return undefined;\n}\n\nfunction BookChapterControl({ scrRef, handleSubmit }: BookChapterControlProps) {\n const [searchQuery, setSearchQuery] = useState('');\n const [selectedBookId, setSelectedBookId] = useState(\n Canon.bookNumberToId(scrRef.bookNum),\n );\n const [highlightedChapter, setHighlightedChapter] = useState(scrRef.chapterNum ?? 0);\n const [highlightedBookId, setHighlightedBookId] = useState(\n Canon.bookNumberToId(scrRef.bookNum),\n );\n const [isContentOpen, setIsContentOpen] = useState(false);\n const [isContentOpenDelayed, setIsContentOpenDelayed] = useState(isContentOpen);\n\n // This ref will always be defined\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const inputRef = useRef(undefined!);\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const contentRef = useRef(undefined!);\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const menuItemRef = useRef(undefined!);\n\n const fetchFilteredBooks = useCallback(\n (bookType: BookType) => {\n return fetchGroupedBooks(bookType).filter((bookId: string) => {\n const englishNameLowerCase = Canon.bookIdToEnglishName(bookId).toLowerCase();\n const normalizedQuery = searchQuery.replace(/[^a-zA-Z]/g, '').toLowerCase();\n return (\n englishNameLowerCase.includes(normalizedQuery) || // Match book name\n bookId.toLowerCase().includes(normalizedQuery) // Match book ID\n );\n });\n },\n [searchQuery],\n );\n\n const handleSearchInput = (searchString: string) => {\n setSearchQuery(searchString);\n };\n\n /**\n * Whether to prevent radix's logic from closing the dropdown. This is important because radix\n * tries to close the dropdown when the input first focuses, and we don't want it to do that. But\n * we don't want to prevent the dropdown from closing when we click away from the input, so we\n * don't want to just keep it open if the input is focused\n */\n const shouldPreventAutoClosing = useRef(false);\n\n const controlMenuState = useCallback((open: boolean) => {\n if (shouldPreventAutoClosing.current) {\n shouldPreventAutoClosing.current = false;\n return;\n }\n setIsContentOpen(open);\n }, []);\n\n const updateReference = useCallback(\n (bookId: string, shouldClose: boolean, chapter?: number, verse?: number) => {\n setHighlightedChapter(\n Canon.bookNumberToId(scrRef.bookNum) !== bookId ? 1 : scrRef.chapterNum,\n );\n\n if (shouldClose || fetchEndChapter(bookId) === -1) {\n handleSubmit({\n bookNum: Canon.bookIdToNumber(bookId),\n chapterNum: chapter || 1,\n verseNum: verse || 1,\n });\n\n setIsContentOpen(false);\n setSearchQuery('');\n return;\n }\n\n setSelectedBookId(selectedBookId !== bookId ? bookId : '');\n setIsContentOpen(!shouldClose);\n },\n [handleSubmit, scrRef.bookNum, scrRef.chapterNum, selectedBookId],\n );\n\n const handleSelectChapter = (chapterNumber: number) => {\n if (chapterNumber <= 0 || chapterNumber > fetchEndChapter(selectedBookId)) {\n return;\n }\n updateReference(selectedBookId, true, chapterNumber);\n };\n\n const handleInputSubmit = useCallback(() => {\n SEARCH_QUERY_FORMATS.forEach((format) => {\n const matches = searchQuery.match(format);\n if (matches) {\n // Book should be a bookId or an english name\n const [book, chapter = undefined, verse = undefined] = matches.slice(1);\n const englishName = getBookIdFromEnglishName(book);\n\n if (Canon.isBookIdValid(book) || englishName) {\n updateReference(\n englishName ?? book,\n true,\n chapter ? parseInt(chapter, 10) : 1,\n verse ? parseInt(verse, 10) : 1,\n );\n }\n }\n });\n }, [updateReference, searchQuery]);\n\n const handleKeyDownInput = useCallback(\n (event: ReactKeyboardEvent) => {\n if (!isContentOpen) {\n setIsContentOpen(true);\n } else if (event.key === 'ArrowDown' || event.key === 'ArrowUp') {\n if (\n typeof menuItemRef !== 'undefined' &&\n // Ref uses null\n // eslint-disable-next-line no-null/no-null\n menuItemRef.current !== null\n ) {\n menuItemRef.current.focus();\n } else if (\n typeof contentRef !== 'undefined' &&\n // Ref uses null\n // eslint-disable-next-line no-null/no-null\n contentRef.current !== null\n ) {\n contentRef.current.focus();\n }\n event.preventDefault();\n }\n },\n [isContentOpen],\n );\n\n const handleKeyDownContent = (event: ReactKeyboardEvent) => {\n // When the dropdown menu has focus, key strokes should give focus to the input component,\n // unless they're navigation keys (arrows and enter)\n const { key } = event;\n if (\n key === 'ArrowRight' ||\n key === 'ArrowLeft' ||\n key === 'ArrowDown' ||\n key === 'ArrowUp' ||\n key === 'Enter'\n ) {\n return;\n }\n\n inputRef.current.dispatchEvent(new KeyboardEvent('keydown', { key }));\n inputRef.current.focus();\n };\n\n const handleKeyDownMenuItem = (event: ReactKeyboardEvent) => {\n const { key } = event;\n if (highlightedBookId === selectedBookId) {\n if (key === 'Enter') {\n event.preventDefault();\n updateReference(selectedBookId, true, highlightedChapter);\n return;\n }\n\n let chapterOffSet = 0;\n if (key === 'ArrowRight') {\n if (highlightedChapter < fetchEndChapter(highlightedBookId)) {\n chapterOffSet = 1;\n } else {\n event.preventDefault();\n return;\n }\n } else if (key === 'ArrowLeft') {\n if (highlightedChapter > 1) {\n chapterOffSet = -1;\n } else {\n event.preventDefault();\n return;\n }\n } else if (key === 'ArrowDown') {\n chapterOffSet = 6;\n } else if (key === 'ArrowUp') {\n chapterOffSet = -6;\n }\n if (\n highlightedChapter + chapterOffSet <= 0 ||\n highlightedChapter + chapterOffSet > fetchEndChapter(highlightedBookId)\n ) {\n setHighlightedChapter(0);\n } else if (chapterOffSet !== 0) {\n setHighlightedChapter(highlightedChapter + chapterOffSet);\n event.preventDefault();\n }\n }\n };\n\n useEffect(() => {\n if (selectedBookId === highlightedBookId) {\n if (selectedBookId === Canon.bookNumberToId(scrRef.bookNum)) {\n setHighlightedChapter(scrRef.chapterNum);\n } else {\n setHighlightedChapter(1);\n }\n } else {\n setHighlightedChapter(0);\n }\n }, [highlightedBookId, scrRef.bookNum, scrRef.chapterNum, selectedBookId]);\n\n // The purpose of these useLayoutEffects and timeout is to delay the scroll just\n // enough so that the refs are defined and available when they are used after the timeout\n useLayoutEffect(() => {\n setIsContentOpenDelayed(isContentOpen);\n }, [isContentOpen]);\n\n useLayoutEffect(() => {\n const scrollTimeout = setTimeout(() => {\n if (isContentOpenDelayed && contentRef.current && menuItemRef.current) {\n const menuItemOffsetTop = menuItemRef.current.offsetTop;\n const scrollPosition = menuItemOffsetTop - SCROLL_OFFSET;\n contentRef.current.scrollTo({ top: scrollPosition, behavior: 'instant' });\n }\n }, 10);\n return () => {\n clearTimeout(scrollTimeout);\n };\n }, [isContentOpenDelayed]);\n\n return (\n
\n \n \n {\n setSelectedBookId(Canon.bookNumberToId(scrRef.bookNum));\n setHighlightedBookId(Canon.bookNumberToId(scrRef.bookNum));\n setHighlightedChapter(scrRef.chapterNum > 0 ? scrRef.chapterNum : 0);\n setIsContentOpen(true);\n inputRef.current.focus();\n }}\n onFocus={() => {\n // Radix thinks we want to close because the input is being focused. Prevent that\n shouldPreventAutoClosing.current = true;\n }}\n handleSubmit={handleInputSubmit}\n placeholder={`${Canon.bookNumberToEnglishName(scrRef.bookNum)} ${scrRef.chapterNum}:${scrRef.verseNum}`}\n />\n \n \n console.log('sorting')}\n handleLocationHistory={() => console.log('location history')}\n handleBookmarks={() => console.log('bookmarks')}\n />\n {BOOK_TYPE_ARRAY.map(\n (bookType, bookTypeIndex) =>\n fetchFilteredBooks(bookType).length > 0 && (\n
\n \n {BOOK_TYPE_LABELS[bookType]}\n \n\n {fetchFilteredBooks(bookType).map((bookId) => (\n
\n updateReference(bookId, false)}\n isSelected={selectedBookId === bookId}\n handleHighlightBook={() => setHighlightedBookId(bookId)}\n handleKeyDown={handleKeyDownMenuItem}\n bookType={bookType}\n ref={(element: HTMLDivElement) => {\n if (selectedBookId === bookId) menuItemRef.current = element;\n }}\n >\n {\n setHighlightedChapter(chapterNumber);\n }}\n />\n \n
\n ))}\n {BOOK_TYPE_ARRAY.length - 1 !== bookTypeIndex ? (\n \n ) : undefined}\n
\n ),\n )}\n \n
\n
\n );\n}\n\nexport default BookChapterControl;\n","import React from 'react';\nimport { Slot } from '@radix-ui/react-slot';\nimport { cva, type VariantProps } from 'class-variance-authority';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport const buttonVariants = cva(\n 'pr-twp tw-inline-flex tw-items-center tw-justify-center tw-whitespace-nowrap tw-rounded-md tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-colors focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50',\n {\n variants: {\n variant: {\n default: 'tw-bg-primary tw-text-primary-foreground hover:tw-bg-primary/90',\n destructive: 'tw-bg-destructive tw-text-destructive-foreground hover:tw-bg-destructive/90',\n outline:\n 'tw-border tw-border-input tw-bg-background hover:tw-bg-accent hover:tw-text-accent-foreground',\n secondary: 'tw-bg-secondary tw-text-secondary-foreground hover:tw-bg-secondary/80',\n ghost: 'hover:tw-bg-accent hover:tw-text-accent-foreground',\n link: 'tw-text-primary tw-underline-offset-4 hover:tw-underline',\n },\n size: {\n default: 'tw-h-10 tw-px-4 tw-py-2',\n sm: 'tw-h-9 tw-rounded-md tw-px-3',\n lg: 'tw-h-11 tw-rounded-md tw-px-8',\n icon: 'tw-h-10 tw-w-10',\n },\n },\n defaultVariants: {\n variant: 'default',\n size: 'default',\n },\n },\n);\n\nexport interface ButtonProps\n extends React.ButtonHTMLAttributes,\n VariantProps {\n asChild?: boolean;\n}\n\nexport const Button = React.forwardRef(\n ({ className, variant, size, asChild = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'button';\n return (\n \n );\n },\n);\nButton.displayName = 'Button';\n","import React from 'react';\nimport * as LabelPrimitive from '@radix-ui/react-label';\nimport { cva, type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst labelVariants = cva(\n 'tw-text-sm tw-font-medium tw-leading-none peer-disabled:tw-cursor-not-allowed peer-disabled:tw-opacity-70',\n);\n\nexport const Label = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef & VariantProps\n>(({ className, ...props }, ref) => (\n \n));\nLabel.displayName = LabelPrimitive.Root.displayName;\n","import React from 'react';\nimport * as RadioGroupPrimitive from '@radix-ui/react-radio-group';\nimport { Circle } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst RadioGroup = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => {\n return (\n \n );\n});\nRadioGroup.displayName = RadioGroupPrimitive.Root.displayName;\n\nconst RadioGroupItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => {\n return (\n \n \n \n \n \n );\n});\nRadioGroupItem.displayName = RadioGroupPrimitive.Item.displayName;\n\nexport { RadioGroup, RadioGroupItem };\n","import React from 'react';\nimport * as PopoverPrimitive from '@radix-ui/react-popover';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Popover = PopoverPrimitive.Root;\n\nconst PopoverTrigger = PopoverPrimitive.Trigger;\n\nconst PopoverContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, align = 'center', sideOffset = 4, ...props }, ref) => (\n \n \n \n));\nPopoverContent.displayName = PopoverPrimitive.Content.displayName;\n\nexport { Popover, PopoverTrigger, PopoverContent };\n","import React from 'react';\nimport * as DialogPrimitive from '@radix-ui/react-dialog';\nimport { X } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Dialog = DialogPrimitive.Root;\n\nconst DialogTrigger = DialogPrimitive.Trigger;\n\nconst DialogPortal = DialogPrimitive.Portal;\n\nconst DialogClose = DialogPrimitive.Close;\n\nconst DialogOverlay = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nDialogOverlay.displayName = DialogPrimitive.Overlay.displayName;\n\nconst DialogContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, ...props }, ref) => (\n \n \n \n {children}\n \n \n Close\n \n \n \n));\nDialogContent.displayName = DialogPrimitive.Content.displayName;\n\nfunction DialogHeader({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nDialogHeader.displayName = 'DialogHeader';\n\nfunction DialogFooter({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nDialogFooter.displayName = 'DialogFooter';\n\nconst DialogTitle = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nDialogTitle.displayName = DialogPrimitive.Title.displayName;\n\nconst DialogDescription = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nDialogDescription.displayName = DialogPrimitive.Description.displayName;\n\nexport {\n Dialog,\n DialogPortal,\n DialogOverlay,\n DialogClose,\n DialogTrigger,\n DialogContent,\n DialogHeader,\n DialogFooter,\n DialogTitle,\n DialogDescription,\n};\n","import React from 'react';\nimport { type DialogProps } from '@radix-ui/react-dialog';\nimport { Command as CommandPrimitive } from 'cmdk';\nimport { Search } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Dialog, DialogContent } from '@/components/shadcn-ui/dialog';\n\nconst Command = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nCommand.displayName = CommandPrimitive.displayName;\n\ninterface CommandDialogProps extends DialogProps {}\n\nfunction CommandDialog({ children, ...props }: CommandDialogProps) {\n return (\n \n \n \n {children}\n \n \n \n );\n}\n\nconst CommandInput = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n
\n \n \n
\n));\n\nCommandInput.displayName = CommandPrimitive.Input.displayName;\n\nconst CommandList = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\n\nCommandList.displayName = CommandPrimitive.List.displayName;\n\nconst CommandEmpty = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>((props, ref) => (\n \n));\n\nCommandEmpty.displayName = CommandPrimitive.Empty.displayName;\n\nconst CommandGroup = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\n\nCommandGroup.displayName = CommandPrimitive.Group.displayName;\n\nconst CommandSeparator = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nCommandSeparator.displayName = CommandPrimitive.Separator.displayName;\n\nconst CommandItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\n\nCommandItem.displayName = CommandPrimitive.Item.displayName;\n\nfunction CommandShortcut({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nCommandShortcut.displayName = 'CommandShortcut';\n\nexport {\n Command,\n CommandDialog,\n CommandInput,\n CommandList,\n CommandEmpty,\n CommandGroup,\n CommandItem,\n CommandShortcut,\n CommandSeparator,\n};\n","import { useState } from 'react';\nimport { Check, ChevronsUpDown } from 'lucide-react';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport { Popover, PopoverContent, PopoverTrigger } from '@/components/shadcn-ui/popover';\nimport {\n Command,\n CommandEmpty,\n CommandInput,\n CommandItem,\n CommandList,\n} from '@/components/shadcn-ui/command';\nimport { PopoverProps } from '@radix-ui/react-popover';\n\nexport type ComboBoxLabelOption = { label: string };\nexport type ComboBoxOption = string | number | ComboBoxLabelOption;\n\nexport type ComboBoxProps = {\n /** Optional unique identifier */\n id?: string;\n /** Text label title for combobox */\n /** List of available options for the dropdown menu */\n options?: readonly T[];\n /** Additional css classes to help with unique styling of the combo box */\n className?: string;\n /**\n * The selected value that the combo box currently holds. Must be shallow equal to one of the\n * options entries.\n */\n value?: T;\n /** Triggers when content of textfield is changed */\n onChange?: (newValue: T) => void;\n /** Used to determine the string value for a given option. */\n getOptionLabel?: (option: ComboBoxOption) => string;\n /** Text displayed on button if `value` is undefined */\n buttonPlaceholder?: string;\n /** Placeholder text for text field */\n textPlaceholder?: string;\n /** Text to display when no options match input */\n commandEmptyMessage?: string;\n /** Variant of button */\n buttonVariant?: ButtonProps['variant'];\n /** Text direction ltr or rtl */\n dir?: Direction;\n /** Optional boolean to set if trigger should be disabled */\n isDisabled?: boolean;\n} & PopoverProps;\n\ntype Direction = 'ltr' | 'rtl';\n\nfunction getOptionLabelDefault(option: ComboBoxOption): string {\n if (typeof option === 'string') {\n return option;\n }\n if (typeof option === 'number') {\n return option.toString();\n }\n return option.label;\n}\n\n/**\n * Autocomplete input and command palette with a list of suggestions.\n *\n * Thanks to Shadcn for heavy inspiration and documentation\n * https://ui.shadcn.com/docs/components/combobox\n */\nfunction ComboBox({\n id,\n options = [],\n className,\n value,\n onChange = () => {},\n getOptionLabel = getOptionLabelDefault,\n buttonPlaceholder = '',\n textPlaceholder = '',\n commandEmptyMessage = 'No option found',\n buttonVariant = 'outline',\n dir = 'ltr',\n isDisabled = false,\n ...props\n}: ComboBoxProps) {\n const [open, setOpen] = useState(false);\n\n return (\n \n \n \n \n {value ? getOptionLabel(value) : buttonPlaceholder}\n \n \n \n \n \n \n \n {commandEmptyMessage}\n \n {options.map((option) => (\n {\n onChange(option);\n setOpen(false);\n }}\n >\n \n {getOptionLabel(option)}\n \n ))}\n \n \n \n \n );\n}\n\nexport default ComboBox;\n","import { useMemo } from 'react';\nimport ComboBox from '@/components/basics/combo-box.component';\nimport { Label } from '@/components/shadcn-ui/label';\n\nexport type ChapterRangeSelectorProps = {\n startChapter: number;\n endChapter: number;\n handleSelectStartChapter: (chapter: number) => void;\n handleSelectEndChapter: (chapter: number) => void;\n isDisabled?: boolean;\n chapterCount: number;\n};\n\nexport default function ChapterRangeSelector({\n startChapter,\n endChapter,\n handleSelectStartChapter,\n handleSelectEndChapter,\n isDisabled = false,\n chapterCount,\n}: ChapterRangeSelectorProps) {\n const chapterOptions = useMemo(\n () => Array.from({ length: chapterCount }, (_, index) => index + 1),\n [chapterCount],\n );\n\n const onChangeStartChapter = (value: number) => {\n handleSelectStartChapter(value);\n if (value > endChapter) {\n handleSelectEndChapter(value);\n }\n };\n\n const onChangeEndChapter = (value: number) => {\n handleSelectEndChapter(value);\n if (value < startChapter) {\n handleSelectStartChapter(value);\n }\n };\n\n return (\n <>\n \n option.toString()}\n value={startChapter}\n />\n\n \n option.toString()}\n value={endChapter}\n />\n \n );\n}\n","import { Button } from '@/components/shadcn-ui/button';\nimport { Label } from '@/components/shadcn-ui/label';\nimport { RadioGroup, RadioGroupItem } from '@/components/shadcn-ui/radio-group';\nimport { Canon } from '@sillsdev/scripture';\nimport { LocalizedStringValue } from 'platform-bible-utils';\nimport { useState } from 'react';\nimport ChapterRangeSelector, {\n ChapterRangeSelectorProps,\n} from '../basics/chapter-range-selector.component';\n\nexport enum BookSelectionMode {\n CURRENT_BOOK = 'current book',\n CHOOSE_BOOKS = 'choose books',\n}\n\n/**\n * Object containing all keys used for localization in this component. If you're using this\n * component in an extension, you can pass it into the useLocalizedStrings hook to easily obtain the\n * localized strings and pass them into the localizedStrings prop of this component\n */\nexport const BOOK_SELECTOR_STRING_KEYS = Object.freeze([\n '%webView_bookSelector_currentBook%',\n '%webView_bookSelector_choose%',\n '%webView_bookSelector_chooseBooks%',\n] as const);\n\nexport type BookSelectorLocalizedStrings = {\n [localizedInventoryKey in (typeof BOOK_SELECTOR_STRING_KEYS)[number]]?: LocalizedStringValue;\n};\n\n/**\n * Gets the localized value for the provided key\n *\n * @param strings Object containing localized string\n * @param key Key for a localized string\n * @returns The localized value for the provided key, if available. Returns the key if no localized\n * value is available\n */\nconst localizeString = (\n strings: BookSelectorLocalizedStrings,\n key: keyof BookSelectorLocalizedStrings,\n) => {\n return strings[key] ?? key;\n};\n\ntype BookSelectorProps = ChapterRangeSelectorProps & {\n handleBookSelectionModeChange: (newMode: BookSelectionMode) => void;\n currentBookName: string;\n onSelectBooks: () => void;\n selectedBookIds: string[];\n localizedStrings: BookSelectorLocalizedStrings;\n};\n\nexport default function BookSelector({\n handleBookSelectionModeChange,\n currentBookName,\n onSelectBooks,\n selectedBookIds,\n chapterCount,\n endChapter,\n handleSelectEndChapter,\n startChapter,\n handleSelectStartChapter,\n localizedStrings,\n}: BookSelectorProps) {\n const currentBookText = localizeString(localizedStrings, '%webView_bookSelector_currentBook%');\n const chooseText = localizeString(localizedStrings, '%webView_bookSelector_choose%');\n const chooseBooksText = localizeString(localizedStrings, '%webView_bookSelector_chooseBooks%');\n\n const [bookSelectionMode, setBookSelectionMode] = useState(\n BookSelectionMode.CURRENT_BOOK,\n );\n\n const onSelectionModeChange = (newMode: BookSelectionMode) => {\n setBookSelectionMode(newMode);\n handleBookSelectionModeChange(newMode);\n };\n\n return (\n onSelectionModeChange(value as BookSelectionMode)}\n >\n
\n
\n
\n \n \n
\n \n
\n \n
\n
\n
\n
\n \n \n
\n \n onSelectBooks()}\n >\n {chooseText}\n \n
\n
\n \n );\n}\n","import { DropdownMenuTrigger } from '@radix-ui/react-dropdown-menu';\nimport { FilterIcon } from 'lucide-react';\nimport { Table } from '@tanstack/react-table';\n\nimport { Button } from '@/components/shadcn-ui/button';\nimport {\n DropdownMenu,\n DropdownMenuCheckboxItem,\n DropdownMenuContent,\n DropdownMenuLabel,\n DropdownMenuSeparator,\n} from '@/components/shadcn-ui/dropdown-menu';\n\ninterface DataTableViewOptionsProps {\n table: Table;\n}\n\nfunction DataTableViewOptions({ table }: DataTableViewOptionsProps) {\n return (\n \n \n \n \n \n Toggle columns\n \n {table\n .getAllColumns()\n .filter((column) => column.getCanHide())\n .map((column) => {\n return (\n column.toggleVisibility(!!value)}\n >\n {column.id}\n \n );\n })}\n \n \n );\n}\n\nexport default DataTableViewOptions;\n","import React from 'react';\nimport * as SelectPrimitive from '@radix-ui/react-select';\nimport { Check, ChevronDown, ChevronUp } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Select = SelectPrimitive.Root;\n\nconst SelectGroup = SelectPrimitive.Group;\n\nconst SelectValue = SelectPrimitive.Value;\n\nconst SelectTrigger = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, ...props }, ref) => (\n span]:tw-line-clamp-1',\n className,\n )}\n {...props}\n >\n {children}\n \n \n \n \n));\nSelectTrigger.displayName = SelectPrimitive.Trigger.displayName;\n\nconst SelectScrollUpButton = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n));\nSelectScrollUpButton.displayName = SelectPrimitive.ScrollUpButton.displayName;\n\nconst SelectScrollDownButton = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n));\nSelectScrollDownButton.displayName = SelectPrimitive.ScrollDownButton.displayName;\n\nconst SelectContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, position = 'popper', ...props }, ref) => (\n \n \n \n \n {children}\n \n \n \n \n));\nSelectContent.displayName = SelectPrimitive.Content.displayName;\n\nconst SelectLabel = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSelectLabel.displayName = SelectPrimitive.Label.displayName;\n\nconst SelectItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, ...props }, ref) => (\n \n \n \n \n \n \n\n {children}\n \n));\nSelectItem.displayName = SelectPrimitive.Item.displayName;\n\nconst SelectSeparator = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSelectSeparator.displayName = SelectPrimitive.Separator.displayName;\n\nexport {\n Select,\n SelectGroup,\n SelectValue,\n SelectTrigger,\n SelectContent,\n SelectLabel,\n SelectItem,\n SelectSeparator,\n SelectScrollUpButton,\n SelectScrollDownButton,\n};\n","import { ChevronLeftIcon, ChevronRightIcon, ArrowLeftIcon, ArrowRightIcon } from 'lucide-react';\nimport { Table } from '@tanstack/react-table';\n\nimport { Button } from '@/components/shadcn-ui/button';\nimport {\n Select,\n SelectContent,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\n\ninterface DataTablePaginationProps {\n table: Table;\n}\n\nfunction DataTablePagination({ table }: DataTablePaginationProps) {\n return (\n
\n
\n
\n {table.getFilteredSelectedRowModel().rows.length} of{' '}\n {table.getFilteredRowModel().rows.length} row(s) selected\n
\n
\n

Rows per page

\n {\n table.setPageSize(Number(value));\n }}\n >\n \n \n \n \n {[10, 20, 30, 40, 50].map((pageSize) => (\n \n {pageSize}\n \n ))}\n \n \n
\n
\n Page {table.getState().pagination.pageIndex + 1} of {table.getPageCount()}\n
\n
\n table.setPageIndex(0)}\n disabled={!table.getCanPreviousPage()}\n >\n Go to first page\n \n \n table.previousPage()}\n disabled={!table.getCanPreviousPage()}\n >\n Go to previous page\n \n \n table.nextPage()}\n disabled={!table.getCanNextPage()}\n >\n Go to next page\n \n \n table.setPageIndex(table.getPageCount() - 1)}\n disabled={!table.getCanNextPage()}\n >\n Go to last page\n \n \n
\n
\n
\n );\n}\n\nexport default DataTablePagination;\n","import React from 'react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Table = React.forwardRef<\n HTMLTableElement,\n React.HTMLAttributes & { stickyHeader?: boolean }\n>(({ className, stickyHeader, ...props }, ref) => (\n
\n \n
\n));\nTable.displayName = 'Table';\n\nconst TableHeader = React.forwardRef<\n HTMLTableSectionElement,\n React.HTMLAttributes & { stickyHeader?: boolean }\n>(({ className, stickyHeader, ...props }, ref) => (\n \n));\nTableHeader.displayName = 'TableHeader';\n\nconst TableBody = React.forwardRef<\n HTMLTableSectionElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableBody.displayName = 'TableBody';\n\nconst TableFooter = React.forwardRef<\n HTMLTableSectionElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n tr]:last:tw-border-b-0', className)}\n {...props}\n />\n));\nTableFooter.displayName = 'TableFooter';\n\nconst TableRow = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nTableRow.displayName = 'TableRow';\n\nconst TableHead = React.forwardRef<\n HTMLTableCellElement,\n React.ThHTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableHead.displayName = 'TableHead';\n\nconst TableCell = React.forwardRef<\n HTMLTableCellElement,\n React.TdHTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableCell.displayName = 'TableCell';\n\nconst TableCaption = React.forwardRef<\n HTMLTableCaptionElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableCaption.displayName = 'TableCaption';\n\nexport { Table, TableHeader, TableBody, TableFooter, TableHead, TableRow, TableCell, TableCaption };\n","import { useState } from 'react';\n\nimport {\n ColumnFiltersState,\n flexRender,\n getCoreRowModel,\n getFilteredRowModel,\n getPaginationRowModel,\n getSortedRowModel,\n SortingState,\n ColumnDef as TSColumnDef,\n Row as TSRow,\n RowSelectionState as TSRowSelectionState,\n SortDirection as TSSortDirection,\n Table as TSTable,\n useReactTable,\n VisibilityState,\n} from '@tanstack/react-table';\n\nimport DataTableViewOptions from '@/components/advanced/data-table/data-table-column-toggle.component';\nimport DataTablePagination from '@/components/advanced/data-table/data-table-pagination.component';\nimport { Button } from '@/components/shadcn-ui/button';\nimport {\n Table,\n TableBody,\n TableCell,\n TableHead,\n TableHeader,\n TableRow,\n} from '@/components/shadcn-ui/table';\n\nexport type ColumnDef = TSColumnDef;\nexport type RowContents = TSRow;\nexport type TableContents = TSTable;\nexport type SortDirection = TSSortDirection;\nexport type RowSelectionState = TSRowSelectionState;\n\ninterface DataTableProps {\n columns: ColumnDef[];\n data: TData[];\n enablePagination?: boolean;\n showPaginationControls?: boolean;\n showColumnVisibilityControls?: boolean;\n stickyHeader?: boolean;\n onRowClickHandler?: (row: RowContents, table: TableContents) => void;\n}\n\n/**\n * Feature-rich table component that infuses our basic shadcn-based Table component with features\n * from TanStack's React Table library\n */\nfunction DataTable({\n columns,\n data,\n enablePagination = false,\n showPaginationControls = false,\n showColumnVisibilityControls = false,\n stickyHeader = false,\n onRowClickHandler = () => {},\n}: DataTableProps) {\n const [sorting, setSorting] = useState([]);\n const [columnFilters, setColumnFilters] = useState([]);\n const [columnVisibility, setColumnVisibility] = useState({});\n const [rowSelection, setRowSelection] = useState({});\n\n const table = useReactTable({\n data,\n columns,\n getCoreRowModel: getCoreRowModel(),\n ...(enablePagination && { getPaginationRowModel: getPaginationRowModel() }),\n onSortingChange: setSorting,\n getSortedRowModel: getSortedRowModel(),\n onColumnFiltersChange: setColumnFilters,\n getFilteredRowModel: getFilteredRowModel(),\n onColumnVisibilityChange: setColumnVisibility,\n onRowSelectionChange: setRowSelection,\n state: {\n sorting,\n columnFilters,\n columnVisibility,\n rowSelection,\n },\n });\n\n return (\n
\n {showColumnVisibilityControls && }\n \n \n {table.getHeaderGroups().map((headerGroup) => (\n \n {headerGroup.headers.map((header) => {\n return (\n \n {header.isPlaceholder\n ? undefined\n : flexRender(header.column.columnDef.header, header.getContext())}\n \n );\n })}\n \n ))}\n \n \n {table.getRowModel().rows?.length ? (\n table.getRowModel().rows.map((row) => (\n onRowClickHandler(row, table)}\n key={row.id}\n data-state={row.getIsSelected() && 'selected'}\n >\n {row.getVisibleCells().map((cell) => (\n \n {flexRender(cell.column.columnDef.cell, cell.getContext())}\n \n ))}\n \n ))\n ) : (\n \n \n No results.\n \n \n )}\n \n
\n {enablePagination && (\n
\n table.previousPage()}\n disabled={!table.getCanPreviousPage()}\n >\n Previous\n \n table.nextPage()}\n disabled={!table.getCanNextPage()}\n >\n Next\n \n
\n )}\n {enablePagination && showPaginationControls && }\n
\n );\n}\n\nexport default DataTable;\n","import {\n Table,\n TableBody,\n TableCell,\n TableHead,\n TableHeader,\n TableRow,\n} from '@/components/shadcn-ui/table';\nimport { Canon } from '@sillsdev/scripture';\nimport { deepEqual, LanguageStrings, ScriptureReference } from 'platform-bible-utils';\nimport { useMemo } from 'react';\nimport { InventoryItemOccurrence } from './inventory-utils';\n\n/** Props for the OccurrencesTable component */\ntype OccurrencesTableProps = {\n /** Data that contains scriptures references and snippets of scripture */\n occurrenceData: InventoryItemOccurrence[];\n /** Callback function that is executed when the scripture reference is changed */\n setScriptureReference: (scriptureReference: ScriptureReference) => void;\n /**\n * Object with all localized strings that the OccurrencesTable needs to work well across multiple\n * languages\n */\n localizedStrings: LanguageStrings;\n};\n\n/**\n * Table that shows occurrences of specified inventory item(s). The first column shows the related\n * scripture reference. The second column shows the snippet of scripture that contains the specified\n * inventory item\n */\nfunction OccurrencesTable({\n occurrenceData,\n setScriptureReference,\n localizedStrings,\n}: OccurrencesTableProps) {\n const referenceHeaderText =\n localizedStrings['%webView_inventory_occurrences_table_header_reference%'];\n const occurrenceHeaderText =\n localizedStrings['%webView_inventory_occurrences_table_header_occurrence%'];\n\n const occurrences: InventoryItemOccurrence[] = useMemo(() => {\n const uniqueOccurrences: InventoryItemOccurrence[] = [];\n\n occurrenceData.forEach((occurrence) => {\n if (!uniqueOccurrences.some((uniqueOccurrence) => deepEqual(uniqueOccurrence, occurrence))) {\n uniqueOccurrences.push(occurrence);\n }\n });\n\n return uniqueOccurrences;\n }, [occurrenceData]);\n\n return (\n \n \n \n {referenceHeaderText}\n {occurrenceHeaderText}\n \n \n \n {occurrences.length > 0 &&\n occurrences.map((occurrence) => (\n {\n setScriptureReference(occurrence.reference);\n }}\n >\n {`${Canon.bookNumberToEnglishName(occurrence.reference.bookNum)} ${occurrence.reference.chapterNum}:${occurrence.reference.verseNum}`}\n {occurrence.text}\n \n ))}\n \n
\n );\n}\n\nexport default OccurrencesTable;\n","import React from 'react';\nimport * as CheckboxPrimitive from '@radix-ui/react-checkbox';\nimport { Check } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Checkbox = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n \n \n));\nCheckbox.displayName = CheckboxPrimitive.Root.displayName;\n\nexport default Checkbox;\n","import { Canon } from '@sillsdev/scripture';\nimport { ScriptureReference } from 'platform-bible-utils';\n\n/* #region Types */\n\n/**\n * Status of items that appear in inventories. 'approved' and 'unapproved' items are defined in the\n * project's `Settings.xml`. All other items are defined as 'unknown'\n */\nexport type Status = 'approved' | 'unapproved' | 'unknown';\n\n/** Occurrence of item in inventory. Primarily used by table that shows occurrences */\nexport type InventoryItemOccurrence = {\n /** Reference to scripture where the item appears */\n reference: ScriptureReference;\n /** Snippet of scripture that contains the occurrence */\n text: string;\n};\n\n/** Data structure that contains all information on an item that is shown in an inventory */\nexport type InventoryTableData = {\n /**\n * The item (e.g. a character in the characters inventory, a marker in the marker inventory) In\n * most cases the array will only have one element. In case of additional items (e.g. the\n * preceding marker in the markers check), the primary item should be stored in the first index.\n * To show additional items in the inventory, make sure to configure the `additionalItemsLabels`\n * prop for the Inventory component\n */\n items: string[];\n /** The number of times this item occurs in the selected scope */\n count: number;\n /** The status of this item (see documentation for `Status` type for more information) */\n status: Status;\n /** Occurrences of this item in the scripture text for the selected scope */\n occurrences: InventoryItemOccurrence[];\n};\n\n/* #endregion */\n\n/* #region Functions */\n\n/**\n * Splits USFM string into shorter line-like segments\n *\n * @param text A single (likely very large) USFM string\n * @returns An array containing the input text, split into shorter segments\n */\nexport const getLinesFromUSFM = (text: string) => {\n // Splits on (CR)LF, CR, \\v, \\c and \\id\n return text.split(/(?:\\r?\\n|\\r)|(?=(?:\\\\(?:v|c|id)))/g);\n};\n\n/**\n * Extracts chapter or verse number from USFM strings that start with a \\c or \\v marker\n *\n * @param text USFM string that is expected to start with \\c or \\v marker\n * @returns Chapter or verse number if one is found. Else returns 0.\n */\nexport const getNumberFromUSFM = (text: string): number | undefined => {\n // Captures all digits that follow \\v or \\c markers followed by whitespace located at the start of a string\n const regex = /^\\\\[vc]\\s+(\\d+)/;\n const match = text.match(regex);\n\n if (match) {\n return +match[1];\n }\n return undefined;\n};\n\n/**\n * Gets book ID from USFM string that starts with the \\id marker, and returns book number for it\n *\n * @param text USFM string that is expected to start with \\id marker\n * @returns Book number corresponding to the \\id marker in the input text. Returns 0 if no marker is\n * found or the marker is not valid\n */\nexport const getBookNumFromId = (text: string): number => {\n // Captures all digits that follow an \\id marker followed by whitespace located at the start of a string\n const match = text.match(/^\\\\id\\s+([A-Za-z]+)/);\n if (match) {\n return Canon.bookIdToNumber(match[1]);\n }\n return 0;\n};\n\n/**\n * Gets the status for an item, typically used in the Inventory component\n *\n * @param item The item for which the status is being requested\n * @param approvedItems Array of approved items, typically as defined in `Settings.xml`\n * @param unapprovedItems Array of unapproved items, typically as defined in `Settings.xml`\n * @returns The status for the specified item\n */\nexport const getStatusForItem = (\n item: string,\n approvedItems: string[],\n unapprovedItems: string[],\n): Status => {\n if (unapprovedItems.includes(item)) return 'unapproved';\n if (approvedItems.includes(item)) return 'approved';\n return 'unknown';\n};\n\n/* #endregion */\n","import React from 'react';\nimport * as TogglePrimitive from '@radix-ui/react-toggle';\nimport { cva, type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst toggleVariants = cva(\n 'pr-twp tw-inline-flex tw-items-center tw-justify-center tw-rounded-md tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-colors hover:tw-bg-muted hover:tw-text-muted-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50 data-[state=on]:tw-bg-accent data-[state=on]:tw-text-accent-foreground',\n {\n variants: {\n variant: {\n default: 'tw-bg-transparent',\n outline:\n 'tw-border tw-border-input tw-bg-transparent hover:tw-bg-accent hover:tw-text-accent-foreground',\n },\n size: {\n default: 'tw-h-10 tw-px-3',\n sm: 'tw-h-9 tw-px-2.5',\n lg: 'tw-h-11 tw-px-5',\n },\n },\n defaultVariants: {\n variant: 'default',\n size: 'default',\n },\n },\n);\n\nconst Toggle = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef & VariantProps\n>(({ className, variant, size, ...props }, ref) => (\n \n));\n\nToggle.displayName = TogglePrimitive.Root.displayName;\n\nexport { Toggle, toggleVariants };\n","import React from 'react';\nimport * as ToggleGroupPrimitive from '@radix-ui/react-toggle-group';\nimport { type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { toggleVariants } from '@/components/shadcn-ui/toggle';\n\nconst ToggleGroupContext = React.createContext>({\n size: 'default',\n variant: 'default',\n});\n\nconst ToggleGroup = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef &\n VariantProps\n>(({ className, variant, size, children, ...props }, ref) => (\n \n \n {children}\n \n \n));\n\nToggleGroup.displayName = ToggleGroupPrimitive.Root.displayName;\n\nconst ToggleGroupItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef &\n VariantProps\n>(({ className, children, variant, size, ...props }, ref) => {\n const context = React.useContext(ToggleGroupContext);\n\n return (\n \n {children}\n \n );\n});\n\nToggleGroupItem.displayName = ToggleGroupPrimitive.Item.displayName;\n\nexport { ToggleGroup, ToggleGroupItem };\n","import { ColumnDef, SortDirection } from '@/components/advanced/data-table/data-table.component';\nimport { Button } from '@/components/shadcn-ui/button';\nimport { ToggleGroup, ToggleGroupItem } from '@/components/shadcn-ui/toggle-group';\nimport {\n ArrowDownIcon,\n ArrowUpDownIcon,\n ArrowUpIcon,\n CircleCheckIcon,\n CircleHelpIcon,\n CircleXIcon,\n} from 'lucide-react';\nimport { ReactNode } from 'react';\nimport { InventoryTableData, Status } from './inventory-utils';\n\n/**\n * Gets an icon that indicates the current sorting direction based on the provided input\n *\n * @param sortDirection Sorting direction. Can be ascending ('asc'), descending ('desc') or false (\n * i.e. not sorted)\n * @returns The appropriate sorting icon for the provided sorting direction\n */\nconst getSortingIcon = (sortDirection: false | SortDirection): ReactNode => {\n if (sortDirection === 'asc') {\n return ;\n }\n if (sortDirection === 'desc') {\n return ;\n }\n return ;\n};\n\n/**\n * Function that creates the item column for inventories\n *\n * @param itemLabel Localized label for the item column (e.g. 'Character', 'Repeated Word', etc.)\n * @returns Column that shows the inventory items. Should be used with the DataTable component\n */\nexport const inventoryItemColumn = (itemLabel: string): ColumnDef => {\n return {\n accessorKey: 'item',\n accessorFn: (row: InventoryTableData) => row.items[0],\n header: ({ column }) => (\n \n ),\n };\n};\n\n/**\n * Function that creates the additional item columns for inventories\n *\n * @param additionalItemLabel Localized label for the additional item column (e.g. 'Preceding\n * Marker')\n * @param additionalItemIndex Index that locates the desired item in the items array of the\n * inventory\n * @returns Column that shows additional inventory items. Should be used with the DataTable\n * component\n */\nexport const inventoryAdditionalItemColumn = (\n additionalItemLabel: string,\n additionalItemIndex: number,\n): ColumnDef => {\n return {\n accessorKey: `item${additionalItemIndex}`,\n accessorFn: (row: InventoryTableData) => row.items[additionalItemIndex],\n header: ({ column }) => (\n \n ),\n };\n};\n\n/**\n * Function that creates the count column for inventories. Should be used with the DataTable\n * component.\n *\n * @param itemLabel Localized label for the count column\n * @returns Column that shows the number of occurrences of the related inventory items\n */\nexport const inventoryCountColumn = (countLabel: string): ColumnDef => {\n return {\n accessorKey: 'count',\n header: ({ column }) => (\n
\n \n
\n ),\n cell: ({ row }) =>
{row.getValue('count')}
,\n };\n};\n\n/**\n * Function that updates project settings when status for item(s) changes\n *\n * @param changedItems Array of items for which the status is being updated\n * @param newStatus The status that the items are being given\n * @param approvedItems Array of currently approved items\n * @param onApprovedItemsChange Callback function that stores the updated list of approved items\n * @param unapprovedItems Array of currently unapproved items\n * @param onUnapprovedItemsChange Callback function that stores the updated list of unapproved items\n */\nconst statusChangeHandler = (\n changedItems: string[],\n newStatus: Status,\n approvedItems: string[],\n onApprovedItemsChange: (items: string[]) => void,\n unapprovedItems: string[],\n onUnapprovedItemsChange: (items: string[]) => void,\n) => {\n let newApprovedItems: string[] = [...approvedItems];\n changedItems.forEach((item) => {\n if (newStatus === 'approved') {\n if (!newApprovedItems.includes(item)) {\n newApprovedItems.push(item);\n }\n } else {\n newApprovedItems = newApprovedItems.filter((validItem) => validItem !== item);\n }\n });\n onApprovedItemsChange(newApprovedItems);\n\n let newUnapprovedItems: string[] = [...unapprovedItems];\n changedItems.forEach((item) => {\n if (newStatus === 'unapproved') {\n if (!newUnapprovedItems.includes(item)) {\n newUnapprovedItems.push(item);\n }\n } else {\n newUnapprovedItems = newUnapprovedItems.filter((unapprovedItem) => unapprovedItem !== item);\n }\n });\n onUnapprovedItemsChange(newUnapprovedItems);\n};\n\n/**\n * Function that creates the status column for inventories. Should be used with the DataTable\n * component.\n *\n * @param statusLabel Localized label for the status column\n * @param approvedItems Array of approved items, typically as defined in `Settings.xml`\n * @param onApprovedItemsChange Callback function that stores the updated list of approved items\n * @param unapprovedItems Array of unapproved items, typically as defined in `Settings.xml`\n * @param onUnapprovedItemsChange Callback function that stores the updated list of unapproved items\n * @returns Column that shows the status buttons for the related inventory item. The button for the\n * current status of the item is selected\n */\nexport const inventoryStatusColumn = (\n statusLabel: string,\n approvedItems: string[],\n onApprovedItemsChange: (items: string[]) => void,\n unapprovedItems: string[],\n onUnapprovedItemsChange: (items: string[]) => void,\n): ColumnDef => {\n return {\n accessorKey: 'status',\n header: ({ column }) => {\n return (\n
\n \n
\n );\n },\n cell: ({ row }) => {\n const status: Status = row.getValue('status');\n const item: string = row.getValue('item');\n return (\n \n \n statusChangeHandler(\n [item],\n 'approved',\n approvedItems,\n onApprovedItemsChange,\n unapprovedItems,\n onUnapprovedItemsChange,\n )\n }\n value=\"approved\"\n >\n \n \n \n statusChangeHandler(\n [item],\n 'unapproved',\n approvedItems,\n onApprovedItemsChange,\n unapprovedItems,\n onUnapprovedItemsChange,\n )\n }\n value=\"unapproved\"\n >\n \n \n \n statusChangeHandler(\n [item],\n 'unknown',\n approvedItems,\n onApprovedItemsChange,\n unapprovedItems,\n onUnapprovedItemsChange,\n )\n }\n value=\"unknown\"\n >\n \n \n \n );\n },\n };\n};\n","import DataTable, {\n ColumnDef,\n RowContents,\n RowSelectionState,\n TableContents,\n} from '@/components/advanced/data-table/data-table.component';\nimport OccurrencesTable from '@/components/advanced/inventory/occurrences-table.component';\nimport Checkbox from '@/components/shadcn-ui/checkbox';\nimport { Input } from '@/components/shadcn-ui/input';\nimport { Label } from '@/components/shadcn-ui/label';\nimport {\n Select,\n SelectContent,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\nimport {\n deepEqual,\n LocalizedStringValue,\n ScriptureReference,\n substring,\n} from 'platform-bible-utils';\nimport { useEffect, useMemo, useState } from 'react';\nimport {\n getBookNumFromId,\n getLinesFromUSFM,\n getNumberFromUSFM,\n getStatusForItem,\n InventoryItemOccurrence,\n InventoryTableData,\n Status,\n} from './inventory-utils';\nimport { inventoryAdditionalItemColumn } from './inventory-columns';\n\n/**\n * Object containing all keys used for localization in this component. If you're using this\n * component in an extension, you can pass it into the useLocalizedStrings hook to easily obtain the\n * localized strings and pass them into the localizedStrings prop of this component\n */\nexport const INVENTORY_STRING_KEYS = Object.freeze([\n '%webView_inventory_all%',\n '%webView_inventory_approved%',\n '%webView_inventory_unapproved%',\n '%webView_inventory_unknown%',\n '%webView_inventory_scope_currentBook%',\n '%webView_inventory_scope_chapter%',\n '%webView_inventory_scope_verse%',\n '%webView_inventory_filter_text%',\n '%webView_inventory_show_additional_items%',\n '%webView_inventory_occurrences_table_header_reference%',\n '%webView_inventory_occurrences_table_header_occurrence%',\n] as const);\n\nexport type InventoryLocalizedStrings = {\n [localizedInventoryKey in (typeof INVENTORY_STRING_KEYS)[number]]?: LocalizedStringValue;\n};\n\n/** Scope of scripture that the inventory can operate on */\nexport type Scope = 'book' | 'chapter' | 'verse';\n\n/** Status values that the status filter can select from */\ntype StatusFilter = Status | 'all';\n\n/** Text labels for the inventory columns and the control components of additional inventory items */\ntype AdditionalItemsLabels = {\n checkboxText?: string;\n tableHeaders?: string[];\n};\n\n/**\n * Filters data that is shown in the DataTable section of the Inventory\n *\n * @param itemData All inventory items and their related information\n * @param statusFilter Allows filtering by status (i.e. show all items, or only items that are\n * 'approved', 'unapproved' or 'unknown')\n * @param textFilter Allows filtering by text. All items that include the filter text will be\n * selected.\n * @returns Array of items and their related information that are matched by the specified filters\n */\nconst filterItemData = (\n itemData: InventoryTableData[],\n statusFilter: StatusFilter,\n textFilter: string,\n): InventoryTableData[] => {\n let filteredItemData: InventoryTableData[] = itemData;\n\n if (statusFilter !== 'all') {\n filteredItemData = filteredItemData.filter(\n (item) =>\n (statusFilter === 'approved' && item.status === 'approved') ||\n (statusFilter === 'unapproved' && item.status === 'unapproved') ||\n (statusFilter === 'unknown' && item.status === 'unknown'),\n );\n }\n\n if (textFilter !== '')\n filteredItemData = filteredItemData.filter((item) => item.items[0].includes(textFilter));\n\n return filteredItemData;\n};\n\n/**\n * Turns array of strings into array of inventory items, along with their count and status\n *\n * @param text The source scripture text that is searched for inventory items\n * @param scriptureRef The scripture reference that the application is currently set to\n * @param approvedItems Array of approved items, typically as defined in `Settings.xml`\n * @param unapprovedItems Array of unapproved items, typically as defined in `Settings.xml`\n * @param itemRegex Regular expression that describes what items this Inventory should extract from\n * the provided scripture text\n * @returns Array of inventory items, along with their count and status\n */\nconst createTableData = (\n text: string | undefined,\n scriptureRef: ScriptureReference,\n approvedItems: string[],\n unapprovedItems: string[],\n itemRegex: RegExp,\n): InventoryTableData[] => {\n if (!text) return [];\n\n const tableData: InventoryTableData[] = [];\n\n let currentBook: number | undefined = scriptureRef.bookNum;\n let currentChapter: number | undefined = scriptureRef.chapterNum;\n let currentVerse: number | undefined = scriptureRef.verseNum;\n\n const lines = getLinesFromUSFM(text);\n\n lines.forEach((line: string) => {\n if (line.startsWith('\\\\id')) {\n currentBook = getBookNumFromId(line);\n currentChapter = 0;\n currentVerse = 0;\n }\n if (line.startsWith('\\\\c')) {\n currentChapter = getNumberFromUSFM(line);\n currentVerse = 0;\n }\n if (line.startsWith('\\\\v')) {\n currentVerse = getNumberFromUSFM(line);\n if (currentChapter === 0) {\n currentChapter = scriptureRef.chapterNum;\n }\n }\n\n let match: RegExpExecArray | undefined = itemRegex.exec(line) ?? undefined;\n while (match) {\n const items: string[] = [];\n match.forEach((item) => items.push(item));\n const itemIndex = match.index;\n const existingItem = tableData.find((tableEntry) => deepEqual(tableEntry.items, items));\n const newReference: InventoryItemOccurrence = {\n reference: {\n bookNum: currentBook !== undefined ? currentBook : -1,\n chapterNum: currentChapter !== undefined ? currentChapter : -1,\n verseNum: currentVerse !== undefined ? currentVerse : -1,\n },\n text: substring(line, Math.max(0, itemIndex - 25), Math.min(itemIndex + 25, line.length)),\n };\n if (existingItem) {\n existingItem.count += 1;\n existingItem.occurrences.push(newReference);\n } else {\n const newItem: InventoryTableData = {\n items,\n count: 1,\n status: getStatusForItem(items[0], approvedItems, unapprovedItems),\n occurrences: [newReference],\n };\n tableData.push(newItem);\n }\n\n match = itemRegex.exec(line) ?? undefined;\n }\n });\n\n return tableData;\n};\n\n/**\n * Gets the localized value for the provided key\n *\n * @param strings Object containing localized string\n * @param key Key for a localized string\n * @returns The localized value for the provided key, if available. Returns the key if no localized\n * value is available\n */\nconst localizeString = (\n strings: InventoryLocalizedStrings,\n key: keyof InventoryLocalizedStrings,\n) => {\n return strings[key] ?? key;\n};\n\n/** Props for the Inventory component */\ntype InventoryProps = {\n /** The scripture reference that the application is currently set to */\n scriptureReference: ScriptureReference;\n /** Callback function that is executed when the scripture reference is changed */\n setScriptureReference: (scriptureReference: ScriptureReference) => void;\n /**\n * Object with all localized strings that the Inventory needs to work well across multiple\n * languages. When using this component with Platform.Bible, you can import\n * `INVENTORY_STRING_KEYS` from this library, pass it in to the Platform's localization hook, and\n * pass the localized keys that are returned by the hook into this prop.\n */\n localizedStrings: InventoryLocalizedStrings;\n /**\n * The logic that finds the desired items in the source text. This can either be a Regular\n * expression that captures one or multiple items (preferred), or a custom function that builds\n * and return an InventoryDataTable[] manually. Note: In case the logic captures more than one\n * item (i.e. InventoryTableData.items has a length greater than 1), you must provide text labels\n * for the related columns and control elements to show by setting the `additionalItemsLabels`\n * prop\n */\n extractItems:\n | RegExp\n | ((\n text: string | undefined,\n scriptureRef: ScriptureReference,\n approvedItems: string[],\n unapprovedItems: string[],\n ) => InventoryTableData[]);\n /**\n * Text labels for control elements and additional column headers in case your Inventory has more\n * than one item to show (e.g. The 'Preceding Marker' in the Markers Inventory)\n */\n additionalItemsLabels?: AdditionalItemsLabels;\n /** Array of approved items, typically as defined in `Settings.xml` */\n approvedItems: string[];\n /** Array of unapproved items, typically as defined in `Settings.xml` */\n unapprovedItems: string[];\n /** The source scripture text that is searched for in inventory items */\n text: string | undefined;\n /** Scope of scripture that the inventory will operate on */\n scope: Scope;\n /** Callback function that is executed when the scope is changed from the Inventory */\n onScopeChange: (scope: Scope) => void;\n /**\n * Column definitions for the Inventory data table. The most commonly used column definitions are\n * pre-configured for your convenience and can be imported (e.g. inventoryItemColumn,\n * inventoryAdditionalItemColumn inventoryCountColumn, and inventoryStatusColumn). If you need any\n * other columns you can add these yourself\n */\n columns: ColumnDef[];\n};\n\n/** Inventory component that is used to view and control the status of provided project settings */\nexport default function Inventory({\n scriptureReference,\n setScriptureReference,\n localizedStrings,\n extractItems,\n additionalItemsLabels,\n approvedItems,\n unapprovedItems,\n text,\n scope,\n onScopeChange,\n columns,\n}: InventoryProps) {\n const allItemsText = localizeString(localizedStrings, '%webView_inventory_all%');\n const approvedItemsText = localizeString(localizedStrings, '%webView_inventory_approved%');\n const unapprovedItemsText = localizeString(localizedStrings, '%webView_inventory_unapproved%');\n const unknownItemsText = localizeString(localizedStrings, '%webView_inventory_unknown%');\n const scopeBookText = localizeString(localizedStrings, '%webView_inventory_scope_currentBook%');\n const scopeChapterText = localizeString(localizedStrings, '%webView_inventory_scope_chapter%');\n const scopeVerseText = localizeString(localizedStrings, '%webView_inventory_scope_verse%');\n const filterText = localizeString(localizedStrings, '%webView_inventory_filter_text%');\n const showAdditionalItemsText = localizeString(\n localizedStrings,\n '%webView_inventory_show_additional_items%',\n );\n\n const [showAdditionalItems, setShowAdditionalItems] = useState(false);\n const [statusFilter, setStatusFilter] = useState('all');\n const [textFilter, setTextFilter] = useState('');\n const [selectedItem, setSelectedItem] = useState([]);\n\n const tableData: InventoryTableData[] = useMemo(() => {\n if (!text) return [];\n if (extractItems instanceof RegExp)\n return createTableData(\n text,\n scriptureReference,\n approvedItems,\n unapprovedItems,\n extractItems,\n );\n return extractItems(text, scriptureReference, approvedItems, unapprovedItems);\n }, [text, extractItems, scriptureReference, approvedItems, unapprovedItems]);\n\n const reducedTableData: InventoryTableData[] = useMemo(() => {\n if (showAdditionalItems) return tableData;\n\n const newTableData: InventoryTableData[] = [];\n\n tableData.forEach((tableEntry) => {\n const firstItem = tableEntry.items[0];\n\n const existingEntry = newTableData.find(\n (newTableEntry) => newTableEntry.items[0] === firstItem,\n );\n\n if (existingEntry) {\n existingEntry.count += tableEntry.count;\n existingEntry.occurrences = existingEntry.occurrences.concat(tableEntry.occurrences);\n } else {\n newTableData.push({\n items: [firstItem],\n count: tableEntry.count,\n occurrences: tableEntry.occurrences,\n status: tableEntry.status,\n });\n }\n });\n\n return newTableData;\n }, [showAdditionalItems, tableData]);\n\n const filteredTableData: InventoryTableData[] = useMemo(() => {\n return filterItemData(reducedTableData, statusFilter, textFilter);\n }, [reducedTableData, statusFilter, textFilter]);\n\n const allColumns: ColumnDef[] = useMemo(() => {\n if (!showAdditionalItems) return columns;\n\n const numberOfAdditionalItems = additionalItemsLabels?.tableHeaders?.length;\n if (!numberOfAdditionalItems) return columns;\n\n const additionalColumns: ColumnDef[] = [];\n\n for (let index = 0; index < numberOfAdditionalItems; index++) {\n additionalColumns.push(\n inventoryAdditionalItemColumn(\n additionalItemsLabels?.tableHeaders?.[index] || 'Additional Item',\n index + 1,\n ),\n );\n }\n\n return [...additionalColumns, ...columns];\n }, [additionalItemsLabels?.tableHeaders, columns, showAdditionalItems]);\n\n useEffect(() => {\n setSelectedItem([]);\n }, [filteredTableData]);\n\n const rowClickHandler = (\n row: RowContents,\n table: TableContents,\n ) => {\n table.setRowSelection(() => {\n const newSelection: RowSelectionState = {};\n newSelection[row.index] = true;\n return newSelection;\n });\n\n setSelectedItem(row.original.items);\n };\n\n const handleScopeChange = (value: string) => {\n if (value === 'book' || value === 'chapter' || value === 'verse') {\n onScopeChange(value);\n } else {\n throw new Error(`Invalid scope value: ${value}`);\n }\n };\n\n const handleStatusFilterChange = (value: string) => {\n if (value === 'all' || value === 'approved' || value === 'unapproved' || value === 'unknown') {\n setStatusFilter(value);\n } else {\n throw new Error(`Invalid status filter value: ${value}`);\n }\n };\n\n const occurrenceData: InventoryItemOccurrence[] = useMemo(() => {\n if (reducedTableData.length === 0 || selectedItem.length === 0) return [];\n const occurrence = reducedTableData.filter((tableEntry: InventoryTableData) => {\n return deepEqual(\n showAdditionalItems ? tableEntry.items : [tableEntry.items[0]],\n selectedItem,\n );\n });\n if (occurrence.length > 1) throw new Error('Selected item is not unique');\n return occurrence[0].occurrences;\n }, [selectedItem, showAdditionalItems, reducedTableData]);\n\n return (\n
\n
\n handleStatusFilterChange(value)}\n defaultValue={statusFilter}\n >\n \n \n \n \n {allItemsText}\n {approvedItemsText}\n {unapprovedItemsText}\n {unknownItemsText}\n \n \n \n {\n setTextFilter(event.target.value);\n }}\n />\n {additionalItemsLabels && (\n
\n {\n setSelectedItem([]);\n setShowAdditionalItems(checked);\n }}\n />\n \n
\n )}\n
\n
\n \n
\n {occurrenceData.length > 0 && (\n
\n \n
\n )}\n
\n );\n}\n","import { Input } from '@/components/shadcn-ui/input';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { useState } from 'react';\n\nexport type SearchBarProps = {\n /**\n * Callback fired to handle the search query when button pressed\n *\n * @param searchQuery\n */\n onSearch: (searchQuery: string) => void;\n\n /** Optional string that appears in the search bar without a search string */\n placeholder?: string;\n\n /** Optional boolean to set the input base to full width */\n isFullWidth?: boolean;\n};\n\nexport default function SearchBar({ onSearch, placeholder, isFullWidth }: SearchBarProps) {\n const [searchQuery, setSearchQuery] = useState('');\n\n const handleInputChange = (searchString: string) => {\n setSearchQuery(searchString);\n onSearch(searchString);\n };\n\n return (\n handleInputChange(e.target.value)}\n />\n );\n}\n","// adapted from: https://github.com/shadcn-ui/ui/discussions/752\n\n'use client';\n\nimport { TabsContentProps, TabsListProps, TabsTriggerProps } from '@/components/shadcn-ui/tabs';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport * as TabsPrimitive from '@radix-ui/react-tabs';\nimport React from 'react';\n\nexport type VerticalTabsProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport type LeftTabsTriggerProps = TabsTriggerProps & {\n value: string;\n ref?: React.Ref;\n};\n\nexport const VerticalTabs = React.forwardRef<\n React.ElementRef,\n VerticalTabsProps\n>(({ className, ...props }, ref) => (\n \n));\n\nVerticalTabs.displayName = TabsPrimitive.List.displayName;\n\nexport const VerticalTabsList = React.forwardRef<\n React.ElementRef,\n TabsListProps\n>(({ className, ...props }, ref) => (\n \n));\nVerticalTabsList.displayName = TabsPrimitive.List.displayName;\n\nexport const VerticalTabsTrigger = React.forwardRef<\n React.ElementRef,\n LeftTabsTriggerProps\n>(({ className, ...props }, ref) => (\n \n));\n\nexport const VerticalTabsContent = React.forwardRef<\n React.ElementRef,\n TabsContentProps\n>(({ className, ...props }, ref) => (\n \n));\nVerticalTabsContent.displayName = TabsPrimitive.Content.displayName;\n","import SearchBar from '@/components/basics/search-bar.component';\nimport {\n VerticalTabs,\n VerticalTabsContent,\n VerticalTabsList,\n VerticalTabsTrigger,\n} from '@/components/basics/tabs-vertical';\nimport { ReactNode } from 'react';\n\nexport type TabKeyValueContent = {\n key: string;\n value: string;\n content: ReactNode;\n};\n\nexport type NavigationContentSearchProps = {\n /** List of values and keys for each tab this component should provide */\n tabList: TabKeyValueContent[];\n\n /** Handler to run when the value of the search bar changes */\n onSearch: (searchQuery: string) => void;\n\n /** Optional placeholder for the search bar */\n searchPlaceholder?: string;\n\n /** Optional title to include in the header */\n headerTitle?: string;\n\n /** Optional flag to make the search bar appear full width */\n isSearchBarFullWidth?: boolean;\n\n /** Text direction ltr or rtl */\n direction?: 'ltr' | 'rtl';\n};\n\nexport default function NavigationContentSearch({\n tabList,\n onSearch,\n searchPlaceholder,\n headerTitle,\n isSearchBarFullWidth = false,\n direction = 'ltr',\n}: NavigationContentSearchProps) {\n return (\n
\n
\n {headerTitle ?

{headerTitle}

: ''}\n \n
\n \n \n {tabList.map((tab) => (\n \n {tab.value}\n \n ))}\n \n {tabList.map((tab) => (\n \n {tab.content}\n \n ))}\n \n
\n );\n}\n","import { Button } from '@/components/shadcn-ui/button';\nimport {\n Select,\n SelectContent,\n SelectGroup,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\nimport {\n Table,\n TableBody,\n TableCell,\n TableHead,\n TableHeader,\n TableRow,\n} from '@/components/shadcn-ui/table';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Canon } from '@sillsdev/scripture';\nimport {\n Cell,\n ColumnDef,\n flexRender,\n getCoreRowModel,\n getExpandedRowModel,\n getGroupedRowModel,\n getSortedRowModel,\n GroupingState,\n Row,\n RowSelectionState,\n SortingState,\n useReactTable,\n} from '@tanstack/react-table';\nimport '@/components/advanced/scripture-results-viewer/scripture-results-viewer.component.css';\nimport {\n compareScrRefs,\n formatScrRef,\n ScriptureSelection,\n scrRefToBBBCCCVVV,\n} from 'platform-bible-utils';\nimport { MouseEvent, useEffect, useMemo, useState } from 'react';\nimport { ChevronDown, ChevronLeft, ChevronRight } from 'lucide-react';\n\n/**\n * Information (e.g., a checking error or some other type of \"transient\" annotation) about something\n * noteworthy at a specific place in an instance of the Scriptures.\n */\nexport type ScriptureItemDetail = ScriptureSelection & {\n /**\n * Text of the error, note, etc. In the future, we might want to support something more than just\n * text so that a JSX element could be provided with a link or some other controls related to the\n * issue being reported.\n */\n detail: string;\n};\n\n/**\n * A uniquely identifiable source of results that can be displayed in the ScriptureResultsViewer.\n * Generally, the source will be a particular Scripture check, but there may be other types of\n * sources.\n */\nexport type ResultsSource = {\n /**\n * Uniquely identifies the source.\n *\n * @type {string}\n */\n id: string;\n\n /**\n * Name (potentially localized) of the source, suitable for display in the UI.\n *\n * @type {string}\n */\n displayName: string;\n};\n\nexport type ScriptureSrcItemDetail = ScriptureItemDetail & {\n /** Source/type of detail. Can be used for grouping. */\n source: ResultsSource;\n};\n\n/**\n * Represents a set of results keyed by Scripture reference. Generally, the source will be a\n * particular Scripture check, but this type also allows for other types of uniquely identifiable\n * sources.\n */\nexport type ResultsSet = {\n /**\n * The backing source associated with this set of results.\n *\n * @type {ResultsSource}\n */\n source: ResultsSource;\n\n /**\n * Array of Scripture item details (messages keyed by Scripture reference).\n *\n * @type {ScriptureItemDetail[]}\n */\n data: ScriptureItemDetail[];\n};\n\nconst scrBookColId = 'scrBook';\nconst scrRefColId = 'scrRef';\nconst typeColId = 'source';\nconst detailsColId = 'details';\n\nconst defaultScrRefColumnName = 'Scripture Reference';\nconst defaultScrBookGroupName = 'Scripture Book';\nconst defaultTypeColumnName = 'Type';\nconst defaultDetailsColumnName = 'Details';\n\nexport type ScriptureResultsViewerColumnInfo = {\n /** Optional header to display for the Reference column. Default value: 'Scripture Reference'. */\n scriptureReferenceColumnName?: string;\n\n /** Optional text to display to refer to the Scripture book group. Default value: 'Scripture Book'. */\n scriptureBookGroupName?: string;\n\n /** Optional header to display for the Type column. Default value: 'Type'. */\n typeColumnName?: string;\n\n /** Optional header to display for the Details column. Default value: 'Details' */\n detailsColumnName?: string;\n};\n\nexport type ScriptureResultsViewerProps = ScriptureResultsViewerColumnInfo & {\n /** Groups of ScriptureItemDetail objects from particular sources (e.g., Scripture checks) */\n sources: ResultsSet[];\n\n /** Flag indicating whether to display column headers. Default is false. */\n showColumnHeaders?: boolean;\n\n /** Flag indicating whether to display source column. Default is false. */\n showSourceColumn?: boolean;\n\n /** Callback function to notify when a row is selected */\n onRowSelected?: (selectedRow: ScriptureSrcItemDetail | undefined) => void;\n\n /** Text direction ltr or rtl */\n direction?: 'ltr' | 'rtl';\n};\n\nfunction getColumns(\n colInfo?: ScriptureResultsViewerColumnInfo,\n showSourceColumn?: boolean,\n): ColumnDef[] {\n const showSrcCol = showSourceColumn ?? false;\n return [\n {\n accessorFn: (row) =>\n `${Canon.bookNumberToId(row.start.bookNum)} ${row.start.chapterNum}:${row.start.verseNum}`,\n id: scrBookColId,\n header: colInfo?.scriptureReferenceColumnName ?? defaultScrRefColumnName,\n cell: (info) => {\n const row = info.row.original;\n if (info.row.getIsGrouped()) {\n return Canon.bookNumberToEnglishName(row.start.bookNum);\n }\n return info.row.groupingColumnId === scrBookColId ? formatScrRef(row.start) : undefined;\n },\n getGroupingValue: (row) => row.start.bookNum,\n sortingFn: (a, b) => {\n return compareScrRefs(a.original.start, b.original.start);\n },\n enableGrouping: true,\n },\n {\n accessorFn: (row) => formatScrRef(row.start),\n id: scrRefColId,\n header: undefined,\n cell: (info) => {\n const row = info.row.original;\n return info.row.getIsGrouped() ? undefined : formatScrRef(row.start);\n },\n sortingFn: (a, b) => {\n return compareScrRefs(a.original.start, b.original.start);\n },\n enableGrouping: false,\n },\n {\n accessorFn: (row) => row.source.displayName,\n id: typeColId,\n header: showSrcCol ? (colInfo?.typeColumnName ?? defaultTypeColumnName) : undefined,\n cell: (info) => (showSrcCol || info.row.getIsGrouped() ? info.getValue() : undefined),\n getGroupingValue: (row) => row.source.id,\n sortingFn: (a, b) =>\n a.original.source.displayName.localeCompare(b.original.source.displayName),\n enableGrouping: true,\n },\n {\n accessorFn: (row) => row.detail,\n id: detailsColId,\n header: colInfo?.detailsColumnName ?? defaultDetailsColumnName,\n cell: (info) => info.getValue(),\n enableGrouping: false,\n },\n ];\n}\n\nconst toRefOrRange = (scriptureSelection: ScriptureSelection) => {\n if (!('offset' in scriptureSelection.start))\n throw new Error('No offset available in range start');\n if (scriptureSelection.end && !('offset' in scriptureSelection.end))\n throw new Error('No offset available in range end');\n const { offset: offsetStart } = scriptureSelection.start;\n let offsetEnd: number = 0;\n if (scriptureSelection.end) ({ offset: offsetEnd } = scriptureSelection.end);\n if (\n !scriptureSelection.end ||\n compareScrRefs(scriptureSelection.start, scriptureSelection.end) === 0\n )\n return `${scrRefToBBBCCCVVV(scriptureSelection.start)}+${offsetStart}`;\n return `${scrRefToBBBCCCVVV(scriptureSelection.start)}+${offsetStart}-${scrRefToBBBCCCVVV(scriptureSelection.end)}+${offsetEnd}`;\n};\n\nconst getRowKey = (row: ScriptureSrcItemDetail) =>\n `${toRefOrRange({ start: row.start, end: row.end })} ${row.source.displayName} ${row.detail}`;\n\n/**\n * Component to display a combined list of detailed items from one or more sources, where the items\n * are keyed primarily by Scripture reference. This is particularly useful for displaying a list of\n * results from Scripture checks, but more generally could be used to display any \"results\" from any\n * source(s). The component allows for grouping by Scripture book, source, or both. By default, it\n * displays somewhat \"tree-like\" which allows it to be more horizontally compact and intuitive. But\n * it also has the option of displaying as a traditional table with column headings (with or without\n * the source column showing).\n */\nexport default function ScriptureResultsViewer({\n sources,\n showColumnHeaders = false,\n showSourceColumn = false,\n scriptureReferenceColumnName,\n scriptureBookGroupName,\n typeColumnName,\n detailsColumnName,\n onRowSelected,\n direction = 'ltr',\n}: ScriptureResultsViewerProps) {\n const [grouping, setGrouping] = useState([]);\n const [sorting, setSorting] = useState([{ id: scrBookColId, desc: false }]);\n const [rowSelection, setRowSelection] = useState({});\n\n const scriptureResults = useMemo(\n () =>\n sources.flatMap((source) => {\n return source.data.map((item) => ({\n ...item,\n source: source.source,\n }));\n }),\n [sources],\n );\n\n const columns = useMemo(\n () =>\n getColumns(\n {\n scriptureReferenceColumnName,\n typeColumnName,\n detailsColumnName,\n },\n showSourceColumn,\n ),\n [scriptureReferenceColumnName, typeColumnName, detailsColumnName, showSourceColumn],\n );\n\n useEffect(() => {\n // Ensure sorting is applied correctly when grouped by type\n if (grouping.includes(typeColId)) {\n setSorting([\n { id: typeColId, desc: false },\n { id: scrBookColId, desc: false },\n ]);\n } else {\n setSorting([{ id: scrBookColId, desc: false }]);\n }\n }, [grouping]);\n\n const table = useReactTable({\n data: scriptureResults,\n columns,\n state: {\n grouping,\n sorting,\n rowSelection,\n },\n onGroupingChange: setGrouping,\n onSortingChange: setSorting,\n onRowSelectionChange: setRowSelection,\n getExpandedRowModel: getExpandedRowModel(),\n getGroupedRowModel: getGroupedRowModel(),\n getCoreRowModel: getCoreRowModel(),\n getSortedRowModel: getSortedRowModel(),\n getRowId: getRowKey,\n autoResetExpanded: false,\n enableMultiRowSelection: false,\n enableSubRowSelection: false,\n });\n\n useEffect(() => {\n if (onRowSelected) {\n const selectedRows = table.getSelectedRowModel().rowsById;\n const keys = Object.keys(selectedRows);\n if (keys.length === 1) {\n const selectedRow = scriptureResults.find((row) => getRowKey(row) === keys[0]) || undefined;\n if (selectedRow) onRowSelected(selectedRow);\n }\n }\n }, [rowSelection, scriptureResults, onRowSelected, table]);\n\n // Define possible grouping options\n const scrBookGroupName = scriptureBookGroupName ?? defaultScrBookGroupName;\n const typeGroupName = typeColumnName ?? defaultTypeColumnName;\n\n const groupingOptions = [\n { label: 'No Grouping', value: [] },\n { label: `Group by ${scrBookGroupName}`, value: [scrBookColId] },\n { label: `Group by ${typeGroupName}`, value: [typeColId] },\n {\n label: `Group by ${scrBookGroupName} and ${typeGroupName}`,\n value: [scrBookColId, typeColId],\n },\n {\n label: `Group by ${typeGroupName} and ${scrBookGroupName}`,\n value: [typeColId, scrBookColId],\n },\n ];\n\n const handleSelectChange = (selectedGrouping: string) => {\n setGrouping(JSON.parse(selectedGrouping));\n };\n\n const handleRowClick = (row: Row, event: MouseEvent) => {\n if (!row.getIsGrouped() && !row.getIsSelected()) {\n row.getToggleSelectedHandler()(event);\n }\n };\n\n const getEvenOrOddBandingStyle = (row: Row, index: number) => {\n if (row.getIsGrouped()) return '';\n // UX has now said they don't think they want banding. I'm leaving in the code to\n // set even and odd styles, but there's nothing in the CSS to style them differently.\n // The \"even\" style used to also have tw-bg-neutral-300 (along with even) to create\n // a visual banding effect. That could be added back in if UX changes the decision.\n return cn('banded-row', index % 2 === 0 ? 'even' : 'odd');\n };\n\n const getIndent = (\n groupingState: GroupingState,\n row: Row,\n cell: Cell,\n ) => {\n if (groupingState?.length === 0 || row.depth < cell.column.getGroupedIndex()) return undefined;\n if (row.getIsGrouped()) {\n switch (row.depth) {\n case 1:\n return 'tw-ps-4';\n default:\n return undefined;\n }\n }\n switch (row.depth) {\n case 1:\n return 'tw-ps-8';\n case 2:\n return 'tw-ps-12';\n default:\n return undefined;\n }\n };\n\n return (\n
\n {!showColumnHeaders && (\n {\n handleSelectChange(value);\n }}\n >\n \n \n \n \n \n {groupingOptions.map((option) => (\n \n {option.label}\n \n ))}\n \n \n \n )}\n \n {showColumnHeaders && (\n \n {table.getHeaderGroups().map((headerGroup) => (\n \n {headerGroup.headers\n .filter((h) => h.column.columnDef.header)\n .map((header) => (\n /* For sticky column headers to work, we probably need to change the default definition of the shadcn Table component. See https://github.com/shadcn-ui/ui/issues/1151 */\n \n {header.isPlaceholder ? undefined : (\n
\n {header.column.getCanGroup() ? (\n \n {header.column.getIsGrouped() ? `🛑` : `👊 `}\n \n ) : undefined}{' '}\n {flexRender(header.column.columnDef.header, header.getContext())}\n
\n )}\n
\n ))}\n
\n ))}\n
\n )}\n \n {table.getRowModel().rows.map((row, rowIndex) => {\n return (\n handleRowClick(row, event)}\n >\n {row.getVisibleCells().map((cell) => {\n if (\n cell.getIsPlaceholder() ||\n (cell.column.columnDef.enableGrouping &&\n !cell.getIsGrouped() &&\n (cell.column.columnDef.id !== typeColId || !showSourceColumn))\n )\n return undefined;\n return (\n \n {(() => {\n if (cell.getIsGrouped()) {\n return (\n \n {row.getIsExpanded() && }\n {!row.getIsExpanded() &&\n (direction === 'ltr' ? : )}{' '}\n {flexRender(cell.column.columnDef.cell, cell.getContext())} (\n {row.subRows.length})\n \n );\n }\n\n // if (cell.getIsAggregated()) {\n // flexRender(\n // cell.column.columnDef.aggregatedCell ?? cell.column.columnDef.cell,\n // cell.getContext(),\n // );\n // }\n\n return flexRender(cell.column.columnDef.cell, cell.getContext());\n })()}\n \n );\n })}\n \n );\n })}\n \n
\n
\n );\n}\n","import {\n getLocalizeKeyForScrollGroupId,\n LanguageStrings,\n ScrollGroupId,\n} from 'platform-bible-utils';\nimport {\n Select,\n SelectContent,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\n\nconst DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS = {\n [getLocalizeKeyForScrollGroupId('undefined')]: 'Ø',\n [getLocalizeKeyForScrollGroupId(0)]: 'A',\n [getLocalizeKeyForScrollGroupId(1)]: 'B',\n [getLocalizeKeyForScrollGroupId(2)]: 'C',\n [getLocalizeKeyForScrollGroupId(3)]: 'D',\n [getLocalizeKeyForScrollGroupId(4)]: 'E',\n [getLocalizeKeyForScrollGroupId(5)]: 'F',\n [getLocalizeKeyForScrollGroupId(6)]: 'G',\n [getLocalizeKeyForScrollGroupId(7)]: 'H',\n [getLocalizeKeyForScrollGroupId(8)]: 'I',\n [getLocalizeKeyForScrollGroupId(9)]: 'J',\n [getLocalizeKeyForScrollGroupId(10)]: 'K',\n [getLocalizeKeyForScrollGroupId(11)]: 'L',\n [getLocalizeKeyForScrollGroupId(12)]: 'M',\n [getLocalizeKeyForScrollGroupId(13)]: 'N',\n [getLocalizeKeyForScrollGroupId(14)]: 'O',\n [getLocalizeKeyForScrollGroupId(15)]: 'P',\n [getLocalizeKeyForScrollGroupId(16)]: 'Q',\n [getLocalizeKeyForScrollGroupId(17)]: 'R',\n [getLocalizeKeyForScrollGroupId(18)]: 'S',\n [getLocalizeKeyForScrollGroupId(19)]: 'T',\n [getLocalizeKeyForScrollGroupId(20)]: 'U',\n [getLocalizeKeyForScrollGroupId(21)]: 'V',\n [getLocalizeKeyForScrollGroupId(22)]: 'W',\n [getLocalizeKeyForScrollGroupId(23)]: 'X',\n [getLocalizeKeyForScrollGroupId(24)]: 'Y',\n [getLocalizeKeyForScrollGroupId(25)]: 'Z',\n};\n\nexport type ScrollGroupSelectorProps = {\n /**\n * List of scroll group ids to show to the user. Either a {@link ScrollGroupId} or `undefined` for\n * no scroll group\n */\n availableScrollGroupIds: (ScrollGroupId | undefined)[];\n /** Currently selected scroll group id. `undefined` for no scroll group */\n scrollGroupId: ScrollGroupId | undefined;\n /** Callback function run when the user tries to change the scroll group id */\n onChangeScrollGroupId: (newScrollGroupId: ScrollGroupId | undefined) => void;\n /**\n * Localized strings to use for displaying scroll group ids. Must be an object whose keys are\n * `getLocalizeKeyForScrollGroupId(scrollGroupId)` for all scroll group ids (and `undefined` if\n * included) in {@link ScrollGroupSelectorProps.availableScrollGroupIds} and whose values are the\n * localized strings to use for those scroll group ids.\n *\n * Defaults to English localizations of English alphabet for scroll groups 0-25 (e.g. 0 is A) and\n * Ø for `undefined`. Will fill in any that are not provided with these English localizations.\n * Also, if any values match the keys, the English localization will be used. This is useful in\n * case you want to pass in a temporary version of the localized strings while your localized\n * strings load.\n *\n * @example\n *\n * ```typescript\n * const myScrollGroupIdLocalizedStrings = {\n * [getLocalizeKeyForScrollGroupId('undefined')]: 'Ø',\n * [getLocalizeKeyForScrollGroupId(0)]: 'A',\n * [getLocalizeKeyForScrollGroupId(1)]: 'B',\n * [getLocalizeKeyForScrollGroupId(2)]: 'C',\n * [getLocalizeKeyForScrollGroupId(3)]: 'D',\n * [getLocalizeKeyForScrollGroupId(4)]: 'E',\n * };\n * ```\n *\n * @example\n *\n * ```tsx\n * const availableScrollGroupIds = [undefined, 0, 1, 2, 3, 4];\n *\n * const localizeKeys = getLocalizeKeysForScrollGroupIds();\n *\n * const [localizedStrings] = useLocalizedStrings(localizeKeys);\n *\n * ...\n *\n * \n * ```\n */\n localizedStrings?: LanguageStrings;\n};\n\n/** Selector component for choosing a scroll group */\nexport default function ScrollGroupSelector({\n availableScrollGroupIds,\n scrollGroupId,\n onChangeScrollGroupId,\n localizedStrings = {},\n}: ScrollGroupSelectorProps) {\n const localizedStringsDefaulted = {\n ...DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS,\n ...Object.fromEntries(\n Object.entries(localizedStrings).map(\n ([localizedStringKey, localizedStringValue]: [string, string]) => [\n localizedStringKey,\n localizedStringKey === localizedStringValue &&\n localizedStringKey in DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS\n ? DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS[localizedStringKey]\n : localizedStringValue,\n ],\n ),\n ),\n };\n return (\n \n onChangeScrollGroupId(\n newScrollGroupString === 'undefined' ? undefined : parseInt(newScrollGroupString, 10),\n )\n }\n >\n \n \n \n \n {availableScrollGroupIds.map((scrollGroupOptionId) => (\n \n {localizedStringsDefaulted[getLocalizeKeyForScrollGroupId(scrollGroupOptionId)]}\n \n ))}\n \n \n );\n}\n","import React from 'react';\nimport * as SeparatorPrimitive from '@radix-ui/react-separator';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Separator = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, orientation = 'horizontal', decorative = true, ...props }, ref) => (\n \n));\nSeparator.displayName = SeparatorPrimitive.Root.displayName;\n\nexport { Separator };\n","import { PropsWithChildren } from 'react';\nimport { Separator } from '@/components/shadcn-ui/separator';\n\n/** Props for the SettingsList component, currently just children */\ntype SettingsListProps = PropsWithChildren;\n\n/**\n * SettingsList component is a wrapper for list items. Rendered with a formatted div\n *\n * @param children To populate the list with\n * @returns Formatted div encompassing the children\n */\nexport function SettingsList({ children }: SettingsListProps) {\n return
{children}
;\n}\n\n/** Props for SettingsListItem component */\ntype SettingsListItemProps = PropsWithChildren & {\n /** Primary text of the list item */\n primary: string;\n\n /** Optional text of the list item */\n secondary?: string | undefined;\n\n /** Optional boolean to display a message if the children aren't loaded yet. Defaults to false */\n isLoading?: boolean;\n\n /** Optional message to display if isLoading */\n loadingMessage?: string;\n};\n\n/**\n * SettingsListItem component is a common list item. Rendered with a formatted div\n *\n * @param primary Primary text of the list item\n * @param secondary Optional secondary text of the list item\n * @param isLoading Optional, to display a message if the action component isn't generated yet,\n * defaults to false\n * @param children The action component(s) to provide for this item\n * @param loadingMessage Optional, message to display if isLoading\n * @returns Formatted div encompassing the list item content\n */\nexport function SettingsListItem({\n primary,\n secondary,\n children,\n isLoading = false,\n loadingMessage,\n}: SettingsListItemProps) {\n return (\n
\n
\n

{primary}

\n

\n {secondary}\n

\n
\n\n {isLoading ? (\n

{loadingMessage}

\n ) : (\n
{children}
\n )}\n
\n );\n}\n\n/** Props for SettingsListHeader component */\ntype SettingsListHeaderProps = {\n /** The primary text of the list header */\n primary: string;\n\n /** Optional secondary text of the list header */\n secondary?: string | undefined;\n\n /** Optional boolean to include a separator underneath the secondary text. Defaults to false */\n includeSeparator?: boolean;\n};\n\n/**\n * SettingsListHeader component displays text above the list\n *\n * @param primary The primary text of the list header\n * @param secondary Optional secondary text of the list header\n * @param includeSeparator Optional boolean to include a separator underneath the secondary text.\n * Defaults to false\n * @returns Formatted div with list header content\n */\nexport function SettingsListHeader({\n primary,\n secondary,\n includeSeparator = false,\n}: SettingsListHeaderProps) {\n return (\n
\n
\n

{primary}

\n

{secondary}

\n
\n {includeSeparator ? : ''}\n
\n );\n}\n","import Checkbox from '@/components/shadcn-ui/checkbox';\nimport { Label } from '@/components/shadcn-ui/label';\n\nexport type ChecklistProps = {\n /** Optional string representing the id attribute of the Checklist */\n id?: string;\n /** Optional string representing CSS class name(s) for styling */\n className?: string;\n /** Array of strings representing the checkable items */\n listItems: string[];\n /** Array of strings representing the checked items */\n selectedListItems: string[];\n /**\n * Function that is called when a checkbox item is selected or deselected\n *\n * @param item The string description for this item\n * @param selected True if selected, false if not selected\n */\n handleSelectListItem: (item: string, selected: boolean) => void;\n\n /**\n * Optional function creates a label for a provided checkable item\n *\n * @param item The item for which a label is to be created\n * @returns A string representing the label text for the checkbox associated with that item\n */\n createLabel?: (item: string) => string;\n};\n\n/** Renders a list of checkboxes. Each checkbox corresponds to an item from the `listItems` array. */\nexport default function Checklist({\n id,\n className,\n listItems,\n selectedListItems,\n handleSelectListItem,\n createLabel,\n}: ChecklistProps) {\n return (\n
\n {listItems.map((item) => (\n
\n handleSelectListItem(item, value)}\n />\n \n
\n ))}\n
\n );\n}\n","function _interopRequireDefault(obj) {\n return obj && obj.__esModule ? obj : {\n \"default\": obj\n };\n}\nmodule.exports = _interopRequireDefault, module.exports.__esModule = true, module.exports[\"default\"] = module.exports;","export default function chainPropTypes(propType1, propType2) {\n if (process.env.NODE_ENV === 'production') {\n return () => null;\n }\n return function validate(...args) {\n return propType1(...args) || propType2(...args);\n };\n}","export default function _extends() {\n _extends = Object.assign ? Object.assign.bind() : function (target) {\n for (var i = 1; i < arguments.length; i++) {\n var source = arguments[i];\n for (var key in source) {\n if (Object.prototype.hasOwnProperty.call(source, key)) {\n target[key] = source[key];\n }\n }\n }\n return target;\n };\n return _extends.apply(this, arguments);\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\n// https://github.com/sindresorhus/is-plain-obj/blob/main/index.js\nexport function isPlainObject(item) {\n if (typeof item !== 'object' || item === null) {\n return false;\n }\n const prototype = Object.getPrototypeOf(item);\n return (prototype === null || prototype === Object.prototype || Object.getPrototypeOf(prototype) === null) && !(Symbol.toStringTag in item) && !(Symbol.iterator in item);\n}\nfunction deepClone(source) {\n if (!isPlainObject(source)) {\n return source;\n }\n const output = {};\n Object.keys(source).forEach(key => {\n output[key] = deepClone(source[key]);\n });\n return output;\n}\nexport default function deepmerge(target, source, options = {\n clone: true\n}) {\n const output = options.clone ? _extends({}, target) : target;\n if (isPlainObject(target) && isPlainObject(source)) {\n Object.keys(source).forEach(key => {\n // Avoid prototype pollution\n if (key === '__proto__') {\n return;\n }\n if (isPlainObject(source[key]) && key in target && isPlainObject(target[key])) {\n // Since `output` is a clone of `target` and we have narrowed `target` in this block we can cast to the same type.\n output[key] = deepmerge(target[key], source[key], options);\n } else if (options.clone) {\n output[key] = isPlainObject(source[key]) ? deepClone(source[key]) : source[key];\n } else {\n output[key] = source[key];\n }\n });\n }\n return output;\n}","/** @license React v16.13.1\n * react-is.production.min.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';var b=\"function\"===typeof Symbol&&Symbol.for,c=b?Symbol.for(\"react.element\"):60103,d=b?Symbol.for(\"react.portal\"):60106,e=b?Symbol.for(\"react.fragment\"):60107,f=b?Symbol.for(\"react.strict_mode\"):60108,g=b?Symbol.for(\"react.profiler\"):60114,h=b?Symbol.for(\"react.provider\"):60109,k=b?Symbol.for(\"react.context\"):60110,l=b?Symbol.for(\"react.async_mode\"):60111,m=b?Symbol.for(\"react.concurrent_mode\"):60111,n=b?Symbol.for(\"react.forward_ref\"):60112,p=b?Symbol.for(\"react.suspense\"):60113,q=b?\nSymbol.for(\"react.suspense_list\"):60120,r=b?Symbol.for(\"react.memo\"):60115,t=b?Symbol.for(\"react.lazy\"):60116,v=b?Symbol.for(\"react.block\"):60121,w=b?Symbol.for(\"react.fundamental\"):60117,x=b?Symbol.for(\"react.responder\"):60118,y=b?Symbol.for(\"react.scope\"):60119;\nfunction z(a){if(\"object\"===typeof a&&null!==a){var u=a.$$typeof;switch(u){case c:switch(a=a.type,a){case l:case m:case e:case g:case f:case p:return a;default:switch(a=a&&a.$$typeof,a){case k:case n:case t:case r:case h:return a;default:return u}}case d:return u}}}function A(a){return z(a)===m}exports.AsyncMode=l;exports.ConcurrentMode=m;exports.ContextConsumer=k;exports.ContextProvider=h;exports.Element=c;exports.ForwardRef=n;exports.Fragment=e;exports.Lazy=t;exports.Memo=r;exports.Portal=d;\nexports.Profiler=g;exports.StrictMode=f;exports.Suspense=p;exports.isAsyncMode=function(a){return A(a)||z(a)===l};exports.isConcurrentMode=A;exports.isContextConsumer=function(a){return z(a)===k};exports.isContextProvider=function(a){return z(a)===h};exports.isElement=function(a){return\"object\"===typeof a&&null!==a&&a.$$typeof===c};exports.isForwardRef=function(a){return z(a)===n};exports.isFragment=function(a){return z(a)===e};exports.isLazy=function(a){return z(a)===t};\nexports.isMemo=function(a){return z(a)===r};exports.isPortal=function(a){return z(a)===d};exports.isProfiler=function(a){return z(a)===g};exports.isStrictMode=function(a){return z(a)===f};exports.isSuspense=function(a){return z(a)===p};\nexports.isValidElementType=function(a){return\"string\"===typeof a||\"function\"===typeof a||a===e||a===m||a===g||a===f||a===p||a===q||\"object\"===typeof a&&null!==a&&(a.$$typeof===t||a.$$typeof===r||a.$$typeof===h||a.$$typeof===k||a.$$typeof===n||a.$$typeof===w||a.$$typeof===x||a.$$typeof===y||a.$$typeof===v)};exports.typeOf=z;\n","/** @license React v16.13.1\n * react-is.development.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\n\n\nif (process.env.NODE_ENV !== \"production\") {\n (function() {\n'use strict';\n\n// The Symbol used to tag the ReactElement-like types. If there is no native Symbol\n// nor polyfill, then a plain number is used for performance.\nvar hasSymbol = typeof Symbol === 'function' && Symbol.for;\nvar REACT_ELEMENT_TYPE = hasSymbol ? Symbol.for('react.element') : 0xeac7;\nvar REACT_PORTAL_TYPE = hasSymbol ? Symbol.for('react.portal') : 0xeaca;\nvar REACT_FRAGMENT_TYPE = hasSymbol ? Symbol.for('react.fragment') : 0xeacb;\nvar REACT_STRICT_MODE_TYPE = hasSymbol ? Symbol.for('react.strict_mode') : 0xeacc;\nvar REACT_PROFILER_TYPE = hasSymbol ? Symbol.for('react.profiler') : 0xead2;\nvar REACT_PROVIDER_TYPE = hasSymbol ? Symbol.for('react.provider') : 0xeacd;\nvar REACT_CONTEXT_TYPE = hasSymbol ? Symbol.for('react.context') : 0xeace; // TODO: We don't use AsyncMode or ConcurrentMode anymore. They were temporary\n// (unstable) APIs that have been removed. Can we remove the symbols?\n\nvar REACT_ASYNC_MODE_TYPE = hasSymbol ? Symbol.for('react.async_mode') : 0xeacf;\nvar REACT_CONCURRENT_MODE_TYPE = hasSymbol ? Symbol.for('react.concurrent_mode') : 0xeacf;\nvar REACT_FORWARD_REF_TYPE = hasSymbol ? Symbol.for('react.forward_ref') : 0xead0;\nvar REACT_SUSPENSE_TYPE = hasSymbol ? Symbol.for('react.suspense') : 0xead1;\nvar REACT_SUSPENSE_LIST_TYPE = hasSymbol ? Symbol.for('react.suspense_list') : 0xead8;\nvar REACT_MEMO_TYPE = hasSymbol ? Symbol.for('react.memo') : 0xead3;\nvar REACT_LAZY_TYPE = hasSymbol ? Symbol.for('react.lazy') : 0xead4;\nvar REACT_BLOCK_TYPE = hasSymbol ? Symbol.for('react.block') : 0xead9;\nvar REACT_FUNDAMENTAL_TYPE = hasSymbol ? Symbol.for('react.fundamental') : 0xead5;\nvar REACT_RESPONDER_TYPE = hasSymbol ? Symbol.for('react.responder') : 0xead6;\nvar REACT_SCOPE_TYPE = hasSymbol ? Symbol.for('react.scope') : 0xead7;\n\nfunction isValidElementType(type) {\n return typeof type === 'string' || typeof type === 'function' || // Note: its typeof might be other than 'symbol' or 'number' if it's a polyfill.\n type === REACT_FRAGMENT_TYPE || type === REACT_CONCURRENT_MODE_TYPE || type === REACT_PROFILER_TYPE || type === REACT_STRICT_MODE_TYPE || type === REACT_SUSPENSE_TYPE || type === REACT_SUSPENSE_LIST_TYPE || typeof type === 'object' && type !== null && (type.$$typeof === REACT_LAZY_TYPE || type.$$typeof === REACT_MEMO_TYPE || type.$$typeof === REACT_PROVIDER_TYPE || type.$$typeof === REACT_CONTEXT_TYPE || type.$$typeof === REACT_FORWARD_REF_TYPE || type.$$typeof === REACT_FUNDAMENTAL_TYPE || type.$$typeof === REACT_RESPONDER_TYPE || type.$$typeof === REACT_SCOPE_TYPE || type.$$typeof === REACT_BLOCK_TYPE);\n}\n\nfunction typeOf(object) {\n if (typeof object === 'object' && object !== null) {\n var $$typeof = object.$$typeof;\n\n switch ($$typeof) {\n case REACT_ELEMENT_TYPE:\n var type = object.type;\n\n switch (type) {\n case REACT_ASYNC_MODE_TYPE:\n case REACT_CONCURRENT_MODE_TYPE:\n case REACT_FRAGMENT_TYPE:\n case REACT_PROFILER_TYPE:\n case REACT_STRICT_MODE_TYPE:\n case REACT_SUSPENSE_TYPE:\n return type;\n\n default:\n var $$typeofType = type && type.$$typeof;\n\n switch ($$typeofType) {\n case REACT_CONTEXT_TYPE:\n case REACT_FORWARD_REF_TYPE:\n case REACT_LAZY_TYPE:\n case REACT_MEMO_TYPE:\n case REACT_PROVIDER_TYPE:\n return $$typeofType;\n\n default:\n return $$typeof;\n }\n\n }\n\n case REACT_PORTAL_TYPE:\n return $$typeof;\n }\n }\n\n return undefined;\n} // AsyncMode is deprecated along with isAsyncMode\n\nvar AsyncMode = REACT_ASYNC_MODE_TYPE;\nvar ConcurrentMode = REACT_CONCURRENT_MODE_TYPE;\nvar ContextConsumer = REACT_CONTEXT_TYPE;\nvar ContextProvider = REACT_PROVIDER_TYPE;\nvar Element = REACT_ELEMENT_TYPE;\nvar ForwardRef = REACT_FORWARD_REF_TYPE;\nvar Fragment = REACT_FRAGMENT_TYPE;\nvar Lazy = REACT_LAZY_TYPE;\nvar Memo = REACT_MEMO_TYPE;\nvar Portal = REACT_PORTAL_TYPE;\nvar Profiler = REACT_PROFILER_TYPE;\nvar StrictMode = REACT_STRICT_MODE_TYPE;\nvar Suspense = REACT_SUSPENSE_TYPE;\nvar hasWarnedAboutDeprecatedIsAsyncMode = false; // AsyncMode should be deprecated\n\nfunction isAsyncMode(object) {\n {\n if (!hasWarnedAboutDeprecatedIsAsyncMode) {\n hasWarnedAboutDeprecatedIsAsyncMode = true; // Using console['warn'] to evade Babel and ESLint\n\n console['warn']('The ReactIs.isAsyncMode() alias has been deprecated, ' + 'and will be removed in React 17+. Update your code to use ' + 'ReactIs.isConcurrentMode() instead. It has the exact same API.');\n }\n }\n\n return isConcurrentMode(object) || typeOf(object) === REACT_ASYNC_MODE_TYPE;\n}\nfunction isConcurrentMode(object) {\n return typeOf(object) === REACT_CONCURRENT_MODE_TYPE;\n}\nfunction isContextConsumer(object) {\n return typeOf(object) === REACT_CONTEXT_TYPE;\n}\nfunction isContextProvider(object) {\n return typeOf(object) === REACT_PROVIDER_TYPE;\n}\nfunction isElement(object) {\n return typeof object === 'object' && object !== null && object.$$typeof === REACT_ELEMENT_TYPE;\n}\nfunction isForwardRef(object) {\n return typeOf(object) === REACT_FORWARD_REF_TYPE;\n}\nfunction isFragment(object) {\n return typeOf(object) === REACT_FRAGMENT_TYPE;\n}\nfunction isLazy(object) {\n return typeOf(object) === REACT_LAZY_TYPE;\n}\nfunction isMemo(object) {\n return typeOf(object) === REACT_MEMO_TYPE;\n}\nfunction isPortal(object) {\n return typeOf(object) === REACT_PORTAL_TYPE;\n}\nfunction isProfiler(object) {\n return typeOf(object) === REACT_PROFILER_TYPE;\n}\nfunction isStrictMode(object) {\n return typeOf(object) === REACT_STRICT_MODE_TYPE;\n}\nfunction isSuspense(object) {\n return typeOf(object) === REACT_SUSPENSE_TYPE;\n}\n\nexports.AsyncMode = AsyncMode;\nexports.ConcurrentMode = ConcurrentMode;\nexports.ContextConsumer = ContextConsumer;\nexports.ContextProvider = ContextProvider;\nexports.Element = Element;\nexports.ForwardRef = ForwardRef;\nexports.Fragment = Fragment;\nexports.Lazy = Lazy;\nexports.Memo = Memo;\nexports.Portal = Portal;\nexports.Profiler = Profiler;\nexports.StrictMode = StrictMode;\nexports.Suspense = Suspense;\nexports.isAsyncMode = isAsyncMode;\nexports.isConcurrentMode = isConcurrentMode;\nexports.isContextConsumer = isContextConsumer;\nexports.isContextProvider = isContextProvider;\nexports.isElement = isElement;\nexports.isForwardRef = isForwardRef;\nexports.isFragment = isFragment;\nexports.isLazy = isLazy;\nexports.isMemo = isMemo;\nexports.isPortal = isPortal;\nexports.isProfiler = isProfiler;\nexports.isStrictMode = isStrictMode;\nexports.isSuspense = isSuspense;\nexports.isValidElementType = isValidElementType;\nexports.typeOf = typeOf;\n })();\n}\n","'use strict';\n\nif (process.env.NODE_ENV === 'production') {\n module.exports = require('./cjs/react-is.production.min.js');\n} else {\n module.exports = require('./cjs/react-is.development.js');\n}\n","/*\nobject-assign\n(c) Sindre Sorhus\n@license MIT\n*/\n\n'use strict';\n/* eslint-disable no-unused-vars */\nvar getOwnPropertySymbols = Object.getOwnPropertySymbols;\nvar hasOwnProperty = Object.prototype.hasOwnProperty;\nvar propIsEnumerable = Object.prototype.propertyIsEnumerable;\n\nfunction toObject(val) {\n\tif (val === null || val === undefined) {\n\t\tthrow new TypeError('Object.assign cannot be called with null or undefined');\n\t}\n\n\treturn Object(val);\n}\n\nfunction shouldUseNative() {\n\ttry {\n\t\tif (!Object.assign) {\n\t\t\treturn false;\n\t\t}\n\n\t\t// Detect buggy property enumeration order in older V8 versions.\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=4118\n\t\tvar test1 = new String('abc'); // eslint-disable-line no-new-wrappers\n\t\ttest1[5] = 'de';\n\t\tif (Object.getOwnPropertyNames(test1)[0] === '5') {\n\t\t\treturn false;\n\t\t}\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=3056\n\t\tvar test2 = {};\n\t\tfor (var i = 0; i < 10; i++) {\n\t\t\ttest2['_' + String.fromCharCode(i)] = i;\n\t\t}\n\t\tvar order2 = Object.getOwnPropertyNames(test2).map(function (n) {\n\t\t\treturn test2[n];\n\t\t});\n\t\tif (order2.join('') !== '0123456789') {\n\t\t\treturn false;\n\t\t}\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=3056\n\t\tvar test3 = {};\n\t\t'abcdefghijklmnopqrst'.split('').forEach(function (letter) {\n\t\t\ttest3[letter] = letter;\n\t\t});\n\t\tif (Object.keys(Object.assign({}, test3)).join('') !==\n\t\t\t\t'abcdefghijklmnopqrst') {\n\t\t\treturn false;\n\t\t}\n\n\t\treturn true;\n\t} catch (err) {\n\t\t// We don't expect any of the above to throw, but better to be safe.\n\t\treturn false;\n\t}\n}\n\nmodule.exports = shouldUseNative() ? Object.assign : function (target, source) {\n\tvar from;\n\tvar to = toObject(target);\n\tvar symbols;\n\n\tfor (var s = 1; s < arguments.length; s++) {\n\t\tfrom = Object(arguments[s]);\n\n\t\tfor (var key in from) {\n\t\t\tif (hasOwnProperty.call(from, key)) {\n\t\t\t\tto[key] = from[key];\n\t\t\t}\n\t\t}\n\n\t\tif (getOwnPropertySymbols) {\n\t\t\tsymbols = getOwnPropertySymbols(from);\n\t\t\tfor (var i = 0; i < symbols.length; i++) {\n\t\t\t\tif (propIsEnumerable.call(from, symbols[i])) {\n\t\t\t\t\tto[symbols[i]] = from[symbols[i]];\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\n\treturn to;\n};\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar ReactPropTypesSecret = 'SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED';\n\nmodule.exports = ReactPropTypesSecret;\n","module.exports = Function.call.bind(Object.prototype.hasOwnProperty);\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar printWarning = function() {};\n\nif (process.env.NODE_ENV !== 'production') {\n var ReactPropTypesSecret = require('./lib/ReactPropTypesSecret');\n var loggedTypeFailures = {};\n var has = require('./lib/has');\n\n printWarning = function(text) {\n var message = 'Warning: ' + text;\n if (typeof console !== 'undefined') {\n console.error(message);\n }\n try {\n // --- Welcome to debugging React ---\n // This error was thrown as a convenience so that you can use this stack\n // to find the callsite that caused this warning to fire.\n throw new Error(message);\n } catch (x) { /**/ }\n };\n}\n\n/**\n * Assert that the values match with the type specs.\n * Error messages are memorized and will only be shown once.\n *\n * @param {object} typeSpecs Map of name to a ReactPropType\n * @param {object} values Runtime values that need to be type-checked\n * @param {string} location e.g. \"prop\", \"context\", \"child context\"\n * @param {string} componentName Name of the component for error messages.\n * @param {?Function} getStack Returns the component stack.\n * @private\n */\nfunction checkPropTypes(typeSpecs, values, location, componentName, getStack) {\n if (process.env.NODE_ENV !== 'production') {\n for (var typeSpecName in typeSpecs) {\n if (has(typeSpecs, typeSpecName)) {\n var error;\n // Prop type validation may throw. In case they do, we don't want to\n // fail the render phase where it didn't fail before. So we log it.\n // After these have been cleaned up, we'll let them throw.\n try {\n // This is intentionally an invariant that gets caught. It's the same\n // behavior as without this statement except with a better message.\n if (typeof typeSpecs[typeSpecName] !== 'function') {\n var err = Error(\n (componentName || 'React class') + ': ' + location + ' type `' + typeSpecName + '` is invalid; ' +\n 'it must be a function, usually from the `prop-types` package, but received `' + typeof typeSpecs[typeSpecName] + '`.' +\n 'This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.'\n );\n err.name = 'Invariant Violation';\n throw err;\n }\n error = typeSpecs[typeSpecName](values, typeSpecName, componentName, location, null, ReactPropTypesSecret);\n } catch (ex) {\n error = ex;\n }\n if (error && !(error instanceof Error)) {\n printWarning(\n (componentName || 'React class') + ': type specification of ' +\n location + ' `' + typeSpecName + '` is invalid; the type checker ' +\n 'function must return `null` or an `Error` but returned a ' + typeof error + '. ' +\n 'You may have forgotten to pass an argument to the type checker ' +\n 'creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and ' +\n 'shape all require an argument).'\n );\n }\n if (error instanceof Error && !(error.message in loggedTypeFailures)) {\n // Only monitor this failure once because there tends to be a lot of the\n // same error.\n loggedTypeFailures[error.message] = true;\n\n var stack = getStack ? getStack() : '';\n\n printWarning(\n 'Failed ' + location + ' type: ' + error.message + (stack != null ? stack : '')\n );\n }\n }\n }\n }\n}\n\n/**\n * Resets warning cache when testing.\n *\n * @private\n */\ncheckPropTypes.resetWarningCache = function() {\n if (process.env.NODE_ENV !== 'production') {\n loggedTypeFailures = {};\n }\n}\n\nmodule.exports = checkPropTypes;\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar ReactIs = require('react-is');\nvar assign = require('object-assign');\n\nvar ReactPropTypesSecret = require('./lib/ReactPropTypesSecret');\nvar has = require('./lib/has');\nvar checkPropTypes = require('./checkPropTypes');\n\nvar printWarning = function() {};\n\nif (process.env.NODE_ENV !== 'production') {\n printWarning = function(text) {\n var message = 'Warning: ' + text;\n if (typeof console !== 'undefined') {\n console.error(message);\n }\n try {\n // --- Welcome to debugging React ---\n // This error was thrown as a convenience so that you can use this stack\n // to find the callsite that caused this warning to fire.\n throw new Error(message);\n } catch (x) {}\n };\n}\n\nfunction emptyFunctionThatReturnsNull() {\n return null;\n}\n\nmodule.exports = function(isValidElement, throwOnDirectAccess) {\n /* global Symbol */\n var ITERATOR_SYMBOL = typeof Symbol === 'function' && Symbol.iterator;\n var FAUX_ITERATOR_SYMBOL = '@@iterator'; // Before Symbol spec.\n\n /**\n * Returns the iterator method function contained on the iterable object.\n *\n * Be sure to invoke the function with the iterable as context:\n *\n * var iteratorFn = getIteratorFn(myIterable);\n * if (iteratorFn) {\n * var iterator = iteratorFn.call(myIterable);\n * ...\n * }\n *\n * @param {?object} maybeIterable\n * @return {?function}\n */\n function getIteratorFn(maybeIterable) {\n var iteratorFn = maybeIterable && (ITERATOR_SYMBOL && maybeIterable[ITERATOR_SYMBOL] || maybeIterable[FAUX_ITERATOR_SYMBOL]);\n if (typeof iteratorFn === 'function') {\n return iteratorFn;\n }\n }\n\n /**\n * Collection of methods that allow declaration and validation of props that are\n * supplied to React components. Example usage:\n *\n * var Props = require('ReactPropTypes');\n * var MyArticle = React.createClass({\n * propTypes: {\n * // An optional string prop named \"description\".\n * description: Props.string,\n *\n * // A required enum prop named \"category\".\n * category: Props.oneOf(['News','Photos']).isRequired,\n *\n * // A prop named \"dialog\" that requires an instance of Dialog.\n * dialog: Props.instanceOf(Dialog).isRequired\n * },\n * render: function() { ... }\n * });\n *\n * A more formal specification of how these methods are used:\n *\n * type := array|bool|func|object|number|string|oneOf([...])|instanceOf(...)\n * decl := ReactPropTypes.{type}(.isRequired)?\n *\n * Each and every declaration produces a function with the same signature. This\n * allows the creation of custom validation functions. For example:\n *\n * var MyLink = React.createClass({\n * propTypes: {\n * // An optional string or URI prop named \"href\".\n * href: function(props, propName, componentName) {\n * var propValue = props[propName];\n * if (propValue != null && typeof propValue !== 'string' &&\n * !(propValue instanceof URI)) {\n * return new Error(\n * 'Expected a string or an URI for ' + propName + ' in ' +\n * componentName\n * );\n * }\n * }\n * },\n * render: function() {...}\n * });\n *\n * @internal\n */\n\n var ANONYMOUS = '<>';\n\n // Important!\n // Keep this list in sync with production version in `./factoryWithThrowingShims.js`.\n var ReactPropTypes = {\n array: createPrimitiveTypeChecker('array'),\n bigint: createPrimitiveTypeChecker('bigint'),\n bool: createPrimitiveTypeChecker('boolean'),\n func: createPrimitiveTypeChecker('function'),\n number: createPrimitiveTypeChecker('number'),\n object: createPrimitiveTypeChecker('object'),\n string: createPrimitiveTypeChecker('string'),\n symbol: createPrimitiveTypeChecker('symbol'),\n\n any: createAnyTypeChecker(),\n arrayOf: createArrayOfTypeChecker,\n element: createElementTypeChecker(),\n elementType: createElementTypeTypeChecker(),\n instanceOf: createInstanceTypeChecker,\n node: createNodeChecker(),\n objectOf: createObjectOfTypeChecker,\n oneOf: createEnumTypeChecker,\n oneOfType: createUnionTypeChecker,\n shape: createShapeTypeChecker,\n exact: createStrictShapeTypeChecker,\n };\n\n /**\n * inlined Object.is polyfill to avoid requiring consumers ship their own\n * https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object/is\n */\n /*eslint-disable no-self-compare*/\n function is(x, y) {\n // SameValue algorithm\n if (x === y) {\n // Steps 1-5, 7-10\n // Steps 6.b-6.e: +0 != -0\n return x !== 0 || 1 / x === 1 / y;\n } else {\n // Step 6.a: NaN == NaN\n return x !== x && y !== y;\n }\n }\n /*eslint-enable no-self-compare*/\n\n /**\n * We use an Error-like object for backward compatibility as people may call\n * PropTypes directly and inspect their output. However, we don't use real\n * Errors anymore. We don't inspect their stack anyway, and creating them\n * is prohibitively expensive if they are created too often, such as what\n * happens in oneOfType() for any type before the one that matched.\n */\n function PropTypeError(message, data) {\n this.message = message;\n this.data = data && typeof data === 'object' ? data: {};\n this.stack = '';\n }\n // Make `instanceof Error` still work for returned errors.\n PropTypeError.prototype = Error.prototype;\n\n function createChainableTypeChecker(validate) {\n if (process.env.NODE_ENV !== 'production') {\n var manualPropTypeCallCache = {};\n var manualPropTypeWarningCount = 0;\n }\n function checkType(isRequired, props, propName, componentName, location, propFullName, secret) {\n componentName = componentName || ANONYMOUS;\n propFullName = propFullName || propName;\n\n if (secret !== ReactPropTypesSecret) {\n if (throwOnDirectAccess) {\n // New behavior only for users of `prop-types` package\n var err = new Error(\n 'Calling PropTypes validators directly is not supported by the `prop-types` package. ' +\n 'Use `PropTypes.checkPropTypes()` to call them. ' +\n 'Read more at http://fb.me/use-check-prop-types'\n );\n err.name = 'Invariant Violation';\n throw err;\n } else if (process.env.NODE_ENV !== 'production' && typeof console !== 'undefined') {\n // Old behavior for people using React.PropTypes\n var cacheKey = componentName + ':' + propName;\n if (\n !manualPropTypeCallCache[cacheKey] &&\n // Avoid spamming the console because they are often not actionable except for lib authors\n manualPropTypeWarningCount < 3\n ) {\n printWarning(\n 'You are manually calling a React.PropTypes validation ' +\n 'function for the `' + propFullName + '` prop on `' + componentName + '`. This is deprecated ' +\n 'and will throw in the standalone `prop-types` package. ' +\n 'You may be seeing this warning due to a third-party PropTypes ' +\n 'library. See https://fb.me/react-warning-dont-call-proptypes ' + 'for details.'\n );\n manualPropTypeCallCache[cacheKey] = true;\n manualPropTypeWarningCount++;\n }\n }\n }\n if (props[propName] == null) {\n if (isRequired) {\n if (props[propName] === null) {\n return new PropTypeError('The ' + location + ' `' + propFullName + '` is marked as required ' + ('in `' + componentName + '`, but its value is `null`.'));\n }\n return new PropTypeError('The ' + location + ' `' + propFullName + '` is marked as required in ' + ('`' + componentName + '`, but its value is `undefined`.'));\n }\n return null;\n } else {\n return validate(props, propName, componentName, location, propFullName);\n }\n }\n\n var chainedCheckType = checkType.bind(null, false);\n chainedCheckType.isRequired = checkType.bind(null, true);\n\n return chainedCheckType;\n }\n\n function createPrimitiveTypeChecker(expectedType) {\n function validate(props, propName, componentName, location, propFullName, secret) {\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== expectedType) {\n // `propValue` being instance of, say, date/regexp, pass the 'object'\n // check, but we can offer a more precise error message here rather than\n // 'of type `object`'.\n var preciseType = getPreciseType(propValue);\n\n return new PropTypeError(\n 'Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + preciseType + '` supplied to `' + componentName + '`, expected ') + ('`' + expectedType + '`.'),\n {expectedType: expectedType}\n );\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createAnyTypeChecker() {\n return createChainableTypeChecker(emptyFunctionThatReturnsNull);\n }\n\n function createArrayOfTypeChecker(typeChecker) {\n function validate(props, propName, componentName, location, propFullName) {\n if (typeof typeChecker !== 'function') {\n return new PropTypeError('Property `' + propFullName + '` of component `' + componentName + '` has invalid PropType notation inside arrayOf.');\n }\n var propValue = props[propName];\n if (!Array.isArray(propValue)) {\n var propType = getPropType(propValue);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected an array.'));\n }\n for (var i = 0; i < propValue.length; i++) {\n var error = typeChecker(propValue, i, componentName, location, propFullName + '[' + i + ']', ReactPropTypesSecret);\n if (error instanceof Error) {\n return error;\n }\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createElementTypeChecker() {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n if (!isValidElement(propValue)) {\n var propType = getPropType(propValue);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected a single ReactElement.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createElementTypeTypeChecker() {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n if (!ReactIs.isValidElementType(propValue)) {\n var propType = getPropType(propValue);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected a single ReactElement type.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createInstanceTypeChecker(expectedClass) {\n function validate(props, propName, componentName, location, propFullName) {\n if (!(props[propName] instanceof expectedClass)) {\n var expectedClassName = expectedClass.name || ANONYMOUS;\n var actualClassName = getClassName(props[propName]);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + actualClassName + '` supplied to `' + componentName + '`, expected ') + ('instance of `' + expectedClassName + '`.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createEnumTypeChecker(expectedValues) {\n if (!Array.isArray(expectedValues)) {\n if (process.env.NODE_ENV !== 'production') {\n if (arguments.length > 1) {\n printWarning(\n 'Invalid arguments supplied to oneOf, expected an array, got ' + arguments.length + ' arguments. ' +\n 'A common mistake is to write oneOf(x, y, z) instead of oneOf([x, y, z]).'\n );\n } else {\n printWarning('Invalid argument supplied to oneOf, expected an array.');\n }\n }\n return emptyFunctionThatReturnsNull;\n }\n\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n for (var i = 0; i < expectedValues.length; i++) {\n if (is(propValue, expectedValues[i])) {\n return null;\n }\n }\n\n var valuesString = JSON.stringify(expectedValues, function replacer(key, value) {\n var type = getPreciseType(value);\n if (type === 'symbol') {\n return String(value);\n }\n return value;\n });\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of value `' + String(propValue) + '` ' + ('supplied to `' + componentName + '`, expected one of ' + valuesString + '.'));\n }\n return createChainableTypeChecker(validate);\n }\n\n function createObjectOfTypeChecker(typeChecker) {\n function validate(props, propName, componentName, location, propFullName) {\n if (typeof typeChecker !== 'function') {\n return new PropTypeError('Property `' + propFullName + '` of component `' + componentName + '` has invalid PropType notation inside objectOf.');\n }\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== 'object') {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected an object.'));\n }\n for (var key in propValue) {\n if (has(propValue, key)) {\n var error = typeChecker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret);\n if (error instanceof Error) {\n return error;\n }\n }\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createUnionTypeChecker(arrayOfTypeCheckers) {\n if (!Array.isArray(arrayOfTypeCheckers)) {\n process.env.NODE_ENV !== 'production' ? printWarning('Invalid argument supplied to oneOfType, expected an instance of array.') : void 0;\n return emptyFunctionThatReturnsNull;\n }\n\n for (var i = 0; i < arrayOfTypeCheckers.length; i++) {\n var checker = arrayOfTypeCheckers[i];\n if (typeof checker !== 'function') {\n printWarning(\n 'Invalid argument supplied to oneOfType. Expected an array of check functions, but ' +\n 'received ' + getPostfixForTypeWarning(checker) + ' at index ' + i + '.'\n );\n return emptyFunctionThatReturnsNull;\n }\n }\n\n function validate(props, propName, componentName, location, propFullName) {\n var expectedTypes = [];\n for (var i = 0; i < arrayOfTypeCheckers.length; i++) {\n var checker = arrayOfTypeCheckers[i];\n var checkerResult = checker(props, propName, componentName, location, propFullName, ReactPropTypesSecret);\n if (checkerResult == null) {\n return null;\n }\n if (checkerResult.data && has(checkerResult.data, 'expectedType')) {\n expectedTypes.push(checkerResult.data.expectedType);\n }\n }\n var expectedTypesMessage = (expectedTypes.length > 0) ? ', expected one of type [' + expectedTypes.join(', ') + ']': '';\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` supplied to ' + ('`' + componentName + '`' + expectedTypesMessage + '.'));\n }\n return createChainableTypeChecker(validate);\n }\n\n function createNodeChecker() {\n function validate(props, propName, componentName, location, propFullName) {\n if (!isNode(props[propName])) {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` supplied to ' + ('`' + componentName + '`, expected a ReactNode.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function invalidValidatorError(componentName, location, propFullName, key, type) {\n return new PropTypeError(\n (componentName || 'React class') + ': ' + location + ' type `' + propFullName + '.' + key + '` is invalid; ' +\n 'it must be a function, usually from the `prop-types` package, but received `' + type + '`.'\n );\n }\n\n function createShapeTypeChecker(shapeTypes) {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== 'object') {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type `' + propType + '` ' + ('supplied to `' + componentName + '`, expected `object`.'));\n }\n for (var key in shapeTypes) {\n var checker = shapeTypes[key];\n if (typeof checker !== 'function') {\n return invalidValidatorError(componentName, location, propFullName, key, getPreciseType(checker));\n }\n var error = checker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret);\n if (error) {\n return error;\n }\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createStrictShapeTypeChecker(shapeTypes) {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== 'object') {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type `' + propType + '` ' + ('supplied to `' + componentName + '`, expected `object`.'));\n }\n // We need to check all keys in case some are required but missing from props.\n var allKeys = assign({}, props[propName], shapeTypes);\n for (var key in allKeys) {\n var checker = shapeTypes[key];\n if (has(shapeTypes, key) && typeof checker !== 'function') {\n return invalidValidatorError(componentName, location, propFullName, key, getPreciseType(checker));\n }\n if (!checker) {\n return new PropTypeError(\n 'Invalid ' + location + ' `' + propFullName + '` key `' + key + '` supplied to `' + componentName + '`.' +\n '\\nBad object: ' + JSON.stringify(props[propName], null, ' ') +\n '\\nValid keys: ' + JSON.stringify(Object.keys(shapeTypes), null, ' ')\n );\n }\n var error = checker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret);\n if (error) {\n return error;\n }\n }\n return null;\n }\n\n return createChainableTypeChecker(validate);\n }\n\n function isNode(propValue) {\n switch (typeof propValue) {\n case 'number':\n case 'string':\n case 'undefined':\n return true;\n case 'boolean':\n return !propValue;\n case 'object':\n if (Array.isArray(propValue)) {\n return propValue.every(isNode);\n }\n if (propValue === null || isValidElement(propValue)) {\n return true;\n }\n\n var iteratorFn = getIteratorFn(propValue);\n if (iteratorFn) {\n var iterator = iteratorFn.call(propValue);\n var step;\n if (iteratorFn !== propValue.entries) {\n while (!(step = iterator.next()).done) {\n if (!isNode(step.value)) {\n return false;\n }\n }\n } else {\n // Iterator will provide entry [k,v] tuples rather than values.\n while (!(step = iterator.next()).done) {\n var entry = step.value;\n if (entry) {\n if (!isNode(entry[1])) {\n return false;\n }\n }\n }\n }\n } else {\n return false;\n }\n\n return true;\n default:\n return false;\n }\n }\n\n function isSymbol(propType, propValue) {\n // Native Symbol.\n if (propType === 'symbol') {\n return true;\n }\n\n // falsy value can't be a Symbol\n if (!propValue) {\n return false;\n }\n\n // 19.4.3.5 Symbol.prototype[@@toStringTag] === 'Symbol'\n if (propValue['@@toStringTag'] === 'Symbol') {\n return true;\n }\n\n // Fallback for non-spec compliant Symbols which are polyfilled.\n if (typeof Symbol === 'function' && propValue instanceof Symbol) {\n return true;\n }\n\n return false;\n }\n\n // Equivalent of `typeof` but with special handling for array and regexp.\n function getPropType(propValue) {\n var propType = typeof propValue;\n if (Array.isArray(propValue)) {\n return 'array';\n }\n if (propValue instanceof RegExp) {\n // Old webkits (at least until Android 4.0) return 'function' rather than\n // 'object' for typeof a RegExp. We'll normalize this here so that /bla/\n // passes PropTypes.object.\n return 'object';\n }\n if (isSymbol(propType, propValue)) {\n return 'symbol';\n }\n return propType;\n }\n\n // This handles more types than `getPropType`. Only used for error messages.\n // See `createPrimitiveTypeChecker`.\n function getPreciseType(propValue) {\n if (typeof propValue === 'undefined' || propValue === null) {\n return '' + propValue;\n }\n var propType = getPropType(propValue);\n if (propType === 'object') {\n if (propValue instanceof Date) {\n return 'date';\n } else if (propValue instanceof RegExp) {\n return 'regexp';\n }\n }\n return propType;\n }\n\n // Returns a string that is postfixed to a warning about an invalid type.\n // For example, \"undefined\" or \"of type array\"\n function getPostfixForTypeWarning(value) {\n var type = getPreciseType(value);\n switch (type) {\n case 'array':\n case 'object':\n return 'an ' + type;\n case 'boolean':\n case 'date':\n case 'regexp':\n return 'a ' + type;\n default:\n return type;\n }\n }\n\n // Returns class name of the object, if any.\n function getClassName(propValue) {\n if (!propValue.constructor || !propValue.constructor.name) {\n return ANONYMOUS;\n }\n return propValue.constructor.name;\n }\n\n ReactPropTypes.checkPropTypes = checkPropTypes;\n ReactPropTypes.resetWarningCache = checkPropTypes.resetWarningCache;\n ReactPropTypes.PropTypes = ReactPropTypes;\n\n return ReactPropTypes;\n};\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar ReactPropTypesSecret = require('./lib/ReactPropTypesSecret');\n\nfunction emptyFunction() {}\nfunction emptyFunctionWithReset() {}\nemptyFunctionWithReset.resetWarningCache = emptyFunction;\n\nmodule.exports = function() {\n function shim(props, propName, componentName, location, propFullName, secret) {\n if (secret === ReactPropTypesSecret) {\n // It is still safe when called from React.\n return;\n }\n var err = new Error(\n 'Calling PropTypes validators directly is not supported by the `prop-types` package. ' +\n 'Use PropTypes.checkPropTypes() to call them. ' +\n 'Read more at http://fb.me/use-check-prop-types'\n );\n err.name = 'Invariant Violation';\n throw err;\n };\n shim.isRequired = shim;\n function getShim() {\n return shim;\n };\n // Important!\n // Keep this list in sync with production version in `./factoryWithTypeCheckers.js`.\n var ReactPropTypes = {\n array: shim,\n bigint: shim,\n bool: shim,\n func: shim,\n number: shim,\n object: shim,\n string: shim,\n symbol: shim,\n\n any: shim,\n arrayOf: getShim,\n element: shim,\n elementType: shim,\n instanceOf: getShim,\n node: shim,\n objectOf: getShim,\n oneOf: getShim,\n oneOfType: getShim,\n shape: getShim,\n exact: getShim,\n\n checkPropTypes: emptyFunctionWithReset,\n resetWarningCache: emptyFunction\n };\n\n ReactPropTypes.PropTypes = ReactPropTypes;\n\n return ReactPropTypes;\n};\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\nif (process.env.NODE_ENV !== 'production') {\n var ReactIs = require('react-is');\n\n // By explicitly using `prop-types` you are opting into new development behavior.\n // http://fb.me/prop-types-in-prod\n var throwOnDirectAccess = true;\n module.exports = require('./factoryWithTypeCheckers')(ReactIs.isElement, throwOnDirectAccess);\n} else {\n // By explicitly using `prop-types` you are opting into new production behavior.\n // http://fb.me/prop-types-in-prod\n module.exports = require('./factoryWithThrowingShims')();\n}\n","import PropTypes from 'prop-types';\nimport chainPropTypes from '../chainPropTypes';\nfunction isClassComponent(elementType) {\n // elementType.prototype?.isReactComponent\n const {\n prototype = {}\n } = elementType;\n return Boolean(prototype.isReactComponent);\n}\nfunction acceptingRef(props, propName, componentName, location, propFullName) {\n const element = props[propName];\n const safePropName = propFullName || propName;\n if (element == null ||\n // When server-side rendering React doesn't warn either.\n // This is not an accurate check for SSR.\n // This is only in place for Emotion compat.\n // TODO: Revisit once https://github.com/facebook/react/issues/20047 is resolved.\n typeof window === 'undefined') {\n return null;\n }\n let warningHint;\n const elementType = element.type;\n /**\n * Blacklisting instead of whitelisting\n *\n * Blacklisting will miss some components, such as React.Fragment. Those will at least\n * trigger a warning in React.\n * We can't whitelist because there is no safe way to detect React.forwardRef\n * or class components. \"Safe\" means there's no public API.\n *\n */\n if (typeof elementType === 'function' && !isClassComponent(elementType)) {\n warningHint = 'Did you accidentally use a plain function component for an element instead?';\n }\n if (warningHint !== undefined) {\n return new Error(`Invalid ${location} \\`${safePropName}\\` supplied to \\`${componentName}\\`. ` + `Expected an element that can hold a ref. ${warningHint} ` + 'For more information see https://mui.com/r/caveat-with-refs-guide');\n }\n return null;\n}\nconst elementAcceptingRef = chainPropTypes(PropTypes.element, acceptingRef);\nelementAcceptingRef.isRequired = chainPropTypes(PropTypes.element.isRequired, acceptingRef);\nexport default elementAcceptingRef;","import _extends from \"@babel/runtime/helpers/esm/extends\";\n// This module is based on https://github.com/airbnb/prop-types-exact repository.\n// However, in order to reduce the number of dependencies and to remove some extra safe checks\n// the module was forked.\n\nconst specialProperty = 'exact-prop: \\u200b';\nexport default function exactProp(propTypes) {\n if (process.env.NODE_ENV === 'production') {\n return propTypes;\n }\n return _extends({}, propTypes, {\n [specialProperty]: props => {\n const unsupportedProps = Object.keys(props).filter(prop => !propTypes.hasOwnProperty(prop));\n if (unsupportedProps.length > 0) {\n return new Error(`The following props are not supported: ${unsupportedProps.map(prop => `\\`${prop}\\``).join(', ')}. Please remove them.`);\n }\n return null;\n }\n });\n}","/**\n * WARNING: Don't import this directly.\n * Use `MuiError` from `@mui/internal-babel-macros/MuiError.macro` instead.\n * @param {number} code\n */\nexport default function formatMuiErrorMessage(code) {\n // Apply babel-plugin-transform-template-literals in loose mode\n // loose mode is safe if we're concatenating primitives\n // see https://babeljs.io/docs/en/babel-plugin-transform-template-literals#loose\n /* eslint-disable prefer-template */\n let url = 'https://mui.com/production-error/?code=' + code;\n for (let i = 1; i < arguments.length; i += 1) {\n // rest params over-transpile for this case\n // eslint-disable-next-line prefer-rest-params\n url += '&args[]=' + encodeURIComponent(arguments[i]);\n }\n return 'Minified MUI error #' + code + '; visit ' + url + ' for the full message.';\n /* eslint-enable prefer-template */\n}","/**\n * @license React\n * react-is.production.min.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n'use strict';var b=Symbol.for(\"react.element\"),c=Symbol.for(\"react.portal\"),d=Symbol.for(\"react.fragment\"),e=Symbol.for(\"react.strict_mode\"),f=Symbol.for(\"react.profiler\"),g=Symbol.for(\"react.provider\"),h=Symbol.for(\"react.context\"),k=Symbol.for(\"react.server_context\"),l=Symbol.for(\"react.forward_ref\"),m=Symbol.for(\"react.suspense\"),n=Symbol.for(\"react.suspense_list\"),p=Symbol.for(\"react.memo\"),q=Symbol.for(\"react.lazy\"),t=Symbol.for(\"react.offscreen\"),u;u=Symbol.for(\"react.module.reference\");\nfunction v(a){if(\"object\"===typeof a&&null!==a){var r=a.$$typeof;switch(r){case b:switch(a=a.type,a){case d:case f:case e:case m:case n:return a;default:switch(a=a&&a.$$typeof,a){case k:case h:case l:case q:case p:case g:return a;default:return r}}case c:return r}}}exports.ContextConsumer=h;exports.ContextProvider=g;exports.Element=b;exports.ForwardRef=l;exports.Fragment=d;exports.Lazy=q;exports.Memo=p;exports.Portal=c;exports.Profiler=f;exports.StrictMode=e;exports.Suspense=m;\nexports.SuspenseList=n;exports.isAsyncMode=function(){return!1};exports.isConcurrentMode=function(){return!1};exports.isContextConsumer=function(a){return v(a)===h};exports.isContextProvider=function(a){return v(a)===g};exports.isElement=function(a){return\"object\"===typeof a&&null!==a&&a.$$typeof===b};exports.isForwardRef=function(a){return v(a)===l};exports.isFragment=function(a){return v(a)===d};exports.isLazy=function(a){return v(a)===q};exports.isMemo=function(a){return v(a)===p};\nexports.isPortal=function(a){return v(a)===c};exports.isProfiler=function(a){return v(a)===f};exports.isStrictMode=function(a){return v(a)===e};exports.isSuspense=function(a){return v(a)===m};exports.isSuspenseList=function(a){return v(a)===n};\nexports.isValidElementType=function(a){return\"string\"===typeof a||\"function\"===typeof a||a===d||a===f||a===e||a===m||a===n||a===t||\"object\"===typeof a&&null!==a&&(a.$$typeof===q||a.$$typeof===p||a.$$typeof===g||a.$$typeof===h||a.$$typeof===l||a.$$typeof===u||void 0!==a.getModuleId)?!0:!1};exports.typeOf=v;\n","/**\n * @license React\n * react-is.development.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nif (process.env.NODE_ENV !== \"production\") {\n (function() {\n'use strict';\n\n// ATTENTION\n// When adding new symbols to this file,\n// Please consider also adding to 'react-devtools-shared/src/backend/ReactSymbols'\n// The Symbol used to tag the ReactElement-like types.\nvar REACT_ELEMENT_TYPE = Symbol.for('react.element');\nvar REACT_PORTAL_TYPE = Symbol.for('react.portal');\nvar REACT_FRAGMENT_TYPE = Symbol.for('react.fragment');\nvar REACT_STRICT_MODE_TYPE = Symbol.for('react.strict_mode');\nvar REACT_PROFILER_TYPE = Symbol.for('react.profiler');\nvar REACT_PROVIDER_TYPE = Symbol.for('react.provider');\nvar REACT_CONTEXT_TYPE = Symbol.for('react.context');\nvar REACT_SERVER_CONTEXT_TYPE = Symbol.for('react.server_context');\nvar REACT_FORWARD_REF_TYPE = Symbol.for('react.forward_ref');\nvar REACT_SUSPENSE_TYPE = Symbol.for('react.suspense');\nvar REACT_SUSPENSE_LIST_TYPE = Symbol.for('react.suspense_list');\nvar REACT_MEMO_TYPE = Symbol.for('react.memo');\nvar REACT_LAZY_TYPE = Symbol.for('react.lazy');\nvar REACT_OFFSCREEN_TYPE = Symbol.for('react.offscreen');\n\n// -----------------------------------------------------------------------------\n\nvar enableScopeAPI = false; // Experimental Create Event Handle API.\nvar enableCacheElement = false;\nvar enableTransitionTracing = false; // No known bugs, but needs performance testing\n\nvar enableLegacyHidden = false; // Enables unstable_avoidThisFallback feature in Fiber\n// stuff. Intended to enable React core members to more easily debug scheduling\n// issues in DEV builds.\n\nvar enableDebugTracing = false; // Track which Fiber(s) schedule render work.\n\nvar REACT_MODULE_REFERENCE;\n\n{\n REACT_MODULE_REFERENCE = Symbol.for('react.module.reference');\n}\n\nfunction isValidElementType(type) {\n if (typeof type === 'string' || typeof type === 'function') {\n return true;\n } // Note: typeof might be other than 'symbol' or 'number' (e.g. if it's a polyfill).\n\n\n if (type === REACT_FRAGMENT_TYPE || type === REACT_PROFILER_TYPE || enableDebugTracing || type === REACT_STRICT_MODE_TYPE || type === REACT_SUSPENSE_TYPE || type === REACT_SUSPENSE_LIST_TYPE || enableLegacyHidden || type === REACT_OFFSCREEN_TYPE || enableScopeAPI || enableCacheElement || enableTransitionTracing ) {\n return true;\n }\n\n if (typeof type === 'object' && type !== null) {\n if (type.$$typeof === REACT_LAZY_TYPE || type.$$typeof === REACT_MEMO_TYPE || type.$$typeof === REACT_PROVIDER_TYPE || type.$$typeof === REACT_CONTEXT_TYPE || type.$$typeof === REACT_FORWARD_REF_TYPE || // This needs to include all possible module reference object\n // types supported by any Flight configuration anywhere since\n // we don't know which Flight build this will end up being used\n // with.\n type.$$typeof === REACT_MODULE_REFERENCE || type.getModuleId !== undefined) {\n return true;\n }\n }\n\n return false;\n}\n\nfunction typeOf(object) {\n if (typeof object === 'object' && object !== null) {\n var $$typeof = object.$$typeof;\n\n switch ($$typeof) {\n case REACT_ELEMENT_TYPE:\n var type = object.type;\n\n switch (type) {\n case REACT_FRAGMENT_TYPE:\n case REACT_PROFILER_TYPE:\n case REACT_STRICT_MODE_TYPE:\n case REACT_SUSPENSE_TYPE:\n case REACT_SUSPENSE_LIST_TYPE:\n return type;\n\n default:\n var $$typeofType = type && type.$$typeof;\n\n switch ($$typeofType) {\n case REACT_SERVER_CONTEXT_TYPE:\n case REACT_CONTEXT_TYPE:\n case REACT_FORWARD_REF_TYPE:\n case REACT_LAZY_TYPE:\n case REACT_MEMO_TYPE:\n case REACT_PROVIDER_TYPE:\n return $$typeofType;\n\n default:\n return $$typeof;\n }\n\n }\n\n case REACT_PORTAL_TYPE:\n return $$typeof;\n }\n }\n\n return undefined;\n}\nvar ContextConsumer = REACT_CONTEXT_TYPE;\nvar ContextProvider = REACT_PROVIDER_TYPE;\nvar Element = REACT_ELEMENT_TYPE;\nvar ForwardRef = REACT_FORWARD_REF_TYPE;\nvar Fragment = REACT_FRAGMENT_TYPE;\nvar Lazy = REACT_LAZY_TYPE;\nvar Memo = REACT_MEMO_TYPE;\nvar Portal = REACT_PORTAL_TYPE;\nvar Profiler = REACT_PROFILER_TYPE;\nvar StrictMode = REACT_STRICT_MODE_TYPE;\nvar Suspense = REACT_SUSPENSE_TYPE;\nvar SuspenseList = REACT_SUSPENSE_LIST_TYPE;\nvar hasWarnedAboutDeprecatedIsAsyncMode = false;\nvar hasWarnedAboutDeprecatedIsConcurrentMode = false; // AsyncMode should be deprecated\n\nfunction isAsyncMode(object) {\n {\n if (!hasWarnedAboutDeprecatedIsAsyncMode) {\n hasWarnedAboutDeprecatedIsAsyncMode = true; // Using console['warn'] to evade Babel and ESLint\n\n console['warn']('The ReactIs.isAsyncMode() alias has been deprecated, ' + 'and will be removed in React 18+.');\n }\n }\n\n return false;\n}\nfunction isConcurrentMode(object) {\n {\n if (!hasWarnedAboutDeprecatedIsConcurrentMode) {\n hasWarnedAboutDeprecatedIsConcurrentMode = true; // Using console['warn'] to evade Babel and ESLint\n\n console['warn']('The ReactIs.isConcurrentMode() alias has been deprecated, ' + 'and will be removed in React 18+.');\n }\n }\n\n return false;\n}\nfunction isContextConsumer(object) {\n return typeOf(object) === REACT_CONTEXT_TYPE;\n}\nfunction isContextProvider(object) {\n return typeOf(object) === REACT_PROVIDER_TYPE;\n}\nfunction isElement(object) {\n return typeof object === 'object' && object !== null && object.$$typeof === REACT_ELEMENT_TYPE;\n}\nfunction isForwardRef(object) {\n return typeOf(object) === REACT_FORWARD_REF_TYPE;\n}\nfunction isFragment(object) {\n return typeOf(object) === REACT_FRAGMENT_TYPE;\n}\nfunction isLazy(object) {\n return typeOf(object) === REACT_LAZY_TYPE;\n}\nfunction isMemo(object) {\n return typeOf(object) === REACT_MEMO_TYPE;\n}\nfunction isPortal(object) {\n return typeOf(object) === REACT_PORTAL_TYPE;\n}\nfunction isProfiler(object) {\n return typeOf(object) === REACT_PROFILER_TYPE;\n}\nfunction isStrictMode(object) {\n return typeOf(object) === REACT_STRICT_MODE_TYPE;\n}\nfunction isSuspense(object) {\n return typeOf(object) === REACT_SUSPENSE_TYPE;\n}\nfunction isSuspenseList(object) {\n return typeOf(object) === REACT_SUSPENSE_LIST_TYPE;\n}\n\nexports.ContextConsumer = ContextConsumer;\nexports.ContextProvider = ContextProvider;\nexports.Element = Element;\nexports.ForwardRef = ForwardRef;\nexports.Fragment = Fragment;\nexports.Lazy = Lazy;\nexports.Memo = Memo;\nexports.Portal = Portal;\nexports.Profiler = Profiler;\nexports.StrictMode = StrictMode;\nexports.Suspense = Suspense;\nexports.SuspenseList = SuspenseList;\nexports.isAsyncMode = isAsyncMode;\nexports.isConcurrentMode = isConcurrentMode;\nexports.isContextConsumer = isContextConsumer;\nexports.isContextProvider = isContextProvider;\nexports.isElement = isElement;\nexports.isForwardRef = isForwardRef;\nexports.isFragment = isFragment;\nexports.isLazy = isLazy;\nexports.isMemo = isMemo;\nexports.isPortal = isPortal;\nexports.isProfiler = isProfiler;\nexports.isStrictMode = isStrictMode;\nexports.isSuspense = isSuspense;\nexports.isSuspenseList = isSuspenseList;\nexports.isValidElementType = isValidElementType;\nexports.typeOf = typeOf;\n })();\n}\n","'use strict';\n\nif (process.env.NODE_ENV === 'production') {\n module.exports = require('./cjs/react-is.production.min.js');\n} else {\n module.exports = require('./cjs/react-is.development.js');\n}\n","import { ForwardRef, Memo } from 'react-is';\n\n// Simplified polyfill for IE11 support\n// https://github.com/JamesMGreene/Function.name/blob/58b314d4a983110c3682f1228f845d39ccca1817/Function.name.js#L3\nconst fnNameMatchRegex = /^\\s*function(?:\\s|\\s*\\/\\*.*\\*\\/\\s*)+([^(\\s/]*)\\s*/;\nexport function getFunctionName(fn) {\n const match = `${fn}`.match(fnNameMatchRegex);\n const name = match && match[1];\n return name || '';\n}\nfunction getFunctionComponentName(Component, fallback = '') {\n return Component.displayName || Component.name || getFunctionName(Component) || fallback;\n}\nfunction getWrappedName(outerType, innerType, wrapperName) {\n const functionName = getFunctionComponentName(innerType);\n return outerType.displayName || (functionName !== '' ? `${wrapperName}(${functionName})` : wrapperName);\n}\n\n/**\n * cherry-pick from\n * https://github.com/facebook/react/blob/769b1f270e1251d9dbdce0fcbd9e92e502d059b8/packages/shared/getComponentName.js\n * originally forked from recompose/getDisplayName with added IE11 support\n */\nexport default function getDisplayName(Component) {\n if (Component == null) {\n return undefined;\n }\n if (typeof Component === 'string') {\n return Component;\n }\n if (typeof Component === 'function') {\n return getFunctionComponentName(Component, 'Component');\n }\n\n // TypeScript can't have components as objects but they exist in the form of `memo` or `Suspense`\n if (typeof Component === 'object') {\n switch (Component.$$typeof) {\n case ForwardRef:\n return getWrappedName(Component, Component.render, 'ForwardRef');\n case Memo:\n return getWrappedName(Component, Component.type, 'memo');\n default:\n return undefined;\n }\n }\n return undefined;\n}","export default function HTMLElementType(props, propName, componentName, location, propFullName) {\n if (process.env.NODE_ENV === 'production') {\n return null;\n }\n const propValue = props[propName];\n const safePropName = propFullName || propName;\n if (propValue == null) {\n return null;\n }\n if (propValue && propValue.nodeType !== 1) {\n return new Error(`Invalid ${location} \\`${safePropName}\\` supplied to \\`${componentName}\\`. ` + `Expected an HTMLElement.`);\n }\n return null;\n}","import PropTypes from 'prop-types';\nconst refType = PropTypes.oneOfType([PropTypes.func, PropTypes.object]);\nexport default refType;","import _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\n// It should to be noted that this function isn't equivalent to `text-transform: capitalize`.\n//\n// A strict capitalization should uppercase the first letter of each word in the sentence.\n// We only handle the first word.\nexport default function capitalize(string) {\n if (typeof string !== 'string') {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: \\`capitalize(string)\\` expects a string argument.` : _formatMuiErrorMessage(7));\n }\n return string.charAt(0).toUpperCase() + string.slice(1);\n}","/**\n * Safe chained function.\n *\n * Will only create a new function if needed,\n * otherwise will pass back existing functions or null.\n */\nexport default function createChainedFunction(...funcs) {\n return funcs.reduce((acc, func) => {\n if (func == null) {\n return acc;\n }\n return function chainedFunction(...args) {\n acc.apply(this, args);\n func.apply(this, args);\n };\n }, () => {});\n}","// Corresponds to 10 frames at 60 Hz.\n// A few bytes payload overhead when lodash/debounce is ~3 kB and debounce ~300 B.\nexport default function debounce(func, wait = 166) {\n let timeout;\n function debounced(...args) {\n const later = () => {\n // @ts-ignore\n func.apply(this, args);\n };\n clearTimeout(timeout);\n timeout = setTimeout(later, wait);\n }\n debounced.clear = () => {\n clearTimeout(timeout);\n };\n return debounced;\n}","export default function deprecatedPropType(validator, reason) {\n if (process.env.NODE_ENV === 'production') {\n return () => null;\n }\n return (props, propName, componentName, location, propFullName) => {\n const componentNameSafe = componentName || '<>';\n const propFullNameSafe = propFullName || propName;\n if (typeof props[propName] !== 'undefined') {\n return new Error(`The ${location} \\`${propFullNameSafe}\\` of ` + `\\`${componentNameSafe}\\` is deprecated. ${reason}`);\n }\n return null;\n };\n}","import * as React from 'react';\nexport default function isMuiElement(element, muiNames) {\n var _muiName, _element$type;\n return /*#__PURE__*/React.isValidElement(element) && muiNames.indexOf( // For server components `muiName` is avaialble in element.type._payload.value.muiName\n // relevant info - https://github.com/facebook/react/blob/2807d781a08db8e9873687fccc25c0f12b4fb3d4/packages/react/src/ReactLazy.js#L45\n // eslint-disable-next-line no-underscore-dangle\n (_muiName = element.type.muiName) != null ? _muiName : (_element$type = element.type) == null || (_element$type = _element$type._payload) == null || (_element$type = _element$type.value) == null ? void 0 : _element$type.muiName) !== -1;\n}","export default function ownerDocument(node) {\n return node && node.ownerDocument || document;\n}","import ownerDocument from '../ownerDocument';\nexport default function ownerWindow(node) {\n const doc = ownerDocument(node);\n return doc.defaultView || window;\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nexport default function requirePropFactory(componentNameInError, Component) {\n if (process.env.NODE_ENV === 'production') {\n return () => null;\n }\n\n // eslint-disable-next-line react/forbid-foreign-prop-types\n const prevPropTypes = Component ? _extends({}, Component.propTypes) : null;\n const requireProp = requiredProp => (props, propName, componentName, location, propFullName, ...args) => {\n const propFullNameSafe = propFullName || propName;\n const defaultTypeChecker = prevPropTypes == null ? void 0 : prevPropTypes[propFullNameSafe];\n if (defaultTypeChecker) {\n const typeCheckerResult = defaultTypeChecker(props, propName, componentName, location, propFullName, ...args);\n if (typeCheckerResult) {\n return typeCheckerResult;\n }\n }\n if (typeof props[propName] !== 'undefined' && !props[requiredProp]) {\n return new Error(`The prop \\`${propFullNameSafe}\\` of ` + `\\`${componentNameInError}\\` can only be used together with the \\`${requiredProp}\\` prop.`);\n }\n return null;\n };\n return requireProp;\n}","/**\n * TODO v5: consider making it private\n *\n * passes {value} to {ref}\n *\n * WARNING: Be sure to only call this inside a callback that is passed as a ref.\n * Otherwise, make sure to cleanup the previous {ref} if it changes. See\n * https://github.com/mui/material-ui/issues/13539\n *\n * Useful if you want to expose the ref of an inner component to the public API\n * while still using it inside the component.\n * @param ref A ref callback or ref object. If anything falsy, this is a no-op.\n */\nexport default function setRef(ref, value) {\n if (typeof ref === 'function') {\n ref(value);\n } else if (ref) {\n ref.current = value;\n }\n}","'use client';\n\nimport * as React from 'react';\n\n/**\n * A version of `React.useLayoutEffect` that does not show a warning when server-side rendering.\n * This is useful for effects that are only needed for client-side rendering but not for SSR.\n *\n * Before you use this hook, make sure to read https://gist.github.com/gaearon/e7d97cdf38a2907924ea12e4ebdf3c85\n * and confirm it doesn't apply to your use-case.\n */\nconst useEnhancedEffect = typeof window !== 'undefined' ? React.useLayoutEffect : React.useEffect;\nexport default useEnhancedEffect;","'use client';\n\nimport * as React from 'react';\nlet globalId = 0;\nfunction useGlobalId(idOverride) {\n const [defaultId, setDefaultId] = React.useState(idOverride);\n const id = idOverride || defaultId;\n React.useEffect(() => {\n if (defaultId == null) {\n // Fallback to this default id when possible.\n // Use the incrementing value for client-side rendering only.\n // We can't use it server-side.\n // If you want to use random values please consider the Birthday Problem: https://en.wikipedia.org/wiki/Birthday_problem\n globalId += 1;\n setDefaultId(`mui-${globalId}`);\n }\n }, [defaultId]);\n return id;\n}\n\n// downstream bundlers may remove unnecessary concatenation, but won't remove toString call -- Workaround for https://github.com/webpack/webpack/issues/14814\nconst maybeReactUseId = React['useId'.toString()];\n/**\n *\n * @example
\n * @param idOverride\n * @returns {string}\n */\nexport default function useId(idOverride) {\n if (maybeReactUseId !== undefined) {\n const reactId = maybeReactUseId();\n return idOverride != null ? idOverride : reactId;\n }\n // eslint-disable-next-line react-hooks/rules-of-hooks -- `React.useId` is invariant at runtime.\n return useGlobalId(idOverride);\n}","export default function unsupportedProp(props, propName, componentName, location, propFullName) {\n if (process.env.NODE_ENV === 'production') {\n return null;\n }\n const propFullNameSafe = propFullName || propName;\n if (typeof props[propName] !== 'undefined') {\n return new Error(`The prop \\`${propFullNameSafe}\\` is not supported. Please remove it.`);\n }\n return null;\n}","'use client';\n\n/* eslint-disable react-hooks/rules-of-hooks, react-hooks/exhaustive-deps */\nimport * as React from 'react';\nexport default function useControlled({\n controlled,\n default: defaultProp,\n name,\n state = 'value'\n}) {\n // isControlled is ignored in the hook dependency lists as it should never change.\n const {\n current: isControlled\n } = React.useRef(controlled !== undefined);\n const [valueState, setValue] = React.useState(defaultProp);\n const value = isControlled ? controlled : valueState;\n if (process.env.NODE_ENV !== 'production') {\n React.useEffect(() => {\n if (isControlled !== (controlled !== undefined)) {\n console.error([`MUI: A component is changing the ${isControlled ? '' : 'un'}controlled ${state} state of ${name} to be ${isControlled ? 'un' : ''}controlled.`, 'Elements should not switch from uncontrolled to controlled (or vice versa).', `Decide between using a controlled or uncontrolled ${name} ` + 'element for the lifetime of the component.', \"The nature of the state is determined during the first render. It's considered controlled if the value is not `undefined`.\", 'More info: https://fb.me/react-controlled-components'].join('\\n'));\n }\n }, [state, name, controlled]);\n const {\n current: defaultValue\n } = React.useRef(defaultProp);\n React.useEffect(() => {\n if (!isControlled && defaultValue !== defaultProp) {\n console.error([`MUI: A component is changing the default ${state} state of an uncontrolled ${name} after being initialized. ` + `To suppress this warning opt to use a controlled ${name}.`].join('\\n'));\n }\n }, [JSON.stringify(defaultProp)]);\n }\n const setValueIfUncontrolled = React.useCallback(newValue => {\n if (!isControlled) {\n setValue(newValue);\n }\n }, []);\n return [value, setValueIfUncontrolled];\n}","'use client';\n\nimport * as React from 'react';\nimport useEnhancedEffect from '../useEnhancedEffect';\n\n/**\n * Inspired by https://github.com/facebook/react/issues/14099#issuecomment-440013892\n * See RFC in https://github.com/reactjs/rfcs/pull/220\n */\n\nfunction useEventCallback(fn) {\n const ref = React.useRef(fn);\n useEnhancedEffect(() => {\n ref.current = fn;\n });\n return React.useRef((...args) =>\n // @ts-expect-error hide `this`\n (0, ref.current)(...args)).current;\n}\nexport default useEventCallback;","'use client';\n\nimport * as React from 'react';\nimport setRef from '../setRef';\nexport default function useForkRef(...refs) {\n /**\n * This will create a new function if the refs passed to this hook change and are all defined.\n * This means react will call the old forkRef with `null` and the new forkRef\n * with the ref. Cleanup naturally emerges from this behavior.\n */\n return React.useMemo(() => {\n if (refs.every(ref => ref == null)) {\n return null;\n }\n return instance => {\n refs.forEach(ref => {\n setRef(ref, instance);\n });\n };\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, refs);\n}","'use client';\n\nimport * as React from 'react';\nconst UNINITIALIZED = {};\n\n/**\n * A React.useRef() that is initialized lazily with a function. Note that it accepts an optional\n * initialization argument, so the initialization function doesn't need to be an inline closure.\n *\n * @usage\n * const ref = useLazyRef(sortColumns, columns)\n */\nexport default function useLazyRef(init, initArg) {\n const ref = React.useRef(UNINITIALIZED);\n if (ref.current === UNINITIALIZED) {\n ref.current = init(initArg);\n }\n return ref;\n}","'use client';\n\nimport * as React from 'react';\nconst EMPTY = [];\n\n/**\n * A React.useEffect equivalent that runs once, when the component is mounted.\n */\nexport default function useOnMount(fn) {\n /* eslint-disable react-hooks/exhaustive-deps */\n React.useEffect(fn, EMPTY);\n /* eslint-enable react-hooks/exhaustive-deps */\n}","'use client';\n\nimport useLazyRef from '../useLazyRef/useLazyRef';\nimport useOnMount from '../useOnMount/useOnMount';\nexport class Timeout {\n constructor() {\n this.currentId = null;\n this.clear = () => {\n if (this.currentId !== null) {\n clearTimeout(this.currentId);\n this.currentId = null;\n }\n };\n this.disposeEffect = () => {\n return this.clear;\n };\n }\n static create() {\n return new Timeout();\n }\n /**\n * Executes `fn` after `delay`, clearing any previously scheduled call.\n */\n start(delay, fn) {\n this.clear();\n this.currentId = setTimeout(() => {\n this.currentId = null;\n fn();\n }, delay);\n }\n}\nexport default function useTimeout() {\n const timeout = useLazyRef(Timeout.create).current;\n useOnMount(timeout.disposeEffect);\n return timeout;\n}","'use client';\n\n// based on https://github.com/WICG/focus-visible/blob/v4.1.5/src/focus-visible.js\nimport * as React from 'react';\nimport { Timeout } from '../useTimeout/useTimeout';\nlet hadKeyboardEvent = true;\nlet hadFocusVisibleRecently = false;\nconst hadFocusVisibleRecentlyTimeout = new Timeout();\nconst inputTypesWhitelist = {\n text: true,\n search: true,\n url: true,\n tel: true,\n email: true,\n password: true,\n number: true,\n date: true,\n month: true,\n week: true,\n time: true,\n datetime: true,\n 'datetime-local': true\n};\n\n/**\n * Computes whether the given element should automatically trigger the\n * `focus-visible` class being added, i.e. whether it should always match\n * `:focus-visible` when focused.\n * @param {Element} node\n * @returns {boolean}\n */\nfunction focusTriggersKeyboardModality(node) {\n const {\n type,\n tagName\n } = node;\n if (tagName === 'INPUT' && inputTypesWhitelist[type] && !node.readOnly) {\n return true;\n }\n if (tagName === 'TEXTAREA' && !node.readOnly) {\n return true;\n }\n if (node.isContentEditable) {\n return true;\n }\n return false;\n}\n\n/**\n * Keep track of our keyboard modality state with `hadKeyboardEvent`.\n * If the most recent user interaction was via the keyboard;\n * and the key press did not include a meta, alt/option, or control key;\n * then the modality is keyboard. Otherwise, the modality is not keyboard.\n * @param {KeyboardEvent} event\n */\nfunction handleKeyDown(event) {\n if (event.metaKey || event.altKey || event.ctrlKey) {\n return;\n }\n hadKeyboardEvent = true;\n}\n\n/**\n * If at any point a user clicks with a pointing device, ensure that we change\n * the modality away from keyboard.\n * This avoids the situation where a user presses a key on an already focused\n * element, and then clicks on a different element, focusing it with a\n * pointing device, while we still think we're in keyboard modality.\n */\nfunction handlePointerDown() {\n hadKeyboardEvent = false;\n}\nfunction handleVisibilityChange() {\n if (this.visibilityState === 'hidden') {\n // If the tab becomes active again, the browser will handle calling focus\n // on the element (Safari actually calls it twice).\n // If this tab change caused a blur on an element with focus-visible,\n // re-apply the class when the user switches back to the tab.\n if (hadFocusVisibleRecently) {\n hadKeyboardEvent = true;\n }\n }\n}\nfunction prepare(doc) {\n doc.addEventListener('keydown', handleKeyDown, true);\n doc.addEventListener('mousedown', handlePointerDown, true);\n doc.addEventListener('pointerdown', handlePointerDown, true);\n doc.addEventListener('touchstart', handlePointerDown, true);\n doc.addEventListener('visibilitychange', handleVisibilityChange, true);\n}\nexport function teardown(doc) {\n doc.removeEventListener('keydown', handleKeyDown, true);\n doc.removeEventListener('mousedown', handlePointerDown, true);\n doc.removeEventListener('pointerdown', handlePointerDown, true);\n doc.removeEventListener('touchstart', handlePointerDown, true);\n doc.removeEventListener('visibilitychange', handleVisibilityChange, true);\n}\nfunction isFocusVisible(event) {\n const {\n target\n } = event;\n try {\n return target.matches(':focus-visible');\n } catch (error) {\n // Browsers not implementing :focus-visible will throw a SyntaxError.\n // We use our own heuristic for those browsers.\n // Rethrow might be better if it's not the expected error but do we really\n // want to crash if focus-visible malfunctioned?\n }\n\n // No need for validFocusTarget check. The user does that by attaching it to\n // focusable events only.\n return hadKeyboardEvent || focusTriggersKeyboardModality(target);\n}\nexport default function useIsFocusVisible() {\n const ref = React.useCallback(node => {\n if (node != null) {\n prepare(node.ownerDocument);\n }\n }, []);\n const isFocusVisibleRef = React.useRef(false);\n\n /**\n * Should be called if a blur event is fired\n */\n function handleBlurVisible() {\n // checking against potential state variable does not suffice if we focus and blur synchronously.\n // React wouldn't have time to trigger a re-render so `focusVisible` would be stale.\n // Ideally we would adjust `isFocusVisible(event)` to look at `relatedTarget` for blur events.\n // This doesn't work in IE11 due to https://github.com/facebook/react/issues/3751\n // TODO: check again if React releases their internal changes to focus event handling (https://github.com/facebook/react/pull/19186).\n if (isFocusVisibleRef.current) {\n // To detect a tab/window switch, we look for a blur event followed\n // rapidly by a visibility change.\n // If we don't see a visibility change within 100ms, it's probably a\n // regular focus change.\n hadFocusVisibleRecently = true;\n hadFocusVisibleRecentlyTimeout.start(100, () => {\n hadFocusVisibleRecently = false;\n });\n isFocusVisibleRef.current = false;\n return true;\n }\n return false;\n }\n\n /**\n * Should be called if a blur event is fired\n */\n function handleFocusVisible(event) {\n if (isFocusVisible(event)) {\n isFocusVisibleRef.current = true;\n return true;\n }\n return false;\n }\n return {\n isFocusVisibleRef,\n onFocus: handleFocusVisible,\n onBlur: handleBlurVisible,\n ref\n };\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\n/**\n * Add keys, values of `defaultProps` that does not exist in `props`\n * @param {object} defaultProps\n * @param {object} props\n * @returns {object} resolved props\n */\nexport default function resolveProps(defaultProps, props) {\n const output = _extends({}, props);\n Object.keys(defaultProps).forEach(propName => {\n if (propName.toString().match(/^(components|slots)$/)) {\n output[propName] = _extends({}, defaultProps[propName], output[propName]);\n } else if (propName.toString().match(/^(componentsProps|slotProps)$/)) {\n const defaultSlotProps = defaultProps[propName] || {};\n const slotProps = props[propName];\n output[propName] = {};\n if (!slotProps || !Object.keys(slotProps)) {\n // Reduce the iteration if the slot props is empty\n output[propName] = defaultSlotProps;\n } else if (!defaultSlotProps || !Object.keys(defaultSlotProps)) {\n // Reduce the iteration if the default slot props is empty\n output[propName] = slotProps;\n } else {\n output[propName] = _extends({}, slotProps);\n Object.keys(defaultSlotProps).forEach(slotPropName => {\n output[propName][slotPropName] = resolveProps(defaultSlotProps[slotPropName], slotProps[slotPropName]);\n });\n }\n } else if (output[propName] === undefined) {\n output[propName] = defaultProps[propName];\n }\n });\n return output;\n}","export default function composeClasses(slots, getUtilityClass, classes = undefined) {\n const output = {};\n Object.keys(slots).forEach(\n // `Object.keys(slots)` can't be wider than `T` because we infer `T` from `slots`.\n // @ts-expect-error https://github.com/microsoft/TypeScript/pull/12253#issuecomment-263132208\n slot => {\n output[slot] = slots[slot].reduce((acc, key) => {\n if (key) {\n const utilityClass = getUtilityClass(key);\n if (utilityClass !== '') {\n acc.push(utilityClass);\n }\n if (classes && classes[key]) {\n acc.push(classes[key]);\n }\n }\n return acc;\n }, []).join(' ');\n });\n return output;\n}","const defaultGenerator = componentName => componentName;\nconst createClassNameGenerator = () => {\n let generate = defaultGenerator;\n return {\n configure(generator) {\n generate = generator;\n },\n generate(componentName) {\n return generate(componentName);\n },\n reset() {\n generate = defaultGenerator;\n }\n };\n};\nconst ClassNameGenerator = createClassNameGenerator();\nexport default ClassNameGenerator;","import ClassNameGenerator from '../ClassNameGenerator';\nexport const globalStateClasses = {\n active: 'active',\n checked: 'checked',\n completed: 'completed',\n disabled: 'disabled',\n error: 'error',\n expanded: 'expanded',\n focused: 'focused',\n focusVisible: 'focusVisible',\n open: 'open',\n readOnly: 'readOnly',\n required: 'required',\n selected: 'selected'\n};\nexport default function generateUtilityClass(componentName, slot, globalStatePrefix = 'Mui') {\n const globalStateClass = globalStateClasses[slot];\n return globalStateClass ? `${globalStatePrefix}-${globalStateClass}` : `${ClassNameGenerator.generate(componentName)}-${slot}`;\n}\nexport function isGlobalState(slot) {\n return globalStateClasses[slot] !== undefined;\n}","import generateUtilityClass from '../generateUtilityClass';\nexport default function generateUtilityClasses(componentName, slots, globalStatePrefix = 'Mui') {\n const result = {};\n slots.forEach(slot => {\n result[slot] = generateUtilityClass(componentName, slot, globalStatePrefix);\n });\n return result;\n}","function clamp(val, min = Number.MIN_SAFE_INTEGER, max = Number.MAX_SAFE_INTEGER) {\n return Math.max(min, Math.min(val, max));\n}\nexport default clamp;","export default function _objectWithoutPropertiesLoose(source, excluded) {\n if (source == null) return {};\n var target = {};\n var sourceKeys = Object.keys(source);\n var key, i;\n for (i = 0; i < sourceKeys.length; i++) {\n key = sourceKeys[i];\n if (excluded.indexOf(key) >= 0) continue;\n target[key] = source[key];\n }\n return target;\n}","import _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nconst _excluded = [\"values\", \"unit\", \"step\"];\n// Sorted ASC by size. That's important.\n// It can't be configured as it's used statically for propTypes.\nexport const breakpointKeys = ['xs', 'sm', 'md', 'lg', 'xl'];\nconst sortBreakpointsValues = values => {\n const breakpointsAsArray = Object.keys(values).map(key => ({\n key,\n val: values[key]\n })) || [];\n // Sort in ascending order\n breakpointsAsArray.sort((breakpoint1, breakpoint2) => breakpoint1.val - breakpoint2.val);\n return breakpointsAsArray.reduce((acc, obj) => {\n return _extends({}, acc, {\n [obj.key]: obj.val\n });\n }, {});\n};\n\n// Keep in mind that @media is inclusive by the CSS specification.\nexport default function createBreakpoints(breakpoints) {\n const {\n // The breakpoint **start** at this value.\n // For instance with the first breakpoint xs: [xs, sm).\n values = {\n xs: 0,\n // phone\n sm: 600,\n // tablet\n md: 900,\n // small laptop\n lg: 1200,\n // desktop\n xl: 1536 // large screen\n },\n unit = 'px',\n step = 5\n } = breakpoints,\n other = _objectWithoutPropertiesLoose(breakpoints, _excluded);\n const sortedValues = sortBreakpointsValues(values);\n const keys = Object.keys(sortedValues);\n function up(key) {\n const value = typeof values[key] === 'number' ? values[key] : key;\n return `@media (min-width:${value}${unit})`;\n }\n function down(key) {\n const value = typeof values[key] === 'number' ? values[key] : key;\n return `@media (max-width:${value - step / 100}${unit})`;\n }\n function between(start, end) {\n const endIndex = keys.indexOf(end);\n return `@media (min-width:${typeof values[start] === 'number' ? values[start] : start}${unit}) and ` + `(max-width:${(endIndex !== -1 && typeof values[keys[endIndex]] === 'number' ? values[keys[endIndex]] : end) - step / 100}${unit})`;\n }\n function only(key) {\n if (keys.indexOf(key) + 1 < keys.length) {\n return between(key, keys[keys.indexOf(key) + 1]);\n }\n return up(key);\n }\n function not(key) {\n // handle first and last key separately, for better readability\n const keyIndex = keys.indexOf(key);\n if (keyIndex === 0) {\n return up(keys[1]);\n }\n if (keyIndex === keys.length - 1) {\n return down(keys[keyIndex]);\n }\n return between(key, keys[keys.indexOf(key) + 1]).replace('@media', '@media not all and');\n }\n return _extends({\n keys,\n values: sortedValues,\n up,\n down,\n between,\n only,\n not,\n unit\n }, other);\n}","const shape = {\n borderRadius: 4\n};\nexport default shape;","import PropTypes from 'prop-types';\nconst responsivePropType = process.env.NODE_ENV !== 'production' ? PropTypes.oneOfType([PropTypes.number, PropTypes.string, PropTypes.object, PropTypes.array]) : {};\nexport default responsivePropType;","import deepmerge from '@mui/utils/deepmerge';\nfunction merge(acc, item) {\n if (!item) {\n return acc;\n }\n return deepmerge(acc, item, {\n clone: false // No need to clone deep, it's way faster.\n });\n}\nexport default merge;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport PropTypes from 'prop-types';\nimport deepmerge from '@mui/utils/deepmerge';\nimport merge from './merge';\n\n// The breakpoint **start** at this value.\n// For instance with the first breakpoint xs: [xs, sm[.\nexport const values = {\n xs: 0,\n // phone\n sm: 600,\n // tablet\n md: 900,\n // small laptop\n lg: 1200,\n // desktop\n xl: 1536 // large screen\n};\nconst defaultBreakpoints = {\n // Sorted ASC by size. That's important.\n // It can't be configured as it's used statically for propTypes.\n keys: ['xs', 'sm', 'md', 'lg', 'xl'],\n up: key => `@media (min-width:${values[key]}px)`\n};\nexport function handleBreakpoints(props, propValue, styleFromPropValue) {\n const theme = props.theme || {};\n if (Array.isArray(propValue)) {\n const themeBreakpoints = theme.breakpoints || defaultBreakpoints;\n return propValue.reduce((acc, item, index) => {\n acc[themeBreakpoints.up(themeBreakpoints.keys[index])] = styleFromPropValue(propValue[index]);\n return acc;\n }, {});\n }\n if (typeof propValue === 'object') {\n const themeBreakpoints = theme.breakpoints || defaultBreakpoints;\n return Object.keys(propValue).reduce((acc, breakpoint) => {\n // key is breakpoint\n if (Object.keys(themeBreakpoints.values || values).indexOf(breakpoint) !== -1) {\n const mediaKey = themeBreakpoints.up(breakpoint);\n acc[mediaKey] = styleFromPropValue(propValue[breakpoint], breakpoint);\n } else {\n const cssKey = breakpoint;\n acc[cssKey] = propValue[cssKey];\n }\n return acc;\n }, {});\n }\n const output = styleFromPropValue(propValue);\n return output;\n}\nfunction breakpoints(styleFunction) {\n // false positive\n // eslint-disable-next-line react/function-component-definition\n const newStyleFunction = props => {\n const theme = props.theme || {};\n const base = styleFunction(props);\n const themeBreakpoints = theme.breakpoints || defaultBreakpoints;\n const extended = themeBreakpoints.keys.reduce((acc, key) => {\n if (props[key]) {\n acc = acc || {};\n acc[themeBreakpoints.up(key)] = styleFunction(_extends({\n theme\n }, props[key]));\n }\n return acc;\n }, null);\n return merge(base, extended);\n };\n newStyleFunction.propTypes = process.env.NODE_ENV !== 'production' ? _extends({}, styleFunction.propTypes, {\n xs: PropTypes.object,\n sm: PropTypes.object,\n md: PropTypes.object,\n lg: PropTypes.object,\n xl: PropTypes.object\n }) : {};\n newStyleFunction.filterProps = ['xs', 'sm', 'md', 'lg', 'xl', ...styleFunction.filterProps];\n return newStyleFunction;\n}\nexport function createEmptyBreakpointObject(breakpointsInput = {}) {\n var _breakpointsInput$key;\n const breakpointsInOrder = (_breakpointsInput$key = breakpointsInput.keys) == null ? void 0 : _breakpointsInput$key.reduce((acc, key) => {\n const breakpointStyleKey = breakpointsInput.up(key);\n acc[breakpointStyleKey] = {};\n return acc;\n }, {});\n return breakpointsInOrder || {};\n}\nexport function removeUnusedBreakpoints(breakpointKeys, style) {\n return breakpointKeys.reduce((acc, key) => {\n const breakpointOutput = acc[key];\n const isBreakpointUnused = !breakpointOutput || Object.keys(breakpointOutput).length === 0;\n if (isBreakpointUnused) {\n delete acc[key];\n }\n return acc;\n }, style);\n}\nexport function mergeBreakpointsInOrder(breakpointsInput, ...styles) {\n const emptyBreakpoints = createEmptyBreakpointObject(breakpointsInput);\n const mergedOutput = [emptyBreakpoints, ...styles].reduce((prev, next) => deepmerge(prev, next), {});\n return removeUnusedBreakpoints(Object.keys(emptyBreakpoints), mergedOutput);\n}\n\n// compute base for responsive values; e.g.,\n// [1,2,3] => {xs: true, sm: true, md: true}\n// {xs: 1, sm: 2, md: 3} => {xs: true, sm: true, md: true}\nexport function computeBreakpointsBase(breakpointValues, themeBreakpoints) {\n // fixed value\n if (typeof breakpointValues !== 'object') {\n return {};\n }\n const base = {};\n const breakpointsKeys = Object.keys(themeBreakpoints);\n if (Array.isArray(breakpointValues)) {\n breakpointsKeys.forEach((breakpoint, i) => {\n if (i < breakpointValues.length) {\n base[breakpoint] = true;\n }\n });\n } else {\n breakpointsKeys.forEach(breakpoint => {\n if (breakpointValues[breakpoint] != null) {\n base[breakpoint] = true;\n }\n });\n }\n return base;\n}\nexport function resolveBreakpointValues({\n values: breakpointValues,\n breakpoints: themeBreakpoints,\n base: customBase\n}) {\n const base = customBase || computeBreakpointsBase(breakpointValues, themeBreakpoints);\n const keys = Object.keys(base);\n if (keys.length === 0) {\n return breakpointValues;\n }\n let previous;\n return keys.reduce((acc, breakpoint, i) => {\n if (Array.isArray(breakpointValues)) {\n acc[breakpoint] = breakpointValues[i] != null ? breakpointValues[i] : breakpointValues[previous];\n previous = i;\n } else if (typeof breakpointValues === 'object') {\n acc[breakpoint] = breakpointValues[breakpoint] != null ? breakpointValues[breakpoint] : breakpointValues[previous];\n previous = breakpoint;\n } else {\n acc[breakpoint] = breakpointValues;\n }\n return acc;\n }, {});\n}\nexport default breakpoints;","import capitalize from '@mui/utils/capitalize';\nimport responsivePropType from './responsivePropType';\nimport { handleBreakpoints } from './breakpoints';\nexport function getPath(obj, path, checkVars = true) {\n if (!path || typeof path !== 'string') {\n return null;\n }\n\n // Check if CSS variables are used\n if (obj && obj.vars && checkVars) {\n const val = `vars.${path}`.split('.').reduce((acc, item) => acc && acc[item] ? acc[item] : null, obj);\n if (val != null) {\n return val;\n }\n }\n return path.split('.').reduce((acc, item) => {\n if (acc && acc[item] != null) {\n return acc[item];\n }\n return null;\n }, obj);\n}\nexport function getStyleValue(themeMapping, transform, propValueFinal, userValue = propValueFinal) {\n let value;\n if (typeof themeMapping === 'function') {\n value = themeMapping(propValueFinal);\n } else if (Array.isArray(themeMapping)) {\n value = themeMapping[propValueFinal] || userValue;\n } else {\n value = getPath(themeMapping, propValueFinal) || userValue;\n }\n if (transform) {\n value = transform(value, userValue, themeMapping);\n }\n return value;\n}\nfunction style(options) {\n const {\n prop,\n cssProperty = options.prop,\n themeKey,\n transform\n } = options;\n\n // false positive\n // eslint-disable-next-line react/function-component-definition\n const fn = props => {\n if (props[prop] == null) {\n return null;\n }\n const propValue = props[prop];\n const theme = props.theme;\n const themeMapping = getPath(theme, themeKey) || {};\n const styleFromPropValue = propValueFinal => {\n let value = getStyleValue(themeMapping, transform, propValueFinal);\n if (propValueFinal === value && typeof propValueFinal === 'string') {\n // Haven't found value\n value = getStyleValue(themeMapping, transform, `${prop}${propValueFinal === 'default' ? '' : capitalize(propValueFinal)}`, propValueFinal);\n }\n if (cssProperty === false) {\n return value;\n }\n return {\n [cssProperty]: value\n };\n };\n return handleBreakpoints(props, propValue, styleFromPropValue);\n };\n fn.propTypes = process.env.NODE_ENV !== 'production' ? {\n [prop]: responsivePropType\n } : {};\n fn.filterProps = [prop];\n return fn;\n}\nexport default style;","export default function memoize(fn) {\n const cache = {};\n return arg => {\n if (cache[arg] === undefined) {\n cache[arg] = fn(arg);\n }\n return cache[arg];\n };\n}","import responsivePropType from './responsivePropType';\nimport { handleBreakpoints } from './breakpoints';\nimport { getPath } from './style';\nimport merge from './merge';\nimport memoize from './memoize';\nconst properties = {\n m: 'margin',\n p: 'padding'\n};\nconst directions = {\n t: 'Top',\n r: 'Right',\n b: 'Bottom',\n l: 'Left',\n x: ['Left', 'Right'],\n y: ['Top', 'Bottom']\n};\nconst aliases = {\n marginX: 'mx',\n marginY: 'my',\n paddingX: 'px',\n paddingY: 'py'\n};\n\n// memoize() impact:\n// From 300,000 ops/sec\n// To 350,000 ops/sec\nconst getCssProperties = memoize(prop => {\n // It's not a shorthand notation.\n if (prop.length > 2) {\n if (aliases[prop]) {\n prop = aliases[prop];\n } else {\n return [prop];\n }\n }\n const [a, b] = prop.split('');\n const property = properties[a];\n const direction = directions[b] || '';\n return Array.isArray(direction) ? direction.map(dir => property + dir) : [property + direction];\n});\nexport const marginKeys = ['m', 'mt', 'mr', 'mb', 'ml', 'mx', 'my', 'margin', 'marginTop', 'marginRight', 'marginBottom', 'marginLeft', 'marginX', 'marginY', 'marginInline', 'marginInlineStart', 'marginInlineEnd', 'marginBlock', 'marginBlockStart', 'marginBlockEnd'];\nexport const paddingKeys = ['p', 'pt', 'pr', 'pb', 'pl', 'px', 'py', 'padding', 'paddingTop', 'paddingRight', 'paddingBottom', 'paddingLeft', 'paddingX', 'paddingY', 'paddingInline', 'paddingInlineStart', 'paddingInlineEnd', 'paddingBlock', 'paddingBlockStart', 'paddingBlockEnd'];\nconst spacingKeys = [...marginKeys, ...paddingKeys];\nexport function createUnaryUnit(theme, themeKey, defaultValue, propName) {\n var _getPath;\n const themeSpacing = (_getPath = getPath(theme, themeKey, false)) != null ? _getPath : defaultValue;\n if (typeof themeSpacing === 'number') {\n return abs => {\n if (typeof abs === 'string') {\n return abs;\n }\n if (process.env.NODE_ENV !== 'production') {\n if (typeof abs !== 'number') {\n console.error(`MUI: Expected ${propName} argument to be a number or a string, got ${abs}.`);\n }\n }\n return themeSpacing * abs;\n };\n }\n if (Array.isArray(themeSpacing)) {\n return abs => {\n if (typeof abs === 'string') {\n return abs;\n }\n if (process.env.NODE_ENV !== 'production') {\n if (!Number.isInteger(abs)) {\n console.error([`MUI: The \\`theme.${themeKey}\\` array type cannot be combined with non integer values.` + `You should either use an integer value that can be used as index, or define the \\`theme.${themeKey}\\` as a number.`].join('\\n'));\n } else if (abs > themeSpacing.length - 1) {\n console.error([`MUI: The value provided (${abs}) overflows.`, `The supported values are: ${JSON.stringify(themeSpacing)}.`, `${abs} > ${themeSpacing.length - 1}, you need to add the missing values.`].join('\\n'));\n }\n }\n return themeSpacing[abs];\n };\n }\n if (typeof themeSpacing === 'function') {\n return themeSpacing;\n }\n if (process.env.NODE_ENV !== 'production') {\n console.error([`MUI: The \\`theme.${themeKey}\\` value (${themeSpacing}) is invalid.`, 'It should be a number, an array or a function.'].join('\\n'));\n }\n return () => undefined;\n}\nexport function createUnarySpacing(theme) {\n return createUnaryUnit(theme, 'spacing', 8, 'spacing');\n}\nexport function getValue(transformer, propValue) {\n if (typeof propValue === 'string' || propValue == null) {\n return propValue;\n }\n const abs = Math.abs(propValue);\n const transformed = transformer(abs);\n if (propValue >= 0) {\n return transformed;\n }\n if (typeof transformed === 'number') {\n return -transformed;\n }\n return `-${transformed}`;\n}\nexport function getStyleFromPropValue(cssProperties, transformer) {\n return propValue => cssProperties.reduce((acc, cssProperty) => {\n acc[cssProperty] = getValue(transformer, propValue);\n return acc;\n }, {});\n}\nfunction resolveCssProperty(props, keys, prop, transformer) {\n // Using a hash computation over an array iteration could be faster, but with only 28 items,\n // it's doesn't worth the bundle size.\n if (keys.indexOf(prop) === -1) {\n return null;\n }\n const cssProperties = getCssProperties(prop);\n const styleFromPropValue = getStyleFromPropValue(cssProperties, transformer);\n const propValue = props[prop];\n return handleBreakpoints(props, propValue, styleFromPropValue);\n}\nfunction style(props, keys) {\n const transformer = createUnarySpacing(props.theme);\n return Object.keys(props).map(prop => resolveCssProperty(props, keys, prop, transformer)).reduce(merge, {});\n}\nexport function margin(props) {\n return style(props, marginKeys);\n}\nmargin.propTypes = process.env.NODE_ENV !== 'production' ? marginKeys.reduce((obj, key) => {\n obj[key] = responsivePropType;\n return obj;\n}, {}) : {};\nmargin.filterProps = marginKeys;\nexport function padding(props) {\n return style(props, paddingKeys);\n}\npadding.propTypes = process.env.NODE_ENV !== 'production' ? paddingKeys.reduce((obj, key) => {\n obj[key] = responsivePropType;\n return obj;\n}, {}) : {};\npadding.filterProps = paddingKeys;\nfunction spacing(props) {\n return style(props, spacingKeys);\n}\nspacing.propTypes = process.env.NODE_ENV !== 'production' ? spacingKeys.reduce((obj, key) => {\n obj[key] = responsivePropType;\n return obj;\n}, {}) : {};\nspacing.filterProps = spacingKeys;\nexport default spacing;","import { createUnarySpacing } from '../spacing';\n\n// The different signatures imply different meaning for their arguments that can't be expressed structurally.\n// We express the difference with variable names.\n\nexport default function createSpacing(spacingInput = 8) {\n // Already transformed.\n if (spacingInput.mui) {\n return spacingInput;\n }\n\n // Material Design layouts are visually balanced. Most measurements align to an 8dp grid, which aligns both spacing and the overall layout.\n // Smaller components, such as icons, can align to a 4dp grid.\n // https://m2.material.io/design/layout/understanding-layout.html\n const transform = createUnarySpacing({\n spacing: spacingInput\n });\n const spacing = (...argsInput) => {\n if (process.env.NODE_ENV !== 'production') {\n if (!(argsInput.length <= 4)) {\n console.error(`MUI: Too many arguments provided, expected between 0 and 4, got ${argsInput.length}`);\n }\n }\n const args = argsInput.length === 0 ? [1] : argsInput;\n return args.map(argument => {\n const output = transform(argument);\n return typeof output === 'number' ? `${output}px` : output;\n }).join(' ');\n };\n spacing.mui = true;\n return spacing;\n}","import merge from './merge';\nfunction compose(...styles) {\n const handlers = styles.reduce((acc, style) => {\n style.filterProps.forEach(prop => {\n acc[prop] = style;\n });\n return acc;\n }, {});\n\n // false positive\n // eslint-disable-next-line react/function-component-definition\n const fn = props => {\n return Object.keys(props).reduce((acc, prop) => {\n if (handlers[prop]) {\n return merge(acc, handlers[prop](props));\n }\n return acc;\n }, {});\n };\n fn.propTypes = process.env.NODE_ENV !== 'production' ? styles.reduce((acc, style) => Object.assign(acc, style.propTypes), {}) : {};\n fn.filterProps = styles.reduce((acc, style) => acc.concat(style.filterProps), []);\n return fn;\n}\nexport default compose;","import responsivePropType from './responsivePropType';\nimport style from './style';\nimport compose from './compose';\nimport { createUnaryUnit, getValue } from './spacing';\nimport { handleBreakpoints } from './breakpoints';\nexport function borderTransform(value) {\n if (typeof value !== 'number') {\n return value;\n }\n return `${value}px solid`;\n}\nfunction createBorderStyle(prop, transform) {\n return style({\n prop,\n themeKey: 'borders',\n transform\n });\n}\nexport const border = createBorderStyle('border', borderTransform);\nexport const borderTop = createBorderStyle('borderTop', borderTransform);\nexport const borderRight = createBorderStyle('borderRight', borderTransform);\nexport const borderBottom = createBorderStyle('borderBottom', borderTransform);\nexport const borderLeft = createBorderStyle('borderLeft', borderTransform);\nexport const borderColor = createBorderStyle('borderColor');\nexport const borderTopColor = createBorderStyle('borderTopColor');\nexport const borderRightColor = createBorderStyle('borderRightColor');\nexport const borderBottomColor = createBorderStyle('borderBottomColor');\nexport const borderLeftColor = createBorderStyle('borderLeftColor');\nexport const outline = createBorderStyle('outline', borderTransform);\nexport const outlineColor = createBorderStyle('outlineColor');\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const borderRadius = props => {\n if (props.borderRadius !== undefined && props.borderRadius !== null) {\n const transformer = createUnaryUnit(props.theme, 'shape.borderRadius', 4, 'borderRadius');\n const styleFromPropValue = propValue => ({\n borderRadius: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.borderRadius, styleFromPropValue);\n }\n return null;\n};\nborderRadius.propTypes = process.env.NODE_ENV !== 'production' ? {\n borderRadius: responsivePropType\n} : {};\nborderRadius.filterProps = ['borderRadius'];\nconst borders = compose(border, borderTop, borderRight, borderBottom, borderLeft, borderColor, borderTopColor, borderRightColor, borderBottomColor, borderLeftColor, borderRadius, outline, outlineColor);\nexport default borders;","import style from './style';\nimport compose from './compose';\nimport { createUnaryUnit, getValue } from './spacing';\nimport { handleBreakpoints } from './breakpoints';\nimport responsivePropType from './responsivePropType';\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const gap = props => {\n if (props.gap !== undefined && props.gap !== null) {\n const transformer = createUnaryUnit(props.theme, 'spacing', 8, 'gap');\n const styleFromPropValue = propValue => ({\n gap: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.gap, styleFromPropValue);\n }\n return null;\n};\ngap.propTypes = process.env.NODE_ENV !== 'production' ? {\n gap: responsivePropType\n} : {};\ngap.filterProps = ['gap'];\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const columnGap = props => {\n if (props.columnGap !== undefined && props.columnGap !== null) {\n const transformer = createUnaryUnit(props.theme, 'spacing', 8, 'columnGap');\n const styleFromPropValue = propValue => ({\n columnGap: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.columnGap, styleFromPropValue);\n }\n return null;\n};\ncolumnGap.propTypes = process.env.NODE_ENV !== 'production' ? {\n columnGap: responsivePropType\n} : {};\ncolumnGap.filterProps = ['columnGap'];\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const rowGap = props => {\n if (props.rowGap !== undefined && props.rowGap !== null) {\n const transformer = createUnaryUnit(props.theme, 'spacing', 8, 'rowGap');\n const styleFromPropValue = propValue => ({\n rowGap: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.rowGap, styleFromPropValue);\n }\n return null;\n};\nrowGap.propTypes = process.env.NODE_ENV !== 'production' ? {\n rowGap: responsivePropType\n} : {};\nrowGap.filterProps = ['rowGap'];\nexport const gridColumn = style({\n prop: 'gridColumn'\n});\nexport const gridRow = style({\n prop: 'gridRow'\n});\nexport const gridAutoFlow = style({\n prop: 'gridAutoFlow'\n});\nexport const gridAutoColumns = style({\n prop: 'gridAutoColumns'\n});\nexport const gridAutoRows = style({\n prop: 'gridAutoRows'\n});\nexport const gridTemplateColumns = style({\n prop: 'gridTemplateColumns'\n});\nexport const gridTemplateRows = style({\n prop: 'gridTemplateRows'\n});\nexport const gridTemplateAreas = style({\n prop: 'gridTemplateAreas'\n});\nexport const gridArea = style({\n prop: 'gridArea'\n});\nconst grid = compose(gap, columnGap, rowGap, gridColumn, gridRow, gridAutoFlow, gridAutoColumns, gridAutoRows, gridTemplateColumns, gridTemplateRows, gridTemplateAreas, gridArea);\nexport default grid;","import style from './style';\nimport compose from './compose';\nexport function paletteTransform(value, userValue) {\n if (userValue === 'grey') {\n return userValue;\n }\n return value;\n}\nexport const color = style({\n prop: 'color',\n themeKey: 'palette',\n transform: paletteTransform\n});\nexport const bgcolor = style({\n prop: 'bgcolor',\n cssProperty: 'backgroundColor',\n themeKey: 'palette',\n transform: paletteTransform\n});\nexport const backgroundColor = style({\n prop: 'backgroundColor',\n themeKey: 'palette',\n transform: paletteTransform\n});\nconst palette = compose(color, bgcolor, backgroundColor);\nexport default palette;","import style from './style';\nimport compose from './compose';\nimport { handleBreakpoints, values as breakpointsValues } from './breakpoints';\nexport function sizingTransform(value) {\n return value <= 1 && value !== 0 ? `${value * 100}%` : value;\n}\nexport const width = style({\n prop: 'width',\n transform: sizingTransform\n});\nexport const maxWidth = props => {\n if (props.maxWidth !== undefined && props.maxWidth !== null) {\n const styleFromPropValue = propValue => {\n var _props$theme, _props$theme2;\n const breakpoint = ((_props$theme = props.theme) == null || (_props$theme = _props$theme.breakpoints) == null || (_props$theme = _props$theme.values) == null ? void 0 : _props$theme[propValue]) || breakpointsValues[propValue];\n if (!breakpoint) {\n return {\n maxWidth: sizingTransform(propValue)\n };\n }\n if (((_props$theme2 = props.theme) == null || (_props$theme2 = _props$theme2.breakpoints) == null ? void 0 : _props$theme2.unit) !== 'px') {\n return {\n maxWidth: `${breakpoint}${props.theme.breakpoints.unit}`\n };\n }\n return {\n maxWidth: breakpoint\n };\n };\n return handleBreakpoints(props, props.maxWidth, styleFromPropValue);\n }\n return null;\n};\nmaxWidth.filterProps = ['maxWidth'];\nexport const minWidth = style({\n prop: 'minWidth',\n transform: sizingTransform\n});\nexport const height = style({\n prop: 'height',\n transform: sizingTransform\n});\nexport const maxHeight = style({\n prop: 'maxHeight',\n transform: sizingTransform\n});\nexport const minHeight = style({\n prop: 'minHeight',\n transform: sizingTransform\n});\nexport const sizeWidth = style({\n prop: 'size',\n cssProperty: 'width',\n transform: sizingTransform\n});\nexport const sizeHeight = style({\n prop: 'size',\n cssProperty: 'height',\n transform: sizingTransform\n});\nexport const boxSizing = style({\n prop: 'boxSizing'\n});\nconst sizing = compose(width, maxWidth, minWidth, height, maxHeight, minHeight, boxSizing);\nexport default sizing;","import { padding, margin } from '../spacing';\nimport { borderRadius, borderTransform } from '../borders';\nimport { gap, rowGap, columnGap } from '../cssGrid';\nimport { paletteTransform } from '../palette';\nimport { maxWidth, sizingTransform } from '../sizing';\nconst defaultSxConfig = {\n // borders\n border: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderTop: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderRight: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderBottom: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderLeft: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderColor: {\n themeKey: 'palette'\n },\n borderTopColor: {\n themeKey: 'palette'\n },\n borderRightColor: {\n themeKey: 'palette'\n },\n borderBottomColor: {\n themeKey: 'palette'\n },\n borderLeftColor: {\n themeKey: 'palette'\n },\n outline: {\n themeKey: 'borders',\n transform: borderTransform\n },\n outlineColor: {\n themeKey: 'palette'\n },\n borderRadius: {\n themeKey: 'shape.borderRadius',\n style: borderRadius\n },\n // palette\n color: {\n themeKey: 'palette',\n transform: paletteTransform\n },\n bgcolor: {\n themeKey: 'palette',\n cssProperty: 'backgroundColor',\n transform: paletteTransform\n },\n backgroundColor: {\n themeKey: 'palette',\n transform: paletteTransform\n },\n // spacing\n p: {\n style: padding\n },\n pt: {\n style: padding\n },\n pr: {\n style: padding\n },\n pb: {\n style: padding\n },\n pl: {\n style: padding\n },\n px: {\n style: padding\n },\n py: {\n style: padding\n },\n padding: {\n style: padding\n },\n paddingTop: {\n style: padding\n },\n paddingRight: {\n style: padding\n },\n paddingBottom: {\n style: padding\n },\n paddingLeft: {\n style: padding\n },\n paddingX: {\n style: padding\n },\n paddingY: {\n style: padding\n },\n paddingInline: {\n style: padding\n },\n paddingInlineStart: {\n style: padding\n },\n paddingInlineEnd: {\n style: padding\n },\n paddingBlock: {\n style: padding\n },\n paddingBlockStart: {\n style: padding\n },\n paddingBlockEnd: {\n style: padding\n },\n m: {\n style: margin\n },\n mt: {\n style: margin\n },\n mr: {\n style: margin\n },\n mb: {\n style: margin\n },\n ml: {\n style: margin\n },\n mx: {\n style: margin\n },\n my: {\n style: margin\n },\n margin: {\n style: margin\n },\n marginTop: {\n style: margin\n },\n marginRight: {\n style: margin\n },\n marginBottom: {\n style: margin\n },\n marginLeft: {\n style: margin\n },\n marginX: {\n style: margin\n },\n marginY: {\n style: margin\n },\n marginInline: {\n style: margin\n },\n marginInlineStart: {\n style: margin\n },\n marginInlineEnd: {\n style: margin\n },\n marginBlock: {\n style: margin\n },\n marginBlockStart: {\n style: margin\n },\n marginBlockEnd: {\n style: margin\n },\n // display\n displayPrint: {\n cssProperty: false,\n transform: value => ({\n '@media print': {\n display: value\n }\n })\n },\n display: {},\n overflow: {},\n textOverflow: {},\n visibility: {},\n whiteSpace: {},\n // flexbox\n flexBasis: {},\n flexDirection: {},\n flexWrap: {},\n justifyContent: {},\n alignItems: {},\n alignContent: {},\n order: {},\n flex: {},\n flexGrow: {},\n flexShrink: {},\n alignSelf: {},\n justifyItems: {},\n justifySelf: {},\n // grid\n gap: {\n style: gap\n },\n rowGap: {\n style: rowGap\n },\n columnGap: {\n style: columnGap\n },\n gridColumn: {},\n gridRow: {},\n gridAutoFlow: {},\n gridAutoColumns: {},\n gridAutoRows: {},\n gridTemplateColumns: {},\n gridTemplateRows: {},\n gridTemplateAreas: {},\n gridArea: {},\n // positions\n position: {},\n zIndex: {\n themeKey: 'zIndex'\n },\n top: {},\n right: {},\n bottom: {},\n left: {},\n // shadows\n boxShadow: {\n themeKey: 'shadows'\n },\n // sizing\n width: {\n transform: sizingTransform\n },\n maxWidth: {\n style: maxWidth\n },\n minWidth: {\n transform: sizingTransform\n },\n height: {\n transform: sizingTransform\n },\n maxHeight: {\n transform: sizingTransform\n },\n minHeight: {\n transform: sizingTransform\n },\n boxSizing: {},\n // typography\n fontFamily: {\n themeKey: 'typography'\n },\n fontSize: {\n themeKey: 'typography'\n },\n fontStyle: {\n themeKey: 'typography'\n },\n fontWeight: {\n themeKey: 'typography'\n },\n letterSpacing: {},\n textTransform: {},\n lineHeight: {},\n textAlign: {},\n typography: {\n cssProperty: false,\n themeKey: 'typography'\n }\n};\nexport default defaultSxConfig;","import capitalize from '@mui/utils/capitalize';\nimport merge from '../merge';\nimport { getPath, getStyleValue as getValue } from '../style';\nimport { handleBreakpoints, createEmptyBreakpointObject, removeUnusedBreakpoints } from '../breakpoints';\nimport defaultSxConfig from './defaultSxConfig';\nfunction objectsHaveSameKeys(...objects) {\n const allKeys = objects.reduce((keys, object) => keys.concat(Object.keys(object)), []);\n const union = new Set(allKeys);\n return objects.every(object => union.size === Object.keys(object).length);\n}\nfunction callIfFn(maybeFn, arg) {\n return typeof maybeFn === 'function' ? maybeFn(arg) : maybeFn;\n}\n\n// eslint-disable-next-line @typescript-eslint/naming-convention\nexport function unstable_createStyleFunctionSx() {\n function getThemeValue(prop, val, theme, config) {\n const props = {\n [prop]: val,\n theme\n };\n const options = config[prop];\n if (!options) {\n return {\n [prop]: val\n };\n }\n const {\n cssProperty = prop,\n themeKey,\n transform,\n style\n } = options;\n if (val == null) {\n return null;\n }\n\n // TODO v6: remove, see https://github.com/mui/material-ui/pull/38123\n if (themeKey === 'typography' && val === 'inherit') {\n return {\n [prop]: val\n };\n }\n const themeMapping = getPath(theme, themeKey) || {};\n if (style) {\n return style(props);\n }\n const styleFromPropValue = propValueFinal => {\n let value = getValue(themeMapping, transform, propValueFinal);\n if (propValueFinal === value && typeof propValueFinal === 'string') {\n // Haven't found value\n value = getValue(themeMapping, transform, `${prop}${propValueFinal === 'default' ? '' : capitalize(propValueFinal)}`, propValueFinal);\n }\n if (cssProperty === false) {\n return value;\n }\n return {\n [cssProperty]: value\n };\n };\n return handleBreakpoints(props, val, styleFromPropValue);\n }\n function styleFunctionSx(props) {\n var _theme$unstable_sxCon;\n const {\n sx,\n theme = {}\n } = props || {};\n if (!sx) {\n return null; // Emotion & styled-components will neglect null\n }\n const config = (_theme$unstable_sxCon = theme.unstable_sxConfig) != null ? _theme$unstable_sxCon : defaultSxConfig;\n\n /*\n * Receive `sxInput` as object or callback\n * and then recursively check keys & values to create media query object styles.\n * (the result will be used in `styled`)\n */\n function traverse(sxInput) {\n let sxObject = sxInput;\n if (typeof sxInput === 'function') {\n sxObject = sxInput(theme);\n } else if (typeof sxInput !== 'object') {\n // value\n return sxInput;\n }\n if (!sxObject) {\n return null;\n }\n const emptyBreakpoints = createEmptyBreakpointObject(theme.breakpoints);\n const breakpointsKeys = Object.keys(emptyBreakpoints);\n let css = emptyBreakpoints;\n Object.keys(sxObject).forEach(styleKey => {\n const value = callIfFn(sxObject[styleKey], theme);\n if (value !== null && value !== undefined) {\n if (typeof value === 'object') {\n if (config[styleKey]) {\n css = merge(css, getThemeValue(styleKey, value, theme, config));\n } else {\n const breakpointsValues = handleBreakpoints({\n theme\n }, value, x => ({\n [styleKey]: x\n }));\n if (objectsHaveSameKeys(breakpointsValues, value)) {\n css[styleKey] = styleFunctionSx({\n sx: value,\n theme\n });\n } else {\n css = merge(css, breakpointsValues);\n }\n }\n } else {\n css = merge(css, getThemeValue(styleKey, value, theme, config));\n }\n }\n });\n return removeUnusedBreakpoints(breakpointsKeys, css);\n }\n return Array.isArray(sx) ? sx.map(traverse) : traverse(sx);\n }\n return styleFunctionSx;\n}\nconst styleFunctionSx = unstable_createStyleFunctionSx();\nstyleFunctionSx.filterProps = ['sx'];\nexport default styleFunctionSx;","/**\n * A universal utility to style components with multiple color modes. Always use it from the theme object.\n * It works with:\n * - [Basic theme](https://mui.com/material-ui/customization/dark-mode/)\n * - [CSS theme variables](https://mui.com/material-ui/experimental-api/css-theme-variables/overview/)\n * - Zero-runtime engine\n *\n * Tips: Use an array over object spread and place `theme.applyStyles()` last.\n *\n * ✅ [{ background: '#e5e5e5' }, theme.applyStyles('dark', { background: '#1c1c1c' })]\n *\n * 🚫 { background: '#e5e5e5', ...theme.applyStyles('dark', { background: '#1c1c1c' })}\n *\n * @example\n * 1. using with `styled`:\n * ```jsx\n * const Component = styled('div')(({ theme }) => [\n * { background: '#e5e5e5' },\n * theme.applyStyles('dark', {\n * background: '#1c1c1c',\n * color: '#fff',\n * }),\n * ]);\n * ```\n *\n * @example\n * 2. using with `sx` prop:\n * ```jsx\n * [\n * { background: '#e5e5e5' },\n * theme.applyStyles('dark', {\n * background: '#1c1c1c',\n * color: '#fff',\n * }),\n * ]}\n * />\n * ```\n *\n * @example\n * 3. theming a component:\n * ```jsx\n * extendTheme({\n * components: {\n * MuiButton: {\n * styleOverrides: {\n * root: ({ theme }) => [\n * { background: '#e5e5e5' },\n * theme.applyStyles('dark', {\n * background: '#1c1c1c',\n * color: '#fff',\n * }),\n * ],\n * },\n * }\n * }\n * })\n *```\n */\nexport default function applyStyles(key, styles) {\n // @ts-expect-error this is 'any' type\n const theme = this;\n if (theme.vars && typeof theme.getColorSchemeSelector === 'function') {\n // If CssVarsProvider is used as a provider,\n // returns '* :where([data-mui-color-scheme=\"light|dark\"]) &'\n const selector = theme.getColorSchemeSelector(key).replace(/(\\[[^\\]]+\\])/, '*:where($1)');\n return {\n [selector]: styles\n };\n }\n if (theme.palette.mode === key) {\n return styles;\n }\n return {};\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"breakpoints\", \"palette\", \"spacing\", \"shape\"];\nimport deepmerge from '@mui/utils/deepmerge';\nimport createBreakpoints from './createBreakpoints';\nimport shape from './shape';\nimport createSpacing from './createSpacing';\nimport styleFunctionSx from '../styleFunctionSx/styleFunctionSx';\nimport defaultSxConfig from '../styleFunctionSx/defaultSxConfig';\nimport applyStyles from './applyStyles';\nfunction createTheme(options = {}, ...args) {\n const {\n breakpoints: breakpointsInput = {},\n palette: paletteInput = {},\n spacing: spacingInput,\n shape: shapeInput = {}\n } = options,\n other = _objectWithoutPropertiesLoose(options, _excluded);\n const breakpoints = createBreakpoints(breakpointsInput);\n const spacing = createSpacing(spacingInput);\n let muiTheme = deepmerge({\n breakpoints,\n direction: 'ltr',\n components: {},\n // Inject component definitions.\n palette: _extends({\n mode: 'light'\n }, paletteInput),\n spacing,\n shape: _extends({}, shape, shapeInput)\n }, other);\n muiTheme.applyStyles = applyStyles;\n muiTheme = args.reduce((acc, argument) => deepmerge(acc, argument), muiTheme);\n muiTheme.unstable_sxConfig = _extends({}, defaultSxConfig, other == null ? void 0 : other.unstable_sxConfig);\n muiTheme.unstable_sx = function sx(props) {\n return styleFunctionSx({\n sx: props,\n theme: this\n });\n };\n return muiTheme;\n}\nexport default createTheme;","'use client';\n\nimport * as React from 'react';\nimport { ThemeContext } from '@mui/styled-engine';\nfunction isObjectEmpty(obj) {\n return Object.keys(obj).length === 0;\n}\nfunction useTheme(defaultTheme = null) {\n const contextTheme = React.useContext(ThemeContext);\n return !contextTheme || isObjectEmpty(contextTheme) ? defaultTheme : contextTheme;\n}\nexport default useTheme;","'use client';\n\nimport createTheme from './createTheme';\nimport useThemeWithoutDefault from './useThemeWithoutDefault';\nexport const systemDefaultTheme = createTheme();\nfunction useTheme(defaultTheme = systemDefaultTheme) {\n return useThemeWithoutDefault(defaultTheme);\n}\nexport default useTheme;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"ownerState\"],\n _excluded2 = [\"variants\"],\n _excluded3 = [\"name\", \"slot\", \"skipVariantsResolver\", \"skipSx\", \"overridesResolver\"];\n/* eslint-disable no-underscore-dangle */\nimport styledEngineStyled, { internal_processStyles as processStyles } from '@mui/styled-engine';\nimport { isPlainObject } from '@mui/utils/deepmerge';\nimport capitalize from '@mui/utils/capitalize';\nimport getDisplayName from '@mui/utils/getDisplayName';\nimport createTheme from './createTheme';\nimport styleFunctionSx from './styleFunctionSx';\nfunction isEmpty(obj) {\n return Object.keys(obj).length === 0;\n}\n\n// https://github.com/emotion-js/emotion/blob/26ded6109fcd8ca9875cc2ce4564fee678a3f3c5/packages/styled/src/utils.js#L40\nfunction isStringTag(tag) {\n return typeof tag === 'string' &&\n // 96 is one less than the char code\n // for \"a\" so this is checking that\n // it's a lowercase character\n tag.charCodeAt(0) > 96;\n}\n\n// Update /system/styled/#api in case if this changes\nexport function shouldForwardProp(prop) {\n return prop !== 'ownerState' && prop !== 'theme' && prop !== 'sx' && prop !== 'as';\n}\nexport const systemDefaultTheme = createTheme();\nconst lowercaseFirstLetter = string => {\n if (!string) {\n return string;\n }\n return string.charAt(0).toLowerCase() + string.slice(1);\n};\nfunction resolveTheme({\n defaultTheme,\n theme,\n themeId\n}) {\n return isEmpty(theme) ? defaultTheme : theme[themeId] || theme;\n}\nfunction defaultOverridesResolver(slot) {\n if (!slot) {\n return null;\n }\n return (props, styles) => styles[slot];\n}\nfunction processStyleArg(callableStyle, _ref) {\n let {\n ownerState\n } = _ref,\n props = _objectWithoutPropertiesLoose(_ref, _excluded);\n const resolvedStylesArg = typeof callableStyle === 'function' ? callableStyle(_extends({\n ownerState\n }, props)) : callableStyle;\n if (Array.isArray(resolvedStylesArg)) {\n return resolvedStylesArg.flatMap(resolvedStyle => processStyleArg(resolvedStyle, _extends({\n ownerState\n }, props)));\n }\n if (!!resolvedStylesArg && typeof resolvedStylesArg === 'object' && Array.isArray(resolvedStylesArg.variants)) {\n const {\n variants = []\n } = resolvedStylesArg,\n otherStyles = _objectWithoutPropertiesLoose(resolvedStylesArg, _excluded2);\n let result = otherStyles;\n variants.forEach(variant => {\n let isMatch = true;\n if (typeof variant.props === 'function') {\n isMatch = variant.props(_extends({\n ownerState\n }, props, ownerState));\n } else {\n Object.keys(variant.props).forEach(key => {\n if ((ownerState == null ? void 0 : ownerState[key]) !== variant.props[key] && props[key] !== variant.props[key]) {\n isMatch = false;\n }\n });\n }\n if (isMatch) {\n if (!Array.isArray(result)) {\n result = [result];\n }\n result.push(typeof variant.style === 'function' ? variant.style(_extends({\n ownerState\n }, props, ownerState)) : variant.style);\n }\n });\n return result;\n }\n return resolvedStylesArg;\n}\nexport default function createStyled(input = {}) {\n const {\n themeId,\n defaultTheme = systemDefaultTheme,\n rootShouldForwardProp = shouldForwardProp,\n slotShouldForwardProp = shouldForwardProp\n } = input;\n const systemSx = props => {\n return styleFunctionSx(_extends({}, props, {\n theme: resolveTheme(_extends({}, props, {\n defaultTheme,\n themeId\n }))\n }));\n };\n systemSx.__mui_systemSx = true;\n return (tag, inputOptions = {}) => {\n // Filter out the `sx` style function from the previous styled component to prevent unnecessary styles generated by the composite components.\n processStyles(tag, styles => styles.filter(style => !(style != null && style.__mui_systemSx)));\n const {\n name: componentName,\n slot: componentSlot,\n skipVariantsResolver: inputSkipVariantsResolver,\n skipSx: inputSkipSx,\n // TODO v6: remove `lowercaseFirstLetter()` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n overridesResolver = defaultOverridesResolver(lowercaseFirstLetter(componentSlot))\n } = inputOptions,\n options = _objectWithoutPropertiesLoose(inputOptions, _excluded3);\n\n // if skipVariantsResolver option is defined, take the value, otherwise, true for root and false for other slots.\n const skipVariantsResolver = inputSkipVariantsResolver !== undefined ? inputSkipVariantsResolver :\n // TODO v6: remove `Root` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n componentSlot && componentSlot !== 'Root' && componentSlot !== 'root' || false;\n const skipSx = inputSkipSx || false;\n let label;\n if (process.env.NODE_ENV !== 'production') {\n if (componentName) {\n // TODO v6: remove `lowercaseFirstLetter()` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n label = `${componentName}-${lowercaseFirstLetter(componentSlot || 'Root')}`;\n }\n }\n let shouldForwardPropOption = shouldForwardProp;\n\n // TODO v6: remove `Root` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n if (componentSlot === 'Root' || componentSlot === 'root') {\n shouldForwardPropOption = rootShouldForwardProp;\n } else if (componentSlot) {\n // any other slot specified\n shouldForwardPropOption = slotShouldForwardProp;\n } else if (isStringTag(tag)) {\n // for string (html) tag, preserve the behavior in emotion & styled-components.\n shouldForwardPropOption = undefined;\n }\n const defaultStyledResolver = styledEngineStyled(tag, _extends({\n shouldForwardProp: shouldForwardPropOption,\n label\n }, options));\n const transformStyleArg = stylesArg => {\n // On the server Emotion doesn't use React.forwardRef for creating components, so the created\n // component stays as a function. This condition makes sure that we do not interpolate functions\n // which are basically components used as a selectors.\n if (typeof stylesArg === 'function' && stylesArg.__emotion_real !== stylesArg || isPlainObject(stylesArg)) {\n return props => processStyleArg(stylesArg, _extends({}, props, {\n theme: resolveTheme({\n theme: props.theme,\n defaultTheme,\n themeId\n })\n }));\n }\n return stylesArg;\n };\n const muiStyledResolver = (styleArg, ...expressions) => {\n let transformedStyleArg = transformStyleArg(styleArg);\n const expressionsWithDefaultTheme = expressions ? expressions.map(transformStyleArg) : [];\n if (componentName && overridesResolver) {\n expressionsWithDefaultTheme.push(props => {\n const theme = resolveTheme(_extends({}, props, {\n defaultTheme,\n themeId\n }));\n if (!theme.components || !theme.components[componentName] || !theme.components[componentName].styleOverrides) {\n return null;\n }\n const styleOverrides = theme.components[componentName].styleOverrides;\n const resolvedStyleOverrides = {};\n // TODO: v7 remove iteration and use `resolveStyleArg(styleOverrides[slot])` directly\n Object.entries(styleOverrides).forEach(([slotKey, slotStyle]) => {\n resolvedStyleOverrides[slotKey] = processStyleArg(slotStyle, _extends({}, props, {\n theme\n }));\n });\n return overridesResolver(props, resolvedStyleOverrides);\n });\n }\n if (componentName && !skipVariantsResolver) {\n expressionsWithDefaultTheme.push(props => {\n var _theme$components;\n const theme = resolveTheme(_extends({}, props, {\n defaultTheme,\n themeId\n }));\n const themeVariants = theme == null || (_theme$components = theme.components) == null || (_theme$components = _theme$components[componentName]) == null ? void 0 : _theme$components.variants;\n return processStyleArg({\n variants: themeVariants\n }, _extends({}, props, {\n theme\n }));\n });\n }\n if (!skipSx) {\n expressionsWithDefaultTheme.push(systemSx);\n }\n const numOfCustomFnsApplied = expressionsWithDefaultTheme.length - expressions.length;\n if (Array.isArray(styleArg) && numOfCustomFnsApplied > 0) {\n const placeholders = new Array(numOfCustomFnsApplied).fill('');\n // If the type is array, than we need to add placeholders in the template for the overrides, variants and the sx styles.\n transformedStyleArg = [...styleArg, ...placeholders];\n transformedStyleArg.raw = [...styleArg.raw, ...placeholders];\n }\n const Component = defaultStyledResolver(transformedStyleArg, ...expressionsWithDefaultTheme);\n if (process.env.NODE_ENV !== 'production') {\n let displayName;\n if (componentName) {\n displayName = `${componentName}${capitalize(componentSlot || '')}`;\n }\n if (displayName === undefined) {\n displayName = `Styled(${getDisplayName(tag)})`;\n }\n Component.displayName = displayName;\n }\n if (tag.muiName) {\n Component.muiName = tag.muiName;\n }\n return Component;\n };\n if (defaultStyledResolver.withConfig) {\n muiStyledResolver.withConfig = defaultStyledResolver.withConfig;\n }\n return muiStyledResolver;\n };\n}","import resolveProps from '@mui/utils/resolveProps';\nexport default function getThemeProps(params) {\n const {\n theme,\n name,\n props\n } = params;\n if (!theme || !theme.components || !theme.components[name] || !theme.components[name].defaultProps) {\n return props;\n }\n return resolveProps(theme.components[name].defaultProps, props);\n}","'use client';\n\nimport getThemeProps from './getThemeProps';\nimport useTheme from '../useTheme';\nexport default function useThemeProps({\n props,\n name,\n defaultTheme,\n themeId\n}) {\n let theme = useTheme(defaultTheme);\n if (themeId) {\n theme = theme[themeId] || theme;\n }\n const mergedProps = getThemeProps({\n theme,\n name,\n props\n });\n return mergedProps;\n}","import _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\n/* eslint-disable @typescript-eslint/naming-convention */\nimport clamp from '@mui/utils/clamp';\n/**\n * Returns a number whose value is limited to the given range.\n * @param {number} value The value to be clamped\n * @param {number} min The lower boundary of the output range\n * @param {number} max The upper boundary of the output range\n * @returns {number} A number in the range [min, max]\n */\nfunction clampWrapper(value, min = 0, max = 1) {\n if (process.env.NODE_ENV !== 'production') {\n if (value < min || value > max) {\n console.error(`MUI: The value provided ${value} is out of range [${min}, ${max}].`);\n }\n }\n return clamp(value, min, max);\n}\n\n/**\n * Converts a color from CSS hex format to CSS rgb format.\n * @param {string} color - Hex color, i.e. #nnn or #nnnnnn\n * @returns {string} A CSS rgb color string\n */\nexport function hexToRgb(color) {\n color = color.slice(1);\n const re = new RegExp(`.{1,${color.length >= 6 ? 2 : 1}}`, 'g');\n let colors = color.match(re);\n if (colors && colors[0].length === 1) {\n colors = colors.map(n => n + n);\n }\n return colors ? `rgb${colors.length === 4 ? 'a' : ''}(${colors.map((n, index) => {\n return index < 3 ? parseInt(n, 16) : Math.round(parseInt(n, 16) / 255 * 1000) / 1000;\n }).join(', ')})` : '';\n}\nfunction intToHex(int) {\n const hex = int.toString(16);\n return hex.length === 1 ? `0${hex}` : hex;\n}\n\n/**\n * Returns an object with the type and values of a color.\n *\n * Note: Does not support rgb % values.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @returns {object} - A MUI color object: {type: string, values: number[]}\n */\nexport function decomposeColor(color) {\n // Idempotent\n if (color.type) {\n return color;\n }\n if (color.charAt(0) === '#') {\n return decomposeColor(hexToRgb(color));\n }\n const marker = color.indexOf('(');\n const type = color.substring(0, marker);\n if (['rgb', 'rgba', 'hsl', 'hsla', 'color'].indexOf(type) === -1) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: Unsupported \\`${color}\\` color.\nThe following formats are supported: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color().` : _formatMuiErrorMessage(9, color));\n }\n let values = color.substring(marker + 1, color.length - 1);\n let colorSpace;\n if (type === 'color') {\n values = values.split(' ');\n colorSpace = values.shift();\n if (values.length === 4 && values[3].charAt(0) === '/') {\n values[3] = values[3].slice(1);\n }\n if (['srgb', 'display-p3', 'a98-rgb', 'prophoto-rgb', 'rec-2020'].indexOf(colorSpace) === -1) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: unsupported \\`${colorSpace}\\` color space.\nThe following color spaces are supported: srgb, display-p3, a98-rgb, prophoto-rgb, rec-2020.` : _formatMuiErrorMessage(10, colorSpace));\n }\n } else {\n values = values.split(',');\n }\n values = values.map(value => parseFloat(value));\n return {\n type,\n values,\n colorSpace\n };\n}\n\n/**\n * Returns a channel created from the input color.\n *\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @returns {string} - The channel for the color, that can be used in rgba or hsla colors\n */\nexport const colorChannel = color => {\n const decomposedColor = decomposeColor(color);\n return decomposedColor.values.slice(0, 3).map((val, idx) => decomposedColor.type.indexOf('hsl') !== -1 && idx !== 0 ? `${val}%` : val).join(' ');\n};\nexport const private_safeColorChannel = (color, warning) => {\n try {\n return colorChannel(color);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n};\n\n/**\n * Converts a color object with type and values to a string.\n * @param {object} color - Decomposed color\n * @param {string} color.type - One of: 'rgb', 'rgba', 'hsl', 'hsla', 'color'\n * @param {array} color.values - [n,n,n] or [n,n,n,n]\n * @returns {string} A CSS color string\n */\nexport function recomposeColor(color) {\n const {\n type,\n colorSpace\n } = color;\n let {\n values\n } = color;\n if (type.indexOf('rgb') !== -1) {\n // Only convert the first 3 values to int (i.e. not alpha)\n values = values.map((n, i) => i < 3 ? parseInt(n, 10) : n);\n } else if (type.indexOf('hsl') !== -1) {\n values[1] = `${values[1]}%`;\n values[2] = `${values[2]}%`;\n }\n if (type.indexOf('color') !== -1) {\n values = `${colorSpace} ${values.join(' ')}`;\n } else {\n values = `${values.join(', ')}`;\n }\n return `${type}(${values})`;\n}\n\n/**\n * Converts a color from CSS rgb format to CSS hex format.\n * @param {string} color - RGB color, i.e. rgb(n, n, n)\n * @returns {string} A CSS rgb color string, i.e. #nnnnnn\n */\nexport function rgbToHex(color) {\n // Idempotent\n if (color.indexOf('#') === 0) {\n return color;\n }\n const {\n values\n } = decomposeColor(color);\n return `#${values.map((n, i) => intToHex(i === 3 ? Math.round(255 * n) : n)).join('')}`;\n}\n\n/**\n * Converts a color from hsl format to rgb format.\n * @param {string} color - HSL color values\n * @returns {string} rgb color values\n */\nexport function hslToRgb(color) {\n color = decomposeColor(color);\n const {\n values\n } = color;\n const h = values[0];\n const s = values[1] / 100;\n const l = values[2] / 100;\n const a = s * Math.min(l, 1 - l);\n const f = (n, k = (n + h / 30) % 12) => l - a * Math.max(Math.min(k - 3, 9 - k, 1), -1);\n let type = 'rgb';\n const rgb = [Math.round(f(0) * 255), Math.round(f(8) * 255), Math.round(f(4) * 255)];\n if (color.type === 'hsla') {\n type += 'a';\n rgb.push(values[3]);\n }\n return recomposeColor({\n type,\n values: rgb\n });\n}\n/**\n * The relative brightness of any point in a color space,\n * normalized to 0 for darkest black and 1 for lightest white.\n *\n * Formula: https://www.w3.org/TR/WCAG20-TECHS/G17.html#G17-tests\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @returns {number} The relative brightness of the color in the range 0 - 1\n */\nexport function getLuminance(color) {\n color = decomposeColor(color);\n let rgb = color.type === 'hsl' || color.type === 'hsla' ? decomposeColor(hslToRgb(color)).values : color.values;\n rgb = rgb.map(val => {\n if (color.type !== 'color') {\n val /= 255; // normalized\n }\n return val <= 0.03928 ? val / 12.92 : ((val + 0.055) / 1.055) ** 2.4;\n });\n\n // Truncate at 3 digits\n return Number((0.2126 * rgb[0] + 0.7152 * rgb[1] + 0.0722 * rgb[2]).toFixed(3));\n}\n\n/**\n * Calculates the contrast ratio between two colors.\n *\n * Formula: https://www.w3.org/TR/WCAG20-TECHS/G17.html#G17-tests\n * @param {string} foreground - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla()\n * @param {string} background - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla()\n * @returns {number} A contrast ratio value in the range 0 - 21.\n */\nexport function getContrastRatio(foreground, background) {\n const lumA = getLuminance(foreground);\n const lumB = getLuminance(background);\n return (Math.max(lumA, lumB) + 0.05) / (Math.min(lumA, lumB) + 0.05);\n}\n\n/**\n * Sets the absolute transparency of a color.\n * Any existing alpha values are overwritten.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} value - value to set the alpha channel to in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function alpha(color, value) {\n color = decomposeColor(color);\n value = clampWrapper(value);\n if (color.type === 'rgb' || color.type === 'hsl') {\n color.type += 'a';\n }\n if (color.type === 'color') {\n color.values[3] = `/${value}`;\n } else {\n color.values[3] = value;\n }\n return recomposeColor(color);\n}\nexport function private_safeAlpha(color, value, warning) {\n try {\n return alpha(color, value);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Darkens a color.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} coefficient - multiplier in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function darken(color, coefficient) {\n color = decomposeColor(color);\n coefficient = clampWrapper(coefficient);\n if (color.type.indexOf('hsl') !== -1) {\n color.values[2] *= 1 - coefficient;\n } else if (color.type.indexOf('rgb') !== -1 || color.type.indexOf('color') !== -1) {\n for (let i = 0; i < 3; i += 1) {\n color.values[i] *= 1 - coefficient;\n }\n }\n return recomposeColor(color);\n}\nexport function private_safeDarken(color, coefficient, warning) {\n try {\n return darken(color, coefficient);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Lightens a color.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} coefficient - multiplier in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function lighten(color, coefficient) {\n color = decomposeColor(color);\n coefficient = clampWrapper(coefficient);\n if (color.type.indexOf('hsl') !== -1) {\n color.values[2] += (100 - color.values[2]) * coefficient;\n } else if (color.type.indexOf('rgb') !== -1) {\n for (let i = 0; i < 3; i += 1) {\n color.values[i] += (255 - color.values[i]) * coefficient;\n }\n } else if (color.type.indexOf('color') !== -1) {\n for (let i = 0; i < 3; i += 1) {\n color.values[i] += (1 - color.values[i]) * coefficient;\n }\n }\n return recomposeColor(color);\n}\nexport function private_safeLighten(color, coefficient, warning) {\n try {\n return lighten(color, coefficient);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Darken or lighten a color, depending on its luminance.\n * Light colors are darkened, dark colors are lightened.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} coefficient=0.15 - multiplier in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function emphasize(color, coefficient = 0.15) {\n return getLuminance(color) > 0.5 ? darken(color, coefficient) : lighten(color, coefficient);\n}\nexport function private_safeEmphasize(color, coefficient, warning) {\n try {\n return emphasize(color, coefficient);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Blend a transparent overlay color with a background color, resulting in a single\n * RGB color.\n * @param {string} background - CSS color\n * @param {string} overlay - CSS color\n * @param {number} opacity - Opacity multiplier in the range 0 - 1\n * @param {number} [gamma=1.0] - Gamma correction factor. For gamma-correct blending, 2.2 is usual.\n */\nexport function blend(background, overlay, opacity, gamma = 1.0) {\n const blendChannel = (b, o) => Math.round((b ** (1 / gamma) * (1 - opacity) + o ** (1 / gamma) * opacity) ** gamma);\n const backgroundColor = decomposeColor(background);\n const overlayColor = decomposeColor(overlay);\n const rgb = [blendChannel(backgroundColor.values[0], overlayColor.values[0]), blendChannel(backgroundColor.values[1], overlayColor.values[1]), blendChannel(backgroundColor.values[2], overlayColor.values[2])];\n return recomposeColor({\n type: 'rgb',\n values: rgb\n });\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nexport default function createMixins(breakpoints, mixins) {\n return _extends({\n toolbar: {\n minHeight: 56,\n [breakpoints.up('xs')]: {\n '@media (orientation: landscape)': {\n minHeight: 48\n }\n },\n [breakpoints.up('sm')]: {\n minHeight: 64\n }\n }\n }, mixins);\n}","const common = {\n black: '#000',\n white: '#fff'\n};\nexport default common;","const grey = {\n 50: '#fafafa',\n 100: '#f5f5f5',\n 200: '#eeeeee',\n 300: '#e0e0e0',\n 400: '#bdbdbd',\n 500: '#9e9e9e',\n 600: '#757575',\n 700: '#616161',\n 800: '#424242',\n 900: '#212121',\n A100: '#f5f5f5',\n A200: '#eeeeee',\n A400: '#bdbdbd',\n A700: '#616161'\n};\nexport default grey;","const purple = {\n 50: '#f3e5f5',\n 100: '#e1bee7',\n 200: '#ce93d8',\n 300: '#ba68c8',\n 400: '#ab47bc',\n 500: '#9c27b0',\n 600: '#8e24aa',\n 700: '#7b1fa2',\n 800: '#6a1b9a',\n 900: '#4a148c',\n A100: '#ea80fc',\n A200: '#e040fb',\n A400: '#d500f9',\n A700: '#aa00ff'\n};\nexport default purple;","const red = {\n 50: '#ffebee',\n 100: '#ffcdd2',\n 200: '#ef9a9a',\n 300: '#e57373',\n 400: '#ef5350',\n 500: '#f44336',\n 600: '#e53935',\n 700: '#d32f2f',\n 800: '#c62828',\n 900: '#b71c1c',\n A100: '#ff8a80',\n A200: '#ff5252',\n A400: '#ff1744',\n A700: '#d50000'\n};\nexport default red;","const orange = {\n 50: '#fff3e0',\n 100: '#ffe0b2',\n 200: '#ffcc80',\n 300: '#ffb74d',\n 400: '#ffa726',\n 500: '#ff9800',\n 600: '#fb8c00',\n 700: '#f57c00',\n 800: '#ef6c00',\n 900: '#e65100',\n A100: '#ffd180',\n A200: '#ffab40',\n A400: '#ff9100',\n A700: '#ff6d00'\n};\nexport default orange;","const blue = {\n 50: '#e3f2fd',\n 100: '#bbdefb',\n 200: '#90caf9',\n 300: '#64b5f6',\n 400: '#42a5f5',\n 500: '#2196f3',\n 600: '#1e88e5',\n 700: '#1976d2',\n 800: '#1565c0',\n 900: '#0d47a1',\n A100: '#82b1ff',\n A200: '#448aff',\n A400: '#2979ff',\n A700: '#2962ff'\n};\nexport default blue;","const lightBlue = {\n 50: '#e1f5fe',\n 100: '#b3e5fc',\n 200: '#81d4fa',\n 300: '#4fc3f7',\n 400: '#29b6f6',\n 500: '#03a9f4',\n 600: '#039be5',\n 700: '#0288d1',\n 800: '#0277bd',\n 900: '#01579b',\n A100: '#80d8ff',\n A200: '#40c4ff',\n A400: '#00b0ff',\n A700: '#0091ea'\n};\nexport default lightBlue;","const green = {\n 50: '#e8f5e9',\n 100: '#c8e6c9',\n 200: '#a5d6a7',\n 300: '#81c784',\n 400: '#66bb6a',\n 500: '#4caf50',\n 600: '#43a047',\n 700: '#388e3c',\n 800: '#2e7d32',\n 900: '#1b5e20',\n A100: '#b9f6ca',\n A200: '#69f0ae',\n A400: '#00e676',\n A700: '#00c853'\n};\nexport default green;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\nconst _excluded = [\"mode\", \"contrastThreshold\", \"tonalOffset\"];\nimport { deepmerge } from '@mui/utils';\nimport { darken, getContrastRatio, lighten } from '@mui/system';\nimport common from '../colors/common';\nimport grey from '../colors/grey';\nimport purple from '../colors/purple';\nimport red from '../colors/red';\nimport orange from '../colors/orange';\nimport blue from '../colors/blue';\nimport lightBlue from '../colors/lightBlue';\nimport green from '../colors/green';\nexport const light = {\n // The colors used to style the text.\n text: {\n // The most important text.\n primary: 'rgba(0, 0, 0, 0.87)',\n // Secondary text.\n secondary: 'rgba(0, 0, 0, 0.6)',\n // Disabled text have even lower visual prominence.\n disabled: 'rgba(0, 0, 0, 0.38)'\n },\n // The color used to divide different elements.\n divider: 'rgba(0, 0, 0, 0.12)',\n // The background colors used to style the surfaces.\n // Consistency between these values is important.\n background: {\n paper: common.white,\n default: common.white\n },\n // The colors used to style the action elements.\n action: {\n // The color of an active action like an icon button.\n active: 'rgba(0, 0, 0, 0.54)',\n // The color of an hovered action.\n hover: 'rgba(0, 0, 0, 0.04)',\n hoverOpacity: 0.04,\n // The color of a selected action.\n selected: 'rgba(0, 0, 0, 0.08)',\n selectedOpacity: 0.08,\n // The color of a disabled action.\n disabled: 'rgba(0, 0, 0, 0.26)',\n // The background color of a disabled action.\n disabledBackground: 'rgba(0, 0, 0, 0.12)',\n disabledOpacity: 0.38,\n focus: 'rgba(0, 0, 0, 0.12)',\n focusOpacity: 0.12,\n activatedOpacity: 0.12\n }\n};\nexport const dark = {\n text: {\n primary: common.white,\n secondary: 'rgba(255, 255, 255, 0.7)',\n disabled: 'rgba(255, 255, 255, 0.5)',\n icon: 'rgba(255, 255, 255, 0.5)'\n },\n divider: 'rgba(255, 255, 255, 0.12)',\n background: {\n paper: '#121212',\n default: '#121212'\n },\n action: {\n active: common.white,\n hover: 'rgba(255, 255, 255, 0.08)',\n hoverOpacity: 0.08,\n selected: 'rgba(255, 255, 255, 0.16)',\n selectedOpacity: 0.16,\n disabled: 'rgba(255, 255, 255, 0.3)',\n disabledBackground: 'rgba(255, 255, 255, 0.12)',\n disabledOpacity: 0.38,\n focus: 'rgba(255, 255, 255, 0.12)',\n focusOpacity: 0.12,\n activatedOpacity: 0.24\n }\n};\nfunction addLightOrDark(intent, direction, shade, tonalOffset) {\n const tonalOffsetLight = tonalOffset.light || tonalOffset;\n const tonalOffsetDark = tonalOffset.dark || tonalOffset * 1.5;\n if (!intent[direction]) {\n if (intent.hasOwnProperty(shade)) {\n intent[direction] = intent[shade];\n } else if (direction === 'light') {\n intent.light = lighten(intent.main, tonalOffsetLight);\n } else if (direction === 'dark') {\n intent.dark = darken(intent.main, tonalOffsetDark);\n }\n }\n}\nfunction getDefaultPrimary(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: blue[200],\n light: blue[50],\n dark: blue[400]\n };\n }\n return {\n main: blue[700],\n light: blue[400],\n dark: blue[800]\n };\n}\nfunction getDefaultSecondary(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: purple[200],\n light: purple[50],\n dark: purple[400]\n };\n }\n return {\n main: purple[500],\n light: purple[300],\n dark: purple[700]\n };\n}\nfunction getDefaultError(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: red[500],\n light: red[300],\n dark: red[700]\n };\n }\n return {\n main: red[700],\n light: red[400],\n dark: red[800]\n };\n}\nfunction getDefaultInfo(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: lightBlue[400],\n light: lightBlue[300],\n dark: lightBlue[700]\n };\n }\n return {\n main: lightBlue[700],\n light: lightBlue[500],\n dark: lightBlue[900]\n };\n}\nfunction getDefaultSuccess(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: green[400],\n light: green[300],\n dark: green[700]\n };\n }\n return {\n main: green[800],\n light: green[500],\n dark: green[900]\n };\n}\nfunction getDefaultWarning(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: orange[400],\n light: orange[300],\n dark: orange[700]\n };\n }\n return {\n main: '#ed6c02',\n // closest to orange[800] that pass 3:1.\n light: orange[500],\n dark: orange[900]\n };\n}\nexport default function createPalette(palette) {\n const {\n mode = 'light',\n contrastThreshold = 3,\n tonalOffset = 0.2\n } = palette,\n other = _objectWithoutPropertiesLoose(palette, _excluded);\n const primary = palette.primary || getDefaultPrimary(mode);\n const secondary = palette.secondary || getDefaultSecondary(mode);\n const error = palette.error || getDefaultError(mode);\n const info = palette.info || getDefaultInfo(mode);\n const success = palette.success || getDefaultSuccess(mode);\n const warning = palette.warning || getDefaultWarning(mode);\n\n // Use the same logic as\n // Bootstrap: https://github.com/twbs/bootstrap/blob/1d6e3710dd447de1a200f29e8fa521f8a0908f70/scss/_functions.scss#L59\n // and material-components-web https://github.com/material-components/material-components-web/blob/ac46b8863c4dab9fc22c4c662dc6bd1b65dd652f/packages/mdc-theme/_functions.scss#L54\n function getContrastText(background) {\n const contrastText = getContrastRatio(background, dark.text.primary) >= contrastThreshold ? dark.text.primary : light.text.primary;\n if (process.env.NODE_ENV !== 'production') {\n const contrast = getContrastRatio(background, contrastText);\n if (contrast < 3) {\n console.error([`MUI: The contrast ratio of ${contrast}:1 for ${contrastText} on ${background}`, 'falls below the WCAG recommended absolute minimum contrast ratio of 3:1.', 'https://www.w3.org/TR/2008/REC-WCAG20-20081211/#visual-audio-contrast-contrast'].join('\\n'));\n }\n }\n return contrastText;\n }\n const augmentColor = ({\n color,\n name,\n mainShade = 500,\n lightShade = 300,\n darkShade = 700\n }) => {\n color = _extends({}, color);\n if (!color.main && color[mainShade]) {\n color.main = color[mainShade];\n }\n if (!color.hasOwnProperty('main')) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: The color${name ? ` (${name})` : ''} provided to augmentColor(color) is invalid.\nThe color object needs to have a \\`main\\` property or a \\`${mainShade}\\` property.` : _formatMuiErrorMessage(11, name ? ` (${name})` : '', mainShade));\n }\n if (typeof color.main !== 'string') {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: The color${name ? ` (${name})` : ''} provided to augmentColor(color) is invalid.\n\\`color.main\\` should be a string, but \\`${JSON.stringify(color.main)}\\` was provided instead.\n\nDid you intend to use one of the following approaches?\n\nimport { green } from \"@mui/material/colors\";\n\nconst theme1 = createTheme({ palette: {\n primary: green,\n} });\n\nconst theme2 = createTheme({ palette: {\n primary: { main: green[500] },\n} });` : _formatMuiErrorMessage(12, name ? ` (${name})` : '', JSON.stringify(color.main)));\n }\n addLightOrDark(color, 'light', lightShade, tonalOffset);\n addLightOrDark(color, 'dark', darkShade, tonalOffset);\n if (!color.contrastText) {\n color.contrastText = getContrastText(color.main);\n }\n return color;\n };\n const modes = {\n dark,\n light\n };\n if (process.env.NODE_ENV !== 'production') {\n if (!modes[mode]) {\n console.error(`MUI: The palette mode \\`${mode}\\` is not supported.`);\n }\n }\n const paletteOutput = deepmerge(_extends({\n // A collection of common colors.\n common: _extends({}, common),\n // prevent mutable object.\n // The palette mode, can be light or dark.\n mode,\n // The colors used to represent primary interface elements for a user.\n primary: augmentColor({\n color: primary,\n name: 'primary'\n }),\n // The colors used to represent secondary interface elements for a user.\n secondary: augmentColor({\n color: secondary,\n name: 'secondary',\n mainShade: 'A400',\n lightShade: 'A200',\n darkShade: 'A700'\n }),\n // The colors used to represent interface elements that the user should be made aware of.\n error: augmentColor({\n color: error,\n name: 'error'\n }),\n // The colors used to represent potentially dangerous actions or important messages.\n warning: augmentColor({\n color: warning,\n name: 'warning'\n }),\n // The colors used to present information to the user that is neutral and not necessarily important.\n info: augmentColor({\n color: info,\n name: 'info'\n }),\n // The colors used to indicate the successful completion of an action that user triggered.\n success: augmentColor({\n color: success,\n name: 'success'\n }),\n // The grey colors.\n grey,\n // Used by `getContrastText()` to maximize the contrast between\n // the background and the text.\n contrastThreshold,\n // Takes a background color and returns the text color that maximizes the contrast.\n getContrastText,\n // Generate a rich color object.\n augmentColor,\n // Used by the functions below to shift a color's luminance by approximately\n // two indexes within its tonal palette.\n // E.g., shift from Red 500 to Red 300 or Red 700.\n tonalOffset\n }, modes[mode]), other);\n return paletteOutput;\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"fontFamily\", \"fontSize\", \"fontWeightLight\", \"fontWeightRegular\", \"fontWeightMedium\", \"fontWeightBold\", \"htmlFontSize\", \"allVariants\", \"pxToRem\"];\nimport { deepmerge } from '@mui/utils';\nfunction round(value) {\n return Math.round(value * 1e5) / 1e5;\n}\nconst caseAllCaps = {\n textTransform: 'uppercase'\n};\nconst defaultFontFamily = '\"Roboto\", \"Helvetica\", \"Arial\", sans-serif';\n\n/**\n * @see @link{https://m2.material.io/design/typography/the-type-system.html}\n * @see @link{https://m2.material.io/design/typography/understanding-typography.html}\n */\nexport default function createTypography(palette, typography) {\n const _ref = typeof typography === 'function' ? typography(palette) : typography,\n {\n fontFamily = defaultFontFamily,\n // The default font size of the Material Specification.\n fontSize = 14,\n // px\n fontWeightLight = 300,\n fontWeightRegular = 400,\n fontWeightMedium = 500,\n fontWeightBold = 700,\n // Tell MUI what's the font-size on the html element.\n // 16px is the default font-size used by browsers.\n htmlFontSize = 16,\n // Apply the CSS properties to all the variants.\n allVariants,\n pxToRem: pxToRem2\n } = _ref,\n other = _objectWithoutPropertiesLoose(_ref, _excluded);\n if (process.env.NODE_ENV !== 'production') {\n if (typeof fontSize !== 'number') {\n console.error('MUI: `fontSize` is required to be a number.');\n }\n if (typeof htmlFontSize !== 'number') {\n console.error('MUI: `htmlFontSize` is required to be a number.');\n }\n }\n const coef = fontSize / 14;\n const pxToRem = pxToRem2 || (size => `${size / htmlFontSize * coef}rem`);\n const buildVariant = (fontWeight, size, lineHeight, letterSpacing, casing) => _extends({\n fontFamily,\n fontWeight,\n fontSize: pxToRem(size),\n // Unitless following https://meyerweb.com/eric/thoughts/2006/02/08/unitless-line-heights/\n lineHeight\n }, fontFamily === defaultFontFamily ? {\n letterSpacing: `${round(letterSpacing / size)}em`\n } : {}, casing, allVariants);\n const variants = {\n h1: buildVariant(fontWeightLight, 96, 1.167, -1.5),\n h2: buildVariant(fontWeightLight, 60, 1.2, -0.5),\n h3: buildVariant(fontWeightRegular, 48, 1.167, 0),\n h4: buildVariant(fontWeightRegular, 34, 1.235, 0.25),\n h5: buildVariant(fontWeightRegular, 24, 1.334, 0),\n h6: buildVariant(fontWeightMedium, 20, 1.6, 0.15),\n subtitle1: buildVariant(fontWeightRegular, 16, 1.75, 0.15),\n subtitle2: buildVariant(fontWeightMedium, 14, 1.57, 0.1),\n body1: buildVariant(fontWeightRegular, 16, 1.5, 0.15),\n body2: buildVariant(fontWeightRegular, 14, 1.43, 0.15),\n button: buildVariant(fontWeightMedium, 14, 1.75, 0.4, caseAllCaps),\n caption: buildVariant(fontWeightRegular, 12, 1.66, 0.4),\n overline: buildVariant(fontWeightRegular, 12, 2.66, 1, caseAllCaps),\n // TODO v6: Remove handling of 'inherit' variant from the theme as it is already handled in Material UI's Typography component. Also, remember to remove the associated types.\n inherit: {\n fontFamily: 'inherit',\n fontWeight: 'inherit',\n fontSize: 'inherit',\n lineHeight: 'inherit',\n letterSpacing: 'inherit'\n }\n };\n return deepmerge(_extends({\n htmlFontSize,\n pxToRem,\n fontFamily,\n fontSize,\n fontWeightLight,\n fontWeightRegular,\n fontWeightMedium,\n fontWeightBold\n }, variants), other, {\n clone: false // No need to clone deep\n });\n}","const shadowKeyUmbraOpacity = 0.2;\nconst shadowKeyPenumbraOpacity = 0.14;\nconst shadowAmbientShadowOpacity = 0.12;\nfunction createShadow(...px) {\n return [`${px[0]}px ${px[1]}px ${px[2]}px ${px[3]}px rgba(0,0,0,${shadowKeyUmbraOpacity})`, `${px[4]}px ${px[5]}px ${px[6]}px ${px[7]}px rgba(0,0,0,${shadowKeyPenumbraOpacity})`, `${px[8]}px ${px[9]}px ${px[10]}px ${px[11]}px rgba(0,0,0,${shadowAmbientShadowOpacity})`].join(',');\n}\n\n// Values from https://github.com/material-components/material-components-web/blob/be8747f94574669cb5e7add1a7c54fa41a89cec7/packages/mdc-elevation/_variables.scss\nconst shadows = ['none', createShadow(0, 2, 1, -1, 0, 1, 1, 0, 0, 1, 3, 0), createShadow(0, 3, 1, -2, 0, 2, 2, 0, 0, 1, 5, 0), createShadow(0, 3, 3, -2, 0, 3, 4, 0, 0, 1, 8, 0), createShadow(0, 2, 4, -1, 0, 4, 5, 0, 0, 1, 10, 0), createShadow(0, 3, 5, -1, 0, 5, 8, 0, 0, 1, 14, 0), createShadow(0, 3, 5, -1, 0, 6, 10, 0, 0, 1, 18, 0), createShadow(0, 4, 5, -2, 0, 7, 10, 1, 0, 2, 16, 1), createShadow(0, 5, 5, -3, 0, 8, 10, 1, 0, 3, 14, 2), createShadow(0, 5, 6, -3, 0, 9, 12, 1, 0, 3, 16, 2), createShadow(0, 6, 6, -3, 0, 10, 14, 1, 0, 4, 18, 3), createShadow(0, 6, 7, -4, 0, 11, 15, 1, 0, 4, 20, 3), createShadow(0, 7, 8, -4, 0, 12, 17, 2, 0, 5, 22, 4), createShadow(0, 7, 8, -4, 0, 13, 19, 2, 0, 5, 24, 4), createShadow(0, 7, 9, -4, 0, 14, 21, 2, 0, 5, 26, 4), createShadow(0, 8, 9, -5, 0, 15, 22, 2, 0, 6, 28, 5), createShadow(0, 8, 10, -5, 0, 16, 24, 2, 0, 6, 30, 5), createShadow(0, 8, 11, -5, 0, 17, 26, 2, 0, 6, 32, 5), createShadow(0, 9, 11, -5, 0, 18, 28, 2, 0, 7, 34, 6), createShadow(0, 9, 12, -6, 0, 19, 29, 2, 0, 7, 36, 6), createShadow(0, 10, 13, -6, 0, 20, 31, 3, 0, 8, 38, 7), createShadow(0, 10, 13, -6, 0, 21, 33, 3, 0, 8, 40, 7), createShadow(0, 10, 14, -6, 0, 22, 35, 3, 0, 8, 42, 7), createShadow(0, 11, 14, -7, 0, 23, 36, 3, 0, 9, 44, 8), createShadow(0, 11, 15, -7, 0, 24, 38, 3, 0, 9, 46, 8)];\nexport default shadows;","import _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nconst _excluded = [\"duration\", \"easing\", \"delay\"];\n// Follow https://material.google.com/motion/duration-easing.html#duration-easing-natural-easing-curves\n// to learn the context in which each easing should be used.\nexport const easing = {\n // This is the most common easing curve.\n easeInOut: 'cubic-bezier(0.4, 0, 0.2, 1)',\n // Objects enter the screen at full velocity from off-screen and\n // slowly decelerate to a resting point.\n easeOut: 'cubic-bezier(0.0, 0, 0.2, 1)',\n // Objects leave the screen at full velocity. They do not decelerate when off-screen.\n easeIn: 'cubic-bezier(0.4, 0, 1, 1)',\n // The sharp curve is used by objects that may return to the screen at any time.\n sharp: 'cubic-bezier(0.4, 0, 0.6, 1)'\n};\n\n// Follow https://m2.material.io/guidelines/motion/duration-easing.html#duration-easing-common-durations\n// to learn when use what timing\nexport const duration = {\n shortest: 150,\n shorter: 200,\n short: 250,\n // most basic recommended timing\n standard: 300,\n // this is to be used in complex animations\n complex: 375,\n // recommended when something is entering screen\n enteringScreen: 225,\n // recommended when something is leaving screen\n leavingScreen: 195\n};\nfunction formatMs(milliseconds) {\n return `${Math.round(milliseconds)}ms`;\n}\nfunction getAutoHeightDuration(height) {\n if (!height) {\n return 0;\n }\n const constant = height / 36;\n\n // https://www.wolframalpha.com/input/?i=(4+%2B+15+*+(x+%2F+36+)+**+0.25+%2B+(x+%2F+36)+%2F+5)+*+10\n return Math.round((4 + 15 * constant ** 0.25 + constant / 5) * 10);\n}\nexport default function createTransitions(inputTransitions) {\n const mergedEasing = _extends({}, easing, inputTransitions.easing);\n const mergedDuration = _extends({}, duration, inputTransitions.duration);\n const create = (props = ['all'], options = {}) => {\n const {\n duration: durationOption = mergedDuration.standard,\n easing: easingOption = mergedEasing.easeInOut,\n delay = 0\n } = options,\n other = _objectWithoutPropertiesLoose(options, _excluded);\n if (process.env.NODE_ENV !== 'production') {\n const isString = value => typeof value === 'string';\n // IE11 support, replace with Number.isNaN\n // eslint-disable-next-line no-restricted-globals\n const isNumber = value => !isNaN(parseFloat(value));\n if (!isString(props) && !Array.isArray(props)) {\n console.error('MUI: Argument \"props\" must be a string or Array.');\n }\n if (!isNumber(durationOption) && !isString(durationOption)) {\n console.error(`MUI: Argument \"duration\" must be a number or a string but found ${durationOption}.`);\n }\n if (!isString(easingOption)) {\n console.error('MUI: Argument \"easing\" must be a string.');\n }\n if (!isNumber(delay) && !isString(delay)) {\n console.error('MUI: Argument \"delay\" must be a number or a string.');\n }\n if (typeof options !== 'object') {\n console.error(['MUI: Secong argument of transition.create must be an object.', \"Arguments should be either `create('prop1', options)` or `create(['prop1', 'prop2'], options)`\"].join('\\n'));\n }\n if (Object.keys(other).length !== 0) {\n console.error(`MUI: Unrecognized argument(s) [${Object.keys(other).join(',')}].`);\n }\n }\n return (Array.isArray(props) ? props : [props]).map(animatedProp => `${animatedProp} ${typeof durationOption === 'string' ? durationOption : formatMs(durationOption)} ${easingOption} ${typeof delay === 'string' ? delay : formatMs(delay)}`).join(',');\n };\n return _extends({\n getAutoHeightDuration,\n create\n }, inputTransitions, {\n easing: mergedEasing,\n duration: mergedDuration\n });\n}","// We need to centralize the zIndex definitions as they work\n// like global values in the browser.\nconst zIndex = {\n mobileStepper: 1000,\n fab: 1050,\n speedDial: 1050,\n appBar: 1100,\n drawer: 1200,\n modal: 1300,\n snackbar: 1400,\n tooltip: 1500\n};\nexport default zIndex;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\nconst _excluded = [\"breakpoints\", \"mixins\", \"spacing\", \"palette\", \"transitions\", \"typography\", \"shape\"];\nimport { deepmerge } from '@mui/utils';\nimport { createTheme as systemCreateTheme, unstable_defaultSxConfig as defaultSxConfig, unstable_styleFunctionSx as styleFunctionSx } from '@mui/system';\nimport generateUtilityClass from '@mui/utils/generateUtilityClass';\nimport createMixins from './createMixins';\nimport createPalette from './createPalette';\nimport createTypography from './createTypography';\nimport shadows from './shadows';\nimport createTransitions from './createTransitions';\nimport zIndex from './zIndex';\nfunction createTheme(options = {}, ...args) {\n const {\n mixins: mixinsInput = {},\n palette: paletteInput = {},\n transitions: transitionsInput = {},\n typography: typographyInput = {}\n } = options,\n other = _objectWithoutPropertiesLoose(options, _excluded);\n if (options.vars) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: \\`vars\\` is a private field used for CSS variables support.\nPlease use another name.` : _formatMuiErrorMessage(18));\n }\n const palette = createPalette(paletteInput);\n const systemTheme = systemCreateTheme(options);\n let muiTheme = deepmerge(systemTheme, {\n mixins: createMixins(systemTheme.breakpoints, mixinsInput),\n palette,\n // Don't use [...shadows] until you've verified its transpiled code is not invoking the iterator protocol.\n shadows: shadows.slice(),\n typography: createTypography(palette, typographyInput),\n transitions: createTransitions(transitionsInput),\n zIndex: _extends({}, zIndex)\n });\n muiTheme = deepmerge(muiTheme, other);\n muiTheme = args.reduce((acc, argument) => deepmerge(acc, argument), muiTheme);\n if (process.env.NODE_ENV !== 'production') {\n // TODO v6: Refactor to use globalStateClassesMapping from @mui/utils once `readOnly` state class is used in Rating component.\n const stateClasses = ['active', 'checked', 'completed', 'disabled', 'error', 'expanded', 'focused', 'focusVisible', 'required', 'selected'];\n const traverse = (node, component) => {\n let key;\n\n // eslint-disable-next-line guard-for-in, no-restricted-syntax\n for (key in node) {\n const child = node[key];\n if (stateClasses.indexOf(key) !== -1 && Object.keys(child).length > 0) {\n if (process.env.NODE_ENV !== 'production') {\n const stateClass = generateUtilityClass('', key);\n console.error([`MUI: The \\`${component}\\` component increases ` + `the CSS specificity of the \\`${key}\\` internal state.`, 'You can not override it like this: ', JSON.stringify(node, null, 2), '', `Instead, you need to use the '&.${stateClass}' syntax:`, JSON.stringify({\n root: {\n [`&.${stateClass}`]: child\n }\n }, null, 2), '', 'https://mui.com/r/state-classes-guide'].join('\\n'));\n }\n // Remove the style to prevent global conflicts.\n node[key] = {};\n }\n }\n };\n Object.keys(muiTheme.components).forEach(component => {\n const styleOverrides = muiTheme.components[component].styleOverrides;\n if (styleOverrides && component.indexOf('Mui') === 0) {\n traverse(styleOverrides, component);\n }\n });\n }\n muiTheme.unstable_sxConfig = _extends({}, defaultSxConfig, other == null ? void 0 : other.unstable_sxConfig);\n muiTheme.unstable_sx = function sx(props) {\n return styleFunctionSx({\n sx: props,\n theme: this\n });\n };\n return muiTheme;\n}\nlet warnedOnce = false;\nexport function createMuiTheme(...args) {\n if (process.env.NODE_ENV !== 'production') {\n if (!warnedOnce) {\n warnedOnce = true;\n console.error(['MUI: the createMuiTheme function was renamed to createTheme.', '', \"You should use `import { createTheme } from '@mui/material/styles'`\"].join('\\n'));\n }\n }\n return createTheme(...args);\n}\nexport default createTheme;","'use client';\n\nimport createTheme from './createTheme';\nconst defaultTheme = createTheme();\nexport default defaultTheme;","export default '$$material';","'use client';\n\nimport { useThemeProps as systemUseThemeProps } from '@mui/system';\nimport defaultTheme from './defaultTheme';\nimport THEME_ID from './identifier';\nexport default function useThemeProps({\n props,\n name\n}) {\n return systemUseThemeProps({\n props,\n name,\n defaultTheme,\n themeId: THEME_ID\n });\n}","'use client';\n\nimport { createStyled, shouldForwardProp } from '@mui/system';\nimport defaultTheme from './defaultTheme';\nimport THEME_ID from './identifier';\nexport const rootShouldForwardProp = prop => shouldForwardProp(prop) && prop !== 'classes';\nexport const slotShouldForwardProp = shouldForwardProp;\nconst styled = createStyled({\n themeId: THEME_ID,\n defaultTheme,\n rootShouldForwardProp\n});\nexport default styled;","import generateUtilityClasses from '@mui/utils/generateUtilityClasses';\nimport generateUtilityClass from '@mui/utils/generateUtilityClass';\nexport function getSvgIconUtilityClass(slot) {\n return generateUtilityClass('MuiSvgIcon', slot);\n}\nconst svgIconClasses = generateUtilityClasses('MuiSvgIcon', ['root', 'colorPrimary', 'colorSecondary', 'colorAction', 'colorError', 'colorDisabled', 'fontSizeInherit', 'fontSizeSmall', 'fontSizeMedium', 'fontSizeLarge']);\nexport default svgIconClasses;","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"children\", \"className\", \"color\", \"component\", \"fontSize\", \"htmlColor\", \"inheritViewBox\", \"titleAccess\", \"viewBox\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport clsx from 'clsx';\nimport { unstable_composeClasses as composeClasses } from '@mui/base/composeClasses';\nimport capitalize from '../utils/capitalize';\nimport useThemeProps from '../styles/useThemeProps';\nimport styled from '../styles/styled';\nimport { getSvgIconUtilityClass } from './svgIconClasses';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nimport { jsxs as _jsxs } from \"react/jsx-runtime\";\nconst useUtilityClasses = ownerState => {\n const {\n color,\n fontSize,\n classes\n } = ownerState;\n const slots = {\n root: ['root', color !== 'inherit' && `color${capitalize(color)}`, `fontSize${capitalize(fontSize)}`]\n };\n return composeClasses(slots, getSvgIconUtilityClass, classes);\n};\nconst SvgIconRoot = styled('svg', {\n name: 'MuiSvgIcon',\n slot: 'Root',\n overridesResolver: (props, styles) => {\n const {\n ownerState\n } = props;\n return [styles.root, ownerState.color !== 'inherit' && styles[`color${capitalize(ownerState.color)}`], styles[`fontSize${capitalize(ownerState.fontSize)}`]];\n }\n})(({\n theme,\n ownerState\n}) => {\n var _theme$transitions, _theme$transitions$cr, _theme$transitions2, _theme$typography, _theme$typography$pxT, _theme$typography2, _theme$typography2$px, _theme$typography3, _theme$typography3$px, _palette$ownerState$c, _palette, _palette2, _palette3;\n return {\n userSelect: 'none',\n width: '1em',\n height: '1em',\n display: 'inline-block',\n // the will define the property that has `currentColor`\n // e.g. heroicons uses fill=\"none\" and stroke=\"currentColor\"\n fill: ownerState.hasSvgAsChild ? undefined : 'currentColor',\n flexShrink: 0,\n transition: (_theme$transitions = theme.transitions) == null || (_theme$transitions$cr = _theme$transitions.create) == null ? void 0 : _theme$transitions$cr.call(_theme$transitions, 'fill', {\n duration: (_theme$transitions2 = theme.transitions) == null || (_theme$transitions2 = _theme$transitions2.duration) == null ? void 0 : _theme$transitions2.shorter\n }),\n fontSize: {\n inherit: 'inherit',\n small: ((_theme$typography = theme.typography) == null || (_theme$typography$pxT = _theme$typography.pxToRem) == null ? void 0 : _theme$typography$pxT.call(_theme$typography, 20)) || '1.25rem',\n medium: ((_theme$typography2 = theme.typography) == null || (_theme$typography2$px = _theme$typography2.pxToRem) == null ? void 0 : _theme$typography2$px.call(_theme$typography2, 24)) || '1.5rem',\n large: ((_theme$typography3 = theme.typography) == null || (_theme$typography3$px = _theme$typography3.pxToRem) == null ? void 0 : _theme$typography3$px.call(_theme$typography3, 35)) || '2.1875rem'\n }[ownerState.fontSize],\n // TODO v5 deprecate, v6 remove for sx\n color: (_palette$ownerState$c = (_palette = (theme.vars || theme).palette) == null || (_palette = _palette[ownerState.color]) == null ? void 0 : _palette.main) != null ? _palette$ownerState$c : {\n action: (_palette2 = (theme.vars || theme).palette) == null || (_palette2 = _palette2.action) == null ? void 0 : _palette2.active,\n disabled: (_palette3 = (theme.vars || theme).palette) == null || (_palette3 = _palette3.action) == null ? void 0 : _palette3.disabled,\n inherit: undefined\n }[ownerState.color]\n };\n});\nconst SvgIcon = /*#__PURE__*/React.forwardRef(function SvgIcon(inProps, ref) {\n const props = useThemeProps({\n props: inProps,\n name: 'MuiSvgIcon'\n });\n const {\n children,\n className,\n color = 'inherit',\n component = 'svg',\n fontSize = 'medium',\n htmlColor,\n inheritViewBox = false,\n titleAccess,\n viewBox = '0 0 24 24'\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const hasSvgAsChild = /*#__PURE__*/React.isValidElement(children) && children.type === 'svg';\n const ownerState = _extends({}, props, {\n color,\n component,\n fontSize,\n instanceFontSize: inProps.fontSize,\n inheritViewBox,\n viewBox,\n hasSvgAsChild\n });\n const more = {};\n if (!inheritViewBox) {\n more.viewBox = viewBox;\n }\n const classes = useUtilityClasses(ownerState);\n return /*#__PURE__*/_jsxs(SvgIconRoot, _extends({\n as: component,\n className: clsx(classes.root, className),\n focusable: \"false\",\n color: htmlColor,\n \"aria-hidden\": titleAccess ? undefined : true,\n role: titleAccess ? 'img' : undefined,\n ref: ref\n }, more, other, hasSvgAsChild && children.props, {\n ownerState: ownerState,\n children: [hasSvgAsChild ? children.props.children : children, titleAccess ? /*#__PURE__*/_jsx(\"title\", {\n children: titleAccess\n }) : null]\n }));\n});\nprocess.env.NODE_ENV !== \"production\" ? SvgIcon.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the d.ts file and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * Node passed into the SVG element.\n */\n children: PropTypes.node,\n /**\n * Override or extend the styles applied to the component.\n */\n classes: PropTypes.object,\n /**\n * @ignore\n */\n className: PropTypes.string,\n /**\n * The color of the component.\n * It supports both default and custom theme colors, which can be added as shown in the\n * [palette customization guide](https://mui.com/material-ui/customization/palette/#custom-colors).\n * You can use the `htmlColor` prop to apply a color attribute to the SVG element.\n * @default 'inherit'\n */\n color: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.oneOf(['inherit', 'action', 'disabled', 'primary', 'secondary', 'error', 'info', 'success', 'warning']), PropTypes.string]),\n /**\n * The component used for the root node.\n * Either a string to use a HTML element or a component.\n */\n component: PropTypes.elementType,\n /**\n * The fontSize applied to the icon. Defaults to 24px, but can be configure to inherit font size.\n * @default 'medium'\n */\n fontSize: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.oneOf(['inherit', 'large', 'medium', 'small']), PropTypes.string]),\n /**\n * Applies a color attribute to the SVG element.\n */\n htmlColor: PropTypes.string,\n /**\n * If `true`, the root node will inherit the custom `component`'s viewBox and the `viewBox`\n * prop will be ignored.\n * Useful when you want to reference a custom `component` and have `SvgIcon` pass that\n * `component`'s viewBox to the root node.\n * @default false\n */\n inheritViewBox: PropTypes.bool,\n /**\n * The shape-rendering attribute. The behavior of the different options is described on the\n * [MDN Web Docs](https://developer.mozilla.org/en-US/docs/Web/SVG/Attribute/shape-rendering).\n * If you are having issues with blurry icons you should investigate this prop.\n */\n shapeRendering: PropTypes.string,\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Provides a human-readable title for the element that contains it.\n * https://www.w3.org/TR/SVG-access/#Equivalent\n */\n titleAccess: PropTypes.string,\n /**\n * Allows you to redefine what the coordinates without units mean inside an SVG element.\n * For example, if the SVG element is 500 (width) by 200 (height),\n * and you pass viewBox=\"0 0 50 20\",\n * this means that the coordinates inside the SVG will go from the top left corner (0,0)\n * to bottom right (50,20) and each unit will be worth 10px.\n * @default '0 0 24 24'\n */\n viewBox: PropTypes.string\n} : void 0;\nSvgIcon.muiName = 'SvgIcon';\nexport default SvgIcon;","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport * as React from 'react';\nimport SvgIcon from '../SvgIcon';\n\n/**\n * Private module reserved for @mui packages.\n */\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nexport default function createSvgIcon(path, displayName) {\n function Component(props, ref) {\n return /*#__PURE__*/_jsx(SvgIcon, _extends({\n \"data-testid\": `${displayName}Icon`,\n ref: ref\n }, props, {\n children: path\n }));\n }\n if (process.env.NODE_ENV !== 'production') {\n // Need to set `displayName` on the inner component for React.memo.\n // React prior to 16.14 ignores `displayName` on the wrapper.\n Component.displayName = `${displayName}Icon`;\n }\n Component.muiName = SvgIcon.muiName;\n return /*#__PURE__*/React.memo( /*#__PURE__*/React.forwardRef(Component));\n}","'use client';\n\nimport { unstable_ClassNameGenerator as ClassNameGenerator } from '@mui/base/ClassNameGenerator';\nexport { default as capitalize } from './capitalize';\nexport { default as createChainedFunction } from './createChainedFunction';\nexport { default as createSvgIcon } from './createSvgIcon';\nexport { default as debounce } from './debounce';\nexport { default as deprecatedPropType } from './deprecatedPropType';\nexport { default as isMuiElement } from './isMuiElement';\nexport { default as ownerDocument } from './ownerDocument';\nexport { default as ownerWindow } from './ownerWindow';\nexport { default as requirePropFactory } from './requirePropFactory';\nexport { default as setRef } from './setRef';\nexport { default as unstable_useEnhancedEffect } from './useEnhancedEffect';\nexport { default as unstable_useId } from './useId';\nexport { default as unsupportedProp } from './unsupportedProp';\nexport { default as useControlled } from './useControlled';\nexport { default as useEventCallback } from './useEventCallback';\nexport { default as useForkRef } from './useForkRef';\nexport { default as useIsFocusVisible } from './useIsFocusVisible';\n// TODO: remove this export once ClassNameGenerator is stable\n// eslint-disable-next-line @typescript-eslint/naming-convention\nexport const unstable_ClassNameGenerator = {\n configure: generator => {\n if (process.env.NODE_ENV !== 'production') {\n console.warn(['MUI: `ClassNameGenerator` import from `@mui/material/utils` is outdated and might cause unexpected issues.', '', \"You should use `import { unstable_ClassNameGenerator } from '@mui/material/className'` instead\", '', 'The detail of the issue: https://github.com/mui/material-ui/issues/30011#issuecomment-1024993401', '', 'The updated documentation: https://mui.com/guides/classname-generator/'].join('\\n'));\n }\n ClassNameGenerator.configure(generator);\n }\n};","\"use strict\";\n'use client';\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nObject.defineProperty(exports, \"default\", {\n enumerable: true,\n get: function () {\n return _utils.createSvgIcon;\n }\n});\nvar _utils = require(\"@mui/material/utils\");","\"use strict\";\n\"use client\";\n\nvar _interopRequireDefault = require(\"@babel/runtime/helpers/interopRequireDefault\");\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = void 0;\nvar _createSvgIcon = _interopRequireDefault(require(\"./utils/createSvgIcon\"));\nvar _jsxRuntime = require(\"react/jsx-runtime\");\nvar _default = exports.default = (0, _createSvgIcon.default)( /*#__PURE__*/(0, _jsxRuntime.jsx)(\"path\", {\n d: \"m10 17 5-5-5-5z\"\n}), 'ArrowRight');","/**\n * Determines if a given element is a DOM element name (i.e. not a React component).\n */\nexport function isHostComponent(element) {\n return typeof element === 'string';\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport { isHostComponent } from './isHostComponent';\n\n/**\n * Type of the ownerState based on the type of an element it applies to.\n * This resolves to the provided OwnerState for React components and `undefined` for host components.\n * Falls back to `OwnerState | undefined` when the exact type can't be determined in development time.\n */\n\n/**\n * Appends the ownerState object to the props, merging with the existing one if necessary.\n *\n * @param elementType Type of the element that owns the `existingProps`. If the element is a DOM node or undefined, `ownerState` is not applied.\n * @param otherProps Props of the element.\n * @param ownerState\n */\nexport function appendOwnerState(elementType, otherProps, ownerState) {\n if (elementType === undefined || isHostComponent(elementType)) {\n return otherProps;\n }\n return _extends({}, otherProps, {\n ownerState: _extends({}, otherProps.ownerState, ownerState)\n });\n}","'use client';\n\nimport * as React from 'react';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nconst defaultContextValue = {\n disableDefaultClasses: false\n};\nconst ClassNameConfiguratorContext = /*#__PURE__*/React.createContext(defaultContextValue);\n/**\n * @ignore - internal hook.\n *\n * Wraps the `generateUtilityClass` function and controls how the classes are generated.\n * Currently it only affects whether the classes are applied or not.\n *\n * @returns Function to be called with the `generateUtilityClass` function specific to a component to generate the classes.\n */\nexport function useClassNamesOverride(generateUtilityClass) {\n const {\n disableDefaultClasses\n } = React.useContext(ClassNameConfiguratorContext);\n return slot => {\n if (disableDefaultClasses) {\n return '';\n }\n return generateUtilityClass(slot);\n };\n}\n\n/**\n * Allows to configure the components within to not apply any built-in classes.\n */\nexport function ClassNameConfigurator(props) {\n const {\n disableDefaultClasses,\n children\n } = props;\n const contextValue = React.useMemo(() => ({\n disableDefaultClasses: disableDefaultClasses != null ? disableDefaultClasses : false\n }), [disableDefaultClasses]);\n return /*#__PURE__*/_jsx(ClassNameConfiguratorContext.Provider, {\n value: contextValue,\n children: children\n });\n}","/**\n * Extracts event handlers from a given object.\n * A prop is considered an event handler if it is a function and its name starts with `on`.\n *\n * @param object An object to extract event handlers from.\n * @param excludeKeys An array of keys to exclude from the returned object.\n */\nexport function extractEventHandlers(object, excludeKeys = []) {\n if (object === undefined) {\n return {};\n }\n const result = {};\n Object.keys(object).filter(prop => prop.match(/^on[A-Z]/) && typeof object[prop] === 'function' && !excludeKeys.includes(prop)).forEach(prop => {\n result[prop] = object[prop];\n });\n return result;\n}","/**\n * If `componentProps` is a function, calls it with the provided `ownerState`.\n * Otherwise, just returns `componentProps`.\n */\nexport function resolveComponentProps(componentProps, ownerState, slotState) {\n if (typeof componentProps === 'function') {\n return componentProps(ownerState, slotState);\n }\n return componentProps;\n}","/**\n * Removes event handlers from the given object.\n * A field is considered an event handler if it is a function with a name beginning with `on`.\n *\n * @param object Object to remove event handlers from.\n * @returns Object with event handlers removed.\n */\nexport function omitEventHandlers(object) {\n if (object === undefined) {\n return {};\n }\n const result = {};\n Object.keys(object).filter(prop => !(prop.match(/^on[A-Z]/) && typeof object[prop] === 'function')).forEach(prop => {\n result[prop] = object[prop];\n });\n return result;\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport clsx from 'clsx';\nimport { extractEventHandlers } from './extractEventHandlers';\nimport { omitEventHandlers } from './omitEventHandlers';\n/**\n * Merges the slot component internal props (usually coming from a hook)\n * with the externally provided ones.\n *\n * The merge order is (the latter overrides the former):\n * 1. The internal props (specified as a getter function to work with get*Props hook result)\n * 2. Additional props (specified internally on a Base UI component)\n * 3. External props specified on the owner component. These should only be used on a root slot.\n * 4. External props specified in the `slotProps.*` prop.\n * 5. The `className` prop - combined from all the above.\n * @param parameters\n * @returns\n */\nexport function mergeSlotProps(parameters) {\n const {\n getSlotProps,\n additionalProps,\n externalSlotProps,\n externalForwardedProps,\n className\n } = parameters;\n if (!getSlotProps) {\n // The simpler case - getSlotProps is not defined, so no internal event handlers are defined,\n // so we can simply merge all the props without having to worry about extracting event handlers.\n const joinedClasses = clsx(additionalProps == null ? void 0 : additionalProps.className, className, externalForwardedProps == null ? void 0 : externalForwardedProps.className, externalSlotProps == null ? void 0 : externalSlotProps.className);\n const mergedStyle = _extends({}, additionalProps == null ? void 0 : additionalProps.style, externalForwardedProps == null ? void 0 : externalForwardedProps.style, externalSlotProps == null ? void 0 : externalSlotProps.style);\n const props = _extends({}, additionalProps, externalForwardedProps, externalSlotProps);\n if (joinedClasses.length > 0) {\n props.className = joinedClasses;\n }\n if (Object.keys(mergedStyle).length > 0) {\n props.style = mergedStyle;\n }\n return {\n props,\n internalRef: undefined\n };\n }\n\n // In this case, getSlotProps is responsible for calling the external event handlers.\n // We don't need to include them in the merged props because of this.\n\n const eventHandlers = extractEventHandlers(_extends({}, externalForwardedProps, externalSlotProps));\n const componentsPropsWithoutEventHandlers = omitEventHandlers(externalSlotProps);\n const otherPropsWithoutEventHandlers = omitEventHandlers(externalForwardedProps);\n const internalSlotProps = getSlotProps(eventHandlers);\n\n // The order of classes is important here.\n // Emotion (that we use in libraries consuming Base UI) depends on this order\n // to properly override style. It requires the most important classes to be last\n // (see https://github.com/mui/material-ui/pull/33205) for the related discussion.\n const joinedClasses = clsx(internalSlotProps == null ? void 0 : internalSlotProps.className, additionalProps == null ? void 0 : additionalProps.className, className, externalForwardedProps == null ? void 0 : externalForwardedProps.className, externalSlotProps == null ? void 0 : externalSlotProps.className);\n const mergedStyle = _extends({}, internalSlotProps == null ? void 0 : internalSlotProps.style, additionalProps == null ? void 0 : additionalProps.style, externalForwardedProps == null ? void 0 : externalForwardedProps.style, externalSlotProps == null ? void 0 : externalSlotProps.style);\n const props = _extends({}, internalSlotProps, additionalProps, otherPropsWithoutEventHandlers, componentsPropsWithoutEventHandlers);\n if (joinedClasses.length > 0) {\n props.className = joinedClasses;\n }\n if (Object.keys(mergedStyle).length > 0) {\n props.style = mergedStyle;\n }\n return {\n props,\n internalRef: internalSlotProps.ref\n };\n}","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"elementType\", \"externalSlotProps\", \"ownerState\", \"skipResolvingSlotProps\"];\nimport { unstable_useForkRef as useForkRef } from '@mui/utils';\nimport { appendOwnerState } from './appendOwnerState';\nimport { mergeSlotProps } from './mergeSlotProps';\nimport { resolveComponentProps } from './resolveComponentProps';\n/**\n * @ignore - do not document.\n * Builds the props to be passed into the slot of an unstyled component.\n * It merges the internal props of the component with the ones supplied by the user, allowing to customize the behavior.\n * If the slot component is not a host component, it also merges in the `ownerState`.\n *\n * @param parameters.getSlotProps - A function that returns the props to be passed to the slot component.\n */\nexport function useSlotProps(parameters) {\n var _parameters$additiona;\n const {\n elementType,\n externalSlotProps,\n ownerState,\n skipResolvingSlotProps = false\n } = parameters,\n rest = _objectWithoutPropertiesLoose(parameters, _excluded);\n const resolvedComponentsProps = skipResolvingSlotProps ? {} : resolveComponentProps(externalSlotProps, ownerState);\n const {\n props: mergedProps,\n internalRef\n } = mergeSlotProps(_extends({}, rest, {\n externalSlotProps: resolvedComponentsProps\n }));\n const ref = useForkRef(internalRef, resolvedComponentsProps == null ? void 0 : resolvedComponentsProps.ref, (_parameters$additiona = parameters.additionalProps) == null ? void 0 : _parameters$additiona.ref);\n const props = appendOwnerState(elementType, _extends({}, mergedProps, {\n ref\n }), ownerState);\n return props;\n}","import { globalStateClasses } from '@mui/utils/generateUtilityClass';\nconst GLOBAL_CLASS_PREFIX = 'base';\nfunction buildStateClass(state) {\n return `${GLOBAL_CLASS_PREFIX}--${state}`;\n}\nfunction buildSlotClass(componentName, slot) {\n return `${GLOBAL_CLASS_PREFIX}-${componentName}-${slot}`;\n}\nexport function generateUtilityClass(componentName, slot) {\n const globalStateClass = globalStateClasses[slot];\n return globalStateClass ? buildStateClass(globalStateClass) : buildSlotClass(componentName, slot);\n}\nexport function isGlobalState(slot) {\n return globalStateClasses[slot] !== undefined;\n}","import { generateUtilityClass } from '../generateUtilityClass';\nexport function generateUtilityClasses(componentName, slots) {\n const result = {};\n slots.forEach(slot => {\n result[slot] = generateUtilityClass(componentName, slot);\n });\n return result;\n}","'use client';\n\nimport * as React from 'react';\nimport * as ReactDOM from 'react-dom';\nimport PropTypes from 'prop-types';\nimport { exactProp, HTMLElementType, unstable_useEnhancedEffect as useEnhancedEffect, unstable_useForkRef as useForkRef, unstable_setRef as setRef } from '@mui/utils';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nfunction getContainer(container) {\n return typeof container === 'function' ? container() : container;\n}\n\n/**\n * Portals provide a first-class way to render children into a DOM node\n * that exists outside the DOM hierarchy of the parent component.\n *\n * Demos:\n *\n * - [Portal](https://mui.com/base-ui/react-portal/)\n *\n * API:\n *\n * - [Portal API](https://mui.com/base-ui/react-portal/components-api/#portal)\n */\nconst Portal = /*#__PURE__*/React.forwardRef(function Portal(props, forwardedRef) {\n const {\n children,\n container,\n disablePortal = false\n } = props;\n const [mountNode, setMountNode] = React.useState(null);\n // @ts-expect-error TODO upstream fix\n const handleRef = useForkRef( /*#__PURE__*/React.isValidElement(children) ? children.ref : null, forwardedRef);\n useEnhancedEffect(() => {\n if (!disablePortal) {\n setMountNode(getContainer(container) || document.body);\n }\n }, [container, disablePortal]);\n useEnhancedEffect(() => {\n if (mountNode && !disablePortal) {\n setRef(forwardedRef, mountNode);\n return () => {\n setRef(forwardedRef, null);\n };\n }\n return undefined;\n }, [forwardedRef, mountNode, disablePortal]);\n if (disablePortal) {\n if ( /*#__PURE__*/React.isValidElement(children)) {\n const newProps = {\n ref: handleRef\n };\n return /*#__PURE__*/React.cloneElement(children, newProps);\n }\n return /*#__PURE__*/_jsx(React.Fragment, {\n children: children\n });\n }\n return /*#__PURE__*/_jsx(React.Fragment, {\n children: mountNode ? /*#__PURE__*/ReactDOM.createPortal(children, mountNode) : mountNode\n });\n});\nprocess.env.NODE_ENV !== \"production\" ? Portal.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * The children to render into the `container`.\n */\n children: PropTypes.node,\n /**\n * An HTML element or function that returns one.\n * The `container` will have the portal children appended to it.\n *\n * You can also provide a callback, which is called in a React layout effect.\n * This lets you set the container from a ref, and also makes server-side rendering possible.\n *\n * By default, it uses the body of the top-level document object,\n * so it's simply `document.body` most of the time.\n */\n container: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.func]),\n /**\n * The `children` will be under the DOM hierarchy of the parent component.\n * @default false\n */\n disablePortal: PropTypes.bool\n} : void 0;\nif (process.env.NODE_ENV !== 'production') {\n // eslint-disable-next-line\n Portal['propTypes' + ''] = exactProp(Portal.propTypes);\n}\nexport { Portal };","export var top = 'top';\nexport var bottom = 'bottom';\nexport var right = 'right';\nexport var left = 'left';\nexport var auto = 'auto';\nexport var basePlacements = [top, bottom, right, left];\nexport var start = 'start';\nexport var end = 'end';\nexport var clippingParents = 'clippingParents';\nexport var viewport = 'viewport';\nexport var popper = 'popper';\nexport var reference = 'reference';\nexport var variationPlacements = /*#__PURE__*/basePlacements.reduce(function (acc, placement) {\n return acc.concat([placement + \"-\" + start, placement + \"-\" + end]);\n}, []);\nexport var placements = /*#__PURE__*/[].concat(basePlacements, [auto]).reduce(function (acc, placement) {\n return acc.concat([placement, placement + \"-\" + start, placement + \"-\" + end]);\n}, []); // modifiers that need to read the DOM\n\nexport var beforeRead = 'beforeRead';\nexport var read = 'read';\nexport var afterRead = 'afterRead'; // pure-logic modifiers\n\nexport var beforeMain = 'beforeMain';\nexport var main = 'main';\nexport var afterMain = 'afterMain'; // modifier with the purpose to write to the DOM (or write into a framework state)\n\nexport var beforeWrite = 'beforeWrite';\nexport var write = 'write';\nexport var afterWrite = 'afterWrite';\nexport var modifierPhases = [beforeRead, read, afterRead, beforeMain, main, afterMain, beforeWrite, write, afterWrite];","export default function getNodeName(element) {\n return element ? (element.nodeName || '').toLowerCase() : null;\n}","export default function getWindow(node) {\n if (node == null) {\n return window;\n }\n\n if (node.toString() !== '[object Window]') {\n var ownerDocument = node.ownerDocument;\n return ownerDocument ? ownerDocument.defaultView || window : window;\n }\n\n return node;\n}","import getWindow from \"./getWindow.js\";\n\nfunction isElement(node) {\n var OwnElement = getWindow(node).Element;\n return node instanceof OwnElement || node instanceof Element;\n}\n\nfunction isHTMLElement(node) {\n var OwnElement = getWindow(node).HTMLElement;\n return node instanceof OwnElement || node instanceof HTMLElement;\n}\n\nfunction isShadowRoot(node) {\n // IE 11 has no ShadowRoot\n if (typeof ShadowRoot === 'undefined') {\n return false;\n }\n\n var OwnElement = getWindow(node).ShadowRoot;\n return node instanceof OwnElement || node instanceof ShadowRoot;\n}\n\nexport { isElement, isHTMLElement, isShadowRoot };","import getNodeName from \"../dom-utils/getNodeName.js\";\nimport { isHTMLElement } from \"../dom-utils/instanceOf.js\"; // This modifier takes the styles prepared by the `computeStyles` modifier\n// and applies them to the HTMLElements such as popper and arrow\n\nfunction applyStyles(_ref) {\n var state = _ref.state;\n Object.keys(state.elements).forEach(function (name) {\n var style = state.styles[name] || {};\n var attributes = state.attributes[name] || {};\n var element = state.elements[name]; // arrow is optional + virtual elements\n\n if (!isHTMLElement(element) || !getNodeName(element)) {\n return;\n } // Flow doesn't support to extend this property, but it's the most\n // effective way to apply styles to an HTMLElement\n // $FlowFixMe[cannot-write]\n\n\n Object.assign(element.style, style);\n Object.keys(attributes).forEach(function (name) {\n var value = attributes[name];\n\n if (value === false) {\n element.removeAttribute(name);\n } else {\n element.setAttribute(name, value === true ? '' : value);\n }\n });\n });\n}\n\nfunction effect(_ref2) {\n var state = _ref2.state;\n var initialStyles = {\n popper: {\n position: state.options.strategy,\n left: '0',\n top: '0',\n margin: '0'\n },\n arrow: {\n position: 'absolute'\n },\n reference: {}\n };\n Object.assign(state.elements.popper.style, initialStyles.popper);\n state.styles = initialStyles;\n\n if (state.elements.arrow) {\n Object.assign(state.elements.arrow.style, initialStyles.arrow);\n }\n\n return function () {\n Object.keys(state.elements).forEach(function (name) {\n var element = state.elements[name];\n var attributes = state.attributes[name] || {};\n var styleProperties = Object.keys(state.styles.hasOwnProperty(name) ? state.styles[name] : initialStyles[name]); // Set all values to an empty string to unset them\n\n var style = styleProperties.reduce(function (style, property) {\n style[property] = '';\n return style;\n }, {}); // arrow is optional + virtual elements\n\n if (!isHTMLElement(element) || !getNodeName(element)) {\n return;\n }\n\n Object.assign(element.style, style);\n Object.keys(attributes).forEach(function (attribute) {\n element.removeAttribute(attribute);\n });\n });\n };\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'applyStyles',\n enabled: true,\n phase: 'write',\n fn: applyStyles,\n effect: effect,\n requires: ['computeStyles']\n};","import { auto } from \"../enums.js\";\nexport default function getBasePlacement(placement) {\n return placement.split('-')[0];\n}","export var max = Math.max;\nexport var min = Math.min;\nexport var round = Math.round;","export default function getUAString() {\n var uaData = navigator.userAgentData;\n\n if (uaData != null && uaData.brands && Array.isArray(uaData.brands)) {\n return uaData.brands.map(function (item) {\n return item.brand + \"/\" + item.version;\n }).join(' ');\n }\n\n return navigator.userAgent;\n}","import getUAString from \"../utils/userAgent.js\";\nexport default function isLayoutViewport() {\n return !/^((?!chrome|android).)*safari/i.test(getUAString());\n}","import { isElement, isHTMLElement } from \"./instanceOf.js\";\nimport { round } from \"../utils/math.js\";\nimport getWindow from \"./getWindow.js\";\nimport isLayoutViewport from \"./isLayoutViewport.js\";\nexport default function getBoundingClientRect(element, includeScale, isFixedStrategy) {\n if (includeScale === void 0) {\n includeScale = false;\n }\n\n if (isFixedStrategy === void 0) {\n isFixedStrategy = false;\n }\n\n var clientRect = element.getBoundingClientRect();\n var scaleX = 1;\n var scaleY = 1;\n\n if (includeScale && isHTMLElement(element)) {\n scaleX = element.offsetWidth > 0 ? round(clientRect.width) / element.offsetWidth || 1 : 1;\n scaleY = element.offsetHeight > 0 ? round(clientRect.height) / element.offsetHeight || 1 : 1;\n }\n\n var _ref = isElement(element) ? getWindow(element) : window,\n visualViewport = _ref.visualViewport;\n\n var addVisualOffsets = !isLayoutViewport() && isFixedStrategy;\n var x = (clientRect.left + (addVisualOffsets && visualViewport ? visualViewport.offsetLeft : 0)) / scaleX;\n var y = (clientRect.top + (addVisualOffsets && visualViewport ? visualViewport.offsetTop : 0)) / scaleY;\n var width = clientRect.width / scaleX;\n var height = clientRect.height / scaleY;\n return {\n width: width,\n height: height,\n top: y,\n right: x + width,\n bottom: y + height,\n left: x,\n x: x,\n y: y\n };\n}","import getBoundingClientRect from \"./getBoundingClientRect.js\"; // Returns the layout rect of an element relative to its offsetParent. Layout\n// means it doesn't take into account transforms.\n\nexport default function getLayoutRect(element) {\n var clientRect = getBoundingClientRect(element); // Use the clientRect sizes if it's not been transformed.\n // Fixes https://github.com/popperjs/popper-core/issues/1223\n\n var width = element.offsetWidth;\n var height = element.offsetHeight;\n\n if (Math.abs(clientRect.width - width) <= 1) {\n width = clientRect.width;\n }\n\n if (Math.abs(clientRect.height - height) <= 1) {\n height = clientRect.height;\n }\n\n return {\n x: element.offsetLeft,\n y: element.offsetTop,\n width: width,\n height: height\n };\n}","import { isShadowRoot } from \"./instanceOf.js\";\nexport default function contains(parent, child) {\n var rootNode = child.getRootNode && child.getRootNode(); // First, attempt with faster native method\n\n if (parent.contains(child)) {\n return true;\n } // then fallback to custom implementation with Shadow DOM support\n else if (rootNode && isShadowRoot(rootNode)) {\n var next = child;\n\n do {\n if (next && parent.isSameNode(next)) {\n return true;\n } // $FlowFixMe[prop-missing]: need a better way to handle this...\n\n\n next = next.parentNode || next.host;\n } while (next);\n } // Give up, the result is false\n\n\n return false;\n}","import getWindow from \"./getWindow.js\";\nexport default function getComputedStyle(element) {\n return getWindow(element).getComputedStyle(element);\n}","import getNodeName from \"./getNodeName.js\";\nexport default function isTableElement(element) {\n return ['table', 'td', 'th'].indexOf(getNodeName(element)) >= 0;\n}","import { isElement } from \"./instanceOf.js\";\nexport default function getDocumentElement(element) {\n // $FlowFixMe[incompatible-return]: assume body is always available\n return ((isElement(element) ? element.ownerDocument : // $FlowFixMe[prop-missing]\n element.document) || window.document).documentElement;\n}","import getNodeName from \"./getNodeName.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport { isShadowRoot } from \"./instanceOf.js\";\nexport default function getParentNode(element) {\n if (getNodeName(element) === 'html') {\n return element;\n }\n\n return (// this is a quicker (but less type safe) way to save quite some bytes from the bundle\n // $FlowFixMe[incompatible-return]\n // $FlowFixMe[prop-missing]\n element.assignedSlot || // step into the shadow DOM of the parent of a slotted node\n element.parentNode || ( // DOM Element detected\n isShadowRoot(element) ? element.host : null) || // ShadowRoot detected\n // $FlowFixMe[incompatible-call]: HTMLElement is a Node\n getDocumentElement(element) // fallback\n\n );\n}","import getWindow from \"./getWindow.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport getComputedStyle from \"./getComputedStyle.js\";\nimport { isHTMLElement, isShadowRoot } from \"./instanceOf.js\";\nimport isTableElement from \"./isTableElement.js\";\nimport getParentNode from \"./getParentNode.js\";\nimport getUAString from \"../utils/userAgent.js\";\n\nfunction getTrueOffsetParent(element) {\n if (!isHTMLElement(element) || // https://github.com/popperjs/popper-core/issues/837\n getComputedStyle(element).position === 'fixed') {\n return null;\n }\n\n return element.offsetParent;\n} // `.offsetParent` reports `null` for fixed elements, while absolute elements\n// return the containing block\n\n\nfunction getContainingBlock(element) {\n var isFirefox = /firefox/i.test(getUAString());\n var isIE = /Trident/i.test(getUAString());\n\n if (isIE && isHTMLElement(element)) {\n // In IE 9, 10 and 11 fixed elements containing block is always established by the viewport\n var elementCss = getComputedStyle(element);\n\n if (elementCss.position === 'fixed') {\n return null;\n }\n }\n\n var currentNode = getParentNode(element);\n\n if (isShadowRoot(currentNode)) {\n currentNode = currentNode.host;\n }\n\n while (isHTMLElement(currentNode) && ['html', 'body'].indexOf(getNodeName(currentNode)) < 0) {\n var css = getComputedStyle(currentNode); // This is non-exhaustive but covers the most common CSS properties that\n // create a containing block.\n // https://developer.mozilla.org/en-US/docs/Web/CSS/Containing_block#identifying_the_containing_block\n\n if (css.transform !== 'none' || css.perspective !== 'none' || css.contain === 'paint' || ['transform', 'perspective'].indexOf(css.willChange) !== -1 || isFirefox && css.willChange === 'filter' || isFirefox && css.filter && css.filter !== 'none') {\n return currentNode;\n } else {\n currentNode = currentNode.parentNode;\n }\n }\n\n return null;\n} // Gets the closest ancestor positioned element. Handles some edge cases,\n// such as table ancestors and cross browser bugs.\n\n\nexport default function getOffsetParent(element) {\n var window = getWindow(element);\n var offsetParent = getTrueOffsetParent(element);\n\n while (offsetParent && isTableElement(offsetParent) && getComputedStyle(offsetParent).position === 'static') {\n offsetParent = getTrueOffsetParent(offsetParent);\n }\n\n if (offsetParent && (getNodeName(offsetParent) === 'html' || getNodeName(offsetParent) === 'body' && getComputedStyle(offsetParent).position === 'static')) {\n return window;\n }\n\n return offsetParent || getContainingBlock(element) || window;\n}","export default function getMainAxisFromPlacement(placement) {\n return ['top', 'bottom'].indexOf(placement) >= 0 ? 'x' : 'y';\n}","import { max as mathMax, min as mathMin } from \"./math.js\";\nexport function within(min, value, max) {\n return mathMax(min, mathMin(value, max));\n}\nexport function withinMaxClamp(min, value, max) {\n var v = within(min, value, max);\n return v > max ? max : v;\n}","export default function getFreshSideObject() {\n return {\n top: 0,\n right: 0,\n bottom: 0,\n left: 0\n };\n}","import getFreshSideObject from \"./getFreshSideObject.js\";\nexport default function mergePaddingObject(paddingObject) {\n return Object.assign({}, getFreshSideObject(), paddingObject);\n}","export default function expandToHashMap(value, keys) {\n return keys.reduce(function (hashMap, key) {\n hashMap[key] = value;\n return hashMap;\n }, {});\n}","import getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getLayoutRect from \"../dom-utils/getLayoutRect.js\";\nimport contains from \"../dom-utils/contains.js\";\nimport getOffsetParent from \"../dom-utils/getOffsetParent.js\";\nimport getMainAxisFromPlacement from \"../utils/getMainAxisFromPlacement.js\";\nimport { within } from \"../utils/within.js\";\nimport mergePaddingObject from \"../utils/mergePaddingObject.js\";\nimport expandToHashMap from \"../utils/expandToHashMap.js\";\nimport { left, right, basePlacements, top, bottom } from \"../enums.js\"; // eslint-disable-next-line import/no-unused-modules\n\nvar toPaddingObject = function toPaddingObject(padding, state) {\n padding = typeof padding === 'function' ? padding(Object.assign({}, state.rects, {\n placement: state.placement\n })) : padding;\n return mergePaddingObject(typeof padding !== 'number' ? padding : expandToHashMap(padding, basePlacements));\n};\n\nfunction arrow(_ref) {\n var _state$modifiersData$;\n\n var state = _ref.state,\n name = _ref.name,\n options = _ref.options;\n var arrowElement = state.elements.arrow;\n var popperOffsets = state.modifiersData.popperOffsets;\n var basePlacement = getBasePlacement(state.placement);\n var axis = getMainAxisFromPlacement(basePlacement);\n var isVertical = [left, right].indexOf(basePlacement) >= 0;\n var len = isVertical ? 'height' : 'width';\n\n if (!arrowElement || !popperOffsets) {\n return;\n }\n\n var paddingObject = toPaddingObject(options.padding, state);\n var arrowRect = getLayoutRect(arrowElement);\n var minProp = axis === 'y' ? top : left;\n var maxProp = axis === 'y' ? bottom : right;\n var endDiff = state.rects.reference[len] + state.rects.reference[axis] - popperOffsets[axis] - state.rects.popper[len];\n var startDiff = popperOffsets[axis] - state.rects.reference[axis];\n var arrowOffsetParent = getOffsetParent(arrowElement);\n var clientSize = arrowOffsetParent ? axis === 'y' ? arrowOffsetParent.clientHeight || 0 : arrowOffsetParent.clientWidth || 0 : 0;\n var centerToReference = endDiff / 2 - startDiff / 2; // Make sure the arrow doesn't overflow the popper if the center point is\n // outside of the popper bounds\n\n var min = paddingObject[minProp];\n var max = clientSize - arrowRect[len] - paddingObject[maxProp];\n var center = clientSize / 2 - arrowRect[len] / 2 + centerToReference;\n var offset = within(min, center, max); // Prevents breaking syntax highlighting...\n\n var axisProp = axis;\n state.modifiersData[name] = (_state$modifiersData$ = {}, _state$modifiersData$[axisProp] = offset, _state$modifiersData$.centerOffset = offset - center, _state$modifiersData$);\n}\n\nfunction effect(_ref2) {\n var state = _ref2.state,\n options = _ref2.options;\n var _options$element = options.element,\n arrowElement = _options$element === void 0 ? '[data-popper-arrow]' : _options$element;\n\n if (arrowElement == null) {\n return;\n } // CSS selector\n\n\n if (typeof arrowElement === 'string') {\n arrowElement = state.elements.popper.querySelector(arrowElement);\n\n if (!arrowElement) {\n return;\n }\n }\n\n if (!contains(state.elements.popper, arrowElement)) {\n return;\n }\n\n state.elements.arrow = arrowElement;\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'arrow',\n enabled: true,\n phase: 'main',\n fn: arrow,\n effect: effect,\n requires: ['popperOffsets'],\n requiresIfExists: ['preventOverflow']\n};","export default function getVariation(placement) {\n return placement.split('-')[1];\n}","import { top, left, right, bottom, end } from \"../enums.js\";\nimport getOffsetParent from \"../dom-utils/getOffsetParent.js\";\nimport getWindow from \"../dom-utils/getWindow.js\";\nimport getDocumentElement from \"../dom-utils/getDocumentElement.js\";\nimport getComputedStyle from \"../dom-utils/getComputedStyle.js\";\nimport getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getVariation from \"../utils/getVariation.js\";\nimport { round } from \"../utils/math.js\"; // eslint-disable-next-line import/no-unused-modules\n\nvar unsetSides = {\n top: 'auto',\n right: 'auto',\n bottom: 'auto',\n left: 'auto'\n}; // Round the offsets to the nearest suitable subpixel based on the DPR.\n// Zooming can change the DPR, but it seems to report a value that will\n// cleanly divide the values into the appropriate subpixels.\n\nfunction roundOffsetsByDPR(_ref, win) {\n var x = _ref.x,\n y = _ref.y;\n var dpr = win.devicePixelRatio || 1;\n return {\n x: round(x * dpr) / dpr || 0,\n y: round(y * dpr) / dpr || 0\n };\n}\n\nexport function mapToStyles(_ref2) {\n var _Object$assign2;\n\n var popper = _ref2.popper,\n popperRect = _ref2.popperRect,\n placement = _ref2.placement,\n variation = _ref2.variation,\n offsets = _ref2.offsets,\n position = _ref2.position,\n gpuAcceleration = _ref2.gpuAcceleration,\n adaptive = _ref2.adaptive,\n roundOffsets = _ref2.roundOffsets,\n isFixed = _ref2.isFixed;\n var _offsets$x = offsets.x,\n x = _offsets$x === void 0 ? 0 : _offsets$x,\n _offsets$y = offsets.y,\n y = _offsets$y === void 0 ? 0 : _offsets$y;\n\n var _ref3 = typeof roundOffsets === 'function' ? roundOffsets({\n x: x,\n y: y\n }) : {\n x: x,\n y: y\n };\n\n x = _ref3.x;\n y = _ref3.y;\n var hasX = offsets.hasOwnProperty('x');\n var hasY = offsets.hasOwnProperty('y');\n var sideX = left;\n var sideY = top;\n var win = window;\n\n if (adaptive) {\n var offsetParent = getOffsetParent(popper);\n var heightProp = 'clientHeight';\n var widthProp = 'clientWidth';\n\n if (offsetParent === getWindow(popper)) {\n offsetParent = getDocumentElement(popper);\n\n if (getComputedStyle(offsetParent).position !== 'static' && position === 'absolute') {\n heightProp = 'scrollHeight';\n widthProp = 'scrollWidth';\n }\n } // $FlowFixMe[incompatible-cast]: force type refinement, we compare offsetParent with window above, but Flow doesn't detect it\n\n\n offsetParent = offsetParent;\n\n if (placement === top || (placement === left || placement === right) && variation === end) {\n sideY = bottom;\n var offsetY = isFixed && offsetParent === win && win.visualViewport ? win.visualViewport.height : // $FlowFixMe[prop-missing]\n offsetParent[heightProp];\n y -= offsetY - popperRect.height;\n y *= gpuAcceleration ? 1 : -1;\n }\n\n if (placement === left || (placement === top || placement === bottom) && variation === end) {\n sideX = right;\n var offsetX = isFixed && offsetParent === win && win.visualViewport ? win.visualViewport.width : // $FlowFixMe[prop-missing]\n offsetParent[widthProp];\n x -= offsetX - popperRect.width;\n x *= gpuAcceleration ? 1 : -1;\n }\n }\n\n var commonStyles = Object.assign({\n position: position\n }, adaptive && unsetSides);\n\n var _ref4 = roundOffsets === true ? roundOffsetsByDPR({\n x: x,\n y: y\n }, getWindow(popper)) : {\n x: x,\n y: y\n };\n\n x = _ref4.x;\n y = _ref4.y;\n\n if (gpuAcceleration) {\n var _Object$assign;\n\n return Object.assign({}, commonStyles, (_Object$assign = {}, _Object$assign[sideY] = hasY ? '0' : '', _Object$assign[sideX] = hasX ? '0' : '', _Object$assign.transform = (win.devicePixelRatio || 1) <= 1 ? \"translate(\" + x + \"px, \" + y + \"px)\" : \"translate3d(\" + x + \"px, \" + y + \"px, 0)\", _Object$assign));\n }\n\n return Object.assign({}, commonStyles, (_Object$assign2 = {}, _Object$assign2[sideY] = hasY ? y + \"px\" : '', _Object$assign2[sideX] = hasX ? x + \"px\" : '', _Object$assign2.transform = '', _Object$assign2));\n}\n\nfunction computeStyles(_ref5) {\n var state = _ref5.state,\n options = _ref5.options;\n var _options$gpuAccelerat = options.gpuAcceleration,\n gpuAcceleration = _options$gpuAccelerat === void 0 ? true : _options$gpuAccelerat,\n _options$adaptive = options.adaptive,\n adaptive = _options$adaptive === void 0 ? true : _options$adaptive,\n _options$roundOffsets = options.roundOffsets,\n roundOffsets = _options$roundOffsets === void 0 ? true : _options$roundOffsets;\n var commonStyles = {\n placement: getBasePlacement(state.placement),\n variation: getVariation(state.placement),\n popper: state.elements.popper,\n popperRect: state.rects.popper,\n gpuAcceleration: gpuAcceleration,\n isFixed: state.options.strategy === 'fixed'\n };\n\n if (state.modifiersData.popperOffsets != null) {\n state.styles.popper = Object.assign({}, state.styles.popper, mapToStyles(Object.assign({}, commonStyles, {\n offsets: state.modifiersData.popperOffsets,\n position: state.options.strategy,\n adaptive: adaptive,\n roundOffsets: roundOffsets\n })));\n }\n\n if (state.modifiersData.arrow != null) {\n state.styles.arrow = Object.assign({}, state.styles.arrow, mapToStyles(Object.assign({}, commonStyles, {\n offsets: state.modifiersData.arrow,\n position: 'absolute',\n adaptive: false,\n roundOffsets: roundOffsets\n })));\n }\n\n state.attributes.popper = Object.assign({}, state.attributes.popper, {\n 'data-popper-placement': state.placement\n });\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'computeStyles',\n enabled: true,\n phase: 'beforeWrite',\n fn: computeStyles,\n data: {}\n};","import getWindow from \"../dom-utils/getWindow.js\"; // eslint-disable-next-line import/no-unused-modules\n\nvar passive = {\n passive: true\n};\n\nfunction effect(_ref) {\n var state = _ref.state,\n instance = _ref.instance,\n options = _ref.options;\n var _options$scroll = options.scroll,\n scroll = _options$scroll === void 0 ? true : _options$scroll,\n _options$resize = options.resize,\n resize = _options$resize === void 0 ? true : _options$resize;\n var window = getWindow(state.elements.popper);\n var scrollParents = [].concat(state.scrollParents.reference, state.scrollParents.popper);\n\n if (scroll) {\n scrollParents.forEach(function (scrollParent) {\n scrollParent.addEventListener('scroll', instance.update, passive);\n });\n }\n\n if (resize) {\n window.addEventListener('resize', instance.update, passive);\n }\n\n return function () {\n if (scroll) {\n scrollParents.forEach(function (scrollParent) {\n scrollParent.removeEventListener('scroll', instance.update, passive);\n });\n }\n\n if (resize) {\n window.removeEventListener('resize', instance.update, passive);\n }\n };\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'eventListeners',\n enabled: true,\n phase: 'write',\n fn: function fn() {},\n effect: effect,\n data: {}\n};","var hash = {\n left: 'right',\n right: 'left',\n bottom: 'top',\n top: 'bottom'\n};\nexport default function getOppositePlacement(placement) {\n return placement.replace(/left|right|bottom|top/g, function (matched) {\n return hash[matched];\n });\n}","var hash = {\n start: 'end',\n end: 'start'\n};\nexport default function getOppositeVariationPlacement(placement) {\n return placement.replace(/start|end/g, function (matched) {\n return hash[matched];\n });\n}","import getWindow from \"./getWindow.js\";\nexport default function getWindowScroll(node) {\n var win = getWindow(node);\n var scrollLeft = win.pageXOffset;\n var scrollTop = win.pageYOffset;\n return {\n scrollLeft: scrollLeft,\n scrollTop: scrollTop\n };\n}","import getBoundingClientRect from \"./getBoundingClientRect.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport getWindowScroll from \"./getWindowScroll.js\";\nexport default function getWindowScrollBarX(element) {\n // If has a CSS width greater than the viewport, then this will be\n // incorrect for RTL.\n // Popper 1 is broken in this case and never had a bug report so let's assume\n // it's not an issue. I don't think anyone ever specifies width on \n // anyway.\n // Browsers where the left scrollbar doesn't cause an issue report `0` for\n // this (e.g. Edge 2019, IE11, Safari)\n return getBoundingClientRect(getDocumentElement(element)).left + getWindowScroll(element).scrollLeft;\n}","import getWindow from \"./getWindow.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport getWindowScrollBarX from \"./getWindowScrollBarX.js\";\nimport isLayoutViewport from \"./isLayoutViewport.js\";\nexport default function getViewportRect(element, strategy) {\n var win = getWindow(element);\n var html = getDocumentElement(element);\n var visualViewport = win.visualViewport;\n var width = html.clientWidth;\n var height = html.clientHeight;\n var x = 0;\n var y = 0;\n\n if (visualViewport) {\n width = visualViewport.width;\n height = visualViewport.height;\n var layoutViewport = isLayoutViewport();\n\n if (layoutViewport || !layoutViewport && strategy === 'fixed') {\n x = visualViewport.offsetLeft;\n y = visualViewport.offsetTop;\n }\n }\n\n return {\n width: width,\n height: height,\n x: x + getWindowScrollBarX(element),\n y: y\n };\n}","import getDocumentElement from \"./getDocumentElement.js\";\nimport getComputedStyle from \"./getComputedStyle.js\";\nimport getWindowScrollBarX from \"./getWindowScrollBarX.js\";\nimport getWindowScroll from \"./getWindowScroll.js\";\nimport { max } from \"../utils/math.js\"; // Gets the entire size of the scrollable document area, even extending outside\n// of the `` and `` rect bounds if horizontally scrollable\n\nexport default function getDocumentRect(element) {\n var _element$ownerDocumen;\n\n var html = getDocumentElement(element);\n var winScroll = getWindowScroll(element);\n var body = (_element$ownerDocumen = element.ownerDocument) == null ? void 0 : _element$ownerDocumen.body;\n var width = max(html.scrollWidth, html.clientWidth, body ? body.scrollWidth : 0, body ? body.clientWidth : 0);\n var height = max(html.scrollHeight, html.clientHeight, body ? body.scrollHeight : 0, body ? body.clientHeight : 0);\n var x = -winScroll.scrollLeft + getWindowScrollBarX(element);\n var y = -winScroll.scrollTop;\n\n if (getComputedStyle(body || html).direction === 'rtl') {\n x += max(html.clientWidth, body ? body.clientWidth : 0) - width;\n }\n\n return {\n width: width,\n height: height,\n x: x,\n y: y\n };\n}","import getComputedStyle from \"./getComputedStyle.js\";\nexport default function isScrollParent(element) {\n // Firefox wants us to check `-x` and `-y` variations as well\n var _getComputedStyle = getComputedStyle(element),\n overflow = _getComputedStyle.overflow,\n overflowX = _getComputedStyle.overflowX,\n overflowY = _getComputedStyle.overflowY;\n\n return /auto|scroll|overlay|hidden/.test(overflow + overflowY + overflowX);\n}","import getParentNode from \"./getParentNode.js\";\nimport isScrollParent from \"./isScrollParent.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport { isHTMLElement } from \"./instanceOf.js\";\nexport default function getScrollParent(node) {\n if (['html', 'body', '#document'].indexOf(getNodeName(node)) >= 0) {\n // $FlowFixMe[incompatible-return]: assume body is always available\n return node.ownerDocument.body;\n }\n\n if (isHTMLElement(node) && isScrollParent(node)) {\n return node;\n }\n\n return getScrollParent(getParentNode(node));\n}","import getScrollParent from \"./getScrollParent.js\";\nimport getParentNode from \"./getParentNode.js\";\nimport getWindow from \"./getWindow.js\";\nimport isScrollParent from \"./isScrollParent.js\";\n/*\ngiven a DOM element, return the list of all scroll parents, up the list of ancesors\nuntil we get to the top window object. This list is what we attach scroll listeners\nto, because if any of these parent elements scroll, we'll need to re-calculate the\nreference element's position.\n*/\n\nexport default function listScrollParents(element, list) {\n var _element$ownerDocumen;\n\n if (list === void 0) {\n list = [];\n }\n\n var scrollParent = getScrollParent(element);\n var isBody = scrollParent === ((_element$ownerDocumen = element.ownerDocument) == null ? void 0 : _element$ownerDocumen.body);\n var win = getWindow(scrollParent);\n var target = isBody ? [win].concat(win.visualViewport || [], isScrollParent(scrollParent) ? scrollParent : []) : scrollParent;\n var updatedList = list.concat(target);\n return isBody ? updatedList : // $FlowFixMe[incompatible-call]: isBody tells us target will be an HTMLElement here\n updatedList.concat(listScrollParents(getParentNode(target)));\n}","export default function rectToClientRect(rect) {\n return Object.assign({}, rect, {\n left: rect.x,\n top: rect.y,\n right: rect.x + rect.width,\n bottom: rect.y + rect.height\n });\n}","import { viewport } from \"../enums.js\";\nimport getViewportRect from \"./getViewportRect.js\";\nimport getDocumentRect from \"./getDocumentRect.js\";\nimport listScrollParents from \"./listScrollParents.js\";\nimport getOffsetParent from \"./getOffsetParent.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport getComputedStyle from \"./getComputedStyle.js\";\nimport { isElement, isHTMLElement } from \"./instanceOf.js\";\nimport getBoundingClientRect from \"./getBoundingClientRect.js\";\nimport getParentNode from \"./getParentNode.js\";\nimport contains from \"./contains.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport rectToClientRect from \"../utils/rectToClientRect.js\";\nimport { max, min } from \"../utils/math.js\";\n\nfunction getInnerBoundingClientRect(element, strategy) {\n var rect = getBoundingClientRect(element, false, strategy === 'fixed');\n rect.top = rect.top + element.clientTop;\n rect.left = rect.left + element.clientLeft;\n rect.bottom = rect.top + element.clientHeight;\n rect.right = rect.left + element.clientWidth;\n rect.width = element.clientWidth;\n rect.height = element.clientHeight;\n rect.x = rect.left;\n rect.y = rect.top;\n return rect;\n}\n\nfunction getClientRectFromMixedType(element, clippingParent, strategy) {\n return clippingParent === viewport ? rectToClientRect(getViewportRect(element, strategy)) : isElement(clippingParent) ? getInnerBoundingClientRect(clippingParent, strategy) : rectToClientRect(getDocumentRect(getDocumentElement(element)));\n} // A \"clipping parent\" is an overflowable container with the characteristic of\n// clipping (or hiding) overflowing elements with a position different from\n// `initial`\n\n\nfunction getClippingParents(element) {\n var clippingParents = listScrollParents(getParentNode(element));\n var canEscapeClipping = ['absolute', 'fixed'].indexOf(getComputedStyle(element).position) >= 0;\n var clipperElement = canEscapeClipping && isHTMLElement(element) ? getOffsetParent(element) : element;\n\n if (!isElement(clipperElement)) {\n return [];\n } // $FlowFixMe[incompatible-return]: https://github.com/facebook/flow/issues/1414\n\n\n return clippingParents.filter(function (clippingParent) {\n return isElement(clippingParent) && contains(clippingParent, clipperElement) && getNodeName(clippingParent) !== 'body';\n });\n} // Gets the maximum area that the element is visible in due to any number of\n// clipping parents\n\n\nexport default function getClippingRect(element, boundary, rootBoundary, strategy) {\n var mainClippingParents = boundary === 'clippingParents' ? getClippingParents(element) : [].concat(boundary);\n var clippingParents = [].concat(mainClippingParents, [rootBoundary]);\n var firstClippingParent = clippingParents[0];\n var clippingRect = clippingParents.reduce(function (accRect, clippingParent) {\n var rect = getClientRectFromMixedType(element, clippingParent, strategy);\n accRect.top = max(rect.top, accRect.top);\n accRect.right = min(rect.right, accRect.right);\n accRect.bottom = min(rect.bottom, accRect.bottom);\n accRect.left = max(rect.left, accRect.left);\n return accRect;\n }, getClientRectFromMixedType(element, firstClippingParent, strategy));\n clippingRect.width = clippingRect.right - clippingRect.left;\n clippingRect.height = clippingRect.bottom - clippingRect.top;\n clippingRect.x = clippingRect.left;\n clippingRect.y = clippingRect.top;\n return clippingRect;\n}","import getBasePlacement from \"./getBasePlacement.js\";\nimport getVariation from \"./getVariation.js\";\nimport getMainAxisFromPlacement from \"./getMainAxisFromPlacement.js\";\nimport { top, right, bottom, left, start, end } from \"../enums.js\";\nexport default function computeOffsets(_ref) {\n var reference = _ref.reference,\n element = _ref.element,\n placement = _ref.placement;\n var basePlacement = placement ? getBasePlacement(placement) : null;\n var variation = placement ? getVariation(placement) : null;\n var commonX = reference.x + reference.width / 2 - element.width / 2;\n var commonY = reference.y + reference.height / 2 - element.height / 2;\n var offsets;\n\n switch (basePlacement) {\n case top:\n offsets = {\n x: commonX,\n y: reference.y - element.height\n };\n break;\n\n case bottom:\n offsets = {\n x: commonX,\n y: reference.y + reference.height\n };\n break;\n\n case right:\n offsets = {\n x: reference.x + reference.width,\n y: commonY\n };\n break;\n\n case left:\n offsets = {\n x: reference.x - element.width,\n y: commonY\n };\n break;\n\n default:\n offsets = {\n x: reference.x,\n y: reference.y\n };\n }\n\n var mainAxis = basePlacement ? getMainAxisFromPlacement(basePlacement) : null;\n\n if (mainAxis != null) {\n var len = mainAxis === 'y' ? 'height' : 'width';\n\n switch (variation) {\n case start:\n offsets[mainAxis] = offsets[mainAxis] - (reference[len] / 2 - element[len] / 2);\n break;\n\n case end:\n offsets[mainAxis] = offsets[mainAxis] + (reference[len] / 2 - element[len] / 2);\n break;\n\n default:\n }\n }\n\n return offsets;\n}","import getClippingRect from \"../dom-utils/getClippingRect.js\";\nimport getDocumentElement from \"../dom-utils/getDocumentElement.js\";\nimport getBoundingClientRect from \"../dom-utils/getBoundingClientRect.js\";\nimport computeOffsets from \"./computeOffsets.js\";\nimport rectToClientRect from \"./rectToClientRect.js\";\nimport { clippingParents, reference, popper, bottom, top, right, basePlacements, viewport } from \"../enums.js\";\nimport { isElement } from \"../dom-utils/instanceOf.js\";\nimport mergePaddingObject from \"./mergePaddingObject.js\";\nimport expandToHashMap from \"./expandToHashMap.js\"; // eslint-disable-next-line import/no-unused-modules\n\nexport default function detectOverflow(state, options) {\n if (options === void 0) {\n options = {};\n }\n\n var _options = options,\n _options$placement = _options.placement,\n placement = _options$placement === void 0 ? state.placement : _options$placement,\n _options$strategy = _options.strategy,\n strategy = _options$strategy === void 0 ? state.strategy : _options$strategy,\n _options$boundary = _options.boundary,\n boundary = _options$boundary === void 0 ? clippingParents : _options$boundary,\n _options$rootBoundary = _options.rootBoundary,\n rootBoundary = _options$rootBoundary === void 0 ? viewport : _options$rootBoundary,\n _options$elementConte = _options.elementContext,\n elementContext = _options$elementConte === void 0 ? popper : _options$elementConte,\n _options$altBoundary = _options.altBoundary,\n altBoundary = _options$altBoundary === void 0 ? false : _options$altBoundary,\n _options$padding = _options.padding,\n padding = _options$padding === void 0 ? 0 : _options$padding;\n var paddingObject = mergePaddingObject(typeof padding !== 'number' ? padding : expandToHashMap(padding, basePlacements));\n var altContext = elementContext === popper ? reference : popper;\n var popperRect = state.rects.popper;\n var element = state.elements[altBoundary ? altContext : elementContext];\n var clippingClientRect = getClippingRect(isElement(element) ? element : element.contextElement || getDocumentElement(state.elements.popper), boundary, rootBoundary, strategy);\n var referenceClientRect = getBoundingClientRect(state.elements.reference);\n var popperOffsets = computeOffsets({\n reference: referenceClientRect,\n element: popperRect,\n strategy: 'absolute',\n placement: placement\n });\n var popperClientRect = rectToClientRect(Object.assign({}, popperRect, popperOffsets));\n var elementClientRect = elementContext === popper ? popperClientRect : referenceClientRect; // positive = overflowing the clipping rect\n // 0 or negative = within the clipping rect\n\n var overflowOffsets = {\n top: clippingClientRect.top - elementClientRect.top + paddingObject.top,\n bottom: elementClientRect.bottom - clippingClientRect.bottom + paddingObject.bottom,\n left: clippingClientRect.left - elementClientRect.left + paddingObject.left,\n right: elementClientRect.right - clippingClientRect.right + paddingObject.right\n };\n var offsetData = state.modifiersData.offset; // Offsets can be applied only to the popper element\n\n if (elementContext === popper && offsetData) {\n var offset = offsetData[placement];\n Object.keys(overflowOffsets).forEach(function (key) {\n var multiply = [right, bottom].indexOf(key) >= 0 ? 1 : -1;\n var axis = [top, bottom].indexOf(key) >= 0 ? 'y' : 'x';\n overflowOffsets[key] += offset[axis] * multiply;\n });\n }\n\n return overflowOffsets;\n}","import getVariation from \"./getVariation.js\";\nimport { variationPlacements, basePlacements, placements as allPlacements } from \"../enums.js\";\nimport detectOverflow from \"./detectOverflow.js\";\nimport getBasePlacement from \"./getBasePlacement.js\";\nexport default function computeAutoPlacement(state, options) {\n if (options === void 0) {\n options = {};\n }\n\n var _options = options,\n placement = _options.placement,\n boundary = _options.boundary,\n rootBoundary = _options.rootBoundary,\n padding = _options.padding,\n flipVariations = _options.flipVariations,\n _options$allowedAutoP = _options.allowedAutoPlacements,\n allowedAutoPlacements = _options$allowedAutoP === void 0 ? allPlacements : _options$allowedAutoP;\n var variation = getVariation(placement);\n var placements = variation ? flipVariations ? variationPlacements : variationPlacements.filter(function (placement) {\n return getVariation(placement) === variation;\n }) : basePlacements;\n var allowedPlacements = placements.filter(function (placement) {\n return allowedAutoPlacements.indexOf(placement) >= 0;\n });\n\n if (allowedPlacements.length === 0) {\n allowedPlacements = placements;\n } // $FlowFixMe[incompatible-type]: Flow seems to have problems with two array unions...\n\n\n var overflows = allowedPlacements.reduce(function (acc, placement) {\n acc[placement] = detectOverflow(state, {\n placement: placement,\n boundary: boundary,\n rootBoundary: rootBoundary,\n padding: padding\n })[getBasePlacement(placement)];\n return acc;\n }, {});\n return Object.keys(overflows).sort(function (a, b) {\n return overflows[a] - overflows[b];\n });\n}","import getOppositePlacement from \"../utils/getOppositePlacement.js\";\nimport getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getOppositeVariationPlacement from \"../utils/getOppositeVariationPlacement.js\";\nimport detectOverflow from \"../utils/detectOverflow.js\";\nimport computeAutoPlacement from \"../utils/computeAutoPlacement.js\";\nimport { bottom, top, start, right, left, auto } from \"../enums.js\";\nimport getVariation from \"../utils/getVariation.js\"; // eslint-disable-next-line import/no-unused-modules\n\nfunction getExpandedFallbackPlacements(placement) {\n if (getBasePlacement(placement) === auto) {\n return [];\n }\n\n var oppositePlacement = getOppositePlacement(placement);\n return [getOppositeVariationPlacement(placement), oppositePlacement, getOppositeVariationPlacement(oppositePlacement)];\n}\n\nfunction flip(_ref) {\n var state = _ref.state,\n options = _ref.options,\n name = _ref.name;\n\n if (state.modifiersData[name]._skip) {\n return;\n }\n\n var _options$mainAxis = options.mainAxis,\n checkMainAxis = _options$mainAxis === void 0 ? true : _options$mainAxis,\n _options$altAxis = options.altAxis,\n checkAltAxis = _options$altAxis === void 0 ? true : _options$altAxis,\n specifiedFallbackPlacements = options.fallbackPlacements,\n padding = options.padding,\n boundary = options.boundary,\n rootBoundary = options.rootBoundary,\n altBoundary = options.altBoundary,\n _options$flipVariatio = options.flipVariations,\n flipVariations = _options$flipVariatio === void 0 ? true : _options$flipVariatio,\n allowedAutoPlacements = options.allowedAutoPlacements;\n var preferredPlacement = state.options.placement;\n var basePlacement = getBasePlacement(preferredPlacement);\n var isBasePlacement = basePlacement === preferredPlacement;\n var fallbackPlacements = specifiedFallbackPlacements || (isBasePlacement || !flipVariations ? [getOppositePlacement(preferredPlacement)] : getExpandedFallbackPlacements(preferredPlacement));\n var placements = [preferredPlacement].concat(fallbackPlacements).reduce(function (acc, placement) {\n return acc.concat(getBasePlacement(placement) === auto ? computeAutoPlacement(state, {\n placement: placement,\n boundary: boundary,\n rootBoundary: rootBoundary,\n padding: padding,\n flipVariations: flipVariations,\n allowedAutoPlacements: allowedAutoPlacements\n }) : placement);\n }, []);\n var referenceRect = state.rects.reference;\n var popperRect = state.rects.popper;\n var checksMap = new Map();\n var makeFallbackChecks = true;\n var firstFittingPlacement = placements[0];\n\n for (var i = 0; i < placements.length; i++) {\n var placement = placements[i];\n\n var _basePlacement = getBasePlacement(placement);\n\n var isStartVariation = getVariation(placement) === start;\n var isVertical = [top, bottom].indexOf(_basePlacement) >= 0;\n var len = isVertical ? 'width' : 'height';\n var overflow = detectOverflow(state, {\n placement: placement,\n boundary: boundary,\n rootBoundary: rootBoundary,\n altBoundary: altBoundary,\n padding: padding\n });\n var mainVariationSide = isVertical ? isStartVariation ? right : left : isStartVariation ? bottom : top;\n\n if (referenceRect[len] > popperRect[len]) {\n mainVariationSide = getOppositePlacement(mainVariationSide);\n }\n\n var altVariationSide = getOppositePlacement(mainVariationSide);\n var checks = [];\n\n if (checkMainAxis) {\n checks.push(overflow[_basePlacement] <= 0);\n }\n\n if (checkAltAxis) {\n checks.push(overflow[mainVariationSide] <= 0, overflow[altVariationSide] <= 0);\n }\n\n if (checks.every(function (check) {\n return check;\n })) {\n firstFittingPlacement = placement;\n makeFallbackChecks = false;\n break;\n }\n\n checksMap.set(placement, checks);\n }\n\n if (makeFallbackChecks) {\n // `2` may be desired in some cases – research later\n var numberOfChecks = flipVariations ? 3 : 1;\n\n var _loop = function _loop(_i) {\n var fittingPlacement = placements.find(function (placement) {\n var checks = checksMap.get(placement);\n\n if (checks) {\n return checks.slice(0, _i).every(function (check) {\n return check;\n });\n }\n });\n\n if (fittingPlacement) {\n firstFittingPlacement = fittingPlacement;\n return \"break\";\n }\n };\n\n for (var _i = numberOfChecks; _i > 0; _i--) {\n var _ret = _loop(_i);\n\n if (_ret === \"break\") break;\n }\n }\n\n if (state.placement !== firstFittingPlacement) {\n state.modifiersData[name]._skip = true;\n state.placement = firstFittingPlacement;\n state.reset = true;\n }\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'flip',\n enabled: true,\n phase: 'main',\n fn: flip,\n requiresIfExists: ['offset'],\n data: {\n _skip: false\n }\n};","import { top, bottom, left, right } from \"../enums.js\";\nimport detectOverflow from \"../utils/detectOverflow.js\";\n\nfunction getSideOffsets(overflow, rect, preventedOffsets) {\n if (preventedOffsets === void 0) {\n preventedOffsets = {\n x: 0,\n y: 0\n };\n }\n\n return {\n top: overflow.top - rect.height - preventedOffsets.y,\n right: overflow.right - rect.width + preventedOffsets.x,\n bottom: overflow.bottom - rect.height + preventedOffsets.y,\n left: overflow.left - rect.width - preventedOffsets.x\n };\n}\n\nfunction isAnySideFullyClipped(overflow) {\n return [top, right, bottom, left].some(function (side) {\n return overflow[side] >= 0;\n });\n}\n\nfunction hide(_ref) {\n var state = _ref.state,\n name = _ref.name;\n var referenceRect = state.rects.reference;\n var popperRect = state.rects.popper;\n var preventedOffsets = state.modifiersData.preventOverflow;\n var referenceOverflow = detectOverflow(state, {\n elementContext: 'reference'\n });\n var popperAltOverflow = detectOverflow(state, {\n altBoundary: true\n });\n var referenceClippingOffsets = getSideOffsets(referenceOverflow, referenceRect);\n var popperEscapeOffsets = getSideOffsets(popperAltOverflow, popperRect, preventedOffsets);\n var isReferenceHidden = isAnySideFullyClipped(referenceClippingOffsets);\n var hasPopperEscaped = isAnySideFullyClipped(popperEscapeOffsets);\n state.modifiersData[name] = {\n referenceClippingOffsets: referenceClippingOffsets,\n popperEscapeOffsets: popperEscapeOffsets,\n isReferenceHidden: isReferenceHidden,\n hasPopperEscaped: hasPopperEscaped\n };\n state.attributes.popper = Object.assign({}, state.attributes.popper, {\n 'data-popper-reference-hidden': isReferenceHidden,\n 'data-popper-escaped': hasPopperEscaped\n });\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'hide',\n enabled: true,\n phase: 'main',\n requiresIfExists: ['preventOverflow'],\n fn: hide\n};","import getBasePlacement from \"../utils/getBasePlacement.js\";\nimport { top, left, right, placements } from \"../enums.js\"; // eslint-disable-next-line import/no-unused-modules\n\nexport function distanceAndSkiddingToXY(placement, rects, offset) {\n var basePlacement = getBasePlacement(placement);\n var invertDistance = [left, top].indexOf(basePlacement) >= 0 ? -1 : 1;\n\n var _ref = typeof offset === 'function' ? offset(Object.assign({}, rects, {\n placement: placement\n })) : offset,\n skidding = _ref[0],\n distance = _ref[1];\n\n skidding = skidding || 0;\n distance = (distance || 0) * invertDistance;\n return [left, right].indexOf(basePlacement) >= 0 ? {\n x: distance,\n y: skidding\n } : {\n x: skidding,\n y: distance\n };\n}\n\nfunction offset(_ref2) {\n var state = _ref2.state,\n options = _ref2.options,\n name = _ref2.name;\n var _options$offset = options.offset,\n offset = _options$offset === void 0 ? [0, 0] : _options$offset;\n var data = placements.reduce(function (acc, placement) {\n acc[placement] = distanceAndSkiddingToXY(placement, state.rects, offset);\n return acc;\n }, {});\n var _data$state$placement = data[state.placement],\n x = _data$state$placement.x,\n y = _data$state$placement.y;\n\n if (state.modifiersData.popperOffsets != null) {\n state.modifiersData.popperOffsets.x += x;\n state.modifiersData.popperOffsets.y += y;\n }\n\n state.modifiersData[name] = data;\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'offset',\n enabled: true,\n phase: 'main',\n requires: ['popperOffsets'],\n fn: offset\n};","import computeOffsets from \"../utils/computeOffsets.js\";\n\nfunction popperOffsets(_ref) {\n var state = _ref.state,\n name = _ref.name;\n // Offsets are the actual position the popper needs to have to be\n // properly positioned near its reference element\n // This is the most basic placement, and will be adjusted by\n // the modifiers in the next step\n state.modifiersData[name] = computeOffsets({\n reference: state.rects.reference,\n element: state.rects.popper,\n strategy: 'absolute',\n placement: state.placement\n });\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'popperOffsets',\n enabled: true,\n phase: 'read',\n fn: popperOffsets,\n data: {}\n};","export default function getAltAxis(axis) {\n return axis === 'x' ? 'y' : 'x';\n}","import { top, left, right, bottom, start } from \"../enums.js\";\nimport getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getMainAxisFromPlacement from \"../utils/getMainAxisFromPlacement.js\";\nimport getAltAxis from \"../utils/getAltAxis.js\";\nimport { within, withinMaxClamp } from \"../utils/within.js\";\nimport getLayoutRect from \"../dom-utils/getLayoutRect.js\";\nimport getOffsetParent from \"../dom-utils/getOffsetParent.js\";\nimport detectOverflow from \"../utils/detectOverflow.js\";\nimport getVariation from \"../utils/getVariation.js\";\nimport getFreshSideObject from \"../utils/getFreshSideObject.js\";\nimport { min as mathMin, max as mathMax } from \"../utils/math.js\";\n\nfunction preventOverflow(_ref) {\n var state = _ref.state,\n options = _ref.options,\n name = _ref.name;\n var _options$mainAxis = options.mainAxis,\n checkMainAxis = _options$mainAxis === void 0 ? true : _options$mainAxis,\n _options$altAxis = options.altAxis,\n checkAltAxis = _options$altAxis === void 0 ? false : _options$altAxis,\n boundary = options.boundary,\n rootBoundary = options.rootBoundary,\n altBoundary = options.altBoundary,\n padding = options.padding,\n _options$tether = options.tether,\n tether = _options$tether === void 0 ? true : _options$tether,\n _options$tetherOffset = options.tetherOffset,\n tetherOffset = _options$tetherOffset === void 0 ? 0 : _options$tetherOffset;\n var overflow = detectOverflow(state, {\n boundary: boundary,\n rootBoundary: rootBoundary,\n padding: padding,\n altBoundary: altBoundary\n });\n var basePlacement = getBasePlacement(state.placement);\n var variation = getVariation(state.placement);\n var isBasePlacement = !variation;\n var mainAxis = getMainAxisFromPlacement(basePlacement);\n var altAxis = getAltAxis(mainAxis);\n var popperOffsets = state.modifiersData.popperOffsets;\n var referenceRect = state.rects.reference;\n var popperRect = state.rects.popper;\n var tetherOffsetValue = typeof tetherOffset === 'function' ? tetherOffset(Object.assign({}, state.rects, {\n placement: state.placement\n })) : tetherOffset;\n var normalizedTetherOffsetValue = typeof tetherOffsetValue === 'number' ? {\n mainAxis: tetherOffsetValue,\n altAxis: tetherOffsetValue\n } : Object.assign({\n mainAxis: 0,\n altAxis: 0\n }, tetherOffsetValue);\n var offsetModifierState = state.modifiersData.offset ? state.modifiersData.offset[state.placement] : null;\n var data = {\n x: 0,\n y: 0\n };\n\n if (!popperOffsets) {\n return;\n }\n\n if (checkMainAxis) {\n var _offsetModifierState$;\n\n var mainSide = mainAxis === 'y' ? top : left;\n var altSide = mainAxis === 'y' ? bottom : right;\n var len = mainAxis === 'y' ? 'height' : 'width';\n var offset = popperOffsets[mainAxis];\n var min = offset + overflow[mainSide];\n var max = offset - overflow[altSide];\n var additive = tether ? -popperRect[len] / 2 : 0;\n var minLen = variation === start ? referenceRect[len] : popperRect[len];\n var maxLen = variation === start ? -popperRect[len] : -referenceRect[len]; // We need to include the arrow in the calculation so the arrow doesn't go\n // outside the reference bounds\n\n var arrowElement = state.elements.arrow;\n var arrowRect = tether && arrowElement ? getLayoutRect(arrowElement) : {\n width: 0,\n height: 0\n };\n var arrowPaddingObject = state.modifiersData['arrow#persistent'] ? state.modifiersData['arrow#persistent'].padding : getFreshSideObject();\n var arrowPaddingMin = arrowPaddingObject[mainSide];\n var arrowPaddingMax = arrowPaddingObject[altSide]; // If the reference length is smaller than the arrow length, we don't want\n // to include its full size in the calculation. If the reference is small\n // and near the edge of a boundary, the popper can overflow even if the\n // reference is not overflowing as well (e.g. virtual elements with no\n // width or height)\n\n var arrowLen = within(0, referenceRect[len], arrowRect[len]);\n var minOffset = isBasePlacement ? referenceRect[len] / 2 - additive - arrowLen - arrowPaddingMin - normalizedTetherOffsetValue.mainAxis : minLen - arrowLen - arrowPaddingMin - normalizedTetherOffsetValue.mainAxis;\n var maxOffset = isBasePlacement ? -referenceRect[len] / 2 + additive + arrowLen + arrowPaddingMax + normalizedTetherOffsetValue.mainAxis : maxLen + arrowLen + arrowPaddingMax + normalizedTetherOffsetValue.mainAxis;\n var arrowOffsetParent = state.elements.arrow && getOffsetParent(state.elements.arrow);\n var clientOffset = arrowOffsetParent ? mainAxis === 'y' ? arrowOffsetParent.clientTop || 0 : arrowOffsetParent.clientLeft || 0 : 0;\n var offsetModifierValue = (_offsetModifierState$ = offsetModifierState == null ? void 0 : offsetModifierState[mainAxis]) != null ? _offsetModifierState$ : 0;\n var tetherMin = offset + minOffset - offsetModifierValue - clientOffset;\n var tetherMax = offset + maxOffset - offsetModifierValue;\n var preventedOffset = within(tether ? mathMin(min, tetherMin) : min, offset, tether ? mathMax(max, tetherMax) : max);\n popperOffsets[mainAxis] = preventedOffset;\n data[mainAxis] = preventedOffset - offset;\n }\n\n if (checkAltAxis) {\n var _offsetModifierState$2;\n\n var _mainSide = mainAxis === 'x' ? top : left;\n\n var _altSide = mainAxis === 'x' ? bottom : right;\n\n var _offset = popperOffsets[altAxis];\n\n var _len = altAxis === 'y' ? 'height' : 'width';\n\n var _min = _offset + overflow[_mainSide];\n\n var _max = _offset - overflow[_altSide];\n\n var isOriginSide = [top, left].indexOf(basePlacement) !== -1;\n\n var _offsetModifierValue = (_offsetModifierState$2 = offsetModifierState == null ? void 0 : offsetModifierState[altAxis]) != null ? _offsetModifierState$2 : 0;\n\n var _tetherMin = isOriginSide ? _min : _offset - referenceRect[_len] - popperRect[_len] - _offsetModifierValue + normalizedTetherOffsetValue.altAxis;\n\n var _tetherMax = isOriginSide ? _offset + referenceRect[_len] + popperRect[_len] - _offsetModifierValue - normalizedTetherOffsetValue.altAxis : _max;\n\n var _preventedOffset = tether && isOriginSide ? withinMaxClamp(_tetherMin, _offset, _tetherMax) : within(tether ? _tetherMin : _min, _offset, tether ? _tetherMax : _max);\n\n popperOffsets[altAxis] = _preventedOffset;\n data[altAxis] = _preventedOffset - _offset;\n }\n\n state.modifiersData[name] = data;\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'preventOverflow',\n enabled: true,\n phase: 'main',\n fn: preventOverflow,\n requiresIfExists: ['offset']\n};","export default function getHTMLElementScroll(element) {\n return {\n scrollLeft: element.scrollLeft,\n scrollTop: element.scrollTop\n };\n}","import getWindowScroll from \"./getWindowScroll.js\";\nimport getWindow from \"./getWindow.js\";\nimport { isHTMLElement } from \"./instanceOf.js\";\nimport getHTMLElementScroll from \"./getHTMLElementScroll.js\";\nexport default function getNodeScroll(node) {\n if (node === getWindow(node) || !isHTMLElement(node)) {\n return getWindowScroll(node);\n } else {\n return getHTMLElementScroll(node);\n }\n}","import getBoundingClientRect from \"./getBoundingClientRect.js\";\nimport getNodeScroll from \"./getNodeScroll.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport { isHTMLElement } from \"./instanceOf.js\";\nimport getWindowScrollBarX from \"./getWindowScrollBarX.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport isScrollParent from \"./isScrollParent.js\";\nimport { round } from \"../utils/math.js\";\n\nfunction isElementScaled(element) {\n var rect = element.getBoundingClientRect();\n var scaleX = round(rect.width) / element.offsetWidth || 1;\n var scaleY = round(rect.height) / element.offsetHeight || 1;\n return scaleX !== 1 || scaleY !== 1;\n} // Returns the composite rect of an element relative to its offsetParent.\n// Composite means it takes into account transforms as well as layout.\n\n\nexport default function getCompositeRect(elementOrVirtualElement, offsetParent, isFixed) {\n if (isFixed === void 0) {\n isFixed = false;\n }\n\n var isOffsetParentAnElement = isHTMLElement(offsetParent);\n var offsetParentIsScaled = isHTMLElement(offsetParent) && isElementScaled(offsetParent);\n var documentElement = getDocumentElement(offsetParent);\n var rect = getBoundingClientRect(elementOrVirtualElement, offsetParentIsScaled, isFixed);\n var scroll = {\n scrollLeft: 0,\n scrollTop: 0\n };\n var offsets = {\n x: 0,\n y: 0\n };\n\n if (isOffsetParentAnElement || !isOffsetParentAnElement && !isFixed) {\n if (getNodeName(offsetParent) !== 'body' || // https://github.com/popperjs/popper-core/issues/1078\n isScrollParent(documentElement)) {\n scroll = getNodeScroll(offsetParent);\n }\n\n if (isHTMLElement(offsetParent)) {\n offsets = getBoundingClientRect(offsetParent, true);\n offsets.x += offsetParent.clientLeft;\n offsets.y += offsetParent.clientTop;\n } else if (documentElement) {\n offsets.x = getWindowScrollBarX(documentElement);\n }\n }\n\n return {\n x: rect.left + scroll.scrollLeft - offsets.x,\n y: rect.top + scroll.scrollTop - offsets.y,\n width: rect.width,\n height: rect.height\n };\n}","import { modifierPhases } from \"../enums.js\"; // source: https://stackoverflow.com/questions/49875255\n\nfunction order(modifiers) {\n var map = new Map();\n var visited = new Set();\n var result = [];\n modifiers.forEach(function (modifier) {\n map.set(modifier.name, modifier);\n }); // On visiting object, check for its dependencies and visit them recursively\n\n function sort(modifier) {\n visited.add(modifier.name);\n var requires = [].concat(modifier.requires || [], modifier.requiresIfExists || []);\n requires.forEach(function (dep) {\n if (!visited.has(dep)) {\n var depModifier = map.get(dep);\n\n if (depModifier) {\n sort(depModifier);\n }\n }\n });\n result.push(modifier);\n }\n\n modifiers.forEach(function (modifier) {\n if (!visited.has(modifier.name)) {\n // check for visited object\n sort(modifier);\n }\n });\n return result;\n}\n\nexport default function orderModifiers(modifiers) {\n // order based on dependencies\n var orderedModifiers = order(modifiers); // order based on phase\n\n return modifierPhases.reduce(function (acc, phase) {\n return acc.concat(orderedModifiers.filter(function (modifier) {\n return modifier.phase === phase;\n }));\n }, []);\n}","export default function debounce(fn) {\n var pending;\n return function () {\n if (!pending) {\n pending = new Promise(function (resolve) {\n Promise.resolve().then(function () {\n pending = undefined;\n resolve(fn());\n });\n });\n }\n\n return pending;\n };\n}","export default function mergeByName(modifiers) {\n var merged = modifiers.reduce(function (merged, current) {\n var existing = merged[current.name];\n merged[current.name] = existing ? Object.assign({}, existing, current, {\n options: Object.assign({}, existing.options, current.options),\n data: Object.assign({}, existing.data, current.data)\n }) : current;\n return merged;\n }, {}); // IE11 does not support Object.values\n\n return Object.keys(merged).map(function (key) {\n return merged[key];\n });\n}","import getCompositeRect from \"./dom-utils/getCompositeRect.js\";\nimport getLayoutRect from \"./dom-utils/getLayoutRect.js\";\nimport listScrollParents from \"./dom-utils/listScrollParents.js\";\nimport getOffsetParent from \"./dom-utils/getOffsetParent.js\";\nimport orderModifiers from \"./utils/orderModifiers.js\";\nimport debounce from \"./utils/debounce.js\";\nimport mergeByName from \"./utils/mergeByName.js\";\nimport detectOverflow from \"./utils/detectOverflow.js\";\nimport { isElement } from \"./dom-utils/instanceOf.js\";\nvar DEFAULT_OPTIONS = {\n placement: 'bottom',\n modifiers: [],\n strategy: 'absolute'\n};\n\nfunction areValidElements() {\n for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {\n args[_key] = arguments[_key];\n }\n\n return !args.some(function (element) {\n return !(element && typeof element.getBoundingClientRect === 'function');\n });\n}\n\nexport function popperGenerator(generatorOptions) {\n if (generatorOptions === void 0) {\n generatorOptions = {};\n }\n\n var _generatorOptions = generatorOptions,\n _generatorOptions$def = _generatorOptions.defaultModifiers,\n defaultModifiers = _generatorOptions$def === void 0 ? [] : _generatorOptions$def,\n _generatorOptions$def2 = _generatorOptions.defaultOptions,\n defaultOptions = _generatorOptions$def2 === void 0 ? DEFAULT_OPTIONS : _generatorOptions$def2;\n return function createPopper(reference, popper, options) {\n if (options === void 0) {\n options = defaultOptions;\n }\n\n var state = {\n placement: 'bottom',\n orderedModifiers: [],\n options: Object.assign({}, DEFAULT_OPTIONS, defaultOptions),\n modifiersData: {},\n elements: {\n reference: reference,\n popper: popper\n },\n attributes: {},\n styles: {}\n };\n var effectCleanupFns = [];\n var isDestroyed = false;\n var instance = {\n state: state,\n setOptions: function setOptions(setOptionsAction) {\n var options = typeof setOptionsAction === 'function' ? setOptionsAction(state.options) : setOptionsAction;\n cleanupModifierEffects();\n state.options = Object.assign({}, defaultOptions, state.options, options);\n state.scrollParents = {\n reference: isElement(reference) ? listScrollParents(reference) : reference.contextElement ? listScrollParents(reference.contextElement) : [],\n popper: listScrollParents(popper)\n }; // Orders the modifiers based on their dependencies and `phase`\n // properties\n\n var orderedModifiers = orderModifiers(mergeByName([].concat(defaultModifiers, state.options.modifiers))); // Strip out disabled modifiers\n\n state.orderedModifiers = orderedModifiers.filter(function (m) {\n return m.enabled;\n });\n runModifierEffects();\n return instance.update();\n },\n // Sync update – it will always be executed, even if not necessary. This\n // is useful for low frequency updates where sync behavior simplifies the\n // logic.\n // For high frequency updates (e.g. `resize` and `scroll` events), always\n // prefer the async Popper#update method\n forceUpdate: function forceUpdate() {\n if (isDestroyed) {\n return;\n }\n\n var _state$elements = state.elements,\n reference = _state$elements.reference,\n popper = _state$elements.popper; // Don't proceed if `reference` or `popper` are not valid elements\n // anymore\n\n if (!areValidElements(reference, popper)) {\n return;\n } // Store the reference and popper rects to be read by modifiers\n\n\n state.rects = {\n reference: getCompositeRect(reference, getOffsetParent(popper), state.options.strategy === 'fixed'),\n popper: getLayoutRect(popper)\n }; // Modifiers have the ability to reset the current update cycle. The\n // most common use case for this is the `flip` modifier changing the\n // placement, which then needs to re-run all the modifiers, because the\n // logic was previously ran for the previous placement and is therefore\n // stale/incorrect\n\n state.reset = false;\n state.placement = state.options.placement; // On each update cycle, the `modifiersData` property for each modifier\n // is filled with the initial data specified by the modifier. This means\n // it doesn't persist and is fresh on each update.\n // To ensure persistent data, use `${name}#persistent`\n\n state.orderedModifiers.forEach(function (modifier) {\n return state.modifiersData[modifier.name] = Object.assign({}, modifier.data);\n });\n\n for (var index = 0; index < state.orderedModifiers.length; index++) {\n if (state.reset === true) {\n state.reset = false;\n index = -1;\n continue;\n }\n\n var _state$orderedModifie = state.orderedModifiers[index],\n fn = _state$orderedModifie.fn,\n _state$orderedModifie2 = _state$orderedModifie.options,\n _options = _state$orderedModifie2 === void 0 ? {} : _state$orderedModifie2,\n name = _state$orderedModifie.name;\n\n if (typeof fn === 'function') {\n state = fn({\n state: state,\n options: _options,\n name: name,\n instance: instance\n }) || state;\n }\n }\n },\n // Async and optimistically optimized update – it will not be executed if\n // not necessary (debounced to run at most once-per-tick)\n update: debounce(function () {\n return new Promise(function (resolve) {\n instance.forceUpdate();\n resolve(state);\n });\n }),\n destroy: function destroy() {\n cleanupModifierEffects();\n isDestroyed = true;\n }\n };\n\n if (!areValidElements(reference, popper)) {\n return instance;\n }\n\n instance.setOptions(options).then(function (state) {\n if (!isDestroyed && options.onFirstUpdate) {\n options.onFirstUpdate(state);\n }\n }); // Modifiers have the ability to execute arbitrary code before the first\n // update cycle runs. They will be executed in the same order as the update\n // cycle. This is useful when a modifier adds some persistent data that\n // other modifiers need to use, but the modifier is run after the dependent\n // one.\n\n function runModifierEffects() {\n state.orderedModifiers.forEach(function (_ref) {\n var name = _ref.name,\n _ref$options = _ref.options,\n options = _ref$options === void 0 ? {} : _ref$options,\n effect = _ref.effect;\n\n if (typeof effect === 'function') {\n var cleanupFn = effect({\n state: state,\n name: name,\n instance: instance,\n options: options\n });\n\n var noopFn = function noopFn() {};\n\n effectCleanupFns.push(cleanupFn || noopFn);\n }\n });\n }\n\n function cleanupModifierEffects() {\n effectCleanupFns.forEach(function (fn) {\n return fn();\n });\n effectCleanupFns = [];\n }\n\n return instance;\n };\n}\nexport var createPopper = /*#__PURE__*/popperGenerator(); // eslint-disable-next-line import/no-unused-modules\n\nexport { detectOverflow };","import { popperGenerator, detectOverflow } from \"./createPopper.js\";\nimport eventListeners from \"./modifiers/eventListeners.js\";\nimport popperOffsets from \"./modifiers/popperOffsets.js\";\nimport computeStyles from \"./modifiers/computeStyles.js\";\nimport applyStyles from \"./modifiers/applyStyles.js\";\nimport offset from \"./modifiers/offset.js\";\nimport flip from \"./modifiers/flip.js\";\nimport preventOverflow from \"./modifiers/preventOverflow.js\";\nimport arrow from \"./modifiers/arrow.js\";\nimport hide from \"./modifiers/hide.js\";\nvar defaultModifiers = [eventListeners, popperOffsets, computeStyles, applyStyles, offset, flip, preventOverflow, arrow, hide];\nvar createPopper = /*#__PURE__*/popperGenerator({\n defaultModifiers: defaultModifiers\n}); // eslint-disable-next-line import/no-unused-modules\n\nexport { createPopper, popperGenerator, defaultModifiers, detectOverflow }; // eslint-disable-next-line import/no-unused-modules\n\nexport { createPopper as createPopperLite } from \"./popper-lite.js\"; // eslint-disable-next-line import/no-unused-modules\n\nexport * from \"./modifiers/index.js\";","import { generateUtilityClass } from '../generateUtilityClass';\nimport { generateUtilityClasses } from '../generateUtilityClasses';\nconst COMPONENT_NAME = 'Popper';\nexport function getPopperUtilityClass(slot) {\n return generateUtilityClass(COMPONENT_NAME, slot);\n}\nexport const popperClasses = generateUtilityClasses(COMPONENT_NAME, ['root']);","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"anchorEl\", \"children\", \"direction\", \"disablePortal\", \"modifiers\", \"open\", \"placement\", \"popperOptions\", \"popperRef\", \"slotProps\", \"slots\", \"TransitionProps\", \"ownerState\"],\n _excluded2 = [\"anchorEl\", \"children\", \"container\", \"direction\", \"disablePortal\", \"keepMounted\", \"modifiers\", \"open\", \"placement\", \"popperOptions\", \"popperRef\", \"style\", \"transition\", \"slotProps\", \"slots\"];\nimport * as React from 'react';\nimport { chainPropTypes, HTMLElementType, refType, unstable_ownerDocument as ownerDocument, unstable_useEnhancedEffect as useEnhancedEffect, unstable_useForkRef as useForkRef } from '@mui/utils';\nimport { createPopper } from '@popperjs/core';\nimport PropTypes from 'prop-types';\nimport { unstable_composeClasses as composeClasses } from '../composeClasses';\nimport { Portal } from '../Portal';\nimport { getPopperUtilityClass } from './popperClasses';\nimport { useSlotProps } from '../utils';\nimport { useClassNamesOverride } from '../utils/ClassNameConfigurator';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nfunction flipPlacement(placement, direction) {\n if (direction === 'ltr') {\n return placement;\n }\n switch (placement) {\n case 'bottom-end':\n return 'bottom-start';\n case 'bottom-start':\n return 'bottom-end';\n case 'top-end':\n return 'top-start';\n case 'top-start':\n return 'top-end';\n default:\n return placement;\n }\n}\nfunction resolveAnchorEl(anchorEl) {\n return typeof anchorEl === 'function' ? anchorEl() : anchorEl;\n}\nfunction isHTMLElement(element) {\n return element.nodeType !== undefined;\n}\nfunction isVirtualElement(element) {\n return !isHTMLElement(element);\n}\nconst useUtilityClasses = () => {\n const slots = {\n root: ['root']\n };\n return composeClasses(slots, useClassNamesOverride(getPopperUtilityClass));\n};\nconst defaultPopperOptions = {};\nconst PopperTooltip = /*#__PURE__*/React.forwardRef(function PopperTooltip(props, forwardedRef) {\n var _slots$root;\n const {\n anchorEl,\n children,\n direction,\n disablePortal,\n modifiers,\n open,\n placement: initialPlacement,\n popperOptions,\n popperRef: popperRefProp,\n slotProps = {},\n slots = {},\n TransitionProps\n // @ts-ignore internal logic\n // prevent from spreading to DOM, it can come from the parent component e.g. Select.\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const tooltipRef = React.useRef(null);\n const ownRef = useForkRef(tooltipRef, forwardedRef);\n const popperRef = React.useRef(null);\n const handlePopperRef = useForkRef(popperRef, popperRefProp);\n const handlePopperRefRef = React.useRef(handlePopperRef);\n useEnhancedEffect(() => {\n handlePopperRefRef.current = handlePopperRef;\n }, [handlePopperRef]);\n React.useImperativeHandle(popperRefProp, () => popperRef.current, []);\n const rtlPlacement = flipPlacement(initialPlacement, direction);\n /**\n * placement initialized from prop but can change during lifetime if modifiers.flip.\n * modifiers.flip is essentially a flip for controlled/uncontrolled behavior\n */\n const [placement, setPlacement] = React.useState(rtlPlacement);\n const [resolvedAnchorElement, setResolvedAnchorElement] = React.useState(resolveAnchorEl(anchorEl));\n React.useEffect(() => {\n if (popperRef.current) {\n popperRef.current.forceUpdate();\n }\n });\n React.useEffect(() => {\n if (anchorEl) {\n setResolvedAnchorElement(resolveAnchorEl(anchorEl));\n }\n }, [anchorEl]);\n useEnhancedEffect(() => {\n if (!resolvedAnchorElement || !open) {\n return undefined;\n }\n const handlePopperUpdate = data => {\n setPlacement(data.placement);\n };\n if (process.env.NODE_ENV !== 'production') {\n if (resolvedAnchorElement && isHTMLElement(resolvedAnchorElement) && resolvedAnchorElement.nodeType === 1) {\n const box = resolvedAnchorElement.getBoundingClientRect();\n if (process.env.NODE_ENV !== 'test' && box.top === 0 && box.left === 0 && box.right === 0 && box.bottom === 0) {\n console.warn(['MUI: The `anchorEl` prop provided to the component is invalid.', 'The anchor element should be part of the document layout.', \"Make sure the element is present in the document or that it's not display none.\"].join('\\n'));\n }\n }\n }\n let popperModifiers = [{\n name: 'preventOverflow',\n options: {\n altBoundary: disablePortal\n }\n }, {\n name: 'flip',\n options: {\n altBoundary: disablePortal\n }\n }, {\n name: 'onUpdate',\n enabled: true,\n phase: 'afterWrite',\n fn: ({\n state\n }) => {\n handlePopperUpdate(state);\n }\n }];\n if (modifiers != null) {\n popperModifiers = popperModifiers.concat(modifiers);\n }\n if (popperOptions && popperOptions.modifiers != null) {\n popperModifiers = popperModifiers.concat(popperOptions.modifiers);\n }\n const popper = createPopper(resolvedAnchorElement, tooltipRef.current, _extends({\n placement: rtlPlacement\n }, popperOptions, {\n modifiers: popperModifiers\n }));\n handlePopperRefRef.current(popper);\n return () => {\n popper.destroy();\n handlePopperRefRef.current(null);\n };\n }, [resolvedAnchorElement, disablePortal, modifiers, open, popperOptions, rtlPlacement]);\n const childProps = {\n placement: placement\n };\n if (TransitionProps !== null) {\n childProps.TransitionProps = TransitionProps;\n }\n const classes = useUtilityClasses();\n const Root = (_slots$root = slots.root) != null ? _slots$root : 'div';\n const rootProps = useSlotProps({\n elementType: Root,\n externalSlotProps: slotProps.root,\n externalForwardedProps: other,\n additionalProps: {\n role: 'tooltip',\n ref: ownRef\n },\n ownerState: props,\n className: classes.root\n });\n return /*#__PURE__*/_jsx(Root, _extends({}, rootProps, {\n children: typeof children === 'function' ? children(childProps) : children\n }));\n});\n\n/**\n * Poppers rely on the 3rd party library [Popper.js](https://popper.js.org/docs/v2/) for positioning.\n *\n * Demos:\n *\n * - [Popper](https://mui.com/base-ui/react-popper/)\n *\n * API:\n *\n * - [Popper API](https://mui.com/base-ui/react-popper/components-api/#popper)\n */\nconst Popper = /*#__PURE__*/React.forwardRef(function Popper(props, forwardedRef) {\n const {\n anchorEl,\n children,\n container: containerProp,\n direction = 'ltr',\n disablePortal = false,\n keepMounted = false,\n modifiers,\n open,\n placement = 'bottom',\n popperOptions = defaultPopperOptions,\n popperRef,\n style,\n transition = false,\n slotProps = {},\n slots = {}\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded2);\n const [exited, setExited] = React.useState(true);\n const handleEnter = () => {\n setExited(false);\n };\n const handleExited = () => {\n setExited(true);\n };\n if (!keepMounted && !open && (!transition || exited)) {\n return null;\n }\n\n // If the container prop is provided, use that\n // If the anchorEl prop is provided, use its parent body element as the container\n // If neither are provided let the Modal take care of choosing the container\n let container;\n if (containerProp) {\n container = containerProp;\n } else if (anchorEl) {\n const resolvedAnchorEl = resolveAnchorEl(anchorEl);\n container = resolvedAnchorEl && isHTMLElement(resolvedAnchorEl) ? ownerDocument(resolvedAnchorEl).body : ownerDocument(null).body;\n }\n const display = !open && keepMounted && (!transition || exited) ? 'none' : undefined;\n const transitionProps = transition ? {\n in: open,\n onEnter: handleEnter,\n onExited: handleExited\n } : undefined;\n return /*#__PURE__*/_jsx(Portal, {\n disablePortal: disablePortal,\n container: container,\n children: /*#__PURE__*/_jsx(PopperTooltip, _extends({\n anchorEl: anchorEl,\n direction: direction,\n disablePortal: disablePortal,\n modifiers: modifiers,\n ref: forwardedRef,\n open: transition ? !exited : open,\n placement: placement,\n popperOptions: popperOptions,\n popperRef: popperRef,\n slotProps: slotProps,\n slots: slots\n }, other, {\n style: _extends({\n // Prevents scroll issue, waiting for Popper.js to add this style once initiated.\n position: 'fixed',\n // Fix Popper.js display issue\n top: 0,\n left: 0,\n display\n }, style),\n TransitionProps: transitionProps,\n children: children\n }))\n });\n});\nprocess.env.NODE_ENV !== \"production\" ? Popper.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * An HTML element, [virtualElement](https://popper.js.org/docs/v2/virtual-elements/),\n * or a function that returns either.\n * It's used to set the position of the popper.\n * The return value will passed as the reference object of the Popper instance.\n */\n anchorEl: chainPropTypes(PropTypes.oneOfType([HTMLElementType, PropTypes.object, PropTypes.func]), props => {\n if (props.open) {\n const resolvedAnchorEl = resolveAnchorEl(props.anchorEl);\n if (resolvedAnchorEl && isHTMLElement(resolvedAnchorEl) && resolvedAnchorEl.nodeType === 1) {\n const box = resolvedAnchorEl.getBoundingClientRect();\n if (process.env.NODE_ENV !== 'test' && box.top === 0 && box.left === 0 && box.right === 0 && box.bottom === 0) {\n return new Error(['MUI: The `anchorEl` prop provided to the component is invalid.', 'The anchor element should be part of the document layout.', \"Make sure the element is present in the document or that it's not display none.\"].join('\\n'));\n }\n } else if (!resolvedAnchorEl || typeof resolvedAnchorEl.getBoundingClientRect !== 'function' || isVirtualElement(resolvedAnchorEl) && resolvedAnchorEl.contextElement != null && resolvedAnchorEl.contextElement.nodeType !== 1) {\n return new Error(['MUI: The `anchorEl` prop provided to the component is invalid.', 'It should be an HTML element instance or a virtualElement ', '(https://popper.js.org/docs/v2/virtual-elements/).'].join('\\n'));\n }\n }\n return null;\n }),\n /**\n * Popper render function or node.\n */\n children: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.node, PropTypes.func]),\n /**\n * An HTML element or function that returns one.\n * The `container` will have the portal children appended to it.\n *\n * You can also provide a callback, which is called in a React layout effect.\n * This lets you set the container from a ref, and also makes server-side rendering possible.\n *\n * By default, it uses the body of the top-level document object,\n * so it's simply `document.body` most of the time.\n */\n container: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.func]),\n /**\n * Direction of the text.\n * @default 'ltr'\n */\n direction: PropTypes.oneOf(['ltr', 'rtl']),\n /**\n * The `children` will be under the DOM hierarchy of the parent component.\n * @default false\n */\n disablePortal: PropTypes.bool,\n /**\n * Always keep the children in the DOM.\n * This prop can be useful in SEO situation or\n * when you want to maximize the responsiveness of the Popper.\n * @default false\n */\n keepMounted: PropTypes.bool,\n /**\n * Popper.js is based on a \"plugin-like\" architecture,\n * most of its features are fully encapsulated \"modifiers\".\n *\n * A modifier is a function that is called each time Popper.js needs to\n * compute the position of the popper.\n * For this reason, modifiers should be very performant to avoid bottlenecks.\n * To learn how to create a modifier, [read the modifiers documentation](https://popper.js.org/docs/v2/modifiers/).\n */\n modifiers: PropTypes.arrayOf(PropTypes.shape({\n data: PropTypes.object,\n effect: PropTypes.func,\n enabled: PropTypes.bool,\n fn: PropTypes.func,\n name: PropTypes.any,\n options: PropTypes.object,\n phase: PropTypes.oneOf(['afterMain', 'afterRead', 'afterWrite', 'beforeMain', 'beforeRead', 'beforeWrite', 'main', 'read', 'write']),\n requires: PropTypes.arrayOf(PropTypes.string),\n requiresIfExists: PropTypes.arrayOf(PropTypes.string)\n })),\n /**\n * If `true`, the component is shown.\n */\n open: PropTypes.bool.isRequired,\n /**\n * Popper placement.\n * @default 'bottom'\n */\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n /**\n * Options provided to the [`Popper.js`](https://popper.js.org/docs/v2/constructors/#options) instance.\n * @default {}\n */\n popperOptions: PropTypes.shape({\n modifiers: PropTypes.array,\n onFirstUpdate: PropTypes.func,\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n strategy: PropTypes.oneOf(['absolute', 'fixed'])\n }),\n /**\n * A ref that points to the used popper instance.\n */\n popperRef: refType,\n /**\n * The props used for each slot inside the Popper.\n * @default {}\n */\n slotProps: PropTypes.shape({\n root: PropTypes.oneOfType([PropTypes.func, PropTypes.object])\n }),\n /**\n * The components used for each slot inside the Popper.\n * Either a string to use a HTML element or a component.\n * @default {}\n */\n slots: PropTypes.shape({\n root: PropTypes.elementType\n }),\n /**\n * Help supporting a react-transition-group/Transition component.\n * @default false\n */\n transition: PropTypes.bool\n} : void 0;\nexport { Popper };","'use client';\n\nimport * as React from 'react';\nimport { useTheme as useThemeSystem } from '@mui/system';\nimport defaultTheme from './defaultTheme';\nimport THEME_ID from './identifier';\nexport default function useTheme() {\n const theme = useThemeSystem(defaultTheme);\n if (process.env.NODE_ENV !== 'production') {\n // eslint-disable-next-line react-hooks/rules-of-hooks\n React.useDebugValue(theme);\n }\n return theme[THEME_ID] || theme;\n}","export default function _setPrototypeOf(o, p) {\n _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function _setPrototypeOf(o, p) {\n o.__proto__ = p;\n return o;\n };\n return _setPrototypeOf(o, p);\n}","import setPrototypeOf from \"./setPrototypeOf.js\";\nexport default function _inheritsLoose(subClass, superClass) {\n subClass.prototype = Object.create(superClass.prototype);\n subClass.prototype.constructor = subClass;\n setPrototypeOf(subClass, superClass);\n}","export default {\n disabled: false\n};","import PropTypes from 'prop-types';\nexport var timeoutsShape = process.env.NODE_ENV !== 'production' ? PropTypes.oneOfType([PropTypes.number, PropTypes.shape({\n enter: PropTypes.number,\n exit: PropTypes.number,\n appear: PropTypes.number\n}).isRequired]) : null;\nexport var classNamesShape = process.env.NODE_ENV !== 'production' ? PropTypes.oneOfType([PropTypes.string, PropTypes.shape({\n enter: PropTypes.string,\n exit: PropTypes.string,\n active: PropTypes.string\n}), PropTypes.shape({\n enter: PropTypes.string,\n enterDone: PropTypes.string,\n enterActive: PropTypes.string,\n exit: PropTypes.string,\n exitDone: PropTypes.string,\n exitActive: PropTypes.string\n})]) : null;","import React from 'react';\nexport default React.createContext(null);","export var forceReflow = function forceReflow(node) {\n return node.scrollTop;\n};","import _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _inheritsLoose from \"@babel/runtime/helpers/esm/inheritsLoose\";\nimport PropTypes from 'prop-types';\nimport React from 'react';\nimport ReactDOM from 'react-dom';\nimport config from './config';\nimport { timeoutsShape } from './utils/PropTypes';\nimport TransitionGroupContext from './TransitionGroupContext';\nimport { forceReflow } from './utils/reflow';\nexport var UNMOUNTED = 'unmounted';\nexport var EXITED = 'exited';\nexport var ENTERING = 'entering';\nexport var ENTERED = 'entered';\nexport var EXITING = 'exiting';\n/**\n * The Transition component lets you describe a transition from one component\n * state to another _over time_ with a simple declarative API. Most commonly\n * it's used to animate the mounting and unmounting of a component, but can also\n * be used to describe in-place transition states as well.\n *\n * ---\n *\n * **Note**: `Transition` is a platform-agnostic base component. If you're using\n * transitions in CSS, you'll probably want to use\n * [`CSSTransition`](https://reactcommunity.org/react-transition-group/css-transition)\n * instead. It inherits all the features of `Transition`, but contains\n * additional features necessary to play nice with CSS transitions (hence the\n * name of the component).\n *\n * ---\n *\n * By default the `Transition` component does not alter the behavior of the\n * component it renders, it only tracks \"enter\" and \"exit\" states for the\n * components. It's up to you to give meaning and effect to those states. For\n * example we can add styles to a component when it enters or exits:\n *\n * ```jsx\n * import { Transition } from 'react-transition-group';\n *\n * const duration = 300;\n *\n * const defaultStyle = {\n * transition: `opacity ${duration}ms ease-in-out`,\n * opacity: 0,\n * }\n *\n * const transitionStyles = {\n * entering: { opacity: 1 },\n * entered: { opacity: 1 },\n * exiting: { opacity: 0 },\n * exited: { opacity: 0 },\n * };\n *\n * const Fade = ({ in: inProp }) => (\n * \n * {state => (\n *
\n * I'm a fade Transition!\n *
\n * )}\n *
\n * );\n * ```\n *\n * There are 4 main states a Transition can be in:\n * - `'entering'`\n * - `'entered'`\n * - `'exiting'`\n * - `'exited'`\n *\n * Transition state is toggled via the `in` prop. When `true` the component\n * begins the \"Enter\" stage. During this stage, the component will shift from\n * its current transition state, to `'entering'` for the duration of the\n * transition and then to the `'entered'` stage once it's complete. Let's take\n * the following example (we'll use the\n * [useState](https://reactjs.org/docs/hooks-reference.html#usestate) hook):\n *\n * ```jsx\n * function App() {\n * const [inProp, setInProp] = useState(false);\n * return (\n *
\n * \n * {state => (\n * // ...\n * )}\n * \n * \n *
\n * );\n * }\n * ```\n *\n * When the button is clicked the component will shift to the `'entering'` state\n * and stay there for 500ms (the value of `timeout`) before it finally switches\n * to `'entered'`.\n *\n * When `in` is `false` the same thing happens except the state moves from\n * `'exiting'` to `'exited'`.\n */\n\nvar Transition = /*#__PURE__*/function (_React$Component) {\n _inheritsLoose(Transition, _React$Component);\n\n function Transition(props, context) {\n var _this;\n\n _this = _React$Component.call(this, props, context) || this;\n var parentGroup = context; // In the context of a TransitionGroup all enters are really appears\n\n var appear = parentGroup && !parentGroup.isMounting ? props.enter : props.appear;\n var initialStatus;\n _this.appearStatus = null;\n\n if (props.in) {\n if (appear) {\n initialStatus = EXITED;\n _this.appearStatus = ENTERING;\n } else {\n initialStatus = ENTERED;\n }\n } else {\n if (props.unmountOnExit || props.mountOnEnter) {\n initialStatus = UNMOUNTED;\n } else {\n initialStatus = EXITED;\n }\n }\n\n _this.state = {\n status: initialStatus\n };\n _this.nextCallback = null;\n return _this;\n }\n\n Transition.getDerivedStateFromProps = function getDerivedStateFromProps(_ref, prevState) {\n var nextIn = _ref.in;\n\n if (nextIn && prevState.status === UNMOUNTED) {\n return {\n status: EXITED\n };\n }\n\n return null;\n } // getSnapshotBeforeUpdate(prevProps) {\n // let nextStatus = null\n // if (prevProps !== this.props) {\n // const { status } = this.state\n // if (this.props.in) {\n // if (status !== ENTERING && status !== ENTERED) {\n // nextStatus = ENTERING\n // }\n // } else {\n // if (status === ENTERING || status === ENTERED) {\n // nextStatus = EXITING\n // }\n // }\n // }\n // return { nextStatus }\n // }\n ;\n\n var _proto = Transition.prototype;\n\n _proto.componentDidMount = function componentDidMount() {\n this.updateStatus(true, this.appearStatus);\n };\n\n _proto.componentDidUpdate = function componentDidUpdate(prevProps) {\n var nextStatus = null;\n\n if (prevProps !== this.props) {\n var status = this.state.status;\n\n if (this.props.in) {\n if (status !== ENTERING && status !== ENTERED) {\n nextStatus = ENTERING;\n }\n } else {\n if (status === ENTERING || status === ENTERED) {\n nextStatus = EXITING;\n }\n }\n }\n\n this.updateStatus(false, nextStatus);\n };\n\n _proto.componentWillUnmount = function componentWillUnmount() {\n this.cancelNextCallback();\n };\n\n _proto.getTimeouts = function getTimeouts() {\n var timeout = this.props.timeout;\n var exit, enter, appear;\n exit = enter = appear = timeout;\n\n if (timeout != null && typeof timeout !== 'number') {\n exit = timeout.exit;\n enter = timeout.enter; // TODO: remove fallback for next major\n\n appear = timeout.appear !== undefined ? timeout.appear : enter;\n }\n\n return {\n exit: exit,\n enter: enter,\n appear: appear\n };\n };\n\n _proto.updateStatus = function updateStatus(mounting, nextStatus) {\n if (mounting === void 0) {\n mounting = false;\n }\n\n if (nextStatus !== null) {\n // nextStatus will always be ENTERING or EXITING.\n this.cancelNextCallback();\n\n if (nextStatus === ENTERING) {\n if (this.props.unmountOnExit || this.props.mountOnEnter) {\n var node = this.props.nodeRef ? this.props.nodeRef.current : ReactDOM.findDOMNode(this); // https://github.com/reactjs/react-transition-group/pull/749\n // With unmountOnExit or mountOnEnter, the enter animation should happen at the transition between `exited` and `entering`.\n // To make the animation happen, we have to separate each rendering and avoid being processed as batched.\n\n if (node) forceReflow(node);\n }\n\n this.performEnter(mounting);\n } else {\n this.performExit();\n }\n } else if (this.props.unmountOnExit && this.state.status === EXITED) {\n this.setState({\n status: UNMOUNTED\n });\n }\n };\n\n _proto.performEnter = function performEnter(mounting) {\n var _this2 = this;\n\n var enter = this.props.enter;\n var appearing = this.context ? this.context.isMounting : mounting;\n\n var _ref2 = this.props.nodeRef ? [appearing] : [ReactDOM.findDOMNode(this), appearing],\n maybeNode = _ref2[0],\n maybeAppearing = _ref2[1];\n\n var timeouts = this.getTimeouts();\n var enterTimeout = appearing ? timeouts.appear : timeouts.enter; // no enter animation skip right to ENTERED\n // if we are mounting and running this it means appear _must_ be set\n\n if (!mounting && !enter || config.disabled) {\n this.safeSetState({\n status: ENTERED\n }, function () {\n _this2.props.onEntered(maybeNode);\n });\n return;\n }\n\n this.props.onEnter(maybeNode, maybeAppearing);\n this.safeSetState({\n status: ENTERING\n }, function () {\n _this2.props.onEntering(maybeNode, maybeAppearing);\n\n _this2.onTransitionEnd(enterTimeout, function () {\n _this2.safeSetState({\n status: ENTERED\n }, function () {\n _this2.props.onEntered(maybeNode, maybeAppearing);\n });\n });\n });\n };\n\n _proto.performExit = function performExit() {\n var _this3 = this;\n\n var exit = this.props.exit;\n var timeouts = this.getTimeouts();\n var maybeNode = this.props.nodeRef ? undefined : ReactDOM.findDOMNode(this); // no exit animation skip right to EXITED\n\n if (!exit || config.disabled) {\n this.safeSetState({\n status: EXITED\n }, function () {\n _this3.props.onExited(maybeNode);\n });\n return;\n }\n\n this.props.onExit(maybeNode);\n this.safeSetState({\n status: EXITING\n }, function () {\n _this3.props.onExiting(maybeNode);\n\n _this3.onTransitionEnd(timeouts.exit, function () {\n _this3.safeSetState({\n status: EXITED\n }, function () {\n _this3.props.onExited(maybeNode);\n });\n });\n });\n };\n\n _proto.cancelNextCallback = function cancelNextCallback() {\n if (this.nextCallback !== null) {\n this.nextCallback.cancel();\n this.nextCallback = null;\n }\n };\n\n _proto.safeSetState = function safeSetState(nextState, callback) {\n // This shouldn't be necessary, but there are weird race conditions with\n // setState callbacks and unmounting in testing, so always make sure that\n // we can cancel any pending setState callbacks after we unmount.\n callback = this.setNextCallback(callback);\n this.setState(nextState, callback);\n };\n\n _proto.setNextCallback = function setNextCallback(callback) {\n var _this4 = this;\n\n var active = true;\n\n this.nextCallback = function (event) {\n if (active) {\n active = false;\n _this4.nextCallback = null;\n callback(event);\n }\n };\n\n this.nextCallback.cancel = function () {\n active = false;\n };\n\n return this.nextCallback;\n };\n\n _proto.onTransitionEnd = function onTransitionEnd(timeout, handler) {\n this.setNextCallback(handler);\n var node = this.props.nodeRef ? this.props.nodeRef.current : ReactDOM.findDOMNode(this);\n var doesNotHaveTimeoutOrListener = timeout == null && !this.props.addEndListener;\n\n if (!node || doesNotHaveTimeoutOrListener) {\n setTimeout(this.nextCallback, 0);\n return;\n }\n\n if (this.props.addEndListener) {\n var _ref3 = this.props.nodeRef ? [this.nextCallback] : [node, this.nextCallback],\n maybeNode = _ref3[0],\n maybeNextCallback = _ref3[1];\n\n this.props.addEndListener(maybeNode, maybeNextCallback);\n }\n\n if (timeout != null) {\n setTimeout(this.nextCallback, timeout);\n }\n };\n\n _proto.render = function render() {\n var status = this.state.status;\n\n if (status === UNMOUNTED) {\n return null;\n }\n\n var _this$props = this.props,\n children = _this$props.children,\n _in = _this$props.in,\n _mountOnEnter = _this$props.mountOnEnter,\n _unmountOnExit = _this$props.unmountOnExit,\n _appear = _this$props.appear,\n _enter = _this$props.enter,\n _exit = _this$props.exit,\n _timeout = _this$props.timeout,\n _addEndListener = _this$props.addEndListener,\n _onEnter = _this$props.onEnter,\n _onEntering = _this$props.onEntering,\n _onEntered = _this$props.onEntered,\n _onExit = _this$props.onExit,\n _onExiting = _this$props.onExiting,\n _onExited = _this$props.onExited,\n _nodeRef = _this$props.nodeRef,\n childProps = _objectWithoutPropertiesLoose(_this$props, [\"children\", \"in\", \"mountOnEnter\", \"unmountOnExit\", \"appear\", \"enter\", \"exit\", \"timeout\", \"addEndListener\", \"onEnter\", \"onEntering\", \"onEntered\", \"onExit\", \"onExiting\", \"onExited\", \"nodeRef\"]);\n\n return (\n /*#__PURE__*/\n // allows for nested Transitions\n React.createElement(TransitionGroupContext.Provider, {\n value: null\n }, typeof children === 'function' ? children(status, childProps) : React.cloneElement(React.Children.only(children), childProps))\n );\n };\n\n return Transition;\n}(React.Component);\n\nTransition.contextType = TransitionGroupContext;\nTransition.propTypes = process.env.NODE_ENV !== \"production\" ? {\n /**\n * A React reference to DOM element that need to transition:\n * https://stackoverflow.com/a/51127130/4671932\n *\n * - When `nodeRef` prop is used, `node` is not passed to callback functions\n * (e.g. `onEnter`) because user already has direct access to the node.\n * - When changing `key` prop of `Transition` in a `TransitionGroup` a new\n * `nodeRef` need to be provided to `Transition` with changed `key` prop\n * (see\n * [test/CSSTransition-test.js](https://github.com/reactjs/react-transition-group/blob/13435f897b3ab71f6e19d724f145596f5910581c/test/CSSTransition-test.js#L362-L437)).\n */\n nodeRef: PropTypes.shape({\n current: typeof Element === 'undefined' ? PropTypes.any : function (propValue, key, componentName, location, propFullName, secret) {\n var value = propValue[key];\n return PropTypes.instanceOf(value && 'ownerDocument' in value ? value.ownerDocument.defaultView.Element : Element)(propValue, key, componentName, location, propFullName, secret);\n }\n }),\n\n /**\n * A `function` child can be used instead of a React element. This function is\n * called with the current transition status (`'entering'`, `'entered'`,\n * `'exiting'`, `'exited'`), which can be used to apply context\n * specific props to a component.\n *\n * ```jsx\n * \n * {state => (\n * \n * )}\n * \n * ```\n */\n children: PropTypes.oneOfType([PropTypes.func.isRequired, PropTypes.element.isRequired]).isRequired,\n\n /**\n * Show the component; triggers the enter or exit states\n */\n in: PropTypes.bool,\n\n /**\n * By default the child component is mounted immediately along with\n * the parent `Transition` component. If you want to \"lazy mount\" the component on the\n * first `in={true}` you can set `mountOnEnter`. After the first enter transition the component will stay\n * mounted, even on \"exited\", unless you also specify `unmountOnExit`.\n */\n mountOnEnter: PropTypes.bool,\n\n /**\n * By default the child component stays mounted after it reaches the `'exited'` state.\n * Set `unmountOnExit` if you'd prefer to unmount the component after it finishes exiting.\n */\n unmountOnExit: PropTypes.bool,\n\n /**\n * By default the child component does not perform the enter transition when\n * it first mounts, regardless of the value of `in`. If you want this\n * behavior, set both `appear` and `in` to `true`.\n *\n * > **Note**: there are no special appear states like `appearing`/`appeared`, this prop\n * > only adds an additional enter transition. However, in the\n * > `` component that first enter transition does result in\n * > additional `.appear-*` classes, that way you can choose to style it\n * > differently.\n */\n appear: PropTypes.bool,\n\n /**\n * Enable or disable enter transitions.\n */\n enter: PropTypes.bool,\n\n /**\n * Enable or disable exit transitions.\n */\n exit: PropTypes.bool,\n\n /**\n * The duration of the transition, in milliseconds.\n * Required unless `addEndListener` is provided.\n *\n * You may specify a single timeout for all transitions:\n *\n * ```jsx\n * timeout={500}\n * ```\n *\n * or individually:\n *\n * ```jsx\n * timeout={{\n * appear: 500,\n * enter: 300,\n * exit: 500,\n * }}\n * ```\n *\n * - `appear` defaults to the value of `enter`\n * - `enter` defaults to `0`\n * - `exit` defaults to `0`\n *\n * @type {number | { enter?: number, exit?: number, appear?: number }}\n */\n timeout: function timeout(props) {\n var pt = timeoutsShape;\n if (!props.addEndListener) pt = pt.isRequired;\n\n for (var _len = arguments.length, args = new Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) {\n args[_key - 1] = arguments[_key];\n }\n\n return pt.apply(void 0, [props].concat(args));\n },\n\n /**\n * Add a custom transition end trigger. Called with the transitioning\n * DOM node and a `done` callback. Allows for more fine grained transition end\n * logic. Timeouts are still used as a fallback if provided.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * ```jsx\n * addEndListener={(node, done) => {\n * // use the css transitionend event to mark the finish of a transition\n * node.addEventListener('transitionend', done, false);\n * }}\n * ```\n */\n addEndListener: PropTypes.func,\n\n /**\n * Callback fired before the \"entering\" status is applied. An extra parameter\n * `isAppearing` is supplied to indicate if the enter stage is occurring on the initial mount\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement, isAppearing: bool) -> void\n */\n onEnter: PropTypes.func,\n\n /**\n * Callback fired after the \"entering\" status is applied. An extra parameter\n * `isAppearing` is supplied to indicate if the enter stage is occurring on the initial mount\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement, isAppearing: bool)\n */\n onEntering: PropTypes.func,\n\n /**\n * Callback fired after the \"entered\" status is applied. An extra parameter\n * `isAppearing` is supplied to indicate if the enter stage is occurring on the initial mount\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement, isAppearing: bool) -> void\n */\n onEntered: PropTypes.func,\n\n /**\n * Callback fired before the \"exiting\" status is applied.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement) -> void\n */\n onExit: PropTypes.func,\n\n /**\n * Callback fired after the \"exiting\" status is applied.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement) -> void\n */\n onExiting: PropTypes.func,\n\n /**\n * Callback fired after the \"exited\" status is applied.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed\n *\n * @type Function(node: HtmlElement) -> void\n */\n onExited: PropTypes.func\n} : {}; // Name the function so it is clearer in the documentation\n\nfunction noop() {}\n\nTransition.defaultProps = {\n in: false,\n mountOnEnter: false,\n unmountOnExit: false,\n appear: false,\n enter: true,\n exit: true,\n onEnter: noop,\n onEntering: noop,\n onEntered: noop,\n onExit: noop,\n onExiting: noop,\n onExited: noop\n};\nTransition.UNMOUNTED = UNMOUNTED;\nTransition.EXITED = EXITED;\nTransition.ENTERING = ENTERING;\nTransition.ENTERED = ENTERED;\nTransition.EXITING = EXITING;\nexport default Transition;","export const reflow = node => node.scrollTop;\nexport function getTransitionProps(props, options) {\n var _style$transitionDura, _style$transitionTimi;\n const {\n timeout,\n easing,\n style = {}\n } = props;\n return {\n duration: (_style$transitionDura = style.transitionDuration) != null ? _style$transitionDura : typeof timeout === 'number' ? timeout : timeout[options.mode] || 0,\n easing: (_style$transitionTimi = style.transitionTimingFunction) != null ? _style$transitionTimi : typeof easing === 'object' ? easing[options.mode] : easing,\n delay: style.transitionDelay\n };\n}","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"addEndListener\", \"appear\", \"children\", \"easing\", \"in\", \"onEnter\", \"onEntered\", \"onEntering\", \"onExit\", \"onExited\", \"onExiting\", \"style\", \"timeout\", \"TransitionComponent\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport { elementAcceptingRef, unstable_useTimeout as useTimeout } from '@mui/utils';\nimport { Transition } from 'react-transition-group';\nimport useTheme from '../styles/useTheme';\nimport { getTransitionProps, reflow } from '../transitions/utils';\nimport useForkRef from '../utils/useForkRef';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nfunction getScale(value) {\n return `scale(${value}, ${value ** 2})`;\n}\nconst styles = {\n entering: {\n opacity: 1,\n transform: getScale(1)\n },\n entered: {\n opacity: 1,\n transform: 'none'\n }\n};\n\n/*\n TODO v6: remove\n Conditionally apply a workaround for the CSS transition bug in Safari 15.4 / WebKit browsers.\n */\nconst isWebKit154 = typeof navigator !== 'undefined' && /^((?!chrome|android).)*(safari|mobile)/i.test(navigator.userAgent) && /(os |version\\/)15(.|_)4/i.test(navigator.userAgent);\n\n/**\n * The Grow transition is used by the [Tooltip](/material-ui/react-tooltip/) and\n * [Popover](/material-ui/react-popover/) components.\n * It uses [react-transition-group](https://github.com/reactjs/react-transition-group) internally.\n */\nconst Grow = /*#__PURE__*/React.forwardRef(function Grow(props, ref) {\n const {\n addEndListener,\n appear = true,\n children,\n easing,\n in: inProp,\n onEnter,\n onEntered,\n onEntering,\n onExit,\n onExited,\n onExiting,\n style,\n timeout = 'auto',\n // eslint-disable-next-line react/prop-types\n TransitionComponent = Transition\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const timer = useTimeout();\n const autoTimeout = React.useRef();\n const theme = useTheme();\n const nodeRef = React.useRef(null);\n const handleRef = useForkRef(nodeRef, children.ref, ref);\n const normalizedTransitionCallback = callback => maybeIsAppearing => {\n if (callback) {\n const node = nodeRef.current;\n\n // onEnterXxx and onExitXxx callbacks have a different arguments.length value.\n if (maybeIsAppearing === undefined) {\n callback(node);\n } else {\n callback(node, maybeIsAppearing);\n }\n }\n };\n const handleEntering = normalizedTransitionCallback(onEntering);\n const handleEnter = normalizedTransitionCallback((node, isAppearing) => {\n reflow(node); // So the animation always start from the start.\n\n const {\n duration: transitionDuration,\n delay,\n easing: transitionTimingFunction\n } = getTransitionProps({\n style,\n timeout,\n easing\n }, {\n mode: 'enter'\n });\n let duration;\n if (timeout === 'auto') {\n duration = theme.transitions.getAutoHeightDuration(node.clientHeight);\n autoTimeout.current = duration;\n } else {\n duration = transitionDuration;\n }\n node.style.transition = [theme.transitions.create('opacity', {\n duration,\n delay\n }), theme.transitions.create('transform', {\n duration: isWebKit154 ? duration : duration * 0.666,\n delay,\n easing: transitionTimingFunction\n })].join(',');\n if (onEnter) {\n onEnter(node, isAppearing);\n }\n });\n const handleEntered = normalizedTransitionCallback(onEntered);\n const handleExiting = normalizedTransitionCallback(onExiting);\n const handleExit = normalizedTransitionCallback(node => {\n const {\n duration: transitionDuration,\n delay,\n easing: transitionTimingFunction\n } = getTransitionProps({\n style,\n timeout,\n easing\n }, {\n mode: 'exit'\n });\n let duration;\n if (timeout === 'auto') {\n duration = theme.transitions.getAutoHeightDuration(node.clientHeight);\n autoTimeout.current = duration;\n } else {\n duration = transitionDuration;\n }\n node.style.transition = [theme.transitions.create('opacity', {\n duration,\n delay\n }), theme.transitions.create('transform', {\n duration: isWebKit154 ? duration : duration * 0.666,\n delay: isWebKit154 ? delay : delay || duration * 0.333,\n easing: transitionTimingFunction\n })].join(',');\n node.style.opacity = 0;\n node.style.transform = getScale(0.75);\n if (onExit) {\n onExit(node);\n }\n });\n const handleExited = normalizedTransitionCallback(onExited);\n const handleAddEndListener = next => {\n if (timeout === 'auto') {\n timer.start(autoTimeout.current || 0, next);\n }\n if (addEndListener) {\n // Old call signature before `react-transition-group` implemented `nodeRef`\n addEndListener(nodeRef.current, next);\n }\n };\n return /*#__PURE__*/_jsx(TransitionComponent, _extends({\n appear: appear,\n in: inProp,\n nodeRef: nodeRef,\n onEnter: handleEnter,\n onEntered: handleEntered,\n onEntering: handleEntering,\n onExit: handleExit,\n onExited: handleExited,\n onExiting: handleExiting,\n addEndListener: handleAddEndListener,\n timeout: timeout === 'auto' ? null : timeout\n }, other, {\n children: (state, childProps) => {\n return /*#__PURE__*/React.cloneElement(children, _extends({\n style: _extends({\n opacity: 0,\n transform: getScale(0.75),\n visibility: state === 'exited' && !inProp ? 'hidden' : undefined\n }, styles[state], style, children.props.style),\n ref: handleRef\n }, childProps));\n }\n }));\n});\nprocess.env.NODE_ENV !== \"production\" ? Grow.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the d.ts file and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * Add a custom transition end trigger. Called with the transitioning DOM\n * node and a done callback. Allows for more fine grained transition end\n * logic. Note: Timeouts are still used as a fallback if provided.\n */\n addEndListener: PropTypes.func,\n /**\n * Perform the enter transition when it first mounts if `in` is also `true`.\n * Set this to `false` to disable this behavior.\n * @default true\n */\n appear: PropTypes.bool,\n /**\n * A single child content element.\n */\n children: elementAcceptingRef.isRequired,\n /**\n * The transition timing function.\n * You may specify a single easing or a object containing enter and exit values.\n */\n easing: PropTypes.oneOfType([PropTypes.shape({\n enter: PropTypes.string,\n exit: PropTypes.string\n }), PropTypes.string]),\n /**\n * If `true`, the component will transition in.\n */\n in: PropTypes.bool,\n /**\n * @ignore\n */\n onEnter: PropTypes.func,\n /**\n * @ignore\n */\n onEntered: PropTypes.func,\n /**\n * @ignore\n */\n onEntering: PropTypes.func,\n /**\n * @ignore\n */\n onExit: PropTypes.func,\n /**\n * @ignore\n */\n onExited: PropTypes.func,\n /**\n * @ignore\n */\n onExiting: PropTypes.func,\n /**\n * @ignore\n */\n style: PropTypes.object,\n /**\n * The duration for the transition, in milliseconds.\n * You may specify a single timeout for all transitions, or individually with an object.\n *\n * Set to 'auto' to automatically calculate transition time based on height.\n * @default 'auto'\n */\n timeout: PropTypes.oneOfType([PropTypes.oneOf(['auto']), PropTypes.number, PropTypes.shape({\n appear: PropTypes.number,\n enter: PropTypes.number,\n exit: PropTypes.number\n })])\n} : void 0;\nGrow.muiSupportAuto = true;\nexport default Grow;","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"anchorEl\", \"component\", \"components\", \"componentsProps\", \"container\", \"disablePortal\", \"keepMounted\", \"modifiers\", \"open\", \"placement\", \"popperOptions\", \"popperRef\", \"transition\", \"slots\", \"slotProps\"];\nimport { Popper as BasePopper } from '@mui/base/Popper';\nimport { useThemeWithoutDefault as useTheme } from '@mui/system';\nimport { HTMLElementType, refType } from '@mui/utils';\nimport PropTypes from 'prop-types';\nimport * as React from 'react';\nimport { styled, useThemeProps } from '../styles';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nconst PopperRoot = styled(BasePopper, {\n name: 'MuiPopper',\n slot: 'Root',\n overridesResolver: (props, styles) => styles.root\n})({});\n\n/**\n *\n * Demos:\n *\n * - [Autocomplete](https://mui.com/material-ui/react-autocomplete/)\n * - [Menu](https://mui.com/material-ui/react-menu/)\n * - [Popper](https://mui.com/material-ui/react-popper/)\n *\n * API:\n *\n * - [Popper API](https://mui.com/material-ui/api/popper/)\n */\nconst Popper = /*#__PURE__*/React.forwardRef(function Popper(inProps, ref) {\n var _slots$root;\n const theme = useTheme();\n const props = useThemeProps({\n props: inProps,\n name: 'MuiPopper'\n });\n const {\n anchorEl,\n component,\n components,\n componentsProps,\n container,\n disablePortal,\n keepMounted,\n modifiers,\n open,\n placement,\n popperOptions,\n popperRef,\n transition,\n slots,\n slotProps\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const RootComponent = (_slots$root = slots == null ? void 0 : slots.root) != null ? _slots$root : components == null ? void 0 : components.Root;\n const otherProps = _extends({\n anchorEl,\n container,\n disablePortal,\n keepMounted,\n modifiers,\n open,\n placement,\n popperOptions,\n popperRef,\n transition\n }, other);\n return /*#__PURE__*/_jsx(PopperRoot, _extends({\n as: component,\n direction: theme == null ? void 0 : theme.direction,\n slots: {\n root: RootComponent\n },\n slotProps: slotProps != null ? slotProps : componentsProps\n }, otherProps, {\n ref: ref\n }));\n});\nprocess.env.NODE_ENV !== \"production\" ? Popper.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * An HTML element, [virtualElement](https://popper.js.org/docs/v2/virtual-elements/),\n * or a function that returns either.\n * It's used to set the position of the popper.\n * The return value will passed as the reference object of the Popper instance.\n */\n anchorEl: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.object, PropTypes.func]),\n /**\n * Popper render function or node.\n */\n children: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.node, PropTypes.func]),\n /**\n * The component used for the root node.\n * Either a string to use a HTML element or a component.\n */\n component: PropTypes.elementType,\n /**\n * The components used for each slot inside the Popper.\n * Either a string to use a HTML element or a component.\n * @default {}\n */\n components: PropTypes.shape({\n Root: PropTypes.elementType\n }),\n /**\n * The props used for each slot inside the Popper.\n * @default {}\n */\n componentsProps: PropTypes.shape({\n root: PropTypes.oneOfType([PropTypes.func, PropTypes.object])\n }),\n /**\n * An HTML element or function that returns one.\n * The `container` will have the portal children appended to it.\n *\n * You can also provide a callback, which is called in a React layout effect.\n * This lets you set the container from a ref, and also makes server-side rendering possible.\n *\n * By default, it uses the body of the top-level document object,\n * so it's simply `document.body` most of the time.\n */\n container: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.func]),\n /**\n * The `children` will be under the DOM hierarchy of the parent component.\n * @default false\n */\n disablePortal: PropTypes.bool,\n /**\n * Always keep the children in the DOM.\n * This prop can be useful in SEO situation or\n * when you want to maximize the responsiveness of the Popper.\n * @default false\n */\n keepMounted: PropTypes.bool,\n /**\n * Popper.js is based on a \"plugin-like\" architecture,\n * most of its features are fully encapsulated \"modifiers\".\n *\n * A modifier is a function that is called each time Popper.js needs to\n * compute the position of the popper.\n * For this reason, modifiers should be very performant to avoid bottlenecks.\n * To learn how to create a modifier, [read the modifiers documentation](https://popper.js.org/docs/v2/modifiers/).\n */\n modifiers: PropTypes.arrayOf(PropTypes.shape({\n data: PropTypes.object,\n effect: PropTypes.func,\n enabled: PropTypes.bool,\n fn: PropTypes.func,\n name: PropTypes.any,\n options: PropTypes.object,\n phase: PropTypes.oneOf(['afterMain', 'afterRead', 'afterWrite', 'beforeMain', 'beforeRead', 'beforeWrite', 'main', 'read', 'write']),\n requires: PropTypes.arrayOf(PropTypes.string),\n requiresIfExists: PropTypes.arrayOf(PropTypes.string)\n })),\n /**\n * If `true`, the component is shown.\n */\n open: PropTypes.bool.isRequired,\n /**\n * Popper placement.\n * @default 'bottom'\n */\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n /**\n * Options provided to the [`Popper.js`](https://popper.js.org/docs/v2/constructors/#options) instance.\n * @default {}\n */\n popperOptions: PropTypes.shape({\n modifiers: PropTypes.array,\n onFirstUpdate: PropTypes.func,\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n strategy: PropTypes.oneOf(['absolute', 'fixed'])\n }),\n /**\n * A ref that points to the used popper instance.\n */\n popperRef: refType,\n /**\n * The props used for each slot inside the Popper.\n * @default {}\n */\n slotProps: PropTypes.shape({\n root: PropTypes.oneOfType([PropTypes.func, PropTypes.object])\n }),\n /**\n * The components used for each slot inside the Popper.\n * Either a string to use a HTML element or a component.\n * @default {}\n */\n slots: PropTypes.shape({\n root: PropTypes.elementType\n }),\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Help supporting a react-transition-group/Transition component.\n * @default false\n */\n transition: PropTypes.bool\n} : void 0;\nexport default Popper;","import generateUtilityClasses from '@mui/utils/generateUtilityClasses';\nimport generateUtilityClass from '@mui/utils/generateUtilityClass';\nexport function getTooltipUtilityClass(slot) {\n return generateUtilityClass('MuiTooltip', slot);\n}\nconst tooltipClasses = generateUtilityClasses('MuiTooltip', ['popper', 'popperInteractive', 'popperArrow', 'popperClose', 'tooltip', 'tooltipArrow', 'touch', 'tooltipPlacementLeft', 'tooltipPlacementRight', 'tooltipPlacementTop', 'tooltipPlacementBottom', 'arrow']);\nexport default tooltipClasses;","'use client';\n\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nconst _excluded = [\"arrow\", \"children\", \"classes\", \"components\", \"componentsProps\", \"describeChild\", \"disableFocusListener\", \"disableHoverListener\", \"disableInteractive\", \"disableTouchListener\", \"enterDelay\", \"enterNextDelay\", \"enterTouchDelay\", \"followCursor\", \"id\", \"leaveDelay\", \"leaveTouchDelay\", \"onClose\", \"onOpen\", \"open\", \"placement\", \"PopperComponent\", \"PopperProps\", \"slotProps\", \"slots\", \"title\", \"TransitionComponent\", \"TransitionProps\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport clsx from 'clsx';\nimport { elementAcceptingRef, unstable_useTimeout as useTimeout, unstable_Timeout as Timeout } from '@mui/utils';\nimport { unstable_composeClasses as composeClasses, appendOwnerState } from '@mui/base';\nimport { alpha } from '@mui/system';\nimport styled from '../styles/styled';\nimport useTheme from '../styles/useTheme';\nimport useThemeProps from '../styles/useThemeProps';\nimport capitalize from '../utils/capitalize';\nimport Grow from '../Grow';\nimport Popper from '../Popper';\nimport useEventCallback from '../utils/useEventCallback';\nimport useForkRef from '../utils/useForkRef';\nimport useId from '../utils/useId';\nimport useIsFocusVisible from '../utils/useIsFocusVisible';\nimport useControlled from '../utils/useControlled';\nimport tooltipClasses, { getTooltipUtilityClass } from './tooltipClasses';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nimport { jsxs as _jsxs } from \"react/jsx-runtime\";\nfunction round(value) {\n return Math.round(value * 1e5) / 1e5;\n}\nconst useUtilityClasses = ownerState => {\n const {\n classes,\n disableInteractive,\n arrow,\n touch,\n placement\n } = ownerState;\n const slots = {\n popper: ['popper', !disableInteractive && 'popperInteractive', arrow && 'popperArrow'],\n tooltip: ['tooltip', arrow && 'tooltipArrow', touch && 'touch', `tooltipPlacement${capitalize(placement.split('-')[0])}`],\n arrow: ['arrow']\n };\n return composeClasses(slots, getTooltipUtilityClass, classes);\n};\nconst TooltipPopper = styled(Popper, {\n name: 'MuiTooltip',\n slot: 'Popper',\n overridesResolver: (props, styles) => {\n const {\n ownerState\n } = props;\n return [styles.popper, !ownerState.disableInteractive && styles.popperInteractive, ownerState.arrow && styles.popperArrow, !ownerState.open && styles.popperClose];\n }\n})(({\n theme,\n ownerState,\n open\n}) => _extends({\n zIndex: (theme.vars || theme).zIndex.tooltip,\n pointerEvents: 'none'\n}, !ownerState.disableInteractive && {\n pointerEvents: 'auto'\n}, !open && {\n pointerEvents: 'none'\n}, ownerState.arrow && {\n [`&[data-popper-placement*=\"bottom\"] .${tooltipClasses.arrow}`]: {\n top: 0,\n marginTop: '-0.71em',\n '&::before': {\n transformOrigin: '0 100%'\n }\n },\n [`&[data-popper-placement*=\"top\"] .${tooltipClasses.arrow}`]: {\n bottom: 0,\n marginBottom: '-0.71em',\n '&::before': {\n transformOrigin: '100% 0'\n }\n },\n [`&[data-popper-placement*=\"right\"] .${tooltipClasses.arrow}`]: _extends({}, !ownerState.isRtl ? {\n left: 0,\n marginLeft: '-0.71em'\n } : {\n right: 0,\n marginRight: '-0.71em'\n }, {\n height: '1em',\n width: '0.71em',\n '&::before': {\n transformOrigin: '100% 100%'\n }\n }),\n [`&[data-popper-placement*=\"left\"] .${tooltipClasses.arrow}`]: _extends({}, !ownerState.isRtl ? {\n right: 0,\n marginRight: '-0.71em'\n } : {\n left: 0,\n marginLeft: '-0.71em'\n }, {\n height: '1em',\n width: '0.71em',\n '&::before': {\n transformOrigin: '0 0'\n }\n })\n}));\nconst TooltipTooltip = styled('div', {\n name: 'MuiTooltip',\n slot: 'Tooltip',\n overridesResolver: (props, styles) => {\n const {\n ownerState\n } = props;\n return [styles.tooltip, ownerState.touch && styles.touch, ownerState.arrow && styles.tooltipArrow, styles[`tooltipPlacement${capitalize(ownerState.placement.split('-')[0])}`]];\n }\n})(({\n theme,\n ownerState\n}) => _extends({\n backgroundColor: theme.vars ? theme.vars.palette.Tooltip.bg : alpha(theme.palette.grey[700], 0.92),\n borderRadius: (theme.vars || theme).shape.borderRadius,\n color: (theme.vars || theme).palette.common.white,\n fontFamily: theme.typography.fontFamily,\n padding: '4px 8px',\n fontSize: theme.typography.pxToRem(11),\n maxWidth: 300,\n margin: 2,\n wordWrap: 'break-word',\n fontWeight: theme.typography.fontWeightMedium\n}, ownerState.arrow && {\n position: 'relative',\n margin: 0\n}, ownerState.touch && {\n padding: '8px 16px',\n fontSize: theme.typography.pxToRem(14),\n lineHeight: `${round(16 / 14)}em`,\n fontWeight: theme.typography.fontWeightRegular\n}, {\n [`.${tooltipClasses.popper}[data-popper-placement*=\"left\"] &`]: _extends({\n transformOrigin: 'right center'\n }, !ownerState.isRtl ? _extends({\n marginRight: '14px'\n }, ownerState.touch && {\n marginRight: '24px'\n }) : _extends({\n marginLeft: '14px'\n }, ownerState.touch && {\n marginLeft: '24px'\n })),\n [`.${tooltipClasses.popper}[data-popper-placement*=\"right\"] &`]: _extends({\n transformOrigin: 'left center'\n }, !ownerState.isRtl ? _extends({\n marginLeft: '14px'\n }, ownerState.touch && {\n marginLeft: '24px'\n }) : _extends({\n marginRight: '14px'\n }, ownerState.touch && {\n marginRight: '24px'\n })),\n [`.${tooltipClasses.popper}[data-popper-placement*=\"top\"] &`]: _extends({\n transformOrigin: 'center bottom',\n marginBottom: '14px'\n }, ownerState.touch && {\n marginBottom: '24px'\n }),\n [`.${tooltipClasses.popper}[data-popper-placement*=\"bottom\"] &`]: _extends({\n transformOrigin: 'center top',\n marginTop: '14px'\n }, ownerState.touch && {\n marginTop: '24px'\n })\n}));\nconst TooltipArrow = styled('span', {\n name: 'MuiTooltip',\n slot: 'Arrow',\n overridesResolver: (props, styles) => styles.arrow\n})(({\n theme\n}) => ({\n overflow: 'hidden',\n position: 'absolute',\n width: '1em',\n height: '0.71em' /* = width / sqrt(2) = (length of the hypotenuse) */,\n boxSizing: 'border-box',\n color: theme.vars ? theme.vars.palette.Tooltip.bg : alpha(theme.palette.grey[700], 0.9),\n '&::before': {\n content: '\"\"',\n margin: 'auto',\n display: 'block',\n width: '100%',\n height: '100%',\n backgroundColor: 'currentColor',\n transform: 'rotate(45deg)'\n }\n}));\nlet hystersisOpen = false;\nconst hystersisTimer = new Timeout();\nlet cursorPosition = {\n x: 0,\n y: 0\n};\nexport function testReset() {\n hystersisOpen = false;\n hystersisTimer.clear();\n}\nfunction composeEventHandler(handler, eventHandler) {\n return event => {\n if (eventHandler) {\n eventHandler(event);\n }\n handler(event);\n };\n}\n\n// TODO v6: Remove PopperComponent, PopperProps, TransitionComponent and TransitionProps.\nconst Tooltip = /*#__PURE__*/React.forwardRef(function Tooltip(inProps, ref) {\n var _ref, _slots$popper, _ref2, _ref3, _slots$transition, _ref4, _slots$tooltip, _ref5, _slots$arrow, _slotProps$popper, _ref6, _slotProps$popper2, _slotProps$transition, _slotProps$tooltip, _ref7, _slotProps$tooltip2, _slotProps$arrow, _ref8, _slotProps$arrow2;\n const props = useThemeProps({\n props: inProps,\n name: 'MuiTooltip'\n });\n const {\n arrow = false,\n children: childrenProp,\n components = {},\n componentsProps = {},\n describeChild = false,\n disableFocusListener = false,\n disableHoverListener = false,\n disableInteractive: disableInteractiveProp = false,\n disableTouchListener = false,\n enterDelay = 100,\n enterNextDelay = 0,\n enterTouchDelay = 700,\n followCursor = false,\n id: idProp,\n leaveDelay = 0,\n leaveTouchDelay = 1500,\n onClose,\n onOpen,\n open: openProp,\n placement = 'bottom',\n PopperComponent: PopperComponentProp,\n PopperProps = {},\n slotProps = {},\n slots = {},\n title,\n TransitionComponent: TransitionComponentProp = Grow,\n TransitionProps\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n\n // to prevent runtime errors, developers will need to provide a child as a React element anyway.\n const children = /*#__PURE__*/React.isValidElement(childrenProp) ? childrenProp : /*#__PURE__*/_jsx(\"span\", {\n children: childrenProp\n });\n const theme = useTheme();\n const isRtl = theme.direction === 'rtl';\n const [childNode, setChildNode] = React.useState();\n const [arrowRef, setArrowRef] = React.useState(null);\n const ignoreNonTouchEvents = React.useRef(false);\n const disableInteractive = disableInteractiveProp || followCursor;\n const closeTimer = useTimeout();\n const enterTimer = useTimeout();\n const leaveTimer = useTimeout();\n const touchTimer = useTimeout();\n const [openState, setOpenState] = useControlled({\n controlled: openProp,\n default: false,\n name: 'Tooltip',\n state: 'open'\n });\n let open = openState;\n if (process.env.NODE_ENV !== 'production') {\n // eslint-disable-next-line react-hooks/rules-of-hooks\n const {\n current: isControlled\n } = React.useRef(openProp !== undefined);\n\n // eslint-disable-next-line react-hooks/rules-of-hooks\n React.useEffect(() => {\n if (childNode && childNode.disabled && !isControlled && title !== '' && childNode.tagName.toLowerCase() === 'button') {\n console.error(['MUI: You are providing a disabled `button` child to the Tooltip component.', 'A disabled element does not fire events.', \"Tooltip needs to listen to the child element's events to display the title.\", '', 'Add a simple wrapper element, such as a `span`.'].join('\\n'));\n }\n }, [title, childNode, isControlled]);\n }\n const id = useId(idProp);\n const prevUserSelect = React.useRef();\n const stopTouchInteraction = useEventCallback(() => {\n if (prevUserSelect.current !== undefined) {\n document.body.style.WebkitUserSelect = prevUserSelect.current;\n prevUserSelect.current = undefined;\n }\n touchTimer.clear();\n });\n React.useEffect(() => stopTouchInteraction, [stopTouchInteraction]);\n const handleOpen = event => {\n hystersisTimer.clear();\n hystersisOpen = true;\n\n // The mouseover event will trigger for every nested element in the tooltip.\n // We can skip rerendering when the tooltip is already open.\n // We are using the mouseover event instead of the mouseenter event to fix a hide/show issue.\n setOpenState(true);\n if (onOpen && !open) {\n onOpen(event);\n }\n };\n const handleClose = useEventCallback(\n /**\n * @param {React.SyntheticEvent | Event} event\n */\n event => {\n hystersisTimer.start(800 + leaveDelay, () => {\n hystersisOpen = false;\n });\n setOpenState(false);\n if (onClose && open) {\n onClose(event);\n }\n closeTimer.start(theme.transitions.duration.shortest, () => {\n ignoreNonTouchEvents.current = false;\n });\n });\n const handleEnter = event => {\n if (ignoreNonTouchEvents.current && event.type !== 'touchstart') {\n return;\n }\n\n // Remove the title ahead of time.\n // We don't want to wait for the next render commit.\n // We would risk displaying two tooltips at the same time (native + this one).\n if (childNode) {\n childNode.removeAttribute('title');\n }\n enterTimer.clear();\n leaveTimer.clear();\n if (enterDelay || hystersisOpen && enterNextDelay) {\n enterTimer.start(hystersisOpen ? enterNextDelay : enterDelay, () => {\n handleOpen(event);\n });\n } else {\n handleOpen(event);\n }\n };\n const handleLeave = event => {\n enterTimer.clear();\n leaveTimer.start(leaveDelay, () => {\n handleClose(event);\n });\n };\n const {\n isFocusVisibleRef,\n onBlur: handleBlurVisible,\n onFocus: handleFocusVisible,\n ref: focusVisibleRef\n } = useIsFocusVisible();\n // We don't necessarily care about the focusVisible state (which is safe to access via ref anyway).\n // We just need to re-render the Tooltip if the focus-visible state changes.\n const [, setChildIsFocusVisible] = React.useState(false);\n const handleBlur = event => {\n handleBlurVisible(event);\n if (isFocusVisibleRef.current === false) {\n setChildIsFocusVisible(false);\n handleLeave(event);\n }\n };\n const handleFocus = event => {\n // Workaround for https://github.com/facebook/react/issues/7769\n // The autoFocus of React might trigger the event before the componentDidMount.\n // We need to account for this eventuality.\n if (!childNode) {\n setChildNode(event.currentTarget);\n }\n handleFocusVisible(event);\n if (isFocusVisibleRef.current === true) {\n setChildIsFocusVisible(true);\n handleEnter(event);\n }\n };\n const detectTouchStart = event => {\n ignoreNonTouchEvents.current = true;\n const childrenProps = children.props;\n if (childrenProps.onTouchStart) {\n childrenProps.onTouchStart(event);\n }\n };\n const handleMouseOver = handleEnter;\n const handleMouseLeave = handleLeave;\n const handleTouchStart = event => {\n detectTouchStart(event);\n leaveTimer.clear();\n closeTimer.clear();\n stopTouchInteraction();\n prevUserSelect.current = document.body.style.WebkitUserSelect;\n // Prevent iOS text selection on long-tap.\n document.body.style.WebkitUserSelect = 'none';\n touchTimer.start(enterTouchDelay, () => {\n document.body.style.WebkitUserSelect = prevUserSelect.current;\n handleEnter(event);\n });\n };\n const handleTouchEnd = event => {\n if (children.props.onTouchEnd) {\n children.props.onTouchEnd(event);\n }\n stopTouchInteraction();\n leaveTimer.start(leaveTouchDelay, () => {\n handleClose(event);\n });\n };\n React.useEffect(() => {\n if (!open) {\n return undefined;\n }\n\n /**\n * @param {KeyboardEvent} nativeEvent\n */\n function handleKeyDown(nativeEvent) {\n // IE11, Edge (prior to using Bink?) use 'Esc'\n if (nativeEvent.key === 'Escape' || nativeEvent.key === 'Esc') {\n handleClose(nativeEvent);\n }\n }\n document.addEventListener('keydown', handleKeyDown);\n return () => {\n document.removeEventListener('keydown', handleKeyDown);\n };\n }, [handleClose, open]);\n const handleRef = useForkRef(children.ref, focusVisibleRef, setChildNode, ref);\n\n // There is no point in displaying an empty tooltip.\n // So we exclude all falsy values, except 0, which is valid.\n if (!title && title !== 0) {\n open = false;\n }\n const popperRef = React.useRef();\n const handleMouseMove = event => {\n const childrenProps = children.props;\n if (childrenProps.onMouseMove) {\n childrenProps.onMouseMove(event);\n }\n cursorPosition = {\n x: event.clientX,\n y: event.clientY\n };\n if (popperRef.current) {\n popperRef.current.update();\n }\n };\n const nameOrDescProps = {};\n const titleIsString = typeof title === 'string';\n if (describeChild) {\n nameOrDescProps.title = !open && titleIsString && !disableHoverListener ? title : null;\n nameOrDescProps['aria-describedby'] = open ? id : null;\n } else {\n nameOrDescProps['aria-label'] = titleIsString ? title : null;\n nameOrDescProps['aria-labelledby'] = open && !titleIsString ? id : null;\n }\n const childrenProps = _extends({}, nameOrDescProps, other, children.props, {\n className: clsx(other.className, children.props.className),\n onTouchStart: detectTouchStart,\n ref: handleRef\n }, followCursor ? {\n onMouseMove: handleMouseMove\n } : {});\n if (process.env.NODE_ENV !== 'production') {\n childrenProps['data-mui-internal-clone-element'] = true;\n\n // eslint-disable-next-line react-hooks/rules-of-hooks\n React.useEffect(() => {\n if (childNode && !childNode.getAttribute('data-mui-internal-clone-element')) {\n console.error(['MUI: The `children` component of the Tooltip is not forwarding its props correctly.', 'Please make sure that props are spread on the same element that the ref is applied to.'].join('\\n'));\n }\n }, [childNode]);\n }\n const interactiveWrapperListeners = {};\n if (!disableTouchListener) {\n childrenProps.onTouchStart = handleTouchStart;\n childrenProps.onTouchEnd = handleTouchEnd;\n }\n if (!disableHoverListener) {\n childrenProps.onMouseOver = composeEventHandler(handleMouseOver, childrenProps.onMouseOver);\n childrenProps.onMouseLeave = composeEventHandler(handleMouseLeave, childrenProps.onMouseLeave);\n if (!disableInteractive) {\n interactiveWrapperListeners.onMouseOver = handleMouseOver;\n interactiveWrapperListeners.onMouseLeave = handleMouseLeave;\n }\n }\n if (!disableFocusListener) {\n childrenProps.onFocus = composeEventHandler(handleFocus, childrenProps.onFocus);\n childrenProps.onBlur = composeEventHandler(handleBlur, childrenProps.onBlur);\n if (!disableInteractive) {\n interactiveWrapperListeners.onFocus = handleFocus;\n interactiveWrapperListeners.onBlur = handleBlur;\n }\n }\n if (process.env.NODE_ENV !== 'production') {\n if (children.props.title) {\n console.error(['MUI: You have provided a `title` prop to the child of .', `Remove this title prop \\`${children.props.title}\\` or the Tooltip component.`].join('\\n'));\n }\n }\n const popperOptions = React.useMemo(() => {\n var _PopperProps$popperOp;\n let tooltipModifiers = [{\n name: 'arrow',\n enabled: Boolean(arrowRef),\n options: {\n element: arrowRef,\n padding: 4\n }\n }];\n if ((_PopperProps$popperOp = PopperProps.popperOptions) != null && _PopperProps$popperOp.modifiers) {\n tooltipModifiers = tooltipModifiers.concat(PopperProps.popperOptions.modifiers);\n }\n return _extends({}, PopperProps.popperOptions, {\n modifiers: tooltipModifiers\n });\n }, [arrowRef, PopperProps]);\n const ownerState = _extends({}, props, {\n isRtl,\n arrow,\n disableInteractive,\n placement,\n PopperComponentProp,\n touch: ignoreNonTouchEvents.current\n });\n const classes = useUtilityClasses(ownerState);\n const PopperComponent = (_ref = (_slots$popper = slots.popper) != null ? _slots$popper : components.Popper) != null ? _ref : TooltipPopper;\n const TransitionComponent = (_ref2 = (_ref3 = (_slots$transition = slots.transition) != null ? _slots$transition : components.Transition) != null ? _ref3 : TransitionComponentProp) != null ? _ref2 : Grow;\n const TooltipComponent = (_ref4 = (_slots$tooltip = slots.tooltip) != null ? _slots$tooltip : components.Tooltip) != null ? _ref4 : TooltipTooltip;\n const ArrowComponent = (_ref5 = (_slots$arrow = slots.arrow) != null ? _slots$arrow : components.Arrow) != null ? _ref5 : TooltipArrow;\n const popperProps = appendOwnerState(PopperComponent, _extends({}, PopperProps, (_slotProps$popper = slotProps.popper) != null ? _slotProps$popper : componentsProps.popper, {\n className: clsx(classes.popper, PopperProps == null ? void 0 : PopperProps.className, (_ref6 = (_slotProps$popper2 = slotProps.popper) != null ? _slotProps$popper2 : componentsProps.popper) == null ? void 0 : _ref6.className)\n }), ownerState);\n const transitionProps = appendOwnerState(TransitionComponent, _extends({}, TransitionProps, (_slotProps$transition = slotProps.transition) != null ? _slotProps$transition : componentsProps.transition), ownerState);\n const tooltipProps = appendOwnerState(TooltipComponent, _extends({}, (_slotProps$tooltip = slotProps.tooltip) != null ? _slotProps$tooltip : componentsProps.tooltip, {\n className: clsx(classes.tooltip, (_ref7 = (_slotProps$tooltip2 = slotProps.tooltip) != null ? _slotProps$tooltip2 : componentsProps.tooltip) == null ? void 0 : _ref7.className)\n }), ownerState);\n const tooltipArrowProps = appendOwnerState(ArrowComponent, _extends({}, (_slotProps$arrow = slotProps.arrow) != null ? _slotProps$arrow : componentsProps.arrow, {\n className: clsx(classes.arrow, (_ref8 = (_slotProps$arrow2 = slotProps.arrow) != null ? _slotProps$arrow2 : componentsProps.arrow) == null ? void 0 : _ref8.className)\n }), ownerState);\n return /*#__PURE__*/_jsxs(React.Fragment, {\n children: [/*#__PURE__*/React.cloneElement(children, childrenProps), /*#__PURE__*/_jsx(PopperComponent, _extends({\n as: PopperComponentProp != null ? PopperComponentProp : Popper,\n placement: placement,\n anchorEl: followCursor ? {\n getBoundingClientRect: () => ({\n top: cursorPosition.y,\n left: cursorPosition.x,\n right: cursorPosition.x,\n bottom: cursorPosition.y,\n width: 0,\n height: 0\n })\n } : childNode,\n popperRef: popperRef,\n open: childNode ? open : false,\n id: id,\n transition: true\n }, interactiveWrapperListeners, popperProps, {\n popperOptions: popperOptions,\n children: ({\n TransitionProps: TransitionPropsInner\n }) => /*#__PURE__*/_jsx(TransitionComponent, _extends({\n timeout: theme.transitions.duration.shorter\n }, TransitionPropsInner, transitionProps, {\n children: /*#__PURE__*/_jsxs(TooltipComponent, _extends({}, tooltipProps, {\n children: [title, arrow ? /*#__PURE__*/_jsx(ArrowComponent, _extends({}, tooltipArrowProps, {\n ref: setArrowRef\n })) : null]\n }))\n }))\n }))]\n });\n});\nprocess.env.NODE_ENV !== \"production\" ? Tooltip.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the d.ts file and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * If `true`, adds an arrow to the tooltip.\n * @default false\n */\n arrow: PropTypes.bool,\n /**\n * Tooltip reference element.\n */\n children: elementAcceptingRef.isRequired,\n /**\n * Override or extend the styles applied to the component.\n */\n classes: PropTypes.object,\n /**\n * @ignore\n */\n className: PropTypes.string,\n /**\n * The components used for each slot inside.\n *\n * This prop is an alias for the `slots` prop.\n * It's recommended to use the `slots` prop instead.\n *\n * @default {}\n */\n components: PropTypes.shape({\n Arrow: PropTypes.elementType,\n Popper: PropTypes.elementType,\n Tooltip: PropTypes.elementType,\n Transition: PropTypes.elementType\n }),\n /**\n * The extra props for the slot components.\n * You can override the existing props or add new ones.\n *\n * This prop is an alias for the `slotProps` prop.\n * It's recommended to use the `slotProps` prop instead, as `componentsProps` will be deprecated in the future.\n *\n * @default {}\n */\n componentsProps: PropTypes.shape({\n arrow: PropTypes.object,\n popper: PropTypes.object,\n tooltip: PropTypes.object,\n transition: PropTypes.object\n }),\n /**\n * Set to `true` if the `title` acts as an accessible description.\n * By default the `title` acts as an accessible label for the child.\n * @default false\n */\n describeChild: PropTypes.bool,\n /**\n * Do not respond to focus-visible events.\n * @default false\n */\n disableFocusListener: PropTypes.bool,\n /**\n * Do not respond to hover events.\n * @default false\n */\n disableHoverListener: PropTypes.bool,\n /**\n * Makes a tooltip not interactive, i.e. it will close when the user\n * hovers over the tooltip before the `leaveDelay` is expired.\n * @default false\n */\n disableInteractive: PropTypes.bool,\n /**\n * Do not respond to long press touch events.\n * @default false\n */\n disableTouchListener: PropTypes.bool,\n /**\n * The number of milliseconds to wait before showing the tooltip.\n * This prop won't impact the enter touch delay (`enterTouchDelay`).\n * @default 100\n */\n enterDelay: PropTypes.number,\n /**\n * The number of milliseconds to wait before showing the tooltip when one was already recently opened.\n * @default 0\n */\n enterNextDelay: PropTypes.number,\n /**\n * The number of milliseconds a user must touch the element before showing the tooltip.\n * @default 700\n */\n enterTouchDelay: PropTypes.number,\n /**\n * If `true`, the tooltip follow the cursor over the wrapped element.\n * @default false\n */\n followCursor: PropTypes.bool,\n /**\n * This prop is used to help implement the accessibility logic.\n * If you don't provide this prop. It falls back to a randomly generated id.\n */\n id: PropTypes.string,\n /**\n * The number of milliseconds to wait before hiding the tooltip.\n * This prop won't impact the leave touch delay (`leaveTouchDelay`).\n * @default 0\n */\n leaveDelay: PropTypes.number,\n /**\n * The number of milliseconds after the user stops touching an element before hiding the tooltip.\n * @default 1500\n */\n leaveTouchDelay: PropTypes.number,\n /**\n * Callback fired when the component requests to be closed.\n *\n * @param {React.SyntheticEvent} event The event source of the callback.\n */\n onClose: PropTypes.func,\n /**\n * Callback fired when the component requests to be open.\n *\n * @param {React.SyntheticEvent} event The event source of the callback.\n */\n onOpen: PropTypes.func,\n /**\n * If `true`, the component is shown.\n */\n open: PropTypes.bool,\n /**\n * Tooltip placement.\n * @default 'bottom'\n */\n placement: PropTypes.oneOf(['bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n /**\n * The component used for the popper.\n * @default Popper\n */\n PopperComponent: PropTypes.elementType,\n /**\n * Props applied to the [`Popper`](/material-ui/api/popper/) element.\n * @default {}\n */\n PopperProps: PropTypes.object,\n /**\n * The extra props for the slot components.\n * You can override the existing props or add new ones.\n *\n * This prop is an alias for the `componentsProps` prop, which will be deprecated in the future.\n *\n * @default {}\n */\n slotProps: PropTypes.shape({\n arrow: PropTypes.object,\n popper: PropTypes.object,\n tooltip: PropTypes.object,\n transition: PropTypes.object\n }),\n /**\n * The components used for each slot inside.\n *\n * This prop is an alias for the `components` prop, which will be deprecated in the future.\n *\n * @default {}\n */\n slots: PropTypes.shape({\n arrow: PropTypes.elementType,\n popper: PropTypes.elementType,\n tooltip: PropTypes.elementType,\n transition: PropTypes.elementType\n }),\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Tooltip title. Zero-length titles string, undefined, null and false are never displayed.\n */\n title: PropTypes.node,\n /**\n * The component used for the transition.\n * [Follow this guide](/material-ui/transitions/#transitioncomponent-prop) to learn more about the requirements for this component.\n * @default Grow\n */\n TransitionComponent: PropTypes.elementType,\n /**\n * Props applied to the transition element.\n * By default, the element is based on this [`Transition`](http://reactcommunity.org/react-transition-group/transition/) component.\n */\n TransitionProps: PropTypes.object\n} : void 0;\nexport default Tooltip;","import '@/components/mui/menu-item.component.css';\nimport ArrowRightIcon from '@mui/icons-material/ArrowRight';\nimport {\n ListItemIcon as MuiListItemIcon,\n ListItemText as MuiListItemText,\n MenuItem as MuiMenuItem,\n} from '@mui/material';\nimport Tooltip from '@mui/material/Tooltip';\nimport { Localized, ReferencedItem, SingleColumnMenu } from 'platform-bible-utils';\nimport { MouseEvent, PropsWithChildren } from 'react';\n\ntype MenuItemInfoBase = {\n /** Text (displayable in the UI) as the name of the menu item */\n label: string;\n /** Text to display when the mouse hovers over the menu item */\n tooltip?: string;\n};\n\nexport type Command = MenuItemInfoBase & {\n /** Command to execute (string.string) */\n command: string;\n};\n\ntype SubMenu = MenuItemInfoBase & {\n /** Command to execute (string.string) */\n items: MenuItemInfo[];\n};\n\nexport interface CommandHandler {\n (command: Command): void;\n}\n\nexport type MenuPropsBase = {\n /*\n * The JSON defining the menu whose items are to be rendered. This will typically be one of the\n * menus in the \"defs\" in a Platform.Bible menu (see PlatformMenus). The schema for this is\n * menuDocumentSchema (at the end of menus.model.ts). Note that while this is a\n * \"SingleColumnMenu\", somewhat bizarrely, a MultiColumnMenu is a SingleColumnMenu, so it really\n * could be a MultiColumnMenu, in which case, column had better be defined so it can be used\n * to filter out the actual groups and items to display on the column.\n */\n menuDefinition: Localized;\n\n commandHandler: CommandHandler;\n\n /**\n * Additional action to perform when any menu item is clicked. Allows the caller to handle event\n * (e.g., to close the menu).\n */\n onClick?: (event: MouseEvent) => void;\n};\n\nexport type MenuItemListProps = MenuPropsBase & {\n /** Optional unique (column) identifier */\n columnId?: ReferencedItem;\n};\n\nexport type MenuItemProps = Omit &\n PropsWithChildren<{\n /** Optional unique identifier */\n id?: string;\n\n onClick: (event: MouseEvent) => void;\n }>;\n\ntype MenuItemInfo = (Command | SubMenu) & {\n /**\n * If specified, menu item will be inset if it does not have a leading icon.\n *\n * @default true\n */\n allowForLeadingIcons?: boolean;\n /**\n * If specified, the path to the icon image to display on the leading side of the menu text.\n *\n * @default undefined (no leading icon will be shown)\n */\n iconPathBefore?: string;\n /**\n * If specified, the path to the icon image to display on the trailing side of the menu text.\n *\n * @default undefined (no trailing icon will be shown)\n */\n iconPathAfter?: string;\n /**\n * If true, list item is focused during the first mount\n *\n * @default false\n */\n hasAutoFocus?: boolean;\n\n /** Additional css classes to help with unique styling of the menu item */\n className?: string;\n\n /**\n * If true, the menu item will appear disabled and it will not respond to clicks or mouse hovers.\n *\n * @default false\n */\n isDisabled?: boolean;\n\n /**\n * If true, compact vertical padding designed for keyboard and mouse input is used.\n *\n * @default true\n */\n isDense?: boolean;\n\n /**\n * If true, a right-arrow icon will be displayed (iconPathAfter, if specified, will be ignored).\n *\n * @default false\n */\n isSubMenuParent?: boolean;\n\n /**\n * If true, the left and right padding is removed\n *\n * @default false\n */\n hasDisabledGutters?: boolean;\n\n /**\n * If true, a 1px light border is added to bottom of menu item\n *\n * @default false\n */\n hasDivider?: boolean;\n\n /** Help identify which element has keyboard focus */\n focusVisibleClassName?: string;\n\n /** If it's a submenu, it should have the items property */\n items?: MenuItemInfo[];\n};\n\nfunction getIcon(icon: string | undefined, menuLabel: string, leading: boolean) {\n return icon ? (\n \n {`${leading\n \n ) : undefined;\n}\n\nexport default function MenuItem(props: MenuItemProps) {\n const {\n onClick,\n label,\n tooltip,\n allowForLeadingIcons = true,\n iconPathBefore = undefined,\n iconPathAfter = undefined,\n hasAutoFocus = false,\n className,\n isDisabled = false,\n isDense = true,\n isSubMenuParent = false,\n hasDisabledGutters = false,\n hasDivider = false,\n focusVisibleClassName,\n id,\n children,\n } = props;\n\n const menuItem = (\n \n {label ? (\n <>\n {getIcon(iconPathBefore, label, true)}\n \n {isSubMenuParent ? (\n \n \n \n ) : (\n getIcon(iconPathAfter, label, false)\n )}\n \n ) : (\n children\n )}\n \n );\n\n return tooltip ? (\n \n
{menuItem}
\n
\n ) : (\n menuItem\n );\n}\n","import MenuItem, {\n MenuItemListProps,\n MenuItemProps,\n MenuPropsBase,\n} from '@/components/mui/menu-item.component';\nimport { Menu } from '@mui/material';\nimport {\n Localized,\n MenuGroupDetailsInSubMenu,\n MenuItemContainingCommand,\n MenuItemContainingSubmenu,\n OrderedExtensibleContainer,\n ReferencedItem,\n SingleColumnMenu,\n} from 'platform-bible-utils';\nimport { MouseEvent, useMemo, useState } from 'react';\n\n/**\n * All the exported types in this file should be regarded as \"internal\" (i.e., they should not be\n * exposed via index.ts).\n */\n\nexport type GroupedMenuPropsBase = MenuPropsBase & {\n /** Optional unique (column) identifier */\n columnId?: ReferencedItem;\n};\n\nexport type GroupedMenuItemListProps = MenuItemListProps & {\n /**\n * If the menuDefinition includes \"top-level\" groups (i.e., those that belong to a column as\n * opposed to those that belong to a submenu) that should not be included in the list, then this\n * array specifies which groups to include. Likewise, for a submenu, this list indicates which\n * groups are pertinent for that submenu. So then for a context menu this property need not be\n * specified since it is a top-level menu based on a \"true\" SingleColumnMenu (i.e., one that is\n * not a MultiColumnMenu).\n */\n includedGroups?: {\n id: string;\n group: Localized;\n }[];\n};\n\ninterface ItemInfo {\n item: Localized;\n isLastItemInGroup: boolean;\n}\n\ntype SubMenuProps = MenuPropsBase & {\n parentMenuItem: Localized;\n parentItemProps: Omit, 'iconPathAfter'>;\n};\n\nfunction getAllGroups(menuDefinition: Localized) {\n const groupEntries = Object.entries(menuDefinition.groups);\n // Convert array of entries to array of objects with id and group properties\n return groupEntries.map(([key, value]) => ({ id: key, group: value }));\n}\n\nfunction SubMenu(props: SubMenuProps) {\n const [anchorEl, setAnchorEl] = useState(undefined);\n\n const { parentMenuItem, parentItemProps, menuDefinition } = props;\n\n const handleParentMenuItemClick = (event: MouseEvent) => {\n setAnchorEl(event.currentTarget);\n };\n\n const handleClose = () => {\n setAnchorEl(undefined);\n };\n\n const renderSubMenuItems = () => {\n let includedGroups = getAllGroups(menuDefinition).filter((g) => 'menuItem' in g.group);\n\n // Ensure valid parent menu was provided. (If not, submenu will contain all groups!)\n if (!parentMenuItem?.id) throw new Error('A valid parent menu item is required for submenus.');\n\n // When laying out a submenu, only include groups associated with the provided parent menu.\n // Note: without the (annoying) redundant check that the included groups\n // have the menuItem field, TS doesn't think it exists.\n includedGroups = includedGroups.filter(\n (group) => 'menuItem' in group.group && group.group.menuItem === parentMenuItem.id,\n );\n\n return ;\n };\n\n return (\n <>\n \n \n {renderSubMenuItems()}\n \n \n );\n}\n\nconst getOrderedGroupItems = (\n groupId: string,\n allItems: Localized[],\n) => {\n // Filter items that belong to the specified group\n const itemsForGroup = allItems.filter((item) => item.group === groupId);\n // Sort items based on order\n const sortedItems = itemsForGroup.sort((a, b) => (a.order || 0) - (b.order || 0));\n return sortedItems;\n};\n\n/**\n * This component is internal; it does not need to be exposed to the outside world since it is not\n * useful on its own. It is used to generate and lay out the MenuItems that appear either on a\n * top-level menu (in a GridMenu or ContextMenu) or in a submenu.\n */\nexport default function GroupedMenuItemList(menuProps: GroupedMenuItemListProps) {\n const { menuDefinition, onClick, commandHandler, includedGroups } = menuProps;\n\n const { items, allowForLeadingIcons } = useMemo(() => {\n const groupsToInclude =\n includedGroups && includedGroups.length > 0\n ? includedGroups\n : // We're apparently laying out a single-column menu (presumably a context menu). In this\n // case, all groups should be included except ones that belong to a submenu.\n getAllGroups(menuDefinition).filter((g) => !('menuItem' in g.group));\n\n const sortedGroups = Object.values(groupsToInclude).sort(\n (a, b) => (a.group.order || 0) - (b.group.order || 0),\n );\n\n const itemArray: ItemInfo[] = [];\n\n sortedGroups.forEach((group) => {\n getOrderedGroupItems(group.id, menuDefinition.items).forEach((item) =>\n itemArray.push({ item, isLastItemInGroup: false }),\n );\n if (itemArray.length > 0) itemArray[itemArray.length - 1].isLastItemInGroup = true;\n });\n\n // No divider after last item in final group.\n if (itemArray.length > 0) itemArray[itemArray.length - 1].isLastItemInGroup = false;\n\n const allowSpaceForLeadingIcons = itemArray.some(\n (i) => 'iconPathBefore' in i.item && i.item.iconPathBefore,\n );\n\n return { items: itemArray, allowForLeadingIcons: allowSpaceForLeadingIcons };\n }, [includedGroups, menuDefinition]);\n\n // Create props for MenuItem component including setting hasDivider for the last item in a group\n const createMenuItemProps = ({ item, isLastItemInGroup }: ItemInfo) => {\n const menuItemProps = {\n className: 'papi-menu-item',\n label: item.label,\n tooltip: item.tooltip,\n iconPathBefore: 'iconPathBefore' in item ? item.iconPathBefore : undefined,\n iconPathAfter: 'iconPathAfter' in item ? item.iconPathAfter : undefined,\n hasDivider: isLastItemInGroup, // Set hasDivider to true for the last item in a group\n allowForLeadingIcons,\n };\n\n return menuItemProps;\n };\n\n const [firstItem] = items;\n\n if (!firstItem) return
;\n\n const divKey = firstItem.item.group;\n\n return (\n
\n {items.map((itemInfo, index) => {\n const { item } = itemInfo;\n const menuItemProps = createMenuItemProps(itemInfo);\n if ('command' in item) {\n const key = item.group + index;\n return (\n ) => {\n onClick?.(event);\n commandHandler(item);\n }}\n {...menuItemProps}\n />\n );\n }\n return (\n \n );\n })}\n
\n );\n}\n","import GroupedMenuItemList from '@/components/mui/grouped-menu-item-list.component';\nimport { MenuItemListProps } from '@/components/mui/menu-item.component';\nimport { MultiColumnMenu } from 'platform-bible-utils';\n\n/**\n * This component is internal; it does not need to be exposed to the outside world since it is not\n * useful on its own. Use either GridMenu or ContextMenu.\n */\nexport default function TopLevelMenu(props: MenuItemListProps) {\n const { menuDefinition, columnId } = props;\n\n const groupEntries = Object.entries(menuDefinition.groups);\n // Convert array of entries to array of objects with id and group properties\n const groups = groupEntries.map(([key, value]) => ({ id: key, group: value }));\n let includedGroups = groups.filter((g) => 'column' in g.group);\n\n // Check if column is provided and menuDefinition is a MultiColumnMenu\n if (\n columnId &&\n 'columns' in menuDefinition &&\n // Without this type assertion, TS doesn't know what columns is.\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n (menuDefinition as MultiColumnMenu).columns[columnId]\n ) {\n // When laying out a single column in a MultiColumnMenu, only include groups associated with\n // the provided column. Note: without the (annoying) redundant check that the included groups\n // have the colum field, TS doesn't think it exists.\n includedGroups = includedGroups.filter(\n (g) => 'column' in g.group && g.group.column === columnId,\n );\n }\n\n return ;\n}\n","import '@/components/mui/grid-menu.component.css';\nimport { GroupedMenuPropsBase } from '@/components/mui/grouped-menu-item-list.component';\nimport { CommandHandler } from '@/components/mui/menu-item.component';\nimport TopLevelMenu from '@/components/mui/top-level-menu.component';\nimport { Grid, List } from '@mui/material';\nimport {\n Localized,\n MenuColumnWithHeader,\n MultiColumnMenu,\n ReferencedItem,\n} from 'platform-bible-utils';\nimport { useMemo } from 'react';\n\ntype ColumnInfo = {\n /*\n * The ID (`${string}.${string}`) of a specific menu column.\n */\n id: ReferencedItem;\n\n /*\n * Metadata (label, order, etc.) for a specific menu column.\n */\n metadata: Localized;\n};\n\ntype MenuColumnProps = ColumnInfo &\n GroupedMenuPropsBase & {\n /** Additional css classes to help with unique styling of the menu column */\n className?: string;\n };\n\nexport type GridMenuInfo = {\n /** The menu object containing information about the columns, groups, and items to display. */\n multiColumnMenu: Localized;\n};\n\nexport type GridMenuProps = GridMenuInfo & {\n /** Optional unique identifier */\n id?: string;\n\n commandHandler: CommandHandler;\n\n /** Additional css classes to help with unique styling of the grid menu */\n className?: string;\n};\n\nfunction MenuColumn({\n commandHandler,\n menuDefinition,\n id,\n metadata,\n onClick,\n className,\n}: MenuColumnProps) {\n return (\n \n

\n {metadata.label}\n

\n {/* It would seem as though this List component were unnecessary, since it only contains one\n thing, but the \"dense\" property does affect the layout of the items (in a way I don't fully\n understand). There might be a better way. */}\n \n \n \n \n );\n}\n\nexport default function GridMenu({\n commandHandler,\n className,\n multiColumnMenu,\n id,\n}: GridMenuProps) {\n const { columns } = multiColumnMenu;\n\n const sortedColumns = useMemo(() => {\n const columnNumbers = new Map();\n Object.getOwnPropertyNames(columns).forEach((columnName: string) => {\n // We know for sure there is a (boolean) property 'isExtensible' that we are not interested in.\n if (columnName === 'isExtensible') return;\n // TS doesn't allow `columnName` above to be a ReferencedItem even though the type says it is\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const columnId = columnName as ReferencedItem;\n const column = columns[columnId];\n // As of right now (and hopefully forever after), all remaining properties of the\n // ColumnsWithHeaders object are columns whose property names are the IDs of the columns.\n // This is an additional (redundant) sanity check. Specifically we're interested in\n // MenuColumnWithHeader objects, which TypeScript now \"knows\" we have, but at runtime all we\n // can check for is that it's an object with a valid numeric order field. That's likely good\n // enough.\n if (\n typeof column === 'object' &&\n typeof column.order === 'number' &&\n !Number.isNaN(column.order)\n )\n columnNumbers.set(column.order, { id: columnId, metadata: column });\n else\n console.warn(\n `Property ${columnName} (${typeof column}) on menu ${id} is not a valid column and is being ignored. This might indicate data corruption`,\n );\n });\n\n // Extract values and sort them based on the 'order' property\n return Array.from(columnNumbers.values()).sort((a, b) => {\n return (a.metadata.order || 0) - (b.metadata.order || 0);\n });\n }, [columns, id]);\n\n // We might need something like this if we need to be able to prevent empty columns\n // sortedColumns.filter((c) => multiColumnMenu.groups.some((g) => 'column' in g && (g as .column)...\n\n return (\n \n {sortedColumns.map((col, index) => (\n \n ))}\n \n );\n}\n","import { useEffect, useRef, useState } from 'react';\n\nexport type UsePromiseOptions = {\n /**\n * Whether to leave the value as the most recent resolved promise value or set it back to\n * defaultValue while running the promise again. Defaults to true\n */\n preserveValue?: boolean;\n};\n\n/** Set up defaults for options for usePromise hook */\nfunction getUsePromiseOptionsDefaults(options: UsePromiseOptions): UsePromiseOptions {\n return {\n preserveValue: true,\n ...options,\n };\n}\n\n/**\n * Awaits a promise and returns a loading value while the promise is unresolved\n *\n * @param promiseFactoryCallback A function that returns the promise to await. If this callback is\n * undefined, the current value will be returned (defaultValue unless it was previously changed\n * and `options.preserveValue` is true), and there will be no loading.\n *\n * WARNING: MUST BE STABLE - const or wrapped in useCallback. The reference must not be updated\n * every render\n * @param defaultValue The initial value to return while first awaiting the promise. If\n * `options.preserveValue` is false, this value is also shown while awaiting the promise on\n * subsequent calls.\n *\n * Note: this parameter is internally assigned to a `ref`, so changing it will not cause any hooks\n * to re-run with its new value. This means that, if the `promiseFactoryCallback` changes and\n * `options.preserveValue` is `false`, the returned value will be set to the current\n * `defaultValue`. However, the returned value will not be updated if`defaultValue` changes.\n * @param options Various options for adjusting how this hook runs the `promiseFactoryCallback`\n *\n * Note: this parameter is internally assigned to a `ref`, so changing it will not cause any hooks\n * to re-run with its new value. However, the latest `options.preserveValue` will always be used\n * appropriately to determine whether to preserve the returned value when changing the\n * `promiseFactoryCallback`\n * @returns `[value, isLoading]`\n *\n * - `value`: the current value for the promise, either the defaultValue or the resolved promise value\n * - `isLoading`: whether the promise is waiting to be resolved\n */\nconst usePromise = (\n promiseFactoryCallback: (() => Promise) | undefined,\n defaultValue: T,\n options: UsePromiseOptions = {},\n): [value: T, isLoading: boolean] => {\n // Use defaultValue as a ref so it doesn't update dependency arrays\n const defaultValueRef = useRef(defaultValue);\n defaultValueRef.current = defaultValue;\n // Use options as a ref so it doesn't update dependency arrays\n const optionsDefaultedRef = useRef(options);\n optionsDefaultedRef.current = getUsePromiseOptionsDefaults(optionsDefaultedRef.current);\n\n const [value, setValue] = useState(() => defaultValueRef.current);\n const [isLoading, setIsLoading] = useState(true);\n useEffect(() => {\n let promiseIsCurrent = true;\n // If a promiseFactoryCallback was provided, we are loading. Otherwise, there is no loading to do\n setIsLoading(!!promiseFactoryCallback);\n (async () => {\n // If there is a callback to run, run it\n if (promiseFactoryCallback) {\n const result = await promiseFactoryCallback();\n // If the promise was not already replaced, update the value\n if (promiseIsCurrent) {\n setValue(() => result);\n setIsLoading(false);\n }\n }\n })();\n\n return () => {\n // Mark this promise as old and not to be used\n promiseIsCurrent = false;\n if (!optionsDefaultedRef.current.preserveValue) setValue(() => defaultValueRef.current);\n };\n }, [promiseFactoryCallback]);\n\n return [value, isLoading];\n};\nexport default usePromise;\n","\"use client\";\n\nimport createSvgIcon from './utils/createSvgIcon';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nexport default createSvgIcon( /*#__PURE__*/_jsx(\"path\", {\n d: \"M3 18h18v-2H3zm0-5h18v-2H3zm0-7v2h18V6z\"\n}), 'Menu');","import GridMenu from '@/components/mui/grid-menu.component';\nimport { Command, CommandHandler } from '@/components/mui/menu-item.component';\nimport usePromise from '@/hooks/use-promise.hook';\nimport { Menu as MenuIcon } from '@mui/icons-material';\nimport { Drawer, IconButton } from '@mui/material';\nimport { Localized, MultiColumnMenu } from 'platform-bible-utils';\nimport {\n MouseEvent,\n MutableRefObject,\n PropsWithChildren,\n useCallback,\n useEffect,\n useState,\n} from 'react';\n\nexport interface MultiColumnMenuProvider {\n (isSupportAndDevelopment: boolean): Promise>;\n}\n\nexport type HamburgerMenuButtonProps = PropsWithChildren & {\n /** The handler to use for menu commands (and eventually toolbar commands). */\n commandHandler: CommandHandler;\n\n /**\n * Optional reference to the \"div\" container that determines the where the menu should appear. If\n * not defined, then (1,1) used.\n */\n containerRef?: MutableRefObject;\n\n /**\n * The delegate to use to get the menu data. If not specified or if it returns undefined, the data\n * in normalMenu or fullMenu property will be used.\n */\n menuProvider?: MultiColumnMenuProvider;\n\n /**\n * The menu data to show when the menu is opened if the menuProvider property is not defined.\n * (This allows for a default or test-only static menu to be used.)\n */\n normalMenu?: Localized;\n\n /**\n * The menu data to show for \"full\" menu (when opened with the SHIFT key pressed) if the\n * menuProvider property is not defined. (This allows for a default or test-only static menu to be\n * used.)\n */\n fullMenu?: Localized;\n\n /** Additional css class(es) to help with unique styling of the sub-components */\n className?: string;\n\n /** Value to use as prefix for ARIA labels on interactive sub-components */\n ariaLabelPrefix?: string;\n};\n\nexport default function HamburgerMenuButton({\n menuProvider,\n normalMenu,\n fullMenu,\n commandHandler,\n containerRef,\n className,\n ariaLabelPrefix,\n children,\n}: HamburgerMenuButtonProps) {\n const [isMenuOpen, setMenuOpen] = useState(false);\n const [showFullMenu, setShowFullMenu] = useState(false);\n\n const handleMenuItemClick = useCallback(() => {\n if (isMenuOpen) setMenuOpen(false);\n setShowFullMenu(false);\n }, [isMenuOpen]);\n\n const handleMenuButtonClick = useCallback((e: MouseEvent) => {\n e.stopPropagation();\n setMenuOpen((prevIsOpen) => {\n const isOpening = !prevIsOpen;\n if (isOpening && e.shiftKey) setShowFullMenu(true);\n else if (!isOpening) setShowFullMenu(false);\n return isOpening;\n });\n }, []);\n\n const menuCommandHandler = useCallback(\n (command: Command) => {\n handleMenuItemClick();\n return commandHandler(command);\n },\n [commandHandler, handleMenuItemClick],\n );\n\n const [offset, setOffset] = useState({ top: 1, left: 1 });\n\n useEffect(() => {\n if (isMenuOpen) {\n const node = containerRef?.current;\n if (node) {\n const rect = node.getBoundingClientRect();\n const scrollTop = window.scrollY;\n const scrollLeft = window.scrollX;\n const top = rect.top + scrollTop + node.clientHeight;\n const left = rect.left + scrollLeft;\n setOffset({ top, left });\n }\n }\n }, [isMenuOpen, containerRef]);\n\n const [normalMenuData] = usePromise(\n useCallback(async () => {\n return menuProvider?.(false) ?? normalMenu;\n // isMenuOpen needs to be included for the menu contents to reevaluate when reopened\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [menuProvider, normalMenu, isMenuOpen]),\n normalMenu,\n );\n\n const [fullMenuData] = usePromise(\n useCallback(async () => {\n return menuProvider?.(true) ?? fullMenu ?? normalMenuData;\n // isMenuOpen needs to be included for the menu contents to reevaluate when reopened\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [menuProvider, fullMenu, normalMenuData, isMenuOpen]),\n fullMenu ?? normalMenuData,\n );\n\n const menu = showFullMenu && fullMenuData ? fullMenuData : normalMenuData;\n\n return (\n <>\n \n {children ?? }\n \n \n {menu ? (\n \n ) : undefined}\n \n \n );\n}\n","import '@/components/mui/icon-button.component.css';\nimport { IconButton as MuiIconButton } from '@mui/material';\nimport { MouseEventHandler, PropsWithChildren } from 'react';\n\nexport type IconButtonProps = PropsWithChildren<{\n /** Optional unique identifier */\n id?: string;\n /**\n * Required. Used as both the tooltip (aka, title) and the aria-label (used for accessibility,\n * testing, etc.), unless a distinct tooltip is supplied.\n */\n label: string;\n /**\n * Enabled status of button\n *\n * @default false\n */\n isDisabled?: boolean;\n /** Optional tooltip to display if different from the aria-label. */\n tooltip?: string;\n /** If true, no tooltip will be displayed. */\n isTooltipSuppressed?: boolean;\n /**\n * If given, uses a negative margin to counteract the padding on one side (this is often helpful\n * for aligning the left or right side of the icon with content above or below, without ruining\n * the border size and shape).\n *\n * @default false\n */\n adjustMarginToAlignToEdge?: 'end' | 'start' | false;\n /**\n * The size of the component. small is equivalent to the dense button styling.\n *\n * @default false\n */\n size: 'small' | 'medium' | 'large';\n /** Additional css classes to help with unique styling of the button */\n className?: string;\n /** Optional click handler */\n onClick?: MouseEventHandler;\n}>;\n\n/**\n * Iconic button a user can click to do something\n *\n * Thanks to MUI for heavy inspiration and documentation\n * https://mui.com/material-ui/getting-started/overview/\n */\nfunction IconButton({\n id,\n label,\n isDisabled = false,\n tooltip,\n isTooltipSuppressed = false,\n adjustMarginToAlignToEdge = false,\n size = 'medium',\n className,\n onClick,\n children,\n}: IconButtonProps) {\n return (\n \n {children /* the icon to display */}\n \n );\n}\n\nexport default IconButton;\n","import { cn } from '@/utils/shadcn-ui.util';\nimport { LoaderCircle, LucideProps } from 'lucide-react';\nimport { forwardRef } from 'react';\n\nexport type SpinnerProps = LucideProps;\n\nconst Spinner = forwardRef(({ className, ...props }, ref) => {\n return (\n \n );\n});\n\nSpinner.displayName = 'Spinner';\n\nexport default Spinner;\n","import { Input as ShadInput } from '@/components/shadcn-ui/input';\nimport { Label as ShadLabel } from '@/components/shadcn-ui/label';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { ChangeEventHandler, FocusEventHandler } from 'react';\n\nexport type TextFieldProps = {\n /** Optional unique identifier */\n id?: string;\n /**\n * If `true`, the component is disabled.\n *\n * @default false\n */\n isDisabled?: boolean;\n /**\n * If `true`, the label is displayed in an error state.\n *\n * @default false\n */\n hasError?: boolean;\n /**\n * If `true`, the input will take up the full width of its container.\n *\n * @default false\n */\n isFullWidth?: boolean;\n /** Text that gives the user instructions on what contents the TextField expects */\n helperText?: string;\n /** The title of the TextField */\n label?: string;\n /** The short hint displayed in the `input` before the user enters a value. */\n placeholder?: string;\n /**\n * If `true`, the label is displayed as required and the `input` element is required.\n *\n * @default false\n */\n isRequired?: boolean;\n /** Additional css classes to help with unique styling of the text field */\n className?: string;\n /** Starting value for the text field if it is not controlled */\n defaultValue?: string | number;\n /** Value of the text field if controlled */\n value?: string | number;\n /** Triggers when content of textfield is changed */\n onChange?: ChangeEventHandler;\n /** Triggers when textfield gets focus */\n onFocus?: FocusEventHandler;\n /** Triggers when textfield loses focus */\n onBlur?: FocusEventHandler;\n};\n\n/**\n * Text input field\n *\n * Thanks to Shadcn for heavy inspiration and documentation\n * https://ui.shadcn.com/docs/components/input#with-label\n */\nfunction TextField({\n id,\n isDisabled = false,\n hasError = false,\n isFullWidth = false,\n helperText,\n label,\n placeholder,\n isRequired = false,\n className,\n defaultValue,\n value,\n onChange,\n onFocus,\n onBlur,\n}: TextFieldProps) {\n return (\n
\n {`${label}${isRequired ? '*' : ''}`}\n \n

{helperText}

\n
\n );\n}\n\nexport default TextField;\n","import HamburgerMenuButton, {\n MultiColumnMenuProvider,\n} from '@/components/mui/hamburger-menu-button.component';\nimport { CommandHandler } from '@/components/mui/menu-item.component';\nimport '@/components/mui/toolbar.component.css';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { AppBar, Toolbar as MuiToolbar } from '@mui/material';\nimport { PropsWithChildren, useRef } from 'react';\n\nexport type ToolbarProps = PropsWithChildren<{\n /** The handler to use for menu commands (and eventually toolbar commands). */\n commandHandler: CommandHandler;\n\n /**\n * The optional delegate to use to get the menu data. If not specified, the \"hamburger\" menu will\n * not display.\n */\n menuProvider?: MultiColumnMenuProvider;\n\n /** Optional unique identifier */\n id?: string;\n\n /** Additional css classes to help with unique styling of the toolbar */\n className?: string;\n}>;\n\nexport default function Toolbar({\n menuProvider,\n commandHandler,\n className,\n id,\n children,\n}: ToolbarProps) {\n // This ref will always be defined\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const containerRef = useRef(undefined!);\n\n return (\n
\n \n \n {menuProvider ? (\n \n ) : undefined}\n {children ?
{children}
: undefined}\n \n
\n
\n );\n}\n","import React from 'react';\nimport { cva, type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst alertVariants = cva(\n 'tw-relative tw-w-full tw-rounded-lg tw-border tw-p-4 [&>svg~*]:tw-pl-7 [&>svg+div]:tw-translate-y-[-3px] [&>svg]:tw-absolute [&>svg]:tw-left-4 [&>svg]:tw-top-4 [&>svg]:tw-text-foreground',\n {\n variants: {\n variant: {\n default: 'tw-bg-background tw-text-foreground',\n destructive:\n 'tw-border-destructive/50 tw-text-destructive dark:tw-border-destructive [&>svg]:tw-text-destructive',\n },\n },\n defaultVariants: {\n variant: 'default',\n },\n },\n);\n\nconst Alert = React.forwardRef<\n HTMLDivElement,\n React.HTMLAttributes & VariantProps\n>(({ className, variant, ...props }, ref) => (\n
\n));\nAlert.displayName = 'Alert';\n\nconst AlertTitle = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n {/* added because of https://github.com/jsx-eslint/eslint-plugin-jsx-a11y/blob/main/docs/rules/heading-has-content.md */}\n {props.children}{' '}\n \n ),\n);\nAlertTitle.displayName = 'AlertTitle';\n\nconst AlertDescription = React.forwardRef<\n HTMLParagraphElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n
\n));\nAlertDescription.displayName = 'AlertDescription';\n\nexport { Alert, AlertTitle, AlertDescription };\n","import React from 'react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Card = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nCard.displayName = 'Card';\n\nconst CardHeader = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nCardHeader.displayName = 'CardHeader';\n\nconst CardTitle = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n {/* added because of https://github.com/jsx-eslint/eslint-plugin-jsx-a11y/blob/main/docs/rules/heading-has-content.md */}\n {props.children}\n \n ),\n);\nCardTitle.displayName = 'CardTitle';\n\nconst CardDescription = React.forwardRef<\n HTMLParagraphElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n

\n));\nCardDescription.displayName = 'CardDescription';\n\nconst CardContent = React.forwardRef>(\n ({ className, ...props }, ref) => (\n

\n ),\n);\nCardContent.displayName = 'CardContent';\n\nconst CardFooter = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nCardFooter.displayName = 'CardFooter';\n\nexport { Card, CardHeader, CardFooter, CardTitle, CardDescription, CardContent };\n","import { ComponentProps } from 'react';\nimport { toast as sonner, Toaster } from 'sonner';\n\ntype SonnerProps = ComponentProps;\n\nfunction Sonner({ ...props }: SonnerProps) {\n return (\n \n );\n}\n\n// The re-export of the sonner function was added manually\nexport { Sonner, sonner };\n","import React from 'react';\nimport * as SliderPrimitive from '@radix-ui/react-slider';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Slider = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n \n \n \n));\nSlider.displayName = SliderPrimitive.Root.displayName;\n\nexport { Slider };\n","import React from 'react';\nimport * as SwitchPrimitives from '@radix-ui/react-switch';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Switch = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n));\nSwitch.displayName = SwitchPrimitives.Root.displayName;\n\nexport { Switch };\n","import React from 'react';\nimport * as TabsPrimitive from '@radix-ui/react-tabs';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport const Tabs = TabsPrimitive.Root;\n\nexport type TabsListProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport type TabsTriggerProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport type TabsContentProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport const TabsList = React.forwardRef<\n React.ElementRef,\n TabsListProps\n>(({ className, ...props }, ref) => (\n \n));\nTabsList.displayName = TabsPrimitive.List.displayName;\n\nexport const TabsTrigger = React.forwardRef<\n React.ElementRef,\n TabsTriggerProps\n>(({ className, ...props }, ref) => (\n \n));\nTabsTrigger.displayName = TabsPrimitive.Trigger.displayName;\n\nexport const TabsContent = React.forwardRef<\n React.ElementRef,\n TabsContentProps\n>(({ className, ...props }, ref) => (\n \n));\nTabsContent.displayName = TabsPrimitive.Content.displayName;\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Download } from 'lucide-react';\n\ntype InstallButtonProps = {\n /** The installing boolean value determines the state of the button. */\n isInstalling: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n /** Optional text for the button. */\n buttonText?: string;\n} & ButtonProps;\n\n/**\n * The InstallButton component is a button designed for initiating installs. It includes visuals for\n * active installing and idle states.\n *\n * @param isInstalling The installing boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @param buttonText Optional text for the button.\n * @returns A install button.\n */\nexport default function InstallButton({\n isInstalling,\n handleClick,\n buttonText,\n className,\n ...props\n}: InstallButtonProps) {\n return (\n \n {isInstalling ? (\n \n ) : (\n <>\n \n {buttonText}\n \n )}\n \n );\n}\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\n\ntype EnableButtonProps = {\n /** The enabling boolean value determines the state of the button. */\n isEnabling: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n} & ButtonProps;\n\n/**\n * The EnableButton component is a button designed for initiating enabling of downloads. It includes\n * visuals for active enabling and idle states.\n *\n * @param isEnabling The enabling boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @returns A button that can be used to enable.\n */\nexport default function EnableButton({\n isEnabling,\n handleClick,\n className,\n ...props\n}: EnableButtonProps) {\n return (\n \n {isEnabling ? (\n <>\n \n Enabling...\n \n ) : (\n 'Enable'\n )}\n \n );\n}\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\n\ntype DisableButtonProps = {\n /** The disabling boolean value determines the state of the button. */\n isDisabling: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n} & ButtonProps;\n\n/**\n * The DisableButton component is a button designed for initiating disabling of downloads. It\n * includes visuals for active disabling and idle states.\n *\n * @param isDisabling The disabling boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @returns A button that can be used to disable.\n */\nexport default function DisableButton({\n isDisabling,\n handleClick,\n className,\n ...props\n}: DisableButtonProps) {\n return (\n \n {isDisabling ? (\n <>\n \n Disabling...\n \n ) : (\n 'Disable'\n )}\n \n );\n}\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\n\ntype UpdateButtonProps = {\n /** The updating boolean value determines the state of the button. */\n isUpdating: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n} & ButtonProps;\n\n/**\n * The UpdateButton component is a button designed for initiating updates for downloaded extensions.\n * It includes visuals for active updating and idle states.\n *\n * @param isUpdating The updating boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @returns A button that can be used to update.\n */\nexport default function UpdateButton({\n isUpdating,\n handleClick,\n className,\n ...props\n}: UpdateButtonProps) {\n return (\n \n {isUpdating ? (\n <>\n \n Updating...\n \n ) : (\n 'Update'\n )}\n \n );\n}\n","import { cn } from '@/utils/shadcn-ui.util';\nimport Markdown, { MarkdownToJSX } from 'markdown-to-jsx';\nimport { useMemo } from 'react';\n\ninterface MarkdownRendererProps {\n /** Optional unique identifier */\n id?: string;\n /** The markdown string to render */\n markdown: string;\n className?: string;\n /**\n * The [`target` attribute for `a` html\n * tags](https://developer.mozilla.org/en-US/docs/Web/HTML/Element/a#target). Defaults to not\n * adding a `target` to `a` tags\n */\n anchorTarget?: string;\n}\n\n/**\n * This component renders markdown content given a markdown string. It uses typography styles from\n * the platform.\n *\n * @param markdown The markdown string to render.\n * @param id Optional unique identifier\n * @returns A div containing the rendered markdown content.\n */\nexport default function MarkdownRenderer({\n id,\n markdown,\n className,\n anchorTarget,\n}: MarkdownRendererProps) {\n const options: MarkdownToJSX.Options = useMemo(\n () => ({\n overrides: {\n a: {\n props: {\n target: anchorTarget,\n },\n },\n },\n }),\n [anchorTarget],\n );\n return (\n
\n {markdown}\n
\n );\n}\n","import { Filter, ChevronDown } from 'lucide-react';\nimport { forwardRef } from 'react';\nimport { Button } from '@/components/shadcn-ui/button';\n\n/**\n * The FilterButton component is a button designed for initiating filtering of data. It is designed\n * to be used with the dropdown menu. It uses forwardRef to pass the button to the dropdown trigger\n * asChild.\n *\n * @returns A button that can be used to filter.\n */\nconst FilterButton = forwardRef((props, ref) => {\n return (\n \n \n Filter\n \n \n );\n});\n\nexport default FilterButton;\n","import {\n DropdownMenu,\n DropdownMenuTrigger,\n DropdownMenuContent,\n DropdownMenuLabel,\n DropdownMenuGroup,\n DropdownMenuCheckboxItem,\n DropdownMenuRadioItem,\n DropdownMenuSeparator,\n} from '@/components/shadcn-ui/dropdown-menu';\nimport FilterButton from './buttons/filter-button.component';\n\nexport enum DropdownMenuItemType {\n Check,\n Radio,\n}\n\nexport type DropdownItem = {\n /** The label is the text that will be displayed on the dropdown item. */\n label: string;\n /** The itemType determines the DropdownMenuItemType type as either Check or Radio. */\n itemType: DropdownMenuItemType;\n /** The onClick function is called when the item is clicked. */\n onClick: () => void;\n};\n\nexport type DropdownGroup = {\n /**\n * The label is the text that will be displayed on the dropdown group. It is used to categorize\n * the items in the group.\n */\n label: string;\n /** The items array contains the items that will be displayed in the dropdown group */\n items: DropdownItem[];\n};\n\nexport type FilterDropdownProps = {\n /** Object unique identifier */\n id?: string;\n /** The groups array contains the groups that will be displayed in the dropdown */\n groups: DropdownGroup[];\n}; // TODO: extend the props later\n\n/**\n * The FilterDropdown component is a dropdown designed for filtering content. It includes groups of\n * items that can be checkboxes or radio items.\n *\n * @param id Optional unique identifier\n * @param groups The groups array contains the groups that will be displayed in the dropdown\n * @returns A filter dropdown.\n */\nexport default function FilterDropdown({ id, groups }: FilterDropdownProps) {\n return (\n
\n {/* TODO: remove this once the DropDown Menu shadcn has an id prop */}\n \n \n \n \n \n {groups.map((group) => (\n
\n {group.label}\n \n {group.items.map((item) => (\n
\n {item.itemType === DropdownMenuItemType.Check ? (\n \n {item.label}\n \n ) : (\n \n {item.label}\n \n )}\n
\n ))}\n
\n \n
\n ))}\n
\n
\n
\n );\n}\n","interface NoExtensionsFoundProps {\n /** Optional unique identifier */\n id?: string;\n /** The message to display */\n message: string;\n}\n/**\n * This component displays a message to the user when no extensions are found in the marketplace.\n *\n * @param id Optional unique identifier\n * @param message The message to display.\n * @returns {JSX.Element} - Returns the message component that displays the message to the user.\n */\nexport default function NoExtensionsFound({ id, message }: NoExtensionsFoundProps) {\n return (\n
\n
\n

{message}

\n
\n
\n );\n}\n","import { CircleHelp, Link as LucideLink, User } from 'lucide-react';\nimport { NumberFormat } from 'platform-bible-utils';\n\n/** Interface that stores the parameters passed to the More Info component */\ninterface MoreInfoProps {\n /** Optional unique identifier */\n id?: string;\n /** The category of the extension */\n category: string;\n /** The number of downloads for the extension */\n downloads: Record;\n /** The languages supported by the extension */\n languages: string[];\n /** The URL to the more info page of the extension */\n moreInfoUrl: string;\n}\n/**\n * This component displays the more info section of the extension which includes the category,\n * number of downloads, languages, and links to the website and support\n *\n * @param id Optional unique identifier\n * @param category The category of the extension\n * @param downloads The number of downloads for the extension\n * @param languages The languages supported by the extension\n * @param moreInfoUrl The URL to the more info page of the extension\n * @returns {JSX.Element} - Returns the more info component that displays the category, number of\n * downloads, languages, and links to the website and support\n */\nexport default function MoreInfo({\n id,\n category,\n downloads,\n languages,\n moreInfoUrl,\n}: MoreInfoProps) {\n /**\n * This constant formats the number of downloads into a more readable format.\n *\n * @example 1000 -> 1K\n *\n * @example 1000000 -> 1M\n *\n * @returns The formatted number of downloads\n */\n const numberFormatted = new NumberFormat('en', {\n notation: 'compact',\n compactDisplay: 'short',\n }).format(Object.values(downloads).reduce((a: number, b: number) => a + b, 0));\n\n /** This function scrolls the window to the bottom of the page. */\n const handleScrollToBottom = () => {\n window.scrollTo(0, document.body.scrollHeight);\n };\n\n return (\n \n
\n
\n {category}\n
\n CATEGORY\n
\n
\n
\n
\n \n {numberFormatted}\n
\n USERS\n
\n
\n
\n
\n {languages.slice(0, 3).map((locale) => (\n \n {locale.toUpperCase()}\n \n ))}\n
\n {languages.length > 3 && (\n handleScrollToBottom()}\n className=\"tw-text-xs tw-text-gray-500 tw-underline\"\n >\n +{languages.length - 3} more languages\n \n )}\n
\n
\n
\n \n Website\n \n \n \n Support\n \n \n
\n
\n );\n}\n","import { useState } from 'react';\n\nexport type VersionInformation = {\n /** Date the version was published */\n date: string;\n /** Description of the changes in the version */\n description: string;\n};\n\n/** Type to store the version history information */\nexport type VersionHistoryType = Record;\n\n/** Interface that stores the parameters passed to the Version History component */\ninterface VersionHistoryProps {\n /** Optional unique identifier */\n id?: string;\n /** Object containing the versions mapped with their information */\n versionHistory: VersionHistoryType;\n}\n\n/**\n * Component to render the version history information shown in the footer component. Lists the 5\n * most recent versions, with the options to show all versions by pressing a button.\n *\n * @param versionHistory Object containing the versions mapped with their information\n * @param id Optional unique identifier\n * @returns Rendered version history for the Footer component\n */\nexport default function VersionHistory({ id, versionHistory }: VersionHistoryProps) {\n const [showAllVersions, setShowAllVersions] = useState(false);\n const currentDate = new Date();\n\n /**\n * Function to format the time string for the version history in the form of 'X year(s) ago'.\n *\n * @param dateString ISO Date string to determine the time string from\n * @returns Formatted time string\n */\n function formatTimeString(dateString: string) {\n const date = new Date(dateString);\n const dateDiff = new Date(currentDate.getTime() - date.getTime());\n const yearDiff = dateDiff.getUTCFullYear() - 1970;\n const monthDiff = dateDiff.getUTCMonth();\n const dayDiff = dateDiff.getUTCDate() - 1;\n\n // Determines how long ago the version was published\n let timeString = '';\n if (yearDiff > 0) {\n timeString = `${yearDiff.toString()} year${yearDiff === 1 ? '' : 's'} ago`;\n } else if (monthDiff > 0) {\n timeString = `${monthDiff.toString()} month${monthDiff === 1 ? '' : 's'} ago`;\n } else if (dayDiff === 0) {\n timeString = 'today';\n } else {\n timeString = `${dayDiff.toString()} day${dayDiff === 1 ? '' : 's'} ago`;\n }\n\n return timeString;\n }\n\n // Sorts the version history by version number\n const sortedEntries = Object.entries(versionHistory).sort((a, b) => b[0].localeCompare(a[0]));\n\n return (\n
\n

What`s New

\n
    \n {(showAllVersions ? sortedEntries : sortedEntries.slice(0, 5)).map((entry) => (\n
    \n
    \n
  • \n {entry[1].description}\n
  • \n
    \n
    \n
    Version {entry[0]}
    \n
    {formatTimeString(entry[1].date)}
    \n
    \n
    \n ))}\n
\n {sortedEntries.length > 5 && (\n setShowAllVersions(!showAllVersions)}\n className=\"tw-text-xs tw-text-gray-500 tw-underline\"\n >\n {showAllVersions ? 'Show Less Version History' : 'Show All Version History'}\n \n )}\n
\n );\n}\n","import { useMemo } from 'react';\nimport { formatBytes } from 'platform-bible-utils';\nimport VersionHistory, { VersionHistoryType } from './version-history.component';\n\n/** Interface to store the parameters passed to the Footer component */\ninterface FooterProps {\n /** Optional unique identifier */\n id?: string;\n /** Name of the publisher */\n publisherDisplayName: string;\n /** Size of the extension file in bytes */\n fileSize: number;\n /** List of language codes supported by the extension */\n locales: string[];\n /** Object containing the version history mapped with their information */\n versionHistory: VersionHistoryType;\n}\n\n/**\n * Component to render the footer for the extension details which contains information on the\n * publisher, version history, languages, and file size.\n *\n * @param id Optional unique identifier\n * @param publisherDisplayName Name of the publisher\n * @param fileSize Size of the extension file in bytes\n * @param locales List of language codes supported by the extension\n * @param versionHistory Object containing the version history mapped with their information\n * @returns The rendered Footer component\n */\nexport default function Footer({\n id,\n publisherDisplayName,\n fileSize,\n locales,\n versionHistory,\n}: FooterProps) {\n /** Formats the file size into a human-readable format */\n const formattedFileSize = useMemo(() => formatBytes(fileSize), [fileSize]);\n\n /**\n * This function gets the display names of the languages based on the language codes.\n *\n * @param codes The list of language codes\n * @returns The list of language names\n */\n const getLanguageNames = (codes: string[]) => {\n const displayNames = new Intl.DisplayNames(navigator.language, { type: 'language' });\n return codes.map((code) => displayNames.of(code));\n };\n\n const languageNames = getLanguageNames(locales);\n\n return (\n
\n
\n \n
\n
\n

Information

\n
\n

\n Publisher\n {publisherDisplayName}\n Size\n {formattedFileSize}\n

\n
\n

\n Languages\n {languageNames.join(', ')}\n

\n
\n
\n
\n
\n
\n );\n}\n","import { PlatformEvent, PlatformEventHandler } from 'platform-bible-utils';\nimport { useEffect } from 'react';\n\n/**\n * Adds an event handler to an event so the event handler runs when the event is emitted. Use\n * `papi.network.getNetworkEvent` to use a networked event with this hook.\n *\n * @param event The event to subscribe to.\n *\n * - If event is a `PlatformEvent`, that event will be used\n * - If event is undefined, the callback will not be subscribed. Useful if the event is not yet\n * available for example\n *\n * @param eventHandler The callback to run when the event is emitted\n *\n * WARNING: MUST BE STABLE - const or wrapped in useCallback. The reference must not be updated\n * every render\n */\nconst useEvent = (\n event: PlatformEvent | undefined,\n eventHandler: PlatformEventHandler,\n) => {\n useEffect(() => {\n // Do nothing if the event is not provided (in case the event is not yet available, for example)\n if (!event) return () => {};\n\n const unsubscriber = event(eventHandler);\n return () => {\n unsubscriber();\n };\n }, [event, eventHandler]);\n};\nexport default useEvent;\n","import { useCallback, useEffect } from 'react';\nimport { PlatformEvent, PlatformEventAsync, PlatformEventHandler } from 'platform-bible-utils';\nimport usePromise from './use-promise.hook';\n\nconst noopUnsubscriber = () => false;\n\n/**\n * Adds an event handler to an asynchronously subscribing/unsubscribing event so the event handler\n * runs when the event is emitted. Use `papi.network.getNetworkEvent` to use a networked event with\n * this hook.\n *\n * @param event The asynchronously (un)subscribing event to subscribe to.\n *\n * - If event is a `PlatformEvent` or `PlatformEventAsync`, that event will be used\n * - If event is undefined, the callback will not be subscribed. Useful if the event is not yet\n * available for example\n *\n * @param eventHandler The callback to run when the event is emitted\n *\n * WARNING: MUST BE STABLE - const or wrapped in useCallback. The reference must not be updated\n * every render\n */\nconst useEventAsync = (\n event: PlatformEvent | PlatformEventAsync | undefined,\n eventHandler: PlatformEventHandler,\n) => {\n // Subscribe to the event asynchronously\n const [unsubscribe] = usePromise(\n useCallback(async () => {\n // Do nothing if the event is not provided (in case the event is not yet available, for example)\n if (!event) return noopUnsubscriber;\n\n // Wrap subscribe and unsubscribe in promises to allow normal events to be used as well\n const unsub = await Promise.resolve(event(eventHandler));\n return async () => unsub();\n }, [eventHandler, event]),\n noopUnsubscriber,\n // We want the unsubscriber to return to default value immediately upon changing subscription\n // So the useEffect below will unsubscribe asap\n { preserveValue: false },\n );\n\n // Unsubscribe from the event asynchronously (but we aren't awaiting the unsub)\n useEffect(() => {\n return () => {\n if (unsubscribe !== noopUnsubscriber) {\n unsubscribe();\n }\n };\n }, [unsubscribe]);\n};\n\nexport default useEventAsync;\n"],"names":["twMergeCustom","extendTailwindMerge","cn","inputs","clsx","Input","React","className","type","props","ref","jsx","BookChapterInput","forwardRef","handleSearch","handleKeyDown","handleOnClick","handleSubmit","jsxs","ShadInput","event","e","History","P","R","t","s","n","N","B","O","S","K","g","k","x","T","X","V","w","L","G","A","H","C","I","y","q","U","m","l","h","c","E","D","i","a","o","u","v","f","d","b","p","J","DropdownMenu","DropdownMenuPrimitive","DropdownMenuTrigger","DropdownMenuGroup","DropdownMenuPortal","DropdownMenuSub","DropdownMenuRadioGroup","DropdownMenuSubTrigger","inset","children","ChevronRight","DropdownMenuSubContent","DropdownMenuContent","sideOffset","DropdownMenuItem","DropdownMenuCheckboxItem","checked","Check","DropdownMenuRadioItem","Circle","DropdownMenuLabel","DropdownMenuSeparator","DropdownMenuShortcut","BookMenuItem","bookId","handleSelectBook","isSelected","handleHighlightBook","bookType","ShadDropdownMenuItem","Canon","ChapterSelect","handleSelectChapter","endChapter","activeChapter","highlightedChapter","handleHighlightedChapter","chapters","_","handleMouse","useCallback","chapterNumber","chapter","GoToMenuItem","handleSort","handleLocationHistory","handleBookmarks","ShadDropdownMenuLabel","ArrowDownWideNarrow","Clock","Bookmark","ALL_BOOK_IDS","BOOK_TYPE_LABELS","BOOK_TYPE_ARRAY","SCROLL_OFFSET","SEARCH_QUERY_FORMATS","fetchGroupedBooks","fetchEndChapter","getChaptersForBook","getAllEnglishNames","isValidBookEnglishName","bookName","getBookIdFromEnglishName","formattedBookName","BookChapterControl","scrRef","searchQuery","setSearchQuery","useState","selectedBookId","setSelectedBookId","setHighlightedChapter","highlightedBookId","setHighlightedBookId","isContentOpen","setIsContentOpen","isContentOpenDelayed","setIsContentOpenDelayed","inputRef","useRef","contentRef","menuItemRef","fetchFilteredBooks","englishNameLowerCase","normalizedQuery","handleSearchInput","searchString","shouldPreventAutoClosing","controlMenuState","open","updateReference","shouldClose","verse","handleInputSubmit","format","matches","book","englishName","handleKeyDownInput","handleKeyDownContent","key","handleKeyDownMenuItem","chapterOffSet","useEffect","useLayoutEffect","scrollTimeout","scrollPosition","ShadDropdownMenu","ShadDropdownMenuTrigger","ShadDropdownMenuContent","bookTypeIndex","element","ShadDropdownMenuSeparator","buttonVariants","cva","Button","variant","size","asChild","Comp","Slot","labelVariants","Label","LabelPrimitive","RadioGroup","RadioGroupPrimitive","RadioGroupItem","Popover","PopoverPrimitive","PopoverTrigger","PopoverContent","align","DialogPortal","DialogPrimitive","DialogOverlay","DialogContent","DialogTitle","DialogDescription","Command","CommandPrimitive","CommandInput","Search","CommandList","CommandEmpty","CommandGroup","CommandSeparator","CommandItem","getOptionLabelDefault","option","ComboBox","id","options","value","onChange","getOptionLabel","buttonPlaceholder","textPlaceholder","commandEmptyMessage","buttonVariant","dir","isDisabled","setOpen","ChevronsUpDown","ChapterRangeSelector","startChapter","handleSelectStartChapter","handleSelectEndChapter","chapterCount","chapterOptions","useMemo","index","onChangeStartChapter","onChangeEndChapter","Fragment","BookSelectionMode","BOOK_SELECTOR_STRING_KEYS","localizeString","strings","BookSelector","handleBookSelectionModeChange","currentBookName","onSelectBooks","selectedBookIds","localizedStrings","currentBookText","chooseText","chooseBooksText","bookSelectionMode","setBookSelectionMode","onSelectionModeChange","newMode","DataTableViewOptions","table","FilterIcon","column","Select","SelectPrimitive","SelectGroup","SelectValue","SelectTrigger","ChevronDown","SelectScrollUpButton","ChevronUp","SelectScrollDownButton","SelectContent","position","SelectLabel","SelectItem","SelectSeparator","DataTablePagination","pageSize","ArrowLeftIcon","ChevronLeftIcon","ChevronRightIcon","ArrowRightIcon","Table","stickyHeader","TableHeader","TableBody","TableFooter","TableRow","TableHead","TableCell","TableCaption","DataTable","columns","data","enablePagination","showPaginationControls","showColumnVisibilityControls","onRowClickHandler","sorting","setSorting","columnFilters","setColumnFilters","columnVisibility","setColumnVisibility","rowSelection","setRowSelection","useReactTable","getCoreRowModel","getPaginationRowModel","getSortedRowModel","getFilteredRowModel","headerGroup","header","flexRender","_a","row","cell","OccurrencesTable","occurrenceData","setScriptureReference","referenceHeaderText","occurrenceHeaderText","occurrences","uniqueOccurrences","occurrence","uniqueOccurrence","deepEqual","Checkbox","CheckboxPrimitive","getLinesFromUSFM","text","getNumberFromUSFM","regex","match","getBookNumFromId","getStatusForItem","item","approvedItems","unapprovedItems","toggleVariants","Toggle","TogglePrimitive","ToggleGroupContext","ToggleGroup","ToggleGroupPrimitive","ToggleGroupItem","context","getSortingIcon","sortDirection","ArrowUpIcon","ArrowDownIcon","ArrowUpDownIcon","inventoryItemColumn","itemLabel","inventoryAdditionalItemColumn","additionalItemLabel","additionalItemIndex","inventoryCountColumn","countLabel","statusChangeHandler","changedItems","newStatus","onApprovedItemsChange","onUnapprovedItemsChange","newApprovedItems","validItem","newUnapprovedItems","unapprovedItem","inventoryStatusColumn","statusLabel","status","CircleCheckIcon","CircleXIcon","CircleHelpIcon","INVENTORY_STRING_KEYS","filterItemData","itemData","statusFilter","textFilter","filteredItemData","createTableData","scriptureRef","itemRegex","tableData","currentBook","currentChapter","currentVerse","line","items","itemIndex","existingItem","tableEntry","newReference","substring","newItem","Inventory","scriptureReference","extractItems","additionalItemsLabels","scope","onScopeChange","allItemsText","approvedItemsText","unapprovedItemsText","unknownItemsText","scopeBookText","scopeChapterText","scopeVerseText","filterText","showAdditionalItemsText","showAdditionalItems","setShowAdditionalItems","setStatusFilter","setTextFilter","selectedItem","setSelectedItem","reducedTableData","newTableData","firstItem","existingEntry","newTableEntry","filteredTableData","allColumns","numberOfAdditionalItems","additionalColumns","_b","rowClickHandler","newSelection","handleScopeChange","handleStatusFilterChange","SearchBar","onSearch","placeholder","isFullWidth","handleInputChange","VerticalTabs","TabsPrimitive","VerticalTabsList","VerticalTabsTrigger","VerticalTabsContent","NavigationContentSearch","tabList","searchPlaceholder","headerTitle","isSearchBarFullWidth","direction","tab","scrBookColId","scrRefColId","typeColId","detailsColId","defaultScrRefColumnName","defaultScrBookGroupName","defaultTypeColumnName","defaultDetailsColumnName","getColumns","colInfo","showSourceColumn","showSrcCol","info","formatScrRef","compareScrRefs","toRefOrRange","scriptureSelection","offsetStart","offsetEnd","scrRefToBBBCCCVVV","getRowKey","ScriptureResultsViewer","sources","showColumnHeaders","scriptureReferenceColumnName","scriptureBookGroupName","typeColumnName","detailsColumnName","onRowSelected","grouping","setGrouping","scriptureResults","source","getExpandedRowModel","getGroupedRowModel","selectedRows","keys","selectedRow","scrBookGroupName","typeGroupName","groupingOptions","handleSelectChange","selectedGrouping","handleRowClick","getEvenOrOddBandingStyle","getIndent","groupingState","rowIndex","ChevronLeft","DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS","getLocalizeKeyForScrollGroupId","ScrollGroupSelector","availableScrollGroupIds","scrollGroupId","onChangeScrollGroupId","localizedStringsDefaulted","localizedStringKey","localizedStringValue","newScrollGroupString","scrollGroupOptionId","Separator","orientation","decorative","SeparatorPrimitive","SettingsList","SettingsListItem","primary","secondary","isLoading","loadingMessage","SettingsListHeader","includeSeparator","Checklist","listItems","selectedListItems","handleSelectListItem","createLabel","_interopRequireDefault","obj","module","chainPropTypes","propType1","propType2","args","_extends","target","isPlainObject","prototype","deepClone","output","deepmerge","r","z","reactIs_production_min","hasSymbol","REACT_ELEMENT_TYPE","REACT_PORTAL_TYPE","REACT_FRAGMENT_TYPE","REACT_STRICT_MODE_TYPE","REACT_PROFILER_TYPE","REACT_PROVIDER_TYPE","REACT_CONTEXT_TYPE","REACT_ASYNC_MODE_TYPE","REACT_CONCURRENT_MODE_TYPE","REACT_FORWARD_REF_TYPE","REACT_SUSPENSE_TYPE","REACT_SUSPENSE_LIST_TYPE","REACT_MEMO_TYPE","REACT_LAZY_TYPE","REACT_BLOCK_TYPE","REACT_FUNDAMENTAL_TYPE","REACT_RESPONDER_TYPE","REACT_SCOPE_TYPE","isValidElementType","typeOf","object","$$typeof","$$typeofType","AsyncMode","ConcurrentMode","ContextConsumer","ContextProvider","Element","ForwardRef","Lazy","Memo","Portal","Profiler","StrictMode","Suspense","hasWarnedAboutDeprecatedIsAsyncMode","isAsyncMode","isConcurrentMode","isContextConsumer","isContextProvider","isElement","isForwardRef","isFragment","isLazy","isMemo","isPortal","isProfiler","isStrictMode","isSuspense","reactIs_development","reactIsModule","require$$0","require$$1","getOwnPropertySymbols","hasOwnProperty","propIsEnumerable","toObject","val","shouldUseNative","test1","test2","order2","test3","letter","objectAssign","from","to","symbols","ReactPropTypesSecret","ReactPropTypesSecret_1","has","printWarning","loggedTypeFailures","message","checkPropTypes","typeSpecs","values","location","componentName","getStack","typeSpecName","error","err","ex","stack","checkPropTypes_1","ReactIs","assign","require$$2","require$$3","require$$4","emptyFunctionThatReturnsNull","factoryWithTypeCheckers","isValidElement","throwOnDirectAccess","ITERATOR_SYMBOL","FAUX_ITERATOR_SYMBOL","getIteratorFn","maybeIterable","iteratorFn","ANONYMOUS","ReactPropTypes","createPrimitiveTypeChecker","createAnyTypeChecker","createArrayOfTypeChecker","createElementTypeChecker","createElementTypeTypeChecker","createInstanceTypeChecker","createNodeChecker","createObjectOfTypeChecker","createEnumTypeChecker","createUnionTypeChecker","createShapeTypeChecker","createStrictShapeTypeChecker","is","PropTypeError","createChainableTypeChecker","validate","manualPropTypeCallCache","manualPropTypeWarningCount","checkType","isRequired","propName","propFullName","secret","cacheKey","chainedCheckType","expectedType","propValue","propType","getPropType","preciseType","getPreciseType","typeChecker","expectedClass","expectedClassName","actualClassName","getClassName","expectedValues","valuesString","arrayOfTypeCheckers","checker","getPostfixForTypeWarning","expectedTypes","checkerResult","expectedTypesMessage","isNode","invalidValidatorError","shapeTypes","allKeys","iterator","step","entry","isSymbol","emptyFunction","emptyFunctionWithReset","factoryWithThrowingShims","shim","getShim","propTypesModule","isClassComponent","elementType","acceptingRef","safePropName","warningHint","elementAcceptingRef","PropTypes","elementAcceptingRef$1","specialProperty","exactProp","propTypes","unsupportedProps","prop","formatMuiErrorMessage","code","url","REACT_SERVER_CONTEXT_TYPE","REACT_OFFSCREEN_TYPE","enableScopeAPI","enableCacheElement","enableTransitionTracing","enableLegacyHidden","enableDebugTracing","REACT_MODULE_REFERENCE","SuspenseList","hasWarnedAboutDeprecatedIsConcurrentMode","isSuspenseList","fnNameMatchRegex","getFunctionName","fn","getFunctionComponentName","Component","fallback","getWrappedName","outerType","innerType","wrapperName","functionName","getDisplayName","HTMLElementType","refType","refType$1","capitalize","string","_formatMuiErrorMessage","createChainedFunction","funcs","acc","func","debounce","wait","timeout","debounced","later","deprecatedPropType","validator","reason","componentNameSafe","propFullNameSafe","isMuiElement","muiNames","_muiName","_element$type","ownerDocument","node","ownerWindow","requirePropFactory","componentNameInError","prevPropTypes","requiredProp","defaultTypeChecker","typeCheckerResult","setRef","useEnhancedEffect","useEnhancedEffect$1","globalId","useGlobalId","idOverride","defaultId","setDefaultId","maybeReactUseId","useId","reactId","unsupportedProp","useControlled","controlled","defaultProp","name","state","isControlled","valueState","setValue","defaultValue","setValueIfUncontrolled","newValue","useEventCallback","useForkRef","refs","instance","UNINITIALIZED","useLazyRef","init","initArg","EMPTY","useOnMount","Timeout","delay","useTimeout","hadKeyboardEvent","hadFocusVisibleRecently","hadFocusVisibleRecentlyTimeout","inputTypesWhitelist","focusTriggersKeyboardModality","tagName","handlePointerDown","handleVisibilityChange","prepare","doc","isFocusVisible","useIsFocusVisible","isFocusVisibleRef","handleBlurVisible","handleFocusVisible","resolveProps","defaultProps","defaultSlotProps","slotProps","slotPropName","composeClasses","slots","getUtilityClass","classes","slot","utilityClass","defaultGenerator","createClassNameGenerator","generate","generator","ClassNameGenerator","ClassNameGenerator$1","globalStateClasses","generateUtilityClass","globalStatePrefix","globalStateClass","generateUtilityClasses","result","clamp","min","max","_objectWithoutPropertiesLoose","excluded","sourceKeys","_excluded","sortBreakpointsValues","breakpointsAsArray","breakpoint1","breakpoint2","createBreakpoints","breakpoints","unit","other","sortedValues","up","down","between","start","end","endIndex","only","not","keyIndex","shape","shape$1","responsivePropType","responsivePropType$1","merge","defaultBreakpoints","handleBreakpoints","styleFromPropValue","theme","themeBreakpoints","breakpoint","mediaKey","cssKey","createEmptyBreakpointObject","breakpointsInput","_breakpointsInput$key","breakpointStyleKey","removeUnusedBreakpoints","breakpointKeys","style","breakpointOutput","getPath","path","checkVars","getStyleValue","themeMapping","transform","propValueFinal","userValue","cssProperty","themeKey","memoize","cache","arg","properties","directions","aliases","getCssProperties","property","marginKeys","paddingKeys","spacingKeys","createUnaryUnit","_getPath","themeSpacing","abs","createUnarySpacing","getValue","transformer","transformed","getStyleFromPropValue","cssProperties","resolveCssProperty","margin","padding","createSpacing","spacingInput","spacing","argsInput","argument","compose","styles","handlers","borderTransform","createBorderStyle","border","borderTop","borderRight","borderBottom","borderLeft","borderColor","borderTopColor","borderRightColor","borderBottomColor","borderLeftColor","outline","outlineColor","borderRadius","gap","columnGap","rowGap","gridColumn","gridRow","gridAutoFlow","gridAutoColumns","gridAutoRows","gridTemplateColumns","gridTemplateRows","gridTemplateAreas","gridArea","paletteTransform","color","bgcolor","backgroundColor","sizingTransform","width","maxWidth","_props$theme","_props$theme2","breakpointsValues","minWidth","height","maxHeight","minHeight","boxSizing","defaultSxConfig","defaultSxConfig$1","objectsHaveSameKeys","objects","union","callIfFn","maybeFn","unstable_createStyleFunctionSx","getThemeValue","config","styleFunctionSx","_theme$unstable_sxCon","sx","traverse","sxInput","sxObject","emptyBreakpoints","breakpointsKeys","css","styleKey","styleFunctionSx$1","applyStyles","createTheme","paletteInput","shapeInput","muiTheme","isObjectEmpty","useTheme","defaultTheme","contextTheme","ThemeContext","systemDefaultTheme","useThemeWithoutDefault","_excluded2","_excluded3","isEmpty","isStringTag","tag","shouldForwardProp","lowercaseFirstLetter","resolveTheme","themeId","defaultOverridesResolver","processStyleArg","callableStyle","_ref","ownerState","resolvedStylesArg","resolvedStyle","variants","isMatch","createStyled","input","rootShouldForwardProp","slotShouldForwardProp","systemSx","inputOptions","processStyles","componentSlot","inputSkipVariantsResolver","inputSkipSx","overridesResolver","skipVariantsResolver","skipSx","label","shouldForwardPropOption","defaultStyledResolver","styledEngineStyled","transformStyleArg","stylesArg","muiStyledResolver","styleArg","expressions","transformedStyleArg","expressionsWithDefaultTheme","styleOverrides","resolvedStyleOverrides","slotKey","slotStyle","_theme$components","themeVariants","numOfCustomFnsApplied","placeholders","displayName","getThemeProps","params","useThemeProps","clampWrapper","hexToRgb","re","colors","decomposeColor","marker","colorSpace","recomposeColor","hslToRgb","rgb","getLuminance","getContrastRatio","foreground","background","lumA","lumB","alpha","darken","coefficient","lighten","createMixins","mixins","common","common$1","grey","grey$1","purple","purple$1","red","red$1","orange","orange$1","blue","blue$1","lightBlue","lightBlue$1","green","green$1","light","dark","addLightOrDark","intent","shade","tonalOffset","tonalOffsetLight","tonalOffsetDark","getDefaultPrimary","mode","getDefaultSecondary","getDefaultError","getDefaultInfo","getDefaultSuccess","getDefaultWarning","createPalette","palette","contrastThreshold","success","warning","getContrastText","contrastText","contrast","augmentColor","mainShade","lightShade","darkShade","modes","round","caseAllCaps","defaultFontFamily","createTypography","typography","fontFamily","fontSize","fontWeightLight","fontWeightRegular","fontWeightMedium","fontWeightBold","htmlFontSize","allVariants","pxToRem2","coef","pxToRem","buildVariant","fontWeight","lineHeight","letterSpacing","casing","shadowKeyUmbraOpacity","shadowKeyPenumbraOpacity","shadowAmbientShadowOpacity","createShadow","px","shadows","shadows$1","easing","duration","formatMs","milliseconds","getAutoHeightDuration","constant","createTransitions","inputTransitions","mergedEasing","mergedDuration","durationOption","easingOption","isString","isNumber","animatedProp","zIndex","zIndex$1","mixinsInput","transitionsInput","typographyInput","systemTheme","systemCreateTheme","stateClasses","component","child","stateClass","defaultTheme$1","THEME_ID","systemUseThemeProps","styled","styled$1","getSvgIconUtilityClass","useUtilityClasses","SvgIconRoot","_theme$transitions","_theme$transitions$cr","_theme$transitions2","_theme$typography","_theme$typography$pxT","_theme$typography2","_theme$typography2$px","_theme$typography3","_theme$typography3$px","_palette$ownerState$c","_palette","_palette2","_palette3","SvgIcon","inProps","htmlColor","inheritViewBox","titleAccess","viewBox","hasSvgAsChild","more","_jsxs","_jsx","SvgIcon$1","createSvgIcon","unstable_ClassNameGenerator","exports","_utils","ArrowRight","default_1","_createSvgIcon","_jsxRuntime","isHostComponent","appendOwnerState","otherProps","defaultContextValue","ClassNameConfiguratorContext","useClassNamesOverride","disableDefaultClasses","extractEventHandlers","excludeKeys","resolveComponentProps","componentProps","slotState","omitEventHandlers","mergeSlotProps","parameters","getSlotProps","additionalProps","externalSlotProps","externalForwardedProps","joinedClasses","mergedStyle","eventHandlers","componentsPropsWithoutEventHandlers","otherPropsWithoutEventHandlers","internalSlotProps","useSlotProps","_parameters$additiona","skipResolvingSlotProps","rest","resolvedComponentsProps","mergedProps","internalRef","GLOBAL_CLASS_PREFIX","buildStateClass","buildSlotClass","getContainer","container","forwardedRef","disablePortal","mountNode","setMountNode","handleRef","newProps","ReactDOM","top","bottom","right","left","auto","basePlacements","clippingParents","viewport","popper","reference","variationPlacements","placement","placements","beforeRead","read","afterRead","beforeMain","main","afterMain","beforeWrite","write","afterWrite","modifierPhases","getNodeName","getWindow","OwnElement","isHTMLElement","isShadowRoot","attributes","effect","_ref2","initialStyles","styleProperties","attribute","applyStyles$1","getBasePlacement","getUAString","uaData","isLayoutViewport","getBoundingClientRect","includeScale","isFixedStrategy","clientRect","scaleX","scaleY","visualViewport","addVisualOffsets","getLayoutRect","contains","parent","rootNode","next","getComputedStyle","isTableElement","getDocumentElement","getParentNode","getTrueOffsetParent","getContainingBlock","isFirefox","isIE","elementCss","currentNode","getOffsetParent","window","offsetParent","getMainAxisFromPlacement","within","mathMax","mathMin","withinMaxClamp","getFreshSideObject","mergePaddingObject","paddingObject","expandToHashMap","hashMap","toPaddingObject","arrow","_state$modifiersData$","arrowElement","popperOffsets","basePlacement","axis","isVertical","len","arrowRect","minProp","maxProp","endDiff","startDiff","arrowOffsetParent","clientSize","centerToReference","center","offset","axisProp","_options$element","arrow$1","getVariation","unsetSides","roundOffsetsByDPR","win","dpr","mapToStyles","_Object$assign2","popperRect","variation","offsets","gpuAcceleration","adaptive","roundOffsets","isFixed","_offsets$x","_offsets$y","_ref3","hasX","hasY","sideX","sideY","heightProp","widthProp","offsetY","offsetX","commonStyles","_ref4","_Object$assign","computeStyles","_ref5","_options$gpuAccelerat","_options$adaptive","_options$roundOffsets","computeStyles$1","passive","_options$scroll","scroll","_options$resize","resize","scrollParents","scrollParent","eventListeners","hash","getOppositePlacement","matched","getOppositeVariationPlacement","getWindowScroll","scrollLeft","scrollTop","getWindowScrollBarX","getViewportRect","strategy","html","layoutViewport","getDocumentRect","_element$ownerDocumen","winScroll","body","isScrollParent","_getComputedStyle","overflow","overflowX","overflowY","getScrollParent","listScrollParents","list","isBody","updatedList","rectToClientRect","rect","getInnerBoundingClientRect","getClientRectFromMixedType","clippingParent","getClippingParents","canEscapeClipping","clipperElement","getClippingRect","boundary","rootBoundary","mainClippingParents","firstClippingParent","clippingRect","accRect","computeOffsets","commonX","commonY","mainAxis","detectOverflow","_options","_options$placement","_options$strategy","_options$boundary","_options$rootBoundary","_options$elementConte","elementContext","_options$altBoundary","altBoundary","_options$padding","altContext","clippingClientRect","referenceClientRect","popperClientRect","elementClientRect","overflowOffsets","offsetData","multiply","computeAutoPlacement","flipVariations","_options$allowedAutoP","allowedAutoPlacements","allPlacements","allowedPlacements","overflows","getExpandedFallbackPlacements","oppositePlacement","flip","_options$mainAxis","checkMainAxis","_options$altAxis","checkAltAxis","specifiedFallbackPlacements","_options$flipVariatio","preferredPlacement","isBasePlacement","fallbackPlacements","referenceRect","checksMap","makeFallbackChecks","firstFittingPlacement","_basePlacement","isStartVariation","mainVariationSide","altVariationSide","checks","check","numberOfChecks","_loop","_i","fittingPlacement","_ret","flip$1","getSideOffsets","preventedOffsets","isAnySideFullyClipped","side","hide","referenceOverflow","popperAltOverflow","referenceClippingOffsets","popperEscapeOffsets","isReferenceHidden","hasPopperEscaped","hide$1","distanceAndSkiddingToXY","rects","invertDistance","skidding","distance","_options$offset","_data$state$placement","offset$1","popperOffsets$1","getAltAxis","preventOverflow","_options$tether","tether","_options$tetherOffset","tetherOffset","altAxis","tetherOffsetValue","normalizedTetherOffsetValue","offsetModifierState","_offsetModifierState$","mainSide","altSide","additive","minLen","maxLen","arrowPaddingObject","arrowPaddingMin","arrowPaddingMax","arrowLen","minOffset","maxOffset","clientOffset","offsetModifierValue","tetherMin","tetherMax","preventedOffset","_offsetModifierState$2","_mainSide","_altSide","_offset","_len","_min","_max","isOriginSide","_offsetModifierValue","_tetherMin","_tetherMax","_preventedOffset","preventOverflow$1","getHTMLElementScroll","getNodeScroll","isElementScaled","getCompositeRect","elementOrVirtualElement","isOffsetParentAnElement","offsetParentIsScaled","documentElement","order","modifiers","map","visited","modifier","sort","requires","dep","depModifier","orderModifiers","orderedModifiers","phase","pending","resolve","mergeByName","merged","current","existing","DEFAULT_OPTIONS","areValidElements","_key","popperGenerator","generatorOptions","_generatorOptions","_generatorOptions$def","defaultModifiers","_generatorOptions$def2","defaultOptions","effectCleanupFns","isDestroyed","setOptionsAction","cleanupModifierEffects","runModifierEffects","_state$elements","_state$orderedModifie","_state$orderedModifie2","_ref$options","cleanupFn","noopFn","createPopper","COMPONENT_NAME","getPopperUtilityClass","flipPlacement","resolveAnchorEl","anchorEl","isVirtualElement","defaultPopperOptions","PopperTooltip","_slots$root","initialPlacement","popperOptions","popperRefProp","TransitionProps","tooltipRef","ownRef","popperRef","handlePopperRef","handlePopperRefRef","rtlPlacement","setPlacement","resolvedAnchorElement","setResolvedAnchorElement","handlePopperUpdate","box","popperModifiers","childProps","Root","rootProps","Popper","containerProp","keepMounted","transition","exited","setExited","handleEnter","handleExited","resolvedAnchorEl","display","transitionProps","useThemeSystem","_setPrototypeOf","_inheritsLoose","subClass","superClass","setPrototypeOf","timeoutsShape","TransitionGroupContext","forceReflow","UNMOUNTED","EXITED","ENTERING","ENTERED","EXITING","Transition","_React$Component","_this","parentGroup","appear","initialStatus","prevState","nextIn","_proto","prevProps","nextStatus","exit","enter","mounting","_this2","appearing","maybeNode","maybeAppearing","timeouts","enterTimeout","_this3","nextState","callback","_this4","active","handler","doesNotHaveTimeoutOrListener","maybeNextCallback","_this$props","pt","noop","Transition$1","reflow","getTransitionProps","_style$transitionDura","_style$transitionTimi","getScale","isWebKit154","Grow","addEndListener","inProp","onEnter","onEntered","onEntering","onExit","onExited","onExiting","TransitionComponent","timer","autoTimeout","nodeRef","normalizedTransitionCallback","maybeIsAppearing","handleEntering","isAppearing","transitionDuration","transitionTimingFunction","handleEntered","handleExiting","handleExit","handleAddEndListener","Grow$1","PopperRoot","BasePopper","components","componentsProps","RootComponent","Popper$1","getTooltipUtilityClass","tooltipClasses","tooltipClasses$1","disableInteractive","touch","TooltipPopper","TooltipTooltip","TooltipArrow","hystersisOpen","hystersisTimer","cursorPosition","composeEventHandler","eventHandler","Tooltip","_slots$popper","_slots$transition","_slots$tooltip","_slots$arrow","_slotProps$popper","_ref6","_slotProps$popper2","_slotProps$transition","_slotProps$tooltip","_ref7","_slotProps$tooltip2","_slotProps$arrow","_ref8","_slotProps$arrow2","childrenProp","describeChild","disableFocusListener","disableHoverListener","disableInteractiveProp","disableTouchListener","enterDelay","enterNextDelay","enterTouchDelay","followCursor","idProp","leaveDelay","leaveTouchDelay","onClose","onOpen","openProp","PopperComponentProp","PopperProps","title","TransitionComponentProp","isRtl","childNode","setChildNode","arrowRef","setArrowRef","ignoreNonTouchEvents","closeTimer","enterTimer","leaveTimer","touchTimer","openState","setOpenState","prevUserSelect","stopTouchInteraction","handleOpen","handleClose","handleLeave","focusVisibleRef","setChildIsFocusVisible","handleBlur","handleFocus","detectTouchStart","childrenProps","handleMouseOver","handleMouseLeave","handleTouchStart","handleTouchEnd","nativeEvent","handleMouseMove","nameOrDescProps","titleIsString","interactiveWrapperListeners","_PopperProps$popperOp","tooltipModifiers","PopperComponent","TooltipComponent","ArrowComponent","popperProps","tooltipProps","tooltipArrowProps","TransitionPropsInner","Tooltip$1","getIcon","icon","menuLabel","leading","MuiListItemIcon","MenuItem","onClick","tooltip","allowForLeadingIcons","iconPathBefore","iconPathAfter","hasAutoFocus","isDense","isSubMenuParent","hasDisabledGutters","hasDivider","focusVisibleClassName","menuItem","MuiMenuItem","MuiListItemText","getAllGroups","menuDefinition","SubMenu","setAnchorEl","parentMenuItem","parentItemProps","handleParentMenuItemClick","renderSubMenuItems","includedGroups","group","GroupedMenuItemList","Menu","getOrderedGroupItems","groupId","allItems","menuProps","commandHandler","groupsToInclude","sortedGroups","itemArray","allowSpaceForLeadingIcons","createMenuItemProps","isLastItemInGroup","divKey","itemInfo","menuItemProps","TopLevelMenu","columnId","MenuColumn","metadata","Grid","List","GridMenu","multiColumnMenu","sortedColumns","columnNumbers","columnName","col","getUsePromiseOptionsDefaults","usePromise","promiseFactoryCallback","defaultValueRef","optionsDefaultedRef","setIsLoading","promiseIsCurrent","MenuIcon","HamburgerMenuButton","menuProvider","normalMenu","fullMenu","containerRef","ariaLabelPrefix","isMenuOpen","setMenuOpen","showFullMenu","setShowFullMenu","handleMenuItemClick","handleMenuButtonClick","prevIsOpen","isOpening","menuCommandHandler","command","setOffset","normalMenuData","fullMenuData","menu","IconButton","Drawer","isTooltipSuppressed","adjustMarginToAlignToEdge","MuiIconButton","Spinner","LoaderCircle","TextField","hasError","helperText","onFocus","onBlur","ShadLabel","Toolbar","AppBar","MuiToolbar","alertVariants","Alert","AlertTitle","AlertDescription","Card","CardHeader","CardTitle","CardDescription","CardContent","CardFooter","Sonner","Toaster","Slider","SliderPrimitive","Switch","SwitchPrimitives","Tabs","TabsList","TabsTrigger","TabsContent","InstallButton","isInstalling","handleClick","buttonText","Download","EnableButton","isEnabling","DisableButton","isDisabling","UpdateButton","isUpdating","MarkdownRenderer","markdown","anchorTarget","Markdown","FilterButton","Filter","DropdownMenuItemType","DropdownMenuItemType2","FilterDropdown","groups","NoExtensionsFound","MoreInfo","category","downloads","languages","moreInfoUrl","numberFormatted","NumberFormat","handleScrollToBottom","User","locale","LucideLink","CircleHelp","VersionHistory","versionHistory","showAllVersions","setShowAllVersions","currentDate","formatTimeString","dateString","date","dateDiff","yearDiff","monthDiff","dayDiff","timeString","sortedEntries","Footer","publisherDisplayName","fileSize","locales","formattedFileSize","formatBytes","languageNames","codes","displayNames","useEvent","unsubscriber","noopUnsubscriber","useEventAsync","unsubscribe","unsub"],"mappings":"45CAGA,MAAMA,GAAgBC,GAAAA,oBAAoB,CAAE,OAAQ,KAAO,CAAA,EAyDpD,SAASC,KAAMC,EAAsB,CACnC,OAAAH,GAAcI,GAAAA,KAAKD,CAAM,CAAC,CACnC,CCzDO,MAAME,GAAQC,EAAM,WACzB,CAAC,CAAE,UAAAC,EAAW,KAAAC,EAAM,GAAGC,CAAA,EAASC,IAE5BC,EAAA,IAAC,QAAA,CACC,KAAAH,EACA,UAAWN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A,MACA,MACA,MACA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MAEA,MAEA,MAEA,MAEA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,MAEA,MAEA,MAEA,MAEA,MACA,MACA,MACA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,KACF,EAAGC,GAAI,CACL,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,KACF,EAAGC,GAAI,CACL,UACA,SACA,YACA,UACA,cACA,SACA,SACA,OACA,WACA,WACA,UACA,UACA,eACA,eACA,OACA,WACA,kBACA,MACA,SACA,WACA,eACA,gBACA,SACA,WACA,eACA,UACA,kBACA,QACA,OACA,OACA,UACA,QACA,QACA,QACA,WACA,YACA,SACA,YACA,UACA,UACA,OACA,OACA,OACA,OACA,SACA,gBACA,gBACA,YACA,YACA,cACA,aACA,kBACA,kBACA,YACA,YACA,QACA,WACA,UACA,QACA,UACA,UACA,SACA,SACA,SACA,OACA,aACA,QACA,SACA,eACA,oBACA,0BACA,SACA,qBACA,sBACA,UACA,qBACA,cACA,cACA,cACA,cACA,mBACA,mBACA,qBACA,YACA,OACA,oBAGA,uBACA,uBACA,sBACA,yBACA,wBACA,qBACA,UACA,UACA,UACA,UACA,UACA,UACA,UACA,eACA,cACA,eACA,oBACA,qBACA,0BACA,0BACA,eACA,eACA,YACA,gBACA,cACA,eACA,iBACA,wBACA,mBACA,WACA,QACA,aACA,aACA,aACA,2BACA,4BACA,YACF,EAAGC,GAAIC,KACP,SAASC,GAAER,EAAGJ,EAAI,GAAI,CACpB,OAAOA,IAAMI,EAAIA,EAAE,YAAa,GAAGA,KAAKM,GAAIA,GAAEN,CAAC,EAAI,CACrD,CACA,SAASS,GAAET,EAAG,CACZ,OAAOQ,GAAER,CAAC,EAAI,CACh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Aa,CACX,SAAU,UACV,UAAWA,EACZ,EACD,aAAc,CACZ,SAAU,UACV,UAAWA,EACZ,EACD,WAAY,CACV,SAAU,UACV,UAAWA,EACZ,EACD,YAAa,CACX,SAAU,SACX,EACD,eAAgB,CACd,SAAU,SACX,EACD,iBAAkB,CAChB,SAAU,SACX,EACD,kBAAmB,CACjB,SAAU,SACX,EACD,gBAAiB,CACf,SAAU,SACX,EACD,QAAS,CACP,SAAU,UACV,UAAWA,EACZ,EACD,aAAc,CACZ,SAAU,SACX,EACD,aAAc,CACZ,SAAU,qBACV,MAAOc,EACR,EAED,MAAO,CACL,SAAU,UACV,UAAWa,EACZ,EACD,QAAS,CACP,SAAU,UACV,YAAa,kBACb,UAAWA,EACZ,EACD,gBAAiB,CACf,SAAU,UACV,UAAWA,EACZ,EAED,EAAG,CACD,MAAOpC,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,QAAS,CACP,MAAOA,EACR,EACD,WAAY,CACV,MAAOA,EACR,EACD,aAAc,CACZ,MAAOA,EACR,EACD,cAAe,CACb,MAAOA,EACR,EACD,YAAa,CACX,MAAOA,EACR,EACD,SAAU,CACR,MAAOA,EACR,EACD,SAAU,CACR,MAAOA,EACR,EACD,cAAe,CACb,MAAOA,EACR,EACD,mBAAoB,CAClB,MAAOA,EACR,EACD,iBAAkB,CAChB,MAAOA,EACR,EACD,aAAc,CACZ,MAAOA,EACR,EACD,kBAAmB,CACjB,MAAOA,EACR,EACD,gBAAiB,CACf,MAAOA,EACR,EACD,EAAG,CACD,MAAOD,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EAC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;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","x_google_ignoreList":[3,38,39,40,41,42,43,44,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,83,84,85,86,87,88,89,90,91,92,93,94,95,96,97,98,99,100,101,102,103,104,105,106,107,108,109,110,111,112,113,114,115,116,117,118,119,120,121,122,123,124,125,126,127,128,129,130,131,132,133,134,135,136,137,138,139,140,141,142,143,144,145,146,147,148,149,150,151,152,153,154,155,156,157,158,159,160,161,162,163,164,165,166,167,168,169,170,171,172,173,174,175,176,177,178,179,180,181,182,183,184,185,186,187,188,189,190,191,192,193,194,195,196,197,198,199,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,221]} \ No newline at end of file +{"version":3,"file":"index.cjs","sources":["../src/utils/shadcn-ui.util.ts","../src/components/shadcn-ui/input.tsx","../src/components/advanced/book-chapter-control/book-chapter-input.component.tsx","../../../node_modules/@sillsdev/scripture/dist/index.es.js","../src/components/shadcn-ui/dropdown-menu.tsx","../src/components/advanced/book-chapter-control/book-menu-item.component.tsx","../src/components/advanced/book-chapter-control/chapter-select.component.tsx","../src/components/advanced/book-chapter-control/go-to-menu-item.component.tsx","../src/components/advanced/book-chapter-control/book-chapter-control.component.tsx","../src/components/shadcn-ui/button.tsx","../src/components/shadcn-ui/label.tsx","../src/components/shadcn-ui/radio-group.tsx","../src/components/shadcn-ui/popover.tsx","../src/components/shadcn-ui/dialog.tsx","../src/components/shadcn-ui/command.tsx","../src/components/basics/combo-box.component.tsx","../src/components/basics/chapter-range-selector.component.tsx","../src/components/advanced/book-selector.component.tsx","../src/components/advanced/data-table/data-table-column-toggle.component.tsx","../src/components/shadcn-ui/select.tsx","../src/components/advanced/data-table/data-table-pagination.component.tsx","../src/components/shadcn-ui/table.tsx","../src/components/advanced/data-table/data-table.component.tsx","../src/components/advanced/inventory/occurrences-table.component.tsx","../src/components/shadcn-ui/checkbox.tsx","../src/components/advanced/inventory/inventory-utils.ts","../src/components/shadcn-ui/toggle.tsx","../src/components/shadcn-ui/toggle-group.tsx","../src/components/advanced/inventory/inventory-columns.tsx","../src/components/advanced/inventory/inventory.component.tsx","../src/components/basics/search-bar.component.tsx","../src/components/basics/tabs-vertical.tsx","../src/components/advanced/tab-navigation-content-search.component.tsx","../src/components/shadcn-ui/separator.tsx","../src/components/shadcn-ui/sheet.tsx","../src/components/shadcn-ui/skeleton.tsx","../src/components/shadcn-ui/tooltip.tsx","../src/components/hooks/use-mobile.tsx","../src/components/shadcn-ui/sidebar.tsx","../src/components/advanced/settings-components/settings-sidebar.component.tsx","../src/components/advanced/settings-components/settings-sidebar-content-search.component.tsx","../src/components/advanced/scripture-results-viewer/scripture-results-viewer.component.tsx","../src/components/advanced/scroll-group-selector.component.tsx","../src/components/advanced/settings-components/settings-list.component.tsx","../src/components/shadcn-ui/card.tsx","../src/components/advanced/settings-components/settings-card.component.tsx","../src/components/basics/checklist.component.tsx","../../../node_modules/@babel/runtime/helpers/interopRequireDefault.js","../../../node_modules/@mui/utils/chainPropTypes/chainPropTypes.js","../../../node_modules/@babel/runtime/helpers/esm/extends.js","../../../node_modules/@mui/utils/deepmerge/deepmerge.js","../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.production.min.js","../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.development.js","../../../node_modules/prop-types/node_modules/react-is/index.js","../../../node_modules/object-assign/index.js","../../../node_modules/prop-types/lib/ReactPropTypesSecret.js","../../../node_modules/prop-types/lib/has.js","../../../node_modules/prop-types/checkPropTypes.js","../../../node_modules/prop-types/factoryWithTypeCheckers.js","../../../node_modules/prop-types/factoryWithThrowingShims.js","../../../node_modules/prop-types/index.js","../../../node_modules/@mui/utils/elementAcceptingRef/elementAcceptingRef.js","../../../node_modules/@mui/utils/exactProp/exactProp.js","../../../node_modules/@mui/utils/formatMuiErrorMessage/formatMuiErrorMessage.js","../../../node_modules/react-is/cjs/react-is.production.min.js","../../../node_modules/react-is/cjs/react-is.development.js","../../../node_modules/react-is/index.js","../../../node_modules/@mui/utils/getDisplayName/getDisplayName.js","../../../node_modules/@mui/utils/HTMLElementType/HTMLElementType.js","../../../node_modules/@mui/utils/refType/refType.js","../../../node_modules/@mui/utils/capitalize/capitalize.js","../../../node_modules/@mui/utils/createChainedFunction/createChainedFunction.js","../../../node_modules/@mui/utils/debounce/debounce.js","../../../node_modules/@mui/utils/deprecatedPropType/deprecatedPropType.js","../../../node_modules/@mui/utils/isMuiElement/isMuiElement.js","../../../node_modules/@mui/utils/ownerDocument/ownerDocument.js","../../../node_modules/@mui/utils/ownerWindow/ownerWindow.js","../../../node_modules/@mui/utils/requirePropFactory/requirePropFactory.js","../../../node_modules/@mui/utils/setRef/setRef.js","../../../node_modules/@mui/utils/useEnhancedEffect/useEnhancedEffect.js","../../../node_modules/@mui/utils/useId/useId.js","../../../node_modules/@mui/utils/unsupportedProp/unsupportedProp.js","../../../node_modules/@mui/utils/useControlled/useControlled.js","../../../node_modules/@mui/utils/useEventCallback/useEventCallback.js","../../../node_modules/@mui/utils/useForkRef/useForkRef.js","../../../node_modules/@mui/utils/useLazyRef/useLazyRef.js","../../../node_modules/@mui/utils/useOnMount/useOnMount.js","../../../node_modules/@mui/utils/useTimeout/useTimeout.js","../../../node_modules/@mui/utils/useIsFocusVisible/useIsFocusVisible.js","../../../node_modules/@mui/utils/resolveProps/resolveProps.js","../../../node_modules/@mui/utils/composeClasses/composeClasses.js","../../../node_modules/@mui/utils/ClassNameGenerator/ClassNameGenerator.js","../../../node_modules/@mui/utils/generateUtilityClass/generateUtilityClass.js","../../../node_modules/@mui/utils/generateUtilityClasses/generateUtilityClasses.js","../../../node_modules/@mui/utils/clamp/clamp.js","../../../node_modules/@babel/runtime/helpers/esm/objectWithoutPropertiesLoose.js","../../../node_modules/@mui/system/esm/createTheme/createBreakpoints.js","../../../node_modules/@mui/system/esm/createTheme/shape.js","../../../node_modules/@mui/system/esm/responsivePropType.js","../../../node_modules/@mui/system/esm/merge.js","../../../node_modules/@mui/system/esm/breakpoints.js","../../../node_modules/@mui/system/esm/style.js","../../../node_modules/@mui/system/esm/memoize.js","../../../node_modules/@mui/system/esm/spacing.js","../../../node_modules/@mui/system/esm/createTheme/createSpacing.js","../../../node_modules/@mui/system/esm/compose.js","../../../node_modules/@mui/system/esm/borders.js","../../../node_modules/@mui/system/esm/cssGrid.js","../../../node_modules/@mui/system/esm/palette.js","../../../node_modules/@mui/system/esm/sizing.js","../../../node_modules/@mui/system/esm/styleFunctionSx/defaultSxConfig.js","../../../node_modules/@mui/system/esm/styleFunctionSx/styleFunctionSx.js","../../../node_modules/@mui/system/esm/createTheme/applyStyles.js","../../../node_modules/@mui/system/esm/createTheme/createTheme.js","../../../node_modules/@mui/system/esm/useThemeWithoutDefault.js","../../../node_modules/@mui/system/esm/useTheme.js","../../../node_modules/@mui/system/esm/createStyled.js","../../../node_modules/@mui/system/esm/useThemeProps/getThemeProps.js","../../../node_modules/@mui/system/esm/useThemeProps/useThemeProps.js","../../../node_modules/@mui/system/esm/colorManipulator.js","../../../node_modules/@mui/material/styles/createMixins.js","../../../node_modules/@mui/material/colors/common.js","../../../node_modules/@mui/material/colors/grey.js","../../../node_modules/@mui/material/colors/purple.js","../../../node_modules/@mui/material/colors/red.js","../../../node_modules/@mui/material/colors/orange.js","../../../node_modules/@mui/material/colors/blue.js","../../../node_modules/@mui/material/colors/lightBlue.js","../../../node_modules/@mui/material/colors/green.js","../../../node_modules/@mui/material/styles/createPalette.js","../../../node_modules/@mui/material/styles/createTypography.js","../../../node_modules/@mui/material/styles/shadows.js","../../../node_modules/@mui/material/styles/createTransitions.js","../../../node_modules/@mui/material/styles/zIndex.js","../../../node_modules/@mui/material/styles/createTheme.js","../../../node_modules/@mui/material/styles/defaultTheme.js","../../../node_modules/@mui/material/styles/identifier.js","../../../node_modules/@mui/material/styles/useThemeProps.js","../../../node_modules/@mui/material/styles/styled.js","../../../node_modules/@mui/material/SvgIcon/svgIconClasses.js","../../../node_modules/@mui/material/SvgIcon/SvgIcon.js","../../../node_modules/@mui/material/utils/createSvgIcon.js","../../../node_modules/@mui/material/utils/index.js","../../../node_modules/@mui/icons-material/utils/createSvgIcon.js","../../../node_modules/@mui/icons-material/ArrowRight.js","../../../node_modules/@mui/base/utils/isHostComponent.js","../../../node_modules/@mui/base/utils/appendOwnerState.js","../../../node_modules/@mui/base/utils/ClassNameConfigurator.js","../../../node_modules/@mui/base/utils/extractEventHandlers.js","../../../node_modules/@mui/base/utils/resolveComponentProps.js","../../../node_modules/@mui/base/utils/omitEventHandlers.js","../../../node_modules/@mui/base/utils/mergeSlotProps.js","../../../node_modules/@mui/base/utils/useSlotProps.js","../../../node_modules/@mui/base/generateUtilityClass/index.js","../../../node_modules/@mui/base/generateUtilityClasses/index.js","../../../node_modules/@mui/base/Portal/Portal.js","../../../node_modules/@popperjs/core/lib/enums.js","../../../node_modules/@popperjs/core/lib/dom-utils/getNodeName.js","../../../node_modules/@popperjs/core/lib/dom-utils/getWindow.js","../../../node_modules/@popperjs/core/lib/dom-utils/instanceOf.js","../../../node_modules/@popperjs/core/lib/modifiers/applyStyles.js","../../../node_modules/@popperjs/core/lib/utils/getBasePlacement.js","../../../node_modules/@popperjs/core/lib/utils/math.js","../../../node_modules/@popperjs/core/lib/utils/userAgent.js","../../../node_modules/@popperjs/core/lib/dom-utils/isLayoutViewport.js","../../../node_modules/@popperjs/core/lib/dom-utils/getBoundingClientRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/getLayoutRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/contains.js","../../../node_modules/@popperjs/core/lib/dom-utils/getComputedStyle.js","../../../node_modules/@popperjs/core/lib/dom-utils/isTableElement.js","../../../node_modules/@popperjs/core/lib/dom-utils/getDocumentElement.js","../../../node_modules/@popperjs/core/lib/dom-utils/getParentNode.js","../../../node_modules/@popperjs/core/lib/dom-utils/getOffsetParent.js","../../../node_modules/@popperjs/core/lib/utils/getMainAxisFromPlacement.js","../../../node_modules/@popperjs/core/lib/utils/within.js","../../../node_modules/@popperjs/core/lib/utils/getFreshSideObject.js","../../../node_modules/@popperjs/core/lib/utils/mergePaddingObject.js","../../../node_modules/@popperjs/core/lib/utils/expandToHashMap.js","../../../node_modules/@popperjs/core/lib/modifiers/arrow.js","../../../node_modules/@popperjs/core/lib/utils/getVariation.js","../../../node_modules/@popperjs/core/lib/modifiers/computeStyles.js","../../../node_modules/@popperjs/core/lib/modifiers/eventListeners.js","../../../node_modules/@popperjs/core/lib/utils/getOppositePlacement.js","../../../node_modules/@popperjs/core/lib/utils/getOppositeVariationPlacement.js","../../../node_modules/@popperjs/core/lib/dom-utils/getWindowScroll.js","../../../node_modules/@popperjs/core/lib/dom-utils/getWindowScrollBarX.js","../../../node_modules/@popperjs/core/lib/dom-utils/getViewportRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/getDocumentRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/isScrollParent.js","../../../node_modules/@popperjs/core/lib/dom-utils/getScrollParent.js","../../../node_modules/@popperjs/core/lib/dom-utils/listScrollParents.js","../../../node_modules/@popperjs/core/lib/utils/rectToClientRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/getClippingRect.js","../../../node_modules/@popperjs/core/lib/utils/computeOffsets.js","../../../node_modules/@popperjs/core/lib/utils/detectOverflow.js","../../../node_modules/@popperjs/core/lib/utils/computeAutoPlacement.js","../../../node_modules/@popperjs/core/lib/modifiers/flip.js","../../../node_modules/@popperjs/core/lib/modifiers/hide.js","../../../node_modules/@popperjs/core/lib/modifiers/offset.js","../../../node_modules/@popperjs/core/lib/modifiers/popperOffsets.js","../../../node_modules/@popperjs/core/lib/utils/getAltAxis.js","../../../node_modules/@popperjs/core/lib/modifiers/preventOverflow.js","../../../node_modules/@popperjs/core/lib/dom-utils/getHTMLElementScroll.js","../../../node_modules/@popperjs/core/lib/dom-utils/getNodeScroll.js","../../../node_modules/@popperjs/core/lib/dom-utils/getCompositeRect.js","../../../node_modules/@popperjs/core/lib/utils/orderModifiers.js","../../../node_modules/@popperjs/core/lib/utils/debounce.js","../../../node_modules/@popperjs/core/lib/utils/mergeByName.js","../../../node_modules/@popperjs/core/lib/createPopper.js","../../../node_modules/@popperjs/core/lib/popper.js","../../../node_modules/@mui/base/Popper/popperClasses.js","../../../node_modules/@mui/base/Popper/Popper.js","../../../node_modules/@mui/material/styles/useTheme.js","../../../node_modules/@babel/runtime/helpers/esm/setPrototypeOf.js","../../../node_modules/@babel/runtime/helpers/esm/inheritsLoose.js","../../../node_modules/react-transition-group/esm/config.js","../../../node_modules/react-transition-group/esm/utils/PropTypes.js","../../../node_modules/react-transition-group/esm/TransitionGroupContext.js","../../../node_modules/react-transition-group/esm/utils/reflow.js","../../../node_modules/react-transition-group/esm/Transition.js","../../../node_modules/@mui/material/transitions/utils.js","../../../node_modules/@mui/material/Grow/Grow.js","../../../node_modules/@mui/material/Popper/Popper.js","../../../node_modules/@mui/material/Tooltip/tooltipClasses.js","../../../node_modules/@mui/material/Tooltip/Tooltip.js","../src/components/mui/menu-item.component.tsx","../src/components/mui/grouped-menu-item-list.component.tsx","../src/components/mui/top-level-menu.component.tsx","../src/components/mui/grid-menu.component.tsx","../src/hooks/use-promise.hook.ts","../../../node_modules/@mui/icons-material/esm/Menu.js","../src/components/mui/hamburger-menu-button.component.tsx","../src/components/mui/icon-button.component.tsx","../src/components/basics/spinner.component.tsx","../src/components/basics/text-field.component.tsx","../src/components/mui/toolbar.component.tsx","../src/components/shadcn-ui/alert.tsx","../src/components/shadcn-ui/sonner.tsx","../src/components/shadcn-ui/slider.tsx","../src/components/shadcn-ui/switch.tsx","../src/components/shadcn-ui/tabs.tsx","../src/components/advanced/extension-marketplace/buttons/install-button.component.tsx","../src/components/advanced/extension-marketplace/buttons/enable-button.component.tsx","../src/components/advanced/extension-marketplace/buttons/disable-button.component.tsx","../src/components/advanced/extension-marketplace/buttons/update-button.component.tsx","../src/components/advanced/extension-marketplace/markdown-renderer.component.tsx","../src/components/advanced/extension-marketplace/buttons/filter-button.component.tsx","../src/components/advanced/extension-marketplace/filter-dropdown.component.tsx","../src/components/advanced/extension-marketplace/no-extensions-found.component.tsx","../src/components/advanced/extension-marketplace/more-info.component.tsx","../src/components/advanced/extension-marketplace/version-history.component.tsx","../src/components/advanced/extension-marketplace/footer.component.tsx","../src/hooks/use-event.hook.ts","../src/hooks/use-event-async.hook.ts"],"sourcesContent":["import { type ClassValue, clsx } from 'clsx';\nimport { extendTailwindMerge } from 'tailwind-merge';\n\nconst twMergeCustom = extendTailwindMerge({ prefix: 'tw-' });\n\n/**\n * Tailwind and CSS class application helper function. Uses\n * [`clsx`](https://www.npmjs.com/package/clsx) to make it easy to apply classes conditionally using\n * object syntax, and uses [`tailwind-merge`](https://www.npmjs.com/package/tailwind-merge) to make\n * it easy to merge/overwrite Tailwind classes in a programmer-logic-friendly way.\n *\n * Note: `tailwind-merge` is configured to use the prefix `tw-`, so you must use the same prefix\n * with any Tailwind classes you use with this function to successfully overwrite other Tailwind\n * classes. `platform-bible-react` is configured to use `tw-` as its Tailwind prefix, so any\n * Tailwind classes you pass into `platform-bible-react` components will be compared using the `tw-`\n * prefix.\n *\n * This function was popularized by\n * [shadcn/ui](https://ui.shadcn.com/docs/installation/manual#add-a-cn-helper). See [ByteGrad's\n * explanation video](https://www.youtube.com/watch?v=re2JFITR7TI) for more information.\n *\n * @example\n *\n * ```typescript\n * const borderShouldBeBlue = true;\n * const textShouldBeRed = true;\n * const heightShouldBe20 = false;\n * const classString = cn(\n * 'tw-bg-primary tw-h-10 tw-text-primary-foreground',\n * 'tw-bg-secondary',\n * {\n * 'tw-border-blue-500': borderShouldBeBlue,\n * 'tw-text-red-500': textShouldBeRed,\n * 'tw-h-20': heightShouldBe20,\n * },\n * 'some-class',\n * );\n * ```\n *\n * The resulting `classString` is `'tw-h-10 tw-bg-secondary tw-border-blue-500 tw-text-red-500\n * some-class'`\n *\n * - Notice that `'tw-bg-secondary'`, specified later, overwrote `'tw-bg-primary'`, specified earlier,\n * because they are Tailwind classes that affect the same css property\n * - Notice that `'tw-text-red-500'`, specified later, overwrote `'tw-text-primary-foreground'`,\n * specified earlier, because they are Tailwind classes that affect the same css property\n * - Notice that `'tw-h-20'`, specified later, did not overwrite `'tw-h-10'`, specified earlier,\n * because `'tw-h-20'` is part of a conditional class object and its value evaluated to `false`;\n * therefore it was not applied\n * - Notice that `'some-class'` was applied. This function is not limited only to Tailwind classes.\n *\n *\n * @param inputs Class strings or `clsx` conditional class objects to merge. Tailwind classes\n * specified later in the arguments overwrite similar Tailwind classes specified earlier in the\n * arguments\n * @returns Class string containing all applicable classes from the arguments based on the rules\n * described above\n */\n// shadcn/ui uses this export in its boilerplate code\n// eslint-disable-next-line import/prefer-default-export\nexport function cn(...inputs: ClassValue[]) {\n return twMergeCustom(clsx(inputs));\n}\n","import React from 'react';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport interface InputProps extends React.InputHTMLAttributes {}\n\nexport const Input = React.forwardRef(\n ({ className, type, ...props }, ref) => {\n return (\n \n );\n },\n);\nInput.displayName = 'Input';\n","import { FocusEventHandler, forwardRef, KeyboardEvent, MouseEventHandler } from 'react';\nimport { History } from 'lucide-react';\nimport { Input as ShadInput } from '@/components/shadcn-ui/input';\n\nexport type BookChapterInputProps = {\n handleSearch: (searchString: string) => void;\n handleKeyDown: (event: KeyboardEvent) => void;\n handleOnClick: MouseEventHandler;\n handleSubmit: () => void;\n onFocus?: FocusEventHandler;\n value: string;\n placeholder: string;\n};\n\n// Shadcn Input sets type to \"button\"- HAVE to prop spread before setting type\nconst BookChapterInput = forwardRef(\n (\n { handleSearch, handleKeyDown, handleOnClick, handleSubmit, ...props }: BookChapterInputProps,\n ref,\n ) => {\n return (\n
\n handleSearch(event.target.value)}\n onKeyDown={(e) => {\n if (e.key === 'Enter') {\n handleSubmit();\n }\n handleKeyDown(e);\n }}\n onClick={handleOnClick}\n ref={ref}\n />\n {\n // eslint-disable-next-line no-console\n console.log('back in history');\n }}\n />\n
\n );\n },\n);\n\nexport default BookChapterInput;\n","var P = Object.defineProperty;\nvar R = (t, e, s) => e in t ? P(t, e, { enumerable: !0, configurable: !0, writable: !0, value: s }) : t[e] = s;\nvar n = (t, e, s) => R(t, typeof e != \"symbol\" ? e + \"\" : e, s);\nclass _ {\n constructor() {\n n(this, \"books\");\n n(this, \"firstSelectedBookNum\");\n n(this, \"lastSelectedBookNum\");\n n(this, \"count\");\n n(this, \"selectedBookNumbers\");\n n(this, \"selectedBookIds\");\n }\n}\nconst N = [\n \"GEN\",\n \"EXO\",\n \"LEV\",\n \"NUM\",\n \"DEU\",\n \"JOS\",\n \"JDG\",\n \"RUT\",\n \"1SA\",\n \"2SA\",\n // 10\n \"1KI\",\n \"2KI\",\n \"1CH\",\n \"2CH\",\n \"EZR\",\n \"NEH\",\n \"EST\",\n \"JOB\",\n \"PSA\",\n \"PRO\",\n // 20\n \"ECC\",\n \"SNG\",\n \"ISA\",\n \"JER\",\n \"LAM\",\n \"EZK\",\n \"DAN\",\n \"HOS\",\n \"JOL\",\n \"AMO\",\n // 30\n \"OBA\",\n \"JON\",\n \"MIC\",\n \"NAM\",\n \"HAB\",\n \"ZEP\",\n \"HAG\",\n \"ZEC\",\n \"MAL\",\n \"MAT\",\n // 40\n \"MRK\",\n \"LUK\",\n \"JHN\",\n \"ACT\",\n \"ROM\",\n \"1CO\",\n \"2CO\",\n \"GAL\",\n \"EPH\",\n \"PHP\",\n // 50\n \"COL\",\n \"1TH\",\n \"2TH\",\n \"1TI\",\n \"2TI\",\n \"TIT\",\n \"PHM\",\n \"HEB\",\n \"JAS\",\n \"1PE\",\n // 60\n \"2PE\",\n \"1JN\",\n \"2JN\",\n \"3JN\",\n \"JUD\",\n \"REV\",\n \"TOB\",\n \"JDT\",\n \"ESG\",\n \"WIS\",\n // 70\n \"SIR\",\n \"BAR\",\n \"LJE\",\n \"S3Y\",\n \"SUS\",\n \"BEL\",\n \"1MA\",\n \"2MA\",\n \"3MA\",\n \"4MA\",\n // 80\n \"1ES\",\n \"2ES\",\n \"MAN\",\n \"PS2\",\n \"ODA\",\n \"PSS\",\n \"JSA\",\n // actual variant text for JOS, now in LXA text\n \"JDB\",\n // actual variant text for JDG, now in LXA text\n \"TBS\",\n // actual variant text for TOB, now in LXA text\n \"SST\",\n // actual variant text for SUS, now in LXA text // 90\n \"DNT\",\n // actual variant text for DAN, now in LXA text\n \"BLT\",\n // actual variant text for BEL, now in LXA text\n \"XXA\",\n \"XXB\",\n \"XXC\",\n \"XXD\",\n \"XXE\",\n \"XXF\",\n \"XXG\",\n \"FRT\",\n // 100\n \"BAK\",\n \"OTH\",\n \"3ES\",\n // Used previously but really should be 2ES\n \"EZA\",\n // Used to be called 4ES, but not actually in any known project\n \"5EZ\",\n // Used to be called 5ES, but not actually in any known project\n \"6EZ\",\n // Used to be called 6ES, but not actually in any known project\n \"INT\",\n \"CNC\",\n \"GLO\",\n \"TDX\",\n // 110\n \"NDX\",\n \"DAG\",\n \"PS3\",\n \"2BA\",\n \"LBA\",\n \"JUB\",\n \"ENO\",\n \"1MQ\",\n \"2MQ\",\n \"3MQ\",\n // 120\n \"REP\",\n \"4BA\",\n \"LAO\"\n], B = [\n \"XXA\",\n \"XXB\",\n \"XXC\",\n \"XXD\",\n \"XXE\",\n \"XXF\",\n \"XXG\",\n \"FRT\",\n \"BAK\",\n \"OTH\",\n \"INT\",\n \"CNC\",\n \"GLO\",\n \"TDX\",\n \"NDX\"\n], O = [\n \"Genesis\",\n \"Exodus\",\n \"Leviticus\",\n \"Numbers\",\n \"Deuteronomy\",\n \"Joshua\",\n \"Judges\",\n \"Ruth\",\n \"1 Samuel\",\n \"2 Samuel\",\n \"1 Kings\",\n \"2 Kings\",\n \"1 Chronicles\",\n \"2 Chronicles\",\n \"Ezra\",\n \"Nehemiah\",\n \"Esther (Hebrew)\",\n \"Job\",\n \"Psalms\",\n \"Proverbs\",\n \"Ecclesiastes\",\n \"Song of Songs\",\n \"Isaiah\",\n \"Jeremiah\",\n \"Lamentations\",\n \"Ezekiel\",\n \"Daniel (Hebrew)\",\n \"Hosea\",\n \"Joel\",\n \"Amos\",\n \"Obadiah\",\n \"Jonah\",\n \"Micah\",\n \"Nahum\",\n \"Habakkuk\",\n \"Zephaniah\",\n \"Haggai\",\n \"Zechariah\",\n \"Malachi\",\n \"Matthew\",\n \"Mark\",\n \"Luke\",\n \"John\",\n \"Acts\",\n \"Romans\",\n \"1 Corinthians\",\n \"2 Corinthians\",\n \"Galatians\",\n \"Ephesians\",\n \"Philippians\",\n \"Colossians\",\n \"1 Thessalonians\",\n \"2 Thessalonians\",\n \"1 Timothy\",\n \"2 Timothy\",\n \"Titus\",\n \"Philemon\",\n \"Hebrews\",\n \"James\",\n \"1 Peter\",\n \"2 Peter\",\n \"1 John\",\n \"2 John\",\n \"3 John\",\n \"Jude\",\n \"Revelation\",\n \"Tobit\",\n \"Judith\",\n \"Esther Greek\",\n \"Wisdom of Solomon\",\n \"Sirach (Ecclesiasticus)\",\n \"Baruch\",\n \"Letter of Jeremiah\",\n \"Song of 3 Young Men\",\n \"Susanna\",\n \"Bel and the Dragon\",\n \"1 Maccabees\",\n \"2 Maccabees\",\n \"3 Maccabees\",\n \"4 Maccabees\",\n \"1 Esdras (Greek)\",\n \"2 Esdras (Latin)\",\n \"Prayer of Manasseh\",\n \"Psalm 151\",\n \"Odes\",\n \"Psalms of Solomon\",\n // WARNING, if you change the spelling of the *obsolete* tag be sure to update\n // IsObsolete routine\n \"Joshua A. *obsolete*\",\n \"Judges B. *obsolete*\",\n \"Tobit S. *obsolete*\",\n \"Susanna Th. *obsolete*\",\n \"Daniel Th. *obsolete*\",\n \"Bel Th. *obsolete*\",\n \"Extra A\",\n \"Extra B\",\n \"Extra C\",\n \"Extra D\",\n \"Extra E\",\n \"Extra F\",\n \"Extra G\",\n \"Front Matter\",\n \"Back Matter\",\n \"Other Matter\",\n \"3 Ezra *obsolete*\",\n \"Apocalypse of Ezra\",\n \"5 Ezra (Latin Prologue)\",\n \"6 Ezra (Latin Epilogue)\",\n \"Introduction\",\n \"Concordance \",\n \"Glossary \",\n \"Topical Index\",\n \"Names Index\",\n \"Daniel Greek\",\n \"Psalms 152-155\",\n \"2 Baruch (Apocalypse)\",\n \"Letter of Baruch\",\n \"Jubilees\",\n \"Enoch\",\n \"1 Meqabyan\",\n \"2 Meqabyan\",\n \"3 Meqabyan\",\n \"Reproof (Proverbs 25-31)\",\n \"4 Baruch (Rest of Baruch)\",\n \"Laodiceans\"\n], S = K();\nfunction g(t, e = !0) {\n return e && (t = t.toUpperCase()), t in S ? S[t] : 0;\n}\nfunction k(t) {\n return g(t) > 0;\n}\nfunction x(t) {\n const e = typeof t == \"string\" ? g(t) : t;\n return e >= 40 && e <= 66;\n}\nfunction T(t) {\n return (typeof t == \"string\" ? g(t) : t) <= 39;\n}\nfunction X(t) {\n return t <= 66;\n}\nfunction V(t) {\n const e = typeof t == \"string\" ? g(t) : t;\n return w(e) && !X(e);\n}\nfunction* L() {\n for (let t = 1; t <= N.length; t++) yield t;\n}\nconst G = 1, A = N.length;\nfunction H() {\n return [\"XXA\", \"XXB\", \"XXC\", \"XXD\", \"XXE\", \"XXF\", \"XXG\"];\n}\nfunction C(t, e = \"***\") {\n const s = t - 1;\n return s < 0 || s >= N.length ? e : N[s];\n}\nfunction I(t) {\n return t <= 0 || t > A ? \"******\" : O[t - 1];\n}\nfunction y(t) {\n return I(g(t));\n}\nfunction w(t) {\n const e = typeof t == \"number\" ? C(t) : t;\n return k(e) && !B.includes(e);\n}\nfunction q(t) {\n const e = typeof t == \"number\" ? C(t) : t;\n return k(e) && B.includes(e);\n}\nfunction U(t) {\n return O[t - 1].includes(\"*obsolete*\");\n}\nfunction K() {\n const t = {};\n for (let e = 0; e < N.length; e++)\n t[N[e]] = e + 1;\n return t;\n}\nconst m = {\n allBookIds: N,\n nonCanonicalIds: B,\n bookIdToNumber: g,\n isBookIdValid: k,\n isBookNT: x,\n isBookOT: T,\n isBookOTNT: X,\n isBookDC: V,\n allBookNumbers: L,\n firstBook: G,\n lastBook: A,\n extraBooks: H,\n bookNumberToId: C,\n bookNumberToEnglishName: I,\n bookIdToEnglishName: y,\n isCanonical: w,\n isExtraMaterial: q,\n isObsolete: U\n};\nvar l = /* @__PURE__ */ ((t) => (t[t.Unknown = 0] = \"Unknown\", t[t.Original = 1] = \"Original\", t[t.Septuagint = 2] = \"Septuagint\", t[t.Vulgate = 3] = \"Vulgate\", t[t.English = 4] = \"English\", t[t.RussianProtestant = 5] = \"RussianProtestant\", t[t.RussianOrthodox = 6] = \"RussianOrthodox\", t))(l || {});\nconst h = class h {\n // private versInfo: Versification;\n constructor(e) {\n n(this, \"name\");\n n(this, \"fullPath\");\n n(this, \"isPresent\");\n n(this, \"hasVerseSegments\");\n n(this, \"isCustomized\");\n n(this, \"baseVersification\");\n n(this, \"scriptureBooks\");\n n(this, \"_type\");\n if (e == null)\n throw new Error(\"Argument undefined\");\n typeof e == \"string\" ? (this.name = e, this._type = l[e]) : (this._type = e, this.name = l[e]);\n }\n get type() {\n return this._type;\n }\n equals(e) {\n return !e.type || !this.type ? !1 : e.type === this.type;\n }\n};\nn(h, \"Original\", new h(l.Original)), n(h, \"Septuagint\", new h(l.Septuagint)), n(h, \"Vulgate\", new h(l.Vulgate)), n(h, \"English\", new h(l.English)), n(h, \"RussianProtestant\", new h(l.RussianProtestant)), n(h, \"RussianOrthodox\", new h(l.RussianOrthodox));\nlet c = h;\nfunction E(t, e) {\n const s = e[0];\n for (let r = 1; r < e.length; r++)\n t = t.split(e[r]).join(s);\n return t.split(s);\n}\nvar D = /* @__PURE__ */ ((t) => (t[t.Valid = 0] = \"Valid\", t[t.UnknownVersification = 1] = \"UnknownVersification\", t[t.OutOfRange = 2] = \"OutOfRange\", t[t.VerseOutOfOrder = 3] = \"VerseOutOfOrder\", t[t.VerseRepeated = 4] = \"VerseRepeated\", t))(D || {});\nconst i = class i {\n constructor(e, s, r, a) {\n /** Not yet implemented. */\n n(this, \"firstChapter\");\n /** Not yet implemented. */\n n(this, \"lastChapter\");\n /** Not yet implemented. */\n n(this, \"lastVerse\");\n /** Not yet implemented. */\n n(this, \"hasSegmentsDefined\");\n /** Not yet implemented. */\n n(this, \"text\");\n /** Not yet implemented. */\n n(this, \"BBBCCCVVVS\");\n /** Not yet implemented. */\n n(this, \"longHashCode\");\n /** The versification of the reference. */\n n(this, \"versification\");\n n(this, \"rtlMark\", \"‏\");\n n(this, \"_bookNum\", 0);\n n(this, \"_chapterNum\", 0);\n n(this, \"_verseNum\", 0);\n n(this, \"_verse\");\n if (r == null && a == null)\n if (e != null && typeof e == \"string\") {\n const o = e, u = s != null && s instanceof c ? s : void 0;\n this.setEmpty(u), this.parse(o);\n } else if (e != null && typeof e == \"number\") {\n const o = s != null && s instanceof c ? s : void 0;\n this.setEmpty(o), this._verseNum = e % i.chapterDigitShifter, this._chapterNum = Math.floor(\n e % i.bookDigitShifter / i.chapterDigitShifter\n ), this._bookNum = Math.floor(e / i.bookDigitShifter);\n } else if (s == null)\n if (e != null && e instanceof i) {\n const o = e;\n this._bookNum = o.bookNum, this._chapterNum = o.chapterNum, this._verseNum = o.verseNum, this._verse = o.verse, this.versification = o.versification;\n } else {\n if (e == null) return;\n const o = e instanceof c ? e : i.defaultVersification;\n this.setEmpty(o);\n }\n else\n throw new Error(\"VerseRef constructor not supported.\");\n else if (e != null && s != null && r != null)\n if (typeof e == \"string\" && typeof s == \"string\" && typeof r == \"string\")\n this.setEmpty(a), this.updateInternal(e, s, r);\n else if (typeof e == \"number\" && typeof s == \"number\" && typeof r == \"number\")\n this._bookNum = e, this._chapterNum = s, this._verseNum = r, this.versification = a ?? i.defaultVersification;\n else\n throw new Error(\"VerseRef constructor not supported.\");\n else\n throw new Error(\"VerseRef constructor not supported.\");\n }\n /**\n * Determines if the verse string is in a valid format (does not consider versification).\n */\n static isVerseParseable(e) {\n return e.length > 0 && \"0123456789\".includes(e[0]) && !e.endsWith(this.verseRangeSeparator) && !e.endsWith(this.verseSequenceIndicator);\n }\n /**\n * Tries to parse the specified string into a verse reference.\n * @param str - The string to attempt to parse.\n * @returns success: `true` if the specified string was successfully parsed, `false` otherwise.\n * @returns verseRef: The result of the parse if successful, or empty VerseRef if it failed\n */\n static tryParse(e) {\n let s;\n try {\n return s = new i(e), { success: !0, verseRef: s };\n } catch (r) {\n if (r instanceof v)\n return s = new i(), { success: !1, verseRef: s };\n throw r;\n }\n }\n /**\n * Gets the reference as a comparable integer where the book, chapter, and verse each occupy 3\n * digits.\n * @param bookNum - Book number (this is 1-based, not an index).\n * @param chapterNum - Chapter number.\n * @param verseNum - Verse number.\n * @returns The reference as a comparable integer where the book, chapter, and verse each occupy 3\n * digits.\n */\n static getBBBCCCVVV(e, s, r) {\n return e % i.bcvMaxValue * i.bookDigitShifter + (s >= 0 ? s % i.bcvMaxValue * i.chapterDigitShifter : 0) + (r >= 0 ? r % i.bcvMaxValue : 0);\n }\n /**\n * Deserializes a serialized VerseRef.\n * @param serializedVerseRef - Serialized VerseRef to create from.\n * @returns the deserialized VerseRef.\n */\n static fromJSON(e) {\n const { book: s, chapterNum: r, verseNum: a, verse: o, versificationStr: u } = e, f = o || a.toString();\n let d;\n return u && (d = new c(u)), s ? new i(s, r.toString(), f, d) : new i();\n }\n /**\n * Parses a verse string and gets the leading numeric portion as a number.\n * @param verseStr - verse string to parse\n * @returns true if the entire string could be parsed as a single, simple verse number (1-999);\n * false if the verse string represented a verse bridge, contained segment letters, or was invalid\n */\n static tryGetVerseNum(e) {\n let s;\n if (!e)\n return s = -1, { success: !0, vNum: s };\n s = 0;\n let r;\n for (let a = 0; a < e.length; a++) {\n if (r = e[a], r < \"0\" || r > \"9\")\n return a === 0 && (s = -1), { success: !1, vNum: s };\n if (s = s * 10 + +r - 0, s > i.bcvMaxValue)\n return s = -1, { success: !1, vNum: s };\n }\n return { success: !0, vNum: s };\n }\n /**\n * Checks to see if a VerseRef hasn't been set - all values are the default.\n */\n get isDefault() {\n return this.bookNum === 0 && this.chapterNum === 0 && this.verseNum === 0 && this.versification == null;\n }\n /**\n * Gets whether the verse contains multiple verses.\n */\n get hasMultiple() {\n return this._verse != null && (this._verse.includes(i.verseRangeSeparator) || this._verse.includes(i.verseSequenceIndicator));\n }\n /**\n * Gets or sets the book of the reference. Book is the 3-letter abbreviation in capital letters,\n * e.g. `'MAT'`.\n */\n get book() {\n return m.bookNumberToId(this.bookNum, \"\");\n }\n set book(e) {\n this.bookNum = m.bookIdToNumber(e);\n }\n /**\n * Gets or sets the chapter of the reference,. e.g. `'3'`.\n */\n get chapter() {\n return this.isDefault || this._chapterNum < 0 ? \"\" : this._chapterNum.toString();\n }\n set chapter(e) {\n const s = +e;\n this._chapterNum = Number.isInteger(s) ? s : -1;\n }\n /**\n * Gets or sets the verse of the reference, including range, segments, and sequences, e.g. `'4'`,\n * or `'4b-5a, 7'`.\n */\n get verse() {\n return this._verse != null ? this._verse : this.isDefault || this._verseNum < 0 ? \"\" : this._verseNum.toString();\n }\n set verse(e) {\n const { success: s, vNum: r } = i.tryGetVerseNum(e);\n this._verse = s ? void 0 : e.replace(this.rtlMark, \"\"), this._verseNum = r, !(this._verseNum >= 0) && ({ vNum: this._verseNum } = i.tryGetVerseNum(this._verse));\n }\n /**\n * Get or set Book based on book number, e.g. `42`.\n */\n get bookNum() {\n return this._bookNum;\n }\n set bookNum(e) {\n if (e <= 0 || e > m.lastBook)\n throw new v(\n \"BookNum must be greater than zero and less than or equal to last book\"\n );\n this._bookNum = e;\n }\n /**\n * Gets or sets the chapter number, e.g. `3`. `-1` if not valid.\n */\n get chapterNum() {\n return this._chapterNum;\n }\n set chapterNum(e) {\n this.chapterNum = e;\n }\n /**\n * Gets or sets verse start number, e.g. `4`. `-1` if not valid.\n */\n get verseNum() {\n return this._verseNum;\n }\n set verseNum(e) {\n this._verseNum = e;\n }\n /**\n * String representing the versification (should ONLY be used for serialization/deserialization).\n *\n * @remarks This is for backwards compatibility when ScrVers was an enumeration.\n */\n get versificationStr() {\n var e;\n return (e = this.versification) == null ? void 0 : e.name;\n }\n set versificationStr(e) {\n this.versification = this.versification != null ? new c(e) : void 0;\n }\n /**\n * Determines if the reference is valid.\n */\n get valid() {\n return this.validStatus === 0;\n }\n /**\n * Get the valid status for this reference.\n */\n get validStatus() {\n return this.validateVerse(i.verseRangeSeparators, i.verseSequenceIndicators);\n }\n /**\n * Gets the reference as a comparable integer where the book,\n * chapter, and verse each occupy three digits and the verse is 0.\n */\n get BBBCCC() {\n return i.getBBBCCCVVV(this._bookNum, this._chapterNum, 0);\n }\n /**\n * Gets the reference as a comparable integer where the book,\n * chapter, and verse each occupy three digits. If verse is not null\n * (i.e., this reference represents a complex reference with verse\n * segments or bridge) this cannot be used for an exact comparison.\n */\n get BBBCCCVVV() {\n return i.getBBBCCCVVV(this._bookNum, this._chapterNum, this._verseNum);\n }\n /**\n * Gets whether the verse is defined as an excluded verse in the versification.\n * Does not handle verse ranges.\n */\n // eslint-disable-next-line @typescript-eslint/class-literal-property-style\n get isExcluded() {\n return !1;\n }\n /**\n * Parses the reference in the specified string.\n * Optionally versification can follow reference as in GEN 3:11/4\n * Throw an exception if\n * - invalid book name\n * - chapter number is missing or not a number\n * - verse number is missing or does not start with a number\n * - versification is invalid\n * @param verseStr - string to parse e.g. 'MAT 3:11'\n */\n parse(e) {\n if (e = e.replace(this.rtlMark, \"\"), e.includes(\"/\")) {\n const o = e.split(\"/\");\n if (e = o[0], o.length > 1)\n try {\n const u = +o[1].trim();\n this.versification = new c(l[u]);\n } catch {\n throw new v(\"Invalid reference : \" + e);\n }\n }\n const s = e.trim().split(\" \");\n if (s.length !== 2)\n throw new v(\"Invalid reference : \" + e);\n const r = s[1].split(\":\"), a = +r[0];\n if (r.length !== 2 || m.bookIdToNumber(s[0]) === 0 || !Number.isInteger(a) || a < 0 || !i.isVerseParseable(r[1]))\n throw new v(\"Invalid reference : \" + e);\n this.updateInternal(s[0], r[0], r[1]);\n }\n /**\n * Simplifies this verse ref so that it has no bridging of verses or\n * verse segments like `'1a'`.\n */\n simplify() {\n this._verse = void 0;\n }\n /**\n * Makes a clone of the reference.\n *\n * @returns The cloned VerseRef.\n */\n clone() {\n return new i(this);\n }\n toString() {\n const e = this.book;\n return e === \"\" ? \"\" : `${e} ${this.chapter}:${this.verse}`;\n }\n toJSON() {\n let e = this.verse;\n (e === \"\" || e === this.verseNum.toString()) && (e = void 0);\n const s = {\n book: this.book,\n chapterNum: this.chapterNum,\n verseNum: this.verseNum,\n verse: e,\n versificationStr: this.versificationStr\n };\n return e || delete s.verse, s;\n }\n /**\n * Compares this `VerseRef` with supplied one.\n * @param verseRef - object to compare this one to.\n * @returns `true` if this `VerseRef` is equal to the supplied one, `false` otherwise.\n */\n equals(e) {\n return e instanceof i ? e._bookNum === this._bookNum && e._chapterNum === this._chapterNum && e._verseNum === this._verseNum && e.verse === this.verse && (e.versification == null && this.versification == null || e.versification != null && this.versification != null && e.versification.equals(this.versification)) : !1;\n }\n /**\n * Enumerate all individual verses contained in a VerseRef.\n * Verse ranges are indicated by \"-\" and consecutive verses by \",\"s.\n * Examples:\n * GEN 1:2 returns GEN 1:2\n * GEN 1:1a-3b,5 returns GEN 1:1a, GEN 1:2, GEN 1:3b, GEN 1:5\n * GEN 1:2a-2c returns //! ??????\n *\n * @param specifiedVersesOnly - if set to true return only verses that are\n * explicitly specified only, not verses within a range. Defaults to `false`.\n * @param verseRangeSeparators - Verse range separators.\n * Defaults to `VerseRef.verseRangeSeparators`.\n * @param verseSequenceSeparators - Verse sequence separators.\n * Defaults to `VerseRef.verseSequenceIndicators`.\n * @returns An array of all single verse references in this VerseRef.\n */\n allVerses(e = !1, s = i.verseRangeSeparators, r = i.verseSequenceIndicators) {\n if (this._verse == null || this.chapterNum <= 0)\n return [this.clone()];\n const a = [], o = E(this._verse, r);\n for (const u of o.map((f) => E(f, s))) {\n const f = this.clone();\n f.verse = u[0];\n const d = f.verseNum;\n if (a.push(f), u.length > 1) {\n const b = this.clone();\n if (b.verse = u[1], !e)\n for (let p = d + 1; p < b.verseNum; p++) {\n const J = new i(\n this._bookNum,\n this._chapterNum,\n p,\n this.versification\n );\n this.isExcluded || a.push(J);\n }\n a.push(b);\n }\n }\n return a;\n }\n /**\n * Validates a verse number using the supplied separators rather than the defaults.\n */\n validateVerse(e, s) {\n if (!this.verse)\n return this.internalValid;\n let r = 0;\n for (const a of this.allVerses(!0, e, s)) {\n const o = a.internalValid;\n if (o !== 0)\n return o;\n const u = a.BBBCCCVVV;\n if (r > u)\n return 3;\n if (r === u)\n return 4;\n r = u;\n }\n return 0;\n }\n /**\n * Gets whether a single verse reference is valid.\n */\n get internalValid() {\n return this.versification == null ? 1 : this._bookNum <= 0 || this._bookNum > m.lastBook ? 2 : (m.isCanonical(this._bookNum), 0);\n }\n setEmpty(e = i.defaultVersification) {\n this._bookNum = 0, this._chapterNum = -1, this._verse = void 0, this.versification = e;\n }\n updateInternal(e, s, r) {\n this.bookNum = m.bookIdToNumber(e), this.chapter = s, this.verse = r;\n }\n};\nn(i, \"defaultVersification\", c.English), n(i, \"verseRangeSeparator\", \"-\"), n(i, \"verseSequenceIndicator\", \",\"), n(i, \"verseRangeSeparators\", [i.verseRangeSeparator]), n(i, \"verseSequenceIndicators\", [i.verseSequenceIndicator]), n(i, \"chapterDigitShifter\", 1e3), n(i, \"bookDigitShifter\", i.chapterDigitShifter * i.chapterDigitShifter), n(i, \"bcvMaxValue\", i.chapterDigitShifter - 1), /**\n * The valid status of the VerseRef.\n */\nn(i, \"ValidStatusType\", D);\nlet M = i;\nclass v extends Error {\n}\nexport {\n _ as BookSet,\n m as Canon,\n c as ScrVers,\n l as ScrVersType,\n M as VerseRef,\n v as VerseRefException\n};\n//# sourceMappingURL=index.es.js.map\n","import React from 'react';\nimport * as DropdownMenuPrimitive from '@radix-ui/react-dropdown-menu';\nimport { Check, ChevronRight, Circle } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport const DropdownMenu = DropdownMenuPrimitive.Root;\n\nexport const DropdownMenuTrigger = DropdownMenuPrimitive.Trigger;\n\nexport const DropdownMenuGroup = DropdownMenuPrimitive.Group;\n\nexport const DropdownMenuPortal = DropdownMenuPrimitive.Portal;\n\nexport const DropdownMenuSub = DropdownMenuPrimitive.Sub;\n\nexport const DropdownMenuRadioGroup = DropdownMenuPrimitive.RadioGroup;\n\nexport type DropdownMenuSubTriggerProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.SubTrigger\n> & {\n className?: string;\n inset?: boolean;\n};\n\nexport type DropdownMenuSubContentProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.SubContent\n> & {\n className?: string;\n};\n\nexport type DropdownMenuContentProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Content\n> & {\n className?: string;\n sideOffset?: number;\n};\n\nexport type DropdownMenuItemProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Item\n> & {\n className?: string;\n inset?: boolean;\n};\n\nexport type DropdownMenuCheckboxItemProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.CheckboxItem\n> & {\n className?: string;\n checked?: boolean;\n};\n\nexport type DropdownMenuRadioItemProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.RadioItem\n> & {\n className?: string;\n};\n\nexport type DropdownMenuLabelProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Label\n> & {\n className?: string;\n inset?: boolean;\n};\n\nexport type DropdownMenuSeparatorProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Separator\n> & {\n className?: string;\n};\n\nexport type DropdownMenuShortcutProps = React.HTMLAttributes & {\n className?: string;\n};\n\nexport const DropdownMenuSubTrigger = React.forwardRef<\n React.ElementRef,\n DropdownMenuSubTriggerProps\n>(({ className, inset, children, ...props }, ref) => (\n \n {children}\n \n \n));\nDropdownMenuSubTrigger.displayName = DropdownMenuPrimitive.SubTrigger.displayName;\n\nexport const DropdownMenuSubContent = React.forwardRef<\n React.ElementRef,\n DropdownMenuSubContentProps\n>(({ className, ...props }, ref) => (\n \n));\nDropdownMenuSubContent.displayName = DropdownMenuPrimitive.SubContent.displayName;\n\nexport const DropdownMenuContent = React.forwardRef<\n React.ElementRef,\n DropdownMenuContentProps\n>(({ className, sideOffset = 4, ...props }, ref) => (\n \n \n \n));\nDropdownMenuContent.displayName = DropdownMenuPrimitive.Content.displayName;\n\n/**\n * TODO: fix: direction is not automatically handled by this component, so that shortcuts are\n * display always to the right\n */\nexport const DropdownMenuItem = React.forwardRef<\n React.ElementRef,\n DropdownMenuItemProps\n>(({ className, inset, ...props }, ref) => (\n \n));\nDropdownMenuItem.displayName = DropdownMenuPrimitive.Item.displayName;\n\nexport const DropdownMenuCheckboxItem = React.forwardRef<\n React.ElementRef,\n DropdownMenuCheckboxItemProps\n>(({ className, children, checked, ...props }, ref) => (\n \n \n \n \n \n \n {children}\n \n));\nDropdownMenuCheckboxItem.displayName = DropdownMenuPrimitive.CheckboxItem.displayName;\n\nexport const DropdownMenuRadioItem = React.forwardRef<\n React.ElementRef,\n DropdownMenuRadioItemProps\n>(({ className, children, ...props }, ref) => (\n \n \n \n \n \n \n {children}\n \n));\nDropdownMenuRadioItem.displayName = DropdownMenuPrimitive.RadioItem.displayName;\n\nexport const DropdownMenuLabel = React.forwardRef<\n React.ElementRef,\n DropdownMenuLabelProps\n>(({ className, inset, ...props }, ref) => (\n \n));\nDropdownMenuLabel.displayName = DropdownMenuPrimitive.Label.displayName;\n\nexport const DropdownMenuSeparator = React.forwardRef<\n React.ElementRef,\n DropdownMenuSeparatorProps\n>(({ className, ...props }, ref) => (\n \n));\nDropdownMenuSeparator.displayName = DropdownMenuPrimitive.Separator.displayName;\n\nexport function DropdownMenuShortcut({ className, ...props }: DropdownMenuShortcutProps) {\n return (\n \n );\n}\nDropdownMenuShortcut.displayName = 'DropdownMenuShortcut';\n","import { Canon } from '@sillsdev/scripture';\nimport { PropsWithChildren, KeyboardEvent, forwardRef } from 'react';\nimport { DropdownMenuItem as ShadDropdownMenuItem } from '@/components/shadcn-ui/dropdown-menu';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport type BookType = 'OT' | 'NT' | 'DC';\n\ntype BookMenuItemProps = PropsWithChildren<{\n /** String id of book */\n bookId: string;\n /** Callback to run when a book menu item is selected */\n handleSelectBook: () => void;\n /** Indicates if this menu item is currently selected */\n isSelected: boolean;\n /** Function that is called upon highlighting a book in the dropdown menu */\n handleHighlightBook: () => void;\n /**\n * Function that is called on pressing a key\n *\n * @param event Event that contains information about the key stroke\n */\n handleKeyDown: (event: KeyboardEvent) => void;\n /**\n * Type of book associated with this menu item, coordinates color labels ? Mock up has the labels\n * coordinated to genre\n */\n bookType: BookType;\n}>;\n\nconst BookMenuItem = forwardRef(\n (\n {\n bookId,\n handleSelectBook,\n isSelected,\n handleHighlightBook,\n handleKeyDown,\n bookType,\n children,\n }: BookMenuItemProps,\n ref,\n ) => {\n return (\n {\n // preventDefault() here prevents the entire dropdown menu from closing when selecting this item\n event.preventDefault();\n handleSelectBook();\n }}\n onKeyDown={(event: KeyboardEvent) => {\n handleKeyDown(event);\n }}\n onFocus={handleHighlightBook}\n onMouseMove={handleHighlightBook}\n >\n \n {Canon.bookIdToEnglishName(bookId)}\n \n {isSelected &&
{children}
}\n \n );\n },\n);\n\nexport default BookMenuItem;\n","import { cn } from '@/utils/shadcn-ui.util';\nimport { useCallback } from 'react';\n\nexport type ChapterSelectProps = {\n /**\n * Callback to run when a chapter div is selected\n *\n * @param chapterNumber Number of the chapter that has been selected\n */\n handleSelectChapter: (chapterNumber: number) => void;\n /** The highest chapter number in the book (of course equal to number of chapters in the book) */\n endChapter: number;\n /** The chapter number that is currently selected */\n activeChapter: number;\n /** The chapter number that is currently highlighted using keyboard or mouse navigation */\n highlightedChapter: number;\n /**\n * Callback to run when a chapter is highlighted by the user\n *\n * @param chapterNumber The chapter that is highlighted\n */\n handleHighlightedChapter: (chapterNumber: number) => void;\n};\n\nfunction ChapterSelect({\n handleSelectChapter,\n endChapter,\n activeChapter,\n highlightedChapter,\n handleHighlightedChapter,\n}: ChapterSelectProps) {\n const chapters = Array.from({ length: endChapter }, (_, i) => i + 1);\n\n const handleMouse = useCallback(\n (chapterNumber: number) => {\n handleHighlightedChapter(chapterNumber);\n },\n [handleHighlightedChapter],\n );\n\n return (\n
\n {chapters.map((chapter) => (\n {\n event.preventDefault();\n event.stopPropagation();\n handleSelectChapter(chapter);\n }}\n role=\"button\"\n onKeyDown={(event) => {\n if (event.key === 'Enter') {\n handleSelectChapter(chapter);\n }\n }}\n tabIndex={0}\n onMouseMove={() => handleMouse(chapter)}\n >\n {chapter}\n
\n ))}\n
\n );\n}\n\nexport default ChapterSelect;\n","import { DropdownMenuLabel as ShadDropdownMenuLabel } from '@/components/shadcn-ui/dropdown-menu';\nimport { Bookmark, Clock, ArrowDownWideNarrow } from 'lucide-react';\n\nexport type GoToMenuItemProps = {\n handleSort: () => void;\n handleLocationHistory: () => void;\n handleBookmarks: () => void;\n};\n\nfunction GoToMenuItem({ handleSort, handleLocationHistory, handleBookmarks }: GoToMenuItemProps) {\n return (\n \n

Go To

\n
\n \n \n \n
\n
\n );\n}\n\nexport default GoToMenuItem;\n","import BookChapterInput from '@/components/advanced/book-chapter-control/book-chapter-input.component';\nimport BookMenuItem, {\n BookType,\n} from '@/components/advanced/book-chapter-control/book-menu-item.component';\nimport ChapterSelect from '@/components/advanced/book-chapter-control/chapter-select.component';\nimport GoToMenuItem from '@/components/advanced/book-chapter-control/go-to-menu-item.component';\nimport {\n DropdownMenu as ShadDropdownMenu,\n DropdownMenuContent as ShadDropdownMenuContent,\n DropdownMenuLabel as ShadDropdownMenuLabel,\n DropdownMenuSeparator as ShadDropdownMenuSeparator,\n DropdownMenuTrigger as ShadDropdownMenuTrigger,\n} from '@/components/shadcn-ui/dropdown-menu';\nimport { Canon } from '@sillsdev/scripture';\nimport { ScriptureReference, getChaptersForBook } from 'platform-bible-utils';\nimport {\n KeyboardEvent as ReactKeyboardEvent,\n useCallback,\n useEffect,\n useLayoutEffect,\n useRef,\n useState,\n} from 'react';\n\ntype BookTypeLabels = {\n [bookType in BookType]: string;\n};\ntype BookChapterControlProps = {\n scrRef: ScriptureReference;\n handleSubmit: (scrRef: ScriptureReference) => void;\n};\n\nconst ALL_BOOK_IDS = Canon.allBookIds;\nconst BOOK_TYPE_LABELS: BookTypeLabels = {\n OT: 'Old Testament',\n NT: 'New Testament',\n DC: 'Deuterocanon',\n};\nconst BOOK_TYPE_ARRAY: BookType[] = ['OT', 'NT', 'DC'];\n// This is the height of three menu items to offset scrolling to the selected menu item\n// If you use menuItemRef.clientHeight- includes height of chapter div which is too big\nconst SCROLL_OFFSET = 32 + 32 + 32;\nconst SEARCH_QUERY_FORMATS = [\n /^(\\w+)$/i, // Matches a single word (book name or id)\n /^(\\w+)(?:\\s(\\d+))$/i, // Matches a word followed by a chapter number\n /^(\\w+)(?:\\s(\\d+):(\\d+))$/i, // Matches a word followed by a chapter and verse number\n];\nconst fetchGroupedBooks = (bookType: BookType) => {\n const groupedBooks = {\n OT: ALL_BOOK_IDS.filter((bookId) => Canon.isBookOT(bookId)),\n NT: ALL_BOOK_IDS.filter((bookId) => Canon.isBookNT(bookId)),\n DC: ALL_BOOK_IDS.filter((bookId) => Canon.isBookDC(bookId)),\n };\n return groupedBooks[bookType];\n};\nconst fetchEndChapter = (bookId: string) => {\n // getChaptersForBook returns -1 if not found in scrBookData\n // scrBookData only includes OT and NT, so all DC will return -1\n return getChaptersForBook(Canon.bookIdToNumber(bookId));\n};\n\n/**\n * Gets all of the English names from book ids\n *\n * @returns String[]\n */\nfunction getAllEnglishNames(): string[] {\n const allEnglishNames = ALL_BOOK_IDS.map((bookId) => {\n return Canon.bookIdToEnglishName(bookId);\n });\n return allEnglishNames;\n}\n\n/**\n * Determines if bookName is in allEnglishNames\n *\n * @param bookName Book English name\n * @returns True if bookName is included, false otherwise\n */\nfunction isValidBookEnglishName(bookName: string): boolean {\n return getAllEnglishNames().includes(bookName);\n}\n\n/**\n * Gets a bookId from given English name\n *\n * @param bookName Book English name\n * @returns BookId of provided bookName, undefined otherwise\n */\nfunction getBookIdFromEnglishName(bookName: string): string | undefined {\n // Convert bookName to lowercase and then capitalize the first letter\n const formattedBookName = bookName.toLowerCase().replace(/^\\w/, (c) => c.toUpperCase());\n\n if (isValidBookEnglishName(formattedBookName)) {\n const matchingBookId = ALL_BOOK_IDS.find((bookId) => {\n return Canon.bookIdToEnglishName(bookId) === formattedBookName;\n });\n return matchingBookId;\n }\n\n return undefined;\n}\n\nfunction BookChapterControl({ scrRef, handleSubmit }: BookChapterControlProps) {\n const [searchQuery, setSearchQuery] = useState('');\n const [selectedBookId, setSelectedBookId] = useState(\n Canon.bookNumberToId(scrRef.bookNum),\n );\n const [highlightedChapter, setHighlightedChapter] = useState(scrRef.chapterNum ?? 0);\n const [highlightedBookId, setHighlightedBookId] = useState(\n Canon.bookNumberToId(scrRef.bookNum),\n );\n const [isContentOpen, setIsContentOpen] = useState(false);\n const [isContentOpenDelayed, setIsContentOpenDelayed] = useState(isContentOpen);\n\n // This ref will always be defined\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const inputRef = useRef(undefined!);\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const contentRef = useRef(undefined!);\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const menuItemRef = useRef(undefined!);\n\n const fetchFilteredBooks = useCallback(\n (bookType: BookType) => {\n return fetchGroupedBooks(bookType).filter((bookId: string) => {\n const englishNameLowerCase = Canon.bookIdToEnglishName(bookId).toLowerCase();\n const normalizedQuery = searchQuery.replace(/[^a-zA-Z]/g, '').toLowerCase();\n return (\n englishNameLowerCase.includes(normalizedQuery) || // Match book name\n bookId.toLowerCase().includes(normalizedQuery) // Match book ID\n );\n });\n },\n [searchQuery],\n );\n\n const handleSearchInput = (searchString: string) => {\n setSearchQuery(searchString);\n };\n\n /**\n * Whether to prevent radix's logic from closing the dropdown. This is important because radix\n * tries to close the dropdown when the input first focuses, and we don't want it to do that. But\n * we don't want to prevent the dropdown from closing when we click away from the input, so we\n * don't want to just keep it open if the input is focused\n */\n const shouldPreventAutoClosing = useRef(false);\n\n const controlMenuState = useCallback((open: boolean) => {\n if (shouldPreventAutoClosing.current) {\n shouldPreventAutoClosing.current = false;\n return;\n }\n setIsContentOpen(open);\n }, []);\n\n const updateReference = useCallback(\n (bookId: string, shouldClose: boolean, chapter?: number, verse?: number) => {\n setHighlightedChapter(\n Canon.bookNumberToId(scrRef.bookNum) !== bookId ? 1 : scrRef.chapterNum,\n );\n\n if (shouldClose || fetchEndChapter(bookId) === -1) {\n handleSubmit({\n bookNum: Canon.bookIdToNumber(bookId),\n chapterNum: chapter || 1,\n verseNum: verse || 1,\n });\n\n setIsContentOpen(false);\n setSearchQuery('');\n return;\n }\n\n setSelectedBookId(selectedBookId !== bookId ? bookId : '');\n setIsContentOpen(!shouldClose);\n },\n [handleSubmit, scrRef.bookNum, scrRef.chapterNum, selectedBookId],\n );\n\n const handleSelectChapter = (chapterNumber: number) => {\n if (chapterNumber <= 0 || chapterNumber > fetchEndChapter(selectedBookId)) {\n return;\n }\n updateReference(selectedBookId, true, chapterNumber);\n };\n\n const handleInputSubmit = useCallback(() => {\n SEARCH_QUERY_FORMATS.forEach((format) => {\n const matches = searchQuery.match(format);\n if (matches) {\n // Book should be a bookId or an english name\n const [book, chapter = undefined, verse = undefined] = matches.slice(1);\n const englishName = getBookIdFromEnglishName(book);\n\n if (Canon.isBookIdValid(book) || englishName) {\n updateReference(\n englishName ?? book,\n true,\n chapter ? parseInt(chapter, 10) : 1,\n verse ? parseInt(verse, 10) : 1,\n );\n }\n }\n });\n }, [updateReference, searchQuery]);\n\n const handleKeyDownInput = useCallback(\n (event: ReactKeyboardEvent) => {\n if (!isContentOpen) {\n setIsContentOpen(true);\n } else if (event.key === 'ArrowDown' || event.key === 'ArrowUp') {\n if (\n typeof menuItemRef !== 'undefined' &&\n // Ref uses null\n // eslint-disable-next-line no-null/no-null\n menuItemRef.current !== null\n ) {\n menuItemRef.current.focus();\n } else if (\n typeof contentRef !== 'undefined' &&\n // Ref uses null\n // eslint-disable-next-line no-null/no-null\n contentRef.current !== null\n ) {\n contentRef.current.focus();\n }\n event.preventDefault();\n }\n },\n [isContentOpen],\n );\n\n const handleKeyDownContent = (event: ReactKeyboardEvent) => {\n // When the dropdown menu has focus, key strokes should give focus to the input component,\n // unless they're navigation keys (arrows and enter)\n const { key } = event;\n if (\n key === 'ArrowRight' ||\n key === 'ArrowLeft' ||\n key === 'ArrowDown' ||\n key === 'ArrowUp' ||\n key === 'Enter'\n ) {\n return;\n }\n\n inputRef.current.dispatchEvent(new KeyboardEvent('keydown', { key }));\n inputRef.current.focus();\n };\n\n const handleKeyDownMenuItem = (event: ReactKeyboardEvent) => {\n const { key } = event;\n if (highlightedBookId === selectedBookId) {\n if (key === 'Enter') {\n event.preventDefault();\n updateReference(selectedBookId, true, highlightedChapter);\n return;\n }\n\n let chapterOffSet = 0;\n if (key === 'ArrowRight') {\n if (highlightedChapter < fetchEndChapter(highlightedBookId)) {\n chapterOffSet = 1;\n } else {\n event.preventDefault();\n return;\n }\n } else if (key === 'ArrowLeft') {\n if (highlightedChapter > 1) {\n chapterOffSet = -1;\n } else {\n event.preventDefault();\n return;\n }\n } else if (key === 'ArrowDown') {\n chapterOffSet = 6;\n } else if (key === 'ArrowUp') {\n chapterOffSet = -6;\n }\n if (\n highlightedChapter + chapterOffSet <= 0 ||\n highlightedChapter + chapterOffSet > fetchEndChapter(highlightedBookId)\n ) {\n setHighlightedChapter(0);\n } else if (chapterOffSet !== 0) {\n setHighlightedChapter(highlightedChapter + chapterOffSet);\n event.preventDefault();\n }\n }\n };\n\n useEffect(() => {\n if (selectedBookId === highlightedBookId) {\n if (selectedBookId === Canon.bookNumberToId(scrRef.bookNum)) {\n setHighlightedChapter(scrRef.chapterNum);\n } else {\n setHighlightedChapter(1);\n }\n } else {\n setHighlightedChapter(0);\n }\n }, [highlightedBookId, scrRef.bookNum, scrRef.chapterNum, selectedBookId]);\n\n // The purpose of these useLayoutEffects and timeout is to delay the scroll just\n // enough so that the refs are defined and available when they are used after the timeout\n useLayoutEffect(() => {\n setIsContentOpenDelayed(isContentOpen);\n }, [isContentOpen]);\n\n useLayoutEffect(() => {\n const scrollTimeout = setTimeout(() => {\n if (isContentOpenDelayed && contentRef.current && menuItemRef.current) {\n const menuItemOffsetTop = menuItemRef.current.offsetTop;\n const scrollPosition = menuItemOffsetTop - SCROLL_OFFSET;\n contentRef.current.scrollTo({ top: scrollPosition, behavior: 'instant' });\n }\n }, 10);\n return () => {\n clearTimeout(scrollTimeout);\n };\n }, [isContentOpenDelayed]);\n\n return (\n
\n \n \n {\n setSelectedBookId(Canon.bookNumberToId(scrRef.bookNum));\n setHighlightedBookId(Canon.bookNumberToId(scrRef.bookNum));\n setHighlightedChapter(scrRef.chapterNum > 0 ? scrRef.chapterNum : 0);\n setIsContentOpen(true);\n inputRef.current.focus();\n }}\n onFocus={() => {\n // Radix thinks we want to close because the input is being focused. Prevent that\n shouldPreventAutoClosing.current = true;\n }}\n handleSubmit={handleInputSubmit}\n placeholder={`${Canon.bookNumberToEnglishName(scrRef.bookNum)} ${scrRef.chapterNum}:${scrRef.verseNum}`}\n />\n \n \n console.log('sorting')}\n handleLocationHistory={() => console.log('location history')}\n handleBookmarks={() => console.log('bookmarks')}\n />\n {BOOK_TYPE_ARRAY.map(\n (bookType, bookTypeIndex) =>\n fetchFilteredBooks(bookType).length > 0 && (\n
\n \n {BOOK_TYPE_LABELS[bookType]}\n \n\n {fetchFilteredBooks(bookType).map((bookId) => (\n
\n updateReference(bookId, false)}\n isSelected={selectedBookId === bookId}\n handleHighlightBook={() => setHighlightedBookId(bookId)}\n handleKeyDown={handleKeyDownMenuItem}\n bookType={bookType}\n ref={(element: HTMLDivElement) => {\n if (selectedBookId === bookId) menuItemRef.current = element;\n }}\n >\n {\n setHighlightedChapter(chapterNumber);\n }}\n />\n \n
\n ))}\n {BOOK_TYPE_ARRAY.length - 1 !== bookTypeIndex ? (\n \n ) : undefined}\n
\n ),\n )}\n \n
\n
\n );\n}\n\nexport default BookChapterControl;\n","import React from 'react';\nimport { Slot } from '@radix-ui/react-slot';\nimport { cva, type VariantProps } from 'class-variance-authority';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport const buttonVariants = cva(\n 'pr-twp tw-inline-flex tw-items-center tw-justify-center tw-whitespace-nowrap tw-rounded-md tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-colors focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50',\n {\n variants: {\n variant: {\n default: 'tw-bg-primary tw-text-primary-foreground hover:tw-bg-primary/90',\n destructive: 'tw-bg-destructive tw-text-destructive-foreground hover:tw-bg-destructive/90',\n outline:\n 'tw-border tw-border-input tw-bg-background hover:tw-bg-accent hover:tw-text-accent-foreground',\n secondary: 'tw-bg-secondary tw-text-secondary-foreground hover:tw-bg-secondary/80',\n ghost: 'hover:tw-bg-accent hover:tw-text-accent-foreground',\n link: 'tw-text-primary tw-underline-offset-4 hover:tw-underline',\n },\n size: {\n default: 'tw-h-10 tw-px-4 tw-py-2',\n sm: 'tw-h-9 tw-rounded-md tw-px-3',\n lg: 'tw-h-11 tw-rounded-md tw-px-8',\n icon: 'tw-h-10 tw-w-10',\n },\n },\n defaultVariants: {\n variant: 'default',\n size: 'default',\n },\n },\n);\n\nexport interface ButtonProps\n extends React.ButtonHTMLAttributes,\n VariantProps {\n asChild?: boolean;\n}\n\nexport const Button = React.forwardRef(\n ({ className, variant, size, asChild = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'button';\n return (\n \n );\n },\n);\nButton.displayName = 'Button';\n","import React from 'react';\nimport * as LabelPrimitive from '@radix-ui/react-label';\nimport { cva, type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst labelVariants = cva(\n 'tw-text-sm tw-font-medium tw-leading-none peer-disabled:tw-cursor-not-allowed peer-disabled:tw-opacity-70',\n);\n\nexport const Label = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef & VariantProps\n>(({ className, ...props }, ref) => (\n \n));\nLabel.displayName = LabelPrimitive.Root.displayName;\n","import React from 'react';\nimport * as RadioGroupPrimitive from '@radix-ui/react-radio-group';\nimport { Circle } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst RadioGroup = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => {\n return (\n \n );\n});\nRadioGroup.displayName = RadioGroupPrimitive.Root.displayName;\n\nconst RadioGroupItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => {\n return (\n \n \n \n \n \n );\n});\nRadioGroupItem.displayName = RadioGroupPrimitive.Item.displayName;\n\nexport { RadioGroup, RadioGroupItem };\n","import React from 'react';\nimport * as PopoverPrimitive from '@radix-ui/react-popover';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Popover = PopoverPrimitive.Root;\n\nconst PopoverTrigger = PopoverPrimitive.Trigger;\n\nconst PopoverContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, align = 'center', sideOffset = 4, ...props }, ref) => (\n \n \n \n));\nPopoverContent.displayName = PopoverPrimitive.Content.displayName;\n\nexport { Popover, PopoverTrigger, PopoverContent };\n","import React from 'react';\nimport * as DialogPrimitive from '@radix-ui/react-dialog';\nimport { X } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Dialog = DialogPrimitive.Root;\n\nconst DialogTrigger = DialogPrimitive.Trigger;\n\nconst DialogPortal = DialogPrimitive.Portal;\n\nconst DialogClose = DialogPrimitive.Close;\n\nconst DialogOverlay = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nDialogOverlay.displayName = DialogPrimitive.Overlay.displayName;\n\nconst DialogContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, ...props }, ref) => (\n \n \n \n {children}\n \n \n Close\n \n \n \n));\nDialogContent.displayName = DialogPrimitive.Content.displayName;\n\nfunction DialogHeader({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nDialogHeader.displayName = 'DialogHeader';\n\nfunction DialogFooter({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nDialogFooter.displayName = 'DialogFooter';\n\nconst DialogTitle = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nDialogTitle.displayName = DialogPrimitive.Title.displayName;\n\nconst DialogDescription = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nDialogDescription.displayName = DialogPrimitive.Description.displayName;\n\nexport {\n Dialog,\n DialogPortal,\n DialogOverlay,\n DialogClose,\n DialogTrigger,\n DialogContent,\n DialogHeader,\n DialogFooter,\n DialogTitle,\n DialogDescription,\n};\n","import React from 'react';\nimport { type DialogProps } from '@radix-ui/react-dialog';\nimport { Command as CommandPrimitive } from 'cmdk';\nimport { Search } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Dialog, DialogContent } from '@/components/shadcn-ui/dialog';\n\nconst Command = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nCommand.displayName = CommandPrimitive.displayName;\n\ninterface CommandDialogProps extends DialogProps {}\n\nfunction CommandDialog({ children, ...props }: CommandDialogProps) {\n return (\n \n \n \n {children}\n \n \n \n );\n}\n\nconst CommandInput = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n
\n \n \n
\n));\n\nCommandInput.displayName = CommandPrimitive.Input.displayName;\n\nconst CommandList = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\n\nCommandList.displayName = CommandPrimitive.List.displayName;\n\nconst CommandEmpty = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>((props, ref) => (\n \n));\n\nCommandEmpty.displayName = CommandPrimitive.Empty.displayName;\n\nconst CommandGroup = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\n\nCommandGroup.displayName = CommandPrimitive.Group.displayName;\n\nconst CommandSeparator = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nCommandSeparator.displayName = CommandPrimitive.Separator.displayName;\n\nconst CommandItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\n\nCommandItem.displayName = CommandPrimitive.Item.displayName;\n\nfunction CommandShortcut({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nCommandShortcut.displayName = 'CommandShortcut';\n\nexport {\n Command,\n CommandDialog,\n CommandInput,\n CommandList,\n CommandEmpty,\n CommandGroup,\n CommandItem,\n CommandShortcut,\n CommandSeparator,\n};\n","import { useState } from 'react';\nimport { Check, ChevronsUpDown } from 'lucide-react';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport { Popover, PopoverContent, PopoverTrigger } from '@/components/shadcn-ui/popover';\nimport {\n Command,\n CommandEmpty,\n CommandInput,\n CommandItem,\n CommandList,\n} from '@/components/shadcn-ui/command';\nimport { PopoverProps } from '@radix-ui/react-popover';\n\nexport type ComboBoxLabelOption = { label: string };\nexport type ComboBoxOption = string | number | ComboBoxLabelOption;\n\nexport type ComboBoxProps = {\n /** Optional unique identifier */\n id?: string;\n /** Text label title for combobox */\n /** List of available options for the dropdown menu */\n options?: readonly T[];\n /** Additional css classes to help with unique styling of the combo box */\n className?: string;\n /**\n * The selected value that the combo box currently holds. Must be shallow equal to one of the\n * options entries.\n */\n value?: T;\n /** Triggers when content of textfield is changed */\n onChange?: (newValue: T) => void;\n /** Used to determine the string value for a given option. */\n getOptionLabel?: (option: ComboBoxOption) => string;\n /** Text displayed on button if `value` is undefined */\n buttonPlaceholder?: string;\n /** Placeholder text for text field */\n textPlaceholder?: string;\n /** Text to display when no options match input */\n commandEmptyMessage?: string;\n /** Variant of button */\n buttonVariant?: ButtonProps['variant'];\n /** Text direction ltr or rtl */\n dir?: Direction;\n /** Optional boolean to set if trigger should be disabled */\n isDisabled?: boolean;\n} & PopoverProps;\n\ntype Direction = 'ltr' | 'rtl';\n\nfunction getOptionLabelDefault(option: ComboBoxOption): string {\n if (typeof option === 'string') {\n return option;\n }\n if (typeof option === 'number') {\n return option.toString();\n }\n return option.label;\n}\n\n/**\n * Autocomplete input and command palette with a list of suggestions.\n *\n * Thanks to Shadcn for heavy inspiration and documentation\n * https://ui.shadcn.com/docs/components/combobox\n */\nfunction ComboBox({\n id,\n options = [],\n className,\n value,\n onChange = () => {},\n getOptionLabel = getOptionLabelDefault,\n buttonPlaceholder = '',\n textPlaceholder = '',\n commandEmptyMessage = 'No option found',\n buttonVariant = 'outline',\n dir = 'ltr',\n isDisabled = false,\n ...props\n}: ComboBoxProps) {\n const [open, setOpen] = useState(false);\n\n return (\n \n \n \n \n {value ? getOptionLabel(value) : buttonPlaceholder}\n \n \n \n \n \n \n \n {commandEmptyMessage}\n \n {options.map((option) => (\n {\n onChange(option);\n setOpen(false);\n }}\n >\n \n {getOptionLabel(option)}\n \n ))}\n \n \n \n \n );\n}\n\nexport default ComboBox;\n","import { useMemo } from 'react';\nimport ComboBox from '@/components/basics/combo-box.component';\nimport { Label } from '@/components/shadcn-ui/label';\n\nexport type ChapterRangeSelectorProps = {\n startChapter: number;\n endChapter: number;\n handleSelectStartChapter: (chapter: number) => void;\n handleSelectEndChapter: (chapter: number) => void;\n isDisabled?: boolean;\n chapterCount: number;\n};\n\nexport default function ChapterRangeSelector({\n startChapter,\n endChapter,\n handleSelectStartChapter,\n handleSelectEndChapter,\n isDisabled = false,\n chapterCount,\n}: ChapterRangeSelectorProps) {\n const chapterOptions = useMemo(\n () => Array.from({ length: chapterCount }, (_, index) => index + 1),\n [chapterCount],\n );\n\n const onChangeStartChapter = (value: number) => {\n handleSelectStartChapter(value);\n if (value > endChapter) {\n handleSelectEndChapter(value);\n }\n };\n\n const onChangeEndChapter = (value: number) => {\n handleSelectEndChapter(value);\n if (value < startChapter) {\n handleSelectStartChapter(value);\n }\n };\n\n return (\n <>\n \n option.toString()}\n value={startChapter}\n />\n\n \n option.toString()}\n value={endChapter}\n />\n \n );\n}\n","import { Button } from '@/components/shadcn-ui/button';\nimport { Label } from '@/components/shadcn-ui/label';\nimport { RadioGroup, RadioGroupItem } from '@/components/shadcn-ui/radio-group';\nimport { Canon } from '@sillsdev/scripture';\nimport { LocalizedStringValue } from 'platform-bible-utils';\nimport { useState } from 'react';\nimport ChapterRangeSelector, {\n ChapterRangeSelectorProps,\n} from '../basics/chapter-range-selector.component';\n\nexport enum BookSelectionMode {\n CURRENT_BOOK = 'current book',\n CHOOSE_BOOKS = 'choose books',\n}\n\n/**\n * Object containing all keys used for localization in this component. If you're using this\n * component in an extension, you can pass it into the useLocalizedStrings hook to easily obtain the\n * localized strings and pass them into the localizedStrings prop of this component\n */\nexport const BOOK_SELECTOR_STRING_KEYS = Object.freeze([\n '%webView_bookSelector_currentBook%',\n '%webView_bookSelector_choose%',\n '%webView_bookSelector_chooseBooks%',\n] as const);\n\nexport type BookSelectorLocalizedStrings = {\n [localizedInventoryKey in (typeof BOOK_SELECTOR_STRING_KEYS)[number]]?: LocalizedStringValue;\n};\n\n/**\n * Gets the localized value for the provided key\n *\n * @param strings Object containing localized string\n * @param key Key for a localized string\n * @returns The localized value for the provided key, if available. Returns the key if no localized\n * value is available\n */\nconst localizeString = (\n strings: BookSelectorLocalizedStrings,\n key: keyof BookSelectorLocalizedStrings,\n) => {\n return strings[key] ?? key;\n};\n\ntype BookSelectorProps = ChapterRangeSelectorProps & {\n handleBookSelectionModeChange: (newMode: BookSelectionMode) => void;\n currentBookName: string;\n onSelectBooks: () => void;\n selectedBookIds: string[];\n localizedStrings: BookSelectorLocalizedStrings;\n};\n\nexport default function BookSelector({\n handleBookSelectionModeChange,\n currentBookName,\n onSelectBooks,\n selectedBookIds,\n chapterCount,\n endChapter,\n handleSelectEndChapter,\n startChapter,\n handleSelectStartChapter,\n localizedStrings,\n}: BookSelectorProps) {\n const currentBookText = localizeString(localizedStrings, '%webView_bookSelector_currentBook%');\n const chooseText = localizeString(localizedStrings, '%webView_bookSelector_choose%');\n const chooseBooksText = localizeString(localizedStrings, '%webView_bookSelector_chooseBooks%');\n\n const [bookSelectionMode, setBookSelectionMode] = useState(\n BookSelectionMode.CURRENT_BOOK,\n );\n\n const onSelectionModeChange = (newMode: BookSelectionMode) => {\n setBookSelectionMode(newMode);\n handleBookSelectionModeChange(newMode);\n };\n\n return (\n onSelectionModeChange(value as BookSelectionMode)}\n >\n
\n
\n
\n \n \n
\n \n
\n \n
\n
\n
\n
\n \n \n
\n \n onSelectBooks()}\n >\n {chooseText}\n \n
\n
\n \n );\n}\n","import { DropdownMenuTrigger } from '@radix-ui/react-dropdown-menu';\nimport { FilterIcon } from 'lucide-react';\nimport { Table } from '@tanstack/react-table';\n\nimport { Button } from '@/components/shadcn-ui/button';\nimport {\n DropdownMenu,\n DropdownMenuCheckboxItem,\n DropdownMenuContent,\n DropdownMenuLabel,\n DropdownMenuSeparator,\n} from '@/components/shadcn-ui/dropdown-menu';\n\ninterface DataTableViewOptionsProps {\n table: Table;\n}\n\nfunction DataTableViewOptions({ table }: DataTableViewOptionsProps) {\n return (\n \n \n \n \n \n Toggle columns\n \n {table\n .getAllColumns()\n .filter((column) => column.getCanHide())\n .map((column) => {\n return (\n column.toggleVisibility(!!value)}\n >\n {column.id}\n \n );\n })}\n \n \n );\n}\n\nexport default DataTableViewOptions;\n","import React from 'react';\nimport * as SelectPrimitive from '@radix-ui/react-select';\nimport { Check, ChevronDown, ChevronUp } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Select = SelectPrimitive.Root;\n\nconst SelectGroup = SelectPrimitive.Group;\n\nconst SelectValue = SelectPrimitive.Value;\n\nconst SelectTrigger = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, ...props }, ref) => (\n span]:tw-line-clamp-1',\n className,\n )}\n {...props}\n >\n {children}\n \n \n \n \n));\nSelectTrigger.displayName = SelectPrimitive.Trigger.displayName;\n\nconst SelectScrollUpButton = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n));\nSelectScrollUpButton.displayName = SelectPrimitive.ScrollUpButton.displayName;\n\nconst SelectScrollDownButton = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n));\nSelectScrollDownButton.displayName = SelectPrimitive.ScrollDownButton.displayName;\n\nconst SelectContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, position = 'popper', ...props }, ref) => (\n \n \n \n \n {children}\n \n \n \n \n));\nSelectContent.displayName = SelectPrimitive.Content.displayName;\n\nconst SelectLabel = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSelectLabel.displayName = SelectPrimitive.Label.displayName;\n\nconst SelectItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, ...props }, ref) => (\n \n \n \n \n \n \n\n {children}\n \n));\nSelectItem.displayName = SelectPrimitive.Item.displayName;\n\nconst SelectSeparator = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSelectSeparator.displayName = SelectPrimitive.Separator.displayName;\n\nexport {\n Select,\n SelectGroup,\n SelectValue,\n SelectTrigger,\n SelectContent,\n SelectLabel,\n SelectItem,\n SelectSeparator,\n SelectScrollUpButton,\n SelectScrollDownButton,\n};\n","import { ChevronLeftIcon, ChevronRightIcon, ArrowLeftIcon, ArrowRightIcon } from 'lucide-react';\nimport { Table } from '@tanstack/react-table';\n\nimport { Button } from '@/components/shadcn-ui/button';\nimport {\n Select,\n SelectContent,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\n\ninterface DataTablePaginationProps {\n table: Table;\n}\n\nfunction DataTablePagination({ table }: DataTablePaginationProps) {\n return (\n
\n
\n
\n {table.getFilteredSelectedRowModel().rows.length} of{' '}\n {table.getFilteredRowModel().rows.length} row(s) selected\n
\n
\n

Rows per page

\n {\n table.setPageSize(Number(value));\n }}\n >\n \n \n \n \n {[10, 20, 30, 40, 50].map((pageSize) => (\n \n {pageSize}\n \n ))}\n \n \n
\n
\n Page {table.getState().pagination.pageIndex + 1} of {table.getPageCount()}\n
\n
\n table.setPageIndex(0)}\n disabled={!table.getCanPreviousPage()}\n >\n Go to first page\n \n \n table.previousPage()}\n disabled={!table.getCanPreviousPage()}\n >\n Go to previous page\n \n \n table.nextPage()}\n disabled={!table.getCanNextPage()}\n >\n Go to next page\n \n \n table.setPageIndex(table.getPageCount() - 1)}\n disabled={!table.getCanNextPage()}\n >\n Go to last page\n \n \n
\n
\n
\n );\n}\n\nexport default DataTablePagination;\n","import React from 'react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Table = React.forwardRef<\n HTMLTableElement,\n React.HTMLAttributes & { stickyHeader?: boolean }\n>(({ className, stickyHeader, ...props }, ref) => (\n
\n \n
\n));\nTable.displayName = 'Table';\n\nconst TableHeader = React.forwardRef<\n HTMLTableSectionElement,\n React.HTMLAttributes & { stickyHeader?: boolean }\n>(({ className, stickyHeader, ...props }, ref) => (\n \n));\nTableHeader.displayName = 'TableHeader';\n\nconst TableBody = React.forwardRef<\n HTMLTableSectionElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableBody.displayName = 'TableBody';\n\nconst TableFooter = React.forwardRef<\n HTMLTableSectionElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n tr]:last:tw-border-b-0', className)}\n {...props}\n />\n));\nTableFooter.displayName = 'TableFooter';\n\nconst TableRow = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nTableRow.displayName = 'TableRow';\n\nconst TableHead = React.forwardRef<\n HTMLTableCellElement,\n React.ThHTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableHead.displayName = 'TableHead';\n\nconst TableCell = React.forwardRef<\n HTMLTableCellElement,\n React.TdHTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableCell.displayName = 'TableCell';\n\nconst TableCaption = React.forwardRef<\n HTMLTableCaptionElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableCaption.displayName = 'TableCaption';\n\nexport { Table, TableHeader, TableBody, TableFooter, TableHead, TableRow, TableCell, TableCaption };\n","import { useState } from 'react';\n\nimport {\n ColumnFiltersState,\n flexRender,\n getCoreRowModel,\n getFilteredRowModel,\n getPaginationRowModel,\n getSortedRowModel,\n SortingState,\n ColumnDef as TSColumnDef,\n Row as TSRow,\n RowSelectionState as TSRowSelectionState,\n SortDirection as TSSortDirection,\n Table as TSTable,\n useReactTable,\n VisibilityState,\n} from '@tanstack/react-table';\n\nimport DataTableViewOptions from '@/components/advanced/data-table/data-table-column-toggle.component';\nimport DataTablePagination from '@/components/advanced/data-table/data-table-pagination.component';\nimport { Button } from '@/components/shadcn-ui/button';\nimport {\n Table,\n TableBody,\n TableCell,\n TableHead,\n TableHeader,\n TableRow,\n} from '@/components/shadcn-ui/table';\n\nexport type ColumnDef = TSColumnDef;\nexport type RowContents = TSRow;\nexport type TableContents = TSTable;\nexport type SortDirection = TSSortDirection;\nexport type RowSelectionState = TSRowSelectionState;\n\ninterface DataTableProps {\n columns: ColumnDef[];\n data: TData[];\n enablePagination?: boolean;\n showPaginationControls?: boolean;\n showColumnVisibilityControls?: boolean;\n stickyHeader?: boolean;\n onRowClickHandler?: (row: RowContents, table: TableContents) => void;\n}\n\n/**\n * Feature-rich table component that infuses our basic shadcn-based Table component with features\n * from TanStack's React Table library\n */\nfunction DataTable({\n columns,\n data,\n enablePagination = false,\n showPaginationControls = false,\n showColumnVisibilityControls = false,\n stickyHeader = false,\n onRowClickHandler = () => {},\n}: DataTableProps) {\n const [sorting, setSorting] = useState([]);\n const [columnFilters, setColumnFilters] = useState([]);\n const [columnVisibility, setColumnVisibility] = useState({});\n const [rowSelection, setRowSelection] = useState({});\n\n const table = useReactTable({\n data,\n columns,\n getCoreRowModel: getCoreRowModel(),\n ...(enablePagination && { getPaginationRowModel: getPaginationRowModel() }),\n onSortingChange: setSorting,\n getSortedRowModel: getSortedRowModel(),\n onColumnFiltersChange: setColumnFilters,\n getFilteredRowModel: getFilteredRowModel(),\n onColumnVisibilityChange: setColumnVisibility,\n onRowSelectionChange: setRowSelection,\n state: {\n sorting,\n columnFilters,\n columnVisibility,\n rowSelection,\n },\n });\n\n return (\n
\n {showColumnVisibilityControls && }\n \n \n {table.getHeaderGroups().map((headerGroup) => (\n \n {headerGroup.headers.map((header) => {\n return (\n \n {header.isPlaceholder\n ? undefined\n : flexRender(header.column.columnDef.header, header.getContext())}\n \n );\n })}\n \n ))}\n \n \n {table.getRowModel().rows?.length ? (\n table.getRowModel().rows.map((row) => (\n onRowClickHandler(row, table)}\n key={row.id}\n data-state={row.getIsSelected() && 'selected'}\n >\n {row.getVisibleCells().map((cell) => (\n \n {flexRender(cell.column.columnDef.cell, cell.getContext())}\n \n ))}\n \n ))\n ) : (\n \n \n No results.\n \n \n )}\n \n
\n {enablePagination && (\n
\n table.previousPage()}\n disabled={!table.getCanPreviousPage()}\n >\n Previous\n \n table.nextPage()}\n disabled={!table.getCanNextPage()}\n >\n Next\n \n
\n )}\n {enablePagination && showPaginationControls && }\n
\n );\n}\n\nexport default DataTable;\n","import {\n Table,\n TableBody,\n TableCell,\n TableHead,\n TableHeader,\n TableRow,\n} from '@/components/shadcn-ui/table';\nimport { Canon } from '@sillsdev/scripture';\nimport { deepEqual, LanguageStrings, ScriptureReference } from 'platform-bible-utils';\nimport { useMemo } from 'react';\nimport { InventoryItemOccurrence } from './inventory-utils';\n\n/** Props for the OccurrencesTable component */\ntype OccurrencesTableProps = {\n /** Data that contains scriptures references and snippets of scripture */\n occurrenceData: InventoryItemOccurrence[];\n /** Callback function that is executed when the scripture reference is changed */\n setScriptureReference: (scriptureReference: ScriptureReference) => void;\n /**\n * Object with all localized strings that the OccurrencesTable needs to work well across multiple\n * languages\n */\n localizedStrings: LanguageStrings;\n};\n\n/**\n * Table that shows occurrences of specified inventory item(s). The first column shows the related\n * scripture reference. The second column shows the snippet of scripture that contains the specified\n * inventory item\n */\nfunction OccurrencesTable({\n occurrenceData,\n setScriptureReference,\n localizedStrings,\n}: OccurrencesTableProps) {\n const referenceHeaderText =\n localizedStrings['%webView_inventory_occurrences_table_header_reference%'];\n const occurrenceHeaderText =\n localizedStrings['%webView_inventory_occurrences_table_header_occurrence%'];\n\n const occurrences: InventoryItemOccurrence[] = useMemo(() => {\n const uniqueOccurrences: InventoryItemOccurrence[] = [];\n\n occurrenceData.forEach((occurrence) => {\n if (!uniqueOccurrences.some((uniqueOccurrence) => deepEqual(uniqueOccurrence, occurrence))) {\n uniqueOccurrences.push(occurrence);\n }\n });\n\n return uniqueOccurrences;\n }, [occurrenceData]);\n\n return (\n \n \n \n {referenceHeaderText}\n {occurrenceHeaderText}\n \n \n \n {occurrences.length > 0 &&\n occurrences.map((occurrence) => (\n {\n setScriptureReference(occurrence.reference);\n }}\n >\n {`${Canon.bookNumberToEnglishName(occurrence.reference.bookNum)} ${occurrence.reference.chapterNum}:${occurrence.reference.verseNum}`}\n {occurrence.text}\n \n ))}\n \n
\n );\n}\n\nexport default OccurrencesTable;\n","import React from 'react';\nimport * as CheckboxPrimitive from '@radix-ui/react-checkbox';\nimport { Check } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Checkbox = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n \n \n));\nCheckbox.displayName = CheckboxPrimitive.Root.displayName;\n\nexport default Checkbox;\n","import { Canon } from '@sillsdev/scripture';\nimport { ScriptureReference } from 'platform-bible-utils';\n\n/* #region Types */\n\n/**\n * Status of items that appear in inventories. 'approved' and 'unapproved' items are defined in the\n * project's `Settings.xml`. All other items are defined as 'unknown'\n */\nexport type Status = 'approved' | 'unapproved' | 'unknown';\n\n/** Occurrence of item in inventory. Primarily used by table that shows occurrences */\nexport type InventoryItemOccurrence = {\n /** Reference to scripture where the item appears */\n reference: ScriptureReference;\n /** Snippet of scripture that contains the occurrence */\n text: string;\n};\n\n/** Data structure that contains all information on an item that is shown in an inventory */\nexport type InventoryTableData = {\n /**\n * The item (e.g. a character in the characters inventory, a marker in the marker inventory) In\n * most cases the array will only have one element. In case of additional items (e.g. the\n * preceding marker in the markers check), the primary item should be stored in the first index.\n * To show additional items in the inventory, make sure to configure the `additionalItemsLabels`\n * prop for the Inventory component\n */\n items: string[];\n /** The number of times this item occurs in the selected scope */\n count: number;\n /** The status of this item (see documentation for `Status` type for more information) */\n status: Status;\n /** Occurrences of this item in the scripture text for the selected scope */\n occurrences: InventoryItemOccurrence[];\n};\n\n/* #endregion */\n\n/* #region Functions */\n\n/**\n * Splits USFM string into shorter line-like segments\n *\n * @param text A single (likely very large) USFM string\n * @returns An array containing the input text, split into shorter segments\n */\nexport const getLinesFromUSFM = (text: string) => {\n // Splits on (CR)LF, CR, \\v, \\c and \\id\n return text.split(/(?:\\r?\\n|\\r)|(?=(?:\\\\(?:v|c|id)))/g);\n};\n\n/**\n * Extracts chapter or verse number from USFM strings that start with a \\c or \\v marker\n *\n * @param text USFM string that is expected to start with \\c or \\v marker\n * @returns Chapter or verse number if one is found. Else returns 0.\n */\nexport const getNumberFromUSFM = (text: string): number | undefined => {\n // Captures all digits that follow \\v or \\c markers followed by whitespace located at the start of a string\n const regex = /^\\\\[vc]\\s+(\\d+)/;\n const match = text.match(regex);\n\n if (match) {\n return +match[1];\n }\n return undefined;\n};\n\n/**\n * Gets book ID from USFM string that starts with the \\id marker, and returns book number for it\n *\n * @param text USFM string that is expected to start with \\id marker\n * @returns Book number corresponding to the \\id marker in the input text. Returns 0 if no marker is\n * found or the marker is not valid\n */\nexport const getBookNumFromId = (text: string): number => {\n // Captures all digits that follow an \\id marker followed by whitespace located at the start of a string\n const match = text.match(/^\\\\id\\s+([A-Za-z]+)/);\n if (match) {\n return Canon.bookIdToNumber(match[1]);\n }\n return 0;\n};\n\n/**\n * Gets the status for an item, typically used in the Inventory component\n *\n * @param item The item for which the status is being requested\n * @param approvedItems Array of approved items, typically as defined in `Settings.xml`\n * @param unapprovedItems Array of unapproved items, typically as defined in `Settings.xml`\n * @returns The status for the specified item\n */\nexport const getStatusForItem = (\n item: string,\n approvedItems: string[],\n unapprovedItems: string[],\n): Status => {\n if (unapprovedItems.includes(item)) return 'unapproved';\n if (approvedItems.includes(item)) return 'approved';\n return 'unknown';\n};\n\n/* #endregion */\n","import React from 'react';\nimport * as TogglePrimitive from '@radix-ui/react-toggle';\nimport { cva, type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst toggleVariants = cva(\n 'pr-twp tw-inline-flex tw-items-center tw-justify-center tw-rounded-md tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-colors hover:tw-bg-muted hover:tw-text-muted-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50 data-[state=on]:tw-bg-accent data-[state=on]:tw-text-accent-foreground',\n {\n variants: {\n variant: {\n default: 'tw-bg-transparent',\n outline:\n 'tw-border tw-border-input tw-bg-transparent hover:tw-bg-accent hover:tw-text-accent-foreground',\n },\n size: {\n default: 'tw-h-10 tw-px-3',\n sm: 'tw-h-9 tw-px-2.5',\n lg: 'tw-h-11 tw-px-5',\n },\n },\n defaultVariants: {\n variant: 'default',\n size: 'default',\n },\n },\n);\n\nconst Toggle = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef & VariantProps\n>(({ className, variant, size, ...props }, ref) => (\n \n));\n\nToggle.displayName = TogglePrimitive.Root.displayName;\n\nexport { Toggle, toggleVariants };\n","import React from 'react';\nimport * as ToggleGroupPrimitive from '@radix-ui/react-toggle-group';\nimport { type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { toggleVariants } from '@/components/shadcn-ui/toggle';\n\nconst ToggleGroupContext = React.createContext>({\n size: 'default',\n variant: 'default',\n});\n\nconst ToggleGroup = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef &\n VariantProps\n>(({ className, variant, size, children, ...props }, ref) => (\n \n \n {children}\n \n \n));\n\nToggleGroup.displayName = ToggleGroupPrimitive.Root.displayName;\n\nconst ToggleGroupItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef &\n VariantProps\n>(({ className, children, variant, size, ...props }, ref) => {\n const context = React.useContext(ToggleGroupContext);\n\n return (\n \n {children}\n \n );\n});\n\nToggleGroupItem.displayName = ToggleGroupPrimitive.Item.displayName;\n\nexport { ToggleGroup, ToggleGroupItem };\n","import { ColumnDef, SortDirection } from '@/components/advanced/data-table/data-table.component';\nimport { Button } from '@/components/shadcn-ui/button';\nimport { ToggleGroup, ToggleGroupItem } from '@/components/shadcn-ui/toggle-group';\nimport {\n ArrowDownIcon,\n ArrowUpDownIcon,\n ArrowUpIcon,\n CircleCheckIcon,\n CircleHelpIcon,\n CircleXIcon,\n} from 'lucide-react';\nimport { ReactNode } from 'react';\nimport { InventoryTableData, Status } from './inventory-utils';\n\n/**\n * Gets an icon that indicates the current sorting direction based on the provided input\n *\n * @param sortDirection Sorting direction. Can be ascending ('asc'), descending ('desc') or false (\n * i.e. not sorted)\n * @returns The appropriate sorting icon for the provided sorting direction\n */\nconst getSortingIcon = (sortDirection: false | SortDirection): ReactNode => {\n if (sortDirection === 'asc') {\n return ;\n }\n if (sortDirection === 'desc') {\n return ;\n }\n return ;\n};\n\n/**\n * Function that creates the item column for inventories\n *\n * @param itemLabel Localized label for the item column (e.g. 'Character', 'Repeated Word', etc.)\n * @returns Column that shows the inventory items. Should be used with the DataTable component\n */\nexport const inventoryItemColumn = (itemLabel: string): ColumnDef => {\n return {\n accessorKey: 'item',\n accessorFn: (row: InventoryTableData) => row.items[0],\n header: ({ column }) => (\n \n ),\n };\n};\n\n/**\n * Function that creates the additional item columns for inventories\n *\n * @param additionalItemLabel Localized label for the additional item column (e.g. 'Preceding\n * Marker')\n * @param additionalItemIndex Index that locates the desired item in the items array of the\n * inventory\n * @returns Column that shows additional inventory items. Should be used with the DataTable\n * component\n */\nexport const inventoryAdditionalItemColumn = (\n additionalItemLabel: string,\n additionalItemIndex: number,\n): ColumnDef => {\n return {\n accessorKey: `item${additionalItemIndex}`,\n accessorFn: (row: InventoryTableData) => row.items[additionalItemIndex],\n header: ({ column }) => (\n \n ),\n };\n};\n\n/**\n * Function that creates the count column for inventories. Should be used with the DataTable\n * component.\n *\n * @param itemLabel Localized label for the count column\n * @returns Column that shows the number of occurrences of the related inventory items\n */\nexport const inventoryCountColumn = (countLabel: string): ColumnDef => {\n return {\n accessorKey: 'count',\n header: ({ column }) => (\n
\n \n
\n ),\n cell: ({ row }) =>
{row.getValue('count')}
,\n };\n};\n\n/**\n * Function that updates project settings when status for item(s) changes\n *\n * @param changedItems Array of items for which the status is being updated\n * @param newStatus The status that the items are being given\n * @param approvedItems Array of currently approved items\n * @param onApprovedItemsChange Callback function that stores the updated list of approved items\n * @param unapprovedItems Array of currently unapproved items\n * @param onUnapprovedItemsChange Callback function that stores the updated list of unapproved items\n */\nconst statusChangeHandler = (\n changedItems: string[],\n newStatus: Status,\n approvedItems: string[],\n onApprovedItemsChange: (items: string[]) => void,\n unapprovedItems: string[],\n onUnapprovedItemsChange: (items: string[]) => void,\n) => {\n let newApprovedItems: string[] = [...approvedItems];\n changedItems.forEach((item) => {\n if (newStatus === 'approved') {\n if (!newApprovedItems.includes(item)) {\n newApprovedItems.push(item);\n }\n } else {\n newApprovedItems = newApprovedItems.filter((validItem) => validItem !== item);\n }\n });\n onApprovedItemsChange(newApprovedItems);\n\n let newUnapprovedItems: string[] = [...unapprovedItems];\n changedItems.forEach((item) => {\n if (newStatus === 'unapproved') {\n if (!newUnapprovedItems.includes(item)) {\n newUnapprovedItems.push(item);\n }\n } else {\n newUnapprovedItems = newUnapprovedItems.filter((unapprovedItem) => unapprovedItem !== item);\n }\n });\n onUnapprovedItemsChange(newUnapprovedItems);\n};\n\n/**\n * Function that creates the status column for inventories. Should be used with the DataTable\n * component.\n *\n * @param statusLabel Localized label for the status column\n * @param approvedItems Array of approved items, typically as defined in `Settings.xml`\n * @param onApprovedItemsChange Callback function that stores the updated list of approved items\n * @param unapprovedItems Array of unapproved items, typically as defined in `Settings.xml`\n * @param onUnapprovedItemsChange Callback function that stores the updated list of unapproved items\n * @returns Column that shows the status buttons for the related inventory item. The button for the\n * current status of the item is selected\n */\nexport const inventoryStatusColumn = (\n statusLabel: string,\n approvedItems: string[],\n onApprovedItemsChange: (items: string[]) => void,\n unapprovedItems: string[],\n onUnapprovedItemsChange: (items: string[]) => void,\n): ColumnDef => {\n return {\n accessorKey: 'status',\n header: ({ column }) => {\n return (\n
\n \n
\n );\n },\n cell: ({ row }) => {\n const status: Status = row.getValue('status');\n const item: string = row.getValue('item');\n return (\n \n \n statusChangeHandler(\n [item],\n 'approved',\n approvedItems,\n onApprovedItemsChange,\n unapprovedItems,\n onUnapprovedItemsChange,\n )\n }\n value=\"approved\"\n >\n \n \n \n statusChangeHandler(\n [item],\n 'unapproved',\n approvedItems,\n onApprovedItemsChange,\n unapprovedItems,\n onUnapprovedItemsChange,\n )\n }\n value=\"unapproved\"\n >\n \n \n \n statusChangeHandler(\n [item],\n 'unknown',\n approvedItems,\n onApprovedItemsChange,\n unapprovedItems,\n onUnapprovedItemsChange,\n )\n }\n value=\"unknown\"\n >\n \n \n \n );\n },\n };\n};\n","import DataTable, {\n ColumnDef,\n RowContents,\n RowSelectionState,\n TableContents,\n} from '@/components/advanced/data-table/data-table.component';\nimport OccurrencesTable from '@/components/advanced/inventory/occurrences-table.component';\nimport Checkbox from '@/components/shadcn-ui/checkbox';\nimport { Input } from '@/components/shadcn-ui/input';\nimport { Label } from '@/components/shadcn-ui/label';\nimport {\n Select,\n SelectContent,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\nimport {\n deepEqual,\n LocalizedStringValue,\n ScriptureReference,\n substring,\n} from 'platform-bible-utils';\nimport { useEffect, useMemo, useState } from 'react';\nimport {\n getBookNumFromId,\n getLinesFromUSFM,\n getNumberFromUSFM,\n getStatusForItem,\n InventoryItemOccurrence,\n InventoryTableData,\n Status,\n} from './inventory-utils';\nimport { inventoryAdditionalItemColumn } from './inventory-columns';\n\n/**\n * Object containing all keys used for localization in this component. If you're using this\n * component in an extension, you can pass it into the useLocalizedStrings hook to easily obtain the\n * localized strings and pass them into the localizedStrings prop of this component\n */\nexport const INVENTORY_STRING_KEYS = Object.freeze([\n '%webView_inventory_all%',\n '%webView_inventory_approved%',\n '%webView_inventory_unapproved%',\n '%webView_inventory_unknown%',\n '%webView_inventory_scope_currentBook%',\n '%webView_inventory_scope_chapter%',\n '%webView_inventory_scope_verse%',\n '%webView_inventory_filter_text%',\n '%webView_inventory_show_additional_items%',\n '%webView_inventory_occurrences_table_header_reference%',\n '%webView_inventory_occurrences_table_header_occurrence%',\n] as const);\n\nexport type InventoryLocalizedStrings = {\n [localizedInventoryKey in (typeof INVENTORY_STRING_KEYS)[number]]?: LocalizedStringValue;\n};\n\n/** Scope of scripture that the inventory can operate on */\nexport type Scope = 'book' | 'chapter' | 'verse';\n\n/** Status values that the status filter can select from */\ntype StatusFilter = Status | 'all';\n\n/** Text labels for the inventory columns and the control components of additional inventory items */\ntype AdditionalItemsLabels = {\n checkboxText?: string;\n tableHeaders?: string[];\n};\n\n/**\n * Filters data that is shown in the DataTable section of the Inventory\n *\n * @param itemData All inventory items and their related information\n * @param statusFilter Allows filtering by status (i.e. show all items, or only items that are\n * 'approved', 'unapproved' or 'unknown')\n * @param textFilter Allows filtering by text. All items that include the filter text will be\n * selected.\n * @returns Array of items and their related information that are matched by the specified filters\n */\nconst filterItemData = (\n itemData: InventoryTableData[],\n statusFilter: StatusFilter,\n textFilter: string,\n): InventoryTableData[] => {\n let filteredItemData: InventoryTableData[] = itemData;\n\n if (statusFilter !== 'all') {\n filteredItemData = filteredItemData.filter(\n (item) =>\n (statusFilter === 'approved' && item.status === 'approved') ||\n (statusFilter === 'unapproved' && item.status === 'unapproved') ||\n (statusFilter === 'unknown' && item.status === 'unknown'),\n );\n }\n\n if (textFilter !== '')\n filteredItemData = filteredItemData.filter((item) => item.items[0].includes(textFilter));\n\n return filteredItemData;\n};\n\n/**\n * Turns array of strings into array of inventory items, along with their count and status\n *\n * @param text The source scripture text that is searched for inventory items\n * @param scriptureRef The scripture reference that the application is currently set to\n * @param approvedItems Array of approved items, typically as defined in `Settings.xml`\n * @param unapprovedItems Array of unapproved items, typically as defined in `Settings.xml`\n * @param itemRegex Regular expression that describes what items this Inventory should extract from\n * the provided scripture text\n * @returns Array of inventory items, along with their count and status\n */\nconst createTableData = (\n text: string | undefined,\n scriptureRef: ScriptureReference,\n approvedItems: string[],\n unapprovedItems: string[],\n itemRegex: RegExp,\n): InventoryTableData[] => {\n if (!text) return [];\n\n const tableData: InventoryTableData[] = [];\n\n let currentBook: number | undefined = scriptureRef.bookNum;\n let currentChapter: number | undefined = scriptureRef.chapterNum;\n let currentVerse: number | undefined = scriptureRef.verseNum;\n\n const lines = getLinesFromUSFM(text);\n\n lines.forEach((line: string) => {\n if (line.startsWith('\\\\id')) {\n currentBook = getBookNumFromId(line);\n currentChapter = 0;\n currentVerse = 0;\n }\n if (line.startsWith('\\\\c')) {\n currentChapter = getNumberFromUSFM(line);\n currentVerse = 0;\n }\n if (line.startsWith('\\\\v')) {\n currentVerse = getNumberFromUSFM(line);\n if (currentChapter === 0) {\n currentChapter = scriptureRef.chapterNum;\n }\n }\n\n let match: RegExpExecArray | undefined = itemRegex.exec(line) ?? undefined;\n while (match) {\n const items: string[] = [];\n match.forEach((item) => items.push(item));\n const itemIndex = match.index;\n const existingItem = tableData.find((tableEntry) => deepEqual(tableEntry.items, items));\n const newReference: InventoryItemOccurrence = {\n reference: {\n bookNum: currentBook !== undefined ? currentBook : -1,\n chapterNum: currentChapter !== undefined ? currentChapter : -1,\n verseNum: currentVerse !== undefined ? currentVerse : -1,\n },\n text: substring(line, Math.max(0, itemIndex - 25), Math.min(itemIndex + 25, line.length)),\n };\n if (existingItem) {\n existingItem.count += 1;\n existingItem.occurrences.push(newReference);\n } else {\n const newItem: InventoryTableData = {\n items,\n count: 1,\n status: getStatusForItem(items[0], approvedItems, unapprovedItems),\n occurrences: [newReference],\n };\n tableData.push(newItem);\n }\n\n match = itemRegex.exec(line) ?? undefined;\n }\n });\n\n return tableData;\n};\n\n/**\n * Gets the localized value for the provided key\n *\n * @param strings Object containing localized string\n * @param key Key for a localized string\n * @returns The localized value for the provided key, if available. Returns the key if no localized\n * value is available\n */\nconst localizeString = (\n strings: InventoryLocalizedStrings,\n key: keyof InventoryLocalizedStrings,\n) => {\n return strings[key] ?? key;\n};\n\n/** Props for the Inventory component */\ntype InventoryProps = {\n /** The scripture reference that the application is currently set to */\n scriptureReference: ScriptureReference;\n /** Callback function that is executed when the scripture reference is changed */\n setScriptureReference: (scriptureReference: ScriptureReference) => void;\n /**\n * Object with all localized strings that the Inventory needs to work well across multiple\n * languages. When using this component with Platform.Bible, you can import\n * `INVENTORY_STRING_KEYS` from this library, pass it in to the Platform's localization hook, and\n * pass the localized keys that are returned by the hook into this prop.\n */\n localizedStrings: InventoryLocalizedStrings;\n /**\n * The logic that finds the desired items in the source text. This can either be a Regular\n * expression that captures one or multiple items (preferred), or a custom function that builds\n * and return an InventoryDataTable[] manually. Note: In case the logic captures more than one\n * item (i.e. InventoryTableData.items has a length greater than 1), you must provide text labels\n * for the related columns and control elements to show by setting the `additionalItemsLabels`\n * prop\n */\n extractItems:\n | RegExp\n | ((\n text: string | undefined,\n scriptureRef: ScriptureReference,\n approvedItems: string[],\n unapprovedItems: string[],\n ) => InventoryTableData[]);\n /**\n * Text labels for control elements and additional column headers in case your Inventory has more\n * than one item to show (e.g. The 'Preceding Marker' in the Markers Inventory)\n */\n additionalItemsLabels?: AdditionalItemsLabels;\n /** Array of approved items, typically as defined in `Settings.xml` */\n approvedItems: string[];\n /** Array of unapproved items, typically as defined in `Settings.xml` */\n unapprovedItems: string[];\n /** The source scripture text that is searched for in inventory items */\n text: string | undefined;\n /** Scope of scripture that the inventory will operate on */\n scope: Scope;\n /** Callback function that is executed when the scope is changed from the Inventory */\n onScopeChange: (scope: Scope) => void;\n /**\n * Column definitions for the Inventory data table. The most commonly used column definitions are\n * pre-configured for your convenience and can be imported (e.g. inventoryItemColumn,\n * inventoryAdditionalItemColumn inventoryCountColumn, and inventoryStatusColumn). If you need any\n * other columns you can add these yourself\n */\n columns: ColumnDef[];\n};\n\n/** Inventory component that is used to view and control the status of provided project settings */\nexport default function Inventory({\n scriptureReference,\n setScriptureReference,\n localizedStrings,\n extractItems,\n additionalItemsLabels,\n approvedItems,\n unapprovedItems,\n text,\n scope,\n onScopeChange,\n columns,\n}: InventoryProps) {\n const allItemsText = localizeString(localizedStrings, '%webView_inventory_all%');\n const approvedItemsText = localizeString(localizedStrings, '%webView_inventory_approved%');\n const unapprovedItemsText = localizeString(localizedStrings, '%webView_inventory_unapproved%');\n const unknownItemsText = localizeString(localizedStrings, '%webView_inventory_unknown%');\n const scopeBookText = localizeString(localizedStrings, '%webView_inventory_scope_currentBook%');\n const scopeChapterText = localizeString(localizedStrings, '%webView_inventory_scope_chapter%');\n const scopeVerseText = localizeString(localizedStrings, '%webView_inventory_scope_verse%');\n const filterText = localizeString(localizedStrings, '%webView_inventory_filter_text%');\n const showAdditionalItemsText = localizeString(\n localizedStrings,\n '%webView_inventory_show_additional_items%',\n );\n\n const [showAdditionalItems, setShowAdditionalItems] = useState(false);\n const [statusFilter, setStatusFilter] = useState('all');\n const [textFilter, setTextFilter] = useState('');\n const [selectedItem, setSelectedItem] = useState([]);\n\n const tableData: InventoryTableData[] = useMemo(() => {\n if (!text) return [];\n if (extractItems instanceof RegExp)\n return createTableData(\n text,\n scriptureReference,\n approvedItems,\n unapprovedItems,\n extractItems,\n );\n return extractItems(text, scriptureReference, approvedItems, unapprovedItems);\n }, [text, extractItems, scriptureReference, approvedItems, unapprovedItems]);\n\n const reducedTableData: InventoryTableData[] = useMemo(() => {\n if (showAdditionalItems) return tableData;\n\n const newTableData: InventoryTableData[] = [];\n\n tableData.forEach((tableEntry) => {\n const firstItem = tableEntry.items[0];\n\n const existingEntry = newTableData.find(\n (newTableEntry) => newTableEntry.items[0] === firstItem,\n );\n\n if (existingEntry) {\n existingEntry.count += tableEntry.count;\n existingEntry.occurrences = existingEntry.occurrences.concat(tableEntry.occurrences);\n } else {\n newTableData.push({\n items: [firstItem],\n count: tableEntry.count,\n occurrences: tableEntry.occurrences,\n status: tableEntry.status,\n });\n }\n });\n\n return newTableData;\n }, [showAdditionalItems, tableData]);\n\n const filteredTableData: InventoryTableData[] = useMemo(() => {\n return filterItemData(reducedTableData, statusFilter, textFilter);\n }, [reducedTableData, statusFilter, textFilter]);\n\n const allColumns: ColumnDef[] = useMemo(() => {\n if (!showAdditionalItems) return columns;\n\n const numberOfAdditionalItems = additionalItemsLabels?.tableHeaders?.length;\n if (!numberOfAdditionalItems) return columns;\n\n const additionalColumns: ColumnDef[] = [];\n\n for (let index = 0; index < numberOfAdditionalItems; index++) {\n additionalColumns.push(\n inventoryAdditionalItemColumn(\n additionalItemsLabels?.tableHeaders?.[index] || 'Additional Item',\n index + 1,\n ),\n );\n }\n\n return [...additionalColumns, ...columns];\n }, [additionalItemsLabels?.tableHeaders, columns, showAdditionalItems]);\n\n useEffect(() => {\n setSelectedItem([]);\n }, [filteredTableData]);\n\n const rowClickHandler = (\n row: RowContents,\n table: TableContents,\n ) => {\n table.setRowSelection(() => {\n const newSelection: RowSelectionState = {};\n newSelection[row.index] = true;\n return newSelection;\n });\n\n setSelectedItem(row.original.items);\n };\n\n const handleScopeChange = (value: string) => {\n if (value === 'book' || value === 'chapter' || value === 'verse') {\n onScopeChange(value);\n } else {\n throw new Error(`Invalid scope value: ${value}`);\n }\n };\n\n const handleStatusFilterChange = (value: string) => {\n if (value === 'all' || value === 'approved' || value === 'unapproved' || value === 'unknown') {\n setStatusFilter(value);\n } else {\n throw new Error(`Invalid status filter value: ${value}`);\n }\n };\n\n const occurrenceData: InventoryItemOccurrence[] = useMemo(() => {\n if (reducedTableData.length === 0 || selectedItem.length === 0) return [];\n const occurrence = reducedTableData.filter((tableEntry: InventoryTableData) => {\n return deepEqual(\n showAdditionalItems ? tableEntry.items : [tableEntry.items[0]],\n selectedItem,\n );\n });\n if (occurrence.length > 1) throw new Error('Selected item is not unique');\n return occurrence[0].occurrences;\n }, [selectedItem, showAdditionalItems, reducedTableData]);\n\n return (\n
\n
\n handleStatusFilterChange(value)}\n defaultValue={statusFilter}\n >\n \n \n \n \n {allItemsText}\n {approvedItemsText}\n {unapprovedItemsText}\n {unknownItemsText}\n \n \n \n {\n setTextFilter(event.target.value);\n }}\n />\n {additionalItemsLabels && (\n
\n {\n setSelectedItem([]);\n setShowAdditionalItems(checked);\n }}\n />\n \n
\n )}\n
\n
\n \n
\n {occurrenceData.length > 0 && (\n
\n \n
\n )}\n
\n );\n}\n","import { Input } from '@/components/shadcn-ui/input';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { useState } from 'react';\n\nexport type SearchBarProps = {\n /**\n * Callback fired to handle the search query when button pressed\n *\n * @param searchQuery\n */\n onSearch: (searchQuery: string) => void;\n\n /** Optional string that appears in the search bar without a search string */\n placeholder?: string;\n\n /** Optional boolean to set the input base to full width */\n isFullWidth?: boolean;\n};\n\nexport default function SearchBar({ onSearch, placeholder, isFullWidth }: SearchBarProps) {\n const [searchQuery, setSearchQuery] = useState('');\n\n const handleInputChange = (searchString: string) => {\n setSearchQuery(searchString);\n onSearch(searchString);\n };\n\n return (\n handleInputChange(e.target.value)}\n />\n );\n}\n","// adapted from: https://github.com/shadcn-ui/ui/discussions/752\n\n'use client';\n\nimport { TabsContentProps, TabsListProps, TabsTriggerProps } from '@/components/shadcn-ui/tabs';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport * as TabsPrimitive from '@radix-ui/react-tabs';\nimport React from 'react';\n\nexport type VerticalTabsProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport type LeftTabsTriggerProps = TabsTriggerProps & {\n value: string;\n ref?: React.Ref;\n};\n\nexport const VerticalTabs = React.forwardRef<\n React.ElementRef,\n VerticalTabsProps\n>(({ className, ...props }, ref) => (\n \n));\n\nVerticalTabs.displayName = TabsPrimitive.List.displayName;\n\nexport const VerticalTabsList = React.forwardRef<\n React.ElementRef,\n TabsListProps\n>(({ className, ...props }, ref) => (\n \n));\nVerticalTabsList.displayName = TabsPrimitive.List.displayName;\n\nexport const VerticalTabsTrigger = React.forwardRef<\n React.ElementRef,\n LeftTabsTriggerProps\n>(({ className, ...props }, ref) => (\n \n));\n\nexport const VerticalTabsContent = React.forwardRef<\n React.ElementRef,\n TabsContentProps\n>(({ className, ...props }, ref) => (\n \n));\nVerticalTabsContent.displayName = TabsPrimitive.Content.displayName;\n","import SearchBar from '@/components/basics/search-bar.component';\nimport {\n VerticalTabs,\n VerticalTabsContent,\n VerticalTabsList,\n VerticalTabsTrigger,\n} from '@/components/basics/tabs-vertical';\nimport { ReactNode } from 'react';\n\nexport type TabKeyValueContent = {\n key: string;\n value: string;\n content: ReactNode;\n};\n\nexport type TabNavigationContentSearchProps = {\n /** List of values and keys for each tab this component should provide */\n tabList: TabKeyValueContent[];\n\n /** Handler to run when the value of the search bar changes */\n onSearch: (searchQuery: string) => void;\n\n /** Optional placeholder for the search bar */\n searchPlaceholder?: string;\n\n /** Optional title to include in the header */\n headerTitle?: string;\n\n /** Optional flag to make the search bar appear full width */\n isSearchBarFullWidth?: boolean;\n\n /** Text direction ltr or rtl */\n direction?: 'ltr' | 'rtl';\n};\n\nexport default function TabNavigationContentSearch({\n tabList,\n onSearch,\n searchPlaceholder,\n headerTitle,\n isSearchBarFullWidth = false,\n direction = 'ltr',\n}: TabNavigationContentSearchProps) {\n return (\n
\n
\n {headerTitle ?

{headerTitle}

: ''}\n \n
\n \n \n {tabList.map((tab) => (\n \n {tab.value}\n \n ))}\n \n {tabList.map((tab) => (\n \n {tab.content}\n \n ))}\n \n
\n );\n}\n","import React from 'react';\nimport * as SeparatorPrimitive from '@radix-ui/react-separator';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Separator = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, orientation = 'horizontal', decorative = true, ...props }, ref) => (\n \n));\nSeparator.displayName = SeparatorPrimitive.Root.displayName;\n\nexport { Separator };\n","'use client';\n\nimport * as React from 'react';\nimport * as SheetPrimitive from '@radix-ui/react-dialog';\nimport { cva, type VariantProps } from 'class-variance-authority';\nimport { X } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Sheet = SheetPrimitive.Root;\n\nconst SheetTrigger = SheetPrimitive.Trigger;\n\nconst SheetClose = SheetPrimitive.Close;\n\nconst SheetPortal = SheetPrimitive.Portal;\n\nconst SheetOverlay = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSheetOverlay.displayName = SheetPrimitive.Overlay.displayName;\n\nconst sheetVariants = cva(\n 'pr-twp tw-fixed tw-z-50 tw-gap-4 tw-bg-background tw-p-6 tw-shadow-lg tw-transition tw-ease-in-out data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-duration-300 data-[state=open]:tw-duration-500',\n {\n variants: {\n side: {\n top: 'tw-inset-x-0 tw-top-0 tw-border-b data-[state=closed]:tw-slide-out-to-top data-[state=open]:tw-slide-in-from-top',\n bottom:\n 'tw-inset-x-0 tw-bottom-0 tw-border-t data-[state=closed]:tw-slide-out-to-bottom data-[state=open]:tw-slide-in-from-bottom',\n left: 'tw-inset-y-0 tw-left-0 tw-h-full tw-w-3/4 tw-border-r data-[state=closed]:tw-slide-out-to-left data-[state=open]:tw-slide-in-from-left sm:tw-max-w-sm',\n right:\n 'tw-inset-y-0 tw-right-0 tw-h-full tw-w-3/4 tw- tw-border-l data-[state=closed]:tw-slide-out-to-right data-[state=open]:tw-slide-in-from-right sm:tw-max-w-sm',\n },\n },\n defaultVariants: {\n side: 'right',\n },\n },\n);\n\ninterface SheetContentProps\n extends React.ComponentPropsWithoutRef,\n VariantProps {}\n\nconst SheetContent = React.forwardRef<\n React.ElementRef,\n SheetContentProps\n>(({ side = 'right', className, children, ...props }, ref) => (\n \n \n \n {children}\n \n \n Close\n \n \n \n));\nSheetContent.displayName = SheetPrimitive.Content.displayName;\n\nfunction SheetHeader({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nSheetHeader.displayName = 'SheetHeader';\n\nfunction SheetFooter({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nSheetFooter.displayName = 'SheetFooter';\n\nconst SheetTitle = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSheetTitle.displayName = SheetPrimitive.Title.displayName;\n\nconst SheetDescription = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSheetDescription.displayName = SheetPrimitive.Description.displayName;\n\nexport {\n Sheet,\n SheetPortal,\n SheetOverlay,\n SheetTrigger,\n SheetClose,\n SheetContent,\n SheetHeader,\n SheetFooter,\n SheetTitle,\n SheetDescription,\n};\n","import React from 'react';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nfunction Skeleton({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\n\nexport { Skeleton };\n","import React from 'react';\nimport * as TooltipPrimitive from '@radix-ui/react-tooltip';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst TooltipProvider = TooltipPrimitive.Provider;\n\nconst Tooltip = TooltipPrimitive.Root;\n\nconst TooltipTrigger = TooltipPrimitive.Trigger;\n\nconst TooltipContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, sideOffset = 4, ...props }, ref) => (\n \n));\nTooltipContent.displayName = TooltipPrimitive.Content.displayName;\n\nexport { Tooltip, TooltipTrigger, TooltipContent, TooltipProvider };\n","import * as React from 'react';\n\nconst MOBILE_BREAKPOINT = 768;\n\nexport default function useIsMobile() {\n const [isMobile, setIsMobile] = React.useState(undefined);\n\n React.useEffect(() => {\n const mql = window.matchMedia(`(max-width: ${MOBILE_BREAKPOINT - 1}px)`);\n const onChange = () => {\n setIsMobile(window.innerWidth < MOBILE_BREAKPOINT);\n };\n mql.addEventListener('change', onChange);\n setIsMobile(window.innerWidth < MOBILE_BREAKPOINT);\n return () => mql.removeEventListener('change', onChange);\n }, []);\n\n return !!isMobile;\n}\n","import React from 'react';\nimport { Slot } from '@radix-ui/react-slot';\nimport { VariantProps, cva } from 'class-variance-authority';\nimport { PanelLeft } from 'lucide-react';\n\nimport { Button } from '@/components/shadcn-ui/button';\nimport { Input } from '@/components/shadcn-ui/input';\nimport { Separator } from '@/components/shadcn-ui/separator';\nimport { Sheet, SheetContent } from '@/components/shadcn-ui/sheet';\nimport { Skeleton } from '@/components/shadcn-ui/skeleton';\nimport {\n Tooltip,\n TooltipContent,\n TooltipProvider,\n TooltipTrigger,\n} from '@/components/shadcn-ui/tooltip';\nimport useIsMobile from '@/components/hooks/use-mobile';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst SIDEBAR_COOKIE_NAME = 'sidebar:state';\nconst SIDEBAR_COOKIE_MAX_AGE = 60 * 60 * 24 * 7;\nconst SIDEBAR_WIDTH = '16rem';\nconst SIDEBAR_WIDTH_MOBILE = '18rem';\nconst SIDEBAR_WIDTH_ICON = '3rem';\nconst SIDEBAR_KEYBOARD_SHORTCUT = 'b';\n\ntype SidebarContextProps = {\n state: 'expanded' | 'collapsed';\n open: boolean;\n setOpen: (open: boolean) => void;\n openMobile: boolean;\n setOpenMobile: (open: boolean) => void;\n isMobile: boolean;\n toggleSidebar: () => void;\n};\n\nconst SidebarContext = React.createContext(undefined);\n\nfunction useSidebar() {\n const context = React.useContext(SidebarContext);\n if (!context) {\n throw new Error('useSidebar must be used within a SidebarProvider.');\n }\n\n return context;\n}\n\nconst SidebarProvider = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & {\n defaultOpen?: boolean;\n open?: boolean;\n onOpenChange?: (open: boolean) => void;\n }\n>(\n (\n {\n defaultOpen = true,\n open: openProp,\n onOpenChange: setOpenProp,\n className,\n style,\n children,\n ...props\n },\n ref,\n ) => {\n const isMobile = useIsMobile();\n const [openMobile, setOpenMobile] = React.useState(false);\n\n // This is the internal state of the sidebar.\n // We use openProp and setOpenProp for control from outside the component.\n const [_open, _setOpen] = React.useState(defaultOpen);\n const isOpen = openProp ?? _open;\n const setOpen = React.useCallback(\n (value: boolean | ((value: boolean) => boolean)) => {\n const openState = typeof value === 'function' ? value(isOpen) : value;\n if (setOpenProp) {\n setOpenProp(openState);\n } else {\n _setOpen(openState);\n }\n\n // This sets the cookie to keep the sidebar state.\n document.cookie = `${SIDEBAR_COOKIE_NAME}=${openState}; path=/; max-age=${SIDEBAR_COOKIE_MAX_AGE}`;\n },\n [setOpenProp, isOpen],\n );\n\n // Helper to toggle the sidebar.\n const toggleSidebar = React.useCallback(() => {\n return isMobile ? setOpenMobile((open) => !open) : setOpen((open) => !open);\n }, [isMobile, setOpen, setOpenMobile]);\n\n // Adds a keyboard shortcut to toggle the sidebar.\n React.useEffect(() => {\n const handleKeyDown = (event: KeyboardEvent) => {\n if (event.key === SIDEBAR_KEYBOARD_SHORTCUT && (event.metaKey || event.ctrlKey)) {\n event.preventDefault();\n toggleSidebar();\n }\n };\n\n window.addEventListener('keydown', handleKeyDown);\n return () => window.removeEventListener('keydown', handleKeyDown);\n }, [toggleSidebar]);\n\n // We add a state so that we can do data-state=\"expanded\" or \"collapsed\".\n // This makes it easier to style the sidebar with Tailwind classes.\n const state = isOpen ? 'expanded' : 'collapsed';\n\n const contextValue = React.useMemo(\n () => ({\n state,\n open: isOpen,\n setOpen,\n isMobile,\n openMobile,\n setOpenMobile,\n toggleSidebar,\n }),\n [state, isOpen, setOpen, isMobile, openMobile, setOpenMobile, toggleSidebar],\n );\n\n return (\n \n \n \n {children}\n
\n \n \n );\n },\n);\nSidebarProvider.displayName = 'SidebarProvider';\n\nconst Sidebar = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & {\n side?: 'left' | 'right';\n variant?: 'sidebar' | 'floating' | 'inset';\n collapsible?: 'offcanvas' | 'icon' | 'none';\n }\n>(\n (\n {\n side = 'left',\n variant = 'sidebar',\n collapsible = 'offcanvas',\n className,\n children,\n ...props\n },\n ref,\n ) => {\n const { isMobile, state, openMobile, setOpenMobile } = useSidebar();\n\n if (collapsible === 'none') {\n return (\n \n {children}\n
\n );\n }\n\n if (isMobile) {\n return (\n \n button]:tw-hidden\"\n style={\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n {\n '--sidebar-width': SIDEBAR_WIDTH_MOBILE,\n } as React.CSSProperties\n }\n side={side}\n >\n
{children}
\n \n
\n );\n }\n\n return (\n \n {/* This is what handles the sidebar gap on desktop */}\n \n \n \n {children}\n
\n
\n
\n );\n },\n);\nSidebar.displayName = 'Sidebar';\n\nconst SidebarTrigger = React.forwardRef<\n React.ElementRef,\n React.ComponentProps\n>(({ className, onClick, ...props }, ref) => {\n const { toggleSidebar } = useSidebar();\n\n return (\n {\n onClick?.(event);\n toggleSidebar();\n }}\n {...props}\n >\n \n Toggle Sidebar\n \n );\n});\nSidebarTrigger.displayName = 'SidebarTrigger';\n\nconst SidebarRail = React.forwardRef>(\n ({ className, ...props }, ref) => {\n const { toggleSidebar } = useSidebar();\n\n return (\n \n );\n },\n);\nSidebarRail.displayName = 'SidebarRail';\n\nconst SidebarInset = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarInset.displayName = 'SidebarInset';\n\nconst SidebarInput = React.forwardRef<\n React.ElementRef,\n React.ComponentProps\n>(({ className, ...props }, ref) => {\n return (\n \n );\n});\nSidebarInput.displayName = 'SidebarInput';\n\nconst SidebarHeader = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarHeader.displayName = 'SidebarHeader';\n\nconst SidebarFooter = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarFooter.displayName = 'SidebarFooter';\n\nconst SidebarSeparator = React.forwardRef<\n React.ElementRef,\n React.ComponentProps\n>(({ className, ...props }, ref) => {\n return (\n \n );\n});\nSidebarSeparator.displayName = 'SidebarSeparator';\n\nconst SidebarContent = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarContent.displayName = 'SidebarContent';\n\nconst SidebarGroup = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarGroup.displayName = 'SidebarGroup';\n\nconst SidebarGroupLabel = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & { asChild?: boolean }\n>(({ className, asChild = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'div';\n\n return (\n svg]:tw-size-4 [&>svg]:tw-shrink-0',\n 'group-data-[collapsible=icon]:tw--mt-8 group-data-[collapsible=icon]:tw-opacity-0',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarGroupLabel.displayName = 'SidebarGroupLabel';\n\nconst SidebarGroupAction = React.forwardRef<\n HTMLButtonElement,\n React.ComponentProps<'button'> & { asChild?: boolean }\n>(({ className, asChild = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'button';\n\n return (\n svg]:tw-size-4 [&>svg]:tw-shrink-0',\n // Increases the hit area of the button on mobile.\n 'after:tw-absolute after:tw--inset-2 after:md:tw-hidden',\n 'group-data-[collapsible=icon]:tw-hidden',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarGroupAction.displayName = 'SidebarGroupAction';\n\nconst SidebarGroupContent = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarGroupContent.displayName = 'SidebarGroupContent';\n\nconst SidebarMenu = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenu.displayName = 'SidebarMenu';\n\nconst SidebarMenuItem = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenuItem.displayName = 'SidebarMenuItem';\n\nconst sidebarMenuButtonVariants = cva(\n 'tw-peer/menu-button tw-flex tw-w-full tw-items-center tw-gap-2 tw-overflow-hidden tw-rounded-md tw-p-2 tw-text-left tw-text-sm tw-outline-none tw-ring-sidebar-ring tw-transition-[width,height,padding] hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground focus-visible:tw-ring-2 active:tw-bg-sidebar-accent active:tw-text-sidebar-accent-foreground disabled:tw-pointer-events-none disabled:tw-opacity-50 tw-group-has-[[data-sidebar=menu-action]]/menu-item:pr-8 aria-disabled:tw-pointer-events-none aria-disabled:tw-opacity-50 data-[active=true]:tw-bg-sidebar-accent data-[active=true]:tw-font-medium data-[active=true]:tw-text-sidebar-accent-foreground data-[state=open]:hover:tw-bg-sidebar-accent data-[state=open]:hover:tw-text-sidebar-accent-foreground group-data-[collapsible=icon]:tw-!size-8 group-data-[collapsible=icon]:tw-!p-2 [&>span:last-child]:tw-truncate [&>svg]:tw-size-4 [&>svg]:tw-shrink-0',\n {\n variants: {\n variant: {\n default: 'hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground',\n outline:\n 'tw-bg-background tw-shadow-[0_0_0_1px_hsl(var(--sidebar-border))] hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground hover:tw-shadow-[0_0_0_1px_hsl(var(--sidebar-accent))]',\n },\n size: {\n default: 'tw-h-8 tw-text-sm',\n sm: 'tw-h-7 tw-text-xs',\n lg: 'tw-h-12 tw-text-sm group-data-[collapsible=icon]:tw-!p-0',\n },\n },\n defaultVariants: {\n variant: 'default',\n size: 'default',\n },\n },\n);\n\nconst SidebarMenuButton = React.forwardRef<\n HTMLButtonElement,\n React.ComponentProps<'button'> & {\n asChild?: boolean;\n isActive?: boolean;\n tooltip?: string | React.ComponentProps;\n } & VariantProps\n>(\n (\n {\n asChild = false,\n isActive = false,\n variant = 'default',\n size = 'default',\n tooltip,\n className,\n ...props\n },\n ref,\n ) => {\n const Comp = asChild ? Slot : 'button';\n const { isMobile, state } = useSidebar();\n\n const button = (\n \n );\n\n if (!tooltip) {\n return button;\n }\n\n if (typeof tooltip === 'string') {\n // eslint-disable-next-line no-param-reassign\n tooltip = {\n children: tooltip,\n };\n }\n\n return (\n \n {button}\n \n );\n },\n);\nSidebarMenuButton.displayName = 'SidebarMenuButton';\n\nconst SidebarMenuAction = React.forwardRef<\n HTMLButtonElement,\n React.ComponentProps<'button'> & {\n asChild?: boolean;\n showOnHover?: boolean;\n }\n>(({ className, asChild = false, showOnHover = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'button';\n\n return (\n svg]:tw-size-4 [&>svg]:tw-shrink-0',\n // Increases the hit area of the button on mobile.\n 'after:tw-absolute after:tw--inset-2 after:md:tw-hidden',\n 'tw-peer-data-[size=sm]/menu-button:top-1',\n 'tw-peer-data-[size=default]/menu-button:top-1.5',\n 'tw-peer-data-[size=lg]/menu-button:top-2.5',\n 'group-data-[collapsible=icon]:tw-hidden',\n showOnHover &&\n 'tw-group-focus-within/menu-item:opacity-100 tw-group-hover/menu-item:opacity-100 tw-peer-data-[active=true]/menu-button:text-sidebar-accent-foreground data-[state=open]:tw-opacity-100 md:tw-opacity-0',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarMenuAction.displayName = 'SidebarMenuAction';\n\nconst SidebarMenuBadge = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenuBadge.displayName = 'SidebarMenuBadge';\n\nconst SidebarMenuSkeleton = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & {\n showIcon?: boolean;\n }\n>(({ className, showIcon = false, ...props }, ref) => {\n // Random width between 50 to 90%.\n const width = React.useMemo(() => {\n return `${Math.floor(Math.random() * 40) + 50}%`;\n }, []);\n\n return (\n \n {showIcon && (\n \n )}\n \n
\n );\n});\nSidebarMenuSkeleton.displayName = 'SidebarMenuSkeleton';\n\nconst SidebarMenuSub = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenuSub.displayName = 'SidebarMenuSub';\n\nconst SidebarMenuSubItem = React.forwardRef>(\n ({ ...props }, ref) =>
  • ,\n);\nSidebarMenuSubItem.displayName = 'SidebarMenuSubItem';\n\nconst SidebarMenuSubButton = React.forwardRef<\n HTMLAnchorElement,\n React.ComponentProps<'a'> & {\n asChild?: boolean;\n size?: 'sm' | 'md';\n isActive?: boolean;\n }\n>(({ asChild = false, size = 'md', isActive, className, ...props }, ref) => {\n const Comp = asChild ? Slot : 'a';\n\n return (\n span:last-child]:tw-truncate [&>svg]:tw-size-4 [&>svg]:tw-shrink-0 [&>svg]:tw-text-sidebar-accent-foreground',\n 'data-[active=true]:tw-bg-sidebar-accent data-[active=true]:tw-text-sidebar-accent-foreground',\n size === 'sm' && 'tw-text-xs',\n size === 'md' && 'tw-text-sm',\n 'group-data-[collapsible=icon]:tw-hidden',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarMenuSubButton.displayName = 'SidebarMenuSubButton';\n\nexport {\n Sidebar,\n SidebarContent,\n SidebarFooter,\n SidebarGroup,\n SidebarGroupAction,\n SidebarGroupContent,\n SidebarGroupLabel,\n SidebarHeader,\n SidebarInput,\n SidebarInset,\n SidebarMenu,\n SidebarMenuAction,\n SidebarMenuBadge,\n SidebarMenuButton,\n SidebarMenuItem,\n SidebarMenuSkeleton,\n SidebarMenuSub,\n SidebarMenuSubButton,\n SidebarMenuSubItem,\n SidebarProvider,\n SidebarRail,\n SidebarSeparator,\n SidebarTrigger,\n useSidebar,\n};\n","import { useState } from 'react';\nimport {\n Sidebar,\n SidebarContent,\n SidebarGroup,\n SidebarGroupLabel,\n SidebarGroupContent,\n SidebarMenu,\n SidebarMenuItem,\n SidebarMenuButton,\n} from '../../shadcn-ui/sidebar';\n\nexport type SettingsSidebarProps = {\n /** Optional id */\n id?: string;\n\n /** Extension labels to list in sidebar */\n extensionLabels: string[];\n\n /** Project labels to list in sidebar */\n // projectLabels: string[];\n\n handleSelectSidebarItem: (key: string, isProjectSetting: boolean) => void;\n};\n\nexport default function SettingsSidebar({\n id,\n extensionLabels,\n // projectLabels,\n handleSelectSidebarItem,\n}: SettingsSidebarProps) {\n const [selectedItem, setSelectedItem] = useState();\n\n const handleSelectItem = (item: string, isProjectSetting: boolean) => {\n setSelectedItem(item);\n handleSelectSidebarItem(item, isProjectSetting);\n };\n\n return (\n \n \n \n Extensions\n \n \n {extensionLabels.map((label) => (\n \n handleSelectItem(label, false)}\n isActive={label === selectedItem}\n >\n {label}\n \n \n ))}\n \n \n \n\n {/* \n Projects\n \n \n {projectLabels.map((label) => (\n \n handleSelectItem(label)}\n isActive={label === selectedItem}\n >\n {label}\n \n \n ))}\n \n \n */}\n \n \n );\n}\n","import { SidebarInset, SidebarProvider } from '@/components/shadcn-ui/sidebar';\n// import { ProjectSettingProperties, SettingProperties } from 'platform-bible-utils';\nimport { PropsWithChildren } from 'react';\nimport SettingsSidebar from './settings-sidebar.component';\n\nexport type SettingsSidebarContentSearchProps = {\n /** Text direction ltr or rtl */\n direction?: 'ltr' | 'rtl';\n\n extensionLabels: string[];\n // projectLabels: string[];\n handleSelectSidebarItem: (key: string, isProjectSetting: boolean) => void;\n // renderSettingsProperties: (extension: string) => SettingProperties;\n // renderProjectSettingsProperties: (project: string) => ProjectSettingProperties;\n} & PropsWithChildren;\n\nexport default function SettingsSidebarContentSearch({\n direction = 'ltr',\n extensionLabels,\n // projectLabels,\n children,\n handleSelectSidebarItem,\n // renderSettingsProperties,\n // renderProjectSettingsProperties.\n}: SettingsSidebarContentSearchProps) {\n return (\n \n \n {children}\n \n );\n}\n","import { Button } from '@/components/shadcn-ui/button';\nimport {\n Select,\n SelectContent,\n SelectGroup,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\nimport {\n Table,\n TableBody,\n TableCell,\n TableHead,\n TableHeader,\n TableRow,\n} from '@/components/shadcn-ui/table';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Canon } from '@sillsdev/scripture';\nimport {\n Cell,\n ColumnDef,\n flexRender,\n getCoreRowModel,\n getExpandedRowModel,\n getGroupedRowModel,\n getSortedRowModel,\n GroupingState,\n Row,\n RowSelectionState,\n SortingState,\n useReactTable,\n} from '@tanstack/react-table';\nimport '@/components/advanced/scripture-results-viewer/scripture-results-viewer.component.css';\nimport {\n compareScrRefs,\n formatScrRef,\n ScriptureSelection,\n scrRefToBBBCCCVVV,\n} from 'platform-bible-utils';\nimport { MouseEvent, useEffect, useMemo, useState } from 'react';\nimport { ChevronDown, ChevronLeft, ChevronRight } from 'lucide-react';\n\n/**\n * Information (e.g., a checking error or some other type of \"transient\" annotation) about something\n * noteworthy at a specific place in an instance of the Scriptures.\n */\nexport type ScriptureItemDetail = ScriptureSelection & {\n /**\n * Text of the error, note, etc. In the future, we might want to support something more than just\n * text so that a JSX element could be provided with a link or some other controls related to the\n * issue being reported.\n */\n detail: string;\n};\n\n/**\n * A uniquely identifiable source of results that can be displayed in the ScriptureResultsViewer.\n * Generally, the source will be a particular Scripture check, but there may be other types of\n * sources.\n */\nexport type ResultsSource = {\n /**\n * Uniquely identifies the source.\n *\n * @type {string}\n */\n id: string;\n\n /**\n * Name (potentially localized) of the source, suitable for display in the UI.\n *\n * @type {string}\n */\n displayName: string;\n};\n\nexport type ScriptureSrcItemDetail = ScriptureItemDetail & {\n /** Source/type of detail. Can be used for grouping. */\n source: ResultsSource;\n};\n\n/**\n * Represents a set of results keyed by Scripture reference. Generally, the source will be a\n * particular Scripture check, but this type also allows for other types of uniquely identifiable\n * sources.\n */\nexport type ResultsSet = {\n /**\n * The backing source associated with this set of results.\n *\n * @type {ResultsSource}\n */\n source: ResultsSource;\n\n /**\n * Array of Scripture item details (messages keyed by Scripture reference).\n *\n * @type {ScriptureItemDetail[]}\n */\n data: ScriptureItemDetail[];\n};\n\nconst scrBookColId = 'scrBook';\nconst scrRefColId = 'scrRef';\nconst typeColId = 'source';\nconst detailsColId = 'details';\n\nconst defaultScrRefColumnName = 'Scripture Reference';\nconst defaultScrBookGroupName = 'Scripture Book';\nconst defaultTypeColumnName = 'Type';\nconst defaultDetailsColumnName = 'Details';\n\nexport type ScriptureResultsViewerColumnInfo = {\n /** Optional header to display for the Reference column. Default value: 'Scripture Reference'. */\n scriptureReferenceColumnName?: string;\n\n /** Optional text to display to refer to the Scripture book group. Default value: 'Scripture Book'. */\n scriptureBookGroupName?: string;\n\n /** Optional header to display for the Type column. Default value: 'Type'. */\n typeColumnName?: string;\n\n /** Optional header to display for the Details column. Default value: 'Details' */\n detailsColumnName?: string;\n};\n\nexport type ScriptureResultsViewerProps = ScriptureResultsViewerColumnInfo & {\n /** Groups of ScriptureItemDetail objects from particular sources (e.g., Scripture checks) */\n sources: ResultsSet[];\n\n /** Flag indicating whether to display column headers. Default is false. */\n showColumnHeaders?: boolean;\n\n /** Flag indicating whether to display source column. Default is false. */\n showSourceColumn?: boolean;\n\n /** Callback function to notify when a row is selected */\n onRowSelected?: (selectedRow: ScriptureSrcItemDetail | undefined) => void;\n\n /** Text direction ltr or rtl */\n direction?: 'ltr' | 'rtl';\n};\n\nfunction getColumns(\n colInfo?: ScriptureResultsViewerColumnInfo,\n showSourceColumn?: boolean,\n): ColumnDef[] {\n const showSrcCol = showSourceColumn ?? false;\n return [\n {\n accessorFn: (row) =>\n `${Canon.bookNumberToId(row.start.bookNum)} ${row.start.chapterNum}:${row.start.verseNum}`,\n id: scrBookColId,\n header: colInfo?.scriptureReferenceColumnName ?? defaultScrRefColumnName,\n cell: (info) => {\n const row = info.row.original;\n if (info.row.getIsGrouped()) {\n return Canon.bookNumberToEnglishName(row.start.bookNum);\n }\n return info.row.groupingColumnId === scrBookColId ? formatScrRef(row.start) : undefined;\n },\n getGroupingValue: (row) => row.start.bookNum,\n sortingFn: (a, b) => {\n return compareScrRefs(a.original.start, b.original.start);\n },\n enableGrouping: true,\n },\n {\n accessorFn: (row) => formatScrRef(row.start),\n id: scrRefColId,\n header: undefined,\n cell: (info) => {\n const row = info.row.original;\n return info.row.getIsGrouped() ? undefined : formatScrRef(row.start);\n },\n sortingFn: (a, b) => {\n return compareScrRefs(a.original.start, b.original.start);\n },\n enableGrouping: false,\n },\n {\n accessorFn: (row) => row.source.displayName,\n id: typeColId,\n header: showSrcCol ? (colInfo?.typeColumnName ?? defaultTypeColumnName) : undefined,\n cell: (info) => (showSrcCol || info.row.getIsGrouped() ? info.getValue() : undefined),\n getGroupingValue: (row) => row.source.id,\n sortingFn: (a, b) =>\n a.original.source.displayName.localeCompare(b.original.source.displayName),\n enableGrouping: true,\n },\n {\n accessorFn: (row) => row.detail,\n id: detailsColId,\n header: colInfo?.detailsColumnName ?? defaultDetailsColumnName,\n cell: (info) => info.getValue(),\n enableGrouping: false,\n },\n ];\n}\n\nconst toRefOrRange = (scriptureSelection: ScriptureSelection) => {\n if (!('offset' in scriptureSelection.start))\n throw new Error('No offset available in range start');\n if (scriptureSelection.end && !('offset' in scriptureSelection.end))\n throw new Error('No offset available in range end');\n const { offset: offsetStart } = scriptureSelection.start;\n let offsetEnd: number = 0;\n if (scriptureSelection.end) ({ offset: offsetEnd } = scriptureSelection.end);\n if (\n !scriptureSelection.end ||\n compareScrRefs(scriptureSelection.start, scriptureSelection.end) === 0\n )\n return `${scrRefToBBBCCCVVV(scriptureSelection.start)}+${offsetStart}`;\n return `${scrRefToBBBCCCVVV(scriptureSelection.start)}+${offsetStart}-${scrRefToBBBCCCVVV(scriptureSelection.end)}+${offsetEnd}`;\n};\n\nconst getRowKey = (row: ScriptureSrcItemDetail) =>\n `${toRefOrRange({ start: row.start, end: row.end })} ${row.source.displayName} ${row.detail}`;\n\n/**\n * Component to display a combined list of detailed items from one or more sources, where the items\n * are keyed primarily by Scripture reference. This is particularly useful for displaying a list of\n * results from Scripture checks, but more generally could be used to display any \"results\" from any\n * source(s). The component allows for grouping by Scripture book, source, or both. By default, it\n * displays somewhat \"tree-like\" which allows it to be more horizontally compact and intuitive. But\n * it also has the option of displaying as a traditional table with column headings (with or without\n * the source column showing).\n */\nexport default function ScriptureResultsViewer({\n sources,\n showColumnHeaders = false,\n showSourceColumn = false,\n scriptureReferenceColumnName,\n scriptureBookGroupName,\n typeColumnName,\n detailsColumnName,\n onRowSelected,\n direction = 'ltr',\n}: ScriptureResultsViewerProps) {\n const [grouping, setGrouping] = useState([]);\n const [sorting, setSorting] = useState([{ id: scrBookColId, desc: false }]);\n const [rowSelection, setRowSelection] = useState({});\n\n const scriptureResults = useMemo(\n () =>\n sources.flatMap((source) => {\n return source.data.map((item) => ({\n ...item,\n source: source.source,\n }));\n }),\n [sources],\n );\n\n const columns = useMemo(\n () =>\n getColumns(\n {\n scriptureReferenceColumnName,\n typeColumnName,\n detailsColumnName,\n },\n showSourceColumn,\n ),\n [scriptureReferenceColumnName, typeColumnName, detailsColumnName, showSourceColumn],\n );\n\n useEffect(() => {\n // Ensure sorting is applied correctly when grouped by type\n if (grouping.includes(typeColId)) {\n setSorting([\n { id: typeColId, desc: false },\n { id: scrBookColId, desc: false },\n ]);\n } else {\n setSorting([{ id: scrBookColId, desc: false }]);\n }\n }, [grouping]);\n\n const table = useReactTable({\n data: scriptureResults,\n columns,\n state: {\n grouping,\n sorting,\n rowSelection,\n },\n onGroupingChange: setGrouping,\n onSortingChange: setSorting,\n onRowSelectionChange: setRowSelection,\n getExpandedRowModel: getExpandedRowModel(),\n getGroupedRowModel: getGroupedRowModel(),\n getCoreRowModel: getCoreRowModel(),\n getSortedRowModel: getSortedRowModel(),\n getRowId: getRowKey,\n autoResetExpanded: false,\n enableMultiRowSelection: false,\n enableSubRowSelection: false,\n });\n\n useEffect(() => {\n if (onRowSelected) {\n const selectedRows = table.getSelectedRowModel().rowsById;\n const keys = Object.keys(selectedRows);\n if (keys.length === 1) {\n const selectedRow = scriptureResults.find((row) => getRowKey(row) === keys[0]) || undefined;\n if (selectedRow) onRowSelected(selectedRow);\n }\n }\n }, [rowSelection, scriptureResults, onRowSelected, table]);\n\n // Define possible grouping options\n const scrBookGroupName = scriptureBookGroupName ?? defaultScrBookGroupName;\n const typeGroupName = typeColumnName ?? defaultTypeColumnName;\n\n const groupingOptions = [\n { label: 'No Grouping', value: [] },\n { label: `Group by ${scrBookGroupName}`, value: [scrBookColId] },\n { label: `Group by ${typeGroupName}`, value: [typeColId] },\n {\n label: `Group by ${scrBookGroupName} and ${typeGroupName}`,\n value: [scrBookColId, typeColId],\n },\n {\n label: `Group by ${typeGroupName} and ${scrBookGroupName}`,\n value: [typeColId, scrBookColId],\n },\n ];\n\n const handleSelectChange = (selectedGrouping: string) => {\n setGrouping(JSON.parse(selectedGrouping));\n };\n\n const handleRowClick = (row: Row, event: MouseEvent) => {\n if (!row.getIsGrouped() && !row.getIsSelected()) {\n row.getToggleSelectedHandler()(event);\n }\n };\n\n const getEvenOrOddBandingStyle = (row: Row, index: number) => {\n if (row.getIsGrouped()) return '';\n // UX has now said they don't think they want banding. I'm leaving in the code to\n // set even and odd styles, but there's nothing in the CSS to style them differently.\n // The \"even\" style used to also have tw-bg-neutral-300 (along with even) to create\n // a visual banding effect. That could be added back in if UX changes the decision.\n return cn('banded-row', index % 2 === 0 ? 'even' : 'odd');\n };\n\n const getIndent = (\n groupingState: GroupingState,\n row: Row,\n cell: Cell,\n ) => {\n if (groupingState?.length === 0 || row.depth < cell.column.getGroupedIndex()) return undefined;\n if (row.getIsGrouped()) {\n switch (row.depth) {\n case 1:\n return 'tw-ps-4';\n default:\n return undefined;\n }\n }\n switch (row.depth) {\n case 1:\n return 'tw-ps-8';\n case 2:\n return 'tw-ps-12';\n default:\n return undefined;\n }\n };\n\n return (\n
    \n {!showColumnHeaders && (\n {\n handleSelectChange(value);\n }}\n >\n \n \n \n \n \n {groupingOptions.map((option) => (\n \n {option.label}\n \n ))}\n \n \n \n )}\n \n {showColumnHeaders && (\n \n {table.getHeaderGroups().map((headerGroup) => (\n \n {headerGroup.headers\n .filter((h) => h.column.columnDef.header)\n .map((header) => (\n /* For sticky column headers to work, we probably need to change the default definition of the shadcn Table component. See https://github.com/shadcn-ui/ui/issues/1151 */\n \n {header.isPlaceholder ? undefined : (\n
    \n {header.column.getCanGroup() ? (\n \n {header.column.getIsGrouped() ? `🛑` : `👊 `}\n \n ) : undefined}{' '}\n {flexRender(header.column.columnDef.header, header.getContext())}\n
    \n )}\n
    \n ))}\n
    \n ))}\n
    \n )}\n \n {table.getRowModel().rows.map((row, rowIndex) => {\n return (\n handleRowClick(row, event)}\n >\n {row.getVisibleCells().map((cell) => {\n if (\n cell.getIsPlaceholder() ||\n (cell.column.columnDef.enableGrouping &&\n !cell.getIsGrouped() &&\n (cell.column.columnDef.id !== typeColId || !showSourceColumn))\n )\n return undefined;\n return (\n \n {(() => {\n if (cell.getIsGrouped()) {\n return (\n \n {row.getIsExpanded() && }\n {!row.getIsExpanded() &&\n (direction === 'ltr' ? : )}{' '}\n {flexRender(cell.column.columnDef.cell, cell.getContext())} (\n {row.subRows.length})\n \n );\n }\n\n // if (cell.getIsAggregated()) {\n // flexRender(\n // cell.column.columnDef.aggregatedCell ?? cell.column.columnDef.cell,\n // cell.getContext(),\n // );\n // }\n\n return flexRender(cell.column.columnDef.cell, cell.getContext());\n })()}\n \n );\n })}\n \n );\n })}\n \n
    \n
    \n );\n}\n","import {\n getLocalizeKeyForScrollGroupId,\n LanguageStrings,\n ScrollGroupId,\n} from 'platform-bible-utils';\nimport {\n Select,\n SelectContent,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\n\nconst DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS = {\n [getLocalizeKeyForScrollGroupId('undefined')]: 'Ø',\n [getLocalizeKeyForScrollGroupId(0)]: 'A',\n [getLocalizeKeyForScrollGroupId(1)]: 'B',\n [getLocalizeKeyForScrollGroupId(2)]: 'C',\n [getLocalizeKeyForScrollGroupId(3)]: 'D',\n [getLocalizeKeyForScrollGroupId(4)]: 'E',\n [getLocalizeKeyForScrollGroupId(5)]: 'F',\n [getLocalizeKeyForScrollGroupId(6)]: 'G',\n [getLocalizeKeyForScrollGroupId(7)]: 'H',\n [getLocalizeKeyForScrollGroupId(8)]: 'I',\n [getLocalizeKeyForScrollGroupId(9)]: 'J',\n [getLocalizeKeyForScrollGroupId(10)]: 'K',\n [getLocalizeKeyForScrollGroupId(11)]: 'L',\n [getLocalizeKeyForScrollGroupId(12)]: 'M',\n [getLocalizeKeyForScrollGroupId(13)]: 'N',\n [getLocalizeKeyForScrollGroupId(14)]: 'O',\n [getLocalizeKeyForScrollGroupId(15)]: 'P',\n [getLocalizeKeyForScrollGroupId(16)]: 'Q',\n [getLocalizeKeyForScrollGroupId(17)]: 'R',\n [getLocalizeKeyForScrollGroupId(18)]: 'S',\n [getLocalizeKeyForScrollGroupId(19)]: 'T',\n [getLocalizeKeyForScrollGroupId(20)]: 'U',\n [getLocalizeKeyForScrollGroupId(21)]: 'V',\n [getLocalizeKeyForScrollGroupId(22)]: 'W',\n [getLocalizeKeyForScrollGroupId(23)]: 'X',\n [getLocalizeKeyForScrollGroupId(24)]: 'Y',\n [getLocalizeKeyForScrollGroupId(25)]: 'Z',\n};\n\nexport type ScrollGroupSelectorProps = {\n /**\n * List of scroll group ids to show to the user. Either a {@link ScrollGroupId} or `undefined` for\n * no scroll group\n */\n availableScrollGroupIds: (ScrollGroupId | undefined)[];\n /** Currently selected scroll group id. `undefined` for no scroll group */\n scrollGroupId: ScrollGroupId | undefined;\n /** Callback function run when the user tries to change the scroll group id */\n onChangeScrollGroupId: (newScrollGroupId: ScrollGroupId | undefined) => void;\n /**\n * Localized strings to use for displaying scroll group ids. Must be an object whose keys are\n * `getLocalizeKeyForScrollGroupId(scrollGroupId)` for all scroll group ids (and `undefined` if\n * included) in {@link ScrollGroupSelectorProps.availableScrollGroupIds} and whose values are the\n * localized strings to use for those scroll group ids.\n *\n * Defaults to English localizations of English alphabet for scroll groups 0-25 (e.g. 0 is A) and\n * Ø for `undefined`. Will fill in any that are not provided with these English localizations.\n * Also, if any values match the keys, the English localization will be used. This is useful in\n * case you want to pass in a temporary version of the localized strings while your localized\n * strings load.\n *\n * @example\n *\n * ```typescript\n * const myScrollGroupIdLocalizedStrings = {\n * [getLocalizeKeyForScrollGroupId('undefined')]: 'Ø',\n * [getLocalizeKeyForScrollGroupId(0)]: 'A',\n * [getLocalizeKeyForScrollGroupId(1)]: 'B',\n * [getLocalizeKeyForScrollGroupId(2)]: 'C',\n * [getLocalizeKeyForScrollGroupId(3)]: 'D',\n * [getLocalizeKeyForScrollGroupId(4)]: 'E',\n * };\n * ```\n *\n * @example\n *\n * ```tsx\n * const availableScrollGroupIds = [undefined, 0, 1, 2, 3, 4];\n *\n * const localizeKeys = getLocalizeKeysForScrollGroupIds();\n *\n * const [localizedStrings] = useLocalizedStrings(localizeKeys);\n *\n * ...\n *\n * \n * ```\n */\n localizedStrings?: LanguageStrings;\n};\n\n/** Selector component for choosing a scroll group */\nexport default function ScrollGroupSelector({\n availableScrollGroupIds,\n scrollGroupId,\n onChangeScrollGroupId,\n localizedStrings = {},\n}: ScrollGroupSelectorProps) {\n const localizedStringsDefaulted = {\n ...DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS,\n ...Object.fromEntries(\n Object.entries(localizedStrings).map(\n ([localizedStringKey, localizedStringValue]: [string, string]) => [\n localizedStringKey,\n localizedStringKey === localizedStringValue &&\n localizedStringKey in DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS\n ? DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS[localizedStringKey]\n : localizedStringValue,\n ],\n ),\n ),\n };\n return (\n \n onChangeScrollGroupId(\n newScrollGroupString === 'undefined' ? undefined : parseInt(newScrollGroupString, 10),\n )\n }\n >\n \n \n \n \n {availableScrollGroupIds.map((scrollGroupOptionId) => (\n \n {localizedStringsDefaulted[getLocalizeKeyForScrollGroupId(scrollGroupOptionId)]}\n \n ))}\n \n \n );\n}\n","import { PropsWithChildren } from 'react';\nimport { Separator } from '@/components/shadcn-ui/separator';\n\n/** Props for the SettingsList component, currently just children */\ntype SettingsListProps = PropsWithChildren;\n\n/**\n * SettingsList component is a wrapper for list items. Rendered with a formatted div\n *\n * @param children To populate the list with\n * @returns Formatted div encompassing the children\n */\nexport function SettingsList({ children }: SettingsListProps) {\n return
    {children}
    ;\n}\n\n/** Props for SettingsListItem component */\ntype SettingsListItemProps = PropsWithChildren & {\n /** Primary text of the list item */\n primary: string;\n\n /** Optional text of the list item */\n secondary?: string | undefined;\n\n /** Optional boolean to display a message if the children aren't loaded yet. Defaults to false */\n isLoading?: boolean;\n\n /** Optional message to display if isLoading */\n loadingMessage?: string;\n};\n\n/**\n * SettingsListItem component is a common list item. Rendered with a formatted div\n *\n * @param primary Primary text of the list item\n * @param secondary Optional secondary text of the list item\n * @param isLoading Optional, to display a message if the action component isn't generated yet,\n * defaults to false\n * @param children The action component(s) to provide for this item\n * @param loadingMessage Optional, message to display if isLoading\n * @returns Formatted div encompassing the list item content\n */\nexport function SettingsListItem({\n primary,\n secondary,\n children,\n isLoading = false,\n loadingMessage,\n}: SettingsListItemProps) {\n return (\n
    \n
    \n

    {primary}

    \n

    \n {secondary}\n

    \n
    \n\n {isLoading ? (\n

    {loadingMessage}

    \n ) : (\n
    {children}
    \n )}\n
    \n );\n}\n\n/** Props for SettingsListHeader component */\ntype SettingsListHeaderProps = {\n /** The primary text of the list header */\n primary: string;\n\n /** Optional secondary text of the list header */\n secondary?: string | undefined;\n\n /** Optional boolean to include a separator underneath the secondary text. Defaults to false */\n includeSeparator?: boolean;\n};\n\n/**\n * SettingsListHeader component displays text above the list\n *\n * @param primary The primary text of the list header\n * @param secondary Optional secondary text of the list header\n * @param includeSeparator Optional boolean to include a separator underneath the secondary text.\n * Defaults to false\n * @returns Formatted div with list header content\n */\nexport function SettingsListHeader({\n primary,\n secondary,\n includeSeparator = false,\n}: SettingsListHeaderProps) {\n return (\n
    \n
    \n

    {primary}

    \n

    {secondary}

    \n
    \n {includeSeparator ? : ''}\n
    \n );\n}\n","import React from 'react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Card = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nCard.displayName = 'Card';\n\nconst CardHeader = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nCardHeader.displayName = 'CardHeader';\n\nconst CardTitle = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n {/* added because of https://github.com/jsx-eslint/eslint-plugin-jsx-a11y/blob/main/docs/rules/heading-has-content.md */}\n {props.children}\n \n ),\n);\nCardTitle.displayName = 'CardTitle';\n\nconst CardDescription = React.forwardRef<\n HTMLParagraphElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n

    \n));\nCardDescription.displayName = 'CardDescription';\n\nconst CardContent = React.forwardRef>(\n ({ className, ...props }, ref) => (\n

    \n ),\n);\nCardContent.displayName = 'CardContent';\n\nconst CardFooter = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nCardFooter.displayName = 'CardFooter';\n\nexport { Card, CardHeader, CardFooter, CardTitle, CardDescription, CardContent };\n","import { Card, CardDescription, CardHeader, CardTitle } from '@/components/shadcn-ui/card';\nimport { CardContent } from '@mui/material';\nimport { PropsWithChildren } from 'react';\n\ntype SettingsCardProps = PropsWithChildren & {\n settingsGroupLabel: string;\n settingsGroupDescription: string;\n};\n\nexport default function SettingsCard({\n settingsGroupLabel,\n settingsGroupDescription,\n children,\n}: SettingsCardProps) {\n return (\n \n \n {settingsGroupLabel}\n {settingsGroupDescription}\n \n {children}\n \n );\n}\n","import Checkbox from '@/components/shadcn-ui/checkbox';\nimport { Label } from '@/components/shadcn-ui/label';\n\nexport type ChecklistProps = {\n /** Optional string representing the id attribute of the Checklist */\n id?: string;\n /** Optional string representing CSS class name(s) for styling */\n className?: string;\n /** Array of strings representing the checkable items */\n listItems: string[];\n /** Array of strings representing the checked items */\n selectedListItems: string[];\n /**\n * Function that is called when a checkbox item is selected or deselected\n *\n * @param item The string description for this item\n * @param selected True if selected, false if not selected\n */\n handleSelectListItem: (item: string, selected: boolean) => void;\n\n /**\n * Optional function creates a label for a provided checkable item\n *\n * @param item The item for which a label is to be created\n * @returns A string representing the label text for the checkbox associated with that item\n */\n createLabel?: (item: string) => string;\n};\n\n/** Renders a list of checkboxes. Each checkbox corresponds to an item from the `listItems` array. */\nexport default function Checklist({\n id,\n className,\n listItems,\n selectedListItems,\n handleSelectListItem,\n createLabel,\n}: ChecklistProps) {\n return (\n
    \n {listItems.map((item) => (\n
    \n handleSelectListItem(item, value)}\n />\n \n
    \n ))}\n
    \n );\n}\n","function _interopRequireDefault(obj) {\n return obj && obj.__esModule ? obj : {\n \"default\": obj\n };\n}\nmodule.exports = _interopRequireDefault, module.exports.__esModule = true, module.exports[\"default\"] = module.exports;","export default function chainPropTypes(propType1, propType2) {\n if (process.env.NODE_ENV === 'production') {\n return () => null;\n }\n return function validate(...args) {\n return propType1(...args) || propType2(...args);\n };\n}","export default function _extends() {\n _extends = Object.assign ? Object.assign.bind() : function (target) {\n for (var i = 1; i < arguments.length; i++) {\n var source = arguments[i];\n for (var key in source) {\n if (Object.prototype.hasOwnProperty.call(source, key)) {\n target[key] = source[key];\n }\n }\n }\n return target;\n };\n return _extends.apply(this, arguments);\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\n// https://github.com/sindresorhus/is-plain-obj/blob/main/index.js\nexport function isPlainObject(item) {\n if (typeof item !== 'object' || item === null) {\n return false;\n }\n const prototype = Object.getPrototypeOf(item);\n return (prototype === null || prototype === Object.prototype || Object.getPrototypeOf(prototype) === null) && !(Symbol.toStringTag in item) && !(Symbol.iterator in item);\n}\nfunction deepClone(source) {\n if (!isPlainObject(source)) {\n return source;\n }\n const output = {};\n Object.keys(source).forEach(key => {\n output[key] = deepClone(source[key]);\n });\n return output;\n}\nexport default function deepmerge(target, source, options = {\n clone: true\n}) {\n const output = options.clone ? _extends({}, target) : target;\n if (isPlainObject(target) && isPlainObject(source)) {\n Object.keys(source).forEach(key => {\n // Avoid prototype pollution\n if (key === '__proto__') {\n return;\n }\n if (isPlainObject(source[key]) && key in target && isPlainObject(target[key])) {\n // Since `output` is a clone of `target` and we have narrowed `target` in this block we can cast to the same type.\n output[key] = deepmerge(target[key], source[key], options);\n } else if (options.clone) {\n output[key] = isPlainObject(source[key]) ? deepClone(source[key]) : source[key];\n } else {\n output[key] = source[key];\n }\n });\n }\n return output;\n}","/** @license React v16.13.1\n * react-is.production.min.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';var b=\"function\"===typeof Symbol&&Symbol.for,c=b?Symbol.for(\"react.element\"):60103,d=b?Symbol.for(\"react.portal\"):60106,e=b?Symbol.for(\"react.fragment\"):60107,f=b?Symbol.for(\"react.strict_mode\"):60108,g=b?Symbol.for(\"react.profiler\"):60114,h=b?Symbol.for(\"react.provider\"):60109,k=b?Symbol.for(\"react.context\"):60110,l=b?Symbol.for(\"react.async_mode\"):60111,m=b?Symbol.for(\"react.concurrent_mode\"):60111,n=b?Symbol.for(\"react.forward_ref\"):60112,p=b?Symbol.for(\"react.suspense\"):60113,q=b?\nSymbol.for(\"react.suspense_list\"):60120,r=b?Symbol.for(\"react.memo\"):60115,t=b?Symbol.for(\"react.lazy\"):60116,v=b?Symbol.for(\"react.block\"):60121,w=b?Symbol.for(\"react.fundamental\"):60117,x=b?Symbol.for(\"react.responder\"):60118,y=b?Symbol.for(\"react.scope\"):60119;\nfunction z(a){if(\"object\"===typeof a&&null!==a){var u=a.$$typeof;switch(u){case c:switch(a=a.type,a){case l:case m:case e:case g:case f:case p:return a;default:switch(a=a&&a.$$typeof,a){case k:case n:case t:case r:case h:return a;default:return u}}case d:return u}}}function A(a){return z(a)===m}exports.AsyncMode=l;exports.ConcurrentMode=m;exports.ContextConsumer=k;exports.ContextProvider=h;exports.Element=c;exports.ForwardRef=n;exports.Fragment=e;exports.Lazy=t;exports.Memo=r;exports.Portal=d;\nexports.Profiler=g;exports.StrictMode=f;exports.Suspense=p;exports.isAsyncMode=function(a){return A(a)||z(a)===l};exports.isConcurrentMode=A;exports.isContextConsumer=function(a){return z(a)===k};exports.isContextProvider=function(a){return z(a)===h};exports.isElement=function(a){return\"object\"===typeof a&&null!==a&&a.$$typeof===c};exports.isForwardRef=function(a){return z(a)===n};exports.isFragment=function(a){return z(a)===e};exports.isLazy=function(a){return z(a)===t};\nexports.isMemo=function(a){return z(a)===r};exports.isPortal=function(a){return z(a)===d};exports.isProfiler=function(a){return z(a)===g};exports.isStrictMode=function(a){return z(a)===f};exports.isSuspense=function(a){return z(a)===p};\nexports.isValidElementType=function(a){return\"string\"===typeof a||\"function\"===typeof a||a===e||a===m||a===g||a===f||a===p||a===q||\"object\"===typeof a&&null!==a&&(a.$$typeof===t||a.$$typeof===r||a.$$typeof===h||a.$$typeof===k||a.$$typeof===n||a.$$typeof===w||a.$$typeof===x||a.$$typeof===y||a.$$typeof===v)};exports.typeOf=z;\n","/** @license React v16.13.1\n * react-is.development.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\n\n\nif (process.env.NODE_ENV !== \"production\") {\n (function() {\n'use strict';\n\n// The Symbol used to tag the ReactElement-like types. If there is no native Symbol\n// nor polyfill, then a plain number is used for performance.\nvar hasSymbol = typeof Symbol === 'function' && Symbol.for;\nvar REACT_ELEMENT_TYPE = hasSymbol ? Symbol.for('react.element') : 0xeac7;\nvar REACT_PORTAL_TYPE = hasSymbol ? Symbol.for('react.portal') : 0xeaca;\nvar REACT_FRAGMENT_TYPE = hasSymbol ? Symbol.for('react.fragment') : 0xeacb;\nvar REACT_STRICT_MODE_TYPE = hasSymbol ? Symbol.for('react.strict_mode') : 0xeacc;\nvar REACT_PROFILER_TYPE = hasSymbol ? Symbol.for('react.profiler') : 0xead2;\nvar REACT_PROVIDER_TYPE = hasSymbol ? Symbol.for('react.provider') : 0xeacd;\nvar REACT_CONTEXT_TYPE = hasSymbol ? Symbol.for('react.context') : 0xeace; // TODO: We don't use AsyncMode or ConcurrentMode anymore. They were temporary\n// (unstable) APIs that have been removed. Can we remove the symbols?\n\nvar REACT_ASYNC_MODE_TYPE = hasSymbol ? Symbol.for('react.async_mode') : 0xeacf;\nvar REACT_CONCURRENT_MODE_TYPE = hasSymbol ? Symbol.for('react.concurrent_mode') : 0xeacf;\nvar REACT_FORWARD_REF_TYPE = hasSymbol ? Symbol.for('react.forward_ref') : 0xead0;\nvar REACT_SUSPENSE_TYPE = hasSymbol ? Symbol.for('react.suspense') : 0xead1;\nvar REACT_SUSPENSE_LIST_TYPE = hasSymbol ? Symbol.for('react.suspense_list') : 0xead8;\nvar REACT_MEMO_TYPE = hasSymbol ? Symbol.for('react.memo') : 0xead3;\nvar REACT_LAZY_TYPE = hasSymbol ? Symbol.for('react.lazy') : 0xead4;\nvar REACT_BLOCK_TYPE = hasSymbol ? Symbol.for('react.block') : 0xead9;\nvar REACT_FUNDAMENTAL_TYPE = hasSymbol ? Symbol.for('react.fundamental') : 0xead5;\nvar REACT_RESPONDER_TYPE = hasSymbol ? Symbol.for('react.responder') : 0xead6;\nvar REACT_SCOPE_TYPE = hasSymbol ? Symbol.for('react.scope') : 0xead7;\n\nfunction isValidElementType(type) {\n return typeof type === 'string' || typeof type === 'function' || // Note: its typeof might be other than 'symbol' or 'number' if it's a polyfill.\n type === REACT_FRAGMENT_TYPE || type === REACT_CONCURRENT_MODE_TYPE || type === REACT_PROFILER_TYPE || type === REACT_STRICT_MODE_TYPE || type === REACT_SUSPENSE_TYPE || type === REACT_SUSPENSE_LIST_TYPE || typeof type === 'object' && type !== null && (type.$$typeof === REACT_LAZY_TYPE || type.$$typeof === REACT_MEMO_TYPE || type.$$typeof === REACT_PROVIDER_TYPE || type.$$typeof === REACT_CONTEXT_TYPE || type.$$typeof === REACT_FORWARD_REF_TYPE || type.$$typeof === REACT_FUNDAMENTAL_TYPE || type.$$typeof === REACT_RESPONDER_TYPE || type.$$typeof === REACT_SCOPE_TYPE || type.$$typeof === REACT_BLOCK_TYPE);\n}\n\nfunction typeOf(object) {\n if (typeof object === 'object' && object !== null) {\n var $$typeof = object.$$typeof;\n\n switch ($$typeof) {\n case REACT_ELEMENT_TYPE:\n var type = object.type;\n\n switch (type) {\n case REACT_ASYNC_MODE_TYPE:\n case REACT_CONCURRENT_MODE_TYPE:\n case REACT_FRAGMENT_TYPE:\n case REACT_PROFILER_TYPE:\n case REACT_STRICT_MODE_TYPE:\n case REACT_SUSPENSE_TYPE:\n return type;\n\n default:\n var $$typeofType = type && type.$$typeof;\n\n switch ($$typeofType) {\n case REACT_CONTEXT_TYPE:\n case REACT_FORWARD_REF_TYPE:\n case REACT_LAZY_TYPE:\n case REACT_MEMO_TYPE:\n case REACT_PROVIDER_TYPE:\n return $$typeofType;\n\n default:\n return $$typeof;\n }\n\n }\n\n case REACT_PORTAL_TYPE:\n return $$typeof;\n }\n }\n\n return undefined;\n} // AsyncMode is deprecated along with isAsyncMode\n\nvar AsyncMode = REACT_ASYNC_MODE_TYPE;\nvar ConcurrentMode = REACT_CONCURRENT_MODE_TYPE;\nvar ContextConsumer = REACT_CONTEXT_TYPE;\nvar ContextProvider = REACT_PROVIDER_TYPE;\nvar Element = REACT_ELEMENT_TYPE;\nvar ForwardRef = REACT_FORWARD_REF_TYPE;\nvar Fragment = REACT_FRAGMENT_TYPE;\nvar Lazy = REACT_LAZY_TYPE;\nvar Memo = REACT_MEMO_TYPE;\nvar Portal = REACT_PORTAL_TYPE;\nvar Profiler = REACT_PROFILER_TYPE;\nvar StrictMode = REACT_STRICT_MODE_TYPE;\nvar Suspense = REACT_SUSPENSE_TYPE;\nvar hasWarnedAboutDeprecatedIsAsyncMode = false; // AsyncMode should be deprecated\n\nfunction isAsyncMode(object) {\n {\n if (!hasWarnedAboutDeprecatedIsAsyncMode) {\n hasWarnedAboutDeprecatedIsAsyncMode = true; // Using console['warn'] to evade Babel and ESLint\n\n console['warn']('The ReactIs.isAsyncMode() alias has been deprecated, ' + 'and will be removed in React 17+. Update your code to use ' + 'ReactIs.isConcurrentMode() instead. It has the exact same API.');\n }\n }\n\n return isConcurrentMode(object) || typeOf(object) === REACT_ASYNC_MODE_TYPE;\n}\nfunction isConcurrentMode(object) {\n return typeOf(object) === REACT_CONCURRENT_MODE_TYPE;\n}\nfunction isContextConsumer(object) {\n return typeOf(object) === REACT_CONTEXT_TYPE;\n}\nfunction isContextProvider(object) {\n return typeOf(object) === REACT_PROVIDER_TYPE;\n}\nfunction isElement(object) {\n return typeof object === 'object' && object !== null && object.$$typeof === REACT_ELEMENT_TYPE;\n}\nfunction isForwardRef(object) {\n return typeOf(object) === REACT_FORWARD_REF_TYPE;\n}\nfunction isFragment(object) {\n return typeOf(object) === REACT_FRAGMENT_TYPE;\n}\nfunction isLazy(object) {\n return typeOf(object) === REACT_LAZY_TYPE;\n}\nfunction isMemo(object) {\n return typeOf(object) === REACT_MEMO_TYPE;\n}\nfunction isPortal(object) {\n return typeOf(object) === REACT_PORTAL_TYPE;\n}\nfunction isProfiler(object) {\n return typeOf(object) === REACT_PROFILER_TYPE;\n}\nfunction isStrictMode(object) {\n return typeOf(object) === REACT_STRICT_MODE_TYPE;\n}\nfunction isSuspense(object) {\n return typeOf(object) === REACT_SUSPENSE_TYPE;\n}\n\nexports.AsyncMode = AsyncMode;\nexports.ConcurrentMode = ConcurrentMode;\nexports.ContextConsumer = ContextConsumer;\nexports.ContextProvider = ContextProvider;\nexports.Element = Element;\nexports.ForwardRef = ForwardRef;\nexports.Fragment = Fragment;\nexports.Lazy = Lazy;\nexports.Memo = Memo;\nexports.Portal = Portal;\nexports.Profiler = Profiler;\nexports.StrictMode = StrictMode;\nexports.Suspense = Suspense;\nexports.isAsyncMode = isAsyncMode;\nexports.isConcurrentMode = isConcurrentMode;\nexports.isContextConsumer = isContextConsumer;\nexports.isContextProvider = isContextProvider;\nexports.isElement = isElement;\nexports.isForwardRef = isForwardRef;\nexports.isFragment = isFragment;\nexports.isLazy = isLazy;\nexports.isMemo = isMemo;\nexports.isPortal = isPortal;\nexports.isProfiler = isProfiler;\nexports.isStrictMode = isStrictMode;\nexports.isSuspense = isSuspense;\nexports.isValidElementType = isValidElementType;\nexports.typeOf = typeOf;\n })();\n}\n","'use strict';\n\nif (process.env.NODE_ENV === 'production') {\n module.exports = require('./cjs/react-is.production.min.js');\n} else {\n module.exports = require('./cjs/react-is.development.js');\n}\n","/*\nobject-assign\n(c) Sindre Sorhus\n@license MIT\n*/\n\n'use strict';\n/* eslint-disable no-unused-vars */\nvar getOwnPropertySymbols = Object.getOwnPropertySymbols;\nvar hasOwnProperty = Object.prototype.hasOwnProperty;\nvar propIsEnumerable = Object.prototype.propertyIsEnumerable;\n\nfunction toObject(val) {\n\tif (val === null || val === undefined) {\n\t\tthrow new TypeError('Object.assign cannot be called with null or undefined');\n\t}\n\n\treturn Object(val);\n}\n\nfunction shouldUseNative() {\n\ttry {\n\t\tif (!Object.assign) {\n\t\t\treturn false;\n\t\t}\n\n\t\t// Detect buggy property enumeration order in older V8 versions.\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=4118\n\t\tvar test1 = new String('abc'); // eslint-disable-line no-new-wrappers\n\t\ttest1[5] = 'de';\n\t\tif (Object.getOwnPropertyNames(test1)[0] === '5') {\n\t\t\treturn false;\n\t\t}\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=3056\n\t\tvar test2 = {};\n\t\tfor (var i = 0; i < 10; i++) {\n\t\t\ttest2['_' + String.fromCharCode(i)] = i;\n\t\t}\n\t\tvar order2 = Object.getOwnPropertyNames(test2).map(function (n) {\n\t\t\treturn test2[n];\n\t\t});\n\t\tif (order2.join('') !== '0123456789') {\n\t\t\treturn false;\n\t\t}\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=3056\n\t\tvar test3 = {};\n\t\t'abcdefghijklmnopqrst'.split('').forEach(function (letter) {\n\t\t\ttest3[letter] = letter;\n\t\t});\n\t\tif (Object.keys(Object.assign({}, test3)).join('') !==\n\t\t\t\t'abcdefghijklmnopqrst') {\n\t\t\treturn false;\n\t\t}\n\n\t\treturn true;\n\t} catch (err) {\n\t\t// We don't expect any of the above to throw, but better to be safe.\n\t\treturn false;\n\t}\n}\n\nmodule.exports = shouldUseNative() ? Object.assign : function (target, source) {\n\tvar from;\n\tvar to = toObject(target);\n\tvar symbols;\n\n\tfor (var s = 1; s < arguments.length; s++) {\n\t\tfrom = Object(arguments[s]);\n\n\t\tfor (var key in from) {\n\t\t\tif (hasOwnProperty.call(from, key)) {\n\t\t\t\tto[key] = from[key];\n\t\t\t}\n\t\t}\n\n\t\tif (getOwnPropertySymbols) {\n\t\t\tsymbols = getOwnPropertySymbols(from);\n\t\t\tfor (var i = 0; i < symbols.length; i++) {\n\t\t\t\tif (propIsEnumerable.call(from, symbols[i])) {\n\t\t\t\t\tto[symbols[i]] = from[symbols[i]];\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\n\treturn to;\n};\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar ReactPropTypesSecret = 'SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED';\n\nmodule.exports = ReactPropTypesSecret;\n","module.exports = Function.call.bind(Object.prototype.hasOwnProperty);\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar printWarning = function() {};\n\nif (process.env.NODE_ENV !== 'production') {\n var ReactPropTypesSecret = require('./lib/ReactPropTypesSecret');\n var loggedTypeFailures = {};\n var has = require('./lib/has');\n\n printWarning = function(text) {\n var message = 'Warning: ' + text;\n if (typeof console !== 'undefined') {\n console.error(message);\n }\n try {\n // --- Welcome to debugging React ---\n // This error was thrown as a convenience so that you can use this stack\n // to find the callsite that caused this warning to fire.\n throw new Error(message);\n } catch (x) { /**/ }\n };\n}\n\n/**\n * Assert that the values match with the type specs.\n * Error messages are memorized and will only be shown once.\n *\n * @param {object} typeSpecs Map of name to a ReactPropType\n * @param {object} values Runtime values that need to be type-checked\n * @param {string} location e.g. \"prop\", \"context\", \"child context\"\n * @param {string} componentName Name of the component for error messages.\n * @param {?Function} getStack Returns the component stack.\n * @private\n */\nfunction checkPropTypes(typeSpecs, values, location, componentName, getStack) {\n if (process.env.NODE_ENV !== 'production') {\n for (var typeSpecName in typeSpecs) {\n if (has(typeSpecs, typeSpecName)) {\n var error;\n // Prop type validation may throw. In case they do, we don't want to\n // fail the render phase where it didn't fail before. So we log it.\n // After these have been cleaned up, we'll let them throw.\n try {\n // This is intentionally an invariant that gets caught. It's the same\n // behavior as without this statement except with a better message.\n if (typeof typeSpecs[typeSpecName] !== 'function') {\n var err = Error(\n (componentName || 'React class') + ': ' + location + ' type `' + typeSpecName + '` is invalid; ' +\n 'it must be a function, usually from the `prop-types` package, but received `' + typeof typeSpecs[typeSpecName] + '`.' +\n 'This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.'\n );\n err.name = 'Invariant Violation';\n throw err;\n }\n error = typeSpecs[typeSpecName](values, typeSpecName, componentName, location, null, ReactPropTypesSecret);\n } catch (ex) {\n error = ex;\n }\n if (error && !(error instanceof Error)) {\n printWarning(\n (componentName || 'React class') + ': type specification of ' +\n location + ' `' + typeSpecName + '` is invalid; the type checker ' +\n 'function must return `null` or an `Error` but returned a ' + typeof error + '. ' +\n 'You may have forgotten to pass an argument to the type checker ' +\n 'creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and ' +\n 'shape all require an argument).'\n );\n }\n if (error instanceof Error && !(error.message in loggedTypeFailures)) {\n // Only monitor this failure once because there tends to be a lot of the\n // same error.\n loggedTypeFailures[error.message] = true;\n\n var stack = getStack ? getStack() : '';\n\n printWarning(\n 'Failed ' + location + ' type: ' + error.message + (stack != null ? stack : '')\n );\n }\n }\n }\n }\n}\n\n/**\n * Resets warning cache when testing.\n *\n * @private\n */\ncheckPropTypes.resetWarningCache = function() {\n if (process.env.NODE_ENV !== 'production') {\n loggedTypeFailures = {};\n }\n}\n\nmodule.exports = checkPropTypes;\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar ReactIs = require('react-is');\nvar assign = require('object-assign');\n\nvar ReactPropTypesSecret = require('./lib/ReactPropTypesSecret');\nvar has = require('./lib/has');\nvar checkPropTypes = require('./checkPropTypes');\n\nvar printWarning = function() {};\n\nif (process.env.NODE_ENV !== 'production') {\n printWarning = function(text) {\n var message = 'Warning: ' + text;\n if (typeof console !== 'undefined') {\n console.error(message);\n }\n try {\n // --- Welcome to debugging React ---\n // This error was thrown as a convenience so that you can use this stack\n // to find the callsite that caused this warning to fire.\n throw new Error(message);\n } catch (x) {}\n };\n}\n\nfunction emptyFunctionThatReturnsNull() {\n return null;\n}\n\nmodule.exports = function(isValidElement, throwOnDirectAccess) {\n /* global Symbol */\n var ITERATOR_SYMBOL = typeof Symbol === 'function' && Symbol.iterator;\n var FAUX_ITERATOR_SYMBOL = '@@iterator'; // Before Symbol spec.\n\n /**\n * Returns the iterator method function contained on the iterable object.\n *\n * Be sure to invoke the function with the iterable as context:\n *\n * var iteratorFn = getIteratorFn(myIterable);\n * if (iteratorFn) {\n * var iterator = iteratorFn.call(myIterable);\n * ...\n * }\n *\n * @param {?object} maybeIterable\n * @return {?function}\n */\n function getIteratorFn(maybeIterable) {\n var iteratorFn = maybeIterable && (ITERATOR_SYMBOL && maybeIterable[ITERATOR_SYMBOL] || maybeIterable[FAUX_ITERATOR_SYMBOL]);\n if (typeof iteratorFn === 'function') {\n return iteratorFn;\n }\n }\n\n /**\n * Collection of methods that allow declaration and validation of props that are\n * supplied to React components. Example usage:\n *\n * var Props = require('ReactPropTypes');\n * var MyArticle = React.createClass({\n * propTypes: {\n * // An optional string prop named \"description\".\n * description: Props.string,\n *\n * // A required enum prop named \"category\".\n * category: Props.oneOf(['News','Photos']).isRequired,\n *\n * // A prop named \"dialog\" that requires an instance of Dialog.\n * dialog: Props.instanceOf(Dialog).isRequired\n * },\n * render: function() { ... }\n * });\n *\n * A more formal specification of how these methods are used:\n *\n * type := array|bool|func|object|number|string|oneOf([...])|instanceOf(...)\n * decl := ReactPropTypes.{type}(.isRequired)?\n *\n * Each and every declaration produces a function with the same signature. This\n * allows the creation of custom validation functions. For example:\n *\n * var MyLink = React.createClass({\n * propTypes: {\n * // An optional string or URI prop named \"href\".\n * href: function(props, propName, componentName) {\n * var propValue = props[propName];\n * if (propValue != null && typeof propValue !== 'string' &&\n * !(propValue instanceof URI)) {\n * return new Error(\n * 'Expected a string or an URI for ' + propName + ' in ' +\n * componentName\n * );\n * }\n * }\n * },\n * render: function() {...}\n * });\n *\n * @internal\n */\n\n var ANONYMOUS = '<>';\n\n // Important!\n // Keep this list in sync with production version in `./factoryWithThrowingShims.js`.\n var ReactPropTypes = {\n array: createPrimitiveTypeChecker('array'),\n bigint: createPrimitiveTypeChecker('bigint'),\n bool: createPrimitiveTypeChecker('boolean'),\n func: createPrimitiveTypeChecker('function'),\n number: createPrimitiveTypeChecker('number'),\n object: createPrimitiveTypeChecker('object'),\n string: createPrimitiveTypeChecker('string'),\n symbol: createPrimitiveTypeChecker('symbol'),\n\n any: createAnyTypeChecker(),\n arrayOf: createArrayOfTypeChecker,\n element: createElementTypeChecker(),\n elementType: createElementTypeTypeChecker(),\n instanceOf: createInstanceTypeChecker,\n node: createNodeChecker(),\n objectOf: createObjectOfTypeChecker,\n oneOf: createEnumTypeChecker,\n oneOfType: createUnionTypeChecker,\n shape: createShapeTypeChecker,\n exact: createStrictShapeTypeChecker,\n };\n\n /**\n * inlined Object.is polyfill to avoid requiring consumers ship their own\n * https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object/is\n */\n /*eslint-disable no-self-compare*/\n function is(x, y) {\n // SameValue algorithm\n if (x === y) {\n // Steps 1-5, 7-10\n // Steps 6.b-6.e: +0 != -0\n return x !== 0 || 1 / x === 1 / y;\n } else {\n // Step 6.a: NaN == NaN\n return x !== x && y !== y;\n }\n }\n /*eslint-enable no-self-compare*/\n\n /**\n * We use an Error-like object for backward compatibility as people may call\n * PropTypes directly and inspect their output. However, we don't use real\n * Errors anymore. We don't inspect their stack anyway, and creating them\n * is prohibitively expensive if they are created too often, such as what\n * happens in oneOfType() for any type before the one that matched.\n */\n function PropTypeError(message, data) {\n this.message = message;\n this.data = data && typeof data === 'object' ? data: {};\n this.stack = '';\n }\n // Make `instanceof Error` still work for returned errors.\n PropTypeError.prototype = Error.prototype;\n\n function createChainableTypeChecker(validate) {\n if (process.env.NODE_ENV !== 'production') {\n var manualPropTypeCallCache = {};\n var manualPropTypeWarningCount = 0;\n }\n function checkType(isRequired, props, propName, componentName, location, propFullName, secret) {\n componentName = componentName || ANONYMOUS;\n propFullName = propFullName || propName;\n\n if (secret !== ReactPropTypesSecret) {\n if (throwOnDirectAccess) {\n // New behavior only for users of `prop-types` package\n var err = new Error(\n 'Calling PropTypes validators directly is not supported by the `prop-types` package. ' +\n 'Use `PropTypes.checkPropTypes()` to call them. ' +\n 'Read more at http://fb.me/use-check-prop-types'\n );\n err.name = 'Invariant Violation';\n throw err;\n } else if (process.env.NODE_ENV !== 'production' && typeof console !== 'undefined') {\n // Old behavior for people using React.PropTypes\n var cacheKey = componentName + ':' + propName;\n if (\n !manualPropTypeCallCache[cacheKey] &&\n // Avoid spamming the console because they are often not actionable except for lib authors\n manualPropTypeWarningCount < 3\n ) {\n printWarning(\n 'You are manually calling a React.PropTypes validation ' +\n 'function for the `' + propFullName + '` prop on `' + componentName + '`. This is deprecated ' +\n 'and will throw in the standalone `prop-types` package. ' +\n 'You may be seeing this warning due to a third-party PropTypes ' +\n 'library. See https://fb.me/react-warning-dont-call-proptypes ' + 'for details.'\n );\n manualPropTypeCallCache[cacheKey] = true;\n manualPropTypeWarningCount++;\n }\n }\n }\n if (props[propName] == null) {\n if (isRequired) {\n if (props[propName] === null) {\n return new PropTypeError('The ' + location + ' `' + propFullName + '` is marked as required ' + ('in `' + componentName + '`, but its value is `null`.'));\n }\n return new PropTypeError('The ' + location + ' `' + propFullName + '` is marked as required in ' + ('`' + componentName + '`, but its value is `undefined`.'));\n }\n return null;\n } else {\n return validate(props, propName, componentName, location, propFullName);\n }\n }\n\n var chainedCheckType = checkType.bind(null, false);\n chainedCheckType.isRequired = checkType.bind(null, true);\n\n return chainedCheckType;\n }\n\n function createPrimitiveTypeChecker(expectedType) {\n function validate(props, propName, componentName, location, propFullName, secret) {\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== expectedType) {\n // `propValue` being instance of, say, date/regexp, pass the 'object'\n // check, but we can offer a more precise error message here rather than\n // 'of type `object`'.\n var preciseType = getPreciseType(propValue);\n\n return new PropTypeError(\n 'Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + preciseType + '` supplied to `' + componentName + '`, expected ') + ('`' + expectedType + '`.'),\n {expectedType: expectedType}\n );\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createAnyTypeChecker() {\n return createChainableTypeChecker(emptyFunctionThatReturnsNull);\n }\n\n function createArrayOfTypeChecker(typeChecker) {\n function validate(props, propName, componentName, location, propFullName) {\n if (typeof typeChecker !== 'function') {\n return new PropTypeError('Property `' + propFullName + '` of component `' + componentName + '` has invalid PropType notation inside arrayOf.');\n }\n var propValue = props[propName];\n if (!Array.isArray(propValue)) {\n var propType = getPropType(propValue);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected an array.'));\n }\n for (var i = 0; i < propValue.length; i++) {\n var error = typeChecker(propValue, i, componentName, location, propFullName + '[' + i + ']', ReactPropTypesSecret);\n if (error instanceof Error) {\n return error;\n }\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createElementTypeChecker() {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n if (!isValidElement(propValue)) {\n var propType = getPropType(propValue);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected a single ReactElement.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createElementTypeTypeChecker() {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n if (!ReactIs.isValidElementType(propValue)) {\n var propType = getPropType(propValue);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected a single ReactElement type.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createInstanceTypeChecker(expectedClass) {\n function validate(props, propName, componentName, location, propFullName) {\n if (!(props[propName] instanceof expectedClass)) {\n var expectedClassName = expectedClass.name || ANONYMOUS;\n var actualClassName = getClassName(props[propName]);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + actualClassName + '` supplied to `' + componentName + '`, expected ') + ('instance of `' + expectedClassName + '`.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createEnumTypeChecker(expectedValues) {\n if (!Array.isArray(expectedValues)) {\n if (process.env.NODE_ENV !== 'production') {\n if (arguments.length > 1) {\n printWarning(\n 'Invalid arguments supplied to oneOf, expected an array, got ' + arguments.length + ' arguments. ' +\n 'A common mistake is to write oneOf(x, y, z) instead of oneOf([x, y, z]).'\n );\n } else {\n printWarning('Invalid argument supplied to oneOf, expected an array.');\n }\n }\n return emptyFunctionThatReturnsNull;\n }\n\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n for (var i = 0; i < expectedValues.length; i++) {\n if (is(propValue, expectedValues[i])) {\n return null;\n }\n }\n\n var valuesString = JSON.stringify(expectedValues, function replacer(key, value) {\n var type = getPreciseType(value);\n if (type === 'symbol') {\n return String(value);\n }\n return value;\n });\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of value `' + String(propValue) + '` ' + ('supplied to `' + componentName + '`, expected one of ' + valuesString + '.'));\n }\n return createChainableTypeChecker(validate);\n }\n\n function createObjectOfTypeChecker(typeChecker) {\n function validate(props, propName, componentName, location, propFullName) {\n if (typeof typeChecker !== 'function') {\n return new PropTypeError('Property `' + propFullName + '` of component `' + componentName + '` has invalid PropType notation inside objectOf.');\n }\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== 'object') {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected an object.'));\n }\n for (var key in propValue) {\n if (has(propValue, key)) {\n var error = typeChecker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret);\n if (error instanceof Error) {\n return error;\n }\n }\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createUnionTypeChecker(arrayOfTypeCheckers) {\n if (!Array.isArray(arrayOfTypeCheckers)) {\n process.env.NODE_ENV !== 'production' ? printWarning('Invalid argument supplied to oneOfType, expected an instance of array.') : void 0;\n return emptyFunctionThatReturnsNull;\n }\n\n for (var i = 0; i < arrayOfTypeCheckers.length; i++) {\n var checker = arrayOfTypeCheckers[i];\n if (typeof checker !== 'function') {\n printWarning(\n 'Invalid argument supplied to oneOfType. Expected an array of check functions, but ' +\n 'received ' + getPostfixForTypeWarning(checker) + ' at index ' + i + '.'\n );\n return emptyFunctionThatReturnsNull;\n }\n }\n\n function validate(props, propName, componentName, location, propFullName) {\n var expectedTypes = [];\n for (var i = 0; i < arrayOfTypeCheckers.length; i++) {\n var checker = arrayOfTypeCheckers[i];\n var checkerResult = checker(props, propName, componentName, location, propFullName, ReactPropTypesSecret);\n if (checkerResult == null) {\n return null;\n }\n if (checkerResult.data && has(checkerResult.data, 'expectedType')) {\n expectedTypes.push(checkerResult.data.expectedType);\n }\n }\n var expectedTypesMessage = (expectedTypes.length > 0) ? ', expected one of type [' + expectedTypes.join(', ') + ']': '';\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` supplied to ' + ('`' + componentName + '`' + expectedTypesMessage + '.'));\n }\n return createChainableTypeChecker(validate);\n }\n\n function createNodeChecker() {\n function validate(props, propName, componentName, location, propFullName) {\n if (!isNode(props[propName])) {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` supplied to ' + ('`' + componentName + '`, expected a ReactNode.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function invalidValidatorError(componentName, location, propFullName, key, type) {\n return new PropTypeError(\n (componentName || 'React class') + ': ' + location + ' type `' + propFullName + '.' + key + '` is invalid; ' +\n 'it must be a function, usually from the `prop-types` package, but received `' + type + '`.'\n );\n }\n\n function createShapeTypeChecker(shapeTypes) {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== 'object') {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type `' + propType + '` ' + ('supplied to `' + componentName + '`, expected `object`.'));\n }\n for (var key in shapeTypes) {\n var checker = shapeTypes[key];\n if (typeof checker !== 'function') {\n return invalidValidatorError(componentName, location, propFullName, key, getPreciseType(checker));\n }\n var error = checker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret);\n if (error) {\n return error;\n }\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createStrictShapeTypeChecker(shapeTypes) {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== 'object') {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type `' + propType + '` ' + ('supplied to `' + componentName + '`, expected `object`.'));\n }\n // We need to check all keys in case some are required but missing from props.\n var allKeys = assign({}, props[propName], shapeTypes);\n for (var key in allKeys) {\n var checker = shapeTypes[key];\n if (has(shapeTypes, key) && typeof checker !== 'function') {\n return invalidValidatorError(componentName, location, propFullName, key, getPreciseType(checker));\n }\n if (!checker) {\n return new PropTypeError(\n 'Invalid ' + location + ' `' + propFullName + '` key `' + key + '` supplied to `' + componentName + '`.' +\n '\\nBad object: ' + JSON.stringify(props[propName], null, ' ') +\n '\\nValid keys: ' + JSON.stringify(Object.keys(shapeTypes), null, ' ')\n );\n }\n var error = checker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret);\n if (error) {\n return error;\n }\n }\n return null;\n }\n\n return createChainableTypeChecker(validate);\n }\n\n function isNode(propValue) {\n switch (typeof propValue) {\n case 'number':\n case 'string':\n case 'undefined':\n return true;\n case 'boolean':\n return !propValue;\n case 'object':\n if (Array.isArray(propValue)) {\n return propValue.every(isNode);\n }\n if (propValue === null || isValidElement(propValue)) {\n return true;\n }\n\n var iteratorFn = getIteratorFn(propValue);\n if (iteratorFn) {\n var iterator = iteratorFn.call(propValue);\n var step;\n if (iteratorFn !== propValue.entries) {\n while (!(step = iterator.next()).done) {\n if (!isNode(step.value)) {\n return false;\n }\n }\n } else {\n // Iterator will provide entry [k,v] tuples rather than values.\n while (!(step = iterator.next()).done) {\n var entry = step.value;\n if (entry) {\n if (!isNode(entry[1])) {\n return false;\n }\n }\n }\n }\n } else {\n return false;\n }\n\n return true;\n default:\n return false;\n }\n }\n\n function isSymbol(propType, propValue) {\n // Native Symbol.\n if (propType === 'symbol') {\n return true;\n }\n\n // falsy value can't be a Symbol\n if (!propValue) {\n return false;\n }\n\n // 19.4.3.5 Symbol.prototype[@@toStringTag] === 'Symbol'\n if (propValue['@@toStringTag'] === 'Symbol') {\n return true;\n }\n\n // Fallback for non-spec compliant Symbols which are polyfilled.\n if (typeof Symbol === 'function' && propValue instanceof Symbol) {\n return true;\n }\n\n return false;\n }\n\n // Equivalent of `typeof` but with special handling for array and regexp.\n function getPropType(propValue) {\n var propType = typeof propValue;\n if (Array.isArray(propValue)) {\n return 'array';\n }\n if (propValue instanceof RegExp) {\n // Old webkits (at least until Android 4.0) return 'function' rather than\n // 'object' for typeof a RegExp. We'll normalize this here so that /bla/\n // passes PropTypes.object.\n return 'object';\n }\n if (isSymbol(propType, propValue)) {\n return 'symbol';\n }\n return propType;\n }\n\n // This handles more types than `getPropType`. Only used for error messages.\n // See `createPrimitiveTypeChecker`.\n function getPreciseType(propValue) {\n if (typeof propValue === 'undefined' || propValue === null) {\n return '' + propValue;\n }\n var propType = getPropType(propValue);\n if (propType === 'object') {\n if (propValue instanceof Date) {\n return 'date';\n } else if (propValue instanceof RegExp) {\n return 'regexp';\n }\n }\n return propType;\n }\n\n // Returns a string that is postfixed to a warning about an invalid type.\n // For example, \"undefined\" or \"of type array\"\n function getPostfixForTypeWarning(value) {\n var type = getPreciseType(value);\n switch (type) {\n case 'array':\n case 'object':\n return 'an ' + type;\n case 'boolean':\n case 'date':\n case 'regexp':\n return 'a ' + type;\n default:\n return type;\n }\n }\n\n // Returns class name of the object, if any.\n function getClassName(propValue) {\n if (!propValue.constructor || !propValue.constructor.name) {\n return ANONYMOUS;\n }\n return propValue.constructor.name;\n }\n\n ReactPropTypes.checkPropTypes = checkPropTypes;\n ReactPropTypes.resetWarningCache = checkPropTypes.resetWarningCache;\n ReactPropTypes.PropTypes = ReactPropTypes;\n\n return ReactPropTypes;\n};\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar ReactPropTypesSecret = require('./lib/ReactPropTypesSecret');\n\nfunction emptyFunction() {}\nfunction emptyFunctionWithReset() {}\nemptyFunctionWithReset.resetWarningCache = emptyFunction;\n\nmodule.exports = function() {\n function shim(props, propName, componentName, location, propFullName, secret) {\n if (secret === ReactPropTypesSecret) {\n // It is still safe when called from React.\n return;\n }\n var err = new Error(\n 'Calling PropTypes validators directly is not supported by the `prop-types` package. ' +\n 'Use PropTypes.checkPropTypes() to call them. ' +\n 'Read more at http://fb.me/use-check-prop-types'\n );\n err.name = 'Invariant Violation';\n throw err;\n };\n shim.isRequired = shim;\n function getShim() {\n return shim;\n };\n // Important!\n // Keep this list in sync with production version in `./factoryWithTypeCheckers.js`.\n var ReactPropTypes = {\n array: shim,\n bigint: shim,\n bool: shim,\n func: shim,\n number: shim,\n object: shim,\n string: shim,\n symbol: shim,\n\n any: shim,\n arrayOf: getShim,\n element: shim,\n elementType: shim,\n instanceOf: getShim,\n node: shim,\n objectOf: getShim,\n oneOf: getShim,\n oneOfType: getShim,\n shape: getShim,\n exact: getShim,\n\n checkPropTypes: emptyFunctionWithReset,\n resetWarningCache: emptyFunction\n };\n\n ReactPropTypes.PropTypes = ReactPropTypes;\n\n return ReactPropTypes;\n};\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\nif (process.env.NODE_ENV !== 'production') {\n var ReactIs = require('react-is');\n\n // By explicitly using `prop-types` you are opting into new development behavior.\n // http://fb.me/prop-types-in-prod\n var throwOnDirectAccess = true;\n module.exports = require('./factoryWithTypeCheckers')(ReactIs.isElement, throwOnDirectAccess);\n} else {\n // By explicitly using `prop-types` you are opting into new production behavior.\n // http://fb.me/prop-types-in-prod\n module.exports = require('./factoryWithThrowingShims')();\n}\n","import PropTypes from 'prop-types';\nimport chainPropTypes from '../chainPropTypes';\nfunction isClassComponent(elementType) {\n // elementType.prototype?.isReactComponent\n const {\n prototype = {}\n } = elementType;\n return Boolean(prototype.isReactComponent);\n}\nfunction acceptingRef(props, propName, componentName, location, propFullName) {\n const element = props[propName];\n const safePropName = propFullName || propName;\n if (element == null ||\n // When server-side rendering React doesn't warn either.\n // This is not an accurate check for SSR.\n // This is only in place for Emotion compat.\n // TODO: Revisit once https://github.com/facebook/react/issues/20047 is resolved.\n typeof window === 'undefined') {\n return null;\n }\n let warningHint;\n const elementType = element.type;\n /**\n * Blacklisting instead of whitelisting\n *\n * Blacklisting will miss some components, such as React.Fragment. Those will at least\n * trigger a warning in React.\n * We can't whitelist because there is no safe way to detect React.forwardRef\n * or class components. \"Safe\" means there's no public API.\n *\n */\n if (typeof elementType === 'function' && !isClassComponent(elementType)) {\n warningHint = 'Did you accidentally use a plain function component for an element instead?';\n }\n if (warningHint !== undefined) {\n return new Error(`Invalid ${location} \\`${safePropName}\\` supplied to \\`${componentName}\\`. ` + `Expected an element that can hold a ref. ${warningHint} ` + 'For more information see https://mui.com/r/caveat-with-refs-guide');\n }\n return null;\n}\nconst elementAcceptingRef = chainPropTypes(PropTypes.element, acceptingRef);\nelementAcceptingRef.isRequired = chainPropTypes(PropTypes.element.isRequired, acceptingRef);\nexport default elementAcceptingRef;","import _extends from \"@babel/runtime/helpers/esm/extends\";\n// This module is based on https://github.com/airbnb/prop-types-exact repository.\n// However, in order to reduce the number of dependencies and to remove some extra safe checks\n// the module was forked.\n\nconst specialProperty = 'exact-prop: \\u200b';\nexport default function exactProp(propTypes) {\n if (process.env.NODE_ENV === 'production') {\n return propTypes;\n }\n return _extends({}, propTypes, {\n [specialProperty]: props => {\n const unsupportedProps = Object.keys(props).filter(prop => !propTypes.hasOwnProperty(prop));\n if (unsupportedProps.length > 0) {\n return new Error(`The following props are not supported: ${unsupportedProps.map(prop => `\\`${prop}\\``).join(', ')}. Please remove them.`);\n }\n return null;\n }\n });\n}","/**\n * WARNING: Don't import this directly.\n * Use `MuiError` from `@mui/internal-babel-macros/MuiError.macro` instead.\n * @param {number} code\n */\nexport default function formatMuiErrorMessage(code) {\n // Apply babel-plugin-transform-template-literals in loose mode\n // loose mode is safe if we're concatenating primitives\n // see https://babeljs.io/docs/en/babel-plugin-transform-template-literals#loose\n /* eslint-disable prefer-template */\n let url = 'https://mui.com/production-error/?code=' + code;\n for (let i = 1; i < arguments.length; i += 1) {\n // rest params over-transpile for this case\n // eslint-disable-next-line prefer-rest-params\n url += '&args[]=' + encodeURIComponent(arguments[i]);\n }\n return 'Minified MUI error #' + code + '; visit ' + url + ' for the full message.';\n /* eslint-enable prefer-template */\n}","/**\n * @license React\n * react-is.production.min.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n'use strict';var b=Symbol.for(\"react.element\"),c=Symbol.for(\"react.portal\"),d=Symbol.for(\"react.fragment\"),e=Symbol.for(\"react.strict_mode\"),f=Symbol.for(\"react.profiler\"),g=Symbol.for(\"react.provider\"),h=Symbol.for(\"react.context\"),k=Symbol.for(\"react.server_context\"),l=Symbol.for(\"react.forward_ref\"),m=Symbol.for(\"react.suspense\"),n=Symbol.for(\"react.suspense_list\"),p=Symbol.for(\"react.memo\"),q=Symbol.for(\"react.lazy\"),t=Symbol.for(\"react.offscreen\"),u;u=Symbol.for(\"react.module.reference\");\nfunction v(a){if(\"object\"===typeof a&&null!==a){var r=a.$$typeof;switch(r){case b:switch(a=a.type,a){case d:case f:case e:case m:case n:return a;default:switch(a=a&&a.$$typeof,a){case k:case h:case l:case q:case p:case g:return a;default:return r}}case c:return r}}}exports.ContextConsumer=h;exports.ContextProvider=g;exports.Element=b;exports.ForwardRef=l;exports.Fragment=d;exports.Lazy=q;exports.Memo=p;exports.Portal=c;exports.Profiler=f;exports.StrictMode=e;exports.Suspense=m;\nexports.SuspenseList=n;exports.isAsyncMode=function(){return!1};exports.isConcurrentMode=function(){return!1};exports.isContextConsumer=function(a){return v(a)===h};exports.isContextProvider=function(a){return v(a)===g};exports.isElement=function(a){return\"object\"===typeof a&&null!==a&&a.$$typeof===b};exports.isForwardRef=function(a){return v(a)===l};exports.isFragment=function(a){return v(a)===d};exports.isLazy=function(a){return v(a)===q};exports.isMemo=function(a){return v(a)===p};\nexports.isPortal=function(a){return v(a)===c};exports.isProfiler=function(a){return v(a)===f};exports.isStrictMode=function(a){return v(a)===e};exports.isSuspense=function(a){return v(a)===m};exports.isSuspenseList=function(a){return v(a)===n};\nexports.isValidElementType=function(a){return\"string\"===typeof a||\"function\"===typeof a||a===d||a===f||a===e||a===m||a===n||a===t||\"object\"===typeof a&&null!==a&&(a.$$typeof===q||a.$$typeof===p||a.$$typeof===g||a.$$typeof===h||a.$$typeof===l||a.$$typeof===u||void 0!==a.getModuleId)?!0:!1};exports.typeOf=v;\n","/**\n * @license React\n * react-is.development.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nif (process.env.NODE_ENV !== \"production\") {\n (function() {\n'use strict';\n\n// ATTENTION\n// When adding new symbols to this file,\n// Please consider also adding to 'react-devtools-shared/src/backend/ReactSymbols'\n// The Symbol used to tag the ReactElement-like types.\nvar REACT_ELEMENT_TYPE = Symbol.for('react.element');\nvar REACT_PORTAL_TYPE = Symbol.for('react.portal');\nvar REACT_FRAGMENT_TYPE = Symbol.for('react.fragment');\nvar REACT_STRICT_MODE_TYPE = Symbol.for('react.strict_mode');\nvar REACT_PROFILER_TYPE = Symbol.for('react.profiler');\nvar REACT_PROVIDER_TYPE = Symbol.for('react.provider');\nvar REACT_CONTEXT_TYPE = Symbol.for('react.context');\nvar REACT_SERVER_CONTEXT_TYPE = Symbol.for('react.server_context');\nvar REACT_FORWARD_REF_TYPE = Symbol.for('react.forward_ref');\nvar REACT_SUSPENSE_TYPE = Symbol.for('react.suspense');\nvar REACT_SUSPENSE_LIST_TYPE = Symbol.for('react.suspense_list');\nvar REACT_MEMO_TYPE = Symbol.for('react.memo');\nvar REACT_LAZY_TYPE = Symbol.for('react.lazy');\nvar REACT_OFFSCREEN_TYPE = Symbol.for('react.offscreen');\n\n// -----------------------------------------------------------------------------\n\nvar enableScopeAPI = false; // Experimental Create Event Handle API.\nvar enableCacheElement = false;\nvar enableTransitionTracing = false; // No known bugs, but needs performance testing\n\nvar enableLegacyHidden = false; // Enables unstable_avoidThisFallback feature in Fiber\n// stuff. Intended to enable React core members to more easily debug scheduling\n// issues in DEV builds.\n\nvar enableDebugTracing = false; // Track which Fiber(s) schedule render work.\n\nvar REACT_MODULE_REFERENCE;\n\n{\n REACT_MODULE_REFERENCE = Symbol.for('react.module.reference');\n}\n\nfunction isValidElementType(type) {\n if (typeof type === 'string' || typeof type === 'function') {\n return true;\n } // Note: typeof might be other than 'symbol' or 'number' (e.g. if it's a polyfill).\n\n\n if (type === REACT_FRAGMENT_TYPE || type === REACT_PROFILER_TYPE || enableDebugTracing || type === REACT_STRICT_MODE_TYPE || type === REACT_SUSPENSE_TYPE || type === REACT_SUSPENSE_LIST_TYPE || enableLegacyHidden || type === REACT_OFFSCREEN_TYPE || enableScopeAPI || enableCacheElement || enableTransitionTracing ) {\n return true;\n }\n\n if (typeof type === 'object' && type !== null) {\n if (type.$$typeof === REACT_LAZY_TYPE || type.$$typeof === REACT_MEMO_TYPE || type.$$typeof === REACT_PROVIDER_TYPE || type.$$typeof === REACT_CONTEXT_TYPE || type.$$typeof === REACT_FORWARD_REF_TYPE || // This needs to include all possible module reference object\n // types supported by any Flight configuration anywhere since\n // we don't know which Flight build this will end up being used\n // with.\n type.$$typeof === REACT_MODULE_REFERENCE || type.getModuleId !== undefined) {\n return true;\n }\n }\n\n return false;\n}\n\nfunction typeOf(object) {\n if (typeof object === 'object' && object !== null) {\n var $$typeof = object.$$typeof;\n\n switch ($$typeof) {\n case REACT_ELEMENT_TYPE:\n var type = object.type;\n\n switch (type) {\n case REACT_FRAGMENT_TYPE:\n case REACT_PROFILER_TYPE:\n case REACT_STRICT_MODE_TYPE:\n case REACT_SUSPENSE_TYPE:\n case REACT_SUSPENSE_LIST_TYPE:\n return type;\n\n default:\n var $$typeofType = type && type.$$typeof;\n\n switch ($$typeofType) {\n case REACT_SERVER_CONTEXT_TYPE:\n case REACT_CONTEXT_TYPE:\n case REACT_FORWARD_REF_TYPE:\n case REACT_LAZY_TYPE:\n case REACT_MEMO_TYPE:\n case REACT_PROVIDER_TYPE:\n return $$typeofType;\n\n default:\n return $$typeof;\n }\n\n }\n\n case REACT_PORTAL_TYPE:\n return $$typeof;\n }\n }\n\n return undefined;\n}\nvar ContextConsumer = REACT_CONTEXT_TYPE;\nvar ContextProvider = REACT_PROVIDER_TYPE;\nvar Element = REACT_ELEMENT_TYPE;\nvar ForwardRef = REACT_FORWARD_REF_TYPE;\nvar Fragment = REACT_FRAGMENT_TYPE;\nvar Lazy = REACT_LAZY_TYPE;\nvar Memo = REACT_MEMO_TYPE;\nvar Portal = REACT_PORTAL_TYPE;\nvar Profiler = REACT_PROFILER_TYPE;\nvar StrictMode = REACT_STRICT_MODE_TYPE;\nvar Suspense = REACT_SUSPENSE_TYPE;\nvar SuspenseList = REACT_SUSPENSE_LIST_TYPE;\nvar hasWarnedAboutDeprecatedIsAsyncMode = false;\nvar hasWarnedAboutDeprecatedIsConcurrentMode = false; // AsyncMode should be deprecated\n\nfunction isAsyncMode(object) {\n {\n if (!hasWarnedAboutDeprecatedIsAsyncMode) {\n hasWarnedAboutDeprecatedIsAsyncMode = true; // Using console['warn'] to evade Babel and ESLint\n\n console['warn']('The ReactIs.isAsyncMode() alias has been deprecated, ' + 'and will be removed in React 18+.');\n }\n }\n\n return false;\n}\nfunction isConcurrentMode(object) {\n {\n if (!hasWarnedAboutDeprecatedIsConcurrentMode) {\n hasWarnedAboutDeprecatedIsConcurrentMode = true; // Using console['warn'] to evade Babel and ESLint\n\n console['warn']('The ReactIs.isConcurrentMode() alias has been deprecated, ' + 'and will be removed in React 18+.');\n }\n }\n\n return false;\n}\nfunction isContextConsumer(object) {\n return typeOf(object) === REACT_CONTEXT_TYPE;\n}\nfunction isContextProvider(object) {\n return typeOf(object) === REACT_PROVIDER_TYPE;\n}\nfunction isElement(object) {\n return typeof object === 'object' && object !== null && object.$$typeof === REACT_ELEMENT_TYPE;\n}\nfunction isForwardRef(object) {\n return typeOf(object) === REACT_FORWARD_REF_TYPE;\n}\nfunction isFragment(object) {\n return typeOf(object) === REACT_FRAGMENT_TYPE;\n}\nfunction isLazy(object) {\n return typeOf(object) === REACT_LAZY_TYPE;\n}\nfunction isMemo(object) {\n return typeOf(object) === REACT_MEMO_TYPE;\n}\nfunction isPortal(object) {\n return typeOf(object) === REACT_PORTAL_TYPE;\n}\nfunction isProfiler(object) {\n return typeOf(object) === REACT_PROFILER_TYPE;\n}\nfunction isStrictMode(object) {\n return typeOf(object) === REACT_STRICT_MODE_TYPE;\n}\nfunction isSuspense(object) {\n return typeOf(object) === REACT_SUSPENSE_TYPE;\n}\nfunction isSuspenseList(object) {\n return typeOf(object) === REACT_SUSPENSE_LIST_TYPE;\n}\n\nexports.ContextConsumer = ContextConsumer;\nexports.ContextProvider = ContextProvider;\nexports.Element = Element;\nexports.ForwardRef = ForwardRef;\nexports.Fragment = Fragment;\nexports.Lazy = Lazy;\nexports.Memo = Memo;\nexports.Portal = Portal;\nexports.Profiler = Profiler;\nexports.StrictMode = StrictMode;\nexports.Suspense = Suspense;\nexports.SuspenseList = SuspenseList;\nexports.isAsyncMode = isAsyncMode;\nexports.isConcurrentMode = isConcurrentMode;\nexports.isContextConsumer = isContextConsumer;\nexports.isContextProvider = isContextProvider;\nexports.isElement = isElement;\nexports.isForwardRef = isForwardRef;\nexports.isFragment = isFragment;\nexports.isLazy = isLazy;\nexports.isMemo = isMemo;\nexports.isPortal = isPortal;\nexports.isProfiler = isProfiler;\nexports.isStrictMode = isStrictMode;\nexports.isSuspense = isSuspense;\nexports.isSuspenseList = isSuspenseList;\nexports.isValidElementType = isValidElementType;\nexports.typeOf = typeOf;\n })();\n}\n","'use strict';\n\nif (process.env.NODE_ENV === 'production') {\n module.exports = require('./cjs/react-is.production.min.js');\n} else {\n module.exports = require('./cjs/react-is.development.js');\n}\n","import { ForwardRef, Memo } from 'react-is';\n\n// Simplified polyfill for IE11 support\n// https://github.com/JamesMGreene/Function.name/blob/58b314d4a983110c3682f1228f845d39ccca1817/Function.name.js#L3\nconst fnNameMatchRegex = /^\\s*function(?:\\s|\\s*\\/\\*.*\\*\\/\\s*)+([^(\\s/]*)\\s*/;\nexport function getFunctionName(fn) {\n const match = `${fn}`.match(fnNameMatchRegex);\n const name = match && match[1];\n return name || '';\n}\nfunction getFunctionComponentName(Component, fallback = '') {\n return Component.displayName || Component.name || getFunctionName(Component) || fallback;\n}\nfunction getWrappedName(outerType, innerType, wrapperName) {\n const functionName = getFunctionComponentName(innerType);\n return outerType.displayName || (functionName !== '' ? `${wrapperName}(${functionName})` : wrapperName);\n}\n\n/**\n * cherry-pick from\n * https://github.com/facebook/react/blob/769b1f270e1251d9dbdce0fcbd9e92e502d059b8/packages/shared/getComponentName.js\n * originally forked from recompose/getDisplayName with added IE11 support\n */\nexport default function getDisplayName(Component) {\n if (Component == null) {\n return undefined;\n }\n if (typeof Component === 'string') {\n return Component;\n }\n if (typeof Component === 'function') {\n return getFunctionComponentName(Component, 'Component');\n }\n\n // TypeScript can't have components as objects but they exist in the form of `memo` or `Suspense`\n if (typeof Component === 'object') {\n switch (Component.$$typeof) {\n case ForwardRef:\n return getWrappedName(Component, Component.render, 'ForwardRef');\n case Memo:\n return getWrappedName(Component, Component.type, 'memo');\n default:\n return undefined;\n }\n }\n return undefined;\n}","export default function HTMLElementType(props, propName, componentName, location, propFullName) {\n if (process.env.NODE_ENV === 'production') {\n return null;\n }\n const propValue = props[propName];\n const safePropName = propFullName || propName;\n if (propValue == null) {\n return null;\n }\n if (propValue && propValue.nodeType !== 1) {\n return new Error(`Invalid ${location} \\`${safePropName}\\` supplied to \\`${componentName}\\`. ` + `Expected an HTMLElement.`);\n }\n return null;\n}","import PropTypes from 'prop-types';\nconst refType = PropTypes.oneOfType([PropTypes.func, PropTypes.object]);\nexport default refType;","import _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\n// It should to be noted that this function isn't equivalent to `text-transform: capitalize`.\n//\n// A strict capitalization should uppercase the first letter of each word in the sentence.\n// We only handle the first word.\nexport default function capitalize(string) {\n if (typeof string !== 'string') {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: \\`capitalize(string)\\` expects a string argument.` : _formatMuiErrorMessage(7));\n }\n return string.charAt(0).toUpperCase() + string.slice(1);\n}","/**\n * Safe chained function.\n *\n * Will only create a new function if needed,\n * otherwise will pass back existing functions or null.\n */\nexport default function createChainedFunction(...funcs) {\n return funcs.reduce((acc, func) => {\n if (func == null) {\n return acc;\n }\n return function chainedFunction(...args) {\n acc.apply(this, args);\n func.apply(this, args);\n };\n }, () => {});\n}","// Corresponds to 10 frames at 60 Hz.\n// A few bytes payload overhead when lodash/debounce is ~3 kB and debounce ~300 B.\nexport default function debounce(func, wait = 166) {\n let timeout;\n function debounced(...args) {\n const later = () => {\n // @ts-ignore\n func.apply(this, args);\n };\n clearTimeout(timeout);\n timeout = setTimeout(later, wait);\n }\n debounced.clear = () => {\n clearTimeout(timeout);\n };\n return debounced;\n}","export default function deprecatedPropType(validator, reason) {\n if (process.env.NODE_ENV === 'production') {\n return () => null;\n }\n return (props, propName, componentName, location, propFullName) => {\n const componentNameSafe = componentName || '<>';\n const propFullNameSafe = propFullName || propName;\n if (typeof props[propName] !== 'undefined') {\n return new Error(`The ${location} \\`${propFullNameSafe}\\` of ` + `\\`${componentNameSafe}\\` is deprecated. ${reason}`);\n }\n return null;\n };\n}","import * as React from 'react';\nexport default function isMuiElement(element, muiNames) {\n var _muiName, _element$type;\n return /*#__PURE__*/React.isValidElement(element) && muiNames.indexOf( // For server components `muiName` is avaialble in element.type._payload.value.muiName\n // relevant info - https://github.com/facebook/react/blob/2807d781a08db8e9873687fccc25c0f12b4fb3d4/packages/react/src/ReactLazy.js#L45\n // eslint-disable-next-line no-underscore-dangle\n (_muiName = element.type.muiName) != null ? _muiName : (_element$type = element.type) == null || (_element$type = _element$type._payload) == null || (_element$type = _element$type.value) == null ? void 0 : _element$type.muiName) !== -1;\n}","export default function ownerDocument(node) {\n return node && node.ownerDocument || document;\n}","import ownerDocument from '../ownerDocument';\nexport default function ownerWindow(node) {\n const doc = ownerDocument(node);\n return doc.defaultView || window;\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nexport default function requirePropFactory(componentNameInError, Component) {\n if (process.env.NODE_ENV === 'production') {\n return () => null;\n }\n\n // eslint-disable-next-line react/forbid-foreign-prop-types\n const prevPropTypes = Component ? _extends({}, Component.propTypes) : null;\n const requireProp = requiredProp => (props, propName, componentName, location, propFullName, ...args) => {\n const propFullNameSafe = propFullName || propName;\n const defaultTypeChecker = prevPropTypes == null ? void 0 : prevPropTypes[propFullNameSafe];\n if (defaultTypeChecker) {\n const typeCheckerResult = defaultTypeChecker(props, propName, componentName, location, propFullName, ...args);\n if (typeCheckerResult) {\n return typeCheckerResult;\n }\n }\n if (typeof props[propName] !== 'undefined' && !props[requiredProp]) {\n return new Error(`The prop \\`${propFullNameSafe}\\` of ` + `\\`${componentNameInError}\\` can only be used together with the \\`${requiredProp}\\` prop.`);\n }\n return null;\n };\n return requireProp;\n}","/**\n * TODO v5: consider making it private\n *\n * passes {value} to {ref}\n *\n * WARNING: Be sure to only call this inside a callback that is passed as a ref.\n * Otherwise, make sure to cleanup the previous {ref} if it changes. See\n * https://github.com/mui/material-ui/issues/13539\n *\n * Useful if you want to expose the ref of an inner component to the public API\n * while still using it inside the component.\n * @param ref A ref callback or ref object. If anything falsy, this is a no-op.\n */\nexport default function setRef(ref, value) {\n if (typeof ref === 'function') {\n ref(value);\n } else if (ref) {\n ref.current = value;\n }\n}","'use client';\n\nimport * as React from 'react';\n\n/**\n * A version of `React.useLayoutEffect` that does not show a warning when server-side rendering.\n * This is useful for effects that are only needed for client-side rendering but not for SSR.\n *\n * Before you use this hook, make sure to read https://gist.github.com/gaearon/e7d97cdf38a2907924ea12e4ebdf3c85\n * and confirm it doesn't apply to your use-case.\n */\nconst useEnhancedEffect = typeof window !== 'undefined' ? React.useLayoutEffect : React.useEffect;\nexport default useEnhancedEffect;","'use client';\n\nimport * as React from 'react';\nlet globalId = 0;\nfunction useGlobalId(idOverride) {\n const [defaultId, setDefaultId] = React.useState(idOverride);\n const id = idOverride || defaultId;\n React.useEffect(() => {\n if (defaultId == null) {\n // Fallback to this default id when possible.\n // Use the incrementing value for client-side rendering only.\n // We can't use it server-side.\n // If you want to use random values please consider the Birthday Problem: https://en.wikipedia.org/wiki/Birthday_problem\n globalId += 1;\n setDefaultId(`mui-${globalId}`);\n }\n }, [defaultId]);\n return id;\n}\n\n// downstream bundlers may remove unnecessary concatenation, but won't remove toString call -- Workaround for https://github.com/webpack/webpack/issues/14814\nconst maybeReactUseId = React['useId'.toString()];\n/**\n *\n * @example
    \n * @param idOverride\n * @returns {string}\n */\nexport default function useId(idOverride) {\n if (maybeReactUseId !== undefined) {\n const reactId = maybeReactUseId();\n return idOverride != null ? idOverride : reactId;\n }\n // eslint-disable-next-line react-hooks/rules-of-hooks -- `React.useId` is invariant at runtime.\n return useGlobalId(idOverride);\n}","export default function unsupportedProp(props, propName, componentName, location, propFullName) {\n if (process.env.NODE_ENV === 'production') {\n return null;\n }\n const propFullNameSafe = propFullName || propName;\n if (typeof props[propName] !== 'undefined') {\n return new Error(`The prop \\`${propFullNameSafe}\\` is not supported. Please remove it.`);\n }\n return null;\n}","'use client';\n\n/* eslint-disable react-hooks/rules-of-hooks, react-hooks/exhaustive-deps */\nimport * as React from 'react';\nexport default function useControlled({\n controlled,\n default: defaultProp,\n name,\n state = 'value'\n}) {\n // isControlled is ignored in the hook dependency lists as it should never change.\n const {\n current: isControlled\n } = React.useRef(controlled !== undefined);\n const [valueState, setValue] = React.useState(defaultProp);\n const value = isControlled ? controlled : valueState;\n if (process.env.NODE_ENV !== 'production') {\n React.useEffect(() => {\n if (isControlled !== (controlled !== undefined)) {\n console.error([`MUI: A component is changing the ${isControlled ? '' : 'un'}controlled ${state} state of ${name} to be ${isControlled ? 'un' : ''}controlled.`, 'Elements should not switch from uncontrolled to controlled (or vice versa).', `Decide between using a controlled or uncontrolled ${name} ` + 'element for the lifetime of the component.', \"The nature of the state is determined during the first render. It's considered controlled if the value is not `undefined`.\", 'More info: https://fb.me/react-controlled-components'].join('\\n'));\n }\n }, [state, name, controlled]);\n const {\n current: defaultValue\n } = React.useRef(defaultProp);\n React.useEffect(() => {\n if (!isControlled && defaultValue !== defaultProp) {\n console.error([`MUI: A component is changing the default ${state} state of an uncontrolled ${name} after being initialized. ` + `To suppress this warning opt to use a controlled ${name}.`].join('\\n'));\n }\n }, [JSON.stringify(defaultProp)]);\n }\n const setValueIfUncontrolled = React.useCallback(newValue => {\n if (!isControlled) {\n setValue(newValue);\n }\n }, []);\n return [value, setValueIfUncontrolled];\n}","'use client';\n\nimport * as React from 'react';\nimport useEnhancedEffect from '../useEnhancedEffect';\n\n/**\n * Inspired by https://github.com/facebook/react/issues/14099#issuecomment-440013892\n * See RFC in https://github.com/reactjs/rfcs/pull/220\n */\n\nfunction useEventCallback(fn) {\n const ref = React.useRef(fn);\n useEnhancedEffect(() => {\n ref.current = fn;\n });\n return React.useRef((...args) =>\n // @ts-expect-error hide `this`\n (0, ref.current)(...args)).current;\n}\nexport default useEventCallback;","'use client';\n\nimport * as React from 'react';\nimport setRef from '../setRef';\nexport default function useForkRef(...refs) {\n /**\n * This will create a new function if the refs passed to this hook change and are all defined.\n * This means react will call the old forkRef with `null` and the new forkRef\n * with the ref. Cleanup naturally emerges from this behavior.\n */\n return React.useMemo(() => {\n if (refs.every(ref => ref == null)) {\n return null;\n }\n return instance => {\n refs.forEach(ref => {\n setRef(ref, instance);\n });\n };\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, refs);\n}","'use client';\n\nimport * as React from 'react';\nconst UNINITIALIZED = {};\n\n/**\n * A React.useRef() that is initialized lazily with a function. Note that it accepts an optional\n * initialization argument, so the initialization function doesn't need to be an inline closure.\n *\n * @usage\n * const ref = useLazyRef(sortColumns, columns)\n */\nexport default function useLazyRef(init, initArg) {\n const ref = React.useRef(UNINITIALIZED);\n if (ref.current === UNINITIALIZED) {\n ref.current = init(initArg);\n }\n return ref;\n}","'use client';\n\nimport * as React from 'react';\nconst EMPTY = [];\n\n/**\n * A React.useEffect equivalent that runs once, when the component is mounted.\n */\nexport default function useOnMount(fn) {\n /* eslint-disable react-hooks/exhaustive-deps */\n React.useEffect(fn, EMPTY);\n /* eslint-enable react-hooks/exhaustive-deps */\n}","'use client';\n\nimport useLazyRef from '../useLazyRef/useLazyRef';\nimport useOnMount from '../useOnMount/useOnMount';\nexport class Timeout {\n constructor() {\n this.currentId = null;\n this.clear = () => {\n if (this.currentId !== null) {\n clearTimeout(this.currentId);\n this.currentId = null;\n }\n };\n this.disposeEffect = () => {\n return this.clear;\n };\n }\n static create() {\n return new Timeout();\n }\n /**\n * Executes `fn` after `delay`, clearing any previously scheduled call.\n */\n start(delay, fn) {\n this.clear();\n this.currentId = setTimeout(() => {\n this.currentId = null;\n fn();\n }, delay);\n }\n}\nexport default function useTimeout() {\n const timeout = useLazyRef(Timeout.create).current;\n useOnMount(timeout.disposeEffect);\n return timeout;\n}","'use client';\n\n// based on https://github.com/WICG/focus-visible/blob/v4.1.5/src/focus-visible.js\nimport * as React from 'react';\nimport { Timeout } from '../useTimeout/useTimeout';\nlet hadKeyboardEvent = true;\nlet hadFocusVisibleRecently = false;\nconst hadFocusVisibleRecentlyTimeout = new Timeout();\nconst inputTypesWhitelist = {\n text: true,\n search: true,\n url: true,\n tel: true,\n email: true,\n password: true,\n number: true,\n date: true,\n month: true,\n week: true,\n time: true,\n datetime: true,\n 'datetime-local': true\n};\n\n/**\n * Computes whether the given element should automatically trigger the\n * `focus-visible` class being added, i.e. whether it should always match\n * `:focus-visible` when focused.\n * @param {Element} node\n * @returns {boolean}\n */\nfunction focusTriggersKeyboardModality(node) {\n const {\n type,\n tagName\n } = node;\n if (tagName === 'INPUT' && inputTypesWhitelist[type] && !node.readOnly) {\n return true;\n }\n if (tagName === 'TEXTAREA' && !node.readOnly) {\n return true;\n }\n if (node.isContentEditable) {\n return true;\n }\n return false;\n}\n\n/**\n * Keep track of our keyboard modality state with `hadKeyboardEvent`.\n * If the most recent user interaction was via the keyboard;\n * and the key press did not include a meta, alt/option, or control key;\n * then the modality is keyboard. Otherwise, the modality is not keyboard.\n * @param {KeyboardEvent} event\n */\nfunction handleKeyDown(event) {\n if (event.metaKey || event.altKey || event.ctrlKey) {\n return;\n }\n hadKeyboardEvent = true;\n}\n\n/**\n * If at any point a user clicks with a pointing device, ensure that we change\n * the modality away from keyboard.\n * This avoids the situation where a user presses a key on an already focused\n * element, and then clicks on a different element, focusing it with a\n * pointing device, while we still think we're in keyboard modality.\n */\nfunction handlePointerDown() {\n hadKeyboardEvent = false;\n}\nfunction handleVisibilityChange() {\n if (this.visibilityState === 'hidden') {\n // If the tab becomes active again, the browser will handle calling focus\n // on the element (Safari actually calls it twice).\n // If this tab change caused a blur on an element with focus-visible,\n // re-apply the class when the user switches back to the tab.\n if (hadFocusVisibleRecently) {\n hadKeyboardEvent = true;\n }\n }\n}\nfunction prepare(doc) {\n doc.addEventListener('keydown', handleKeyDown, true);\n doc.addEventListener('mousedown', handlePointerDown, true);\n doc.addEventListener('pointerdown', handlePointerDown, true);\n doc.addEventListener('touchstart', handlePointerDown, true);\n doc.addEventListener('visibilitychange', handleVisibilityChange, true);\n}\nexport function teardown(doc) {\n doc.removeEventListener('keydown', handleKeyDown, true);\n doc.removeEventListener('mousedown', handlePointerDown, true);\n doc.removeEventListener('pointerdown', handlePointerDown, true);\n doc.removeEventListener('touchstart', handlePointerDown, true);\n doc.removeEventListener('visibilitychange', handleVisibilityChange, true);\n}\nfunction isFocusVisible(event) {\n const {\n target\n } = event;\n try {\n return target.matches(':focus-visible');\n } catch (error) {\n // Browsers not implementing :focus-visible will throw a SyntaxError.\n // We use our own heuristic for those browsers.\n // Rethrow might be better if it's not the expected error but do we really\n // want to crash if focus-visible malfunctioned?\n }\n\n // No need for validFocusTarget check. The user does that by attaching it to\n // focusable events only.\n return hadKeyboardEvent || focusTriggersKeyboardModality(target);\n}\nexport default function useIsFocusVisible() {\n const ref = React.useCallback(node => {\n if (node != null) {\n prepare(node.ownerDocument);\n }\n }, []);\n const isFocusVisibleRef = React.useRef(false);\n\n /**\n * Should be called if a blur event is fired\n */\n function handleBlurVisible() {\n // checking against potential state variable does not suffice if we focus and blur synchronously.\n // React wouldn't have time to trigger a re-render so `focusVisible` would be stale.\n // Ideally we would adjust `isFocusVisible(event)` to look at `relatedTarget` for blur events.\n // This doesn't work in IE11 due to https://github.com/facebook/react/issues/3751\n // TODO: check again if React releases their internal changes to focus event handling (https://github.com/facebook/react/pull/19186).\n if (isFocusVisibleRef.current) {\n // To detect a tab/window switch, we look for a blur event followed\n // rapidly by a visibility change.\n // If we don't see a visibility change within 100ms, it's probably a\n // regular focus change.\n hadFocusVisibleRecently = true;\n hadFocusVisibleRecentlyTimeout.start(100, () => {\n hadFocusVisibleRecently = false;\n });\n isFocusVisibleRef.current = false;\n return true;\n }\n return false;\n }\n\n /**\n * Should be called if a blur event is fired\n */\n function handleFocusVisible(event) {\n if (isFocusVisible(event)) {\n isFocusVisibleRef.current = true;\n return true;\n }\n return false;\n }\n return {\n isFocusVisibleRef,\n onFocus: handleFocusVisible,\n onBlur: handleBlurVisible,\n ref\n };\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\n/**\n * Add keys, values of `defaultProps` that does not exist in `props`\n * @param {object} defaultProps\n * @param {object} props\n * @returns {object} resolved props\n */\nexport default function resolveProps(defaultProps, props) {\n const output = _extends({}, props);\n Object.keys(defaultProps).forEach(propName => {\n if (propName.toString().match(/^(components|slots)$/)) {\n output[propName] = _extends({}, defaultProps[propName], output[propName]);\n } else if (propName.toString().match(/^(componentsProps|slotProps)$/)) {\n const defaultSlotProps = defaultProps[propName] || {};\n const slotProps = props[propName];\n output[propName] = {};\n if (!slotProps || !Object.keys(slotProps)) {\n // Reduce the iteration if the slot props is empty\n output[propName] = defaultSlotProps;\n } else if (!defaultSlotProps || !Object.keys(defaultSlotProps)) {\n // Reduce the iteration if the default slot props is empty\n output[propName] = slotProps;\n } else {\n output[propName] = _extends({}, slotProps);\n Object.keys(defaultSlotProps).forEach(slotPropName => {\n output[propName][slotPropName] = resolveProps(defaultSlotProps[slotPropName], slotProps[slotPropName]);\n });\n }\n } else if (output[propName] === undefined) {\n output[propName] = defaultProps[propName];\n }\n });\n return output;\n}","export default function composeClasses(slots, getUtilityClass, classes = undefined) {\n const output = {};\n Object.keys(slots).forEach(\n // `Object.keys(slots)` can't be wider than `T` because we infer `T` from `slots`.\n // @ts-expect-error https://github.com/microsoft/TypeScript/pull/12253#issuecomment-263132208\n slot => {\n output[slot] = slots[slot].reduce((acc, key) => {\n if (key) {\n const utilityClass = getUtilityClass(key);\n if (utilityClass !== '') {\n acc.push(utilityClass);\n }\n if (classes && classes[key]) {\n acc.push(classes[key]);\n }\n }\n return acc;\n }, []).join(' ');\n });\n return output;\n}","const defaultGenerator = componentName => componentName;\nconst createClassNameGenerator = () => {\n let generate = defaultGenerator;\n return {\n configure(generator) {\n generate = generator;\n },\n generate(componentName) {\n return generate(componentName);\n },\n reset() {\n generate = defaultGenerator;\n }\n };\n};\nconst ClassNameGenerator = createClassNameGenerator();\nexport default ClassNameGenerator;","import ClassNameGenerator from '../ClassNameGenerator';\nexport const globalStateClasses = {\n active: 'active',\n checked: 'checked',\n completed: 'completed',\n disabled: 'disabled',\n error: 'error',\n expanded: 'expanded',\n focused: 'focused',\n focusVisible: 'focusVisible',\n open: 'open',\n readOnly: 'readOnly',\n required: 'required',\n selected: 'selected'\n};\nexport default function generateUtilityClass(componentName, slot, globalStatePrefix = 'Mui') {\n const globalStateClass = globalStateClasses[slot];\n return globalStateClass ? `${globalStatePrefix}-${globalStateClass}` : `${ClassNameGenerator.generate(componentName)}-${slot}`;\n}\nexport function isGlobalState(slot) {\n return globalStateClasses[slot] !== undefined;\n}","import generateUtilityClass from '../generateUtilityClass';\nexport default function generateUtilityClasses(componentName, slots, globalStatePrefix = 'Mui') {\n const result = {};\n slots.forEach(slot => {\n result[slot] = generateUtilityClass(componentName, slot, globalStatePrefix);\n });\n return result;\n}","function clamp(val, min = Number.MIN_SAFE_INTEGER, max = Number.MAX_SAFE_INTEGER) {\n return Math.max(min, Math.min(val, max));\n}\nexport default clamp;","export default function _objectWithoutPropertiesLoose(source, excluded) {\n if (source == null) return {};\n var target = {};\n var sourceKeys = Object.keys(source);\n var key, i;\n for (i = 0; i < sourceKeys.length; i++) {\n key = sourceKeys[i];\n if (excluded.indexOf(key) >= 0) continue;\n target[key] = source[key];\n }\n return target;\n}","import _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nconst _excluded = [\"values\", \"unit\", \"step\"];\n// Sorted ASC by size. That's important.\n// It can't be configured as it's used statically for propTypes.\nexport const breakpointKeys = ['xs', 'sm', 'md', 'lg', 'xl'];\nconst sortBreakpointsValues = values => {\n const breakpointsAsArray = Object.keys(values).map(key => ({\n key,\n val: values[key]\n })) || [];\n // Sort in ascending order\n breakpointsAsArray.sort((breakpoint1, breakpoint2) => breakpoint1.val - breakpoint2.val);\n return breakpointsAsArray.reduce((acc, obj) => {\n return _extends({}, acc, {\n [obj.key]: obj.val\n });\n }, {});\n};\n\n// Keep in mind that @media is inclusive by the CSS specification.\nexport default function createBreakpoints(breakpoints) {\n const {\n // The breakpoint **start** at this value.\n // For instance with the first breakpoint xs: [xs, sm).\n values = {\n xs: 0,\n // phone\n sm: 600,\n // tablet\n md: 900,\n // small laptop\n lg: 1200,\n // desktop\n xl: 1536 // large screen\n },\n unit = 'px',\n step = 5\n } = breakpoints,\n other = _objectWithoutPropertiesLoose(breakpoints, _excluded);\n const sortedValues = sortBreakpointsValues(values);\n const keys = Object.keys(sortedValues);\n function up(key) {\n const value = typeof values[key] === 'number' ? values[key] : key;\n return `@media (min-width:${value}${unit})`;\n }\n function down(key) {\n const value = typeof values[key] === 'number' ? values[key] : key;\n return `@media (max-width:${value - step / 100}${unit})`;\n }\n function between(start, end) {\n const endIndex = keys.indexOf(end);\n return `@media (min-width:${typeof values[start] === 'number' ? values[start] : start}${unit}) and ` + `(max-width:${(endIndex !== -1 && typeof values[keys[endIndex]] === 'number' ? values[keys[endIndex]] : end) - step / 100}${unit})`;\n }\n function only(key) {\n if (keys.indexOf(key) + 1 < keys.length) {\n return between(key, keys[keys.indexOf(key) + 1]);\n }\n return up(key);\n }\n function not(key) {\n // handle first and last key separately, for better readability\n const keyIndex = keys.indexOf(key);\n if (keyIndex === 0) {\n return up(keys[1]);\n }\n if (keyIndex === keys.length - 1) {\n return down(keys[keyIndex]);\n }\n return between(key, keys[keys.indexOf(key) + 1]).replace('@media', '@media not all and');\n }\n return _extends({\n keys,\n values: sortedValues,\n up,\n down,\n between,\n only,\n not,\n unit\n }, other);\n}","const shape = {\n borderRadius: 4\n};\nexport default shape;","import PropTypes from 'prop-types';\nconst responsivePropType = process.env.NODE_ENV !== 'production' ? PropTypes.oneOfType([PropTypes.number, PropTypes.string, PropTypes.object, PropTypes.array]) : {};\nexport default responsivePropType;","import deepmerge from '@mui/utils/deepmerge';\nfunction merge(acc, item) {\n if (!item) {\n return acc;\n }\n return deepmerge(acc, item, {\n clone: false // No need to clone deep, it's way faster.\n });\n}\nexport default merge;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport PropTypes from 'prop-types';\nimport deepmerge from '@mui/utils/deepmerge';\nimport merge from './merge';\n\n// The breakpoint **start** at this value.\n// For instance with the first breakpoint xs: [xs, sm[.\nexport const values = {\n xs: 0,\n // phone\n sm: 600,\n // tablet\n md: 900,\n // small laptop\n lg: 1200,\n // desktop\n xl: 1536 // large screen\n};\nconst defaultBreakpoints = {\n // Sorted ASC by size. That's important.\n // It can't be configured as it's used statically for propTypes.\n keys: ['xs', 'sm', 'md', 'lg', 'xl'],\n up: key => `@media (min-width:${values[key]}px)`\n};\nexport function handleBreakpoints(props, propValue, styleFromPropValue) {\n const theme = props.theme || {};\n if (Array.isArray(propValue)) {\n const themeBreakpoints = theme.breakpoints || defaultBreakpoints;\n return propValue.reduce((acc, item, index) => {\n acc[themeBreakpoints.up(themeBreakpoints.keys[index])] = styleFromPropValue(propValue[index]);\n return acc;\n }, {});\n }\n if (typeof propValue === 'object') {\n const themeBreakpoints = theme.breakpoints || defaultBreakpoints;\n return Object.keys(propValue).reduce((acc, breakpoint) => {\n // key is breakpoint\n if (Object.keys(themeBreakpoints.values || values).indexOf(breakpoint) !== -1) {\n const mediaKey = themeBreakpoints.up(breakpoint);\n acc[mediaKey] = styleFromPropValue(propValue[breakpoint], breakpoint);\n } else {\n const cssKey = breakpoint;\n acc[cssKey] = propValue[cssKey];\n }\n return acc;\n }, {});\n }\n const output = styleFromPropValue(propValue);\n return output;\n}\nfunction breakpoints(styleFunction) {\n // false positive\n // eslint-disable-next-line react/function-component-definition\n const newStyleFunction = props => {\n const theme = props.theme || {};\n const base = styleFunction(props);\n const themeBreakpoints = theme.breakpoints || defaultBreakpoints;\n const extended = themeBreakpoints.keys.reduce((acc, key) => {\n if (props[key]) {\n acc = acc || {};\n acc[themeBreakpoints.up(key)] = styleFunction(_extends({\n theme\n }, props[key]));\n }\n return acc;\n }, null);\n return merge(base, extended);\n };\n newStyleFunction.propTypes = process.env.NODE_ENV !== 'production' ? _extends({}, styleFunction.propTypes, {\n xs: PropTypes.object,\n sm: PropTypes.object,\n md: PropTypes.object,\n lg: PropTypes.object,\n xl: PropTypes.object\n }) : {};\n newStyleFunction.filterProps = ['xs', 'sm', 'md', 'lg', 'xl', ...styleFunction.filterProps];\n return newStyleFunction;\n}\nexport function createEmptyBreakpointObject(breakpointsInput = {}) {\n var _breakpointsInput$key;\n const breakpointsInOrder = (_breakpointsInput$key = breakpointsInput.keys) == null ? void 0 : _breakpointsInput$key.reduce((acc, key) => {\n const breakpointStyleKey = breakpointsInput.up(key);\n acc[breakpointStyleKey] = {};\n return acc;\n }, {});\n return breakpointsInOrder || {};\n}\nexport function removeUnusedBreakpoints(breakpointKeys, style) {\n return breakpointKeys.reduce((acc, key) => {\n const breakpointOutput = acc[key];\n const isBreakpointUnused = !breakpointOutput || Object.keys(breakpointOutput).length === 0;\n if (isBreakpointUnused) {\n delete acc[key];\n }\n return acc;\n }, style);\n}\nexport function mergeBreakpointsInOrder(breakpointsInput, ...styles) {\n const emptyBreakpoints = createEmptyBreakpointObject(breakpointsInput);\n const mergedOutput = [emptyBreakpoints, ...styles].reduce((prev, next) => deepmerge(prev, next), {});\n return removeUnusedBreakpoints(Object.keys(emptyBreakpoints), mergedOutput);\n}\n\n// compute base for responsive values; e.g.,\n// [1,2,3] => {xs: true, sm: true, md: true}\n// {xs: 1, sm: 2, md: 3} => {xs: true, sm: true, md: true}\nexport function computeBreakpointsBase(breakpointValues, themeBreakpoints) {\n // fixed value\n if (typeof breakpointValues !== 'object') {\n return {};\n }\n const base = {};\n const breakpointsKeys = Object.keys(themeBreakpoints);\n if (Array.isArray(breakpointValues)) {\n breakpointsKeys.forEach((breakpoint, i) => {\n if (i < breakpointValues.length) {\n base[breakpoint] = true;\n }\n });\n } else {\n breakpointsKeys.forEach(breakpoint => {\n if (breakpointValues[breakpoint] != null) {\n base[breakpoint] = true;\n }\n });\n }\n return base;\n}\nexport function resolveBreakpointValues({\n values: breakpointValues,\n breakpoints: themeBreakpoints,\n base: customBase\n}) {\n const base = customBase || computeBreakpointsBase(breakpointValues, themeBreakpoints);\n const keys = Object.keys(base);\n if (keys.length === 0) {\n return breakpointValues;\n }\n let previous;\n return keys.reduce((acc, breakpoint, i) => {\n if (Array.isArray(breakpointValues)) {\n acc[breakpoint] = breakpointValues[i] != null ? breakpointValues[i] : breakpointValues[previous];\n previous = i;\n } else if (typeof breakpointValues === 'object') {\n acc[breakpoint] = breakpointValues[breakpoint] != null ? breakpointValues[breakpoint] : breakpointValues[previous];\n previous = breakpoint;\n } else {\n acc[breakpoint] = breakpointValues;\n }\n return acc;\n }, {});\n}\nexport default breakpoints;","import capitalize from '@mui/utils/capitalize';\nimport responsivePropType from './responsivePropType';\nimport { handleBreakpoints } from './breakpoints';\nexport function getPath(obj, path, checkVars = true) {\n if (!path || typeof path !== 'string') {\n return null;\n }\n\n // Check if CSS variables are used\n if (obj && obj.vars && checkVars) {\n const val = `vars.${path}`.split('.').reduce((acc, item) => acc && acc[item] ? acc[item] : null, obj);\n if (val != null) {\n return val;\n }\n }\n return path.split('.').reduce((acc, item) => {\n if (acc && acc[item] != null) {\n return acc[item];\n }\n return null;\n }, obj);\n}\nexport function getStyleValue(themeMapping, transform, propValueFinal, userValue = propValueFinal) {\n let value;\n if (typeof themeMapping === 'function') {\n value = themeMapping(propValueFinal);\n } else if (Array.isArray(themeMapping)) {\n value = themeMapping[propValueFinal] || userValue;\n } else {\n value = getPath(themeMapping, propValueFinal) || userValue;\n }\n if (transform) {\n value = transform(value, userValue, themeMapping);\n }\n return value;\n}\nfunction style(options) {\n const {\n prop,\n cssProperty = options.prop,\n themeKey,\n transform\n } = options;\n\n // false positive\n // eslint-disable-next-line react/function-component-definition\n const fn = props => {\n if (props[prop] == null) {\n return null;\n }\n const propValue = props[prop];\n const theme = props.theme;\n const themeMapping = getPath(theme, themeKey) || {};\n const styleFromPropValue = propValueFinal => {\n let value = getStyleValue(themeMapping, transform, propValueFinal);\n if (propValueFinal === value && typeof propValueFinal === 'string') {\n // Haven't found value\n value = getStyleValue(themeMapping, transform, `${prop}${propValueFinal === 'default' ? '' : capitalize(propValueFinal)}`, propValueFinal);\n }\n if (cssProperty === false) {\n return value;\n }\n return {\n [cssProperty]: value\n };\n };\n return handleBreakpoints(props, propValue, styleFromPropValue);\n };\n fn.propTypes = process.env.NODE_ENV !== 'production' ? {\n [prop]: responsivePropType\n } : {};\n fn.filterProps = [prop];\n return fn;\n}\nexport default style;","export default function memoize(fn) {\n const cache = {};\n return arg => {\n if (cache[arg] === undefined) {\n cache[arg] = fn(arg);\n }\n return cache[arg];\n };\n}","import responsivePropType from './responsivePropType';\nimport { handleBreakpoints } from './breakpoints';\nimport { getPath } from './style';\nimport merge from './merge';\nimport memoize from './memoize';\nconst properties = {\n m: 'margin',\n p: 'padding'\n};\nconst directions = {\n t: 'Top',\n r: 'Right',\n b: 'Bottom',\n l: 'Left',\n x: ['Left', 'Right'],\n y: ['Top', 'Bottom']\n};\nconst aliases = {\n marginX: 'mx',\n marginY: 'my',\n paddingX: 'px',\n paddingY: 'py'\n};\n\n// memoize() impact:\n// From 300,000 ops/sec\n// To 350,000 ops/sec\nconst getCssProperties = memoize(prop => {\n // It's not a shorthand notation.\n if (prop.length > 2) {\n if (aliases[prop]) {\n prop = aliases[prop];\n } else {\n return [prop];\n }\n }\n const [a, b] = prop.split('');\n const property = properties[a];\n const direction = directions[b] || '';\n return Array.isArray(direction) ? direction.map(dir => property + dir) : [property + direction];\n});\nexport const marginKeys = ['m', 'mt', 'mr', 'mb', 'ml', 'mx', 'my', 'margin', 'marginTop', 'marginRight', 'marginBottom', 'marginLeft', 'marginX', 'marginY', 'marginInline', 'marginInlineStart', 'marginInlineEnd', 'marginBlock', 'marginBlockStart', 'marginBlockEnd'];\nexport const paddingKeys = ['p', 'pt', 'pr', 'pb', 'pl', 'px', 'py', 'padding', 'paddingTop', 'paddingRight', 'paddingBottom', 'paddingLeft', 'paddingX', 'paddingY', 'paddingInline', 'paddingInlineStart', 'paddingInlineEnd', 'paddingBlock', 'paddingBlockStart', 'paddingBlockEnd'];\nconst spacingKeys = [...marginKeys, ...paddingKeys];\nexport function createUnaryUnit(theme, themeKey, defaultValue, propName) {\n var _getPath;\n const themeSpacing = (_getPath = getPath(theme, themeKey, false)) != null ? _getPath : defaultValue;\n if (typeof themeSpacing === 'number') {\n return abs => {\n if (typeof abs === 'string') {\n return abs;\n }\n if (process.env.NODE_ENV !== 'production') {\n if (typeof abs !== 'number') {\n console.error(`MUI: Expected ${propName} argument to be a number or a string, got ${abs}.`);\n }\n }\n return themeSpacing * abs;\n };\n }\n if (Array.isArray(themeSpacing)) {\n return abs => {\n if (typeof abs === 'string') {\n return abs;\n }\n if (process.env.NODE_ENV !== 'production') {\n if (!Number.isInteger(abs)) {\n console.error([`MUI: The \\`theme.${themeKey}\\` array type cannot be combined with non integer values.` + `You should either use an integer value that can be used as index, or define the \\`theme.${themeKey}\\` as a number.`].join('\\n'));\n } else if (abs > themeSpacing.length - 1) {\n console.error([`MUI: The value provided (${abs}) overflows.`, `The supported values are: ${JSON.stringify(themeSpacing)}.`, `${abs} > ${themeSpacing.length - 1}, you need to add the missing values.`].join('\\n'));\n }\n }\n return themeSpacing[abs];\n };\n }\n if (typeof themeSpacing === 'function') {\n return themeSpacing;\n }\n if (process.env.NODE_ENV !== 'production') {\n console.error([`MUI: The \\`theme.${themeKey}\\` value (${themeSpacing}) is invalid.`, 'It should be a number, an array or a function.'].join('\\n'));\n }\n return () => undefined;\n}\nexport function createUnarySpacing(theme) {\n return createUnaryUnit(theme, 'spacing', 8, 'spacing');\n}\nexport function getValue(transformer, propValue) {\n if (typeof propValue === 'string' || propValue == null) {\n return propValue;\n }\n const abs = Math.abs(propValue);\n const transformed = transformer(abs);\n if (propValue >= 0) {\n return transformed;\n }\n if (typeof transformed === 'number') {\n return -transformed;\n }\n return `-${transformed}`;\n}\nexport function getStyleFromPropValue(cssProperties, transformer) {\n return propValue => cssProperties.reduce((acc, cssProperty) => {\n acc[cssProperty] = getValue(transformer, propValue);\n return acc;\n }, {});\n}\nfunction resolveCssProperty(props, keys, prop, transformer) {\n // Using a hash computation over an array iteration could be faster, but with only 28 items,\n // it's doesn't worth the bundle size.\n if (keys.indexOf(prop) === -1) {\n return null;\n }\n const cssProperties = getCssProperties(prop);\n const styleFromPropValue = getStyleFromPropValue(cssProperties, transformer);\n const propValue = props[prop];\n return handleBreakpoints(props, propValue, styleFromPropValue);\n}\nfunction style(props, keys) {\n const transformer = createUnarySpacing(props.theme);\n return Object.keys(props).map(prop => resolveCssProperty(props, keys, prop, transformer)).reduce(merge, {});\n}\nexport function margin(props) {\n return style(props, marginKeys);\n}\nmargin.propTypes = process.env.NODE_ENV !== 'production' ? marginKeys.reduce((obj, key) => {\n obj[key] = responsivePropType;\n return obj;\n}, {}) : {};\nmargin.filterProps = marginKeys;\nexport function padding(props) {\n return style(props, paddingKeys);\n}\npadding.propTypes = process.env.NODE_ENV !== 'production' ? paddingKeys.reduce((obj, key) => {\n obj[key] = responsivePropType;\n return obj;\n}, {}) : {};\npadding.filterProps = paddingKeys;\nfunction spacing(props) {\n return style(props, spacingKeys);\n}\nspacing.propTypes = process.env.NODE_ENV !== 'production' ? spacingKeys.reduce((obj, key) => {\n obj[key] = responsivePropType;\n return obj;\n}, {}) : {};\nspacing.filterProps = spacingKeys;\nexport default spacing;","import { createUnarySpacing } from '../spacing';\n\n// The different signatures imply different meaning for their arguments that can't be expressed structurally.\n// We express the difference with variable names.\n\nexport default function createSpacing(spacingInput = 8) {\n // Already transformed.\n if (spacingInput.mui) {\n return spacingInput;\n }\n\n // Material Design layouts are visually balanced. Most measurements align to an 8dp grid, which aligns both spacing and the overall layout.\n // Smaller components, such as icons, can align to a 4dp grid.\n // https://m2.material.io/design/layout/understanding-layout.html\n const transform = createUnarySpacing({\n spacing: spacingInput\n });\n const spacing = (...argsInput) => {\n if (process.env.NODE_ENV !== 'production') {\n if (!(argsInput.length <= 4)) {\n console.error(`MUI: Too many arguments provided, expected between 0 and 4, got ${argsInput.length}`);\n }\n }\n const args = argsInput.length === 0 ? [1] : argsInput;\n return args.map(argument => {\n const output = transform(argument);\n return typeof output === 'number' ? `${output}px` : output;\n }).join(' ');\n };\n spacing.mui = true;\n return spacing;\n}","import merge from './merge';\nfunction compose(...styles) {\n const handlers = styles.reduce((acc, style) => {\n style.filterProps.forEach(prop => {\n acc[prop] = style;\n });\n return acc;\n }, {});\n\n // false positive\n // eslint-disable-next-line react/function-component-definition\n const fn = props => {\n return Object.keys(props).reduce((acc, prop) => {\n if (handlers[prop]) {\n return merge(acc, handlers[prop](props));\n }\n return acc;\n }, {});\n };\n fn.propTypes = process.env.NODE_ENV !== 'production' ? styles.reduce((acc, style) => Object.assign(acc, style.propTypes), {}) : {};\n fn.filterProps = styles.reduce((acc, style) => acc.concat(style.filterProps), []);\n return fn;\n}\nexport default compose;","import responsivePropType from './responsivePropType';\nimport style from './style';\nimport compose from './compose';\nimport { createUnaryUnit, getValue } from './spacing';\nimport { handleBreakpoints } from './breakpoints';\nexport function borderTransform(value) {\n if (typeof value !== 'number') {\n return value;\n }\n return `${value}px solid`;\n}\nfunction createBorderStyle(prop, transform) {\n return style({\n prop,\n themeKey: 'borders',\n transform\n });\n}\nexport const border = createBorderStyle('border', borderTransform);\nexport const borderTop = createBorderStyle('borderTop', borderTransform);\nexport const borderRight = createBorderStyle('borderRight', borderTransform);\nexport const borderBottom = createBorderStyle('borderBottom', borderTransform);\nexport const borderLeft = createBorderStyle('borderLeft', borderTransform);\nexport const borderColor = createBorderStyle('borderColor');\nexport const borderTopColor = createBorderStyle('borderTopColor');\nexport const borderRightColor = createBorderStyle('borderRightColor');\nexport const borderBottomColor = createBorderStyle('borderBottomColor');\nexport const borderLeftColor = createBorderStyle('borderLeftColor');\nexport const outline = createBorderStyle('outline', borderTransform);\nexport const outlineColor = createBorderStyle('outlineColor');\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const borderRadius = props => {\n if (props.borderRadius !== undefined && props.borderRadius !== null) {\n const transformer = createUnaryUnit(props.theme, 'shape.borderRadius', 4, 'borderRadius');\n const styleFromPropValue = propValue => ({\n borderRadius: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.borderRadius, styleFromPropValue);\n }\n return null;\n};\nborderRadius.propTypes = process.env.NODE_ENV !== 'production' ? {\n borderRadius: responsivePropType\n} : {};\nborderRadius.filterProps = ['borderRadius'];\nconst borders = compose(border, borderTop, borderRight, borderBottom, borderLeft, borderColor, borderTopColor, borderRightColor, borderBottomColor, borderLeftColor, borderRadius, outline, outlineColor);\nexport default borders;","import style from './style';\nimport compose from './compose';\nimport { createUnaryUnit, getValue } from './spacing';\nimport { handleBreakpoints } from './breakpoints';\nimport responsivePropType from './responsivePropType';\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const gap = props => {\n if (props.gap !== undefined && props.gap !== null) {\n const transformer = createUnaryUnit(props.theme, 'spacing', 8, 'gap');\n const styleFromPropValue = propValue => ({\n gap: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.gap, styleFromPropValue);\n }\n return null;\n};\ngap.propTypes = process.env.NODE_ENV !== 'production' ? {\n gap: responsivePropType\n} : {};\ngap.filterProps = ['gap'];\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const columnGap = props => {\n if (props.columnGap !== undefined && props.columnGap !== null) {\n const transformer = createUnaryUnit(props.theme, 'spacing', 8, 'columnGap');\n const styleFromPropValue = propValue => ({\n columnGap: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.columnGap, styleFromPropValue);\n }\n return null;\n};\ncolumnGap.propTypes = process.env.NODE_ENV !== 'production' ? {\n columnGap: responsivePropType\n} : {};\ncolumnGap.filterProps = ['columnGap'];\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const rowGap = props => {\n if (props.rowGap !== undefined && props.rowGap !== null) {\n const transformer = createUnaryUnit(props.theme, 'spacing', 8, 'rowGap');\n const styleFromPropValue = propValue => ({\n rowGap: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.rowGap, styleFromPropValue);\n }\n return null;\n};\nrowGap.propTypes = process.env.NODE_ENV !== 'production' ? {\n rowGap: responsivePropType\n} : {};\nrowGap.filterProps = ['rowGap'];\nexport const gridColumn = style({\n prop: 'gridColumn'\n});\nexport const gridRow = style({\n prop: 'gridRow'\n});\nexport const gridAutoFlow = style({\n prop: 'gridAutoFlow'\n});\nexport const gridAutoColumns = style({\n prop: 'gridAutoColumns'\n});\nexport const gridAutoRows = style({\n prop: 'gridAutoRows'\n});\nexport const gridTemplateColumns = style({\n prop: 'gridTemplateColumns'\n});\nexport const gridTemplateRows = style({\n prop: 'gridTemplateRows'\n});\nexport const gridTemplateAreas = style({\n prop: 'gridTemplateAreas'\n});\nexport const gridArea = style({\n prop: 'gridArea'\n});\nconst grid = compose(gap, columnGap, rowGap, gridColumn, gridRow, gridAutoFlow, gridAutoColumns, gridAutoRows, gridTemplateColumns, gridTemplateRows, gridTemplateAreas, gridArea);\nexport default grid;","import style from './style';\nimport compose from './compose';\nexport function paletteTransform(value, userValue) {\n if (userValue === 'grey') {\n return userValue;\n }\n return value;\n}\nexport const color = style({\n prop: 'color',\n themeKey: 'palette',\n transform: paletteTransform\n});\nexport const bgcolor = style({\n prop: 'bgcolor',\n cssProperty: 'backgroundColor',\n themeKey: 'palette',\n transform: paletteTransform\n});\nexport const backgroundColor = style({\n prop: 'backgroundColor',\n themeKey: 'palette',\n transform: paletteTransform\n});\nconst palette = compose(color, bgcolor, backgroundColor);\nexport default palette;","import style from './style';\nimport compose from './compose';\nimport { handleBreakpoints, values as breakpointsValues } from './breakpoints';\nexport function sizingTransform(value) {\n return value <= 1 && value !== 0 ? `${value * 100}%` : value;\n}\nexport const width = style({\n prop: 'width',\n transform: sizingTransform\n});\nexport const maxWidth = props => {\n if (props.maxWidth !== undefined && props.maxWidth !== null) {\n const styleFromPropValue = propValue => {\n var _props$theme, _props$theme2;\n const breakpoint = ((_props$theme = props.theme) == null || (_props$theme = _props$theme.breakpoints) == null || (_props$theme = _props$theme.values) == null ? void 0 : _props$theme[propValue]) || breakpointsValues[propValue];\n if (!breakpoint) {\n return {\n maxWidth: sizingTransform(propValue)\n };\n }\n if (((_props$theme2 = props.theme) == null || (_props$theme2 = _props$theme2.breakpoints) == null ? void 0 : _props$theme2.unit) !== 'px') {\n return {\n maxWidth: `${breakpoint}${props.theme.breakpoints.unit}`\n };\n }\n return {\n maxWidth: breakpoint\n };\n };\n return handleBreakpoints(props, props.maxWidth, styleFromPropValue);\n }\n return null;\n};\nmaxWidth.filterProps = ['maxWidth'];\nexport const minWidth = style({\n prop: 'minWidth',\n transform: sizingTransform\n});\nexport const height = style({\n prop: 'height',\n transform: sizingTransform\n});\nexport const maxHeight = style({\n prop: 'maxHeight',\n transform: sizingTransform\n});\nexport const minHeight = style({\n prop: 'minHeight',\n transform: sizingTransform\n});\nexport const sizeWidth = style({\n prop: 'size',\n cssProperty: 'width',\n transform: sizingTransform\n});\nexport const sizeHeight = style({\n prop: 'size',\n cssProperty: 'height',\n transform: sizingTransform\n});\nexport const boxSizing = style({\n prop: 'boxSizing'\n});\nconst sizing = compose(width, maxWidth, minWidth, height, maxHeight, minHeight, boxSizing);\nexport default sizing;","import { padding, margin } from '../spacing';\nimport { borderRadius, borderTransform } from '../borders';\nimport { gap, rowGap, columnGap } from '../cssGrid';\nimport { paletteTransform } from '../palette';\nimport { maxWidth, sizingTransform } from '../sizing';\nconst defaultSxConfig = {\n // borders\n border: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderTop: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderRight: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderBottom: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderLeft: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderColor: {\n themeKey: 'palette'\n },\n borderTopColor: {\n themeKey: 'palette'\n },\n borderRightColor: {\n themeKey: 'palette'\n },\n borderBottomColor: {\n themeKey: 'palette'\n },\n borderLeftColor: {\n themeKey: 'palette'\n },\n outline: {\n themeKey: 'borders',\n transform: borderTransform\n },\n outlineColor: {\n themeKey: 'palette'\n },\n borderRadius: {\n themeKey: 'shape.borderRadius',\n style: borderRadius\n },\n // palette\n color: {\n themeKey: 'palette',\n transform: paletteTransform\n },\n bgcolor: {\n themeKey: 'palette',\n cssProperty: 'backgroundColor',\n transform: paletteTransform\n },\n backgroundColor: {\n themeKey: 'palette',\n transform: paletteTransform\n },\n // spacing\n p: {\n style: padding\n },\n pt: {\n style: padding\n },\n pr: {\n style: padding\n },\n pb: {\n style: padding\n },\n pl: {\n style: padding\n },\n px: {\n style: padding\n },\n py: {\n style: padding\n },\n padding: {\n style: padding\n },\n paddingTop: {\n style: padding\n },\n paddingRight: {\n style: padding\n },\n paddingBottom: {\n style: padding\n },\n paddingLeft: {\n style: padding\n },\n paddingX: {\n style: padding\n },\n paddingY: {\n style: padding\n },\n paddingInline: {\n style: padding\n },\n paddingInlineStart: {\n style: padding\n },\n paddingInlineEnd: {\n style: padding\n },\n paddingBlock: {\n style: padding\n },\n paddingBlockStart: {\n style: padding\n },\n paddingBlockEnd: {\n style: padding\n },\n m: {\n style: margin\n },\n mt: {\n style: margin\n },\n mr: {\n style: margin\n },\n mb: {\n style: margin\n },\n ml: {\n style: margin\n },\n mx: {\n style: margin\n },\n my: {\n style: margin\n },\n margin: {\n style: margin\n },\n marginTop: {\n style: margin\n },\n marginRight: {\n style: margin\n },\n marginBottom: {\n style: margin\n },\n marginLeft: {\n style: margin\n },\n marginX: {\n style: margin\n },\n marginY: {\n style: margin\n },\n marginInline: {\n style: margin\n },\n marginInlineStart: {\n style: margin\n },\n marginInlineEnd: {\n style: margin\n },\n marginBlock: {\n style: margin\n },\n marginBlockStart: {\n style: margin\n },\n marginBlockEnd: {\n style: margin\n },\n // display\n displayPrint: {\n cssProperty: false,\n transform: value => ({\n '@media print': {\n display: value\n }\n })\n },\n display: {},\n overflow: {},\n textOverflow: {},\n visibility: {},\n whiteSpace: {},\n // flexbox\n flexBasis: {},\n flexDirection: {},\n flexWrap: {},\n justifyContent: {},\n alignItems: {},\n alignContent: {},\n order: {},\n flex: {},\n flexGrow: {},\n flexShrink: {},\n alignSelf: {},\n justifyItems: {},\n justifySelf: {},\n // grid\n gap: {\n style: gap\n },\n rowGap: {\n style: rowGap\n },\n columnGap: {\n style: columnGap\n },\n gridColumn: {},\n gridRow: {},\n gridAutoFlow: {},\n gridAutoColumns: {},\n gridAutoRows: {},\n gridTemplateColumns: {},\n gridTemplateRows: {},\n gridTemplateAreas: {},\n gridArea: {},\n // positions\n position: {},\n zIndex: {\n themeKey: 'zIndex'\n },\n top: {},\n right: {},\n bottom: {},\n left: {},\n // shadows\n boxShadow: {\n themeKey: 'shadows'\n },\n // sizing\n width: {\n transform: sizingTransform\n },\n maxWidth: {\n style: maxWidth\n },\n minWidth: {\n transform: sizingTransform\n },\n height: {\n transform: sizingTransform\n },\n maxHeight: {\n transform: sizingTransform\n },\n minHeight: {\n transform: sizingTransform\n },\n boxSizing: {},\n // typography\n fontFamily: {\n themeKey: 'typography'\n },\n fontSize: {\n themeKey: 'typography'\n },\n fontStyle: {\n themeKey: 'typography'\n },\n fontWeight: {\n themeKey: 'typography'\n },\n letterSpacing: {},\n textTransform: {},\n lineHeight: {},\n textAlign: {},\n typography: {\n cssProperty: false,\n themeKey: 'typography'\n }\n};\nexport default defaultSxConfig;","import capitalize from '@mui/utils/capitalize';\nimport merge from '../merge';\nimport { getPath, getStyleValue as getValue } from '../style';\nimport { handleBreakpoints, createEmptyBreakpointObject, removeUnusedBreakpoints } from '../breakpoints';\nimport defaultSxConfig from './defaultSxConfig';\nfunction objectsHaveSameKeys(...objects) {\n const allKeys = objects.reduce((keys, object) => keys.concat(Object.keys(object)), []);\n const union = new Set(allKeys);\n return objects.every(object => union.size === Object.keys(object).length);\n}\nfunction callIfFn(maybeFn, arg) {\n return typeof maybeFn === 'function' ? maybeFn(arg) : maybeFn;\n}\n\n// eslint-disable-next-line @typescript-eslint/naming-convention\nexport function unstable_createStyleFunctionSx() {\n function getThemeValue(prop, val, theme, config) {\n const props = {\n [prop]: val,\n theme\n };\n const options = config[prop];\n if (!options) {\n return {\n [prop]: val\n };\n }\n const {\n cssProperty = prop,\n themeKey,\n transform,\n style\n } = options;\n if (val == null) {\n return null;\n }\n\n // TODO v6: remove, see https://github.com/mui/material-ui/pull/38123\n if (themeKey === 'typography' && val === 'inherit') {\n return {\n [prop]: val\n };\n }\n const themeMapping = getPath(theme, themeKey) || {};\n if (style) {\n return style(props);\n }\n const styleFromPropValue = propValueFinal => {\n let value = getValue(themeMapping, transform, propValueFinal);\n if (propValueFinal === value && typeof propValueFinal === 'string') {\n // Haven't found value\n value = getValue(themeMapping, transform, `${prop}${propValueFinal === 'default' ? '' : capitalize(propValueFinal)}`, propValueFinal);\n }\n if (cssProperty === false) {\n return value;\n }\n return {\n [cssProperty]: value\n };\n };\n return handleBreakpoints(props, val, styleFromPropValue);\n }\n function styleFunctionSx(props) {\n var _theme$unstable_sxCon;\n const {\n sx,\n theme = {}\n } = props || {};\n if (!sx) {\n return null; // Emotion & styled-components will neglect null\n }\n const config = (_theme$unstable_sxCon = theme.unstable_sxConfig) != null ? _theme$unstable_sxCon : defaultSxConfig;\n\n /*\n * Receive `sxInput` as object or callback\n * and then recursively check keys & values to create media query object styles.\n * (the result will be used in `styled`)\n */\n function traverse(sxInput) {\n let sxObject = sxInput;\n if (typeof sxInput === 'function') {\n sxObject = sxInput(theme);\n } else if (typeof sxInput !== 'object') {\n // value\n return sxInput;\n }\n if (!sxObject) {\n return null;\n }\n const emptyBreakpoints = createEmptyBreakpointObject(theme.breakpoints);\n const breakpointsKeys = Object.keys(emptyBreakpoints);\n let css = emptyBreakpoints;\n Object.keys(sxObject).forEach(styleKey => {\n const value = callIfFn(sxObject[styleKey], theme);\n if (value !== null && value !== undefined) {\n if (typeof value === 'object') {\n if (config[styleKey]) {\n css = merge(css, getThemeValue(styleKey, value, theme, config));\n } else {\n const breakpointsValues = handleBreakpoints({\n theme\n }, value, x => ({\n [styleKey]: x\n }));\n if (objectsHaveSameKeys(breakpointsValues, value)) {\n css[styleKey] = styleFunctionSx({\n sx: value,\n theme\n });\n } else {\n css = merge(css, breakpointsValues);\n }\n }\n } else {\n css = merge(css, getThemeValue(styleKey, value, theme, config));\n }\n }\n });\n return removeUnusedBreakpoints(breakpointsKeys, css);\n }\n return Array.isArray(sx) ? sx.map(traverse) : traverse(sx);\n }\n return styleFunctionSx;\n}\nconst styleFunctionSx = unstable_createStyleFunctionSx();\nstyleFunctionSx.filterProps = ['sx'];\nexport default styleFunctionSx;","/**\n * A universal utility to style components with multiple color modes. Always use it from the theme object.\n * It works with:\n * - [Basic theme](https://mui.com/material-ui/customization/dark-mode/)\n * - [CSS theme variables](https://mui.com/material-ui/experimental-api/css-theme-variables/overview/)\n * - Zero-runtime engine\n *\n * Tips: Use an array over object spread and place `theme.applyStyles()` last.\n *\n * ✅ [{ background: '#e5e5e5' }, theme.applyStyles('dark', { background: '#1c1c1c' })]\n *\n * 🚫 { background: '#e5e5e5', ...theme.applyStyles('dark', { background: '#1c1c1c' })}\n *\n * @example\n * 1. using with `styled`:\n * ```jsx\n * const Component = styled('div')(({ theme }) => [\n * { background: '#e5e5e5' },\n * theme.applyStyles('dark', {\n * background: '#1c1c1c',\n * color: '#fff',\n * }),\n * ]);\n * ```\n *\n * @example\n * 2. using with `sx` prop:\n * ```jsx\n * [\n * { background: '#e5e5e5' },\n * theme.applyStyles('dark', {\n * background: '#1c1c1c',\n * color: '#fff',\n * }),\n * ]}\n * />\n * ```\n *\n * @example\n * 3. theming a component:\n * ```jsx\n * extendTheme({\n * components: {\n * MuiButton: {\n * styleOverrides: {\n * root: ({ theme }) => [\n * { background: '#e5e5e5' },\n * theme.applyStyles('dark', {\n * background: '#1c1c1c',\n * color: '#fff',\n * }),\n * ],\n * },\n * }\n * }\n * })\n *```\n */\nexport default function applyStyles(key, styles) {\n // @ts-expect-error this is 'any' type\n const theme = this;\n if (theme.vars && typeof theme.getColorSchemeSelector === 'function') {\n // If CssVarsProvider is used as a provider,\n // returns '* :where([data-mui-color-scheme=\"light|dark\"]) &'\n const selector = theme.getColorSchemeSelector(key).replace(/(\\[[^\\]]+\\])/, '*:where($1)');\n return {\n [selector]: styles\n };\n }\n if (theme.palette.mode === key) {\n return styles;\n }\n return {};\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"breakpoints\", \"palette\", \"spacing\", \"shape\"];\nimport deepmerge from '@mui/utils/deepmerge';\nimport createBreakpoints from './createBreakpoints';\nimport shape from './shape';\nimport createSpacing from './createSpacing';\nimport styleFunctionSx from '../styleFunctionSx/styleFunctionSx';\nimport defaultSxConfig from '../styleFunctionSx/defaultSxConfig';\nimport applyStyles from './applyStyles';\nfunction createTheme(options = {}, ...args) {\n const {\n breakpoints: breakpointsInput = {},\n palette: paletteInput = {},\n spacing: spacingInput,\n shape: shapeInput = {}\n } = options,\n other = _objectWithoutPropertiesLoose(options, _excluded);\n const breakpoints = createBreakpoints(breakpointsInput);\n const spacing = createSpacing(spacingInput);\n let muiTheme = deepmerge({\n breakpoints,\n direction: 'ltr',\n components: {},\n // Inject component definitions.\n palette: _extends({\n mode: 'light'\n }, paletteInput),\n spacing,\n shape: _extends({}, shape, shapeInput)\n }, other);\n muiTheme.applyStyles = applyStyles;\n muiTheme = args.reduce((acc, argument) => deepmerge(acc, argument), muiTheme);\n muiTheme.unstable_sxConfig = _extends({}, defaultSxConfig, other == null ? void 0 : other.unstable_sxConfig);\n muiTheme.unstable_sx = function sx(props) {\n return styleFunctionSx({\n sx: props,\n theme: this\n });\n };\n return muiTheme;\n}\nexport default createTheme;","'use client';\n\nimport * as React from 'react';\nimport { ThemeContext } from '@mui/styled-engine';\nfunction isObjectEmpty(obj) {\n return Object.keys(obj).length === 0;\n}\nfunction useTheme(defaultTheme = null) {\n const contextTheme = React.useContext(ThemeContext);\n return !contextTheme || isObjectEmpty(contextTheme) ? defaultTheme : contextTheme;\n}\nexport default useTheme;","'use client';\n\nimport createTheme from './createTheme';\nimport useThemeWithoutDefault from './useThemeWithoutDefault';\nexport const systemDefaultTheme = createTheme();\nfunction useTheme(defaultTheme = systemDefaultTheme) {\n return useThemeWithoutDefault(defaultTheme);\n}\nexport default useTheme;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"ownerState\"],\n _excluded2 = [\"variants\"],\n _excluded3 = [\"name\", \"slot\", \"skipVariantsResolver\", \"skipSx\", \"overridesResolver\"];\n/* eslint-disable no-underscore-dangle */\nimport styledEngineStyled, { internal_processStyles as processStyles } from '@mui/styled-engine';\nimport { isPlainObject } from '@mui/utils/deepmerge';\nimport capitalize from '@mui/utils/capitalize';\nimport getDisplayName from '@mui/utils/getDisplayName';\nimport createTheme from './createTheme';\nimport styleFunctionSx from './styleFunctionSx';\nfunction isEmpty(obj) {\n return Object.keys(obj).length === 0;\n}\n\n// https://github.com/emotion-js/emotion/blob/26ded6109fcd8ca9875cc2ce4564fee678a3f3c5/packages/styled/src/utils.js#L40\nfunction isStringTag(tag) {\n return typeof tag === 'string' &&\n // 96 is one less than the char code\n // for \"a\" so this is checking that\n // it's a lowercase character\n tag.charCodeAt(0) > 96;\n}\n\n// Update /system/styled/#api in case if this changes\nexport function shouldForwardProp(prop) {\n return prop !== 'ownerState' && prop !== 'theme' && prop !== 'sx' && prop !== 'as';\n}\nexport const systemDefaultTheme = createTheme();\nconst lowercaseFirstLetter = string => {\n if (!string) {\n return string;\n }\n return string.charAt(0).toLowerCase() + string.slice(1);\n};\nfunction resolveTheme({\n defaultTheme,\n theme,\n themeId\n}) {\n return isEmpty(theme) ? defaultTheme : theme[themeId] || theme;\n}\nfunction defaultOverridesResolver(slot) {\n if (!slot) {\n return null;\n }\n return (props, styles) => styles[slot];\n}\nfunction processStyleArg(callableStyle, _ref) {\n let {\n ownerState\n } = _ref,\n props = _objectWithoutPropertiesLoose(_ref, _excluded);\n const resolvedStylesArg = typeof callableStyle === 'function' ? callableStyle(_extends({\n ownerState\n }, props)) : callableStyle;\n if (Array.isArray(resolvedStylesArg)) {\n return resolvedStylesArg.flatMap(resolvedStyle => processStyleArg(resolvedStyle, _extends({\n ownerState\n }, props)));\n }\n if (!!resolvedStylesArg && typeof resolvedStylesArg === 'object' && Array.isArray(resolvedStylesArg.variants)) {\n const {\n variants = []\n } = resolvedStylesArg,\n otherStyles = _objectWithoutPropertiesLoose(resolvedStylesArg, _excluded2);\n let result = otherStyles;\n variants.forEach(variant => {\n let isMatch = true;\n if (typeof variant.props === 'function') {\n isMatch = variant.props(_extends({\n ownerState\n }, props, ownerState));\n } else {\n Object.keys(variant.props).forEach(key => {\n if ((ownerState == null ? void 0 : ownerState[key]) !== variant.props[key] && props[key] !== variant.props[key]) {\n isMatch = false;\n }\n });\n }\n if (isMatch) {\n if (!Array.isArray(result)) {\n result = [result];\n }\n result.push(typeof variant.style === 'function' ? variant.style(_extends({\n ownerState\n }, props, ownerState)) : variant.style);\n }\n });\n return result;\n }\n return resolvedStylesArg;\n}\nexport default function createStyled(input = {}) {\n const {\n themeId,\n defaultTheme = systemDefaultTheme,\n rootShouldForwardProp = shouldForwardProp,\n slotShouldForwardProp = shouldForwardProp\n } = input;\n const systemSx = props => {\n return styleFunctionSx(_extends({}, props, {\n theme: resolveTheme(_extends({}, props, {\n defaultTheme,\n themeId\n }))\n }));\n };\n systemSx.__mui_systemSx = true;\n return (tag, inputOptions = {}) => {\n // Filter out the `sx` style function from the previous styled component to prevent unnecessary styles generated by the composite components.\n processStyles(tag, styles => styles.filter(style => !(style != null && style.__mui_systemSx)));\n const {\n name: componentName,\n slot: componentSlot,\n skipVariantsResolver: inputSkipVariantsResolver,\n skipSx: inputSkipSx,\n // TODO v6: remove `lowercaseFirstLetter()` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n overridesResolver = defaultOverridesResolver(lowercaseFirstLetter(componentSlot))\n } = inputOptions,\n options = _objectWithoutPropertiesLoose(inputOptions, _excluded3);\n\n // if skipVariantsResolver option is defined, take the value, otherwise, true for root and false for other slots.\n const skipVariantsResolver = inputSkipVariantsResolver !== undefined ? inputSkipVariantsResolver :\n // TODO v6: remove `Root` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n componentSlot && componentSlot !== 'Root' && componentSlot !== 'root' || false;\n const skipSx = inputSkipSx || false;\n let label;\n if (process.env.NODE_ENV !== 'production') {\n if (componentName) {\n // TODO v6: remove `lowercaseFirstLetter()` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n label = `${componentName}-${lowercaseFirstLetter(componentSlot || 'Root')}`;\n }\n }\n let shouldForwardPropOption = shouldForwardProp;\n\n // TODO v6: remove `Root` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n if (componentSlot === 'Root' || componentSlot === 'root') {\n shouldForwardPropOption = rootShouldForwardProp;\n } else if (componentSlot) {\n // any other slot specified\n shouldForwardPropOption = slotShouldForwardProp;\n } else if (isStringTag(tag)) {\n // for string (html) tag, preserve the behavior in emotion & styled-components.\n shouldForwardPropOption = undefined;\n }\n const defaultStyledResolver = styledEngineStyled(tag, _extends({\n shouldForwardProp: shouldForwardPropOption,\n label\n }, options));\n const transformStyleArg = stylesArg => {\n // On the server Emotion doesn't use React.forwardRef for creating components, so the created\n // component stays as a function. This condition makes sure that we do not interpolate functions\n // which are basically components used as a selectors.\n if (typeof stylesArg === 'function' && stylesArg.__emotion_real !== stylesArg || isPlainObject(stylesArg)) {\n return props => processStyleArg(stylesArg, _extends({}, props, {\n theme: resolveTheme({\n theme: props.theme,\n defaultTheme,\n themeId\n })\n }));\n }\n return stylesArg;\n };\n const muiStyledResolver = (styleArg, ...expressions) => {\n let transformedStyleArg = transformStyleArg(styleArg);\n const expressionsWithDefaultTheme = expressions ? expressions.map(transformStyleArg) : [];\n if (componentName && overridesResolver) {\n expressionsWithDefaultTheme.push(props => {\n const theme = resolveTheme(_extends({}, props, {\n defaultTheme,\n themeId\n }));\n if (!theme.components || !theme.components[componentName] || !theme.components[componentName].styleOverrides) {\n return null;\n }\n const styleOverrides = theme.components[componentName].styleOverrides;\n const resolvedStyleOverrides = {};\n // TODO: v7 remove iteration and use `resolveStyleArg(styleOverrides[slot])` directly\n Object.entries(styleOverrides).forEach(([slotKey, slotStyle]) => {\n resolvedStyleOverrides[slotKey] = processStyleArg(slotStyle, _extends({}, props, {\n theme\n }));\n });\n return overridesResolver(props, resolvedStyleOverrides);\n });\n }\n if (componentName && !skipVariantsResolver) {\n expressionsWithDefaultTheme.push(props => {\n var _theme$components;\n const theme = resolveTheme(_extends({}, props, {\n defaultTheme,\n themeId\n }));\n const themeVariants = theme == null || (_theme$components = theme.components) == null || (_theme$components = _theme$components[componentName]) == null ? void 0 : _theme$components.variants;\n return processStyleArg({\n variants: themeVariants\n }, _extends({}, props, {\n theme\n }));\n });\n }\n if (!skipSx) {\n expressionsWithDefaultTheme.push(systemSx);\n }\n const numOfCustomFnsApplied = expressionsWithDefaultTheme.length - expressions.length;\n if (Array.isArray(styleArg) && numOfCustomFnsApplied > 0) {\n const placeholders = new Array(numOfCustomFnsApplied).fill('');\n // If the type is array, than we need to add placeholders in the template for the overrides, variants and the sx styles.\n transformedStyleArg = [...styleArg, ...placeholders];\n transformedStyleArg.raw = [...styleArg.raw, ...placeholders];\n }\n const Component = defaultStyledResolver(transformedStyleArg, ...expressionsWithDefaultTheme);\n if (process.env.NODE_ENV !== 'production') {\n let displayName;\n if (componentName) {\n displayName = `${componentName}${capitalize(componentSlot || '')}`;\n }\n if (displayName === undefined) {\n displayName = `Styled(${getDisplayName(tag)})`;\n }\n Component.displayName = displayName;\n }\n if (tag.muiName) {\n Component.muiName = tag.muiName;\n }\n return Component;\n };\n if (defaultStyledResolver.withConfig) {\n muiStyledResolver.withConfig = defaultStyledResolver.withConfig;\n }\n return muiStyledResolver;\n };\n}","import resolveProps from '@mui/utils/resolveProps';\nexport default function getThemeProps(params) {\n const {\n theme,\n name,\n props\n } = params;\n if (!theme || !theme.components || !theme.components[name] || !theme.components[name].defaultProps) {\n return props;\n }\n return resolveProps(theme.components[name].defaultProps, props);\n}","'use client';\n\nimport getThemeProps from './getThemeProps';\nimport useTheme from '../useTheme';\nexport default function useThemeProps({\n props,\n name,\n defaultTheme,\n themeId\n}) {\n let theme = useTheme(defaultTheme);\n if (themeId) {\n theme = theme[themeId] || theme;\n }\n const mergedProps = getThemeProps({\n theme,\n name,\n props\n });\n return mergedProps;\n}","import _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\n/* eslint-disable @typescript-eslint/naming-convention */\nimport clamp from '@mui/utils/clamp';\n/**\n * Returns a number whose value is limited to the given range.\n * @param {number} value The value to be clamped\n * @param {number} min The lower boundary of the output range\n * @param {number} max The upper boundary of the output range\n * @returns {number} A number in the range [min, max]\n */\nfunction clampWrapper(value, min = 0, max = 1) {\n if (process.env.NODE_ENV !== 'production') {\n if (value < min || value > max) {\n console.error(`MUI: The value provided ${value} is out of range [${min}, ${max}].`);\n }\n }\n return clamp(value, min, max);\n}\n\n/**\n * Converts a color from CSS hex format to CSS rgb format.\n * @param {string} color - Hex color, i.e. #nnn or #nnnnnn\n * @returns {string} A CSS rgb color string\n */\nexport function hexToRgb(color) {\n color = color.slice(1);\n const re = new RegExp(`.{1,${color.length >= 6 ? 2 : 1}}`, 'g');\n let colors = color.match(re);\n if (colors && colors[0].length === 1) {\n colors = colors.map(n => n + n);\n }\n return colors ? `rgb${colors.length === 4 ? 'a' : ''}(${colors.map((n, index) => {\n return index < 3 ? parseInt(n, 16) : Math.round(parseInt(n, 16) / 255 * 1000) / 1000;\n }).join(', ')})` : '';\n}\nfunction intToHex(int) {\n const hex = int.toString(16);\n return hex.length === 1 ? `0${hex}` : hex;\n}\n\n/**\n * Returns an object with the type and values of a color.\n *\n * Note: Does not support rgb % values.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @returns {object} - A MUI color object: {type: string, values: number[]}\n */\nexport function decomposeColor(color) {\n // Idempotent\n if (color.type) {\n return color;\n }\n if (color.charAt(0) === '#') {\n return decomposeColor(hexToRgb(color));\n }\n const marker = color.indexOf('(');\n const type = color.substring(0, marker);\n if (['rgb', 'rgba', 'hsl', 'hsla', 'color'].indexOf(type) === -1) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: Unsupported \\`${color}\\` color.\nThe following formats are supported: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color().` : _formatMuiErrorMessage(9, color));\n }\n let values = color.substring(marker + 1, color.length - 1);\n let colorSpace;\n if (type === 'color') {\n values = values.split(' ');\n colorSpace = values.shift();\n if (values.length === 4 && values[3].charAt(0) === '/') {\n values[3] = values[3].slice(1);\n }\n if (['srgb', 'display-p3', 'a98-rgb', 'prophoto-rgb', 'rec-2020'].indexOf(colorSpace) === -1) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: unsupported \\`${colorSpace}\\` color space.\nThe following color spaces are supported: srgb, display-p3, a98-rgb, prophoto-rgb, rec-2020.` : _formatMuiErrorMessage(10, colorSpace));\n }\n } else {\n values = values.split(',');\n }\n values = values.map(value => parseFloat(value));\n return {\n type,\n values,\n colorSpace\n };\n}\n\n/**\n * Returns a channel created from the input color.\n *\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @returns {string} - The channel for the color, that can be used in rgba or hsla colors\n */\nexport const colorChannel = color => {\n const decomposedColor = decomposeColor(color);\n return decomposedColor.values.slice(0, 3).map((val, idx) => decomposedColor.type.indexOf('hsl') !== -1 && idx !== 0 ? `${val}%` : val).join(' ');\n};\nexport const private_safeColorChannel = (color, warning) => {\n try {\n return colorChannel(color);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n};\n\n/**\n * Converts a color object with type and values to a string.\n * @param {object} color - Decomposed color\n * @param {string} color.type - One of: 'rgb', 'rgba', 'hsl', 'hsla', 'color'\n * @param {array} color.values - [n,n,n] or [n,n,n,n]\n * @returns {string} A CSS color string\n */\nexport function recomposeColor(color) {\n const {\n type,\n colorSpace\n } = color;\n let {\n values\n } = color;\n if (type.indexOf('rgb') !== -1) {\n // Only convert the first 3 values to int (i.e. not alpha)\n values = values.map((n, i) => i < 3 ? parseInt(n, 10) : n);\n } else if (type.indexOf('hsl') !== -1) {\n values[1] = `${values[1]}%`;\n values[2] = `${values[2]}%`;\n }\n if (type.indexOf('color') !== -1) {\n values = `${colorSpace} ${values.join(' ')}`;\n } else {\n values = `${values.join(', ')}`;\n }\n return `${type}(${values})`;\n}\n\n/**\n * Converts a color from CSS rgb format to CSS hex format.\n * @param {string} color - RGB color, i.e. rgb(n, n, n)\n * @returns {string} A CSS rgb color string, i.e. #nnnnnn\n */\nexport function rgbToHex(color) {\n // Idempotent\n if (color.indexOf('#') === 0) {\n return color;\n }\n const {\n values\n } = decomposeColor(color);\n return `#${values.map((n, i) => intToHex(i === 3 ? Math.round(255 * n) : n)).join('')}`;\n}\n\n/**\n * Converts a color from hsl format to rgb format.\n * @param {string} color - HSL color values\n * @returns {string} rgb color values\n */\nexport function hslToRgb(color) {\n color = decomposeColor(color);\n const {\n values\n } = color;\n const h = values[0];\n const s = values[1] / 100;\n const l = values[2] / 100;\n const a = s * Math.min(l, 1 - l);\n const f = (n, k = (n + h / 30) % 12) => l - a * Math.max(Math.min(k - 3, 9 - k, 1), -1);\n let type = 'rgb';\n const rgb = [Math.round(f(0) * 255), Math.round(f(8) * 255), Math.round(f(4) * 255)];\n if (color.type === 'hsla') {\n type += 'a';\n rgb.push(values[3]);\n }\n return recomposeColor({\n type,\n values: rgb\n });\n}\n/**\n * The relative brightness of any point in a color space,\n * normalized to 0 for darkest black and 1 for lightest white.\n *\n * Formula: https://www.w3.org/TR/WCAG20-TECHS/G17.html#G17-tests\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @returns {number} The relative brightness of the color in the range 0 - 1\n */\nexport function getLuminance(color) {\n color = decomposeColor(color);\n let rgb = color.type === 'hsl' || color.type === 'hsla' ? decomposeColor(hslToRgb(color)).values : color.values;\n rgb = rgb.map(val => {\n if (color.type !== 'color') {\n val /= 255; // normalized\n }\n return val <= 0.03928 ? val / 12.92 : ((val + 0.055) / 1.055) ** 2.4;\n });\n\n // Truncate at 3 digits\n return Number((0.2126 * rgb[0] + 0.7152 * rgb[1] + 0.0722 * rgb[2]).toFixed(3));\n}\n\n/**\n * Calculates the contrast ratio between two colors.\n *\n * Formula: https://www.w3.org/TR/WCAG20-TECHS/G17.html#G17-tests\n * @param {string} foreground - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla()\n * @param {string} background - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla()\n * @returns {number} A contrast ratio value in the range 0 - 21.\n */\nexport function getContrastRatio(foreground, background) {\n const lumA = getLuminance(foreground);\n const lumB = getLuminance(background);\n return (Math.max(lumA, lumB) + 0.05) / (Math.min(lumA, lumB) + 0.05);\n}\n\n/**\n * Sets the absolute transparency of a color.\n * Any existing alpha values are overwritten.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} value - value to set the alpha channel to in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function alpha(color, value) {\n color = decomposeColor(color);\n value = clampWrapper(value);\n if (color.type === 'rgb' || color.type === 'hsl') {\n color.type += 'a';\n }\n if (color.type === 'color') {\n color.values[3] = `/${value}`;\n } else {\n color.values[3] = value;\n }\n return recomposeColor(color);\n}\nexport function private_safeAlpha(color, value, warning) {\n try {\n return alpha(color, value);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Darkens a color.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} coefficient - multiplier in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function darken(color, coefficient) {\n color = decomposeColor(color);\n coefficient = clampWrapper(coefficient);\n if (color.type.indexOf('hsl') !== -1) {\n color.values[2] *= 1 - coefficient;\n } else if (color.type.indexOf('rgb') !== -1 || color.type.indexOf('color') !== -1) {\n for (let i = 0; i < 3; i += 1) {\n color.values[i] *= 1 - coefficient;\n }\n }\n return recomposeColor(color);\n}\nexport function private_safeDarken(color, coefficient, warning) {\n try {\n return darken(color, coefficient);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Lightens a color.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} coefficient - multiplier in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function lighten(color, coefficient) {\n color = decomposeColor(color);\n coefficient = clampWrapper(coefficient);\n if (color.type.indexOf('hsl') !== -1) {\n color.values[2] += (100 - color.values[2]) * coefficient;\n } else if (color.type.indexOf('rgb') !== -1) {\n for (let i = 0; i < 3; i += 1) {\n color.values[i] += (255 - color.values[i]) * coefficient;\n }\n } else if (color.type.indexOf('color') !== -1) {\n for (let i = 0; i < 3; i += 1) {\n color.values[i] += (1 - color.values[i]) * coefficient;\n }\n }\n return recomposeColor(color);\n}\nexport function private_safeLighten(color, coefficient, warning) {\n try {\n return lighten(color, coefficient);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Darken or lighten a color, depending on its luminance.\n * Light colors are darkened, dark colors are lightened.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} coefficient=0.15 - multiplier in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function emphasize(color, coefficient = 0.15) {\n return getLuminance(color) > 0.5 ? darken(color, coefficient) : lighten(color, coefficient);\n}\nexport function private_safeEmphasize(color, coefficient, warning) {\n try {\n return emphasize(color, coefficient);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Blend a transparent overlay color with a background color, resulting in a single\n * RGB color.\n * @param {string} background - CSS color\n * @param {string} overlay - CSS color\n * @param {number} opacity - Opacity multiplier in the range 0 - 1\n * @param {number} [gamma=1.0] - Gamma correction factor. For gamma-correct blending, 2.2 is usual.\n */\nexport function blend(background, overlay, opacity, gamma = 1.0) {\n const blendChannel = (b, o) => Math.round((b ** (1 / gamma) * (1 - opacity) + o ** (1 / gamma) * opacity) ** gamma);\n const backgroundColor = decomposeColor(background);\n const overlayColor = decomposeColor(overlay);\n const rgb = [blendChannel(backgroundColor.values[0], overlayColor.values[0]), blendChannel(backgroundColor.values[1], overlayColor.values[1]), blendChannel(backgroundColor.values[2], overlayColor.values[2])];\n return recomposeColor({\n type: 'rgb',\n values: rgb\n });\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nexport default function createMixins(breakpoints, mixins) {\n return _extends({\n toolbar: {\n minHeight: 56,\n [breakpoints.up('xs')]: {\n '@media (orientation: landscape)': {\n minHeight: 48\n }\n },\n [breakpoints.up('sm')]: {\n minHeight: 64\n }\n }\n }, mixins);\n}","const common = {\n black: '#000',\n white: '#fff'\n};\nexport default common;","const grey = {\n 50: '#fafafa',\n 100: '#f5f5f5',\n 200: '#eeeeee',\n 300: '#e0e0e0',\n 400: '#bdbdbd',\n 500: '#9e9e9e',\n 600: '#757575',\n 700: '#616161',\n 800: '#424242',\n 900: '#212121',\n A100: '#f5f5f5',\n A200: '#eeeeee',\n A400: '#bdbdbd',\n A700: '#616161'\n};\nexport default grey;","const purple = {\n 50: '#f3e5f5',\n 100: '#e1bee7',\n 200: '#ce93d8',\n 300: '#ba68c8',\n 400: '#ab47bc',\n 500: '#9c27b0',\n 600: '#8e24aa',\n 700: '#7b1fa2',\n 800: '#6a1b9a',\n 900: '#4a148c',\n A100: '#ea80fc',\n A200: '#e040fb',\n A400: '#d500f9',\n A700: '#aa00ff'\n};\nexport default purple;","const red = {\n 50: '#ffebee',\n 100: '#ffcdd2',\n 200: '#ef9a9a',\n 300: '#e57373',\n 400: '#ef5350',\n 500: '#f44336',\n 600: '#e53935',\n 700: '#d32f2f',\n 800: '#c62828',\n 900: '#b71c1c',\n A100: '#ff8a80',\n A200: '#ff5252',\n A400: '#ff1744',\n A700: '#d50000'\n};\nexport default red;","const orange = {\n 50: '#fff3e0',\n 100: '#ffe0b2',\n 200: '#ffcc80',\n 300: '#ffb74d',\n 400: '#ffa726',\n 500: '#ff9800',\n 600: '#fb8c00',\n 700: '#f57c00',\n 800: '#ef6c00',\n 900: '#e65100',\n A100: '#ffd180',\n A200: '#ffab40',\n A400: '#ff9100',\n A700: '#ff6d00'\n};\nexport default orange;","const blue = {\n 50: '#e3f2fd',\n 100: '#bbdefb',\n 200: '#90caf9',\n 300: '#64b5f6',\n 400: '#42a5f5',\n 500: '#2196f3',\n 600: '#1e88e5',\n 700: '#1976d2',\n 800: '#1565c0',\n 900: '#0d47a1',\n A100: '#82b1ff',\n A200: '#448aff',\n A400: '#2979ff',\n A700: '#2962ff'\n};\nexport default blue;","const lightBlue = {\n 50: '#e1f5fe',\n 100: '#b3e5fc',\n 200: '#81d4fa',\n 300: '#4fc3f7',\n 400: '#29b6f6',\n 500: '#03a9f4',\n 600: '#039be5',\n 700: '#0288d1',\n 800: '#0277bd',\n 900: '#01579b',\n A100: '#80d8ff',\n A200: '#40c4ff',\n A400: '#00b0ff',\n A700: '#0091ea'\n};\nexport default lightBlue;","const green = {\n 50: '#e8f5e9',\n 100: '#c8e6c9',\n 200: '#a5d6a7',\n 300: '#81c784',\n 400: '#66bb6a',\n 500: '#4caf50',\n 600: '#43a047',\n 700: '#388e3c',\n 800: '#2e7d32',\n 900: '#1b5e20',\n A100: '#b9f6ca',\n A200: '#69f0ae',\n A400: '#00e676',\n A700: '#00c853'\n};\nexport default green;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\nconst _excluded = [\"mode\", \"contrastThreshold\", \"tonalOffset\"];\nimport { deepmerge } from '@mui/utils';\nimport { darken, getContrastRatio, lighten } from '@mui/system';\nimport common from '../colors/common';\nimport grey from '../colors/grey';\nimport purple from '../colors/purple';\nimport red from '../colors/red';\nimport orange from '../colors/orange';\nimport blue from '../colors/blue';\nimport lightBlue from '../colors/lightBlue';\nimport green from '../colors/green';\nexport const light = {\n // The colors used to style the text.\n text: {\n // The most important text.\n primary: 'rgba(0, 0, 0, 0.87)',\n // Secondary text.\n secondary: 'rgba(0, 0, 0, 0.6)',\n // Disabled text have even lower visual prominence.\n disabled: 'rgba(0, 0, 0, 0.38)'\n },\n // The color used to divide different elements.\n divider: 'rgba(0, 0, 0, 0.12)',\n // The background colors used to style the surfaces.\n // Consistency between these values is important.\n background: {\n paper: common.white,\n default: common.white\n },\n // The colors used to style the action elements.\n action: {\n // The color of an active action like an icon button.\n active: 'rgba(0, 0, 0, 0.54)',\n // The color of an hovered action.\n hover: 'rgba(0, 0, 0, 0.04)',\n hoverOpacity: 0.04,\n // The color of a selected action.\n selected: 'rgba(0, 0, 0, 0.08)',\n selectedOpacity: 0.08,\n // The color of a disabled action.\n disabled: 'rgba(0, 0, 0, 0.26)',\n // The background color of a disabled action.\n disabledBackground: 'rgba(0, 0, 0, 0.12)',\n disabledOpacity: 0.38,\n focus: 'rgba(0, 0, 0, 0.12)',\n focusOpacity: 0.12,\n activatedOpacity: 0.12\n }\n};\nexport const dark = {\n text: {\n primary: common.white,\n secondary: 'rgba(255, 255, 255, 0.7)',\n disabled: 'rgba(255, 255, 255, 0.5)',\n icon: 'rgba(255, 255, 255, 0.5)'\n },\n divider: 'rgba(255, 255, 255, 0.12)',\n background: {\n paper: '#121212',\n default: '#121212'\n },\n action: {\n active: common.white,\n hover: 'rgba(255, 255, 255, 0.08)',\n hoverOpacity: 0.08,\n selected: 'rgba(255, 255, 255, 0.16)',\n selectedOpacity: 0.16,\n disabled: 'rgba(255, 255, 255, 0.3)',\n disabledBackground: 'rgba(255, 255, 255, 0.12)',\n disabledOpacity: 0.38,\n focus: 'rgba(255, 255, 255, 0.12)',\n focusOpacity: 0.12,\n activatedOpacity: 0.24\n }\n};\nfunction addLightOrDark(intent, direction, shade, tonalOffset) {\n const tonalOffsetLight = tonalOffset.light || tonalOffset;\n const tonalOffsetDark = tonalOffset.dark || tonalOffset * 1.5;\n if (!intent[direction]) {\n if (intent.hasOwnProperty(shade)) {\n intent[direction] = intent[shade];\n } else if (direction === 'light') {\n intent.light = lighten(intent.main, tonalOffsetLight);\n } else if (direction === 'dark') {\n intent.dark = darken(intent.main, tonalOffsetDark);\n }\n }\n}\nfunction getDefaultPrimary(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: blue[200],\n light: blue[50],\n dark: blue[400]\n };\n }\n return {\n main: blue[700],\n light: blue[400],\n dark: blue[800]\n };\n}\nfunction getDefaultSecondary(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: purple[200],\n light: purple[50],\n dark: purple[400]\n };\n }\n return {\n main: purple[500],\n light: purple[300],\n dark: purple[700]\n };\n}\nfunction getDefaultError(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: red[500],\n light: red[300],\n dark: red[700]\n };\n }\n return {\n main: red[700],\n light: red[400],\n dark: red[800]\n };\n}\nfunction getDefaultInfo(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: lightBlue[400],\n light: lightBlue[300],\n dark: lightBlue[700]\n };\n }\n return {\n main: lightBlue[700],\n light: lightBlue[500],\n dark: lightBlue[900]\n };\n}\nfunction getDefaultSuccess(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: green[400],\n light: green[300],\n dark: green[700]\n };\n }\n return {\n main: green[800],\n light: green[500],\n dark: green[900]\n };\n}\nfunction getDefaultWarning(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: orange[400],\n light: orange[300],\n dark: orange[700]\n };\n }\n return {\n main: '#ed6c02',\n // closest to orange[800] that pass 3:1.\n light: orange[500],\n dark: orange[900]\n };\n}\nexport default function createPalette(palette) {\n const {\n mode = 'light',\n contrastThreshold = 3,\n tonalOffset = 0.2\n } = palette,\n other = _objectWithoutPropertiesLoose(palette, _excluded);\n const primary = palette.primary || getDefaultPrimary(mode);\n const secondary = palette.secondary || getDefaultSecondary(mode);\n const error = palette.error || getDefaultError(mode);\n const info = palette.info || getDefaultInfo(mode);\n const success = palette.success || getDefaultSuccess(mode);\n const warning = palette.warning || getDefaultWarning(mode);\n\n // Use the same logic as\n // Bootstrap: https://github.com/twbs/bootstrap/blob/1d6e3710dd447de1a200f29e8fa521f8a0908f70/scss/_functions.scss#L59\n // and material-components-web https://github.com/material-components/material-components-web/blob/ac46b8863c4dab9fc22c4c662dc6bd1b65dd652f/packages/mdc-theme/_functions.scss#L54\n function getContrastText(background) {\n const contrastText = getContrastRatio(background, dark.text.primary) >= contrastThreshold ? dark.text.primary : light.text.primary;\n if (process.env.NODE_ENV !== 'production') {\n const contrast = getContrastRatio(background, contrastText);\n if (contrast < 3) {\n console.error([`MUI: The contrast ratio of ${contrast}:1 for ${contrastText} on ${background}`, 'falls below the WCAG recommended absolute minimum contrast ratio of 3:1.', 'https://www.w3.org/TR/2008/REC-WCAG20-20081211/#visual-audio-contrast-contrast'].join('\\n'));\n }\n }\n return contrastText;\n }\n const augmentColor = ({\n color,\n name,\n mainShade = 500,\n lightShade = 300,\n darkShade = 700\n }) => {\n color = _extends({}, color);\n if (!color.main && color[mainShade]) {\n color.main = color[mainShade];\n }\n if (!color.hasOwnProperty('main')) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: The color${name ? ` (${name})` : ''} provided to augmentColor(color) is invalid.\nThe color object needs to have a \\`main\\` property or a \\`${mainShade}\\` property.` : _formatMuiErrorMessage(11, name ? ` (${name})` : '', mainShade));\n }\n if (typeof color.main !== 'string') {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: The color${name ? ` (${name})` : ''} provided to augmentColor(color) is invalid.\n\\`color.main\\` should be a string, but \\`${JSON.stringify(color.main)}\\` was provided instead.\n\nDid you intend to use one of the following approaches?\n\nimport { green } from \"@mui/material/colors\";\n\nconst theme1 = createTheme({ palette: {\n primary: green,\n} });\n\nconst theme2 = createTheme({ palette: {\n primary: { main: green[500] },\n} });` : _formatMuiErrorMessage(12, name ? ` (${name})` : '', JSON.stringify(color.main)));\n }\n addLightOrDark(color, 'light', lightShade, tonalOffset);\n addLightOrDark(color, 'dark', darkShade, tonalOffset);\n if (!color.contrastText) {\n color.contrastText = getContrastText(color.main);\n }\n return color;\n };\n const modes = {\n dark,\n light\n };\n if (process.env.NODE_ENV !== 'production') {\n if (!modes[mode]) {\n console.error(`MUI: The palette mode \\`${mode}\\` is not supported.`);\n }\n }\n const paletteOutput = deepmerge(_extends({\n // A collection of common colors.\n common: _extends({}, common),\n // prevent mutable object.\n // The palette mode, can be light or dark.\n mode,\n // The colors used to represent primary interface elements for a user.\n primary: augmentColor({\n color: primary,\n name: 'primary'\n }),\n // The colors used to represent secondary interface elements for a user.\n secondary: augmentColor({\n color: secondary,\n name: 'secondary',\n mainShade: 'A400',\n lightShade: 'A200',\n darkShade: 'A700'\n }),\n // The colors used to represent interface elements that the user should be made aware of.\n error: augmentColor({\n color: error,\n name: 'error'\n }),\n // The colors used to represent potentially dangerous actions or important messages.\n warning: augmentColor({\n color: warning,\n name: 'warning'\n }),\n // The colors used to present information to the user that is neutral and not necessarily important.\n info: augmentColor({\n color: info,\n name: 'info'\n }),\n // The colors used to indicate the successful completion of an action that user triggered.\n success: augmentColor({\n color: success,\n name: 'success'\n }),\n // The grey colors.\n grey,\n // Used by `getContrastText()` to maximize the contrast between\n // the background and the text.\n contrastThreshold,\n // Takes a background color and returns the text color that maximizes the contrast.\n getContrastText,\n // Generate a rich color object.\n augmentColor,\n // Used by the functions below to shift a color's luminance by approximately\n // two indexes within its tonal palette.\n // E.g., shift from Red 500 to Red 300 or Red 700.\n tonalOffset\n }, modes[mode]), other);\n return paletteOutput;\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"fontFamily\", \"fontSize\", \"fontWeightLight\", \"fontWeightRegular\", \"fontWeightMedium\", \"fontWeightBold\", \"htmlFontSize\", \"allVariants\", \"pxToRem\"];\nimport { deepmerge } from '@mui/utils';\nfunction round(value) {\n return Math.round(value * 1e5) / 1e5;\n}\nconst caseAllCaps = {\n textTransform: 'uppercase'\n};\nconst defaultFontFamily = '\"Roboto\", \"Helvetica\", \"Arial\", sans-serif';\n\n/**\n * @see @link{https://m2.material.io/design/typography/the-type-system.html}\n * @see @link{https://m2.material.io/design/typography/understanding-typography.html}\n */\nexport default function createTypography(palette, typography) {\n const _ref = typeof typography === 'function' ? typography(palette) : typography,\n {\n fontFamily = defaultFontFamily,\n // The default font size of the Material Specification.\n fontSize = 14,\n // px\n fontWeightLight = 300,\n fontWeightRegular = 400,\n fontWeightMedium = 500,\n fontWeightBold = 700,\n // Tell MUI what's the font-size on the html element.\n // 16px is the default font-size used by browsers.\n htmlFontSize = 16,\n // Apply the CSS properties to all the variants.\n allVariants,\n pxToRem: pxToRem2\n } = _ref,\n other = _objectWithoutPropertiesLoose(_ref, _excluded);\n if (process.env.NODE_ENV !== 'production') {\n if (typeof fontSize !== 'number') {\n console.error('MUI: `fontSize` is required to be a number.');\n }\n if (typeof htmlFontSize !== 'number') {\n console.error('MUI: `htmlFontSize` is required to be a number.');\n }\n }\n const coef = fontSize / 14;\n const pxToRem = pxToRem2 || (size => `${size / htmlFontSize * coef}rem`);\n const buildVariant = (fontWeight, size, lineHeight, letterSpacing, casing) => _extends({\n fontFamily,\n fontWeight,\n fontSize: pxToRem(size),\n // Unitless following https://meyerweb.com/eric/thoughts/2006/02/08/unitless-line-heights/\n lineHeight\n }, fontFamily === defaultFontFamily ? {\n letterSpacing: `${round(letterSpacing / size)}em`\n } : {}, casing, allVariants);\n const variants = {\n h1: buildVariant(fontWeightLight, 96, 1.167, -1.5),\n h2: buildVariant(fontWeightLight, 60, 1.2, -0.5),\n h3: buildVariant(fontWeightRegular, 48, 1.167, 0),\n h4: buildVariant(fontWeightRegular, 34, 1.235, 0.25),\n h5: buildVariant(fontWeightRegular, 24, 1.334, 0),\n h6: buildVariant(fontWeightMedium, 20, 1.6, 0.15),\n subtitle1: buildVariant(fontWeightRegular, 16, 1.75, 0.15),\n subtitle2: buildVariant(fontWeightMedium, 14, 1.57, 0.1),\n body1: buildVariant(fontWeightRegular, 16, 1.5, 0.15),\n body2: buildVariant(fontWeightRegular, 14, 1.43, 0.15),\n button: buildVariant(fontWeightMedium, 14, 1.75, 0.4, caseAllCaps),\n caption: buildVariant(fontWeightRegular, 12, 1.66, 0.4),\n overline: buildVariant(fontWeightRegular, 12, 2.66, 1, caseAllCaps),\n // TODO v6: Remove handling of 'inherit' variant from the theme as it is already handled in Material UI's Typography component. Also, remember to remove the associated types.\n inherit: {\n fontFamily: 'inherit',\n fontWeight: 'inherit',\n fontSize: 'inherit',\n lineHeight: 'inherit',\n letterSpacing: 'inherit'\n }\n };\n return deepmerge(_extends({\n htmlFontSize,\n pxToRem,\n fontFamily,\n fontSize,\n fontWeightLight,\n fontWeightRegular,\n fontWeightMedium,\n fontWeightBold\n }, variants), other, {\n clone: false // No need to clone deep\n });\n}","const shadowKeyUmbraOpacity = 0.2;\nconst shadowKeyPenumbraOpacity = 0.14;\nconst shadowAmbientShadowOpacity = 0.12;\nfunction createShadow(...px) {\n return [`${px[0]}px ${px[1]}px ${px[2]}px ${px[3]}px rgba(0,0,0,${shadowKeyUmbraOpacity})`, `${px[4]}px ${px[5]}px ${px[6]}px ${px[7]}px rgba(0,0,0,${shadowKeyPenumbraOpacity})`, `${px[8]}px ${px[9]}px ${px[10]}px ${px[11]}px rgba(0,0,0,${shadowAmbientShadowOpacity})`].join(',');\n}\n\n// Values from https://github.com/material-components/material-components-web/blob/be8747f94574669cb5e7add1a7c54fa41a89cec7/packages/mdc-elevation/_variables.scss\nconst shadows = ['none', createShadow(0, 2, 1, -1, 0, 1, 1, 0, 0, 1, 3, 0), createShadow(0, 3, 1, -2, 0, 2, 2, 0, 0, 1, 5, 0), createShadow(0, 3, 3, -2, 0, 3, 4, 0, 0, 1, 8, 0), createShadow(0, 2, 4, -1, 0, 4, 5, 0, 0, 1, 10, 0), createShadow(0, 3, 5, -1, 0, 5, 8, 0, 0, 1, 14, 0), createShadow(0, 3, 5, -1, 0, 6, 10, 0, 0, 1, 18, 0), createShadow(0, 4, 5, -2, 0, 7, 10, 1, 0, 2, 16, 1), createShadow(0, 5, 5, -3, 0, 8, 10, 1, 0, 3, 14, 2), createShadow(0, 5, 6, -3, 0, 9, 12, 1, 0, 3, 16, 2), createShadow(0, 6, 6, -3, 0, 10, 14, 1, 0, 4, 18, 3), createShadow(0, 6, 7, -4, 0, 11, 15, 1, 0, 4, 20, 3), createShadow(0, 7, 8, -4, 0, 12, 17, 2, 0, 5, 22, 4), createShadow(0, 7, 8, -4, 0, 13, 19, 2, 0, 5, 24, 4), createShadow(0, 7, 9, -4, 0, 14, 21, 2, 0, 5, 26, 4), createShadow(0, 8, 9, -5, 0, 15, 22, 2, 0, 6, 28, 5), createShadow(0, 8, 10, -5, 0, 16, 24, 2, 0, 6, 30, 5), createShadow(0, 8, 11, -5, 0, 17, 26, 2, 0, 6, 32, 5), createShadow(0, 9, 11, -5, 0, 18, 28, 2, 0, 7, 34, 6), createShadow(0, 9, 12, -6, 0, 19, 29, 2, 0, 7, 36, 6), createShadow(0, 10, 13, -6, 0, 20, 31, 3, 0, 8, 38, 7), createShadow(0, 10, 13, -6, 0, 21, 33, 3, 0, 8, 40, 7), createShadow(0, 10, 14, -6, 0, 22, 35, 3, 0, 8, 42, 7), createShadow(0, 11, 14, -7, 0, 23, 36, 3, 0, 9, 44, 8), createShadow(0, 11, 15, -7, 0, 24, 38, 3, 0, 9, 46, 8)];\nexport default shadows;","import _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nconst _excluded = [\"duration\", \"easing\", \"delay\"];\n// Follow https://material.google.com/motion/duration-easing.html#duration-easing-natural-easing-curves\n// to learn the context in which each easing should be used.\nexport const easing = {\n // This is the most common easing curve.\n easeInOut: 'cubic-bezier(0.4, 0, 0.2, 1)',\n // Objects enter the screen at full velocity from off-screen and\n // slowly decelerate to a resting point.\n easeOut: 'cubic-bezier(0.0, 0, 0.2, 1)',\n // Objects leave the screen at full velocity. They do not decelerate when off-screen.\n easeIn: 'cubic-bezier(0.4, 0, 1, 1)',\n // The sharp curve is used by objects that may return to the screen at any time.\n sharp: 'cubic-bezier(0.4, 0, 0.6, 1)'\n};\n\n// Follow https://m2.material.io/guidelines/motion/duration-easing.html#duration-easing-common-durations\n// to learn when use what timing\nexport const duration = {\n shortest: 150,\n shorter: 200,\n short: 250,\n // most basic recommended timing\n standard: 300,\n // this is to be used in complex animations\n complex: 375,\n // recommended when something is entering screen\n enteringScreen: 225,\n // recommended when something is leaving screen\n leavingScreen: 195\n};\nfunction formatMs(milliseconds) {\n return `${Math.round(milliseconds)}ms`;\n}\nfunction getAutoHeightDuration(height) {\n if (!height) {\n return 0;\n }\n const constant = height / 36;\n\n // https://www.wolframalpha.com/input/?i=(4+%2B+15+*+(x+%2F+36+)+**+0.25+%2B+(x+%2F+36)+%2F+5)+*+10\n return Math.round((4 + 15 * constant ** 0.25 + constant / 5) * 10);\n}\nexport default function createTransitions(inputTransitions) {\n const mergedEasing = _extends({}, easing, inputTransitions.easing);\n const mergedDuration = _extends({}, duration, inputTransitions.duration);\n const create = (props = ['all'], options = {}) => {\n const {\n duration: durationOption = mergedDuration.standard,\n easing: easingOption = mergedEasing.easeInOut,\n delay = 0\n } = options,\n other = _objectWithoutPropertiesLoose(options, _excluded);\n if (process.env.NODE_ENV !== 'production') {\n const isString = value => typeof value === 'string';\n // IE11 support, replace with Number.isNaN\n // eslint-disable-next-line no-restricted-globals\n const isNumber = value => !isNaN(parseFloat(value));\n if (!isString(props) && !Array.isArray(props)) {\n console.error('MUI: Argument \"props\" must be a string or Array.');\n }\n if (!isNumber(durationOption) && !isString(durationOption)) {\n console.error(`MUI: Argument \"duration\" must be a number or a string but found ${durationOption}.`);\n }\n if (!isString(easingOption)) {\n console.error('MUI: Argument \"easing\" must be a string.');\n }\n if (!isNumber(delay) && !isString(delay)) {\n console.error('MUI: Argument \"delay\" must be a number or a string.');\n }\n if (typeof options !== 'object') {\n console.error(['MUI: Secong argument of transition.create must be an object.', \"Arguments should be either `create('prop1', options)` or `create(['prop1', 'prop2'], options)`\"].join('\\n'));\n }\n if (Object.keys(other).length !== 0) {\n console.error(`MUI: Unrecognized argument(s) [${Object.keys(other).join(',')}].`);\n }\n }\n return (Array.isArray(props) ? props : [props]).map(animatedProp => `${animatedProp} ${typeof durationOption === 'string' ? durationOption : formatMs(durationOption)} ${easingOption} ${typeof delay === 'string' ? delay : formatMs(delay)}`).join(',');\n };\n return _extends({\n getAutoHeightDuration,\n create\n }, inputTransitions, {\n easing: mergedEasing,\n duration: mergedDuration\n });\n}","// We need to centralize the zIndex definitions as they work\n// like global values in the browser.\nconst zIndex = {\n mobileStepper: 1000,\n fab: 1050,\n speedDial: 1050,\n appBar: 1100,\n drawer: 1200,\n modal: 1300,\n snackbar: 1400,\n tooltip: 1500\n};\nexport default zIndex;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\nconst _excluded = [\"breakpoints\", \"mixins\", \"spacing\", \"palette\", \"transitions\", \"typography\", \"shape\"];\nimport { deepmerge } from '@mui/utils';\nimport { createTheme as systemCreateTheme, unstable_defaultSxConfig as defaultSxConfig, unstable_styleFunctionSx as styleFunctionSx } from '@mui/system';\nimport generateUtilityClass from '@mui/utils/generateUtilityClass';\nimport createMixins from './createMixins';\nimport createPalette from './createPalette';\nimport createTypography from './createTypography';\nimport shadows from './shadows';\nimport createTransitions from './createTransitions';\nimport zIndex from './zIndex';\nfunction createTheme(options = {}, ...args) {\n const {\n mixins: mixinsInput = {},\n palette: paletteInput = {},\n transitions: transitionsInput = {},\n typography: typographyInput = {}\n } = options,\n other = _objectWithoutPropertiesLoose(options, _excluded);\n if (options.vars) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: \\`vars\\` is a private field used for CSS variables support.\nPlease use another name.` : _formatMuiErrorMessage(18));\n }\n const palette = createPalette(paletteInput);\n const systemTheme = systemCreateTheme(options);\n let muiTheme = deepmerge(systemTheme, {\n mixins: createMixins(systemTheme.breakpoints, mixinsInput),\n palette,\n // Don't use [...shadows] until you've verified its transpiled code is not invoking the iterator protocol.\n shadows: shadows.slice(),\n typography: createTypography(palette, typographyInput),\n transitions: createTransitions(transitionsInput),\n zIndex: _extends({}, zIndex)\n });\n muiTheme = deepmerge(muiTheme, other);\n muiTheme = args.reduce((acc, argument) => deepmerge(acc, argument), muiTheme);\n if (process.env.NODE_ENV !== 'production') {\n // TODO v6: Refactor to use globalStateClassesMapping from @mui/utils once `readOnly` state class is used in Rating component.\n const stateClasses = ['active', 'checked', 'completed', 'disabled', 'error', 'expanded', 'focused', 'focusVisible', 'required', 'selected'];\n const traverse = (node, component) => {\n let key;\n\n // eslint-disable-next-line guard-for-in, no-restricted-syntax\n for (key in node) {\n const child = node[key];\n if (stateClasses.indexOf(key) !== -1 && Object.keys(child).length > 0) {\n if (process.env.NODE_ENV !== 'production') {\n const stateClass = generateUtilityClass('', key);\n console.error([`MUI: The \\`${component}\\` component increases ` + `the CSS specificity of the \\`${key}\\` internal state.`, 'You can not override it like this: ', JSON.stringify(node, null, 2), '', `Instead, you need to use the '&.${stateClass}' syntax:`, JSON.stringify({\n root: {\n [`&.${stateClass}`]: child\n }\n }, null, 2), '', 'https://mui.com/r/state-classes-guide'].join('\\n'));\n }\n // Remove the style to prevent global conflicts.\n node[key] = {};\n }\n }\n };\n Object.keys(muiTheme.components).forEach(component => {\n const styleOverrides = muiTheme.components[component].styleOverrides;\n if (styleOverrides && component.indexOf('Mui') === 0) {\n traverse(styleOverrides, component);\n }\n });\n }\n muiTheme.unstable_sxConfig = _extends({}, defaultSxConfig, other == null ? void 0 : other.unstable_sxConfig);\n muiTheme.unstable_sx = function sx(props) {\n return styleFunctionSx({\n sx: props,\n theme: this\n });\n };\n return muiTheme;\n}\nlet warnedOnce = false;\nexport function createMuiTheme(...args) {\n if (process.env.NODE_ENV !== 'production') {\n if (!warnedOnce) {\n warnedOnce = true;\n console.error(['MUI: the createMuiTheme function was renamed to createTheme.', '', \"You should use `import { createTheme } from '@mui/material/styles'`\"].join('\\n'));\n }\n }\n return createTheme(...args);\n}\nexport default createTheme;","'use client';\n\nimport createTheme from './createTheme';\nconst defaultTheme = createTheme();\nexport default defaultTheme;","export default '$$material';","'use client';\n\nimport { useThemeProps as systemUseThemeProps } from '@mui/system';\nimport defaultTheme from './defaultTheme';\nimport THEME_ID from './identifier';\nexport default function useThemeProps({\n props,\n name\n}) {\n return systemUseThemeProps({\n props,\n name,\n defaultTheme,\n themeId: THEME_ID\n });\n}","'use client';\n\nimport { createStyled, shouldForwardProp } from '@mui/system';\nimport defaultTheme from './defaultTheme';\nimport THEME_ID from './identifier';\nexport const rootShouldForwardProp = prop => shouldForwardProp(prop) && prop !== 'classes';\nexport const slotShouldForwardProp = shouldForwardProp;\nconst styled = createStyled({\n themeId: THEME_ID,\n defaultTheme,\n rootShouldForwardProp\n});\nexport default styled;","import generateUtilityClasses from '@mui/utils/generateUtilityClasses';\nimport generateUtilityClass from '@mui/utils/generateUtilityClass';\nexport function getSvgIconUtilityClass(slot) {\n return generateUtilityClass('MuiSvgIcon', slot);\n}\nconst svgIconClasses = generateUtilityClasses('MuiSvgIcon', ['root', 'colorPrimary', 'colorSecondary', 'colorAction', 'colorError', 'colorDisabled', 'fontSizeInherit', 'fontSizeSmall', 'fontSizeMedium', 'fontSizeLarge']);\nexport default svgIconClasses;","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"children\", \"className\", \"color\", \"component\", \"fontSize\", \"htmlColor\", \"inheritViewBox\", \"titleAccess\", \"viewBox\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport clsx from 'clsx';\nimport { unstable_composeClasses as composeClasses } from '@mui/base/composeClasses';\nimport capitalize from '../utils/capitalize';\nimport useThemeProps from '../styles/useThemeProps';\nimport styled from '../styles/styled';\nimport { getSvgIconUtilityClass } from './svgIconClasses';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nimport { jsxs as _jsxs } from \"react/jsx-runtime\";\nconst useUtilityClasses = ownerState => {\n const {\n color,\n fontSize,\n classes\n } = ownerState;\n const slots = {\n root: ['root', color !== 'inherit' && `color${capitalize(color)}`, `fontSize${capitalize(fontSize)}`]\n };\n return composeClasses(slots, getSvgIconUtilityClass, classes);\n};\nconst SvgIconRoot = styled('svg', {\n name: 'MuiSvgIcon',\n slot: 'Root',\n overridesResolver: (props, styles) => {\n const {\n ownerState\n } = props;\n return [styles.root, ownerState.color !== 'inherit' && styles[`color${capitalize(ownerState.color)}`], styles[`fontSize${capitalize(ownerState.fontSize)}`]];\n }\n})(({\n theme,\n ownerState\n}) => {\n var _theme$transitions, _theme$transitions$cr, _theme$transitions2, _theme$typography, _theme$typography$pxT, _theme$typography2, _theme$typography2$px, _theme$typography3, _theme$typography3$px, _palette$ownerState$c, _palette, _palette2, _palette3;\n return {\n userSelect: 'none',\n width: '1em',\n height: '1em',\n display: 'inline-block',\n // the will define the property that has `currentColor`\n // e.g. heroicons uses fill=\"none\" and stroke=\"currentColor\"\n fill: ownerState.hasSvgAsChild ? undefined : 'currentColor',\n flexShrink: 0,\n transition: (_theme$transitions = theme.transitions) == null || (_theme$transitions$cr = _theme$transitions.create) == null ? void 0 : _theme$transitions$cr.call(_theme$transitions, 'fill', {\n duration: (_theme$transitions2 = theme.transitions) == null || (_theme$transitions2 = _theme$transitions2.duration) == null ? void 0 : _theme$transitions2.shorter\n }),\n fontSize: {\n inherit: 'inherit',\n small: ((_theme$typography = theme.typography) == null || (_theme$typography$pxT = _theme$typography.pxToRem) == null ? void 0 : _theme$typography$pxT.call(_theme$typography, 20)) || '1.25rem',\n medium: ((_theme$typography2 = theme.typography) == null || (_theme$typography2$px = _theme$typography2.pxToRem) == null ? void 0 : _theme$typography2$px.call(_theme$typography2, 24)) || '1.5rem',\n large: ((_theme$typography3 = theme.typography) == null || (_theme$typography3$px = _theme$typography3.pxToRem) == null ? void 0 : _theme$typography3$px.call(_theme$typography3, 35)) || '2.1875rem'\n }[ownerState.fontSize],\n // TODO v5 deprecate, v6 remove for sx\n color: (_palette$ownerState$c = (_palette = (theme.vars || theme).palette) == null || (_palette = _palette[ownerState.color]) == null ? void 0 : _palette.main) != null ? _palette$ownerState$c : {\n action: (_palette2 = (theme.vars || theme).palette) == null || (_palette2 = _palette2.action) == null ? void 0 : _palette2.active,\n disabled: (_palette3 = (theme.vars || theme).palette) == null || (_palette3 = _palette3.action) == null ? void 0 : _palette3.disabled,\n inherit: undefined\n }[ownerState.color]\n };\n});\nconst SvgIcon = /*#__PURE__*/React.forwardRef(function SvgIcon(inProps, ref) {\n const props = useThemeProps({\n props: inProps,\n name: 'MuiSvgIcon'\n });\n const {\n children,\n className,\n color = 'inherit',\n component = 'svg',\n fontSize = 'medium',\n htmlColor,\n inheritViewBox = false,\n titleAccess,\n viewBox = '0 0 24 24'\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const hasSvgAsChild = /*#__PURE__*/React.isValidElement(children) && children.type === 'svg';\n const ownerState = _extends({}, props, {\n color,\n component,\n fontSize,\n instanceFontSize: inProps.fontSize,\n inheritViewBox,\n viewBox,\n hasSvgAsChild\n });\n const more = {};\n if (!inheritViewBox) {\n more.viewBox = viewBox;\n }\n const classes = useUtilityClasses(ownerState);\n return /*#__PURE__*/_jsxs(SvgIconRoot, _extends({\n as: component,\n className: clsx(classes.root, className),\n focusable: \"false\",\n color: htmlColor,\n \"aria-hidden\": titleAccess ? undefined : true,\n role: titleAccess ? 'img' : undefined,\n ref: ref\n }, more, other, hasSvgAsChild && children.props, {\n ownerState: ownerState,\n children: [hasSvgAsChild ? children.props.children : children, titleAccess ? /*#__PURE__*/_jsx(\"title\", {\n children: titleAccess\n }) : null]\n }));\n});\nprocess.env.NODE_ENV !== \"production\" ? SvgIcon.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the d.ts file and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * Node passed into the SVG element.\n */\n children: PropTypes.node,\n /**\n * Override or extend the styles applied to the component.\n */\n classes: PropTypes.object,\n /**\n * @ignore\n */\n className: PropTypes.string,\n /**\n * The color of the component.\n * It supports both default and custom theme colors, which can be added as shown in the\n * [palette customization guide](https://mui.com/material-ui/customization/palette/#custom-colors).\n * You can use the `htmlColor` prop to apply a color attribute to the SVG element.\n * @default 'inherit'\n */\n color: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.oneOf(['inherit', 'action', 'disabled', 'primary', 'secondary', 'error', 'info', 'success', 'warning']), PropTypes.string]),\n /**\n * The component used for the root node.\n * Either a string to use a HTML element or a component.\n */\n component: PropTypes.elementType,\n /**\n * The fontSize applied to the icon. Defaults to 24px, but can be configure to inherit font size.\n * @default 'medium'\n */\n fontSize: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.oneOf(['inherit', 'large', 'medium', 'small']), PropTypes.string]),\n /**\n * Applies a color attribute to the SVG element.\n */\n htmlColor: PropTypes.string,\n /**\n * If `true`, the root node will inherit the custom `component`'s viewBox and the `viewBox`\n * prop will be ignored.\n * Useful when you want to reference a custom `component` and have `SvgIcon` pass that\n * `component`'s viewBox to the root node.\n * @default false\n */\n inheritViewBox: PropTypes.bool,\n /**\n * The shape-rendering attribute. The behavior of the different options is described on the\n * [MDN Web Docs](https://developer.mozilla.org/en-US/docs/Web/SVG/Attribute/shape-rendering).\n * If you are having issues with blurry icons you should investigate this prop.\n */\n shapeRendering: PropTypes.string,\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Provides a human-readable title for the element that contains it.\n * https://www.w3.org/TR/SVG-access/#Equivalent\n */\n titleAccess: PropTypes.string,\n /**\n * Allows you to redefine what the coordinates without units mean inside an SVG element.\n * For example, if the SVG element is 500 (width) by 200 (height),\n * and you pass viewBox=\"0 0 50 20\",\n * this means that the coordinates inside the SVG will go from the top left corner (0,0)\n * to bottom right (50,20) and each unit will be worth 10px.\n * @default '0 0 24 24'\n */\n viewBox: PropTypes.string\n} : void 0;\nSvgIcon.muiName = 'SvgIcon';\nexport default SvgIcon;","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport * as React from 'react';\nimport SvgIcon from '../SvgIcon';\n\n/**\n * Private module reserved for @mui packages.\n */\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nexport default function createSvgIcon(path, displayName) {\n function Component(props, ref) {\n return /*#__PURE__*/_jsx(SvgIcon, _extends({\n \"data-testid\": `${displayName}Icon`,\n ref: ref\n }, props, {\n children: path\n }));\n }\n if (process.env.NODE_ENV !== 'production') {\n // Need to set `displayName` on the inner component for React.memo.\n // React prior to 16.14 ignores `displayName` on the wrapper.\n Component.displayName = `${displayName}Icon`;\n }\n Component.muiName = SvgIcon.muiName;\n return /*#__PURE__*/React.memo( /*#__PURE__*/React.forwardRef(Component));\n}","'use client';\n\nimport { unstable_ClassNameGenerator as ClassNameGenerator } from '@mui/base/ClassNameGenerator';\nexport { default as capitalize } from './capitalize';\nexport { default as createChainedFunction } from './createChainedFunction';\nexport { default as createSvgIcon } from './createSvgIcon';\nexport { default as debounce } from './debounce';\nexport { default as deprecatedPropType } from './deprecatedPropType';\nexport { default as isMuiElement } from './isMuiElement';\nexport { default as ownerDocument } from './ownerDocument';\nexport { default as ownerWindow } from './ownerWindow';\nexport { default as requirePropFactory } from './requirePropFactory';\nexport { default as setRef } from './setRef';\nexport { default as unstable_useEnhancedEffect } from './useEnhancedEffect';\nexport { default as unstable_useId } from './useId';\nexport { default as unsupportedProp } from './unsupportedProp';\nexport { default as useControlled } from './useControlled';\nexport { default as useEventCallback } from './useEventCallback';\nexport { default as useForkRef } from './useForkRef';\nexport { default as useIsFocusVisible } from './useIsFocusVisible';\n// TODO: remove this export once ClassNameGenerator is stable\n// eslint-disable-next-line @typescript-eslint/naming-convention\nexport const unstable_ClassNameGenerator = {\n configure: generator => {\n if (process.env.NODE_ENV !== 'production') {\n console.warn(['MUI: `ClassNameGenerator` import from `@mui/material/utils` is outdated and might cause unexpected issues.', '', \"You should use `import { unstable_ClassNameGenerator } from '@mui/material/className'` instead\", '', 'The detail of the issue: https://github.com/mui/material-ui/issues/30011#issuecomment-1024993401', '', 'The updated documentation: https://mui.com/guides/classname-generator/'].join('\\n'));\n }\n ClassNameGenerator.configure(generator);\n }\n};","\"use strict\";\n'use client';\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nObject.defineProperty(exports, \"default\", {\n enumerable: true,\n get: function () {\n return _utils.createSvgIcon;\n }\n});\nvar _utils = require(\"@mui/material/utils\");","\"use strict\";\n\"use client\";\n\nvar _interopRequireDefault = require(\"@babel/runtime/helpers/interopRequireDefault\");\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = void 0;\nvar _createSvgIcon = _interopRequireDefault(require(\"./utils/createSvgIcon\"));\nvar _jsxRuntime = require(\"react/jsx-runtime\");\nvar _default = exports.default = (0, _createSvgIcon.default)( /*#__PURE__*/(0, _jsxRuntime.jsx)(\"path\", {\n d: \"m10 17 5-5-5-5z\"\n}), 'ArrowRight');","/**\n * Determines if a given element is a DOM element name (i.e. not a React component).\n */\nexport function isHostComponent(element) {\n return typeof element === 'string';\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport { isHostComponent } from './isHostComponent';\n\n/**\n * Type of the ownerState based on the type of an element it applies to.\n * This resolves to the provided OwnerState for React components and `undefined` for host components.\n * Falls back to `OwnerState | undefined` when the exact type can't be determined in development time.\n */\n\n/**\n * Appends the ownerState object to the props, merging with the existing one if necessary.\n *\n * @param elementType Type of the element that owns the `existingProps`. If the element is a DOM node or undefined, `ownerState` is not applied.\n * @param otherProps Props of the element.\n * @param ownerState\n */\nexport function appendOwnerState(elementType, otherProps, ownerState) {\n if (elementType === undefined || isHostComponent(elementType)) {\n return otherProps;\n }\n return _extends({}, otherProps, {\n ownerState: _extends({}, otherProps.ownerState, ownerState)\n });\n}","'use client';\n\nimport * as React from 'react';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nconst defaultContextValue = {\n disableDefaultClasses: false\n};\nconst ClassNameConfiguratorContext = /*#__PURE__*/React.createContext(defaultContextValue);\n/**\n * @ignore - internal hook.\n *\n * Wraps the `generateUtilityClass` function and controls how the classes are generated.\n * Currently it only affects whether the classes are applied or not.\n *\n * @returns Function to be called with the `generateUtilityClass` function specific to a component to generate the classes.\n */\nexport function useClassNamesOverride(generateUtilityClass) {\n const {\n disableDefaultClasses\n } = React.useContext(ClassNameConfiguratorContext);\n return slot => {\n if (disableDefaultClasses) {\n return '';\n }\n return generateUtilityClass(slot);\n };\n}\n\n/**\n * Allows to configure the components within to not apply any built-in classes.\n */\nexport function ClassNameConfigurator(props) {\n const {\n disableDefaultClasses,\n children\n } = props;\n const contextValue = React.useMemo(() => ({\n disableDefaultClasses: disableDefaultClasses != null ? disableDefaultClasses : false\n }), [disableDefaultClasses]);\n return /*#__PURE__*/_jsx(ClassNameConfiguratorContext.Provider, {\n value: contextValue,\n children: children\n });\n}","/**\n * Extracts event handlers from a given object.\n * A prop is considered an event handler if it is a function and its name starts with `on`.\n *\n * @param object An object to extract event handlers from.\n * @param excludeKeys An array of keys to exclude from the returned object.\n */\nexport function extractEventHandlers(object, excludeKeys = []) {\n if (object === undefined) {\n return {};\n }\n const result = {};\n Object.keys(object).filter(prop => prop.match(/^on[A-Z]/) && typeof object[prop] === 'function' && !excludeKeys.includes(prop)).forEach(prop => {\n result[prop] = object[prop];\n });\n return result;\n}","/**\n * If `componentProps` is a function, calls it with the provided `ownerState`.\n * Otherwise, just returns `componentProps`.\n */\nexport function resolveComponentProps(componentProps, ownerState, slotState) {\n if (typeof componentProps === 'function') {\n return componentProps(ownerState, slotState);\n }\n return componentProps;\n}","/**\n * Removes event handlers from the given object.\n * A field is considered an event handler if it is a function with a name beginning with `on`.\n *\n * @param object Object to remove event handlers from.\n * @returns Object with event handlers removed.\n */\nexport function omitEventHandlers(object) {\n if (object === undefined) {\n return {};\n }\n const result = {};\n Object.keys(object).filter(prop => !(prop.match(/^on[A-Z]/) && typeof object[prop] === 'function')).forEach(prop => {\n result[prop] = object[prop];\n });\n return result;\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport clsx from 'clsx';\nimport { extractEventHandlers } from './extractEventHandlers';\nimport { omitEventHandlers } from './omitEventHandlers';\n/**\n * Merges the slot component internal props (usually coming from a hook)\n * with the externally provided ones.\n *\n * The merge order is (the latter overrides the former):\n * 1. The internal props (specified as a getter function to work with get*Props hook result)\n * 2. Additional props (specified internally on a Base UI component)\n * 3. External props specified on the owner component. These should only be used on a root slot.\n * 4. External props specified in the `slotProps.*` prop.\n * 5. The `className` prop - combined from all the above.\n * @param parameters\n * @returns\n */\nexport function mergeSlotProps(parameters) {\n const {\n getSlotProps,\n additionalProps,\n externalSlotProps,\n externalForwardedProps,\n className\n } = parameters;\n if (!getSlotProps) {\n // The simpler case - getSlotProps is not defined, so no internal event handlers are defined,\n // so we can simply merge all the props without having to worry about extracting event handlers.\n const joinedClasses = clsx(additionalProps == null ? void 0 : additionalProps.className, className, externalForwardedProps == null ? void 0 : externalForwardedProps.className, externalSlotProps == null ? void 0 : externalSlotProps.className);\n const mergedStyle = _extends({}, additionalProps == null ? void 0 : additionalProps.style, externalForwardedProps == null ? void 0 : externalForwardedProps.style, externalSlotProps == null ? void 0 : externalSlotProps.style);\n const props = _extends({}, additionalProps, externalForwardedProps, externalSlotProps);\n if (joinedClasses.length > 0) {\n props.className = joinedClasses;\n }\n if (Object.keys(mergedStyle).length > 0) {\n props.style = mergedStyle;\n }\n return {\n props,\n internalRef: undefined\n };\n }\n\n // In this case, getSlotProps is responsible for calling the external event handlers.\n // We don't need to include them in the merged props because of this.\n\n const eventHandlers = extractEventHandlers(_extends({}, externalForwardedProps, externalSlotProps));\n const componentsPropsWithoutEventHandlers = omitEventHandlers(externalSlotProps);\n const otherPropsWithoutEventHandlers = omitEventHandlers(externalForwardedProps);\n const internalSlotProps = getSlotProps(eventHandlers);\n\n // The order of classes is important here.\n // Emotion (that we use in libraries consuming Base UI) depends on this order\n // to properly override style. It requires the most important classes to be last\n // (see https://github.com/mui/material-ui/pull/33205) for the related discussion.\n const joinedClasses = clsx(internalSlotProps == null ? void 0 : internalSlotProps.className, additionalProps == null ? void 0 : additionalProps.className, className, externalForwardedProps == null ? void 0 : externalForwardedProps.className, externalSlotProps == null ? void 0 : externalSlotProps.className);\n const mergedStyle = _extends({}, internalSlotProps == null ? void 0 : internalSlotProps.style, additionalProps == null ? void 0 : additionalProps.style, externalForwardedProps == null ? void 0 : externalForwardedProps.style, externalSlotProps == null ? void 0 : externalSlotProps.style);\n const props = _extends({}, internalSlotProps, additionalProps, otherPropsWithoutEventHandlers, componentsPropsWithoutEventHandlers);\n if (joinedClasses.length > 0) {\n props.className = joinedClasses;\n }\n if (Object.keys(mergedStyle).length > 0) {\n props.style = mergedStyle;\n }\n return {\n props,\n internalRef: internalSlotProps.ref\n };\n}","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"elementType\", \"externalSlotProps\", \"ownerState\", \"skipResolvingSlotProps\"];\nimport { unstable_useForkRef as useForkRef } from '@mui/utils';\nimport { appendOwnerState } from './appendOwnerState';\nimport { mergeSlotProps } from './mergeSlotProps';\nimport { resolveComponentProps } from './resolveComponentProps';\n/**\n * @ignore - do not document.\n * Builds the props to be passed into the slot of an unstyled component.\n * It merges the internal props of the component with the ones supplied by the user, allowing to customize the behavior.\n * If the slot component is not a host component, it also merges in the `ownerState`.\n *\n * @param parameters.getSlotProps - A function that returns the props to be passed to the slot component.\n */\nexport function useSlotProps(parameters) {\n var _parameters$additiona;\n const {\n elementType,\n externalSlotProps,\n ownerState,\n skipResolvingSlotProps = false\n } = parameters,\n rest = _objectWithoutPropertiesLoose(parameters, _excluded);\n const resolvedComponentsProps = skipResolvingSlotProps ? {} : resolveComponentProps(externalSlotProps, ownerState);\n const {\n props: mergedProps,\n internalRef\n } = mergeSlotProps(_extends({}, rest, {\n externalSlotProps: resolvedComponentsProps\n }));\n const ref = useForkRef(internalRef, resolvedComponentsProps == null ? void 0 : resolvedComponentsProps.ref, (_parameters$additiona = parameters.additionalProps) == null ? void 0 : _parameters$additiona.ref);\n const props = appendOwnerState(elementType, _extends({}, mergedProps, {\n ref\n }), ownerState);\n return props;\n}","import { globalStateClasses } from '@mui/utils/generateUtilityClass';\nconst GLOBAL_CLASS_PREFIX = 'base';\nfunction buildStateClass(state) {\n return `${GLOBAL_CLASS_PREFIX}--${state}`;\n}\nfunction buildSlotClass(componentName, slot) {\n return `${GLOBAL_CLASS_PREFIX}-${componentName}-${slot}`;\n}\nexport function generateUtilityClass(componentName, slot) {\n const globalStateClass = globalStateClasses[slot];\n return globalStateClass ? buildStateClass(globalStateClass) : buildSlotClass(componentName, slot);\n}\nexport function isGlobalState(slot) {\n return globalStateClasses[slot] !== undefined;\n}","import { generateUtilityClass } from '../generateUtilityClass';\nexport function generateUtilityClasses(componentName, slots) {\n const result = {};\n slots.forEach(slot => {\n result[slot] = generateUtilityClass(componentName, slot);\n });\n return result;\n}","'use client';\n\nimport * as React from 'react';\nimport * as ReactDOM from 'react-dom';\nimport PropTypes from 'prop-types';\nimport { exactProp, HTMLElementType, unstable_useEnhancedEffect as useEnhancedEffect, unstable_useForkRef as useForkRef, unstable_setRef as setRef } from '@mui/utils';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nfunction getContainer(container) {\n return typeof container === 'function' ? container() : container;\n}\n\n/**\n * Portals provide a first-class way to render children into a DOM node\n * that exists outside the DOM hierarchy of the parent component.\n *\n * Demos:\n *\n * - [Portal](https://mui.com/base-ui/react-portal/)\n *\n * API:\n *\n * - [Portal API](https://mui.com/base-ui/react-portal/components-api/#portal)\n */\nconst Portal = /*#__PURE__*/React.forwardRef(function Portal(props, forwardedRef) {\n const {\n children,\n container,\n disablePortal = false\n } = props;\n const [mountNode, setMountNode] = React.useState(null);\n // @ts-expect-error TODO upstream fix\n const handleRef = useForkRef( /*#__PURE__*/React.isValidElement(children) ? children.ref : null, forwardedRef);\n useEnhancedEffect(() => {\n if (!disablePortal) {\n setMountNode(getContainer(container) || document.body);\n }\n }, [container, disablePortal]);\n useEnhancedEffect(() => {\n if (mountNode && !disablePortal) {\n setRef(forwardedRef, mountNode);\n return () => {\n setRef(forwardedRef, null);\n };\n }\n return undefined;\n }, [forwardedRef, mountNode, disablePortal]);\n if (disablePortal) {\n if ( /*#__PURE__*/React.isValidElement(children)) {\n const newProps = {\n ref: handleRef\n };\n return /*#__PURE__*/React.cloneElement(children, newProps);\n }\n return /*#__PURE__*/_jsx(React.Fragment, {\n children: children\n });\n }\n return /*#__PURE__*/_jsx(React.Fragment, {\n children: mountNode ? /*#__PURE__*/ReactDOM.createPortal(children, mountNode) : mountNode\n });\n});\nprocess.env.NODE_ENV !== \"production\" ? Portal.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * The children to render into the `container`.\n */\n children: PropTypes.node,\n /**\n * An HTML element or function that returns one.\n * The `container` will have the portal children appended to it.\n *\n * You can also provide a callback, which is called in a React layout effect.\n * This lets you set the container from a ref, and also makes server-side rendering possible.\n *\n * By default, it uses the body of the top-level document object,\n * so it's simply `document.body` most of the time.\n */\n container: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.func]),\n /**\n * The `children` will be under the DOM hierarchy of the parent component.\n * @default false\n */\n disablePortal: PropTypes.bool\n} : void 0;\nif (process.env.NODE_ENV !== 'production') {\n // eslint-disable-next-line\n Portal['propTypes' + ''] = exactProp(Portal.propTypes);\n}\nexport { Portal };","export var top = 'top';\nexport var bottom = 'bottom';\nexport var right = 'right';\nexport var left = 'left';\nexport var auto = 'auto';\nexport var basePlacements = [top, bottom, right, left];\nexport var start = 'start';\nexport var end = 'end';\nexport var clippingParents = 'clippingParents';\nexport var viewport = 'viewport';\nexport var popper = 'popper';\nexport var reference = 'reference';\nexport var variationPlacements = /*#__PURE__*/basePlacements.reduce(function (acc, placement) {\n return acc.concat([placement + \"-\" + start, placement + \"-\" + end]);\n}, []);\nexport var placements = /*#__PURE__*/[].concat(basePlacements, [auto]).reduce(function (acc, placement) {\n return acc.concat([placement, placement + \"-\" + start, placement + \"-\" + end]);\n}, []); // modifiers that need to read the DOM\n\nexport var beforeRead = 'beforeRead';\nexport var read = 'read';\nexport var afterRead = 'afterRead'; // pure-logic modifiers\n\nexport var beforeMain = 'beforeMain';\nexport var main = 'main';\nexport var afterMain = 'afterMain'; // modifier with the purpose to write to the DOM (or write into a framework state)\n\nexport var beforeWrite = 'beforeWrite';\nexport var write = 'write';\nexport var afterWrite = 'afterWrite';\nexport var modifierPhases = [beforeRead, read, afterRead, beforeMain, main, afterMain, beforeWrite, write, afterWrite];","export default function getNodeName(element) {\n return element ? (element.nodeName || '').toLowerCase() : null;\n}","export default function getWindow(node) {\n if (node == null) {\n return window;\n }\n\n if (node.toString() !== '[object Window]') {\n var ownerDocument = node.ownerDocument;\n return ownerDocument ? ownerDocument.defaultView || window : window;\n }\n\n return node;\n}","import getWindow from \"./getWindow.js\";\n\nfunction isElement(node) {\n var OwnElement = getWindow(node).Element;\n return node instanceof OwnElement || node instanceof Element;\n}\n\nfunction isHTMLElement(node) {\n var OwnElement = getWindow(node).HTMLElement;\n return node instanceof OwnElement || node instanceof HTMLElement;\n}\n\nfunction isShadowRoot(node) {\n // IE 11 has no ShadowRoot\n if (typeof ShadowRoot === 'undefined') {\n return false;\n }\n\n var OwnElement = getWindow(node).ShadowRoot;\n return node instanceof OwnElement || node instanceof ShadowRoot;\n}\n\nexport { isElement, isHTMLElement, isShadowRoot };","import getNodeName from \"../dom-utils/getNodeName.js\";\nimport { isHTMLElement } from \"../dom-utils/instanceOf.js\"; // This modifier takes the styles prepared by the `computeStyles` modifier\n// and applies them to the HTMLElements such as popper and arrow\n\nfunction applyStyles(_ref) {\n var state = _ref.state;\n Object.keys(state.elements).forEach(function (name) {\n var style = state.styles[name] || {};\n var attributes = state.attributes[name] || {};\n var element = state.elements[name]; // arrow is optional + virtual elements\n\n if (!isHTMLElement(element) || !getNodeName(element)) {\n return;\n } // Flow doesn't support to extend this property, but it's the most\n // effective way to apply styles to an HTMLElement\n // $FlowFixMe[cannot-write]\n\n\n Object.assign(element.style, style);\n Object.keys(attributes).forEach(function (name) {\n var value = attributes[name];\n\n if (value === false) {\n element.removeAttribute(name);\n } else {\n element.setAttribute(name, value === true ? '' : value);\n }\n });\n });\n}\n\nfunction effect(_ref2) {\n var state = _ref2.state;\n var initialStyles = {\n popper: {\n position: state.options.strategy,\n left: '0',\n top: '0',\n margin: '0'\n },\n arrow: {\n position: 'absolute'\n },\n reference: {}\n };\n Object.assign(state.elements.popper.style, initialStyles.popper);\n state.styles = initialStyles;\n\n if (state.elements.arrow) {\n Object.assign(state.elements.arrow.style, initialStyles.arrow);\n }\n\n return function () {\n Object.keys(state.elements).forEach(function (name) {\n var element = state.elements[name];\n var attributes = state.attributes[name] || {};\n var styleProperties = Object.keys(state.styles.hasOwnProperty(name) ? state.styles[name] : initialStyles[name]); // Set all values to an empty string to unset them\n\n var style = styleProperties.reduce(function (style, property) {\n style[property] = '';\n return style;\n }, {}); // arrow is optional + virtual elements\n\n if (!isHTMLElement(element) || !getNodeName(element)) {\n return;\n }\n\n Object.assign(element.style, style);\n Object.keys(attributes).forEach(function (attribute) {\n element.removeAttribute(attribute);\n });\n });\n };\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'applyStyles',\n enabled: true,\n phase: 'write',\n fn: applyStyles,\n effect: effect,\n requires: ['computeStyles']\n};","import { auto } from \"../enums.js\";\nexport default function getBasePlacement(placement) {\n return placement.split('-')[0];\n}","export var max = Math.max;\nexport var min = Math.min;\nexport var round = Math.round;","export default function getUAString() {\n var uaData = navigator.userAgentData;\n\n if (uaData != null && uaData.brands && Array.isArray(uaData.brands)) {\n return uaData.brands.map(function (item) {\n return item.brand + \"/\" + item.version;\n }).join(' ');\n }\n\n return navigator.userAgent;\n}","import getUAString from \"../utils/userAgent.js\";\nexport default function isLayoutViewport() {\n return !/^((?!chrome|android).)*safari/i.test(getUAString());\n}","import { isElement, isHTMLElement } from \"./instanceOf.js\";\nimport { round } from \"../utils/math.js\";\nimport getWindow from \"./getWindow.js\";\nimport isLayoutViewport from \"./isLayoutViewport.js\";\nexport default function getBoundingClientRect(element, includeScale, isFixedStrategy) {\n if (includeScale === void 0) {\n includeScale = false;\n }\n\n if (isFixedStrategy === void 0) {\n isFixedStrategy = false;\n }\n\n var clientRect = element.getBoundingClientRect();\n var scaleX = 1;\n var scaleY = 1;\n\n if (includeScale && isHTMLElement(element)) {\n scaleX = element.offsetWidth > 0 ? round(clientRect.width) / element.offsetWidth || 1 : 1;\n scaleY = element.offsetHeight > 0 ? round(clientRect.height) / element.offsetHeight || 1 : 1;\n }\n\n var _ref = isElement(element) ? getWindow(element) : window,\n visualViewport = _ref.visualViewport;\n\n var addVisualOffsets = !isLayoutViewport() && isFixedStrategy;\n var x = (clientRect.left + (addVisualOffsets && visualViewport ? visualViewport.offsetLeft : 0)) / scaleX;\n var y = (clientRect.top + (addVisualOffsets && visualViewport ? visualViewport.offsetTop : 0)) / scaleY;\n var width = clientRect.width / scaleX;\n var height = clientRect.height / scaleY;\n return {\n width: width,\n height: height,\n top: y,\n right: x + width,\n bottom: y + height,\n left: x,\n x: x,\n y: y\n };\n}","import getBoundingClientRect from \"./getBoundingClientRect.js\"; // Returns the layout rect of an element relative to its offsetParent. Layout\n// means it doesn't take into account transforms.\n\nexport default function getLayoutRect(element) {\n var clientRect = getBoundingClientRect(element); // Use the clientRect sizes if it's not been transformed.\n // Fixes https://github.com/popperjs/popper-core/issues/1223\n\n var width = element.offsetWidth;\n var height = element.offsetHeight;\n\n if (Math.abs(clientRect.width - width) <= 1) {\n width = clientRect.width;\n }\n\n if (Math.abs(clientRect.height - height) <= 1) {\n height = clientRect.height;\n }\n\n return {\n x: element.offsetLeft,\n y: element.offsetTop,\n width: width,\n height: height\n };\n}","import { isShadowRoot } from \"./instanceOf.js\";\nexport default function contains(parent, child) {\n var rootNode = child.getRootNode && child.getRootNode(); // First, attempt with faster native method\n\n if (parent.contains(child)) {\n return true;\n } // then fallback to custom implementation with Shadow DOM support\n else if (rootNode && isShadowRoot(rootNode)) {\n var next = child;\n\n do {\n if (next && parent.isSameNode(next)) {\n return true;\n } // $FlowFixMe[prop-missing]: need a better way to handle this...\n\n\n next = next.parentNode || next.host;\n } while (next);\n } // Give up, the result is false\n\n\n return false;\n}","import getWindow from \"./getWindow.js\";\nexport default function getComputedStyle(element) {\n return getWindow(element).getComputedStyle(element);\n}","import getNodeName from \"./getNodeName.js\";\nexport default function isTableElement(element) {\n return ['table', 'td', 'th'].indexOf(getNodeName(element)) >= 0;\n}","import { isElement } from \"./instanceOf.js\";\nexport default function getDocumentElement(element) {\n // $FlowFixMe[incompatible-return]: assume body is always available\n return ((isElement(element) ? element.ownerDocument : // $FlowFixMe[prop-missing]\n element.document) || window.document).documentElement;\n}","import getNodeName from \"./getNodeName.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport { isShadowRoot } from \"./instanceOf.js\";\nexport default function getParentNode(element) {\n if (getNodeName(element) === 'html') {\n return element;\n }\n\n return (// this is a quicker (but less type safe) way to save quite some bytes from the bundle\n // $FlowFixMe[incompatible-return]\n // $FlowFixMe[prop-missing]\n element.assignedSlot || // step into the shadow DOM of the parent of a slotted node\n element.parentNode || ( // DOM Element detected\n isShadowRoot(element) ? element.host : null) || // ShadowRoot detected\n // $FlowFixMe[incompatible-call]: HTMLElement is a Node\n getDocumentElement(element) // fallback\n\n );\n}","import getWindow from \"./getWindow.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport getComputedStyle from \"./getComputedStyle.js\";\nimport { isHTMLElement, isShadowRoot } from \"./instanceOf.js\";\nimport isTableElement from \"./isTableElement.js\";\nimport getParentNode from \"./getParentNode.js\";\nimport getUAString from \"../utils/userAgent.js\";\n\nfunction getTrueOffsetParent(element) {\n if (!isHTMLElement(element) || // https://github.com/popperjs/popper-core/issues/837\n getComputedStyle(element).position === 'fixed') {\n return null;\n }\n\n return element.offsetParent;\n} // `.offsetParent` reports `null` for fixed elements, while absolute elements\n// return the containing block\n\n\nfunction getContainingBlock(element) {\n var isFirefox = /firefox/i.test(getUAString());\n var isIE = /Trident/i.test(getUAString());\n\n if (isIE && isHTMLElement(element)) {\n // In IE 9, 10 and 11 fixed elements containing block is always established by the viewport\n var elementCss = getComputedStyle(element);\n\n if (elementCss.position === 'fixed') {\n return null;\n }\n }\n\n var currentNode = getParentNode(element);\n\n if (isShadowRoot(currentNode)) {\n currentNode = currentNode.host;\n }\n\n while (isHTMLElement(currentNode) && ['html', 'body'].indexOf(getNodeName(currentNode)) < 0) {\n var css = getComputedStyle(currentNode); // This is non-exhaustive but covers the most common CSS properties that\n // create a containing block.\n // https://developer.mozilla.org/en-US/docs/Web/CSS/Containing_block#identifying_the_containing_block\n\n if (css.transform !== 'none' || css.perspective !== 'none' || css.contain === 'paint' || ['transform', 'perspective'].indexOf(css.willChange) !== -1 || isFirefox && css.willChange === 'filter' || isFirefox && css.filter && css.filter !== 'none') {\n return currentNode;\n } else {\n currentNode = currentNode.parentNode;\n }\n }\n\n return null;\n} // Gets the closest ancestor positioned element. Handles some edge cases,\n// such as table ancestors and cross browser bugs.\n\n\nexport default function getOffsetParent(element) {\n var window = getWindow(element);\n var offsetParent = getTrueOffsetParent(element);\n\n while (offsetParent && isTableElement(offsetParent) && getComputedStyle(offsetParent).position === 'static') {\n offsetParent = getTrueOffsetParent(offsetParent);\n }\n\n if (offsetParent && (getNodeName(offsetParent) === 'html' || getNodeName(offsetParent) === 'body' && getComputedStyle(offsetParent).position === 'static')) {\n return window;\n }\n\n return offsetParent || getContainingBlock(element) || window;\n}","export default function getMainAxisFromPlacement(placement) {\n return ['top', 'bottom'].indexOf(placement) >= 0 ? 'x' : 'y';\n}","import { max as mathMax, min as mathMin } from \"./math.js\";\nexport function within(min, value, max) {\n return mathMax(min, mathMin(value, max));\n}\nexport function withinMaxClamp(min, value, max) {\n var v = within(min, value, max);\n return v > max ? max : v;\n}","export default function getFreshSideObject() {\n return {\n top: 0,\n right: 0,\n bottom: 0,\n left: 0\n };\n}","import getFreshSideObject from \"./getFreshSideObject.js\";\nexport default function mergePaddingObject(paddingObject) {\n return Object.assign({}, getFreshSideObject(), paddingObject);\n}","export default function expandToHashMap(value, keys) {\n return keys.reduce(function (hashMap, key) {\n hashMap[key] = value;\n return hashMap;\n }, {});\n}","import getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getLayoutRect from \"../dom-utils/getLayoutRect.js\";\nimport contains from \"../dom-utils/contains.js\";\nimport getOffsetParent from \"../dom-utils/getOffsetParent.js\";\nimport getMainAxisFromPlacement from \"../utils/getMainAxisFromPlacement.js\";\nimport { within } from \"../utils/within.js\";\nimport mergePaddingObject from \"../utils/mergePaddingObject.js\";\nimport expandToHashMap from \"../utils/expandToHashMap.js\";\nimport { left, right, basePlacements, top, bottom } from \"../enums.js\"; // eslint-disable-next-line import/no-unused-modules\n\nvar toPaddingObject = function toPaddingObject(padding, state) {\n padding = typeof padding === 'function' ? padding(Object.assign({}, state.rects, {\n placement: state.placement\n })) : padding;\n return mergePaddingObject(typeof padding !== 'number' ? padding : expandToHashMap(padding, basePlacements));\n};\n\nfunction arrow(_ref) {\n var _state$modifiersData$;\n\n var state = _ref.state,\n name = _ref.name,\n options = _ref.options;\n var arrowElement = state.elements.arrow;\n var popperOffsets = state.modifiersData.popperOffsets;\n var basePlacement = getBasePlacement(state.placement);\n var axis = getMainAxisFromPlacement(basePlacement);\n var isVertical = [left, right].indexOf(basePlacement) >= 0;\n var len = isVertical ? 'height' : 'width';\n\n if (!arrowElement || !popperOffsets) {\n return;\n }\n\n var paddingObject = toPaddingObject(options.padding, state);\n var arrowRect = getLayoutRect(arrowElement);\n var minProp = axis === 'y' ? top : left;\n var maxProp = axis === 'y' ? bottom : right;\n var endDiff = state.rects.reference[len] + state.rects.reference[axis] - popperOffsets[axis] - state.rects.popper[len];\n var startDiff = popperOffsets[axis] - state.rects.reference[axis];\n var arrowOffsetParent = getOffsetParent(arrowElement);\n var clientSize = arrowOffsetParent ? axis === 'y' ? arrowOffsetParent.clientHeight || 0 : arrowOffsetParent.clientWidth || 0 : 0;\n var centerToReference = endDiff / 2 - startDiff / 2; // Make sure the arrow doesn't overflow the popper if the center point is\n // outside of the popper bounds\n\n var min = paddingObject[minProp];\n var max = clientSize - arrowRect[len] - paddingObject[maxProp];\n var center = clientSize / 2 - arrowRect[len] / 2 + centerToReference;\n var offset = within(min, center, max); // Prevents breaking syntax highlighting...\n\n var axisProp = axis;\n state.modifiersData[name] = (_state$modifiersData$ = {}, _state$modifiersData$[axisProp] = offset, _state$modifiersData$.centerOffset = offset - center, _state$modifiersData$);\n}\n\nfunction effect(_ref2) {\n var state = _ref2.state,\n options = _ref2.options;\n var _options$element = options.element,\n arrowElement = _options$element === void 0 ? '[data-popper-arrow]' : _options$element;\n\n if (arrowElement == null) {\n return;\n } // CSS selector\n\n\n if (typeof arrowElement === 'string') {\n arrowElement = state.elements.popper.querySelector(arrowElement);\n\n if (!arrowElement) {\n return;\n }\n }\n\n if (!contains(state.elements.popper, arrowElement)) {\n return;\n }\n\n state.elements.arrow = arrowElement;\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'arrow',\n enabled: true,\n phase: 'main',\n fn: arrow,\n effect: effect,\n requires: ['popperOffsets'],\n requiresIfExists: ['preventOverflow']\n};","export default function getVariation(placement) {\n return placement.split('-')[1];\n}","import { top, left, right, bottom, end } from \"../enums.js\";\nimport getOffsetParent from \"../dom-utils/getOffsetParent.js\";\nimport getWindow from \"../dom-utils/getWindow.js\";\nimport getDocumentElement from \"../dom-utils/getDocumentElement.js\";\nimport getComputedStyle from \"../dom-utils/getComputedStyle.js\";\nimport getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getVariation from \"../utils/getVariation.js\";\nimport { round } from \"../utils/math.js\"; // eslint-disable-next-line import/no-unused-modules\n\nvar unsetSides = {\n top: 'auto',\n right: 'auto',\n bottom: 'auto',\n left: 'auto'\n}; // Round the offsets to the nearest suitable subpixel based on the DPR.\n// Zooming can change the DPR, but it seems to report a value that will\n// cleanly divide the values into the appropriate subpixels.\n\nfunction roundOffsetsByDPR(_ref, win) {\n var x = _ref.x,\n y = _ref.y;\n var dpr = win.devicePixelRatio || 1;\n return {\n x: round(x * dpr) / dpr || 0,\n y: round(y * dpr) / dpr || 0\n };\n}\n\nexport function mapToStyles(_ref2) {\n var _Object$assign2;\n\n var popper = _ref2.popper,\n popperRect = _ref2.popperRect,\n placement = _ref2.placement,\n variation = _ref2.variation,\n offsets = _ref2.offsets,\n position = _ref2.position,\n gpuAcceleration = _ref2.gpuAcceleration,\n adaptive = _ref2.adaptive,\n roundOffsets = _ref2.roundOffsets,\n isFixed = _ref2.isFixed;\n var _offsets$x = offsets.x,\n x = _offsets$x === void 0 ? 0 : _offsets$x,\n _offsets$y = offsets.y,\n y = _offsets$y === void 0 ? 0 : _offsets$y;\n\n var _ref3 = typeof roundOffsets === 'function' ? roundOffsets({\n x: x,\n y: y\n }) : {\n x: x,\n y: y\n };\n\n x = _ref3.x;\n y = _ref3.y;\n var hasX = offsets.hasOwnProperty('x');\n var hasY = offsets.hasOwnProperty('y');\n var sideX = left;\n var sideY = top;\n var win = window;\n\n if (adaptive) {\n var offsetParent = getOffsetParent(popper);\n var heightProp = 'clientHeight';\n var widthProp = 'clientWidth';\n\n if (offsetParent === getWindow(popper)) {\n offsetParent = getDocumentElement(popper);\n\n if (getComputedStyle(offsetParent).position !== 'static' && position === 'absolute') {\n heightProp = 'scrollHeight';\n widthProp = 'scrollWidth';\n }\n } // $FlowFixMe[incompatible-cast]: force type refinement, we compare offsetParent with window above, but Flow doesn't detect it\n\n\n offsetParent = offsetParent;\n\n if (placement === top || (placement === left || placement === right) && variation === end) {\n sideY = bottom;\n var offsetY = isFixed && offsetParent === win && win.visualViewport ? win.visualViewport.height : // $FlowFixMe[prop-missing]\n offsetParent[heightProp];\n y -= offsetY - popperRect.height;\n y *= gpuAcceleration ? 1 : -1;\n }\n\n if (placement === left || (placement === top || placement === bottom) && variation === end) {\n sideX = right;\n var offsetX = isFixed && offsetParent === win && win.visualViewport ? win.visualViewport.width : // $FlowFixMe[prop-missing]\n offsetParent[widthProp];\n x -= offsetX - popperRect.width;\n x *= gpuAcceleration ? 1 : -1;\n }\n }\n\n var commonStyles = Object.assign({\n position: position\n }, adaptive && unsetSides);\n\n var _ref4 = roundOffsets === true ? roundOffsetsByDPR({\n x: x,\n y: y\n }, getWindow(popper)) : {\n x: x,\n y: y\n };\n\n x = _ref4.x;\n y = _ref4.y;\n\n if (gpuAcceleration) {\n var _Object$assign;\n\n return Object.assign({}, commonStyles, (_Object$assign = {}, _Object$assign[sideY] = hasY ? '0' : '', _Object$assign[sideX] = hasX ? '0' : '', _Object$assign.transform = (win.devicePixelRatio || 1) <= 1 ? \"translate(\" + x + \"px, \" + y + \"px)\" : \"translate3d(\" + x + \"px, \" + y + \"px, 0)\", _Object$assign));\n }\n\n return Object.assign({}, commonStyles, (_Object$assign2 = {}, _Object$assign2[sideY] = hasY ? y + \"px\" : '', _Object$assign2[sideX] = hasX ? x + \"px\" : '', _Object$assign2.transform = '', _Object$assign2));\n}\n\nfunction computeStyles(_ref5) {\n var state = _ref5.state,\n options = _ref5.options;\n var _options$gpuAccelerat = options.gpuAcceleration,\n gpuAcceleration = _options$gpuAccelerat === void 0 ? true : _options$gpuAccelerat,\n _options$adaptive = options.adaptive,\n adaptive = _options$adaptive === void 0 ? true : _options$adaptive,\n _options$roundOffsets = options.roundOffsets,\n roundOffsets = _options$roundOffsets === void 0 ? true : _options$roundOffsets;\n var commonStyles = {\n placement: getBasePlacement(state.placement),\n variation: getVariation(state.placement),\n popper: state.elements.popper,\n popperRect: state.rects.popper,\n gpuAcceleration: gpuAcceleration,\n isFixed: state.options.strategy === 'fixed'\n };\n\n if (state.modifiersData.popperOffsets != null) {\n state.styles.popper = Object.assign({}, state.styles.popper, mapToStyles(Object.assign({}, commonStyles, {\n offsets: state.modifiersData.popperOffsets,\n position: state.options.strategy,\n adaptive: adaptive,\n roundOffsets: roundOffsets\n })));\n }\n\n if (state.modifiersData.arrow != null) {\n state.styles.arrow = Object.assign({}, state.styles.arrow, mapToStyles(Object.assign({}, commonStyles, {\n offsets: state.modifiersData.arrow,\n position: 'absolute',\n adaptive: false,\n roundOffsets: roundOffsets\n })));\n }\n\n state.attributes.popper = Object.assign({}, state.attributes.popper, {\n 'data-popper-placement': state.placement\n });\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'computeStyles',\n enabled: true,\n phase: 'beforeWrite',\n fn: computeStyles,\n data: {}\n};","import getWindow from \"../dom-utils/getWindow.js\"; // eslint-disable-next-line import/no-unused-modules\n\nvar passive = {\n passive: true\n};\n\nfunction effect(_ref) {\n var state = _ref.state,\n instance = _ref.instance,\n options = _ref.options;\n var _options$scroll = options.scroll,\n scroll = _options$scroll === void 0 ? true : _options$scroll,\n _options$resize = options.resize,\n resize = _options$resize === void 0 ? true : _options$resize;\n var window = getWindow(state.elements.popper);\n var scrollParents = [].concat(state.scrollParents.reference, state.scrollParents.popper);\n\n if (scroll) {\n scrollParents.forEach(function (scrollParent) {\n scrollParent.addEventListener('scroll', instance.update, passive);\n });\n }\n\n if (resize) {\n window.addEventListener('resize', instance.update, passive);\n }\n\n return function () {\n if (scroll) {\n scrollParents.forEach(function (scrollParent) {\n scrollParent.removeEventListener('scroll', instance.update, passive);\n });\n }\n\n if (resize) {\n window.removeEventListener('resize', instance.update, passive);\n }\n };\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'eventListeners',\n enabled: true,\n phase: 'write',\n fn: function fn() {},\n effect: effect,\n data: {}\n};","var hash = {\n left: 'right',\n right: 'left',\n bottom: 'top',\n top: 'bottom'\n};\nexport default function getOppositePlacement(placement) {\n return placement.replace(/left|right|bottom|top/g, function (matched) {\n return hash[matched];\n });\n}","var hash = {\n start: 'end',\n end: 'start'\n};\nexport default function getOppositeVariationPlacement(placement) {\n return placement.replace(/start|end/g, function (matched) {\n return hash[matched];\n });\n}","import getWindow from \"./getWindow.js\";\nexport default function getWindowScroll(node) {\n var win = getWindow(node);\n var scrollLeft = win.pageXOffset;\n var scrollTop = win.pageYOffset;\n return {\n scrollLeft: scrollLeft,\n scrollTop: scrollTop\n };\n}","import getBoundingClientRect from \"./getBoundingClientRect.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport getWindowScroll from \"./getWindowScroll.js\";\nexport default function getWindowScrollBarX(element) {\n // If has a CSS width greater than the viewport, then this will be\n // incorrect for RTL.\n // Popper 1 is broken in this case and never had a bug report so let's assume\n // it's not an issue. I don't think anyone ever specifies width on \n // anyway.\n // Browsers where the left scrollbar doesn't cause an issue report `0` for\n // this (e.g. Edge 2019, IE11, Safari)\n return getBoundingClientRect(getDocumentElement(element)).left + getWindowScroll(element).scrollLeft;\n}","import getWindow from \"./getWindow.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport getWindowScrollBarX from \"./getWindowScrollBarX.js\";\nimport isLayoutViewport from \"./isLayoutViewport.js\";\nexport default function getViewportRect(element, strategy) {\n var win = getWindow(element);\n var html = getDocumentElement(element);\n var visualViewport = win.visualViewport;\n var width = html.clientWidth;\n var height = html.clientHeight;\n var x = 0;\n var y = 0;\n\n if (visualViewport) {\n width = visualViewport.width;\n height = visualViewport.height;\n var layoutViewport = isLayoutViewport();\n\n if (layoutViewport || !layoutViewport && strategy === 'fixed') {\n x = visualViewport.offsetLeft;\n y = visualViewport.offsetTop;\n }\n }\n\n return {\n width: width,\n height: height,\n x: x + getWindowScrollBarX(element),\n y: y\n };\n}","import getDocumentElement from \"./getDocumentElement.js\";\nimport getComputedStyle from \"./getComputedStyle.js\";\nimport getWindowScrollBarX from \"./getWindowScrollBarX.js\";\nimport getWindowScroll from \"./getWindowScroll.js\";\nimport { max } from \"../utils/math.js\"; // Gets the entire size of the scrollable document area, even extending outside\n// of the `` and `` rect bounds if horizontally scrollable\n\nexport default function getDocumentRect(element) {\n var _element$ownerDocumen;\n\n var html = getDocumentElement(element);\n var winScroll = getWindowScroll(element);\n var body = (_element$ownerDocumen = element.ownerDocument) == null ? void 0 : _element$ownerDocumen.body;\n var width = max(html.scrollWidth, html.clientWidth, body ? body.scrollWidth : 0, body ? body.clientWidth : 0);\n var height = max(html.scrollHeight, html.clientHeight, body ? body.scrollHeight : 0, body ? body.clientHeight : 0);\n var x = -winScroll.scrollLeft + getWindowScrollBarX(element);\n var y = -winScroll.scrollTop;\n\n if (getComputedStyle(body || html).direction === 'rtl') {\n x += max(html.clientWidth, body ? body.clientWidth : 0) - width;\n }\n\n return {\n width: width,\n height: height,\n x: x,\n y: y\n };\n}","import getComputedStyle from \"./getComputedStyle.js\";\nexport default function isScrollParent(element) {\n // Firefox wants us to check `-x` and `-y` variations as well\n var _getComputedStyle = getComputedStyle(element),\n overflow = _getComputedStyle.overflow,\n overflowX = _getComputedStyle.overflowX,\n overflowY = _getComputedStyle.overflowY;\n\n return /auto|scroll|overlay|hidden/.test(overflow + overflowY + overflowX);\n}","import getParentNode from \"./getParentNode.js\";\nimport isScrollParent from \"./isScrollParent.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport { isHTMLElement } from \"./instanceOf.js\";\nexport default function getScrollParent(node) {\n if (['html', 'body', '#document'].indexOf(getNodeName(node)) >= 0) {\n // $FlowFixMe[incompatible-return]: assume body is always available\n return node.ownerDocument.body;\n }\n\n if (isHTMLElement(node) && isScrollParent(node)) {\n return node;\n }\n\n return getScrollParent(getParentNode(node));\n}","import getScrollParent from \"./getScrollParent.js\";\nimport getParentNode from \"./getParentNode.js\";\nimport getWindow from \"./getWindow.js\";\nimport isScrollParent from \"./isScrollParent.js\";\n/*\ngiven a DOM element, return the list of all scroll parents, up the list of ancesors\nuntil we get to the top window object. This list is what we attach scroll listeners\nto, because if any of these parent elements scroll, we'll need to re-calculate the\nreference element's position.\n*/\n\nexport default function listScrollParents(element, list) {\n var _element$ownerDocumen;\n\n if (list === void 0) {\n list = [];\n }\n\n var scrollParent = getScrollParent(element);\n var isBody = scrollParent === ((_element$ownerDocumen = element.ownerDocument) == null ? void 0 : _element$ownerDocumen.body);\n var win = getWindow(scrollParent);\n var target = isBody ? [win].concat(win.visualViewport || [], isScrollParent(scrollParent) ? scrollParent : []) : scrollParent;\n var updatedList = list.concat(target);\n return isBody ? updatedList : // $FlowFixMe[incompatible-call]: isBody tells us target will be an HTMLElement here\n updatedList.concat(listScrollParents(getParentNode(target)));\n}","export default function rectToClientRect(rect) {\n return Object.assign({}, rect, {\n left: rect.x,\n top: rect.y,\n right: rect.x + rect.width,\n bottom: rect.y + rect.height\n });\n}","import { viewport } from \"../enums.js\";\nimport getViewportRect from \"./getViewportRect.js\";\nimport getDocumentRect from \"./getDocumentRect.js\";\nimport listScrollParents from \"./listScrollParents.js\";\nimport getOffsetParent from \"./getOffsetParent.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport getComputedStyle from \"./getComputedStyle.js\";\nimport { isElement, isHTMLElement } from \"./instanceOf.js\";\nimport getBoundingClientRect from \"./getBoundingClientRect.js\";\nimport getParentNode from \"./getParentNode.js\";\nimport contains from \"./contains.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport rectToClientRect from \"../utils/rectToClientRect.js\";\nimport { max, min } from \"../utils/math.js\";\n\nfunction getInnerBoundingClientRect(element, strategy) {\n var rect = getBoundingClientRect(element, false, strategy === 'fixed');\n rect.top = rect.top + element.clientTop;\n rect.left = rect.left + element.clientLeft;\n rect.bottom = rect.top + element.clientHeight;\n rect.right = rect.left + element.clientWidth;\n rect.width = element.clientWidth;\n rect.height = element.clientHeight;\n rect.x = rect.left;\n rect.y = rect.top;\n return rect;\n}\n\nfunction getClientRectFromMixedType(element, clippingParent, strategy) {\n return clippingParent === viewport ? rectToClientRect(getViewportRect(element, strategy)) : isElement(clippingParent) ? getInnerBoundingClientRect(clippingParent, strategy) : rectToClientRect(getDocumentRect(getDocumentElement(element)));\n} // A \"clipping parent\" is an overflowable container with the characteristic of\n// clipping (or hiding) overflowing elements with a position different from\n// `initial`\n\n\nfunction getClippingParents(element) {\n var clippingParents = listScrollParents(getParentNode(element));\n var canEscapeClipping = ['absolute', 'fixed'].indexOf(getComputedStyle(element).position) >= 0;\n var clipperElement = canEscapeClipping && isHTMLElement(element) ? getOffsetParent(element) : element;\n\n if (!isElement(clipperElement)) {\n return [];\n } // $FlowFixMe[incompatible-return]: https://github.com/facebook/flow/issues/1414\n\n\n return clippingParents.filter(function (clippingParent) {\n return isElement(clippingParent) && contains(clippingParent, clipperElement) && getNodeName(clippingParent) !== 'body';\n });\n} // Gets the maximum area that the element is visible in due to any number of\n// clipping parents\n\n\nexport default function getClippingRect(element, boundary, rootBoundary, strategy) {\n var mainClippingParents = boundary === 'clippingParents' ? getClippingParents(element) : [].concat(boundary);\n var clippingParents = [].concat(mainClippingParents, [rootBoundary]);\n var firstClippingParent = clippingParents[0];\n var clippingRect = clippingParents.reduce(function (accRect, clippingParent) {\n var rect = getClientRectFromMixedType(element, clippingParent, strategy);\n accRect.top = max(rect.top, accRect.top);\n accRect.right = min(rect.right, accRect.right);\n accRect.bottom = min(rect.bottom, accRect.bottom);\n accRect.left = max(rect.left, accRect.left);\n return accRect;\n }, getClientRectFromMixedType(element, firstClippingParent, strategy));\n clippingRect.width = clippingRect.right - clippingRect.left;\n clippingRect.height = clippingRect.bottom - clippingRect.top;\n clippingRect.x = clippingRect.left;\n clippingRect.y = clippingRect.top;\n return clippingRect;\n}","import getBasePlacement from \"./getBasePlacement.js\";\nimport getVariation from \"./getVariation.js\";\nimport getMainAxisFromPlacement from \"./getMainAxisFromPlacement.js\";\nimport { top, right, bottom, left, start, end } from \"../enums.js\";\nexport default function computeOffsets(_ref) {\n var reference = _ref.reference,\n element = _ref.element,\n placement = _ref.placement;\n var basePlacement = placement ? getBasePlacement(placement) : null;\n var variation = placement ? getVariation(placement) : null;\n var commonX = reference.x + reference.width / 2 - element.width / 2;\n var commonY = reference.y + reference.height / 2 - element.height / 2;\n var offsets;\n\n switch (basePlacement) {\n case top:\n offsets = {\n x: commonX,\n y: reference.y - element.height\n };\n break;\n\n case bottom:\n offsets = {\n x: commonX,\n y: reference.y + reference.height\n };\n break;\n\n case right:\n offsets = {\n x: reference.x + reference.width,\n y: commonY\n };\n break;\n\n case left:\n offsets = {\n x: reference.x - element.width,\n y: commonY\n };\n break;\n\n default:\n offsets = {\n x: reference.x,\n y: reference.y\n };\n }\n\n var mainAxis = basePlacement ? getMainAxisFromPlacement(basePlacement) : null;\n\n if (mainAxis != null) {\n var len = mainAxis === 'y' ? 'height' : 'width';\n\n switch (variation) {\n case start:\n offsets[mainAxis] = offsets[mainAxis] - (reference[len] / 2 - element[len] / 2);\n break;\n\n case end:\n offsets[mainAxis] = offsets[mainAxis] + (reference[len] / 2 - element[len] / 2);\n break;\n\n default:\n }\n }\n\n return offsets;\n}","import getClippingRect from \"../dom-utils/getClippingRect.js\";\nimport getDocumentElement from \"../dom-utils/getDocumentElement.js\";\nimport getBoundingClientRect from \"../dom-utils/getBoundingClientRect.js\";\nimport computeOffsets from \"./computeOffsets.js\";\nimport rectToClientRect from \"./rectToClientRect.js\";\nimport { clippingParents, reference, popper, bottom, top, right, basePlacements, viewport } from \"../enums.js\";\nimport { isElement } from \"../dom-utils/instanceOf.js\";\nimport mergePaddingObject from \"./mergePaddingObject.js\";\nimport expandToHashMap from \"./expandToHashMap.js\"; // eslint-disable-next-line import/no-unused-modules\n\nexport default function detectOverflow(state, options) {\n if (options === void 0) {\n options = {};\n }\n\n var _options = options,\n _options$placement = _options.placement,\n placement = _options$placement === void 0 ? state.placement : _options$placement,\n _options$strategy = _options.strategy,\n strategy = _options$strategy === void 0 ? state.strategy : _options$strategy,\n _options$boundary = _options.boundary,\n boundary = _options$boundary === void 0 ? clippingParents : _options$boundary,\n _options$rootBoundary = _options.rootBoundary,\n rootBoundary = _options$rootBoundary === void 0 ? viewport : _options$rootBoundary,\n _options$elementConte = _options.elementContext,\n elementContext = _options$elementConte === void 0 ? popper : _options$elementConte,\n _options$altBoundary = _options.altBoundary,\n altBoundary = _options$altBoundary === void 0 ? false : _options$altBoundary,\n _options$padding = _options.padding,\n padding = _options$padding === void 0 ? 0 : _options$padding;\n var paddingObject = mergePaddingObject(typeof padding !== 'number' ? padding : expandToHashMap(padding, basePlacements));\n var altContext = elementContext === popper ? reference : popper;\n var popperRect = state.rects.popper;\n var element = state.elements[altBoundary ? altContext : elementContext];\n var clippingClientRect = getClippingRect(isElement(element) ? element : element.contextElement || getDocumentElement(state.elements.popper), boundary, rootBoundary, strategy);\n var referenceClientRect = getBoundingClientRect(state.elements.reference);\n var popperOffsets = computeOffsets({\n reference: referenceClientRect,\n element: popperRect,\n strategy: 'absolute',\n placement: placement\n });\n var popperClientRect = rectToClientRect(Object.assign({}, popperRect, popperOffsets));\n var elementClientRect = elementContext === popper ? popperClientRect : referenceClientRect; // positive = overflowing the clipping rect\n // 0 or negative = within the clipping rect\n\n var overflowOffsets = {\n top: clippingClientRect.top - elementClientRect.top + paddingObject.top,\n bottom: elementClientRect.bottom - clippingClientRect.bottom + paddingObject.bottom,\n left: clippingClientRect.left - elementClientRect.left + paddingObject.left,\n right: elementClientRect.right - clippingClientRect.right + paddingObject.right\n };\n var offsetData = state.modifiersData.offset; // Offsets can be applied only to the popper element\n\n if (elementContext === popper && offsetData) {\n var offset = offsetData[placement];\n Object.keys(overflowOffsets).forEach(function (key) {\n var multiply = [right, bottom].indexOf(key) >= 0 ? 1 : -1;\n var axis = [top, bottom].indexOf(key) >= 0 ? 'y' : 'x';\n overflowOffsets[key] += offset[axis] * multiply;\n });\n }\n\n return overflowOffsets;\n}","import getVariation from \"./getVariation.js\";\nimport { variationPlacements, basePlacements, placements as allPlacements } from \"../enums.js\";\nimport detectOverflow from \"./detectOverflow.js\";\nimport getBasePlacement from \"./getBasePlacement.js\";\nexport default function computeAutoPlacement(state, options) {\n if (options === void 0) {\n options = {};\n }\n\n var _options = options,\n placement = _options.placement,\n boundary = _options.boundary,\n rootBoundary = _options.rootBoundary,\n padding = _options.padding,\n flipVariations = _options.flipVariations,\n _options$allowedAutoP = _options.allowedAutoPlacements,\n allowedAutoPlacements = _options$allowedAutoP === void 0 ? allPlacements : _options$allowedAutoP;\n var variation = getVariation(placement);\n var placements = variation ? flipVariations ? variationPlacements : variationPlacements.filter(function (placement) {\n return getVariation(placement) === variation;\n }) : basePlacements;\n var allowedPlacements = placements.filter(function (placement) {\n return allowedAutoPlacements.indexOf(placement) >= 0;\n });\n\n if (allowedPlacements.length === 0) {\n allowedPlacements = placements;\n } // $FlowFixMe[incompatible-type]: Flow seems to have problems with two array unions...\n\n\n var overflows = allowedPlacements.reduce(function (acc, placement) {\n acc[placement] = detectOverflow(state, {\n placement: placement,\n boundary: boundary,\n rootBoundary: rootBoundary,\n padding: padding\n })[getBasePlacement(placement)];\n return acc;\n }, {});\n return Object.keys(overflows).sort(function (a, b) {\n return overflows[a] - overflows[b];\n });\n}","import getOppositePlacement from \"../utils/getOppositePlacement.js\";\nimport getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getOppositeVariationPlacement from \"../utils/getOppositeVariationPlacement.js\";\nimport detectOverflow from \"../utils/detectOverflow.js\";\nimport computeAutoPlacement from \"../utils/computeAutoPlacement.js\";\nimport { bottom, top, start, right, left, auto } from \"../enums.js\";\nimport getVariation from \"../utils/getVariation.js\"; // eslint-disable-next-line import/no-unused-modules\n\nfunction getExpandedFallbackPlacements(placement) {\n if (getBasePlacement(placement) === auto) {\n return [];\n }\n\n var oppositePlacement = getOppositePlacement(placement);\n return [getOppositeVariationPlacement(placement), oppositePlacement, getOppositeVariationPlacement(oppositePlacement)];\n}\n\nfunction flip(_ref) {\n var state = _ref.state,\n options = _ref.options,\n name = _ref.name;\n\n if (state.modifiersData[name]._skip) {\n return;\n }\n\n var _options$mainAxis = options.mainAxis,\n checkMainAxis = _options$mainAxis === void 0 ? true : _options$mainAxis,\n _options$altAxis = options.altAxis,\n checkAltAxis = _options$altAxis === void 0 ? true : _options$altAxis,\n specifiedFallbackPlacements = options.fallbackPlacements,\n padding = options.padding,\n boundary = options.boundary,\n rootBoundary = options.rootBoundary,\n altBoundary = options.altBoundary,\n _options$flipVariatio = options.flipVariations,\n flipVariations = _options$flipVariatio === void 0 ? true : _options$flipVariatio,\n allowedAutoPlacements = options.allowedAutoPlacements;\n var preferredPlacement = state.options.placement;\n var basePlacement = getBasePlacement(preferredPlacement);\n var isBasePlacement = basePlacement === preferredPlacement;\n var fallbackPlacements = specifiedFallbackPlacements || (isBasePlacement || !flipVariations ? [getOppositePlacement(preferredPlacement)] : getExpandedFallbackPlacements(preferredPlacement));\n var placements = [preferredPlacement].concat(fallbackPlacements).reduce(function (acc, placement) {\n return acc.concat(getBasePlacement(placement) === auto ? computeAutoPlacement(state, {\n placement: placement,\n boundary: boundary,\n rootBoundary: rootBoundary,\n padding: padding,\n flipVariations: flipVariations,\n allowedAutoPlacements: allowedAutoPlacements\n }) : placement);\n }, []);\n var referenceRect = state.rects.reference;\n var popperRect = state.rects.popper;\n var checksMap = new Map();\n var makeFallbackChecks = true;\n var firstFittingPlacement = placements[0];\n\n for (var i = 0; i < placements.length; i++) {\n var placement = placements[i];\n\n var _basePlacement = getBasePlacement(placement);\n\n var isStartVariation = getVariation(placement) === start;\n var isVertical = [top, bottom].indexOf(_basePlacement) >= 0;\n var len = isVertical ? 'width' : 'height';\n var overflow = detectOverflow(state, {\n placement: placement,\n boundary: boundary,\n rootBoundary: rootBoundary,\n altBoundary: altBoundary,\n padding: padding\n });\n var mainVariationSide = isVertical ? isStartVariation ? right : left : isStartVariation ? bottom : top;\n\n if (referenceRect[len] > popperRect[len]) {\n mainVariationSide = getOppositePlacement(mainVariationSide);\n }\n\n var altVariationSide = getOppositePlacement(mainVariationSide);\n var checks = [];\n\n if (checkMainAxis) {\n checks.push(overflow[_basePlacement] <= 0);\n }\n\n if (checkAltAxis) {\n checks.push(overflow[mainVariationSide] <= 0, overflow[altVariationSide] <= 0);\n }\n\n if (checks.every(function (check) {\n return check;\n })) {\n firstFittingPlacement = placement;\n makeFallbackChecks = false;\n break;\n }\n\n checksMap.set(placement, checks);\n }\n\n if (makeFallbackChecks) {\n // `2` may be desired in some cases – research later\n var numberOfChecks = flipVariations ? 3 : 1;\n\n var _loop = function _loop(_i) {\n var fittingPlacement = placements.find(function (placement) {\n var checks = checksMap.get(placement);\n\n if (checks) {\n return checks.slice(0, _i).every(function (check) {\n return check;\n });\n }\n });\n\n if (fittingPlacement) {\n firstFittingPlacement = fittingPlacement;\n return \"break\";\n }\n };\n\n for (var _i = numberOfChecks; _i > 0; _i--) {\n var _ret = _loop(_i);\n\n if (_ret === \"break\") break;\n }\n }\n\n if (state.placement !== firstFittingPlacement) {\n state.modifiersData[name]._skip = true;\n state.placement = firstFittingPlacement;\n state.reset = true;\n }\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'flip',\n enabled: true,\n phase: 'main',\n fn: flip,\n requiresIfExists: ['offset'],\n data: {\n _skip: false\n }\n};","import { top, bottom, left, right } from \"../enums.js\";\nimport detectOverflow from \"../utils/detectOverflow.js\";\n\nfunction getSideOffsets(overflow, rect, preventedOffsets) {\n if (preventedOffsets === void 0) {\n preventedOffsets = {\n x: 0,\n y: 0\n };\n }\n\n return {\n top: overflow.top - rect.height - preventedOffsets.y,\n right: overflow.right - rect.width + preventedOffsets.x,\n bottom: overflow.bottom - rect.height + preventedOffsets.y,\n left: overflow.left - rect.width - preventedOffsets.x\n };\n}\n\nfunction isAnySideFullyClipped(overflow) {\n return [top, right, bottom, left].some(function (side) {\n return overflow[side] >= 0;\n });\n}\n\nfunction hide(_ref) {\n var state = _ref.state,\n name = _ref.name;\n var referenceRect = state.rects.reference;\n var popperRect = state.rects.popper;\n var preventedOffsets = state.modifiersData.preventOverflow;\n var referenceOverflow = detectOverflow(state, {\n elementContext: 'reference'\n });\n var popperAltOverflow = detectOverflow(state, {\n altBoundary: true\n });\n var referenceClippingOffsets = getSideOffsets(referenceOverflow, referenceRect);\n var popperEscapeOffsets = getSideOffsets(popperAltOverflow, popperRect, preventedOffsets);\n var isReferenceHidden = isAnySideFullyClipped(referenceClippingOffsets);\n var hasPopperEscaped = isAnySideFullyClipped(popperEscapeOffsets);\n state.modifiersData[name] = {\n referenceClippingOffsets: referenceClippingOffsets,\n popperEscapeOffsets: popperEscapeOffsets,\n isReferenceHidden: isReferenceHidden,\n hasPopperEscaped: hasPopperEscaped\n };\n state.attributes.popper = Object.assign({}, state.attributes.popper, {\n 'data-popper-reference-hidden': isReferenceHidden,\n 'data-popper-escaped': hasPopperEscaped\n });\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'hide',\n enabled: true,\n phase: 'main',\n requiresIfExists: ['preventOverflow'],\n fn: hide\n};","import getBasePlacement from \"../utils/getBasePlacement.js\";\nimport { top, left, right, placements } from \"../enums.js\"; // eslint-disable-next-line import/no-unused-modules\n\nexport function distanceAndSkiddingToXY(placement, rects, offset) {\n var basePlacement = getBasePlacement(placement);\n var invertDistance = [left, top].indexOf(basePlacement) >= 0 ? -1 : 1;\n\n var _ref = typeof offset === 'function' ? offset(Object.assign({}, rects, {\n placement: placement\n })) : offset,\n skidding = _ref[0],\n distance = _ref[1];\n\n skidding = skidding || 0;\n distance = (distance || 0) * invertDistance;\n return [left, right].indexOf(basePlacement) >= 0 ? {\n x: distance,\n y: skidding\n } : {\n x: skidding,\n y: distance\n };\n}\n\nfunction offset(_ref2) {\n var state = _ref2.state,\n options = _ref2.options,\n name = _ref2.name;\n var _options$offset = options.offset,\n offset = _options$offset === void 0 ? [0, 0] : _options$offset;\n var data = placements.reduce(function (acc, placement) {\n acc[placement] = distanceAndSkiddingToXY(placement, state.rects, offset);\n return acc;\n }, {});\n var _data$state$placement = data[state.placement],\n x = _data$state$placement.x,\n y = _data$state$placement.y;\n\n if (state.modifiersData.popperOffsets != null) {\n state.modifiersData.popperOffsets.x += x;\n state.modifiersData.popperOffsets.y += y;\n }\n\n state.modifiersData[name] = data;\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'offset',\n enabled: true,\n phase: 'main',\n requires: ['popperOffsets'],\n fn: offset\n};","import computeOffsets from \"../utils/computeOffsets.js\";\n\nfunction popperOffsets(_ref) {\n var state = _ref.state,\n name = _ref.name;\n // Offsets are the actual position the popper needs to have to be\n // properly positioned near its reference element\n // This is the most basic placement, and will be adjusted by\n // the modifiers in the next step\n state.modifiersData[name] = computeOffsets({\n reference: state.rects.reference,\n element: state.rects.popper,\n strategy: 'absolute',\n placement: state.placement\n });\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'popperOffsets',\n enabled: true,\n phase: 'read',\n fn: popperOffsets,\n data: {}\n};","export default function getAltAxis(axis) {\n return axis === 'x' ? 'y' : 'x';\n}","import { top, left, right, bottom, start } from \"../enums.js\";\nimport getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getMainAxisFromPlacement from \"../utils/getMainAxisFromPlacement.js\";\nimport getAltAxis from \"../utils/getAltAxis.js\";\nimport { within, withinMaxClamp } from \"../utils/within.js\";\nimport getLayoutRect from \"../dom-utils/getLayoutRect.js\";\nimport getOffsetParent from \"../dom-utils/getOffsetParent.js\";\nimport detectOverflow from \"../utils/detectOverflow.js\";\nimport getVariation from \"../utils/getVariation.js\";\nimport getFreshSideObject from \"../utils/getFreshSideObject.js\";\nimport { min as mathMin, max as mathMax } from \"../utils/math.js\";\n\nfunction preventOverflow(_ref) {\n var state = _ref.state,\n options = _ref.options,\n name = _ref.name;\n var _options$mainAxis = options.mainAxis,\n checkMainAxis = _options$mainAxis === void 0 ? true : _options$mainAxis,\n _options$altAxis = options.altAxis,\n checkAltAxis = _options$altAxis === void 0 ? false : _options$altAxis,\n boundary = options.boundary,\n rootBoundary = options.rootBoundary,\n altBoundary = options.altBoundary,\n padding = options.padding,\n _options$tether = options.tether,\n tether = _options$tether === void 0 ? true : _options$tether,\n _options$tetherOffset = options.tetherOffset,\n tetherOffset = _options$tetherOffset === void 0 ? 0 : _options$tetherOffset;\n var overflow = detectOverflow(state, {\n boundary: boundary,\n rootBoundary: rootBoundary,\n padding: padding,\n altBoundary: altBoundary\n });\n var basePlacement = getBasePlacement(state.placement);\n var variation = getVariation(state.placement);\n var isBasePlacement = !variation;\n var mainAxis = getMainAxisFromPlacement(basePlacement);\n var altAxis = getAltAxis(mainAxis);\n var popperOffsets = state.modifiersData.popperOffsets;\n var referenceRect = state.rects.reference;\n var popperRect = state.rects.popper;\n var tetherOffsetValue = typeof tetherOffset === 'function' ? tetherOffset(Object.assign({}, state.rects, {\n placement: state.placement\n })) : tetherOffset;\n var normalizedTetherOffsetValue = typeof tetherOffsetValue === 'number' ? {\n mainAxis: tetherOffsetValue,\n altAxis: tetherOffsetValue\n } : Object.assign({\n mainAxis: 0,\n altAxis: 0\n }, tetherOffsetValue);\n var offsetModifierState = state.modifiersData.offset ? state.modifiersData.offset[state.placement] : null;\n var data = {\n x: 0,\n y: 0\n };\n\n if (!popperOffsets) {\n return;\n }\n\n if (checkMainAxis) {\n var _offsetModifierState$;\n\n var mainSide = mainAxis === 'y' ? top : left;\n var altSide = mainAxis === 'y' ? bottom : right;\n var len = mainAxis === 'y' ? 'height' : 'width';\n var offset = popperOffsets[mainAxis];\n var min = offset + overflow[mainSide];\n var max = offset - overflow[altSide];\n var additive = tether ? -popperRect[len] / 2 : 0;\n var minLen = variation === start ? referenceRect[len] : popperRect[len];\n var maxLen = variation === start ? -popperRect[len] : -referenceRect[len]; // We need to include the arrow in the calculation so the arrow doesn't go\n // outside the reference bounds\n\n var arrowElement = state.elements.arrow;\n var arrowRect = tether && arrowElement ? getLayoutRect(arrowElement) : {\n width: 0,\n height: 0\n };\n var arrowPaddingObject = state.modifiersData['arrow#persistent'] ? state.modifiersData['arrow#persistent'].padding : getFreshSideObject();\n var arrowPaddingMin = arrowPaddingObject[mainSide];\n var arrowPaddingMax = arrowPaddingObject[altSide]; // If the reference length is smaller than the arrow length, we don't want\n // to include its full size in the calculation. If the reference is small\n // and near the edge of a boundary, the popper can overflow even if the\n // reference is not overflowing as well (e.g. virtual elements with no\n // width or height)\n\n var arrowLen = within(0, referenceRect[len], arrowRect[len]);\n var minOffset = isBasePlacement ? referenceRect[len] / 2 - additive - arrowLen - arrowPaddingMin - normalizedTetherOffsetValue.mainAxis : minLen - arrowLen - arrowPaddingMin - normalizedTetherOffsetValue.mainAxis;\n var maxOffset = isBasePlacement ? -referenceRect[len] / 2 + additive + arrowLen + arrowPaddingMax + normalizedTetherOffsetValue.mainAxis : maxLen + arrowLen + arrowPaddingMax + normalizedTetherOffsetValue.mainAxis;\n var arrowOffsetParent = state.elements.arrow && getOffsetParent(state.elements.arrow);\n var clientOffset = arrowOffsetParent ? mainAxis === 'y' ? arrowOffsetParent.clientTop || 0 : arrowOffsetParent.clientLeft || 0 : 0;\n var offsetModifierValue = (_offsetModifierState$ = offsetModifierState == null ? void 0 : offsetModifierState[mainAxis]) != null ? _offsetModifierState$ : 0;\n var tetherMin = offset + minOffset - offsetModifierValue - clientOffset;\n var tetherMax = offset + maxOffset - offsetModifierValue;\n var preventedOffset = within(tether ? mathMin(min, tetherMin) : min, offset, tether ? mathMax(max, tetherMax) : max);\n popperOffsets[mainAxis] = preventedOffset;\n data[mainAxis] = preventedOffset - offset;\n }\n\n if (checkAltAxis) {\n var _offsetModifierState$2;\n\n var _mainSide = mainAxis === 'x' ? top : left;\n\n var _altSide = mainAxis === 'x' ? bottom : right;\n\n var _offset = popperOffsets[altAxis];\n\n var _len = altAxis === 'y' ? 'height' : 'width';\n\n var _min = _offset + overflow[_mainSide];\n\n var _max = _offset - overflow[_altSide];\n\n var isOriginSide = [top, left].indexOf(basePlacement) !== -1;\n\n var _offsetModifierValue = (_offsetModifierState$2 = offsetModifierState == null ? void 0 : offsetModifierState[altAxis]) != null ? _offsetModifierState$2 : 0;\n\n var _tetherMin = isOriginSide ? _min : _offset - referenceRect[_len] - popperRect[_len] - _offsetModifierValue + normalizedTetherOffsetValue.altAxis;\n\n var _tetherMax = isOriginSide ? _offset + referenceRect[_len] + popperRect[_len] - _offsetModifierValue - normalizedTetherOffsetValue.altAxis : _max;\n\n var _preventedOffset = tether && isOriginSide ? withinMaxClamp(_tetherMin, _offset, _tetherMax) : within(tether ? _tetherMin : _min, _offset, tether ? _tetherMax : _max);\n\n popperOffsets[altAxis] = _preventedOffset;\n data[altAxis] = _preventedOffset - _offset;\n }\n\n state.modifiersData[name] = data;\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'preventOverflow',\n enabled: true,\n phase: 'main',\n fn: preventOverflow,\n requiresIfExists: ['offset']\n};","export default function getHTMLElementScroll(element) {\n return {\n scrollLeft: element.scrollLeft,\n scrollTop: element.scrollTop\n };\n}","import getWindowScroll from \"./getWindowScroll.js\";\nimport getWindow from \"./getWindow.js\";\nimport { isHTMLElement } from \"./instanceOf.js\";\nimport getHTMLElementScroll from \"./getHTMLElementScroll.js\";\nexport default function getNodeScroll(node) {\n if (node === getWindow(node) || !isHTMLElement(node)) {\n return getWindowScroll(node);\n } else {\n return getHTMLElementScroll(node);\n }\n}","import getBoundingClientRect from \"./getBoundingClientRect.js\";\nimport getNodeScroll from \"./getNodeScroll.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport { isHTMLElement } from \"./instanceOf.js\";\nimport getWindowScrollBarX from \"./getWindowScrollBarX.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport isScrollParent from \"./isScrollParent.js\";\nimport { round } from \"../utils/math.js\";\n\nfunction isElementScaled(element) {\n var rect = element.getBoundingClientRect();\n var scaleX = round(rect.width) / element.offsetWidth || 1;\n var scaleY = round(rect.height) / element.offsetHeight || 1;\n return scaleX !== 1 || scaleY !== 1;\n} // Returns the composite rect of an element relative to its offsetParent.\n// Composite means it takes into account transforms as well as layout.\n\n\nexport default function getCompositeRect(elementOrVirtualElement, offsetParent, isFixed) {\n if (isFixed === void 0) {\n isFixed = false;\n }\n\n var isOffsetParentAnElement = isHTMLElement(offsetParent);\n var offsetParentIsScaled = isHTMLElement(offsetParent) && isElementScaled(offsetParent);\n var documentElement = getDocumentElement(offsetParent);\n var rect = getBoundingClientRect(elementOrVirtualElement, offsetParentIsScaled, isFixed);\n var scroll = {\n scrollLeft: 0,\n scrollTop: 0\n };\n var offsets = {\n x: 0,\n y: 0\n };\n\n if (isOffsetParentAnElement || !isOffsetParentAnElement && !isFixed) {\n if (getNodeName(offsetParent) !== 'body' || // https://github.com/popperjs/popper-core/issues/1078\n isScrollParent(documentElement)) {\n scroll = getNodeScroll(offsetParent);\n }\n\n if (isHTMLElement(offsetParent)) {\n offsets = getBoundingClientRect(offsetParent, true);\n offsets.x += offsetParent.clientLeft;\n offsets.y += offsetParent.clientTop;\n } else if (documentElement) {\n offsets.x = getWindowScrollBarX(documentElement);\n }\n }\n\n return {\n x: rect.left + scroll.scrollLeft - offsets.x,\n y: rect.top + scroll.scrollTop - offsets.y,\n width: rect.width,\n height: rect.height\n };\n}","import { modifierPhases } from \"../enums.js\"; // source: https://stackoverflow.com/questions/49875255\n\nfunction order(modifiers) {\n var map = new Map();\n var visited = new Set();\n var result = [];\n modifiers.forEach(function (modifier) {\n map.set(modifier.name, modifier);\n }); // On visiting object, check for its dependencies and visit them recursively\n\n function sort(modifier) {\n visited.add(modifier.name);\n var requires = [].concat(modifier.requires || [], modifier.requiresIfExists || []);\n requires.forEach(function (dep) {\n if (!visited.has(dep)) {\n var depModifier = map.get(dep);\n\n if (depModifier) {\n sort(depModifier);\n }\n }\n });\n result.push(modifier);\n }\n\n modifiers.forEach(function (modifier) {\n if (!visited.has(modifier.name)) {\n // check for visited object\n sort(modifier);\n }\n });\n return result;\n}\n\nexport default function orderModifiers(modifiers) {\n // order based on dependencies\n var orderedModifiers = order(modifiers); // order based on phase\n\n return modifierPhases.reduce(function (acc, phase) {\n return acc.concat(orderedModifiers.filter(function (modifier) {\n return modifier.phase === phase;\n }));\n }, []);\n}","export default function debounce(fn) {\n var pending;\n return function () {\n if (!pending) {\n pending = new Promise(function (resolve) {\n Promise.resolve().then(function () {\n pending = undefined;\n resolve(fn());\n });\n });\n }\n\n return pending;\n };\n}","export default function mergeByName(modifiers) {\n var merged = modifiers.reduce(function (merged, current) {\n var existing = merged[current.name];\n merged[current.name] = existing ? Object.assign({}, existing, current, {\n options: Object.assign({}, existing.options, current.options),\n data: Object.assign({}, existing.data, current.data)\n }) : current;\n return merged;\n }, {}); // IE11 does not support Object.values\n\n return Object.keys(merged).map(function (key) {\n return merged[key];\n });\n}","import getCompositeRect from \"./dom-utils/getCompositeRect.js\";\nimport getLayoutRect from \"./dom-utils/getLayoutRect.js\";\nimport listScrollParents from \"./dom-utils/listScrollParents.js\";\nimport getOffsetParent from \"./dom-utils/getOffsetParent.js\";\nimport orderModifiers from \"./utils/orderModifiers.js\";\nimport debounce from \"./utils/debounce.js\";\nimport mergeByName from \"./utils/mergeByName.js\";\nimport detectOverflow from \"./utils/detectOverflow.js\";\nimport { isElement } from \"./dom-utils/instanceOf.js\";\nvar DEFAULT_OPTIONS = {\n placement: 'bottom',\n modifiers: [],\n strategy: 'absolute'\n};\n\nfunction areValidElements() {\n for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {\n args[_key] = arguments[_key];\n }\n\n return !args.some(function (element) {\n return !(element && typeof element.getBoundingClientRect === 'function');\n });\n}\n\nexport function popperGenerator(generatorOptions) {\n if (generatorOptions === void 0) {\n generatorOptions = {};\n }\n\n var _generatorOptions = generatorOptions,\n _generatorOptions$def = _generatorOptions.defaultModifiers,\n defaultModifiers = _generatorOptions$def === void 0 ? [] : _generatorOptions$def,\n _generatorOptions$def2 = _generatorOptions.defaultOptions,\n defaultOptions = _generatorOptions$def2 === void 0 ? DEFAULT_OPTIONS : _generatorOptions$def2;\n return function createPopper(reference, popper, options) {\n if (options === void 0) {\n options = defaultOptions;\n }\n\n var state = {\n placement: 'bottom',\n orderedModifiers: [],\n options: Object.assign({}, DEFAULT_OPTIONS, defaultOptions),\n modifiersData: {},\n elements: {\n reference: reference,\n popper: popper\n },\n attributes: {},\n styles: {}\n };\n var effectCleanupFns = [];\n var isDestroyed = false;\n var instance = {\n state: state,\n setOptions: function setOptions(setOptionsAction) {\n var options = typeof setOptionsAction === 'function' ? setOptionsAction(state.options) : setOptionsAction;\n cleanupModifierEffects();\n state.options = Object.assign({}, defaultOptions, state.options, options);\n state.scrollParents = {\n reference: isElement(reference) ? listScrollParents(reference) : reference.contextElement ? listScrollParents(reference.contextElement) : [],\n popper: listScrollParents(popper)\n }; // Orders the modifiers based on their dependencies and `phase`\n // properties\n\n var orderedModifiers = orderModifiers(mergeByName([].concat(defaultModifiers, state.options.modifiers))); // Strip out disabled modifiers\n\n state.orderedModifiers = orderedModifiers.filter(function (m) {\n return m.enabled;\n });\n runModifierEffects();\n return instance.update();\n },\n // Sync update – it will always be executed, even if not necessary. This\n // is useful for low frequency updates where sync behavior simplifies the\n // logic.\n // For high frequency updates (e.g. `resize` and `scroll` events), always\n // prefer the async Popper#update method\n forceUpdate: function forceUpdate() {\n if (isDestroyed) {\n return;\n }\n\n var _state$elements = state.elements,\n reference = _state$elements.reference,\n popper = _state$elements.popper; // Don't proceed if `reference` or `popper` are not valid elements\n // anymore\n\n if (!areValidElements(reference, popper)) {\n return;\n } // Store the reference and popper rects to be read by modifiers\n\n\n state.rects = {\n reference: getCompositeRect(reference, getOffsetParent(popper), state.options.strategy === 'fixed'),\n popper: getLayoutRect(popper)\n }; // Modifiers have the ability to reset the current update cycle. The\n // most common use case for this is the `flip` modifier changing the\n // placement, which then needs to re-run all the modifiers, because the\n // logic was previously ran for the previous placement and is therefore\n // stale/incorrect\n\n state.reset = false;\n state.placement = state.options.placement; // On each update cycle, the `modifiersData` property for each modifier\n // is filled with the initial data specified by the modifier. This means\n // it doesn't persist and is fresh on each update.\n // To ensure persistent data, use `${name}#persistent`\n\n state.orderedModifiers.forEach(function (modifier) {\n return state.modifiersData[modifier.name] = Object.assign({}, modifier.data);\n });\n\n for (var index = 0; index < state.orderedModifiers.length; index++) {\n if (state.reset === true) {\n state.reset = false;\n index = -1;\n continue;\n }\n\n var _state$orderedModifie = state.orderedModifiers[index],\n fn = _state$orderedModifie.fn,\n _state$orderedModifie2 = _state$orderedModifie.options,\n _options = _state$orderedModifie2 === void 0 ? {} : _state$orderedModifie2,\n name = _state$orderedModifie.name;\n\n if (typeof fn === 'function') {\n state = fn({\n state: state,\n options: _options,\n name: name,\n instance: instance\n }) || state;\n }\n }\n },\n // Async and optimistically optimized update – it will not be executed if\n // not necessary (debounced to run at most once-per-tick)\n update: debounce(function () {\n return new Promise(function (resolve) {\n instance.forceUpdate();\n resolve(state);\n });\n }),\n destroy: function destroy() {\n cleanupModifierEffects();\n isDestroyed = true;\n }\n };\n\n if (!areValidElements(reference, popper)) {\n return instance;\n }\n\n instance.setOptions(options).then(function (state) {\n if (!isDestroyed && options.onFirstUpdate) {\n options.onFirstUpdate(state);\n }\n }); // Modifiers have the ability to execute arbitrary code before the first\n // update cycle runs. They will be executed in the same order as the update\n // cycle. This is useful when a modifier adds some persistent data that\n // other modifiers need to use, but the modifier is run after the dependent\n // one.\n\n function runModifierEffects() {\n state.orderedModifiers.forEach(function (_ref) {\n var name = _ref.name,\n _ref$options = _ref.options,\n options = _ref$options === void 0 ? {} : _ref$options,\n effect = _ref.effect;\n\n if (typeof effect === 'function') {\n var cleanupFn = effect({\n state: state,\n name: name,\n instance: instance,\n options: options\n });\n\n var noopFn = function noopFn() {};\n\n effectCleanupFns.push(cleanupFn || noopFn);\n }\n });\n }\n\n function cleanupModifierEffects() {\n effectCleanupFns.forEach(function (fn) {\n return fn();\n });\n effectCleanupFns = [];\n }\n\n return instance;\n };\n}\nexport var createPopper = /*#__PURE__*/popperGenerator(); // eslint-disable-next-line import/no-unused-modules\n\nexport { detectOverflow };","import { popperGenerator, detectOverflow } from \"./createPopper.js\";\nimport eventListeners from \"./modifiers/eventListeners.js\";\nimport popperOffsets from \"./modifiers/popperOffsets.js\";\nimport computeStyles from \"./modifiers/computeStyles.js\";\nimport applyStyles from \"./modifiers/applyStyles.js\";\nimport offset from \"./modifiers/offset.js\";\nimport flip from \"./modifiers/flip.js\";\nimport preventOverflow from \"./modifiers/preventOverflow.js\";\nimport arrow from \"./modifiers/arrow.js\";\nimport hide from \"./modifiers/hide.js\";\nvar defaultModifiers = [eventListeners, popperOffsets, computeStyles, applyStyles, offset, flip, preventOverflow, arrow, hide];\nvar createPopper = /*#__PURE__*/popperGenerator({\n defaultModifiers: defaultModifiers\n}); // eslint-disable-next-line import/no-unused-modules\n\nexport { createPopper, popperGenerator, defaultModifiers, detectOverflow }; // eslint-disable-next-line import/no-unused-modules\n\nexport { createPopper as createPopperLite } from \"./popper-lite.js\"; // eslint-disable-next-line import/no-unused-modules\n\nexport * from \"./modifiers/index.js\";","import { generateUtilityClass } from '../generateUtilityClass';\nimport { generateUtilityClasses } from '../generateUtilityClasses';\nconst COMPONENT_NAME = 'Popper';\nexport function getPopperUtilityClass(slot) {\n return generateUtilityClass(COMPONENT_NAME, slot);\n}\nexport const popperClasses = generateUtilityClasses(COMPONENT_NAME, ['root']);","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"anchorEl\", \"children\", \"direction\", \"disablePortal\", \"modifiers\", \"open\", \"placement\", \"popperOptions\", \"popperRef\", \"slotProps\", \"slots\", \"TransitionProps\", \"ownerState\"],\n _excluded2 = [\"anchorEl\", \"children\", \"container\", \"direction\", \"disablePortal\", \"keepMounted\", \"modifiers\", \"open\", \"placement\", \"popperOptions\", \"popperRef\", \"style\", \"transition\", \"slotProps\", \"slots\"];\nimport * as React from 'react';\nimport { chainPropTypes, HTMLElementType, refType, unstable_ownerDocument as ownerDocument, unstable_useEnhancedEffect as useEnhancedEffect, unstable_useForkRef as useForkRef } from '@mui/utils';\nimport { createPopper } from '@popperjs/core';\nimport PropTypes from 'prop-types';\nimport { unstable_composeClasses as composeClasses } from '../composeClasses';\nimport { Portal } from '../Portal';\nimport { getPopperUtilityClass } from './popperClasses';\nimport { useSlotProps } from '../utils';\nimport { useClassNamesOverride } from '../utils/ClassNameConfigurator';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nfunction flipPlacement(placement, direction) {\n if (direction === 'ltr') {\n return placement;\n }\n switch (placement) {\n case 'bottom-end':\n return 'bottom-start';\n case 'bottom-start':\n return 'bottom-end';\n case 'top-end':\n return 'top-start';\n case 'top-start':\n return 'top-end';\n default:\n return placement;\n }\n}\nfunction resolveAnchorEl(anchorEl) {\n return typeof anchorEl === 'function' ? anchorEl() : anchorEl;\n}\nfunction isHTMLElement(element) {\n return element.nodeType !== undefined;\n}\nfunction isVirtualElement(element) {\n return !isHTMLElement(element);\n}\nconst useUtilityClasses = () => {\n const slots = {\n root: ['root']\n };\n return composeClasses(slots, useClassNamesOverride(getPopperUtilityClass));\n};\nconst defaultPopperOptions = {};\nconst PopperTooltip = /*#__PURE__*/React.forwardRef(function PopperTooltip(props, forwardedRef) {\n var _slots$root;\n const {\n anchorEl,\n children,\n direction,\n disablePortal,\n modifiers,\n open,\n placement: initialPlacement,\n popperOptions,\n popperRef: popperRefProp,\n slotProps = {},\n slots = {},\n TransitionProps\n // @ts-ignore internal logic\n // prevent from spreading to DOM, it can come from the parent component e.g. Select.\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const tooltipRef = React.useRef(null);\n const ownRef = useForkRef(tooltipRef, forwardedRef);\n const popperRef = React.useRef(null);\n const handlePopperRef = useForkRef(popperRef, popperRefProp);\n const handlePopperRefRef = React.useRef(handlePopperRef);\n useEnhancedEffect(() => {\n handlePopperRefRef.current = handlePopperRef;\n }, [handlePopperRef]);\n React.useImperativeHandle(popperRefProp, () => popperRef.current, []);\n const rtlPlacement = flipPlacement(initialPlacement, direction);\n /**\n * placement initialized from prop but can change during lifetime if modifiers.flip.\n * modifiers.flip is essentially a flip for controlled/uncontrolled behavior\n */\n const [placement, setPlacement] = React.useState(rtlPlacement);\n const [resolvedAnchorElement, setResolvedAnchorElement] = React.useState(resolveAnchorEl(anchorEl));\n React.useEffect(() => {\n if (popperRef.current) {\n popperRef.current.forceUpdate();\n }\n });\n React.useEffect(() => {\n if (anchorEl) {\n setResolvedAnchorElement(resolveAnchorEl(anchorEl));\n }\n }, [anchorEl]);\n useEnhancedEffect(() => {\n if (!resolvedAnchorElement || !open) {\n return undefined;\n }\n const handlePopperUpdate = data => {\n setPlacement(data.placement);\n };\n if (process.env.NODE_ENV !== 'production') {\n if (resolvedAnchorElement && isHTMLElement(resolvedAnchorElement) && resolvedAnchorElement.nodeType === 1) {\n const box = resolvedAnchorElement.getBoundingClientRect();\n if (process.env.NODE_ENV !== 'test' && box.top === 0 && box.left === 0 && box.right === 0 && box.bottom === 0) {\n console.warn(['MUI: The `anchorEl` prop provided to the component is invalid.', 'The anchor element should be part of the document layout.', \"Make sure the element is present in the document or that it's not display none.\"].join('\\n'));\n }\n }\n }\n let popperModifiers = [{\n name: 'preventOverflow',\n options: {\n altBoundary: disablePortal\n }\n }, {\n name: 'flip',\n options: {\n altBoundary: disablePortal\n }\n }, {\n name: 'onUpdate',\n enabled: true,\n phase: 'afterWrite',\n fn: ({\n state\n }) => {\n handlePopperUpdate(state);\n }\n }];\n if (modifiers != null) {\n popperModifiers = popperModifiers.concat(modifiers);\n }\n if (popperOptions && popperOptions.modifiers != null) {\n popperModifiers = popperModifiers.concat(popperOptions.modifiers);\n }\n const popper = createPopper(resolvedAnchorElement, tooltipRef.current, _extends({\n placement: rtlPlacement\n }, popperOptions, {\n modifiers: popperModifiers\n }));\n handlePopperRefRef.current(popper);\n return () => {\n popper.destroy();\n handlePopperRefRef.current(null);\n };\n }, [resolvedAnchorElement, disablePortal, modifiers, open, popperOptions, rtlPlacement]);\n const childProps = {\n placement: placement\n };\n if (TransitionProps !== null) {\n childProps.TransitionProps = TransitionProps;\n }\n const classes = useUtilityClasses();\n const Root = (_slots$root = slots.root) != null ? _slots$root : 'div';\n const rootProps = useSlotProps({\n elementType: Root,\n externalSlotProps: slotProps.root,\n externalForwardedProps: other,\n additionalProps: {\n role: 'tooltip',\n ref: ownRef\n },\n ownerState: props,\n className: classes.root\n });\n return /*#__PURE__*/_jsx(Root, _extends({}, rootProps, {\n children: typeof children === 'function' ? children(childProps) : children\n }));\n});\n\n/**\n * Poppers rely on the 3rd party library [Popper.js](https://popper.js.org/docs/v2/) for positioning.\n *\n * Demos:\n *\n * - [Popper](https://mui.com/base-ui/react-popper/)\n *\n * API:\n *\n * - [Popper API](https://mui.com/base-ui/react-popper/components-api/#popper)\n */\nconst Popper = /*#__PURE__*/React.forwardRef(function Popper(props, forwardedRef) {\n const {\n anchorEl,\n children,\n container: containerProp,\n direction = 'ltr',\n disablePortal = false,\n keepMounted = false,\n modifiers,\n open,\n placement = 'bottom',\n popperOptions = defaultPopperOptions,\n popperRef,\n style,\n transition = false,\n slotProps = {},\n slots = {}\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded2);\n const [exited, setExited] = React.useState(true);\n const handleEnter = () => {\n setExited(false);\n };\n const handleExited = () => {\n setExited(true);\n };\n if (!keepMounted && !open && (!transition || exited)) {\n return null;\n }\n\n // If the container prop is provided, use that\n // If the anchorEl prop is provided, use its parent body element as the container\n // If neither are provided let the Modal take care of choosing the container\n let container;\n if (containerProp) {\n container = containerProp;\n } else if (anchorEl) {\n const resolvedAnchorEl = resolveAnchorEl(anchorEl);\n container = resolvedAnchorEl && isHTMLElement(resolvedAnchorEl) ? ownerDocument(resolvedAnchorEl).body : ownerDocument(null).body;\n }\n const display = !open && keepMounted && (!transition || exited) ? 'none' : undefined;\n const transitionProps = transition ? {\n in: open,\n onEnter: handleEnter,\n onExited: handleExited\n } : undefined;\n return /*#__PURE__*/_jsx(Portal, {\n disablePortal: disablePortal,\n container: container,\n children: /*#__PURE__*/_jsx(PopperTooltip, _extends({\n anchorEl: anchorEl,\n direction: direction,\n disablePortal: disablePortal,\n modifiers: modifiers,\n ref: forwardedRef,\n open: transition ? !exited : open,\n placement: placement,\n popperOptions: popperOptions,\n popperRef: popperRef,\n slotProps: slotProps,\n slots: slots\n }, other, {\n style: _extends({\n // Prevents scroll issue, waiting for Popper.js to add this style once initiated.\n position: 'fixed',\n // Fix Popper.js display issue\n top: 0,\n left: 0,\n display\n }, style),\n TransitionProps: transitionProps,\n children: children\n }))\n });\n});\nprocess.env.NODE_ENV !== \"production\" ? Popper.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * An HTML element, [virtualElement](https://popper.js.org/docs/v2/virtual-elements/),\n * or a function that returns either.\n * It's used to set the position of the popper.\n * The return value will passed as the reference object of the Popper instance.\n */\n anchorEl: chainPropTypes(PropTypes.oneOfType([HTMLElementType, PropTypes.object, PropTypes.func]), props => {\n if (props.open) {\n const resolvedAnchorEl = resolveAnchorEl(props.anchorEl);\n if (resolvedAnchorEl && isHTMLElement(resolvedAnchorEl) && resolvedAnchorEl.nodeType === 1) {\n const box = resolvedAnchorEl.getBoundingClientRect();\n if (process.env.NODE_ENV !== 'test' && box.top === 0 && box.left === 0 && box.right === 0 && box.bottom === 0) {\n return new Error(['MUI: The `anchorEl` prop provided to the component is invalid.', 'The anchor element should be part of the document layout.', \"Make sure the element is present in the document or that it's not display none.\"].join('\\n'));\n }\n } else if (!resolvedAnchorEl || typeof resolvedAnchorEl.getBoundingClientRect !== 'function' || isVirtualElement(resolvedAnchorEl) && resolvedAnchorEl.contextElement != null && resolvedAnchorEl.contextElement.nodeType !== 1) {\n return new Error(['MUI: The `anchorEl` prop provided to the component is invalid.', 'It should be an HTML element instance or a virtualElement ', '(https://popper.js.org/docs/v2/virtual-elements/).'].join('\\n'));\n }\n }\n return null;\n }),\n /**\n * Popper render function or node.\n */\n children: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.node, PropTypes.func]),\n /**\n * An HTML element or function that returns one.\n * The `container` will have the portal children appended to it.\n *\n * You can also provide a callback, which is called in a React layout effect.\n * This lets you set the container from a ref, and also makes server-side rendering possible.\n *\n * By default, it uses the body of the top-level document object,\n * so it's simply `document.body` most of the time.\n */\n container: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.func]),\n /**\n * Direction of the text.\n * @default 'ltr'\n */\n direction: PropTypes.oneOf(['ltr', 'rtl']),\n /**\n * The `children` will be under the DOM hierarchy of the parent component.\n * @default false\n */\n disablePortal: PropTypes.bool,\n /**\n * Always keep the children in the DOM.\n * This prop can be useful in SEO situation or\n * when you want to maximize the responsiveness of the Popper.\n * @default false\n */\n keepMounted: PropTypes.bool,\n /**\n * Popper.js is based on a \"plugin-like\" architecture,\n * most of its features are fully encapsulated \"modifiers\".\n *\n * A modifier is a function that is called each time Popper.js needs to\n * compute the position of the popper.\n * For this reason, modifiers should be very performant to avoid bottlenecks.\n * To learn how to create a modifier, [read the modifiers documentation](https://popper.js.org/docs/v2/modifiers/).\n */\n modifiers: PropTypes.arrayOf(PropTypes.shape({\n data: PropTypes.object,\n effect: PropTypes.func,\n enabled: PropTypes.bool,\n fn: PropTypes.func,\n name: PropTypes.any,\n options: PropTypes.object,\n phase: PropTypes.oneOf(['afterMain', 'afterRead', 'afterWrite', 'beforeMain', 'beforeRead', 'beforeWrite', 'main', 'read', 'write']),\n requires: PropTypes.arrayOf(PropTypes.string),\n requiresIfExists: PropTypes.arrayOf(PropTypes.string)\n })),\n /**\n * If `true`, the component is shown.\n */\n open: PropTypes.bool.isRequired,\n /**\n * Popper placement.\n * @default 'bottom'\n */\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n /**\n * Options provided to the [`Popper.js`](https://popper.js.org/docs/v2/constructors/#options) instance.\n * @default {}\n */\n popperOptions: PropTypes.shape({\n modifiers: PropTypes.array,\n onFirstUpdate: PropTypes.func,\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n strategy: PropTypes.oneOf(['absolute', 'fixed'])\n }),\n /**\n * A ref that points to the used popper instance.\n */\n popperRef: refType,\n /**\n * The props used for each slot inside the Popper.\n * @default {}\n */\n slotProps: PropTypes.shape({\n root: PropTypes.oneOfType([PropTypes.func, PropTypes.object])\n }),\n /**\n * The components used for each slot inside the Popper.\n * Either a string to use a HTML element or a component.\n * @default {}\n */\n slots: PropTypes.shape({\n root: PropTypes.elementType\n }),\n /**\n * Help supporting a react-transition-group/Transition component.\n * @default false\n */\n transition: PropTypes.bool\n} : void 0;\nexport { Popper };","'use client';\n\nimport * as React from 'react';\nimport { useTheme as useThemeSystem } from '@mui/system';\nimport defaultTheme from './defaultTheme';\nimport THEME_ID from './identifier';\nexport default function useTheme() {\n const theme = useThemeSystem(defaultTheme);\n if (process.env.NODE_ENV !== 'production') {\n // eslint-disable-next-line react-hooks/rules-of-hooks\n React.useDebugValue(theme);\n }\n return theme[THEME_ID] || theme;\n}","export default function _setPrototypeOf(o, p) {\n _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function _setPrototypeOf(o, p) {\n o.__proto__ = p;\n return o;\n };\n return _setPrototypeOf(o, p);\n}","import setPrototypeOf from \"./setPrototypeOf.js\";\nexport default function _inheritsLoose(subClass, superClass) {\n subClass.prototype = Object.create(superClass.prototype);\n subClass.prototype.constructor = subClass;\n setPrototypeOf(subClass, superClass);\n}","export default {\n disabled: false\n};","import PropTypes from 'prop-types';\nexport var timeoutsShape = process.env.NODE_ENV !== 'production' ? PropTypes.oneOfType([PropTypes.number, PropTypes.shape({\n enter: PropTypes.number,\n exit: PropTypes.number,\n appear: PropTypes.number\n}).isRequired]) : null;\nexport var classNamesShape = process.env.NODE_ENV !== 'production' ? PropTypes.oneOfType([PropTypes.string, PropTypes.shape({\n enter: PropTypes.string,\n exit: PropTypes.string,\n active: PropTypes.string\n}), PropTypes.shape({\n enter: PropTypes.string,\n enterDone: PropTypes.string,\n enterActive: PropTypes.string,\n exit: PropTypes.string,\n exitDone: PropTypes.string,\n exitActive: PropTypes.string\n})]) : null;","import React from 'react';\nexport default React.createContext(null);","export var forceReflow = function forceReflow(node) {\n return node.scrollTop;\n};","import _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _inheritsLoose from \"@babel/runtime/helpers/esm/inheritsLoose\";\nimport PropTypes from 'prop-types';\nimport React from 'react';\nimport ReactDOM from 'react-dom';\nimport config from './config';\nimport { timeoutsShape } from './utils/PropTypes';\nimport TransitionGroupContext from './TransitionGroupContext';\nimport { forceReflow } from './utils/reflow';\nexport var UNMOUNTED = 'unmounted';\nexport var EXITED = 'exited';\nexport var ENTERING = 'entering';\nexport var ENTERED = 'entered';\nexport var EXITING = 'exiting';\n/**\n * The Transition component lets you describe a transition from one component\n * state to another _over time_ with a simple declarative API. Most commonly\n * it's used to animate the mounting and unmounting of a component, but can also\n * be used to describe in-place transition states as well.\n *\n * ---\n *\n * **Note**: `Transition` is a platform-agnostic base component. If you're using\n * transitions in CSS, you'll probably want to use\n * [`CSSTransition`](https://reactcommunity.org/react-transition-group/css-transition)\n * instead. It inherits all the features of `Transition`, but contains\n * additional features necessary to play nice with CSS transitions (hence the\n * name of the component).\n *\n * ---\n *\n * By default the `Transition` component does not alter the behavior of the\n * component it renders, it only tracks \"enter\" and \"exit\" states for the\n * components. It's up to you to give meaning and effect to those states. For\n * example we can add styles to a component when it enters or exits:\n *\n * ```jsx\n * import { Transition } from 'react-transition-group';\n *\n * const duration = 300;\n *\n * const defaultStyle = {\n * transition: `opacity ${duration}ms ease-in-out`,\n * opacity: 0,\n * }\n *\n * const transitionStyles = {\n * entering: { opacity: 1 },\n * entered: { opacity: 1 },\n * exiting: { opacity: 0 },\n * exited: { opacity: 0 },\n * };\n *\n * const Fade = ({ in: inProp }) => (\n * \n * {state => (\n *
    \n * I'm a fade Transition!\n *
    \n * )}\n *
    \n * );\n * ```\n *\n * There are 4 main states a Transition can be in:\n * - `'entering'`\n * - `'entered'`\n * - `'exiting'`\n * - `'exited'`\n *\n * Transition state is toggled via the `in` prop. When `true` the component\n * begins the \"Enter\" stage. During this stage, the component will shift from\n * its current transition state, to `'entering'` for the duration of the\n * transition and then to the `'entered'` stage once it's complete. Let's take\n * the following example (we'll use the\n * [useState](https://reactjs.org/docs/hooks-reference.html#usestate) hook):\n *\n * ```jsx\n * function App() {\n * const [inProp, setInProp] = useState(false);\n * return (\n *
    \n * \n * {state => (\n * // ...\n * )}\n * \n * \n *
    \n * );\n * }\n * ```\n *\n * When the button is clicked the component will shift to the `'entering'` state\n * and stay there for 500ms (the value of `timeout`) before it finally switches\n * to `'entered'`.\n *\n * When `in` is `false` the same thing happens except the state moves from\n * `'exiting'` to `'exited'`.\n */\n\nvar Transition = /*#__PURE__*/function (_React$Component) {\n _inheritsLoose(Transition, _React$Component);\n\n function Transition(props, context) {\n var _this;\n\n _this = _React$Component.call(this, props, context) || this;\n var parentGroup = context; // In the context of a TransitionGroup all enters are really appears\n\n var appear = parentGroup && !parentGroup.isMounting ? props.enter : props.appear;\n var initialStatus;\n _this.appearStatus = null;\n\n if (props.in) {\n if (appear) {\n initialStatus = EXITED;\n _this.appearStatus = ENTERING;\n } else {\n initialStatus = ENTERED;\n }\n } else {\n if (props.unmountOnExit || props.mountOnEnter) {\n initialStatus = UNMOUNTED;\n } else {\n initialStatus = EXITED;\n }\n }\n\n _this.state = {\n status: initialStatus\n };\n _this.nextCallback = null;\n return _this;\n }\n\n Transition.getDerivedStateFromProps = function getDerivedStateFromProps(_ref, prevState) {\n var nextIn = _ref.in;\n\n if (nextIn && prevState.status === UNMOUNTED) {\n return {\n status: EXITED\n };\n }\n\n return null;\n } // getSnapshotBeforeUpdate(prevProps) {\n // let nextStatus = null\n // if (prevProps !== this.props) {\n // const { status } = this.state\n // if (this.props.in) {\n // if (status !== ENTERING && status !== ENTERED) {\n // nextStatus = ENTERING\n // }\n // } else {\n // if (status === ENTERING || status === ENTERED) {\n // nextStatus = EXITING\n // }\n // }\n // }\n // return { nextStatus }\n // }\n ;\n\n var _proto = Transition.prototype;\n\n _proto.componentDidMount = function componentDidMount() {\n this.updateStatus(true, this.appearStatus);\n };\n\n _proto.componentDidUpdate = function componentDidUpdate(prevProps) {\n var nextStatus = null;\n\n if (prevProps !== this.props) {\n var status = this.state.status;\n\n if (this.props.in) {\n if (status !== ENTERING && status !== ENTERED) {\n nextStatus = ENTERING;\n }\n } else {\n if (status === ENTERING || status === ENTERED) {\n nextStatus = EXITING;\n }\n }\n }\n\n this.updateStatus(false, nextStatus);\n };\n\n _proto.componentWillUnmount = function componentWillUnmount() {\n this.cancelNextCallback();\n };\n\n _proto.getTimeouts = function getTimeouts() {\n var timeout = this.props.timeout;\n var exit, enter, appear;\n exit = enter = appear = timeout;\n\n if (timeout != null && typeof timeout !== 'number') {\n exit = timeout.exit;\n enter = timeout.enter; // TODO: remove fallback for next major\n\n appear = timeout.appear !== undefined ? timeout.appear : enter;\n }\n\n return {\n exit: exit,\n enter: enter,\n appear: appear\n };\n };\n\n _proto.updateStatus = function updateStatus(mounting, nextStatus) {\n if (mounting === void 0) {\n mounting = false;\n }\n\n if (nextStatus !== null) {\n // nextStatus will always be ENTERING or EXITING.\n this.cancelNextCallback();\n\n if (nextStatus === ENTERING) {\n if (this.props.unmountOnExit || this.props.mountOnEnter) {\n var node = this.props.nodeRef ? this.props.nodeRef.current : ReactDOM.findDOMNode(this); // https://github.com/reactjs/react-transition-group/pull/749\n // With unmountOnExit or mountOnEnter, the enter animation should happen at the transition between `exited` and `entering`.\n // To make the animation happen, we have to separate each rendering and avoid being processed as batched.\n\n if (node) forceReflow(node);\n }\n\n this.performEnter(mounting);\n } else {\n this.performExit();\n }\n } else if (this.props.unmountOnExit && this.state.status === EXITED) {\n this.setState({\n status: UNMOUNTED\n });\n }\n };\n\n _proto.performEnter = function performEnter(mounting) {\n var _this2 = this;\n\n var enter = this.props.enter;\n var appearing = this.context ? this.context.isMounting : mounting;\n\n var _ref2 = this.props.nodeRef ? [appearing] : [ReactDOM.findDOMNode(this), appearing],\n maybeNode = _ref2[0],\n maybeAppearing = _ref2[1];\n\n var timeouts = this.getTimeouts();\n var enterTimeout = appearing ? timeouts.appear : timeouts.enter; // no enter animation skip right to ENTERED\n // if we are mounting and running this it means appear _must_ be set\n\n if (!mounting && !enter || config.disabled) {\n this.safeSetState({\n status: ENTERED\n }, function () {\n _this2.props.onEntered(maybeNode);\n });\n return;\n }\n\n this.props.onEnter(maybeNode, maybeAppearing);\n this.safeSetState({\n status: ENTERING\n }, function () {\n _this2.props.onEntering(maybeNode, maybeAppearing);\n\n _this2.onTransitionEnd(enterTimeout, function () {\n _this2.safeSetState({\n status: ENTERED\n }, function () {\n _this2.props.onEntered(maybeNode, maybeAppearing);\n });\n });\n });\n };\n\n _proto.performExit = function performExit() {\n var _this3 = this;\n\n var exit = this.props.exit;\n var timeouts = this.getTimeouts();\n var maybeNode = this.props.nodeRef ? undefined : ReactDOM.findDOMNode(this); // no exit animation skip right to EXITED\n\n if (!exit || config.disabled) {\n this.safeSetState({\n status: EXITED\n }, function () {\n _this3.props.onExited(maybeNode);\n });\n return;\n }\n\n this.props.onExit(maybeNode);\n this.safeSetState({\n status: EXITING\n }, function () {\n _this3.props.onExiting(maybeNode);\n\n _this3.onTransitionEnd(timeouts.exit, function () {\n _this3.safeSetState({\n status: EXITED\n }, function () {\n _this3.props.onExited(maybeNode);\n });\n });\n });\n };\n\n _proto.cancelNextCallback = function cancelNextCallback() {\n if (this.nextCallback !== null) {\n this.nextCallback.cancel();\n this.nextCallback = null;\n }\n };\n\n _proto.safeSetState = function safeSetState(nextState, callback) {\n // This shouldn't be necessary, but there are weird race conditions with\n // setState callbacks and unmounting in testing, so always make sure that\n // we can cancel any pending setState callbacks after we unmount.\n callback = this.setNextCallback(callback);\n this.setState(nextState, callback);\n };\n\n _proto.setNextCallback = function setNextCallback(callback) {\n var _this4 = this;\n\n var active = true;\n\n this.nextCallback = function (event) {\n if (active) {\n active = false;\n _this4.nextCallback = null;\n callback(event);\n }\n };\n\n this.nextCallback.cancel = function () {\n active = false;\n };\n\n return this.nextCallback;\n };\n\n _proto.onTransitionEnd = function onTransitionEnd(timeout, handler) {\n this.setNextCallback(handler);\n var node = this.props.nodeRef ? this.props.nodeRef.current : ReactDOM.findDOMNode(this);\n var doesNotHaveTimeoutOrListener = timeout == null && !this.props.addEndListener;\n\n if (!node || doesNotHaveTimeoutOrListener) {\n setTimeout(this.nextCallback, 0);\n return;\n }\n\n if (this.props.addEndListener) {\n var _ref3 = this.props.nodeRef ? [this.nextCallback] : [node, this.nextCallback],\n maybeNode = _ref3[0],\n maybeNextCallback = _ref3[1];\n\n this.props.addEndListener(maybeNode, maybeNextCallback);\n }\n\n if (timeout != null) {\n setTimeout(this.nextCallback, timeout);\n }\n };\n\n _proto.render = function render() {\n var status = this.state.status;\n\n if (status === UNMOUNTED) {\n return null;\n }\n\n var _this$props = this.props,\n children = _this$props.children,\n _in = _this$props.in,\n _mountOnEnter = _this$props.mountOnEnter,\n _unmountOnExit = _this$props.unmountOnExit,\n _appear = _this$props.appear,\n _enter = _this$props.enter,\n _exit = _this$props.exit,\n _timeout = _this$props.timeout,\n _addEndListener = _this$props.addEndListener,\n _onEnter = _this$props.onEnter,\n _onEntering = _this$props.onEntering,\n _onEntered = _this$props.onEntered,\n _onExit = _this$props.onExit,\n _onExiting = _this$props.onExiting,\n _onExited = _this$props.onExited,\n _nodeRef = _this$props.nodeRef,\n childProps = _objectWithoutPropertiesLoose(_this$props, [\"children\", \"in\", \"mountOnEnter\", \"unmountOnExit\", \"appear\", \"enter\", \"exit\", \"timeout\", \"addEndListener\", \"onEnter\", \"onEntering\", \"onEntered\", \"onExit\", \"onExiting\", \"onExited\", \"nodeRef\"]);\n\n return (\n /*#__PURE__*/\n // allows for nested Transitions\n React.createElement(TransitionGroupContext.Provider, {\n value: null\n }, typeof children === 'function' ? children(status, childProps) : React.cloneElement(React.Children.only(children), childProps))\n );\n };\n\n return Transition;\n}(React.Component);\n\nTransition.contextType = TransitionGroupContext;\nTransition.propTypes = process.env.NODE_ENV !== \"production\" ? {\n /**\n * A React reference to DOM element that need to transition:\n * https://stackoverflow.com/a/51127130/4671932\n *\n * - When `nodeRef` prop is used, `node` is not passed to callback functions\n * (e.g. `onEnter`) because user already has direct access to the node.\n * - When changing `key` prop of `Transition` in a `TransitionGroup` a new\n * `nodeRef` need to be provided to `Transition` with changed `key` prop\n * (see\n * [test/CSSTransition-test.js](https://github.com/reactjs/react-transition-group/blob/13435f897b3ab71f6e19d724f145596f5910581c/test/CSSTransition-test.js#L362-L437)).\n */\n nodeRef: PropTypes.shape({\n current: typeof Element === 'undefined' ? PropTypes.any : function (propValue, key, componentName, location, propFullName, secret) {\n var value = propValue[key];\n return PropTypes.instanceOf(value && 'ownerDocument' in value ? value.ownerDocument.defaultView.Element : Element)(propValue, key, componentName, location, propFullName, secret);\n }\n }),\n\n /**\n * A `function` child can be used instead of a React element. This function is\n * called with the current transition status (`'entering'`, `'entered'`,\n * `'exiting'`, `'exited'`), which can be used to apply context\n * specific props to a component.\n *\n * ```jsx\n * \n * {state => (\n * \n * )}\n * \n * ```\n */\n children: PropTypes.oneOfType([PropTypes.func.isRequired, PropTypes.element.isRequired]).isRequired,\n\n /**\n * Show the component; triggers the enter or exit states\n */\n in: PropTypes.bool,\n\n /**\n * By default the child component is mounted immediately along with\n * the parent `Transition` component. If you want to \"lazy mount\" the component on the\n * first `in={true}` you can set `mountOnEnter`. After the first enter transition the component will stay\n * mounted, even on \"exited\", unless you also specify `unmountOnExit`.\n */\n mountOnEnter: PropTypes.bool,\n\n /**\n * By default the child component stays mounted after it reaches the `'exited'` state.\n * Set `unmountOnExit` if you'd prefer to unmount the component after it finishes exiting.\n */\n unmountOnExit: PropTypes.bool,\n\n /**\n * By default the child component does not perform the enter transition when\n * it first mounts, regardless of the value of `in`. If you want this\n * behavior, set both `appear` and `in` to `true`.\n *\n * > **Note**: there are no special appear states like `appearing`/`appeared`, this prop\n * > only adds an additional enter transition. However, in the\n * > `` component that first enter transition does result in\n * > additional `.appear-*` classes, that way you can choose to style it\n * > differently.\n */\n appear: PropTypes.bool,\n\n /**\n * Enable or disable enter transitions.\n */\n enter: PropTypes.bool,\n\n /**\n * Enable or disable exit transitions.\n */\n exit: PropTypes.bool,\n\n /**\n * The duration of the transition, in milliseconds.\n * Required unless `addEndListener` is provided.\n *\n * You may specify a single timeout for all transitions:\n *\n * ```jsx\n * timeout={500}\n * ```\n *\n * or individually:\n *\n * ```jsx\n * timeout={{\n * appear: 500,\n * enter: 300,\n * exit: 500,\n * }}\n * ```\n *\n * - `appear` defaults to the value of `enter`\n * - `enter` defaults to `0`\n * - `exit` defaults to `0`\n *\n * @type {number | { enter?: number, exit?: number, appear?: number }}\n */\n timeout: function timeout(props) {\n var pt = timeoutsShape;\n if (!props.addEndListener) pt = pt.isRequired;\n\n for (var _len = arguments.length, args = new Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) {\n args[_key - 1] = arguments[_key];\n }\n\n return pt.apply(void 0, [props].concat(args));\n },\n\n /**\n * Add a custom transition end trigger. Called with the transitioning\n * DOM node and a `done` callback. Allows for more fine grained transition end\n * logic. Timeouts are still used as a fallback if provided.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * ```jsx\n * addEndListener={(node, done) => {\n * // use the css transitionend event to mark the finish of a transition\n * node.addEventListener('transitionend', done, false);\n * }}\n * ```\n */\n addEndListener: PropTypes.func,\n\n /**\n * Callback fired before the \"entering\" status is applied. An extra parameter\n * `isAppearing` is supplied to indicate if the enter stage is occurring on the initial mount\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement, isAppearing: bool) -> void\n */\n onEnter: PropTypes.func,\n\n /**\n * Callback fired after the \"entering\" status is applied. An extra parameter\n * `isAppearing` is supplied to indicate if the enter stage is occurring on the initial mount\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement, isAppearing: bool)\n */\n onEntering: PropTypes.func,\n\n /**\n * Callback fired after the \"entered\" status is applied. An extra parameter\n * `isAppearing` is supplied to indicate if the enter stage is occurring on the initial mount\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement, isAppearing: bool) -> void\n */\n onEntered: PropTypes.func,\n\n /**\n * Callback fired before the \"exiting\" status is applied.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement) -> void\n */\n onExit: PropTypes.func,\n\n /**\n * Callback fired after the \"exiting\" status is applied.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement) -> void\n */\n onExiting: PropTypes.func,\n\n /**\n * Callback fired after the \"exited\" status is applied.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed\n *\n * @type Function(node: HtmlElement) -> void\n */\n onExited: PropTypes.func\n} : {}; // Name the function so it is clearer in the documentation\n\nfunction noop() {}\n\nTransition.defaultProps = {\n in: false,\n mountOnEnter: false,\n unmountOnExit: false,\n appear: false,\n enter: true,\n exit: true,\n onEnter: noop,\n onEntering: noop,\n onEntered: noop,\n onExit: noop,\n onExiting: noop,\n onExited: noop\n};\nTransition.UNMOUNTED = UNMOUNTED;\nTransition.EXITED = EXITED;\nTransition.ENTERING = ENTERING;\nTransition.ENTERED = ENTERED;\nTransition.EXITING = EXITING;\nexport default Transition;","export const reflow = node => node.scrollTop;\nexport function getTransitionProps(props, options) {\n var _style$transitionDura, _style$transitionTimi;\n const {\n timeout,\n easing,\n style = {}\n } = props;\n return {\n duration: (_style$transitionDura = style.transitionDuration) != null ? _style$transitionDura : typeof timeout === 'number' ? timeout : timeout[options.mode] || 0,\n easing: (_style$transitionTimi = style.transitionTimingFunction) != null ? _style$transitionTimi : typeof easing === 'object' ? easing[options.mode] : easing,\n delay: style.transitionDelay\n };\n}","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"addEndListener\", \"appear\", \"children\", \"easing\", \"in\", \"onEnter\", \"onEntered\", \"onEntering\", \"onExit\", \"onExited\", \"onExiting\", \"style\", \"timeout\", \"TransitionComponent\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport { elementAcceptingRef, unstable_useTimeout as useTimeout } from '@mui/utils';\nimport { Transition } from 'react-transition-group';\nimport useTheme from '../styles/useTheme';\nimport { getTransitionProps, reflow } from '../transitions/utils';\nimport useForkRef from '../utils/useForkRef';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nfunction getScale(value) {\n return `scale(${value}, ${value ** 2})`;\n}\nconst styles = {\n entering: {\n opacity: 1,\n transform: getScale(1)\n },\n entered: {\n opacity: 1,\n transform: 'none'\n }\n};\n\n/*\n TODO v6: remove\n Conditionally apply a workaround for the CSS transition bug in Safari 15.4 / WebKit browsers.\n */\nconst isWebKit154 = typeof navigator !== 'undefined' && /^((?!chrome|android).)*(safari|mobile)/i.test(navigator.userAgent) && /(os |version\\/)15(.|_)4/i.test(navigator.userAgent);\n\n/**\n * The Grow transition is used by the [Tooltip](/material-ui/react-tooltip/) and\n * [Popover](/material-ui/react-popover/) components.\n * It uses [react-transition-group](https://github.com/reactjs/react-transition-group) internally.\n */\nconst Grow = /*#__PURE__*/React.forwardRef(function Grow(props, ref) {\n const {\n addEndListener,\n appear = true,\n children,\n easing,\n in: inProp,\n onEnter,\n onEntered,\n onEntering,\n onExit,\n onExited,\n onExiting,\n style,\n timeout = 'auto',\n // eslint-disable-next-line react/prop-types\n TransitionComponent = Transition\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const timer = useTimeout();\n const autoTimeout = React.useRef();\n const theme = useTheme();\n const nodeRef = React.useRef(null);\n const handleRef = useForkRef(nodeRef, children.ref, ref);\n const normalizedTransitionCallback = callback => maybeIsAppearing => {\n if (callback) {\n const node = nodeRef.current;\n\n // onEnterXxx and onExitXxx callbacks have a different arguments.length value.\n if (maybeIsAppearing === undefined) {\n callback(node);\n } else {\n callback(node, maybeIsAppearing);\n }\n }\n };\n const handleEntering = normalizedTransitionCallback(onEntering);\n const handleEnter = normalizedTransitionCallback((node, isAppearing) => {\n reflow(node); // So the animation always start from the start.\n\n const {\n duration: transitionDuration,\n delay,\n easing: transitionTimingFunction\n } = getTransitionProps({\n style,\n timeout,\n easing\n }, {\n mode: 'enter'\n });\n let duration;\n if (timeout === 'auto') {\n duration = theme.transitions.getAutoHeightDuration(node.clientHeight);\n autoTimeout.current = duration;\n } else {\n duration = transitionDuration;\n }\n node.style.transition = [theme.transitions.create('opacity', {\n duration,\n delay\n }), theme.transitions.create('transform', {\n duration: isWebKit154 ? duration : duration * 0.666,\n delay,\n easing: transitionTimingFunction\n })].join(',');\n if (onEnter) {\n onEnter(node, isAppearing);\n }\n });\n const handleEntered = normalizedTransitionCallback(onEntered);\n const handleExiting = normalizedTransitionCallback(onExiting);\n const handleExit = normalizedTransitionCallback(node => {\n const {\n duration: transitionDuration,\n delay,\n easing: transitionTimingFunction\n } = getTransitionProps({\n style,\n timeout,\n easing\n }, {\n mode: 'exit'\n });\n let duration;\n if (timeout === 'auto') {\n duration = theme.transitions.getAutoHeightDuration(node.clientHeight);\n autoTimeout.current = duration;\n } else {\n duration = transitionDuration;\n }\n node.style.transition = [theme.transitions.create('opacity', {\n duration,\n delay\n }), theme.transitions.create('transform', {\n duration: isWebKit154 ? duration : duration * 0.666,\n delay: isWebKit154 ? delay : delay || duration * 0.333,\n easing: transitionTimingFunction\n })].join(',');\n node.style.opacity = 0;\n node.style.transform = getScale(0.75);\n if (onExit) {\n onExit(node);\n }\n });\n const handleExited = normalizedTransitionCallback(onExited);\n const handleAddEndListener = next => {\n if (timeout === 'auto') {\n timer.start(autoTimeout.current || 0, next);\n }\n if (addEndListener) {\n // Old call signature before `react-transition-group` implemented `nodeRef`\n addEndListener(nodeRef.current, next);\n }\n };\n return /*#__PURE__*/_jsx(TransitionComponent, _extends({\n appear: appear,\n in: inProp,\n nodeRef: nodeRef,\n onEnter: handleEnter,\n onEntered: handleEntered,\n onEntering: handleEntering,\n onExit: handleExit,\n onExited: handleExited,\n onExiting: handleExiting,\n addEndListener: handleAddEndListener,\n timeout: timeout === 'auto' ? null : timeout\n }, other, {\n children: (state, childProps) => {\n return /*#__PURE__*/React.cloneElement(children, _extends({\n style: _extends({\n opacity: 0,\n transform: getScale(0.75),\n visibility: state === 'exited' && !inProp ? 'hidden' : undefined\n }, styles[state], style, children.props.style),\n ref: handleRef\n }, childProps));\n }\n }));\n});\nprocess.env.NODE_ENV !== \"production\" ? Grow.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the d.ts file and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * Add a custom transition end trigger. Called with the transitioning DOM\n * node and a done callback. Allows for more fine grained transition end\n * logic. Note: Timeouts are still used as a fallback if provided.\n */\n addEndListener: PropTypes.func,\n /**\n * Perform the enter transition when it first mounts if `in` is also `true`.\n * Set this to `false` to disable this behavior.\n * @default true\n */\n appear: PropTypes.bool,\n /**\n * A single child content element.\n */\n children: elementAcceptingRef.isRequired,\n /**\n * The transition timing function.\n * You may specify a single easing or a object containing enter and exit values.\n */\n easing: PropTypes.oneOfType([PropTypes.shape({\n enter: PropTypes.string,\n exit: PropTypes.string\n }), PropTypes.string]),\n /**\n * If `true`, the component will transition in.\n */\n in: PropTypes.bool,\n /**\n * @ignore\n */\n onEnter: PropTypes.func,\n /**\n * @ignore\n */\n onEntered: PropTypes.func,\n /**\n * @ignore\n */\n onEntering: PropTypes.func,\n /**\n * @ignore\n */\n onExit: PropTypes.func,\n /**\n * @ignore\n */\n onExited: PropTypes.func,\n /**\n * @ignore\n */\n onExiting: PropTypes.func,\n /**\n * @ignore\n */\n style: PropTypes.object,\n /**\n * The duration for the transition, in milliseconds.\n * You may specify a single timeout for all transitions, or individually with an object.\n *\n * Set to 'auto' to automatically calculate transition time based on height.\n * @default 'auto'\n */\n timeout: PropTypes.oneOfType([PropTypes.oneOf(['auto']), PropTypes.number, PropTypes.shape({\n appear: PropTypes.number,\n enter: PropTypes.number,\n exit: PropTypes.number\n })])\n} : void 0;\nGrow.muiSupportAuto = true;\nexport default Grow;","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"anchorEl\", \"component\", \"components\", \"componentsProps\", \"container\", \"disablePortal\", \"keepMounted\", \"modifiers\", \"open\", \"placement\", \"popperOptions\", \"popperRef\", \"transition\", \"slots\", \"slotProps\"];\nimport { Popper as BasePopper } from '@mui/base/Popper';\nimport { useThemeWithoutDefault as useTheme } from '@mui/system';\nimport { HTMLElementType, refType } from '@mui/utils';\nimport PropTypes from 'prop-types';\nimport * as React from 'react';\nimport { styled, useThemeProps } from '../styles';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nconst PopperRoot = styled(BasePopper, {\n name: 'MuiPopper',\n slot: 'Root',\n overridesResolver: (props, styles) => styles.root\n})({});\n\n/**\n *\n * Demos:\n *\n * - [Autocomplete](https://mui.com/material-ui/react-autocomplete/)\n * - [Menu](https://mui.com/material-ui/react-menu/)\n * - [Popper](https://mui.com/material-ui/react-popper/)\n *\n * API:\n *\n * - [Popper API](https://mui.com/material-ui/api/popper/)\n */\nconst Popper = /*#__PURE__*/React.forwardRef(function Popper(inProps, ref) {\n var _slots$root;\n const theme = useTheme();\n const props = useThemeProps({\n props: inProps,\n name: 'MuiPopper'\n });\n const {\n anchorEl,\n component,\n components,\n componentsProps,\n container,\n disablePortal,\n keepMounted,\n modifiers,\n open,\n placement,\n popperOptions,\n popperRef,\n transition,\n slots,\n slotProps\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const RootComponent = (_slots$root = slots == null ? void 0 : slots.root) != null ? _slots$root : components == null ? void 0 : components.Root;\n const otherProps = _extends({\n anchorEl,\n container,\n disablePortal,\n keepMounted,\n modifiers,\n open,\n placement,\n popperOptions,\n popperRef,\n transition\n }, other);\n return /*#__PURE__*/_jsx(PopperRoot, _extends({\n as: component,\n direction: theme == null ? void 0 : theme.direction,\n slots: {\n root: RootComponent\n },\n slotProps: slotProps != null ? slotProps : componentsProps\n }, otherProps, {\n ref: ref\n }));\n});\nprocess.env.NODE_ENV !== \"production\" ? Popper.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * An HTML element, [virtualElement](https://popper.js.org/docs/v2/virtual-elements/),\n * or a function that returns either.\n * It's used to set the position of the popper.\n * The return value will passed as the reference object of the Popper instance.\n */\n anchorEl: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.object, PropTypes.func]),\n /**\n * Popper render function or node.\n */\n children: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.node, PropTypes.func]),\n /**\n * The component used for the root node.\n * Either a string to use a HTML element or a component.\n */\n component: PropTypes.elementType,\n /**\n * The components used for each slot inside the Popper.\n * Either a string to use a HTML element or a component.\n * @default {}\n */\n components: PropTypes.shape({\n Root: PropTypes.elementType\n }),\n /**\n * The props used for each slot inside the Popper.\n * @default {}\n */\n componentsProps: PropTypes.shape({\n root: PropTypes.oneOfType([PropTypes.func, PropTypes.object])\n }),\n /**\n * An HTML element or function that returns one.\n * The `container` will have the portal children appended to it.\n *\n * You can also provide a callback, which is called in a React layout effect.\n * This lets you set the container from a ref, and also makes server-side rendering possible.\n *\n * By default, it uses the body of the top-level document object,\n * so it's simply `document.body` most of the time.\n */\n container: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.func]),\n /**\n * The `children` will be under the DOM hierarchy of the parent component.\n * @default false\n */\n disablePortal: PropTypes.bool,\n /**\n * Always keep the children in the DOM.\n * This prop can be useful in SEO situation or\n * when you want to maximize the responsiveness of the Popper.\n * @default false\n */\n keepMounted: PropTypes.bool,\n /**\n * Popper.js is based on a \"plugin-like\" architecture,\n * most of its features are fully encapsulated \"modifiers\".\n *\n * A modifier is a function that is called each time Popper.js needs to\n * compute the position of the popper.\n * For this reason, modifiers should be very performant to avoid bottlenecks.\n * To learn how to create a modifier, [read the modifiers documentation](https://popper.js.org/docs/v2/modifiers/).\n */\n modifiers: PropTypes.arrayOf(PropTypes.shape({\n data: PropTypes.object,\n effect: PropTypes.func,\n enabled: PropTypes.bool,\n fn: PropTypes.func,\n name: PropTypes.any,\n options: PropTypes.object,\n phase: PropTypes.oneOf(['afterMain', 'afterRead', 'afterWrite', 'beforeMain', 'beforeRead', 'beforeWrite', 'main', 'read', 'write']),\n requires: PropTypes.arrayOf(PropTypes.string),\n requiresIfExists: PropTypes.arrayOf(PropTypes.string)\n })),\n /**\n * If `true`, the component is shown.\n */\n open: PropTypes.bool.isRequired,\n /**\n * Popper placement.\n * @default 'bottom'\n */\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n /**\n * Options provided to the [`Popper.js`](https://popper.js.org/docs/v2/constructors/#options) instance.\n * @default {}\n */\n popperOptions: PropTypes.shape({\n modifiers: PropTypes.array,\n onFirstUpdate: PropTypes.func,\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n strategy: PropTypes.oneOf(['absolute', 'fixed'])\n }),\n /**\n * A ref that points to the used popper instance.\n */\n popperRef: refType,\n /**\n * The props used for each slot inside the Popper.\n * @default {}\n */\n slotProps: PropTypes.shape({\n root: PropTypes.oneOfType([PropTypes.func, PropTypes.object])\n }),\n /**\n * The components used for each slot inside the Popper.\n * Either a string to use a HTML element or a component.\n * @default {}\n */\n slots: PropTypes.shape({\n root: PropTypes.elementType\n }),\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Help supporting a react-transition-group/Transition component.\n * @default false\n */\n transition: PropTypes.bool\n} : void 0;\nexport default Popper;","import generateUtilityClasses from '@mui/utils/generateUtilityClasses';\nimport generateUtilityClass from '@mui/utils/generateUtilityClass';\nexport function getTooltipUtilityClass(slot) {\n return generateUtilityClass('MuiTooltip', slot);\n}\nconst tooltipClasses = generateUtilityClasses('MuiTooltip', ['popper', 'popperInteractive', 'popperArrow', 'popperClose', 'tooltip', 'tooltipArrow', 'touch', 'tooltipPlacementLeft', 'tooltipPlacementRight', 'tooltipPlacementTop', 'tooltipPlacementBottom', 'arrow']);\nexport default tooltipClasses;","'use client';\n\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nconst _excluded = [\"arrow\", \"children\", \"classes\", \"components\", \"componentsProps\", \"describeChild\", \"disableFocusListener\", \"disableHoverListener\", \"disableInteractive\", \"disableTouchListener\", \"enterDelay\", \"enterNextDelay\", \"enterTouchDelay\", \"followCursor\", \"id\", \"leaveDelay\", \"leaveTouchDelay\", \"onClose\", \"onOpen\", \"open\", \"placement\", \"PopperComponent\", \"PopperProps\", \"slotProps\", \"slots\", \"title\", \"TransitionComponent\", \"TransitionProps\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport clsx from 'clsx';\nimport { elementAcceptingRef, unstable_useTimeout as useTimeout, unstable_Timeout as Timeout } from '@mui/utils';\nimport { unstable_composeClasses as composeClasses, appendOwnerState } from '@mui/base';\nimport { alpha } from '@mui/system';\nimport styled from '../styles/styled';\nimport useTheme from '../styles/useTheme';\nimport useThemeProps from '../styles/useThemeProps';\nimport capitalize from '../utils/capitalize';\nimport Grow from '../Grow';\nimport Popper from '../Popper';\nimport useEventCallback from '../utils/useEventCallback';\nimport useForkRef from '../utils/useForkRef';\nimport useId from '../utils/useId';\nimport useIsFocusVisible from '../utils/useIsFocusVisible';\nimport useControlled from '../utils/useControlled';\nimport tooltipClasses, { getTooltipUtilityClass } from './tooltipClasses';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nimport { jsxs as _jsxs } from \"react/jsx-runtime\";\nfunction round(value) {\n return Math.round(value * 1e5) / 1e5;\n}\nconst useUtilityClasses = ownerState => {\n const {\n classes,\n disableInteractive,\n arrow,\n touch,\n placement\n } = ownerState;\n const slots = {\n popper: ['popper', !disableInteractive && 'popperInteractive', arrow && 'popperArrow'],\n tooltip: ['tooltip', arrow && 'tooltipArrow', touch && 'touch', `tooltipPlacement${capitalize(placement.split('-')[0])}`],\n arrow: ['arrow']\n };\n return composeClasses(slots, getTooltipUtilityClass, classes);\n};\nconst TooltipPopper = styled(Popper, {\n name: 'MuiTooltip',\n slot: 'Popper',\n overridesResolver: (props, styles) => {\n const {\n ownerState\n } = props;\n return [styles.popper, !ownerState.disableInteractive && styles.popperInteractive, ownerState.arrow && styles.popperArrow, !ownerState.open && styles.popperClose];\n }\n})(({\n theme,\n ownerState,\n open\n}) => _extends({\n zIndex: (theme.vars || theme).zIndex.tooltip,\n pointerEvents: 'none'\n}, !ownerState.disableInteractive && {\n pointerEvents: 'auto'\n}, !open && {\n pointerEvents: 'none'\n}, ownerState.arrow && {\n [`&[data-popper-placement*=\"bottom\"] .${tooltipClasses.arrow}`]: {\n top: 0,\n marginTop: '-0.71em',\n '&::before': {\n transformOrigin: '0 100%'\n }\n },\n [`&[data-popper-placement*=\"top\"] .${tooltipClasses.arrow}`]: {\n bottom: 0,\n marginBottom: '-0.71em',\n '&::before': {\n transformOrigin: '100% 0'\n }\n },\n [`&[data-popper-placement*=\"right\"] .${tooltipClasses.arrow}`]: _extends({}, !ownerState.isRtl ? {\n left: 0,\n marginLeft: '-0.71em'\n } : {\n right: 0,\n marginRight: '-0.71em'\n }, {\n height: '1em',\n width: '0.71em',\n '&::before': {\n transformOrigin: '100% 100%'\n }\n }),\n [`&[data-popper-placement*=\"left\"] .${tooltipClasses.arrow}`]: _extends({}, !ownerState.isRtl ? {\n right: 0,\n marginRight: '-0.71em'\n } : {\n left: 0,\n marginLeft: '-0.71em'\n }, {\n height: '1em',\n width: '0.71em',\n '&::before': {\n transformOrigin: '0 0'\n }\n })\n}));\nconst TooltipTooltip = styled('div', {\n name: 'MuiTooltip',\n slot: 'Tooltip',\n overridesResolver: (props, styles) => {\n const {\n ownerState\n } = props;\n return [styles.tooltip, ownerState.touch && styles.touch, ownerState.arrow && styles.tooltipArrow, styles[`tooltipPlacement${capitalize(ownerState.placement.split('-')[0])}`]];\n }\n})(({\n theme,\n ownerState\n}) => _extends({\n backgroundColor: theme.vars ? theme.vars.palette.Tooltip.bg : alpha(theme.palette.grey[700], 0.92),\n borderRadius: (theme.vars || theme).shape.borderRadius,\n color: (theme.vars || theme).palette.common.white,\n fontFamily: theme.typography.fontFamily,\n padding: '4px 8px',\n fontSize: theme.typography.pxToRem(11),\n maxWidth: 300,\n margin: 2,\n wordWrap: 'break-word',\n fontWeight: theme.typography.fontWeightMedium\n}, ownerState.arrow && {\n position: 'relative',\n margin: 0\n}, ownerState.touch && {\n padding: '8px 16px',\n fontSize: theme.typography.pxToRem(14),\n lineHeight: `${round(16 / 14)}em`,\n fontWeight: theme.typography.fontWeightRegular\n}, {\n [`.${tooltipClasses.popper}[data-popper-placement*=\"left\"] &`]: _extends({\n transformOrigin: 'right center'\n }, !ownerState.isRtl ? _extends({\n marginRight: '14px'\n }, ownerState.touch && {\n marginRight: '24px'\n }) : _extends({\n marginLeft: '14px'\n }, ownerState.touch && {\n marginLeft: '24px'\n })),\n [`.${tooltipClasses.popper}[data-popper-placement*=\"right\"] &`]: _extends({\n transformOrigin: 'left center'\n }, !ownerState.isRtl ? _extends({\n marginLeft: '14px'\n }, ownerState.touch && {\n marginLeft: '24px'\n }) : _extends({\n marginRight: '14px'\n }, ownerState.touch && {\n marginRight: '24px'\n })),\n [`.${tooltipClasses.popper}[data-popper-placement*=\"top\"] &`]: _extends({\n transformOrigin: 'center bottom',\n marginBottom: '14px'\n }, ownerState.touch && {\n marginBottom: '24px'\n }),\n [`.${tooltipClasses.popper}[data-popper-placement*=\"bottom\"] &`]: _extends({\n transformOrigin: 'center top',\n marginTop: '14px'\n }, ownerState.touch && {\n marginTop: '24px'\n })\n}));\nconst TooltipArrow = styled('span', {\n name: 'MuiTooltip',\n slot: 'Arrow',\n overridesResolver: (props, styles) => styles.arrow\n})(({\n theme\n}) => ({\n overflow: 'hidden',\n position: 'absolute',\n width: '1em',\n height: '0.71em' /* = width / sqrt(2) = (length of the hypotenuse) */,\n boxSizing: 'border-box',\n color: theme.vars ? theme.vars.palette.Tooltip.bg : alpha(theme.palette.grey[700], 0.9),\n '&::before': {\n content: '\"\"',\n margin: 'auto',\n display: 'block',\n width: '100%',\n height: '100%',\n backgroundColor: 'currentColor',\n transform: 'rotate(45deg)'\n }\n}));\nlet hystersisOpen = false;\nconst hystersisTimer = new Timeout();\nlet cursorPosition = {\n x: 0,\n y: 0\n};\nexport function testReset() {\n hystersisOpen = false;\n hystersisTimer.clear();\n}\nfunction composeEventHandler(handler, eventHandler) {\n return event => {\n if (eventHandler) {\n eventHandler(event);\n }\n handler(event);\n };\n}\n\n// TODO v6: Remove PopperComponent, PopperProps, TransitionComponent and TransitionProps.\nconst Tooltip = /*#__PURE__*/React.forwardRef(function Tooltip(inProps, ref) {\n var _ref, _slots$popper, _ref2, _ref3, _slots$transition, _ref4, _slots$tooltip, _ref5, _slots$arrow, _slotProps$popper, _ref6, _slotProps$popper2, _slotProps$transition, _slotProps$tooltip, _ref7, _slotProps$tooltip2, _slotProps$arrow, _ref8, _slotProps$arrow2;\n const props = useThemeProps({\n props: inProps,\n name: 'MuiTooltip'\n });\n const {\n arrow = false,\n children: childrenProp,\n components = {},\n componentsProps = {},\n describeChild = false,\n disableFocusListener = false,\n disableHoverListener = false,\n disableInteractive: disableInteractiveProp = false,\n disableTouchListener = false,\n enterDelay = 100,\n enterNextDelay = 0,\n enterTouchDelay = 700,\n followCursor = false,\n id: idProp,\n leaveDelay = 0,\n leaveTouchDelay = 1500,\n onClose,\n onOpen,\n open: openProp,\n placement = 'bottom',\n PopperComponent: PopperComponentProp,\n PopperProps = {},\n slotProps = {},\n slots = {},\n title,\n TransitionComponent: TransitionComponentProp = Grow,\n TransitionProps\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n\n // to prevent runtime errors, developers will need to provide a child as a React element anyway.\n const children = /*#__PURE__*/React.isValidElement(childrenProp) ? childrenProp : /*#__PURE__*/_jsx(\"span\", {\n children: childrenProp\n });\n const theme = useTheme();\n const isRtl = theme.direction === 'rtl';\n const [childNode, setChildNode] = React.useState();\n const [arrowRef, setArrowRef] = React.useState(null);\n const ignoreNonTouchEvents = React.useRef(false);\n const disableInteractive = disableInteractiveProp || followCursor;\n const closeTimer = useTimeout();\n const enterTimer = useTimeout();\n const leaveTimer = useTimeout();\n const touchTimer = useTimeout();\n const [openState, setOpenState] = useControlled({\n controlled: openProp,\n default: false,\n name: 'Tooltip',\n state: 'open'\n });\n let open = openState;\n if (process.env.NODE_ENV !== 'production') {\n // eslint-disable-next-line react-hooks/rules-of-hooks\n const {\n current: isControlled\n } = React.useRef(openProp !== undefined);\n\n // eslint-disable-next-line react-hooks/rules-of-hooks\n React.useEffect(() => {\n if (childNode && childNode.disabled && !isControlled && title !== '' && childNode.tagName.toLowerCase() === 'button') {\n console.error(['MUI: You are providing a disabled `button` child to the Tooltip component.', 'A disabled element does not fire events.', \"Tooltip needs to listen to the child element's events to display the title.\", '', 'Add a simple wrapper element, such as a `span`.'].join('\\n'));\n }\n }, [title, childNode, isControlled]);\n }\n const id = useId(idProp);\n const prevUserSelect = React.useRef();\n const stopTouchInteraction = useEventCallback(() => {\n if (prevUserSelect.current !== undefined) {\n document.body.style.WebkitUserSelect = prevUserSelect.current;\n prevUserSelect.current = undefined;\n }\n touchTimer.clear();\n });\n React.useEffect(() => stopTouchInteraction, [stopTouchInteraction]);\n const handleOpen = event => {\n hystersisTimer.clear();\n hystersisOpen = true;\n\n // The mouseover event will trigger for every nested element in the tooltip.\n // We can skip rerendering when the tooltip is already open.\n // We are using the mouseover event instead of the mouseenter event to fix a hide/show issue.\n setOpenState(true);\n if (onOpen && !open) {\n onOpen(event);\n }\n };\n const handleClose = useEventCallback(\n /**\n * @param {React.SyntheticEvent | Event} event\n */\n event => {\n hystersisTimer.start(800 + leaveDelay, () => {\n hystersisOpen = false;\n });\n setOpenState(false);\n if (onClose && open) {\n onClose(event);\n }\n closeTimer.start(theme.transitions.duration.shortest, () => {\n ignoreNonTouchEvents.current = false;\n });\n });\n const handleEnter = event => {\n if (ignoreNonTouchEvents.current && event.type !== 'touchstart') {\n return;\n }\n\n // Remove the title ahead of time.\n // We don't want to wait for the next render commit.\n // We would risk displaying two tooltips at the same time (native + this one).\n if (childNode) {\n childNode.removeAttribute('title');\n }\n enterTimer.clear();\n leaveTimer.clear();\n if (enterDelay || hystersisOpen && enterNextDelay) {\n enterTimer.start(hystersisOpen ? enterNextDelay : enterDelay, () => {\n handleOpen(event);\n });\n } else {\n handleOpen(event);\n }\n };\n const handleLeave = event => {\n enterTimer.clear();\n leaveTimer.start(leaveDelay, () => {\n handleClose(event);\n });\n };\n const {\n isFocusVisibleRef,\n onBlur: handleBlurVisible,\n onFocus: handleFocusVisible,\n ref: focusVisibleRef\n } = useIsFocusVisible();\n // We don't necessarily care about the focusVisible state (which is safe to access via ref anyway).\n // We just need to re-render the Tooltip if the focus-visible state changes.\n const [, setChildIsFocusVisible] = React.useState(false);\n const handleBlur = event => {\n handleBlurVisible(event);\n if (isFocusVisibleRef.current === false) {\n setChildIsFocusVisible(false);\n handleLeave(event);\n }\n };\n const handleFocus = event => {\n // Workaround for https://github.com/facebook/react/issues/7769\n // The autoFocus of React might trigger the event before the componentDidMount.\n // We need to account for this eventuality.\n if (!childNode) {\n setChildNode(event.currentTarget);\n }\n handleFocusVisible(event);\n if (isFocusVisibleRef.current === true) {\n setChildIsFocusVisible(true);\n handleEnter(event);\n }\n };\n const detectTouchStart = event => {\n ignoreNonTouchEvents.current = true;\n const childrenProps = children.props;\n if (childrenProps.onTouchStart) {\n childrenProps.onTouchStart(event);\n }\n };\n const handleMouseOver = handleEnter;\n const handleMouseLeave = handleLeave;\n const handleTouchStart = event => {\n detectTouchStart(event);\n leaveTimer.clear();\n closeTimer.clear();\n stopTouchInteraction();\n prevUserSelect.current = document.body.style.WebkitUserSelect;\n // Prevent iOS text selection on long-tap.\n document.body.style.WebkitUserSelect = 'none';\n touchTimer.start(enterTouchDelay, () => {\n document.body.style.WebkitUserSelect = prevUserSelect.current;\n handleEnter(event);\n });\n };\n const handleTouchEnd = event => {\n if (children.props.onTouchEnd) {\n children.props.onTouchEnd(event);\n }\n stopTouchInteraction();\n leaveTimer.start(leaveTouchDelay, () => {\n handleClose(event);\n });\n };\n React.useEffect(() => {\n if (!open) {\n return undefined;\n }\n\n /**\n * @param {KeyboardEvent} nativeEvent\n */\n function handleKeyDown(nativeEvent) {\n // IE11, Edge (prior to using Bink?) use 'Esc'\n if (nativeEvent.key === 'Escape' || nativeEvent.key === 'Esc') {\n handleClose(nativeEvent);\n }\n }\n document.addEventListener('keydown', handleKeyDown);\n return () => {\n document.removeEventListener('keydown', handleKeyDown);\n };\n }, [handleClose, open]);\n const handleRef = useForkRef(children.ref, focusVisibleRef, setChildNode, ref);\n\n // There is no point in displaying an empty tooltip.\n // So we exclude all falsy values, except 0, which is valid.\n if (!title && title !== 0) {\n open = false;\n }\n const popperRef = React.useRef();\n const handleMouseMove = event => {\n const childrenProps = children.props;\n if (childrenProps.onMouseMove) {\n childrenProps.onMouseMove(event);\n }\n cursorPosition = {\n x: event.clientX,\n y: event.clientY\n };\n if (popperRef.current) {\n popperRef.current.update();\n }\n };\n const nameOrDescProps = {};\n const titleIsString = typeof title === 'string';\n if (describeChild) {\n nameOrDescProps.title = !open && titleIsString && !disableHoverListener ? title : null;\n nameOrDescProps['aria-describedby'] = open ? id : null;\n } else {\n nameOrDescProps['aria-label'] = titleIsString ? title : null;\n nameOrDescProps['aria-labelledby'] = open && !titleIsString ? id : null;\n }\n const childrenProps = _extends({}, nameOrDescProps, other, children.props, {\n className: clsx(other.className, children.props.className),\n onTouchStart: detectTouchStart,\n ref: handleRef\n }, followCursor ? {\n onMouseMove: handleMouseMove\n } : {});\n if (process.env.NODE_ENV !== 'production') {\n childrenProps['data-mui-internal-clone-element'] = true;\n\n // eslint-disable-next-line react-hooks/rules-of-hooks\n React.useEffect(() => {\n if (childNode && !childNode.getAttribute('data-mui-internal-clone-element')) {\n console.error(['MUI: The `children` component of the Tooltip is not forwarding its props correctly.', 'Please make sure that props are spread on the same element that the ref is applied to.'].join('\\n'));\n }\n }, [childNode]);\n }\n const interactiveWrapperListeners = {};\n if (!disableTouchListener) {\n childrenProps.onTouchStart = handleTouchStart;\n childrenProps.onTouchEnd = handleTouchEnd;\n }\n if (!disableHoverListener) {\n childrenProps.onMouseOver = composeEventHandler(handleMouseOver, childrenProps.onMouseOver);\n childrenProps.onMouseLeave = composeEventHandler(handleMouseLeave, childrenProps.onMouseLeave);\n if (!disableInteractive) {\n interactiveWrapperListeners.onMouseOver = handleMouseOver;\n interactiveWrapperListeners.onMouseLeave = handleMouseLeave;\n }\n }\n if (!disableFocusListener) {\n childrenProps.onFocus = composeEventHandler(handleFocus, childrenProps.onFocus);\n childrenProps.onBlur = composeEventHandler(handleBlur, childrenProps.onBlur);\n if (!disableInteractive) {\n interactiveWrapperListeners.onFocus = handleFocus;\n interactiveWrapperListeners.onBlur = handleBlur;\n }\n }\n if (process.env.NODE_ENV !== 'production') {\n if (children.props.title) {\n console.error(['MUI: You have provided a `title` prop to the child of .', `Remove this title prop \\`${children.props.title}\\` or the Tooltip component.`].join('\\n'));\n }\n }\n const popperOptions = React.useMemo(() => {\n var _PopperProps$popperOp;\n let tooltipModifiers = [{\n name: 'arrow',\n enabled: Boolean(arrowRef),\n options: {\n element: arrowRef,\n padding: 4\n }\n }];\n if ((_PopperProps$popperOp = PopperProps.popperOptions) != null && _PopperProps$popperOp.modifiers) {\n tooltipModifiers = tooltipModifiers.concat(PopperProps.popperOptions.modifiers);\n }\n return _extends({}, PopperProps.popperOptions, {\n modifiers: tooltipModifiers\n });\n }, [arrowRef, PopperProps]);\n const ownerState = _extends({}, props, {\n isRtl,\n arrow,\n disableInteractive,\n placement,\n PopperComponentProp,\n touch: ignoreNonTouchEvents.current\n });\n const classes = useUtilityClasses(ownerState);\n const PopperComponent = (_ref = (_slots$popper = slots.popper) != null ? _slots$popper : components.Popper) != null ? _ref : TooltipPopper;\n const TransitionComponent = (_ref2 = (_ref3 = (_slots$transition = slots.transition) != null ? _slots$transition : components.Transition) != null ? _ref3 : TransitionComponentProp) != null ? _ref2 : Grow;\n const TooltipComponent = (_ref4 = (_slots$tooltip = slots.tooltip) != null ? _slots$tooltip : components.Tooltip) != null ? _ref4 : TooltipTooltip;\n const ArrowComponent = (_ref5 = (_slots$arrow = slots.arrow) != null ? _slots$arrow : components.Arrow) != null ? _ref5 : TooltipArrow;\n const popperProps = appendOwnerState(PopperComponent, _extends({}, PopperProps, (_slotProps$popper = slotProps.popper) != null ? _slotProps$popper : componentsProps.popper, {\n className: clsx(classes.popper, PopperProps == null ? void 0 : PopperProps.className, (_ref6 = (_slotProps$popper2 = slotProps.popper) != null ? _slotProps$popper2 : componentsProps.popper) == null ? void 0 : _ref6.className)\n }), ownerState);\n const transitionProps = appendOwnerState(TransitionComponent, _extends({}, TransitionProps, (_slotProps$transition = slotProps.transition) != null ? _slotProps$transition : componentsProps.transition), ownerState);\n const tooltipProps = appendOwnerState(TooltipComponent, _extends({}, (_slotProps$tooltip = slotProps.tooltip) != null ? _slotProps$tooltip : componentsProps.tooltip, {\n className: clsx(classes.tooltip, (_ref7 = (_slotProps$tooltip2 = slotProps.tooltip) != null ? _slotProps$tooltip2 : componentsProps.tooltip) == null ? void 0 : _ref7.className)\n }), ownerState);\n const tooltipArrowProps = appendOwnerState(ArrowComponent, _extends({}, (_slotProps$arrow = slotProps.arrow) != null ? _slotProps$arrow : componentsProps.arrow, {\n className: clsx(classes.arrow, (_ref8 = (_slotProps$arrow2 = slotProps.arrow) != null ? _slotProps$arrow2 : componentsProps.arrow) == null ? void 0 : _ref8.className)\n }), ownerState);\n return /*#__PURE__*/_jsxs(React.Fragment, {\n children: [/*#__PURE__*/React.cloneElement(children, childrenProps), /*#__PURE__*/_jsx(PopperComponent, _extends({\n as: PopperComponentProp != null ? PopperComponentProp : Popper,\n placement: placement,\n anchorEl: followCursor ? {\n getBoundingClientRect: () => ({\n top: cursorPosition.y,\n left: cursorPosition.x,\n right: cursorPosition.x,\n bottom: cursorPosition.y,\n width: 0,\n height: 0\n })\n } : childNode,\n popperRef: popperRef,\n open: childNode ? open : false,\n id: id,\n transition: true\n }, interactiveWrapperListeners, popperProps, {\n popperOptions: popperOptions,\n children: ({\n TransitionProps: TransitionPropsInner\n }) => /*#__PURE__*/_jsx(TransitionComponent, _extends({\n timeout: theme.transitions.duration.shorter\n }, TransitionPropsInner, transitionProps, {\n children: /*#__PURE__*/_jsxs(TooltipComponent, _extends({}, tooltipProps, {\n children: [title, arrow ? /*#__PURE__*/_jsx(ArrowComponent, _extends({}, tooltipArrowProps, {\n ref: setArrowRef\n })) : null]\n }))\n }))\n }))]\n });\n});\nprocess.env.NODE_ENV !== \"production\" ? Tooltip.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the d.ts file and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * If `true`, adds an arrow to the tooltip.\n * @default false\n */\n arrow: PropTypes.bool,\n /**\n * Tooltip reference element.\n */\n children: elementAcceptingRef.isRequired,\n /**\n * Override or extend the styles applied to the component.\n */\n classes: PropTypes.object,\n /**\n * @ignore\n */\n className: PropTypes.string,\n /**\n * The components used for each slot inside.\n *\n * This prop is an alias for the `slots` prop.\n * It's recommended to use the `slots` prop instead.\n *\n * @default {}\n */\n components: PropTypes.shape({\n Arrow: PropTypes.elementType,\n Popper: PropTypes.elementType,\n Tooltip: PropTypes.elementType,\n Transition: PropTypes.elementType\n }),\n /**\n * The extra props for the slot components.\n * You can override the existing props or add new ones.\n *\n * This prop is an alias for the `slotProps` prop.\n * It's recommended to use the `slotProps` prop instead, as `componentsProps` will be deprecated in the future.\n *\n * @default {}\n */\n componentsProps: PropTypes.shape({\n arrow: PropTypes.object,\n popper: PropTypes.object,\n tooltip: PropTypes.object,\n transition: PropTypes.object\n }),\n /**\n * Set to `true` if the `title` acts as an accessible description.\n * By default the `title` acts as an accessible label for the child.\n * @default false\n */\n describeChild: PropTypes.bool,\n /**\n * Do not respond to focus-visible events.\n * @default false\n */\n disableFocusListener: PropTypes.bool,\n /**\n * Do not respond to hover events.\n * @default false\n */\n disableHoverListener: PropTypes.bool,\n /**\n * Makes a tooltip not interactive, i.e. it will close when the user\n * hovers over the tooltip before the `leaveDelay` is expired.\n * @default false\n */\n disableInteractive: PropTypes.bool,\n /**\n * Do not respond to long press touch events.\n * @default false\n */\n disableTouchListener: PropTypes.bool,\n /**\n * The number of milliseconds to wait before showing the tooltip.\n * This prop won't impact the enter touch delay (`enterTouchDelay`).\n * @default 100\n */\n enterDelay: PropTypes.number,\n /**\n * The number of milliseconds to wait before showing the tooltip when one was already recently opened.\n * @default 0\n */\n enterNextDelay: PropTypes.number,\n /**\n * The number of milliseconds a user must touch the element before showing the tooltip.\n * @default 700\n */\n enterTouchDelay: PropTypes.number,\n /**\n * If `true`, the tooltip follow the cursor over the wrapped element.\n * @default false\n */\n followCursor: PropTypes.bool,\n /**\n * This prop is used to help implement the accessibility logic.\n * If you don't provide this prop. It falls back to a randomly generated id.\n */\n id: PropTypes.string,\n /**\n * The number of milliseconds to wait before hiding the tooltip.\n * This prop won't impact the leave touch delay (`leaveTouchDelay`).\n * @default 0\n */\n leaveDelay: PropTypes.number,\n /**\n * The number of milliseconds after the user stops touching an element before hiding the tooltip.\n * @default 1500\n */\n leaveTouchDelay: PropTypes.number,\n /**\n * Callback fired when the component requests to be closed.\n *\n * @param {React.SyntheticEvent} event The event source of the callback.\n */\n onClose: PropTypes.func,\n /**\n * Callback fired when the component requests to be open.\n *\n * @param {React.SyntheticEvent} event The event source of the callback.\n */\n onOpen: PropTypes.func,\n /**\n * If `true`, the component is shown.\n */\n open: PropTypes.bool,\n /**\n * Tooltip placement.\n * @default 'bottom'\n */\n placement: PropTypes.oneOf(['bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n /**\n * The component used for the popper.\n * @default Popper\n */\n PopperComponent: PropTypes.elementType,\n /**\n * Props applied to the [`Popper`](/material-ui/api/popper/) element.\n * @default {}\n */\n PopperProps: PropTypes.object,\n /**\n * The extra props for the slot components.\n * You can override the existing props or add new ones.\n *\n * This prop is an alias for the `componentsProps` prop, which will be deprecated in the future.\n *\n * @default {}\n */\n slotProps: PropTypes.shape({\n arrow: PropTypes.object,\n popper: PropTypes.object,\n tooltip: PropTypes.object,\n transition: PropTypes.object\n }),\n /**\n * The components used for each slot inside.\n *\n * This prop is an alias for the `components` prop, which will be deprecated in the future.\n *\n * @default {}\n */\n slots: PropTypes.shape({\n arrow: PropTypes.elementType,\n popper: PropTypes.elementType,\n tooltip: PropTypes.elementType,\n transition: PropTypes.elementType\n }),\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Tooltip title. Zero-length titles string, undefined, null and false are never displayed.\n */\n title: PropTypes.node,\n /**\n * The component used for the transition.\n * [Follow this guide](/material-ui/transitions/#transitioncomponent-prop) to learn more about the requirements for this component.\n * @default Grow\n */\n TransitionComponent: PropTypes.elementType,\n /**\n * Props applied to the transition element.\n * By default, the element is based on this [`Transition`](http://reactcommunity.org/react-transition-group/transition/) component.\n */\n TransitionProps: PropTypes.object\n} : void 0;\nexport default Tooltip;","import '@/components/mui/menu-item.component.css';\nimport ArrowRightIcon from '@mui/icons-material/ArrowRight';\nimport {\n ListItemIcon as MuiListItemIcon,\n ListItemText as MuiListItemText,\n MenuItem as MuiMenuItem,\n} from '@mui/material';\nimport Tooltip from '@mui/material/Tooltip';\nimport { Localized, ReferencedItem, SingleColumnMenu } from 'platform-bible-utils';\nimport { MouseEvent, PropsWithChildren } from 'react';\n\ntype MenuItemInfoBase = {\n /** Text (displayable in the UI) as the name of the menu item */\n label: string;\n /** Text to display when the mouse hovers over the menu item */\n tooltip?: string;\n};\n\nexport type Command = MenuItemInfoBase & {\n /** Command to execute (string.string) */\n command: string;\n};\n\ntype SubMenu = MenuItemInfoBase & {\n /** Command to execute (string.string) */\n items: MenuItemInfo[];\n};\n\nexport interface CommandHandler {\n (command: Command): void;\n}\n\nexport type MenuPropsBase = {\n /*\n * The JSON defining the menu whose items are to be rendered. This will typically be one of the\n * menus in the \"defs\" in a Platform.Bible menu (see PlatformMenus). The schema for this is\n * menuDocumentSchema (at the end of menus.model.ts). Note that while this is a\n * \"SingleColumnMenu\", somewhat bizarrely, a MultiColumnMenu is a SingleColumnMenu, so it really\n * could be a MultiColumnMenu, in which case, column had better be defined so it can be used\n * to filter out the actual groups and items to display on the column.\n */\n menuDefinition: Localized;\n\n commandHandler: CommandHandler;\n\n /**\n * Additional action to perform when any menu item is clicked. Allows the caller to handle event\n * (e.g., to close the menu).\n */\n onClick?: (event: MouseEvent) => void;\n};\n\nexport type MenuItemListProps = MenuPropsBase & {\n /** Optional unique (column) identifier */\n columnId?: ReferencedItem;\n};\n\nexport type MenuItemProps = Omit &\n PropsWithChildren<{\n /** Optional unique identifier */\n id?: string;\n\n onClick: (event: MouseEvent) => void;\n }>;\n\ntype MenuItemInfo = (Command | SubMenu) & {\n /**\n * If specified, menu item will be inset if it does not have a leading icon.\n *\n * @default true\n */\n allowForLeadingIcons?: boolean;\n /**\n * If specified, the path to the icon image to display on the leading side of the menu text.\n *\n * @default undefined (no leading icon will be shown)\n */\n iconPathBefore?: string;\n /**\n * If specified, the path to the icon image to display on the trailing side of the menu text.\n *\n * @default undefined (no trailing icon will be shown)\n */\n iconPathAfter?: string;\n /**\n * If true, list item is focused during the first mount\n *\n * @default false\n */\n hasAutoFocus?: boolean;\n\n /** Additional css classes to help with unique styling of the menu item */\n className?: string;\n\n /**\n * If true, the menu item will appear disabled and it will not respond to clicks or mouse hovers.\n *\n * @default false\n */\n isDisabled?: boolean;\n\n /**\n * If true, compact vertical padding designed for keyboard and mouse input is used.\n *\n * @default true\n */\n isDense?: boolean;\n\n /**\n * If true, a right-arrow icon will be displayed (iconPathAfter, if specified, will be ignored).\n *\n * @default false\n */\n isSubMenuParent?: boolean;\n\n /**\n * If true, the left and right padding is removed\n *\n * @default false\n */\n hasDisabledGutters?: boolean;\n\n /**\n * If true, a 1px light border is added to bottom of menu item\n *\n * @default false\n */\n hasDivider?: boolean;\n\n /** Help identify which element has keyboard focus */\n focusVisibleClassName?: string;\n\n /** If it's a submenu, it should have the items property */\n items?: MenuItemInfo[];\n};\n\nfunction getIcon(icon: string | undefined, menuLabel: string, leading: boolean) {\n return icon ? (\n \n {`${leading\n \n ) : undefined;\n}\n\nexport default function MenuItem(props: MenuItemProps) {\n const {\n onClick,\n label,\n tooltip,\n allowForLeadingIcons = true,\n iconPathBefore = undefined,\n iconPathAfter = undefined,\n hasAutoFocus = false,\n className,\n isDisabled = false,\n isDense = true,\n isSubMenuParent = false,\n hasDisabledGutters = false,\n hasDivider = false,\n focusVisibleClassName,\n id,\n children,\n } = props;\n\n const menuItem = (\n \n {label ? (\n <>\n {getIcon(iconPathBefore, label, true)}\n \n {isSubMenuParent ? (\n \n \n \n ) : (\n getIcon(iconPathAfter, label, false)\n )}\n \n ) : (\n children\n )}\n \n );\n\n return tooltip ? (\n \n
    {menuItem}
    \n
    \n ) : (\n menuItem\n );\n}\n","import MenuItem, {\n MenuItemListProps,\n MenuItemProps,\n MenuPropsBase,\n} from '@/components/mui/menu-item.component';\nimport { Menu } from '@mui/material';\nimport {\n Localized,\n MenuGroupDetailsInSubMenu,\n MenuItemContainingCommand,\n MenuItemContainingSubmenu,\n OrderedExtensibleContainer,\n ReferencedItem,\n SingleColumnMenu,\n} from 'platform-bible-utils';\nimport { MouseEvent, useMemo, useState } from 'react';\n\n/**\n * All the exported types in this file should be regarded as \"internal\" (i.e., they should not be\n * exposed via index.ts).\n */\n\nexport type GroupedMenuPropsBase = MenuPropsBase & {\n /** Optional unique (column) identifier */\n columnId?: ReferencedItem;\n};\n\nexport type GroupedMenuItemListProps = MenuItemListProps & {\n /**\n * If the menuDefinition includes \"top-level\" groups (i.e., those that belong to a column as\n * opposed to those that belong to a submenu) that should not be included in the list, then this\n * array specifies which groups to include. Likewise, for a submenu, this list indicates which\n * groups are pertinent for that submenu. So then for a context menu this property need not be\n * specified since it is a top-level menu based on a \"true\" SingleColumnMenu (i.e., one that is\n * not a MultiColumnMenu).\n */\n includedGroups?: {\n id: string;\n group: Localized;\n }[];\n};\n\ninterface ItemInfo {\n item: Localized;\n isLastItemInGroup: boolean;\n}\n\ntype SubMenuProps = MenuPropsBase & {\n parentMenuItem: Localized;\n parentItemProps: Omit, 'iconPathAfter'>;\n};\n\nfunction getAllGroups(menuDefinition: Localized) {\n const groupEntries = Object.entries(menuDefinition.groups);\n // Convert array of entries to array of objects with id and group properties\n return groupEntries.map(([key, value]) => ({ id: key, group: value }));\n}\n\nfunction SubMenu(props: SubMenuProps) {\n const [anchorEl, setAnchorEl] = useState(undefined);\n\n const { parentMenuItem, parentItemProps, menuDefinition } = props;\n\n const handleParentMenuItemClick = (event: MouseEvent) => {\n setAnchorEl(event.currentTarget);\n };\n\n const handleClose = () => {\n setAnchorEl(undefined);\n };\n\n const renderSubMenuItems = () => {\n let includedGroups = getAllGroups(menuDefinition).filter((g) => 'menuItem' in g.group);\n\n // Ensure valid parent menu was provided. (If not, submenu will contain all groups!)\n if (!parentMenuItem?.id) throw new Error('A valid parent menu item is required for submenus.');\n\n // When laying out a submenu, only include groups associated with the provided parent menu.\n // Note: without the (annoying) redundant check that the included groups\n // have the menuItem field, TS doesn't think it exists.\n includedGroups = includedGroups.filter(\n (group) => 'menuItem' in group.group && group.group.menuItem === parentMenuItem.id,\n );\n\n return ;\n };\n\n return (\n <>\n \n \n {renderSubMenuItems()}\n \n \n );\n}\n\nconst getOrderedGroupItems = (\n groupId: string,\n allItems: Localized[],\n) => {\n // Filter items that belong to the specified group\n const itemsForGroup = allItems.filter((item) => item.group === groupId);\n // Sort items based on order\n const sortedItems = itemsForGroup.sort((a, b) => (a.order || 0) - (b.order || 0));\n return sortedItems;\n};\n\n/**\n * This component is internal; it does not need to be exposed to the outside world since it is not\n * useful on its own. It is used to generate and lay out the MenuItems that appear either on a\n * top-level menu (in a GridMenu or ContextMenu) or in a submenu.\n */\nexport default function GroupedMenuItemList(menuProps: GroupedMenuItemListProps) {\n const { menuDefinition, onClick, commandHandler, includedGroups } = menuProps;\n\n const { items, allowForLeadingIcons } = useMemo(() => {\n const groupsToInclude =\n includedGroups && includedGroups.length > 0\n ? includedGroups\n : // We're apparently laying out a single-column menu (presumably a context menu). In this\n // case, all groups should be included except ones that belong to a submenu.\n getAllGroups(menuDefinition).filter((g) => !('menuItem' in g.group));\n\n const sortedGroups = Object.values(groupsToInclude).sort(\n (a, b) => (a.group.order || 0) - (b.group.order || 0),\n );\n\n const itemArray: ItemInfo[] = [];\n\n sortedGroups.forEach((group) => {\n getOrderedGroupItems(group.id, menuDefinition.items).forEach((item) =>\n itemArray.push({ item, isLastItemInGroup: false }),\n );\n if (itemArray.length > 0) itemArray[itemArray.length - 1].isLastItemInGroup = true;\n });\n\n // No divider after last item in final group.\n if (itemArray.length > 0) itemArray[itemArray.length - 1].isLastItemInGroup = false;\n\n const allowSpaceForLeadingIcons = itemArray.some(\n (i) => 'iconPathBefore' in i.item && i.item.iconPathBefore,\n );\n\n return { items: itemArray, allowForLeadingIcons: allowSpaceForLeadingIcons };\n }, [includedGroups, menuDefinition]);\n\n // Create props for MenuItem component including setting hasDivider for the last item in a group\n const createMenuItemProps = ({ item, isLastItemInGroup }: ItemInfo) => {\n const menuItemProps = {\n className: 'papi-menu-item',\n label: item.label,\n tooltip: item.tooltip,\n iconPathBefore: 'iconPathBefore' in item ? item.iconPathBefore : undefined,\n iconPathAfter: 'iconPathAfter' in item ? item.iconPathAfter : undefined,\n hasDivider: isLastItemInGroup, // Set hasDivider to true for the last item in a group\n allowForLeadingIcons,\n };\n\n return menuItemProps;\n };\n\n const [firstItem] = items;\n\n if (!firstItem) return
    ;\n\n const divKey = firstItem.item.group;\n\n return (\n
    \n {items.map((itemInfo, index) => {\n const { item } = itemInfo;\n const menuItemProps = createMenuItemProps(itemInfo);\n if ('command' in item) {\n const key = item.group + index;\n return (\n ) => {\n onClick?.(event);\n commandHandler(item);\n }}\n {...menuItemProps}\n />\n );\n }\n return (\n \n );\n })}\n
    \n );\n}\n","import GroupedMenuItemList from '@/components/mui/grouped-menu-item-list.component';\nimport { MenuItemListProps } from '@/components/mui/menu-item.component';\nimport { MultiColumnMenu } from 'platform-bible-utils';\n\n/**\n * This component is internal; it does not need to be exposed to the outside world since it is not\n * useful on its own. Use either GridMenu or ContextMenu.\n */\nexport default function TopLevelMenu(props: MenuItemListProps) {\n const { menuDefinition, columnId } = props;\n\n const groupEntries = Object.entries(menuDefinition.groups);\n // Convert array of entries to array of objects with id and group properties\n const groups = groupEntries.map(([key, value]) => ({ id: key, group: value }));\n let includedGroups = groups.filter((g) => 'column' in g.group);\n\n // Check if column is provided and menuDefinition is a MultiColumnMenu\n if (\n columnId &&\n 'columns' in menuDefinition &&\n // Without this type assertion, TS doesn't know what columns is.\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n (menuDefinition as MultiColumnMenu).columns[columnId]\n ) {\n // When laying out a single column in a MultiColumnMenu, only include groups associated with\n // the provided column. Note: without the (annoying) redundant check that the included groups\n // have the colum field, TS doesn't think it exists.\n includedGroups = includedGroups.filter(\n (g) => 'column' in g.group && g.group.column === columnId,\n );\n }\n\n return ;\n}\n","import '@/components/mui/grid-menu.component.css';\nimport { GroupedMenuPropsBase } from '@/components/mui/grouped-menu-item-list.component';\nimport { CommandHandler } from '@/components/mui/menu-item.component';\nimport TopLevelMenu from '@/components/mui/top-level-menu.component';\nimport { Grid, List } from '@mui/material';\nimport {\n Localized,\n MenuColumnWithHeader,\n MultiColumnMenu,\n ReferencedItem,\n} from 'platform-bible-utils';\nimport { useMemo } from 'react';\n\ntype ColumnInfo = {\n /*\n * The ID (`${string}.${string}`) of a specific menu column.\n */\n id: ReferencedItem;\n\n /*\n * Metadata (label, order, etc.) for a specific menu column.\n */\n metadata: Localized;\n};\n\ntype MenuColumnProps = ColumnInfo &\n GroupedMenuPropsBase & {\n /** Additional css classes to help with unique styling of the menu column */\n className?: string;\n };\n\nexport type GridMenuInfo = {\n /** The menu object containing information about the columns, groups, and items to display. */\n multiColumnMenu: Localized;\n};\n\nexport type GridMenuProps = GridMenuInfo & {\n /** Optional unique identifier */\n id?: string;\n\n commandHandler: CommandHandler;\n\n /** Additional css classes to help with unique styling of the grid menu */\n className?: string;\n};\n\nfunction MenuColumn({\n commandHandler,\n menuDefinition,\n id,\n metadata,\n onClick,\n className,\n}: MenuColumnProps) {\n return (\n \n

    \n {metadata.label}\n

    \n {/* It would seem as though this List component were unnecessary, since it only contains one\n thing, but the \"dense\" property does affect the layout of the items (in a way I don't fully\n understand). There might be a better way. */}\n \n \n \n \n );\n}\n\nexport default function GridMenu({\n commandHandler,\n className,\n multiColumnMenu,\n id,\n}: GridMenuProps) {\n const { columns } = multiColumnMenu;\n\n const sortedColumns = useMemo(() => {\n const columnNumbers = new Map();\n Object.getOwnPropertyNames(columns).forEach((columnName: string) => {\n // We know for sure there is a (boolean) property 'isExtensible' that we are not interested in.\n if (columnName === 'isExtensible') return;\n // TS doesn't allow `columnName` above to be a ReferencedItem even though the type says it is\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const columnId = columnName as ReferencedItem;\n const column = columns[columnId];\n // As of right now (and hopefully forever after), all remaining properties of the\n // ColumnsWithHeaders object are columns whose property names are the IDs of the columns.\n // This is an additional (redundant) sanity check. Specifically we're interested in\n // MenuColumnWithHeader objects, which TypeScript now \"knows\" we have, but at runtime all we\n // can check for is that it's an object with a valid numeric order field. That's likely good\n // enough.\n if (\n typeof column === 'object' &&\n typeof column.order === 'number' &&\n !Number.isNaN(column.order)\n )\n columnNumbers.set(column.order, { id: columnId, metadata: column });\n else\n console.warn(\n `Property ${columnName} (${typeof column}) on menu ${id} is not a valid column and is being ignored. This might indicate data corruption`,\n );\n });\n\n // Extract values and sort them based on the 'order' property\n return Array.from(columnNumbers.values()).sort((a, b) => {\n return (a.metadata.order || 0) - (b.metadata.order || 0);\n });\n }, [columns, id]);\n\n // We might need something like this if we need to be able to prevent empty columns\n // sortedColumns.filter((c) => multiColumnMenu.groups.some((g) => 'column' in g && (g as .column)...\n\n return (\n \n {sortedColumns.map((col, index) => (\n \n ))}\n \n );\n}\n","import { useEffect, useRef, useState } from 'react';\n\nexport type UsePromiseOptions = {\n /**\n * Whether to leave the value as the most recent resolved promise value or set it back to\n * defaultValue while running the promise again. Defaults to true\n */\n preserveValue?: boolean;\n};\n\n/** Set up defaults for options for usePromise hook */\nfunction getUsePromiseOptionsDefaults(options: UsePromiseOptions): UsePromiseOptions {\n return {\n preserveValue: true,\n ...options,\n };\n}\n\n/**\n * Awaits a promise and returns a loading value while the promise is unresolved\n *\n * @param promiseFactoryCallback A function that returns the promise to await. If this callback is\n * undefined, the current value will be returned (defaultValue unless it was previously changed\n * and `options.preserveValue` is true), and there will be no loading.\n *\n * WARNING: MUST BE STABLE - const or wrapped in useCallback. The reference must not be updated\n * every render\n * @param defaultValue The initial value to return while first awaiting the promise. If\n * `options.preserveValue` is false, this value is also shown while awaiting the promise on\n * subsequent calls.\n *\n * Note: this parameter is internally assigned to a `ref`, so changing it will not cause any hooks\n * to re-run with its new value. This means that, if the `promiseFactoryCallback` changes and\n * `options.preserveValue` is `false`, the returned value will be set to the current\n * `defaultValue`. However, the returned value will not be updated if`defaultValue` changes.\n * @param options Various options for adjusting how this hook runs the `promiseFactoryCallback`\n *\n * Note: this parameter is internally assigned to a `ref`, so changing it will not cause any hooks\n * to re-run with its new value. However, the latest `options.preserveValue` will always be used\n * appropriately to determine whether to preserve the returned value when changing the\n * `promiseFactoryCallback`\n * @returns `[value, isLoading]`\n *\n * - `value`: the current value for the promise, either the defaultValue or the resolved promise value\n * - `isLoading`: whether the promise is waiting to be resolved\n */\nconst usePromise = (\n promiseFactoryCallback: (() => Promise) | undefined,\n defaultValue: T,\n options: UsePromiseOptions = {},\n): [value: T, isLoading: boolean] => {\n // Use defaultValue as a ref so it doesn't update dependency arrays\n const defaultValueRef = useRef(defaultValue);\n defaultValueRef.current = defaultValue;\n // Use options as a ref so it doesn't update dependency arrays\n const optionsDefaultedRef = useRef(options);\n optionsDefaultedRef.current = getUsePromiseOptionsDefaults(optionsDefaultedRef.current);\n\n const [value, setValue] = useState(() => defaultValueRef.current);\n const [isLoading, setIsLoading] = useState(true);\n useEffect(() => {\n let promiseIsCurrent = true;\n // If a promiseFactoryCallback was provided, we are loading. Otherwise, there is no loading to do\n setIsLoading(!!promiseFactoryCallback);\n (async () => {\n // If there is a callback to run, run it\n if (promiseFactoryCallback) {\n const result = await promiseFactoryCallback();\n // If the promise was not already replaced, update the value\n if (promiseIsCurrent) {\n setValue(() => result);\n setIsLoading(false);\n }\n }\n })();\n\n return () => {\n // Mark this promise as old and not to be used\n promiseIsCurrent = false;\n if (!optionsDefaultedRef.current.preserveValue) setValue(() => defaultValueRef.current);\n };\n }, [promiseFactoryCallback]);\n\n return [value, isLoading];\n};\nexport default usePromise;\n","\"use client\";\n\nimport createSvgIcon from './utils/createSvgIcon';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nexport default createSvgIcon( /*#__PURE__*/_jsx(\"path\", {\n d: \"M3 18h18v-2H3zm0-5h18v-2H3zm0-7v2h18V6z\"\n}), 'Menu');","import GridMenu from '@/components/mui/grid-menu.component';\nimport { Command, CommandHandler } from '@/components/mui/menu-item.component';\nimport usePromise from '@/hooks/use-promise.hook';\nimport { Menu as MenuIcon } from '@mui/icons-material';\nimport { Drawer, IconButton } from '@mui/material';\nimport { Localized, MultiColumnMenu } from 'platform-bible-utils';\nimport {\n MouseEvent,\n MutableRefObject,\n PropsWithChildren,\n useCallback,\n useEffect,\n useState,\n} from 'react';\n\nexport interface MultiColumnMenuProvider {\n (isSupportAndDevelopment: boolean): Promise>;\n}\n\nexport type HamburgerMenuButtonProps = PropsWithChildren & {\n /** The handler to use for menu commands (and eventually toolbar commands). */\n commandHandler: CommandHandler;\n\n /**\n * Optional reference to the \"div\" container that determines the where the menu should appear. If\n * not defined, then (1,1) used.\n */\n containerRef?: MutableRefObject;\n\n /**\n * The delegate to use to get the menu data. If not specified or if it returns undefined, the data\n * in normalMenu or fullMenu property will be used.\n */\n menuProvider?: MultiColumnMenuProvider;\n\n /**\n * The menu data to show when the menu is opened if the menuProvider property is not defined.\n * (This allows for a default or test-only static menu to be used.)\n */\n normalMenu?: Localized;\n\n /**\n * The menu data to show for \"full\" menu (when opened with the SHIFT key pressed) if the\n * menuProvider property is not defined. (This allows for a default or test-only static menu to be\n * used.)\n */\n fullMenu?: Localized;\n\n /** Additional css class(es) to help with unique styling of the sub-components */\n className?: string;\n\n /** Value to use as prefix for ARIA labels on interactive sub-components */\n ariaLabelPrefix?: string;\n};\n\nexport default function HamburgerMenuButton({\n menuProvider,\n normalMenu,\n fullMenu,\n commandHandler,\n containerRef,\n className,\n ariaLabelPrefix,\n children,\n}: HamburgerMenuButtonProps) {\n const [isMenuOpen, setMenuOpen] = useState(false);\n const [showFullMenu, setShowFullMenu] = useState(false);\n\n const handleMenuItemClick = useCallback(() => {\n if (isMenuOpen) setMenuOpen(false);\n setShowFullMenu(false);\n }, [isMenuOpen]);\n\n const handleMenuButtonClick = useCallback((e: MouseEvent) => {\n e.stopPropagation();\n setMenuOpen((prevIsOpen) => {\n const isOpening = !prevIsOpen;\n if (isOpening && e.shiftKey) setShowFullMenu(true);\n else if (!isOpening) setShowFullMenu(false);\n return isOpening;\n });\n }, []);\n\n const menuCommandHandler = useCallback(\n (command: Command) => {\n handleMenuItemClick();\n return commandHandler(command);\n },\n [commandHandler, handleMenuItemClick],\n );\n\n const [offset, setOffset] = useState({ top: 1, left: 1 });\n\n useEffect(() => {\n if (isMenuOpen) {\n const node = containerRef?.current;\n if (node) {\n const rect = node.getBoundingClientRect();\n const scrollTop = window.scrollY;\n const scrollLeft = window.scrollX;\n const top = rect.top + scrollTop + node.clientHeight;\n const left = rect.left + scrollLeft;\n setOffset({ top, left });\n }\n }\n }, [isMenuOpen, containerRef]);\n\n const [normalMenuData] = usePromise(\n useCallback(async () => {\n return menuProvider?.(false) ?? normalMenu;\n // isMenuOpen needs to be included for the menu contents to reevaluate when reopened\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [menuProvider, normalMenu, isMenuOpen]),\n normalMenu,\n );\n\n const [fullMenuData] = usePromise(\n useCallback(async () => {\n return menuProvider?.(true) ?? fullMenu ?? normalMenuData;\n // isMenuOpen needs to be included for the menu contents to reevaluate when reopened\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [menuProvider, fullMenu, normalMenuData, isMenuOpen]),\n fullMenu ?? normalMenuData,\n );\n\n const menu = showFullMenu && fullMenuData ? fullMenuData : normalMenuData;\n\n return (\n <>\n \n {children ?? }\n \n \n {menu ? (\n \n ) : undefined}\n \n \n );\n}\n","import '@/components/mui/icon-button.component.css';\nimport { IconButton as MuiIconButton } from '@mui/material';\nimport { MouseEventHandler, PropsWithChildren } from 'react';\n\nexport type IconButtonProps = PropsWithChildren<{\n /** Optional unique identifier */\n id?: string;\n /**\n * Required. Used as both the tooltip (aka, title) and the aria-label (used for accessibility,\n * testing, etc.), unless a distinct tooltip is supplied.\n */\n label: string;\n /**\n * Enabled status of button\n *\n * @default false\n */\n isDisabled?: boolean;\n /** Optional tooltip to display if different from the aria-label. */\n tooltip?: string;\n /** If true, no tooltip will be displayed. */\n isTooltipSuppressed?: boolean;\n /**\n * If given, uses a negative margin to counteract the padding on one side (this is often helpful\n * for aligning the left or right side of the icon with content above or below, without ruining\n * the border size and shape).\n *\n * @default false\n */\n adjustMarginToAlignToEdge?: 'end' | 'start' | false;\n /**\n * The size of the component. small is equivalent to the dense button styling.\n *\n * @default false\n */\n size: 'small' | 'medium' | 'large';\n /** Additional css classes to help with unique styling of the button */\n className?: string;\n /** Optional click handler */\n onClick?: MouseEventHandler;\n}>;\n\n/**\n * Iconic button a user can click to do something\n *\n * Thanks to MUI for heavy inspiration and documentation\n * https://mui.com/material-ui/getting-started/overview/\n */\nfunction IconButton({\n id,\n label,\n isDisabled = false,\n tooltip,\n isTooltipSuppressed = false,\n adjustMarginToAlignToEdge = false,\n size = 'medium',\n className,\n onClick,\n children,\n}: IconButtonProps) {\n return (\n \n {children /* the icon to display */}\n \n );\n}\n\nexport default IconButton;\n","import { cn } from '@/utils/shadcn-ui.util';\nimport { LoaderCircle, LucideProps } from 'lucide-react';\nimport { forwardRef } from 'react';\n\nexport type SpinnerProps = LucideProps;\n\nconst Spinner = forwardRef(({ className, ...props }, ref) => {\n return (\n \n );\n});\n\nSpinner.displayName = 'Spinner';\n\nexport default Spinner;\n","import { Input as ShadInput } from '@/components/shadcn-ui/input';\nimport { Label as ShadLabel } from '@/components/shadcn-ui/label';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { ChangeEventHandler, FocusEventHandler } from 'react';\n\nexport type TextFieldProps = {\n /** Optional unique identifier */\n id?: string;\n /**\n * If `true`, the component is disabled.\n *\n * @default false\n */\n isDisabled?: boolean;\n /**\n * If `true`, the label is displayed in an error state.\n *\n * @default false\n */\n hasError?: boolean;\n /**\n * If `true`, the input will take up the full width of its container.\n *\n * @default false\n */\n isFullWidth?: boolean;\n /** Text that gives the user instructions on what contents the TextField expects */\n helperText?: string;\n /** The title of the TextField */\n label?: string;\n /** The short hint displayed in the `input` before the user enters a value. */\n placeholder?: string;\n /**\n * If `true`, the label is displayed as required and the `input` element is required.\n *\n * @default false\n */\n isRequired?: boolean;\n /** Additional css classes to help with unique styling of the text field */\n className?: string;\n /** Starting value for the text field if it is not controlled */\n defaultValue?: string | number;\n /** Value of the text field if controlled */\n value?: string | number;\n /** Triggers when content of textfield is changed */\n onChange?: ChangeEventHandler;\n /** Triggers when textfield gets focus */\n onFocus?: FocusEventHandler;\n /** Triggers when textfield loses focus */\n onBlur?: FocusEventHandler;\n};\n\n/**\n * Text input field\n *\n * Thanks to Shadcn for heavy inspiration and documentation\n * https://ui.shadcn.com/docs/components/input#with-label\n */\nfunction TextField({\n id,\n isDisabled = false,\n hasError = false,\n isFullWidth = false,\n helperText,\n label,\n placeholder,\n isRequired = false,\n className,\n defaultValue,\n value,\n onChange,\n onFocus,\n onBlur,\n}: TextFieldProps) {\n return (\n
    \n {`${label}${isRequired ? '*' : ''}`}\n \n

    {helperText}

    \n
    \n );\n}\n\nexport default TextField;\n","import HamburgerMenuButton, {\n MultiColumnMenuProvider,\n} from '@/components/mui/hamburger-menu-button.component';\nimport { CommandHandler } from '@/components/mui/menu-item.component';\nimport '@/components/mui/toolbar.component.css';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { AppBar, Toolbar as MuiToolbar } from '@mui/material';\nimport { PropsWithChildren, useRef } from 'react';\n\nexport type ToolbarProps = PropsWithChildren<{\n /** The handler to use for menu commands (and eventually toolbar commands). */\n commandHandler: CommandHandler;\n\n /**\n * The optional delegate to use to get the menu data. If not specified, the \"hamburger\" menu will\n * not display.\n */\n menuProvider?: MultiColumnMenuProvider;\n\n /** Optional unique identifier */\n id?: string;\n\n /** Additional css classes to help with unique styling of the toolbar */\n className?: string;\n}>;\n\nexport default function Toolbar({\n menuProvider,\n commandHandler,\n className,\n id,\n children,\n}: ToolbarProps) {\n // This ref will always be defined\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const containerRef = useRef(undefined!);\n\n return (\n
    \n \n \n {menuProvider ? (\n \n ) : undefined}\n {children ?
    {children}
    : undefined}\n \n
    \n
    \n );\n}\n","import React from 'react';\nimport { cva, type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst alertVariants = cva(\n 'tw-relative tw-w-full tw-rounded-lg tw-border tw-p-4 [&>svg~*]:tw-pl-7 [&>svg+div]:tw-translate-y-[-3px] [&>svg]:tw-absolute [&>svg]:tw-left-4 [&>svg]:tw-top-4 [&>svg]:tw-text-foreground',\n {\n variants: {\n variant: {\n default: 'tw-bg-background tw-text-foreground',\n destructive:\n 'tw-border-destructive/50 tw-text-destructive dark:tw-border-destructive [&>svg]:tw-text-destructive',\n },\n },\n defaultVariants: {\n variant: 'default',\n },\n },\n);\n\nconst Alert = React.forwardRef<\n HTMLDivElement,\n React.HTMLAttributes & VariantProps\n>(({ className, variant, ...props }, ref) => (\n
    \n));\nAlert.displayName = 'Alert';\n\nconst AlertTitle = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n {/* added because of https://github.com/jsx-eslint/eslint-plugin-jsx-a11y/blob/main/docs/rules/heading-has-content.md */}\n {props.children}{' '}\n \n ),\n);\nAlertTitle.displayName = 'AlertTitle';\n\nconst AlertDescription = React.forwardRef<\n HTMLParagraphElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n
    \n));\nAlertDescription.displayName = 'AlertDescription';\n\nexport { Alert, AlertTitle, AlertDescription };\n","import { ComponentProps } from 'react';\nimport { toast as sonner, Toaster } from 'sonner';\n\ntype SonnerProps = ComponentProps;\n\nfunction Sonner({ ...props }: SonnerProps) {\n return (\n \n );\n}\n\n// The re-export of the sonner function was added manually\nexport { Sonner, sonner };\n","import React from 'react';\nimport * as SliderPrimitive from '@radix-ui/react-slider';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Slider = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n \n \n \n));\nSlider.displayName = SliderPrimitive.Root.displayName;\n\nexport { Slider };\n","import React from 'react';\nimport * as SwitchPrimitives from '@radix-ui/react-switch';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Switch = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n));\nSwitch.displayName = SwitchPrimitives.Root.displayName;\n\nexport { Switch };\n","import React from 'react';\nimport * as TabsPrimitive from '@radix-ui/react-tabs';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport const Tabs = TabsPrimitive.Root;\n\nexport type TabsListProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport type TabsTriggerProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport type TabsContentProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport const TabsList = React.forwardRef<\n React.ElementRef,\n TabsListProps\n>(({ className, ...props }, ref) => (\n \n));\nTabsList.displayName = TabsPrimitive.List.displayName;\n\nexport const TabsTrigger = React.forwardRef<\n React.ElementRef,\n TabsTriggerProps\n>(({ className, ...props }, ref) => (\n \n));\nTabsTrigger.displayName = TabsPrimitive.Trigger.displayName;\n\nexport const TabsContent = React.forwardRef<\n React.ElementRef,\n TabsContentProps\n>(({ className, ...props }, ref) => (\n \n));\nTabsContent.displayName = TabsPrimitive.Content.displayName;\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Download } from 'lucide-react';\n\ntype InstallButtonProps = {\n /** The installing boolean value determines the state of the button. */\n isInstalling: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n /** Optional text for the button. */\n buttonText?: string;\n} & ButtonProps;\n\n/**\n * The InstallButton component is a button designed for initiating installs. It includes visuals for\n * active installing and idle states.\n *\n * @param isInstalling The installing boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @param buttonText Optional text for the button.\n * @returns A install button.\n */\nexport default function InstallButton({\n isInstalling,\n handleClick,\n buttonText,\n className,\n ...props\n}: InstallButtonProps) {\n return (\n \n {isInstalling ? (\n \n ) : (\n <>\n \n {buttonText}\n \n )}\n \n );\n}\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\n\ntype EnableButtonProps = {\n /** The enabling boolean value determines the state of the button. */\n isEnabling: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n} & ButtonProps;\n\n/**\n * The EnableButton component is a button designed for initiating enabling of downloads. It includes\n * visuals for active enabling and idle states.\n *\n * @param isEnabling The enabling boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @returns A button that can be used to enable.\n */\nexport default function EnableButton({\n isEnabling,\n handleClick,\n className,\n ...props\n}: EnableButtonProps) {\n return (\n \n {isEnabling ? (\n <>\n \n Enabling...\n \n ) : (\n 'Enable'\n )}\n \n );\n}\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\n\ntype DisableButtonProps = {\n /** The disabling boolean value determines the state of the button. */\n isDisabling: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n} & ButtonProps;\n\n/**\n * The DisableButton component is a button designed for initiating disabling of downloads. It\n * includes visuals for active disabling and idle states.\n *\n * @param isDisabling The disabling boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @returns A button that can be used to disable.\n */\nexport default function DisableButton({\n isDisabling,\n handleClick,\n className,\n ...props\n}: DisableButtonProps) {\n return (\n \n {isDisabling ? (\n <>\n \n Disabling...\n \n ) : (\n 'Disable'\n )}\n \n );\n}\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\n\ntype UpdateButtonProps = {\n /** The updating boolean value determines the state of the button. */\n isUpdating: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n} & ButtonProps;\n\n/**\n * The UpdateButton component is a button designed for initiating updates for downloaded extensions.\n * It includes visuals for active updating and idle states.\n *\n * @param isUpdating The updating boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @returns A button that can be used to update.\n */\nexport default function UpdateButton({\n isUpdating,\n handleClick,\n className,\n ...props\n}: UpdateButtonProps) {\n return (\n \n {isUpdating ? (\n <>\n \n Updating...\n \n ) : (\n 'Update'\n )}\n \n );\n}\n","import { cn } from '@/utils/shadcn-ui.util';\nimport Markdown, { MarkdownToJSX } from 'markdown-to-jsx';\nimport { useMemo } from 'react';\n\ninterface MarkdownRendererProps {\n /** Optional unique identifier */\n id?: string;\n /** The markdown string to render */\n markdown: string;\n className?: string;\n /**\n * The [`target` attribute for `a` html\n * tags](https://developer.mozilla.org/en-US/docs/Web/HTML/Element/a#target). Defaults to not\n * adding a `target` to `a` tags\n */\n anchorTarget?: string;\n}\n\n/**\n * This component renders markdown content given a markdown string. It uses typography styles from\n * the platform.\n *\n * @param markdown The markdown string to render.\n * @param id Optional unique identifier\n * @returns A div containing the rendered markdown content.\n */\nexport default function MarkdownRenderer({\n id,\n markdown,\n className,\n anchorTarget,\n}: MarkdownRendererProps) {\n const options: MarkdownToJSX.Options = useMemo(\n () => ({\n overrides: {\n a: {\n props: {\n target: anchorTarget,\n },\n },\n },\n }),\n [anchorTarget],\n );\n return (\n
    \n {markdown}\n
    \n );\n}\n","import { Filter, ChevronDown } from 'lucide-react';\nimport { forwardRef } from 'react';\nimport { Button } from '@/components/shadcn-ui/button';\n\n/**\n * The FilterButton component is a button designed for initiating filtering of data. It is designed\n * to be used with the dropdown menu. It uses forwardRef to pass the button to the dropdown trigger\n * asChild.\n *\n * @returns A button that can be used to filter.\n */\nconst FilterButton = forwardRef((props, ref) => {\n return (\n \n \n Filter\n \n \n );\n});\n\nexport default FilterButton;\n","import {\n DropdownMenu,\n DropdownMenuTrigger,\n DropdownMenuContent,\n DropdownMenuLabel,\n DropdownMenuGroup,\n DropdownMenuCheckboxItem,\n DropdownMenuRadioItem,\n DropdownMenuSeparator,\n} from '@/components/shadcn-ui/dropdown-menu';\nimport FilterButton from './buttons/filter-button.component';\n\nexport enum DropdownMenuItemType {\n Check,\n Radio,\n}\n\nexport type DropdownItem = {\n /** The label is the text that will be displayed on the dropdown item. */\n label: string;\n /** The itemType determines the DropdownMenuItemType type as either Check or Radio. */\n itemType: DropdownMenuItemType;\n /** The onClick function is called when the item is clicked. */\n onClick: () => void;\n};\n\nexport type DropdownGroup = {\n /**\n * The label is the text that will be displayed on the dropdown group. It is used to categorize\n * the items in the group.\n */\n label: string;\n /** The items array contains the items that will be displayed in the dropdown group */\n items: DropdownItem[];\n};\n\nexport type FilterDropdownProps = {\n /** Object unique identifier */\n id?: string;\n /** The groups array contains the groups that will be displayed in the dropdown */\n groups: DropdownGroup[];\n}; // TODO: extend the props later\n\n/**\n * The FilterDropdown component is a dropdown designed for filtering content. It includes groups of\n * items that can be checkboxes or radio items.\n *\n * @param id Optional unique identifier\n * @param groups The groups array contains the groups that will be displayed in the dropdown\n * @returns A filter dropdown.\n */\nexport default function FilterDropdown({ id, groups }: FilterDropdownProps) {\n return (\n
    \n {/* TODO: remove this once the DropDown Menu shadcn has an id prop */}\n \n \n \n \n \n {groups.map((group) => (\n
    \n {group.label}\n \n {group.items.map((item) => (\n
    \n {item.itemType === DropdownMenuItemType.Check ? (\n \n {item.label}\n \n ) : (\n \n {item.label}\n \n )}\n
    \n ))}\n
    \n \n
    \n ))}\n
    \n
    \n
    \n );\n}\n","interface NoExtensionsFoundProps {\n /** Optional unique identifier */\n id?: string;\n /** The message to display */\n message: string;\n}\n/**\n * This component displays a message to the user when no extensions are found in the marketplace.\n *\n * @param id Optional unique identifier\n * @param message The message to display.\n * @returns {JSX.Element} - Returns the message component that displays the message to the user.\n */\nexport default function NoExtensionsFound({ id, message }: NoExtensionsFoundProps) {\n return (\n
    \n
    \n

    {message}

    \n
    \n
    \n );\n}\n","import { CircleHelp, Link as LucideLink, User } from 'lucide-react';\nimport { NumberFormat } from 'platform-bible-utils';\n\n/** Interface that stores the parameters passed to the More Info component */\ninterface MoreInfoProps {\n /** Optional unique identifier */\n id?: string;\n /** The category of the extension */\n category: string;\n /** The number of downloads for the extension */\n downloads: Record;\n /** The languages supported by the extension */\n languages: string[];\n /** The URL to the more info page of the extension */\n moreInfoUrl: string;\n}\n/**\n * This component displays the more info section of the extension which includes the category,\n * number of downloads, languages, and links to the website and support\n *\n * @param id Optional unique identifier\n * @param category The category of the extension\n * @param downloads The number of downloads for the extension\n * @param languages The languages supported by the extension\n * @param moreInfoUrl The URL to the more info page of the extension\n * @returns {JSX.Element} - Returns the more info component that displays the category, number of\n * downloads, languages, and links to the website and support\n */\nexport default function MoreInfo({\n id,\n category,\n downloads,\n languages,\n moreInfoUrl,\n}: MoreInfoProps) {\n /**\n * This constant formats the number of downloads into a more readable format.\n *\n * @example 1000 -> 1K\n *\n * @example 1000000 -> 1M\n *\n * @returns The formatted number of downloads\n */\n const numberFormatted = new NumberFormat('en', {\n notation: 'compact',\n compactDisplay: 'short',\n }).format(Object.values(downloads).reduce((a: number, b: number) => a + b, 0));\n\n /** This function scrolls the window to the bottom of the page. */\n const handleScrollToBottom = () => {\n window.scrollTo(0, document.body.scrollHeight);\n };\n\n return (\n \n
    \n
    \n {category}\n
    \n CATEGORY\n
    \n
    \n
    \n
    \n \n {numberFormatted}\n
    \n USERS\n
    \n
    \n
    \n
    \n {languages.slice(0, 3).map((locale) => (\n \n {locale.toUpperCase()}\n \n ))}\n
    \n {languages.length > 3 && (\n handleScrollToBottom()}\n className=\"tw-text-xs tw-text-gray-500 tw-underline\"\n >\n +{languages.length - 3} more languages\n \n )}\n
    \n
    \n
    \n \n Website\n \n \n \n Support\n \n \n
    \n
    \n );\n}\n","import { useState } from 'react';\n\nexport type VersionInformation = {\n /** Date the version was published */\n date: string;\n /** Description of the changes in the version */\n description: string;\n};\n\n/** Type to store the version history information */\nexport type VersionHistoryType = Record;\n\n/** Interface that stores the parameters passed to the Version History component */\ninterface VersionHistoryProps {\n /** Optional unique identifier */\n id?: string;\n /** Object containing the versions mapped with their information */\n versionHistory: VersionHistoryType;\n}\n\n/**\n * Component to render the version history information shown in the footer component. Lists the 5\n * most recent versions, with the options to show all versions by pressing a button.\n *\n * @param versionHistory Object containing the versions mapped with their information\n * @param id Optional unique identifier\n * @returns Rendered version history for the Footer component\n */\nexport default function VersionHistory({ id, versionHistory }: VersionHistoryProps) {\n const [showAllVersions, setShowAllVersions] = useState(false);\n const currentDate = new Date();\n\n /**\n * Function to format the time string for the version history in the form of 'X year(s) ago'.\n *\n * @param dateString ISO Date string to determine the time string from\n * @returns Formatted time string\n */\n function formatTimeString(dateString: string) {\n const date = new Date(dateString);\n const dateDiff = new Date(currentDate.getTime() - date.getTime());\n const yearDiff = dateDiff.getUTCFullYear() - 1970;\n const monthDiff = dateDiff.getUTCMonth();\n const dayDiff = dateDiff.getUTCDate() - 1;\n\n // Determines how long ago the version was published\n let timeString = '';\n if (yearDiff > 0) {\n timeString = `${yearDiff.toString()} year${yearDiff === 1 ? '' : 's'} ago`;\n } else if (monthDiff > 0) {\n timeString = `${monthDiff.toString()} month${monthDiff === 1 ? '' : 's'} ago`;\n } else if (dayDiff === 0) {\n timeString = 'today';\n } else {\n timeString = `${dayDiff.toString()} day${dayDiff === 1 ? '' : 's'} ago`;\n }\n\n return timeString;\n }\n\n // Sorts the version history by version number\n const sortedEntries = Object.entries(versionHistory).sort((a, b) => b[0].localeCompare(a[0]));\n\n return (\n
    \n

    What`s New

    \n
      \n {(showAllVersions ? sortedEntries : sortedEntries.slice(0, 5)).map((entry) => (\n
      \n
      \n
    • \n {entry[1].description}\n
    • \n
      \n
      \n
      Version {entry[0]}
      \n
      {formatTimeString(entry[1].date)}
      \n
      \n
      \n ))}\n
    \n {sortedEntries.length > 5 && (\n setShowAllVersions(!showAllVersions)}\n className=\"tw-text-xs tw-text-gray-500 tw-underline\"\n >\n {showAllVersions ? 'Show Less Version History' : 'Show All Version History'}\n \n )}\n
    \n );\n}\n","import { useMemo } from 'react';\nimport { formatBytes } from 'platform-bible-utils';\nimport VersionHistory, { VersionHistoryType } from './version-history.component';\n\n/** Interface to store the parameters passed to the Footer component */\ninterface FooterProps {\n /** Optional unique identifier */\n id?: string;\n /** Name of the publisher */\n publisherDisplayName: string;\n /** Size of the extension file in bytes */\n fileSize: number;\n /** List of language codes supported by the extension */\n locales: string[];\n /** Object containing the version history mapped with their information */\n versionHistory: VersionHistoryType;\n}\n\n/**\n * Component to render the footer for the extension details which contains information on the\n * publisher, version history, languages, and file size.\n *\n * @param id Optional unique identifier\n * @param publisherDisplayName Name of the publisher\n * @param fileSize Size of the extension file in bytes\n * @param locales List of language codes supported by the extension\n * @param versionHistory Object containing the version history mapped with their information\n * @returns The rendered Footer component\n */\nexport default function Footer({\n id,\n publisherDisplayName,\n fileSize,\n locales,\n versionHistory,\n}: FooterProps) {\n /** Formats the file size into a human-readable format */\n const formattedFileSize = useMemo(() => formatBytes(fileSize), [fileSize]);\n\n /**\n * This function gets the display names of the languages based on the language codes.\n *\n * @param codes The list of language codes\n * @returns The list of language names\n */\n const getLanguageNames = (codes: string[]) => {\n const displayNames = new Intl.DisplayNames(navigator.language, { type: 'language' });\n return codes.map((code) => displayNames.of(code));\n };\n\n const languageNames = getLanguageNames(locales);\n\n return (\n
    \n
    \n \n
    \n
    \n

    Information

    \n
    \n

    \n Publisher\n {publisherDisplayName}\n Size\n {formattedFileSize}\n

    \n
    \n

    \n Languages\n {languageNames.join(', ')}\n

    \n
    \n
    \n
    \n
    \n
    \n );\n}\n","import { PlatformEvent, PlatformEventHandler } from 'platform-bible-utils';\nimport { useEffect } from 'react';\n\n/**\n * Adds an event handler to an event so the event handler runs when the event is emitted. Use\n * `papi.network.getNetworkEvent` to use a networked event with this hook.\n *\n * @param event The event to subscribe to.\n *\n * - If event is a `PlatformEvent`, that event will be used\n * - If event is undefined, the callback will not be subscribed. Useful if the event is not yet\n * available for example\n *\n * @param eventHandler The callback to run when the event is emitted\n *\n * WARNING: MUST BE STABLE - const or wrapped in useCallback. The reference must not be updated\n * every render\n */\nconst useEvent = (\n event: PlatformEvent | undefined,\n eventHandler: PlatformEventHandler,\n) => {\n useEffect(() => {\n // Do nothing if the event is not provided (in case the event is not yet available, for example)\n if (!event) return () => {};\n\n const unsubscriber = event(eventHandler);\n return () => {\n unsubscriber();\n };\n }, [event, eventHandler]);\n};\nexport default useEvent;\n","import { useCallback, useEffect } from 'react';\nimport { PlatformEvent, PlatformEventAsync, PlatformEventHandler } from 'platform-bible-utils';\nimport usePromise from './use-promise.hook';\n\nconst noopUnsubscriber = () => false;\n\n/**\n * Adds an event handler to an asynchronously subscribing/unsubscribing event so the event handler\n * runs when the event is emitted. Use `papi.network.getNetworkEvent` to use a networked event with\n * this hook.\n *\n * @param event The asynchronously (un)subscribing event to subscribe to.\n *\n * - If event is a `PlatformEvent` or `PlatformEventAsync`, that event will be used\n * - If event is undefined, the callback will not be subscribed. Useful if the event is not yet\n * available for example\n *\n * @param eventHandler The callback to run when the event is emitted\n *\n * WARNING: MUST BE STABLE - const or wrapped in useCallback. The reference must not be updated\n * every render\n */\nconst useEventAsync = (\n event: PlatformEvent | PlatformEventAsync | undefined,\n eventHandler: PlatformEventHandler,\n) => {\n // Subscribe to the event asynchronously\n const [unsubscribe] = usePromise(\n useCallback(async () => {\n // Do nothing if the event is not provided (in case the event is not yet available, for example)\n if (!event) return noopUnsubscriber;\n\n // Wrap subscribe and unsubscribe in promises to allow normal events to be used as well\n const unsub = await Promise.resolve(event(eventHandler));\n return async () => unsub();\n }, [eventHandler, event]),\n noopUnsubscriber,\n // We want the unsubscriber to return to default value immediately upon changing subscription\n // So the useEffect below will unsubscribe asap\n { preserveValue: false },\n );\n\n // Unsubscribe from the event asynchronously (but we aren't awaiting the unsub)\n useEffect(() => {\n return () => {\n if (unsubscribe !== noopUnsubscriber) {\n unsubscribe();\n }\n };\n }, [unsubscribe]);\n};\n\nexport default useEventAsync;\n"],"names":["twMergeCustom","extendTailwindMerge","cn","inputs","clsx","Input","React","className","type","props","ref","jsx","BookChapterInput","forwardRef","handleSearch","handleKeyDown","handleOnClick","handleSubmit","jsxs","ShadInput","event","e","History","P","R","t","s","n","N","B","O","S","K","g","k","x","T","X","V","w","L","G","A","H","C","I","y","q","U","m","l","h","c","E","D","i","a","o","u","v","f","d","b","p","J","DropdownMenu","DropdownMenuPrimitive","DropdownMenuTrigger","DropdownMenuGroup","DropdownMenuPortal","DropdownMenuSub","DropdownMenuRadioGroup","DropdownMenuSubTrigger","inset","children","ChevronRight","DropdownMenuSubContent","DropdownMenuContent","sideOffset","DropdownMenuItem","DropdownMenuCheckboxItem","checked","Check","DropdownMenuRadioItem","Circle","DropdownMenuLabel","DropdownMenuSeparator","DropdownMenuShortcut","BookMenuItem","bookId","handleSelectBook","isSelected","handleHighlightBook","bookType","ShadDropdownMenuItem","Canon","ChapterSelect","handleSelectChapter","endChapter","activeChapter","highlightedChapter","handleHighlightedChapter","chapters","_","handleMouse","useCallback","chapterNumber","chapter","GoToMenuItem","handleSort","handleLocationHistory","handleBookmarks","ShadDropdownMenuLabel","ArrowDownWideNarrow","Clock","Bookmark","ALL_BOOK_IDS","BOOK_TYPE_LABELS","BOOK_TYPE_ARRAY","SCROLL_OFFSET","SEARCH_QUERY_FORMATS","fetchGroupedBooks","fetchEndChapter","getChaptersForBook","getAllEnglishNames","isValidBookEnglishName","bookName","getBookIdFromEnglishName","formattedBookName","BookChapterControl","scrRef","searchQuery","setSearchQuery","useState","selectedBookId","setSelectedBookId","setHighlightedChapter","highlightedBookId","setHighlightedBookId","isContentOpen","setIsContentOpen","isContentOpenDelayed","setIsContentOpenDelayed","inputRef","useRef","contentRef","menuItemRef","fetchFilteredBooks","englishNameLowerCase","normalizedQuery","handleSearchInput","searchString","shouldPreventAutoClosing","controlMenuState","open","updateReference","shouldClose","verse","handleInputSubmit","format","matches","book","englishName","handleKeyDownInput","handleKeyDownContent","key","handleKeyDownMenuItem","chapterOffSet","useEffect","useLayoutEffect","scrollTimeout","scrollPosition","ShadDropdownMenu","ShadDropdownMenuTrigger","ShadDropdownMenuContent","bookTypeIndex","element","ShadDropdownMenuSeparator","buttonVariants","cva","Button","variant","size","asChild","Comp","Slot","labelVariants","Label","LabelPrimitive","RadioGroup","RadioGroupPrimitive","RadioGroupItem","Popover","PopoverPrimitive","PopoverTrigger","PopoverContent","align","DialogPortal","DialogPrimitive","DialogOverlay","DialogContent","DialogTitle","DialogDescription","Command","CommandPrimitive","CommandInput","Search","CommandList","CommandEmpty","CommandGroup","CommandSeparator","CommandItem","getOptionLabelDefault","option","ComboBox","id","options","value","onChange","getOptionLabel","buttonPlaceholder","textPlaceholder","commandEmptyMessage","buttonVariant","dir","isDisabled","setOpen","ChevronsUpDown","ChapterRangeSelector","startChapter","handleSelectStartChapter","handleSelectEndChapter","chapterCount","chapterOptions","useMemo","index","onChangeStartChapter","onChangeEndChapter","Fragment","BookSelectionMode","BOOK_SELECTOR_STRING_KEYS","localizeString","strings","BookSelector","handleBookSelectionModeChange","currentBookName","onSelectBooks","selectedBookIds","localizedStrings","currentBookText","chooseText","chooseBooksText","bookSelectionMode","setBookSelectionMode","onSelectionModeChange","newMode","DataTableViewOptions","table","FilterIcon","column","Select","SelectPrimitive","SelectGroup","SelectValue","SelectTrigger","ChevronDown","SelectScrollUpButton","ChevronUp","SelectScrollDownButton","SelectContent","position","SelectLabel","SelectItem","SelectSeparator","DataTablePagination","pageSize","ArrowLeftIcon","ChevronLeftIcon","ChevronRightIcon","ArrowRightIcon","Table","stickyHeader","TableHeader","TableBody","TableFooter","TableRow","TableHead","TableCell","TableCaption","DataTable","columns","data","enablePagination","showPaginationControls","showColumnVisibilityControls","onRowClickHandler","sorting","setSorting","columnFilters","setColumnFilters","columnVisibility","setColumnVisibility","rowSelection","setRowSelection","useReactTable","getCoreRowModel","getPaginationRowModel","getSortedRowModel","getFilteredRowModel","headerGroup","header","flexRender","_a","row","cell","OccurrencesTable","occurrenceData","setScriptureReference","referenceHeaderText","occurrenceHeaderText","occurrences","uniqueOccurrences","occurrence","uniqueOccurrence","deepEqual","Checkbox","CheckboxPrimitive","getLinesFromUSFM","text","getNumberFromUSFM","regex","match","getBookNumFromId","getStatusForItem","item","approvedItems","unapprovedItems","toggleVariants","Toggle","TogglePrimitive","ToggleGroupContext","ToggleGroup","ToggleGroupPrimitive","ToggleGroupItem","context","getSortingIcon","sortDirection","ArrowUpIcon","ArrowDownIcon","ArrowUpDownIcon","inventoryItemColumn","itemLabel","inventoryAdditionalItemColumn","additionalItemLabel","additionalItemIndex","inventoryCountColumn","countLabel","statusChangeHandler","changedItems","newStatus","onApprovedItemsChange","onUnapprovedItemsChange","newApprovedItems","validItem","newUnapprovedItems","unapprovedItem","inventoryStatusColumn","statusLabel","status","CircleCheckIcon","CircleXIcon","CircleHelpIcon","INVENTORY_STRING_KEYS","filterItemData","itemData","statusFilter","textFilter","filteredItemData","createTableData","scriptureRef","itemRegex","tableData","currentBook","currentChapter","currentVerse","line","items","itemIndex","existingItem","tableEntry","newReference","substring","newItem","Inventory","scriptureReference","extractItems","additionalItemsLabels","scope","onScopeChange","allItemsText","approvedItemsText","unapprovedItemsText","unknownItemsText","scopeBookText","scopeChapterText","scopeVerseText","filterText","showAdditionalItemsText","showAdditionalItems","setShowAdditionalItems","setStatusFilter","setTextFilter","selectedItem","setSelectedItem","reducedTableData","newTableData","firstItem","existingEntry","newTableEntry","filteredTableData","allColumns","numberOfAdditionalItems","additionalColumns","_b","rowClickHandler","newSelection","handleScopeChange","handleStatusFilterChange","SearchBar","onSearch","placeholder","isFullWidth","handleInputChange","VerticalTabs","TabsPrimitive","VerticalTabsList","VerticalTabsTrigger","VerticalTabsContent","TabNavigationContentSearch","tabList","searchPlaceholder","headerTitle","isSearchBarFullWidth","direction","tab","Separator","orientation","decorative","SeparatorPrimitive","Sheet","SheetPrimitive","SheetPortal","SheetOverlay","sheetVariants","SheetContent","side","SheetTitle","SheetDescription","Skeleton","TooltipProvider","TooltipPrimitive","Tooltip","TooltipTrigger","TooltipContent","MOBILE_BREAKPOINT","useIsMobile","isMobile","setIsMobile","mql","SIDEBAR_COOKIE_NAME","SIDEBAR_COOKIE_MAX_AGE","SIDEBAR_WIDTH","SIDEBAR_WIDTH_MOBILE","SIDEBAR_WIDTH_ICON","SIDEBAR_KEYBOARD_SHORTCUT","SidebarContext","useSidebar","SidebarProvider","defaultOpen","openProp","setOpenProp","style","openMobile","setOpenMobile","_open","_setOpen","isOpen","openState","toggleSidebar","state","contextValue","Sidebar","collapsible","SidebarTrigger","onClick","PanelLeft","SidebarRail","SidebarInset","SidebarInput","SidebarHeader","SidebarFooter","SidebarSeparator","SidebarContent","SidebarGroup","SidebarGroupLabel","SidebarGroupAction","SidebarGroupContent","SidebarMenu","SidebarMenuItem","sidebarMenuButtonVariants","SidebarMenuButton","isActive","tooltip","button","SidebarMenuAction","showOnHover","SidebarMenuBadge","SidebarMenuSkeleton","showIcon","width","SidebarMenuSub","SidebarMenuSubItem","SidebarMenuSubButton","SettingsSidebar","extensionLabels","handleSelectSidebarItem","handleSelectItem","isProjectSetting","label","SettingsSidebarContentSearch","scrBookColId","scrRefColId","typeColId","detailsColId","defaultScrRefColumnName","defaultScrBookGroupName","defaultTypeColumnName","defaultDetailsColumnName","getColumns","colInfo","showSourceColumn","showSrcCol","info","formatScrRef","compareScrRefs","toRefOrRange","scriptureSelection","offsetStart","offsetEnd","scrRefToBBBCCCVVV","getRowKey","ScriptureResultsViewer","sources","showColumnHeaders","scriptureReferenceColumnName","scriptureBookGroupName","typeColumnName","detailsColumnName","onRowSelected","grouping","setGrouping","scriptureResults","source","getExpandedRowModel","getGroupedRowModel","selectedRows","keys","selectedRow","scrBookGroupName","typeGroupName","groupingOptions","handleSelectChange","selectedGrouping","handleRowClick","getEvenOrOddBandingStyle","getIndent","groupingState","rowIndex","ChevronLeft","DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS","getLocalizeKeyForScrollGroupId","ScrollGroupSelector","availableScrollGroupIds","scrollGroupId","onChangeScrollGroupId","localizedStringsDefaulted","localizedStringKey","localizedStringValue","newScrollGroupString","scrollGroupOptionId","SettingsList","SettingsListItem","primary","secondary","isLoading","loadingMessage","SettingsListHeader","includeSeparator","Card","CardHeader","CardTitle","CardDescription","CardContent","CardFooter","SettingsCard","settingsGroupLabel","settingsGroupDescription","Checklist","listItems","selectedListItems","handleSelectListItem","createLabel","_interopRequireDefault","obj","module","chainPropTypes","propType1","propType2","args","_extends","target","isPlainObject","prototype","deepClone","output","deepmerge","r","z","reactIs_production_min","hasSymbol","REACT_ELEMENT_TYPE","REACT_PORTAL_TYPE","REACT_FRAGMENT_TYPE","REACT_STRICT_MODE_TYPE","REACT_PROFILER_TYPE","REACT_PROVIDER_TYPE","REACT_CONTEXT_TYPE","REACT_ASYNC_MODE_TYPE","REACT_CONCURRENT_MODE_TYPE","REACT_FORWARD_REF_TYPE","REACT_SUSPENSE_TYPE","REACT_SUSPENSE_LIST_TYPE","REACT_MEMO_TYPE","REACT_LAZY_TYPE","REACT_BLOCK_TYPE","REACT_FUNDAMENTAL_TYPE","REACT_RESPONDER_TYPE","REACT_SCOPE_TYPE","isValidElementType","typeOf","object","$$typeof","$$typeofType","AsyncMode","ConcurrentMode","ContextConsumer","ContextProvider","Element","ForwardRef","Lazy","Memo","Portal","Profiler","StrictMode","Suspense","hasWarnedAboutDeprecatedIsAsyncMode","isAsyncMode","isConcurrentMode","isContextConsumer","isContextProvider","isElement","isForwardRef","isFragment","isLazy","isMemo","isPortal","isProfiler","isStrictMode","isSuspense","reactIs_development","reactIsModule","require$$0","require$$1","getOwnPropertySymbols","hasOwnProperty","propIsEnumerable","toObject","val","shouldUseNative","test1","test2","order2","test3","letter","objectAssign","from","to","symbols","ReactPropTypesSecret","ReactPropTypesSecret_1","has","printWarning","loggedTypeFailures","message","checkPropTypes","typeSpecs","values","location","componentName","getStack","typeSpecName","error","err","ex","stack","checkPropTypes_1","ReactIs","assign","require$$2","require$$3","require$$4","emptyFunctionThatReturnsNull","factoryWithTypeCheckers","isValidElement","throwOnDirectAccess","ITERATOR_SYMBOL","FAUX_ITERATOR_SYMBOL","getIteratorFn","maybeIterable","iteratorFn","ANONYMOUS","ReactPropTypes","createPrimitiveTypeChecker","createAnyTypeChecker","createArrayOfTypeChecker","createElementTypeChecker","createElementTypeTypeChecker","createInstanceTypeChecker","createNodeChecker","createObjectOfTypeChecker","createEnumTypeChecker","createUnionTypeChecker","createShapeTypeChecker","createStrictShapeTypeChecker","is","PropTypeError","createChainableTypeChecker","validate","manualPropTypeCallCache","manualPropTypeWarningCount","checkType","isRequired","propName","propFullName","secret","cacheKey","chainedCheckType","expectedType","propValue","propType","getPropType","preciseType","getPreciseType","typeChecker","expectedClass","expectedClassName","actualClassName","getClassName","expectedValues","valuesString","arrayOfTypeCheckers","checker","getPostfixForTypeWarning","expectedTypes","checkerResult","expectedTypesMessage","isNode","invalidValidatorError","shapeTypes","allKeys","iterator","step","entry","isSymbol","emptyFunction","emptyFunctionWithReset","factoryWithThrowingShims","shim","getShim","propTypesModule","isClassComponent","elementType","acceptingRef","safePropName","warningHint","elementAcceptingRef","PropTypes","elementAcceptingRef$1","specialProperty","exactProp","propTypes","unsupportedProps","prop","formatMuiErrorMessage","code","url","REACT_SERVER_CONTEXT_TYPE","REACT_OFFSCREEN_TYPE","enableScopeAPI","enableCacheElement","enableTransitionTracing","enableLegacyHidden","enableDebugTracing","REACT_MODULE_REFERENCE","SuspenseList","hasWarnedAboutDeprecatedIsConcurrentMode","isSuspenseList","fnNameMatchRegex","getFunctionName","fn","getFunctionComponentName","Component","fallback","getWrappedName","outerType","innerType","wrapperName","functionName","getDisplayName","HTMLElementType","refType","refType$1","capitalize","string","_formatMuiErrorMessage","createChainedFunction","funcs","acc","func","debounce","wait","timeout","debounced","later","deprecatedPropType","validator","reason","componentNameSafe","propFullNameSafe","isMuiElement","muiNames","_muiName","_element$type","ownerDocument","node","ownerWindow","requirePropFactory","componentNameInError","prevPropTypes","requiredProp","defaultTypeChecker","typeCheckerResult","setRef","useEnhancedEffect","useEnhancedEffect$1","globalId","useGlobalId","idOverride","defaultId","setDefaultId","maybeReactUseId","useId","reactId","unsupportedProp","useControlled","controlled","defaultProp","name","isControlled","valueState","setValue","defaultValue","setValueIfUncontrolled","newValue","useEventCallback","useForkRef","refs","instance","UNINITIALIZED","useLazyRef","init","initArg","EMPTY","useOnMount","Timeout","delay","useTimeout","hadKeyboardEvent","hadFocusVisibleRecently","hadFocusVisibleRecentlyTimeout","inputTypesWhitelist","focusTriggersKeyboardModality","tagName","handlePointerDown","handleVisibilityChange","prepare","doc","isFocusVisible","useIsFocusVisible","isFocusVisibleRef","handleBlurVisible","handleFocusVisible","resolveProps","defaultProps","defaultSlotProps","slotProps","slotPropName","composeClasses","slots","getUtilityClass","classes","slot","utilityClass","defaultGenerator","createClassNameGenerator","generate","generator","ClassNameGenerator","ClassNameGenerator$1","globalStateClasses","generateUtilityClass","globalStatePrefix","globalStateClass","generateUtilityClasses","result","clamp","min","max","_objectWithoutPropertiesLoose","excluded","sourceKeys","_excluded","sortBreakpointsValues","breakpointsAsArray","breakpoint1","breakpoint2","createBreakpoints","breakpoints","unit","other","sortedValues","up","down","between","start","end","endIndex","only","not","keyIndex","shape","shape$1","responsivePropType","responsivePropType$1","merge","defaultBreakpoints","handleBreakpoints","styleFromPropValue","theme","themeBreakpoints","breakpoint","mediaKey","cssKey","createEmptyBreakpointObject","breakpointsInput","_breakpointsInput$key","breakpointStyleKey","removeUnusedBreakpoints","breakpointKeys","breakpointOutput","getPath","path","checkVars","getStyleValue","themeMapping","transform","propValueFinal","userValue","cssProperty","themeKey","memoize","cache","arg","properties","directions","aliases","getCssProperties","property","marginKeys","paddingKeys","spacingKeys","createUnaryUnit","_getPath","themeSpacing","abs","createUnarySpacing","getValue","transformer","transformed","getStyleFromPropValue","cssProperties","resolveCssProperty","margin","padding","createSpacing","spacingInput","spacing","argsInput","argument","compose","styles","handlers","borderTransform","createBorderStyle","border","borderTop","borderRight","borderBottom","borderLeft","borderColor","borderTopColor","borderRightColor","borderBottomColor","borderLeftColor","outline","outlineColor","borderRadius","gap","columnGap","rowGap","gridColumn","gridRow","gridAutoFlow","gridAutoColumns","gridAutoRows","gridTemplateColumns","gridTemplateRows","gridTemplateAreas","gridArea","paletteTransform","color","bgcolor","backgroundColor","sizingTransform","maxWidth","_props$theme","_props$theme2","breakpointsValues","minWidth","height","maxHeight","minHeight","boxSizing","defaultSxConfig","defaultSxConfig$1","objectsHaveSameKeys","objects","union","callIfFn","maybeFn","unstable_createStyleFunctionSx","getThemeValue","config","styleFunctionSx","_theme$unstable_sxCon","sx","traverse","sxInput","sxObject","emptyBreakpoints","breakpointsKeys","css","styleKey","styleFunctionSx$1","applyStyles","createTheme","paletteInput","shapeInput","muiTheme","isObjectEmpty","useTheme","defaultTheme","contextTheme","ThemeContext","systemDefaultTheme","useThemeWithoutDefault","_excluded2","_excluded3","isEmpty","isStringTag","tag","shouldForwardProp","lowercaseFirstLetter","resolveTheme","themeId","defaultOverridesResolver","processStyleArg","callableStyle","_ref","ownerState","resolvedStylesArg","resolvedStyle","variants","isMatch","createStyled","input","rootShouldForwardProp","slotShouldForwardProp","systemSx","inputOptions","processStyles","componentSlot","inputSkipVariantsResolver","inputSkipSx","overridesResolver","skipVariantsResolver","skipSx","shouldForwardPropOption","defaultStyledResolver","styledEngineStyled","transformStyleArg","stylesArg","muiStyledResolver","styleArg","expressions","transformedStyleArg","expressionsWithDefaultTheme","styleOverrides","resolvedStyleOverrides","slotKey","slotStyle","_theme$components","themeVariants","numOfCustomFnsApplied","placeholders","displayName","getThemeProps","params","useThemeProps","clampWrapper","hexToRgb","re","colors","decomposeColor","marker","colorSpace","recomposeColor","hslToRgb","rgb","getLuminance","getContrastRatio","foreground","background","lumA","lumB","alpha","darken","coefficient","lighten","createMixins","mixins","common","common$1","grey","grey$1","purple","purple$1","red","red$1","orange","orange$1","blue","blue$1","lightBlue","lightBlue$1","green","green$1","light","dark","addLightOrDark","intent","shade","tonalOffset","tonalOffsetLight","tonalOffsetDark","getDefaultPrimary","mode","getDefaultSecondary","getDefaultError","getDefaultInfo","getDefaultSuccess","getDefaultWarning","createPalette","palette","contrastThreshold","success","warning","getContrastText","contrastText","contrast","augmentColor","mainShade","lightShade","darkShade","modes","round","caseAllCaps","defaultFontFamily","createTypography","typography","fontFamily","fontSize","fontWeightLight","fontWeightRegular","fontWeightMedium","fontWeightBold","htmlFontSize","allVariants","pxToRem2","coef","pxToRem","buildVariant","fontWeight","lineHeight","letterSpacing","casing","shadowKeyUmbraOpacity","shadowKeyPenumbraOpacity","shadowAmbientShadowOpacity","createShadow","px","shadows","shadows$1","easing","duration","formatMs","milliseconds","getAutoHeightDuration","constant","createTransitions","inputTransitions","mergedEasing","mergedDuration","durationOption","easingOption","isString","isNumber","animatedProp","zIndex","zIndex$1","mixinsInput","transitionsInput","typographyInput","systemTheme","systemCreateTheme","stateClasses","component","child","stateClass","defaultTheme$1","THEME_ID","systemUseThemeProps","styled","styled$1","getSvgIconUtilityClass","useUtilityClasses","SvgIconRoot","_theme$transitions","_theme$transitions$cr","_theme$transitions2","_theme$typography","_theme$typography$pxT","_theme$typography2","_theme$typography2$px","_theme$typography3","_theme$typography3$px","_palette$ownerState$c","_palette","_palette2","_palette3","SvgIcon","inProps","htmlColor","inheritViewBox","titleAccess","viewBox","hasSvgAsChild","more","_jsxs","_jsx","SvgIcon$1","createSvgIcon","unstable_ClassNameGenerator","exports","_utils","ArrowRight","default_1","_createSvgIcon","_jsxRuntime","isHostComponent","appendOwnerState","otherProps","defaultContextValue","ClassNameConfiguratorContext","useClassNamesOverride","disableDefaultClasses","extractEventHandlers","excludeKeys","resolveComponentProps","componentProps","slotState","omitEventHandlers","mergeSlotProps","parameters","getSlotProps","additionalProps","externalSlotProps","externalForwardedProps","joinedClasses","mergedStyle","eventHandlers","componentsPropsWithoutEventHandlers","otherPropsWithoutEventHandlers","internalSlotProps","useSlotProps","_parameters$additiona","skipResolvingSlotProps","rest","resolvedComponentsProps","mergedProps","internalRef","GLOBAL_CLASS_PREFIX","buildStateClass","buildSlotClass","getContainer","container","forwardedRef","disablePortal","mountNode","setMountNode","handleRef","newProps","ReactDOM","top","bottom","right","left","auto","basePlacements","clippingParents","viewport","popper","reference","variationPlacements","placement","placements","beforeRead","read","afterRead","beforeMain","main","afterMain","beforeWrite","write","afterWrite","modifierPhases","getNodeName","getWindow","OwnElement","isHTMLElement","isShadowRoot","attributes","effect","_ref2","initialStyles","styleProperties","attribute","applyStyles$1","getBasePlacement","getUAString","uaData","isLayoutViewport","getBoundingClientRect","includeScale","isFixedStrategy","clientRect","scaleX","scaleY","visualViewport","addVisualOffsets","getLayoutRect","contains","parent","rootNode","next","getComputedStyle","isTableElement","getDocumentElement","getParentNode","getTrueOffsetParent","getContainingBlock","isFirefox","isIE","elementCss","currentNode","getOffsetParent","window","offsetParent","getMainAxisFromPlacement","within","mathMax","mathMin","withinMaxClamp","getFreshSideObject","mergePaddingObject","paddingObject","expandToHashMap","hashMap","toPaddingObject","arrow","_state$modifiersData$","arrowElement","popperOffsets","basePlacement","axis","isVertical","len","arrowRect","minProp","maxProp","endDiff","startDiff","arrowOffsetParent","clientSize","centerToReference","center","offset","axisProp","_options$element","arrow$1","getVariation","unsetSides","roundOffsetsByDPR","win","dpr","mapToStyles","_Object$assign2","popperRect","variation","offsets","gpuAcceleration","adaptive","roundOffsets","isFixed","_offsets$x","_offsets$y","_ref3","hasX","hasY","sideX","sideY","heightProp","widthProp","offsetY","offsetX","commonStyles","_ref4","_Object$assign","computeStyles","_ref5","_options$gpuAccelerat","_options$adaptive","_options$roundOffsets","computeStyles$1","passive","_options$scroll","scroll","_options$resize","resize","scrollParents","scrollParent","eventListeners","hash","getOppositePlacement","matched","getOppositeVariationPlacement","getWindowScroll","scrollLeft","scrollTop","getWindowScrollBarX","getViewportRect","strategy","html","layoutViewport","getDocumentRect","_element$ownerDocumen","winScroll","body","isScrollParent","_getComputedStyle","overflow","overflowX","overflowY","getScrollParent","listScrollParents","list","isBody","updatedList","rectToClientRect","rect","getInnerBoundingClientRect","getClientRectFromMixedType","clippingParent","getClippingParents","canEscapeClipping","clipperElement","getClippingRect","boundary","rootBoundary","mainClippingParents","firstClippingParent","clippingRect","accRect","computeOffsets","commonX","commonY","mainAxis","detectOverflow","_options","_options$placement","_options$strategy","_options$boundary","_options$rootBoundary","_options$elementConte","elementContext","_options$altBoundary","altBoundary","_options$padding","altContext","clippingClientRect","referenceClientRect","popperClientRect","elementClientRect","overflowOffsets","offsetData","multiply","computeAutoPlacement","flipVariations","_options$allowedAutoP","allowedAutoPlacements","allPlacements","allowedPlacements","overflows","getExpandedFallbackPlacements","oppositePlacement","flip","_options$mainAxis","checkMainAxis","_options$altAxis","checkAltAxis","specifiedFallbackPlacements","_options$flipVariatio","preferredPlacement","isBasePlacement","fallbackPlacements","referenceRect","checksMap","makeFallbackChecks","firstFittingPlacement","_basePlacement","isStartVariation","mainVariationSide","altVariationSide","checks","check","numberOfChecks","_loop","_i","fittingPlacement","_ret","flip$1","getSideOffsets","preventedOffsets","isAnySideFullyClipped","hide","referenceOverflow","popperAltOverflow","referenceClippingOffsets","popperEscapeOffsets","isReferenceHidden","hasPopperEscaped","hide$1","distanceAndSkiddingToXY","rects","invertDistance","skidding","distance","_options$offset","_data$state$placement","offset$1","popperOffsets$1","getAltAxis","preventOverflow","_options$tether","tether","_options$tetherOffset","tetherOffset","altAxis","tetherOffsetValue","normalizedTetherOffsetValue","offsetModifierState","_offsetModifierState$","mainSide","altSide","additive","minLen","maxLen","arrowPaddingObject","arrowPaddingMin","arrowPaddingMax","arrowLen","minOffset","maxOffset","clientOffset","offsetModifierValue","tetherMin","tetherMax","preventedOffset","_offsetModifierState$2","_mainSide","_altSide","_offset","_len","_min","_max","isOriginSide","_offsetModifierValue","_tetherMin","_tetherMax","_preventedOffset","preventOverflow$1","getHTMLElementScroll","getNodeScroll","isElementScaled","getCompositeRect","elementOrVirtualElement","isOffsetParentAnElement","offsetParentIsScaled","documentElement","order","modifiers","map","visited","modifier","sort","requires","dep","depModifier","orderModifiers","orderedModifiers","phase","pending","resolve","mergeByName","merged","current","existing","DEFAULT_OPTIONS","areValidElements","_key","popperGenerator","generatorOptions","_generatorOptions","_generatorOptions$def","defaultModifiers","_generatorOptions$def2","defaultOptions","effectCleanupFns","isDestroyed","setOptionsAction","cleanupModifierEffects","runModifierEffects","_state$elements","_state$orderedModifie","_state$orderedModifie2","_ref$options","cleanupFn","noopFn","createPopper","COMPONENT_NAME","getPopperUtilityClass","flipPlacement","resolveAnchorEl","anchorEl","isVirtualElement","defaultPopperOptions","PopperTooltip","_slots$root","initialPlacement","popperOptions","popperRefProp","TransitionProps","tooltipRef","ownRef","popperRef","handlePopperRef","handlePopperRefRef","rtlPlacement","setPlacement","resolvedAnchorElement","setResolvedAnchorElement","handlePopperUpdate","box","popperModifiers","childProps","Root","rootProps","Popper","containerProp","keepMounted","transition","exited","setExited","handleEnter","handleExited","resolvedAnchorEl","display","transitionProps","useThemeSystem","_setPrototypeOf","_inheritsLoose","subClass","superClass","setPrototypeOf","timeoutsShape","TransitionGroupContext","forceReflow","UNMOUNTED","EXITED","ENTERING","ENTERED","EXITING","Transition","_React$Component","_this","parentGroup","appear","initialStatus","prevState","nextIn","_proto","prevProps","nextStatus","exit","enter","mounting","_this2","appearing","maybeNode","maybeAppearing","timeouts","enterTimeout","_this3","nextState","callback","_this4","active","handler","doesNotHaveTimeoutOrListener","maybeNextCallback","_this$props","pt","noop","Transition$1","reflow","getTransitionProps","_style$transitionDura","_style$transitionTimi","getScale","isWebKit154","Grow","addEndListener","inProp","onEnter","onEntered","onEntering","onExit","onExited","onExiting","TransitionComponent","timer","autoTimeout","nodeRef","normalizedTransitionCallback","maybeIsAppearing","handleEntering","isAppearing","transitionDuration","transitionTimingFunction","handleEntered","handleExiting","handleExit","handleAddEndListener","Grow$1","PopperRoot","BasePopper","components","componentsProps","RootComponent","Popper$1","getTooltipUtilityClass","tooltipClasses","tooltipClasses$1","disableInteractive","touch","TooltipPopper","TooltipTooltip","TooltipArrow","hystersisOpen","hystersisTimer","cursorPosition","composeEventHandler","eventHandler","_slots$popper","_slots$transition","_slots$tooltip","_slots$arrow","_slotProps$popper","_ref6","_slotProps$popper2","_slotProps$transition","_slotProps$tooltip","_ref7","_slotProps$tooltip2","_slotProps$arrow","_ref8","_slotProps$arrow2","childrenProp","describeChild","disableFocusListener","disableHoverListener","disableInteractiveProp","disableTouchListener","enterDelay","enterNextDelay","enterTouchDelay","followCursor","idProp","leaveDelay","leaveTouchDelay","onClose","onOpen","PopperComponentProp","PopperProps","title","TransitionComponentProp","isRtl","childNode","setChildNode","arrowRef","setArrowRef","ignoreNonTouchEvents","closeTimer","enterTimer","leaveTimer","touchTimer","setOpenState","prevUserSelect","stopTouchInteraction","handleOpen","handleClose","handleLeave","focusVisibleRef","setChildIsFocusVisible","handleBlur","handleFocus","detectTouchStart","childrenProps","handleMouseOver","handleMouseLeave","handleTouchStart","handleTouchEnd","nativeEvent","handleMouseMove","nameOrDescProps","titleIsString","interactiveWrapperListeners","_PopperProps$popperOp","tooltipModifiers","PopperComponent","TooltipComponent","ArrowComponent","popperProps","tooltipProps","tooltipArrowProps","TransitionPropsInner","Tooltip$1","getIcon","icon","menuLabel","leading","MuiListItemIcon","MenuItem","allowForLeadingIcons","iconPathBefore","iconPathAfter","hasAutoFocus","isDense","isSubMenuParent","hasDisabledGutters","hasDivider","focusVisibleClassName","menuItem","MuiMenuItem","MuiListItemText","getAllGroups","menuDefinition","SubMenu","setAnchorEl","parentMenuItem","parentItemProps","handleParentMenuItemClick","renderSubMenuItems","includedGroups","group","GroupedMenuItemList","Menu","getOrderedGroupItems","groupId","allItems","menuProps","commandHandler","groupsToInclude","sortedGroups","itemArray","allowSpaceForLeadingIcons","createMenuItemProps","isLastItemInGroup","divKey","itemInfo","menuItemProps","TopLevelMenu","columnId","MenuColumn","metadata","Grid","List","GridMenu","multiColumnMenu","sortedColumns","columnNumbers","columnName","col","getUsePromiseOptionsDefaults","usePromise","promiseFactoryCallback","defaultValueRef","optionsDefaultedRef","setIsLoading","promiseIsCurrent","MenuIcon","HamburgerMenuButton","menuProvider","normalMenu","fullMenu","containerRef","ariaLabelPrefix","isMenuOpen","setMenuOpen","showFullMenu","setShowFullMenu","handleMenuItemClick","handleMenuButtonClick","prevIsOpen","isOpening","menuCommandHandler","command","setOffset","normalMenuData","fullMenuData","menu","IconButton","Drawer","isTooltipSuppressed","adjustMarginToAlignToEdge","MuiIconButton","Spinner","LoaderCircle","TextField","hasError","helperText","onFocus","onBlur","ShadLabel","Toolbar","AppBar","MuiToolbar","alertVariants","Alert","AlertTitle","AlertDescription","Sonner","Toaster","Slider","SliderPrimitive","Switch","SwitchPrimitives","Tabs","TabsList","TabsTrigger","TabsContent","InstallButton","isInstalling","handleClick","buttonText","Download","EnableButton","isEnabling","DisableButton","isDisabling","UpdateButton","isUpdating","MarkdownRenderer","markdown","anchorTarget","Markdown","FilterButton","Filter","DropdownMenuItemType","DropdownMenuItemType2","FilterDropdown","groups","NoExtensionsFound","MoreInfo","category","downloads","languages","moreInfoUrl","numberFormatted","NumberFormat","handleScrollToBottom","User","locale","LucideLink","CircleHelp","VersionHistory","versionHistory","showAllVersions","setShowAllVersions","currentDate","formatTimeString","dateString","date","dateDiff","yearDiff","monthDiff","dayDiff","timeString","sortedEntries","Footer","publisherDisplayName","fileSize","locales","formattedFileSize","formatBytes","languageNames","codes","displayNames","useEvent","unsubscriber","noopUnsubscriber","useEventAsync","unsubscribe","unsub"],"mappings":"28CAGA,MAAMA,GAAgBC,GAAAA,oBAAoB,CAAE,OAAQ,KAAO,CAAA,EAyDpD,SAASC,KAAMC,EAAsB,CACnC,OAAAH,GAAcI,GAAAA,KAAKD,CAAM,CAAC,CACnC,CCzDO,MAAME,GAAQC,EAAM,WACzB,CAAC,CAAE,UAAAC,EAAW,KAAAC,EAAM,GAAGC,CAAA,EAASC,IAE5BC,EAAA,IAAC,QAAA,CACC,KAAAH,EACA,UAAWN,EACT,sbACAK,CACF,EACA,IAAAG,EAEC,GAAGD,CAAA,CAAA,CAIZ,EACAJ,GAAM,YAAc,QCNpB,MAAMO,GAAmBC,EAAA,WACvB,CACE,CAAE,aAAAC,EAAc,cAAAC,EAAe,cAAAC,EAAe,aAAAC,EAAc,GAAGR,CAAM,EACrEC,IAGEQ,EAAA,KAAC,MAAI,CAAA,UAAU,cACb,SAAA,CAAAP,EAAA,IAACQ,GAAA,CACE,GAAGV,EACJ,KAAK,OACL,UAAU,0JACV,SAAWW,GAAUN,EAAaM,EAAM,OAAO,KAAK,EACpD,UAAYC,GAAM,CACZA,EAAE,MAAQ,SACCJ,IAEfF,EAAcM,CAAC,CACjB,EACA,QAASL,EACT,IAAAN,CAAA,CACF,EACAC,EAAA,IAACW,EAAA,QAAA,CACC,UAAU,8HACV,QAAS,IAAM,CAEb,QAAQ,IAAI,iBAAiB,CAC/B,CAAA,CACF,CACF,CAAA,CAAA,CAGN,EC9CA,IAAIC,GAAI,OAAO,eACXC,GAAI,CAACC,EAAGJ,EAAGK,IAAML,KAAKI,EAAIF,GAAEE,EAAGJ,EAAG,CAAE,WAAY,GAAI,aAAc,GAAI,SAAU,GAAI,MAAOK,CAAC,CAAE,EAAID,EAAEJ,CAAC,EAAIK,EACzGC,GAAI,CAACF,EAAGJ,EAAGK,IAAMF,GAAEC,EAAG,OAAOJ,GAAK,SAAWA,EAAI,GAAKA,EAAGK,CAAC,EAW9D,MAAME,GAAI,CACR,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MAEA,MAEA,MAEA,MAEA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,MAEA,MAEA,MAEA,MAEA,MACA,MACA,MACA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,KACF,EAAGC,GAAI,CACL,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,KACF,EAAGC,GAAI,CACL,UACA,SACA,YACA,UACA,cACA,SACA,SACA,OACA,WACA,WACA,UACA,UACA,eACA,eACA,OACA,WACA,kBACA,MACA,SACA,WACA,eACA,gBACA,SACA,WACA,eACA,UACA,kBACA,QACA,OACA,OACA,UACA,QACA,QACA,QACA,WACA,YACA,SACA,YACA,UACA,UACA,OACA,OACA,OACA,OACA,SACA,gBACA,gBACA,YACA,YACA,cACA,aACA,kBACA,kBACA,Y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AI,CACF,MAAOA,EACR,EACD,QAAS,CACP,MAAOA,EACR,EACD,WAAY,CACV,MAAOA,EACR,EACD,aAAc,CACZ,MAAOA,EACR,EACD,cAAe,CACb,MAAOA,EACR,EACD,YAAa,CACX,MAAOA,EACR,EACD,SAAU,CACR,MAAOA,EACR,EACD,SAAU,CACR,MAAOA,EACR,EACD,cAAe,CACb,MAAOA,EACR,EACD,mBAAoB,CAClB,MAAOA,EACR,EACD,iBAAkB,CAChB,MAAOA,EACR,EACD,aAAc,CACZ,MAAOA,EACR,EACD,kBAAmB,CACjB,MAAOA,EACR,EACD,gBAAiB,CACf,MAAOA,EACR,EACD,EAAG,CACD,MAAOD,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,OAAQ,CACN,MAAOA,EACR,EACD,UAAW,CACT,MAAOA,EACR,EACD,YAAa,CACX,MAAOA,EACR,EACD,aAAc,CACZ,MAAOA,EACR,EACD,WAAY,CACV,MAAOA,EACR,EACD,QAAS,CACP,MAAOA,EACR,EACD,QAAS,CACP,MAAOA,EACR,EACD,aAAc,CACZ,MAAOA,EACR,EACD,kBAAmB,CACjB,MAAOA,EACR,EACD,gBAAiB,CACf,MAAOA,EACR,EACD,YAAa,CACX,MAAOA,EACR,EACD,iBAAkB,CAChB,MAAOA,EACR,EACD,eAAgB,CACd,MAAOA,EACR,EAED,aAAc,CACZ,YAAa,GACb,UAAW3xB,IAAU,CACnB,eAAgB,CACd,QAASA,CACV,CACP,EACG,EACD,QAAS,CAAE,EACX,SAAU,CAAE,EACZ,aAAc,CAAE,EAChB,WAAY,CAAE,EACd,WAAY,CAAE,EAEd,UAAW,CAAE,EACb,cAAe,CAAE,EACjB,SAAU,CAAE,EACZ,eAAgB,CAAE,EAClB,WAAY,CAAE,EACd,aAAc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;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","x_google_ignoreList":[3,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,83,84,85,86,87,88,89,90,91,92,93,94,95,96,97,98,99,100,101,102,103,104,105,106,107,108,109,110,111,112,113,114,115,116,117,118,119,120,121,122,123,124,125,126,127,128,129,130,131,132,133,134,135,136,137,138,139,140,141,142,143,144,145,146,147,148,149,150,151,152,153,154,155,156,157,158,159,160,161,162,163,164,165,166,167,168,169,170,171,172,173,174,175,176,177,178,179,180,181,182,183,184,185,186,187,188,189,190,191,192,193,194,195,196,197,198,199,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,230]} \ No newline at end of file diff --git a/lib/platform-bible-react/dist/index.d.ts b/lib/platform-bible-react/dist/index.d.ts index 8bcbe94652..7f379c0577 100644 --- a/lib/platform-bible-react/dist/index.d.ts +++ b/lib/platform-bible-react/dist/index.d.ts @@ -417,7 +417,7 @@ export type TabKeyValueContent = { value: string; content: React$1.ReactNode; }; -export type NavigationContentSearchProps = { +export type TabNavigationContentSearchProps = { /** List of values and keys for each tab this component should provide */ tabList: TabKeyValueContent[]; /** Handler to run when the value of the search bar changes */ @@ -431,7 +431,23 @@ export type NavigationContentSearchProps = { /** Text direction ltr or rtl */ direction?: "ltr" | "rtl"; }; -export function NavigationContentSearch({ tabList, onSearch, searchPlaceholder, headerTitle, isSearchBarFullWidth, direction, }: NavigationContentSearchProps): import("react/jsx-runtime").JSX.Element; +declare function TabNavigationContentSearch({ tabList, onSearch, searchPlaceholder, headerTitle, isSearchBarFullWidth, direction, }: TabNavigationContentSearchProps): import("react/jsx-runtime").JSX.Element; +export type SettingsSidebarProps = { + /** Optional id */ + id?: string; + /** Extension labels to list in sidebar */ + extensionLabels: string[]; + /** Project labels to list in sidebar */ + handleSelectSidebarItem: (key: string, isProjectSetting: boolean) => void; +}; +export function SettingsSidebar({ id, extensionLabels, handleSelectSidebarItem, }: SettingsSidebarProps): import("react/jsx-runtime").JSX.Element; +export type SettingsSidebarContentSearchProps = { + /** Text direction ltr or rtl */ + direction?: "ltr" | "rtl"; + extensionLabels: string[]; + handleSelectSidebarItem: (key: string, isProjectSetting: boolean) => void; +} & React$1.PropsWithChildren; +export function SettingsSidebarContentSearch({ direction, extensionLabels, children, handleSelectSidebarItem, }: SettingsSidebarContentSearchProps): import("react/jsx-runtime").JSX.Element; /** * Information (e.g., a checking error or some other type of "transient" annotation) about something * noteworthy at a specific place in an instance of the Scriptures. @@ -622,6 +638,11 @@ export type SettingsListHeaderProps = { * @returns Formatted div with list header content */ export declare function SettingsListHeader({ primary, secondary, includeSeparator, }: SettingsListHeaderProps): import("react/jsx-runtime").JSX.Element; +export type SettingsCardProps = React$1.PropsWithChildren & { + settingsGroupLabel: string; + settingsGroupDescription: string; +}; +export function SettingsCard({ settingsGroupLabel, settingsGroupDescription, children, }: SettingsCardProps): import("react/jsx-runtime").JSX.Element; export type ChecklistProps = { /** Optional string representing the id attribute of the Checklist */ id?: string; @@ -1468,6 +1489,7 @@ export declare const usePromise: (promiseFactoryCallback: (() => Promise) export declare function cn(...inputs: ClassValue[]): string; export { + TabNavigationContentSearch as NavigationContentSearch, sonner, }; diff --git a/lib/platform-bible-react/dist/index.js b/lib/platform-bible-react/dist/index.js index f5c7e939d2..c901aa810b 100644 --- a/lib/platform-bible-react/dist/index.js +++ b/lib/platform-bible-react/dist/index.js @@ -1,72 +1,73 @@ -import Ri, { jsx as i, jsxs as x, Fragment as st } from "react/jsx-runtime"; +import Qs, { jsx as s, jsxs as x, Fragment as ie } from "react/jsx-runtime"; import * as M from "react"; -import I, { forwardRef as Kn, useCallback as Me, useState as ue, useRef as gt, useEffect as at, useLayoutEffect as Ho, useMemo as _e } from "react"; -import { History as Pi, ChevronRight as Fa, Check as Jn, Circle as Ua, ArrowDownWideNarrow as _i, Clock as $i, Bookmark as Ii, X as Ai, Search as Di, ChevronsUpDown as Mi, FilterIcon as Bi, ChevronDown as Zn, ChevronUp as ji, ArrowLeftIcon as Vi, ChevronLeftIcon as Li, ChevronRightIcon as zi, ArrowRightIcon as Fi, CircleCheckIcon as Ui, CircleXIcon as Gi, CircleHelpIcon as Hi, ArrowUpIcon as Xi, ArrowDownIcon as Yi, ArrowUpDownIcon as Wi, ChevronLeft as qi, LoaderCircle as Ki, Download as Ji, Filter as Zi, User as Qi, Link as el, CircleHelp as tl } from "lucide-react"; -import bt, { clsx as nl } from "clsx"; -import { extendTailwindMerge as rl } from "tailwind-merge"; -import * as we from "@radix-ui/react-dropdown-menu"; -import { DropdownMenuTrigger as ol } from "@radix-ui/react-dropdown-menu"; -import { getChaptersForBook as al, deepEqual as to, substring as sl, formatScrRef as Tr, compareScrRefs as zr, scrRefToBBBCCCVVV as Cr, getLocalizeKeyForScrollGroupId as pe, NumberFormat as il, formatBytes as ll } from "platform-bible-utils"; -import { Slot as cl } from "@radix-ui/react-slot"; -import { cva as Qn } from "class-variance-authority"; -import * as Ga from "@radix-ui/react-label"; -import * as un from "@radix-ui/react-radio-group"; -import * as wn from "@radix-ui/react-popover"; -import { Command as Se } from "cmdk"; -import * as Ye from "@radix-ui/react-dialog"; -import { useReactTable as Ha, getCoreRowModel as Xa, getPaginationRowModel as dl, getSortedRowModel as Ya, getFilteredRowModel as pl, flexRender as sn, getExpandedRowModel as ul, getGroupedRowModel as wl } from "@tanstack/react-table"; -import * as ge from "@radix-ui/react-select"; -import * as Fr from "@radix-ui/react-checkbox"; -import * as er from "@radix-ui/react-toggle-group"; -import * as Wa from "@radix-ui/react-toggle"; -import * as Oe from "@radix-ui/react-tabs"; -import * as qa from "@radix-ui/react-separator"; -import fl, { ThemeContext as ml, internal_processStyles as hl } from "@mui/styled-engine"; -import { MenuItem as gl, ListItemText as bl, ListItemIcon as Ka, Menu as vl, Grid as Ja, List as yl, IconButton as Za, Drawer as xl, AppBar as Nl, Toolbar as kl } from "@mui/material"; -import * as El from "react-dom"; -import An from "react-dom"; -import { Toaster as Tl } from "sonner"; -import { toast as th } from "sonner"; -import * as nn from "@radix-ui/react-slider"; -import * as Ur from "@radix-ui/react-switch"; -import Cl from "markdown-to-jsx"; -const Sl = rl({ prefix: "tw-" }); -function T(...e) { - return Sl(nl(e)); -} -const xn = I.forwardRef( - ({ className: e, type: t, ...n }, r) => /* @__PURE__ */ i( +import T, { forwardRef as Qn, useCallback as Bt, useState as ut, useRef as ge, useEffect as ae, useLayoutEffect as Ko, useMemo as $t } from "react"; +import { History as tl, ChevronRight as Wa, Check as tr, Circle as qa, ArrowDownWideNarrow as el, Clock as nl, Bookmark as rl, X as Ka, Search as ol, ChevronsUpDown as al, FilterIcon as il, ChevronDown as er, ChevronUp as sl, ArrowLeftIcon as ll, ChevronLeftIcon as cl, ChevronRightIcon as dl, ArrowRightIcon as pl, CircleCheckIcon as ul, CircleXIcon as wl, CircleHelpIcon as fl, ArrowUpIcon as ml, ArrowDownIcon as hl, ArrowUpDownIcon as gl, PanelLeft as bl, ChevronLeft as vl, LoaderCircle as yl, Download as xl, Filter as Nl, User as kl, Link as El, CircleHelp as Sl } from "lucide-react"; +import be, { clsx as Tl } from "clsx"; +import { extendTailwindMerge as Cl } from "tailwind-merge"; +import * as wt from "@radix-ui/react-dropdown-menu"; +import { DropdownMenuTrigger as Ol } from "@radix-ui/react-dropdown-menu"; +import { getChaptersForBook as Rl, deepEqual as ao, substring as _l, formatScrRef as Or, compareScrRefs as Hr, scrRefToBBBCCCVVV as Rr, getLocalizeKeyForScrollGroupId as pt, NumberFormat as Pl, formatBytes as $l } from "platform-bible-utils"; +import { Slot as He } from "@radix-ui/react-slot"; +import { cva as Xe } from "class-variance-authority"; +import * as Ja from "@radix-ui/react-label"; +import * as mn from "@radix-ui/react-radio-group"; +import * as hn from "@radix-ui/react-popover"; +import { Command as Ot } from "cmdk"; +import * as vt from "@radix-ui/react-dialog"; +import { useReactTable as Za, getCoreRowModel as Qa, getPaginationRowModel as Il, getSortedRowModel as ti, getFilteredRowModel as Al, flexRender as dn, getExpandedRowModel as Ml, getGroupedRowModel as Dl } from "@tanstack/react-table"; +import * as bt from "@radix-ui/react-select"; +import * as Xr from "@radix-ui/react-checkbox"; +import * as nr from "@radix-ui/react-toggle-group"; +import * as ei from "@radix-ui/react-toggle"; +import * as Rt from "@radix-ui/react-tabs"; +import * as ni from "@radix-ui/react-separator"; +import * as En from "@radix-ui/react-tooltip"; +import { CardContent as Bl, MenuItem as jl, ListItemText as Vl, ListItemIcon as ri, Menu as zl, Grid as oi, List as Ll, IconButton as ai, Drawer as Fl, AppBar as Ul, Toolbar as Gl } from "@mui/material"; +import Hl, { ThemeContext as Xl, internal_processStyles as Yl } from "@mui/styled-engine"; +import * as Wl from "react-dom"; +import Bn from "react-dom"; +import { Toaster as ql } from "sonner"; +import { toast as Qh } from "sonner"; +import * as an from "@radix-ui/react-slider"; +import * as Yr from "@radix-ui/react-switch"; +import Kl from "markdown-to-jsx"; +const Jl = Cl({ prefix: "tw-" }); +function N(...t) { + return Jl(Tl(t)); +} +const Ye = T.forwardRef( + ({ className: t, type: e, ...n }, r) => /* @__PURE__ */ s( "input", { - type: t, - className: T( + type: e, + className: N( "pr-twp tw-flex tw-h-10 tw-rounded-md tw-border tw-border-input tw-bg-background tw-px-3 tw-py-2 tw-text-sm tw-ring-offset-background file:tw-border-0 file:tw-bg-transparent file:tw-text-sm file:tw-font-medium file:tw-text-foreground placeholder:tw-text-muted-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-cursor-not-allowed disabled:tw-opacity-50", - e + t ), ref: r, ...n } ) ); -xn.displayName = "Input"; -const Ol = Kn( - ({ handleSearch: e, handleKeyDown: t, handleOnClick: n, handleSubmit: r, ...o }, a) => /* @__PURE__ */ x("div", { className: "tw-relative", children: [ - /* @__PURE__ */ i( - xn, +Ye.displayName = "Input"; +const Zl = Qn( + ({ handleSearch: t, handleKeyDown: e, handleOnClick: n, handleSubmit: r, ...o }, a) => /* @__PURE__ */ x("div", { className: "tw-relative", children: [ + /* @__PURE__ */ s( + Ye, { ...o, type: "text", className: "tw-box-border tw-gap-2.5 tw-rounded-lg tw-border tw-border-solid tw-bg-background tw-py-2 tw-pl-4 tw-pr-3 tw-font-medium tw-shadow-none tw-outline-none", - onChange: (s) => e(s.target.value), - onKeyDown: (s) => { - s.key === "Enter" && r(), t(s); + onChange: (i) => t(i.target.value), + onKeyDown: (i) => { + i.key === "Enter" && r(), e(i); }, onClick: n, ref: a } ), - /* @__PURE__ */ i( - Pi, + /* @__PURE__ */ s( + tl, { className: "tw-absolute tw-right-3 tw-top-1/2 tw-h-4 tw-w-4 tw--translate-y-1/2 tw-transform tw-cursor-pointer tw-text-muted-foreground", onClick: () => { @@ -76,8 +77,8 @@ const Ol = Kn( ) ] }) ); -var Rl = Object.defineProperty, Pl = (e, t, n) => t in e ? Rl(e, t, { enumerable: !0, configurable: !0, writable: !0, value: n }) : e[t] = n, te = (e, t, n) => Pl(e, typeof t != "symbol" ? t + "" : t, n); -const yt = [ +var Ql = Object.defineProperty, tc = (t, e, n) => e in t ? Ql(t, e, { enumerable: !0, configurable: !0, writable: !0, value: n }) : t[e] = n, et = (t, e, n) => tc(t, typeof e != "symbol" ? e + "" : e, n); +const ye = [ "GEN", "EXO", "LEV", @@ -222,7 +223,7 @@ const yt = [ "REP", "4BA", "LAO" -], no = [ +], io = [ "XXA", "XXB", "XXC", @@ -238,7 +239,7 @@ const yt = [ "GLO", "TDX", "NDX" -], Qa = [ +], ii = [ "Genesis", "Exodus", "Leviticus", @@ -364,134 +365,134 @@ const yt = [ "Reproof (Proverbs 25-31)", "4 Baruch (Rest of Baruch)", "Laodiceans" -], Xo = Ll(); -function Ht(e, t = !0) { - return t && (e = e.toUpperCase()), e in Xo ? Xo[e] : 0; +], Jo = dc(); +function We(t, e = !0) { + return e && (t = t.toUpperCase()), t in Jo ? Jo[t] : 0; } -function ro(e) { - return Ht(e) > 0; +function so(t) { + return We(t) > 0; } -function _l(e) { - const t = typeof e == "string" ? Ht(e) : e; - return t >= 40 && t <= 66; +function ec(t) { + const e = typeof t == "string" ? We(t) : t; + return e >= 40 && e <= 66; } -function $l(e) { - return (typeof e == "string" ? Ht(e) : e) <= 39; +function nc(t) { + return (typeof t == "string" ? We(t) : t) <= 39; } -function es(e) { - return e <= 66; +function si(t) { + return t <= 66; } -function Il(e) { - const t = typeof e == "string" ? Ht(e) : e; - return rs(t) && !es(t); +function rc(t) { + const e = typeof t == "string" ? We(t) : t; + return di(e) && !si(e); } -function* Al() { - for (let e = 1; e <= yt.length; e++) - yield e; +function* oc() { + for (let t = 1; t <= ye.length; t++) + yield t; } -const Dl = 1, ts = yt.length; -function Ml() { +const ac = 1, li = ye.length; +function ic() { return ["XXA", "XXB", "XXC", "XXD", "XXE", "XXF", "XXG"]; } -function oo(e, t = "***") { - const n = e - 1; - return n < 0 || n >= yt.length ? t : yt[n]; +function lo(t, e = "***") { + const n = t - 1; + return n < 0 || n >= ye.length ? e : ye[n]; } -function ns(e) { - return e <= 0 || e > ts ? "******" : Qa[e - 1]; +function ci(t) { + return t <= 0 || t > li ? "******" : ii[t - 1]; } -function Bl(e) { - return ns(Ht(e)); +function sc(t) { + return ci(We(t)); } -function rs(e) { - const t = typeof e == "number" ? oo(e) : e; - return ro(t) && !no.includes(t); +function di(t) { + const e = typeof t == "number" ? lo(t) : t; + return so(e) && !io.includes(e); } -function jl(e) { - const t = typeof e == "number" ? oo(e) : e; - return ro(t) && no.includes(t); +function lc(t) { + const e = typeof t == "number" ? lo(t) : t; + return so(e) && io.includes(e); } -function Vl(e) { - return Qa[e - 1].includes("*obsolete*"); +function cc(t) { + return ii[t - 1].includes("*obsolete*"); } -function Ll() { - const e = {}; - for (let t = 0; t < yt.length; t++) - e[yt[t]] = t + 1; - return e; +function dc() { + const t = {}; + for (let e = 0; e < ye.length; e++) + t[ye[e]] = e + 1; + return t; } -const oe = { - allBookIds: yt, - nonCanonicalIds: no, - bookIdToNumber: Ht, - isBookIdValid: ro, - isBookNT: _l, - isBookOT: $l, - isBookOTNT: es, - isBookDC: Il, - allBookNumbers: Al, - firstBook: Dl, - lastBook: ts, - extraBooks: Ml, - bookNumberToId: oo, - bookNumberToEnglishName: ns, - bookIdToEnglishName: Bl, - isCanonical: rs, - isExtraMaterial: jl, - isObsolete: Vl +const ot = { + allBookIds: ye, + nonCanonicalIds: io, + bookIdToNumber: We, + isBookIdValid: so, + isBookNT: ec, + isBookOT: nc, + isBookOTNT: si, + isBookDC: rc, + allBookNumbers: oc, + firstBook: ac, + lastBook: li, + extraBooks: ic, + bookNumberToId: lo, + bookNumberToEnglishName: ci, + bookIdToEnglishName: sc, + isCanonical: di, + isExtraMaterial: lc, + isObsolete: cc }; -var Ge = /* @__PURE__ */ ((e) => (e[e.Unknown = 0] = "Unknown", e[e.Original = 1] = "Original", e[e.Septuagint = 2] = "Septuagint", e[e.Vulgate = 3] = "Vulgate", e[e.English = 4] = "English", e[e.RussianProtestant = 5] = "RussianProtestant", e[e.RussianOrthodox = 6] = "RussianOrthodox", e))(Ge || {}); -const Pe = class { +var Ht = /* @__PURE__ */ ((t) => (t[t.Unknown = 0] = "Unknown", t[t.Original = 1] = "Original", t[t.Septuagint = 2] = "Septuagint", t[t.Vulgate = 3] = "Vulgate", t[t.English = 4] = "English", t[t.RussianProtestant = 5] = "RussianProtestant", t[t.RussianOrthodox = 6] = "RussianOrthodox", t))(Ht || {}); +const Pt = class { // private versInfo: Versification; - constructor(t) { - if (te(this, "name"), te(this, "fullPath"), te(this, "isPresent"), te(this, "hasVerseSegments"), te(this, "isCustomized"), te(this, "baseVersification"), te(this, "scriptureBooks"), te(this, "_type"), t == null) + constructor(e) { + if (et(this, "name"), et(this, "fullPath"), et(this, "isPresent"), et(this, "hasVerseSegments"), et(this, "isCustomized"), et(this, "baseVersification"), et(this, "scriptureBooks"), et(this, "_type"), e == null) throw new Error("Argument undefined"); - typeof t == "string" ? (this.name = t, this._type = Ge[t]) : (this._type = t, this.name = Ge[t]); + typeof e == "string" ? (this.name = e, this._type = Ht[e]) : (this._type = e, this.name = Ht[e]); } get type() { return this._type; } - equals(t) { - return !t.type || !this.type ? !1 : t.type === this.type; + equals(e) { + return !e.type || !this.type ? !1 : e.type === this.type; } }; -te(Pe, "Original", new Pe(Ge.Original)), te(Pe, "Septuagint", new Pe(Ge.Septuagint)), te(Pe, "Vulgate", new Pe(Ge.Vulgate)), te(Pe, "English", new Pe(Ge.English)), te(Pe, "RussianProtestant", new Pe(Ge.RussianProtestant)), te(Pe, "RussianOrthodox", new Pe(Ge.RussianOrthodox)); -let ut = Pe; -function Yo(e, t) { - const n = t[0]; - for (let r = 1; r < t.length; r++) - e = e.split(t[r]).join(n); - return e.split(n); -} -var os = /* @__PURE__ */ ((e) => (e[e.Valid = 0] = "Valid", e[e.UnknownVersification = 1] = "UnknownVersification", e[e.OutOfRange = 2] = "OutOfRange", e[e.VerseOutOfOrder = 3] = "VerseOutOfOrder", e[e.VerseRepeated = 4] = "VerseRepeated", e))(os || {}); -const Ee = class ne { - constructor(t, n, r, o) { - if (te(this, "firstChapter"), te(this, "lastChapter"), te(this, "lastVerse"), te(this, "hasSegmentsDefined"), te(this, "text"), te(this, "BBBCCCVVVS"), te(this, "longHashCode"), te(this, "versification"), te(this, "rtlMark", "‏"), te(this, "_bookNum", 0), te(this, "_chapterNum", 0), te(this, "_verseNum", 0), te(this, "_verse"), r == null && o == null) - if (t != null && typeof t == "string") { - const a = t, s = n != null && n instanceof ut ? n : void 0; - this.setEmpty(s), this.parse(a); - } else if (t != null && typeof t == "number") { - const a = n != null && n instanceof ut ? n : void 0; - this.setEmpty(a), this._verseNum = t % ne.chapterDigitShifter, this._chapterNum = Math.floor( - t % ne.bookDigitShifter / ne.chapterDigitShifter - ), this._bookNum = Math.floor(t / ne.bookDigitShifter); +et(Pt, "Original", new Pt(Ht.Original)), et(Pt, "Septuagint", new Pt(Ht.Septuagint)), et(Pt, "Vulgate", new Pt(Ht.Vulgate)), et(Pt, "English", new Pt(Ht.English)), et(Pt, "RussianProtestant", new Pt(Ht.RussianProtestant)), et(Pt, "RussianOrthodox", new Pt(Ht.RussianOrthodox)); +let ue = Pt; +function Zo(t, e) { + const n = e[0]; + for (let r = 1; r < e.length; r++) + t = t.split(e[r]).join(n); + return t.split(n); +} +var pi = /* @__PURE__ */ ((t) => (t[t.Valid = 0] = "Valid", t[t.UnknownVersification = 1] = "UnknownVersification", t[t.OutOfRange = 2] = "OutOfRange", t[t.VerseOutOfOrder = 3] = "VerseOutOfOrder", t[t.VerseRepeated = 4] = "VerseRepeated", t))(pi || {}); +const St = class nt { + constructor(e, n, r, o) { + if (et(this, "firstChapter"), et(this, "lastChapter"), et(this, "lastVerse"), et(this, "hasSegmentsDefined"), et(this, "text"), et(this, "BBBCCCVVVS"), et(this, "longHashCode"), et(this, "versification"), et(this, "rtlMark", "‏"), et(this, "_bookNum", 0), et(this, "_chapterNum", 0), et(this, "_verseNum", 0), et(this, "_verse"), r == null && o == null) + if (e != null && typeof e == "string") { + const a = e, i = n != null && n instanceof ue ? n : void 0; + this.setEmpty(i), this.parse(a); + } else if (e != null && typeof e == "number") { + const a = n != null && n instanceof ue ? n : void 0; + this.setEmpty(a), this._verseNum = e % nt.chapterDigitShifter, this._chapterNum = Math.floor( + e % nt.bookDigitShifter / nt.chapterDigitShifter + ), this._bookNum = Math.floor(e / nt.bookDigitShifter); } else if (n == null) - if (t != null && t instanceof ne) { - const a = t; + if (e != null && e instanceof nt) { + const a = e; this._bookNum = a.bookNum, this._chapterNum = a.chapterNum, this._verseNum = a.verseNum, this._verse = a.verse, this.versification = a.versification; } else { - if (t == null) + if (e == null) return; - const a = t instanceof ut ? t : ne.defaultVersification; + const a = e instanceof ue ? e : nt.defaultVersification; this.setEmpty(a); } else throw new Error("VerseRef constructor not supported."); - else if (t != null && n != null && r != null) - if (typeof t == "string" && typeof n == "string" && typeof r == "string") - this.setEmpty(o), this.updateInternal(t, n, r); - else if (typeof t == "number" && typeof n == "number" && typeof r == "number") - this._bookNum = t, this._chapterNum = n, this._verseNum = r, this.versification = o ?? ne.defaultVersification; + else if (e != null && n != null && r != null) + if (typeof e == "string" && typeof n == "string" && typeof r == "string") + this.setEmpty(o), this.updateInternal(e, n, r); + else if (typeof e == "number" && typeof n == "number" && typeof r == "number") + this._bookNum = e, this._chapterNum = n, this._verseNum = r, this.versification = o ?? nt.defaultVersification; else throw new Error("VerseRef constructor not supported."); else @@ -500,8 +501,8 @@ const Ee = class ne { /** * Determines if the verse string is in a valid format (does not consider versification). */ - static isVerseParseable(t) { - return t.length > 0 && "0123456789".includes(t[0]) && !t.endsWith(this.verseRangeSeparator) && !t.endsWith(this.verseSequenceIndicator); + static isVerseParseable(e) { + return e.length > 0 && "0123456789".includes(e[0]) && !e.endsWith(this.verseRangeSeparator) && !e.endsWith(this.verseSequenceIndicator); } /** * Tries to parse the specified string into a verse reference. @@ -509,13 +510,13 @@ const Ee = class ne { * @returns success: `true` if the specified string was successfully parsed, `false` otherwise. * @returns verseRef: The result of the parse if successful, or empty VerseRef if it failed */ - static tryParse(t) { + static tryParse(e) { let n; try { - return n = new ne(t), { success: !0, verseRef: n }; + return n = new nt(e), { success: !0, verseRef: n }; } catch (r) { - if (r instanceof Jt) - return n = new ne(), { success: !1, verseRef: n }; + if (r instanceof tn) + return n = new nt(), { success: !1, verseRef: n }; throw r; } } @@ -528,18 +529,18 @@ const Ee = class ne { * @returns The reference as a comparable integer where the book, chapter, and verse each occupy 3 * digits. */ - static getBBBCCCVVV(t, n, r) { - return t % ne.bcvMaxValue * ne.bookDigitShifter + (n >= 0 ? n % ne.bcvMaxValue * ne.chapterDigitShifter : 0) + (r >= 0 ? r % ne.bcvMaxValue : 0); + static getBBBCCCVVV(e, n, r) { + return e % nt.bcvMaxValue * nt.bookDigitShifter + (n >= 0 ? n % nt.bcvMaxValue * nt.chapterDigitShifter : 0) + (r >= 0 ? r % nt.bcvMaxValue : 0); } /** * Deserializes a serialized VerseRef. * @param serializedVerseRef - Serialized VerseRef to create from. * @returns the deserialized VerseRef. */ - static fromJSON(t) { - const { book: n, chapterNum: r, verseNum: o, verse: a, versificationStr: s } = t, l = a || o.toString(); + static fromJSON(e) { + const { book: n, chapterNum: r, verseNum: o, verse: a, versificationStr: i } = e, l = a || o.toString(); let c; - return s && (c = new ut(s)), n ? new ne(n, r.toString(), l, c) : new ne(); + return i && (c = new ue(i)), n ? new nt(n, r.toString(), l, c) : new nt(); } /** * Parses a verse string and gets the leading numeric portion as a number. @@ -547,16 +548,16 @@ const Ee = class ne { * @returns true if the entire string could be parsed as a single, simple verse number (1-999); * false if the verse string represented a verse bridge, contained segment letters, or was invalid */ - static tryGetVerseNum(t) { + static tryGetVerseNum(e) { let n; - if (!t) + if (!e) return n = -1, { success: !0, vNum: n }; n = 0; let r; - for (let o = 0; o < t.length; o++) { - if (r = t[o], r < "0" || r > "9") + for (let o = 0; o < e.length; o++) { + if (r = e[o], r < "0" || r > "9") return o === 0 && (n = -1), { success: !1, vNum: n }; - if (n = n * 10 + +r - 0, n > ne.bcvMaxValue) + if (n = n * 10 + +r - 0, n > nt.bcvMaxValue) return n = -1, { success: !1, vNum: n }; } return { success: !0, vNum: n }; @@ -571,17 +572,17 @@ const Ee = class ne { * Gets whether the verse contains multiple verses. */ get hasMultiple() { - return this._verse != null && (this._verse.includes(ne.verseRangeSeparator) || this._verse.includes(ne.verseSequenceIndicator)); + return this._verse != null && (this._verse.includes(nt.verseRangeSeparator) || this._verse.includes(nt.verseSequenceIndicator)); } /** * Gets or sets the book of the reference. Book is the 3-letter abbreviation in capital letters, * e.g. `'MAT'`. */ get book() { - return oe.bookNumberToId(this.bookNum, ""); + return ot.bookNumberToId(this.bookNum, ""); } - set book(t) { - this.bookNum = oe.bookIdToNumber(t); + set book(e) { + this.bookNum = ot.bookIdToNumber(e); } /** * Gets or sets the chapter of the reference,. e.g. `'3'`. @@ -589,8 +590,8 @@ const Ee = class ne { get chapter() { return this.isDefault || this._chapterNum < 0 ? "" : this._chapterNum.toString(); } - set chapter(t) { - const n = +t; + set chapter(e) { + const n = +e; this._chapterNum = Number.isInteger(n) ? n : -1; } /** @@ -600,9 +601,9 @@ const Ee = class ne { get verse() { return this._verse != null ? this._verse : this.isDefault || this._verseNum < 0 ? "" : this._verseNum.toString(); } - set verse(t) { - const { success: n, vNum: r } = ne.tryGetVerseNum(t); - this._verse = n ? void 0 : t.replace(this.rtlMark, ""), this._verseNum = r, !(this._verseNum >= 0) && ({ vNum: this._verseNum } = ne.tryGetVerseNum(this._verse)); + set verse(e) { + const { success: n, vNum: r } = nt.tryGetVerseNum(e); + this._verse = n ? void 0 : e.replace(this.rtlMark, ""), this._verseNum = r, !(this._verseNum >= 0) && ({ vNum: this._verseNum } = nt.tryGetVerseNum(this._verse)); } /** * Get or set Book based on book number, e.g. `42`. @@ -610,12 +611,12 @@ const Ee = class ne { get bookNum() { return this._bookNum; } - set bookNum(t) { - if (t <= 0 || t > oe.lastBook) - throw new Jt( + set bookNum(e) { + if (e <= 0 || e > ot.lastBook) + throw new tn( "BookNum must be greater than zero and less than or equal to last book" ); - this._bookNum = t; + this._bookNum = e; } /** * Gets or sets the chapter number, e.g. `3`. `-1` if not valid. @@ -623,8 +624,8 @@ const Ee = class ne { get chapterNum() { return this._chapterNum; } - set chapterNum(t) { - this.chapterNum = t; + set chapterNum(e) { + this.chapterNum = e; } /** * Gets or sets verse start number, e.g. `4`. `-1` if not valid. @@ -632,8 +633,8 @@ const Ee = class ne { get verseNum() { return this._verseNum; } - set verseNum(t) { - this._verseNum = t; + set verseNum(e) { + this._verseNum = e; } /** * String representing the versification (should ONLY be used for serialization/deserialization). @@ -641,11 +642,11 @@ const Ee = class ne { * @remarks This is for backwards compatibility when ScrVers was an enumeration. */ get versificationStr() { - var t; - return (t = this.versification) == null ? void 0 : t.name; + var e; + return (e = this.versification) == null ? void 0 : e.name; } - set versificationStr(t) { - this.versification = this.versification != null ? new ut(t) : void 0; + set versificationStr(e) { + this.versification = this.versification != null ? new ue(e) : void 0; } /** * Determines if the reference is valid. @@ -657,14 +658,14 @@ const Ee = class ne { * Get the valid status for this reference. */ get validStatus() { - return this.validateVerse(ne.verseRangeSeparators, ne.verseSequenceIndicators); + return this.validateVerse(nt.verseRangeSeparators, nt.verseSequenceIndicators); } /** * Gets the reference as a comparable integer where the book, * chapter, and verse each occupy three digits and the verse is 0. */ get BBBCCC() { - return ne.getBBBCCCVVV(this._bookNum, this._chapterNum, 0); + return nt.getBBBCCCVVV(this._bookNum, this._chapterNum, 0); } /** * Gets the reference as a comparable integer where the book, @@ -673,7 +674,7 @@ const Ee = class ne { * segments or bridge) this cannot be used for an exact comparison. */ get BBBCCCVVV() { - return ne.getBBBCCCVVV(this._bookNum, this._chapterNum, this._verseNum); + return nt.getBBBCCCVVV(this._bookNum, this._chapterNum, this._verseNum); } /** * Gets whether the verse is defined as an excluded verse in the versification. @@ -693,23 +694,23 @@ const Ee = class ne { * - versification is invalid * @param verseStr - string to parse e.g. 'MAT 3:11' */ - parse(t) { - if (t = t.replace(this.rtlMark, ""), t.includes("/")) { - const a = t.split("/"); - if (t = a[0], a.length > 1) + parse(e) { + if (e = e.replace(this.rtlMark, ""), e.includes("/")) { + const a = e.split("/"); + if (e = a[0], a.length > 1) try { - const s = +a[1].trim(); - this.versification = new ut(Ge[s]); + const i = +a[1].trim(); + this.versification = new ue(Ht[i]); } catch { - throw new Jt("Invalid reference : " + t); + throw new tn("Invalid reference : " + e); } } - const n = t.trim().split(" "); + const n = e.trim().split(" "); if (n.length !== 2) - throw new Jt("Invalid reference : " + t); + throw new tn("Invalid reference : " + e); const r = n[1].split(":"), o = +r[0]; - if (r.length !== 2 || oe.bookIdToNumber(n[0]) === 0 || !Number.isInteger(o) || o < 0 || !ne.isVerseParseable(r[1])) - throw new Jt("Invalid reference : " + t); + if (r.length !== 2 || ot.bookIdToNumber(n[0]) === 0 || !Number.isInteger(o) || o < 0 || !nt.isVerseParseable(r[1])) + throw new tn("Invalid reference : " + e); this.updateInternal(n[0], r[0], r[1]); } /** @@ -725,31 +726,31 @@ const Ee = class ne { * @returns The cloned VerseRef. */ clone() { - return new ne(this); + return new nt(this); } toString() { - const t = this.book; - return t === "" ? "" : `${t} ${this.chapter}:${this.verse}`; + const e = this.book; + return e === "" ? "" : `${e} ${this.chapter}:${this.verse}`; } toJSON() { - let t = this.verse; - (t === "" || t === this.verseNum.toString()) && (t = void 0); + let e = this.verse; + (e === "" || e === this.verseNum.toString()) && (e = void 0); const n = { book: this.book, chapterNum: this.chapterNum, verseNum: this.verseNum, - verse: t, + verse: e, versificationStr: this.versificationStr }; - return t || delete n.verse, n; + return e || delete n.verse, n; } /** * Compares this `VerseRef` with supplied one. * @param verseRef - object to compare this one to. * @returns `true` if this `VerseRef` is equal to the supplied one, `false` otherwise. */ - equals(t) { - return t instanceof ne ? t._bookNum === this._bookNum && t._chapterNum === this._chapterNum && t._verseNum === this._verseNum && t.verse === this.verse && (t.versification == null && this.versification == null || t.versification != null && this.versification != null && t.versification.equals(this.versification)) : !1; + equals(e) { + return e instanceof nt ? e._bookNum === this._bookNum && e._chapterNum === this._chapterNum && e._verseNum === this._verseNum && e.verse === this.verse && (e.versification == null && this.versification == null || e.versification != null && this.versification != null && e.versification.equals(this.versification)) : !1; } /** * Enumerate all individual verses contained in a VerseRef. @@ -767,19 +768,19 @@ const Ee = class ne { * Defaults to `VerseRef.verseSequenceIndicators`. * @returns An array of all single verse references in this VerseRef. */ - allVerses(t = !1, n = ne.verseRangeSeparators, r = ne.verseSequenceIndicators) { + allVerses(e = !1, n = nt.verseRangeSeparators, r = nt.verseSequenceIndicators) { if (this._verse == null || this.chapterNum <= 0) return [this.clone()]; - const o = [], a = Yo(this._verse, r); - for (const s of a.map((l) => Yo(l, n))) { + const o = [], a = Zo(this._verse, r); + for (const i of a.map((l) => Zo(l, n))) { const l = this.clone(); - l.verse = s[0]; + l.verse = i[0]; const c = l.verseNum; - if (o.push(l), s.length > 1) { + if (o.push(l), i.length > 1) { const d = this.clone(); - if (d.verse = s[1], !t) + if (d.verse = i[1], !e) for (let p = c + 1; p < d.verseNum; p++) { - const m = new ne( + const m = new nt( this._bookNum, this._chapterNum, p, @@ -795,20 +796,20 @@ const Ee = class ne { /** * Validates a verse number using the supplied separators rather than the defaults. */ - validateVerse(t, n) { + validateVerse(e, n) { if (!this.verse) return this.internalValid; let r = 0; - for (const o of this.allVerses(!0, t, n)) { + for (const o of this.allVerses(!0, e, n)) { const a = o.internalValid; if (a !== 0) return a; - const s = o.BBBCCCVVV; - if (r > s) + const i = o.BBBCCCVVV; + if (r > i) return 3; - if (r === s) + if (r === i) return 4; - r = s; + r = i; } return 0; } @@ -816,159 +817,159 @@ const Ee = class ne { * Gets whether a single verse reference is valid. */ get internalValid() { - return this.versification == null ? 1 : this._bookNum <= 0 || this._bookNum > oe.lastBook ? 2 : (oe.isCanonical(this._bookNum), 0); + return this.versification == null ? 1 : this._bookNum <= 0 || this._bookNum > ot.lastBook ? 2 : (ot.isCanonical(this._bookNum), 0); } - setEmpty(t = ne.defaultVersification) { - this._bookNum = 0, this._chapterNum = -1, this._verse = void 0, this.versification = t; + setEmpty(e = nt.defaultVersification) { + this._bookNum = 0, this._chapterNum = -1, this._verse = void 0, this.versification = e; } - updateInternal(t, n, r) { - this.bookNum = oe.bookIdToNumber(t), this.chapter = n, this.verse = r; + updateInternal(e, n, r) { + this.bookNum = ot.bookIdToNumber(e), this.chapter = n, this.verse = r; } }; -te(Ee, "defaultVersification", ut.English), te(Ee, "verseRangeSeparator", "-"), te(Ee, "verseSequenceIndicator", ","), te(Ee, "verseRangeSeparators", [Ee.verseRangeSeparator]), te(Ee, "verseSequenceIndicators", [Ee.verseSequenceIndicator]), te(Ee, "chapterDigitShifter", 1e3), te(Ee, "bookDigitShifter", Ee.chapterDigitShifter * Ee.chapterDigitShifter), te(Ee, "bcvMaxValue", Ee.chapterDigitShifter - 1), /** +et(St, "defaultVersification", ue.English), et(St, "verseRangeSeparator", "-"), et(St, "verseSequenceIndicator", ","), et(St, "verseRangeSeparators", [St.verseRangeSeparator]), et(St, "verseSequenceIndicators", [St.verseSequenceIndicator]), et(St, "chapterDigitShifter", 1e3), et(St, "bookDigitShifter", St.chapterDigitShifter * St.chapterDigitShifter), et(St, "bcvMaxValue", St.chapterDigitShifter - 1), /** * The valid status of the VerseRef. */ -te(Ee, "ValidStatusType", os); -class Jt extends Error { +et(St, "ValidStatusType", pi); +class tn extends Error { } -const ao = we.Root, as = we.Trigger, zl = we.Group, vm = we.Portal, ym = we.Sub, xm = we.RadioGroup, Fl = I.forwardRef(({ className: e, inset: t, children: n, ...r }, o) => /* @__PURE__ */ x( - we.SubTrigger, +const co = wt.Root, ui = wt.Trigger, pc = wt.Group, mh = wt.Portal, hh = wt.Sub, gh = wt.RadioGroup, uc = T.forwardRef(({ className: t, inset: e, children: n, ...r }, o) => /* @__PURE__ */ x( + wt.SubTrigger, { ref: o, - className: T( + className: N( "tw-flex tw-cursor-default tw-select-none tw-items-center tw-rounded-sm tw-px-2 tw-py-1.5 tw-text-sm tw-outline-none focus:tw-bg-accent data-[state=open]:tw-bg-accent", - t && "tw-pl-8", - e + e && "tw-pl-8", + t ), ...r, children: [ n, - /* @__PURE__ */ i(Fa, { className: "tw-ml-auto tw-h-4 tw-w-4" }) + /* @__PURE__ */ s(Wa, { className: "tw-ml-auto tw-h-4 tw-w-4" }) ] } )); -Fl.displayName = we.SubTrigger.displayName; -const Ul = I.forwardRef(({ className: e, ...t }, n) => /* @__PURE__ */ i( - we.SubContent, +uc.displayName = wt.SubTrigger.displayName; +const wc = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( + wt.SubContent, { ref: n, - className: T( + className: N( "tw-z-50 tw-min-w-[8rem] tw-overflow-hidden tw-rounded-md tw-border tw-bg-popover tw-p-1 tw-text-popover-foreground tw-shadow-lg data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0 data-[state=closed]:tw-zoom-out-95 data-[state=open]:tw-zoom-in-95 data-[side=bottom]:tw-slide-in-from-top-2 data-[side=left]:tw-slide-in-from-right-2 data-[side=right]:tw-slide-in-from-left-2 data-[side=top]:tw-slide-in-from-bottom-2", - e + t ), - ...t + ...e } )); -Ul.displayName = we.SubContent.displayName; -const tr = I.forwardRef(({ className: e, sideOffset: t = 4, ...n }, r) => /* @__PURE__ */ i(we.Portal, { children: /* @__PURE__ */ i( - we.Content, +wc.displayName = wt.SubContent.displayName; +const rr = T.forwardRef(({ className: t, sideOffset: e = 4, ...n }, r) => /* @__PURE__ */ s(wt.Portal, { children: /* @__PURE__ */ s( + wt.Content, { ref: r, - sideOffset: t, - className: T( + sideOffset: e, + className: N( /* adding pr-twp because the dropdown content is added to the dom as a sibling to the app root */ "pr-twp tw-z-50 tw-min-w-[8rem] tw-overflow-hidden tw-rounded-md tw-border tw-bg-popover tw-p-1 tw-text-popover-foreground tw-shadow-md data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0 data-[state=closed]:tw-zoom-out-95 data-[state=open]:tw-zoom-in-95 data-[side=bottom]:tw-slide-in-from-top-2 data-[side=left]:tw-slide-in-from-right-2 data-[side=right]:tw-slide-in-from-left-2 data-[side=top]:tw-slide-in-from-bottom-2", - e + t ), ...n } ) })); -tr.displayName = we.Content.displayName; -const ss = I.forwardRef(({ className: e, inset: t, ...n }, r) => /* @__PURE__ */ i( - we.Item, +rr.displayName = wt.Content.displayName; +const wi = T.forwardRef(({ className: t, inset: e, ...n }, r) => /* @__PURE__ */ s( + wt.Item, { ref: r, - className: T( + className: N( // removed: tw-relative tw-flex focus:tw-text-accent-foreground "tw-cursor-default tw-select-none tw-items-center tw-rounded-sm tw-px-2 tw-py-1.5 tw-text-sm tw-outline-none tw-transition-colors focus:tw-bg-accent data-[disabled]:tw-pointer-events-none data-[disabled]:tw-opacity-50", - t && "tw-pl-8", - e + e && "tw-pl-8", + t ), ...n } )); -ss.displayName = we.Item.displayName; -const so = I.forwardRef(({ className: e, children: t, checked: n, ...r }, o) => /* @__PURE__ */ x( - we.CheckboxItem, +wi.displayName = wt.Item.displayName; +const po = T.forwardRef(({ className: t, children: e, checked: n, ...r }, o) => /* @__PURE__ */ x( + wt.CheckboxItem, { ref: o, - className: T( + className: N( "tw-relative tw-flex tw-cursor-default tw-select-none tw-items-center tw-rounded-sm tw-py-1.5 tw-pl-8 tw-pr-2 tw-text-sm tw-outline-none tw-transition-colors focus:tw-bg-accent focus:tw-text-accent-foreground data-[disabled]:tw-pointer-events-none data-[disabled]:tw-opacity-50", - e + t ), checked: n, ...r, children: [ - /* @__PURE__ */ i("span", { className: "tw-absolute tw-left-2 tw-flex tw-h-3.5 tw-w-3.5 tw-items-center tw-justify-center", children: /* @__PURE__ */ i(we.ItemIndicator, { children: /* @__PURE__ */ i(Jn, { className: "tw-h-4 tw-w-4" }) }) }), - t + /* @__PURE__ */ s("span", { className: "tw-absolute tw-left-2 tw-flex tw-h-3.5 tw-w-3.5 tw-items-center tw-justify-center", children: /* @__PURE__ */ s(wt.ItemIndicator, { children: /* @__PURE__ */ s(tr, { className: "tw-h-4 tw-w-4" }) }) }), + e ] } )); -so.displayName = we.CheckboxItem.displayName; -const is = I.forwardRef(({ className: e, children: t, ...n }, r) => /* @__PURE__ */ x( - we.RadioItem, +po.displayName = wt.CheckboxItem.displayName; +const fi = T.forwardRef(({ className: t, children: e, ...n }, r) => /* @__PURE__ */ x( + wt.RadioItem, { ref: r, - className: T( + className: N( "tw-relative tw-flex tw-cursor-default tw-select-none tw-items-center tw-rounded-sm tw-py-1.5 tw-pl-8 tw-pr-2 tw-text-sm tw-outline-none tw-transition-colors focus:tw-bg-accent focus:tw-text-accent-foreground data-[disabled]:tw-pointer-events-none data-[disabled]:tw-opacity-50", - e + t ), ...n, children: [ - /* @__PURE__ */ i("span", { className: "tw-absolute tw-left-2 tw-flex tw-h-3.5 tw-w-3.5 tw-items-center tw-justify-center", children: /* @__PURE__ */ i(we.ItemIndicator, { children: /* @__PURE__ */ i(Ua, { className: "tw-h-2 tw-w-2 tw-fill-current" }) }) }), - t + /* @__PURE__ */ s("span", { className: "tw-absolute tw-left-2 tw-flex tw-h-3.5 tw-w-3.5 tw-items-center tw-justify-center", children: /* @__PURE__ */ s(wt.ItemIndicator, { children: /* @__PURE__ */ s(qa, { className: "tw-h-2 tw-w-2 tw-fill-current" }) }) }), + e ] } )); -is.displayName = we.RadioItem.displayName; -const Nn = I.forwardRef(({ className: e, inset: t, ...n }, r) => /* @__PURE__ */ i( - we.Label, +fi.displayName = wt.RadioItem.displayName; +const Sn = T.forwardRef(({ className: t, inset: e, ...n }, r) => /* @__PURE__ */ s( + wt.Label, { ref: r, - className: T("tw-px-2 tw-py-1.5 tw-text-sm tw-font-semibold", t && "tw-pl-8", e), + className: N("tw-px-2 tw-py-1.5 tw-text-sm tw-font-semibold", e && "tw-pl-8", t), ...n } )); -Nn.displayName = we.Label.displayName; -const nr = I.forwardRef(({ className: e, ...t }, n) => /* @__PURE__ */ i( - we.Separator, +Sn.displayName = wt.Label.displayName; +const or = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( + wt.Separator, { ref: n, - className: T("tw--mx-1 tw-my-1 tw-h-px tw-bg-muted", e), - ...t + className: N("tw--mx-1 tw-my-1 tw-h-px tw-bg-muted", t), + ...e } )); -nr.displayName = we.Separator.displayName; -function Gl({ className: e, ...t }) { - return /* @__PURE__ */ i( +or.displayName = wt.Separator.displayName; +function fc({ className: t, ...e }) { + return /* @__PURE__ */ s( "span", { - className: T("tw-ml-auto tw-text-xs tw-tracking-widest tw-opacity-60", e), - ...t + className: N("tw-ml-auto tw-text-xs tw-tracking-widest tw-opacity-60", t), + ...e } ); } -Gl.displayName = "DropdownMenuShortcut"; -const Hl = Kn( +fc.displayName = "DropdownMenuShortcut"; +const mc = Qn( ({ - bookId: e, - handleSelectBook: t, + bookId: t, + handleSelectBook: e, isSelected: n, handleHighlightBook: r, handleKeyDown: o, bookType: a, - children: s + children: i }, l) => /* @__PURE__ */ x( - ss, + wi, { ref: l, - textValue: e, - className: T("tw-mx-1 tw-px-1 tw-font-normal tw-text-foreground/80", { + textValue: t, + className: N("tw-mx-1 tw-px-1 tw-font-normal tw-text-foreground/80", { // Overriding `data-[highlighted]` changes the default gray background that is normally shown on hover "tw-bg-amber-50 tw-text-yellow-900 data-[highlighted]:tw-bg-amber-100": n }), onSelect: (c) => { - c.preventDefault(), t(); + c.preventDefault(), e(); }, onKeyDown: (c) => { o(c); @@ -976,10 +977,10 @@ const Hl = Kn( onFocus: r, onMouseMove: r, children: [ - /* @__PURE__ */ i( + /* @__PURE__ */ s( "span", { - className: T( + className: N( "tw-border-b-0 tw-border-l-2 tw-border-r-0 tw-border-t-0 tw-border-solid tw-px-2", { "tw-font-bold": n, @@ -988,32 +989,32 @@ const Hl = Kn( "tw-border-l-indigo-200": a.toLowerCase() === "dc" } ), - children: oe.bookIdToEnglishName(e) + children: ot.bookIdToEnglishName(t) } ), - n && /* @__PURE__ */ i("div", { children: s }) + n && /* @__PURE__ */ s("div", { children: i }) ] }, - e + t ) ); -function Xl({ - handleSelectChapter: e, - endChapter: t, +function hc({ + handleSelectChapter: t, + endChapter: e, activeChapter: n, highlightedChapter: r, handleHighlightedChapter: o }) { - const a = Array.from({ length: t }, (l, c) => c + 1), s = Me( + const a = Array.from({ length: e }, (l, c) => c + 1), i = Bt( (l) => { o(l); }, [o] ); - return /* @__PURE__ */ i("div", { className: T("tw-flex tw-flex-wrap tw-items-start tw-justify-start tw-self-stretch"), children: a.map((l) => /* @__PURE__ */ i( + return /* @__PURE__ */ s("div", { className: N("tw-flex tw-flex-wrap tw-items-start tw-justify-start tw-self-stretch"), children: a.map((l) => /* @__PURE__ */ s( "div", { - className: T( + className: N( "tw-box-content tw-flex tw-h-4 tw-w-4 tw-cursor-pointer tw-items-center tw-justify-end tw-rounded-md tw-p-2 tw-text-amber-800", { "tw-font-semibold tw-text-amber-900": l === n, @@ -1021,39 +1022,39 @@ function Xl({ } ), onClick: (c) => { - c.preventDefault(), c.stopPropagation(), e(l); + c.preventDefault(), c.stopPropagation(), t(l); }, role: "button", onKeyDown: (c) => { - c.key === "Enter" && e(l); + c.key === "Enter" && t(l); }, tabIndex: 0, - onMouseMove: () => s(l), + onMouseMove: () => i(l), children: l }, l )) }); } -function Yl({ handleSort: e, handleLocationHistory: t, handleBookmarks: n }) { - return /* @__PURE__ */ x(Nn, { className: "tw-flex tw-justify-between", children: [ - /* @__PURE__ */ i("p", { className: "tw-inline-block tw-align-middle", children: "Go To" }), +function gc({ handleSort: t, handleLocationHistory: e, handleBookmarks: n }) { + return /* @__PURE__ */ x(Sn, { className: "tw-flex tw-justify-between", children: [ + /* @__PURE__ */ s("p", { className: "tw-inline-block tw-align-middle", children: "Go To" }), /* @__PURE__ */ x("div", { className: "tw-flex tw-items-center", children: [ - /* @__PURE__ */ i( - _i, + /* @__PURE__ */ s( + el, { - onClick: e, + onClick: t, className: "tw-m-2 tw-h-4 tw-w-4 tw-cursor-pointer tw-gap-2" } ), - /* @__PURE__ */ i( - $i, + /* @__PURE__ */ s( + nl, { - onClick: t, + onClick: e, className: "tw-m-2 tw-h-4 tw-w-4 tw-cursor-pointer tw-gap-2" } ), - /* @__PURE__ */ i( - Ii, + /* @__PURE__ */ s( + rl, { onClick: n, className: "tw-m-2 tw-h-4 tw-w-4 tw-cursor-pointer tw-gap-2" @@ -1062,76 +1063,76 @@ function Yl({ handleSort: e, handleLocationHistory: t, handleBookmarks: n }) { ] }) ] }); } -const ln = oe.allBookIds, Wl = { +const pn = ot.allBookIds, bc = { OT: "Old Testament", NT: "New Testament", DC: "Deuterocanon" -}, Wo = ["OT", "NT", "DC"], ql = 32 + 32 + 32, Kl = [ +}, Qo = ["OT", "NT", "DC"], vc = 32 + 32 + 32, yc = [ /^(\w+)$/i, // Matches a single word (book name or id) /^(\w+)(?:\s(\d+))$/i, // Matches a word followed by a chapter number /^(\w+)(?:\s(\d+):(\d+))$/i // Matches a word followed by a chapter and verse number -], Jl = (e) => ({ - OT: ln.filter((n) => oe.isBookOT(n)), - NT: ln.filter((n) => oe.isBookNT(n)), - DC: ln.filter((n) => oe.isBookDC(n)) -})[e], Zt = (e) => al(oe.bookIdToNumber(e)); -function Zl() { - return ln.map((t) => oe.bookIdToEnglishName(t)); -} -function Ql(e) { - return Zl().includes(e); -} -function ec(e) { - const t = e.toLowerCase().replace(/^\w/, (n) => n.toUpperCase()); - if (Ql(t)) - return ln.find((r) => oe.bookIdToEnglishName(r) === t); -} -function Nm({ scrRef: e, handleSubmit: t }) { - const [n, r] = ue(""), [o, a] = ue( - oe.bookNumberToId(e.bookNum) - ), [s, l] = ue(e.chapterNum ?? 0), [c, d] = ue( - oe.bookNumberToId(e.bookNum) - ), [p, m] = ue(!1), [w, b] = ue(p), v = gt(void 0), f = gt(void 0), h = gt(void 0), E = Me( - (N) => Jl(N).filter((B) => { - const D = oe.bookIdToEnglishName(B).toLowerCase(), J = n.replace(/[^a-zA-Z]/g, "").toLowerCase(); +], xc = (t) => ({ + OT: pn.filter((n) => ot.isBookOT(n)), + NT: pn.filter((n) => ot.isBookNT(n)), + DC: pn.filter((n) => ot.isBookDC(n)) +})[t], en = (t) => Rl(ot.bookIdToNumber(t)); +function Nc() { + return pn.map((e) => ot.bookIdToEnglishName(e)); +} +function kc(t) { + return Nc().includes(t); +} +function Ec(t) { + const e = t.toLowerCase().replace(/^\w/, (n) => n.toUpperCase()); + if (kc(e)) + return pn.find((r) => ot.bookIdToEnglishName(r) === e); +} +function bh({ scrRef: t, handleSubmit: e }) { + const [n, r] = ut(""), [o, a] = ut( + ot.bookNumberToId(t.bookNum) + ), [i, l] = ut(t.chapterNum ?? 0), [c, d] = ut( + ot.bookNumberToId(t.bookNum) + ), [p, m] = ut(!1), [w, g] = ut(p), v = ge(void 0), f = ge(void 0), h = ge(void 0), E = Bt( + (k) => xc(k).filter((B) => { + const D = ot.bookIdToEnglishName(B).toLowerCase(), J = n.replace(/[^a-zA-Z]/g, "").toLowerCase(); return D.includes(J) || // Match book name B.toLowerCase().includes(J); }), [n] - ), A = (N) => { - r(N); - }, O = gt(!1), k = Me((N) => { - if (O.current) { - O.current = !1; + ), _ = (k) => { + r(k); + }, C = ge(!1), S = Bt((k) => { + if (C.current) { + C.current = !1; return; } - m(N); - }, []), g = Me( - (N, B, D, J) => { + m(k); + }, []), b = Bt( + (k, B, D, J) => { if (l( - oe.bookNumberToId(e.bookNum) !== N ? 1 : e.chapterNum - ), B || Zt(N) === -1) { - t({ - bookNum: oe.bookIdToNumber(N), + ot.bookNumberToId(t.bookNum) !== k ? 1 : t.chapterNum + ), B || en(k) === -1) { + e({ + bookNum: ot.bookIdToNumber(k), chapterNum: D || 1, verseNum: J || 1 }), m(!1), r(""); return; } - a(o !== N ? N : ""), m(!B); + a(o !== k ? k : ""), m(!B); }, - [t, e.bookNum, e.chapterNum, o] - ), _ = (N) => { - N <= 0 || N > Zt(o) || g(o, !0, N); - }, L = Me(() => { - Kl.forEach((N) => { - const B = n.match(N); + [e, t.bookNum, t.chapterNum, o] + ), I = (k) => { + k <= 0 || k > en(o) || b(o, !0, k); + }, z = Bt(() => { + yc.forEach((k) => { + const B = n.match(k); if (B) { - const [D, J = void 0, q = void 0] = B.slice(1), U = ec(D); - (oe.isBookIdValid(D) || U) && g( + const [D, J = void 0, q = void 0] = B.slice(1), U = Ec(D); + (ot.isBookIdValid(D) || U) && b( U ?? D, !0, J ? parseInt(J, 10) : 1, @@ -1139,116 +1140,116 @@ function Nm({ scrRef: e, handleSubmit: t }) { ); } }); - }, [g, n]), H = Me( - (N) => { - p ? (N.key === "ArrowDown" || N.key === "ArrowUp") && (typeof h < "u" && // Ref uses null + }, [b, n]), H = Bt( + (k) => { + p ? (k.key === "ArrowDown" || k.key === "ArrowUp") && (typeof h < "u" && // Ref uses null // eslint-disable-next-line no-null/no-null h.current !== null ? h.current.focus() : typeof f < "u" && // Ref uses null // eslint-disable-next-line no-null/no-null - f.current !== null && f.current.focus(), N.preventDefault()) : m(!0); + f.current !== null && f.current.focus(), k.preventDefault()) : m(!0); }, [p] - ), C = (N) => { - const { key: B } = N; + ), O = (k) => { + const { key: B } = k; B === "ArrowRight" || B === "ArrowLeft" || B === "ArrowDown" || B === "ArrowUp" || B === "Enter" || (v.current.dispatchEvent(new KeyboardEvent("keydown", { key: B })), v.current.focus()); - }, P = (N) => { - const { key: B } = N; + }, $ = (k) => { + const { key: B } = k; if (c === o) { if (B === "Enter") { - N.preventDefault(), g(o, !0, s); + k.preventDefault(), b(o, !0, i); return; } let D = 0; if (B === "ArrowRight") - if (s < Zt(c)) + if (i < en(c)) D = 1; else { - N.preventDefault(); + k.preventDefault(); return; } else if (B === "ArrowLeft") - if (s > 1) + if (i > 1) D = -1; else { - N.preventDefault(); + k.preventDefault(); return; } else B === "ArrowDown" ? D = 6 : B === "ArrowUp" && (D = -6); - s + D <= 0 || s + D > Zt(c) ? l(0) : D !== 0 && (l(s + D), N.preventDefault()); + i + D <= 0 || i + D > en(c) ? l(0) : D !== 0 && (l(i + D), k.preventDefault()); } }; - return at(() => { - o === c ? o === oe.bookNumberToId(e.bookNum) ? l(e.chapterNum) : l(1) : l(0); - }, [c, e.bookNum, e.chapterNum, o]), Ho(() => { - b(p); - }, [p]), Ho(() => { - const N = setTimeout(() => { + return ae(() => { + o === c ? o === ot.bookNumberToId(t.bookNum) ? l(t.chapterNum) : l(1) : l(0); + }, [c, t.bookNum, t.chapterNum, o]), Ko(() => { + g(p); + }, [p]), Ko(() => { + const k = setTimeout(() => { if (w && f.current && h.current) { - const D = h.current.offsetTop - ql; + const D = h.current.offsetTop - vc; f.current.scrollTo({ top: D, behavior: "instant" }); } }, 10); return () => { - clearTimeout(N); + clearTimeout(k); }; - }, [w]), /* @__PURE__ */ i("div", { className: "pr-twp tw-flex", children: /* @__PURE__ */ x(ao, { modal: !1, open: p, onOpenChange: k, children: [ - /* @__PURE__ */ i(as, { asChild: !0, children: /* @__PURE__ */ i( - Ol, + }, [w]), /* @__PURE__ */ s("div", { className: "pr-twp tw-flex", children: /* @__PURE__ */ x(co, { modal: !1, open: p, onOpenChange: S, children: [ + /* @__PURE__ */ s(ui, { asChild: !0, children: /* @__PURE__ */ s( + Zl, { ref: v, value: n, - handleSearch: A, + handleSearch: _, handleKeyDown: H, handleOnClick: () => { - a(oe.bookNumberToId(e.bookNum)), d(oe.bookNumberToId(e.bookNum)), l(e.chapterNum > 0 ? e.chapterNum : 0), m(!0), v.current.focus(); + a(ot.bookNumberToId(t.bookNum)), d(ot.bookNumberToId(t.bookNum)), l(t.chapterNum > 0 ? t.chapterNum : 0), m(!0), v.current.focus(); }, onFocus: () => { - O.current = !0; + C.current = !0; }, - handleSubmit: L, - placeholder: `${oe.bookNumberToEnglishName(e.bookNum)} ${e.chapterNum}:${e.verseNum}` + handleSubmit: z, + placeholder: `${ot.bookNumberToEnglishName(t.bookNum)} ${t.chapterNum}:${t.verseNum}` } ) }), /* @__PURE__ */ x( - tr, + rr, { className: "tw-m-1 tw-overflow-y-auto tw-p-0 tw-font-normal tw-text-foreground/80", style: { width: "233px", maxHeight: "500px", zIndex: "250" }, - onKeyDown: C, + onKeyDown: O, align: "start", ref: f, children: [ - /* @__PURE__ */ i( - Yl, + /* @__PURE__ */ s( + gc, { handleSort: () => console.log("sorting"), handleLocationHistory: () => console.log("location history"), handleBookmarks: () => console.log("bookmarks") } ), - Wo.map( - (N, B) => E(N).length > 0 && /* @__PURE__ */ x("div", { children: [ - /* @__PURE__ */ i(Nn, { className: "tw-font-semibold tw-text-foreground/80", children: Wl[N] }), - E(N).map((D) => /* @__PURE__ */ i("div", { children: /* @__PURE__ */ i( - Hl, + Qo.map( + (k, B) => E(k).length > 0 && /* @__PURE__ */ x("div", { children: [ + /* @__PURE__ */ s(Sn, { className: "tw-font-semibold tw-text-foreground/80", children: bc[k] }), + E(k).map((D) => /* @__PURE__ */ s("div", { children: /* @__PURE__ */ s( + mc, { bookId: D, - handleSelectBook: () => g(D, !1), + handleSelectBook: () => b(D, !1), isSelected: o === D, handleHighlightBook: () => d(D), - handleKeyDown: P, - bookType: N, + handleKeyDown: $, + bookType: k, ref: (J) => { o === D && (h.current = J); }, - children: /* @__PURE__ */ i( - Xl, + children: /* @__PURE__ */ s( + hc, { - handleSelectChapter: _, - endChapter: Zt(D), - activeChapter: e.bookNum === oe.bookIdToNumber(D) ? e.chapterNum : 0, - highlightedChapter: s, + handleSelectChapter: I, + endChapter: en(D), + activeChapter: t.bookNum === ot.bookIdToNumber(D) ? t.chapterNum : 0, + highlightedChapter: i, handleHighlightedChapter: (J) => { l(J); } @@ -1256,15 +1257,15 @@ function Nm({ scrRef: e, handleSubmit: t }) { ) } ) }, D)), - Wo.length - 1 !== B ? /* @__PURE__ */ i(nr, {}) : void 0 - ] }, N) + Qo.length - 1 !== B ? /* @__PURE__ */ s(or, {}) : void 0 + ] }, k) ) ] } ) ] }) }); } -const tc = Qn( +const Sc = Xe( "pr-twp tw-inline-flex tw-items-center tw-justify-center tw-whitespace-nowrap tw-rounded-md tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-colors focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50", { variants: { @@ -1288,185 +1289,185 @@ const tc = Qn( size: "default" } } -), be = I.forwardRef( - ({ className: e, variant: t, size: n, asChild: r = !1, ...o }, a) => /* @__PURE__ */ i(r ? cl : "button", { className: T(tc({ variant: t, size: n, className: e })), ref: a, ...o }) +), gt = T.forwardRef( + ({ className: t, variant: e, size: n, asChild: r = !1, ...o }, a) => /* @__PURE__ */ s(r ? He : "button", { className: N(Sc({ variant: e, size: n, className: t })), ref: a, ...o }) ); -be.displayName = "Button"; -const nc = Qn( +gt.displayName = "Button"; +const Tc = Xe( "tw-text-sm tw-font-medium tw-leading-none peer-disabled:tw-cursor-not-allowed peer-disabled:tw-opacity-70" -), He = I.forwardRef(({ className: e, ...t }, n) => /* @__PURE__ */ i(Ga.Root, { ref: n, className: T("pr-twp", nc(), e), ...t })); -He.displayName = Ga.Root.displayName; -const ls = I.forwardRef(({ className: e, ...t }, n) => /* @__PURE__ */ i( - un.Root, +), Xt = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s(Ja.Root, { ref: n, className: N("pr-twp", Tc(), t), ...e })); +Xt.displayName = Ja.Root.displayName; +const mi = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( + mn.Root, { - className: T("pr-twp tw-grid tw-gap-2", e), - ...t, + className: N("pr-twp tw-grid tw-gap-2", t), + ...e, ref: n } )); -ls.displayName = un.Root.displayName; -const Gr = I.forwardRef(({ className: e, ...t }, n) => /* @__PURE__ */ i( - un.Item, +mi.displayName = mn.Root.displayName; +const Wr = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( + mn.Item, { ref: n, - className: T( + className: N( "pr-twp tw-aspect-square tw-h-4 tw-w-4 tw-rounded-full tw-border tw-border-primary tw-text-primary tw-ring-offset-background focus:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-cursor-not-allowed disabled:tw-opacity-50", - e + t ), - ...t, - children: /* @__PURE__ */ i(un.Indicator, { className: "tw-flex tw-items-center tw-justify-center", children: /* @__PURE__ */ i(Ua, { className: "tw-h-2.5 tw-w-2.5 tw-fill-current tw-text-current" }) }) + ...e, + children: /* @__PURE__ */ s(mn.Indicator, { className: "tw-flex tw-items-center tw-justify-center", children: /* @__PURE__ */ s(qa, { className: "tw-h-2.5 tw-w-2.5 tw-fill-current tw-text-current" }) }) } )); -Gr.displayName = un.Item.displayName; -const rc = wn.Root, oc = wn.Trigger, cs = I.forwardRef(({ className: e, align: t = "center", sideOffset: n = 4, ...r }, o) => /* @__PURE__ */ i(wn.Portal, { children: /* @__PURE__ */ i( - wn.Content, +Wr.displayName = mn.Item.displayName; +const Cc = hn.Root, Oc = hn.Trigger, hi = T.forwardRef(({ className: t, align: e = "center", sideOffset: n = 4, ...r }, o) => /* @__PURE__ */ s(hn.Portal, { children: /* @__PURE__ */ s( + hn.Content, { ref: o, - align: t, + align: e, sideOffset: n, - className: T( + className: N( "pr-twp tw-z-50 tw-w-72 tw-rounded-md tw-border tw-bg-popover tw-p-4 tw-text-popover-foreground tw-shadow-md tw-outline-none data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0 data-[state=closed]:tw-zoom-out-95 data-[state=open]:tw-zoom-in-95 data-[side=bottom]:tw-slide-in-from-top-2 data-[side=left]:tw-slide-in-from-right-2 data-[side=right]:tw-slide-in-from-left-2 data-[side=top]:tw-slide-in-from-bottom-2", - e + t ), ...r } ) })); -cs.displayName = wn.Content.displayName; -const ac = Ye.Portal, ds = I.forwardRef(({ className: e, ...t }, n) => /* @__PURE__ */ i( - Ye.Overlay, +hi.displayName = hn.Content.displayName; +const Rc = vt.Portal, gi = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( + vt.Overlay, { ref: n, - className: T( + className: N( "tw-fixed tw-inset-0 tw-z-50 tw-bg-black/80 data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0", - e + t ), - ...t + ...e } )); -ds.displayName = Ye.Overlay.displayName; -const sc = I.forwardRef(({ className: e, children: t, ...n }, r) => /* @__PURE__ */ x(ac, { children: [ - /* @__PURE__ */ i(ds, {}), +gi.displayName = vt.Overlay.displayName; +const _c = T.forwardRef(({ className: t, children: e, ...n }, r) => /* @__PURE__ */ x(Rc, { children: [ + /* @__PURE__ */ s(gi, {}), /* @__PURE__ */ x( - Ye.Content, + vt.Content, { ref: r, - className: T( + className: N( "tw-fixed tw-left-[50%] tw-top-[50%] tw-z-50 tw-grid tw-w-full tw-max-w-lg tw-translate-x-[-50%] tw-translate-y-[-50%] tw-gap-4 tw-border tw-bg-background tw-p-6 tw-shadow-lg tw-duration-200 data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0 data-[state=closed]:tw-zoom-out-95 data-[state=open]:tw-zoom-in-95 data-[state=closed]:tw-slide-out-to-left-1/2 data-[state=closed]:tw-slide-out-to-top-[48%] data-[state=open]:tw-slide-in-from-left-1/2 data-[state=open]:tw-slide-in-from-top-[48%] sm:tw-rounded-lg", - e + t ), ...n, children: [ - t, - /* @__PURE__ */ x(Ye.Close, { className: "tw-absolute tw-right-4 tw-top-4 tw-rounded-sm tw-opacity-70 tw-ring-offset-background tw-transition-opacity hover:tw-opacity-100 focus:tw-outline-none focus:tw-ring-2 focus:tw-ring-ring focus:tw-ring-offset-2 disabled:tw-pointer-events-none data-[state=open]:tw-bg-accent data-[state=open]:tw-text-muted-foreground", children: [ - /* @__PURE__ */ i(Ai, { className: "tw-h-4 tw-w-4" }), - /* @__PURE__ */ i("span", { className: "tw-sr-only", children: "Close" }) + e, + /* @__PURE__ */ x(vt.Close, { className: "tw-absolute tw-right-4 tw-top-4 tw-rounded-sm tw-opacity-70 tw-ring-offset-background tw-transition-opacity hover:tw-opacity-100 focus:tw-outline-none focus:tw-ring-2 focus:tw-ring-ring focus:tw-ring-offset-2 disabled:tw-pointer-events-none data-[state=open]:tw-bg-accent data-[state=open]:tw-text-muted-foreground", children: [ + /* @__PURE__ */ s(Ka, { className: "tw-h-4 tw-w-4" }), + /* @__PURE__ */ s("span", { className: "tw-sr-only", children: "Close" }) ] }) ] } ) ] })); -sc.displayName = Ye.Content.displayName; -const ic = I.forwardRef(({ className: e, ...t }, n) => /* @__PURE__ */ i( - Ye.Title, +_c.displayName = vt.Content.displayName; +const Pc = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( + vt.Title, { ref: n, - className: T("tw-text-lg tw-font-semibold tw-leading-none tw-tracking-tight", e), - ...t + className: N("tw-text-lg tw-font-semibold tw-leading-none tw-tracking-tight", t), + ...e } )); -ic.displayName = Ye.Title.displayName; -const lc = I.forwardRef(({ className: e, ...t }, n) => /* @__PURE__ */ i( - Ye.Description, +Pc.displayName = vt.Title.displayName; +const $c = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( + vt.Description, { ref: n, - className: T("tw-text-sm tw-text-muted-foreground", e), - ...t + className: N("tw-text-sm tw-text-muted-foreground", t), + ...e } )); -lc.displayName = Ye.Description.displayName; -const ps = I.forwardRef(({ className: e, ...t }, n) => /* @__PURE__ */ i( - Se, +$c.displayName = vt.Description.displayName; +const bi = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( + Ot, { ref: n, - className: T( + className: N( "tw-flex tw-h-full tw-w-full tw-flex-col tw-overflow-hidden tw-rounded-md tw-bg-popover tw-text-popover-foreground", - e + t ), - ...t + ...e } )); -ps.displayName = Se.displayName; -const us = I.forwardRef(({ className: e, ...t }, n) => /* @__PURE__ */ x("div", { className: "tw-flex tw-items-center tw-border-b tw-px-3", children: [ - /* @__PURE__ */ i(Di, { className: "tw-me-2 tw-h-4 tw-w-4 tw-shrink-0 tw-opacity-50" }), - /* @__PURE__ */ i( - Se.Input, +bi.displayName = Ot.displayName; +const vi = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ x("div", { className: "tw-flex tw-items-center tw-border-b tw-px-3", children: [ + /* @__PURE__ */ s(ol, { className: "tw-me-2 tw-h-4 tw-w-4 tw-shrink-0 tw-opacity-50" }), + /* @__PURE__ */ s( + Ot.Input, { ref: n, - className: T( + className: N( "tw-flex tw-h-11 tw-w-full tw-rounded-md tw-bg-transparent tw-py-3 tw-text-sm tw-outline-none placeholder:tw-text-muted-foreground disabled:tw-cursor-not-allowed disabled:tw-opacity-50", - e + t ), - ...t + ...e } ) ] })); -us.displayName = Se.Input.displayName; -const ws = I.forwardRef(({ className: e, ...t }, n) => /* @__PURE__ */ i( - Se.List, +vi.displayName = Ot.Input.displayName; +const yi = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( + Ot.List, { ref: n, - className: T("tw-max-h-[300px] tw-overflow-y-auto tw-overflow-x-hidden", e), - ...t + className: N("tw-max-h-[300px] tw-overflow-y-auto tw-overflow-x-hidden", t), + ...e } )); -ws.displayName = Se.List.displayName; -const fs = I.forwardRef((e, t) => /* @__PURE__ */ i(Se.Empty, { ref: t, className: "tw-py-6 tw-text-center tw-text-sm", ...e })); -fs.displayName = Se.Empty.displayName; -const cc = I.forwardRef(({ className: e, ...t }, n) => /* @__PURE__ */ i( - Se.Group, +yi.displayName = Ot.List.displayName; +const xi = T.forwardRef((t, e) => /* @__PURE__ */ s(Ot.Empty, { ref: e, className: "tw-py-6 tw-text-center tw-text-sm", ...t })); +xi.displayName = Ot.Empty.displayName; +const Ic = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( + Ot.Group, { ref: n, - className: T( + className: N( "tw-overflow-hidden tw-p-1 tw-text-foreground [&_[cmdk-group-heading]]:tw-px-2 [&_[cmdk-group-heading]]:tw-py-1.5 [&_[cmdk-group-heading]]:tw-text-xs [&_[cmdk-group-heading]]:tw-font-medium [&_[cmdk-group-heading]]:tw-text-muted-foreground", - e + t ), - ...t + ...e } )); -cc.displayName = Se.Group.displayName; -const dc = I.forwardRef(({ className: e, ...t }, n) => /* @__PURE__ */ i( - Se.Separator, +Ic.displayName = Ot.Group.displayName; +const Ac = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( + Ot.Separator, { ref: n, - className: T("tw--mx-1 tw-h-px tw-bg-border", e), - ...t + className: N("tw--mx-1 tw-h-px tw-bg-border", t), + ...e } )); -dc.displayName = Se.Separator.displayName; -const ms = I.forwardRef(({ className: e, ...t }, n) => /* @__PURE__ */ i( - Se.Item, +Ac.displayName = Ot.Separator.displayName; +const Ni = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( + Ot.Item, { ref: n, - className: T( + className: N( "tw-relative tw-flex tw-cursor-default tw-select-none tw-items-center tw-rounded-sm tw-px-2 tw-py-1.5 tw-text-sm tw-outline-none data-[disabled=true]:tw-pointer-events-none data-[selected=true]:tw-bg-accent data-[selected=true]:tw-text-accent-foreground data-[disabled=true]:tw-opacity-50", - e + t ), - ...t + ...e } )); -ms.displayName = Se.Item.displayName; -function pc(e) { - return typeof e == "string" ? e : typeof e == "number" ? e.toString() : e.label; +Ni.displayName = Ot.Item.displayName; +function Mc(t) { + return typeof t == "string" ? t : typeof t == "number" ? t.toString() : t.label; } -function qo({ - id: e, - options: t = [], +function ta({ + id: t, + options: e = [], className: n, value: r, onChange: o = () => { }, - getOptionLabel: a = pc, - buttonPlaceholder: s = "", + getOptionLabel: a = Mc, + buttonPlaceholder: i = "", textPlaceholder: l = "", commandEmptyMessage: c = "No option found", buttonVariant: d = "outline", @@ -1474,38 +1475,38 @@ function qo({ isDisabled: m = !1, ...w }) { - const [b, v] = ue(!1); - return /* @__PURE__ */ x(rc, { open: b, onOpenChange: v, ...w, children: [ - /* @__PURE__ */ i(oc, { asChild: !0, children: /* @__PURE__ */ x( - be, + const [g, v] = ut(!1); + return /* @__PURE__ */ x(Cc, { open: g, onOpenChange: v, ...w, children: [ + /* @__PURE__ */ s(Oc, { asChild: !0, children: /* @__PURE__ */ x( + gt, { variant: d, role: "combobox", - "aria-expanded": b, - id: e, - className: T("tw-w-[200px] tw-justify-between", n), + "aria-expanded": g, + id: t, + className: N("tw-w-[200px] tw-justify-between", n), disabled: m, children: [ - /* @__PURE__ */ i("span", { className: "tw-overflow-hidden tw-text-ellipsis tw-whitespace-nowrap", children: r ? a(r) : s }), - /* @__PURE__ */ i(Mi, { className: "tw-ms-2 tw-h-4 tw-w-4 tw-shrink-0 tw-opacity-50" }) + /* @__PURE__ */ s("span", { className: "tw-overflow-hidden tw-text-ellipsis tw-whitespace-nowrap", children: r ? a(r) : i }), + /* @__PURE__ */ s(al, { className: "tw-ms-2 tw-h-4 tw-w-4 tw-shrink-0 tw-opacity-50" }) ] } ) }), - /* @__PURE__ */ i(cs, { className: "tw-w-[200px] tw-p-0", dir: p, children: /* @__PURE__ */ x(ps, { children: [ - /* @__PURE__ */ i(us, { dir: p, placeholder: l, className: "tw-text-inherit" }), - /* @__PURE__ */ i(fs, { children: c }), - /* @__PURE__ */ i(ws, { children: t.map((f) => /* @__PURE__ */ x( - ms, + /* @__PURE__ */ s(hi, { className: "tw-w-[200px] tw-p-0", dir: p, children: /* @__PURE__ */ x(bi, { children: [ + /* @__PURE__ */ s(vi, { dir: p, placeholder: l, className: "tw-text-inherit" }), + /* @__PURE__ */ s(xi, { children: c }), + /* @__PURE__ */ s(yi, { children: e.map((f) => /* @__PURE__ */ x( + Ni, { value: a(f), onSelect: () => { o(f), v(!1); }, children: [ - /* @__PURE__ */ i( - Jn, + /* @__PURE__ */ s( + tr, { - className: T("tw-me-2 tw-h-4 tw-w-4", { + className: N("tw-me-2 tw-h-4 tw-w-4", { "tw-opacity-0": !r || a(r) !== a(f) }) } @@ -1518,97 +1519,97 @@ function qo({ ] }) }) ] }); } -function uc({ - startChapter: e, - endChapter: t, +function Dc({ + startChapter: t, + endChapter: e, handleSelectStartChapter: n, handleSelectEndChapter: r, isDisabled: o = !1, chapterCount: a }) { - const s = _e( + const i = $t( () => Array.from({ length: a }, (d, p) => p + 1), [a] ); - return /* @__PURE__ */ x(st, { children: [ - /* @__PURE__ */ i(He, { htmlFor: "start-chapters-combobox", children: "Chapters" }), - /* @__PURE__ */ i( - qo, + return /* @__PURE__ */ x(ie, { children: [ + /* @__PURE__ */ s(Xt, { htmlFor: "start-chapters-combobox", children: "Chapters" }), + /* @__PURE__ */ s( + ta, { isDisabled: o, onChange: (d) => { - n(d), d > t && r(d); + n(d), d > e && r(d); }, className: "tw-ml-2 tw-mr-2 tw-w-20", - options: s, + options: i, getOptionLabel: (d) => d.toString(), - value: e + value: t }, "start chapter" ), - /* @__PURE__ */ i(He, { htmlFor: "end-chapters-combobox", children: "to" }), - /* @__PURE__ */ i( - qo, + /* @__PURE__ */ s(Xt, { htmlFor: "end-chapters-combobox", children: "to" }), + /* @__PURE__ */ s( + ta, { isDisabled: o, onChange: (d) => { - r(d), d < e && n(d); + r(d), d < t && n(d); }, className: "tw-ml-2 tw-w-20", - options: s, + options: i, getOptionLabel: (d) => d.toString(), - value: t + value: e }, "end chapter" ) ] }); } -var wc = /* @__PURE__ */ ((e) => (e.CURRENT_BOOK = "current book", e.CHOOSE_BOOKS = "choose books", e))(wc || {}); -const km = Object.freeze([ +var Bc = /* @__PURE__ */ ((t) => (t.CURRENT_BOOK = "current book", t.CHOOSE_BOOKS = "choose books", t))(Bc || {}); +const vh = Object.freeze([ "%webView_bookSelector_currentBook%", "%webView_bookSelector_choose%", "%webView_bookSelector_chooseBooks%" -]), Sr = (e, t) => e[t] ?? t; -function Em({ - handleBookSelectionModeChange: e, - currentBookName: t, +]), _r = (t, e) => t[e] ?? e; +function yh({ + handleBookSelectionModeChange: t, + currentBookName: e, onSelectBooks: n, selectedBookIds: r, chapterCount: o, endChapter: a, - handleSelectEndChapter: s, + handleSelectEndChapter: i, startChapter: l, handleSelectStartChapter: c, localizedStrings: d }) { - const p = Sr(d, "%webView_bookSelector_currentBook%"), m = Sr(d, "%webView_bookSelector_choose%"), w = Sr(d, "%webView_bookSelector_chooseBooks%"), [b, v] = ue( + const p = _r(d, "%webView_bookSelector_currentBook%"), m = _r(d, "%webView_bookSelector_choose%"), w = _r(d, "%webView_bookSelector_chooseBooks%"), [g, v] = ut( "current book" /* CURRENT_BOOK */ ), f = (h) => { - v(h), e(h); + v(h), t(h); }; - return /* @__PURE__ */ i( - ls, + return /* @__PURE__ */ s( + mi, { className: "pr-twp tw-flex", - value: b, + value: g, onValueChange: (h) => f(h), children: /* @__PURE__ */ x("div", { className: "tw-flex tw-w-full tw-flex-col tw-gap-4", children: [ /* @__PURE__ */ x("div", { className: "tw-grid tw-grid-cols-[25%,25%,50%]", children: [ /* @__PURE__ */ x("div", { className: "tw-flex tw-items-center", children: [ - /* @__PURE__ */ i(Gr, { + /* @__PURE__ */ s(Wr, { value: "current book" /* CURRENT_BOOK */ }), - /* @__PURE__ */ i(He, { className: "tw-ml-1", children: p }) + /* @__PURE__ */ s(Xt, { className: "tw-ml-1", children: p }) ] }), - /* @__PURE__ */ i(He, { className: "tw-flex tw-items-center", children: t }), - /* @__PURE__ */ i("div", { className: "tw-flex tw-items-center tw-justify-end", children: /* @__PURE__ */ i( - uc, + /* @__PURE__ */ s(Xt, { className: "tw-flex tw-items-center", children: e }), + /* @__PURE__ */ s("div", { className: "tw-flex tw-items-center tw-justify-end", children: /* @__PURE__ */ s( + Dc, { - isDisabled: b === "choose books", + isDisabled: g === "choose books", handleSelectStartChapter: c, - handleSelectEndChapter: s, + handleSelectEndChapter: i, chapterCount: o, startChapter: l, endChapter: a @@ -1617,17 +1618,17 @@ function Em({ ] }), /* @__PURE__ */ x("div", { className: "tw-grid tw-grid-cols-[25%,50%,25%]", children: [ /* @__PURE__ */ x("div", { className: "tw-flex tw-items-center", children: [ - /* @__PURE__ */ i(Gr, { + /* @__PURE__ */ s(Wr, { value: "choose books" /* CHOOSE_BOOKS */ }), - /* @__PURE__ */ i(He, { className: "tw-ml-1", children: w }) + /* @__PURE__ */ s(Xt, { className: "tw-ml-1", children: w }) ] }), - /* @__PURE__ */ i(He, { className: "tw-flex tw-items-center", children: r.map((h) => oe.bookIdToEnglishName(h)).join(", ") }), - /* @__PURE__ */ i( - be, + /* @__PURE__ */ s(Xt, { className: "tw-flex tw-items-center", children: r.map((h) => ot.bookIdToEnglishName(h)).join(", ") }), + /* @__PURE__ */ s( + gt, { - disabled: b === "current book", + disabled: g === "current book", onClick: () => n(), children: m } @@ -1637,340 +1638,340 @@ function Em({ } ); } -function fc({ table: e }) { - return /* @__PURE__ */ x(ao, { children: [ - /* @__PURE__ */ i(ol, { asChild: !0, children: /* @__PURE__ */ x(be, { variant: "outline", size: "sm", className: "tw-ml-auto tw-hidden tw-h-8 lg:tw-flex", children: [ - /* @__PURE__ */ i(Bi, { className: "tw-mr-2 tw-h-4 tw-w-4" }), +function jc({ table: t }) { + return /* @__PURE__ */ x(co, { children: [ + /* @__PURE__ */ s(Ol, { asChild: !0, children: /* @__PURE__ */ x(gt, { variant: "outline", size: "sm", className: "tw-ml-auto tw-hidden tw-h-8 lg:tw-flex", children: [ + /* @__PURE__ */ s(il, { className: "tw-mr-2 tw-h-4 tw-w-4" }), "View" ] }) }), - /* @__PURE__ */ x(tr, { align: "end", className: "tw-w-[150px]", children: [ - /* @__PURE__ */ i(Nn, { children: "Toggle columns" }), - /* @__PURE__ */ i(nr, {}), - e.getAllColumns().filter((t) => t.getCanHide()).map((t) => /* @__PURE__ */ i( - so, + /* @__PURE__ */ x(rr, { align: "end", className: "tw-w-[150px]", children: [ + /* @__PURE__ */ s(Sn, { children: "Toggle columns" }), + /* @__PURE__ */ s(or, {}), + t.getAllColumns().filter((e) => e.getCanHide()).map((e) => /* @__PURE__ */ s( + po, { className: "tw-capitalize", - checked: t.getIsVisible(), - onCheckedChange: (n) => t.toggleVisibility(!!n), - children: t.id + checked: e.getIsVisible(), + onCheckedChange: (n) => e.toggleVisibility(!!n), + children: e.id }, - t.id + e.id )) ] }) ] }); } -const fn = ge.Root, mc = ge.Group, mn = ge.Value, Mt = I.forwardRef(({ className: e, children: t, ...n }, r) => /* @__PURE__ */ x( - ge.Trigger, +const gn = bt.Root, Vc = bt.Group, bn = bt.Value, De = T.forwardRef(({ className: t, children: e, ...n }, r) => /* @__PURE__ */ x( + bt.Trigger, { ref: r, - className: T( + className: N( "tw-flex tw-h-10 tw-w-full tw-items-center tw-justify-between tw-rounded-md tw-border tw-border-input tw-bg-background tw-px-3 tw-py-2 tw-text-sm tw-ring-offset-background placeholder:tw-text-muted-foreground focus:tw-outline-none focus:tw-ring-2 focus:tw-ring-ring focus:tw-ring-offset-2 disabled:tw-cursor-not-allowed disabled:tw-opacity-50 [&>span]:tw-line-clamp-1", - e + t ), ...n, children: [ - t, - /* @__PURE__ */ i(ge.Icon, { asChild: !0, children: /* @__PURE__ */ i(Zn, { className: "tw-h-4 tw-w-4 tw-opacity-50" }) }) + e, + /* @__PURE__ */ s(bt.Icon, { asChild: !0, children: /* @__PURE__ */ s(er, { className: "tw-h-4 tw-w-4 tw-opacity-50" }) }) ] } )); -Mt.displayName = ge.Trigger.displayName; -const hs = I.forwardRef(({ className: e, ...t }, n) => /* @__PURE__ */ i( - ge.ScrollUpButton, +De.displayName = bt.Trigger.displayName; +const ki = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( + bt.ScrollUpButton, { ref: n, - className: T("tw-flex tw-cursor-default tw-items-center tw-justify-center tw-py-1", e), - ...t, - children: /* @__PURE__ */ i(ji, { className: "tw-h-4 tw-w-4" }) + className: N("tw-flex tw-cursor-default tw-items-center tw-justify-center tw-py-1", t), + ...e, + children: /* @__PURE__ */ s(sl, { className: "tw-h-4 tw-w-4" }) } )); -hs.displayName = ge.ScrollUpButton.displayName; -const gs = I.forwardRef(({ className: e, ...t }, n) => /* @__PURE__ */ i( - ge.ScrollDownButton, +ki.displayName = bt.ScrollUpButton.displayName; +const Ei = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( + bt.ScrollDownButton, { ref: n, - className: T("tw-flex tw-cursor-default tw-items-center tw-justify-center tw-py-1", e), - ...t, - children: /* @__PURE__ */ i(Zn, { className: "tw-h-4 tw-w-4" }) + className: N("tw-flex tw-cursor-default tw-items-center tw-justify-center tw-py-1", t), + ...e, + children: /* @__PURE__ */ s(er, { className: "tw-h-4 tw-w-4" }) } )); -gs.displayName = ge.ScrollDownButton.displayName; -const Bt = I.forwardRef(({ className: e, children: t, position: n = "popper", ...r }, o) => /* @__PURE__ */ i(ge.Portal, { children: /* @__PURE__ */ x( - ge.Content, +Ei.displayName = bt.ScrollDownButton.displayName; +const Be = T.forwardRef(({ className: t, children: e, position: n = "popper", ...r }, o) => /* @__PURE__ */ s(bt.Portal, { children: /* @__PURE__ */ x( + bt.Content, { ref: o, - className: T( + className: N( "pr-twp tw-relative tw-z-50 tw-max-h-96 tw-min-w-[8rem] tw-overflow-hidden tw-rounded-md tw-border tw-bg-popover tw-text-popover-foreground tw-shadow-md data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0 data-[state=closed]:tw-zoom-out-95 data-[state=open]:tw-zoom-in-95 data-[side=bottom]:tw-slide-in-from-top-2 data-[side=left]:tw-slide-in-from-right-2 data-[side=right]:tw-slide-in-from-left-2 data-[side=top]:tw-slide-in-from-bottom-2", n === "popper" && "data-[side=bottom]:tw-translate-y-1 data-[side=left]:tw--translate-x-1 data-[side=right]:tw-translate-x-1 data-[side=top]:tw--translate-y-1", - e + t ), position: n, ...r, children: [ - /* @__PURE__ */ i(hs, {}), - /* @__PURE__ */ i( - ge.Viewport, + /* @__PURE__ */ s(ki, {}), + /* @__PURE__ */ s( + bt.Viewport, { - className: T( + className: N( "tw-p-1", n === "popper" && "tw-h-[var(--radix-select-trigger-height)] tw-w-full tw-min-w-[var(--radix-select-trigger-width)]" ), - children: t + children: e } ), - /* @__PURE__ */ i(gs, {}) + /* @__PURE__ */ s(Ei, {}) ] } ) })); -Bt.displayName = ge.Content.displayName; -const hc = I.forwardRef(({ className: e, ...t }, n) => /* @__PURE__ */ i( - ge.Label, +Be.displayName = bt.Content.displayName; +const zc = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( + bt.Label, { ref: n, - className: T("tw-py-1.5 tw-pl-8 tw-pr-2 tw-text-sm tw-font-semibold", e), - ...t + className: N("tw-py-1.5 tw-pl-8 tw-pr-2 tw-text-sm tw-font-semibold", t), + ...e } )); -hc.displayName = ge.Label.displayName; -const Ue = I.forwardRef(({ className: e, children: t, ...n }, r) => /* @__PURE__ */ x( - ge.Item, +zc.displayName = bt.Label.displayName; +const Gt = T.forwardRef(({ className: t, children: e, ...n }, r) => /* @__PURE__ */ x( + bt.Item, { ref: r, - className: T( + className: N( "tw-relative tw-flex tw-w-full tw-cursor-default tw-select-none tw-items-center tw-rounded-sm tw-py-1.5 tw-pl-8 tw-pr-2 tw-text-sm tw-outline-none focus:tw-bg-accent focus:tw-text-accent-foreground data-[disabled]:tw-pointer-events-none data-[disabled]:tw-opacity-50", - e + t ), ...n, children: [ - /* @__PURE__ */ i("span", { className: "tw-absolute tw-left-2 tw-flex tw-h-3.5 tw-w-3.5 tw-items-center tw-justify-center", children: /* @__PURE__ */ i(ge.ItemIndicator, { children: /* @__PURE__ */ i(Jn, { className: "tw-h-4 tw-w-4" }) }) }), - /* @__PURE__ */ i(ge.ItemText, { children: t }) + /* @__PURE__ */ s("span", { className: "tw-absolute tw-left-2 tw-flex tw-h-3.5 tw-w-3.5 tw-items-center tw-justify-center", children: /* @__PURE__ */ s(bt.ItemIndicator, { children: /* @__PURE__ */ s(tr, { className: "tw-h-4 tw-w-4" }) }) }), + /* @__PURE__ */ s(bt.ItemText, { children: e }) ] } )); -Ue.displayName = ge.Item.displayName; -const gc = I.forwardRef(({ className: e, ...t }, n) => /* @__PURE__ */ i( - ge.Separator, +Gt.displayName = bt.Item.displayName; +const Lc = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( + bt.Separator, { ref: n, - className: T("tw--mx-1 tw-my-1 tw-h-px tw-bg-muted", e), - ...t + className: N("tw--mx-1 tw-my-1 tw-h-px tw-bg-muted", t), + ...e } )); -gc.displayName = ge.Separator.displayName; -function bc({ table: e }) { - return /* @__PURE__ */ i("div", { className: "tw-flex tw-items-center tw-justify-between tw-px-2 tw-pb-3 tw-pt-3", children: /* @__PURE__ */ x("div", { className: "tw-flex tw-items-center tw-space-x-6 lg:tw-space-x-8", children: [ +Lc.displayName = bt.Separator.displayName; +function Fc({ table: t }) { + return /* @__PURE__ */ s("div", { className: "tw-flex tw-items-center tw-justify-between tw-px-2 tw-pb-3 tw-pt-3", children: /* @__PURE__ */ x("div", { className: "tw-flex tw-items-center tw-space-x-6 lg:tw-space-x-8", children: [ /* @__PURE__ */ x("div", { className: "tw-flex-1 tw-text-sm tw-text-muted-foreground", children: [ - e.getFilteredSelectedRowModel().rows.length, + t.getFilteredSelectedRowModel().rows.length, " of", " ", - e.getFilteredRowModel().rows.length, + t.getFilteredRowModel().rows.length, " row(s) selected" ] }), /* @__PURE__ */ x("div", { className: "tw-flex tw-items-center tw-space-x-2", children: [ - /* @__PURE__ */ i("p", { className: "tw-text-nowrap tw-text-sm tw-font-medium", children: "Rows per page" }), + /* @__PURE__ */ s("p", { className: "tw-text-nowrap tw-text-sm tw-font-medium", children: "Rows per page" }), /* @__PURE__ */ x( - fn, + gn, { - value: `${e.getState().pagination.pageSize}`, - onValueChange: (t) => { - e.setPageSize(Number(t)); + value: `${t.getState().pagination.pageSize}`, + onValueChange: (e) => { + t.setPageSize(Number(e)); }, children: [ - /* @__PURE__ */ i(Mt, { className: "tw-h-8 tw-w-[70px]", children: /* @__PURE__ */ i(mn, { placeholder: e.getState().pagination.pageSize }) }), - /* @__PURE__ */ i(Bt, { side: "top", children: [10, 20, 30, 40, 50].map((t) => /* @__PURE__ */ i(Ue, { value: `${t}`, children: t }, t)) }) + /* @__PURE__ */ s(De, { className: "tw-h-8 tw-w-[70px]", children: /* @__PURE__ */ s(bn, { placeholder: t.getState().pagination.pageSize }) }), + /* @__PURE__ */ s(Be, { side: "top", children: [10, 20, 30, 40, 50].map((e) => /* @__PURE__ */ s(Gt, { value: `${e}`, children: e }, e)) }) ] } ) ] }), /* @__PURE__ */ x("div", { className: "tw-flex tw-w-[100px] tw-items-center tw-justify-center tw-text-sm tw-font-medium", children: [ "Page ", - e.getState().pagination.pageIndex + 1, + t.getState().pagination.pageIndex + 1, " of ", - e.getPageCount() + t.getPageCount() ] }), /* @__PURE__ */ x("div", { className: "tw-flex tw-items-center tw-space-x-2", children: [ /* @__PURE__ */ x( - be, + gt, { variant: "outline", size: "icon", className: "tw-hidden tw-h-8 tw-w-8 tw-p-0 lg:tw-flex", - onClick: () => e.setPageIndex(0), - disabled: !e.getCanPreviousPage(), + onClick: () => t.setPageIndex(0), + disabled: !t.getCanPreviousPage(), children: [ - /* @__PURE__ */ i("span", { className: "tw-sr-only", children: "Go to first page" }), - /* @__PURE__ */ i(Vi, { className: "tw-h-4 tw-w-4" }) + /* @__PURE__ */ s("span", { className: "tw-sr-only", children: "Go to first page" }), + /* @__PURE__ */ s(ll, { className: "tw-h-4 tw-w-4" }) ] } ), /* @__PURE__ */ x( - be, + gt, { variant: "outline", size: "icon", className: "tw-h-8 tw-w-8 tw-p-0", - onClick: () => e.previousPage(), - disabled: !e.getCanPreviousPage(), + onClick: () => t.previousPage(), + disabled: !t.getCanPreviousPage(), children: [ - /* @__PURE__ */ i("span", { className: "tw-sr-only", children: "Go to previous page" }), - /* @__PURE__ */ i(Li, { className: "tw-h-4 tw-w-4" }) + /* @__PURE__ */ s("span", { className: "tw-sr-only", children: "Go to previous page" }), + /* @__PURE__ */ s(cl, { className: "tw-h-4 tw-w-4" }) ] } ), /* @__PURE__ */ x( - be, + gt, { variant: "outline", size: "icon", className: "tw-h-8 tw-w-8 tw-p-0", - onClick: () => e.nextPage(), - disabled: !e.getCanNextPage(), + onClick: () => t.nextPage(), + disabled: !t.getCanNextPage(), children: [ - /* @__PURE__ */ i("span", { className: "tw-sr-only", children: "Go to next page" }), - /* @__PURE__ */ i(zi, { className: "tw-h-4 tw-w-4" }) + /* @__PURE__ */ s("span", { className: "tw-sr-only", children: "Go to next page" }), + /* @__PURE__ */ s(dl, { className: "tw-h-4 tw-w-4" }) ] } ), /* @__PURE__ */ x( - be, + gt, { variant: "outline", size: "icon", className: "tw-hidden tw-h-8 tw-w-8 tw-p-0 lg:tw-flex", - onClick: () => e.setPageIndex(e.getPageCount() - 1), - disabled: !e.getCanNextPage(), + onClick: () => t.setPageIndex(t.getPageCount() - 1), + disabled: !t.getCanNextPage(), children: [ - /* @__PURE__ */ i("span", { className: "tw-sr-only", children: "Go to last page" }), - /* @__PURE__ */ i(Fi, { className: "tw-h-4 tw-w-4" }) + /* @__PURE__ */ s("span", { className: "tw-sr-only", children: "Go to last page" }), + /* @__PURE__ */ s(pl, { className: "tw-h-4 tw-w-4" }) ] } ) ] }) ] }) }); } -const rr = I.forwardRef(({ className: e, stickyHeader: t, ...n }, r) => /* @__PURE__ */ i("div", { className: T("pr-twp tw-relative tw-w-full", { "tw-overflow-auto": !t }), children: /* @__PURE__ */ i( +const ar = T.forwardRef(({ className: t, stickyHeader: e, ...n }, r) => /* @__PURE__ */ s("div", { className: N("pr-twp tw-relative tw-w-full", { "tw-overflow-auto": !e }), children: /* @__PURE__ */ s( "table", { ref: r, - className: T("tw-w-full tw-caption-bottom tw-text-sm", e), + className: N("tw-w-full tw-caption-bottom tw-text-sm", t), ...n } ) })); -rr.displayName = "Table"; -const or = I.forwardRef(({ className: e, stickyHeader: t, ...n }, r) => /* @__PURE__ */ i( +ar.displayName = "Table"; +const ir = T.forwardRef(({ className: t, stickyHeader: e, ...n }, r) => /* @__PURE__ */ s( "thead", { ref: r, - className: T( - { "tw-sticky tw-top-[-1px] tw-bg-background tw-drop-shadow-sm": t }, + className: N( + { "tw-sticky tw-top-[-1px] tw-bg-background tw-drop-shadow-sm": e }, "[&_tr]:tw-border-b", - e + t ), ...n } )); -or.displayName = "TableHeader"; -const ar = I.forwardRef(({ className: e, ...t }, n) => /* @__PURE__ */ i("tbody", { ref: n, className: T("[&_tr:last-child]:tw-border-0", e), ...t })); -ar.displayName = "TableBody"; -const vc = I.forwardRef(({ className: e, ...t }, n) => /* @__PURE__ */ i( +ir.displayName = "TableHeader"; +const sr = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s("tbody", { ref: n, className: N("[&_tr:last-child]:tw-border-0", t), ...e })); +sr.displayName = "TableBody"; +const Uc = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( "tfoot", { ref: n, - className: T("tw-border-t tw-bg-muted/50 tw-font-medium [&>tr]:last:tw-border-b-0", e), - ...t + className: N("tw-border-t tw-bg-muted/50 tw-font-medium [&>tr]:last:tw-border-b-0", t), + ...e } )); -vc.displayName = "TableFooter"; -const ot = I.forwardRef( - ({ className: e, ...t }, n) => /* @__PURE__ */ i( +Uc.displayName = "TableFooter"; +const oe = T.forwardRef( + ({ className: t, ...e }, n) => /* @__PURE__ */ s( "tr", { ref: n, - className: T( + className: N( "tw-border-b tw-transition-colors hover:tw-bg-muted/50 data-[state=selected]:tw-bg-muted", - e + t ), - ...t + ...e } ) ); -ot.displayName = "TableRow"; -const hn = I.forwardRef(({ className: e, ...t }, n) => /* @__PURE__ */ i( +oe.displayName = "TableRow"; +const vn = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( "th", { ref: n, - className: T( + className: N( "tw-h-12 tw-px-4 tw-text-start tw-align-middle tw-font-medium tw-text-muted-foreground [&:has([role=checkbox])]:tw-pe-0", - e + t ), - ...t + ...e } )); -hn.displayName = "TableHead"; -const jt = I.forwardRef(({ className: e, ...t }, n) => /* @__PURE__ */ i( +vn.displayName = "TableHead"; +const je = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( "td", { ref: n, - className: T("tw-p-4 tw-align-middle [&:has([role=checkbox])]:tw-pe-0", e), - ...t + className: N("tw-p-4 tw-align-middle [&:has([role=checkbox])]:tw-pe-0", t), + ...e } )); -jt.displayName = "TableCell"; -const yc = I.forwardRef(({ className: e, ...t }, n) => /* @__PURE__ */ i( +je.displayName = "TableCell"; +const Gc = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( "caption", { ref: n, - className: T("tw-mt-4 tw-text-sm tw-text-muted-foreground", e), - ...t + className: N("tw-mt-4 tw-text-sm tw-text-muted-foreground", t), + ...e } )); -yc.displayName = "TableCaption"; -function xc({ - columns: e, - data: t, +Gc.displayName = "TableCaption"; +function Hc({ + columns: t, + data: e, enablePagination: n = !1, showPaginationControls: r = !1, showColumnVisibilityControls: o = !1, stickyHeader: a = !1, - onRowClickHandler: s = () => { + onRowClickHandler: i = () => { } }) { var h; - const [l, c] = ue([]), [d, p] = ue([]), [m, w] = ue({}), [b, v] = ue({}), f = Ha({ - data: t, - columns: e, - getCoreRowModel: Xa(), - ...n && { getPaginationRowModel: dl() }, + const [l, c] = ut([]), [d, p] = ut([]), [m, w] = ut({}), [g, v] = ut({}), f = Za({ + data: e, + columns: t, + getCoreRowModel: Qa(), + ...n && { getPaginationRowModel: Il() }, onSortingChange: c, - getSortedRowModel: Ya(), + getSortedRowModel: ti(), onColumnFiltersChange: p, - getFilteredRowModel: pl(), + getFilteredRowModel: Al(), onColumnVisibilityChange: w, onRowSelectionChange: v, state: { sorting: l, columnFilters: d, columnVisibility: m, - rowSelection: b + rowSelection: g } }); return /* @__PURE__ */ x("div", { className: "pr-twp", children: [ - o && /* @__PURE__ */ i(fc, { table: f }), - /* @__PURE__ */ x(rr, { stickyHeader: a, children: [ - /* @__PURE__ */ i(or, { stickyHeader: a, children: f.getHeaderGroups().map((E) => /* @__PURE__ */ i(ot, { children: E.headers.map((A) => /* @__PURE__ */ i(hn, { children: A.isPlaceholder ? void 0 : sn(A.column.columnDef.header, A.getContext()) }, A.id)) }, E.id)) }), - /* @__PURE__ */ i(ar, { children: (h = f.getRowModel().rows) != null && h.length ? f.getRowModel().rows.map((E) => /* @__PURE__ */ i( - ot, + o && /* @__PURE__ */ s(jc, { table: f }), + /* @__PURE__ */ x(ar, { stickyHeader: a, children: [ + /* @__PURE__ */ s(ir, { stickyHeader: a, children: f.getHeaderGroups().map((E) => /* @__PURE__ */ s(oe, { children: E.headers.map((_) => /* @__PURE__ */ s(vn, { children: _.isPlaceholder ? void 0 : dn(_.column.columnDef.header, _.getContext()) }, _.id)) }, E.id)) }), + /* @__PURE__ */ s(sr, { children: (h = f.getRowModel().rows) != null && h.length ? f.getRowModel().rows.map((E) => /* @__PURE__ */ s( + oe, { - onClick: () => s(E, f), + onClick: () => i(E, f), "data-state": E.getIsSelected() && "selected", - children: E.getVisibleCells().map((A) => /* @__PURE__ */ i(jt, { children: sn(A.column.columnDef.cell, A.getContext()) }, A.id)) + children: E.getVisibleCells().map((_) => /* @__PURE__ */ s(je, { children: dn(_.column.columnDef.cell, _.getContext()) }, _.id)) }, E.id - )) : /* @__PURE__ */ i(ot, { children: /* @__PURE__ */ i(jt, { colSpan: e.length, className: "tw-h-24 tw-text-center", children: "No results." }) }) }) + )) : /* @__PURE__ */ s(oe, { children: /* @__PURE__ */ s(je, { colSpan: t.length, className: "tw-h-24 tw-text-center", children: "No results." }) }) }) ] }), n && /* @__PURE__ */ x("div", { className: "tw-flex tw-items-center tw-justify-end tw-space-x-2 tw-py-4", children: [ - /* @__PURE__ */ i( - be, + /* @__PURE__ */ s( + gt, { variant: "outline", size: "sm", @@ -1979,8 +1980,8 @@ function xc({ children: "Previous" } ), - /* @__PURE__ */ i( - be, + /* @__PURE__ */ s( + gt, { variant: "outline", size: "sm", @@ -1990,67 +1991,67 @@ function xc({ } ) ] }), - n && r && /* @__PURE__ */ i(bc, { table: f }) + n && r && /* @__PURE__ */ s(Fc, { table: f }) ] }); } -function Nc({ - occurrenceData: e, - setScriptureReference: t, +function Xc({ + occurrenceData: t, + setScriptureReference: e, localizedStrings: n }) { - const r = n["%webView_inventory_occurrences_table_header_reference%"], o = n["%webView_inventory_occurrences_table_header_occurrence%"], a = _e(() => { - const s = []; - return e.forEach((l) => { - s.some((c) => to(c, l)) || s.push(l); - }), s; - }, [e]); - return /* @__PURE__ */ x(rr, { stickyHeader: !0, children: [ - /* @__PURE__ */ i(or, { stickyHeader: !0, children: /* @__PURE__ */ x(ot, { children: [ - /* @__PURE__ */ i(hn, { children: r }), - /* @__PURE__ */ i(hn, { children: o }) + const r = n["%webView_inventory_occurrences_table_header_reference%"], o = n["%webView_inventory_occurrences_table_header_occurrence%"], a = $t(() => { + const i = []; + return t.forEach((l) => { + i.some((c) => ao(c, l)) || i.push(l); + }), i; + }, [t]); + return /* @__PURE__ */ x(ar, { stickyHeader: !0, children: [ + /* @__PURE__ */ s(ir, { stickyHeader: !0, children: /* @__PURE__ */ x(oe, { children: [ + /* @__PURE__ */ s(vn, { children: r }), + /* @__PURE__ */ s(vn, { children: o }) ] }) }), - /* @__PURE__ */ i(ar, { children: a.length > 0 && a.map((s) => /* @__PURE__ */ x( - ot, + /* @__PURE__ */ s(sr, { children: a.length > 0 && a.map((i) => /* @__PURE__ */ x( + oe, { onClick: () => { - t(s.reference); + e(i.reference); }, children: [ - /* @__PURE__ */ i(jt, { children: `${oe.bookNumberToEnglishName(s.reference.bookNum)} ${s.reference.chapterNum}:${s.reference.verseNum}` }), - /* @__PURE__ */ i(jt, { children: s.text }) + /* @__PURE__ */ s(je, { children: `${ot.bookNumberToEnglishName(i.reference.bookNum)} ${i.reference.chapterNum}:${i.reference.verseNum}` }), + /* @__PURE__ */ s(je, { children: i.text }) ] }, - `${s.reference.bookNum} ${s.reference.chapterNum}:${s.reference.verseNum}-${s.text}` + `${i.reference.bookNum} ${i.reference.chapterNum}:${i.reference.verseNum}-${i.text}` )) }) ] }); } -const io = I.forwardRef(({ className: e, ...t }, n) => /* @__PURE__ */ i( - Fr.Root, +const uo = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( + Xr.Root, { ref: n, - className: T( + className: N( "tw-peer pr-twp tw-h-4 tw-w-4 tw-shrink-0 tw-rounded-sm tw-border tw-border-primary tw-ring-offset-background focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-cursor-not-allowed disabled:tw-opacity-50 data-[state=checked]:tw-bg-primary data-[state=checked]:tw-text-primary-foreground", - e + t ), - ...t, - children: /* @__PURE__ */ i( - Fr.Indicator, + ...e, + children: /* @__PURE__ */ s( + Xr.Indicator, { - className: T("tw-flex tw-items-center tw-justify-center tw-text-current"), - children: /* @__PURE__ */ i(Jn, { className: "tw-h-4 tw-w-4" }) + className: N("tw-flex tw-items-center tw-justify-center tw-text-current"), + children: /* @__PURE__ */ s(tr, { className: "tw-h-4 tw-w-4" }) } ) } )); -io.displayName = Fr.Root.displayName; -const kc = (e) => e.split(/(?:\r?\n|\r)|(?=(?:\\(?:v|c|id)))/g), Ko = (e) => { - const t = /^\\[vc]\s+(\d+)/, n = e.match(t); +uo.displayName = Xr.Root.displayName; +const Yc = (t) => t.split(/(?:\r?\n|\r)|(?=(?:\\(?:v|c|id)))/g), ea = (t) => { + const e = /^\\[vc]\s+(\d+)/, n = t.match(e); if (n) return +n[1]; -}, Ec = (e) => { - const t = e.match(/^\\id\s+([A-Za-z]+)/); - return t ? oe.bookIdToNumber(t[1]) : 0; -}, Tc = (e, t, n) => n.includes(e) ? "unapproved" : t.includes(e) ? "approved" : "unknown", bs = Qn( +}, Wc = (t) => { + const e = t.match(/^\\id\s+([A-Za-z]+)/); + return e ? ot.bookIdToNumber(e[1]) : 0; +}, qc = (t, e, n) => n.includes(t) ? "unapproved" : e.includes(t) ? "approved" : "unknown", Si = Xe( "pr-twp tw-inline-flex tw-items-center tw-justify-center tw-rounded-md tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-colors hover:tw-bg-muted hover:tw-text-muted-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50 data-[state=on]:tw-bg-accent data-[state=on]:tw-text-accent-foreground", { variants: { @@ -2069,140 +2070,140 @@ const kc = (e) => e.split(/(?:\r?\n|\r)|(?=(?:\\(?:v|c|id)))/g), Ko = (e) => { size: "default" } } -), Cc = I.forwardRef(({ className: e, variant: t, size: n, ...r }, o) => /* @__PURE__ */ i( - Wa.Root, +), Kc = T.forwardRef(({ className: t, variant: e, size: n, ...r }, o) => /* @__PURE__ */ s( + ei.Root, { ref: o, - className: T(bs({ variant: t, size: n, className: e })), + className: N(Si({ variant: e, size: n, className: t })), ...r } )); -Cc.displayName = Wa.Root.displayName; -const vs = I.createContext({ +Kc.displayName = ei.Root.displayName; +const Ti = T.createContext({ size: "default", variant: "default" -}), ys = I.forwardRef(({ className: e, variant: t, size: n, children: r, ...o }, a) => /* @__PURE__ */ i( - er.Root, +}), Ci = T.forwardRef(({ className: t, variant: e, size: n, children: r, ...o }, a) => /* @__PURE__ */ s( + nr.Root, { ref: a, - className: T("pr-twp tw-flex tw-items-center tw-justify-center tw-gap-1", e), + className: N("pr-twp tw-flex tw-items-center tw-justify-center tw-gap-1", t), ...o, - children: /* @__PURE__ */ i( - vs.Provider, + children: /* @__PURE__ */ s( + Ti.Provider, { - value: { variant: t, size: n }, + value: { variant: e, size: n }, children: r } ) } )); -ys.displayName = er.Root.displayName; -const Ln = I.forwardRef(({ className: e, children: t, variant: n, size: r, ...o }, a) => { - const s = I.useContext(vs); - return /* @__PURE__ */ i( - er.Item, +Ci.displayName = nr.Root.displayName; +const Un = T.forwardRef(({ className: t, children: e, variant: n, size: r, ...o }, a) => { + const i = T.useContext(Ti); + return /* @__PURE__ */ s( + nr.Item, { ref: a, - className: T( - bs({ - variant: s.variant || n, - size: s.size || r + className: N( + Si({ + variant: i.variant || n, + size: i.size || r }), - e + t ), ...o, - children: t + children: e } ); }); -Ln.displayName = er.Item.displayName; -const sr = (e) => e === "asc" ? /* @__PURE__ */ i(Xi, { className: "tw-ms-2 tw-h-4 tw-w-4" }) : e === "desc" ? /* @__PURE__ */ i(Yi, { className: "tw-ms-2 tw-h-4 tw-w-4" }) : /* @__PURE__ */ i(Wi, { className: "tw-ms-2 tw-h-4 tw-w-4" }), Tm = (e) => ({ +Un.displayName = nr.Item.displayName; +const lr = (t) => t === "asc" ? /* @__PURE__ */ s(ml, { className: "tw-ms-2 tw-h-4 tw-w-4" }) : t === "desc" ? /* @__PURE__ */ s(hl, { className: "tw-ms-2 tw-h-4 tw-w-4" }) : /* @__PURE__ */ s(gl, { className: "tw-ms-2 tw-h-4 tw-w-4" }), xh = (t) => ({ accessorKey: "item", - accessorFn: (t) => t.items[0], - header: ({ column: t }) => /* @__PURE__ */ x(be, { variant: "ghost", onClick: () => t.toggleSorting(void 0), children: [ - e, - sr(t.getIsSorted()) + accessorFn: (e) => e.items[0], + header: ({ column: e }) => /* @__PURE__ */ x(gt, { variant: "ghost", onClick: () => e.toggleSorting(void 0), children: [ + t, + lr(e.getIsSorted()) ] }) -}), Sc = (e, t) => ({ - accessorKey: `item${t}`, - accessorFn: (n) => n.items[t], - header: ({ column: n }) => /* @__PURE__ */ x(be, { variant: "ghost", onClick: () => n.toggleSorting(void 0), children: [ - e, - sr(n.getIsSorted()) +}), Jc = (t, e) => ({ + accessorKey: `item${e}`, + accessorFn: (n) => n.items[e], + header: ({ column: n }) => /* @__PURE__ */ x(gt, { variant: "ghost", onClick: () => n.toggleSorting(void 0), children: [ + t, + lr(n.getIsSorted()) ] }) -}), Cm = (e) => ({ +}), Nh = (t) => ({ accessorKey: "count", - header: ({ column: t }) => /* @__PURE__ */ i("div", { className: "tw-flex tw-justify-end tw-tabular-nums", children: /* @__PURE__ */ x(be, { variant: "ghost", onClick: () => t.toggleSorting(void 0), children: [ - e, - sr(t.getIsSorted()) + header: ({ column: e }) => /* @__PURE__ */ s("div", { className: "tw-flex tw-justify-end tw-tabular-nums", children: /* @__PURE__ */ x(gt, { variant: "ghost", onClick: () => e.toggleSorting(void 0), children: [ + t, + lr(e.getIsSorted()) ] }) }), - cell: ({ row: t }) => /* @__PURE__ */ i("div", { className: "tw-flex tw-justify-end", children: t.getValue("count") }) -}), Or = (e, t, n, r, o, a) => { - let s = [...n]; - e.forEach((c) => { - t === "approved" ? s.includes(c) || s.push(c) : s = s.filter((d) => d !== c); - }), r(s); + cell: ({ row: e }) => /* @__PURE__ */ s("div", { className: "tw-flex tw-justify-end", children: e.getValue("count") }) +}), Pr = (t, e, n, r, o, a) => { + let i = [...n]; + t.forEach((c) => { + e === "approved" ? i.includes(c) || i.push(c) : i = i.filter((d) => d !== c); + }), r(i); let l = [...o]; - e.forEach((c) => { - t === "unapproved" ? l.includes(c) || l.push(c) : l = l.filter((d) => d !== c); + t.forEach((c) => { + e === "unapproved" ? l.includes(c) || l.push(c) : l = l.filter((d) => d !== c); }), a(l); -}, Sm = (e, t, n, r, o) => ({ +}, kh = (t, e, n, r, o) => ({ accessorKey: "status", - header: ({ column: a }) => /* @__PURE__ */ i("div", { className: "tw-flex tw-justify-center", children: /* @__PURE__ */ x(be, { variant: "ghost", onClick: () => a.toggleSorting(void 0), children: [ - e, - sr(a.getIsSorted()) + header: ({ column: a }) => /* @__PURE__ */ s("div", { className: "tw-flex tw-justify-center", children: /* @__PURE__ */ x(gt, { variant: "ghost", onClick: () => a.toggleSorting(void 0), children: [ + t, + lr(a.getIsSorted()) ] }) }), cell: ({ row: a }) => { - const s = a.getValue("status"), l = a.getValue("item"); - return /* @__PURE__ */ x(ys, { value: s, variant: "outline", type: "single", children: [ - /* @__PURE__ */ i( - Ln, + const i = a.getValue("status"), l = a.getValue("item"); + return /* @__PURE__ */ x(Ci, { value: i, variant: "outline", type: "single", children: [ + /* @__PURE__ */ s( + Un, { - onClick: () => Or( + onClick: () => Pr( [l], "approved", - t, + e, n, r, o ), value: "approved", - children: /* @__PURE__ */ i(Ui, {}) + children: /* @__PURE__ */ s(ul, {}) } ), - /* @__PURE__ */ i( - Ln, + /* @__PURE__ */ s( + Un, { - onClick: () => Or( + onClick: () => Pr( [l], "unapproved", - t, + e, n, r, o ), value: "unapproved", - children: /* @__PURE__ */ i(Gi, {}) + children: /* @__PURE__ */ s(wl, {}) } ), - /* @__PURE__ */ i( - Ln, + /* @__PURE__ */ s( + Un, { - onClick: () => Or( + onClick: () => Pr( [l], "unknown", - t, + e, n, r, o ), value: "unknown", - children: /* @__PURE__ */ i(Hi, {}) + children: /* @__PURE__ */ s(fl, {}) } ) ] }); } -}), Om = Object.freeze([ +}), Eh = Object.freeze([ "%webView_inventory_all%", "%webView_inventory_approved%", "%webView_inventory_unapproved%", @@ -2214,29 +2215,29 @@ const sr = (e) => e === "asc" ? /* @__PURE__ */ i(Xi, { className: "tw-ms-2 tw-h "%webView_inventory_show_additional_items%", "%webView_inventory_occurrences_table_header_reference%", "%webView_inventory_occurrences_table_header_occurrence%" -]), Oc = (e, t, n) => { - let r = e; - return t !== "all" && (r = r.filter( - (o) => t === "approved" && o.status === "approved" || t === "unapproved" && o.status === "unapproved" || t === "unknown" && o.status === "unknown" +]), Zc = (t, e, n) => { + let r = t; + return e !== "all" && (r = r.filter( + (o) => e === "approved" && o.status === "approved" || e === "unapproved" && o.status === "unapproved" || e === "unknown" && o.status === "unknown" )), n !== "" && (r = r.filter((o) => o.items[0].includes(n))), r; -}, Rc = (e, t, n, r, o) => { - if (!e) +}, Qc = (t, e, n, r, o) => { + if (!t) return []; const a = []; - let s = t.bookNum, l = t.chapterNum, c = t.verseNum; - return kc(e).forEach((p) => { - p.startsWith("\\id") && (s = Ec(p), l = 0, c = 0), p.startsWith("\\c") && (l = Ko(p), c = 0), p.startsWith("\\v") && (c = Ko(p), l === 0 && (l = t.chapterNum)); + let i = e.bookNum, l = e.chapterNum, c = e.verseNum; + return Yc(t).forEach((p) => { + p.startsWith("\\id") && (i = Wc(p), l = 0, c = 0), p.startsWith("\\c") && (l = ea(p), c = 0), p.startsWith("\\v") && (c = ea(p), l === 0 && (l = e.chapterNum)); let m = o.exec(p) ?? void 0; for (; m; ) { const w = []; m.forEach((h) => w.push(h)); - const b = m.index, v = a.find((h) => to(h.items, w)), f = { + const g = m.index, v = a.find((h) => ao(h.items, w)), f = { reference: { - bookNum: s !== void 0 ? s : -1, + bookNum: i !== void 0 ? i : -1, chapterNum: l !== void 0 ? l : -1, verseNum: c !== void 0 ? c : -1 }, - text: sl(p, Math.max(0, b - 25), Math.min(b + 25, p.length)) + text: _l(p, Math.max(0, g - 25), Math.min(g + 25, p.length)) }; if (v) v.count += 1, v.occurrences.push(f); @@ -2244,7 +2245,7 @@ const sr = (e) => e === "asc" ? /* @__PURE__ */ i(Xi, { className: "tw-ms-2 tw-h const h = { items: w, count: 1, - status: Tc(w[0], n, r), + status: qc(w[0], n, r), occurrences: [f] }; a.push(h); @@ -2252,143 +2253,143 @@ const sr = (e) => e === "asc" ? /* @__PURE__ */ i(Xi, { className: "tw-ms-2 tw-h m = o.exec(p) ?? void 0; } }), a; -}, Je = (e, t) => e[t] ?? t; -function Rm({ - scriptureReference: e, - setScriptureReference: t, +}, Jt = (t, e) => t[e] ?? e; +function Sh({ + scriptureReference: t, + setScriptureReference: e, localizedStrings: n, extractItems: r, additionalItemsLabels: o, approvedItems: a, - unapprovedItems: s, + unapprovedItems: i, text: l, scope: c, onScopeChange: d, columns: p }) { - const m = Je(n, "%webView_inventory_all%"), w = Je(n, "%webView_inventory_approved%"), b = Je(n, "%webView_inventory_unapproved%"), v = Je(n, "%webView_inventory_unknown%"), f = Je(n, "%webView_inventory_scope_currentBook%"), h = Je(n, "%webView_inventory_scope_chapter%"), E = Je(n, "%webView_inventory_scope_verse%"), A = Je(n, "%webView_inventory_filter_text%"), O = Je( + const m = Jt(n, "%webView_inventory_all%"), w = Jt(n, "%webView_inventory_approved%"), g = Jt(n, "%webView_inventory_unapproved%"), v = Jt(n, "%webView_inventory_unknown%"), f = Jt(n, "%webView_inventory_scope_currentBook%"), h = Jt(n, "%webView_inventory_scope_chapter%"), E = Jt(n, "%webView_inventory_scope_verse%"), _ = Jt(n, "%webView_inventory_filter_text%"), C = Jt( n, "%webView_inventory_show_additional_items%" - ), [k, g] = ue(!1), [_, L] = ue("all"), [H, C] = ue(""), [P, N] = ue([]), B = _e(() => l ? r instanceof RegExp ? Rc( + ), [S, b] = ut(!1), [I, z] = ut("all"), [H, O] = ut(""), [$, k] = ut([]), B = $t(() => l ? r instanceof RegExp ? Qc( l, - e, + t, a, - s, + i, r - ) : r(l, e, a, s) : [], [l, r, e, a, s]), D = _e(() => { - if (k) + ) : r(l, t, a, i) : [], [l, r, t, a, i]), D = $t(() => { + if (S) return B; const y = []; - return B.forEach((S) => { - const z = S.items[0], F = y.find( - (V) => V.items[0] === z + return B.forEach((R) => { + const L = R.items[0], F = y.find( + (V) => V.items[0] === L ); - F ? (F.count += S.count, F.occurrences = F.occurrences.concat(S.occurrences)) : y.push({ - items: [z], - count: S.count, - occurrences: S.occurrences, - status: S.status + F ? (F.count += R.count, F.occurrences = F.occurrences.concat(R.occurrences)) : y.push({ + items: [L], + count: R.count, + occurrences: R.occurrences, + status: R.status }); }), y; - }, [k, B]), J = _e(() => Oc(D, _, H), [D, _, H]), q = _e(() => { - var z, F; - if (!k) + }, [S, B]), J = $t(() => Zc(D, I, H), [D, I, H]), q = $t(() => { + var L, F; + if (!S) return p; - const y = (z = o == null ? void 0 : o.tableHeaders) == null ? void 0 : z.length; + const y = (L = o == null ? void 0 : o.tableHeaders) == null ? void 0 : L.length; if (!y) return p; - const S = []; + const R = []; for (let V = 0; V < y; V++) - S.push( - Sc( + R.push( + Jc( ((F = o == null ? void 0 : o.tableHeaders) == null ? void 0 : F[V]) || "Additional Item", V + 1 ) ); - return [...S, ...p]; - }, [o == null ? void 0 : o.tableHeaders, p, k]); - at(() => { - N([]); + return [...R, ...p]; + }, [o == null ? void 0 : o.tableHeaders, p, S]); + ae(() => { + k([]); }, [J]); - const U = (y, S) => { - S.setRowSelection(() => { - const z = {}; - return z[y.index] = !0, z; - }), N(y.original.items); - }, ee = (y) => { + const U = (y, R) => { + R.setRowSelection(() => { + const L = {}; + return L[y.index] = !0, L; + }), k(y.original.items); + }, tt = (y) => { if (y === "book" || y === "chapter" || y === "verse") d(y); else throw new Error(`Invalid scope value: ${y}`); - }, ae = (y) => { + }, at = (y) => { if (y === "all" || y === "approved" || y === "unapproved" || y === "unknown") - L(y); + z(y); else throw new Error(`Invalid status filter value: ${y}`); - }, re = _e(() => { - if (D.length === 0 || P.length === 0) + }, rt = $t(() => { + if (D.length === 0 || $.length === 0) return []; - const y = D.filter((S) => to( - k ? S.items : [S.items[0]], - P + const y = D.filter((R) => ao( + S ? R.items : [R.items[0]], + $ )); if (y.length > 1) throw new Error("Selected item is not unique"); return y[0].occurrences; - }, [P, k, D]); + }, [$, S, D]); return /* @__PURE__ */ x("div", { className: "pr-twp tw-flex tw-h-full tw-flex-col", children: [ /* @__PURE__ */ x("div", { className: "tw-flex tw-items-stretch", children: [ /* @__PURE__ */ x( - fn, + gn, { - onValueChange: (y) => ae(y), - defaultValue: _, + onValueChange: (y) => at(y), + defaultValue: I, children: [ - /* @__PURE__ */ i(Mt, { className: "tw-m-1", children: /* @__PURE__ */ i(mn, { placeholder: "Select filter" }) }), - /* @__PURE__ */ x(Bt, { children: [ - /* @__PURE__ */ i(Ue, { value: "all", children: m }), - /* @__PURE__ */ i(Ue, { value: "approved", children: w }), - /* @__PURE__ */ i(Ue, { value: "unapproved", children: b }), - /* @__PURE__ */ i(Ue, { value: "unknown", children: v }) + /* @__PURE__ */ s(De, { className: "tw-m-1", children: /* @__PURE__ */ s(bn, { placeholder: "Select filter" }) }), + /* @__PURE__ */ x(Be, { children: [ + /* @__PURE__ */ s(Gt, { value: "all", children: m }), + /* @__PURE__ */ s(Gt, { value: "approved", children: w }), + /* @__PURE__ */ s(Gt, { value: "unapproved", children: g }), + /* @__PURE__ */ s(Gt, { value: "unknown", children: v }) ] }) ] } ), - /* @__PURE__ */ x(fn, { onValueChange: (y) => ee(y), defaultValue: c, children: [ - /* @__PURE__ */ i(Mt, { className: "tw-m-1", children: /* @__PURE__ */ i(mn, { placeholder: "Select scope" }) }), - /* @__PURE__ */ x(Bt, { children: [ - /* @__PURE__ */ i(Ue, { value: "book", children: f }), - /* @__PURE__ */ i(Ue, { value: "chapter", children: h }), - /* @__PURE__ */ i(Ue, { value: "verse", children: E }) + /* @__PURE__ */ x(gn, { onValueChange: (y) => tt(y), defaultValue: c, children: [ + /* @__PURE__ */ s(De, { className: "tw-m-1", children: /* @__PURE__ */ s(bn, { placeholder: "Select scope" }) }), + /* @__PURE__ */ x(Be, { children: [ + /* @__PURE__ */ s(Gt, { value: "book", children: f }), + /* @__PURE__ */ s(Gt, { value: "chapter", children: h }), + /* @__PURE__ */ s(Gt, { value: "verse", children: E }) ] }) ] }), - /* @__PURE__ */ i( - xn, + /* @__PURE__ */ s( + Ye, { className: "tw-m-1 tw-rounded-md tw-border", - placeholder: A, + placeholder: _, value: H, onChange: (y) => { - C(y.target.value); + O(y.target.value); } } ), o && /* @__PURE__ */ x("div", { className: "tw-m-1 tw-flex tw-items-center tw-rounded-md tw-border", children: [ - /* @__PURE__ */ i( - io, + /* @__PURE__ */ s( + uo, { className: "tw-m-1", - checked: k, + checked: S, onCheckedChange: (y) => { - N([]), g(y); + k([]), b(y); } } ), - /* @__PURE__ */ i(He, { className: "tw-m-1 tw-flex-shrink-0 tw-whitespace-nowrap", children: (o == null ? void 0 : o.checkboxText) ?? O }) + /* @__PURE__ */ s(Xt, { className: "tw-m-1 tw-flex-shrink-0 tw-whitespace-nowrap", children: (o == null ? void 0 : o.checkboxText) ?? C }) ] }) ] }), - /* @__PURE__ */ i("div", { className: "tw-m-1 tw-flex-1 tw-overflow-auto tw-rounded-md tw-border", children: /* @__PURE__ */ i( - xc, + /* @__PURE__ */ s("div", { className: "tw-m-1 tw-flex-1 tw-overflow-auto tw-rounded-md tw-border", children: /* @__PURE__ */ s( + Hc, { columns: q, data: J, @@ -2396,81 +2397,81 @@ function Rm({ stickyHeader: !0 } ) }), - re.length > 0 && /* @__PURE__ */ i("div", { className: "tw-m-1 tw-flex-1 tw-overflow-auto tw-rounded-md tw-border", children: /* @__PURE__ */ i( - Nc, + rt.length > 0 && /* @__PURE__ */ s("div", { className: "tw-m-1 tw-flex-1 tw-overflow-auto tw-rounded-md tw-border", children: /* @__PURE__ */ s( + Xc, { - occurrenceData: re, - setScriptureReference: t, + occurrenceData: rt, + setScriptureReference: e, localizedStrings: n } ) }) ] }); } -function Pc({ onSearch: e, placeholder: t, isFullWidth: n }) { - const [r, o] = ue(""), a = (s) => { - o(s), e(s); +function td({ onSearch: t, placeholder: e, isFullWidth: n }) { + const [r, o] = ut(""), a = (i) => { + o(i), t(i); }; - return /* @__PURE__ */ i( - xn, + return /* @__PURE__ */ s( + Ye, { - className: T( + className: N( "tw-flex tw-h-10 tw-rounded-md tw-border tw-border-input tw-bg-background tw-px-3 tw-py-2 tw-text-sm tw-ring-offset-background file:tw-border-0 file:tw-bg-transparent file:tw-text-sm file:tw-font-medium placeholder:tw-text-muted-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-[color:hsl(240,5%,64.9%)] focus-visible:tw-ring-offset-2 disabled:tw-cursor-not-allowed disabled:tw-opacity-50", { "tw-w-full": n } ), - placeholder: t, + placeholder: e, value: r, - onChange: (s) => a(s.target.value) + onChange: (i) => a(i.target.value) } ); } -const xs = I.forwardRef(({ className: e, ...t }, n) => /* @__PURE__ */ i( - Oe.Root, +const Oi = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( + Rt.Root, { orientation: "vertical", ref: n, - className: T("tw-flex tw-gap-1 tw-rounded-md tw-text-muted-foreground", e), - ...t + className: N("tw-flex tw-gap-1 tw-rounded-md tw-text-muted-foreground", t), + ...e } )); -xs.displayName = Oe.List.displayName; -const Ns = I.forwardRef(({ className: e, ...t }, n) => /* @__PURE__ */ i( - Oe.List, +Oi.displayName = Rt.List.displayName; +const Ri = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( + Rt.List, { ref: n, - className: T( + className: N( "tw-flex-fit tw-mlk-items-center tw-w-[124px] tw-justify-center tw-rounded-md tw-bg-muted tw-p-1 tw-text-muted-foreground", - e + t ), - ...t + ...e } )); -Ns.displayName = Oe.List.displayName; -const _c = I.forwardRef(({ className: e, ...t }, n) => /* @__PURE__ */ i( - Oe.Trigger, +Ri.displayName = Rt.List.displayName; +const ed = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( + Rt.Trigger, { ref: n, - ...t, - className: T( + ...e, + className: N( "overflow-clip tw-inline-flex tw-w-[116px] tw-cursor-pointer tw-items-center tw-justify-center tw-break-words tw-rounded-sm tw-border-0 tw-bg-muted tw-px-3 tw-py-1.5 tw-text-sm tw-font-medium tw-text-inherit tw-ring-offset-background tw-transition-all hover:tw-text-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50 data-[state=active]:tw-bg-background data-[state=active]:tw-text-foreground data-[state=active]:tw-shadow-sm", - e + t ) } -)), ks = I.forwardRef(({ className: e, ...t }, n) => /* @__PURE__ */ i( - Oe.Content, +)), _i = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( + Rt.Content, { ref: n, - className: T( + className: N( // Removed tw-mt-2 because Sebastian said so "tw-ms-5 tw-flex-grow tw-text-foreground tw-ring-offset-background focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2", - e + t ), - ...t + ...e } )); -ks.displayName = Oe.Content.displayName; -function Pm({ - tabList: e, - onSearch: t, +_i.displayName = Rt.Content.displayName; +function Th({ + tabList: t, + onSearch: e, searchPlaceholder: n, headerTitle: r, isSearchBarFullWidth: o = !1, @@ -2478,53 +2479,717 @@ function Pm({ }) { return /* @__PURE__ */ x("div", { className: "pr-twp", children: [ /* @__PURE__ */ x("div", { className: "tw-sticky tw-top-0 tw-space-y-2 tw-pb-2", children: [ - r ? /* @__PURE__ */ i("h1", { children: r }) : "", - /* @__PURE__ */ i( - Pc, + r ? /* @__PURE__ */ s("h1", { children: r }) : "", + /* @__PURE__ */ s( + td, { isFullWidth: o, - onSearch: t, + onSearch: e, placeholder: n } ) ] }), - /* @__PURE__ */ x(xs, { dir: a, children: [ - /* @__PURE__ */ i(Ns, { children: e.map((s) => /* @__PURE__ */ i(_c, { value: s.value, children: s.value }, s.key)) }), - e.map((s) => /* @__PURE__ */ i(ks, { value: s.value, children: s.content }, s.key)) + /* @__PURE__ */ x(Oi, { dir: a, children: [ + /* @__PURE__ */ s(Ri, { children: t.map((i) => /* @__PURE__ */ s(ed, { value: i.value, children: i.value }, i.key)) }), + t.map((i) => /* @__PURE__ */ s(_i, { value: i.value, children: i.content }, i.key)) + ] }) + ] }); +} +const wo = T.forwardRef(({ className: t, orientation: e = "horizontal", decorative: n = !0, ...r }, o) => /* @__PURE__ */ s( + ni.Root, + { + ref: o, + decorative: n, + orientation: e, + className: N( + "pr-twp tw-shrink-0 tw-bg-border", + e === "horizontal" ? "tw-h-[1px] tw-w-full" : "tw-h-full tw-w-[1px]", + t + ), + ...r + } +)); +wo.displayName = ni.Root.displayName; +const nd = vt.Root, rd = vt.Portal, Pi = M.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( + vt.Overlay, + { + className: N( + "tw-fixed tw-inset-0 tw-z-50 tw-bg-black/80 data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0", + t + ), + ...e, + ref: n + } +)); +Pi.displayName = vt.Overlay.displayName; +const od = Xe( + "pr-twp tw-fixed tw-z-50 tw-gap-4 tw-bg-background tw-p-6 tw-shadow-lg tw-transition tw-ease-in-out data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-duration-300 data-[state=open]:tw-duration-500", + { + variants: { + side: { + top: "tw-inset-x-0 tw-top-0 tw-border-b data-[state=closed]:tw-slide-out-to-top data-[state=open]:tw-slide-in-from-top", + bottom: "tw-inset-x-0 tw-bottom-0 tw-border-t data-[state=closed]:tw-slide-out-to-bottom data-[state=open]:tw-slide-in-from-bottom", + left: "tw-inset-y-0 tw-left-0 tw-h-full tw-w-3/4 tw-border-r data-[state=closed]:tw-slide-out-to-left data-[state=open]:tw-slide-in-from-left sm:tw-max-w-sm", + right: "tw-inset-y-0 tw-right-0 tw-h-full tw-w-3/4 tw- tw-border-l data-[state=closed]:tw-slide-out-to-right data-[state=open]:tw-slide-in-from-right sm:tw-max-w-sm" + } + }, + defaultVariants: { + side: "right" + } + } +), $i = M.forwardRef(({ side: t = "right", className: e, children: n, ...r }, o) => /* @__PURE__ */ x(rd, { children: [ + /* @__PURE__ */ s(Pi, {}), + /* @__PURE__ */ x(vt.Content, { ref: o, className: N(od({ side: t }), e), ...r, children: [ + n, + /* @__PURE__ */ x(vt.Close, { className: "tw-absolute tw-right-4 tw-top-4 tw-rounded-sm tw-opacity-70 tw-ring-offset-background tw-transition-opacity hover:tw-opacity-100 focus:tw-outline-none focus:tw-ring-2 focus:tw-ring-ring focus:tw-ring-offset-2 disabled:tw-pointer-events-none data-[state=open]:tw-bg-secondary", children: [ + /* @__PURE__ */ s(Ka, { className: "tw-h-4 tw-w-4" }), + /* @__PURE__ */ s("span", { className: "tw-sr-only", children: "Close" }) ] }) + ] }) +] })); +$i.displayName = vt.Content.displayName; +const ad = M.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( + vt.Title, + { + ref: n, + className: N("tw-text-lg tw-font-semibold tw-text-foreground", t), + ...e + } +)); +ad.displayName = vt.Title.displayName; +const id = M.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( + vt.Description, + { + ref: n, + className: N("tw-text-sm tw-text-muted-foreground", t), + ...e + } +)); +id.displayName = vt.Description.displayName; +function na({ className: t, ...e }) { + return /* @__PURE__ */ s( + "div", + { + className: N("pr-twp tw-animate-pulse tw-rounded-md tw-bg-muted", t), + ...e + } + ); +} +const sd = En.Provider, ld = En.Root, cd = En.Trigger, Ii = T.forwardRef(({ className: t, sideOffset: e = 4, ...n }, r) => /* @__PURE__ */ s( + En.Content, + { + ref: r, + sideOffset: e, + className: N( + "pr-twp tw-z-50 tw-overflow-hidden tw-rounded-md tw-border tw-bg-popover tw-px-3 tw-py-1.5 tw-text-sm tw-text-popover-foreground tw-shadow-md tw-animate-in tw-fade-in-0 tw-zoom-in-95 data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=closed]:tw-zoom-out-95 data-[side=bottom]:tw-slide-in-from-top-2 data-[side=left]:tw-slide-in-from-right-2 data-[side=right]:tw-slide-in-from-left-2 data-[side=top]:tw-slide-in-from-bottom-2", + t + ), + ...n + } +)); +Ii.displayName = En.Content.displayName; +const $r = 768; +function dd() { + const [t, e] = M.useState(void 0); + return M.useEffect(() => { + const n = window.matchMedia(`(max-width: ${$r - 1}px)`), r = () => { + e(window.innerWidth < $r); + }; + return n.addEventListener("change", r), e(window.innerWidth < $r), () => n.removeEventListener("change", r); + }, []), !!t; +} +const pd = "sidebar:state", ud = 60 * 60 * 24 * 7, wd = "16rem", fd = "18rem", md = "3rem", hd = "b", Ai = T.createContext(void 0); +function cr() { + const t = T.useContext(Ai); + if (!t) + throw new Error("useSidebar must be used within a SidebarProvider."); + return t; +} +const Mi = T.forwardRef( + ({ + defaultOpen: t = !0, + open: e, + onOpenChange: n, + className: r, + style: o, + children: a, + ...i + }, l) => { + const c = dd(), [d, p] = T.useState(!1), [m, w] = T.useState(t), g = e ?? m, v = T.useCallback( + (_) => { + const C = typeof _ == "function" ? _(g) : _; + n ? n(C) : w(C), document.cookie = `${pd}=${C}; path=/; max-age=${ud}`; + }, + [n, g] + ), f = T.useCallback(() => c ? p((_) => !_) : v((_) => !_), [c, v, p]); + T.useEffect(() => { + const _ = (C) => { + C.key === hd && (C.metaKey || C.ctrlKey) && (C.preventDefault(), f()); + }; + return window.addEventListener("keydown", _), () => window.removeEventListener("keydown", _); + }, [f]); + const h = g ? "expanded" : "collapsed", E = T.useMemo( + () => ({ + state: h, + open: g, + setOpen: v, + isMobile: c, + openMobile: d, + setOpenMobile: p, + toggleSidebar: f + }), + [h, g, v, c, d, p, f] + ); + return /* @__PURE__ */ s(Ai.Provider, { value: E, children: /* @__PURE__ */ s(sd, { delayDuration: 0, children: /* @__PURE__ */ s( + "div", + { + style: ( + // eslint-disable-next-line no-type-assertion/no-type-assertion + { + "--sidebar-width": wd, + "--sidebar-width-icon": md, + ...o + } + ), + className: N( + "tw-group/sidebar-wrapper pr-twp tw-flex tw-min-h-svh tw-w-full has-[[data-variant=inset]]:tw-bg-sidebar", + r + ), + ref: l, + ...i, + children: a + } + ) }) }); + } +); +Mi.displayName = "SidebarProvider"; +const Di = T.forwardRef( + ({ + side: t = "left", + variant: e = "sidebar", + collapsible: n = "offcanvas", + className: r, + children: o, + ...a + }, i) => { + const { isMobile: l, state: c, openMobile: d, setOpenMobile: p } = cr(); + return n === "none" ? /* @__PURE__ */ s( + "div", + { + className: N( + "tw-flex tw-h-full tw-w-[--sidebar-width] tw-flex-col tw-bg-sidebar tw-text-sidebar-foreground", + r + ), + ref: i, + ...a, + children: o + } + ) : l ? /* @__PURE__ */ s(nd, { open: d, onOpenChange: p, ...a, children: /* @__PURE__ */ s( + $i, + { + "data-sidebar": "sidebar", + "data-mobile": "true", + className: "tw-w-[--sidebar-width] tw-bg-sidebar tw-p-0 tw-text-sidebar-foreground [&>button]:tw-hidden", + style: ( + // eslint-disable-next-line no-type-assertion/no-type-assertion + { + "--sidebar-width": fd + } + ), + side: t, + children: /* @__PURE__ */ s("div", { className: "tw-flex tw-h-full tw-w-full tw-flex-col", children: o }) + } + ) }) : /* @__PURE__ */ x( + "div", + { + ref: i, + className: "tw-group tw-peer tw-hidden tw-text-sidebar-foreground md:tw-block", + "data-state": c, + "data-collapsible": c === "collapsed" ? n : "", + "data-variant": e, + "data-side": t, + children: [ + /* @__PURE__ */ s( + "div", + { + className: N( + "tw-relative tw-h-svh tw-w-[--sidebar-width] tw-bg-transparent tw-transition-[width] tw-duration-200 tw-ease-linear", + "group-data-[collapsible=offcanvas]:tw-w-0", + "group-data-[side=right]:tw-rotate-180", + e === "floating" || e === "inset" ? "group-data-[collapsible=icon]:tw-w-[calc(var(--sidebar-width-icon)_+_theme(spacing.4))]" : "group-data-[collapsible=icon]:tw-w-[--sidebar-width-icon]" + ) + } + ), + /* @__PURE__ */ s( + "div", + { + className: N( + // Switched tw-fixed to tw-absolute here to scope the sidebar inside of it's container + "tw-absolute tw-inset-y-0 tw-z-10 tw-hidden tw-h-svh tw-w-[--sidebar-width] tw-transition-[left,right,width] tw-duration-200 tw-ease-linear md:tw-flex", + t === "left" ? "tw-left-0 group-data-[collapsible=offcanvas]:tw-left-[calc(var(--sidebar-width)*-1)]" : "tw-right-0 group-data-[collapsible=offcanvas]:tw-right-[calc(var(--sidebar-width)*-1)]", + // Adjust the padding for floating and inset variants. + e === "floating" || e === "inset" ? "tw-p-2 group-data-[collapsible=icon]:tw-w-[calc(var(--sidebar-width-icon)_+_theme(spacing.4)_+2px)]" : "group-data-[collapsible=icon]:tw-w-[--sidebar-width-icon] group-data-[side=left]:tw-border-r group-data-[side=right]:tw-border-l", + r + ), + ...a, + children: /* @__PURE__ */ s( + "div", + { + "data-sidebar": "sidebar", + className: "tw-flex tw-h-full tw-w-full tw-flex-col tw-bg-sidebar group-data-[variant=floating]:tw-rounded-lg group-data-[variant=floating]:tw-border group-data-[variant=floating]:tw-border-sidebar-border group-data-[variant=floating]:tw-shadow", + children: o + } + ) + } + ) + ] + } + ); + } +); +Di.displayName = "Sidebar"; +const gd = T.forwardRef(({ className: t, onClick: e, ...n }, r) => { + const { toggleSidebar: o } = cr(); + return /* @__PURE__ */ x( + gt, + { + ref: r, + "data-sidebar": "trigger", + variant: "ghost", + size: "icon", + className: N("tw-h-7 tw-w-7", t), + onClick: (a) => { + e == null || e(a), o(); + }, + ...n, + children: [ + /* @__PURE__ */ s(bl, {}), + /* @__PURE__ */ s("span", { className: "tw-sr-only", children: "Toggle Sidebar" }) + ] + } + ); +}); +gd.displayName = "SidebarTrigger"; +const bd = T.forwardRef( + ({ className: t, ...e }, n) => { + const { toggleSidebar: r } = cr(); + return /* @__PURE__ */ s( + "button", + { + type: "button", + ref: n, + "data-sidebar": "rail", + "aria-label": "Toggle Sidebar", + tabIndex: -1, + onClick: r, + title: "Toggle Sidebar", + className: N( + "tw-absolute tw-inset-y-0 tw-z-20 tw-hidden tw-w-4 tw--translate-x-1/2 tw-transition-all tw-ease-linear after:tw-absolute after:tw-inset-y-0 after:tw-left-1/2 after:tw-w-[2px] hover:after:tw-bg-sidebar-border group-data-[side=left]:tw--right-4 group-data-[side=right]:tw-left-0 sm:tw-flex", + "[[data-side=left]_&]:tw-cursor-w-resize [[data-side=right]_&]:tw-cursor-e-resize", + "[[data-side=left][data-state=collapsed]_&]:tw-cursor-e-resize [[data-side=right][data-state=collapsed]_&]:tw-cursor-w-resize", + "group-data-[collapsible=offcanvas]:tw-translate-x-0 group-data-[collapsible=offcanvas]:after:tw-left-full group-data-[collapsible=offcanvas]:hover:tw-bg-sidebar", + "[[data-side=left][data-collapsible=offcanvas]_&]:tw--right-2", + "[[data-side=right][data-collapsible=offcanvas]_&]:tw--left-2", + t + ), + ...e + } + ); + } +); +bd.displayName = "SidebarRail"; +const Bi = T.forwardRef( + ({ className: t, ...e }, n) => /* @__PURE__ */ s( + "main", + { + ref: n, + className: N( + "tw-relative tw-flex tw-min-h-svh tw-flex-1 tw-flex-col tw-bg-background", + "peer-data-[variant=inset]:tw-min-h-[calc(100svh-theme(spacing.4))] md:peer-data-[variant=inset]:tw-m-2 md:peer-data-[state=collapsed]:peer-data-[variant=inset]:tw-ml-2 md:peer-data-[variant=inset]:tw-ml-0 md:peer-data-[variant=inset]:tw-rounded-xl md:peer-data-[variant=inset]:tw-shadow", + t + ), + ...e + } + ) +); +Bi.displayName = "SidebarInset"; +const vd = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( + Ye, + { + ref: n, + "data-sidebar": "input", + className: N( + "tw-h-8 tw-w-full tw-bg-background tw-shadow-none focus-visible:tw-ring-2 focus-visible:tw-ring-sidebar-ring", + t + ), + ...e + } +)); +vd.displayName = "SidebarInput"; +const yd = T.forwardRef( + ({ className: t, ...e }, n) => /* @__PURE__ */ s( + "div", + { + ref: n, + "data-sidebar": "header", + className: N("tw-flex tw-flex-col tw-gap-2 tw-p-2", t), + ...e + } + ) +); +yd.displayName = "SidebarHeader"; +const xd = T.forwardRef( + ({ className: t, ...e }, n) => /* @__PURE__ */ s( + "div", + { + ref: n, + "data-sidebar": "footer", + className: N("tw-flex tw-flex-col tw-gap-2 tw-p-2", t), + ...e + } + ) +); +xd.displayName = "SidebarFooter"; +const Nd = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( + wo, + { + ref: n, + "data-sidebar": "separator", + className: N("tw-mx-2 tw-w-auto tw-bg-sidebar-border", t), + ...e + } +)); +Nd.displayName = "SidebarSeparator"; +const ji = T.forwardRef( + ({ className: t, ...e }, n) => /* @__PURE__ */ s( + "div", + { + ref: n, + "data-sidebar": "content", + className: N( + "tw-flex tw-min-h-0 tw-flex-1 tw-flex-col tw-gap-2 tw-overflow-auto group-data-[collapsible=icon]:tw-overflow-hidden", + t + ), + ...e + } + ) +); +ji.displayName = "SidebarContent"; +const Vi = T.forwardRef( + ({ className: t, ...e }, n) => /* @__PURE__ */ s( + "div", + { + ref: n, + "data-sidebar": "group", + className: N("tw-relative tw-flex tw-w-full tw-min-w-0 tw-flex-col tw-p-2", t), + ...e + } + ) +); +Vi.displayName = "SidebarGroup"; +const zi = T.forwardRef(({ className: t, asChild: e = !1, ...n }, r) => /* @__PURE__ */ s( + e ? He : "div", + { + ref: r, + "data-sidebar": "group-label", + className: N( + "tw-flex tw-h-8 tw-shrink-0 tw-items-center tw-rounded-md tw-px-2 tw-text-xs tw-font-medium tw-text-sidebar-foreground/70 tw-outline-none tw-ring-sidebar-ring tw-transition-[margin,opa] tw-duration-200 tw-ease-linear focus-visible:tw-ring-2 [&>svg]:tw-size-4 [&>svg]:tw-shrink-0", + "group-data-[collapsible=icon]:tw--mt-8 group-data-[collapsible=icon]:tw-opacity-0", + t + ), + ...n + } +)); +zi.displayName = "SidebarGroupLabel"; +const kd = T.forwardRef(({ className: t, asChild: e = !1, ...n }, r) => /* @__PURE__ */ s( + e ? He : "button", + { + ref: r, + "data-sidebar": "group-action", + className: N( + "tw-absolute tw-right-3 tw-top-3.5 tw-flex tw-aspect-square tw-w-5 tw-items-center tw-justify-center tw-rounded-md tw-p-0 tw-text-sidebar-foreground tw-outline-none tw-ring-sidebar-ring tw-transition-transform hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground focus-visible:tw-ring-2 [&>svg]:tw-size-4 [&>svg]:tw-shrink-0", + // Increases the hit area of the button on mobile. + "after:tw-absolute after:tw--inset-2 after:md:tw-hidden", + "group-data-[collapsible=icon]:tw-hidden", + t + ), + ...n + } +)); +kd.displayName = "SidebarGroupAction"; +const Li = T.forwardRef( + ({ className: t, ...e }, n) => /* @__PURE__ */ s( + "div", + { + ref: n, + "data-sidebar": "group-content", + className: N("tw-w-full tw-text-sm", t), + ...e + } + ) +); +Li.displayName = "SidebarGroupContent"; +const Fi = T.forwardRef( + ({ className: t, ...e }, n) => /* @__PURE__ */ s( + "ul", + { + ref: n, + "data-sidebar": "menu", + className: N("tw-flex tw-w-full tw-min-w-0 tw-flex-col tw-gap-1", t), + ...e + } + ) +); +Fi.displayName = "SidebarMenu"; +const Ui = T.forwardRef( + ({ className: t, ...e }, n) => /* @__PURE__ */ s( + "li", + { + ref: n, + "data-sidebar": "menu-item", + className: N("tw-group/menu-item tw-relative", t), + ...e + } + ) +); +Ui.displayName = "SidebarMenuItem"; +const Ed = Xe( + "tw-peer/menu-button tw-flex tw-w-full tw-items-center tw-gap-2 tw-overflow-hidden tw-rounded-md tw-p-2 tw-text-left tw-text-sm tw-outline-none tw-ring-sidebar-ring tw-transition-[width,height,padding] hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground focus-visible:tw-ring-2 active:tw-bg-sidebar-accent active:tw-text-sidebar-accent-foreground disabled:tw-pointer-events-none disabled:tw-opacity-50 tw-group-has-[[data-sidebar=menu-action]]/menu-item:pr-8 aria-disabled:tw-pointer-events-none aria-disabled:tw-opacity-50 data-[active=true]:tw-bg-sidebar-accent data-[active=true]:tw-font-medium data-[active=true]:tw-text-sidebar-accent-foreground data-[state=open]:hover:tw-bg-sidebar-accent data-[state=open]:hover:tw-text-sidebar-accent-foreground group-data-[collapsible=icon]:tw-!size-8 group-data-[collapsible=icon]:tw-!p-2 [&>span:last-child]:tw-truncate [&>svg]:tw-size-4 [&>svg]:tw-shrink-0", + { + variants: { + variant: { + default: "hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground", + outline: "tw-bg-background tw-shadow-[0_0_0_1px_hsl(var(--sidebar-border))] hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground hover:tw-shadow-[0_0_0_1px_hsl(var(--sidebar-accent))]" + }, + size: { + default: "tw-h-8 tw-text-sm", + sm: "tw-h-7 tw-text-xs", + lg: "tw-h-12 tw-text-sm group-data-[collapsible=icon]:tw-!p-0" + } + }, + defaultVariants: { + variant: "default", + size: "default" + } + } +), Gi = T.forwardRef( + ({ + asChild: t = !1, + isActive: e = !1, + variant: n = "default", + size: r = "default", + tooltip: o, + className: a, + ...i + }, l) => { + const c = t ? He : "button", { isMobile: d, state: p } = cr(), m = /* @__PURE__ */ s( + c, + { + ref: l, + "data-sidebar": "menu-button", + "data-size": r, + "data-active": e, + className: N(Ed({ variant: n, size: r }), a), + ...i + } + ); + return o ? (typeof o == "string" && (o = { + children: o + }), /* @__PURE__ */ x(ld, { children: [ + /* @__PURE__ */ s(cd, { asChild: !0, children: m }), + /* @__PURE__ */ s( + Ii, + { + side: "right", + align: "center", + hidden: p !== "collapsed" || d, + ...o + } + ) + ] })) : m; + } +); +Gi.displayName = "SidebarMenuButton"; +const Sd = T.forwardRef(({ className: t, asChild: e = !1, showOnHover: n = !1, ...r }, o) => /* @__PURE__ */ s( + e ? He : "button", + { + ref: o, + "data-sidebar": "menu-action", + className: N( + "tw-peer-hover/menu-button:text-sidebar-accent-foreground tw-absolute tw-right-1 tw-top-1.5 tw-flex tw-aspect-square tw-w-5 tw-items-center tw-justify-center tw-rounded-md tw-p-0 tw-text-sidebar-foreground tw-outline-none tw-ring-sidebar-ring tw-transition-transform hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground focus-visible:tw-ring-2 [&>svg]:tw-size-4 [&>svg]:tw-shrink-0", + // Increases the hit area of the button on mobile. + "after:tw-absolute after:tw--inset-2 after:md:tw-hidden", + "tw-peer-data-[size=sm]/menu-button:top-1", + "tw-peer-data-[size=default]/menu-button:top-1.5", + "tw-peer-data-[size=lg]/menu-button:top-2.5", + "group-data-[collapsible=icon]:tw-hidden", + n && "tw-group-focus-within/menu-item:opacity-100 tw-group-hover/menu-item:opacity-100 tw-peer-data-[active=true]/menu-button:text-sidebar-accent-foreground data-[state=open]:tw-opacity-100 md:tw-opacity-0", + t + ), + ...r + } +)); +Sd.displayName = "SidebarMenuAction"; +const Td = T.forwardRef( + ({ className: t, ...e }, n) => /* @__PURE__ */ s( + "div", + { + ref: n, + "data-sidebar": "menu-badge", + className: N( + "tw-pointer-events-none tw-absolute tw-right-1 tw-flex tw-h-5 tw-min-w-5 tw-select-none tw-items-center tw-justify-center tw-rounded-md tw-px-1 tw-text-xs tw-font-medium tw-tabular-nums tw-text-sidebar-foreground", + "tw-peer-hover/menu-button:text-sidebar-accent-foreground tw-peer-data-[active=true]/menu-button:text-sidebar-accent-foreground", + "tw-peer-data-[size=sm]/menu-button:top-1", + "tw-peer-data-[size=default]/menu-button:top-1.5", + "tw-peer-data-[size=lg]/menu-button:top-2.5", + "group-data-[collapsible=icon]:tw-hidden", + t + ), + ...e + } + ) +); +Td.displayName = "SidebarMenuBadge"; +const Cd = T.forwardRef(({ className: t, showIcon: e = !1, ...n }, r) => { + const o = T.useMemo(() => `${Math.floor(Math.random() * 40) + 50}%`, []); + return /* @__PURE__ */ x( + "div", + { + ref: r, + "data-sidebar": "menu-skeleton", + className: N("tw-flex tw-h-8 tw-items-center tw-gap-2 tw-rounded-md tw-px-2", t), + ...n, + children: [ + e && /* @__PURE__ */ s(na, { className: "tw-size-4 tw-rounded-md", "data-sidebar": "menu-skeleton-icon" }), + /* @__PURE__ */ s( + na, + { + className: "tw-h-4 tw-max-w-[--skeleton-width] tw-flex-1", + "data-sidebar": "menu-skeleton-text", + style: ( + // eslint-disable-next-line no-type-assertion/no-type-assertion + { + "--skeleton-width": o + } + ) + } + ) + ] + } + ); +}); +Cd.displayName = "SidebarMenuSkeleton"; +const Od = T.forwardRef( + ({ className: t, ...e }, n) => /* @__PURE__ */ s( + "ul", + { + ref: n, + "data-sidebar": "menu-sub", + className: N( + "tw-mx-3.5 tw-flex tw-min-w-0 tw-translate-x-px tw-flex-col tw-gap-1 tw-border-l tw-border-sidebar-border tw-px-2.5 tw-py-0.5", + "group-data-[collapsible=icon]:tw-hidden", + t + ), + ...e + } + ) +); +Od.displayName = "SidebarMenuSub"; +const Rd = T.forwardRef( + ({ ...t }, e) => /* @__PURE__ */ s("li", { ref: e, ...t }) +); +Rd.displayName = "SidebarMenuSubItem"; +const _d = T.forwardRef(({ asChild: t = !1, size: e = "md", isActive: n, className: r, ...o }, a) => /* @__PURE__ */ s( + t ? He : "a", + { + ref: a, + "data-sidebar": "menu-sub-button", + "data-size": e, + "data-active": n, + className: N( + "tw-flex tw-h-7 tw-min-w-0 tw--translate-x-px tw-items-center tw-gap-2 tw-overflow-hidden tw-rounded-md tw-px-2 tw-text-sidebar-foreground tw-outline-none tw-ring-sidebar-ring hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground focus-visible:tw-ring-2 active:tw-bg-sidebar-accent active:tw-text-sidebar-accent-foreground disabled:tw-pointer-events-none disabled:tw-opacity-50 aria-disabled:tw-pointer-events-none aria-disabled:tw-opacity-50 [&>span:last-child]:tw-truncate [&>svg]:tw-size-4 [&>svg]:tw-shrink-0 [&>svg]:tw-text-sidebar-accent-foreground", + "data-[active=true]:tw-bg-sidebar-accent data-[active=true]:tw-text-sidebar-accent-foreground", + e === "sm" && "tw-text-xs", + e === "md" && "tw-text-sm", + "group-data-[collapsible=icon]:tw-hidden", + r + ), + ...o + } +)); +_d.displayName = "SidebarMenuSubButton"; +function Pd({ + id: t, + extensionLabels: e, + // projectLabels, + handleSelectSidebarItem: n +}) { + const [r, o] = ut(), a = (i, l) => { + o(i), n(i, l); + }; + return /* @__PURE__ */ s(Di, { id: t, collapsible: "offcanvas", variant: "sidebar", children: /* @__PURE__ */ s(ji, { children: /* @__PURE__ */ x(Vi, { children: [ + /* @__PURE__ */ s(zi, { children: "Extensions" }), + /* @__PURE__ */ s(Li, { children: /* @__PURE__ */ s(Fi, { children: e.map((i) => /* @__PURE__ */ s(Ui, { children: /* @__PURE__ */ s( + Gi, + { + onClick: () => a(i, !1), + isActive: i === r, + children: i + } + ) }, i)) }) }) + ] }) }) }); +} +function Ch({ + direction: t = "ltr", + extensionLabels: e, + // projectLabels, + children: n, + handleSelectSidebarItem: r + // renderSettingsProperties, + // renderProjectSettingsProperties. +}) { + return /* @__PURE__ */ x(Mi, { dir: t, children: [ + /* @__PURE__ */ s( + Pd, + { + extensionLabels: e, + handleSelectSidebarItem: r + } + ), + /* @__PURE__ */ s(Bi, { children: n }) ] }); } -const nt = "scrBook", $c = "scrRef", wt = "source", Ic = "details", Ac = "Scripture Reference", Dc = "Scripture Book", Es = "Type", Mc = "Details"; -function Bc(e, t) { - const n = t ?? !1; +const ne = "scrBook", $d = "scrRef", we = "source", Id = "details", Ad = "Scripture Reference", Md = "Scripture Book", Hi = "Type", Dd = "Details"; +function Bd(t, e) { + const n = e ?? !1; return [ { - accessorFn: (r) => `${oe.bookNumberToId(r.start.bookNum)} ${r.start.chapterNum}:${r.start.verseNum}`, - id: nt, - header: (e == null ? void 0 : e.scriptureReferenceColumnName) ?? Ac, + accessorFn: (r) => `${ot.bookNumberToId(r.start.bookNum)} ${r.start.chapterNum}:${r.start.verseNum}`, + id: ne, + header: (t == null ? void 0 : t.scriptureReferenceColumnName) ?? Ad, cell: (r) => { const o = r.row.original; - return r.row.getIsGrouped() ? oe.bookNumberToEnglishName(o.start.bookNum) : r.row.groupingColumnId === nt ? Tr(o.start) : void 0; + return r.row.getIsGrouped() ? ot.bookNumberToEnglishName(o.start.bookNum) : r.row.groupingColumnId === ne ? Or(o.start) : void 0; }, getGroupingValue: (r) => r.start.bookNum, - sortingFn: (r, o) => zr(r.original.start, o.original.start), + sortingFn: (r, o) => Hr(r.original.start, o.original.start), enableGrouping: !0 }, { - accessorFn: (r) => Tr(r.start), - id: $c, + accessorFn: (r) => Or(r.start), + id: $d, header: void 0, cell: (r) => { const o = r.row.original; - return r.row.getIsGrouped() ? void 0 : Tr(o.start); + return r.row.getIsGrouped() ? void 0 : Or(o.start); }, - sortingFn: (r, o) => zr(r.original.start, o.original.start), + sortingFn: (r, o) => Hr(r.original.start, o.original.start), enableGrouping: !1 }, { accessorFn: (r) => r.source.displayName, - id: wt, - header: n ? (e == null ? void 0 : e.typeColumnName) ?? Es : void 0, + id: we, + header: n ? (t == null ? void 0 : t.typeColumnName) ?? Hi : void 0, cell: (r) => n || r.row.getIsGrouped() ? r.getValue() : void 0, getGroupingValue: (r) => r.source.id, sortingFn: (r, o) => r.original.source.displayName.localeCompare(o.original.source.displayName), @@ -2532,111 +3197,111 @@ function Bc(e, t) { }, { accessorFn: (r) => r.detail, - id: Ic, - header: (e == null ? void 0 : e.detailsColumnName) ?? Mc, + id: Id, + header: (t == null ? void 0 : t.detailsColumnName) ?? Dd, cell: (r) => r.getValue(), enableGrouping: !1 } ]; } -const jc = (e) => { - if (!("offset" in e.start)) +const jd = (t) => { + if (!("offset" in t.start)) throw new Error("No offset available in range start"); - if (e.end && !("offset" in e.end)) + if (t.end && !("offset" in t.end)) throw new Error("No offset available in range end"); - const { offset: t } = e.start; + const { offset: e } = t.start; let n = 0; - return e.end && ({ offset: n } = e.end), !e.end || zr(e.start, e.end) === 0 ? `${Cr(e.start)}+${t}` : `${Cr(e.start)}+${t}-${Cr(e.end)}+${n}`; -}, Jo = (e) => `${jc({ start: e.start, end: e.end })} ${e.source.displayName} ${e.detail}`; -function _m({ - sources: e, - showColumnHeaders: t = !1, + return t.end && ({ offset: n } = t.end), !t.end || Hr(t.start, t.end) === 0 ? `${Rr(t.start)}+${e}` : `${Rr(t.start)}+${e}-${Rr(t.end)}+${n}`; +}, ra = (t) => `${jd({ start: t.start, end: t.end })} ${t.source.displayName} ${t.detail}`; +function Oh({ + sources: t, + showColumnHeaders: e = !1, showSourceColumn: n = !1, scriptureReferenceColumnName: r, scriptureBookGroupName: o, typeColumnName: a, - detailsColumnName: s, + detailsColumnName: i, onRowSelected: l, direction: c = "ltr" }) { - const [d, p] = ue([]), [m, w] = ue([{ id: nt, desc: !1 }]), [b, v] = ue({}), f = _e( - () => e.flatMap((C) => C.data.map((P) => ({ - ...P, - source: C.source + const [d, p] = ut([]), [m, w] = ut([{ id: ne, desc: !1 }]), [g, v] = ut({}), f = $t( + () => t.flatMap((O) => O.data.map(($) => ({ + ...$, + source: O.source }))), - [e] - ), h = _e( - () => Bc( + [t] + ), h = $t( + () => Bd( { scriptureReferenceColumnName: r, typeColumnName: a, - detailsColumnName: s + detailsColumnName: i }, n ), - [r, a, s, n] + [r, a, i, n] ); - at(() => { - d.includes(wt) ? w([ - { id: wt, desc: !1 }, - { id: nt, desc: !1 } - ]) : w([{ id: nt, desc: !1 }]); + ae(() => { + d.includes(we) ? w([ + { id: we, desc: !1 }, + { id: ne, desc: !1 } + ]) : w([{ id: ne, desc: !1 }]); }, [d]); - const E = Ha({ + const E = Za({ data: f, columns: h, state: { grouping: d, sorting: m, - rowSelection: b + rowSelection: g }, onGroupingChange: p, onSortingChange: w, onRowSelectionChange: v, - getExpandedRowModel: ul(), - getGroupedRowModel: wl(), - getCoreRowModel: Xa(), - getSortedRowModel: Ya(), - getRowId: Jo, + getExpandedRowModel: Ml(), + getGroupedRowModel: Dl(), + getCoreRowModel: Qa(), + getSortedRowModel: ti(), + getRowId: ra, autoResetExpanded: !1, enableMultiRowSelection: !1, enableSubRowSelection: !1 }); - at(() => { + ae(() => { if (l) { - const C = E.getSelectedRowModel().rowsById, P = Object.keys(C); - if (P.length === 1) { - const N = f.find((B) => Jo(B) === P[0]) || void 0; - N && l(N); + const O = E.getSelectedRowModel().rowsById, $ = Object.keys(O); + if ($.length === 1) { + const k = f.find((B) => ra(B) === $[0]) || void 0; + k && l(k); } } - }, [b, f, l, E]); - const A = o ?? Dc, O = a ?? Es, k = [ + }, [g, f, l, E]); + const _ = o ?? Md, C = a ?? Hi, S = [ { label: "No Grouping", value: [] }, - { label: `Group by ${A}`, value: [nt] }, - { label: `Group by ${O}`, value: [wt] }, + { label: `Group by ${_}`, value: [ne] }, + { label: `Group by ${C}`, value: [we] }, { - label: `Group by ${A} and ${O}`, - value: [nt, wt] + label: `Group by ${_} and ${C}`, + value: [ne, we] }, { - label: `Group by ${O} and ${A}`, - value: [wt, nt] - } - ], g = (C) => { - p(JSON.parse(C)); - }, _ = (C, P) => { - !C.getIsGrouped() && !C.getIsSelected() && C.getToggleSelectedHandler()(P); - }, L = (C, P) => C.getIsGrouped() ? "" : T("banded-row", P % 2 === 0 ? "even" : "odd"), H = (C, P, N) => { - if (!((C == null ? void 0 : C.length) === 0 || P.depth < N.column.getGroupedIndex())) { - if (P.getIsGrouped()) - switch (P.depth) { + label: `Group by ${C} and ${_}`, + value: [we, ne] + } + ], b = (O) => { + p(JSON.parse(O)); + }, I = (O, $) => { + !O.getIsGrouped() && !O.getIsSelected() && O.getToggleSelectedHandler()($); + }, z = (O, $) => O.getIsGrouped() ? "" : N("banded-row", $ % 2 === 0 ? "even" : "odd"), H = (O, $, k) => { + if (!((O == null ? void 0 : O.length) === 0 || $.depth < k.column.getGroupedIndex())) { + if ($.getIsGrouped()) + switch ($.depth) { case 1: return "tw-ps-4"; default: return; } - switch (P.depth) { + switch ($.depth) { case 1: return "tw-ps-8"; case 2: @@ -2647,289 +3312,344 @@ function _m({ } }; return /* @__PURE__ */ x("div", { className: "pr-twp tw-flex tw-h-full tw-w-full tw-flex-col", children: [ - !t && /* @__PURE__ */ x( - fn, + !e && /* @__PURE__ */ x( + gn, { value: JSON.stringify(d), - onValueChange: (C) => { - g(C); + onValueChange: (O) => { + b(O); }, children: [ - /* @__PURE__ */ i(Mt, { className: "tw-mb-1 tw-mt-2", children: /* @__PURE__ */ i(mn, {}) }), - /* @__PURE__ */ i(Bt, { position: "item-aligned", children: /* @__PURE__ */ i(mc, { children: k.map((C) => /* @__PURE__ */ i(Ue, { value: JSON.stringify(C.value), children: C.label }, C.label)) }) }) + /* @__PURE__ */ s(De, { className: "tw-mb-1 tw-mt-2", children: /* @__PURE__ */ s(bn, {}) }), + /* @__PURE__ */ s(Be, { position: "item-aligned", children: /* @__PURE__ */ s(Vc, { children: S.map((O) => /* @__PURE__ */ s(Gt, { value: JSON.stringify(O.value), children: O.label }, O.label)) }) }) ] } ), - /* @__PURE__ */ x(rr, { className: "tw-relative tw-flex tw-flex-col tw-overflow-y-auto tw-p-0", children: [ - t && /* @__PURE__ */ i(or, { children: E.getHeaderGroups().map((C) => /* @__PURE__ */ i(ot, { children: C.headers.filter((P) => P.column.columnDef.header).map((P) => ( + /* @__PURE__ */ x(ar, { className: "tw-relative tw-flex tw-flex-col tw-overflow-y-auto tw-p-0", children: [ + e && /* @__PURE__ */ s(ir, { children: E.getHeaderGroups().map((O) => /* @__PURE__ */ s(oe, { children: O.headers.filter(($) => $.column.columnDef.header).map(($) => ( /* For sticky column headers to work, we probably need to change the default definition of the shadcn Table component. See https://github.com/shadcn-ui/ui/issues/1151 */ - /* @__PURE__ */ i(hn, { colSpan: P.colSpan, className: "top-0 tw-sticky", children: P.isPlaceholder ? void 0 : /* @__PURE__ */ x("div", { children: [ - P.column.getCanGroup() ? /* @__PURE__ */ i( - be, + /* @__PURE__ */ s(vn, { colSpan: $.colSpan, className: "top-0 tw-sticky", children: $.isPlaceholder ? void 0 : /* @__PURE__ */ x("div", { children: [ + $.column.getCanGroup() ? /* @__PURE__ */ s( + gt, { variant: "ghost", - title: `Toggle grouping by ${P.column.columnDef.header}`, - onClick: P.column.getToggleGroupingHandler(), + title: `Toggle grouping by ${$.column.columnDef.header}`, + onClick: $.column.getToggleGroupingHandler(), type: "button", - children: P.column.getIsGrouped() ? "🛑" : "👊 " + children: $.column.getIsGrouped() ? "🛑" : "👊 " } ) : void 0, " ", - sn(P.column.columnDef.header, P.getContext()) - ] }) }, P.id) - )) }, C.id)) }), - /* @__PURE__ */ i(ar, { children: E.getRowModel().rows.map((C, P) => /* @__PURE__ */ i( - ot, + dn($.column.columnDef.header, $.getContext()) + ] }) }, $.id) + )) }, O.id)) }), + /* @__PURE__ */ s(sr, { children: E.getRowModel().rows.map((O, $) => /* @__PURE__ */ s( + oe, { - "data-state": C.getIsSelected() ? "selected" : "", - className: T(L(C, P)), - onClick: (N) => _(C, N), - children: C.getVisibleCells().map((N) => { - if (!(N.getIsPlaceholder() || N.column.columnDef.enableGrouping && !N.getIsGrouped() && (N.column.columnDef.id !== wt || !n))) - return /* @__PURE__ */ i( - jt, + "data-state": O.getIsSelected() ? "selected" : "", + className: N(z(O, $)), + onClick: (k) => I(O, k), + children: O.getVisibleCells().map((k) => { + if (!(k.getIsPlaceholder() || k.column.columnDef.enableGrouping && !k.getIsGrouped() && (k.column.columnDef.id !== we || !n))) + return /* @__PURE__ */ s( + je, { - className: T( - N.column.columnDef.id, + className: N( + k.column.columnDef.id, "tw-p-[1px]", - H(d, C, N) + H(d, O, k) ), - children: (() => N.getIsGrouped() ? /* @__PURE__ */ x( - be, + children: (() => k.getIsGrouped() ? /* @__PURE__ */ x( + gt, { variant: "link", - onClick: C.getToggleExpandedHandler(), + onClick: O.getToggleExpandedHandler(), type: "button", children: [ - C.getIsExpanded() && /* @__PURE__ */ i(Zn, {}), - !C.getIsExpanded() && (c === "ltr" ? /* @__PURE__ */ i(Fa, {}) : /* @__PURE__ */ i(qi, {})), + O.getIsExpanded() && /* @__PURE__ */ s(er, {}), + !O.getIsExpanded() && (c === "ltr" ? /* @__PURE__ */ s(Wa, {}) : /* @__PURE__ */ s(vl, {})), " ", - sn(N.column.columnDef.cell, N.getContext()), + dn(k.column.columnDef.cell, k.getContext()), " (", - C.subRows.length, + O.subRows.length, ")" ] } - ) : sn(N.column.columnDef.cell, N.getContext()))() + ) : dn(k.column.columnDef.cell, k.getContext()))() }, - N.id + k.id ); }) }, - C.id + O.id )) }) ] }) ] }); } -const Rr = { - [pe("undefined")]: "Ø", - [pe(0)]: "A", - [pe(1)]: "B", - [pe(2)]: "C", - [pe(3)]: "D", - [pe(4)]: "E", - [pe(5)]: "F", - [pe(6)]: "G", - [pe(7)]: "H", - [pe(8)]: "I", - [pe(9)]: "J", - [pe(10)]: "K", - [pe(11)]: "L", - [pe(12)]: "M", - [pe(13)]: "N", - [pe(14)]: "O", - [pe(15)]: "P", - [pe(16)]: "Q", - [pe(17)]: "R", - [pe(18)]: "S", - [pe(19)]: "T", - [pe(20)]: "U", - [pe(21)]: "V", - [pe(22)]: "W", - [pe(23)]: "X", - [pe(24)]: "Y", - [pe(25)]: "Z" +const Ir = { + [pt("undefined")]: "Ø", + [pt(0)]: "A", + [pt(1)]: "B", + [pt(2)]: "C", + [pt(3)]: "D", + [pt(4)]: "E", + [pt(5)]: "F", + [pt(6)]: "G", + [pt(7)]: "H", + [pt(8)]: "I", + [pt(9)]: "J", + [pt(10)]: "K", + [pt(11)]: "L", + [pt(12)]: "M", + [pt(13)]: "N", + [pt(14)]: "O", + [pt(15)]: "P", + [pt(16)]: "Q", + [pt(17)]: "R", + [pt(18)]: "S", + [pt(19)]: "T", + [pt(20)]: "U", + [pt(21)]: "V", + [pt(22)]: "W", + [pt(23)]: "X", + [pt(24)]: "Y", + [pt(25)]: "Z" }; -function $m({ - availableScrollGroupIds: e, - scrollGroupId: t, +function Rh({ + availableScrollGroupIds: t, + scrollGroupId: e, onChangeScrollGroupId: n, localizedStrings: r = {} }) { const o = { - ...Rr, + ...Ir, ...Object.fromEntries( Object.entries(r).map( - ([a, s]) => [ + ([a, i]) => [ a, - a === s && a in Rr ? Rr[a] : s + a === i && a in Ir ? Ir[a] : i ] ) ) }; return /* @__PURE__ */ x( - fn, + gn, { - value: `${t}`, + value: `${e}`, onValueChange: (a) => n( a === "undefined" ? void 0 : parseInt(a, 10) ), children: [ - /* @__PURE__ */ i(Mt, { className: "pr-twp tw-w-auto", children: /* @__PURE__ */ i( - mn, + /* @__PURE__ */ s(De, { className: "pr-twp tw-w-auto", children: /* @__PURE__ */ s( + bn, { - placeholder: o[pe(t)] ?? t + placeholder: o[pt(e)] ?? e } ) }), - /* @__PURE__ */ i( - Bt, + /* @__PURE__ */ s( + Be, { style: { zIndex: 250 }, - children: e.map((a) => /* @__PURE__ */ i(Ue, { value: `${a}`, children: o[pe(a)] }, `${a}`)) + children: t.map((a) => /* @__PURE__ */ s(Gt, { value: `${a}`, children: o[pt(a)] }, `${a}`)) } ) ] } ); } -const Ts = I.forwardRef(({ className: e, orientation: t = "horizontal", decorative: n = !0, ...r }, o) => /* @__PURE__ */ i( - qa.Root, - { - ref: o, - decorative: n, - orientation: t, - className: T( - "pr-twp tw-shrink-0 tw-bg-border", - t === "horizontal" ? "tw-h-[1px] tw-w-full" : "tw-h-full tw-w-[1px]", - e - ), - ...r - } -)); -Ts.displayName = qa.Root.displayName; -function Im({ children: e }) { - return /* @__PURE__ */ i("div", { className: "pr-twp tw-grid", children: e }); +function _h({ children: t }) { + return /* @__PURE__ */ s("div", { className: "pr-twp tw-grid", children: t }); } -function Am({ - primary: e, - secondary: t, +function Ph({ + primary: t, + secondary: e, children: n, isLoading: r = !1, loadingMessage: o }) { return /* @__PURE__ */ x("div", { className: "tw-flex tw-items-center tw-justify-between tw-space-x-4 tw-py-2", children: [ /* @__PURE__ */ x("div", { children: [ - /* @__PURE__ */ i("p", { className: "tw-text-sm tw-font-medium tw-leading-none", children: e }), - /* @__PURE__ */ i("p", { className: "tw-whitespace-normal tw-break-words tw-text-sm tw-text-muted-foreground", children: t }) + /* @__PURE__ */ s("p", { className: "tw-text-sm tw-font-medium tw-leading-none", children: t }), + /* @__PURE__ */ s("p", { className: "tw-whitespace-normal tw-break-words tw-text-sm tw-text-muted-foreground", children: e }) ] }), - r ? /* @__PURE__ */ i("p", { className: "tw-text-sm tw-text-muted-foreground", children: o }) : /* @__PURE__ */ i("div", { children: n }) + r ? /* @__PURE__ */ s("p", { className: "tw-text-sm tw-text-muted-foreground", children: o }) : /* @__PURE__ */ s("div", { children: n }) ] }); } -function Dm({ - primary: e, - secondary: t, +function $h({ + primary: t, + secondary: e, includeSeparator: n = !1 }) { return /* @__PURE__ */ x("div", { className: "tw-space-y-4 tw-py-2", children: [ /* @__PURE__ */ x("div", { children: [ - /* @__PURE__ */ i("h3", { className: "tw-text-lg tw-font-medium", children: e }), - /* @__PURE__ */ i("p", { className: "tw-text-sm tw-text-muted-foreground", children: t }) + /* @__PURE__ */ s("h3", { className: "tw-text-lg tw-font-medium", children: t }), + /* @__PURE__ */ s("p", { className: "tw-text-sm tw-text-muted-foreground", children: e }) ] }), - n ? /* @__PURE__ */ i(Ts, {}) : "" + n ? /* @__PURE__ */ s(wo, {}) : "" ] }); } -function Mm({ - id: e, - className: t, +const Xi = T.forwardRef( + ({ className: t, ...e }, n) => /* @__PURE__ */ s( + "div", + { + ref: n, + className: N( + "pr-twp tw-rounded-lg tw-border tw-bg-card tw-text-card-foreground tw-shadow-sm", + t + ), + ...e + } + ) +); +Xi.displayName = "Card"; +const Yi = T.forwardRef( + ({ className: t, ...e }, n) => /* @__PURE__ */ s( + "div", + { + ref: n, + className: N("pr-twp tw-flex tw-flex-col tw-space-y-1.5 tw-p-6", t), + ...e + } + ) +); +Yi.displayName = "CardHeader"; +const Wi = T.forwardRef( + ({ className: t, ...e }, n) => /* @__PURE__ */ s( + "h3", + { + ref: n, + className: N( + "pr-twp tw-text-2xl tw-font-semibold tw-leading-none tw-tracking-tight", + t + ), + ...e, + children: e.children + } + ) +); +Wi.displayName = "CardTitle"; +const qi = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s("p", { ref: n, className: N("pr-twp tw-text-sm tw-text-muted-foreground", t), ...e })); +qi.displayName = "CardDescription"; +const Vd = T.forwardRef( + ({ className: t, ...e }, n) => /* @__PURE__ */ s("div", { ref: n, className: N("pr-twp tw-p-6 tw-pt-0", t), ...e }) +); +Vd.displayName = "CardContent"; +const zd = T.forwardRef( + ({ className: t, ...e }, n) => /* @__PURE__ */ s( + "div", + { + ref: n, + className: N("pr-twp tw-flex tw-items-center tw-p-6 tw-pt-0", t), + ...e + } + ) +); +zd.displayName = "CardFooter"; +function Ih({ + settingsGroupLabel: t, + settingsGroupDescription: e, + children: n +}) { + return /* @__PURE__ */ x(Xi, { children: [ + /* @__PURE__ */ x(Yi, { children: [ + /* @__PURE__ */ s(Wi, { children: t }), + /* @__PURE__ */ s(qi, { children: e }) + ] }), + /* @__PURE__ */ s(Bl, { className: "tw-space-y-4", children: n }) + ] }); +} +function Ah({ + id: t, + className: e, listItems: n, selectedListItems: r, handleSelectListItem: o, createLabel: a }) { - return /* @__PURE__ */ i("div", { id: e, className: t, children: n.map((s) => /* @__PURE__ */ x("div", { className: "tw-m-2 tw-flex tw-items-center", children: [ - /* @__PURE__ */ i( - io, + return /* @__PURE__ */ s("div", { id: t, className: e, children: n.map((i) => /* @__PURE__ */ x("div", { className: "tw-m-2 tw-flex tw-items-center", children: [ + /* @__PURE__ */ s( + uo, { className: "tw-mr-2 tw-align-middle", - checked: r.includes(s), - onCheckedChange: (l) => o(s, l) + checked: r.includes(i), + onCheckedChange: (l) => o(i, l) } ), - /* @__PURE__ */ i(He, { children: a ? a(s) : s }) - ] }, s)) }); + /* @__PURE__ */ s(Xt, { children: a ? a(i) : i }) + ] }, i)) }); } -function Vc(e) { - return e && e.__esModule && Object.prototype.hasOwnProperty.call(e, "default") ? e.default : e; +function Ld(t) { + return t && t.__esModule && Object.prototype.hasOwnProperty.call(t, "default") ? t.default : t; } -function Lc(e) { - if (e.__esModule) - return e; - var t = e.default; - if (typeof t == "function") { +function Fd(t) { + if (t.__esModule) + return t; + var e = t.default; + if (typeof e == "function") { var n = function r() { - return this instanceof r ? Reflect.construct(t, arguments, this.constructor) : t.apply(this, arguments); + return this instanceof r ? Reflect.construct(e, arguments, this.constructor) : e.apply(this, arguments); }; - n.prototype = t.prototype; + n.prototype = e.prototype; } else n = {}; - return Object.defineProperty(n, "__esModule", { value: !0 }), Object.keys(e).forEach(function(r) { - var o = Object.getOwnPropertyDescriptor(e, r); + return Object.defineProperty(n, "__esModule", { value: !0 }), Object.keys(t).forEach(function(r) { + var o = Object.getOwnPropertyDescriptor(t, r); Object.defineProperty(n, r, o.get ? o : { enumerable: !0, get: function() { - return e[r]; + return t[r]; } }); }), n; } -var lo = {}, Cs = { exports: {} }; -(function(e) { - function t(n) { +var fo = {}, Ki = { exports: {} }; +(function(t) { + function e(n) { return n && n.__esModule ? n : { default: n }; } - e.exports = t, e.exports.__esModule = !0, e.exports.default = e.exports; -})(Cs); -var zc = Cs.exports, Pr = {}; -function co(e, t) { + t.exports = e, t.exports.__esModule = !0, t.exports.default = t.exports; +})(Ki); +var Ud = Ki.exports, Ar = {}; +function mo(t, e) { return process.env.NODE_ENV === "production" ? () => null : function(...r) { - return e(...r) || t(...r); + return t(...r) || e(...r); }; } -function R() { - return R = Object.assign ? Object.assign.bind() : function(e) { - for (var t = 1; t < arguments.length; t++) { - var n = arguments[t]; +function P() { + return P = Object.assign ? Object.assign.bind() : function(t) { + for (var e = 1; e < arguments.length; e++) { + var n = arguments[e]; for (var r in n) - Object.prototype.hasOwnProperty.call(n, r) && (e[r] = n[r]); + Object.prototype.hasOwnProperty.call(n, r) && (t[r] = n[r]); } - return e; - }, R.apply(this, arguments); + return t; + }, P.apply(this, arguments); } -function ht(e) { - if (typeof e != "object" || e === null) +function he(t) { + if (typeof t != "object" || t === null) return !1; - const t = Object.getPrototypeOf(e); - return (t === null || t === Object.prototype || Object.getPrototypeOf(t) === null) && !(Symbol.toStringTag in e) && !(Symbol.iterator in e); + const e = Object.getPrototypeOf(t); + return (e === null || e === Object.prototype || Object.getPrototypeOf(e) === null) && !(Symbol.toStringTag in t) && !(Symbol.iterator in t); } -function Ss(e) { - if (!ht(e)) - return e; - const t = {}; - return Object.keys(e).forEach((n) => { - t[n] = Ss(e[n]); - }), t; +function Ji(t) { + if (!he(t)) + return t; + const e = {}; + return Object.keys(t).forEach((n) => { + e[n] = Ji(t[n]); + }), e; } -function Ze(e, t, n = { +function Zt(t, e, n = { clone: !0 }) { - const r = n.clone ? R({}, e) : e; - return ht(e) && ht(t) && Object.keys(t).forEach((o) => { - o !== "__proto__" && (ht(t[o]) && o in e && ht(e[o]) ? r[o] = Ze(e[o], t[o], n) : n.clone ? r[o] = ht(t[o]) ? Ss(t[o]) : t[o] : r[o] = t[o]); + const r = n.clone ? P({}, t) : t; + return he(t) && he(e) && Object.keys(e).forEach((o) => { + o !== "__proto__" && (he(e[o]) && o in t && he(t[o]) ? r[o] = Zt(t[o], e[o], n) : n.clone ? r[o] = he(e[o]) ? Ji(e[o]) : e[o] : r[o] = e[o]); }), r; } -var Hr = { exports: {} }, Dn = { exports: {} }, se = {}; +var qr = { exports: {} }, jn = { exports: {} }, it = {}; /** @license React v16.13.1 * react-is.production.min.js * @@ -2938,74 +3658,74 @@ var Hr = { exports: {} }, Dn = { exports: {} }, se = {}; * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. */ -var Zo; -function Fc() { - if (Zo) - return se; - Zo = 1; - var e = typeof Symbol == "function" && Symbol.for, t = e ? Symbol.for("react.element") : 60103, n = e ? Symbol.for("react.portal") : 60106, r = e ? Symbol.for("react.fragment") : 60107, o = e ? Symbol.for("react.strict_mode") : 60108, a = e ? Symbol.for("react.profiler") : 60114, s = e ? Symbol.for("react.provider") : 60109, l = e ? Symbol.for("react.context") : 60110, c = e ? Symbol.for("react.async_mode") : 60111, d = e ? Symbol.for("react.concurrent_mode") : 60111, p = e ? Symbol.for("react.forward_ref") : 60112, m = e ? Symbol.for("react.suspense") : 60113, w = e ? Symbol.for("react.suspense_list") : 60120, b = e ? Symbol.for("react.memo") : 60115, v = e ? Symbol.for("react.lazy") : 60116, f = e ? Symbol.for("react.block") : 60121, h = e ? Symbol.for("react.fundamental") : 60117, E = e ? Symbol.for("react.responder") : 60118, A = e ? Symbol.for("react.scope") : 60119; - function O(g) { - if (typeof g == "object" && g !== null) { - var _ = g.$$typeof; - switch (_) { - case t: - switch (g = g.type, g) { +var oa; +function Gd() { + if (oa) + return it; + oa = 1; + var t = typeof Symbol == "function" && Symbol.for, e = t ? Symbol.for("react.element") : 60103, n = t ? Symbol.for("react.portal") : 60106, r = t ? Symbol.for("react.fragment") : 60107, o = t ? Symbol.for("react.strict_mode") : 60108, a = t ? Symbol.for("react.profiler") : 60114, i = t ? Symbol.for("react.provider") : 60109, l = t ? Symbol.for("react.context") : 60110, c = t ? Symbol.for("react.async_mode") : 60111, d = t ? Symbol.for("react.concurrent_mode") : 60111, p = t ? Symbol.for("react.forward_ref") : 60112, m = t ? Symbol.for("react.suspense") : 60113, w = t ? Symbol.for("react.suspense_list") : 60120, g = t ? Symbol.for("react.memo") : 60115, v = t ? Symbol.for("react.lazy") : 60116, f = t ? Symbol.for("react.block") : 60121, h = t ? Symbol.for("react.fundamental") : 60117, E = t ? Symbol.for("react.responder") : 60118, _ = t ? Symbol.for("react.scope") : 60119; + function C(b) { + if (typeof b == "object" && b !== null) { + var I = b.$$typeof; + switch (I) { + case e: + switch (b = b.type, b) { case c: case d: case r: case a: case o: case m: - return g; + return b; default: - switch (g = g && g.$$typeof, g) { + switch (b = b && b.$$typeof, b) { case l: case p: case v: - case b: - case s: - return g; + case g: + case i: + return b; default: - return _; + return I; } } case n: - return _; + return I; } } } - function k(g) { - return O(g) === d; - } - return se.AsyncMode = c, se.ConcurrentMode = d, se.ContextConsumer = l, se.ContextProvider = s, se.Element = t, se.ForwardRef = p, se.Fragment = r, se.Lazy = v, se.Memo = b, se.Portal = n, se.Profiler = a, se.StrictMode = o, se.Suspense = m, se.isAsyncMode = function(g) { - return k(g) || O(g) === c; - }, se.isConcurrentMode = k, se.isContextConsumer = function(g) { - return O(g) === l; - }, se.isContextProvider = function(g) { - return O(g) === s; - }, se.isElement = function(g) { - return typeof g == "object" && g !== null && g.$$typeof === t; - }, se.isForwardRef = function(g) { - return O(g) === p; - }, se.isFragment = function(g) { - return O(g) === r; - }, se.isLazy = function(g) { - return O(g) === v; - }, se.isMemo = function(g) { - return O(g) === b; - }, se.isPortal = function(g) { - return O(g) === n; - }, se.isProfiler = function(g) { - return O(g) === a; - }, se.isStrictMode = function(g) { - return O(g) === o; - }, se.isSuspense = function(g) { - return O(g) === m; - }, se.isValidElementType = function(g) { - return typeof g == "string" || typeof g == "function" || g === r || g === d || g === a || g === o || g === m || g === w || typeof g == "object" && g !== null && (g.$$typeof === v || g.$$typeof === b || g.$$typeof === s || g.$$typeof === l || g.$$typeof === p || g.$$typeof === h || g.$$typeof === E || g.$$typeof === A || g.$$typeof === f); - }, se.typeOf = O, se; -} -var ie = {}; + function S(b) { + return C(b) === d; + } + return it.AsyncMode = c, it.ConcurrentMode = d, it.ContextConsumer = l, it.ContextProvider = i, it.Element = e, it.ForwardRef = p, it.Fragment = r, it.Lazy = v, it.Memo = g, it.Portal = n, it.Profiler = a, it.StrictMode = o, it.Suspense = m, it.isAsyncMode = function(b) { + return S(b) || C(b) === c; + }, it.isConcurrentMode = S, it.isContextConsumer = function(b) { + return C(b) === l; + }, it.isContextProvider = function(b) { + return C(b) === i; + }, it.isElement = function(b) { + return typeof b == "object" && b !== null && b.$$typeof === e; + }, it.isForwardRef = function(b) { + return C(b) === p; + }, it.isFragment = function(b) { + return C(b) === r; + }, it.isLazy = function(b) { + return C(b) === v; + }, it.isMemo = function(b) { + return C(b) === g; + }, it.isPortal = function(b) { + return C(b) === n; + }, it.isProfiler = function(b) { + return C(b) === a; + }, it.isStrictMode = function(b) { + return C(b) === o; + }, it.isSuspense = function(b) { + return C(b) === m; + }, it.isValidElementType = function(b) { + return typeof b == "string" || typeof b == "function" || b === r || b === d || b === a || b === o || b === m || b === w || typeof b == "object" && b !== null && (b.$$typeof === v || b.$$typeof === g || b.$$typeof === i || b.$$typeof === l || b.$$typeof === p || b.$$typeof === h || b.$$typeof === E || b.$$typeof === _ || b.$$typeof === f); + }, it.typeOf = C, it; +} +var st = {}; /** @license React v16.13.1 * react-is.development.js * @@ -3014,20 +3734,20 @@ var ie = {}; * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. */ -var Qo; -function Uc() { - return Qo || (Qo = 1, process.env.NODE_ENV !== "production" && function() { - var e = typeof Symbol == "function" && Symbol.for, t = e ? Symbol.for("react.element") : 60103, n = e ? Symbol.for("react.portal") : 60106, r = e ? Symbol.for("react.fragment") : 60107, o = e ? Symbol.for("react.strict_mode") : 60108, a = e ? Symbol.for("react.profiler") : 60114, s = e ? Symbol.for("react.provider") : 60109, l = e ? Symbol.for("react.context") : 60110, c = e ? Symbol.for("react.async_mode") : 60111, d = e ? Symbol.for("react.concurrent_mode") : 60111, p = e ? Symbol.for("react.forward_ref") : 60112, m = e ? Symbol.for("react.suspense") : 60113, w = e ? Symbol.for("react.suspense_list") : 60120, b = e ? Symbol.for("react.memo") : 60115, v = e ? Symbol.for("react.lazy") : 60116, f = e ? Symbol.for("react.block") : 60121, h = e ? Symbol.for("react.fundamental") : 60117, E = e ? Symbol.for("react.responder") : 60118, A = e ? Symbol.for("react.scope") : 60119; - function O($) { - return typeof $ == "string" || typeof $ == "function" || // Note: its typeof might be other than 'symbol' or 'number' if it's a polyfill. - $ === r || $ === d || $ === a || $ === o || $ === m || $ === w || typeof $ == "object" && $ !== null && ($.$$typeof === v || $.$$typeof === b || $.$$typeof === s || $.$$typeof === l || $.$$typeof === p || $.$$typeof === h || $.$$typeof === E || $.$$typeof === A || $.$$typeof === f); - } - function k($) { - if (typeof $ == "object" && $ !== null) { - var xe = $.$$typeof; - switch (xe) { - case t: - var j = $.type; +var aa; +function Hd() { + return aa || (aa = 1, process.env.NODE_ENV !== "production" && function() { + var t = typeof Symbol == "function" && Symbol.for, e = t ? Symbol.for("react.element") : 60103, n = t ? Symbol.for("react.portal") : 60106, r = t ? Symbol.for("react.fragment") : 60107, o = t ? Symbol.for("react.strict_mode") : 60108, a = t ? Symbol.for("react.profiler") : 60114, i = t ? Symbol.for("react.provider") : 60109, l = t ? Symbol.for("react.context") : 60110, c = t ? Symbol.for("react.async_mode") : 60111, d = t ? Symbol.for("react.concurrent_mode") : 60111, p = t ? Symbol.for("react.forward_ref") : 60112, m = t ? Symbol.for("react.suspense") : 60113, w = t ? Symbol.for("react.suspense_list") : 60120, g = t ? Symbol.for("react.memo") : 60115, v = t ? Symbol.for("react.lazy") : 60116, f = t ? Symbol.for("react.block") : 60121, h = t ? Symbol.for("react.fundamental") : 60117, E = t ? Symbol.for("react.responder") : 60118, _ = t ? Symbol.for("react.scope") : 60119; + function C(A) { + return typeof A == "string" || typeof A == "function" || // Note: its typeof might be other than 'symbol' or 'number' if it's a polyfill. + A === r || A === d || A === a || A === o || A === m || A === w || typeof A == "object" && A !== null && (A.$$typeof === v || A.$$typeof === g || A.$$typeof === i || A.$$typeof === l || A.$$typeof === p || A.$$typeof === h || A.$$typeof === E || A.$$typeof === _ || A.$$typeof === f); + } + function S(A) { + if (typeof A == "object" && A !== null) { + var Nt = A.$$typeof; + switch (Nt) { + case e: + var j = A.type; switch (j) { case c: case d: @@ -3037,81 +3757,81 @@ function Uc() { case m: return j; default: - var ye = j && j.$$typeof; - switch (ye) { + var xt = j && j.$$typeof; + switch (xt) { case l: case p: case v: - case b: - case s: - return ye; + case g: + case i: + return xt; default: - return xe; + return Nt; } } case n: - return xe; + return Nt; } } } - var g = c, _ = d, L = l, H = s, C = t, P = p, N = r, B = v, D = b, J = n, q = a, U = o, ee = m, ae = !1; - function re($) { - return ae || (ae = !0, console.warn("The ReactIs.isAsyncMode() alias has been deprecated, and will be removed in React 17+. Update your code to use ReactIs.isConcurrentMode() instead. It has the exact same API.")), y($) || k($) === c; + var b = c, I = d, z = l, H = i, O = e, $ = p, k = r, B = v, D = g, J = n, q = a, U = o, tt = m, at = !1; + function rt(A) { + return at || (at = !0, console.warn("The ReactIs.isAsyncMode() alias has been deprecated, and will be removed in React 17+. Update your code to use ReactIs.isConcurrentMode() instead. It has the exact same API.")), y(A) || S(A) === c; } - function y($) { - return k($) === d; + function y(A) { + return S(A) === d; } - function S($) { - return k($) === l; + function R(A) { + return S(A) === l; } - function z($) { - return k($) === s; + function L(A) { + return S(A) === i; } - function F($) { - return typeof $ == "object" && $ !== null && $.$$typeof === t; + function F(A) { + return typeof A == "object" && A !== null && A.$$typeof === e; } - function V($) { - return k($) === p; + function V(A) { + return S(A) === p; } - function W($) { - return k($) === r; + function W(A) { + return S(A) === r; } - function X($) { - return k($) === v; + function X(A) { + return S(A) === v; } - function Y($) { - return k($) === b; + function Y(A) { + return S(A) === g; } - function G($) { - return k($) === n; + function G(A) { + return S(A) === n; } - function K($) { - return k($) === a; + function K(A) { + return S(A) === a; } - function Z($) { - return k($) === o; + function Z(A) { + return S(A) === o; } - function de($) { - return k($) === m; + function dt(A) { + return S(A) === m; } - ie.AsyncMode = g, ie.ConcurrentMode = _, ie.ContextConsumer = L, ie.ContextProvider = H, ie.Element = C, ie.ForwardRef = P, ie.Fragment = N, ie.Lazy = B, ie.Memo = D, ie.Portal = J, ie.Profiler = q, ie.StrictMode = U, ie.Suspense = ee, ie.isAsyncMode = re, ie.isConcurrentMode = y, ie.isContextConsumer = S, ie.isContextProvider = z, ie.isElement = F, ie.isForwardRef = V, ie.isFragment = W, ie.isLazy = X, ie.isMemo = Y, ie.isPortal = G, ie.isProfiler = K, ie.isStrictMode = Z, ie.isSuspense = de, ie.isValidElementType = O, ie.typeOf = k; - }()), ie; + st.AsyncMode = b, st.ConcurrentMode = I, st.ContextConsumer = z, st.ContextProvider = H, st.Element = O, st.ForwardRef = $, st.Fragment = k, st.Lazy = B, st.Memo = D, st.Portal = J, st.Profiler = q, st.StrictMode = U, st.Suspense = tt, st.isAsyncMode = rt, st.isConcurrentMode = y, st.isContextConsumer = R, st.isContextProvider = L, st.isElement = F, st.isForwardRef = V, st.isFragment = W, st.isLazy = X, st.isMemo = Y, st.isPortal = G, st.isProfiler = K, st.isStrictMode = Z, st.isSuspense = dt, st.isValidElementType = C, st.typeOf = S; + }()), st; } -var ea; -function Os() { - return ea || (ea = 1, process.env.NODE_ENV === "production" ? Dn.exports = Fc() : Dn.exports = Uc()), Dn.exports; +var ia; +function Zi() { + return ia || (ia = 1, process.env.NODE_ENV === "production" ? jn.exports = Gd() : jn.exports = Hd()), jn.exports; } /* object-assign (c) Sindre Sorhus @license MIT */ -var _r, ta; -function Gc() { - if (ta) - return _r; - ta = 1; - var e = Object.getOwnPropertySymbols, t = Object.prototype.hasOwnProperty, n = Object.prototype.propertyIsEnumerable; +var Mr, sa; +function Xd() { + if (sa) + return Mr; + sa = 1; + var t = Object.getOwnPropertySymbols, e = Object.prototype.hasOwnProperty, n = Object.prototype.propertyIsEnumerable; function r(a) { if (a == null) throw new TypeError("Object.assign cannot be called with null or undefined"); @@ -3124,10 +3844,10 @@ function Gc() { var a = new String("abc"); if (a[5] = "de", Object.getOwnPropertyNames(a)[0] === "5") return !1; - for (var s = {}, l = 0; l < 10; l++) - s["_" + String.fromCharCode(l)] = l; - var c = Object.getOwnPropertyNames(s).map(function(p) { - return s[p]; + for (var i = {}, l = 0; l < 10; l++) + i["_" + String.fromCharCode(l)] = l; + var c = Object.getOwnPropertyNames(i).map(function(p) { + return i[p]; }); if (c.join("") !== "0123456789") return !1; @@ -3139,51 +3859,51 @@ function Gc() { return !1; } } - return _r = o() ? Object.assign : function(a, s) { + return Mr = o() ? Object.assign : function(a, i) { for (var l, c = r(a), d, p = 1; p < arguments.length; p++) { l = Object(arguments[p]); for (var m in l) - t.call(l, m) && (c[m] = l[m]); - if (e) { - d = e(l); + e.call(l, m) && (c[m] = l[m]); + if (t) { + d = t(l); for (var w = 0; w < d.length; w++) n.call(l, d[w]) && (c[d[w]] = l[d[w]]); } } return c; - }, _r; -} -var $r, na; -function po() { - if (na) - return $r; - na = 1; - var e = "SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED"; - return $r = e, $r; -} -var Ir, ra; -function Rs() { - return ra || (ra = 1, Ir = Function.call.bind(Object.prototype.hasOwnProperty)), Ir; -} -var Ar, oa; -function Hc() { - if (oa) - return Ar; - oa = 1; - var e = function() { + }, Mr; +} +var Dr, la; +function ho() { + if (la) + return Dr; + la = 1; + var t = "SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED"; + return Dr = t, Dr; +} +var Br, ca; +function Qi() { + return ca || (ca = 1, Br = Function.call.bind(Object.prototype.hasOwnProperty)), Br; +} +var jr, da; +function Yd() { + if (da) + return jr; + da = 1; + var t = function() { }; if (process.env.NODE_ENV !== "production") { - var t = po(), n = {}, r = Rs(); - e = function(a) { - var s = "Warning: " + a; - typeof console < "u" && console.error(s); + var e = ho(), n = {}, r = Qi(); + t = function(a) { + var i = "Warning: " + a; + typeof console < "u" && console.error(i); try { - throw new Error(s); + throw new Error(i); } catch { } }; } - function o(a, s, l, c, d) { + function o(a, i, l, c, d) { if (process.env.NODE_ENV !== "production") { for (var p in a) if (r(a, p)) { @@ -3195,17 +3915,17 @@ function Hc() { ); throw w.name = "Invariant Violation", w; } - m = a[p](s, p, c, l, null, t); + m = a[p](i, p, c, l, null, e); } catch (v) { m = v; } - if (m && !(m instanceof Error) && e( + if (m && !(m instanceof Error) && t( (c || "React class") + ": type specification of " + l + " `" + p + "` is invalid; the type checker function must return `null` or an `Error` but returned a " + typeof m + ". You may have forgotten to pass an argument to the type checker creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and shape all require an argument)." ), m instanceof Error && !(m.message in n)) { n[m.message] = !0; - var b = d ? d() : ""; - e( - "Failed " + l + " type: " + m.message + (b ?? "") + var g = d ? d() : ""; + t( + "Failed " + l + " type: " + m.message + (g ?? "") ); } } @@ -3213,14 +3933,14 @@ function Hc() { } return o.resetWarningCache = function() { process.env.NODE_ENV !== "production" && (n = {}); - }, Ar = o, Ar; -} -var Dr, aa; -function Xc() { - if (aa) - return Dr; - aa = 1; - var e = Os(), t = Gc(), n = po(), r = Rs(), o = Hc(), a = function() { + }, jr = o, jr; +} +var Vr, pa; +function Wd() { + if (pa) + return Vr; + pa = 1; + var t = Zi(), e = Xd(), n = ho(), r = Qi(), o = Yd(), a = function() { }; process.env.NODE_ENV !== "production" && (a = function(l) { var c = "Warning: " + l; @@ -3230,17 +3950,17 @@ function Xc() { } catch { } }); - function s() { + function i() { return null; } - return Dr = function(l, c) { + return Vr = function(l, c) { var d = typeof Symbol == "function" && Symbol.iterator, p = "@@iterator"; function m(y) { - var S = y && (d && y[d] || y[p]); - if (typeof S == "function") - return S; + var R = y && (d && y[d] || y[p]); + if (typeof R == "function") + return R; } - var w = "<>", b = { + var w = "<>", g = { array: E("array"), bigint: E("bigint"), bool: E("boolean"), @@ -3249,41 +3969,41 @@ function Xc() { object: E("object"), string: E("string"), symbol: E("symbol"), - any: A(), - arrayOf: O, - element: k(), - elementType: g(), - instanceOf: _, - node: P(), + any: _(), + arrayOf: C, + element: S(), + elementType: b(), + instanceOf: I, + node: $(), objectOf: H, - oneOf: L, - oneOfType: C, + oneOf: z, + oneOfType: O, shape: B, exact: D }; - function v(y, S) { - return y === S ? y !== 0 || 1 / y === 1 / S : y !== y && S !== S; + function v(y, R) { + return y === R ? y !== 0 || 1 / y === 1 / R : y !== y && R !== R; } - function f(y, S) { - this.message = y, this.data = S && typeof S == "object" ? S : {}, this.stack = ""; + function f(y, R) { + this.message = y, this.data = R && typeof R == "object" ? R : {}, this.stack = ""; } f.prototype = Error.prototype; function h(y) { if (process.env.NODE_ENV !== "production") - var S = {}, z = 0; - function F(W, X, Y, G, K, Z, de) { - if (G = G || w, Z = Z || Y, de !== n) { + var R = {}, L = 0; + function F(W, X, Y, G, K, Z, dt) { + if (G = G || w, Z = Z || Y, dt !== n) { if (c) { - var $ = new Error( + var A = new Error( "Calling PropTypes validators directly is not supported by the `prop-types` package. Use `PropTypes.checkPropTypes()` to call them. Read more at http://fb.me/use-check-prop-types" ); - throw $.name = "Invariant Violation", $; + throw A.name = "Invariant Violation", A; } else if (process.env.NODE_ENV !== "production" && typeof console < "u") { - var xe = G + ":" + Y; - !S[xe] && // Avoid spamming the console because they are often not actionable except for lib authors - z < 3 && (a( + var Nt = G + ":" + Y; + !R[Nt] && // Avoid spamming the console because they are often not actionable except for lib authors + L < 3 && (a( "You are manually calling a React.PropTypes validation function for the `" + Z + "` prop on `" + G + "`. This is deprecated and will throw in the standalone `prop-types` package. You may be seeing this warning due to a third-party PropTypes library. See https://fb.me/react-warning-dont-call-proptypes for details." - ), S[xe] = !0, z++); + ), R[Nt] = !0, L++); } } return X[Y] == null ? W ? X[Y] === null ? new f("The " + K + " `" + Z + "` is marked as required " + ("in `" + G + "`, but its value is `null`.")) : new f("The " + K + " `" + Z + "` is marked as required in " + ("`" + G + "`, but its value is `undefined`.")) : null : y(X, Y, G, K, Z); @@ -3292,10 +4012,10 @@ function Xc() { return V.isRequired = F.bind(null, !0), V; } function E(y) { - function S(z, F, V, W, X, Y) { - var G = z[F], K = U(G); + function R(L, F, V, W, X, Y) { + var G = L[F], K = U(G); if (K !== y) { - var Z = ee(G); + var Z = tt(G); return new f( "Invalid " + W + " `" + X + "` of type " + ("`" + Z + "` supplied to `" + V + "`, expected ") + ("`" + y + "`."), { expectedType: y } @@ -3303,16 +4023,16 @@ function Xc() { } return null; } - return h(S); + return h(R); } - function A() { - return h(s); + function _() { + return h(i); } - function O(y) { - function S(z, F, V, W, X) { + function C(y) { + function R(L, F, V, W, X) { if (typeof y != "function") return new f("Property `" + X + "` of component `" + V + "` has invalid PropType notation inside arrayOf."); - var Y = z[F]; + var Y = L[F]; if (!Array.isArray(Y)) { var G = U(Y); return new f("Invalid " + W + " `" + X + "` of type " + ("`" + G + "` supplied to `" + V + "`, expected an array.")); @@ -3324,11 +4044,11 @@ function Xc() { } return null; } - return h(S); + return h(R); } - function k() { - function y(S, z, F, V, W) { - var X = S[z]; + function S() { + function y(R, L, F, V, W) { + var X = R[L]; if (!l(X)) { var Y = U(X); return new f("Invalid " + V + " `" + W + "` of type " + ("`" + Y + "` supplied to `" + F + "`, expected a single ReactElement.")); @@ -3337,10 +4057,10 @@ function Xc() { } return h(y); } - function g() { - function y(S, z, F, V, W) { - var X = S[z]; - if (!e.isValidElementType(X)) { + function b() { + function y(R, L, F, V, W) { + var X = R[L]; + if (!t.isValidElementType(X)) { var Y = U(X); return new f("Invalid " + V + " `" + W + "` of type " + ("`" + Y + "` supplied to `" + F + "`, expected a single ReactElement type.")); } @@ -3348,38 +4068,38 @@ function Xc() { } return h(y); } - function _(y) { - function S(z, F, V, W, X) { - if (!(z[F] instanceof y)) { - var Y = y.name || w, G = re(z[F]); + function I(y) { + function R(L, F, V, W, X) { + if (!(L[F] instanceof y)) { + var Y = y.name || w, G = rt(L[F]); return new f("Invalid " + W + " `" + X + "` of type " + ("`" + G + "` supplied to `" + V + "`, expected ") + ("instance of `" + Y + "`.")); } return null; } - return h(S); + return h(R); } - function L(y) { + function z(y) { if (!Array.isArray(y)) return process.env.NODE_ENV !== "production" && (arguments.length > 1 ? a( "Invalid arguments supplied to oneOf, expected an array, got " + arguments.length + " arguments. A common mistake is to write oneOf(x, y, z) instead of oneOf([x, y, z])." - ) : a("Invalid argument supplied to oneOf, expected an array.")), s; - function S(z, F, V, W, X) { - for (var Y = z[F], G = 0; G < y.length; G++) + ) : a("Invalid argument supplied to oneOf, expected an array.")), i; + function R(L, F, V, W, X) { + for (var Y = L[F], G = 0; G < y.length; G++) if (v(Y, y[G])) return null; - var K = JSON.stringify(y, function(de, $) { - var xe = ee($); - return xe === "symbol" ? String($) : $; + var K = JSON.stringify(y, function(dt, A) { + var Nt = tt(A); + return Nt === "symbol" ? String(A) : A; }); return new f("Invalid " + W + " `" + X + "` of value `" + String(Y) + "` " + ("supplied to `" + V + "`, expected one of " + K + ".")); } - return h(S); + return h(R); } function H(y) { - function S(z, F, V, W, X) { + function R(L, F, V, W, X) { if (typeof y != "function") return new f("Property `" + X + "` of component `" + V + "` has invalid PropType notation inside objectOf."); - var Y = z[F], G = U(Y); + var Y = L[F], G = U(Y); if (G !== "object") return new f("Invalid " + W + " `" + X + "` of type " + ("`" + G + "` supplied to `" + V + "`, expected an object.")); for (var K in Y) @@ -3390,80 +4110,80 @@ function Xc() { } return null; } - return h(S); + return h(R); } - function C(y) { + function O(y) { if (!Array.isArray(y)) - return process.env.NODE_ENV !== "production" && a("Invalid argument supplied to oneOfType, expected an instance of array."), s; - for (var S = 0; S < y.length; S++) { - var z = y[S]; - if (typeof z != "function") + return process.env.NODE_ENV !== "production" && a("Invalid argument supplied to oneOfType, expected an instance of array."), i; + for (var R = 0; R < y.length; R++) { + var L = y[R]; + if (typeof L != "function") return a( - "Invalid argument supplied to oneOfType. Expected an array of check functions, but received " + ae(z) + " at index " + S + "." - ), s; + "Invalid argument supplied to oneOfType. Expected an array of check functions, but received " + at(L) + " at index " + R + "." + ), i; } function F(V, W, X, Y, G) { for (var K = [], Z = 0; Z < y.length; Z++) { - var de = y[Z], $ = de(V, W, X, Y, G, n); - if ($ == null) + var dt = y[Z], A = dt(V, W, X, Y, G, n); + if (A == null) return null; - $.data && r($.data, "expectedType") && K.push($.data.expectedType); + A.data && r(A.data, "expectedType") && K.push(A.data.expectedType); } - var xe = K.length > 0 ? ", expected one of type [" + K.join(", ") + "]" : ""; - return new f("Invalid " + Y + " `" + G + "` supplied to " + ("`" + X + "`" + xe + ".")); + var Nt = K.length > 0 ? ", expected one of type [" + K.join(", ") + "]" : ""; + return new f("Invalid " + Y + " `" + G + "` supplied to " + ("`" + X + "`" + Nt + ".")); } return h(F); } - function P() { - function y(S, z, F, V, W) { - return J(S[z]) ? null : new f("Invalid " + V + " `" + W + "` supplied to " + ("`" + F + "`, expected a ReactNode.")); + function $() { + function y(R, L, F, V, W) { + return J(R[L]) ? null : new f("Invalid " + V + " `" + W + "` supplied to " + ("`" + F + "`, expected a ReactNode.")); } return h(y); } - function N(y, S, z, F, V) { + function k(y, R, L, F, V) { return new f( - (y || "React class") + ": " + S + " type `" + z + "." + F + "` is invalid; it must be a function, usually from the `prop-types` package, but received `" + V + "`." + (y || "React class") + ": " + R + " type `" + L + "." + F + "` is invalid; it must be a function, usually from the `prop-types` package, but received `" + V + "`." ); } function B(y) { - function S(z, F, V, W, X) { - var Y = z[F], G = U(Y); + function R(L, F, V, W, X) { + var Y = L[F], G = U(Y); if (G !== "object") return new f("Invalid " + W + " `" + X + "` of type `" + G + "` " + ("supplied to `" + V + "`, expected `object`.")); for (var K in y) { var Z = y[K]; if (typeof Z != "function") - return N(V, W, X, K, ee(Z)); - var de = Z(Y, K, V, W, X + "." + K, n); - if (de) - return de; + return k(V, W, X, K, tt(Z)); + var dt = Z(Y, K, V, W, X + "." + K, n); + if (dt) + return dt; } return null; } - return h(S); + return h(R); } function D(y) { - function S(z, F, V, W, X) { - var Y = z[F], G = U(Y); + function R(L, F, V, W, X) { + var Y = L[F], G = U(Y); if (G !== "object") return new f("Invalid " + W + " `" + X + "` of type `" + G + "` " + ("supplied to `" + V + "`, expected `object`.")); - var K = t({}, z[F], y); + var K = e({}, L[F], y); for (var Z in K) { - var de = y[Z]; - if (r(y, Z) && typeof de != "function") - return N(V, W, X, Z, ee(de)); - if (!de) + var dt = y[Z]; + if (r(y, Z) && typeof dt != "function") + return k(V, W, X, Z, tt(dt)); + if (!dt) return new f( - "Invalid " + W + " `" + X + "` key `" + Z + "` supplied to `" + V + "`.\nBad object: " + JSON.stringify(z[F], null, " ") + ` + "Invalid " + W + " `" + X + "` key `" + Z + "` supplied to `" + V + "`.\nBad object: " + JSON.stringify(L[F], null, " ") + ` Valid keys: ` + JSON.stringify(Object.keys(y), null, " ") ); - var $ = de(Y, Z, V, W, X + "." + Z, n); - if ($) - return $; + var A = dt(Y, Z, V, W, X + "." + Z, n); + if (A) + return A; } return null; } - return h(S); + return h(R); } function J(y) { switch (typeof y) { @@ -3478,15 +4198,15 @@ Valid keys: ` + JSON.stringify(Object.keys(y), null, " ") return y.every(J); if (y === null || l(y)) return !0; - var S = m(y); - if (S) { - var z = S.call(y), F; - if (S !== y.entries) { - for (; !(F = z.next()).done; ) + var R = m(y); + if (R) { + var L = R.call(y), F; + if (R !== y.entries) { + for (; !(F = L.next()).done; ) if (!J(F.value)) return !1; } else - for (; !(F = z.next()).done; ) { + for (; !(F = L.next()).done; ) { var V = F.value; if (V && !J(V[1])) return !1; @@ -3498,58 +4218,58 @@ Valid keys: ` + JSON.stringify(Object.keys(y), null, " ") return !1; } } - function q(y, S) { - return y === "symbol" ? !0 : S ? S["@@toStringTag"] === "Symbol" || typeof Symbol == "function" && S instanceof Symbol : !1; + function q(y, R) { + return y === "symbol" ? !0 : R ? R["@@toStringTag"] === "Symbol" || typeof Symbol == "function" && R instanceof Symbol : !1; } function U(y) { - var S = typeof y; - return Array.isArray(y) ? "array" : y instanceof RegExp ? "object" : q(S, y) ? "symbol" : S; + var R = typeof y; + return Array.isArray(y) ? "array" : y instanceof RegExp ? "object" : q(R, y) ? "symbol" : R; } - function ee(y) { + function tt(y) { if (typeof y > "u" || y === null) return "" + y; - var S = U(y); - if (S === "object") { + var R = U(y); + if (R === "object") { if (y instanceof Date) return "date"; if (y instanceof RegExp) return "regexp"; } - return S; + return R; } - function ae(y) { - var S = ee(y); - switch (S) { + function at(y) { + var R = tt(y); + switch (R) { case "array": case "object": - return "an " + S; + return "an " + R; case "boolean": case "date": case "regexp": - return "a " + S; + return "a " + R; default: - return S; + return R; } } - function re(y) { + function rt(y) { return !y.constructor || !y.constructor.name ? w : y.constructor.name; } - return b.checkPropTypes = o, b.resetWarningCache = o.resetWarningCache, b.PropTypes = b, b; - }, Dr; + return g.checkPropTypes = o, g.resetWarningCache = o.resetWarningCache, g.PropTypes = g, g; + }, Vr; } -var Mr, sa; -function Yc() { - if (sa) - return Mr; - sa = 1; - var e = po(); - function t() { +var zr, ua; +function qd() { + if (ua) + return zr; + ua = 1; + var t = ho(); + function e() { } function n() { } - return n.resetWarningCache = t, Mr = function() { - function r(s, l, c, d, p, m) { - if (m !== e) { + return n.resetWarningCache = e, zr = function() { + function r(i, l, c, d, p, m) { + if (m !== t) { var w = new Error( "Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types" ); @@ -3581,26 +4301,26 @@ function Yc() { shape: o, exact: o, checkPropTypes: n, - resetWarningCache: t + resetWarningCache: e }; return a.PropTypes = a, a; - }, Mr; + }, zr; } if (process.env.NODE_ENV !== "production") { - var Wc = Os(), qc = !0; - Hr.exports = Xc()(Wc.isElement, qc); + var Kd = Zi(), Jd = !0; + qr.exports = Wd()(Kd.isElement, Jd); } else - Hr.exports = Yc()(); -var Kc = Hr.exports; -const u = /* @__PURE__ */ Vc(Kc); -function Jc(e) { + qr.exports = qd()(); +var Zd = qr.exports; +const u = /* @__PURE__ */ Ld(Zd); +function Qd(t) { const { - prototype: t = {} - } = e; - return !!t.isReactComponent; + prototype: e = {} + } = t; + return !!e.isReactComponent; } -function Ps(e, t, n, r, o) { - const a = e[t], s = o || t; +function ts(t, e, n, r, o) { + const a = t[e], i = o || e; if (a == null || // When server-side rendering React doesn't warn either. // This is not an accurate check for SSR. // This is only in place for Emotion compat. @@ -3609,26 +4329,26 @@ function Ps(e, t, n, r, o) { return null; let l; const c = a.type; - return typeof c == "function" && !Jc(c) && (l = "Did you accidentally use a plain function component for an element instead?"), l !== void 0 ? new Error(`Invalid ${r} \`${s}\` supplied to \`${n}\`. Expected an element that can hold a ref. ${l} For more information see https://mui.com/r/caveat-with-refs-guide`) : null; -} -const _s = co(u.element, Ps); -_s.isRequired = co(u.element.isRequired, Ps); -const $s = _s, Zc = "exact-prop: ​"; -function Qc(e) { - return process.env.NODE_ENV === "production" ? e : R({}, e, { - [Zc]: (t) => { - const n = Object.keys(t).filter((r) => !e.hasOwnProperty(r)); + return typeof c == "function" && !Qd(c) && (l = "Did you accidentally use a plain function component for an element instead?"), l !== void 0 ? new Error(`Invalid ${r} \`${i}\` supplied to \`${n}\`. Expected an element that can hold a ref. ${l} For more information see https://mui.com/r/caveat-with-refs-guide`) : null; +} +const es = mo(u.element, ts); +es.isRequired = mo(u.element.isRequired, ts); +const ns = es, tp = "exact-prop: ​"; +function ep(t) { + return process.env.NODE_ENV === "production" ? t : P({}, t, { + [tp]: (e) => { + const n = Object.keys(e).filter((r) => !t.hasOwnProperty(r)); return n.length > 0 ? new Error(`The following props are not supported: ${n.map((r) => `\`${r}\``).join(", ")}. Please remove them.`) : null; } }); } -function Vt(e) { - let t = "https://mui.com/production-error/?code=" + e; +function Ve(t) { + let e = "https://mui.com/production-error/?code=" + t; for (let n = 1; n < arguments.length; n += 1) - t += "&args[]=" + encodeURIComponent(arguments[n]); - return "Minified MUI error #" + e + "; visit " + t + " for the full message."; + e += "&args[]=" + encodeURIComponent(arguments[n]); + return "Minified MUI error #" + t + "; visit " + e + " for the full message."; } -var Xr = { exports: {} }, le = {}; +var Kr = { exports: {} }, lt = {}; /** * @license React * react-is.production.min.js @@ -3638,18 +4358,18 @@ var Xr = { exports: {} }, le = {}; * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. */ -var ia; -function ed() { - if (ia) - return le; - ia = 1; - var e = Symbol.for("react.element"), t = Symbol.for("react.portal"), n = Symbol.for("react.fragment"), r = Symbol.for("react.strict_mode"), o = Symbol.for("react.profiler"), a = Symbol.for("react.provider"), s = Symbol.for("react.context"), l = Symbol.for("react.server_context"), c = Symbol.for("react.forward_ref"), d = Symbol.for("react.suspense"), p = Symbol.for("react.suspense_list"), m = Symbol.for("react.memo"), w = Symbol.for("react.lazy"), b = Symbol.for("react.offscreen"), v; +var wa; +function np() { + if (wa) + return lt; + wa = 1; + var t = Symbol.for("react.element"), e = Symbol.for("react.portal"), n = Symbol.for("react.fragment"), r = Symbol.for("react.strict_mode"), o = Symbol.for("react.profiler"), a = Symbol.for("react.provider"), i = Symbol.for("react.context"), l = Symbol.for("react.server_context"), c = Symbol.for("react.forward_ref"), d = Symbol.for("react.suspense"), p = Symbol.for("react.suspense_list"), m = Symbol.for("react.memo"), w = Symbol.for("react.lazy"), g = Symbol.for("react.offscreen"), v; v = Symbol.for("react.module.reference"); function f(h) { if (typeof h == "object" && h !== null) { var E = h.$$typeof; switch (E) { - case e: + case t: switch (h = h.type, h) { case n: case o: @@ -3660,7 +4380,7 @@ function ed() { default: switch (h = h && h.$$typeof, h) { case l: - case s: + case i: case c: case w: case m: @@ -3670,44 +4390,44 @@ function ed() { return E; } } - case t: + case e: return E; } } } - return le.ContextConsumer = s, le.ContextProvider = a, le.Element = e, le.ForwardRef = c, le.Fragment = n, le.Lazy = w, le.Memo = m, le.Portal = t, le.Profiler = o, le.StrictMode = r, le.Suspense = d, le.SuspenseList = p, le.isAsyncMode = function() { + return lt.ContextConsumer = i, lt.ContextProvider = a, lt.Element = t, lt.ForwardRef = c, lt.Fragment = n, lt.Lazy = w, lt.Memo = m, lt.Portal = e, lt.Profiler = o, lt.StrictMode = r, lt.Suspense = d, lt.SuspenseList = p, lt.isAsyncMode = function() { return !1; - }, le.isConcurrentMode = function() { + }, lt.isConcurrentMode = function() { return !1; - }, le.isContextConsumer = function(h) { - return f(h) === s; - }, le.isContextProvider = function(h) { + }, lt.isContextConsumer = function(h) { + return f(h) === i; + }, lt.isContextProvider = function(h) { return f(h) === a; - }, le.isElement = function(h) { - return typeof h == "object" && h !== null && h.$$typeof === e; - }, le.isForwardRef = function(h) { + }, lt.isElement = function(h) { + return typeof h == "object" && h !== null && h.$$typeof === t; + }, lt.isForwardRef = function(h) { return f(h) === c; - }, le.isFragment = function(h) { + }, lt.isFragment = function(h) { return f(h) === n; - }, le.isLazy = function(h) { + }, lt.isLazy = function(h) { return f(h) === w; - }, le.isMemo = function(h) { + }, lt.isMemo = function(h) { return f(h) === m; - }, le.isPortal = function(h) { - return f(h) === t; - }, le.isProfiler = function(h) { + }, lt.isPortal = function(h) { + return f(h) === e; + }, lt.isProfiler = function(h) { return f(h) === o; - }, le.isStrictMode = function(h) { + }, lt.isStrictMode = function(h) { return f(h) === r; - }, le.isSuspense = function(h) { + }, lt.isSuspense = function(h) { return f(h) === d; - }, le.isSuspenseList = function(h) { + }, lt.isSuspenseList = function(h) { return f(h) === p; - }, le.isValidElementType = function(h) { - return typeof h == "string" || typeof h == "function" || h === n || h === o || h === r || h === d || h === p || h === b || typeof h == "object" && h !== null && (h.$$typeof === w || h.$$typeof === m || h.$$typeof === a || h.$$typeof === s || h.$$typeof === c || h.$$typeof === v || h.getModuleId !== void 0); - }, le.typeOf = f, le; + }, lt.isValidElementType = function(h) { + return typeof h == "string" || typeof h == "function" || h === n || h === o || h === r || h === d || h === p || h === g || typeof h == "object" && h !== null && (h.$$typeof === w || h.$$typeof === m || h.$$typeof === a || h.$$typeof === i || h.$$typeof === c || h.$$typeof === v || h.getModuleId !== void 0); + }, lt.typeOf = f, lt; } -var ce = {}; +var ct = {}; /** * @license React * react-is.development.js @@ -3717,293 +4437,293 @@ var ce = {}; * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. */ -var la; -function td() { - return la || (la = 1, process.env.NODE_ENV !== "production" && function() { - var e = Symbol.for("react.element"), t = Symbol.for("react.portal"), n = Symbol.for("react.fragment"), r = Symbol.for("react.strict_mode"), o = Symbol.for("react.profiler"), a = Symbol.for("react.provider"), s = Symbol.for("react.context"), l = Symbol.for("react.server_context"), c = Symbol.for("react.forward_ref"), d = Symbol.for("react.suspense"), p = Symbol.for("react.suspense_list"), m = Symbol.for("react.memo"), w = Symbol.for("react.lazy"), b = Symbol.for("react.offscreen"), v = !1, f = !1, h = !1, E = !1, A = !1, O; - O = Symbol.for("react.module.reference"); - function k(j) { - return !!(typeof j == "string" || typeof j == "function" || j === n || j === o || A || j === r || j === d || j === p || E || j === b || v || f || h || typeof j == "object" && j !== null && (j.$$typeof === w || j.$$typeof === m || j.$$typeof === a || j.$$typeof === s || j.$$typeof === c || // This needs to include all possible module reference object +var fa; +function rp() { + return fa || (fa = 1, process.env.NODE_ENV !== "production" && function() { + var t = Symbol.for("react.element"), e = Symbol.for("react.portal"), n = Symbol.for("react.fragment"), r = Symbol.for("react.strict_mode"), o = Symbol.for("react.profiler"), a = Symbol.for("react.provider"), i = Symbol.for("react.context"), l = Symbol.for("react.server_context"), c = Symbol.for("react.forward_ref"), d = Symbol.for("react.suspense"), p = Symbol.for("react.suspense_list"), m = Symbol.for("react.memo"), w = Symbol.for("react.lazy"), g = Symbol.for("react.offscreen"), v = !1, f = !1, h = !1, E = !1, _ = !1, C; + C = Symbol.for("react.module.reference"); + function S(j) { + return !!(typeof j == "string" || typeof j == "function" || j === n || j === o || _ || j === r || j === d || j === p || E || j === g || v || f || h || typeof j == "object" && j !== null && (j.$$typeof === w || j.$$typeof === m || j.$$typeof === a || j.$$typeof === i || j.$$typeof === c || // This needs to include all possible module reference object // types supported by any Flight configuration anywhere since // we don't know which Flight build this will end up being used // with. - j.$$typeof === O || j.getModuleId !== void 0)); + j.$$typeof === C || j.getModuleId !== void 0)); } - function g(j) { + function b(j) { if (typeof j == "object" && j !== null) { - var ye = j.$$typeof; - switch (ye) { - case e: - var ze = j.type; - switch (ze) { + var xt = j.$$typeof; + switch (xt) { + case t: + var Ft = j.type; + switch (Ft) { case n: case o: case r: case d: case p: - return ze; + return Ft; default: - var ct = ze && ze.$$typeof; - switch (ct) { + var ce = Ft && Ft.$$typeof; + switch (ce) { case l: - case s: + case i: case c: case w: case m: case a: - return ct; + return ce; default: - return ye; + return xt; } } - case t: - return ye; + case e: + return xt; } } } - var _ = s, L = a, H = e, C = c, P = n, N = w, B = m, D = t, J = o, q = r, U = d, ee = p, ae = !1, re = !1; + var I = i, z = a, H = t, O = c, $ = n, k = w, B = m, D = e, J = o, q = r, U = d, tt = p, at = !1, rt = !1; function y(j) { - return ae || (ae = !0, console.warn("The ReactIs.isAsyncMode() alias has been deprecated, and will be removed in React 18+.")), !1; + return at || (at = !0, console.warn("The ReactIs.isAsyncMode() alias has been deprecated, and will be removed in React 18+.")), !1; } - function S(j) { - return re || (re = !0, console.warn("The ReactIs.isConcurrentMode() alias has been deprecated, and will be removed in React 18+.")), !1; + function R(j) { + return rt || (rt = !0, console.warn("The ReactIs.isConcurrentMode() alias has been deprecated, and will be removed in React 18+.")), !1; } - function z(j) { - return g(j) === s; + function L(j) { + return b(j) === i; } function F(j) { - return g(j) === a; + return b(j) === a; } function V(j) { - return typeof j == "object" && j !== null && j.$$typeof === e; + return typeof j == "object" && j !== null && j.$$typeof === t; } function W(j) { - return g(j) === c; + return b(j) === c; } function X(j) { - return g(j) === n; + return b(j) === n; } function Y(j) { - return g(j) === w; + return b(j) === w; } function G(j) { - return g(j) === m; + return b(j) === m; } function K(j) { - return g(j) === t; + return b(j) === e; } function Z(j) { - return g(j) === o; - } - function de(j) { - return g(j) === r; - } - function $(j) { - return g(j) === d; - } - function xe(j) { - return g(j) === p; - } - ce.ContextConsumer = _, ce.ContextProvider = L, ce.Element = H, ce.ForwardRef = C, ce.Fragment = P, ce.Lazy = N, ce.Memo = B, ce.Portal = D, ce.Profiler = J, ce.StrictMode = q, ce.Suspense = U, ce.SuspenseList = ee, ce.isAsyncMode = y, ce.isConcurrentMode = S, ce.isContextConsumer = z, ce.isContextProvider = F, ce.isElement = V, ce.isForwardRef = W, ce.isFragment = X, ce.isLazy = Y, ce.isMemo = G, ce.isPortal = K, ce.isProfiler = Z, ce.isStrictMode = de, ce.isSuspense = $, ce.isSuspenseList = xe, ce.isValidElementType = k, ce.typeOf = g; - }()), ce; -} -process.env.NODE_ENV === "production" ? Xr.exports = ed() : Xr.exports = td(); -var ca = Xr.exports; -const nd = /^\s*function(?:\s|\s*\/\*.*\*\/\s*)+([^(\s/]*)\s*/; -function rd(e) { - const t = `${e}`.match(nd); - return t && t[1] || ""; -} -function Is(e, t = "") { - return e.displayName || e.name || rd(e) || t; -} -function da(e, t, n) { - const r = Is(t); - return e.displayName || (r !== "" ? `${n}(${r})` : n); -} -function od(e) { - if (e != null) { - if (typeof e == "string") - return e; - if (typeof e == "function") - return Is(e, "Component"); - if (typeof e == "object") - switch (e.$$typeof) { - case ca.ForwardRef: - return da(e, e.render, "ForwardRef"); - case ca.Memo: - return da(e, e.type, "memo"); + return b(j) === o; + } + function dt(j) { + return b(j) === r; + } + function A(j) { + return b(j) === d; + } + function Nt(j) { + return b(j) === p; + } + ct.ContextConsumer = I, ct.ContextProvider = z, ct.Element = H, ct.ForwardRef = O, ct.Fragment = $, ct.Lazy = k, ct.Memo = B, ct.Portal = D, ct.Profiler = J, ct.StrictMode = q, ct.Suspense = U, ct.SuspenseList = tt, ct.isAsyncMode = y, ct.isConcurrentMode = R, ct.isContextConsumer = L, ct.isContextProvider = F, ct.isElement = V, ct.isForwardRef = W, ct.isFragment = X, ct.isLazy = Y, ct.isMemo = G, ct.isPortal = K, ct.isProfiler = Z, ct.isStrictMode = dt, ct.isSuspense = A, ct.isSuspenseList = Nt, ct.isValidElementType = S, ct.typeOf = b; + }()), ct; +} +process.env.NODE_ENV === "production" ? Kr.exports = np() : Kr.exports = rp(); +var ma = Kr.exports; +const op = /^\s*function(?:\s|\s*\/\*.*\*\/\s*)+([^(\s/]*)\s*/; +function ap(t) { + const e = `${t}`.match(op); + return e && e[1] || ""; +} +function rs(t, e = "") { + return t.displayName || t.name || ap(t) || e; +} +function ha(t, e, n) { + const r = rs(e); + return t.displayName || (r !== "" ? `${n}(${r})` : n); +} +function ip(t) { + if (t != null) { + if (typeof t == "string") + return t; + if (typeof t == "function") + return rs(t, "Component"); + if (typeof t == "object") + switch (t.$$typeof) { + case ma.ForwardRef: + return ha(t, t.render, "ForwardRef"); + case ma.Memo: + return ha(t, t.type, "memo"); default: return; } } } -function gn(e, t, n, r, o) { +function yn(t, e, n, r, o) { if (process.env.NODE_ENV === "production") return null; - const a = e[t], s = o || t; - return a == null ? null : a && a.nodeType !== 1 ? new Error(`Invalid ${r} \`${s}\` supplied to \`${n}\`. Expected an HTMLElement.`) : null; -} -const ad = u.oneOfType([u.func, u.object]), As = ad; -function We(e) { - if (typeof e != "string") - throw new Error(process.env.NODE_ENV !== "production" ? "MUI: `capitalize(string)` expects a string argument." : Vt(7)); - return e.charAt(0).toUpperCase() + e.slice(1); -} -function sd(...e) { - return e.reduce((t, n) => n == null ? t : function(...o) { - t.apply(this, o), n.apply(this, o); + const a = t[e], i = o || e; + return a == null ? null : a && a.nodeType !== 1 ? new Error(`Invalid ${r} \`${i}\` supplied to \`${n}\`. Expected an HTMLElement.`) : null; +} +const sp = u.oneOfType([u.func, u.object]), os = sp; +function Wt(t) { + if (typeof t != "string") + throw new Error(process.env.NODE_ENV !== "production" ? "MUI: `capitalize(string)` expects a string argument." : Ve(7)); + return t.charAt(0).toUpperCase() + t.slice(1); +} +function lp(...t) { + return t.reduce((e, n) => n == null ? e : function(...o) { + e.apply(this, o), n.apply(this, o); }, () => { }); } -function id(e, t = 166) { +function cp(t, e = 166) { let n; function r(...o) { const a = () => { - e.apply(this, o); + t.apply(this, o); }; - clearTimeout(n), n = setTimeout(a, t); + clearTimeout(n), n = setTimeout(a, e); } return r.clear = () => { clearTimeout(n); }, r; } -function ld(e, t) { - return process.env.NODE_ENV === "production" ? () => null : (n, r, o, a, s) => { - const l = o || "<>", c = s || r; - return typeof n[r] < "u" ? new Error(`The ${a} \`${c}\` of \`${l}\` is deprecated. ${t}`) : null; +function dp(t, e) { + return process.env.NODE_ENV === "production" ? () => null : (n, r, o, a, i) => { + const l = o || "<>", c = i || r; + return typeof n[r] < "u" ? new Error(`The ${a} \`${c}\` of \`${l}\` is deprecated. ${e}`) : null; }; } -function cd(e, t) { +function pp(t, e) { var n, r; - return /* @__PURE__ */ M.isValidElement(e) && t.indexOf( + return /* @__PURE__ */ M.isValidElement(t) && e.indexOf( // For server components `muiName` is avaialble in element.type._payload.value.muiName // relevant info - https://github.com/facebook/react/blob/2807d781a08db8e9873687fccc25c0f12b4fb3d4/packages/react/src/ReactLazy.js#L45 // eslint-disable-next-line no-underscore-dangle - (n = e.type.muiName) != null ? n : (r = e.type) == null || (r = r._payload) == null || (r = r.value) == null ? void 0 : r.muiName + (n = t.type.muiName) != null ? n : (r = t.type) == null || (r = r._payload) == null || (r = r.value) == null ? void 0 : r.muiName ) !== -1; } -function Gn(e) { - return e && e.ownerDocument || document; +function Yn(t) { + return t && t.ownerDocument || document; } -function dd(e) { - return Gn(e).defaultView || window; +function up(t) { + return Yn(t).defaultView || window; } -function pd(e, t) { +function wp(t, e) { if (process.env.NODE_ENV === "production") return () => null; - const n = t ? R({}, t.propTypes) : null; - return (o) => (a, s, l, c, d, ...p) => { - const m = d || s, w = n == null ? void 0 : n[m]; + const n = e ? P({}, e.propTypes) : null; + return (o) => (a, i, l, c, d, ...p) => { + const m = d || i, w = n == null ? void 0 : n[m]; if (w) { - const b = w(a, s, l, c, d, ...p); - if (b) - return b; + const g = w(a, i, l, c, d, ...p); + if (g) + return g; } - return typeof a[s] < "u" && !a[o] ? new Error(`The prop \`${m}\` of \`${e}\` can only be used together with the \`${o}\` prop.`) : null; + return typeof a[i] < "u" && !a[o] ? new Error(`The prop \`${m}\` of \`${t}\` can only be used together with the \`${o}\` prop.`) : null; }; } -function Hn(e, t) { - typeof e == "function" ? e(t) : e && (e.current = t); +function Wn(t, e) { + typeof t == "function" ? t(e) : t && (t.current = e); } -const ud = typeof window < "u" ? M.useLayoutEffect : M.useEffect, Lt = ud; -let pa = 0; -function wd(e) { - const [t, n] = M.useState(e), r = e || t; +const fp = typeof window < "u" ? M.useLayoutEffect : M.useEffect, ze = fp; +let ga = 0; +function mp(t) { + const [e, n] = M.useState(t), r = t || e; return M.useEffect(() => { - t == null && (pa += 1, n(`mui-${pa}`)); - }, [t]), r; + e == null && (ga += 1, n(`mui-${ga}`)); + }, [e]), r; } -const ua = M["useId".toString()]; -function Ds(e) { - if (ua !== void 0) { - const t = ua(); - return e ?? t; +const ba = M["useId".toString()]; +function as(t) { + if (ba !== void 0) { + const e = ba(); + return t ?? e; } - return wd(e); + return mp(t); } -function fd(e, t, n, r, o) { +function hp(t, e, n, r, o) { if (process.env.NODE_ENV === "production") return null; - const a = o || t; - return typeof e[t] < "u" ? new Error(`The prop \`${a}\` is not supported. Please remove it.`) : null; + const a = o || e; + return typeof t[e] < "u" ? new Error(`The prop \`${a}\` is not supported. Please remove it.`) : null; } -function Ms({ - controlled: e, - default: t, +function is({ + controlled: t, + default: e, name: n, state: r = "value" }) { const { current: o - } = M.useRef(e !== void 0), [a, s] = M.useState(t), l = o ? e : a; + } = M.useRef(t !== void 0), [a, i] = M.useState(e), l = o ? t : a; if (process.env.NODE_ENV !== "production") { M.useEffect(() => { - o !== (e !== void 0) && console.error([`MUI: A component is changing the ${o ? "" : "un"}controlled ${r} state of ${n} to be ${o ? "un" : ""}controlled.`, "Elements should not switch from uncontrolled to controlled (or vice versa).", `Decide between using a controlled or uncontrolled ${n} element for the lifetime of the component.`, "The nature of the state is determined during the first render. It's considered controlled if the value is not `undefined`.", "More info: https://fb.me/react-controlled-components"].join(` + o !== (t !== void 0) && console.error([`MUI: A component is changing the ${o ? "" : "un"}controlled ${r} state of ${n} to be ${o ? "un" : ""}controlled.`, "Elements should not switch from uncontrolled to controlled (or vice versa).", `Decide between using a controlled or uncontrolled ${n} element for the lifetime of the component.`, "The nature of the state is determined during the first render. It's considered controlled if the value is not `undefined`.", "More info: https://fb.me/react-controlled-components"].join(` `)); - }, [r, n, e]); + }, [r, n, t]); const { current: d - } = M.useRef(t); + } = M.useRef(e); M.useEffect(() => { - !o && d !== t && console.error([`MUI: A component is changing the default ${r} state of an uncontrolled ${n} after being initialized. To suppress this warning opt to use a controlled ${n}.`].join(` + !o && d !== e && console.error([`MUI: A component is changing the default ${r} state of an uncontrolled ${n} after being initialized. To suppress this warning opt to use a controlled ${n}.`].join(` `)); - }, [JSON.stringify(t)]); + }, [JSON.stringify(e)]); } const c = M.useCallback((d) => { - o || s(d); + o || i(d); }, []); return [l, c]; } -function Yr(e) { - const t = M.useRef(e); - return Lt(() => { - t.current = e; +function Jr(t) { + const e = M.useRef(t); + return ze(() => { + e.current = t; }), M.useRef((...n) => ( // @ts-expect-error hide `this` - (0, t.current)(...n) + (0, e.current)(...n) )).current; } -function xt(...e) { - return M.useMemo(() => e.every((t) => t == null) ? null : (t) => { - e.forEach((n) => { - Hn(n, t); +function xe(...t) { + return M.useMemo(() => t.every((e) => e == null) ? null : (e) => { + t.forEach((n) => { + Wn(n, e); }); - }, e); + }, t); } -const wa = {}; -function md(e, t) { - const n = M.useRef(wa); - return n.current === wa && (n.current = e(t)), n; +const va = {}; +function gp(t, e) { + const n = M.useRef(va); + return n.current === va && (n.current = t(e)), n; } -const hd = []; -function gd(e) { - M.useEffect(e, hd); +const bp = []; +function vp(t) { + M.useEffect(t, bp); } -class kn { +class Tn { constructor() { this.currentId = null, this.clear = () => { this.currentId !== null && (clearTimeout(this.currentId), this.currentId = null); }, this.disposeEffect = () => this.clear; } static create() { - return new kn(); + return new Tn(); } /** * Executes `fn` after `delay`, clearing any previously scheduled call. */ - start(t, n) { + start(e, n) { this.clear(), this.currentId = setTimeout(() => { this.currentId = null, n(); - }, t); + }, e); } } -function rn() { - const e = md(kn.create).current; - return gd(e.disposeEffect), e; +function sn() { + const t = gp(Tn.create).current; + return vp(t.disposeEffect), t; } -let ir = !0, Wr = !1; -const bd = new kn(), vd = { +let dr = !0, Zr = !1; +const yp = new Tn(), xp = { text: !0, search: !0, url: !0, @@ -4018,98 +4738,98 @@ const bd = new kn(), vd = { datetime: !0, "datetime-local": !0 }; -function yd(e) { +function Np(t) { const { - type: t, + type: e, tagName: n - } = e; - return !!(n === "INPUT" && vd[t] && !e.readOnly || n === "TEXTAREA" && !e.readOnly || e.isContentEditable); + } = t; + return !!(n === "INPUT" && xp[e] && !t.readOnly || n === "TEXTAREA" && !t.readOnly || t.isContentEditable); } -function xd(e) { - e.metaKey || e.altKey || e.ctrlKey || (ir = !0); +function kp(t) { + t.metaKey || t.altKey || t.ctrlKey || (dr = !0); } -function Br() { - ir = !1; +function Lr() { + dr = !1; } -function Nd() { - this.visibilityState === "hidden" && Wr && (ir = !0); +function Ep() { + this.visibilityState === "hidden" && Zr && (dr = !0); } -function kd(e) { - e.addEventListener("keydown", xd, !0), e.addEventListener("mousedown", Br, !0), e.addEventListener("pointerdown", Br, !0), e.addEventListener("touchstart", Br, !0), e.addEventListener("visibilitychange", Nd, !0); +function Sp(t) { + t.addEventListener("keydown", kp, !0), t.addEventListener("mousedown", Lr, !0), t.addEventListener("pointerdown", Lr, !0), t.addEventListener("touchstart", Lr, !0), t.addEventListener("visibilitychange", Ep, !0); } -function Ed(e) { +function Tp(t) { const { - target: t - } = e; + target: e + } = t; try { - return t.matches(":focus-visible"); + return e.matches(":focus-visible"); } catch { } - return ir || yd(t); + return dr || Np(e); } -function Bs() { - const e = M.useCallback((o) => { - o != null && kd(o.ownerDocument); - }, []), t = M.useRef(!1); +function ss() { + const t = M.useCallback((o) => { + o != null && Sp(o.ownerDocument); + }, []), e = M.useRef(!1); function n() { - return t.current ? (Wr = !0, bd.start(100, () => { - Wr = !1; - }), t.current = !1, !0) : !1; + return e.current ? (Zr = !0, yp.start(100, () => { + Zr = !1; + }), e.current = !1, !0) : !1; } function r(o) { - return Ed(o) ? (t.current = !0, !0) : !1; + return Tp(o) ? (e.current = !0, !0) : !1; } return { - isFocusVisibleRef: t, + isFocusVisibleRef: e, onFocus: r, onBlur: n, - ref: e + ref: t }; } -function js(e, t) { - const n = R({}, t); - return Object.keys(e).forEach((r) => { +function ls(t, e) { + const n = P({}, e); + return Object.keys(t).forEach((r) => { if (r.toString().match(/^(components|slots)$/)) - n[r] = R({}, e[r], n[r]); + n[r] = P({}, t[r], n[r]); else if (r.toString().match(/^(componentsProps|slotProps)$/)) { - const o = e[r] || {}, a = t[r]; - n[r] = {}, !a || !Object.keys(a) ? n[r] = o : !o || !Object.keys(o) ? n[r] = a : (n[r] = R({}, a), Object.keys(o).forEach((s) => { - n[r][s] = js(o[s], a[s]); + const o = t[r] || {}, a = e[r]; + n[r] = {}, !a || !Object.keys(a) ? n[r] = o : !o || !Object.keys(o) ? n[r] = a : (n[r] = P({}, a), Object.keys(o).forEach((i) => { + n[r][i] = ls(o[i], a[i]); })); } else - n[r] === void 0 && (n[r] = e[r]); + n[r] === void 0 && (n[r] = t[r]); }), n; } -function uo(e, t, n = void 0) { +function go(t, e, n = void 0) { const r = {}; - return Object.keys(e).forEach( + return Object.keys(t).forEach( // `Object.keys(slots)` can't be wider than `T` because we infer `T` from `slots`. // @ts-expect-error https://github.com/microsoft/TypeScript/pull/12253#issuecomment-263132208 (o) => { - r[o] = e[o].reduce((a, s) => { - if (s) { - const l = t(s); - l !== "" && a.push(l), n && n[s] && a.push(n[s]); + r[o] = t[o].reduce((a, i) => { + if (i) { + const l = e(i); + l !== "" && a.push(l), n && n[i] && a.push(n[i]); } return a; }, []).join(" "); } ), r; } -const fa = (e) => e, Td = () => { - let e = fa; +const ya = (t) => t, Cp = () => { + let t = ya; return { - configure(t) { - e = t; + configure(e) { + t = e; }, - generate(t) { - return e(t); + generate(e) { + return t(e); }, reset() { - e = fa; + t = ya; } }; -}, Cd = Td(), Vs = Cd, Ls = { +}, Op = Cp(), cs = Op, ds = { active: "active", checked: "checked", completed: "completed", @@ -4123,41 +4843,41 @@ const fa = (e) => e, Td = () => { required: "required", selected: "selected" }; -function lr(e, t, n = "Mui") { - const r = Ls[t]; - return r ? `${n}-${r}` : `${Vs.generate(e)}-${t}`; +function pr(t, e, n = "Mui") { + const r = ds[e]; + return r ? `${n}-${r}` : `${cs.generate(t)}-${e}`; } -function zs(e, t, n = "Mui") { +function ps(t, e, n = "Mui") { const r = {}; - return t.forEach((o) => { - r[o] = lr(e, o, n); + return e.forEach((o) => { + r[o] = pr(t, o, n); }), r; } -function Sd(e, t = Number.MIN_SAFE_INTEGER, n = Number.MAX_SAFE_INTEGER) { - return Math.max(t, Math.min(e, n)); +function Rp(t, e = Number.MIN_SAFE_INTEGER, n = Number.MAX_SAFE_INTEGER) { + return Math.max(e, Math.min(t, n)); } -function Ne(e, t) { - if (e == null) +function kt(t, e) { + if (t == null) return {}; - var n = {}, r = Object.keys(e), o, a; + var n = {}, r = Object.keys(t), o, a; for (a = 0; a < r.length; a++) - o = r[a], !(t.indexOf(o) >= 0) && (n[o] = e[o]); + o = r[a], !(e.indexOf(o) >= 0) && (n[o] = t[o]); return n; } -const Od = ["values", "unit", "step"], Rd = (e) => { - const t = Object.keys(e).map((n) => ({ +const _p = ["values", "unit", "step"], Pp = (t) => { + const e = Object.keys(t).map((n) => ({ key: n, - val: e[n] + val: t[n] })) || []; - return t.sort((n, r) => n.val - r.val), t.reduce((n, r) => R({}, n, { + return e.sort((n, r) => n.val - r.val), e.reduce((n, r) => P({}, n, { [r.key]: r.val }), {}); }; -function Pd(e) { +function $p(t) { const { // The breakpoint **start** at this value. // For instance with the first breakpoint xs: [xs, sm). - values: t = { + values: e = { xs: 0, // phone sm: 600, @@ -4171,26 +4891,26 @@ function Pd(e) { }, unit: n = "px", step: r = 5 - } = e, o = Ne(e, Od), a = Rd(t), s = Object.keys(a); + } = t, o = kt(t, _p), a = Pp(e), i = Object.keys(a); function l(w) { - return `@media (min-width:${typeof t[w] == "number" ? t[w] : w}${n})`; + return `@media (min-width:${typeof e[w] == "number" ? e[w] : w}${n})`; } function c(w) { - return `@media (max-width:${(typeof t[w] == "number" ? t[w] : w) - r / 100}${n})`; + return `@media (max-width:${(typeof e[w] == "number" ? e[w] : w) - r / 100}${n})`; } - function d(w, b) { - const v = s.indexOf(b); - return `@media (min-width:${typeof t[w] == "number" ? t[w] : w}${n}) and (max-width:${(v !== -1 && typeof t[s[v]] == "number" ? t[s[v]] : b) - r / 100}${n})`; + function d(w, g) { + const v = i.indexOf(g); + return `@media (min-width:${typeof e[w] == "number" ? e[w] : w}${n}) and (max-width:${(v !== -1 && typeof e[i[v]] == "number" ? e[i[v]] : g) - r / 100}${n})`; } function p(w) { - return s.indexOf(w) + 1 < s.length ? d(w, s[s.indexOf(w) + 1]) : l(w); + return i.indexOf(w) + 1 < i.length ? d(w, i[i.indexOf(w) + 1]) : l(w); } function m(w) { - const b = s.indexOf(w); - return b === 0 ? l(s[1]) : b === s.length - 1 ? c(s[b]) : d(w, s[s.indexOf(w) + 1]).replace("@media", "@media not all and"); + const g = i.indexOf(w); + return g === 0 ? l(i[1]) : g === i.length - 1 ? c(i[g]) : d(w, i[i.indexOf(w) + 1]).replace("@media", "@media not all and"); } - return R({ - keys: s, + return P({ + keys: i, values: a, up: l, down: c, @@ -4200,16 +4920,16 @@ function Pd(e) { unit: n }, o); } -const _d = { +const Ip = { borderRadius: 4 -}, $d = _d, Id = process.env.NODE_ENV !== "production" ? u.oneOfType([u.number, u.string, u.object, u.array]) : {}, it = Id; -function cn(e, t) { - return t ? Ze(e, t, { +}, Ap = Ip, Mp = process.env.NODE_ENV !== "production" ? u.oneOfType([u.number, u.string, u.object, u.array]) : {}, se = Mp; +function un(t, e) { + return e ? Zt(t, e, { clone: !1 // No need to clone deep, it's way faster. - }) : e; + }) : t; } -const wo = { +const bo = { xs: 0, // phone sm: 600, @@ -4220,341 +4940,341 @@ const wo = { // desktop xl: 1536 // large screen -}, ma = { +}, xa = { // Sorted ASC by size. That's important. // It can't be configured as it's used statically for propTypes. keys: ["xs", "sm", "md", "lg", "xl"], - up: (e) => `@media (min-width:${wo[e]}px)` + up: (t) => `@media (min-width:${bo[t]}px)` }; -function Qe(e, t, n) { - const r = e.theme || {}; - if (Array.isArray(t)) { - const a = r.breakpoints || ma; - return t.reduce((s, l, c) => (s[a.up(a.keys[c])] = n(t[c]), s), {}); - } - if (typeof t == "object") { - const a = r.breakpoints || ma; - return Object.keys(t).reduce((s, l) => { - if (Object.keys(a.values || wo).indexOf(l) !== -1) { +function Qt(t, e, n) { + const r = t.theme || {}; + if (Array.isArray(e)) { + const a = r.breakpoints || xa; + return e.reduce((i, l, c) => (i[a.up(a.keys[c])] = n(e[c]), i), {}); + } + if (typeof e == "object") { + const a = r.breakpoints || xa; + return Object.keys(e).reduce((i, l) => { + if (Object.keys(a.values || bo).indexOf(l) !== -1) { const c = a.up(l); - s[c] = n(t[l], l); + i[c] = n(e[l], l); } else { const c = l; - s[c] = t[c]; + i[c] = e[c]; } - return s; + return i; }, {}); } - return n(t); + return n(e); } -function Ad(e = {}) { - var t; - return ((t = e.keys) == null ? void 0 : t.reduce((r, o) => { - const a = e.up(o); +function Dp(t = {}) { + var e; + return ((e = t.keys) == null ? void 0 : e.reduce((r, o) => { + const a = t.up(o); return r[a] = {}, r; }, {})) || {}; } -function Dd(e, t) { - return e.reduce((n, r) => { +function Bp(t, e) { + return t.reduce((n, r) => { const o = n[r]; return (!o || Object.keys(o).length === 0) && delete n[r], n; - }, t); + }, e); } -function cr(e, t, n = !0) { - if (!t || typeof t != "string") +function ur(t, e, n = !0) { + if (!e || typeof e != "string") return null; - if (e && e.vars && n) { - const r = `vars.${t}`.split(".").reduce((o, a) => o && o[a] ? o[a] : null, e); + if (t && t.vars && n) { + const r = `vars.${e}`.split(".").reduce((o, a) => o && o[a] ? o[a] : null, t); if (r != null) return r; } - return t.split(".").reduce((r, o) => r && r[o] != null ? r[o] : null, e); + return e.split(".").reduce((r, o) => r && r[o] != null ? r[o] : null, t); } -function Xn(e, t, n, r = n) { +function qn(t, e, n, r = n) { let o; - return typeof e == "function" ? o = e(n) : Array.isArray(e) ? o = e[n] || r : o = cr(e, n) || r, t && (o = t(o, r, e)), o; + return typeof t == "function" ? o = t(n) : Array.isArray(t) ? o = t[n] || r : o = ur(t, n) || r, e && (o = e(o, r, t)), o; } -function ve(e) { +function yt(t) { const { - prop: t, - cssProperty: n = e.prop, + prop: e, + cssProperty: n = t.prop, themeKey: r, transform: o - } = e, a = (s) => { - if (s[t] == null) + } = t, a = (i) => { + if (i[e] == null) return null; - const l = s[t], c = s.theme, d = cr(c, r) || {}; - return Qe(s, l, (m) => { - let w = Xn(d, o, m); - return m === w && typeof m == "string" && (w = Xn(d, o, `${t}${m === "default" ? "" : We(m)}`, m)), n === !1 ? w : { + const l = i[e], c = i.theme, d = ur(c, r) || {}; + return Qt(i, l, (m) => { + let w = qn(d, o, m); + return m === w && typeof m == "string" && (w = qn(d, o, `${e}${m === "default" ? "" : Wt(m)}`, m)), n === !1 ? w : { [n]: w }; }); }; return a.propTypes = process.env.NODE_ENV !== "production" ? { - [t]: it - } : {}, a.filterProps = [t], a; + [e]: se + } : {}, a.filterProps = [e], a; } -function Md(e) { - const t = {}; - return (n) => (t[n] === void 0 && (t[n] = e(n)), t[n]); +function jp(t) { + const e = {}; + return (n) => (e[n] === void 0 && (e[n] = t(n)), e[n]); } -const Bd = { +const Vp = { m: "margin", p: "padding" -}, jd = { +}, zp = { t: "Top", r: "Right", b: "Bottom", l: "Left", x: ["Left", "Right"], y: ["Top", "Bottom"] -}, ha = { +}, Na = { marginX: "mx", marginY: "my", paddingX: "px", paddingY: "py" -}, Vd = Md((e) => { - if (e.length > 2) - if (ha[e]) - e = ha[e]; +}, Lp = jp((t) => { + if (t.length > 2) + if (Na[t]) + t = Na[t]; else - return [e]; - const [t, n] = e.split(""), r = Bd[t], o = jd[n] || ""; + return [t]; + const [e, n] = t.split(""), r = Vp[e], o = zp[n] || ""; return Array.isArray(o) ? o.map((a) => r + a) : [r + o]; -}), dr = ["m", "mt", "mr", "mb", "ml", "mx", "my", "margin", "marginTop", "marginRight", "marginBottom", "marginLeft", "marginX", "marginY", "marginInline", "marginInlineStart", "marginInlineEnd", "marginBlock", "marginBlockStart", "marginBlockEnd"], pr = ["p", "pt", "pr", "pb", "pl", "px", "py", "padding", "paddingTop", "paddingRight", "paddingBottom", "paddingLeft", "paddingX", "paddingY", "paddingInline", "paddingInlineStart", "paddingInlineEnd", "paddingBlock", "paddingBlockStart", "paddingBlockEnd"], Ld = [...dr, ...pr]; -function En(e, t, n, r) { +}), wr = ["m", "mt", "mr", "mb", "ml", "mx", "my", "margin", "marginTop", "marginRight", "marginBottom", "marginLeft", "marginX", "marginY", "marginInline", "marginInlineStart", "marginInlineEnd", "marginBlock", "marginBlockStart", "marginBlockEnd"], fr = ["p", "pt", "pr", "pb", "pl", "px", "py", "padding", "paddingTop", "paddingRight", "paddingBottom", "paddingLeft", "paddingX", "paddingY", "paddingInline", "paddingInlineStart", "paddingInlineEnd", "paddingBlock", "paddingBlockStart", "paddingBlockEnd"], Fp = [...wr, ...fr]; +function Cn(t, e, n, r) { var o; - const a = (o = cr(e, t, !1)) != null ? o : n; - return typeof a == "number" ? (s) => typeof s == "string" ? s : (process.env.NODE_ENV !== "production" && typeof s != "number" && console.error(`MUI: Expected ${r} argument to be a number or a string, got ${s}.`), a * s) : Array.isArray(a) ? (s) => typeof s == "string" ? s : (process.env.NODE_ENV !== "production" && (Number.isInteger(s) ? s > a.length - 1 && console.error([`MUI: The value provided (${s}) overflows.`, `The supported values are: ${JSON.stringify(a)}.`, `${s} > ${a.length - 1}, you need to add the missing values.`].join(` -`)) : console.error([`MUI: The \`theme.${t}\` array type cannot be combined with non integer values.You should either use an integer value that can be used as index, or define the \`theme.${t}\` as a number.`].join(` -`))), a[s]) : typeof a == "function" ? a : (process.env.NODE_ENV !== "production" && console.error([`MUI: The \`theme.${t}\` value (${a}) is invalid.`, "It should be a number, an array or a function."].join(` + const a = (o = ur(t, e, !1)) != null ? o : n; + return typeof a == "number" ? (i) => typeof i == "string" ? i : (process.env.NODE_ENV !== "production" && typeof i != "number" && console.error(`MUI: Expected ${r} argument to be a number or a string, got ${i}.`), a * i) : Array.isArray(a) ? (i) => typeof i == "string" ? i : (process.env.NODE_ENV !== "production" && (Number.isInteger(i) ? i > a.length - 1 && console.error([`MUI: The value provided (${i}) overflows.`, `The supported values are: ${JSON.stringify(a)}.`, `${i} > ${a.length - 1}, you need to add the missing values.`].join(` +`)) : console.error([`MUI: The \`theme.${e}\` array type cannot be combined with non integer values.You should either use an integer value that can be used as index, or define the \`theme.${e}\` as a number.`].join(` +`))), a[i]) : typeof a == "function" ? a : (process.env.NODE_ENV !== "production" && console.error([`MUI: The \`theme.${e}\` value (${a}) is invalid.`, "It should be a number, an array or a function."].join(` `)), () => { }); } -function Fs(e) { - return En(e, "spacing", 8, "spacing"); +function us(t) { + return Cn(t, "spacing", 8, "spacing"); } -function Tn(e, t) { - if (typeof t == "string" || t == null) - return t; - const n = Math.abs(t), r = e(n); - return t >= 0 ? r : typeof r == "number" ? -r : `-${r}`; +function On(t, e) { + if (typeof e == "string" || e == null) + return e; + const n = Math.abs(e), r = t(n); + return e >= 0 ? r : typeof r == "number" ? -r : `-${r}`; } -function zd(e, t) { - return (n) => e.reduce((r, o) => (r[o] = Tn(t, n), r), {}); +function Up(t, e) { + return (n) => t.reduce((r, o) => (r[o] = On(e, n), r), {}); } -function Fd(e, t, n, r) { - if (t.indexOf(n) === -1) +function Gp(t, e, n, r) { + if (e.indexOf(n) === -1) return null; - const o = Vd(n), a = zd(o, r), s = e[n]; - return Qe(e, s, a); -} -function Us(e, t) { - const n = Fs(e.theme); - return Object.keys(e).map((r) => Fd(e, t, r, n)).reduce(cn, {}); -} -function me(e) { - return Us(e, dr); -} -me.propTypes = process.env.NODE_ENV !== "production" ? dr.reduce((e, t) => (e[t] = it, e), {}) : {}; -me.filterProps = dr; -function he(e) { - return Us(e, pr); -} -he.propTypes = process.env.NODE_ENV !== "production" ? pr.reduce((e, t) => (e[t] = it, e), {}) : {}; -he.filterProps = pr; -process.env.NODE_ENV !== "production" && Ld.reduce((e, t) => (e[t] = it, e), {}); -function Ud(e = 8) { - if (e.mui) - return e; - const t = Fs({ - spacing: e + const o = Lp(n), a = Up(o, r), i = t[n]; + return Qt(t, i, a); +} +function ws(t, e) { + const n = us(t.theme); + return Object.keys(t).map((r) => Gp(t, e, r, n)).reduce(un, {}); +} +function mt(t) { + return ws(t, wr); +} +mt.propTypes = process.env.NODE_ENV !== "production" ? wr.reduce((t, e) => (t[e] = se, t), {}) : {}; +mt.filterProps = wr; +function ht(t) { + return ws(t, fr); +} +ht.propTypes = process.env.NODE_ENV !== "production" ? fr.reduce((t, e) => (t[e] = se, t), {}) : {}; +ht.filterProps = fr; +process.env.NODE_ENV !== "production" && Fp.reduce((t, e) => (t[e] = se, t), {}); +function Hp(t = 8) { + if (t.mui) + return t; + const e = us({ + spacing: t }), n = (...r) => (process.env.NODE_ENV !== "production" && (r.length <= 4 || console.error(`MUI: Too many arguments provided, expected between 0 and 4, got ${r.length}`)), (r.length === 0 ? [1] : r).map((a) => { - const s = t(a); - return typeof s == "number" ? `${s}px` : s; + const i = e(a); + return typeof i == "number" ? `${i}px` : i; }).join(" ")); return n.mui = !0, n; } -function ur(...e) { - const t = e.reduce((r, o) => (o.filterProps.forEach((a) => { +function mr(...t) { + const e = t.reduce((r, o) => (o.filterProps.forEach((a) => { r[a] = o; - }), r), {}), n = (r) => Object.keys(r).reduce((o, a) => t[a] ? cn(o, t[a](r)) : o, {}); - return n.propTypes = process.env.NODE_ENV !== "production" ? e.reduce((r, o) => Object.assign(r, o.propTypes), {}) : {}, n.filterProps = e.reduce((r, o) => r.concat(o.filterProps), []), n; + }), r), {}), n = (r) => Object.keys(r).reduce((o, a) => e[a] ? un(o, e[a](r)) : o, {}); + return n.propTypes = process.env.NODE_ENV !== "production" ? t.reduce((r, o) => Object.assign(r, o.propTypes), {}) : {}, n.filterProps = t.reduce((r, o) => r.concat(o.filterProps), []), n; } -function De(e) { - return typeof e != "number" ? e : `${e}px solid`; +function Dt(t) { + return typeof t != "number" ? t : `${t}px solid`; } -function Le(e, t) { - return ve({ - prop: e, +function Lt(t, e) { + return yt({ + prop: t, themeKey: "borders", - transform: t + transform: e }); } -const Gd = Le("border", De), Hd = Le("borderTop", De), Xd = Le("borderRight", De), Yd = Le("borderBottom", De), Wd = Le("borderLeft", De), qd = Le("borderColor"), Kd = Le("borderTopColor"), Jd = Le("borderRightColor"), Zd = Le("borderBottomColor"), Qd = Le("borderLeftColor"), ep = Le("outline", De), tp = Le("outlineColor"), wr = (e) => { - if (e.borderRadius !== void 0 && e.borderRadius !== null) { - const t = En(e.theme, "shape.borderRadius", 4, "borderRadius"), n = (r) => ({ - borderRadius: Tn(t, r) +const Xp = Lt("border", Dt), Yp = Lt("borderTop", Dt), Wp = Lt("borderRight", Dt), qp = Lt("borderBottom", Dt), Kp = Lt("borderLeft", Dt), Jp = Lt("borderColor"), Zp = Lt("borderTopColor"), Qp = Lt("borderRightColor"), tu = Lt("borderBottomColor"), eu = Lt("borderLeftColor"), nu = Lt("outline", Dt), ru = Lt("outlineColor"), hr = (t) => { + if (t.borderRadius !== void 0 && t.borderRadius !== null) { + const e = Cn(t.theme, "shape.borderRadius", 4, "borderRadius"), n = (r) => ({ + borderRadius: On(e, r) }); - return Qe(e, e.borderRadius, n); + return Qt(t, t.borderRadius, n); } return null; }; -wr.propTypes = process.env.NODE_ENV !== "production" ? { - borderRadius: it +hr.propTypes = process.env.NODE_ENV !== "production" ? { + borderRadius: se } : {}; -wr.filterProps = ["borderRadius"]; -ur(Gd, Hd, Xd, Yd, Wd, qd, Kd, Jd, Zd, Qd, wr, ep, tp); -const fr = (e) => { - if (e.gap !== void 0 && e.gap !== null) { - const t = En(e.theme, "spacing", 8, "gap"), n = (r) => ({ - gap: Tn(t, r) +hr.filterProps = ["borderRadius"]; +mr(Xp, Yp, Wp, qp, Kp, Jp, Zp, Qp, tu, eu, hr, nu, ru); +const gr = (t) => { + if (t.gap !== void 0 && t.gap !== null) { + const e = Cn(t.theme, "spacing", 8, "gap"), n = (r) => ({ + gap: On(e, r) }); - return Qe(e, e.gap, n); + return Qt(t, t.gap, n); } return null; }; -fr.propTypes = process.env.NODE_ENV !== "production" ? { - gap: it +gr.propTypes = process.env.NODE_ENV !== "production" ? { + gap: se } : {}; -fr.filterProps = ["gap"]; -const mr = (e) => { - if (e.columnGap !== void 0 && e.columnGap !== null) { - const t = En(e.theme, "spacing", 8, "columnGap"), n = (r) => ({ - columnGap: Tn(t, r) +gr.filterProps = ["gap"]; +const br = (t) => { + if (t.columnGap !== void 0 && t.columnGap !== null) { + const e = Cn(t.theme, "spacing", 8, "columnGap"), n = (r) => ({ + columnGap: On(e, r) }); - return Qe(e, e.columnGap, n); + return Qt(t, t.columnGap, n); } return null; }; -mr.propTypes = process.env.NODE_ENV !== "production" ? { - columnGap: it +br.propTypes = process.env.NODE_ENV !== "production" ? { + columnGap: se } : {}; -mr.filterProps = ["columnGap"]; -const hr = (e) => { - if (e.rowGap !== void 0 && e.rowGap !== null) { - const t = En(e.theme, "spacing", 8, "rowGap"), n = (r) => ({ - rowGap: Tn(t, r) +br.filterProps = ["columnGap"]; +const vr = (t) => { + if (t.rowGap !== void 0 && t.rowGap !== null) { + const e = Cn(t.theme, "spacing", 8, "rowGap"), n = (r) => ({ + rowGap: On(e, r) }); - return Qe(e, e.rowGap, n); + return Qt(t, t.rowGap, n); } return null; }; -hr.propTypes = process.env.NODE_ENV !== "production" ? { - rowGap: it +vr.propTypes = process.env.NODE_ENV !== "production" ? { + rowGap: se } : {}; -hr.filterProps = ["rowGap"]; -const np = ve({ +vr.filterProps = ["rowGap"]; +const ou = yt({ prop: "gridColumn" -}), rp = ve({ +}), au = yt({ prop: "gridRow" -}), op = ve({ +}), iu = yt({ prop: "gridAutoFlow" -}), ap = ve({ +}), su = yt({ prop: "gridAutoColumns" -}), sp = ve({ +}), lu = yt({ prop: "gridAutoRows" -}), ip = ve({ +}), cu = yt({ prop: "gridTemplateColumns" -}), lp = ve({ +}), du = yt({ prop: "gridTemplateRows" -}), cp = ve({ +}), pu = yt({ prop: "gridTemplateAreas" -}), dp = ve({ +}), uu = yt({ prop: "gridArea" }); -ur(fr, mr, hr, np, rp, op, ap, sp, ip, lp, cp, dp); -function Dt(e, t) { - return t === "grey" ? t : e; +mr(gr, br, vr, ou, au, iu, su, lu, cu, du, pu, uu); +function Me(t, e) { + return e === "grey" ? e : t; } -const pp = ve({ +const wu = yt({ prop: "color", themeKey: "palette", - transform: Dt -}), up = ve({ + transform: Me +}), fu = yt({ prop: "bgcolor", cssProperty: "backgroundColor", themeKey: "palette", - transform: Dt -}), wp = ve({ + transform: Me +}), mu = yt({ prop: "backgroundColor", themeKey: "palette", - transform: Dt + transform: Me }); -ur(pp, up, wp); -function $e(e) { - return e <= 1 && e !== 0 ? `${e * 100}%` : e; +mr(wu, fu, mu); +function It(t) { + return t <= 1 && t !== 0 ? `${t * 100}%` : t; } -const fp = ve({ +const hu = yt({ prop: "width", - transform: $e -}), fo = (e) => { - if (e.maxWidth !== void 0 && e.maxWidth !== null) { - const t = (n) => { + transform: It +}), vo = (t) => { + if (t.maxWidth !== void 0 && t.maxWidth !== null) { + const e = (n) => { var r, o; - const a = ((r = e.theme) == null || (r = r.breakpoints) == null || (r = r.values) == null ? void 0 : r[n]) || wo[n]; - return a ? ((o = e.theme) == null || (o = o.breakpoints) == null ? void 0 : o.unit) !== "px" ? { - maxWidth: `${a}${e.theme.breakpoints.unit}` + const a = ((r = t.theme) == null || (r = r.breakpoints) == null || (r = r.values) == null ? void 0 : r[n]) || bo[n]; + return a ? ((o = t.theme) == null || (o = o.breakpoints) == null ? void 0 : o.unit) !== "px" ? { + maxWidth: `${a}${t.theme.breakpoints.unit}` } : { maxWidth: a } : { - maxWidth: $e(n) + maxWidth: It(n) }; }; - return Qe(e, e.maxWidth, t); + return Qt(t, t.maxWidth, e); } return null; }; -fo.filterProps = ["maxWidth"]; -const mp = ve({ +vo.filterProps = ["maxWidth"]; +const gu = yt({ prop: "minWidth", - transform: $e -}), hp = ve({ + transform: It +}), bu = yt({ prop: "height", - transform: $e -}), gp = ve({ + transform: It +}), vu = yt({ prop: "maxHeight", - transform: $e -}), bp = ve({ + transform: It +}), yu = yt({ prop: "minHeight", - transform: $e + transform: It }); -ve({ +yt({ prop: "size", cssProperty: "width", - transform: $e + transform: It }); -ve({ +yt({ prop: "size", cssProperty: "height", - transform: $e + transform: It }); -const vp = ve({ +const xu = yt({ prop: "boxSizing" }); -ur(fp, fo, mp, hp, gp, bp, vp); -const yp = { +mr(hu, vo, gu, bu, vu, yu, xu); +const Nu = { // borders border: { themeKey: "borders", - transform: De + transform: Dt }, borderTop: { themeKey: "borders", - transform: De + transform: Dt }, borderRight: { themeKey: "borders", - transform: De + transform: Dt }, borderBottom: { themeKey: "borders", - transform: De + transform: Dt }, borderLeft: { themeKey: "borders", - transform: De + transform: Dt }, borderColor: { themeKey: "palette" @@ -4573,156 +5293,156 @@ const yp = { }, outline: { themeKey: "borders", - transform: De + transform: Dt }, outlineColor: { themeKey: "palette" }, borderRadius: { themeKey: "shape.borderRadius", - style: wr + style: hr }, // palette color: { themeKey: "palette", - transform: Dt + transform: Me }, bgcolor: { themeKey: "palette", cssProperty: "backgroundColor", - transform: Dt + transform: Me }, backgroundColor: { themeKey: "palette", - transform: Dt + transform: Me }, // spacing p: { - style: he + style: ht }, pt: { - style: he + style: ht }, pr: { - style: he + style: ht }, pb: { - style: he + style: ht }, pl: { - style: he + style: ht }, px: { - style: he + style: ht }, py: { - style: he + style: ht }, padding: { - style: he + style: ht }, paddingTop: { - style: he + style: ht }, paddingRight: { - style: he + style: ht }, paddingBottom: { - style: he + style: ht }, paddingLeft: { - style: he + style: ht }, paddingX: { - style: he + style: ht }, paddingY: { - style: he + style: ht }, paddingInline: { - style: he + style: ht }, paddingInlineStart: { - style: he + style: ht }, paddingInlineEnd: { - style: he + style: ht }, paddingBlock: { - style: he + style: ht }, paddingBlockStart: { - style: he + style: ht }, paddingBlockEnd: { - style: he + style: ht }, m: { - style: me + style: mt }, mt: { - style: me + style: mt }, mr: { - style: me + style: mt }, mb: { - style: me + style: mt }, ml: { - style: me + style: mt }, mx: { - style: me + style: mt }, my: { - style: me + style: mt }, margin: { - style: me + style: mt }, marginTop: { - style: me + style: mt }, marginRight: { - style: me + style: mt }, marginBottom: { - style: me + style: mt }, marginLeft: { - style: me + style: mt }, marginX: { - style: me + style: mt }, marginY: { - style: me + style: mt }, marginInline: { - style: me + style: mt }, marginInlineStart: { - style: me + style: mt }, marginInlineEnd: { - style: me + style: mt }, marginBlock: { - style: me + style: mt }, marginBlockStart: { - style: me + style: mt }, marginBlockEnd: { - style: me + style: mt }, // display displayPrint: { cssProperty: !1, - transform: (e) => ({ + transform: (t) => ({ "@media print": { - display: e + display: t } }) }, @@ -4747,13 +5467,13 @@ const yp = { justifySelf: {}, // grid gap: { - style: fr + style: gr }, rowGap: { - style: hr + style: vr }, columnGap: { - style: mr + style: br }, gridColumn: {}, gridRow: {}, @@ -4779,22 +5499,22 @@ const yp = { }, // sizing width: { - transform: $e + transform: It }, maxWidth: { - style: fo + style: vo }, minWidth: { - transform: $e + transform: It }, height: { - transform: $e + transform: It }, maxHeight: { - transform: $e + transform: It }, minHeight: { - transform: $e + transform: It }, boxSizing: {}, // typography @@ -4818,17 +5538,17 @@ const yp = { cssProperty: !1, themeKey: "typography" } -}, mo = yp; -function xp(...e) { - const t = e.reduce((r, o) => r.concat(Object.keys(o)), []), n = new Set(t); - return e.every((r) => n.size === Object.keys(r).length); +}, yo = Nu; +function ku(...t) { + const e = t.reduce((r, o) => r.concat(Object.keys(o)), []), n = new Set(e); + return t.every((r) => n.size === Object.keys(r).length); } -function Np(e, t) { - return typeof e == "function" ? e(t) : e; +function Eu(t, e) { + return typeof t == "function" ? t(e) : t; } -function kp() { - function e(n, r, o, a) { - const s = { +function Su() { + function t(n, r, o, a) { + const i = { [n]: r, theme: o }, l = a[n]; @@ -4848,15 +5568,15 @@ function kp() { return { [n]: r }; - const w = cr(o, d) || {}; - return m ? m(s) : Qe(s, r, (v) => { - let f = Xn(w, p, v); - return v === f && typeof v == "string" && (f = Xn(w, p, `${n}${v === "default" ? "" : We(v)}`, v)), c === !1 ? f : { + const w = ur(o, d) || {}; + return m ? m(i) : Qt(i, r, (v) => { + let f = qn(w, p, v); + return v === f && typeof v == "string" && (f = qn(w, p, `${n}${v === "default" ? "" : Wt(v)}`, v)), c === !1 ? f : { [c]: f }; }); } - function t(n) { + function e(n) { var r; const { sx: o, @@ -4864,7 +5584,7 @@ function kp() { } = n || {}; if (!o) return null; - const s = (r = a.unstable_sxConfig) != null ? r : mo; + const i = (r = a.unstable_sxConfig) != null ? r : yo; function l(c) { let d = c; if (typeof c == "function") @@ -4873,146 +5593,146 @@ function kp() { return c; if (!d) return null; - const p = Ad(a.breakpoints), m = Object.keys(p); + const p = Dp(a.breakpoints), m = Object.keys(p); let w = p; - return Object.keys(d).forEach((b) => { - const v = Np(d[b], a); + return Object.keys(d).forEach((g) => { + const v = Eu(d[g], a); if (v != null) if (typeof v == "object") - if (s[b]) - w = cn(w, e(b, v, a, s)); + if (i[g]) + w = un(w, t(g, v, a, i)); else { - const f = Qe({ + const f = Qt({ theme: a }, v, (h) => ({ - [b]: h + [g]: h })); - xp(f, v) ? w[b] = t({ + ku(f, v) ? w[g] = e({ sx: v, theme: a - }) : w = cn(w, f); + }) : w = un(w, f); } else - w = cn(w, e(b, v, a, s)); - }), Dd(m, w); + w = un(w, t(g, v, a, i)); + }), Bp(m, w); } return Array.isArray(o) ? o.map(l) : l(o); } - return t; + return e; } -const Gs = kp(); -Gs.filterProps = ["sx"]; -const ho = Gs; -function Ep(e, t) { +const fs = Su(); +fs.filterProps = ["sx"]; +const xo = fs; +function Tu(t, e) { const n = this; return n.vars && typeof n.getColorSchemeSelector == "function" ? { - [n.getColorSchemeSelector(e).replace(/(\[[^\]]+\])/, "*:where($1)")]: t - } : n.palette.mode === e ? t : {}; + [n.getColorSchemeSelector(t).replace(/(\[[^\]]+\])/, "*:where($1)")]: e + } : n.palette.mode === t ? e : {}; } -const Tp = ["breakpoints", "palette", "spacing", "shape"]; -function go(e = {}, ...t) { +const Cu = ["breakpoints", "palette", "spacing", "shape"]; +function No(t = {}, ...e) { const { breakpoints: n = {}, palette: r = {}, spacing: o, shape: a = {} - } = e, s = Ne(e, Tp), l = Pd(n), c = Ud(o); - let d = Ze({ + } = t, i = kt(t, Cu), l = $p(n), c = Hp(o); + let d = Zt({ breakpoints: l, direction: "ltr", components: {}, // Inject component definitions. - palette: R({ + palette: P({ mode: "light" }, r), spacing: c, - shape: R({}, $d, a) - }, s); - return d.applyStyles = Ep, d = t.reduce((p, m) => Ze(p, m), d), d.unstable_sxConfig = R({}, mo, s == null ? void 0 : s.unstable_sxConfig), d.unstable_sx = function(m) { - return ho({ + shape: P({}, Ap, a) + }, i); + return d.applyStyles = Tu, d = e.reduce((p, m) => Zt(p, m), d), d.unstable_sxConfig = P({}, yo, i == null ? void 0 : i.unstable_sxConfig), d.unstable_sx = function(m) { + return xo({ sx: m, theme: this }); }, d; } -function Cp(e) { - return Object.keys(e).length === 0; +function Ou(t) { + return Object.keys(t).length === 0; } -function Hs(e = null) { - const t = M.useContext(ml); - return !t || Cp(t) ? e : t; +function ms(t = null) { + const e = M.useContext(Xl); + return !e || Ou(e) ? t : e; } -const Sp = go(); -function Xs(e = Sp) { - return Hs(e); +const Ru = No(); +function hs(t = Ru) { + return ms(t); } -const Op = ["ownerState"], Rp = ["variants"], Pp = ["name", "slot", "skipVariantsResolver", "skipSx", "overridesResolver"]; -function _p(e) { - return Object.keys(e).length === 0; +const _u = ["ownerState"], Pu = ["variants"], $u = ["name", "slot", "skipVariantsResolver", "skipSx", "overridesResolver"]; +function Iu(t) { + return Object.keys(t).length === 0; } -function $p(e) { - return typeof e == "string" && // 96 is one less than the char code +function Au(t) { + return typeof t == "string" && // 96 is one less than the char code // for "a" so this is checking that // it's a lowercase character - e.charCodeAt(0) > 96; + t.charCodeAt(0) > 96; } -function zn(e) { - return e !== "ownerState" && e !== "theme" && e !== "sx" && e !== "as"; +function Gn(t) { + return t !== "ownerState" && t !== "theme" && t !== "sx" && t !== "as"; } -const Ip = go(), ga = (e) => e && e.charAt(0).toLowerCase() + e.slice(1); -function Mn({ - defaultTheme: e, - theme: t, +const Mu = No(), ka = (t) => t && t.charAt(0).toLowerCase() + t.slice(1); +function Vn({ + defaultTheme: t, + theme: e, themeId: n }) { - return _p(t) ? e : t[n] || t; + return Iu(e) ? t : e[n] || e; } -function Ap(e) { - return e ? (t, n) => n[e] : null; +function Du(t) { + return t ? (e, n) => n[t] : null; } -function Fn(e, t) { +function Hn(t, e) { let { ownerState: n - } = t, r = Ne(t, Op); - const o = typeof e == "function" ? e(R({ + } = e, r = kt(e, _u); + const o = typeof t == "function" ? t(P({ ownerState: n - }, r)) : e; + }, r)) : t; if (Array.isArray(o)) - return o.flatMap((a) => Fn(a, R({ + return o.flatMap((a) => Hn(a, P({ ownerState: n }, r))); if (o && typeof o == "object" && Array.isArray(o.variants)) { const { variants: a = [] } = o; - let l = Ne(o, Rp); + let l = kt(o, Pu); return a.forEach((c) => { let d = !0; - typeof c.props == "function" ? d = c.props(R({ + typeof c.props == "function" ? d = c.props(P({ ownerState: n }, r, n)) : Object.keys(c.props).forEach((p) => { (n == null ? void 0 : n[p]) !== c.props[p] && r[p] !== c.props[p] && (d = !1); - }), d && (Array.isArray(l) || (l = [l]), l.push(typeof c.style == "function" ? c.style(R({ + }), d && (Array.isArray(l) || (l = [l]), l.push(typeof c.style == "function" ? c.style(P({ ownerState: n }, r, n)) : c.style)); }), l; } return o; } -function Dp(e = {}) { +function Bu(t = {}) { const { - themeId: t, - defaultTheme: n = Ip, - rootShouldForwardProp: r = zn, - slotShouldForwardProp: o = zn - } = e, a = (s) => ho(R({}, s, { - theme: Mn(R({}, s, { + themeId: e, + defaultTheme: n = Mu, + rootShouldForwardProp: r = Gn, + slotShouldForwardProp: o = Gn + } = t, a = (i) => xo(P({}, i, { + theme: Vn(P({}, i, { defaultTheme: n, - themeId: t + themeId: e })) })); - return a.__mui_systemSx = !0, (s, l = {}) => { - hl(s, (g) => g.filter((_) => !(_ != null && _.__mui_systemSx))); + return a.__mui_systemSx = !0, (i, l = {}) => { + Yl(i, (b) => b.filter((I) => !(I != null && I.__mui_systemSx))); const { name: c, slot: d, @@ -5020,112 +5740,112 @@ function Dp(e = {}) { skipSx: m, // TODO v6: remove `lowercaseFirstLetter()` in the next major release // For more details: https://github.com/mui/material-ui/pull/37908 - overridesResolver: w = Ap(ga(d)) - } = l, b = Ne(l, Pp), v = p !== void 0 ? p : ( + overridesResolver: w = Du(ka(d)) + } = l, g = kt(l, $u), v = p !== void 0 ? p : ( // TODO v6: remove `Root` in the next major release // For more details: https://github.com/mui/material-ui/pull/37908 d && d !== "Root" && d !== "root" || !1 ), f = m || !1; let h; - process.env.NODE_ENV !== "production" && c && (h = `${c}-${ga(d || "Root")}`); - let E = zn; - d === "Root" || d === "root" ? E = r : d ? E = o : $p(s) && (E = void 0); - const A = fl(s, R({ + process.env.NODE_ENV !== "production" && c && (h = `${c}-${ka(d || "Root")}`); + let E = Gn; + d === "Root" || d === "root" ? E = r : d ? E = o : Au(i) && (E = void 0); + const _ = Hl(i, P({ shouldForwardProp: E, label: h - }, b)), O = (g) => typeof g == "function" && g.__emotion_real !== g || ht(g) ? (_) => Fn(g, R({}, _, { - theme: Mn({ - theme: _.theme, + }, g)), C = (b) => typeof b == "function" && b.__emotion_real !== b || he(b) ? (I) => Hn(b, P({}, I, { + theme: Vn({ + theme: I.theme, defaultTheme: n, - themeId: t + themeId: e }) - })) : g, k = (g, ..._) => { - let L = O(g); - const H = _ ? _.map(O) : []; - c && w && H.push((N) => { - const B = Mn(R({}, N, { + })) : b, S = (b, ...I) => { + let z = C(b); + const H = I ? I.map(C) : []; + c && w && H.push((k) => { + const B = Vn(P({}, k, { defaultTheme: n, - themeId: t + themeId: e })); if (!B.components || !B.components[c] || !B.components[c].styleOverrides) return null; const D = B.components[c].styleOverrides, J = {}; return Object.entries(D).forEach(([q, U]) => { - J[q] = Fn(U, R({}, N, { + J[q] = Hn(U, P({}, k, { theme: B })); - }), w(N, J); - }), c && !v && H.push((N) => { + }), w(k, J); + }), c && !v && H.push((k) => { var B; - const D = Mn(R({}, N, { + const D = Vn(P({}, k, { defaultTheme: n, - themeId: t + themeId: e })), J = D == null || (B = D.components) == null || (B = B[c]) == null ? void 0 : B.variants; - return Fn({ + return Hn({ variants: J - }, R({}, N, { + }, P({}, k, { theme: D })); }), f || H.push(a); - const C = H.length - _.length; - if (Array.isArray(g) && C > 0) { - const N = new Array(C).fill(""); - L = [...g, ...N], L.raw = [...g.raw, ...N]; + const O = H.length - I.length; + if (Array.isArray(b) && O > 0) { + const k = new Array(O).fill(""); + z = [...b, ...k], z.raw = [...b.raw, ...k]; } - const P = A(L, ...H); + const $ = _(z, ...H); if (process.env.NODE_ENV !== "production") { - let N; - c && (N = `${c}${We(d || "")}`), N === void 0 && (N = `Styled(${od(s)})`), P.displayName = N; + let k; + c && (k = `${c}${Wt(d || "")}`), k === void 0 && (k = `Styled(${ip(i)})`), $.displayName = k; } - return s.muiName && (P.muiName = s.muiName), P; + return i.muiName && ($.muiName = i.muiName), $; }; - return A.withConfig && (k.withConfig = A.withConfig), k; + return _.withConfig && (S.withConfig = _.withConfig), S; }; } -function Mp(e) { +function ju(t) { const { - theme: t, + theme: e, name: n, props: r - } = e; - return !t || !t.components || !t.components[n] || !t.components[n].defaultProps ? r : js(t.components[n].defaultProps, r); + } = t; + return !e || !e.components || !e.components[n] || !e.components[n].defaultProps ? r : ls(e.components[n].defaultProps, r); } -function Bp({ - props: e, - name: t, +function Vu({ + props: t, + name: e, defaultTheme: n, themeId: r }) { - let o = Xs(n); - return r && (o = o[r] || o), Mp({ + let o = hs(n); + return r && (o = o[r] || o), ju({ theme: o, - name: t, - props: e + name: e, + props: t }); } -function bo(e, t = 0, n = 1) { - return process.env.NODE_ENV !== "production" && (e < t || e > n) && console.error(`MUI: The value provided ${e} is out of range [${t}, ${n}].`), Sd(e, t, n); +function ko(t, e = 0, n = 1) { + return process.env.NODE_ENV !== "production" && (t < e || t > n) && console.error(`MUI: The value provided ${t} is out of range [${e}, ${n}].`), Rp(t, e, n); } -function jp(e) { - e = e.slice(1); - const t = new RegExp(`.{1,${e.length >= 6 ? 2 : 1}}`, "g"); - let n = e.match(t); +function zu(t) { + t = t.slice(1); + const e = new RegExp(`.{1,${t.length >= 6 ? 2 : 1}}`, "g"); + let n = t.match(e); return n && n[0].length === 1 && (n = n.map((r) => r + r)), n ? `rgb${n.length === 4 ? "a" : ""}(${n.map((r, o) => o < 3 ? parseInt(r, 16) : Math.round(parseInt(r, 16) / 255 * 1e3) / 1e3).join(", ")})` : ""; } -function Nt(e) { - if (e.type) - return e; - if (e.charAt(0) === "#") - return Nt(jp(e)); - const t = e.indexOf("("), n = e.substring(0, t); +function Ne(t) { + if (t.type) + return t; + if (t.charAt(0) === "#") + return Ne(zu(t)); + const e = t.indexOf("("), n = t.substring(0, e); if (["rgb", "rgba", "hsl", "hsla", "color"].indexOf(n) === -1) - throw new Error(process.env.NODE_ENV !== "production" ? `MUI: Unsupported \`${e}\` color. -The following formats are supported: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color().` : Vt(9, e)); - let r = e.substring(t + 1, e.length - 1), o; + throw new Error(process.env.NODE_ENV !== "production" ? `MUI: Unsupported \`${t}\` color. +The following formats are supported: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color().` : Ve(9, t)); + let r = t.substring(e + 1, t.length - 1), o; if (n === "color") { if (r = r.split(" "), o = r.shift(), r.length === 4 && r[3].charAt(0) === "/" && (r[3] = r[3].slice(1)), ["srgb", "display-p3", "a98-rgb", "prophoto-rgb", "rec-2020"].indexOf(o) === -1) throw new Error(process.env.NODE_ENV !== "production" ? `MUI: unsupported \`${o}\` color space. -The following color spaces are supported: srgb, display-p3, a98-rgb, prophoto-rgb, rec-2020.` : Vt(10, o)); +The following color spaces are supported: srgb, display-p3, a98-rgb, prophoto-rgb, rec-2020.` : Ve(10, o)); } else r = r.split(","); return r = r.map((a) => parseFloat(a)), { @@ -5134,78 +5854,78 @@ The following color spaces are supported: srgb, display-p3, a98-rgb, prophoto-rg colorSpace: o }; } -function gr(e) { +function yr(t) { const { - type: t, + type: e, colorSpace: n - } = e; + } = t; let { values: r - } = e; - return t.indexOf("rgb") !== -1 ? r = r.map((o, a) => a < 3 ? parseInt(o, 10) : o) : t.indexOf("hsl") !== -1 && (r[1] = `${r[1]}%`, r[2] = `${r[2]}%`), t.indexOf("color") !== -1 ? r = `${n} ${r.join(" ")}` : r = `${r.join(", ")}`, `${t}(${r})`; + } = t; + return e.indexOf("rgb") !== -1 ? r = r.map((o, a) => a < 3 ? parseInt(o, 10) : o) : e.indexOf("hsl") !== -1 && (r[1] = `${r[1]}%`, r[2] = `${r[2]}%`), e.indexOf("color") !== -1 ? r = `${n} ${r.join(" ")}` : r = `${r.join(", ")}`, `${e}(${r})`; } -function Vp(e) { - e = Nt(e); +function Lu(t) { + t = Ne(t); const { - values: t - } = e, n = t[0], r = t[1] / 100, o = t[2] / 100, a = r * Math.min(o, 1 - o), s = (d, p = (d + n / 30) % 12) => o - a * Math.max(Math.min(p - 3, 9 - p, 1), -1); + values: e + } = t, n = e[0], r = e[1] / 100, o = e[2] / 100, a = r * Math.min(o, 1 - o), i = (d, p = (d + n / 30) % 12) => o - a * Math.max(Math.min(p - 3, 9 - p, 1), -1); let l = "rgb"; - const c = [Math.round(s(0) * 255), Math.round(s(8) * 255), Math.round(s(4) * 255)]; - return e.type === "hsla" && (l += "a", c.push(t[3])), gr({ + const c = [Math.round(i(0) * 255), Math.round(i(8) * 255), Math.round(i(4) * 255)]; + return t.type === "hsla" && (l += "a", c.push(e[3])), yr({ type: l, values: c }); } -function ba(e) { - e = Nt(e); - let t = e.type === "hsl" || e.type === "hsla" ? Nt(Vp(e)).values : e.values; - return t = t.map((n) => (e.type !== "color" && (n /= 255), n <= 0.03928 ? n / 12.92 : ((n + 0.055) / 1.055) ** 2.4)), Number((0.2126 * t[0] + 0.7152 * t[1] + 0.0722 * t[2]).toFixed(3)); +function Ea(t) { + t = Ne(t); + let e = t.type === "hsl" || t.type === "hsla" ? Ne(Lu(t)).values : t.values; + return e = e.map((n) => (t.type !== "color" && (n /= 255), n <= 0.03928 ? n / 12.92 : ((n + 0.055) / 1.055) ** 2.4)), Number((0.2126 * e[0] + 0.7152 * e[1] + 0.0722 * e[2]).toFixed(3)); } -function va(e, t) { - const n = ba(e), r = ba(t); +function Sa(t, e) { + const n = Ea(t), r = Ea(e); return (Math.max(n, r) + 0.05) / (Math.min(n, r) + 0.05); } -function Ys(e, t) { - return e = Nt(e), t = bo(t), (e.type === "rgb" || e.type === "hsl") && (e.type += "a"), e.type === "color" ? e.values[3] = `/${t}` : e.values[3] = t, gr(e); +function gs(t, e) { + return t = Ne(t), e = ko(e), (t.type === "rgb" || t.type === "hsl") && (t.type += "a"), t.type === "color" ? t.values[3] = `/${e}` : t.values[3] = e, yr(t); } -function Lp(e, t) { - if (e = Nt(e), t = bo(t), e.type.indexOf("hsl") !== -1) - e.values[2] *= 1 - t; - else if (e.type.indexOf("rgb") !== -1 || e.type.indexOf("color") !== -1) +function Fu(t, e) { + if (t = Ne(t), e = ko(e), t.type.indexOf("hsl") !== -1) + t.values[2] *= 1 - e; + else if (t.type.indexOf("rgb") !== -1 || t.type.indexOf("color") !== -1) for (let n = 0; n < 3; n += 1) - e.values[n] *= 1 - t; - return gr(e); + t.values[n] *= 1 - e; + return yr(t); } -function zp(e, t) { - if (e = Nt(e), t = bo(t), e.type.indexOf("hsl") !== -1) - e.values[2] += (100 - e.values[2]) * t; - else if (e.type.indexOf("rgb") !== -1) +function Uu(t, e) { + if (t = Ne(t), e = ko(e), t.type.indexOf("hsl") !== -1) + t.values[2] += (100 - t.values[2]) * e; + else if (t.type.indexOf("rgb") !== -1) for (let n = 0; n < 3; n += 1) - e.values[n] += (255 - e.values[n]) * t; - else if (e.type.indexOf("color") !== -1) + t.values[n] += (255 - t.values[n]) * e; + else if (t.type.indexOf("color") !== -1) for (let n = 0; n < 3; n += 1) - e.values[n] += (1 - e.values[n]) * t; - return gr(e); + t.values[n] += (1 - t.values[n]) * e; + return yr(t); } -function Fp(e, t) { - return R({ +function Gu(t, e) { + return P({ toolbar: { minHeight: 56, - [e.up("xs")]: { + [t.up("xs")]: { "@media (orientation: landscape)": { minHeight: 48 } }, - [e.up("sm")]: { + [t.up("sm")]: { minHeight: 64 } } - }, t); + }, e); } -const Up = { +const Hu = { black: "#000", white: "#fff" -}, bn = Up, Gp = { +}, xn = Hu, Xu = { 50: "#fafafa", 100: "#f5f5f5", 200: "#eeeeee", @@ -5220,7 +5940,7 @@ const Up = { A200: "#eeeeee", A400: "#bdbdbd", A700: "#616161" -}, Hp = Gp, Xp = { +}, Yu = Xu, Wu = { 50: "#f3e5f5", 100: "#e1bee7", 200: "#ce93d8", @@ -5235,7 +5955,7 @@ const Up = { A200: "#e040fb", A400: "#d500f9", A700: "#aa00ff" -}, Ot = Xp, Yp = { +}, Oe = Wu, qu = { 50: "#ffebee", 100: "#ffcdd2", 200: "#ef9a9a", @@ -5250,7 +5970,7 @@ const Up = { A200: "#ff5252", A400: "#ff1744", A700: "#d50000" -}, Rt = Yp, Wp = { +}, Re = qu, Ku = { 50: "#fff3e0", 100: "#ffe0b2", 200: "#ffcc80", @@ -5265,7 +5985,7 @@ const Up = { A200: "#ffab40", A400: "#ff9100", A700: "#ff6d00" -}, Qt = Wp, qp = { +}, nn = Ku, Ju = { 50: "#e3f2fd", 100: "#bbdefb", 200: "#90caf9", @@ -5280,7 +6000,7 @@ const Up = { A200: "#448aff", A400: "#2979ff", A700: "#2962ff" -}, Pt = qp, Kp = { +}, _e = Ju, Zu = { 50: "#e1f5fe", 100: "#b3e5fc", 200: "#81d4fa", @@ -5295,7 +6015,7 @@ const Up = { A200: "#40c4ff", A400: "#00b0ff", A700: "#0091ea" -}, _t = Kp, Jp = { +}, Pe = Zu, Qu = { 50: "#e8f5e9", 100: "#c8e6c9", 200: "#a5d6a7", @@ -5310,7 +6030,7 @@ const Up = { A200: "#69f0ae", A400: "#00e676", A700: "#00c853" -}, $t = Jp, Zp = ["mode", "contrastThreshold", "tonalOffset"], ya = { +}, $e = Qu, tw = ["mode", "contrastThreshold", "tonalOffset"], Ta = { // The colors used to style the text. text: { // The most important text. @@ -5325,8 +6045,8 @@ const Up = { // The background colors used to style the surfaces. // Consistency between these values is important. background: { - paper: bn.white, - default: bn.white + paper: xn.white, + default: xn.white }, // The colors used to style the action elements. action: { @@ -5347,9 +6067,9 @@ const Up = { focusOpacity: 0.12, activatedOpacity: 0.12 } -}, jr = { +}, Fr = { text: { - primary: bn.white, + primary: xn.white, secondary: "rgba(255, 255, 255, 0.7)", disabled: "rgba(255, 255, 255, 0.5)", icon: "rgba(255, 255, 255, 0.5)" @@ -5360,7 +6080,7 @@ const Up = { default: "#121212" }, action: { - active: bn.white, + active: xn.white, hover: "rgba(255, 255, 255, 0.08)", hoverOpacity: 0.08, selected: "rgba(255, 255, 255, 0.16)", @@ -5373,87 +6093,87 @@ const Up = { activatedOpacity: 0.24 } }; -function xa(e, t, n, r) { +function Ca(t, e, n, r) { const o = r.light || r, a = r.dark || r * 1.5; - e[t] || (e.hasOwnProperty(n) ? e[t] = e[n] : t === "light" ? e.light = zp(e.main, o) : t === "dark" && (e.dark = Lp(e.main, a))); + t[e] || (t.hasOwnProperty(n) ? t[e] = t[n] : e === "light" ? t.light = Uu(t.main, o) : e === "dark" && (t.dark = Fu(t.main, a))); } -function Qp(e = "light") { - return e === "dark" ? { - main: Pt[200], - light: Pt[50], - dark: Pt[400] +function ew(t = "light") { + return t === "dark" ? { + main: _e[200], + light: _e[50], + dark: _e[400] } : { - main: Pt[700], - light: Pt[400], - dark: Pt[800] + main: _e[700], + light: _e[400], + dark: _e[800] }; } -function eu(e = "light") { - return e === "dark" ? { - main: Ot[200], - light: Ot[50], - dark: Ot[400] +function nw(t = "light") { + return t === "dark" ? { + main: Oe[200], + light: Oe[50], + dark: Oe[400] } : { - main: Ot[500], - light: Ot[300], - dark: Ot[700] + main: Oe[500], + light: Oe[300], + dark: Oe[700] }; } -function tu(e = "light") { - return e === "dark" ? { - main: Rt[500], - light: Rt[300], - dark: Rt[700] +function rw(t = "light") { + return t === "dark" ? { + main: Re[500], + light: Re[300], + dark: Re[700] } : { - main: Rt[700], - light: Rt[400], - dark: Rt[800] + main: Re[700], + light: Re[400], + dark: Re[800] }; } -function nu(e = "light") { - return e === "dark" ? { - main: _t[400], - light: _t[300], - dark: _t[700] +function ow(t = "light") { + return t === "dark" ? { + main: Pe[400], + light: Pe[300], + dark: Pe[700] } : { - main: _t[700], - light: _t[500], - dark: _t[900] + main: Pe[700], + light: Pe[500], + dark: Pe[900] }; } -function ru(e = "light") { - return e === "dark" ? { - main: $t[400], - light: $t[300], - dark: $t[700] +function aw(t = "light") { + return t === "dark" ? { + main: $e[400], + light: $e[300], + dark: $e[700] } : { - main: $t[800], - light: $t[500], - dark: $t[900] + main: $e[800], + light: $e[500], + dark: $e[900] }; } -function ou(e = "light") { - return e === "dark" ? { - main: Qt[400], - light: Qt[300], - dark: Qt[700] +function iw(t = "light") { + return t === "dark" ? { + main: nn[400], + light: nn[300], + dark: nn[700] } : { main: "#ed6c02", // closest to orange[800] that pass 3:1. - light: Qt[500], - dark: Qt[900] + light: nn[500], + dark: nn[900] }; } -function au(e) { +function sw(t) { const { - mode: t = "light", + mode: e = "light", contrastThreshold: n = 3, tonalOffset: r = 0.2 - } = e, o = Ne(e, Zp), a = e.primary || Qp(t), s = e.secondary || eu(t), l = e.error || tu(t), c = e.info || nu(t), d = e.success || ru(t), p = e.warning || ou(t); + } = t, o = kt(t, tw), a = t.primary || ew(e), i = t.secondary || nw(e), l = t.error || rw(e), c = t.info || ow(e), d = t.success || aw(e), p = t.warning || iw(e); function m(f) { - const h = va(f, jr.text.primary) >= n ? jr.text.primary : ya.text.primary; + const h = Sa(f, Fr.text.primary) >= n ? Fr.text.primary : Ta.text.primary; if (process.env.NODE_ENV !== "production") { - const E = va(f, h); + const E = Sa(f, h); E < 3 && console.error([`MUI: The contrast ratio of ${E}:1 for ${h} on ${f}`, "falls below the WCAG recommended absolute minimum contrast ratio of 3:1.", "https://www.w3.org/TR/2008/REC-WCAG20-20081211/#visual-audio-contrast-contrast"].join(` `)); } @@ -5463,12 +6183,12 @@ function au(e) { color: f, name: h, mainShade: E = 500, - lightShade: A = 300, - darkShade: O = 700 + lightShade: _ = 300, + darkShade: C = 700 }) => { - if (f = R({}, f), !f.main && f[E] && (f.main = f[E]), !f.hasOwnProperty("main")) + if (f = P({}, f), !f.main && f[E] && (f.main = f[E]), !f.hasOwnProperty("main")) throw new Error(process.env.NODE_ENV !== "production" ? `MUI: The color${h ? ` (${h})` : ""} provided to augmentColor(color) is invalid. -The color object needs to have a \`main\` property or a \`${E}\` property.` : Vt(11, h ? ` (${h})` : "", E)); +The color object needs to have a \`main\` property or a \`${E}\` property.` : Ve(11, h ? ` (${h})` : "", E)); if (typeof f.main != "string") throw new Error(process.env.NODE_ENV !== "production" ? `MUI: The color${h ? ` (${h})` : ""} provided to augmentColor(color) is invalid. \`color.main\` should be a string, but \`${JSON.stringify(f.main)}\` was provided instead. @@ -5483,18 +6203,18 @@ const theme1 = createTheme({ palette: { const theme2 = createTheme({ palette: { primary: { main: green[500] }, -} });` : Vt(12, h ? ` (${h})` : "", JSON.stringify(f.main))); - return xa(f, "light", A, r), xa(f, "dark", O, r), f.contrastText || (f.contrastText = m(f.main)), f; - }, b = { - dark: jr, - light: ya +} });` : Ve(12, h ? ` (${h})` : "", JSON.stringify(f.main))); + return Ca(f, "light", _, r), Ca(f, "dark", C, r), f.contrastText || (f.contrastText = m(f.main)), f; + }, g = { + dark: Fr, + light: Ta }; - return process.env.NODE_ENV !== "production" && (b[t] || console.error(`MUI: The palette mode \`${t}\` is not supported.`)), Ze(R({ + return process.env.NODE_ENV !== "production" && (g[e] || console.error(`MUI: The palette mode \`${e}\` is not supported.`)), Zt(P({ // A collection of common colors. - common: R({}, bn), + common: P({}, xn), // prevent mutable object. // The palette mode, can be light or dark. - mode: t, + mode: e, // The colors used to represent primary interface elements for a user. primary: w({ color: a, @@ -5502,7 +6222,7 @@ const theme2 = createTheme({ palette: { }), // The colors used to represent secondary interface elements for a user. secondary: w({ - color: s, + color: i, name: "secondary", mainShade: "A400", lightShade: "A200", @@ -5529,7 +6249,7 @@ const theme2 = createTheme({ palette: { name: "success" }), // The grey colors. - grey: Hp, + grey: Yu, // Used by `getContrastText()` to maximize the contrast between // the background and the text. contrastThreshold: n, @@ -5541,23 +6261,23 @@ const theme2 = createTheme({ palette: { // two indexes within its tonal palette. // E.g., shift from Red 500 to Red 300 or Red 700. tonalOffset: r - }, b[t]), o); + }, g[e]), o); } -const su = ["fontFamily", "fontSize", "fontWeightLight", "fontWeightRegular", "fontWeightMedium", "fontWeightBold", "htmlFontSize", "allVariants", "pxToRem"]; -function iu(e) { - return Math.round(e * 1e5) / 1e5; +const lw = ["fontFamily", "fontSize", "fontWeightLight", "fontWeightRegular", "fontWeightMedium", "fontWeightBold", "htmlFontSize", "allVariants", "pxToRem"]; +function cw(t) { + return Math.round(t * 1e5) / 1e5; } -const Na = { +const Oa = { textTransform: "uppercase" -}, ka = '"Roboto", "Helvetica", "Arial", sans-serif'; -function lu(e, t) { - const n = typeof t == "function" ? t(e) : t, { - fontFamily: r = ka, +}, Ra = '"Roboto", "Helvetica", "Arial", sans-serif'; +function dw(t, e) { + const n = typeof e == "function" ? e(t) : e, { + fontFamily: r = Ra, // The default font size of the Material Specification. fontSize: o = 14, // px fontWeightLight: a = 300, - fontWeightRegular: s = 400, + fontWeightRegular: i = 400, fontWeightMedium: l = 500, fontWeightBold: c = 700, // Tell MUI what's the font-size on the html element. @@ -5566,30 +6286,30 @@ function lu(e, t) { // Apply the CSS properties to all the variants. allVariants: p, pxToRem: m - } = n, w = Ne(n, su); + } = n, w = kt(n, lw); process.env.NODE_ENV !== "production" && (typeof o != "number" && console.error("MUI: `fontSize` is required to be a number."), typeof d != "number" && console.error("MUI: `htmlFontSize` is required to be a number.")); - const b = o / 14, v = m || ((E) => `${E / d * b}rem`), f = (E, A, O, k, g) => R({ + const g = o / 14, v = m || ((E) => `${E / d * g}rem`), f = (E, _, C, S, b) => P({ fontFamily: r, fontWeight: E, - fontSize: v(A), + fontSize: v(_), // Unitless following https://meyerweb.com/eric/thoughts/2006/02/08/unitless-line-heights/ - lineHeight: O - }, r === ka ? { - letterSpacing: `${iu(k / A)}em` - } : {}, g, p), h = { + lineHeight: C + }, r === Ra ? { + letterSpacing: `${cw(S / _)}em` + } : {}, b, p), h = { h1: f(a, 96, 1.167, -1.5), h2: f(a, 60, 1.2, -0.5), - h3: f(s, 48, 1.167, 0), - h4: f(s, 34, 1.235, 0.25), - h5: f(s, 24, 1.334, 0), + h3: f(i, 48, 1.167, 0), + h4: f(i, 34, 1.235, 0.25), + h5: f(i, 24, 1.334, 0), h6: f(l, 20, 1.6, 0.15), - subtitle1: f(s, 16, 1.75, 0.15), + subtitle1: f(i, 16, 1.75, 0.15), subtitle2: f(l, 14, 1.57, 0.1), - body1: f(s, 16, 1.5, 0.15), - body2: f(s, 14, 1.43, 0.15), - button: f(l, 14, 1.75, 0.4, Na), - caption: f(s, 12, 1.66, 0.4), - overline: f(s, 12, 2.66, 1, Na), + body1: f(i, 16, 1.5, 0.15), + body2: f(i, 14, 1.43, 0.15), + button: f(l, 14, 1.75, 0.4, Oa), + caption: f(i, 12, 1.66, 0.4), + overline: f(i, 12, 2.66, 1, Oa), // TODO v6: Remove handling of 'inherit' variant from the theme as it is already handled in Material UI's Typography component. Also, remember to remove the associated types. inherit: { fontFamily: "inherit", @@ -5599,13 +6319,13 @@ function lu(e, t) { letterSpacing: "inherit" } }; - return Ze(R({ + return Zt(P({ htmlFontSize: d, pxToRem: v, fontFamily: r, fontSize: o, fontWeightLight: a, - fontWeightRegular: s, + fontWeightRegular: i, fontWeightMedium: l, fontWeightBold: c }, h), w, { @@ -5613,11 +6333,11 @@ function lu(e, t) { // No need to clone deep }); } -const cu = 0.2, du = 0.14, pu = 0.12; -function fe(...e) { - return [`${e[0]}px ${e[1]}px ${e[2]}px ${e[3]}px rgba(0,0,0,${cu})`, `${e[4]}px ${e[5]}px ${e[6]}px ${e[7]}px rgba(0,0,0,${du})`, `${e[8]}px ${e[9]}px ${e[10]}px ${e[11]}px rgba(0,0,0,${pu})`].join(","); +const pw = 0.2, uw = 0.14, ww = 0.12; +function ft(...t) { + return [`${t[0]}px ${t[1]}px ${t[2]}px ${t[3]}px rgba(0,0,0,${pw})`, `${t[4]}px ${t[5]}px ${t[6]}px ${t[7]}px rgba(0,0,0,${uw})`, `${t[8]}px ${t[9]}px ${t[10]}px ${t[11]}px rgba(0,0,0,${ww})`].join(","); } -const uu = ["none", fe(0, 2, 1, -1, 0, 1, 1, 0, 0, 1, 3, 0), fe(0, 3, 1, -2, 0, 2, 2, 0, 0, 1, 5, 0), fe(0, 3, 3, -2, 0, 3, 4, 0, 0, 1, 8, 0), fe(0, 2, 4, -1, 0, 4, 5, 0, 0, 1, 10, 0), fe(0, 3, 5, -1, 0, 5, 8, 0, 0, 1, 14, 0), fe(0, 3, 5, -1, 0, 6, 10, 0, 0, 1, 18, 0), fe(0, 4, 5, -2, 0, 7, 10, 1, 0, 2, 16, 1), fe(0, 5, 5, -3, 0, 8, 10, 1, 0, 3, 14, 2), fe(0, 5, 6, -3, 0, 9, 12, 1, 0, 3, 16, 2), fe(0, 6, 6, -3, 0, 10, 14, 1, 0, 4, 18, 3), fe(0, 6, 7, -4, 0, 11, 15, 1, 0, 4, 20, 3), fe(0, 7, 8, -4, 0, 12, 17, 2, 0, 5, 22, 4), fe(0, 7, 8, -4, 0, 13, 19, 2, 0, 5, 24, 4), fe(0, 7, 9, -4, 0, 14, 21, 2, 0, 5, 26, 4), fe(0, 8, 9, -5, 0, 15, 22, 2, 0, 6, 28, 5), fe(0, 8, 10, -5, 0, 16, 24, 2, 0, 6, 30, 5), fe(0, 8, 11, -5, 0, 17, 26, 2, 0, 6, 32, 5), fe(0, 9, 11, -5, 0, 18, 28, 2, 0, 7, 34, 6), fe(0, 9, 12, -6, 0, 19, 29, 2, 0, 7, 36, 6), fe(0, 10, 13, -6, 0, 20, 31, 3, 0, 8, 38, 7), fe(0, 10, 13, -6, 0, 21, 33, 3, 0, 8, 40, 7), fe(0, 10, 14, -6, 0, 22, 35, 3, 0, 8, 42, 7), fe(0, 11, 14, -7, 0, 23, 36, 3, 0, 9, 44, 8), fe(0, 11, 15, -7, 0, 24, 38, 3, 0, 9, 46, 8)], wu = uu, fu = ["duration", "easing", "delay"], mu = { +const fw = ["none", ft(0, 2, 1, -1, 0, 1, 1, 0, 0, 1, 3, 0), ft(0, 3, 1, -2, 0, 2, 2, 0, 0, 1, 5, 0), ft(0, 3, 3, -2, 0, 3, 4, 0, 0, 1, 8, 0), ft(0, 2, 4, -1, 0, 4, 5, 0, 0, 1, 10, 0), ft(0, 3, 5, -1, 0, 5, 8, 0, 0, 1, 14, 0), ft(0, 3, 5, -1, 0, 6, 10, 0, 0, 1, 18, 0), ft(0, 4, 5, -2, 0, 7, 10, 1, 0, 2, 16, 1), ft(0, 5, 5, -3, 0, 8, 10, 1, 0, 3, 14, 2), ft(0, 5, 6, -3, 0, 9, 12, 1, 0, 3, 16, 2), ft(0, 6, 6, -3, 0, 10, 14, 1, 0, 4, 18, 3), ft(0, 6, 7, -4, 0, 11, 15, 1, 0, 4, 20, 3), ft(0, 7, 8, -4, 0, 12, 17, 2, 0, 5, 22, 4), ft(0, 7, 8, -4, 0, 13, 19, 2, 0, 5, 24, 4), ft(0, 7, 9, -4, 0, 14, 21, 2, 0, 5, 26, 4), ft(0, 8, 9, -5, 0, 15, 22, 2, 0, 6, 28, 5), ft(0, 8, 10, -5, 0, 16, 24, 2, 0, 6, 30, 5), ft(0, 8, 11, -5, 0, 17, 26, 2, 0, 6, 32, 5), ft(0, 9, 11, -5, 0, 18, 28, 2, 0, 7, 34, 6), ft(0, 9, 12, -6, 0, 19, 29, 2, 0, 7, 36, 6), ft(0, 10, 13, -6, 0, 20, 31, 3, 0, 8, 38, 7), ft(0, 10, 13, -6, 0, 21, 33, 3, 0, 8, 40, 7), ft(0, 10, 14, -6, 0, 22, 35, 3, 0, 8, 42, 7), ft(0, 11, 14, -7, 0, 23, 36, 3, 0, 9, 44, 8), ft(0, 11, 15, -7, 0, 24, 38, 3, 0, 9, 46, 8)], mw = fw, hw = ["duration", "easing", "delay"], gw = { // This is the most common easing curve. easeInOut: "cubic-bezier(0.4, 0, 0.2, 1)", // Objects enter the screen at full velocity from off-screen and @@ -5627,7 +6347,7 @@ const uu = ["none", fe(0, 2, 1, -1, 0, 1, 1, 0, 0, 1, 3, 0), fe(0, 3, 1, -2, 0, easeIn: "cubic-bezier(0.4, 0, 1, 1)", // The sharp curve is used by objects that may return to the screen at any time. sharp: "cubic-bezier(0.4, 0, 0.6, 1)" -}, hu = { +}, bw = { shortest: 150, shorter: 200, short: 250, @@ -5640,38 +6360,38 @@ const uu = ["none", fe(0, 2, 1, -1, 0, 1, 1, 0, 0, 1, 3, 0), fe(0, 3, 1, -2, 0, // recommended when something is leaving screen leavingScreen: 195 }; -function Ea(e) { - return `${Math.round(e)}ms`; +function _a(t) { + return `${Math.round(t)}ms`; } -function gu(e) { - if (!e) +function vw(t) { + if (!t) return 0; - const t = e / 36; - return Math.round((4 + 15 * t ** 0.25 + t / 5) * 10); + const e = t / 36; + return Math.round((4 + 15 * e ** 0.25 + e / 5) * 10); } -function bu(e) { - const t = R({}, mu, e.easing), n = R({}, hu, e.duration); - return R({ - getAutoHeightDuration: gu, +function yw(t) { + const e = P({}, gw, t.easing), n = P({}, bw, t.duration); + return P({ + getAutoHeightDuration: vw, create: (o = ["all"], a = {}) => { const { - duration: s = n.standard, - easing: l = t.easeInOut, + duration: i = n.standard, + easing: l = e.easeInOut, delay: c = 0 - } = a, d = Ne(a, fu); + } = a, d = kt(a, hw); if (process.env.NODE_ENV !== "production") { const p = (w) => typeof w == "string", m = (w) => !isNaN(parseFloat(w)); - !p(o) && !Array.isArray(o) && console.error('MUI: Argument "props" must be a string or Array.'), !m(s) && !p(s) && console.error(`MUI: Argument "duration" must be a number or a string but found ${s}.`), p(l) || console.error('MUI: Argument "easing" must be a string.'), !m(c) && !p(c) && console.error('MUI: Argument "delay" must be a number or a string.'), typeof a != "object" && console.error(["MUI: Secong argument of transition.create must be an object.", "Arguments should be either `create('prop1', options)` or `create(['prop1', 'prop2'], options)`"].join(` + !p(o) && !Array.isArray(o) && console.error('MUI: Argument "props" must be a string or Array.'), !m(i) && !p(i) && console.error(`MUI: Argument "duration" must be a number or a string but found ${i}.`), p(l) || console.error('MUI: Argument "easing" must be a string.'), !m(c) && !p(c) && console.error('MUI: Argument "delay" must be a number or a string.'), typeof a != "object" && console.error(["MUI: Secong argument of transition.create must be an object.", "Arguments should be either `create('prop1', options)` or `create(['prop1', 'prop2'], options)`"].join(` `)), Object.keys(d).length !== 0 && console.error(`MUI: Unrecognized argument(s) [${Object.keys(d).join(",")}].`); } - return (Array.isArray(o) ? o : [o]).map((p) => `${p} ${typeof s == "string" ? s : Ea(s)} ${l} ${typeof c == "string" ? c : Ea(c)}`).join(","); + return (Array.isArray(o) ? o : [o]).map((p) => `${p} ${typeof i == "string" ? i : _a(i)} ${l} ${typeof c == "string" ? c : _a(c)}`).join(","); } - }, e, { - easing: t, + }, t, { + easing: e, duration: n }); } -const vu = { +const xw = { mobileStepper: 1e3, fab: 1050, speedDial: 1050, @@ -5680,35 +6400,35 @@ const vu = { modal: 1300, snackbar: 1400, tooltip: 1500 -}, yu = vu, xu = ["breakpoints", "mixins", "spacing", "palette", "transitions", "typography", "shape"]; -function Nu(e = {}, ...t) { +}, Nw = xw, kw = ["breakpoints", "mixins", "spacing", "palette", "transitions", "typography", "shape"]; +function Ew(t = {}, ...e) { const { mixins: n = {}, palette: r = {}, transitions: o = {}, typography: a = {} - } = e, s = Ne(e, xu); - if (e.vars) - throw new Error(process.env.NODE_ENV !== "production" ? "MUI: `vars` is a private field used for CSS variables support.\nPlease use another name." : Vt(18)); - const l = au(r), c = go(e); - let d = Ze(c, { - mixins: Fp(c.breakpoints, n), + } = t, i = kt(t, kw); + if (t.vars) + throw new Error(process.env.NODE_ENV !== "production" ? "MUI: `vars` is a private field used for CSS variables support.\nPlease use another name." : Ve(18)); + const l = sw(r), c = No(t); + let d = Zt(c, { + mixins: Gu(c.breakpoints, n), palette: l, // Don't use [...shadows] until you've verified its transpiled code is not invoking the iterator protocol. - shadows: wu.slice(), - typography: lu(l, a), - transitions: bu(o), - zIndex: R({}, yu) + shadows: mw.slice(), + typography: dw(l, a), + transitions: yw(o), + zIndex: P({}, Nw) }); - if (d = Ze(d, s), d = t.reduce((p, m) => Ze(p, m), d), process.env.NODE_ENV !== "production") { - const p = ["active", "checked", "completed", "disabled", "error", "expanded", "focused", "focusVisible", "required", "selected"], m = (w, b) => { + if (d = Zt(d, i), d = e.reduce((p, m) => Zt(p, m), d), process.env.NODE_ENV !== "production") { + const p = ["active", "checked", "completed", "disabled", "error", "expanded", "focused", "focusVisible", "required", "selected"], m = (w, g) => { let v; for (v in w) { const f = w[v]; if (p.indexOf(v) !== -1 && Object.keys(f).length > 0) { if (process.env.NODE_ENV !== "production") { - const h = lr("", v); - console.error([`MUI: The \`${b}\` component increases the CSS specificity of the \`${v}\` internal state.`, "You can not override it like this: ", JSON.stringify(w, null, 2), "", `Instead, you need to use the '&.${h}' syntax:`, JSON.stringify({ + const h = pr("", v); + console.error([`MUI: The \`${g}\` component increases the CSS specificity of the \`${v}\` internal state.`, "You can not override it like this: ", JSON.stringify(w, null, 2), "", `Instead, you need to use the '&.${h}' syntax:`, JSON.stringify({ root: { [`&.${h}`]: f } @@ -5720,61 +6440,61 @@ function Nu(e = {}, ...t) { } }; Object.keys(d.components).forEach((w) => { - const b = d.components[w].styleOverrides; - b && w.indexOf("Mui") === 0 && m(b, w); + const g = d.components[w].styleOverrides; + g && w.indexOf("Mui") === 0 && m(g, w); }); } - return d.unstable_sxConfig = R({}, mo, s == null ? void 0 : s.unstable_sxConfig), d.unstable_sx = function(m) { - return ho({ + return d.unstable_sxConfig = P({}, yo, i == null ? void 0 : i.unstable_sxConfig), d.unstable_sx = function(m) { + return xo({ sx: m, theme: this }); }, d; } -const ku = Nu(), vo = ku, yo = "$$material"; -function xo({ - props: e, - name: t +const Sw = Ew(), Eo = Sw, So = "$$material"; +function To({ + props: t, + name: e }) { - return Bp({ - props: e, - name: t, - defaultTheme: vo, - themeId: yo + return Vu({ + props: t, + name: e, + defaultTheme: Eo, + themeId: So }); } -const Eu = (e) => zn(e) && e !== "classes", Tu = Dp({ - themeId: yo, - defaultTheme: vo, - rootShouldForwardProp: Eu -}), Cn = Tu; -function Cu(e) { - return lr("MuiSvgIcon", e); +const Tw = (t) => Gn(t) && t !== "classes", Cw = Bu({ + themeId: So, + defaultTheme: Eo, + rootShouldForwardProp: Tw +}), Rn = Cw; +function Ow(t) { + return pr("MuiSvgIcon", t); } -zs("MuiSvgIcon", ["root", "colorPrimary", "colorSecondary", "colorAction", "colorError", "colorDisabled", "fontSizeInherit", "fontSizeSmall", "fontSizeMedium", "fontSizeLarge"]); -const Su = ["children", "className", "color", "component", "fontSize", "htmlColor", "inheritViewBox", "titleAccess", "viewBox"], Ou = (e) => { +ps("MuiSvgIcon", ["root", "colorPrimary", "colorSecondary", "colorAction", "colorError", "colorDisabled", "fontSizeInherit", "fontSizeSmall", "fontSizeMedium", "fontSizeLarge"]); +const Rw = ["children", "className", "color", "component", "fontSize", "htmlColor", "inheritViewBox", "titleAccess", "viewBox"], _w = (t) => { const { - color: t, + color: e, fontSize: n, classes: r - } = e, o = { - root: ["root", t !== "inherit" && `color${We(t)}`, `fontSize${We(n)}`] + } = t, o = { + root: ["root", e !== "inherit" && `color${Wt(e)}`, `fontSize${Wt(n)}`] }; - return uo(o, Cu, r); -}, Ru = Cn("svg", { + return go(o, Ow, r); +}, Pw = Rn("svg", { name: "MuiSvgIcon", slot: "Root", - overridesResolver: (e, t) => { + overridesResolver: (t, e) => { const { ownerState: n - } = e; - return [t.root, n.color !== "inherit" && t[`color${We(n.color)}`], t[`fontSize${We(n.fontSize)}`]]; + } = t; + return [e.root, n.color !== "inherit" && e[`color${Wt(n.color)}`], e[`fontSize${Wt(n.fontSize)}`]]; } })(({ - theme: e, - ownerState: t + theme: t, + ownerState: e }) => { - var n, r, o, a, s, l, c, d, p, m, w, b, v; + var n, r, o, a, i, l, c, d, p, m, w, g, v; return { userSelect: "none", width: "1em", @@ -5782,65 +6502,65 @@ const Su = ["children", "className", "color", "component", "fontSize", "htmlColo display: "inline-block", // the will define the property that has `currentColor` // e.g. heroicons uses fill="none" and stroke="currentColor" - fill: t.hasSvgAsChild ? void 0 : "currentColor", + fill: e.hasSvgAsChild ? void 0 : "currentColor", flexShrink: 0, - transition: (n = e.transitions) == null || (r = n.create) == null ? void 0 : r.call(n, "fill", { - duration: (o = e.transitions) == null || (o = o.duration) == null ? void 0 : o.shorter + transition: (n = t.transitions) == null || (r = n.create) == null ? void 0 : r.call(n, "fill", { + duration: (o = t.transitions) == null || (o = o.duration) == null ? void 0 : o.shorter }), fontSize: { inherit: "inherit", - small: ((a = e.typography) == null || (s = a.pxToRem) == null ? void 0 : s.call(a, 20)) || "1.25rem", - medium: ((l = e.typography) == null || (c = l.pxToRem) == null ? void 0 : c.call(l, 24)) || "1.5rem", - large: ((d = e.typography) == null || (p = d.pxToRem) == null ? void 0 : p.call(d, 35)) || "2.1875rem" - }[t.fontSize], + small: ((a = t.typography) == null || (i = a.pxToRem) == null ? void 0 : i.call(a, 20)) || "1.25rem", + medium: ((l = t.typography) == null || (c = l.pxToRem) == null ? void 0 : c.call(l, 24)) || "1.5rem", + large: ((d = t.typography) == null || (p = d.pxToRem) == null ? void 0 : p.call(d, 35)) || "2.1875rem" + }[e.fontSize], // TODO v5 deprecate, v6 remove for sx - color: (m = (w = (e.vars || e).palette) == null || (w = w[t.color]) == null ? void 0 : w.main) != null ? m : { - action: (b = (e.vars || e).palette) == null || (b = b.action) == null ? void 0 : b.active, - disabled: (v = (e.vars || e).palette) == null || (v = v.action) == null ? void 0 : v.disabled, + color: (m = (w = (t.vars || t).palette) == null || (w = w[e.color]) == null ? void 0 : w.main) != null ? m : { + action: (g = (t.vars || t).palette) == null || (g = g.action) == null ? void 0 : g.active, + disabled: (v = (t.vars || t).palette) == null || (v = v.action) == null ? void 0 : v.disabled, inherit: void 0 - }[t.color] + }[e.color] }; -}), No = /* @__PURE__ */ M.forwardRef(function(t, n) { - const r = xo({ - props: t, +}), Co = /* @__PURE__ */ M.forwardRef(function(e, n) { + const r = To({ + props: e, name: "MuiSvgIcon" }), { children: o, className: a, - color: s = "inherit", + color: i = "inherit", component: l = "svg", fontSize: c = "medium", htmlColor: d, inheritViewBox: p = !1, titleAccess: m, viewBox: w = "0 0 24 24" - } = r, b = Ne(r, Su), v = /* @__PURE__ */ M.isValidElement(o) && o.type === "svg", f = R({}, r, { - color: s, + } = r, g = kt(r, Rw), v = /* @__PURE__ */ M.isValidElement(o) && o.type === "svg", f = P({}, r, { + color: i, component: l, fontSize: c, - instanceFontSize: t.fontSize, + instanceFontSize: e.fontSize, inheritViewBox: p, viewBox: w, hasSvgAsChild: v }), h = {}; p || (h.viewBox = w); - const E = Ou(f); - return /* @__PURE__ */ x(Ru, R({ + const E = _w(f); + return /* @__PURE__ */ x(Pw, P({ as: l, - className: bt(E.root, a), + className: be(E.root, a), focusable: "false", color: d, "aria-hidden": m ? void 0 : !0, role: m ? "img" : void 0, ref: n - }, h, b, v && o.props, { + }, h, g, v && o.props, { ownerState: f, - children: [v ? o.props.children : o, m ? /* @__PURE__ */ i("title", { + children: [v ? o.props.children : o, m ? /* @__PURE__ */ s("title", { children: m }) : null] })); }); -process.env.NODE_ENV !== "production" && (No.propTypes = { +process.env.NODE_ENV !== "production" && (Co.propTypes = { // ┌────────────────────────────── Warning ──────────────────────────────┐ // │ These PropTypes are generated from the TypeScript type definitions. │ // │ To update them, edit the d.ts file and run `pnpm proptypes`. │ @@ -5912,192 +6632,192 @@ process.env.NODE_ENV !== "production" && (No.propTypes = { */ viewBox: u.string }); -No.muiName = "SvgIcon"; -const Ta = No; -function Ws(e, t) { +Co.muiName = "SvgIcon"; +const Pa = Co; +function bs(t, e) { function n(r, o) { - return /* @__PURE__ */ i(Ta, R({ - "data-testid": `${t}Icon`, + return /* @__PURE__ */ s(Pa, P({ + "data-testid": `${e}Icon`, ref: o }, r, { - children: e + children: t })); } - return process.env.NODE_ENV !== "production" && (n.displayName = `${t}Icon`), n.muiName = Ta.muiName, /* @__PURE__ */ M.memo(/* @__PURE__ */ M.forwardRef(n)); + return process.env.NODE_ENV !== "production" && (n.displayName = `${e}Icon`), n.muiName = Pa.muiName, /* @__PURE__ */ M.memo(/* @__PURE__ */ M.forwardRef(n)); } -const Pu = { - configure: (e) => { +const $w = { + configure: (t) => { process.env.NODE_ENV !== "production" && console.warn(["MUI: `ClassNameGenerator` import from `@mui/material/utils` is outdated and might cause unexpected issues.", "", "You should use `import { unstable_ClassNameGenerator } from '@mui/material/className'` instead", "", "The detail of the issue: https://github.com/mui/material-ui/issues/30011#issuecomment-1024993401", "", "The updated documentation: https://mui.com/guides/classname-generator/"].join(` -`)), Vs.configure(e); +`)), cs.configure(t); } -}, _u = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({ +}, Iw = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({ __proto__: null, - capitalize: We, - createChainedFunction: sd, - createSvgIcon: Ws, - debounce: id, - deprecatedPropType: ld, - isMuiElement: cd, - ownerDocument: Gn, - ownerWindow: dd, - requirePropFactory: pd, - setRef: Hn, - unstable_ClassNameGenerator: Pu, - unstable_useEnhancedEffect: Lt, - unstable_useId: Ds, - unsupportedProp: fd, - useControlled: Ms, - useEventCallback: Yr, - useForkRef: xt, - useIsFocusVisible: Bs -}, Symbol.toStringTag, { value: "Module" })), $u = /* @__PURE__ */ Lc(_u); -var Ca; -function Iu() { - return Ca || (Ca = 1, function(e) { + capitalize: Wt, + createChainedFunction: lp, + createSvgIcon: bs, + debounce: cp, + deprecatedPropType: dp, + isMuiElement: pp, + ownerDocument: Yn, + ownerWindow: up, + requirePropFactory: wp, + setRef: Wn, + unstable_ClassNameGenerator: $w, + unstable_useEnhancedEffect: ze, + unstable_useId: as, + unsupportedProp: hp, + useControlled: is, + useEventCallback: Jr, + useForkRef: xe, + useIsFocusVisible: ss +}, Symbol.toStringTag, { value: "Module" })), Aw = /* @__PURE__ */ Fd(Iw); +var $a; +function Mw() { + return $a || ($a = 1, function(t) { "use client"; - Object.defineProperty(e, "__esModule", { + Object.defineProperty(t, "__esModule", { value: !0 - }), Object.defineProperty(e, "default", { + }), Object.defineProperty(t, "default", { enumerable: !0, get: function() { - return t.createSvgIcon; + return e.createSvgIcon; } }); - var t = $u; - }(Pr)), Pr; + var e = Aw; + }(Ar)), Ar; } -var Au = zc; -Object.defineProperty(lo, "__esModule", { +var Dw = Ud; +Object.defineProperty(fo, "__esModule", { value: !0 }); -var qs = lo.default = void 0, Du = Au(Iu()), Mu = Ri; -qs = lo.default = (0, Du.default)(/* @__PURE__ */ (0, Mu.jsx)("path", { +var vs = fo.default = void 0, Bw = Dw(Mw()), jw = Qs; +vs = fo.default = (0, Bw.default)(/* @__PURE__ */ (0, jw.jsx)("path", { d: "m10 17 5-5-5-5z" }), "ArrowRight"); -function Bu(e) { - return typeof e == "string"; +function Vw(t) { + return typeof t == "string"; } -function on(e, t, n) { - return e === void 0 || Bu(e) ? t : R({}, t, { - ownerState: R({}, t.ownerState, n) +function ln(t, e, n) { + return t === void 0 || Vw(t) ? e : P({}, e, { + ownerState: P({}, e.ownerState, n) }); } -const ju = { +const zw = { disableDefaultClasses: !1 -}, Vu = /* @__PURE__ */ M.createContext(ju); -function Lu(e) { +}, Lw = /* @__PURE__ */ M.createContext(zw); +function Fw(t) { const { - disableDefaultClasses: t - } = M.useContext(Vu); - return (n) => t ? "" : e(n); + disableDefaultClasses: e + } = M.useContext(Lw); + return (n) => e ? "" : t(n); } -function zu(e, t = []) { - if (e === void 0) +function Uw(t, e = []) { + if (t === void 0) return {}; const n = {}; - return Object.keys(e).filter((r) => r.match(/^on[A-Z]/) && typeof e[r] == "function" && !t.includes(r)).forEach((r) => { - n[r] = e[r]; + return Object.keys(t).filter((r) => r.match(/^on[A-Z]/) && typeof t[r] == "function" && !e.includes(r)).forEach((r) => { + n[r] = t[r]; }), n; } -function Fu(e, t, n) { - return typeof e == "function" ? e(t, n) : e; +function Gw(t, e, n) { + return typeof t == "function" ? t(e, n) : t; } -function Sa(e) { - if (e === void 0) +function Ia(t) { + if (t === void 0) return {}; - const t = {}; - return Object.keys(e).filter((n) => !(n.match(/^on[A-Z]/) && typeof e[n] == "function")).forEach((n) => { - t[n] = e[n]; - }), t; + const e = {}; + return Object.keys(t).filter((n) => !(n.match(/^on[A-Z]/) && typeof t[n] == "function")).forEach((n) => { + e[n] = t[n]; + }), e; } -function Uu(e) { +function Hw(t) { const { - getSlotProps: t, + getSlotProps: e, additionalProps: n, externalSlotProps: r, externalForwardedProps: o, className: a - } = e; - if (!t) { - const b = bt(n == null ? void 0 : n.className, a, o == null ? void 0 : o.className, r == null ? void 0 : r.className), v = R({}, n == null ? void 0 : n.style, o == null ? void 0 : o.style, r == null ? void 0 : r.style), f = R({}, n, o, r); - return b.length > 0 && (f.className = b), Object.keys(v).length > 0 && (f.style = v), { + } = t; + if (!e) { + const g = be(n == null ? void 0 : n.className, a, o == null ? void 0 : o.className, r == null ? void 0 : r.className), v = P({}, n == null ? void 0 : n.style, o == null ? void 0 : o.style, r == null ? void 0 : r.style), f = P({}, n, o, r); + return g.length > 0 && (f.className = g), Object.keys(v).length > 0 && (f.style = v), { props: f, internalRef: void 0 }; } - const s = zu(R({}, o, r)), l = Sa(r), c = Sa(o), d = t(s), p = bt(d == null ? void 0 : d.className, n == null ? void 0 : n.className, a, o == null ? void 0 : o.className, r == null ? void 0 : r.className), m = R({}, d == null ? void 0 : d.style, n == null ? void 0 : n.style, o == null ? void 0 : o.style, r == null ? void 0 : r.style), w = R({}, d, n, c, l); + const i = Uw(P({}, o, r)), l = Ia(r), c = Ia(o), d = e(i), p = be(d == null ? void 0 : d.className, n == null ? void 0 : n.className, a, o == null ? void 0 : o.className, r == null ? void 0 : r.className), m = P({}, d == null ? void 0 : d.style, n == null ? void 0 : n.style, o == null ? void 0 : o.style, r == null ? void 0 : r.style), w = P({}, d, n, c, l); return p.length > 0 && (w.className = p), Object.keys(m).length > 0 && (w.style = m), { props: w, internalRef: d.ref }; } -const Gu = ["elementType", "externalSlotProps", "ownerState", "skipResolvingSlotProps"]; -function Hu(e) { - var t; +const Xw = ["elementType", "externalSlotProps", "ownerState", "skipResolvingSlotProps"]; +function Yw(t) { + var e; const { elementType: n, externalSlotProps: r, ownerState: o, skipResolvingSlotProps: a = !1 - } = e, s = Ne(e, Gu), l = a ? {} : Fu(r, o), { + } = t, i = kt(t, Xw), l = a ? {} : Gw(r, o), { props: c, internalRef: d - } = Uu(R({}, s, { + } = Hw(P({}, i, { externalSlotProps: l - })), p = xt(d, l == null ? void 0 : l.ref, (t = e.additionalProps) == null ? void 0 : t.ref); - return on(n, R({}, c, { + })), p = xe(d, l == null ? void 0 : l.ref, (e = t.additionalProps) == null ? void 0 : e.ref); + return ln(n, P({}, c, { ref: p }), o); } -const Ks = "base"; -function Xu(e) { - return `${Ks}--${e}`; +const ys = "base"; +function Ww(t) { + return `${ys}--${t}`; } -function Yu(e, t) { - return `${Ks}-${e}-${t}`; +function qw(t, e) { + return `${ys}-${t}-${e}`; } -function Js(e, t) { - const n = Ls[t]; - return n ? Xu(n) : Yu(e, t); +function xs(t, e) { + const n = ds[e]; + return n ? Ww(n) : qw(t, e); } -function Wu(e, t) { +function Kw(t, e) { const n = {}; - return t.forEach((r) => { - n[r] = Js(e, r); + return e.forEach((r) => { + n[r] = xs(t, r); }), n; } -function qu(e) { - return typeof e == "function" ? e() : e; +function Jw(t) { + return typeof t == "function" ? t() : t; } -const Yn = /* @__PURE__ */ M.forwardRef(function(t, n) { +const Kn = /* @__PURE__ */ M.forwardRef(function(e, n) { const { children: r, container: o, disablePortal: a = !1 - } = t, [s, l] = M.useState(null), c = xt(/* @__PURE__ */ M.isValidElement(r) ? r.ref : null, n); - if (Lt(() => { - a || l(qu(o) || document.body); - }, [o, a]), Lt(() => { - if (s && !a) - return Hn(n, s), () => { - Hn(n, null); + } = e, [i, l] = M.useState(null), c = xe(/* @__PURE__ */ M.isValidElement(r) ? r.ref : null, n); + if (ze(() => { + a || l(Jw(o) || document.body); + }, [o, a]), ze(() => { + if (i && !a) + return Wn(n, i), () => { + Wn(n, null); }; - }, [n, s, a]), a) { + }, [n, i, a]), a) { if (/* @__PURE__ */ M.isValidElement(r)) { const d = { ref: c }; return /* @__PURE__ */ M.cloneElement(r, d); } - return /* @__PURE__ */ i(M.Fragment, { + return /* @__PURE__ */ s(M.Fragment, { children: r }); } - return /* @__PURE__ */ i(M.Fragment, { - children: s && /* @__PURE__ */ El.createPortal(r, s) + return /* @__PURE__ */ s(M.Fragment, { + children: i && /* @__PURE__ */ Wl.createPortal(r, i) }); }); -process.env.NODE_ENV !== "production" && (Yn.propTypes = { +process.env.NODE_ENV !== "production" && (Kn.propTypes = { // ┌────────────────────────────── Warning ──────────────────────────────┐ // │ These PropTypes are generated from the TypeScript type definitions. │ // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │ @@ -6116,59 +6836,59 @@ process.env.NODE_ENV !== "production" && (Yn.propTypes = { * By default, it uses the body of the top-level document object, * so it's simply `document.body` most of the time. */ - container: u.oneOfType([gn, u.func]), + container: u.oneOfType([yn, u.func]), /** * The `children` will be under the DOM hierarchy of the parent component. * @default false */ disablePortal: u.bool }); -process.env.NODE_ENV !== "production" && (Yn["propTypes"] = Qc(Yn.propTypes)); -var Te = "top", je = "bottom", Ve = "right", Ce = "left", ko = "auto", Sn = [Te, je, Ve, Ce], zt = "start", vn = "end", Ku = "clippingParents", Zs = "viewport", en = "popper", Ju = "reference", Oa = /* @__PURE__ */ Sn.reduce(function(e, t) { - return e.concat([t + "-" + zt, t + "-" + vn]); -}, []), Qs = /* @__PURE__ */ [].concat(Sn, [ko]).reduce(function(e, t) { - return e.concat([t, t + "-" + zt, t + "-" + vn]); -}, []), Zu = "beforeRead", Qu = "read", ew = "afterRead", tw = "beforeMain", nw = "main", rw = "afterMain", ow = "beforeWrite", aw = "write", sw = "afterWrite", iw = [Zu, Qu, ew, tw, nw, rw, ow, aw, sw]; -function qe(e) { - return e ? (e.nodeName || "").toLowerCase() : null; -} -function Ie(e) { - if (e == null) +process.env.NODE_ENV !== "production" && (Kn["propTypes"] = ep(Kn.propTypes)); +var Tt = "top", Vt = "bottom", zt = "right", Ct = "left", Oo = "auto", _n = [Tt, Vt, zt, Ct], Le = "start", Nn = "end", Zw = "clippingParents", Ns = "viewport", rn = "popper", Qw = "reference", Aa = /* @__PURE__ */ _n.reduce(function(t, e) { + return t.concat([e + "-" + Le, e + "-" + Nn]); +}, []), ks = /* @__PURE__ */ [].concat(_n, [Oo]).reduce(function(t, e) { + return t.concat([e, e + "-" + Le, e + "-" + Nn]); +}, []), tf = "beforeRead", ef = "read", nf = "afterRead", rf = "beforeMain", of = "main", af = "afterMain", sf = "beforeWrite", lf = "write", cf = "afterWrite", df = [tf, ef, nf, rf, of, af, sf, lf, cf]; +function qt(t) { + return t ? (t.nodeName || "").toLowerCase() : null; +} +function At(t) { + if (t == null) return window; - if (e.toString() !== "[object Window]") { - var t = e.ownerDocument; - return t && t.defaultView || window; + if (t.toString() !== "[object Window]") { + var e = t.ownerDocument; + return e && e.defaultView || window; } - return e; + return t; } -function kt(e) { - var t = Ie(e).Element; - return e instanceof t || e instanceof Element; +function ke(t) { + var e = At(t).Element; + return t instanceof e || t instanceof Element; } -function Be(e) { - var t = Ie(e).HTMLElement; - return e instanceof t || e instanceof HTMLElement; +function jt(t) { + var e = At(t).HTMLElement; + return t instanceof e || t instanceof HTMLElement; } -function Eo(e) { +function Ro(t) { if (typeof ShadowRoot > "u") return !1; - var t = Ie(e).ShadowRoot; - return e instanceof t || e instanceof ShadowRoot; -} -function lw(e) { - var t = e.state; - Object.keys(t.elements).forEach(function(n) { - var r = t.styles[n] || {}, o = t.attributes[n] || {}, a = t.elements[n]; - !Be(a) || !qe(a) || (Object.assign(a.style, r), Object.keys(o).forEach(function(s) { - var l = o[s]; - l === !1 ? a.removeAttribute(s) : a.setAttribute(s, l === !0 ? "" : l); + var e = At(t).ShadowRoot; + return t instanceof e || t instanceof ShadowRoot; +} +function pf(t) { + var e = t.state; + Object.keys(e.elements).forEach(function(n) { + var r = e.styles[n] || {}, o = e.attributes[n] || {}, a = e.elements[n]; + !jt(a) || !qt(a) || (Object.assign(a.style, r), Object.keys(o).forEach(function(i) { + var l = o[i]; + l === !1 ? a.removeAttribute(i) : a.setAttribute(i, l === !0 ? "" : l); })); }); } -function cw(e) { - var t = e.state, n = { +function uf(t) { + var e = t.state, n = { popper: { - position: t.options.strategy, + position: e.options.strategy, left: "0", top: "0", margin: "0" @@ -6178,43 +6898,43 @@ function cw(e) { }, reference: {} }; - return Object.assign(t.elements.popper.style, n.popper), t.styles = n, t.elements.arrow && Object.assign(t.elements.arrow.style, n.arrow), function() { - Object.keys(t.elements).forEach(function(r) { - var o = t.elements[r], a = t.attributes[r] || {}, s = Object.keys(t.styles.hasOwnProperty(r) ? t.styles[r] : n[r]), l = s.reduce(function(c, d) { + return Object.assign(e.elements.popper.style, n.popper), e.styles = n, e.elements.arrow && Object.assign(e.elements.arrow.style, n.arrow), function() { + Object.keys(e.elements).forEach(function(r) { + var o = e.elements[r], a = e.attributes[r] || {}, i = Object.keys(e.styles.hasOwnProperty(r) ? e.styles[r] : n[r]), l = i.reduce(function(c, d) { return c[d] = "", c; }, {}); - !Be(o) || !qe(o) || (Object.assign(o.style, l), Object.keys(a).forEach(function(c) { + !jt(o) || !qt(o) || (Object.assign(o.style, l), Object.keys(a).forEach(function(c) { o.removeAttribute(c); })); }); }; } -const dw = { +const wf = { name: "applyStyles", enabled: !0, phase: "write", - fn: lw, - effect: cw, + fn: pf, + effect: uf, requires: ["computeStyles"] }; -function Xe(e) { - return e.split("-")[0]; -} -var vt = Math.max, Wn = Math.min, Ft = Math.round; -function qr() { - var e = navigator.userAgentData; - return e != null && e.brands && Array.isArray(e.brands) ? e.brands.map(function(t) { - return t.brand + "/" + t.version; +function Yt(t) { + return t.split("-")[0]; +} +var ve = Math.max, Jn = Math.min, Fe = Math.round; +function Qr() { + var t = navigator.userAgentData; + return t != null && t.brands && Array.isArray(t.brands) ? t.brands.map(function(e) { + return e.brand + "/" + e.version; }).join(" ") : navigator.userAgent; } -function ei() { - return !/^((?!chrome|android).)*safari/i.test(qr()); +function Es() { + return !/^((?!chrome|android).)*safari/i.test(Qr()); } -function Ut(e, t, n) { - t === void 0 && (t = !1), n === void 0 && (n = !1); - var r = e.getBoundingClientRect(), o = 1, a = 1; - t && Be(e) && (o = e.offsetWidth > 0 && Ft(r.width) / e.offsetWidth || 1, a = e.offsetHeight > 0 && Ft(r.height) / e.offsetHeight || 1); - var s = kt(e) ? Ie(e) : window, l = s.visualViewport, c = !ei() && n, d = (r.left + (c && l ? l.offsetLeft : 0)) / o, p = (r.top + (c && l ? l.offsetTop : 0)) / a, m = r.width / o, w = r.height / a; +function Ue(t, e, n) { + e === void 0 && (e = !1), n === void 0 && (n = !1); + var r = t.getBoundingClientRect(), o = 1, a = 1; + e && jt(t) && (o = t.offsetWidth > 0 && Fe(r.width) / t.offsetWidth || 1, a = t.offsetHeight > 0 && Fe(r.height) / t.offsetHeight || 1); + var i = ke(t) ? At(t) : window, l = i.visualViewport, c = !Es() && n, d = (r.left + (c && l ? l.offsetLeft : 0)) / o, p = (r.top + (c && l ? l.offsetTop : 0)) / a, m = r.width / o, w = r.height / a; return { width: m, height: w, @@ -6226,89 +6946,89 @@ function Ut(e, t, n) { y: p }; } -function To(e) { - var t = Ut(e), n = e.offsetWidth, r = e.offsetHeight; - return Math.abs(t.width - n) <= 1 && (n = t.width), Math.abs(t.height - r) <= 1 && (r = t.height), { - x: e.offsetLeft, - y: e.offsetTop, +function _o(t) { + var e = Ue(t), n = t.offsetWidth, r = t.offsetHeight; + return Math.abs(e.width - n) <= 1 && (n = e.width), Math.abs(e.height - r) <= 1 && (r = e.height), { + x: t.offsetLeft, + y: t.offsetTop, width: n, height: r }; } -function ti(e, t) { - var n = t.getRootNode && t.getRootNode(); - if (e.contains(t)) +function Ss(t, e) { + var n = e.getRootNode && e.getRootNode(); + if (t.contains(e)) return !0; - if (n && Eo(n)) { - var r = t; + if (n && Ro(n)) { + var r = e; do { - if (r && e.isSameNode(r)) + if (r && t.isSameNode(r)) return !0; r = r.parentNode || r.host; } while (r); } return !1; } -function et(e) { - return Ie(e).getComputedStyle(e); +function te(t) { + return At(t).getComputedStyle(t); } -function pw(e) { - return ["table", "td", "th"].indexOf(qe(e)) >= 0; +function ff(t) { + return ["table", "td", "th"].indexOf(qt(t)) >= 0; } -function lt(e) { - return ((kt(e) ? e.ownerDocument : ( +function le(t) { + return ((ke(t) ? t.ownerDocument : ( // $FlowFixMe[prop-missing] - e.document + t.document )) || window.document).documentElement; } -function br(e) { - return qe(e) === "html" ? e : ( +function xr(t) { + return qt(t) === "html" ? t : ( // this is a quicker (but less type safe) way to save quite some bytes from the bundle // $FlowFixMe[incompatible-return] // $FlowFixMe[prop-missing] - e.assignedSlot || // step into the shadow DOM of the parent of a slotted node - e.parentNode || // DOM Element detected - (Eo(e) ? e.host : null) || // ShadowRoot detected + t.assignedSlot || // step into the shadow DOM of the parent of a slotted node + t.parentNode || // DOM Element detected + (Ro(t) ? t.host : null) || // ShadowRoot detected // $FlowFixMe[incompatible-call]: HTMLElement is a Node - lt(e) + le(t) ); } -function Ra(e) { - return !Be(e) || // https://github.com/popperjs/popper-core/issues/837 - et(e).position === "fixed" ? null : e.offsetParent; +function Ma(t) { + return !jt(t) || // https://github.com/popperjs/popper-core/issues/837 + te(t).position === "fixed" ? null : t.offsetParent; } -function uw(e) { - var t = /firefox/i.test(qr()), n = /Trident/i.test(qr()); - if (n && Be(e)) { - var r = et(e); +function mf(t) { + var e = /firefox/i.test(Qr()), n = /Trident/i.test(Qr()); + if (n && jt(t)) { + var r = te(t); if (r.position === "fixed") return null; } - var o = br(e); - for (Eo(o) && (o = o.host); Be(o) && ["html", "body"].indexOf(qe(o)) < 0; ) { - var a = et(o); - if (a.transform !== "none" || a.perspective !== "none" || a.contain === "paint" || ["transform", "perspective"].indexOf(a.willChange) !== -1 || t && a.willChange === "filter" || t && a.filter && a.filter !== "none") + var o = xr(t); + for (Ro(o) && (o = o.host); jt(o) && ["html", "body"].indexOf(qt(o)) < 0; ) { + var a = te(o); + if (a.transform !== "none" || a.perspective !== "none" || a.contain === "paint" || ["transform", "perspective"].indexOf(a.willChange) !== -1 || e && a.willChange === "filter" || e && a.filter && a.filter !== "none") return o; o = o.parentNode; } return null; } -function On(e) { - for (var t = Ie(e), n = Ra(e); n && pw(n) && et(n).position === "static"; ) - n = Ra(n); - return n && (qe(n) === "html" || qe(n) === "body" && et(n).position === "static") ? t : n || uw(e) || t; +function Pn(t) { + for (var e = At(t), n = Ma(t); n && ff(n) && te(n).position === "static"; ) + n = Ma(n); + return n && (qt(n) === "html" || qt(n) === "body" && te(n).position === "static") ? e : n || mf(t) || e; } -function Co(e) { - return ["top", "bottom"].indexOf(e) >= 0 ? "x" : "y"; +function Po(t) { + return ["top", "bottom"].indexOf(t) >= 0 ? "x" : "y"; } -function dn(e, t, n) { - return vt(e, Wn(t, n)); +function wn(t, e, n) { + return ve(t, Jn(e, n)); } -function ww(e, t, n) { - var r = dn(e, t, n); +function hf(t, e, n) { + var r = wn(t, e, n); return r > n ? n : r; } -function ni() { +function Ts() { return { top: 0, right: 0, @@ -6316,348 +7036,348 @@ function ni() { left: 0 }; } -function ri(e) { - return Object.assign({}, ni(), e); +function Cs(t) { + return Object.assign({}, Ts(), t); } -function oi(e, t) { - return t.reduce(function(n, r) { - return n[r] = e, n; +function Os(t, e) { + return e.reduce(function(n, r) { + return n[r] = t, n; }, {}); } -var fw = function(t, n) { - return t = typeof t == "function" ? t(Object.assign({}, n.rects, { +var gf = function(e, n) { + return e = typeof e == "function" ? e(Object.assign({}, n.rects, { placement: n.placement - })) : t, ri(typeof t != "number" ? t : oi(t, Sn)); + })) : e, Cs(typeof e != "number" ? e : Os(e, _n)); }; -function mw(e) { - var t, n = e.state, r = e.name, o = e.options, a = n.elements.arrow, s = n.modifiersData.popperOffsets, l = Xe(n.placement), c = Co(l), d = [Ce, Ve].indexOf(l) >= 0, p = d ? "height" : "width"; - if (!(!a || !s)) { - var m = fw(o.padding, n), w = To(a), b = c === "y" ? Te : Ce, v = c === "y" ? je : Ve, f = n.rects.reference[p] + n.rects.reference[c] - s[c] - n.rects.popper[p], h = s[c] - n.rects.reference[c], E = On(a), A = E ? c === "y" ? E.clientHeight || 0 : E.clientWidth || 0 : 0, O = f / 2 - h / 2, k = m[b], g = A - w[p] - m[v], _ = A / 2 - w[p] / 2 + O, L = dn(k, _, g), H = c; - n.modifiersData[r] = (t = {}, t[H] = L, t.centerOffset = L - _, t); +function bf(t) { + var e, n = t.state, r = t.name, o = t.options, a = n.elements.arrow, i = n.modifiersData.popperOffsets, l = Yt(n.placement), c = Po(l), d = [Ct, zt].indexOf(l) >= 0, p = d ? "height" : "width"; + if (!(!a || !i)) { + var m = gf(o.padding, n), w = _o(a), g = c === "y" ? Tt : Ct, v = c === "y" ? Vt : zt, f = n.rects.reference[p] + n.rects.reference[c] - i[c] - n.rects.popper[p], h = i[c] - n.rects.reference[c], E = Pn(a), _ = E ? c === "y" ? E.clientHeight || 0 : E.clientWidth || 0 : 0, C = f / 2 - h / 2, S = m[g], b = _ - w[p] - m[v], I = _ / 2 - w[p] / 2 + C, z = wn(S, I, b), H = c; + n.modifiersData[r] = (e = {}, e[H] = z, e.centerOffset = z - I, e); } } -function hw(e) { - var t = e.state, n = e.options, r = n.element, o = r === void 0 ? "[data-popper-arrow]" : r; - o != null && (typeof o == "string" && (o = t.elements.popper.querySelector(o), !o) || ti(t.elements.popper, o) && (t.elements.arrow = o)); +function vf(t) { + var e = t.state, n = t.options, r = n.element, o = r === void 0 ? "[data-popper-arrow]" : r; + o != null && (typeof o == "string" && (o = e.elements.popper.querySelector(o), !o) || Ss(e.elements.popper, o) && (e.elements.arrow = o)); } -const gw = { +const yf = { name: "arrow", enabled: !0, phase: "main", - fn: mw, - effect: hw, + fn: bf, + effect: vf, requires: ["popperOffsets"], requiresIfExists: ["preventOverflow"] }; -function Gt(e) { - return e.split("-")[1]; +function Ge(t) { + return t.split("-")[1]; } -var bw = { +var xf = { top: "auto", right: "auto", bottom: "auto", left: "auto" }; -function vw(e, t) { - var n = e.x, r = e.y, o = t.devicePixelRatio || 1; +function Nf(t, e) { + var n = t.x, r = t.y, o = e.devicePixelRatio || 1; return { - x: Ft(n * o) / o || 0, - y: Ft(r * o) / o || 0 + x: Fe(n * o) / o || 0, + y: Fe(r * o) / o || 0 }; } -function Pa(e) { - var t, n = e.popper, r = e.popperRect, o = e.placement, a = e.variation, s = e.offsets, l = e.position, c = e.gpuAcceleration, d = e.adaptive, p = e.roundOffsets, m = e.isFixed, w = s.x, b = w === void 0 ? 0 : w, v = s.y, f = v === void 0 ? 0 : v, h = typeof p == "function" ? p({ - x: b, +function Da(t) { + var e, n = t.popper, r = t.popperRect, o = t.placement, a = t.variation, i = t.offsets, l = t.position, c = t.gpuAcceleration, d = t.adaptive, p = t.roundOffsets, m = t.isFixed, w = i.x, g = w === void 0 ? 0 : w, v = i.y, f = v === void 0 ? 0 : v, h = typeof p == "function" ? p({ + x: g, y: f }) : { - x: b, + x: g, y: f }; - b = h.x, f = h.y; - var E = s.hasOwnProperty("x"), A = s.hasOwnProperty("y"), O = Ce, k = Te, g = window; + g = h.x, f = h.y; + var E = i.hasOwnProperty("x"), _ = i.hasOwnProperty("y"), C = Ct, S = Tt, b = window; if (d) { - var _ = On(n), L = "clientHeight", H = "clientWidth"; - if (_ === Ie(n) && (_ = lt(n), et(_).position !== "static" && l === "absolute" && (L = "scrollHeight", H = "scrollWidth")), _ = _, o === Te || (o === Ce || o === Ve) && a === vn) { - k = je; - var C = m && _ === g && g.visualViewport ? g.visualViewport.height : ( + var I = Pn(n), z = "clientHeight", H = "clientWidth"; + if (I === At(n) && (I = le(n), te(I).position !== "static" && l === "absolute" && (z = "scrollHeight", H = "scrollWidth")), I = I, o === Tt || (o === Ct || o === zt) && a === Nn) { + S = Vt; + var O = m && I === b && b.visualViewport ? b.visualViewport.height : ( // $FlowFixMe[prop-missing] - _[L] + I[z] ); - f -= C - r.height, f *= c ? 1 : -1; + f -= O - r.height, f *= c ? 1 : -1; } - if (o === Ce || (o === Te || o === je) && a === vn) { - O = Ve; - var P = m && _ === g && g.visualViewport ? g.visualViewport.width : ( + if (o === Ct || (o === Tt || o === Vt) && a === Nn) { + C = zt; + var $ = m && I === b && b.visualViewport ? b.visualViewport.width : ( // $FlowFixMe[prop-missing] - _[H] + I[H] ); - b -= P - r.width, b *= c ? 1 : -1; + g -= $ - r.width, g *= c ? 1 : -1; } } - var N = Object.assign({ + var k = Object.assign({ position: l - }, d && bw), B = p === !0 ? vw({ - x: b, + }, d && xf), B = p === !0 ? Nf({ + x: g, y: f - }, Ie(n)) : { - x: b, + }, At(n)) : { + x: g, y: f }; - if (b = B.x, f = B.y, c) { + if (g = B.x, f = B.y, c) { var D; - return Object.assign({}, N, (D = {}, D[k] = A ? "0" : "", D[O] = E ? "0" : "", D.transform = (g.devicePixelRatio || 1) <= 1 ? "translate(" + b + "px, " + f + "px)" : "translate3d(" + b + "px, " + f + "px, 0)", D)); + return Object.assign({}, k, (D = {}, D[S] = _ ? "0" : "", D[C] = E ? "0" : "", D.transform = (b.devicePixelRatio || 1) <= 1 ? "translate(" + g + "px, " + f + "px)" : "translate3d(" + g + "px, " + f + "px, 0)", D)); } - return Object.assign({}, N, (t = {}, t[k] = A ? f + "px" : "", t[O] = E ? b + "px" : "", t.transform = "", t)); + return Object.assign({}, k, (e = {}, e[S] = _ ? f + "px" : "", e[C] = E ? g + "px" : "", e.transform = "", e)); } -function yw(e) { - var t = e.state, n = e.options, r = n.gpuAcceleration, o = r === void 0 ? !0 : r, a = n.adaptive, s = a === void 0 ? !0 : a, l = n.roundOffsets, c = l === void 0 ? !0 : l, d = { - placement: Xe(t.placement), - variation: Gt(t.placement), - popper: t.elements.popper, - popperRect: t.rects.popper, +function kf(t) { + var e = t.state, n = t.options, r = n.gpuAcceleration, o = r === void 0 ? !0 : r, a = n.adaptive, i = a === void 0 ? !0 : a, l = n.roundOffsets, c = l === void 0 ? !0 : l, d = { + placement: Yt(e.placement), + variation: Ge(e.placement), + popper: e.elements.popper, + popperRect: e.rects.popper, gpuAcceleration: o, - isFixed: t.options.strategy === "fixed" + isFixed: e.options.strategy === "fixed" }; - t.modifiersData.popperOffsets != null && (t.styles.popper = Object.assign({}, t.styles.popper, Pa(Object.assign({}, d, { - offsets: t.modifiersData.popperOffsets, - position: t.options.strategy, - adaptive: s, + e.modifiersData.popperOffsets != null && (e.styles.popper = Object.assign({}, e.styles.popper, Da(Object.assign({}, d, { + offsets: e.modifiersData.popperOffsets, + position: e.options.strategy, + adaptive: i, roundOffsets: c - })))), t.modifiersData.arrow != null && (t.styles.arrow = Object.assign({}, t.styles.arrow, Pa(Object.assign({}, d, { - offsets: t.modifiersData.arrow, + })))), e.modifiersData.arrow != null && (e.styles.arrow = Object.assign({}, e.styles.arrow, Da(Object.assign({}, d, { + offsets: e.modifiersData.arrow, position: "absolute", adaptive: !1, roundOffsets: c - })))), t.attributes.popper = Object.assign({}, t.attributes.popper, { - "data-popper-placement": t.placement + })))), e.attributes.popper = Object.assign({}, e.attributes.popper, { + "data-popper-placement": e.placement }); } -const xw = { +const Ef = { name: "computeStyles", enabled: !0, phase: "beforeWrite", - fn: yw, + fn: kf, data: {} }; -var Bn = { +var zn = { passive: !0 }; -function Nw(e) { - var t = e.state, n = e.instance, r = e.options, o = r.scroll, a = o === void 0 ? !0 : o, s = r.resize, l = s === void 0 ? !0 : s, c = Ie(t.elements.popper), d = [].concat(t.scrollParents.reference, t.scrollParents.popper); +function Sf(t) { + var e = t.state, n = t.instance, r = t.options, o = r.scroll, a = o === void 0 ? !0 : o, i = r.resize, l = i === void 0 ? !0 : i, c = At(e.elements.popper), d = [].concat(e.scrollParents.reference, e.scrollParents.popper); return a && d.forEach(function(p) { - p.addEventListener("scroll", n.update, Bn); - }), l && c.addEventListener("resize", n.update, Bn), function() { + p.addEventListener("scroll", n.update, zn); + }), l && c.addEventListener("resize", n.update, zn), function() { a && d.forEach(function(p) { - p.removeEventListener("scroll", n.update, Bn); - }), l && c.removeEventListener("resize", n.update, Bn); + p.removeEventListener("scroll", n.update, zn); + }), l && c.removeEventListener("resize", n.update, zn); }; } -const kw = { +const Tf = { name: "eventListeners", enabled: !0, phase: "write", fn: function() { }, - effect: Nw, + effect: Sf, data: {} }; -var Ew = { +var Cf = { left: "right", right: "left", bottom: "top", top: "bottom" }; -function Un(e) { - return e.replace(/left|right|bottom|top/g, function(t) { - return Ew[t]; +function Xn(t) { + return t.replace(/left|right|bottom|top/g, function(e) { + return Cf[e]; }); } -var Tw = { +var Of = { start: "end", end: "start" }; -function _a(e) { - return e.replace(/start|end/g, function(t) { - return Tw[t]; +function Ba(t) { + return t.replace(/start|end/g, function(e) { + return Of[e]; }); } -function So(e) { - var t = Ie(e), n = t.pageXOffset, r = t.pageYOffset; +function $o(t) { + var e = At(t), n = e.pageXOffset, r = e.pageYOffset; return { scrollLeft: n, scrollTop: r }; } -function Oo(e) { - return Ut(lt(e)).left + So(e).scrollLeft; +function Io(t) { + return Ue(le(t)).left + $o(t).scrollLeft; } -function Cw(e, t) { - var n = Ie(e), r = lt(e), o = n.visualViewport, a = r.clientWidth, s = r.clientHeight, l = 0, c = 0; +function Rf(t, e) { + var n = At(t), r = le(t), o = n.visualViewport, a = r.clientWidth, i = r.clientHeight, l = 0, c = 0; if (o) { - a = o.width, s = o.height; - var d = ei(); - (d || !d && t === "fixed") && (l = o.offsetLeft, c = o.offsetTop); + a = o.width, i = o.height; + var d = Es(); + (d || !d && e === "fixed") && (l = o.offsetLeft, c = o.offsetTop); } return { width: a, - height: s, - x: l + Oo(e), + height: i, + x: l + Io(t), y: c }; } -function Sw(e) { - var t, n = lt(e), r = So(e), o = (t = e.ownerDocument) == null ? void 0 : t.body, a = vt(n.scrollWidth, n.clientWidth, o ? o.scrollWidth : 0, o ? o.clientWidth : 0), s = vt(n.scrollHeight, n.clientHeight, o ? o.scrollHeight : 0, o ? o.clientHeight : 0), l = -r.scrollLeft + Oo(e), c = -r.scrollTop; - return et(o || n).direction === "rtl" && (l += vt(n.clientWidth, o ? o.clientWidth : 0) - a), { +function _f(t) { + var e, n = le(t), r = $o(t), o = (e = t.ownerDocument) == null ? void 0 : e.body, a = ve(n.scrollWidth, n.clientWidth, o ? o.scrollWidth : 0, o ? o.clientWidth : 0), i = ve(n.scrollHeight, n.clientHeight, o ? o.scrollHeight : 0, o ? o.clientHeight : 0), l = -r.scrollLeft + Io(t), c = -r.scrollTop; + return te(o || n).direction === "rtl" && (l += ve(n.clientWidth, o ? o.clientWidth : 0) - a), { width: a, - height: s, + height: i, x: l, y: c }; } -function Ro(e) { - var t = et(e), n = t.overflow, r = t.overflowX, o = t.overflowY; +function Ao(t) { + var e = te(t), n = e.overflow, r = e.overflowX, o = e.overflowY; return /auto|scroll|overlay|hidden/.test(n + o + r); } -function ai(e) { - return ["html", "body", "#document"].indexOf(qe(e)) >= 0 ? e.ownerDocument.body : Be(e) && Ro(e) ? e : ai(br(e)); +function Rs(t) { + return ["html", "body", "#document"].indexOf(qt(t)) >= 0 ? t.ownerDocument.body : jt(t) && Ao(t) ? t : Rs(xr(t)); } -function pn(e, t) { +function fn(t, e) { var n; - t === void 0 && (t = []); - var r = ai(e), o = r === ((n = e.ownerDocument) == null ? void 0 : n.body), a = Ie(r), s = o ? [a].concat(a.visualViewport || [], Ro(r) ? r : []) : r, l = t.concat(s); + e === void 0 && (e = []); + var r = Rs(t), o = r === ((n = t.ownerDocument) == null ? void 0 : n.body), a = At(r), i = o ? [a].concat(a.visualViewport || [], Ao(r) ? r : []) : r, l = e.concat(i); return o ? l : ( // $FlowFixMe[incompatible-call]: isBody tells us target will be an HTMLElement here - l.concat(pn(br(s))) + l.concat(fn(xr(i))) ); } -function Kr(e) { - return Object.assign({}, e, { - left: e.x, - top: e.y, - right: e.x + e.width, - bottom: e.y + e.height +function to(t) { + return Object.assign({}, t, { + left: t.x, + top: t.y, + right: t.x + t.width, + bottom: t.y + t.height }); } -function Ow(e, t) { - var n = Ut(e, !1, t === "fixed"); - return n.top = n.top + e.clientTop, n.left = n.left + e.clientLeft, n.bottom = n.top + e.clientHeight, n.right = n.left + e.clientWidth, n.width = e.clientWidth, n.height = e.clientHeight, n.x = n.left, n.y = n.top, n; +function Pf(t, e) { + var n = Ue(t, !1, e === "fixed"); + return n.top = n.top + t.clientTop, n.left = n.left + t.clientLeft, n.bottom = n.top + t.clientHeight, n.right = n.left + t.clientWidth, n.width = t.clientWidth, n.height = t.clientHeight, n.x = n.left, n.y = n.top, n; } -function $a(e, t, n) { - return t === Zs ? Kr(Cw(e, n)) : kt(t) ? Ow(t, n) : Kr(Sw(lt(e))); +function ja(t, e, n) { + return e === Ns ? to(Rf(t, n)) : ke(e) ? Pf(e, n) : to(_f(le(t))); } -function Rw(e) { - var t = pn(br(e)), n = ["absolute", "fixed"].indexOf(et(e).position) >= 0, r = n && Be(e) ? On(e) : e; - return kt(r) ? t.filter(function(o) { - return kt(o) && ti(o, r) && qe(o) !== "body"; +function $f(t) { + var e = fn(xr(t)), n = ["absolute", "fixed"].indexOf(te(t).position) >= 0, r = n && jt(t) ? Pn(t) : t; + return ke(r) ? e.filter(function(o) { + return ke(o) && Ss(o, r) && qt(o) !== "body"; }) : []; } -function Pw(e, t, n, r) { - var o = t === "clippingParents" ? Rw(e) : [].concat(t), a = [].concat(o, [n]), s = a[0], l = a.reduce(function(c, d) { - var p = $a(e, d, r); - return c.top = vt(p.top, c.top), c.right = Wn(p.right, c.right), c.bottom = Wn(p.bottom, c.bottom), c.left = vt(p.left, c.left), c; - }, $a(e, s, r)); +function If(t, e, n, r) { + var o = e === "clippingParents" ? $f(t) : [].concat(e), a = [].concat(o, [n]), i = a[0], l = a.reduce(function(c, d) { + var p = ja(t, d, r); + return c.top = ve(p.top, c.top), c.right = Jn(p.right, c.right), c.bottom = Jn(p.bottom, c.bottom), c.left = ve(p.left, c.left), c; + }, ja(t, i, r)); return l.width = l.right - l.left, l.height = l.bottom - l.top, l.x = l.left, l.y = l.top, l; } -function si(e) { - var t = e.reference, n = e.element, r = e.placement, o = r ? Xe(r) : null, a = r ? Gt(r) : null, s = t.x + t.width / 2 - n.width / 2, l = t.y + t.height / 2 - n.height / 2, c; +function _s(t) { + var e = t.reference, n = t.element, r = t.placement, o = r ? Yt(r) : null, a = r ? Ge(r) : null, i = e.x + e.width / 2 - n.width / 2, l = e.y + e.height / 2 - n.height / 2, c; switch (o) { - case Te: + case Tt: c = { - x: s, - y: t.y - n.height + x: i, + y: e.y - n.height }; break; - case je: + case Vt: c = { - x: s, - y: t.y + t.height + x: i, + y: e.y + e.height }; break; - case Ve: + case zt: c = { - x: t.x + t.width, + x: e.x + e.width, y: l }; break; - case Ce: + case Ct: c = { - x: t.x - n.width, + x: e.x - n.width, y: l }; break; default: c = { - x: t.x, - y: t.y + x: e.x, + y: e.y }; } - var d = o ? Co(o) : null; + var d = o ? Po(o) : null; if (d != null) { var p = d === "y" ? "height" : "width"; switch (a) { - case zt: - c[d] = c[d] - (t[p] / 2 - n[p] / 2); + case Le: + c[d] = c[d] - (e[p] / 2 - n[p] / 2); break; - case vn: - c[d] = c[d] + (t[p] / 2 - n[p] / 2); + case Nn: + c[d] = c[d] + (e[p] / 2 - n[p] / 2); break; } } return c; } -function yn(e, t) { - t === void 0 && (t = {}); - var n = t, r = n.placement, o = r === void 0 ? e.placement : r, a = n.strategy, s = a === void 0 ? e.strategy : a, l = n.boundary, c = l === void 0 ? Ku : l, d = n.rootBoundary, p = d === void 0 ? Zs : d, m = n.elementContext, w = m === void 0 ? en : m, b = n.altBoundary, v = b === void 0 ? !1 : b, f = n.padding, h = f === void 0 ? 0 : f, E = ri(typeof h != "number" ? h : oi(h, Sn)), A = w === en ? Ju : en, O = e.rects.popper, k = e.elements[v ? A : w], g = Pw(kt(k) ? k : k.contextElement || lt(e.elements.popper), c, p, s), _ = Ut(e.elements.reference), L = si({ - reference: _, - element: O, +function kn(t, e) { + e === void 0 && (e = {}); + var n = e, r = n.placement, o = r === void 0 ? t.placement : r, a = n.strategy, i = a === void 0 ? t.strategy : a, l = n.boundary, c = l === void 0 ? Zw : l, d = n.rootBoundary, p = d === void 0 ? Ns : d, m = n.elementContext, w = m === void 0 ? rn : m, g = n.altBoundary, v = g === void 0 ? !1 : g, f = n.padding, h = f === void 0 ? 0 : f, E = Cs(typeof h != "number" ? h : Os(h, _n)), _ = w === rn ? Qw : rn, C = t.rects.popper, S = t.elements[v ? _ : w], b = If(ke(S) ? S : S.contextElement || le(t.elements.popper), c, p, i), I = Ue(t.elements.reference), z = _s({ + reference: I, + element: C, strategy: "absolute", placement: o - }), H = Kr(Object.assign({}, O, L)), C = w === en ? H : _, P = { - top: g.top - C.top + E.top, - bottom: C.bottom - g.bottom + E.bottom, - left: g.left - C.left + E.left, - right: C.right - g.right + E.right - }, N = e.modifiersData.offset; - if (w === en && N) { - var B = N[o]; - Object.keys(P).forEach(function(D) { - var J = [Ve, je].indexOf(D) >= 0 ? 1 : -1, q = [Te, je].indexOf(D) >= 0 ? "y" : "x"; - P[D] += B[q] * J; + }), H = to(Object.assign({}, C, z)), O = w === rn ? H : I, $ = { + top: b.top - O.top + E.top, + bottom: O.bottom - b.bottom + E.bottom, + left: b.left - O.left + E.left, + right: O.right - b.right + E.right + }, k = t.modifiersData.offset; + if (w === rn && k) { + var B = k[o]; + Object.keys($).forEach(function(D) { + var J = [zt, Vt].indexOf(D) >= 0 ? 1 : -1, q = [Tt, Vt].indexOf(D) >= 0 ? "y" : "x"; + $[D] += B[q] * J; }); } - return P; + return $; } -function _w(e, t) { - t === void 0 && (t = {}); - var n = t, r = n.placement, o = n.boundary, a = n.rootBoundary, s = n.padding, l = n.flipVariations, c = n.allowedAutoPlacements, d = c === void 0 ? Qs : c, p = Gt(r), m = p ? l ? Oa : Oa.filter(function(v) { - return Gt(v) === p; - }) : Sn, w = m.filter(function(v) { +function Af(t, e) { + e === void 0 && (e = {}); + var n = e, r = n.placement, o = n.boundary, a = n.rootBoundary, i = n.padding, l = n.flipVariations, c = n.allowedAutoPlacements, d = c === void 0 ? ks : c, p = Ge(r), m = p ? l ? Aa : Aa.filter(function(v) { + return Ge(v) === p; + }) : _n, w = m.filter(function(v) { return d.indexOf(v) >= 0; }); w.length === 0 && (w = m); - var b = w.reduce(function(v, f) { - return v[f] = yn(e, { + var g = w.reduce(function(v, f) { + return v[f] = kn(t, { placement: f, boundary: o, rootBoundary: a, - padding: s - })[Xe(f)], v; + padding: i + })[Yt(f)], v; }, {}); - return Object.keys(b).sort(function(v, f) { - return b[v] - b[f]; + return Object.keys(g).sort(function(v, f) { + return g[v] - g[f]; }); } -function $w(e) { - if (Xe(e) === ko) +function Mf(t) { + if (Yt(t) === Oo) return []; - var t = Un(e); - return [_a(e), t, _a(t)]; -} -function Iw(e) { - var t = e.state, n = e.options, r = e.name; - if (!t.modifiersData[r]._skip) { - for (var o = n.mainAxis, a = o === void 0 ? !0 : o, s = n.altAxis, l = s === void 0 ? !0 : s, c = n.fallbackPlacements, d = n.padding, p = n.boundary, m = n.rootBoundary, w = n.altBoundary, b = n.flipVariations, v = b === void 0 ? !0 : b, f = n.allowedAutoPlacements, h = t.options.placement, E = Xe(h), A = E === h, O = c || (A || !v ? [Un(h)] : $w(h)), k = [h].concat(O).reduce(function(V, W) { - return V.concat(Xe(W) === ko ? _w(t, { + var e = Xn(t); + return [Ba(t), e, Ba(e)]; +} +function Df(t) { + var e = t.state, n = t.options, r = t.name; + if (!e.modifiersData[r]._skip) { + for (var o = n.mainAxis, a = o === void 0 ? !0 : o, i = n.altAxis, l = i === void 0 ? !0 : i, c = n.fallbackPlacements, d = n.padding, p = n.boundary, m = n.rootBoundary, w = n.altBoundary, g = n.flipVariations, v = g === void 0 ? !0 : g, f = n.allowedAutoPlacements, h = e.options.placement, E = Yt(h), _ = E === h, C = c || (_ || !v ? [Xn(h)] : Mf(h)), S = [h].concat(C).reduce(function(V, W) { + return V.concat(Yt(W) === Oo ? Af(e, { placement: W, boundary: p, rootBoundary: m, @@ -6665,276 +7385,276 @@ function Iw(e) { flipVariations: v, allowedAutoPlacements: f }) : W); - }, []), g = t.rects.reference, _ = t.rects.popper, L = /* @__PURE__ */ new Map(), H = !0, C = k[0], P = 0; P < k.length; P++) { - var N = k[P], B = Xe(N), D = Gt(N) === zt, J = [Te, je].indexOf(B) >= 0, q = J ? "width" : "height", U = yn(t, { - placement: N, + }, []), b = e.rects.reference, I = e.rects.popper, z = /* @__PURE__ */ new Map(), H = !0, O = S[0], $ = 0; $ < S.length; $++) { + var k = S[$], B = Yt(k), D = Ge(k) === Le, J = [Tt, Vt].indexOf(B) >= 0, q = J ? "width" : "height", U = kn(e, { + placement: k, boundary: p, rootBoundary: m, altBoundary: w, padding: d - }), ee = J ? D ? Ve : Ce : D ? je : Te; - g[q] > _[q] && (ee = Un(ee)); - var ae = Un(ee), re = []; - if (a && re.push(U[B] <= 0), l && re.push(U[ee] <= 0, U[ae] <= 0), re.every(function(V) { + }), tt = J ? D ? zt : Ct : D ? Vt : Tt; + b[q] > I[q] && (tt = Xn(tt)); + var at = Xn(tt), rt = []; + if (a && rt.push(U[B] <= 0), l && rt.push(U[tt] <= 0, U[at] <= 0), rt.every(function(V) { return V; })) { - C = N, H = !1; + O = k, H = !1; break; } - L.set(N, re); + z.set(k, rt); } if (H) - for (var y = v ? 3 : 1, S = function(W) { - var X = k.find(function(Y) { - var G = L.get(Y); + for (var y = v ? 3 : 1, R = function(W) { + var X = S.find(function(Y) { + var G = z.get(Y); if (G) return G.slice(0, W).every(function(K) { return K; }); }); if (X) - return C = X, "break"; - }, z = y; z > 0; z--) { - var F = S(z); + return O = X, "break"; + }, L = y; L > 0; L--) { + var F = R(L); if (F === "break") break; } - t.placement !== C && (t.modifiersData[r]._skip = !0, t.placement = C, t.reset = !0); + e.placement !== O && (e.modifiersData[r]._skip = !0, e.placement = O, e.reset = !0); } } -const Aw = { +const Bf = { name: "flip", enabled: !0, phase: "main", - fn: Iw, + fn: Df, requiresIfExists: ["offset"], data: { _skip: !1 } }; -function Ia(e, t, n) { +function Va(t, e, n) { return n === void 0 && (n = { x: 0, y: 0 }), { - top: e.top - t.height - n.y, - right: e.right - t.width + n.x, - bottom: e.bottom - t.height + n.y, - left: e.left - t.width - n.x + top: t.top - e.height - n.y, + right: t.right - e.width + n.x, + bottom: t.bottom - e.height + n.y, + left: t.left - e.width - n.x }; } -function Aa(e) { - return [Te, Ve, je, Ce].some(function(t) { - return e[t] >= 0; +function za(t) { + return [Tt, zt, Vt, Ct].some(function(e) { + return t[e] >= 0; }); } -function Dw(e) { - var t = e.state, n = e.name, r = t.rects.reference, o = t.rects.popper, a = t.modifiersData.preventOverflow, s = yn(t, { +function jf(t) { + var e = t.state, n = t.name, r = e.rects.reference, o = e.rects.popper, a = e.modifiersData.preventOverflow, i = kn(e, { elementContext: "reference" - }), l = yn(t, { + }), l = kn(e, { altBoundary: !0 - }), c = Ia(s, r), d = Ia(l, o, a), p = Aa(c), m = Aa(d); - t.modifiersData[n] = { + }), c = Va(i, r), d = Va(l, o, a), p = za(c), m = za(d); + e.modifiersData[n] = { referenceClippingOffsets: c, popperEscapeOffsets: d, isReferenceHidden: p, hasPopperEscaped: m - }, t.attributes.popper = Object.assign({}, t.attributes.popper, { + }, e.attributes.popper = Object.assign({}, e.attributes.popper, { "data-popper-reference-hidden": p, "data-popper-escaped": m }); } -const Mw = { +const Vf = { name: "hide", enabled: !0, phase: "main", requiresIfExists: ["preventOverflow"], - fn: Dw + fn: jf }; -function Bw(e, t, n) { - var r = Xe(e), o = [Ce, Te].indexOf(r) >= 0 ? -1 : 1, a = typeof n == "function" ? n(Object.assign({}, t, { - placement: e - })) : n, s = a[0], l = a[1]; - return s = s || 0, l = (l || 0) * o, [Ce, Ve].indexOf(r) >= 0 ? { +function zf(t, e, n) { + var r = Yt(t), o = [Ct, Tt].indexOf(r) >= 0 ? -1 : 1, a = typeof n == "function" ? n(Object.assign({}, e, { + placement: t + })) : n, i = a[0], l = a[1]; + return i = i || 0, l = (l || 0) * o, [Ct, zt].indexOf(r) >= 0 ? { x: l, - y: s + y: i } : { - x: s, + x: i, y: l }; } -function jw(e) { - var t = e.state, n = e.options, r = e.name, o = n.offset, a = o === void 0 ? [0, 0] : o, s = Qs.reduce(function(p, m) { - return p[m] = Bw(m, t.rects, a), p; - }, {}), l = s[t.placement], c = l.x, d = l.y; - t.modifiersData.popperOffsets != null && (t.modifiersData.popperOffsets.x += c, t.modifiersData.popperOffsets.y += d), t.modifiersData[r] = s; +function Lf(t) { + var e = t.state, n = t.options, r = t.name, o = n.offset, a = o === void 0 ? [0, 0] : o, i = ks.reduce(function(p, m) { + return p[m] = zf(m, e.rects, a), p; + }, {}), l = i[e.placement], c = l.x, d = l.y; + e.modifiersData.popperOffsets != null && (e.modifiersData.popperOffsets.x += c, e.modifiersData.popperOffsets.y += d), e.modifiersData[r] = i; } -const Vw = { +const Ff = { name: "offset", enabled: !0, phase: "main", requires: ["popperOffsets"], - fn: jw + fn: Lf }; -function Lw(e) { - var t = e.state, n = e.name; - t.modifiersData[n] = si({ - reference: t.rects.reference, - element: t.rects.popper, +function Uf(t) { + var e = t.state, n = t.name; + e.modifiersData[n] = _s({ + reference: e.rects.reference, + element: e.rects.popper, strategy: "absolute", - placement: t.placement + placement: e.placement }); } -const zw = { +const Gf = { name: "popperOffsets", enabled: !0, phase: "read", - fn: Lw, + fn: Uf, data: {} }; -function Fw(e) { - return e === "x" ? "y" : "x"; +function Hf(t) { + return t === "x" ? "y" : "x"; } -function Uw(e) { - var t = e.state, n = e.options, r = e.name, o = n.mainAxis, a = o === void 0 ? !0 : o, s = n.altAxis, l = s === void 0 ? !1 : s, c = n.boundary, d = n.rootBoundary, p = n.altBoundary, m = n.padding, w = n.tether, b = w === void 0 ? !0 : w, v = n.tetherOffset, f = v === void 0 ? 0 : v, h = yn(t, { +function Xf(t) { + var e = t.state, n = t.options, r = t.name, o = n.mainAxis, a = o === void 0 ? !0 : o, i = n.altAxis, l = i === void 0 ? !1 : i, c = n.boundary, d = n.rootBoundary, p = n.altBoundary, m = n.padding, w = n.tether, g = w === void 0 ? !0 : w, v = n.tetherOffset, f = v === void 0 ? 0 : v, h = kn(e, { boundary: c, rootBoundary: d, padding: m, altBoundary: p - }), E = Xe(t.placement), A = Gt(t.placement), O = !A, k = Co(E), g = Fw(k), _ = t.modifiersData.popperOffsets, L = t.rects.reference, H = t.rects.popper, C = typeof f == "function" ? f(Object.assign({}, t.rects, { - placement: t.placement - })) : f, P = typeof C == "number" ? { - mainAxis: C, - altAxis: C + }), E = Yt(e.placement), _ = Ge(e.placement), C = !_, S = Po(E), b = Hf(S), I = e.modifiersData.popperOffsets, z = e.rects.reference, H = e.rects.popper, O = typeof f == "function" ? f(Object.assign({}, e.rects, { + placement: e.placement + })) : f, $ = typeof O == "number" ? { + mainAxis: O, + altAxis: O } : Object.assign({ mainAxis: 0, altAxis: 0 - }, C), N = t.modifiersData.offset ? t.modifiersData.offset[t.placement] : null, B = { + }, O), k = e.modifiersData.offset ? e.modifiersData.offset[e.placement] : null, B = { x: 0, y: 0 }; - if (_) { + if (I) { if (a) { - var D, J = k === "y" ? Te : Ce, q = k === "y" ? je : Ve, U = k === "y" ? "height" : "width", ee = _[k], ae = ee + h[J], re = ee - h[q], y = b ? -H[U] / 2 : 0, S = A === zt ? L[U] : H[U], z = A === zt ? -H[U] : -L[U], F = t.elements.arrow, V = b && F ? To(F) : { + var D, J = S === "y" ? Tt : Ct, q = S === "y" ? Vt : zt, U = S === "y" ? "height" : "width", tt = I[S], at = tt + h[J], rt = tt - h[q], y = g ? -H[U] / 2 : 0, R = _ === Le ? z[U] : H[U], L = _ === Le ? -H[U] : -z[U], F = e.elements.arrow, V = g && F ? _o(F) : { width: 0, height: 0 - }, W = t.modifiersData["arrow#persistent"] ? t.modifiersData["arrow#persistent"].padding : ni(), X = W[J], Y = W[q], G = dn(0, L[U], V[U]), K = O ? L[U] / 2 - y - G - X - P.mainAxis : S - G - X - P.mainAxis, Z = O ? -L[U] / 2 + y + G + Y + P.mainAxis : z + G + Y + P.mainAxis, de = t.elements.arrow && On(t.elements.arrow), $ = de ? k === "y" ? de.clientTop || 0 : de.clientLeft || 0 : 0, xe = (D = N == null ? void 0 : N[k]) != null ? D : 0, j = ee + K - xe - $, ye = ee + Z - xe, ze = dn(b ? Wn(ae, j) : ae, ee, b ? vt(re, ye) : re); - _[k] = ze, B[k] = ze - ee; + }, W = e.modifiersData["arrow#persistent"] ? e.modifiersData["arrow#persistent"].padding : Ts(), X = W[J], Y = W[q], G = wn(0, z[U], V[U]), K = C ? z[U] / 2 - y - G - X - $.mainAxis : R - G - X - $.mainAxis, Z = C ? -z[U] / 2 + y + G + Y + $.mainAxis : L + G + Y + $.mainAxis, dt = e.elements.arrow && Pn(e.elements.arrow), A = dt ? S === "y" ? dt.clientTop || 0 : dt.clientLeft || 0 : 0, Nt = (D = k == null ? void 0 : k[S]) != null ? D : 0, j = tt + K - Nt - A, xt = tt + Z - Nt, Ft = wn(g ? Jn(at, j) : at, tt, g ? ve(rt, xt) : rt); + I[S] = Ft, B[S] = Ft - tt; } if (l) { - var ct, ke = k === "x" ? Te : Ce, Pn = k === "x" ? je : Ve, Fe = _[g], Et = g === "y" ? "height" : "width", dt = Fe + h[ke], Tt = Fe - h[Pn], Ct = [Te, Ce].indexOf(E) !== -1, St = (ct = N == null ? void 0 : N[g]) != null ? ct : 0, pt = Ct ? dt : Fe - L[Et] - H[Et] - St + P.altAxis, Xt = Ct ? Fe + L[Et] + H[Et] - St - P.altAxis : Tt, _n = b && Ct ? ww(pt, Fe, Xt) : dn(b ? pt : dt, Fe, b ? Xt : Tt); - _[g] = _n, B[g] = _n - Fe; + var ce, Et = S === "x" ? Tt : Ct, In = S === "x" ? Vt : zt, Ut = I[b], Ee = b === "y" ? "height" : "width", de = Ut + h[Et], Se = Ut - h[In], Te = [Tt, Ct].indexOf(E) !== -1, Ce = (ce = k == null ? void 0 : k[b]) != null ? ce : 0, pe = Te ? de : Ut - z[Ee] - H[Ee] - Ce + $.altAxis, qe = Te ? Ut + z[Ee] + H[Ee] - Ce - $.altAxis : Se, An = g && Te ? hf(pe, Ut, qe) : wn(g ? pe : de, Ut, g ? qe : Se); + I[b] = An, B[b] = An - Ut; } - t.modifiersData[r] = B; + e.modifiersData[r] = B; } } -const Gw = { +const Yf = { name: "preventOverflow", enabled: !0, phase: "main", - fn: Uw, + fn: Xf, requiresIfExists: ["offset"] }; -function Hw(e) { +function Wf(t) { return { - scrollLeft: e.scrollLeft, - scrollTop: e.scrollTop + scrollLeft: t.scrollLeft, + scrollTop: t.scrollTop }; } -function Xw(e) { - return e === Ie(e) || !Be(e) ? So(e) : Hw(e); +function qf(t) { + return t === At(t) || !jt(t) ? $o(t) : Wf(t); } -function Yw(e) { - var t = e.getBoundingClientRect(), n = Ft(t.width) / e.offsetWidth || 1, r = Ft(t.height) / e.offsetHeight || 1; +function Kf(t) { + var e = t.getBoundingClientRect(), n = Fe(e.width) / t.offsetWidth || 1, r = Fe(e.height) / t.offsetHeight || 1; return n !== 1 || r !== 1; } -function Ww(e, t, n) { +function Jf(t, e, n) { n === void 0 && (n = !1); - var r = Be(t), o = Be(t) && Yw(t), a = lt(t), s = Ut(e, o, n), l = { + var r = jt(e), o = jt(e) && Kf(e), a = le(e), i = Ue(t, o, n), l = { scrollLeft: 0, scrollTop: 0 }, c = { x: 0, y: 0 }; - return (r || !r && !n) && ((qe(t) !== "body" || // https://github.com/popperjs/popper-core/issues/1078 - Ro(a)) && (l = Xw(t)), Be(t) ? (c = Ut(t, !0), c.x += t.clientLeft, c.y += t.clientTop) : a && (c.x = Oo(a))), { - x: s.left + l.scrollLeft - c.x, - y: s.top + l.scrollTop - c.y, - width: s.width, - height: s.height + return (r || !r && !n) && ((qt(e) !== "body" || // https://github.com/popperjs/popper-core/issues/1078 + Ao(a)) && (l = qf(e)), jt(e) ? (c = Ue(e, !0), c.x += e.clientLeft, c.y += e.clientTop) : a && (c.x = Io(a))), { + x: i.left + l.scrollLeft - c.x, + y: i.top + l.scrollTop - c.y, + width: i.width, + height: i.height }; } -function qw(e) { - var t = /* @__PURE__ */ new Map(), n = /* @__PURE__ */ new Set(), r = []; - e.forEach(function(a) { - t.set(a.name, a); +function Zf(t) { + var e = /* @__PURE__ */ new Map(), n = /* @__PURE__ */ new Set(), r = []; + t.forEach(function(a) { + e.set(a.name, a); }); function o(a) { n.add(a.name); - var s = [].concat(a.requires || [], a.requiresIfExists || []); - s.forEach(function(l) { + var i = [].concat(a.requires || [], a.requiresIfExists || []); + i.forEach(function(l) { if (!n.has(l)) { - var c = t.get(l); + var c = e.get(l); c && o(c); } }), r.push(a); } - return e.forEach(function(a) { + return t.forEach(function(a) { n.has(a.name) || o(a); }), r; } -function Kw(e) { - var t = qw(e); - return iw.reduce(function(n, r) { - return n.concat(t.filter(function(o) { +function Qf(t) { + var e = Zf(t); + return df.reduce(function(n, r) { + return n.concat(e.filter(function(o) { return o.phase === r; })); }, []); } -function Jw(e) { - var t; +function tm(t) { + var e; return function() { - return t || (t = new Promise(function(n) { + return e || (e = new Promise(function(n) { Promise.resolve().then(function() { - t = void 0, n(e()); + e = void 0, n(t()); }); - })), t; + })), e; }; } -function Zw(e) { - var t = e.reduce(function(n, r) { +function em(t) { + var e = t.reduce(function(n, r) { var o = n[r.name]; return n[r.name] = o ? Object.assign({}, o, r, { options: Object.assign({}, o.options, r.options), data: Object.assign({}, o.data, r.data) }) : r, n; }, {}); - return Object.keys(t).map(function(n) { - return t[n]; + return Object.keys(e).map(function(n) { + return e[n]; }); } -var Da = { +var La = { placement: "bottom", modifiers: [], strategy: "absolute" }; -function Ma() { - for (var e = arguments.length, t = new Array(e), n = 0; n < e; n++) - t[n] = arguments[n]; - return !t.some(function(r) { +function Fa() { + for (var t = arguments.length, e = new Array(t), n = 0; n < t; n++) + e[n] = arguments[n]; + return !e.some(function(r) { return !(r && typeof r.getBoundingClientRect == "function"); }); } -function Qw(e) { - e === void 0 && (e = {}); - var t = e, n = t.defaultModifiers, r = n === void 0 ? [] : n, o = t.defaultOptions, a = o === void 0 ? Da : o; +function nm(t) { + t === void 0 && (t = {}); + var e = t, n = e.defaultModifiers, r = n === void 0 ? [] : n, o = e.defaultOptions, a = o === void 0 ? La : o; return function(l, c, d) { d === void 0 && (d = a); var p = { placement: "bottom", orderedModifiers: [], - options: Object.assign({}, Da, a), + options: Object.assign({}, La, a), modifiersData: {}, elements: { reference: l, @@ -6942,18 +7662,18 @@ function Qw(e) { }, attributes: {}, styles: {} - }, m = [], w = !1, b = { + }, m = [], w = !1, g = { state: p, setOptions: function(E) { - var A = typeof E == "function" ? E(p.options) : E; - f(), p.options = Object.assign({}, a, p.options, A), p.scrollParents = { - reference: kt(l) ? pn(l) : l.contextElement ? pn(l.contextElement) : [], - popper: pn(c) + var _ = typeof E == "function" ? E(p.options) : E; + f(), p.options = Object.assign({}, a, p.options, _), p.scrollParents = { + reference: ke(l) ? fn(l) : l.contextElement ? fn(l.contextElement) : [], + popper: fn(c) }; - var O = Kw(Zw([].concat(r, p.options.modifiers))); - return p.orderedModifiers = O.filter(function(k) { - return k.enabled; - }), v(), b.update(); + var C = Qf(em([].concat(r, p.options.modifiers))); + return p.orderedModifiers = C.filter(function(S) { + return S.enabled; + }), v(), g.update(); }, // Sync update – it will always be executed, even if not necessary. This // is useful for low frequency updates where sync behavior simplifies the @@ -6962,25 +7682,25 @@ function Qw(e) { // prefer the async Popper#update method forceUpdate: function() { if (!w) { - var E = p.elements, A = E.reference, O = E.popper; - if (Ma(A, O)) { + var E = p.elements, _ = E.reference, C = E.popper; + if (Fa(_, C)) { p.rects = { - reference: Ww(A, On(O), p.options.strategy === "fixed"), - popper: To(O) - }, p.reset = !1, p.placement = p.options.placement, p.orderedModifiers.forEach(function(P) { - return p.modifiersData[P.name] = Object.assign({}, P.data); + reference: Jf(_, Pn(C), p.options.strategy === "fixed"), + popper: _o(C) + }, p.reset = !1, p.placement = p.options.placement, p.orderedModifiers.forEach(function($) { + return p.modifiersData[$.name] = Object.assign({}, $.data); }); - for (var k = 0; k < p.orderedModifiers.length; k++) { + for (var S = 0; S < p.orderedModifiers.length; S++) { if (p.reset === !0) { - p.reset = !1, k = -1; + p.reset = !1, S = -1; continue; } - var g = p.orderedModifiers[k], _ = g.fn, L = g.options, H = L === void 0 ? {} : L, C = g.name; - typeof _ == "function" && (p = _({ + var b = p.orderedModifiers[S], I = b.fn, z = b.options, H = z === void 0 ? {} : z, O = b.name; + typeof I == "function" && (p = I({ state: p, options: H, - name: C, - instance: b + name: O, + instance: g }) || p); } } @@ -6988,32 +7708,32 @@ function Qw(e) { }, // Async and optimistically optimized update – it will not be executed if // not necessary (debounced to run at most once-per-tick) - update: Jw(function() { + update: tm(function() { return new Promise(function(h) { - b.forceUpdate(), h(p); + g.forceUpdate(), h(p); }); }), destroy: function() { f(), w = !0; } }; - if (!Ma(l, c)) - return b; - b.setOptions(d).then(function(h) { + if (!Fa(l, c)) + return g; + g.setOptions(d).then(function(h) { !w && d.onFirstUpdate && d.onFirstUpdate(h); }); function v() { p.orderedModifiers.forEach(function(h) { - var E = h.name, A = h.options, O = A === void 0 ? {} : A, k = h.effect; - if (typeof k == "function") { - var g = k({ + var E = h.name, _ = h.options, C = _ === void 0 ? {} : _, S = h.effect; + if (typeof S == "function") { + var b = S({ state: p, name: E, - instance: b, - options: O - }), _ = function() { + instance: g, + options: C + }), I = function() { }; - m.push(g || _); + m.push(b || I); } }); } @@ -7022,22 +7742,22 @@ function Qw(e) { return h(); }), m = []; } - return b; + return g; }; } -var ef = [kw, zw, xw, dw, Vw, Aw, Gw, gw, Mw], tf = /* @__PURE__ */ Qw({ - defaultModifiers: ef +var rm = [Tf, Gf, Ef, wf, Ff, Bf, Yf, yf, Vf], om = /* @__PURE__ */ nm({ + defaultModifiers: rm }); -const ii = "Popper"; -function nf(e) { - return Js(ii, e); -} -Wu(ii, ["root"]); -const rf = ["anchorEl", "children", "direction", "disablePortal", "modifiers", "open", "placement", "popperOptions", "popperRef", "slotProps", "slots", "TransitionProps", "ownerState"], of = ["anchorEl", "children", "container", "direction", "disablePortal", "keepMounted", "modifiers", "open", "placement", "popperOptions", "popperRef", "style", "transition", "slotProps", "slots"]; -function af(e, t) { - if (t === "ltr") - return e; - switch (e) { +const Ps = "Popper"; +function am(t) { + return xs(Ps, t); +} +Kw(Ps, ["root"]); +const im = ["anchorEl", "children", "direction", "disablePortal", "modifiers", "open", "placement", "popperOptions", "popperRef", "slotProps", "slots", "TransitionProps", "ownerState"], sm = ["anchorEl", "children", "container", "direction", "disablePortal", "keepMounted", "modifiers", "open", "placement", "popperOptions", "popperRef", "style", "transition", "slotProps", "slots"]; +function lm(t, e) { + if (e === "ltr") + return t; + switch (t) { case "bottom-end": return "bottom-start"; case "bottom-start": @@ -7047,55 +7767,55 @@ function af(e, t) { case "top-start": return "top-end"; default: - return e; + return t; } } -function qn(e) { - return typeof e == "function" ? e() : e; +function Zn(t) { + return typeof t == "function" ? t() : t; } -function vr(e) { - return e.nodeType !== void 0; +function Nr(t) { + return t.nodeType !== void 0; } -function sf(e) { - return !vr(e); +function cm(t) { + return !Nr(t); } -const lf = () => uo({ +const dm = () => go({ root: ["root"] -}, Lu(nf)), cf = {}, df = /* @__PURE__ */ M.forwardRef(function(t, n) { +}, Fw(am)), pm = {}, um = /* @__PURE__ */ M.forwardRef(function(e, n) { var r; const { anchorEl: o, children: a, - direction: s, + direction: i, disablePortal: l, modifiers: c, open: d, placement: p, popperOptions: m, popperRef: w, - slotProps: b = {}, + slotProps: g = {}, slots: v = {}, TransitionProps: f // @ts-ignore internal logic // prevent from spreading to DOM, it can come from the parent component e.g. Select. - } = t, h = Ne(t, rf), E = M.useRef(null), A = xt(E, n), O = M.useRef(null), k = xt(O, w), g = M.useRef(k); - Lt(() => { - g.current = k; - }, [k]), M.useImperativeHandle(w, () => O.current, []); - const _ = af(p, s), [L, H] = M.useState(_), [C, P] = M.useState(qn(o)); + } = e, h = kt(e, im), E = M.useRef(null), _ = xe(E, n), C = M.useRef(null), S = xe(C, w), b = M.useRef(S); + ze(() => { + b.current = S; + }, [S]), M.useImperativeHandle(w, () => C.current, []); + const I = lm(p, i), [z, H] = M.useState(I), [O, $] = M.useState(Zn(o)); M.useEffect(() => { - O.current && O.current.forceUpdate(); + C.current && C.current.forceUpdate(); }), M.useEffect(() => { - o && P(qn(o)); - }, [o]), Lt(() => { - if (!C || !d) + o && $(Zn(o)); + }, [o]), ze(() => { + if (!O || !d) return; - const q = (ae) => { - H(ae.placement); + const q = (at) => { + H(at.placement); }; - if (process.env.NODE_ENV !== "production" && C && vr(C) && C.nodeType === 1) { - const ae = C.getBoundingClientRect(); - process.env.NODE_ENV !== "test" && ae.top === 0 && ae.left === 0 && ae.right === 0 && ae.bottom === 0 && console.warn(["MUI: The `anchorEl` prop provided to the component is invalid.", "The anchor element should be part of the document layout.", "Make sure the element is present in the document or that it's not display none."].join(` + if (process.env.NODE_ENV !== "production" && O && Nr(O) && O.nodeType === 1) { + const at = O.getBoundingClientRect(); + process.env.NODE_ENV !== "test" && at.top === 0 && at.left === 0 && at.right === 0 && at.bottom === 0 && console.warn(["MUI: The `anchorEl` prop provided to the component is invalid.", "The anchor element should be part of the document layout.", "Make sure the element is present in the document or that it's not display none."].join(` `)); } let U = [{ @@ -7113,92 +7833,92 @@ const lf = () => uo({ enabled: !0, phase: "afterWrite", fn: ({ - state: ae + state: at }) => { - q(ae); + q(at); } }]; c != null && (U = U.concat(c)), m && m.modifiers != null && (U = U.concat(m.modifiers)); - const ee = tf(C, E.current, R({ - placement: _ + const tt = om(O, E.current, P({ + placement: I }, m, { modifiers: U })); - return g.current(ee), () => { - ee.destroy(), g.current(null); + return b.current(tt), () => { + tt.destroy(), b.current(null); }; - }, [C, l, c, d, m, _]); - const N = { - placement: L + }, [O, l, c, d, m, I]); + const k = { + placement: z }; - f !== null && (N.TransitionProps = f); - const B = lf(), D = (r = v.root) != null ? r : "div", J = Hu({ + f !== null && (k.TransitionProps = f); + const B = dm(), D = (r = v.root) != null ? r : "div", J = Yw({ elementType: D, - externalSlotProps: b.root, + externalSlotProps: g.root, externalForwardedProps: h, additionalProps: { role: "tooltip", - ref: A + ref: _ }, - ownerState: t, + ownerState: e, className: B.root }); - return /* @__PURE__ */ i(D, R({}, J, { - children: typeof a == "function" ? a(N) : a + return /* @__PURE__ */ s(D, P({}, J, { + children: typeof a == "function" ? a(k) : a })); -}), li = /* @__PURE__ */ M.forwardRef(function(t, n) { +}), $s = /* @__PURE__ */ M.forwardRef(function(e, n) { const { anchorEl: r, children: o, container: a, - direction: s = "ltr", + direction: i = "ltr", disablePortal: l = !1, keepMounted: c = !1, modifiers: d, open: p, placement: m = "bottom", - popperOptions: w = cf, - popperRef: b, + popperOptions: w = pm, + popperRef: g, style: v, transition: f = !1, slotProps: h = {}, slots: E = {} - } = t, A = Ne(t, of), [O, k] = M.useState(!0), g = () => { - k(!1); - }, _ = () => { - k(!0); + } = e, _ = kt(e, sm), [C, S] = M.useState(!0), b = () => { + S(!1); + }, I = () => { + S(!0); }; - if (!c && !p && (!f || O)) + if (!c && !p && (!f || C)) return null; - let L; + let z; if (a) - L = a; + z = a; else if (r) { - const P = qn(r); - L = P && vr(P) ? Gn(P).body : Gn(null).body; + const $ = Zn(r); + z = $ && Nr($) ? Yn($).body : Yn(null).body; } - const H = !p && c && (!f || O) ? "none" : void 0, C = f ? { + const H = !p && c && (!f || C) ? "none" : void 0, O = f ? { in: p, - onEnter: g, - onExited: _ + onEnter: b, + onExited: I } : void 0; - return /* @__PURE__ */ i(Yn, { + return /* @__PURE__ */ s(Kn, { disablePortal: l, - container: L, - children: /* @__PURE__ */ i(df, R({ + container: z, + children: /* @__PURE__ */ s(um, P({ anchorEl: r, - direction: s, + direction: i, disablePortal: l, modifiers: d, ref: n, - open: f ? !O : p, + open: f ? !C : p, placement: m, popperOptions: w, - popperRef: b, + popperRef: g, slotProps: h, slots: E - }, A, { - style: R({ + }, _, { + style: P({ // Prevents scroll issue, waiting for Popper.js to add this style once initiated. position: "fixed", // Fix Popper.js display issue @@ -7206,12 +7926,12 @@ const lf = () => uo({ left: 0, display: H }, v), - TransitionProps: C, + TransitionProps: O, children: o })) }); }); -process.env.NODE_ENV !== "production" && (li.propTypes = { +process.env.NODE_ENV !== "production" && ($s.propTypes = { // ┌────────────────────────────── Warning ──────────────────────────────┐ // │ These PropTypes are generated from the TypeScript type definitions. │ // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │ @@ -7222,15 +7942,15 @@ process.env.NODE_ENV !== "production" && (li.propTypes = { * It's used to set the position of the popper. * The return value will passed as the reference object of the Popper instance. */ - anchorEl: co(u.oneOfType([gn, u.object, u.func]), (e) => { - if (e.open) { - const t = qn(e.anchorEl); - if (t && vr(t) && t.nodeType === 1) { - const n = t.getBoundingClientRect(); + anchorEl: mo(u.oneOfType([yn, u.object, u.func]), (t) => { + if (t.open) { + const e = Zn(t.anchorEl); + if (e && Nr(e) && e.nodeType === 1) { + const n = e.getBoundingClientRect(); if (process.env.NODE_ENV !== "test" && n.top === 0 && n.left === 0 && n.right === 0 && n.bottom === 0) return new Error(["MUI: The `anchorEl` prop provided to the component is invalid.", "The anchor element should be part of the document layout.", "Make sure the element is present in the document or that it's not display none."].join(` `)); - } else if (!t || typeof t.getBoundingClientRect != "function" || sf(t) && t.contextElement != null && t.contextElement.nodeType !== 1) + } else if (!e || typeof e.getBoundingClientRect != "function" || cm(e) && e.contextElement != null && e.contextElement.nodeType !== 1) return new Error(["MUI: The `anchorEl` prop provided to the component is invalid.", "It should be an HTML element instance or a virtualElement ", "(https://popper.js.org/docs/v2/virtual-elements/)."].join(` `)); } @@ -7250,7 +7970,7 @@ process.env.NODE_ENV !== "production" && (li.propTypes = { * By default, it uses the body of the top-level document object, * so it's simply `document.body` most of the time. */ - container: u.oneOfType([gn, u.func]), + container: u.oneOfType([yn, u.func]), /** * Direction of the text. * @default 'ltr' @@ -7310,7 +8030,7 @@ process.env.NODE_ENV !== "production" && (li.propTypes = { /** * A ref that points to the used popper instance. */ - popperRef: As, + popperRef: os, /** * The props used for each slot inside the Popper. * @default {} @@ -7332,22 +8052,22 @@ process.env.NODE_ENV !== "production" && (li.propTypes = { */ transition: u.bool }); -function ci() { - const e = Xs(vo); - return process.env.NODE_ENV !== "production" && M.useDebugValue(e), e[yo] || e; +function Is() { + const t = hs(Eo); + return process.env.NODE_ENV !== "production" && M.useDebugValue(t), t[So] || t; } -function Jr(e, t) { - return Jr = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function(r, o) { +function eo(t, e) { + return eo = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function(r, o) { return r.__proto__ = o, r; - }, Jr(e, t); + }, eo(t, e); } -function pf(e, t) { - e.prototype = Object.create(t.prototype), e.prototype.constructor = e, Jr(e, t); +function wm(t, e) { + t.prototype = Object.create(e.prototype), t.prototype.constructor = t, eo(t, e); } -const Ba = { +const Ua = { disabled: !1 }; -var uf = process.env.NODE_ENV !== "production" ? u.oneOfType([u.number, u.shape({ +var fm = process.env.NODE_ENV !== "production" ? u.oneOfType([u.number, u.shape({ enter: u.number, exit: u.number, appear: u.number @@ -7364,95 +8084,95 @@ process.env.NODE_ENV !== "production" && u.oneOfType([u.string, u.shape({ exitDone: u.string, exitActive: u.string })]); -const di = I.createContext(null); -var wf = function(t) { - return t.scrollTop; -}, an = "unmounted", ft = "exited", mt = "entering", At = "entered", Zr = "exiting", tt = /* @__PURE__ */ function(e) { - pf(t, e); - function t(r, o) { +const As = T.createContext(null); +var mm = function(e) { + return e.scrollTop; +}, cn = "unmounted", fe = "exited", me = "entering", Ae = "entered", no = "exiting", ee = /* @__PURE__ */ function(t) { + wm(e, t); + function e(r, o) { var a; - a = e.call(this, r, o) || this; - var s = o, l = s && !s.isMounting ? r.enter : r.appear, c; - return a.appearStatus = null, r.in ? l ? (c = ft, a.appearStatus = mt) : c = At : r.unmountOnExit || r.mountOnEnter ? c = an : c = ft, a.state = { + a = t.call(this, r, o) || this; + var i = o, l = i && !i.isMounting ? r.enter : r.appear, c; + return a.appearStatus = null, r.in ? l ? (c = fe, a.appearStatus = me) : c = Ae : r.unmountOnExit || r.mountOnEnter ? c = cn : c = fe, a.state = { status: c }, a.nextCallback = null, a; } - t.getDerivedStateFromProps = function(o, a) { - var s = o.in; - return s && a.status === an ? { - status: ft + e.getDerivedStateFromProps = function(o, a) { + var i = o.in; + return i && a.status === cn ? { + status: fe } : null; }; - var n = t.prototype; + var n = e.prototype; return n.componentDidMount = function() { this.updateStatus(!0, this.appearStatus); }, n.componentDidUpdate = function(o) { var a = null; if (o !== this.props) { - var s = this.state.status; - this.props.in ? s !== mt && s !== At && (a = mt) : (s === mt || s === At) && (a = Zr); + var i = this.state.status; + this.props.in ? i !== me && i !== Ae && (a = me) : (i === me || i === Ae) && (a = no); } this.updateStatus(!1, a); }, n.componentWillUnmount = function() { this.cancelNextCallback(); }, n.getTimeouts = function() { - var o = this.props.timeout, a, s, l; - return a = s = l = o, o != null && typeof o != "number" && (a = o.exit, s = o.enter, l = o.appear !== void 0 ? o.appear : s), { + var o = this.props.timeout, a, i, l; + return a = i = l = o, o != null && typeof o != "number" && (a = o.exit, i = o.enter, l = o.appear !== void 0 ? o.appear : i), { exit: a, - enter: s, + enter: i, appear: l }; }, n.updateStatus = function(o, a) { if (o === void 0 && (o = !1), a !== null) - if (this.cancelNextCallback(), a === mt) { + if (this.cancelNextCallback(), a === me) { if (this.props.unmountOnExit || this.props.mountOnEnter) { - var s = this.props.nodeRef ? this.props.nodeRef.current : An.findDOMNode(this); - s && wf(s); + var i = this.props.nodeRef ? this.props.nodeRef.current : Bn.findDOMNode(this); + i && mm(i); } this.performEnter(o); } else this.performExit(); else - this.props.unmountOnExit && this.state.status === ft && this.setState({ - status: an + this.props.unmountOnExit && this.state.status === fe && this.setState({ + status: cn }); }, n.performEnter = function(o) { - var a = this, s = this.props.enter, l = this.context ? this.context.isMounting : o, c = this.props.nodeRef ? [l] : [An.findDOMNode(this), l], d = c[0], p = c[1], m = this.getTimeouts(), w = l ? m.appear : m.enter; - if (!o && !s || Ba.disabled) { + var a = this, i = this.props.enter, l = this.context ? this.context.isMounting : o, c = this.props.nodeRef ? [l] : [Bn.findDOMNode(this), l], d = c[0], p = c[1], m = this.getTimeouts(), w = l ? m.appear : m.enter; + if (!o && !i || Ua.disabled) { this.safeSetState({ - status: At + status: Ae }, function() { a.props.onEntered(d); }); return; } this.props.onEnter(d, p), this.safeSetState({ - status: mt + status: me }, function() { a.props.onEntering(d, p), a.onTransitionEnd(w, function() { a.safeSetState({ - status: At + status: Ae }, function() { a.props.onEntered(d, p); }); }); }); }, n.performExit = function() { - var o = this, a = this.props.exit, s = this.getTimeouts(), l = this.props.nodeRef ? void 0 : An.findDOMNode(this); - if (!a || Ba.disabled) { + var o = this, a = this.props.exit, i = this.getTimeouts(), l = this.props.nodeRef ? void 0 : Bn.findDOMNode(this); + if (!a || Ua.disabled) { this.safeSetState({ - status: ft + status: fe }, function() { o.props.onExited(l); }); return; } this.props.onExit(l), this.safeSetState({ - status: Zr + status: no }, function() { - o.props.onExiting(l), o.onTransitionEnd(s.exit, function() { + o.props.onExiting(l), o.onTransitionEnd(i.exit, function() { o.safeSetState({ - status: ft + status: fe }, function() { o.props.onExited(l); }); @@ -7463,41 +8183,41 @@ var wf = function(t) { }, n.safeSetState = function(o, a) { a = this.setNextCallback(a), this.setState(o, a); }, n.setNextCallback = function(o) { - var a = this, s = !0; + var a = this, i = !0; return this.nextCallback = function(l) { - s && (s = !1, a.nextCallback = null, o(l)); + i && (i = !1, a.nextCallback = null, o(l)); }, this.nextCallback.cancel = function() { - s = !1; + i = !1; }, this.nextCallback; }, n.onTransitionEnd = function(o, a) { this.setNextCallback(a); - var s = this.props.nodeRef ? this.props.nodeRef.current : An.findDOMNode(this), l = o == null && !this.props.addEndListener; - if (!s || l) { + var i = this.props.nodeRef ? this.props.nodeRef.current : Bn.findDOMNode(this), l = o == null && !this.props.addEndListener; + if (!i || l) { setTimeout(this.nextCallback, 0); return; } if (this.props.addEndListener) { - var c = this.props.nodeRef ? [this.nextCallback] : [s, this.nextCallback], d = c[0], p = c[1]; + var c = this.props.nodeRef ? [this.nextCallback] : [i, this.nextCallback], d = c[0], p = c[1]; this.props.addEndListener(d, p); } o != null && setTimeout(this.nextCallback, o); }, n.render = function() { var o = this.state.status; - if (o === an) + if (o === cn) return null; - var a = this.props, s = a.children; + var a = this.props, i = a.children; a.in, a.mountOnEnter, a.unmountOnExit, a.appear, a.enter, a.exit, a.timeout, a.addEndListener, a.onEnter, a.onEntering, a.onEntered, a.onExit, a.onExiting, a.onExited, a.nodeRef; - var l = Ne(a, ["children", "in", "mountOnEnter", "unmountOnExit", "appear", "enter", "exit", "timeout", "addEndListener", "onEnter", "onEntering", "onEntered", "onExit", "onExiting", "onExited", "nodeRef"]); + var l = kt(a, ["children", "in", "mountOnEnter", "unmountOnExit", "appear", "enter", "exit", "timeout", "addEndListener", "onEnter", "onEntering", "onEntered", "onExit", "onExiting", "onExited", "nodeRef"]); return ( // allows for nested Transitions - /* @__PURE__ */ I.createElement(di.Provider, { + /* @__PURE__ */ T.createElement(As.Provider, { value: null - }, typeof s == "function" ? s(o, l) : I.cloneElement(I.Children.only(s), l)) + }, typeof i == "function" ? i(o, l) : T.cloneElement(T.Children.only(i), l)) ); - }, t; -}(I.Component); -tt.contextType = di; -tt.propTypes = process.env.NODE_ENV !== "production" ? { + }, e; +}(T.Component); +ee.contextType = As; +ee.propTypes = process.env.NODE_ENV !== "production" ? { /** * A React reference to DOM element that need to transition: * https://stackoverflow.com/a/51127130/4671932 @@ -7510,9 +8230,9 @@ tt.propTypes = process.env.NODE_ENV !== "production" ? { * [test/CSSTransition-test.js](https://github.com/reactjs/react-transition-group/blob/13435f897b3ab71f6e19d724f145596f5910581c/test/CSSTransition-test.js#L362-L437)). */ nodeRef: u.shape({ - current: typeof Element > "u" ? u.any : function(e, t, n, r, o, a) { - var s = e[t]; - return u.instanceOf(s && "ownerDocument" in s ? s.ownerDocument.defaultView.Element : Element)(e, t, n, r, o, a); + current: typeof Element > "u" ? u.any : function(t, e, n, r, o, a) { + var i = t[e]; + return u.instanceOf(i && "ownerDocument" in i ? i.ownerDocument.defaultView.Element : Element)(t, e, n, r, o, a); } }), /** @@ -7592,12 +8312,12 @@ tt.propTypes = process.env.NODE_ENV !== "production" ? { * * @type {number | { enter?: number, exit?: number, appear?: number }} */ - timeout: function(t) { - var n = uf; - t.addEndListener || (n = n.isRequired); + timeout: function(e) { + var n = fm; + e.addEndListener || (n = n.isRequired); for (var r = arguments.length, o = new Array(r > 1 ? r - 1 : 0), a = 1; a < r; a++) o[a - 1] = arguments[a]; - return n.apply(void 0, [t].concat(o)); + return n.apply(void 0, [e].concat(o)); }, /** * Add a custom transition end trigger. Called with the transitioning @@ -7666,146 +8386,146 @@ tt.propTypes = process.env.NODE_ENV !== "production" ? { */ onExited: u.func } : {}; -function It() { +function Ie() { } -tt.defaultProps = { +ee.defaultProps = { in: !1, mountOnEnter: !1, unmountOnExit: !1, appear: !1, enter: !0, exit: !0, - onEnter: It, - onEntering: It, - onEntered: It, - onExit: It, - onExiting: It, - onExited: It + onEnter: Ie, + onEntering: Ie, + onEntered: Ie, + onExit: Ie, + onExiting: Ie, + onExited: Ie }; -tt.UNMOUNTED = an; -tt.EXITED = ft; -tt.ENTERING = mt; -tt.ENTERED = At; -tt.EXITING = Zr; -const ff = tt, mf = (e) => e.scrollTop; -function ja(e, t) { +ee.UNMOUNTED = cn; +ee.EXITED = fe; +ee.ENTERING = me; +ee.ENTERED = Ae; +ee.EXITING = no; +const hm = ee, gm = (t) => t.scrollTop; +function Ga(t, e) { var n, r; const { timeout: o, easing: a, - style: s = {} - } = e; + style: i = {} + } = t; return { - duration: (n = s.transitionDuration) != null ? n : typeof o == "number" ? o : o[t.mode] || 0, - easing: (r = s.transitionTimingFunction) != null ? r : typeof a == "object" ? a[t.mode] : a, - delay: s.transitionDelay + duration: (n = i.transitionDuration) != null ? n : typeof o == "number" ? o : o[e.mode] || 0, + easing: (r = i.transitionTimingFunction) != null ? r : typeof a == "object" ? a[e.mode] : a, + delay: i.transitionDelay }; } -const hf = ["addEndListener", "appear", "children", "easing", "in", "onEnter", "onEntered", "onEntering", "onExit", "onExited", "onExiting", "style", "timeout", "TransitionComponent"]; -function Qr(e) { - return `scale(${e}, ${e ** 2})`; +const bm = ["addEndListener", "appear", "children", "easing", "in", "onEnter", "onEntered", "onEntering", "onExit", "onExited", "onExiting", "style", "timeout", "TransitionComponent"]; +function ro(t) { + return `scale(${t}, ${t ** 2})`; } -const gf = { +const vm = { entering: { opacity: 1, - transform: Qr(1) + transform: ro(1) }, entered: { opacity: 1, transform: "none" } -}, Vr = typeof navigator < "u" && /^((?!chrome|android).)*(safari|mobile)/i.test(navigator.userAgent) && /(os |version\/)15(.|_)4/i.test(navigator.userAgent), Po = /* @__PURE__ */ M.forwardRef(function(t, n) { +}, Ur = typeof navigator < "u" && /^((?!chrome|android).)*(safari|mobile)/i.test(navigator.userAgent) && /(os |version\/)15(.|_)4/i.test(navigator.userAgent), Mo = /* @__PURE__ */ M.forwardRef(function(e, n) { const { addEndListener: r, appear: o = !0, children: a, - easing: s, + easing: i, in: l, onEnter: c, onEntered: d, onEntering: p, onExit: m, onExited: w, - onExiting: b, + onExiting: g, style: v, timeout: f = "auto", // eslint-disable-next-line react/prop-types - TransitionComponent: h = ff - } = t, E = Ne(t, hf), A = rn(), O = M.useRef(), k = ci(), g = M.useRef(null), _ = xt(g, a.ref, n), L = (q) => (U) => { + TransitionComponent: h = hm + } = e, E = kt(e, bm), _ = sn(), C = M.useRef(), S = Is(), b = M.useRef(null), I = xe(b, a.ref, n), z = (q) => (U) => { if (q) { - const ee = g.current; - U === void 0 ? q(ee) : q(ee, U); + const tt = b.current; + U === void 0 ? q(tt) : q(tt, U); } - }, H = L(p), C = L((q, U) => { - mf(q); + }, H = z(p), O = z((q, U) => { + gm(q); const { - duration: ee, - delay: ae, - easing: re - } = ja({ + duration: tt, + delay: at, + easing: rt + } = Ga({ style: v, timeout: f, - easing: s + easing: i }, { mode: "enter" }); let y; - f === "auto" ? (y = k.transitions.getAutoHeightDuration(q.clientHeight), O.current = y) : y = ee, q.style.transition = [k.transitions.create("opacity", { + f === "auto" ? (y = S.transitions.getAutoHeightDuration(q.clientHeight), C.current = y) : y = tt, q.style.transition = [S.transitions.create("opacity", { duration: y, - delay: ae - }), k.transitions.create("transform", { - duration: Vr ? y : y * 0.666, - delay: ae, - easing: re + delay: at + }), S.transitions.create("transform", { + duration: Ur ? y : y * 0.666, + delay: at, + easing: rt })].join(","), c && c(q, U); - }), P = L(d), N = L(b), B = L((q) => { + }), $ = z(d), k = z(g), B = z((q) => { const { duration: U, - delay: ee, - easing: ae - } = ja({ + delay: tt, + easing: at + } = Ga({ style: v, timeout: f, - easing: s + easing: i }, { mode: "exit" }); - let re; - f === "auto" ? (re = k.transitions.getAutoHeightDuration(q.clientHeight), O.current = re) : re = U, q.style.transition = [k.transitions.create("opacity", { - duration: re, - delay: ee - }), k.transitions.create("transform", { - duration: Vr ? re : re * 0.666, - delay: Vr ? ee : ee || re * 0.333, - easing: ae - })].join(","), q.style.opacity = 0, q.style.transform = Qr(0.75), m && m(q); - }), D = L(w); - return /* @__PURE__ */ i(h, R({ + let rt; + f === "auto" ? (rt = S.transitions.getAutoHeightDuration(q.clientHeight), C.current = rt) : rt = U, q.style.transition = [S.transitions.create("opacity", { + duration: rt, + delay: tt + }), S.transitions.create("transform", { + duration: Ur ? rt : rt * 0.666, + delay: Ur ? tt : tt || rt * 0.333, + easing: at + })].join(","), q.style.opacity = 0, q.style.transform = ro(0.75), m && m(q); + }), D = z(w); + return /* @__PURE__ */ s(h, P({ appear: o, in: l, - nodeRef: g, - onEnter: C, - onEntered: P, + nodeRef: b, + onEnter: O, + onEntered: $, onEntering: H, onExit: B, onExited: D, - onExiting: N, + onExiting: k, addEndListener: (q) => { - f === "auto" && A.start(O.current || 0, q), r && r(g.current, q); + f === "auto" && _.start(C.current || 0, q), r && r(b.current, q); }, timeout: f === "auto" ? null : f }, E, { - children: (q, U) => /* @__PURE__ */ M.cloneElement(a, R({ - style: R({ + children: (q, U) => /* @__PURE__ */ M.cloneElement(a, P({ + style: P({ opacity: 0, - transform: Qr(0.75), + transform: ro(0.75), visibility: q === "exited" && !l ? "hidden" : void 0 - }, gf[q], v, a.props.style), - ref: _ + }, vm[q], v, a.props.style), + ref: I }, U)) })); }); -process.env.NODE_ENV !== "production" && (Po.propTypes = { +process.env.NODE_ENV !== "production" && (Mo.propTypes = { // ┌────────────────────────────── Warning ──────────────────────────────┐ // │ These PropTypes are generated from the TypeScript type definitions. │ // │ To update them, edit the d.ts file and run `pnpm proptypes`. │ @@ -7825,7 +8545,7 @@ process.env.NODE_ENV !== "production" && (Po.propTypes = { /** * A single child content element. */ - children: $s.isRequired, + children: ns.isRequired, /** * The transition timing function. * You may specify a single easing or a object containing enter and exit values. @@ -7879,56 +8599,56 @@ process.env.NODE_ENV !== "production" && (Po.propTypes = { exit: u.number })]) }); -Po.muiSupportAuto = !0; -const Va = Po, bf = ["anchorEl", "component", "components", "componentsProps", "container", "disablePortal", "keepMounted", "modifiers", "open", "placement", "popperOptions", "popperRef", "transition", "slots", "slotProps"], vf = Cn(li, { +Mo.muiSupportAuto = !0; +const Ha = Mo, ym = ["anchorEl", "component", "components", "componentsProps", "container", "disablePortal", "keepMounted", "modifiers", "open", "placement", "popperOptions", "popperRef", "transition", "slots", "slotProps"], xm = Rn($s, { name: "MuiPopper", slot: "Root", - overridesResolver: (e, t) => t.root -})({}), pi = /* @__PURE__ */ M.forwardRef(function(t, n) { + overridesResolver: (t, e) => e.root +})({}), Ms = /* @__PURE__ */ M.forwardRef(function(e, n) { var r; - const o = Hs(), a = xo({ - props: t, + const o = ms(), a = To({ + props: e, name: "MuiPopper" }), { - anchorEl: s, + anchorEl: i, component: l, components: c, componentsProps: d, container: p, disablePortal: m, keepMounted: w, - modifiers: b, + modifiers: g, open: v, placement: f, popperOptions: h, popperRef: E, - transition: A, - slots: O, - slotProps: k - } = a, g = Ne(a, bf), _ = (r = O == null ? void 0 : O.root) != null ? r : c == null ? void 0 : c.Root, L = R({ - anchorEl: s, + transition: _, + slots: C, + slotProps: S + } = a, b = kt(a, ym), I = (r = C == null ? void 0 : C.root) != null ? r : c == null ? void 0 : c.Root, z = P({ + anchorEl: i, container: p, disablePortal: m, keepMounted: w, - modifiers: b, + modifiers: g, open: v, placement: f, popperOptions: h, popperRef: E, - transition: A - }, g); - return /* @__PURE__ */ i(vf, R({ + transition: _ + }, b); + return /* @__PURE__ */ s(xm, P({ as: l, direction: o == null ? void 0 : o.direction, slots: { - root: _ + root: I }, - slotProps: k ?? d - }, L, { + slotProps: S ?? d + }, z, { ref: n })); }); -process.env.NODE_ENV !== "production" && (pi.propTypes = { +process.env.NODE_ENV !== "production" && (Ms.propTypes = { // ┌────────────────────────────── Warning ──────────────────────────────┐ // │ These PropTypes are generated from the TypeScript type definitions. │ // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │ @@ -7939,7 +8659,7 @@ process.env.NODE_ENV !== "production" && (pi.propTypes = { * It's used to set the position of the popper. * The return value will passed as the reference object of the Popper instance. */ - anchorEl: u.oneOfType([gn, u.object, u.func]), + anchorEl: u.oneOfType([yn, u.object, u.func]), /** * Popper render function or node. */ @@ -7974,7 +8694,7 @@ process.env.NODE_ENV !== "production" && (pi.propTypes = { * By default, it uses the body of the top-level document object, * so it's simply `document.body` most of the time. */ - container: u.oneOfType([gn, u.func]), + container: u.oneOfType([yn, u.func]), /** * The `children` will be under the DOM hierarchy of the parent component. * @default false @@ -8029,7 +8749,7 @@ process.env.NODE_ENV !== "production" && (pi.propTypes = { /** * A ref that points to the used popper instance. */ - popperRef: As, + popperRef: os, /** * The props used for each slot inside the Popper. * @default {} @@ -8055,63 +8775,63 @@ process.env.NODE_ENV !== "production" && (pi.propTypes = { */ transition: u.bool }); -const ui = pi; -function yf(e) { - return lr("MuiTooltip", e); +const Ds = Ms; +function Nm(t) { + return pr("MuiTooltip", t); } -const xf = zs("MuiTooltip", ["popper", "popperInteractive", "popperArrow", "popperClose", "tooltip", "tooltipArrow", "touch", "tooltipPlacementLeft", "tooltipPlacementRight", "tooltipPlacementTop", "tooltipPlacementBottom", "arrow"]), rt = xf, Nf = ["arrow", "children", "classes", "components", "componentsProps", "describeChild", "disableFocusListener", "disableHoverListener", "disableInteractive", "disableTouchListener", "enterDelay", "enterNextDelay", "enterTouchDelay", "followCursor", "id", "leaveDelay", "leaveTouchDelay", "onClose", "onOpen", "open", "placement", "PopperComponent", "PopperProps", "slotProps", "slots", "title", "TransitionComponent", "TransitionProps"]; -function kf(e) { - return Math.round(e * 1e5) / 1e5; +const km = ps("MuiTooltip", ["popper", "popperInteractive", "popperArrow", "popperClose", "tooltip", "tooltipArrow", "touch", "tooltipPlacementLeft", "tooltipPlacementRight", "tooltipPlacementTop", "tooltipPlacementBottom", "arrow"]), re = km, Em = ["arrow", "children", "classes", "components", "componentsProps", "describeChild", "disableFocusListener", "disableHoverListener", "disableInteractive", "disableTouchListener", "enterDelay", "enterNextDelay", "enterTouchDelay", "followCursor", "id", "leaveDelay", "leaveTouchDelay", "onClose", "onOpen", "open", "placement", "PopperComponent", "PopperProps", "slotProps", "slots", "title", "TransitionComponent", "TransitionProps"]; +function Sm(t) { + return Math.round(t * 1e5) / 1e5; } -const Ef = (e) => { +const Tm = (t) => { const { - classes: t, + classes: e, disableInteractive: n, arrow: r, touch: o, placement: a - } = e, s = { + } = t, i = { popper: ["popper", !n && "popperInteractive", r && "popperArrow"], - tooltip: ["tooltip", r && "tooltipArrow", o && "touch", `tooltipPlacement${We(a.split("-")[0])}`], + tooltip: ["tooltip", r && "tooltipArrow", o && "touch", `tooltipPlacement${Wt(a.split("-")[0])}`], arrow: ["arrow"] }; - return uo(s, yf, t); -}, Tf = Cn(ui, { + return go(i, Nm, e); +}, Cm = Rn(Ds, { name: "MuiTooltip", slot: "Popper", - overridesResolver: (e, t) => { + overridesResolver: (t, e) => { const { ownerState: n - } = e; - return [t.popper, !n.disableInteractive && t.popperInteractive, n.arrow && t.popperArrow, !n.open && t.popperClose]; + } = t; + return [e.popper, !n.disableInteractive && e.popperInteractive, n.arrow && e.popperArrow, !n.open && e.popperClose]; } })(({ - theme: e, - ownerState: t, + theme: t, + ownerState: e, open: n -}) => R({ - zIndex: (e.vars || e).zIndex.tooltip, +}) => P({ + zIndex: (t.vars || t).zIndex.tooltip, pointerEvents: "none" -}, !t.disableInteractive && { +}, !e.disableInteractive && { pointerEvents: "auto" }, !n && { pointerEvents: "none" -}, t.arrow && { - [`&[data-popper-placement*="bottom"] .${rt.arrow}`]: { +}, e.arrow && { + [`&[data-popper-placement*="bottom"] .${re.arrow}`]: { top: 0, marginTop: "-0.71em", "&::before": { transformOrigin: "0 100%" } }, - [`&[data-popper-placement*="top"] .${rt.arrow}`]: { + [`&[data-popper-placement*="top"] .${re.arrow}`]: { bottom: 0, marginBottom: "-0.71em", "&::before": { transformOrigin: "100% 0" } }, - [`&[data-popper-placement*="right"] .${rt.arrow}`]: R({}, t.isRtl ? { + [`&[data-popper-placement*="right"] .${re.arrow}`]: P({}, e.isRtl ? { right: 0, marginRight: "-0.71em" } : { @@ -8124,7 +8844,7 @@ const Ef = (e) => { transformOrigin: "100% 100%" } }), - [`&[data-popper-placement*="left"] .${rt.arrow}`]: R({}, t.isRtl ? { + [`&[data-popper-placement*="left"] .${re.arrow}`]: P({}, e.isRtl ? { left: 0, marginLeft: "-0.71em" } : { @@ -8137,85 +8857,85 @@ const Ef = (e) => { transformOrigin: "0 0" } }) -})), Cf = Cn("div", { +})), Om = Rn("div", { name: "MuiTooltip", slot: "Tooltip", - overridesResolver: (e, t) => { + overridesResolver: (t, e) => { const { ownerState: n - } = e; - return [t.tooltip, n.touch && t.touch, n.arrow && t.tooltipArrow, t[`tooltipPlacement${We(n.placement.split("-")[0])}`]]; + } = t; + return [e.tooltip, n.touch && e.touch, n.arrow && e.tooltipArrow, e[`tooltipPlacement${Wt(n.placement.split("-")[0])}`]]; } })(({ - theme: e, - ownerState: t -}) => R({ - backgroundColor: e.vars ? e.vars.palette.Tooltip.bg : Ys(e.palette.grey[700], 0.92), - borderRadius: (e.vars || e).shape.borderRadius, - color: (e.vars || e).palette.common.white, - fontFamily: e.typography.fontFamily, + theme: t, + ownerState: e +}) => P({ + backgroundColor: t.vars ? t.vars.palette.Tooltip.bg : gs(t.palette.grey[700], 0.92), + borderRadius: (t.vars || t).shape.borderRadius, + color: (t.vars || t).palette.common.white, + fontFamily: t.typography.fontFamily, padding: "4px 8px", - fontSize: e.typography.pxToRem(11), + fontSize: t.typography.pxToRem(11), maxWidth: 300, margin: 2, wordWrap: "break-word", - fontWeight: e.typography.fontWeightMedium -}, t.arrow && { + fontWeight: t.typography.fontWeightMedium +}, e.arrow && { position: "relative", margin: 0 -}, t.touch && { +}, e.touch && { padding: "8px 16px", - fontSize: e.typography.pxToRem(14), - lineHeight: `${kf(16 / 14)}em`, - fontWeight: e.typography.fontWeightRegular + fontSize: t.typography.pxToRem(14), + lineHeight: `${Sm(16 / 14)}em`, + fontWeight: t.typography.fontWeightRegular }, { - [`.${rt.popper}[data-popper-placement*="left"] &`]: R({ + [`.${re.popper}[data-popper-placement*="left"] &`]: P({ transformOrigin: "right center" - }, t.isRtl ? R({ + }, e.isRtl ? P({ marginLeft: "14px" - }, t.touch && { + }, e.touch && { marginLeft: "24px" - }) : R({ + }) : P({ marginRight: "14px" - }, t.touch && { + }, e.touch && { marginRight: "24px" })), - [`.${rt.popper}[data-popper-placement*="right"] &`]: R({ + [`.${re.popper}[data-popper-placement*="right"] &`]: P({ transformOrigin: "left center" - }, t.isRtl ? R({ + }, e.isRtl ? P({ marginRight: "14px" - }, t.touch && { + }, e.touch && { marginRight: "24px" - }) : R({ + }) : P({ marginLeft: "14px" - }, t.touch && { + }, e.touch && { marginLeft: "24px" })), - [`.${rt.popper}[data-popper-placement*="top"] &`]: R({ + [`.${re.popper}[data-popper-placement*="top"] &`]: P({ transformOrigin: "center bottom", marginBottom: "14px" - }, t.touch && { + }, e.touch && { marginBottom: "24px" }), - [`.${rt.popper}[data-popper-placement*="bottom"] &`]: R({ + [`.${re.popper}[data-popper-placement*="bottom"] &`]: P({ transformOrigin: "center top", marginTop: "14px" - }, t.touch && { + }, e.touch && { marginTop: "24px" }) -})), Sf = Cn("span", { +})), Rm = Rn("span", { name: "MuiTooltip", slot: "Arrow", - overridesResolver: (e, t) => t.arrow + overridesResolver: (t, e) => e.arrow })(({ - theme: e + theme: t }) => ({ overflow: "hidden", position: "absolute", width: "1em", height: "0.71em", boxSizing: "border-box", - color: e.vars ? e.vars.palette.Tooltip.bg : Ys(e.palette.grey[700], 0.9), + color: t.vars ? t.vars.palette.Tooltip.bg : gs(t.palette.grey[700], 0.9), "&::before": { content: '""', margin: "auto", @@ -8226,39 +8946,39 @@ const Ef = (e) => { transform: "rotate(45deg)" } })); -let jn = !1; -const La = new kn(); -let tn = { +let Ln = !1; +const Xa = new Tn(); +let on = { x: 0, y: 0 }; -function Vn(e, t) { +function Fn(t, e) { return (n) => { - t && t(n), e(n); + e && e(n), t(n); }; } -const wi = /* @__PURE__ */ M.forwardRef(function(t, n) { - var r, o, a, s, l, c, d, p, m, w, b, v, f, h, E, A, O, k, g; - const _ = xo({ - props: t, +const Bs = /* @__PURE__ */ M.forwardRef(function(e, n) { + var r, o, a, i, l, c, d, p, m, w, g, v, f, h, E, _, C, S, b; + const I = To({ + props: e, name: "MuiTooltip" }), { - arrow: L = !1, + arrow: z = !1, children: H, - components: C = {}, - componentsProps: P = {}, - describeChild: N = !1, + components: O = {}, + componentsProps: $ = {}, + describeChild: k = !1, disableFocusListener: B = !1, disableHoverListener: D = !1, disableInteractive: J = !1, disableTouchListener: q = !1, enterDelay: U = 100, - enterNextDelay: ee = 0, - enterTouchDelay: ae = 700, - followCursor: re = !1, + enterNextDelay: tt = 0, + enterTouchDelay: at = 700, + followCursor: rt = !1, id: y, - leaveDelay: S = 0, - leaveTouchDelay: z = 1500, + leaveDelay: R = 0, + leaveTouchDelay: L = 1500, onClose: F, onOpen: V, open: W, @@ -8267,170 +8987,170 @@ const wi = /* @__PURE__ */ M.forwardRef(function(t, n) { PopperProps: G = {}, slotProps: K = {}, slots: Z = {}, - title: de, - TransitionComponent: $ = Va, - TransitionProps: xe - } = _, j = Ne(_, Nf), ye = /* @__PURE__ */ M.isValidElement(H) ? H : /* @__PURE__ */ i("span", { + title: dt, + TransitionComponent: A = Ha, + TransitionProps: Nt + } = I, j = kt(I, Em), xt = /* @__PURE__ */ M.isValidElement(H) ? H : /* @__PURE__ */ s("span", { children: H - }), ze = ci(), ct = ze.direction === "rtl", [ke, Pn] = M.useState(), [Fe, Et] = M.useState(null), dt = M.useRef(!1), Tt = J || re, Ct = rn(), St = rn(), pt = rn(), Xt = rn(), [_n, _o] = Ms({ + }), Ft = Is(), ce = Ft.direction === "rtl", [Et, In] = M.useState(), [Ut, Ee] = M.useState(null), de = M.useRef(!1), Se = J || rt, Te = sn(), Ce = sn(), pe = sn(), qe = sn(), [An, Do] = is({ controlled: W, default: !1, name: "Tooltip", state: "open" }); - let Ke = _n; + let Kt = An; if (process.env.NODE_ENV !== "production") { const { current: Q } = M.useRef(W !== void 0); M.useEffect(() => { - ke && ke.disabled && !Q && de !== "" && ke.tagName.toLowerCase() === "button" && console.error(["MUI: You are providing a disabled `button` child to the Tooltip component.", "A disabled element does not fire events.", "Tooltip needs to listen to the child element's events to display the title.", "", "Add a simple wrapper element, such as a `span`."].join(` + Et && Et.disabled && !Q && dt !== "" && Et.tagName.toLowerCase() === "button" && console.error(["MUI: You are providing a disabled `button` child to the Tooltip component.", "A disabled element does not fire events.", "Tooltip needs to listen to the child element's events to display the title.", "", "Add a simple wrapper element, such as a `span`."].join(` `)); - }, [de, ke, Q]); + }, [dt, Et, Q]); } - const yr = Ds(y), Yt = M.useRef(), $n = Yr(() => { - Yt.current !== void 0 && (document.body.style.WebkitUserSelect = Yt.current, Yt.current = void 0), Xt.clear(); + const kr = as(y), Ke = M.useRef(), Mn = Jr(() => { + Ke.current !== void 0 && (document.body.style.WebkitUserSelect = Ke.current, Ke.current = void 0), qe.clear(); }); - M.useEffect(() => $n, [$n]); - const $o = (Q) => { - La.clear(), jn = !0, _o(!0), V && !Ke && V(Q); - }, In = Yr( + M.useEffect(() => Mn, [Mn]); + const Bo = (Q) => { + Xa.clear(), Ln = !0, Do(!0), V && !Kt && V(Q); + }, Dn = Jr( /** * @param {React.SyntheticEvent | Event} event */ (Q) => { - La.start(800 + S, () => { - jn = !1; - }), _o(!1), F && Ke && F(Q), Ct.start(ze.transitions.duration.shortest, () => { - dt.current = !1; + Xa.start(800 + R, () => { + Ln = !1; + }), Do(!1), F && Kt && F(Q), Te.start(Ft.transitions.duration.shortest, () => { + de.current = !1; }); } - ), xr = (Q) => { - dt.current && Q.type !== "touchstart" || (ke && ke.removeAttribute("title"), St.clear(), pt.clear(), U || jn && ee ? St.start(jn ? ee : U, () => { - $o(Q); - }) : $o(Q)); - }, Io = (Q) => { - St.clear(), pt.start(S, () => { - In(Q); + ), Er = (Q) => { + de.current && Q.type !== "touchstart" || (Et && Et.removeAttribute("title"), Ce.clear(), pe.clear(), U || Ln && tt ? Ce.start(Ln ? tt : U, () => { + Bo(Q); + }) : Bo(Q)); + }, jo = (Q) => { + Ce.clear(), pe.start(R, () => { + Dn(Q); }); }, { - isFocusVisibleRef: Ao, - onBlur: gi, - onFocus: bi, - ref: vi - } = Bs(), [, Do] = M.useState(!1), Mo = (Q) => { - gi(Q), Ao.current === !1 && (Do(!1), Io(Q)); - }, Bo = (Q) => { - ke || Pn(Q.currentTarget), bi(Q), Ao.current === !0 && (Do(!0), xr(Q)); - }, jo = (Q) => { - dt.current = !0; - const Re = ye.props; - Re.onTouchStart && Re.onTouchStart(Q); - }, Vo = xr, Lo = Io, yi = (Q) => { - jo(Q), pt.clear(), Ct.clear(), $n(), Yt.current = document.body.style.WebkitUserSelect, document.body.style.WebkitUserSelect = "none", Xt.start(ae, () => { - document.body.style.WebkitUserSelect = Yt.current, xr(Q); + isFocusVisibleRef: Vo, + onBlur: Ls, + onFocus: Fs, + ref: Us + } = ss(), [, zo] = M.useState(!1), Lo = (Q) => { + Ls(Q), Vo.current === !1 && (zo(!1), jo(Q)); + }, Fo = (Q) => { + Et || In(Q.currentTarget), Fs(Q), Vo.current === !0 && (zo(!0), Er(Q)); + }, Uo = (Q) => { + de.current = !0; + const _t = xt.props; + _t.onTouchStart && _t.onTouchStart(Q); + }, Go = Er, Ho = jo, Gs = (Q) => { + Uo(Q), pe.clear(), Te.clear(), Mn(), Ke.current = document.body.style.WebkitUserSelect, document.body.style.WebkitUserSelect = "none", qe.start(at, () => { + document.body.style.WebkitUserSelect = Ke.current, Er(Q); }); - }, xi = (Q) => { - ye.props.onTouchEnd && ye.props.onTouchEnd(Q), $n(), pt.start(z, () => { - In(Q); + }, Hs = (Q) => { + xt.props.onTouchEnd && xt.props.onTouchEnd(Q), Mn(), pe.start(L, () => { + Dn(Q); }); }; M.useEffect(() => { - if (!Ke) + if (!Kt) return; - function Q(Re) { - (Re.key === "Escape" || Re.key === "Esc") && In(Re); + function Q(_t) { + (_t.key === "Escape" || _t.key === "Esc") && Dn(_t); } return document.addEventListener("keydown", Q), () => { document.removeEventListener("keydown", Q); }; - }, [In, Ke]); - const Ni = xt(ye.ref, vi, Pn, n); - !de && de !== 0 && (Ke = !1); - const Nr = M.useRef(), ki = (Q) => { - const Re = ye.props; - Re.onMouseMove && Re.onMouseMove(Q), tn = { + }, [Dn, Kt]); + const Xs = xe(xt.ref, Us, In, n); + !dt && dt !== 0 && (Kt = !1); + const Sr = M.useRef(), Ys = (Q) => { + const _t = xt.props; + _t.onMouseMove && _t.onMouseMove(Q), on = { x: Q.clientX, y: Q.clientY - }, Nr.current && Nr.current.update(); - }, Wt = {}, kr = typeof de == "string"; - N ? (Wt.title = !Ke && kr && !D ? de : null, Wt["aria-describedby"] = Ke ? yr : null) : (Wt["aria-label"] = kr ? de : null, Wt["aria-labelledby"] = Ke && !kr ? yr : null); - const Ae = R({}, Wt, j, ye.props, { - className: bt(j.className, ye.props.className), - onTouchStart: jo, - ref: Ni - }, re ? { - onMouseMove: ki + }, Sr.current && Sr.current.update(); + }, Je = {}, Tr = typeof dt == "string"; + k ? (Je.title = !Kt && Tr && !D ? dt : null, Je["aria-describedby"] = Kt ? kr : null) : (Je["aria-label"] = Tr ? dt : null, Je["aria-labelledby"] = Kt && !Tr ? kr : null); + const Mt = P({}, Je, j, xt.props, { + className: be(j.className, xt.props.className), + onTouchStart: Uo, + ref: Xs + }, rt ? { + onMouseMove: Ys } : {}); - process.env.NODE_ENV !== "production" && (Ae["data-mui-internal-clone-element"] = !0, M.useEffect(() => { - ke && !ke.getAttribute("data-mui-internal-clone-element") && console.error(["MUI: The `children` component of the Tooltip is not forwarding its props correctly.", "Please make sure that props are spread on the same element that the ref is applied to."].join(` + process.env.NODE_ENV !== "production" && (Mt["data-mui-internal-clone-element"] = !0, M.useEffect(() => { + Et && !Et.getAttribute("data-mui-internal-clone-element") && console.error(["MUI: The `children` component of the Tooltip is not forwarding its props correctly.", "Please make sure that props are spread on the same element that the ref is applied to."].join(` `)); - }, [ke])); - const qt = {}; - q || (Ae.onTouchStart = yi, Ae.onTouchEnd = xi), D || (Ae.onMouseOver = Vn(Vo, Ae.onMouseOver), Ae.onMouseLeave = Vn(Lo, Ae.onMouseLeave), Tt || (qt.onMouseOver = Vo, qt.onMouseLeave = Lo)), B || (Ae.onFocus = Vn(Bo, Ae.onFocus), Ae.onBlur = Vn(Mo, Ae.onBlur), Tt || (qt.onFocus = Bo, qt.onBlur = Mo)), process.env.NODE_ENV !== "production" && ye.props.title && console.error(["MUI: You have provided a `title` prop to the child of .", `Remove this title prop \`${ye.props.title}\` or the Tooltip component.`].join(` + }, [Et])); + const Ze = {}; + q || (Mt.onTouchStart = Gs, Mt.onTouchEnd = Hs), D || (Mt.onMouseOver = Fn(Go, Mt.onMouseOver), Mt.onMouseLeave = Fn(Ho, Mt.onMouseLeave), Se || (Ze.onMouseOver = Go, Ze.onMouseLeave = Ho)), B || (Mt.onFocus = Fn(Fo, Mt.onFocus), Mt.onBlur = Fn(Lo, Mt.onBlur), Se || (Ze.onFocus = Fo, Ze.onBlur = Lo)), process.env.NODE_ENV !== "production" && xt.props.title && console.error(["MUI: You have provided a `title` prop to the child of .", `Remove this title prop \`${xt.props.title}\` or the Tooltip component.`].join(` `)); - const Ei = M.useMemo(() => { + const Ws = M.useMemo(() => { var Q; - let Re = [{ + let _t = [{ name: "arrow", - enabled: !!Fe, + enabled: !!Ut, options: { - element: Fe, + element: Ut, padding: 4 } }]; - return (Q = G.popperOptions) != null && Q.modifiers && (Re = Re.concat(G.popperOptions.modifiers)), R({}, G.popperOptions, { - modifiers: Re + return (Q = G.popperOptions) != null && Q.modifiers && (_t = _t.concat(G.popperOptions.modifiers)), P({}, G.popperOptions, { + modifiers: _t }); - }, [Fe, G]), Kt = R({}, _, { - isRtl: ct, - arrow: L, - disableInteractive: Tt, + }, [Ut, G]), Qe = P({}, I, { + isRtl: ce, + arrow: z, + disableInteractive: Se, placement: X, PopperComponentProp: Y, - touch: dt.current - }), Er = Ef(Kt), zo = (r = (o = Z.popper) != null ? o : C.Popper) != null ? r : Tf, Fo = (a = (s = (l = Z.transition) != null ? l : C.Transition) != null ? s : $) != null ? a : Va, Uo = (c = (d = Z.tooltip) != null ? d : C.Tooltip) != null ? c : Cf, Go = (p = (m = Z.arrow) != null ? m : C.Arrow) != null ? p : Sf, Ti = on(zo, R({}, G, (w = K.popper) != null ? w : P.popper, { - className: bt(Er.popper, G == null ? void 0 : G.className, (b = (v = K.popper) != null ? v : P.popper) == null ? void 0 : b.className) - }), Kt), Ci = on(Fo, R({}, xe, (f = K.transition) != null ? f : P.transition), Kt), Si = on(Uo, R({}, (h = K.tooltip) != null ? h : P.tooltip, { - className: bt(Er.tooltip, (E = (A = K.tooltip) != null ? A : P.tooltip) == null ? void 0 : E.className) - }), Kt), Oi = on(Go, R({}, (O = K.arrow) != null ? O : P.arrow, { - className: bt(Er.arrow, (k = (g = K.arrow) != null ? g : P.arrow) == null ? void 0 : k.className) - }), Kt); + touch: de.current + }), Cr = Tm(Qe), Xo = (r = (o = Z.popper) != null ? o : O.Popper) != null ? r : Cm, Yo = (a = (i = (l = Z.transition) != null ? l : O.Transition) != null ? i : A) != null ? a : Ha, Wo = (c = (d = Z.tooltip) != null ? d : O.Tooltip) != null ? c : Om, qo = (p = (m = Z.arrow) != null ? m : O.Arrow) != null ? p : Rm, qs = ln(Xo, P({}, G, (w = K.popper) != null ? w : $.popper, { + className: be(Cr.popper, G == null ? void 0 : G.className, (g = (v = K.popper) != null ? v : $.popper) == null ? void 0 : g.className) + }), Qe), Ks = ln(Yo, P({}, Nt, (f = K.transition) != null ? f : $.transition), Qe), Js = ln(Wo, P({}, (h = K.tooltip) != null ? h : $.tooltip, { + className: be(Cr.tooltip, (E = (_ = K.tooltip) != null ? _ : $.tooltip) == null ? void 0 : E.className) + }), Qe), Zs = ln(qo, P({}, (C = K.arrow) != null ? C : $.arrow, { + className: be(Cr.arrow, (S = (b = K.arrow) != null ? b : $.arrow) == null ? void 0 : S.className) + }), Qe); return /* @__PURE__ */ x(M.Fragment, { - children: [/* @__PURE__ */ M.cloneElement(ye, Ae), /* @__PURE__ */ i(zo, R({ - as: Y ?? ui, + children: [/* @__PURE__ */ M.cloneElement(xt, Mt), /* @__PURE__ */ s(Xo, P({ + as: Y ?? Ds, placement: X, - anchorEl: re ? { + anchorEl: rt ? { getBoundingClientRect: () => ({ - top: tn.y, - left: tn.x, - right: tn.x, - bottom: tn.y, + top: on.y, + left: on.x, + right: on.x, + bottom: on.y, width: 0, height: 0 }) - } : ke, - popperRef: Nr, - open: ke ? Ke : !1, - id: yr, + } : Et, + popperRef: Sr, + open: Et ? Kt : !1, + id: kr, transition: !0 - }, qt, Ti, { - popperOptions: Ei, + }, Ze, qs, { + popperOptions: Ws, children: ({ TransitionProps: Q - }) => /* @__PURE__ */ i(Fo, R({ - timeout: ze.transitions.duration.shorter - }, Q, Ci, { - children: /* @__PURE__ */ x(Uo, R({}, Si, { - children: [de, L ? /* @__PURE__ */ i(Go, R({}, Oi, { - ref: Et + }) => /* @__PURE__ */ s(Yo, P({ + timeout: Ft.transitions.duration.shorter + }, Q, Ks, { + children: /* @__PURE__ */ x(Wo, P({}, Js, { + children: [dt, z ? /* @__PURE__ */ s(qo, P({}, Zs, { + ref: Ee })) : null] })) })) }))] }); }); -process.env.NODE_ENV !== "production" && (wi.propTypes = { +process.env.NODE_ENV !== "production" && (Bs.propTypes = { // ┌────────────────────────────── Warning ──────────────────────────────┐ // │ These PropTypes are generated from the TypeScript type definitions. │ // │ To update them, edit the d.ts file and run `pnpm proptypes`. │ @@ -8443,7 +9163,7 @@ process.env.NODE_ENV !== "production" && (wi.propTypes = { /** * Tooltip reference element. */ - children: $s.isRequired, + children: ns.isRequired, /** * Override or extend the styles applied to the component. */ @@ -8623,30 +9343,30 @@ process.env.NODE_ENV !== "production" && (wi.propTypes = { */ TransitionProps: u.object }); -const Of = wi; -function za(e, t, n) { - return e ? /* @__PURE__ */ i(Ka, { className: `papi-menu-icon-${n ? "leading" : "trailing"}`, children: /* @__PURE__ */ i("img", { src: e, alt: `${n ? "Leading" : "Trailing"} icon for ${t}` }) }) : void 0; +const _m = Bs; +function Ya(t, e, n) { + return t ? /* @__PURE__ */ s(ri, { className: `papi-menu-icon-${n ? "leading" : "trailing"}`, children: /* @__PURE__ */ s("img", { src: t, alt: `${n ? "Leading" : "Trailing"} icon for ${e}` }) }) : void 0; } -function fi(e) { +function js(t) { const { - onClick: t, + onClick: e, label: n, tooltip: r, allowForLeadingIcons: o = !0, iconPathBefore: a = void 0, - iconPathAfter: s = void 0, + iconPathAfter: i = void 0, hasAutoFocus: l = !1, className: c, isDisabled: d = !1, isDense: p = !0, isSubMenuParent: m = !1, hasDisabledGutters: w = !1, - hasDivider: b = !1, + hasDivider: g = !1, focusVisibleClassName: v, id: f, children: h - } = e, E = /* @__PURE__ */ i( - gl, + } = t, E = /* @__PURE__ */ s( + jl, { sx: { lineHeight: 0.8 }, autoFocus: l, @@ -8654,42 +9374,42 @@ function fi(e) { disabled: d, dense: p, disableGutters: w, - divider: b, + divider: g, focusVisibleClassName: v, - onClick: t, + onClick: e, id: f, - children: n ? /* @__PURE__ */ x(st, { children: [ - za(a, n, !0), - /* @__PURE__ */ i(bl, { primary: n, inset: !a && o }), - m ? /* @__PURE__ */ i(Ka, { className: "papi-menu-icon-trailing", children: /* @__PURE__ */ i(qs, {}) }) : za(s, n, !1) + children: n ? /* @__PURE__ */ x(ie, { children: [ + Ya(a, n, !0), + /* @__PURE__ */ s(Vl, { primary: n, inset: !a && o }), + m ? /* @__PURE__ */ s(ri, { className: "papi-menu-icon-trailing", children: /* @__PURE__ */ s(vs, {}) }) : Ya(i, n, !1) ] }) : h } ); - return r ? /* @__PURE__ */ i(Of, { title: r, placement: "right", children: /* @__PURE__ */ i("div", { children: E }) }) : E; + return r ? /* @__PURE__ */ s(_m, { title: r, placement: "right", children: /* @__PURE__ */ s("div", { children: E }) }) : E; } -function mi(e) { - return Object.entries(e.groups).map(([n, r]) => ({ id: n, group: r })); +function Vs(t) { + return Object.entries(t.groups).map(([n, r]) => ({ id: n, group: r })); } -function Rf(e) { - const [t, n] = ue(void 0), { parentMenuItem: r, parentItemProps: o, menuDefinition: a } = e, s = (d) => { +function Pm(t) { + const [e, n] = ut(void 0), { parentMenuItem: r, parentItemProps: o, menuDefinition: a } = t, i = (d) => { n(d.currentTarget); }, l = () => { n(void 0); }, c = () => { - let d = mi(a).filter((p) => "menuItem" in p.group); + let d = Vs(a).filter((p) => "menuItem" in p.group); if (!(r != null && r.id)) throw new Error("A valid parent menu item is required for submenus."); return d = d.filter( (p) => "menuItem" in p.group && p.group.menuItem === r.id - ), /* @__PURE__ */ i(hi, { ...e, includedGroups: d }); + ), /* @__PURE__ */ s(zs, { ...t, includedGroups: d }); }; - return /* @__PURE__ */ x(st, { children: [ - /* @__PURE__ */ i(fi, { onClick: s, ...o, isSubMenuParent: !0 }), - /* @__PURE__ */ i( - vl, + return /* @__PURE__ */ x(ie, { children: [ + /* @__PURE__ */ s(js, { onClick: i, ...o, isSubMenuParent: !0 }), + /* @__PURE__ */ s( + zl, { - anchorEl: t, - open: !!t, + anchorEl: e, + open: !!e, onClose: l, anchorOrigin: { vertical: "top", @@ -8705,26 +9425,26 @@ function Rf(e) { ) ] }); } -const Pf = (e, t) => t.filter((o) => o.group === e).sort((o, a) => (o.order || 0) - (a.order || 0)); -function hi(e) { - const { menuDefinition: t, onClick: n, commandHandler: r, includedGroups: o } = e, { items: a, allowForLeadingIcons: s } = _e(() => { +const $m = (t, e) => e.filter((o) => o.group === t).sort((o, a) => (o.order || 0) - (a.order || 0)); +function zs(t) { + const { menuDefinition: e, onClick: n, commandHandler: r, includedGroups: o } = t, { items: a, allowForLeadingIcons: i } = $t(() => { const p = o && o.length > 0 ? o : ( // We're apparently laying out a single-column menu (presumably a context menu). In this // case, all groups should be included except ones that belong to a submenu. - mi(t).filter((v) => !("menuItem" in v.group)) + Vs(e).filter((v) => !("menuItem" in v.group)) ), m = Object.values(p).sort( (v, f) => (v.group.order || 0) - (f.group.order || 0) ), w = []; m.forEach((v) => { - Pf(v.id, t.items).forEach( + $m(v.id, e.items).forEach( (f) => w.push({ item: f, isLastItemInGroup: !1 }) ), w.length > 0 && (w[w.length - 1].isLastItemInGroup = !0); }), w.length > 0 && (w[w.length - 1].isLastItemInGroup = !1); - const b = w.some( + const g = w.some( (v) => "iconPathBefore" in v.item && v.item.iconPathBefore ); - return { items: w, allowForLeadingIcons: b }; - }, [o, t]), l = ({ item: p, isLastItemInGroup: m }) => ({ + return { items: w, allowForLeadingIcons: g }; + }, [o, e]), l = ({ item: p, isLastItemInGroup: m }) => ({ className: "papi-menu-item", label: p.label, tooltip: p.tooltip, @@ -8732,56 +9452,56 @@ function hi(e) { iconPathAfter: "iconPathAfter" in p ? p.iconPathAfter : void 0, hasDivider: m, // Set hasDivider to true for the last item in a group - allowForLeadingIcons: s + allowForLeadingIcons: i }), [c] = a; if (!c) - return /* @__PURE__ */ i("div", {}); + return /* @__PURE__ */ s("div", {}); const d = c.item.group; - return /* @__PURE__ */ i("div", { role: "menu", "aria-label": d, children: a.map((p, m) => { - const { item: w } = p, b = l(p); + return /* @__PURE__ */ s("div", { role: "menu", "aria-label": d, children: a.map((p, m) => { + const { item: w } = p, g = l(p); if ("command" in w) { const v = w.group + m; - return /* @__PURE__ */ i( - fi, + return /* @__PURE__ */ s( + js, { onClick: (f) => { n == null || n(f), r(w); }, - ...b + ...g }, v ); } - return /* @__PURE__ */ i( - Rf, + return /* @__PURE__ */ s( + Pm, { parentMenuItem: w, - parentItemProps: b, - ...e + parentItemProps: g, + ...t }, d + w.id ); }) }, d); } -function _f(e) { - const { menuDefinition: t, columnId: n } = e; - let a = Object.entries(t.groups).map(([s, l]) => ({ id: s, group: l })).filter((s) => "column" in s.group); - return n && "columns" in t && // Without this type assertion, TS doesn't know what columns is. +function Im(t) { + const { menuDefinition: e, columnId: n } = t; + let a = Object.entries(e.groups).map(([i, l]) => ({ id: i, group: l })).filter((i) => "column" in i.group); + return n && "columns" in e && // Without this type assertion, TS doesn't know what columns is. // eslint-disable-next-line no-type-assertion/no-type-assertion - t.columns[n] && (a = a.filter( - (s) => "column" in s.group && s.group.column === n - )), /* @__PURE__ */ i(hi, { ...e, includedGroups: a }); + e.columns[n] && (a = a.filter( + (i) => "column" in i.group && i.group.column === n + )), /* @__PURE__ */ s(zs, { ...t, includedGroups: a }); } -function $f({ - commandHandler: e, - menuDefinition: t, +function Am({ + commandHandler: t, + menuDefinition: e, id: n, metadata: r, onClick: o, className: a }) { return /* @__PURE__ */ x( - Ja, + oi, { id: n, item: !0, @@ -8790,12 +9510,12 @@ function $f({ "aria-label": n, className: `papi-menu-column ${a ?? ""}`, children: [ - /* @__PURE__ */ i("h3", { "aria-label": r.label, className: `papi-menu-column-header ${a ?? ""}`, children: r.label }), - /* @__PURE__ */ i(yl, { id: n, dense: !0, className: a ?? "", children: /* @__PURE__ */ i( - _f, + /* @__PURE__ */ s("h3", { "aria-label": r.label, className: `papi-menu-column-header ${a ?? ""}`, children: r.label }), + /* @__PURE__ */ s(Ll, { id: n, dense: !0, className: a ?? "", children: /* @__PURE__ */ s( + Im, { - commandHandler: e, - menuDefinition: t, + commandHandler: t, + menuDefinition: e, columnId: n, onClick: o } @@ -8804,112 +9524,112 @@ function $f({ } ); } -function If({ - commandHandler: e, - className: t, +function Mm({ + commandHandler: t, + className: e, multiColumnMenu: n, id: r }) { - const { columns: o } = n, a = _e(() => { - const s = /* @__PURE__ */ new Map(); + const { columns: o } = n, a = $t(() => { + const i = /* @__PURE__ */ new Map(); return Object.getOwnPropertyNames(o).forEach((l) => { if (l === "isExtensible") return; const c = l, d = o[c]; - typeof d == "object" && typeof d.order == "number" && !Number.isNaN(d.order) ? s.set(d.order, { id: c, metadata: d }) : console.warn( + typeof d == "object" && typeof d.order == "number" && !Number.isNaN(d.order) ? i.set(d.order, { id: c, metadata: d }) : console.warn( `Property ${l} (${typeof d}) on menu ${r} is not a valid column and is being ignored. This might indicate data corruption` ); - }), Array.from(s.values()).sort((l, c) => (l.metadata.order || 0) - (c.metadata.order || 0)); + }), Array.from(i.values()).sort((l, c) => (l.metadata.order || 0) - (c.metadata.order || 0)); }, [o, r]); - return /* @__PURE__ */ i( - Ja, + return /* @__PURE__ */ s( + oi, { container: !0, spacing: 0, - className: `papi-multi-column-menu ${t ?? ""}`, + className: `papi-multi-column-menu ${e ?? ""}`, columns: a.length, role: "menu", "aria-label": "GridMenu", id: r, - children: a.map((s, l) => /* @__PURE__ */ i( - $f, + children: a.map((i, l) => /* @__PURE__ */ s( + Am, { - commandHandler: e, + commandHandler: t, menuDefinition: n, - ...s, - className: t + ...i, + className: e }, l )) } ); } -function Af(e) { +function Dm(t) { return { preserveValue: !0, - ...e + ...t }; } -const eo = (e, t, n = {}) => { - const r = gt(t); - r.current = t; - const o = gt(n); - o.current = Af(o.current); - const [a, s] = ue(() => r.current), [l, c] = ue(!0); - return at(() => { +const oo = (t, e, n = {}) => { + const r = ge(e); + r.current = e; + const o = ge(n); + o.current = Dm(o.current); + const [a, i] = ut(() => r.current), [l, c] = ut(!0); + return ae(() => { let d = !0; - return c(!!e), (async () => { - if (e) { - const p = await e(); - d && (s(() => p), c(!1)); + return c(!!t), (async () => { + if (t) { + const p = await t(); + d && (i(() => p), c(!1)); } })(), () => { - d = !1, o.current.preserveValue || s(() => r.current); + d = !1, o.current.preserveValue || i(() => r.current); }; - }, [e]), [a, l]; -}, Df = Ws(/* @__PURE__ */ i("path", { + }, [t]), [a, l]; +}, Bm = bs(/* @__PURE__ */ s("path", { d: "M3 18h18v-2H3zm0-5h18v-2H3zm0-7v2h18V6z" }), "Menu"); -function Mf({ - menuProvider: e, - normalMenu: t, +function jm({ + menuProvider: t, + normalMenu: e, fullMenu: n, commandHandler: r, containerRef: o, className: a, - ariaLabelPrefix: s, + ariaLabelPrefix: i, children: l }) { - const [c, d] = ue(!1), [p, m] = ue(!1), w = Me(() => { + const [c, d] = ut(!1), [p, m] = ut(!1), w = Bt(() => { c && d(!1), m(!1); - }, [c]), b = Me((k) => { - k.stopPropagation(), d((g) => { - const _ = !g; - return _ && k.shiftKey ? m(!0) : _ || m(!1), _; + }, [c]), g = Bt((S) => { + S.stopPropagation(), d((b) => { + const I = !b; + return I && S.shiftKey ? m(!0) : I || m(!1), I; }); - }, []), v = Me( - (k) => (w(), r(k)), + }, []), v = Bt( + (S) => (w(), r(S)), [r, w] - ), [f, h] = ue({ top: 1, left: 1 }); - at(() => { + ), [f, h] = ut({ top: 1, left: 1 }); + ae(() => { if (c) { - const k = o == null ? void 0 : o.current; - if (k) { - const g = k.getBoundingClientRect(), _ = window.scrollY, L = window.scrollX, H = g.top + _ + k.clientHeight, C = g.left + L; - h({ top: H, left: C }); + const S = o == null ? void 0 : o.current; + if (S) { + const b = S.getBoundingClientRect(), I = window.scrollY, z = window.scrollX, H = b.top + I + S.clientHeight, O = b.left + z; + h({ top: H, left: O }); } } }, [c, o]); - const [E] = eo( - Me(async () => (e == null ? void 0 : e(!1)) ?? t, [e, t, c]), - t - ), [A] = eo( - Me(async () => (e == null ? void 0 : e(!0)) ?? n ?? E, [e, n, E, c]), + const [E] = oo( + Bt(async () => (t == null ? void 0 : t(!1)) ?? e, [t, e, c]), + e + ), [_] = oo( + Bt(async () => (t == null ? void 0 : t(!0)) ?? n ?? E, [t, n, E, c]), n ?? E - ), O = p && A ? A : E; - return /* @__PURE__ */ x(st, { children: [ - /* @__PURE__ */ i( - Za, + ), C = p && _ ? _ : E; + return /* @__PURE__ */ x(ie, { children: [ + /* @__PURE__ */ s( + ai, { sx: { paddingTop: 0, @@ -8918,13 +9638,13 @@ function Mf({ edge: "start", className: `papi-menuButton ${a ?? ""}`, color: "inherit", - "aria-label": `${s ?? ""} menu button`, - onClick: b, - children: l ?? /* @__PURE__ */ i(Df, {}) + "aria-label": `${i ?? ""} menu button`, + onClick: g, + children: l ?? /* @__PURE__ */ s(Bm, {}) } ), - /* @__PURE__ */ i( - xl, + /* @__PURE__ */ s( + Fl, { className: `papi-menu-drawer ${a ?? ""}`, anchor: "left", @@ -8938,122 +9658,122 @@ function Mf({ left: f.left } }, - children: O ? /* @__PURE__ */ i( - If, + children: C ? /* @__PURE__ */ s( + Mm, { className: a, - id: `${s ?? ""} main menu`, + id: `${i ?? ""} main menu`, commandHandler: v, - multiColumnMenu: O + multiColumnMenu: C } ) : void 0 } ) ] }); } -function Bm({ - id: e, - label: t, +function Mh({ + id: t, + label: e, isDisabled: n = !1, tooltip: r, isTooltipSuppressed: o = !1, adjustMarginToAlignToEdge: a = !1, - size: s = "medium", + size: i = "medium", className: l, onClick: c, children: d }) { - return /* @__PURE__ */ i( - Za, + return /* @__PURE__ */ s( + ai, { - id: e, + id: t, disabled: n, edge: a, - size: s, - "aria-label": t, - title: o ? void 0 : r ?? t, + size: i, + "aria-label": e, + title: o ? void 0 : r ?? e, className: `papi-icon-button ${l ?? ""}`, onClick: c, children: d } ); } -const Rn = Kn(({ className: e, ...t }, n) => /* @__PURE__ */ i(Ki, { size: 35, className: T("tw-animate-spin", e), ...t, ref: n })); -Rn.displayName = "Spinner"; -function jm({ - id: e, - isDisabled: t = !1, +const $n = Qn(({ className: t, ...e }, n) => /* @__PURE__ */ s(yl, { size: 35, className: N("tw-animate-spin", t), ...e, ref: n })); +$n.displayName = "Spinner"; +function Dh({ + id: t, + isDisabled: e = !1, hasError: n = !1, isFullWidth: r = !1, helperText: o, label: a, - placeholder: s, + placeholder: i, isRequired: l = !1, className: c, defaultValue: d, value: p, onChange: m, onFocus: w, - onBlur: b + onBlur: g }) { - return /* @__PURE__ */ x("div", { className: T("tw-inline-grid tw-items-center tw-gap-1.5", { "tw-w-full": r }), children: [ - /* @__PURE__ */ i( - He, + return /* @__PURE__ */ x("div", { className: N("tw-inline-grid tw-items-center tw-gap-1.5", { "tw-w-full": r }), children: [ + /* @__PURE__ */ s( + Xt, { - htmlFor: e, - className: T({ + htmlFor: t, + className: N({ "tw-text-red-600": n, "tw-hidden": !a }), children: `${a}${l ? "*" : ""}` } ), - /* @__PURE__ */ i( - xn, + /* @__PURE__ */ s( + Ye, { - id: e, - disabled: t, - placeholder: s, + id: t, + disabled: e, + placeholder: i, required: l, - className: T(c, { "tw-border-red-600": n }), + className: N(c, { "tw-border-red-600": n }), defaultValue: d, value: p, onChange: m, onFocus: w, - onBlur: b + onBlur: g } ), - /* @__PURE__ */ i("p", { className: T({ "tw-hidden": !o }), children: o }) + /* @__PURE__ */ s("p", { className: N({ "tw-hidden": !o }), children: o }) ] }); } -function Vm({ - menuProvider: e, - commandHandler: t, +function Bh({ + menuProvider: t, + commandHandler: e, className: n, id: r, children: o }) { - const a = gt(void 0); - return /* @__PURE__ */ i("div", { ref: a, style: { position: "relative" }, children: /* @__PURE__ */ i(Nl, { position: "static", id: r, children: /* @__PURE__ */ x( - kl, + const a = ge(void 0); + return /* @__PURE__ */ s("div", { ref: a, style: { position: "relative" }, children: /* @__PURE__ */ s(Ul, { position: "static", id: r, children: /* @__PURE__ */ x( + Gl, { - className: T("tw-bg-muted tw-text-muted-foreground", n), + className: N("tw-bg-muted tw-text-muted-foreground", n), variant: "dense", children: [ - e ? /* @__PURE__ */ i( - Mf, + t ? /* @__PURE__ */ s( + jm, { - commandHandler: t, + commandHandler: e, containerRef: a, - menuProvider: e + menuProvider: t } ) : void 0, - o ? /* @__PURE__ */ i("div", { className: "papi-toolbar-children", children: o }) : void 0 + o ? /* @__PURE__ */ s("div", { className: "papi-toolbar-children", children: o }) : void 0 ] } ) }) }); } -const Bf = Qn( +const Vm = Xe( "tw-relative tw-w-full tw-rounded-lg tw-border tw-p-4 [&>svg~*]:tw-pl-7 [&>svg+div]:tw-translate-y-[-3px] [&>svg]:tw-absolute [&>svg]:tw-left-4 [&>svg]:tw-top-4 [&>svg]:tw-text-foreground", { variants: { @@ -9066,85 +9786,28 @@ const Bf = Qn( variant: "default" } } -), jf = I.forwardRef(({ className: e, variant: t, ...n }, r) => /* @__PURE__ */ i("div", { ref: r, role: "alert", className: T(Bf({ variant: t }), e), ...n })); -jf.displayName = "Alert"; -const Vf = I.forwardRef( - ({ className: e, ...t }, n) => /* @__PURE__ */ x( +), zm = T.forwardRef(({ className: t, variant: e, ...n }, r) => /* @__PURE__ */ s("div", { ref: r, role: "alert", className: N(Vm({ variant: e }), t), ...n })); +zm.displayName = "Alert"; +const Lm = T.forwardRef( + ({ className: t, ...e }, n) => /* @__PURE__ */ x( "h5", { ref: n, - className: T("tw-mb-1 tw-font-medium tw-leading-none tw-tracking-tight", e), - ...t, + className: N("tw-mb-1 tw-font-medium tw-leading-none tw-tracking-tight", t), + ...e, children: [ - t.children, + e.children, " " ] } ) ); -Vf.displayName = "AlertTitle"; -const Lf = I.forwardRef(({ className: e, ...t }, n) => /* @__PURE__ */ i("div", { ref: n, className: T("tw-text-sm [&_p]:tw-leading-relaxed", e), ...t })); -Lf.displayName = "AlertDescription"; -const zf = I.forwardRef( - ({ className: e, ...t }, n) => /* @__PURE__ */ i( - "div", - { - ref: n, - className: T( - "pr-twp tw-rounded-lg tw-border tw-bg-card tw-text-card-foreground tw-shadow-sm", - e - ), - ...t - } - ) -); -zf.displayName = "Card"; -const Ff = I.forwardRef( - ({ className: e, ...t }, n) => /* @__PURE__ */ i( - "div", - { - ref: n, - className: T("pr-twp tw-flex tw-flex-col tw-space-y-1.5 tw-p-6", e), - ...t - } - ) -); -Ff.displayName = "CardHeader"; -const Uf = I.forwardRef( - ({ className: e, ...t }, n) => /* @__PURE__ */ i( - "h3", - { - ref: n, - className: T( - "pr-twp tw-text-2xl tw-font-semibold tw-leading-none tw-tracking-tight", - e - ), - ...t, - children: t.children - } - ) -); -Uf.displayName = "CardTitle"; -const Gf = I.forwardRef(({ className: e, ...t }, n) => /* @__PURE__ */ i("p", { ref: n, className: T("pr-twp tw-text-sm tw-text-muted-foreground", e), ...t })); -Gf.displayName = "CardDescription"; -const Hf = I.forwardRef( - ({ className: e, ...t }, n) => /* @__PURE__ */ i("div", { ref: n, className: T("pr-twp tw-p-6 tw-pt-0", e), ...t }) -); -Hf.displayName = "CardContent"; -const Xf = I.forwardRef( - ({ className: e, ...t }, n) => /* @__PURE__ */ i( - "div", - { - ref: n, - className: T("pr-twp tw-flex tw-items-center tw-p-6 tw-pt-0", e), - ...t - } - ) -); -Xf.displayName = "CardFooter"; -function Lm({ ...e }) { - return /* @__PURE__ */ i( - Tl, +Lm.displayName = "AlertTitle"; +const Fm = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s("div", { ref: n, className: N("tw-text-sm [&_p]:tw-leading-relaxed", t), ...e })); +Fm.displayName = "AlertDescription"; +function jh({ ...t }) { + return /* @__PURE__ */ s( + ql, { className: "tw-toaster tw-group", toastOptions: { @@ -9155,193 +9818,193 @@ function Lm({ ...e }) { cancelButton: "group-[.toast]:bg-muted group-[.toast]:text-muted-foreground" } }, - ...e + ...t } ); } -const Yf = I.forwardRef(({ className: e, ...t }, n) => /* @__PURE__ */ x( - nn.Root, +const Um = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ x( + an.Root, { ref: n, - className: T( + className: N( "pr-twp tw-relative tw-flex tw-w-full tw-touch-none tw-select-none tw-items-center", - e + t ), - ...t, + ...e, children: [ - /* @__PURE__ */ i(nn.Track, { className: "tw-relative tw-h-2 tw-w-full tw-grow tw-overflow-hidden tw-rounded-full tw-bg-secondary", children: /* @__PURE__ */ i(nn.Range, { className: "tw-absolute tw-h-full tw-bg-primary" }) }), - /* @__PURE__ */ i(nn.Thumb, { className: "tw-block tw-h-5 tw-w-5 tw-rounded-full tw-border-2 tw-border-primary tw-bg-background tw-ring-offset-background tw-transition-colors focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50" }) + /* @__PURE__ */ s(an.Track, { className: "tw-relative tw-h-2 tw-w-full tw-grow tw-overflow-hidden tw-rounded-full tw-bg-secondary", children: /* @__PURE__ */ s(an.Range, { className: "tw-absolute tw-h-full tw-bg-primary" }) }), + /* @__PURE__ */ s(an.Thumb, { className: "tw-block tw-h-5 tw-w-5 tw-rounded-full tw-border-2 tw-border-primary tw-bg-background tw-ring-offset-background tw-transition-colors focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50" }) ] } )); -Yf.displayName = nn.Root.displayName; -const Wf = I.forwardRef(({ className: e, ...t }, n) => /* @__PURE__ */ i( - Ur.Root, +Um.displayName = an.Root.displayName; +const Gm = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( + Yr.Root, { - className: T( + className: N( "tw-peer pr-twp tw-inline-flex tw-h-6 tw-w-11 tw-shrink-0 tw-cursor-pointer tw-items-center tw-rounded-full tw-border-2 tw-border-transparent tw-transition-colors focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 focus-visible:tw-ring-offset-background disabled:tw-cursor-not-allowed disabled:tw-opacity-50 data-[state=checked]:tw-bg-primary data-[state=unchecked]:tw-bg-input", - e + t ), - ...t, + ...e, ref: n, - children: /* @__PURE__ */ i( - Ur.Thumb, + children: /* @__PURE__ */ s( + Yr.Thumb, { - className: T( + className: N( "pr-twp tw-pointer-events-none tw-block tw-h-5 tw-w-5 tw-rounded-full tw-bg-background tw-shadow-lg tw-ring-0 tw-transition-transform data-[state=checked]:tw-translate-x-5 data-[state=unchecked]:tw-translate-x-0" ) } ) } )); -Wf.displayName = Ur.Root.displayName; -const zm = Oe.Root, qf = I.forwardRef(({ className: e, ...t }, n) => /* @__PURE__ */ i( - Oe.List, +Gm.displayName = Yr.Root.displayName; +const Vh = Rt.Root, Hm = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( + Rt.List, { ref: n, - className: T( + className: N( "tw-inline-flex tw-h-10 tw-items-center tw-justify-center tw-rounded-md tw-bg-muted tw-p-1 tw-text-muted-foreground", - e + t ), - ...t + ...e } )); -qf.displayName = Oe.List.displayName; -const Kf = I.forwardRef(({ className: e, ...t }, n) => /* @__PURE__ */ i( - Oe.Trigger, +Hm.displayName = Rt.List.displayName; +const Xm = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( + Rt.Trigger, { ref: n, - className: T( + className: N( "tw-inline-flex tw-items-center tw-justify-center tw-whitespace-nowrap tw-rounded-sm tw-px-3 tw-py-1.5 tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-all hover:tw-text-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50 data-[state=active]:tw-bg-background data-[state=active]:tw-text-foreground data-[state=active]:tw-shadow-sm", - e + t ), - ...t + ...e } )); -Kf.displayName = Oe.Trigger.displayName; -const Jf = I.forwardRef(({ className: e, ...t }, n) => /* @__PURE__ */ i( - Oe.Content, +Xm.displayName = Rt.Trigger.displayName; +const Ym = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( + Rt.Content, { ref: n, - className: T( + className: N( "tw-mt-2 tw-ring-offset-background focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2", - e + t ), - ...t + ...e } )); -Jf.displayName = Oe.Content.displayName; -function Fm({ - isInstalling: e, - handleClick: t, +Ym.displayName = Rt.Content.displayName; +function zh({ + isInstalling: t, + handleClick: e, buttonText: n, className: r, ...o }) { - return /* @__PURE__ */ i( - be, + return /* @__PURE__ */ s( + gt, { - className: T( + className: N( "tw-h-8 tw-rounded-md tw-text-white tw-transition tw-duration-300 tw-ease-in-out hover:tw-bg-blue-700", { - "tw-cursor-not-allowed tw-bg-blue-700": e, - "tw-bg-blue-600": !e, + "tw-cursor-not-allowed tw-bg-blue-700": t, + "tw-bg-blue-600": !t, "tw-bg-white tw-text-blue-600 hover:tw-text-white": !n, "tw-w-20": n }, r ), - onClick: t, + onClick: e, ...o, - children: e ? /* @__PURE__ */ i(Rn, { size: 15 }) : /* @__PURE__ */ x(st, { children: [ - /* @__PURE__ */ i(Ji, { size: 25, className: T("tw-h-4 tw-w-4", { "tw-mr-1": n }) }), + children: t ? /* @__PURE__ */ s($n, { size: 15 }) : /* @__PURE__ */ x(ie, { children: [ + /* @__PURE__ */ s(xl, { size: 25, className: N("tw-h-4 tw-w-4", { "tw-mr-1": n }) }), n ] }) } ); } -function Um({ - isEnabling: e, - handleClick: t, +function Lh({ + isEnabling: t, + handleClick: e, className: n, ...r }) { - return /* @__PURE__ */ i( - be, + return /* @__PURE__ */ s( + gt, { - className: T( + className: N( "tw-h-8 tw-rounded-md tw-bg-blue-600 tw-px-4 tw-text-white tw-transition tw-duration-300 tw-ease-in-out hover:tw-bg-blue-700", { - "tw-cursor-not-allowed tw-bg-blue-700": e + "tw-cursor-not-allowed tw-bg-blue-700": t }, n ), - onClick: t, + onClick: e, ...r, - children: e ? /* @__PURE__ */ x(st, { children: [ - /* @__PURE__ */ i(Rn, { size: 15, className: "tw-mr-1 tw-text-white" }), + children: t ? /* @__PURE__ */ x(ie, { children: [ + /* @__PURE__ */ s($n, { size: 15, className: "tw-mr-1 tw-text-white" }), "Enabling..." ] }) : "Enable" } ); } -function Gm({ - isDisabling: e, - handleClick: t, +function Fh({ + isDisabling: t, + handleClick: e, className: n, ...r }) { - return /* @__PURE__ */ i( - be, + return /* @__PURE__ */ s( + gt, { - className: T( + className: N( "tw-h-8 tw-rounded-md tw-bg-gray-300 tw-text-black tw-transition tw-duration-300 tw-ease-in-out hover:tw-bg-gray-400", { - "tw-cursor-not-allowed tw-bg-gray-400": e + "tw-cursor-not-allowed tw-bg-gray-400": t }, n ), - onClick: t, + onClick: e, ...r, - children: e ? /* @__PURE__ */ x(st, { children: [ - /* @__PURE__ */ i(Rn, { size: 15, className: "tw-mr-1 tw-text-black" }), + children: t ? /* @__PURE__ */ x(ie, { children: [ + /* @__PURE__ */ s($n, { size: 15, className: "tw-mr-1 tw-text-black" }), "Disabling..." ] }) : "Disable" } ); } -function Hm({ - isUpdating: e, - handleClick: t, +function Uh({ + isUpdating: t, + handleClick: e, className: n, ...r }) { - return /* @__PURE__ */ i( - be, + return /* @__PURE__ */ s( + gt, { - className: T( + className: N( "tw-h-8 tw-rounded-md tw-bg-blue-600 tw-px-4 tw-text-white tw-transition tw-duration-300 tw-ease-in-out hover:tw-bg-blue-700 hover:tw-text-white", { - "tw-cursor-not-allowed tw-bg-blue-700": e + "tw-cursor-not-allowed tw-bg-blue-700": t }, n ), - onClick: t, + onClick: e, ...r, - children: e ? /* @__PURE__ */ x(st, { children: [ - /* @__PURE__ */ i(Rn, { size: 15, className: "tw-mr-1 tw-text-white" }), + children: t ? /* @__PURE__ */ x(ie, { children: [ + /* @__PURE__ */ s($n, { size: 15, className: "tw-mr-1 tw-text-white" }), "Updating..." ] }) : "Update" } ); } -function Xm({ - id: e, - markdown: t, +function Gh({ + id: t, + markdown: e, className: n, anchorTarget: r }) { - const o = _e( + const o = $t( () => ({ overrides: { a: { @@ -9353,19 +10016,19 @@ function Xm({ }), [r] ); - return /* @__PURE__ */ i("div", { id: e, className: T("pr-twp tw-prose", n), children: /* @__PURE__ */ i(Cl, { options: o, children: t }) }); + return /* @__PURE__ */ s("div", { id: t, className: N("pr-twp tw-prose", n), children: /* @__PURE__ */ s(Kl, { options: o, children: e }) }); } -const Zf = Kn((e, t) => /* @__PURE__ */ x( - be, +const Wm = Qn((t, e) => /* @__PURE__ */ x( + gt, { - ref: t, + ref: e, className: "tw-rounded-md tw-border tw-border-dashed tw-border-gray-400 tw-bg-white tw-px-4 tw-py-2 tw-text-black tw-transition tw-duration-300 tw-ease-in-out hover:tw-border-blue-600 hover:tw-bg-white hover:tw-text-blue-600", - ...e, + ...t, children: [ - /* @__PURE__ */ i(Zi, { size: 16, className: "tw-mr-2 tw-h-4 tw-w-4 tw-text-gray-700 hover:tw-text-blue-600" }), + /* @__PURE__ */ s(Nl, { size: 16, className: "tw-mr-2 tw-h-4 tw-w-4 tw-text-gray-700 hover:tw-text-blue-600" }), "Filter", - /* @__PURE__ */ i( - Zn, + /* @__PURE__ */ s( + er, { size: 16, className: "tw-ml-2 tw-h-4 tw-w-4 tw-text-gray-700 hover:tw-text-blue-600" @@ -9374,54 +10037,54 @@ const Zf = Kn((e, t) => /* @__PURE__ */ x( ] } )); -var Qf = /* @__PURE__ */ ((e) => (e[e.Check = 0] = "Check", e[e.Radio = 1] = "Radio", e))(Qf || {}); -function Ym({ id: e, groups: t }) { - return /* @__PURE__ */ i("div", { id: e, children: /* @__PURE__ */ x(ao, { children: [ - /* @__PURE__ */ i(as, { asChild: !0, children: /* @__PURE__ */ i(Zf, {}) }), - /* @__PURE__ */ i(tr, { children: t.map((n) => /* @__PURE__ */ x("div", { children: [ - /* @__PURE__ */ i(Nn, { children: n.label }), - /* @__PURE__ */ i(zl, { children: n.items.map((r) => /* @__PURE__ */ i("div", { children: r.itemType === 0 ? /* @__PURE__ */ i(so, { onClick: r.onClick, children: r.label }) : /* @__PURE__ */ i(is, { onClick: r.onClick, value: r.label, children: r.label }) }, r.label)) }), - /* @__PURE__ */ i(nr, {}) +var qm = /* @__PURE__ */ ((t) => (t[t.Check = 0] = "Check", t[t.Radio = 1] = "Radio", t))(qm || {}); +function Hh({ id: t, groups: e }) { + return /* @__PURE__ */ s("div", { id: t, children: /* @__PURE__ */ x(co, { children: [ + /* @__PURE__ */ s(ui, { asChild: !0, children: /* @__PURE__ */ s(Wm, {}) }), + /* @__PURE__ */ s(rr, { children: e.map((n) => /* @__PURE__ */ x("div", { children: [ + /* @__PURE__ */ s(Sn, { children: n.label }), + /* @__PURE__ */ s(pc, { children: n.items.map((r) => /* @__PURE__ */ s("div", { children: r.itemType === 0 ? /* @__PURE__ */ s(po, { onClick: r.onClick, children: r.label }) : /* @__PURE__ */ s(fi, { onClick: r.onClick, value: r.label, children: r.label }) }, r.label)) }), + /* @__PURE__ */ s(or, {}) ] }, n.label)) }) ] }) }); } -function Wm({ id: e, message: t }) { - return /* @__PURE__ */ i("div", { id: e, className: "tw-mb-20 tw-mt-20 tw-flex tw-items-center tw-justify-center", children: /* @__PURE__ */ i("div", { className: "tw-w-3/4 tw-rounded-lg tw-bg-gray-100 tw-p-8 tw-text-center", children: /* @__PURE__ */ i("p", { className: "tw-text-lg tw-text-gray-800", children: t }) }) }); +function Xh({ id: t, message: e }) { + return /* @__PURE__ */ s("div", { id: t, className: "tw-mb-20 tw-mt-20 tw-flex tw-items-center tw-justify-center", children: /* @__PURE__ */ s("div", { className: "tw-w-3/4 tw-rounded-lg tw-bg-gray-100 tw-p-8 tw-text-center", children: /* @__PURE__ */ s("p", { className: "tw-text-lg tw-text-gray-800", children: e }) }) }); } -function qm({ - id: e, - category: t, +function Yh({ + id: t, + category: e, downloads: n, languages: r, moreInfoUrl: o }) { - const a = new il("en", { + const a = new Pl("en", { notation: "compact", compactDisplay: "short" - }).format(Object.values(n).reduce((l, c) => l + c, 0)), s = () => { + }).format(Object.values(n).reduce((l, c) => l + c, 0)), i = () => { window.scrollTo(0, document.body.scrollHeight); }; return /* @__PURE__ */ x( "div", { - id: e, + id: t, className: "tw-flex tw-flex-wrap tw-items-start tw-space-x-4 tw-border-b tw-border-t tw-bg-white tw-pb-4 tw-pt-4", children: [ /* @__PURE__ */ x("div", { className: "tw-flex tw-flex-col tw-items-center", children: [ - /* @__PURE__ */ i("div", { className: "tw-flex tw-items-center tw-rounded-md tw-bg-gray-100 tw-px-2 tw-py-1", children: /* @__PURE__ */ i("span", { className: "tw-text-xs tw-font-semibold tw-text-gray-700", children: t }) }), - /* @__PURE__ */ i("span", { className: "tw-text-xs tw-text-gray-500", children: "CATEGORY" }) + /* @__PURE__ */ s("div", { className: "tw-flex tw-items-center tw-rounded-md tw-bg-gray-100 tw-px-2 tw-py-1", children: /* @__PURE__ */ s("span", { className: "tw-text-xs tw-font-semibold tw-text-gray-700", children: e }) }), + /* @__PURE__ */ s("span", { className: "tw-text-xs tw-text-gray-500", children: "CATEGORY" }) ] }), - /* @__PURE__ */ i("div", { className: "tw-mx-2 tw-h-10 tw-border-l tw-border-gray-300" }), + /* @__PURE__ */ s("div", { className: "tw-mx-2 tw-h-10 tw-border-l tw-border-gray-300" }), /* @__PURE__ */ x("div", { className: "tw-flex tw-flex-col tw-items-center", children: [ /* @__PURE__ */ x("div", { className: "tw-flex tw-items-center tw-rounded-md tw-bg-gray-100 tw-px-2 tw-py-1", children: [ - /* @__PURE__ */ i(Qi, { className: "tw-mr-1 tw-h-4 tw-w-4" }), - /* @__PURE__ */ i("span", { className: "tw-text-xs tw-font-semibold tw-text-gray-700", children: a }) + /* @__PURE__ */ s(kl, { className: "tw-mr-1 tw-h-4 tw-w-4" }), + /* @__PURE__ */ s("span", { className: "tw-text-xs tw-font-semibold tw-text-gray-700", children: a }) ] }), - /* @__PURE__ */ i("span", { className: "tw-text-xs tw-text-gray-500", children: "USERS" }) + /* @__PURE__ */ s("span", { className: "tw-text-xs tw-text-gray-500", children: "USERS" }) ] }), - /* @__PURE__ */ i("div", { className: "tw-mx-2 tw-h-10 tw-border-l tw-border-gray-300" }), + /* @__PURE__ */ s("div", { className: "tw-mx-2 tw-h-10 tw-border-l tw-border-gray-300" }), /* @__PURE__ */ x("div", { className: "tw-flex tw-flex-col tw-items-center", children: [ - /* @__PURE__ */ i("div", { className: "tw-flex tw-items-center", children: r.slice(0, 3).map((l) => /* @__PURE__ */ i( + /* @__PURE__ */ s("div", { className: "tw-flex tw-items-center", children: r.slice(0, 3).map((l) => /* @__PURE__ */ s( "span", { className: "tw-ml-1 tw-rounded-md tw-bg-gray-100 tw-px-2 tw-py-1 tw-text-xs tw-font-semibold tw-text-gray-700", @@ -9433,7 +10096,7 @@ function qm({ "button", { type: "button", - onClick: () => s(), + onClick: () => i(), className: "tw-text-xs tw-text-gray-500 tw-underline", children: [ "+", @@ -9443,7 +10106,7 @@ function qm({ } ) ] }), - /* @__PURE__ */ i("div", { className: "tw-mx-2 tw-h-10 tw-border-l tw-border-gray-300" }), + /* @__PURE__ */ s("div", { className: "tw-mx-2 tw-h-10 tw-border-l tw-border-gray-300" }), /* @__PURE__ */ x("div", { className: "tw-ml-auto tw-flex tw-flex-col tw-space-y-2", children: [ /* @__PURE__ */ x( "a", @@ -9454,7 +10117,7 @@ function qm({ className: "tw-flex tw-items-center tw-text-xs tw-font-semibold tw-text-gray-500 tw-underline", children: [ "Website", - /* @__PURE__ */ i(el, { className: "tw-ml-1 tw-inline tw-h-4 tw-w-4" }) + /* @__PURE__ */ s(El, { className: "tw-ml-1 tw-inline tw-h-4 tw-w-4" }) ] } ), @@ -9467,7 +10130,7 @@ function qm({ className: "tw-flex tw-items-center tw-text-xs tw-font-semibold tw-text-gray-500 tw-underline", children: [ "Support", - /* @__PURE__ */ i(tl, { className: "tw-ml-1 tw-inline tw-h-4 tw-w-4" }) + /* @__PURE__ */ s(Sl, { className: "tw-ml-1 tw-inline tw-h-4 tw-w-4" }) ] } ) @@ -9476,27 +10139,27 @@ function qm({ } ); } -function em({ id: e, versionHistory: t }) { - const [n, r] = ue(!1), o = /* @__PURE__ */ new Date(); +function Km({ id: t, versionHistory: e }) { + const [n, r] = ut(!1), o = /* @__PURE__ */ new Date(); function a(l) { const c = new Date(l), d = new Date(o.getTime() - c.getTime()), p = d.getUTCFullYear() - 1970, m = d.getUTCMonth(), w = d.getUTCDate() - 1; - let b = ""; - return p > 0 ? b = `${p.toString()} year${p === 1 ? "" : "s"} ago` : m > 0 ? b = `${m.toString()} month${m === 1 ? "" : "s"} ago` : w === 0 ? b = "today" : b = `${w.toString()} day${w === 1 ? "" : "s"} ago`, b; - } - const s = Object.entries(t).sort((l, c) => c[0].localeCompare(l[0])); - return /* @__PURE__ */ x("div", { id: e, children: [ - /* @__PURE__ */ i("h3", { className: "tw-text-md tw-font-semibold", children: "What`s New" }), - /* @__PURE__ */ i("ul", { className: "tw-list-disc tw-pl-5 tw-pr-4 tw-text-xs tw-text-gray-600", children: (n ? s : s.slice(0, 5)).map((l) => /* @__PURE__ */ x("div", { className: "tw-mt-3 tw-flex tw-justify-between", children: [ - /* @__PURE__ */ i("div", { className: "tw-text-gray-600", children: /* @__PURE__ */ i("li", { className: "tw-prose tw-text-xs", children: /* @__PURE__ */ i("span", { children: l[1].description }) }) }), + let g = ""; + return p > 0 ? g = `${p.toString()} year${p === 1 ? "" : "s"} ago` : m > 0 ? g = `${m.toString()} month${m === 1 ? "" : "s"} ago` : w === 0 ? g = "today" : g = `${w.toString()} day${w === 1 ? "" : "s"} ago`, g; + } + const i = Object.entries(e).sort((l, c) => c[0].localeCompare(l[0])); + return /* @__PURE__ */ x("div", { id: t, children: [ + /* @__PURE__ */ s("h3", { className: "tw-text-md tw-font-semibold", children: "What`s New" }), + /* @__PURE__ */ s("ul", { className: "tw-list-disc tw-pl-5 tw-pr-4 tw-text-xs tw-text-gray-600", children: (n ? i : i.slice(0, 5)).map((l) => /* @__PURE__ */ x("div", { className: "tw-mt-3 tw-flex tw-justify-between", children: [ + /* @__PURE__ */ s("div", { className: "tw-text-gray-600", children: /* @__PURE__ */ s("li", { className: "tw-prose tw-text-xs", children: /* @__PURE__ */ s("span", { children: l[1].description }) }) }), /* @__PURE__ */ x("div", { className: "tw-justify-end tw-text-right", children: [ /* @__PURE__ */ x("div", { children: [ "Version ", l[0] ] }), - /* @__PURE__ */ i("div", { children: a(l[1].date) }) + /* @__PURE__ */ s("div", { children: a(l[1].date) }) ] }) ] }, l[0])) }), - s.length > 5 && /* @__PURE__ */ i( + i.length > 5 && /* @__PURE__ */ s( "button", { type: "button", @@ -9507,71 +10170,71 @@ function em({ id: e, versionHistory: t }) { ) ] }); } -function Km({ - id: e, - publisherDisplayName: t, +function Wh({ + id: t, + publisherDisplayName: e, fileSize: n, locales: r, versionHistory: o }) { - const a = _e(() => ll(n), [n]), l = ((c) => { + const a = $t(() => $l(n), [n]), l = ((c) => { const d = new Intl.DisplayNames(navigator.language, { type: "language" }); return c.map((p) => d.of(p)); })(r); - return /* @__PURE__ */ i("div", { id: e, className: "tw-border-t tw-pb-4 tw-pt-4", children: /* @__PURE__ */ x("div", { className: "tw-md:flex-row tw-md:space-x-8 tw-flex tw-flex-col tw-space-x-0", children: [ - /* @__PURE__ */ i(em, { versionHistory: o }), - /* @__PURE__ */ i("div", { className: "tw-md:border-t-0 tw-md:border-l tw-md-h-auto tw-md-ml-8 tw-mt-4 tw-border-t tw-border-gray-300" }), + return /* @__PURE__ */ s("div", { id: t, className: "tw-border-t tw-pb-4 tw-pt-4", children: /* @__PURE__ */ x("div", { className: "tw-md:flex-row tw-md:space-x-8 tw-flex tw-flex-col tw-space-x-0", children: [ + /* @__PURE__ */ s(Km, { versionHistory: o }), + /* @__PURE__ */ s("div", { className: "tw-md:border-t-0 tw-md:border-l tw-md-h-auto tw-md-ml-8 tw-mt-4 tw-border-t tw-border-gray-300" }), /* @__PURE__ */ x("div", { className: "tw-md:mt-0 tw-mt-4 tw-flex-1 tw-space-y-3", children: [ - /* @__PURE__ */ i("h2", { className: "tw-text-md tw-font-semibold", children: "Information" }), + /* @__PURE__ */ s("h2", { className: "tw-text-md tw-font-semibold", children: "Information" }), /* @__PURE__ */ x("div", { className: "tw-flex tw-items-start tw-justify-between tw-pr-4 tw-text-xs tw-text-gray-600", children: [ /* @__PURE__ */ x("p", { className: "tw-flex tw-flex-col tw-justify-start", children: [ - /* @__PURE__ */ i("span", { className: "tw-mb-2", children: "Publisher" }), - /* @__PURE__ */ i("span", { className: "tw-font-semibold", children: t }), - /* @__PURE__ */ i("span", { className: "tw-mb-2 tw-mt-4", children: "Size" }), - /* @__PURE__ */ i("span", { className: "tw-font-semibold", children: a }) + /* @__PURE__ */ s("span", { className: "tw-mb-2", children: "Publisher" }), + /* @__PURE__ */ s("span", { className: "tw-font-semibold", children: e }), + /* @__PURE__ */ s("span", { className: "tw-mb-2 tw-mt-4", children: "Size" }), + /* @__PURE__ */ s("span", { className: "tw-font-semibold", children: a }) ] }), - /* @__PURE__ */ i("div", { className: "tw-flex tw-w-3/4 tw-items-center tw-justify-between tw-text-xs tw-text-gray-600", children: /* @__PURE__ */ x("p", { className: "tw-flex tw-flex-col tw-justify-start", children: [ - /* @__PURE__ */ i("span", { className: "tw-mb-2", children: "Languages" }), - /* @__PURE__ */ i("span", { className: "tw-font-semibold", children: l.join(", ") }) + /* @__PURE__ */ s("div", { className: "tw-flex tw-w-3/4 tw-items-center tw-justify-between tw-text-xs tw-text-gray-600", children: /* @__PURE__ */ x("p", { className: "tw-flex tw-flex-col tw-justify-start", children: [ + /* @__PURE__ */ s("span", { className: "tw-mb-2", children: "Languages" }), + /* @__PURE__ */ s("span", { className: "tw-font-semibold", children: l.join(", ") }) ] }) }) ] }) ] }) ] }) }); } -const Jm = (e, t) => { - at(() => { - if (!e) +const qh = (t, e) => { + ae(() => { + if (!t) return () => { }; - const n = e(t); + const n = t(e); return () => { n(); }; - }, [e, t]); -}, Lr = () => !1, Zm = (e, t) => { - const [n] = eo( - Me(async () => { - if (!e) - return Lr; - const r = await Promise.resolve(e(t)); + }, [t, e]); +}, Gr = () => !1, Kh = (t, e) => { + const [n] = oo( + Bt(async () => { + if (!t) + return Gr; + const r = await Promise.resolve(t(e)); return async () => r(); - }, [t, e]), - Lr, + }, [e, t]), + Gr, // We want the unsubscriber to return to default value immediately upon changing subscription // So the useEffect below will unsubscribe asap { preserveValue: !1 } ); - at(() => () => { - n !== Lr && n(); + ae(() => () => { + n !== Gr && n(); }, [n]); }; -function tm(e, t = "top") { - if (!e || typeof document > "u") +function Jm(t, e = "top") { + if (!t || typeof document > "u") return; const n = document.head || document.querySelector("head"), r = n.querySelector(":first-child"), o = document.createElement("style"); - o.appendChild(document.createTextNode(e)), t === "top" && r ? n.insertBefore(o, r) : n.appendChild(o); + o.appendChild(document.createTextNode(t)), e === "top" && r ? n.insertBefore(o, r) : n.appendChild(o); } -tm(`*, ::before, ::after { +Jm(`*, ::before, ::after { --tw-border-spacing-x: 0; --tw-border-spacing-y: 0; --tw-translate-x: 0; @@ -10641,13 +11304,23 @@ video:where(.pr-twp,.pr-twp *) { .tw-inset-0 { inset: 0px; } +.tw-inset-x-0 { + left: 0px; + right: 0px; +} .tw-inset-y-0 { top: 0px; bottom: 0px; } +.tw-bottom-0 { + bottom: 0px; +} .tw-bottom-2 { bottom: 0.5rem; } +.tw-left-0 { + left: 0px; +} .tw-left-2 { left: 0.5rem; } @@ -10657,6 +11330,12 @@ video:where(.pr-twp,.pr-twp *) { .tw-left-\\[50\\%\\] { left: 50%; } +.tw-right-0 { + right: 0px; +} +.tw-right-1 { + right: 0.25rem; +} .tw-right-3 { right: 0.75rem; } @@ -10666,12 +11345,18 @@ video:where(.pr-twp,.pr-twp *) { .tw-top-0 { top: 0px; } +.tw-top-1\\.5 { + top: 0.375rem; +} .tw-top-1\\/2 { top: 50%; } .tw-top-2\\.5 { top: 0.625rem; } +.tw-top-3\\.5 { + top: 0.875rem; +} .tw-top-4 { top: 1rem; } @@ -10684,6 +11369,9 @@ video:where(.pr-twp,.pr-twp *) { .tw-z-10 { z-index: 10; } +.tw-z-20 { + z-index: 20; +} .tw-z-30 { z-index: 30; } @@ -10711,6 +11399,10 @@ video:where(.pr-twp,.pr-twp *) { margin-left: 0.5rem; margin-right: 0.5rem; } +.tw-mx-3\\.5 { + margin-left: 0.875rem; + margin-right: 0.875rem; +} .tw-my-1 { margin-top: 0.25rem; margin-bottom: 0.25rem; @@ -10807,6 +11499,10 @@ video:where(.pr-twp,.pr-twp *) { .tw-aspect-square { aspect-ratio: 1 / 1; } +.tw-size-4 { + width: 1rem; + height: 1rem; +} .tw-h-1\\/2 { height: 50%; } @@ -10882,6 +11578,9 @@ video:where(.pr-twp,.pr-twp *) { .tw-h-px { height: 1px; } +.tw-h-svh { + height: 100svh; +} .tw-max-h-80 { max-height: 20rem; } @@ -10891,6 +11590,12 @@ video:where(.pr-twp,.pr-twp *) { .tw-max-h-\\[300px\\] { max-height: 300px; } +.tw-min-h-0 { + min-height: 0px; +} +.tw-min-h-svh { + min-height: 100svh; +} .tw-w-0 { width: 0px; } @@ -10933,6 +11638,9 @@ video:where(.pr-twp,.pr-twp *) { .tw-w-6 { width: 1.5rem; } +.tw-w-7 { + width: 1.75rem; +} .tw-w-72 { width: 18rem; } @@ -10942,6 +11650,9 @@ video:where(.pr-twp,.pr-twp *) { .tw-w-9 { width: 2.25rem; } +.tw-w-\\[--sidebar-width\\] { + width: var(--sidebar-width); +} .tw-w-\\[1\\.2rem\\] { width: 1.2rem; } @@ -10975,6 +11686,12 @@ video:where(.pr-twp,.pr-twp *) { .tw-w-full { width: 100%; } +.tw-min-w-0 { + min-width: 0px; +} +.tw-min-w-5 { + min-width: 1.25rem; +} .tw-min-w-\\[8rem\\] { min-width: 8rem; } @@ -10984,6 +11701,9 @@ video:where(.pr-twp,.pr-twp *) { .tw-max-w-64 { max-width: 16rem; } +.tw-max-w-\\[--skeleton-width\\] { + max-width: var(--skeleton-width); +} .tw-max-w-lg { max-width: 32rem; } @@ -11005,6 +11725,14 @@ video:where(.pr-twp,.pr-twp *) { .tw-caption-bottom { caption-side: bottom; } +.tw--translate-x-1\\/2 { + --tw-translate-x: -50%; + transform: translate(var(--tw-translate-x), var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y)); +} +.tw--translate-x-px { + --tw-translate-x: -1px; + transform: translate(var(--tw-translate-x), var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y)); +} .tw--translate-y-1\\/2 { --tw-translate-y: -50%; transform: translate(var(--tw-translate-x), var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y)); @@ -11013,6 +11741,10 @@ video:where(.pr-twp,.pr-twp *) { --tw-translate-x: -50%; transform: translate(var(--tw-translate-x), var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y)); } +.tw-translate-x-px { + --tw-translate-x: 1px; + transform: translate(var(--tw-translate-x), var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y)); +} .tw-translate-y-\\[-50\\%\\] { --tw-translate-y: -50%; transform: translate(var(--tw-translate-x), var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y)); @@ -11038,6 +11770,15 @@ video:where(.pr-twp,.pr-twp *) { .tw-transform { transform: translate(var(--tw-translate-x), var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y)); } +@keyframes tw-pulse { + + 50% { + opacity: .5; + } +} +.tw-animate-pulse { + animation: tw-pulse 2s cubic-bezier(0.4, 0, 0.6, 1) infinite; +} @keyframes tw-spin { to { @@ -11273,6 +12014,9 @@ video:where(.pr-twp,.pr-twp *) { .tw-border-l-2 { border-left-width: 2px; } +.tw-border-r { + border-right-width: 1px; +} .tw-border-r-0 { border-right-width: 0px; } @@ -11317,6 +12061,9 @@ video:where(.pr-twp,.pr-twp *) { --tw-border-opacity: 1; border-color: rgb(220 38 38 / var(--tw-border-opacity)); } +.tw-border-sidebar-border { + border-color: hsl(var(--sidebar-border)); +} .tw-border-transparent { border-color: transparent; } @@ -11434,6 +12181,12 @@ video:where(.pr-twp,.pr-twp *) { .tw-bg-secondary-foreground { background-color: hsl(var(--secondary-foreground)); } +.tw-bg-sidebar { + background-color: hsl(var(--sidebar-background)); +} +.tw-bg-sidebar-border { + background-color: hsl(var(--sidebar-border)); +} .tw-bg-transparent { background-color: transparent; } @@ -11501,6 +12254,10 @@ video:where(.pr-twp,.pr-twp *) { padding-left: 2rem; padding-right: 2rem; } +.tw-py-0\\.5 { + padding-top: 0.125rem; + padding-bottom: 0.125rem; +} .tw-py-1 { padding-top: 0.25rem; padding-bottom: 0.25rem; @@ -11573,6 +12330,9 @@ video:where(.pr-twp,.pr-twp *) { .tw-pt-4 { padding-top: 1rem; } +.tw-text-left { + text-align: left; +} .tw-text-center { text-align: center; } @@ -11731,6 +12491,12 @@ video:where(.pr-twp,.pr-twp *) { .tw-text-secondary-foreground { color: hsl(var(--secondary-foreground)); } +.tw-text-sidebar-foreground { + color: hsl(var(--sidebar-foreground)); +} +.tw-text-sidebar-foreground\\/70 { + color: hsl(var(--sidebar-foreground) / 0.7); +} .tw-text-slate-900 { --tw-text-opacity: 1; color: rgb(15 23 42 / var(--tw-text-opacity)); @@ -11761,6 +12527,11 @@ video:where(.pr-twp,.pr-twp *) { .tw-opacity-70 { opacity: 0.7; } +.tw-shadow-\\[0_0_0_1px_hsl\\(var\\(--sidebar-border\\)\\)\\] { + --tw-shadow: 0 0 0 1px hsl(var(--sidebar-border)); + --tw-shadow-colored: 0 0 0 1px var(--tw-shadow-color); + box-shadow: var(--tw-ring-offset-shadow, 0 0 #0000), var(--tw-ring-shadow, 0 0 #0000), var(--tw-shadow); +} .tw-shadow-lg { --tw-shadow: 0 10px 15px -3px rgb(0 0 0 / 0.1), 0 4px 6px -4px rgb(0 0 0 / 0.1); --tw-shadow-colored: 0 10px 15px -3px var(--tw-shadow-color), 0 4px 6px -4px var(--tw-shadow-color); @@ -11790,6 +12561,9 @@ video:where(.pr-twp,.pr-twp *) { --tw-ring-shadow: var(--tw-ring-inset) 0 0 0 calc(0px + var(--tw-ring-offset-width)) var(--tw-ring-color); box-shadow: var(--tw-ring-offset-shadow), var(--tw-ring-shadow), var(--tw-shadow, 0 0 #0000); } +.tw-ring-sidebar-ring { + --tw-ring-color: hsl(var(--sidebar-ring)); +} .tw-ring-offset-background { --tw-ring-offset-color: hsl(var(--background)); } @@ -11802,6 +12576,26 @@ video:where(.pr-twp,.pr-twp *) { transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1); transition-duration: 150ms; } +.tw-transition-\\[left\\,right\\,width\\] { + transition-property: left,right,width; + transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1); + transition-duration: 150ms; +} +.tw-transition-\\[margin\\,opa\\] { + transition-property: margin,opa; + transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1); + transition-duration: 150ms; +} +.tw-transition-\\[width\\,height\\,padding\\] { + transition-property: width,height,padding; + transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1); + transition-duration: 150ms; +} +.tw-transition-\\[width\\] { + transition-property: width; + transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1); + transition-duration: 150ms; +} .tw-transition-all { transition-property: all; transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1); @@ -11831,6 +12625,9 @@ video:where(.pr-twp,.pr-twp *) { .tw-ease-in-out { transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1); } +.tw-ease-linear { + transition-timing-function: linear; +} @keyframes enter { from { @@ -11845,6 +12642,21 @@ video:where(.pr-twp,.pr-twp *) { transform: translate3d(var(--tw-exit-translate-x, 0), var(--tw-exit-translate-y, 0), 0) scale3d(var(--tw-exit-scale, 1), var(--tw-exit-scale, 1), var(--tw-exit-scale, 1)) rotate(var(--tw-exit-rotate, 0)); } } +.tw-animate-in { + animation-name: enter; + animation-duration: 150ms; + --tw-enter-opacity: initial; + --tw-enter-scale: initial; + --tw-enter-rotate: initial; + --tw-enter-translate-x: initial; + --tw-enter-translate-y: initial; +} +.tw-fade-in-0 { + --tw-enter-opacity: 0; +} +.tw-zoom-in-95 { + --tw-enter-scale: .95; +} .tw-duration-200 { animation-duration: 200ms; } @@ -11854,6 +12666,9 @@ video:where(.pr-twp,.pr-twp *) { .tw-ease-in-out { animation-timing-function: cubic-bezier(0.4, 0, 0.2, 1); } +.tw-ease-linear { + animation-timing-function: linear; +} /* #region shared with https://github.com/paranext/paranext-extension-template/blob/main/tailwind.css */ @@ -11888,6 +12703,32 @@ video:where(.pr-twp,.pr-twp *) { color: hsl(var(--muted-foreground)); } +.after\\:tw-absolute::after { + content: var(--tw-content); + position: absolute; +} + +.after\\:tw--inset-2::after { + content: var(--tw-content); + inset: -0.5rem; +} + +.after\\:tw-inset-y-0::after { + content: var(--tw-content); + top: 0px; + bottom: 0px; +} + +.after\\:tw-left-1\\/2::after { + content: var(--tw-content); + left: 50%; +} + +.after\\:tw-w-\\[2px\\]::after { + content: var(--tw-content); + width: 2px; +} + .hover\\:tw-border-blue-600:hover { --tw-border-opacity: 1; border-color: rgb(37 99 235 / var(--tw-border-opacity)); @@ -11927,6 +12768,10 @@ video:where(.pr-twp,.pr-twp *) { background-color: hsl(var(--secondary) / 0.8); } +.hover\\:tw-bg-sidebar-accent:hover { + background-color: hsl(var(--sidebar-accent)); +} + .hover\\:tw-bg-white:hover { --tw-bg-opacity: 1; background-color: rgb(255 255 255 / var(--tw-bg-opacity)); @@ -11949,6 +12794,10 @@ video:where(.pr-twp,.pr-twp *) { color: hsl(var(--muted-foreground)); } +.hover\\:tw-text-sidebar-accent-foreground:hover { + color: hsl(var(--sidebar-accent-foreground)); +} + .hover\\:tw-text-white:hover { --tw-text-opacity: 1; color: rgb(255 255 255 / var(--tw-text-opacity)); @@ -11962,6 +12811,17 @@ video:where(.pr-twp,.pr-twp *) { opacity: 1; } +.hover\\:tw-shadow-\\[0_0_0_1px_hsl\\(var\\(--sidebar-accent\\)\\)\\]:hover { + --tw-shadow: 0 0 0 1px hsl(var(--sidebar-accent)); + --tw-shadow-colored: 0 0 0 1px var(--tw-shadow-color); + box-shadow: var(--tw-ring-offset-shadow, 0 0 #0000), var(--tw-ring-shadow, 0 0 #0000), var(--tw-shadow); +} + +.hover\\:after\\:tw-bg-sidebar-border:hover::after { + content: var(--tw-content); + background-color: hsl(var(--sidebar-border)); +} + .focus\\:tw-bg-accent:focus { background-color: hsl(var(--accent)); } @@ -12009,6 +12869,10 @@ video:where(.pr-twp,.pr-twp *) { --tw-ring-color: hsl(var(--ring)); } +.focus-visible\\:tw-ring-sidebar-ring:focus-visible { + --tw-ring-color: hsl(var(--sidebar-ring)); +} + .focus-visible\\:tw-ring-offset-2:focus-visible { --tw-ring-offset-width: 2px; } @@ -12017,6 +12881,14 @@ video:where(.pr-twp,.pr-twp *) { --tw-ring-offset-color: hsl(var(--background)); } +.active\\:tw-bg-sidebar-accent:active { + background-color: hsl(var(--sidebar-accent)); +} + +.active\\:tw-text-sidebar-accent-foreground:active { + color: hsl(var(--sidebar-accent-foreground)); +} + .disabled\\:tw-pointer-events-none:disabled { pointer-events: none; } @@ -12041,6 +12913,18 @@ video:where(.pr-twp,.pr-twp *) { opacity: 0.7; } +.has-\\[\\[data-variant\\=inset\\]\\]\\:tw-bg-sidebar:has([data-variant=inset]) { + background-color: hsl(var(--sidebar-background)); +} + +.aria-disabled\\:tw-pointer-events-none[aria-disabled="true"] { + pointer-events: none; +} + +.aria-disabled\\:tw-opacity-50[aria-disabled="true"] { + opacity: 0.5; +} + .data-\\[disabled\\=true\\]\\:tw-pointer-events-none[data-disabled="true"] { pointer-events: none; } @@ -12079,6 +12963,10 @@ video:where(.pr-twp,.pr-twp *) { transform: translate(var(--tw-translate-x), var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y)); } +.data-\\[active\\=true\\]\\:tw-bg-sidebar-accent[data-active="true"] { + background-color: hsl(var(--sidebar-accent)); +} + .data-\\[highlighted\\]\\:tw-bg-amber-100[data-highlighted] { --tw-bg-opacity: 1; background-color: rgb(254 243 199 / var(--tw-bg-opacity)); @@ -12104,6 +12992,10 @@ video:where(.pr-twp,.pr-twp *) { background-color: hsl(var(--accent)); } +.data-\\[state\\=open\\]\\:tw-bg-secondary[data-state="open"] { + background-color: hsl(var(--secondary)); +} + .data-\\[state\\=selected\\]\\:tw-bg-muted[data-state="selected"] { background-color: hsl(var(--muted)); } @@ -12112,6 +13004,14 @@ video:where(.pr-twp,.pr-twp *) { background-color: hsl(var(--input)); } +.data-\\[active\\=true\\]\\:tw-font-medium[data-active="true"] { + font-weight: 500; +} + +.data-\\[active\\=true\\]\\:tw-text-sidebar-accent-foreground[data-active="true"] { + color: hsl(var(--sidebar-accent-foreground)); +} + .data-\\[selected\\=true\\]\\:tw-text-accent-foreground[data-selected="true"] { color: hsl(var(--accent-foreground)); } @@ -12140,12 +13040,24 @@ video:where(.pr-twp,.pr-twp *) { opacity: 0.5; } +.data-\\[state\\=open\\]\\:tw-opacity-100[data-state="open"] { + opacity: 1; +} + .data-\\[state\\=active\\]\\:tw-shadow-sm[data-state="active"] { --tw-shadow: 0 1px 2px 0 rgb(0 0 0 / 0.05); --tw-shadow-colored: 0 1px 2px 0 var(--tw-shadow-color); box-shadow: var(--tw-ring-offset-shadow, 0 0 #0000), var(--tw-ring-shadow, 0 0 #0000), var(--tw-shadow); } +.data-\\[state\\=closed\\]\\:tw-duration-300[data-state="closed"] { + transition-duration: 300ms; +} + +.data-\\[state\\=open\\]\\:tw-duration-500[data-state="open"] { + transition-duration: 500ms; +} + .data-\\[state\\=open\\]\\:tw-animate-in[data-state="open"] { animation-name: enter; animation-duration: 150ms; @@ -12198,22 +13110,167 @@ video:where(.pr-twp,.pr-twp *) { --tw-enter-translate-y: 0.5rem; } +.data-\\[state\\=closed\\]\\:tw-slide-out-to-bottom[data-state="closed"] { + --tw-exit-translate-y: 100%; +} + +.data-\\[state\\=closed\\]\\:tw-slide-out-to-left[data-state="closed"] { + --tw-exit-translate-x: -100%; +} + .data-\\[state\\=closed\\]\\:tw-slide-out-to-left-1\\/2[data-state="closed"] { --tw-exit-translate-x: -50%; } +.data-\\[state\\=closed\\]\\:tw-slide-out-to-right[data-state="closed"] { + --tw-exit-translate-x: 100%; +} + +.data-\\[state\\=closed\\]\\:tw-slide-out-to-top[data-state="closed"] { + --tw-exit-translate-y: -100%; +} + .data-\\[state\\=closed\\]\\:tw-slide-out-to-top-\\[48\\%\\][data-state="closed"] { --tw-exit-translate-y: -48%; } +.data-\\[state\\=open\\]\\:tw-slide-in-from-bottom[data-state="open"] { + --tw-enter-translate-y: 100%; +} + +.data-\\[state\\=open\\]\\:tw-slide-in-from-left[data-state="open"] { + --tw-enter-translate-x: -100%; +} + .data-\\[state\\=open\\]\\:tw-slide-in-from-left-1\\/2[data-state="open"] { --tw-enter-translate-x: -50%; } +.data-\\[state\\=open\\]\\:tw-slide-in-from-right[data-state="open"] { + --tw-enter-translate-x: 100%; +} + +.data-\\[state\\=open\\]\\:tw-slide-in-from-top[data-state="open"] { + --tw-enter-translate-y: -100%; +} + .data-\\[state\\=open\\]\\:tw-slide-in-from-top-\\[48\\%\\][data-state="open"] { --tw-enter-translate-y: -48%; } +.data-\\[state\\=closed\\]\\:tw-duration-300[data-state="closed"] { + animation-duration: 300ms; +} + +.data-\\[state\\=open\\]\\:tw-duration-500[data-state="open"] { + animation-duration: 500ms; +} + +.data-\\[state\\=open\\]\\:hover\\:tw-bg-sidebar-accent:hover[data-state="open"] { + background-color: hsl(var(--sidebar-accent)); +} + +.data-\\[state\\=open\\]\\:hover\\:tw-text-sidebar-accent-foreground:hover[data-state="open"] { + color: hsl(var(--sidebar-accent-foreground)); +} + +.tw-group[data-collapsible="offcanvas"] .group-data-\\[collapsible\\=offcanvas\\]\\:tw-left-\\[calc\\(var\\(--sidebar-width\\)\\*-1\\)\\] { + left: calc(var(--sidebar-width) * -1); +} + +.tw-group[data-collapsible="offcanvas"] .group-data-\\[collapsible\\=offcanvas\\]\\:tw-right-\\[calc\\(var\\(--sidebar-width\\)\\*-1\\)\\] { + right: calc(var(--sidebar-width) * -1); +} + +.tw-group[data-side="left"] .group-data-\\[side\\=left\\]\\:tw--right-4 { + right: -1rem; +} + +.tw-group[data-side="right"] .group-data-\\[side\\=right\\]\\:tw-left-0 { + left: 0px; +} + +.tw-group[data-collapsible="icon"] .group-data-\\[collapsible\\=icon\\]\\:tw--mt-8 { + margin-top: -2rem; +} + +.tw-group[data-collapsible="icon"] .group-data-\\[collapsible\\=icon\\]\\:tw-hidden { + display: none; +} + +.tw-group[data-collapsible="icon"] .group-data-\\[collapsible\\=icon\\]\\:tw-w-\\[--sidebar-width-icon\\] { + width: var(--sidebar-width-icon); +} + +.tw-group[data-collapsible="icon"] .group-data-\\[collapsible\\=icon\\]\\:tw-w-\\[calc\\(var\\(--sidebar-width-icon\\)_\\+_theme\\(spacing\\.4\\)\\)\\] { + width: calc(var(--sidebar-width-icon) + 1rem); +} + +.tw-group[data-collapsible="icon"] .group-data-\\[collapsible\\=icon\\]\\:tw-w-\\[calc\\(var\\(--sidebar-width-icon\\)_\\+_theme\\(spacing\\.4\\)_\\+2px\\)\\] { + width: calc(var(--sidebar-width-icon) + 1rem + 2px); +} + +.tw-group[data-collapsible="offcanvas"] .group-data-\\[collapsible\\=offcanvas\\]\\:tw-w-0 { + width: 0px; +} + +.tw-group[data-collapsible="offcanvas"] .group-data-\\[collapsible\\=offcanvas\\]\\:tw-translate-x-0 { + --tw-translate-x: 0px; + transform: translate(var(--tw-translate-x), var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y)); +} + +.tw-group[data-side="right"] .group-data-\\[side\\=right\\]\\:tw-rotate-180 { + --tw-rotate: 180deg; + transform: translate(var(--tw-translate-x), var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y)); +} + +.tw-group[data-collapsible="icon"] .group-data-\\[collapsible\\=icon\\]\\:tw-overflow-hidden { + overflow: hidden; +} + +.tw-group[data-variant="floating"] .group-data-\\[variant\\=floating\\]\\:tw-rounded-lg { + border-radius: var(--radius); +} + +.tw-group[data-variant="floating"] .group-data-\\[variant\\=floating\\]\\:tw-border { + border-width: 1px; +} + +.tw-group[data-side="left"] .group-data-\\[side\\=left\\]\\:tw-border-r { + border-right-width: 1px; +} + +.tw-group[data-side="right"] .group-data-\\[side\\=right\\]\\:tw-border-l { + border-left-width: 1px; +} + +.tw-group[data-variant="floating"] .group-data-\\[variant\\=floating\\]\\:tw-border-sidebar-border { + border-color: hsl(var(--sidebar-border)); +} + +.tw-group[data-collapsible="icon"] .group-data-\\[collapsible\\=icon\\]\\:tw-opacity-0 { + opacity: 0; +} + +.tw-group[data-variant="floating"] .group-data-\\[variant\\=floating\\]\\:tw-shadow { + --tw-shadow: 0 1px 3px 0 rgb(0 0 0 / 0.1), 0 1px 2px -1px rgb(0 0 0 / 0.1); + --tw-shadow-colored: 0 1px 3px 0 var(--tw-shadow-color), 0 1px 2px -1px var(--tw-shadow-color); + box-shadow: var(--tw-ring-offset-shadow, 0 0 #0000), var(--tw-ring-shadow, 0 0 #0000), var(--tw-shadow); +} + +.tw-group[data-collapsible="offcanvas"] .group-data-\\[collapsible\\=offcanvas\\]\\:after\\:tw-left-full::after { + content: var(--tw-content); + left: 100%; +} + +.tw-group[data-collapsible="offcanvas"] .group-data-\\[collapsible\\=offcanvas\\]\\:hover\\:tw-bg-sidebar:hover { + background-color: hsl(var(--sidebar-background)); +} + +.tw-peer[data-variant="inset"] ~ .peer-data-\\[variant\\=inset\\]\\:tw-min-h-\\[calc\\(100svh-theme\\(spacing\\.4\\)\\)\\] { + min-height: calc(100svh - 1rem); +} + @media (min-width: 640px) { .sm\\:tw-not-sr-only { @@ -12247,6 +13304,10 @@ video:where(.pr-twp,.pr-twp *) { display: none; } + .sm\\:tw-max-w-sm { + max-width: 24rem; + } + .sm\\:tw-grid-cols-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); } @@ -12312,6 +13373,10 @@ video:where(.pr-twp,.pr-twp *) { @media (min-width: 768px) { + .md\\:tw-block { + display: block; + } + .md\\:tw-inline { display: inline; } @@ -12352,6 +13417,37 @@ video:where(.pr-twp,.pr-twp *) { font-size: 1rem; line-height: 1.5rem; } + + .md\\:tw-opacity-0 { + opacity: 0; + } + + .after\\:md\\:tw-hidden::after { + content: var(--tw-content); + display: none; + } + + .tw-peer[data-variant="inset"] ~ .md\\:peer-data-\\[variant\\=inset\\]\\:tw-m-2 { + margin: 0.5rem; + } + + .tw-peer[data-state="collapsed"][data-variant="inset"] ~ .md\\:peer-data-\\[state\\=collapsed\\]\\:peer-data-\\[variant\\=inset\\]\\:tw-ml-2 { + margin-left: 0.5rem; + } + + .tw-peer[data-variant="inset"] ~ .md\\:peer-data-\\[variant\\=inset\\]\\:tw-ml-0 { + margin-left: 0px; + } + + .tw-peer[data-variant="inset"] ~ .md\\:peer-data-\\[variant\\=inset\\]\\:tw-rounded-xl { + border-radius: 0.75rem; + } + + .tw-peer[data-variant="inset"] ~ .md\\:peer-data-\\[variant\\=inset\\]\\:tw-shadow { + --tw-shadow: 0 1px 3px 0 rgb(0 0 0 / 0.1), 0 1px 2px -1px rgb(0 0 0 / 0.1); + --tw-shadow-colored: 0 1px 3px 0 var(--tw-shadow-color), 0 1px 2px -1px var(--tw-shadow-color); + box-shadow: var(--tw-ring-offset-shadow, 0 0 #0000), var(--tw-ring-shadow, 0 0 #0000), var(--tw-shadow); + } } @media (min-width: 1024px) { @@ -12454,6 +13550,16 @@ video:where(.pr-twp,.pr-twp *) { padding-inline-end: 0px; } +.\\[\\&\\>button\\]\\:tw-hidden>button { + display: none; +} + +.\\[\\&\\>span\\:last-child\\]\\:tw-truncate>span:last-child { + overflow: hidden; + text-overflow: ellipsis; + white-space: nowrap; +} + .\\[\\&\\>span\\]\\:tw-line-clamp-1>span { overflow: hidden; display: -webkit-box; @@ -12478,6 +13584,15 @@ video:where(.pr-twp,.pr-twp *) { top: 1rem; } +.\\[\\&\\>svg\\]\\:tw-size-4>svg { + width: 1rem; + height: 1rem; +} + +.\\[\\&\\>svg\\]\\:tw-shrink-0>svg { + flex-shrink: 0; +} + .\\[\\&\\>svg\\]\\:tw-text-destructive>svg { color: hsl(var(--destructive)); } @@ -12486,6 +13601,10 @@ video:where(.pr-twp,.pr-twp *) { color: hsl(var(--foreground)); } +.\\[\\&\\>svg\\]\\:tw-text-sidebar-accent-foreground>svg { + color: hsl(var(--sidebar-accent-foreground)); +} + .\\[\\&\\>svg\\~\\*\\]\\:tw-pl-7>svg~* { padding-left: 1.75rem; } @@ -12567,6 +13686,37 @@ video:where(.pr-twp,.pr-twp *) { .\\[\\&_tr\\]\\:tw-border-b tr { border-bottom-width: 1px; } + +[data-side=left][data-collapsible=offcanvas] .\\[\\[data-side\\=left\\]\\[data-collapsible\\=offcanvas\\]_\\&\\]\\:tw--right-2 { + right: -0.5rem; +} + +[data-side=left][data-state=collapsed] .\\[\\[data-side\\=left\\]\\[data-state\\=collapsed\\]_\\&\\]\\:tw-cursor-e-resize { + cursor: e-resize; +} + +[data-side=left] .\\[\\[data-side\\=left\\]_\\&\\]\\:tw-cursor-w-resize { + cursor: w-resize; +} + +[data-side=right][data-collapsible=offcanvas] .\\[\\[data-side\\=right\\]\\[data-collapsible\\=offcanvas\\]_\\&\\]\\:tw--left-2 { + left: -0.5rem; +} + +[data-side=right][data-state=collapsed] .\\[\\[data-side\\=right\\]\\[data-state\\=collapsed\\]_\\&\\]\\:tw-cursor-w-resize { + cursor: w-resize; +} + +[data-side=right] .\\[\\[data-side\\=right\\]_\\&\\]\\:tw-cursor-e-resize { + cursor: e-resize; +} +.banded-row:hover { + cursor: pointer; +} + +.banded-row[data-state='selected']:hover { + cursor: default; +} .papi-multi-column-menu { background-color: rgb(222, 222, 222); display: flex; @@ -12640,13 +13790,6 @@ video:where(.pr-twp,.pr-twp *) { max-width: 24px; max-height: 24px; } -.banded-row:hover { - cursor: pointer; -} - -.banded-row[data-state='selected']:hover { - cursor: default; -} .papi-menu-drawer-paper { height: fit-content !important; position: absolute !important; @@ -12659,116 +13802,119 @@ video:where(.pr-twp,.pr-twp *) { } `, "top"); export { - jf as Alert, - Lf as AlertDescription, - Vf as AlertTitle, - km as BOOK_SELECTOR_STRING_KEYS, - Nm as BookChapterControl, - wc as BookSelectionMode, - Em as BookSelector, - be as Button, - zf as Card, - Hf as CardContent, - Gf as CardDescription, - Xf as CardFooter, - Ff as CardHeader, - Uf as CardTitle, - uc as ChapterRangeSelector, - io as Checkbox, - Mm as Checklist, - qo as ComboBox, - xc as DataTable, - Gm as DisableButton, - ao as DropdownMenu, - so as DropdownMenuCheckboxItem, - tr as DropdownMenuContent, - zl as DropdownMenuGroup, - ss as DropdownMenuItem, - Qf as DropdownMenuItemType, - Nn as DropdownMenuLabel, - vm as DropdownMenuPortal, - xm as DropdownMenuRadioGroup, - is as DropdownMenuRadioItem, - nr as DropdownMenuSeparator, - Gl as DropdownMenuShortcut, - ym as DropdownMenuSub, - Ul as DropdownMenuSubContent, - Fl as DropdownMenuSubTrigger, - as as DropdownMenuTrigger, - Um as EnableButton, - Zf as FilterButton, - Ym as FilterDropdown, - Km as Footer, - If as GridMenu, - Mf as HamburgerMenuButton, - Om as INVENTORY_STRING_KEYS, - Bm as IconButton, - xn as Input, - Fm as InstallButton, - Rm as Inventory, - He as Label, - Xm as MarkdownRenderer, - fi as MenuItem, - qm as MoreInfo, - Pm as NavigationContentSearch, - Wm as NoExtensionsFound, - ls as RadioGroup, - Gr as RadioGroupItem, - _m as ScriptureResultsViewer, - $m as ScrollGroupSelector, - Pc as SearchBar, - fn as Select, - Bt as SelectContent, - mc as SelectGroup, - Ue as SelectItem, - hc as SelectLabel, - gs as SelectScrollDownButton, - hs as SelectScrollUpButton, - gc as SelectSeparator, - Mt as SelectTrigger, - mn as SelectValue, - Ts as Separator, - Im as SettingsList, - Dm as SettingsListHeader, - Am as SettingsListItem, - Yf as Slider, - Lm as Sonner, - Rn as Spinner, - Wf as Switch, - rr as Table, - ar as TableBody, - yc as TableCaption, - jt as TableCell, - vc as TableFooter, - hn as TableHead, - or as TableHeader, - ot as TableRow, - zm as Tabs, - Jf as TabsContent, - qf as TabsList, - Kf as TabsTrigger, - jm as TextField, - ys as ToggleGroup, - Ln as ToggleGroupItem, - Vm as Toolbar, - Hm as UpdateButton, - em as VersionHistory, - xs as VerticalTabs, - ks as VerticalTabsContent, - Ns as VerticalTabsList, - _c as VerticalTabsTrigger, - tc as buttonVariants, - T as cn, - Ec as getBookNumFromId, - kc as getLinesFromUSFM, - Ko as getNumberFromUSFM, - Tc as getStatusForItem, - Cm as inventoryCountColumn, - Tm as inventoryItemColumn, - Sm as inventoryStatusColumn, - th as sonner, - Jm as useEvent, - Zm as useEventAsync, - eo as usePromise + zm as Alert, + Fm as AlertDescription, + Lm as AlertTitle, + vh as BOOK_SELECTOR_STRING_KEYS, + bh as BookChapterControl, + Bc as BookSelectionMode, + yh as BookSelector, + gt as Button, + Xi as Card, + Vd as CardContent, + qi as CardDescription, + zd as CardFooter, + Yi as CardHeader, + Wi as CardTitle, + Dc as ChapterRangeSelector, + uo as Checkbox, + Ah as Checklist, + ta as ComboBox, + Hc as DataTable, + Fh as DisableButton, + co as DropdownMenu, + po as DropdownMenuCheckboxItem, + rr as DropdownMenuContent, + pc as DropdownMenuGroup, + wi as DropdownMenuItem, + qm as DropdownMenuItemType, + Sn as DropdownMenuLabel, + mh as DropdownMenuPortal, + gh as DropdownMenuRadioGroup, + fi as DropdownMenuRadioItem, + or as DropdownMenuSeparator, + fc as DropdownMenuShortcut, + hh as DropdownMenuSub, + wc as DropdownMenuSubContent, + uc as DropdownMenuSubTrigger, + ui as DropdownMenuTrigger, + Lh as EnableButton, + Wm as FilterButton, + Hh as FilterDropdown, + Wh as Footer, + Mm as GridMenu, + jm as HamburgerMenuButton, + Eh as INVENTORY_STRING_KEYS, + Mh as IconButton, + Ye as Input, + zh as InstallButton, + Sh as Inventory, + Xt as Label, + Gh as MarkdownRenderer, + js as MenuItem, + Yh as MoreInfo, + Th as NavigationContentSearch, + Xh as NoExtensionsFound, + mi as RadioGroup, + Wr as RadioGroupItem, + Oh as ScriptureResultsViewer, + Rh as ScrollGroupSelector, + td as SearchBar, + gn as Select, + Be as SelectContent, + Vc as SelectGroup, + Gt as SelectItem, + zc as SelectLabel, + Ei as SelectScrollDownButton, + ki as SelectScrollUpButton, + Lc as SelectSeparator, + De as SelectTrigger, + bn as SelectValue, + wo as Separator, + Ih as SettingsCard, + _h as SettingsList, + $h as SettingsListHeader, + Ph as SettingsListItem, + Pd as SettingsSidebar, + Ch as SettingsSidebarContentSearch, + Um as Slider, + jh as Sonner, + $n as Spinner, + Gm as Switch, + ar as Table, + sr as TableBody, + Gc as TableCaption, + je as TableCell, + Uc as TableFooter, + vn as TableHead, + ir as TableHeader, + oe as TableRow, + Vh as Tabs, + Ym as TabsContent, + Hm as TabsList, + Xm as TabsTrigger, + Dh as TextField, + Ci as ToggleGroup, + Un as ToggleGroupItem, + Bh as Toolbar, + Uh as UpdateButton, + Km as VersionHistory, + Oi as VerticalTabs, + _i as VerticalTabsContent, + Ri as VerticalTabsList, + ed as VerticalTabsTrigger, + Sc as buttonVariants, + N as cn, + Wc as getBookNumFromId, + Yc as getLinesFromUSFM, + ea as getNumberFromUSFM, + qc as getStatusForItem, + Nh as inventoryCountColumn, + xh as inventoryItemColumn, + kh as inventoryStatusColumn, + Qh as sonner, + qh as useEvent, + Kh as useEventAsync, + oo as usePromise }; //# sourceMappingURL=index.js.map diff --git a/lib/platform-bible-react/dist/index.js.map b/lib/platform-bible-react/dist/index.js.map index a8c8f86bbf..7f2e3ad564 100644 --- a/lib/platform-bible-react/dist/index.js.map +++ b/lib/platform-bible-react/dist/index.js.map @@ -1 +1 @@ -{"version":3,"file":"index.js","sources":["../src/utils/shadcn-ui.util.ts","../src/components/shadcn-ui/input.tsx","../src/components/advanced/book-chapter-control/book-chapter-input.component.tsx","../../../node_modules/@sillsdev/scripture/dist/index.es.js","../src/components/shadcn-ui/dropdown-menu.tsx","../src/components/advanced/book-chapter-control/book-menu-item.component.tsx","../src/components/advanced/book-chapter-control/chapter-select.component.tsx","../src/components/advanced/book-chapter-control/go-to-menu-item.component.tsx","../src/components/advanced/book-chapter-control/book-chapter-control.component.tsx","../src/components/shadcn-ui/button.tsx","../src/components/shadcn-ui/label.tsx","../src/components/shadcn-ui/radio-group.tsx","../src/components/shadcn-ui/popover.tsx","../src/components/shadcn-ui/dialog.tsx","../src/components/shadcn-ui/command.tsx","../src/components/basics/combo-box.component.tsx","../src/components/basics/chapter-range-selector.component.tsx","../src/components/advanced/book-selector.component.tsx","../src/components/advanced/data-table/data-table-column-toggle.component.tsx","../src/components/shadcn-ui/select.tsx","../src/components/advanced/data-table/data-table-pagination.component.tsx","../src/components/shadcn-ui/table.tsx","../src/components/advanced/data-table/data-table.component.tsx","../src/components/advanced/inventory/occurrences-table.component.tsx","../src/components/shadcn-ui/checkbox.tsx","../src/components/advanced/inventory/inventory-utils.ts","../src/components/shadcn-ui/toggle.tsx","../src/components/shadcn-ui/toggle-group.tsx","../src/components/advanced/inventory/inventory-columns.tsx","../src/components/advanced/inventory/inventory.component.tsx","../src/components/basics/search-bar.component.tsx","../src/components/basics/tabs-vertical.tsx","../src/components/advanced/navigation-content-search.component.tsx","../src/components/advanced/scripture-results-viewer/scripture-results-viewer.component.tsx","../src/components/advanced/scroll-group-selector.component.tsx","../src/components/shadcn-ui/separator.tsx","../src/components/advanced/settings-components/settings-list.component.tsx","../src/components/basics/checklist.component.tsx","../../../node_modules/@babel/runtime/helpers/interopRequireDefault.js","../../../node_modules/@mui/utils/chainPropTypes/chainPropTypes.js","../../../node_modules/@babel/runtime/helpers/esm/extends.js","../../../node_modules/@mui/utils/deepmerge/deepmerge.js","../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.production.min.js","../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.development.js","../../../node_modules/prop-types/node_modules/react-is/index.js","../../../node_modules/object-assign/index.js","../../../node_modules/prop-types/lib/ReactPropTypesSecret.js","../../../node_modules/prop-types/lib/has.js","../../../node_modules/prop-types/checkPropTypes.js","../../../node_modules/prop-types/factoryWithTypeCheckers.js","../../../node_modules/prop-types/factoryWithThrowingShims.js","../../../node_modules/prop-types/index.js","../../../node_modules/@mui/utils/elementAcceptingRef/elementAcceptingRef.js","../../../node_modules/@mui/utils/exactProp/exactProp.js","../../../node_modules/@mui/utils/formatMuiErrorMessage/formatMuiErrorMessage.js","../../../node_modules/react-is/cjs/react-is.production.min.js","../../../node_modules/react-is/cjs/react-is.development.js","../../../node_modules/react-is/index.js","../../../node_modules/@mui/utils/getDisplayName/getDisplayName.js","../../../node_modules/@mui/utils/HTMLElementType/HTMLElementType.js","../../../node_modules/@mui/utils/refType/refType.js","../../../node_modules/@mui/utils/capitalize/capitalize.js","../../../node_modules/@mui/utils/createChainedFunction/createChainedFunction.js","../../../node_modules/@mui/utils/debounce/debounce.js","../../../node_modules/@mui/utils/deprecatedPropType/deprecatedPropType.js","../../../node_modules/@mui/utils/isMuiElement/isMuiElement.js","../../../node_modules/@mui/utils/ownerDocument/ownerDocument.js","../../../node_modules/@mui/utils/ownerWindow/ownerWindow.js","../../../node_modules/@mui/utils/requirePropFactory/requirePropFactory.js","../../../node_modules/@mui/utils/setRef/setRef.js","../../../node_modules/@mui/utils/useEnhancedEffect/useEnhancedEffect.js","../../../node_modules/@mui/utils/useId/useId.js","../../../node_modules/@mui/utils/unsupportedProp/unsupportedProp.js","../../../node_modules/@mui/utils/useControlled/useControlled.js","../../../node_modules/@mui/utils/useEventCallback/useEventCallback.js","../../../node_modules/@mui/utils/useForkRef/useForkRef.js","../../../node_modules/@mui/utils/useLazyRef/useLazyRef.js","../../../node_modules/@mui/utils/useOnMount/useOnMount.js","../../../node_modules/@mui/utils/useTimeout/useTimeout.js","../../../node_modules/@mui/utils/useIsFocusVisible/useIsFocusVisible.js","../../../node_modules/@mui/utils/resolveProps/resolveProps.js","../../../node_modules/@mui/utils/composeClasses/composeClasses.js","../../../node_modules/@mui/utils/ClassNameGenerator/ClassNameGenerator.js","../../../node_modules/@mui/utils/generateUtilityClass/generateUtilityClass.js","../../../node_modules/@mui/utils/generateUtilityClasses/generateUtilityClasses.js","../../../node_modules/@mui/utils/clamp/clamp.js","../../../node_modules/@babel/runtime/helpers/esm/objectWithoutPropertiesLoose.js","../../../node_modules/@mui/system/esm/createTheme/createBreakpoints.js","../../../node_modules/@mui/system/esm/createTheme/shape.js","../../../node_modules/@mui/system/esm/responsivePropType.js","../../../node_modules/@mui/system/esm/merge.js","../../../node_modules/@mui/system/esm/breakpoints.js","../../../node_modules/@mui/system/esm/style.js","../../../node_modules/@mui/system/esm/memoize.js","../../../node_modules/@mui/system/esm/spacing.js","../../../node_modules/@mui/system/esm/createTheme/createSpacing.js","../../../node_modules/@mui/system/esm/compose.js","../../../node_modules/@mui/system/esm/borders.js","../../../node_modules/@mui/system/esm/cssGrid.js","../../../node_modules/@mui/system/esm/palette.js","../../../node_modules/@mui/system/esm/sizing.js","../../../node_modules/@mui/system/esm/styleFunctionSx/defaultSxConfig.js","../../../node_modules/@mui/system/esm/styleFunctionSx/styleFunctionSx.js","../../../node_modules/@mui/system/esm/createTheme/applyStyles.js","../../../node_modules/@mui/system/esm/createTheme/createTheme.js","../../../node_modules/@mui/system/esm/useThemeWithoutDefault.js","../../../node_modules/@mui/system/esm/useTheme.js","../../../node_modules/@mui/system/esm/createStyled.js","../../../node_modules/@mui/system/esm/useThemeProps/getThemeProps.js","../../../node_modules/@mui/system/esm/useThemeProps/useThemeProps.js","../../../node_modules/@mui/system/esm/colorManipulator.js","../../../node_modules/@mui/material/styles/createMixins.js","../../../node_modules/@mui/material/colors/common.js","../../../node_modules/@mui/material/colors/grey.js","../../../node_modules/@mui/material/colors/purple.js","../../../node_modules/@mui/material/colors/red.js","../../../node_modules/@mui/material/colors/orange.js","../../../node_modules/@mui/material/colors/blue.js","../../../node_modules/@mui/material/colors/lightBlue.js","../../../node_modules/@mui/material/colors/green.js","../../../node_modules/@mui/material/styles/createPalette.js","../../../node_modules/@mui/material/styles/createTypography.js","../../../node_modules/@mui/material/styles/shadows.js","../../../node_modules/@mui/material/styles/createTransitions.js","../../../node_modules/@mui/material/styles/zIndex.js","../../../node_modules/@mui/material/styles/createTheme.js","../../../node_modules/@mui/material/styles/defaultTheme.js","../../../node_modules/@mui/material/styles/identifier.js","../../../node_modules/@mui/material/styles/useThemeProps.js","../../../node_modules/@mui/material/styles/styled.js","../../../node_modules/@mui/material/SvgIcon/svgIconClasses.js","../../../node_modules/@mui/material/SvgIcon/SvgIcon.js","../../../node_modules/@mui/material/utils/createSvgIcon.js","../../../node_modules/@mui/material/utils/index.js","../../../node_modules/@mui/icons-material/utils/createSvgIcon.js","../../../node_modules/@mui/icons-material/ArrowRight.js","../../../node_modules/@mui/base/utils/isHostComponent.js","../../../node_modules/@mui/base/utils/appendOwnerState.js","../../../node_modules/@mui/base/utils/ClassNameConfigurator.js","../../../node_modules/@mui/base/utils/extractEventHandlers.js","../../../node_modules/@mui/base/utils/resolveComponentProps.js","../../../node_modules/@mui/base/utils/omitEventHandlers.js","../../../node_modules/@mui/base/utils/mergeSlotProps.js","../../../node_modules/@mui/base/utils/useSlotProps.js","../../../node_modules/@mui/base/generateUtilityClass/index.js","../../../node_modules/@mui/base/generateUtilityClasses/index.js","../../../node_modules/@mui/base/Portal/Portal.js","../../../node_modules/@popperjs/core/lib/enums.js","../../../node_modules/@popperjs/core/lib/dom-utils/getNodeName.js","../../../node_modules/@popperjs/core/lib/dom-utils/getWindow.js","../../../node_modules/@popperjs/core/lib/dom-utils/instanceOf.js","../../../node_modules/@popperjs/core/lib/modifiers/applyStyles.js","../../../node_modules/@popperjs/core/lib/utils/getBasePlacement.js","../../../node_modules/@popperjs/core/lib/utils/math.js","../../../node_modules/@popperjs/core/lib/utils/userAgent.js","../../../node_modules/@popperjs/core/lib/dom-utils/isLayoutViewport.js","../../../node_modules/@popperjs/core/lib/dom-utils/getBoundingClientRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/getLayoutRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/contains.js","../../../node_modules/@popperjs/core/lib/dom-utils/getComputedStyle.js","../../../node_modules/@popperjs/core/lib/dom-utils/isTableElement.js","../../../node_modules/@popperjs/core/lib/dom-utils/getDocumentElement.js","../../../node_modules/@popperjs/core/lib/dom-utils/getParentNode.js","../../../node_modules/@popperjs/core/lib/dom-utils/getOffsetParent.js","../../../node_modules/@popperjs/core/lib/utils/getMainAxisFromPlacement.js","../../../node_modules/@popperjs/core/lib/utils/within.js","../../../node_modules/@popperjs/core/lib/utils/getFreshSideObject.js","../../../node_modules/@popperjs/core/lib/utils/mergePaddingObject.js","../../../node_modules/@popperjs/core/lib/utils/expandToHashMap.js","../../../node_modules/@popperjs/core/lib/modifiers/arrow.js","../../../node_modules/@popperjs/core/lib/utils/getVariation.js","../../../node_modules/@popperjs/core/lib/modifiers/computeStyles.js","../../../node_modules/@popperjs/core/lib/modifiers/eventListeners.js","../../../node_modules/@popperjs/core/lib/utils/getOppositePlacement.js","../../../node_modules/@popperjs/core/lib/utils/getOppositeVariationPlacement.js","../../../node_modules/@popperjs/core/lib/dom-utils/getWindowScroll.js","../../../node_modules/@popperjs/core/lib/dom-utils/getWindowScrollBarX.js","../../../node_modules/@popperjs/core/lib/dom-utils/getViewportRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/getDocumentRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/isScrollParent.js","../../../node_modules/@popperjs/core/lib/dom-utils/getScrollParent.js","../../../node_modules/@popperjs/core/lib/dom-utils/listScrollParents.js","../../../node_modules/@popperjs/core/lib/utils/rectToClientRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/getClippingRect.js","../../../node_modules/@popperjs/core/lib/utils/computeOffsets.js","../../../node_modules/@popperjs/core/lib/utils/detectOverflow.js","../../../node_modules/@popperjs/core/lib/utils/computeAutoPlacement.js","../../../node_modules/@popperjs/core/lib/modifiers/flip.js","../../../node_modules/@popperjs/core/lib/modifiers/hide.js","../../../node_modules/@popperjs/core/lib/modifiers/offset.js","../../../node_modules/@popperjs/core/lib/modifiers/popperOffsets.js","../../../node_modules/@popperjs/core/lib/utils/getAltAxis.js","../../../node_modules/@popperjs/core/lib/modifiers/preventOverflow.js","../../../node_modules/@popperjs/core/lib/dom-utils/getHTMLElementScroll.js","../../../node_modules/@popperjs/core/lib/dom-utils/getNodeScroll.js","../../../node_modules/@popperjs/core/lib/dom-utils/getCompositeRect.js","../../../node_modules/@popperjs/core/lib/utils/orderModifiers.js","../../../node_modules/@popperjs/core/lib/utils/debounce.js","../../../node_modules/@popperjs/core/lib/utils/mergeByName.js","../../../node_modules/@popperjs/core/lib/createPopper.js","../../../node_modules/@popperjs/core/lib/popper.js","../../../node_modules/@mui/base/Popper/popperClasses.js","../../../node_modules/@mui/base/Popper/Popper.js","../../../node_modules/@mui/material/styles/useTheme.js","../../../node_modules/@babel/runtime/helpers/esm/setPrototypeOf.js","../../../node_modules/@babel/runtime/helpers/esm/inheritsLoose.js","../../../node_modules/react-transition-group/esm/config.js","../../../node_modules/react-transition-group/esm/utils/PropTypes.js","../../../node_modules/react-transition-group/esm/TransitionGroupContext.js","../../../node_modules/react-transition-group/esm/utils/reflow.js","../../../node_modules/react-transition-group/esm/Transition.js","../../../node_modules/@mui/material/transitions/utils.js","../../../node_modules/@mui/material/Grow/Grow.js","../../../node_modules/@mui/material/Popper/Popper.js","../../../node_modules/@mui/material/Tooltip/tooltipClasses.js","../../../node_modules/@mui/material/Tooltip/Tooltip.js","../src/components/mui/menu-item.component.tsx","../src/components/mui/grouped-menu-item-list.component.tsx","../src/components/mui/top-level-menu.component.tsx","../src/components/mui/grid-menu.component.tsx","../src/hooks/use-promise.hook.ts","../../../node_modules/@mui/icons-material/esm/Menu.js","../src/components/mui/hamburger-menu-button.component.tsx","../src/components/mui/icon-button.component.tsx","../src/components/basics/spinner.component.tsx","../src/components/basics/text-field.component.tsx","../src/components/mui/toolbar.component.tsx","../src/components/shadcn-ui/alert.tsx","../src/components/shadcn-ui/card.tsx","../src/components/shadcn-ui/sonner.tsx","../src/components/shadcn-ui/slider.tsx","../src/components/shadcn-ui/switch.tsx","../src/components/shadcn-ui/tabs.tsx","../src/components/advanced/extension-marketplace/buttons/install-button.component.tsx","../src/components/advanced/extension-marketplace/buttons/enable-button.component.tsx","../src/components/advanced/extension-marketplace/buttons/disable-button.component.tsx","../src/components/advanced/extension-marketplace/buttons/update-button.component.tsx","../src/components/advanced/extension-marketplace/markdown-renderer.component.tsx","../src/components/advanced/extension-marketplace/buttons/filter-button.component.tsx","../src/components/advanced/extension-marketplace/filter-dropdown.component.tsx","../src/components/advanced/extension-marketplace/no-extensions-found.component.tsx","../src/components/advanced/extension-marketplace/more-info.component.tsx","../src/components/advanced/extension-marketplace/version-history.component.tsx","../src/components/advanced/extension-marketplace/footer.component.tsx","../src/hooks/use-event.hook.ts","../src/hooks/use-event-async.hook.ts"],"sourcesContent":["import { type ClassValue, clsx } from 'clsx';\nimport { extendTailwindMerge } from 'tailwind-merge';\n\nconst twMergeCustom = extendTailwindMerge({ prefix: 'tw-' });\n\n/**\n * Tailwind and CSS class application helper function. Uses\n * [`clsx`](https://www.npmjs.com/package/clsx) to make it easy to apply classes conditionally using\n * object syntax, and uses [`tailwind-merge`](https://www.npmjs.com/package/tailwind-merge) to make\n * it easy to merge/overwrite Tailwind classes in a programmer-logic-friendly way.\n *\n * Note: `tailwind-merge` is configured to use the prefix `tw-`, so you must use the same prefix\n * with any Tailwind classes you use with this function to successfully overwrite other Tailwind\n * classes. `platform-bible-react` is configured to use `tw-` as its Tailwind prefix, so any\n * Tailwind classes you pass into `platform-bible-react` components will be compared using the `tw-`\n * prefix.\n *\n * This function was popularized by\n * [shadcn/ui](https://ui.shadcn.com/docs/installation/manual#add-a-cn-helper). See [ByteGrad's\n * explanation video](https://www.youtube.com/watch?v=re2JFITR7TI) for more information.\n *\n * @example\n *\n * ```typescript\n * const borderShouldBeBlue = true;\n * const textShouldBeRed = true;\n * const heightShouldBe20 = false;\n * const classString = cn(\n * 'tw-bg-primary tw-h-10 tw-text-primary-foreground',\n * 'tw-bg-secondary',\n * {\n * 'tw-border-blue-500': borderShouldBeBlue,\n * 'tw-text-red-500': textShouldBeRed,\n * 'tw-h-20': heightShouldBe20,\n * },\n * 'some-class',\n * );\n * ```\n *\n * The resulting `classString` is `'tw-h-10 tw-bg-secondary tw-border-blue-500 tw-text-red-500\n * some-class'`\n *\n * - Notice that `'tw-bg-secondary'`, specified later, overwrote `'tw-bg-primary'`, specified earlier,\n * because they are Tailwind classes that affect the same css property\n * - Notice that `'tw-text-red-500'`, specified later, overwrote `'tw-text-primary-foreground'`,\n * specified earlier, because they are Tailwind classes that affect the same css property\n * - Notice that `'tw-h-20'`, specified later, did not overwrite `'tw-h-10'`, specified earlier,\n * because `'tw-h-20'` is part of a conditional class object and its value evaluated to `false`;\n * therefore it was not applied\n * - Notice that `'some-class'` was applied. This function is not limited only to Tailwind classes.\n *\n *\n * @param inputs Class strings or `clsx` conditional class objects to merge. Tailwind classes\n * specified later in the arguments overwrite similar Tailwind classes specified earlier in the\n * arguments\n * @returns Class string containing all applicable classes from the arguments based on the rules\n * described above\n */\n// shadcn/ui uses this export in its boilerplate code\n// eslint-disable-next-line import/prefer-default-export\nexport function cn(...inputs: ClassValue[]) {\n return twMergeCustom(clsx(inputs));\n}\n","import React from 'react';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport interface InputProps extends React.InputHTMLAttributes {}\n\nexport const Input = React.forwardRef(\n ({ className, type, ...props }, ref) => {\n return (\n \n );\n },\n);\nInput.displayName = 'Input';\n","import { FocusEventHandler, forwardRef, KeyboardEvent, MouseEventHandler } from 'react';\nimport { History } from 'lucide-react';\nimport { Input as ShadInput } from '@/components/shadcn-ui/input';\n\nexport type BookChapterInputProps = {\n handleSearch: (searchString: string) => void;\n handleKeyDown: (event: KeyboardEvent) => void;\n handleOnClick: MouseEventHandler;\n handleSubmit: () => void;\n onFocus?: FocusEventHandler;\n value: string;\n placeholder: string;\n};\n\n// Shadcn Input sets type to \"button\"- HAVE to prop spread before setting type\nconst BookChapterInput = forwardRef(\n (\n { handleSearch, handleKeyDown, handleOnClick, handleSubmit, ...props }: BookChapterInputProps,\n ref,\n ) => {\n return (\n
    \n handleSearch(event.target.value)}\n onKeyDown={(e) => {\n if (e.key === 'Enter') {\n handleSubmit();\n }\n handleKeyDown(e);\n }}\n onClick={handleOnClick}\n ref={ref}\n />\n {\n // eslint-disable-next-line no-console\n console.log('back in history');\n }}\n />\n
    \n );\n },\n);\n\nexport default BookChapterInput;\n","var P = Object.defineProperty;\nvar R = (t, e, s) => e in t ? P(t, e, { enumerable: !0, configurable: !0, writable: !0, value: s }) : t[e] = s;\nvar n = (t, e, s) => R(t, typeof e != \"symbol\" ? e + \"\" : e, s);\nclass _ {\n constructor() {\n n(this, \"books\");\n n(this, \"firstSelectedBookNum\");\n n(this, \"lastSelectedBookNum\");\n n(this, \"count\");\n n(this, \"selectedBookNumbers\");\n n(this, \"selectedBookIds\");\n }\n}\nconst N = [\n \"GEN\",\n \"EXO\",\n \"LEV\",\n \"NUM\",\n \"DEU\",\n \"JOS\",\n \"JDG\",\n \"RUT\",\n \"1SA\",\n \"2SA\",\n // 10\n \"1KI\",\n \"2KI\",\n \"1CH\",\n \"2CH\",\n \"EZR\",\n \"NEH\",\n \"EST\",\n \"JOB\",\n \"PSA\",\n \"PRO\",\n // 20\n \"ECC\",\n \"SNG\",\n \"ISA\",\n \"JER\",\n \"LAM\",\n \"EZK\",\n \"DAN\",\n \"HOS\",\n \"JOL\",\n \"AMO\",\n // 30\n \"OBA\",\n \"JON\",\n \"MIC\",\n \"NAM\",\n \"HAB\",\n \"ZEP\",\n \"HAG\",\n \"ZEC\",\n \"MAL\",\n \"MAT\",\n // 40\n \"MRK\",\n \"LUK\",\n \"JHN\",\n \"ACT\",\n \"ROM\",\n \"1CO\",\n \"2CO\",\n \"GAL\",\n \"EPH\",\n \"PHP\",\n // 50\n \"COL\",\n \"1TH\",\n \"2TH\",\n \"1TI\",\n \"2TI\",\n \"TIT\",\n \"PHM\",\n \"HEB\",\n \"JAS\",\n \"1PE\",\n // 60\n \"2PE\",\n \"1JN\",\n \"2JN\",\n \"3JN\",\n \"JUD\",\n \"REV\",\n \"TOB\",\n \"JDT\",\n \"ESG\",\n \"WIS\",\n // 70\n \"SIR\",\n \"BAR\",\n \"LJE\",\n \"S3Y\",\n \"SUS\",\n \"BEL\",\n \"1MA\",\n \"2MA\",\n \"3MA\",\n \"4MA\",\n // 80\n \"1ES\",\n \"2ES\",\n \"MAN\",\n \"PS2\",\n \"ODA\",\n \"PSS\",\n \"JSA\",\n // actual variant text for JOS, now in LXA text\n \"JDB\",\n // actual variant text for JDG, now in LXA text\n \"TBS\",\n // actual variant text for TOB, now in LXA text\n \"SST\",\n // actual variant text for SUS, now in LXA text // 90\n \"DNT\",\n // actual variant text for DAN, now in LXA text\n \"BLT\",\n // actual variant text for BEL, now in LXA text\n \"XXA\",\n \"XXB\",\n \"XXC\",\n \"XXD\",\n \"XXE\",\n \"XXF\",\n \"XXG\",\n \"FRT\",\n // 100\n \"BAK\",\n \"OTH\",\n \"3ES\",\n // Used previously but really should be 2ES\n \"EZA\",\n // Used to be called 4ES, but not actually in any known project\n \"5EZ\",\n // Used to be called 5ES, but not actually in any known project\n \"6EZ\",\n // Used to be called 6ES, but not actually in any known project\n \"INT\",\n \"CNC\",\n \"GLO\",\n \"TDX\",\n // 110\n \"NDX\",\n \"DAG\",\n \"PS3\",\n \"2BA\",\n \"LBA\",\n \"JUB\",\n \"ENO\",\n \"1MQ\",\n \"2MQ\",\n \"3MQ\",\n // 120\n \"REP\",\n \"4BA\",\n \"LAO\"\n], B = [\n \"XXA\",\n \"XXB\",\n \"XXC\",\n \"XXD\",\n \"XXE\",\n \"XXF\",\n \"XXG\",\n \"FRT\",\n \"BAK\",\n \"OTH\",\n \"INT\",\n \"CNC\",\n \"GLO\",\n \"TDX\",\n \"NDX\"\n], O = [\n \"Genesis\",\n \"Exodus\",\n \"Leviticus\",\n \"Numbers\",\n \"Deuteronomy\",\n \"Joshua\",\n \"Judges\",\n \"Ruth\",\n \"1 Samuel\",\n \"2 Samuel\",\n \"1 Kings\",\n \"2 Kings\",\n \"1 Chronicles\",\n \"2 Chronicles\",\n \"Ezra\",\n \"Nehemiah\",\n \"Esther (Hebrew)\",\n \"Job\",\n \"Psalms\",\n \"Proverbs\",\n \"Ecclesiastes\",\n \"Song of Songs\",\n \"Isaiah\",\n \"Jeremiah\",\n \"Lamentations\",\n \"Ezekiel\",\n \"Daniel (Hebrew)\",\n \"Hosea\",\n \"Joel\",\n \"Amos\",\n \"Obadiah\",\n \"Jonah\",\n \"Micah\",\n \"Nahum\",\n \"Habakkuk\",\n \"Zephaniah\",\n \"Haggai\",\n \"Zechariah\",\n \"Malachi\",\n \"Matthew\",\n \"Mark\",\n \"Luke\",\n \"John\",\n \"Acts\",\n \"Romans\",\n \"1 Corinthians\",\n \"2 Corinthians\",\n \"Galatians\",\n \"Ephesians\",\n \"Philippians\",\n \"Colossians\",\n \"1 Thessalonians\",\n \"2 Thessalonians\",\n \"1 Timothy\",\n \"2 Timothy\",\n \"Titus\",\n \"Philemon\",\n \"Hebrews\",\n \"James\",\n \"1 Peter\",\n \"2 Peter\",\n \"1 John\",\n \"2 John\",\n \"3 John\",\n \"Jude\",\n \"Revelation\",\n \"Tobit\",\n \"Judith\",\n \"Esther Greek\",\n \"Wisdom of Solomon\",\n \"Sirach (Ecclesiasticus)\",\n \"Baruch\",\n \"Letter of Jeremiah\",\n \"Song of 3 Young Men\",\n \"Susanna\",\n \"Bel and the Dragon\",\n \"1 Maccabees\",\n \"2 Maccabees\",\n \"3 Maccabees\",\n \"4 Maccabees\",\n \"1 Esdras (Greek)\",\n \"2 Esdras (Latin)\",\n \"Prayer of Manasseh\",\n \"Psalm 151\",\n \"Odes\",\n \"Psalms of Solomon\",\n // WARNING, if you change the spelling of the *obsolete* tag be sure to update\n // IsObsolete routine\n \"Joshua A. *obsolete*\",\n \"Judges B. *obsolete*\",\n \"Tobit S. *obsolete*\",\n \"Susanna Th. *obsolete*\",\n \"Daniel Th. *obsolete*\",\n \"Bel Th. *obsolete*\",\n \"Extra A\",\n \"Extra B\",\n \"Extra C\",\n \"Extra D\",\n \"Extra E\",\n \"Extra F\",\n \"Extra G\",\n \"Front Matter\",\n \"Back Matter\",\n \"Other Matter\",\n \"3 Ezra *obsolete*\",\n \"Apocalypse of Ezra\",\n \"5 Ezra (Latin Prologue)\",\n \"6 Ezra (Latin Epilogue)\",\n \"Introduction\",\n \"Concordance \",\n \"Glossary \",\n \"Topical Index\",\n \"Names Index\",\n \"Daniel Greek\",\n \"Psalms 152-155\",\n \"2 Baruch (Apocalypse)\",\n \"Letter of Baruch\",\n \"Jubilees\",\n \"Enoch\",\n \"1 Meqabyan\",\n \"2 Meqabyan\",\n \"3 Meqabyan\",\n \"Reproof (Proverbs 25-31)\",\n \"4 Baruch (Rest of Baruch)\",\n \"Laodiceans\"\n], S = K();\nfunction g(t, e = !0) {\n return e && (t = t.toUpperCase()), t in S ? S[t] : 0;\n}\nfunction k(t) {\n return g(t) > 0;\n}\nfunction x(t) {\n const e = typeof t == \"string\" ? g(t) : t;\n return e >= 40 && e <= 66;\n}\nfunction T(t) {\n return (typeof t == \"string\" ? g(t) : t) <= 39;\n}\nfunction X(t) {\n return t <= 66;\n}\nfunction V(t) {\n const e = typeof t == \"string\" ? g(t) : t;\n return w(e) && !X(e);\n}\nfunction* L() {\n for (let t = 1; t <= N.length; t++) yield t;\n}\nconst G = 1, A = N.length;\nfunction H() {\n return [\"XXA\", \"XXB\", \"XXC\", \"XXD\", \"XXE\", \"XXF\", \"XXG\"];\n}\nfunction C(t, e = \"***\") {\n const s = t - 1;\n return s < 0 || s >= N.length ? e : N[s];\n}\nfunction I(t) {\n return t <= 0 || t > A ? \"******\" : O[t - 1];\n}\nfunction y(t) {\n return I(g(t));\n}\nfunction w(t) {\n const e = typeof t == \"number\" ? C(t) : t;\n return k(e) && !B.includes(e);\n}\nfunction q(t) {\n const e = typeof t == \"number\" ? C(t) : t;\n return k(e) && B.includes(e);\n}\nfunction U(t) {\n return O[t - 1].includes(\"*obsolete*\");\n}\nfunction K() {\n const t = {};\n for (let e = 0; e < N.length; e++)\n t[N[e]] = e + 1;\n return t;\n}\nconst m = {\n allBookIds: N,\n nonCanonicalIds: B,\n bookIdToNumber: g,\n isBookIdValid: k,\n isBookNT: x,\n isBookOT: T,\n isBookOTNT: X,\n isBookDC: V,\n allBookNumbers: L,\n firstBook: G,\n lastBook: A,\n extraBooks: H,\n bookNumberToId: C,\n bookNumberToEnglishName: I,\n bookIdToEnglishName: y,\n isCanonical: w,\n isExtraMaterial: q,\n isObsolete: U\n};\nvar l = /* @__PURE__ */ ((t) => (t[t.Unknown = 0] = \"Unknown\", t[t.Original = 1] = \"Original\", t[t.Septuagint = 2] = \"Septuagint\", t[t.Vulgate = 3] = \"Vulgate\", t[t.English = 4] = \"English\", t[t.RussianProtestant = 5] = \"RussianProtestant\", t[t.RussianOrthodox = 6] = \"RussianOrthodox\", t))(l || {});\nconst h = class h {\n // private versInfo: Versification;\n constructor(e) {\n n(this, \"name\");\n n(this, \"fullPath\");\n n(this, \"isPresent\");\n n(this, \"hasVerseSegments\");\n n(this, \"isCustomized\");\n n(this, \"baseVersification\");\n n(this, \"scriptureBooks\");\n n(this, \"_type\");\n if (e == null)\n throw new Error(\"Argument undefined\");\n typeof e == \"string\" ? (this.name = e, this._type = l[e]) : (this._type = e, this.name = l[e]);\n }\n get type() {\n return this._type;\n }\n equals(e) {\n return !e.type || !this.type ? !1 : e.type === this.type;\n }\n};\nn(h, \"Original\", new h(l.Original)), n(h, \"Septuagint\", new h(l.Septuagint)), n(h, \"Vulgate\", new h(l.Vulgate)), n(h, \"English\", new h(l.English)), n(h, \"RussianProtestant\", new h(l.RussianProtestant)), n(h, \"RussianOrthodox\", new h(l.RussianOrthodox));\nlet c = h;\nfunction E(t, e) {\n const s = e[0];\n for (let r = 1; r < e.length; r++)\n t = t.split(e[r]).join(s);\n return t.split(s);\n}\nvar D = /* @__PURE__ */ ((t) => (t[t.Valid = 0] = \"Valid\", t[t.UnknownVersification = 1] = \"UnknownVersification\", t[t.OutOfRange = 2] = \"OutOfRange\", t[t.VerseOutOfOrder = 3] = \"VerseOutOfOrder\", t[t.VerseRepeated = 4] = \"VerseRepeated\", t))(D || {});\nconst i = class i {\n constructor(e, s, r, a) {\n /** Not yet implemented. */\n n(this, \"firstChapter\");\n /** Not yet implemented. */\n n(this, \"lastChapter\");\n /** Not yet implemented. */\n n(this, \"lastVerse\");\n /** Not yet implemented. */\n n(this, \"hasSegmentsDefined\");\n /** Not yet implemented. */\n n(this, \"text\");\n /** Not yet implemented. */\n n(this, \"BBBCCCVVVS\");\n /** Not yet implemented. */\n n(this, \"longHashCode\");\n /** The versification of the reference. */\n n(this, \"versification\");\n n(this, \"rtlMark\", \"‏\");\n n(this, \"_bookNum\", 0);\n n(this, \"_chapterNum\", 0);\n n(this, \"_verseNum\", 0);\n n(this, \"_verse\");\n if (r == null && a == null)\n if (e != null && typeof e == \"string\") {\n const o = e, u = s != null && s instanceof c ? s : void 0;\n this.setEmpty(u), this.parse(o);\n } else if (e != null && typeof e == \"number\") {\n const o = s != null && s instanceof c ? s : void 0;\n this.setEmpty(o), this._verseNum = e % i.chapterDigitShifter, this._chapterNum = Math.floor(\n e % i.bookDigitShifter / i.chapterDigitShifter\n ), this._bookNum = Math.floor(e / i.bookDigitShifter);\n } else if (s == null)\n if (e != null && e instanceof i) {\n const o = e;\n this._bookNum = o.bookNum, this._chapterNum = o.chapterNum, this._verseNum = o.verseNum, this._verse = o.verse, this.versification = o.versification;\n } else {\n if (e == null) return;\n const o = e instanceof c ? e : i.defaultVersification;\n this.setEmpty(o);\n }\n else\n throw new Error(\"VerseRef constructor not supported.\");\n else if (e != null && s != null && r != null)\n if (typeof e == \"string\" && typeof s == \"string\" && typeof r == \"string\")\n this.setEmpty(a), this.updateInternal(e, s, r);\n else if (typeof e == \"number\" && typeof s == \"number\" && typeof r == \"number\")\n this._bookNum = e, this._chapterNum = s, this._verseNum = r, this.versification = a ?? i.defaultVersification;\n else\n throw new Error(\"VerseRef constructor not supported.\");\n else\n throw new Error(\"VerseRef constructor not supported.\");\n }\n /**\n * Determines if the verse string is in a valid format (does not consider versification).\n */\n static isVerseParseable(e) {\n return e.length > 0 && \"0123456789\".includes(e[0]) && !e.endsWith(this.verseRangeSeparator) && !e.endsWith(this.verseSequenceIndicator);\n }\n /**\n * Tries to parse the specified string into a verse reference.\n * @param str - The string to attempt to parse.\n * @returns success: `true` if the specified string was successfully parsed, `false` otherwise.\n * @returns verseRef: The result of the parse if successful, or empty VerseRef if it failed\n */\n static tryParse(e) {\n let s;\n try {\n return s = new i(e), { success: !0, verseRef: s };\n } catch (r) {\n if (r instanceof v)\n return s = new i(), { success: !1, verseRef: s };\n throw r;\n }\n }\n /**\n * Gets the reference as a comparable integer where the book, chapter, and verse each occupy 3\n * digits.\n * @param bookNum - Book number (this is 1-based, not an index).\n * @param chapterNum - Chapter number.\n * @param verseNum - Verse number.\n * @returns The reference as a comparable integer where the book, chapter, and verse each occupy 3\n * digits.\n */\n static getBBBCCCVVV(e, s, r) {\n return e % i.bcvMaxValue * i.bookDigitShifter + (s >= 0 ? s % i.bcvMaxValue * i.chapterDigitShifter : 0) + (r >= 0 ? r % i.bcvMaxValue : 0);\n }\n /**\n * Deserializes a serialized VerseRef.\n * @param serializedVerseRef - Serialized VerseRef to create from.\n * @returns the deserialized VerseRef.\n */\n static fromJSON(e) {\n const { book: s, chapterNum: r, verseNum: a, verse: o, versificationStr: u } = e, f = o || a.toString();\n let d;\n return u && (d = new c(u)), s ? new i(s, r.toString(), f, d) : new i();\n }\n /**\n * Parses a verse string and gets the leading numeric portion as a number.\n * @param verseStr - verse string to parse\n * @returns true if the entire string could be parsed as a single, simple verse number (1-999);\n * false if the verse string represented a verse bridge, contained segment letters, or was invalid\n */\n static tryGetVerseNum(e) {\n let s;\n if (!e)\n return s = -1, { success: !0, vNum: s };\n s = 0;\n let r;\n for (let a = 0; a < e.length; a++) {\n if (r = e[a], r < \"0\" || r > \"9\")\n return a === 0 && (s = -1), { success: !1, vNum: s };\n if (s = s * 10 + +r - 0, s > i.bcvMaxValue)\n return s = -1, { success: !1, vNum: s };\n }\n return { success: !0, vNum: s };\n }\n /**\n * Checks to see if a VerseRef hasn't been set - all values are the default.\n */\n get isDefault() {\n return this.bookNum === 0 && this.chapterNum === 0 && this.verseNum === 0 && this.versification == null;\n }\n /**\n * Gets whether the verse contains multiple verses.\n */\n get hasMultiple() {\n return this._verse != null && (this._verse.includes(i.verseRangeSeparator) || this._verse.includes(i.verseSequenceIndicator));\n }\n /**\n * Gets or sets the book of the reference. Book is the 3-letter abbreviation in capital letters,\n * e.g. `'MAT'`.\n */\n get book() {\n return m.bookNumberToId(this.bookNum, \"\");\n }\n set book(e) {\n this.bookNum = m.bookIdToNumber(e);\n }\n /**\n * Gets or sets the chapter of the reference,. e.g. `'3'`.\n */\n get chapter() {\n return this.isDefault || this._chapterNum < 0 ? \"\" : this._chapterNum.toString();\n }\n set chapter(e) {\n const s = +e;\n this._chapterNum = Number.isInteger(s) ? s : -1;\n }\n /**\n * Gets or sets the verse of the reference, including range, segments, and sequences, e.g. `'4'`,\n * or `'4b-5a, 7'`.\n */\n get verse() {\n return this._verse != null ? this._verse : this.isDefault || this._verseNum < 0 ? \"\" : this._verseNum.toString();\n }\n set verse(e) {\n const { success: s, vNum: r } = i.tryGetVerseNum(e);\n this._verse = s ? void 0 : e.replace(this.rtlMark, \"\"), this._verseNum = r, !(this._verseNum >= 0) && ({ vNum: this._verseNum } = i.tryGetVerseNum(this._verse));\n }\n /**\n * Get or set Book based on book number, e.g. `42`.\n */\n get bookNum() {\n return this._bookNum;\n }\n set bookNum(e) {\n if (e <= 0 || e > m.lastBook)\n throw new v(\n \"BookNum must be greater than zero and less than or equal to last book\"\n );\n this._bookNum = e;\n }\n /**\n * Gets or sets the chapter number, e.g. `3`. `-1` if not valid.\n */\n get chapterNum() {\n return this._chapterNum;\n }\n set chapterNum(e) {\n this.chapterNum = e;\n }\n /**\n * Gets or sets verse start number, e.g. `4`. `-1` if not valid.\n */\n get verseNum() {\n return this._verseNum;\n }\n set verseNum(e) {\n this._verseNum = e;\n }\n /**\n * String representing the versification (should ONLY be used for serialization/deserialization).\n *\n * @remarks This is for backwards compatibility when ScrVers was an enumeration.\n */\n get versificationStr() {\n var e;\n return (e = this.versification) == null ? void 0 : e.name;\n }\n set versificationStr(e) {\n this.versification = this.versification != null ? new c(e) : void 0;\n }\n /**\n * Determines if the reference is valid.\n */\n get valid() {\n return this.validStatus === 0;\n }\n /**\n * Get the valid status for this reference.\n */\n get validStatus() {\n return this.validateVerse(i.verseRangeSeparators, i.verseSequenceIndicators);\n }\n /**\n * Gets the reference as a comparable integer where the book,\n * chapter, and verse each occupy three digits and the verse is 0.\n */\n get BBBCCC() {\n return i.getBBBCCCVVV(this._bookNum, this._chapterNum, 0);\n }\n /**\n * Gets the reference as a comparable integer where the book,\n * chapter, and verse each occupy three digits. If verse is not null\n * (i.e., this reference represents a complex reference with verse\n * segments or bridge) this cannot be used for an exact comparison.\n */\n get BBBCCCVVV() {\n return i.getBBBCCCVVV(this._bookNum, this._chapterNum, this._verseNum);\n }\n /**\n * Gets whether the verse is defined as an excluded verse in the versification.\n * Does not handle verse ranges.\n */\n // eslint-disable-next-line @typescript-eslint/class-literal-property-style\n get isExcluded() {\n return !1;\n }\n /**\n * Parses the reference in the specified string.\n * Optionally versification can follow reference as in GEN 3:11/4\n * Throw an exception if\n * - invalid book name\n * - chapter number is missing or not a number\n * - verse number is missing or does not start with a number\n * - versification is invalid\n * @param verseStr - string to parse e.g. 'MAT 3:11'\n */\n parse(e) {\n if (e = e.replace(this.rtlMark, \"\"), e.includes(\"/\")) {\n const o = e.split(\"/\");\n if (e = o[0], o.length > 1)\n try {\n const u = +o[1].trim();\n this.versification = new c(l[u]);\n } catch {\n throw new v(\"Invalid reference : \" + e);\n }\n }\n const s = e.trim().split(\" \");\n if (s.length !== 2)\n throw new v(\"Invalid reference : \" + e);\n const r = s[1].split(\":\"), a = +r[0];\n if (r.length !== 2 || m.bookIdToNumber(s[0]) === 0 || !Number.isInteger(a) || a < 0 || !i.isVerseParseable(r[1]))\n throw new v(\"Invalid reference : \" + e);\n this.updateInternal(s[0], r[0], r[1]);\n }\n /**\n * Simplifies this verse ref so that it has no bridging of verses or\n * verse segments like `'1a'`.\n */\n simplify() {\n this._verse = void 0;\n }\n /**\n * Makes a clone of the reference.\n *\n * @returns The cloned VerseRef.\n */\n clone() {\n return new i(this);\n }\n toString() {\n const e = this.book;\n return e === \"\" ? \"\" : `${e} ${this.chapter}:${this.verse}`;\n }\n toJSON() {\n let e = this.verse;\n (e === \"\" || e === this.verseNum.toString()) && (e = void 0);\n const s = {\n book: this.book,\n chapterNum: this.chapterNum,\n verseNum: this.verseNum,\n verse: e,\n versificationStr: this.versificationStr\n };\n return e || delete s.verse, s;\n }\n /**\n * Compares this `VerseRef` with supplied one.\n * @param verseRef - object to compare this one to.\n * @returns `true` if this `VerseRef` is equal to the supplied one, `false` otherwise.\n */\n equals(e) {\n return e instanceof i ? e._bookNum === this._bookNum && e._chapterNum === this._chapterNum && e._verseNum === this._verseNum && e.verse === this.verse && (e.versification == null && this.versification == null || e.versification != null && this.versification != null && e.versification.equals(this.versification)) : !1;\n }\n /**\n * Enumerate all individual verses contained in a VerseRef.\n * Verse ranges are indicated by \"-\" and consecutive verses by \",\"s.\n * Examples:\n * GEN 1:2 returns GEN 1:2\n * GEN 1:1a-3b,5 returns GEN 1:1a, GEN 1:2, GEN 1:3b, GEN 1:5\n * GEN 1:2a-2c returns //! ??????\n *\n * @param specifiedVersesOnly - if set to true return only verses that are\n * explicitly specified only, not verses within a range. Defaults to `false`.\n * @param verseRangeSeparators - Verse range separators.\n * Defaults to `VerseRef.verseRangeSeparators`.\n * @param verseSequenceSeparators - Verse sequence separators.\n * Defaults to `VerseRef.verseSequenceIndicators`.\n * @returns An array of all single verse references in this VerseRef.\n */\n allVerses(e = !1, s = i.verseRangeSeparators, r = i.verseSequenceIndicators) {\n if (this._verse == null || this.chapterNum <= 0)\n return [this.clone()];\n const a = [], o = E(this._verse, r);\n for (const u of o.map((f) => E(f, s))) {\n const f = this.clone();\n f.verse = u[0];\n const d = f.verseNum;\n if (a.push(f), u.length > 1) {\n const b = this.clone();\n if (b.verse = u[1], !e)\n for (let p = d + 1; p < b.verseNum; p++) {\n const J = new i(\n this._bookNum,\n this._chapterNum,\n p,\n this.versification\n );\n this.isExcluded || a.push(J);\n }\n a.push(b);\n }\n }\n return a;\n }\n /**\n * Validates a verse number using the supplied separators rather than the defaults.\n */\n validateVerse(e, s) {\n if (!this.verse)\n return this.internalValid;\n let r = 0;\n for (const a of this.allVerses(!0, e, s)) {\n const o = a.internalValid;\n if (o !== 0)\n return o;\n const u = a.BBBCCCVVV;\n if (r > u)\n return 3;\n if (r === u)\n return 4;\n r = u;\n }\n return 0;\n }\n /**\n * Gets whether a single verse reference is valid.\n */\n get internalValid() {\n return this.versification == null ? 1 : this._bookNum <= 0 || this._bookNum > m.lastBook ? 2 : (m.isCanonical(this._bookNum), 0);\n }\n setEmpty(e = i.defaultVersification) {\n this._bookNum = 0, this._chapterNum = -1, this._verse = void 0, this.versification = e;\n }\n updateInternal(e, s, r) {\n this.bookNum = m.bookIdToNumber(e), this.chapter = s, this.verse = r;\n }\n};\nn(i, \"defaultVersification\", c.English), n(i, \"verseRangeSeparator\", \"-\"), n(i, \"verseSequenceIndicator\", \",\"), n(i, \"verseRangeSeparators\", [i.verseRangeSeparator]), n(i, \"verseSequenceIndicators\", [i.verseSequenceIndicator]), n(i, \"chapterDigitShifter\", 1e3), n(i, \"bookDigitShifter\", i.chapterDigitShifter * i.chapterDigitShifter), n(i, \"bcvMaxValue\", i.chapterDigitShifter - 1), /**\n * The valid status of the VerseRef.\n */\nn(i, \"ValidStatusType\", D);\nlet M = i;\nclass v extends Error {\n}\nexport {\n _ as BookSet,\n m as Canon,\n c as ScrVers,\n l as ScrVersType,\n M as VerseRef,\n v as VerseRefException\n};\n//# sourceMappingURL=index.es.js.map\n","import React from 'react';\nimport * as DropdownMenuPrimitive from '@radix-ui/react-dropdown-menu';\nimport { Check, ChevronRight, Circle } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport const DropdownMenu = DropdownMenuPrimitive.Root;\n\nexport const DropdownMenuTrigger = DropdownMenuPrimitive.Trigger;\n\nexport const DropdownMenuGroup = DropdownMenuPrimitive.Group;\n\nexport const DropdownMenuPortal = DropdownMenuPrimitive.Portal;\n\nexport const DropdownMenuSub = DropdownMenuPrimitive.Sub;\n\nexport const DropdownMenuRadioGroup = DropdownMenuPrimitive.RadioGroup;\n\nexport type DropdownMenuSubTriggerProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.SubTrigger\n> & {\n className?: string;\n inset?: boolean;\n};\n\nexport type DropdownMenuSubContentProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.SubContent\n> & {\n className?: string;\n};\n\nexport type DropdownMenuContentProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Content\n> & {\n className?: string;\n sideOffset?: number;\n};\n\nexport type DropdownMenuItemProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Item\n> & {\n className?: string;\n inset?: boolean;\n};\n\nexport type DropdownMenuCheckboxItemProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.CheckboxItem\n> & {\n className?: string;\n checked?: boolean;\n};\n\nexport type DropdownMenuRadioItemProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.RadioItem\n> & {\n className?: string;\n};\n\nexport type DropdownMenuLabelProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Label\n> & {\n className?: string;\n inset?: boolean;\n};\n\nexport type DropdownMenuSeparatorProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Separator\n> & {\n className?: string;\n};\n\nexport type DropdownMenuShortcutProps = React.HTMLAttributes & {\n className?: string;\n};\n\nexport const DropdownMenuSubTrigger = React.forwardRef<\n React.ElementRef,\n DropdownMenuSubTriggerProps\n>(({ className, inset, children, ...props }, ref) => (\n \n {children}\n \n \n));\nDropdownMenuSubTrigger.displayName = DropdownMenuPrimitive.SubTrigger.displayName;\n\nexport const DropdownMenuSubContent = React.forwardRef<\n React.ElementRef,\n DropdownMenuSubContentProps\n>(({ className, ...props }, ref) => (\n \n));\nDropdownMenuSubContent.displayName = DropdownMenuPrimitive.SubContent.displayName;\n\nexport const DropdownMenuContent = React.forwardRef<\n React.ElementRef,\n DropdownMenuContentProps\n>(({ className, sideOffset = 4, ...props }, ref) => (\n \n \n \n));\nDropdownMenuContent.displayName = DropdownMenuPrimitive.Content.displayName;\n\n/**\n * TODO: fix: direction is not automatically handled by this component, so that shortcuts are\n * display always to the right\n */\nexport const DropdownMenuItem = React.forwardRef<\n React.ElementRef,\n DropdownMenuItemProps\n>(({ className, inset, ...props }, ref) => (\n \n));\nDropdownMenuItem.displayName = DropdownMenuPrimitive.Item.displayName;\n\nexport const DropdownMenuCheckboxItem = React.forwardRef<\n React.ElementRef,\n DropdownMenuCheckboxItemProps\n>(({ className, children, checked, ...props }, ref) => (\n \n \n \n \n \n \n {children}\n \n));\nDropdownMenuCheckboxItem.displayName = DropdownMenuPrimitive.CheckboxItem.displayName;\n\nexport const DropdownMenuRadioItem = React.forwardRef<\n React.ElementRef,\n DropdownMenuRadioItemProps\n>(({ className, children, ...props }, ref) => (\n \n \n \n \n \n \n {children}\n \n));\nDropdownMenuRadioItem.displayName = DropdownMenuPrimitive.RadioItem.displayName;\n\nexport const DropdownMenuLabel = React.forwardRef<\n React.ElementRef,\n DropdownMenuLabelProps\n>(({ className, inset, ...props }, ref) => (\n \n));\nDropdownMenuLabel.displayName = DropdownMenuPrimitive.Label.displayName;\n\nexport const DropdownMenuSeparator = React.forwardRef<\n React.ElementRef,\n DropdownMenuSeparatorProps\n>(({ className, ...props }, ref) => (\n \n));\nDropdownMenuSeparator.displayName = DropdownMenuPrimitive.Separator.displayName;\n\nexport function DropdownMenuShortcut({ className, ...props }: DropdownMenuShortcutProps) {\n return (\n \n );\n}\nDropdownMenuShortcut.displayName = 'DropdownMenuShortcut';\n","import { Canon } from '@sillsdev/scripture';\nimport { PropsWithChildren, KeyboardEvent, forwardRef } from 'react';\nimport { DropdownMenuItem as ShadDropdownMenuItem } from '@/components/shadcn-ui/dropdown-menu';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport type BookType = 'OT' | 'NT' | 'DC';\n\ntype BookMenuItemProps = PropsWithChildren<{\n /** String id of book */\n bookId: string;\n /** Callback to run when a book menu item is selected */\n handleSelectBook: () => void;\n /** Indicates if this menu item is currently selected */\n isSelected: boolean;\n /** Function that is called upon highlighting a book in the dropdown menu */\n handleHighlightBook: () => void;\n /**\n * Function that is called on pressing a key\n *\n * @param event Event that contains information about the key stroke\n */\n handleKeyDown: (event: KeyboardEvent) => void;\n /**\n * Type of book associated with this menu item, coordinates color labels ? Mock up has the labels\n * coordinated to genre\n */\n bookType: BookType;\n}>;\n\nconst BookMenuItem = forwardRef(\n (\n {\n bookId,\n handleSelectBook,\n isSelected,\n handleHighlightBook,\n handleKeyDown,\n bookType,\n children,\n }: BookMenuItemProps,\n ref,\n ) => {\n return (\n {\n // preventDefault() here prevents the entire dropdown menu from closing when selecting this item\n event.preventDefault();\n handleSelectBook();\n }}\n onKeyDown={(event: KeyboardEvent) => {\n handleKeyDown(event);\n }}\n onFocus={handleHighlightBook}\n onMouseMove={handleHighlightBook}\n >\n \n {Canon.bookIdToEnglishName(bookId)}\n \n {isSelected &&
    {children}
    }\n \n );\n },\n);\n\nexport default BookMenuItem;\n","import { cn } from '@/utils/shadcn-ui.util';\nimport { useCallback } from 'react';\n\nexport type ChapterSelectProps = {\n /**\n * Callback to run when a chapter div is selected\n *\n * @param chapterNumber Number of the chapter that has been selected\n */\n handleSelectChapter: (chapterNumber: number) => void;\n /** The highest chapter number in the book (of course equal to number of chapters in the book) */\n endChapter: number;\n /** The chapter number that is currently selected */\n activeChapter: number;\n /** The chapter number that is currently highlighted using keyboard or mouse navigation */\n highlightedChapter: number;\n /**\n * Callback to run when a chapter is highlighted by the user\n *\n * @param chapterNumber The chapter that is highlighted\n */\n handleHighlightedChapter: (chapterNumber: number) => void;\n};\n\nfunction ChapterSelect({\n handleSelectChapter,\n endChapter,\n activeChapter,\n highlightedChapter,\n handleHighlightedChapter,\n}: ChapterSelectProps) {\n const chapters = Array.from({ length: endChapter }, (_, i) => i + 1);\n\n const handleMouse = useCallback(\n (chapterNumber: number) => {\n handleHighlightedChapter(chapterNumber);\n },\n [handleHighlightedChapter],\n );\n\n return (\n
    \n {chapters.map((chapter) => (\n {\n event.preventDefault();\n event.stopPropagation();\n handleSelectChapter(chapter);\n }}\n role=\"button\"\n onKeyDown={(event) => {\n if (event.key === 'Enter') {\n handleSelectChapter(chapter);\n }\n }}\n tabIndex={0}\n onMouseMove={() => handleMouse(chapter)}\n >\n {chapter}\n
    \n ))}\n
    \n );\n}\n\nexport default ChapterSelect;\n","import { DropdownMenuLabel as ShadDropdownMenuLabel } from '@/components/shadcn-ui/dropdown-menu';\nimport { Bookmark, Clock, ArrowDownWideNarrow } from 'lucide-react';\n\nexport type GoToMenuItemProps = {\n handleSort: () => void;\n handleLocationHistory: () => void;\n handleBookmarks: () => void;\n};\n\nfunction GoToMenuItem({ handleSort, handleLocationHistory, handleBookmarks }: GoToMenuItemProps) {\n return (\n \n

    Go To

    \n
    \n \n \n \n
    \n
    \n );\n}\n\nexport default GoToMenuItem;\n","import BookChapterInput from '@/components/advanced/book-chapter-control/book-chapter-input.component';\nimport BookMenuItem, {\n BookType,\n} from '@/components/advanced/book-chapter-control/book-menu-item.component';\nimport ChapterSelect from '@/components/advanced/book-chapter-control/chapter-select.component';\nimport GoToMenuItem from '@/components/advanced/book-chapter-control/go-to-menu-item.component';\nimport {\n DropdownMenu as ShadDropdownMenu,\n DropdownMenuContent as ShadDropdownMenuContent,\n DropdownMenuLabel as ShadDropdownMenuLabel,\n DropdownMenuSeparator as ShadDropdownMenuSeparator,\n DropdownMenuTrigger as ShadDropdownMenuTrigger,\n} from '@/components/shadcn-ui/dropdown-menu';\nimport { Canon } from '@sillsdev/scripture';\nimport { ScriptureReference, getChaptersForBook } from 'platform-bible-utils';\nimport {\n KeyboardEvent as ReactKeyboardEvent,\n useCallback,\n useEffect,\n useLayoutEffect,\n useRef,\n useState,\n} from 'react';\n\ntype BookTypeLabels = {\n [bookType in BookType]: string;\n};\ntype BookChapterControlProps = {\n scrRef: ScriptureReference;\n handleSubmit: (scrRef: ScriptureReference) => void;\n};\n\nconst ALL_BOOK_IDS = Canon.allBookIds;\nconst BOOK_TYPE_LABELS: BookTypeLabels = {\n OT: 'Old Testament',\n NT: 'New Testament',\n DC: 'Deuterocanon',\n};\nconst BOOK_TYPE_ARRAY: BookType[] = ['OT', 'NT', 'DC'];\n// This is the height of three menu items to offset scrolling to the selected menu item\n// If you use menuItemRef.clientHeight- includes height of chapter div which is too big\nconst SCROLL_OFFSET = 32 + 32 + 32;\nconst SEARCH_QUERY_FORMATS = [\n /^(\\w+)$/i, // Matches a single word (book name or id)\n /^(\\w+)(?:\\s(\\d+))$/i, // Matches a word followed by a chapter number\n /^(\\w+)(?:\\s(\\d+):(\\d+))$/i, // Matches a word followed by a chapter and verse number\n];\nconst fetchGroupedBooks = (bookType: BookType) => {\n const groupedBooks = {\n OT: ALL_BOOK_IDS.filter((bookId) => Canon.isBookOT(bookId)),\n NT: ALL_BOOK_IDS.filter((bookId) => Canon.isBookNT(bookId)),\n DC: ALL_BOOK_IDS.filter((bookId) => Canon.isBookDC(bookId)),\n };\n return groupedBooks[bookType];\n};\nconst fetchEndChapter = (bookId: string) => {\n // getChaptersForBook returns -1 if not found in scrBookData\n // scrBookData only includes OT and NT, so all DC will return -1\n return getChaptersForBook(Canon.bookIdToNumber(bookId));\n};\n\n/**\n * Gets all of the English names from book ids\n *\n * @returns String[]\n */\nfunction getAllEnglishNames(): string[] {\n const allEnglishNames = ALL_BOOK_IDS.map((bookId) => {\n return Canon.bookIdToEnglishName(bookId);\n });\n return allEnglishNames;\n}\n\n/**\n * Determines if bookName is in allEnglishNames\n *\n * @param bookName Book English name\n * @returns True if bookName is included, false otherwise\n */\nfunction isValidBookEnglishName(bookName: string): boolean {\n return getAllEnglishNames().includes(bookName);\n}\n\n/**\n * Gets a bookId from given English name\n *\n * @param bookName Book English name\n * @returns BookId of provided bookName, undefined otherwise\n */\nfunction getBookIdFromEnglishName(bookName: string): string | undefined {\n // Convert bookName to lowercase and then capitalize the first letter\n const formattedBookName = bookName.toLowerCase().replace(/^\\w/, (c) => c.toUpperCase());\n\n if (isValidBookEnglishName(formattedBookName)) {\n const matchingBookId = ALL_BOOK_IDS.find((bookId) => {\n return Canon.bookIdToEnglishName(bookId) === formattedBookName;\n });\n return matchingBookId;\n }\n\n return undefined;\n}\n\nfunction BookChapterControl({ scrRef, handleSubmit }: BookChapterControlProps) {\n const [searchQuery, setSearchQuery] = useState('');\n const [selectedBookId, setSelectedBookId] = useState(\n Canon.bookNumberToId(scrRef.bookNum),\n );\n const [highlightedChapter, setHighlightedChapter] = useState(scrRef.chapterNum ?? 0);\n const [highlightedBookId, setHighlightedBookId] = useState(\n Canon.bookNumberToId(scrRef.bookNum),\n );\n const [isContentOpen, setIsContentOpen] = useState(false);\n const [isContentOpenDelayed, setIsContentOpenDelayed] = useState(isContentOpen);\n\n // This ref will always be defined\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const inputRef = useRef(undefined!);\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const contentRef = useRef(undefined!);\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const menuItemRef = useRef(undefined!);\n\n const fetchFilteredBooks = useCallback(\n (bookType: BookType) => {\n return fetchGroupedBooks(bookType).filter((bookId: string) => {\n const englishNameLowerCase = Canon.bookIdToEnglishName(bookId).toLowerCase();\n const normalizedQuery = searchQuery.replace(/[^a-zA-Z]/g, '').toLowerCase();\n return (\n englishNameLowerCase.includes(normalizedQuery) || // Match book name\n bookId.toLowerCase().includes(normalizedQuery) // Match book ID\n );\n });\n },\n [searchQuery],\n );\n\n const handleSearchInput = (searchString: string) => {\n setSearchQuery(searchString);\n };\n\n /**\n * Whether to prevent radix's logic from closing the dropdown. This is important because radix\n * tries to close the dropdown when the input first focuses, and we don't want it to do that. But\n * we don't want to prevent the dropdown from closing when we click away from the input, so we\n * don't want to just keep it open if the input is focused\n */\n const shouldPreventAutoClosing = useRef(false);\n\n const controlMenuState = useCallback((open: boolean) => {\n if (shouldPreventAutoClosing.current) {\n shouldPreventAutoClosing.current = false;\n return;\n }\n setIsContentOpen(open);\n }, []);\n\n const updateReference = useCallback(\n (bookId: string, shouldClose: boolean, chapter?: number, verse?: number) => {\n setHighlightedChapter(\n Canon.bookNumberToId(scrRef.bookNum) !== bookId ? 1 : scrRef.chapterNum,\n );\n\n if (shouldClose || fetchEndChapter(bookId) === -1) {\n handleSubmit({\n bookNum: Canon.bookIdToNumber(bookId),\n chapterNum: chapter || 1,\n verseNum: verse || 1,\n });\n\n setIsContentOpen(false);\n setSearchQuery('');\n return;\n }\n\n setSelectedBookId(selectedBookId !== bookId ? bookId : '');\n setIsContentOpen(!shouldClose);\n },\n [handleSubmit, scrRef.bookNum, scrRef.chapterNum, selectedBookId],\n );\n\n const handleSelectChapter = (chapterNumber: number) => {\n if (chapterNumber <= 0 || chapterNumber > fetchEndChapter(selectedBookId)) {\n return;\n }\n updateReference(selectedBookId, true, chapterNumber);\n };\n\n const handleInputSubmit = useCallback(() => {\n SEARCH_QUERY_FORMATS.forEach((format) => {\n const matches = searchQuery.match(format);\n if (matches) {\n // Book should be a bookId or an english name\n const [book, chapter = undefined, verse = undefined] = matches.slice(1);\n const englishName = getBookIdFromEnglishName(book);\n\n if (Canon.isBookIdValid(book) || englishName) {\n updateReference(\n englishName ?? book,\n true,\n chapter ? parseInt(chapter, 10) : 1,\n verse ? parseInt(verse, 10) : 1,\n );\n }\n }\n });\n }, [updateReference, searchQuery]);\n\n const handleKeyDownInput = useCallback(\n (event: ReactKeyboardEvent) => {\n if (!isContentOpen) {\n setIsContentOpen(true);\n } else if (event.key === 'ArrowDown' || event.key === 'ArrowUp') {\n if (\n typeof menuItemRef !== 'undefined' &&\n // Ref uses null\n // eslint-disable-next-line no-null/no-null\n menuItemRef.current !== null\n ) {\n menuItemRef.current.focus();\n } else if (\n typeof contentRef !== 'undefined' &&\n // Ref uses null\n // eslint-disable-next-line no-null/no-null\n contentRef.current !== null\n ) {\n contentRef.current.focus();\n }\n event.preventDefault();\n }\n },\n [isContentOpen],\n );\n\n const handleKeyDownContent = (event: ReactKeyboardEvent) => {\n // When the dropdown menu has focus, key strokes should give focus to the input component,\n // unless they're navigation keys (arrows and enter)\n const { key } = event;\n if (\n key === 'ArrowRight' ||\n key === 'ArrowLeft' ||\n key === 'ArrowDown' ||\n key === 'ArrowUp' ||\n key === 'Enter'\n ) {\n return;\n }\n\n inputRef.current.dispatchEvent(new KeyboardEvent('keydown', { key }));\n inputRef.current.focus();\n };\n\n const handleKeyDownMenuItem = (event: ReactKeyboardEvent) => {\n const { key } = event;\n if (highlightedBookId === selectedBookId) {\n if (key === 'Enter') {\n event.preventDefault();\n updateReference(selectedBookId, true, highlightedChapter);\n return;\n }\n\n let chapterOffSet = 0;\n if (key === 'ArrowRight') {\n if (highlightedChapter < fetchEndChapter(highlightedBookId)) {\n chapterOffSet = 1;\n } else {\n event.preventDefault();\n return;\n }\n } else if (key === 'ArrowLeft') {\n if (highlightedChapter > 1) {\n chapterOffSet = -1;\n } else {\n event.preventDefault();\n return;\n }\n } else if (key === 'ArrowDown') {\n chapterOffSet = 6;\n } else if (key === 'ArrowUp') {\n chapterOffSet = -6;\n }\n if (\n highlightedChapter + chapterOffSet <= 0 ||\n highlightedChapter + chapterOffSet > fetchEndChapter(highlightedBookId)\n ) {\n setHighlightedChapter(0);\n } else if (chapterOffSet !== 0) {\n setHighlightedChapter(highlightedChapter + chapterOffSet);\n event.preventDefault();\n }\n }\n };\n\n useEffect(() => {\n if (selectedBookId === highlightedBookId) {\n if (selectedBookId === Canon.bookNumberToId(scrRef.bookNum)) {\n setHighlightedChapter(scrRef.chapterNum);\n } else {\n setHighlightedChapter(1);\n }\n } else {\n setHighlightedChapter(0);\n }\n }, [highlightedBookId, scrRef.bookNum, scrRef.chapterNum, selectedBookId]);\n\n // The purpose of these useLayoutEffects and timeout is to delay the scroll just\n // enough so that the refs are defined and available when they are used after the timeout\n useLayoutEffect(() => {\n setIsContentOpenDelayed(isContentOpen);\n }, [isContentOpen]);\n\n useLayoutEffect(() => {\n const scrollTimeout = setTimeout(() => {\n if (isContentOpenDelayed && contentRef.current && menuItemRef.current) {\n const menuItemOffsetTop = menuItemRef.current.offsetTop;\n const scrollPosition = menuItemOffsetTop - SCROLL_OFFSET;\n contentRef.current.scrollTo({ top: scrollPosition, behavior: 'instant' });\n }\n }, 10);\n return () => {\n clearTimeout(scrollTimeout);\n };\n }, [isContentOpenDelayed]);\n\n return (\n
    \n \n \n {\n setSelectedBookId(Canon.bookNumberToId(scrRef.bookNum));\n setHighlightedBookId(Canon.bookNumberToId(scrRef.bookNum));\n setHighlightedChapter(scrRef.chapterNum > 0 ? scrRef.chapterNum : 0);\n setIsContentOpen(true);\n inputRef.current.focus();\n }}\n onFocus={() => {\n // Radix thinks we want to close because the input is being focused. Prevent that\n shouldPreventAutoClosing.current = true;\n }}\n handleSubmit={handleInputSubmit}\n placeholder={`${Canon.bookNumberToEnglishName(scrRef.bookNum)} ${scrRef.chapterNum}:${scrRef.verseNum}`}\n />\n \n \n console.log('sorting')}\n handleLocationHistory={() => console.log('location history')}\n handleBookmarks={() => console.log('bookmarks')}\n />\n {BOOK_TYPE_ARRAY.map(\n (bookType, bookTypeIndex) =>\n fetchFilteredBooks(bookType).length > 0 && (\n
    \n \n {BOOK_TYPE_LABELS[bookType]}\n \n\n {fetchFilteredBooks(bookType).map((bookId) => (\n
    \n updateReference(bookId, false)}\n isSelected={selectedBookId === bookId}\n handleHighlightBook={() => setHighlightedBookId(bookId)}\n handleKeyDown={handleKeyDownMenuItem}\n bookType={bookType}\n ref={(element: HTMLDivElement) => {\n if (selectedBookId === bookId) menuItemRef.current = element;\n }}\n >\n {\n setHighlightedChapter(chapterNumber);\n }}\n />\n \n
    \n ))}\n {BOOK_TYPE_ARRAY.length - 1 !== bookTypeIndex ? (\n \n ) : undefined}\n
    \n ),\n )}\n \n
    \n
    \n );\n}\n\nexport default BookChapterControl;\n","import React from 'react';\nimport { Slot } from '@radix-ui/react-slot';\nimport { cva, type VariantProps } from 'class-variance-authority';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport const buttonVariants = cva(\n 'pr-twp tw-inline-flex tw-items-center tw-justify-center tw-whitespace-nowrap tw-rounded-md tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-colors focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50',\n {\n variants: {\n variant: {\n default: 'tw-bg-primary tw-text-primary-foreground hover:tw-bg-primary/90',\n destructive: 'tw-bg-destructive tw-text-destructive-foreground hover:tw-bg-destructive/90',\n outline:\n 'tw-border tw-border-input tw-bg-background hover:tw-bg-accent hover:tw-text-accent-foreground',\n secondary: 'tw-bg-secondary tw-text-secondary-foreground hover:tw-bg-secondary/80',\n ghost: 'hover:tw-bg-accent hover:tw-text-accent-foreground',\n link: 'tw-text-primary tw-underline-offset-4 hover:tw-underline',\n },\n size: {\n default: 'tw-h-10 tw-px-4 tw-py-2',\n sm: 'tw-h-9 tw-rounded-md tw-px-3',\n lg: 'tw-h-11 tw-rounded-md tw-px-8',\n icon: 'tw-h-10 tw-w-10',\n },\n },\n defaultVariants: {\n variant: 'default',\n size: 'default',\n },\n },\n);\n\nexport interface ButtonProps\n extends React.ButtonHTMLAttributes,\n VariantProps {\n asChild?: boolean;\n}\n\nexport const Button = React.forwardRef(\n ({ className, variant, size, asChild = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'button';\n return (\n \n );\n },\n);\nButton.displayName = 'Button';\n","import React from 'react';\nimport * as LabelPrimitive from '@radix-ui/react-label';\nimport { cva, type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst labelVariants = cva(\n 'tw-text-sm tw-font-medium tw-leading-none peer-disabled:tw-cursor-not-allowed peer-disabled:tw-opacity-70',\n);\n\nexport const Label = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef & VariantProps\n>(({ className, ...props }, ref) => (\n \n));\nLabel.displayName = LabelPrimitive.Root.displayName;\n","import React from 'react';\nimport * as RadioGroupPrimitive from '@radix-ui/react-radio-group';\nimport { Circle } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst RadioGroup = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => {\n return (\n \n );\n});\nRadioGroup.displayName = RadioGroupPrimitive.Root.displayName;\n\nconst RadioGroupItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => {\n return (\n \n \n \n \n \n );\n});\nRadioGroupItem.displayName = RadioGroupPrimitive.Item.displayName;\n\nexport { RadioGroup, RadioGroupItem };\n","import React from 'react';\nimport * as PopoverPrimitive from '@radix-ui/react-popover';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Popover = PopoverPrimitive.Root;\n\nconst PopoverTrigger = PopoverPrimitive.Trigger;\n\nconst PopoverContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, align = 'center', sideOffset = 4, ...props }, ref) => (\n \n \n \n));\nPopoverContent.displayName = PopoverPrimitive.Content.displayName;\n\nexport { Popover, PopoverTrigger, PopoverContent };\n","import React from 'react';\nimport * as DialogPrimitive from '@radix-ui/react-dialog';\nimport { X } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Dialog = DialogPrimitive.Root;\n\nconst DialogTrigger = DialogPrimitive.Trigger;\n\nconst DialogPortal = DialogPrimitive.Portal;\n\nconst DialogClose = DialogPrimitive.Close;\n\nconst DialogOverlay = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nDialogOverlay.displayName = DialogPrimitive.Overlay.displayName;\n\nconst DialogContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, ...props }, ref) => (\n \n \n \n {children}\n \n \n Close\n \n \n \n));\nDialogContent.displayName = DialogPrimitive.Content.displayName;\n\nfunction DialogHeader({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nDialogHeader.displayName = 'DialogHeader';\n\nfunction DialogFooter({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nDialogFooter.displayName = 'DialogFooter';\n\nconst DialogTitle = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nDialogTitle.displayName = DialogPrimitive.Title.displayName;\n\nconst DialogDescription = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nDialogDescription.displayName = DialogPrimitive.Description.displayName;\n\nexport {\n Dialog,\n DialogPortal,\n DialogOverlay,\n DialogClose,\n DialogTrigger,\n DialogContent,\n DialogHeader,\n DialogFooter,\n DialogTitle,\n DialogDescription,\n};\n","import React from 'react';\nimport { type DialogProps } from '@radix-ui/react-dialog';\nimport { Command as CommandPrimitive } from 'cmdk';\nimport { Search } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Dialog, DialogContent } from '@/components/shadcn-ui/dialog';\n\nconst Command = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nCommand.displayName = CommandPrimitive.displayName;\n\ninterface CommandDialogProps extends DialogProps {}\n\nfunction CommandDialog({ children, ...props }: CommandDialogProps) {\n return (\n \n \n \n {children}\n \n \n \n );\n}\n\nconst CommandInput = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n
    \n \n \n
    \n));\n\nCommandInput.displayName = CommandPrimitive.Input.displayName;\n\nconst CommandList = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\n\nCommandList.displayName = CommandPrimitive.List.displayName;\n\nconst CommandEmpty = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>((props, ref) => (\n \n));\n\nCommandEmpty.displayName = CommandPrimitive.Empty.displayName;\n\nconst CommandGroup = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\n\nCommandGroup.displayName = CommandPrimitive.Group.displayName;\n\nconst CommandSeparator = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nCommandSeparator.displayName = CommandPrimitive.Separator.displayName;\n\nconst CommandItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\n\nCommandItem.displayName = CommandPrimitive.Item.displayName;\n\nfunction CommandShortcut({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nCommandShortcut.displayName = 'CommandShortcut';\n\nexport {\n Command,\n CommandDialog,\n CommandInput,\n CommandList,\n CommandEmpty,\n CommandGroup,\n CommandItem,\n CommandShortcut,\n CommandSeparator,\n};\n","import { useState } from 'react';\nimport { Check, ChevronsUpDown } from 'lucide-react';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport { Popover, PopoverContent, PopoverTrigger } from '@/components/shadcn-ui/popover';\nimport {\n Command,\n CommandEmpty,\n CommandInput,\n CommandItem,\n CommandList,\n} from '@/components/shadcn-ui/command';\nimport { PopoverProps } from '@radix-ui/react-popover';\n\nexport type ComboBoxLabelOption = { label: string };\nexport type ComboBoxOption = string | number | ComboBoxLabelOption;\n\nexport type ComboBoxProps = {\n /** Optional unique identifier */\n id?: string;\n /** Text label title for combobox */\n /** List of available options for the dropdown menu */\n options?: readonly T[];\n /** Additional css classes to help with unique styling of the combo box */\n className?: string;\n /**\n * The selected value that the combo box currently holds. Must be shallow equal to one of the\n * options entries.\n */\n value?: T;\n /** Triggers when content of textfield is changed */\n onChange?: (newValue: T) => void;\n /** Used to determine the string value for a given option. */\n getOptionLabel?: (option: ComboBoxOption) => string;\n /** Text displayed on button if `value` is undefined */\n buttonPlaceholder?: string;\n /** Placeholder text for text field */\n textPlaceholder?: string;\n /** Text to display when no options match input */\n commandEmptyMessage?: string;\n /** Variant of button */\n buttonVariant?: ButtonProps['variant'];\n /** Text direction ltr or rtl */\n dir?: Direction;\n /** Optional boolean to set if trigger should be disabled */\n isDisabled?: boolean;\n} & PopoverProps;\n\ntype Direction = 'ltr' | 'rtl';\n\nfunction getOptionLabelDefault(option: ComboBoxOption): string {\n if (typeof option === 'string') {\n return option;\n }\n if (typeof option === 'number') {\n return option.toString();\n }\n return option.label;\n}\n\n/**\n * Autocomplete input and command palette with a list of suggestions.\n *\n * Thanks to Shadcn for heavy inspiration and documentation\n * https://ui.shadcn.com/docs/components/combobox\n */\nfunction ComboBox({\n id,\n options = [],\n className,\n value,\n onChange = () => {},\n getOptionLabel = getOptionLabelDefault,\n buttonPlaceholder = '',\n textPlaceholder = '',\n commandEmptyMessage = 'No option found',\n buttonVariant = 'outline',\n dir = 'ltr',\n isDisabled = false,\n ...props\n}: ComboBoxProps) {\n const [open, setOpen] = useState(false);\n\n return (\n \n \n \n \n {value ? getOptionLabel(value) : buttonPlaceholder}\n \n \n \n \n \n \n \n {commandEmptyMessage}\n \n {options.map((option) => (\n {\n onChange(option);\n setOpen(false);\n }}\n >\n \n {getOptionLabel(option)}\n \n ))}\n \n \n \n \n );\n}\n\nexport default ComboBox;\n","import { useMemo } from 'react';\nimport ComboBox from '@/components/basics/combo-box.component';\nimport { Label } from '@/components/shadcn-ui/label';\n\nexport type ChapterRangeSelectorProps = {\n startChapter: number;\n endChapter: number;\n handleSelectStartChapter: (chapter: number) => void;\n handleSelectEndChapter: (chapter: number) => void;\n isDisabled?: boolean;\n chapterCount: number;\n};\n\nexport default function ChapterRangeSelector({\n startChapter,\n endChapter,\n handleSelectStartChapter,\n handleSelectEndChapter,\n isDisabled = false,\n chapterCount,\n}: ChapterRangeSelectorProps) {\n const chapterOptions = useMemo(\n () => Array.from({ length: chapterCount }, (_, index) => index + 1),\n [chapterCount],\n );\n\n const onChangeStartChapter = (value: number) => {\n handleSelectStartChapter(value);\n if (value > endChapter) {\n handleSelectEndChapter(value);\n }\n };\n\n const onChangeEndChapter = (value: number) => {\n handleSelectEndChapter(value);\n if (value < startChapter) {\n handleSelectStartChapter(value);\n }\n };\n\n return (\n <>\n \n option.toString()}\n value={startChapter}\n />\n\n \n option.toString()}\n value={endChapter}\n />\n \n );\n}\n","import { Button } from '@/components/shadcn-ui/button';\nimport { Label } from '@/components/shadcn-ui/label';\nimport { RadioGroup, RadioGroupItem } from '@/components/shadcn-ui/radio-group';\nimport { Canon } from '@sillsdev/scripture';\nimport { LocalizedStringValue } from 'platform-bible-utils';\nimport { useState } from 'react';\nimport ChapterRangeSelector, {\n ChapterRangeSelectorProps,\n} from '../basics/chapter-range-selector.component';\n\nexport enum BookSelectionMode {\n CURRENT_BOOK = 'current book',\n CHOOSE_BOOKS = 'choose books',\n}\n\n/**\n * Object containing all keys used for localization in this component. If you're using this\n * component in an extension, you can pass it into the useLocalizedStrings hook to easily obtain the\n * localized strings and pass them into the localizedStrings prop of this component\n */\nexport const BOOK_SELECTOR_STRING_KEYS = Object.freeze([\n '%webView_bookSelector_currentBook%',\n '%webView_bookSelector_choose%',\n '%webView_bookSelector_chooseBooks%',\n] as const);\n\nexport type BookSelectorLocalizedStrings = {\n [localizedInventoryKey in (typeof BOOK_SELECTOR_STRING_KEYS)[number]]?: LocalizedStringValue;\n};\n\n/**\n * Gets the localized value for the provided key\n *\n * @param strings Object containing localized string\n * @param key Key for a localized string\n * @returns The localized value for the provided key, if available. Returns the key if no localized\n * value is available\n */\nconst localizeString = (\n strings: BookSelectorLocalizedStrings,\n key: keyof BookSelectorLocalizedStrings,\n) => {\n return strings[key] ?? key;\n};\n\ntype BookSelectorProps = ChapterRangeSelectorProps & {\n handleBookSelectionModeChange: (newMode: BookSelectionMode) => void;\n currentBookName: string;\n onSelectBooks: () => void;\n selectedBookIds: string[];\n localizedStrings: BookSelectorLocalizedStrings;\n};\n\nexport default function BookSelector({\n handleBookSelectionModeChange,\n currentBookName,\n onSelectBooks,\n selectedBookIds,\n chapterCount,\n endChapter,\n handleSelectEndChapter,\n startChapter,\n handleSelectStartChapter,\n localizedStrings,\n}: BookSelectorProps) {\n const currentBookText = localizeString(localizedStrings, '%webView_bookSelector_currentBook%');\n const chooseText = localizeString(localizedStrings, '%webView_bookSelector_choose%');\n const chooseBooksText = localizeString(localizedStrings, '%webView_bookSelector_chooseBooks%');\n\n const [bookSelectionMode, setBookSelectionMode] = useState(\n BookSelectionMode.CURRENT_BOOK,\n );\n\n const onSelectionModeChange = (newMode: BookSelectionMode) => {\n setBookSelectionMode(newMode);\n handleBookSelectionModeChange(newMode);\n };\n\n return (\n onSelectionModeChange(value as BookSelectionMode)}\n >\n
    \n
    \n
    \n \n \n
    \n \n
    \n \n
    \n
    \n
    \n
    \n \n \n
    \n \n onSelectBooks()}\n >\n {chooseText}\n \n
    \n
    \n \n );\n}\n","import { DropdownMenuTrigger } from '@radix-ui/react-dropdown-menu';\nimport { FilterIcon } from 'lucide-react';\nimport { Table } from '@tanstack/react-table';\n\nimport { Button } from '@/components/shadcn-ui/button';\nimport {\n DropdownMenu,\n DropdownMenuCheckboxItem,\n DropdownMenuContent,\n DropdownMenuLabel,\n DropdownMenuSeparator,\n} from '@/components/shadcn-ui/dropdown-menu';\n\ninterface DataTableViewOptionsProps {\n table: Table;\n}\n\nfunction DataTableViewOptions({ table }: DataTableViewOptionsProps) {\n return (\n \n \n \n \n \n Toggle columns\n \n {table\n .getAllColumns()\n .filter((column) => column.getCanHide())\n .map((column) => {\n return (\n column.toggleVisibility(!!value)}\n >\n {column.id}\n \n );\n })}\n \n \n );\n}\n\nexport default DataTableViewOptions;\n","import React from 'react';\nimport * as SelectPrimitive from '@radix-ui/react-select';\nimport { Check, ChevronDown, ChevronUp } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Select = SelectPrimitive.Root;\n\nconst SelectGroup = SelectPrimitive.Group;\n\nconst SelectValue = SelectPrimitive.Value;\n\nconst SelectTrigger = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, ...props }, ref) => (\n span]:tw-line-clamp-1',\n className,\n )}\n {...props}\n >\n {children}\n \n \n \n \n));\nSelectTrigger.displayName = SelectPrimitive.Trigger.displayName;\n\nconst SelectScrollUpButton = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n));\nSelectScrollUpButton.displayName = SelectPrimitive.ScrollUpButton.displayName;\n\nconst SelectScrollDownButton = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n));\nSelectScrollDownButton.displayName = SelectPrimitive.ScrollDownButton.displayName;\n\nconst SelectContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, position = 'popper', ...props }, ref) => (\n \n \n \n \n {children}\n \n \n \n \n));\nSelectContent.displayName = SelectPrimitive.Content.displayName;\n\nconst SelectLabel = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSelectLabel.displayName = SelectPrimitive.Label.displayName;\n\nconst SelectItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, ...props }, ref) => (\n \n \n \n \n \n \n\n {children}\n \n));\nSelectItem.displayName = SelectPrimitive.Item.displayName;\n\nconst SelectSeparator = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSelectSeparator.displayName = SelectPrimitive.Separator.displayName;\n\nexport {\n Select,\n SelectGroup,\n SelectValue,\n SelectTrigger,\n SelectContent,\n SelectLabel,\n SelectItem,\n SelectSeparator,\n SelectScrollUpButton,\n SelectScrollDownButton,\n};\n","import { ChevronLeftIcon, ChevronRightIcon, ArrowLeftIcon, ArrowRightIcon } from 'lucide-react';\nimport { Table } from '@tanstack/react-table';\n\nimport { Button } from '@/components/shadcn-ui/button';\nimport {\n Select,\n SelectContent,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\n\ninterface DataTablePaginationProps {\n table: Table;\n}\n\nfunction DataTablePagination({ table }: DataTablePaginationProps) {\n return (\n
    \n
    \n
    \n {table.getFilteredSelectedRowModel().rows.length} of{' '}\n {table.getFilteredRowModel().rows.length} row(s) selected\n
    \n
    \n

    Rows per page

    \n {\n table.setPageSize(Number(value));\n }}\n >\n \n \n \n \n {[10, 20, 30, 40, 50].map((pageSize) => (\n \n {pageSize}\n \n ))}\n \n \n
    \n
    \n Page {table.getState().pagination.pageIndex + 1} of {table.getPageCount()}\n
    \n
    \n table.setPageIndex(0)}\n disabled={!table.getCanPreviousPage()}\n >\n Go to first page\n \n \n table.previousPage()}\n disabled={!table.getCanPreviousPage()}\n >\n Go to previous page\n \n \n table.nextPage()}\n disabled={!table.getCanNextPage()}\n >\n Go to next page\n \n \n table.setPageIndex(table.getPageCount() - 1)}\n disabled={!table.getCanNextPage()}\n >\n Go to last page\n \n \n
    \n
    \n
    \n );\n}\n\nexport default DataTablePagination;\n","import React from 'react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Table = React.forwardRef<\n HTMLTableElement,\n React.HTMLAttributes & { stickyHeader?: boolean }\n>(({ className, stickyHeader, ...props }, ref) => (\n
    \n \n
    \n));\nTable.displayName = 'Table';\n\nconst TableHeader = React.forwardRef<\n HTMLTableSectionElement,\n React.HTMLAttributes & { stickyHeader?: boolean }\n>(({ className, stickyHeader, ...props }, ref) => (\n \n));\nTableHeader.displayName = 'TableHeader';\n\nconst TableBody = React.forwardRef<\n HTMLTableSectionElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableBody.displayName = 'TableBody';\n\nconst TableFooter = React.forwardRef<\n HTMLTableSectionElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n tr]:last:tw-border-b-0', className)}\n {...props}\n />\n));\nTableFooter.displayName = 'TableFooter';\n\nconst TableRow = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nTableRow.displayName = 'TableRow';\n\nconst TableHead = React.forwardRef<\n HTMLTableCellElement,\n React.ThHTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableHead.displayName = 'TableHead';\n\nconst TableCell = React.forwardRef<\n HTMLTableCellElement,\n React.TdHTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableCell.displayName = 'TableCell';\n\nconst TableCaption = React.forwardRef<\n HTMLTableCaptionElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableCaption.displayName = 'TableCaption';\n\nexport { Table, TableHeader, TableBody, TableFooter, TableHead, TableRow, TableCell, TableCaption };\n","import { useState } from 'react';\n\nimport {\n ColumnFiltersState,\n flexRender,\n getCoreRowModel,\n getFilteredRowModel,\n getPaginationRowModel,\n getSortedRowModel,\n SortingState,\n ColumnDef as TSColumnDef,\n Row as TSRow,\n RowSelectionState as TSRowSelectionState,\n SortDirection as TSSortDirection,\n Table as TSTable,\n useReactTable,\n VisibilityState,\n} from '@tanstack/react-table';\n\nimport DataTableViewOptions from '@/components/advanced/data-table/data-table-column-toggle.component';\nimport DataTablePagination from '@/components/advanced/data-table/data-table-pagination.component';\nimport { Button } from '@/components/shadcn-ui/button';\nimport {\n Table,\n TableBody,\n TableCell,\n TableHead,\n TableHeader,\n TableRow,\n} from '@/components/shadcn-ui/table';\n\nexport type ColumnDef = TSColumnDef;\nexport type RowContents = TSRow;\nexport type TableContents = TSTable;\nexport type SortDirection = TSSortDirection;\nexport type RowSelectionState = TSRowSelectionState;\n\ninterface DataTableProps {\n columns: ColumnDef[];\n data: TData[];\n enablePagination?: boolean;\n showPaginationControls?: boolean;\n showColumnVisibilityControls?: boolean;\n stickyHeader?: boolean;\n onRowClickHandler?: (row: RowContents, table: TableContents) => void;\n}\n\n/**\n * Feature-rich table component that infuses our basic shadcn-based Table component with features\n * from TanStack's React Table library\n */\nfunction DataTable({\n columns,\n data,\n enablePagination = false,\n showPaginationControls = false,\n showColumnVisibilityControls = false,\n stickyHeader = false,\n onRowClickHandler = () => {},\n}: DataTableProps) {\n const [sorting, setSorting] = useState([]);\n const [columnFilters, setColumnFilters] = useState([]);\n const [columnVisibility, setColumnVisibility] = useState({});\n const [rowSelection, setRowSelection] = useState({});\n\n const table = useReactTable({\n data,\n columns,\n getCoreRowModel: getCoreRowModel(),\n ...(enablePagination && { getPaginationRowModel: getPaginationRowModel() }),\n onSortingChange: setSorting,\n getSortedRowModel: getSortedRowModel(),\n onColumnFiltersChange: setColumnFilters,\n getFilteredRowModel: getFilteredRowModel(),\n onColumnVisibilityChange: setColumnVisibility,\n onRowSelectionChange: setRowSelection,\n state: {\n sorting,\n columnFilters,\n columnVisibility,\n rowSelection,\n },\n });\n\n return (\n
    \n {showColumnVisibilityControls && }\n \n \n {table.getHeaderGroups().map((headerGroup) => (\n \n {headerGroup.headers.map((header) => {\n return (\n \n {header.isPlaceholder\n ? undefined\n : flexRender(header.column.columnDef.header, header.getContext())}\n \n );\n })}\n \n ))}\n \n \n {table.getRowModel().rows?.length ? (\n table.getRowModel().rows.map((row) => (\n onRowClickHandler(row, table)}\n key={row.id}\n data-state={row.getIsSelected() && 'selected'}\n >\n {row.getVisibleCells().map((cell) => (\n \n {flexRender(cell.column.columnDef.cell, cell.getContext())}\n \n ))}\n \n ))\n ) : (\n \n \n No results.\n \n \n )}\n \n
    \n {enablePagination && (\n
    \n table.previousPage()}\n disabled={!table.getCanPreviousPage()}\n >\n Previous\n \n table.nextPage()}\n disabled={!table.getCanNextPage()}\n >\n Next\n \n
    \n )}\n {enablePagination && showPaginationControls && }\n
    \n );\n}\n\nexport default DataTable;\n","import {\n Table,\n TableBody,\n TableCell,\n TableHead,\n TableHeader,\n TableRow,\n} from '@/components/shadcn-ui/table';\nimport { Canon } from '@sillsdev/scripture';\nimport { deepEqual, LanguageStrings, ScriptureReference } from 'platform-bible-utils';\nimport { useMemo } from 'react';\nimport { InventoryItemOccurrence } from './inventory-utils';\n\n/** Props for the OccurrencesTable component */\ntype OccurrencesTableProps = {\n /** Data that contains scriptures references and snippets of scripture */\n occurrenceData: InventoryItemOccurrence[];\n /** Callback function that is executed when the scripture reference is changed */\n setScriptureReference: (scriptureReference: ScriptureReference) => void;\n /**\n * Object with all localized strings that the OccurrencesTable needs to work well across multiple\n * languages\n */\n localizedStrings: LanguageStrings;\n};\n\n/**\n * Table that shows occurrences of specified inventory item(s). The first column shows the related\n * scripture reference. The second column shows the snippet of scripture that contains the specified\n * inventory item\n */\nfunction OccurrencesTable({\n occurrenceData,\n setScriptureReference,\n localizedStrings,\n}: OccurrencesTableProps) {\n const referenceHeaderText =\n localizedStrings['%webView_inventory_occurrences_table_header_reference%'];\n const occurrenceHeaderText =\n localizedStrings['%webView_inventory_occurrences_table_header_occurrence%'];\n\n const occurrences: InventoryItemOccurrence[] = useMemo(() => {\n const uniqueOccurrences: InventoryItemOccurrence[] = [];\n\n occurrenceData.forEach((occurrence) => {\n if (!uniqueOccurrences.some((uniqueOccurrence) => deepEqual(uniqueOccurrence, occurrence))) {\n uniqueOccurrences.push(occurrence);\n }\n });\n\n return uniqueOccurrences;\n }, [occurrenceData]);\n\n return (\n \n \n \n {referenceHeaderText}\n {occurrenceHeaderText}\n \n \n \n {occurrences.length > 0 &&\n occurrences.map((occurrence) => (\n {\n setScriptureReference(occurrence.reference);\n }}\n >\n {`${Canon.bookNumberToEnglishName(occurrence.reference.bookNum)} ${occurrence.reference.chapterNum}:${occurrence.reference.verseNum}`}\n {occurrence.text}\n \n ))}\n \n
    \n );\n}\n\nexport default OccurrencesTable;\n","import React from 'react';\nimport * as CheckboxPrimitive from '@radix-ui/react-checkbox';\nimport { Check } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Checkbox = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n \n \n));\nCheckbox.displayName = CheckboxPrimitive.Root.displayName;\n\nexport default Checkbox;\n","import { Canon } from '@sillsdev/scripture';\nimport { ScriptureReference } from 'platform-bible-utils';\n\n/* #region Types */\n\n/**\n * Status of items that appear in inventories. 'approved' and 'unapproved' items are defined in the\n * project's `Settings.xml`. All other items are defined as 'unknown'\n */\nexport type Status = 'approved' | 'unapproved' | 'unknown';\n\n/** Occurrence of item in inventory. Primarily used by table that shows occurrences */\nexport type InventoryItemOccurrence = {\n /** Reference to scripture where the item appears */\n reference: ScriptureReference;\n /** Snippet of scripture that contains the occurrence */\n text: string;\n};\n\n/** Data structure that contains all information on an item that is shown in an inventory */\nexport type InventoryTableData = {\n /**\n * The item (e.g. a character in the characters inventory, a marker in the marker inventory) In\n * most cases the array will only have one element. In case of additional items (e.g. the\n * preceding marker in the markers check), the primary item should be stored in the first index.\n * To show additional items in the inventory, make sure to configure the `additionalItemsLabels`\n * prop for the Inventory component\n */\n items: string[];\n /** The number of times this item occurs in the selected scope */\n count: number;\n /** The status of this item (see documentation for `Status` type for more information) */\n status: Status;\n /** Occurrences of this item in the scripture text for the selected scope */\n occurrences: InventoryItemOccurrence[];\n};\n\n/* #endregion */\n\n/* #region Functions */\n\n/**\n * Splits USFM string into shorter line-like segments\n *\n * @param text A single (likely very large) USFM string\n * @returns An array containing the input text, split into shorter segments\n */\nexport const getLinesFromUSFM = (text: string) => {\n // Splits on (CR)LF, CR, \\v, \\c and \\id\n return text.split(/(?:\\r?\\n|\\r)|(?=(?:\\\\(?:v|c|id)))/g);\n};\n\n/**\n * Extracts chapter or verse number from USFM strings that start with a \\c or \\v marker\n *\n * @param text USFM string that is expected to start with \\c or \\v marker\n * @returns Chapter or verse number if one is found. Else returns 0.\n */\nexport const getNumberFromUSFM = (text: string): number | undefined => {\n // Captures all digits that follow \\v or \\c markers followed by whitespace located at the start of a string\n const regex = /^\\\\[vc]\\s+(\\d+)/;\n const match = text.match(regex);\n\n if (match) {\n return +match[1];\n }\n return undefined;\n};\n\n/**\n * Gets book ID from USFM string that starts with the \\id marker, and returns book number for it\n *\n * @param text USFM string that is expected to start with \\id marker\n * @returns Book number corresponding to the \\id marker in the input text. Returns 0 if no marker is\n * found or the marker is not valid\n */\nexport const getBookNumFromId = (text: string): number => {\n // Captures all digits that follow an \\id marker followed by whitespace located at the start of a string\n const match = text.match(/^\\\\id\\s+([A-Za-z]+)/);\n if (match) {\n return Canon.bookIdToNumber(match[1]);\n }\n return 0;\n};\n\n/**\n * Gets the status for an item, typically used in the Inventory component\n *\n * @param item The item for which the status is being requested\n * @param approvedItems Array of approved items, typically as defined in `Settings.xml`\n * @param unapprovedItems Array of unapproved items, typically as defined in `Settings.xml`\n * @returns The status for the specified item\n */\nexport const getStatusForItem = (\n item: string,\n approvedItems: string[],\n unapprovedItems: string[],\n): Status => {\n if (unapprovedItems.includes(item)) return 'unapproved';\n if (approvedItems.includes(item)) return 'approved';\n return 'unknown';\n};\n\n/* #endregion */\n","import React from 'react';\nimport * as TogglePrimitive from '@radix-ui/react-toggle';\nimport { cva, type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst toggleVariants = cva(\n 'pr-twp tw-inline-flex tw-items-center tw-justify-center tw-rounded-md tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-colors hover:tw-bg-muted hover:tw-text-muted-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50 data-[state=on]:tw-bg-accent data-[state=on]:tw-text-accent-foreground',\n {\n variants: {\n variant: {\n default: 'tw-bg-transparent',\n outline:\n 'tw-border tw-border-input tw-bg-transparent hover:tw-bg-accent hover:tw-text-accent-foreground',\n },\n size: {\n default: 'tw-h-10 tw-px-3',\n sm: 'tw-h-9 tw-px-2.5',\n lg: 'tw-h-11 tw-px-5',\n },\n },\n defaultVariants: {\n variant: 'default',\n size: 'default',\n },\n },\n);\n\nconst Toggle = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef & VariantProps\n>(({ className, variant, size, ...props }, ref) => (\n \n));\n\nToggle.displayName = TogglePrimitive.Root.displayName;\n\nexport { Toggle, toggleVariants };\n","import React from 'react';\nimport * as ToggleGroupPrimitive from '@radix-ui/react-toggle-group';\nimport { type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { toggleVariants } from '@/components/shadcn-ui/toggle';\n\nconst ToggleGroupContext = React.createContext>({\n size: 'default',\n variant: 'default',\n});\n\nconst ToggleGroup = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef &\n VariantProps\n>(({ className, variant, size, children, ...props }, ref) => (\n \n \n {children}\n \n \n));\n\nToggleGroup.displayName = ToggleGroupPrimitive.Root.displayName;\n\nconst ToggleGroupItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef &\n VariantProps\n>(({ className, children, variant, size, ...props }, ref) => {\n const context = React.useContext(ToggleGroupContext);\n\n return (\n \n {children}\n \n );\n});\n\nToggleGroupItem.displayName = ToggleGroupPrimitive.Item.displayName;\n\nexport { ToggleGroup, ToggleGroupItem };\n","import { ColumnDef, SortDirection } from '@/components/advanced/data-table/data-table.component';\nimport { Button } from '@/components/shadcn-ui/button';\nimport { ToggleGroup, ToggleGroupItem } from '@/components/shadcn-ui/toggle-group';\nimport {\n ArrowDownIcon,\n ArrowUpDownIcon,\n ArrowUpIcon,\n CircleCheckIcon,\n CircleHelpIcon,\n CircleXIcon,\n} from 'lucide-react';\nimport { ReactNode } from 'react';\nimport { InventoryTableData, Status } from './inventory-utils';\n\n/**\n * Gets an icon that indicates the current sorting direction based on the provided input\n *\n * @param sortDirection Sorting direction. Can be ascending ('asc'), descending ('desc') or false (\n * i.e. not sorted)\n * @returns The appropriate sorting icon for the provided sorting direction\n */\nconst getSortingIcon = (sortDirection: false | SortDirection): ReactNode => {\n if (sortDirection === 'asc') {\n return ;\n }\n if (sortDirection === 'desc') {\n return ;\n }\n return ;\n};\n\n/**\n * Function that creates the item column for inventories\n *\n * @param itemLabel Localized label for the item column (e.g. 'Character', 'Repeated Word', etc.)\n * @returns Column that shows the inventory items. Should be used with the DataTable component\n */\nexport const inventoryItemColumn = (itemLabel: string): ColumnDef => {\n return {\n accessorKey: 'item',\n accessorFn: (row: InventoryTableData) => row.items[0],\n header: ({ column }) => (\n \n ),\n };\n};\n\n/**\n * Function that creates the additional item columns for inventories\n *\n * @param additionalItemLabel Localized label for the additional item column (e.g. 'Preceding\n * Marker')\n * @param additionalItemIndex Index that locates the desired item in the items array of the\n * inventory\n * @returns Column that shows additional inventory items. Should be used with the DataTable\n * component\n */\nexport const inventoryAdditionalItemColumn = (\n additionalItemLabel: string,\n additionalItemIndex: number,\n): ColumnDef => {\n return {\n accessorKey: `item${additionalItemIndex}`,\n accessorFn: (row: InventoryTableData) => row.items[additionalItemIndex],\n header: ({ column }) => (\n \n ),\n };\n};\n\n/**\n * Function that creates the count column for inventories. Should be used with the DataTable\n * component.\n *\n * @param itemLabel Localized label for the count column\n * @returns Column that shows the number of occurrences of the related inventory items\n */\nexport const inventoryCountColumn = (countLabel: string): ColumnDef => {\n return {\n accessorKey: 'count',\n header: ({ column }) => (\n
    \n \n
    \n ),\n cell: ({ row }) =>
    {row.getValue('count')}
    ,\n };\n};\n\n/**\n * Function that updates project settings when status for item(s) changes\n *\n * @param changedItems Array of items for which the status is being updated\n * @param newStatus The status that the items are being given\n * @param approvedItems Array of currently approved items\n * @param onApprovedItemsChange Callback function that stores the updated list of approved items\n * @param unapprovedItems Array of currently unapproved items\n * @param onUnapprovedItemsChange Callback function that stores the updated list of unapproved items\n */\nconst statusChangeHandler = (\n changedItems: string[],\n newStatus: Status,\n approvedItems: string[],\n onApprovedItemsChange: (items: string[]) => void,\n unapprovedItems: string[],\n onUnapprovedItemsChange: (items: string[]) => void,\n) => {\n let newApprovedItems: string[] = [...approvedItems];\n changedItems.forEach((item) => {\n if (newStatus === 'approved') {\n if (!newApprovedItems.includes(item)) {\n newApprovedItems.push(item);\n }\n } else {\n newApprovedItems = newApprovedItems.filter((validItem) => validItem !== item);\n }\n });\n onApprovedItemsChange(newApprovedItems);\n\n let newUnapprovedItems: string[] = [...unapprovedItems];\n changedItems.forEach((item) => {\n if (newStatus === 'unapproved') {\n if (!newUnapprovedItems.includes(item)) {\n newUnapprovedItems.push(item);\n }\n } else {\n newUnapprovedItems = newUnapprovedItems.filter((unapprovedItem) => unapprovedItem !== item);\n }\n });\n onUnapprovedItemsChange(newUnapprovedItems);\n};\n\n/**\n * Function that creates the status column for inventories. Should be used with the DataTable\n * component.\n *\n * @param statusLabel Localized label for the status column\n * @param approvedItems Array of approved items, typically as defined in `Settings.xml`\n * @param onApprovedItemsChange Callback function that stores the updated list of approved items\n * @param unapprovedItems Array of unapproved items, typically as defined in `Settings.xml`\n * @param onUnapprovedItemsChange Callback function that stores the updated list of unapproved items\n * @returns Column that shows the status buttons for the related inventory item. The button for the\n * current status of the item is selected\n */\nexport const inventoryStatusColumn = (\n statusLabel: string,\n approvedItems: string[],\n onApprovedItemsChange: (items: string[]) => void,\n unapprovedItems: string[],\n onUnapprovedItemsChange: (items: string[]) => void,\n): ColumnDef => {\n return {\n accessorKey: 'status',\n header: ({ column }) => {\n return (\n
    \n \n
    \n );\n },\n cell: ({ row }) => {\n const status: Status = row.getValue('status');\n const item: string = row.getValue('item');\n return (\n \n \n statusChangeHandler(\n [item],\n 'approved',\n approvedItems,\n onApprovedItemsChange,\n unapprovedItems,\n onUnapprovedItemsChange,\n )\n }\n value=\"approved\"\n >\n \n \n \n statusChangeHandler(\n [item],\n 'unapproved',\n approvedItems,\n onApprovedItemsChange,\n unapprovedItems,\n onUnapprovedItemsChange,\n )\n }\n value=\"unapproved\"\n >\n \n \n \n statusChangeHandler(\n [item],\n 'unknown',\n approvedItems,\n onApprovedItemsChange,\n unapprovedItems,\n onUnapprovedItemsChange,\n )\n }\n value=\"unknown\"\n >\n \n \n \n );\n },\n };\n};\n","import DataTable, {\n ColumnDef,\n RowContents,\n RowSelectionState,\n TableContents,\n} from '@/components/advanced/data-table/data-table.component';\nimport OccurrencesTable from '@/components/advanced/inventory/occurrences-table.component';\nimport Checkbox from '@/components/shadcn-ui/checkbox';\nimport { Input } from '@/components/shadcn-ui/input';\nimport { Label } from '@/components/shadcn-ui/label';\nimport {\n Select,\n SelectContent,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\nimport {\n deepEqual,\n LocalizedStringValue,\n ScriptureReference,\n substring,\n} from 'platform-bible-utils';\nimport { useEffect, useMemo, useState } from 'react';\nimport {\n getBookNumFromId,\n getLinesFromUSFM,\n getNumberFromUSFM,\n getStatusForItem,\n InventoryItemOccurrence,\n InventoryTableData,\n Status,\n} from './inventory-utils';\nimport { inventoryAdditionalItemColumn } from './inventory-columns';\n\n/**\n * Object containing all keys used for localization in this component. If you're using this\n * component in an extension, you can pass it into the useLocalizedStrings hook to easily obtain the\n * localized strings and pass them into the localizedStrings prop of this component\n */\nexport const INVENTORY_STRING_KEYS = Object.freeze([\n '%webView_inventory_all%',\n '%webView_inventory_approved%',\n '%webView_inventory_unapproved%',\n '%webView_inventory_unknown%',\n '%webView_inventory_scope_currentBook%',\n '%webView_inventory_scope_chapter%',\n '%webView_inventory_scope_verse%',\n '%webView_inventory_filter_text%',\n '%webView_inventory_show_additional_items%',\n '%webView_inventory_occurrences_table_header_reference%',\n '%webView_inventory_occurrences_table_header_occurrence%',\n] as const);\n\nexport type InventoryLocalizedStrings = {\n [localizedInventoryKey in (typeof INVENTORY_STRING_KEYS)[number]]?: LocalizedStringValue;\n};\n\n/** Scope of scripture that the inventory can operate on */\nexport type Scope = 'book' | 'chapter' | 'verse';\n\n/** Status values that the status filter can select from */\ntype StatusFilter = Status | 'all';\n\n/** Text labels for the inventory columns and the control components of additional inventory items */\ntype AdditionalItemsLabels = {\n checkboxText?: string;\n tableHeaders?: string[];\n};\n\n/**\n * Filters data that is shown in the DataTable section of the Inventory\n *\n * @param itemData All inventory items and their related information\n * @param statusFilter Allows filtering by status (i.e. show all items, or only items that are\n * 'approved', 'unapproved' or 'unknown')\n * @param textFilter Allows filtering by text. All items that include the filter text will be\n * selected.\n * @returns Array of items and their related information that are matched by the specified filters\n */\nconst filterItemData = (\n itemData: InventoryTableData[],\n statusFilter: StatusFilter,\n textFilter: string,\n): InventoryTableData[] => {\n let filteredItemData: InventoryTableData[] = itemData;\n\n if (statusFilter !== 'all') {\n filteredItemData = filteredItemData.filter(\n (item) =>\n (statusFilter === 'approved' && item.status === 'approved') ||\n (statusFilter === 'unapproved' && item.status === 'unapproved') ||\n (statusFilter === 'unknown' && item.status === 'unknown'),\n );\n }\n\n if (textFilter !== '')\n filteredItemData = filteredItemData.filter((item) => item.items[0].includes(textFilter));\n\n return filteredItemData;\n};\n\n/**\n * Turns array of strings into array of inventory items, along with their count and status\n *\n * @param text The source scripture text that is searched for inventory items\n * @param scriptureRef The scripture reference that the application is currently set to\n * @param approvedItems Array of approved items, typically as defined in `Settings.xml`\n * @param unapprovedItems Array of unapproved items, typically as defined in `Settings.xml`\n * @param itemRegex Regular expression that describes what items this Inventory should extract from\n * the provided scripture text\n * @returns Array of inventory items, along with their count and status\n */\nconst createTableData = (\n text: string | undefined,\n scriptureRef: ScriptureReference,\n approvedItems: string[],\n unapprovedItems: string[],\n itemRegex: RegExp,\n): InventoryTableData[] => {\n if (!text) return [];\n\n const tableData: InventoryTableData[] = [];\n\n let currentBook: number | undefined = scriptureRef.bookNum;\n let currentChapter: number | undefined = scriptureRef.chapterNum;\n let currentVerse: number | undefined = scriptureRef.verseNum;\n\n const lines = getLinesFromUSFM(text);\n\n lines.forEach((line: string) => {\n if (line.startsWith('\\\\id')) {\n currentBook = getBookNumFromId(line);\n currentChapter = 0;\n currentVerse = 0;\n }\n if (line.startsWith('\\\\c')) {\n currentChapter = getNumberFromUSFM(line);\n currentVerse = 0;\n }\n if (line.startsWith('\\\\v')) {\n currentVerse = getNumberFromUSFM(line);\n if (currentChapter === 0) {\n currentChapter = scriptureRef.chapterNum;\n }\n }\n\n let match: RegExpExecArray | undefined = itemRegex.exec(line) ?? undefined;\n while (match) {\n const items: string[] = [];\n match.forEach((item) => items.push(item));\n const itemIndex = match.index;\n const existingItem = tableData.find((tableEntry) => deepEqual(tableEntry.items, items));\n const newReference: InventoryItemOccurrence = {\n reference: {\n bookNum: currentBook !== undefined ? currentBook : -1,\n chapterNum: currentChapter !== undefined ? currentChapter : -1,\n verseNum: currentVerse !== undefined ? currentVerse : -1,\n },\n text: substring(line, Math.max(0, itemIndex - 25), Math.min(itemIndex + 25, line.length)),\n };\n if (existingItem) {\n existingItem.count += 1;\n existingItem.occurrences.push(newReference);\n } else {\n const newItem: InventoryTableData = {\n items,\n count: 1,\n status: getStatusForItem(items[0], approvedItems, unapprovedItems),\n occurrences: [newReference],\n };\n tableData.push(newItem);\n }\n\n match = itemRegex.exec(line) ?? undefined;\n }\n });\n\n return tableData;\n};\n\n/**\n * Gets the localized value for the provided key\n *\n * @param strings Object containing localized string\n * @param key Key for a localized string\n * @returns The localized value for the provided key, if available. Returns the key if no localized\n * value is available\n */\nconst localizeString = (\n strings: InventoryLocalizedStrings,\n key: keyof InventoryLocalizedStrings,\n) => {\n return strings[key] ?? key;\n};\n\n/** Props for the Inventory component */\ntype InventoryProps = {\n /** The scripture reference that the application is currently set to */\n scriptureReference: ScriptureReference;\n /** Callback function that is executed when the scripture reference is changed */\n setScriptureReference: (scriptureReference: ScriptureReference) => void;\n /**\n * Object with all localized strings that the Inventory needs to work well across multiple\n * languages. When using this component with Platform.Bible, you can import\n * `INVENTORY_STRING_KEYS` from this library, pass it in to the Platform's localization hook, and\n * pass the localized keys that are returned by the hook into this prop.\n */\n localizedStrings: InventoryLocalizedStrings;\n /**\n * The logic that finds the desired items in the source text. This can either be a Regular\n * expression that captures one or multiple items (preferred), or a custom function that builds\n * and return an InventoryDataTable[] manually. Note: In case the logic captures more than one\n * item (i.e. InventoryTableData.items has a length greater than 1), you must provide text labels\n * for the related columns and control elements to show by setting the `additionalItemsLabels`\n * prop\n */\n extractItems:\n | RegExp\n | ((\n text: string | undefined,\n scriptureRef: ScriptureReference,\n approvedItems: string[],\n unapprovedItems: string[],\n ) => InventoryTableData[]);\n /**\n * Text labels for control elements and additional column headers in case your Inventory has more\n * than one item to show (e.g. The 'Preceding Marker' in the Markers Inventory)\n */\n additionalItemsLabels?: AdditionalItemsLabels;\n /** Array of approved items, typically as defined in `Settings.xml` */\n approvedItems: string[];\n /** Array of unapproved items, typically as defined in `Settings.xml` */\n unapprovedItems: string[];\n /** The source scripture text that is searched for in inventory items */\n text: string | undefined;\n /** Scope of scripture that the inventory will operate on */\n scope: Scope;\n /** Callback function that is executed when the scope is changed from the Inventory */\n onScopeChange: (scope: Scope) => void;\n /**\n * Column definitions for the Inventory data table. The most commonly used column definitions are\n * pre-configured for your convenience and can be imported (e.g. inventoryItemColumn,\n * inventoryAdditionalItemColumn inventoryCountColumn, and inventoryStatusColumn). If you need any\n * other columns you can add these yourself\n */\n columns: ColumnDef[];\n};\n\n/** Inventory component that is used to view and control the status of provided project settings */\nexport default function Inventory({\n scriptureReference,\n setScriptureReference,\n localizedStrings,\n extractItems,\n additionalItemsLabels,\n approvedItems,\n unapprovedItems,\n text,\n scope,\n onScopeChange,\n columns,\n}: InventoryProps) {\n const allItemsText = localizeString(localizedStrings, '%webView_inventory_all%');\n const approvedItemsText = localizeString(localizedStrings, '%webView_inventory_approved%');\n const unapprovedItemsText = localizeString(localizedStrings, '%webView_inventory_unapproved%');\n const unknownItemsText = localizeString(localizedStrings, '%webView_inventory_unknown%');\n const scopeBookText = localizeString(localizedStrings, '%webView_inventory_scope_currentBook%');\n const scopeChapterText = localizeString(localizedStrings, '%webView_inventory_scope_chapter%');\n const scopeVerseText = localizeString(localizedStrings, '%webView_inventory_scope_verse%');\n const filterText = localizeString(localizedStrings, '%webView_inventory_filter_text%');\n const showAdditionalItemsText = localizeString(\n localizedStrings,\n '%webView_inventory_show_additional_items%',\n );\n\n const [showAdditionalItems, setShowAdditionalItems] = useState(false);\n const [statusFilter, setStatusFilter] = useState('all');\n const [textFilter, setTextFilter] = useState('');\n const [selectedItem, setSelectedItem] = useState([]);\n\n const tableData: InventoryTableData[] = useMemo(() => {\n if (!text) return [];\n if (extractItems instanceof RegExp)\n return createTableData(\n text,\n scriptureReference,\n approvedItems,\n unapprovedItems,\n extractItems,\n );\n return extractItems(text, scriptureReference, approvedItems, unapprovedItems);\n }, [text, extractItems, scriptureReference, approvedItems, unapprovedItems]);\n\n const reducedTableData: InventoryTableData[] = useMemo(() => {\n if (showAdditionalItems) return tableData;\n\n const newTableData: InventoryTableData[] = [];\n\n tableData.forEach((tableEntry) => {\n const firstItem = tableEntry.items[0];\n\n const existingEntry = newTableData.find(\n (newTableEntry) => newTableEntry.items[0] === firstItem,\n );\n\n if (existingEntry) {\n existingEntry.count += tableEntry.count;\n existingEntry.occurrences = existingEntry.occurrences.concat(tableEntry.occurrences);\n } else {\n newTableData.push({\n items: [firstItem],\n count: tableEntry.count,\n occurrences: tableEntry.occurrences,\n status: tableEntry.status,\n });\n }\n });\n\n return newTableData;\n }, [showAdditionalItems, tableData]);\n\n const filteredTableData: InventoryTableData[] = useMemo(() => {\n return filterItemData(reducedTableData, statusFilter, textFilter);\n }, [reducedTableData, statusFilter, textFilter]);\n\n const allColumns: ColumnDef[] = useMemo(() => {\n if (!showAdditionalItems) return columns;\n\n const numberOfAdditionalItems = additionalItemsLabels?.tableHeaders?.length;\n if (!numberOfAdditionalItems) return columns;\n\n const additionalColumns: ColumnDef[] = [];\n\n for (let index = 0; index < numberOfAdditionalItems; index++) {\n additionalColumns.push(\n inventoryAdditionalItemColumn(\n additionalItemsLabels?.tableHeaders?.[index] || 'Additional Item',\n index + 1,\n ),\n );\n }\n\n return [...additionalColumns, ...columns];\n }, [additionalItemsLabels?.tableHeaders, columns, showAdditionalItems]);\n\n useEffect(() => {\n setSelectedItem([]);\n }, [filteredTableData]);\n\n const rowClickHandler = (\n row: RowContents,\n table: TableContents,\n ) => {\n table.setRowSelection(() => {\n const newSelection: RowSelectionState = {};\n newSelection[row.index] = true;\n return newSelection;\n });\n\n setSelectedItem(row.original.items);\n };\n\n const handleScopeChange = (value: string) => {\n if (value === 'book' || value === 'chapter' || value === 'verse') {\n onScopeChange(value);\n } else {\n throw new Error(`Invalid scope value: ${value}`);\n }\n };\n\n const handleStatusFilterChange = (value: string) => {\n if (value === 'all' || value === 'approved' || value === 'unapproved' || value === 'unknown') {\n setStatusFilter(value);\n } else {\n throw new Error(`Invalid status filter value: ${value}`);\n }\n };\n\n const occurrenceData: InventoryItemOccurrence[] = useMemo(() => {\n if (reducedTableData.length === 0 || selectedItem.length === 0) return [];\n const occurrence = reducedTableData.filter((tableEntry: InventoryTableData) => {\n return deepEqual(\n showAdditionalItems ? tableEntry.items : [tableEntry.items[0]],\n selectedItem,\n );\n });\n if (occurrence.length > 1) throw new Error('Selected item is not unique');\n return occurrence[0].occurrences;\n }, [selectedItem, showAdditionalItems, reducedTableData]);\n\n return (\n
    \n
    \n handleStatusFilterChange(value)}\n defaultValue={statusFilter}\n >\n \n \n \n \n {allItemsText}\n {approvedItemsText}\n {unapprovedItemsText}\n {unknownItemsText}\n \n \n \n {\n setTextFilter(event.target.value);\n }}\n />\n {additionalItemsLabels && (\n
    \n {\n setSelectedItem([]);\n setShowAdditionalItems(checked);\n }}\n />\n \n
    \n )}\n
    \n
    \n \n
    \n {occurrenceData.length > 0 && (\n
    \n \n
    \n )}\n
    \n );\n}\n","import { Input } from '@/components/shadcn-ui/input';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { useState } from 'react';\n\nexport type SearchBarProps = {\n /**\n * Callback fired to handle the search query when button pressed\n *\n * @param searchQuery\n */\n onSearch: (searchQuery: string) => void;\n\n /** Optional string that appears in the search bar without a search string */\n placeholder?: string;\n\n /** Optional boolean to set the input base to full width */\n isFullWidth?: boolean;\n};\n\nexport default function SearchBar({ onSearch, placeholder, isFullWidth }: SearchBarProps) {\n const [searchQuery, setSearchQuery] = useState('');\n\n const handleInputChange = (searchString: string) => {\n setSearchQuery(searchString);\n onSearch(searchString);\n };\n\n return (\n handleInputChange(e.target.value)}\n />\n );\n}\n","// adapted from: https://github.com/shadcn-ui/ui/discussions/752\n\n'use client';\n\nimport { TabsContentProps, TabsListProps, TabsTriggerProps } from '@/components/shadcn-ui/tabs';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport * as TabsPrimitive from '@radix-ui/react-tabs';\nimport React from 'react';\n\nexport type VerticalTabsProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport type LeftTabsTriggerProps = TabsTriggerProps & {\n value: string;\n ref?: React.Ref;\n};\n\nexport const VerticalTabs = React.forwardRef<\n React.ElementRef,\n VerticalTabsProps\n>(({ className, ...props }, ref) => (\n \n));\n\nVerticalTabs.displayName = TabsPrimitive.List.displayName;\n\nexport const VerticalTabsList = React.forwardRef<\n React.ElementRef,\n TabsListProps\n>(({ className, ...props }, ref) => (\n \n));\nVerticalTabsList.displayName = TabsPrimitive.List.displayName;\n\nexport const VerticalTabsTrigger = React.forwardRef<\n React.ElementRef,\n LeftTabsTriggerProps\n>(({ className, ...props }, ref) => (\n \n));\n\nexport const VerticalTabsContent = React.forwardRef<\n React.ElementRef,\n TabsContentProps\n>(({ className, ...props }, ref) => (\n \n));\nVerticalTabsContent.displayName = TabsPrimitive.Content.displayName;\n","import SearchBar from '@/components/basics/search-bar.component';\nimport {\n VerticalTabs,\n VerticalTabsContent,\n VerticalTabsList,\n VerticalTabsTrigger,\n} from '@/components/basics/tabs-vertical';\nimport { ReactNode } from 'react';\n\nexport type TabKeyValueContent = {\n key: string;\n value: string;\n content: ReactNode;\n};\n\nexport type NavigationContentSearchProps = {\n /** List of values and keys for each tab this component should provide */\n tabList: TabKeyValueContent[];\n\n /** Handler to run when the value of the search bar changes */\n onSearch: (searchQuery: string) => void;\n\n /** Optional placeholder for the search bar */\n searchPlaceholder?: string;\n\n /** Optional title to include in the header */\n headerTitle?: string;\n\n /** Optional flag to make the search bar appear full width */\n isSearchBarFullWidth?: boolean;\n\n /** Text direction ltr or rtl */\n direction?: 'ltr' | 'rtl';\n};\n\nexport default function NavigationContentSearch({\n tabList,\n onSearch,\n searchPlaceholder,\n headerTitle,\n isSearchBarFullWidth = false,\n direction = 'ltr',\n}: NavigationContentSearchProps) {\n return (\n
    \n
    \n {headerTitle ?

    {headerTitle}

    : ''}\n \n
    \n \n \n {tabList.map((tab) => (\n \n {tab.value}\n \n ))}\n \n {tabList.map((tab) => (\n \n {tab.content}\n \n ))}\n \n
    \n );\n}\n","import { Button } from '@/components/shadcn-ui/button';\nimport {\n Select,\n SelectContent,\n SelectGroup,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\nimport {\n Table,\n TableBody,\n TableCell,\n TableHead,\n TableHeader,\n TableRow,\n} from '@/components/shadcn-ui/table';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Canon } from '@sillsdev/scripture';\nimport {\n Cell,\n ColumnDef,\n flexRender,\n getCoreRowModel,\n getExpandedRowModel,\n getGroupedRowModel,\n getSortedRowModel,\n GroupingState,\n Row,\n RowSelectionState,\n SortingState,\n useReactTable,\n} from '@tanstack/react-table';\nimport '@/components/advanced/scripture-results-viewer/scripture-results-viewer.component.css';\nimport {\n compareScrRefs,\n formatScrRef,\n ScriptureSelection,\n scrRefToBBBCCCVVV,\n} from 'platform-bible-utils';\nimport { MouseEvent, useEffect, useMemo, useState } from 'react';\nimport { ChevronDown, ChevronLeft, ChevronRight } from 'lucide-react';\n\n/**\n * Information (e.g., a checking error or some other type of \"transient\" annotation) about something\n * noteworthy at a specific place in an instance of the Scriptures.\n */\nexport type ScriptureItemDetail = ScriptureSelection & {\n /**\n * Text of the error, note, etc. In the future, we might want to support something more than just\n * text so that a JSX element could be provided with a link or some other controls related to the\n * issue being reported.\n */\n detail: string;\n};\n\n/**\n * A uniquely identifiable source of results that can be displayed in the ScriptureResultsViewer.\n * Generally, the source will be a particular Scripture check, but there may be other types of\n * sources.\n */\nexport type ResultsSource = {\n /**\n * Uniquely identifies the source.\n *\n * @type {string}\n */\n id: string;\n\n /**\n * Name (potentially localized) of the source, suitable for display in the UI.\n *\n * @type {string}\n */\n displayName: string;\n};\n\nexport type ScriptureSrcItemDetail = ScriptureItemDetail & {\n /** Source/type of detail. Can be used for grouping. */\n source: ResultsSource;\n};\n\n/**\n * Represents a set of results keyed by Scripture reference. Generally, the source will be a\n * particular Scripture check, but this type also allows for other types of uniquely identifiable\n * sources.\n */\nexport type ResultsSet = {\n /**\n * The backing source associated with this set of results.\n *\n * @type {ResultsSource}\n */\n source: ResultsSource;\n\n /**\n * Array of Scripture item details (messages keyed by Scripture reference).\n *\n * @type {ScriptureItemDetail[]}\n */\n data: ScriptureItemDetail[];\n};\n\nconst scrBookColId = 'scrBook';\nconst scrRefColId = 'scrRef';\nconst typeColId = 'source';\nconst detailsColId = 'details';\n\nconst defaultScrRefColumnName = 'Scripture Reference';\nconst defaultScrBookGroupName = 'Scripture Book';\nconst defaultTypeColumnName = 'Type';\nconst defaultDetailsColumnName = 'Details';\n\nexport type ScriptureResultsViewerColumnInfo = {\n /** Optional header to display for the Reference column. Default value: 'Scripture Reference'. */\n scriptureReferenceColumnName?: string;\n\n /** Optional text to display to refer to the Scripture book group. Default value: 'Scripture Book'. */\n scriptureBookGroupName?: string;\n\n /** Optional header to display for the Type column. Default value: 'Type'. */\n typeColumnName?: string;\n\n /** Optional header to display for the Details column. Default value: 'Details' */\n detailsColumnName?: string;\n};\n\nexport type ScriptureResultsViewerProps = ScriptureResultsViewerColumnInfo & {\n /** Groups of ScriptureItemDetail objects from particular sources (e.g., Scripture checks) */\n sources: ResultsSet[];\n\n /** Flag indicating whether to display column headers. Default is false. */\n showColumnHeaders?: boolean;\n\n /** Flag indicating whether to display source column. Default is false. */\n showSourceColumn?: boolean;\n\n /** Callback function to notify when a row is selected */\n onRowSelected?: (selectedRow: ScriptureSrcItemDetail | undefined) => void;\n\n /** Text direction ltr or rtl */\n direction?: 'ltr' | 'rtl';\n};\n\nfunction getColumns(\n colInfo?: ScriptureResultsViewerColumnInfo,\n showSourceColumn?: boolean,\n): ColumnDef[] {\n const showSrcCol = showSourceColumn ?? false;\n return [\n {\n accessorFn: (row) =>\n `${Canon.bookNumberToId(row.start.bookNum)} ${row.start.chapterNum}:${row.start.verseNum}`,\n id: scrBookColId,\n header: colInfo?.scriptureReferenceColumnName ?? defaultScrRefColumnName,\n cell: (info) => {\n const row = info.row.original;\n if (info.row.getIsGrouped()) {\n return Canon.bookNumberToEnglishName(row.start.bookNum);\n }\n return info.row.groupingColumnId === scrBookColId ? formatScrRef(row.start) : undefined;\n },\n getGroupingValue: (row) => row.start.bookNum,\n sortingFn: (a, b) => {\n return compareScrRefs(a.original.start, b.original.start);\n },\n enableGrouping: true,\n },\n {\n accessorFn: (row) => formatScrRef(row.start),\n id: scrRefColId,\n header: undefined,\n cell: (info) => {\n const row = info.row.original;\n return info.row.getIsGrouped() ? undefined : formatScrRef(row.start);\n },\n sortingFn: (a, b) => {\n return compareScrRefs(a.original.start, b.original.start);\n },\n enableGrouping: false,\n },\n {\n accessorFn: (row) => row.source.displayName,\n id: typeColId,\n header: showSrcCol ? (colInfo?.typeColumnName ?? defaultTypeColumnName) : undefined,\n cell: (info) => (showSrcCol || info.row.getIsGrouped() ? info.getValue() : undefined),\n getGroupingValue: (row) => row.source.id,\n sortingFn: (a, b) =>\n a.original.source.displayName.localeCompare(b.original.source.displayName),\n enableGrouping: true,\n },\n {\n accessorFn: (row) => row.detail,\n id: detailsColId,\n header: colInfo?.detailsColumnName ?? defaultDetailsColumnName,\n cell: (info) => info.getValue(),\n enableGrouping: false,\n },\n ];\n}\n\nconst toRefOrRange = (scriptureSelection: ScriptureSelection) => {\n if (!('offset' in scriptureSelection.start))\n throw new Error('No offset available in range start');\n if (scriptureSelection.end && !('offset' in scriptureSelection.end))\n throw new Error('No offset available in range end');\n const { offset: offsetStart } = scriptureSelection.start;\n let offsetEnd: number = 0;\n if (scriptureSelection.end) ({ offset: offsetEnd } = scriptureSelection.end);\n if (\n !scriptureSelection.end ||\n compareScrRefs(scriptureSelection.start, scriptureSelection.end) === 0\n )\n return `${scrRefToBBBCCCVVV(scriptureSelection.start)}+${offsetStart}`;\n return `${scrRefToBBBCCCVVV(scriptureSelection.start)}+${offsetStart}-${scrRefToBBBCCCVVV(scriptureSelection.end)}+${offsetEnd}`;\n};\n\nconst getRowKey = (row: ScriptureSrcItemDetail) =>\n `${toRefOrRange({ start: row.start, end: row.end })} ${row.source.displayName} ${row.detail}`;\n\n/**\n * Component to display a combined list of detailed items from one or more sources, where the items\n * are keyed primarily by Scripture reference. This is particularly useful for displaying a list of\n * results from Scripture checks, but more generally could be used to display any \"results\" from any\n * source(s). The component allows for grouping by Scripture book, source, or both. By default, it\n * displays somewhat \"tree-like\" which allows it to be more horizontally compact and intuitive. But\n * it also has the option of displaying as a traditional table with column headings (with or without\n * the source column showing).\n */\nexport default function ScriptureResultsViewer({\n sources,\n showColumnHeaders = false,\n showSourceColumn = false,\n scriptureReferenceColumnName,\n scriptureBookGroupName,\n typeColumnName,\n detailsColumnName,\n onRowSelected,\n direction = 'ltr',\n}: ScriptureResultsViewerProps) {\n const [grouping, setGrouping] = useState([]);\n const [sorting, setSorting] = useState([{ id: scrBookColId, desc: false }]);\n const [rowSelection, setRowSelection] = useState({});\n\n const scriptureResults = useMemo(\n () =>\n sources.flatMap((source) => {\n return source.data.map((item) => ({\n ...item,\n source: source.source,\n }));\n }),\n [sources],\n );\n\n const columns = useMemo(\n () =>\n getColumns(\n {\n scriptureReferenceColumnName,\n typeColumnName,\n detailsColumnName,\n },\n showSourceColumn,\n ),\n [scriptureReferenceColumnName, typeColumnName, detailsColumnName, showSourceColumn],\n );\n\n useEffect(() => {\n // Ensure sorting is applied correctly when grouped by type\n if (grouping.includes(typeColId)) {\n setSorting([\n { id: typeColId, desc: false },\n { id: scrBookColId, desc: false },\n ]);\n } else {\n setSorting([{ id: scrBookColId, desc: false }]);\n }\n }, [grouping]);\n\n const table = useReactTable({\n data: scriptureResults,\n columns,\n state: {\n grouping,\n sorting,\n rowSelection,\n },\n onGroupingChange: setGrouping,\n onSortingChange: setSorting,\n onRowSelectionChange: setRowSelection,\n getExpandedRowModel: getExpandedRowModel(),\n getGroupedRowModel: getGroupedRowModel(),\n getCoreRowModel: getCoreRowModel(),\n getSortedRowModel: getSortedRowModel(),\n getRowId: getRowKey,\n autoResetExpanded: false,\n enableMultiRowSelection: false,\n enableSubRowSelection: false,\n });\n\n useEffect(() => {\n if (onRowSelected) {\n const selectedRows = table.getSelectedRowModel().rowsById;\n const keys = Object.keys(selectedRows);\n if (keys.length === 1) {\n const selectedRow = scriptureResults.find((row) => getRowKey(row) === keys[0]) || undefined;\n if (selectedRow) onRowSelected(selectedRow);\n }\n }\n }, [rowSelection, scriptureResults, onRowSelected, table]);\n\n // Define possible grouping options\n const scrBookGroupName = scriptureBookGroupName ?? defaultScrBookGroupName;\n const typeGroupName = typeColumnName ?? defaultTypeColumnName;\n\n const groupingOptions = [\n { label: 'No Grouping', value: [] },\n { label: `Group by ${scrBookGroupName}`, value: [scrBookColId] },\n { label: `Group by ${typeGroupName}`, value: [typeColId] },\n {\n label: `Group by ${scrBookGroupName} and ${typeGroupName}`,\n value: [scrBookColId, typeColId],\n },\n {\n label: `Group by ${typeGroupName} and ${scrBookGroupName}`,\n value: [typeColId, scrBookColId],\n },\n ];\n\n const handleSelectChange = (selectedGrouping: string) => {\n setGrouping(JSON.parse(selectedGrouping));\n };\n\n const handleRowClick = (row: Row, event: MouseEvent) => {\n if (!row.getIsGrouped() && !row.getIsSelected()) {\n row.getToggleSelectedHandler()(event);\n }\n };\n\n const getEvenOrOddBandingStyle = (row: Row, index: number) => {\n if (row.getIsGrouped()) return '';\n // UX has now said they don't think they want banding. I'm leaving in the code to\n // set even and odd styles, but there's nothing in the CSS to style them differently.\n // The \"even\" style used to also have tw-bg-neutral-300 (along with even) to create\n // a visual banding effect. That could be added back in if UX changes the decision.\n return cn('banded-row', index % 2 === 0 ? 'even' : 'odd');\n };\n\n const getIndent = (\n groupingState: GroupingState,\n row: Row,\n cell: Cell,\n ) => {\n if (groupingState?.length === 0 || row.depth < cell.column.getGroupedIndex()) return undefined;\n if (row.getIsGrouped()) {\n switch (row.depth) {\n case 1:\n return 'tw-ps-4';\n default:\n return undefined;\n }\n }\n switch (row.depth) {\n case 1:\n return 'tw-ps-8';\n case 2:\n return 'tw-ps-12';\n default:\n return undefined;\n }\n };\n\n return (\n
    \n {!showColumnHeaders && (\n {\n handleSelectChange(value);\n }}\n >\n \n \n \n \n \n {groupingOptions.map((option) => (\n \n {option.label}\n \n ))}\n \n \n \n )}\n \n {showColumnHeaders && (\n \n {table.getHeaderGroups().map((headerGroup) => (\n \n {headerGroup.headers\n .filter((h) => h.column.columnDef.header)\n .map((header) => (\n /* For sticky column headers to work, we probably need to change the default definition of the shadcn Table component. See https://github.com/shadcn-ui/ui/issues/1151 */\n \n {header.isPlaceholder ? undefined : (\n
    \n {header.column.getCanGroup() ? (\n \n {header.column.getIsGrouped() ? `🛑` : `👊 `}\n \n ) : undefined}{' '}\n {flexRender(header.column.columnDef.header, header.getContext())}\n
    \n )}\n
    \n ))}\n
    \n ))}\n
    \n )}\n \n {table.getRowModel().rows.map((row, rowIndex) => {\n return (\n handleRowClick(row, event)}\n >\n {row.getVisibleCells().map((cell) => {\n if (\n cell.getIsPlaceholder() ||\n (cell.column.columnDef.enableGrouping &&\n !cell.getIsGrouped() &&\n (cell.column.columnDef.id !== typeColId || !showSourceColumn))\n )\n return undefined;\n return (\n \n {(() => {\n if (cell.getIsGrouped()) {\n return (\n \n {row.getIsExpanded() && }\n {!row.getIsExpanded() &&\n (direction === 'ltr' ? : )}{' '}\n {flexRender(cell.column.columnDef.cell, cell.getContext())} (\n {row.subRows.length})\n \n );\n }\n\n // if (cell.getIsAggregated()) {\n // flexRender(\n // cell.column.columnDef.aggregatedCell ?? cell.column.columnDef.cell,\n // cell.getContext(),\n // );\n // }\n\n return flexRender(cell.column.columnDef.cell, cell.getContext());\n })()}\n \n );\n })}\n \n );\n })}\n \n
    \n
    \n );\n}\n","import {\n getLocalizeKeyForScrollGroupId,\n LanguageStrings,\n ScrollGroupId,\n} from 'platform-bible-utils';\nimport {\n Select,\n SelectContent,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\n\nconst DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS = {\n [getLocalizeKeyForScrollGroupId('undefined')]: 'Ø',\n [getLocalizeKeyForScrollGroupId(0)]: 'A',\n [getLocalizeKeyForScrollGroupId(1)]: 'B',\n [getLocalizeKeyForScrollGroupId(2)]: 'C',\n [getLocalizeKeyForScrollGroupId(3)]: 'D',\n [getLocalizeKeyForScrollGroupId(4)]: 'E',\n [getLocalizeKeyForScrollGroupId(5)]: 'F',\n [getLocalizeKeyForScrollGroupId(6)]: 'G',\n [getLocalizeKeyForScrollGroupId(7)]: 'H',\n [getLocalizeKeyForScrollGroupId(8)]: 'I',\n [getLocalizeKeyForScrollGroupId(9)]: 'J',\n [getLocalizeKeyForScrollGroupId(10)]: 'K',\n [getLocalizeKeyForScrollGroupId(11)]: 'L',\n [getLocalizeKeyForScrollGroupId(12)]: 'M',\n [getLocalizeKeyForScrollGroupId(13)]: 'N',\n [getLocalizeKeyForScrollGroupId(14)]: 'O',\n [getLocalizeKeyForScrollGroupId(15)]: 'P',\n [getLocalizeKeyForScrollGroupId(16)]: 'Q',\n [getLocalizeKeyForScrollGroupId(17)]: 'R',\n [getLocalizeKeyForScrollGroupId(18)]: 'S',\n [getLocalizeKeyForScrollGroupId(19)]: 'T',\n [getLocalizeKeyForScrollGroupId(20)]: 'U',\n [getLocalizeKeyForScrollGroupId(21)]: 'V',\n [getLocalizeKeyForScrollGroupId(22)]: 'W',\n [getLocalizeKeyForScrollGroupId(23)]: 'X',\n [getLocalizeKeyForScrollGroupId(24)]: 'Y',\n [getLocalizeKeyForScrollGroupId(25)]: 'Z',\n};\n\nexport type ScrollGroupSelectorProps = {\n /**\n * List of scroll group ids to show to the user. Either a {@link ScrollGroupId} or `undefined` for\n * no scroll group\n */\n availableScrollGroupIds: (ScrollGroupId | undefined)[];\n /** Currently selected scroll group id. `undefined` for no scroll group */\n scrollGroupId: ScrollGroupId | undefined;\n /** Callback function run when the user tries to change the scroll group id */\n onChangeScrollGroupId: (newScrollGroupId: ScrollGroupId | undefined) => void;\n /**\n * Localized strings to use for displaying scroll group ids. Must be an object whose keys are\n * `getLocalizeKeyForScrollGroupId(scrollGroupId)` for all scroll group ids (and `undefined` if\n * included) in {@link ScrollGroupSelectorProps.availableScrollGroupIds} and whose values are the\n * localized strings to use for those scroll group ids.\n *\n * Defaults to English localizations of English alphabet for scroll groups 0-25 (e.g. 0 is A) and\n * Ø for `undefined`. Will fill in any that are not provided with these English localizations.\n * Also, if any values match the keys, the English localization will be used. This is useful in\n * case you want to pass in a temporary version of the localized strings while your localized\n * strings load.\n *\n * @example\n *\n * ```typescript\n * const myScrollGroupIdLocalizedStrings = {\n * [getLocalizeKeyForScrollGroupId('undefined')]: 'Ø',\n * [getLocalizeKeyForScrollGroupId(0)]: 'A',\n * [getLocalizeKeyForScrollGroupId(1)]: 'B',\n * [getLocalizeKeyForScrollGroupId(2)]: 'C',\n * [getLocalizeKeyForScrollGroupId(3)]: 'D',\n * [getLocalizeKeyForScrollGroupId(4)]: 'E',\n * };\n * ```\n *\n * @example\n *\n * ```tsx\n * const availableScrollGroupIds = [undefined, 0, 1, 2, 3, 4];\n *\n * const localizeKeys = getLocalizeKeysForScrollGroupIds();\n *\n * const [localizedStrings] = useLocalizedStrings(localizeKeys);\n *\n * ...\n *\n * \n * ```\n */\n localizedStrings?: LanguageStrings;\n};\n\n/** Selector component for choosing a scroll group */\nexport default function ScrollGroupSelector({\n availableScrollGroupIds,\n scrollGroupId,\n onChangeScrollGroupId,\n localizedStrings = {},\n}: ScrollGroupSelectorProps) {\n const localizedStringsDefaulted = {\n ...DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS,\n ...Object.fromEntries(\n Object.entries(localizedStrings).map(\n ([localizedStringKey, localizedStringValue]: [string, string]) => [\n localizedStringKey,\n localizedStringKey === localizedStringValue &&\n localizedStringKey in DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS\n ? DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS[localizedStringKey]\n : localizedStringValue,\n ],\n ),\n ),\n };\n return (\n \n onChangeScrollGroupId(\n newScrollGroupString === 'undefined' ? undefined : parseInt(newScrollGroupString, 10),\n )\n }\n >\n \n \n \n \n {availableScrollGroupIds.map((scrollGroupOptionId) => (\n \n {localizedStringsDefaulted[getLocalizeKeyForScrollGroupId(scrollGroupOptionId)]}\n \n ))}\n \n \n );\n}\n","import React from 'react';\nimport * as SeparatorPrimitive from '@radix-ui/react-separator';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Separator = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, orientation = 'horizontal', decorative = true, ...props }, ref) => (\n \n));\nSeparator.displayName = SeparatorPrimitive.Root.displayName;\n\nexport { Separator };\n","import { PropsWithChildren } from 'react';\nimport { Separator } from '@/components/shadcn-ui/separator';\n\n/** Props for the SettingsList component, currently just children */\ntype SettingsListProps = PropsWithChildren;\n\n/**\n * SettingsList component is a wrapper for list items. Rendered with a formatted div\n *\n * @param children To populate the list with\n * @returns Formatted div encompassing the children\n */\nexport function SettingsList({ children }: SettingsListProps) {\n return
    {children}
    ;\n}\n\n/** Props for SettingsListItem component */\ntype SettingsListItemProps = PropsWithChildren & {\n /** Primary text of the list item */\n primary: string;\n\n /** Optional text of the list item */\n secondary?: string | undefined;\n\n /** Optional boolean to display a message if the children aren't loaded yet. Defaults to false */\n isLoading?: boolean;\n\n /** Optional message to display if isLoading */\n loadingMessage?: string;\n};\n\n/**\n * SettingsListItem component is a common list item. Rendered with a formatted div\n *\n * @param primary Primary text of the list item\n * @param secondary Optional secondary text of the list item\n * @param isLoading Optional, to display a message if the action component isn't generated yet,\n * defaults to false\n * @param children The action component(s) to provide for this item\n * @param loadingMessage Optional, message to display if isLoading\n * @returns Formatted div encompassing the list item content\n */\nexport function SettingsListItem({\n primary,\n secondary,\n children,\n isLoading = false,\n loadingMessage,\n}: SettingsListItemProps) {\n return (\n
    \n
    \n

    {primary}

    \n

    \n {secondary}\n

    \n
    \n\n {isLoading ? (\n

    {loadingMessage}

    \n ) : (\n
    {children}
    \n )}\n
    \n );\n}\n\n/** Props for SettingsListHeader component */\ntype SettingsListHeaderProps = {\n /** The primary text of the list header */\n primary: string;\n\n /** Optional secondary text of the list header */\n secondary?: string | undefined;\n\n /** Optional boolean to include a separator underneath the secondary text. Defaults to false */\n includeSeparator?: boolean;\n};\n\n/**\n * SettingsListHeader component displays text above the list\n *\n * @param primary The primary text of the list header\n * @param secondary Optional secondary text of the list header\n * @param includeSeparator Optional boolean to include a separator underneath the secondary text.\n * Defaults to false\n * @returns Formatted div with list header content\n */\nexport function SettingsListHeader({\n primary,\n secondary,\n includeSeparator = false,\n}: SettingsListHeaderProps) {\n return (\n
    \n
    \n

    {primary}

    \n

    {secondary}

    \n
    \n {includeSeparator ? : ''}\n
    \n );\n}\n","import Checkbox from '@/components/shadcn-ui/checkbox';\nimport { Label } from '@/components/shadcn-ui/label';\n\nexport type ChecklistProps = {\n /** Optional string representing the id attribute of the Checklist */\n id?: string;\n /** Optional string representing CSS class name(s) for styling */\n className?: string;\n /** Array of strings representing the checkable items */\n listItems: string[];\n /** Array of strings representing the checked items */\n selectedListItems: string[];\n /**\n * Function that is called when a checkbox item is selected or deselected\n *\n * @param item The string description for this item\n * @param selected True if selected, false if not selected\n */\n handleSelectListItem: (item: string, selected: boolean) => void;\n\n /**\n * Optional function creates a label for a provided checkable item\n *\n * @param item The item for which a label is to be created\n * @returns A string representing the label text for the checkbox associated with that item\n */\n createLabel?: (item: string) => string;\n};\n\n/** Renders a list of checkboxes. Each checkbox corresponds to an item from the `listItems` array. */\nexport default function Checklist({\n id,\n className,\n listItems,\n selectedListItems,\n handleSelectListItem,\n createLabel,\n}: ChecklistProps) {\n return (\n
    \n {listItems.map((item) => (\n
    \n handleSelectListItem(item, value)}\n />\n \n
    \n ))}\n
    \n );\n}\n","function _interopRequireDefault(obj) {\n return obj && obj.__esModule ? obj : {\n \"default\": obj\n };\n}\nmodule.exports = _interopRequireDefault, module.exports.__esModule = true, module.exports[\"default\"] = module.exports;","export default function chainPropTypes(propType1, propType2) {\n if (process.env.NODE_ENV === 'production') {\n return () => null;\n }\n return function validate(...args) {\n return propType1(...args) || propType2(...args);\n };\n}","export default function _extends() {\n _extends = Object.assign ? Object.assign.bind() : function (target) {\n for (var i = 1; i < arguments.length; i++) {\n var source = arguments[i];\n for (var key in source) {\n if (Object.prototype.hasOwnProperty.call(source, key)) {\n target[key] = source[key];\n }\n }\n }\n return target;\n };\n return _extends.apply(this, arguments);\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\n// https://github.com/sindresorhus/is-plain-obj/blob/main/index.js\nexport function isPlainObject(item) {\n if (typeof item !== 'object' || item === null) {\n return false;\n }\n const prototype = Object.getPrototypeOf(item);\n return (prototype === null || prototype === Object.prototype || Object.getPrototypeOf(prototype) === null) && !(Symbol.toStringTag in item) && !(Symbol.iterator in item);\n}\nfunction deepClone(source) {\n if (!isPlainObject(source)) {\n return source;\n }\n const output = {};\n Object.keys(source).forEach(key => {\n output[key] = deepClone(source[key]);\n });\n return output;\n}\nexport default function deepmerge(target, source, options = {\n clone: true\n}) {\n const output = options.clone ? _extends({}, target) : target;\n if (isPlainObject(target) && isPlainObject(source)) {\n Object.keys(source).forEach(key => {\n // Avoid prototype pollution\n if (key === '__proto__') {\n return;\n }\n if (isPlainObject(source[key]) && key in target && isPlainObject(target[key])) {\n // Since `output` is a clone of `target` and we have narrowed `target` in this block we can cast to the same type.\n output[key] = deepmerge(target[key], source[key], options);\n } else if (options.clone) {\n output[key] = isPlainObject(source[key]) ? deepClone(source[key]) : source[key];\n } else {\n output[key] = source[key];\n }\n });\n }\n return output;\n}","/** @license React v16.13.1\n * react-is.production.min.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';var b=\"function\"===typeof Symbol&&Symbol.for,c=b?Symbol.for(\"react.element\"):60103,d=b?Symbol.for(\"react.portal\"):60106,e=b?Symbol.for(\"react.fragment\"):60107,f=b?Symbol.for(\"react.strict_mode\"):60108,g=b?Symbol.for(\"react.profiler\"):60114,h=b?Symbol.for(\"react.provider\"):60109,k=b?Symbol.for(\"react.context\"):60110,l=b?Symbol.for(\"react.async_mode\"):60111,m=b?Symbol.for(\"react.concurrent_mode\"):60111,n=b?Symbol.for(\"react.forward_ref\"):60112,p=b?Symbol.for(\"react.suspense\"):60113,q=b?\nSymbol.for(\"react.suspense_list\"):60120,r=b?Symbol.for(\"react.memo\"):60115,t=b?Symbol.for(\"react.lazy\"):60116,v=b?Symbol.for(\"react.block\"):60121,w=b?Symbol.for(\"react.fundamental\"):60117,x=b?Symbol.for(\"react.responder\"):60118,y=b?Symbol.for(\"react.scope\"):60119;\nfunction z(a){if(\"object\"===typeof a&&null!==a){var u=a.$$typeof;switch(u){case c:switch(a=a.type,a){case l:case m:case e:case g:case f:case p:return a;default:switch(a=a&&a.$$typeof,a){case k:case n:case t:case r:case h:return a;default:return u}}case d:return u}}}function A(a){return z(a)===m}exports.AsyncMode=l;exports.ConcurrentMode=m;exports.ContextConsumer=k;exports.ContextProvider=h;exports.Element=c;exports.ForwardRef=n;exports.Fragment=e;exports.Lazy=t;exports.Memo=r;exports.Portal=d;\nexports.Profiler=g;exports.StrictMode=f;exports.Suspense=p;exports.isAsyncMode=function(a){return A(a)||z(a)===l};exports.isConcurrentMode=A;exports.isContextConsumer=function(a){return z(a)===k};exports.isContextProvider=function(a){return z(a)===h};exports.isElement=function(a){return\"object\"===typeof a&&null!==a&&a.$$typeof===c};exports.isForwardRef=function(a){return z(a)===n};exports.isFragment=function(a){return z(a)===e};exports.isLazy=function(a){return z(a)===t};\nexports.isMemo=function(a){return z(a)===r};exports.isPortal=function(a){return z(a)===d};exports.isProfiler=function(a){return z(a)===g};exports.isStrictMode=function(a){return z(a)===f};exports.isSuspense=function(a){return z(a)===p};\nexports.isValidElementType=function(a){return\"string\"===typeof a||\"function\"===typeof a||a===e||a===m||a===g||a===f||a===p||a===q||\"object\"===typeof a&&null!==a&&(a.$$typeof===t||a.$$typeof===r||a.$$typeof===h||a.$$typeof===k||a.$$typeof===n||a.$$typeof===w||a.$$typeof===x||a.$$typeof===y||a.$$typeof===v)};exports.typeOf=z;\n","/** @license React v16.13.1\n * react-is.development.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\n\n\nif (process.env.NODE_ENV !== \"production\") {\n (function() {\n'use strict';\n\n// The Symbol used to tag the ReactElement-like types. If there is no native Symbol\n// nor polyfill, then a plain number is used for performance.\nvar hasSymbol = typeof Symbol === 'function' && Symbol.for;\nvar REACT_ELEMENT_TYPE = hasSymbol ? Symbol.for('react.element') : 0xeac7;\nvar REACT_PORTAL_TYPE = hasSymbol ? Symbol.for('react.portal') : 0xeaca;\nvar REACT_FRAGMENT_TYPE = hasSymbol ? Symbol.for('react.fragment') : 0xeacb;\nvar REACT_STRICT_MODE_TYPE = hasSymbol ? Symbol.for('react.strict_mode') : 0xeacc;\nvar REACT_PROFILER_TYPE = hasSymbol ? Symbol.for('react.profiler') : 0xead2;\nvar REACT_PROVIDER_TYPE = hasSymbol ? Symbol.for('react.provider') : 0xeacd;\nvar REACT_CONTEXT_TYPE = hasSymbol ? Symbol.for('react.context') : 0xeace; // TODO: We don't use AsyncMode or ConcurrentMode anymore. They were temporary\n// (unstable) APIs that have been removed. Can we remove the symbols?\n\nvar REACT_ASYNC_MODE_TYPE = hasSymbol ? Symbol.for('react.async_mode') : 0xeacf;\nvar REACT_CONCURRENT_MODE_TYPE = hasSymbol ? Symbol.for('react.concurrent_mode') : 0xeacf;\nvar REACT_FORWARD_REF_TYPE = hasSymbol ? Symbol.for('react.forward_ref') : 0xead0;\nvar REACT_SUSPENSE_TYPE = hasSymbol ? Symbol.for('react.suspense') : 0xead1;\nvar REACT_SUSPENSE_LIST_TYPE = hasSymbol ? Symbol.for('react.suspense_list') : 0xead8;\nvar REACT_MEMO_TYPE = hasSymbol ? Symbol.for('react.memo') : 0xead3;\nvar REACT_LAZY_TYPE = hasSymbol ? Symbol.for('react.lazy') : 0xead4;\nvar REACT_BLOCK_TYPE = hasSymbol ? Symbol.for('react.block') : 0xead9;\nvar REACT_FUNDAMENTAL_TYPE = hasSymbol ? Symbol.for('react.fundamental') : 0xead5;\nvar REACT_RESPONDER_TYPE = hasSymbol ? Symbol.for('react.responder') : 0xead6;\nvar REACT_SCOPE_TYPE = hasSymbol ? Symbol.for('react.scope') : 0xead7;\n\nfunction isValidElementType(type) {\n return typeof type === 'string' || typeof type === 'function' || // Note: its typeof might be other than 'symbol' or 'number' if it's a polyfill.\n type === REACT_FRAGMENT_TYPE || type === REACT_CONCURRENT_MODE_TYPE || type === REACT_PROFILER_TYPE || type === REACT_STRICT_MODE_TYPE || type === REACT_SUSPENSE_TYPE || type === REACT_SUSPENSE_LIST_TYPE || typeof type === 'object' && type !== null && (type.$$typeof === REACT_LAZY_TYPE || type.$$typeof === REACT_MEMO_TYPE || type.$$typeof === REACT_PROVIDER_TYPE || type.$$typeof === REACT_CONTEXT_TYPE || type.$$typeof === REACT_FORWARD_REF_TYPE || type.$$typeof === REACT_FUNDAMENTAL_TYPE || type.$$typeof === REACT_RESPONDER_TYPE || type.$$typeof === REACT_SCOPE_TYPE || type.$$typeof === REACT_BLOCK_TYPE);\n}\n\nfunction typeOf(object) {\n if (typeof object === 'object' && object !== null) {\n var $$typeof = object.$$typeof;\n\n switch ($$typeof) {\n case REACT_ELEMENT_TYPE:\n var type = object.type;\n\n switch (type) {\n case REACT_ASYNC_MODE_TYPE:\n case REACT_CONCURRENT_MODE_TYPE:\n case REACT_FRAGMENT_TYPE:\n case REACT_PROFILER_TYPE:\n case REACT_STRICT_MODE_TYPE:\n case REACT_SUSPENSE_TYPE:\n return type;\n\n default:\n var $$typeofType = type && type.$$typeof;\n\n switch ($$typeofType) {\n case REACT_CONTEXT_TYPE:\n case REACT_FORWARD_REF_TYPE:\n case REACT_LAZY_TYPE:\n case REACT_MEMO_TYPE:\n case REACT_PROVIDER_TYPE:\n return $$typeofType;\n\n default:\n return $$typeof;\n }\n\n }\n\n case REACT_PORTAL_TYPE:\n return $$typeof;\n }\n }\n\n return undefined;\n} // AsyncMode is deprecated along with isAsyncMode\n\nvar AsyncMode = REACT_ASYNC_MODE_TYPE;\nvar ConcurrentMode = REACT_CONCURRENT_MODE_TYPE;\nvar ContextConsumer = REACT_CONTEXT_TYPE;\nvar ContextProvider = REACT_PROVIDER_TYPE;\nvar Element = REACT_ELEMENT_TYPE;\nvar ForwardRef = REACT_FORWARD_REF_TYPE;\nvar Fragment = REACT_FRAGMENT_TYPE;\nvar Lazy = REACT_LAZY_TYPE;\nvar Memo = REACT_MEMO_TYPE;\nvar Portal = REACT_PORTAL_TYPE;\nvar Profiler = REACT_PROFILER_TYPE;\nvar StrictMode = REACT_STRICT_MODE_TYPE;\nvar Suspense = REACT_SUSPENSE_TYPE;\nvar hasWarnedAboutDeprecatedIsAsyncMode = false; // AsyncMode should be deprecated\n\nfunction isAsyncMode(object) {\n {\n if (!hasWarnedAboutDeprecatedIsAsyncMode) {\n hasWarnedAboutDeprecatedIsAsyncMode = true; // Using console['warn'] to evade Babel and ESLint\n\n console['warn']('The ReactIs.isAsyncMode() alias has been deprecated, ' + 'and will be removed in React 17+. Update your code to use ' + 'ReactIs.isConcurrentMode() instead. It has the exact same API.');\n }\n }\n\n return isConcurrentMode(object) || typeOf(object) === REACT_ASYNC_MODE_TYPE;\n}\nfunction isConcurrentMode(object) {\n return typeOf(object) === REACT_CONCURRENT_MODE_TYPE;\n}\nfunction isContextConsumer(object) {\n return typeOf(object) === REACT_CONTEXT_TYPE;\n}\nfunction isContextProvider(object) {\n return typeOf(object) === REACT_PROVIDER_TYPE;\n}\nfunction isElement(object) {\n return typeof object === 'object' && object !== null && object.$$typeof === REACT_ELEMENT_TYPE;\n}\nfunction isForwardRef(object) {\n return typeOf(object) === REACT_FORWARD_REF_TYPE;\n}\nfunction isFragment(object) {\n return typeOf(object) === REACT_FRAGMENT_TYPE;\n}\nfunction isLazy(object) {\n return typeOf(object) === REACT_LAZY_TYPE;\n}\nfunction isMemo(object) {\n return typeOf(object) === REACT_MEMO_TYPE;\n}\nfunction isPortal(object) {\n return typeOf(object) === REACT_PORTAL_TYPE;\n}\nfunction isProfiler(object) {\n return typeOf(object) === REACT_PROFILER_TYPE;\n}\nfunction isStrictMode(object) {\n return typeOf(object) === REACT_STRICT_MODE_TYPE;\n}\nfunction isSuspense(object) {\n return typeOf(object) === REACT_SUSPENSE_TYPE;\n}\n\nexports.AsyncMode = AsyncMode;\nexports.ConcurrentMode = ConcurrentMode;\nexports.ContextConsumer = ContextConsumer;\nexports.ContextProvider = ContextProvider;\nexports.Element = Element;\nexports.ForwardRef = ForwardRef;\nexports.Fragment = Fragment;\nexports.Lazy = Lazy;\nexports.Memo = Memo;\nexports.Portal = Portal;\nexports.Profiler = Profiler;\nexports.StrictMode = StrictMode;\nexports.Suspense = Suspense;\nexports.isAsyncMode = isAsyncMode;\nexports.isConcurrentMode = isConcurrentMode;\nexports.isContextConsumer = isContextConsumer;\nexports.isContextProvider = isContextProvider;\nexports.isElement = isElement;\nexports.isForwardRef = isForwardRef;\nexports.isFragment = isFragment;\nexports.isLazy = isLazy;\nexports.isMemo = isMemo;\nexports.isPortal = isPortal;\nexports.isProfiler = isProfiler;\nexports.isStrictMode = isStrictMode;\nexports.isSuspense = isSuspense;\nexports.isValidElementType = isValidElementType;\nexports.typeOf = typeOf;\n })();\n}\n","'use strict';\n\nif (process.env.NODE_ENV === 'production') {\n module.exports = require('./cjs/react-is.production.min.js');\n} else {\n module.exports = require('./cjs/react-is.development.js');\n}\n","/*\nobject-assign\n(c) Sindre Sorhus\n@license MIT\n*/\n\n'use strict';\n/* eslint-disable no-unused-vars */\nvar getOwnPropertySymbols = Object.getOwnPropertySymbols;\nvar hasOwnProperty = Object.prototype.hasOwnProperty;\nvar propIsEnumerable = Object.prototype.propertyIsEnumerable;\n\nfunction toObject(val) {\n\tif (val === null || val === undefined) {\n\t\tthrow new TypeError('Object.assign cannot be called with null or undefined');\n\t}\n\n\treturn Object(val);\n}\n\nfunction shouldUseNative() {\n\ttry {\n\t\tif (!Object.assign) {\n\t\t\treturn false;\n\t\t}\n\n\t\t// Detect buggy property enumeration order in older V8 versions.\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=4118\n\t\tvar test1 = new String('abc'); // eslint-disable-line no-new-wrappers\n\t\ttest1[5] = 'de';\n\t\tif (Object.getOwnPropertyNames(test1)[0] === '5') {\n\t\t\treturn false;\n\t\t}\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=3056\n\t\tvar test2 = {};\n\t\tfor (var i = 0; i < 10; i++) {\n\t\t\ttest2['_' + String.fromCharCode(i)] = i;\n\t\t}\n\t\tvar order2 = Object.getOwnPropertyNames(test2).map(function (n) {\n\t\t\treturn test2[n];\n\t\t});\n\t\tif (order2.join('') !== '0123456789') {\n\t\t\treturn false;\n\t\t}\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=3056\n\t\tvar test3 = {};\n\t\t'abcdefghijklmnopqrst'.split('').forEach(function (letter) {\n\t\t\ttest3[letter] = letter;\n\t\t});\n\t\tif (Object.keys(Object.assign({}, test3)).join('') !==\n\t\t\t\t'abcdefghijklmnopqrst') {\n\t\t\treturn false;\n\t\t}\n\n\t\treturn true;\n\t} catch (err) {\n\t\t// We don't expect any of the above to throw, but better to be safe.\n\t\treturn false;\n\t}\n}\n\nmodule.exports = shouldUseNative() ? Object.assign : function (target, source) {\n\tvar from;\n\tvar to = toObject(target);\n\tvar symbols;\n\n\tfor (var s = 1; s < arguments.length; s++) {\n\t\tfrom = Object(arguments[s]);\n\n\t\tfor (var key in from) {\n\t\t\tif (hasOwnProperty.call(from, key)) {\n\t\t\t\tto[key] = from[key];\n\t\t\t}\n\t\t}\n\n\t\tif (getOwnPropertySymbols) {\n\t\t\tsymbols = getOwnPropertySymbols(from);\n\t\t\tfor (var i = 0; i < symbols.length; i++) {\n\t\t\t\tif (propIsEnumerable.call(from, symbols[i])) {\n\t\t\t\t\tto[symbols[i]] = from[symbols[i]];\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\n\treturn to;\n};\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar ReactPropTypesSecret = 'SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED';\n\nmodule.exports = ReactPropTypesSecret;\n","module.exports = Function.call.bind(Object.prototype.hasOwnProperty);\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar printWarning = function() {};\n\nif (process.env.NODE_ENV !== 'production') {\n var ReactPropTypesSecret = require('./lib/ReactPropTypesSecret');\n var loggedTypeFailures = {};\n var has = require('./lib/has');\n\n printWarning = function(text) {\n var message = 'Warning: ' + text;\n if (typeof console !== 'undefined') {\n console.error(message);\n }\n try {\n // --- Welcome to debugging React ---\n // This error was thrown as a convenience so that you can use this stack\n // to find the callsite that caused this warning to fire.\n throw new Error(message);\n } catch (x) { /**/ }\n };\n}\n\n/**\n * Assert that the values match with the type specs.\n * Error messages are memorized and will only be shown once.\n *\n * @param {object} typeSpecs Map of name to a ReactPropType\n * @param {object} values Runtime values that need to be type-checked\n * @param {string} location e.g. \"prop\", \"context\", \"child context\"\n * @param {string} componentName Name of the component for error messages.\n * @param {?Function} getStack Returns the component stack.\n * @private\n */\nfunction checkPropTypes(typeSpecs, values, location, componentName, getStack) {\n if (process.env.NODE_ENV !== 'production') {\n for (var typeSpecName in typeSpecs) {\n if (has(typeSpecs, typeSpecName)) {\n var error;\n // Prop type validation may throw. In case they do, we don't want to\n // fail the render phase where it didn't fail before. So we log it.\n // After these have been cleaned up, we'll let them throw.\n try {\n // This is intentionally an invariant that gets caught. It's the same\n // behavior as without this statement except with a better message.\n if (typeof typeSpecs[typeSpecName] !== 'function') {\n var err = Error(\n (componentName || 'React class') + ': ' + location + ' type `' + typeSpecName + '` is invalid; ' +\n 'it must be a function, usually from the `prop-types` package, but received `' + typeof typeSpecs[typeSpecName] + '`.' +\n 'This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.'\n );\n err.name = 'Invariant Violation';\n throw err;\n }\n error = typeSpecs[typeSpecName](values, typeSpecName, componentName, location, null, ReactPropTypesSecret);\n } catch (ex) {\n error = ex;\n }\n if (error && !(error instanceof Error)) {\n printWarning(\n (componentName || 'React class') + ': type specification of ' +\n location + ' `' + typeSpecName + '` is invalid; the type checker ' +\n 'function must return `null` or an `Error` but returned a ' + typeof error + '. ' +\n 'You may have forgotten to pass an argument to the type checker ' +\n 'creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and ' +\n 'shape all require an argument).'\n );\n }\n if (error instanceof Error && !(error.message in loggedTypeFailures)) {\n // Only monitor this failure once because there tends to be a lot of the\n // same error.\n loggedTypeFailures[error.message] = true;\n\n var stack = getStack ? getStack() : '';\n\n printWarning(\n 'Failed ' + location + ' type: ' + error.message + (stack != null ? stack : '')\n );\n }\n }\n }\n }\n}\n\n/**\n * Resets warning cache when testing.\n *\n * @private\n */\ncheckPropTypes.resetWarningCache = function() {\n if (process.env.NODE_ENV !== 'production') {\n loggedTypeFailures = {};\n }\n}\n\nmodule.exports = checkPropTypes;\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar ReactIs = require('react-is');\nvar assign = require('object-assign');\n\nvar ReactPropTypesSecret = require('./lib/ReactPropTypesSecret');\nvar has = require('./lib/has');\nvar checkPropTypes = require('./checkPropTypes');\n\nvar printWarning = function() {};\n\nif (process.env.NODE_ENV !== 'production') {\n printWarning = function(text) {\n var message = 'Warning: ' + text;\n if (typeof console !== 'undefined') {\n console.error(message);\n }\n try {\n // --- Welcome to debugging React ---\n // This error was thrown as a convenience so that you can use this stack\n // to find the callsite that caused this warning to fire.\n throw new Error(message);\n } catch (x) {}\n };\n}\n\nfunction emptyFunctionThatReturnsNull() {\n return null;\n}\n\nmodule.exports = function(isValidElement, throwOnDirectAccess) {\n /* global Symbol */\n var ITERATOR_SYMBOL = typeof Symbol === 'function' && Symbol.iterator;\n var FAUX_ITERATOR_SYMBOL = '@@iterator'; // Before Symbol spec.\n\n /**\n * Returns the iterator method function contained on the iterable object.\n *\n * Be sure to invoke the function with the iterable as context:\n *\n * var iteratorFn = getIteratorFn(myIterable);\n * if (iteratorFn) {\n * var iterator = iteratorFn.call(myIterable);\n * ...\n * }\n *\n * @param {?object} maybeIterable\n * @return {?function}\n */\n function getIteratorFn(maybeIterable) {\n var iteratorFn = maybeIterable && (ITERATOR_SYMBOL && maybeIterable[ITERATOR_SYMBOL] || maybeIterable[FAUX_ITERATOR_SYMBOL]);\n if (typeof iteratorFn === 'function') {\n return iteratorFn;\n }\n }\n\n /**\n * Collection of methods that allow declaration and validation of props that are\n * supplied to React components. Example usage:\n *\n * var Props = require('ReactPropTypes');\n * var MyArticle = React.createClass({\n * propTypes: {\n * // An optional string prop named \"description\".\n * description: Props.string,\n *\n * // A required enum prop named \"category\".\n * category: Props.oneOf(['News','Photos']).isRequired,\n *\n * // A prop named \"dialog\" that requires an instance of Dialog.\n * dialog: Props.instanceOf(Dialog).isRequired\n * },\n * render: function() { ... }\n * });\n *\n * A more formal specification of how these methods are used:\n *\n * type := array|bool|func|object|number|string|oneOf([...])|instanceOf(...)\n * decl := ReactPropTypes.{type}(.isRequired)?\n *\n * Each and every declaration produces a function with the same signature. This\n * allows the creation of custom validation functions. For example:\n *\n * var MyLink = React.createClass({\n * propTypes: {\n * // An optional string or URI prop named \"href\".\n * href: function(props, propName, componentName) {\n * var propValue = props[propName];\n * if (propValue != null && typeof propValue !== 'string' &&\n * !(propValue instanceof URI)) {\n * return new Error(\n * 'Expected a string or an URI for ' + propName + ' in ' +\n * componentName\n * );\n * }\n * }\n * },\n * render: function() {...}\n * });\n *\n * @internal\n */\n\n var ANONYMOUS = '<>';\n\n // Important!\n // Keep this list in sync with production version in `./factoryWithThrowingShims.js`.\n var ReactPropTypes = {\n array: createPrimitiveTypeChecker('array'),\n bigint: createPrimitiveTypeChecker('bigint'),\n bool: createPrimitiveTypeChecker('boolean'),\n func: createPrimitiveTypeChecker('function'),\n number: createPrimitiveTypeChecker('number'),\n object: createPrimitiveTypeChecker('object'),\n string: createPrimitiveTypeChecker('string'),\n symbol: createPrimitiveTypeChecker('symbol'),\n\n any: createAnyTypeChecker(),\n arrayOf: createArrayOfTypeChecker,\n element: createElementTypeChecker(),\n elementType: createElementTypeTypeChecker(),\n instanceOf: createInstanceTypeChecker,\n node: createNodeChecker(),\n objectOf: createObjectOfTypeChecker,\n oneOf: createEnumTypeChecker,\n oneOfType: createUnionTypeChecker,\n shape: createShapeTypeChecker,\n exact: createStrictShapeTypeChecker,\n };\n\n /**\n * inlined Object.is polyfill to avoid requiring consumers ship their own\n * https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object/is\n */\n /*eslint-disable no-self-compare*/\n function is(x, y) {\n // SameValue algorithm\n if (x === y) {\n // Steps 1-5, 7-10\n // Steps 6.b-6.e: +0 != -0\n return x !== 0 || 1 / x === 1 / y;\n } else {\n // Step 6.a: NaN == NaN\n return x !== x && y !== y;\n }\n }\n /*eslint-enable no-self-compare*/\n\n /**\n * We use an Error-like object for backward compatibility as people may call\n * PropTypes directly and inspect their output. However, we don't use real\n * Errors anymore. We don't inspect their stack anyway, and creating them\n * is prohibitively expensive if they are created too often, such as what\n * happens in oneOfType() for any type before the one that matched.\n */\n function PropTypeError(message, data) {\n this.message = message;\n this.data = data && typeof data === 'object' ? data: {};\n this.stack = '';\n }\n // Make `instanceof Error` still work for returned errors.\n PropTypeError.prototype = Error.prototype;\n\n function createChainableTypeChecker(validate) {\n if (process.env.NODE_ENV !== 'production') {\n var manualPropTypeCallCache = {};\n var manualPropTypeWarningCount = 0;\n }\n function checkType(isRequired, props, propName, componentName, location, propFullName, secret) {\n componentName = componentName || ANONYMOUS;\n propFullName = propFullName || propName;\n\n if (secret !== ReactPropTypesSecret) {\n if (throwOnDirectAccess) {\n // New behavior only for users of `prop-types` package\n var err = new Error(\n 'Calling PropTypes validators directly is not supported by the `prop-types` package. ' +\n 'Use `PropTypes.checkPropTypes()` to call them. ' +\n 'Read more at http://fb.me/use-check-prop-types'\n );\n err.name = 'Invariant Violation';\n throw err;\n } else if (process.env.NODE_ENV !== 'production' && typeof console !== 'undefined') {\n // Old behavior for people using React.PropTypes\n var cacheKey = componentName + ':' + propName;\n if (\n !manualPropTypeCallCache[cacheKey] &&\n // Avoid spamming the console because they are often not actionable except for lib authors\n manualPropTypeWarningCount < 3\n ) {\n printWarning(\n 'You are manually calling a React.PropTypes validation ' +\n 'function for the `' + propFullName + '` prop on `' + componentName + '`. This is deprecated ' +\n 'and will throw in the standalone `prop-types` package. ' +\n 'You may be seeing this warning due to a third-party PropTypes ' +\n 'library. See https://fb.me/react-warning-dont-call-proptypes ' + 'for details.'\n );\n manualPropTypeCallCache[cacheKey] = true;\n manualPropTypeWarningCount++;\n }\n }\n }\n if (props[propName] == null) {\n if (isRequired) {\n if (props[propName] === null) {\n return new PropTypeError('The ' + location + ' `' + propFullName + '` is marked as required ' + ('in `' + componentName + '`, but its value is `null`.'));\n }\n return new PropTypeError('The ' + location + ' `' + propFullName + '` is marked as required in ' + ('`' + componentName + '`, but its value is `undefined`.'));\n }\n return null;\n } else {\n return validate(props, propName, componentName, location, propFullName);\n }\n }\n\n var chainedCheckType = checkType.bind(null, false);\n chainedCheckType.isRequired = checkType.bind(null, true);\n\n return chainedCheckType;\n }\n\n function createPrimitiveTypeChecker(expectedType) {\n function validate(props, propName, componentName, location, propFullName, secret) {\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== expectedType) {\n // `propValue` being instance of, say, date/regexp, pass the 'object'\n // check, but we can offer a more precise error message here rather than\n // 'of type `object`'.\n var preciseType = getPreciseType(propValue);\n\n return new PropTypeError(\n 'Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + preciseType + '` supplied to `' + componentName + '`, expected ') + ('`' + expectedType + '`.'),\n {expectedType: expectedType}\n );\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createAnyTypeChecker() {\n return createChainableTypeChecker(emptyFunctionThatReturnsNull);\n }\n\n function createArrayOfTypeChecker(typeChecker) {\n function validate(props, propName, componentName, location, propFullName) {\n if (typeof typeChecker !== 'function') {\n return new PropTypeError('Property `' + propFullName + '` of component `' + componentName + '` has invalid PropType notation inside arrayOf.');\n }\n var propValue = props[propName];\n if (!Array.isArray(propValue)) {\n var propType = getPropType(propValue);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected an array.'));\n }\n for (var i = 0; i < propValue.length; i++) {\n var error = typeChecker(propValue, i, componentName, location, propFullName + '[' + i + ']', ReactPropTypesSecret);\n if (error instanceof Error) {\n return error;\n }\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createElementTypeChecker() {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n if (!isValidElement(propValue)) {\n var propType = getPropType(propValue);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected a single ReactElement.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createElementTypeTypeChecker() {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n if (!ReactIs.isValidElementType(propValue)) {\n var propType = getPropType(propValue);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected a single ReactElement type.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createInstanceTypeChecker(expectedClass) {\n function validate(props, propName, componentName, location, propFullName) {\n if (!(props[propName] instanceof expectedClass)) {\n var expectedClassName = expectedClass.name || ANONYMOUS;\n var actualClassName = getClassName(props[propName]);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + actualClassName + '` supplied to `' + componentName + '`, expected ') + ('instance of `' + expectedClassName + '`.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createEnumTypeChecker(expectedValues) {\n if (!Array.isArray(expectedValues)) {\n if (process.env.NODE_ENV !== 'production') {\n if (arguments.length > 1) {\n printWarning(\n 'Invalid arguments supplied to oneOf, expected an array, got ' + arguments.length + ' arguments. ' +\n 'A common mistake is to write oneOf(x, y, z) instead of oneOf([x, y, z]).'\n );\n } else {\n printWarning('Invalid argument supplied to oneOf, expected an array.');\n }\n }\n return emptyFunctionThatReturnsNull;\n }\n\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n for (var i = 0; i < expectedValues.length; i++) {\n if (is(propValue, expectedValues[i])) {\n return null;\n }\n }\n\n var valuesString = JSON.stringify(expectedValues, function replacer(key, value) {\n var type = getPreciseType(value);\n if (type === 'symbol') {\n return String(value);\n }\n return value;\n });\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of value `' + String(propValue) + '` ' + ('supplied to `' + componentName + '`, expected one of ' + valuesString + '.'));\n }\n return createChainableTypeChecker(validate);\n }\n\n function createObjectOfTypeChecker(typeChecker) {\n function validate(props, propName, componentName, location, propFullName) {\n if (typeof typeChecker !== 'function') {\n return new PropTypeError('Property `' + propFullName + '` of component `' + componentName + '` has invalid PropType notation inside objectOf.');\n }\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== 'object') {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected an object.'));\n }\n for (var key in propValue) {\n if (has(propValue, key)) {\n var error = typeChecker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret);\n if (error instanceof Error) {\n return error;\n }\n }\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createUnionTypeChecker(arrayOfTypeCheckers) {\n if (!Array.isArray(arrayOfTypeCheckers)) {\n process.env.NODE_ENV !== 'production' ? printWarning('Invalid argument supplied to oneOfType, expected an instance of array.') : void 0;\n return emptyFunctionThatReturnsNull;\n }\n\n for (var i = 0; i < arrayOfTypeCheckers.length; i++) {\n var checker = arrayOfTypeCheckers[i];\n if (typeof checker !== 'function') {\n printWarning(\n 'Invalid argument supplied to oneOfType. Expected an array of check functions, but ' +\n 'received ' + getPostfixForTypeWarning(checker) + ' at index ' + i + '.'\n );\n return emptyFunctionThatReturnsNull;\n }\n }\n\n function validate(props, propName, componentName, location, propFullName) {\n var expectedTypes = [];\n for (var i = 0; i < arrayOfTypeCheckers.length; i++) {\n var checker = arrayOfTypeCheckers[i];\n var checkerResult = checker(props, propName, componentName, location, propFullName, ReactPropTypesSecret);\n if (checkerResult == null) {\n return null;\n }\n if (checkerResult.data && has(checkerResult.data, 'expectedType')) {\n expectedTypes.push(checkerResult.data.expectedType);\n }\n }\n var expectedTypesMessage = (expectedTypes.length > 0) ? ', expected one of type [' + expectedTypes.join(', ') + ']': '';\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` supplied to ' + ('`' + componentName + '`' + expectedTypesMessage + '.'));\n }\n return createChainableTypeChecker(validate);\n }\n\n function createNodeChecker() {\n function validate(props, propName, componentName, location, propFullName) {\n if (!isNode(props[propName])) {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` supplied to ' + ('`' + componentName + '`, expected a ReactNode.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function invalidValidatorError(componentName, location, propFullName, key, type) {\n return new PropTypeError(\n (componentName || 'React class') + ': ' + location + ' type `' + propFullName + '.' + key + '` is invalid; ' +\n 'it must be a function, usually from the `prop-types` package, but received `' + type + '`.'\n );\n }\n\n function createShapeTypeChecker(shapeTypes) {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== 'object') {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type `' + propType + '` ' + ('supplied to `' + componentName + '`, expected `object`.'));\n }\n for (var key in shapeTypes) {\n var checker = shapeTypes[key];\n if (typeof checker !== 'function') {\n return invalidValidatorError(componentName, location, propFullName, key, getPreciseType(checker));\n }\n var error = checker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret);\n if (error) {\n return error;\n }\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createStrictShapeTypeChecker(shapeTypes) {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== 'object') {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type `' + propType + '` ' + ('supplied to `' + componentName + '`, expected `object`.'));\n }\n // We need to check all keys in case some are required but missing from props.\n var allKeys = assign({}, props[propName], shapeTypes);\n for (var key in allKeys) {\n var checker = shapeTypes[key];\n if (has(shapeTypes, key) && typeof checker !== 'function') {\n return invalidValidatorError(componentName, location, propFullName, key, getPreciseType(checker));\n }\n if (!checker) {\n return new PropTypeError(\n 'Invalid ' + location + ' `' + propFullName + '` key `' + key + '` supplied to `' + componentName + '`.' +\n '\\nBad object: ' + JSON.stringify(props[propName], null, ' ') +\n '\\nValid keys: ' + JSON.stringify(Object.keys(shapeTypes), null, ' ')\n );\n }\n var error = checker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret);\n if (error) {\n return error;\n }\n }\n return null;\n }\n\n return createChainableTypeChecker(validate);\n }\n\n function isNode(propValue) {\n switch (typeof propValue) {\n case 'number':\n case 'string':\n case 'undefined':\n return true;\n case 'boolean':\n return !propValue;\n case 'object':\n if (Array.isArray(propValue)) {\n return propValue.every(isNode);\n }\n if (propValue === null || isValidElement(propValue)) {\n return true;\n }\n\n var iteratorFn = getIteratorFn(propValue);\n if (iteratorFn) {\n var iterator = iteratorFn.call(propValue);\n var step;\n if (iteratorFn !== propValue.entries) {\n while (!(step = iterator.next()).done) {\n if (!isNode(step.value)) {\n return false;\n }\n }\n } else {\n // Iterator will provide entry [k,v] tuples rather than values.\n while (!(step = iterator.next()).done) {\n var entry = step.value;\n if (entry) {\n if (!isNode(entry[1])) {\n return false;\n }\n }\n }\n }\n } else {\n return false;\n }\n\n return true;\n default:\n return false;\n }\n }\n\n function isSymbol(propType, propValue) {\n // Native Symbol.\n if (propType === 'symbol') {\n return true;\n }\n\n // falsy value can't be a Symbol\n if (!propValue) {\n return false;\n }\n\n // 19.4.3.5 Symbol.prototype[@@toStringTag] === 'Symbol'\n if (propValue['@@toStringTag'] === 'Symbol') {\n return true;\n }\n\n // Fallback for non-spec compliant Symbols which are polyfilled.\n if (typeof Symbol === 'function' && propValue instanceof Symbol) {\n return true;\n }\n\n return false;\n }\n\n // Equivalent of `typeof` but with special handling for array and regexp.\n function getPropType(propValue) {\n var propType = typeof propValue;\n if (Array.isArray(propValue)) {\n return 'array';\n }\n if (propValue instanceof RegExp) {\n // Old webkits (at least until Android 4.0) return 'function' rather than\n // 'object' for typeof a RegExp. We'll normalize this here so that /bla/\n // passes PropTypes.object.\n return 'object';\n }\n if (isSymbol(propType, propValue)) {\n return 'symbol';\n }\n return propType;\n }\n\n // This handles more types than `getPropType`. Only used for error messages.\n // See `createPrimitiveTypeChecker`.\n function getPreciseType(propValue) {\n if (typeof propValue === 'undefined' || propValue === null) {\n return '' + propValue;\n }\n var propType = getPropType(propValue);\n if (propType === 'object') {\n if (propValue instanceof Date) {\n return 'date';\n } else if (propValue instanceof RegExp) {\n return 'regexp';\n }\n }\n return propType;\n }\n\n // Returns a string that is postfixed to a warning about an invalid type.\n // For example, \"undefined\" or \"of type array\"\n function getPostfixForTypeWarning(value) {\n var type = getPreciseType(value);\n switch (type) {\n case 'array':\n case 'object':\n return 'an ' + type;\n case 'boolean':\n case 'date':\n case 'regexp':\n return 'a ' + type;\n default:\n return type;\n }\n }\n\n // Returns class name of the object, if any.\n function getClassName(propValue) {\n if (!propValue.constructor || !propValue.constructor.name) {\n return ANONYMOUS;\n }\n return propValue.constructor.name;\n }\n\n ReactPropTypes.checkPropTypes = checkPropTypes;\n ReactPropTypes.resetWarningCache = checkPropTypes.resetWarningCache;\n ReactPropTypes.PropTypes = ReactPropTypes;\n\n return ReactPropTypes;\n};\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar ReactPropTypesSecret = require('./lib/ReactPropTypesSecret');\n\nfunction emptyFunction() {}\nfunction emptyFunctionWithReset() {}\nemptyFunctionWithReset.resetWarningCache = emptyFunction;\n\nmodule.exports = function() {\n function shim(props, propName, componentName, location, propFullName, secret) {\n if (secret === ReactPropTypesSecret) {\n // It is still safe when called from React.\n return;\n }\n var err = new Error(\n 'Calling PropTypes validators directly is not supported by the `prop-types` package. ' +\n 'Use PropTypes.checkPropTypes() to call them. ' +\n 'Read more at http://fb.me/use-check-prop-types'\n );\n err.name = 'Invariant Violation';\n throw err;\n };\n shim.isRequired = shim;\n function getShim() {\n return shim;\n };\n // Important!\n // Keep this list in sync with production version in `./factoryWithTypeCheckers.js`.\n var ReactPropTypes = {\n array: shim,\n bigint: shim,\n bool: shim,\n func: shim,\n number: shim,\n object: shim,\n string: shim,\n symbol: shim,\n\n any: shim,\n arrayOf: getShim,\n element: shim,\n elementType: shim,\n instanceOf: getShim,\n node: shim,\n objectOf: getShim,\n oneOf: getShim,\n oneOfType: getShim,\n shape: getShim,\n exact: getShim,\n\n checkPropTypes: emptyFunctionWithReset,\n resetWarningCache: emptyFunction\n };\n\n ReactPropTypes.PropTypes = ReactPropTypes;\n\n return ReactPropTypes;\n};\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\nif (process.env.NODE_ENV !== 'production') {\n var ReactIs = require('react-is');\n\n // By explicitly using `prop-types` you are opting into new development behavior.\n // http://fb.me/prop-types-in-prod\n var throwOnDirectAccess = true;\n module.exports = require('./factoryWithTypeCheckers')(ReactIs.isElement, throwOnDirectAccess);\n} else {\n // By explicitly using `prop-types` you are opting into new production behavior.\n // http://fb.me/prop-types-in-prod\n module.exports = require('./factoryWithThrowingShims')();\n}\n","import PropTypes from 'prop-types';\nimport chainPropTypes from '../chainPropTypes';\nfunction isClassComponent(elementType) {\n // elementType.prototype?.isReactComponent\n const {\n prototype = {}\n } = elementType;\n return Boolean(prototype.isReactComponent);\n}\nfunction acceptingRef(props, propName, componentName, location, propFullName) {\n const element = props[propName];\n const safePropName = propFullName || propName;\n if (element == null ||\n // When server-side rendering React doesn't warn either.\n // This is not an accurate check for SSR.\n // This is only in place for Emotion compat.\n // TODO: Revisit once https://github.com/facebook/react/issues/20047 is resolved.\n typeof window === 'undefined') {\n return null;\n }\n let warningHint;\n const elementType = element.type;\n /**\n * Blacklisting instead of whitelisting\n *\n * Blacklisting will miss some components, such as React.Fragment. Those will at least\n * trigger a warning in React.\n * We can't whitelist because there is no safe way to detect React.forwardRef\n * or class components. \"Safe\" means there's no public API.\n *\n */\n if (typeof elementType === 'function' && !isClassComponent(elementType)) {\n warningHint = 'Did you accidentally use a plain function component for an element instead?';\n }\n if (warningHint !== undefined) {\n return new Error(`Invalid ${location} \\`${safePropName}\\` supplied to \\`${componentName}\\`. ` + `Expected an element that can hold a ref. ${warningHint} ` + 'For more information see https://mui.com/r/caveat-with-refs-guide');\n }\n return null;\n}\nconst elementAcceptingRef = chainPropTypes(PropTypes.element, acceptingRef);\nelementAcceptingRef.isRequired = chainPropTypes(PropTypes.element.isRequired, acceptingRef);\nexport default elementAcceptingRef;","import _extends from \"@babel/runtime/helpers/esm/extends\";\n// This module is based on https://github.com/airbnb/prop-types-exact repository.\n// However, in order to reduce the number of dependencies and to remove some extra safe checks\n// the module was forked.\n\nconst specialProperty = 'exact-prop: \\u200b';\nexport default function exactProp(propTypes) {\n if (process.env.NODE_ENV === 'production') {\n return propTypes;\n }\n return _extends({}, propTypes, {\n [specialProperty]: props => {\n const unsupportedProps = Object.keys(props).filter(prop => !propTypes.hasOwnProperty(prop));\n if (unsupportedProps.length > 0) {\n return new Error(`The following props are not supported: ${unsupportedProps.map(prop => `\\`${prop}\\``).join(', ')}. Please remove them.`);\n }\n return null;\n }\n });\n}","/**\n * WARNING: Don't import this directly.\n * Use `MuiError` from `@mui/internal-babel-macros/MuiError.macro` instead.\n * @param {number} code\n */\nexport default function formatMuiErrorMessage(code) {\n // Apply babel-plugin-transform-template-literals in loose mode\n // loose mode is safe if we're concatenating primitives\n // see https://babeljs.io/docs/en/babel-plugin-transform-template-literals#loose\n /* eslint-disable prefer-template */\n let url = 'https://mui.com/production-error/?code=' + code;\n for (let i = 1; i < arguments.length; i += 1) {\n // rest params over-transpile for this case\n // eslint-disable-next-line prefer-rest-params\n url += '&args[]=' + encodeURIComponent(arguments[i]);\n }\n return 'Minified MUI error #' + code + '; visit ' + url + ' for the full message.';\n /* eslint-enable prefer-template */\n}","/**\n * @license React\n * react-is.production.min.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n'use strict';var b=Symbol.for(\"react.element\"),c=Symbol.for(\"react.portal\"),d=Symbol.for(\"react.fragment\"),e=Symbol.for(\"react.strict_mode\"),f=Symbol.for(\"react.profiler\"),g=Symbol.for(\"react.provider\"),h=Symbol.for(\"react.context\"),k=Symbol.for(\"react.server_context\"),l=Symbol.for(\"react.forward_ref\"),m=Symbol.for(\"react.suspense\"),n=Symbol.for(\"react.suspense_list\"),p=Symbol.for(\"react.memo\"),q=Symbol.for(\"react.lazy\"),t=Symbol.for(\"react.offscreen\"),u;u=Symbol.for(\"react.module.reference\");\nfunction v(a){if(\"object\"===typeof a&&null!==a){var r=a.$$typeof;switch(r){case b:switch(a=a.type,a){case d:case f:case e:case m:case n:return a;default:switch(a=a&&a.$$typeof,a){case k:case h:case l:case q:case p:case g:return a;default:return r}}case c:return r}}}exports.ContextConsumer=h;exports.ContextProvider=g;exports.Element=b;exports.ForwardRef=l;exports.Fragment=d;exports.Lazy=q;exports.Memo=p;exports.Portal=c;exports.Profiler=f;exports.StrictMode=e;exports.Suspense=m;\nexports.SuspenseList=n;exports.isAsyncMode=function(){return!1};exports.isConcurrentMode=function(){return!1};exports.isContextConsumer=function(a){return v(a)===h};exports.isContextProvider=function(a){return v(a)===g};exports.isElement=function(a){return\"object\"===typeof a&&null!==a&&a.$$typeof===b};exports.isForwardRef=function(a){return v(a)===l};exports.isFragment=function(a){return v(a)===d};exports.isLazy=function(a){return v(a)===q};exports.isMemo=function(a){return v(a)===p};\nexports.isPortal=function(a){return v(a)===c};exports.isProfiler=function(a){return v(a)===f};exports.isStrictMode=function(a){return v(a)===e};exports.isSuspense=function(a){return v(a)===m};exports.isSuspenseList=function(a){return v(a)===n};\nexports.isValidElementType=function(a){return\"string\"===typeof a||\"function\"===typeof a||a===d||a===f||a===e||a===m||a===n||a===t||\"object\"===typeof a&&null!==a&&(a.$$typeof===q||a.$$typeof===p||a.$$typeof===g||a.$$typeof===h||a.$$typeof===l||a.$$typeof===u||void 0!==a.getModuleId)?!0:!1};exports.typeOf=v;\n","/**\n * @license React\n * react-is.development.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nif (process.env.NODE_ENV !== \"production\") {\n (function() {\n'use strict';\n\n// ATTENTION\n// When adding new symbols to this file,\n// Please consider also adding to 'react-devtools-shared/src/backend/ReactSymbols'\n// The Symbol used to tag the ReactElement-like types.\nvar REACT_ELEMENT_TYPE = Symbol.for('react.element');\nvar REACT_PORTAL_TYPE = Symbol.for('react.portal');\nvar REACT_FRAGMENT_TYPE = Symbol.for('react.fragment');\nvar REACT_STRICT_MODE_TYPE = Symbol.for('react.strict_mode');\nvar REACT_PROFILER_TYPE = Symbol.for('react.profiler');\nvar REACT_PROVIDER_TYPE = Symbol.for('react.provider');\nvar REACT_CONTEXT_TYPE = Symbol.for('react.context');\nvar REACT_SERVER_CONTEXT_TYPE = Symbol.for('react.server_context');\nvar REACT_FORWARD_REF_TYPE = Symbol.for('react.forward_ref');\nvar REACT_SUSPENSE_TYPE = Symbol.for('react.suspense');\nvar REACT_SUSPENSE_LIST_TYPE = Symbol.for('react.suspense_list');\nvar REACT_MEMO_TYPE = Symbol.for('react.memo');\nvar REACT_LAZY_TYPE = Symbol.for('react.lazy');\nvar REACT_OFFSCREEN_TYPE = Symbol.for('react.offscreen');\n\n// -----------------------------------------------------------------------------\n\nvar enableScopeAPI = false; // Experimental Create Event Handle API.\nvar enableCacheElement = false;\nvar enableTransitionTracing = false; // No known bugs, but needs performance testing\n\nvar enableLegacyHidden = false; // Enables unstable_avoidThisFallback feature in Fiber\n// stuff. Intended to enable React core members to more easily debug scheduling\n// issues in DEV builds.\n\nvar enableDebugTracing = false; // Track which Fiber(s) schedule render work.\n\nvar REACT_MODULE_REFERENCE;\n\n{\n REACT_MODULE_REFERENCE = Symbol.for('react.module.reference');\n}\n\nfunction isValidElementType(type) {\n if (typeof type === 'string' || typeof type === 'function') {\n return true;\n } // Note: typeof might be other than 'symbol' or 'number' (e.g. if it's a polyfill).\n\n\n if (type === REACT_FRAGMENT_TYPE || type === REACT_PROFILER_TYPE || enableDebugTracing || type === REACT_STRICT_MODE_TYPE || type === REACT_SUSPENSE_TYPE || type === REACT_SUSPENSE_LIST_TYPE || enableLegacyHidden || type === REACT_OFFSCREEN_TYPE || enableScopeAPI || enableCacheElement || enableTransitionTracing ) {\n return true;\n }\n\n if (typeof type === 'object' && type !== null) {\n if (type.$$typeof === REACT_LAZY_TYPE || type.$$typeof === REACT_MEMO_TYPE || type.$$typeof === REACT_PROVIDER_TYPE || type.$$typeof === REACT_CONTEXT_TYPE || type.$$typeof === REACT_FORWARD_REF_TYPE || // This needs to include all possible module reference object\n // types supported by any Flight configuration anywhere since\n // we don't know which Flight build this will end up being used\n // with.\n type.$$typeof === REACT_MODULE_REFERENCE || type.getModuleId !== undefined) {\n return true;\n }\n }\n\n return false;\n}\n\nfunction typeOf(object) {\n if (typeof object === 'object' && object !== null) {\n var $$typeof = object.$$typeof;\n\n switch ($$typeof) {\n case REACT_ELEMENT_TYPE:\n var type = object.type;\n\n switch (type) {\n case REACT_FRAGMENT_TYPE:\n case REACT_PROFILER_TYPE:\n case REACT_STRICT_MODE_TYPE:\n case REACT_SUSPENSE_TYPE:\n case REACT_SUSPENSE_LIST_TYPE:\n return type;\n\n default:\n var $$typeofType = type && type.$$typeof;\n\n switch ($$typeofType) {\n case REACT_SERVER_CONTEXT_TYPE:\n case REACT_CONTEXT_TYPE:\n case REACT_FORWARD_REF_TYPE:\n case REACT_LAZY_TYPE:\n case REACT_MEMO_TYPE:\n case REACT_PROVIDER_TYPE:\n return $$typeofType;\n\n default:\n return $$typeof;\n }\n\n }\n\n case REACT_PORTAL_TYPE:\n return $$typeof;\n }\n }\n\n return undefined;\n}\nvar ContextConsumer = REACT_CONTEXT_TYPE;\nvar ContextProvider = REACT_PROVIDER_TYPE;\nvar Element = REACT_ELEMENT_TYPE;\nvar ForwardRef = REACT_FORWARD_REF_TYPE;\nvar Fragment = REACT_FRAGMENT_TYPE;\nvar Lazy = REACT_LAZY_TYPE;\nvar Memo = REACT_MEMO_TYPE;\nvar Portal = REACT_PORTAL_TYPE;\nvar Profiler = REACT_PROFILER_TYPE;\nvar StrictMode = REACT_STRICT_MODE_TYPE;\nvar Suspense = REACT_SUSPENSE_TYPE;\nvar SuspenseList = REACT_SUSPENSE_LIST_TYPE;\nvar hasWarnedAboutDeprecatedIsAsyncMode = false;\nvar hasWarnedAboutDeprecatedIsConcurrentMode = false; // AsyncMode should be deprecated\n\nfunction isAsyncMode(object) {\n {\n if (!hasWarnedAboutDeprecatedIsAsyncMode) {\n hasWarnedAboutDeprecatedIsAsyncMode = true; // Using console['warn'] to evade Babel and ESLint\n\n console['warn']('The ReactIs.isAsyncMode() alias has been deprecated, ' + 'and will be removed in React 18+.');\n }\n }\n\n return false;\n}\nfunction isConcurrentMode(object) {\n {\n if (!hasWarnedAboutDeprecatedIsConcurrentMode) {\n hasWarnedAboutDeprecatedIsConcurrentMode = true; // Using console['warn'] to evade Babel and ESLint\n\n console['warn']('The ReactIs.isConcurrentMode() alias has been deprecated, ' + 'and will be removed in React 18+.');\n }\n }\n\n return false;\n}\nfunction isContextConsumer(object) {\n return typeOf(object) === REACT_CONTEXT_TYPE;\n}\nfunction isContextProvider(object) {\n return typeOf(object) === REACT_PROVIDER_TYPE;\n}\nfunction isElement(object) {\n return typeof object === 'object' && object !== null && object.$$typeof === REACT_ELEMENT_TYPE;\n}\nfunction isForwardRef(object) {\n return typeOf(object) === REACT_FORWARD_REF_TYPE;\n}\nfunction isFragment(object) {\n return typeOf(object) === REACT_FRAGMENT_TYPE;\n}\nfunction isLazy(object) {\n return typeOf(object) === REACT_LAZY_TYPE;\n}\nfunction isMemo(object) {\n return typeOf(object) === REACT_MEMO_TYPE;\n}\nfunction isPortal(object) {\n return typeOf(object) === REACT_PORTAL_TYPE;\n}\nfunction isProfiler(object) {\n return typeOf(object) === REACT_PROFILER_TYPE;\n}\nfunction isStrictMode(object) {\n return typeOf(object) === REACT_STRICT_MODE_TYPE;\n}\nfunction isSuspense(object) {\n return typeOf(object) === REACT_SUSPENSE_TYPE;\n}\nfunction isSuspenseList(object) {\n return typeOf(object) === REACT_SUSPENSE_LIST_TYPE;\n}\n\nexports.ContextConsumer = ContextConsumer;\nexports.ContextProvider = ContextProvider;\nexports.Element = Element;\nexports.ForwardRef = ForwardRef;\nexports.Fragment = Fragment;\nexports.Lazy = Lazy;\nexports.Memo = Memo;\nexports.Portal = Portal;\nexports.Profiler = Profiler;\nexports.StrictMode = StrictMode;\nexports.Suspense = Suspense;\nexports.SuspenseList = SuspenseList;\nexports.isAsyncMode = isAsyncMode;\nexports.isConcurrentMode = isConcurrentMode;\nexports.isContextConsumer = isContextConsumer;\nexports.isContextProvider = isContextProvider;\nexports.isElement = isElement;\nexports.isForwardRef = isForwardRef;\nexports.isFragment = isFragment;\nexports.isLazy = isLazy;\nexports.isMemo = isMemo;\nexports.isPortal = isPortal;\nexports.isProfiler = isProfiler;\nexports.isStrictMode = isStrictMode;\nexports.isSuspense = isSuspense;\nexports.isSuspenseList = isSuspenseList;\nexports.isValidElementType = isValidElementType;\nexports.typeOf = typeOf;\n })();\n}\n","'use strict';\n\nif (process.env.NODE_ENV === 'production') {\n module.exports = require('./cjs/react-is.production.min.js');\n} else {\n module.exports = require('./cjs/react-is.development.js');\n}\n","import { ForwardRef, Memo } from 'react-is';\n\n// Simplified polyfill for IE11 support\n// https://github.com/JamesMGreene/Function.name/blob/58b314d4a983110c3682f1228f845d39ccca1817/Function.name.js#L3\nconst fnNameMatchRegex = /^\\s*function(?:\\s|\\s*\\/\\*.*\\*\\/\\s*)+([^(\\s/]*)\\s*/;\nexport function getFunctionName(fn) {\n const match = `${fn}`.match(fnNameMatchRegex);\n const name = match && match[1];\n return name || '';\n}\nfunction getFunctionComponentName(Component, fallback = '') {\n return Component.displayName || Component.name || getFunctionName(Component) || fallback;\n}\nfunction getWrappedName(outerType, innerType, wrapperName) {\n const functionName = getFunctionComponentName(innerType);\n return outerType.displayName || (functionName !== '' ? `${wrapperName}(${functionName})` : wrapperName);\n}\n\n/**\n * cherry-pick from\n * https://github.com/facebook/react/blob/769b1f270e1251d9dbdce0fcbd9e92e502d059b8/packages/shared/getComponentName.js\n * originally forked from recompose/getDisplayName with added IE11 support\n */\nexport default function getDisplayName(Component) {\n if (Component == null) {\n return undefined;\n }\n if (typeof Component === 'string') {\n return Component;\n }\n if (typeof Component === 'function') {\n return getFunctionComponentName(Component, 'Component');\n }\n\n // TypeScript can't have components as objects but they exist in the form of `memo` or `Suspense`\n if (typeof Component === 'object') {\n switch (Component.$$typeof) {\n case ForwardRef:\n return getWrappedName(Component, Component.render, 'ForwardRef');\n case Memo:\n return getWrappedName(Component, Component.type, 'memo');\n default:\n return undefined;\n }\n }\n return undefined;\n}","export default function HTMLElementType(props, propName, componentName, location, propFullName) {\n if (process.env.NODE_ENV === 'production') {\n return null;\n }\n const propValue = props[propName];\n const safePropName = propFullName || propName;\n if (propValue == null) {\n return null;\n }\n if (propValue && propValue.nodeType !== 1) {\n return new Error(`Invalid ${location} \\`${safePropName}\\` supplied to \\`${componentName}\\`. ` + `Expected an HTMLElement.`);\n }\n return null;\n}","import PropTypes from 'prop-types';\nconst refType = PropTypes.oneOfType([PropTypes.func, PropTypes.object]);\nexport default refType;","import _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\n// It should to be noted that this function isn't equivalent to `text-transform: capitalize`.\n//\n// A strict capitalization should uppercase the first letter of each word in the sentence.\n// We only handle the first word.\nexport default function capitalize(string) {\n if (typeof string !== 'string') {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: \\`capitalize(string)\\` expects a string argument.` : _formatMuiErrorMessage(7));\n }\n return string.charAt(0).toUpperCase() + string.slice(1);\n}","/**\n * Safe chained function.\n *\n * Will only create a new function if needed,\n * otherwise will pass back existing functions or null.\n */\nexport default function createChainedFunction(...funcs) {\n return funcs.reduce((acc, func) => {\n if (func == null) {\n return acc;\n }\n return function chainedFunction(...args) {\n acc.apply(this, args);\n func.apply(this, args);\n };\n }, () => {});\n}","// Corresponds to 10 frames at 60 Hz.\n// A few bytes payload overhead when lodash/debounce is ~3 kB and debounce ~300 B.\nexport default function debounce(func, wait = 166) {\n let timeout;\n function debounced(...args) {\n const later = () => {\n // @ts-ignore\n func.apply(this, args);\n };\n clearTimeout(timeout);\n timeout = setTimeout(later, wait);\n }\n debounced.clear = () => {\n clearTimeout(timeout);\n };\n return debounced;\n}","export default function deprecatedPropType(validator, reason) {\n if (process.env.NODE_ENV === 'production') {\n return () => null;\n }\n return (props, propName, componentName, location, propFullName) => {\n const componentNameSafe = componentName || '<>';\n const propFullNameSafe = propFullName || propName;\n if (typeof props[propName] !== 'undefined') {\n return new Error(`The ${location} \\`${propFullNameSafe}\\` of ` + `\\`${componentNameSafe}\\` is deprecated. ${reason}`);\n }\n return null;\n };\n}","import * as React from 'react';\nexport default function isMuiElement(element, muiNames) {\n var _muiName, _element$type;\n return /*#__PURE__*/React.isValidElement(element) && muiNames.indexOf( // For server components `muiName` is avaialble in element.type._payload.value.muiName\n // relevant info - https://github.com/facebook/react/blob/2807d781a08db8e9873687fccc25c0f12b4fb3d4/packages/react/src/ReactLazy.js#L45\n // eslint-disable-next-line no-underscore-dangle\n (_muiName = element.type.muiName) != null ? _muiName : (_element$type = element.type) == null || (_element$type = _element$type._payload) == null || (_element$type = _element$type.value) == null ? void 0 : _element$type.muiName) !== -1;\n}","export default function ownerDocument(node) {\n return node && node.ownerDocument || document;\n}","import ownerDocument from '../ownerDocument';\nexport default function ownerWindow(node) {\n const doc = ownerDocument(node);\n return doc.defaultView || window;\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nexport default function requirePropFactory(componentNameInError, Component) {\n if (process.env.NODE_ENV === 'production') {\n return () => null;\n }\n\n // eslint-disable-next-line react/forbid-foreign-prop-types\n const prevPropTypes = Component ? _extends({}, Component.propTypes) : null;\n const requireProp = requiredProp => (props, propName, componentName, location, propFullName, ...args) => {\n const propFullNameSafe = propFullName || propName;\n const defaultTypeChecker = prevPropTypes == null ? void 0 : prevPropTypes[propFullNameSafe];\n if (defaultTypeChecker) {\n const typeCheckerResult = defaultTypeChecker(props, propName, componentName, location, propFullName, ...args);\n if (typeCheckerResult) {\n return typeCheckerResult;\n }\n }\n if (typeof props[propName] !== 'undefined' && !props[requiredProp]) {\n return new Error(`The prop \\`${propFullNameSafe}\\` of ` + `\\`${componentNameInError}\\` can only be used together with the \\`${requiredProp}\\` prop.`);\n }\n return null;\n };\n return requireProp;\n}","/**\n * TODO v5: consider making it private\n *\n * passes {value} to {ref}\n *\n * WARNING: Be sure to only call this inside a callback that is passed as a ref.\n * Otherwise, make sure to cleanup the previous {ref} if it changes. See\n * https://github.com/mui/material-ui/issues/13539\n *\n * Useful if you want to expose the ref of an inner component to the public API\n * while still using it inside the component.\n * @param ref A ref callback or ref object. If anything falsy, this is a no-op.\n */\nexport default function setRef(ref, value) {\n if (typeof ref === 'function') {\n ref(value);\n } else if (ref) {\n ref.current = value;\n }\n}","'use client';\n\nimport * as React from 'react';\n\n/**\n * A version of `React.useLayoutEffect` that does not show a warning when server-side rendering.\n * This is useful for effects that are only needed for client-side rendering but not for SSR.\n *\n * Before you use this hook, make sure to read https://gist.github.com/gaearon/e7d97cdf38a2907924ea12e4ebdf3c85\n * and confirm it doesn't apply to your use-case.\n */\nconst useEnhancedEffect = typeof window !== 'undefined' ? React.useLayoutEffect : React.useEffect;\nexport default useEnhancedEffect;","'use client';\n\nimport * as React from 'react';\nlet globalId = 0;\nfunction useGlobalId(idOverride) {\n const [defaultId, setDefaultId] = React.useState(idOverride);\n const id = idOverride || defaultId;\n React.useEffect(() => {\n if (defaultId == null) {\n // Fallback to this default id when possible.\n // Use the incrementing value for client-side rendering only.\n // We can't use it server-side.\n // If you want to use random values please consider the Birthday Problem: https://en.wikipedia.org/wiki/Birthday_problem\n globalId += 1;\n setDefaultId(`mui-${globalId}`);\n }\n }, [defaultId]);\n return id;\n}\n\n// downstream bundlers may remove unnecessary concatenation, but won't remove toString call -- Workaround for https://github.com/webpack/webpack/issues/14814\nconst maybeReactUseId = React['useId'.toString()];\n/**\n *\n * @example
    \n * @param idOverride\n * @returns {string}\n */\nexport default function useId(idOverride) {\n if (maybeReactUseId !== undefined) {\n const reactId = maybeReactUseId();\n return idOverride != null ? idOverride : reactId;\n }\n // eslint-disable-next-line react-hooks/rules-of-hooks -- `React.useId` is invariant at runtime.\n return useGlobalId(idOverride);\n}","export default function unsupportedProp(props, propName, componentName, location, propFullName) {\n if (process.env.NODE_ENV === 'production') {\n return null;\n }\n const propFullNameSafe = propFullName || propName;\n if (typeof props[propName] !== 'undefined') {\n return new Error(`The prop \\`${propFullNameSafe}\\` is not supported. Please remove it.`);\n }\n return null;\n}","'use client';\n\n/* eslint-disable react-hooks/rules-of-hooks, react-hooks/exhaustive-deps */\nimport * as React from 'react';\nexport default function useControlled({\n controlled,\n default: defaultProp,\n name,\n state = 'value'\n}) {\n // isControlled is ignored in the hook dependency lists as it should never change.\n const {\n current: isControlled\n } = React.useRef(controlled !== undefined);\n const [valueState, setValue] = React.useState(defaultProp);\n const value = isControlled ? controlled : valueState;\n if (process.env.NODE_ENV !== 'production') {\n React.useEffect(() => {\n if (isControlled !== (controlled !== undefined)) {\n console.error([`MUI: A component is changing the ${isControlled ? '' : 'un'}controlled ${state} state of ${name} to be ${isControlled ? 'un' : ''}controlled.`, 'Elements should not switch from uncontrolled to controlled (or vice versa).', `Decide between using a controlled or uncontrolled ${name} ` + 'element for the lifetime of the component.', \"The nature of the state is determined during the first render. It's considered controlled if the value is not `undefined`.\", 'More info: https://fb.me/react-controlled-components'].join('\\n'));\n }\n }, [state, name, controlled]);\n const {\n current: defaultValue\n } = React.useRef(defaultProp);\n React.useEffect(() => {\n if (!isControlled && defaultValue !== defaultProp) {\n console.error([`MUI: A component is changing the default ${state} state of an uncontrolled ${name} after being initialized. ` + `To suppress this warning opt to use a controlled ${name}.`].join('\\n'));\n }\n }, [JSON.stringify(defaultProp)]);\n }\n const setValueIfUncontrolled = React.useCallback(newValue => {\n if (!isControlled) {\n setValue(newValue);\n }\n }, []);\n return [value, setValueIfUncontrolled];\n}","'use client';\n\nimport * as React from 'react';\nimport useEnhancedEffect from '../useEnhancedEffect';\n\n/**\n * Inspired by https://github.com/facebook/react/issues/14099#issuecomment-440013892\n * See RFC in https://github.com/reactjs/rfcs/pull/220\n */\n\nfunction useEventCallback(fn) {\n const ref = React.useRef(fn);\n useEnhancedEffect(() => {\n ref.current = fn;\n });\n return React.useRef((...args) =>\n // @ts-expect-error hide `this`\n (0, ref.current)(...args)).current;\n}\nexport default useEventCallback;","'use client';\n\nimport * as React from 'react';\nimport setRef from '../setRef';\nexport default function useForkRef(...refs) {\n /**\n * This will create a new function if the refs passed to this hook change and are all defined.\n * This means react will call the old forkRef with `null` and the new forkRef\n * with the ref. Cleanup naturally emerges from this behavior.\n */\n return React.useMemo(() => {\n if (refs.every(ref => ref == null)) {\n return null;\n }\n return instance => {\n refs.forEach(ref => {\n setRef(ref, instance);\n });\n };\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, refs);\n}","'use client';\n\nimport * as React from 'react';\nconst UNINITIALIZED = {};\n\n/**\n * A React.useRef() that is initialized lazily with a function. Note that it accepts an optional\n * initialization argument, so the initialization function doesn't need to be an inline closure.\n *\n * @usage\n * const ref = useLazyRef(sortColumns, columns)\n */\nexport default function useLazyRef(init, initArg) {\n const ref = React.useRef(UNINITIALIZED);\n if (ref.current === UNINITIALIZED) {\n ref.current = init(initArg);\n }\n return ref;\n}","'use client';\n\nimport * as React from 'react';\nconst EMPTY = [];\n\n/**\n * A React.useEffect equivalent that runs once, when the component is mounted.\n */\nexport default function useOnMount(fn) {\n /* eslint-disable react-hooks/exhaustive-deps */\n React.useEffect(fn, EMPTY);\n /* eslint-enable react-hooks/exhaustive-deps */\n}","'use client';\n\nimport useLazyRef from '../useLazyRef/useLazyRef';\nimport useOnMount from '../useOnMount/useOnMount';\nexport class Timeout {\n constructor() {\n this.currentId = null;\n this.clear = () => {\n if (this.currentId !== null) {\n clearTimeout(this.currentId);\n this.currentId = null;\n }\n };\n this.disposeEffect = () => {\n return this.clear;\n };\n }\n static create() {\n return new Timeout();\n }\n /**\n * Executes `fn` after `delay`, clearing any previously scheduled call.\n */\n start(delay, fn) {\n this.clear();\n this.currentId = setTimeout(() => {\n this.currentId = null;\n fn();\n }, delay);\n }\n}\nexport default function useTimeout() {\n const timeout = useLazyRef(Timeout.create).current;\n useOnMount(timeout.disposeEffect);\n return timeout;\n}","'use client';\n\n// based on https://github.com/WICG/focus-visible/blob/v4.1.5/src/focus-visible.js\nimport * as React from 'react';\nimport { Timeout } from '../useTimeout/useTimeout';\nlet hadKeyboardEvent = true;\nlet hadFocusVisibleRecently = false;\nconst hadFocusVisibleRecentlyTimeout = new Timeout();\nconst inputTypesWhitelist = {\n text: true,\n search: true,\n url: true,\n tel: true,\n email: true,\n password: true,\n number: true,\n date: true,\n month: true,\n week: true,\n time: true,\n datetime: true,\n 'datetime-local': true\n};\n\n/**\n * Computes whether the given element should automatically trigger the\n * `focus-visible` class being added, i.e. whether it should always match\n * `:focus-visible` when focused.\n * @param {Element} node\n * @returns {boolean}\n */\nfunction focusTriggersKeyboardModality(node) {\n const {\n type,\n tagName\n } = node;\n if (tagName === 'INPUT' && inputTypesWhitelist[type] && !node.readOnly) {\n return true;\n }\n if (tagName === 'TEXTAREA' && !node.readOnly) {\n return true;\n }\n if (node.isContentEditable) {\n return true;\n }\n return false;\n}\n\n/**\n * Keep track of our keyboard modality state with `hadKeyboardEvent`.\n * If the most recent user interaction was via the keyboard;\n * and the key press did not include a meta, alt/option, or control key;\n * then the modality is keyboard. Otherwise, the modality is not keyboard.\n * @param {KeyboardEvent} event\n */\nfunction handleKeyDown(event) {\n if (event.metaKey || event.altKey || event.ctrlKey) {\n return;\n }\n hadKeyboardEvent = true;\n}\n\n/**\n * If at any point a user clicks with a pointing device, ensure that we change\n * the modality away from keyboard.\n * This avoids the situation where a user presses a key on an already focused\n * element, and then clicks on a different element, focusing it with a\n * pointing device, while we still think we're in keyboard modality.\n */\nfunction handlePointerDown() {\n hadKeyboardEvent = false;\n}\nfunction handleVisibilityChange() {\n if (this.visibilityState === 'hidden') {\n // If the tab becomes active again, the browser will handle calling focus\n // on the element (Safari actually calls it twice).\n // If this tab change caused a blur on an element with focus-visible,\n // re-apply the class when the user switches back to the tab.\n if (hadFocusVisibleRecently) {\n hadKeyboardEvent = true;\n }\n }\n}\nfunction prepare(doc) {\n doc.addEventListener('keydown', handleKeyDown, true);\n doc.addEventListener('mousedown', handlePointerDown, true);\n doc.addEventListener('pointerdown', handlePointerDown, true);\n doc.addEventListener('touchstart', handlePointerDown, true);\n doc.addEventListener('visibilitychange', handleVisibilityChange, true);\n}\nexport function teardown(doc) {\n doc.removeEventListener('keydown', handleKeyDown, true);\n doc.removeEventListener('mousedown', handlePointerDown, true);\n doc.removeEventListener('pointerdown', handlePointerDown, true);\n doc.removeEventListener('touchstart', handlePointerDown, true);\n doc.removeEventListener('visibilitychange', handleVisibilityChange, true);\n}\nfunction isFocusVisible(event) {\n const {\n target\n } = event;\n try {\n return target.matches(':focus-visible');\n } catch (error) {\n // Browsers not implementing :focus-visible will throw a SyntaxError.\n // We use our own heuristic for those browsers.\n // Rethrow might be better if it's not the expected error but do we really\n // want to crash if focus-visible malfunctioned?\n }\n\n // No need for validFocusTarget check. The user does that by attaching it to\n // focusable events only.\n return hadKeyboardEvent || focusTriggersKeyboardModality(target);\n}\nexport default function useIsFocusVisible() {\n const ref = React.useCallback(node => {\n if (node != null) {\n prepare(node.ownerDocument);\n }\n }, []);\n const isFocusVisibleRef = React.useRef(false);\n\n /**\n * Should be called if a blur event is fired\n */\n function handleBlurVisible() {\n // checking against potential state variable does not suffice if we focus and blur synchronously.\n // React wouldn't have time to trigger a re-render so `focusVisible` would be stale.\n // Ideally we would adjust `isFocusVisible(event)` to look at `relatedTarget` for blur events.\n // This doesn't work in IE11 due to https://github.com/facebook/react/issues/3751\n // TODO: check again if React releases their internal changes to focus event handling (https://github.com/facebook/react/pull/19186).\n if (isFocusVisibleRef.current) {\n // To detect a tab/window switch, we look for a blur event followed\n // rapidly by a visibility change.\n // If we don't see a visibility change within 100ms, it's probably a\n // regular focus change.\n hadFocusVisibleRecently = true;\n hadFocusVisibleRecentlyTimeout.start(100, () => {\n hadFocusVisibleRecently = false;\n });\n isFocusVisibleRef.current = false;\n return true;\n }\n return false;\n }\n\n /**\n * Should be called if a blur event is fired\n */\n function handleFocusVisible(event) {\n if (isFocusVisible(event)) {\n isFocusVisibleRef.current = true;\n return true;\n }\n return false;\n }\n return {\n isFocusVisibleRef,\n onFocus: handleFocusVisible,\n onBlur: handleBlurVisible,\n ref\n };\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\n/**\n * Add keys, values of `defaultProps` that does not exist in `props`\n * @param {object} defaultProps\n * @param {object} props\n * @returns {object} resolved props\n */\nexport default function resolveProps(defaultProps, props) {\n const output = _extends({}, props);\n Object.keys(defaultProps).forEach(propName => {\n if (propName.toString().match(/^(components|slots)$/)) {\n output[propName] = _extends({}, defaultProps[propName], output[propName]);\n } else if (propName.toString().match(/^(componentsProps|slotProps)$/)) {\n const defaultSlotProps = defaultProps[propName] || {};\n const slotProps = props[propName];\n output[propName] = {};\n if (!slotProps || !Object.keys(slotProps)) {\n // Reduce the iteration if the slot props is empty\n output[propName] = defaultSlotProps;\n } else if (!defaultSlotProps || !Object.keys(defaultSlotProps)) {\n // Reduce the iteration if the default slot props is empty\n output[propName] = slotProps;\n } else {\n output[propName] = _extends({}, slotProps);\n Object.keys(defaultSlotProps).forEach(slotPropName => {\n output[propName][slotPropName] = resolveProps(defaultSlotProps[slotPropName], slotProps[slotPropName]);\n });\n }\n } else if (output[propName] === undefined) {\n output[propName] = defaultProps[propName];\n }\n });\n return output;\n}","export default function composeClasses(slots, getUtilityClass, classes = undefined) {\n const output = {};\n Object.keys(slots).forEach(\n // `Object.keys(slots)` can't be wider than `T` because we infer `T` from `slots`.\n // @ts-expect-error https://github.com/microsoft/TypeScript/pull/12253#issuecomment-263132208\n slot => {\n output[slot] = slots[slot].reduce((acc, key) => {\n if (key) {\n const utilityClass = getUtilityClass(key);\n if (utilityClass !== '') {\n acc.push(utilityClass);\n }\n if (classes && classes[key]) {\n acc.push(classes[key]);\n }\n }\n return acc;\n }, []).join(' ');\n });\n return output;\n}","const defaultGenerator = componentName => componentName;\nconst createClassNameGenerator = () => {\n let generate = defaultGenerator;\n return {\n configure(generator) {\n generate = generator;\n },\n generate(componentName) {\n return generate(componentName);\n },\n reset() {\n generate = defaultGenerator;\n }\n };\n};\nconst ClassNameGenerator = createClassNameGenerator();\nexport default ClassNameGenerator;","import ClassNameGenerator from '../ClassNameGenerator';\nexport const globalStateClasses = {\n active: 'active',\n checked: 'checked',\n completed: 'completed',\n disabled: 'disabled',\n error: 'error',\n expanded: 'expanded',\n focused: 'focused',\n focusVisible: 'focusVisible',\n open: 'open',\n readOnly: 'readOnly',\n required: 'required',\n selected: 'selected'\n};\nexport default function generateUtilityClass(componentName, slot, globalStatePrefix = 'Mui') {\n const globalStateClass = globalStateClasses[slot];\n return globalStateClass ? `${globalStatePrefix}-${globalStateClass}` : `${ClassNameGenerator.generate(componentName)}-${slot}`;\n}\nexport function isGlobalState(slot) {\n return globalStateClasses[slot] !== undefined;\n}","import generateUtilityClass from '../generateUtilityClass';\nexport default function generateUtilityClasses(componentName, slots, globalStatePrefix = 'Mui') {\n const result = {};\n slots.forEach(slot => {\n result[slot] = generateUtilityClass(componentName, slot, globalStatePrefix);\n });\n return result;\n}","function clamp(val, min = Number.MIN_SAFE_INTEGER, max = Number.MAX_SAFE_INTEGER) {\n return Math.max(min, Math.min(val, max));\n}\nexport default clamp;","export default function _objectWithoutPropertiesLoose(source, excluded) {\n if (source == null) return {};\n var target = {};\n var sourceKeys = Object.keys(source);\n var key, i;\n for (i = 0; i < sourceKeys.length; i++) {\n key = sourceKeys[i];\n if (excluded.indexOf(key) >= 0) continue;\n target[key] = source[key];\n }\n return target;\n}","import _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nconst _excluded = [\"values\", \"unit\", \"step\"];\n// Sorted ASC by size. That's important.\n// It can't be configured as it's used statically for propTypes.\nexport const breakpointKeys = ['xs', 'sm', 'md', 'lg', 'xl'];\nconst sortBreakpointsValues = values => {\n const breakpointsAsArray = Object.keys(values).map(key => ({\n key,\n val: values[key]\n })) || [];\n // Sort in ascending order\n breakpointsAsArray.sort((breakpoint1, breakpoint2) => breakpoint1.val - breakpoint2.val);\n return breakpointsAsArray.reduce((acc, obj) => {\n return _extends({}, acc, {\n [obj.key]: obj.val\n });\n }, {});\n};\n\n// Keep in mind that @media is inclusive by the CSS specification.\nexport default function createBreakpoints(breakpoints) {\n const {\n // The breakpoint **start** at this value.\n // For instance with the first breakpoint xs: [xs, sm).\n values = {\n xs: 0,\n // phone\n sm: 600,\n // tablet\n md: 900,\n // small laptop\n lg: 1200,\n // desktop\n xl: 1536 // large screen\n },\n unit = 'px',\n step = 5\n } = breakpoints,\n other = _objectWithoutPropertiesLoose(breakpoints, _excluded);\n const sortedValues = sortBreakpointsValues(values);\n const keys = Object.keys(sortedValues);\n function up(key) {\n const value = typeof values[key] === 'number' ? values[key] : key;\n return `@media (min-width:${value}${unit})`;\n }\n function down(key) {\n const value = typeof values[key] === 'number' ? values[key] : key;\n return `@media (max-width:${value - step / 100}${unit})`;\n }\n function between(start, end) {\n const endIndex = keys.indexOf(end);\n return `@media (min-width:${typeof values[start] === 'number' ? values[start] : start}${unit}) and ` + `(max-width:${(endIndex !== -1 && typeof values[keys[endIndex]] === 'number' ? values[keys[endIndex]] : end) - step / 100}${unit})`;\n }\n function only(key) {\n if (keys.indexOf(key) + 1 < keys.length) {\n return between(key, keys[keys.indexOf(key) + 1]);\n }\n return up(key);\n }\n function not(key) {\n // handle first and last key separately, for better readability\n const keyIndex = keys.indexOf(key);\n if (keyIndex === 0) {\n return up(keys[1]);\n }\n if (keyIndex === keys.length - 1) {\n return down(keys[keyIndex]);\n }\n return between(key, keys[keys.indexOf(key) + 1]).replace('@media', '@media not all and');\n }\n return _extends({\n keys,\n values: sortedValues,\n up,\n down,\n between,\n only,\n not,\n unit\n }, other);\n}","const shape = {\n borderRadius: 4\n};\nexport default shape;","import PropTypes from 'prop-types';\nconst responsivePropType = process.env.NODE_ENV !== 'production' ? PropTypes.oneOfType([PropTypes.number, PropTypes.string, PropTypes.object, PropTypes.array]) : {};\nexport default responsivePropType;","import deepmerge from '@mui/utils/deepmerge';\nfunction merge(acc, item) {\n if (!item) {\n return acc;\n }\n return deepmerge(acc, item, {\n clone: false // No need to clone deep, it's way faster.\n });\n}\nexport default merge;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport PropTypes from 'prop-types';\nimport deepmerge from '@mui/utils/deepmerge';\nimport merge from './merge';\n\n// The breakpoint **start** at this value.\n// For instance with the first breakpoint xs: [xs, sm[.\nexport const values = {\n xs: 0,\n // phone\n sm: 600,\n // tablet\n md: 900,\n // small laptop\n lg: 1200,\n // desktop\n xl: 1536 // large screen\n};\nconst defaultBreakpoints = {\n // Sorted ASC by size. That's important.\n // It can't be configured as it's used statically for propTypes.\n keys: ['xs', 'sm', 'md', 'lg', 'xl'],\n up: key => `@media (min-width:${values[key]}px)`\n};\nexport function handleBreakpoints(props, propValue, styleFromPropValue) {\n const theme = props.theme || {};\n if (Array.isArray(propValue)) {\n const themeBreakpoints = theme.breakpoints || defaultBreakpoints;\n return propValue.reduce((acc, item, index) => {\n acc[themeBreakpoints.up(themeBreakpoints.keys[index])] = styleFromPropValue(propValue[index]);\n return acc;\n }, {});\n }\n if (typeof propValue === 'object') {\n const themeBreakpoints = theme.breakpoints || defaultBreakpoints;\n return Object.keys(propValue).reduce((acc, breakpoint) => {\n // key is breakpoint\n if (Object.keys(themeBreakpoints.values || values).indexOf(breakpoint) !== -1) {\n const mediaKey = themeBreakpoints.up(breakpoint);\n acc[mediaKey] = styleFromPropValue(propValue[breakpoint], breakpoint);\n } else {\n const cssKey = breakpoint;\n acc[cssKey] = propValue[cssKey];\n }\n return acc;\n }, {});\n }\n const output = styleFromPropValue(propValue);\n return output;\n}\nfunction breakpoints(styleFunction) {\n // false positive\n // eslint-disable-next-line react/function-component-definition\n const newStyleFunction = props => {\n const theme = props.theme || {};\n const base = styleFunction(props);\n const themeBreakpoints = theme.breakpoints || defaultBreakpoints;\n const extended = themeBreakpoints.keys.reduce((acc, key) => {\n if (props[key]) {\n acc = acc || {};\n acc[themeBreakpoints.up(key)] = styleFunction(_extends({\n theme\n }, props[key]));\n }\n return acc;\n }, null);\n return merge(base, extended);\n };\n newStyleFunction.propTypes = process.env.NODE_ENV !== 'production' ? _extends({}, styleFunction.propTypes, {\n xs: PropTypes.object,\n sm: PropTypes.object,\n md: PropTypes.object,\n lg: PropTypes.object,\n xl: PropTypes.object\n }) : {};\n newStyleFunction.filterProps = ['xs', 'sm', 'md', 'lg', 'xl', ...styleFunction.filterProps];\n return newStyleFunction;\n}\nexport function createEmptyBreakpointObject(breakpointsInput = {}) {\n var _breakpointsInput$key;\n const breakpointsInOrder = (_breakpointsInput$key = breakpointsInput.keys) == null ? void 0 : _breakpointsInput$key.reduce((acc, key) => {\n const breakpointStyleKey = breakpointsInput.up(key);\n acc[breakpointStyleKey] = {};\n return acc;\n }, {});\n return breakpointsInOrder || {};\n}\nexport function removeUnusedBreakpoints(breakpointKeys, style) {\n return breakpointKeys.reduce((acc, key) => {\n const breakpointOutput = acc[key];\n const isBreakpointUnused = !breakpointOutput || Object.keys(breakpointOutput).length === 0;\n if (isBreakpointUnused) {\n delete acc[key];\n }\n return acc;\n }, style);\n}\nexport function mergeBreakpointsInOrder(breakpointsInput, ...styles) {\n const emptyBreakpoints = createEmptyBreakpointObject(breakpointsInput);\n const mergedOutput = [emptyBreakpoints, ...styles].reduce((prev, next) => deepmerge(prev, next), {});\n return removeUnusedBreakpoints(Object.keys(emptyBreakpoints), mergedOutput);\n}\n\n// compute base for responsive values; e.g.,\n// [1,2,3] => {xs: true, sm: true, md: true}\n// {xs: 1, sm: 2, md: 3} => {xs: true, sm: true, md: true}\nexport function computeBreakpointsBase(breakpointValues, themeBreakpoints) {\n // fixed value\n if (typeof breakpointValues !== 'object') {\n return {};\n }\n const base = {};\n const breakpointsKeys = Object.keys(themeBreakpoints);\n if (Array.isArray(breakpointValues)) {\n breakpointsKeys.forEach((breakpoint, i) => {\n if (i < breakpointValues.length) {\n base[breakpoint] = true;\n }\n });\n } else {\n breakpointsKeys.forEach(breakpoint => {\n if (breakpointValues[breakpoint] != null) {\n base[breakpoint] = true;\n }\n });\n }\n return base;\n}\nexport function resolveBreakpointValues({\n values: breakpointValues,\n breakpoints: themeBreakpoints,\n base: customBase\n}) {\n const base = customBase || computeBreakpointsBase(breakpointValues, themeBreakpoints);\n const keys = Object.keys(base);\n if (keys.length === 0) {\n return breakpointValues;\n }\n let previous;\n return keys.reduce((acc, breakpoint, i) => {\n if (Array.isArray(breakpointValues)) {\n acc[breakpoint] = breakpointValues[i] != null ? breakpointValues[i] : breakpointValues[previous];\n previous = i;\n } else if (typeof breakpointValues === 'object') {\n acc[breakpoint] = breakpointValues[breakpoint] != null ? breakpointValues[breakpoint] : breakpointValues[previous];\n previous = breakpoint;\n } else {\n acc[breakpoint] = breakpointValues;\n }\n return acc;\n }, {});\n}\nexport default breakpoints;","import capitalize from '@mui/utils/capitalize';\nimport responsivePropType from './responsivePropType';\nimport { handleBreakpoints } from './breakpoints';\nexport function getPath(obj, path, checkVars = true) {\n if (!path || typeof path !== 'string') {\n return null;\n }\n\n // Check if CSS variables are used\n if (obj && obj.vars && checkVars) {\n const val = `vars.${path}`.split('.').reduce((acc, item) => acc && acc[item] ? acc[item] : null, obj);\n if (val != null) {\n return val;\n }\n }\n return path.split('.').reduce((acc, item) => {\n if (acc && acc[item] != null) {\n return acc[item];\n }\n return null;\n }, obj);\n}\nexport function getStyleValue(themeMapping, transform, propValueFinal, userValue = propValueFinal) {\n let value;\n if (typeof themeMapping === 'function') {\n value = themeMapping(propValueFinal);\n } else if (Array.isArray(themeMapping)) {\n value = themeMapping[propValueFinal] || userValue;\n } else {\n value = getPath(themeMapping, propValueFinal) || userValue;\n }\n if (transform) {\n value = transform(value, userValue, themeMapping);\n }\n return value;\n}\nfunction style(options) {\n const {\n prop,\n cssProperty = options.prop,\n themeKey,\n transform\n } = options;\n\n // false positive\n // eslint-disable-next-line react/function-component-definition\n const fn = props => {\n if (props[prop] == null) {\n return null;\n }\n const propValue = props[prop];\n const theme = props.theme;\n const themeMapping = getPath(theme, themeKey) || {};\n const styleFromPropValue = propValueFinal => {\n let value = getStyleValue(themeMapping, transform, propValueFinal);\n if (propValueFinal === value && typeof propValueFinal === 'string') {\n // Haven't found value\n value = getStyleValue(themeMapping, transform, `${prop}${propValueFinal === 'default' ? '' : capitalize(propValueFinal)}`, propValueFinal);\n }\n if (cssProperty === false) {\n return value;\n }\n return {\n [cssProperty]: value\n };\n };\n return handleBreakpoints(props, propValue, styleFromPropValue);\n };\n fn.propTypes = process.env.NODE_ENV !== 'production' ? {\n [prop]: responsivePropType\n } : {};\n fn.filterProps = [prop];\n return fn;\n}\nexport default style;","export default function memoize(fn) {\n const cache = {};\n return arg => {\n if (cache[arg] === undefined) {\n cache[arg] = fn(arg);\n }\n return cache[arg];\n };\n}","import responsivePropType from './responsivePropType';\nimport { handleBreakpoints } from './breakpoints';\nimport { getPath } from './style';\nimport merge from './merge';\nimport memoize from './memoize';\nconst properties = {\n m: 'margin',\n p: 'padding'\n};\nconst directions = {\n t: 'Top',\n r: 'Right',\n b: 'Bottom',\n l: 'Left',\n x: ['Left', 'Right'],\n y: ['Top', 'Bottom']\n};\nconst aliases = {\n marginX: 'mx',\n marginY: 'my',\n paddingX: 'px',\n paddingY: 'py'\n};\n\n// memoize() impact:\n// From 300,000 ops/sec\n// To 350,000 ops/sec\nconst getCssProperties = memoize(prop => {\n // It's not a shorthand notation.\n if (prop.length > 2) {\n if (aliases[prop]) {\n prop = aliases[prop];\n } else {\n return [prop];\n }\n }\n const [a, b] = prop.split('');\n const property = properties[a];\n const direction = directions[b] || '';\n return Array.isArray(direction) ? direction.map(dir => property + dir) : [property + direction];\n});\nexport const marginKeys = ['m', 'mt', 'mr', 'mb', 'ml', 'mx', 'my', 'margin', 'marginTop', 'marginRight', 'marginBottom', 'marginLeft', 'marginX', 'marginY', 'marginInline', 'marginInlineStart', 'marginInlineEnd', 'marginBlock', 'marginBlockStart', 'marginBlockEnd'];\nexport const paddingKeys = ['p', 'pt', 'pr', 'pb', 'pl', 'px', 'py', 'padding', 'paddingTop', 'paddingRight', 'paddingBottom', 'paddingLeft', 'paddingX', 'paddingY', 'paddingInline', 'paddingInlineStart', 'paddingInlineEnd', 'paddingBlock', 'paddingBlockStart', 'paddingBlockEnd'];\nconst spacingKeys = [...marginKeys, ...paddingKeys];\nexport function createUnaryUnit(theme, themeKey, defaultValue, propName) {\n var _getPath;\n const themeSpacing = (_getPath = getPath(theme, themeKey, false)) != null ? _getPath : defaultValue;\n if (typeof themeSpacing === 'number') {\n return abs => {\n if (typeof abs === 'string') {\n return abs;\n }\n if (process.env.NODE_ENV !== 'production') {\n if (typeof abs !== 'number') {\n console.error(`MUI: Expected ${propName} argument to be a number or a string, got ${abs}.`);\n }\n }\n return themeSpacing * abs;\n };\n }\n if (Array.isArray(themeSpacing)) {\n return abs => {\n if (typeof abs === 'string') {\n return abs;\n }\n if (process.env.NODE_ENV !== 'production') {\n if (!Number.isInteger(abs)) {\n console.error([`MUI: The \\`theme.${themeKey}\\` array type cannot be combined with non integer values.` + `You should either use an integer value that can be used as index, or define the \\`theme.${themeKey}\\` as a number.`].join('\\n'));\n } else if (abs > themeSpacing.length - 1) {\n console.error([`MUI: The value provided (${abs}) overflows.`, `The supported values are: ${JSON.stringify(themeSpacing)}.`, `${abs} > ${themeSpacing.length - 1}, you need to add the missing values.`].join('\\n'));\n }\n }\n return themeSpacing[abs];\n };\n }\n if (typeof themeSpacing === 'function') {\n return themeSpacing;\n }\n if (process.env.NODE_ENV !== 'production') {\n console.error([`MUI: The \\`theme.${themeKey}\\` value (${themeSpacing}) is invalid.`, 'It should be a number, an array or a function.'].join('\\n'));\n }\n return () => undefined;\n}\nexport function createUnarySpacing(theme) {\n return createUnaryUnit(theme, 'spacing', 8, 'spacing');\n}\nexport function getValue(transformer, propValue) {\n if (typeof propValue === 'string' || propValue == null) {\n return propValue;\n }\n const abs = Math.abs(propValue);\n const transformed = transformer(abs);\n if (propValue >= 0) {\n return transformed;\n }\n if (typeof transformed === 'number') {\n return -transformed;\n }\n return `-${transformed}`;\n}\nexport function getStyleFromPropValue(cssProperties, transformer) {\n return propValue => cssProperties.reduce((acc, cssProperty) => {\n acc[cssProperty] = getValue(transformer, propValue);\n return acc;\n }, {});\n}\nfunction resolveCssProperty(props, keys, prop, transformer) {\n // Using a hash computation over an array iteration could be faster, but with only 28 items,\n // it's doesn't worth the bundle size.\n if (keys.indexOf(prop) === -1) {\n return null;\n }\n const cssProperties = getCssProperties(prop);\n const styleFromPropValue = getStyleFromPropValue(cssProperties, transformer);\n const propValue = props[prop];\n return handleBreakpoints(props, propValue, styleFromPropValue);\n}\nfunction style(props, keys) {\n const transformer = createUnarySpacing(props.theme);\n return Object.keys(props).map(prop => resolveCssProperty(props, keys, prop, transformer)).reduce(merge, {});\n}\nexport function margin(props) {\n return style(props, marginKeys);\n}\nmargin.propTypes = process.env.NODE_ENV !== 'production' ? marginKeys.reduce((obj, key) => {\n obj[key] = responsivePropType;\n return obj;\n}, {}) : {};\nmargin.filterProps = marginKeys;\nexport function padding(props) {\n return style(props, paddingKeys);\n}\npadding.propTypes = process.env.NODE_ENV !== 'production' ? paddingKeys.reduce((obj, key) => {\n obj[key] = responsivePropType;\n return obj;\n}, {}) : {};\npadding.filterProps = paddingKeys;\nfunction spacing(props) {\n return style(props, spacingKeys);\n}\nspacing.propTypes = process.env.NODE_ENV !== 'production' ? spacingKeys.reduce((obj, key) => {\n obj[key] = responsivePropType;\n return obj;\n}, {}) : {};\nspacing.filterProps = spacingKeys;\nexport default spacing;","import { createUnarySpacing } from '../spacing';\n\n// The different signatures imply different meaning for their arguments that can't be expressed structurally.\n// We express the difference with variable names.\n\nexport default function createSpacing(spacingInput = 8) {\n // Already transformed.\n if (spacingInput.mui) {\n return spacingInput;\n }\n\n // Material Design layouts are visually balanced. Most measurements align to an 8dp grid, which aligns both spacing and the overall layout.\n // Smaller components, such as icons, can align to a 4dp grid.\n // https://m2.material.io/design/layout/understanding-layout.html\n const transform = createUnarySpacing({\n spacing: spacingInput\n });\n const spacing = (...argsInput) => {\n if (process.env.NODE_ENV !== 'production') {\n if (!(argsInput.length <= 4)) {\n console.error(`MUI: Too many arguments provided, expected between 0 and 4, got ${argsInput.length}`);\n }\n }\n const args = argsInput.length === 0 ? [1] : argsInput;\n return args.map(argument => {\n const output = transform(argument);\n return typeof output === 'number' ? `${output}px` : output;\n }).join(' ');\n };\n spacing.mui = true;\n return spacing;\n}","import merge from './merge';\nfunction compose(...styles) {\n const handlers = styles.reduce((acc, style) => {\n style.filterProps.forEach(prop => {\n acc[prop] = style;\n });\n return acc;\n }, {});\n\n // false positive\n // eslint-disable-next-line react/function-component-definition\n const fn = props => {\n return Object.keys(props).reduce((acc, prop) => {\n if (handlers[prop]) {\n return merge(acc, handlers[prop](props));\n }\n return acc;\n }, {});\n };\n fn.propTypes = process.env.NODE_ENV !== 'production' ? styles.reduce((acc, style) => Object.assign(acc, style.propTypes), {}) : {};\n fn.filterProps = styles.reduce((acc, style) => acc.concat(style.filterProps), []);\n return fn;\n}\nexport default compose;","import responsivePropType from './responsivePropType';\nimport style from './style';\nimport compose from './compose';\nimport { createUnaryUnit, getValue } from './spacing';\nimport { handleBreakpoints } from './breakpoints';\nexport function borderTransform(value) {\n if (typeof value !== 'number') {\n return value;\n }\n return `${value}px solid`;\n}\nfunction createBorderStyle(prop, transform) {\n return style({\n prop,\n themeKey: 'borders',\n transform\n });\n}\nexport const border = createBorderStyle('border', borderTransform);\nexport const borderTop = createBorderStyle('borderTop', borderTransform);\nexport const borderRight = createBorderStyle('borderRight', borderTransform);\nexport const borderBottom = createBorderStyle('borderBottom', borderTransform);\nexport const borderLeft = createBorderStyle('borderLeft', borderTransform);\nexport const borderColor = createBorderStyle('borderColor');\nexport const borderTopColor = createBorderStyle('borderTopColor');\nexport const borderRightColor = createBorderStyle('borderRightColor');\nexport const borderBottomColor = createBorderStyle('borderBottomColor');\nexport const borderLeftColor = createBorderStyle('borderLeftColor');\nexport const outline = createBorderStyle('outline', borderTransform);\nexport const outlineColor = createBorderStyle('outlineColor');\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const borderRadius = props => {\n if (props.borderRadius !== undefined && props.borderRadius !== null) {\n const transformer = createUnaryUnit(props.theme, 'shape.borderRadius', 4, 'borderRadius');\n const styleFromPropValue = propValue => ({\n borderRadius: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.borderRadius, styleFromPropValue);\n }\n return null;\n};\nborderRadius.propTypes = process.env.NODE_ENV !== 'production' ? {\n borderRadius: responsivePropType\n} : {};\nborderRadius.filterProps = ['borderRadius'];\nconst borders = compose(border, borderTop, borderRight, borderBottom, borderLeft, borderColor, borderTopColor, borderRightColor, borderBottomColor, borderLeftColor, borderRadius, outline, outlineColor);\nexport default borders;","import style from './style';\nimport compose from './compose';\nimport { createUnaryUnit, getValue } from './spacing';\nimport { handleBreakpoints } from './breakpoints';\nimport responsivePropType from './responsivePropType';\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const gap = props => {\n if (props.gap !== undefined && props.gap !== null) {\n const transformer = createUnaryUnit(props.theme, 'spacing', 8, 'gap');\n const styleFromPropValue = propValue => ({\n gap: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.gap, styleFromPropValue);\n }\n return null;\n};\ngap.propTypes = process.env.NODE_ENV !== 'production' ? {\n gap: responsivePropType\n} : {};\ngap.filterProps = ['gap'];\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const columnGap = props => {\n if (props.columnGap !== undefined && props.columnGap !== null) {\n const transformer = createUnaryUnit(props.theme, 'spacing', 8, 'columnGap');\n const styleFromPropValue = propValue => ({\n columnGap: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.columnGap, styleFromPropValue);\n }\n return null;\n};\ncolumnGap.propTypes = process.env.NODE_ENV !== 'production' ? {\n columnGap: responsivePropType\n} : {};\ncolumnGap.filterProps = ['columnGap'];\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const rowGap = props => {\n if (props.rowGap !== undefined && props.rowGap !== null) {\n const transformer = createUnaryUnit(props.theme, 'spacing', 8, 'rowGap');\n const styleFromPropValue = propValue => ({\n rowGap: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.rowGap, styleFromPropValue);\n }\n return null;\n};\nrowGap.propTypes = process.env.NODE_ENV !== 'production' ? {\n rowGap: responsivePropType\n} : {};\nrowGap.filterProps = ['rowGap'];\nexport const gridColumn = style({\n prop: 'gridColumn'\n});\nexport const gridRow = style({\n prop: 'gridRow'\n});\nexport const gridAutoFlow = style({\n prop: 'gridAutoFlow'\n});\nexport const gridAutoColumns = style({\n prop: 'gridAutoColumns'\n});\nexport const gridAutoRows = style({\n prop: 'gridAutoRows'\n});\nexport const gridTemplateColumns = style({\n prop: 'gridTemplateColumns'\n});\nexport const gridTemplateRows = style({\n prop: 'gridTemplateRows'\n});\nexport const gridTemplateAreas = style({\n prop: 'gridTemplateAreas'\n});\nexport const gridArea = style({\n prop: 'gridArea'\n});\nconst grid = compose(gap, columnGap, rowGap, gridColumn, gridRow, gridAutoFlow, gridAutoColumns, gridAutoRows, gridTemplateColumns, gridTemplateRows, gridTemplateAreas, gridArea);\nexport default grid;","import style from './style';\nimport compose from './compose';\nexport function paletteTransform(value, userValue) {\n if (userValue === 'grey') {\n return userValue;\n }\n return value;\n}\nexport const color = style({\n prop: 'color',\n themeKey: 'palette',\n transform: paletteTransform\n});\nexport const bgcolor = style({\n prop: 'bgcolor',\n cssProperty: 'backgroundColor',\n themeKey: 'palette',\n transform: paletteTransform\n});\nexport const backgroundColor = style({\n prop: 'backgroundColor',\n themeKey: 'palette',\n transform: paletteTransform\n});\nconst palette = compose(color, bgcolor, backgroundColor);\nexport default palette;","import style from './style';\nimport compose from './compose';\nimport { handleBreakpoints, values as breakpointsValues } from './breakpoints';\nexport function sizingTransform(value) {\n return value <= 1 && value !== 0 ? `${value * 100}%` : value;\n}\nexport const width = style({\n prop: 'width',\n transform: sizingTransform\n});\nexport const maxWidth = props => {\n if (props.maxWidth !== undefined && props.maxWidth !== null) {\n const styleFromPropValue = propValue => {\n var _props$theme, _props$theme2;\n const breakpoint = ((_props$theme = props.theme) == null || (_props$theme = _props$theme.breakpoints) == null || (_props$theme = _props$theme.values) == null ? void 0 : _props$theme[propValue]) || breakpointsValues[propValue];\n if (!breakpoint) {\n return {\n maxWidth: sizingTransform(propValue)\n };\n }\n if (((_props$theme2 = props.theme) == null || (_props$theme2 = _props$theme2.breakpoints) == null ? void 0 : _props$theme2.unit) !== 'px') {\n return {\n maxWidth: `${breakpoint}${props.theme.breakpoints.unit}`\n };\n }\n return {\n maxWidth: breakpoint\n };\n };\n return handleBreakpoints(props, props.maxWidth, styleFromPropValue);\n }\n return null;\n};\nmaxWidth.filterProps = ['maxWidth'];\nexport const minWidth = style({\n prop: 'minWidth',\n transform: sizingTransform\n});\nexport const height = style({\n prop: 'height',\n transform: sizingTransform\n});\nexport const maxHeight = style({\n prop: 'maxHeight',\n transform: sizingTransform\n});\nexport const minHeight = style({\n prop: 'minHeight',\n transform: sizingTransform\n});\nexport const sizeWidth = style({\n prop: 'size',\n cssProperty: 'width',\n transform: sizingTransform\n});\nexport const sizeHeight = style({\n prop: 'size',\n cssProperty: 'height',\n transform: sizingTransform\n});\nexport const boxSizing = style({\n prop: 'boxSizing'\n});\nconst sizing = compose(width, maxWidth, minWidth, height, maxHeight, minHeight, boxSizing);\nexport default sizing;","import { padding, margin } from '../spacing';\nimport { borderRadius, borderTransform } from '../borders';\nimport { gap, rowGap, columnGap } from '../cssGrid';\nimport { paletteTransform } from '../palette';\nimport { maxWidth, sizingTransform } from '../sizing';\nconst defaultSxConfig = {\n // borders\n border: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderTop: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderRight: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderBottom: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderLeft: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderColor: {\n themeKey: 'palette'\n },\n borderTopColor: {\n themeKey: 'palette'\n },\n borderRightColor: {\n themeKey: 'palette'\n },\n borderBottomColor: {\n themeKey: 'palette'\n },\n borderLeftColor: {\n themeKey: 'palette'\n },\n outline: {\n themeKey: 'borders',\n transform: borderTransform\n },\n outlineColor: {\n themeKey: 'palette'\n },\n borderRadius: {\n themeKey: 'shape.borderRadius',\n style: borderRadius\n },\n // palette\n color: {\n themeKey: 'palette',\n transform: paletteTransform\n },\n bgcolor: {\n themeKey: 'palette',\n cssProperty: 'backgroundColor',\n transform: paletteTransform\n },\n backgroundColor: {\n themeKey: 'palette',\n transform: paletteTransform\n },\n // spacing\n p: {\n style: padding\n },\n pt: {\n style: padding\n },\n pr: {\n style: padding\n },\n pb: {\n style: padding\n },\n pl: {\n style: padding\n },\n px: {\n style: padding\n },\n py: {\n style: padding\n },\n padding: {\n style: padding\n },\n paddingTop: {\n style: padding\n },\n paddingRight: {\n style: padding\n },\n paddingBottom: {\n style: padding\n },\n paddingLeft: {\n style: padding\n },\n paddingX: {\n style: padding\n },\n paddingY: {\n style: padding\n },\n paddingInline: {\n style: padding\n },\n paddingInlineStart: {\n style: padding\n },\n paddingInlineEnd: {\n style: padding\n },\n paddingBlock: {\n style: padding\n },\n paddingBlockStart: {\n style: padding\n },\n paddingBlockEnd: {\n style: padding\n },\n m: {\n style: margin\n },\n mt: {\n style: margin\n },\n mr: {\n style: margin\n },\n mb: {\n style: margin\n },\n ml: {\n style: margin\n },\n mx: {\n style: margin\n },\n my: {\n style: margin\n },\n margin: {\n style: margin\n },\n marginTop: {\n style: margin\n },\n marginRight: {\n style: margin\n },\n marginBottom: {\n style: margin\n },\n marginLeft: {\n style: margin\n },\n marginX: {\n style: margin\n },\n marginY: {\n style: margin\n },\n marginInline: {\n style: margin\n },\n marginInlineStart: {\n style: margin\n },\n marginInlineEnd: {\n style: margin\n },\n marginBlock: {\n style: margin\n },\n marginBlockStart: {\n style: margin\n },\n marginBlockEnd: {\n style: margin\n },\n // display\n displayPrint: {\n cssProperty: false,\n transform: value => ({\n '@media print': {\n display: value\n }\n })\n },\n display: {},\n overflow: {},\n textOverflow: {},\n visibility: {},\n whiteSpace: {},\n // flexbox\n flexBasis: {},\n flexDirection: {},\n flexWrap: {},\n justifyContent: {},\n alignItems: {},\n alignContent: {},\n order: {},\n flex: {},\n flexGrow: {},\n flexShrink: {},\n alignSelf: {},\n justifyItems: {},\n justifySelf: {},\n // grid\n gap: {\n style: gap\n },\n rowGap: {\n style: rowGap\n },\n columnGap: {\n style: columnGap\n },\n gridColumn: {},\n gridRow: {},\n gridAutoFlow: {},\n gridAutoColumns: {},\n gridAutoRows: {},\n gridTemplateColumns: {},\n gridTemplateRows: {},\n gridTemplateAreas: {},\n gridArea: {},\n // positions\n position: {},\n zIndex: {\n themeKey: 'zIndex'\n },\n top: {},\n right: {},\n bottom: {},\n left: {},\n // shadows\n boxShadow: {\n themeKey: 'shadows'\n },\n // sizing\n width: {\n transform: sizingTransform\n },\n maxWidth: {\n style: maxWidth\n },\n minWidth: {\n transform: sizingTransform\n },\n height: {\n transform: sizingTransform\n },\n maxHeight: {\n transform: sizingTransform\n },\n minHeight: {\n transform: sizingTransform\n },\n boxSizing: {},\n // typography\n fontFamily: {\n themeKey: 'typography'\n },\n fontSize: {\n themeKey: 'typography'\n },\n fontStyle: {\n themeKey: 'typography'\n },\n fontWeight: {\n themeKey: 'typography'\n },\n letterSpacing: {},\n textTransform: {},\n lineHeight: {},\n textAlign: {},\n typography: {\n cssProperty: false,\n themeKey: 'typography'\n }\n};\nexport default defaultSxConfig;","import capitalize from '@mui/utils/capitalize';\nimport merge from '../merge';\nimport { getPath, getStyleValue as getValue } from '../style';\nimport { handleBreakpoints, createEmptyBreakpointObject, removeUnusedBreakpoints } from '../breakpoints';\nimport defaultSxConfig from './defaultSxConfig';\nfunction objectsHaveSameKeys(...objects) {\n const allKeys = objects.reduce((keys, object) => keys.concat(Object.keys(object)), []);\n const union = new Set(allKeys);\n return objects.every(object => union.size === Object.keys(object).length);\n}\nfunction callIfFn(maybeFn, arg) {\n return typeof maybeFn === 'function' ? maybeFn(arg) : maybeFn;\n}\n\n// eslint-disable-next-line @typescript-eslint/naming-convention\nexport function unstable_createStyleFunctionSx() {\n function getThemeValue(prop, val, theme, config) {\n const props = {\n [prop]: val,\n theme\n };\n const options = config[prop];\n if (!options) {\n return {\n [prop]: val\n };\n }\n const {\n cssProperty = prop,\n themeKey,\n transform,\n style\n } = options;\n if (val == null) {\n return null;\n }\n\n // TODO v6: remove, see https://github.com/mui/material-ui/pull/38123\n if (themeKey === 'typography' && val === 'inherit') {\n return {\n [prop]: val\n };\n }\n const themeMapping = getPath(theme, themeKey) || {};\n if (style) {\n return style(props);\n }\n const styleFromPropValue = propValueFinal => {\n let value = getValue(themeMapping, transform, propValueFinal);\n if (propValueFinal === value && typeof propValueFinal === 'string') {\n // Haven't found value\n value = getValue(themeMapping, transform, `${prop}${propValueFinal === 'default' ? '' : capitalize(propValueFinal)}`, propValueFinal);\n }\n if (cssProperty === false) {\n return value;\n }\n return {\n [cssProperty]: value\n };\n };\n return handleBreakpoints(props, val, styleFromPropValue);\n }\n function styleFunctionSx(props) {\n var _theme$unstable_sxCon;\n const {\n sx,\n theme = {}\n } = props || {};\n if (!sx) {\n return null; // Emotion & styled-components will neglect null\n }\n const config = (_theme$unstable_sxCon = theme.unstable_sxConfig) != null ? _theme$unstable_sxCon : defaultSxConfig;\n\n /*\n * Receive `sxInput` as object or callback\n * and then recursively check keys & values to create media query object styles.\n * (the result will be used in `styled`)\n */\n function traverse(sxInput) {\n let sxObject = sxInput;\n if (typeof sxInput === 'function') {\n sxObject = sxInput(theme);\n } else if (typeof sxInput !== 'object') {\n // value\n return sxInput;\n }\n if (!sxObject) {\n return null;\n }\n const emptyBreakpoints = createEmptyBreakpointObject(theme.breakpoints);\n const breakpointsKeys = Object.keys(emptyBreakpoints);\n let css = emptyBreakpoints;\n Object.keys(sxObject).forEach(styleKey => {\n const value = callIfFn(sxObject[styleKey], theme);\n if (value !== null && value !== undefined) {\n if (typeof value === 'object') {\n if (config[styleKey]) {\n css = merge(css, getThemeValue(styleKey, value, theme, config));\n } else {\n const breakpointsValues = handleBreakpoints({\n theme\n }, value, x => ({\n [styleKey]: x\n }));\n if (objectsHaveSameKeys(breakpointsValues, value)) {\n css[styleKey] = styleFunctionSx({\n sx: value,\n theme\n });\n } else {\n css = merge(css, breakpointsValues);\n }\n }\n } else {\n css = merge(css, getThemeValue(styleKey, value, theme, config));\n }\n }\n });\n return removeUnusedBreakpoints(breakpointsKeys, css);\n }\n return Array.isArray(sx) ? sx.map(traverse) : traverse(sx);\n }\n return styleFunctionSx;\n}\nconst styleFunctionSx = unstable_createStyleFunctionSx();\nstyleFunctionSx.filterProps = ['sx'];\nexport default styleFunctionSx;","/**\n * A universal utility to style components with multiple color modes. Always use it from the theme object.\n * It works with:\n * - [Basic theme](https://mui.com/material-ui/customization/dark-mode/)\n * - [CSS theme variables](https://mui.com/material-ui/experimental-api/css-theme-variables/overview/)\n * - Zero-runtime engine\n *\n * Tips: Use an array over object spread and place `theme.applyStyles()` last.\n *\n * ✅ [{ background: '#e5e5e5' }, theme.applyStyles('dark', { background: '#1c1c1c' })]\n *\n * 🚫 { background: '#e5e5e5', ...theme.applyStyles('dark', { background: '#1c1c1c' })}\n *\n * @example\n * 1. using with `styled`:\n * ```jsx\n * const Component = styled('div')(({ theme }) => [\n * { background: '#e5e5e5' },\n * theme.applyStyles('dark', {\n * background: '#1c1c1c',\n * color: '#fff',\n * }),\n * ]);\n * ```\n *\n * @example\n * 2. using with `sx` prop:\n * ```jsx\n * [\n * { background: '#e5e5e5' },\n * theme.applyStyles('dark', {\n * background: '#1c1c1c',\n * color: '#fff',\n * }),\n * ]}\n * />\n * ```\n *\n * @example\n * 3. theming a component:\n * ```jsx\n * extendTheme({\n * components: {\n * MuiButton: {\n * styleOverrides: {\n * root: ({ theme }) => [\n * { background: '#e5e5e5' },\n * theme.applyStyles('dark', {\n * background: '#1c1c1c',\n * color: '#fff',\n * }),\n * ],\n * },\n * }\n * }\n * })\n *```\n */\nexport default function applyStyles(key, styles) {\n // @ts-expect-error this is 'any' type\n const theme = this;\n if (theme.vars && typeof theme.getColorSchemeSelector === 'function') {\n // If CssVarsProvider is used as a provider,\n // returns '* :where([data-mui-color-scheme=\"light|dark\"]) &'\n const selector = theme.getColorSchemeSelector(key).replace(/(\\[[^\\]]+\\])/, '*:where($1)');\n return {\n [selector]: styles\n };\n }\n if (theme.palette.mode === key) {\n return styles;\n }\n return {};\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"breakpoints\", \"palette\", \"spacing\", \"shape\"];\nimport deepmerge from '@mui/utils/deepmerge';\nimport createBreakpoints from './createBreakpoints';\nimport shape from './shape';\nimport createSpacing from './createSpacing';\nimport styleFunctionSx from '../styleFunctionSx/styleFunctionSx';\nimport defaultSxConfig from '../styleFunctionSx/defaultSxConfig';\nimport applyStyles from './applyStyles';\nfunction createTheme(options = {}, ...args) {\n const {\n breakpoints: breakpointsInput = {},\n palette: paletteInput = {},\n spacing: spacingInput,\n shape: shapeInput = {}\n } = options,\n other = _objectWithoutPropertiesLoose(options, _excluded);\n const breakpoints = createBreakpoints(breakpointsInput);\n const spacing = createSpacing(spacingInput);\n let muiTheme = deepmerge({\n breakpoints,\n direction: 'ltr',\n components: {},\n // Inject component definitions.\n palette: _extends({\n mode: 'light'\n }, paletteInput),\n spacing,\n shape: _extends({}, shape, shapeInput)\n }, other);\n muiTheme.applyStyles = applyStyles;\n muiTheme = args.reduce((acc, argument) => deepmerge(acc, argument), muiTheme);\n muiTheme.unstable_sxConfig = _extends({}, defaultSxConfig, other == null ? void 0 : other.unstable_sxConfig);\n muiTheme.unstable_sx = function sx(props) {\n return styleFunctionSx({\n sx: props,\n theme: this\n });\n };\n return muiTheme;\n}\nexport default createTheme;","'use client';\n\nimport * as React from 'react';\nimport { ThemeContext } from '@mui/styled-engine';\nfunction isObjectEmpty(obj) {\n return Object.keys(obj).length === 0;\n}\nfunction useTheme(defaultTheme = null) {\n const contextTheme = React.useContext(ThemeContext);\n return !contextTheme || isObjectEmpty(contextTheme) ? defaultTheme : contextTheme;\n}\nexport default useTheme;","'use client';\n\nimport createTheme from './createTheme';\nimport useThemeWithoutDefault from './useThemeWithoutDefault';\nexport const systemDefaultTheme = createTheme();\nfunction useTheme(defaultTheme = systemDefaultTheme) {\n return useThemeWithoutDefault(defaultTheme);\n}\nexport default useTheme;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"ownerState\"],\n _excluded2 = [\"variants\"],\n _excluded3 = [\"name\", \"slot\", \"skipVariantsResolver\", \"skipSx\", \"overridesResolver\"];\n/* eslint-disable no-underscore-dangle */\nimport styledEngineStyled, { internal_processStyles as processStyles } from '@mui/styled-engine';\nimport { isPlainObject } from '@mui/utils/deepmerge';\nimport capitalize from '@mui/utils/capitalize';\nimport getDisplayName from '@mui/utils/getDisplayName';\nimport createTheme from './createTheme';\nimport styleFunctionSx from './styleFunctionSx';\nfunction isEmpty(obj) {\n return Object.keys(obj).length === 0;\n}\n\n// https://github.com/emotion-js/emotion/blob/26ded6109fcd8ca9875cc2ce4564fee678a3f3c5/packages/styled/src/utils.js#L40\nfunction isStringTag(tag) {\n return typeof tag === 'string' &&\n // 96 is one less than the char code\n // for \"a\" so this is checking that\n // it's a lowercase character\n tag.charCodeAt(0) > 96;\n}\n\n// Update /system/styled/#api in case if this changes\nexport function shouldForwardProp(prop) {\n return prop !== 'ownerState' && prop !== 'theme' && prop !== 'sx' && prop !== 'as';\n}\nexport const systemDefaultTheme = createTheme();\nconst lowercaseFirstLetter = string => {\n if (!string) {\n return string;\n }\n return string.charAt(0).toLowerCase() + string.slice(1);\n};\nfunction resolveTheme({\n defaultTheme,\n theme,\n themeId\n}) {\n return isEmpty(theme) ? defaultTheme : theme[themeId] || theme;\n}\nfunction defaultOverridesResolver(slot) {\n if (!slot) {\n return null;\n }\n return (props, styles) => styles[slot];\n}\nfunction processStyleArg(callableStyle, _ref) {\n let {\n ownerState\n } = _ref,\n props = _objectWithoutPropertiesLoose(_ref, _excluded);\n const resolvedStylesArg = typeof callableStyle === 'function' ? callableStyle(_extends({\n ownerState\n }, props)) : callableStyle;\n if (Array.isArray(resolvedStylesArg)) {\n return resolvedStylesArg.flatMap(resolvedStyle => processStyleArg(resolvedStyle, _extends({\n ownerState\n }, props)));\n }\n if (!!resolvedStylesArg && typeof resolvedStylesArg === 'object' && Array.isArray(resolvedStylesArg.variants)) {\n const {\n variants = []\n } = resolvedStylesArg,\n otherStyles = _objectWithoutPropertiesLoose(resolvedStylesArg, _excluded2);\n let result = otherStyles;\n variants.forEach(variant => {\n let isMatch = true;\n if (typeof variant.props === 'function') {\n isMatch = variant.props(_extends({\n ownerState\n }, props, ownerState));\n } else {\n Object.keys(variant.props).forEach(key => {\n if ((ownerState == null ? void 0 : ownerState[key]) !== variant.props[key] && props[key] !== variant.props[key]) {\n isMatch = false;\n }\n });\n }\n if (isMatch) {\n if (!Array.isArray(result)) {\n result = [result];\n }\n result.push(typeof variant.style === 'function' ? variant.style(_extends({\n ownerState\n }, props, ownerState)) : variant.style);\n }\n });\n return result;\n }\n return resolvedStylesArg;\n}\nexport default function createStyled(input = {}) {\n const {\n themeId,\n defaultTheme = systemDefaultTheme,\n rootShouldForwardProp = shouldForwardProp,\n slotShouldForwardProp = shouldForwardProp\n } = input;\n const systemSx = props => {\n return styleFunctionSx(_extends({}, props, {\n theme: resolveTheme(_extends({}, props, {\n defaultTheme,\n themeId\n }))\n }));\n };\n systemSx.__mui_systemSx = true;\n return (tag, inputOptions = {}) => {\n // Filter out the `sx` style function from the previous styled component to prevent unnecessary styles generated by the composite components.\n processStyles(tag, styles => styles.filter(style => !(style != null && style.__mui_systemSx)));\n const {\n name: componentName,\n slot: componentSlot,\n skipVariantsResolver: inputSkipVariantsResolver,\n skipSx: inputSkipSx,\n // TODO v6: remove `lowercaseFirstLetter()` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n overridesResolver = defaultOverridesResolver(lowercaseFirstLetter(componentSlot))\n } = inputOptions,\n options = _objectWithoutPropertiesLoose(inputOptions, _excluded3);\n\n // if skipVariantsResolver option is defined, take the value, otherwise, true for root and false for other slots.\n const skipVariantsResolver = inputSkipVariantsResolver !== undefined ? inputSkipVariantsResolver :\n // TODO v6: remove `Root` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n componentSlot && componentSlot !== 'Root' && componentSlot !== 'root' || false;\n const skipSx = inputSkipSx || false;\n let label;\n if (process.env.NODE_ENV !== 'production') {\n if (componentName) {\n // TODO v6: remove `lowercaseFirstLetter()` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n label = `${componentName}-${lowercaseFirstLetter(componentSlot || 'Root')}`;\n }\n }\n let shouldForwardPropOption = shouldForwardProp;\n\n // TODO v6: remove `Root` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n if (componentSlot === 'Root' || componentSlot === 'root') {\n shouldForwardPropOption = rootShouldForwardProp;\n } else if (componentSlot) {\n // any other slot specified\n shouldForwardPropOption = slotShouldForwardProp;\n } else if (isStringTag(tag)) {\n // for string (html) tag, preserve the behavior in emotion & styled-components.\n shouldForwardPropOption = undefined;\n }\n const defaultStyledResolver = styledEngineStyled(tag, _extends({\n shouldForwardProp: shouldForwardPropOption,\n label\n }, options));\n const transformStyleArg = stylesArg => {\n // On the server Emotion doesn't use React.forwardRef for creating components, so the created\n // component stays as a function. This condition makes sure that we do not interpolate functions\n // which are basically components used as a selectors.\n if (typeof stylesArg === 'function' && stylesArg.__emotion_real !== stylesArg || isPlainObject(stylesArg)) {\n return props => processStyleArg(stylesArg, _extends({}, props, {\n theme: resolveTheme({\n theme: props.theme,\n defaultTheme,\n themeId\n })\n }));\n }\n return stylesArg;\n };\n const muiStyledResolver = (styleArg, ...expressions) => {\n let transformedStyleArg = transformStyleArg(styleArg);\n const expressionsWithDefaultTheme = expressions ? expressions.map(transformStyleArg) : [];\n if (componentName && overridesResolver) {\n expressionsWithDefaultTheme.push(props => {\n const theme = resolveTheme(_extends({}, props, {\n defaultTheme,\n themeId\n }));\n if (!theme.components || !theme.components[componentName] || !theme.components[componentName].styleOverrides) {\n return null;\n }\n const styleOverrides = theme.components[componentName].styleOverrides;\n const resolvedStyleOverrides = {};\n // TODO: v7 remove iteration and use `resolveStyleArg(styleOverrides[slot])` directly\n Object.entries(styleOverrides).forEach(([slotKey, slotStyle]) => {\n resolvedStyleOverrides[slotKey] = processStyleArg(slotStyle, _extends({}, props, {\n theme\n }));\n });\n return overridesResolver(props, resolvedStyleOverrides);\n });\n }\n if (componentName && !skipVariantsResolver) {\n expressionsWithDefaultTheme.push(props => {\n var _theme$components;\n const theme = resolveTheme(_extends({}, props, {\n defaultTheme,\n themeId\n }));\n const themeVariants = theme == null || (_theme$components = theme.components) == null || (_theme$components = _theme$components[componentName]) == null ? void 0 : _theme$components.variants;\n return processStyleArg({\n variants: themeVariants\n }, _extends({}, props, {\n theme\n }));\n });\n }\n if (!skipSx) {\n expressionsWithDefaultTheme.push(systemSx);\n }\n const numOfCustomFnsApplied = expressionsWithDefaultTheme.length - expressions.length;\n if (Array.isArray(styleArg) && numOfCustomFnsApplied > 0) {\n const placeholders = new Array(numOfCustomFnsApplied).fill('');\n // If the type is array, than we need to add placeholders in the template for the overrides, variants and the sx styles.\n transformedStyleArg = [...styleArg, ...placeholders];\n transformedStyleArg.raw = [...styleArg.raw, ...placeholders];\n }\n const Component = defaultStyledResolver(transformedStyleArg, ...expressionsWithDefaultTheme);\n if (process.env.NODE_ENV !== 'production') {\n let displayName;\n if (componentName) {\n displayName = `${componentName}${capitalize(componentSlot || '')}`;\n }\n if (displayName === undefined) {\n displayName = `Styled(${getDisplayName(tag)})`;\n }\n Component.displayName = displayName;\n }\n if (tag.muiName) {\n Component.muiName = tag.muiName;\n }\n return Component;\n };\n if (defaultStyledResolver.withConfig) {\n muiStyledResolver.withConfig = defaultStyledResolver.withConfig;\n }\n return muiStyledResolver;\n };\n}","import resolveProps from '@mui/utils/resolveProps';\nexport default function getThemeProps(params) {\n const {\n theme,\n name,\n props\n } = params;\n if (!theme || !theme.components || !theme.components[name] || !theme.components[name].defaultProps) {\n return props;\n }\n return resolveProps(theme.components[name].defaultProps, props);\n}","'use client';\n\nimport getThemeProps from './getThemeProps';\nimport useTheme from '../useTheme';\nexport default function useThemeProps({\n props,\n name,\n defaultTheme,\n themeId\n}) {\n let theme = useTheme(defaultTheme);\n if (themeId) {\n theme = theme[themeId] || theme;\n }\n const mergedProps = getThemeProps({\n theme,\n name,\n props\n });\n return mergedProps;\n}","import _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\n/* eslint-disable @typescript-eslint/naming-convention */\nimport clamp from '@mui/utils/clamp';\n/**\n * Returns a number whose value is limited to the given range.\n * @param {number} value The value to be clamped\n * @param {number} min The lower boundary of the output range\n * @param {number} max The upper boundary of the output range\n * @returns {number} A number in the range [min, max]\n */\nfunction clampWrapper(value, min = 0, max = 1) {\n if (process.env.NODE_ENV !== 'production') {\n if (value < min || value > max) {\n console.error(`MUI: The value provided ${value} is out of range [${min}, ${max}].`);\n }\n }\n return clamp(value, min, max);\n}\n\n/**\n * Converts a color from CSS hex format to CSS rgb format.\n * @param {string} color - Hex color, i.e. #nnn or #nnnnnn\n * @returns {string} A CSS rgb color string\n */\nexport function hexToRgb(color) {\n color = color.slice(1);\n const re = new RegExp(`.{1,${color.length >= 6 ? 2 : 1}}`, 'g');\n let colors = color.match(re);\n if (colors && colors[0].length === 1) {\n colors = colors.map(n => n + n);\n }\n return colors ? `rgb${colors.length === 4 ? 'a' : ''}(${colors.map((n, index) => {\n return index < 3 ? parseInt(n, 16) : Math.round(parseInt(n, 16) / 255 * 1000) / 1000;\n }).join(', ')})` : '';\n}\nfunction intToHex(int) {\n const hex = int.toString(16);\n return hex.length === 1 ? `0${hex}` : hex;\n}\n\n/**\n * Returns an object with the type and values of a color.\n *\n * Note: Does not support rgb % values.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @returns {object} - A MUI color object: {type: string, values: number[]}\n */\nexport function decomposeColor(color) {\n // Idempotent\n if (color.type) {\n return color;\n }\n if (color.charAt(0) === '#') {\n return decomposeColor(hexToRgb(color));\n }\n const marker = color.indexOf('(');\n const type = color.substring(0, marker);\n if (['rgb', 'rgba', 'hsl', 'hsla', 'color'].indexOf(type) === -1) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: Unsupported \\`${color}\\` color.\nThe following formats are supported: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color().` : _formatMuiErrorMessage(9, color));\n }\n let values = color.substring(marker + 1, color.length - 1);\n let colorSpace;\n if (type === 'color') {\n values = values.split(' ');\n colorSpace = values.shift();\n if (values.length === 4 && values[3].charAt(0) === '/') {\n values[3] = values[3].slice(1);\n }\n if (['srgb', 'display-p3', 'a98-rgb', 'prophoto-rgb', 'rec-2020'].indexOf(colorSpace) === -1) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: unsupported \\`${colorSpace}\\` color space.\nThe following color spaces are supported: srgb, display-p3, a98-rgb, prophoto-rgb, rec-2020.` : _formatMuiErrorMessage(10, colorSpace));\n }\n } else {\n values = values.split(',');\n }\n values = values.map(value => parseFloat(value));\n return {\n type,\n values,\n colorSpace\n };\n}\n\n/**\n * Returns a channel created from the input color.\n *\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @returns {string} - The channel for the color, that can be used in rgba or hsla colors\n */\nexport const colorChannel = color => {\n const decomposedColor = decomposeColor(color);\n return decomposedColor.values.slice(0, 3).map((val, idx) => decomposedColor.type.indexOf('hsl') !== -1 && idx !== 0 ? `${val}%` : val).join(' ');\n};\nexport const private_safeColorChannel = (color, warning) => {\n try {\n return colorChannel(color);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n};\n\n/**\n * Converts a color object with type and values to a string.\n * @param {object} color - Decomposed color\n * @param {string} color.type - One of: 'rgb', 'rgba', 'hsl', 'hsla', 'color'\n * @param {array} color.values - [n,n,n] or [n,n,n,n]\n * @returns {string} A CSS color string\n */\nexport function recomposeColor(color) {\n const {\n type,\n colorSpace\n } = color;\n let {\n values\n } = color;\n if (type.indexOf('rgb') !== -1) {\n // Only convert the first 3 values to int (i.e. not alpha)\n values = values.map((n, i) => i < 3 ? parseInt(n, 10) : n);\n } else if (type.indexOf('hsl') !== -1) {\n values[1] = `${values[1]}%`;\n values[2] = `${values[2]}%`;\n }\n if (type.indexOf('color') !== -1) {\n values = `${colorSpace} ${values.join(' ')}`;\n } else {\n values = `${values.join(', ')}`;\n }\n return `${type}(${values})`;\n}\n\n/**\n * Converts a color from CSS rgb format to CSS hex format.\n * @param {string} color - RGB color, i.e. rgb(n, n, n)\n * @returns {string} A CSS rgb color string, i.e. #nnnnnn\n */\nexport function rgbToHex(color) {\n // Idempotent\n if (color.indexOf('#') === 0) {\n return color;\n }\n const {\n values\n } = decomposeColor(color);\n return `#${values.map((n, i) => intToHex(i === 3 ? Math.round(255 * n) : n)).join('')}`;\n}\n\n/**\n * Converts a color from hsl format to rgb format.\n * @param {string} color - HSL color values\n * @returns {string} rgb color values\n */\nexport function hslToRgb(color) {\n color = decomposeColor(color);\n const {\n values\n } = color;\n const h = values[0];\n const s = values[1] / 100;\n const l = values[2] / 100;\n const a = s * Math.min(l, 1 - l);\n const f = (n, k = (n + h / 30) % 12) => l - a * Math.max(Math.min(k - 3, 9 - k, 1), -1);\n let type = 'rgb';\n const rgb = [Math.round(f(0) * 255), Math.round(f(8) * 255), Math.round(f(4) * 255)];\n if (color.type === 'hsla') {\n type += 'a';\n rgb.push(values[3]);\n }\n return recomposeColor({\n type,\n values: rgb\n });\n}\n/**\n * The relative brightness of any point in a color space,\n * normalized to 0 for darkest black and 1 for lightest white.\n *\n * Formula: https://www.w3.org/TR/WCAG20-TECHS/G17.html#G17-tests\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @returns {number} The relative brightness of the color in the range 0 - 1\n */\nexport function getLuminance(color) {\n color = decomposeColor(color);\n let rgb = color.type === 'hsl' || color.type === 'hsla' ? decomposeColor(hslToRgb(color)).values : color.values;\n rgb = rgb.map(val => {\n if (color.type !== 'color') {\n val /= 255; // normalized\n }\n return val <= 0.03928 ? val / 12.92 : ((val + 0.055) / 1.055) ** 2.4;\n });\n\n // Truncate at 3 digits\n return Number((0.2126 * rgb[0] + 0.7152 * rgb[1] + 0.0722 * rgb[2]).toFixed(3));\n}\n\n/**\n * Calculates the contrast ratio between two colors.\n *\n * Formula: https://www.w3.org/TR/WCAG20-TECHS/G17.html#G17-tests\n * @param {string} foreground - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla()\n * @param {string} background - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla()\n * @returns {number} A contrast ratio value in the range 0 - 21.\n */\nexport function getContrastRatio(foreground, background) {\n const lumA = getLuminance(foreground);\n const lumB = getLuminance(background);\n return (Math.max(lumA, lumB) + 0.05) / (Math.min(lumA, lumB) + 0.05);\n}\n\n/**\n * Sets the absolute transparency of a color.\n * Any existing alpha values are overwritten.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} value - value to set the alpha channel to in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function alpha(color, value) {\n color = decomposeColor(color);\n value = clampWrapper(value);\n if (color.type === 'rgb' || color.type === 'hsl') {\n color.type += 'a';\n }\n if (color.type === 'color') {\n color.values[3] = `/${value}`;\n } else {\n color.values[3] = value;\n }\n return recomposeColor(color);\n}\nexport function private_safeAlpha(color, value, warning) {\n try {\n return alpha(color, value);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Darkens a color.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} coefficient - multiplier in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function darken(color, coefficient) {\n color = decomposeColor(color);\n coefficient = clampWrapper(coefficient);\n if (color.type.indexOf('hsl') !== -1) {\n color.values[2] *= 1 - coefficient;\n } else if (color.type.indexOf('rgb') !== -1 || color.type.indexOf('color') !== -1) {\n for (let i = 0; i < 3; i += 1) {\n color.values[i] *= 1 - coefficient;\n }\n }\n return recomposeColor(color);\n}\nexport function private_safeDarken(color, coefficient, warning) {\n try {\n return darken(color, coefficient);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Lightens a color.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} coefficient - multiplier in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function lighten(color, coefficient) {\n color = decomposeColor(color);\n coefficient = clampWrapper(coefficient);\n if (color.type.indexOf('hsl') !== -1) {\n color.values[2] += (100 - color.values[2]) * coefficient;\n } else if (color.type.indexOf('rgb') !== -1) {\n for (let i = 0; i < 3; i += 1) {\n color.values[i] += (255 - color.values[i]) * coefficient;\n }\n } else if (color.type.indexOf('color') !== -1) {\n for (let i = 0; i < 3; i += 1) {\n color.values[i] += (1 - color.values[i]) * coefficient;\n }\n }\n return recomposeColor(color);\n}\nexport function private_safeLighten(color, coefficient, warning) {\n try {\n return lighten(color, coefficient);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Darken or lighten a color, depending on its luminance.\n * Light colors are darkened, dark colors are lightened.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} coefficient=0.15 - multiplier in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function emphasize(color, coefficient = 0.15) {\n return getLuminance(color) > 0.5 ? darken(color, coefficient) : lighten(color, coefficient);\n}\nexport function private_safeEmphasize(color, coefficient, warning) {\n try {\n return emphasize(color, coefficient);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Blend a transparent overlay color with a background color, resulting in a single\n * RGB color.\n * @param {string} background - CSS color\n * @param {string} overlay - CSS color\n * @param {number} opacity - Opacity multiplier in the range 0 - 1\n * @param {number} [gamma=1.0] - Gamma correction factor. For gamma-correct blending, 2.2 is usual.\n */\nexport function blend(background, overlay, opacity, gamma = 1.0) {\n const blendChannel = (b, o) => Math.round((b ** (1 / gamma) * (1 - opacity) + o ** (1 / gamma) * opacity) ** gamma);\n const backgroundColor = decomposeColor(background);\n const overlayColor = decomposeColor(overlay);\n const rgb = [blendChannel(backgroundColor.values[0], overlayColor.values[0]), blendChannel(backgroundColor.values[1], overlayColor.values[1]), blendChannel(backgroundColor.values[2], overlayColor.values[2])];\n return recomposeColor({\n type: 'rgb',\n values: rgb\n });\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nexport default function createMixins(breakpoints, mixins) {\n return _extends({\n toolbar: {\n minHeight: 56,\n [breakpoints.up('xs')]: {\n '@media (orientation: landscape)': {\n minHeight: 48\n }\n },\n [breakpoints.up('sm')]: {\n minHeight: 64\n }\n }\n }, mixins);\n}","const common = {\n black: '#000',\n white: '#fff'\n};\nexport default common;","const grey = {\n 50: '#fafafa',\n 100: '#f5f5f5',\n 200: '#eeeeee',\n 300: '#e0e0e0',\n 400: '#bdbdbd',\n 500: '#9e9e9e',\n 600: '#757575',\n 700: '#616161',\n 800: '#424242',\n 900: '#212121',\n A100: '#f5f5f5',\n A200: '#eeeeee',\n A400: '#bdbdbd',\n A700: '#616161'\n};\nexport default grey;","const purple = {\n 50: '#f3e5f5',\n 100: '#e1bee7',\n 200: '#ce93d8',\n 300: '#ba68c8',\n 400: '#ab47bc',\n 500: '#9c27b0',\n 600: '#8e24aa',\n 700: '#7b1fa2',\n 800: '#6a1b9a',\n 900: '#4a148c',\n A100: '#ea80fc',\n A200: '#e040fb',\n A400: '#d500f9',\n A700: '#aa00ff'\n};\nexport default purple;","const red = {\n 50: '#ffebee',\n 100: '#ffcdd2',\n 200: '#ef9a9a',\n 300: '#e57373',\n 400: '#ef5350',\n 500: '#f44336',\n 600: '#e53935',\n 700: '#d32f2f',\n 800: '#c62828',\n 900: '#b71c1c',\n A100: '#ff8a80',\n A200: '#ff5252',\n A400: '#ff1744',\n A700: '#d50000'\n};\nexport default red;","const orange = {\n 50: '#fff3e0',\n 100: '#ffe0b2',\n 200: '#ffcc80',\n 300: '#ffb74d',\n 400: '#ffa726',\n 500: '#ff9800',\n 600: '#fb8c00',\n 700: '#f57c00',\n 800: '#ef6c00',\n 900: '#e65100',\n A100: '#ffd180',\n A200: '#ffab40',\n A400: '#ff9100',\n A700: '#ff6d00'\n};\nexport default orange;","const blue = {\n 50: '#e3f2fd',\n 100: '#bbdefb',\n 200: '#90caf9',\n 300: '#64b5f6',\n 400: '#42a5f5',\n 500: '#2196f3',\n 600: '#1e88e5',\n 700: '#1976d2',\n 800: '#1565c0',\n 900: '#0d47a1',\n A100: '#82b1ff',\n A200: '#448aff',\n A400: '#2979ff',\n A700: '#2962ff'\n};\nexport default blue;","const lightBlue = {\n 50: '#e1f5fe',\n 100: '#b3e5fc',\n 200: '#81d4fa',\n 300: '#4fc3f7',\n 400: '#29b6f6',\n 500: '#03a9f4',\n 600: '#039be5',\n 700: '#0288d1',\n 800: '#0277bd',\n 900: '#01579b',\n A100: '#80d8ff',\n A200: '#40c4ff',\n A400: '#00b0ff',\n A700: '#0091ea'\n};\nexport default lightBlue;","const green = {\n 50: '#e8f5e9',\n 100: '#c8e6c9',\n 200: '#a5d6a7',\n 300: '#81c784',\n 400: '#66bb6a',\n 500: '#4caf50',\n 600: '#43a047',\n 700: '#388e3c',\n 800: '#2e7d32',\n 900: '#1b5e20',\n A100: '#b9f6ca',\n A200: '#69f0ae',\n A400: '#00e676',\n A700: '#00c853'\n};\nexport default green;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\nconst _excluded = [\"mode\", \"contrastThreshold\", \"tonalOffset\"];\nimport { deepmerge } from '@mui/utils';\nimport { darken, getContrastRatio, lighten } from '@mui/system';\nimport common from '../colors/common';\nimport grey from '../colors/grey';\nimport purple from '../colors/purple';\nimport red from '../colors/red';\nimport orange from '../colors/orange';\nimport blue from '../colors/blue';\nimport lightBlue from '../colors/lightBlue';\nimport green from '../colors/green';\nexport const light = {\n // The colors used to style the text.\n text: {\n // The most important text.\n primary: 'rgba(0, 0, 0, 0.87)',\n // Secondary text.\n secondary: 'rgba(0, 0, 0, 0.6)',\n // Disabled text have even lower visual prominence.\n disabled: 'rgba(0, 0, 0, 0.38)'\n },\n // The color used to divide different elements.\n divider: 'rgba(0, 0, 0, 0.12)',\n // The background colors used to style the surfaces.\n // Consistency between these values is important.\n background: {\n paper: common.white,\n default: common.white\n },\n // The colors used to style the action elements.\n action: {\n // The color of an active action like an icon button.\n active: 'rgba(0, 0, 0, 0.54)',\n // The color of an hovered action.\n hover: 'rgba(0, 0, 0, 0.04)',\n hoverOpacity: 0.04,\n // The color of a selected action.\n selected: 'rgba(0, 0, 0, 0.08)',\n selectedOpacity: 0.08,\n // The color of a disabled action.\n disabled: 'rgba(0, 0, 0, 0.26)',\n // The background color of a disabled action.\n disabledBackground: 'rgba(0, 0, 0, 0.12)',\n disabledOpacity: 0.38,\n focus: 'rgba(0, 0, 0, 0.12)',\n focusOpacity: 0.12,\n activatedOpacity: 0.12\n }\n};\nexport const dark = {\n text: {\n primary: common.white,\n secondary: 'rgba(255, 255, 255, 0.7)',\n disabled: 'rgba(255, 255, 255, 0.5)',\n icon: 'rgba(255, 255, 255, 0.5)'\n },\n divider: 'rgba(255, 255, 255, 0.12)',\n background: {\n paper: '#121212',\n default: '#121212'\n },\n action: {\n active: common.white,\n hover: 'rgba(255, 255, 255, 0.08)',\n hoverOpacity: 0.08,\n selected: 'rgba(255, 255, 255, 0.16)',\n selectedOpacity: 0.16,\n disabled: 'rgba(255, 255, 255, 0.3)',\n disabledBackground: 'rgba(255, 255, 255, 0.12)',\n disabledOpacity: 0.38,\n focus: 'rgba(255, 255, 255, 0.12)',\n focusOpacity: 0.12,\n activatedOpacity: 0.24\n }\n};\nfunction addLightOrDark(intent, direction, shade, tonalOffset) {\n const tonalOffsetLight = tonalOffset.light || tonalOffset;\n const tonalOffsetDark = tonalOffset.dark || tonalOffset * 1.5;\n if (!intent[direction]) {\n if (intent.hasOwnProperty(shade)) {\n intent[direction] = intent[shade];\n } else if (direction === 'light') {\n intent.light = lighten(intent.main, tonalOffsetLight);\n } else if (direction === 'dark') {\n intent.dark = darken(intent.main, tonalOffsetDark);\n }\n }\n}\nfunction getDefaultPrimary(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: blue[200],\n light: blue[50],\n dark: blue[400]\n };\n }\n return {\n main: blue[700],\n light: blue[400],\n dark: blue[800]\n };\n}\nfunction getDefaultSecondary(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: purple[200],\n light: purple[50],\n dark: purple[400]\n };\n }\n return {\n main: purple[500],\n light: purple[300],\n dark: purple[700]\n };\n}\nfunction getDefaultError(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: red[500],\n light: red[300],\n dark: red[700]\n };\n }\n return {\n main: red[700],\n light: red[400],\n dark: red[800]\n };\n}\nfunction getDefaultInfo(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: lightBlue[400],\n light: lightBlue[300],\n dark: lightBlue[700]\n };\n }\n return {\n main: lightBlue[700],\n light: lightBlue[500],\n dark: lightBlue[900]\n };\n}\nfunction getDefaultSuccess(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: green[400],\n light: green[300],\n dark: green[700]\n };\n }\n return {\n main: green[800],\n light: green[500],\n dark: green[900]\n };\n}\nfunction getDefaultWarning(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: orange[400],\n light: orange[300],\n dark: orange[700]\n };\n }\n return {\n main: '#ed6c02',\n // closest to orange[800] that pass 3:1.\n light: orange[500],\n dark: orange[900]\n };\n}\nexport default function createPalette(palette) {\n const {\n mode = 'light',\n contrastThreshold = 3,\n tonalOffset = 0.2\n } = palette,\n other = _objectWithoutPropertiesLoose(palette, _excluded);\n const primary = palette.primary || getDefaultPrimary(mode);\n const secondary = palette.secondary || getDefaultSecondary(mode);\n const error = palette.error || getDefaultError(mode);\n const info = palette.info || getDefaultInfo(mode);\n const success = palette.success || getDefaultSuccess(mode);\n const warning = palette.warning || getDefaultWarning(mode);\n\n // Use the same logic as\n // Bootstrap: https://github.com/twbs/bootstrap/blob/1d6e3710dd447de1a200f29e8fa521f8a0908f70/scss/_functions.scss#L59\n // and material-components-web https://github.com/material-components/material-components-web/blob/ac46b8863c4dab9fc22c4c662dc6bd1b65dd652f/packages/mdc-theme/_functions.scss#L54\n function getContrastText(background) {\n const contrastText = getContrastRatio(background, dark.text.primary) >= contrastThreshold ? dark.text.primary : light.text.primary;\n if (process.env.NODE_ENV !== 'production') {\n const contrast = getContrastRatio(background, contrastText);\n if (contrast < 3) {\n console.error([`MUI: The contrast ratio of ${contrast}:1 for ${contrastText} on ${background}`, 'falls below the WCAG recommended absolute minimum contrast ratio of 3:1.', 'https://www.w3.org/TR/2008/REC-WCAG20-20081211/#visual-audio-contrast-contrast'].join('\\n'));\n }\n }\n return contrastText;\n }\n const augmentColor = ({\n color,\n name,\n mainShade = 500,\n lightShade = 300,\n darkShade = 700\n }) => {\n color = _extends({}, color);\n if (!color.main && color[mainShade]) {\n color.main = color[mainShade];\n }\n if (!color.hasOwnProperty('main')) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: The color${name ? ` (${name})` : ''} provided to augmentColor(color) is invalid.\nThe color object needs to have a \\`main\\` property or a \\`${mainShade}\\` property.` : _formatMuiErrorMessage(11, name ? ` (${name})` : '', mainShade));\n }\n if (typeof color.main !== 'string') {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: The color${name ? ` (${name})` : ''} provided to augmentColor(color) is invalid.\n\\`color.main\\` should be a string, but \\`${JSON.stringify(color.main)}\\` was provided instead.\n\nDid you intend to use one of the following approaches?\n\nimport { green } from \"@mui/material/colors\";\n\nconst theme1 = createTheme({ palette: {\n primary: green,\n} });\n\nconst theme2 = createTheme({ palette: {\n primary: { main: green[500] },\n} });` : _formatMuiErrorMessage(12, name ? ` (${name})` : '', JSON.stringify(color.main)));\n }\n addLightOrDark(color, 'light', lightShade, tonalOffset);\n addLightOrDark(color, 'dark', darkShade, tonalOffset);\n if (!color.contrastText) {\n color.contrastText = getContrastText(color.main);\n }\n return color;\n };\n const modes = {\n dark,\n light\n };\n if (process.env.NODE_ENV !== 'production') {\n if (!modes[mode]) {\n console.error(`MUI: The palette mode \\`${mode}\\` is not supported.`);\n }\n }\n const paletteOutput = deepmerge(_extends({\n // A collection of common colors.\n common: _extends({}, common),\n // prevent mutable object.\n // The palette mode, can be light or dark.\n mode,\n // The colors used to represent primary interface elements for a user.\n primary: augmentColor({\n color: primary,\n name: 'primary'\n }),\n // The colors used to represent secondary interface elements for a user.\n secondary: augmentColor({\n color: secondary,\n name: 'secondary',\n mainShade: 'A400',\n lightShade: 'A200',\n darkShade: 'A700'\n }),\n // The colors used to represent interface elements that the user should be made aware of.\n error: augmentColor({\n color: error,\n name: 'error'\n }),\n // The colors used to represent potentially dangerous actions or important messages.\n warning: augmentColor({\n color: warning,\n name: 'warning'\n }),\n // The colors used to present information to the user that is neutral and not necessarily important.\n info: augmentColor({\n color: info,\n name: 'info'\n }),\n // The colors used to indicate the successful completion of an action that user triggered.\n success: augmentColor({\n color: success,\n name: 'success'\n }),\n // The grey colors.\n grey,\n // Used by `getContrastText()` to maximize the contrast between\n // the background and the text.\n contrastThreshold,\n // Takes a background color and returns the text color that maximizes the contrast.\n getContrastText,\n // Generate a rich color object.\n augmentColor,\n // Used by the functions below to shift a color's luminance by approximately\n // two indexes within its tonal palette.\n // E.g., shift from Red 500 to Red 300 or Red 700.\n tonalOffset\n }, modes[mode]), other);\n return paletteOutput;\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"fontFamily\", \"fontSize\", \"fontWeightLight\", \"fontWeightRegular\", \"fontWeightMedium\", \"fontWeightBold\", \"htmlFontSize\", \"allVariants\", \"pxToRem\"];\nimport { deepmerge } from '@mui/utils';\nfunction round(value) {\n return Math.round(value * 1e5) / 1e5;\n}\nconst caseAllCaps = {\n textTransform: 'uppercase'\n};\nconst defaultFontFamily = '\"Roboto\", \"Helvetica\", \"Arial\", sans-serif';\n\n/**\n * @see @link{https://m2.material.io/design/typography/the-type-system.html}\n * @see @link{https://m2.material.io/design/typography/understanding-typography.html}\n */\nexport default function createTypography(palette, typography) {\n const _ref = typeof typography === 'function' ? typography(palette) : typography,\n {\n fontFamily = defaultFontFamily,\n // The default font size of the Material Specification.\n fontSize = 14,\n // px\n fontWeightLight = 300,\n fontWeightRegular = 400,\n fontWeightMedium = 500,\n fontWeightBold = 700,\n // Tell MUI what's the font-size on the html element.\n // 16px is the default font-size used by browsers.\n htmlFontSize = 16,\n // Apply the CSS properties to all the variants.\n allVariants,\n pxToRem: pxToRem2\n } = _ref,\n other = _objectWithoutPropertiesLoose(_ref, _excluded);\n if (process.env.NODE_ENV !== 'production') {\n if (typeof fontSize !== 'number') {\n console.error('MUI: `fontSize` is required to be a number.');\n }\n if (typeof htmlFontSize !== 'number') {\n console.error('MUI: `htmlFontSize` is required to be a number.');\n }\n }\n const coef = fontSize / 14;\n const pxToRem = pxToRem2 || (size => `${size / htmlFontSize * coef}rem`);\n const buildVariant = (fontWeight, size, lineHeight, letterSpacing, casing) => _extends({\n fontFamily,\n fontWeight,\n fontSize: pxToRem(size),\n // Unitless following https://meyerweb.com/eric/thoughts/2006/02/08/unitless-line-heights/\n lineHeight\n }, fontFamily === defaultFontFamily ? {\n letterSpacing: `${round(letterSpacing / size)}em`\n } : {}, casing, allVariants);\n const variants = {\n h1: buildVariant(fontWeightLight, 96, 1.167, -1.5),\n h2: buildVariant(fontWeightLight, 60, 1.2, -0.5),\n h3: buildVariant(fontWeightRegular, 48, 1.167, 0),\n h4: buildVariant(fontWeightRegular, 34, 1.235, 0.25),\n h5: buildVariant(fontWeightRegular, 24, 1.334, 0),\n h6: buildVariant(fontWeightMedium, 20, 1.6, 0.15),\n subtitle1: buildVariant(fontWeightRegular, 16, 1.75, 0.15),\n subtitle2: buildVariant(fontWeightMedium, 14, 1.57, 0.1),\n body1: buildVariant(fontWeightRegular, 16, 1.5, 0.15),\n body2: buildVariant(fontWeightRegular, 14, 1.43, 0.15),\n button: buildVariant(fontWeightMedium, 14, 1.75, 0.4, caseAllCaps),\n caption: buildVariant(fontWeightRegular, 12, 1.66, 0.4),\n overline: buildVariant(fontWeightRegular, 12, 2.66, 1, caseAllCaps),\n // TODO v6: Remove handling of 'inherit' variant from the theme as it is already handled in Material UI's Typography component. Also, remember to remove the associated types.\n inherit: {\n fontFamily: 'inherit',\n fontWeight: 'inherit',\n fontSize: 'inherit',\n lineHeight: 'inherit',\n letterSpacing: 'inherit'\n }\n };\n return deepmerge(_extends({\n htmlFontSize,\n pxToRem,\n fontFamily,\n fontSize,\n fontWeightLight,\n fontWeightRegular,\n fontWeightMedium,\n fontWeightBold\n }, variants), other, {\n clone: false // No need to clone deep\n });\n}","const shadowKeyUmbraOpacity = 0.2;\nconst shadowKeyPenumbraOpacity = 0.14;\nconst shadowAmbientShadowOpacity = 0.12;\nfunction createShadow(...px) {\n return [`${px[0]}px ${px[1]}px ${px[2]}px ${px[3]}px rgba(0,0,0,${shadowKeyUmbraOpacity})`, `${px[4]}px ${px[5]}px ${px[6]}px ${px[7]}px rgba(0,0,0,${shadowKeyPenumbraOpacity})`, `${px[8]}px ${px[9]}px ${px[10]}px ${px[11]}px rgba(0,0,0,${shadowAmbientShadowOpacity})`].join(',');\n}\n\n// Values from https://github.com/material-components/material-components-web/blob/be8747f94574669cb5e7add1a7c54fa41a89cec7/packages/mdc-elevation/_variables.scss\nconst shadows = ['none', createShadow(0, 2, 1, -1, 0, 1, 1, 0, 0, 1, 3, 0), createShadow(0, 3, 1, -2, 0, 2, 2, 0, 0, 1, 5, 0), createShadow(0, 3, 3, -2, 0, 3, 4, 0, 0, 1, 8, 0), createShadow(0, 2, 4, -1, 0, 4, 5, 0, 0, 1, 10, 0), createShadow(0, 3, 5, -1, 0, 5, 8, 0, 0, 1, 14, 0), createShadow(0, 3, 5, -1, 0, 6, 10, 0, 0, 1, 18, 0), createShadow(0, 4, 5, -2, 0, 7, 10, 1, 0, 2, 16, 1), createShadow(0, 5, 5, -3, 0, 8, 10, 1, 0, 3, 14, 2), createShadow(0, 5, 6, -3, 0, 9, 12, 1, 0, 3, 16, 2), createShadow(0, 6, 6, -3, 0, 10, 14, 1, 0, 4, 18, 3), createShadow(0, 6, 7, -4, 0, 11, 15, 1, 0, 4, 20, 3), createShadow(0, 7, 8, -4, 0, 12, 17, 2, 0, 5, 22, 4), createShadow(0, 7, 8, -4, 0, 13, 19, 2, 0, 5, 24, 4), createShadow(0, 7, 9, -4, 0, 14, 21, 2, 0, 5, 26, 4), createShadow(0, 8, 9, -5, 0, 15, 22, 2, 0, 6, 28, 5), createShadow(0, 8, 10, -5, 0, 16, 24, 2, 0, 6, 30, 5), createShadow(0, 8, 11, -5, 0, 17, 26, 2, 0, 6, 32, 5), createShadow(0, 9, 11, -5, 0, 18, 28, 2, 0, 7, 34, 6), createShadow(0, 9, 12, -6, 0, 19, 29, 2, 0, 7, 36, 6), createShadow(0, 10, 13, -6, 0, 20, 31, 3, 0, 8, 38, 7), createShadow(0, 10, 13, -6, 0, 21, 33, 3, 0, 8, 40, 7), createShadow(0, 10, 14, -6, 0, 22, 35, 3, 0, 8, 42, 7), createShadow(0, 11, 14, -7, 0, 23, 36, 3, 0, 9, 44, 8), createShadow(0, 11, 15, -7, 0, 24, 38, 3, 0, 9, 46, 8)];\nexport default shadows;","import _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nconst _excluded = [\"duration\", \"easing\", \"delay\"];\n// Follow https://material.google.com/motion/duration-easing.html#duration-easing-natural-easing-curves\n// to learn the context in which each easing should be used.\nexport const easing = {\n // This is the most common easing curve.\n easeInOut: 'cubic-bezier(0.4, 0, 0.2, 1)',\n // Objects enter the screen at full velocity from off-screen and\n // slowly decelerate to a resting point.\n easeOut: 'cubic-bezier(0.0, 0, 0.2, 1)',\n // Objects leave the screen at full velocity. They do not decelerate when off-screen.\n easeIn: 'cubic-bezier(0.4, 0, 1, 1)',\n // The sharp curve is used by objects that may return to the screen at any time.\n sharp: 'cubic-bezier(0.4, 0, 0.6, 1)'\n};\n\n// Follow https://m2.material.io/guidelines/motion/duration-easing.html#duration-easing-common-durations\n// to learn when use what timing\nexport const duration = {\n shortest: 150,\n shorter: 200,\n short: 250,\n // most basic recommended timing\n standard: 300,\n // this is to be used in complex animations\n complex: 375,\n // recommended when something is entering screen\n enteringScreen: 225,\n // recommended when something is leaving screen\n leavingScreen: 195\n};\nfunction formatMs(milliseconds) {\n return `${Math.round(milliseconds)}ms`;\n}\nfunction getAutoHeightDuration(height) {\n if (!height) {\n return 0;\n }\n const constant = height / 36;\n\n // https://www.wolframalpha.com/input/?i=(4+%2B+15+*+(x+%2F+36+)+**+0.25+%2B+(x+%2F+36)+%2F+5)+*+10\n return Math.round((4 + 15 * constant ** 0.25 + constant / 5) * 10);\n}\nexport default function createTransitions(inputTransitions) {\n const mergedEasing = _extends({}, easing, inputTransitions.easing);\n const mergedDuration = _extends({}, duration, inputTransitions.duration);\n const create = (props = ['all'], options = {}) => {\n const {\n duration: durationOption = mergedDuration.standard,\n easing: easingOption = mergedEasing.easeInOut,\n delay = 0\n } = options,\n other = _objectWithoutPropertiesLoose(options, _excluded);\n if (process.env.NODE_ENV !== 'production') {\n const isString = value => typeof value === 'string';\n // IE11 support, replace with Number.isNaN\n // eslint-disable-next-line no-restricted-globals\n const isNumber = value => !isNaN(parseFloat(value));\n if (!isString(props) && !Array.isArray(props)) {\n console.error('MUI: Argument \"props\" must be a string or Array.');\n }\n if (!isNumber(durationOption) && !isString(durationOption)) {\n console.error(`MUI: Argument \"duration\" must be a number or a string but found ${durationOption}.`);\n }\n if (!isString(easingOption)) {\n console.error('MUI: Argument \"easing\" must be a string.');\n }\n if (!isNumber(delay) && !isString(delay)) {\n console.error('MUI: Argument \"delay\" must be a number or a string.');\n }\n if (typeof options !== 'object') {\n console.error(['MUI: Secong argument of transition.create must be an object.', \"Arguments should be either `create('prop1', options)` or `create(['prop1', 'prop2'], options)`\"].join('\\n'));\n }\n if (Object.keys(other).length !== 0) {\n console.error(`MUI: Unrecognized argument(s) [${Object.keys(other).join(',')}].`);\n }\n }\n return (Array.isArray(props) ? props : [props]).map(animatedProp => `${animatedProp} ${typeof durationOption === 'string' ? durationOption : formatMs(durationOption)} ${easingOption} ${typeof delay === 'string' ? delay : formatMs(delay)}`).join(',');\n };\n return _extends({\n getAutoHeightDuration,\n create\n }, inputTransitions, {\n easing: mergedEasing,\n duration: mergedDuration\n });\n}","// We need to centralize the zIndex definitions as they work\n// like global values in the browser.\nconst zIndex = {\n mobileStepper: 1000,\n fab: 1050,\n speedDial: 1050,\n appBar: 1100,\n drawer: 1200,\n modal: 1300,\n snackbar: 1400,\n tooltip: 1500\n};\nexport default zIndex;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\nconst _excluded = [\"breakpoints\", \"mixins\", \"spacing\", \"palette\", \"transitions\", \"typography\", \"shape\"];\nimport { deepmerge } from '@mui/utils';\nimport { createTheme as systemCreateTheme, unstable_defaultSxConfig as defaultSxConfig, unstable_styleFunctionSx as styleFunctionSx } from '@mui/system';\nimport generateUtilityClass from '@mui/utils/generateUtilityClass';\nimport createMixins from './createMixins';\nimport createPalette from './createPalette';\nimport createTypography from './createTypography';\nimport shadows from './shadows';\nimport createTransitions from './createTransitions';\nimport zIndex from './zIndex';\nfunction createTheme(options = {}, ...args) {\n const {\n mixins: mixinsInput = {},\n palette: paletteInput = {},\n transitions: transitionsInput = {},\n typography: typographyInput = {}\n } = options,\n other = _objectWithoutPropertiesLoose(options, _excluded);\n if (options.vars) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: \\`vars\\` is a private field used for CSS variables support.\nPlease use another name.` : _formatMuiErrorMessage(18));\n }\n const palette = createPalette(paletteInput);\n const systemTheme = systemCreateTheme(options);\n let muiTheme = deepmerge(systemTheme, {\n mixins: createMixins(systemTheme.breakpoints, mixinsInput),\n palette,\n // Don't use [...shadows] until you've verified its transpiled code is not invoking the iterator protocol.\n shadows: shadows.slice(),\n typography: createTypography(palette, typographyInput),\n transitions: createTransitions(transitionsInput),\n zIndex: _extends({}, zIndex)\n });\n muiTheme = deepmerge(muiTheme, other);\n muiTheme = args.reduce((acc, argument) => deepmerge(acc, argument), muiTheme);\n if (process.env.NODE_ENV !== 'production') {\n // TODO v6: Refactor to use globalStateClassesMapping from @mui/utils once `readOnly` state class is used in Rating component.\n const stateClasses = ['active', 'checked', 'completed', 'disabled', 'error', 'expanded', 'focused', 'focusVisible', 'required', 'selected'];\n const traverse = (node, component) => {\n let key;\n\n // eslint-disable-next-line guard-for-in, no-restricted-syntax\n for (key in node) {\n const child = node[key];\n if (stateClasses.indexOf(key) !== -1 && Object.keys(child).length > 0) {\n if (process.env.NODE_ENV !== 'production') {\n const stateClass = generateUtilityClass('', key);\n console.error([`MUI: The \\`${component}\\` component increases ` + `the CSS specificity of the \\`${key}\\` internal state.`, 'You can not override it like this: ', JSON.stringify(node, null, 2), '', `Instead, you need to use the '&.${stateClass}' syntax:`, JSON.stringify({\n root: {\n [`&.${stateClass}`]: child\n }\n }, null, 2), '', 'https://mui.com/r/state-classes-guide'].join('\\n'));\n }\n // Remove the style to prevent global conflicts.\n node[key] = {};\n }\n }\n };\n Object.keys(muiTheme.components).forEach(component => {\n const styleOverrides = muiTheme.components[component].styleOverrides;\n if (styleOverrides && component.indexOf('Mui') === 0) {\n traverse(styleOverrides, component);\n }\n });\n }\n muiTheme.unstable_sxConfig = _extends({}, defaultSxConfig, other == null ? void 0 : other.unstable_sxConfig);\n muiTheme.unstable_sx = function sx(props) {\n return styleFunctionSx({\n sx: props,\n theme: this\n });\n };\n return muiTheme;\n}\nlet warnedOnce = false;\nexport function createMuiTheme(...args) {\n if (process.env.NODE_ENV !== 'production') {\n if (!warnedOnce) {\n warnedOnce = true;\n console.error(['MUI: the createMuiTheme function was renamed to createTheme.', '', \"You should use `import { createTheme } from '@mui/material/styles'`\"].join('\\n'));\n }\n }\n return createTheme(...args);\n}\nexport default createTheme;","'use client';\n\nimport createTheme from './createTheme';\nconst defaultTheme = createTheme();\nexport default defaultTheme;","export default '$$material';","'use client';\n\nimport { useThemeProps as systemUseThemeProps } from '@mui/system';\nimport defaultTheme from './defaultTheme';\nimport THEME_ID from './identifier';\nexport default function useThemeProps({\n props,\n name\n}) {\n return systemUseThemeProps({\n props,\n name,\n defaultTheme,\n themeId: THEME_ID\n });\n}","'use client';\n\nimport { createStyled, shouldForwardProp } from '@mui/system';\nimport defaultTheme from './defaultTheme';\nimport THEME_ID from './identifier';\nexport const rootShouldForwardProp = prop => shouldForwardProp(prop) && prop !== 'classes';\nexport const slotShouldForwardProp = shouldForwardProp;\nconst styled = createStyled({\n themeId: THEME_ID,\n defaultTheme,\n rootShouldForwardProp\n});\nexport default styled;","import generateUtilityClasses from '@mui/utils/generateUtilityClasses';\nimport generateUtilityClass from '@mui/utils/generateUtilityClass';\nexport function getSvgIconUtilityClass(slot) {\n return generateUtilityClass('MuiSvgIcon', slot);\n}\nconst svgIconClasses = generateUtilityClasses('MuiSvgIcon', ['root', 'colorPrimary', 'colorSecondary', 'colorAction', 'colorError', 'colorDisabled', 'fontSizeInherit', 'fontSizeSmall', 'fontSizeMedium', 'fontSizeLarge']);\nexport default svgIconClasses;","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"children\", \"className\", \"color\", \"component\", \"fontSize\", \"htmlColor\", \"inheritViewBox\", \"titleAccess\", \"viewBox\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport clsx from 'clsx';\nimport { unstable_composeClasses as composeClasses } from '@mui/base/composeClasses';\nimport capitalize from '../utils/capitalize';\nimport useThemeProps from '../styles/useThemeProps';\nimport styled from '../styles/styled';\nimport { getSvgIconUtilityClass } from './svgIconClasses';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nimport { jsxs as _jsxs } from \"react/jsx-runtime\";\nconst useUtilityClasses = ownerState => {\n const {\n color,\n fontSize,\n classes\n } = ownerState;\n const slots = {\n root: ['root', color !== 'inherit' && `color${capitalize(color)}`, `fontSize${capitalize(fontSize)}`]\n };\n return composeClasses(slots, getSvgIconUtilityClass, classes);\n};\nconst SvgIconRoot = styled('svg', {\n name: 'MuiSvgIcon',\n slot: 'Root',\n overridesResolver: (props, styles) => {\n const {\n ownerState\n } = props;\n return [styles.root, ownerState.color !== 'inherit' && styles[`color${capitalize(ownerState.color)}`], styles[`fontSize${capitalize(ownerState.fontSize)}`]];\n }\n})(({\n theme,\n ownerState\n}) => {\n var _theme$transitions, _theme$transitions$cr, _theme$transitions2, _theme$typography, _theme$typography$pxT, _theme$typography2, _theme$typography2$px, _theme$typography3, _theme$typography3$px, _palette$ownerState$c, _palette, _palette2, _palette3;\n return {\n userSelect: 'none',\n width: '1em',\n height: '1em',\n display: 'inline-block',\n // the will define the property that has `currentColor`\n // e.g. heroicons uses fill=\"none\" and stroke=\"currentColor\"\n fill: ownerState.hasSvgAsChild ? undefined : 'currentColor',\n flexShrink: 0,\n transition: (_theme$transitions = theme.transitions) == null || (_theme$transitions$cr = _theme$transitions.create) == null ? void 0 : _theme$transitions$cr.call(_theme$transitions, 'fill', {\n duration: (_theme$transitions2 = theme.transitions) == null || (_theme$transitions2 = _theme$transitions2.duration) == null ? void 0 : _theme$transitions2.shorter\n }),\n fontSize: {\n inherit: 'inherit',\n small: ((_theme$typography = theme.typography) == null || (_theme$typography$pxT = _theme$typography.pxToRem) == null ? void 0 : _theme$typography$pxT.call(_theme$typography, 20)) || '1.25rem',\n medium: ((_theme$typography2 = theme.typography) == null || (_theme$typography2$px = _theme$typography2.pxToRem) == null ? void 0 : _theme$typography2$px.call(_theme$typography2, 24)) || '1.5rem',\n large: ((_theme$typography3 = theme.typography) == null || (_theme$typography3$px = _theme$typography3.pxToRem) == null ? void 0 : _theme$typography3$px.call(_theme$typography3, 35)) || '2.1875rem'\n }[ownerState.fontSize],\n // TODO v5 deprecate, v6 remove for sx\n color: (_palette$ownerState$c = (_palette = (theme.vars || theme).palette) == null || (_palette = _palette[ownerState.color]) == null ? void 0 : _palette.main) != null ? _palette$ownerState$c : {\n action: (_palette2 = (theme.vars || theme).palette) == null || (_palette2 = _palette2.action) == null ? void 0 : _palette2.active,\n disabled: (_palette3 = (theme.vars || theme).palette) == null || (_palette3 = _palette3.action) == null ? void 0 : _palette3.disabled,\n inherit: undefined\n }[ownerState.color]\n };\n});\nconst SvgIcon = /*#__PURE__*/React.forwardRef(function SvgIcon(inProps, ref) {\n const props = useThemeProps({\n props: inProps,\n name: 'MuiSvgIcon'\n });\n const {\n children,\n className,\n color = 'inherit',\n component = 'svg',\n fontSize = 'medium',\n htmlColor,\n inheritViewBox = false,\n titleAccess,\n viewBox = '0 0 24 24'\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const hasSvgAsChild = /*#__PURE__*/React.isValidElement(children) && children.type === 'svg';\n const ownerState = _extends({}, props, {\n color,\n component,\n fontSize,\n instanceFontSize: inProps.fontSize,\n inheritViewBox,\n viewBox,\n hasSvgAsChild\n });\n const more = {};\n if (!inheritViewBox) {\n more.viewBox = viewBox;\n }\n const classes = useUtilityClasses(ownerState);\n return /*#__PURE__*/_jsxs(SvgIconRoot, _extends({\n as: component,\n className: clsx(classes.root, className),\n focusable: \"false\",\n color: htmlColor,\n \"aria-hidden\": titleAccess ? undefined : true,\n role: titleAccess ? 'img' : undefined,\n ref: ref\n }, more, other, hasSvgAsChild && children.props, {\n ownerState: ownerState,\n children: [hasSvgAsChild ? children.props.children : children, titleAccess ? /*#__PURE__*/_jsx(\"title\", {\n children: titleAccess\n }) : null]\n }));\n});\nprocess.env.NODE_ENV !== \"production\" ? SvgIcon.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the d.ts file and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * Node passed into the SVG element.\n */\n children: PropTypes.node,\n /**\n * Override or extend the styles applied to the component.\n */\n classes: PropTypes.object,\n /**\n * @ignore\n */\n className: PropTypes.string,\n /**\n * The color of the component.\n * It supports both default and custom theme colors, which can be added as shown in the\n * [palette customization guide](https://mui.com/material-ui/customization/palette/#custom-colors).\n * You can use the `htmlColor` prop to apply a color attribute to the SVG element.\n * @default 'inherit'\n */\n color: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.oneOf(['inherit', 'action', 'disabled', 'primary', 'secondary', 'error', 'info', 'success', 'warning']), PropTypes.string]),\n /**\n * The component used for the root node.\n * Either a string to use a HTML element or a component.\n */\n component: PropTypes.elementType,\n /**\n * The fontSize applied to the icon. Defaults to 24px, but can be configure to inherit font size.\n * @default 'medium'\n */\n fontSize: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.oneOf(['inherit', 'large', 'medium', 'small']), PropTypes.string]),\n /**\n * Applies a color attribute to the SVG element.\n */\n htmlColor: PropTypes.string,\n /**\n * If `true`, the root node will inherit the custom `component`'s viewBox and the `viewBox`\n * prop will be ignored.\n * Useful when you want to reference a custom `component` and have `SvgIcon` pass that\n * `component`'s viewBox to the root node.\n * @default false\n */\n inheritViewBox: PropTypes.bool,\n /**\n * The shape-rendering attribute. The behavior of the different options is described on the\n * [MDN Web Docs](https://developer.mozilla.org/en-US/docs/Web/SVG/Attribute/shape-rendering).\n * If you are having issues with blurry icons you should investigate this prop.\n */\n shapeRendering: PropTypes.string,\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Provides a human-readable title for the element that contains it.\n * https://www.w3.org/TR/SVG-access/#Equivalent\n */\n titleAccess: PropTypes.string,\n /**\n * Allows you to redefine what the coordinates without units mean inside an SVG element.\n * For example, if the SVG element is 500 (width) by 200 (height),\n * and you pass viewBox=\"0 0 50 20\",\n * this means that the coordinates inside the SVG will go from the top left corner (0,0)\n * to bottom right (50,20) and each unit will be worth 10px.\n * @default '0 0 24 24'\n */\n viewBox: PropTypes.string\n} : void 0;\nSvgIcon.muiName = 'SvgIcon';\nexport default SvgIcon;","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport * as React from 'react';\nimport SvgIcon from '../SvgIcon';\n\n/**\n * Private module reserved for @mui packages.\n */\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nexport default function createSvgIcon(path, displayName) {\n function Component(props, ref) {\n return /*#__PURE__*/_jsx(SvgIcon, _extends({\n \"data-testid\": `${displayName}Icon`,\n ref: ref\n }, props, {\n children: path\n }));\n }\n if (process.env.NODE_ENV !== 'production') {\n // Need to set `displayName` on the inner component for React.memo.\n // React prior to 16.14 ignores `displayName` on the wrapper.\n Component.displayName = `${displayName}Icon`;\n }\n Component.muiName = SvgIcon.muiName;\n return /*#__PURE__*/React.memo( /*#__PURE__*/React.forwardRef(Component));\n}","'use client';\n\nimport { unstable_ClassNameGenerator as ClassNameGenerator } from '@mui/base/ClassNameGenerator';\nexport { default as capitalize } from './capitalize';\nexport { default as createChainedFunction } from './createChainedFunction';\nexport { default as createSvgIcon } from './createSvgIcon';\nexport { default as debounce } from './debounce';\nexport { default as deprecatedPropType } from './deprecatedPropType';\nexport { default as isMuiElement } from './isMuiElement';\nexport { default as ownerDocument } from './ownerDocument';\nexport { default as ownerWindow } from './ownerWindow';\nexport { default as requirePropFactory } from './requirePropFactory';\nexport { default as setRef } from './setRef';\nexport { default as unstable_useEnhancedEffect } from './useEnhancedEffect';\nexport { default as unstable_useId } from './useId';\nexport { default as unsupportedProp } from './unsupportedProp';\nexport { default as useControlled } from './useControlled';\nexport { default as useEventCallback } from './useEventCallback';\nexport { default as useForkRef } from './useForkRef';\nexport { default as useIsFocusVisible } from './useIsFocusVisible';\n// TODO: remove this export once ClassNameGenerator is stable\n// eslint-disable-next-line @typescript-eslint/naming-convention\nexport const unstable_ClassNameGenerator = {\n configure: generator => {\n if (process.env.NODE_ENV !== 'production') {\n console.warn(['MUI: `ClassNameGenerator` import from `@mui/material/utils` is outdated and might cause unexpected issues.', '', \"You should use `import { unstable_ClassNameGenerator } from '@mui/material/className'` instead\", '', 'The detail of the issue: https://github.com/mui/material-ui/issues/30011#issuecomment-1024993401', '', 'The updated documentation: https://mui.com/guides/classname-generator/'].join('\\n'));\n }\n ClassNameGenerator.configure(generator);\n }\n};","\"use strict\";\n'use client';\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nObject.defineProperty(exports, \"default\", {\n enumerable: true,\n get: function () {\n return _utils.createSvgIcon;\n }\n});\nvar _utils = require(\"@mui/material/utils\");","\"use strict\";\n\"use client\";\n\nvar _interopRequireDefault = require(\"@babel/runtime/helpers/interopRequireDefault\");\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = void 0;\nvar _createSvgIcon = _interopRequireDefault(require(\"./utils/createSvgIcon\"));\nvar _jsxRuntime = require(\"react/jsx-runtime\");\nvar _default = exports.default = (0, _createSvgIcon.default)( /*#__PURE__*/(0, _jsxRuntime.jsx)(\"path\", {\n d: \"m10 17 5-5-5-5z\"\n}), 'ArrowRight');","/**\n * Determines if a given element is a DOM element name (i.e. not a React component).\n */\nexport function isHostComponent(element) {\n return typeof element === 'string';\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport { isHostComponent } from './isHostComponent';\n\n/**\n * Type of the ownerState based on the type of an element it applies to.\n * This resolves to the provided OwnerState for React components and `undefined` for host components.\n * Falls back to `OwnerState | undefined` when the exact type can't be determined in development time.\n */\n\n/**\n * Appends the ownerState object to the props, merging with the existing one if necessary.\n *\n * @param elementType Type of the element that owns the `existingProps`. If the element is a DOM node or undefined, `ownerState` is not applied.\n * @param otherProps Props of the element.\n * @param ownerState\n */\nexport function appendOwnerState(elementType, otherProps, ownerState) {\n if (elementType === undefined || isHostComponent(elementType)) {\n return otherProps;\n }\n return _extends({}, otherProps, {\n ownerState: _extends({}, otherProps.ownerState, ownerState)\n });\n}","'use client';\n\nimport * as React from 'react';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nconst defaultContextValue = {\n disableDefaultClasses: false\n};\nconst ClassNameConfiguratorContext = /*#__PURE__*/React.createContext(defaultContextValue);\n/**\n * @ignore - internal hook.\n *\n * Wraps the `generateUtilityClass` function and controls how the classes are generated.\n * Currently it only affects whether the classes are applied or not.\n *\n * @returns Function to be called with the `generateUtilityClass` function specific to a component to generate the classes.\n */\nexport function useClassNamesOverride(generateUtilityClass) {\n const {\n disableDefaultClasses\n } = React.useContext(ClassNameConfiguratorContext);\n return slot => {\n if (disableDefaultClasses) {\n return '';\n }\n return generateUtilityClass(slot);\n };\n}\n\n/**\n * Allows to configure the components within to not apply any built-in classes.\n */\nexport function ClassNameConfigurator(props) {\n const {\n disableDefaultClasses,\n children\n } = props;\n const contextValue = React.useMemo(() => ({\n disableDefaultClasses: disableDefaultClasses != null ? disableDefaultClasses : false\n }), [disableDefaultClasses]);\n return /*#__PURE__*/_jsx(ClassNameConfiguratorContext.Provider, {\n value: contextValue,\n children: children\n });\n}","/**\n * Extracts event handlers from a given object.\n * A prop is considered an event handler if it is a function and its name starts with `on`.\n *\n * @param object An object to extract event handlers from.\n * @param excludeKeys An array of keys to exclude from the returned object.\n */\nexport function extractEventHandlers(object, excludeKeys = []) {\n if (object === undefined) {\n return {};\n }\n const result = {};\n Object.keys(object).filter(prop => prop.match(/^on[A-Z]/) && typeof object[prop] === 'function' && !excludeKeys.includes(prop)).forEach(prop => {\n result[prop] = object[prop];\n });\n return result;\n}","/**\n * If `componentProps` is a function, calls it with the provided `ownerState`.\n * Otherwise, just returns `componentProps`.\n */\nexport function resolveComponentProps(componentProps, ownerState, slotState) {\n if (typeof componentProps === 'function') {\n return componentProps(ownerState, slotState);\n }\n return componentProps;\n}","/**\n * Removes event handlers from the given object.\n * A field is considered an event handler if it is a function with a name beginning with `on`.\n *\n * @param object Object to remove event handlers from.\n * @returns Object with event handlers removed.\n */\nexport function omitEventHandlers(object) {\n if (object === undefined) {\n return {};\n }\n const result = {};\n Object.keys(object).filter(prop => !(prop.match(/^on[A-Z]/) && typeof object[prop] === 'function')).forEach(prop => {\n result[prop] = object[prop];\n });\n return result;\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport clsx from 'clsx';\nimport { extractEventHandlers } from './extractEventHandlers';\nimport { omitEventHandlers } from './omitEventHandlers';\n/**\n * Merges the slot component internal props (usually coming from a hook)\n * with the externally provided ones.\n *\n * The merge order is (the latter overrides the former):\n * 1. The internal props (specified as a getter function to work with get*Props hook result)\n * 2. Additional props (specified internally on a Base UI component)\n * 3. External props specified on the owner component. These should only be used on a root slot.\n * 4. External props specified in the `slotProps.*` prop.\n * 5. The `className` prop - combined from all the above.\n * @param parameters\n * @returns\n */\nexport function mergeSlotProps(parameters) {\n const {\n getSlotProps,\n additionalProps,\n externalSlotProps,\n externalForwardedProps,\n className\n } = parameters;\n if (!getSlotProps) {\n // The simpler case - getSlotProps is not defined, so no internal event handlers are defined,\n // so we can simply merge all the props without having to worry about extracting event handlers.\n const joinedClasses = clsx(additionalProps == null ? void 0 : additionalProps.className, className, externalForwardedProps == null ? void 0 : externalForwardedProps.className, externalSlotProps == null ? void 0 : externalSlotProps.className);\n const mergedStyle = _extends({}, additionalProps == null ? void 0 : additionalProps.style, externalForwardedProps == null ? void 0 : externalForwardedProps.style, externalSlotProps == null ? void 0 : externalSlotProps.style);\n const props = _extends({}, additionalProps, externalForwardedProps, externalSlotProps);\n if (joinedClasses.length > 0) {\n props.className = joinedClasses;\n }\n if (Object.keys(mergedStyle).length > 0) {\n props.style = mergedStyle;\n }\n return {\n props,\n internalRef: undefined\n };\n }\n\n // In this case, getSlotProps is responsible for calling the external event handlers.\n // We don't need to include them in the merged props because of this.\n\n const eventHandlers = extractEventHandlers(_extends({}, externalForwardedProps, externalSlotProps));\n const componentsPropsWithoutEventHandlers = omitEventHandlers(externalSlotProps);\n const otherPropsWithoutEventHandlers = omitEventHandlers(externalForwardedProps);\n const internalSlotProps = getSlotProps(eventHandlers);\n\n // The order of classes is important here.\n // Emotion (that we use in libraries consuming Base UI) depends on this order\n // to properly override style. It requires the most important classes to be last\n // (see https://github.com/mui/material-ui/pull/33205) for the related discussion.\n const joinedClasses = clsx(internalSlotProps == null ? void 0 : internalSlotProps.className, additionalProps == null ? void 0 : additionalProps.className, className, externalForwardedProps == null ? void 0 : externalForwardedProps.className, externalSlotProps == null ? void 0 : externalSlotProps.className);\n const mergedStyle = _extends({}, internalSlotProps == null ? void 0 : internalSlotProps.style, additionalProps == null ? void 0 : additionalProps.style, externalForwardedProps == null ? void 0 : externalForwardedProps.style, externalSlotProps == null ? void 0 : externalSlotProps.style);\n const props = _extends({}, internalSlotProps, additionalProps, otherPropsWithoutEventHandlers, componentsPropsWithoutEventHandlers);\n if (joinedClasses.length > 0) {\n props.className = joinedClasses;\n }\n if (Object.keys(mergedStyle).length > 0) {\n props.style = mergedStyle;\n }\n return {\n props,\n internalRef: internalSlotProps.ref\n };\n}","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"elementType\", \"externalSlotProps\", \"ownerState\", \"skipResolvingSlotProps\"];\nimport { unstable_useForkRef as useForkRef } from '@mui/utils';\nimport { appendOwnerState } from './appendOwnerState';\nimport { mergeSlotProps } from './mergeSlotProps';\nimport { resolveComponentProps } from './resolveComponentProps';\n/**\n * @ignore - do not document.\n * Builds the props to be passed into the slot of an unstyled component.\n * It merges the internal props of the component with the ones supplied by the user, allowing to customize the behavior.\n * If the slot component is not a host component, it also merges in the `ownerState`.\n *\n * @param parameters.getSlotProps - A function that returns the props to be passed to the slot component.\n */\nexport function useSlotProps(parameters) {\n var _parameters$additiona;\n const {\n elementType,\n externalSlotProps,\n ownerState,\n skipResolvingSlotProps = false\n } = parameters,\n rest = _objectWithoutPropertiesLoose(parameters, _excluded);\n const resolvedComponentsProps = skipResolvingSlotProps ? {} : resolveComponentProps(externalSlotProps, ownerState);\n const {\n props: mergedProps,\n internalRef\n } = mergeSlotProps(_extends({}, rest, {\n externalSlotProps: resolvedComponentsProps\n }));\n const ref = useForkRef(internalRef, resolvedComponentsProps == null ? void 0 : resolvedComponentsProps.ref, (_parameters$additiona = parameters.additionalProps) == null ? void 0 : _parameters$additiona.ref);\n const props = appendOwnerState(elementType, _extends({}, mergedProps, {\n ref\n }), ownerState);\n return props;\n}","import { globalStateClasses } from '@mui/utils/generateUtilityClass';\nconst GLOBAL_CLASS_PREFIX = 'base';\nfunction buildStateClass(state) {\n return `${GLOBAL_CLASS_PREFIX}--${state}`;\n}\nfunction buildSlotClass(componentName, slot) {\n return `${GLOBAL_CLASS_PREFIX}-${componentName}-${slot}`;\n}\nexport function generateUtilityClass(componentName, slot) {\n const globalStateClass = globalStateClasses[slot];\n return globalStateClass ? buildStateClass(globalStateClass) : buildSlotClass(componentName, slot);\n}\nexport function isGlobalState(slot) {\n return globalStateClasses[slot] !== undefined;\n}","import { generateUtilityClass } from '../generateUtilityClass';\nexport function generateUtilityClasses(componentName, slots) {\n const result = {};\n slots.forEach(slot => {\n result[slot] = generateUtilityClass(componentName, slot);\n });\n return result;\n}","'use client';\n\nimport * as React from 'react';\nimport * as ReactDOM from 'react-dom';\nimport PropTypes from 'prop-types';\nimport { exactProp, HTMLElementType, unstable_useEnhancedEffect as useEnhancedEffect, unstable_useForkRef as useForkRef, unstable_setRef as setRef } from '@mui/utils';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nfunction getContainer(container) {\n return typeof container === 'function' ? container() : container;\n}\n\n/**\n * Portals provide a first-class way to render children into a DOM node\n * that exists outside the DOM hierarchy of the parent component.\n *\n * Demos:\n *\n * - [Portal](https://mui.com/base-ui/react-portal/)\n *\n * API:\n *\n * - [Portal API](https://mui.com/base-ui/react-portal/components-api/#portal)\n */\nconst Portal = /*#__PURE__*/React.forwardRef(function Portal(props, forwardedRef) {\n const {\n children,\n container,\n disablePortal = false\n } = props;\n const [mountNode, setMountNode] = React.useState(null);\n // @ts-expect-error TODO upstream fix\n const handleRef = useForkRef( /*#__PURE__*/React.isValidElement(children) ? children.ref : null, forwardedRef);\n useEnhancedEffect(() => {\n if (!disablePortal) {\n setMountNode(getContainer(container) || document.body);\n }\n }, [container, disablePortal]);\n useEnhancedEffect(() => {\n if (mountNode && !disablePortal) {\n setRef(forwardedRef, mountNode);\n return () => {\n setRef(forwardedRef, null);\n };\n }\n return undefined;\n }, [forwardedRef, mountNode, disablePortal]);\n if (disablePortal) {\n if ( /*#__PURE__*/React.isValidElement(children)) {\n const newProps = {\n ref: handleRef\n };\n return /*#__PURE__*/React.cloneElement(children, newProps);\n }\n return /*#__PURE__*/_jsx(React.Fragment, {\n children: children\n });\n }\n return /*#__PURE__*/_jsx(React.Fragment, {\n children: mountNode ? /*#__PURE__*/ReactDOM.createPortal(children, mountNode) : mountNode\n });\n});\nprocess.env.NODE_ENV !== \"production\" ? Portal.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * The children to render into the `container`.\n */\n children: PropTypes.node,\n /**\n * An HTML element or function that returns one.\n * The `container` will have the portal children appended to it.\n *\n * You can also provide a callback, which is called in a React layout effect.\n * This lets you set the container from a ref, and also makes server-side rendering possible.\n *\n * By default, it uses the body of the top-level document object,\n * so it's simply `document.body` most of the time.\n */\n container: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.func]),\n /**\n * The `children` will be under the DOM hierarchy of the parent component.\n * @default false\n */\n disablePortal: PropTypes.bool\n} : void 0;\nif (process.env.NODE_ENV !== 'production') {\n // eslint-disable-next-line\n Portal['propTypes' + ''] = exactProp(Portal.propTypes);\n}\nexport { Portal };","export var top = 'top';\nexport var bottom = 'bottom';\nexport var right = 'right';\nexport var left = 'left';\nexport var auto = 'auto';\nexport var basePlacements = [top, bottom, right, left];\nexport var start = 'start';\nexport var end = 'end';\nexport var clippingParents = 'clippingParents';\nexport var viewport = 'viewport';\nexport var popper = 'popper';\nexport var reference = 'reference';\nexport var variationPlacements = /*#__PURE__*/basePlacements.reduce(function (acc, placement) {\n return acc.concat([placement + \"-\" + start, placement + \"-\" + end]);\n}, []);\nexport var placements = /*#__PURE__*/[].concat(basePlacements, [auto]).reduce(function (acc, placement) {\n return acc.concat([placement, placement + \"-\" + start, placement + \"-\" + end]);\n}, []); // modifiers that need to read the DOM\n\nexport var beforeRead = 'beforeRead';\nexport var read = 'read';\nexport var afterRead = 'afterRead'; // pure-logic modifiers\n\nexport var beforeMain = 'beforeMain';\nexport var main = 'main';\nexport var afterMain = 'afterMain'; // modifier with the purpose to write to the DOM (or write into a framework state)\n\nexport var beforeWrite = 'beforeWrite';\nexport var write = 'write';\nexport var afterWrite = 'afterWrite';\nexport var modifierPhases = [beforeRead, read, afterRead, beforeMain, main, afterMain, beforeWrite, write, afterWrite];","export default function getNodeName(element) {\n return element ? (element.nodeName || '').toLowerCase() : null;\n}","export default function getWindow(node) {\n if (node == null) {\n return window;\n }\n\n if (node.toString() !== '[object Window]') {\n var ownerDocument = node.ownerDocument;\n return ownerDocument ? ownerDocument.defaultView || window : window;\n }\n\n return node;\n}","import getWindow from \"./getWindow.js\";\n\nfunction isElement(node) {\n var OwnElement = getWindow(node).Element;\n return node instanceof OwnElement || node instanceof Element;\n}\n\nfunction isHTMLElement(node) {\n var OwnElement = getWindow(node).HTMLElement;\n return node instanceof OwnElement || node instanceof HTMLElement;\n}\n\nfunction isShadowRoot(node) {\n // IE 11 has no ShadowRoot\n if (typeof ShadowRoot === 'undefined') {\n return false;\n }\n\n var OwnElement = getWindow(node).ShadowRoot;\n return node instanceof OwnElement || node instanceof ShadowRoot;\n}\n\nexport { isElement, isHTMLElement, isShadowRoot };","import getNodeName from \"../dom-utils/getNodeName.js\";\nimport { isHTMLElement } from \"../dom-utils/instanceOf.js\"; // This modifier takes the styles prepared by the `computeStyles` modifier\n// and applies them to the HTMLElements such as popper and arrow\n\nfunction applyStyles(_ref) {\n var state = _ref.state;\n Object.keys(state.elements).forEach(function (name) {\n var style = state.styles[name] || {};\n var attributes = state.attributes[name] || {};\n var element = state.elements[name]; // arrow is optional + virtual elements\n\n if (!isHTMLElement(element) || !getNodeName(element)) {\n return;\n } // Flow doesn't support to extend this property, but it's the most\n // effective way to apply styles to an HTMLElement\n // $FlowFixMe[cannot-write]\n\n\n Object.assign(element.style, style);\n Object.keys(attributes).forEach(function (name) {\n var value = attributes[name];\n\n if (value === false) {\n element.removeAttribute(name);\n } else {\n element.setAttribute(name, value === true ? '' : value);\n }\n });\n });\n}\n\nfunction effect(_ref2) {\n var state = _ref2.state;\n var initialStyles = {\n popper: {\n position: state.options.strategy,\n left: '0',\n top: '0',\n margin: '0'\n },\n arrow: {\n position: 'absolute'\n },\n reference: {}\n };\n Object.assign(state.elements.popper.style, initialStyles.popper);\n state.styles = initialStyles;\n\n if (state.elements.arrow) {\n Object.assign(state.elements.arrow.style, initialStyles.arrow);\n }\n\n return function () {\n Object.keys(state.elements).forEach(function (name) {\n var element = state.elements[name];\n var attributes = state.attributes[name] || {};\n var styleProperties = Object.keys(state.styles.hasOwnProperty(name) ? state.styles[name] : initialStyles[name]); // Set all values to an empty string to unset them\n\n var style = styleProperties.reduce(function (style, property) {\n style[property] = '';\n return style;\n }, {}); // arrow is optional + virtual elements\n\n if (!isHTMLElement(element) || !getNodeName(element)) {\n return;\n }\n\n Object.assign(element.style, style);\n Object.keys(attributes).forEach(function (attribute) {\n element.removeAttribute(attribute);\n });\n });\n };\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'applyStyles',\n enabled: true,\n phase: 'write',\n fn: applyStyles,\n effect: effect,\n requires: ['computeStyles']\n};","import { auto } from \"../enums.js\";\nexport default function getBasePlacement(placement) {\n return placement.split('-')[0];\n}","export var max = Math.max;\nexport var min = Math.min;\nexport var round = Math.round;","export default function getUAString() {\n var uaData = navigator.userAgentData;\n\n if (uaData != null && uaData.brands && Array.isArray(uaData.brands)) {\n return uaData.brands.map(function (item) {\n return item.brand + \"/\" + item.version;\n }).join(' ');\n }\n\n return navigator.userAgent;\n}","import getUAString from \"../utils/userAgent.js\";\nexport default function isLayoutViewport() {\n return !/^((?!chrome|android).)*safari/i.test(getUAString());\n}","import { isElement, isHTMLElement } from \"./instanceOf.js\";\nimport { round } from \"../utils/math.js\";\nimport getWindow from \"./getWindow.js\";\nimport isLayoutViewport from \"./isLayoutViewport.js\";\nexport default function getBoundingClientRect(element, includeScale, isFixedStrategy) {\n if (includeScale === void 0) {\n includeScale = false;\n }\n\n if (isFixedStrategy === void 0) {\n isFixedStrategy = false;\n }\n\n var clientRect = element.getBoundingClientRect();\n var scaleX = 1;\n var scaleY = 1;\n\n if (includeScale && isHTMLElement(element)) {\n scaleX = element.offsetWidth > 0 ? round(clientRect.width) / element.offsetWidth || 1 : 1;\n scaleY = element.offsetHeight > 0 ? round(clientRect.height) / element.offsetHeight || 1 : 1;\n }\n\n var _ref = isElement(element) ? getWindow(element) : window,\n visualViewport = _ref.visualViewport;\n\n var addVisualOffsets = !isLayoutViewport() && isFixedStrategy;\n var x = (clientRect.left + (addVisualOffsets && visualViewport ? visualViewport.offsetLeft : 0)) / scaleX;\n var y = (clientRect.top + (addVisualOffsets && visualViewport ? visualViewport.offsetTop : 0)) / scaleY;\n var width = clientRect.width / scaleX;\n var height = clientRect.height / scaleY;\n return {\n width: width,\n height: height,\n top: y,\n right: x + width,\n bottom: y + height,\n left: x,\n x: x,\n y: y\n };\n}","import getBoundingClientRect from \"./getBoundingClientRect.js\"; // Returns the layout rect of an element relative to its offsetParent. Layout\n// means it doesn't take into account transforms.\n\nexport default function getLayoutRect(element) {\n var clientRect = getBoundingClientRect(element); // Use the clientRect sizes if it's not been transformed.\n // Fixes https://github.com/popperjs/popper-core/issues/1223\n\n var width = element.offsetWidth;\n var height = element.offsetHeight;\n\n if (Math.abs(clientRect.width - width) <= 1) {\n width = clientRect.width;\n }\n\n if (Math.abs(clientRect.height - height) <= 1) {\n height = clientRect.height;\n }\n\n return {\n x: element.offsetLeft,\n y: element.offsetTop,\n width: width,\n height: height\n };\n}","import { isShadowRoot } from \"./instanceOf.js\";\nexport default function contains(parent, child) {\n var rootNode = child.getRootNode && child.getRootNode(); // First, attempt with faster native method\n\n if (parent.contains(child)) {\n return true;\n } // then fallback to custom implementation with Shadow DOM support\n else if (rootNode && isShadowRoot(rootNode)) {\n var next = child;\n\n do {\n if (next && parent.isSameNode(next)) {\n return true;\n } // $FlowFixMe[prop-missing]: need a better way to handle this...\n\n\n next = next.parentNode || next.host;\n } while (next);\n } // Give up, the result is false\n\n\n return false;\n}","import getWindow from \"./getWindow.js\";\nexport default function getComputedStyle(element) {\n return getWindow(element).getComputedStyle(element);\n}","import getNodeName from \"./getNodeName.js\";\nexport default function isTableElement(element) {\n return ['table', 'td', 'th'].indexOf(getNodeName(element)) >= 0;\n}","import { isElement } from \"./instanceOf.js\";\nexport default function getDocumentElement(element) {\n // $FlowFixMe[incompatible-return]: assume body is always available\n return ((isElement(element) ? element.ownerDocument : // $FlowFixMe[prop-missing]\n element.document) || window.document).documentElement;\n}","import getNodeName from \"./getNodeName.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport { isShadowRoot } from \"./instanceOf.js\";\nexport default function getParentNode(element) {\n if (getNodeName(element) === 'html') {\n return element;\n }\n\n return (// this is a quicker (but less type safe) way to save quite some bytes from the bundle\n // $FlowFixMe[incompatible-return]\n // $FlowFixMe[prop-missing]\n element.assignedSlot || // step into the shadow DOM of the parent of a slotted node\n element.parentNode || ( // DOM Element detected\n isShadowRoot(element) ? element.host : null) || // ShadowRoot detected\n // $FlowFixMe[incompatible-call]: HTMLElement is a Node\n getDocumentElement(element) // fallback\n\n );\n}","import getWindow from \"./getWindow.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport getComputedStyle from \"./getComputedStyle.js\";\nimport { isHTMLElement, isShadowRoot } from \"./instanceOf.js\";\nimport isTableElement from \"./isTableElement.js\";\nimport getParentNode from \"./getParentNode.js\";\nimport getUAString from \"../utils/userAgent.js\";\n\nfunction getTrueOffsetParent(element) {\n if (!isHTMLElement(element) || // https://github.com/popperjs/popper-core/issues/837\n getComputedStyle(element).position === 'fixed') {\n return null;\n }\n\n return element.offsetParent;\n} // `.offsetParent` reports `null` for fixed elements, while absolute elements\n// return the containing block\n\n\nfunction getContainingBlock(element) {\n var isFirefox = /firefox/i.test(getUAString());\n var isIE = /Trident/i.test(getUAString());\n\n if (isIE && isHTMLElement(element)) {\n // In IE 9, 10 and 11 fixed elements containing block is always established by the viewport\n var elementCss = getComputedStyle(element);\n\n if (elementCss.position === 'fixed') {\n return null;\n }\n }\n\n var currentNode = getParentNode(element);\n\n if (isShadowRoot(currentNode)) {\n currentNode = currentNode.host;\n }\n\n while (isHTMLElement(currentNode) && ['html', 'body'].indexOf(getNodeName(currentNode)) < 0) {\n var css = getComputedStyle(currentNode); // This is non-exhaustive but covers the most common CSS properties that\n // create a containing block.\n // https://developer.mozilla.org/en-US/docs/Web/CSS/Containing_block#identifying_the_containing_block\n\n if (css.transform !== 'none' || css.perspective !== 'none' || css.contain === 'paint' || ['transform', 'perspective'].indexOf(css.willChange) !== -1 || isFirefox && css.willChange === 'filter' || isFirefox && css.filter && css.filter !== 'none') {\n return currentNode;\n } else {\n currentNode = currentNode.parentNode;\n }\n }\n\n return null;\n} // Gets the closest ancestor positioned element. Handles some edge cases,\n// such as table ancestors and cross browser bugs.\n\n\nexport default function getOffsetParent(element) {\n var window = getWindow(element);\n var offsetParent = getTrueOffsetParent(element);\n\n while (offsetParent && isTableElement(offsetParent) && getComputedStyle(offsetParent).position === 'static') {\n offsetParent = getTrueOffsetParent(offsetParent);\n }\n\n if (offsetParent && (getNodeName(offsetParent) === 'html' || getNodeName(offsetParent) === 'body' && getComputedStyle(offsetParent).position === 'static')) {\n return window;\n }\n\n return offsetParent || getContainingBlock(element) || window;\n}","export default function getMainAxisFromPlacement(placement) {\n return ['top', 'bottom'].indexOf(placement) >= 0 ? 'x' : 'y';\n}","import { max as mathMax, min as mathMin } from \"./math.js\";\nexport function within(min, value, max) {\n return mathMax(min, mathMin(value, max));\n}\nexport function withinMaxClamp(min, value, max) {\n var v = within(min, value, max);\n return v > max ? max : v;\n}","export default function getFreshSideObject() {\n return {\n top: 0,\n right: 0,\n bottom: 0,\n left: 0\n };\n}","import getFreshSideObject from \"./getFreshSideObject.js\";\nexport default function mergePaddingObject(paddingObject) {\n return Object.assign({}, getFreshSideObject(), paddingObject);\n}","export default function expandToHashMap(value, keys) {\n return keys.reduce(function (hashMap, key) {\n hashMap[key] = value;\n return hashMap;\n }, {});\n}","import getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getLayoutRect from \"../dom-utils/getLayoutRect.js\";\nimport contains from \"../dom-utils/contains.js\";\nimport getOffsetParent from \"../dom-utils/getOffsetParent.js\";\nimport getMainAxisFromPlacement from \"../utils/getMainAxisFromPlacement.js\";\nimport { within } from \"../utils/within.js\";\nimport mergePaddingObject from \"../utils/mergePaddingObject.js\";\nimport expandToHashMap from \"../utils/expandToHashMap.js\";\nimport { left, right, basePlacements, top, bottom } from \"../enums.js\"; // eslint-disable-next-line import/no-unused-modules\n\nvar toPaddingObject = function toPaddingObject(padding, state) {\n padding = typeof padding === 'function' ? padding(Object.assign({}, state.rects, {\n placement: state.placement\n })) : padding;\n return mergePaddingObject(typeof padding !== 'number' ? padding : expandToHashMap(padding, basePlacements));\n};\n\nfunction arrow(_ref) {\n var _state$modifiersData$;\n\n var state = _ref.state,\n name = _ref.name,\n options = _ref.options;\n var arrowElement = state.elements.arrow;\n var popperOffsets = state.modifiersData.popperOffsets;\n var basePlacement = getBasePlacement(state.placement);\n var axis = getMainAxisFromPlacement(basePlacement);\n var isVertical = [left, right].indexOf(basePlacement) >= 0;\n var len = isVertical ? 'height' : 'width';\n\n if (!arrowElement || !popperOffsets) {\n return;\n }\n\n var paddingObject = toPaddingObject(options.padding, state);\n var arrowRect = getLayoutRect(arrowElement);\n var minProp = axis === 'y' ? top : left;\n var maxProp = axis === 'y' ? bottom : right;\n var endDiff = state.rects.reference[len] + state.rects.reference[axis] - popperOffsets[axis] - state.rects.popper[len];\n var startDiff = popperOffsets[axis] - state.rects.reference[axis];\n var arrowOffsetParent = getOffsetParent(arrowElement);\n var clientSize = arrowOffsetParent ? axis === 'y' ? arrowOffsetParent.clientHeight || 0 : arrowOffsetParent.clientWidth || 0 : 0;\n var centerToReference = endDiff / 2 - startDiff / 2; // Make sure the arrow doesn't overflow the popper if the center point is\n // outside of the popper bounds\n\n var min = paddingObject[minProp];\n var max = clientSize - arrowRect[len] - paddingObject[maxProp];\n var center = clientSize / 2 - arrowRect[len] / 2 + centerToReference;\n var offset = within(min, center, max); // Prevents breaking syntax highlighting...\n\n var axisProp = axis;\n state.modifiersData[name] = (_state$modifiersData$ = {}, _state$modifiersData$[axisProp] = offset, _state$modifiersData$.centerOffset = offset - center, _state$modifiersData$);\n}\n\nfunction effect(_ref2) {\n var state = _ref2.state,\n options = _ref2.options;\n var _options$element = options.element,\n arrowElement = _options$element === void 0 ? '[data-popper-arrow]' : _options$element;\n\n if (arrowElement == null) {\n return;\n } // CSS selector\n\n\n if (typeof arrowElement === 'string') {\n arrowElement = state.elements.popper.querySelector(arrowElement);\n\n if (!arrowElement) {\n return;\n }\n }\n\n if (!contains(state.elements.popper, arrowElement)) {\n return;\n }\n\n state.elements.arrow = arrowElement;\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'arrow',\n enabled: true,\n phase: 'main',\n fn: arrow,\n effect: effect,\n requires: ['popperOffsets'],\n requiresIfExists: ['preventOverflow']\n};","export default function getVariation(placement) {\n return placement.split('-')[1];\n}","import { top, left, right, bottom, end } from \"../enums.js\";\nimport getOffsetParent from \"../dom-utils/getOffsetParent.js\";\nimport getWindow from \"../dom-utils/getWindow.js\";\nimport getDocumentElement from \"../dom-utils/getDocumentElement.js\";\nimport getComputedStyle from \"../dom-utils/getComputedStyle.js\";\nimport getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getVariation from \"../utils/getVariation.js\";\nimport { round } from \"../utils/math.js\"; // eslint-disable-next-line import/no-unused-modules\n\nvar unsetSides = {\n top: 'auto',\n right: 'auto',\n bottom: 'auto',\n left: 'auto'\n}; // Round the offsets to the nearest suitable subpixel based on the DPR.\n// Zooming can change the DPR, but it seems to report a value that will\n// cleanly divide the values into the appropriate subpixels.\n\nfunction roundOffsetsByDPR(_ref, win) {\n var x = _ref.x,\n y = _ref.y;\n var dpr = win.devicePixelRatio || 1;\n return {\n x: round(x * dpr) / dpr || 0,\n y: round(y * dpr) / dpr || 0\n };\n}\n\nexport function mapToStyles(_ref2) {\n var _Object$assign2;\n\n var popper = _ref2.popper,\n popperRect = _ref2.popperRect,\n placement = _ref2.placement,\n variation = _ref2.variation,\n offsets = _ref2.offsets,\n position = _ref2.position,\n gpuAcceleration = _ref2.gpuAcceleration,\n adaptive = _ref2.adaptive,\n roundOffsets = _ref2.roundOffsets,\n isFixed = _ref2.isFixed;\n var _offsets$x = offsets.x,\n x = _offsets$x === void 0 ? 0 : _offsets$x,\n _offsets$y = offsets.y,\n y = _offsets$y === void 0 ? 0 : _offsets$y;\n\n var _ref3 = typeof roundOffsets === 'function' ? roundOffsets({\n x: x,\n y: y\n }) : {\n x: x,\n y: y\n };\n\n x = _ref3.x;\n y = _ref3.y;\n var hasX = offsets.hasOwnProperty('x');\n var hasY = offsets.hasOwnProperty('y');\n var sideX = left;\n var sideY = top;\n var win = window;\n\n if (adaptive) {\n var offsetParent = getOffsetParent(popper);\n var heightProp = 'clientHeight';\n var widthProp = 'clientWidth';\n\n if (offsetParent === getWindow(popper)) {\n offsetParent = getDocumentElement(popper);\n\n if (getComputedStyle(offsetParent).position !== 'static' && position === 'absolute') {\n heightProp = 'scrollHeight';\n widthProp = 'scrollWidth';\n }\n } // $FlowFixMe[incompatible-cast]: force type refinement, we compare offsetParent with window above, but Flow doesn't detect it\n\n\n offsetParent = offsetParent;\n\n if (placement === top || (placement === left || placement === right) && variation === end) {\n sideY = bottom;\n var offsetY = isFixed && offsetParent === win && win.visualViewport ? win.visualViewport.height : // $FlowFixMe[prop-missing]\n offsetParent[heightProp];\n y -= offsetY - popperRect.height;\n y *= gpuAcceleration ? 1 : -1;\n }\n\n if (placement === left || (placement === top || placement === bottom) && variation === end) {\n sideX = right;\n var offsetX = isFixed && offsetParent === win && win.visualViewport ? win.visualViewport.width : // $FlowFixMe[prop-missing]\n offsetParent[widthProp];\n x -= offsetX - popperRect.width;\n x *= gpuAcceleration ? 1 : -1;\n }\n }\n\n var commonStyles = Object.assign({\n position: position\n }, adaptive && unsetSides);\n\n var _ref4 = roundOffsets === true ? roundOffsetsByDPR({\n x: x,\n y: y\n }, getWindow(popper)) : {\n x: x,\n y: y\n };\n\n x = _ref4.x;\n y = _ref4.y;\n\n if (gpuAcceleration) {\n var _Object$assign;\n\n return Object.assign({}, commonStyles, (_Object$assign = {}, _Object$assign[sideY] = hasY ? '0' : '', _Object$assign[sideX] = hasX ? '0' : '', _Object$assign.transform = (win.devicePixelRatio || 1) <= 1 ? \"translate(\" + x + \"px, \" + y + \"px)\" : \"translate3d(\" + x + \"px, \" + y + \"px, 0)\", _Object$assign));\n }\n\n return Object.assign({}, commonStyles, (_Object$assign2 = {}, _Object$assign2[sideY] = hasY ? y + \"px\" : '', _Object$assign2[sideX] = hasX ? x + \"px\" : '', _Object$assign2.transform = '', _Object$assign2));\n}\n\nfunction computeStyles(_ref5) {\n var state = _ref5.state,\n options = _ref5.options;\n var _options$gpuAccelerat = options.gpuAcceleration,\n gpuAcceleration = _options$gpuAccelerat === void 0 ? true : _options$gpuAccelerat,\n _options$adaptive = options.adaptive,\n adaptive = _options$adaptive === void 0 ? true : _options$adaptive,\n _options$roundOffsets = options.roundOffsets,\n roundOffsets = _options$roundOffsets === void 0 ? true : _options$roundOffsets;\n var commonStyles = {\n placement: getBasePlacement(state.placement),\n variation: getVariation(state.placement),\n popper: state.elements.popper,\n popperRect: state.rects.popper,\n gpuAcceleration: gpuAcceleration,\n isFixed: state.options.strategy === 'fixed'\n };\n\n if (state.modifiersData.popperOffsets != null) {\n state.styles.popper = Object.assign({}, state.styles.popper, mapToStyles(Object.assign({}, commonStyles, {\n offsets: state.modifiersData.popperOffsets,\n position: state.options.strategy,\n adaptive: adaptive,\n roundOffsets: roundOffsets\n })));\n }\n\n if (state.modifiersData.arrow != null) {\n state.styles.arrow = Object.assign({}, state.styles.arrow, mapToStyles(Object.assign({}, commonStyles, {\n offsets: state.modifiersData.arrow,\n position: 'absolute',\n adaptive: false,\n roundOffsets: roundOffsets\n })));\n }\n\n state.attributes.popper = Object.assign({}, state.attributes.popper, {\n 'data-popper-placement': state.placement\n });\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'computeStyles',\n enabled: true,\n phase: 'beforeWrite',\n fn: computeStyles,\n data: {}\n};","import getWindow from \"../dom-utils/getWindow.js\"; // eslint-disable-next-line import/no-unused-modules\n\nvar passive = {\n passive: true\n};\n\nfunction effect(_ref) {\n var state = _ref.state,\n instance = _ref.instance,\n options = _ref.options;\n var _options$scroll = options.scroll,\n scroll = _options$scroll === void 0 ? true : _options$scroll,\n _options$resize = options.resize,\n resize = _options$resize === void 0 ? true : _options$resize;\n var window = getWindow(state.elements.popper);\n var scrollParents = [].concat(state.scrollParents.reference, state.scrollParents.popper);\n\n if (scroll) {\n scrollParents.forEach(function (scrollParent) {\n scrollParent.addEventListener('scroll', instance.update, passive);\n });\n }\n\n if (resize) {\n window.addEventListener('resize', instance.update, passive);\n }\n\n return function () {\n if (scroll) {\n scrollParents.forEach(function (scrollParent) {\n scrollParent.removeEventListener('scroll', instance.update, passive);\n });\n }\n\n if (resize) {\n window.removeEventListener('resize', instance.update, passive);\n }\n };\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'eventListeners',\n enabled: true,\n phase: 'write',\n fn: function fn() {},\n effect: effect,\n data: {}\n};","var hash = {\n left: 'right',\n right: 'left',\n bottom: 'top',\n top: 'bottom'\n};\nexport default function getOppositePlacement(placement) {\n return placement.replace(/left|right|bottom|top/g, function (matched) {\n return hash[matched];\n });\n}","var hash = {\n start: 'end',\n end: 'start'\n};\nexport default function getOppositeVariationPlacement(placement) {\n return placement.replace(/start|end/g, function (matched) {\n return hash[matched];\n });\n}","import getWindow from \"./getWindow.js\";\nexport default function getWindowScroll(node) {\n var win = getWindow(node);\n var scrollLeft = win.pageXOffset;\n var scrollTop = win.pageYOffset;\n return {\n scrollLeft: scrollLeft,\n scrollTop: scrollTop\n };\n}","import getBoundingClientRect from \"./getBoundingClientRect.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport getWindowScroll from \"./getWindowScroll.js\";\nexport default function getWindowScrollBarX(element) {\n // If has a CSS width greater than the viewport, then this will be\n // incorrect for RTL.\n // Popper 1 is broken in this case and never had a bug report so let's assume\n // it's not an issue. I don't think anyone ever specifies width on \n // anyway.\n // Browsers where the left scrollbar doesn't cause an issue report `0` for\n // this (e.g. Edge 2019, IE11, Safari)\n return getBoundingClientRect(getDocumentElement(element)).left + getWindowScroll(element).scrollLeft;\n}","import getWindow from \"./getWindow.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport getWindowScrollBarX from \"./getWindowScrollBarX.js\";\nimport isLayoutViewport from \"./isLayoutViewport.js\";\nexport default function getViewportRect(element, strategy) {\n var win = getWindow(element);\n var html = getDocumentElement(element);\n var visualViewport = win.visualViewport;\n var width = html.clientWidth;\n var height = html.clientHeight;\n var x = 0;\n var y = 0;\n\n if (visualViewport) {\n width = visualViewport.width;\n height = visualViewport.height;\n var layoutViewport = isLayoutViewport();\n\n if (layoutViewport || !layoutViewport && strategy === 'fixed') {\n x = visualViewport.offsetLeft;\n y = visualViewport.offsetTop;\n }\n }\n\n return {\n width: width,\n height: height,\n x: x + getWindowScrollBarX(element),\n y: y\n };\n}","import getDocumentElement from \"./getDocumentElement.js\";\nimport getComputedStyle from \"./getComputedStyle.js\";\nimport getWindowScrollBarX from \"./getWindowScrollBarX.js\";\nimport getWindowScroll from \"./getWindowScroll.js\";\nimport { max } from \"../utils/math.js\"; // Gets the entire size of the scrollable document area, even extending outside\n// of the `` and `` rect bounds if horizontally scrollable\n\nexport default function getDocumentRect(element) {\n var _element$ownerDocumen;\n\n var html = getDocumentElement(element);\n var winScroll = getWindowScroll(element);\n var body = (_element$ownerDocumen = element.ownerDocument) == null ? void 0 : _element$ownerDocumen.body;\n var width = max(html.scrollWidth, html.clientWidth, body ? body.scrollWidth : 0, body ? body.clientWidth : 0);\n var height = max(html.scrollHeight, html.clientHeight, body ? body.scrollHeight : 0, body ? body.clientHeight : 0);\n var x = -winScroll.scrollLeft + getWindowScrollBarX(element);\n var y = -winScroll.scrollTop;\n\n if (getComputedStyle(body || html).direction === 'rtl') {\n x += max(html.clientWidth, body ? body.clientWidth : 0) - width;\n }\n\n return {\n width: width,\n height: height,\n x: x,\n y: y\n };\n}","import getComputedStyle from \"./getComputedStyle.js\";\nexport default function isScrollParent(element) {\n // Firefox wants us to check `-x` and `-y` variations as well\n var _getComputedStyle = getComputedStyle(element),\n overflow = _getComputedStyle.overflow,\n overflowX = _getComputedStyle.overflowX,\n overflowY = _getComputedStyle.overflowY;\n\n return /auto|scroll|overlay|hidden/.test(overflow + overflowY + overflowX);\n}","import getParentNode from \"./getParentNode.js\";\nimport isScrollParent from \"./isScrollParent.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport { isHTMLElement } from \"./instanceOf.js\";\nexport default function getScrollParent(node) {\n if (['html', 'body', '#document'].indexOf(getNodeName(node)) >= 0) {\n // $FlowFixMe[incompatible-return]: assume body is always available\n return node.ownerDocument.body;\n }\n\n if (isHTMLElement(node) && isScrollParent(node)) {\n return node;\n }\n\n return getScrollParent(getParentNode(node));\n}","import getScrollParent from \"./getScrollParent.js\";\nimport getParentNode from \"./getParentNode.js\";\nimport getWindow from \"./getWindow.js\";\nimport isScrollParent from \"./isScrollParent.js\";\n/*\ngiven a DOM element, return the list of all scroll parents, up the list of ancesors\nuntil we get to the top window object. This list is what we attach scroll listeners\nto, because if any of these parent elements scroll, we'll need to re-calculate the\nreference element's position.\n*/\n\nexport default function listScrollParents(element, list) {\n var _element$ownerDocumen;\n\n if (list === void 0) {\n list = [];\n }\n\n var scrollParent = getScrollParent(element);\n var isBody = scrollParent === ((_element$ownerDocumen = element.ownerDocument) == null ? void 0 : _element$ownerDocumen.body);\n var win = getWindow(scrollParent);\n var target = isBody ? [win].concat(win.visualViewport || [], isScrollParent(scrollParent) ? scrollParent : []) : scrollParent;\n var updatedList = list.concat(target);\n return isBody ? updatedList : // $FlowFixMe[incompatible-call]: isBody tells us target will be an HTMLElement here\n updatedList.concat(listScrollParents(getParentNode(target)));\n}","export default function rectToClientRect(rect) {\n return Object.assign({}, rect, {\n left: rect.x,\n top: rect.y,\n right: rect.x + rect.width,\n bottom: rect.y + rect.height\n });\n}","import { viewport } from \"../enums.js\";\nimport getViewportRect from \"./getViewportRect.js\";\nimport getDocumentRect from \"./getDocumentRect.js\";\nimport listScrollParents from \"./listScrollParents.js\";\nimport getOffsetParent from \"./getOffsetParent.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport getComputedStyle from \"./getComputedStyle.js\";\nimport { isElement, isHTMLElement } from \"./instanceOf.js\";\nimport getBoundingClientRect from \"./getBoundingClientRect.js\";\nimport getParentNode from \"./getParentNode.js\";\nimport contains from \"./contains.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport rectToClientRect from \"../utils/rectToClientRect.js\";\nimport { max, min } from \"../utils/math.js\";\n\nfunction getInnerBoundingClientRect(element, strategy) {\n var rect = getBoundingClientRect(element, false, strategy === 'fixed');\n rect.top = rect.top + element.clientTop;\n rect.left = rect.left + element.clientLeft;\n rect.bottom = rect.top + element.clientHeight;\n rect.right = rect.left + element.clientWidth;\n rect.width = element.clientWidth;\n rect.height = element.clientHeight;\n rect.x = rect.left;\n rect.y = rect.top;\n return rect;\n}\n\nfunction getClientRectFromMixedType(element, clippingParent, strategy) {\n return clippingParent === viewport ? rectToClientRect(getViewportRect(element, strategy)) : isElement(clippingParent) ? getInnerBoundingClientRect(clippingParent, strategy) : rectToClientRect(getDocumentRect(getDocumentElement(element)));\n} // A \"clipping parent\" is an overflowable container with the characteristic of\n// clipping (or hiding) overflowing elements with a position different from\n// `initial`\n\n\nfunction getClippingParents(element) {\n var clippingParents = listScrollParents(getParentNode(element));\n var canEscapeClipping = ['absolute', 'fixed'].indexOf(getComputedStyle(element).position) >= 0;\n var clipperElement = canEscapeClipping && isHTMLElement(element) ? getOffsetParent(element) : element;\n\n if (!isElement(clipperElement)) {\n return [];\n } // $FlowFixMe[incompatible-return]: https://github.com/facebook/flow/issues/1414\n\n\n return clippingParents.filter(function (clippingParent) {\n return isElement(clippingParent) && contains(clippingParent, clipperElement) && getNodeName(clippingParent) !== 'body';\n });\n} // Gets the maximum area that the element is visible in due to any number of\n// clipping parents\n\n\nexport default function getClippingRect(element, boundary, rootBoundary, strategy) {\n var mainClippingParents = boundary === 'clippingParents' ? getClippingParents(element) : [].concat(boundary);\n var clippingParents = [].concat(mainClippingParents, [rootBoundary]);\n var firstClippingParent = clippingParents[0];\n var clippingRect = clippingParents.reduce(function (accRect, clippingParent) {\n var rect = getClientRectFromMixedType(element, clippingParent, strategy);\n accRect.top = max(rect.top, accRect.top);\n accRect.right = min(rect.right, accRect.right);\n accRect.bottom = min(rect.bottom, accRect.bottom);\n accRect.left = max(rect.left, accRect.left);\n return accRect;\n }, getClientRectFromMixedType(element, firstClippingParent, strategy));\n clippingRect.width = clippingRect.right - clippingRect.left;\n clippingRect.height = clippingRect.bottom - clippingRect.top;\n clippingRect.x = clippingRect.left;\n clippingRect.y = clippingRect.top;\n return clippingRect;\n}","import getBasePlacement from \"./getBasePlacement.js\";\nimport getVariation from \"./getVariation.js\";\nimport getMainAxisFromPlacement from \"./getMainAxisFromPlacement.js\";\nimport { top, right, bottom, left, start, end } from \"../enums.js\";\nexport default function computeOffsets(_ref) {\n var reference = _ref.reference,\n element = _ref.element,\n placement = _ref.placement;\n var basePlacement = placement ? getBasePlacement(placement) : null;\n var variation = placement ? getVariation(placement) : null;\n var commonX = reference.x + reference.width / 2 - element.width / 2;\n var commonY = reference.y + reference.height / 2 - element.height / 2;\n var offsets;\n\n switch (basePlacement) {\n case top:\n offsets = {\n x: commonX,\n y: reference.y - element.height\n };\n break;\n\n case bottom:\n offsets = {\n x: commonX,\n y: reference.y + reference.height\n };\n break;\n\n case right:\n offsets = {\n x: reference.x + reference.width,\n y: commonY\n };\n break;\n\n case left:\n offsets = {\n x: reference.x - element.width,\n y: commonY\n };\n break;\n\n default:\n offsets = {\n x: reference.x,\n y: reference.y\n };\n }\n\n var mainAxis = basePlacement ? getMainAxisFromPlacement(basePlacement) : null;\n\n if (mainAxis != null) {\n var len = mainAxis === 'y' ? 'height' : 'width';\n\n switch (variation) {\n case start:\n offsets[mainAxis] = offsets[mainAxis] - (reference[len] / 2 - element[len] / 2);\n break;\n\n case end:\n offsets[mainAxis] = offsets[mainAxis] + (reference[len] / 2 - element[len] / 2);\n break;\n\n default:\n }\n }\n\n return offsets;\n}","import getClippingRect from \"../dom-utils/getClippingRect.js\";\nimport getDocumentElement from \"../dom-utils/getDocumentElement.js\";\nimport getBoundingClientRect from \"../dom-utils/getBoundingClientRect.js\";\nimport computeOffsets from \"./computeOffsets.js\";\nimport rectToClientRect from \"./rectToClientRect.js\";\nimport { clippingParents, reference, popper, bottom, top, right, basePlacements, viewport } from \"../enums.js\";\nimport { isElement } from \"../dom-utils/instanceOf.js\";\nimport mergePaddingObject from \"./mergePaddingObject.js\";\nimport expandToHashMap from \"./expandToHashMap.js\"; // eslint-disable-next-line import/no-unused-modules\n\nexport default function detectOverflow(state, options) {\n if (options === void 0) {\n options = {};\n }\n\n var _options = options,\n _options$placement = _options.placement,\n placement = _options$placement === void 0 ? state.placement : _options$placement,\n _options$strategy = _options.strategy,\n strategy = _options$strategy === void 0 ? state.strategy : _options$strategy,\n _options$boundary = _options.boundary,\n boundary = _options$boundary === void 0 ? clippingParents : _options$boundary,\n _options$rootBoundary = _options.rootBoundary,\n rootBoundary = _options$rootBoundary === void 0 ? viewport : _options$rootBoundary,\n _options$elementConte = _options.elementContext,\n elementContext = _options$elementConte === void 0 ? popper : _options$elementConte,\n _options$altBoundary = _options.altBoundary,\n altBoundary = _options$altBoundary === void 0 ? false : _options$altBoundary,\n _options$padding = _options.padding,\n padding = _options$padding === void 0 ? 0 : _options$padding;\n var paddingObject = mergePaddingObject(typeof padding !== 'number' ? padding : expandToHashMap(padding, basePlacements));\n var altContext = elementContext === popper ? reference : popper;\n var popperRect = state.rects.popper;\n var element = state.elements[altBoundary ? altContext : elementContext];\n var clippingClientRect = getClippingRect(isElement(element) ? element : element.contextElement || getDocumentElement(state.elements.popper), boundary, rootBoundary, strategy);\n var referenceClientRect = getBoundingClientRect(state.elements.reference);\n var popperOffsets = computeOffsets({\n reference: referenceClientRect,\n element: popperRect,\n strategy: 'absolute',\n placement: placement\n });\n var popperClientRect = rectToClientRect(Object.assign({}, popperRect, popperOffsets));\n var elementClientRect = elementContext === popper ? popperClientRect : referenceClientRect; // positive = overflowing the clipping rect\n // 0 or negative = within the clipping rect\n\n var overflowOffsets = {\n top: clippingClientRect.top - elementClientRect.top + paddingObject.top,\n bottom: elementClientRect.bottom - clippingClientRect.bottom + paddingObject.bottom,\n left: clippingClientRect.left - elementClientRect.left + paddingObject.left,\n right: elementClientRect.right - clippingClientRect.right + paddingObject.right\n };\n var offsetData = state.modifiersData.offset; // Offsets can be applied only to the popper element\n\n if (elementContext === popper && offsetData) {\n var offset = offsetData[placement];\n Object.keys(overflowOffsets).forEach(function (key) {\n var multiply = [right, bottom].indexOf(key) >= 0 ? 1 : -1;\n var axis = [top, bottom].indexOf(key) >= 0 ? 'y' : 'x';\n overflowOffsets[key] += offset[axis] * multiply;\n });\n }\n\n return overflowOffsets;\n}","import getVariation from \"./getVariation.js\";\nimport { variationPlacements, basePlacements, placements as allPlacements } from \"../enums.js\";\nimport detectOverflow from \"./detectOverflow.js\";\nimport getBasePlacement from \"./getBasePlacement.js\";\nexport default function computeAutoPlacement(state, options) {\n if (options === void 0) {\n options = {};\n }\n\n var _options = options,\n placement = _options.placement,\n boundary = _options.boundary,\n rootBoundary = _options.rootBoundary,\n padding = _options.padding,\n flipVariations = _options.flipVariations,\n _options$allowedAutoP = _options.allowedAutoPlacements,\n allowedAutoPlacements = _options$allowedAutoP === void 0 ? allPlacements : _options$allowedAutoP;\n var variation = getVariation(placement);\n var placements = variation ? flipVariations ? variationPlacements : variationPlacements.filter(function (placement) {\n return getVariation(placement) === variation;\n }) : basePlacements;\n var allowedPlacements = placements.filter(function (placement) {\n return allowedAutoPlacements.indexOf(placement) >= 0;\n });\n\n if (allowedPlacements.length === 0) {\n allowedPlacements = placements;\n } // $FlowFixMe[incompatible-type]: Flow seems to have problems with two array unions...\n\n\n var overflows = allowedPlacements.reduce(function (acc, placement) {\n acc[placement] = detectOverflow(state, {\n placement: placement,\n boundary: boundary,\n rootBoundary: rootBoundary,\n padding: padding\n })[getBasePlacement(placement)];\n return acc;\n }, {});\n return Object.keys(overflows).sort(function (a, b) {\n return overflows[a] - overflows[b];\n });\n}","import getOppositePlacement from \"../utils/getOppositePlacement.js\";\nimport getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getOppositeVariationPlacement from \"../utils/getOppositeVariationPlacement.js\";\nimport detectOverflow from \"../utils/detectOverflow.js\";\nimport computeAutoPlacement from \"../utils/computeAutoPlacement.js\";\nimport { bottom, top, start, right, left, auto } from \"../enums.js\";\nimport getVariation from \"../utils/getVariation.js\"; // eslint-disable-next-line import/no-unused-modules\n\nfunction getExpandedFallbackPlacements(placement) {\n if (getBasePlacement(placement) === auto) {\n return [];\n }\n\n var oppositePlacement = getOppositePlacement(placement);\n return [getOppositeVariationPlacement(placement), oppositePlacement, getOppositeVariationPlacement(oppositePlacement)];\n}\n\nfunction flip(_ref) {\n var state = _ref.state,\n options = _ref.options,\n name = _ref.name;\n\n if (state.modifiersData[name]._skip) {\n return;\n }\n\n var _options$mainAxis = options.mainAxis,\n checkMainAxis = _options$mainAxis === void 0 ? true : _options$mainAxis,\n _options$altAxis = options.altAxis,\n checkAltAxis = _options$altAxis === void 0 ? true : _options$altAxis,\n specifiedFallbackPlacements = options.fallbackPlacements,\n padding = options.padding,\n boundary = options.boundary,\n rootBoundary = options.rootBoundary,\n altBoundary = options.altBoundary,\n _options$flipVariatio = options.flipVariations,\n flipVariations = _options$flipVariatio === void 0 ? true : _options$flipVariatio,\n allowedAutoPlacements = options.allowedAutoPlacements;\n var preferredPlacement = state.options.placement;\n var basePlacement = getBasePlacement(preferredPlacement);\n var isBasePlacement = basePlacement === preferredPlacement;\n var fallbackPlacements = specifiedFallbackPlacements || (isBasePlacement || !flipVariations ? [getOppositePlacement(preferredPlacement)] : getExpandedFallbackPlacements(preferredPlacement));\n var placements = [preferredPlacement].concat(fallbackPlacements).reduce(function (acc, placement) {\n return acc.concat(getBasePlacement(placement) === auto ? computeAutoPlacement(state, {\n placement: placement,\n boundary: boundary,\n rootBoundary: rootBoundary,\n padding: padding,\n flipVariations: flipVariations,\n allowedAutoPlacements: allowedAutoPlacements\n }) : placement);\n }, []);\n var referenceRect = state.rects.reference;\n var popperRect = state.rects.popper;\n var checksMap = new Map();\n var makeFallbackChecks = true;\n var firstFittingPlacement = placements[0];\n\n for (var i = 0; i < placements.length; i++) {\n var placement = placements[i];\n\n var _basePlacement = getBasePlacement(placement);\n\n var isStartVariation = getVariation(placement) === start;\n var isVertical = [top, bottom].indexOf(_basePlacement) >= 0;\n var len = isVertical ? 'width' : 'height';\n var overflow = detectOverflow(state, {\n placement: placement,\n boundary: boundary,\n rootBoundary: rootBoundary,\n altBoundary: altBoundary,\n padding: padding\n });\n var mainVariationSide = isVertical ? isStartVariation ? right : left : isStartVariation ? bottom : top;\n\n if (referenceRect[len] > popperRect[len]) {\n mainVariationSide = getOppositePlacement(mainVariationSide);\n }\n\n var altVariationSide = getOppositePlacement(mainVariationSide);\n var checks = [];\n\n if (checkMainAxis) {\n checks.push(overflow[_basePlacement] <= 0);\n }\n\n if (checkAltAxis) {\n checks.push(overflow[mainVariationSide] <= 0, overflow[altVariationSide] <= 0);\n }\n\n if (checks.every(function (check) {\n return check;\n })) {\n firstFittingPlacement = placement;\n makeFallbackChecks = false;\n break;\n }\n\n checksMap.set(placement, checks);\n }\n\n if (makeFallbackChecks) {\n // `2` may be desired in some cases – research later\n var numberOfChecks = flipVariations ? 3 : 1;\n\n var _loop = function _loop(_i) {\n var fittingPlacement = placements.find(function (placement) {\n var checks = checksMap.get(placement);\n\n if (checks) {\n return checks.slice(0, _i).every(function (check) {\n return check;\n });\n }\n });\n\n if (fittingPlacement) {\n firstFittingPlacement = fittingPlacement;\n return \"break\";\n }\n };\n\n for (var _i = numberOfChecks; _i > 0; _i--) {\n var _ret = _loop(_i);\n\n if (_ret === \"break\") break;\n }\n }\n\n if (state.placement !== firstFittingPlacement) {\n state.modifiersData[name]._skip = true;\n state.placement = firstFittingPlacement;\n state.reset = true;\n }\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'flip',\n enabled: true,\n phase: 'main',\n fn: flip,\n requiresIfExists: ['offset'],\n data: {\n _skip: false\n }\n};","import { top, bottom, left, right } from \"../enums.js\";\nimport detectOverflow from \"../utils/detectOverflow.js\";\n\nfunction getSideOffsets(overflow, rect, preventedOffsets) {\n if (preventedOffsets === void 0) {\n preventedOffsets = {\n x: 0,\n y: 0\n };\n }\n\n return {\n top: overflow.top - rect.height - preventedOffsets.y,\n right: overflow.right - rect.width + preventedOffsets.x,\n bottom: overflow.bottom - rect.height + preventedOffsets.y,\n left: overflow.left - rect.width - preventedOffsets.x\n };\n}\n\nfunction isAnySideFullyClipped(overflow) {\n return [top, right, bottom, left].some(function (side) {\n return overflow[side] >= 0;\n });\n}\n\nfunction hide(_ref) {\n var state = _ref.state,\n name = _ref.name;\n var referenceRect = state.rects.reference;\n var popperRect = state.rects.popper;\n var preventedOffsets = state.modifiersData.preventOverflow;\n var referenceOverflow = detectOverflow(state, {\n elementContext: 'reference'\n });\n var popperAltOverflow = detectOverflow(state, {\n altBoundary: true\n });\n var referenceClippingOffsets = getSideOffsets(referenceOverflow, referenceRect);\n var popperEscapeOffsets = getSideOffsets(popperAltOverflow, popperRect, preventedOffsets);\n var isReferenceHidden = isAnySideFullyClipped(referenceClippingOffsets);\n var hasPopperEscaped = isAnySideFullyClipped(popperEscapeOffsets);\n state.modifiersData[name] = {\n referenceClippingOffsets: referenceClippingOffsets,\n popperEscapeOffsets: popperEscapeOffsets,\n isReferenceHidden: isReferenceHidden,\n hasPopperEscaped: hasPopperEscaped\n };\n state.attributes.popper = Object.assign({}, state.attributes.popper, {\n 'data-popper-reference-hidden': isReferenceHidden,\n 'data-popper-escaped': hasPopperEscaped\n });\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'hide',\n enabled: true,\n phase: 'main',\n requiresIfExists: ['preventOverflow'],\n fn: hide\n};","import getBasePlacement from \"../utils/getBasePlacement.js\";\nimport { top, left, right, placements } from \"../enums.js\"; // eslint-disable-next-line import/no-unused-modules\n\nexport function distanceAndSkiddingToXY(placement, rects, offset) {\n var basePlacement = getBasePlacement(placement);\n var invertDistance = [left, top].indexOf(basePlacement) >= 0 ? -1 : 1;\n\n var _ref = typeof offset === 'function' ? offset(Object.assign({}, rects, {\n placement: placement\n })) : offset,\n skidding = _ref[0],\n distance = _ref[1];\n\n skidding = skidding || 0;\n distance = (distance || 0) * invertDistance;\n return [left, right].indexOf(basePlacement) >= 0 ? {\n x: distance,\n y: skidding\n } : {\n x: skidding,\n y: distance\n };\n}\n\nfunction offset(_ref2) {\n var state = _ref2.state,\n options = _ref2.options,\n name = _ref2.name;\n var _options$offset = options.offset,\n offset = _options$offset === void 0 ? [0, 0] : _options$offset;\n var data = placements.reduce(function (acc, placement) {\n acc[placement] = distanceAndSkiddingToXY(placement, state.rects, offset);\n return acc;\n }, {});\n var _data$state$placement = data[state.placement],\n x = _data$state$placement.x,\n y = _data$state$placement.y;\n\n if (state.modifiersData.popperOffsets != null) {\n state.modifiersData.popperOffsets.x += x;\n state.modifiersData.popperOffsets.y += y;\n }\n\n state.modifiersData[name] = data;\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'offset',\n enabled: true,\n phase: 'main',\n requires: ['popperOffsets'],\n fn: offset\n};","import computeOffsets from \"../utils/computeOffsets.js\";\n\nfunction popperOffsets(_ref) {\n var state = _ref.state,\n name = _ref.name;\n // Offsets are the actual position the popper needs to have to be\n // properly positioned near its reference element\n // This is the most basic placement, and will be adjusted by\n // the modifiers in the next step\n state.modifiersData[name] = computeOffsets({\n reference: state.rects.reference,\n element: state.rects.popper,\n strategy: 'absolute',\n placement: state.placement\n });\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'popperOffsets',\n enabled: true,\n phase: 'read',\n fn: popperOffsets,\n data: {}\n};","export default function getAltAxis(axis) {\n return axis === 'x' ? 'y' : 'x';\n}","import { top, left, right, bottom, start } from \"../enums.js\";\nimport getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getMainAxisFromPlacement from \"../utils/getMainAxisFromPlacement.js\";\nimport getAltAxis from \"../utils/getAltAxis.js\";\nimport { within, withinMaxClamp } from \"../utils/within.js\";\nimport getLayoutRect from \"../dom-utils/getLayoutRect.js\";\nimport getOffsetParent from \"../dom-utils/getOffsetParent.js\";\nimport detectOverflow from \"../utils/detectOverflow.js\";\nimport getVariation from \"../utils/getVariation.js\";\nimport getFreshSideObject from \"../utils/getFreshSideObject.js\";\nimport { min as mathMin, max as mathMax } from \"../utils/math.js\";\n\nfunction preventOverflow(_ref) {\n var state = _ref.state,\n options = _ref.options,\n name = _ref.name;\n var _options$mainAxis = options.mainAxis,\n checkMainAxis = _options$mainAxis === void 0 ? true : _options$mainAxis,\n _options$altAxis = options.altAxis,\n checkAltAxis = _options$altAxis === void 0 ? false : _options$altAxis,\n boundary = options.boundary,\n rootBoundary = options.rootBoundary,\n altBoundary = options.altBoundary,\n padding = options.padding,\n _options$tether = options.tether,\n tether = _options$tether === void 0 ? true : _options$tether,\n _options$tetherOffset = options.tetherOffset,\n tetherOffset = _options$tetherOffset === void 0 ? 0 : _options$tetherOffset;\n var overflow = detectOverflow(state, {\n boundary: boundary,\n rootBoundary: rootBoundary,\n padding: padding,\n altBoundary: altBoundary\n });\n var basePlacement = getBasePlacement(state.placement);\n var variation = getVariation(state.placement);\n var isBasePlacement = !variation;\n var mainAxis = getMainAxisFromPlacement(basePlacement);\n var altAxis = getAltAxis(mainAxis);\n var popperOffsets = state.modifiersData.popperOffsets;\n var referenceRect = state.rects.reference;\n var popperRect = state.rects.popper;\n var tetherOffsetValue = typeof tetherOffset === 'function' ? tetherOffset(Object.assign({}, state.rects, {\n placement: state.placement\n })) : tetherOffset;\n var normalizedTetherOffsetValue = typeof tetherOffsetValue === 'number' ? {\n mainAxis: tetherOffsetValue,\n altAxis: tetherOffsetValue\n } : Object.assign({\n mainAxis: 0,\n altAxis: 0\n }, tetherOffsetValue);\n var offsetModifierState = state.modifiersData.offset ? state.modifiersData.offset[state.placement] : null;\n var data = {\n x: 0,\n y: 0\n };\n\n if (!popperOffsets) {\n return;\n }\n\n if (checkMainAxis) {\n var _offsetModifierState$;\n\n var mainSide = mainAxis === 'y' ? top : left;\n var altSide = mainAxis === 'y' ? bottom : right;\n var len = mainAxis === 'y' ? 'height' : 'width';\n var offset = popperOffsets[mainAxis];\n var min = offset + overflow[mainSide];\n var max = offset - overflow[altSide];\n var additive = tether ? -popperRect[len] / 2 : 0;\n var minLen = variation === start ? referenceRect[len] : popperRect[len];\n var maxLen = variation === start ? -popperRect[len] : -referenceRect[len]; // We need to include the arrow in the calculation so the arrow doesn't go\n // outside the reference bounds\n\n var arrowElement = state.elements.arrow;\n var arrowRect = tether && arrowElement ? getLayoutRect(arrowElement) : {\n width: 0,\n height: 0\n };\n var arrowPaddingObject = state.modifiersData['arrow#persistent'] ? state.modifiersData['arrow#persistent'].padding : getFreshSideObject();\n var arrowPaddingMin = arrowPaddingObject[mainSide];\n var arrowPaddingMax = arrowPaddingObject[altSide]; // If the reference length is smaller than the arrow length, we don't want\n // to include its full size in the calculation. If the reference is small\n // and near the edge of a boundary, the popper can overflow even if the\n // reference is not overflowing as well (e.g. virtual elements with no\n // width or height)\n\n var arrowLen = within(0, referenceRect[len], arrowRect[len]);\n var minOffset = isBasePlacement ? referenceRect[len] / 2 - additive - arrowLen - arrowPaddingMin - normalizedTetherOffsetValue.mainAxis : minLen - arrowLen - arrowPaddingMin - normalizedTetherOffsetValue.mainAxis;\n var maxOffset = isBasePlacement ? -referenceRect[len] / 2 + additive + arrowLen + arrowPaddingMax + normalizedTetherOffsetValue.mainAxis : maxLen + arrowLen + arrowPaddingMax + normalizedTetherOffsetValue.mainAxis;\n var arrowOffsetParent = state.elements.arrow && getOffsetParent(state.elements.arrow);\n var clientOffset = arrowOffsetParent ? mainAxis === 'y' ? arrowOffsetParent.clientTop || 0 : arrowOffsetParent.clientLeft || 0 : 0;\n var offsetModifierValue = (_offsetModifierState$ = offsetModifierState == null ? void 0 : offsetModifierState[mainAxis]) != null ? _offsetModifierState$ : 0;\n var tetherMin = offset + minOffset - offsetModifierValue - clientOffset;\n var tetherMax = offset + maxOffset - offsetModifierValue;\n var preventedOffset = within(tether ? mathMin(min, tetherMin) : min, offset, tether ? mathMax(max, tetherMax) : max);\n popperOffsets[mainAxis] = preventedOffset;\n data[mainAxis] = preventedOffset - offset;\n }\n\n if (checkAltAxis) {\n var _offsetModifierState$2;\n\n var _mainSide = mainAxis === 'x' ? top : left;\n\n var _altSide = mainAxis === 'x' ? bottom : right;\n\n var _offset = popperOffsets[altAxis];\n\n var _len = altAxis === 'y' ? 'height' : 'width';\n\n var _min = _offset + overflow[_mainSide];\n\n var _max = _offset - overflow[_altSide];\n\n var isOriginSide = [top, left].indexOf(basePlacement) !== -1;\n\n var _offsetModifierValue = (_offsetModifierState$2 = offsetModifierState == null ? void 0 : offsetModifierState[altAxis]) != null ? _offsetModifierState$2 : 0;\n\n var _tetherMin = isOriginSide ? _min : _offset - referenceRect[_len] - popperRect[_len] - _offsetModifierValue + normalizedTetherOffsetValue.altAxis;\n\n var _tetherMax = isOriginSide ? _offset + referenceRect[_len] + popperRect[_len] - _offsetModifierValue - normalizedTetherOffsetValue.altAxis : _max;\n\n var _preventedOffset = tether && isOriginSide ? withinMaxClamp(_tetherMin, _offset, _tetherMax) : within(tether ? _tetherMin : _min, _offset, tether ? _tetherMax : _max);\n\n popperOffsets[altAxis] = _preventedOffset;\n data[altAxis] = _preventedOffset - _offset;\n }\n\n state.modifiersData[name] = data;\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'preventOverflow',\n enabled: true,\n phase: 'main',\n fn: preventOverflow,\n requiresIfExists: ['offset']\n};","export default function getHTMLElementScroll(element) {\n return {\n scrollLeft: element.scrollLeft,\n scrollTop: element.scrollTop\n };\n}","import getWindowScroll from \"./getWindowScroll.js\";\nimport getWindow from \"./getWindow.js\";\nimport { isHTMLElement } from \"./instanceOf.js\";\nimport getHTMLElementScroll from \"./getHTMLElementScroll.js\";\nexport default function getNodeScroll(node) {\n if (node === getWindow(node) || !isHTMLElement(node)) {\n return getWindowScroll(node);\n } else {\n return getHTMLElementScroll(node);\n }\n}","import getBoundingClientRect from \"./getBoundingClientRect.js\";\nimport getNodeScroll from \"./getNodeScroll.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport { isHTMLElement } from \"./instanceOf.js\";\nimport getWindowScrollBarX from \"./getWindowScrollBarX.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport isScrollParent from \"./isScrollParent.js\";\nimport { round } from \"../utils/math.js\";\n\nfunction isElementScaled(element) {\n var rect = element.getBoundingClientRect();\n var scaleX = round(rect.width) / element.offsetWidth || 1;\n var scaleY = round(rect.height) / element.offsetHeight || 1;\n return scaleX !== 1 || scaleY !== 1;\n} // Returns the composite rect of an element relative to its offsetParent.\n// Composite means it takes into account transforms as well as layout.\n\n\nexport default function getCompositeRect(elementOrVirtualElement, offsetParent, isFixed) {\n if (isFixed === void 0) {\n isFixed = false;\n }\n\n var isOffsetParentAnElement = isHTMLElement(offsetParent);\n var offsetParentIsScaled = isHTMLElement(offsetParent) && isElementScaled(offsetParent);\n var documentElement = getDocumentElement(offsetParent);\n var rect = getBoundingClientRect(elementOrVirtualElement, offsetParentIsScaled, isFixed);\n var scroll = {\n scrollLeft: 0,\n scrollTop: 0\n };\n var offsets = {\n x: 0,\n y: 0\n };\n\n if (isOffsetParentAnElement || !isOffsetParentAnElement && !isFixed) {\n if (getNodeName(offsetParent) !== 'body' || // https://github.com/popperjs/popper-core/issues/1078\n isScrollParent(documentElement)) {\n scroll = getNodeScroll(offsetParent);\n }\n\n if (isHTMLElement(offsetParent)) {\n offsets = getBoundingClientRect(offsetParent, true);\n offsets.x += offsetParent.clientLeft;\n offsets.y += offsetParent.clientTop;\n } else if (documentElement) {\n offsets.x = getWindowScrollBarX(documentElement);\n }\n }\n\n return {\n x: rect.left + scroll.scrollLeft - offsets.x,\n y: rect.top + scroll.scrollTop - offsets.y,\n width: rect.width,\n height: rect.height\n };\n}","import { modifierPhases } from \"../enums.js\"; // source: https://stackoverflow.com/questions/49875255\n\nfunction order(modifiers) {\n var map = new Map();\n var visited = new Set();\n var result = [];\n modifiers.forEach(function (modifier) {\n map.set(modifier.name, modifier);\n }); // On visiting object, check for its dependencies and visit them recursively\n\n function sort(modifier) {\n visited.add(modifier.name);\n var requires = [].concat(modifier.requires || [], modifier.requiresIfExists || []);\n requires.forEach(function (dep) {\n if (!visited.has(dep)) {\n var depModifier = map.get(dep);\n\n if (depModifier) {\n sort(depModifier);\n }\n }\n });\n result.push(modifier);\n }\n\n modifiers.forEach(function (modifier) {\n if (!visited.has(modifier.name)) {\n // check for visited object\n sort(modifier);\n }\n });\n return result;\n}\n\nexport default function orderModifiers(modifiers) {\n // order based on dependencies\n var orderedModifiers = order(modifiers); // order based on phase\n\n return modifierPhases.reduce(function (acc, phase) {\n return acc.concat(orderedModifiers.filter(function (modifier) {\n return modifier.phase === phase;\n }));\n }, []);\n}","export default function debounce(fn) {\n var pending;\n return function () {\n if (!pending) {\n pending = new Promise(function (resolve) {\n Promise.resolve().then(function () {\n pending = undefined;\n resolve(fn());\n });\n });\n }\n\n return pending;\n };\n}","export default function mergeByName(modifiers) {\n var merged = modifiers.reduce(function (merged, current) {\n var existing = merged[current.name];\n merged[current.name] = existing ? Object.assign({}, existing, current, {\n options: Object.assign({}, existing.options, current.options),\n data: Object.assign({}, existing.data, current.data)\n }) : current;\n return merged;\n }, {}); // IE11 does not support Object.values\n\n return Object.keys(merged).map(function (key) {\n return merged[key];\n });\n}","import getCompositeRect from \"./dom-utils/getCompositeRect.js\";\nimport getLayoutRect from \"./dom-utils/getLayoutRect.js\";\nimport listScrollParents from \"./dom-utils/listScrollParents.js\";\nimport getOffsetParent from \"./dom-utils/getOffsetParent.js\";\nimport orderModifiers from \"./utils/orderModifiers.js\";\nimport debounce from \"./utils/debounce.js\";\nimport mergeByName from \"./utils/mergeByName.js\";\nimport detectOverflow from \"./utils/detectOverflow.js\";\nimport { isElement } from \"./dom-utils/instanceOf.js\";\nvar DEFAULT_OPTIONS = {\n placement: 'bottom',\n modifiers: [],\n strategy: 'absolute'\n};\n\nfunction areValidElements() {\n for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {\n args[_key] = arguments[_key];\n }\n\n return !args.some(function (element) {\n return !(element && typeof element.getBoundingClientRect === 'function');\n });\n}\n\nexport function popperGenerator(generatorOptions) {\n if (generatorOptions === void 0) {\n generatorOptions = {};\n }\n\n var _generatorOptions = generatorOptions,\n _generatorOptions$def = _generatorOptions.defaultModifiers,\n defaultModifiers = _generatorOptions$def === void 0 ? [] : _generatorOptions$def,\n _generatorOptions$def2 = _generatorOptions.defaultOptions,\n defaultOptions = _generatorOptions$def2 === void 0 ? DEFAULT_OPTIONS : _generatorOptions$def2;\n return function createPopper(reference, popper, options) {\n if (options === void 0) {\n options = defaultOptions;\n }\n\n var state = {\n placement: 'bottom',\n orderedModifiers: [],\n options: Object.assign({}, DEFAULT_OPTIONS, defaultOptions),\n modifiersData: {},\n elements: {\n reference: reference,\n popper: popper\n },\n attributes: {},\n styles: {}\n };\n var effectCleanupFns = [];\n var isDestroyed = false;\n var instance = {\n state: state,\n setOptions: function setOptions(setOptionsAction) {\n var options = typeof setOptionsAction === 'function' ? setOptionsAction(state.options) : setOptionsAction;\n cleanupModifierEffects();\n state.options = Object.assign({}, defaultOptions, state.options, options);\n state.scrollParents = {\n reference: isElement(reference) ? listScrollParents(reference) : reference.contextElement ? listScrollParents(reference.contextElement) : [],\n popper: listScrollParents(popper)\n }; // Orders the modifiers based on their dependencies and `phase`\n // properties\n\n var orderedModifiers = orderModifiers(mergeByName([].concat(defaultModifiers, state.options.modifiers))); // Strip out disabled modifiers\n\n state.orderedModifiers = orderedModifiers.filter(function (m) {\n return m.enabled;\n });\n runModifierEffects();\n return instance.update();\n },\n // Sync update – it will always be executed, even if not necessary. This\n // is useful for low frequency updates where sync behavior simplifies the\n // logic.\n // For high frequency updates (e.g. `resize` and `scroll` events), always\n // prefer the async Popper#update method\n forceUpdate: function forceUpdate() {\n if (isDestroyed) {\n return;\n }\n\n var _state$elements = state.elements,\n reference = _state$elements.reference,\n popper = _state$elements.popper; // Don't proceed if `reference` or `popper` are not valid elements\n // anymore\n\n if (!areValidElements(reference, popper)) {\n return;\n } // Store the reference and popper rects to be read by modifiers\n\n\n state.rects = {\n reference: getCompositeRect(reference, getOffsetParent(popper), state.options.strategy === 'fixed'),\n popper: getLayoutRect(popper)\n }; // Modifiers have the ability to reset the current update cycle. The\n // most common use case for this is the `flip` modifier changing the\n // placement, which then needs to re-run all the modifiers, because the\n // logic was previously ran for the previous placement and is therefore\n // stale/incorrect\n\n state.reset = false;\n state.placement = state.options.placement; // On each update cycle, the `modifiersData` property for each modifier\n // is filled with the initial data specified by the modifier. This means\n // it doesn't persist and is fresh on each update.\n // To ensure persistent data, use `${name}#persistent`\n\n state.orderedModifiers.forEach(function (modifier) {\n return state.modifiersData[modifier.name] = Object.assign({}, modifier.data);\n });\n\n for (var index = 0; index < state.orderedModifiers.length; index++) {\n if (state.reset === true) {\n state.reset = false;\n index = -1;\n continue;\n }\n\n var _state$orderedModifie = state.orderedModifiers[index],\n fn = _state$orderedModifie.fn,\n _state$orderedModifie2 = _state$orderedModifie.options,\n _options = _state$orderedModifie2 === void 0 ? {} : _state$orderedModifie2,\n name = _state$orderedModifie.name;\n\n if (typeof fn === 'function') {\n state = fn({\n state: state,\n options: _options,\n name: name,\n instance: instance\n }) || state;\n }\n }\n },\n // Async and optimistically optimized update – it will not be executed if\n // not necessary (debounced to run at most once-per-tick)\n update: debounce(function () {\n return new Promise(function (resolve) {\n instance.forceUpdate();\n resolve(state);\n });\n }),\n destroy: function destroy() {\n cleanupModifierEffects();\n isDestroyed = true;\n }\n };\n\n if (!areValidElements(reference, popper)) {\n return instance;\n }\n\n instance.setOptions(options).then(function (state) {\n if (!isDestroyed && options.onFirstUpdate) {\n options.onFirstUpdate(state);\n }\n }); // Modifiers have the ability to execute arbitrary code before the first\n // update cycle runs. They will be executed in the same order as the update\n // cycle. This is useful when a modifier adds some persistent data that\n // other modifiers need to use, but the modifier is run after the dependent\n // one.\n\n function runModifierEffects() {\n state.orderedModifiers.forEach(function (_ref) {\n var name = _ref.name,\n _ref$options = _ref.options,\n options = _ref$options === void 0 ? {} : _ref$options,\n effect = _ref.effect;\n\n if (typeof effect === 'function') {\n var cleanupFn = effect({\n state: state,\n name: name,\n instance: instance,\n options: options\n });\n\n var noopFn = function noopFn() {};\n\n effectCleanupFns.push(cleanupFn || noopFn);\n }\n });\n }\n\n function cleanupModifierEffects() {\n effectCleanupFns.forEach(function (fn) {\n return fn();\n });\n effectCleanupFns = [];\n }\n\n return instance;\n };\n}\nexport var createPopper = /*#__PURE__*/popperGenerator(); // eslint-disable-next-line import/no-unused-modules\n\nexport { detectOverflow };","import { popperGenerator, detectOverflow } from \"./createPopper.js\";\nimport eventListeners from \"./modifiers/eventListeners.js\";\nimport popperOffsets from \"./modifiers/popperOffsets.js\";\nimport computeStyles from \"./modifiers/computeStyles.js\";\nimport applyStyles from \"./modifiers/applyStyles.js\";\nimport offset from \"./modifiers/offset.js\";\nimport flip from \"./modifiers/flip.js\";\nimport preventOverflow from \"./modifiers/preventOverflow.js\";\nimport arrow from \"./modifiers/arrow.js\";\nimport hide from \"./modifiers/hide.js\";\nvar defaultModifiers = [eventListeners, popperOffsets, computeStyles, applyStyles, offset, flip, preventOverflow, arrow, hide];\nvar createPopper = /*#__PURE__*/popperGenerator({\n defaultModifiers: defaultModifiers\n}); // eslint-disable-next-line import/no-unused-modules\n\nexport { createPopper, popperGenerator, defaultModifiers, detectOverflow }; // eslint-disable-next-line import/no-unused-modules\n\nexport { createPopper as createPopperLite } from \"./popper-lite.js\"; // eslint-disable-next-line import/no-unused-modules\n\nexport * from \"./modifiers/index.js\";","import { generateUtilityClass } from '../generateUtilityClass';\nimport { generateUtilityClasses } from '../generateUtilityClasses';\nconst COMPONENT_NAME = 'Popper';\nexport function getPopperUtilityClass(slot) {\n return generateUtilityClass(COMPONENT_NAME, slot);\n}\nexport const popperClasses = generateUtilityClasses(COMPONENT_NAME, ['root']);","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"anchorEl\", \"children\", \"direction\", \"disablePortal\", \"modifiers\", \"open\", \"placement\", \"popperOptions\", \"popperRef\", \"slotProps\", \"slots\", \"TransitionProps\", \"ownerState\"],\n _excluded2 = [\"anchorEl\", \"children\", \"container\", \"direction\", \"disablePortal\", \"keepMounted\", \"modifiers\", \"open\", \"placement\", \"popperOptions\", \"popperRef\", \"style\", \"transition\", \"slotProps\", \"slots\"];\nimport * as React from 'react';\nimport { chainPropTypes, HTMLElementType, refType, unstable_ownerDocument as ownerDocument, unstable_useEnhancedEffect as useEnhancedEffect, unstable_useForkRef as useForkRef } from '@mui/utils';\nimport { createPopper } from '@popperjs/core';\nimport PropTypes from 'prop-types';\nimport { unstable_composeClasses as composeClasses } from '../composeClasses';\nimport { Portal } from '../Portal';\nimport { getPopperUtilityClass } from './popperClasses';\nimport { useSlotProps } from '../utils';\nimport { useClassNamesOverride } from '../utils/ClassNameConfigurator';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nfunction flipPlacement(placement, direction) {\n if (direction === 'ltr') {\n return placement;\n }\n switch (placement) {\n case 'bottom-end':\n return 'bottom-start';\n case 'bottom-start':\n return 'bottom-end';\n case 'top-end':\n return 'top-start';\n case 'top-start':\n return 'top-end';\n default:\n return placement;\n }\n}\nfunction resolveAnchorEl(anchorEl) {\n return typeof anchorEl === 'function' ? anchorEl() : anchorEl;\n}\nfunction isHTMLElement(element) {\n return element.nodeType !== undefined;\n}\nfunction isVirtualElement(element) {\n return !isHTMLElement(element);\n}\nconst useUtilityClasses = () => {\n const slots = {\n root: ['root']\n };\n return composeClasses(slots, useClassNamesOverride(getPopperUtilityClass));\n};\nconst defaultPopperOptions = {};\nconst PopperTooltip = /*#__PURE__*/React.forwardRef(function PopperTooltip(props, forwardedRef) {\n var _slots$root;\n const {\n anchorEl,\n children,\n direction,\n disablePortal,\n modifiers,\n open,\n placement: initialPlacement,\n popperOptions,\n popperRef: popperRefProp,\n slotProps = {},\n slots = {},\n TransitionProps\n // @ts-ignore internal logic\n // prevent from spreading to DOM, it can come from the parent component e.g. Select.\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const tooltipRef = React.useRef(null);\n const ownRef = useForkRef(tooltipRef, forwardedRef);\n const popperRef = React.useRef(null);\n const handlePopperRef = useForkRef(popperRef, popperRefProp);\n const handlePopperRefRef = React.useRef(handlePopperRef);\n useEnhancedEffect(() => {\n handlePopperRefRef.current = handlePopperRef;\n }, [handlePopperRef]);\n React.useImperativeHandle(popperRefProp, () => popperRef.current, []);\n const rtlPlacement = flipPlacement(initialPlacement, direction);\n /**\n * placement initialized from prop but can change during lifetime if modifiers.flip.\n * modifiers.flip is essentially a flip for controlled/uncontrolled behavior\n */\n const [placement, setPlacement] = React.useState(rtlPlacement);\n const [resolvedAnchorElement, setResolvedAnchorElement] = React.useState(resolveAnchorEl(anchorEl));\n React.useEffect(() => {\n if (popperRef.current) {\n popperRef.current.forceUpdate();\n }\n });\n React.useEffect(() => {\n if (anchorEl) {\n setResolvedAnchorElement(resolveAnchorEl(anchorEl));\n }\n }, [anchorEl]);\n useEnhancedEffect(() => {\n if (!resolvedAnchorElement || !open) {\n return undefined;\n }\n const handlePopperUpdate = data => {\n setPlacement(data.placement);\n };\n if (process.env.NODE_ENV !== 'production') {\n if (resolvedAnchorElement && isHTMLElement(resolvedAnchorElement) && resolvedAnchorElement.nodeType === 1) {\n const box = resolvedAnchorElement.getBoundingClientRect();\n if (process.env.NODE_ENV !== 'test' && box.top === 0 && box.left === 0 && box.right === 0 && box.bottom === 0) {\n console.warn(['MUI: The `anchorEl` prop provided to the component is invalid.', 'The anchor element should be part of the document layout.', \"Make sure the element is present in the document or that it's not display none.\"].join('\\n'));\n }\n }\n }\n let popperModifiers = [{\n name: 'preventOverflow',\n options: {\n altBoundary: disablePortal\n }\n }, {\n name: 'flip',\n options: {\n altBoundary: disablePortal\n }\n }, {\n name: 'onUpdate',\n enabled: true,\n phase: 'afterWrite',\n fn: ({\n state\n }) => {\n handlePopperUpdate(state);\n }\n }];\n if (modifiers != null) {\n popperModifiers = popperModifiers.concat(modifiers);\n }\n if (popperOptions && popperOptions.modifiers != null) {\n popperModifiers = popperModifiers.concat(popperOptions.modifiers);\n }\n const popper = createPopper(resolvedAnchorElement, tooltipRef.current, _extends({\n placement: rtlPlacement\n }, popperOptions, {\n modifiers: popperModifiers\n }));\n handlePopperRefRef.current(popper);\n return () => {\n popper.destroy();\n handlePopperRefRef.current(null);\n };\n }, [resolvedAnchorElement, disablePortal, modifiers, open, popperOptions, rtlPlacement]);\n const childProps = {\n placement: placement\n };\n if (TransitionProps !== null) {\n childProps.TransitionProps = TransitionProps;\n }\n const classes = useUtilityClasses();\n const Root = (_slots$root = slots.root) != null ? _slots$root : 'div';\n const rootProps = useSlotProps({\n elementType: Root,\n externalSlotProps: slotProps.root,\n externalForwardedProps: other,\n additionalProps: {\n role: 'tooltip',\n ref: ownRef\n },\n ownerState: props,\n className: classes.root\n });\n return /*#__PURE__*/_jsx(Root, _extends({}, rootProps, {\n children: typeof children === 'function' ? children(childProps) : children\n }));\n});\n\n/**\n * Poppers rely on the 3rd party library [Popper.js](https://popper.js.org/docs/v2/) for positioning.\n *\n * Demos:\n *\n * - [Popper](https://mui.com/base-ui/react-popper/)\n *\n * API:\n *\n * - [Popper API](https://mui.com/base-ui/react-popper/components-api/#popper)\n */\nconst Popper = /*#__PURE__*/React.forwardRef(function Popper(props, forwardedRef) {\n const {\n anchorEl,\n children,\n container: containerProp,\n direction = 'ltr',\n disablePortal = false,\n keepMounted = false,\n modifiers,\n open,\n placement = 'bottom',\n popperOptions = defaultPopperOptions,\n popperRef,\n style,\n transition = false,\n slotProps = {},\n slots = {}\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded2);\n const [exited, setExited] = React.useState(true);\n const handleEnter = () => {\n setExited(false);\n };\n const handleExited = () => {\n setExited(true);\n };\n if (!keepMounted && !open && (!transition || exited)) {\n return null;\n }\n\n // If the container prop is provided, use that\n // If the anchorEl prop is provided, use its parent body element as the container\n // If neither are provided let the Modal take care of choosing the container\n let container;\n if (containerProp) {\n container = containerProp;\n } else if (anchorEl) {\n const resolvedAnchorEl = resolveAnchorEl(anchorEl);\n container = resolvedAnchorEl && isHTMLElement(resolvedAnchorEl) ? ownerDocument(resolvedAnchorEl).body : ownerDocument(null).body;\n }\n const display = !open && keepMounted && (!transition || exited) ? 'none' : undefined;\n const transitionProps = transition ? {\n in: open,\n onEnter: handleEnter,\n onExited: handleExited\n } : undefined;\n return /*#__PURE__*/_jsx(Portal, {\n disablePortal: disablePortal,\n container: container,\n children: /*#__PURE__*/_jsx(PopperTooltip, _extends({\n anchorEl: anchorEl,\n direction: direction,\n disablePortal: disablePortal,\n modifiers: modifiers,\n ref: forwardedRef,\n open: transition ? !exited : open,\n placement: placement,\n popperOptions: popperOptions,\n popperRef: popperRef,\n slotProps: slotProps,\n slots: slots\n }, other, {\n style: _extends({\n // Prevents scroll issue, waiting for Popper.js to add this style once initiated.\n position: 'fixed',\n // Fix Popper.js display issue\n top: 0,\n left: 0,\n display\n }, style),\n TransitionProps: transitionProps,\n children: children\n }))\n });\n});\nprocess.env.NODE_ENV !== \"production\" ? Popper.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * An HTML element, [virtualElement](https://popper.js.org/docs/v2/virtual-elements/),\n * or a function that returns either.\n * It's used to set the position of the popper.\n * The return value will passed as the reference object of the Popper instance.\n */\n anchorEl: chainPropTypes(PropTypes.oneOfType([HTMLElementType, PropTypes.object, PropTypes.func]), props => {\n if (props.open) {\n const resolvedAnchorEl = resolveAnchorEl(props.anchorEl);\n if (resolvedAnchorEl && isHTMLElement(resolvedAnchorEl) && resolvedAnchorEl.nodeType === 1) {\n const box = resolvedAnchorEl.getBoundingClientRect();\n if (process.env.NODE_ENV !== 'test' && box.top === 0 && box.left === 0 && box.right === 0 && box.bottom === 0) {\n return new Error(['MUI: The `anchorEl` prop provided to the component is invalid.', 'The anchor element should be part of the document layout.', \"Make sure the element is present in the document or that it's not display none.\"].join('\\n'));\n }\n } else if (!resolvedAnchorEl || typeof resolvedAnchorEl.getBoundingClientRect !== 'function' || isVirtualElement(resolvedAnchorEl) && resolvedAnchorEl.contextElement != null && resolvedAnchorEl.contextElement.nodeType !== 1) {\n return new Error(['MUI: The `anchorEl` prop provided to the component is invalid.', 'It should be an HTML element instance or a virtualElement ', '(https://popper.js.org/docs/v2/virtual-elements/).'].join('\\n'));\n }\n }\n return null;\n }),\n /**\n * Popper render function or node.\n */\n children: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.node, PropTypes.func]),\n /**\n * An HTML element or function that returns one.\n * The `container` will have the portal children appended to it.\n *\n * You can also provide a callback, which is called in a React layout effect.\n * This lets you set the container from a ref, and also makes server-side rendering possible.\n *\n * By default, it uses the body of the top-level document object,\n * so it's simply `document.body` most of the time.\n */\n container: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.func]),\n /**\n * Direction of the text.\n * @default 'ltr'\n */\n direction: PropTypes.oneOf(['ltr', 'rtl']),\n /**\n * The `children` will be under the DOM hierarchy of the parent component.\n * @default false\n */\n disablePortal: PropTypes.bool,\n /**\n * Always keep the children in the DOM.\n * This prop can be useful in SEO situation or\n * when you want to maximize the responsiveness of the Popper.\n * @default false\n */\n keepMounted: PropTypes.bool,\n /**\n * Popper.js is based on a \"plugin-like\" architecture,\n * most of its features are fully encapsulated \"modifiers\".\n *\n * A modifier is a function that is called each time Popper.js needs to\n * compute the position of the popper.\n * For this reason, modifiers should be very performant to avoid bottlenecks.\n * To learn how to create a modifier, [read the modifiers documentation](https://popper.js.org/docs/v2/modifiers/).\n */\n modifiers: PropTypes.arrayOf(PropTypes.shape({\n data: PropTypes.object,\n effect: PropTypes.func,\n enabled: PropTypes.bool,\n fn: PropTypes.func,\n name: PropTypes.any,\n options: PropTypes.object,\n phase: PropTypes.oneOf(['afterMain', 'afterRead', 'afterWrite', 'beforeMain', 'beforeRead', 'beforeWrite', 'main', 'read', 'write']),\n requires: PropTypes.arrayOf(PropTypes.string),\n requiresIfExists: PropTypes.arrayOf(PropTypes.string)\n })),\n /**\n * If `true`, the component is shown.\n */\n open: PropTypes.bool.isRequired,\n /**\n * Popper placement.\n * @default 'bottom'\n */\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n /**\n * Options provided to the [`Popper.js`](https://popper.js.org/docs/v2/constructors/#options) instance.\n * @default {}\n */\n popperOptions: PropTypes.shape({\n modifiers: PropTypes.array,\n onFirstUpdate: PropTypes.func,\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n strategy: PropTypes.oneOf(['absolute', 'fixed'])\n }),\n /**\n * A ref that points to the used popper instance.\n */\n popperRef: refType,\n /**\n * The props used for each slot inside the Popper.\n * @default {}\n */\n slotProps: PropTypes.shape({\n root: PropTypes.oneOfType([PropTypes.func, PropTypes.object])\n }),\n /**\n * The components used for each slot inside the Popper.\n * Either a string to use a HTML element or a component.\n * @default {}\n */\n slots: PropTypes.shape({\n root: PropTypes.elementType\n }),\n /**\n * Help supporting a react-transition-group/Transition component.\n * @default false\n */\n transition: PropTypes.bool\n} : void 0;\nexport { Popper };","'use client';\n\nimport * as React from 'react';\nimport { useTheme as useThemeSystem } from '@mui/system';\nimport defaultTheme from './defaultTheme';\nimport THEME_ID from './identifier';\nexport default function useTheme() {\n const theme = useThemeSystem(defaultTheme);\n if (process.env.NODE_ENV !== 'production') {\n // eslint-disable-next-line react-hooks/rules-of-hooks\n React.useDebugValue(theme);\n }\n return theme[THEME_ID] || theme;\n}","export default function _setPrototypeOf(o, p) {\n _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function _setPrototypeOf(o, p) {\n o.__proto__ = p;\n return o;\n };\n return _setPrototypeOf(o, p);\n}","import setPrototypeOf from \"./setPrototypeOf.js\";\nexport default function _inheritsLoose(subClass, superClass) {\n subClass.prototype = Object.create(superClass.prototype);\n subClass.prototype.constructor = subClass;\n setPrototypeOf(subClass, superClass);\n}","export default {\n disabled: false\n};","import PropTypes from 'prop-types';\nexport var timeoutsShape = process.env.NODE_ENV !== 'production' ? PropTypes.oneOfType([PropTypes.number, PropTypes.shape({\n enter: PropTypes.number,\n exit: PropTypes.number,\n appear: PropTypes.number\n}).isRequired]) : null;\nexport var classNamesShape = process.env.NODE_ENV !== 'production' ? PropTypes.oneOfType([PropTypes.string, PropTypes.shape({\n enter: PropTypes.string,\n exit: PropTypes.string,\n active: PropTypes.string\n}), PropTypes.shape({\n enter: PropTypes.string,\n enterDone: PropTypes.string,\n enterActive: PropTypes.string,\n exit: PropTypes.string,\n exitDone: PropTypes.string,\n exitActive: PropTypes.string\n})]) : null;","import React from 'react';\nexport default React.createContext(null);","export var forceReflow = function forceReflow(node) {\n return node.scrollTop;\n};","import _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _inheritsLoose from \"@babel/runtime/helpers/esm/inheritsLoose\";\nimport PropTypes from 'prop-types';\nimport React from 'react';\nimport ReactDOM from 'react-dom';\nimport config from './config';\nimport { timeoutsShape } from './utils/PropTypes';\nimport TransitionGroupContext from './TransitionGroupContext';\nimport { forceReflow } from './utils/reflow';\nexport var UNMOUNTED = 'unmounted';\nexport var EXITED = 'exited';\nexport var ENTERING = 'entering';\nexport var ENTERED = 'entered';\nexport var EXITING = 'exiting';\n/**\n * The Transition component lets you describe a transition from one component\n * state to another _over time_ with a simple declarative API. Most commonly\n * it's used to animate the mounting and unmounting of a component, but can also\n * be used to describe in-place transition states as well.\n *\n * ---\n *\n * **Note**: `Transition` is a platform-agnostic base component. If you're using\n * transitions in CSS, you'll probably want to use\n * [`CSSTransition`](https://reactcommunity.org/react-transition-group/css-transition)\n * instead. It inherits all the features of `Transition`, but contains\n * additional features necessary to play nice with CSS transitions (hence the\n * name of the component).\n *\n * ---\n *\n * By default the `Transition` component does not alter the behavior of the\n * component it renders, it only tracks \"enter\" and \"exit\" states for the\n * components. It's up to you to give meaning and effect to those states. For\n * example we can add styles to a component when it enters or exits:\n *\n * ```jsx\n * import { Transition } from 'react-transition-group';\n *\n * const duration = 300;\n *\n * const defaultStyle = {\n * transition: `opacity ${duration}ms ease-in-out`,\n * opacity: 0,\n * }\n *\n * const transitionStyles = {\n * entering: { opacity: 1 },\n * entered: { opacity: 1 },\n * exiting: { opacity: 0 },\n * exited: { opacity: 0 },\n * };\n *\n * const Fade = ({ in: inProp }) => (\n * \n * {state => (\n *
    \n * I'm a fade Transition!\n *
    \n * )}\n *
    \n * );\n * ```\n *\n * There are 4 main states a Transition can be in:\n * - `'entering'`\n * - `'entered'`\n * - `'exiting'`\n * - `'exited'`\n *\n * Transition state is toggled via the `in` prop. When `true` the component\n * begins the \"Enter\" stage. During this stage, the component will shift from\n * its current transition state, to `'entering'` for the duration of the\n * transition and then to the `'entered'` stage once it's complete. Let's take\n * the following example (we'll use the\n * [useState](https://reactjs.org/docs/hooks-reference.html#usestate) hook):\n *\n * ```jsx\n * function App() {\n * const [inProp, setInProp] = useState(false);\n * return (\n *
    \n * \n * {state => (\n * // ...\n * )}\n * \n * \n *
    \n * );\n * }\n * ```\n *\n * When the button is clicked the component will shift to the `'entering'` state\n * and stay there for 500ms (the value of `timeout`) before it finally switches\n * to `'entered'`.\n *\n * When `in` is `false` the same thing happens except the state moves from\n * `'exiting'` to `'exited'`.\n */\n\nvar Transition = /*#__PURE__*/function (_React$Component) {\n _inheritsLoose(Transition, _React$Component);\n\n function Transition(props, context) {\n var _this;\n\n _this = _React$Component.call(this, props, context) || this;\n var parentGroup = context; // In the context of a TransitionGroup all enters are really appears\n\n var appear = parentGroup && !parentGroup.isMounting ? props.enter : props.appear;\n var initialStatus;\n _this.appearStatus = null;\n\n if (props.in) {\n if (appear) {\n initialStatus = EXITED;\n _this.appearStatus = ENTERING;\n } else {\n initialStatus = ENTERED;\n }\n } else {\n if (props.unmountOnExit || props.mountOnEnter) {\n initialStatus = UNMOUNTED;\n } else {\n initialStatus = EXITED;\n }\n }\n\n _this.state = {\n status: initialStatus\n };\n _this.nextCallback = null;\n return _this;\n }\n\n Transition.getDerivedStateFromProps = function getDerivedStateFromProps(_ref, prevState) {\n var nextIn = _ref.in;\n\n if (nextIn && prevState.status === UNMOUNTED) {\n return {\n status: EXITED\n };\n }\n\n return null;\n } // getSnapshotBeforeUpdate(prevProps) {\n // let nextStatus = null\n // if (prevProps !== this.props) {\n // const { status } = this.state\n // if (this.props.in) {\n // if (status !== ENTERING && status !== ENTERED) {\n // nextStatus = ENTERING\n // }\n // } else {\n // if (status === ENTERING || status === ENTERED) {\n // nextStatus = EXITING\n // }\n // }\n // }\n // return { nextStatus }\n // }\n ;\n\n var _proto = Transition.prototype;\n\n _proto.componentDidMount = function componentDidMount() {\n this.updateStatus(true, this.appearStatus);\n };\n\n _proto.componentDidUpdate = function componentDidUpdate(prevProps) {\n var nextStatus = null;\n\n if (prevProps !== this.props) {\n var status = this.state.status;\n\n if (this.props.in) {\n if (status !== ENTERING && status !== ENTERED) {\n nextStatus = ENTERING;\n }\n } else {\n if (status === ENTERING || status === ENTERED) {\n nextStatus = EXITING;\n }\n }\n }\n\n this.updateStatus(false, nextStatus);\n };\n\n _proto.componentWillUnmount = function componentWillUnmount() {\n this.cancelNextCallback();\n };\n\n _proto.getTimeouts = function getTimeouts() {\n var timeout = this.props.timeout;\n var exit, enter, appear;\n exit = enter = appear = timeout;\n\n if (timeout != null && typeof timeout !== 'number') {\n exit = timeout.exit;\n enter = timeout.enter; // TODO: remove fallback for next major\n\n appear = timeout.appear !== undefined ? timeout.appear : enter;\n }\n\n return {\n exit: exit,\n enter: enter,\n appear: appear\n };\n };\n\n _proto.updateStatus = function updateStatus(mounting, nextStatus) {\n if (mounting === void 0) {\n mounting = false;\n }\n\n if (nextStatus !== null) {\n // nextStatus will always be ENTERING or EXITING.\n this.cancelNextCallback();\n\n if (nextStatus === ENTERING) {\n if (this.props.unmountOnExit || this.props.mountOnEnter) {\n var node = this.props.nodeRef ? this.props.nodeRef.current : ReactDOM.findDOMNode(this); // https://github.com/reactjs/react-transition-group/pull/749\n // With unmountOnExit or mountOnEnter, the enter animation should happen at the transition between `exited` and `entering`.\n // To make the animation happen, we have to separate each rendering and avoid being processed as batched.\n\n if (node) forceReflow(node);\n }\n\n this.performEnter(mounting);\n } else {\n this.performExit();\n }\n } else if (this.props.unmountOnExit && this.state.status === EXITED) {\n this.setState({\n status: UNMOUNTED\n });\n }\n };\n\n _proto.performEnter = function performEnter(mounting) {\n var _this2 = this;\n\n var enter = this.props.enter;\n var appearing = this.context ? this.context.isMounting : mounting;\n\n var _ref2 = this.props.nodeRef ? [appearing] : [ReactDOM.findDOMNode(this), appearing],\n maybeNode = _ref2[0],\n maybeAppearing = _ref2[1];\n\n var timeouts = this.getTimeouts();\n var enterTimeout = appearing ? timeouts.appear : timeouts.enter; // no enter animation skip right to ENTERED\n // if we are mounting and running this it means appear _must_ be set\n\n if (!mounting && !enter || config.disabled) {\n this.safeSetState({\n status: ENTERED\n }, function () {\n _this2.props.onEntered(maybeNode);\n });\n return;\n }\n\n this.props.onEnter(maybeNode, maybeAppearing);\n this.safeSetState({\n status: ENTERING\n }, function () {\n _this2.props.onEntering(maybeNode, maybeAppearing);\n\n _this2.onTransitionEnd(enterTimeout, function () {\n _this2.safeSetState({\n status: ENTERED\n }, function () {\n _this2.props.onEntered(maybeNode, maybeAppearing);\n });\n });\n });\n };\n\n _proto.performExit = function performExit() {\n var _this3 = this;\n\n var exit = this.props.exit;\n var timeouts = this.getTimeouts();\n var maybeNode = this.props.nodeRef ? undefined : ReactDOM.findDOMNode(this); // no exit animation skip right to EXITED\n\n if (!exit || config.disabled) {\n this.safeSetState({\n status: EXITED\n }, function () {\n _this3.props.onExited(maybeNode);\n });\n return;\n }\n\n this.props.onExit(maybeNode);\n this.safeSetState({\n status: EXITING\n }, function () {\n _this3.props.onExiting(maybeNode);\n\n _this3.onTransitionEnd(timeouts.exit, function () {\n _this3.safeSetState({\n status: EXITED\n }, function () {\n _this3.props.onExited(maybeNode);\n });\n });\n });\n };\n\n _proto.cancelNextCallback = function cancelNextCallback() {\n if (this.nextCallback !== null) {\n this.nextCallback.cancel();\n this.nextCallback = null;\n }\n };\n\n _proto.safeSetState = function safeSetState(nextState, callback) {\n // This shouldn't be necessary, but there are weird race conditions with\n // setState callbacks and unmounting in testing, so always make sure that\n // we can cancel any pending setState callbacks after we unmount.\n callback = this.setNextCallback(callback);\n this.setState(nextState, callback);\n };\n\n _proto.setNextCallback = function setNextCallback(callback) {\n var _this4 = this;\n\n var active = true;\n\n this.nextCallback = function (event) {\n if (active) {\n active = false;\n _this4.nextCallback = null;\n callback(event);\n }\n };\n\n this.nextCallback.cancel = function () {\n active = false;\n };\n\n return this.nextCallback;\n };\n\n _proto.onTransitionEnd = function onTransitionEnd(timeout, handler) {\n this.setNextCallback(handler);\n var node = this.props.nodeRef ? this.props.nodeRef.current : ReactDOM.findDOMNode(this);\n var doesNotHaveTimeoutOrListener = timeout == null && !this.props.addEndListener;\n\n if (!node || doesNotHaveTimeoutOrListener) {\n setTimeout(this.nextCallback, 0);\n return;\n }\n\n if (this.props.addEndListener) {\n var _ref3 = this.props.nodeRef ? [this.nextCallback] : [node, this.nextCallback],\n maybeNode = _ref3[0],\n maybeNextCallback = _ref3[1];\n\n this.props.addEndListener(maybeNode, maybeNextCallback);\n }\n\n if (timeout != null) {\n setTimeout(this.nextCallback, timeout);\n }\n };\n\n _proto.render = function render() {\n var status = this.state.status;\n\n if (status === UNMOUNTED) {\n return null;\n }\n\n var _this$props = this.props,\n children = _this$props.children,\n _in = _this$props.in,\n _mountOnEnter = _this$props.mountOnEnter,\n _unmountOnExit = _this$props.unmountOnExit,\n _appear = _this$props.appear,\n _enter = _this$props.enter,\n _exit = _this$props.exit,\n _timeout = _this$props.timeout,\n _addEndListener = _this$props.addEndListener,\n _onEnter = _this$props.onEnter,\n _onEntering = _this$props.onEntering,\n _onEntered = _this$props.onEntered,\n _onExit = _this$props.onExit,\n _onExiting = _this$props.onExiting,\n _onExited = _this$props.onExited,\n _nodeRef = _this$props.nodeRef,\n childProps = _objectWithoutPropertiesLoose(_this$props, [\"children\", \"in\", \"mountOnEnter\", \"unmountOnExit\", \"appear\", \"enter\", \"exit\", \"timeout\", \"addEndListener\", \"onEnter\", \"onEntering\", \"onEntered\", \"onExit\", \"onExiting\", \"onExited\", \"nodeRef\"]);\n\n return (\n /*#__PURE__*/\n // allows for nested Transitions\n React.createElement(TransitionGroupContext.Provider, {\n value: null\n }, typeof children === 'function' ? children(status, childProps) : React.cloneElement(React.Children.only(children), childProps))\n );\n };\n\n return Transition;\n}(React.Component);\n\nTransition.contextType = TransitionGroupContext;\nTransition.propTypes = process.env.NODE_ENV !== \"production\" ? {\n /**\n * A React reference to DOM element that need to transition:\n * https://stackoverflow.com/a/51127130/4671932\n *\n * - When `nodeRef` prop is used, `node` is not passed to callback functions\n * (e.g. `onEnter`) because user already has direct access to the node.\n * - When changing `key` prop of `Transition` in a `TransitionGroup` a new\n * `nodeRef` need to be provided to `Transition` with changed `key` prop\n * (see\n * [test/CSSTransition-test.js](https://github.com/reactjs/react-transition-group/blob/13435f897b3ab71f6e19d724f145596f5910581c/test/CSSTransition-test.js#L362-L437)).\n */\n nodeRef: PropTypes.shape({\n current: typeof Element === 'undefined' ? PropTypes.any : function (propValue, key, componentName, location, propFullName, secret) {\n var value = propValue[key];\n return PropTypes.instanceOf(value && 'ownerDocument' in value ? value.ownerDocument.defaultView.Element : Element)(propValue, key, componentName, location, propFullName, secret);\n }\n }),\n\n /**\n * A `function` child can be used instead of a React element. This function is\n * called with the current transition status (`'entering'`, `'entered'`,\n * `'exiting'`, `'exited'`), which can be used to apply context\n * specific props to a component.\n *\n * ```jsx\n * \n * {state => (\n * \n * )}\n * \n * ```\n */\n children: PropTypes.oneOfType([PropTypes.func.isRequired, PropTypes.element.isRequired]).isRequired,\n\n /**\n * Show the component; triggers the enter or exit states\n */\n in: PropTypes.bool,\n\n /**\n * By default the child component is mounted immediately along with\n * the parent `Transition` component. If you want to \"lazy mount\" the component on the\n * first `in={true}` you can set `mountOnEnter`. After the first enter transition the component will stay\n * mounted, even on \"exited\", unless you also specify `unmountOnExit`.\n */\n mountOnEnter: PropTypes.bool,\n\n /**\n * By default the child component stays mounted after it reaches the `'exited'` state.\n * Set `unmountOnExit` if you'd prefer to unmount the component after it finishes exiting.\n */\n unmountOnExit: PropTypes.bool,\n\n /**\n * By default the child component does not perform the enter transition when\n * it first mounts, regardless of the value of `in`. If you want this\n * behavior, set both `appear` and `in` to `true`.\n *\n * > **Note**: there are no special appear states like `appearing`/`appeared`, this prop\n * > only adds an additional enter transition. However, in the\n * > `` component that first enter transition does result in\n * > additional `.appear-*` classes, that way you can choose to style it\n * > differently.\n */\n appear: PropTypes.bool,\n\n /**\n * Enable or disable enter transitions.\n */\n enter: PropTypes.bool,\n\n /**\n * Enable or disable exit transitions.\n */\n exit: PropTypes.bool,\n\n /**\n * The duration of the transition, in milliseconds.\n * Required unless `addEndListener` is provided.\n *\n * You may specify a single timeout for all transitions:\n *\n * ```jsx\n * timeout={500}\n * ```\n *\n * or individually:\n *\n * ```jsx\n * timeout={{\n * appear: 500,\n * enter: 300,\n * exit: 500,\n * }}\n * ```\n *\n * - `appear` defaults to the value of `enter`\n * - `enter` defaults to `0`\n * - `exit` defaults to `0`\n *\n * @type {number | { enter?: number, exit?: number, appear?: number }}\n */\n timeout: function timeout(props) {\n var pt = timeoutsShape;\n if (!props.addEndListener) pt = pt.isRequired;\n\n for (var _len = arguments.length, args = new Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) {\n args[_key - 1] = arguments[_key];\n }\n\n return pt.apply(void 0, [props].concat(args));\n },\n\n /**\n * Add a custom transition end trigger. Called with the transitioning\n * DOM node and a `done` callback. Allows for more fine grained transition end\n * logic. Timeouts are still used as a fallback if provided.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * ```jsx\n * addEndListener={(node, done) => {\n * // use the css transitionend event to mark the finish of a transition\n * node.addEventListener('transitionend', done, false);\n * }}\n * ```\n */\n addEndListener: PropTypes.func,\n\n /**\n * Callback fired before the \"entering\" status is applied. An extra parameter\n * `isAppearing` is supplied to indicate if the enter stage is occurring on the initial mount\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement, isAppearing: bool) -> void\n */\n onEnter: PropTypes.func,\n\n /**\n * Callback fired after the \"entering\" status is applied. An extra parameter\n * `isAppearing` is supplied to indicate if the enter stage is occurring on the initial mount\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement, isAppearing: bool)\n */\n onEntering: PropTypes.func,\n\n /**\n * Callback fired after the \"entered\" status is applied. An extra parameter\n * `isAppearing` is supplied to indicate if the enter stage is occurring on the initial mount\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement, isAppearing: bool) -> void\n */\n onEntered: PropTypes.func,\n\n /**\n * Callback fired before the \"exiting\" status is applied.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement) -> void\n */\n onExit: PropTypes.func,\n\n /**\n * Callback fired after the \"exiting\" status is applied.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement) -> void\n */\n onExiting: PropTypes.func,\n\n /**\n * Callback fired after the \"exited\" status is applied.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed\n *\n * @type Function(node: HtmlElement) -> void\n */\n onExited: PropTypes.func\n} : {}; // Name the function so it is clearer in the documentation\n\nfunction noop() {}\n\nTransition.defaultProps = {\n in: false,\n mountOnEnter: false,\n unmountOnExit: false,\n appear: false,\n enter: true,\n exit: true,\n onEnter: noop,\n onEntering: noop,\n onEntered: noop,\n onExit: noop,\n onExiting: noop,\n onExited: noop\n};\nTransition.UNMOUNTED = UNMOUNTED;\nTransition.EXITED = EXITED;\nTransition.ENTERING = ENTERING;\nTransition.ENTERED = ENTERED;\nTransition.EXITING = EXITING;\nexport default Transition;","export const reflow = node => node.scrollTop;\nexport function getTransitionProps(props, options) {\n var _style$transitionDura, _style$transitionTimi;\n const {\n timeout,\n easing,\n style = {}\n } = props;\n return {\n duration: (_style$transitionDura = style.transitionDuration) != null ? _style$transitionDura : typeof timeout === 'number' ? timeout : timeout[options.mode] || 0,\n easing: (_style$transitionTimi = style.transitionTimingFunction) != null ? _style$transitionTimi : typeof easing === 'object' ? easing[options.mode] : easing,\n delay: style.transitionDelay\n };\n}","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"addEndListener\", \"appear\", \"children\", \"easing\", \"in\", \"onEnter\", \"onEntered\", \"onEntering\", \"onExit\", \"onExited\", \"onExiting\", \"style\", \"timeout\", \"TransitionComponent\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport { elementAcceptingRef, unstable_useTimeout as useTimeout } from '@mui/utils';\nimport { Transition } from 'react-transition-group';\nimport useTheme from '../styles/useTheme';\nimport { getTransitionProps, reflow } from '../transitions/utils';\nimport useForkRef from '../utils/useForkRef';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nfunction getScale(value) {\n return `scale(${value}, ${value ** 2})`;\n}\nconst styles = {\n entering: {\n opacity: 1,\n transform: getScale(1)\n },\n entered: {\n opacity: 1,\n transform: 'none'\n }\n};\n\n/*\n TODO v6: remove\n Conditionally apply a workaround for the CSS transition bug in Safari 15.4 / WebKit browsers.\n */\nconst isWebKit154 = typeof navigator !== 'undefined' && /^((?!chrome|android).)*(safari|mobile)/i.test(navigator.userAgent) && /(os |version\\/)15(.|_)4/i.test(navigator.userAgent);\n\n/**\n * The Grow transition is used by the [Tooltip](/material-ui/react-tooltip/) and\n * [Popover](/material-ui/react-popover/) components.\n * It uses [react-transition-group](https://github.com/reactjs/react-transition-group) internally.\n */\nconst Grow = /*#__PURE__*/React.forwardRef(function Grow(props, ref) {\n const {\n addEndListener,\n appear = true,\n children,\n easing,\n in: inProp,\n onEnter,\n onEntered,\n onEntering,\n onExit,\n onExited,\n onExiting,\n style,\n timeout = 'auto',\n // eslint-disable-next-line react/prop-types\n TransitionComponent = Transition\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const timer = useTimeout();\n const autoTimeout = React.useRef();\n const theme = useTheme();\n const nodeRef = React.useRef(null);\n const handleRef = useForkRef(nodeRef, children.ref, ref);\n const normalizedTransitionCallback = callback => maybeIsAppearing => {\n if (callback) {\n const node = nodeRef.current;\n\n // onEnterXxx and onExitXxx callbacks have a different arguments.length value.\n if (maybeIsAppearing === undefined) {\n callback(node);\n } else {\n callback(node, maybeIsAppearing);\n }\n }\n };\n const handleEntering = normalizedTransitionCallback(onEntering);\n const handleEnter = normalizedTransitionCallback((node, isAppearing) => {\n reflow(node); // So the animation always start from the start.\n\n const {\n duration: transitionDuration,\n delay,\n easing: transitionTimingFunction\n } = getTransitionProps({\n style,\n timeout,\n easing\n }, {\n mode: 'enter'\n });\n let duration;\n if (timeout === 'auto') {\n duration = theme.transitions.getAutoHeightDuration(node.clientHeight);\n autoTimeout.current = duration;\n } else {\n duration = transitionDuration;\n }\n node.style.transition = [theme.transitions.create('opacity', {\n duration,\n delay\n }), theme.transitions.create('transform', {\n duration: isWebKit154 ? duration : duration * 0.666,\n delay,\n easing: transitionTimingFunction\n })].join(',');\n if (onEnter) {\n onEnter(node, isAppearing);\n }\n });\n const handleEntered = normalizedTransitionCallback(onEntered);\n const handleExiting = normalizedTransitionCallback(onExiting);\n const handleExit = normalizedTransitionCallback(node => {\n const {\n duration: transitionDuration,\n delay,\n easing: transitionTimingFunction\n } = getTransitionProps({\n style,\n timeout,\n easing\n }, {\n mode: 'exit'\n });\n let duration;\n if (timeout === 'auto') {\n duration = theme.transitions.getAutoHeightDuration(node.clientHeight);\n autoTimeout.current = duration;\n } else {\n duration = transitionDuration;\n }\n node.style.transition = [theme.transitions.create('opacity', {\n duration,\n delay\n }), theme.transitions.create('transform', {\n duration: isWebKit154 ? duration : duration * 0.666,\n delay: isWebKit154 ? delay : delay || duration * 0.333,\n easing: transitionTimingFunction\n })].join(',');\n node.style.opacity = 0;\n node.style.transform = getScale(0.75);\n if (onExit) {\n onExit(node);\n }\n });\n const handleExited = normalizedTransitionCallback(onExited);\n const handleAddEndListener = next => {\n if (timeout === 'auto') {\n timer.start(autoTimeout.current || 0, next);\n }\n if (addEndListener) {\n // Old call signature before `react-transition-group` implemented `nodeRef`\n addEndListener(nodeRef.current, next);\n }\n };\n return /*#__PURE__*/_jsx(TransitionComponent, _extends({\n appear: appear,\n in: inProp,\n nodeRef: nodeRef,\n onEnter: handleEnter,\n onEntered: handleEntered,\n onEntering: handleEntering,\n onExit: handleExit,\n onExited: handleExited,\n onExiting: handleExiting,\n addEndListener: handleAddEndListener,\n timeout: timeout === 'auto' ? null : timeout\n }, other, {\n children: (state, childProps) => {\n return /*#__PURE__*/React.cloneElement(children, _extends({\n style: _extends({\n opacity: 0,\n transform: getScale(0.75),\n visibility: state === 'exited' && !inProp ? 'hidden' : undefined\n }, styles[state], style, children.props.style),\n ref: handleRef\n }, childProps));\n }\n }));\n});\nprocess.env.NODE_ENV !== \"production\" ? Grow.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the d.ts file and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * Add a custom transition end trigger. Called with the transitioning DOM\n * node and a done callback. Allows for more fine grained transition end\n * logic. Note: Timeouts are still used as a fallback if provided.\n */\n addEndListener: PropTypes.func,\n /**\n * Perform the enter transition when it first mounts if `in` is also `true`.\n * Set this to `false` to disable this behavior.\n * @default true\n */\n appear: PropTypes.bool,\n /**\n * A single child content element.\n */\n children: elementAcceptingRef.isRequired,\n /**\n * The transition timing function.\n * You may specify a single easing or a object containing enter and exit values.\n */\n easing: PropTypes.oneOfType([PropTypes.shape({\n enter: PropTypes.string,\n exit: PropTypes.string\n }), PropTypes.string]),\n /**\n * If `true`, the component will transition in.\n */\n in: PropTypes.bool,\n /**\n * @ignore\n */\n onEnter: PropTypes.func,\n /**\n * @ignore\n */\n onEntered: PropTypes.func,\n /**\n * @ignore\n */\n onEntering: PropTypes.func,\n /**\n * @ignore\n */\n onExit: PropTypes.func,\n /**\n * @ignore\n */\n onExited: PropTypes.func,\n /**\n * @ignore\n */\n onExiting: PropTypes.func,\n /**\n * @ignore\n */\n style: PropTypes.object,\n /**\n * The duration for the transition, in milliseconds.\n * You may specify a single timeout for all transitions, or individually with an object.\n *\n * Set to 'auto' to automatically calculate transition time based on height.\n * @default 'auto'\n */\n timeout: PropTypes.oneOfType([PropTypes.oneOf(['auto']), PropTypes.number, PropTypes.shape({\n appear: PropTypes.number,\n enter: PropTypes.number,\n exit: PropTypes.number\n })])\n} : void 0;\nGrow.muiSupportAuto = true;\nexport default Grow;","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"anchorEl\", \"component\", \"components\", \"componentsProps\", \"container\", \"disablePortal\", \"keepMounted\", \"modifiers\", \"open\", \"placement\", \"popperOptions\", \"popperRef\", \"transition\", \"slots\", \"slotProps\"];\nimport { Popper as BasePopper } from '@mui/base/Popper';\nimport { useThemeWithoutDefault as useTheme } from '@mui/system';\nimport { HTMLElementType, refType } from '@mui/utils';\nimport PropTypes from 'prop-types';\nimport * as React from 'react';\nimport { styled, useThemeProps } from '../styles';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nconst PopperRoot = styled(BasePopper, {\n name: 'MuiPopper',\n slot: 'Root',\n overridesResolver: (props, styles) => styles.root\n})({});\n\n/**\n *\n * Demos:\n *\n * - [Autocomplete](https://mui.com/material-ui/react-autocomplete/)\n * - [Menu](https://mui.com/material-ui/react-menu/)\n * - [Popper](https://mui.com/material-ui/react-popper/)\n *\n * API:\n *\n * - [Popper API](https://mui.com/material-ui/api/popper/)\n */\nconst Popper = /*#__PURE__*/React.forwardRef(function Popper(inProps, ref) {\n var _slots$root;\n const theme = useTheme();\n const props = useThemeProps({\n props: inProps,\n name: 'MuiPopper'\n });\n const {\n anchorEl,\n component,\n components,\n componentsProps,\n container,\n disablePortal,\n keepMounted,\n modifiers,\n open,\n placement,\n popperOptions,\n popperRef,\n transition,\n slots,\n slotProps\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const RootComponent = (_slots$root = slots == null ? void 0 : slots.root) != null ? _slots$root : components == null ? void 0 : components.Root;\n const otherProps = _extends({\n anchorEl,\n container,\n disablePortal,\n keepMounted,\n modifiers,\n open,\n placement,\n popperOptions,\n popperRef,\n transition\n }, other);\n return /*#__PURE__*/_jsx(PopperRoot, _extends({\n as: component,\n direction: theme == null ? void 0 : theme.direction,\n slots: {\n root: RootComponent\n },\n slotProps: slotProps != null ? slotProps : componentsProps\n }, otherProps, {\n ref: ref\n }));\n});\nprocess.env.NODE_ENV !== \"production\" ? Popper.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * An HTML element, [virtualElement](https://popper.js.org/docs/v2/virtual-elements/),\n * or a function that returns either.\n * It's used to set the position of the popper.\n * The return value will passed as the reference object of the Popper instance.\n */\n anchorEl: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.object, PropTypes.func]),\n /**\n * Popper render function or node.\n */\n children: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.node, PropTypes.func]),\n /**\n * The component used for the root node.\n * Either a string to use a HTML element or a component.\n */\n component: PropTypes.elementType,\n /**\n * The components used for each slot inside the Popper.\n * Either a string to use a HTML element or a component.\n * @default {}\n */\n components: PropTypes.shape({\n Root: PropTypes.elementType\n }),\n /**\n * The props used for each slot inside the Popper.\n * @default {}\n */\n componentsProps: PropTypes.shape({\n root: PropTypes.oneOfType([PropTypes.func, PropTypes.object])\n }),\n /**\n * An HTML element or function that returns one.\n * The `container` will have the portal children appended to it.\n *\n * You can also provide a callback, which is called in a React layout effect.\n * This lets you set the container from a ref, and also makes server-side rendering possible.\n *\n * By default, it uses the body of the top-level document object,\n * so it's simply `document.body` most of the time.\n */\n container: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.func]),\n /**\n * The `children` will be under the DOM hierarchy of the parent component.\n * @default false\n */\n disablePortal: PropTypes.bool,\n /**\n * Always keep the children in the DOM.\n * This prop can be useful in SEO situation or\n * when you want to maximize the responsiveness of the Popper.\n * @default false\n */\n keepMounted: PropTypes.bool,\n /**\n * Popper.js is based on a \"plugin-like\" architecture,\n * most of its features are fully encapsulated \"modifiers\".\n *\n * A modifier is a function that is called each time Popper.js needs to\n * compute the position of the popper.\n * For this reason, modifiers should be very performant to avoid bottlenecks.\n * To learn how to create a modifier, [read the modifiers documentation](https://popper.js.org/docs/v2/modifiers/).\n */\n modifiers: PropTypes.arrayOf(PropTypes.shape({\n data: PropTypes.object,\n effect: PropTypes.func,\n enabled: PropTypes.bool,\n fn: PropTypes.func,\n name: PropTypes.any,\n options: PropTypes.object,\n phase: PropTypes.oneOf(['afterMain', 'afterRead', 'afterWrite', 'beforeMain', 'beforeRead', 'beforeWrite', 'main', 'read', 'write']),\n requires: PropTypes.arrayOf(PropTypes.string),\n requiresIfExists: PropTypes.arrayOf(PropTypes.string)\n })),\n /**\n * If `true`, the component is shown.\n */\n open: PropTypes.bool.isRequired,\n /**\n * Popper placement.\n * @default 'bottom'\n */\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n /**\n * Options provided to the [`Popper.js`](https://popper.js.org/docs/v2/constructors/#options) instance.\n * @default {}\n */\n popperOptions: PropTypes.shape({\n modifiers: PropTypes.array,\n onFirstUpdate: PropTypes.func,\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n strategy: PropTypes.oneOf(['absolute', 'fixed'])\n }),\n /**\n * A ref that points to the used popper instance.\n */\n popperRef: refType,\n /**\n * The props used for each slot inside the Popper.\n * @default {}\n */\n slotProps: PropTypes.shape({\n root: PropTypes.oneOfType([PropTypes.func, PropTypes.object])\n }),\n /**\n * The components used for each slot inside the Popper.\n * Either a string to use a HTML element or a component.\n * @default {}\n */\n slots: PropTypes.shape({\n root: PropTypes.elementType\n }),\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Help supporting a react-transition-group/Transition component.\n * @default false\n */\n transition: PropTypes.bool\n} : void 0;\nexport default Popper;","import generateUtilityClasses from '@mui/utils/generateUtilityClasses';\nimport generateUtilityClass from '@mui/utils/generateUtilityClass';\nexport function getTooltipUtilityClass(slot) {\n return generateUtilityClass('MuiTooltip', slot);\n}\nconst tooltipClasses = generateUtilityClasses('MuiTooltip', ['popper', 'popperInteractive', 'popperArrow', 'popperClose', 'tooltip', 'tooltipArrow', 'touch', 'tooltipPlacementLeft', 'tooltipPlacementRight', 'tooltipPlacementTop', 'tooltipPlacementBottom', 'arrow']);\nexport default tooltipClasses;","'use client';\n\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nconst _excluded = [\"arrow\", \"children\", \"classes\", \"components\", \"componentsProps\", \"describeChild\", \"disableFocusListener\", \"disableHoverListener\", \"disableInteractive\", \"disableTouchListener\", \"enterDelay\", \"enterNextDelay\", \"enterTouchDelay\", \"followCursor\", \"id\", \"leaveDelay\", \"leaveTouchDelay\", \"onClose\", \"onOpen\", \"open\", \"placement\", \"PopperComponent\", \"PopperProps\", \"slotProps\", \"slots\", \"title\", \"TransitionComponent\", \"TransitionProps\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport clsx from 'clsx';\nimport { elementAcceptingRef, unstable_useTimeout as useTimeout, unstable_Timeout as Timeout } from '@mui/utils';\nimport { unstable_composeClasses as composeClasses, appendOwnerState } from '@mui/base';\nimport { alpha } from '@mui/system';\nimport styled from '../styles/styled';\nimport useTheme from '../styles/useTheme';\nimport useThemeProps from '../styles/useThemeProps';\nimport capitalize from '../utils/capitalize';\nimport Grow from '../Grow';\nimport Popper from '../Popper';\nimport useEventCallback from '../utils/useEventCallback';\nimport useForkRef from '../utils/useForkRef';\nimport useId from '../utils/useId';\nimport useIsFocusVisible from '../utils/useIsFocusVisible';\nimport useControlled from '../utils/useControlled';\nimport tooltipClasses, { getTooltipUtilityClass } from './tooltipClasses';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nimport { jsxs as _jsxs } from \"react/jsx-runtime\";\nfunction round(value) {\n return Math.round(value * 1e5) / 1e5;\n}\nconst useUtilityClasses = ownerState => {\n const {\n classes,\n disableInteractive,\n arrow,\n touch,\n placement\n } = ownerState;\n const slots = {\n popper: ['popper', !disableInteractive && 'popperInteractive', arrow && 'popperArrow'],\n tooltip: ['tooltip', arrow && 'tooltipArrow', touch && 'touch', `tooltipPlacement${capitalize(placement.split('-')[0])}`],\n arrow: ['arrow']\n };\n return composeClasses(slots, getTooltipUtilityClass, classes);\n};\nconst TooltipPopper = styled(Popper, {\n name: 'MuiTooltip',\n slot: 'Popper',\n overridesResolver: (props, styles) => {\n const {\n ownerState\n } = props;\n return [styles.popper, !ownerState.disableInteractive && styles.popperInteractive, ownerState.arrow && styles.popperArrow, !ownerState.open && styles.popperClose];\n }\n})(({\n theme,\n ownerState,\n open\n}) => _extends({\n zIndex: (theme.vars || theme).zIndex.tooltip,\n pointerEvents: 'none'\n}, !ownerState.disableInteractive && {\n pointerEvents: 'auto'\n}, !open && {\n pointerEvents: 'none'\n}, ownerState.arrow && {\n [`&[data-popper-placement*=\"bottom\"] .${tooltipClasses.arrow}`]: {\n top: 0,\n marginTop: '-0.71em',\n '&::before': {\n transformOrigin: '0 100%'\n }\n },\n [`&[data-popper-placement*=\"top\"] .${tooltipClasses.arrow}`]: {\n bottom: 0,\n marginBottom: '-0.71em',\n '&::before': {\n transformOrigin: '100% 0'\n }\n },\n [`&[data-popper-placement*=\"right\"] .${tooltipClasses.arrow}`]: _extends({}, !ownerState.isRtl ? {\n left: 0,\n marginLeft: '-0.71em'\n } : {\n right: 0,\n marginRight: '-0.71em'\n }, {\n height: '1em',\n width: '0.71em',\n '&::before': {\n transformOrigin: '100% 100%'\n }\n }),\n [`&[data-popper-placement*=\"left\"] .${tooltipClasses.arrow}`]: _extends({}, !ownerState.isRtl ? {\n right: 0,\n marginRight: '-0.71em'\n } : {\n left: 0,\n marginLeft: '-0.71em'\n }, {\n height: '1em',\n width: '0.71em',\n '&::before': {\n transformOrigin: '0 0'\n }\n })\n}));\nconst TooltipTooltip = styled('div', {\n name: 'MuiTooltip',\n slot: 'Tooltip',\n overridesResolver: (props, styles) => {\n const {\n ownerState\n } = props;\n return [styles.tooltip, ownerState.touch && styles.touch, ownerState.arrow && styles.tooltipArrow, styles[`tooltipPlacement${capitalize(ownerState.placement.split('-')[0])}`]];\n }\n})(({\n theme,\n ownerState\n}) => _extends({\n backgroundColor: theme.vars ? theme.vars.palette.Tooltip.bg : alpha(theme.palette.grey[700], 0.92),\n borderRadius: (theme.vars || theme).shape.borderRadius,\n color: (theme.vars || theme).palette.common.white,\n fontFamily: theme.typography.fontFamily,\n padding: '4px 8px',\n fontSize: theme.typography.pxToRem(11),\n maxWidth: 300,\n margin: 2,\n wordWrap: 'break-word',\n fontWeight: theme.typography.fontWeightMedium\n}, ownerState.arrow && {\n position: 'relative',\n margin: 0\n}, ownerState.touch && {\n padding: '8px 16px',\n fontSize: theme.typography.pxToRem(14),\n lineHeight: `${round(16 / 14)}em`,\n fontWeight: theme.typography.fontWeightRegular\n}, {\n [`.${tooltipClasses.popper}[data-popper-placement*=\"left\"] &`]: _extends({\n transformOrigin: 'right center'\n }, !ownerState.isRtl ? _extends({\n marginRight: '14px'\n }, ownerState.touch && {\n marginRight: '24px'\n }) : _extends({\n marginLeft: '14px'\n }, ownerState.touch && {\n marginLeft: '24px'\n })),\n [`.${tooltipClasses.popper}[data-popper-placement*=\"right\"] &`]: _extends({\n transformOrigin: 'left center'\n }, !ownerState.isRtl ? _extends({\n marginLeft: '14px'\n }, ownerState.touch && {\n marginLeft: '24px'\n }) : _extends({\n marginRight: '14px'\n }, ownerState.touch && {\n marginRight: '24px'\n })),\n [`.${tooltipClasses.popper}[data-popper-placement*=\"top\"] &`]: _extends({\n transformOrigin: 'center bottom',\n marginBottom: '14px'\n }, ownerState.touch && {\n marginBottom: '24px'\n }),\n [`.${tooltipClasses.popper}[data-popper-placement*=\"bottom\"] &`]: _extends({\n transformOrigin: 'center top',\n marginTop: '14px'\n }, ownerState.touch && {\n marginTop: '24px'\n })\n}));\nconst TooltipArrow = styled('span', {\n name: 'MuiTooltip',\n slot: 'Arrow',\n overridesResolver: (props, styles) => styles.arrow\n})(({\n theme\n}) => ({\n overflow: 'hidden',\n position: 'absolute',\n width: '1em',\n height: '0.71em' /* = width / sqrt(2) = (length of the hypotenuse) */,\n boxSizing: 'border-box',\n color: theme.vars ? theme.vars.palette.Tooltip.bg : alpha(theme.palette.grey[700], 0.9),\n '&::before': {\n content: '\"\"',\n margin: 'auto',\n display: 'block',\n width: '100%',\n height: '100%',\n backgroundColor: 'currentColor',\n transform: 'rotate(45deg)'\n }\n}));\nlet hystersisOpen = false;\nconst hystersisTimer = new Timeout();\nlet cursorPosition = {\n x: 0,\n y: 0\n};\nexport function testReset() {\n hystersisOpen = false;\n hystersisTimer.clear();\n}\nfunction composeEventHandler(handler, eventHandler) {\n return event => {\n if (eventHandler) {\n eventHandler(event);\n }\n handler(event);\n };\n}\n\n// TODO v6: Remove PopperComponent, PopperProps, TransitionComponent and TransitionProps.\nconst Tooltip = /*#__PURE__*/React.forwardRef(function Tooltip(inProps, ref) {\n var _ref, _slots$popper, _ref2, _ref3, _slots$transition, _ref4, _slots$tooltip, _ref5, _slots$arrow, _slotProps$popper, _ref6, _slotProps$popper2, _slotProps$transition, _slotProps$tooltip, _ref7, _slotProps$tooltip2, _slotProps$arrow, _ref8, _slotProps$arrow2;\n const props = useThemeProps({\n props: inProps,\n name: 'MuiTooltip'\n });\n const {\n arrow = false,\n children: childrenProp,\n components = {},\n componentsProps = {},\n describeChild = false,\n disableFocusListener = false,\n disableHoverListener = false,\n disableInteractive: disableInteractiveProp = false,\n disableTouchListener = false,\n enterDelay = 100,\n enterNextDelay = 0,\n enterTouchDelay = 700,\n followCursor = false,\n id: idProp,\n leaveDelay = 0,\n leaveTouchDelay = 1500,\n onClose,\n onOpen,\n open: openProp,\n placement = 'bottom',\n PopperComponent: PopperComponentProp,\n PopperProps = {},\n slotProps = {},\n slots = {},\n title,\n TransitionComponent: TransitionComponentProp = Grow,\n TransitionProps\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n\n // to prevent runtime errors, developers will need to provide a child as a React element anyway.\n const children = /*#__PURE__*/React.isValidElement(childrenProp) ? childrenProp : /*#__PURE__*/_jsx(\"span\", {\n children: childrenProp\n });\n const theme = useTheme();\n const isRtl = theme.direction === 'rtl';\n const [childNode, setChildNode] = React.useState();\n const [arrowRef, setArrowRef] = React.useState(null);\n const ignoreNonTouchEvents = React.useRef(false);\n const disableInteractive = disableInteractiveProp || followCursor;\n const closeTimer = useTimeout();\n const enterTimer = useTimeout();\n const leaveTimer = useTimeout();\n const touchTimer = useTimeout();\n const [openState, setOpenState] = useControlled({\n controlled: openProp,\n default: false,\n name: 'Tooltip',\n state: 'open'\n });\n let open = openState;\n if (process.env.NODE_ENV !== 'production') {\n // eslint-disable-next-line react-hooks/rules-of-hooks\n const {\n current: isControlled\n } = React.useRef(openProp !== undefined);\n\n // eslint-disable-next-line react-hooks/rules-of-hooks\n React.useEffect(() => {\n if (childNode && childNode.disabled && !isControlled && title !== '' && childNode.tagName.toLowerCase() === 'button') {\n console.error(['MUI: You are providing a disabled `button` child to the Tooltip component.', 'A disabled element does not fire events.', \"Tooltip needs to listen to the child element's events to display the title.\", '', 'Add a simple wrapper element, such as a `span`.'].join('\\n'));\n }\n }, [title, childNode, isControlled]);\n }\n const id = useId(idProp);\n const prevUserSelect = React.useRef();\n const stopTouchInteraction = useEventCallback(() => {\n if (prevUserSelect.current !== undefined) {\n document.body.style.WebkitUserSelect = prevUserSelect.current;\n prevUserSelect.current = undefined;\n }\n touchTimer.clear();\n });\n React.useEffect(() => stopTouchInteraction, [stopTouchInteraction]);\n const handleOpen = event => {\n hystersisTimer.clear();\n hystersisOpen = true;\n\n // The mouseover event will trigger for every nested element in the tooltip.\n // We can skip rerendering when the tooltip is already open.\n // We are using the mouseover event instead of the mouseenter event to fix a hide/show issue.\n setOpenState(true);\n if (onOpen && !open) {\n onOpen(event);\n }\n };\n const handleClose = useEventCallback(\n /**\n * @param {React.SyntheticEvent | Event} event\n */\n event => {\n hystersisTimer.start(800 + leaveDelay, () => {\n hystersisOpen = false;\n });\n setOpenState(false);\n if (onClose && open) {\n onClose(event);\n }\n closeTimer.start(theme.transitions.duration.shortest, () => {\n ignoreNonTouchEvents.current = false;\n });\n });\n const handleEnter = event => {\n if (ignoreNonTouchEvents.current && event.type !== 'touchstart') {\n return;\n }\n\n // Remove the title ahead of time.\n // We don't want to wait for the next render commit.\n // We would risk displaying two tooltips at the same time (native + this one).\n if (childNode) {\n childNode.removeAttribute('title');\n }\n enterTimer.clear();\n leaveTimer.clear();\n if (enterDelay || hystersisOpen && enterNextDelay) {\n enterTimer.start(hystersisOpen ? enterNextDelay : enterDelay, () => {\n handleOpen(event);\n });\n } else {\n handleOpen(event);\n }\n };\n const handleLeave = event => {\n enterTimer.clear();\n leaveTimer.start(leaveDelay, () => {\n handleClose(event);\n });\n };\n const {\n isFocusVisibleRef,\n onBlur: handleBlurVisible,\n onFocus: handleFocusVisible,\n ref: focusVisibleRef\n } = useIsFocusVisible();\n // We don't necessarily care about the focusVisible state (which is safe to access via ref anyway).\n // We just need to re-render the Tooltip if the focus-visible state changes.\n const [, setChildIsFocusVisible] = React.useState(false);\n const handleBlur = event => {\n handleBlurVisible(event);\n if (isFocusVisibleRef.current === false) {\n setChildIsFocusVisible(false);\n handleLeave(event);\n }\n };\n const handleFocus = event => {\n // Workaround for https://github.com/facebook/react/issues/7769\n // The autoFocus of React might trigger the event before the componentDidMount.\n // We need to account for this eventuality.\n if (!childNode) {\n setChildNode(event.currentTarget);\n }\n handleFocusVisible(event);\n if (isFocusVisibleRef.current === true) {\n setChildIsFocusVisible(true);\n handleEnter(event);\n }\n };\n const detectTouchStart = event => {\n ignoreNonTouchEvents.current = true;\n const childrenProps = children.props;\n if (childrenProps.onTouchStart) {\n childrenProps.onTouchStart(event);\n }\n };\n const handleMouseOver = handleEnter;\n const handleMouseLeave = handleLeave;\n const handleTouchStart = event => {\n detectTouchStart(event);\n leaveTimer.clear();\n closeTimer.clear();\n stopTouchInteraction();\n prevUserSelect.current = document.body.style.WebkitUserSelect;\n // Prevent iOS text selection on long-tap.\n document.body.style.WebkitUserSelect = 'none';\n touchTimer.start(enterTouchDelay, () => {\n document.body.style.WebkitUserSelect = prevUserSelect.current;\n handleEnter(event);\n });\n };\n const handleTouchEnd = event => {\n if (children.props.onTouchEnd) {\n children.props.onTouchEnd(event);\n }\n stopTouchInteraction();\n leaveTimer.start(leaveTouchDelay, () => {\n handleClose(event);\n });\n };\n React.useEffect(() => {\n if (!open) {\n return undefined;\n }\n\n /**\n * @param {KeyboardEvent} nativeEvent\n */\n function handleKeyDown(nativeEvent) {\n // IE11, Edge (prior to using Bink?) use 'Esc'\n if (nativeEvent.key === 'Escape' || nativeEvent.key === 'Esc') {\n handleClose(nativeEvent);\n }\n }\n document.addEventListener('keydown', handleKeyDown);\n return () => {\n document.removeEventListener('keydown', handleKeyDown);\n };\n }, [handleClose, open]);\n const handleRef = useForkRef(children.ref, focusVisibleRef, setChildNode, ref);\n\n // There is no point in displaying an empty tooltip.\n // So we exclude all falsy values, except 0, which is valid.\n if (!title && title !== 0) {\n open = false;\n }\n const popperRef = React.useRef();\n const handleMouseMove = event => {\n const childrenProps = children.props;\n if (childrenProps.onMouseMove) {\n childrenProps.onMouseMove(event);\n }\n cursorPosition = {\n x: event.clientX,\n y: event.clientY\n };\n if (popperRef.current) {\n popperRef.current.update();\n }\n };\n const nameOrDescProps = {};\n const titleIsString = typeof title === 'string';\n if (describeChild) {\n nameOrDescProps.title = !open && titleIsString && !disableHoverListener ? title : null;\n nameOrDescProps['aria-describedby'] = open ? id : null;\n } else {\n nameOrDescProps['aria-label'] = titleIsString ? title : null;\n nameOrDescProps['aria-labelledby'] = open && !titleIsString ? id : null;\n }\n const childrenProps = _extends({}, nameOrDescProps, other, children.props, {\n className: clsx(other.className, children.props.className),\n onTouchStart: detectTouchStart,\n ref: handleRef\n }, followCursor ? {\n onMouseMove: handleMouseMove\n } : {});\n if (process.env.NODE_ENV !== 'production') {\n childrenProps['data-mui-internal-clone-element'] = true;\n\n // eslint-disable-next-line react-hooks/rules-of-hooks\n React.useEffect(() => {\n if (childNode && !childNode.getAttribute('data-mui-internal-clone-element')) {\n console.error(['MUI: The `children` component of the Tooltip is not forwarding its props correctly.', 'Please make sure that props are spread on the same element that the ref is applied to.'].join('\\n'));\n }\n }, [childNode]);\n }\n const interactiveWrapperListeners = {};\n if (!disableTouchListener) {\n childrenProps.onTouchStart = handleTouchStart;\n childrenProps.onTouchEnd = handleTouchEnd;\n }\n if (!disableHoverListener) {\n childrenProps.onMouseOver = composeEventHandler(handleMouseOver, childrenProps.onMouseOver);\n childrenProps.onMouseLeave = composeEventHandler(handleMouseLeave, childrenProps.onMouseLeave);\n if (!disableInteractive) {\n interactiveWrapperListeners.onMouseOver = handleMouseOver;\n interactiveWrapperListeners.onMouseLeave = handleMouseLeave;\n }\n }\n if (!disableFocusListener) {\n childrenProps.onFocus = composeEventHandler(handleFocus, childrenProps.onFocus);\n childrenProps.onBlur = composeEventHandler(handleBlur, childrenProps.onBlur);\n if (!disableInteractive) {\n interactiveWrapperListeners.onFocus = handleFocus;\n interactiveWrapperListeners.onBlur = handleBlur;\n }\n }\n if (process.env.NODE_ENV !== 'production') {\n if (children.props.title) {\n console.error(['MUI: You have provided a `title` prop to the child of .', `Remove this title prop \\`${children.props.title}\\` or the Tooltip component.`].join('\\n'));\n }\n }\n const popperOptions = React.useMemo(() => {\n var _PopperProps$popperOp;\n let tooltipModifiers = [{\n name: 'arrow',\n enabled: Boolean(arrowRef),\n options: {\n element: arrowRef,\n padding: 4\n }\n }];\n if ((_PopperProps$popperOp = PopperProps.popperOptions) != null && _PopperProps$popperOp.modifiers) {\n tooltipModifiers = tooltipModifiers.concat(PopperProps.popperOptions.modifiers);\n }\n return _extends({}, PopperProps.popperOptions, {\n modifiers: tooltipModifiers\n });\n }, [arrowRef, PopperProps]);\n const ownerState = _extends({}, props, {\n isRtl,\n arrow,\n disableInteractive,\n placement,\n PopperComponentProp,\n touch: ignoreNonTouchEvents.current\n });\n const classes = useUtilityClasses(ownerState);\n const PopperComponent = (_ref = (_slots$popper = slots.popper) != null ? _slots$popper : components.Popper) != null ? _ref : TooltipPopper;\n const TransitionComponent = (_ref2 = (_ref3 = (_slots$transition = slots.transition) != null ? _slots$transition : components.Transition) != null ? _ref3 : TransitionComponentProp) != null ? _ref2 : Grow;\n const TooltipComponent = (_ref4 = (_slots$tooltip = slots.tooltip) != null ? _slots$tooltip : components.Tooltip) != null ? _ref4 : TooltipTooltip;\n const ArrowComponent = (_ref5 = (_slots$arrow = slots.arrow) != null ? _slots$arrow : components.Arrow) != null ? _ref5 : TooltipArrow;\n const popperProps = appendOwnerState(PopperComponent, _extends({}, PopperProps, (_slotProps$popper = slotProps.popper) != null ? _slotProps$popper : componentsProps.popper, {\n className: clsx(classes.popper, PopperProps == null ? void 0 : PopperProps.className, (_ref6 = (_slotProps$popper2 = slotProps.popper) != null ? _slotProps$popper2 : componentsProps.popper) == null ? void 0 : _ref6.className)\n }), ownerState);\n const transitionProps = appendOwnerState(TransitionComponent, _extends({}, TransitionProps, (_slotProps$transition = slotProps.transition) != null ? _slotProps$transition : componentsProps.transition), ownerState);\n const tooltipProps = appendOwnerState(TooltipComponent, _extends({}, (_slotProps$tooltip = slotProps.tooltip) != null ? _slotProps$tooltip : componentsProps.tooltip, {\n className: clsx(classes.tooltip, (_ref7 = (_slotProps$tooltip2 = slotProps.tooltip) != null ? _slotProps$tooltip2 : componentsProps.tooltip) == null ? void 0 : _ref7.className)\n }), ownerState);\n const tooltipArrowProps = appendOwnerState(ArrowComponent, _extends({}, (_slotProps$arrow = slotProps.arrow) != null ? _slotProps$arrow : componentsProps.arrow, {\n className: clsx(classes.arrow, (_ref8 = (_slotProps$arrow2 = slotProps.arrow) != null ? _slotProps$arrow2 : componentsProps.arrow) == null ? void 0 : _ref8.className)\n }), ownerState);\n return /*#__PURE__*/_jsxs(React.Fragment, {\n children: [/*#__PURE__*/React.cloneElement(children, childrenProps), /*#__PURE__*/_jsx(PopperComponent, _extends({\n as: PopperComponentProp != null ? PopperComponentProp : Popper,\n placement: placement,\n anchorEl: followCursor ? {\n getBoundingClientRect: () => ({\n top: cursorPosition.y,\n left: cursorPosition.x,\n right: cursorPosition.x,\n bottom: cursorPosition.y,\n width: 0,\n height: 0\n })\n } : childNode,\n popperRef: popperRef,\n open: childNode ? open : false,\n id: id,\n transition: true\n }, interactiveWrapperListeners, popperProps, {\n popperOptions: popperOptions,\n children: ({\n TransitionProps: TransitionPropsInner\n }) => /*#__PURE__*/_jsx(TransitionComponent, _extends({\n timeout: theme.transitions.duration.shorter\n }, TransitionPropsInner, transitionProps, {\n children: /*#__PURE__*/_jsxs(TooltipComponent, _extends({}, tooltipProps, {\n children: [title, arrow ? /*#__PURE__*/_jsx(ArrowComponent, _extends({}, tooltipArrowProps, {\n ref: setArrowRef\n })) : null]\n }))\n }))\n }))]\n });\n});\nprocess.env.NODE_ENV !== \"production\" ? Tooltip.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the d.ts file and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * If `true`, adds an arrow to the tooltip.\n * @default false\n */\n arrow: PropTypes.bool,\n /**\n * Tooltip reference element.\n */\n children: elementAcceptingRef.isRequired,\n /**\n * Override or extend the styles applied to the component.\n */\n classes: PropTypes.object,\n /**\n * @ignore\n */\n className: PropTypes.string,\n /**\n * The components used for each slot inside.\n *\n * This prop is an alias for the `slots` prop.\n * It's recommended to use the `slots` prop instead.\n *\n * @default {}\n */\n components: PropTypes.shape({\n Arrow: PropTypes.elementType,\n Popper: PropTypes.elementType,\n Tooltip: PropTypes.elementType,\n Transition: PropTypes.elementType\n }),\n /**\n * The extra props for the slot components.\n * You can override the existing props or add new ones.\n *\n * This prop is an alias for the `slotProps` prop.\n * It's recommended to use the `slotProps` prop instead, as `componentsProps` will be deprecated in the future.\n *\n * @default {}\n */\n componentsProps: PropTypes.shape({\n arrow: PropTypes.object,\n popper: PropTypes.object,\n tooltip: PropTypes.object,\n transition: PropTypes.object\n }),\n /**\n * Set to `true` if the `title` acts as an accessible description.\n * By default the `title` acts as an accessible label for the child.\n * @default false\n */\n describeChild: PropTypes.bool,\n /**\n * Do not respond to focus-visible events.\n * @default false\n */\n disableFocusListener: PropTypes.bool,\n /**\n * Do not respond to hover events.\n * @default false\n */\n disableHoverListener: PropTypes.bool,\n /**\n * Makes a tooltip not interactive, i.e. it will close when the user\n * hovers over the tooltip before the `leaveDelay` is expired.\n * @default false\n */\n disableInteractive: PropTypes.bool,\n /**\n * Do not respond to long press touch events.\n * @default false\n */\n disableTouchListener: PropTypes.bool,\n /**\n * The number of milliseconds to wait before showing the tooltip.\n * This prop won't impact the enter touch delay (`enterTouchDelay`).\n * @default 100\n */\n enterDelay: PropTypes.number,\n /**\n * The number of milliseconds to wait before showing the tooltip when one was already recently opened.\n * @default 0\n */\n enterNextDelay: PropTypes.number,\n /**\n * The number of milliseconds a user must touch the element before showing the tooltip.\n * @default 700\n */\n enterTouchDelay: PropTypes.number,\n /**\n * If `true`, the tooltip follow the cursor over the wrapped element.\n * @default false\n */\n followCursor: PropTypes.bool,\n /**\n * This prop is used to help implement the accessibility logic.\n * If you don't provide this prop. It falls back to a randomly generated id.\n */\n id: PropTypes.string,\n /**\n * The number of milliseconds to wait before hiding the tooltip.\n * This prop won't impact the leave touch delay (`leaveTouchDelay`).\n * @default 0\n */\n leaveDelay: PropTypes.number,\n /**\n * The number of milliseconds after the user stops touching an element before hiding the tooltip.\n * @default 1500\n */\n leaveTouchDelay: PropTypes.number,\n /**\n * Callback fired when the component requests to be closed.\n *\n * @param {React.SyntheticEvent} event The event source of the callback.\n */\n onClose: PropTypes.func,\n /**\n * Callback fired when the component requests to be open.\n *\n * @param {React.SyntheticEvent} event The event source of the callback.\n */\n onOpen: PropTypes.func,\n /**\n * If `true`, the component is shown.\n */\n open: PropTypes.bool,\n /**\n * Tooltip placement.\n * @default 'bottom'\n */\n placement: PropTypes.oneOf(['bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n /**\n * The component used for the popper.\n * @default Popper\n */\n PopperComponent: PropTypes.elementType,\n /**\n * Props applied to the [`Popper`](/material-ui/api/popper/) element.\n * @default {}\n */\n PopperProps: PropTypes.object,\n /**\n * The extra props for the slot components.\n * You can override the existing props or add new ones.\n *\n * This prop is an alias for the `componentsProps` prop, which will be deprecated in the future.\n *\n * @default {}\n */\n slotProps: PropTypes.shape({\n arrow: PropTypes.object,\n popper: PropTypes.object,\n tooltip: PropTypes.object,\n transition: PropTypes.object\n }),\n /**\n * The components used for each slot inside.\n *\n * This prop is an alias for the `components` prop, which will be deprecated in the future.\n *\n * @default {}\n */\n slots: PropTypes.shape({\n arrow: PropTypes.elementType,\n popper: PropTypes.elementType,\n tooltip: PropTypes.elementType,\n transition: PropTypes.elementType\n }),\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Tooltip title. Zero-length titles string, undefined, null and false are never displayed.\n */\n title: PropTypes.node,\n /**\n * The component used for the transition.\n * [Follow this guide](/material-ui/transitions/#transitioncomponent-prop) to learn more about the requirements for this component.\n * @default Grow\n */\n TransitionComponent: PropTypes.elementType,\n /**\n * Props applied to the transition element.\n * By default, the element is based on this [`Transition`](http://reactcommunity.org/react-transition-group/transition/) component.\n */\n TransitionProps: PropTypes.object\n} : void 0;\nexport default Tooltip;","import '@/components/mui/menu-item.component.css';\nimport ArrowRightIcon from '@mui/icons-material/ArrowRight';\nimport {\n ListItemIcon as MuiListItemIcon,\n ListItemText as MuiListItemText,\n MenuItem as MuiMenuItem,\n} from '@mui/material';\nimport Tooltip from '@mui/material/Tooltip';\nimport { Localized, ReferencedItem, SingleColumnMenu } from 'platform-bible-utils';\nimport { MouseEvent, PropsWithChildren } from 'react';\n\ntype MenuItemInfoBase = {\n /** Text (displayable in the UI) as the name of the menu item */\n label: string;\n /** Text to display when the mouse hovers over the menu item */\n tooltip?: string;\n};\n\nexport type Command = MenuItemInfoBase & {\n /** Command to execute (string.string) */\n command: string;\n};\n\ntype SubMenu = MenuItemInfoBase & {\n /** Command to execute (string.string) */\n items: MenuItemInfo[];\n};\n\nexport interface CommandHandler {\n (command: Command): void;\n}\n\nexport type MenuPropsBase = {\n /*\n * The JSON defining the menu whose items are to be rendered. This will typically be one of the\n * menus in the \"defs\" in a Platform.Bible menu (see PlatformMenus). The schema for this is\n * menuDocumentSchema (at the end of menus.model.ts). Note that while this is a\n * \"SingleColumnMenu\", somewhat bizarrely, a MultiColumnMenu is a SingleColumnMenu, so it really\n * could be a MultiColumnMenu, in which case, column had better be defined so it can be used\n * to filter out the actual groups and items to display on the column.\n */\n menuDefinition: Localized;\n\n commandHandler: CommandHandler;\n\n /**\n * Additional action to perform when any menu item is clicked. Allows the caller to handle event\n * (e.g., to close the menu).\n */\n onClick?: (event: MouseEvent) => void;\n};\n\nexport type MenuItemListProps = MenuPropsBase & {\n /** Optional unique (column) identifier */\n columnId?: ReferencedItem;\n};\n\nexport type MenuItemProps = Omit &\n PropsWithChildren<{\n /** Optional unique identifier */\n id?: string;\n\n onClick: (event: MouseEvent) => void;\n }>;\n\ntype MenuItemInfo = (Command | SubMenu) & {\n /**\n * If specified, menu item will be inset if it does not have a leading icon.\n *\n * @default true\n */\n allowForLeadingIcons?: boolean;\n /**\n * If specified, the path to the icon image to display on the leading side of the menu text.\n *\n * @default undefined (no leading icon will be shown)\n */\n iconPathBefore?: string;\n /**\n * If specified, the path to the icon image to display on the trailing side of the menu text.\n *\n * @default undefined (no trailing icon will be shown)\n */\n iconPathAfter?: string;\n /**\n * If true, list item is focused during the first mount\n *\n * @default false\n */\n hasAutoFocus?: boolean;\n\n /** Additional css classes to help with unique styling of the menu item */\n className?: string;\n\n /**\n * If true, the menu item will appear disabled and it will not respond to clicks or mouse hovers.\n *\n * @default false\n */\n isDisabled?: boolean;\n\n /**\n * If true, compact vertical padding designed for keyboard and mouse input is used.\n *\n * @default true\n */\n isDense?: boolean;\n\n /**\n * If true, a right-arrow icon will be displayed (iconPathAfter, if specified, will be ignored).\n *\n * @default false\n */\n isSubMenuParent?: boolean;\n\n /**\n * If true, the left and right padding is removed\n *\n * @default false\n */\n hasDisabledGutters?: boolean;\n\n /**\n * If true, a 1px light border is added to bottom of menu item\n *\n * @default false\n */\n hasDivider?: boolean;\n\n /** Help identify which element has keyboard focus */\n focusVisibleClassName?: string;\n\n /** If it's a submenu, it should have the items property */\n items?: MenuItemInfo[];\n};\n\nfunction getIcon(icon: string | undefined, menuLabel: string, leading: boolean) {\n return icon ? (\n \n {`${leading\n \n ) : undefined;\n}\n\nexport default function MenuItem(props: MenuItemProps) {\n const {\n onClick,\n label,\n tooltip,\n allowForLeadingIcons = true,\n iconPathBefore = undefined,\n iconPathAfter = undefined,\n hasAutoFocus = false,\n className,\n isDisabled = false,\n isDense = true,\n isSubMenuParent = false,\n hasDisabledGutters = false,\n hasDivider = false,\n focusVisibleClassName,\n id,\n children,\n } = props;\n\n const menuItem = (\n \n {label ? (\n <>\n {getIcon(iconPathBefore, label, true)}\n \n {isSubMenuParent ? (\n \n \n \n ) : (\n getIcon(iconPathAfter, label, false)\n )}\n \n ) : (\n children\n )}\n \n );\n\n return tooltip ? (\n \n
    {menuItem}
    \n
    \n ) : (\n menuItem\n );\n}\n","import MenuItem, {\n MenuItemListProps,\n MenuItemProps,\n MenuPropsBase,\n} from '@/components/mui/menu-item.component';\nimport { Menu } from '@mui/material';\nimport {\n Localized,\n MenuGroupDetailsInSubMenu,\n MenuItemContainingCommand,\n MenuItemContainingSubmenu,\n OrderedExtensibleContainer,\n ReferencedItem,\n SingleColumnMenu,\n} from 'platform-bible-utils';\nimport { MouseEvent, useMemo, useState } from 'react';\n\n/**\n * All the exported types in this file should be regarded as \"internal\" (i.e., they should not be\n * exposed via index.ts).\n */\n\nexport type GroupedMenuPropsBase = MenuPropsBase & {\n /** Optional unique (column) identifier */\n columnId?: ReferencedItem;\n};\n\nexport type GroupedMenuItemListProps = MenuItemListProps & {\n /**\n * If the menuDefinition includes \"top-level\" groups (i.e., those that belong to a column as\n * opposed to those that belong to a submenu) that should not be included in the list, then this\n * array specifies which groups to include. Likewise, for a submenu, this list indicates which\n * groups are pertinent for that submenu. So then for a context menu this property need not be\n * specified since it is a top-level menu based on a \"true\" SingleColumnMenu (i.e., one that is\n * not a MultiColumnMenu).\n */\n includedGroups?: {\n id: string;\n group: Localized;\n }[];\n};\n\ninterface ItemInfo {\n item: Localized;\n isLastItemInGroup: boolean;\n}\n\ntype SubMenuProps = MenuPropsBase & {\n parentMenuItem: Localized;\n parentItemProps: Omit, 'iconPathAfter'>;\n};\n\nfunction getAllGroups(menuDefinition: Localized) {\n const groupEntries = Object.entries(menuDefinition.groups);\n // Convert array of entries to array of objects with id and group properties\n return groupEntries.map(([key, value]) => ({ id: key, group: value }));\n}\n\nfunction SubMenu(props: SubMenuProps) {\n const [anchorEl, setAnchorEl] = useState(undefined);\n\n const { parentMenuItem, parentItemProps, menuDefinition } = props;\n\n const handleParentMenuItemClick = (event: MouseEvent) => {\n setAnchorEl(event.currentTarget);\n };\n\n const handleClose = () => {\n setAnchorEl(undefined);\n };\n\n const renderSubMenuItems = () => {\n let includedGroups = getAllGroups(menuDefinition).filter((g) => 'menuItem' in g.group);\n\n // Ensure valid parent menu was provided. (If not, submenu will contain all groups!)\n if (!parentMenuItem?.id) throw new Error('A valid parent menu item is required for submenus.');\n\n // When laying out a submenu, only include groups associated with the provided parent menu.\n // Note: without the (annoying) redundant check that the included groups\n // have the menuItem field, TS doesn't think it exists.\n includedGroups = includedGroups.filter(\n (group) => 'menuItem' in group.group && group.group.menuItem === parentMenuItem.id,\n );\n\n return ;\n };\n\n return (\n <>\n \n \n {renderSubMenuItems()}\n \n \n );\n}\n\nconst getOrderedGroupItems = (\n groupId: string,\n allItems: Localized[],\n) => {\n // Filter items that belong to the specified group\n const itemsForGroup = allItems.filter((item) => item.group === groupId);\n // Sort items based on order\n const sortedItems = itemsForGroup.sort((a, b) => (a.order || 0) - (b.order || 0));\n return sortedItems;\n};\n\n/**\n * This component is internal; it does not need to be exposed to the outside world since it is not\n * useful on its own. It is used to generate and lay out the MenuItems that appear either on a\n * top-level menu (in a GridMenu or ContextMenu) or in a submenu.\n */\nexport default function GroupedMenuItemList(menuProps: GroupedMenuItemListProps) {\n const { menuDefinition, onClick, commandHandler, includedGroups } = menuProps;\n\n const { items, allowForLeadingIcons } = useMemo(() => {\n const groupsToInclude =\n includedGroups && includedGroups.length > 0\n ? includedGroups\n : // We're apparently laying out a single-column menu (presumably a context menu). In this\n // case, all groups should be included except ones that belong to a submenu.\n getAllGroups(menuDefinition).filter((g) => !('menuItem' in g.group));\n\n const sortedGroups = Object.values(groupsToInclude).sort(\n (a, b) => (a.group.order || 0) - (b.group.order || 0),\n );\n\n const itemArray: ItemInfo[] = [];\n\n sortedGroups.forEach((group) => {\n getOrderedGroupItems(group.id, menuDefinition.items).forEach((item) =>\n itemArray.push({ item, isLastItemInGroup: false }),\n );\n if (itemArray.length > 0) itemArray[itemArray.length - 1].isLastItemInGroup = true;\n });\n\n // No divider after last item in final group.\n if (itemArray.length > 0) itemArray[itemArray.length - 1].isLastItemInGroup = false;\n\n const allowSpaceForLeadingIcons = itemArray.some(\n (i) => 'iconPathBefore' in i.item && i.item.iconPathBefore,\n );\n\n return { items: itemArray, allowForLeadingIcons: allowSpaceForLeadingIcons };\n }, [includedGroups, menuDefinition]);\n\n // Create props for MenuItem component including setting hasDivider for the last item in a group\n const createMenuItemProps = ({ item, isLastItemInGroup }: ItemInfo) => {\n const menuItemProps = {\n className: 'papi-menu-item',\n label: item.label,\n tooltip: item.tooltip,\n iconPathBefore: 'iconPathBefore' in item ? item.iconPathBefore : undefined,\n iconPathAfter: 'iconPathAfter' in item ? item.iconPathAfter : undefined,\n hasDivider: isLastItemInGroup, // Set hasDivider to true for the last item in a group\n allowForLeadingIcons,\n };\n\n return menuItemProps;\n };\n\n const [firstItem] = items;\n\n if (!firstItem) return
    ;\n\n const divKey = firstItem.item.group;\n\n return (\n
    \n {items.map((itemInfo, index) => {\n const { item } = itemInfo;\n const menuItemProps = createMenuItemProps(itemInfo);\n if ('command' in item) {\n const key = item.group + index;\n return (\n ) => {\n onClick?.(event);\n commandHandler(item);\n }}\n {...menuItemProps}\n />\n );\n }\n return (\n \n );\n })}\n
    \n );\n}\n","import GroupedMenuItemList from '@/components/mui/grouped-menu-item-list.component';\nimport { MenuItemListProps } from '@/components/mui/menu-item.component';\nimport { MultiColumnMenu } from 'platform-bible-utils';\n\n/**\n * This component is internal; it does not need to be exposed to the outside world since it is not\n * useful on its own. Use either GridMenu or ContextMenu.\n */\nexport default function TopLevelMenu(props: MenuItemListProps) {\n const { menuDefinition, columnId } = props;\n\n const groupEntries = Object.entries(menuDefinition.groups);\n // Convert array of entries to array of objects with id and group properties\n const groups = groupEntries.map(([key, value]) => ({ id: key, group: value }));\n let includedGroups = groups.filter((g) => 'column' in g.group);\n\n // Check if column is provided and menuDefinition is a MultiColumnMenu\n if (\n columnId &&\n 'columns' in menuDefinition &&\n // Without this type assertion, TS doesn't know what columns is.\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n (menuDefinition as MultiColumnMenu).columns[columnId]\n ) {\n // When laying out a single column in a MultiColumnMenu, only include groups associated with\n // the provided column. Note: without the (annoying) redundant check that the included groups\n // have the colum field, TS doesn't think it exists.\n includedGroups = includedGroups.filter(\n (g) => 'column' in g.group && g.group.column === columnId,\n );\n }\n\n return ;\n}\n","import '@/components/mui/grid-menu.component.css';\nimport { GroupedMenuPropsBase } from '@/components/mui/grouped-menu-item-list.component';\nimport { CommandHandler } from '@/components/mui/menu-item.component';\nimport TopLevelMenu from '@/components/mui/top-level-menu.component';\nimport { Grid, List } from '@mui/material';\nimport {\n Localized,\n MenuColumnWithHeader,\n MultiColumnMenu,\n ReferencedItem,\n} from 'platform-bible-utils';\nimport { useMemo } from 'react';\n\ntype ColumnInfo = {\n /*\n * The ID (`${string}.${string}`) of a specific menu column.\n */\n id: ReferencedItem;\n\n /*\n * Metadata (label, order, etc.) for a specific menu column.\n */\n metadata: Localized;\n};\n\ntype MenuColumnProps = ColumnInfo &\n GroupedMenuPropsBase & {\n /** Additional css classes to help with unique styling of the menu column */\n className?: string;\n };\n\nexport type GridMenuInfo = {\n /** The menu object containing information about the columns, groups, and items to display. */\n multiColumnMenu: Localized;\n};\n\nexport type GridMenuProps = GridMenuInfo & {\n /** Optional unique identifier */\n id?: string;\n\n commandHandler: CommandHandler;\n\n /** Additional css classes to help with unique styling of the grid menu */\n className?: string;\n};\n\nfunction MenuColumn({\n commandHandler,\n menuDefinition,\n id,\n metadata,\n onClick,\n className,\n}: MenuColumnProps) {\n return (\n \n

    \n {metadata.label}\n

    \n {/* It would seem as though this List component were unnecessary, since it only contains one\n thing, but the \"dense\" property does affect the layout of the items (in a way I don't fully\n understand). There might be a better way. */}\n \n \n \n \n );\n}\n\nexport default function GridMenu({\n commandHandler,\n className,\n multiColumnMenu,\n id,\n}: GridMenuProps) {\n const { columns } = multiColumnMenu;\n\n const sortedColumns = useMemo(() => {\n const columnNumbers = new Map();\n Object.getOwnPropertyNames(columns).forEach((columnName: string) => {\n // We know for sure there is a (boolean) property 'isExtensible' that we are not interested in.\n if (columnName === 'isExtensible') return;\n // TS doesn't allow `columnName` above to be a ReferencedItem even though the type says it is\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const columnId = columnName as ReferencedItem;\n const column = columns[columnId];\n // As of right now (and hopefully forever after), all remaining properties of the\n // ColumnsWithHeaders object are columns whose property names are the IDs of the columns.\n // This is an additional (redundant) sanity check. Specifically we're interested in\n // MenuColumnWithHeader objects, which TypeScript now \"knows\" we have, but at runtime all we\n // can check for is that it's an object with a valid numeric order field. That's likely good\n // enough.\n if (\n typeof column === 'object' &&\n typeof column.order === 'number' &&\n !Number.isNaN(column.order)\n )\n columnNumbers.set(column.order, { id: columnId, metadata: column });\n else\n console.warn(\n `Property ${columnName} (${typeof column}) on menu ${id} is not a valid column and is being ignored. This might indicate data corruption`,\n );\n });\n\n // Extract values and sort them based on the 'order' property\n return Array.from(columnNumbers.values()).sort((a, b) => {\n return (a.metadata.order || 0) - (b.metadata.order || 0);\n });\n }, [columns, id]);\n\n // We might need something like this if we need to be able to prevent empty columns\n // sortedColumns.filter((c) => multiColumnMenu.groups.some((g) => 'column' in g && (g as .column)...\n\n return (\n \n {sortedColumns.map((col, index) => (\n \n ))}\n \n );\n}\n","import { useEffect, useRef, useState } from 'react';\n\nexport type UsePromiseOptions = {\n /**\n * Whether to leave the value as the most recent resolved promise value or set it back to\n * defaultValue while running the promise again. Defaults to true\n */\n preserveValue?: boolean;\n};\n\n/** Set up defaults for options for usePromise hook */\nfunction getUsePromiseOptionsDefaults(options: UsePromiseOptions): UsePromiseOptions {\n return {\n preserveValue: true,\n ...options,\n };\n}\n\n/**\n * Awaits a promise and returns a loading value while the promise is unresolved\n *\n * @param promiseFactoryCallback A function that returns the promise to await. If this callback is\n * undefined, the current value will be returned (defaultValue unless it was previously changed\n * and `options.preserveValue` is true), and there will be no loading.\n *\n * WARNING: MUST BE STABLE - const or wrapped in useCallback. The reference must not be updated\n * every render\n * @param defaultValue The initial value to return while first awaiting the promise. If\n * `options.preserveValue` is false, this value is also shown while awaiting the promise on\n * subsequent calls.\n *\n * Note: this parameter is internally assigned to a `ref`, so changing it will not cause any hooks\n * to re-run with its new value. This means that, if the `promiseFactoryCallback` changes and\n * `options.preserveValue` is `false`, the returned value will be set to the current\n * `defaultValue`. However, the returned value will not be updated if`defaultValue` changes.\n * @param options Various options for adjusting how this hook runs the `promiseFactoryCallback`\n *\n * Note: this parameter is internally assigned to a `ref`, so changing it will not cause any hooks\n * to re-run with its new value. However, the latest `options.preserveValue` will always be used\n * appropriately to determine whether to preserve the returned value when changing the\n * `promiseFactoryCallback`\n * @returns `[value, isLoading]`\n *\n * - `value`: the current value for the promise, either the defaultValue or the resolved promise value\n * - `isLoading`: whether the promise is waiting to be resolved\n */\nconst usePromise = (\n promiseFactoryCallback: (() => Promise) | undefined,\n defaultValue: T,\n options: UsePromiseOptions = {},\n): [value: T, isLoading: boolean] => {\n // Use defaultValue as a ref so it doesn't update dependency arrays\n const defaultValueRef = useRef(defaultValue);\n defaultValueRef.current = defaultValue;\n // Use options as a ref so it doesn't update dependency arrays\n const optionsDefaultedRef = useRef(options);\n optionsDefaultedRef.current = getUsePromiseOptionsDefaults(optionsDefaultedRef.current);\n\n const [value, setValue] = useState(() => defaultValueRef.current);\n const [isLoading, setIsLoading] = useState(true);\n useEffect(() => {\n let promiseIsCurrent = true;\n // If a promiseFactoryCallback was provided, we are loading. Otherwise, there is no loading to do\n setIsLoading(!!promiseFactoryCallback);\n (async () => {\n // If there is a callback to run, run it\n if (promiseFactoryCallback) {\n const result = await promiseFactoryCallback();\n // If the promise was not already replaced, update the value\n if (promiseIsCurrent) {\n setValue(() => result);\n setIsLoading(false);\n }\n }\n })();\n\n return () => {\n // Mark this promise as old and not to be used\n promiseIsCurrent = false;\n if (!optionsDefaultedRef.current.preserveValue) setValue(() => defaultValueRef.current);\n };\n }, [promiseFactoryCallback]);\n\n return [value, isLoading];\n};\nexport default usePromise;\n","\"use client\";\n\nimport createSvgIcon from './utils/createSvgIcon';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nexport default createSvgIcon( /*#__PURE__*/_jsx(\"path\", {\n d: \"M3 18h18v-2H3zm0-5h18v-2H3zm0-7v2h18V6z\"\n}), 'Menu');","import GridMenu from '@/components/mui/grid-menu.component';\nimport { Command, CommandHandler } from '@/components/mui/menu-item.component';\nimport usePromise from '@/hooks/use-promise.hook';\nimport { Menu as MenuIcon } from '@mui/icons-material';\nimport { Drawer, IconButton } from '@mui/material';\nimport { Localized, MultiColumnMenu } from 'platform-bible-utils';\nimport {\n MouseEvent,\n MutableRefObject,\n PropsWithChildren,\n useCallback,\n useEffect,\n useState,\n} from 'react';\n\nexport interface MultiColumnMenuProvider {\n (isSupportAndDevelopment: boolean): Promise>;\n}\n\nexport type HamburgerMenuButtonProps = PropsWithChildren & {\n /** The handler to use for menu commands (and eventually toolbar commands). */\n commandHandler: CommandHandler;\n\n /**\n * Optional reference to the \"div\" container that determines the where the menu should appear. If\n * not defined, then (1,1) used.\n */\n containerRef?: MutableRefObject;\n\n /**\n * The delegate to use to get the menu data. If not specified or if it returns undefined, the data\n * in normalMenu or fullMenu property will be used.\n */\n menuProvider?: MultiColumnMenuProvider;\n\n /**\n * The menu data to show when the menu is opened if the menuProvider property is not defined.\n * (This allows for a default or test-only static menu to be used.)\n */\n normalMenu?: Localized;\n\n /**\n * The menu data to show for \"full\" menu (when opened with the SHIFT key pressed) if the\n * menuProvider property is not defined. (This allows for a default or test-only static menu to be\n * used.)\n */\n fullMenu?: Localized;\n\n /** Additional css class(es) to help with unique styling of the sub-components */\n className?: string;\n\n /** Value to use as prefix for ARIA labels on interactive sub-components */\n ariaLabelPrefix?: string;\n};\n\nexport default function HamburgerMenuButton({\n menuProvider,\n normalMenu,\n fullMenu,\n commandHandler,\n containerRef,\n className,\n ariaLabelPrefix,\n children,\n}: HamburgerMenuButtonProps) {\n const [isMenuOpen, setMenuOpen] = useState(false);\n const [showFullMenu, setShowFullMenu] = useState(false);\n\n const handleMenuItemClick = useCallback(() => {\n if (isMenuOpen) setMenuOpen(false);\n setShowFullMenu(false);\n }, [isMenuOpen]);\n\n const handleMenuButtonClick = useCallback((e: MouseEvent) => {\n e.stopPropagation();\n setMenuOpen((prevIsOpen) => {\n const isOpening = !prevIsOpen;\n if (isOpening && e.shiftKey) setShowFullMenu(true);\n else if (!isOpening) setShowFullMenu(false);\n return isOpening;\n });\n }, []);\n\n const menuCommandHandler = useCallback(\n (command: Command) => {\n handleMenuItemClick();\n return commandHandler(command);\n },\n [commandHandler, handleMenuItemClick],\n );\n\n const [offset, setOffset] = useState({ top: 1, left: 1 });\n\n useEffect(() => {\n if (isMenuOpen) {\n const node = containerRef?.current;\n if (node) {\n const rect = node.getBoundingClientRect();\n const scrollTop = window.scrollY;\n const scrollLeft = window.scrollX;\n const top = rect.top + scrollTop + node.clientHeight;\n const left = rect.left + scrollLeft;\n setOffset({ top, left });\n }\n }\n }, [isMenuOpen, containerRef]);\n\n const [normalMenuData] = usePromise(\n useCallback(async () => {\n return menuProvider?.(false) ?? normalMenu;\n // isMenuOpen needs to be included for the menu contents to reevaluate when reopened\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [menuProvider, normalMenu, isMenuOpen]),\n normalMenu,\n );\n\n const [fullMenuData] = usePromise(\n useCallback(async () => {\n return menuProvider?.(true) ?? fullMenu ?? normalMenuData;\n // isMenuOpen needs to be included for the menu contents to reevaluate when reopened\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [menuProvider, fullMenu, normalMenuData, isMenuOpen]),\n fullMenu ?? normalMenuData,\n );\n\n const menu = showFullMenu && fullMenuData ? fullMenuData : normalMenuData;\n\n return (\n <>\n \n {children ?? }\n \n \n {menu ? (\n \n ) : undefined}\n \n \n );\n}\n","import '@/components/mui/icon-button.component.css';\nimport { IconButton as MuiIconButton } from '@mui/material';\nimport { MouseEventHandler, PropsWithChildren } from 'react';\n\nexport type IconButtonProps = PropsWithChildren<{\n /** Optional unique identifier */\n id?: string;\n /**\n * Required. Used as both the tooltip (aka, title) and the aria-label (used for accessibility,\n * testing, etc.), unless a distinct tooltip is supplied.\n */\n label: string;\n /**\n * Enabled status of button\n *\n * @default false\n */\n isDisabled?: boolean;\n /** Optional tooltip to display if different from the aria-label. */\n tooltip?: string;\n /** If true, no tooltip will be displayed. */\n isTooltipSuppressed?: boolean;\n /**\n * If given, uses a negative margin to counteract the padding on one side (this is often helpful\n * for aligning the left or right side of the icon with content above or below, without ruining\n * the border size and shape).\n *\n * @default false\n */\n adjustMarginToAlignToEdge?: 'end' | 'start' | false;\n /**\n * The size of the component. small is equivalent to the dense button styling.\n *\n * @default false\n */\n size: 'small' | 'medium' | 'large';\n /** Additional css classes to help with unique styling of the button */\n className?: string;\n /** Optional click handler */\n onClick?: MouseEventHandler;\n}>;\n\n/**\n * Iconic button a user can click to do something\n *\n * Thanks to MUI for heavy inspiration and documentation\n * https://mui.com/material-ui/getting-started/overview/\n */\nfunction IconButton({\n id,\n label,\n isDisabled = false,\n tooltip,\n isTooltipSuppressed = false,\n adjustMarginToAlignToEdge = false,\n size = 'medium',\n className,\n onClick,\n children,\n}: IconButtonProps) {\n return (\n \n {children /* the icon to display */}\n \n );\n}\n\nexport default IconButton;\n","import { cn } from '@/utils/shadcn-ui.util';\nimport { LoaderCircle, LucideProps } from 'lucide-react';\nimport { forwardRef } from 'react';\n\nexport type SpinnerProps = LucideProps;\n\nconst Spinner = forwardRef(({ className, ...props }, ref) => {\n return (\n \n );\n});\n\nSpinner.displayName = 'Spinner';\n\nexport default Spinner;\n","import { Input as ShadInput } from '@/components/shadcn-ui/input';\nimport { Label as ShadLabel } from '@/components/shadcn-ui/label';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { ChangeEventHandler, FocusEventHandler } from 'react';\n\nexport type TextFieldProps = {\n /** Optional unique identifier */\n id?: string;\n /**\n * If `true`, the component is disabled.\n *\n * @default false\n */\n isDisabled?: boolean;\n /**\n * If `true`, the label is displayed in an error state.\n *\n * @default false\n */\n hasError?: boolean;\n /**\n * If `true`, the input will take up the full width of its container.\n *\n * @default false\n */\n isFullWidth?: boolean;\n /** Text that gives the user instructions on what contents the TextField expects */\n helperText?: string;\n /** The title of the TextField */\n label?: string;\n /** The short hint displayed in the `input` before the user enters a value. */\n placeholder?: string;\n /**\n * If `true`, the label is displayed as required and the `input` element is required.\n *\n * @default false\n */\n isRequired?: boolean;\n /** Additional css classes to help with unique styling of the text field */\n className?: string;\n /** Starting value for the text field if it is not controlled */\n defaultValue?: string | number;\n /** Value of the text field if controlled */\n value?: string | number;\n /** Triggers when content of textfield is changed */\n onChange?: ChangeEventHandler;\n /** Triggers when textfield gets focus */\n onFocus?: FocusEventHandler;\n /** Triggers when textfield loses focus */\n onBlur?: FocusEventHandler;\n};\n\n/**\n * Text input field\n *\n * Thanks to Shadcn for heavy inspiration and documentation\n * https://ui.shadcn.com/docs/components/input#with-label\n */\nfunction TextField({\n id,\n isDisabled = false,\n hasError = false,\n isFullWidth = false,\n helperText,\n label,\n placeholder,\n isRequired = false,\n className,\n defaultValue,\n value,\n onChange,\n onFocus,\n onBlur,\n}: TextFieldProps) {\n return (\n
    \n {`${label}${isRequired ? '*' : ''}`}\n \n

    {helperText}

    \n
    \n );\n}\n\nexport default TextField;\n","import HamburgerMenuButton, {\n MultiColumnMenuProvider,\n} from '@/components/mui/hamburger-menu-button.component';\nimport { CommandHandler } from '@/components/mui/menu-item.component';\nimport '@/components/mui/toolbar.component.css';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { AppBar, Toolbar as MuiToolbar } from '@mui/material';\nimport { PropsWithChildren, useRef } from 'react';\n\nexport type ToolbarProps = PropsWithChildren<{\n /** The handler to use for menu commands (and eventually toolbar commands). */\n commandHandler: CommandHandler;\n\n /**\n * The optional delegate to use to get the menu data. If not specified, the \"hamburger\" menu will\n * not display.\n */\n menuProvider?: MultiColumnMenuProvider;\n\n /** Optional unique identifier */\n id?: string;\n\n /** Additional css classes to help with unique styling of the toolbar */\n className?: string;\n}>;\n\nexport default function Toolbar({\n menuProvider,\n commandHandler,\n className,\n id,\n children,\n}: ToolbarProps) {\n // This ref will always be defined\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const containerRef = useRef(undefined!);\n\n return (\n
    \n \n \n {menuProvider ? (\n \n ) : undefined}\n {children ?
    {children}
    : undefined}\n \n
    \n
    \n );\n}\n","import React from 'react';\nimport { cva, type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst alertVariants = cva(\n 'tw-relative tw-w-full tw-rounded-lg tw-border tw-p-4 [&>svg~*]:tw-pl-7 [&>svg+div]:tw-translate-y-[-3px] [&>svg]:tw-absolute [&>svg]:tw-left-4 [&>svg]:tw-top-4 [&>svg]:tw-text-foreground',\n {\n variants: {\n variant: {\n default: 'tw-bg-background tw-text-foreground',\n destructive:\n 'tw-border-destructive/50 tw-text-destructive dark:tw-border-destructive [&>svg]:tw-text-destructive',\n },\n },\n defaultVariants: {\n variant: 'default',\n },\n },\n);\n\nconst Alert = React.forwardRef<\n HTMLDivElement,\n React.HTMLAttributes & VariantProps\n>(({ className, variant, ...props }, ref) => (\n
    \n));\nAlert.displayName = 'Alert';\n\nconst AlertTitle = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n {/* added because of https://github.com/jsx-eslint/eslint-plugin-jsx-a11y/blob/main/docs/rules/heading-has-content.md */}\n {props.children}{' '}\n \n ),\n);\nAlertTitle.displayName = 'AlertTitle';\n\nconst AlertDescription = React.forwardRef<\n HTMLParagraphElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n
    \n));\nAlertDescription.displayName = 'AlertDescription';\n\nexport { Alert, AlertTitle, AlertDescription };\n","import React from 'react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Card = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nCard.displayName = 'Card';\n\nconst CardHeader = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nCardHeader.displayName = 'CardHeader';\n\nconst CardTitle = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n {/* added because of https://github.com/jsx-eslint/eslint-plugin-jsx-a11y/blob/main/docs/rules/heading-has-content.md */}\n {props.children}\n \n ),\n);\nCardTitle.displayName = 'CardTitle';\n\nconst CardDescription = React.forwardRef<\n HTMLParagraphElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n

    \n));\nCardDescription.displayName = 'CardDescription';\n\nconst CardContent = React.forwardRef>(\n ({ className, ...props }, ref) => (\n

    \n ),\n);\nCardContent.displayName = 'CardContent';\n\nconst CardFooter = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nCardFooter.displayName = 'CardFooter';\n\nexport { Card, CardHeader, CardFooter, CardTitle, CardDescription, CardContent };\n","import { ComponentProps } from 'react';\nimport { toast as sonner, Toaster } from 'sonner';\n\ntype SonnerProps = ComponentProps;\n\nfunction Sonner({ ...props }: SonnerProps) {\n return (\n \n );\n}\n\n// The re-export of the sonner function was added manually\nexport { Sonner, sonner };\n","import React from 'react';\nimport * as SliderPrimitive from '@radix-ui/react-slider';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Slider = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n \n \n \n));\nSlider.displayName = SliderPrimitive.Root.displayName;\n\nexport { Slider };\n","import React from 'react';\nimport * as SwitchPrimitives from '@radix-ui/react-switch';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Switch = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n));\nSwitch.displayName = SwitchPrimitives.Root.displayName;\n\nexport { Switch };\n","import React from 'react';\nimport * as TabsPrimitive from '@radix-ui/react-tabs';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport const Tabs = TabsPrimitive.Root;\n\nexport type TabsListProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport type TabsTriggerProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport type TabsContentProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport const TabsList = React.forwardRef<\n React.ElementRef,\n TabsListProps\n>(({ className, ...props }, ref) => (\n \n));\nTabsList.displayName = TabsPrimitive.List.displayName;\n\nexport const TabsTrigger = React.forwardRef<\n React.ElementRef,\n TabsTriggerProps\n>(({ className, ...props }, ref) => (\n \n));\nTabsTrigger.displayName = TabsPrimitive.Trigger.displayName;\n\nexport const TabsContent = React.forwardRef<\n React.ElementRef,\n TabsContentProps\n>(({ className, ...props }, ref) => (\n \n));\nTabsContent.displayName = TabsPrimitive.Content.displayName;\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Download } from 'lucide-react';\n\ntype InstallButtonProps = {\n /** The installing boolean value determines the state of the button. */\n isInstalling: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n /** Optional text for the button. */\n buttonText?: string;\n} & ButtonProps;\n\n/**\n * The InstallButton component is a button designed for initiating installs. It includes visuals for\n * active installing and idle states.\n *\n * @param isInstalling The installing boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @param buttonText Optional text for the button.\n * @returns A install button.\n */\nexport default function InstallButton({\n isInstalling,\n handleClick,\n buttonText,\n className,\n ...props\n}: InstallButtonProps) {\n return (\n \n {isInstalling ? (\n \n ) : (\n <>\n \n {buttonText}\n \n )}\n \n );\n}\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\n\ntype EnableButtonProps = {\n /** The enabling boolean value determines the state of the button. */\n isEnabling: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n} & ButtonProps;\n\n/**\n * The EnableButton component is a button designed for initiating enabling of downloads. It includes\n * visuals for active enabling and idle states.\n *\n * @param isEnabling The enabling boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @returns A button that can be used to enable.\n */\nexport default function EnableButton({\n isEnabling,\n handleClick,\n className,\n ...props\n}: EnableButtonProps) {\n return (\n \n {isEnabling ? (\n <>\n \n Enabling...\n \n ) : (\n 'Enable'\n )}\n \n );\n}\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\n\ntype DisableButtonProps = {\n /** The disabling boolean value determines the state of the button. */\n isDisabling: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n} & ButtonProps;\n\n/**\n * The DisableButton component is a button designed for initiating disabling of downloads. It\n * includes visuals for active disabling and idle states.\n *\n * @param isDisabling The disabling boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @returns A button that can be used to disable.\n */\nexport default function DisableButton({\n isDisabling,\n handleClick,\n className,\n ...props\n}: DisableButtonProps) {\n return (\n \n {isDisabling ? (\n <>\n \n Disabling...\n \n ) : (\n 'Disable'\n )}\n \n );\n}\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\n\ntype UpdateButtonProps = {\n /** The updating boolean value determines the state of the button. */\n isUpdating: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n} & ButtonProps;\n\n/**\n * The UpdateButton component is a button designed for initiating updates for downloaded extensions.\n * It includes visuals for active updating and idle states.\n *\n * @param isUpdating The updating boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @returns A button that can be used to update.\n */\nexport default function UpdateButton({\n isUpdating,\n handleClick,\n className,\n ...props\n}: UpdateButtonProps) {\n return (\n \n {isUpdating ? (\n <>\n \n Updating...\n \n ) : (\n 'Update'\n )}\n \n );\n}\n","import { cn } from '@/utils/shadcn-ui.util';\nimport Markdown, { MarkdownToJSX } from 'markdown-to-jsx';\nimport { useMemo } from 'react';\n\ninterface MarkdownRendererProps {\n /** Optional unique identifier */\n id?: string;\n /** The markdown string to render */\n markdown: string;\n className?: string;\n /**\n * The [`target` attribute for `a` html\n * tags](https://developer.mozilla.org/en-US/docs/Web/HTML/Element/a#target). Defaults to not\n * adding a `target` to `a` tags\n */\n anchorTarget?: string;\n}\n\n/**\n * This component renders markdown content given a markdown string. It uses typography styles from\n * the platform.\n *\n * @param markdown The markdown string to render.\n * @param id Optional unique identifier\n * @returns A div containing the rendered markdown content.\n */\nexport default function MarkdownRenderer({\n id,\n markdown,\n className,\n anchorTarget,\n}: MarkdownRendererProps) {\n const options: MarkdownToJSX.Options = useMemo(\n () => ({\n overrides: {\n a: {\n props: {\n target: anchorTarget,\n },\n },\n },\n }),\n [anchorTarget],\n );\n return (\n
    \n {markdown}\n
    \n );\n}\n","import { Filter, ChevronDown } from 'lucide-react';\nimport { forwardRef } from 'react';\nimport { Button } from '@/components/shadcn-ui/button';\n\n/**\n * The FilterButton component is a button designed for initiating filtering of data. It is designed\n * to be used with the dropdown menu. It uses forwardRef to pass the button to the dropdown trigger\n * asChild.\n *\n * @returns A button that can be used to filter.\n */\nconst FilterButton = forwardRef((props, ref) => {\n return (\n \n \n Filter\n \n \n );\n});\n\nexport default FilterButton;\n","import {\n DropdownMenu,\n DropdownMenuTrigger,\n DropdownMenuContent,\n DropdownMenuLabel,\n DropdownMenuGroup,\n DropdownMenuCheckboxItem,\n DropdownMenuRadioItem,\n DropdownMenuSeparator,\n} from '@/components/shadcn-ui/dropdown-menu';\nimport FilterButton from './buttons/filter-button.component';\n\nexport enum DropdownMenuItemType {\n Check,\n Radio,\n}\n\nexport type DropdownItem = {\n /** The label is the text that will be displayed on the dropdown item. */\n label: string;\n /** The itemType determines the DropdownMenuItemType type as either Check or Radio. */\n itemType: DropdownMenuItemType;\n /** The onClick function is called when the item is clicked. */\n onClick: () => void;\n};\n\nexport type DropdownGroup = {\n /**\n * The label is the text that will be displayed on the dropdown group. It is used to categorize\n * the items in the group.\n */\n label: string;\n /** The items array contains the items that will be displayed in the dropdown group */\n items: DropdownItem[];\n};\n\nexport type FilterDropdownProps = {\n /** Object unique identifier */\n id?: string;\n /** The groups array contains the groups that will be displayed in the dropdown */\n groups: DropdownGroup[];\n}; // TODO: extend the props later\n\n/**\n * The FilterDropdown component is a dropdown designed for filtering content. It includes groups of\n * items that can be checkboxes or radio items.\n *\n * @param id Optional unique identifier\n * @param groups The groups array contains the groups that will be displayed in the dropdown\n * @returns A filter dropdown.\n */\nexport default function FilterDropdown({ id, groups }: FilterDropdownProps) {\n return (\n
    \n {/* TODO: remove this once the DropDown Menu shadcn has an id prop */}\n \n \n \n \n \n {groups.map((group) => (\n
    \n {group.label}\n \n {group.items.map((item) => (\n
    \n {item.itemType === DropdownMenuItemType.Check ? (\n \n {item.label}\n \n ) : (\n \n {item.label}\n \n )}\n
    \n ))}\n
    \n \n
    \n ))}\n
    \n
    \n
    \n );\n}\n","interface NoExtensionsFoundProps {\n /** Optional unique identifier */\n id?: string;\n /** The message to display */\n message: string;\n}\n/**\n * This component displays a message to the user when no extensions are found in the marketplace.\n *\n * @param id Optional unique identifier\n * @param message The message to display.\n * @returns {JSX.Element} - Returns the message component that displays the message to the user.\n */\nexport default function NoExtensionsFound({ id, message }: NoExtensionsFoundProps) {\n return (\n
    \n
    \n

    {message}

    \n
    \n
    \n );\n}\n","import { CircleHelp, Link as LucideLink, User } from 'lucide-react';\nimport { NumberFormat } from 'platform-bible-utils';\n\n/** Interface that stores the parameters passed to the More Info component */\ninterface MoreInfoProps {\n /** Optional unique identifier */\n id?: string;\n /** The category of the extension */\n category: string;\n /** The number of downloads for the extension */\n downloads: Record;\n /** The languages supported by the extension */\n languages: string[];\n /** The URL to the more info page of the extension */\n moreInfoUrl: string;\n}\n/**\n * This component displays the more info section of the extension which includes the category,\n * number of downloads, languages, and links to the website and support\n *\n * @param id Optional unique identifier\n * @param category The category of the extension\n * @param downloads The number of downloads for the extension\n * @param languages The languages supported by the extension\n * @param moreInfoUrl The URL to the more info page of the extension\n * @returns {JSX.Element} - Returns the more info component that displays the category, number of\n * downloads, languages, and links to the website and support\n */\nexport default function MoreInfo({\n id,\n category,\n downloads,\n languages,\n moreInfoUrl,\n}: MoreInfoProps) {\n /**\n * This constant formats the number of downloads into a more readable format.\n *\n * @example 1000 -> 1K\n *\n * @example 1000000 -> 1M\n *\n * @returns The formatted number of downloads\n */\n const numberFormatted = new NumberFormat('en', {\n notation: 'compact',\n compactDisplay: 'short',\n }).format(Object.values(downloads).reduce((a: number, b: number) => a + b, 0));\n\n /** This function scrolls the window to the bottom of the page. */\n const handleScrollToBottom = () => {\n window.scrollTo(0, document.body.scrollHeight);\n };\n\n return (\n \n
    \n
    \n {category}\n
    \n CATEGORY\n
    \n
    \n
    \n
    \n \n {numberFormatted}\n
    \n USERS\n
    \n
    \n
    \n
    \n {languages.slice(0, 3).map((locale) => (\n \n {locale.toUpperCase()}\n \n ))}\n
    \n {languages.length > 3 && (\n handleScrollToBottom()}\n className=\"tw-text-xs tw-text-gray-500 tw-underline\"\n >\n +{languages.length - 3} more languages\n \n )}\n
    \n
    \n
    \n \n Website\n \n \n \n Support\n \n \n
    \n
    \n );\n}\n","import { useState } from 'react';\n\nexport type VersionInformation = {\n /** Date the version was published */\n date: string;\n /** Description of the changes in the version */\n description: string;\n};\n\n/** Type to store the version history information */\nexport type VersionHistoryType = Record;\n\n/** Interface that stores the parameters passed to the Version History component */\ninterface VersionHistoryProps {\n /** Optional unique identifier */\n id?: string;\n /** Object containing the versions mapped with their information */\n versionHistory: VersionHistoryType;\n}\n\n/**\n * Component to render the version history information shown in the footer component. Lists the 5\n * most recent versions, with the options to show all versions by pressing a button.\n *\n * @param versionHistory Object containing the versions mapped with their information\n * @param id Optional unique identifier\n * @returns Rendered version history for the Footer component\n */\nexport default function VersionHistory({ id, versionHistory }: VersionHistoryProps) {\n const [showAllVersions, setShowAllVersions] = useState(false);\n const currentDate = new Date();\n\n /**\n * Function to format the time string for the version history in the form of 'X year(s) ago'.\n *\n * @param dateString ISO Date string to determine the time string from\n * @returns Formatted time string\n */\n function formatTimeString(dateString: string) {\n const date = new Date(dateString);\n const dateDiff = new Date(currentDate.getTime() - date.getTime());\n const yearDiff = dateDiff.getUTCFullYear() - 1970;\n const monthDiff = dateDiff.getUTCMonth();\n const dayDiff = dateDiff.getUTCDate() - 1;\n\n // Determines how long ago the version was published\n let timeString = '';\n if (yearDiff > 0) {\n timeString = `${yearDiff.toString()} year${yearDiff === 1 ? '' : 's'} ago`;\n } else if (monthDiff > 0) {\n timeString = `${monthDiff.toString()} month${monthDiff === 1 ? '' : 's'} ago`;\n } else if (dayDiff === 0) {\n timeString = 'today';\n } else {\n timeString = `${dayDiff.toString()} day${dayDiff === 1 ? '' : 's'} ago`;\n }\n\n return timeString;\n }\n\n // Sorts the version history by version number\n const sortedEntries = Object.entries(versionHistory).sort((a, b) => b[0].localeCompare(a[0]));\n\n return (\n
    \n

    What`s New

    \n
      \n {(showAllVersions ? sortedEntries : sortedEntries.slice(0, 5)).map((entry) => (\n
      \n
      \n
    • \n {entry[1].description}\n
    • \n
      \n
      \n
      Version {entry[0]}
      \n
      {formatTimeString(entry[1].date)}
      \n
      \n
      \n ))}\n
    \n {sortedEntries.length > 5 && (\n setShowAllVersions(!showAllVersions)}\n className=\"tw-text-xs tw-text-gray-500 tw-underline\"\n >\n {showAllVersions ? 'Show Less Version History' : 'Show All Version History'}\n \n )}\n
    \n );\n}\n","import { useMemo } from 'react';\nimport { formatBytes } from 'platform-bible-utils';\nimport VersionHistory, { VersionHistoryType } from './version-history.component';\n\n/** Interface to store the parameters passed to the Footer component */\ninterface FooterProps {\n /** Optional unique identifier */\n id?: string;\n /** Name of the publisher */\n publisherDisplayName: string;\n /** Size of the extension file in bytes */\n fileSize: number;\n /** List of language codes supported by the extension */\n locales: string[];\n /** Object containing the version history mapped with their information */\n versionHistory: VersionHistoryType;\n}\n\n/**\n * Component to render the footer for the extension details which contains information on the\n * publisher, version history, languages, and file size.\n *\n * @param id Optional unique identifier\n * @param publisherDisplayName Name of the publisher\n * @param fileSize Size of the extension file in bytes\n * @param locales List of language codes supported by the extension\n * @param versionHistory Object containing the version history mapped with their information\n * @returns The rendered Footer component\n */\nexport default function Footer({\n id,\n publisherDisplayName,\n fileSize,\n locales,\n versionHistory,\n}: FooterProps) {\n /** Formats the file size into a human-readable format */\n const formattedFileSize = useMemo(() => formatBytes(fileSize), [fileSize]);\n\n /**\n * This function gets the display names of the languages based on the language codes.\n *\n * @param codes The list of language codes\n * @returns The list of language names\n */\n const getLanguageNames = (codes: string[]) => {\n const displayNames = new Intl.DisplayNames(navigator.language, { type: 'language' });\n return codes.map((code) => displayNames.of(code));\n };\n\n const languageNames = getLanguageNames(locales);\n\n return (\n
    \n
    \n \n
    \n
    \n

    Information

    \n
    \n

    \n Publisher\n {publisherDisplayName}\n Size\n {formattedFileSize}\n

    \n
    \n

    \n Languages\n {languageNames.join(', ')}\n

    \n
    \n
    \n
    \n
    \n
    \n );\n}\n","import { PlatformEvent, PlatformEventHandler } from 'platform-bible-utils';\nimport { useEffect } from 'react';\n\n/**\n * Adds an event handler to an event so the event handler runs when the event is emitted. Use\n * `papi.network.getNetworkEvent` to use a networked event with this hook.\n *\n * @param event The event to subscribe to.\n *\n * - If event is a `PlatformEvent`, that event will be used\n * - If event is undefined, the callback will not be subscribed. Useful if the event is not yet\n * available for example\n *\n * @param eventHandler The callback to run when the event is emitted\n *\n * WARNING: MUST BE STABLE - const or wrapped in useCallback. The reference must not be updated\n * every render\n */\nconst useEvent = (\n event: PlatformEvent | undefined,\n eventHandler: PlatformEventHandler,\n) => {\n useEffect(() => {\n // Do nothing if the event is not provided (in case the event is not yet available, for example)\n if (!event) return () => {};\n\n const unsubscriber = event(eventHandler);\n return () => {\n unsubscriber();\n };\n }, [event, eventHandler]);\n};\nexport default useEvent;\n","import { useCallback, useEffect } from 'react';\nimport { PlatformEvent, PlatformEventAsync, PlatformEventHandler } from 'platform-bible-utils';\nimport usePromise from './use-promise.hook';\n\nconst noopUnsubscriber = () => false;\n\n/**\n * Adds an event handler to an asynchronously subscribing/unsubscribing event so the event handler\n * runs when the event is emitted. Use `papi.network.getNetworkEvent` to use a networked event with\n * this hook.\n *\n * @param event The asynchronously (un)subscribing event to subscribe to.\n *\n * - If event is a `PlatformEvent` or `PlatformEventAsync`, that event will be used\n * - If event is undefined, the callback will not be subscribed. Useful if the event is not yet\n * available for example\n *\n * @param eventHandler The callback to run when the event is emitted\n *\n * WARNING: MUST BE STABLE - const or wrapped in useCallback. The reference must not be updated\n * every render\n */\nconst useEventAsync = (\n event: PlatformEvent | PlatformEventAsync | undefined,\n eventHandler: PlatformEventHandler,\n) => {\n // Subscribe to the event asynchronously\n const [unsubscribe] = usePromise(\n useCallback(async () => {\n // Do nothing if the event is not provided (in case the event is not yet available, for example)\n if (!event) return noopUnsubscriber;\n\n // Wrap subscribe and unsubscribe in promises to allow normal events to be used as well\n const unsub = await Promise.resolve(event(eventHandler));\n return async () => unsub();\n }, [eventHandler, event]),\n noopUnsubscriber,\n // We want the unsubscriber to return to default value immediately upon changing subscription\n // So the useEffect below will unsubscribe asap\n { preserveValue: false },\n );\n\n // Unsubscribe from the event asynchronously (but we aren't awaiting the unsub)\n useEffect(() => {\n return () => {\n if (unsubscribe !== noopUnsubscriber) {\n unsubscribe();\n }\n };\n }, [unsubscribe]);\n};\n\nexport default useEventAsync;\n"],"names":["twMergeCustom","extendTailwindMerge","cn","inputs","clsx","Input","React","className","type","props","ref","jsx","BookChapterInput","forwardRef","handleSearch","handleKeyDown","handleOnClick","handleSubmit","jsxs","ShadInput","event","e","History","P","R","t","s","n","N","B","O","S","K","g","k","x","T","X","V","w","L","G","A","H","C","I","y","q","U","m","l","h","c","E","D","i","a","o","u","v","f","d","b","J","DropdownMenu","DropdownMenuPrimitive","DropdownMenuTrigger","DropdownMenuGroup","DropdownMenuPortal","DropdownMenuSub","DropdownMenuRadioGroup","DropdownMenuSubTrigger","inset","children","ChevronRight","DropdownMenuSubContent","DropdownMenuContent","sideOffset","DropdownMenuItem","DropdownMenuCheckboxItem","checked","Check","DropdownMenuRadioItem","Circle","DropdownMenuLabel","DropdownMenuSeparator","DropdownMenuShortcut","BookMenuItem","bookId","handleSelectBook","isSelected","handleHighlightBook","bookType","ShadDropdownMenuItem","Canon","ChapterSelect","handleSelectChapter","endChapter","activeChapter","highlightedChapter","handleHighlightedChapter","chapters","_","handleMouse","useCallback","chapterNumber","chapter","GoToMenuItem","handleSort","handleLocationHistory","handleBookmarks","ShadDropdownMenuLabel","ArrowDownWideNarrow","Clock","Bookmark","ALL_BOOK_IDS","BOOK_TYPE_LABELS","BOOK_TYPE_ARRAY","SCROLL_OFFSET","SEARCH_QUERY_FORMATS","fetchGroupedBooks","fetchEndChapter","getChaptersForBook","getAllEnglishNames","isValidBookEnglishName","bookName","getBookIdFromEnglishName","formattedBookName","BookChapterControl","scrRef","searchQuery","setSearchQuery","useState","selectedBookId","setSelectedBookId","setHighlightedChapter","highlightedBookId","setHighlightedBookId","isContentOpen","setIsContentOpen","isContentOpenDelayed","setIsContentOpenDelayed","inputRef","useRef","contentRef","menuItemRef","fetchFilteredBooks","englishNameLowerCase","normalizedQuery","handleSearchInput","searchString","shouldPreventAutoClosing","controlMenuState","open","updateReference","shouldClose","verse","handleInputSubmit","format","matches","book","englishName","handleKeyDownInput","handleKeyDownContent","key","handleKeyDownMenuItem","chapterOffSet","useEffect","useLayoutEffect","scrollTimeout","scrollPosition","ShadDropdownMenu","ShadDropdownMenuTrigger","ShadDropdownMenuContent","bookTypeIndex","element","ShadDropdownMenuSeparator","buttonVariants","cva","Button","variant","size","asChild","Slot","labelVariants","Label","LabelPrimitive","RadioGroup","RadioGroupPrimitive","RadioGroupItem","Popover","PopoverPrimitive","PopoverTrigger","PopoverContent","align","DialogPortal","DialogPrimitive","DialogOverlay","DialogContent","DialogTitle","DialogDescription","Command","CommandPrimitive","CommandInput","Search","CommandList","CommandEmpty","CommandGroup","CommandSeparator","CommandItem","getOptionLabelDefault","option","ComboBox","id","options","value","onChange","getOptionLabel","buttonPlaceholder","textPlaceholder","commandEmptyMessage","buttonVariant","dir","isDisabled","setOpen","ChevronsUpDown","ChapterRangeSelector","startChapter","handleSelectStartChapter","handleSelectEndChapter","chapterCount","chapterOptions","useMemo","index","Fragment","BookSelectionMode","BOOK_SELECTOR_STRING_KEYS","localizeString","strings","BookSelector","handleBookSelectionModeChange","currentBookName","onSelectBooks","selectedBookIds","localizedStrings","currentBookText","chooseText","chooseBooksText","bookSelectionMode","setBookSelectionMode","onSelectionModeChange","newMode","DataTableViewOptions","table","FilterIcon","column","Select","SelectPrimitive","SelectGroup","SelectValue","SelectTrigger","ChevronDown","SelectScrollUpButton","ChevronUp","SelectScrollDownButton","SelectContent","position","SelectLabel","SelectItem","SelectSeparator","DataTablePagination","pageSize","ArrowLeftIcon","ChevronLeftIcon","ChevronRightIcon","ArrowRightIcon","Table","stickyHeader","TableHeader","TableBody","TableFooter","TableRow","TableHead","TableCell","TableCaption","DataTable","columns","data","enablePagination","showPaginationControls","showColumnVisibilityControls","onRowClickHandler","sorting","setSorting","columnFilters","setColumnFilters","columnVisibility","setColumnVisibility","rowSelection","setRowSelection","useReactTable","getCoreRowModel","getPaginationRowModel","getSortedRowModel","getFilteredRowModel","headerGroup","header","flexRender","_a","row","cell","OccurrencesTable","occurrenceData","setScriptureReference","referenceHeaderText","occurrenceHeaderText","occurrences","uniqueOccurrences","occurrence","uniqueOccurrence","deepEqual","Checkbox","CheckboxPrimitive","getLinesFromUSFM","text","getNumberFromUSFM","regex","match","getBookNumFromId","getStatusForItem","item","approvedItems","unapprovedItems","toggleVariants","Toggle","TogglePrimitive","ToggleGroupContext","ToggleGroup","ToggleGroupPrimitive","ToggleGroupItem","context","getSortingIcon","sortDirection","ArrowUpIcon","ArrowDownIcon","ArrowUpDownIcon","inventoryItemColumn","itemLabel","inventoryAdditionalItemColumn","additionalItemLabel","additionalItemIndex","inventoryCountColumn","countLabel","statusChangeHandler","changedItems","newStatus","onApprovedItemsChange","onUnapprovedItemsChange","newApprovedItems","validItem","newUnapprovedItems","unapprovedItem","inventoryStatusColumn","statusLabel","status","CircleCheckIcon","CircleXIcon","CircleHelpIcon","INVENTORY_STRING_KEYS","filterItemData","itemData","statusFilter","textFilter","filteredItemData","createTableData","scriptureRef","itemRegex","tableData","currentBook","currentChapter","currentVerse","line","items","itemIndex","existingItem","tableEntry","newReference","substring","newItem","Inventory","scriptureReference","extractItems","additionalItemsLabels","scope","onScopeChange","allItemsText","approvedItemsText","unapprovedItemsText","unknownItemsText","scopeBookText","scopeChapterText","scopeVerseText","filterText","showAdditionalItemsText","showAdditionalItems","setShowAdditionalItems","setStatusFilter","setTextFilter","selectedItem","setSelectedItem","reducedTableData","newTableData","firstItem","existingEntry","newTableEntry","filteredTableData","allColumns","numberOfAdditionalItems","additionalColumns","_b","rowClickHandler","newSelection","handleScopeChange","handleStatusFilterChange","SearchBar","onSearch","placeholder","isFullWidth","handleInputChange","VerticalTabs","TabsPrimitive","VerticalTabsList","VerticalTabsTrigger","VerticalTabsContent","NavigationContentSearch","tabList","searchPlaceholder","headerTitle","isSearchBarFullWidth","direction","tab","scrBookColId","scrRefColId","typeColId","detailsColId","defaultScrRefColumnName","defaultScrBookGroupName","defaultTypeColumnName","defaultDetailsColumnName","getColumns","colInfo","showSourceColumn","showSrcCol","info","formatScrRef","compareScrRefs","toRefOrRange","scriptureSelection","offsetStart","offsetEnd","scrRefToBBBCCCVVV","getRowKey","ScriptureResultsViewer","sources","showColumnHeaders","scriptureReferenceColumnName","scriptureBookGroupName","typeColumnName","detailsColumnName","onRowSelected","grouping","setGrouping","scriptureResults","source","getExpandedRowModel","getGroupedRowModel","selectedRows","keys","selectedRow","scrBookGroupName","typeGroupName","groupingOptions","handleSelectChange","selectedGrouping","handleRowClick","getEvenOrOddBandingStyle","getIndent","groupingState","rowIndex","ChevronLeft","DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS","getLocalizeKeyForScrollGroupId","ScrollGroupSelector","availableScrollGroupIds","scrollGroupId","onChangeScrollGroupId","localizedStringsDefaulted","localizedStringKey","localizedStringValue","newScrollGroupString","scrollGroupOptionId","Separator","orientation","decorative","SeparatorPrimitive","SettingsList","SettingsListItem","primary","secondary","isLoading","loadingMessage","SettingsListHeader","includeSeparator","Checklist","listItems","selectedListItems","handleSelectListItem","createLabel","_interopRequireDefault","obj","module","chainPropTypes","propType1","propType2","args","_extends","target","isPlainObject","prototype","deepClone","output","deepmerge","p","r","z","reactIs_production_min","hasSymbol","REACT_ELEMENT_TYPE","REACT_PORTAL_TYPE","REACT_FRAGMENT_TYPE","REACT_STRICT_MODE_TYPE","REACT_PROFILER_TYPE","REACT_PROVIDER_TYPE","REACT_CONTEXT_TYPE","REACT_ASYNC_MODE_TYPE","REACT_CONCURRENT_MODE_TYPE","REACT_FORWARD_REF_TYPE","REACT_SUSPENSE_TYPE","REACT_SUSPENSE_LIST_TYPE","REACT_MEMO_TYPE","REACT_LAZY_TYPE","REACT_BLOCK_TYPE","REACT_FUNDAMENTAL_TYPE","REACT_RESPONDER_TYPE","REACT_SCOPE_TYPE","isValidElementType","typeOf","object","$$typeof","$$typeofType","AsyncMode","ConcurrentMode","ContextConsumer","ContextProvider","Element","ForwardRef","Lazy","Memo","Portal","Profiler","StrictMode","Suspense","hasWarnedAboutDeprecatedIsAsyncMode","isAsyncMode","isConcurrentMode","isContextConsumer","isContextProvider","isElement","isForwardRef","isFragment","isLazy","isMemo","isPortal","isProfiler","isStrictMode","isSuspense","reactIs_development","reactIsModule","require$$0","require$$1","getOwnPropertySymbols","hasOwnProperty","propIsEnumerable","toObject","val","shouldUseNative","test1","test2","order2","test3","letter","objectAssign","from","to","symbols","ReactPropTypesSecret","ReactPropTypesSecret_1","has","printWarning","loggedTypeFailures","message","checkPropTypes","typeSpecs","values","location","componentName","getStack","typeSpecName","error","err","ex","stack","checkPropTypes_1","ReactIs","assign","require$$2","require$$3","require$$4","emptyFunctionThatReturnsNull","factoryWithTypeCheckers","isValidElement","throwOnDirectAccess","ITERATOR_SYMBOL","FAUX_ITERATOR_SYMBOL","getIteratorFn","maybeIterable","iteratorFn","ANONYMOUS","ReactPropTypes","createPrimitiveTypeChecker","createAnyTypeChecker","createArrayOfTypeChecker","createElementTypeChecker","createElementTypeTypeChecker","createInstanceTypeChecker","createNodeChecker","createObjectOfTypeChecker","createEnumTypeChecker","createUnionTypeChecker","createShapeTypeChecker","createStrictShapeTypeChecker","is","PropTypeError","createChainableTypeChecker","validate","manualPropTypeCallCache","manualPropTypeWarningCount","checkType","isRequired","propName","propFullName","secret","cacheKey","chainedCheckType","expectedType","propValue","propType","getPropType","preciseType","getPreciseType","typeChecker","expectedClass","expectedClassName","actualClassName","getClassName","expectedValues","valuesString","arrayOfTypeCheckers","checker","getPostfixForTypeWarning","expectedTypes","checkerResult","expectedTypesMessage","isNode","invalidValidatorError","shapeTypes","allKeys","iterator","step","entry","isSymbol","emptyFunction","emptyFunctionWithReset","factoryWithThrowingShims","shim","getShim","propTypesModule","isClassComponent","elementType","acceptingRef","safePropName","warningHint","elementAcceptingRef","PropTypes","elementAcceptingRef$1","specialProperty","exactProp","propTypes","unsupportedProps","prop","formatMuiErrorMessage","code","url","REACT_SERVER_CONTEXT_TYPE","REACT_OFFSCREEN_TYPE","enableScopeAPI","enableCacheElement","enableTransitionTracing","enableLegacyHidden","enableDebugTracing","REACT_MODULE_REFERENCE","SuspenseList","hasWarnedAboutDeprecatedIsConcurrentMode","isSuspenseList","fnNameMatchRegex","getFunctionName","fn","getFunctionComponentName","Component","fallback","getWrappedName","outerType","innerType","wrapperName","functionName","getDisplayName","HTMLElementType","refType","refType$1","capitalize","string","_formatMuiErrorMessage","createChainedFunction","funcs","acc","func","debounce","wait","timeout","debounced","later","deprecatedPropType","validator","reason","componentNameSafe","propFullNameSafe","isMuiElement","muiNames","_muiName","_element$type","ownerDocument","node","ownerWindow","requirePropFactory","componentNameInError","prevPropTypes","requiredProp","defaultTypeChecker","typeCheckerResult","setRef","useEnhancedEffect","useEnhancedEffect$1","globalId","useGlobalId","idOverride","defaultId","setDefaultId","maybeReactUseId","useId","reactId","unsupportedProp","useControlled","controlled","defaultProp","name","state","isControlled","valueState","setValue","defaultValue","setValueIfUncontrolled","newValue","useEventCallback","useForkRef","refs","instance","UNINITIALIZED","useLazyRef","init","initArg","EMPTY","useOnMount","Timeout","delay","useTimeout","hadKeyboardEvent","hadFocusVisibleRecently","hadFocusVisibleRecentlyTimeout","inputTypesWhitelist","focusTriggersKeyboardModality","tagName","handlePointerDown","handleVisibilityChange","prepare","doc","isFocusVisible","useIsFocusVisible","isFocusVisibleRef","handleBlurVisible","handleFocusVisible","resolveProps","defaultProps","defaultSlotProps","slotProps","slotPropName","composeClasses","slots","getUtilityClass","classes","slot","utilityClass","defaultGenerator","createClassNameGenerator","generate","generator","ClassNameGenerator","ClassNameGenerator$1","globalStateClasses","generateUtilityClass","globalStatePrefix","globalStateClass","generateUtilityClasses","result","clamp","min","max","_objectWithoutPropertiesLoose","excluded","sourceKeys","_excluded","sortBreakpointsValues","breakpointsAsArray","breakpoint1","breakpoint2","createBreakpoints","breakpoints","unit","other","sortedValues","up","down","between","start","end","endIndex","only","not","keyIndex","shape","shape$1","responsivePropType","responsivePropType$1","merge","defaultBreakpoints","handleBreakpoints","styleFromPropValue","theme","themeBreakpoints","breakpoint","mediaKey","cssKey","createEmptyBreakpointObject","breakpointsInput","_breakpointsInput$key","breakpointStyleKey","removeUnusedBreakpoints","breakpointKeys","style","breakpointOutput","getPath","path","checkVars","getStyleValue","themeMapping","transform","propValueFinal","userValue","cssProperty","themeKey","memoize","cache","arg","properties","directions","aliases","getCssProperties","property","marginKeys","paddingKeys","spacingKeys","createUnaryUnit","_getPath","themeSpacing","abs","createUnarySpacing","getValue","transformer","transformed","getStyleFromPropValue","cssProperties","resolveCssProperty","margin","padding","createSpacing","spacingInput","spacing","argsInput","argument","compose","styles","handlers","borderTransform","createBorderStyle","border","borderTop","borderRight","borderBottom","borderLeft","borderColor","borderTopColor","borderRightColor","borderBottomColor","borderLeftColor","outline","outlineColor","borderRadius","gap","columnGap","rowGap","gridColumn","gridRow","gridAutoFlow","gridAutoColumns","gridAutoRows","gridTemplateColumns","gridTemplateRows","gridTemplateAreas","gridArea","paletteTransform","color","bgcolor","backgroundColor","sizingTransform","width","maxWidth","_props$theme","_props$theme2","breakpointsValues","minWidth","height","maxHeight","minHeight","boxSizing","defaultSxConfig","defaultSxConfig$1","objectsHaveSameKeys","objects","union","callIfFn","maybeFn","unstable_createStyleFunctionSx","getThemeValue","config","styleFunctionSx","_theme$unstable_sxCon","sx","traverse","sxInput","sxObject","emptyBreakpoints","breakpointsKeys","css","styleKey","styleFunctionSx$1","applyStyles","createTheme","paletteInput","shapeInput","muiTheme","isObjectEmpty","useTheme","defaultTheme","contextTheme","ThemeContext","systemDefaultTheme","useThemeWithoutDefault","_excluded2","_excluded3","isEmpty","isStringTag","tag","shouldForwardProp","lowercaseFirstLetter","resolveTheme","themeId","defaultOverridesResolver","processStyleArg","callableStyle","_ref","ownerState","resolvedStylesArg","resolvedStyle","variants","isMatch","createStyled","input","rootShouldForwardProp","slotShouldForwardProp","systemSx","inputOptions","processStyles","componentSlot","inputSkipVariantsResolver","inputSkipSx","overridesResolver","skipVariantsResolver","skipSx","label","shouldForwardPropOption","defaultStyledResolver","styledEngineStyled","transformStyleArg","stylesArg","muiStyledResolver","styleArg","expressions","transformedStyleArg","expressionsWithDefaultTheme","styleOverrides","resolvedStyleOverrides","slotKey","slotStyle","_theme$components","themeVariants","numOfCustomFnsApplied","placeholders","displayName","getThemeProps","params","useThemeProps","clampWrapper","hexToRgb","re","colors","decomposeColor","marker","colorSpace","recomposeColor","hslToRgb","rgb","getLuminance","getContrastRatio","foreground","background","lumA","lumB","alpha","darken","coefficient","lighten","createMixins","mixins","common","common$1","grey","grey$1","purple","purple$1","red","red$1","orange","orange$1","blue","blue$1","lightBlue","lightBlue$1","green","green$1","light","dark","addLightOrDark","intent","shade","tonalOffset","tonalOffsetLight","tonalOffsetDark","getDefaultPrimary","mode","getDefaultSecondary","getDefaultError","getDefaultInfo","getDefaultSuccess","getDefaultWarning","createPalette","palette","contrastThreshold","success","warning","getContrastText","contrastText","contrast","augmentColor","mainShade","lightShade","darkShade","modes","round","caseAllCaps","defaultFontFamily","createTypography","typography","fontFamily","fontSize","fontWeightLight","fontWeightRegular","fontWeightMedium","fontWeightBold","htmlFontSize","allVariants","pxToRem2","coef","pxToRem","buildVariant","fontWeight","lineHeight","letterSpacing","casing","shadowKeyUmbraOpacity","shadowKeyPenumbraOpacity","shadowAmbientShadowOpacity","createShadow","px","shadows","shadows$1","easing","duration","formatMs","milliseconds","getAutoHeightDuration","constant","createTransitions","inputTransitions","mergedEasing","mergedDuration","durationOption","easingOption","isString","isNumber","animatedProp","zIndex","zIndex$1","mixinsInput","transitionsInput","typographyInput","systemTheme","systemCreateTheme","stateClasses","component","child","stateClass","defaultTheme$1","THEME_ID","systemUseThemeProps","styled","styled$1","getSvgIconUtilityClass","useUtilityClasses","SvgIconRoot","_theme$transitions","_theme$transitions$cr","_theme$transitions2","_theme$typography","_theme$typography$pxT","_theme$typography2","_theme$typography2$px","_theme$typography3","_theme$typography3$px","_palette$ownerState$c","_palette","_palette2","_palette3","SvgIcon","inProps","htmlColor","inheritViewBox","titleAccess","viewBox","hasSvgAsChild","more","_jsxs","_jsx","SvgIcon$1","createSvgIcon","unstable_ClassNameGenerator","exports","_utils","ArrowRight","default_1","_createSvgIcon","_jsxRuntime","isHostComponent","appendOwnerState","otherProps","defaultContextValue","ClassNameConfiguratorContext","useClassNamesOverride","disableDefaultClasses","extractEventHandlers","excludeKeys","resolveComponentProps","componentProps","slotState","omitEventHandlers","mergeSlotProps","parameters","getSlotProps","additionalProps","externalSlotProps","externalForwardedProps","joinedClasses","mergedStyle","eventHandlers","componentsPropsWithoutEventHandlers","otherPropsWithoutEventHandlers","internalSlotProps","useSlotProps","_parameters$additiona","skipResolvingSlotProps","rest","resolvedComponentsProps","mergedProps","internalRef","GLOBAL_CLASS_PREFIX","buildStateClass","buildSlotClass","getContainer","container","forwardedRef","disablePortal","mountNode","setMountNode","handleRef","newProps","ReactDOM","top","bottom","right","left","auto","basePlacements","clippingParents","viewport","popper","reference","variationPlacements","placement","placements","beforeRead","read","afterRead","beforeMain","main","afterMain","beforeWrite","write","afterWrite","modifierPhases","getNodeName","getWindow","OwnElement","isHTMLElement","isShadowRoot","attributes","effect","_ref2","initialStyles","styleProperties","attribute","applyStyles$1","getBasePlacement","getUAString","uaData","isLayoutViewport","getBoundingClientRect","includeScale","isFixedStrategy","clientRect","scaleX","scaleY","visualViewport","addVisualOffsets","getLayoutRect","contains","parent","rootNode","next","getComputedStyle","isTableElement","getDocumentElement","getParentNode","getTrueOffsetParent","getContainingBlock","isFirefox","isIE","elementCss","currentNode","getOffsetParent","window","offsetParent","getMainAxisFromPlacement","within","mathMax","mathMin","withinMaxClamp","getFreshSideObject","mergePaddingObject","paddingObject","expandToHashMap","hashMap","toPaddingObject","arrow","_state$modifiersData$","arrowElement","popperOffsets","basePlacement","axis","isVertical","len","arrowRect","minProp","maxProp","endDiff","startDiff","arrowOffsetParent","clientSize","centerToReference","center","offset","axisProp","_options$element","arrow$1","getVariation","unsetSides","roundOffsetsByDPR","win","dpr","mapToStyles","_Object$assign2","popperRect","variation","offsets","gpuAcceleration","adaptive","roundOffsets","isFixed","_offsets$x","_offsets$y","_ref3","hasX","hasY","sideX","sideY","heightProp","widthProp","offsetY","offsetX","commonStyles","_ref4","_Object$assign","computeStyles","_ref5","_options$gpuAccelerat","_options$adaptive","_options$roundOffsets","computeStyles$1","passive","_options$scroll","scroll","_options$resize","resize","scrollParents","scrollParent","eventListeners","hash","getOppositePlacement","matched","getOppositeVariationPlacement","getWindowScroll","scrollLeft","scrollTop","getWindowScrollBarX","getViewportRect","strategy","html","layoutViewport","getDocumentRect","_element$ownerDocumen","winScroll","body","isScrollParent","_getComputedStyle","overflow","overflowX","overflowY","getScrollParent","listScrollParents","list","isBody","updatedList","rectToClientRect","rect","getInnerBoundingClientRect","getClientRectFromMixedType","clippingParent","getClippingParents","canEscapeClipping","clipperElement","getClippingRect","boundary","rootBoundary","mainClippingParents","firstClippingParent","clippingRect","accRect","computeOffsets","commonX","commonY","mainAxis","detectOverflow","_options","_options$placement","_options$strategy","_options$boundary","_options$rootBoundary","_options$elementConte","elementContext","_options$altBoundary","altBoundary","_options$padding","altContext","clippingClientRect","referenceClientRect","popperClientRect","elementClientRect","overflowOffsets","offsetData","multiply","computeAutoPlacement","flipVariations","_options$allowedAutoP","allowedAutoPlacements","allPlacements","allowedPlacements","overflows","getExpandedFallbackPlacements","oppositePlacement","flip","_options$mainAxis","checkMainAxis","_options$altAxis","checkAltAxis","specifiedFallbackPlacements","_options$flipVariatio","preferredPlacement","isBasePlacement","fallbackPlacements","referenceRect","checksMap","makeFallbackChecks","firstFittingPlacement","_basePlacement","isStartVariation","mainVariationSide","altVariationSide","checks","check","numberOfChecks","_loop","_i","fittingPlacement","_ret","flip$1","getSideOffsets","preventedOffsets","isAnySideFullyClipped","side","hide","referenceOverflow","popperAltOverflow","referenceClippingOffsets","popperEscapeOffsets","isReferenceHidden","hasPopperEscaped","hide$1","distanceAndSkiddingToXY","rects","invertDistance","skidding","distance","_options$offset","_data$state$placement","offset$1","popperOffsets$1","getAltAxis","preventOverflow","_options$tether","tether","_options$tetherOffset","tetherOffset","altAxis","tetherOffsetValue","normalizedTetherOffsetValue","offsetModifierState","_offsetModifierState$","mainSide","altSide","additive","minLen","maxLen","arrowPaddingObject","arrowPaddingMin","arrowPaddingMax","arrowLen","minOffset","maxOffset","clientOffset","offsetModifierValue","tetherMin","tetherMax","preventedOffset","_offsetModifierState$2","_mainSide","_altSide","_offset","_len","_min","_max","isOriginSide","_offsetModifierValue","_tetherMin","_tetherMax","_preventedOffset","preventOverflow$1","getHTMLElementScroll","getNodeScroll","isElementScaled","getCompositeRect","elementOrVirtualElement","isOffsetParentAnElement","offsetParentIsScaled","documentElement","order","modifiers","map","visited","modifier","sort","requires","dep","depModifier","orderModifiers","orderedModifiers","phase","pending","resolve","mergeByName","merged","current","existing","DEFAULT_OPTIONS","areValidElements","_key","popperGenerator","generatorOptions","_generatorOptions","_generatorOptions$def","defaultModifiers","_generatorOptions$def2","defaultOptions","effectCleanupFns","isDestroyed","setOptionsAction","cleanupModifierEffects","runModifierEffects","_state$elements","_state$orderedModifie","_state$orderedModifie2","_ref$options","cleanupFn","noopFn","createPopper","COMPONENT_NAME","getPopperUtilityClass","flipPlacement","resolveAnchorEl","anchorEl","isVirtualElement","defaultPopperOptions","PopperTooltip","_slots$root","initialPlacement","popperOptions","popperRefProp","TransitionProps","tooltipRef","ownRef","popperRef","handlePopperRef","handlePopperRefRef","rtlPlacement","setPlacement","resolvedAnchorElement","setResolvedAnchorElement","handlePopperUpdate","box","popperModifiers","childProps","Root","rootProps","Popper","containerProp","keepMounted","transition","exited","setExited","handleEnter","handleExited","resolvedAnchorEl","display","transitionProps","useThemeSystem","_setPrototypeOf","_inheritsLoose","subClass","superClass","setPrototypeOf","timeoutsShape","TransitionGroupContext","forceReflow","UNMOUNTED","EXITED","ENTERING","ENTERED","EXITING","Transition","_React$Component","_this","parentGroup","appear","initialStatus","prevState","nextIn","_proto","prevProps","nextStatus","exit","enter","mounting","_this2","appearing","maybeNode","maybeAppearing","timeouts","enterTimeout","_this3","nextState","callback","_this4","active","handler","doesNotHaveTimeoutOrListener","maybeNextCallback","_this$props","pt","noop","Transition$1","reflow","getTransitionProps","_style$transitionDura","_style$transitionTimi","getScale","isWebKit154","Grow","addEndListener","inProp","onEnter","onEntered","onEntering","onExit","onExited","onExiting","TransitionComponent","timer","autoTimeout","nodeRef","normalizedTransitionCallback","maybeIsAppearing","handleEntering","isAppearing","transitionDuration","transitionTimingFunction","handleEntered","handleExiting","handleExit","Grow$1","PopperRoot","BasePopper","components","componentsProps","RootComponent","Popper$1","getTooltipUtilityClass","tooltipClasses","tooltipClasses$1","disableInteractive","touch","TooltipPopper","TooltipTooltip","TooltipArrow","hystersisOpen","hystersisTimer","cursorPosition","composeEventHandler","eventHandler","Tooltip","_slots$popper","_slots$transition","_slots$tooltip","_slots$arrow","_slotProps$popper","_ref6","_slotProps$popper2","_slotProps$transition","_slotProps$tooltip","_ref7","_slotProps$tooltip2","_slotProps$arrow","_ref8","_slotProps$arrow2","childrenProp","describeChild","disableFocusListener","disableHoverListener","disableInteractiveProp","disableTouchListener","enterDelay","enterNextDelay","enterTouchDelay","followCursor","idProp","leaveDelay","leaveTouchDelay","onClose","onOpen","openProp","PopperComponentProp","PopperProps","title","TransitionComponentProp","isRtl","childNode","setChildNode","arrowRef","setArrowRef","ignoreNonTouchEvents","closeTimer","enterTimer","leaveTimer","touchTimer","openState","setOpenState","prevUserSelect","stopTouchInteraction","handleOpen","handleClose","handleLeave","focusVisibleRef","setChildIsFocusVisible","handleBlur","handleFocus","detectTouchStart","childrenProps","handleMouseOver","handleMouseLeave","handleTouchStart","handleTouchEnd","nativeEvent","handleMouseMove","nameOrDescProps","titleIsString","interactiveWrapperListeners","_PopperProps$popperOp","tooltipModifiers","PopperComponent","TooltipComponent","ArrowComponent","popperProps","tooltipProps","tooltipArrowProps","TransitionPropsInner","Tooltip$1","getIcon","icon","menuLabel","leading","MuiListItemIcon","MenuItem","onClick","tooltip","allowForLeadingIcons","iconPathBefore","iconPathAfter","hasAutoFocus","isDense","isSubMenuParent","hasDisabledGutters","hasDivider","focusVisibleClassName","menuItem","MuiMenuItem","MuiListItemText","getAllGroups","menuDefinition","SubMenu","setAnchorEl","parentMenuItem","parentItemProps","handleParentMenuItemClick","renderSubMenuItems","includedGroups","group","GroupedMenuItemList","Menu","getOrderedGroupItems","groupId","allItems","menuProps","commandHandler","groupsToInclude","sortedGroups","itemArray","allowSpaceForLeadingIcons","createMenuItemProps","isLastItemInGroup","divKey","itemInfo","menuItemProps","TopLevelMenu","columnId","MenuColumn","metadata","Grid","List","GridMenu","multiColumnMenu","sortedColumns","columnNumbers","columnName","col","getUsePromiseOptionsDefaults","usePromise","promiseFactoryCallback","defaultValueRef","optionsDefaultedRef","setIsLoading","promiseIsCurrent","MenuIcon","HamburgerMenuButton","menuProvider","normalMenu","fullMenu","containerRef","ariaLabelPrefix","isMenuOpen","setMenuOpen","showFullMenu","setShowFullMenu","handleMenuItemClick","handleMenuButtonClick","prevIsOpen","isOpening","menuCommandHandler","command","setOffset","normalMenuData","fullMenuData","menu","IconButton","Drawer","isTooltipSuppressed","adjustMarginToAlignToEdge","MuiIconButton","Spinner","LoaderCircle","TextField","hasError","helperText","onFocus","onBlur","ShadLabel","Toolbar","AppBar","MuiToolbar","alertVariants","Alert","AlertTitle","AlertDescription","Card","CardHeader","CardTitle","CardDescription","CardContent","CardFooter","Sonner","Toaster","Slider","SliderPrimitive","Switch","SwitchPrimitives","Tabs","TabsList","TabsTrigger","TabsContent","InstallButton","isInstalling","handleClick","buttonText","Download","EnableButton","isEnabling","DisableButton","isDisabling","UpdateButton","isUpdating","MarkdownRenderer","markdown","anchorTarget","Markdown","FilterButton","Filter","DropdownMenuItemType","DropdownMenuItemType2","FilterDropdown","groups","NoExtensionsFound","MoreInfo","category","downloads","languages","moreInfoUrl","numberFormatted","NumberFormat","handleScrollToBottom","User","locale","LucideLink","CircleHelp","VersionHistory","versionHistory","showAllVersions","setShowAllVersions","currentDate","formatTimeString","dateString","date","dateDiff","yearDiff","monthDiff","dayDiff","timeString","sortedEntries","Footer","publisherDisplayName","fileSize","locales","formattedFileSize","formatBytes","languageNames","codes","displayNames","useEvent","unsubscriber","noopUnsubscriber","useEventAsync","unsubscribe","unsub"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAGA,MAAMA,KAAgBC,GAAoB,EAAE,QAAQ,MAAO,CAAA;AAyDpD,SAASC,KAAMC,GAAsB;AACnC,SAAAH,GAAcI,GAAKD,CAAM,CAAC;AACnC;ACzDO,MAAME,KAAQC,EAAM;AAAA,EACzB,CAAC,EAAE,WAAAC,GAAW,MAAAC,GAAM,GAAGC,EAAA,GAASC,MAE5B,gBAAAC;AAAA,IAAC;AAAA,IAAA;AAAA,MACC,MAAAH;AAAA,MACA,WAAWN;AAAA,QACT;AAAA,QACAK;AAAA,MACF;AAAA,MACA,KAAAG;AAAA,MAEC,GAAGD;AAAA,IAAA;AAAA,EAAA;AAIZ;AACAJ,GAAM,cAAc;ACNpB,MAAMO,KAAmBC;AAAA,EACvB,CACE,EAAE,cAAAC,GAAc,eAAAC,GAAe,eAAAC,GAAe,cAAAC,GAAc,GAAGR,EAAM,GACrEC,MAGE,gBAAAQ,EAAC,OAAI,EAAA,WAAU,eACb,UAAA;AAAA,IAAA,gBAAAP;AAAA,MAACQ;AAAAA,MAAA;AAAA,QACE,GAAGV;AAAA,QACJ,MAAK;AAAA,QACL,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;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA;AAAA;AAAA,EAGA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA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78,79,80,81,82,83,84,85,86,87,88,89,90,91,92,93,94,95,96,97,98,99,100,101,102,103,104,105,106,107,108,109,110,111,112,113,114,115,116,117,118,119,120,121,122,123,124,125,126,127,128,129,130,131,132,133,134,135,136,137,138,139,140,141,142,143,144,145,146,147,148,149,150,151,152,153,154,155,156,157,158,159,160,161,162,163,164,165,166,167,168,169,170,171,172,173,174,175,176,177,178,179,180,181,182,183,184,185,186,187,188,189,190,191,192,193,194,195,196,197,198,199,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,221]} \ No newline at end of file +{"version":3,"file":"index.js","sources":["../src/utils/shadcn-ui.util.ts","../src/components/shadcn-ui/input.tsx","../src/components/advanced/book-chapter-control/book-chapter-input.component.tsx","../../../node_modules/@sillsdev/scripture/dist/index.es.js","../src/components/shadcn-ui/dropdown-menu.tsx","../src/components/advanced/book-chapter-control/book-menu-item.component.tsx","../src/components/advanced/book-chapter-control/chapter-select.component.tsx","../src/components/advanced/book-chapter-control/go-to-menu-item.component.tsx","../src/components/advanced/book-chapter-control/book-chapter-control.component.tsx","../src/components/shadcn-ui/button.tsx","../src/components/shadcn-ui/label.tsx","../src/components/shadcn-ui/radio-group.tsx","../src/components/shadcn-ui/popover.tsx","../src/components/shadcn-ui/dialog.tsx","../src/components/shadcn-ui/command.tsx","../src/components/basics/combo-box.component.tsx","../src/components/basics/chapter-range-selector.component.tsx","../src/components/advanced/book-selector.component.tsx","../src/components/advanced/data-table/data-table-column-toggle.component.tsx","../src/components/shadcn-ui/select.tsx","../src/components/advanced/data-table/data-table-pagination.component.tsx","../src/components/shadcn-ui/table.tsx","../src/components/advanced/data-table/data-table.component.tsx","../src/components/advanced/inventory/occurrences-table.component.tsx","../src/components/shadcn-ui/checkbox.tsx","../src/components/advanced/inventory/inventory-utils.ts","../src/components/shadcn-ui/toggle.tsx","../src/components/shadcn-ui/toggle-group.tsx","../src/components/advanced/inventory/inventory-columns.tsx","../src/components/advanced/inventory/inventory.component.tsx","../src/components/basics/search-bar.component.tsx","../src/components/basics/tabs-vertical.tsx","../src/components/advanced/tab-navigation-content-search.component.tsx","../src/components/shadcn-ui/separator.tsx","../src/components/shadcn-ui/sheet.tsx","../src/components/shadcn-ui/skeleton.tsx","../src/components/shadcn-ui/tooltip.tsx","../src/components/hooks/use-mobile.tsx","../src/components/shadcn-ui/sidebar.tsx","../src/components/advanced/settings-components/settings-sidebar.component.tsx","../src/components/advanced/settings-components/settings-sidebar-content-search.component.tsx","../src/components/advanced/scripture-results-viewer/scripture-results-viewer.component.tsx","../src/components/advanced/scroll-group-selector.component.tsx","../src/components/advanced/settings-components/settings-list.component.tsx","../src/components/shadcn-ui/card.tsx","../src/components/advanced/settings-components/settings-card.component.tsx","../src/components/basics/checklist.component.tsx","../../../node_modules/@babel/runtime/helpers/interopRequireDefault.js","../../../node_modules/@mui/utils/chainPropTypes/chainPropTypes.js","../../../node_modules/@babel/runtime/helpers/esm/extends.js","../../../node_modules/@mui/utils/deepmerge/deepmerge.js","../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.production.min.js","../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.development.js","../../../node_modules/prop-types/node_modules/react-is/index.js","../../../node_modules/object-assign/index.js","../../../node_modules/prop-types/lib/ReactPropTypesSecret.js","../../../node_modules/prop-types/lib/has.js","../../../node_modules/prop-types/checkPropTypes.js","../../../node_modules/prop-types/factoryWithTypeCheckers.js","../../../node_modules/prop-types/factoryWithThrowingShims.js","../../../node_modules/prop-types/index.js","../../../node_modules/@mui/utils/elementAcceptingRef/elementAcceptingRef.js","../../../node_modules/@mui/utils/exactProp/exactProp.js","../../../node_modules/@mui/utils/formatMuiErrorMessage/formatMuiErrorMessage.js","../../../node_modules/react-is/cjs/react-is.production.min.js","../../../node_modules/react-is/cjs/react-is.development.js","../../../node_modules/react-is/index.js","../../../node_modules/@mui/utils/getDisplayName/getDisplayName.js","../../../node_modules/@mui/utils/HTMLElementType/HTMLElementType.js","../../../node_modules/@mui/utils/refType/refType.js","../../../node_modules/@mui/utils/capitalize/capitalize.js","../../../node_modules/@mui/utils/createChainedFunction/createChainedFunction.js","../../../node_modules/@mui/utils/debounce/debounce.js","../../../node_modules/@mui/utils/deprecatedPropType/deprecatedPropType.js","../../../node_modules/@mui/utils/isMuiElement/isMuiElement.js","../../../node_modules/@mui/utils/ownerDocument/ownerDocument.js","../../../node_modules/@mui/utils/ownerWindow/ownerWindow.js","../../../node_modules/@mui/utils/requirePropFactory/requirePropFactory.js","../../../node_modules/@mui/utils/setRef/setRef.js","../../../node_modules/@mui/utils/useEnhancedEffect/useEnhancedEffect.js","../../../node_modules/@mui/utils/useId/useId.js","../../../node_modules/@mui/utils/unsupportedProp/unsupportedProp.js","../../../node_modules/@mui/utils/useControlled/useControlled.js","../../../node_modules/@mui/utils/useEventCallback/useEventCallback.js","../../../node_modules/@mui/utils/useForkRef/useForkRef.js","../../../node_modules/@mui/utils/useLazyRef/useLazyRef.js","../../../node_modules/@mui/utils/useOnMount/useOnMount.js","../../../node_modules/@mui/utils/useTimeout/useTimeout.js","../../../node_modules/@mui/utils/useIsFocusVisible/useIsFocusVisible.js","../../../node_modules/@mui/utils/resolveProps/resolveProps.js","../../../node_modules/@mui/utils/composeClasses/composeClasses.js","../../../node_modules/@mui/utils/ClassNameGenerator/ClassNameGenerator.js","../../../node_modules/@mui/utils/generateUtilityClass/generateUtilityClass.js","../../../node_modules/@mui/utils/generateUtilityClasses/generateUtilityClasses.js","../../../node_modules/@mui/utils/clamp/clamp.js","../../../node_modules/@babel/runtime/helpers/esm/objectWithoutPropertiesLoose.js","../../../node_modules/@mui/system/esm/createTheme/createBreakpoints.js","../../../node_modules/@mui/system/esm/createTheme/shape.js","../../../node_modules/@mui/system/esm/responsivePropType.js","../../../node_modules/@mui/system/esm/merge.js","../../../node_modules/@mui/system/esm/breakpoints.js","../../../node_modules/@mui/system/esm/style.js","../../../node_modules/@mui/system/esm/memoize.js","../../../node_modules/@mui/system/esm/spacing.js","../../../node_modules/@mui/system/esm/createTheme/createSpacing.js","../../../node_modules/@mui/system/esm/compose.js","../../../node_modules/@mui/system/esm/borders.js","../../../node_modules/@mui/system/esm/cssGrid.js","../../../node_modules/@mui/system/esm/palette.js","../../../node_modules/@mui/system/esm/sizing.js","../../../node_modules/@mui/system/esm/styleFunctionSx/defaultSxConfig.js","../../../node_modules/@mui/system/esm/styleFunctionSx/styleFunctionSx.js","../../../node_modules/@mui/system/esm/createTheme/applyStyles.js","../../../node_modules/@mui/system/esm/createTheme/createTheme.js","../../../node_modules/@mui/system/esm/useThemeWithoutDefault.js","../../../node_modules/@mui/system/esm/useTheme.js","../../../node_modules/@mui/system/esm/createStyled.js","../../../node_modules/@mui/system/esm/useThemeProps/getThemeProps.js","../../../node_modules/@mui/system/esm/useThemeProps/useThemeProps.js","../../../node_modules/@mui/system/esm/colorManipulator.js","../../../node_modules/@mui/material/styles/createMixins.js","../../../node_modules/@mui/material/colors/common.js","../../../node_modules/@mui/material/colors/grey.js","../../../node_modules/@mui/material/colors/purple.js","../../../node_modules/@mui/material/colors/red.js","../../../node_modules/@mui/material/colors/orange.js","../../../node_modules/@mui/material/colors/blue.js","../../../node_modules/@mui/material/colors/lightBlue.js","../../../node_modules/@mui/material/colors/green.js","../../../node_modules/@mui/material/styles/createPalette.js","../../../node_modules/@mui/material/styles/createTypography.js","../../../node_modules/@mui/material/styles/shadows.js","../../../node_modules/@mui/material/styles/createTransitions.js","../../../node_modules/@mui/material/styles/zIndex.js","../../../node_modules/@mui/material/styles/createTheme.js","../../../node_modules/@mui/material/styles/defaultTheme.js","../../../node_modules/@mui/material/styles/identifier.js","../../../node_modules/@mui/material/styles/useThemeProps.js","../../../node_modules/@mui/material/styles/styled.js","../../../node_modules/@mui/material/SvgIcon/svgIconClasses.js","../../../node_modules/@mui/material/SvgIcon/SvgIcon.js","../../../node_modules/@mui/material/utils/createSvgIcon.js","../../../node_modules/@mui/material/utils/index.js","../../../node_modules/@mui/icons-material/utils/createSvgIcon.js","../../../node_modules/@mui/icons-material/ArrowRight.js","../../../node_modules/@mui/base/utils/isHostComponent.js","../../../node_modules/@mui/base/utils/appendOwnerState.js","../../../node_modules/@mui/base/utils/ClassNameConfigurator.js","../../../node_modules/@mui/base/utils/extractEventHandlers.js","../../../node_modules/@mui/base/utils/resolveComponentProps.js","../../../node_modules/@mui/base/utils/omitEventHandlers.js","../../../node_modules/@mui/base/utils/mergeSlotProps.js","../../../node_modules/@mui/base/utils/useSlotProps.js","../../../node_modules/@mui/base/generateUtilityClass/index.js","../../../node_modules/@mui/base/generateUtilityClasses/index.js","../../../node_modules/@mui/base/Portal/Portal.js","../../../node_modules/@popperjs/core/lib/enums.js","../../../node_modules/@popperjs/core/lib/dom-utils/getNodeName.js","../../../node_modules/@popperjs/core/lib/dom-utils/getWindow.js","../../../node_modules/@popperjs/core/lib/dom-utils/instanceOf.js","../../../node_modules/@popperjs/core/lib/modifiers/applyStyles.js","../../../node_modules/@popperjs/core/lib/utils/getBasePlacement.js","../../../node_modules/@popperjs/core/lib/utils/math.js","../../../node_modules/@popperjs/core/lib/utils/userAgent.js","../../../node_modules/@popperjs/core/lib/dom-utils/isLayoutViewport.js","../../../node_modules/@popperjs/core/lib/dom-utils/getBoundingClientRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/getLayoutRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/contains.js","../../../node_modules/@popperjs/core/lib/dom-utils/getComputedStyle.js","../../../node_modules/@popperjs/core/lib/dom-utils/isTableElement.js","../../../node_modules/@popperjs/core/lib/dom-utils/getDocumentElement.js","../../../node_modules/@popperjs/core/lib/dom-utils/getParentNode.js","../../../node_modules/@popperjs/core/lib/dom-utils/getOffsetParent.js","../../../node_modules/@popperjs/core/lib/utils/getMainAxisFromPlacement.js","../../../node_modules/@popperjs/core/lib/utils/within.js","../../../node_modules/@popperjs/core/lib/utils/getFreshSideObject.js","../../../node_modules/@popperjs/core/lib/utils/mergePaddingObject.js","../../../node_modules/@popperjs/core/lib/utils/expandToHashMap.js","../../../node_modules/@popperjs/core/lib/modifiers/arrow.js","../../../node_modules/@popperjs/core/lib/utils/getVariation.js","../../../node_modules/@popperjs/core/lib/modifiers/computeStyles.js","../../../node_modules/@popperjs/core/lib/modifiers/eventListeners.js","../../../node_modules/@popperjs/core/lib/utils/getOppositePlacement.js","../../../node_modules/@popperjs/core/lib/utils/getOppositeVariationPlacement.js","../../../node_modules/@popperjs/core/lib/dom-utils/getWindowScroll.js","../../../node_modules/@popperjs/core/lib/dom-utils/getWindowScrollBarX.js","../../../node_modules/@popperjs/core/lib/dom-utils/getViewportRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/getDocumentRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/isScrollParent.js","../../../node_modules/@popperjs/core/lib/dom-utils/getScrollParent.js","../../../node_modules/@popperjs/core/lib/dom-utils/listScrollParents.js","../../../node_modules/@popperjs/core/lib/utils/rectToClientRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/getClippingRect.js","../../../node_modules/@popperjs/core/lib/utils/computeOffsets.js","../../../node_modules/@popperjs/core/lib/utils/detectOverflow.js","../../../node_modules/@popperjs/core/lib/utils/computeAutoPlacement.js","../../../node_modules/@popperjs/core/lib/modifiers/flip.js","../../../node_modules/@popperjs/core/lib/modifiers/hide.js","../../../node_modules/@popperjs/core/lib/modifiers/offset.js","../../../node_modules/@popperjs/core/lib/modifiers/popperOffsets.js","../../../node_modules/@popperjs/core/lib/utils/getAltAxis.js","../../../node_modules/@popperjs/core/lib/modifiers/preventOverflow.js","../../../node_modules/@popperjs/core/lib/dom-utils/getHTMLElementScroll.js","../../../node_modules/@popperjs/core/lib/dom-utils/getNodeScroll.js","../../../node_modules/@popperjs/core/lib/dom-utils/getCompositeRect.js","../../../node_modules/@popperjs/core/lib/utils/orderModifiers.js","../../../node_modules/@popperjs/core/lib/utils/debounce.js","../../../node_modules/@popperjs/core/lib/utils/mergeByName.js","../../../node_modules/@popperjs/core/lib/createPopper.js","../../../node_modules/@popperjs/core/lib/popper.js","../../../node_modules/@mui/base/Popper/popperClasses.js","../../../node_modules/@mui/base/Popper/Popper.js","../../../node_modules/@mui/material/styles/useTheme.js","../../../node_modules/@babel/runtime/helpers/esm/setPrototypeOf.js","../../../node_modules/@babel/runtime/helpers/esm/inheritsLoose.js","../../../node_modules/react-transition-group/esm/config.js","../../../node_modules/react-transition-group/esm/utils/PropTypes.js","../../../node_modules/react-transition-group/esm/TransitionGroupContext.js","../../../node_modules/react-transition-group/esm/utils/reflow.js","../../../node_modules/react-transition-group/esm/Transition.js","../../../node_modules/@mui/material/transitions/utils.js","../../../node_modules/@mui/material/Grow/Grow.js","../../../node_modules/@mui/material/Popper/Popper.js","../../../node_modules/@mui/material/Tooltip/tooltipClasses.js","../../../node_modules/@mui/material/Tooltip/Tooltip.js","../src/components/mui/menu-item.component.tsx","../src/components/mui/grouped-menu-item-list.component.tsx","../src/components/mui/top-level-menu.component.tsx","../src/components/mui/grid-menu.component.tsx","../src/hooks/use-promise.hook.ts","../../../node_modules/@mui/icons-material/esm/Menu.js","../src/components/mui/hamburger-menu-button.component.tsx","../src/components/mui/icon-button.component.tsx","../src/components/basics/spinner.component.tsx","../src/components/basics/text-field.component.tsx","../src/components/mui/toolbar.component.tsx","../src/components/shadcn-ui/alert.tsx","../src/components/shadcn-ui/sonner.tsx","../src/components/shadcn-ui/slider.tsx","../src/components/shadcn-ui/switch.tsx","../src/components/shadcn-ui/tabs.tsx","../src/components/advanced/extension-marketplace/buttons/install-button.component.tsx","../src/components/advanced/extension-marketplace/buttons/enable-button.component.tsx","../src/components/advanced/extension-marketplace/buttons/disable-button.component.tsx","../src/components/advanced/extension-marketplace/buttons/update-button.component.tsx","../src/components/advanced/extension-marketplace/markdown-renderer.component.tsx","../src/components/advanced/extension-marketplace/buttons/filter-button.component.tsx","../src/components/advanced/extension-marketplace/filter-dropdown.component.tsx","../src/components/advanced/extension-marketplace/no-extensions-found.component.tsx","../src/components/advanced/extension-marketplace/more-info.component.tsx","../src/components/advanced/extension-marketplace/version-history.component.tsx","../src/components/advanced/extension-marketplace/footer.component.tsx","../src/hooks/use-event.hook.ts","../src/hooks/use-event-async.hook.ts"],"sourcesContent":["import { type ClassValue, clsx } from 'clsx';\nimport { extendTailwindMerge } from 'tailwind-merge';\n\nconst twMergeCustom = extendTailwindMerge({ prefix: 'tw-' });\n\n/**\n * Tailwind and CSS class application helper function. Uses\n * [`clsx`](https://www.npmjs.com/package/clsx) to make it easy to apply classes conditionally using\n * object syntax, and uses [`tailwind-merge`](https://www.npmjs.com/package/tailwind-merge) to make\n * it easy to merge/overwrite Tailwind classes in a programmer-logic-friendly way.\n *\n * Note: `tailwind-merge` is configured to use the prefix `tw-`, so you must use the same prefix\n * with any Tailwind classes you use with this function to successfully overwrite other Tailwind\n * classes. `platform-bible-react` is configured to use `tw-` as its Tailwind prefix, so any\n * Tailwind classes you pass into `platform-bible-react` components will be compared using the `tw-`\n * prefix.\n *\n * This function was popularized by\n * [shadcn/ui](https://ui.shadcn.com/docs/installation/manual#add-a-cn-helper). See [ByteGrad's\n * explanation video](https://www.youtube.com/watch?v=re2JFITR7TI) for more information.\n *\n * @example\n *\n * ```typescript\n * const borderShouldBeBlue = true;\n * const textShouldBeRed = true;\n * const heightShouldBe20 = false;\n * const classString = cn(\n * 'tw-bg-primary tw-h-10 tw-text-primary-foreground',\n * 'tw-bg-secondary',\n * {\n * 'tw-border-blue-500': borderShouldBeBlue,\n * 'tw-text-red-500': textShouldBeRed,\n * 'tw-h-20': heightShouldBe20,\n * },\n * 'some-class',\n * );\n * ```\n *\n * The resulting `classString` is `'tw-h-10 tw-bg-secondary tw-border-blue-500 tw-text-red-500\n * some-class'`\n *\n * - Notice that `'tw-bg-secondary'`, specified later, overwrote `'tw-bg-primary'`, specified earlier,\n * because they are Tailwind classes that affect the same css property\n * - Notice that `'tw-text-red-500'`, specified later, overwrote `'tw-text-primary-foreground'`,\n * specified earlier, because they are Tailwind classes that affect the same css property\n * - Notice that `'tw-h-20'`, specified later, did not overwrite `'tw-h-10'`, specified earlier,\n * because `'tw-h-20'` is part of a conditional class object and its value evaluated to `false`;\n * therefore it was not applied\n * - Notice that `'some-class'` was applied. This function is not limited only to Tailwind classes.\n *\n *\n * @param inputs Class strings or `clsx` conditional class objects to merge. Tailwind classes\n * specified later in the arguments overwrite similar Tailwind classes specified earlier in the\n * arguments\n * @returns Class string containing all applicable classes from the arguments based on the rules\n * described above\n */\n// shadcn/ui uses this export in its boilerplate code\n// eslint-disable-next-line import/prefer-default-export\nexport function cn(...inputs: ClassValue[]) {\n return twMergeCustom(clsx(inputs));\n}\n","import React from 'react';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport interface InputProps extends React.InputHTMLAttributes {}\n\nexport const Input = React.forwardRef(\n ({ className, type, ...props }, ref) => {\n return (\n \n );\n },\n);\nInput.displayName = 'Input';\n","import { FocusEventHandler, forwardRef, KeyboardEvent, MouseEventHandler } from 'react';\nimport { History } from 'lucide-react';\nimport { Input as ShadInput } from '@/components/shadcn-ui/input';\n\nexport type BookChapterInputProps = {\n handleSearch: (searchString: string) => void;\n handleKeyDown: (event: KeyboardEvent) => void;\n handleOnClick: MouseEventHandler;\n handleSubmit: () => void;\n onFocus?: FocusEventHandler;\n value: string;\n placeholder: string;\n};\n\n// Shadcn Input sets type to \"button\"- HAVE to prop spread before setting type\nconst BookChapterInput = forwardRef(\n (\n { handleSearch, handleKeyDown, handleOnClick, handleSubmit, ...props }: BookChapterInputProps,\n ref,\n ) => {\n return (\n
    \n handleSearch(event.target.value)}\n onKeyDown={(e) => {\n if (e.key === 'Enter') {\n handleSubmit();\n }\n handleKeyDown(e);\n }}\n onClick={handleOnClick}\n ref={ref}\n />\n {\n // eslint-disable-next-line no-console\n console.log('back in history');\n }}\n />\n
    \n );\n },\n);\n\nexport default BookChapterInput;\n","var P = Object.defineProperty;\nvar R = (t, e, s) => e in t ? P(t, e, { enumerable: !0, configurable: !0, writable: !0, value: s }) : t[e] = s;\nvar n = (t, e, s) => R(t, typeof e != \"symbol\" ? e + \"\" : e, s);\nclass _ {\n constructor() {\n n(this, \"books\");\n n(this, \"firstSelectedBookNum\");\n n(this, \"lastSelectedBookNum\");\n n(this, \"count\");\n n(this, \"selectedBookNumbers\");\n n(this, \"selectedBookIds\");\n }\n}\nconst N = [\n \"GEN\",\n \"EXO\",\n \"LEV\",\n \"NUM\",\n \"DEU\",\n \"JOS\",\n \"JDG\",\n \"RUT\",\n \"1SA\",\n \"2SA\",\n // 10\n \"1KI\",\n \"2KI\",\n \"1CH\",\n \"2CH\",\n \"EZR\",\n \"NEH\",\n \"EST\",\n \"JOB\",\n \"PSA\",\n \"PRO\",\n // 20\n \"ECC\",\n \"SNG\",\n \"ISA\",\n \"JER\",\n \"LAM\",\n \"EZK\",\n \"DAN\",\n \"HOS\",\n \"JOL\",\n \"AMO\",\n // 30\n \"OBA\",\n \"JON\",\n \"MIC\",\n \"NAM\",\n \"HAB\",\n \"ZEP\",\n \"HAG\",\n \"ZEC\",\n \"MAL\",\n \"MAT\",\n // 40\n \"MRK\",\n \"LUK\",\n \"JHN\",\n \"ACT\",\n \"ROM\",\n \"1CO\",\n \"2CO\",\n \"GAL\",\n \"EPH\",\n \"PHP\",\n // 50\n \"COL\",\n \"1TH\",\n \"2TH\",\n \"1TI\",\n \"2TI\",\n \"TIT\",\n \"PHM\",\n \"HEB\",\n \"JAS\",\n \"1PE\",\n // 60\n \"2PE\",\n \"1JN\",\n \"2JN\",\n \"3JN\",\n \"JUD\",\n \"REV\",\n \"TOB\",\n \"JDT\",\n \"ESG\",\n \"WIS\",\n // 70\n \"SIR\",\n \"BAR\",\n \"LJE\",\n \"S3Y\",\n \"SUS\",\n \"BEL\",\n \"1MA\",\n \"2MA\",\n \"3MA\",\n \"4MA\",\n // 80\n \"1ES\",\n \"2ES\",\n \"MAN\",\n \"PS2\",\n \"ODA\",\n \"PSS\",\n \"JSA\",\n // actual variant text for JOS, now in LXA text\n \"JDB\",\n // actual variant text for JDG, now in LXA text\n \"TBS\",\n // actual variant text for TOB, now in LXA text\n \"SST\",\n // actual variant text for SUS, now in LXA text // 90\n \"DNT\",\n // actual variant text for DAN, now in LXA text\n \"BLT\",\n // actual variant text for BEL, now in LXA text\n \"XXA\",\n \"XXB\",\n \"XXC\",\n \"XXD\",\n \"XXE\",\n \"XXF\",\n \"XXG\",\n \"FRT\",\n // 100\n \"BAK\",\n \"OTH\",\n \"3ES\",\n // Used previously but really should be 2ES\n \"EZA\",\n // Used to be called 4ES, but not actually in any known project\n \"5EZ\",\n // Used to be called 5ES, but not actually in any known project\n \"6EZ\",\n // Used to be called 6ES, but not actually in any known project\n \"INT\",\n \"CNC\",\n \"GLO\",\n \"TDX\",\n // 110\n \"NDX\",\n \"DAG\",\n \"PS3\",\n \"2BA\",\n \"LBA\",\n \"JUB\",\n \"ENO\",\n \"1MQ\",\n \"2MQ\",\n \"3MQ\",\n // 120\n \"REP\",\n \"4BA\",\n \"LAO\"\n], B = [\n \"XXA\",\n \"XXB\",\n \"XXC\",\n \"XXD\",\n \"XXE\",\n \"XXF\",\n \"XXG\",\n \"FRT\",\n \"BAK\",\n \"OTH\",\n \"INT\",\n \"CNC\",\n \"GLO\",\n \"TDX\",\n \"NDX\"\n], O = [\n \"Genesis\",\n \"Exodus\",\n \"Leviticus\",\n \"Numbers\",\n \"Deuteronomy\",\n \"Joshua\",\n \"Judges\",\n \"Ruth\",\n \"1 Samuel\",\n \"2 Samuel\",\n \"1 Kings\",\n \"2 Kings\",\n \"1 Chronicles\",\n \"2 Chronicles\",\n \"Ezra\",\n \"Nehemiah\",\n \"Esther (Hebrew)\",\n \"Job\",\n \"Psalms\",\n \"Proverbs\",\n \"Ecclesiastes\",\n \"Song of Songs\",\n \"Isaiah\",\n \"Jeremiah\",\n \"Lamentations\",\n \"Ezekiel\",\n \"Daniel (Hebrew)\",\n \"Hosea\",\n \"Joel\",\n \"Amos\",\n \"Obadiah\",\n \"Jonah\",\n \"Micah\",\n \"Nahum\",\n \"Habakkuk\",\n \"Zephaniah\",\n \"Haggai\",\n \"Zechariah\",\n \"Malachi\",\n \"Matthew\",\n \"Mark\",\n \"Luke\",\n \"John\",\n \"Acts\",\n \"Romans\",\n \"1 Corinthians\",\n \"2 Corinthians\",\n \"Galatians\",\n \"Ephesians\",\n \"Philippians\",\n \"Colossians\",\n \"1 Thessalonians\",\n \"2 Thessalonians\",\n \"1 Timothy\",\n \"2 Timothy\",\n \"Titus\",\n \"Philemon\",\n \"Hebrews\",\n \"James\",\n \"1 Peter\",\n \"2 Peter\",\n \"1 John\",\n \"2 John\",\n \"3 John\",\n \"Jude\",\n \"Revelation\",\n \"Tobit\",\n \"Judith\",\n \"Esther Greek\",\n \"Wisdom of Solomon\",\n \"Sirach (Ecclesiasticus)\",\n \"Baruch\",\n \"Letter of Jeremiah\",\n \"Song of 3 Young Men\",\n \"Susanna\",\n \"Bel and the Dragon\",\n \"1 Maccabees\",\n \"2 Maccabees\",\n \"3 Maccabees\",\n \"4 Maccabees\",\n \"1 Esdras (Greek)\",\n \"2 Esdras (Latin)\",\n \"Prayer of Manasseh\",\n \"Psalm 151\",\n \"Odes\",\n \"Psalms of Solomon\",\n // WARNING, if you change the spelling of the *obsolete* tag be sure to update\n // IsObsolete routine\n \"Joshua A. *obsolete*\",\n \"Judges B. *obsolete*\",\n \"Tobit S. *obsolete*\",\n \"Susanna Th. *obsolete*\",\n \"Daniel Th. *obsolete*\",\n \"Bel Th. *obsolete*\",\n \"Extra A\",\n \"Extra B\",\n \"Extra C\",\n \"Extra D\",\n \"Extra E\",\n \"Extra F\",\n \"Extra G\",\n \"Front Matter\",\n \"Back Matter\",\n \"Other Matter\",\n \"3 Ezra *obsolete*\",\n \"Apocalypse of Ezra\",\n \"5 Ezra (Latin Prologue)\",\n \"6 Ezra (Latin Epilogue)\",\n \"Introduction\",\n \"Concordance \",\n \"Glossary \",\n \"Topical Index\",\n \"Names Index\",\n \"Daniel Greek\",\n \"Psalms 152-155\",\n \"2 Baruch (Apocalypse)\",\n \"Letter of Baruch\",\n \"Jubilees\",\n \"Enoch\",\n \"1 Meqabyan\",\n \"2 Meqabyan\",\n \"3 Meqabyan\",\n \"Reproof (Proverbs 25-31)\",\n \"4 Baruch (Rest of Baruch)\",\n \"Laodiceans\"\n], S = K();\nfunction g(t, e = !0) {\n return e && (t = t.toUpperCase()), t in S ? S[t] : 0;\n}\nfunction k(t) {\n return g(t) > 0;\n}\nfunction x(t) {\n const e = typeof t == \"string\" ? g(t) : t;\n return e >= 40 && e <= 66;\n}\nfunction T(t) {\n return (typeof t == \"string\" ? g(t) : t) <= 39;\n}\nfunction X(t) {\n return t <= 66;\n}\nfunction V(t) {\n const e = typeof t == \"string\" ? g(t) : t;\n return w(e) && !X(e);\n}\nfunction* L() {\n for (let t = 1; t <= N.length; t++) yield t;\n}\nconst G = 1, A = N.length;\nfunction H() {\n return [\"XXA\", \"XXB\", \"XXC\", \"XXD\", \"XXE\", \"XXF\", \"XXG\"];\n}\nfunction C(t, e = \"***\") {\n const s = t - 1;\n return s < 0 || s >= N.length ? e : N[s];\n}\nfunction I(t) {\n return t <= 0 || t > A ? \"******\" : O[t - 1];\n}\nfunction y(t) {\n return I(g(t));\n}\nfunction w(t) {\n const e = typeof t == \"number\" ? C(t) : t;\n return k(e) && !B.includes(e);\n}\nfunction q(t) {\n const e = typeof t == \"number\" ? C(t) : t;\n return k(e) && B.includes(e);\n}\nfunction U(t) {\n return O[t - 1].includes(\"*obsolete*\");\n}\nfunction K() {\n const t = {};\n for (let e = 0; e < N.length; e++)\n t[N[e]] = e + 1;\n return t;\n}\nconst m = {\n allBookIds: N,\n nonCanonicalIds: B,\n bookIdToNumber: g,\n isBookIdValid: k,\n isBookNT: x,\n isBookOT: T,\n isBookOTNT: X,\n isBookDC: V,\n allBookNumbers: L,\n firstBook: G,\n lastBook: A,\n extraBooks: H,\n bookNumberToId: C,\n bookNumberToEnglishName: I,\n bookIdToEnglishName: y,\n isCanonical: w,\n isExtraMaterial: q,\n isObsolete: U\n};\nvar l = /* @__PURE__ */ ((t) => (t[t.Unknown = 0] = \"Unknown\", t[t.Original = 1] = \"Original\", t[t.Septuagint = 2] = \"Septuagint\", t[t.Vulgate = 3] = \"Vulgate\", t[t.English = 4] = \"English\", t[t.RussianProtestant = 5] = \"RussianProtestant\", t[t.RussianOrthodox = 6] = \"RussianOrthodox\", t))(l || {});\nconst h = class h {\n // private versInfo: Versification;\n constructor(e) {\n n(this, \"name\");\n n(this, \"fullPath\");\n n(this, \"isPresent\");\n n(this, \"hasVerseSegments\");\n n(this, \"isCustomized\");\n n(this, \"baseVersification\");\n n(this, \"scriptureBooks\");\n n(this, \"_type\");\n if (e == null)\n throw new Error(\"Argument undefined\");\n typeof e == \"string\" ? (this.name = e, this._type = l[e]) : (this._type = e, this.name = l[e]);\n }\n get type() {\n return this._type;\n }\n equals(e) {\n return !e.type || !this.type ? !1 : e.type === this.type;\n }\n};\nn(h, \"Original\", new h(l.Original)), n(h, \"Septuagint\", new h(l.Septuagint)), n(h, \"Vulgate\", new h(l.Vulgate)), n(h, \"English\", new h(l.English)), n(h, \"RussianProtestant\", new h(l.RussianProtestant)), n(h, \"RussianOrthodox\", new h(l.RussianOrthodox));\nlet c = h;\nfunction E(t, e) {\n const s = e[0];\n for (let r = 1; r < e.length; r++)\n t = t.split(e[r]).join(s);\n return t.split(s);\n}\nvar D = /* @__PURE__ */ ((t) => (t[t.Valid = 0] = \"Valid\", t[t.UnknownVersification = 1] = \"UnknownVersification\", t[t.OutOfRange = 2] = \"OutOfRange\", t[t.VerseOutOfOrder = 3] = \"VerseOutOfOrder\", t[t.VerseRepeated = 4] = \"VerseRepeated\", t))(D || {});\nconst i = class i {\n constructor(e, s, r, a) {\n /** Not yet implemented. */\n n(this, \"firstChapter\");\n /** Not yet implemented. */\n n(this, \"lastChapter\");\n /** Not yet implemented. */\n n(this, \"lastVerse\");\n /** Not yet implemented. */\n n(this, \"hasSegmentsDefined\");\n /** Not yet implemented. */\n n(this, \"text\");\n /** Not yet implemented. */\n n(this, \"BBBCCCVVVS\");\n /** Not yet implemented. */\n n(this, \"longHashCode\");\n /** The versification of the reference. */\n n(this, \"versification\");\n n(this, \"rtlMark\", \"‏\");\n n(this, \"_bookNum\", 0);\n n(this, \"_chapterNum\", 0);\n n(this, \"_verseNum\", 0);\n n(this, \"_verse\");\n if (r == null && a == null)\n if (e != null && typeof e == \"string\") {\n const o = e, u = s != null && s instanceof c ? s : void 0;\n this.setEmpty(u), this.parse(o);\n } else if (e != null && typeof e == \"number\") {\n const o = s != null && s instanceof c ? s : void 0;\n this.setEmpty(o), this._verseNum = e % i.chapterDigitShifter, this._chapterNum = Math.floor(\n e % i.bookDigitShifter / i.chapterDigitShifter\n ), this._bookNum = Math.floor(e / i.bookDigitShifter);\n } else if (s == null)\n if (e != null && e instanceof i) {\n const o = e;\n this._bookNum = o.bookNum, this._chapterNum = o.chapterNum, this._verseNum = o.verseNum, this._verse = o.verse, this.versification = o.versification;\n } else {\n if (e == null) return;\n const o = e instanceof c ? e : i.defaultVersification;\n this.setEmpty(o);\n }\n else\n throw new Error(\"VerseRef constructor not supported.\");\n else if (e != null && s != null && r != null)\n if (typeof e == \"string\" && typeof s == \"string\" && typeof r == \"string\")\n this.setEmpty(a), this.updateInternal(e, s, r);\n else if (typeof e == \"number\" && typeof s == \"number\" && typeof r == \"number\")\n this._bookNum = e, this._chapterNum = s, this._verseNum = r, this.versification = a ?? i.defaultVersification;\n else\n throw new Error(\"VerseRef constructor not supported.\");\n else\n throw new Error(\"VerseRef constructor not supported.\");\n }\n /**\n * Determines if the verse string is in a valid format (does not consider versification).\n */\n static isVerseParseable(e) {\n return e.length > 0 && \"0123456789\".includes(e[0]) && !e.endsWith(this.verseRangeSeparator) && !e.endsWith(this.verseSequenceIndicator);\n }\n /**\n * Tries to parse the specified string into a verse reference.\n * @param str - The string to attempt to parse.\n * @returns success: `true` if the specified string was successfully parsed, `false` otherwise.\n * @returns verseRef: The result of the parse if successful, or empty VerseRef if it failed\n */\n static tryParse(e) {\n let s;\n try {\n return s = new i(e), { success: !0, verseRef: s };\n } catch (r) {\n if (r instanceof v)\n return s = new i(), { success: !1, verseRef: s };\n throw r;\n }\n }\n /**\n * Gets the reference as a comparable integer where the book, chapter, and verse each occupy 3\n * digits.\n * @param bookNum - Book number (this is 1-based, not an index).\n * @param chapterNum - Chapter number.\n * @param verseNum - Verse number.\n * @returns The reference as a comparable integer where the book, chapter, and verse each occupy 3\n * digits.\n */\n static getBBBCCCVVV(e, s, r) {\n return e % i.bcvMaxValue * i.bookDigitShifter + (s >= 0 ? s % i.bcvMaxValue * i.chapterDigitShifter : 0) + (r >= 0 ? r % i.bcvMaxValue : 0);\n }\n /**\n * Deserializes a serialized VerseRef.\n * @param serializedVerseRef - Serialized VerseRef to create from.\n * @returns the deserialized VerseRef.\n */\n static fromJSON(e) {\n const { book: s, chapterNum: r, verseNum: a, verse: o, versificationStr: u } = e, f = o || a.toString();\n let d;\n return u && (d = new c(u)), s ? new i(s, r.toString(), f, d) : new i();\n }\n /**\n * Parses a verse string and gets the leading numeric portion as a number.\n * @param verseStr - verse string to parse\n * @returns true if the entire string could be parsed as a single, simple verse number (1-999);\n * false if the verse string represented a verse bridge, contained segment letters, or was invalid\n */\n static tryGetVerseNum(e) {\n let s;\n if (!e)\n return s = -1, { success: !0, vNum: s };\n s = 0;\n let r;\n for (let a = 0; a < e.length; a++) {\n if (r = e[a], r < \"0\" || r > \"9\")\n return a === 0 && (s = -1), { success: !1, vNum: s };\n if (s = s * 10 + +r - 0, s > i.bcvMaxValue)\n return s = -1, { success: !1, vNum: s };\n }\n return { success: !0, vNum: s };\n }\n /**\n * Checks to see if a VerseRef hasn't been set - all values are the default.\n */\n get isDefault() {\n return this.bookNum === 0 && this.chapterNum === 0 && this.verseNum === 0 && this.versification == null;\n }\n /**\n * Gets whether the verse contains multiple verses.\n */\n get hasMultiple() {\n return this._verse != null && (this._verse.includes(i.verseRangeSeparator) || this._verse.includes(i.verseSequenceIndicator));\n }\n /**\n * Gets or sets the book of the reference. Book is the 3-letter abbreviation in capital letters,\n * e.g. `'MAT'`.\n */\n get book() {\n return m.bookNumberToId(this.bookNum, \"\");\n }\n set book(e) {\n this.bookNum = m.bookIdToNumber(e);\n }\n /**\n * Gets or sets the chapter of the reference,. e.g. `'3'`.\n */\n get chapter() {\n return this.isDefault || this._chapterNum < 0 ? \"\" : this._chapterNum.toString();\n }\n set chapter(e) {\n const s = +e;\n this._chapterNum = Number.isInteger(s) ? s : -1;\n }\n /**\n * Gets or sets the verse of the reference, including range, segments, and sequences, e.g. `'4'`,\n * or `'4b-5a, 7'`.\n */\n get verse() {\n return this._verse != null ? this._verse : this.isDefault || this._verseNum < 0 ? \"\" : this._verseNum.toString();\n }\n set verse(e) {\n const { success: s, vNum: r } = i.tryGetVerseNum(e);\n this._verse = s ? void 0 : e.replace(this.rtlMark, \"\"), this._verseNum = r, !(this._verseNum >= 0) && ({ vNum: this._verseNum } = i.tryGetVerseNum(this._verse));\n }\n /**\n * Get or set Book based on book number, e.g. `42`.\n */\n get bookNum() {\n return this._bookNum;\n }\n set bookNum(e) {\n if (e <= 0 || e > m.lastBook)\n throw new v(\n \"BookNum must be greater than zero and less than or equal to last book\"\n );\n this._bookNum = e;\n }\n /**\n * Gets or sets the chapter number, e.g. `3`. `-1` if not valid.\n */\n get chapterNum() {\n return this._chapterNum;\n }\n set chapterNum(e) {\n this.chapterNum = e;\n }\n /**\n * Gets or sets verse start number, e.g. `4`. `-1` if not valid.\n */\n get verseNum() {\n return this._verseNum;\n }\n set verseNum(e) {\n this._verseNum = e;\n }\n /**\n * String representing the versification (should ONLY be used for serialization/deserialization).\n *\n * @remarks This is for backwards compatibility when ScrVers was an enumeration.\n */\n get versificationStr() {\n var e;\n return (e = this.versification) == null ? void 0 : e.name;\n }\n set versificationStr(e) {\n this.versification = this.versification != null ? new c(e) : void 0;\n }\n /**\n * Determines if the reference is valid.\n */\n get valid() {\n return this.validStatus === 0;\n }\n /**\n * Get the valid status for this reference.\n */\n get validStatus() {\n return this.validateVerse(i.verseRangeSeparators, i.verseSequenceIndicators);\n }\n /**\n * Gets the reference as a comparable integer where the book,\n * chapter, and verse each occupy three digits and the verse is 0.\n */\n get BBBCCC() {\n return i.getBBBCCCVVV(this._bookNum, this._chapterNum, 0);\n }\n /**\n * Gets the reference as a comparable integer where the book,\n * chapter, and verse each occupy three digits. If verse is not null\n * (i.e., this reference represents a complex reference with verse\n * segments or bridge) this cannot be used for an exact comparison.\n */\n get BBBCCCVVV() {\n return i.getBBBCCCVVV(this._bookNum, this._chapterNum, this._verseNum);\n }\n /**\n * Gets whether the verse is defined as an excluded verse in the versification.\n * Does not handle verse ranges.\n */\n // eslint-disable-next-line @typescript-eslint/class-literal-property-style\n get isExcluded() {\n return !1;\n }\n /**\n * Parses the reference in the specified string.\n * Optionally versification can follow reference as in GEN 3:11/4\n * Throw an exception if\n * - invalid book name\n * - chapter number is missing or not a number\n * - verse number is missing or does not start with a number\n * - versification is invalid\n * @param verseStr - string to parse e.g. 'MAT 3:11'\n */\n parse(e) {\n if (e = e.replace(this.rtlMark, \"\"), e.includes(\"/\")) {\n const o = e.split(\"/\");\n if (e = o[0], o.length > 1)\n try {\n const u = +o[1].trim();\n this.versification = new c(l[u]);\n } catch {\n throw new v(\"Invalid reference : \" + e);\n }\n }\n const s = e.trim().split(\" \");\n if (s.length !== 2)\n throw new v(\"Invalid reference : \" + e);\n const r = s[1].split(\":\"), a = +r[0];\n if (r.length !== 2 || m.bookIdToNumber(s[0]) === 0 || !Number.isInteger(a) || a < 0 || !i.isVerseParseable(r[1]))\n throw new v(\"Invalid reference : \" + e);\n this.updateInternal(s[0], r[0], r[1]);\n }\n /**\n * Simplifies this verse ref so that it has no bridging of verses or\n * verse segments like `'1a'`.\n */\n simplify() {\n this._verse = void 0;\n }\n /**\n * Makes a clone of the reference.\n *\n * @returns The cloned VerseRef.\n */\n clone() {\n return new i(this);\n }\n toString() {\n const e = this.book;\n return e === \"\" ? \"\" : `${e} ${this.chapter}:${this.verse}`;\n }\n toJSON() {\n let e = this.verse;\n (e === \"\" || e === this.verseNum.toString()) && (e = void 0);\n const s = {\n book: this.book,\n chapterNum: this.chapterNum,\n verseNum: this.verseNum,\n verse: e,\n versificationStr: this.versificationStr\n };\n return e || delete s.verse, s;\n }\n /**\n * Compares this `VerseRef` with supplied one.\n * @param verseRef - object to compare this one to.\n * @returns `true` if this `VerseRef` is equal to the supplied one, `false` otherwise.\n */\n equals(e) {\n return e instanceof i ? e._bookNum === this._bookNum && e._chapterNum === this._chapterNum && e._verseNum === this._verseNum && e.verse === this.verse && (e.versification == null && this.versification == null || e.versification != null && this.versification != null && e.versification.equals(this.versification)) : !1;\n }\n /**\n * Enumerate all individual verses contained in a VerseRef.\n * Verse ranges are indicated by \"-\" and consecutive verses by \",\"s.\n * Examples:\n * GEN 1:2 returns GEN 1:2\n * GEN 1:1a-3b,5 returns GEN 1:1a, GEN 1:2, GEN 1:3b, GEN 1:5\n * GEN 1:2a-2c returns //! ??????\n *\n * @param specifiedVersesOnly - if set to true return only verses that are\n * explicitly specified only, not verses within a range. Defaults to `false`.\n * @param verseRangeSeparators - Verse range separators.\n * Defaults to `VerseRef.verseRangeSeparators`.\n * @param verseSequenceSeparators - Verse sequence separators.\n * Defaults to `VerseRef.verseSequenceIndicators`.\n * @returns An array of all single verse references in this VerseRef.\n */\n allVerses(e = !1, s = i.verseRangeSeparators, r = i.verseSequenceIndicators) {\n if (this._verse == null || this.chapterNum <= 0)\n return [this.clone()];\n const a = [], o = E(this._verse, r);\n for (const u of o.map((f) => E(f, s))) {\n const f = this.clone();\n f.verse = u[0];\n const d = f.verseNum;\n if (a.push(f), u.length > 1) {\n const b = this.clone();\n if (b.verse = u[1], !e)\n for (let p = d + 1; p < b.verseNum; p++) {\n const J = new i(\n this._bookNum,\n this._chapterNum,\n p,\n this.versification\n );\n this.isExcluded || a.push(J);\n }\n a.push(b);\n }\n }\n return a;\n }\n /**\n * Validates a verse number using the supplied separators rather than the defaults.\n */\n validateVerse(e, s) {\n if (!this.verse)\n return this.internalValid;\n let r = 0;\n for (const a of this.allVerses(!0, e, s)) {\n const o = a.internalValid;\n if (o !== 0)\n return o;\n const u = a.BBBCCCVVV;\n if (r > u)\n return 3;\n if (r === u)\n return 4;\n r = u;\n }\n return 0;\n }\n /**\n * Gets whether a single verse reference is valid.\n */\n get internalValid() {\n return this.versification == null ? 1 : this._bookNum <= 0 || this._bookNum > m.lastBook ? 2 : (m.isCanonical(this._bookNum), 0);\n }\n setEmpty(e = i.defaultVersification) {\n this._bookNum = 0, this._chapterNum = -1, this._verse = void 0, this.versification = e;\n }\n updateInternal(e, s, r) {\n this.bookNum = m.bookIdToNumber(e), this.chapter = s, this.verse = r;\n }\n};\nn(i, \"defaultVersification\", c.English), n(i, \"verseRangeSeparator\", \"-\"), n(i, \"verseSequenceIndicator\", \",\"), n(i, \"verseRangeSeparators\", [i.verseRangeSeparator]), n(i, \"verseSequenceIndicators\", [i.verseSequenceIndicator]), n(i, \"chapterDigitShifter\", 1e3), n(i, \"bookDigitShifter\", i.chapterDigitShifter * i.chapterDigitShifter), n(i, \"bcvMaxValue\", i.chapterDigitShifter - 1), /**\n * The valid status of the VerseRef.\n */\nn(i, \"ValidStatusType\", D);\nlet M = i;\nclass v extends Error {\n}\nexport {\n _ as BookSet,\n m as Canon,\n c as ScrVers,\n l as ScrVersType,\n M as VerseRef,\n v as VerseRefException\n};\n//# sourceMappingURL=index.es.js.map\n","import React from 'react';\nimport * as DropdownMenuPrimitive from '@radix-ui/react-dropdown-menu';\nimport { Check, ChevronRight, Circle } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport const DropdownMenu = DropdownMenuPrimitive.Root;\n\nexport const DropdownMenuTrigger = DropdownMenuPrimitive.Trigger;\n\nexport const DropdownMenuGroup = DropdownMenuPrimitive.Group;\n\nexport const DropdownMenuPortal = DropdownMenuPrimitive.Portal;\n\nexport const DropdownMenuSub = DropdownMenuPrimitive.Sub;\n\nexport const DropdownMenuRadioGroup = DropdownMenuPrimitive.RadioGroup;\n\nexport type DropdownMenuSubTriggerProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.SubTrigger\n> & {\n className?: string;\n inset?: boolean;\n};\n\nexport type DropdownMenuSubContentProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.SubContent\n> & {\n className?: string;\n};\n\nexport type DropdownMenuContentProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Content\n> & {\n className?: string;\n sideOffset?: number;\n};\n\nexport type DropdownMenuItemProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Item\n> & {\n className?: string;\n inset?: boolean;\n};\n\nexport type DropdownMenuCheckboxItemProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.CheckboxItem\n> & {\n className?: string;\n checked?: boolean;\n};\n\nexport type DropdownMenuRadioItemProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.RadioItem\n> & {\n className?: string;\n};\n\nexport type DropdownMenuLabelProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Label\n> & {\n className?: string;\n inset?: boolean;\n};\n\nexport type DropdownMenuSeparatorProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Separator\n> & {\n className?: string;\n};\n\nexport type DropdownMenuShortcutProps = React.HTMLAttributes & {\n className?: string;\n};\n\nexport const DropdownMenuSubTrigger = React.forwardRef<\n React.ElementRef,\n DropdownMenuSubTriggerProps\n>(({ className, inset, children, ...props }, ref) => (\n \n {children}\n \n \n));\nDropdownMenuSubTrigger.displayName = DropdownMenuPrimitive.SubTrigger.displayName;\n\nexport const DropdownMenuSubContent = React.forwardRef<\n React.ElementRef,\n DropdownMenuSubContentProps\n>(({ className, ...props }, ref) => (\n \n));\nDropdownMenuSubContent.displayName = DropdownMenuPrimitive.SubContent.displayName;\n\nexport const DropdownMenuContent = React.forwardRef<\n React.ElementRef,\n DropdownMenuContentProps\n>(({ className, sideOffset = 4, ...props }, ref) => (\n \n \n \n));\nDropdownMenuContent.displayName = DropdownMenuPrimitive.Content.displayName;\n\n/**\n * TODO: fix: direction is not automatically handled by this component, so that shortcuts are\n * display always to the right\n */\nexport const DropdownMenuItem = React.forwardRef<\n React.ElementRef,\n DropdownMenuItemProps\n>(({ className, inset, ...props }, ref) => (\n \n));\nDropdownMenuItem.displayName = DropdownMenuPrimitive.Item.displayName;\n\nexport const DropdownMenuCheckboxItem = React.forwardRef<\n React.ElementRef,\n DropdownMenuCheckboxItemProps\n>(({ className, children, checked, ...props }, ref) => (\n \n \n \n \n \n \n {children}\n \n));\nDropdownMenuCheckboxItem.displayName = DropdownMenuPrimitive.CheckboxItem.displayName;\n\nexport const DropdownMenuRadioItem = React.forwardRef<\n React.ElementRef,\n DropdownMenuRadioItemProps\n>(({ className, children, ...props }, ref) => (\n \n \n \n \n \n \n {children}\n \n));\nDropdownMenuRadioItem.displayName = DropdownMenuPrimitive.RadioItem.displayName;\n\nexport const DropdownMenuLabel = React.forwardRef<\n React.ElementRef,\n DropdownMenuLabelProps\n>(({ className, inset, ...props }, ref) => (\n \n));\nDropdownMenuLabel.displayName = DropdownMenuPrimitive.Label.displayName;\n\nexport const DropdownMenuSeparator = React.forwardRef<\n React.ElementRef,\n DropdownMenuSeparatorProps\n>(({ className, ...props }, ref) => (\n \n));\nDropdownMenuSeparator.displayName = DropdownMenuPrimitive.Separator.displayName;\n\nexport function DropdownMenuShortcut({ className, ...props }: DropdownMenuShortcutProps) {\n return (\n \n );\n}\nDropdownMenuShortcut.displayName = 'DropdownMenuShortcut';\n","import { Canon } from '@sillsdev/scripture';\nimport { PropsWithChildren, KeyboardEvent, forwardRef } from 'react';\nimport { DropdownMenuItem as ShadDropdownMenuItem } from '@/components/shadcn-ui/dropdown-menu';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport type BookType = 'OT' | 'NT' | 'DC';\n\ntype BookMenuItemProps = PropsWithChildren<{\n /** String id of book */\n bookId: string;\n /** Callback to run when a book menu item is selected */\n handleSelectBook: () => void;\n /** Indicates if this menu item is currently selected */\n isSelected: boolean;\n /** Function that is called upon highlighting a book in the dropdown menu */\n handleHighlightBook: () => void;\n /**\n * Function that is called on pressing a key\n *\n * @param event Event that contains information about the key stroke\n */\n handleKeyDown: (event: KeyboardEvent) => void;\n /**\n * Type of book associated with this menu item, coordinates color labels ? Mock up has the labels\n * coordinated to genre\n */\n bookType: BookType;\n}>;\n\nconst BookMenuItem = forwardRef(\n (\n {\n bookId,\n handleSelectBook,\n isSelected,\n handleHighlightBook,\n handleKeyDown,\n bookType,\n children,\n }: BookMenuItemProps,\n ref,\n ) => {\n return (\n {\n // preventDefault() here prevents the entire dropdown menu from closing when selecting this item\n event.preventDefault();\n handleSelectBook();\n }}\n onKeyDown={(event: KeyboardEvent) => {\n handleKeyDown(event);\n }}\n onFocus={handleHighlightBook}\n onMouseMove={handleHighlightBook}\n >\n \n {Canon.bookIdToEnglishName(bookId)}\n \n {isSelected &&
    {children}
    }\n \n );\n },\n);\n\nexport default BookMenuItem;\n","import { cn } from '@/utils/shadcn-ui.util';\nimport { useCallback } from 'react';\n\nexport type ChapterSelectProps = {\n /**\n * Callback to run when a chapter div is selected\n *\n * @param chapterNumber Number of the chapter that has been selected\n */\n handleSelectChapter: (chapterNumber: number) => void;\n /** The highest chapter number in the book (of course equal to number of chapters in the book) */\n endChapter: number;\n /** The chapter number that is currently selected */\n activeChapter: number;\n /** The chapter number that is currently highlighted using keyboard or mouse navigation */\n highlightedChapter: number;\n /**\n * Callback to run when a chapter is highlighted by the user\n *\n * @param chapterNumber The chapter that is highlighted\n */\n handleHighlightedChapter: (chapterNumber: number) => void;\n};\n\nfunction ChapterSelect({\n handleSelectChapter,\n endChapter,\n activeChapter,\n highlightedChapter,\n handleHighlightedChapter,\n}: ChapterSelectProps) {\n const chapters = Array.from({ length: endChapter }, (_, i) => i + 1);\n\n const handleMouse = useCallback(\n (chapterNumber: number) => {\n handleHighlightedChapter(chapterNumber);\n },\n [handleHighlightedChapter],\n );\n\n return (\n
    \n {chapters.map((chapter) => (\n {\n event.preventDefault();\n event.stopPropagation();\n handleSelectChapter(chapter);\n }}\n role=\"button\"\n onKeyDown={(event) => {\n if (event.key === 'Enter') {\n handleSelectChapter(chapter);\n }\n }}\n tabIndex={0}\n onMouseMove={() => handleMouse(chapter)}\n >\n {chapter}\n
    \n ))}\n
    \n );\n}\n\nexport default ChapterSelect;\n","import { DropdownMenuLabel as ShadDropdownMenuLabel } from '@/components/shadcn-ui/dropdown-menu';\nimport { Bookmark, Clock, ArrowDownWideNarrow } from 'lucide-react';\n\nexport type GoToMenuItemProps = {\n handleSort: () => void;\n handleLocationHistory: () => void;\n handleBookmarks: () => void;\n};\n\nfunction GoToMenuItem({ handleSort, handleLocationHistory, handleBookmarks }: GoToMenuItemProps) {\n return (\n \n

    Go To

    \n
    \n \n \n \n
    \n
    \n );\n}\n\nexport default GoToMenuItem;\n","import BookChapterInput from '@/components/advanced/book-chapter-control/book-chapter-input.component';\nimport BookMenuItem, {\n BookType,\n} from '@/components/advanced/book-chapter-control/book-menu-item.component';\nimport ChapterSelect from '@/components/advanced/book-chapter-control/chapter-select.component';\nimport GoToMenuItem from '@/components/advanced/book-chapter-control/go-to-menu-item.component';\nimport {\n DropdownMenu as ShadDropdownMenu,\n DropdownMenuContent as ShadDropdownMenuContent,\n DropdownMenuLabel as ShadDropdownMenuLabel,\n DropdownMenuSeparator as ShadDropdownMenuSeparator,\n DropdownMenuTrigger as ShadDropdownMenuTrigger,\n} from '@/components/shadcn-ui/dropdown-menu';\nimport { Canon } from '@sillsdev/scripture';\nimport { ScriptureReference, getChaptersForBook } from 'platform-bible-utils';\nimport {\n KeyboardEvent as ReactKeyboardEvent,\n useCallback,\n useEffect,\n useLayoutEffect,\n useRef,\n useState,\n} from 'react';\n\ntype BookTypeLabels = {\n [bookType in BookType]: string;\n};\ntype BookChapterControlProps = {\n scrRef: ScriptureReference;\n handleSubmit: (scrRef: ScriptureReference) => void;\n};\n\nconst ALL_BOOK_IDS = Canon.allBookIds;\nconst BOOK_TYPE_LABELS: BookTypeLabels = {\n OT: 'Old Testament',\n NT: 'New Testament',\n DC: 'Deuterocanon',\n};\nconst BOOK_TYPE_ARRAY: BookType[] = ['OT', 'NT', 'DC'];\n// This is the height of three menu items to offset scrolling to the selected menu item\n// If you use menuItemRef.clientHeight- includes height of chapter div which is too big\nconst SCROLL_OFFSET = 32 + 32 + 32;\nconst SEARCH_QUERY_FORMATS = [\n /^(\\w+)$/i, // Matches a single word (book name or id)\n /^(\\w+)(?:\\s(\\d+))$/i, // Matches a word followed by a chapter number\n /^(\\w+)(?:\\s(\\d+):(\\d+))$/i, // Matches a word followed by a chapter and verse number\n];\nconst fetchGroupedBooks = (bookType: BookType) => {\n const groupedBooks = {\n OT: ALL_BOOK_IDS.filter((bookId) => Canon.isBookOT(bookId)),\n NT: ALL_BOOK_IDS.filter((bookId) => Canon.isBookNT(bookId)),\n DC: ALL_BOOK_IDS.filter((bookId) => Canon.isBookDC(bookId)),\n };\n return groupedBooks[bookType];\n};\nconst fetchEndChapter = (bookId: string) => {\n // getChaptersForBook returns -1 if not found in scrBookData\n // scrBookData only includes OT and NT, so all DC will return -1\n return getChaptersForBook(Canon.bookIdToNumber(bookId));\n};\n\n/**\n * Gets all of the English names from book ids\n *\n * @returns String[]\n */\nfunction getAllEnglishNames(): string[] {\n const allEnglishNames = ALL_BOOK_IDS.map((bookId) => {\n return Canon.bookIdToEnglishName(bookId);\n });\n return allEnglishNames;\n}\n\n/**\n * Determines if bookName is in allEnglishNames\n *\n * @param bookName Book English name\n * @returns True if bookName is included, false otherwise\n */\nfunction isValidBookEnglishName(bookName: string): boolean {\n return getAllEnglishNames().includes(bookName);\n}\n\n/**\n * Gets a bookId from given English name\n *\n * @param bookName Book English name\n * @returns BookId of provided bookName, undefined otherwise\n */\nfunction getBookIdFromEnglishName(bookName: string): string | undefined {\n // Convert bookName to lowercase and then capitalize the first letter\n const formattedBookName = bookName.toLowerCase().replace(/^\\w/, (c) => c.toUpperCase());\n\n if (isValidBookEnglishName(formattedBookName)) {\n const matchingBookId = ALL_BOOK_IDS.find((bookId) => {\n return Canon.bookIdToEnglishName(bookId) === formattedBookName;\n });\n return matchingBookId;\n }\n\n return undefined;\n}\n\nfunction BookChapterControl({ scrRef, handleSubmit }: BookChapterControlProps) {\n const [searchQuery, setSearchQuery] = useState('');\n const [selectedBookId, setSelectedBookId] = useState(\n Canon.bookNumberToId(scrRef.bookNum),\n );\n const [highlightedChapter, setHighlightedChapter] = useState(scrRef.chapterNum ?? 0);\n const [highlightedBookId, setHighlightedBookId] = useState(\n Canon.bookNumberToId(scrRef.bookNum),\n );\n const [isContentOpen, setIsContentOpen] = useState(false);\n const [isContentOpenDelayed, setIsContentOpenDelayed] = useState(isContentOpen);\n\n // This ref will always be defined\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const inputRef = useRef(undefined!);\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const contentRef = useRef(undefined!);\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const menuItemRef = useRef(undefined!);\n\n const fetchFilteredBooks = useCallback(\n (bookType: BookType) => {\n return fetchGroupedBooks(bookType).filter((bookId: string) => {\n const englishNameLowerCase = Canon.bookIdToEnglishName(bookId).toLowerCase();\n const normalizedQuery = searchQuery.replace(/[^a-zA-Z]/g, '').toLowerCase();\n return (\n englishNameLowerCase.includes(normalizedQuery) || // Match book name\n bookId.toLowerCase().includes(normalizedQuery) // Match book ID\n );\n });\n },\n [searchQuery],\n );\n\n const handleSearchInput = (searchString: string) => {\n setSearchQuery(searchString);\n };\n\n /**\n * Whether to prevent radix's logic from closing the dropdown. This is important because radix\n * tries to close the dropdown when the input first focuses, and we don't want it to do that. But\n * we don't want to prevent the dropdown from closing when we click away from the input, so we\n * don't want to just keep it open if the input is focused\n */\n const shouldPreventAutoClosing = useRef(false);\n\n const controlMenuState = useCallback((open: boolean) => {\n if (shouldPreventAutoClosing.current) {\n shouldPreventAutoClosing.current = false;\n return;\n }\n setIsContentOpen(open);\n }, []);\n\n const updateReference = useCallback(\n (bookId: string, shouldClose: boolean, chapter?: number, verse?: number) => {\n setHighlightedChapter(\n Canon.bookNumberToId(scrRef.bookNum) !== bookId ? 1 : scrRef.chapterNum,\n );\n\n if (shouldClose || fetchEndChapter(bookId) === -1) {\n handleSubmit({\n bookNum: Canon.bookIdToNumber(bookId),\n chapterNum: chapter || 1,\n verseNum: verse || 1,\n });\n\n setIsContentOpen(false);\n setSearchQuery('');\n return;\n }\n\n setSelectedBookId(selectedBookId !== bookId ? bookId : '');\n setIsContentOpen(!shouldClose);\n },\n [handleSubmit, scrRef.bookNum, scrRef.chapterNum, selectedBookId],\n );\n\n const handleSelectChapter = (chapterNumber: number) => {\n if (chapterNumber <= 0 || chapterNumber > fetchEndChapter(selectedBookId)) {\n return;\n }\n updateReference(selectedBookId, true, chapterNumber);\n };\n\n const handleInputSubmit = useCallback(() => {\n SEARCH_QUERY_FORMATS.forEach((format) => {\n const matches = searchQuery.match(format);\n if (matches) {\n // Book should be a bookId or an english name\n const [book, chapter = undefined, verse = undefined] = matches.slice(1);\n const englishName = getBookIdFromEnglishName(book);\n\n if (Canon.isBookIdValid(book) || englishName) {\n updateReference(\n englishName ?? book,\n true,\n chapter ? parseInt(chapter, 10) : 1,\n verse ? parseInt(verse, 10) : 1,\n );\n }\n }\n });\n }, [updateReference, searchQuery]);\n\n const handleKeyDownInput = useCallback(\n (event: ReactKeyboardEvent) => {\n if (!isContentOpen) {\n setIsContentOpen(true);\n } else if (event.key === 'ArrowDown' || event.key === 'ArrowUp') {\n if (\n typeof menuItemRef !== 'undefined' &&\n // Ref uses null\n // eslint-disable-next-line no-null/no-null\n menuItemRef.current !== null\n ) {\n menuItemRef.current.focus();\n } else if (\n typeof contentRef !== 'undefined' &&\n // Ref uses null\n // eslint-disable-next-line no-null/no-null\n contentRef.current !== null\n ) {\n contentRef.current.focus();\n }\n event.preventDefault();\n }\n },\n [isContentOpen],\n );\n\n const handleKeyDownContent = (event: ReactKeyboardEvent) => {\n // When the dropdown menu has focus, key strokes should give focus to the input component,\n // unless they're navigation keys (arrows and enter)\n const { key } = event;\n if (\n key === 'ArrowRight' ||\n key === 'ArrowLeft' ||\n key === 'ArrowDown' ||\n key === 'ArrowUp' ||\n key === 'Enter'\n ) {\n return;\n }\n\n inputRef.current.dispatchEvent(new KeyboardEvent('keydown', { key }));\n inputRef.current.focus();\n };\n\n const handleKeyDownMenuItem = (event: ReactKeyboardEvent) => {\n const { key } = event;\n if (highlightedBookId === selectedBookId) {\n if (key === 'Enter') {\n event.preventDefault();\n updateReference(selectedBookId, true, highlightedChapter);\n return;\n }\n\n let chapterOffSet = 0;\n if (key === 'ArrowRight') {\n if (highlightedChapter < fetchEndChapter(highlightedBookId)) {\n chapterOffSet = 1;\n } else {\n event.preventDefault();\n return;\n }\n } else if (key === 'ArrowLeft') {\n if (highlightedChapter > 1) {\n chapterOffSet = -1;\n } else {\n event.preventDefault();\n return;\n }\n } else if (key === 'ArrowDown') {\n chapterOffSet = 6;\n } else if (key === 'ArrowUp') {\n chapterOffSet = -6;\n }\n if (\n highlightedChapter + chapterOffSet <= 0 ||\n highlightedChapter + chapterOffSet > fetchEndChapter(highlightedBookId)\n ) {\n setHighlightedChapter(0);\n } else if (chapterOffSet !== 0) {\n setHighlightedChapter(highlightedChapter + chapterOffSet);\n event.preventDefault();\n }\n }\n };\n\n useEffect(() => {\n if (selectedBookId === highlightedBookId) {\n if (selectedBookId === Canon.bookNumberToId(scrRef.bookNum)) {\n setHighlightedChapter(scrRef.chapterNum);\n } else {\n setHighlightedChapter(1);\n }\n } else {\n setHighlightedChapter(0);\n }\n }, [highlightedBookId, scrRef.bookNum, scrRef.chapterNum, selectedBookId]);\n\n // The purpose of these useLayoutEffects and timeout is to delay the scroll just\n // enough so that the refs are defined and available when they are used after the timeout\n useLayoutEffect(() => {\n setIsContentOpenDelayed(isContentOpen);\n }, [isContentOpen]);\n\n useLayoutEffect(() => {\n const scrollTimeout = setTimeout(() => {\n if (isContentOpenDelayed && contentRef.current && menuItemRef.current) {\n const menuItemOffsetTop = menuItemRef.current.offsetTop;\n const scrollPosition = menuItemOffsetTop - SCROLL_OFFSET;\n contentRef.current.scrollTo({ top: scrollPosition, behavior: 'instant' });\n }\n }, 10);\n return () => {\n clearTimeout(scrollTimeout);\n };\n }, [isContentOpenDelayed]);\n\n return (\n
    \n \n \n {\n setSelectedBookId(Canon.bookNumberToId(scrRef.bookNum));\n setHighlightedBookId(Canon.bookNumberToId(scrRef.bookNum));\n setHighlightedChapter(scrRef.chapterNum > 0 ? scrRef.chapterNum : 0);\n setIsContentOpen(true);\n inputRef.current.focus();\n }}\n onFocus={() => {\n // Radix thinks we want to close because the input is being focused. Prevent that\n shouldPreventAutoClosing.current = true;\n }}\n handleSubmit={handleInputSubmit}\n placeholder={`${Canon.bookNumberToEnglishName(scrRef.bookNum)} ${scrRef.chapterNum}:${scrRef.verseNum}`}\n />\n \n \n console.log('sorting')}\n handleLocationHistory={() => console.log('location history')}\n handleBookmarks={() => console.log('bookmarks')}\n />\n {BOOK_TYPE_ARRAY.map(\n (bookType, bookTypeIndex) =>\n fetchFilteredBooks(bookType).length > 0 && (\n
    \n \n {BOOK_TYPE_LABELS[bookType]}\n \n\n {fetchFilteredBooks(bookType).map((bookId) => (\n
    \n updateReference(bookId, false)}\n isSelected={selectedBookId === bookId}\n handleHighlightBook={() => setHighlightedBookId(bookId)}\n handleKeyDown={handleKeyDownMenuItem}\n bookType={bookType}\n ref={(element: HTMLDivElement) => {\n if (selectedBookId === bookId) menuItemRef.current = element;\n }}\n >\n {\n setHighlightedChapter(chapterNumber);\n }}\n />\n \n
    \n ))}\n {BOOK_TYPE_ARRAY.length - 1 !== bookTypeIndex ? (\n \n ) : undefined}\n
    \n ),\n )}\n \n
    \n
    \n );\n}\n\nexport default BookChapterControl;\n","import React from 'react';\nimport { Slot } from '@radix-ui/react-slot';\nimport { cva, type VariantProps } from 'class-variance-authority';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport const buttonVariants = cva(\n 'pr-twp tw-inline-flex tw-items-center tw-justify-center tw-whitespace-nowrap tw-rounded-md tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-colors focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50',\n {\n variants: {\n variant: {\n default: 'tw-bg-primary tw-text-primary-foreground hover:tw-bg-primary/90',\n destructive: 'tw-bg-destructive tw-text-destructive-foreground hover:tw-bg-destructive/90',\n outline:\n 'tw-border tw-border-input tw-bg-background hover:tw-bg-accent hover:tw-text-accent-foreground',\n secondary: 'tw-bg-secondary tw-text-secondary-foreground hover:tw-bg-secondary/80',\n ghost: 'hover:tw-bg-accent hover:tw-text-accent-foreground',\n link: 'tw-text-primary tw-underline-offset-4 hover:tw-underline',\n },\n size: {\n default: 'tw-h-10 tw-px-4 tw-py-2',\n sm: 'tw-h-9 tw-rounded-md tw-px-3',\n lg: 'tw-h-11 tw-rounded-md tw-px-8',\n icon: 'tw-h-10 tw-w-10',\n },\n },\n defaultVariants: {\n variant: 'default',\n size: 'default',\n },\n },\n);\n\nexport interface ButtonProps\n extends React.ButtonHTMLAttributes,\n VariantProps {\n asChild?: boolean;\n}\n\nexport const Button = React.forwardRef(\n ({ className, variant, size, asChild = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'button';\n return (\n \n );\n },\n);\nButton.displayName = 'Button';\n","import React from 'react';\nimport * as LabelPrimitive from '@radix-ui/react-label';\nimport { cva, type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst labelVariants = cva(\n 'tw-text-sm tw-font-medium tw-leading-none peer-disabled:tw-cursor-not-allowed peer-disabled:tw-opacity-70',\n);\n\nexport const Label = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef & VariantProps\n>(({ className, ...props }, ref) => (\n \n));\nLabel.displayName = LabelPrimitive.Root.displayName;\n","import React from 'react';\nimport * as RadioGroupPrimitive from '@radix-ui/react-radio-group';\nimport { Circle } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst RadioGroup = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => {\n return (\n \n );\n});\nRadioGroup.displayName = RadioGroupPrimitive.Root.displayName;\n\nconst RadioGroupItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => {\n return (\n \n \n \n \n \n );\n});\nRadioGroupItem.displayName = RadioGroupPrimitive.Item.displayName;\n\nexport { RadioGroup, RadioGroupItem };\n","import React from 'react';\nimport * as PopoverPrimitive from '@radix-ui/react-popover';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Popover = PopoverPrimitive.Root;\n\nconst PopoverTrigger = PopoverPrimitive.Trigger;\n\nconst PopoverContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, align = 'center', sideOffset = 4, ...props }, ref) => (\n \n \n \n));\nPopoverContent.displayName = PopoverPrimitive.Content.displayName;\n\nexport { Popover, PopoverTrigger, PopoverContent };\n","import React from 'react';\nimport * as DialogPrimitive from '@radix-ui/react-dialog';\nimport { X } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Dialog = DialogPrimitive.Root;\n\nconst DialogTrigger = DialogPrimitive.Trigger;\n\nconst DialogPortal = DialogPrimitive.Portal;\n\nconst DialogClose = DialogPrimitive.Close;\n\nconst DialogOverlay = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nDialogOverlay.displayName = DialogPrimitive.Overlay.displayName;\n\nconst DialogContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, ...props }, ref) => (\n \n \n \n {children}\n \n \n Close\n \n \n \n));\nDialogContent.displayName = DialogPrimitive.Content.displayName;\n\nfunction DialogHeader({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nDialogHeader.displayName = 'DialogHeader';\n\nfunction DialogFooter({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nDialogFooter.displayName = 'DialogFooter';\n\nconst DialogTitle = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nDialogTitle.displayName = DialogPrimitive.Title.displayName;\n\nconst DialogDescription = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nDialogDescription.displayName = DialogPrimitive.Description.displayName;\n\nexport {\n Dialog,\n DialogPortal,\n DialogOverlay,\n DialogClose,\n DialogTrigger,\n DialogContent,\n DialogHeader,\n DialogFooter,\n DialogTitle,\n DialogDescription,\n};\n","import React from 'react';\nimport { type DialogProps } from '@radix-ui/react-dialog';\nimport { Command as CommandPrimitive } from 'cmdk';\nimport { Search } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Dialog, DialogContent } from '@/components/shadcn-ui/dialog';\n\nconst Command = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nCommand.displayName = CommandPrimitive.displayName;\n\ninterface CommandDialogProps extends DialogProps {}\n\nfunction CommandDialog({ children, ...props }: CommandDialogProps) {\n return (\n \n \n \n {children}\n \n \n \n );\n}\n\nconst CommandInput = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n
    \n \n \n
    \n));\n\nCommandInput.displayName = CommandPrimitive.Input.displayName;\n\nconst CommandList = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\n\nCommandList.displayName = CommandPrimitive.List.displayName;\n\nconst CommandEmpty = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>((props, ref) => (\n \n));\n\nCommandEmpty.displayName = CommandPrimitive.Empty.displayName;\n\nconst CommandGroup = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\n\nCommandGroup.displayName = CommandPrimitive.Group.displayName;\n\nconst CommandSeparator = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nCommandSeparator.displayName = CommandPrimitive.Separator.displayName;\n\nconst CommandItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\n\nCommandItem.displayName = CommandPrimitive.Item.displayName;\n\nfunction CommandShortcut({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nCommandShortcut.displayName = 'CommandShortcut';\n\nexport {\n Command,\n CommandDialog,\n CommandInput,\n CommandList,\n CommandEmpty,\n CommandGroup,\n CommandItem,\n CommandShortcut,\n CommandSeparator,\n};\n","import { useState } from 'react';\nimport { Check, ChevronsUpDown } from 'lucide-react';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport { Popover, PopoverContent, PopoverTrigger } from '@/components/shadcn-ui/popover';\nimport {\n Command,\n CommandEmpty,\n CommandInput,\n CommandItem,\n CommandList,\n} from '@/components/shadcn-ui/command';\nimport { PopoverProps } from '@radix-ui/react-popover';\n\nexport type ComboBoxLabelOption = { label: string };\nexport type ComboBoxOption = string | number | ComboBoxLabelOption;\n\nexport type ComboBoxProps = {\n /** Optional unique identifier */\n id?: string;\n /** Text label title for combobox */\n /** List of available options for the dropdown menu */\n options?: readonly T[];\n /** Additional css classes to help with unique styling of the combo box */\n className?: string;\n /**\n * The selected value that the combo box currently holds. Must be shallow equal to one of the\n * options entries.\n */\n value?: T;\n /** Triggers when content of textfield is changed */\n onChange?: (newValue: T) => void;\n /** Used to determine the string value for a given option. */\n getOptionLabel?: (option: ComboBoxOption) => string;\n /** Text displayed on button if `value` is undefined */\n buttonPlaceholder?: string;\n /** Placeholder text for text field */\n textPlaceholder?: string;\n /** Text to display when no options match input */\n commandEmptyMessage?: string;\n /** Variant of button */\n buttonVariant?: ButtonProps['variant'];\n /** Text direction ltr or rtl */\n dir?: Direction;\n /** Optional boolean to set if trigger should be disabled */\n isDisabled?: boolean;\n} & PopoverProps;\n\ntype Direction = 'ltr' | 'rtl';\n\nfunction getOptionLabelDefault(option: ComboBoxOption): string {\n if (typeof option === 'string') {\n return option;\n }\n if (typeof option === 'number') {\n return option.toString();\n }\n return option.label;\n}\n\n/**\n * Autocomplete input and command palette with a list of suggestions.\n *\n * Thanks to Shadcn for heavy inspiration and documentation\n * https://ui.shadcn.com/docs/components/combobox\n */\nfunction ComboBox({\n id,\n options = [],\n className,\n value,\n onChange = () => {},\n getOptionLabel = getOptionLabelDefault,\n buttonPlaceholder = '',\n textPlaceholder = '',\n commandEmptyMessage = 'No option found',\n buttonVariant = 'outline',\n dir = 'ltr',\n isDisabled = false,\n ...props\n}: ComboBoxProps) {\n const [open, setOpen] = useState(false);\n\n return (\n \n \n \n \n {value ? getOptionLabel(value) : buttonPlaceholder}\n \n \n \n \n \n \n \n {commandEmptyMessage}\n \n {options.map((option) => (\n {\n onChange(option);\n setOpen(false);\n }}\n >\n \n {getOptionLabel(option)}\n \n ))}\n \n \n \n \n );\n}\n\nexport default ComboBox;\n","import { useMemo } from 'react';\nimport ComboBox from '@/components/basics/combo-box.component';\nimport { Label } from '@/components/shadcn-ui/label';\n\nexport type ChapterRangeSelectorProps = {\n startChapter: number;\n endChapter: number;\n handleSelectStartChapter: (chapter: number) => void;\n handleSelectEndChapter: (chapter: number) => void;\n isDisabled?: boolean;\n chapterCount: number;\n};\n\nexport default function ChapterRangeSelector({\n startChapter,\n endChapter,\n handleSelectStartChapter,\n handleSelectEndChapter,\n isDisabled = false,\n chapterCount,\n}: ChapterRangeSelectorProps) {\n const chapterOptions = useMemo(\n () => Array.from({ length: chapterCount }, (_, index) => index + 1),\n [chapterCount],\n );\n\n const onChangeStartChapter = (value: number) => {\n handleSelectStartChapter(value);\n if (value > endChapter) {\n handleSelectEndChapter(value);\n }\n };\n\n const onChangeEndChapter = (value: number) => {\n handleSelectEndChapter(value);\n if (value < startChapter) {\n handleSelectStartChapter(value);\n }\n };\n\n return (\n <>\n \n option.toString()}\n value={startChapter}\n />\n\n \n option.toString()}\n value={endChapter}\n />\n \n );\n}\n","import { Button } from '@/components/shadcn-ui/button';\nimport { Label } from '@/components/shadcn-ui/label';\nimport { RadioGroup, RadioGroupItem } from '@/components/shadcn-ui/radio-group';\nimport { Canon } from '@sillsdev/scripture';\nimport { LocalizedStringValue } from 'platform-bible-utils';\nimport { useState } from 'react';\nimport ChapterRangeSelector, {\n ChapterRangeSelectorProps,\n} from '../basics/chapter-range-selector.component';\n\nexport enum BookSelectionMode {\n CURRENT_BOOK = 'current book',\n CHOOSE_BOOKS = 'choose books',\n}\n\n/**\n * Object containing all keys used for localization in this component. If you're using this\n * component in an extension, you can pass it into the useLocalizedStrings hook to easily obtain the\n * localized strings and pass them into the localizedStrings prop of this component\n */\nexport const BOOK_SELECTOR_STRING_KEYS = Object.freeze([\n '%webView_bookSelector_currentBook%',\n '%webView_bookSelector_choose%',\n '%webView_bookSelector_chooseBooks%',\n] as const);\n\nexport type BookSelectorLocalizedStrings = {\n [localizedInventoryKey in (typeof BOOK_SELECTOR_STRING_KEYS)[number]]?: LocalizedStringValue;\n};\n\n/**\n * Gets the localized value for the provided key\n *\n * @param strings Object containing localized string\n * @param key Key for a localized string\n * @returns The localized value for the provided key, if available. Returns the key if no localized\n * value is available\n */\nconst localizeString = (\n strings: BookSelectorLocalizedStrings,\n key: keyof BookSelectorLocalizedStrings,\n) => {\n return strings[key] ?? key;\n};\n\ntype BookSelectorProps = ChapterRangeSelectorProps & {\n handleBookSelectionModeChange: (newMode: BookSelectionMode) => void;\n currentBookName: string;\n onSelectBooks: () => void;\n selectedBookIds: string[];\n localizedStrings: BookSelectorLocalizedStrings;\n};\n\nexport default function BookSelector({\n handleBookSelectionModeChange,\n currentBookName,\n onSelectBooks,\n selectedBookIds,\n chapterCount,\n endChapter,\n handleSelectEndChapter,\n startChapter,\n handleSelectStartChapter,\n localizedStrings,\n}: BookSelectorProps) {\n const currentBookText = localizeString(localizedStrings, '%webView_bookSelector_currentBook%');\n const chooseText = localizeString(localizedStrings, '%webView_bookSelector_choose%');\n const chooseBooksText = localizeString(localizedStrings, '%webView_bookSelector_chooseBooks%');\n\n const [bookSelectionMode, setBookSelectionMode] = useState(\n BookSelectionMode.CURRENT_BOOK,\n );\n\n const onSelectionModeChange = (newMode: BookSelectionMode) => {\n setBookSelectionMode(newMode);\n handleBookSelectionModeChange(newMode);\n };\n\n return (\n onSelectionModeChange(value as BookSelectionMode)}\n >\n
    \n
    \n
    \n \n \n
    \n \n
    \n \n
    \n
    \n
    \n
    \n \n \n
    \n \n onSelectBooks()}\n >\n {chooseText}\n \n
    \n
    \n \n );\n}\n","import { DropdownMenuTrigger } from '@radix-ui/react-dropdown-menu';\nimport { FilterIcon } from 'lucide-react';\nimport { Table } from '@tanstack/react-table';\n\nimport { Button } from '@/components/shadcn-ui/button';\nimport {\n DropdownMenu,\n DropdownMenuCheckboxItem,\n DropdownMenuContent,\n DropdownMenuLabel,\n DropdownMenuSeparator,\n} from '@/components/shadcn-ui/dropdown-menu';\n\ninterface DataTableViewOptionsProps {\n table: Table;\n}\n\nfunction DataTableViewOptions({ table }: DataTableViewOptionsProps) {\n return (\n \n \n \n \n \n Toggle columns\n \n {table\n .getAllColumns()\n .filter((column) => column.getCanHide())\n .map((column) => {\n return (\n column.toggleVisibility(!!value)}\n >\n {column.id}\n \n );\n })}\n \n \n );\n}\n\nexport default DataTableViewOptions;\n","import React from 'react';\nimport * as SelectPrimitive from '@radix-ui/react-select';\nimport { Check, ChevronDown, ChevronUp } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Select = SelectPrimitive.Root;\n\nconst SelectGroup = SelectPrimitive.Group;\n\nconst SelectValue = SelectPrimitive.Value;\n\nconst SelectTrigger = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, ...props }, ref) => (\n span]:tw-line-clamp-1',\n className,\n )}\n {...props}\n >\n {children}\n \n \n \n \n));\nSelectTrigger.displayName = SelectPrimitive.Trigger.displayName;\n\nconst SelectScrollUpButton = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n));\nSelectScrollUpButton.displayName = SelectPrimitive.ScrollUpButton.displayName;\n\nconst SelectScrollDownButton = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n));\nSelectScrollDownButton.displayName = SelectPrimitive.ScrollDownButton.displayName;\n\nconst SelectContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, position = 'popper', ...props }, ref) => (\n \n \n \n \n {children}\n \n \n \n \n));\nSelectContent.displayName = SelectPrimitive.Content.displayName;\n\nconst SelectLabel = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSelectLabel.displayName = SelectPrimitive.Label.displayName;\n\nconst SelectItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, ...props }, ref) => (\n \n \n \n \n \n \n\n {children}\n \n));\nSelectItem.displayName = SelectPrimitive.Item.displayName;\n\nconst SelectSeparator = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSelectSeparator.displayName = SelectPrimitive.Separator.displayName;\n\nexport {\n Select,\n SelectGroup,\n SelectValue,\n SelectTrigger,\n SelectContent,\n SelectLabel,\n SelectItem,\n SelectSeparator,\n SelectScrollUpButton,\n SelectScrollDownButton,\n};\n","import { ChevronLeftIcon, ChevronRightIcon, ArrowLeftIcon, ArrowRightIcon } from 'lucide-react';\nimport { Table } from '@tanstack/react-table';\n\nimport { Button } from '@/components/shadcn-ui/button';\nimport {\n Select,\n SelectContent,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\n\ninterface DataTablePaginationProps {\n table: Table;\n}\n\nfunction DataTablePagination({ table }: DataTablePaginationProps) {\n return (\n
    \n
    \n
    \n {table.getFilteredSelectedRowModel().rows.length} of{' '}\n {table.getFilteredRowModel().rows.length} row(s) selected\n
    \n
    \n

    Rows per page

    \n {\n table.setPageSize(Number(value));\n }}\n >\n \n \n \n \n {[10, 20, 30, 40, 50].map((pageSize) => (\n \n {pageSize}\n \n ))}\n \n \n
    \n
    \n Page {table.getState().pagination.pageIndex + 1} of {table.getPageCount()}\n
    \n
    \n table.setPageIndex(0)}\n disabled={!table.getCanPreviousPage()}\n >\n Go to first page\n \n \n table.previousPage()}\n disabled={!table.getCanPreviousPage()}\n >\n Go to previous page\n \n \n table.nextPage()}\n disabled={!table.getCanNextPage()}\n >\n Go to next page\n \n \n table.setPageIndex(table.getPageCount() - 1)}\n disabled={!table.getCanNextPage()}\n >\n Go to last page\n \n \n
    \n
    \n
    \n );\n}\n\nexport default DataTablePagination;\n","import React from 'react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Table = React.forwardRef<\n HTMLTableElement,\n React.HTMLAttributes & { stickyHeader?: boolean }\n>(({ className, stickyHeader, ...props }, ref) => (\n
    \n \n
    \n));\nTable.displayName = 'Table';\n\nconst TableHeader = React.forwardRef<\n HTMLTableSectionElement,\n React.HTMLAttributes & { stickyHeader?: boolean }\n>(({ className, stickyHeader, ...props }, ref) => (\n \n));\nTableHeader.displayName = 'TableHeader';\n\nconst TableBody = React.forwardRef<\n HTMLTableSectionElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableBody.displayName = 'TableBody';\n\nconst TableFooter = React.forwardRef<\n HTMLTableSectionElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n tr]:last:tw-border-b-0', className)}\n {...props}\n />\n));\nTableFooter.displayName = 'TableFooter';\n\nconst TableRow = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nTableRow.displayName = 'TableRow';\n\nconst TableHead = React.forwardRef<\n HTMLTableCellElement,\n React.ThHTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableHead.displayName = 'TableHead';\n\nconst TableCell = React.forwardRef<\n HTMLTableCellElement,\n React.TdHTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableCell.displayName = 'TableCell';\n\nconst TableCaption = React.forwardRef<\n HTMLTableCaptionElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableCaption.displayName = 'TableCaption';\n\nexport { Table, TableHeader, TableBody, TableFooter, TableHead, TableRow, TableCell, TableCaption };\n","import { useState } from 'react';\n\nimport {\n ColumnFiltersState,\n flexRender,\n getCoreRowModel,\n getFilteredRowModel,\n getPaginationRowModel,\n getSortedRowModel,\n SortingState,\n ColumnDef as TSColumnDef,\n Row as TSRow,\n RowSelectionState as TSRowSelectionState,\n SortDirection as TSSortDirection,\n Table as TSTable,\n useReactTable,\n VisibilityState,\n} from '@tanstack/react-table';\n\nimport DataTableViewOptions from '@/components/advanced/data-table/data-table-column-toggle.component';\nimport DataTablePagination from '@/components/advanced/data-table/data-table-pagination.component';\nimport { Button } from '@/components/shadcn-ui/button';\nimport {\n Table,\n TableBody,\n TableCell,\n TableHead,\n TableHeader,\n TableRow,\n} from '@/components/shadcn-ui/table';\n\nexport type ColumnDef = TSColumnDef;\nexport type RowContents = TSRow;\nexport type TableContents = TSTable;\nexport type SortDirection = TSSortDirection;\nexport type RowSelectionState = TSRowSelectionState;\n\ninterface DataTableProps {\n columns: ColumnDef[];\n data: TData[];\n enablePagination?: boolean;\n showPaginationControls?: boolean;\n showColumnVisibilityControls?: boolean;\n stickyHeader?: boolean;\n onRowClickHandler?: (row: RowContents, table: TableContents) => void;\n}\n\n/**\n * Feature-rich table component that infuses our basic shadcn-based Table component with features\n * from TanStack's React Table library\n */\nfunction DataTable({\n columns,\n data,\n enablePagination = false,\n showPaginationControls = false,\n showColumnVisibilityControls = false,\n stickyHeader = false,\n onRowClickHandler = () => {},\n}: DataTableProps) {\n const [sorting, setSorting] = useState([]);\n const [columnFilters, setColumnFilters] = useState([]);\n const [columnVisibility, setColumnVisibility] = useState({});\n const [rowSelection, setRowSelection] = useState({});\n\n const table = useReactTable({\n data,\n columns,\n getCoreRowModel: getCoreRowModel(),\n ...(enablePagination && { getPaginationRowModel: getPaginationRowModel() }),\n onSortingChange: setSorting,\n getSortedRowModel: getSortedRowModel(),\n onColumnFiltersChange: setColumnFilters,\n getFilteredRowModel: getFilteredRowModel(),\n onColumnVisibilityChange: setColumnVisibility,\n onRowSelectionChange: setRowSelection,\n state: {\n sorting,\n columnFilters,\n columnVisibility,\n rowSelection,\n },\n });\n\n return (\n
    \n {showColumnVisibilityControls && }\n \n \n {table.getHeaderGroups().map((headerGroup) => (\n \n {headerGroup.headers.map((header) => {\n return (\n \n {header.isPlaceholder\n ? undefined\n : flexRender(header.column.columnDef.header, header.getContext())}\n \n );\n })}\n \n ))}\n \n \n {table.getRowModel().rows?.length ? (\n table.getRowModel().rows.map((row) => (\n onRowClickHandler(row, table)}\n key={row.id}\n data-state={row.getIsSelected() && 'selected'}\n >\n {row.getVisibleCells().map((cell) => (\n \n {flexRender(cell.column.columnDef.cell, cell.getContext())}\n \n ))}\n \n ))\n ) : (\n \n \n No results.\n \n \n )}\n \n
    \n {enablePagination && (\n
    \n table.previousPage()}\n disabled={!table.getCanPreviousPage()}\n >\n Previous\n \n table.nextPage()}\n disabled={!table.getCanNextPage()}\n >\n Next\n \n
    \n )}\n {enablePagination && showPaginationControls && }\n
    \n );\n}\n\nexport default DataTable;\n","import {\n Table,\n TableBody,\n TableCell,\n TableHead,\n TableHeader,\n TableRow,\n} from '@/components/shadcn-ui/table';\nimport { Canon } from '@sillsdev/scripture';\nimport { deepEqual, LanguageStrings, ScriptureReference } from 'platform-bible-utils';\nimport { useMemo } from 'react';\nimport { InventoryItemOccurrence } from './inventory-utils';\n\n/** Props for the OccurrencesTable component */\ntype OccurrencesTableProps = {\n /** Data that contains scriptures references and snippets of scripture */\n occurrenceData: InventoryItemOccurrence[];\n /** Callback function that is executed when the scripture reference is changed */\n setScriptureReference: (scriptureReference: ScriptureReference) => void;\n /**\n * Object with all localized strings that the OccurrencesTable needs to work well across multiple\n * languages\n */\n localizedStrings: LanguageStrings;\n};\n\n/**\n * Table that shows occurrences of specified inventory item(s). The first column shows the related\n * scripture reference. The second column shows the snippet of scripture that contains the specified\n * inventory item\n */\nfunction OccurrencesTable({\n occurrenceData,\n setScriptureReference,\n localizedStrings,\n}: OccurrencesTableProps) {\n const referenceHeaderText =\n localizedStrings['%webView_inventory_occurrences_table_header_reference%'];\n const occurrenceHeaderText =\n localizedStrings['%webView_inventory_occurrences_table_header_occurrence%'];\n\n const occurrences: InventoryItemOccurrence[] = useMemo(() => {\n const uniqueOccurrences: InventoryItemOccurrence[] = [];\n\n occurrenceData.forEach((occurrence) => {\n if (!uniqueOccurrences.some((uniqueOccurrence) => deepEqual(uniqueOccurrence, occurrence))) {\n uniqueOccurrences.push(occurrence);\n }\n });\n\n return uniqueOccurrences;\n }, [occurrenceData]);\n\n return (\n \n \n \n {referenceHeaderText}\n {occurrenceHeaderText}\n \n \n \n {occurrences.length > 0 &&\n occurrences.map((occurrence) => (\n {\n setScriptureReference(occurrence.reference);\n }}\n >\n {`${Canon.bookNumberToEnglishName(occurrence.reference.bookNum)} ${occurrence.reference.chapterNum}:${occurrence.reference.verseNum}`}\n {occurrence.text}\n \n ))}\n \n
    \n );\n}\n\nexport default OccurrencesTable;\n","import React from 'react';\nimport * as CheckboxPrimitive from '@radix-ui/react-checkbox';\nimport { Check } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Checkbox = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n \n \n));\nCheckbox.displayName = CheckboxPrimitive.Root.displayName;\n\nexport default Checkbox;\n","import { Canon } from '@sillsdev/scripture';\nimport { ScriptureReference } from 'platform-bible-utils';\n\n/* #region Types */\n\n/**\n * Status of items that appear in inventories. 'approved' and 'unapproved' items are defined in the\n * project's `Settings.xml`. All other items are defined as 'unknown'\n */\nexport type Status = 'approved' | 'unapproved' | 'unknown';\n\n/** Occurrence of item in inventory. Primarily used by table that shows occurrences */\nexport type InventoryItemOccurrence = {\n /** Reference to scripture where the item appears */\n reference: ScriptureReference;\n /** Snippet of scripture that contains the occurrence */\n text: string;\n};\n\n/** Data structure that contains all information on an item that is shown in an inventory */\nexport type InventoryTableData = {\n /**\n * The item (e.g. a character in the characters inventory, a marker in the marker inventory) In\n * most cases the array will only have one element. In case of additional items (e.g. the\n * preceding marker in the markers check), the primary item should be stored in the first index.\n * To show additional items in the inventory, make sure to configure the `additionalItemsLabels`\n * prop for the Inventory component\n */\n items: string[];\n /** The number of times this item occurs in the selected scope */\n count: number;\n /** The status of this item (see documentation for `Status` type for more information) */\n status: Status;\n /** Occurrences of this item in the scripture text for the selected scope */\n occurrences: InventoryItemOccurrence[];\n};\n\n/* #endregion */\n\n/* #region Functions */\n\n/**\n * Splits USFM string into shorter line-like segments\n *\n * @param text A single (likely very large) USFM string\n * @returns An array containing the input text, split into shorter segments\n */\nexport const getLinesFromUSFM = (text: string) => {\n // Splits on (CR)LF, CR, \\v, \\c and \\id\n return text.split(/(?:\\r?\\n|\\r)|(?=(?:\\\\(?:v|c|id)))/g);\n};\n\n/**\n * Extracts chapter or verse number from USFM strings that start with a \\c or \\v marker\n *\n * @param text USFM string that is expected to start with \\c or \\v marker\n * @returns Chapter or verse number if one is found. Else returns 0.\n */\nexport const getNumberFromUSFM = (text: string): number | undefined => {\n // Captures all digits that follow \\v or \\c markers followed by whitespace located at the start of a string\n const regex = /^\\\\[vc]\\s+(\\d+)/;\n const match = text.match(regex);\n\n if (match) {\n return +match[1];\n }\n return undefined;\n};\n\n/**\n * Gets book ID from USFM string that starts with the \\id marker, and returns book number for it\n *\n * @param text USFM string that is expected to start with \\id marker\n * @returns Book number corresponding to the \\id marker in the input text. Returns 0 if no marker is\n * found or the marker is not valid\n */\nexport const getBookNumFromId = (text: string): number => {\n // Captures all digits that follow an \\id marker followed by whitespace located at the start of a string\n const match = text.match(/^\\\\id\\s+([A-Za-z]+)/);\n if (match) {\n return Canon.bookIdToNumber(match[1]);\n }\n return 0;\n};\n\n/**\n * Gets the status for an item, typically used in the Inventory component\n *\n * @param item The item for which the status is being requested\n * @param approvedItems Array of approved items, typically as defined in `Settings.xml`\n * @param unapprovedItems Array of unapproved items, typically as defined in `Settings.xml`\n * @returns The status for the specified item\n */\nexport const getStatusForItem = (\n item: string,\n approvedItems: string[],\n unapprovedItems: string[],\n): Status => {\n if (unapprovedItems.includes(item)) return 'unapproved';\n if (approvedItems.includes(item)) return 'approved';\n return 'unknown';\n};\n\n/* #endregion */\n","import React from 'react';\nimport * as TogglePrimitive from '@radix-ui/react-toggle';\nimport { cva, type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst toggleVariants = cva(\n 'pr-twp tw-inline-flex tw-items-center tw-justify-center tw-rounded-md tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-colors hover:tw-bg-muted hover:tw-text-muted-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50 data-[state=on]:tw-bg-accent data-[state=on]:tw-text-accent-foreground',\n {\n variants: {\n variant: {\n default: 'tw-bg-transparent',\n outline:\n 'tw-border tw-border-input tw-bg-transparent hover:tw-bg-accent hover:tw-text-accent-foreground',\n },\n size: {\n default: 'tw-h-10 tw-px-3',\n sm: 'tw-h-9 tw-px-2.5',\n lg: 'tw-h-11 tw-px-5',\n },\n },\n defaultVariants: {\n variant: 'default',\n size: 'default',\n },\n },\n);\n\nconst Toggle = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef & VariantProps\n>(({ className, variant, size, ...props }, ref) => (\n \n));\n\nToggle.displayName = TogglePrimitive.Root.displayName;\n\nexport { Toggle, toggleVariants };\n","import React from 'react';\nimport * as ToggleGroupPrimitive from '@radix-ui/react-toggle-group';\nimport { type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { toggleVariants } from '@/components/shadcn-ui/toggle';\n\nconst ToggleGroupContext = React.createContext>({\n size: 'default',\n variant: 'default',\n});\n\nconst ToggleGroup = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef &\n VariantProps\n>(({ className, variant, size, children, ...props }, ref) => (\n \n \n {children}\n \n \n));\n\nToggleGroup.displayName = ToggleGroupPrimitive.Root.displayName;\n\nconst ToggleGroupItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef &\n VariantProps\n>(({ className, children, variant, size, ...props }, ref) => {\n const context = React.useContext(ToggleGroupContext);\n\n return (\n \n {children}\n \n );\n});\n\nToggleGroupItem.displayName = ToggleGroupPrimitive.Item.displayName;\n\nexport { ToggleGroup, ToggleGroupItem };\n","import { ColumnDef, SortDirection } from '@/components/advanced/data-table/data-table.component';\nimport { Button } from '@/components/shadcn-ui/button';\nimport { ToggleGroup, ToggleGroupItem } from '@/components/shadcn-ui/toggle-group';\nimport {\n ArrowDownIcon,\n ArrowUpDownIcon,\n ArrowUpIcon,\n CircleCheckIcon,\n CircleHelpIcon,\n CircleXIcon,\n} from 'lucide-react';\nimport { ReactNode } from 'react';\nimport { InventoryTableData, Status } from './inventory-utils';\n\n/**\n * Gets an icon that indicates the current sorting direction based on the provided input\n *\n * @param sortDirection Sorting direction. Can be ascending ('asc'), descending ('desc') or false (\n * i.e. not sorted)\n * @returns The appropriate sorting icon for the provided sorting direction\n */\nconst getSortingIcon = (sortDirection: false | SortDirection): ReactNode => {\n if (sortDirection === 'asc') {\n return ;\n }\n if (sortDirection === 'desc') {\n return ;\n }\n return ;\n};\n\n/**\n * Function that creates the item column for inventories\n *\n * @param itemLabel Localized label for the item column (e.g. 'Character', 'Repeated Word', etc.)\n * @returns Column that shows the inventory items. Should be used with the DataTable component\n */\nexport const inventoryItemColumn = (itemLabel: string): ColumnDef => {\n return {\n accessorKey: 'item',\n accessorFn: (row: InventoryTableData) => row.items[0],\n header: ({ column }) => (\n \n ),\n };\n};\n\n/**\n * Function that creates the additional item columns for inventories\n *\n * @param additionalItemLabel Localized label for the additional item column (e.g. 'Preceding\n * Marker')\n * @param additionalItemIndex Index that locates the desired item in the items array of the\n * inventory\n * @returns Column that shows additional inventory items. Should be used with the DataTable\n * component\n */\nexport const inventoryAdditionalItemColumn = (\n additionalItemLabel: string,\n additionalItemIndex: number,\n): ColumnDef => {\n return {\n accessorKey: `item${additionalItemIndex}`,\n accessorFn: (row: InventoryTableData) => row.items[additionalItemIndex],\n header: ({ column }) => (\n \n ),\n };\n};\n\n/**\n * Function that creates the count column for inventories. Should be used with the DataTable\n * component.\n *\n * @param itemLabel Localized label for the count column\n * @returns Column that shows the number of occurrences of the related inventory items\n */\nexport const inventoryCountColumn = (countLabel: string): ColumnDef => {\n return {\n accessorKey: 'count',\n header: ({ column }) => (\n
    \n \n
    \n ),\n cell: ({ row }) =>
    {row.getValue('count')}
    ,\n };\n};\n\n/**\n * Function that updates project settings when status for item(s) changes\n *\n * @param changedItems Array of items for which the status is being updated\n * @param newStatus The status that the items are being given\n * @param approvedItems Array of currently approved items\n * @param onApprovedItemsChange Callback function that stores the updated list of approved items\n * @param unapprovedItems Array of currently unapproved items\n * @param onUnapprovedItemsChange Callback function that stores the updated list of unapproved items\n */\nconst statusChangeHandler = (\n changedItems: string[],\n newStatus: Status,\n approvedItems: string[],\n onApprovedItemsChange: (items: string[]) => void,\n unapprovedItems: string[],\n onUnapprovedItemsChange: (items: string[]) => void,\n) => {\n let newApprovedItems: string[] = [...approvedItems];\n changedItems.forEach((item) => {\n if (newStatus === 'approved') {\n if (!newApprovedItems.includes(item)) {\n newApprovedItems.push(item);\n }\n } else {\n newApprovedItems = newApprovedItems.filter((validItem) => validItem !== item);\n }\n });\n onApprovedItemsChange(newApprovedItems);\n\n let newUnapprovedItems: string[] = [...unapprovedItems];\n changedItems.forEach((item) => {\n if (newStatus === 'unapproved') {\n if (!newUnapprovedItems.includes(item)) {\n newUnapprovedItems.push(item);\n }\n } else {\n newUnapprovedItems = newUnapprovedItems.filter((unapprovedItem) => unapprovedItem !== item);\n }\n });\n onUnapprovedItemsChange(newUnapprovedItems);\n};\n\n/**\n * Function that creates the status column for inventories. Should be used with the DataTable\n * component.\n *\n * @param statusLabel Localized label for the status column\n * @param approvedItems Array of approved items, typically as defined in `Settings.xml`\n * @param onApprovedItemsChange Callback function that stores the updated list of approved items\n * @param unapprovedItems Array of unapproved items, typically as defined in `Settings.xml`\n * @param onUnapprovedItemsChange Callback function that stores the updated list of unapproved items\n * @returns Column that shows the status buttons for the related inventory item. The button for the\n * current status of the item is selected\n */\nexport const inventoryStatusColumn = (\n statusLabel: string,\n approvedItems: string[],\n onApprovedItemsChange: (items: string[]) => void,\n unapprovedItems: string[],\n onUnapprovedItemsChange: (items: string[]) => void,\n): ColumnDef => {\n return {\n accessorKey: 'status',\n header: ({ column }) => {\n return (\n
    \n \n
    \n );\n },\n cell: ({ row }) => {\n const status: Status = row.getValue('status');\n const item: string = row.getValue('item');\n return (\n \n \n statusChangeHandler(\n [item],\n 'approved',\n approvedItems,\n onApprovedItemsChange,\n unapprovedItems,\n onUnapprovedItemsChange,\n )\n }\n value=\"approved\"\n >\n \n \n \n statusChangeHandler(\n [item],\n 'unapproved',\n approvedItems,\n onApprovedItemsChange,\n unapprovedItems,\n onUnapprovedItemsChange,\n )\n }\n value=\"unapproved\"\n >\n \n \n \n statusChangeHandler(\n [item],\n 'unknown',\n approvedItems,\n onApprovedItemsChange,\n unapprovedItems,\n onUnapprovedItemsChange,\n )\n }\n value=\"unknown\"\n >\n \n \n \n );\n },\n };\n};\n","import DataTable, {\n ColumnDef,\n RowContents,\n RowSelectionState,\n TableContents,\n} from '@/components/advanced/data-table/data-table.component';\nimport OccurrencesTable from '@/components/advanced/inventory/occurrences-table.component';\nimport Checkbox from '@/components/shadcn-ui/checkbox';\nimport { Input } from '@/components/shadcn-ui/input';\nimport { Label } from '@/components/shadcn-ui/label';\nimport {\n Select,\n SelectContent,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\nimport {\n deepEqual,\n LocalizedStringValue,\n ScriptureReference,\n substring,\n} from 'platform-bible-utils';\nimport { useEffect, useMemo, useState } from 'react';\nimport {\n getBookNumFromId,\n getLinesFromUSFM,\n getNumberFromUSFM,\n getStatusForItem,\n InventoryItemOccurrence,\n InventoryTableData,\n Status,\n} from './inventory-utils';\nimport { inventoryAdditionalItemColumn } from './inventory-columns';\n\n/**\n * Object containing all keys used for localization in this component. If you're using this\n * component in an extension, you can pass it into the useLocalizedStrings hook to easily obtain the\n * localized strings and pass them into the localizedStrings prop of this component\n */\nexport const INVENTORY_STRING_KEYS = Object.freeze([\n '%webView_inventory_all%',\n '%webView_inventory_approved%',\n '%webView_inventory_unapproved%',\n '%webView_inventory_unknown%',\n '%webView_inventory_scope_currentBook%',\n '%webView_inventory_scope_chapter%',\n '%webView_inventory_scope_verse%',\n '%webView_inventory_filter_text%',\n '%webView_inventory_show_additional_items%',\n '%webView_inventory_occurrences_table_header_reference%',\n '%webView_inventory_occurrences_table_header_occurrence%',\n] as const);\n\nexport type InventoryLocalizedStrings = {\n [localizedInventoryKey in (typeof INVENTORY_STRING_KEYS)[number]]?: LocalizedStringValue;\n};\n\n/** Scope of scripture that the inventory can operate on */\nexport type Scope = 'book' | 'chapter' | 'verse';\n\n/** Status values that the status filter can select from */\ntype StatusFilter = Status | 'all';\n\n/** Text labels for the inventory columns and the control components of additional inventory items */\ntype AdditionalItemsLabels = {\n checkboxText?: string;\n tableHeaders?: string[];\n};\n\n/**\n * Filters data that is shown in the DataTable section of the Inventory\n *\n * @param itemData All inventory items and their related information\n * @param statusFilter Allows filtering by status (i.e. show all items, or only items that are\n * 'approved', 'unapproved' or 'unknown')\n * @param textFilter Allows filtering by text. All items that include the filter text will be\n * selected.\n * @returns Array of items and their related information that are matched by the specified filters\n */\nconst filterItemData = (\n itemData: InventoryTableData[],\n statusFilter: StatusFilter,\n textFilter: string,\n): InventoryTableData[] => {\n let filteredItemData: InventoryTableData[] = itemData;\n\n if (statusFilter !== 'all') {\n filteredItemData = filteredItemData.filter(\n (item) =>\n (statusFilter === 'approved' && item.status === 'approved') ||\n (statusFilter === 'unapproved' && item.status === 'unapproved') ||\n (statusFilter === 'unknown' && item.status === 'unknown'),\n );\n }\n\n if (textFilter !== '')\n filteredItemData = filteredItemData.filter((item) => item.items[0].includes(textFilter));\n\n return filteredItemData;\n};\n\n/**\n * Turns array of strings into array of inventory items, along with their count and status\n *\n * @param text The source scripture text that is searched for inventory items\n * @param scriptureRef The scripture reference that the application is currently set to\n * @param approvedItems Array of approved items, typically as defined in `Settings.xml`\n * @param unapprovedItems Array of unapproved items, typically as defined in `Settings.xml`\n * @param itemRegex Regular expression that describes what items this Inventory should extract from\n * the provided scripture text\n * @returns Array of inventory items, along with their count and status\n */\nconst createTableData = (\n text: string | undefined,\n scriptureRef: ScriptureReference,\n approvedItems: string[],\n unapprovedItems: string[],\n itemRegex: RegExp,\n): InventoryTableData[] => {\n if (!text) return [];\n\n const tableData: InventoryTableData[] = [];\n\n let currentBook: number | undefined = scriptureRef.bookNum;\n let currentChapter: number | undefined = scriptureRef.chapterNum;\n let currentVerse: number | undefined = scriptureRef.verseNum;\n\n const lines = getLinesFromUSFM(text);\n\n lines.forEach((line: string) => {\n if (line.startsWith('\\\\id')) {\n currentBook = getBookNumFromId(line);\n currentChapter = 0;\n currentVerse = 0;\n }\n if (line.startsWith('\\\\c')) {\n currentChapter = getNumberFromUSFM(line);\n currentVerse = 0;\n }\n if (line.startsWith('\\\\v')) {\n currentVerse = getNumberFromUSFM(line);\n if (currentChapter === 0) {\n currentChapter = scriptureRef.chapterNum;\n }\n }\n\n let match: RegExpExecArray | undefined = itemRegex.exec(line) ?? undefined;\n while (match) {\n const items: string[] = [];\n match.forEach((item) => items.push(item));\n const itemIndex = match.index;\n const existingItem = tableData.find((tableEntry) => deepEqual(tableEntry.items, items));\n const newReference: InventoryItemOccurrence = {\n reference: {\n bookNum: currentBook !== undefined ? currentBook : -1,\n chapterNum: currentChapter !== undefined ? currentChapter : -1,\n verseNum: currentVerse !== undefined ? currentVerse : -1,\n },\n text: substring(line, Math.max(0, itemIndex - 25), Math.min(itemIndex + 25, line.length)),\n };\n if (existingItem) {\n existingItem.count += 1;\n existingItem.occurrences.push(newReference);\n } else {\n const newItem: InventoryTableData = {\n items,\n count: 1,\n status: getStatusForItem(items[0], approvedItems, unapprovedItems),\n occurrences: [newReference],\n };\n tableData.push(newItem);\n }\n\n match = itemRegex.exec(line) ?? undefined;\n }\n });\n\n return tableData;\n};\n\n/**\n * Gets the localized value for the provided key\n *\n * @param strings Object containing localized string\n * @param key Key for a localized string\n * @returns The localized value for the provided key, if available. Returns the key if no localized\n * value is available\n */\nconst localizeString = (\n strings: InventoryLocalizedStrings,\n key: keyof InventoryLocalizedStrings,\n) => {\n return strings[key] ?? key;\n};\n\n/** Props for the Inventory component */\ntype InventoryProps = {\n /** The scripture reference that the application is currently set to */\n scriptureReference: ScriptureReference;\n /** Callback function that is executed when the scripture reference is changed */\n setScriptureReference: (scriptureReference: ScriptureReference) => void;\n /**\n * Object with all localized strings that the Inventory needs to work well across multiple\n * languages. When using this component with Platform.Bible, you can import\n * `INVENTORY_STRING_KEYS` from this library, pass it in to the Platform's localization hook, and\n * pass the localized keys that are returned by the hook into this prop.\n */\n localizedStrings: InventoryLocalizedStrings;\n /**\n * The logic that finds the desired items in the source text. This can either be a Regular\n * expression that captures one or multiple items (preferred), or a custom function that builds\n * and return an InventoryDataTable[] manually. Note: In case the logic captures more than one\n * item (i.e. InventoryTableData.items has a length greater than 1), you must provide text labels\n * for the related columns and control elements to show by setting the `additionalItemsLabels`\n * prop\n */\n extractItems:\n | RegExp\n | ((\n text: string | undefined,\n scriptureRef: ScriptureReference,\n approvedItems: string[],\n unapprovedItems: string[],\n ) => InventoryTableData[]);\n /**\n * Text labels for control elements and additional column headers in case your Inventory has more\n * than one item to show (e.g. The 'Preceding Marker' in the Markers Inventory)\n */\n additionalItemsLabels?: AdditionalItemsLabels;\n /** Array of approved items, typically as defined in `Settings.xml` */\n approvedItems: string[];\n /** Array of unapproved items, typically as defined in `Settings.xml` */\n unapprovedItems: string[];\n /** The source scripture text that is searched for in inventory items */\n text: string | undefined;\n /** Scope of scripture that the inventory will operate on */\n scope: Scope;\n /** Callback function that is executed when the scope is changed from the Inventory */\n onScopeChange: (scope: Scope) => void;\n /**\n * Column definitions for the Inventory data table. The most commonly used column definitions are\n * pre-configured for your convenience and can be imported (e.g. inventoryItemColumn,\n * inventoryAdditionalItemColumn inventoryCountColumn, and inventoryStatusColumn). If you need any\n * other columns you can add these yourself\n */\n columns: ColumnDef[];\n};\n\n/** Inventory component that is used to view and control the status of provided project settings */\nexport default function Inventory({\n scriptureReference,\n setScriptureReference,\n localizedStrings,\n extractItems,\n additionalItemsLabels,\n approvedItems,\n unapprovedItems,\n text,\n scope,\n onScopeChange,\n columns,\n}: InventoryProps) {\n const allItemsText = localizeString(localizedStrings, '%webView_inventory_all%');\n const approvedItemsText = localizeString(localizedStrings, '%webView_inventory_approved%');\n const unapprovedItemsText = localizeString(localizedStrings, '%webView_inventory_unapproved%');\n const unknownItemsText = localizeString(localizedStrings, '%webView_inventory_unknown%');\n const scopeBookText = localizeString(localizedStrings, '%webView_inventory_scope_currentBook%');\n const scopeChapterText = localizeString(localizedStrings, '%webView_inventory_scope_chapter%');\n const scopeVerseText = localizeString(localizedStrings, '%webView_inventory_scope_verse%');\n const filterText = localizeString(localizedStrings, '%webView_inventory_filter_text%');\n const showAdditionalItemsText = localizeString(\n localizedStrings,\n '%webView_inventory_show_additional_items%',\n );\n\n const [showAdditionalItems, setShowAdditionalItems] = useState(false);\n const [statusFilter, setStatusFilter] = useState('all');\n const [textFilter, setTextFilter] = useState('');\n const [selectedItem, setSelectedItem] = useState([]);\n\n const tableData: InventoryTableData[] = useMemo(() => {\n if (!text) return [];\n if (extractItems instanceof RegExp)\n return createTableData(\n text,\n scriptureReference,\n approvedItems,\n unapprovedItems,\n extractItems,\n );\n return extractItems(text, scriptureReference, approvedItems, unapprovedItems);\n }, [text, extractItems, scriptureReference, approvedItems, unapprovedItems]);\n\n const reducedTableData: InventoryTableData[] = useMemo(() => {\n if (showAdditionalItems) return tableData;\n\n const newTableData: InventoryTableData[] = [];\n\n tableData.forEach((tableEntry) => {\n const firstItem = tableEntry.items[0];\n\n const existingEntry = newTableData.find(\n (newTableEntry) => newTableEntry.items[0] === firstItem,\n );\n\n if (existingEntry) {\n existingEntry.count += tableEntry.count;\n existingEntry.occurrences = existingEntry.occurrences.concat(tableEntry.occurrences);\n } else {\n newTableData.push({\n items: [firstItem],\n count: tableEntry.count,\n occurrences: tableEntry.occurrences,\n status: tableEntry.status,\n });\n }\n });\n\n return newTableData;\n }, [showAdditionalItems, tableData]);\n\n const filteredTableData: InventoryTableData[] = useMemo(() => {\n return filterItemData(reducedTableData, statusFilter, textFilter);\n }, [reducedTableData, statusFilter, textFilter]);\n\n const allColumns: ColumnDef[] = useMemo(() => {\n if (!showAdditionalItems) return columns;\n\n const numberOfAdditionalItems = additionalItemsLabels?.tableHeaders?.length;\n if (!numberOfAdditionalItems) return columns;\n\n const additionalColumns: ColumnDef[] = [];\n\n for (let index = 0; index < numberOfAdditionalItems; index++) {\n additionalColumns.push(\n inventoryAdditionalItemColumn(\n additionalItemsLabels?.tableHeaders?.[index] || 'Additional Item',\n index + 1,\n ),\n );\n }\n\n return [...additionalColumns, ...columns];\n }, [additionalItemsLabels?.tableHeaders, columns, showAdditionalItems]);\n\n useEffect(() => {\n setSelectedItem([]);\n }, [filteredTableData]);\n\n const rowClickHandler = (\n row: RowContents,\n table: TableContents,\n ) => {\n table.setRowSelection(() => {\n const newSelection: RowSelectionState = {};\n newSelection[row.index] = true;\n return newSelection;\n });\n\n setSelectedItem(row.original.items);\n };\n\n const handleScopeChange = (value: string) => {\n if (value === 'book' || value === 'chapter' || value === 'verse') {\n onScopeChange(value);\n } else {\n throw new Error(`Invalid scope value: ${value}`);\n }\n };\n\n const handleStatusFilterChange = (value: string) => {\n if (value === 'all' || value === 'approved' || value === 'unapproved' || value === 'unknown') {\n setStatusFilter(value);\n } else {\n throw new Error(`Invalid status filter value: ${value}`);\n }\n };\n\n const occurrenceData: InventoryItemOccurrence[] = useMemo(() => {\n if (reducedTableData.length === 0 || selectedItem.length === 0) return [];\n const occurrence = reducedTableData.filter((tableEntry: InventoryTableData) => {\n return deepEqual(\n showAdditionalItems ? tableEntry.items : [tableEntry.items[0]],\n selectedItem,\n );\n });\n if (occurrence.length > 1) throw new Error('Selected item is not unique');\n return occurrence[0].occurrences;\n }, [selectedItem, showAdditionalItems, reducedTableData]);\n\n return (\n
    \n
    \n handleStatusFilterChange(value)}\n defaultValue={statusFilter}\n >\n \n \n \n \n {allItemsText}\n {approvedItemsText}\n {unapprovedItemsText}\n {unknownItemsText}\n \n \n \n {\n setTextFilter(event.target.value);\n }}\n />\n {additionalItemsLabels && (\n
    \n {\n setSelectedItem([]);\n setShowAdditionalItems(checked);\n }}\n />\n \n
    \n )}\n
    \n
    \n \n
    \n {occurrenceData.length > 0 && (\n
    \n \n
    \n )}\n
    \n );\n}\n","import { Input } from '@/components/shadcn-ui/input';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { useState } from 'react';\n\nexport type SearchBarProps = {\n /**\n * Callback fired to handle the search query when button pressed\n *\n * @param searchQuery\n */\n onSearch: (searchQuery: string) => void;\n\n /** Optional string that appears in the search bar without a search string */\n placeholder?: string;\n\n /** Optional boolean to set the input base to full width */\n isFullWidth?: boolean;\n};\n\nexport default function SearchBar({ onSearch, placeholder, isFullWidth }: SearchBarProps) {\n const [searchQuery, setSearchQuery] = useState('');\n\n const handleInputChange = (searchString: string) => {\n setSearchQuery(searchString);\n onSearch(searchString);\n };\n\n return (\n handleInputChange(e.target.value)}\n />\n );\n}\n","// adapted from: https://github.com/shadcn-ui/ui/discussions/752\n\n'use client';\n\nimport { TabsContentProps, TabsListProps, TabsTriggerProps } from '@/components/shadcn-ui/tabs';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport * as TabsPrimitive from '@radix-ui/react-tabs';\nimport React from 'react';\n\nexport type VerticalTabsProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport type LeftTabsTriggerProps = TabsTriggerProps & {\n value: string;\n ref?: React.Ref;\n};\n\nexport const VerticalTabs = React.forwardRef<\n React.ElementRef,\n VerticalTabsProps\n>(({ className, ...props }, ref) => (\n \n));\n\nVerticalTabs.displayName = TabsPrimitive.List.displayName;\n\nexport const VerticalTabsList = React.forwardRef<\n React.ElementRef,\n TabsListProps\n>(({ className, ...props }, ref) => (\n \n));\nVerticalTabsList.displayName = TabsPrimitive.List.displayName;\n\nexport const VerticalTabsTrigger = React.forwardRef<\n React.ElementRef,\n LeftTabsTriggerProps\n>(({ className, ...props }, ref) => (\n \n));\n\nexport const VerticalTabsContent = React.forwardRef<\n React.ElementRef,\n TabsContentProps\n>(({ className, ...props }, ref) => (\n \n));\nVerticalTabsContent.displayName = TabsPrimitive.Content.displayName;\n","import SearchBar from '@/components/basics/search-bar.component';\nimport {\n VerticalTabs,\n VerticalTabsContent,\n VerticalTabsList,\n VerticalTabsTrigger,\n} from '@/components/basics/tabs-vertical';\nimport { ReactNode } from 'react';\n\nexport type TabKeyValueContent = {\n key: string;\n value: string;\n content: ReactNode;\n};\n\nexport type TabNavigationContentSearchProps = {\n /** List of values and keys for each tab this component should provide */\n tabList: TabKeyValueContent[];\n\n /** Handler to run when the value of the search bar changes */\n onSearch: (searchQuery: string) => void;\n\n /** Optional placeholder for the search bar */\n searchPlaceholder?: string;\n\n /** Optional title to include in the header */\n headerTitle?: string;\n\n /** Optional flag to make the search bar appear full width */\n isSearchBarFullWidth?: boolean;\n\n /** Text direction ltr or rtl */\n direction?: 'ltr' | 'rtl';\n};\n\nexport default function TabNavigationContentSearch({\n tabList,\n onSearch,\n searchPlaceholder,\n headerTitle,\n isSearchBarFullWidth = false,\n direction = 'ltr',\n}: TabNavigationContentSearchProps) {\n return (\n
    \n
    \n {headerTitle ?

    {headerTitle}

    : ''}\n \n
    \n \n \n {tabList.map((tab) => (\n \n {tab.value}\n \n ))}\n \n {tabList.map((tab) => (\n \n {tab.content}\n \n ))}\n \n
    \n );\n}\n","import React from 'react';\nimport * as SeparatorPrimitive from '@radix-ui/react-separator';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Separator = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, orientation = 'horizontal', decorative = true, ...props }, ref) => (\n \n));\nSeparator.displayName = SeparatorPrimitive.Root.displayName;\n\nexport { Separator };\n","'use client';\n\nimport * as React from 'react';\nimport * as SheetPrimitive from '@radix-ui/react-dialog';\nimport { cva, type VariantProps } from 'class-variance-authority';\nimport { X } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Sheet = SheetPrimitive.Root;\n\nconst SheetTrigger = SheetPrimitive.Trigger;\n\nconst SheetClose = SheetPrimitive.Close;\n\nconst SheetPortal = SheetPrimitive.Portal;\n\nconst SheetOverlay = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSheetOverlay.displayName = SheetPrimitive.Overlay.displayName;\n\nconst sheetVariants = cva(\n 'pr-twp tw-fixed tw-z-50 tw-gap-4 tw-bg-background tw-p-6 tw-shadow-lg tw-transition tw-ease-in-out data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-duration-300 data-[state=open]:tw-duration-500',\n {\n variants: {\n side: {\n top: 'tw-inset-x-0 tw-top-0 tw-border-b data-[state=closed]:tw-slide-out-to-top data-[state=open]:tw-slide-in-from-top',\n bottom:\n 'tw-inset-x-0 tw-bottom-0 tw-border-t data-[state=closed]:tw-slide-out-to-bottom data-[state=open]:tw-slide-in-from-bottom',\n left: 'tw-inset-y-0 tw-left-0 tw-h-full tw-w-3/4 tw-border-r data-[state=closed]:tw-slide-out-to-left data-[state=open]:tw-slide-in-from-left sm:tw-max-w-sm',\n right:\n 'tw-inset-y-0 tw-right-0 tw-h-full tw-w-3/4 tw- tw-border-l data-[state=closed]:tw-slide-out-to-right data-[state=open]:tw-slide-in-from-right sm:tw-max-w-sm',\n },\n },\n defaultVariants: {\n side: 'right',\n },\n },\n);\n\ninterface SheetContentProps\n extends React.ComponentPropsWithoutRef,\n VariantProps {}\n\nconst SheetContent = React.forwardRef<\n React.ElementRef,\n SheetContentProps\n>(({ side = 'right', className, children, ...props }, ref) => (\n \n \n \n {children}\n \n \n Close\n \n \n \n));\nSheetContent.displayName = SheetPrimitive.Content.displayName;\n\nfunction SheetHeader({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nSheetHeader.displayName = 'SheetHeader';\n\nfunction SheetFooter({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nSheetFooter.displayName = 'SheetFooter';\n\nconst SheetTitle = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSheetTitle.displayName = SheetPrimitive.Title.displayName;\n\nconst SheetDescription = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSheetDescription.displayName = SheetPrimitive.Description.displayName;\n\nexport {\n Sheet,\n SheetPortal,\n SheetOverlay,\n SheetTrigger,\n SheetClose,\n SheetContent,\n SheetHeader,\n SheetFooter,\n SheetTitle,\n SheetDescription,\n};\n","import React from 'react';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nfunction Skeleton({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\n\nexport { Skeleton };\n","import React from 'react';\nimport * as TooltipPrimitive from '@radix-ui/react-tooltip';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst TooltipProvider = TooltipPrimitive.Provider;\n\nconst Tooltip = TooltipPrimitive.Root;\n\nconst TooltipTrigger = TooltipPrimitive.Trigger;\n\nconst TooltipContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, sideOffset = 4, ...props }, ref) => (\n \n));\nTooltipContent.displayName = TooltipPrimitive.Content.displayName;\n\nexport { Tooltip, TooltipTrigger, TooltipContent, TooltipProvider };\n","import * as React from 'react';\n\nconst MOBILE_BREAKPOINT = 768;\n\nexport default function useIsMobile() {\n const [isMobile, setIsMobile] = React.useState(undefined);\n\n React.useEffect(() => {\n const mql = window.matchMedia(`(max-width: ${MOBILE_BREAKPOINT - 1}px)`);\n const onChange = () => {\n setIsMobile(window.innerWidth < MOBILE_BREAKPOINT);\n };\n mql.addEventListener('change', onChange);\n setIsMobile(window.innerWidth < MOBILE_BREAKPOINT);\n return () => mql.removeEventListener('change', onChange);\n }, []);\n\n return !!isMobile;\n}\n","import React from 'react';\nimport { Slot } from '@radix-ui/react-slot';\nimport { VariantProps, cva } from 'class-variance-authority';\nimport { PanelLeft } from 'lucide-react';\n\nimport { Button } from '@/components/shadcn-ui/button';\nimport { Input } from '@/components/shadcn-ui/input';\nimport { Separator } from '@/components/shadcn-ui/separator';\nimport { Sheet, SheetContent } from '@/components/shadcn-ui/sheet';\nimport { Skeleton } from '@/components/shadcn-ui/skeleton';\nimport {\n Tooltip,\n TooltipContent,\n TooltipProvider,\n TooltipTrigger,\n} from '@/components/shadcn-ui/tooltip';\nimport useIsMobile from '@/components/hooks/use-mobile';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst SIDEBAR_COOKIE_NAME = 'sidebar:state';\nconst SIDEBAR_COOKIE_MAX_AGE = 60 * 60 * 24 * 7;\nconst SIDEBAR_WIDTH = '16rem';\nconst SIDEBAR_WIDTH_MOBILE = '18rem';\nconst SIDEBAR_WIDTH_ICON = '3rem';\nconst SIDEBAR_KEYBOARD_SHORTCUT = 'b';\n\ntype SidebarContextProps = {\n state: 'expanded' | 'collapsed';\n open: boolean;\n setOpen: (open: boolean) => void;\n openMobile: boolean;\n setOpenMobile: (open: boolean) => void;\n isMobile: boolean;\n toggleSidebar: () => void;\n};\n\nconst SidebarContext = React.createContext(undefined);\n\nfunction useSidebar() {\n const context = React.useContext(SidebarContext);\n if (!context) {\n throw new Error('useSidebar must be used within a SidebarProvider.');\n }\n\n return context;\n}\n\nconst SidebarProvider = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & {\n defaultOpen?: boolean;\n open?: boolean;\n onOpenChange?: (open: boolean) => void;\n }\n>(\n (\n {\n defaultOpen = true,\n open: openProp,\n onOpenChange: setOpenProp,\n className,\n style,\n children,\n ...props\n },\n ref,\n ) => {\n const isMobile = useIsMobile();\n const [openMobile, setOpenMobile] = React.useState(false);\n\n // This is the internal state of the sidebar.\n // We use openProp and setOpenProp for control from outside the component.\n const [_open, _setOpen] = React.useState(defaultOpen);\n const isOpen = openProp ?? _open;\n const setOpen = React.useCallback(\n (value: boolean | ((value: boolean) => boolean)) => {\n const openState = typeof value === 'function' ? value(isOpen) : value;\n if (setOpenProp) {\n setOpenProp(openState);\n } else {\n _setOpen(openState);\n }\n\n // This sets the cookie to keep the sidebar state.\n document.cookie = `${SIDEBAR_COOKIE_NAME}=${openState}; path=/; max-age=${SIDEBAR_COOKIE_MAX_AGE}`;\n },\n [setOpenProp, isOpen],\n );\n\n // Helper to toggle the sidebar.\n const toggleSidebar = React.useCallback(() => {\n return isMobile ? setOpenMobile((open) => !open) : setOpen((open) => !open);\n }, [isMobile, setOpen, setOpenMobile]);\n\n // Adds a keyboard shortcut to toggle the sidebar.\n React.useEffect(() => {\n const handleKeyDown = (event: KeyboardEvent) => {\n if (event.key === SIDEBAR_KEYBOARD_SHORTCUT && (event.metaKey || event.ctrlKey)) {\n event.preventDefault();\n toggleSidebar();\n }\n };\n\n window.addEventListener('keydown', handleKeyDown);\n return () => window.removeEventListener('keydown', handleKeyDown);\n }, [toggleSidebar]);\n\n // We add a state so that we can do data-state=\"expanded\" or \"collapsed\".\n // This makes it easier to style the sidebar with Tailwind classes.\n const state = isOpen ? 'expanded' : 'collapsed';\n\n const contextValue = React.useMemo(\n () => ({\n state,\n open: isOpen,\n setOpen,\n isMobile,\n openMobile,\n setOpenMobile,\n toggleSidebar,\n }),\n [state, isOpen, setOpen, isMobile, openMobile, setOpenMobile, toggleSidebar],\n );\n\n return (\n \n \n \n {children}\n
    \n \n \n );\n },\n);\nSidebarProvider.displayName = 'SidebarProvider';\n\nconst Sidebar = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & {\n side?: 'left' | 'right';\n variant?: 'sidebar' | 'floating' | 'inset';\n collapsible?: 'offcanvas' | 'icon' | 'none';\n }\n>(\n (\n {\n side = 'left',\n variant = 'sidebar',\n collapsible = 'offcanvas',\n className,\n children,\n ...props\n },\n ref,\n ) => {\n const { isMobile, state, openMobile, setOpenMobile } = useSidebar();\n\n if (collapsible === 'none') {\n return (\n \n {children}\n
    \n );\n }\n\n if (isMobile) {\n return (\n \n button]:tw-hidden\"\n style={\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n {\n '--sidebar-width': SIDEBAR_WIDTH_MOBILE,\n } as React.CSSProperties\n }\n side={side}\n >\n
    {children}
    \n \n
    \n );\n }\n\n return (\n \n {/* This is what handles the sidebar gap on desktop */}\n \n \n \n {children}\n
    \n
    \n
    \n );\n },\n);\nSidebar.displayName = 'Sidebar';\n\nconst SidebarTrigger = React.forwardRef<\n React.ElementRef,\n React.ComponentProps\n>(({ className, onClick, ...props }, ref) => {\n const { toggleSidebar } = useSidebar();\n\n return (\n {\n onClick?.(event);\n toggleSidebar();\n }}\n {...props}\n >\n \n Toggle Sidebar\n \n );\n});\nSidebarTrigger.displayName = 'SidebarTrigger';\n\nconst SidebarRail = React.forwardRef>(\n ({ className, ...props }, ref) => {\n const { toggleSidebar } = useSidebar();\n\n return (\n \n );\n },\n);\nSidebarRail.displayName = 'SidebarRail';\n\nconst SidebarInset = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarInset.displayName = 'SidebarInset';\n\nconst SidebarInput = React.forwardRef<\n React.ElementRef,\n React.ComponentProps\n>(({ className, ...props }, ref) => {\n return (\n \n );\n});\nSidebarInput.displayName = 'SidebarInput';\n\nconst SidebarHeader = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarHeader.displayName = 'SidebarHeader';\n\nconst SidebarFooter = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarFooter.displayName = 'SidebarFooter';\n\nconst SidebarSeparator = React.forwardRef<\n React.ElementRef,\n React.ComponentProps\n>(({ className, ...props }, ref) => {\n return (\n \n );\n});\nSidebarSeparator.displayName = 'SidebarSeparator';\n\nconst SidebarContent = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarContent.displayName = 'SidebarContent';\n\nconst SidebarGroup = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarGroup.displayName = 'SidebarGroup';\n\nconst SidebarGroupLabel = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & { asChild?: boolean }\n>(({ className, asChild = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'div';\n\n return (\n svg]:tw-size-4 [&>svg]:tw-shrink-0',\n 'group-data-[collapsible=icon]:tw--mt-8 group-data-[collapsible=icon]:tw-opacity-0',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarGroupLabel.displayName = 'SidebarGroupLabel';\n\nconst SidebarGroupAction = React.forwardRef<\n HTMLButtonElement,\n React.ComponentProps<'button'> & { asChild?: boolean }\n>(({ className, asChild = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'button';\n\n return (\n svg]:tw-size-4 [&>svg]:tw-shrink-0',\n // Increases the hit area of the button on mobile.\n 'after:tw-absolute after:tw--inset-2 after:md:tw-hidden',\n 'group-data-[collapsible=icon]:tw-hidden',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarGroupAction.displayName = 'SidebarGroupAction';\n\nconst SidebarGroupContent = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarGroupContent.displayName = 'SidebarGroupContent';\n\nconst SidebarMenu = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenu.displayName = 'SidebarMenu';\n\nconst SidebarMenuItem = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenuItem.displayName = 'SidebarMenuItem';\n\nconst sidebarMenuButtonVariants = cva(\n 'tw-peer/menu-button tw-flex tw-w-full tw-items-center tw-gap-2 tw-overflow-hidden tw-rounded-md tw-p-2 tw-text-left tw-text-sm tw-outline-none tw-ring-sidebar-ring tw-transition-[width,height,padding] hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground focus-visible:tw-ring-2 active:tw-bg-sidebar-accent active:tw-text-sidebar-accent-foreground disabled:tw-pointer-events-none disabled:tw-opacity-50 tw-group-has-[[data-sidebar=menu-action]]/menu-item:pr-8 aria-disabled:tw-pointer-events-none aria-disabled:tw-opacity-50 data-[active=true]:tw-bg-sidebar-accent data-[active=true]:tw-font-medium data-[active=true]:tw-text-sidebar-accent-foreground data-[state=open]:hover:tw-bg-sidebar-accent data-[state=open]:hover:tw-text-sidebar-accent-foreground group-data-[collapsible=icon]:tw-!size-8 group-data-[collapsible=icon]:tw-!p-2 [&>span:last-child]:tw-truncate [&>svg]:tw-size-4 [&>svg]:tw-shrink-0',\n {\n variants: {\n variant: {\n default: 'hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground',\n outline:\n 'tw-bg-background tw-shadow-[0_0_0_1px_hsl(var(--sidebar-border))] hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground hover:tw-shadow-[0_0_0_1px_hsl(var(--sidebar-accent))]',\n },\n size: {\n default: 'tw-h-8 tw-text-sm',\n sm: 'tw-h-7 tw-text-xs',\n lg: 'tw-h-12 tw-text-sm group-data-[collapsible=icon]:tw-!p-0',\n },\n },\n defaultVariants: {\n variant: 'default',\n size: 'default',\n },\n },\n);\n\nconst SidebarMenuButton = React.forwardRef<\n HTMLButtonElement,\n React.ComponentProps<'button'> & {\n asChild?: boolean;\n isActive?: boolean;\n tooltip?: string | React.ComponentProps;\n } & VariantProps\n>(\n (\n {\n asChild = false,\n isActive = false,\n variant = 'default',\n size = 'default',\n tooltip,\n className,\n ...props\n },\n ref,\n ) => {\n const Comp = asChild ? Slot : 'button';\n const { isMobile, state } = useSidebar();\n\n const button = (\n \n );\n\n if (!tooltip) {\n return button;\n }\n\n if (typeof tooltip === 'string') {\n // eslint-disable-next-line no-param-reassign\n tooltip = {\n children: tooltip,\n };\n }\n\n return (\n \n {button}\n \n );\n },\n);\nSidebarMenuButton.displayName = 'SidebarMenuButton';\n\nconst SidebarMenuAction = React.forwardRef<\n HTMLButtonElement,\n React.ComponentProps<'button'> & {\n asChild?: boolean;\n showOnHover?: boolean;\n }\n>(({ className, asChild = false, showOnHover = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'button';\n\n return (\n svg]:tw-size-4 [&>svg]:tw-shrink-0',\n // Increases the hit area of the button on mobile.\n 'after:tw-absolute after:tw--inset-2 after:md:tw-hidden',\n 'tw-peer-data-[size=sm]/menu-button:top-1',\n 'tw-peer-data-[size=default]/menu-button:top-1.5',\n 'tw-peer-data-[size=lg]/menu-button:top-2.5',\n 'group-data-[collapsible=icon]:tw-hidden',\n showOnHover &&\n 'tw-group-focus-within/menu-item:opacity-100 tw-group-hover/menu-item:opacity-100 tw-peer-data-[active=true]/menu-button:text-sidebar-accent-foreground data-[state=open]:tw-opacity-100 md:tw-opacity-0',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarMenuAction.displayName = 'SidebarMenuAction';\n\nconst SidebarMenuBadge = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenuBadge.displayName = 'SidebarMenuBadge';\n\nconst SidebarMenuSkeleton = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & {\n showIcon?: boolean;\n }\n>(({ className, showIcon = false, ...props }, ref) => {\n // Random width between 50 to 90%.\n const width = React.useMemo(() => {\n return `${Math.floor(Math.random() * 40) + 50}%`;\n }, []);\n\n return (\n \n {showIcon && (\n \n )}\n \n
    \n );\n});\nSidebarMenuSkeleton.displayName = 'SidebarMenuSkeleton';\n\nconst SidebarMenuSub = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenuSub.displayName = 'SidebarMenuSub';\n\nconst SidebarMenuSubItem = React.forwardRef>(\n ({ ...props }, ref) =>
  • ,\n);\nSidebarMenuSubItem.displayName = 'SidebarMenuSubItem';\n\nconst SidebarMenuSubButton = React.forwardRef<\n HTMLAnchorElement,\n React.ComponentProps<'a'> & {\n asChild?: boolean;\n size?: 'sm' | 'md';\n isActive?: boolean;\n }\n>(({ asChild = false, size = 'md', isActive, className, ...props }, ref) => {\n const Comp = asChild ? Slot : 'a';\n\n return (\n span:last-child]:tw-truncate [&>svg]:tw-size-4 [&>svg]:tw-shrink-0 [&>svg]:tw-text-sidebar-accent-foreground',\n 'data-[active=true]:tw-bg-sidebar-accent data-[active=true]:tw-text-sidebar-accent-foreground',\n size === 'sm' && 'tw-text-xs',\n size === 'md' && 'tw-text-sm',\n 'group-data-[collapsible=icon]:tw-hidden',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarMenuSubButton.displayName = 'SidebarMenuSubButton';\n\nexport {\n Sidebar,\n SidebarContent,\n SidebarFooter,\n SidebarGroup,\n SidebarGroupAction,\n SidebarGroupContent,\n SidebarGroupLabel,\n SidebarHeader,\n SidebarInput,\n SidebarInset,\n SidebarMenu,\n SidebarMenuAction,\n SidebarMenuBadge,\n SidebarMenuButton,\n SidebarMenuItem,\n SidebarMenuSkeleton,\n SidebarMenuSub,\n SidebarMenuSubButton,\n SidebarMenuSubItem,\n SidebarProvider,\n SidebarRail,\n SidebarSeparator,\n SidebarTrigger,\n useSidebar,\n};\n","import { useState } from 'react';\nimport {\n Sidebar,\n SidebarContent,\n SidebarGroup,\n SidebarGroupLabel,\n SidebarGroupContent,\n SidebarMenu,\n SidebarMenuItem,\n SidebarMenuButton,\n} from '../../shadcn-ui/sidebar';\n\nexport type SettingsSidebarProps = {\n /** Optional id */\n id?: string;\n\n /** Extension labels to list in sidebar */\n extensionLabels: string[];\n\n /** Project labels to list in sidebar */\n // projectLabels: string[];\n\n handleSelectSidebarItem: (key: string, isProjectSetting: boolean) => void;\n};\n\nexport default function SettingsSidebar({\n id,\n extensionLabels,\n // projectLabels,\n handleSelectSidebarItem,\n}: SettingsSidebarProps) {\n const [selectedItem, setSelectedItem] = useState();\n\n const handleSelectItem = (item: string, isProjectSetting: boolean) => {\n setSelectedItem(item);\n handleSelectSidebarItem(item, isProjectSetting);\n };\n\n return (\n \n \n \n Extensions\n \n \n {extensionLabels.map((label) => (\n \n handleSelectItem(label, false)}\n isActive={label === selectedItem}\n >\n {label}\n \n \n ))}\n \n \n \n\n {/* \n Projects\n \n \n {projectLabels.map((label) => (\n \n handleSelectItem(label)}\n isActive={label === selectedItem}\n >\n {label}\n \n \n ))}\n \n \n */}\n \n \n );\n}\n","import { SidebarInset, SidebarProvider } from '@/components/shadcn-ui/sidebar';\n// import { ProjectSettingProperties, SettingProperties } from 'platform-bible-utils';\nimport { PropsWithChildren } from 'react';\nimport SettingsSidebar from './settings-sidebar.component';\n\nexport type SettingsSidebarContentSearchProps = {\n /** Text direction ltr or rtl */\n direction?: 'ltr' | 'rtl';\n\n extensionLabels: string[];\n // projectLabels: string[];\n handleSelectSidebarItem: (key: string, isProjectSetting: boolean) => void;\n // renderSettingsProperties: (extension: string) => SettingProperties;\n // renderProjectSettingsProperties: (project: string) => ProjectSettingProperties;\n} & PropsWithChildren;\n\nexport default function SettingsSidebarContentSearch({\n direction = 'ltr',\n extensionLabels,\n // projectLabels,\n children,\n handleSelectSidebarItem,\n // renderSettingsProperties,\n // renderProjectSettingsProperties.\n}: SettingsSidebarContentSearchProps) {\n return (\n \n \n {children}\n \n );\n}\n","import { Button } from '@/components/shadcn-ui/button';\nimport {\n Select,\n SelectContent,\n SelectGroup,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\nimport {\n Table,\n TableBody,\n TableCell,\n TableHead,\n TableHeader,\n TableRow,\n} from '@/components/shadcn-ui/table';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Canon } from '@sillsdev/scripture';\nimport {\n Cell,\n ColumnDef,\n flexRender,\n getCoreRowModel,\n getExpandedRowModel,\n getGroupedRowModel,\n getSortedRowModel,\n GroupingState,\n Row,\n RowSelectionState,\n SortingState,\n useReactTable,\n} from '@tanstack/react-table';\nimport '@/components/advanced/scripture-results-viewer/scripture-results-viewer.component.css';\nimport {\n compareScrRefs,\n formatScrRef,\n ScriptureSelection,\n scrRefToBBBCCCVVV,\n} from 'platform-bible-utils';\nimport { MouseEvent, useEffect, useMemo, useState } from 'react';\nimport { ChevronDown, ChevronLeft, ChevronRight } from 'lucide-react';\n\n/**\n * Information (e.g., a checking error or some other type of \"transient\" annotation) about something\n * noteworthy at a specific place in an instance of the Scriptures.\n */\nexport type ScriptureItemDetail = ScriptureSelection & {\n /**\n * Text of the error, note, etc. In the future, we might want to support something more than just\n * text so that a JSX element could be provided with a link or some other controls related to the\n * issue being reported.\n */\n detail: string;\n};\n\n/**\n * A uniquely identifiable source of results that can be displayed in the ScriptureResultsViewer.\n * Generally, the source will be a particular Scripture check, but there may be other types of\n * sources.\n */\nexport type ResultsSource = {\n /**\n * Uniquely identifies the source.\n *\n * @type {string}\n */\n id: string;\n\n /**\n * Name (potentially localized) of the source, suitable for display in the UI.\n *\n * @type {string}\n */\n displayName: string;\n};\n\nexport type ScriptureSrcItemDetail = ScriptureItemDetail & {\n /** Source/type of detail. Can be used for grouping. */\n source: ResultsSource;\n};\n\n/**\n * Represents a set of results keyed by Scripture reference. Generally, the source will be a\n * particular Scripture check, but this type also allows for other types of uniquely identifiable\n * sources.\n */\nexport type ResultsSet = {\n /**\n * The backing source associated with this set of results.\n *\n * @type {ResultsSource}\n */\n source: ResultsSource;\n\n /**\n * Array of Scripture item details (messages keyed by Scripture reference).\n *\n * @type {ScriptureItemDetail[]}\n */\n data: ScriptureItemDetail[];\n};\n\nconst scrBookColId = 'scrBook';\nconst scrRefColId = 'scrRef';\nconst typeColId = 'source';\nconst detailsColId = 'details';\n\nconst defaultScrRefColumnName = 'Scripture Reference';\nconst defaultScrBookGroupName = 'Scripture Book';\nconst defaultTypeColumnName = 'Type';\nconst defaultDetailsColumnName = 'Details';\n\nexport type ScriptureResultsViewerColumnInfo = {\n /** Optional header to display for the Reference column. Default value: 'Scripture Reference'. */\n scriptureReferenceColumnName?: string;\n\n /** Optional text to display to refer to the Scripture book group. Default value: 'Scripture Book'. */\n scriptureBookGroupName?: string;\n\n /** Optional header to display for the Type column. Default value: 'Type'. */\n typeColumnName?: string;\n\n /** Optional header to display for the Details column. Default value: 'Details' */\n detailsColumnName?: string;\n};\n\nexport type ScriptureResultsViewerProps = ScriptureResultsViewerColumnInfo & {\n /** Groups of ScriptureItemDetail objects from particular sources (e.g., Scripture checks) */\n sources: ResultsSet[];\n\n /** Flag indicating whether to display column headers. Default is false. */\n showColumnHeaders?: boolean;\n\n /** Flag indicating whether to display source column. Default is false. */\n showSourceColumn?: boolean;\n\n /** Callback function to notify when a row is selected */\n onRowSelected?: (selectedRow: ScriptureSrcItemDetail | undefined) => void;\n\n /** Text direction ltr or rtl */\n direction?: 'ltr' | 'rtl';\n};\n\nfunction getColumns(\n colInfo?: ScriptureResultsViewerColumnInfo,\n showSourceColumn?: boolean,\n): ColumnDef[] {\n const showSrcCol = showSourceColumn ?? false;\n return [\n {\n accessorFn: (row) =>\n `${Canon.bookNumberToId(row.start.bookNum)} ${row.start.chapterNum}:${row.start.verseNum}`,\n id: scrBookColId,\n header: colInfo?.scriptureReferenceColumnName ?? defaultScrRefColumnName,\n cell: (info) => {\n const row = info.row.original;\n if (info.row.getIsGrouped()) {\n return Canon.bookNumberToEnglishName(row.start.bookNum);\n }\n return info.row.groupingColumnId === scrBookColId ? formatScrRef(row.start) : undefined;\n },\n getGroupingValue: (row) => row.start.bookNum,\n sortingFn: (a, b) => {\n return compareScrRefs(a.original.start, b.original.start);\n },\n enableGrouping: true,\n },\n {\n accessorFn: (row) => formatScrRef(row.start),\n id: scrRefColId,\n header: undefined,\n cell: (info) => {\n const row = info.row.original;\n return info.row.getIsGrouped() ? undefined : formatScrRef(row.start);\n },\n sortingFn: (a, b) => {\n return compareScrRefs(a.original.start, b.original.start);\n },\n enableGrouping: false,\n },\n {\n accessorFn: (row) => row.source.displayName,\n id: typeColId,\n header: showSrcCol ? (colInfo?.typeColumnName ?? defaultTypeColumnName) : undefined,\n cell: (info) => (showSrcCol || info.row.getIsGrouped() ? info.getValue() : undefined),\n getGroupingValue: (row) => row.source.id,\n sortingFn: (a, b) =>\n a.original.source.displayName.localeCompare(b.original.source.displayName),\n enableGrouping: true,\n },\n {\n accessorFn: (row) => row.detail,\n id: detailsColId,\n header: colInfo?.detailsColumnName ?? defaultDetailsColumnName,\n cell: (info) => info.getValue(),\n enableGrouping: false,\n },\n ];\n}\n\nconst toRefOrRange = (scriptureSelection: ScriptureSelection) => {\n if (!('offset' in scriptureSelection.start))\n throw new Error('No offset available in range start');\n if (scriptureSelection.end && !('offset' in scriptureSelection.end))\n throw new Error('No offset available in range end');\n const { offset: offsetStart } = scriptureSelection.start;\n let offsetEnd: number = 0;\n if (scriptureSelection.end) ({ offset: offsetEnd } = scriptureSelection.end);\n if (\n !scriptureSelection.end ||\n compareScrRefs(scriptureSelection.start, scriptureSelection.end) === 0\n )\n return `${scrRefToBBBCCCVVV(scriptureSelection.start)}+${offsetStart}`;\n return `${scrRefToBBBCCCVVV(scriptureSelection.start)}+${offsetStart}-${scrRefToBBBCCCVVV(scriptureSelection.end)}+${offsetEnd}`;\n};\n\nconst getRowKey = (row: ScriptureSrcItemDetail) =>\n `${toRefOrRange({ start: row.start, end: row.end })} ${row.source.displayName} ${row.detail}`;\n\n/**\n * Component to display a combined list of detailed items from one or more sources, where the items\n * are keyed primarily by Scripture reference. This is particularly useful for displaying a list of\n * results from Scripture checks, but more generally could be used to display any \"results\" from any\n * source(s). The component allows for grouping by Scripture book, source, or both. By default, it\n * displays somewhat \"tree-like\" which allows it to be more horizontally compact and intuitive. But\n * it also has the option of displaying as a traditional table with column headings (with or without\n * the source column showing).\n */\nexport default function ScriptureResultsViewer({\n sources,\n showColumnHeaders = false,\n showSourceColumn = false,\n scriptureReferenceColumnName,\n scriptureBookGroupName,\n typeColumnName,\n detailsColumnName,\n onRowSelected,\n direction = 'ltr',\n}: ScriptureResultsViewerProps) {\n const [grouping, setGrouping] = useState([]);\n const [sorting, setSorting] = useState([{ id: scrBookColId, desc: false }]);\n const [rowSelection, setRowSelection] = useState({});\n\n const scriptureResults = useMemo(\n () =>\n sources.flatMap((source) => {\n return source.data.map((item) => ({\n ...item,\n source: source.source,\n }));\n }),\n [sources],\n );\n\n const columns = useMemo(\n () =>\n getColumns(\n {\n scriptureReferenceColumnName,\n typeColumnName,\n detailsColumnName,\n },\n showSourceColumn,\n ),\n [scriptureReferenceColumnName, typeColumnName, detailsColumnName, showSourceColumn],\n );\n\n useEffect(() => {\n // Ensure sorting is applied correctly when grouped by type\n if (grouping.includes(typeColId)) {\n setSorting([\n { id: typeColId, desc: false },\n { id: scrBookColId, desc: false },\n ]);\n } else {\n setSorting([{ id: scrBookColId, desc: false }]);\n }\n }, [grouping]);\n\n const table = useReactTable({\n data: scriptureResults,\n columns,\n state: {\n grouping,\n sorting,\n rowSelection,\n },\n onGroupingChange: setGrouping,\n onSortingChange: setSorting,\n onRowSelectionChange: setRowSelection,\n getExpandedRowModel: getExpandedRowModel(),\n getGroupedRowModel: getGroupedRowModel(),\n getCoreRowModel: getCoreRowModel(),\n getSortedRowModel: getSortedRowModel(),\n getRowId: getRowKey,\n autoResetExpanded: false,\n enableMultiRowSelection: false,\n enableSubRowSelection: false,\n });\n\n useEffect(() => {\n if (onRowSelected) {\n const selectedRows = table.getSelectedRowModel().rowsById;\n const keys = Object.keys(selectedRows);\n if (keys.length === 1) {\n const selectedRow = scriptureResults.find((row) => getRowKey(row) === keys[0]) || undefined;\n if (selectedRow) onRowSelected(selectedRow);\n }\n }\n }, [rowSelection, scriptureResults, onRowSelected, table]);\n\n // Define possible grouping options\n const scrBookGroupName = scriptureBookGroupName ?? defaultScrBookGroupName;\n const typeGroupName = typeColumnName ?? defaultTypeColumnName;\n\n const groupingOptions = [\n { label: 'No Grouping', value: [] },\n { label: `Group by ${scrBookGroupName}`, value: [scrBookColId] },\n { label: `Group by ${typeGroupName}`, value: [typeColId] },\n {\n label: `Group by ${scrBookGroupName} and ${typeGroupName}`,\n value: [scrBookColId, typeColId],\n },\n {\n label: `Group by ${typeGroupName} and ${scrBookGroupName}`,\n value: [typeColId, scrBookColId],\n },\n ];\n\n const handleSelectChange = (selectedGrouping: string) => {\n setGrouping(JSON.parse(selectedGrouping));\n };\n\n const handleRowClick = (row: Row, event: MouseEvent) => {\n if (!row.getIsGrouped() && !row.getIsSelected()) {\n row.getToggleSelectedHandler()(event);\n }\n };\n\n const getEvenOrOddBandingStyle = (row: Row, index: number) => {\n if (row.getIsGrouped()) return '';\n // UX has now said they don't think they want banding. I'm leaving in the code to\n // set even and odd styles, but there's nothing in the CSS to style them differently.\n // The \"even\" style used to also have tw-bg-neutral-300 (along with even) to create\n // a visual banding effect. That could be added back in if UX changes the decision.\n return cn('banded-row', index % 2 === 0 ? 'even' : 'odd');\n };\n\n const getIndent = (\n groupingState: GroupingState,\n row: Row,\n cell: Cell,\n ) => {\n if (groupingState?.length === 0 || row.depth < cell.column.getGroupedIndex()) return undefined;\n if (row.getIsGrouped()) {\n switch (row.depth) {\n case 1:\n return 'tw-ps-4';\n default:\n return undefined;\n }\n }\n switch (row.depth) {\n case 1:\n return 'tw-ps-8';\n case 2:\n return 'tw-ps-12';\n default:\n return undefined;\n }\n };\n\n return (\n
    \n {!showColumnHeaders && (\n {\n handleSelectChange(value);\n }}\n >\n \n \n \n \n \n {groupingOptions.map((option) => (\n \n {option.label}\n \n ))}\n \n \n \n )}\n \n {showColumnHeaders && (\n \n {table.getHeaderGroups().map((headerGroup) => (\n \n {headerGroup.headers\n .filter((h) => h.column.columnDef.header)\n .map((header) => (\n /* For sticky column headers to work, we probably need to change the default definition of the shadcn Table component. See https://github.com/shadcn-ui/ui/issues/1151 */\n \n {header.isPlaceholder ? undefined : (\n
    \n {header.column.getCanGroup() ? (\n \n {header.column.getIsGrouped() ? `🛑` : `👊 `}\n \n ) : undefined}{' '}\n {flexRender(header.column.columnDef.header, header.getContext())}\n
    \n )}\n
    \n ))}\n
    \n ))}\n
    \n )}\n \n {table.getRowModel().rows.map((row, rowIndex) => {\n return (\n handleRowClick(row, event)}\n >\n {row.getVisibleCells().map((cell) => {\n if (\n cell.getIsPlaceholder() ||\n (cell.column.columnDef.enableGrouping &&\n !cell.getIsGrouped() &&\n (cell.column.columnDef.id !== typeColId || !showSourceColumn))\n )\n return undefined;\n return (\n \n {(() => {\n if (cell.getIsGrouped()) {\n return (\n \n {row.getIsExpanded() && }\n {!row.getIsExpanded() &&\n (direction === 'ltr' ? : )}{' '}\n {flexRender(cell.column.columnDef.cell, cell.getContext())} (\n {row.subRows.length})\n \n );\n }\n\n // if (cell.getIsAggregated()) {\n // flexRender(\n // cell.column.columnDef.aggregatedCell ?? cell.column.columnDef.cell,\n // cell.getContext(),\n // );\n // }\n\n return flexRender(cell.column.columnDef.cell, cell.getContext());\n })()}\n \n );\n })}\n \n );\n })}\n \n
    \n
    \n );\n}\n","import {\n getLocalizeKeyForScrollGroupId,\n LanguageStrings,\n ScrollGroupId,\n} from 'platform-bible-utils';\nimport {\n Select,\n SelectContent,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\n\nconst DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS = {\n [getLocalizeKeyForScrollGroupId('undefined')]: 'Ø',\n [getLocalizeKeyForScrollGroupId(0)]: 'A',\n [getLocalizeKeyForScrollGroupId(1)]: 'B',\n [getLocalizeKeyForScrollGroupId(2)]: 'C',\n [getLocalizeKeyForScrollGroupId(3)]: 'D',\n [getLocalizeKeyForScrollGroupId(4)]: 'E',\n [getLocalizeKeyForScrollGroupId(5)]: 'F',\n [getLocalizeKeyForScrollGroupId(6)]: 'G',\n [getLocalizeKeyForScrollGroupId(7)]: 'H',\n [getLocalizeKeyForScrollGroupId(8)]: 'I',\n [getLocalizeKeyForScrollGroupId(9)]: 'J',\n [getLocalizeKeyForScrollGroupId(10)]: 'K',\n [getLocalizeKeyForScrollGroupId(11)]: 'L',\n [getLocalizeKeyForScrollGroupId(12)]: 'M',\n [getLocalizeKeyForScrollGroupId(13)]: 'N',\n [getLocalizeKeyForScrollGroupId(14)]: 'O',\n [getLocalizeKeyForScrollGroupId(15)]: 'P',\n [getLocalizeKeyForScrollGroupId(16)]: 'Q',\n [getLocalizeKeyForScrollGroupId(17)]: 'R',\n [getLocalizeKeyForScrollGroupId(18)]: 'S',\n [getLocalizeKeyForScrollGroupId(19)]: 'T',\n [getLocalizeKeyForScrollGroupId(20)]: 'U',\n [getLocalizeKeyForScrollGroupId(21)]: 'V',\n [getLocalizeKeyForScrollGroupId(22)]: 'W',\n [getLocalizeKeyForScrollGroupId(23)]: 'X',\n [getLocalizeKeyForScrollGroupId(24)]: 'Y',\n [getLocalizeKeyForScrollGroupId(25)]: 'Z',\n};\n\nexport type ScrollGroupSelectorProps = {\n /**\n * List of scroll group ids to show to the user. Either a {@link ScrollGroupId} or `undefined` for\n * no scroll group\n */\n availableScrollGroupIds: (ScrollGroupId | undefined)[];\n /** Currently selected scroll group id. `undefined` for no scroll group */\n scrollGroupId: ScrollGroupId | undefined;\n /** Callback function run when the user tries to change the scroll group id */\n onChangeScrollGroupId: (newScrollGroupId: ScrollGroupId | undefined) => void;\n /**\n * Localized strings to use for displaying scroll group ids. Must be an object whose keys are\n * `getLocalizeKeyForScrollGroupId(scrollGroupId)` for all scroll group ids (and `undefined` if\n * included) in {@link ScrollGroupSelectorProps.availableScrollGroupIds} and whose values are the\n * localized strings to use for those scroll group ids.\n *\n * Defaults to English localizations of English alphabet for scroll groups 0-25 (e.g. 0 is A) and\n * Ø for `undefined`. Will fill in any that are not provided with these English localizations.\n * Also, if any values match the keys, the English localization will be used. This is useful in\n * case you want to pass in a temporary version of the localized strings while your localized\n * strings load.\n *\n * @example\n *\n * ```typescript\n * const myScrollGroupIdLocalizedStrings = {\n * [getLocalizeKeyForScrollGroupId('undefined')]: 'Ø',\n * [getLocalizeKeyForScrollGroupId(0)]: 'A',\n * [getLocalizeKeyForScrollGroupId(1)]: 'B',\n * [getLocalizeKeyForScrollGroupId(2)]: 'C',\n * [getLocalizeKeyForScrollGroupId(3)]: 'D',\n * [getLocalizeKeyForScrollGroupId(4)]: 'E',\n * };\n * ```\n *\n * @example\n *\n * ```tsx\n * const availableScrollGroupIds = [undefined, 0, 1, 2, 3, 4];\n *\n * const localizeKeys = getLocalizeKeysForScrollGroupIds();\n *\n * const [localizedStrings] = useLocalizedStrings(localizeKeys);\n *\n * ...\n *\n * \n * ```\n */\n localizedStrings?: LanguageStrings;\n};\n\n/** Selector component for choosing a scroll group */\nexport default function ScrollGroupSelector({\n availableScrollGroupIds,\n scrollGroupId,\n onChangeScrollGroupId,\n localizedStrings = {},\n}: ScrollGroupSelectorProps) {\n const localizedStringsDefaulted = {\n ...DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS,\n ...Object.fromEntries(\n Object.entries(localizedStrings).map(\n ([localizedStringKey, localizedStringValue]: [string, string]) => [\n localizedStringKey,\n localizedStringKey === localizedStringValue &&\n localizedStringKey in DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS\n ? DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS[localizedStringKey]\n : localizedStringValue,\n ],\n ),\n ),\n };\n return (\n \n onChangeScrollGroupId(\n newScrollGroupString === 'undefined' ? undefined : parseInt(newScrollGroupString, 10),\n )\n }\n >\n \n \n \n \n {availableScrollGroupIds.map((scrollGroupOptionId) => (\n \n {localizedStringsDefaulted[getLocalizeKeyForScrollGroupId(scrollGroupOptionId)]}\n \n ))}\n \n \n );\n}\n","import { PropsWithChildren } from 'react';\nimport { Separator } from '@/components/shadcn-ui/separator';\n\n/** Props for the SettingsList component, currently just children */\ntype SettingsListProps = PropsWithChildren;\n\n/**\n * SettingsList component is a wrapper for list items. Rendered with a formatted div\n *\n * @param children To populate the list with\n * @returns Formatted div encompassing the children\n */\nexport function SettingsList({ children }: SettingsListProps) {\n return
    {children}
    ;\n}\n\n/** Props for SettingsListItem component */\ntype SettingsListItemProps = PropsWithChildren & {\n /** Primary text of the list item */\n primary: string;\n\n /** Optional text of the list item */\n secondary?: string | undefined;\n\n /** Optional boolean to display a message if the children aren't loaded yet. Defaults to false */\n isLoading?: boolean;\n\n /** Optional message to display if isLoading */\n loadingMessage?: string;\n};\n\n/**\n * SettingsListItem component is a common list item. Rendered with a formatted div\n *\n * @param primary Primary text of the list item\n * @param secondary Optional secondary text of the list item\n * @param isLoading Optional, to display a message if the action component isn't generated yet,\n * defaults to false\n * @param children The action component(s) to provide for this item\n * @param loadingMessage Optional, message to display if isLoading\n * @returns Formatted div encompassing the list item content\n */\nexport function SettingsListItem({\n primary,\n secondary,\n children,\n isLoading = false,\n loadingMessage,\n}: SettingsListItemProps) {\n return (\n
    \n
    \n

    {primary}

    \n

    \n {secondary}\n

    \n
    \n\n {isLoading ? (\n

    {loadingMessage}

    \n ) : (\n
    {children}
    \n )}\n
    \n );\n}\n\n/** Props for SettingsListHeader component */\ntype SettingsListHeaderProps = {\n /** The primary text of the list header */\n primary: string;\n\n /** Optional secondary text of the list header */\n secondary?: string | undefined;\n\n /** Optional boolean to include a separator underneath the secondary text. Defaults to false */\n includeSeparator?: boolean;\n};\n\n/**\n * SettingsListHeader component displays text above the list\n *\n * @param primary The primary text of the list header\n * @param secondary Optional secondary text of the list header\n * @param includeSeparator Optional boolean to include a separator underneath the secondary text.\n * Defaults to false\n * @returns Formatted div with list header content\n */\nexport function SettingsListHeader({\n primary,\n secondary,\n includeSeparator = false,\n}: SettingsListHeaderProps) {\n return (\n
    \n
    \n

    {primary}

    \n

    {secondary}

    \n
    \n {includeSeparator ? : ''}\n
    \n );\n}\n","import React from 'react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Card = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nCard.displayName = 'Card';\n\nconst CardHeader = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nCardHeader.displayName = 'CardHeader';\n\nconst CardTitle = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n {/* added because of https://github.com/jsx-eslint/eslint-plugin-jsx-a11y/blob/main/docs/rules/heading-has-content.md */}\n {props.children}\n \n ),\n);\nCardTitle.displayName = 'CardTitle';\n\nconst CardDescription = React.forwardRef<\n HTMLParagraphElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n

    \n));\nCardDescription.displayName = 'CardDescription';\n\nconst CardContent = React.forwardRef>(\n ({ className, ...props }, ref) => (\n

    \n ),\n);\nCardContent.displayName = 'CardContent';\n\nconst CardFooter = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nCardFooter.displayName = 'CardFooter';\n\nexport { Card, CardHeader, CardFooter, CardTitle, CardDescription, CardContent };\n","import { Card, CardDescription, CardHeader, CardTitle } from '@/components/shadcn-ui/card';\nimport { CardContent } from '@mui/material';\nimport { PropsWithChildren } from 'react';\n\ntype SettingsCardProps = PropsWithChildren & {\n settingsGroupLabel: string;\n settingsGroupDescription: string;\n};\n\nexport default function SettingsCard({\n settingsGroupLabel,\n settingsGroupDescription,\n children,\n}: SettingsCardProps) {\n return (\n \n \n {settingsGroupLabel}\n {settingsGroupDescription}\n \n {children}\n \n );\n}\n","import Checkbox from '@/components/shadcn-ui/checkbox';\nimport { Label } from '@/components/shadcn-ui/label';\n\nexport type ChecklistProps = {\n /** Optional string representing the id attribute of the Checklist */\n id?: string;\n /** Optional string representing CSS class name(s) for styling */\n className?: string;\n /** Array of strings representing the checkable items */\n listItems: string[];\n /** Array of strings representing the checked items */\n selectedListItems: string[];\n /**\n * Function that is called when a checkbox item is selected or deselected\n *\n * @param item The string description for this item\n * @param selected True if selected, false if not selected\n */\n handleSelectListItem: (item: string, selected: boolean) => void;\n\n /**\n * Optional function creates a label for a provided checkable item\n *\n * @param item The item for which a label is to be created\n * @returns A string representing the label text for the checkbox associated with that item\n */\n createLabel?: (item: string) => string;\n};\n\n/** Renders a list of checkboxes. Each checkbox corresponds to an item from the `listItems` array. */\nexport default function Checklist({\n id,\n className,\n listItems,\n selectedListItems,\n handleSelectListItem,\n createLabel,\n}: ChecklistProps) {\n return (\n
    \n {listItems.map((item) => (\n
    \n handleSelectListItem(item, value)}\n />\n \n
    \n ))}\n
    \n );\n}\n","function _interopRequireDefault(obj) {\n return obj && obj.__esModule ? obj : {\n \"default\": obj\n };\n}\nmodule.exports = _interopRequireDefault, module.exports.__esModule = true, module.exports[\"default\"] = module.exports;","export default function chainPropTypes(propType1, propType2) {\n if (process.env.NODE_ENV === 'production') {\n return () => null;\n }\n return function validate(...args) {\n return propType1(...args) || propType2(...args);\n };\n}","export default function _extends() {\n _extends = Object.assign ? Object.assign.bind() : function (target) {\n for (var i = 1; i < arguments.length; i++) {\n var source = arguments[i];\n for (var key in source) {\n if (Object.prototype.hasOwnProperty.call(source, key)) {\n target[key] = source[key];\n }\n }\n }\n return target;\n };\n return _extends.apply(this, arguments);\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\n// https://github.com/sindresorhus/is-plain-obj/blob/main/index.js\nexport function isPlainObject(item) {\n if (typeof item !== 'object' || item === null) {\n return false;\n }\n const prototype = Object.getPrototypeOf(item);\n return (prototype === null || prototype === Object.prototype || Object.getPrototypeOf(prototype) === null) && !(Symbol.toStringTag in item) && !(Symbol.iterator in item);\n}\nfunction deepClone(source) {\n if (!isPlainObject(source)) {\n return source;\n }\n const output = {};\n Object.keys(source).forEach(key => {\n output[key] = deepClone(source[key]);\n });\n return output;\n}\nexport default function deepmerge(target, source, options = {\n clone: true\n}) {\n const output = options.clone ? _extends({}, target) : target;\n if (isPlainObject(target) && isPlainObject(source)) {\n Object.keys(source).forEach(key => {\n // Avoid prototype pollution\n if (key === '__proto__') {\n return;\n }\n if (isPlainObject(source[key]) && key in target && isPlainObject(target[key])) {\n // Since `output` is a clone of `target` and we have narrowed `target` in this block we can cast to the same type.\n output[key] = deepmerge(target[key], source[key], options);\n } else if (options.clone) {\n output[key] = isPlainObject(source[key]) ? deepClone(source[key]) : source[key];\n } else {\n output[key] = source[key];\n }\n });\n }\n return output;\n}","/** @license React v16.13.1\n * react-is.production.min.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';var b=\"function\"===typeof Symbol&&Symbol.for,c=b?Symbol.for(\"react.element\"):60103,d=b?Symbol.for(\"react.portal\"):60106,e=b?Symbol.for(\"react.fragment\"):60107,f=b?Symbol.for(\"react.strict_mode\"):60108,g=b?Symbol.for(\"react.profiler\"):60114,h=b?Symbol.for(\"react.provider\"):60109,k=b?Symbol.for(\"react.context\"):60110,l=b?Symbol.for(\"react.async_mode\"):60111,m=b?Symbol.for(\"react.concurrent_mode\"):60111,n=b?Symbol.for(\"react.forward_ref\"):60112,p=b?Symbol.for(\"react.suspense\"):60113,q=b?\nSymbol.for(\"react.suspense_list\"):60120,r=b?Symbol.for(\"react.memo\"):60115,t=b?Symbol.for(\"react.lazy\"):60116,v=b?Symbol.for(\"react.block\"):60121,w=b?Symbol.for(\"react.fundamental\"):60117,x=b?Symbol.for(\"react.responder\"):60118,y=b?Symbol.for(\"react.scope\"):60119;\nfunction z(a){if(\"object\"===typeof a&&null!==a){var u=a.$$typeof;switch(u){case c:switch(a=a.type,a){case l:case m:case e:case g:case f:case p:return a;default:switch(a=a&&a.$$typeof,a){case k:case n:case t:case r:case h:return a;default:return u}}case d:return u}}}function A(a){return z(a)===m}exports.AsyncMode=l;exports.ConcurrentMode=m;exports.ContextConsumer=k;exports.ContextProvider=h;exports.Element=c;exports.ForwardRef=n;exports.Fragment=e;exports.Lazy=t;exports.Memo=r;exports.Portal=d;\nexports.Profiler=g;exports.StrictMode=f;exports.Suspense=p;exports.isAsyncMode=function(a){return A(a)||z(a)===l};exports.isConcurrentMode=A;exports.isContextConsumer=function(a){return z(a)===k};exports.isContextProvider=function(a){return z(a)===h};exports.isElement=function(a){return\"object\"===typeof a&&null!==a&&a.$$typeof===c};exports.isForwardRef=function(a){return z(a)===n};exports.isFragment=function(a){return z(a)===e};exports.isLazy=function(a){return z(a)===t};\nexports.isMemo=function(a){return z(a)===r};exports.isPortal=function(a){return z(a)===d};exports.isProfiler=function(a){return z(a)===g};exports.isStrictMode=function(a){return z(a)===f};exports.isSuspense=function(a){return z(a)===p};\nexports.isValidElementType=function(a){return\"string\"===typeof a||\"function\"===typeof a||a===e||a===m||a===g||a===f||a===p||a===q||\"object\"===typeof a&&null!==a&&(a.$$typeof===t||a.$$typeof===r||a.$$typeof===h||a.$$typeof===k||a.$$typeof===n||a.$$typeof===w||a.$$typeof===x||a.$$typeof===y||a.$$typeof===v)};exports.typeOf=z;\n","/** @license React v16.13.1\n * react-is.development.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\n\n\nif (process.env.NODE_ENV !== \"production\") {\n (function() {\n'use strict';\n\n// The Symbol used to tag the ReactElement-like types. If there is no native Symbol\n// nor polyfill, then a plain number is used for performance.\nvar hasSymbol = typeof Symbol === 'function' && Symbol.for;\nvar REACT_ELEMENT_TYPE = hasSymbol ? Symbol.for('react.element') : 0xeac7;\nvar REACT_PORTAL_TYPE = hasSymbol ? Symbol.for('react.portal') : 0xeaca;\nvar REACT_FRAGMENT_TYPE = hasSymbol ? Symbol.for('react.fragment') : 0xeacb;\nvar REACT_STRICT_MODE_TYPE = hasSymbol ? Symbol.for('react.strict_mode') : 0xeacc;\nvar REACT_PROFILER_TYPE = hasSymbol ? Symbol.for('react.profiler') : 0xead2;\nvar REACT_PROVIDER_TYPE = hasSymbol ? Symbol.for('react.provider') : 0xeacd;\nvar REACT_CONTEXT_TYPE = hasSymbol ? Symbol.for('react.context') : 0xeace; // TODO: We don't use AsyncMode or ConcurrentMode anymore. They were temporary\n// (unstable) APIs that have been removed. Can we remove the symbols?\n\nvar REACT_ASYNC_MODE_TYPE = hasSymbol ? Symbol.for('react.async_mode') : 0xeacf;\nvar REACT_CONCURRENT_MODE_TYPE = hasSymbol ? Symbol.for('react.concurrent_mode') : 0xeacf;\nvar REACT_FORWARD_REF_TYPE = hasSymbol ? Symbol.for('react.forward_ref') : 0xead0;\nvar REACT_SUSPENSE_TYPE = hasSymbol ? Symbol.for('react.suspense') : 0xead1;\nvar REACT_SUSPENSE_LIST_TYPE = hasSymbol ? Symbol.for('react.suspense_list') : 0xead8;\nvar REACT_MEMO_TYPE = hasSymbol ? Symbol.for('react.memo') : 0xead3;\nvar REACT_LAZY_TYPE = hasSymbol ? Symbol.for('react.lazy') : 0xead4;\nvar REACT_BLOCK_TYPE = hasSymbol ? Symbol.for('react.block') : 0xead9;\nvar REACT_FUNDAMENTAL_TYPE = hasSymbol ? Symbol.for('react.fundamental') : 0xead5;\nvar REACT_RESPONDER_TYPE = hasSymbol ? Symbol.for('react.responder') : 0xead6;\nvar REACT_SCOPE_TYPE = hasSymbol ? Symbol.for('react.scope') : 0xead7;\n\nfunction isValidElementType(type) {\n return typeof type === 'string' || typeof type === 'function' || // Note: its typeof might be other than 'symbol' or 'number' if it's a polyfill.\n type === REACT_FRAGMENT_TYPE || type === REACT_CONCURRENT_MODE_TYPE || type === REACT_PROFILER_TYPE || type === REACT_STRICT_MODE_TYPE || type === REACT_SUSPENSE_TYPE || type === REACT_SUSPENSE_LIST_TYPE || typeof type === 'object' && type !== null && (type.$$typeof === REACT_LAZY_TYPE || type.$$typeof === REACT_MEMO_TYPE || type.$$typeof === REACT_PROVIDER_TYPE || type.$$typeof === REACT_CONTEXT_TYPE || type.$$typeof === REACT_FORWARD_REF_TYPE || type.$$typeof === REACT_FUNDAMENTAL_TYPE || type.$$typeof === REACT_RESPONDER_TYPE || type.$$typeof === REACT_SCOPE_TYPE || type.$$typeof === REACT_BLOCK_TYPE);\n}\n\nfunction typeOf(object) {\n if (typeof object === 'object' && object !== null) {\n var $$typeof = object.$$typeof;\n\n switch ($$typeof) {\n case REACT_ELEMENT_TYPE:\n var type = object.type;\n\n switch (type) {\n case REACT_ASYNC_MODE_TYPE:\n case REACT_CONCURRENT_MODE_TYPE:\n case REACT_FRAGMENT_TYPE:\n case REACT_PROFILER_TYPE:\n case REACT_STRICT_MODE_TYPE:\n case REACT_SUSPENSE_TYPE:\n return type;\n\n default:\n var $$typeofType = type && type.$$typeof;\n\n switch ($$typeofType) {\n case REACT_CONTEXT_TYPE:\n case REACT_FORWARD_REF_TYPE:\n case REACT_LAZY_TYPE:\n case REACT_MEMO_TYPE:\n case REACT_PROVIDER_TYPE:\n return $$typeofType;\n\n default:\n return $$typeof;\n }\n\n }\n\n case REACT_PORTAL_TYPE:\n return $$typeof;\n }\n }\n\n return undefined;\n} // AsyncMode is deprecated along with isAsyncMode\n\nvar AsyncMode = REACT_ASYNC_MODE_TYPE;\nvar ConcurrentMode = REACT_CONCURRENT_MODE_TYPE;\nvar ContextConsumer = REACT_CONTEXT_TYPE;\nvar ContextProvider = REACT_PROVIDER_TYPE;\nvar Element = REACT_ELEMENT_TYPE;\nvar ForwardRef = REACT_FORWARD_REF_TYPE;\nvar Fragment = REACT_FRAGMENT_TYPE;\nvar Lazy = REACT_LAZY_TYPE;\nvar Memo = REACT_MEMO_TYPE;\nvar Portal = REACT_PORTAL_TYPE;\nvar Profiler = REACT_PROFILER_TYPE;\nvar StrictMode = REACT_STRICT_MODE_TYPE;\nvar Suspense = REACT_SUSPENSE_TYPE;\nvar hasWarnedAboutDeprecatedIsAsyncMode = false; // AsyncMode should be deprecated\n\nfunction isAsyncMode(object) {\n {\n if (!hasWarnedAboutDeprecatedIsAsyncMode) {\n hasWarnedAboutDeprecatedIsAsyncMode = true; // Using console['warn'] to evade Babel and ESLint\n\n console['warn']('The ReactIs.isAsyncMode() alias has been deprecated, ' + 'and will be removed in React 17+. Update your code to use ' + 'ReactIs.isConcurrentMode() instead. It has the exact same API.');\n }\n }\n\n return isConcurrentMode(object) || typeOf(object) === REACT_ASYNC_MODE_TYPE;\n}\nfunction isConcurrentMode(object) {\n return typeOf(object) === REACT_CONCURRENT_MODE_TYPE;\n}\nfunction isContextConsumer(object) {\n return typeOf(object) === REACT_CONTEXT_TYPE;\n}\nfunction isContextProvider(object) {\n return typeOf(object) === REACT_PROVIDER_TYPE;\n}\nfunction isElement(object) {\n return typeof object === 'object' && object !== null && object.$$typeof === REACT_ELEMENT_TYPE;\n}\nfunction isForwardRef(object) {\n return typeOf(object) === REACT_FORWARD_REF_TYPE;\n}\nfunction isFragment(object) {\n return typeOf(object) === REACT_FRAGMENT_TYPE;\n}\nfunction isLazy(object) {\n return typeOf(object) === REACT_LAZY_TYPE;\n}\nfunction isMemo(object) {\n return typeOf(object) === REACT_MEMO_TYPE;\n}\nfunction isPortal(object) {\n return typeOf(object) === REACT_PORTAL_TYPE;\n}\nfunction isProfiler(object) {\n return typeOf(object) === REACT_PROFILER_TYPE;\n}\nfunction isStrictMode(object) {\n return typeOf(object) === REACT_STRICT_MODE_TYPE;\n}\nfunction isSuspense(object) {\n return typeOf(object) === REACT_SUSPENSE_TYPE;\n}\n\nexports.AsyncMode = AsyncMode;\nexports.ConcurrentMode = ConcurrentMode;\nexports.ContextConsumer = ContextConsumer;\nexports.ContextProvider = ContextProvider;\nexports.Element = Element;\nexports.ForwardRef = ForwardRef;\nexports.Fragment = Fragment;\nexports.Lazy = Lazy;\nexports.Memo = Memo;\nexports.Portal = Portal;\nexports.Profiler = Profiler;\nexports.StrictMode = StrictMode;\nexports.Suspense = Suspense;\nexports.isAsyncMode = isAsyncMode;\nexports.isConcurrentMode = isConcurrentMode;\nexports.isContextConsumer = isContextConsumer;\nexports.isContextProvider = isContextProvider;\nexports.isElement = isElement;\nexports.isForwardRef = isForwardRef;\nexports.isFragment = isFragment;\nexports.isLazy = isLazy;\nexports.isMemo = isMemo;\nexports.isPortal = isPortal;\nexports.isProfiler = isProfiler;\nexports.isStrictMode = isStrictMode;\nexports.isSuspense = isSuspense;\nexports.isValidElementType = isValidElementType;\nexports.typeOf = typeOf;\n })();\n}\n","'use strict';\n\nif (process.env.NODE_ENV === 'production') {\n module.exports = require('./cjs/react-is.production.min.js');\n} else {\n module.exports = require('./cjs/react-is.development.js');\n}\n","/*\nobject-assign\n(c) Sindre Sorhus\n@license MIT\n*/\n\n'use strict';\n/* eslint-disable no-unused-vars */\nvar getOwnPropertySymbols = Object.getOwnPropertySymbols;\nvar hasOwnProperty = Object.prototype.hasOwnProperty;\nvar propIsEnumerable = Object.prototype.propertyIsEnumerable;\n\nfunction toObject(val) {\n\tif (val === null || val === undefined) {\n\t\tthrow new TypeError('Object.assign cannot be called with null or undefined');\n\t}\n\n\treturn Object(val);\n}\n\nfunction shouldUseNative() {\n\ttry {\n\t\tif (!Object.assign) {\n\t\t\treturn false;\n\t\t}\n\n\t\t// Detect buggy property enumeration order in older V8 versions.\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=4118\n\t\tvar test1 = new String('abc'); // eslint-disable-line no-new-wrappers\n\t\ttest1[5] = 'de';\n\t\tif (Object.getOwnPropertyNames(test1)[0] === '5') {\n\t\t\treturn false;\n\t\t}\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=3056\n\t\tvar test2 = {};\n\t\tfor (var i = 0; i < 10; i++) {\n\t\t\ttest2['_' + String.fromCharCode(i)] = i;\n\t\t}\n\t\tvar order2 = Object.getOwnPropertyNames(test2).map(function (n) {\n\t\t\treturn test2[n];\n\t\t});\n\t\tif (order2.join('') !== '0123456789') {\n\t\t\treturn false;\n\t\t}\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=3056\n\t\tvar test3 = {};\n\t\t'abcdefghijklmnopqrst'.split('').forEach(function (letter) {\n\t\t\ttest3[letter] = letter;\n\t\t});\n\t\tif (Object.keys(Object.assign({}, test3)).join('') !==\n\t\t\t\t'abcdefghijklmnopqrst') {\n\t\t\treturn false;\n\t\t}\n\n\t\treturn true;\n\t} catch (err) {\n\t\t// We don't expect any of the above to throw, but better to be safe.\n\t\treturn false;\n\t}\n}\n\nmodule.exports = shouldUseNative() ? Object.assign : function (target, source) {\n\tvar from;\n\tvar to = toObject(target);\n\tvar symbols;\n\n\tfor (var s = 1; s < arguments.length; s++) {\n\t\tfrom = Object(arguments[s]);\n\n\t\tfor (var key in from) {\n\t\t\tif (hasOwnProperty.call(from, key)) {\n\t\t\t\tto[key] = from[key];\n\t\t\t}\n\t\t}\n\n\t\tif (getOwnPropertySymbols) {\n\t\t\tsymbols = getOwnPropertySymbols(from);\n\t\t\tfor (var i = 0; i < symbols.length; i++) {\n\t\t\t\tif (propIsEnumerable.call(from, symbols[i])) {\n\t\t\t\t\tto[symbols[i]] = from[symbols[i]];\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\n\treturn to;\n};\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar ReactPropTypesSecret = 'SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED';\n\nmodule.exports = ReactPropTypesSecret;\n","module.exports = Function.call.bind(Object.prototype.hasOwnProperty);\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar printWarning = function() {};\n\nif (process.env.NODE_ENV !== 'production') {\n var ReactPropTypesSecret = require('./lib/ReactPropTypesSecret');\n var loggedTypeFailures = {};\n var has = require('./lib/has');\n\n printWarning = function(text) {\n var message = 'Warning: ' + text;\n if (typeof console !== 'undefined') {\n console.error(message);\n }\n try {\n // --- Welcome to debugging React ---\n // This error was thrown as a convenience so that you can use this stack\n // to find the callsite that caused this warning to fire.\n throw new Error(message);\n } catch (x) { /**/ }\n };\n}\n\n/**\n * Assert that the values match with the type specs.\n * Error messages are memorized and will only be shown once.\n *\n * @param {object} typeSpecs Map of name to a ReactPropType\n * @param {object} values Runtime values that need to be type-checked\n * @param {string} location e.g. \"prop\", \"context\", \"child context\"\n * @param {string} componentName Name of the component for error messages.\n * @param {?Function} getStack Returns the component stack.\n * @private\n */\nfunction checkPropTypes(typeSpecs, values, location, componentName, getStack) {\n if (process.env.NODE_ENV !== 'production') {\n for (var typeSpecName in typeSpecs) {\n if (has(typeSpecs, typeSpecName)) {\n var error;\n // Prop type validation may throw. In case they do, we don't want to\n // fail the render phase where it didn't fail before. So we log it.\n // After these have been cleaned up, we'll let them throw.\n try {\n // This is intentionally an invariant that gets caught. It's the same\n // behavior as without this statement except with a better message.\n if (typeof typeSpecs[typeSpecName] !== 'function') {\n var err = Error(\n (componentName || 'React class') + ': ' + location + ' type `' + typeSpecName + '` is invalid; ' +\n 'it must be a function, usually from the `prop-types` package, but received `' + typeof typeSpecs[typeSpecName] + '`.' +\n 'This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.'\n );\n err.name = 'Invariant Violation';\n throw err;\n }\n error = typeSpecs[typeSpecName](values, typeSpecName, componentName, location, null, ReactPropTypesSecret);\n } catch (ex) {\n error = ex;\n }\n if (error && !(error instanceof Error)) {\n printWarning(\n (componentName || 'React class') + ': type specification of ' +\n location + ' `' + typeSpecName + '` is invalid; the type checker ' +\n 'function must return `null` or an `Error` but returned a ' + typeof error + '. ' +\n 'You may have forgotten to pass an argument to the type checker ' +\n 'creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and ' +\n 'shape all require an argument).'\n );\n }\n if (error instanceof Error && !(error.message in loggedTypeFailures)) {\n // Only monitor this failure once because there tends to be a lot of the\n // same error.\n loggedTypeFailures[error.message] = true;\n\n var stack = getStack ? getStack() : '';\n\n printWarning(\n 'Failed ' + location + ' type: ' + error.message + (stack != null ? stack : '')\n );\n }\n }\n }\n }\n}\n\n/**\n * Resets warning cache when testing.\n *\n * @private\n */\ncheckPropTypes.resetWarningCache = function() {\n if (process.env.NODE_ENV !== 'production') {\n loggedTypeFailures = {};\n }\n}\n\nmodule.exports = checkPropTypes;\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar ReactIs = require('react-is');\nvar assign = require('object-assign');\n\nvar ReactPropTypesSecret = require('./lib/ReactPropTypesSecret');\nvar has = require('./lib/has');\nvar checkPropTypes = require('./checkPropTypes');\n\nvar printWarning = function() {};\n\nif (process.env.NODE_ENV !== 'production') {\n printWarning = function(text) {\n var message = 'Warning: ' + text;\n if (typeof console !== 'undefined') {\n console.error(message);\n }\n try {\n // --- Welcome to debugging React ---\n // This error was thrown as a convenience so that you can use this stack\n // to find the callsite that caused this warning to fire.\n throw new Error(message);\n } catch (x) {}\n };\n}\n\nfunction emptyFunctionThatReturnsNull() {\n return null;\n}\n\nmodule.exports = function(isValidElement, throwOnDirectAccess) {\n /* global Symbol */\n var ITERATOR_SYMBOL = typeof Symbol === 'function' && Symbol.iterator;\n var FAUX_ITERATOR_SYMBOL = '@@iterator'; // Before Symbol spec.\n\n /**\n * Returns the iterator method function contained on the iterable object.\n *\n * Be sure to invoke the function with the iterable as context:\n *\n * var iteratorFn = getIteratorFn(myIterable);\n * if (iteratorFn) {\n * var iterator = iteratorFn.call(myIterable);\n * ...\n * }\n *\n * @param {?object} maybeIterable\n * @return {?function}\n */\n function getIteratorFn(maybeIterable) {\n var iteratorFn = maybeIterable && (ITERATOR_SYMBOL && maybeIterable[ITERATOR_SYMBOL] || maybeIterable[FAUX_ITERATOR_SYMBOL]);\n if (typeof iteratorFn === 'function') {\n return iteratorFn;\n }\n }\n\n /**\n * Collection of methods that allow declaration and validation of props that are\n * supplied to React components. Example usage:\n *\n * var Props = require('ReactPropTypes');\n * var MyArticle = React.createClass({\n * propTypes: {\n * // An optional string prop named \"description\".\n * description: Props.string,\n *\n * // A required enum prop named \"category\".\n * category: Props.oneOf(['News','Photos']).isRequired,\n *\n * // A prop named \"dialog\" that requires an instance of Dialog.\n * dialog: Props.instanceOf(Dialog).isRequired\n * },\n * render: function() { ... }\n * });\n *\n * A more formal specification of how these methods are used:\n *\n * type := array|bool|func|object|number|string|oneOf([...])|instanceOf(...)\n * decl := ReactPropTypes.{type}(.isRequired)?\n *\n * Each and every declaration produces a function with the same signature. This\n * allows the creation of custom validation functions. For example:\n *\n * var MyLink = React.createClass({\n * propTypes: {\n * // An optional string or URI prop named \"href\".\n * href: function(props, propName, componentName) {\n * var propValue = props[propName];\n * if (propValue != null && typeof propValue !== 'string' &&\n * !(propValue instanceof URI)) {\n * return new Error(\n * 'Expected a string or an URI for ' + propName + ' in ' +\n * componentName\n * );\n * }\n * }\n * },\n * render: function() {...}\n * });\n *\n * @internal\n */\n\n var ANONYMOUS = '<>';\n\n // Important!\n // Keep this list in sync with production version in `./factoryWithThrowingShims.js`.\n var ReactPropTypes = {\n array: createPrimitiveTypeChecker('array'),\n bigint: createPrimitiveTypeChecker('bigint'),\n bool: createPrimitiveTypeChecker('boolean'),\n func: createPrimitiveTypeChecker('function'),\n number: createPrimitiveTypeChecker('number'),\n object: createPrimitiveTypeChecker('object'),\n string: createPrimitiveTypeChecker('string'),\n symbol: createPrimitiveTypeChecker('symbol'),\n\n any: createAnyTypeChecker(),\n arrayOf: createArrayOfTypeChecker,\n element: createElementTypeChecker(),\n elementType: createElementTypeTypeChecker(),\n instanceOf: createInstanceTypeChecker,\n node: createNodeChecker(),\n objectOf: createObjectOfTypeChecker,\n oneOf: createEnumTypeChecker,\n oneOfType: createUnionTypeChecker,\n shape: createShapeTypeChecker,\n exact: createStrictShapeTypeChecker,\n };\n\n /**\n * inlined Object.is polyfill to avoid requiring consumers ship their own\n * https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object/is\n */\n /*eslint-disable no-self-compare*/\n function is(x, y) {\n // SameValue algorithm\n if (x === y) {\n // Steps 1-5, 7-10\n // Steps 6.b-6.e: +0 != -0\n return x !== 0 || 1 / x === 1 / y;\n } else {\n // Step 6.a: NaN == NaN\n return x !== x && y !== y;\n }\n }\n /*eslint-enable no-self-compare*/\n\n /**\n * We use an Error-like object for backward compatibility as people may call\n * PropTypes directly and inspect their output. However, we don't use real\n * Errors anymore. We don't inspect their stack anyway, and creating them\n * is prohibitively expensive if they are created too often, such as what\n * happens in oneOfType() for any type before the one that matched.\n */\n function PropTypeError(message, data) {\n this.message = message;\n this.data = data && typeof data === 'object' ? data: {};\n this.stack = '';\n }\n // Make `instanceof Error` still work for returned errors.\n PropTypeError.prototype = Error.prototype;\n\n function createChainableTypeChecker(validate) {\n if (process.env.NODE_ENV !== 'production') {\n var manualPropTypeCallCache = {};\n var manualPropTypeWarningCount = 0;\n }\n function checkType(isRequired, props, propName, componentName, location, propFullName, secret) {\n componentName = componentName || ANONYMOUS;\n propFullName = propFullName || propName;\n\n if (secret !== ReactPropTypesSecret) {\n if (throwOnDirectAccess) {\n // New behavior only for users of `prop-types` package\n var err = new Error(\n 'Calling PropTypes validators directly is not supported by the `prop-types` package. ' +\n 'Use `PropTypes.checkPropTypes()` to call them. ' +\n 'Read more at http://fb.me/use-check-prop-types'\n );\n err.name = 'Invariant Violation';\n throw err;\n } else if (process.env.NODE_ENV !== 'production' && typeof console !== 'undefined') {\n // Old behavior for people using React.PropTypes\n var cacheKey = componentName + ':' + propName;\n if (\n !manualPropTypeCallCache[cacheKey] &&\n // Avoid spamming the console because they are often not actionable except for lib authors\n manualPropTypeWarningCount < 3\n ) {\n printWarning(\n 'You are manually calling a React.PropTypes validation ' +\n 'function for the `' + propFullName + '` prop on `' + componentName + '`. This is deprecated ' +\n 'and will throw in the standalone `prop-types` package. ' +\n 'You may be seeing this warning due to a third-party PropTypes ' +\n 'library. See https://fb.me/react-warning-dont-call-proptypes ' + 'for details.'\n );\n manualPropTypeCallCache[cacheKey] = true;\n manualPropTypeWarningCount++;\n }\n }\n }\n if (props[propName] == null) {\n if (isRequired) {\n if (props[propName] === null) {\n return new PropTypeError('The ' + location + ' `' + propFullName + '` is marked as required ' + ('in `' + componentName + '`, but its value is `null`.'));\n }\n return new PropTypeError('The ' + location + ' `' + propFullName + '` is marked as required in ' + ('`' + componentName + '`, but its value is `undefined`.'));\n }\n return null;\n } else {\n return validate(props, propName, componentName, location, propFullName);\n }\n }\n\n var chainedCheckType = checkType.bind(null, false);\n chainedCheckType.isRequired = checkType.bind(null, true);\n\n return chainedCheckType;\n }\n\n function createPrimitiveTypeChecker(expectedType) {\n function validate(props, propName, componentName, location, propFullName, secret) {\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== expectedType) {\n // `propValue` being instance of, say, date/regexp, pass the 'object'\n // check, but we can offer a more precise error message here rather than\n // 'of type `object`'.\n var preciseType = getPreciseType(propValue);\n\n return new PropTypeError(\n 'Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + preciseType + '` supplied to `' + componentName + '`, expected ') + ('`' + expectedType + '`.'),\n {expectedType: expectedType}\n );\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createAnyTypeChecker() {\n return createChainableTypeChecker(emptyFunctionThatReturnsNull);\n }\n\n function createArrayOfTypeChecker(typeChecker) {\n function validate(props, propName, componentName, location, propFullName) {\n if (typeof typeChecker !== 'function') {\n return new PropTypeError('Property `' + propFullName + '` of component `' + componentName + '` has invalid PropType notation inside arrayOf.');\n }\n var propValue = props[propName];\n if (!Array.isArray(propValue)) {\n var propType = getPropType(propValue);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected an array.'));\n }\n for (var i = 0; i < propValue.length; i++) {\n var error = typeChecker(propValue, i, componentName, location, propFullName + '[' + i + ']', ReactPropTypesSecret);\n if (error instanceof Error) {\n return error;\n }\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createElementTypeChecker() {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n if (!isValidElement(propValue)) {\n var propType = getPropType(propValue);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected a single ReactElement.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createElementTypeTypeChecker() {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n if (!ReactIs.isValidElementType(propValue)) {\n var propType = getPropType(propValue);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected a single ReactElement type.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createInstanceTypeChecker(expectedClass) {\n function validate(props, propName, componentName, location, propFullName) {\n if (!(props[propName] instanceof expectedClass)) {\n var expectedClassName = expectedClass.name || ANONYMOUS;\n var actualClassName = getClassName(props[propName]);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + actualClassName + '` supplied to `' + componentName + '`, expected ') + ('instance of `' + expectedClassName + '`.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createEnumTypeChecker(expectedValues) {\n if (!Array.isArray(expectedValues)) {\n if (process.env.NODE_ENV !== 'production') {\n if (arguments.length > 1) {\n printWarning(\n 'Invalid arguments supplied to oneOf, expected an array, got ' + arguments.length + ' arguments. ' +\n 'A common mistake is to write oneOf(x, y, z) instead of oneOf([x, y, z]).'\n );\n } else {\n printWarning('Invalid argument supplied to oneOf, expected an array.');\n }\n }\n return emptyFunctionThatReturnsNull;\n }\n\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n for (var i = 0; i < expectedValues.length; i++) {\n if (is(propValue, expectedValues[i])) {\n return null;\n }\n }\n\n var valuesString = JSON.stringify(expectedValues, function replacer(key, value) {\n var type = getPreciseType(value);\n if (type === 'symbol') {\n return String(value);\n }\n return value;\n });\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of value `' + String(propValue) + '` ' + ('supplied to `' + componentName + '`, expected one of ' + valuesString + '.'));\n }\n return createChainableTypeChecker(validate);\n }\n\n function createObjectOfTypeChecker(typeChecker) {\n function validate(props, propName, componentName, location, propFullName) {\n if (typeof typeChecker !== 'function') {\n return new PropTypeError('Property `' + propFullName + '` of component `' + componentName + '` has invalid PropType notation inside objectOf.');\n }\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== 'object') {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected an object.'));\n }\n for (var key in propValue) {\n if (has(propValue, key)) {\n var error = typeChecker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret);\n if (error instanceof Error) {\n return error;\n }\n }\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createUnionTypeChecker(arrayOfTypeCheckers) {\n if (!Array.isArray(arrayOfTypeCheckers)) {\n process.env.NODE_ENV !== 'production' ? printWarning('Invalid argument supplied to oneOfType, expected an instance of array.') : void 0;\n return emptyFunctionThatReturnsNull;\n }\n\n for (var i = 0; i < arrayOfTypeCheckers.length; i++) {\n var checker = arrayOfTypeCheckers[i];\n if (typeof checker !== 'function') {\n printWarning(\n 'Invalid argument supplied to oneOfType. Expected an array of check functions, but ' +\n 'received ' + getPostfixForTypeWarning(checker) + ' at index ' + i + '.'\n );\n return emptyFunctionThatReturnsNull;\n }\n }\n\n function validate(props, propName, componentName, location, propFullName) {\n var expectedTypes = [];\n for (var i = 0; i < arrayOfTypeCheckers.length; i++) {\n var checker = arrayOfTypeCheckers[i];\n var checkerResult = checker(props, propName, componentName, location, propFullName, ReactPropTypesSecret);\n if (checkerResult == null) {\n return null;\n }\n if (checkerResult.data && has(checkerResult.data, 'expectedType')) {\n expectedTypes.push(checkerResult.data.expectedType);\n }\n }\n var expectedTypesMessage = (expectedTypes.length > 0) ? ', expected one of type [' + expectedTypes.join(', ') + ']': '';\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` supplied to ' + ('`' + componentName + '`' + expectedTypesMessage + '.'));\n }\n return createChainableTypeChecker(validate);\n }\n\n function createNodeChecker() {\n function validate(props, propName, componentName, location, propFullName) {\n if (!isNode(props[propName])) {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` supplied to ' + ('`' + componentName + '`, expected a ReactNode.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function invalidValidatorError(componentName, location, propFullName, key, type) {\n return new PropTypeError(\n (componentName || 'React class') + ': ' + location + ' type `' + propFullName + '.' + key + '` is invalid; ' +\n 'it must be a function, usually from the `prop-types` package, but received `' + type + '`.'\n );\n }\n\n function createShapeTypeChecker(shapeTypes) {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== 'object') {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type `' + propType + '` ' + ('supplied to `' + componentName + '`, expected `object`.'));\n }\n for (var key in shapeTypes) {\n var checker = shapeTypes[key];\n if (typeof checker !== 'function') {\n return invalidValidatorError(componentName, location, propFullName, key, getPreciseType(checker));\n }\n var error = checker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret);\n if (error) {\n return error;\n }\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createStrictShapeTypeChecker(shapeTypes) {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== 'object') {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type `' + propType + '` ' + ('supplied to `' + componentName + '`, expected `object`.'));\n }\n // We need to check all keys in case some are required but missing from props.\n var allKeys = assign({}, props[propName], shapeTypes);\n for (var key in allKeys) {\n var checker = shapeTypes[key];\n if (has(shapeTypes, key) && typeof checker !== 'function') {\n return invalidValidatorError(componentName, location, propFullName, key, getPreciseType(checker));\n }\n if (!checker) {\n return new PropTypeError(\n 'Invalid ' + location + ' `' + propFullName + '` key `' + key + '` supplied to `' + componentName + '`.' +\n '\\nBad object: ' + JSON.stringify(props[propName], null, ' ') +\n '\\nValid keys: ' + JSON.stringify(Object.keys(shapeTypes), null, ' ')\n );\n }\n var error = checker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret);\n if (error) {\n return error;\n }\n }\n return null;\n }\n\n return createChainableTypeChecker(validate);\n }\n\n function isNode(propValue) {\n switch (typeof propValue) {\n case 'number':\n case 'string':\n case 'undefined':\n return true;\n case 'boolean':\n return !propValue;\n case 'object':\n if (Array.isArray(propValue)) {\n return propValue.every(isNode);\n }\n if (propValue === null || isValidElement(propValue)) {\n return true;\n }\n\n var iteratorFn = getIteratorFn(propValue);\n if (iteratorFn) {\n var iterator = iteratorFn.call(propValue);\n var step;\n if (iteratorFn !== propValue.entries) {\n while (!(step = iterator.next()).done) {\n if (!isNode(step.value)) {\n return false;\n }\n }\n } else {\n // Iterator will provide entry [k,v] tuples rather than values.\n while (!(step = iterator.next()).done) {\n var entry = step.value;\n if (entry) {\n if (!isNode(entry[1])) {\n return false;\n }\n }\n }\n }\n } else {\n return false;\n }\n\n return true;\n default:\n return false;\n }\n }\n\n function isSymbol(propType, propValue) {\n // Native Symbol.\n if (propType === 'symbol') {\n return true;\n }\n\n // falsy value can't be a Symbol\n if (!propValue) {\n return false;\n }\n\n // 19.4.3.5 Symbol.prototype[@@toStringTag] === 'Symbol'\n if (propValue['@@toStringTag'] === 'Symbol') {\n return true;\n }\n\n // Fallback for non-spec compliant Symbols which are polyfilled.\n if (typeof Symbol === 'function' && propValue instanceof Symbol) {\n return true;\n }\n\n return false;\n }\n\n // Equivalent of `typeof` but with special handling for array and regexp.\n function getPropType(propValue) {\n var propType = typeof propValue;\n if (Array.isArray(propValue)) {\n return 'array';\n }\n if (propValue instanceof RegExp) {\n // Old webkits (at least until Android 4.0) return 'function' rather than\n // 'object' for typeof a RegExp. We'll normalize this here so that /bla/\n // passes PropTypes.object.\n return 'object';\n }\n if (isSymbol(propType, propValue)) {\n return 'symbol';\n }\n return propType;\n }\n\n // This handles more types than `getPropType`. Only used for error messages.\n // See `createPrimitiveTypeChecker`.\n function getPreciseType(propValue) {\n if (typeof propValue === 'undefined' || propValue === null) {\n return '' + propValue;\n }\n var propType = getPropType(propValue);\n if (propType === 'object') {\n if (propValue instanceof Date) {\n return 'date';\n } else if (propValue instanceof RegExp) {\n return 'regexp';\n }\n }\n return propType;\n }\n\n // Returns a string that is postfixed to a warning about an invalid type.\n // For example, \"undefined\" or \"of type array\"\n function getPostfixForTypeWarning(value) {\n var type = getPreciseType(value);\n switch (type) {\n case 'array':\n case 'object':\n return 'an ' + type;\n case 'boolean':\n case 'date':\n case 'regexp':\n return 'a ' + type;\n default:\n return type;\n }\n }\n\n // Returns class name of the object, if any.\n function getClassName(propValue) {\n if (!propValue.constructor || !propValue.constructor.name) {\n return ANONYMOUS;\n }\n return propValue.constructor.name;\n }\n\n ReactPropTypes.checkPropTypes = checkPropTypes;\n ReactPropTypes.resetWarningCache = checkPropTypes.resetWarningCache;\n ReactPropTypes.PropTypes = ReactPropTypes;\n\n return ReactPropTypes;\n};\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar ReactPropTypesSecret = require('./lib/ReactPropTypesSecret');\n\nfunction emptyFunction() {}\nfunction emptyFunctionWithReset() {}\nemptyFunctionWithReset.resetWarningCache = emptyFunction;\n\nmodule.exports = function() {\n function shim(props, propName, componentName, location, propFullName, secret) {\n if (secret === ReactPropTypesSecret) {\n // It is still safe when called from React.\n return;\n }\n var err = new Error(\n 'Calling PropTypes validators directly is not supported by the `prop-types` package. ' +\n 'Use PropTypes.checkPropTypes() to call them. ' +\n 'Read more at http://fb.me/use-check-prop-types'\n );\n err.name = 'Invariant Violation';\n throw err;\n };\n shim.isRequired = shim;\n function getShim() {\n return shim;\n };\n // Important!\n // Keep this list in sync with production version in `./factoryWithTypeCheckers.js`.\n var ReactPropTypes = {\n array: shim,\n bigint: shim,\n bool: shim,\n func: shim,\n number: shim,\n object: shim,\n string: shim,\n symbol: shim,\n\n any: shim,\n arrayOf: getShim,\n element: shim,\n elementType: shim,\n instanceOf: getShim,\n node: shim,\n objectOf: getShim,\n oneOf: getShim,\n oneOfType: getShim,\n shape: getShim,\n exact: getShim,\n\n checkPropTypes: emptyFunctionWithReset,\n resetWarningCache: emptyFunction\n };\n\n ReactPropTypes.PropTypes = ReactPropTypes;\n\n return ReactPropTypes;\n};\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\nif (process.env.NODE_ENV !== 'production') {\n var ReactIs = require('react-is');\n\n // By explicitly using `prop-types` you are opting into new development behavior.\n // http://fb.me/prop-types-in-prod\n var throwOnDirectAccess = true;\n module.exports = require('./factoryWithTypeCheckers')(ReactIs.isElement, throwOnDirectAccess);\n} else {\n // By explicitly using `prop-types` you are opting into new production behavior.\n // http://fb.me/prop-types-in-prod\n module.exports = require('./factoryWithThrowingShims')();\n}\n","import PropTypes from 'prop-types';\nimport chainPropTypes from '../chainPropTypes';\nfunction isClassComponent(elementType) {\n // elementType.prototype?.isReactComponent\n const {\n prototype = {}\n } = elementType;\n return Boolean(prototype.isReactComponent);\n}\nfunction acceptingRef(props, propName, componentName, location, propFullName) {\n const element = props[propName];\n const safePropName = propFullName || propName;\n if (element == null ||\n // When server-side rendering React doesn't warn either.\n // This is not an accurate check for SSR.\n // This is only in place for Emotion compat.\n // TODO: Revisit once https://github.com/facebook/react/issues/20047 is resolved.\n typeof window === 'undefined') {\n return null;\n }\n let warningHint;\n const elementType = element.type;\n /**\n * Blacklisting instead of whitelisting\n *\n * Blacklisting will miss some components, such as React.Fragment. Those will at least\n * trigger a warning in React.\n * We can't whitelist because there is no safe way to detect React.forwardRef\n * or class components. \"Safe\" means there's no public API.\n *\n */\n if (typeof elementType === 'function' && !isClassComponent(elementType)) {\n warningHint = 'Did you accidentally use a plain function component for an element instead?';\n }\n if (warningHint !== undefined) {\n return new Error(`Invalid ${location} \\`${safePropName}\\` supplied to \\`${componentName}\\`. ` + `Expected an element that can hold a ref. ${warningHint} ` + 'For more information see https://mui.com/r/caveat-with-refs-guide');\n }\n return null;\n}\nconst elementAcceptingRef = chainPropTypes(PropTypes.element, acceptingRef);\nelementAcceptingRef.isRequired = chainPropTypes(PropTypes.element.isRequired, acceptingRef);\nexport default elementAcceptingRef;","import _extends from \"@babel/runtime/helpers/esm/extends\";\n// This module is based on https://github.com/airbnb/prop-types-exact repository.\n// However, in order to reduce the number of dependencies and to remove some extra safe checks\n// the module was forked.\n\nconst specialProperty = 'exact-prop: \\u200b';\nexport default function exactProp(propTypes) {\n if (process.env.NODE_ENV === 'production') {\n return propTypes;\n }\n return _extends({}, propTypes, {\n [specialProperty]: props => {\n const unsupportedProps = Object.keys(props).filter(prop => !propTypes.hasOwnProperty(prop));\n if (unsupportedProps.length > 0) {\n return new Error(`The following props are not supported: ${unsupportedProps.map(prop => `\\`${prop}\\``).join(', ')}. Please remove them.`);\n }\n return null;\n }\n });\n}","/**\n * WARNING: Don't import this directly.\n * Use `MuiError` from `@mui/internal-babel-macros/MuiError.macro` instead.\n * @param {number} code\n */\nexport default function formatMuiErrorMessage(code) {\n // Apply babel-plugin-transform-template-literals in loose mode\n // loose mode is safe if we're concatenating primitives\n // see https://babeljs.io/docs/en/babel-plugin-transform-template-literals#loose\n /* eslint-disable prefer-template */\n let url = 'https://mui.com/production-error/?code=' + code;\n for (let i = 1; i < arguments.length; i += 1) {\n // rest params over-transpile for this case\n // eslint-disable-next-line prefer-rest-params\n url += '&args[]=' + encodeURIComponent(arguments[i]);\n }\n return 'Minified MUI error #' + code + '; visit ' + url + ' for the full message.';\n /* eslint-enable prefer-template */\n}","/**\n * @license React\n * react-is.production.min.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n'use strict';var b=Symbol.for(\"react.element\"),c=Symbol.for(\"react.portal\"),d=Symbol.for(\"react.fragment\"),e=Symbol.for(\"react.strict_mode\"),f=Symbol.for(\"react.profiler\"),g=Symbol.for(\"react.provider\"),h=Symbol.for(\"react.context\"),k=Symbol.for(\"react.server_context\"),l=Symbol.for(\"react.forward_ref\"),m=Symbol.for(\"react.suspense\"),n=Symbol.for(\"react.suspense_list\"),p=Symbol.for(\"react.memo\"),q=Symbol.for(\"react.lazy\"),t=Symbol.for(\"react.offscreen\"),u;u=Symbol.for(\"react.module.reference\");\nfunction v(a){if(\"object\"===typeof a&&null!==a){var r=a.$$typeof;switch(r){case b:switch(a=a.type,a){case d:case f:case e:case m:case n:return a;default:switch(a=a&&a.$$typeof,a){case k:case h:case l:case q:case p:case g:return a;default:return r}}case c:return r}}}exports.ContextConsumer=h;exports.ContextProvider=g;exports.Element=b;exports.ForwardRef=l;exports.Fragment=d;exports.Lazy=q;exports.Memo=p;exports.Portal=c;exports.Profiler=f;exports.StrictMode=e;exports.Suspense=m;\nexports.SuspenseList=n;exports.isAsyncMode=function(){return!1};exports.isConcurrentMode=function(){return!1};exports.isContextConsumer=function(a){return v(a)===h};exports.isContextProvider=function(a){return v(a)===g};exports.isElement=function(a){return\"object\"===typeof a&&null!==a&&a.$$typeof===b};exports.isForwardRef=function(a){return v(a)===l};exports.isFragment=function(a){return v(a)===d};exports.isLazy=function(a){return v(a)===q};exports.isMemo=function(a){return v(a)===p};\nexports.isPortal=function(a){return v(a)===c};exports.isProfiler=function(a){return v(a)===f};exports.isStrictMode=function(a){return v(a)===e};exports.isSuspense=function(a){return v(a)===m};exports.isSuspenseList=function(a){return v(a)===n};\nexports.isValidElementType=function(a){return\"string\"===typeof a||\"function\"===typeof a||a===d||a===f||a===e||a===m||a===n||a===t||\"object\"===typeof a&&null!==a&&(a.$$typeof===q||a.$$typeof===p||a.$$typeof===g||a.$$typeof===h||a.$$typeof===l||a.$$typeof===u||void 0!==a.getModuleId)?!0:!1};exports.typeOf=v;\n","/**\n * @license React\n * react-is.development.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nif (process.env.NODE_ENV !== \"production\") {\n (function() {\n'use strict';\n\n// ATTENTION\n// When adding new symbols to this file,\n// Please consider also adding to 'react-devtools-shared/src/backend/ReactSymbols'\n// The Symbol used to tag the ReactElement-like types.\nvar REACT_ELEMENT_TYPE = Symbol.for('react.element');\nvar REACT_PORTAL_TYPE = Symbol.for('react.portal');\nvar REACT_FRAGMENT_TYPE = Symbol.for('react.fragment');\nvar REACT_STRICT_MODE_TYPE = Symbol.for('react.strict_mode');\nvar REACT_PROFILER_TYPE = Symbol.for('react.profiler');\nvar REACT_PROVIDER_TYPE = Symbol.for('react.provider');\nvar REACT_CONTEXT_TYPE = Symbol.for('react.context');\nvar REACT_SERVER_CONTEXT_TYPE = Symbol.for('react.server_context');\nvar REACT_FORWARD_REF_TYPE = Symbol.for('react.forward_ref');\nvar REACT_SUSPENSE_TYPE = Symbol.for('react.suspense');\nvar REACT_SUSPENSE_LIST_TYPE = Symbol.for('react.suspense_list');\nvar REACT_MEMO_TYPE = Symbol.for('react.memo');\nvar REACT_LAZY_TYPE = Symbol.for('react.lazy');\nvar REACT_OFFSCREEN_TYPE = Symbol.for('react.offscreen');\n\n// -----------------------------------------------------------------------------\n\nvar enableScopeAPI = false; // Experimental Create Event Handle API.\nvar enableCacheElement = false;\nvar enableTransitionTracing = false; // No known bugs, but needs performance testing\n\nvar enableLegacyHidden = false; // Enables unstable_avoidThisFallback feature in Fiber\n// stuff. Intended to enable React core members to more easily debug scheduling\n// issues in DEV builds.\n\nvar enableDebugTracing = false; // Track which Fiber(s) schedule render work.\n\nvar REACT_MODULE_REFERENCE;\n\n{\n REACT_MODULE_REFERENCE = Symbol.for('react.module.reference');\n}\n\nfunction isValidElementType(type) {\n if (typeof type === 'string' || typeof type === 'function') {\n return true;\n } // Note: typeof might be other than 'symbol' or 'number' (e.g. if it's a polyfill).\n\n\n if (type === REACT_FRAGMENT_TYPE || type === REACT_PROFILER_TYPE || enableDebugTracing || type === REACT_STRICT_MODE_TYPE || type === REACT_SUSPENSE_TYPE || type === REACT_SUSPENSE_LIST_TYPE || enableLegacyHidden || type === REACT_OFFSCREEN_TYPE || enableScopeAPI || enableCacheElement || enableTransitionTracing ) {\n return true;\n }\n\n if (typeof type === 'object' && type !== null) {\n if (type.$$typeof === REACT_LAZY_TYPE || type.$$typeof === REACT_MEMO_TYPE || type.$$typeof === REACT_PROVIDER_TYPE || type.$$typeof === REACT_CONTEXT_TYPE || type.$$typeof === REACT_FORWARD_REF_TYPE || // This needs to include all possible module reference object\n // types supported by any Flight configuration anywhere since\n // we don't know which Flight build this will end up being used\n // with.\n type.$$typeof === REACT_MODULE_REFERENCE || type.getModuleId !== undefined) {\n return true;\n }\n }\n\n return false;\n}\n\nfunction typeOf(object) {\n if (typeof object === 'object' && object !== null) {\n var $$typeof = object.$$typeof;\n\n switch ($$typeof) {\n case REACT_ELEMENT_TYPE:\n var type = object.type;\n\n switch (type) {\n case REACT_FRAGMENT_TYPE:\n case REACT_PROFILER_TYPE:\n case REACT_STRICT_MODE_TYPE:\n case REACT_SUSPENSE_TYPE:\n case REACT_SUSPENSE_LIST_TYPE:\n return type;\n\n default:\n var $$typeofType = type && type.$$typeof;\n\n switch ($$typeofType) {\n case REACT_SERVER_CONTEXT_TYPE:\n case REACT_CONTEXT_TYPE:\n case REACT_FORWARD_REF_TYPE:\n case REACT_LAZY_TYPE:\n case REACT_MEMO_TYPE:\n case REACT_PROVIDER_TYPE:\n return $$typeofType;\n\n default:\n return $$typeof;\n }\n\n }\n\n case REACT_PORTAL_TYPE:\n return $$typeof;\n }\n }\n\n return undefined;\n}\nvar ContextConsumer = REACT_CONTEXT_TYPE;\nvar ContextProvider = REACT_PROVIDER_TYPE;\nvar Element = REACT_ELEMENT_TYPE;\nvar ForwardRef = REACT_FORWARD_REF_TYPE;\nvar Fragment = REACT_FRAGMENT_TYPE;\nvar Lazy = REACT_LAZY_TYPE;\nvar Memo = REACT_MEMO_TYPE;\nvar Portal = REACT_PORTAL_TYPE;\nvar Profiler = REACT_PROFILER_TYPE;\nvar StrictMode = REACT_STRICT_MODE_TYPE;\nvar Suspense = REACT_SUSPENSE_TYPE;\nvar SuspenseList = REACT_SUSPENSE_LIST_TYPE;\nvar hasWarnedAboutDeprecatedIsAsyncMode = false;\nvar hasWarnedAboutDeprecatedIsConcurrentMode = false; // AsyncMode should be deprecated\n\nfunction isAsyncMode(object) {\n {\n if (!hasWarnedAboutDeprecatedIsAsyncMode) {\n hasWarnedAboutDeprecatedIsAsyncMode = true; // Using console['warn'] to evade Babel and ESLint\n\n console['warn']('The ReactIs.isAsyncMode() alias has been deprecated, ' + 'and will be removed in React 18+.');\n }\n }\n\n return false;\n}\nfunction isConcurrentMode(object) {\n {\n if (!hasWarnedAboutDeprecatedIsConcurrentMode) {\n hasWarnedAboutDeprecatedIsConcurrentMode = true; // Using console['warn'] to evade Babel and ESLint\n\n console['warn']('The ReactIs.isConcurrentMode() alias has been deprecated, ' + 'and will be removed in React 18+.');\n }\n }\n\n return false;\n}\nfunction isContextConsumer(object) {\n return typeOf(object) === REACT_CONTEXT_TYPE;\n}\nfunction isContextProvider(object) {\n return typeOf(object) === REACT_PROVIDER_TYPE;\n}\nfunction isElement(object) {\n return typeof object === 'object' && object !== null && object.$$typeof === REACT_ELEMENT_TYPE;\n}\nfunction isForwardRef(object) {\n return typeOf(object) === REACT_FORWARD_REF_TYPE;\n}\nfunction isFragment(object) {\n return typeOf(object) === REACT_FRAGMENT_TYPE;\n}\nfunction isLazy(object) {\n return typeOf(object) === REACT_LAZY_TYPE;\n}\nfunction isMemo(object) {\n return typeOf(object) === REACT_MEMO_TYPE;\n}\nfunction isPortal(object) {\n return typeOf(object) === REACT_PORTAL_TYPE;\n}\nfunction isProfiler(object) {\n return typeOf(object) === REACT_PROFILER_TYPE;\n}\nfunction isStrictMode(object) {\n return typeOf(object) === REACT_STRICT_MODE_TYPE;\n}\nfunction isSuspense(object) {\n return typeOf(object) === REACT_SUSPENSE_TYPE;\n}\nfunction isSuspenseList(object) {\n return typeOf(object) === REACT_SUSPENSE_LIST_TYPE;\n}\n\nexports.ContextConsumer = ContextConsumer;\nexports.ContextProvider = ContextProvider;\nexports.Element = Element;\nexports.ForwardRef = ForwardRef;\nexports.Fragment = Fragment;\nexports.Lazy = Lazy;\nexports.Memo = Memo;\nexports.Portal = Portal;\nexports.Profiler = Profiler;\nexports.StrictMode = StrictMode;\nexports.Suspense = Suspense;\nexports.SuspenseList = SuspenseList;\nexports.isAsyncMode = isAsyncMode;\nexports.isConcurrentMode = isConcurrentMode;\nexports.isContextConsumer = isContextConsumer;\nexports.isContextProvider = isContextProvider;\nexports.isElement = isElement;\nexports.isForwardRef = isForwardRef;\nexports.isFragment = isFragment;\nexports.isLazy = isLazy;\nexports.isMemo = isMemo;\nexports.isPortal = isPortal;\nexports.isProfiler = isProfiler;\nexports.isStrictMode = isStrictMode;\nexports.isSuspense = isSuspense;\nexports.isSuspenseList = isSuspenseList;\nexports.isValidElementType = isValidElementType;\nexports.typeOf = typeOf;\n })();\n}\n","'use strict';\n\nif (process.env.NODE_ENV === 'production') {\n module.exports = require('./cjs/react-is.production.min.js');\n} else {\n module.exports = require('./cjs/react-is.development.js');\n}\n","import { ForwardRef, Memo } from 'react-is';\n\n// Simplified polyfill for IE11 support\n// https://github.com/JamesMGreene/Function.name/blob/58b314d4a983110c3682f1228f845d39ccca1817/Function.name.js#L3\nconst fnNameMatchRegex = /^\\s*function(?:\\s|\\s*\\/\\*.*\\*\\/\\s*)+([^(\\s/]*)\\s*/;\nexport function getFunctionName(fn) {\n const match = `${fn}`.match(fnNameMatchRegex);\n const name = match && match[1];\n return name || '';\n}\nfunction getFunctionComponentName(Component, fallback = '') {\n return Component.displayName || Component.name || getFunctionName(Component) || fallback;\n}\nfunction getWrappedName(outerType, innerType, wrapperName) {\n const functionName = getFunctionComponentName(innerType);\n return outerType.displayName || (functionName !== '' ? `${wrapperName}(${functionName})` : wrapperName);\n}\n\n/**\n * cherry-pick from\n * https://github.com/facebook/react/blob/769b1f270e1251d9dbdce0fcbd9e92e502d059b8/packages/shared/getComponentName.js\n * originally forked from recompose/getDisplayName with added IE11 support\n */\nexport default function getDisplayName(Component) {\n if (Component == null) {\n return undefined;\n }\n if (typeof Component === 'string') {\n return Component;\n }\n if (typeof Component === 'function') {\n return getFunctionComponentName(Component, 'Component');\n }\n\n // TypeScript can't have components as objects but they exist in the form of `memo` or `Suspense`\n if (typeof Component === 'object') {\n switch (Component.$$typeof) {\n case ForwardRef:\n return getWrappedName(Component, Component.render, 'ForwardRef');\n case Memo:\n return getWrappedName(Component, Component.type, 'memo');\n default:\n return undefined;\n }\n }\n return undefined;\n}","export default function HTMLElementType(props, propName, componentName, location, propFullName) {\n if (process.env.NODE_ENV === 'production') {\n return null;\n }\n const propValue = props[propName];\n const safePropName = propFullName || propName;\n if (propValue == null) {\n return null;\n }\n if (propValue && propValue.nodeType !== 1) {\n return new Error(`Invalid ${location} \\`${safePropName}\\` supplied to \\`${componentName}\\`. ` + `Expected an HTMLElement.`);\n }\n return null;\n}","import PropTypes from 'prop-types';\nconst refType = PropTypes.oneOfType([PropTypes.func, PropTypes.object]);\nexport default refType;","import _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\n// It should to be noted that this function isn't equivalent to `text-transform: capitalize`.\n//\n// A strict capitalization should uppercase the first letter of each word in the sentence.\n// We only handle the first word.\nexport default function capitalize(string) {\n if (typeof string !== 'string') {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: \\`capitalize(string)\\` expects a string argument.` : _formatMuiErrorMessage(7));\n }\n return string.charAt(0).toUpperCase() + string.slice(1);\n}","/**\n * Safe chained function.\n *\n * Will only create a new function if needed,\n * otherwise will pass back existing functions or null.\n */\nexport default function createChainedFunction(...funcs) {\n return funcs.reduce((acc, func) => {\n if (func == null) {\n return acc;\n }\n return function chainedFunction(...args) {\n acc.apply(this, args);\n func.apply(this, args);\n };\n }, () => {});\n}","// Corresponds to 10 frames at 60 Hz.\n// A few bytes payload overhead when lodash/debounce is ~3 kB and debounce ~300 B.\nexport default function debounce(func, wait = 166) {\n let timeout;\n function debounced(...args) {\n const later = () => {\n // @ts-ignore\n func.apply(this, args);\n };\n clearTimeout(timeout);\n timeout = setTimeout(later, wait);\n }\n debounced.clear = () => {\n clearTimeout(timeout);\n };\n return debounced;\n}","export default function deprecatedPropType(validator, reason) {\n if (process.env.NODE_ENV === 'production') {\n return () => null;\n }\n return (props, propName, componentName, location, propFullName) => {\n const componentNameSafe = componentName || '<>';\n const propFullNameSafe = propFullName || propName;\n if (typeof props[propName] !== 'undefined') {\n return new Error(`The ${location} \\`${propFullNameSafe}\\` of ` + `\\`${componentNameSafe}\\` is deprecated. ${reason}`);\n }\n return null;\n };\n}","import * as React from 'react';\nexport default function isMuiElement(element, muiNames) {\n var _muiName, _element$type;\n return /*#__PURE__*/React.isValidElement(element) && muiNames.indexOf( // For server components `muiName` is avaialble in element.type._payload.value.muiName\n // relevant info - https://github.com/facebook/react/blob/2807d781a08db8e9873687fccc25c0f12b4fb3d4/packages/react/src/ReactLazy.js#L45\n // eslint-disable-next-line no-underscore-dangle\n (_muiName = element.type.muiName) != null ? _muiName : (_element$type = element.type) == null || (_element$type = _element$type._payload) == null || (_element$type = _element$type.value) == null ? void 0 : _element$type.muiName) !== -1;\n}","export default function ownerDocument(node) {\n return node && node.ownerDocument || document;\n}","import ownerDocument from '../ownerDocument';\nexport default function ownerWindow(node) {\n const doc = ownerDocument(node);\n return doc.defaultView || window;\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nexport default function requirePropFactory(componentNameInError, Component) {\n if (process.env.NODE_ENV === 'production') {\n return () => null;\n }\n\n // eslint-disable-next-line react/forbid-foreign-prop-types\n const prevPropTypes = Component ? _extends({}, Component.propTypes) : null;\n const requireProp = requiredProp => (props, propName, componentName, location, propFullName, ...args) => {\n const propFullNameSafe = propFullName || propName;\n const defaultTypeChecker = prevPropTypes == null ? void 0 : prevPropTypes[propFullNameSafe];\n if (defaultTypeChecker) {\n const typeCheckerResult = defaultTypeChecker(props, propName, componentName, location, propFullName, ...args);\n if (typeCheckerResult) {\n return typeCheckerResult;\n }\n }\n if (typeof props[propName] !== 'undefined' && !props[requiredProp]) {\n return new Error(`The prop \\`${propFullNameSafe}\\` of ` + `\\`${componentNameInError}\\` can only be used together with the \\`${requiredProp}\\` prop.`);\n }\n return null;\n };\n return requireProp;\n}","/**\n * TODO v5: consider making it private\n *\n * passes {value} to {ref}\n *\n * WARNING: Be sure to only call this inside a callback that is passed as a ref.\n * Otherwise, make sure to cleanup the previous {ref} if it changes. See\n * https://github.com/mui/material-ui/issues/13539\n *\n * Useful if you want to expose the ref of an inner component to the public API\n * while still using it inside the component.\n * @param ref A ref callback or ref object. If anything falsy, this is a no-op.\n */\nexport default function setRef(ref, value) {\n if (typeof ref === 'function') {\n ref(value);\n } else if (ref) {\n ref.current = value;\n }\n}","'use client';\n\nimport * as React from 'react';\n\n/**\n * A version of `React.useLayoutEffect` that does not show a warning when server-side rendering.\n * This is useful for effects that are only needed for client-side rendering but not for SSR.\n *\n * Before you use this hook, make sure to read https://gist.github.com/gaearon/e7d97cdf38a2907924ea12e4ebdf3c85\n * and confirm it doesn't apply to your use-case.\n */\nconst useEnhancedEffect = typeof window !== 'undefined' ? React.useLayoutEffect : React.useEffect;\nexport default useEnhancedEffect;","'use client';\n\nimport * as React from 'react';\nlet globalId = 0;\nfunction useGlobalId(idOverride) {\n const [defaultId, setDefaultId] = React.useState(idOverride);\n const id = idOverride || defaultId;\n React.useEffect(() => {\n if (defaultId == null) {\n // Fallback to this default id when possible.\n // Use the incrementing value for client-side rendering only.\n // We can't use it server-side.\n // If you want to use random values please consider the Birthday Problem: https://en.wikipedia.org/wiki/Birthday_problem\n globalId += 1;\n setDefaultId(`mui-${globalId}`);\n }\n }, [defaultId]);\n return id;\n}\n\n// downstream bundlers may remove unnecessary concatenation, but won't remove toString call -- Workaround for https://github.com/webpack/webpack/issues/14814\nconst maybeReactUseId = React['useId'.toString()];\n/**\n *\n * @example
    \n * @param idOverride\n * @returns {string}\n */\nexport default function useId(idOverride) {\n if (maybeReactUseId !== undefined) {\n const reactId = maybeReactUseId();\n return idOverride != null ? idOverride : reactId;\n }\n // eslint-disable-next-line react-hooks/rules-of-hooks -- `React.useId` is invariant at runtime.\n return useGlobalId(idOverride);\n}","export default function unsupportedProp(props, propName, componentName, location, propFullName) {\n if (process.env.NODE_ENV === 'production') {\n return null;\n }\n const propFullNameSafe = propFullName || propName;\n if (typeof props[propName] !== 'undefined') {\n return new Error(`The prop \\`${propFullNameSafe}\\` is not supported. Please remove it.`);\n }\n return null;\n}","'use client';\n\n/* eslint-disable react-hooks/rules-of-hooks, react-hooks/exhaustive-deps */\nimport * as React from 'react';\nexport default function useControlled({\n controlled,\n default: defaultProp,\n name,\n state = 'value'\n}) {\n // isControlled is ignored in the hook dependency lists as it should never change.\n const {\n current: isControlled\n } = React.useRef(controlled !== undefined);\n const [valueState, setValue] = React.useState(defaultProp);\n const value = isControlled ? controlled : valueState;\n if (process.env.NODE_ENV !== 'production') {\n React.useEffect(() => {\n if (isControlled !== (controlled !== undefined)) {\n console.error([`MUI: A component is changing the ${isControlled ? '' : 'un'}controlled ${state} state of ${name} to be ${isControlled ? 'un' : ''}controlled.`, 'Elements should not switch from uncontrolled to controlled (or vice versa).', `Decide between using a controlled or uncontrolled ${name} ` + 'element for the lifetime of the component.', \"The nature of the state is determined during the first render. It's considered controlled if the value is not `undefined`.\", 'More info: https://fb.me/react-controlled-components'].join('\\n'));\n }\n }, [state, name, controlled]);\n const {\n current: defaultValue\n } = React.useRef(defaultProp);\n React.useEffect(() => {\n if (!isControlled && defaultValue !== defaultProp) {\n console.error([`MUI: A component is changing the default ${state} state of an uncontrolled ${name} after being initialized. ` + `To suppress this warning opt to use a controlled ${name}.`].join('\\n'));\n }\n }, [JSON.stringify(defaultProp)]);\n }\n const setValueIfUncontrolled = React.useCallback(newValue => {\n if (!isControlled) {\n setValue(newValue);\n }\n }, []);\n return [value, setValueIfUncontrolled];\n}","'use client';\n\nimport * as React from 'react';\nimport useEnhancedEffect from '../useEnhancedEffect';\n\n/**\n * Inspired by https://github.com/facebook/react/issues/14099#issuecomment-440013892\n * See RFC in https://github.com/reactjs/rfcs/pull/220\n */\n\nfunction useEventCallback(fn) {\n const ref = React.useRef(fn);\n useEnhancedEffect(() => {\n ref.current = fn;\n });\n return React.useRef((...args) =>\n // @ts-expect-error hide `this`\n (0, ref.current)(...args)).current;\n}\nexport default useEventCallback;","'use client';\n\nimport * as React from 'react';\nimport setRef from '../setRef';\nexport default function useForkRef(...refs) {\n /**\n * This will create a new function if the refs passed to this hook change and are all defined.\n * This means react will call the old forkRef with `null` and the new forkRef\n * with the ref. Cleanup naturally emerges from this behavior.\n */\n return React.useMemo(() => {\n if (refs.every(ref => ref == null)) {\n return null;\n }\n return instance => {\n refs.forEach(ref => {\n setRef(ref, instance);\n });\n };\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, refs);\n}","'use client';\n\nimport * as React from 'react';\nconst UNINITIALIZED = {};\n\n/**\n * A React.useRef() that is initialized lazily with a function. Note that it accepts an optional\n * initialization argument, so the initialization function doesn't need to be an inline closure.\n *\n * @usage\n * const ref = useLazyRef(sortColumns, columns)\n */\nexport default function useLazyRef(init, initArg) {\n const ref = React.useRef(UNINITIALIZED);\n if (ref.current === UNINITIALIZED) {\n ref.current = init(initArg);\n }\n return ref;\n}","'use client';\n\nimport * as React from 'react';\nconst EMPTY = [];\n\n/**\n * A React.useEffect equivalent that runs once, when the component is mounted.\n */\nexport default function useOnMount(fn) {\n /* eslint-disable react-hooks/exhaustive-deps */\n React.useEffect(fn, EMPTY);\n /* eslint-enable react-hooks/exhaustive-deps */\n}","'use client';\n\nimport useLazyRef from '../useLazyRef/useLazyRef';\nimport useOnMount from '../useOnMount/useOnMount';\nexport class Timeout {\n constructor() {\n this.currentId = null;\n this.clear = () => {\n if (this.currentId !== null) {\n clearTimeout(this.currentId);\n this.currentId = null;\n }\n };\n this.disposeEffect = () => {\n return this.clear;\n };\n }\n static create() {\n return new Timeout();\n }\n /**\n * Executes `fn` after `delay`, clearing any previously scheduled call.\n */\n start(delay, fn) {\n this.clear();\n this.currentId = setTimeout(() => {\n this.currentId = null;\n fn();\n }, delay);\n }\n}\nexport default function useTimeout() {\n const timeout = useLazyRef(Timeout.create).current;\n useOnMount(timeout.disposeEffect);\n return timeout;\n}","'use client';\n\n// based on https://github.com/WICG/focus-visible/blob/v4.1.5/src/focus-visible.js\nimport * as React from 'react';\nimport { Timeout } from '../useTimeout/useTimeout';\nlet hadKeyboardEvent = true;\nlet hadFocusVisibleRecently = false;\nconst hadFocusVisibleRecentlyTimeout = new Timeout();\nconst inputTypesWhitelist = {\n text: true,\n search: true,\n url: true,\n tel: true,\n email: true,\n password: true,\n number: true,\n date: true,\n month: true,\n week: true,\n time: true,\n datetime: true,\n 'datetime-local': true\n};\n\n/**\n * Computes whether the given element should automatically trigger the\n * `focus-visible` class being added, i.e. whether it should always match\n * `:focus-visible` when focused.\n * @param {Element} node\n * @returns {boolean}\n */\nfunction focusTriggersKeyboardModality(node) {\n const {\n type,\n tagName\n } = node;\n if (tagName === 'INPUT' && inputTypesWhitelist[type] && !node.readOnly) {\n return true;\n }\n if (tagName === 'TEXTAREA' && !node.readOnly) {\n return true;\n }\n if (node.isContentEditable) {\n return true;\n }\n return false;\n}\n\n/**\n * Keep track of our keyboard modality state with `hadKeyboardEvent`.\n * If the most recent user interaction was via the keyboard;\n * and the key press did not include a meta, alt/option, or control key;\n * then the modality is keyboard. Otherwise, the modality is not keyboard.\n * @param {KeyboardEvent} event\n */\nfunction handleKeyDown(event) {\n if (event.metaKey || event.altKey || event.ctrlKey) {\n return;\n }\n hadKeyboardEvent = true;\n}\n\n/**\n * If at any point a user clicks with a pointing device, ensure that we change\n * the modality away from keyboard.\n * This avoids the situation where a user presses a key on an already focused\n * element, and then clicks on a different element, focusing it with a\n * pointing device, while we still think we're in keyboard modality.\n */\nfunction handlePointerDown() {\n hadKeyboardEvent = false;\n}\nfunction handleVisibilityChange() {\n if (this.visibilityState === 'hidden') {\n // If the tab becomes active again, the browser will handle calling focus\n // on the element (Safari actually calls it twice).\n // If this tab change caused a blur on an element with focus-visible,\n // re-apply the class when the user switches back to the tab.\n if (hadFocusVisibleRecently) {\n hadKeyboardEvent = true;\n }\n }\n}\nfunction prepare(doc) {\n doc.addEventListener('keydown', handleKeyDown, true);\n doc.addEventListener('mousedown', handlePointerDown, true);\n doc.addEventListener('pointerdown', handlePointerDown, true);\n doc.addEventListener('touchstart', handlePointerDown, true);\n doc.addEventListener('visibilitychange', handleVisibilityChange, true);\n}\nexport function teardown(doc) {\n doc.removeEventListener('keydown', handleKeyDown, true);\n doc.removeEventListener('mousedown', handlePointerDown, true);\n doc.removeEventListener('pointerdown', handlePointerDown, true);\n doc.removeEventListener('touchstart', handlePointerDown, true);\n doc.removeEventListener('visibilitychange', handleVisibilityChange, true);\n}\nfunction isFocusVisible(event) {\n const {\n target\n } = event;\n try {\n return target.matches(':focus-visible');\n } catch (error) {\n // Browsers not implementing :focus-visible will throw a SyntaxError.\n // We use our own heuristic for those browsers.\n // Rethrow might be better if it's not the expected error but do we really\n // want to crash if focus-visible malfunctioned?\n }\n\n // No need for validFocusTarget check. The user does that by attaching it to\n // focusable events only.\n return hadKeyboardEvent || focusTriggersKeyboardModality(target);\n}\nexport default function useIsFocusVisible() {\n const ref = React.useCallback(node => {\n if (node != null) {\n prepare(node.ownerDocument);\n }\n }, []);\n const isFocusVisibleRef = React.useRef(false);\n\n /**\n * Should be called if a blur event is fired\n */\n function handleBlurVisible() {\n // checking against potential state variable does not suffice if we focus and blur synchronously.\n // React wouldn't have time to trigger a re-render so `focusVisible` would be stale.\n // Ideally we would adjust `isFocusVisible(event)` to look at `relatedTarget` for blur events.\n // This doesn't work in IE11 due to https://github.com/facebook/react/issues/3751\n // TODO: check again if React releases their internal changes to focus event handling (https://github.com/facebook/react/pull/19186).\n if (isFocusVisibleRef.current) {\n // To detect a tab/window switch, we look for a blur event followed\n // rapidly by a visibility change.\n // If we don't see a visibility change within 100ms, it's probably a\n // regular focus change.\n hadFocusVisibleRecently = true;\n hadFocusVisibleRecentlyTimeout.start(100, () => {\n hadFocusVisibleRecently = false;\n });\n isFocusVisibleRef.current = false;\n return true;\n }\n return false;\n }\n\n /**\n * Should be called if a blur event is fired\n */\n function handleFocusVisible(event) {\n if (isFocusVisible(event)) {\n isFocusVisibleRef.current = true;\n return true;\n }\n return false;\n }\n return {\n isFocusVisibleRef,\n onFocus: handleFocusVisible,\n onBlur: handleBlurVisible,\n ref\n };\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\n/**\n * Add keys, values of `defaultProps` that does not exist in `props`\n * @param {object} defaultProps\n * @param {object} props\n * @returns {object} resolved props\n */\nexport default function resolveProps(defaultProps, props) {\n const output = _extends({}, props);\n Object.keys(defaultProps).forEach(propName => {\n if (propName.toString().match(/^(components|slots)$/)) {\n output[propName] = _extends({}, defaultProps[propName], output[propName]);\n } else if (propName.toString().match(/^(componentsProps|slotProps)$/)) {\n const defaultSlotProps = defaultProps[propName] || {};\n const slotProps = props[propName];\n output[propName] = {};\n if (!slotProps || !Object.keys(slotProps)) {\n // Reduce the iteration if the slot props is empty\n output[propName] = defaultSlotProps;\n } else if (!defaultSlotProps || !Object.keys(defaultSlotProps)) {\n // Reduce the iteration if the default slot props is empty\n output[propName] = slotProps;\n } else {\n output[propName] = _extends({}, slotProps);\n Object.keys(defaultSlotProps).forEach(slotPropName => {\n output[propName][slotPropName] = resolveProps(defaultSlotProps[slotPropName], slotProps[slotPropName]);\n });\n }\n } else if (output[propName] === undefined) {\n output[propName] = defaultProps[propName];\n }\n });\n return output;\n}","export default function composeClasses(slots, getUtilityClass, classes = undefined) {\n const output = {};\n Object.keys(slots).forEach(\n // `Object.keys(slots)` can't be wider than `T` because we infer `T` from `slots`.\n // @ts-expect-error https://github.com/microsoft/TypeScript/pull/12253#issuecomment-263132208\n slot => {\n output[slot] = slots[slot].reduce((acc, key) => {\n if (key) {\n const utilityClass = getUtilityClass(key);\n if (utilityClass !== '') {\n acc.push(utilityClass);\n }\n if (classes && classes[key]) {\n acc.push(classes[key]);\n }\n }\n return acc;\n }, []).join(' ');\n });\n return output;\n}","const defaultGenerator = componentName => componentName;\nconst createClassNameGenerator = () => {\n let generate = defaultGenerator;\n return {\n configure(generator) {\n generate = generator;\n },\n generate(componentName) {\n return generate(componentName);\n },\n reset() {\n generate = defaultGenerator;\n }\n };\n};\nconst ClassNameGenerator = createClassNameGenerator();\nexport default ClassNameGenerator;","import ClassNameGenerator from '../ClassNameGenerator';\nexport const globalStateClasses = {\n active: 'active',\n checked: 'checked',\n completed: 'completed',\n disabled: 'disabled',\n error: 'error',\n expanded: 'expanded',\n focused: 'focused',\n focusVisible: 'focusVisible',\n open: 'open',\n readOnly: 'readOnly',\n required: 'required',\n selected: 'selected'\n};\nexport default function generateUtilityClass(componentName, slot, globalStatePrefix = 'Mui') {\n const globalStateClass = globalStateClasses[slot];\n return globalStateClass ? `${globalStatePrefix}-${globalStateClass}` : `${ClassNameGenerator.generate(componentName)}-${slot}`;\n}\nexport function isGlobalState(slot) {\n return globalStateClasses[slot] !== undefined;\n}","import generateUtilityClass from '../generateUtilityClass';\nexport default function generateUtilityClasses(componentName, slots, globalStatePrefix = 'Mui') {\n const result = {};\n slots.forEach(slot => {\n result[slot] = generateUtilityClass(componentName, slot, globalStatePrefix);\n });\n return result;\n}","function clamp(val, min = Number.MIN_SAFE_INTEGER, max = Number.MAX_SAFE_INTEGER) {\n return Math.max(min, Math.min(val, max));\n}\nexport default clamp;","export default function _objectWithoutPropertiesLoose(source, excluded) {\n if (source == null) return {};\n var target = {};\n var sourceKeys = Object.keys(source);\n var key, i;\n for (i = 0; i < sourceKeys.length; i++) {\n key = sourceKeys[i];\n if (excluded.indexOf(key) >= 0) continue;\n target[key] = source[key];\n }\n return target;\n}","import _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nconst _excluded = [\"values\", \"unit\", \"step\"];\n// Sorted ASC by size. That's important.\n// It can't be configured as it's used statically for propTypes.\nexport const breakpointKeys = ['xs', 'sm', 'md', 'lg', 'xl'];\nconst sortBreakpointsValues = values => {\n const breakpointsAsArray = Object.keys(values).map(key => ({\n key,\n val: values[key]\n })) || [];\n // Sort in ascending order\n breakpointsAsArray.sort((breakpoint1, breakpoint2) => breakpoint1.val - breakpoint2.val);\n return breakpointsAsArray.reduce((acc, obj) => {\n return _extends({}, acc, {\n [obj.key]: obj.val\n });\n }, {});\n};\n\n// Keep in mind that @media is inclusive by the CSS specification.\nexport default function createBreakpoints(breakpoints) {\n const {\n // The breakpoint **start** at this value.\n // For instance with the first breakpoint xs: [xs, sm).\n values = {\n xs: 0,\n // phone\n sm: 600,\n // tablet\n md: 900,\n // small laptop\n lg: 1200,\n // desktop\n xl: 1536 // large screen\n },\n unit = 'px',\n step = 5\n } = breakpoints,\n other = _objectWithoutPropertiesLoose(breakpoints, _excluded);\n const sortedValues = sortBreakpointsValues(values);\n const keys = Object.keys(sortedValues);\n function up(key) {\n const value = typeof values[key] === 'number' ? values[key] : key;\n return `@media (min-width:${value}${unit})`;\n }\n function down(key) {\n const value = typeof values[key] === 'number' ? values[key] : key;\n return `@media (max-width:${value - step / 100}${unit})`;\n }\n function between(start, end) {\n const endIndex = keys.indexOf(end);\n return `@media (min-width:${typeof values[start] === 'number' ? values[start] : start}${unit}) and ` + `(max-width:${(endIndex !== -1 && typeof values[keys[endIndex]] === 'number' ? values[keys[endIndex]] : end) - step / 100}${unit})`;\n }\n function only(key) {\n if (keys.indexOf(key) + 1 < keys.length) {\n return between(key, keys[keys.indexOf(key) + 1]);\n }\n return up(key);\n }\n function not(key) {\n // handle first and last key separately, for better readability\n const keyIndex = keys.indexOf(key);\n if (keyIndex === 0) {\n return up(keys[1]);\n }\n if (keyIndex === keys.length - 1) {\n return down(keys[keyIndex]);\n }\n return between(key, keys[keys.indexOf(key) + 1]).replace('@media', '@media not all and');\n }\n return _extends({\n keys,\n values: sortedValues,\n up,\n down,\n between,\n only,\n not,\n unit\n }, other);\n}","const shape = {\n borderRadius: 4\n};\nexport default shape;","import PropTypes from 'prop-types';\nconst responsivePropType = process.env.NODE_ENV !== 'production' ? PropTypes.oneOfType([PropTypes.number, PropTypes.string, PropTypes.object, PropTypes.array]) : {};\nexport default responsivePropType;","import deepmerge from '@mui/utils/deepmerge';\nfunction merge(acc, item) {\n if (!item) {\n return acc;\n }\n return deepmerge(acc, item, {\n clone: false // No need to clone deep, it's way faster.\n });\n}\nexport default merge;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport PropTypes from 'prop-types';\nimport deepmerge from '@mui/utils/deepmerge';\nimport merge from './merge';\n\n// The breakpoint **start** at this value.\n// For instance with the first breakpoint xs: [xs, sm[.\nexport const values = {\n xs: 0,\n // phone\n sm: 600,\n // tablet\n md: 900,\n // small laptop\n lg: 1200,\n // desktop\n xl: 1536 // large screen\n};\nconst defaultBreakpoints = {\n // Sorted ASC by size. That's important.\n // It can't be configured as it's used statically for propTypes.\n keys: ['xs', 'sm', 'md', 'lg', 'xl'],\n up: key => `@media (min-width:${values[key]}px)`\n};\nexport function handleBreakpoints(props, propValue, styleFromPropValue) {\n const theme = props.theme || {};\n if (Array.isArray(propValue)) {\n const themeBreakpoints = theme.breakpoints || defaultBreakpoints;\n return propValue.reduce((acc, item, index) => {\n acc[themeBreakpoints.up(themeBreakpoints.keys[index])] = styleFromPropValue(propValue[index]);\n return acc;\n }, {});\n }\n if (typeof propValue === 'object') {\n const themeBreakpoints = theme.breakpoints || defaultBreakpoints;\n return Object.keys(propValue).reduce((acc, breakpoint) => {\n // key is breakpoint\n if (Object.keys(themeBreakpoints.values || values).indexOf(breakpoint) !== -1) {\n const mediaKey = themeBreakpoints.up(breakpoint);\n acc[mediaKey] = styleFromPropValue(propValue[breakpoint], breakpoint);\n } else {\n const cssKey = breakpoint;\n acc[cssKey] = propValue[cssKey];\n }\n return acc;\n }, {});\n }\n const output = styleFromPropValue(propValue);\n return output;\n}\nfunction breakpoints(styleFunction) {\n // false positive\n // eslint-disable-next-line react/function-component-definition\n const newStyleFunction = props => {\n const theme = props.theme || {};\n const base = styleFunction(props);\n const themeBreakpoints = theme.breakpoints || defaultBreakpoints;\n const extended = themeBreakpoints.keys.reduce((acc, key) => {\n if (props[key]) {\n acc = acc || {};\n acc[themeBreakpoints.up(key)] = styleFunction(_extends({\n theme\n }, props[key]));\n }\n return acc;\n }, null);\n return merge(base, extended);\n };\n newStyleFunction.propTypes = process.env.NODE_ENV !== 'production' ? _extends({}, styleFunction.propTypes, {\n xs: PropTypes.object,\n sm: PropTypes.object,\n md: PropTypes.object,\n lg: PropTypes.object,\n xl: PropTypes.object\n }) : {};\n newStyleFunction.filterProps = ['xs', 'sm', 'md', 'lg', 'xl', ...styleFunction.filterProps];\n return newStyleFunction;\n}\nexport function createEmptyBreakpointObject(breakpointsInput = {}) {\n var _breakpointsInput$key;\n const breakpointsInOrder = (_breakpointsInput$key = breakpointsInput.keys) == null ? void 0 : _breakpointsInput$key.reduce((acc, key) => {\n const breakpointStyleKey = breakpointsInput.up(key);\n acc[breakpointStyleKey] = {};\n return acc;\n }, {});\n return breakpointsInOrder || {};\n}\nexport function removeUnusedBreakpoints(breakpointKeys, style) {\n return breakpointKeys.reduce((acc, key) => {\n const breakpointOutput = acc[key];\n const isBreakpointUnused = !breakpointOutput || Object.keys(breakpointOutput).length === 0;\n if (isBreakpointUnused) {\n delete acc[key];\n }\n return acc;\n }, style);\n}\nexport function mergeBreakpointsInOrder(breakpointsInput, ...styles) {\n const emptyBreakpoints = createEmptyBreakpointObject(breakpointsInput);\n const mergedOutput = [emptyBreakpoints, ...styles].reduce((prev, next) => deepmerge(prev, next), {});\n return removeUnusedBreakpoints(Object.keys(emptyBreakpoints), mergedOutput);\n}\n\n// compute base for responsive values; e.g.,\n// [1,2,3] => {xs: true, sm: true, md: true}\n// {xs: 1, sm: 2, md: 3} => {xs: true, sm: true, md: true}\nexport function computeBreakpointsBase(breakpointValues, themeBreakpoints) {\n // fixed value\n if (typeof breakpointValues !== 'object') {\n return {};\n }\n const base = {};\n const breakpointsKeys = Object.keys(themeBreakpoints);\n if (Array.isArray(breakpointValues)) {\n breakpointsKeys.forEach((breakpoint, i) => {\n if (i < breakpointValues.length) {\n base[breakpoint] = true;\n }\n });\n } else {\n breakpointsKeys.forEach(breakpoint => {\n if (breakpointValues[breakpoint] != null) {\n base[breakpoint] = true;\n }\n });\n }\n return base;\n}\nexport function resolveBreakpointValues({\n values: breakpointValues,\n breakpoints: themeBreakpoints,\n base: customBase\n}) {\n const base = customBase || computeBreakpointsBase(breakpointValues, themeBreakpoints);\n const keys = Object.keys(base);\n if (keys.length === 0) {\n return breakpointValues;\n }\n let previous;\n return keys.reduce((acc, breakpoint, i) => {\n if (Array.isArray(breakpointValues)) {\n acc[breakpoint] = breakpointValues[i] != null ? breakpointValues[i] : breakpointValues[previous];\n previous = i;\n } else if (typeof breakpointValues === 'object') {\n acc[breakpoint] = breakpointValues[breakpoint] != null ? breakpointValues[breakpoint] : breakpointValues[previous];\n previous = breakpoint;\n } else {\n acc[breakpoint] = breakpointValues;\n }\n return acc;\n }, {});\n}\nexport default breakpoints;","import capitalize from '@mui/utils/capitalize';\nimport responsivePropType from './responsivePropType';\nimport { handleBreakpoints } from './breakpoints';\nexport function getPath(obj, path, checkVars = true) {\n if (!path || typeof path !== 'string') {\n return null;\n }\n\n // Check if CSS variables are used\n if (obj && obj.vars && checkVars) {\n const val = `vars.${path}`.split('.').reduce((acc, item) => acc && acc[item] ? acc[item] : null, obj);\n if (val != null) {\n return val;\n }\n }\n return path.split('.').reduce((acc, item) => {\n if (acc && acc[item] != null) {\n return acc[item];\n }\n return null;\n }, obj);\n}\nexport function getStyleValue(themeMapping, transform, propValueFinal, userValue = propValueFinal) {\n let value;\n if (typeof themeMapping === 'function') {\n value = themeMapping(propValueFinal);\n } else if (Array.isArray(themeMapping)) {\n value = themeMapping[propValueFinal] || userValue;\n } else {\n value = getPath(themeMapping, propValueFinal) || userValue;\n }\n if (transform) {\n value = transform(value, userValue, themeMapping);\n }\n return value;\n}\nfunction style(options) {\n const {\n prop,\n cssProperty = options.prop,\n themeKey,\n transform\n } = options;\n\n // false positive\n // eslint-disable-next-line react/function-component-definition\n const fn = props => {\n if (props[prop] == null) {\n return null;\n }\n const propValue = props[prop];\n const theme = props.theme;\n const themeMapping = getPath(theme, themeKey) || {};\n const styleFromPropValue = propValueFinal => {\n let value = getStyleValue(themeMapping, transform, propValueFinal);\n if (propValueFinal === value && typeof propValueFinal === 'string') {\n // Haven't found value\n value = getStyleValue(themeMapping, transform, `${prop}${propValueFinal === 'default' ? '' : capitalize(propValueFinal)}`, propValueFinal);\n }\n if (cssProperty === false) {\n return value;\n }\n return {\n [cssProperty]: value\n };\n };\n return handleBreakpoints(props, propValue, styleFromPropValue);\n };\n fn.propTypes = process.env.NODE_ENV !== 'production' ? {\n [prop]: responsivePropType\n } : {};\n fn.filterProps = [prop];\n return fn;\n}\nexport default style;","export default function memoize(fn) {\n const cache = {};\n return arg => {\n if (cache[arg] === undefined) {\n cache[arg] = fn(arg);\n }\n return cache[arg];\n };\n}","import responsivePropType from './responsivePropType';\nimport { handleBreakpoints } from './breakpoints';\nimport { getPath } from './style';\nimport merge from './merge';\nimport memoize from './memoize';\nconst properties = {\n m: 'margin',\n p: 'padding'\n};\nconst directions = {\n t: 'Top',\n r: 'Right',\n b: 'Bottom',\n l: 'Left',\n x: ['Left', 'Right'],\n y: ['Top', 'Bottom']\n};\nconst aliases = {\n marginX: 'mx',\n marginY: 'my',\n paddingX: 'px',\n paddingY: 'py'\n};\n\n// memoize() impact:\n// From 300,000 ops/sec\n// To 350,000 ops/sec\nconst getCssProperties = memoize(prop => {\n // It's not a shorthand notation.\n if (prop.length > 2) {\n if (aliases[prop]) {\n prop = aliases[prop];\n } else {\n return [prop];\n }\n }\n const [a, b] = prop.split('');\n const property = properties[a];\n const direction = directions[b] || '';\n return Array.isArray(direction) ? direction.map(dir => property + dir) : [property + direction];\n});\nexport const marginKeys = ['m', 'mt', 'mr', 'mb', 'ml', 'mx', 'my', 'margin', 'marginTop', 'marginRight', 'marginBottom', 'marginLeft', 'marginX', 'marginY', 'marginInline', 'marginInlineStart', 'marginInlineEnd', 'marginBlock', 'marginBlockStart', 'marginBlockEnd'];\nexport const paddingKeys = ['p', 'pt', 'pr', 'pb', 'pl', 'px', 'py', 'padding', 'paddingTop', 'paddingRight', 'paddingBottom', 'paddingLeft', 'paddingX', 'paddingY', 'paddingInline', 'paddingInlineStart', 'paddingInlineEnd', 'paddingBlock', 'paddingBlockStart', 'paddingBlockEnd'];\nconst spacingKeys = [...marginKeys, ...paddingKeys];\nexport function createUnaryUnit(theme, themeKey, defaultValue, propName) {\n var _getPath;\n const themeSpacing = (_getPath = getPath(theme, themeKey, false)) != null ? _getPath : defaultValue;\n if (typeof themeSpacing === 'number') {\n return abs => {\n if (typeof abs === 'string') {\n return abs;\n }\n if (process.env.NODE_ENV !== 'production') {\n if (typeof abs !== 'number') {\n console.error(`MUI: Expected ${propName} argument to be a number or a string, got ${abs}.`);\n }\n }\n return themeSpacing * abs;\n };\n }\n if (Array.isArray(themeSpacing)) {\n return abs => {\n if (typeof abs === 'string') {\n return abs;\n }\n if (process.env.NODE_ENV !== 'production') {\n if (!Number.isInteger(abs)) {\n console.error([`MUI: The \\`theme.${themeKey}\\` array type cannot be combined with non integer values.` + `You should either use an integer value that can be used as index, or define the \\`theme.${themeKey}\\` as a number.`].join('\\n'));\n } else if (abs > themeSpacing.length - 1) {\n console.error([`MUI: The value provided (${abs}) overflows.`, `The supported values are: ${JSON.stringify(themeSpacing)}.`, `${abs} > ${themeSpacing.length - 1}, you need to add the missing values.`].join('\\n'));\n }\n }\n return themeSpacing[abs];\n };\n }\n if (typeof themeSpacing === 'function') {\n return themeSpacing;\n }\n if (process.env.NODE_ENV !== 'production') {\n console.error([`MUI: The \\`theme.${themeKey}\\` value (${themeSpacing}) is invalid.`, 'It should be a number, an array or a function.'].join('\\n'));\n }\n return () => undefined;\n}\nexport function createUnarySpacing(theme) {\n return createUnaryUnit(theme, 'spacing', 8, 'spacing');\n}\nexport function getValue(transformer, propValue) {\n if (typeof propValue === 'string' || propValue == null) {\n return propValue;\n }\n const abs = Math.abs(propValue);\n const transformed = transformer(abs);\n if (propValue >= 0) {\n return transformed;\n }\n if (typeof transformed === 'number') {\n return -transformed;\n }\n return `-${transformed}`;\n}\nexport function getStyleFromPropValue(cssProperties, transformer) {\n return propValue => cssProperties.reduce((acc, cssProperty) => {\n acc[cssProperty] = getValue(transformer, propValue);\n return acc;\n }, {});\n}\nfunction resolveCssProperty(props, keys, prop, transformer) {\n // Using a hash computation over an array iteration could be faster, but with only 28 items,\n // it's doesn't worth the bundle size.\n if (keys.indexOf(prop) === -1) {\n return null;\n }\n const cssProperties = getCssProperties(prop);\n const styleFromPropValue = getStyleFromPropValue(cssProperties, transformer);\n const propValue = props[prop];\n return handleBreakpoints(props, propValue, styleFromPropValue);\n}\nfunction style(props, keys) {\n const transformer = createUnarySpacing(props.theme);\n return Object.keys(props).map(prop => resolveCssProperty(props, keys, prop, transformer)).reduce(merge, {});\n}\nexport function margin(props) {\n return style(props, marginKeys);\n}\nmargin.propTypes = process.env.NODE_ENV !== 'production' ? marginKeys.reduce((obj, key) => {\n obj[key] = responsivePropType;\n return obj;\n}, {}) : {};\nmargin.filterProps = marginKeys;\nexport function padding(props) {\n return style(props, paddingKeys);\n}\npadding.propTypes = process.env.NODE_ENV !== 'production' ? paddingKeys.reduce((obj, key) => {\n obj[key] = responsivePropType;\n return obj;\n}, {}) : {};\npadding.filterProps = paddingKeys;\nfunction spacing(props) {\n return style(props, spacingKeys);\n}\nspacing.propTypes = process.env.NODE_ENV !== 'production' ? spacingKeys.reduce((obj, key) => {\n obj[key] = responsivePropType;\n return obj;\n}, {}) : {};\nspacing.filterProps = spacingKeys;\nexport default spacing;","import { createUnarySpacing } from '../spacing';\n\n// The different signatures imply different meaning for their arguments that can't be expressed structurally.\n// We express the difference with variable names.\n\nexport default function createSpacing(spacingInput = 8) {\n // Already transformed.\n if (spacingInput.mui) {\n return spacingInput;\n }\n\n // Material Design layouts are visually balanced. Most measurements align to an 8dp grid, which aligns both spacing and the overall layout.\n // Smaller components, such as icons, can align to a 4dp grid.\n // https://m2.material.io/design/layout/understanding-layout.html\n const transform = createUnarySpacing({\n spacing: spacingInput\n });\n const spacing = (...argsInput) => {\n if (process.env.NODE_ENV !== 'production') {\n if (!(argsInput.length <= 4)) {\n console.error(`MUI: Too many arguments provided, expected between 0 and 4, got ${argsInput.length}`);\n }\n }\n const args = argsInput.length === 0 ? [1] : argsInput;\n return args.map(argument => {\n const output = transform(argument);\n return typeof output === 'number' ? `${output}px` : output;\n }).join(' ');\n };\n spacing.mui = true;\n return spacing;\n}","import merge from './merge';\nfunction compose(...styles) {\n const handlers = styles.reduce((acc, style) => {\n style.filterProps.forEach(prop => {\n acc[prop] = style;\n });\n return acc;\n }, {});\n\n // false positive\n // eslint-disable-next-line react/function-component-definition\n const fn = props => {\n return Object.keys(props).reduce((acc, prop) => {\n if (handlers[prop]) {\n return merge(acc, handlers[prop](props));\n }\n return acc;\n }, {});\n };\n fn.propTypes = process.env.NODE_ENV !== 'production' ? styles.reduce((acc, style) => Object.assign(acc, style.propTypes), {}) : {};\n fn.filterProps = styles.reduce((acc, style) => acc.concat(style.filterProps), []);\n return fn;\n}\nexport default compose;","import responsivePropType from './responsivePropType';\nimport style from './style';\nimport compose from './compose';\nimport { createUnaryUnit, getValue } from './spacing';\nimport { handleBreakpoints } from './breakpoints';\nexport function borderTransform(value) {\n if (typeof value !== 'number') {\n return value;\n }\n return `${value}px solid`;\n}\nfunction createBorderStyle(prop, transform) {\n return style({\n prop,\n themeKey: 'borders',\n transform\n });\n}\nexport const border = createBorderStyle('border', borderTransform);\nexport const borderTop = createBorderStyle('borderTop', borderTransform);\nexport const borderRight = createBorderStyle('borderRight', borderTransform);\nexport const borderBottom = createBorderStyle('borderBottom', borderTransform);\nexport const borderLeft = createBorderStyle('borderLeft', borderTransform);\nexport const borderColor = createBorderStyle('borderColor');\nexport const borderTopColor = createBorderStyle('borderTopColor');\nexport const borderRightColor = createBorderStyle('borderRightColor');\nexport const borderBottomColor = createBorderStyle('borderBottomColor');\nexport const borderLeftColor = createBorderStyle('borderLeftColor');\nexport const outline = createBorderStyle('outline', borderTransform);\nexport const outlineColor = createBorderStyle('outlineColor');\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const borderRadius = props => {\n if (props.borderRadius !== undefined && props.borderRadius !== null) {\n const transformer = createUnaryUnit(props.theme, 'shape.borderRadius', 4, 'borderRadius');\n const styleFromPropValue = propValue => ({\n borderRadius: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.borderRadius, styleFromPropValue);\n }\n return null;\n};\nborderRadius.propTypes = process.env.NODE_ENV !== 'production' ? {\n borderRadius: responsivePropType\n} : {};\nborderRadius.filterProps = ['borderRadius'];\nconst borders = compose(border, borderTop, borderRight, borderBottom, borderLeft, borderColor, borderTopColor, borderRightColor, borderBottomColor, borderLeftColor, borderRadius, outline, outlineColor);\nexport default borders;","import style from './style';\nimport compose from './compose';\nimport { createUnaryUnit, getValue } from './spacing';\nimport { handleBreakpoints } from './breakpoints';\nimport responsivePropType from './responsivePropType';\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const gap = props => {\n if (props.gap !== undefined && props.gap !== null) {\n const transformer = createUnaryUnit(props.theme, 'spacing', 8, 'gap');\n const styleFromPropValue = propValue => ({\n gap: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.gap, styleFromPropValue);\n }\n return null;\n};\ngap.propTypes = process.env.NODE_ENV !== 'production' ? {\n gap: responsivePropType\n} : {};\ngap.filterProps = ['gap'];\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const columnGap = props => {\n if (props.columnGap !== undefined && props.columnGap !== null) {\n const transformer = createUnaryUnit(props.theme, 'spacing', 8, 'columnGap');\n const styleFromPropValue = propValue => ({\n columnGap: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.columnGap, styleFromPropValue);\n }\n return null;\n};\ncolumnGap.propTypes = process.env.NODE_ENV !== 'production' ? {\n columnGap: responsivePropType\n} : {};\ncolumnGap.filterProps = ['columnGap'];\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const rowGap = props => {\n if (props.rowGap !== undefined && props.rowGap !== null) {\n const transformer = createUnaryUnit(props.theme, 'spacing', 8, 'rowGap');\n const styleFromPropValue = propValue => ({\n rowGap: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.rowGap, styleFromPropValue);\n }\n return null;\n};\nrowGap.propTypes = process.env.NODE_ENV !== 'production' ? {\n rowGap: responsivePropType\n} : {};\nrowGap.filterProps = ['rowGap'];\nexport const gridColumn = style({\n prop: 'gridColumn'\n});\nexport const gridRow = style({\n prop: 'gridRow'\n});\nexport const gridAutoFlow = style({\n prop: 'gridAutoFlow'\n});\nexport const gridAutoColumns = style({\n prop: 'gridAutoColumns'\n});\nexport const gridAutoRows = style({\n prop: 'gridAutoRows'\n});\nexport const gridTemplateColumns = style({\n prop: 'gridTemplateColumns'\n});\nexport const gridTemplateRows = style({\n prop: 'gridTemplateRows'\n});\nexport const gridTemplateAreas = style({\n prop: 'gridTemplateAreas'\n});\nexport const gridArea = style({\n prop: 'gridArea'\n});\nconst grid = compose(gap, columnGap, rowGap, gridColumn, gridRow, gridAutoFlow, gridAutoColumns, gridAutoRows, gridTemplateColumns, gridTemplateRows, gridTemplateAreas, gridArea);\nexport default grid;","import style from './style';\nimport compose from './compose';\nexport function paletteTransform(value, userValue) {\n if (userValue === 'grey') {\n return userValue;\n }\n return value;\n}\nexport const color = style({\n prop: 'color',\n themeKey: 'palette',\n transform: paletteTransform\n});\nexport const bgcolor = style({\n prop: 'bgcolor',\n cssProperty: 'backgroundColor',\n themeKey: 'palette',\n transform: paletteTransform\n});\nexport const backgroundColor = style({\n prop: 'backgroundColor',\n themeKey: 'palette',\n transform: paletteTransform\n});\nconst palette = compose(color, bgcolor, backgroundColor);\nexport default palette;","import style from './style';\nimport compose from './compose';\nimport { handleBreakpoints, values as breakpointsValues } from './breakpoints';\nexport function sizingTransform(value) {\n return value <= 1 && value !== 0 ? `${value * 100}%` : value;\n}\nexport const width = style({\n prop: 'width',\n transform: sizingTransform\n});\nexport const maxWidth = props => {\n if (props.maxWidth !== undefined && props.maxWidth !== null) {\n const styleFromPropValue = propValue => {\n var _props$theme, _props$theme2;\n const breakpoint = ((_props$theme = props.theme) == null || (_props$theme = _props$theme.breakpoints) == null || (_props$theme = _props$theme.values) == null ? void 0 : _props$theme[propValue]) || breakpointsValues[propValue];\n if (!breakpoint) {\n return {\n maxWidth: sizingTransform(propValue)\n };\n }\n if (((_props$theme2 = props.theme) == null || (_props$theme2 = _props$theme2.breakpoints) == null ? void 0 : _props$theme2.unit) !== 'px') {\n return {\n maxWidth: `${breakpoint}${props.theme.breakpoints.unit}`\n };\n }\n return {\n maxWidth: breakpoint\n };\n };\n return handleBreakpoints(props, props.maxWidth, styleFromPropValue);\n }\n return null;\n};\nmaxWidth.filterProps = ['maxWidth'];\nexport const minWidth = style({\n prop: 'minWidth',\n transform: sizingTransform\n});\nexport const height = style({\n prop: 'height',\n transform: sizingTransform\n});\nexport const maxHeight = style({\n prop: 'maxHeight',\n transform: sizingTransform\n});\nexport const minHeight = style({\n prop: 'minHeight',\n transform: sizingTransform\n});\nexport const sizeWidth = style({\n prop: 'size',\n cssProperty: 'width',\n transform: sizingTransform\n});\nexport const sizeHeight = style({\n prop: 'size',\n cssProperty: 'height',\n transform: sizingTransform\n});\nexport const boxSizing = style({\n prop: 'boxSizing'\n});\nconst sizing = compose(width, maxWidth, minWidth, height, maxHeight, minHeight, boxSizing);\nexport default sizing;","import { padding, margin } from '../spacing';\nimport { borderRadius, borderTransform } from '../borders';\nimport { gap, rowGap, columnGap } from '../cssGrid';\nimport { paletteTransform } from '../palette';\nimport { maxWidth, sizingTransform } from '../sizing';\nconst defaultSxConfig = {\n // borders\n border: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderTop: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderRight: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderBottom: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderLeft: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderColor: {\n themeKey: 'palette'\n },\n borderTopColor: {\n themeKey: 'palette'\n },\n borderRightColor: {\n themeKey: 'palette'\n },\n borderBottomColor: {\n themeKey: 'palette'\n },\n borderLeftColor: {\n themeKey: 'palette'\n },\n outline: {\n themeKey: 'borders',\n transform: borderTransform\n },\n outlineColor: {\n themeKey: 'palette'\n },\n borderRadius: {\n themeKey: 'shape.borderRadius',\n style: borderRadius\n },\n // palette\n color: {\n themeKey: 'palette',\n transform: paletteTransform\n },\n bgcolor: {\n themeKey: 'palette',\n cssProperty: 'backgroundColor',\n transform: paletteTransform\n },\n backgroundColor: {\n themeKey: 'palette',\n transform: paletteTransform\n },\n // spacing\n p: {\n style: padding\n },\n pt: {\n style: padding\n },\n pr: {\n style: padding\n },\n pb: {\n style: padding\n },\n pl: {\n style: padding\n },\n px: {\n style: padding\n },\n py: {\n style: padding\n },\n padding: {\n style: padding\n },\n paddingTop: {\n style: padding\n },\n paddingRight: {\n style: padding\n },\n paddingBottom: {\n style: padding\n },\n paddingLeft: {\n style: padding\n },\n paddingX: {\n style: padding\n },\n paddingY: {\n style: padding\n },\n paddingInline: {\n style: padding\n },\n paddingInlineStart: {\n style: padding\n },\n paddingInlineEnd: {\n style: padding\n },\n paddingBlock: {\n style: padding\n },\n paddingBlockStart: {\n style: padding\n },\n paddingBlockEnd: {\n style: padding\n },\n m: {\n style: margin\n },\n mt: {\n style: margin\n },\n mr: {\n style: margin\n },\n mb: {\n style: margin\n },\n ml: {\n style: margin\n },\n mx: {\n style: margin\n },\n my: {\n style: margin\n },\n margin: {\n style: margin\n },\n marginTop: {\n style: margin\n },\n marginRight: {\n style: margin\n },\n marginBottom: {\n style: margin\n },\n marginLeft: {\n style: margin\n },\n marginX: {\n style: margin\n },\n marginY: {\n style: margin\n },\n marginInline: {\n style: margin\n },\n marginInlineStart: {\n style: margin\n },\n marginInlineEnd: {\n style: margin\n },\n marginBlock: {\n style: margin\n },\n marginBlockStart: {\n style: margin\n },\n marginBlockEnd: {\n style: margin\n },\n // display\n displayPrint: {\n cssProperty: false,\n transform: value => ({\n '@media print': {\n display: value\n }\n })\n },\n display: {},\n overflow: {},\n textOverflow: {},\n visibility: {},\n whiteSpace: {},\n // flexbox\n flexBasis: {},\n flexDirection: {},\n flexWrap: {},\n justifyContent: {},\n alignItems: {},\n alignContent: {},\n order: {},\n flex: {},\n flexGrow: {},\n flexShrink: {},\n alignSelf: {},\n justifyItems: {},\n justifySelf: {},\n // grid\n gap: {\n style: gap\n },\n rowGap: {\n style: rowGap\n },\n columnGap: {\n style: columnGap\n },\n gridColumn: {},\n gridRow: {},\n gridAutoFlow: {},\n gridAutoColumns: {},\n gridAutoRows: {},\n gridTemplateColumns: {},\n gridTemplateRows: {},\n gridTemplateAreas: {},\n gridArea: {},\n // positions\n position: {},\n zIndex: {\n themeKey: 'zIndex'\n },\n top: {},\n right: {},\n bottom: {},\n left: {},\n // shadows\n boxShadow: {\n themeKey: 'shadows'\n },\n // sizing\n width: {\n transform: sizingTransform\n },\n maxWidth: {\n style: maxWidth\n },\n minWidth: {\n transform: sizingTransform\n },\n height: {\n transform: sizingTransform\n },\n maxHeight: {\n transform: sizingTransform\n },\n minHeight: {\n transform: sizingTransform\n },\n boxSizing: {},\n // typography\n fontFamily: {\n themeKey: 'typography'\n },\n fontSize: {\n themeKey: 'typography'\n },\n fontStyle: {\n themeKey: 'typography'\n },\n fontWeight: {\n themeKey: 'typography'\n },\n letterSpacing: {},\n textTransform: {},\n lineHeight: {},\n textAlign: {},\n typography: {\n cssProperty: false,\n themeKey: 'typography'\n }\n};\nexport default defaultSxConfig;","import capitalize from '@mui/utils/capitalize';\nimport merge from '../merge';\nimport { getPath, getStyleValue as getValue } from '../style';\nimport { handleBreakpoints, createEmptyBreakpointObject, removeUnusedBreakpoints } from '../breakpoints';\nimport defaultSxConfig from './defaultSxConfig';\nfunction objectsHaveSameKeys(...objects) {\n const allKeys = objects.reduce((keys, object) => keys.concat(Object.keys(object)), []);\n const union = new Set(allKeys);\n return objects.every(object => union.size === Object.keys(object).length);\n}\nfunction callIfFn(maybeFn, arg) {\n return typeof maybeFn === 'function' ? maybeFn(arg) : maybeFn;\n}\n\n// eslint-disable-next-line @typescript-eslint/naming-convention\nexport function unstable_createStyleFunctionSx() {\n function getThemeValue(prop, val, theme, config) {\n const props = {\n [prop]: val,\n theme\n };\n const options = config[prop];\n if (!options) {\n return {\n [prop]: val\n };\n }\n const {\n cssProperty = prop,\n themeKey,\n transform,\n style\n } = options;\n if (val == null) {\n return null;\n }\n\n // TODO v6: remove, see https://github.com/mui/material-ui/pull/38123\n if (themeKey === 'typography' && val === 'inherit') {\n return {\n [prop]: val\n };\n }\n const themeMapping = getPath(theme, themeKey) || {};\n if (style) {\n return style(props);\n }\n const styleFromPropValue = propValueFinal => {\n let value = getValue(themeMapping, transform, propValueFinal);\n if (propValueFinal === value && typeof propValueFinal === 'string') {\n // Haven't found value\n value = getValue(themeMapping, transform, `${prop}${propValueFinal === 'default' ? '' : capitalize(propValueFinal)}`, propValueFinal);\n }\n if (cssProperty === false) {\n return value;\n }\n return {\n [cssProperty]: value\n };\n };\n return handleBreakpoints(props, val, styleFromPropValue);\n }\n function styleFunctionSx(props) {\n var _theme$unstable_sxCon;\n const {\n sx,\n theme = {}\n } = props || {};\n if (!sx) {\n return null; // Emotion & styled-components will neglect null\n }\n const config = (_theme$unstable_sxCon = theme.unstable_sxConfig) != null ? _theme$unstable_sxCon : defaultSxConfig;\n\n /*\n * Receive `sxInput` as object or callback\n * and then recursively check keys & values to create media query object styles.\n * (the result will be used in `styled`)\n */\n function traverse(sxInput) {\n let sxObject = sxInput;\n if (typeof sxInput === 'function') {\n sxObject = sxInput(theme);\n } else if (typeof sxInput !== 'object') {\n // value\n return sxInput;\n }\n if (!sxObject) {\n return null;\n }\n const emptyBreakpoints = createEmptyBreakpointObject(theme.breakpoints);\n const breakpointsKeys = Object.keys(emptyBreakpoints);\n let css = emptyBreakpoints;\n Object.keys(sxObject).forEach(styleKey => {\n const value = callIfFn(sxObject[styleKey], theme);\n if (value !== null && value !== undefined) {\n if (typeof value === 'object') {\n if (config[styleKey]) {\n css = merge(css, getThemeValue(styleKey, value, theme, config));\n } else {\n const breakpointsValues = handleBreakpoints({\n theme\n }, value, x => ({\n [styleKey]: x\n }));\n if (objectsHaveSameKeys(breakpointsValues, value)) {\n css[styleKey] = styleFunctionSx({\n sx: value,\n theme\n });\n } else {\n css = merge(css, breakpointsValues);\n }\n }\n } else {\n css = merge(css, getThemeValue(styleKey, value, theme, config));\n }\n }\n });\n return removeUnusedBreakpoints(breakpointsKeys, css);\n }\n return Array.isArray(sx) ? sx.map(traverse) : traverse(sx);\n }\n return styleFunctionSx;\n}\nconst styleFunctionSx = unstable_createStyleFunctionSx();\nstyleFunctionSx.filterProps = ['sx'];\nexport default styleFunctionSx;","/**\n * A universal utility to style components with multiple color modes. Always use it from the theme object.\n * It works with:\n * - [Basic theme](https://mui.com/material-ui/customization/dark-mode/)\n * - [CSS theme variables](https://mui.com/material-ui/experimental-api/css-theme-variables/overview/)\n * - Zero-runtime engine\n *\n * Tips: Use an array over object spread and place `theme.applyStyles()` last.\n *\n * ✅ [{ background: '#e5e5e5' }, theme.applyStyles('dark', { background: '#1c1c1c' })]\n *\n * 🚫 { background: '#e5e5e5', ...theme.applyStyles('dark', { background: '#1c1c1c' })}\n *\n * @example\n * 1. using with `styled`:\n * ```jsx\n * const Component = styled('div')(({ theme }) => [\n * { background: '#e5e5e5' },\n * theme.applyStyles('dark', {\n * background: '#1c1c1c',\n * color: '#fff',\n * }),\n * ]);\n * ```\n *\n * @example\n * 2. using with `sx` prop:\n * ```jsx\n * [\n * { background: '#e5e5e5' },\n * theme.applyStyles('dark', {\n * background: '#1c1c1c',\n * color: '#fff',\n * }),\n * ]}\n * />\n * ```\n *\n * @example\n * 3. theming a component:\n * ```jsx\n * extendTheme({\n * components: {\n * MuiButton: {\n * styleOverrides: {\n * root: ({ theme }) => [\n * { background: '#e5e5e5' },\n * theme.applyStyles('dark', {\n * background: '#1c1c1c',\n * color: '#fff',\n * }),\n * ],\n * },\n * }\n * }\n * })\n *```\n */\nexport default function applyStyles(key, styles) {\n // @ts-expect-error this is 'any' type\n const theme = this;\n if (theme.vars && typeof theme.getColorSchemeSelector === 'function') {\n // If CssVarsProvider is used as a provider,\n // returns '* :where([data-mui-color-scheme=\"light|dark\"]) &'\n const selector = theme.getColorSchemeSelector(key).replace(/(\\[[^\\]]+\\])/, '*:where($1)');\n return {\n [selector]: styles\n };\n }\n if (theme.palette.mode === key) {\n return styles;\n }\n return {};\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"breakpoints\", \"palette\", \"spacing\", \"shape\"];\nimport deepmerge from '@mui/utils/deepmerge';\nimport createBreakpoints from './createBreakpoints';\nimport shape from './shape';\nimport createSpacing from './createSpacing';\nimport styleFunctionSx from '../styleFunctionSx/styleFunctionSx';\nimport defaultSxConfig from '../styleFunctionSx/defaultSxConfig';\nimport applyStyles from './applyStyles';\nfunction createTheme(options = {}, ...args) {\n const {\n breakpoints: breakpointsInput = {},\n palette: paletteInput = {},\n spacing: spacingInput,\n shape: shapeInput = {}\n } = options,\n other = _objectWithoutPropertiesLoose(options, _excluded);\n const breakpoints = createBreakpoints(breakpointsInput);\n const spacing = createSpacing(spacingInput);\n let muiTheme = deepmerge({\n breakpoints,\n direction: 'ltr',\n components: {},\n // Inject component definitions.\n palette: _extends({\n mode: 'light'\n }, paletteInput),\n spacing,\n shape: _extends({}, shape, shapeInput)\n }, other);\n muiTheme.applyStyles = applyStyles;\n muiTheme = args.reduce((acc, argument) => deepmerge(acc, argument), muiTheme);\n muiTheme.unstable_sxConfig = _extends({}, defaultSxConfig, other == null ? void 0 : other.unstable_sxConfig);\n muiTheme.unstable_sx = function sx(props) {\n return styleFunctionSx({\n sx: props,\n theme: this\n });\n };\n return muiTheme;\n}\nexport default createTheme;","'use client';\n\nimport * as React from 'react';\nimport { ThemeContext } from '@mui/styled-engine';\nfunction isObjectEmpty(obj) {\n return Object.keys(obj).length === 0;\n}\nfunction useTheme(defaultTheme = null) {\n const contextTheme = React.useContext(ThemeContext);\n return !contextTheme || isObjectEmpty(contextTheme) ? defaultTheme : contextTheme;\n}\nexport default useTheme;","'use client';\n\nimport createTheme from './createTheme';\nimport useThemeWithoutDefault from './useThemeWithoutDefault';\nexport const systemDefaultTheme = createTheme();\nfunction useTheme(defaultTheme = systemDefaultTheme) {\n return useThemeWithoutDefault(defaultTheme);\n}\nexport default useTheme;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"ownerState\"],\n _excluded2 = [\"variants\"],\n _excluded3 = [\"name\", \"slot\", \"skipVariantsResolver\", \"skipSx\", \"overridesResolver\"];\n/* eslint-disable no-underscore-dangle */\nimport styledEngineStyled, { internal_processStyles as processStyles } from '@mui/styled-engine';\nimport { isPlainObject } from '@mui/utils/deepmerge';\nimport capitalize from '@mui/utils/capitalize';\nimport getDisplayName from '@mui/utils/getDisplayName';\nimport createTheme from './createTheme';\nimport styleFunctionSx from './styleFunctionSx';\nfunction isEmpty(obj) {\n return Object.keys(obj).length === 0;\n}\n\n// https://github.com/emotion-js/emotion/blob/26ded6109fcd8ca9875cc2ce4564fee678a3f3c5/packages/styled/src/utils.js#L40\nfunction isStringTag(tag) {\n return typeof tag === 'string' &&\n // 96 is one less than the char code\n // for \"a\" so this is checking that\n // it's a lowercase character\n tag.charCodeAt(0) > 96;\n}\n\n// Update /system/styled/#api in case if this changes\nexport function shouldForwardProp(prop) {\n return prop !== 'ownerState' && prop !== 'theme' && prop !== 'sx' && prop !== 'as';\n}\nexport const systemDefaultTheme = createTheme();\nconst lowercaseFirstLetter = string => {\n if (!string) {\n return string;\n }\n return string.charAt(0).toLowerCase() + string.slice(1);\n};\nfunction resolveTheme({\n defaultTheme,\n theme,\n themeId\n}) {\n return isEmpty(theme) ? defaultTheme : theme[themeId] || theme;\n}\nfunction defaultOverridesResolver(slot) {\n if (!slot) {\n return null;\n }\n return (props, styles) => styles[slot];\n}\nfunction processStyleArg(callableStyle, _ref) {\n let {\n ownerState\n } = _ref,\n props = _objectWithoutPropertiesLoose(_ref, _excluded);\n const resolvedStylesArg = typeof callableStyle === 'function' ? callableStyle(_extends({\n ownerState\n }, props)) : callableStyle;\n if (Array.isArray(resolvedStylesArg)) {\n return resolvedStylesArg.flatMap(resolvedStyle => processStyleArg(resolvedStyle, _extends({\n ownerState\n }, props)));\n }\n if (!!resolvedStylesArg && typeof resolvedStylesArg === 'object' && Array.isArray(resolvedStylesArg.variants)) {\n const {\n variants = []\n } = resolvedStylesArg,\n otherStyles = _objectWithoutPropertiesLoose(resolvedStylesArg, _excluded2);\n let result = otherStyles;\n variants.forEach(variant => {\n let isMatch = true;\n if (typeof variant.props === 'function') {\n isMatch = variant.props(_extends({\n ownerState\n }, props, ownerState));\n } else {\n Object.keys(variant.props).forEach(key => {\n if ((ownerState == null ? void 0 : ownerState[key]) !== variant.props[key] && props[key] !== variant.props[key]) {\n isMatch = false;\n }\n });\n }\n if (isMatch) {\n if (!Array.isArray(result)) {\n result = [result];\n }\n result.push(typeof variant.style === 'function' ? variant.style(_extends({\n ownerState\n }, props, ownerState)) : variant.style);\n }\n });\n return result;\n }\n return resolvedStylesArg;\n}\nexport default function createStyled(input = {}) {\n const {\n themeId,\n defaultTheme = systemDefaultTheme,\n rootShouldForwardProp = shouldForwardProp,\n slotShouldForwardProp = shouldForwardProp\n } = input;\n const systemSx = props => {\n return styleFunctionSx(_extends({}, props, {\n theme: resolveTheme(_extends({}, props, {\n defaultTheme,\n themeId\n }))\n }));\n };\n systemSx.__mui_systemSx = true;\n return (tag, inputOptions = {}) => {\n // Filter out the `sx` style function from the previous styled component to prevent unnecessary styles generated by the composite components.\n processStyles(tag, styles => styles.filter(style => !(style != null && style.__mui_systemSx)));\n const {\n name: componentName,\n slot: componentSlot,\n skipVariantsResolver: inputSkipVariantsResolver,\n skipSx: inputSkipSx,\n // TODO v6: remove `lowercaseFirstLetter()` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n overridesResolver = defaultOverridesResolver(lowercaseFirstLetter(componentSlot))\n } = inputOptions,\n options = _objectWithoutPropertiesLoose(inputOptions, _excluded3);\n\n // if skipVariantsResolver option is defined, take the value, otherwise, true for root and false for other slots.\n const skipVariantsResolver = inputSkipVariantsResolver !== undefined ? inputSkipVariantsResolver :\n // TODO v6: remove `Root` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n componentSlot && componentSlot !== 'Root' && componentSlot !== 'root' || false;\n const skipSx = inputSkipSx || false;\n let label;\n if (process.env.NODE_ENV !== 'production') {\n if (componentName) {\n // TODO v6: remove `lowercaseFirstLetter()` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n label = `${componentName}-${lowercaseFirstLetter(componentSlot || 'Root')}`;\n }\n }\n let shouldForwardPropOption = shouldForwardProp;\n\n // TODO v6: remove `Root` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n if (componentSlot === 'Root' || componentSlot === 'root') {\n shouldForwardPropOption = rootShouldForwardProp;\n } else if (componentSlot) {\n // any other slot specified\n shouldForwardPropOption = slotShouldForwardProp;\n } else if (isStringTag(tag)) {\n // for string (html) tag, preserve the behavior in emotion & styled-components.\n shouldForwardPropOption = undefined;\n }\n const defaultStyledResolver = styledEngineStyled(tag, _extends({\n shouldForwardProp: shouldForwardPropOption,\n label\n }, options));\n const transformStyleArg = stylesArg => {\n // On the server Emotion doesn't use React.forwardRef for creating components, so the created\n // component stays as a function. This condition makes sure that we do not interpolate functions\n // which are basically components used as a selectors.\n if (typeof stylesArg === 'function' && stylesArg.__emotion_real !== stylesArg || isPlainObject(stylesArg)) {\n return props => processStyleArg(stylesArg, _extends({}, props, {\n theme: resolveTheme({\n theme: props.theme,\n defaultTheme,\n themeId\n })\n }));\n }\n return stylesArg;\n };\n const muiStyledResolver = (styleArg, ...expressions) => {\n let transformedStyleArg = transformStyleArg(styleArg);\n const expressionsWithDefaultTheme = expressions ? expressions.map(transformStyleArg) : [];\n if (componentName && overridesResolver) {\n expressionsWithDefaultTheme.push(props => {\n const theme = resolveTheme(_extends({}, props, {\n defaultTheme,\n themeId\n }));\n if (!theme.components || !theme.components[componentName] || !theme.components[componentName].styleOverrides) {\n return null;\n }\n const styleOverrides = theme.components[componentName].styleOverrides;\n const resolvedStyleOverrides = {};\n // TODO: v7 remove iteration and use `resolveStyleArg(styleOverrides[slot])` directly\n Object.entries(styleOverrides).forEach(([slotKey, slotStyle]) => {\n resolvedStyleOverrides[slotKey] = processStyleArg(slotStyle, _extends({}, props, {\n theme\n }));\n });\n return overridesResolver(props, resolvedStyleOverrides);\n });\n }\n if (componentName && !skipVariantsResolver) {\n expressionsWithDefaultTheme.push(props => {\n var _theme$components;\n const theme = resolveTheme(_extends({}, props, {\n defaultTheme,\n themeId\n }));\n const themeVariants = theme == null || (_theme$components = theme.components) == null || (_theme$components = _theme$components[componentName]) == null ? void 0 : _theme$components.variants;\n return processStyleArg({\n variants: themeVariants\n }, _extends({}, props, {\n theme\n }));\n });\n }\n if (!skipSx) {\n expressionsWithDefaultTheme.push(systemSx);\n }\n const numOfCustomFnsApplied = expressionsWithDefaultTheme.length - expressions.length;\n if (Array.isArray(styleArg) && numOfCustomFnsApplied > 0) {\n const placeholders = new Array(numOfCustomFnsApplied).fill('');\n // If the type is array, than we need to add placeholders in the template for the overrides, variants and the sx styles.\n transformedStyleArg = [...styleArg, ...placeholders];\n transformedStyleArg.raw = [...styleArg.raw, ...placeholders];\n }\n const Component = defaultStyledResolver(transformedStyleArg, ...expressionsWithDefaultTheme);\n if (process.env.NODE_ENV !== 'production') {\n let displayName;\n if (componentName) {\n displayName = `${componentName}${capitalize(componentSlot || '')}`;\n }\n if (displayName === undefined) {\n displayName = `Styled(${getDisplayName(tag)})`;\n }\n Component.displayName = displayName;\n }\n if (tag.muiName) {\n Component.muiName = tag.muiName;\n }\n return Component;\n };\n if (defaultStyledResolver.withConfig) {\n muiStyledResolver.withConfig = defaultStyledResolver.withConfig;\n }\n return muiStyledResolver;\n };\n}","import resolveProps from '@mui/utils/resolveProps';\nexport default function getThemeProps(params) {\n const {\n theme,\n name,\n props\n } = params;\n if (!theme || !theme.components || !theme.components[name] || !theme.components[name].defaultProps) {\n return props;\n }\n return resolveProps(theme.components[name].defaultProps, props);\n}","'use client';\n\nimport getThemeProps from './getThemeProps';\nimport useTheme from '../useTheme';\nexport default function useThemeProps({\n props,\n name,\n defaultTheme,\n themeId\n}) {\n let theme = useTheme(defaultTheme);\n if (themeId) {\n theme = theme[themeId] || theme;\n }\n const mergedProps = getThemeProps({\n theme,\n name,\n props\n });\n return mergedProps;\n}","import _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\n/* eslint-disable @typescript-eslint/naming-convention */\nimport clamp from '@mui/utils/clamp';\n/**\n * Returns a number whose value is limited to the given range.\n * @param {number} value The value to be clamped\n * @param {number} min The lower boundary of the output range\n * @param {number} max The upper boundary of the output range\n * @returns {number} A number in the range [min, max]\n */\nfunction clampWrapper(value, min = 0, max = 1) {\n if (process.env.NODE_ENV !== 'production') {\n if (value < min || value > max) {\n console.error(`MUI: The value provided ${value} is out of range [${min}, ${max}].`);\n }\n }\n return clamp(value, min, max);\n}\n\n/**\n * Converts a color from CSS hex format to CSS rgb format.\n * @param {string} color - Hex color, i.e. #nnn or #nnnnnn\n * @returns {string} A CSS rgb color string\n */\nexport function hexToRgb(color) {\n color = color.slice(1);\n const re = new RegExp(`.{1,${color.length >= 6 ? 2 : 1}}`, 'g');\n let colors = color.match(re);\n if (colors && colors[0].length === 1) {\n colors = colors.map(n => n + n);\n }\n return colors ? `rgb${colors.length === 4 ? 'a' : ''}(${colors.map((n, index) => {\n return index < 3 ? parseInt(n, 16) : Math.round(parseInt(n, 16) / 255 * 1000) / 1000;\n }).join(', ')})` : '';\n}\nfunction intToHex(int) {\n const hex = int.toString(16);\n return hex.length === 1 ? `0${hex}` : hex;\n}\n\n/**\n * Returns an object with the type and values of a color.\n *\n * Note: Does not support rgb % values.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @returns {object} - A MUI color object: {type: string, values: number[]}\n */\nexport function decomposeColor(color) {\n // Idempotent\n if (color.type) {\n return color;\n }\n if (color.charAt(0) === '#') {\n return decomposeColor(hexToRgb(color));\n }\n const marker = color.indexOf('(');\n const type = color.substring(0, marker);\n if (['rgb', 'rgba', 'hsl', 'hsla', 'color'].indexOf(type) === -1) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: Unsupported \\`${color}\\` color.\nThe following formats are supported: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color().` : _formatMuiErrorMessage(9, color));\n }\n let values = color.substring(marker + 1, color.length - 1);\n let colorSpace;\n if (type === 'color') {\n values = values.split(' ');\n colorSpace = values.shift();\n if (values.length === 4 && values[3].charAt(0) === '/') {\n values[3] = values[3].slice(1);\n }\n if (['srgb', 'display-p3', 'a98-rgb', 'prophoto-rgb', 'rec-2020'].indexOf(colorSpace) === -1) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: unsupported \\`${colorSpace}\\` color space.\nThe following color spaces are supported: srgb, display-p3, a98-rgb, prophoto-rgb, rec-2020.` : _formatMuiErrorMessage(10, colorSpace));\n }\n } else {\n values = values.split(',');\n }\n values = values.map(value => parseFloat(value));\n return {\n type,\n values,\n colorSpace\n };\n}\n\n/**\n * Returns a channel created from the input color.\n *\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @returns {string} - The channel for the color, that can be used in rgba or hsla colors\n */\nexport const colorChannel = color => {\n const decomposedColor = decomposeColor(color);\n return decomposedColor.values.slice(0, 3).map((val, idx) => decomposedColor.type.indexOf('hsl') !== -1 && idx !== 0 ? `${val}%` : val).join(' ');\n};\nexport const private_safeColorChannel = (color, warning) => {\n try {\n return colorChannel(color);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n};\n\n/**\n * Converts a color object with type and values to a string.\n * @param {object} color - Decomposed color\n * @param {string} color.type - One of: 'rgb', 'rgba', 'hsl', 'hsla', 'color'\n * @param {array} color.values - [n,n,n] or [n,n,n,n]\n * @returns {string} A CSS color string\n */\nexport function recomposeColor(color) {\n const {\n type,\n colorSpace\n } = color;\n let {\n values\n } = color;\n if (type.indexOf('rgb') !== -1) {\n // Only convert the first 3 values to int (i.e. not alpha)\n values = values.map((n, i) => i < 3 ? parseInt(n, 10) : n);\n } else if (type.indexOf('hsl') !== -1) {\n values[1] = `${values[1]}%`;\n values[2] = `${values[2]}%`;\n }\n if (type.indexOf('color') !== -1) {\n values = `${colorSpace} ${values.join(' ')}`;\n } else {\n values = `${values.join(', ')}`;\n }\n return `${type}(${values})`;\n}\n\n/**\n * Converts a color from CSS rgb format to CSS hex format.\n * @param {string} color - RGB color, i.e. rgb(n, n, n)\n * @returns {string} A CSS rgb color string, i.e. #nnnnnn\n */\nexport function rgbToHex(color) {\n // Idempotent\n if (color.indexOf('#') === 0) {\n return color;\n }\n const {\n values\n } = decomposeColor(color);\n return `#${values.map((n, i) => intToHex(i === 3 ? Math.round(255 * n) : n)).join('')}`;\n}\n\n/**\n * Converts a color from hsl format to rgb format.\n * @param {string} color - HSL color values\n * @returns {string} rgb color values\n */\nexport function hslToRgb(color) {\n color = decomposeColor(color);\n const {\n values\n } = color;\n const h = values[0];\n const s = values[1] / 100;\n const l = values[2] / 100;\n const a = s * Math.min(l, 1 - l);\n const f = (n, k = (n + h / 30) % 12) => l - a * Math.max(Math.min(k - 3, 9 - k, 1), -1);\n let type = 'rgb';\n const rgb = [Math.round(f(0) * 255), Math.round(f(8) * 255), Math.round(f(4) * 255)];\n if (color.type === 'hsla') {\n type += 'a';\n rgb.push(values[3]);\n }\n return recomposeColor({\n type,\n values: rgb\n });\n}\n/**\n * The relative brightness of any point in a color space,\n * normalized to 0 for darkest black and 1 for lightest white.\n *\n * Formula: https://www.w3.org/TR/WCAG20-TECHS/G17.html#G17-tests\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @returns {number} The relative brightness of the color in the range 0 - 1\n */\nexport function getLuminance(color) {\n color = decomposeColor(color);\n let rgb = color.type === 'hsl' || color.type === 'hsla' ? decomposeColor(hslToRgb(color)).values : color.values;\n rgb = rgb.map(val => {\n if (color.type !== 'color') {\n val /= 255; // normalized\n }\n return val <= 0.03928 ? val / 12.92 : ((val + 0.055) / 1.055) ** 2.4;\n });\n\n // Truncate at 3 digits\n return Number((0.2126 * rgb[0] + 0.7152 * rgb[1] + 0.0722 * rgb[2]).toFixed(3));\n}\n\n/**\n * Calculates the contrast ratio between two colors.\n *\n * Formula: https://www.w3.org/TR/WCAG20-TECHS/G17.html#G17-tests\n * @param {string} foreground - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla()\n * @param {string} background - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla()\n * @returns {number} A contrast ratio value in the range 0 - 21.\n */\nexport function getContrastRatio(foreground, background) {\n const lumA = getLuminance(foreground);\n const lumB = getLuminance(background);\n return (Math.max(lumA, lumB) + 0.05) / (Math.min(lumA, lumB) + 0.05);\n}\n\n/**\n * Sets the absolute transparency of a color.\n * Any existing alpha values are overwritten.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} value - value to set the alpha channel to in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function alpha(color, value) {\n color = decomposeColor(color);\n value = clampWrapper(value);\n if (color.type === 'rgb' || color.type === 'hsl') {\n color.type += 'a';\n }\n if (color.type === 'color') {\n color.values[3] = `/${value}`;\n } else {\n color.values[3] = value;\n }\n return recomposeColor(color);\n}\nexport function private_safeAlpha(color, value, warning) {\n try {\n return alpha(color, value);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Darkens a color.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} coefficient - multiplier in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function darken(color, coefficient) {\n color = decomposeColor(color);\n coefficient = clampWrapper(coefficient);\n if (color.type.indexOf('hsl') !== -1) {\n color.values[2] *= 1 - coefficient;\n } else if (color.type.indexOf('rgb') !== -1 || color.type.indexOf('color') !== -1) {\n for (let i = 0; i < 3; i += 1) {\n color.values[i] *= 1 - coefficient;\n }\n }\n return recomposeColor(color);\n}\nexport function private_safeDarken(color, coefficient, warning) {\n try {\n return darken(color, coefficient);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Lightens a color.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} coefficient - multiplier in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function lighten(color, coefficient) {\n color = decomposeColor(color);\n coefficient = clampWrapper(coefficient);\n if (color.type.indexOf('hsl') !== -1) {\n color.values[2] += (100 - color.values[2]) * coefficient;\n } else if (color.type.indexOf('rgb') !== -1) {\n for (let i = 0; i < 3; i += 1) {\n color.values[i] += (255 - color.values[i]) * coefficient;\n }\n } else if (color.type.indexOf('color') !== -1) {\n for (let i = 0; i < 3; i += 1) {\n color.values[i] += (1 - color.values[i]) * coefficient;\n }\n }\n return recomposeColor(color);\n}\nexport function private_safeLighten(color, coefficient, warning) {\n try {\n return lighten(color, coefficient);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Darken or lighten a color, depending on its luminance.\n * Light colors are darkened, dark colors are lightened.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} coefficient=0.15 - multiplier in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function emphasize(color, coefficient = 0.15) {\n return getLuminance(color) > 0.5 ? darken(color, coefficient) : lighten(color, coefficient);\n}\nexport function private_safeEmphasize(color, coefficient, warning) {\n try {\n return emphasize(color, coefficient);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Blend a transparent overlay color with a background color, resulting in a single\n * RGB color.\n * @param {string} background - CSS color\n * @param {string} overlay - CSS color\n * @param {number} opacity - Opacity multiplier in the range 0 - 1\n * @param {number} [gamma=1.0] - Gamma correction factor. For gamma-correct blending, 2.2 is usual.\n */\nexport function blend(background, overlay, opacity, gamma = 1.0) {\n const blendChannel = (b, o) => Math.round((b ** (1 / gamma) * (1 - opacity) + o ** (1 / gamma) * opacity) ** gamma);\n const backgroundColor = decomposeColor(background);\n const overlayColor = decomposeColor(overlay);\n const rgb = [blendChannel(backgroundColor.values[0], overlayColor.values[0]), blendChannel(backgroundColor.values[1], overlayColor.values[1]), blendChannel(backgroundColor.values[2], overlayColor.values[2])];\n return recomposeColor({\n type: 'rgb',\n values: rgb\n });\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nexport default function createMixins(breakpoints, mixins) {\n return _extends({\n toolbar: {\n minHeight: 56,\n [breakpoints.up('xs')]: {\n '@media (orientation: landscape)': {\n minHeight: 48\n }\n },\n [breakpoints.up('sm')]: {\n minHeight: 64\n }\n }\n }, mixins);\n}","const common = {\n black: '#000',\n white: '#fff'\n};\nexport default common;","const grey = {\n 50: '#fafafa',\n 100: '#f5f5f5',\n 200: '#eeeeee',\n 300: '#e0e0e0',\n 400: '#bdbdbd',\n 500: '#9e9e9e',\n 600: '#757575',\n 700: '#616161',\n 800: '#424242',\n 900: '#212121',\n A100: '#f5f5f5',\n A200: '#eeeeee',\n A400: '#bdbdbd',\n A700: '#616161'\n};\nexport default grey;","const purple = {\n 50: '#f3e5f5',\n 100: '#e1bee7',\n 200: '#ce93d8',\n 300: '#ba68c8',\n 400: '#ab47bc',\n 500: '#9c27b0',\n 600: '#8e24aa',\n 700: '#7b1fa2',\n 800: '#6a1b9a',\n 900: '#4a148c',\n A100: '#ea80fc',\n A200: '#e040fb',\n A400: '#d500f9',\n A700: '#aa00ff'\n};\nexport default purple;","const red = {\n 50: '#ffebee',\n 100: '#ffcdd2',\n 200: '#ef9a9a',\n 300: '#e57373',\n 400: '#ef5350',\n 500: '#f44336',\n 600: '#e53935',\n 700: '#d32f2f',\n 800: '#c62828',\n 900: '#b71c1c',\n A100: '#ff8a80',\n A200: '#ff5252',\n A400: '#ff1744',\n A700: '#d50000'\n};\nexport default red;","const orange = {\n 50: '#fff3e0',\n 100: '#ffe0b2',\n 200: '#ffcc80',\n 300: '#ffb74d',\n 400: '#ffa726',\n 500: '#ff9800',\n 600: '#fb8c00',\n 700: '#f57c00',\n 800: '#ef6c00',\n 900: '#e65100',\n A100: '#ffd180',\n A200: '#ffab40',\n A400: '#ff9100',\n A700: '#ff6d00'\n};\nexport default orange;","const blue = {\n 50: '#e3f2fd',\n 100: '#bbdefb',\n 200: '#90caf9',\n 300: '#64b5f6',\n 400: '#42a5f5',\n 500: '#2196f3',\n 600: '#1e88e5',\n 700: '#1976d2',\n 800: '#1565c0',\n 900: '#0d47a1',\n A100: '#82b1ff',\n A200: '#448aff',\n A400: '#2979ff',\n A700: '#2962ff'\n};\nexport default blue;","const lightBlue = {\n 50: '#e1f5fe',\n 100: '#b3e5fc',\n 200: '#81d4fa',\n 300: '#4fc3f7',\n 400: '#29b6f6',\n 500: '#03a9f4',\n 600: '#039be5',\n 700: '#0288d1',\n 800: '#0277bd',\n 900: '#01579b',\n A100: '#80d8ff',\n A200: '#40c4ff',\n A400: '#00b0ff',\n A700: '#0091ea'\n};\nexport default lightBlue;","const green = {\n 50: '#e8f5e9',\n 100: '#c8e6c9',\n 200: '#a5d6a7',\n 300: '#81c784',\n 400: '#66bb6a',\n 500: '#4caf50',\n 600: '#43a047',\n 700: '#388e3c',\n 800: '#2e7d32',\n 900: '#1b5e20',\n A100: '#b9f6ca',\n A200: '#69f0ae',\n A400: '#00e676',\n A700: '#00c853'\n};\nexport default green;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\nconst _excluded = [\"mode\", \"contrastThreshold\", \"tonalOffset\"];\nimport { deepmerge } from '@mui/utils';\nimport { darken, getContrastRatio, lighten } from '@mui/system';\nimport common from '../colors/common';\nimport grey from '../colors/grey';\nimport purple from '../colors/purple';\nimport red from '../colors/red';\nimport orange from '../colors/orange';\nimport blue from '../colors/blue';\nimport lightBlue from '../colors/lightBlue';\nimport green from '../colors/green';\nexport const light = {\n // The colors used to style the text.\n text: {\n // The most important text.\n primary: 'rgba(0, 0, 0, 0.87)',\n // Secondary text.\n secondary: 'rgba(0, 0, 0, 0.6)',\n // Disabled text have even lower visual prominence.\n disabled: 'rgba(0, 0, 0, 0.38)'\n },\n // The color used to divide different elements.\n divider: 'rgba(0, 0, 0, 0.12)',\n // The background colors used to style the surfaces.\n // Consistency between these values is important.\n background: {\n paper: common.white,\n default: common.white\n },\n // The colors used to style the action elements.\n action: {\n // The color of an active action like an icon button.\n active: 'rgba(0, 0, 0, 0.54)',\n // The color of an hovered action.\n hover: 'rgba(0, 0, 0, 0.04)',\n hoverOpacity: 0.04,\n // The color of a selected action.\n selected: 'rgba(0, 0, 0, 0.08)',\n selectedOpacity: 0.08,\n // The color of a disabled action.\n disabled: 'rgba(0, 0, 0, 0.26)',\n // The background color of a disabled action.\n disabledBackground: 'rgba(0, 0, 0, 0.12)',\n disabledOpacity: 0.38,\n focus: 'rgba(0, 0, 0, 0.12)',\n focusOpacity: 0.12,\n activatedOpacity: 0.12\n }\n};\nexport const dark = {\n text: {\n primary: common.white,\n secondary: 'rgba(255, 255, 255, 0.7)',\n disabled: 'rgba(255, 255, 255, 0.5)',\n icon: 'rgba(255, 255, 255, 0.5)'\n },\n divider: 'rgba(255, 255, 255, 0.12)',\n background: {\n paper: '#121212',\n default: '#121212'\n },\n action: {\n active: common.white,\n hover: 'rgba(255, 255, 255, 0.08)',\n hoverOpacity: 0.08,\n selected: 'rgba(255, 255, 255, 0.16)',\n selectedOpacity: 0.16,\n disabled: 'rgba(255, 255, 255, 0.3)',\n disabledBackground: 'rgba(255, 255, 255, 0.12)',\n disabledOpacity: 0.38,\n focus: 'rgba(255, 255, 255, 0.12)',\n focusOpacity: 0.12,\n activatedOpacity: 0.24\n }\n};\nfunction addLightOrDark(intent, direction, shade, tonalOffset) {\n const tonalOffsetLight = tonalOffset.light || tonalOffset;\n const tonalOffsetDark = tonalOffset.dark || tonalOffset * 1.5;\n if (!intent[direction]) {\n if (intent.hasOwnProperty(shade)) {\n intent[direction] = intent[shade];\n } else if (direction === 'light') {\n intent.light = lighten(intent.main, tonalOffsetLight);\n } else if (direction === 'dark') {\n intent.dark = darken(intent.main, tonalOffsetDark);\n }\n }\n}\nfunction getDefaultPrimary(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: blue[200],\n light: blue[50],\n dark: blue[400]\n };\n }\n return {\n main: blue[700],\n light: blue[400],\n dark: blue[800]\n };\n}\nfunction getDefaultSecondary(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: purple[200],\n light: purple[50],\n dark: purple[400]\n };\n }\n return {\n main: purple[500],\n light: purple[300],\n dark: purple[700]\n };\n}\nfunction getDefaultError(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: red[500],\n light: red[300],\n dark: red[700]\n };\n }\n return {\n main: red[700],\n light: red[400],\n dark: red[800]\n };\n}\nfunction getDefaultInfo(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: lightBlue[400],\n light: lightBlue[300],\n dark: lightBlue[700]\n };\n }\n return {\n main: lightBlue[700],\n light: lightBlue[500],\n dark: lightBlue[900]\n };\n}\nfunction getDefaultSuccess(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: green[400],\n light: green[300],\n dark: green[700]\n };\n }\n return {\n main: green[800],\n light: green[500],\n dark: green[900]\n };\n}\nfunction getDefaultWarning(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: orange[400],\n light: orange[300],\n dark: orange[700]\n };\n }\n return {\n main: '#ed6c02',\n // closest to orange[800] that pass 3:1.\n light: orange[500],\n dark: orange[900]\n };\n}\nexport default function createPalette(palette) {\n const {\n mode = 'light',\n contrastThreshold = 3,\n tonalOffset = 0.2\n } = palette,\n other = _objectWithoutPropertiesLoose(palette, _excluded);\n const primary = palette.primary || getDefaultPrimary(mode);\n const secondary = palette.secondary || getDefaultSecondary(mode);\n const error = palette.error || getDefaultError(mode);\n const info = palette.info || getDefaultInfo(mode);\n const success = palette.success || getDefaultSuccess(mode);\n const warning = palette.warning || getDefaultWarning(mode);\n\n // Use the same logic as\n // Bootstrap: https://github.com/twbs/bootstrap/blob/1d6e3710dd447de1a200f29e8fa521f8a0908f70/scss/_functions.scss#L59\n // and material-components-web https://github.com/material-components/material-components-web/blob/ac46b8863c4dab9fc22c4c662dc6bd1b65dd652f/packages/mdc-theme/_functions.scss#L54\n function getContrastText(background) {\n const contrastText = getContrastRatio(background, dark.text.primary) >= contrastThreshold ? dark.text.primary : light.text.primary;\n if (process.env.NODE_ENV !== 'production') {\n const contrast = getContrastRatio(background, contrastText);\n if (contrast < 3) {\n console.error([`MUI: The contrast ratio of ${contrast}:1 for ${contrastText} on ${background}`, 'falls below the WCAG recommended absolute minimum contrast ratio of 3:1.', 'https://www.w3.org/TR/2008/REC-WCAG20-20081211/#visual-audio-contrast-contrast'].join('\\n'));\n }\n }\n return contrastText;\n }\n const augmentColor = ({\n color,\n name,\n mainShade = 500,\n lightShade = 300,\n darkShade = 700\n }) => {\n color = _extends({}, color);\n if (!color.main && color[mainShade]) {\n color.main = color[mainShade];\n }\n if (!color.hasOwnProperty('main')) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: The color${name ? ` (${name})` : ''} provided to augmentColor(color) is invalid.\nThe color object needs to have a \\`main\\` property or a \\`${mainShade}\\` property.` : _formatMuiErrorMessage(11, name ? ` (${name})` : '', mainShade));\n }\n if (typeof color.main !== 'string') {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: The color${name ? ` (${name})` : ''} provided to augmentColor(color) is invalid.\n\\`color.main\\` should be a string, but \\`${JSON.stringify(color.main)}\\` was provided instead.\n\nDid you intend to use one of the following approaches?\n\nimport { green } from \"@mui/material/colors\";\n\nconst theme1 = createTheme({ palette: {\n primary: green,\n} });\n\nconst theme2 = createTheme({ palette: {\n primary: { main: green[500] },\n} });` : _formatMuiErrorMessage(12, name ? ` (${name})` : '', JSON.stringify(color.main)));\n }\n addLightOrDark(color, 'light', lightShade, tonalOffset);\n addLightOrDark(color, 'dark', darkShade, tonalOffset);\n if (!color.contrastText) {\n color.contrastText = getContrastText(color.main);\n }\n return color;\n };\n const modes = {\n dark,\n light\n };\n if (process.env.NODE_ENV !== 'production') {\n if (!modes[mode]) {\n console.error(`MUI: The palette mode \\`${mode}\\` is not supported.`);\n }\n }\n const paletteOutput = deepmerge(_extends({\n // A collection of common colors.\n common: _extends({}, common),\n // prevent mutable object.\n // The palette mode, can be light or dark.\n mode,\n // The colors used to represent primary interface elements for a user.\n primary: augmentColor({\n color: primary,\n name: 'primary'\n }),\n // The colors used to represent secondary interface elements for a user.\n secondary: augmentColor({\n color: secondary,\n name: 'secondary',\n mainShade: 'A400',\n lightShade: 'A200',\n darkShade: 'A700'\n }),\n // The colors used to represent interface elements that the user should be made aware of.\n error: augmentColor({\n color: error,\n name: 'error'\n }),\n // The colors used to represent potentially dangerous actions or important messages.\n warning: augmentColor({\n color: warning,\n name: 'warning'\n }),\n // The colors used to present information to the user that is neutral and not necessarily important.\n info: augmentColor({\n color: info,\n name: 'info'\n }),\n // The colors used to indicate the successful completion of an action that user triggered.\n success: augmentColor({\n color: success,\n name: 'success'\n }),\n // The grey colors.\n grey,\n // Used by `getContrastText()` to maximize the contrast between\n // the background and the text.\n contrastThreshold,\n // Takes a background color and returns the text color that maximizes the contrast.\n getContrastText,\n // Generate a rich color object.\n augmentColor,\n // Used by the functions below to shift a color's luminance by approximately\n // two indexes within its tonal palette.\n // E.g., shift from Red 500 to Red 300 or Red 700.\n tonalOffset\n }, modes[mode]), other);\n return paletteOutput;\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"fontFamily\", \"fontSize\", \"fontWeightLight\", \"fontWeightRegular\", \"fontWeightMedium\", \"fontWeightBold\", \"htmlFontSize\", \"allVariants\", \"pxToRem\"];\nimport { deepmerge } from '@mui/utils';\nfunction round(value) {\n return Math.round(value * 1e5) / 1e5;\n}\nconst caseAllCaps = {\n textTransform: 'uppercase'\n};\nconst defaultFontFamily = '\"Roboto\", \"Helvetica\", \"Arial\", sans-serif';\n\n/**\n * @see @link{https://m2.material.io/design/typography/the-type-system.html}\n * @see @link{https://m2.material.io/design/typography/understanding-typography.html}\n */\nexport default function createTypography(palette, typography) {\n const _ref = typeof typography === 'function' ? typography(palette) : typography,\n {\n fontFamily = defaultFontFamily,\n // The default font size of the Material Specification.\n fontSize = 14,\n // px\n fontWeightLight = 300,\n fontWeightRegular = 400,\n fontWeightMedium = 500,\n fontWeightBold = 700,\n // Tell MUI what's the font-size on the html element.\n // 16px is the default font-size used by browsers.\n htmlFontSize = 16,\n // Apply the CSS properties to all the variants.\n allVariants,\n pxToRem: pxToRem2\n } = _ref,\n other = _objectWithoutPropertiesLoose(_ref, _excluded);\n if (process.env.NODE_ENV !== 'production') {\n if (typeof fontSize !== 'number') {\n console.error('MUI: `fontSize` is required to be a number.');\n }\n if (typeof htmlFontSize !== 'number') {\n console.error('MUI: `htmlFontSize` is required to be a number.');\n }\n }\n const coef = fontSize / 14;\n const pxToRem = pxToRem2 || (size => `${size / htmlFontSize * coef}rem`);\n const buildVariant = (fontWeight, size, lineHeight, letterSpacing, casing) => _extends({\n fontFamily,\n fontWeight,\n fontSize: pxToRem(size),\n // Unitless following https://meyerweb.com/eric/thoughts/2006/02/08/unitless-line-heights/\n lineHeight\n }, fontFamily === defaultFontFamily ? {\n letterSpacing: `${round(letterSpacing / size)}em`\n } : {}, casing, allVariants);\n const variants = {\n h1: buildVariant(fontWeightLight, 96, 1.167, -1.5),\n h2: buildVariant(fontWeightLight, 60, 1.2, -0.5),\n h3: buildVariant(fontWeightRegular, 48, 1.167, 0),\n h4: buildVariant(fontWeightRegular, 34, 1.235, 0.25),\n h5: buildVariant(fontWeightRegular, 24, 1.334, 0),\n h6: buildVariant(fontWeightMedium, 20, 1.6, 0.15),\n subtitle1: buildVariant(fontWeightRegular, 16, 1.75, 0.15),\n subtitle2: buildVariant(fontWeightMedium, 14, 1.57, 0.1),\n body1: buildVariant(fontWeightRegular, 16, 1.5, 0.15),\n body2: buildVariant(fontWeightRegular, 14, 1.43, 0.15),\n button: buildVariant(fontWeightMedium, 14, 1.75, 0.4, caseAllCaps),\n caption: buildVariant(fontWeightRegular, 12, 1.66, 0.4),\n overline: buildVariant(fontWeightRegular, 12, 2.66, 1, caseAllCaps),\n // TODO v6: Remove handling of 'inherit' variant from the theme as it is already handled in Material UI's Typography component. Also, remember to remove the associated types.\n inherit: {\n fontFamily: 'inherit',\n fontWeight: 'inherit',\n fontSize: 'inherit',\n lineHeight: 'inherit',\n letterSpacing: 'inherit'\n }\n };\n return deepmerge(_extends({\n htmlFontSize,\n pxToRem,\n fontFamily,\n fontSize,\n fontWeightLight,\n fontWeightRegular,\n fontWeightMedium,\n fontWeightBold\n }, variants), other, {\n clone: false // No need to clone deep\n });\n}","const shadowKeyUmbraOpacity = 0.2;\nconst shadowKeyPenumbraOpacity = 0.14;\nconst shadowAmbientShadowOpacity = 0.12;\nfunction createShadow(...px) {\n return [`${px[0]}px ${px[1]}px ${px[2]}px ${px[3]}px rgba(0,0,0,${shadowKeyUmbraOpacity})`, `${px[4]}px ${px[5]}px ${px[6]}px ${px[7]}px rgba(0,0,0,${shadowKeyPenumbraOpacity})`, `${px[8]}px ${px[9]}px ${px[10]}px ${px[11]}px rgba(0,0,0,${shadowAmbientShadowOpacity})`].join(',');\n}\n\n// Values from https://github.com/material-components/material-components-web/blob/be8747f94574669cb5e7add1a7c54fa41a89cec7/packages/mdc-elevation/_variables.scss\nconst shadows = ['none', createShadow(0, 2, 1, -1, 0, 1, 1, 0, 0, 1, 3, 0), createShadow(0, 3, 1, -2, 0, 2, 2, 0, 0, 1, 5, 0), createShadow(0, 3, 3, -2, 0, 3, 4, 0, 0, 1, 8, 0), createShadow(0, 2, 4, -1, 0, 4, 5, 0, 0, 1, 10, 0), createShadow(0, 3, 5, -1, 0, 5, 8, 0, 0, 1, 14, 0), createShadow(0, 3, 5, -1, 0, 6, 10, 0, 0, 1, 18, 0), createShadow(0, 4, 5, -2, 0, 7, 10, 1, 0, 2, 16, 1), createShadow(0, 5, 5, -3, 0, 8, 10, 1, 0, 3, 14, 2), createShadow(0, 5, 6, -3, 0, 9, 12, 1, 0, 3, 16, 2), createShadow(0, 6, 6, -3, 0, 10, 14, 1, 0, 4, 18, 3), createShadow(0, 6, 7, -4, 0, 11, 15, 1, 0, 4, 20, 3), createShadow(0, 7, 8, -4, 0, 12, 17, 2, 0, 5, 22, 4), createShadow(0, 7, 8, -4, 0, 13, 19, 2, 0, 5, 24, 4), createShadow(0, 7, 9, -4, 0, 14, 21, 2, 0, 5, 26, 4), createShadow(0, 8, 9, -5, 0, 15, 22, 2, 0, 6, 28, 5), createShadow(0, 8, 10, -5, 0, 16, 24, 2, 0, 6, 30, 5), createShadow(0, 8, 11, -5, 0, 17, 26, 2, 0, 6, 32, 5), createShadow(0, 9, 11, -5, 0, 18, 28, 2, 0, 7, 34, 6), createShadow(0, 9, 12, -6, 0, 19, 29, 2, 0, 7, 36, 6), createShadow(0, 10, 13, -6, 0, 20, 31, 3, 0, 8, 38, 7), createShadow(0, 10, 13, -6, 0, 21, 33, 3, 0, 8, 40, 7), createShadow(0, 10, 14, -6, 0, 22, 35, 3, 0, 8, 42, 7), createShadow(0, 11, 14, -7, 0, 23, 36, 3, 0, 9, 44, 8), createShadow(0, 11, 15, -7, 0, 24, 38, 3, 0, 9, 46, 8)];\nexport default shadows;","import _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nconst _excluded = [\"duration\", \"easing\", \"delay\"];\n// Follow https://material.google.com/motion/duration-easing.html#duration-easing-natural-easing-curves\n// to learn the context in which each easing should be used.\nexport const easing = {\n // This is the most common easing curve.\n easeInOut: 'cubic-bezier(0.4, 0, 0.2, 1)',\n // Objects enter the screen at full velocity from off-screen and\n // slowly decelerate to a resting point.\n easeOut: 'cubic-bezier(0.0, 0, 0.2, 1)',\n // Objects leave the screen at full velocity. They do not decelerate when off-screen.\n easeIn: 'cubic-bezier(0.4, 0, 1, 1)',\n // The sharp curve is used by objects that may return to the screen at any time.\n sharp: 'cubic-bezier(0.4, 0, 0.6, 1)'\n};\n\n// Follow https://m2.material.io/guidelines/motion/duration-easing.html#duration-easing-common-durations\n// to learn when use what timing\nexport const duration = {\n shortest: 150,\n shorter: 200,\n short: 250,\n // most basic recommended timing\n standard: 300,\n // this is to be used in complex animations\n complex: 375,\n // recommended when something is entering screen\n enteringScreen: 225,\n // recommended when something is leaving screen\n leavingScreen: 195\n};\nfunction formatMs(milliseconds) {\n return `${Math.round(milliseconds)}ms`;\n}\nfunction getAutoHeightDuration(height) {\n if (!height) {\n return 0;\n }\n const constant = height / 36;\n\n // https://www.wolframalpha.com/input/?i=(4+%2B+15+*+(x+%2F+36+)+**+0.25+%2B+(x+%2F+36)+%2F+5)+*+10\n return Math.round((4 + 15 * constant ** 0.25 + constant / 5) * 10);\n}\nexport default function createTransitions(inputTransitions) {\n const mergedEasing = _extends({}, easing, inputTransitions.easing);\n const mergedDuration = _extends({}, duration, inputTransitions.duration);\n const create = (props = ['all'], options = {}) => {\n const {\n duration: durationOption = mergedDuration.standard,\n easing: easingOption = mergedEasing.easeInOut,\n delay = 0\n } = options,\n other = _objectWithoutPropertiesLoose(options, _excluded);\n if (process.env.NODE_ENV !== 'production') {\n const isString = value => typeof value === 'string';\n // IE11 support, replace with Number.isNaN\n // eslint-disable-next-line no-restricted-globals\n const isNumber = value => !isNaN(parseFloat(value));\n if (!isString(props) && !Array.isArray(props)) {\n console.error('MUI: Argument \"props\" must be a string or Array.');\n }\n if (!isNumber(durationOption) && !isString(durationOption)) {\n console.error(`MUI: Argument \"duration\" must be a number or a string but found ${durationOption}.`);\n }\n if (!isString(easingOption)) {\n console.error('MUI: Argument \"easing\" must be a string.');\n }\n if (!isNumber(delay) && !isString(delay)) {\n console.error('MUI: Argument \"delay\" must be a number or a string.');\n }\n if (typeof options !== 'object') {\n console.error(['MUI: Secong argument of transition.create must be an object.', \"Arguments should be either `create('prop1', options)` or `create(['prop1', 'prop2'], options)`\"].join('\\n'));\n }\n if (Object.keys(other).length !== 0) {\n console.error(`MUI: Unrecognized argument(s) [${Object.keys(other).join(',')}].`);\n }\n }\n return (Array.isArray(props) ? props : [props]).map(animatedProp => `${animatedProp} ${typeof durationOption === 'string' ? durationOption : formatMs(durationOption)} ${easingOption} ${typeof delay === 'string' ? delay : formatMs(delay)}`).join(',');\n };\n return _extends({\n getAutoHeightDuration,\n create\n }, inputTransitions, {\n easing: mergedEasing,\n duration: mergedDuration\n });\n}","// We need to centralize the zIndex definitions as they work\n// like global values in the browser.\nconst zIndex = {\n mobileStepper: 1000,\n fab: 1050,\n speedDial: 1050,\n appBar: 1100,\n drawer: 1200,\n modal: 1300,\n snackbar: 1400,\n tooltip: 1500\n};\nexport default zIndex;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\nconst _excluded = [\"breakpoints\", \"mixins\", \"spacing\", \"palette\", \"transitions\", \"typography\", \"shape\"];\nimport { deepmerge } from '@mui/utils';\nimport { createTheme as systemCreateTheme, unstable_defaultSxConfig as defaultSxConfig, unstable_styleFunctionSx as styleFunctionSx } from '@mui/system';\nimport generateUtilityClass from '@mui/utils/generateUtilityClass';\nimport createMixins from './createMixins';\nimport createPalette from './createPalette';\nimport createTypography from './createTypography';\nimport shadows from './shadows';\nimport createTransitions from './createTransitions';\nimport zIndex from './zIndex';\nfunction createTheme(options = {}, ...args) {\n const {\n mixins: mixinsInput = {},\n palette: paletteInput = {},\n transitions: transitionsInput = {},\n typography: typographyInput = {}\n } = options,\n other = _objectWithoutPropertiesLoose(options, _excluded);\n if (options.vars) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: \\`vars\\` is a private field used for CSS variables support.\nPlease use another name.` : _formatMuiErrorMessage(18));\n }\n const palette = createPalette(paletteInput);\n const systemTheme = systemCreateTheme(options);\n let muiTheme = deepmerge(systemTheme, {\n mixins: createMixins(systemTheme.breakpoints, mixinsInput),\n palette,\n // Don't use [...shadows] until you've verified its transpiled code is not invoking the iterator protocol.\n shadows: shadows.slice(),\n typography: createTypography(palette, typographyInput),\n transitions: createTransitions(transitionsInput),\n zIndex: _extends({}, zIndex)\n });\n muiTheme = deepmerge(muiTheme, other);\n muiTheme = args.reduce((acc, argument) => deepmerge(acc, argument), muiTheme);\n if (process.env.NODE_ENV !== 'production') {\n // TODO v6: Refactor to use globalStateClassesMapping from @mui/utils once `readOnly` state class is used in Rating component.\n const stateClasses = ['active', 'checked', 'completed', 'disabled', 'error', 'expanded', 'focused', 'focusVisible', 'required', 'selected'];\n const traverse = (node, component) => {\n let key;\n\n // eslint-disable-next-line guard-for-in, no-restricted-syntax\n for (key in node) {\n const child = node[key];\n if (stateClasses.indexOf(key) !== -1 && Object.keys(child).length > 0) {\n if (process.env.NODE_ENV !== 'production') {\n const stateClass = generateUtilityClass('', key);\n console.error([`MUI: The \\`${component}\\` component increases ` + `the CSS specificity of the \\`${key}\\` internal state.`, 'You can not override it like this: ', JSON.stringify(node, null, 2), '', `Instead, you need to use the '&.${stateClass}' syntax:`, JSON.stringify({\n root: {\n [`&.${stateClass}`]: child\n }\n }, null, 2), '', 'https://mui.com/r/state-classes-guide'].join('\\n'));\n }\n // Remove the style to prevent global conflicts.\n node[key] = {};\n }\n }\n };\n Object.keys(muiTheme.components).forEach(component => {\n const styleOverrides = muiTheme.components[component].styleOverrides;\n if (styleOverrides && component.indexOf('Mui') === 0) {\n traverse(styleOverrides, component);\n }\n });\n }\n muiTheme.unstable_sxConfig = _extends({}, defaultSxConfig, other == null ? void 0 : other.unstable_sxConfig);\n muiTheme.unstable_sx = function sx(props) {\n return styleFunctionSx({\n sx: props,\n theme: this\n });\n };\n return muiTheme;\n}\nlet warnedOnce = false;\nexport function createMuiTheme(...args) {\n if (process.env.NODE_ENV !== 'production') {\n if (!warnedOnce) {\n warnedOnce = true;\n console.error(['MUI: the createMuiTheme function was renamed to createTheme.', '', \"You should use `import { createTheme } from '@mui/material/styles'`\"].join('\\n'));\n }\n }\n return createTheme(...args);\n}\nexport default createTheme;","'use client';\n\nimport createTheme from './createTheme';\nconst defaultTheme = createTheme();\nexport default defaultTheme;","export default '$$material';","'use client';\n\nimport { useThemeProps as systemUseThemeProps } from '@mui/system';\nimport defaultTheme from './defaultTheme';\nimport THEME_ID from './identifier';\nexport default function useThemeProps({\n props,\n name\n}) {\n return systemUseThemeProps({\n props,\n name,\n defaultTheme,\n themeId: THEME_ID\n });\n}","'use client';\n\nimport { createStyled, shouldForwardProp } from '@mui/system';\nimport defaultTheme from './defaultTheme';\nimport THEME_ID from './identifier';\nexport const rootShouldForwardProp = prop => shouldForwardProp(prop) && prop !== 'classes';\nexport const slotShouldForwardProp = shouldForwardProp;\nconst styled = createStyled({\n themeId: THEME_ID,\n defaultTheme,\n rootShouldForwardProp\n});\nexport default styled;","import generateUtilityClasses from '@mui/utils/generateUtilityClasses';\nimport generateUtilityClass from '@mui/utils/generateUtilityClass';\nexport function getSvgIconUtilityClass(slot) {\n return generateUtilityClass('MuiSvgIcon', slot);\n}\nconst svgIconClasses = generateUtilityClasses('MuiSvgIcon', ['root', 'colorPrimary', 'colorSecondary', 'colorAction', 'colorError', 'colorDisabled', 'fontSizeInherit', 'fontSizeSmall', 'fontSizeMedium', 'fontSizeLarge']);\nexport default svgIconClasses;","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"children\", \"className\", \"color\", \"component\", \"fontSize\", \"htmlColor\", \"inheritViewBox\", \"titleAccess\", \"viewBox\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport clsx from 'clsx';\nimport { unstable_composeClasses as composeClasses } from '@mui/base/composeClasses';\nimport capitalize from '../utils/capitalize';\nimport useThemeProps from '../styles/useThemeProps';\nimport styled from '../styles/styled';\nimport { getSvgIconUtilityClass } from './svgIconClasses';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nimport { jsxs as _jsxs } from \"react/jsx-runtime\";\nconst useUtilityClasses = ownerState => {\n const {\n color,\n fontSize,\n classes\n } = ownerState;\n const slots = {\n root: ['root', color !== 'inherit' && `color${capitalize(color)}`, `fontSize${capitalize(fontSize)}`]\n };\n return composeClasses(slots, getSvgIconUtilityClass, classes);\n};\nconst SvgIconRoot = styled('svg', {\n name: 'MuiSvgIcon',\n slot: 'Root',\n overridesResolver: (props, styles) => {\n const {\n ownerState\n } = props;\n return [styles.root, ownerState.color !== 'inherit' && styles[`color${capitalize(ownerState.color)}`], styles[`fontSize${capitalize(ownerState.fontSize)}`]];\n }\n})(({\n theme,\n ownerState\n}) => {\n var _theme$transitions, _theme$transitions$cr, _theme$transitions2, _theme$typography, _theme$typography$pxT, _theme$typography2, _theme$typography2$px, _theme$typography3, _theme$typography3$px, _palette$ownerState$c, _palette, _palette2, _palette3;\n return {\n userSelect: 'none',\n width: '1em',\n height: '1em',\n display: 'inline-block',\n // the will define the property that has `currentColor`\n // e.g. heroicons uses fill=\"none\" and stroke=\"currentColor\"\n fill: ownerState.hasSvgAsChild ? undefined : 'currentColor',\n flexShrink: 0,\n transition: (_theme$transitions = theme.transitions) == null || (_theme$transitions$cr = _theme$transitions.create) == null ? void 0 : _theme$transitions$cr.call(_theme$transitions, 'fill', {\n duration: (_theme$transitions2 = theme.transitions) == null || (_theme$transitions2 = _theme$transitions2.duration) == null ? void 0 : _theme$transitions2.shorter\n }),\n fontSize: {\n inherit: 'inherit',\n small: ((_theme$typography = theme.typography) == null || (_theme$typography$pxT = _theme$typography.pxToRem) == null ? void 0 : _theme$typography$pxT.call(_theme$typography, 20)) || '1.25rem',\n medium: ((_theme$typography2 = theme.typography) == null || (_theme$typography2$px = _theme$typography2.pxToRem) == null ? void 0 : _theme$typography2$px.call(_theme$typography2, 24)) || '1.5rem',\n large: ((_theme$typography3 = theme.typography) == null || (_theme$typography3$px = _theme$typography3.pxToRem) == null ? void 0 : _theme$typography3$px.call(_theme$typography3, 35)) || '2.1875rem'\n }[ownerState.fontSize],\n // TODO v5 deprecate, v6 remove for sx\n color: (_palette$ownerState$c = (_palette = (theme.vars || theme).palette) == null || (_palette = _palette[ownerState.color]) == null ? void 0 : _palette.main) != null ? _palette$ownerState$c : {\n action: (_palette2 = (theme.vars || theme).palette) == null || (_palette2 = _palette2.action) == null ? void 0 : _palette2.active,\n disabled: (_palette3 = (theme.vars || theme).palette) == null || (_palette3 = _palette3.action) == null ? void 0 : _palette3.disabled,\n inherit: undefined\n }[ownerState.color]\n };\n});\nconst SvgIcon = /*#__PURE__*/React.forwardRef(function SvgIcon(inProps, ref) {\n const props = useThemeProps({\n props: inProps,\n name: 'MuiSvgIcon'\n });\n const {\n children,\n className,\n color = 'inherit',\n component = 'svg',\n fontSize = 'medium',\n htmlColor,\n inheritViewBox = false,\n titleAccess,\n viewBox = '0 0 24 24'\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const hasSvgAsChild = /*#__PURE__*/React.isValidElement(children) && children.type === 'svg';\n const ownerState = _extends({}, props, {\n color,\n component,\n fontSize,\n instanceFontSize: inProps.fontSize,\n inheritViewBox,\n viewBox,\n hasSvgAsChild\n });\n const more = {};\n if (!inheritViewBox) {\n more.viewBox = viewBox;\n }\n const classes = useUtilityClasses(ownerState);\n return /*#__PURE__*/_jsxs(SvgIconRoot, _extends({\n as: component,\n className: clsx(classes.root, className),\n focusable: \"false\",\n color: htmlColor,\n \"aria-hidden\": titleAccess ? undefined : true,\n role: titleAccess ? 'img' : undefined,\n ref: ref\n }, more, other, hasSvgAsChild && children.props, {\n ownerState: ownerState,\n children: [hasSvgAsChild ? children.props.children : children, titleAccess ? /*#__PURE__*/_jsx(\"title\", {\n children: titleAccess\n }) : null]\n }));\n});\nprocess.env.NODE_ENV !== \"production\" ? SvgIcon.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the d.ts file and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * Node passed into the SVG element.\n */\n children: PropTypes.node,\n /**\n * Override or extend the styles applied to the component.\n */\n classes: PropTypes.object,\n /**\n * @ignore\n */\n className: PropTypes.string,\n /**\n * The color of the component.\n * It supports both default and custom theme colors, which can be added as shown in the\n * [palette customization guide](https://mui.com/material-ui/customization/palette/#custom-colors).\n * You can use the `htmlColor` prop to apply a color attribute to the SVG element.\n * @default 'inherit'\n */\n color: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.oneOf(['inherit', 'action', 'disabled', 'primary', 'secondary', 'error', 'info', 'success', 'warning']), PropTypes.string]),\n /**\n * The component used for the root node.\n * Either a string to use a HTML element or a component.\n */\n component: PropTypes.elementType,\n /**\n * The fontSize applied to the icon. Defaults to 24px, but can be configure to inherit font size.\n * @default 'medium'\n */\n fontSize: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.oneOf(['inherit', 'large', 'medium', 'small']), PropTypes.string]),\n /**\n * Applies a color attribute to the SVG element.\n */\n htmlColor: PropTypes.string,\n /**\n * If `true`, the root node will inherit the custom `component`'s viewBox and the `viewBox`\n * prop will be ignored.\n * Useful when you want to reference a custom `component` and have `SvgIcon` pass that\n * `component`'s viewBox to the root node.\n * @default false\n */\n inheritViewBox: PropTypes.bool,\n /**\n * The shape-rendering attribute. The behavior of the different options is described on the\n * [MDN Web Docs](https://developer.mozilla.org/en-US/docs/Web/SVG/Attribute/shape-rendering).\n * If you are having issues with blurry icons you should investigate this prop.\n */\n shapeRendering: PropTypes.string,\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Provides a human-readable title for the element that contains it.\n * https://www.w3.org/TR/SVG-access/#Equivalent\n */\n titleAccess: PropTypes.string,\n /**\n * Allows you to redefine what the coordinates without units mean inside an SVG element.\n * For example, if the SVG element is 500 (width) by 200 (height),\n * and you pass viewBox=\"0 0 50 20\",\n * this means that the coordinates inside the SVG will go from the top left corner (0,0)\n * to bottom right (50,20) and each unit will be worth 10px.\n * @default '0 0 24 24'\n */\n viewBox: PropTypes.string\n} : void 0;\nSvgIcon.muiName = 'SvgIcon';\nexport default SvgIcon;","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport * as React from 'react';\nimport SvgIcon from '../SvgIcon';\n\n/**\n * Private module reserved for @mui packages.\n */\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nexport default function createSvgIcon(path, displayName) {\n function Component(props, ref) {\n return /*#__PURE__*/_jsx(SvgIcon, _extends({\n \"data-testid\": `${displayName}Icon`,\n ref: ref\n }, props, {\n children: path\n }));\n }\n if (process.env.NODE_ENV !== 'production') {\n // Need to set `displayName` on the inner component for React.memo.\n // React prior to 16.14 ignores `displayName` on the wrapper.\n Component.displayName = `${displayName}Icon`;\n }\n Component.muiName = SvgIcon.muiName;\n return /*#__PURE__*/React.memo( /*#__PURE__*/React.forwardRef(Component));\n}","'use client';\n\nimport { unstable_ClassNameGenerator as ClassNameGenerator } from '@mui/base/ClassNameGenerator';\nexport { default as capitalize } from './capitalize';\nexport { default as createChainedFunction } from './createChainedFunction';\nexport { default as createSvgIcon } from './createSvgIcon';\nexport { default as debounce } from './debounce';\nexport { default as deprecatedPropType } from './deprecatedPropType';\nexport { default as isMuiElement } from './isMuiElement';\nexport { default as ownerDocument } from './ownerDocument';\nexport { default as ownerWindow } from './ownerWindow';\nexport { default as requirePropFactory } from './requirePropFactory';\nexport { default as setRef } from './setRef';\nexport { default as unstable_useEnhancedEffect } from './useEnhancedEffect';\nexport { default as unstable_useId } from './useId';\nexport { default as unsupportedProp } from './unsupportedProp';\nexport { default as useControlled } from './useControlled';\nexport { default as useEventCallback } from './useEventCallback';\nexport { default as useForkRef } from './useForkRef';\nexport { default as useIsFocusVisible } from './useIsFocusVisible';\n// TODO: remove this export once ClassNameGenerator is stable\n// eslint-disable-next-line @typescript-eslint/naming-convention\nexport const unstable_ClassNameGenerator = {\n configure: generator => {\n if (process.env.NODE_ENV !== 'production') {\n console.warn(['MUI: `ClassNameGenerator` import from `@mui/material/utils` is outdated and might cause unexpected issues.', '', \"You should use `import { unstable_ClassNameGenerator } from '@mui/material/className'` instead\", '', 'The detail of the issue: https://github.com/mui/material-ui/issues/30011#issuecomment-1024993401', '', 'The updated documentation: https://mui.com/guides/classname-generator/'].join('\\n'));\n }\n ClassNameGenerator.configure(generator);\n }\n};","\"use strict\";\n'use client';\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nObject.defineProperty(exports, \"default\", {\n enumerable: true,\n get: function () {\n return _utils.createSvgIcon;\n }\n});\nvar _utils = require(\"@mui/material/utils\");","\"use strict\";\n\"use client\";\n\nvar _interopRequireDefault = require(\"@babel/runtime/helpers/interopRequireDefault\");\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = void 0;\nvar _createSvgIcon = _interopRequireDefault(require(\"./utils/createSvgIcon\"));\nvar _jsxRuntime = require(\"react/jsx-runtime\");\nvar _default = exports.default = (0, _createSvgIcon.default)( /*#__PURE__*/(0, _jsxRuntime.jsx)(\"path\", {\n d: \"m10 17 5-5-5-5z\"\n}), 'ArrowRight');","/**\n * Determines if a given element is a DOM element name (i.e. not a React component).\n */\nexport function isHostComponent(element) {\n return typeof element === 'string';\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport { isHostComponent } from './isHostComponent';\n\n/**\n * Type of the ownerState based on the type of an element it applies to.\n * This resolves to the provided OwnerState for React components and `undefined` for host components.\n * Falls back to `OwnerState | undefined` when the exact type can't be determined in development time.\n */\n\n/**\n * Appends the ownerState object to the props, merging with the existing one if necessary.\n *\n * @param elementType Type of the element that owns the `existingProps`. If the element is a DOM node or undefined, `ownerState` is not applied.\n * @param otherProps Props of the element.\n * @param ownerState\n */\nexport function appendOwnerState(elementType, otherProps, ownerState) {\n if (elementType === undefined || isHostComponent(elementType)) {\n return otherProps;\n }\n return _extends({}, otherProps, {\n ownerState: _extends({}, otherProps.ownerState, ownerState)\n });\n}","'use client';\n\nimport * as React from 'react';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nconst defaultContextValue = {\n disableDefaultClasses: false\n};\nconst ClassNameConfiguratorContext = /*#__PURE__*/React.createContext(defaultContextValue);\n/**\n * @ignore - internal hook.\n *\n * Wraps the `generateUtilityClass` function and controls how the classes are generated.\n * Currently it only affects whether the classes are applied or not.\n *\n * @returns Function to be called with the `generateUtilityClass` function specific to a component to generate the classes.\n */\nexport function useClassNamesOverride(generateUtilityClass) {\n const {\n disableDefaultClasses\n } = React.useContext(ClassNameConfiguratorContext);\n return slot => {\n if (disableDefaultClasses) {\n return '';\n }\n return generateUtilityClass(slot);\n };\n}\n\n/**\n * Allows to configure the components within to not apply any built-in classes.\n */\nexport function ClassNameConfigurator(props) {\n const {\n disableDefaultClasses,\n children\n } = props;\n const contextValue = React.useMemo(() => ({\n disableDefaultClasses: disableDefaultClasses != null ? disableDefaultClasses : false\n }), [disableDefaultClasses]);\n return /*#__PURE__*/_jsx(ClassNameConfiguratorContext.Provider, {\n value: contextValue,\n children: children\n });\n}","/**\n * Extracts event handlers from a given object.\n * A prop is considered an event handler if it is a function and its name starts with `on`.\n *\n * @param object An object to extract event handlers from.\n * @param excludeKeys An array of keys to exclude from the returned object.\n */\nexport function extractEventHandlers(object, excludeKeys = []) {\n if (object === undefined) {\n return {};\n }\n const result = {};\n Object.keys(object).filter(prop => prop.match(/^on[A-Z]/) && typeof object[prop] === 'function' && !excludeKeys.includes(prop)).forEach(prop => {\n result[prop] = object[prop];\n });\n return result;\n}","/**\n * If `componentProps` is a function, calls it with the provided `ownerState`.\n * Otherwise, just returns `componentProps`.\n */\nexport function resolveComponentProps(componentProps, ownerState, slotState) {\n if (typeof componentProps === 'function') {\n return componentProps(ownerState, slotState);\n }\n return componentProps;\n}","/**\n * Removes event handlers from the given object.\n * A field is considered an event handler if it is a function with a name beginning with `on`.\n *\n * @param object Object to remove event handlers from.\n * @returns Object with event handlers removed.\n */\nexport function omitEventHandlers(object) {\n if (object === undefined) {\n return {};\n }\n const result = {};\n Object.keys(object).filter(prop => !(prop.match(/^on[A-Z]/) && typeof object[prop] === 'function')).forEach(prop => {\n result[prop] = object[prop];\n });\n return result;\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport clsx from 'clsx';\nimport { extractEventHandlers } from './extractEventHandlers';\nimport { omitEventHandlers } from './omitEventHandlers';\n/**\n * Merges the slot component internal props (usually coming from a hook)\n * with the externally provided ones.\n *\n * The merge order is (the latter overrides the former):\n * 1. The internal props (specified as a getter function to work with get*Props hook result)\n * 2. Additional props (specified internally on a Base UI component)\n * 3. External props specified on the owner component. These should only be used on a root slot.\n * 4. External props specified in the `slotProps.*` prop.\n * 5. The `className` prop - combined from all the above.\n * @param parameters\n * @returns\n */\nexport function mergeSlotProps(parameters) {\n const {\n getSlotProps,\n additionalProps,\n externalSlotProps,\n externalForwardedProps,\n className\n } = parameters;\n if (!getSlotProps) {\n // The simpler case - getSlotProps is not defined, so no internal event handlers are defined,\n // so we can simply merge all the props without having to worry about extracting event handlers.\n const joinedClasses = clsx(additionalProps == null ? void 0 : additionalProps.className, className, externalForwardedProps == null ? void 0 : externalForwardedProps.className, externalSlotProps == null ? void 0 : externalSlotProps.className);\n const mergedStyle = _extends({}, additionalProps == null ? void 0 : additionalProps.style, externalForwardedProps == null ? void 0 : externalForwardedProps.style, externalSlotProps == null ? void 0 : externalSlotProps.style);\n const props = _extends({}, additionalProps, externalForwardedProps, externalSlotProps);\n if (joinedClasses.length > 0) {\n props.className = joinedClasses;\n }\n if (Object.keys(mergedStyle).length > 0) {\n props.style = mergedStyle;\n }\n return {\n props,\n internalRef: undefined\n };\n }\n\n // In this case, getSlotProps is responsible for calling the external event handlers.\n // We don't need to include them in the merged props because of this.\n\n const eventHandlers = extractEventHandlers(_extends({}, externalForwardedProps, externalSlotProps));\n const componentsPropsWithoutEventHandlers = omitEventHandlers(externalSlotProps);\n const otherPropsWithoutEventHandlers = omitEventHandlers(externalForwardedProps);\n const internalSlotProps = getSlotProps(eventHandlers);\n\n // The order of classes is important here.\n // Emotion (that we use in libraries consuming Base UI) depends on this order\n // to properly override style. It requires the most important classes to be last\n // (see https://github.com/mui/material-ui/pull/33205) for the related discussion.\n const joinedClasses = clsx(internalSlotProps == null ? void 0 : internalSlotProps.className, additionalProps == null ? void 0 : additionalProps.className, className, externalForwardedProps == null ? void 0 : externalForwardedProps.className, externalSlotProps == null ? void 0 : externalSlotProps.className);\n const mergedStyle = _extends({}, internalSlotProps == null ? void 0 : internalSlotProps.style, additionalProps == null ? void 0 : additionalProps.style, externalForwardedProps == null ? void 0 : externalForwardedProps.style, externalSlotProps == null ? void 0 : externalSlotProps.style);\n const props = _extends({}, internalSlotProps, additionalProps, otherPropsWithoutEventHandlers, componentsPropsWithoutEventHandlers);\n if (joinedClasses.length > 0) {\n props.className = joinedClasses;\n }\n if (Object.keys(mergedStyle).length > 0) {\n props.style = mergedStyle;\n }\n return {\n props,\n internalRef: internalSlotProps.ref\n };\n}","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"elementType\", \"externalSlotProps\", \"ownerState\", \"skipResolvingSlotProps\"];\nimport { unstable_useForkRef as useForkRef } from '@mui/utils';\nimport { appendOwnerState } from './appendOwnerState';\nimport { mergeSlotProps } from './mergeSlotProps';\nimport { resolveComponentProps } from './resolveComponentProps';\n/**\n * @ignore - do not document.\n * Builds the props to be passed into the slot of an unstyled component.\n * It merges the internal props of the component with the ones supplied by the user, allowing to customize the behavior.\n * If the slot component is not a host component, it also merges in the `ownerState`.\n *\n * @param parameters.getSlotProps - A function that returns the props to be passed to the slot component.\n */\nexport function useSlotProps(parameters) {\n var _parameters$additiona;\n const {\n elementType,\n externalSlotProps,\n ownerState,\n skipResolvingSlotProps = false\n } = parameters,\n rest = _objectWithoutPropertiesLoose(parameters, _excluded);\n const resolvedComponentsProps = skipResolvingSlotProps ? {} : resolveComponentProps(externalSlotProps, ownerState);\n const {\n props: mergedProps,\n internalRef\n } = mergeSlotProps(_extends({}, rest, {\n externalSlotProps: resolvedComponentsProps\n }));\n const ref = useForkRef(internalRef, resolvedComponentsProps == null ? void 0 : resolvedComponentsProps.ref, (_parameters$additiona = parameters.additionalProps) == null ? void 0 : _parameters$additiona.ref);\n const props = appendOwnerState(elementType, _extends({}, mergedProps, {\n ref\n }), ownerState);\n return props;\n}","import { globalStateClasses } from '@mui/utils/generateUtilityClass';\nconst GLOBAL_CLASS_PREFIX = 'base';\nfunction buildStateClass(state) {\n return `${GLOBAL_CLASS_PREFIX}--${state}`;\n}\nfunction buildSlotClass(componentName, slot) {\n return `${GLOBAL_CLASS_PREFIX}-${componentName}-${slot}`;\n}\nexport function generateUtilityClass(componentName, slot) {\n const globalStateClass = globalStateClasses[slot];\n return globalStateClass ? buildStateClass(globalStateClass) : buildSlotClass(componentName, slot);\n}\nexport function isGlobalState(slot) {\n return globalStateClasses[slot] !== undefined;\n}","import { generateUtilityClass } from '../generateUtilityClass';\nexport function generateUtilityClasses(componentName, slots) {\n const result = {};\n slots.forEach(slot => {\n result[slot] = generateUtilityClass(componentName, slot);\n });\n return result;\n}","'use client';\n\nimport * as React from 'react';\nimport * as ReactDOM from 'react-dom';\nimport PropTypes from 'prop-types';\nimport { exactProp, HTMLElementType, unstable_useEnhancedEffect as useEnhancedEffect, unstable_useForkRef as useForkRef, unstable_setRef as setRef } from '@mui/utils';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nfunction getContainer(container) {\n return typeof container === 'function' ? container() : container;\n}\n\n/**\n * Portals provide a first-class way to render children into a DOM node\n * that exists outside the DOM hierarchy of the parent component.\n *\n * Demos:\n *\n * - [Portal](https://mui.com/base-ui/react-portal/)\n *\n * API:\n *\n * - [Portal API](https://mui.com/base-ui/react-portal/components-api/#portal)\n */\nconst Portal = /*#__PURE__*/React.forwardRef(function Portal(props, forwardedRef) {\n const {\n children,\n container,\n disablePortal = false\n } = props;\n const [mountNode, setMountNode] = React.useState(null);\n // @ts-expect-error TODO upstream fix\n const handleRef = useForkRef( /*#__PURE__*/React.isValidElement(children) ? children.ref : null, forwardedRef);\n useEnhancedEffect(() => {\n if (!disablePortal) {\n setMountNode(getContainer(container) || document.body);\n }\n }, [container, disablePortal]);\n useEnhancedEffect(() => {\n if (mountNode && !disablePortal) {\n setRef(forwardedRef, mountNode);\n return () => {\n setRef(forwardedRef, null);\n };\n }\n return undefined;\n }, [forwardedRef, mountNode, disablePortal]);\n if (disablePortal) {\n if ( /*#__PURE__*/React.isValidElement(children)) {\n const newProps = {\n ref: handleRef\n };\n return /*#__PURE__*/React.cloneElement(children, newProps);\n }\n return /*#__PURE__*/_jsx(React.Fragment, {\n children: children\n });\n }\n return /*#__PURE__*/_jsx(React.Fragment, {\n children: mountNode ? /*#__PURE__*/ReactDOM.createPortal(children, mountNode) : mountNode\n });\n});\nprocess.env.NODE_ENV !== \"production\" ? Portal.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * The children to render into the `container`.\n */\n children: PropTypes.node,\n /**\n * An HTML element or function that returns one.\n * The `container` will have the portal children appended to it.\n *\n * You can also provide a callback, which is called in a React layout effect.\n * This lets you set the container from a ref, and also makes server-side rendering possible.\n *\n * By default, it uses the body of the top-level document object,\n * so it's simply `document.body` most of the time.\n */\n container: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.func]),\n /**\n * The `children` will be under the DOM hierarchy of the parent component.\n * @default false\n */\n disablePortal: PropTypes.bool\n} : void 0;\nif (process.env.NODE_ENV !== 'production') {\n // eslint-disable-next-line\n Portal['propTypes' + ''] = exactProp(Portal.propTypes);\n}\nexport { Portal };","export var top = 'top';\nexport var bottom = 'bottom';\nexport var right = 'right';\nexport var left = 'left';\nexport var auto = 'auto';\nexport var basePlacements = [top, bottom, right, left];\nexport var start = 'start';\nexport var end = 'end';\nexport var clippingParents = 'clippingParents';\nexport var viewport = 'viewport';\nexport var popper = 'popper';\nexport var reference = 'reference';\nexport var variationPlacements = /*#__PURE__*/basePlacements.reduce(function (acc, placement) {\n return acc.concat([placement + \"-\" + start, placement + \"-\" + end]);\n}, []);\nexport var placements = /*#__PURE__*/[].concat(basePlacements, [auto]).reduce(function (acc, placement) {\n return acc.concat([placement, placement + \"-\" + start, placement + \"-\" + end]);\n}, []); // modifiers that need to read the DOM\n\nexport var beforeRead = 'beforeRead';\nexport var read = 'read';\nexport var afterRead = 'afterRead'; // pure-logic modifiers\n\nexport var beforeMain = 'beforeMain';\nexport var main = 'main';\nexport var afterMain = 'afterMain'; // modifier with the purpose to write to the DOM (or write into a framework state)\n\nexport var beforeWrite = 'beforeWrite';\nexport var write = 'write';\nexport var afterWrite = 'afterWrite';\nexport var modifierPhases = [beforeRead, read, afterRead, beforeMain, main, afterMain, beforeWrite, write, afterWrite];","export default function getNodeName(element) {\n return element ? (element.nodeName || '').toLowerCase() : null;\n}","export default function getWindow(node) {\n if (node == null) {\n return window;\n }\n\n if (node.toString() !== '[object Window]') {\n var ownerDocument = node.ownerDocument;\n return ownerDocument ? ownerDocument.defaultView || window : window;\n }\n\n return node;\n}","import getWindow from \"./getWindow.js\";\n\nfunction isElement(node) {\n var OwnElement = getWindow(node).Element;\n return node instanceof OwnElement || node instanceof Element;\n}\n\nfunction isHTMLElement(node) {\n var OwnElement = getWindow(node).HTMLElement;\n return node instanceof OwnElement || node instanceof HTMLElement;\n}\n\nfunction isShadowRoot(node) {\n // IE 11 has no ShadowRoot\n if (typeof ShadowRoot === 'undefined') {\n return false;\n }\n\n var OwnElement = getWindow(node).ShadowRoot;\n return node instanceof OwnElement || node instanceof ShadowRoot;\n}\n\nexport { isElement, isHTMLElement, isShadowRoot };","import getNodeName from \"../dom-utils/getNodeName.js\";\nimport { isHTMLElement } from \"../dom-utils/instanceOf.js\"; // This modifier takes the styles prepared by the `computeStyles` modifier\n// and applies them to the HTMLElements such as popper and arrow\n\nfunction applyStyles(_ref) {\n var state = _ref.state;\n Object.keys(state.elements).forEach(function (name) {\n var style = state.styles[name] || {};\n var attributes = state.attributes[name] || {};\n var element = state.elements[name]; // arrow is optional + virtual elements\n\n if (!isHTMLElement(element) || !getNodeName(element)) {\n return;\n } // Flow doesn't support to extend this property, but it's the most\n // effective way to apply styles to an HTMLElement\n // $FlowFixMe[cannot-write]\n\n\n Object.assign(element.style, style);\n Object.keys(attributes).forEach(function (name) {\n var value = attributes[name];\n\n if (value === false) {\n element.removeAttribute(name);\n } else {\n element.setAttribute(name, value === true ? '' : value);\n }\n });\n });\n}\n\nfunction effect(_ref2) {\n var state = _ref2.state;\n var initialStyles = {\n popper: {\n position: state.options.strategy,\n left: '0',\n top: '0',\n margin: '0'\n },\n arrow: {\n position: 'absolute'\n },\n reference: {}\n };\n Object.assign(state.elements.popper.style, initialStyles.popper);\n state.styles = initialStyles;\n\n if (state.elements.arrow) {\n Object.assign(state.elements.arrow.style, initialStyles.arrow);\n }\n\n return function () {\n Object.keys(state.elements).forEach(function (name) {\n var element = state.elements[name];\n var attributes = state.attributes[name] || {};\n var styleProperties = Object.keys(state.styles.hasOwnProperty(name) ? state.styles[name] : initialStyles[name]); // Set all values to an empty string to unset them\n\n var style = styleProperties.reduce(function (style, property) {\n style[property] = '';\n return style;\n }, {}); // arrow is optional + virtual elements\n\n if (!isHTMLElement(element) || !getNodeName(element)) {\n return;\n }\n\n Object.assign(element.style, style);\n Object.keys(attributes).forEach(function (attribute) {\n element.removeAttribute(attribute);\n });\n });\n };\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'applyStyles',\n enabled: true,\n phase: 'write',\n fn: applyStyles,\n effect: effect,\n requires: ['computeStyles']\n};","import { auto } from \"../enums.js\";\nexport default function getBasePlacement(placement) {\n return placement.split('-')[0];\n}","export var max = Math.max;\nexport var min = Math.min;\nexport var round = Math.round;","export default function getUAString() {\n var uaData = navigator.userAgentData;\n\n if (uaData != null && uaData.brands && Array.isArray(uaData.brands)) {\n return uaData.brands.map(function (item) {\n return item.brand + \"/\" + item.version;\n }).join(' ');\n }\n\n return navigator.userAgent;\n}","import getUAString from \"../utils/userAgent.js\";\nexport default function isLayoutViewport() {\n return !/^((?!chrome|android).)*safari/i.test(getUAString());\n}","import { isElement, isHTMLElement } from \"./instanceOf.js\";\nimport { round } from \"../utils/math.js\";\nimport getWindow from \"./getWindow.js\";\nimport isLayoutViewport from \"./isLayoutViewport.js\";\nexport default function getBoundingClientRect(element, includeScale, isFixedStrategy) {\n if (includeScale === void 0) {\n includeScale = false;\n }\n\n if (isFixedStrategy === void 0) {\n isFixedStrategy = false;\n }\n\n var clientRect = element.getBoundingClientRect();\n var scaleX = 1;\n var scaleY = 1;\n\n if (includeScale && isHTMLElement(element)) {\n scaleX = element.offsetWidth > 0 ? round(clientRect.width) / element.offsetWidth || 1 : 1;\n scaleY = element.offsetHeight > 0 ? round(clientRect.height) / element.offsetHeight || 1 : 1;\n }\n\n var _ref = isElement(element) ? getWindow(element) : window,\n visualViewport = _ref.visualViewport;\n\n var addVisualOffsets = !isLayoutViewport() && isFixedStrategy;\n var x = (clientRect.left + (addVisualOffsets && visualViewport ? visualViewport.offsetLeft : 0)) / scaleX;\n var y = (clientRect.top + (addVisualOffsets && visualViewport ? visualViewport.offsetTop : 0)) / scaleY;\n var width = clientRect.width / scaleX;\n var height = clientRect.height / scaleY;\n return {\n width: width,\n height: height,\n top: y,\n right: x + width,\n bottom: y + height,\n left: x,\n x: x,\n y: y\n };\n}","import getBoundingClientRect from \"./getBoundingClientRect.js\"; // Returns the layout rect of an element relative to its offsetParent. Layout\n// means it doesn't take into account transforms.\n\nexport default function getLayoutRect(element) {\n var clientRect = getBoundingClientRect(element); // Use the clientRect sizes if it's not been transformed.\n // Fixes https://github.com/popperjs/popper-core/issues/1223\n\n var width = element.offsetWidth;\n var height = element.offsetHeight;\n\n if (Math.abs(clientRect.width - width) <= 1) {\n width = clientRect.width;\n }\n\n if (Math.abs(clientRect.height - height) <= 1) {\n height = clientRect.height;\n }\n\n return {\n x: element.offsetLeft,\n y: element.offsetTop,\n width: width,\n height: height\n };\n}","import { isShadowRoot } from \"./instanceOf.js\";\nexport default function contains(parent, child) {\n var rootNode = child.getRootNode && child.getRootNode(); // First, attempt with faster native method\n\n if (parent.contains(child)) {\n return true;\n } // then fallback to custom implementation with Shadow DOM support\n else if (rootNode && isShadowRoot(rootNode)) {\n var next = child;\n\n do {\n if (next && parent.isSameNode(next)) {\n return true;\n } // $FlowFixMe[prop-missing]: need a better way to handle this...\n\n\n next = next.parentNode || next.host;\n } while (next);\n } // Give up, the result is false\n\n\n return false;\n}","import getWindow from \"./getWindow.js\";\nexport default function getComputedStyle(element) {\n return getWindow(element).getComputedStyle(element);\n}","import getNodeName from \"./getNodeName.js\";\nexport default function isTableElement(element) {\n return ['table', 'td', 'th'].indexOf(getNodeName(element)) >= 0;\n}","import { isElement } from \"./instanceOf.js\";\nexport default function getDocumentElement(element) {\n // $FlowFixMe[incompatible-return]: assume body is always available\n return ((isElement(element) ? element.ownerDocument : // $FlowFixMe[prop-missing]\n element.document) || window.document).documentElement;\n}","import getNodeName from \"./getNodeName.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport { isShadowRoot } from \"./instanceOf.js\";\nexport default function getParentNode(element) {\n if (getNodeName(element) === 'html') {\n return element;\n }\n\n return (// this is a quicker (but less type safe) way to save quite some bytes from the bundle\n // $FlowFixMe[incompatible-return]\n // $FlowFixMe[prop-missing]\n element.assignedSlot || // step into the shadow DOM of the parent of a slotted node\n element.parentNode || ( // DOM Element detected\n isShadowRoot(element) ? element.host : null) || // ShadowRoot detected\n // $FlowFixMe[incompatible-call]: HTMLElement is a Node\n getDocumentElement(element) // fallback\n\n );\n}","import getWindow from \"./getWindow.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport getComputedStyle from \"./getComputedStyle.js\";\nimport { isHTMLElement, isShadowRoot } from \"./instanceOf.js\";\nimport isTableElement from \"./isTableElement.js\";\nimport getParentNode from \"./getParentNode.js\";\nimport getUAString from \"../utils/userAgent.js\";\n\nfunction getTrueOffsetParent(element) {\n if (!isHTMLElement(element) || // https://github.com/popperjs/popper-core/issues/837\n getComputedStyle(element).position === 'fixed') {\n return null;\n }\n\n return element.offsetParent;\n} // `.offsetParent` reports `null` for fixed elements, while absolute elements\n// return the containing block\n\n\nfunction getContainingBlock(element) {\n var isFirefox = /firefox/i.test(getUAString());\n var isIE = /Trident/i.test(getUAString());\n\n if (isIE && isHTMLElement(element)) {\n // In IE 9, 10 and 11 fixed elements containing block is always established by the viewport\n var elementCss = getComputedStyle(element);\n\n if (elementCss.position === 'fixed') {\n return null;\n }\n }\n\n var currentNode = getParentNode(element);\n\n if (isShadowRoot(currentNode)) {\n currentNode = currentNode.host;\n }\n\n while (isHTMLElement(currentNode) && ['html', 'body'].indexOf(getNodeName(currentNode)) < 0) {\n var css = getComputedStyle(currentNode); // This is non-exhaustive but covers the most common CSS properties that\n // create a containing block.\n // https://developer.mozilla.org/en-US/docs/Web/CSS/Containing_block#identifying_the_containing_block\n\n if (css.transform !== 'none' || css.perspective !== 'none' || css.contain === 'paint' || ['transform', 'perspective'].indexOf(css.willChange) !== -1 || isFirefox && css.willChange === 'filter' || isFirefox && css.filter && css.filter !== 'none') {\n return currentNode;\n } else {\n currentNode = currentNode.parentNode;\n }\n }\n\n return null;\n} // Gets the closest ancestor positioned element. Handles some edge cases,\n// such as table ancestors and cross browser bugs.\n\n\nexport default function getOffsetParent(element) {\n var window = getWindow(element);\n var offsetParent = getTrueOffsetParent(element);\n\n while (offsetParent && isTableElement(offsetParent) && getComputedStyle(offsetParent).position === 'static') {\n offsetParent = getTrueOffsetParent(offsetParent);\n }\n\n if (offsetParent && (getNodeName(offsetParent) === 'html' || getNodeName(offsetParent) === 'body' && getComputedStyle(offsetParent).position === 'static')) {\n return window;\n }\n\n return offsetParent || getContainingBlock(element) || window;\n}","export default function getMainAxisFromPlacement(placement) {\n return ['top', 'bottom'].indexOf(placement) >= 0 ? 'x' : 'y';\n}","import { max as mathMax, min as mathMin } from \"./math.js\";\nexport function within(min, value, max) {\n return mathMax(min, mathMin(value, max));\n}\nexport function withinMaxClamp(min, value, max) {\n var v = within(min, value, max);\n return v > max ? max : v;\n}","export default function getFreshSideObject() {\n return {\n top: 0,\n right: 0,\n bottom: 0,\n left: 0\n };\n}","import getFreshSideObject from \"./getFreshSideObject.js\";\nexport default function mergePaddingObject(paddingObject) {\n return Object.assign({}, getFreshSideObject(), paddingObject);\n}","export default function expandToHashMap(value, keys) {\n return keys.reduce(function (hashMap, key) {\n hashMap[key] = value;\n return hashMap;\n }, {});\n}","import getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getLayoutRect from \"../dom-utils/getLayoutRect.js\";\nimport contains from \"../dom-utils/contains.js\";\nimport getOffsetParent from \"../dom-utils/getOffsetParent.js\";\nimport getMainAxisFromPlacement from \"../utils/getMainAxisFromPlacement.js\";\nimport { within } from \"../utils/within.js\";\nimport mergePaddingObject from \"../utils/mergePaddingObject.js\";\nimport expandToHashMap from \"../utils/expandToHashMap.js\";\nimport { left, right, basePlacements, top, bottom } from \"../enums.js\"; // eslint-disable-next-line import/no-unused-modules\n\nvar toPaddingObject = function toPaddingObject(padding, state) {\n padding = typeof padding === 'function' ? padding(Object.assign({}, state.rects, {\n placement: state.placement\n })) : padding;\n return mergePaddingObject(typeof padding !== 'number' ? padding : expandToHashMap(padding, basePlacements));\n};\n\nfunction arrow(_ref) {\n var _state$modifiersData$;\n\n var state = _ref.state,\n name = _ref.name,\n options = _ref.options;\n var arrowElement = state.elements.arrow;\n var popperOffsets = state.modifiersData.popperOffsets;\n var basePlacement = getBasePlacement(state.placement);\n var axis = getMainAxisFromPlacement(basePlacement);\n var isVertical = [left, right].indexOf(basePlacement) >= 0;\n var len = isVertical ? 'height' : 'width';\n\n if (!arrowElement || !popperOffsets) {\n return;\n }\n\n var paddingObject = toPaddingObject(options.padding, state);\n var arrowRect = getLayoutRect(arrowElement);\n var minProp = axis === 'y' ? top : left;\n var maxProp = axis === 'y' ? bottom : right;\n var endDiff = state.rects.reference[len] + state.rects.reference[axis] - popperOffsets[axis] - state.rects.popper[len];\n var startDiff = popperOffsets[axis] - state.rects.reference[axis];\n var arrowOffsetParent = getOffsetParent(arrowElement);\n var clientSize = arrowOffsetParent ? axis === 'y' ? arrowOffsetParent.clientHeight || 0 : arrowOffsetParent.clientWidth || 0 : 0;\n var centerToReference = endDiff / 2 - startDiff / 2; // Make sure the arrow doesn't overflow the popper if the center point is\n // outside of the popper bounds\n\n var min = paddingObject[minProp];\n var max = clientSize - arrowRect[len] - paddingObject[maxProp];\n var center = clientSize / 2 - arrowRect[len] / 2 + centerToReference;\n var offset = within(min, center, max); // Prevents breaking syntax highlighting...\n\n var axisProp = axis;\n state.modifiersData[name] = (_state$modifiersData$ = {}, _state$modifiersData$[axisProp] = offset, _state$modifiersData$.centerOffset = offset - center, _state$modifiersData$);\n}\n\nfunction effect(_ref2) {\n var state = _ref2.state,\n options = _ref2.options;\n var _options$element = options.element,\n arrowElement = _options$element === void 0 ? '[data-popper-arrow]' : _options$element;\n\n if (arrowElement == null) {\n return;\n } // CSS selector\n\n\n if (typeof arrowElement === 'string') {\n arrowElement = state.elements.popper.querySelector(arrowElement);\n\n if (!arrowElement) {\n return;\n }\n }\n\n if (!contains(state.elements.popper, arrowElement)) {\n return;\n }\n\n state.elements.arrow = arrowElement;\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'arrow',\n enabled: true,\n phase: 'main',\n fn: arrow,\n effect: effect,\n requires: ['popperOffsets'],\n requiresIfExists: ['preventOverflow']\n};","export default function getVariation(placement) {\n return placement.split('-')[1];\n}","import { top, left, right, bottom, end } from \"../enums.js\";\nimport getOffsetParent from \"../dom-utils/getOffsetParent.js\";\nimport getWindow from \"../dom-utils/getWindow.js\";\nimport getDocumentElement from \"../dom-utils/getDocumentElement.js\";\nimport getComputedStyle from \"../dom-utils/getComputedStyle.js\";\nimport getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getVariation from \"../utils/getVariation.js\";\nimport { round } from \"../utils/math.js\"; // eslint-disable-next-line import/no-unused-modules\n\nvar unsetSides = {\n top: 'auto',\n right: 'auto',\n bottom: 'auto',\n left: 'auto'\n}; // Round the offsets to the nearest suitable subpixel based on the DPR.\n// Zooming can change the DPR, but it seems to report a value that will\n// cleanly divide the values into the appropriate subpixels.\n\nfunction roundOffsetsByDPR(_ref, win) {\n var x = _ref.x,\n y = _ref.y;\n var dpr = win.devicePixelRatio || 1;\n return {\n x: round(x * dpr) / dpr || 0,\n y: round(y * dpr) / dpr || 0\n };\n}\n\nexport function mapToStyles(_ref2) {\n var _Object$assign2;\n\n var popper = _ref2.popper,\n popperRect = _ref2.popperRect,\n placement = _ref2.placement,\n variation = _ref2.variation,\n offsets = _ref2.offsets,\n position = _ref2.position,\n gpuAcceleration = _ref2.gpuAcceleration,\n adaptive = _ref2.adaptive,\n roundOffsets = _ref2.roundOffsets,\n isFixed = _ref2.isFixed;\n var _offsets$x = offsets.x,\n x = _offsets$x === void 0 ? 0 : _offsets$x,\n _offsets$y = offsets.y,\n y = _offsets$y === void 0 ? 0 : _offsets$y;\n\n var _ref3 = typeof roundOffsets === 'function' ? roundOffsets({\n x: x,\n y: y\n }) : {\n x: x,\n y: y\n };\n\n x = _ref3.x;\n y = _ref3.y;\n var hasX = offsets.hasOwnProperty('x');\n var hasY = offsets.hasOwnProperty('y');\n var sideX = left;\n var sideY = top;\n var win = window;\n\n if (adaptive) {\n var offsetParent = getOffsetParent(popper);\n var heightProp = 'clientHeight';\n var widthProp = 'clientWidth';\n\n if (offsetParent === getWindow(popper)) {\n offsetParent = getDocumentElement(popper);\n\n if (getComputedStyle(offsetParent).position !== 'static' && position === 'absolute') {\n heightProp = 'scrollHeight';\n widthProp = 'scrollWidth';\n }\n } // $FlowFixMe[incompatible-cast]: force type refinement, we compare offsetParent with window above, but Flow doesn't detect it\n\n\n offsetParent = offsetParent;\n\n if (placement === top || (placement === left || placement === right) && variation === end) {\n sideY = bottom;\n var offsetY = isFixed && offsetParent === win && win.visualViewport ? win.visualViewport.height : // $FlowFixMe[prop-missing]\n offsetParent[heightProp];\n y -= offsetY - popperRect.height;\n y *= gpuAcceleration ? 1 : -1;\n }\n\n if (placement === left || (placement === top || placement === bottom) && variation === end) {\n sideX = right;\n var offsetX = isFixed && offsetParent === win && win.visualViewport ? win.visualViewport.width : // $FlowFixMe[prop-missing]\n offsetParent[widthProp];\n x -= offsetX - popperRect.width;\n x *= gpuAcceleration ? 1 : -1;\n }\n }\n\n var commonStyles = Object.assign({\n position: position\n }, adaptive && unsetSides);\n\n var _ref4 = roundOffsets === true ? roundOffsetsByDPR({\n x: x,\n y: y\n }, getWindow(popper)) : {\n x: x,\n y: y\n };\n\n x = _ref4.x;\n y = _ref4.y;\n\n if (gpuAcceleration) {\n var _Object$assign;\n\n return Object.assign({}, commonStyles, (_Object$assign = {}, _Object$assign[sideY] = hasY ? '0' : '', _Object$assign[sideX] = hasX ? '0' : '', _Object$assign.transform = (win.devicePixelRatio || 1) <= 1 ? \"translate(\" + x + \"px, \" + y + \"px)\" : \"translate3d(\" + x + \"px, \" + y + \"px, 0)\", _Object$assign));\n }\n\n return Object.assign({}, commonStyles, (_Object$assign2 = {}, _Object$assign2[sideY] = hasY ? y + \"px\" : '', _Object$assign2[sideX] = hasX ? x + \"px\" : '', _Object$assign2.transform = '', _Object$assign2));\n}\n\nfunction computeStyles(_ref5) {\n var state = _ref5.state,\n options = _ref5.options;\n var _options$gpuAccelerat = options.gpuAcceleration,\n gpuAcceleration = _options$gpuAccelerat === void 0 ? true : _options$gpuAccelerat,\n _options$adaptive = options.adaptive,\n adaptive = _options$adaptive === void 0 ? true : _options$adaptive,\n _options$roundOffsets = options.roundOffsets,\n roundOffsets = _options$roundOffsets === void 0 ? true : _options$roundOffsets;\n var commonStyles = {\n placement: getBasePlacement(state.placement),\n variation: getVariation(state.placement),\n popper: state.elements.popper,\n popperRect: state.rects.popper,\n gpuAcceleration: gpuAcceleration,\n isFixed: state.options.strategy === 'fixed'\n };\n\n if (state.modifiersData.popperOffsets != null) {\n state.styles.popper = Object.assign({}, state.styles.popper, mapToStyles(Object.assign({}, commonStyles, {\n offsets: state.modifiersData.popperOffsets,\n position: state.options.strategy,\n adaptive: adaptive,\n roundOffsets: roundOffsets\n })));\n }\n\n if (state.modifiersData.arrow != null) {\n state.styles.arrow = Object.assign({}, state.styles.arrow, mapToStyles(Object.assign({}, commonStyles, {\n offsets: state.modifiersData.arrow,\n position: 'absolute',\n adaptive: false,\n roundOffsets: roundOffsets\n })));\n }\n\n state.attributes.popper = Object.assign({}, state.attributes.popper, {\n 'data-popper-placement': state.placement\n });\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'computeStyles',\n enabled: true,\n phase: 'beforeWrite',\n fn: computeStyles,\n data: {}\n};","import getWindow from \"../dom-utils/getWindow.js\"; // eslint-disable-next-line import/no-unused-modules\n\nvar passive = {\n passive: true\n};\n\nfunction effect(_ref) {\n var state = _ref.state,\n instance = _ref.instance,\n options = _ref.options;\n var _options$scroll = options.scroll,\n scroll = _options$scroll === void 0 ? true : _options$scroll,\n _options$resize = options.resize,\n resize = _options$resize === void 0 ? true : _options$resize;\n var window = getWindow(state.elements.popper);\n var scrollParents = [].concat(state.scrollParents.reference, state.scrollParents.popper);\n\n if (scroll) {\n scrollParents.forEach(function (scrollParent) {\n scrollParent.addEventListener('scroll', instance.update, passive);\n });\n }\n\n if (resize) {\n window.addEventListener('resize', instance.update, passive);\n }\n\n return function () {\n if (scroll) {\n scrollParents.forEach(function (scrollParent) {\n scrollParent.removeEventListener('scroll', instance.update, passive);\n });\n }\n\n if (resize) {\n window.removeEventListener('resize', instance.update, passive);\n }\n };\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'eventListeners',\n enabled: true,\n phase: 'write',\n fn: function fn() {},\n effect: effect,\n data: {}\n};","var hash = {\n left: 'right',\n right: 'left',\n bottom: 'top',\n top: 'bottom'\n};\nexport default function getOppositePlacement(placement) {\n return placement.replace(/left|right|bottom|top/g, function (matched) {\n return hash[matched];\n });\n}","var hash = {\n start: 'end',\n end: 'start'\n};\nexport default function getOppositeVariationPlacement(placement) {\n return placement.replace(/start|end/g, function (matched) {\n return hash[matched];\n });\n}","import getWindow from \"./getWindow.js\";\nexport default function getWindowScroll(node) {\n var win = getWindow(node);\n var scrollLeft = win.pageXOffset;\n var scrollTop = win.pageYOffset;\n return {\n scrollLeft: scrollLeft,\n scrollTop: scrollTop\n };\n}","import getBoundingClientRect from \"./getBoundingClientRect.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport getWindowScroll from \"./getWindowScroll.js\";\nexport default function getWindowScrollBarX(element) {\n // If has a CSS width greater than the viewport, then this will be\n // incorrect for RTL.\n // Popper 1 is broken in this case and never had a bug report so let's assume\n // it's not an issue. I don't think anyone ever specifies width on \n // anyway.\n // Browsers where the left scrollbar doesn't cause an issue report `0` for\n // this (e.g. Edge 2019, IE11, Safari)\n return getBoundingClientRect(getDocumentElement(element)).left + getWindowScroll(element).scrollLeft;\n}","import getWindow from \"./getWindow.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport getWindowScrollBarX from \"./getWindowScrollBarX.js\";\nimport isLayoutViewport from \"./isLayoutViewport.js\";\nexport default function getViewportRect(element, strategy) {\n var win = getWindow(element);\n var html = getDocumentElement(element);\n var visualViewport = win.visualViewport;\n var width = html.clientWidth;\n var height = html.clientHeight;\n var x = 0;\n var y = 0;\n\n if (visualViewport) {\n width = visualViewport.width;\n height = visualViewport.height;\n var layoutViewport = isLayoutViewport();\n\n if (layoutViewport || !layoutViewport && strategy === 'fixed') {\n x = visualViewport.offsetLeft;\n y = visualViewport.offsetTop;\n }\n }\n\n return {\n width: width,\n height: height,\n x: x + getWindowScrollBarX(element),\n y: y\n };\n}","import getDocumentElement from \"./getDocumentElement.js\";\nimport getComputedStyle from \"./getComputedStyle.js\";\nimport getWindowScrollBarX from \"./getWindowScrollBarX.js\";\nimport getWindowScroll from \"./getWindowScroll.js\";\nimport { max } from \"../utils/math.js\"; // Gets the entire size of the scrollable document area, even extending outside\n// of the `` and `` rect bounds if horizontally scrollable\n\nexport default function getDocumentRect(element) {\n var _element$ownerDocumen;\n\n var html = getDocumentElement(element);\n var winScroll = getWindowScroll(element);\n var body = (_element$ownerDocumen = element.ownerDocument) == null ? void 0 : _element$ownerDocumen.body;\n var width = max(html.scrollWidth, html.clientWidth, body ? body.scrollWidth : 0, body ? body.clientWidth : 0);\n var height = max(html.scrollHeight, html.clientHeight, body ? body.scrollHeight : 0, body ? body.clientHeight : 0);\n var x = -winScroll.scrollLeft + getWindowScrollBarX(element);\n var y = -winScroll.scrollTop;\n\n if (getComputedStyle(body || html).direction === 'rtl') {\n x += max(html.clientWidth, body ? body.clientWidth : 0) - width;\n }\n\n return {\n width: width,\n height: height,\n x: x,\n y: y\n };\n}","import getComputedStyle from \"./getComputedStyle.js\";\nexport default function isScrollParent(element) {\n // Firefox wants us to check `-x` and `-y` variations as well\n var _getComputedStyle = getComputedStyle(element),\n overflow = _getComputedStyle.overflow,\n overflowX = _getComputedStyle.overflowX,\n overflowY = _getComputedStyle.overflowY;\n\n return /auto|scroll|overlay|hidden/.test(overflow + overflowY + overflowX);\n}","import getParentNode from \"./getParentNode.js\";\nimport isScrollParent from \"./isScrollParent.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport { isHTMLElement } from \"./instanceOf.js\";\nexport default function getScrollParent(node) {\n if (['html', 'body', '#document'].indexOf(getNodeName(node)) >= 0) {\n // $FlowFixMe[incompatible-return]: assume body is always available\n return node.ownerDocument.body;\n }\n\n if (isHTMLElement(node) && isScrollParent(node)) {\n return node;\n }\n\n return getScrollParent(getParentNode(node));\n}","import getScrollParent from \"./getScrollParent.js\";\nimport getParentNode from \"./getParentNode.js\";\nimport getWindow from \"./getWindow.js\";\nimport isScrollParent from \"./isScrollParent.js\";\n/*\ngiven a DOM element, return the list of all scroll parents, up the list of ancesors\nuntil we get to the top window object. This list is what we attach scroll listeners\nto, because if any of these parent elements scroll, we'll need to re-calculate the\nreference element's position.\n*/\n\nexport default function listScrollParents(element, list) {\n var _element$ownerDocumen;\n\n if (list === void 0) {\n list = [];\n }\n\n var scrollParent = getScrollParent(element);\n var isBody = scrollParent === ((_element$ownerDocumen = element.ownerDocument) == null ? void 0 : _element$ownerDocumen.body);\n var win = getWindow(scrollParent);\n var target = isBody ? [win].concat(win.visualViewport || [], isScrollParent(scrollParent) ? scrollParent : []) : scrollParent;\n var updatedList = list.concat(target);\n return isBody ? updatedList : // $FlowFixMe[incompatible-call]: isBody tells us target will be an HTMLElement here\n updatedList.concat(listScrollParents(getParentNode(target)));\n}","export default function rectToClientRect(rect) {\n return Object.assign({}, rect, {\n left: rect.x,\n top: rect.y,\n right: rect.x + rect.width,\n bottom: rect.y + rect.height\n });\n}","import { viewport } from \"../enums.js\";\nimport getViewportRect from \"./getViewportRect.js\";\nimport getDocumentRect from \"./getDocumentRect.js\";\nimport listScrollParents from \"./listScrollParents.js\";\nimport getOffsetParent from \"./getOffsetParent.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport getComputedStyle from \"./getComputedStyle.js\";\nimport { isElement, isHTMLElement } from \"./instanceOf.js\";\nimport getBoundingClientRect from \"./getBoundingClientRect.js\";\nimport getParentNode from \"./getParentNode.js\";\nimport contains from \"./contains.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport rectToClientRect from \"../utils/rectToClientRect.js\";\nimport { max, min } from \"../utils/math.js\";\n\nfunction getInnerBoundingClientRect(element, strategy) {\n var rect = getBoundingClientRect(element, false, strategy === 'fixed');\n rect.top = rect.top + element.clientTop;\n rect.left = rect.left + element.clientLeft;\n rect.bottom = rect.top + element.clientHeight;\n rect.right = rect.left + element.clientWidth;\n rect.width = element.clientWidth;\n rect.height = element.clientHeight;\n rect.x = rect.left;\n rect.y = rect.top;\n return rect;\n}\n\nfunction getClientRectFromMixedType(element, clippingParent, strategy) {\n return clippingParent === viewport ? rectToClientRect(getViewportRect(element, strategy)) : isElement(clippingParent) ? getInnerBoundingClientRect(clippingParent, strategy) : rectToClientRect(getDocumentRect(getDocumentElement(element)));\n} // A \"clipping parent\" is an overflowable container with the characteristic of\n// clipping (or hiding) overflowing elements with a position different from\n// `initial`\n\n\nfunction getClippingParents(element) {\n var clippingParents = listScrollParents(getParentNode(element));\n var canEscapeClipping = ['absolute', 'fixed'].indexOf(getComputedStyle(element).position) >= 0;\n var clipperElement = canEscapeClipping && isHTMLElement(element) ? getOffsetParent(element) : element;\n\n if (!isElement(clipperElement)) {\n return [];\n } // $FlowFixMe[incompatible-return]: https://github.com/facebook/flow/issues/1414\n\n\n return clippingParents.filter(function (clippingParent) {\n return isElement(clippingParent) && contains(clippingParent, clipperElement) && getNodeName(clippingParent) !== 'body';\n });\n} // Gets the maximum area that the element is visible in due to any number of\n// clipping parents\n\n\nexport default function getClippingRect(element, boundary, rootBoundary, strategy) {\n var mainClippingParents = boundary === 'clippingParents' ? getClippingParents(element) : [].concat(boundary);\n var clippingParents = [].concat(mainClippingParents, [rootBoundary]);\n var firstClippingParent = clippingParents[0];\n var clippingRect = clippingParents.reduce(function (accRect, clippingParent) {\n var rect = getClientRectFromMixedType(element, clippingParent, strategy);\n accRect.top = max(rect.top, accRect.top);\n accRect.right = min(rect.right, accRect.right);\n accRect.bottom = min(rect.bottom, accRect.bottom);\n accRect.left = max(rect.left, accRect.left);\n return accRect;\n }, getClientRectFromMixedType(element, firstClippingParent, strategy));\n clippingRect.width = clippingRect.right - clippingRect.left;\n clippingRect.height = clippingRect.bottom - clippingRect.top;\n clippingRect.x = clippingRect.left;\n clippingRect.y = clippingRect.top;\n return clippingRect;\n}","import getBasePlacement from \"./getBasePlacement.js\";\nimport getVariation from \"./getVariation.js\";\nimport getMainAxisFromPlacement from \"./getMainAxisFromPlacement.js\";\nimport { top, right, bottom, left, start, end } from \"../enums.js\";\nexport default function computeOffsets(_ref) {\n var reference = _ref.reference,\n element = _ref.element,\n placement = _ref.placement;\n var basePlacement = placement ? getBasePlacement(placement) : null;\n var variation = placement ? getVariation(placement) : null;\n var commonX = reference.x + reference.width / 2 - element.width / 2;\n var commonY = reference.y + reference.height / 2 - element.height / 2;\n var offsets;\n\n switch (basePlacement) {\n case top:\n offsets = {\n x: commonX,\n y: reference.y - element.height\n };\n break;\n\n case bottom:\n offsets = {\n x: commonX,\n y: reference.y + reference.height\n };\n break;\n\n case right:\n offsets = {\n x: reference.x + reference.width,\n y: commonY\n };\n break;\n\n case left:\n offsets = {\n x: reference.x - element.width,\n y: commonY\n };\n break;\n\n default:\n offsets = {\n x: reference.x,\n y: reference.y\n };\n }\n\n var mainAxis = basePlacement ? getMainAxisFromPlacement(basePlacement) : null;\n\n if (mainAxis != null) {\n var len = mainAxis === 'y' ? 'height' : 'width';\n\n switch (variation) {\n case start:\n offsets[mainAxis] = offsets[mainAxis] - (reference[len] / 2 - element[len] / 2);\n break;\n\n case end:\n offsets[mainAxis] = offsets[mainAxis] + (reference[len] / 2 - element[len] / 2);\n break;\n\n default:\n }\n }\n\n return offsets;\n}","import getClippingRect from \"../dom-utils/getClippingRect.js\";\nimport getDocumentElement from \"../dom-utils/getDocumentElement.js\";\nimport getBoundingClientRect from \"../dom-utils/getBoundingClientRect.js\";\nimport computeOffsets from \"./computeOffsets.js\";\nimport rectToClientRect from \"./rectToClientRect.js\";\nimport { clippingParents, reference, popper, bottom, top, right, basePlacements, viewport } from \"../enums.js\";\nimport { isElement } from \"../dom-utils/instanceOf.js\";\nimport mergePaddingObject from \"./mergePaddingObject.js\";\nimport expandToHashMap from \"./expandToHashMap.js\"; // eslint-disable-next-line import/no-unused-modules\n\nexport default function detectOverflow(state, options) {\n if (options === void 0) {\n options = {};\n }\n\n var _options = options,\n _options$placement = _options.placement,\n placement = _options$placement === void 0 ? state.placement : _options$placement,\n _options$strategy = _options.strategy,\n strategy = _options$strategy === void 0 ? state.strategy : _options$strategy,\n _options$boundary = _options.boundary,\n boundary = _options$boundary === void 0 ? clippingParents : _options$boundary,\n _options$rootBoundary = _options.rootBoundary,\n rootBoundary = _options$rootBoundary === void 0 ? viewport : _options$rootBoundary,\n _options$elementConte = _options.elementContext,\n elementContext = _options$elementConte === void 0 ? popper : _options$elementConte,\n _options$altBoundary = _options.altBoundary,\n altBoundary = _options$altBoundary === void 0 ? false : _options$altBoundary,\n _options$padding = _options.padding,\n padding = _options$padding === void 0 ? 0 : _options$padding;\n var paddingObject = mergePaddingObject(typeof padding !== 'number' ? padding : expandToHashMap(padding, basePlacements));\n var altContext = elementContext === popper ? reference : popper;\n var popperRect = state.rects.popper;\n var element = state.elements[altBoundary ? altContext : elementContext];\n var clippingClientRect = getClippingRect(isElement(element) ? element : element.contextElement || getDocumentElement(state.elements.popper), boundary, rootBoundary, strategy);\n var referenceClientRect = getBoundingClientRect(state.elements.reference);\n var popperOffsets = computeOffsets({\n reference: referenceClientRect,\n element: popperRect,\n strategy: 'absolute',\n placement: placement\n });\n var popperClientRect = rectToClientRect(Object.assign({}, popperRect, popperOffsets));\n var elementClientRect = elementContext === popper ? popperClientRect : referenceClientRect; // positive = overflowing the clipping rect\n // 0 or negative = within the clipping rect\n\n var overflowOffsets = {\n top: clippingClientRect.top - elementClientRect.top + paddingObject.top,\n bottom: elementClientRect.bottom - clippingClientRect.bottom + paddingObject.bottom,\n left: clippingClientRect.left - elementClientRect.left + paddingObject.left,\n right: elementClientRect.right - clippingClientRect.right + paddingObject.right\n };\n var offsetData = state.modifiersData.offset; // Offsets can be applied only to the popper element\n\n if (elementContext === popper && offsetData) {\n var offset = offsetData[placement];\n Object.keys(overflowOffsets).forEach(function (key) {\n var multiply = [right, bottom].indexOf(key) >= 0 ? 1 : -1;\n var axis = [top, bottom].indexOf(key) >= 0 ? 'y' : 'x';\n overflowOffsets[key] += offset[axis] * multiply;\n });\n }\n\n return overflowOffsets;\n}","import getVariation from \"./getVariation.js\";\nimport { variationPlacements, basePlacements, placements as allPlacements } from \"../enums.js\";\nimport detectOverflow from \"./detectOverflow.js\";\nimport getBasePlacement from \"./getBasePlacement.js\";\nexport default function computeAutoPlacement(state, options) {\n if (options === void 0) {\n options = {};\n }\n\n var _options = options,\n placement = _options.placement,\n boundary = _options.boundary,\n rootBoundary = _options.rootBoundary,\n padding = _options.padding,\n flipVariations = _options.flipVariations,\n _options$allowedAutoP = _options.allowedAutoPlacements,\n allowedAutoPlacements = _options$allowedAutoP === void 0 ? allPlacements : _options$allowedAutoP;\n var variation = getVariation(placement);\n var placements = variation ? flipVariations ? variationPlacements : variationPlacements.filter(function (placement) {\n return getVariation(placement) === variation;\n }) : basePlacements;\n var allowedPlacements = placements.filter(function (placement) {\n return allowedAutoPlacements.indexOf(placement) >= 0;\n });\n\n if (allowedPlacements.length === 0) {\n allowedPlacements = placements;\n } // $FlowFixMe[incompatible-type]: Flow seems to have problems with two array unions...\n\n\n var overflows = allowedPlacements.reduce(function (acc, placement) {\n acc[placement] = detectOverflow(state, {\n placement: placement,\n boundary: boundary,\n rootBoundary: rootBoundary,\n padding: padding\n })[getBasePlacement(placement)];\n return acc;\n }, {});\n return Object.keys(overflows).sort(function (a, b) {\n return overflows[a] - overflows[b];\n });\n}","import getOppositePlacement from \"../utils/getOppositePlacement.js\";\nimport getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getOppositeVariationPlacement from \"../utils/getOppositeVariationPlacement.js\";\nimport detectOverflow from \"../utils/detectOverflow.js\";\nimport computeAutoPlacement from \"../utils/computeAutoPlacement.js\";\nimport { bottom, top, start, right, left, auto } from \"../enums.js\";\nimport getVariation from \"../utils/getVariation.js\"; // eslint-disable-next-line import/no-unused-modules\n\nfunction getExpandedFallbackPlacements(placement) {\n if (getBasePlacement(placement) === auto) {\n return [];\n }\n\n var oppositePlacement = getOppositePlacement(placement);\n return [getOppositeVariationPlacement(placement), oppositePlacement, getOppositeVariationPlacement(oppositePlacement)];\n}\n\nfunction flip(_ref) {\n var state = _ref.state,\n options = _ref.options,\n name = _ref.name;\n\n if (state.modifiersData[name]._skip) {\n return;\n }\n\n var _options$mainAxis = options.mainAxis,\n checkMainAxis = _options$mainAxis === void 0 ? true : _options$mainAxis,\n _options$altAxis = options.altAxis,\n checkAltAxis = _options$altAxis === void 0 ? true : _options$altAxis,\n specifiedFallbackPlacements = options.fallbackPlacements,\n padding = options.padding,\n boundary = options.boundary,\n rootBoundary = options.rootBoundary,\n altBoundary = options.altBoundary,\n _options$flipVariatio = options.flipVariations,\n flipVariations = _options$flipVariatio === void 0 ? true : _options$flipVariatio,\n allowedAutoPlacements = options.allowedAutoPlacements;\n var preferredPlacement = state.options.placement;\n var basePlacement = getBasePlacement(preferredPlacement);\n var isBasePlacement = basePlacement === preferredPlacement;\n var fallbackPlacements = specifiedFallbackPlacements || (isBasePlacement || !flipVariations ? [getOppositePlacement(preferredPlacement)] : getExpandedFallbackPlacements(preferredPlacement));\n var placements = [preferredPlacement].concat(fallbackPlacements).reduce(function (acc, placement) {\n return acc.concat(getBasePlacement(placement) === auto ? computeAutoPlacement(state, {\n placement: placement,\n boundary: boundary,\n rootBoundary: rootBoundary,\n padding: padding,\n flipVariations: flipVariations,\n allowedAutoPlacements: allowedAutoPlacements\n }) : placement);\n }, []);\n var referenceRect = state.rects.reference;\n var popperRect = state.rects.popper;\n var checksMap = new Map();\n var makeFallbackChecks = true;\n var firstFittingPlacement = placements[0];\n\n for (var i = 0; i < placements.length; i++) {\n var placement = placements[i];\n\n var _basePlacement = getBasePlacement(placement);\n\n var isStartVariation = getVariation(placement) === start;\n var isVertical = [top, bottom].indexOf(_basePlacement) >= 0;\n var len = isVertical ? 'width' : 'height';\n var overflow = detectOverflow(state, {\n placement: placement,\n boundary: boundary,\n rootBoundary: rootBoundary,\n altBoundary: altBoundary,\n padding: padding\n });\n var mainVariationSide = isVertical ? isStartVariation ? right : left : isStartVariation ? bottom : top;\n\n if (referenceRect[len] > popperRect[len]) {\n mainVariationSide = getOppositePlacement(mainVariationSide);\n }\n\n var altVariationSide = getOppositePlacement(mainVariationSide);\n var checks = [];\n\n if (checkMainAxis) {\n checks.push(overflow[_basePlacement] <= 0);\n }\n\n if (checkAltAxis) {\n checks.push(overflow[mainVariationSide] <= 0, overflow[altVariationSide] <= 0);\n }\n\n if (checks.every(function (check) {\n return check;\n })) {\n firstFittingPlacement = placement;\n makeFallbackChecks = false;\n break;\n }\n\n checksMap.set(placement, checks);\n }\n\n if (makeFallbackChecks) {\n // `2` may be desired in some cases – research later\n var numberOfChecks = flipVariations ? 3 : 1;\n\n var _loop = function _loop(_i) {\n var fittingPlacement = placements.find(function (placement) {\n var checks = checksMap.get(placement);\n\n if (checks) {\n return checks.slice(0, _i).every(function (check) {\n return check;\n });\n }\n });\n\n if (fittingPlacement) {\n firstFittingPlacement = fittingPlacement;\n return \"break\";\n }\n };\n\n for (var _i = numberOfChecks; _i > 0; _i--) {\n var _ret = _loop(_i);\n\n if (_ret === \"break\") break;\n }\n }\n\n if (state.placement !== firstFittingPlacement) {\n state.modifiersData[name]._skip = true;\n state.placement = firstFittingPlacement;\n state.reset = true;\n }\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'flip',\n enabled: true,\n phase: 'main',\n fn: flip,\n requiresIfExists: ['offset'],\n data: {\n _skip: false\n }\n};","import { top, bottom, left, right } from \"../enums.js\";\nimport detectOverflow from \"../utils/detectOverflow.js\";\n\nfunction getSideOffsets(overflow, rect, preventedOffsets) {\n if (preventedOffsets === void 0) {\n preventedOffsets = {\n x: 0,\n y: 0\n };\n }\n\n return {\n top: overflow.top - rect.height - preventedOffsets.y,\n right: overflow.right - rect.width + preventedOffsets.x,\n bottom: overflow.bottom - rect.height + preventedOffsets.y,\n left: overflow.left - rect.width - preventedOffsets.x\n };\n}\n\nfunction isAnySideFullyClipped(overflow) {\n return [top, right, bottom, left].some(function (side) {\n return overflow[side] >= 0;\n });\n}\n\nfunction hide(_ref) {\n var state = _ref.state,\n name = _ref.name;\n var referenceRect = state.rects.reference;\n var popperRect = state.rects.popper;\n var preventedOffsets = state.modifiersData.preventOverflow;\n var referenceOverflow = detectOverflow(state, {\n elementContext: 'reference'\n });\n var popperAltOverflow = detectOverflow(state, {\n altBoundary: true\n });\n var referenceClippingOffsets = getSideOffsets(referenceOverflow, referenceRect);\n var popperEscapeOffsets = getSideOffsets(popperAltOverflow, popperRect, preventedOffsets);\n var isReferenceHidden = isAnySideFullyClipped(referenceClippingOffsets);\n var hasPopperEscaped = isAnySideFullyClipped(popperEscapeOffsets);\n state.modifiersData[name] = {\n referenceClippingOffsets: referenceClippingOffsets,\n popperEscapeOffsets: popperEscapeOffsets,\n isReferenceHidden: isReferenceHidden,\n hasPopperEscaped: hasPopperEscaped\n };\n state.attributes.popper = Object.assign({}, state.attributes.popper, {\n 'data-popper-reference-hidden': isReferenceHidden,\n 'data-popper-escaped': hasPopperEscaped\n });\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'hide',\n enabled: true,\n phase: 'main',\n requiresIfExists: ['preventOverflow'],\n fn: hide\n};","import getBasePlacement from \"../utils/getBasePlacement.js\";\nimport { top, left, right, placements } from \"../enums.js\"; // eslint-disable-next-line import/no-unused-modules\n\nexport function distanceAndSkiddingToXY(placement, rects, offset) {\n var basePlacement = getBasePlacement(placement);\n var invertDistance = [left, top].indexOf(basePlacement) >= 0 ? -1 : 1;\n\n var _ref = typeof offset === 'function' ? offset(Object.assign({}, rects, {\n placement: placement\n })) : offset,\n skidding = _ref[0],\n distance = _ref[1];\n\n skidding = skidding || 0;\n distance = (distance || 0) * invertDistance;\n return [left, right].indexOf(basePlacement) >= 0 ? {\n x: distance,\n y: skidding\n } : {\n x: skidding,\n y: distance\n };\n}\n\nfunction offset(_ref2) {\n var state = _ref2.state,\n options = _ref2.options,\n name = _ref2.name;\n var _options$offset = options.offset,\n offset = _options$offset === void 0 ? [0, 0] : _options$offset;\n var data = placements.reduce(function (acc, placement) {\n acc[placement] = distanceAndSkiddingToXY(placement, state.rects, offset);\n return acc;\n }, {});\n var _data$state$placement = data[state.placement],\n x = _data$state$placement.x,\n y = _data$state$placement.y;\n\n if (state.modifiersData.popperOffsets != null) {\n state.modifiersData.popperOffsets.x += x;\n state.modifiersData.popperOffsets.y += y;\n }\n\n state.modifiersData[name] = data;\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'offset',\n enabled: true,\n phase: 'main',\n requires: ['popperOffsets'],\n fn: offset\n};","import computeOffsets from \"../utils/computeOffsets.js\";\n\nfunction popperOffsets(_ref) {\n var state = _ref.state,\n name = _ref.name;\n // Offsets are the actual position the popper needs to have to be\n // properly positioned near its reference element\n // This is the most basic placement, and will be adjusted by\n // the modifiers in the next step\n state.modifiersData[name] = computeOffsets({\n reference: state.rects.reference,\n element: state.rects.popper,\n strategy: 'absolute',\n placement: state.placement\n });\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'popperOffsets',\n enabled: true,\n phase: 'read',\n fn: popperOffsets,\n data: {}\n};","export default function getAltAxis(axis) {\n return axis === 'x' ? 'y' : 'x';\n}","import { top, left, right, bottom, start } from \"../enums.js\";\nimport getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getMainAxisFromPlacement from \"../utils/getMainAxisFromPlacement.js\";\nimport getAltAxis from \"../utils/getAltAxis.js\";\nimport { within, withinMaxClamp } from \"../utils/within.js\";\nimport getLayoutRect from \"../dom-utils/getLayoutRect.js\";\nimport getOffsetParent from \"../dom-utils/getOffsetParent.js\";\nimport detectOverflow from \"../utils/detectOverflow.js\";\nimport getVariation from \"../utils/getVariation.js\";\nimport getFreshSideObject from \"../utils/getFreshSideObject.js\";\nimport { min as mathMin, max as mathMax } from \"../utils/math.js\";\n\nfunction preventOverflow(_ref) {\n var state = _ref.state,\n options = _ref.options,\n name = _ref.name;\n var _options$mainAxis = options.mainAxis,\n checkMainAxis = _options$mainAxis === void 0 ? true : _options$mainAxis,\n _options$altAxis = options.altAxis,\n checkAltAxis = _options$altAxis === void 0 ? false : _options$altAxis,\n boundary = options.boundary,\n rootBoundary = options.rootBoundary,\n altBoundary = options.altBoundary,\n padding = options.padding,\n _options$tether = options.tether,\n tether = _options$tether === void 0 ? true : _options$tether,\n _options$tetherOffset = options.tetherOffset,\n tetherOffset = _options$tetherOffset === void 0 ? 0 : _options$tetherOffset;\n var overflow = detectOverflow(state, {\n boundary: boundary,\n rootBoundary: rootBoundary,\n padding: padding,\n altBoundary: altBoundary\n });\n var basePlacement = getBasePlacement(state.placement);\n var variation = getVariation(state.placement);\n var isBasePlacement = !variation;\n var mainAxis = getMainAxisFromPlacement(basePlacement);\n var altAxis = getAltAxis(mainAxis);\n var popperOffsets = state.modifiersData.popperOffsets;\n var referenceRect = state.rects.reference;\n var popperRect = state.rects.popper;\n var tetherOffsetValue = typeof tetherOffset === 'function' ? tetherOffset(Object.assign({}, state.rects, {\n placement: state.placement\n })) : tetherOffset;\n var normalizedTetherOffsetValue = typeof tetherOffsetValue === 'number' ? {\n mainAxis: tetherOffsetValue,\n altAxis: tetherOffsetValue\n } : Object.assign({\n mainAxis: 0,\n altAxis: 0\n }, tetherOffsetValue);\n var offsetModifierState = state.modifiersData.offset ? state.modifiersData.offset[state.placement] : null;\n var data = {\n x: 0,\n y: 0\n };\n\n if (!popperOffsets) {\n return;\n }\n\n if (checkMainAxis) {\n var _offsetModifierState$;\n\n var mainSide = mainAxis === 'y' ? top : left;\n var altSide = mainAxis === 'y' ? bottom : right;\n var len = mainAxis === 'y' ? 'height' : 'width';\n var offset = popperOffsets[mainAxis];\n var min = offset + overflow[mainSide];\n var max = offset - overflow[altSide];\n var additive = tether ? -popperRect[len] / 2 : 0;\n var minLen = variation === start ? referenceRect[len] : popperRect[len];\n var maxLen = variation === start ? -popperRect[len] : -referenceRect[len]; // We need to include the arrow in the calculation so the arrow doesn't go\n // outside the reference bounds\n\n var arrowElement = state.elements.arrow;\n var arrowRect = tether && arrowElement ? getLayoutRect(arrowElement) : {\n width: 0,\n height: 0\n };\n var arrowPaddingObject = state.modifiersData['arrow#persistent'] ? state.modifiersData['arrow#persistent'].padding : getFreshSideObject();\n var arrowPaddingMin = arrowPaddingObject[mainSide];\n var arrowPaddingMax = arrowPaddingObject[altSide]; // If the reference length is smaller than the arrow length, we don't want\n // to include its full size in the calculation. If the reference is small\n // and near the edge of a boundary, the popper can overflow even if the\n // reference is not overflowing as well (e.g. virtual elements with no\n // width or height)\n\n var arrowLen = within(0, referenceRect[len], arrowRect[len]);\n var minOffset = isBasePlacement ? referenceRect[len] / 2 - additive - arrowLen - arrowPaddingMin - normalizedTetherOffsetValue.mainAxis : minLen - arrowLen - arrowPaddingMin - normalizedTetherOffsetValue.mainAxis;\n var maxOffset = isBasePlacement ? -referenceRect[len] / 2 + additive + arrowLen + arrowPaddingMax + normalizedTetherOffsetValue.mainAxis : maxLen + arrowLen + arrowPaddingMax + normalizedTetherOffsetValue.mainAxis;\n var arrowOffsetParent = state.elements.arrow && getOffsetParent(state.elements.arrow);\n var clientOffset = arrowOffsetParent ? mainAxis === 'y' ? arrowOffsetParent.clientTop || 0 : arrowOffsetParent.clientLeft || 0 : 0;\n var offsetModifierValue = (_offsetModifierState$ = offsetModifierState == null ? void 0 : offsetModifierState[mainAxis]) != null ? _offsetModifierState$ : 0;\n var tetherMin = offset + minOffset - offsetModifierValue - clientOffset;\n var tetherMax = offset + maxOffset - offsetModifierValue;\n var preventedOffset = within(tether ? mathMin(min, tetherMin) : min, offset, tether ? mathMax(max, tetherMax) : max);\n popperOffsets[mainAxis] = preventedOffset;\n data[mainAxis] = preventedOffset - offset;\n }\n\n if (checkAltAxis) {\n var _offsetModifierState$2;\n\n var _mainSide = mainAxis === 'x' ? top : left;\n\n var _altSide = mainAxis === 'x' ? bottom : right;\n\n var _offset = popperOffsets[altAxis];\n\n var _len = altAxis === 'y' ? 'height' : 'width';\n\n var _min = _offset + overflow[_mainSide];\n\n var _max = _offset - overflow[_altSide];\n\n var isOriginSide = [top, left].indexOf(basePlacement) !== -1;\n\n var _offsetModifierValue = (_offsetModifierState$2 = offsetModifierState == null ? void 0 : offsetModifierState[altAxis]) != null ? _offsetModifierState$2 : 0;\n\n var _tetherMin = isOriginSide ? _min : _offset - referenceRect[_len] - popperRect[_len] - _offsetModifierValue + normalizedTetherOffsetValue.altAxis;\n\n var _tetherMax = isOriginSide ? _offset + referenceRect[_len] + popperRect[_len] - _offsetModifierValue - normalizedTetherOffsetValue.altAxis : _max;\n\n var _preventedOffset = tether && isOriginSide ? withinMaxClamp(_tetherMin, _offset, _tetherMax) : within(tether ? _tetherMin : _min, _offset, tether ? _tetherMax : _max);\n\n popperOffsets[altAxis] = _preventedOffset;\n data[altAxis] = _preventedOffset - _offset;\n }\n\n state.modifiersData[name] = data;\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'preventOverflow',\n enabled: true,\n phase: 'main',\n fn: preventOverflow,\n requiresIfExists: ['offset']\n};","export default function getHTMLElementScroll(element) {\n return {\n scrollLeft: element.scrollLeft,\n scrollTop: element.scrollTop\n };\n}","import getWindowScroll from \"./getWindowScroll.js\";\nimport getWindow from \"./getWindow.js\";\nimport { isHTMLElement } from \"./instanceOf.js\";\nimport getHTMLElementScroll from \"./getHTMLElementScroll.js\";\nexport default function getNodeScroll(node) {\n if (node === getWindow(node) || !isHTMLElement(node)) {\n return getWindowScroll(node);\n } else {\n return getHTMLElementScroll(node);\n }\n}","import getBoundingClientRect from \"./getBoundingClientRect.js\";\nimport getNodeScroll from \"./getNodeScroll.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport { isHTMLElement } from \"./instanceOf.js\";\nimport getWindowScrollBarX from \"./getWindowScrollBarX.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport isScrollParent from \"./isScrollParent.js\";\nimport { round } from \"../utils/math.js\";\n\nfunction isElementScaled(element) {\n var rect = element.getBoundingClientRect();\n var scaleX = round(rect.width) / element.offsetWidth || 1;\n var scaleY = round(rect.height) / element.offsetHeight || 1;\n return scaleX !== 1 || scaleY !== 1;\n} // Returns the composite rect of an element relative to its offsetParent.\n// Composite means it takes into account transforms as well as layout.\n\n\nexport default function getCompositeRect(elementOrVirtualElement, offsetParent, isFixed) {\n if (isFixed === void 0) {\n isFixed = false;\n }\n\n var isOffsetParentAnElement = isHTMLElement(offsetParent);\n var offsetParentIsScaled = isHTMLElement(offsetParent) && isElementScaled(offsetParent);\n var documentElement = getDocumentElement(offsetParent);\n var rect = getBoundingClientRect(elementOrVirtualElement, offsetParentIsScaled, isFixed);\n var scroll = {\n scrollLeft: 0,\n scrollTop: 0\n };\n var offsets = {\n x: 0,\n y: 0\n };\n\n if (isOffsetParentAnElement || !isOffsetParentAnElement && !isFixed) {\n if (getNodeName(offsetParent) !== 'body' || // https://github.com/popperjs/popper-core/issues/1078\n isScrollParent(documentElement)) {\n scroll = getNodeScroll(offsetParent);\n }\n\n if (isHTMLElement(offsetParent)) {\n offsets = getBoundingClientRect(offsetParent, true);\n offsets.x += offsetParent.clientLeft;\n offsets.y += offsetParent.clientTop;\n } else if (documentElement) {\n offsets.x = getWindowScrollBarX(documentElement);\n }\n }\n\n return {\n x: rect.left + scroll.scrollLeft - offsets.x,\n y: rect.top + scroll.scrollTop - offsets.y,\n width: rect.width,\n height: rect.height\n };\n}","import { modifierPhases } from \"../enums.js\"; // source: https://stackoverflow.com/questions/49875255\n\nfunction order(modifiers) {\n var map = new Map();\n var visited = new Set();\n var result = [];\n modifiers.forEach(function (modifier) {\n map.set(modifier.name, modifier);\n }); // On visiting object, check for its dependencies and visit them recursively\n\n function sort(modifier) {\n visited.add(modifier.name);\n var requires = [].concat(modifier.requires || [], modifier.requiresIfExists || []);\n requires.forEach(function (dep) {\n if (!visited.has(dep)) {\n var depModifier = map.get(dep);\n\n if (depModifier) {\n sort(depModifier);\n }\n }\n });\n result.push(modifier);\n }\n\n modifiers.forEach(function (modifier) {\n if (!visited.has(modifier.name)) {\n // check for visited object\n sort(modifier);\n }\n });\n return result;\n}\n\nexport default function orderModifiers(modifiers) {\n // order based on dependencies\n var orderedModifiers = order(modifiers); // order based on phase\n\n return modifierPhases.reduce(function (acc, phase) {\n return acc.concat(orderedModifiers.filter(function (modifier) {\n return modifier.phase === phase;\n }));\n }, []);\n}","export default function debounce(fn) {\n var pending;\n return function () {\n if (!pending) {\n pending = new Promise(function (resolve) {\n Promise.resolve().then(function () {\n pending = undefined;\n resolve(fn());\n });\n });\n }\n\n return pending;\n };\n}","export default function mergeByName(modifiers) {\n var merged = modifiers.reduce(function (merged, current) {\n var existing = merged[current.name];\n merged[current.name] = existing ? Object.assign({}, existing, current, {\n options: Object.assign({}, existing.options, current.options),\n data: Object.assign({}, existing.data, current.data)\n }) : current;\n return merged;\n }, {}); // IE11 does not support Object.values\n\n return Object.keys(merged).map(function (key) {\n return merged[key];\n });\n}","import getCompositeRect from \"./dom-utils/getCompositeRect.js\";\nimport getLayoutRect from \"./dom-utils/getLayoutRect.js\";\nimport listScrollParents from \"./dom-utils/listScrollParents.js\";\nimport getOffsetParent from \"./dom-utils/getOffsetParent.js\";\nimport orderModifiers from \"./utils/orderModifiers.js\";\nimport debounce from \"./utils/debounce.js\";\nimport mergeByName from \"./utils/mergeByName.js\";\nimport detectOverflow from \"./utils/detectOverflow.js\";\nimport { isElement } from \"./dom-utils/instanceOf.js\";\nvar DEFAULT_OPTIONS = {\n placement: 'bottom',\n modifiers: [],\n strategy: 'absolute'\n};\n\nfunction areValidElements() {\n for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {\n args[_key] = arguments[_key];\n }\n\n return !args.some(function (element) {\n return !(element && typeof element.getBoundingClientRect === 'function');\n });\n}\n\nexport function popperGenerator(generatorOptions) {\n if (generatorOptions === void 0) {\n generatorOptions = {};\n }\n\n var _generatorOptions = generatorOptions,\n _generatorOptions$def = _generatorOptions.defaultModifiers,\n defaultModifiers = _generatorOptions$def === void 0 ? [] : _generatorOptions$def,\n _generatorOptions$def2 = _generatorOptions.defaultOptions,\n defaultOptions = _generatorOptions$def2 === void 0 ? DEFAULT_OPTIONS : _generatorOptions$def2;\n return function createPopper(reference, popper, options) {\n if (options === void 0) {\n options = defaultOptions;\n }\n\n var state = {\n placement: 'bottom',\n orderedModifiers: [],\n options: Object.assign({}, DEFAULT_OPTIONS, defaultOptions),\n modifiersData: {},\n elements: {\n reference: reference,\n popper: popper\n },\n attributes: {},\n styles: {}\n };\n var effectCleanupFns = [];\n var isDestroyed = false;\n var instance = {\n state: state,\n setOptions: function setOptions(setOptionsAction) {\n var options = typeof setOptionsAction === 'function' ? setOptionsAction(state.options) : setOptionsAction;\n cleanupModifierEffects();\n state.options = Object.assign({}, defaultOptions, state.options, options);\n state.scrollParents = {\n reference: isElement(reference) ? listScrollParents(reference) : reference.contextElement ? listScrollParents(reference.contextElement) : [],\n popper: listScrollParents(popper)\n }; // Orders the modifiers based on their dependencies and `phase`\n // properties\n\n var orderedModifiers = orderModifiers(mergeByName([].concat(defaultModifiers, state.options.modifiers))); // Strip out disabled modifiers\n\n state.orderedModifiers = orderedModifiers.filter(function (m) {\n return m.enabled;\n });\n runModifierEffects();\n return instance.update();\n },\n // Sync update – it will always be executed, even if not necessary. This\n // is useful for low frequency updates where sync behavior simplifies the\n // logic.\n // For high frequency updates (e.g. `resize` and `scroll` events), always\n // prefer the async Popper#update method\n forceUpdate: function forceUpdate() {\n if (isDestroyed) {\n return;\n }\n\n var _state$elements = state.elements,\n reference = _state$elements.reference,\n popper = _state$elements.popper; // Don't proceed if `reference` or `popper` are not valid elements\n // anymore\n\n if (!areValidElements(reference, popper)) {\n return;\n } // Store the reference and popper rects to be read by modifiers\n\n\n state.rects = {\n reference: getCompositeRect(reference, getOffsetParent(popper), state.options.strategy === 'fixed'),\n popper: getLayoutRect(popper)\n }; // Modifiers have the ability to reset the current update cycle. The\n // most common use case for this is the `flip` modifier changing the\n // placement, which then needs to re-run all the modifiers, because the\n // logic was previously ran for the previous placement and is therefore\n // stale/incorrect\n\n state.reset = false;\n state.placement = state.options.placement; // On each update cycle, the `modifiersData` property for each modifier\n // is filled with the initial data specified by the modifier. This means\n // it doesn't persist and is fresh on each update.\n // To ensure persistent data, use `${name}#persistent`\n\n state.orderedModifiers.forEach(function (modifier) {\n return state.modifiersData[modifier.name] = Object.assign({}, modifier.data);\n });\n\n for (var index = 0; index < state.orderedModifiers.length; index++) {\n if (state.reset === true) {\n state.reset = false;\n index = -1;\n continue;\n }\n\n var _state$orderedModifie = state.orderedModifiers[index],\n fn = _state$orderedModifie.fn,\n _state$orderedModifie2 = _state$orderedModifie.options,\n _options = _state$orderedModifie2 === void 0 ? {} : _state$orderedModifie2,\n name = _state$orderedModifie.name;\n\n if (typeof fn === 'function') {\n state = fn({\n state: state,\n options: _options,\n name: name,\n instance: instance\n }) || state;\n }\n }\n },\n // Async and optimistically optimized update – it will not be executed if\n // not necessary (debounced to run at most once-per-tick)\n update: debounce(function () {\n return new Promise(function (resolve) {\n instance.forceUpdate();\n resolve(state);\n });\n }),\n destroy: function destroy() {\n cleanupModifierEffects();\n isDestroyed = true;\n }\n };\n\n if (!areValidElements(reference, popper)) {\n return instance;\n }\n\n instance.setOptions(options).then(function (state) {\n if (!isDestroyed && options.onFirstUpdate) {\n options.onFirstUpdate(state);\n }\n }); // Modifiers have the ability to execute arbitrary code before the first\n // update cycle runs. They will be executed in the same order as the update\n // cycle. This is useful when a modifier adds some persistent data that\n // other modifiers need to use, but the modifier is run after the dependent\n // one.\n\n function runModifierEffects() {\n state.orderedModifiers.forEach(function (_ref) {\n var name = _ref.name,\n _ref$options = _ref.options,\n options = _ref$options === void 0 ? {} : _ref$options,\n effect = _ref.effect;\n\n if (typeof effect === 'function') {\n var cleanupFn = effect({\n state: state,\n name: name,\n instance: instance,\n options: options\n });\n\n var noopFn = function noopFn() {};\n\n effectCleanupFns.push(cleanupFn || noopFn);\n }\n });\n }\n\n function cleanupModifierEffects() {\n effectCleanupFns.forEach(function (fn) {\n return fn();\n });\n effectCleanupFns = [];\n }\n\n return instance;\n };\n}\nexport var createPopper = /*#__PURE__*/popperGenerator(); // eslint-disable-next-line import/no-unused-modules\n\nexport { detectOverflow };","import { popperGenerator, detectOverflow } from \"./createPopper.js\";\nimport eventListeners from \"./modifiers/eventListeners.js\";\nimport popperOffsets from \"./modifiers/popperOffsets.js\";\nimport computeStyles from \"./modifiers/computeStyles.js\";\nimport applyStyles from \"./modifiers/applyStyles.js\";\nimport offset from \"./modifiers/offset.js\";\nimport flip from \"./modifiers/flip.js\";\nimport preventOverflow from \"./modifiers/preventOverflow.js\";\nimport arrow from \"./modifiers/arrow.js\";\nimport hide from \"./modifiers/hide.js\";\nvar defaultModifiers = [eventListeners, popperOffsets, computeStyles, applyStyles, offset, flip, preventOverflow, arrow, hide];\nvar createPopper = /*#__PURE__*/popperGenerator({\n defaultModifiers: defaultModifiers\n}); // eslint-disable-next-line import/no-unused-modules\n\nexport { createPopper, popperGenerator, defaultModifiers, detectOverflow }; // eslint-disable-next-line import/no-unused-modules\n\nexport { createPopper as createPopperLite } from \"./popper-lite.js\"; // eslint-disable-next-line import/no-unused-modules\n\nexport * from \"./modifiers/index.js\";","import { generateUtilityClass } from '../generateUtilityClass';\nimport { generateUtilityClasses } from '../generateUtilityClasses';\nconst COMPONENT_NAME = 'Popper';\nexport function getPopperUtilityClass(slot) {\n return generateUtilityClass(COMPONENT_NAME, slot);\n}\nexport const popperClasses = generateUtilityClasses(COMPONENT_NAME, ['root']);","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"anchorEl\", \"children\", \"direction\", \"disablePortal\", \"modifiers\", \"open\", \"placement\", \"popperOptions\", \"popperRef\", \"slotProps\", \"slots\", \"TransitionProps\", \"ownerState\"],\n _excluded2 = [\"anchorEl\", \"children\", \"container\", \"direction\", \"disablePortal\", \"keepMounted\", \"modifiers\", \"open\", \"placement\", \"popperOptions\", \"popperRef\", \"style\", \"transition\", \"slotProps\", \"slots\"];\nimport * as React from 'react';\nimport { chainPropTypes, HTMLElementType, refType, unstable_ownerDocument as ownerDocument, unstable_useEnhancedEffect as useEnhancedEffect, unstable_useForkRef as useForkRef } from '@mui/utils';\nimport { createPopper } from '@popperjs/core';\nimport PropTypes from 'prop-types';\nimport { unstable_composeClasses as composeClasses } from '../composeClasses';\nimport { Portal } from '../Portal';\nimport { getPopperUtilityClass } from './popperClasses';\nimport { useSlotProps } from '../utils';\nimport { useClassNamesOverride } from '../utils/ClassNameConfigurator';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nfunction flipPlacement(placement, direction) {\n if (direction === 'ltr') {\n return placement;\n }\n switch (placement) {\n case 'bottom-end':\n return 'bottom-start';\n case 'bottom-start':\n return 'bottom-end';\n case 'top-end':\n return 'top-start';\n case 'top-start':\n return 'top-end';\n default:\n return placement;\n }\n}\nfunction resolveAnchorEl(anchorEl) {\n return typeof anchorEl === 'function' ? anchorEl() : anchorEl;\n}\nfunction isHTMLElement(element) {\n return element.nodeType !== undefined;\n}\nfunction isVirtualElement(element) {\n return !isHTMLElement(element);\n}\nconst useUtilityClasses = () => {\n const slots = {\n root: ['root']\n };\n return composeClasses(slots, useClassNamesOverride(getPopperUtilityClass));\n};\nconst defaultPopperOptions = {};\nconst PopperTooltip = /*#__PURE__*/React.forwardRef(function PopperTooltip(props, forwardedRef) {\n var _slots$root;\n const {\n anchorEl,\n children,\n direction,\n disablePortal,\n modifiers,\n open,\n placement: initialPlacement,\n popperOptions,\n popperRef: popperRefProp,\n slotProps = {},\n slots = {},\n TransitionProps\n // @ts-ignore internal logic\n // prevent from spreading to DOM, it can come from the parent component e.g. Select.\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const tooltipRef = React.useRef(null);\n const ownRef = useForkRef(tooltipRef, forwardedRef);\n const popperRef = React.useRef(null);\n const handlePopperRef = useForkRef(popperRef, popperRefProp);\n const handlePopperRefRef = React.useRef(handlePopperRef);\n useEnhancedEffect(() => {\n handlePopperRefRef.current = handlePopperRef;\n }, [handlePopperRef]);\n React.useImperativeHandle(popperRefProp, () => popperRef.current, []);\n const rtlPlacement = flipPlacement(initialPlacement, direction);\n /**\n * placement initialized from prop but can change during lifetime if modifiers.flip.\n * modifiers.flip is essentially a flip for controlled/uncontrolled behavior\n */\n const [placement, setPlacement] = React.useState(rtlPlacement);\n const [resolvedAnchorElement, setResolvedAnchorElement] = React.useState(resolveAnchorEl(anchorEl));\n React.useEffect(() => {\n if (popperRef.current) {\n popperRef.current.forceUpdate();\n }\n });\n React.useEffect(() => {\n if (anchorEl) {\n setResolvedAnchorElement(resolveAnchorEl(anchorEl));\n }\n }, [anchorEl]);\n useEnhancedEffect(() => {\n if (!resolvedAnchorElement || !open) {\n return undefined;\n }\n const handlePopperUpdate = data => {\n setPlacement(data.placement);\n };\n if (process.env.NODE_ENV !== 'production') {\n if (resolvedAnchorElement && isHTMLElement(resolvedAnchorElement) && resolvedAnchorElement.nodeType === 1) {\n const box = resolvedAnchorElement.getBoundingClientRect();\n if (process.env.NODE_ENV !== 'test' && box.top === 0 && box.left === 0 && box.right === 0 && box.bottom === 0) {\n console.warn(['MUI: The `anchorEl` prop provided to the component is invalid.', 'The anchor element should be part of the document layout.', \"Make sure the element is present in the document or that it's not display none.\"].join('\\n'));\n }\n }\n }\n let popperModifiers = [{\n name: 'preventOverflow',\n options: {\n altBoundary: disablePortal\n }\n }, {\n name: 'flip',\n options: {\n altBoundary: disablePortal\n }\n }, {\n name: 'onUpdate',\n enabled: true,\n phase: 'afterWrite',\n fn: ({\n state\n }) => {\n handlePopperUpdate(state);\n }\n }];\n if (modifiers != null) {\n popperModifiers = popperModifiers.concat(modifiers);\n }\n if (popperOptions && popperOptions.modifiers != null) {\n popperModifiers = popperModifiers.concat(popperOptions.modifiers);\n }\n const popper = createPopper(resolvedAnchorElement, tooltipRef.current, _extends({\n placement: rtlPlacement\n }, popperOptions, {\n modifiers: popperModifiers\n }));\n handlePopperRefRef.current(popper);\n return () => {\n popper.destroy();\n handlePopperRefRef.current(null);\n };\n }, [resolvedAnchorElement, disablePortal, modifiers, open, popperOptions, rtlPlacement]);\n const childProps = {\n placement: placement\n };\n if (TransitionProps !== null) {\n childProps.TransitionProps = TransitionProps;\n }\n const classes = useUtilityClasses();\n const Root = (_slots$root = slots.root) != null ? _slots$root : 'div';\n const rootProps = useSlotProps({\n elementType: Root,\n externalSlotProps: slotProps.root,\n externalForwardedProps: other,\n additionalProps: {\n role: 'tooltip',\n ref: ownRef\n },\n ownerState: props,\n className: classes.root\n });\n return /*#__PURE__*/_jsx(Root, _extends({}, rootProps, {\n children: typeof children === 'function' ? children(childProps) : children\n }));\n});\n\n/**\n * Poppers rely on the 3rd party library [Popper.js](https://popper.js.org/docs/v2/) for positioning.\n *\n * Demos:\n *\n * - [Popper](https://mui.com/base-ui/react-popper/)\n *\n * API:\n *\n * - [Popper API](https://mui.com/base-ui/react-popper/components-api/#popper)\n */\nconst Popper = /*#__PURE__*/React.forwardRef(function Popper(props, forwardedRef) {\n const {\n anchorEl,\n children,\n container: containerProp,\n direction = 'ltr',\n disablePortal = false,\n keepMounted = false,\n modifiers,\n open,\n placement = 'bottom',\n popperOptions = defaultPopperOptions,\n popperRef,\n style,\n transition = false,\n slotProps = {},\n slots = {}\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded2);\n const [exited, setExited] = React.useState(true);\n const handleEnter = () => {\n setExited(false);\n };\n const handleExited = () => {\n setExited(true);\n };\n if (!keepMounted && !open && (!transition || exited)) {\n return null;\n }\n\n // If the container prop is provided, use that\n // If the anchorEl prop is provided, use its parent body element as the container\n // If neither are provided let the Modal take care of choosing the container\n let container;\n if (containerProp) {\n container = containerProp;\n } else if (anchorEl) {\n const resolvedAnchorEl = resolveAnchorEl(anchorEl);\n container = resolvedAnchorEl && isHTMLElement(resolvedAnchorEl) ? ownerDocument(resolvedAnchorEl).body : ownerDocument(null).body;\n }\n const display = !open && keepMounted && (!transition || exited) ? 'none' : undefined;\n const transitionProps = transition ? {\n in: open,\n onEnter: handleEnter,\n onExited: handleExited\n } : undefined;\n return /*#__PURE__*/_jsx(Portal, {\n disablePortal: disablePortal,\n container: container,\n children: /*#__PURE__*/_jsx(PopperTooltip, _extends({\n anchorEl: anchorEl,\n direction: direction,\n disablePortal: disablePortal,\n modifiers: modifiers,\n ref: forwardedRef,\n open: transition ? !exited : open,\n placement: placement,\n popperOptions: popperOptions,\n popperRef: popperRef,\n slotProps: slotProps,\n slots: slots\n }, other, {\n style: _extends({\n // Prevents scroll issue, waiting for Popper.js to add this style once initiated.\n position: 'fixed',\n // Fix Popper.js display issue\n top: 0,\n left: 0,\n display\n }, style),\n TransitionProps: transitionProps,\n children: children\n }))\n });\n});\nprocess.env.NODE_ENV !== \"production\" ? Popper.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * An HTML element, [virtualElement](https://popper.js.org/docs/v2/virtual-elements/),\n * or a function that returns either.\n * It's used to set the position of the popper.\n * The return value will passed as the reference object of the Popper instance.\n */\n anchorEl: chainPropTypes(PropTypes.oneOfType([HTMLElementType, PropTypes.object, PropTypes.func]), props => {\n if (props.open) {\n const resolvedAnchorEl = resolveAnchorEl(props.anchorEl);\n if (resolvedAnchorEl && isHTMLElement(resolvedAnchorEl) && resolvedAnchorEl.nodeType === 1) {\n const box = resolvedAnchorEl.getBoundingClientRect();\n if (process.env.NODE_ENV !== 'test' && box.top === 0 && box.left === 0 && box.right === 0 && box.bottom === 0) {\n return new Error(['MUI: The `anchorEl` prop provided to the component is invalid.', 'The anchor element should be part of the document layout.', \"Make sure the element is present in the document or that it's not display none.\"].join('\\n'));\n }\n } else if (!resolvedAnchorEl || typeof resolvedAnchorEl.getBoundingClientRect !== 'function' || isVirtualElement(resolvedAnchorEl) && resolvedAnchorEl.contextElement != null && resolvedAnchorEl.contextElement.nodeType !== 1) {\n return new Error(['MUI: The `anchorEl` prop provided to the component is invalid.', 'It should be an HTML element instance or a virtualElement ', '(https://popper.js.org/docs/v2/virtual-elements/).'].join('\\n'));\n }\n }\n return null;\n }),\n /**\n * Popper render function or node.\n */\n children: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.node, PropTypes.func]),\n /**\n * An HTML element or function that returns one.\n * The `container` will have the portal children appended to it.\n *\n * You can also provide a callback, which is called in a React layout effect.\n * This lets you set the container from a ref, and also makes server-side rendering possible.\n *\n * By default, it uses the body of the top-level document object,\n * so it's simply `document.body` most of the time.\n */\n container: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.func]),\n /**\n * Direction of the text.\n * @default 'ltr'\n */\n direction: PropTypes.oneOf(['ltr', 'rtl']),\n /**\n * The `children` will be under the DOM hierarchy of the parent component.\n * @default false\n */\n disablePortal: PropTypes.bool,\n /**\n * Always keep the children in the DOM.\n * This prop can be useful in SEO situation or\n * when you want to maximize the responsiveness of the Popper.\n * @default false\n */\n keepMounted: PropTypes.bool,\n /**\n * Popper.js is based on a \"plugin-like\" architecture,\n * most of its features are fully encapsulated \"modifiers\".\n *\n * A modifier is a function that is called each time Popper.js needs to\n * compute the position of the popper.\n * For this reason, modifiers should be very performant to avoid bottlenecks.\n * To learn how to create a modifier, [read the modifiers documentation](https://popper.js.org/docs/v2/modifiers/).\n */\n modifiers: PropTypes.arrayOf(PropTypes.shape({\n data: PropTypes.object,\n effect: PropTypes.func,\n enabled: PropTypes.bool,\n fn: PropTypes.func,\n name: PropTypes.any,\n options: PropTypes.object,\n phase: PropTypes.oneOf(['afterMain', 'afterRead', 'afterWrite', 'beforeMain', 'beforeRead', 'beforeWrite', 'main', 'read', 'write']),\n requires: PropTypes.arrayOf(PropTypes.string),\n requiresIfExists: PropTypes.arrayOf(PropTypes.string)\n })),\n /**\n * If `true`, the component is shown.\n */\n open: PropTypes.bool.isRequired,\n /**\n * Popper placement.\n * @default 'bottom'\n */\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n /**\n * Options provided to the [`Popper.js`](https://popper.js.org/docs/v2/constructors/#options) instance.\n * @default {}\n */\n popperOptions: PropTypes.shape({\n modifiers: PropTypes.array,\n onFirstUpdate: PropTypes.func,\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n strategy: PropTypes.oneOf(['absolute', 'fixed'])\n }),\n /**\n * A ref that points to the used popper instance.\n */\n popperRef: refType,\n /**\n * The props used for each slot inside the Popper.\n * @default {}\n */\n slotProps: PropTypes.shape({\n root: PropTypes.oneOfType([PropTypes.func, PropTypes.object])\n }),\n /**\n * The components used for each slot inside the Popper.\n * Either a string to use a HTML element or a component.\n * @default {}\n */\n slots: PropTypes.shape({\n root: PropTypes.elementType\n }),\n /**\n * Help supporting a react-transition-group/Transition component.\n * @default false\n */\n transition: PropTypes.bool\n} : void 0;\nexport { Popper };","'use client';\n\nimport * as React from 'react';\nimport { useTheme as useThemeSystem } from '@mui/system';\nimport defaultTheme from './defaultTheme';\nimport THEME_ID from './identifier';\nexport default function useTheme() {\n const theme = useThemeSystem(defaultTheme);\n if (process.env.NODE_ENV !== 'production') {\n // eslint-disable-next-line react-hooks/rules-of-hooks\n React.useDebugValue(theme);\n }\n return theme[THEME_ID] || theme;\n}","export default function _setPrototypeOf(o, p) {\n _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function _setPrototypeOf(o, p) {\n o.__proto__ = p;\n return o;\n };\n return _setPrototypeOf(o, p);\n}","import setPrototypeOf from \"./setPrototypeOf.js\";\nexport default function _inheritsLoose(subClass, superClass) {\n subClass.prototype = Object.create(superClass.prototype);\n subClass.prototype.constructor = subClass;\n setPrototypeOf(subClass, superClass);\n}","export default {\n disabled: false\n};","import PropTypes from 'prop-types';\nexport var timeoutsShape = process.env.NODE_ENV !== 'production' ? PropTypes.oneOfType([PropTypes.number, PropTypes.shape({\n enter: PropTypes.number,\n exit: PropTypes.number,\n appear: PropTypes.number\n}).isRequired]) : null;\nexport var classNamesShape = process.env.NODE_ENV !== 'production' ? PropTypes.oneOfType([PropTypes.string, PropTypes.shape({\n enter: PropTypes.string,\n exit: PropTypes.string,\n active: PropTypes.string\n}), PropTypes.shape({\n enter: PropTypes.string,\n enterDone: PropTypes.string,\n enterActive: PropTypes.string,\n exit: PropTypes.string,\n exitDone: PropTypes.string,\n exitActive: PropTypes.string\n})]) : null;","import React from 'react';\nexport default React.createContext(null);","export var forceReflow = function forceReflow(node) {\n return node.scrollTop;\n};","import _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _inheritsLoose from \"@babel/runtime/helpers/esm/inheritsLoose\";\nimport PropTypes from 'prop-types';\nimport React from 'react';\nimport ReactDOM from 'react-dom';\nimport config from './config';\nimport { timeoutsShape } from './utils/PropTypes';\nimport TransitionGroupContext from './TransitionGroupContext';\nimport { forceReflow } from './utils/reflow';\nexport var UNMOUNTED = 'unmounted';\nexport var EXITED = 'exited';\nexport var ENTERING = 'entering';\nexport var ENTERED = 'entered';\nexport var EXITING = 'exiting';\n/**\n * The Transition component lets you describe a transition from one component\n * state to another _over time_ with a simple declarative API. Most commonly\n * it's used to animate the mounting and unmounting of a component, but can also\n * be used to describe in-place transition states as well.\n *\n * ---\n *\n * **Note**: `Transition` is a platform-agnostic base component. If you're using\n * transitions in CSS, you'll probably want to use\n * [`CSSTransition`](https://reactcommunity.org/react-transition-group/css-transition)\n * instead. It inherits all the features of `Transition`, but contains\n * additional features necessary to play nice with CSS transitions (hence the\n * name of the component).\n *\n * ---\n *\n * By default the `Transition` component does not alter the behavior of the\n * component it renders, it only tracks \"enter\" and \"exit\" states for the\n * components. It's up to you to give meaning and effect to those states. For\n * example we can add styles to a component when it enters or exits:\n *\n * ```jsx\n * import { Transition } from 'react-transition-group';\n *\n * const duration = 300;\n *\n * const defaultStyle = {\n * transition: `opacity ${duration}ms ease-in-out`,\n * opacity: 0,\n * }\n *\n * const transitionStyles = {\n * entering: { opacity: 1 },\n * entered: { opacity: 1 },\n * exiting: { opacity: 0 },\n * exited: { opacity: 0 },\n * };\n *\n * const Fade = ({ in: inProp }) => (\n * \n * {state => (\n *
    \n * I'm a fade Transition!\n *
    \n * )}\n *
    \n * );\n * ```\n *\n * There are 4 main states a Transition can be in:\n * - `'entering'`\n * - `'entered'`\n * - `'exiting'`\n * - `'exited'`\n *\n * Transition state is toggled via the `in` prop. When `true` the component\n * begins the \"Enter\" stage. During this stage, the component will shift from\n * its current transition state, to `'entering'` for the duration of the\n * transition and then to the `'entered'` stage once it's complete. Let's take\n * the following example (we'll use the\n * [useState](https://reactjs.org/docs/hooks-reference.html#usestate) hook):\n *\n * ```jsx\n * function App() {\n * const [inProp, setInProp] = useState(false);\n * return (\n *
    \n * \n * {state => (\n * // ...\n * )}\n * \n * \n *
    \n * );\n * }\n * ```\n *\n * When the button is clicked the component will shift to the `'entering'` state\n * and stay there for 500ms (the value of `timeout`) before it finally switches\n * to `'entered'`.\n *\n * When `in` is `false` the same thing happens except the state moves from\n * `'exiting'` to `'exited'`.\n */\n\nvar Transition = /*#__PURE__*/function (_React$Component) {\n _inheritsLoose(Transition, _React$Component);\n\n function Transition(props, context) {\n var _this;\n\n _this = _React$Component.call(this, props, context) || this;\n var parentGroup = context; // In the context of a TransitionGroup all enters are really appears\n\n var appear = parentGroup && !parentGroup.isMounting ? props.enter : props.appear;\n var initialStatus;\n _this.appearStatus = null;\n\n if (props.in) {\n if (appear) {\n initialStatus = EXITED;\n _this.appearStatus = ENTERING;\n } else {\n initialStatus = ENTERED;\n }\n } else {\n if (props.unmountOnExit || props.mountOnEnter) {\n initialStatus = UNMOUNTED;\n } else {\n initialStatus = EXITED;\n }\n }\n\n _this.state = {\n status: initialStatus\n };\n _this.nextCallback = null;\n return _this;\n }\n\n Transition.getDerivedStateFromProps = function getDerivedStateFromProps(_ref, prevState) {\n var nextIn = _ref.in;\n\n if (nextIn && prevState.status === UNMOUNTED) {\n return {\n status: EXITED\n };\n }\n\n return null;\n } // getSnapshotBeforeUpdate(prevProps) {\n // let nextStatus = null\n // if (prevProps !== this.props) {\n // const { status } = this.state\n // if (this.props.in) {\n // if (status !== ENTERING && status !== ENTERED) {\n // nextStatus = ENTERING\n // }\n // } else {\n // if (status === ENTERING || status === ENTERED) {\n // nextStatus = EXITING\n // }\n // }\n // }\n // return { nextStatus }\n // }\n ;\n\n var _proto = Transition.prototype;\n\n _proto.componentDidMount = function componentDidMount() {\n this.updateStatus(true, this.appearStatus);\n };\n\n _proto.componentDidUpdate = function componentDidUpdate(prevProps) {\n var nextStatus = null;\n\n if (prevProps !== this.props) {\n var status = this.state.status;\n\n if (this.props.in) {\n if (status !== ENTERING && status !== ENTERED) {\n nextStatus = ENTERING;\n }\n } else {\n if (status === ENTERING || status === ENTERED) {\n nextStatus = EXITING;\n }\n }\n }\n\n this.updateStatus(false, nextStatus);\n };\n\n _proto.componentWillUnmount = function componentWillUnmount() {\n this.cancelNextCallback();\n };\n\n _proto.getTimeouts = function getTimeouts() {\n var timeout = this.props.timeout;\n var exit, enter, appear;\n exit = enter = appear = timeout;\n\n if (timeout != null && typeof timeout !== 'number') {\n exit = timeout.exit;\n enter = timeout.enter; // TODO: remove fallback for next major\n\n appear = timeout.appear !== undefined ? timeout.appear : enter;\n }\n\n return {\n exit: exit,\n enter: enter,\n appear: appear\n };\n };\n\n _proto.updateStatus = function updateStatus(mounting, nextStatus) {\n if (mounting === void 0) {\n mounting = false;\n }\n\n if (nextStatus !== null) {\n // nextStatus will always be ENTERING or EXITING.\n this.cancelNextCallback();\n\n if (nextStatus === ENTERING) {\n if (this.props.unmountOnExit || this.props.mountOnEnter) {\n var node = this.props.nodeRef ? this.props.nodeRef.current : ReactDOM.findDOMNode(this); // https://github.com/reactjs/react-transition-group/pull/749\n // With unmountOnExit or mountOnEnter, the enter animation should happen at the transition between `exited` and `entering`.\n // To make the animation happen, we have to separate each rendering and avoid being processed as batched.\n\n if (node) forceReflow(node);\n }\n\n this.performEnter(mounting);\n } else {\n this.performExit();\n }\n } else if (this.props.unmountOnExit && this.state.status === EXITED) {\n this.setState({\n status: UNMOUNTED\n });\n }\n };\n\n _proto.performEnter = function performEnter(mounting) {\n var _this2 = this;\n\n var enter = this.props.enter;\n var appearing = this.context ? this.context.isMounting : mounting;\n\n var _ref2 = this.props.nodeRef ? [appearing] : [ReactDOM.findDOMNode(this), appearing],\n maybeNode = _ref2[0],\n maybeAppearing = _ref2[1];\n\n var timeouts = this.getTimeouts();\n var enterTimeout = appearing ? timeouts.appear : timeouts.enter; // no enter animation skip right to ENTERED\n // if we are mounting and running this it means appear _must_ be set\n\n if (!mounting && !enter || config.disabled) {\n this.safeSetState({\n status: ENTERED\n }, function () {\n _this2.props.onEntered(maybeNode);\n });\n return;\n }\n\n this.props.onEnter(maybeNode, maybeAppearing);\n this.safeSetState({\n status: ENTERING\n }, function () {\n _this2.props.onEntering(maybeNode, maybeAppearing);\n\n _this2.onTransitionEnd(enterTimeout, function () {\n _this2.safeSetState({\n status: ENTERED\n }, function () {\n _this2.props.onEntered(maybeNode, maybeAppearing);\n });\n });\n });\n };\n\n _proto.performExit = function performExit() {\n var _this3 = this;\n\n var exit = this.props.exit;\n var timeouts = this.getTimeouts();\n var maybeNode = this.props.nodeRef ? undefined : ReactDOM.findDOMNode(this); // no exit animation skip right to EXITED\n\n if (!exit || config.disabled) {\n this.safeSetState({\n status: EXITED\n }, function () {\n _this3.props.onExited(maybeNode);\n });\n return;\n }\n\n this.props.onExit(maybeNode);\n this.safeSetState({\n status: EXITING\n }, function () {\n _this3.props.onExiting(maybeNode);\n\n _this3.onTransitionEnd(timeouts.exit, function () {\n _this3.safeSetState({\n status: EXITED\n }, function () {\n _this3.props.onExited(maybeNode);\n });\n });\n });\n };\n\n _proto.cancelNextCallback = function cancelNextCallback() {\n if (this.nextCallback !== null) {\n this.nextCallback.cancel();\n this.nextCallback = null;\n }\n };\n\n _proto.safeSetState = function safeSetState(nextState, callback) {\n // This shouldn't be necessary, but there are weird race conditions with\n // setState callbacks and unmounting in testing, so always make sure that\n // we can cancel any pending setState callbacks after we unmount.\n callback = this.setNextCallback(callback);\n this.setState(nextState, callback);\n };\n\n _proto.setNextCallback = function setNextCallback(callback) {\n var _this4 = this;\n\n var active = true;\n\n this.nextCallback = function (event) {\n if (active) {\n active = false;\n _this4.nextCallback = null;\n callback(event);\n }\n };\n\n this.nextCallback.cancel = function () {\n active = false;\n };\n\n return this.nextCallback;\n };\n\n _proto.onTransitionEnd = function onTransitionEnd(timeout, handler) {\n this.setNextCallback(handler);\n var node = this.props.nodeRef ? this.props.nodeRef.current : ReactDOM.findDOMNode(this);\n var doesNotHaveTimeoutOrListener = timeout == null && !this.props.addEndListener;\n\n if (!node || doesNotHaveTimeoutOrListener) {\n setTimeout(this.nextCallback, 0);\n return;\n }\n\n if (this.props.addEndListener) {\n var _ref3 = this.props.nodeRef ? [this.nextCallback] : [node, this.nextCallback],\n maybeNode = _ref3[0],\n maybeNextCallback = _ref3[1];\n\n this.props.addEndListener(maybeNode, maybeNextCallback);\n }\n\n if (timeout != null) {\n setTimeout(this.nextCallback, timeout);\n }\n };\n\n _proto.render = function render() {\n var status = this.state.status;\n\n if (status === UNMOUNTED) {\n return null;\n }\n\n var _this$props = this.props,\n children = _this$props.children,\n _in = _this$props.in,\n _mountOnEnter = _this$props.mountOnEnter,\n _unmountOnExit = _this$props.unmountOnExit,\n _appear = _this$props.appear,\n _enter = _this$props.enter,\n _exit = _this$props.exit,\n _timeout = _this$props.timeout,\n _addEndListener = _this$props.addEndListener,\n _onEnter = _this$props.onEnter,\n _onEntering = _this$props.onEntering,\n _onEntered = _this$props.onEntered,\n _onExit = _this$props.onExit,\n _onExiting = _this$props.onExiting,\n _onExited = _this$props.onExited,\n _nodeRef = _this$props.nodeRef,\n childProps = _objectWithoutPropertiesLoose(_this$props, [\"children\", \"in\", \"mountOnEnter\", \"unmountOnExit\", \"appear\", \"enter\", \"exit\", \"timeout\", \"addEndListener\", \"onEnter\", \"onEntering\", \"onEntered\", \"onExit\", \"onExiting\", \"onExited\", \"nodeRef\"]);\n\n return (\n /*#__PURE__*/\n // allows for nested Transitions\n React.createElement(TransitionGroupContext.Provider, {\n value: null\n }, typeof children === 'function' ? children(status, childProps) : React.cloneElement(React.Children.only(children), childProps))\n );\n };\n\n return Transition;\n}(React.Component);\n\nTransition.contextType = TransitionGroupContext;\nTransition.propTypes = process.env.NODE_ENV !== \"production\" ? {\n /**\n * A React reference to DOM element that need to transition:\n * https://stackoverflow.com/a/51127130/4671932\n *\n * - When `nodeRef` prop is used, `node` is not passed to callback functions\n * (e.g. `onEnter`) because user already has direct access to the node.\n * - When changing `key` prop of `Transition` in a `TransitionGroup` a new\n * `nodeRef` need to be provided to `Transition` with changed `key` prop\n * (see\n * [test/CSSTransition-test.js](https://github.com/reactjs/react-transition-group/blob/13435f897b3ab71f6e19d724f145596f5910581c/test/CSSTransition-test.js#L362-L437)).\n */\n nodeRef: PropTypes.shape({\n current: typeof Element === 'undefined' ? PropTypes.any : function (propValue, key, componentName, location, propFullName, secret) {\n var value = propValue[key];\n return PropTypes.instanceOf(value && 'ownerDocument' in value ? value.ownerDocument.defaultView.Element : Element)(propValue, key, componentName, location, propFullName, secret);\n }\n }),\n\n /**\n * A `function` child can be used instead of a React element. This function is\n * called with the current transition status (`'entering'`, `'entered'`,\n * `'exiting'`, `'exited'`), which can be used to apply context\n * specific props to a component.\n *\n * ```jsx\n * \n * {state => (\n * \n * )}\n * \n * ```\n */\n children: PropTypes.oneOfType([PropTypes.func.isRequired, PropTypes.element.isRequired]).isRequired,\n\n /**\n * Show the component; triggers the enter or exit states\n */\n in: PropTypes.bool,\n\n /**\n * By default the child component is mounted immediately along with\n * the parent `Transition` component. If you want to \"lazy mount\" the component on the\n * first `in={true}` you can set `mountOnEnter`. After the first enter transition the component will stay\n * mounted, even on \"exited\", unless you also specify `unmountOnExit`.\n */\n mountOnEnter: PropTypes.bool,\n\n /**\n * By default the child component stays mounted after it reaches the `'exited'` state.\n * Set `unmountOnExit` if you'd prefer to unmount the component after it finishes exiting.\n */\n unmountOnExit: PropTypes.bool,\n\n /**\n * By default the child component does not perform the enter transition when\n * it first mounts, regardless of the value of `in`. If you want this\n * behavior, set both `appear` and `in` to `true`.\n *\n * > **Note**: there are no special appear states like `appearing`/`appeared`, this prop\n * > only adds an additional enter transition. However, in the\n * > `` component that first enter transition does result in\n * > additional `.appear-*` classes, that way you can choose to style it\n * > differently.\n */\n appear: PropTypes.bool,\n\n /**\n * Enable or disable enter transitions.\n */\n enter: PropTypes.bool,\n\n /**\n * Enable or disable exit transitions.\n */\n exit: PropTypes.bool,\n\n /**\n * The duration of the transition, in milliseconds.\n * Required unless `addEndListener` is provided.\n *\n * You may specify a single timeout for all transitions:\n *\n * ```jsx\n * timeout={500}\n * ```\n *\n * or individually:\n *\n * ```jsx\n * timeout={{\n * appear: 500,\n * enter: 300,\n * exit: 500,\n * }}\n * ```\n *\n * - `appear` defaults to the value of `enter`\n * - `enter` defaults to `0`\n * - `exit` defaults to `0`\n *\n * @type {number | { enter?: number, exit?: number, appear?: number }}\n */\n timeout: function timeout(props) {\n var pt = timeoutsShape;\n if (!props.addEndListener) pt = pt.isRequired;\n\n for (var _len = arguments.length, args = new Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) {\n args[_key - 1] = arguments[_key];\n }\n\n return pt.apply(void 0, [props].concat(args));\n },\n\n /**\n * Add a custom transition end trigger. Called with the transitioning\n * DOM node and a `done` callback. Allows for more fine grained transition end\n * logic. Timeouts are still used as a fallback if provided.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * ```jsx\n * addEndListener={(node, done) => {\n * // use the css transitionend event to mark the finish of a transition\n * node.addEventListener('transitionend', done, false);\n * }}\n * ```\n */\n addEndListener: PropTypes.func,\n\n /**\n * Callback fired before the \"entering\" status is applied. An extra parameter\n * `isAppearing` is supplied to indicate if the enter stage is occurring on the initial mount\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement, isAppearing: bool) -> void\n */\n onEnter: PropTypes.func,\n\n /**\n * Callback fired after the \"entering\" status is applied. An extra parameter\n * `isAppearing` is supplied to indicate if the enter stage is occurring on the initial mount\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement, isAppearing: bool)\n */\n onEntering: PropTypes.func,\n\n /**\n * Callback fired after the \"entered\" status is applied. An extra parameter\n * `isAppearing` is supplied to indicate if the enter stage is occurring on the initial mount\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement, isAppearing: bool) -> void\n */\n onEntered: PropTypes.func,\n\n /**\n * Callback fired before the \"exiting\" status is applied.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement) -> void\n */\n onExit: PropTypes.func,\n\n /**\n * Callback fired after the \"exiting\" status is applied.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement) -> void\n */\n onExiting: PropTypes.func,\n\n /**\n * Callback fired after the \"exited\" status is applied.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed\n *\n * @type Function(node: HtmlElement) -> void\n */\n onExited: PropTypes.func\n} : {}; // Name the function so it is clearer in the documentation\n\nfunction noop() {}\n\nTransition.defaultProps = {\n in: false,\n mountOnEnter: false,\n unmountOnExit: false,\n appear: false,\n enter: true,\n exit: true,\n onEnter: noop,\n onEntering: noop,\n onEntered: noop,\n onExit: noop,\n onExiting: noop,\n onExited: noop\n};\nTransition.UNMOUNTED = UNMOUNTED;\nTransition.EXITED = EXITED;\nTransition.ENTERING = ENTERING;\nTransition.ENTERED = ENTERED;\nTransition.EXITING = EXITING;\nexport default Transition;","export const reflow = node => node.scrollTop;\nexport function getTransitionProps(props, options) {\n var _style$transitionDura, _style$transitionTimi;\n const {\n timeout,\n easing,\n style = {}\n } = props;\n return {\n duration: (_style$transitionDura = style.transitionDuration) != null ? _style$transitionDura : typeof timeout === 'number' ? timeout : timeout[options.mode] || 0,\n easing: (_style$transitionTimi = style.transitionTimingFunction) != null ? _style$transitionTimi : typeof easing === 'object' ? easing[options.mode] : easing,\n delay: style.transitionDelay\n };\n}","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"addEndListener\", \"appear\", \"children\", \"easing\", \"in\", \"onEnter\", \"onEntered\", \"onEntering\", \"onExit\", \"onExited\", \"onExiting\", \"style\", \"timeout\", \"TransitionComponent\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport { elementAcceptingRef, unstable_useTimeout as useTimeout } from '@mui/utils';\nimport { Transition } from 'react-transition-group';\nimport useTheme from '../styles/useTheme';\nimport { getTransitionProps, reflow } from '../transitions/utils';\nimport useForkRef from '../utils/useForkRef';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nfunction getScale(value) {\n return `scale(${value}, ${value ** 2})`;\n}\nconst styles = {\n entering: {\n opacity: 1,\n transform: getScale(1)\n },\n entered: {\n opacity: 1,\n transform: 'none'\n }\n};\n\n/*\n TODO v6: remove\n Conditionally apply a workaround for the CSS transition bug in Safari 15.4 / WebKit browsers.\n */\nconst isWebKit154 = typeof navigator !== 'undefined' && /^((?!chrome|android).)*(safari|mobile)/i.test(navigator.userAgent) && /(os |version\\/)15(.|_)4/i.test(navigator.userAgent);\n\n/**\n * The Grow transition is used by the [Tooltip](/material-ui/react-tooltip/) and\n * [Popover](/material-ui/react-popover/) components.\n * It uses [react-transition-group](https://github.com/reactjs/react-transition-group) internally.\n */\nconst Grow = /*#__PURE__*/React.forwardRef(function Grow(props, ref) {\n const {\n addEndListener,\n appear = true,\n children,\n easing,\n in: inProp,\n onEnter,\n onEntered,\n onEntering,\n onExit,\n onExited,\n onExiting,\n style,\n timeout = 'auto',\n // eslint-disable-next-line react/prop-types\n TransitionComponent = Transition\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const timer = useTimeout();\n const autoTimeout = React.useRef();\n const theme = useTheme();\n const nodeRef = React.useRef(null);\n const handleRef = useForkRef(nodeRef, children.ref, ref);\n const normalizedTransitionCallback = callback => maybeIsAppearing => {\n if (callback) {\n const node = nodeRef.current;\n\n // onEnterXxx and onExitXxx callbacks have a different arguments.length value.\n if (maybeIsAppearing === undefined) {\n callback(node);\n } else {\n callback(node, maybeIsAppearing);\n }\n }\n };\n const handleEntering = normalizedTransitionCallback(onEntering);\n const handleEnter = normalizedTransitionCallback((node, isAppearing) => {\n reflow(node); // So the animation always start from the start.\n\n const {\n duration: transitionDuration,\n delay,\n easing: transitionTimingFunction\n } = getTransitionProps({\n style,\n timeout,\n easing\n }, {\n mode: 'enter'\n });\n let duration;\n if (timeout === 'auto') {\n duration = theme.transitions.getAutoHeightDuration(node.clientHeight);\n autoTimeout.current = duration;\n } else {\n duration = transitionDuration;\n }\n node.style.transition = [theme.transitions.create('opacity', {\n duration,\n delay\n }), theme.transitions.create('transform', {\n duration: isWebKit154 ? duration : duration * 0.666,\n delay,\n easing: transitionTimingFunction\n })].join(',');\n if (onEnter) {\n onEnter(node, isAppearing);\n }\n });\n const handleEntered = normalizedTransitionCallback(onEntered);\n const handleExiting = normalizedTransitionCallback(onExiting);\n const handleExit = normalizedTransitionCallback(node => {\n const {\n duration: transitionDuration,\n delay,\n easing: transitionTimingFunction\n } = getTransitionProps({\n style,\n timeout,\n easing\n }, {\n mode: 'exit'\n });\n let duration;\n if (timeout === 'auto') {\n duration = theme.transitions.getAutoHeightDuration(node.clientHeight);\n autoTimeout.current = duration;\n } else {\n duration = transitionDuration;\n }\n node.style.transition = [theme.transitions.create('opacity', {\n duration,\n delay\n }), theme.transitions.create('transform', {\n duration: isWebKit154 ? duration : duration * 0.666,\n delay: isWebKit154 ? delay : delay || duration * 0.333,\n easing: transitionTimingFunction\n })].join(',');\n node.style.opacity = 0;\n node.style.transform = getScale(0.75);\n if (onExit) {\n onExit(node);\n }\n });\n const handleExited = normalizedTransitionCallback(onExited);\n const handleAddEndListener = next => {\n if (timeout === 'auto') {\n timer.start(autoTimeout.current || 0, next);\n }\n if (addEndListener) {\n // Old call signature before `react-transition-group` implemented `nodeRef`\n addEndListener(nodeRef.current, next);\n }\n };\n return /*#__PURE__*/_jsx(TransitionComponent, _extends({\n appear: appear,\n in: inProp,\n nodeRef: nodeRef,\n onEnter: handleEnter,\n onEntered: handleEntered,\n onEntering: handleEntering,\n onExit: handleExit,\n onExited: handleExited,\n onExiting: handleExiting,\n addEndListener: handleAddEndListener,\n timeout: timeout === 'auto' ? null : timeout\n }, other, {\n children: (state, childProps) => {\n return /*#__PURE__*/React.cloneElement(children, _extends({\n style: _extends({\n opacity: 0,\n transform: getScale(0.75),\n visibility: state === 'exited' && !inProp ? 'hidden' : undefined\n }, styles[state], style, children.props.style),\n ref: handleRef\n }, childProps));\n }\n }));\n});\nprocess.env.NODE_ENV !== \"production\" ? Grow.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the d.ts file and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * Add a custom transition end trigger. Called with the transitioning DOM\n * node and a done callback. Allows for more fine grained transition end\n * logic. Note: Timeouts are still used as a fallback if provided.\n */\n addEndListener: PropTypes.func,\n /**\n * Perform the enter transition when it first mounts if `in` is also `true`.\n * Set this to `false` to disable this behavior.\n * @default true\n */\n appear: PropTypes.bool,\n /**\n * A single child content element.\n */\n children: elementAcceptingRef.isRequired,\n /**\n * The transition timing function.\n * You may specify a single easing or a object containing enter and exit values.\n */\n easing: PropTypes.oneOfType([PropTypes.shape({\n enter: PropTypes.string,\n exit: PropTypes.string\n }), PropTypes.string]),\n /**\n * If `true`, the component will transition in.\n */\n in: PropTypes.bool,\n /**\n * @ignore\n */\n onEnter: PropTypes.func,\n /**\n * @ignore\n */\n onEntered: PropTypes.func,\n /**\n * @ignore\n */\n onEntering: PropTypes.func,\n /**\n * @ignore\n */\n onExit: PropTypes.func,\n /**\n * @ignore\n */\n onExited: PropTypes.func,\n /**\n * @ignore\n */\n onExiting: PropTypes.func,\n /**\n * @ignore\n */\n style: PropTypes.object,\n /**\n * The duration for the transition, in milliseconds.\n * You may specify a single timeout for all transitions, or individually with an object.\n *\n * Set to 'auto' to automatically calculate transition time based on height.\n * @default 'auto'\n */\n timeout: PropTypes.oneOfType([PropTypes.oneOf(['auto']), PropTypes.number, PropTypes.shape({\n appear: PropTypes.number,\n enter: PropTypes.number,\n exit: PropTypes.number\n })])\n} : void 0;\nGrow.muiSupportAuto = true;\nexport default Grow;","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"anchorEl\", \"component\", \"components\", \"componentsProps\", \"container\", \"disablePortal\", \"keepMounted\", \"modifiers\", \"open\", \"placement\", \"popperOptions\", \"popperRef\", \"transition\", \"slots\", \"slotProps\"];\nimport { Popper as BasePopper } from '@mui/base/Popper';\nimport { useThemeWithoutDefault as useTheme } from '@mui/system';\nimport { HTMLElementType, refType } from '@mui/utils';\nimport PropTypes from 'prop-types';\nimport * as React from 'react';\nimport { styled, useThemeProps } from '../styles';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nconst PopperRoot = styled(BasePopper, {\n name: 'MuiPopper',\n slot: 'Root',\n overridesResolver: (props, styles) => styles.root\n})({});\n\n/**\n *\n * Demos:\n *\n * - [Autocomplete](https://mui.com/material-ui/react-autocomplete/)\n * - [Menu](https://mui.com/material-ui/react-menu/)\n * - [Popper](https://mui.com/material-ui/react-popper/)\n *\n * API:\n *\n * - [Popper API](https://mui.com/material-ui/api/popper/)\n */\nconst Popper = /*#__PURE__*/React.forwardRef(function Popper(inProps, ref) {\n var _slots$root;\n const theme = useTheme();\n const props = useThemeProps({\n props: inProps,\n name: 'MuiPopper'\n });\n const {\n anchorEl,\n component,\n components,\n componentsProps,\n container,\n disablePortal,\n keepMounted,\n modifiers,\n open,\n placement,\n popperOptions,\n popperRef,\n transition,\n slots,\n slotProps\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const RootComponent = (_slots$root = slots == null ? void 0 : slots.root) != null ? _slots$root : components == null ? void 0 : components.Root;\n const otherProps = _extends({\n anchorEl,\n container,\n disablePortal,\n keepMounted,\n modifiers,\n open,\n placement,\n popperOptions,\n popperRef,\n transition\n }, other);\n return /*#__PURE__*/_jsx(PopperRoot, _extends({\n as: component,\n direction: theme == null ? void 0 : theme.direction,\n slots: {\n root: RootComponent\n },\n slotProps: slotProps != null ? slotProps : componentsProps\n }, otherProps, {\n ref: ref\n }));\n});\nprocess.env.NODE_ENV !== \"production\" ? Popper.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * An HTML element, [virtualElement](https://popper.js.org/docs/v2/virtual-elements/),\n * or a function that returns either.\n * It's used to set the position of the popper.\n * The return value will passed as the reference object of the Popper instance.\n */\n anchorEl: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.object, PropTypes.func]),\n /**\n * Popper render function or node.\n */\n children: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.node, PropTypes.func]),\n /**\n * The component used for the root node.\n * Either a string to use a HTML element or a component.\n */\n component: PropTypes.elementType,\n /**\n * The components used for each slot inside the Popper.\n * Either a string to use a HTML element or a component.\n * @default {}\n */\n components: PropTypes.shape({\n Root: PropTypes.elementType\n }),\n /**\n * The props used for each slot inside the Popper.\n * @default {}\n */\n componentsProps: PropTypes.shape({\n root: PropTypes.oneOfType([PropTypes.func, PropTypes.object])\n }),\n /**\n * An HTML element or function that returns one.\n * The `container` will have the portal children appended to it.\n *\n * You can also provide a callback, which is called in a React layout effect.\n * This lets you set the container from a ref, and also makes server-side rendering possible.\n *\n * By default, it uses the body of the top-level document object,\n * so it's simply `document.body` most of the time.\n */\n container: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.func]),\n /**\n * The `children` will be under the DOM hierarchy of the parent component.\n * @default false\n */\n disablePortal: PropTypes.bool,\n /**\n * Always keep the children in the DOM.\n * This prop can be useful in SEO situation or\n * when you want to maximize the responsiveness of the Popper.\n * @default false\n */\n keepMounted: PropTypes.bool,\n /**\n * Popper.js is based on a \"plugin-like\" architecture,\n * most of its features are fully encapsulated \"modifiers\".\n *\n * A modifier is a function that is called each time Popper.js needs to\n * compute the position of the popper.\n * For this reason, modifiers should be very performant to avoid bottlenecks.\n * To learn how to create a modifier, [read the modifiers documentation](https://popper.js.org/docs/v2/modifiers/).\n */\n modifiers: PropTypes.arrayOf(PropTypes.shape({\n data: PropTypes.object,\n effect: PropTypes.func,\n enabled: PropTypes.bool,\n fn: PropTypes.func,\n name: PropTypes.any,\n options: PropTypes.object,\n phase: PropTypes.oneOf(['afterMain', 'afterRead', 'afterWrite', 'beforeMain', 'beforeRead', 'beforeWrite', 'main', 'read', 'write']),\n requires: PropTypes.arrayOf(PropTypes.string),\n requiresIfExists: PropTypes.arrayOf(PropTypes.string)\n })),\n /**\n * If `true`, the component is shown.\n */\n open: PropTypes.bool.isRequired,\n /**\n * Popper placement.\n * @default 'bottom'\n */\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n /**\n * Options provided to the [`Popper.js`](https://popper.js.org/docs/v2/constructors/#options) instance.\n * @default {}\n */\n popperOptions: PropTypes.shape({\n modifiers: PropTypes.array,\n onFirstUpdate: PropTypes.func,\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n strategy: PropTypes.oneOf(['absolute', 'fixed'])\n }),\n /**\n * A ref that points to the used popper instance.\n */\n popperRef: refType,\n /**\n * The props used for each slot inside the Popper.\n * @default {}\n */\n slotProps: PropTypes.shape({\n root: PropTypes.oneOfType([PropTypes.func, PropTypes.object])\n }),\n /**\n * The components used for each slot inside the Popper.\n * Either a string to use a HTML element or a component.\n * @default {}\n */\n slots: PropTypes.shape({\n root: PropTypes.elementType\n }),\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Help supporting a react-transition-group/Transition component.\n * @default false\n */\n transition: PropTypes.bool\n} : void 0;\nexport default Popper;","import generateUtilityClasses from '@mui/utils/generateUtilityClasses';\nimport generateUtilityClass from '@mui/utils/generateUtilityClass';\nexport function getTooltipUtilityClass(slot) {\n return generateUtilityClass('MuiTooltip', slot);\n}\nconst tooltipClasses = generateUtilityClasses('MuiTooltip', ['popper', 'popperInteractive', 'popperArrow', 'popperClose', 'tooltip', 'tooltipArrow', 'touch', 'tooltipPlacementLeft', 'tooltipPlacementRight', 'tooltipPlacementTop', 'tooltipPlacementBottom', 'arrow']);\nexport default tooltipClasses;","'use client';\n\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nconst _excluded = [\"arrow\", \"children\", \"classes\", \"components\", \"componentsProps\", \"describeChild\", \"disableFocusListener\", \"disableHoverListener\", \"disableInteractive\", \"disableTouchListener\", \"enterDelay\", \"enterNextDelay\", \"enterTouchDelay\", \"followCursor\", \"id\", \"leaveDelay\", \"leaveTouchDelay\", \"onClose\", \"onOpen\", \"open\", \"placement\", \"PopperComponent\", \"PopperProps\", \"slotProps\", \"slots\", \"title\", \"TransitionComponent\", \"TransitionProps\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport clsx from 'clsx';\nimport { elementAcceptingRef, unstable_useTimeout as useTimeout, unstable_Timeout as Timeout } from '@mui/utils';\nimport { unstable_composeClasses as composeClasses, appendOwnerState } from '@mui/base';\nimport { alpha } from '@mui/system';\nimport styled from '../styles/styled';\nimport useTheme from '../styles/useTheme';\nimport useThemeProps from '../styles/useThemeProps';\nimport capitalize from '../utils/capitalize';\nimport Grow from '../Grow';\nimport Popper from '../Popper';\nimport useEventCallback from '../utils/useEventCallback';\nimport useForkRef from '../utils/useForkRef';\nimport useId from '../utils/useId';\nimport useIsFocusVisible from '../utils/useIsFocusVisible';\nimport useControlled from '../utils/useControlled';\nimport tooltipClasses, { getTooltipUtilityClass } from './tooltipClasses';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nimport { jsxs as _jsxs } from \"react/jsx-runtime\";\nfunction round(value) {\n return Math.round(value * 1e5) / 1e5;\n}\nconst useUtilityClasses = ownerState => {\n const {\n classes,\n disableInteractive,\n arrow,\n touch,\n placement\n } = ownerState;\n const slots = {\n popper: ['popper', !disableInteractive && 'popperInteractive', arrow && 'popperArrow'],\n tooltip: ['tooltip', arrow && 'tooltipArrow', touch && 'touch', `tooltipPlacement${capitalize(placement.split('-')[0])}`],\n arrow: ['arrow']\n };\n return composeClasses(slots, getTooltipUtilityClass, classes);\n};\nconst TooltipPopper = styled(Popper, {\n name: 'MuiTooltip',\n slot: 'Popper',\n overridesResolver: (props, styles) => {\n const {\n ownerState\n } = props;\n return [styles.popper, !ownerState.disableInteractive && styles.popperInteractive, ownerState.arrow && styles.popperArrow, !ownerState.open && styles.popperClose];\n }\n})(({\n theme,\n ownerState,\n open\n}) => _extends({\n zIndex: (theme.vars || theme).zIndex.tooltip,\n pointerEvents: 'none'\n}, !ownerState.disableInteractive && {\n pointerEvents: 'auto'\n}, !open && {\n pointerEvents: 'none'\n}, ownerState.arrow && {\n [`&[data-popper-placement*=\"bottom\"] .${tooltipClasses.arrow}`]: {\n top: 0,\n marginTop: '-0.71em',\n '&::before': {\n transformOrigin: '0 100%'\n }\n },\n [`&[data-popper-placement*=\"top\"] .${tooltipClasses.arrow}`]: {\n bottom: 0,\n marginBottom: '-0.71em',\n '&::before': {\n transformOrigin: '100% 0'\n }\n },\n [`&[data-popper-placement*=\"right\"] .${tooltipClasses.arrow}`]: _extends({}, !ownerState.isRtl ? {\n left: 0,\n marginLeft: '-0.71em'\n } : {\n right: 0,\n marginRight: '-0.71em'\n }, {\n height: '1em',\n width: '0.71em',\n '&::before': {\n transformOrigin: '100% 100%'\n }\n }),\n [`&[data-popper-placement*=\"left\"] .${tooltipClasses.arrow}`]: _extends({}, !ownerState.isRtl ? {\n right: 0,\n marginRight: '-0.71em'\n } : {\n left: 0,\n marginLeft: '-0.71em'\n }, {\n height: '1em',\n width: '0.71em',\n '&::before': {\n transformOrigin: '0 0'\n }\n })\n}));\nconst TooltipTooltip = styled('div', {\n name: 'MuiTooltip',\n slot: 'Tooltip',\n overridesResolver: (props, styles) => {\n const {\n ownerState\n } = props;\n return [styles.tooltip, ownerState.touch && styles.touch, ownerState.arrow && styles.tooltipArrow, styles[`tooltipPlacement${capitalize(ownerState.placement.split('-')[0])}`]];\n }\n})(({\n theme,\n ownerState\n}) => _extends({\n backgroundColor: theme.vars ? theme.vars.palette.Tooltip.bg : alpha(theme.palette.grey[700], 0.92),\n borderRadius: (theme.vars || theme).shape.borderRadius,\n color: (theme.vars || theme).palette.common.white,\n fontFamily: theme.typography.fontFamily,\n padding: '4px 8px',\n fontSize: theme.typography.pxToRem(11),\n maxWidth: 300,\n margin: 2,\n wordWrap: 'break-word',\n fontWeight: theme.typography.fontWeightMedium\n}, ownerState.arrow && {\n position: 'relative',\n margin: 0\n}, ownerState.touch && {\n padding: '8px 16px',\n fontSize: theme.typography.pxToRem(14),\n lineHeight: `${round(16 / 14)}em`,\n fontWeight: theme.typography.fontWeightRegular\n}, {\n [`.${tooltipClasses.popper}[data-popper-placement*=\"left\"] &`]: _extends({\n transformOrigin: 'right center'\n }, !ownerState.isRtl ? _extends({\n marginRight: '14px'\n }, ownerState.touch && {\n marginRight: '24px'\n }) : _extends({\n marginLeft: '14px'\n }, ownerState.touch && {\n marginLeft: '24px'\n })),\n [`.${tooltipClasses.popper}[data-popper-placement*=\"right\"] &`]: _extends({\n transformOrigin: 'left center'\n }, !ownerState.isRtl ? _extends({\n marginLeft: '14px'\n }, ownerState.touch && {\n marginLeft: '24px'\n }) : _extends({\n marginRight: '14px'\n }, ownerState.touch && {\n marginRight: '24px'\n })),\n [`.${tooltipClasses.popper}[data-popper-placement*=\"top\"] &`]: _extends({\n transformOrigin: 'center bottom',\n marginBottom: '14px'\n }, ownerState.touch && {\n marginBottom: '24px'\n }),\n [`.${tooltipClasses.popper}[data-popper-placement*=\"bottom\"] &`]: _extends({\n transformOrigin: 'center top',\n marginTop: '14px'\n }, ownerState.touch && {\n marginTop: '24px'\n })\n}));\nconst TooltipArrow = styled('span', {\n name: 'MuiTooltip',\n slot: 'Arrow',\n overridesResolver: (props, styles) => styles.arrow\n})(({\n theme\n}) => ({\n overflow: 'hidden',\n position: 'absolute',\n width: '1em',\n height: '0.71em' /* = width / sqrt(2) = (length of the hypotenuse) */,\n boxSizing: 'border-box',\n color: theme.vars ? theme.vars.palette.Tooltip.bg : alpha(theme.palette.grey[700], 0.9),\n '&::before': {\n content: '\"\"',\n margin: 'auto',\n display: 'block',\n width: '100%',\n height: '100%',\n backgroundColor: 'currentColor',\n transform: 'rotate(45deg)'\n }\n}));\nlet hystersisOpen = false;\nconst hystersisTimer = new Timeout();\nlet cursorPosition = {\n x: 0,\n y: 0\n};\nexport function testReset() {\n hystersisOpen = false;\n hystersisTimer.clear();\n}\nfunction composeEventHandler(handler, eventHandler) {\n return event => {\n if (eventHandler) {\n eventHandler(event);\n }\n handler(event);\n };\n}\n\n// TODO v6: Remove PopperComponent, PopperProps, TransitionComponent and TransitionProps.\nconst Tooltip = /*#__PURE__*/React.forwardRef(function Tooltip(inProps, ref) {\n var _ref, _slots$popper, _ref2, _ref3, _slots$transition, _ref4, _slots$tooltip, _ref5, _slots$arrow, _slotProps$popper, _ref6, _slotProps$popper2, _slotProps$transition, _slotProps$tooltip, _ref7, _slotProps$tooltip2, _slotProps$arrow, _ref8, _slotProps$arrow2;\n const props = useThemeProps({\n props: inProps,\n name: 'MuiTooltip'\n });\n const {\n arrow = false,\n children: childrenProp,\n components = {},\n componentsProps = {},\n describeChild = false,\n disableFocusListener = false,\n disableHoverListener = false,\n disableInteractive: disableInteractiveProp = false,\n disableTouchListener = false,\n enterDelay = 100,\n enterNextDelay = 0,\n enterTouchDelay = 700,\n followCursor = false,\n id: idProp,\n leaveDelay = 0,\n leaveTouchDelay = 1500,\n onClose,\n onOpen,\n open: openProp,\n placement = 'bottom',\n PopperComponent: PopperComponentProp,\n PopperProps = {},\n slotProps = {},\n slots = {},\n title,\n TransitionComponent: TransitionComponentProp = Grow,\n TransitionProps\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n\n // to prevent runtime errors, developers will need to provide a child as a React element anyway.\n const children = /*#__PURE__*/React.isValidElement(childrenProp) ? childrenProp : /*#__PURE__*/_jsx(\"span\", {\n children: childrenProp\n });\n const theme = useTheme();\n const isRtl = theme.direction === 'rtl';\n const [childNode, setChildNode] = React.useState();\n const [arrowRef, setArrowRef] = React.useState(null);\n const ignoreNonTouchEvents = React.useRef(false);\n const disableInteractive = disableInteractiveProp || followCursor;\n const closeTimer = useTimeout();\n const enterTimer = useTimeout();\n const leaveTimer = useTimeout();\n const touchTimer = useTimeout();\n const [openState, setOpenState] = useControlled({\n controlled: openProp,\n default: false,\n name: 'Tooltip',\n state: 'open'\n });\n let open = openState;\n if (process.env.NODE_ENV !== 'production') {\n // eslint-disable-next-line react-hooks/rules-of-hooks\n const {\n current: isControlled\n } = React.useRef(openProp !== undefined);\n\n // eslint-disable-next-line react-hooks/rules-of-hooks\n React.useEffect(() => {\n if (childNode && childNode.disabled && !isControlled && title !== '' && childNode.tagName.toLowerCase() === 'button') {\n console.error(['MUI: You are providing a disabled `button` child to the Tooltip component.', 'A disabled element does not fire events.', \"Tooltip needs to listen to the child element's events to display the title.\", '', 'Add a simple wrapper element, such as a `span`.'].join('\\n'));\n }\n }, [title, childNode, isControlled]);\n }\n const id = useId(idProp);\n const prevUserSelect = React.useRef();\n const stopTouchInteraction = useEventCallback(() => {\n if (prevUserSelect.current !== undefined) {\n document.body.style.WebkitUserSelect = prevUserSelect.current;\n prevUserSelect.current = undefined;\n }\n touchTimer.clear();\n });\n React.useEffect(() => stopTouchInteraction, [stopTouchInteraction]);\n const handleOpen = event => {\n hystersisTimer.clear();\n hystersisOpen = true;\n\n // The mouseover event will trigger for every nested element in the tooltip.\n // We can skip rerendering when the tooltip is already open.\n // We are using the mouseover event instead of the mouseenter event to fix a hide/show issue.\n setOpenState(true);\n if (onOpen && !open) {\n onOpen(event);\n }\n };\n const handleClose = useEventCallback(\n /**\n * @param {React.SyntheticEvent | Event} event\n */\n event => {\n hystersisTimer.start(800 + leaveDelay, () => {\n hystersisOpen = false;\n });\n setOpenState(false);\n if (onClose && open) {\n onClose(event);\n }\n closeTimer.start(theme.transitions.duration.shortest, () => {\n ignoreNonTouchEvents.current = false;\n });\n });\n const handleEnter = event => {\n if (ignoreNonTouchEvents.current && event.type !== 'touchstart') {\n return;\n }\n\n // Remove the title ahead of time.\n // We don't want to wait for the next render commit.\n // We would risk displaying two tooltips at the same time (native + this one).\n if (childNode) {\n childNode.removeAttribute('title');\n }\n enterTimer.clear();\n leaveTimer.clear();\n if (enterDelay || hystersisOpen && enterNextDelay) {\n enterTimer.start(hystersisOpen ? enterNextDelay : enterDelay, () => {\n handleOpen(event);\n });\n } else {\n handleOpen(event);\n }\n };\n const handleLeave = event => {\n enterTimer.clear();\n leaveTimer.start(leaveDelay, () => {\n handleClose(event);\n });\n };\n const {\n isFocusVisibleRef,\n onBlur: handleBlurVisible,\n onFocus: handleFocusVisible,\n ref: focusVisibleRef\n } = useIsFocusVisible();\n // We don't necessarily care about the focusVisible state (which is safe to access via ref anyway).\n // We just need to re-render the Tooltip if the focus-visible state changes.\n const [, setChildIsFocusVisible] = React.useState(false);\n const handleBlur = event => {\n handleBlurVisible(event);\n if (isFocusVisibleRef.current === false) {\n setChildIsFocusVisible(false);\n handleLeave(event);\n }\n };\n const handleFocus = event => {\n // Workaround for https://github.com/facebook/react/issues/7769\n // The autoFocus of React might trigger the event before the componentDidMount.\n // We need to account for this eventuality.\n if (!childNode) {\n setChildNode(event.currentTarget);\n }\n handleFocusVisible(event);\n if (isFocusVisibleRef.current === true) {\n setChildIsFocusVisible(true);\n handleEnter(event);\n }\n };\n const detectTouchStart = event => {\n ignoreNonTouchEvents.current = true;\n const childrenProps = children.props;\n if (childrenProps.onTouchStart) {\n childrenProps.onTouchStart(event);\n }\n };\n const handleMouseOver = handleEnter;\n const handleMouseLeave = handleLeave;\n const handleTouchStart = event => {\n detectTouchStart(event);\n leaveTimer.clear();\n closeTimer.clear();\n stopTouchInteraction();\n prevUserSelect.current = document.body.style.WebkitUserSelect;\n // Prevent iOS text selection on long-tap.\n document.body.style.WebkitUserSelect = 'none';\n touchTimer.start(enterTouchDelay, () => {\n document.body.style.WebkitUserSelect = prevUserSelect.current;\n handleEnter(event);\n });\n };\n const handleTouchEnd = event => {\n if (children.props.onTouchEnd) {\n children.props.onTouchEnd(event);\n }\n stopTouchInteraction();\n leaveTimer.start(leaveTouchDelay, () => {\n handleClose(event);\n });\n };\n React.useEffect(() => {\n if (!open) {\n return undefined;\n }\n\n /**\n * @param {KeyboardEvent} nativeEvent\n */\n function handleKeyDown(nativeEvent) {\n // IE11, Edge (prior to using Bink?) use 'Esc'\n if (nativeEvent.key === 'Escape' || nativeEvent.key === 'Esc') {\n handleClose(nativeEvent);\n }\n }\n document.addEventListener('keydown', handleKeyDown);\n return () => {\n document.removeEventListener('keydown', handleKeyDown);\n };\n }, [handleClose, open]);\n const handleRef = useForkRef(children.ref, focusVisibleRef, setChildNode, ref);\n\n // There is no point in displaying an empty tooltip.\n // So we exclude all falsy values, except 0, which is valid.\n if (!title && title !== 0) {\n open = false;\n }\n const popperRef = React.useRef();\n const handleMouseMove = event => {\n const childrenProps = children.props;\n if (childrenProps.onMouseMove) {\n childrenProps.onMouseMove(event);\n }\n cursorPosition = {\n x: event.clientX,\n y: event.clientY\n };\n if (popperRef.current) {\n popperRef.current.update();\n }\n };\n const nameOrDescProps = {};\n const titleIsString = typeof title === 'string';\n if (describeChild) {\n nameOrDescProps.title = !open && titleIsString && !disableHoverListener ? title : null;\n nameOrDescProps['aria-describedby'] = open ? id : null;\n } else {\n nameOrDescProps['aria-label'] = titleIsString ? title : null;\n nameOrDescProps['aria-labelledby'] = open && !titleIsString ? id : null;\n }\n const childrenProps = _extends({}, nameOrDescProps, other, children.props, {\n className: clsx(other.className, children.props.className),\n onTouchStart: detectTouchStart,\n ref: handleRef\n }, followCursor ? {\n onMouseMove: handleMouseMove\n } : {});\n if (process.env.NODE_ENV !== 'production') {\n childrenProps['data-mui-internal-clone-element'] = true;\n\n // eslint-disable-next-line react-hooks/rules-of-hooks\n React.useEffect(() => {\n if (childNode && !childNode.getAttribute('data-mui-internal-clone-element')) {\n console.error(['MUI: The `children` component of the Tooltip is not forwarding its props correctly.', 'Please make sure that props are spread on the same element that the ref is applied to.'].join('\\n'));\n }\n }, [childNode]);\n }\n const interactiveWrapperListeners = {};\n if (!disableTouchListener) {\n childrenProps.onTouchStart = handleTouchStart;\n childrenProps.onTouchEnd = handleTouchEnd;\n }\n if (!disableHoverListener) {\n childrenProps.onMouseOver = composeEventHandler(handleMouseOver, childrenProps.onMouseOver);\n childrenProps.onMouseLeave = composeEventHandler(handleMouseLeave, childrenProps.onMouseLeave);\n if (!disableInteractive) {\n interactiveWrapperListeners.onMouseOver = handleMouseOver;\n interactiveWrapperListeners.onMouseLeave = handleMouseLeave;\n }\n }\n if (!disableFocusListener) {\n childrenProps.onFocus = composeEventHandler(handleFocus, childrenProps.onFocus);\n childrenProps.onBlur = composeEventHandler(handleBlur, childrenProps.onBlur);\n if (!disableInteractive) {\n interactiveWrapperListeners.onFocus = handleFocus;\n interactiveWrapperListeners.onBlur = handleBlur;\n }\n }\n if (process.env.NODE_ENV !== 'production') {\n if (children.props.title) {\n console.error(['MUI: You have provided a `title` prop to the child of .', `Remove this title prop \\`${children.props.title}\\` or the Tooltip component.`].join('\\n'));\n }\n }\n const popperOptions = React.useMemo(() => {\n var _PopperProps$popperOp;\n let tooltipModifiers = [{\n name: 'arrow',\n enabled: Boolean(arrowRef),\n options: {\n element: arrowRef,\n padding: 4\n }\n }];\n if ((_PopperProps$popperOp = PopperProps.popperOptions) != null && _PopperProps$popperOp.modifiers) {\n tooltipModifiers = tooltipModifiers.concat(PopperProps.popperOptions.modifiers);\n }\n return _extends({}, PopperProps.popperOptions, {\n modifiers: tooltipModifiers\n });\n }, [arrowRef, PopperProps]);\n const ownerState = _extends({}, props, {\n isRtl,\n arrow,\n disableInteractive,\n placement,\n PopperComponentProp,\n touch: ignoreNonTouchEvents.current\n });\n const classes = useUtilityClasses(ownerState);\n const PopperComponent = (_ref = (_slots$popper = slots.popper) != null ? _slots$popper : components.Popper) != null ? _ref : TooltipPopper;\n const TransitionComponent = (_ref2 = (_ref3 = (_slots$transition = slots.transition) != null ? _slots$transition : components.Transition) != null ? _ref3 : TransitionComponentProp) != null ? _ref2 : Grow;\n const TooltipComponent = (_ref4 = (_slots$tooltip = slots.tooltip) != null ? _slots$tooltip : components.Tooltip) != null ? _ref4 : TooltipTooltip;\n const ArrowComponent = (_ref5 = (_slots$arrow = slots.arrow) != null ? _slots$arrow : components.Arrow) != null ? _ref5 : TooltipArrow;\n const popperProps = appendOwnerState(PopperComponent, _extends({}, PopperProps, (_slotProps$popper = slotProps.popper) != null ? _slotProps$popper : componentsProps.popper, {\n className: clsx(classes.popper, PopperProps == null ? void 0 : PopperProps.className, (_ref6 = (_slotProps$popper2 = slotProps.popper) != null ? _slotProps$popper2 : componentsProps.popper) == null ? void 0 : _ref6.className)\n }), ownerState);\n const transitionProps = appendOwnerState(TransitionComponent, _extends({}, TransitionProps, (_slotProps$transition = slotProps.transition) != null ? _slotProps$transition : componentsProps.transition), ownerState);\n const tooltipProps = appendOwnerState(TooltipComponent, _extends({}, (_slotProps$tooltip = slotProps.tooltip) != null ? _slotProps$tooltip : componentsProps.tooltip, {\n className: clsx(classes.tooltip, (_ref7 = (_slotProps$tooltip2 = slotProps.tooltip) != null ? _slotProps$tooltip2 : componentsProps.tooltip) == null ? void 0 : _ref7.className)\n }), ownerState);\n const tooltipArrowProps = appendOwnerState(ArrowComponent, _extends({}, (_slotProps$arrow = slotProps.arrow) != null ? _slotProps$arrow : componentsProps.arrow, {\n className: clsx(classes.arrow, (_ref8 = (_slotProps$arrow2 = slotProps.arrow) != null ? _slotProps$arrow2 : componentsProps.arrow) == null ? void 0 : _ref8.className)\n }), ownerState);\n return /*#__PURE__*/_jsxs(React.Fragment, {\n children: [/*#__PURE__*/React.cloneElement(children, childrenProps), /*#__PURE__*/_jsx(PopperComponent, _extends({\n as: PopperComponentProp != null ? PopperComponentProp : Popper,\n placement: placement,\n anchorEl: followCursor ? {\n getBoundingClientRect: () => ({\n top: cursorPosition.y,\n left: cursorPosition.x,\n right: cursorPosition.x,\n bottom: cursorPosition.y,\n width: 0,\n height: 0\n })\n } : childNode,\n popperRef: popperRef,\n open: childNode ? open : false,\n id: id,\n transition: true\n }, interactiveWrapperListeners, popperProps, {\n popperOptions: popperOptions,\n children: ({\n TransitionProps: TransitionPropsInner\n }) => /*#__PURE__*/_jsx(TransitionComponent, _extends({\n timeout: theme.transitions.duration.shorter\n }, TransitionPropsInner, transitionProps, {\n children: /*#__PURE__*/_jsxs(TooltipComponent, _extends({}, tooltipProps, {\n children: [title, arrow ? /*#__PURE__*/_jsx(ArrowComponent, _extends({}, tooltipArrowProps, {\n ref: setArrowRef\n })) : null]\n }))\n }))\n }))]\n });\n});\nprocess.env.NODE_ENV !== \"production\" ? Tooltip.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the d.ts file and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * If `true`, adds an arrow to the tooltip.\n * @default false\n */\n arrow: PropTypes.bool,\n /**\n * Tooltip reference element.\n */\n children: elementAcceptingRef.isRequired,\n /**\n * Override or extend the styles applied to the component.\n */\n classes: PropTypes.object,\n /**\n * @ignore\n */\n className: PropTypes.string,\n /**\n * The components used for each slot inside.\n *\n * This prop is an alias for the `slots` prop.\n * It's recommended to use the `slots` prop instead.\n *\n * @default {}\n */\n components: PropTypes.shape({\n Arrow: PropTypes.elementType,\n Popper: PropTypes.elementType,\n Tooltip: PropTypes.elementType,\n Transition: PropTypes.elementType\n }),\n /**\n * The extra props for the slot components.\n * You can override the existing props or add new ones.\n *\n * This prop is an alias for the `slotProps` prop.\n * It's recommended to use the `slotProps` prop instead, as `componentsProps` will be deprecated in the future.\n *\n * @default {}\n */\n componentsProps: PropTypes.shape({\n arrow: PropTypes.object,\n popper: PropTypes.object,\n tooltip: PropTypes.object,\n transition: PropTypes.object\n }),\n /**\n * Set to `true` if the `title` acts as an accessible description.\n * By default the `title` acts as an accessible label for the child.\n * @default false\n */\n describeChild: PropTypes.bool,\n /**\n * Do not respond to focus-visible events.\n * @default false\n */\n disableFocusListener: PropTypes.bool,\n /**\n * Do not respond to hover events.\n * @default false\n */\n disableHoverListener: PropTypes.bool,\n /**\n * Makes a tooltip not interactive, i.e. it will close when the user\n * hovers over the tooltip before the `leaveDelay` is expired.\n * @default false\n */\n disableInteractive: PropTypes.bool,\n /**\n * Do not respond to long press touch events.\n * @default false\n */\n disableTouchListener: PropTypes.bool,\n /**\n * The number of milliseconds to wait before showing the tooltip.\n * This prop won't impact the enter touch delay (`enterTouchDelay`).\n * @default 100\n */\n enterDelay: PropTypes.number,\n /**\n * The number of milliseconds to wait before showing the tooltip when one was already recently opened.\n * @default 0\n */\n enterNextDelay: PropTypes.number,\n /**\n * The number of milliseconds a user must touch the element before showing the tooltip.\n * @default 700\n */\n enterTouchDelay: PropTypes.number,\n /**\n * If `true`, the tooltip follow the cursor over the wrapped element.\n * @default false\n */\n followCursor: PropTypes.bool,\n /**\n * This prop is used to help implement the accessibility logic.\n * If you don't provide this prop. It falls back to a randomly generated id.\n */\n id: PropTypes.string,\n /**\n * The number of milliseconds to wait before hiding the tooltip.\n * This prop won't impact the leave touch delay (`leaveTouchDelay`).\n * @default 0\n */\n leaveDelay: PropTypes.number,\n /**\n * The number of milliseconds after the user stops touching an element before hiding the tooltip.\n * @default 1500\n */\n leaveTouchDelay: PropTypes.number,\n /**\n * Callback fired when the component requests to be closed.\n *\n * @param {React.SyntheticEvent} event The event source of the callback.\n */\n onClose: PropTypes.func,\n /**\n * Callback fired when the component requests to be open.\n *\n * @param {React.SyntheticEvent} event The event source of the callback.\n */\n onOpen: PropTypes.func,\n /**\n * If `true`, the component is shown.\n */\n open: PropTypes.bool,\n /**\n * Tooltip placement.\n * @default 'bottom'\n */\n placement: PropTypes.oneOf(['bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n /**\n * The component used for the popper.\n * @default Popper\n */\n PopperComponent: PropTypes.elementType,\n /**\n * Props applied to the [`Popper`](/material-ui/api/popper/) element.\n * @default {}\n */\n PopperProps: PropTypes.object,\n /**\n * The extra props for the slot components.\n * You can override the existing props or add new ones.\n *\n * This prop is an alias for the `componentsProps` prop, which will be deprecated in the future.\n *\n * @default {}\n */\n slotProps: PropTypes.shape({\n arrow: PropTypes.object,\n popper: PropTypes.object,\n tooltip: PropTypes.object,\n transition: PropTypes.object\n }),\n /**\n * The components used for each slot inside.\n *\n * This prop is an alias for the `components` prop, which will be deprecated in the future.\n *\n * @default {}\n */\n slots: PropTypes.shape({\n arrow: PropTypes.elementType,\n popper: PropTypes.elementType,\n tooltip: PropTypes.elementType,\n transition: PropTypes.elementType\n }),\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Tooltip title. Zero-length titles string, undefined, null and false are never displayed.\n */\n title: PropTypes.node,\n /**\n * The component used for the transition.\n * [Follow this guide](/material-ui/transitions/#transitioncomponent-prop) to learn more about the requirements for this component.\n * @default Grow\n */\n TransitionComponent: PropTypes.elementType,\n /**\n * Props applied to the transition element.\n * By default, the element is based on this [`Transition`](http://reactcommunity.org/react-transition-group/transition/) component.\n */\n TransitionProps: PropTypes.object\n} : void 0;\nexport default Tooltip;","import '@/components/mui/menu-item.component.css';\nimport ArrowRightIcon from '@mui/icons-material/ArrowRight';\nimport {\n ListItemIcon as MuiListItemIcon,\n ListItemText as MuiListItemText,\n MenuItem as MuiMenuItem,\n} from '@mui/material';\nimport Tooltip from '@mui/material/Tooltip';\nimport { Localized, ReferencedItem, SingleColumnMenu } from 'platform-bible-utils';\nimport { MouseEvent, PropsWithChildren } from 'react';\n\ntype MenuItemInfoBase = {\n /** Text (displayable in the UI) as the name of the menu item */\n label: string;\n /** Text to display when the mouse hovers over the menu item */\n tooltip?: string;\n};\n\nexport type Command = MenuItemInfoBase & {\n /** Command to execute (string.string) */\n command: string;\n};\n\ntype SubMenu = MenuItemInfoBase & {\n /** Command to execute (string.string) */\n items: MenuItemInfo[];\n};\n\nexport interface CommandHandler {\n (command: Command): void;\n}\n\nexport type MenuPropsBase = {\n /*\n * The JSON defining the menu whose items are to be rendered. This will typically be one of the\n * menus in the \"defs\" in a Platform.Bible menu (see PlatformMenus). The schema for this is\n * menuDocumentSchema (at the end of menus.model.ts). Note that while this is a\n * \"SingleColumnMenu\", somewhat bizarrely, a MultiColumnMenu is a SingleColumnMenu, so it really\n * could be a MultiColumnMenu, in which case, column had better be defined so it can be used\n * to filter out the actual groups and items to display on the column.\n */\n menuDefinition: Localized;\n\n commandHandler: CommandHandler;\n\n /**\n * Additional action to perform when any menu item is clicked. Allows the caller to handle event\n * (e.g., to close the menu).\n */\n onClick?: (event: MouseEvent) => void;\n};\n\nexport type MenuItemListProps = MenuPropsBase & {\n /** Optional unique (column) identifier */\n columnId?: ReferencedItem;\n};\n\nexport type MenuItemProps = Omit &\n PropsWithChildren<{\n /** Optional unique identifier */\n id?: string;\n\n onClick: (event: MouseEvent) => void;\n }>;\n\ntype MenuItemInfo = (Command | SubMenu) & {\n /**\n * If specified, menu item will be inset if it does not have a leading icon.\n *\n * @default true\n */\n allowForLeadingIcons?: boolean;\n /**\n * If specified, the path to the icon image to display on the leading side of the menu text.\n *\n * @default undefined (no leading icon will be shown)\n */\n iconPathBefore?: string;\n /**\n * If specified, the path to the icon image to display on the trailing side of the menu text.\n *\n * @default undefined (no trailing icon will be shown)\n */\n iconPathAfter?: string;\n /**\n * If true, list item is focused during the first mount\n *\n * @default false\n */\n hasAutoFocus?: boolean;\n\n /** Additional css classes to help with unique styling of the menu item */\n className?: string;\n\n /**\n * If true, the menu item will appear disabled and it will not respond to clicks or mouse hovers.\n *\n * @default false\n */\n isDisabled?: boolean;\n\n /**\n * If true, compact vertical padding designed for keyboard and mouse input is used.\n *\n * @default true\n */\n isDense?: boolean;\n\n /**\n * If true, a right-arrow icon will be displayed (iconPathAfter, if specified, will be ignored).\n *\n * @default false\n */\n isSubMenuParent?: boolean;\n\n /**\n * If true, the left and right padding is removed\n *\n * @default false\n */\n hasDisabledGutters?: boolean;\n\n /**\n * If true, a 1px light border is added to bottom of menu item\n *\n * @default false\n */\n hasDivider?: boolean;\n\n /** Help identify which element has keyboard focus */\n focusVisibleClassName?: string;\n\n /** If it's a submenu, it should have the items property */\n items?: MenuItemInfo[];\n};\n\nfunction getIcon(icon: string | undefined, menuLabel: string, leading: boolean) {\n return icon ? (\n \n {`${leading\n \n ) : undefined;\n}\n\nexport default function MenuItem(props: MenuItemProps) {\n const {\n onClick,\n label,\n tooltip,\n allowForLeadingIcons = true,\n iconPathBefore = undefined,\n iconPathAfter = undefined,\n hasAutoFocus = false,\n className,\n isDisabled = false,\n isDense = true,\n isSubMenuParent = false,\n hasDisabledGutters = false,\n hasDivider = false,\n focusVisibleClassName,\n id,\n children,\n } = props;\n\n const menuItem = (\n \n {label ? (\n <>\n {getIcon(iconPathBefore, label, true)}\n \n {isSubMenuParent ? (\n \n \n \n ) : (\n getIcon(iconPathAfter, label, false)\n )}\n \n ) : (\n children\n )}\n \n );\n\n return tooltip ? (\n \n
    {menuItem}
    \n
    \n ) : (\n menuItem\n );\n}\n","import MenuItem, {\n MenuItemListProps,\n MenuItemProps,\n MenuPropsBase,\n} from '@/components/mui/menu-item.component';\nimport { Menu } from '@mui/material';\nimport {\n Localized,\n MenuGroupDetailsInSubMenu,\n MenuItemContainingCommand,\n MenuItemContainingSubmenu,\n OrderedExtensibleContainer,\n ReferencedItem,\n SingleColumnMenu,\n} from 'platform-bible-utils';\nimport { MouseEvent, useMemo, useState } from 'react';\n\n/**\n * All the exported types in this file should be regarded as \"internal\" (i.e., they should not be\n * exposed via index.ts).\n */\n\nexport type GroupedMenuPropsBase = MenuPropsBase & {\n /** Optional unique (column) identifier */\n columnId?: ReferencedItem;\n};\n\nexport type GroupedMenuItemListProps = MenuItemListProps & {\n /**\n * If the menuDefinition includes \"top-level\" groups (i.e., those that belong to a column as\n * opposed to those that belong to a submenu) that should not be included in the list, then this\n * array specifies which groups to include. Likewise, for a submenu, this list indicates which\n * groups are pertinent for that submenu. So then for a context menu this property need not be\n * specified since it is a top-level menu based on a \"true\" SingleColumnMenu (i.e., one that is\n * not a MultiColumnMenu).\n */\n includedGroups?: {\n id: string;\n group: Localized;\n }[];\n};\n\ninterface ItemInfo {\n item: Localized;\n isLastItemInGroup: boolean;\n}\n\ntype SubMenuProps = MenuPropsBase & {\n parentMenuItem: Localized;\n parentItemProps: Omit, 'iconPathAfter'>;\n};\n\nfunction getAllGroups(menuDefinition: Localized) {\n const groupEntries = Object.entries(menuDefinition.groups);\n // Convert array of entries to array of objects with id and group properties\n return groupEntries.map(([key, value]) => ({ id: key, group: value }));\n}\n\nfunction SubMenu(props: SubMenuProps) {\n const [anchorEl, setAnchorEl] = useState(undefined);\n\n const { parentMenuItem, parentItemProps, menuDefinition } = props;\n\n const handleParentMenuItemClick = (event: MouseEvent) => {\n setAnchorEl(event.currentTarget);\n };\n\n const handleClose = () => {\n setAnchorEl(undefined);\n };\n\n const renderSubMenuItems = () => {\n let includedGroups = getAllGroups(menuDefinition).filter((g) => 'menuItem' in g.group);\n\n // Ensure valid parent menu was provided. (If not, submenu will contain all groups!)\n if (!parentMenuItem?.id) throw new Error('A valid parent menu item is required for submenus.');\n\n // When laying out a submenu, only include groups associated with the provided parent menu.\n // Note: without the (annoying) redundant check that the included groups\n // have the menuItem field, TS doesn't think it exists.\n includedGroups = includedGroups.filter(\n (group) => 'menuItem' in group.group && group.group.menuItem === parentMenuItem.id,\n );\n\n return ;\n };\n\n return (\n <>\n \n \n {renderSubMenuItems()}\n \n \n );\n}\n\nconst getOrderedGroupItems = (\n groupId: string,\n allItems: Localized[],\n) => {\n // Filter items that belong to the specified group\n const itemsForGroup = allItems.filter((item) => item.group === groupId);\n // Sort items based on order\n const sortedItems = itemsForGroup.sort((a, b) => (a.order || 0) - (b.order || 0));\n return sortedItems;\n};\n\n/**\n * This component is internal; it does not need to be exposed to the outside world since it is not\n * useful on its own. It is used to generate and lay out the MenuItems that appear either on a\n * top-level menu (in a GridMenu or ContextMenu) or in a submenu.\n */\nexport default function GroupedMenuItemList(menuProps: GroupedMenuItemListProps) {\n const { menuDefinition, onClick, commandHandler, includedGroups } = menuProps;\n\n const { items, allowForLeadingIcons } = useMemo(() => {\n const groupsToInclude =\n includedGroups && includedGroups.length > 0\n ? includedGroups\n : // We're apparently laying out a single-column menu (presumably a context menu). In this\n // case, all groups should be included except ones that belong to a submenu.\n getAllGroups(menuDefinition).filter((g) => !('menuItem' in g.group));\n\n const sortedGroups = Object.values(groupsToInclude).sort(\n (a, b) => (a.group.order || 0) - (b.group.order || 0),\n );\n\n const itemArray: ItemInfo[] = [];\n\n sortedGroups.forEach((group) => {\n getOrderedGroupItems(group.id, menuDefinition.items).forEach((item) =>\n itemArray.push({ item, isLastItemInGroup: false }),\n );\n if (itemArray.length > 0) itemArray[itemArray.length - 1].isLastItemInGroup = true;\n });\n\n // No divider after last item in final group.\n if (itemArray.length > 0) itemArray[itemArray.length - 1].isLastItemInGroup = false;\n\n const allowSpaceForLeadingIcons = itemArray.some(\n (i) => 'iconPathBefore' in i.item && i.item.iconPathBefore,\n );\n\n return { items: itemArray, allowForLeadingIcons: allowSpaceForLeadingIcons };\n }, [includedGroups, menuDefinition]);\n\n // Create props for MenuItem component including setting hasDivider for the last item in a group\n const createMenuItemProps = ({ item, isLastItemInGroup }: ItemInfo) => {\n const menuItemProps = {\n className: 'papi-menu-item',\n label: item.label,\n tooltip: item.tooltip,\n iconPathBefore: 'iconPathBefore' in item ? item.iconPathBefore : undefined,\n iconPathAfter: 'iconPathAfter' in item ? item.iconPathAfter : undefined,\n hasDivider: isLastItemInGroup, // Set hasDivider to true for the last item in a group\n allowForLeadingIcons,\n };\n\n return menuItemProps;\n };\n\n const [firstItem] = items;\n\n if (!firstItem) return
    ;\n\n const divKey = firstItem.item.group;\n\n return (\n
    \n {items.map((itemInfo, index) => {\n const { item } = itemInfo;\n const menuItemProps = createMenuItemProps(itemInfo);\n if ('command' in item) {\n const key = item.group + index;\n return (\n ) => {\n onClick?.(event);\n commandHandler(item);\n }}\n {...menuItemProps}\n />\n );\n }\n return (\n \n );\n })}\n
    \n );\n}\n","import GroupedMenuItemList from '@/components/mui/grouped-menu-item-list.component';\nimport { MenuItemListProps } from '@/components/mui/menu-item.component';\nimport { MultiColumnMenu } from 'platform-bible-utils';\n\n/**\n * This component is internal; it does not need to be exposed to the outside world since it is not\n * useful on its own. Use either GridMenu or ContextMenu.\n */\nexport default function TopLevelMenu(props: MenuItemListProps) {\n const { menuDefinition, columnId } = props;\n\n const groupEntries = Object.entries(menuDefinition.groups);\n // Convert array of entries to array of objects with id and group properties\n const groups = groupEntries.map(([key, value]) => ({ id: key, group: value }));\n let includedGroups = groups.filter((g) => 'column' in g.group);\n\n // Check if column is provided and menuDefinition is a MultiColumnMenu\n if (\n columnId &&\n 'columns' in menuDefinition &&\n // Without this type assertion, TS doesn't know what columns is.\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n (menuDefinition as MultiColumnMenu).columns[columnId]\n ) {\n // When laying out a single column in a MultiColumnMenu, only include groups associated with\n // the provided column. Note: without the (annoying) redundant check that the included groups\n // have the colum field, TS doesn't think it exists.\n includedGroups = includedGroups.filter(\n (g) => 'column' in g.group && g.group.column === columnId,\n );\n }\n\n return ;\n}\n","import '@/components/mui/grid-menu.component.css';\nimport { GroupedMenuPropsBase } from '@/components/mui/grouped-menu-item-list.component';\nimport { CommandHandler } from '@/components/mui/menu-item.component';\nimport TopLevelMenu from '@/components/mui/top-level-menu.component';\nimport { Grid, List } from '@mui/material';\nimport {\n Localized,\n MenuColumnWithHeader,\n MultiColumnMenu,\n ReferencedItem,\n} from 'platform-bible-utils';\nimport { useMemo } from 'react';\n\ntype ColumnInfo = {\n /*\n * The ID (`${string}.${string}`) of a specific menu column.\n */\n id: ReferencedItem;\n\n /*\n * Metadata (label, order, etc.) for a specific menu column.\n */\n metadata: Localized;\n};\n\ntype MenuColumnProps = ColumnInfo &\n GroupedMenuPropsBase & {\n /** Additional css classes to help with unique styling of the menu column */\n className?: string;\n };\n\nexport type GridMenuInfo = {\n /** The menu object containing information about the columns, groups, and items to display. */\n multiColumnMenu: Localized;\n};\n\nexport type GridMenuProps = GridMenuInfo & {\n /** Optional unique identifier */\n id?: string;\n\n commandHandler: CommandHandler;\n\n /** Additional css classes to help with unique styling of the grid menu */\n className?: string;\n};\n\nfunction MenuColumn({\n commandHandler,\n menuDefinition,\n id,\n metadata,\n onClick,\n className,\n}: MenuColumnProps) {\n return (\n \n

    \n {metadata.label}\n

    \n {/* It would seem as though this List component were unnecessary, since it only contains one\n thing, but the \"dense\" property does affect the layout of the items (in a way I don't fully\n understand). There might be a better way. */}\n \n \n \n \n );\n}\n\nexport default function GridMenu({\n commandHandler,\n className,\n multiColumnMenu,\n id,\n}: GridMenuProps) {\n const { columns } = multiColumnMenu;\n\n const sortedColumns = useMemo(() => {\n const columnNumbers = new Map();\n Object.getOwnPropertyNames(columns).forEach((columnName: string) => {\n // We know for sure there is a (boolean) property 'isExtensible' that we are not interested in.\n if (columnName === 'isExtensible') return;\n // TS doesn't allow `columnName` above to be a ReferencedItem even though the type says it is\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const columnId = columnName as ReferencedItem;\n const column = columns[columnId];\n // As of right now (and hopefully forever after), all remaining properties of the\n // ColumnsWithHeaders object are columns whose property names are the IDs of the columns.\n // This is an additional (redundant) sanity check. Specifically we're interested in\n // MenuColumnWithHeader objects, which TypeScript now \"knows\" we have, but at runtime all we\n // can check for is that it's an object with a valid numeric order field. That's likely good\n // enough.\n if (\n typeof column === 'object' &&\n typeof column.order === 'number' &&\n !Number.isNaN(column.order)\n )\n columnNumbers.set(column.order, { id: columnId, metadata: column });\n else\n console.warn(\n `Property ${columnName} (${typeof column}) on menu ${id} is not a valid column and is being ignored. This might indicate data corruption`,\n );\n });\n\n // Extract values and sort them based on the 'order' property\n return Array.from(columnNumbers.values()).sort((a, b) => {\n return (a.metadata.order || 0) - (b.metadata.order || 0);\n });\n }, [columns, id]);\n\n // We might need something like this if we need to be able to prevent empty columns\n // sortedColumns.filter((c) => multiColumnMenu.groups.some((g) => 'column' in g && (g as .column)...\n\n return (\n \n {sortedColumns.map((col, index) => (\n \n ))}\n \n );\n}\n","import { useEffect, useRef, useState } from 'react';\n\nexport type UsePromiseOptions = {\n /**\n * Whether to leave the value as the most recent resolved promise value or set it back to\n * defaultValue while running the promise again. Defaults to true\n */\n preserveValue?: boolean;\n};\n\n/** Set up defaults for options for usePromise hook */\nfunction getUsePromiseOptionsDefaults(options: UsePromiseOptions): UsePromiseOptions {\n return {\n preserveValue: true,\n ...options,\n };\n}\n\n/**\n * Awaits a promise and returns a loading value while the promise is unresolved\n *\n * @param promiseFactoryCallback A function that returns the promise to await. If this callback is\n * undefined, the current value will be returned (defaultValue unless it was previously changed\n * and `options.preserveValue` is true), and there will be no loading.\n *\n * WARNING: MUST BE STABLE - const or wrapped in useCallback. The reference must not be updated\n * every render\n * @param defaultValue The initial value to return while first awaiting the promise. If\n * `options.preserveValue` is false, this value is also shown while awaiting the promise on\n * subsequent calls.\n *\n * Note: this parameter is internally assigned to a `ref`, so changing it will not cause any hooks\n * to re-run with its new value. This means that, if the `promiseFactoryCallback` changes and\n * `options.preserveValue` is `false`, the returned value will be set to the current\n * `defaultValue`. However, the returned value will not be updated if`defaultValue` changes.\n * @param options Various options for adjusting how this hook runs the `promiseFactoryCallback`\n *\n * Note: this parameter is internally assigned to a `ref`, so changing it will not cause any hooks\n * to re-run with its new value. However, the latest `options.preserveValue` will always be used\n * appropriately to determine whether to preserve the returned value when changing the\n * `promiseFactoryCallback`\n * @returns `[value, isLoading]`\n *\n * - `value`: the current value for the promise, either the defaultValue or the resolved promise value\n * - `isLoading`: whether the promise is waiting to be resolved\n */\nconst usePromise = (\n promiseFactoryCallback: (() => Promise) | undefined,\n defaultValue: T,\n options: UsePromiseOptions = {},\n): [value: T, isLoading: boolean] => {\n // Use defaultValue as a ref so it doesn't update dependency arrays\n const defaultValueRef = useRef(defaultValue);\n defaultValueRef.current = defaultValue;\n // Use options as a ref so it doesn't update dependency arrays\n const optionsDefaultedRef = useRef(options);\n optionsDefaultedRef.current = getUsePromiseOptionsDefaults(optionsDefaultedRef.current);\n\n const [value, setValue] = useState(() => defaultValueRef.current);\n const [isLoading, setIsLoading] = useState(true);\n useEffect(() => {\n let promiseIsCurrent = true;\n // If a promiseFactoryCallback was provided, we are loading. Otherwise, there is no loading to do\n setIsLoading(!!promiseFactoryCallback);\n (async () => {\n // If there is a callback to run, run it\n if (promiseFactoryCallback) {\n const result = await promiseFactoryCallback();\n // If the promise was not already replaced, update the value\n if (promiseIsCurrent) {\n setValue(() => result);\n setIsLoading(false);\n }\n }\n })();\n\n return () => {\n // Mark this promise as old and not to be used\n promiseIsCurrent = false;\n if (!optionsDefaultedRef.current.preserveValue) setValue(() => defaultValueRef.current);\n };\n }, [promiseFactoryCallback]);\n\n return [value, isLoading];\n};\nexport default usePromise;\n","\"use client\";\n\nimport createSvgIcon from './utils/createSvgIcon';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nexport default createSvgIcon( /*#__PURE__*/_jsx(\"path\", {\n d: \"M3 18h18v-2H3zm0-5h18v-2H3zm0-7v2h18V6z\"\n}), 'Menu');","import GridMenu from '@/components/mui/grid-menu.component';\nimport { Command, CommandHandler } from '@/components/mui/menu-item.component';\nimport usePromise from '@/hooks/use-promise.hook';\nimport { Menu as MenuIcon } from '@mui/icons-material';\nimport { Drawer, IconButton } from '@mui/material';\nimport { Localized, MultiColumnMenu } from 'platform-bible-utils';\nimport {\n MouseEvent,\n MutableRefObject,\n PropsWithChildren,\n useCallback,\n useEffect,\n useState,\n} from 'react';\n\nexport interface MultiColumnMenuProvider {\n (isSupportAndDevelopment: boolean): Promise>;\n}\n\nexport type HamburgerMenuButtonProps = PropsWithChildren & {\n /** The handler to use for menu commands (and eventually toolbar commands). */\n commandHandler: CommandHandler;\n\n /**\n * Optional reference to the \"div\" container that determines the where the menu should appear. If\n * not defined, then (1,1) used.\n */\n containerRef?: MutableRefObject;\n\n /**\n * The delegate to use to get the menu data. If not specified or if it returns undefined, the data\n * in normalMenu or fullMenu property will be used.\n */\n menuProvider?: MultiColumnMenuProvider;\n\n /**\n * The menu data to show when the menu is opened if the menuProvider property is not defined.\n * (This allows for a default or test-only static menu to be used.)\n */\n normalMenu?: Localized;\n\n /**\n * The menu data to show for \"full\" menu (when opened with the SHIFT key pressed) if the\n * menuProvider property is not defined. (This allows for a default or test-only static menu to be\n * used.)\n */\n fullMenu?: Localized;\n\n /** Additional css class(es) to help with unique styling of the sub-components */\n className?: string;\n\n /** Value to use as prefix for ARIA labels on interactive sub-components */\n ariaLabelPrefix?: string;\n};\n\nexport default function HamburgerMenuButton({\n menuProvider,\n normalMenu,\n fullMenu,\n commandHandler,\n containerRef,\n className,\n ariaLabelPrefix,\n children,\n}: HamburgerMenuButtonProps) {\n const [isMenuOpen, setMenuOpen] = useState(false);\n const [showFullMenu, setShowFullMenu] = useState(false);\n\n const handleMenuItemClick = useCallback(() => {\n if (isMenuOpen) setMenuOpen(false);\n setShowFullMenu(false);\n }, [isMenuOpen]);\n\n const handleMenuButtonClick = useCallback((e: MouseEvent) => {\n e.stopPropagation();\n setMenuOpen((prevIsOpen) => {\n const isOpening = !prevIsOpen;\n if (isOpening && e.shiftKey) setShowFullMenu(true);\n else if (!isOpening) setShowFullMenu(false);\n return isOpening;\n });\n }, []);\n\n const menuCommandHandler = useCallback(\n (command: Command) => {\n handleMenuItemClick();\n return commandHandler(command);\n },\n [commandHandler, handleMenuItemClick],\n );\n\n const [offset, setOffset] = useState({ top: 1, left: 1 });\n\n useEffect(() => {\n if (isMenuOpen) {\n const node = containerRef?.current;\n if (node) {\n const rect = node.getBoundingClientRect();\n const scrollTop = window.scrollY;\n const scrollLeft = window.scrollX;\n const top = rect.top + scrollTop + node.clientHeight;\n const left = rect.left + scrollLeft;\n setOffset({ top, left });\n }\n }\n }, [isMenuOpen, containerRef]);\n\n const [normalMenuData] = usePromise(\n useCallback(async () => {\n return menuProvider?.(false) ?? normalMenu;\n // isMenuOpen needs to be included for the menu contents to reevaluate when reopened\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [menuProvider, normalMenu, isMenuOpen]),\n normalMenu,\n );\n\n const [fullMenuData] = usePromise(\n useCallback(async () => {\n return menuProvider?.(true) ?? fullMenu ?? normalMenuData;\n // isMenuOpen needs to be included for the menu contents to reevaluate when reopened\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [menuProvider, fullMenu, normalMenuData, isMenuOpen]),\n fullMenu ?? normalMenuData,\n );\n\n const menu = showFullMenu && fullMenuData ? fullMenuData : normalMenuData;\n\n return (\n <>\n \n {children ?? }\n \n \n {menu ? (\n \n ) : undefined}\n \n \n );\n}\n","import '@/components/mui/icon-button.component.css';\nimport { IconButton as MuiIconButton } from '@mui/material';\nimport { MouseEventHandler, PropsWithChildren } from 'react';\n\nexport type IconButtonProps = PropsWithChildren<{\n /** Optional unique identifier */\n id?: string;\n /**\n * Required. Used as both the tooltip (aka, title) and the aria-label (used for accessibility,\n * testing, etc.), unless a distinct tooltip is supplied.\n */\n label: string;\n /**\n * Enabled status of button\n *\n * @default false\n */\n isDisabled?: boolean;\n /** Optional tooltip to display if different from the aria-label. */\n tooltip?: string;\n /** If true, no tooltip will be displayed. */\n isTooltipSuppressed?: boolean;\n /**\n * If given, uses a negative margin to counteract the padding on one side (this is often helpful\n * for aligning the left or right side of the icon with content above or below, without ruining\n * the border size and shape).\n *\n * @default false\n */\n adjustMarginToAlignToEdge?: 'end' | 'start' | false;\n /**\n * The size of the component. small is equivalent to the dense button styling.\n *\n * @default false\n */\n size: 'small' | 'medium' | 'large';\n /** Additional css classes to help with unique styling of the button */\n className?: string;\n /** Optional click handler */\n onClick?: MouseEventHandler;\n}>;\n\n/**\n * Iconic button a user can click to do something\n *\n * Thanks to MUI for heavy inspiration and documentation\n * https://mui.com/material-ui/getting-started/overview/\n */\nfunction IconButton({\n id,\n label,\n isDisabled = false,\n tooltip,\n isTooltipSuppressed = false,\n adjustMarginToAlignToEdge = false,\n size = 'medium',\n className,\n onClick,\n children,\n}: IconButtonProps) {\n return (\n \n {children /* the icon to display */}\n \n );\n}\n\nexport default IconButton;\n","import { cn } from '@/utils/shadcn-ui.util';\nimport { LoaderCircle, LucideProps } from 'lucide-react';\nimport { forwardRef } from 'react';\n\nexport type SpinnerProps = LucideProps;\n\nconst Spinner = forwardRef(({ className, ...props }, ref) => {\n return (\n \n );\n});\n\nSpinner.displayName = 'Spinner';\n\nexport default Spinner;\n","import { Input as ShadInput } from '@/components/shadcn-ui/input';\nimport { Label as ShadLabel } from '@/components/shadcn-ui/label';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { ChangeEventHandler, FocusEventHandler } from 'react';\n\nexport type TextFieldProps = {\n /** Optional unique identifier */\n id?: string;\n /**\n * If `true`, the component is disabled.\n *\n * @default false\n */\n isDisabled?: boolean;\n /**\n * If `true`, the label is displayed in an error state.\n *\n * @default false\n */\n hasError?: boolean;\n /**\n * If `true`, the input will take up the full width of its container.\n *\n * @default false\n */\n isFullWidth?: boolean;\n /** Text that gives the user instructions on what contents the TextField expects */\n helperText?: string;\n /** The title of the TextField */\n label?: string;\n /** The short hint displayed in the `input` before the user enters a value. */\n placeholder?: string;\n /**\n * If `true`, the label is displayed as required and the `input` element is required.\n *\n * @default false\n */\n isRequired?: boolean;\n /** Additional css classes to help with unique styling of the text field */\n className?: string;\n /** Starting value for the text field if it is not controlled */\n defaultValue?: string | number;\n /** Value of the text field if controlled */\n value?: string | number;\n /** Triggers when content of textfield is changed */\n onChange?: ChangeEventHandler;\n /** Triggers when textfield gets focus */\n onFocus?: FocusEventHandler;\n /** Triggers when textfield loses focus */\n onBlur?: FocusEventHandler;\n};\n\n/**\n * Text input field\n *\n * Thanks to Shadcn for heavy inspiration and documentation\n * https://ui.shadcn.com/docs/components/input#with-label\n */\nfunction TextField({\n id,\n isDisabled = false,\n hasError = false,\n isFullWidth = false,\n helperText,\n label,\n placeholder,\n isRequired = false,\n className,\n defaultValue,\n value,\n onChange,\n onFocus,\n onBlur,\n}: TextFieldProps) {\n return (\n
    \n {`${label}${isRequired ? '*' : ''}`}\n \n

    {helperText}

    \n
    \n );\n}\n\nexport default TextField;\n","import HamburgerMenuButton, {\n MultiColumnMenuProvider,\n} from '@/components/mui/hamburger-menu-button.component';\nimport { CommandHandler } from '@/components/mui/menu-item.component';\nimport '@/components/mui/toolbar.component.css';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { AppBar, Toolbar as MuiToolbar } from '@mui/material';\nimport { PropsWithChildren, useRef } from 'react';\n\nexport type ToolbarProps = PropsWithChildren<{\n /** The handler to use for menu commands (and eventually toolbar commands). */\n commandHandler: CommandHandler;\n\n /**\n * The optional delegate to use to get the menu data. If not specified, the \"hamburger\" menu will\n * not display.\n */\n menuProvider?: MultiColumnMenuProvider;\n\n /** Optional unique identifier */\n id?: string;\n\n /** Additional css classes to help with unique styling of the toolbar */\n className?: string;\n}>;\n\nexport default function Toolbar({\n menuProvider,\n commandHandler,\n className,\n id,\n children,\n}: ToolbarProps) {\n // This ref will always be defined\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const containerRef = useRef(undefined!);\n\n return (\n
    \n \n \n {menuProvider ? (\n \n ) : undefined}\n {children ?
    {children}
    : undefined}\n \n
    \n
    \n );\n}\n","import React from 'react';\nimport { cva, type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst alertVariants = cva(\n 'tw-relative tw-w-full tw-rounded-lg tw-border tw-p-4 [&>svg~*]:tw-pl-7 [&>svg+div]:tw-translate-y-[-3px] [&>svg]:tw-absolute [&>svg]:tw-left-4 [&>svg]:tw-top-4 [&>svg]:tw-text-foreground',\n {\n variants: {\n variant: {\n default: 'tw-bg-background tw-text-foreground',\n destructive:\n 'tw-border-destructive/50 tw-text-destructive dark:tw-border-destructive [&>svg]:tw-text-destructive',\n },\n },\n defaultVariants: {\n variant: 'default',\n },\n },\n);\n\nconst Alert = React.forwardRef<\n HTMLDivElement,\n React.HTMLAttributes & VariantProps\n>(({ className, variant, ...props }, ref) => (\n
    \n));\nAlert.displayName = 'Alert';\n\nconst AlertTitle = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n {/* added because of https://github.com/jsx-eslint/eslint-plugin-jsx-a11y/blob/main/docs/rules/heading-has-content.md */}\n {props.children}{' '}\n \n ),\n);\nAlertTitle.displayName = 'AlertTitle';\n\nconst AlertDescription = React.forwardRef<\n HTMLParagraphElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n
    \n));\nAlertDescription.displayName = 'AlertDescription';\n\nexport { Alert, AlertTitle, AlertDescription };\n","import { ComponentProps } from 'react';\nimport { toast as sonner, Toaster } from 'sonner';\n\ntype SonnerProps = ComponentProps;\n\nfunction Sonner({ ...props }: SonnerProps) {\n return (\n \n );\n}\n\n// The re-export of the sonner function was added manually\nexport { Sonner, sonner };\n","import React from 'react';\nimport * as SliderPrimitive from '@radix-ui/react-slider';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Slider = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n \n \n \n));\nSlider.displayName = SliderPrimitive.Root.displayName;\n\nexport { Slider };\n","import React from 'react';\nimport * as SwitchPrimitives from '@radix-ui/react-switch';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Switch = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n));\nSwitch.displayName = SwitchPrimitives.Root.displayName;\n\nexport { Switch };\n","import React from 'react';\nimport * as TabsPrimitive from '@radix-ui/react-tabs';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport const Tabs = TabsPrimitive.Root;\n\nexport type TabsListProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport type TabsTriggerProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport type TabsContentProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport const TabsList = React.forwardRef<\n React.ElementRef,\n TabsListProps\n>(({ className, ...props }, ref) => (\n \n));\nTabsList.displayName = TabsPrimitive.List.displayName;\n\nexport const TabsTrigger = React.forwardRef<\n React.ElementRef,\n TabsTriggerProps\n>(({ className, ...props }, ref) => (\n \n));\nTabsTrigger.displayName = TabsPrimitive.Trigger.displayName;\n\nexport const TabsContent = React.forwardRef<\n React.ElementRef,\n TabsContentProps\n>(({ className, ...props }, ref) => (\n \n));\nTabsContent.displayName = TabsPrimitive.Content.displayName;\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Download } from 'lucide-react';\n\ntype InstallButtonProps = {\n /** The installing boolean value determines the state of the button. */\n isInstalling: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n /** Optional text for the button. */\n buttonText?: string;\n} & ButtonProps;\n\n/**\n * The InstallButton component is a button designed for initiating installs. It includes visuals for\n * active installing and idle states.\n *\n * @param isInstalling The installing boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @param buttonText Optional text for the button.\n * @returns A install button.\n */\nexport default function InstallButton({\n isInstalling,\n handleClick,\n buttonText,\n className,\n ...props\n}: InstallButtonProps) {\n return (\n \n {isInstalling ? (\n \n ) : (\n <>\n \n {buttonText}\n \n )}\n \n );\n}\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\n\ntype EnableButtonProps = {\n /** The enabling boolean value determines the state of the button. */\n isEnabling: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n} & ButtonProps;\n\n/**\n * The EnableButton component is a button designed for initiating enabling of downloads. It includes\n * visuals for active enabling and idle states.\n *\n * @param isEnabling The enabling boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @returns A button that can be used to enable.\n */\nexport default function EnableButton({\n isEnabling,\n handleClick,\n className,\n ...props\n}: EnableButtonProps) {\n return (\n \n {isEnabling ? (\n <>\n \n Enabling...\n \n ) : (\n 'Enable'\n )}\n \n );\n}\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\n\ntype DisableButtonProps = {\n /** The disabling boolean value determines the state of the button. */\n isDisabling: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n} & ButtonProps;\n\n/**\n * The DisableButton component is a button designed for initiating disabling of downloads. It\n * includes visuals for active disabling and idle states.\n *\n * @param isDisabling The disabling boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @returns A button that can be used to disable.\n */\nexport default function DisableButton({\n isDisabling,\n handleClick,\n className,\n ...props\n}: DisableButtonProps) {\n return (\n \n {isDisabling ? (\n <>\n \n Disabling...\n \n ) : (\n 'Disable'\n )}\n \n );\n}\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\n\ntype UpdateButtonProps = {\n /** The updating boolean value determines the state of the button. */\n isUpdating: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n} & ButtonProps;\n\n/**\n * The UpdateButton component is a button designed for initiating updates for downloaded extensions.\n * It includes visuals for active updating and idle states.\n *\n * @param isUpdating The updating boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @returns A button that can be used to update.\n */\nexport default function UpdateButton({\n isUpdating,\n handleClick,\n className,\n ...props\n}: UpdateButtonProps) {\n return (\n \n {isUpdating ? (\n <>\n \n Updating...\n \n ) : (\n 'Update'\n )}\n \n );\n}\n","import { cn } from '@/utils/shadcn-ui.util';\nimport Markdown, { MarkdownToJSX } from 'markdown-to-jsx';\nimport { useMemo } from 'react';\n\ninterface MarkdownRendererProps {\n /** Optional unique identifier */\n id?: string;\n /** The markdown string to render */\n markdown: string;\n className?: string;\n /**\n * The [`target` attribute for `a` html\n * tags](https://developer.mozilla.org/en-US/docs/Web/HTML/Element/a#target). Defaults to not\n * adding a `target` to `a` tags\n */\n anchorTarget?: string;\n}\n\n/**\n * This component renders markdown content given a markdown string. It uses typography styles from\n * the platform.\n *\n * @param markdown The markdown string to render.\n * @param id Optional unique identifier\n * @returns A div containing the rendered markdown content.\n */\nexport default function MarkdownRenderer({\n id,\n markdown,\n className,\n anchorTarget,\n}: MarkdownRendererProps) {\n const options: MarkdownToJSX.Options = useMemo(\n () => ({\n overrides: {\n a: {\n props: {\n target: anchorTarget,\n },\n },\n },\n }),\n [anchorTarget],\n );\n return (\n
    \n {markdown}\n
    \n );\n}\n","import { Filter, ChevronDown } from 'lucide-react';\nimport { forwardRef } from 'react';\nimport { Button } from '@/components/shadcn-ui/button';\n\n/**\n * The FilterButton component is a button designed for initiating filtering of data. It is designed\n * to be used with the dropdown menu. It uses forwardRef to pass the button to the dropdown trigger\n * asChild.\n *\n * @returns A button that can be used to filter.\n */\nconst FilterButton = forwardRef((props, ref) => {\n return (\n \n \n Filter\n \n \n );\n});\n\nexport default FilterButton;\n","import {\n DropdownMenu,\n DropdownMenuTrigger,\n DropdownMenuContent,\n DropdownMenuLabel,\n DropdownMenuGroup,\n DropdownMenuCheckboxItem,\n DropdownMenuRadioItem,\n DropdownMenuSeparator,\n} from '@/components/shadcn-ui/dropdown-menu';\nimport FilterButton from './buttons/filter-button.component';\n\nexport enum DropdownMenuItemType {\n Check,\n Radio,\n}\n\nexport type DropdownItem = {\n /** The label is the text that will be displayed on the dropdown item. */\n label: string;\n /** The itemType determines the DropdownMenuItemType type as either Check or Radio. */\n itemType: DropdownMenuItemType;\n /** The onClick function is called when the item is clicked. */\n onClick: () => void;\n};\n\nexport type DropdownGroup = {\n /**\n * The label is the text that will be displayed on the dropdown group. It is used to categorize\n * the items in the group.\n */\n label: string;\n /** The items array contains the items that will be displayed in the dropdown group */\n items: DropdownItem[];\n};\n\nexport type FilterDropdownProps = {\n /** Object unique identifier */\n id?: string;\n /** The groups array contains the groups that will be displayed in the dropdown */\n groups: DropdownGroup[];\n}; // TODO: extend the props later\n\n/**\n * The FilterDropdown component is a dropdown designed for filtering content. It includes groups of\n * items that can be checkboxes or radio items.\n *\n * @param id Optional unique identifier\n * @param groups The groups array contains the groups that will be displayed in the dropdown\n * @returns A filter dropdown.\n */\nexport default function FilterDropdown({ id, groups }: FilterDropdownProps) {\n return (\n
    \n {/* TODO: remove this once the DropDown Menu shadcn has an id prop */}\n \n \n \n \n \n {groups.map((group) => (\n
    \n {group.label}\n \n {group.items.map((item) => (\n
    \n {item.itemType === DropdownMenuItemType.Check ? (\n \n {item.label}\n \n ) : (\n \n {item.label}\n \n )}\n
    \n ))}\n
    \n \n
    \n ))}\n
    \n
    \n
    \n );\n}\n","interface NoExtensionsFoundProps {\n /** Optional unique identifier */\n id?: string;\n /** The message to display */\n message: string;\n}\n/**\n * This component displays a message to the user when no extensions are found in the marketplace.\n *\n * @param id Optional unique identifier\n * @param message The message to display.\n * @returns {JSX.Element} - Returns the message component that displays the message to the user.\n */\nexport default function NoExtensionsFound({ id, message }: NoExtensionsFoundProps) {\n return (\n
    \n
    \n

    {message}

    \n
    \n
    \n );\n}\n","import { CircleHelp, Link as LucideLink, User } from 'lucide-react';\nimport { NumberFormat } from 'platform-bible-utils';\n\n/** Interface that stores the parameters passed to the More Info component */\ninterface MoreInfoProps {\n /** Optional unique identifier */\n id?: string;\n /** The category of the extension */\n category: string;\n /** The number of downloads for the extension */\n downloads: Record;\n /** The languages supported by the extension */\n languages: string[];\n /** The URL to the more info page of the extension */\n moreInfoUrl: string;\n}\n/**\n * This component displays the more info section of the extension which includes the category,\n * number of downloads, languages, and links to the website and support\n *\n * @param id Optional unique identifier\n * @param category The category of the extension\n * @param downloads The number of downloads for the extension\n * @param languages The languages supported by the extension\n * @param moreInfoUrl The URL to the more info page of the extension\n * @returns {JSX.Element} - Returns the more info component that displays the category, number of\n * downloads, languages, and links to the website and support\n */\nexport default function MoreInfo({\n id,\n category,\n downloads,\n languages,\n moreInfoUrl,\n}: MoreInfoProps) {\n /**\n * This constant formats the number of downloads into a more readable format.\n *\n * @example 1000 -> 1K\n *\n * @example 1000000 -> 1M\n *\n * @returns The formatted number of downloads\n */\n const numberFormatted = new NumberFormat('en', {\n notation: 'compact',\n compactDisplay: 'short',\n }).format(Object.values(downloads).reduce((a: number, b: number) => a + b, 0));\n\n /** This function scrolls the window to the bottom of the page. */\n const handleScrollToBottom = () => {\n window.scrollTo(0, document.body.scrollHeight);\n };\n\n return (\n \n
    \n
    \n {category}\n
    \n CATEGORY\n
    \n
    \n
    \n
    \n \n {numberFormatted}\n
    \n USERS\n
    \n
    \n
    \n
    \n {languages.slice(0, 3).map((locale) => (\n \n {locale.toUpperCase()}\n \n ))}\n
    \n {languages.length > 3 && (\n handleScrollToBottom()}\n className=\"tw-text-xs tw-text-gray-500 tw-underline\"\n >\n +{languages.length - 3} more languages\n \n )}\n
    \n
    \n
    \n \n Website\n \n \n \n Support\n \n \n
    \n
    \n );\n}\n","import { useState } from 'react';\n\nexport type VersionInformation = {\n /** Date the version was published */\n date: string;\n /** Description of the changes in the version */\n description: string;\n};\n\n/** Type to store the version history information */\nexport type VersionHistoryType = Record;\n\n/** Interface that stores the parameters passed to the Version History component */\ninterface VersionHistoryProps {\n /** Optional unique identifier */\n id?: string;\n /** Object containing the versions mapped with their information */\n versionHistory: VersionHistoryType;\n}\n\n/**\n * Component to render the version history information shown in the footer component. Lists the 5\n * most recent versions, with the options to show all versions by pressing a button.\n *\n * @param versionHistory Object containing the versions mapped with their information\n * @param id Optional unique identifier\n * @returns Rendered version history for the Footer component\n */\nexport default function VersionHistory({ id, versionHistory }: VersionHistoryProps) {\n const [showAllVersions, setShowAllVersions] = useState(false);\n const currentDate = new Date();\n\n /**\n * Function to format the time string for the version history in the form of 'X year(s) ago'.\n *\n * @param dateString ISO Date string to determine the time string from\n * @returns Formatted time string\n */\n function formatTimeString(dateString: string) {\n const date = new Date(dateString);\n const dateDiff = new Date(currentDate.getTime() - date.getTime());\n const yearDiff = dateDiff.getUTCFullYear() - 1970;\n const monthDiff = dateDiff.getUTCMonth();\n const dayDiff = dateDiff.getUTCDate() - 1;\n\n // Determines how long ago the version was published\n let timeString = '';\n if (yearDiff > 0) {\n timeString = `${yearDiff.toString()} year${yearDiff === 1 ? '' : 's'} ago`;\n } else if (monthDiff > 0) {\n timeString = `${monthDiff.toString()} month${monthDiff === 1 ? '' : 's'} ago`;\n } else if (dayDiff === 0) {\n timeString = 'today';\n } else {\n timeString = `${dayDiff.toString()} day${dayDiff === 1 ? '' : 's'} ago`;\n }\n\n return timeString;\n }\n\n // Sorts the version history by version number\n const sortedEntries = Object.entries(versionHistory).sort((a, b) => b[0].localeCompare(a[0]));\n\n return (\n
    \n

    What`s New

    \n
      \n {(showAllVersions ? sortedEntries : sortedEntries.slice(0, 5)).map((entry) => (\n
      \n
      \n
    • \n {entry[1].description}\n
    • \n
      \n
      \n
      Version {entry[0]}
      \n
      {formatTimeString(entry[1].date)}
      \n
      \n
      \n ))}\n
    \n {sortedEntries.length > 5 && (\n setShowAllVersions(!showAllVersions)}\n className=\"tw-text-xs tw-text-gray-500 tw-underline\"\n >\n {showAllVersions ? 'Show Less Version History' : 'Show All Version History'}\n \n )}\n
    \n );\n}\n","import { useMemo } from 'react';\nimport { formatBytes } from 'platform-bible-utils';\nimport VersionHistory, { VersionHistoryType } from './version-history.component';\n\n/** Interface to store the parameters passed to the Footer component */\ninterface FooterProps {\n /** Optional unique identifier */\n id?: string;\n /** Name of the publisher */\n publisherDisplayName: string;\n /** Size of the extension file in bytes */\n fileSize: number;\n /** List of language codes supported by the extension */\n locales: string[];\n /** Object containing the version history mapped with their information */\n versionHistory: VersionHistoryType;\n}\n\n/**\n * Component to render the footer for the extension details which contains information on the\n * publisher, version history, languages, and file size.\n *\n * @param id Optional unique identifier\n * @param publisherDisplayName Name of the publisher\n * @param fileSize Size of the extension file in bytes\n * @param locales List of language codes supported by the extension\n * @param versionHistory Object containing the version history mapped with their information\n * @returns The rendered Footer component\n */\nexport default function Footer({\n id,\n publisherDisplayName,\n fileSize,\n locales,\n versionHistory,\n}: FooterProps) {\n /** Formats the file size into a human-readable format */\n const formattedFileSize = useMemo(() => formatBytes(fileSize), [fileSize]);\n\n /**\n * This function gets the display names of the languages based on the language codes.\n *\n * @param codes The list of language codes\n * @returns The list of language names\n */\n const getLanguageNames = (codes: string[]) => {\n const displayNames = new Intl.DisplayNames(navigator.language, { type: 'language' });\n return codes.map((code) => displayNames.of(code));\n };\n\n const languageNames = getLanguageNames(locales);\n\n return (\n
    \n
    \n \n
    \n
    \n

    Information

    \n
    \n

    \n Publisher\n {publisherDisplayName}\n Size\n {formattedFileSize}\n

    \n
    \n

    \n Languages\n {languageNames.join(', ')}\n

    \n
    \n
    \n
    \n
    \n
    \n );\n}\n","import { PlatformEvent, PlatformEventHandler } from 'platform-bible-utils';\nimport { useEffect } from 'react';\n\n/**\n * Adds an event handler to an event so the event handler runs when the event is emitted. Use\n * `papi.network.getNetworkEvent` to use a networked event with this hook.\n *\n * @param event The event to subscribe to.\n *\n * - If event is a `PlatformEvent`, that event will be used\n * - If event is undefined, the callback will not be subscribed. Useful if the event is not yet\n * available for example\n *\n * @param eventHandler The callback to run when the event is emitted\n *\n * WARNING: MUST BE STABLE - const or wrapped in useCallback. The reference must not be updated\n * every render\n */\nconst useEvent = (\n event: PlatformEvent | undefined,\n eventHandler: PlatformEventHandler,\n) => {\n useEffect(() => {\n // Do nothing if the event is not provided (in case the event is not yet available, for example)\n if (!event) return () => {};\n\n const unsubscriber = event(eventHandler);\n return () => {\n unsubscriber();\n };\n }, [event, eventHandler]);\n};\nexport default useEvent;\n","import { useCallback, useEffect } from 'react';\nimport { PlatformEvent, PlatformEventAsync, PlatformEventHandler } from 'platform-bible-utils';\nimport usePromise from './use-promise.hook';\n\nconst noopUnsubscriber = () => false;\n\n/**\n * Adds an event handler to an asynchronously subscribing/unsubscribing event so the event handler\n * runs when the event is emitted. Use `papi.network.getNetworkEvent` to use a networked event with\n * this hook.\n *\n * @param event The asynchronously (un)subscribing event to subscribe to.\n *\n * - If event is a `PlatformEvent` or `PlatformEventAsync`, that event will be used\n * - If event is undefined, the callback will not be subscribed. Useful if the event is not yet\n * available for example\n *\n * @param eventHandler The callback to run when the event is emitted\n *\n * WARNING: MUST BE STABLE - const or wrapped in useCallback. The reference must not be updated\n * every render\n */\nconst useEventAsync = (\n event: PlatformEvent | PlatformEventAsync | undefined,\n eventHandler: PlatformEventHandler,\n) => {\n // Subscribe to the event asynchronously\n const [unsubscribe] = usePromise(\n useCallback(async () => {\n // Do nothing if the event is not provided (in case the event is not yet available, for example)\n if (!event) return noopUnsubscriber;\n\n // Wrap subscribe and unsubscribe in promises to allow normal events to be used as well\n const unsub = await Promise.resolve(event(eventHandler));\n return async () => unsub();\n }, [eventHandler, event]),\n noopUnsubscriber,\n // We want the unsubscriber to return to default value immediately upon changing subscription\n // So the useEffect below will unsubscribe asap\n { preserveValue: false },\n );\n\n // Unsubscribe from the event asynchronously (but we aren't awaiting the unsub)\n useEffect(() => {\n return () => {\n if (unsubscribe !== noopUnsubscriber) {\n unsubscribe();\n }\n };\n }, [unsubscribe]);\n};\n\nexport default useEventAsync;\n"],"names":["twMergeCustom","extendTailwindMerge","cn","inputs","clsx","Input","React","className","type","props","ref","jsx","BookChapterInput","forwardRef","handleSearch","handleKeyDown","handleOnClick","handleSubmit","jsxs","ShadInput","event","e","History","P","R","s","n","N","B","O","S","K","g","k","x","T","X","V","w","L","G","A","H","C","I","y","q","U","m","l","h","c","E","D","i","a","o","u","v","f","d","b","J","DropdownMenu","DropdownMenuPrimitive","DropdownMenuTrigger","DropdownMenuGroup","DropdownMenuPortal","DropdownMenuSub","DropdownMenuRadioGroup","DropdownMenuSubTrigger","inset","children","ChevronRight","DropdownMenuSubContent","DropdownMenuContent","sideOffset","DropdownMenuItem","DropdownMenuCheckboxItem","checked","Check","DropdownMenuRadioItem","Circle","DropdownMenuLabel","DropdownMenuSeparator","DropdownMenuShortcut","BookMenuItem","bookId","handleSelectBook","isSelected","handleHighlightBook","bookType","ShadDropdownMenuItem","Canon","ChapterSelect","handleSelectChapter","endChapter","activeChapter","highlightedChapter","handleHighlightedChapter","chapters","_","handleMouse","useCallback","chapterNumber","chapter","GoToMenuItem","handleSort","handleLocationHistory","handleBookmarks","ShadDropdownMenuLabel","ArrowDownWideNarrow","Clock","Bookmark","ALL_BOOK_IDS","BOOK_TYPE_LABELS","BOOK_TYPE_ARRAY","SCROLL_OFFSET","SEARCH_QUERY_FORMATS","fetchGroupedBooks","fetchEndChapter","getChaptersForBook","getAllEnglishNames","isValidBookEnglishName","bookName","getBookIdFromEnglishName","formattedBookName","BookChapterControl","scrRef","searchQuery","setSearchQuery","useState","selectedBookId","setSelectedBookId","setHighlightedChapter","highlightedBookId","setHighlightedBookId","isContentOpen","setIsContentOpen","isContentOpenDelayed","setIsContentOpenDelayed","inputRef","useRef","contentRef","menuItemRef","fetchFilteredBooks","englishNameLowerCase","normalizedQuery","handleSearchInput","searchString","shouldPreventAutoClosing","controlMenuState","open","updateReference","shouldClose","verse","handleInputSubmit","format","matches","book","englishName","handleKeyDownInput","handleKeyDownContent","key","handleKeyDownMenuItem","chapterOffSet","useEffect","useLayoutEffect","scrollTimeout","scrollPosition","ShadDropdownMenu","ShadDropdownMenuTrigger","ShadDropdownMenuContent","bookTypeIndex","element","ShadDropdownMenuSeparator","buttonVariants","cva","Button","variant","size","asChild","Slot","labelVariants","Label","LabelPrimitive","RadioGroup","RadioGroupPrimitive","RadioGroupItem","Popover","PopoverPrimitive","PopoverTrigger","PopoverContent","align","DialogPortal","DialogPrimitive","DialogOverlay","DialogContent","DialogTitle","DialogDescription","Command","CommandPrimitive","CommandInput","Search","CommandList","CommandEmpty","CommandGroup","CommandSeparator","CommandItem","getOptionLabelDefault","option","ComboBox","id","options","value","onChange","getOptionLabel","buttonPlaceholder","textPlaceholder","commandEmptyMessage","buttonVariant","dir","isDisabled","setOpen","ChevronsUpDown","ChapterRangeSelector","startChapter","handleSelectStartChapter","handleSelectEndChapter","chapterCount","chapterOptions","useMemo","index","Fragment","BookSelectionMode","BOOK_SELECTOR_STRING_KEYS","localizeString","strings","BookSelector","handleBookSelectionModeChange","currentBookName","onSelectBooks","selectedBookIds","localizedStrings","currentBookText","chooseText","chooseBooksText","bookSelectionMode","setBookSelectionMode","onSelectionModeChange","newMode","DataTableViewOptions","table","FilterIcon","column","Select","SelectPrimitive","SelectGroup","SelectValue","SelectTrigger","ChevronDown","SelectScrollUpButton","ChevronUp","SelectScrollDownButton","SelectContent","position","SelectLabel","SelectItem","SelectSeparator","DataTablePagination","pageSize","ArrowLeftIcon","ChevronLeftIcon","ChevronRightIcon","ArrowRightIcon","Table","stickyHeader","TableHeader","TableBody","TableFooter","TableRow","TableHead","TableCell","TableCaption","DataTable","columns","data","enablePagination","showPaginationControls","showColumnVisibilityControls","onRowClickHandler","sorting","setSorting","columnFilters","setColumnFilters","columnVisibility","setColumnVisibility","rowSelection","setRowSelection","useReactTable","getCoreRowModel","getPaginationRowModel","getSortedRowModel","getFilteredRowModel","headerGroup","header","flexRender","_a","row","cell","OccurrencesTable","occurrenceData","setScriptureReference","referenceHeaderText","occurrenceHeaderText","occurrences","uniqueOccurrences","occurrence","uniqueOccurrence","deepEqual","Checkbox","CheckboxPrimitive","getLinesFromUSFM","text","getNumberFromUSFM","regex","match","getBookNumFromId","getStatusForItem","item","approvedItems","unapprovedItems","toggleVariants","Toggle","TogglePrimitive","ToggleGroupContext","ToggleGroup","ToggleGroupPrimitive","ToggleGroupItem","context","getSortingIcon","sortDirection","ArrowUpIcon","ArrowDownIcon","ArrowUpDownIcon","inventoryItemColumn","itemLabel","inventoryAdditionalItemColumn","additionalItemLabel","additionalItemIndex","inventoryCountColumn","countLabel","statusChangeHandler","changedItems","newStatus","onApprovedItemsChange","onUnapprovedItemsChange","newApprovedItems","validItem","newUnapprovedItems","unapprovedItem","inventoryStatusColumn","statusLabel","status","CircleCheckIcon","CircleXIcon","CircleHelpIcon","INVENTORY_STRING_KEYS","filterItemData","itemData","statusFilter","textFilter","filteredItemData","createTableData","scriptureRef","itemRegex","tableData","currentBook","currentChapter","currentVerse","line","items","itemIndex","existingItem","tableEntry","newReference","substring","newItem","Inventory","scriptureReference","extractItems","additionalItemsLabels","scope","onScopeChange","allItemsText","approvedItemsText","unapprovedItemsText","unknownItemsText","scopeBookText","scopeChapterText","scopeVerseText","filterText","showAdditionalItemsText","showAdditionalItems","setShowAdditionalItems","setStatusFilter","setTextFilter","selectedItem","setSelectedItem","reducedTableData","newTableData","firstItem","existingEntry","newTableEntry","filteredTableData","allColumns","numberOfAdditionalItems","additionalColumns","_b","rowClickHandler","newSelection","handleScopeChange","handleStatusFilterChange","SearchBar","onSearch","placeholder","isFullWidth","handleInputChange","VerticalTabs","TabsPrimitive","VerticalTabsList","VerticalTabsTrigger","VerticalTabsContent","TabNavigationContentSearch","tabList","searchPlaceholder","headerTitle","isSearchBarFullWidth","direction","tab","Separator","orientation","decorative","SeparatorPrimitive","Sheet","SheetPrimitive","SheetPortal","SheetOverlay","sheetVariants","SheetContent","side","SheetTitle","SheetDescription","Skeleton","TooltipProvider","TooltipPrimitive","Tooltip","TooltipTrigger","TooltipContent","MOBILE_BREAKPOINT","useIsMobile","isMobile","setIsMobile","mql","SIDEBAR_COOKIE_NAME","SIDEBAR_COOKIE_MAX_AGE","SIDEBAR_WIDTH","SIDEBAR_WIDTH_MOBILE","SIDEBAR_WIDTH_ICON","SIDEBAR_KEYBOARD_SHORTCUT","SidebarContext","useSidebar","SidebarProvider","defaultOpen","openProp","setOpenProp","style","openMobile","setOpenMobile","_open","_setOpen","isOpen","openState","toggleSidebar","state","contextValue","Sidebar","collapsible","SidebarTrigger","onClick","PanelLeft","SidebarRail","SidebarInset","SidebarInput","SidebarHeader","SidebarFooter","SidebarSeparator","SidebarContent","SidebarGroup","SidebarGroupLabel","SidebarGroupAction","SidebarGroupContent","SidebarMenu","SidebarMenuItem","sidebarMenuButtonVariants","SidebarMenuButton","isActive","tooltip","Comp","button","SidebarMenuAction","showOnHover","SidebarMenuBadge","SidebarMenuSkeleton","showIcon","width","SidebarMenuSub","SidebarMenuSubItem","SidebarMenuSubButton","SettingsSidebar","extensionLabels","handleSelectSidebarItem","handleSelectItem","isProjectSetting","label","SettingsSidebarContentSearch","scrBookColId","scrRefColId","typeColId","detailsColId","defaultScrRefColumnName","defaultScrBookGroupName","defaultTypeColumnName","defaultDetailsColumnName","getColumns","colInfo","showSourceColumn","showSrcCol","info","formatScrRef","compareScrRefs","toRefOrRange","scriptureSelection","offsetStart","offsetEnd","scrRefToBBBCCCVVV","getRowKey","ScriptureResultsViewer","sources","showColumnHeaders","scriptureReferenceColumnName","scriptureBookGroupName","typeColumnName","detailsColumnName","onRowSelected","grouping","setGrouping","scriptureResults","source","getExpandedRowModel","getGroupedRowModel","selectedRows","keys","selectedRow","scrBookGroupName","typeGroupName","groupingOptions","handleSelectChange","selectedGrouping","handleRowClick","getEvenOrOddBandingStyle","getIndent","groupingState","rowIndex","ChevronLeft","DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS","getLocalizeKeyForScrollGroupId","ScrollGroupSelector","availableScrollGroupIds","scrollGroupId","onChangeScrollGroupId","localizedStringsDefaulted","localizedStringKey","localizedStringValue","newScrollGroupString","scrollGroupOptionId","SettingsList","SettingsListItem","primary","secondary","isLoading","loadingMessage","SettingsListHeader","includeSeparator","Card","CardHeader","CardTitle","CardDescription","CardContent","CardFooter","SettingsCard","settingsGroupLabel","settingsGroupDescription","Checklist","listItems","selectedListItems","handleSelectListItem","createLabel","_interopRequireDefault","obj","module","chainPropTypes","propType1","propType2","args","_extends","target","isPlainObject","prototype","deepClone","output","deepmerge","p","r","t","z","reactIs_production_min","hasSymbol","REACT_ELEMENT_TYPE","REACT_PORTAL_TYPE","REACT_FRAGMENT_TYPE","REACT_STRICT_MODE_TYPE","REACT_PROFILER_TYPE","REACT_PROVIDER_TYPE","REACT_CONTEXT_TYPE","REACT_ASYNC_MODE_TYPE","REACT_CONCURRENT_MODE_TYPE","REACT_FORWARD_REF_TYPE","REACT_SUSPENSE_TYPE","REACT_SUSPENSE_LIST_TYPE","REACT_MEMO_TYPE","REACT_LAZY_TYPE","REACT_BLOCK_TYPE","REACT_FUNDAMENTAL_TYPE","REACT_RESPONDER_TYPE","REACT_SCOPE_TYPE","isValidElementType","typeOf","object","$$typeof","$$typeofType","AsyncMode","ConcurrentMode","ContextConsumer","ContextProvider","Element","ForwardRef","Lazy","Memo","Portal","Profiler","StrictMode","Suspense","hasWarnedAboutDeprecatedIsAsyncMode","isAsyncMode","isConcurrentMode","isContextConsumer","isContextProvider","isElement","isForwardRef","isFragment","isLazy","isMemo","isPortal","isProfiler","isStrictMode","isSuspense","reactIs_development","reactIsModule","require$$0","require$$1","getOwnPropertySymbols","hasOwnProperty","propIsEnumerable","toObject","val","shouldUseNative","test1","test2","order2","test3","letter","objectAssign","from","to","symbols","ReactPropTypesSecret","ReactPropTypesSecret_1","has","printWarning","loggedTypeFailures","message","checkPropTypes","typeSpecs","values","location","componentName","getStack","typeSpecName","error","err","ex","stack","checkPropTypes_1","ReactIs","assign","require$$2","require$$3","require$$4","emptyFunctionThatReturnsNull","factoryWithTypeCheckers","isValidElement","throwOnDirectAccess","ITERATOR_SYMBOL","FAUX_ITERATOR_SYMBOL","getIteratorFn","maybeIterable","iteratorFn","ANONYMOUS","ReactPropTypes","createPrimitiveTypeChecker","createAnyTypeChecker","createArrayOfTypeChecker","createElementTypeChecker","createElementTypeTypeChecker","createInstanceTypeChecker","createNodeChecker","createObjectOfTypeChecker","createEnumTypeChecker","createUnionTypeChecker","createShapeTypeChecker","createStrictShapeTypeChecker","is","PropTypeError","createChainableTypeChecker","validate","manualPropTypeCallCache","manualPropTypeWarningCount","checkType","isRequired","propName","propFullName","secret","cacheKey","chainedCheckType","expectedType","propValue","propType","getPropType","preciseType","getPreciseType","typeChecker","expectedClass","expectedClassName","actualClassName","getClassName","expectedValues","valuesString","arrayOfTypeCheckers","checker","getPostfixForTypeWarning","expectedTypes","checkerResult","expectedTypesMessage","isNode","invalidValidatorError","shapeTypes","allKeys","iterator","step","entry","isSymbol","emptyFunction","emptyFunctionWithReset","factoryWithThrowingShims","shim","getShim","propTypesModule","isClassComponent","elementType","acceptingRef","safePropName","warningHint","elementAcceptingRef","PropTypes","elementAcceptingRef$1","specialProperty","exactProp","propTypes","unsupportedProps","prop","formatMuiErrorMessage","code","url","REACT_SERVER_CONTEXT_TYPE","REACT_OFFSCREEN_TYPE","enableScopeAPI","enableCacheElement","enableTransitionTracing","enableLegacyHidden","enableDebugTracing","REACT_MODULE_REFERENCE","SuspenseList","hasWarnedAboutDeprecatedIsConcurrentMode","isSuspenseList","fnNameMatchRegex","getFunctionName","fn","getFunctionComponentName","Component","fallback","getWrappedName","outerType","innerType","wrapperName","functionName","getDisplayName","HTMLElementType","refType","refType$1","capitalize","string","_formatMuiErrorMessage","createChainedFunction","funcs","acc","func","debounce","wait","timeout","debounced","later","deprecatedPropType","validator","reason","componentNameSafe","propFullNameSafe","isMuiElement","muiNames","_muiName","_element$type","ownerDocument","node","ownerWindow","requirePropFactory","componentNameInError","prevPropTypes","requiredProp","defaultTypeChecker","typeCheckerResult","setRef","useEnhancedEffect","useEnhancedEffect$1","globalId","useGlobalId","idOverride","defaultId","setDefaultId","maybeReactUseId","useId","reactId","unsupportedProp","useControlled","controlled","defaultProp","name","isControlled","valueState","setValue","defaultValue","setValueIfUncontrolled","newValue","useEventCallback","useForkRef","refs","instance","UNINITIALIZED","useLazyRef","init","initArg","EMPTY","useOnMount","Timeout","delay","useTimeout","hadKeyboardEvent","hadFocusVisibleRecently","hadFocusVisibleRecentlyTimeout","inputTypesWhitelist","focusTriggersKeyboardModality","tagName","handlePointerDown","handleVisibilityChange","prepare","doc","isFocusVisible","useIsFocusVisible","isFocusVisibleRef","handleBlurVisible","handleFocusVisible","resolveProps","defaultProps","defaultSlotProps","slotProps","slotPropName","composeClasses","slots","getUtilityClass","classes","slot","utilityClass","defaultGenerator","createClassNameGenerator","generate","generator","ClassNameGenerator","ClassNameGenerator$1","globalStateClasses","generateUtilityClass","globalStatePrefix","globalStateClass","generateUtilityClasses","result","clamp","min","max","_objectWithoutPropertiesLoose","excluded","sourceKeys","_excluded","sortBreakpointsValues","breakpointsAsArray","breakpoint1","breakpoint2","createBreakpoints","breakpoints","unit","other","sortedValues","up","down","between","start","end","endIndex","only","not","keyIndex","shape","shape$1","responsivePropType","responsivePropType$1","merge","defaultBreakpoints","handleBreakpoints","styleFromPropValue","theme","themeBreakpoints","breakpoint","mediaKey","cssKey","createEmptyBreakpointObject","breakpointsInput","_breakpointsInput$key","breakpointStyleKey","removeUnusedBreakpoints","breakpointKeys","breakpointOutput","getPath","path","checkVars","getStyleValue","themeMapping","transform","propValueFinal","userValue","cssProperty","themeKey","memoize","cache","arg","properties","directions","aliases","getCssProperties","property","marginKeys","paddingKeys","spacingKeys","createUnaryUnit","_getPath","themeSpacing","abs","createUnarySpacing","getValue","transformer","transformed","getStyleFromPropValue","cssProperties","resolveCssProperty","margin","padding","createSpacing","spacingInput","spacing","argsInput","argument","compose","styles","handlers","borderTransform","createBorderStyle","border","borderTop","borderRight","borderBottom","borderLeft","borderColor","borderTopColor","borderRightColor","borderBottomColor","borderLeftColor","outline","outlineColor","borderRadius","gap","columnGap","rowGap","gridColumn","gridRow","gridAutoFlow","gridAutoColumns","gridAutoRows","gridTemplateColumns","gridTemplateRows","gridTemplateAreas","gridArea","paletteTransform","color","bgcolor","backgroundColor","sizingTransform","maxWidth","_props$theme","_props$theme2","breakpointsValues","minWidth","height","maxHeight","minHeight","boxSizing","defaultSxConfig","defaultSxConfig$1","objectsHaveSameKeys","objects","union","callIfFn","maybeFn","unstable_createStyleFunctionSx","getThemeValue","config","styleFunctionSx","_theme$unstable_sxCon","sx","traverse","sxInput","sxObject","emptyBreakpoints","breakpointsKeys","css","styleKey","styleFunctionSx$1","applyStyles","createTheme","paletteInput","shapeInput","muiTheme","isObjectEmpty","useTheme","defaultTheme","contextTheme","ThemeContext","systemDefaultTheme","useThemeWithoutDefault","_excluded2","_excluded3","isEmpty","isStringTag","tag","shouldForwardProp","lowercaseFirstLetter","resolveTheme","themeId","defaultOverridesResolver","processStyleArg","callableStyle","_ref","ownerState","resolvedStylesArg","resolvedStyle","variants","isMatch","createStyled","input","rootShouldForwardProp","slotShouldForwardProp","systemSx","inputOptions","processStyles","componentSlot","inputSkipVariantsResolver","inputSkipSx","overridesResolver","skipVariantsResolver","skipSx","shouldForwardPropOption","defaultStyledResolver","styledEngineStyled","transformStyleArg","stylesArg","muiStyledResolver","styleArg","expressions","transformedStyleArg","expressionsWithDefaultTheme","styleOverrides","resolvedStyleOverrides","slotKey","slotStyle","_theme$components","themeVariants","numOfCustomFnsApplied","placeholders","displayName","getThemeProps","params","useThemeProps","clampWrapper","hexToRgb","re","colors","decomposeColor","marker","colorSpace","recomposeColor","hslToRgb","rgb","getLuminance","getContrastRatio","foreground","background","lumA","lumB","alpha","darken","coefficient","lighten","createMixins","mixins","common","common$1","grey","grey$1","purple","purple$1","red","red$1","orange","orange$1","blue","blue$1","lightBlue","lightBlue$1","green","green$1","light","dark","addLightOrDark","intent","shade","tonalOffset","tonalOffsetLight","tonalOffsetDark","getDefaultPrimary","mode","getDefaultSecondary","getDefaultError","getDefaultInfo","getDefaultSuccess","getDefaultWarning","createPalette","palette","contrastThreshold","success","warning","getContrastText","contrastText","contrast","augmentColor","mainShade","lightShade","darkShade","modes","round","caseAllCaps","defaultFontFamily","createTypography","typography","fontFamily","fontSize","fontWeightLight","fontWeightRegular","fontWeightMedium","fontWeightBold","htmlFontSize","allVariants","pxToRem2","coef","pxToRem","buildVariant","fontWeight","lineHeight","letterSpacing","casing","shadowKeyUmbraOpacity","shadowKeyPenumbraOpacity","shadowAmbientShadowOpacity","createShadow","px","shadows","shadows$1","easing","duration","formatMs","milliseconds","getAutoHeightDuration","constant","createTransitions","inputTransitions","mergedEasing","mergedDuration","durationOption","easingOption","isString","isNumber","animatedProp","zIndex","zIndex$1","mixinsInput","transitionsInput","typographyInput","systemTheme","systemCreateTheme","stateClasses","component","child","stateClass","defaultTheme$1","THEME_ID","systemUseThemeProps","styled","styled$1","getSvgIconUtilityClass","useUtilityClasses","SvgIconRoot","_theme$transitions","_theme$transitions$cr","_theme$transitions2","_theme$typography","_theme$typography$pxT","_theme$typography2","_theme$typography2$px","_theme$typography3","_theme$typography3$px","_palette$ownerState$c","_palette","_palette2","_palette3","SvgIcon","inProps","htmlColor","inheritViewBox","titleAccess","viewBox","hasSvgAsChild","more","_jsxs","_jsx","SvgIcon$1","createSvgIcon","unstable_ClassNameGenerator","exports","_utils","ArrowRight","default_1","_createSvgIcon","_jsxRuntime","isHostComponent","appendOwnerState","otherProps","defaultContextValue","ClassNameConfiguratorContext","useClassNamesOverride","disableDefaultClasses","extractEventHandlers","excludeKeys","resolveComponentProps","componentProps","slotState","omitEventHandlers","mergeSlotProps","parameters","getSlotProps","additionalProps","externalSlotProps","externalForwardedProps","joinedClasses","mergedStyle","eventHandlers","componentsPropsWithoutEventHandlers","otherPropsWithoutEventHandlers","internalSlotProps","useSlotProps","_parameters$additiona","skipResolvingSlotProps","rest","resolvedComponentsProps","mergedProps","internalRef","GLOBAL_CLASS_PREFIX","buildStateClass","buildSlotClass","getContainer","container","forwardedRef","disablePortal","mountNode","setMountNode","handleRef","newProps","ReactDOM","top","bottom","right","left","auto","basePlacements","clippingParents","viewport","popper","reference","variationPlacements","placement","placements","beforeRead","read","afterRead","beforeMain","main","afterMain","beforeWrite","write","afterWrite","modifierPhases","getNodeName","getWindow","OwnElement","isHTMLElement","isShadowRoot","attributes","effect","_ref2","initialStyles","styleProperties","attribute","applyStyles$1","getBasePlacement","getUAString","uaData","isLayoutViewport","getBoundingClientRect","includeScale","isFixedStrategy","clientRect","scaleX","scaleY","visualViewport","addVisualOffsets","getLayoutRect","contains","parent","rootNode","next","getComputedStyle","isTableElement","getDocumentElement","getParentNode","getTrueOffsetParent","getContainingBlock","isFirefox","isIE","elementCss","currentNode","getOffsetParent","window","offsetParent","getMainAxisFromPlacement","within","mathMax","mathMin","withinMaxClamp","getFreshSideObject","mergePaddingObject","paddingObject","expandToHashMap","hashMap","toPaddingObject","arrow","_state$modifiersData$","arrowElement","popperOffsets","basePlacement","axis","isVertical","len","arrowRect","minProp","maxProp","endDiff","startDiff","arrowOffsetParent","clientSize","centerToReference","center","offset","axisProp","_options$element","arrow$1","getVariation","unsetSides","roundOffsetsByDPR","win","dpr","mapToStyles","_Object$assign2","popperRect","variation","offsets","gpuAcceleration","adaptive","roundOffsets","isFixed","_offsets$x","_offsets$y","_ref3","hasX","hasY","sideX","sideY","heightProp","widthProp","offsetY","offsetX","commonStyles","_ref4","_Object$assign","computeStyles","_ref5","_options$gpuAccelerat","_options$adaptive","_options$roundOffsets","computeStyles$1","passive","_options$scroll","scroll","_options$resize","resize","scrollParents","scrollParent","eventListeners","hash","getOppositePlacement","matched","getOppositeVariationPlacement","getWindowScroll","scrollLeft","scrollTop","getWindowScrollBarX","getViewportRect","strategy","html","layoutViewport","getDocumentRect","_element$ownerDocumen","winScroll","body","isScrollParent","_getComputedStyle","overflow","overflowX","overflowY","getScrollParent","listScrollParents","list","isBody","updatedList","rectToClientRect","rect","getInnerBoundingClientRect","getClientRectFromMixedType","clippingParent","getClippingParents","canEscapeClipping","clipperElement","getClippingRect","boundary","rootBoundary","mainClippingParents","firstClippingParent","clippingRect","accRect","computeOffsets","commonX","commonY","mainAxis","detectOverflow","_options","_options$placement","_options$strategy","_options$boundary","_options$rootBoundary","_options$elementConte","elementContext","_options$altBoundary","altBoundary","_options$padding","altContext","clippingClientRect","referenceClientRect","popperClientRect","elementClientRect","overflowOffsets","offsetData","multiply","computeAutoPlacement","flipVariations","_options$allowedAutoP","allowedAutoPlacements","allPlacements","allowedPlacements","overflows","getExpandedFallbackPlacements","oppositePlacement","flip","_options$mainAxis","checkMainAxis","_options$altAxis","checkAltAxis","specifiedFallbackPlacements","_options$flipVariatio","preferredPlacement","isBasePlacement","fallbackPlacements","referenceRect","checksMap","makeFallbackChecks","firstFittingPlacement","_basePlacement","isStartVariation","mainVariationSide","altVariationSide","checks","check","numberOfChecks","_loop","_i","fittingPlacement","_ret","flip$1","getSideOffsets","preventedOffsets","isAnySideFullyClipped","hide","referenceOverflow","popperAltOverflow","referenceClippingOffsets","popperEscapeOffsets","isReferenceHidden","hasPopperEscaped","hide$1","distanceAndSkiddingToXY","rects","invertDistance","skidding","distance","_options$offset","_data$state$placement","offset$1","popperOffsets$1","getAltAxis","preventOverflow","_options$tether","tether","_options$tetherOffset","tetherOffset","altAxis","tetherOffsetValue","normalizedTetherOffsetValue","offsetModifierState","_offsetModifierState$","mainSide","altSide","additive","minLen","maxLen","arrowPaddingObject","arrowPaddingMin","arrowPaddingMax","arrowLen","minOffset","maxOffset","clientOffset","offsetModifierValue","tetherMin","tetherMax","preventedOffset","_offsetModifierState$2","_mainSide","_altSide","_offset","_len","_min","_max","isOriginSide","_offsetModifierValue","_tetherMin","_tetherMax","_preventedOffset","preventOverflow$1","getHTMLElementScroll","getNodeScroll","isElementScaled","getCompositeRect","elementOrVirtualElement","isOffsetParentAnElement","offsetParentIsScaled","documentElement","order","modifiers","map","visited","modifier","sort","requires","dep","depModifier","orderModifiers","orderedModifiers","phase","pending","resolve","mergeByName","merged","current","existing","DEFAULT_OPTIONS","areValidElements","_key","popperGenerator","generatorOptions","_generatorOptions","_generatorOptions$def","defaultModifiers","_generatorOptions$def2","defaultOptions","effectCleanupFns","isDestroyed","setOptionsAction","cleanupModifierEffects","runModifierEffects","_state$elements","_state$orderedModifie","_state$orderedModifie2","_ref$options","cleanupFn","noopFn","createPopper","COMPONENT_NAME","getPopperUtilityClass","flipPlacement","resolveAnchorEl","anchorEl","isVirtualElement","defaultPopperOptions","PopperTooltip","_slots$root","initialPlacement","popperOptions","popperRefProp","TransitionProps","tooltipRef","ownRef","popperRef","handlePopperRef","handlePopperRefRef","rtlPlacement","setPlacement","resolvedAnchorElement","setResolvedAnchorElement","handlePopperUpdate","box","popperModifiers","childProps","Root","rootProps","Popper","containerProp","keepMounted","transition","exited","setExited","handleEnter","handleExited","resolvedAnchorEl","display","transitionProps","useThemeSystem","_setPrototypeOf","_inheritsLoose","subClass","superClass","setPrototypeOf","timeoutsShape","TransitionGroupContext","forceReflow","UNMOUNTED","EXITED","ENTERING","ENTERED","EXITING","Transition","_React$Component","_this","parentGroup","appear","initialStatus","prevState","nextIn","_proto","prevProps","nextStatus","exit","enter","mounting","_this2","appearing","maybeNode","maybeAppearing","timeouts","enterTimeout","_this3","nextState","callback","_this4","active","handler","doesNotHaveTimeoutOrListener","maybeNextCallback","_this$props","pt","noop","Transition$1","reflow","getTransitionProps","_style$transitionDura","_style$transitionTimi","getScale","isWebKit154","Grow","addEndListener","inProp","onEnter","onEntered","onEntering","onExit","onExited","onExiting","TransitionComponent","timer","autoTimeout","nodeRef","normalizedTransitionCallback","maybeIsAppearing","handleEntering","isAppearing","transitionDuration","transitionTimingFunction","handleEntered","handleExiting","handleExit","Grow$1","PopperRoot","BasePopper","components","componentsProps","RootComponent","Popper$1","getTooltipUtilityClass","tooltipClasses","tooltipClasses$1","disableInteractive","touch","TooltipPopper","TooltipTooltip","TooltipArrow","hystersisOpen","hystersisTimer","cursorPosition","composeEventHandler","eventHandler","_slots$popper","_slots$transition","_slots$tooltip","_slots$arrow","_slotProps$popper","_ref6","_slotProps$popper2","_slotProps$transition","_slotProps$tooltip","_ref7","_slotProps$tooltip2","_slotProps$arrow","_ref8","_slotProps$arrow2","childrenProp","describeChild","disableFocusListener","disableHoverListener","disableInteractiveProp","disableTouchListener","enterDelay","enterNextDelay","enterTouchDelay","followCursor","idProp","leaveDelay","leaveTouchDelay","onClose","onOpen","PopperComponentProp","PopperProps","title","TransitionComponentProp","isRtl","childNode","setChildNode","arrowRef","setArrowRef","ignoreNonTouchEvents","closeTimer","enterTimer","leaveTimer","touchTimer","setOpenState","prevUserSelect","stopTouchInteraction","handleOpen","handleClose","handleLeave","focusVisibleRef","setChildIsFocusVisible","handleBlur","handleFocus","detectTouchStart","childrenProps","handleMouseOver","handleMouseLeave","handleTouchStart","handleTouchEnd","nativeEvent","handleMouseMove","nameOrDescProps","titleIsString","interactiveWrapperListeners","_PopperProps$popperOp","tooltipModifiers","PopperComponent","TooltipComponent","ArrowComponent","popperProps","tooltipProps","tooltipArrowProps","TransitionPropsInner","Tooltip$1","getIcon","icon","menuLabel","leading","MuiListItemIcon","MenuItem","allowForLeadingIcons","iconPathBefore","iconPathAfter","hasAutoFocus","isDense","isSubMenuParent","hasDisabledGutters","hasDivider","focusVisibleClassName","menuItem","MuiMenuItem","MuiListItemText","getAllGroups","menuDefinition","SubMenu","setAnchorEl","parentMenuItem","parentItemProps","handleParentMenuItemClick","renderSubMenuItems","includedGroups","group","GroupedMenuItemList","Menu","getOrderedGroupItems","groupId","allItems","menuProps","commandHandler","groupsToInclude","sortedGroups","itemArray","allowSpaceForLeadingIcons","createMenuItemProps","isLastItemInGroup","divKey","itemInfo","menuItemProps","TopLevelMenu","columnId","MenuColumn","metadata","Grid","List","GridMenu","multiColumnMenu","sortedColumns","columnNumbers","columnName","col","getUsePromiseOptionsDefaults","usePromise","promiseFactoryCallback","defaultValueRef","optionsDefaultedRef","setIsLoading","promiseIsCurrent","MenuIcon","HamburgerMenuButton","menuProvider","normalMenu","fullMenu","containerRef","ariaLabelPrefix","isMenuOpen","setMenuOpen","showFullMenu","setShowFullMenu","handleMenuItemClick","handleMenuButtonClick","prevIsOpen","isOpening","menuCommandHandler","command","setOffset","normalMenuData","fullMenuData","menu","IconButton","Drawer","isTooltipSuppressed","adjustMarginToAlignToEdge","MuiIconButton","Spinner","LoaderCircle","TextField","hasError","helperText","onFocus","onBlur","ShadLabel","Toolbar","AppBar","MuiToolbar","alertVariants","Alert","AlertTitle","AlertDescription","Sonner","Toaster","Slider","SliderPrimitive","Switch","SwitchPrimitives","Tabs","TabsList","TabsTrigger","TabsContent","InstallButton","isInstalling","handleClick","buttonText","Download","EnableButton","isEnabling","DisableButton","isDisabling","UpdateButton","isUpdating","MarkdownRenderer","markdown","anchorTarget","Markdown","FilterButton","Filter","DropdownMenuItemType","DropdownMenuItemType2","FilterDropdown","groups","NoExtensionsFound","MoreInfo","category","downloads","languages","moreInfoUrl","numberFormatted","NumberFormat","handleScrollToBottom","User","locale","LucideLink","CircleHelp","VersionHistory","versionHistory","showAllVersions","setShowAllVersions","currentDate","formatTimeString","dateString","date","dateDiff","yearDiff","monthDiff","dayDiff","timeString","sortedEntries","Footer","publisherDisplayName","fileSize","locales","formattedFileSize","formatBytes","languageNames","codes","displayNames","useEvent","unsubscriber","noopUnsubscriber","useEventAsync","unsubscribe","unsub"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAGA,MAAMA,KAAgBC,GAAoB,EAAE,QAAQ,MAAO,CAAA;AAyDpD,SAASC,KAAMC,GAAsB;AACnC,SAAAH,GAAcI,GAAKD,CAAM,CAAC;AACnC;ACzDO,MAAME,KAAQC,EAAM;AAAA,EACzB,CAAC,EAAE,WAAAC,GAAW,MAAAC,GAAM,GAAGC,EAAA,GAASC,MAE5B,gBAAAC;AAAA,IAAC;AAAA,IAAA;AAAA,MACC,MAAAH;AAAA,MACA,WAAWN;AAAA,QACT;AAAA,QACAK;AAAA,MACF;AAAA,MACA,KAAAG;AAAA,MAEC,GAAGD;AAAA,IAAA;AAAA,EAAA;AAIZ;AACAJ,GAAM,cAAc;ACNpB,MAAMO,KAAmBC;AAAA,EACvB,CACE,EAAE,cAAAC,GAAc,eAAAC,GAAe,eAAAC,GAAe,cAAAC,GAAc,GAAGR,EAAM,GACrEC,MAGE,gBAAAQ,EAAC,OAAI,EAAA,WAAU,eACb,UAAA;AAAA,IAAA,gBAAAP;AAAA,MAACQ;AAAAA,MAAA;AAAA,QACE,GAAGV;AAAA,QACJ,MAAK;AAAA,QACL,WAAU;AAAA,QACV,UAAU,CAACW,MAAUN,EAAaM,EAAM,OAAO,KAAK;AAAA,QACpD,WAAW,CAACC,MAAM;AACZ,UAAAA,EAAE,QAAQ,WACCJ,KAEfF,EAAcM,CAAC;AAAA,QACjB;AAAA,QACA,SAASL;AAAA,QACT,KAAAN;AAAA,MAAA;AAAA,IACF;AAAA,IACA,gBAAAC;AAAA,MAACW;AAAA,MAAA;AAAA,QACC,WAAU;AAAA,QACV,SAAS,MAAM;AAEb,kBAAQ,IAAI,iBAAiB;AAAA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,78,79,80,81,82,83,84,85,86,87,88,89,90,91,92,93,94,95,96,97,98,99,100,101,102,103,104,105,106,107,108,109,110,111,112,113,114,115,116,117,118,119,120,121,122,123,124,125,126,127,128,129,130,131,132,133,134,135,136,137,138,139,140,141,142,143,144,145,146,147,148,149,150,151,152,153,154,155,156,157,158,159,160,161,162,163,164,165,166,167,168,169,170,171,172,173,174,175,176,177,178,179,180,181,182,183,184,185,186,187,188,189,190,191,192,193,194,195,196,197,198,199,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,230]} \ No newline at end of file diff --git a/lib/platform-bible-react/package.json b/lib/platform-bible-react/package.json index 0e9309d412..4496ca3e7a 100644 --- a/lib/platform-bible-react/package.json +++ b/lib/platform-bible-react/package.json @@ -59,12 +59,13 @@ "@radix-ui/react-select": "^2.0.0", "@radix-ui/react-separator": "^1.1.0", "@radix-ui/react-slider": "^1.2.0", - "@radix-ui/react-slot": "^1.0.2", + "@radix-ui/react-slot": "^1.1.0", "@radix-ui/react-switch": "^1.1.0", "@radix-ui/react-tabs": "^1.0.4", "@radix-ui/react-toast": "^1.2.1", "@radix-ui/react-toggle": "^1.1.0", "@radix-ui/react-toggle-group": "^1.1.0", + "@radix-ui/react-tooltip": "^1.1.3", "@tanstack/react-table": "^8.19.2", "autoprefixer": "^10.4.20", "class-variance-authority": "^0.7.0", diff --git a/lib/platform-bible-react/src/components/advanced/settings-components/settings-card.component.tsx b/lib/platform-bible-react/src/components/advanced/settings-components/settings-card.component.tsx new file mode 100644 index 0000000000..ee92194ca8 --- /dev/null +++ b/lib/platform-bible-react/src/components/advanced/settings-components/settings-card.component.tsx @@ -0,0 +1,24 @@ +import { Card, CardDescription, CardHeader, CardTitle } from '@/components/shadcn-ui/card'; +import { CardContent } from '@mui/material'; +import { PropsWithChildren } from 'react'; + +type SettingsCardProps = PropsWithChildren & { + settingsGroupLabel: string; + settingsGroupDescription: string; +}; + +export default function SettingsCard({ + settingsGroupLabel, + settingsGroupDescription, + children, +}: SettingsCardProps) { + return ( + + + {settingsGroupLabel} + {settingsGroupDescription} + + {children} + + ); +} diff --git a/lib/platform-bible-react/src/components/advanced/settings-components/settings-sidebar-content-search.component.tsx b/lib/platform-bible-react/src/components/advanced/settings-components/settings-sidebar-content-search.component.tsx new file mode 100644 index 0000000000..201c3ec4c2 --- /dev/null +++ b/lib/platform-bible-react/src/components/advanced/settings-components/settings-sidebar-content-search.component.tsx @@ -0,0 +1,36 @@ +import { SidebarInset, SidebarProvider } from '@/components/shadcn-ui/sidebar'; +// import { ProjectSettingProperties, SettingProperties } from 'platform-bible-utils'; +import { PropsWithChildren } from 'react'; +import SettingsSidebar from './settings-sidebar.component'; + +export type SettingsSidebarContentSearchProps = { + /** Text direction ltr or rtl */ + direction?: 'ltr' | 'rtl'; + + extensionLabels: string[]; + // projectLabels: string[]; + handleSelectSidebarItem: (key: string, isProjectSetting: boolean) => void; + // renderSettingsProperties: (extension: string) => SettingProperties; + // renderProjectSettingsProperties: (project: string) => ProjectSettingProperties; +} & PropsWithChildren; + +export default function SettingsSidebarContentSearch({ + direction = 'ltr', + extensionLabels, + // projectLabels, + children, + handleSelectSidebarItem, + // renderSettingsProperties, + // renderProjectSettingsProperties. +}: SettingsSidebarContentSearchProps) { + return ( + + + {children} + + ); +} diff --git a/lib/platform-bible-react/src/components/advanced/settings-components/settings-sidebar.component.tsx b/lib/platform-bible-react/src/components/advanced/settings-components/settings-sidebar.component.tsx new file mode 100644 index 0000000000..19140bcd82 --- /dev/null +++ b/lib/platform-bible-react/src/components/advanced/settings-components/settings-sidebar.component.tsx @@ -0,0 +1,80 @@ +import { useState } from 'react'; +import { + Sidebar, + SidebarContent, + SidebarGroup, + SidebarGroupLabel, + SidebarGroupContent, + SidebarMenu, + SidebarMenuItem, + SidebarMenuButton, +} from '../../shadcn-ui/sidebar'; + +export type SettingsSidebarProps = { + /** Optional id */ + id?: string; + + /** Extension labels to list in sidebar */ + extensionLabels: string[]; + + /** Project labels to list in sidebar */ + // projectLabels: string[]; + + handleSelectSidebarItem: (key: string, isProjectSetting: boolean) => void; +}; + +export default function SettingsSidebar({ + id, + extensionLabels, + // projectLabels, + handleSelectSidebarItem, +}: SettingsSidebarProps) { + const [selectedItem, setSelectedItem] = useState(); + + const handleSelectItem = (item: string, isProjectSetting: boolean) => { + setSelectedItem(item); + handleSelectSidebarItem(item, isProjectSetting); + }; + + return ( + + + + Extensions + + + {extensionLabels.map((label) => ( + + handleSelectItem(label, false)} + isActive={label === selectedItem} + > + {label} + + + ))} + + + + + {/* + Projects + + + {projectLabels.map((label) => ( + + handleSelectItem(label)} + isActive={label === selectedItem} + > + {label} + + + ))} + + + */} + + + ); +} diff --git a/lib/platform-bible-react/src/components/advanced/navigation-content-search.component.tsx b/lib/platform-bible-react/src/components/advanced/tab-navigation-content-search.component.tsx similarity index 92% rename from lib/platform-bible-react/src/components/advanced/navigation-content-search.component.tsx rename to lib/platform-bible-react/src/components/advanced/tab-navigation-content-search.component.tsx index 1ef230fd47..eac8722f7a 100644 --- a/lib/platform-bible-react/src/components/advanced/navigation-content-search.component.tsx +++ b/lib/platform-bible-react/src/components/advanced/tab-navigation-content-search.component.tsx @@ -13,7 +13,7 @@ export type TabKeyValueContent = { content: ReactNode; }; -export type NavigationContentSearchProps = { +export type TabNavigationContentSearchProps = { /** List of values and keys for each tab this component should provide */ tabList: TabKeyValueContent[]; @@ -33,14 +33,14 @@ export type NavigationContentSearchProps = { direction?: 'ltr' | 'rtl'; }; -export default function NavigationContentSearch({ +export default function TabNavigationContentSearch({ tabList, onSearch, searchPlaceholder, headerTitle, isSearchBarFullWidth = false, direction = 'ltr', -}: NavigationContentSearchProps) { +}: TabNavigationContentSearchProps) { return (
    diff --git a/lib/platform-bible-react/src/components/hooks/use-mobile.tsx b/lib/platform-bible-react/src/components/hooks/use-mobile.tsx new file mode 100644 index 0000000000..d8fca73432 --- /dev/null +++ b/lib/platform-bible-react/src/components/hooks/use-mobile.tsx @@ -0,0 +1,19 @@ +import * as React from 'react'; + +const MOBILE_BREAKPOINT = 768; + +export default function useIsMobile() { + const [isMobile, setIsMobile] = React.useState(undefined); + + React.useEffect(() => { + const mql = window.matchMedia(`(max-width: ${MOBILE_BREAKPOINT - 1}px)`); + const onChange = () => { + setIsMobile(window.innerWidth < MOBILE_BREAKPOINT); + }; + mql.addEventListener('change', onChange); + setIsMobile(window.innerWidth < MOBILE_BREAKPOINT); + return () => mql.removeEventListener('change', onChange); + }, []); + + return !!isMobile; +} diff --git a/lib/platform-bible-react/src/components/shadcn-ui/sheet.tsx b/lib/platform-bible-react/src/components/shadcn-ui/sheet.tsx new file mode 100644 index 0000000000..5b2d96a454 --- /dev/null +++ b/lib/platform-bible-react/src/components/shadcn-ui/sheet.tsx @@ -0,0 +1,131 @@ +'use client'; + +import * as React from 'react'; +import * as SheetPrimitive from '@radix-ui/react-dialog'; +import { cva, type VariantProps } from 'class-variance-authority'; +import { X } from 'lucide-react'; + +import { cn } from '@/utils/shadcn-ui.util'; + +const Sheet = SheetPrimitive.Root; + +const SheetTrigger = SheetPrimitive.Trigger; + +const SheetClose = SheetPrimitive.Close; + +const SheetPortal = SheetPrimitive.Portal; + +const SheetOverlay = React.forwardRef< + React.ElementRef, + React.ComponentPropsWithoutRef +>(({ className, ...props }, ref) => ( + +)); +SheetOverlay.displayName = SheetPrimitive.Overlay.displayName; + +const sheetVariants = cva( + 'pr-twp tw-fixed tw-z-50 tw-gap-4 tw-bg-background tw-p-6 tw-shadow-lg tw-transition tw-ease-in-out data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-duration-300 data-[state=open]:tw-duration-500', + { + variants: { + side: { + top: 'tw-inset-x-0 tw-top-0 tw-border-b data-[state=closed]:tw-slide-out-to-top data-[state=open]:tw-slide-in-from-top', + bottom: + 'tw-inset-x-0 tw-bottom-0 tw-border-t data-[state=closed]:tw-slide-out-to-bottom data-[state=open]:tw-slide-in-from-bottom', + left: 'tw-inset-y-0 tw-left-0 tw-h-full tw-w-3/4 tw-border-r data-[state=closed]:tw-slide-out-to-left data-[state=open]:tw-slide-in-from-left sm:tw-max-w-sm', + right: + 'tw-inset-y-0 tw-right-0 tw-h-full tw-w-3/4 tw- tw-border-l data-[state=closed]:tw-slide-out-to-right data-[state=open]:tw-slide-in-from-right sm:tw-max-w-sm', + }, + }, + defaultVariants: { + side: 'right', + }, + }, +); + +interface SheetContentProps + extends React.ComponentPropsWithoutRef, + VariantProps {} + +const SheetContent = React.forwardRef< + React.ElementRef, + SheetContentProps +>(({ side = 'right', className, children, ...props }, ref) => ( + + + + {children} + + + Close + + + +)); +SheetContent.displayName = SheetPrimitive.Content.displayName; + +function SheetHeader({ className, ...props }: React.HTMLAttributes) { + return ( +
    + ); +} +SheetHeader.displayName = 'SheetHeader'; + +function SheetFooter({ className, ...props }: React.HTMLAttributes) { + return ( +
    + ); +} +SheetFooter.displayName = 'SheetFooter'; + +const SheetTitle = React.forwardRef< + React.ElementRef, + React.ComponentPropsWithoutRef +>(({ className, ...props }, ref) => ( + +)); +SheetTitle.displayName = SheetPrimitive.Title.displayName; + +const SheetDescription = React.forwardRef< + React.ElementRef, + React.ComponentPropsWithoutRef +>(({ className, ...props }, ref) => ( + +)); +SheetDescription.displayName = SheetPrimitive.Description.displayName; + +export { + Sheet, + SheetPortal, + SheetOverlay, + SheetTrigger, + SheetClose, + SheetContent, + SheetHeader, + SheetFooter, + SheetTitle, + SheetDescription, +}; diff --git a/lib/platform-bible-react/src/components/shadcn-ui/sidebar.tsx b/lib/platform-bible-react/src/components/shadcn-ui/sidebar.tsx new file mode 100644 index 0000000000..b3d1fd03db --- /dev/null +++ b/lib/platform-bible-react/src/components/shadcn-ui/sidebar.tsx @@ -0,0 +1,747 @@ +import React from 'react'; +import { Slot } from '@radix-ui/react-slot'; +import { VariantProps, cva } from 'class-variance-authority'; +import { PanelLeft } from 'lucide-react'; + +import { Button } from '@/components/shadcn-ui/button'; +import { Input } from '@/components/shadcn-ui/input'; +import { Separator } from '@/components/shadcn-ui/separator'; +import { Sheet, SheetContent } from '@/components/shadcn-ui/sheet'; +import { Skeleton } from '@/components/shadcn-ui/skeleton'; +import { + Tooltip, + TooltipContent, + TooltipProvider, + TooltipTrigger, +} from '@/components/shadcn-ui/tooltip'; +import useIsMobile from '@/components/hooks/use-mobile'; +import { cn } from '@/utils/shadcn-ui.util'; + +const SIDEBAR_COOKIE_NAME = 'sidebar:state'; +const SIDEBAR_COOKIE_MAX_AGE = 60 * 60 * 24 * 7; +const SIDEBAR_WIDTH = '16rem'; +const SIDEBAR_WIDTH_MOBILE = '18rem'; +const SIDEBAR_WIDTH_ICON = '3rem'; +const SIDEBAR_KEYBOARD_SHORTCUT = 'b'; + +type SidebarContextProps = { + state: 'expanded' | 'collapsed'; + open: boolean; + setOpen: (open: boolean) => void; + openMobile: boolean; + setOpenMobile: (open: boolean) => void; + isMobile: boolean; + toggleSidebar: () => void; +}; + +const SidebarContext = React.createContext(undefined); + +function useSidebar() { + const context = React.useContext(SidebarContext); + if (!context) { + throw new Error('useSidebar must be used within a SidebarProvider.'); + } + + return context; +} + +const SidebarProvider = React.forwardRef< + HTMLDivElement, + React.ComponentProps<'div'> & { + defaultOpen?: boolean; + open?: boolean; + onOpenChange?: (open: boolean) => void; + } +>( + ( + { + defaultOpen = true, + open: openProp, + onOpenChange: setOpenProp, + className, + style, + children, + ...props + }, + ref, + ) => { + const isMobile = useIsMobile(); + const [openMobile, setOpenMobile] = React.useState(false); + + // This is the internal state of the sidebar. + // We use openProp and setOpenProp for control from outside the component. + const [_open, _setOpen] = React.useState(defaultOpen); + const isOpen = openProp ?? _open; + const setOpen = React.useCallback( + (value: boolean | ((value: boolean) => boolean)) => { + const openState = typeof value === 'function' ? value(isOpen) : value; + if (setOpenProp) { + setOpenProp(openState); + } else { + _setOpen(openState); + } + + // This sets the cookie to keep the sidebar state. + document.cookie = `${SIDEBAR_COOKIE_NAME}=${openState}; path=/; max-age=${SIDEBAR_COOKIE_MAX_AGE}`; + }, + [setOpenProp, isOpen], + ); + + // Helper to toggle the sidebar. + const toggleSidebar = React.useCallback(() => { + return isMobile ? setOpenMobile((open) => !open) : setOpen((open) => !open); + }, [isMobile, setOpen, setOpenMobile]); + + // Adds a keyboard shortcut to toggle the sidebar. + React.useEffect(() => { + const handleKeyDown = (event: KeyboardEvent) => { + if (event.key === SIDEBAR_KEYBOARD_SHORTCUT && (event.metaKey || event.ctrlKey)) { + event.preventDefault(); + toggleSidebar(); + } + }; + + window.addEventListener('keydown', handleKeyDown); + return () => window.removeEventListener('keydown', handleKeyDown); + }, [toggleSidebar]); + + // We add a state so that we can do data-state="expanded" or "collapsed". + // This makes it easier to style the sidebar with Tailwind classes. + const state = isOpen ? 'expanded' : 'collapsed'; + + const contextValue = React.useMemo( + () => ({ + state, + open: isOpen, + setOpen, + isMobile, + openMobile, + setOpenMobile, + toggleSidebar, + }), + [state, isOpen, setOpen, isMobile, openMobile, setOpenMobile, toggleSidebar], + ); + + return ( + + +
    + {children} +
    +
    +
    + ); + }, +); +SidebarProvider.displayName = 'SidebarProvider'; + +const Sidebar = React.forwardRef< + HTMLDivElement, + React.ComponentProps<'div'> & { + side?: 'left' | 'right'; + variant?: 'sidebar' | 'floating' | 'inset'; + collapsible?: 'offcanvas' | 'icon' | 'none'; + } +>( + ( + { + side = 'left', + variant = 'sidebar', + collapsible = 'offcanvas', + className, + children, + ...props + }, + ref, + ) => { + const { isMobile, state, openMobile, setOpenMobile } = useSidebar(); + + if (collapsible === 'none') { + return ( +
    + {children} +
    + ); + } + + if (isMobile) { + return ( + + +
    {children}
    +
    +
    + ); + } + + return ( +
    + {/* This is what handles the sidebar gap on desktop */} +
    +
    +
    + {children} +
    +
    +
    + ); + }, +); +Sidebar.displayName = 'Sidebar'; + +const SidebarTrigger = React.forwardRef< + React.ElementRef, + React.ComponentProps +>(({ className, onClick, ...props }, ref) => { + const { toggleSidebar } = useSidebar(); + + return ( + + ); +}); +SidebarTrigger.displayName = 'SidebarTrigger'; + +const SidebarRail = React.forwardRef>( + ({ className, ...props }, ref) => { + const { toggleSidebar } = useSidebar(); + + return ( + ; + case 'switch': + return ; + case 'slider': + return ; + default: + return

    No content

    ; + } + } + + return ( + + + + + + Example Sidebar + + + + + + Components + + setSidebarSelection('button')}> + Button + + setSidebarSelection('slider')}> + Slider + + setSidebarSelection('switch')}> + Switch + + + + + + + {renderSidebarContent()} + + ); +} diff --git a/lib/platform-bible-react/tailwind.config.ts b/lib/platform-bible-react/tailwind.config.ts index cc39e9f435..46374c2db4 100644 --- a/lib/platform-bible-react/tailwind.config.ts +++ b/lib/platform-bible-react/tailwind.config.ts @@ -56,6 +56,16 @@ const config: Config = { DEFAULT: 'hsl(var(--card))', foreground: 'hsl(var(--card-foreground))', }, + sidebar: { + DEFAULT: 'hsl(var(--sidebar-background))', + foreground: 'hsl(var(--sidebar-foreground))', + primary: 'hsl(var(--sidebar-primary))', + 'primary-foreground': 'hsl(var(--sidebar-primary-foreground))', + accent: 'hsl(var(--sidebar-accent))', + 'accent-foreground': 'hsl(var(--sidebar-accent-foreground))', + border: 'hsl(var(--sidebar-border))', + ring: 'hsl(var(--sidebar-ring))', + }, }, borderRadius: { lg: 'var(--radius)', @@ -64,12 +74,20 @@ const config: Config = { }, keyframes: { 'accordion-down': { - from: { height: '0' }, - to: { height: 'var(--radix-accordion-content-height)' }, + from: { + height: '0', + }, + to: { + height: 'var(--radix-accordion-content-height)', + }, }, 'accordion-up': { - from: { height: 'var(--radix-accordion-content-height)' }, - to: { height: '0' }, + from: { + height: 'var(--radix-accordion-content-height)', + }, + to: { + height: '0', + }, }, }, animation: { diff --git a/package-lock.json b/package-lock.json index e7eded76da..cb70313e26 100644 --- a/package-lock.json +++ b/package-lock.json @@ -835,12 +835,13 @@ "@radix-ui/react-select": "^2.0.0", "@radix-ui/react-separator": "^1.1.0", "@radix-ui/react-slider": "^1.2.0", - "@radix-ui/react-slot": "^1.0.2", + "@radix-ui/react-slot": "^1.1.0", "@radix-ui/react-switch": "^1.1.0", "@radix-ui/react-tabs": "^1.0.4", "@radix-ui/react-toast": "^1.2.1", "@radix-ui/react-toggle": "^1.1.0", "@radix-ui/react-toggle-group": "^1.1.0", + "@radix-ui/react-tooltip": "^1.1.3", "@tanstack/react-table": "^8.19.2", "autoprefixer": "^10.4.20", "class-variance-authority": "^0.7.0", @@ -903,7 +904,8 @@ "lib/platform-bible-react/node_modules/@radix-ui/primitive": { "version": "1.1.0", "resolved": "https://registry.npmjs.org/@radix-ui/primitive/-/primitive-1.1.0.tgz", - "integrity": "sha512-4Z8dn6Upk0qk4P74xBhZ6Hd/w0mPEzOOLxy4xiPXOXqjF7jZS0VAKk7/x/H6FyY2zCkYJqePf1G5KmkmNJ4RBA==" + "integrity": "sha512-4Z8dn6Upk0qk4P74xBhZ6Hd/w0mPEzOOLxy4xiPXOXqjF7jZS0VAKk7/x/H6FyY2zCkYJqePf1G5KmkmNJ4RBA==", + "license": "MIT" }, "lib/platform-bible-react/node_modules/@radix-ui/react-compose-refs": { "version": "1.1.0", @@ -920,9 +922,10 @@ } }, "lib/platform-bible-react/node_modules/@radix-ui/react-context": { - "version": "1.1.0", - "resolved": "https://registry.npmjs.org/@radix-ui/react-context/-/react-context-1.1.0.tgz", - "integrity": "sha512-OKrckBy+sMEgYM/sMmqmErVn0kZqrHPJze+Ql3DzYsDDp0hl0L62nx/2122/Bvps1qz645jlcu2tD9lrRSdf8A==", + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/@radix-ui/react-context/-/react-context-1.1.1.tgz", + "integrity": "sha512-UASk9zi+crv9WteK/NU4PLvOoL3OuE6BWVKNF6hPRBtYBDXQ2u5iu3O59zUlJiTVvkyuycnqrztsHVJwcK9K+Q==", + "license": "MIT", "peerDependencies": { "@types/react": "*", "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" @@ -934,24 +937,25 @@ } }, "lib/platform-bible-react/node_modules/@radix-ui/react-dialog": { - "version": "1.1.1", - "resolved": "https://registry.npmjs.org/@radix-ui/react-dialog/-/react-dialog-1.1.1.tgz", - "integrity": "sha512-zysS+iU4YP3STKNS6USvFVqI4qqx8EpiwmT5TuCApVEBca+eRCbONi4EgzfNSuVnOXvC5UPHHMjs8RXO6DH9Bg==", + "version": "1.1.2", + "resolved": "https://registry.npmjs.org/@radix-ui/react-dialog/-/react-dialog-1.1.2.tgz", + "integrity": "sha512-Yj4dZtqa2o+kG61fzB0H2qUvmwBA2oyQroGLyNtBj1beo1khoQ3q1a2AO8rrQYjd8256CO9+N8L9tvsS+bnIyA==", + "license": "MIT", "dependencies": { "@radix-ui/primitive": "1.1.0", "@radix-ui/react-compose-refs": "1.1.0", - "@radix-ui/react-context": "1.1.0", - "@radix-ui/react-dismissable-layer": "1.1.0", - "@radix-ui/react-focus-guards": "1.1.0", + "@radix-ui/react-context": "1.1.1", + "@radix-ui/react-dismissable-layer": "1.1.1", + "@radix-ui/react-focus-guards": "1.1.1", "@radix-ui/react-focus-scope": "1.1.0", "@radix-ui/react-id": "1.1.0", - "@radix-ui/react-portal": "1.1.1", - "@radix-ui/react-presence": "1.1.0", + "@radix-ui/react-portal": "1.1.2", + "@radix-ui/react-presence": "1.1.1", "@radix-ui/react-primitive": "2.0.0", "@radix-ui/react-slot": "1.1.0", "@radix-ui/react-use-controllable-state": "1.1.0", "aria-hidden": "^1.1.1", - "react-remove-scroll": "2.5.7" + "react-remove-scroll": "2.6.0" }, "peerDependencies": { "@types/react": "*", @@ -969,9 +973,10 @@ } }, "lib/platform-bible-react/node_modules/@radix-ui/react-dismissable-layer": { - "version": "1.1.0", - "resolved": "https://registry.npmjs.org/@radix-ui/react-dismissable-layer/-/react-dismissable-layer-1.1.0.tgz", - "integrity": "sha512-/UovfmmXGptwGcBQawLzvn2jOfM0t4z3/uKffoBlj724+n3FvBbZ7M0aaBOmkp6pqFYpO4yx8tSVJjx3Fl2jig==", + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/@radix-ui/react-dismissable-layer/-/react-dismissable-layer-1.1.1.tgz", + "integrity": "sha512-QSxg29lfr/xcev6kSz7MAlmDnzbP1eI/Dwn3Tp1ip0KT5CUELsxkekFEMVBEoykI3oV39hKT4TKZzBNMbcTZYQ==", + "license": "MIT", "dependencies": { "@radix-ui/primitive": "1.1.0", "@radix-ui/react-compose-refs": "1.1.0", @@ -995,9 +1000,10 @@ } }, "lib/platform-bible-react/node_modules/@radix-ui/react-focus-guards": { - "version": "1.1.0", - "resolved": "https://registry.npmjs.org/@radix-ui/react-focus-guards/-/react-focus-guards-1.1.0.tgz", - "integrity": "sha512-w6XZNUPVv6xCpZUqb/yN9DL6auvpGX3C/ee6Hdi16v2UUy25HV2Q5bcflsiDyT/g5RwbPQ/GIT1vLkeRb+ITBw==", + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/@radix-ui/react-focus-guards/-/react-focus-guards-1.1.1.tgz", + "integrity": "sha512-pSIwfrT1a6sIoDASCSpFwOasEwKTZWDw/iBdtnqKO7v6FeOzYJ7U53cPzYFVR3geGGXgVHaH+CdngrrAzqUGxg==", + "license": "MIT", "peerDependencies": { "@types/react": "*", "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" @@ -1050,9 +1056,10 @@ } }, "lib/platform-bible-react/node_modules/@radix-ui/react-portal": { - "version": "1.1.1", - "resolved": "https://registry.npmjs.org/@radix-ui/react-portal/-/react-portal-1.1.1.tgz", - "integrity": "sha512-A3UtLk85UtqhzFqtoC8Q0KvR2GbXF3mtPgACSazajqq6A41mEQgo53iPzY4i6BwDxlIFqWIhiQ2G729n+2aw/g==", + "version": "1.1.2", + "resolved": "https://registry.npmjs.org/@radix-ui/react-portal/-/react-portal-1.1.2.tgz", + "integrity": "sha512-WeDYLGPxJb/5EGBoedyJbT0MpoULmwnIPMJMSldkuiMsBAv7N1cRdsTWZWht9vpPOiN3qyiGAtbK2is47/uMFg==", + "license": "MIT", "dependencies": { "@radix-ui/react-primitive": "2.0.0", "@radix-ui/react-use-layout-effect": "1.1.0" @@ -1073,9 +1080,10 @@ } }, "lib/platform-bible-react/node_modules/@radix-ui/react-presence": { - "version": "1.1.0", - "resolved": "https://registry.npmjs.org/@radix-ui/react-presence/-/react-presence-1.1.0.tgz", - "integrity": "sha512-Gq6wuRN/asf9H/E/VzdKoUtT8GC9PQc9z40/vEr0VCJ4u5XvvhWIrSsCB6vD2/cH7ugTdSfYq9fLJCcM00acrQ==", + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/@radix-ui/react-presence/-/react-presence-1.1.1.tgz", + "integrity": "sha512-IeFXVi4YS1K0wVZzXNrbaaUvIJ3qdY+/Ih4eHFhWA9SwGR9UDX7Ck8abvL57C4cv3wwMvUE0OG69Qc3NCcTe/A==", + "license": "MIT", "dependencies": { "@radix-ui/react-compose-refs": "1.1.0", "@radix-ui/react-use-layout-effect": "1.1.0" @@ -1121,6 +1129,7 @@ "version": "1.1.0", "resolved": "https://registry.npmjs.org/@radix-ui/react-slot/-/react-slot-1.1.0.tgz", "integrity": "sha512-FUCf5XMfmW4dtYl69pdS4DbxKy8nj4M7SafBgPllysxmdachynNflAdp/gCsnYWNDnge6tI9onzMp5ARYc1KNw==", + "license": "MIT", "dependencies": { "@radix-ui/react-compose-refs": "1.1.0" }, @@ -1169,6 +1178,7 @@ "version": "1.1.0", "resolved": "https://registry.npmjs.org/@radix-ui/react-use-escape-keydown/-/react-use-escape-keydown-1.1.0.tgz", "integrity": "sha512-L7vwWlR1kTTQ3oh7g1O0CBF3YCyyTj8NmhLR+phShpyA50HCfBFKVJTpshm9PzLiKmehsrQzTYTpX9HvmC9rhw==", + "license": "MIT", "dependencies": { "@radix-ui/react-use-callback-ref": "1.1.0" }, @@ -1225,11 +1235,12 @@ } }, "lib/platform-bible-react/node_modules/react-remove-scroll": { - "version": "2.5.7", - "resolved": "https://registry.npmjs.org/react-remove-scroll/-/react-remove-scroll-2.5.7.tgz", - "integrity": "sha512-FnrTWO4L7/Bhhf3CYBNArEG/yROV0tKmTv7/3h9QCFvH6sndeFf1wPqOcbFVu5VAulS5dV1wGT3GZZ/1GawqiA==", + "version": "2.6.0", + "resolved": "https://registry.npmjs.org/react-remove-scroll/-/react-remove-scroll-2.6.0.tgz", + "integrity": "sha512-I2U4JVEsQenxDAKaVa3VZ/JeJZe0/2DxPWL8Tj8yLKctQJQiZM52pn/GWFpSp8dftjM3pSAHVJZscAnC/y+ySQ==", + "license": "MIT", "dependencies": { - "react-remove-scroll-bar": "^2.3.4", + "react-remove-scroll-bar": "^2.3.6", "react-style-singleton": "^2.2.1", "tslib": "^2.1.0", "use-callback-ref": "^1.3.0", @@ -8367,6 +8378,7 @@ "version": "1.1.0", "resolved": "https://registry.npmjs.org/@radix-ui/react-separator/-/react-separator-1.1.0.tgz", "integrity": "sha512-3uBAs+egzvJBDZAzvb/n4NxxOYpnspmWxO2u5NbZ8Y6FM/NdrGSF9bop3Cf6F6C71z1rTSn8KV0Fo2ZVd79lGA==", + "license": "MIT", "dependencies": { "@radix-ui/react-primitive": "2.0.0" }, @@ -9503,6 +9515,299 @@ } } }, + "node_modules/@radix-ui/react-tooltip": { + "version": "1.1.3", + "resolved": "https://registry.npmjs.org/@radix-ui/react-tooltip/-/react-tooltip-1.1.3.tgz", + "integrity": "sha512-Z4w1FIS0BqVFI2c1jZvb/uDVJijJjJ2ZMuPV81oVgTZ7g3BZxobplnMVvXtFWgtozdvYJ+MFWtwkM5S2HnAong==", + "license": "MIT", + "dependencies": { + "@radix-ui/primitive": "1.1.0", + "@radix-ui/react-compose-refs": "1.1.0", + "@radix-ui/react-context": "1.1.1", + "@radix-ui/react-dismissable-layer": "1.1.1", + "@radix-ui/react-id": "1.1.0", + "@radix-ui/react-popper": "1.2.0", + "@radix-ui/react-portal": "1.1.2", + "@radix-ui/react-presence": "1.1.1", + "@radix-ui/react-primitive": "2.0.0", + "@radix-ui/react-slot": "1.1.0", + "@radix-ui/react-use-controllable-state": "1.1.0", + "@radix-ui/react-visually-hidden": "1.1.0" + }, + "peerDependencies": { + "@types/react": "*", + "@types/react-dom": "*", + "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc", + "react-dom": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" + }, + "peerDependenciesMeta": { + "@types/react": { + "optional": true + }, + "@types/react-dom": { + "optional": true + } + } + }, + "node_modules/@radix-ui/react-tooltip/node_modules/@radix-ui/primitive": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/@radix-ui/primitive/-/primitive-1.1.0.tgz", + "integrity": "sha512-4Z8dn6Upk0qk4P74xBhZ6Hd/w0mPEzOOLxy4xiPXOXqjF7jZS0VAKk7/x/H6FyY2zCkYJqePf1G5KmkmNJ4RBA==", + "license": "MIT" + }, + "node_modules/@radix-ui/react-tooltip/node_modules/@radix-ui/react-compose-refs": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/@radix-ui/react-compose-refs/-/react-compose-refs-1.1.0.tgz", + "integrity": "sha512-b4inOtiaOnYf9KWyO3jAeeCG6FeyfY6ldiEPanbUjWd+xIk5wZeHa8yVwmrJ2vderhu/BQvzCrJI0lHd+wIiqw==", + "license": "MIT", + "peerDependencies": { + "@types/react": "*", + "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" + }, + "peerDependenciesMeta": { + "@types/react": { + "optional": true + } + } + }, + "node_modules/@radix-ui/react-tooltip/node_modules/@radix-ui/react-context": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/@radix-ui/react-context/-/react-context-1.1.1.tgz", + "integrity": "sha512-UASk9zi+crv9WteK/NU4PLvOoL3OuE6BWVKNF6hPRBtYBDXQ2u5iu3O59zUlJiTVvkyuycnqrztsHVJwcK9K+Q==", + "license": "MIT", + "peerDependencies": { + "@types/react": "*", + "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" + }, + "peerDependenciesMeta": { + "@types/react": { + "optional": true + } + } + }, + "node_modules/@radix-ui/react-tooltip/node_modules/@radix-ui/react-dismissable-layer": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/@radix-ui/react-dismissable-layer/-/react-dismissable-layer-1.1.1.tgz", + "integrity": "sha512-QSxg29lfr/xcev6kSz7MAlmDnzbP1eI/Dwn3Tp1ip0KT5CUELsxkekFEMVBEoykI3oV39hKT4TKZzBNMbcTZYQ==", + "license": "MIT", + "dependencies": { + "@radix-ui/primitive": "1.1.0", + "@radix-ui/react-compose-refs": "1.1.0", + "@radix-ui/react-primitive": "2.0.0", + "@radix-ui/react-use-callback-ref": "1.1.0", + "@radix-ui/react-use-escape-keydown": "1.1.0" + }, + "peerDependencies": { + "@types/react": "*", + "@types/react-dom": "*", + "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc", + "react-dom": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" + }, + "peerDependenciesMeta": { + "@types/react": { + "optional": true + }, + "@types/react-dom": { + "optional": true + } + } + }, + "node_modules/@radix-ui/react-tooltip/node_modules/@radix-ui/react-id": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/@radix-ui/react-id/-/react-id-1.1.0.tgz", + "integrity": "sha512-EJUrI8yYh7WOjNOqpoJaf1jlFIH2LvtgAl+YcFqNCa+4hj64ZXmPkAKOFs/ukjz3byN6bdb/AVUqHkI8/uWWMA==", + "license": "MIT", + "dependencies": { + "@radix-ui/react-use-layout-effect": "1.1.0" + }, + "peerDependencies": { + "@types/react": "*", + "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" + }, + "peerDependenciesMeta": { + "@types/react": { + "optional": true + } + } + }, + "node_modules/@radix-ui/react-tooltip/node_modules/@radix-ui/react-portal": { + "version": "1.1.2", + "resolved": "https://registry.npmjs.org/@radix-ui/react-portal/-/react-portal-1.1.2.tgz", + "integrity": "sha512-WeDYLGPxJb/5EGBoedyJbT0MpoULmwnIPMJMSldkuiMsBAv7N1cRdsTWZWht9vpPOiN3qyiGAtbK2is47/uMFg==", + "license": "MIT", + "dependencies": { + "@radix-ui/react-primitive": "2.0.0", + "@radix-ui/react-use-layout-effect": "1.1.0" + }, + "peerDependencies": { + "@types/react": "*", + "@types/react-dom": "*", + "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc", + "react-dom": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" + }, + "peerDependenciesMeta": { + "@types/react": { + "optional": true + }, + "@types/react-dom": { + "optional": true + } + } + }, + "node_modules/@radix-ui/react-tooltip/node_modules/@radix-ui/react-presence": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/@radix-ui/react-presence/-/react-presence-1.1.1.tgz", + "integrity": "sha512-IeFXVi4YS1K0wVZzXNrbaaUvIJ3qdY+/Ih4eHFhWA9SwGR9UDX7Ck8abvL57C4cv3wwMvUE0OG69Qc3NCcTe/A==", + "license": "MIT", + "dependencies": { + "@radix-ui/react-compose-refs": "1.1.0", + "@radix-ui/react-use-layout-effect": "1.1.0" + }, + "peerDependencies": { + "@types/react": "*", + "@types/react-dom": "*", + "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc", + "react-dom": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" + }, + "peerDependenciesMeta": { + "@types/react": { + "optional": true + }, + "@types/react-dom": { + "optional": true + } + } + }, + "node_modules/@radix-ui/react-tooltip/node_modules/@radix-ui/react-primitive": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/@radix-ui/react-primitive/-/react-primitive-2.0.0.tgz", + "integrity": "sha512-ZSpFm0/uHa8zTvKBDjLFWLo8dkr4MBsiDLz0g3gMUwqgLHz9rTaRRGYDgvZPtBJgYCBKXkS9fzmoySgr8CO6Cw==", + "license": "MIT", + "dependencies": { + "@radix-ui/react-slot": "1.1.0" + }, + "peerDependencies": { + "@types/react": "*", + "@types/react-dom": "*", + "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc", + "react-dom": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" + }, + "peerDependenciesMeta": { + "@types/react": { + "optional": true + }, + "@types/react-dom": { + "optional": true + } + } + }, + "node_modules/@radix-ui/react-tooltip/node_modules/@radix-ui/react-slot": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/@radix-ui/react-slot/-/react-slot-1.1.0.tgz", + "integrity": "sha512-FUCf5XMfmW4dtYl69pdS4DbxKy8nj4M7SafBgPllysxmdachynNflAdp/gCsnYWNDnge6tI9onzMp5ARYc1KNw==", + "license": "MIT", + "dependencies": { + "@radix-ui/react-compose-refs": "1.1.0" + }, + "peerDependencies": { + "@types/react": "*", + "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" + }, + "peerDependenciesMeta": { + "@types/react": { + "optional": true + } + } + }, + "node_modules/@radix-ui/react-tooltip/node_modules/@radix-ui/react-use-callback-ref": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/@radix-ui/react-use-callback-ref/-/react-use-callback-ref-1.1.0.tgz", + "integrity": "sha512-CasTfvsy+frcFkbXtSJ2Zu9JHpN8TYKxkgJGWbjiZhFivxaeW7rMeZt7QELGVLaYVfFMsKHjb7Ak0nMEe+2Vfw==", + "license": "MIT", + "peerDependencies": { + "@types/react": "*", + "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" + }, + "peerDependenciesMeta": { + "@types/react": { + "optional": true + } + } + }, + "node_modules/@radix-ui/react-tooltip/node_modules/@radix-ui/react-use-controllable-state": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/@radix-ui/react-use-controllable-state/-/react-use-controllable-state-1.1.0.tgz", + "integrity": "sha512-MtfMVJiSr2NjzS0Aa90NPTnvTSg6C/JLCV7ma0W6+OMV78vd8OyRpID+Ng9LxzsPbLeuBnWBA1Nq30AtBIDChw==", + "license": "MIT", + "dependencies": { + "@radix-ui/react-use-callback-ref": "1.1.0" + }, + "peerDependencies": { + "@types/react": "*", + "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" + }, + "peerDependenciesMeta": { + "@types/react": { + "optional": true + } + } + }, + "node_modules/@radix-ui/react-tooltip/node_modules/@radix-ui/react-use-escape-keydown": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/@radix-ui/react-use-escape-keydown/-/react-use-escape-keydown-1.1.0.tgz", + "integrity": "sha512-L7vwWlR1kTTQ3oh7g1O0CBF3YCyyTj8NmhLR+phShpyA50HCfBFKVJTpshm9PzLiKmehsrQzTYTpX9HvmC9rhw==", + "license": "MIT", + "dependencies": { + "@radix-ui/react-use-callback-ref": "1.1.0" + }, + "peerDependencies": { + "@types/react": "*", + "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" + }, + "peerDependenciesMeta": { + "@types/react": { + "optional": true + } + } + }, + "node_modules/@radix-ui/react-tooltip/node_modules/@radix-ui/react-use-layout-effect": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/@radix-ui/react-use-layout-effect/-/react-use-layout-effect-1.1.0.tgz", + "integrity": "sha512-+FPE0rOdziWSrH9athwI1R0HDVbWlEhd+FR+aSDk4uWGmSJ9Z54sdZVDQPZAinJhJXwfT+qnj969mCsT2gfm5w==", + "license": "MIT", + "peerDependencies": { + "@types/react": "*", + "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" + }, + "peerDependenciesMeta": { + "@types/react": { + "optional": true + } + } + }, + "node_modules/@radix-ui/react-tooltip/node_modules/@radix-ui/react-visually-hidden": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/@radix-ui/react-visually-hidden/-/react-visually-hidden-1.1.0.tgz", + "integrity": "sha512-N8MDZqtgCgG5S3aV60INAB475osJousYpZ4cTJ2cFbMpdHS5Y6loLTH8LPtkj2QN0x93J30HT/M3qJXM0+lyeQ==", + "license": "MIT", + "dependencies": { + "@radix-ui/react-primitive": "2.0.0" + }, + "peerDependencies": { + "@types/react": "*", + "@types/react-dom": "*", + "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc", + "react-dom": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" + }, + "peerDependenciesMeta": { + "@types/react": { + "optional": true + }, + "@types/react-dom": { + "optional": true + } + } + }, "node_modules/@radix-ui/react-use-callback-ref": { "version": "1.0.1", "resolved": "https://registry.npmjs.org/@radix-ui/react-use-callback-ref/-/react-use-callback-ref-1.0.1.tgz", @@ -15090,6 +15395,7 @@ "version": "0.7.0", "resolved": "https://registry.npmjs.org/class-variance-authority/-/class-variance-authority-0.7.0.tgz", "integrity": "sha512-jFI8IQw4hczaL4ALINxqLEXQbWcNjoSkloa4IaufXCJr6QawJyw7tuRysRsrE8w2p/4gGaxKIt/hX3qz/IbD1A==", + "license": "Apache-2.0", "dependencies": { "clsx": "2.0.0" }, @@ -27586,9 +27892,10 @@ } }, "node_modules/react-remove-scroll-bar": { - "version": "2.3.4", - "resolved": "https://registry.npmjs.org/react-remove-scroll-bar/-/react-remove-scroll-bar-2.3.4.tgz", - "integrity": "sha512-63C4YQBUt0m6ALadE9XV56hV8BgJWDmmTPY758iIJjfQKt2nYwoUrPk0LXRXcB/yIj82T1/Ixfdpdk68LwIB0A==", + "version": "2.3.6", + "resolved": "https://registry.npmjs.org/react-remove-scroll-bar/-/react-remove-scroll-bar-2.3.6.tgz", + "integrity": "sha512-DtSYaao4mBmX+HDo5YWYdBWQwYIQQshUV/dVxFxK+KM26Wjwp1gZ6rv6OC3oujI6Bfu6Xyg3TwK533AQutsn/g==", + "license": "MIT", "dependencies": { "react-style-singleton": "^2.2.1", "tslib": "^2.0.0" @@ -37834,6 +38141,134 @@ } } }, + "@radix-ui/react-tooltip": { + "version": "1.1.3", + "resolved": "https://registry.npmjs.org/@radix-ui/react-tooltip/-/react-tooltip-1.1.3.tgz", + "integrity": "sha512-Z4w1FIS0BqVFI2c1jZvb/uDVJijJjJ2ZMuPV81oVgTZ7g3BZxobplnMVvXtFWgtozdvYJ+MFWtwkM5S2HnAong==", + "requires": { + "@radix-ui/primitive": "1.1.0", + "@radix-ui/react-compose-refs": "1.1.0", + "@radix-ui/react-context": "1.1.1", + "@radix-ui/react-dismissable-layer": "1.1.1", + "@radix-ui/react-id": "1.1.0", + "@radix-ui/react-popper": "1.2.0", + "@radix-ui/react-portal": "1.1.2", + "@radix-ui/react-presence": "1.1.1", + "@radix-ui/react-primitive": "2.0.0", + "@radix-ui/react-slot": "1.1.0", + "@radix-ui/react-use-controllable-state": "1.1.0", + "@radix-ui/react-visually-hidden": "1.1.0" + }, + "dependencies": { + "@radix-ui/primitive": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/@radix-ui/primitive/-/primitive-1.1.0.tgz", + "integrity": "sha512-4Z8dn6Upk0qk4P74xBhZ6Hd/w0mPEzOOLxy4xiPXOXqjF7jZS0VAKk7/x/H6FyY2zCkYJqePf1G5KmkmNJ4RBA==" + }, + "@radix-ui/react-compose-refs": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/@radix-ui/react-compose-refs/-/react-compose-refs-1.1.0.tgz", + "integrity": "sha512-b4inOtiaOnYf9KWyO3jAeeCG6FeyfY6ldiEPanbUjWd+xIk5wZeHa8yVwmrJ2vderhu/BQvzCrJI0lHd+wIiqw==", + "requires": {} + }, + "@radix-ui/react-context": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/@radix-ui/react-context/-/react-context-1.1.1.tgz", + "integrity": "sha512-UASk9zi+crv9WteK/NU4PLvOoL3OuE6BWVKNF6hPRBtYBDXQ2u5iu3O59zUlJiTVvkyuycnqrztsHVJwcK9K+Q==", + "requires": {} + }, + "@radix-ui/react-dismissable-layer": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/@radix-ui/react-dismissable-layer/-/react-dismissable-layer-1.1.1.tgz", + "integrity": "sha512-QSxg29lfr/xcev6kSz7MAlmDnzbP1eI/Dwn3Tp1ip0KT5CUELsxkekFEMVBEoykI3oV39hKT4TKZzBNMbcTZYQ==", + "requires": { + "@radix-ui/primitive": "1.1.0", + "@radix-ui/react-compose-refs": "1.1.0", + "@radix-ui/react-primitive": "2.0.0", + "@radix-ui/react-use-callback-ref": "1.1.0", + "@radix-ui/react-use-escape-keydown": "1.1.0" + } + }, + "@radix-ui/react-id": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/@radix-ui/react-id/-/react-id-1.1.0.tgz", + "integrity": "sha512-EJUrI8yYh7WOjNOqpoJaf1jlFIH2LvtgAl+YcFqNCa+4hj64ZXmPkAKOFs/ukjz3byN6bdb/AVUqHkI8/uWWMA==", + "requires": { + "@radix-ui/react-use-layout-effect": "1.1.0" + } + }, + "@radix-ui/react-portal": { + "version": "1.1.2", + "resolved": "https://registry.npmjs.org/@radix-ui/react-portal/-/react-portal-1.1.2.tgz", + "integrity": "sha512-WeDYLGPxJb/5EGBoedyJbT0MpoULmwnIPMJMSldkuiMsBAv7N1cRdsTWZWht9vpPOiN3qyiGAtbK2is47/uMFg==", + "requires": { + "@radix-ui/react-primitive": "2.0.0", + "@radix-ui/react-use-layout-effect": "1.1.0" + } + }, + "@radix-ui/react-presence": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/@radix-ui/react-presence/-/react-presence-1.1.1.tgz", + "integrity": "sha512-IeFXVi4YS1K0wVZzXNrbaaUvIJ3qdY+/Ih4eHFhWA9SwGR9UDX7Ck8abvL57C4cv3wwMvUE0OG69Qc3NCcTe/A==", + "requires": { + "@radix-ui/react-compose-refs": "1.1.0", + "@radix-ui/react-use-layout-effect": "1.1.0" + } + }, + "@radix-ui/react-primitive": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/@radix-ui/react-primitive/-/react-primitive-2.0.0.tgz", + "integrity": "sha512-ZSpFm0/uHa8zTvKBDjLFWLo8dkr4MBsiDLz0g3gMUwqgLHz9rTaRRGYDgvZPtBJgYCBKXkS9fzmoySgr8CO6Cw==", + "requires": { + "@radix-ui/react-slot": "1.1.0" + } + }, + "@radix-ui/react-slot": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/@radix-ui/react-slot/-/react-slot-1.1.0.tgz", + "integrity": "sha512-FUCf5XMfmW4dtYl69pdS4DbxKy8nj4M7SafBgPllysxmdachynNflAdp/gCsnYWNDnge6tI9onzMp5ARYc1KNw==", + "requires": { + "@radix-ui/react-compose-refs": "1.1.0" + } + }, + "@radix-ui/react-use-callback-ref": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/@radix-ui/react-use-callback-ref/-/react-use-callback-ref-1.1.0.tgz", + "integrity": "sha512-CasTfvsy+frcFkbXtSJ2Zu9JHpN8TYKxkgJGWbjiZhFivxaeW7rMeZt7QELGVLaYVfFMsKHjb7Ak0nMEe+2Vfw==", + "requires": {} + }, + "@radix-ui/react-use-controllable-state": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/@radix-ui/react-use-controllable-state/-/react-use-controllable-state-1.1.0.tgz", + "integrity": "sha512-MtfMVJiSr2NjzS0Aa90NPTnvTSg6C/JLCV7ma0W6+OMV78vd8OyRpID+Ng9LxzsPbLeuBnWBA1Nq30AtBIDChw==", + "requires": { + "@radix-ui/react-use-callback-ref": "1.1.0" + } + }, + "@radix-ui/react-use-escape-keydown": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/@radix-ui/react-use-escape-keydown/-/react-use-escape-keydown-1.1.0.tgz", + "integrity": "sha512-L7vwWlR1kTTQ3oh7g1O0CBF3YCyyTj8NmhLR+phShpyA50HCfBFKVJTpshm9PzLiKmehsrQzTYTpX9HvmC9rhw==", + "requires": { + "@radix-ui/react-use-callback-ref": "1.1.0" + } + }, + "@radix-ui/react-use-layout-effect": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/@radix-ui/react-use-layout-effect/-/react-use-layout-effect-1.1.0.tgz", + "integrity": "sha512-+FPE0rOdziWSrH9athwI1R0HDVbWlEhd+FR+aSDk4uWGmSJ9Z54sdZVDQPZAinJhJXwfT+qnj969mCsT2gfm5w==", + "requires": {} + }, + "@radix-ui/react-visually-hidden": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/@radix-ui/react-visually-hidden/-/react-visually-hidden-1.1.0.tgz", + "integrity": "sha512-N8MDZqtgCgG5S3aV60INAB475osJousYpZ4cTJ2cFbMpdHS5Y6loLTH8LPtkj2QN0x93J30HT/M3qJXM0+lyeQ==", + "requires": { + "@radix-ui/react-primitive": "2.0.0" + } + } + } + }, "@radix-ui/react-use-callback-ref": { "version": "1.0.1", "resolved": "https://registry.npmjs.org/@radix-ui/react-use-callback-ref/-/react-use-callback-ref-1.0.1.tgz", @@ -49226,12 +49661,13 @@ "@radix-ui/react-select": "^2.0.0", "@radix-ui/react-separator": "^1.1.0", "@radix-ui/react-slider": "^1.2.0", - "@radix-ui/react-slot": "^1.0.2", + "@radix-ui/react-slot": "^1.1.0", "@radix-ui/react-switch": "^1.1.0", "@radix-ui/react-tabs": "^1.0.4", "@radix-ui/react-toast": "^1.2.1", "@radix-ui/react-toggle": "^1.1.0", "@radix-ui/react-toggle-group": "^1.1.0", + "@radix-ui/react-tooltip": "^1.1.3", "@senojs/rollup-plugin-style-inject": "^0.2.3", "@tailwindcss/typography": "^0.5.15", "@tanstack/react-table": "^8.19.2", @@ -49293,36 +49729,36 @@ "requires": {} }, "@radix-ui/react-context": { - "version": "1.1.0", - "resolved": "https://registry.npmjs.org/@radix-ui/react-context/-/react-context-1.1.0.tgz", - "integrity": "sha512-OKrckBy+sMEgYM/sMmqmErVn0kZqrHPJze+Ql3DzYsDDp0hl0L62nx/2122/Bvps1qz645jlcu2tD9lrRSdf8A==", + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/@radix-ui/react-context/-/react-context-1.1.1.tgz", + "integrity": "sha512-UASk9zi+crv9WteK/NU4PLvOoL3OuE6BWVKNF6hPRBtYBDXQ2u5iu3O59zUlJiTVvkyuycnqrztsHVJwcK9K+Q==", "requires": {} }, "@radix-ui/react-dialog": { - "version": "1.1.1", - "resolved": "https://registry.npmjs.org/@radix-ui/react-dialog/-/react-dialog-1.1.1.tgz", - "integrity": "sha512-zysS+iU4YP3STKNS6USvFVqI4qqx8EpiwmT5TuCApVEBca+eRCbONi4EgzfNSuVnOXvC5UPHHMjs8RXO6DH9Bg==", + "version": "1.1.2", + "resolved": "https://registry.npmjs.org/@radix-ui/react-dialog/-/react-dialog-1.1.2.tgz", + "integrity": "sha512-Yj4dZtqa2o+kG61fzB0H2qUvmwBA2oyQroGLyNtBj1beo1khoQ3q1a2AO8rrQYjd8256CO9+N8L9tvsS+bnIyA==", "requires": { "@radix-ui/primitive": "1.1.0", "@radix-ui/react-compose-refs": "1.1.0", - "@radix-ui/react-context": "1.1.0", - "@radix-ui/react-dismissable-layer": "1.1.0", - "@radix-ui/react-focus-guards": "1.1.0", + "@radix-ui/react-context": "1.1.1", + "@radix-ui/react-dismissable-layer": "1.1.1", + "@radix-ui/react-focus-guards": "1.1.1", "@radix-ui/react-focus-scope": "1.1.0", "@radix-ui/react-id": "1.1.0", - "@radix-ui/react-portal": "1.1.1", - "@radix-ui/react-presence": "1.1.0", + "@radix-ui/react-portal": "1.1.2", + "@radix-ui/react-presence": "1.1.1", "@radix-ui/react-primitive": "2.0.0", "@radix-ui/react-slot": "1.1.0", "@radix-ui/react-use-controllable-state": "1.1.0", "aria-hidden": "^1.1.1", - "react-remove-scroll": "2.5.7" + "react-remove-scroll": "2.6.0" } }, "@radix-ui/react-dismissable-layer": { - "version": "1.1.0", - "resolved": "https://registry.npmjs.org/@radix-ui/react-dismissable-layer/-/react-dismissable-layer-1.1.0.tgz", - "integrity": "sha512-/UovfmmXGptwGcBQawLzvn2jOfM0t4z3/uKffoBlj724+n3FvBbZ7M0aaBOmkp6pqFYpO4yx8tSVJjx3Fl2jig==", + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/@radix-ui/react-dismissable-layer/-/react-dismissable-layer-1.1.1.tgz", + "integrity": "sha512-QSxg29lfr/xcev6kSz7MAlmDnzbP1eI/Dwn3Tp1ip0KT5CUELsxkekFEMVBEoykI3oV39hKT4TKZzBNMbcTZYQ==", "requires": { "@radix-ui/primitive": "1.1.0", "@radix-ui/react-compose-refs": "1.1.0", @@ -49332,9 +49768,9 @@ } }, "@radix-ui/react-focus-guards": { - "version": "1.1.0", - "resolved": "https://registry.npmjs.org/@radix-ui/react-focus-guards/-/react-focus-guards-1.1.0.tgz", - "integrity": "sha512-w6XZNUPVv6xCpZUqb/yN9DL6auvpGX3C/ee6Hdi16v2UUy25HV2Q5bcflsiDyT/g5RwbPQ/GIT1vLkeRb+ITBw==", + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/@radix-ui/react-focus-guards/-/react-focus-guards-1.1.1.tgz", + "integrity": "sha512-pSIwfrT1a6sIoDASCSpFwOasEwKTZWDw/iBdtnqKO7v6FeOzYJ7U53cPzYFVR3geGGXgVHaH+CdngrrAzqUGxg==", "requires": {} }, "@radix-ui/react-focus-scope": { @@ -49356,18 +49792,18 @@ } }, "@radix-ui/react-portal": { - "version": "1.1.1", - "resolved": "https://registry.npmjs.org/@radix-ui/react-portal/-/react-portal-1.1.1.tgz", - "integrity": "sha512-A3UtLk85UtqhzFqtoC8Q0KvR2GbXF3mtPgACSazajqq6A41mEQgo53iPzY4i6BwDxlIFqWIhiQ2G729n+2aw/g==", + "version": "1.1.2", + "resolved": "https://registry.npmjs.org/@radix-ui/react-portal/-/react-portal-1.1.2.tgz", + "integrity": "sha512-WeDYLGPxJb/5EGBoedyJbT0MpoULmwnIPMJMSldkuiMsBAv7N1cRdsTWZWht9vpPOiN3qyiGAtbK2is47/uMFg==", "requires": { "@radix-ui/react-primitive": "2.0.0", "@radix-ui/react-use-layout-effect": "1.1.0" } }, "@radix-ui/react-presence": { - "version": "1.1.0", - "resolved": "https://registry.npmjs.org/@radix-ui/react-presence/-/react-presence-1.1.0.tgz", - "integrity": "sha512-Gq6wuRN/asf9H/E/VzdKoUtT8GC9PQc9z40/vEr0VCJ4u5XvvhWIrSsCB6vD2/cH7ugTdSfYq9fLJCcM00acrQ==", + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/@radix-ui/react-presence/-/react-presence-1.1.1.tgz", + "integrity": "sha512-IeFXVi4YS1K0wVZzXNrbaaUvIJ3qdY+/Ih4eHFhWA9SwGR9UDX7Ck8abvL57C4cv3wwMvUE0OG69Qc3NCcTe/A==", "requires": { "@radix-ui/react-compose-refs": "1.1.0", "@radix-ui/react-use-layout-effect": "1.1.0" @@ -49435,11 +49871,11 @@ "requires": {} }, "react-remove-scroll": { - "version": "2.5.7", - "resolved": "https://registry.npmjs.org/react-remove-scroll/-/react-remove-scroll-2.5.7.tgz", - "integrity": "sha512-FnrTWO4L7/Bhhf3CYBNArEG/yROV0tKmTv7/3h9QCFvH6sndeFf1wPqOcbFVu5VAulS5dV1wGT3GZZ/1GawqiA==", + "version": "2.6.0", + "resolved": "https://registry.npmjs.org/react-remove-scroll/-/react-remove-scroll-2.6.0.tgz", + "integrity": "sha512-I2U4JVEsQenxDAKaVa3VZ/JeJZe0/2DxPWL8Tj8yLKctQJQiZM52pn/GWFpSp8dftjM3pSAHVJZscAnC/y+ySQ==", "requires": { - "react-remove-scroll-bar": "^2.3.4", + "react-remove-scroll-bar": "^2.3.6", "react-style-singleton": "^2.2.1", "tslib": "^2.1.0", "use-callback-ref": "^1.3.0", @@ -51135,9 +51571,9 @@ } }, "react-remove-scroll-bar": { - "version": "2.3.4", - "resolved": "https://registry.npmjs.org/react-remove-scroll-bar/-/react-remove-scroll-bar-2.3.4.tgz", - "integrity": "sha512-63C4YQBUt0m6ALadE9XV56hV8BgJWDmmTPY758iIJjfQKt2nYwoUrPk0LXRXcB/yIj82T1/Ixfdpdk68LwIB0A==", + "version": "2.3.6", + "resolved": "https://registry.npmjs.org/react-remove-scroll-bar/-/react-remove-scroll-bar-2.3.6.tgz", + "integrity": "sha512-DtSYaao4mBmX+HDo5YWYdBWQwYIQQshUV/dVxFxK+KM26Wjwp1gZ6rv6OC3oujI6Bfu6Xyg3TwK533AQutsn/g==", "requires": { "react-style-singleton": "^2.2.1", "tslib": "^2.0.0" diff --git a/src/declarations/papi-shared-types.ts b/src/declarations/papi-shared-types.ts index 7bb796a20b..1240ec48c3 100644 --- a/src/declarations/papi-shared-types.ts +++ b/src/declarations/papi-shared-types.ts @@ -57,8 +57,7 @@ declare module 'papi-shared-types' { 'platform.quit': () => Promise; /** Restart the application */ 'platform.restart': () => Promise; - 'platform.openProjectSettings': (webViewId: string) => Promise; - 'platform.openUserSettings': () => Promise; + 'platform.openSettings': (webViewId?: string) => Promise; // These commands are provided in `extension-host.ts`. They are only here because I needed them to // use in other places, but building `papi-dts` wasn't working because it didn't see // `extension-host.ts` diff --git a/src/extension-host/data/menu.data.json b/src/extension-host/data/menu.data.json index f5341c74b4..b1d883cadc 100644 --- a/src/extension-host/data/menu.data.json +++ b/src/extension-host/data/menu.data.json @@ -31,7 +31,7 @@ "localizeNotes": "Application main menu > Project > Settings", "group": "platform.projectSettings", "order": 1, - "command": "platform.openUserSettings" + "command": "platform.openSettings" }, { "label": "%mainMenu_exit%", @@ -76,13 +76,6 @@ "group": "platform.projectTop", "order": 2, "command": "platform.assignments" - }, - { - "label": "%webView_openProjectSettings%", - "localizeNotes": "Web view main menu > Project > Open Project Settings...", - "group": "platform.projectTop", - "order": 3, - "command": "platform.openProjectSettings" } ] }, diff --git a/src/renderer/components/docking/platform-dock-layout-storage.util.ts b/src/renderer/components/docking/platform-dock-layout-storage.util.ts index 3d289a787a..97eb8f2c1b 100644 --- a/src/renderer/components/docking/platform-dock-layout-storage.util.ts +++ b/src/renderer/components/docking/platform-dock-layout-storage.util.ts @@ -31,10 +31,8 @@ import { loadDownloadUpdateProjectTab, } from '@renderer/components/projects/download-update-project-tab.component'; import { - TAB_TYPE_PROJECT_SETTINGS_TAB, - loadProjectSettingsTab, - TAB_TYPE_USER_SETTINGS_TAB, - loadUserSettingsTab, + TAB_TYPE_SETTINGS_TAB, + loadSettingsTab, } from '@renderer/components/settings-tabs/settings-tab.component'; import { TAB_TYPE_WEBVIEW, @@ -67,8 +65,7 @@ if (globalThis.isNoisyDevModeEnabled) { [TAB_TYPE_WEBVIEW, loadWebViewTab], [TAB_TYPE_DOWNLOAD_UPDATE_PROJECT_DIALOG, loadDownloadUpdateProjectTab], [TAB_TYPE_EXTENSION_MANAGER, loadExtensionManagerTab], - [TAB_TYPE_USER_SETTINGS_TAB, loadUserSettingsTab], - [TAB_TYPE_PROJECT_SETTINGS_TAB, loadProjectSettingsTab], + [TAB_TYPE_SETTINGS_TAB, loadSettingsTab], ...Object.entries(DIALOGS).map( ([dialogTabType, dialogDefinition]) => // The default implementation of `loadDialog` uses `this`, so bind it to the definition @@ -82,8 +79,7 @@ if (globalThis.isNoisyDevModeEnabled) { [TAB_TYPE_WEBVIEW, loadWebViewTab], [TAB_TYPE_DOWNLOAD_UPDATE_PROJECT_DIALOG, loadDownloadUpdateProjectTab], [TAB_TYPE_EXTENSION_MANAGER, loadExtensionManagerTab], - [TAB_TYPE_USER_SETTINGS_TAB, loadUserSettingsTab], - [TAB_TYPE_PROJECT_SETTINGS_TAB, loadProjectSettingsTab], + [TAB_TYPE_SETTINGS_TAB, loadSettingsTab], ...Object.entries(DIALOGS).map( ([dialogTabType, dialogDefinition]) => // The default implementation of `loadDialog` uses `this`, so bind it to the definition diff --git a/src/renderer/components/settings-tabs/settings-components/project-or-user-settings-list.component.tsx b/src/renderer/components/settings-tabs/settings-components/project-or-user-settings-list.component.tsx index b600aa9591..b5033d660a 100644 --- a/src/renderer/components/settings-tabs/settings-components/project-or-user-settings-list.component.tsx +++ b/src/renderer/components/settings-tabs/settings-components/project-or-user-settings-list.component.tsx @@ -1,5 +1,5 @@ import { Localized, ProjectSettingProperties, SettingProperties } from 'platform-bible-utils'; -import { SettingsList, SettingsListHeader } from 'platform-bible-react'; +import { SettingsCard } from 'platform-bible-react'; import { useMemo } from 'react'; import { ProjectSettingNames, SettingNames } from 'papi-shared-types'; import UserSetting from './user-setting.component'; @@ -47,10 +47,13 @@ export default function ProjectOrUserSettingsList({ }, [searchQuery, settingProperties]); return ( - - {Object.keys(filteredSettingsProperties).length > 0 ? ( - - ) : undefined} + + {/* // {Object.keys(filteredSettingsProperties).length > 0 ? ( */} + {/* // */} + {/* // ) : undefined} */}
    {Object.entries(filteredSettingsProperties).map(([key, property]) => projectId ? ( @@ -81,6 +84,6 @@ export default function ProjectOrUserSettingsList({ ), )}
    -
    + ); } diff --git a/src/renderer/components/settings-tabs/settings-components/setting.component.tsx b/src/renderer/components/settings-tabs/settings-components/setting.component.tsx index 4c8107f364..719dec214a 100644 --- a/src/renderer/components/settings-tabs/settings-components/setting.component.tsx +++ b/src/renderer/components/settings-tabs/settings-components/setting.component.tsx @@ -5,7 +5,7 @@ import { SettingNames, SettingTypes, } from 'papi-shared-types'; -import { Checkbox, Input, SettingsListItem } from 'platform-bible-react'; +import { Input, SettingsListItem, Switch } from 'platform-bible-react'; import { debounce, getErrorMessage } from 'platform-bible-utils'; import { DataProviderUpdateInstructions } from '@shared/models/data-provider.model'; import { SettingDataTypes } from '@shared/services/settings.service-model'; @@ -174,11 +174,7 @@ export default function Setting({ ); else if (typeof setting === 'boolean') component = ( - + ); else if (typeof setting === 'object') component = ( diff --git a/src/renderer/components/settings-tabs/settings-tab.component.scss b/src/renderer/components/settings-tabs/settings-tab.component.scss index dab47fa502..93d88a49d4 100644 --- a/src/renderer/components/settings-tabs/settings-tab.component.scss +++ b/src/renderer/components/settings-tabs/settings-tab.component.scss @@ -3,3 +3,8 @@ height: inherit; overflow-y: auto; } + +.sidebar { + position: relative; + overflow: hidden; +} diff --git a/src/renderer/components/settings-tabs/settings-tab.component.tsx b/src/renderer/components/settings-tabs/settings-tab.component.tsx index ded1b7e2be..1d762108f1 100644 --- a/src/renderer/components/settings-tabs/settings-tab.component.tsx +++ b/src/renderer/components/settings-tabs/settings-tab.component.tsx @@ -1,136 +1,191 @@ -import { ReactNode, useCallback, useMemo, useState } from 'react'; -import { NavigationContentSearch, TabKeyValueContent, usePromise } from 'platform-bible-react'; -import { Localized, ProjectSettingsGroup, SettingsGroup } from 'platform-bible-utils'; +import { useCallback, useMemo, useState } from 'react'; +import { SettingsSidebarContentSearch, usePromise } from 'platform-bible-react'; import { SavedTabInfo, TabInfo } from '@shared/models/docking-framework.model'; -import projectSettingsService, { - filterProjectSettingsContributionsByProjectInterfaces, -} from '@shared/services/project-settings.service'; -import projectLookupService from '@shared/services/project-lookup.service'; +import projectSettingsService from '@shared/services/project-settings.service'; import settingsService from '@shared/services/settings.service'; -import { useLocalizedStrings } from '@renderer/hooks/papi-hooks'; +// import { useLocalizedStrings } from '@renderer/hooks/papi-hooks'; import ProjectOrUserSettingsList from './settings-components/project-or-user-settings-list.component'; import './settings-tab.component.scss'; -export const TAB_TYPE_PROJECT_SETTINGS_TAB = 'project-settings-tab'; -export const TAB_TYPE_USER_SETTINGS_TAB = 'user-settings-tab'; +export const TAB_TYPE_SETTINGS_TAB = 'settings-tab'; type SettingsTabProps = { + /** Optional project Id, when passed in, will only show settings for that project */ projectId?: string; + /** Optional setting key, when passed in, will scroll to that selected setting in the dialog */ + // settingKey?: string; +}; + +type SelectedSidebarItem = { + label: string; + isProjectSetting: boolean; }; export default function SettingsTab({ projectId }: SettingsTabProps) { - const searchProjectSettingsKey = '%settings_defaultSearchText_searchProject%'; - const searchUserSettingsKey = '%settings_defaultSearchText_searchUserSettings%'; - const [localizedStrings] = useLocalizedStrings( - useMemo(() => [searchProjectSettingsKey, searchUserSettingsKey], []), - ); - const localizedSearchProjectSettings = localizedStrings[searchProjectSettingsKey]; - const localizedSearchUserSettings = localizedStrings[searchUserSettingsKey]; + // const searchProjectSettingsKey = '%settings_defaultSearchText_searchProject%'; + // const searchUserSettingsKey = '%settings_defaultSearchText_searchUserSettings%'; + // const [localizedStrings] = useLocalizedStrings( + // useMemo(() => [searchProjectSettingsKey, searchUserSettingsKey], []), + // ); + // const localizedSearchProjectSettings = localizedStrings[searchProjectSettingsKey]; + // const localizedSearchUserSettings = localizedStrings[searchUserSettingsKey]; + const [selectedSidebarItem, setSelectedSidebarItem] = useState(); const [settingsContributions, isLoadingSettingsContributions] = usePromise( useCallback(async () => { - if (projectId) { - const allProjectSettingsContributionInfo = ( - await projectSettingsService.getLocalizedContributionInfo() - )?.contributions; - - const projectInterfacesFromProjectId = ( - await projectLookupService.getMetadataForProject(projectId) - ).projectInterfaces; - - const filteredContributions = await filterProjectSettingsContributionsByProjectInterfaces( - allProjectSettingsContributionInfo, - projectInterfacesFromProjectId, - ); - return filteredContributions; - } - return (await settingsService.getLocalizedSettingsContributionInfo())?.contributions; - }, [projectId]), + const contributions = (await settingsService.getLocalizedSettingsContributionInfo()) + ?.contributions; + if (!contributions) return undefined; + + // Filter out the extensions that do not have setting groups + const filteredContributions = Object.fromEntries( + Object.entries(contributions).filter( + ([, settingsGroups]) => Array.isArray(settingsGroups) && settingsGroups.length > 0, + ), + ); + + setSelectedSidebarItem({ + label: Object.keys(filteredContributions)[0], + isProjectSetting: false, + }); + + return filteredContributions; + }, []), + useMemo(() => undefined, []), + ); + + const [projectSettingsContributions, isLoadingProjectSettingsContributions] = usePromise( + useCallback(async () => { + const contributions = (await projectSettingsService.getLocalizedContributionInfo()) + ?.contributions; + if (!contributions) return undefined; + + // Filter out the projects that do not have setting groups + const filteredContributions = Object.fromEntries( + Object.entries(contributions).filter( + ([, projectSettingsGroups]) => + Array.isArray(projectSettingsGroups) && projectSettingsGroups.length > 0, + ), + ); + + return filteredContributions; + }, []), useMemo(() => { return undefined; }, []), ); - const [searchQuery, setSearchQuery] = useState(''); + // const getFilteredProjectSettingKeys = useMemo(() => { + // const objectKeys = Object.keys(projectSettingsContributions); - const handleSearchInput = (newSearchTerm: string) => { - setSearchQuery(newSearchTerm); - }; + // objectKeys.filter((key) => ); + // }, []); - const generateFilteredTabContent = useCallback( - (settingsGroup: Localized | Localized): ReactNode => { - return ( - - ); - }, - [projectId, searchQuery], - ); + // const getProjectSettingLabels = () => { + // if (!projectSettingsContributions) return; - const generateTabList = useCallback(() => { - const tabList: TabKeyValueContent[] = []; + // const projectContributionKeysAndLabels: { [projectName: string]: string } = {}; - if (!settingsContributions) return undefined; + // Object.entries(projectSettingsContributions).map( + // ([projectName, settingsGroups]) => + // settingsGroups && + // Object.entries(settingsGroups).map( + // // eslint-disable-next-line no-return-assign + // ([, settingsGroup]) => + // (projectContributionKeysAndLabels[projectName] = settingsGroup.label), + // ), + // ); + // }; - Object.entries(settingsContributions).map( - ([, settingsGroups]) => - settingsGroups && - Object.entries(settingsGroups).map(([, settingsGroup]) => - tabList.push({ - key: settingsGroup.label, - value: settingsGroup.label, - content: generateFilteredTabContent(settingsGroup), - }), - ), - ); + // const getExtensionSettingLabels = () => { + // if (!settingsContributions) return; + + // const contributionKeysAndLabels: { [extensionName: string]: string } = {}; + + // Object.entries(settingsContributions).map( + // ([extensionName, settingsGroups]) => + // settingsGroups && + // Object.entries(settingsGroups).map( + // // eslint-disable-next-line no-return-assign + // ([, settingsGroup]) => (contributionKeysAndLabels[extensionName] = settingsGroup.label), + // ), + // ); + // }; + + const currentlySelectedSettingGroup = useMemo(() => { + if (!selectedSidebarItem) return undefined; - return tabList; - }, [generateFilteredTabContent, settingsContributions]); + let selectedSettingGroup; + if (!selectedSidebarItem.isProjectSetting && settingsContributions) + selectedSettingGroup = settingsContributions[selectedSidebarItem.label]; + else if (selectedSidebarItem.isProjectSetting && projectSettingsContributions) + selectedSettingGroup = projectSettingsContributions[selectedSidebarItem.label]; + + return selectedSettingGroup; + }, [projectSettingsContributions, selectedSidebarItem, settingsContributions]); if (!settingsContributions) return
    No Settings
    ; - if (isLoadingSettingsContributions) return
    Loading Settings
    ; + if (!projectSettingsContributions) return
    No project settings
    ; + if (isLoadingSettingsContributions || isLoadingProjectSettingsContributions) + return
    Loading Settings
    ; + + // TODO: fix + if (projectId) { + const specificProjectContribution = projectSettingsContributions[projectId]; + + return ( +
    + {specificProjectContribution?.forEach((group) => ( + + )) ||
    } +
    + ); + } return (
    - +
    + + setSelectedSidebarItem({ label: key, isProjectSetting }) + } + // selectedSidebarItem={selectedSidebarItem} // TODO: Needed to set the active item + > + {currentlySelectedSettingGroup && Array.isArray(currentlySelectedSettingGroup) + ? currentlySelectedSettingGroup.map((group) => ( + + )) + : undefined} + +
    ); } export type SettingsTabData = SettingsTabProps; -export const loadProjectSettingsTab = (savedTabInfo: SavedTabInfo): TabInfo => { - const typedSavedTabInfo = { - id: savedTabInfo.id, - tabType: savedTabInfo.tabType, - // We use this type in the addTab function, but it doesn't know what data is here - // eslint-disable-next-line no-type-assertion/no-type-assertion - data: savedTabInfo.data as SettingsTabData, - }; +export const loadSettingsTab = (savedTabInfo: SavedTabInfo): TabInfo => { + // We use this type in the addTab function, but it doesn't know what data is here + // eslint-disable-next-line no-type-assertion/no-type-assertion + const tabData: SettingsTabData = savedTabInfo.data as SettingsTabData; - return { - ...savedTabInfo, - tabTitle: '%settings_title_projectSettings%', - content: , - }; -}; + // TODO project name in title ? + const title = tabData.projectId ? 'Project Settings' : 'Settings'; -export const loadUserSettingsTab = (savedTabInfo: SavedTabInfo): TabInfo => { return { ...savedTabInfo, - tabTitle: '%settings_title_userSettings%', - content: , + tabTitle: title, + content: , }; }; diff --git a/src/renderer/services/web-view.service-host.ts b/src/renderer/services/web-view.service-host.ts index 6ae04ffe9d..241b314b2b 100644 --- a/src/renderer/services/web-view.service-host.ts +++ b/src/renderer/services/web-view.service-host.ts @@ -66,8 +66,7 @@ import { registerCommand } from '@shared/services/command.service'; import { CommandNames } from 'papi-shared-types'; import { type SettingsTabData, - TAB_TYPE_PROJECT_SETTINGS_TAB, - TAB_TYPE_USER_SETTINGS_TAB, + TAB_TYPE_SETTINGS_TAB, } from '@renderer/components/settings-tabs/settings-tab.component'; import THEME, { SCROLLBAR_STYLES, MUI_OVERRIDES } from '@renderer/theme'; @@ -1422,16 +1421,14 @@ const papiWebViewService: WebViewServiceType = { getWebViewController, }; -async function openProjectSettingsTab(webViewId: WebViewId): Promise { +async function openSettingsTab(webViewId: WebViewId): Promise { const settingsTabId = newGuid(); const projectIdFromWebView = (await getOpenWebViewDefinition(webViewId))?.projectId; - if (!projectIdFromWebView) return undefined; - return addTab( { id: settingsTabId, - tabType: TAB_TYPE_PROJECT_SETTINGS_TAB, + tabType: TAB_TYPE_SETTINGS_TAB, data: { projectId: projectIdFromWebView, }, @@ -1444,23 +1441,6 @@ async function openProjectSettingsTab(webViewId: WebViewId): Promise { - const settingsTabId = newGuid(); - - return addTab( - { - id: settingsTabId, - tabType: TAB_TYPE_USER_SETTINGS_TAB, - data: {}, - }, - { - type: 'float', - position: 'center', - floatSize: { height: 400, width: 500 }, - }, - ); -} - /** Register the network object that backs the PAPI webview service */ // To use this service, you should use `web-view.service.ts` export async function startWebViewService(): Promise { @@ -1473,8 +1453,7 @@ export async function startWebViewService(): Promise { // This map should allow any functions because commands can be any function type // eslint-disable-next-line @typescript-eslint/no-explicit-any const commandHandlers: { [commandName: string]: (...args: any[]) => any } = { - 'platform.openProjectSettings': openProjectSettingsTab, - 'platform.openUserSettings': openUserSettingsTab, + 'platform.openSettings': openSettingsTab, }; Object.entries(commandHandlers).forEach(([commandName, handler]) => { From 638c0a097719318a27e4dbe7eb3f2a540156a8d8 Mon Sep 17 00:00:00 2001 From: Jolie Rabideau Date: Thu, 21 Nov 2024 17:27:35 -0500 Subject: [PATCH 02/18] Add second combobox className and fix uses, fix project list in sidebar, removed uses of user --- lib/platform-bible-react/dist/index.cjs | 103 +- lib/platform-bible-react/dist/index.cjs.map | 2 +- lib/platform-bible-react/dist/index.d.ts | 50 +- lib/platform-bible-react/dist/index.js | 2024 +++++++++-------- lib/platform-bible-react/dist/index.js.map | 2 +- .../settings-card.component.tsx | 13 +- ...tings-sidebar-content-search.component.tsx | 30 +- .../settings-sidebar.component.tsx | 85 +- .../chapter-range-selector.component.tsx | 4 +- .../components/basics/combo-box.component.tsx | 13 +- lib/platform-bible-react/src/index.ts | 2 + ...ponent.tsx => other-setting.component.tsx} | 19 +- ...ject-or-other-settings-list.component.tsx} | 22 +- .../settings-components/setting.component.tsx | 46 +- .../settings-tabs/settings-tab.component.tsx | 193 +- 15 files changed, 1356 insertions(+), 1252 deletions(-) rename src/renderer/components/settings-tabs/settings-components/{user-setting.component.tsx => other-setting.component.tsx} (62%) rename src/renderer/components/settings-tabs/settings-components/{project-or-user-settings-list.component.tsx => project-or-other-settings-list.component.tsx} (81%) diff --git a/lib/platform-bible-react/dist/index.cjs b/lib/platform-bible-react/dist/index.cjs index 1b24c512de..49a92932a9 100644 --- a/lib/platform-bible-react/dist/index.cjs +++ b/lib/platform-bible-react/dist/index.cjs @@ -1,23 +1,23 @@ -"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const a=require("react/jsx-runtime"),g=require("react"),Q=require("lucide-react"),ot=require("clsx"),ml=require("tailwind-merge"),Za=require("@radix-ui/react-dropdown-menu"),W=require("platform-bible-utils"),Ht=require("@radix-ui/react-slot"),Xt=require("class-variance-authority"),hl=require("@radix-ui/react-label"),gl=require("@radix-ui/react-radio-group"),bl=require("@radix-ui/react-popover"),Oe=require("cmdk"),vl=require("@radix-ui/react-dialog"),Se=require("@tanstack/react-table"),xl=require("@radix-ui/react-select"),yl=require("@radix-ui/react-checkbox"),Nl=require("@radix-ui/react-toggle-group"),kl=require("@radix-ui/react-toggle"),Sl=require("@radix-ui/react-tabs"),El=require("@radix-ui/react-separator"),jl=require("@radix-ui/react-tooltip"),Te=require("@mui/material"),Fr=require("@mui/styled-engine"),ln=require("react-dom"),Qa=require("sonner"),Tl=require("@radix-ui/react-slider"),Cl=require("@radix-ui/react-switch"),Rl=require("markdown-to-jsx");function ke(e){const t=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(e){for(const n in e)if(n!=="default"){const r=Object.getOwnPropertyDescriptor(e,n);Object.defineProperty(t,n,r.get?r:{enumerable:!0,get:()=>e[n]})}}return t.default=e,Object.freeze(t)}const M=ke(g),pe=ke(Za),es=ke(hl),bn=ke(gl),vn=ke(bl),be=ke(vl),ge=ke(xl),Gr=ke(yl),nr=ke(Nl),ts=ke(kl),_e=ke(Sl),ns=ke(El),Sn=ke(jl),Ol=ke(ln),cn=ke(Tl),Ur=ke(Cl);const _l=ml.extendTailwindMerge({prefix:"tw-"});function N(...e){return _l(ot.clsx(e))}const St=g.forwardRef(({className:e,type:t,...n},r)=>a.jsx("input",{type:t,className:N("pr-twp tw-flex tw-h-10 tw-rounded-md tw-border tw-border-input tw-bg-background tw-px-3 tw-py-2 tw-text-sm tw-ring-offset-background file:tw-border-0 file:tw-bg-transparent file:tw-text-sm file:tw-font-medium file:tw-text-foreground placeholder:tw-text-muted-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-cursor-not-allowed disabled:tw-opacity-50",e),ref:r,...n}));St.displayName="Input";const Pl=g.forwardRef(({handleSearch:e,handleKeyDown:t,handleOnClick:n,handleSubmit:r,...o},s)=>a.jsxs("div",{className:"tw-relative",children:[a.jsx(St,{...o,type:"text",className:"tw-box-border tw-gap-2.5 tw-rounded-lg tw-border tw-border-solid tw-bg-background tw-py-2 tw-pl-4 tw-pr-3 tw-font-medium tw-shadow-none tw-outline-none",onChange:i=>e(i.target.value),onKeyDown:i=>{i.key==="Enter"&&r(),t(i)},onClick:n,ref:s}),a.jsx(Q.History,{className:"tw-absolute tw-right-3 tw-top-1/2 tw-h-4 tw-w-4 tw--translate-y-1/2 tw-transform tw-cursor-pointer tw-text-muted-foreground",onClick:()=>{console.log("back in history")}})]}));var Il=Object.defineProperty,Ml=(e,t,n)=>t in e?Il(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,ne=(e,t,n)=>Ml(e,typeof t!="symbol"?t+"":t,n);const gt=["GEN","EXO","LEV","NUM","DEU","JOS","JDG","RUT","1SA","2SA","1KI","2KI","1CH","2CH","EZR","NEH","EST","JOB","PSA","PRO","ECC","SNG","ISA","JER","LAM","EZK","DAN","HOS","JOL","AMO","OBA","JON","MIC","NAM","HAB","ZEP","HAG","ZEC","MAL","MAT","MRK","LUK","JHN","ACT","ROM","1CO","2CO","GAL","EPH","PHP","COL","1TH","2TH","1TI","2TI","TIT","PHM","HEB","JAS","1PE","2PE","1JN","2JN","3JN","JUD","REV","TOB","JDT","ESG","WIS","SIR","BAR","LJE","S3Y","SUS","BEL","1MA","2MA","3MA","4MA","1ES","2ES","MAN","PS2","ODA","PSS","JSA","JDB","TBS","SST","DNT","BLT","XXA","XXB","XXC","XXD","XXE","XXF","XXG","FRT","BAK","OTH","3ES","EZA","5EZ","6EZ","INT","CNC","GLO","TDX","NDX","DAG","PS3","2BA","LBA","JUB","ENO","1MQ","2MQ","3MQ","REP","4BA","LAO"],no=["XXA","XXB","XXC","XXD","XXE","XXF","XXG","FRT","BAK","OTH","INT","CNC","GLO","TDX","NDX"],rs=["Genesis","Exodus","Leviticus","Numbers","Deuteronomy","Joshua","Judges","Ruth","1 Samuel","2 Samuel","1 Kings","2 Kings","1 Chronicles","2 Chronicles","Ezra","Nehemiah","Esther (Hebrew)","Job","Psalms","Proverbs","Ecclesiastes","Song of Songs","Isaiah","Jeremiah","Lamentations","Ezekiel","Daniel (Hebrew)","Hosea","Joel","Amos","Obadiah","Jonah","Micah","Nahum","Habakkuk","Zephaniah","Haggai","Zechariah","Malachi","Matthew","Mark","Luke","John","Acts","Romans","1 Corinthians","2 Corinthians","Galatians","Ephesians","Philippians","Colossians","1 Thessalonians","2 Thessalonians","1 Timothy","2 Timothy","Titus","Philemon","Hebrews","James","1 Peter","2 Peter","1 John","2 John","3 John","Jude","Revelation","Tobit","Judith","Esther Greek","Wisdom of Solomon","Sirach (Ecclesiasticus)","Baruch","Letter of Jeremiah","Song of 3 Young Men","Susanna","Bel and the Dragon","1 Maccabees","2 Maccabees","3 Maccabees","4 Maccabees","1 Esdras (Greek)","2 Esdras (Latin)","Prayer of Manasseh","Psalm 151","Odes","Psalms of Solomon","Joshua A. *obsolete*","Judges B. *obsolete*","Tobit S. *obsolete*","Susanna Th. *obsolete*","Daniel Th. *obsolete*","Bel Th. *obsolete*","Extra A","Extra B","Extra C","Extra D","Extra E","Extra F","Extra G","Front Matter","Back Matter","Other Matter","3 Ezra *obsolete*","Apocalypse of Ezra","5 Ezra (Latin Prologue)","6 Ezra (Latin Epilogue)","Introduction","Concordance ","Glossary ","Topical Index","Names Index","Daniel Greek","Psalms 152-155","2 Baruch (Apocalypse)","Letter of Baruch","Jubilees","Enoch","1 Meqabyan","2 Meqabyan","3 Meqabyan","Reproof (Proverbs 25-31)","4 Baruch (Rest of Baruch)","Laodiceans"],ra=Ul();function Yt(e,t=!0){return t&&(e=e.toUpperCase()),e in ra?ra[e]:0}function ro(e){return Yt(e)>0}function $l(e){const t=typeof e=="string"?Yt(e):e;return t>=40&&t<=66}function Dl(e){return(typeof e=="string"?Yt(e):e)<=39}function os(e){return e<=66}function Al(e){const t=typeof e=="string"?Yt(e):e;return is(t)&&!os(t)}function*Bl(){for(let e=1;e<=gt.length;e++)yield e}const Vl=1,as=gt.length;function zl(){return["XXA","XXB","XXC","XXD","XXE","XXF","XXG"]}function oo(e,t="***"){const n=e-1;return n<0||n>=gt.length?t:gt[n]}function ss(e){return e<=0||e>as?"******":rs[e-1]}function Ll(e){return ss(Yt(e))}function is(e){const t=typeof e=="number"?oo(e):e;return ro(t)&&!no.includes(t)}function Fl(e){const t=typeof e=="number"?oo(e):e;return ro(t)&&no.includes(t)}function Gl(e){return rs[e-1].includes("*obsolete*")}function Ul(){const e={};for(let t=0;t(e[e.Unknown=0]="Unknown",e[e.Original=1]="Original",e[e.Septuagint=2]="Septuagint",e[e.Vulgate=3]="Vulgate",e[e.English=4]="English",e[e.RussianProtestant=5]="RussianProtestant",e[e.RussianOrthodox=6]="RussianOrthodox",e))(He||{});const Ie=class{constructor(t){if(ne(this,"name"),ne(this,"fullPath"),ne(this,"isPresent"),ne(this,"hasVerseSegments"),ne(this,"isCustomized"),ne(this,"baseVersification"),ne(this,"scriptureBooks"),ne(this,"_type"),t==null)throw new Error("Argument undefined");typeof t=="string"?(this.name=t,this._type=He[t]):(this._type=t,this.name=He[t])}get type(){return this._type}equals(t){return!t.type||!this.type?!1:t.type===this.type}};ne(Ie,"Original",new Ie(He.Original)),ne(Ie,"Septuagint",new Ie(He.Septuagint)),ne(Ie,"Vulgate",new Ie(He.Vulgate)),ne(Ie,"English",new Ie(He.English)),ne(Ie,"RussianProtestant",new Ie(He.RussianProtestant)),ne(Ie,"RussianOrthodox",new Ie(He.RussianOrthodox));let ut=Ie;function oa(e,t){const n=t[0];for(let r=1;r(e[e.Valid=0]="Valid",e[e.UnknownVersification=1]="UnknownVersification",e[e.OutOfRange=2]="OutOfRange",e[e.VerseOutOfOrder=3]="VerseOutOfOrder",e[e.VerseRepeated=4]="VerseRepeated",e))(ls||{});const je=class re{constructor(t,n,r,o){if(ne(this,"firstChapter"),ne(this,"lastChapter"),ne(this,"lastVerse"),ne(this,"hasSegmentsDefined"),ne(this,"text"),ne(this,"BBBCCCVVVS"),ne(this,"longHashCode"),ne(this,"versification"),ne(this,"rtlMark","‏"),ne(this,"_bookNum",0),ne(this,"_chapterNum",0),ne(this,"_verseNum",0),ne(this,"_verse"),r==null&&o==null)if(t!=null&&typeof t=="string"){const s=t,i=n!=null&&n instanceof ut?n:void 0;this.setEmpty(i),this.parse(s)}else if(t!=null&&typeof t=="number"){const s=n!=null&&n instanceof ut?n:void 0;this.setEmpty(s),this._verseNum=t%re.chapterDigitShifter,this._chapterNum=Math.floor(t%re.bookDigitShifter/re.chapterDigitShifter),this._bookNum=Math.floor(t/re.bookDigitShifter)}else if(n==null)if(t!=null&&t instanceof re){const s=t;this._bookNum=s.bookNum,this._chapterNum=s.chapterNum,this._verseNum=s.verseNum,this._verse=s.verse,this.versification=s.versification}else{if(t==null)return;const s=t instanceof ut?t:re.defaultVersification;this.setEmpty(s)}else throw new Error("VerseRef constructor not supported.");else if(t!=null&&n!=null&&r!=null)if(typeof t=="string"&&typeof n=="string"&&typeof r=="string")this.setEmpty(o),this.updateInternal(t,n,r);else if(typeof t=="number"&&typeof n=="number"&&typeof r=="number")this._bookNum=t,this._chapterNum=n,this._verseNum=r,this.versification=o??re.defaultVersification;else throw new Error("VerseRef constructor not supported.");else throw new Error("VerseRef constructor not supported.")}static isVerseParseable(t){return t.length>0&&"0123456789".includes(t[0])&&!t.endsWith(this.verseRangeSeparator)&&!t.endsWith(this.verseSequenceIndicator)}static tryParse(t){let n;try{return n=new re(t),{success:!0,verseRef:n}}catch(r){if(r instanceof nn)return n=new re,{success:!1,verseRef:n};throw r}}static getBBBCCCVVV(t,n,r){return t%re.bcvMaxValue*re.bookDigitShifter+(n>=0?n%re.bcvMaxValue*re.chapterDigitShifter:0)+(r>=0?r%re.bcvMaxValue:0)}static fromJSON(t){const{book:n,chapterNum:r,verseNum:o,verse:s,versificationStr:i}=t,l=s||o.toString();let c;return i&&(c=new ut(i)),n?new re(n,r.toString(),l,c):new re}static tryGetVerseNum(t){let n;if(!t)return n=-1,{success:!0,vNum:n};n=0;let r;for(let o=0;o"9")return o===0&&(n=-1),{success:!1,vNum:n};if(n=n*10+ +r-0,n>re.bcvMaxValue)return n=-1,{success:!1,vNum:n}}return{success:!0,vNum:n}}get isDefault(){return this.bookNum===0&&this.chapterNum===0&&this.verseNum===0&&this.versification==null}get hasMultiple(){return this._verse!=null&&(this._verse.includes(re.verseRangeSeparator)||this._verse.includes(re.verseSequenceIndicator))}get book(){return ae.bookNumberToId(this.bookNum,"")}set book(t){this.bookNum=ae.bookIdToNumber(t)}get chapter(){return this.isDefault||this._chapterNum<0?"":this._chapterNum.toString()}set chapter(t){const n=+t;this._chapterNum=Number.isInteger(n)?n:-1}get verse(){return this._verse!=null?this._verse:this.isDefault||this._verseNum<0?"":this._verseNum.toString()}set verse(t){const{success:n,vNum:r}=re.tryGetVerseNum(t);this._verse=n?void 0:t.replace(this.rtlMark,""),this._verseNum=r,!(this._verseNum>=0)&&({vNum:this._verseNum}=re.tryGetVerseNum(this._verse))}get bookNum(){return this._bookNum}set bookNum(t){if(t<=0||t>ae.lastBook)throw new nn("BookNum must be greater than zero and less than or equal to last book");this._bookNum=t}get chapterNum(){return this._chapterNum}set chapterNum(t){this.chapterNum=t}get verseNum(){return this._verseNum}set verseNum(t){this._verseNum=t}get versificationStr(){var t;return(t=this.versification)==null?void 0:t.name}set versificationStr(t){this.versification=this.versification!=null?new ut(t):void 0}get valid(){return this.validStatus===0}get validStatus(){return this.validateVerse(re.verseRangeSeparators,re.verseSequenceIndicators)}get BBBCCC(){return re.getBBBCCCVVV(this._bookNum,this._chapterNum,0)}get BBBCCCVVV(){return re.getBBBCCCVVV(this._bookNum,this._chapterNum,this._verseNum)}get isExcluded(){return!1}parse(t){if(t=t.replace(this.rtlMark,""),t.includes("/")){const s=t.split("/");if(t=s[0],s.length>1)try{const i=+s[1].trim();this.versification=new ut(He[i])}catch{throw new nn("Invalid reference : "+t)}}const n=t.trim().split(" ");if(n.length!==2)throw new nn("Invalid reference : "+t);const r=n[1].split(":"),o=+r[0];if(r.length!==2||ae.bookIdToNumber(n[0])===0||!Number.isInteger(o)||o<0||!re.isVerseParseable(r[1]))throw new nn("Invalid reference : "+t);this.updateInternal(n[0],r[0],r[1])}simplify(){this._verse=void 0}clone(){return new re(this)}toString(){const t=this.book;return t===""?"":`${t} ${this.chapter}:${this.verse}`}toJSON(){let t=this.verse;(t===""||t===this.verseNum.toString())&&(t=void 0);const n={book:this.book,chapterNum:this.chapterNum,verseNum:this.verseNum,verse:t,versificationStr:this.versificationStr};return t||delete n.verse,n}equals(t){return t instanceof re?t._bookNum===this._bookNum&&t._chapterNum===this._chapterNum&&t._verseNum===this._verseNum&&t.verse===this.verse&&(t.versification==null&&this.versification==null||t.versification!=null&&this.versification!=null&&t.versification.equals(this.versification)):!1}allVerses(t=!1,n=re.verseRangeSeparators,r=re.verseSequenceIndicators){if(this._verse==null||this.chapterNum<=0)return[this.clone()];const o=[],s=oa(this._verse,r);for(const i of s.map(l=>oa(l,n))){const l=this.clone();l.verse=i[0];const c=l.verseNum;if(o.push(l),i.length>1){const d=this.clone();if(d.verse=i[1],!t)for(let u=c+1;ui)return 3;if(r===i)return 4;r=i}return 0}get internalValid(){return this.versification==null?1:this._bookNum<=0||this._bookNum>ae.lastBook?2:(ae.isCanonical(this._bookNum),0)}setEmpty(t=re.defaultVersification){this._bookNum=0,this._chapterNum=-1,this._verse=void 0,this.versification=t}updateInternal(t,n,r){this.bookNum=ae.bookIdToNumber(t),this.chapter=n,this.verse=r}};ne(je,"defaultVersification",ut.English),ne(je,"verseRangeSeparator","-"),ne(je,"verseSequenceIndicator",","),ne(je,"verseRangeSeparators",[je.verseRangeSeparator]),ne(je,"verseSequenceIndicators",[je.verseSequenceIndicator]),ne(je,"chapterDigitShifter",1e3),ne(je,"bookDigitShifter",je.chapterDigitShifter*je.chapterDigitShifter),ne(je,"bcvMaxValue",je.chapterDigitShifter-1),ne(je,"ValidStatusType",ls);class nn extends Error{}const rr=pe.Root,ao=pe.Trigger,cs=pe.Group,ql=pe.Portal,Hl=pe.Sub,Xl=pe.RadioGroup,ds=g.forwardRef(({className:e,inset:t,children:n,...r},o)=>a.jsxs(pe.SubTrigger,{ref:o,className:N("tw-flex tw-cursor-default tw-select-none tw-items-center tw-rounded-sm tw-px-2 tw-py-1.5 tw-text-sm tw-outline-none focus:tw-bg-accent data-[state=open]:tw-bg-accent",t&&"tw-pl-8",e),...r,children:[n,a.jsx(Q.ChevronRight,{className:"tw-ml-auto tw-h-4 tw-w-4"})]}));ds.displayName=pe.SubTrigger.displayName;const us=g.forwardRef(({className:e,...t},n)=>a.jsx(pe.SubContent,{ref:n,className:N("tw-z-50 tw-min-w-[8rem] tw-overflow-hidden tw-rounded-md tw-border tw-bg-popover tw-p-1 tw-text-popover-foreground tw-shadow-lg data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0 data-[state=closed]:tw-zoom-out-95 data-[state=open]:tw-zoom-in-95 data-[side=bottom]:tw-slide-in-from-top-2 data-[side=left]:tw-slide-in-from-right-2 data-[side=right]:tw-slide-in-from-left-2 data-[side=top]:tw-slide-in-from-bottom-2",e),...t}));us.displayName=pe.SubContent.displayName;const En=g.forwardRef(({className:e,sideOffset:t=4,...n},r)=>a.jsx(pe.Portal,{children:a.jsx(pe.Content,{ref:r,sideOffset:t,className:N("pr-twp tw-z-50 tw-min-w-[8rem] tw-overflow-hidden tw-rounded-md tw-border tw-bg-popover tw-p-1 tw-text-popover-foreground tw-shadow-md data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0 data-[state=closed]:tw-zoom-out-95 data-[state=open]:tw-zoom-in-95 data-[side=bottom]:tw-slide-in-from-top-2 data-[side=left]:tw-slide-in-from-right-2 data-[side=right]:tw-slide-in-from-left-2 data-[side=top]:tw-slide-in-from-bottom-2",e),...n})}));En.displayName=pe.Content.displayName;const so=g.forwardRef(({className:e,inset:t,...n},r)=>a.jsx(pe.Item,{ref:r,className:N("tw-cursor-default tw-select-none tw-items-center tw-rounded-sm tw-px-2 tw-py-1.5 tw-text-sm tw-outline-none tw-transition-colors focus:tw-bg-accent data-[disabled]:tw-pointer-events-none data-[disabled]:tw-opacity-50",t&&"tw-pl-8",e),...n}));so.displayName=pe.Item.displayName;const or=g.forwardRef(({className:e,children:t,checked:n,...r},o)=>a.jsxs(pe.CheckboxItem,{ref:o,className:N("tw-relative tw-flex tw-cursor-default tw-select-none tw-items-center tw-rounded-sm tw-py-1.5 tw-pl-8 tw-pr-2 tw-text-sm tw-outline-none tw-transition-colors focus:tw-bg-accent focus:tw-text-accent-foreground data-[disabled]:tw-pointer-events-none data-[disabled]:tw-opacity-50",e),checked:n,...r,children:[a.jsx("span",{className:"tw-absolute tw-left-2 tw-flex tw-h-3.5 tw-w-3.5 tw-items-center tw-justify-center",children:a.jsx(pe.ItemIndicator,{children:a.jsx(Q.Check,{className:"tw-h-4 tw-w-4"})})}),t]}));or.displayName=pe.CheckboxItem.displayName;const io=g.forwardRef(({className:e,children:t,...n},r)=>a.jsxs(pe.RadioItem,{ref:r,className:N("tw-relative tw-flex tw-cursor-default tw-select-none tw-items-center tw-rounded-sm tw-py-1.5 tw-pl-8 tw-pr-2 tw-text-sm tw-outline-none tw-transition-colors focus:tw-bg-accent focus:tw-text-accent-foreground data-[disabled]:tw-pointer-events-none data-[disabled]:tw-opacity-50",e),...n,children:[a.jsx("span",{className:"tw-absolute tw-left-2 tw-flex tw-h-3.5 tw-w-3.5 tw-items-center tw-justify-center",children:a.jsx(pe.ItemIndicator,{children:a.jsx(Q.Circle,{className:"tw-h-2 tw-w-2 tw-fill-current"})})}),t]}));io.displayName=pe.RadioItem.displayName;const Wt=g.forwardRef(({className:e,inset:t,...n},r)=>a.jsx(pe.Label,{ref:r,className:N("tw-px-2 tw-py-1.5 tw-text-sm tw-font-semibold",t&&"tw-pl-8",e),...n}));Wt.displayName=pe.Label.displayName;const jn=g.forwardRef(({className:e,...t},n)=>a.jsx(pe.Separator,{ref:n,className:N("tw--mx-1 tw-my-1 tw-h-px tw-bg-muted",e),...t}));jn.displayName=pe.Separator.displayName;function ps({className:e,...t}){return a.jsx("span",{className:N("tw-ml-auto tw-text-xs tw-tracking-widest tw-opacity-60",e),...t})}ps.displayName="DropdownMenuShortcut";const Yl=g.forwardRef(({bookId:e,handleSelectBook:t,isSelected:n,handleHighlightBook:r,handleKeyDown:o,bookType:s,children:i},l)=>a.jsxs(so,{ref:l,textValue:e,className:N("tw-mx-1 tw-px-1 tw-font-normal tw-text-foreground/80",{"tw-bg-amber-50 tw-text-yellow-900 data-[highlighted]:tw-bg-amber-100":n}),onSelect:c=>{c.preventDefault(),t()},onKeyDown:c=>{o(c)},onFocus:r,onMouseMove:r,children:[a.jsx("span",{className:N("tw-border-b-0 tw-border-l-2 tw-border-r-0 tw-border-t-0 tw-border-solid tw-px-2",{"tw-font-bold":n,"tw-border-l-red-200":s.toLowerCase()==="ot","tw-border-l-purple-200":s.toLowerCase()==="nt","tw-border-l-indigo-200":s.toLowerCase()==="dc"}),children:ae.bookIdToEnglishName(e)}),n&&a.jsx("div",{children:i})]},e));function Wl({handleSelectChapter:e,endChapter:t,activeChapter:n,highlightedChapter:r,handleHighlightedChapter:o}){const s=Array.from({length:t},(l,c)=>c+1),i=g.useCallback(l=>{o(l)},[o]);return a.jsx("div",{className:N("tw-flex tw-flex-wrap tw-items-start tw-justify-start tw-self-stretch"),children:s.map(l=>a.jsx("div",{className:N("tw-box-content tw-flex tw-h-4 tw-w-4 tw-cursor-pointer tw-items-center tw-justify-end tw-rounded-md tw-p-2 tw-text-amber-800",{"tw-font-semibold tw-text-amber-900":l===n,"tw-bg-amber-200":l===r}),onClick:c=>{c.preventDefault(),c.stopPropagation(),e(l)},role:"button",onKeyDown:c=>{c.key==="Enter"&&e(l)},tabIndex:0,onMouseMove:()=>i(l),children:l},l))})}function Kl({handleSort:e,handleLocationHistory:t,handleBookmarks:n}){return a.jsxs(Wt,{className:"tw-flex tw-justify-between",children:[a.jsx("p",{className:"tw-inline-block tw-align-middle",children:"Go To"}),a.jsxs("div",{className:"tw-flex tw-items-center",children:[a.jsx(Q.ArrowDownWideNarrow,{onClick:e,className:"tw-m-2 tw-h-4 tw-w-4 tw-cursor-pointer tw-gap-2"}),a.jsx(Q.Clock,{onClick:t,className:"tw-m-2 tw-h-4 tw-w-4 tw-cursor-pointer tw-gap-2"}),a.jsx(Q.Bookmark,{onClick:n,className:"tw-m-2 tw-h-4 tw-w-4 tw-cursor-pointer tw-gap-2"})]})]})}const wn=ae.allBookIds,Jl={OT:"Old Testament",NT:"New Testament",DC:"Deuterocanon"},aa=["OT","NT","DC"],Zl=32+32+32,Ql=[/^(\w+)$/i,/^(\w+)(?:\s(\d+))$/i,/^(\w+)(?:\s(\d+):(\d+))$/i],ec=e=>({OT:wn.filter(n=>ae.isBookOT(n)),NT:wn.filter(n=>ae.isBookNT(n)),DC:wn.filter(n=>ae.isBookDC(n))})[e],rn=e=>W.getChaptersForBook(ae.bookIdToNumber(e));function tc(){return wn.map(t=>ae.bookIdToEnglishName(t))}function nc(e){return tc().includes(e)}function rc(e){const t=e.toLowerCase().replace(/^\w/,n=>n.toUpperCase());if(nc(t))return wn.find(r=>ae.bookIdToEnglishName(r)===t)}function oc({scrRef:e,handleSubmit:t}){const[n,r]=g.useState(""),[o,s]=g.useState(ae.bookNumberToId(e.bookNum)),[i,l]=g.useState(e.chapterNum??0),[c,d]=g.useState(ae.bookNumberToId(e.bookNum)),[u,m]=g.useState(!1),[w,b]=g.useState(u),x=g.useRef(void 0),f=g.useRef(void 0),h=g.useRef(void 0),S=g.useCallback(k=>ec(k).filter(D=>{const $=ae.bookIdToEnglishName(D).toLowerCase(),J=n.replace(/[^a-zA-Z]/g,"").toLowerCase();return $.includes(J)||D.toLowerCase().includes(J)}),[n]),R=k=>{r(k)},j=g.useRef(!1),E=g.useCallback(k=>{if(j.current){j.current=!1;return}m(k)},[]),v=g.useCallback((k,D,$,J)=>{if(l(ae.bookNumberToId(e.bookNum)!==k?1:e.chapterNum),D||rn(k)===-1){t({bookNum:ae.bookIdToNumber(k),chapterNum:$||1,verseNum:J||1}),m(!1),r("");return}s(o!==k?k:""),m(!D)},[t,e.bookNum,e.chapterNum,o]),P=k=>{k<=0||k>rn(o)||v(o,!0,k)},V=g.useCallback(()=>{Ql.forEach(k=>{const D=n.match(k);if(D){const[$,J=void 0,Y=void 0]=D.slice(1),F=rc($);(ae.isBookIdValid($)||F)&&v(F??$,!0,J?parseInt(J,10):1,Y?parseInt(Y,10):1)}})},[v,n]),U=g.useCallback(k=>{u?(k.key==="ArrowDown"||k.key==="ArrowUp")&&(typeof h<"u"&&h.current!==null?h.current.focus():typeof f<"u"&&f.current!==null&&f.current.focus(),k.preventDefault()):m(!0)},[u]),T=k=>{const{key:D}=k;D==="ArrowRight"||D==="ArrowLeft"||D==="ArrowDown"||D==="ArrowUp"||D==="Enter"||(x.current.dispatchEvent(new KeyboardEvent("keydown",{key:D})),x.current.focus())},_=k=>{const{key:D}=k;if(c===o){if(D==="Enter"){k.preventDefault(),v(o,!0,i);return}let $=0;if(D==="ArrowRight")if(i1)$=-1;else{k.preventDefault();return}else D==="ArrowDown"?$=6:D==="ArrowUp"&&($=-6);i+$<=0||i+$>rn(c)?l(0):$!==0&&(l(i+$),k.preventDefault())}};return g.useEffect(()=>{o===c?o===ae.bookNumberToId(e.bookNum)?l(e.chapterNum):l(1):l(0)},[c,e.bookNum,e.chapterNum,o]),g.useLayoutEffect(()=>{b(u)},[u]),g.useLayoutEffect(()=>{const k=setTimeout(()=>{if(w&&f.current&&h.current){const $=h.current.offsetTop-Zl;f.current.scrollTo({top:$,behavior:"instant"})}},10);return()=>{clearTimeout(k)}},[w]),a.jsx("div",{className:"pr-twp tw-flex",children:a.jsxs(rr,{modal:!1,open:u,onOpenChange:E,children:[a.jsx(ao,{asChild:!0,children:a.jsx(Pl,{ref:x,value:n,handleSearch:R,handleKeyDown:U,handleOnClick:()=>{s(ae.bookNumberToId(e.bookNum)),d(ae.bookNumberToId(e.bookNum)),l(e.chapterNum>0?e.chapterNum:0),m(!0),x.current.focus()},onFocus:()=>{j.current=!0},handleSubmit:V,placeholder:`${ae.bookNumberToEnglishName(e.bookNum)} ${e.chapterNum}:${e.verseNum}`})}),a.jsxs(En,{className:"tw-m-1 tw-overflow-y-auto tw-p-0 tw-font-normal tw-text-foreground/80",style:{width:"233px",maxHeight:"500px",zIndex:"250"},onKeyDown:T,align:"start",ref:f,children:[a.jsx(Kl,{handleSort:()=>console.log("sorting"),handleLocationHistory:()=>console.log("location history"),handleBookmarks:()=>console.log("bookmarks")}),aa.map((k,D)=>S(k).length>0&&a.jsxs("div",{children:[a.jsx(Wt,{className:"tw-font-semibold tw-text-foreground/80",children:Jl[k]}),S(k).map($=>a.jsx("div",{children:a.jsx(Yl,{bookId:$,handleSelectBook:()=>v($,!1),isSelected:o===$,handleHighlightBook:()=>d($),handleKeyDown:_,bookType:k,ref:J=>{o===$&&(h.current=J)},children:a.jsx(Wl,{handleSelectChapter:P,endChapter:rn($),activeChapter:e.bookNum===ae.bookIdToNumber($)?e.chapterNum:0,highlightedChapter:i,handleHighlightedChapter:J=>{l(J)}})})},$)),aa.length-1!==D?a.jsx(jn,{}):void 0]},k))]})]})})}const ws=Xt.cva("pr-twp tw-inline-flex tw-items-center tw-justify-center tw-whitespace-nowrap tw-rounded-md tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-colors focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50",{variants:{variant:{default:"tw-bg-primary tw-text-primary-foreground hover:tw-bg-primary/90",destructive:"tw-bg-destructive tw-text-destructive-foreground hover:tw-bg-destructive/90",outline:"tw-border tw-border-input tw-bg-background hover:tw-bg-accent hover:tw-text-accent-foreground",secondary:"tw-bg-secondary tw-text-secondary-foreground hover:tw-bg-secondary/80",ghost:"hover:tw-bg-accent hover:tw-text-accent-foreground",link:"tw-text-primary tw-underline-offset-4 hover:tw-underline"},size:{default:"tw-h-10 tw-px-4 tw-py-2",sm:"tw-h-9 tw-rounded-md tw-px-3",lg:"tw-h-11 tw-rounded-md tw-px-8",icon:"tw-h-10 tw-w-10"}},defaultVariants:{variant:"default",size:"default"}}),fe=g.forwardRef(({className:e,variant:t,size:n,asChild:r=!1,...o},s)=>{const i=r?Ht.Slot:"button";return a.jsx(i,{className:N(ws({variant:t,size:n,className:e})),ref:s,...o})});fe.displayName="Button";const ac=Xt.cva("tw-text-sm tw-font-medium tw-leading-none peer-disabled:tw-cursor-not-allowed peer-disabled:tw-opacity-70"),qe=g.forwardRef(({className:e,...t},n)=>a.jsx(es.Root,{ref:n,className:N("pr-twp",ac(),e),...t}));qe.displayName=es.Root.displayName;const lo=g.forwardRef(({className:e,...t},n)=>a.jsx(bn.Root,{className:N("pr-twp tw-grid tw-gap-2",e),...t,ref:n}));lo.displayName=bn.Root.displayName;const Yn=g.forwardRef(({className:e,...t},n)=>a.jsx(bn.Item,{ref:n,className:N("pr-twp tw-aspect-square tw-h-4 tw-w-4 tw-rounded-full tw-border tw-border-primary tw-text-primary tw-ring-offset-background focus:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-cursor-not-allowed disabled:tw-opacity-50",e),...t,children:a.jsx(bn.Indicator,{className:"tw-flex tw-items-center tw-justify-center",children:a.jsx(Q.Circle,{className:"tw-h-2.5 tw-w-2.5 tw-fill-current tw-text-current"})})}));Yn.displayName=bn.Item.displayName;const sc=vn.Root,ic=vn.Trigger,fs=g.forwardRef(({className:e,align:t="center",sideOffset:n=4,...r},o)=>a.jsx(vn.Portal,{children:a.jsx(vn.Content,{ref:o,align:t,sideOffset:n,className:N("pr-twp tw-z-50 tw-w-72 tw-rounded-md tw-border tw-bg-popover tw-p-4 tw-text-popover-foreground tw-shadow-md tw-outline-none data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0 data-[state=closed]:tw-zoom-out-95 data-[state=open]:tw-zoom-in-95 data-[side=bottom]:tw-slide-in-from-top-2 data-[side=left]:tw-slide-in-from-right-2 data-[side=right]:tw-slide-in-from-left-2 data-[side=top]:tw-slide-in-from-bottom-2",e),...r})}));fs.displayName=vn.Content.displayName;const lc=be.Portal,ms=g.forwardRef(({className:e,...t},n)=>a.jsx(be.Overlay,{ref:n,className:N("tw-fixed tw-inset-0 tw-z-50 tw-bg-black/80 data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0",e),...t}));ms.displayName=be.Overlay.displayName;const cc=g.forwardRef(({className:e,children:t,...n},r)=>a.jsxs(lc,{children:[a.jsx(ms,{}),a.jsxs(be.Content,{ref:r,className:N("tw-fixed tw-left-[50%] tw-top-[50%] tw-z-50 tw-grid tw-w-full tw-max-w-lg tw-translate-x-[-50%] tw-translate-y-[-50%] tw-gap-4 tw-border tw-bg-background tw-p-6 tw-shadow-lg tw-duration-200 data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0 data-[state=closed]:tw-zoom-out-95 data-[state=open]:tw-zoom-in-95 data-[state=closed]:tw-slide-out-to-left-1/2 data-[state=closed]:tw-slide-out-to-top-[48%] data-[state=open]:tw-slide-in-from-left-1/2 data-[state=open]:tw-slide-in-from-top-[48%] sm:tw-rounded-lg",e),...n,children:[t,a.jsxs(be.Close,{className:"tw-absolute tw-right-4 tw-top-4 tw-rounded-sm tw-opacity-70 tw-ring-offset-background tw-transition-opacity hover:tw-opacity-100 focus:tw-outline-none focus:tw-ring-2 focus:tw-ring-ring focus:tw-ring-offset-2 disabled:tw-pointer-events-none data-[state=open]:tw-bg-accent data-[state=open]:tw-text-muted-foreground",children:[a.jsx(Q.X,{className:"tw-h-4 tw-w-4"}),a.jsx("span",{className:"tw-sr-only",children:"Close"})]})]})]}));cc.displayName=be.Content.displayName;const dc=g.forwardRef(({className:e,...t},n)=>a.jsx(be.Title,{ref:n,className:N("tw-text-lg tw-font-semibold tw-leading-none tw-tracking-tight",e),...t}));dc.displayName=be.Title.displayName;const uc=g.forwardRef(({className:e,...t},n)=>a.jsx(be.Description,{ref:n,className:N("tw-text-sm tw-text-muted-foreground",e),...t}));uc.displayName=be.Description.displayName;const hs=g.forwardRef(({className:e,...t},n)=>a.jsx(Oe.Command,{ref:n,className:N("tw-flex tw-h-full tw-w-full tw-flex-col tw-overflow-hidden tw-rounded-md tw-bg-popover tw-text-popover-foreground",e),...t}));hs.displayName=Oe.Command.displayName;const gs=g.forwardRef(({className:e,...t},n)=>a.jsxs("div",{className:"tw-flex tw-items-center tw-border-b tw-px-3",children:[a.jsx(Q.Search,{className:"tw-me-2 tw-h-4 tw-w-4 tw-shrink-0 tw-opacity-50"}),a.jsx(Oe.Command.Input,{ref:n,className:N("tw-flex tw-h-11 tw-w-full tw-rounded-md tw-bg-transparent tw-py-3 tw-text-sm tw-outline-none placeholder:tw-text-muted-foreground disabled:tw-cursor-not-allowed disabled:tw-opacity-50",e),...t})]}));gs.displayName=Oe.Command.Input.displayName;const bs=g.forwardRef(({className:e,...t},n)=>a.jsx(Oe.Command.List,{ref:n,className:N("tw-max-h-[300px] tw-overflow-y-auto tw-overflow-x-hidden",e),...t}));bs.displayName=Oe.Command.List.displayName;const vs=g.forwardRef((e,t)=>a.jsx(Oe.Command.Empty,{ref:t,className:"tw-py-6 tw-text-center tw-text-sm",...e}));vs.displayName=Oe.Command.Empty.displayName;const pc=g.forwardRef(({className:e,...t},n)=>a.jsx(Oe.Command.Group,{ref:n,className:N("tw-overflow-hidden tw-p-1 tw-text-foreground [&_[cmdk-group-heading]]:tw-px-2 [&_[cmdk-group-heading]]:tw-py-1.5 [&_[cmdk-group-heading]]:tw-text-xs [&_[cmdk-group-heading]]:tw-font-medium [&_[cmdk-group-heading]]:tw-text-muted-foreground",e),...t}));pc.displayName=Oe.Command.Group.displayName;const wc=g.forwardRef(({className:e,...t},n)=>a.jsx(Oe.Command.Separator,{ref:n,className:N("tw--mx-1 tw-h-px tw-bg-border",e),...t}));wc.displayName=Oe.Command.Separator.displayName;const xs=g.forwardRef(({className:e,...t},n)=>a.jsx(Oe.Command.Item,{ref:n,className:N("tw-relative tw-flex tw-cursor-default tw-select-none tw-items-center tw-rounded-sm tw-px-2 tw-py-1.5 tw-text-sm tw-outline-none data-[disabled=true]:tw-pointer-events-none data-[selected=true]:tw-bg-accent data-[selected=true]:tw-text-accent-foreground data-[disabled=true]:tw-opacity-50",e),...t}));xs.displayName=Oe.Command.Item.displayName;function fc(e){return typeof e=="string"?e:typeof e=="number"?e.toString():e.label}function qr({id:e,options:t=[],className:n,value:r,onChange:o=()=>{},getOptionLabel:s=fc,buttonPlaceholder:i="",textPlaceholder:l="",commandEmptyMessage:c="No option found",buttonVariant:d="outline",dir:u="ltr",isDisabled:m=!1,...w}){const[b,x]=g.useState(!1);return a.jsxs(sc,{open:b,onOpenChange:x,...w,children:[a.jsx(ic,{asChild:!0,children:a.jsxs(fe,{variant:d,role:"combobox","aria-expanded":b,id:e,className:N("tw-w-[200px] tw-justify-between",n),disabled:m,children:[a.jsx("span",{className:"tw-overflow-hidden tw-text-ellipsis tw-whitespace-nowrap",children:r?s(r):i}),a.jsx(Q.ChevronsUpDown,{className:"tw-ms-2 tw-h-4 tw-w-4 tw-shrink-0 tw-opacity-50"})]})}),a.jsx(fs,{className:"tw-w-[200px] tw-p-0",dir:u,children:a.jsxs(hs,{children:[a.jsx(gs,{dir:u,placeholder:l,className:"tw-text-inherit"}),a.jsx(vs,{children:c}),a.jsx(bs,{children:t.map(f=>a.jsxs(xs,{value:s(f),onSelect:()=>{o(f),x(!1)},children:[a.jsx(Q.Check,{className:N("tw-me-2 tw-h-4 tw-w-4",{"tw-opacity-0":!r||s(r)!==s(f)})}),s(f)]},s(f)))})]})})]})}function ys({startChapter:e,endChapter:t,handleSelectStartChapter:n,handleSelectEndChapter:r,isDisabled:o=!1,chapterCount:s}){const i=g.useMemo(()=>Array.from({length:s},(d,u)=>u+1),[s]),l=d=>{n(d),d>t&&r(d)},c=d=>{r(d),dd.toString(),value:e},"start chapter"),a.jsx(qe,{htmlFor:"end-chapters-combobox",children:"to"}),a.jsx(qr,{isDisabled:o,onChange:c,className:"tw-ml-2 tw-w-20",options:i,getOptionLabel:d=>d.toString(),value:t},"end chapter")]})}var Ns=(e=>(e.CURRENT_BOOK="current book",e.CHOOSE_BOOKS="choose books",e))(Ns||{});const mc=Object.freeze(["%webView_bookSelector_currentBook%","%webView_bookSelector_choose%","%webView_bookSelector_chooseBooks%"]),Tr=(e,t)=>e[t]??t;function hc({handleBookSelectionModeChange:e,currentBookName:t,onSelectBooks:n,selectedBookIds:r,chapterCount:o,endChapter:s,handleSelectEndChapter:i,startChapter:l,handleSelectStartChapter:c,localizedStrings:d}){const u=Tr(d,"%webView_bookSelector_currentBook%"),m=Tr(d,"%webView_bookSelector_choose%"),w=Tr(d,"%webView_bookSelector_chooseBooks%"),[b,x]=g.useState("current book"),f=h=>{x(h),e(h)};return a.jsx(lo,{className:"pr-twp tw-flex",value:b,onValueChange:h=>f(h),children:a.jsxs("div",{className:"tw-flex tw-w-full tw-flex-col tw-gap-4",children:[a.jsxs("div",{className:"tw-grid tw-grid-cols-[25%,25%,50%]",children:[a.jsxs("div",{className:"tw-flex tw-items-center",children:[a.jsx(Yn,{value:"current book"}),a.jsx(qe,{className:"tw-ml-1",children:u})]}),a.jsx(qe,{className:"tw-flex tw-items-center",children:t}),a.jsx("div",{className:"tw-flex tw-items-center tw-justify-end",children:a.jsx(ys,{isDisabled:b==="choose books",handleSelectStartChapter:c,handleSelectEndChapter:i,chapterCount:o,startChapter:l,endChapter:s})})]}),a.jsxs("div",{className:"tw-grid tw-grid-cols-[25%,50%,25%]",children:[a.jsxs("div",{className:"tw-flex tw-items-center",children:[a.jsx(Yn,{value:"choose books"}),a.jsx(qe,{className:"tw-ml-1",children:w})]}),a.jsx(qe,{className:"tw-flex tw-items-center",children:r.map(h=>ae.bookIdToEnglishName(h)).join(", ")}),a.jsx(fe,{disabled:b==="current book",onClick:()=>n(),children:m})]})]})})}function gc({table:e}){return a.jsxs(rr,{children:[a.jsx(Za.DropdownMenuTrigger,{asChild:!0,children:a.jsxs(fe,{variant:"outline",size:"sm",className:"tw-ml-auto tw-hidden tw-h-8 lg:tw-flex",children:[a.jsx(Q.FilterIcon,{className:"tw-mr-2 tw-h-4 tw-w-4"}),"View"]})}),a.jsxs(En,{align:"end",className:"tw-w-[150px]",children:[a.jsx(Wt,{children:"Toggle columns"}),a.jsx(jn,{}),e.getAllColumns().filter(t=>t.getCanHide()).map(t=>a.jsx(or,{className:"tw-capitalize",checked:t.getIsVisible(),onCheckedChange:n=>t.toggleVisibility(!!n),children:t.id},t.id))]})]})}const At=ge.Root,ks=ge.Group,Bt=ge.Value,bt=g.forwardRef(({className:e,children:t,...n},r)=>a.jsxs(ge.Trigger,{ref:r,className:N("tw-flex tw-h-10 tw-w-full tw-items-center tw-justify-between tw-rounded-md tw-border tw-border-input tw-bg-background tw-px-3 tw-py-2 tw-text-sm tw-ring-offset-background placeholder:tw-text-muted-foreground focus:tw-outline-none focus:tw-ring-2 focus:tw-ring-ring focus:tw-ring-offset-2 disabled:tw-cursor-not-allowed disabled:tw-opacity-50 [&>span]:tw-line-clamp-1",e),...n,children:[t,a.jsx(ge.Icon,{asChild:!0,children:a.jsx(Q.ChevronDown,{className:"tw-h-4 tw-w-4 tw-opacity-50"})})]}));bt.displayName=ge.Trigger.displayName;const co=g.forwardRef(({className:e,...t},n)=>a.jsx(ge.ScrollUpButton,{ref:n,className:N("tw-flex tw-cursor-default tw-items-center tw-justify-center tw-py-1",e),...t,children:a.jsx(Q.ChevronUp,{className:"tw-h-4 tw-w-4"})}));co.displayName=ge.ScrollUpButton.displayName;const uo=g.forwardRef(({className:e,...t},n)=>a.jsx(ge.ScrollDownButton,{ref:n,className:N("tw-flex tw-cursor-default tw-items-center tw-justify-center tw-py-1",e),...t,children:a.jsx(Q.ChevronDown,{className:"tw-h-4 tw-w-4"})}));uo.displayName=ge.ScrollDownButton.displayName;const vt=g.forwardRef(({className:e,children:t,position:n="popper",...r},o)=>a.jsx(ge.Portal,{children:a.jsxs(ge.Content,{ref:o,className:N("pr-twp tw-relative tw-z-50 tw-max-h-96 tw-min-w-[8rem] tw-overflow-hidden tw-rounded-md tw-border tw-bg-popover tw-text-popover-foreground tw-shadow-md data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0 data-[state=closed]:tw-zoom-out-95 data-[state=open]:tw-zoom-in-95 data-[side=bottom]:tw-slide-in-from-top-2 data-[side=left]:tw-slide-in-from-right-2 data-[side=right]:tw-slide-in-from-left-2 data-[side=top]:tw-slide-in-from-bottom-2",n==="popper"&&"data-[side=bottom]:tw-translate-y-1 data-[side=left]:tw--translate-x-1 data-[side=right]:tw-translate-x-1 data-[side=top]:tw--translate-y-1",e),position:n,...r,children:[a.jsx(co,{}),a.jsx(ge.Viewport,{className:N("tw-p-1",n==="popper"&&"tw-h-[var(--radix-select-trigger-height)] tw-w-full tw-min-w-[var(--radix-select-trigger-width)]"),children:t}),a.jsx(uo,{})]})}));vt.displayName=ge.Content.displayName;const Ss=g.forwardRef(({className:e,...t},n)=>a.jsx(ge.Label,{ref:n,className:N("tw-py-1.5 tw-pl-8 tw-pr-2 tw-text-sm tw-font-semibold",e),...t}));Ss.displayName=ge.Label.displayName;const Ae=g.forwardRef(({className:e,children:t,...n},r)=>a.jsxs(ge.Item,{ref:r,className:N("tw-relative tw-flex tw-w-full tw-cursor-default tw-select-none tw-items-center tw-rounded-sm tw-py-1.5 tw-pl-8 tw-pr-2 tw-text-sm tw-outline-none focus:tw-bg-accent focus:tw-text-accent-foreground data-[disabled]:tw-pointer-events-none data-[disabled]:tw-opacity-50",e),...n,children:[a.jsx("span",{className:"tw-absolute tw-left-2 tw-flex tw-h-3.5 tw-w-3.5 tw-items-center tw-justify-center",children:a.jsx(ge.ItemIndicator,{children:a.jsx(Q.Check,{className:"tw-h-4 tw-w-4"})})}),a.jsx(ge.ItemText,{children:t})]}));Ae.displayName=ge.Item.displayName;const Es=g.forwardRef(({className:e,...t},n)=>a.jsx(ge.Separator,{ref:n,className:N("tw--mx-1 tw-my-1 tw-h-px tw-bg-muted",e),...t}));Es.displayName=ge.Separator.displayName;function bc({table:e}){return a.jsx("div",{className:"tw-flex tw-items-center tw-justify-between tw-px-2 tw-pb-3 tw-pt-3",children:a.jsxs("div",{className:"tw-flex tw-items-center tw-space-x-6 lg:tw-space-x-8",children:[a.jsxs("div",{className:"tw-flex-1 tw-text-sm tw-text-muted-foreground",children:[e.getFilteredSelectedRowModel().rows.length," of"," ",e.getFilteredRowModel().rows.length," row(s) selected"]}),a.jsxs("div",{className:"tw-flex tw-items-center tw-space-x-2",children:[a.jsx("p",{className:"tw-text-nowrap tw-text-sm tw-font-medium",children:"Rows per page"}),a.jsxs(At,{value:`${e.getState().pagination.pageSize}`,onValueChange:t=>{e.setPageSize(Number(t))},children:[a.jsx(bt,{className:"tw-h-8 tw-w-[70px]",children:a.jsx(Bt,{placeholder:e.getState().pagination.pageSize})}),a.jsx(vt,{side:"top",children:[10,20,30,40,50].map(t=>a.jsx(Ae,{value:`${t}`,children:t},t))})]})]}),a.jsxs("div",{className:"tw-flex tw-w-[100px] tw-items-center tw-justify-center tw-text-sm tw-font-medium",children:["Page ",e.getState().pagination.pageIndex+1," of ",e.getPageCount()]}),a.jsxs("div",{className:"tw-flex tw-items-center tw-space-x-2",children:[a.jsxs(fe,{variant:"outline",size:"icon",className:"tw-hidden tw-h-8 tw-w-8 tw-p-0 lg:tw-flex",onClick:()=>e.setPageIndex(0),disabled:!e.getCanPreviousPage(),children:[a.jsx("span",{className:"tw-sr-only",children:"Go to first page"}),a.jsx(Q.ArrowLeftIcon,{className:"tw-h-4 tw-w-4"})]}),a.jsxs(fe,{variant:"outline",size:"icon",className:"tw-h-8 tw-w-8 tw-p-0",onClick:()=>e.previousPage(),disabled:!e.getCanPreviousPage(),children:[a.jsx("span",{className:"tw-sr-only",children:"Go to previous page"}),a.jsx(Q.ChevronLeftIcon,{className:"tw-h-4 tw-w-4"})]}),a.jsxs(fe,{variant:"outline",size:"icon",className:"tw-h-8 tw-w-8 tw-p-0",onClick:()=>e.nextPage(),disabled:!e.getCanNextPage(),children:[a.jsx("span",{className:"tw-sr-only",children:"Go to next page"}),a.jsx(Q.ChevronRightIcon,{className:"tw-h-4 tw-w-4"})]}),a.jsxs(fe,{variant:"outline",size:"icon",className:"tw-hidden tw-h-8 tw-w-8 tw-p-0 lg:tw-flex",onClick:()=>e.setPageIndex(e.getPageCount()-1),disabled:!e.getCanNextPage(),children:[a.jsx("span",{className:"tw-sr-only",children:"Go to last page"}),a.jsx(Q.ArrowRightIcon,{className:"tw-h-4 tw-w-4"})]})]})]})})}const Tn=g.forwardRef(({className:e,stickyHeader:t,...n},r)=>a.jsx("div",{className:N("pr-twp tw-relative tw-w-full",{"tw-overflow-auto":!t}),children:a.jsx("table",{ref:r,className:N("tw-w-full tw-caption-bottom tw-text-sm",e),...n})}));Tn.displayName="Table";const Cn=g.forwardRef(({className:e,stickyHeader:t,...n},r)=>a.jsx("thead",{ref:r,className:N({"tw-sticky tw-top-[-1px] tw-bg-background tw-drop-shadow-sm":t},"[&_tr]:tw-border-b",e),...n}));Cn.displayName="TableHeader";const Rn=g.forwardRef(({className:e,...t},n)=>a.jsx("tbody",{ref:n,className:N("[&_tr:last-child]:tw-border-0",e),...t}));Rn.displayName="TableBody";const js=g.forwardRef(({className:e,...t},n)=>a.jsx("tfoot",{ref:n,className:N("tw-border-t tw-bg-muted/50 tw-font-medium [&>tr]:last:tw-border-b-0",e),...t}));js.displayName="TableFooter";const Ze=g.forwardRef(({className:e,...t},n)=>a.jsx("tr",{ref:n,className:N("tw-border-b tw-transition-colors hover:tw-bg-muted/50 data-[state=selected]:tw-bg-muted",e),...t}));Ze.displayName="TableRow";const Vt=g.forwardRef(({className:e,...t},n)=>a.jsx("th",{ref:n,className:N("tw-h-12 tw-px-4 tw-text-start tw-align-middle tw-font-medium tw-text-muted-foreground [&:has([role=checkbox])]:tw-pe-0",e),...t}));Vt.displayName="TableHead";const xt=g.forwardRef(({className:e,...t},n)=>a.jsx("td",{ref:n,className:N("tw-p-4 tw-align-middle [&:has([role=checkbox])]:tw-pe-0",e),...t}));xt.displayName="TableCell";const Ts=g.forwardRef(({className:e,...t},n)=>a.jsx("caption",{ref:n,className:N("tw-mt-4 tw-text-sm tw-text-muted-foreground",e),...t}));Ts.displayName="TableCaption";function Cs({columns:e,data:t,enablePagination:n=!1,showPaginationControls:r=!1,showColumnVisibilityControls:o=!1,stickyHeader:s=!1,onRowClickHandler:i=()=>{}}){var h;const[l,c]=g.useState([]),[d,u]=g.useState([]),[m,w]=g.useState({}),[b,x]=g.useState({}),f=Se.useReactTable({data:t,columns:e,getCoreRowModel:Se.getCoreRowModel(),...n&&{getPaginationRowModel:Se.getPaginationRowModel()},onSortingChange:c,getSortedRowModel:Se.getSortedRowModel(),onColumnFiltersChange:u,getFilteredRowModel:Se.getFilteredRowModel(),onColumnVisibilityChange:w,onRowSelectionChange:x,state:{sorting:l,columnFilters:d,columnVisibility:m,rowSelection:b}});return a.jsxs("div",{className:"pr-twp",children:[o&&a.jsx(gc,{table:f}),a.jsxs(Tn,{stickyHeader:s,children:[a.jsx(Cn,{stickyHeader:s,children:f.getHeaderGroups().map(S=>a.jsx(Ze,{children:S.headers.map(R=>a.jsx(Vt,{children:R.isPlaceholder?void 0:Se.flexRender(R.column.columnDef.header,R.getContext())},R.id))},S.id))}),a.jsx(Rn,{children:(h=f.getRowModel().rows)!=null&&h.length?f.getRowModel().rows.map(S=>a.jsx(Ze,{onClick:()=>i(S,f),"data-state":S.getIsSelected()&&"selected",children:S.getVisibleCells().map(R=>a.jsx(xt,{children:Se.flexRender(R.column.columnDef.cell,R.getContext())},R.id))},S.id)):a.jsx(Ze,{children:a.jsx(xt,{colSpan:e.length,className:"tw-h-24 tw-text-center",children:"No results."})})})]}),n&&a.jsxs("div",{className:"tw-flex tw-items-center tw-justify-end tw-space-x-2 tw-py-4",children:[a.jsx(fe,{variant:"outline",size:"sm",onClick:()=>f.previousPage(),disabled:!f.getCanPreviousPage(),children:"Previous"}),a.jsx(fe,{variant:"outline",size:"sm",onClick:()=>f.nextPage(),disabled:!f.getCanNextPage(),children:"Next"})]}),n&&r&&a.jsx(bc,{table:f})]})}function vc({occurrenceData:e,setScriptureReference:t,localizedStrings:n}){const r=n["%webView_inventory_occurrences_table_header_reference%"],o=n["%webView_inventory_occurrences_table_header_occurrence%"],s=g.useMemo(()=>{const i=[];return e.forEach(l=>{i.some(c=>W.deepEqual(c,l))||i.push(l)}),i},[e]);return a.jsxs(Tn,{stickyHeader:!0,children:[a.jsx(Cn,{stickyHeader:!0,children:a.jsxs(Ze,{children:[a.jsx(Vt,{children:r}),a.jsx(Vt,{children:o})]})}),a.jsx(Rn,{children:s.length>0&&s.map(i=>a.jsxs(Ze,{onClick:()=>{t(i.reference)},children:[a.jsx(xt,{children:`${ae.bookNumberToEnglishName(i.reference.bookNum)} ${i.reference.chapterNum}:${i.reference.verseNum}`}),a.jsx(xt,{children:i.text})]},`${i.reference.bookNum} ${i.reference.chapterNum}:${i.reference.verseNum}-${i.text}`))})]})}const ar=g.forwardRef(({className:e,...t},n)=>a.jsx(Gr.Root,{ref:n,className:N("tw-peer pr-twp tw-h-4 tw-w-4 tw-shrink-0 tw-rounded-sm tw-border tw-border-primary tw-ring-offset-background focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-cursor-not-allowed disabled:tw-opacity-50 data-[state=checked]:tw-bg-primary data-[state=checked]:tw-text-primary-foreground",e),...t,children:a.jsx(Gr.Indicator,{className:N("tw-flex tw-items-center tw-justify-center tw-text-current"),children:a.jsx(Q.Check,{className:"tw-h-4 tw-w-4"})})}));ar.displayName=Gr.Root.displayName;const Rs=e=>e.split(/(?:\r?\n|\r)|(?=(?:\\(?:v|c|id)))/g),Hr=e=>{const t=/^\\[vc]\s+(\d+)/,n=e.match(t);if(n)return+n[1]},Os=e=>{const t=e.match(/^\\id\s+([A-Za-z]+)/);return t?ae.bookIdToNumber(t[1]):0},_s=(e,t,n)=>n.includes(e)?"unapproved":t.includes(e)?"approved":"unknown",Ps=Xt.cva("pr-twp tw-inline-flex tw-items-center tw-justify-center tw-rounded-md tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-colors hover:tw-bg-muted hover:tw-text-muted-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50 data-[state=on]:tw-bg-accent data-[state=on]:tw-text-accent-foreground",{variants:{variant:{default:"tw-bg-transparent",outline:"tw-border tw-border-input tw-bg-transparent hover:tw-bg-accent hover:tw-text-accent-foreground"},size:{default:"tw-h-10 tw-px-3",sm:"tw-h-9 tw-px-2.5",lg:"tw-h-11 tw-px-5"}},defaultVariants:{variant:"default",size:"default"}}),xc=g.forwardRef(({className:e,variant:t,size:n,...r},o)=>a.jsx(ts.Root,{ref:o,className:N(Ps({variant:t,size:n,className:e})),...r}));xc.displayName=ts.Root.displayName;const Is=g.createContext({size:"default",variant:"default"}),po=g.forwardRef(({className:e,variant:t,size:n,children:r,...o},s)=>a.jsx(nr.Root,{ref:s,className:N("pr-twp tw-flex tw-items-center tw-justify-center tw-gap-1",e),...o,children:a.jsx(Is.Provider,{value:{variant:t,size:n},children:r})}));po.displayName=nr.Root.displayName;const fn=g.forwardRef(({className:e,children:t,variant:n,size:r,...o},s)=>{const i=g.useContext(Is);return a.jsx(nr.Item,{ref:s,className:N(Ps({variant:i.variant||n,size:i.size||r}),e),...o,children:t})});fn.displayName=nr.Item.displayName;const sr=e=>e==="asc"?a.jsx(Q.ArrowUpIcon,{className:"tw-ms-2 tw-h-4 tw-w-4"}):e==="desc"?a.jsx(Q.ArrowDownIcon,{className:"tw-ms-2 tw-h-4 tw-w-4"}):a.jsx(Q.ArrowUpDownIcon,{className:"tw-ms-2 tw-h-4 tw-w-4"}),yc=e=>({accessorKey:"item",accessorFn:t=>t.items[0],header:({column:t})=>a.jsxs(fe,{variant:"ghost",onClick:()=>t.toggleSorting(void 0),children:[e,sr(t.getIsSorted())]})}),Nc=(e,t)=>({accessorKey:`item${t}`,accessorFn:n=>n.items[t],header:({column:n})=>a.jsxs(fe,{variant:"ghost",onClick:()=>n.toggleSorting(void 0),children:[e,sr(n.getIsSorted())]})}),kc=e=>({accessorKey:"count",header:({column:t})=>a.jsx("div",{className:"tw-flex tw-justify-end tw-tabular-nums",children:a.jsxs(fe,{variant:"ghost",onClick:()=>t.toggleSorting(void 0),children:[e,sr(t.getIsSorted())]})}),cell:({row:t})=>a.jsx("div",{className:"tw-flex tw-justify-end",children:t.getValue("count")})}),Cr=(e,t,n,r,o,s)=>{let i=[...n];e.forEach(c=>{t==="approved"?i.includes(c)||i.push(c):i=i.filter(d=>d!==c)}),r(i);let l=[...o];e.forEach(c=>{t==="unapproved"?l.includes(c)||l.push(c):l=l.filter(d=>d!==c)}),s(l)},Sc=(e,t,n,r,o)=>({accessorKey:"status",header:({column:s})=>a.jsx("div",{className:"tw-flex tw-justify-center",children:a.jsxs(fe,{variant:"ghost",onClick:()=>s.toggleSorting(void 0),children:[e,sr(s.getIsSorted())]})}),cell:({row:s})=>{const i=s.getValue("status"),l=s.getValue("item");return a.jsxs(po,{value:i,variant:"outline",type:"single",children:[a.jsx(fn,{onClick:()=>Cr([l],"approved",t,n,r,o),value:"approved",children:a.jsx(Q.CircleCheckIcon,{})}),a.jsx(fn,{onClick:()=>Cr([l],"unapproved",t,n,r,o),value:"unapproved",children:a.jsx(Q.CircleXIcon,{})}),a.jsx(fn,{onClick:()=>Cr([l],"unknown",t,n,r,o),value:"unknown",children:a.jsx(Q.CircleHelpIcon,{})})]})}}),Ec=Object.freeze(["%webView_inventory_all%","%webView_inventory_approved%","%webView_inventory_unapproved%","%webView_inventory_unknown%","%webView_inventory_scope_currentBook%","%webView_inventory_scope_chapter%","%webView_inventory_scope_verse%","%webView_inventory_filter_text%","%webView_inventory_show_additional_items%","%webView_inventory_occurrences_table_header_reference%","%webView_inventory_occurrences_table_header_occurrence%"]),jc=(e,t,n)=>{let r=e;return t!=="all"&&(r=r.filter(o=>t==="approved"&&o.status==="approved"||t==="unapproved"&&o.status==="unapproved"||t==="unknown"&&o.status==="unknown")),n!==""&&(r=r.filter(o=>o.items[0].includes(n))),r},Tc=(e,t,n,r,o)=>{if(!e)return[];const s=[];let i=t.bookNum,l=t.chapterNum,c=t.verseNum;return Rs(e).forEach(u=>{u.startsWith("\\id")&&(i=Os(u),l=0,c=0),u.startsWith("\\c")&&(l=Hr(u),c=0),u.startsWith("\\v")&&(c=Hr(u),l===0&&(l=t.chapterNum));let m=o.exec(u)??void 0;for(;m;){const w=[];m.forEach(h=>w.push(h));const b=m.index,x=s.find(h=>W.deepEqual(h.items,w)),f={reference:{bookNum:i!==void 0?i:-1,chapterNum:l!==void 0?l:-1,verseNum:c!==void 0?c:-1},text:W.substring(u,Math.max(0,b-25),Math.min(b+25,u.length))};if(x)x.count+=1,x.occurrences.push(f);else{const h={items:w,count:1,status:_s(w[0],n,r),occurrences:[f]};s.push(h)}m=o.exec(u)??void 0}}),s},Je=(e,t)=>e[t]??t;function Cc({scriptureReference:e,setScriptureReference:t,localizedStrings:n,extractItems:r,additionalItemsLabels:o,approvedItems:s,unapprovedItems:i,text:l,scope:c,onScopeChange:d,columns:u}){const m=Je(n,"%webView_inventory_all%"),w=Je(n,"%webView_inventory_approved%"),b=Je(n,"%webView_inventory_unapproved%"),x=Je(n,"%webView_inventory_unknown%"),f=Je(n,"%webView_inventory_scope_currentBook%"),h=Je(n,"%webView_inventory_scope_chapter%"),S=Je(n,"%webView_inventory_scope_verse%"),R=Je(n,"%webView_inventory_filter_text%"),j=Je(n,"%webView_inventory_show_additional_items%"),[E,v]=g.useState(!1),[P,V]=g.useState("all"),[U,T]=g.useState(""),[_,k]=g.useState([]),D=g.useMemo(()=>l?r instanceof RegExp?Tc(l,e,s,i,r):r(l,e,s,i):[],[l,r,e,s,i]),$=g.useMemo(()=>{if(E)return D;const y=[];return D.forEach(C=>{const z=C.items[0],L=y.find(B=>B.items[0]===z);L?(L.count+=C.count,L.occurrences=L.occurrences.concat(C.occurrences)):y.push({items:[z],count:C.count,occurrences:C.occurrences,status:C.status})}),y},[E,D]),J=g.useMemo(()=>jc($,P,U),[$,P,U]),Y=g.useMemo(()=>{var z,L;if(!E)return u;const y=(z=o==null?void 0:o.tableHeaders)==null?void 0:z.length;if(!y)return u;const C=[];for(let B=0;B{k([])},[J]);const F=(y,C)=>{C.setRowSelection(()=>{const z={};return z[y.index]=!0,z}),k(y.original.items)},te=y=>{if(y==="book"||y==="chapter"||y==="verse")d(y);else throw new Error(`Invalid scope value: ${y}`)},se=y=>{if(y==="all"||y==="approved"||y==="unapproved"||y==="unknown")V(y);else throw new Error(`Invalid status filter value: ${y}`)},oe=g.useMemo(()=>{if($.length===0||_.length===0)return[];const y=$.filter(C=>W.deepEqual(E?C.items:[C.items[0]],_));if(y.length>1)throw new Error("Selected item is not unique");return y[0].occurrences},[_,E,$]);return a.jsxs("div",{className:"pr-twp tw-flex tw-h-full tw-flex-col",children:[a.jsxs("div",{className:"tw-flex tw-items-stretch",children:[a.jsxs(At,{onValueChange:y=>se(y),defaultValue:P,children:[a.jsx(bt,{className:"tw-m-1",children:a.jsx(Bt,{placeholder:"Select filter"})}),a.jsxs(vt,{children:[a.jsx(Ae,{value:"all",children:m}),a.jsx(Ae,{value:"approved",children:w}),a.jsx(Ae,{value:"unapproved",children:b}),a.jsx(Ae,{value:"unknown",children:x})]})]}),a.jsxs(At,{onValueChange:y=>te(y),defaultValue:c,children:[a.jsx(bt,{className:"tw-m-1",children:a.jsx(Bt,{placeholder:"Select scope"})}),a.jsxs(vt,{children:[a.jsx(Ae,{value:"book",children:f}),a.jsx(Ae,{value:"chapter",children:h}),a.jsx(Ae,{value:"verse",children:S})]})]}),a.jsx(St,{className:"tw-m-1 tw-rounded-md tw-border",placeholder:R,value:U,onChange:y=>{T(y.target.value)}}),o&&a.jsxs("div",{className:"tw-m-1 tw-flex tw-items-center tw-rounded-md tw-border",children:[a.jsx(ar,{className:"tw-m-1",checked:E,onCheckedChange:y=>{k([]),v(y)}}),a.jsx(qe,{className:"tw-m-1 tw-flex-shrink-0 tw-whitespace-nowrap",children:(o==null?void 0:o.checkboxText)??j})]})]}),a.jsx("div",{className:"tw-m-1 tw-flex-1 tw-overflow-auto tw-rounded-md tw-border",children:a.jsx(Cs,{columns:Y,data:J,onRowClickHandler:F,stickyHeader:!0})}),oe.length>0&&a.jsx("div",{className:"tw-m-1 tw-flex-1 tw-overflow-auto tw-rounded-md tw-border",children:a.jsx(vc,{occurrenceData:oe,setScriptureReference:t,localizedStrings:n})})]})}function Ms({onSearch:e,placeholder:t,isFullWidth:n}){const[r,o]=g.useState(""),s=i=>{o(i),e(i)};return a.jsx(St,{className:N("tw-flex tw-h-10 tw-rounded-md tw-border tw-border-input tw-bg-background tw-px-3 tw-py-2 tw-text-sm tw-ring-offset-background file:tw-border-0 file:tw-bg-transparent file:tw-text-sm file:tw-font-medium placeholder:tw-text-muted-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-[color:hsl(240,5%,64.9%)] focus-visible:tw-ring-offset-2 disabled:tw-cursor-not-allowed disabled:tw-opacity-50",{"tw-w-full":n}),placeholder:t,value:r,onChange:i=>s(i.target.value)})}const wo=g.forwardRef(({className:e,...t},n)=>a.jsx(_e.Root,{orientation:"vertical",ref:n,className:N("tw-flex tw-gap-1 tw-rounded-md tw-text-muted-foreground",e),...t}));wo.displayName=_e.List.displayName;const fo=g.forwardRef(({className:e,...t},n)=>a.jsx(_e.List,{ref:n,className:N("tw-flex-fit tw-mlk-items-center tw-w-[124px] tw-justify-center tw-rounded-md tw-bg-muted tw-p-1 tw-text-muted-foreground",e),...t}));fo.displayName=_e.List.displayName;const $s=g.forwardRef(({className:e,...t},n)=>a.jsx(_e.Trigger,{ref:n,...t,className:N("overflow-clip tw-inline-flex tw-w-[116px] tw-cursor-pointer tw-items-center tw-justify-center tw-break-words tw-rounded-sm tw-border-0 tw-bg-muted tw-px-3 tw-py-1.5 tw-text-sm tw-font-medium tw-text-inherit tw-ring-offset-background tw-transition-all hover:tw-text-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50 data-[state=active]:tw-bg-background data-[state=active]:tw-text-foreground data-[state=active]:tw-shadow-sm",e)})),mo=g.forwardRef(({className:e,...t},n)=>a.jsx(_e.Content,{ref:n,className:N("tw-ms-5 tw-flex-grow tw-text-foreground tw-ring-offset-background focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2",e),...t}));mo.displayName=_e.Content.displayName;function Rc({tabList:e,onSearch:t,searchPlaceholder:n,headerTitle:r,isSearchBarFullWidth:o=!1,direction:s="ltr"}){return a.jsxs("div",{className:"pr-twp",children:[a.jsxs("div",{className:"tw-sticky tw-top-0 tw-space-y-2 tw-pb-2",children:[r?a.jsx("h1",{children:r}):"",a.jsx(Ms,{isFullWidth:o,onSearch:t,placeholder:n})]}),a.jsxs(wo,{dir:s,children:[a.jsx(fo,{children:e.map(i=>a.jsx($s,{value:i.value,children:i.value},i.key))}),e.map(i=>a.jsx(mo,{value:i.value,children:i.content},i.key))]})]})}const ir=g.forwardRef(({className:e,orientation:t="horizontal",decorative:n=!0,...r},o)=>a.jsx(ns.Root,{ref:o,decorative:n,orientation:t,className:N("pr-twp tw-shrink-0 tw-bg-border",t==="horizontal"?"tw-h-[1px] tw-w-full":"tw-h-full tw-w-[1px]",e),...r}));ir.displayName=ns.Root.displayName;const Oc=be.Root,_c=be.Portal,Ds=M.forwardRef(({className:e,...t},n)=>a.jsx(be.Overlay,{className:N("tw-fixed tw-inset-0 tw-z-50 tw-bg-black/80 data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0",e),...t,ref:n}));Ds.displayName=be.Overlay.displayName;const Pc=Xt.cva("pr-twp tw-fixed tw-z-50 tw-gap-4 tw-bg-background tw-p-6 tw-shadow-lg tw-transition tw-ease-in-out data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-duration-300 data-[state=open]:tw-duration-500",{variants:{side:{top:"tw-inset-x-0 tw-top-0 tw-border-b data-[state=closed]:tw-slide-out-to-top data-[state=open]:tw-slide-in-from-top",bottom:"tw-inset-x-0 tw-bottom-0 tw-border-t data-[state=closed]:tw-slide-out-to-bottom data-[state=open]:tw-slide-in-from-bottom",left:"tw-inset-y-0 tw-left-0 tw-h-full tw-w-3/4 tw-border-r data-[state=closed]:tw-slide-out-to-left data-[state=open]:tw-slide-in-from-left sm:tw-max-w-sm",right:"tw-inset-y-0 tw-right-0 tw-h-full tw-w-3/4 tw- tw-border-l data-[state=closed]:tw-slide-out-to-right data-[state=open]:tw-slide-in-from-right sm:tw-max-w-sm"}},defaultVariants:{side:"right"}}),As=M.forwardRef(({side:e="right",className:t,children:n,...r},o)=>a.jsxs(_c,{children:[a.jsx(Ds,{}),a.jsxs(be.Content,{ref:o,className:N(Pc({side:e}),t),...r,children:[n,a.jsxs(be.Close,{className:"tw-absolute tw-right-4 tw-top-4 tw-rounded-sm tw-opacity-70 tw-ring-offset-background tw-transition-opacity hover:tw-opacity-100 focus:tw-outline-none focus:tw-ring-2 focus:tw-ring-ring focus:tw-ring-offset-2 disabled:tw-pointer-events-none data-[state=open]:tw-bg-secondary",children:[a.jsx(Q.X,{className:"tw-h-4 tw-w-4"}),a.jsx("span",{className:"tw-sr-only",children:"Close"})]})]})]}));As.displayName=be.Content.displayName;const Ic=M.forwardRef(({className:e,...t},n)=>a.jsx(be.Title,{ref:n,className:N("tw-text-lg tw-font-semibold tw-text-foreground",e),...t}));Ic.displayName=be.Title.displayName;const Mc=M.forwardRef(({className:e,...t},n)=>a.jsx(be.Description,{ref:n,className:N("tw-text-sm tw-text-muted-foreground",e),...t}));Mc.displayName=be.Description.displayName;function sa({className:e,...t}){return a.jsx("div",{className:N("pr-twp tw-animate-pulse tw-rounded-md tw-bg-muted",e),...t})}const $c=Sn.Provider,Dc=Sn.Root,Ac=Sn.Trigger,Bs=g.forwardRef(({className:e,sideOffset:t=4,...n},r)=>a.jsx(Sn.Content,{ref:r,sideOffset:t,className:N("pr-twp tw-z-50 tw-overflow-hidden tw-rounded-md tw-border tw-bg-popover tw-px-3 tw-py-1.5 tw-text-sm tw-text-popover-foreground tw-shadow-md tw-animate-in tw-fade-in-0 tw-zoom-in-95 data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=closed]:tw-zoom-out-95 data-[side=bottom]:tw-slide-in-from-top-2 data-[side=left]:tw-slide-in-from-right-2 data-[side=right]:tw-slide-in-from-left-2 data-[side=top]:tw-slide-in-from-bottom-2",e),...n}));Bs.displayName=Sn.Content.displayName;const Rr=768;function Bc(){const[e,t]=M.useState(void 0);return M.useEffect(()=>{const n=window.matchMedia(`(max-width: ${Rr-1}px)`),r=()=>{t(window.innerWidthn.removeEventListener("change",r)},[]),!!e}const Vc="sidebar:state",zc=60*60*24*7,Lc="16rem",Fc="18rem",Gc="3rem",Uc="b",Vs=g.createContext(void 0);function lr(){const e=g.useContext(Vs);if(!e)throw new Error("useSidebar must be used within a SidebarProvider.");return e}const zs=g.forwardRef(({defaultOpen:e=!0,open:t,onOpenChange:n,className:r,style:o,children:s,...i},l)=>{const c=Bc(),[d,u]=g.useState(!1),[m,w]=g.useState(e),b=t??m,x=g.useCallback(R=>{const j=typeof R=="function"?R(b):R;n?n(j):w(j),document.cookie=`${Vc}=${j}; path=/; max-age=${zc}`},[n,b]),f=g.useCallback(()=>c?u(R=>!R):x(R=>!R),[c,x,u]);g.useEffect(()=>{const R=j=>{j.key===Uc&&(j.metaKey||j.ctrlKey)&&(j.preventDefault(),f())};return window.addEventListener("keydown",R),()=>window.removeEventListener("keydown",R)},[f]);const h=b?"expanded":"collapsed",S=g.useMemo(()=>({state:h,open:b,setOpen:x,isMobile:c,openMobile:d,setOpenMobile:u,toggleSidebar:f}),[h,b,x,c,d,u,f]);return a.jsx(Vs.Provider,{value:S,children:a.jsx($c,{delayDuration:0,children:a.jsx("div",{style:{"--sidebar-width":Lc,"--sidebar-width-icon":Gc,...o},className:N("tw-group/sidebar-wrapper pr-twp tw-flex tw-min-h-svh tw-w-full has-[[data-variant=inset]]:tw-bg-sidebar",r),ref:l,...i,children:s})})})});zs.displayName="SidebarProvider";const Ls=g.forwardRef(({side:e="left",variant:t="sidebar",collapsible:n="offcanvas",className:r,children:o,...s},i)=>{const{isMobile:l,state:c,openMobile:d,setOpenMobile:u}=lr();return n==="none"?a.jsx("div",{className:N("tw-flex tw-h-full tw-w-[--sidebar-width] tw-flex-col tw-bg-sidebar tw-text-sidebar-foreground",r),ref:i,...s,children:o}):l?a.jsx(Oc,{open:d,onOpenChange:u,...s,children:a.jsx(As,{"data-sidebar":"sidebar","data-mobile":"true",className:"tw-w-[--sidebar-width] tw-bg-sidebar tw-p-0 tw-text-sidebar-foreground [&>button]:tw-hidden",style:{"--sidebar-width":Fc},side:e,children:a.jsx("div",{className:"tw-flex tw-h-full tw-w-full tw-flex-col",children:o})})}):a.jsxs("div",{ref:i,className:"tw-group tw-peer tw-hidden tw-text-sidebar-foreground md:tw-block","data-state":c,"data-collapsible":c==="collapsed"?n:"","data-variant":t,"data-side":e,children:[a.jsx("div",{className:N("tw-relative tw-h-svh tw-w-[--sidebar-width] tw-bg-transparent tw-transition-[width] tw-duration-200 tw-ease-linear","group-data-[collapsible=offcanvas]:tw-w-0","group-data-[side=right]:tw-rotate-180",t==="floating"||t==="inset"?"group-data-[collapsible=icon]:tw-w-[calc(var(--sidebar-width-icon)_+_theme(spacing.4))]":"group-data-[collapsible=icon]:tw-w-[--sidebar-width-icon]")}),a.jsx("div",{className:N("tw-absolute tw-inset-y-0 tw-z-10 tw-hidden tw-h-svh tw-w-[--sidebar-width] tw-transition-[left,right,width] tw-duration-200 tw-ease-linear md:tw-flex",e==="left"?"tw-left-0 group-data-[collapsible=offcanvas]:tw-left-[calc(var(--sidebar-width)*-1)]":"tw-right-0 group-data-[collapsible=offcanvas]:tw-right-[calc(var(--sidebar-width)*-1)]",t==="floating"||t==="inset"?"tw-p-2 group-data-[collapsible=icon]:tw-w-[calc(var(--sidebar-width-icon)_+_theme(spacing.4)_+2px)]":"group-data-[collapsible=icon]:tw-w-[--sidebar-width-icon] group-data-[side=left]:tw-border-r group-data-[side=right]:tw-border-l",r),...s,children:a.jsx("div",{"data-sidebar":"sidebar",className:"tw-flex tw-h-full tw-w-full tw-flex-col tw-bg-sidebar group-data-[variant=floating]:tw-rounded-lg group-data-[variant=floating]:tw-border group-data-[variant=floating]:tw-border-sidebar-border group-data-[variant=floating]:tw-shadow",children:o})})]})});Ls.displayName="Sidebar";const qc=g.forwardRef(({className:e,onClick:t,...n},r)=>{const{toggleSidebar:o}=lr();return a.jsxs(fe,{ref:r,"data-sidebar":"trigger",variant:"ghost",size:"icon",className:N("tw-h-7 tw-w-7",e),onClick:s=>{t==null||t(s),o()},...n,children:[a.jsx(Q.PanelLeft,{}),a.jsx("span",{className:"tw-sr-only",children:"Toggle Sidebar"})]})});qc.displayName="SidebarTrigger";const Hc=g.forwardRef(({className:e,...t},n)=>{const{toggleSidebar:r}=lr();return a.jsx("button",{type:"button",ref:n,"data-sidebar":"rail","aria-label":"Toggle Sidebar",tabIndex:-1,onClick:r,title:"Toggle Sidebar",className:N("tw-absolute tw-inset-y-0 tw-z-20 tw-hidden tw-w-4 tw--translate-x-1/2 tw-transition-all tw-ease-linear after:tw-absolute after:tw-inset-y-0 after:tw-left-1/2 after:tw-w-[2px] hover:after:tw-bg-sidebar-border group-data-[side=left]:tw--right-4 group-data-[side=right]:tw-left-0 sm:tw-flex","[[data-side=left]_&]:tw-cursor-w-resize [[data-side=right]_&]:tw-cursor-e-resize","[[data-side=left][data-state=collapsed]_&]:tw-cursor-e-resize [[data-side=right][data-state=collapsed]_&]:tw-cursor-w-resize","group-data-[collapsible=offcanvas]:tw-translate-x-0 group-data-[collapsible=offcanvas]:after:tw-left-full group-data-[collapsible=offcanvas]:hover:tw-bg-sidebar","[[data-side=left][data-collapsible=offcanvas]_&]:tw--right-2","[[data-side=right][data-collapsible=offcanvas]_&]:tw--left-2",e),...t})});Hc.displayName="SidebarRail";const Fs=g.forwardRef(({className:e,...t},n)=>a.jsx("main",{ref:n,className:N("tw-relative tw-flex tw-min-h-svh tw-flex-1 tw-flex-col tw-bg-background","peer-data-[variant=inset]:tw-min-h-[calc(100svh-theme(spacing.4))] md:peer-data-[variant=inset]:tw-m-2 md:peer-data-[state=collapsed]:peer-data-[variant=inset]:tw-ml-2 md:peer-data-[variant=inset]:tw-ml-0 md:peer-data-[variant=inset]:tw-rounded-xl md:peer-data-[variant=inset]:tw-shadow",e),...t}));Fs.displayName="SidebarInset";const Xc=g.forwardRef(({className:e,...t},n)=>a.jsx(St,{ref:n,"data-sidebar":"input",className:N("tw-h-8 tw-w-full tw-bg-background tw-shadow-none focus-visible:tw-ring-2 focus-visible:tw-ring-sidebar-ring",e),...t}));Xc.displayName="SidebarInput";const Yc=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,"data-sidebar":"header",className:N("tw-flex tw-flex-col tw-gap-2 tw-p-2",e),...t}));Yc.displayName="SidebarHeader";const Wc=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,"data-sidebar":"footer",className:N("tw-flex tw-flex-col tw-gap-2 tw-p-2",e),...t}));Wc.displayName="SidebarFooter";const Kc=g.forwardRef(({className:e,...t},n)=>a.jsx(ir,{ref:n,"data-sidebar":"separator",className:N("tw-mx-2 tw-w-auto tw-bg-sidebar-border",e),...t}));Kc.displayName="SidebarSeparator";const Gs=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,"data-sidebar":"content",className:N("tw-flex tw-min-h-0 tw-flex-1 tw-flex-col tw-gap-2 tw-overflow-auto group-data-[collapsible=icon]:tw-overflow-hidden",e),...t}));Gs.displayName="SidebarContent";const Us=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,"data-sidebar":"group",className:N("tw-relative tw-flex tw-w-full tw-min-w-0 tw-flex-col tw-p-2",e),...t}));Us.displayName="SidebarGroup";const qs=g.forwardRef(({className:e,asChild:t=!1,...n},r)=>{const o=t?Ht.Slot:"div";return a.jsx(o,{ref:r,"data-sidebar":"group-label",className:N("tw-flex tw-h-8 tw-shrink-0 tw-items-center tw-rounded-md tw-px-2 tw-text-xs tw-font-medium tw-text-sidebar-foreground/70 tw-outline-none tw-ring-sidebar-ring tw-transition-[margin,opa] tw-duration-200 tw-ease-linear focus-visible:tw-ring-2 [&>svg]:tw-size-4 [&>svg]:tw-shrink-0","group-data-[collapsible=icon]:tw--mt-8 group-data-[collapsible=icon]:tw-opacity-0",e),...n})});qs.displayName="SidebarGroupLabel";const Jc=g.forwardRef(({className:e,asChild:t=!1,...n},r)=>{const o=t?Ht.Slot:"button";return a.jsx(o,{ref:r,"data-sidebar":"group-action",className:N("tw-absolute tw-right-3 tw-top-3.5 tw-flex tw-aspect-square tw-w-5 tw-items-center tw-justify-center tw-rounded-md tw-p-0 tw-text-sidebar-foreground tw-outline-none tw-ring-sidebar-ring tw-transition-transform hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground focus-visible:tw-ring-2 [&>svg]:tw-size-4 [&>svg]:tw-shrink-0","after:tw-absolute after:tw--inset-2 after:md:tw-hidden","group-data-[collapsible=icon]:tw-hidden",e),...n})});Jc.displayName="SidebarGroupAction";const Hs=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,"data-sidebar":"group-content",className:N("tw-w-full tw-text-sm",e),...t}));Hs.displayName="SidebarGroupContent";const Xs=g.forwardRef(({className:e,...t},n)=>a.jsx("ul",{ref:n,"data-sidebar":"menu",className:N("tw-flex tw-w-full tw-min-w-0 tw-flex-col tw-gap-1",e),...t}));Xs.displayName="SidebarMenu";const Ys=g.forwardRef(({className:e,...t},n)=>a.jsx("li",{ref:n,"data-sidebar":"menu-item",className:N("tw-group/menu-item tw-relative",e),...t}));Ys.displayName="SidebarMenuItem";const Zc=Xt.cva("tw-peer/menu-button tw-flex tw-w-full tw-items-center tw-gap-2 tw-overflow-hidden tw-rounded-md tw-p-2 tw-text-left tw-text-sm tw-outline-none tw-ring-sidebar-ring tw-transition-[width,height,padding] hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground focus-visible:tw-ring-2 active:tw-bg-sidebar-accent active:tw-text-sidebar-accent-foreground disabled:tw-pointer-events-none disabled:tw-opacity-50 tw-group-has-[[data-sidebar=menu-action]]/menu-item:pr-8 aria-disabled:tw-pointer-events-none aria-disabled:tw-opacity-50 data-[active=true]:tw-bg-sidebar-accent data-[active=true]:tw-font-medium data-[active=true]:tw-text-sidebar-accent-foreground data-[state=open]:hover:tw-bg-sidebar-accent data-[state=open]:hover:tw-text-sidebar-accent-foreground group-data-[collapsible=icon]:tw-!size-8 group-data-[collapsible=icon]:tw-!p-2 [&>span:last-child]:tw-truncate [&>svg]:tw-size-4 [&>svg]:tw-shrink-0",{variants:{variant:{default:"hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground",outline:"tw-bg-background tw-shadow-[0_0_0_1px_hsl(var(--sidebar-border))] hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground hover:tw-shadow-[0_0_0_1px_hsl(var(--sidebar-accent))]"},size:{default:"tw-h-8 tw-text-sm",sm:"tw-h-7 tw-text-xs",lg:"tw-h-12 tw-text-sm group-data-[collapsible=icon]:tw-!p-0"}},defaultVariants:{variant:"default",size:"default"}}),Ws=g.forwardRef(({asChild:e=!1,isActive:t=!1,variant:n="default",size:r="default",tooltip:o,className:s,...i},l)=>{const c=e?Ht.Slot:"button",{isMobile:d,state:u}=lr(),m=a.jsx(c,{ref:l,"data-sidebar":"menu-button","data-size":r,"data-active":t,className:N(Zc({variant:n,size:r}),s),...i});return o?(typeof o=="string"&&(o={children:o}),a.jsxs(Dc,{children:[a.jsx(Ac,{asChild:!0,children:m}),a.jsx(Bs,{side:"right",align:"center",hidden:u!=="collapsed"||d,...o})]})):m});Ws.displayName="SidebarMenuButton";const Qc=g.forwardRef(({className:e,asChild:t=!1,showOnHover:n=!1,...r},o)=>{const s=t?Ht.Slot:"button";return a.jsx(s,{ref:o,"data-sidebar":"menu-action",className:N("tw-peer-hover/menu-button:text-sidebar-accent-foreground tw-absolute tw-right-1 tw-top-1.5 tw-flex tw-aspect-square tw-w-5 tw-items-center tw-justify-center tw-rounded-md tw-p-0 tw-text-sidebar-foreground tw-outline-none tw-ring-sidebar-ring tw-transition-transform hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground focus-visible:tw-ring-2 [&>svg]:tw-size-4 [&>svg]:tw-shrink-0","after:tw-absolute after:tw--inset-2 after:md:tw-hidden","tw-peer-data-[size=sm]/menu-button:top-1","tw-peer-data-[size=default]/menu-button:top-1.5","tw-peer-data-[size=lg]/menu-button:top-2.5","group-data-[collapsible=icon]:tw-hidden",n&&"tw-group-focus-within/menu-item:opacity-100 tw-group-hover/menu-item:opacity-100 tw-peer-data-[active=true]/menu-button:text-sidebar-accent-foreground data-[state=open]:tw-opacity-100 md:tw-opacity-0",e),...r})});Qc.displayName="SidebarMenuAction";const ed=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,"data-sidebar":"menu-badge",className:N("tw-pointer-events-none tw-absolute tw-right-1 tw-flex tw-h-5 tw-min-w-5 tw-select-none tw-items-center tw-justify-center tw-rounded-md tw-px-1 tw-text-xs tw-font-medium tw-tabular-nums tw-text-sidebar-foreground","tw-peer-hover/menu-button:text-sidebar-accent-foreground tw-peer-data-[active=true]/menu-button:text-sidebar-accent-foreground","tw-peer-data-[size=sm]/menu-button:top-1","tw-peer-data-[size=default]/menu-button:top-1.5","tw-peer-data-[size=lg]/menu-button:top-2.5","group-data-[collapsible=icon]:tw-hidden",e),...t}));ed.displayName="SidebarMenuBadge";const td=g.forwardRef(({className:e,showIcon:t=!1,...n},r)=>{const o=g.useMemo(()=>`${Math.floor(Math.random()*40)+50}%`,[]);return a.jsxs("div",{ref:r,"data-sidebar":"menu-skeleton",className:N("tw-flex tw-h-8 tw-items-center tw-gap-2 tw-rounded-md tw-px-2",e),...n,children:[t&&a.jsx(sa,{className:"tw-size-4 tw-rounded-md","data-sidebar":"menu-skeleton-icon"}),a.jsx(sa,{className:"tw-h-4 tw-max-w-[--skeleton-width] tw-flex-1","data-sidebar":"menu-skeleton-text",style:{"--skeleton-width":o}})]})});td.displayName="SidebarMenuSkeleton";const nd=g.forwardRef(({className:e,...t},n)=>a.jsx("ul",{ref:n,"data-sidebar":"menu-sub",className:N("tw-mx-3.5 tw-flex tw-min-w-0 tw-translate-x-px tw-flex-col tw-gap-1 tw-border-l tw-border-sidebar-border tw-px-2.5 tw-py-0.5","group-data-[collapsible=icon]:tw-hidden",e),...t}));nd.displayName="SidebarMenuSub";const rd=g.forwardRef(({...e},t)=>a.jsx("li",{ref:t,...e}));rd.displayName="SidebarMenuSubItem";const od=g.forwardRef(({asChild:e=!1,size:t="md",isActive:n,className:r,...o},s)=>{const i=e?Ht.Slot:"a";return a.jsx(i,{ref:s,"data-sidebar":"menu-sub-button","data-size":t,"data-active":n,className:N("tw-flex tw-h-7 tw-min-w-0 tw--translate-x-px tw-items-center tw-gap-2 tw-overflow-hidden tw-rounded-md tw-px-2 tw-text-sidebar-foreground tw-outline-none tw-ring-sidebar-ring hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground focus-visible:tw-ring-2 active:tw-bg-sidebar-accent active:tw-text-sidebar-accent-foreground disabled:tw-pointer-events-none disabled:tw-opacity-50 aria-disabled:tw-pointer-events-none aria-disabled:tw-opacity-50 [&>span:last-child]:tw-truncate [&>svg]:tw-size-4 [&>svg]:tw-shrink-0 [&>svg]:tw-text-sidebar-accent-foreground","data-[active=true]:tw-bg-sidebar-accent data-[active=true]:tw-text-sidebar-accent-foreground",t==="sm"&&"tw-text-xs",t==="md"&&"tw-text-sm","group-data-[collapsible=icon]:tw-hidden",r),...o})});od.displayName="SidebarMenuSubButton";function Ks({id:e,extensionLabels:t,handleSelectSidebarItem:n}){const[r,o]=g.useState(),s=(i,l)=>{o(i),n(i,l)};return a.jsx(Ls,{id:e,collapsible:"offcanvas",variant:"sidebar",children:a.jsx(Gs,{children:a.jsxs(Us,{children:[a.jsx(qs,{children:"Extensions"}),a.jsx(Hs,{children:a.jsx(Xs,{children:t.map(i=>a.jsx(Ys,{children:a.jsx(Ws,{onClick:()=>s(i,!1),isActive:i===r,children:i})},i))})})]})})})}function ad({direction:e="ltr",extensionLabels:t,children:n,handleSelectSidebarItem:r}){return a.jsxs(zs,{dir:e,children:[a.jsx(Ks,{extensionLabels:t,handleSelectSidebarItem:r}),a.jsx(Fs,{children:n})]})}const rt="scrBook",sd="scrRef",pt="source",id="details",ld="Scripture Reference",cd="Scripture Book",Js="Type",dd="Details";function ud(e,t){const n=t??!1;return[{accessorFn:r=>`${ae.bookNumberToId(r.start.bookNum)} ${r.start.chapterNum}:${r.start.verseNum}`,id:rt,header:(e==null?void 0:e.scriptureReferenceColumnName)??ld,cell:r=>{const o=r.row.original;return r.row.getIsGrouped()?ae.bookNumberToEnglishName(o.start.bookNum):r.row.groupingColumnId===rt?W.formatScrRef(o.start):void 0},getGroupingValue:r=>r.start.bookNum,sortingFn:(r,o)=>W.compareScrRefs(r.original.start,o.original.start),enableGrouping:!0},{accessorFn:r=>W.formatScrRef(r.start),id:sd,header:void 0,cell:r=>{const o=r.row.original;return r.row.getIsGrouped()?void 0:W.formatScrRef(o.start)},sortingFn:(r,o)=>W.compareScrRefs(r.original.start,o.original.start),enableGrouping:!1},{accessorFn:r=>r.source.displayName,id:pt,header:n?(e==null?void 0:e.typeColumnName)??Js:void 0,cell:r=>n||r.row.getIsGrouped()?r.getValue():void 0,getGroupingValue:r=>r.source.id,sortingFn:(r,o)=>r.original.source.displayName.localeCompare(o.original.source.displayName),enableGrouping:!0},{accessorFn:r=>r.detail,id,header:(e==null?void 0:e.detailsColumnName)??dd,cell:r=>r.getValue(),enableGrouping:!1}]}const pd=e=>{if(!("offset"in e.start))throw new Error("No offset available in range start");if(e.end&&!("offset"in e.end))throw new Error("No offset available in range end");const{offset:t}=e.start;let n=0;return e.end&&({offset:n}=e.end),!e.end||W.compareScrRefs(e.start,e.end)===0?`${W.scrRefToBBBCCCVVV(e.start)}+${t}`:`${W.scrRefToBBBCCCVVV(e.start)}+${t}-${W.scrRefToBBBCCCVVV(e.end)}+${n}`},ia=e=>`${pd({start:e.start,end:e.end})} ${e.source.displayName} ${e.detail}`;function wd({sources:e,showColumnHeaders:t=!1,showSourceColumn:n=!1,scriptureReferenceColumnName:r,scriptureBookGroupName:o,typeColumnName:s,detailsColumnName:i,onRowSelected:l,direction:c="ltr"}){const[d,u]=g.useState([]),[m,w]=g.useState([{id:rt,desc:!1}]),[b,x]=g.useState({}),f=g.useMemo(()=>e.flatMap(T=>T.data.map(_=>({..._,source:T.source}))),[e]),h=g.useMemo(()=>ud({scriptureReferenceColumnName:r,typeColumnName:s,detailsColumnName:i},n),[r,s,i,n]);g.useEffect(()=>{d.includes(pt)?w([{id:pt,desc:!1},{id:rt,desc:!1}]):w([{id:rt,desc:!1}])},[d]);const S=Se.useReactTable({data:f,columns:h,state:{grouping:d,sorting:m,rowSelection:b},onGroupingChange:u,onSortingChange:w,onRowSelectionChange:x,getExpandedRowModel:Se.getExpandedRowModel(),getGroupedRowModel:Se.getGroupedRowModel(),getCoreRowModel:Se.getCoreRowModel(),getSortedRowModel:Se.getSortedRowModel(),getRowId:ia,autoResetExpanded:!1,enableMultiRowSelection:!1,enableSubRowSelection:!1});g.useEffect(()=>{if(l){const T=S.getSelectedRowModel().rowsById,_=Object.keys(T);if(_.length===1){const k=f.find(D=>ia(D)===_[0])||void 0;k&&l(k)}}},[b,f,l,S]);const R=o??cd,j=s??Js,E=[{label:"No Grouping",value:[]},{label:`Group by ${R}`,value:[rt]},{label:`Group by ${j}`,value:[pt]},{label:`Group by ${R} and ${j}`,value:[rt,pt]},{label:`Group by ${j} and ${R}`,value:[pt,rt]}],v=T=>{u(JSON.parse(T))},P=(T,_)=>{!T.getIsGrouped()&&!T.getIsSelected()&&T.getToggleSelectedHandler()(_)},V=(T,_)=>T.getIsGrouped()?"":N("banded-row",_%2===0?"even":"odd"),U=(T,_,k)=>{if(!((T==null?void 0:T.length)===0||_.depth{v(T)},children:[a.jsx(bt,{className:"tw-mb-1 tw-mt-2",children:a.jsx(Bt,{})}),a.jsx(vt,{position:"item-aligned",children:a.jsx(ks,{children:E.map(T=>a.jsx(Ae,{value:JSON.stringify(T.value),children:T.label},T.label))})})]}),a.jsxs(Tn,{className:"tw-relative tw-flex tw-flex-col tw-overflow-y-auto tw-p-0",children:[t&&a.jsx(Cn,{children:S.getHeaderGroups().map(T=>a.jsx(Ze,{children:T.headers.filter(_=>_.column.columnDef.header).map(_=>a.jsx(Vt,{colSpan:_.colSpan,className:"top-0 tw-sticky",children:_.isPlaceholder?void 0:a.jsxs("div",{children:[_.column.getCanGroup()?a.jsx(fe,{variant:"ghost",title:`Toggle grouping by ${_.column.columnDef.header}`,onClick:_.column.getToggleGroupingHandler(),type:"button",children:_.column.getIsGrouped()?"🛑":"👊 "}):void 0," ",Se.flexRender(_.column.columnDef.header,_.getContext())]})},_.id))},T.id))}),a.jsx(Rn,{children:S.getRowModel().rows.map((T,_)=>a.jsx(Ze,{"data-state":T.getIsSelected()?"selected":"",className:N(V(T,_)),onClick:k=>P(T,k),children:T.getVisibleCells().map(k=>{if(!(k.getIsPlaceholder()||k.column.columnDef.enableGrouping&&!k.getIsGrouped()&&(k.column.columnDef.id!==pt||!n)))return a.jsx(xt,{className:N(k.column.columnDef.id,"tw-p-[1px]",U(d,T,k)),children:(()=>k.getIsGrouped()?a.jsxs(fe,{variant:"link",onClick:T.getToggleExpandedHandler(),type:"button",children:[T.getIsExpanded()&&a.jsx(Q.ChevronDown,{}),!T.getIsExpanded()&&(c==="ltr"?a.jsx(Q.ChevronRight,{}):a.jsx(Q.ChevronLeft,{}))," ",Se.flexRender(k.column.columnDef.cell,k.getContext())," (",T.subRows.length,")"]}):Se.flexRender(k.column.columnDef.cell,k.getContext()))()},k.id)})},T.id))})]})]})}const Or={[W.getLocalizeKeyForScrollGroupId("undefined")]:"Ø",[W.getLocalizeKeyForScrollGroupId(0)]:"A",[W.getLocalizeKeyForScrollGroupId(1)]:"B",[W.getLocalizeKeyForScrollGroupId(2)]:"C",[W.getLocalizeKeyForScrollGroupId(3)]:"D",[W.getLocalizeKeyForScrollGroupId(4)]:"E",[W.getLocalizeKeyForScrollGroupId(5)]:"F",[W.getLocalizeKeyForScrollGroupId(6)]:"G",[W.getLocalizeKeyForScrollGroupId(7)]:"H",[W.getLocalizeKeyForScrollGroupId(8)]:"I",[W.getLocalizeKeyForScrollGroupId(9)]:"J",[W.getLocalizeKeyForScrollGroupId(10)]:"K",[W.getLocalizeKeyForScrollGroupId(11)]:"L",[W.getLocalizeKeyForScrollGroupId(12)]:"M",[W.getLocalizeKeyForScrollGroupId(13)]:"N",[W.getLocalizeKeyForScrollGroupId(14)]:"O",[W.getLocalizeKeyForScrollGroupId(15)]:"P",[W.getLocalizeKeyForScrollGroupId(16)]:"Q",[W.getLocalizeKeyForScrollGroupId(17)]:"R",[W.getLocalizeKeyForScrollGroupId(18)]:"S",[W.getLocalizeKeyForScrollGroupId(19)]:"T",[W.getLocalizeKeyForScrollGroupId(20)]:"U",[W.getLocalizeKeyForScrollGroupId(21)]:"V",[W.getLocalizeKeyForScrollGroupId(22)]:"W",[W.getLocalizeKeyForScrollGroupId(23)]:"X",[W.getLocalizeKeyForScrollGroupId(24)]:"Y",[W.getLocalizeKeyForScrollGroupId(25)]:"Z"};function fd({availableScrollGroupIds:e,scrollGroupId:t,onChangeScrollGroupId:n,localizedStrings:r={}}){const o={...Or,...Object.fromEntries(Object.entries(r).map(([s,i])=>[s,s===i&&s in Or?Or[s]:i]))};return a.jsxs(At,{value:`${t}`,onValueChange:s=>n(s==="undefined"?void 0:parseInt(s,10)),children:[a.jsx(bt,{className:"pr-twp tw-w-auto",children:a.jsx(Bt,{placeholder:o[W.getLocalizeKeyForScrollGroupId(t)]??t})}),a.jsx(vt,{style:{zIndex:250},children:e.map(s=>a.jsx(Ae,{value:`${s}`,children:o[W.getLocalizeKeyForScrollGroupId(s)]},`${s}`))})]})}function md({children:e}){return a.jsx("div",{className:"pr-twp tw-grid",children:e})}function hd({primary:e,secondary:t,children:n,isLoading:r=!1,loadingMessage:o}){return a.jsxs("div",{className:"tw-flex tw-items-center tw-justify-between tw-space-x-4 tw-py-2",children:[a.jsxs("div",{children:[a.jsx("p",{className:"tw-text-sm tw-font-medium tw-leading-none",children:e}),a.jsx("p",{className:"tw-whitespace-normal tw-break-words tw-text-sm tw-text-muted-foreground",children:t})]}),r?a.jsx("p",{className:"tw-text-sm tw-text-muted-foreground",children:o}):a.jsx("div",{children:n})]})}function gd({primary:e,secondary:t,includeSeparator:n=!1}){return a.jsxs("div",{className:"tw-space-y-4 tw-py-2",children:[a.jsxs("div",{children:[a.jsx("h3",{className:"tw-text-lg tw-font-medium",children:e}),a.jsx("p",{className:"tw-text-sm tw-text-muted-foreground",children:t})]}),n?a.jsx(ir,{}):""]})}const ho=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,className:N("pr-twp tw-rounded-lg tw-border tw-bg-card tw-text-card-foreground tw-shadow-sm",e),...t}));ho.displayName="Card";const go=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,className:N("pr-twp tw-flex tw-flex-col tw-space-y-1.5 tw-p-6",e),...t}));go.displayName="CardHeader";const bo=g.forwardRef(({className:e,...t},n)=>a.jsx("h3",{ref:n,className:N("pr-twp tw-text-2xl tw-font-semibold tw-leading-none tw-tracking-tight",e),...t,children:t.children}));bo.displayName="CardTitle";const vo=g.forwardRef(({className:e,...t},n)=>a.jsx("p",{ref:n,className:N("pr-twp tw-text-sm tw-text-muted-foreground",e),...t}));vo.displayName="CardDescription";const Zs=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,className:N("pr-twp tw-p-6 tw-pt-0",e),...t}));Zs.displayName="CardContent";const Qs=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,className:N("pr-twp tw-flex tw-items-center tw-p-6 tw-pt-0",e),...t}));Qs.displayName="CardFooter";function bd({settingsGroupLabel:e,settingsGroupDescription:t,children:n}){return a.jsxs(ho,{children:[a.jsxs(go,{children:[a.jsx(bo,{children:e}),a.jsx(vo,{children:t})]}),a.jsx(Te.CardContent,{className:"tw-space-y-4",children:n})]})}function vd({id:e,className:t,listItems:n,selectedListItems:r,handleSelectListItem:o,createLabel:s}){return a.jsx("div",{id:e,className:t,children:n.map(i=>a.jsxs("div",{className:"tw-m-2 tw-flex tw-items-center",children:[a.jsx(ar,{className:"tw-mr-2 tw-align-middle",checked:r.includes(i),onCheckedChange:l=>o(i,l)}),a.jsx(qe,{children:s?s(i):i})]},i))})}function xd(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}function yd(e){if(e.__esModule)return e;var t=e.default;if(typeof t=="function"){var n=function r(){return this instanceof r?Reflect.construct(t,arguments,this.constructor):t.apply(this,arguments)};n.prototype=t.prototype}else n={};return Object.defineProperty(n,"__esModule",{value:!0}),Object.keys(e).forEach(function(r){var o=Object.getOwnPropertyDescriptor(e,r);Object.defineProperty(n,r,o.get?o:{enumerable:!0,get:function(){return e[r]}})}),n}var xo={},ei={exports:{}};(function(e){function t(n){return n&&n.__esModule?n:{default:n}}e.exports=t,e.exports.__esModule=!0,e.exports.default=e.exports})(ei);var Nd=ei.exports,_r={};function yo(e,t){return process.env.NODE_ENV==="production"?()=>null:function(...r){return e(...r)||t(...r)}}function O(){return O=Object.assign?Object.assign.bind():function(e){for(var t=1;t{t[n]=ti(e[n])}),t}function Qe(e,t,n={clone:!0}){const r=n.clone?O({},e):e;return mt(e)&&mt(t)&&Object.keys(t).forEach(o=>{o!=="__proto__"&&(mt(t[o])&&o in e&&mt(e[o])?r[o]=Qe(e[o],t[o],n):n.clone?r[o]=mt(t[o])?ti(t[o]):t[o]:r[o]=t[o])}),r}var Xr={exports:{}},zn={exports:{}},ie={};/** @license React v16.13.1 +"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const a=require("react/jsx-runtime"),g=require("react"),Q=require("lucide-react"),ot=require("clsx"),ml=require("tailwind-merge"),ts=require("@radix-ui/react-dropdown-menu"),W=require("platform-bible-utils"),Ht=require("@radix-ui/react-slot"),Xt=require("class-variance-authority"),hl=require("@radix-ui/react-label"),gl=require("@radix-ui/react-radio-group"),bl=require("@radix-ui/react-popover"),Oe=require("cmdk"),vl=require("@radix-ui/react-dialog"),Se=require("@tanstack/react-table"),xl=require("@radix-ui/react-select"),yl=require("@radix-ui/react-checkbox"),Nl=require("@radix-ui/react-toggle-group"),kl=require("@radix-ui/react-toggle"),Sl=require("@radix-ui/react-tabs"),El=require("@radix-ui/react-separator"),jl=require("@radix-ui/react-tooltip"),Ce=require("@mui/material"),Gr=require("@mui/styled-engine"),ln=require("react-dom"),ns=require("sonner"),Cl=require("@radix-ui/react-slider"),Tl=require("@radix-ui/react-switch"),Rl=require("markdown-to-jsx");function ke(e){const t=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(e){for(const n in e)if(n!=="default"){const r=Object.getOwnPropertyDescriptor(e,n);Object.defineProperty(t,n,r.get?r:{enumerable:!0,get:()=>e[n]})}}return t.default=e,Object.freeze(t)}const M=ke(g),pe=ke(ts),rs=ke(hl),bn=ke(gl),vn=ke(bl),be=ke(vl),ge=ke(xl),Ur=ke(yl),rr=ke(Nl),os=ke(kl),_e=ke(Sl),as=ke(El),Sn=ke(jl),Ol=ke(ln),cn=ke(Cl),qr=ke(Tl);const _l=ml.extendTailwindMerge({prefix:"tw-"});function N(...e){return _l(ot.clsx(e))}const St=g.forwardRef(({className:e,type:t,...n},r)=>a.jsx("input",{type:t,className:N("pr-twp tw-flex tw-h-10 tw-rounded-md tw-border tw-border-input tw-bg-background tw-px-3 tw-py-2 tw-text-sm tw-ring-offset-background file:tw-border-0 file:tw-bg-transparent file:tw-text-sm file:tw-font-medium file:tw-text-foreground placeholder:tw-text-muted-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-cursor-not-allowed disabled:tw-opacity-50",e),ref:r,...n}));St.displayName="Input";const Pl=g.forwardRef(({handleSearch:e,handleKeyDown:t,handleOnClick:n,handleSubmit:r,...o},s)=>a.jsxs("div",{className:"tw-relative",children:[a.jsx(St,{...o,type:"text",className:"tw-box-border tw-gap-2.5 tw-rounded-lg tw-border tw-border-solid tw-bg-background tw-py-2 tw-pl-4 tw-pr-3 tw-font-medium tw-shadow-none tw-outline-none",onChange:i=>e(i.target.value),onKeyDown:i=>{i.key==="Enter"&&r(),t(i)},onClick:n,ref:s}),a.jsx(Q.History,{className:"tw-absolute tw-right-3 tw-top-1/2 tw-h-4 tw-w-4 tw--translate-y-1/2 tw-transform tw-cursor-pointer tw-text-muted-foreground",onClick:()=>{console.log("back in history")}})]}));var Il=Object.defineProperty,Ml=(e,t,n)=>t in e?Il(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,ne=(e,t,n)=>Ml(e,typeof t!="symbol"?t+"":t,n);const gt=["GEN","EXO","LEV","NUM","DEU","JOS","JDG","RUT","1SA","2SA","1KI","2KI","1CH","2CH","EZR","NEH","EST","JOB","PSA","PRO","ECC","SNG","ISA","JER","LAM","EZK","DAN","HOS","JOL","AMO","OBA","JON","MIC","NAM","HAB","ZEP","HAG","ZEC","MAL","MAT","MRK","LUK","JHN","ACT","ROM","1CO","2CO","GAL","EPH","PHP","COL","1TH","2TH","1TI","2TI","TIT","PHM","HEB","JAS","1PE","2PE","1JN","2JN","3JN","JUD","REV","TOB","JDT","ESG","WIS","SIR","BAR","LJE","S3Y","SUS","BEL","1MA","2MA","3MA","4MA","1ES","2ES","MAN","PS2","ODA","PSS","JSA","JDB","TBS","SST","DNT","BLT","XXA","XXB","XXC","XXD","XXE","XXF","XXG","FRT","BAK","OTH","3ES","EZA","5EZ","6EZ","INT","CNC","GLO","TDX","NDX","DAG","PS3","2BA","LBA","JUB","ENO","1MQ","2MQ","3MQ","REP","4BA","LAO"],ao=["XXA","XXB","XXC","XXD","XXE","XXF","XXG","FRT","BAK","OTH","INT","CNC","GLO","TDX","NDX"],ss=["Genesis","Exodus","Leviticus","Numbers","Deuteronomy","Joshua","Judges","Ruth","1 Samuel","2 Samuel","1 Kings","2 Kings","1 Chronicles","2 Chronicles","Ezra","Nehemiah","Esther (Hebrew)","Job","Psalms","Proverbs","Ecclesiastes","Song of Songs","Isaiah","Jeremiah","Lamentations","Ezekiel","Daniel (Hebrew)","Hosea","Joel","Amos","Obadiah","Jonah","Micah","Nahum","Habakkuk","Zephaniah","Haggai","Zechariah","Malachi","Matthew","Mark","Luke","John","Acts","Romans","1 Corinthians","2 Corinthians","Galatians","Ephesians","Philippians","Colossians","1 Thessalonians","2 Thessalonians","1 Timothy","2 Timothy","Titus","Philemon","Hebrews","James","1 Peter","2 Peter","1 John","2 John","3 John","Jude","Revelation","Tobit","Judith","Esther Greek","Wisdom of Solomon","Sirach (Ecclesiasticus)","Baruch","Letter of Jeremiah","Song of 3 Young Men","Susanna","Bel and the Dragon","1 Maccabees","2 Maccabees","3 Maccabees","4 Maccabees","1 Esdras (Greek)","2 Esdras (Latin)","Prayer of Manasseh","Psalm 151","Odes","Psalms of Solomon","Joshua A. *obsolete*","Judges B. *obsolete*","Tobit S. *obsolete*","Susanna Th. *obsolete*","Daniel Th. *obsolete*","Bel Th. *obsolete*","Extra A","Extra B","Extra C","Extra D","Extra E","Extra F","Extra G","Front Matter","Back Matter","Other Matter","3 Ezra *obsolete*","Apocalypse of Ezra","5 Ezra (Latin Prologue)","6 Ezra (Latin Epilogue)","Introduction","Concordance ","Glossary ","Topical Index","Names Index","Daniel Greek","Psalms 152-155","2 Baruch (Apocalypse)","Letter of Baruch","Jubilees","Enoch","1 Meqabyan","2 Meqabyan","3 Meqabyan","Reproof (Proverbs 25-31)","4 Baruch (Rest of Baruch)","Laodiceans"],sa=Ul();function Yt(e,t=!0){return t&&(e=e.toUpperCase()),e in sa?sa[e]:0}function so(e){return Yt(e)>0}function $l(e){const t=typeof e=="string"?Yt(e):e;return t>=40&&t<=66}function Dl(e){return(typeof e=="string"?Yt(e):e)<=39}function is(e){return e<=66}function Al(e){const t=typeof e=="string"?Yt(e):e;return ds(t)&&!is(t)}function*Bl(){for(let e=1;e<=gt.length;e++)yield e}const Vl=1,ls=gt.length;function zl(){return["XXA","XXB","XXC","XXD","XXE","XXF","XXG"]}function io(e,t="***"){const n=e-1;return n<0||n>=gt.length?t:gt[n]}function cs(e){return e<=0||e>ls?"******":ss[e-1]}function Ll(e){return cs(Yt(e))}function ds(e){const t=typeof e=="number"?io(e):e;return so(t)&&!ao.includes(t)}function Fl(e){const t=typeof e=="number"?io(e):e;return so(t)&&ao.includes(t)}function Gl(e){return ss[e-1].includes("*obsolete*")}function Ul(){const e={};for(let t=0;t(e[e.Unknown=0]="Unknown",e[e.Original=1]="Original",e[e.Septuagint=2]="Septuagint",e[e.Vulgate=3]="Vulgate",e[e.English=4]="English",e[e.RussianProtestant=5]="RussianProtestant",e[e.RussianOrthodox=6]="RussianOrthodox",e))(He||{});const Ie=class{constructor(t){if(ne(this,"name"),ne(this,"fullPath"),ne(this,"isPresent"),ne(this,"hasVerseSegments"),ne(this,"isCustomized"),ne(this,"baseVersification"),ne(this,"scriptureBooks"),ne(this,"_type"),t==null)throw new Error("Argument undefined");typeof t=="string"?(this.name=t,this._type=He[t]):(this._type=t,this.name=He[t])}get type(){return this._type}equals(t){return!t.type||!this.type?!1:t.type===this.type}};ne(Ie,"Original",new Ie(He.Original)),ne(Ie,"Septuagint",new Ie(He.Septuagint)),ne(Ie,"Vulgate",new Ie(He.Vulgate)),ne(Ie,"English",new Ie(He.English)),ne(Ie,"RussianProtestant",new Ie(He.RussianProtestant)),ne(Ie,"RussianOrthodox",new Ie(He.RussianOrthodox));let ut=Ie;function ia(e,t){const n=t[0];for(let r=1;r(e[e.Valid=0]="Valid",e[e.UnknownVersification=1]="UnknownVersification",e[e.OutOfRange=2]="OutOfRange",e[e.VerseOutOfOrder=3]="VerseOutOfOrder",e[e.VerseRepeated=4]="VerseRepeated",e))(us||{});const je=class re{constructor(t,n,r,o){if(ne(this,"firstChapter"),ne(this,"lastChapter"),ne(this,"lastVerse"),ne(this,"hasSegmentsDefined"),ne(this,"text"),ne(this,"BBBCCCVVVS"),ne(this,"longHashCode"),ne(this,"versification"),ne(this,"rtlMark","‏"),ne(this,"_bookNum",0),ne(this,"_chapterNum",0),ne(this,"_verseNum",0),ne(this,"_verse"),r==null&&o==null)if(t!=null&&typeof t=="string"){const s=t,i=n!=null&&n instanceof ut?n:void 0;this.setEmpty(i),this.parse(s)}else if(t!=null&&typeof t=="number"){const s=n!=null&&n instanceof ut?n:void 0;this.setEmpty(s),this._verseNum=t%re.chapterDigitShifter,this._chapterNum=Math.floor(t%re.bookDigitShifter/re.chapterDigitShifter),this._bookNum=Math.floor(t/re.bookDigitShifter)}else if(n==null)if(t!=null&&t instanceof re){const s=t;this._bookNum=s.bookNum,this._chapterNum=s.chapterNum,this._verseNum=s.verseNum,this._verse=s.verse,this.versification=s.versification}else{if(t==null)return;const s=t instanceof ut?t:re.defaultVersification;this.setEmpty(s)}else throw new Error("VerseRef constructor not supported.");else if(t!=null&&n!=null&&r!=null)if(typeof t=="string"&&typeof n=="string"&&typeof r=="string")this.setEmpty(o),this.updateInternal(t,n,r);else if(typeof t=="number"&&typeof n=="number"&&typeof r=="number")this._bookNum=t,this._chapterNum=n,this._verseNum=r,this.versification=o??re.defaultVersification;else throw new Error("VerseRef constructor not supported.");else throw new Error("VerseRef constructor not supported.")}static isVerseParseable(t){return t.length>0&&"0123456789".includes(t[0])&&!t.endsWith(this.verseRangeSeparator)&&!t.endsWith(this.verseSequenceIndicator)}static tryParse(t){let n;try{return n=new re(t),{success:!0,verseRef:n}}catch(r){if(r instanceof nn)return n=new re,{success:!1,verseRef:n};throw r}}static getBBBCCCVVV(t,n,r){return t%re.bcvMaxValue*re.bookDigitShifter+(n>=0?n%re.bcvMaxValue*re.chapterDigitShifter:0)+(r>=0?r%re.bcvMaxValue:0)}static fromJSON(t){const{book:n,chapterNum:r,verseNum:o,verse:s,versificationStr:i}=t,l=s||o.toString();let c;return i&&(c=new ut(i)),n?new re(n,r.toString(),l,c):new re}static tryGetVerseNum(t){let n;if(!t)return n=-1,{success:!0,vNum:n};n=0;let r;for(let o=0;o"9")return o===0&&(n=-1),{success:!1,vNum:n};if(n=n*10+ +r-0,n>re.bcvMaxValue)return n=-1,{success:!1,vNum:n}}return{success:!0,vNum:n}}get isDefault(){return this.bookNum===0&&this.chapterNum===0&&this.verseNum===0&&this.versification==null}get hasMultiple(){return this._verse!=null&&(this._verse.includes(re.verseRangeSeparator)||this._verse.includes(re.verseSequenceIndicator))}get book(){return ae.bookNumberToId(this.bookNum,"")}set book(t){this.bookNum=ae.bookIdToNumber(t)}get chapter(){return this.isDefault||this._chapterNum<0?"":this._chapterNum.toString()}set chapter(t){const n=+t;this._chapterNum=Number.isInteger(n)?n:-1}get verse(){return this._verse!=null?this._verse:this.isDefault||this._verseNum<0?"":this._verseNum.toString()}set verse(t){const{success:n,vNum:r}=re.tryGetVerseNum(t);this._verse=n?void 0:t.replace(this.rtlMark,""),this._verseNum=r,!(this._verseNum>=0)&&({vNum:this._verseNum}=re.tryGetVerseNum(this._verse))}get bookNum(){return this._bookNum}set bookNum(t){if(t<=0||t>ae.lastBook)throw new nn("BookNum must be greater than zero and less than or equal to last book");this._bookNum=t}get chapterNum(){return this._chapterNum}set chapterNum(t){this.chapterNum=t}get verseNum(){return this._verseNum}set verseNum(t){this._verseNum=t}get versificationStr(){var t;return(t=this.versification)==null?void 0:t.name}set versificationStr(t){this.versification=this.versification!=null?new ut(t):void 0}get valid(){return this.validStatus===0}get validStatus(){return this.validateVerse(re.verseRangeSeparators,re.verseSequenceIndicators)}get BBBCCC(){return re.getBBBCCCVVV(this._bookNum,this._chapterNum,0)}get BBBCCCVVV(){return re.getBBBCCCVVV(this._bookNum,this._chapterNum,this._verseNum)}get isExcluded(){return!1}parse(t){if(t=t.replace(this.rtlMark,""),t.includes("/")){const s=t.split("/");if(t=s[0],s.length>1)try{const i=+s[1].trim();this.versification=new ut(He[i])}catch{throw new nn("Invalid reference : "+t)}}const n=t.trim().split(" ");if(n.length!==2)throw new nn("Invalid reference : "+t);const r=n[1].split(":"),o=+r[0];if(r.length!==2||ae.bookIdToNumber(n[0])===0||!Number.isInteger(o)||o<0||!re.isVerseParseable(r[1]))throw new nn("Invalid reference : "+t);this.updateInternal(n[0],r[0],r[1])}simplify(){this._verse=void 0}clone(){return new re(this)}toString(){const t=this.book;return t===""?"":`${t} ${this.chapter}:${this.verse}`}toJSON(){let t=this.verse;(t===""||t===this.verseNum.toString())&&(t=void 0);const n={book:this.book,chapterNum:this.chapterNum,verseNum:this.verseNum,verse:t,versificationStr:this.versificationStr};return t||delete n.verse,n}equals(t){return t instanceof re?t._bookNum===this._bookNum&&t._chapterNum===this._chapterNum&&t._verseNum===this._verseNum&&t.verse===this.verse&&(t.versification==null&&this.versification==null||t.versification!=null&&this.versification!=null&&t.versification.equals(this.versification)):!1}allVerses(t=!1,n=re.verseRangeSeparators,r=re.verseSequenceIndicators){if(this._verse==null||this.chapterNum<=0)return[this.clone()];const o=[],s=ia(this._verse,r);for(const i of s.map(l=>ia(l,n))){const l=this.clone();l.verse=i[0];const c=l.verseNum;if(o.push(l),i.length>1){const d=this.clone();if(d.verse=i[1],!t)for(let u=c+1;ui)return 3;if(r===i)return 4;r=i}return 0}get internalValid(){return this.versification==null?1:this._bookNum<=0||this._bookNum>ae.lastBook?2:(ae.isCanonical(this._bookNum),0)}setEmpty(t=re.defaultVersification){this._bookNum=0,this._chapterNum=-1,this._verse=void 0,this.versification=t}updateInternal(t,n,r){this.bookNum=ae.bookIdToNumber(t),this.chapter=n,this.verse=r}};ne(je,"defaultVersification",ut.English),ne(je,"verseRangeSeparator","-"),ne(je,"verseSequenceIndicator",","),ne(je,"verseRangeSeparators",[je.verseRangeSeparator]),ne(je,"verseSequenceIndicators",[je.verseSequenceIndicator]),ne(je,"chapterDigitShifter",1e3),ne(je,"bookDigitShifter",je.chapterDigitShifter*je.chapterDigitShifter),ne(je,"bcvMaxValue",je.chapterDigitShifter-1),ne(je,"ValidStatusType",us);class nn extends Error{}const or=pe.Root,lo=pe.Trigger,ps=pe.Group,ql=pe.Portal,Hl=pe.Sub,Xl=pe.RadioGroup,ws=g.forwardRef(({className:e,inset:t,children:n,...r},o)=>a.jsxs(pe.SubTrigger,{ref:o,className:N("tw-flex tw-cursor-default tw-select-none tw-items-center tw-rounded-sm tw-px-2 tw-py-1.5 tw-text-sm tw-outline-none focus:tw-bg-accent data-[state=open]:tw-bg-accent",t&&"tw-pl-8",e),...r,children:[n,a.jsx(Q.ChevronRight,{className:"tw-ml-auto tw-h-4 tw-w-4"})]}));ws.displayName=pe.SubTrigger.displayName;const fs=g.forwardRef(({className:e,...t},n)=>a.jsx(pe.SubContent,{ref:n,className:N("tw-z-50 tw-min-w-[8rem] tw-overflow-hidden tw-rounded-md tw-border tw-bg-popover tw-p-1 tw-text-popover-foreground tw-shadow-lg data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0 data-[state=closed]:tw-zoom-out-95 data-[state=open]:tw-zoom-in-95 data-[side=bottom]:tw-slide-in-from-top-2 data-[side=left]:tw-slide-in-from-right-2 data-[side=right]:tw-slide-in-from-left-2 data-[side=top]:tw-slide-in-from-bottom-2",e),...t}));fs.displayName=pe.SubContent.displayName;const En=g.forwardRef(({className:e,sideOffset:t=4,...n},r)=>a.jsx(pe.Portal,{children:a.jsx(pe.Content,{ref:r,sideOffset:t,className:N("pr-twp tw-z-50 tw-min-w-[8rem] tw-overflow-hidden tw-rounded-md tw-border tw-bg-popover tw-p-1 tw-text-popover-foreground tw-shadow-md data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0 data-[state=closed]:tw-zoom-out-95 data-[state=open]:tw-zoom-in-95 data-[side=bottom]:tw-slide-in-from-top-2 data-[side=left]:tw-slide-in-from-right-2 data-[side=right]:tw-slide-in-from-left-2 data-[side=top]:tw-slide-in-from-bottom-2",e),...n})}));En.displayName=pe.Content.displayName;const co=g.forwardRef(({className:e,inset:t,...n},r)=>a.jsx(pe.Item,{ref:r,className:N("tw-cursor-default tw-select-none tw-items-center tw-rounded-sm tw-px-2 tw-py-1.5 tw-text-sm tw-outline-none tw-transition-colors focus:tw-bg-accent data-[disabled]:tw-pointer-events-none data-[disabled]:tw-opacity-50",t&&"tw-pl-8",e),...n}));co.displayName=pe.Item.displayName;const ar=g.forwardRef(({className:e,children:t,checked:n,...r},o)=>a.jsxs(pe.CheckboxItem,{ref:o,className:N("tw-relative tw-flex tw-cursor-default tw-select-none tw-items-center tw-rounded-sm tw-py-1.5 tw-pl-8 tw-pr-2 tw-text-sm tw-outline-none tw-transition-colors focus:tw-bg-accent focus:tw-text-accent-foreground data-[disabled]:tw-pointer-events-none data-[disabled]:tw-opacity-50",e),checked:n,...r,children:[a.jsx("span",{className:"tw-absolute tw-left-2 tw-flex tw-h-3.5 tw-w-3.5 tw-items-center tw-justify-center",children:a.jsx(pe.ItemIndicator,{children:a.jsx(Q.Check,{className:"tw-h-4 tw-w-4"})})}),t]}));ar.displayName=pe.CheckboxItem.displayName;const uo=g.forwardRef(({className:e,children:t,...n},r)=>a.jsxs(pe.RadioItem,{ref:r,className:N("tw-relative tw-flex tw-cursor-default tw-select-none tw-items-center tw-rounded-sm tw-py-1.5 tw-pl-8 tw-pr-2 tw-text-sm tw-outline-none tw-transition-colors focus:tw-bg-accent focus:tw-text-accent-foreground data-[disabled]:tw-pointer-events-none data-[disabled]:tw-opacity-50",e),...n,children:[a.jsx("span",{className:"tw-absolute tw-left-2 tw-flex tw-h-3.5 tw-w-3.5 tw-items-center tw-justify-center",children:a.jsx(pe.ItemIndicator,{children:a.jsx(Q.Circle,{className:"tw-h-2 tw-w-2 tw-fill-current"})})}),t]}));uo.displayName=pe.RadioItem.displayName;const Wt=g.forwardRef(({className:e,inset:t,...n},r)=>a.jsx(pe.Label,{ref:r,className:N("tw-px-2 tw-py-1.5 tw-text-sm tw-font-semibold",t&&"tw-pl-8",e),...n}));Wt.displayName=pe.Label.displayName;const jn=g.forwardRef(({className:e,...t},n)=>a.jsx(pe.Separator,{ref:n,className:N("tw--mx-1 tw-my-1 tw-h-px tw-bg-muted",e),...t}));jn.displayName=pe.Separator.displayName;function ms({className:e,...t}){return a.jsx("span",{className:N("tw-ml-auto tw-text-xs tw-tracking-widest tw-opacity-60",e),...t})}ms.displayName="DropdownMenuShortcut";const Yl=g.forwardRef(({bookId:e,handleSelectBook:t,isSelected:n,handleHighlightBook:r,handleKeyDown:o,bookType:s,children:i},l)=>a.jsxs(co,{ref:l,textValue:e,className:N("tw-mx-1 tw-px-1 tw-font-normal tw-text-foreground/80",{"tw-bg-amber-50 tw-text-yellow-900 data-[highlighted]:tw-bg-amber-100":n}),onSelect:c=>{c.preventDefault(),t()},onKeyDown:c=>{o(c)},onFocus:r,onMouseMove:r,children:[a.jsx("span",{className:N("tw-border-b-0 tw-border-l-2 tw-border-r-0 tw-border-t-0 tw-border-solid tw-px-2",{"tw-font-bold":n,"tw-border-l-red-200":s.toLowerCase()==="ot","tw-border-l-purple-200":s.toLowerCase()==="nt","tw-border-l-indigo-200":s.toLowerCase()==="dc"}),children:ae.bookIdToEnglishName(e)}),n&&a.jsx("div",{children:i})]},e));function Wl({handleSelectChapter:e,endChapter:t,activeChapter:n,highlightedChapter:r,handleHighlightedChapter:o}){const s=Array.from({length:t},(l,c)=>c+1),i=g.useCallback(l=>{o(l)},[o]);return a.jsx("div",{className:N("tw-flex tw-flex-wrap tw-items-start tw-justify-start tw-self-stretch"),children:s.map(l=>a.jsx("div",{className:N("tw-box-content tw-flex tw-h-4 tw-w-4 tw-cursor-pointer tw-items-center tw-justify-end tw-rounded-md tw-p-2 tw-text-amber-800",{"tw-font-semibold tw-text-amber-900":l===n,"tw-bg-amber-200":l===r}),onClick:c=>{c.preventDefault(),c.stopPropagation(),e(l)},role:"button",onKeyDown:c=>{c.key==="Enter"&&e(l)},tabIndex:0,onMouseMove:()=>i(l),children:l},l))})}function Kl({handleSort:e,handleLocationHistory:t,handleBookmarks:n}){return a.jsxs(Wt,{className:"tw-flex tw-justify-between",children:[a.jsx("p",{className:"tw-inline-block tw-align-middle",children:"Go To"}),a.jsxs("div",{className:"tw-flex tw-items-center",children:[a.jsx(Q.ArrowDownWideNarrow,{onClick:e,className:"tw-m-2 tw-h-4 tw-w-4 tw-cursor-pointer tw-gap-2"}),a.jsx(Q.Clock,{onClick:t,className:"tw-m-2 tw-h-4 tw-w-4 tw-cursor-pointer tw-gap-2"}),a.jsx(Q.Bookmark,{onClick:n,className:"tw-m-2 tw-h-4 tw-w-4 tw-cursor-pointer tw-gap-2"})]})]})}const wn=ae.allBookIds,Jl={OT:"Old Testament",NT:"New Testament",DC:"Deuterocanon"},la=["OT","NT","DC"],Zl=32+32+32,Ql=[/^(\w+)$/i,/^(\w+)(?:\s(\d+))$/i,/^(\w+)(?:\s(\d+):(\d+))$/i],ec=e=>({OT:wn.filter(n=>ae.isBookOT(n)),NT:wn.filter(n=>ae.isBookNT(n)),DC:wn.filter(n=>ae.isBookDC(n))})[e],rn=e=>W.getChaptersForBook(ae.bookIdToNumber(e));function tc(){return wn.map(t=>ae.bookIdToEnglishName(t))}function nc(e){return tc().includes(e)}function rc(e){const t=e.toLowerCase().replace(/^\w/,n=>n.toUpperCase());if(nc(t))return wn.find(r=>ae.bookIdToEnglishName(r)===t)}function oc({scrRef:e,handleSubmit:t}){const[n,r]=g.useState(""),[o,s]=g.useState(ae.bookNumberToId(e.bookNum)),[i,l]=g.useState(e.chapterNum??0),[c,d]=g.useState(ae.bookNumberToId(e.bookNum)),[u,h]=g.useState(!1),[w,b]=g.useState(u),x=g.useRef(void 0),f=g.useRef(void 0),m=g.useRef(void 0),S=g.useCallback(k=>ec(k).filter(D=>{const $=ae.bookIdToEnglishName(D).toLowerCase(),J=n.replace(/[^a-zA-Z]/g,"").toLowerCase();return $.includes(J)||D.toLowerCase().includes(J)}),[n]),R=k=>{r(k)},j=g.useRef(!1),E=g.useCallback(k=>{if(j.current){j.current=!1;return}h(k)},[]),v=g.useCallback((k,D,$,J)=>{if(l(ae.bookNumberToId(e.bookNum)!==k?1:e.chapterNum),D||rn(k)===-1){t({bookNum:ae.bookIdToNumber(k),chapterNum:$||1,verseNum:J||1}),h(!1),r("");return}s(o!==k?k:""),h(!D)},[t,e.bookNum,e.chapterNum,o]),P=k=>{k<=0||k>rn(o)||v(o,!0,k)},V=g.useCallback(()=>{Ql.forEach(k=>{const D=n.match(k);if(D){const[$,J=void 0,Y=void 0]=D.slice(1),F=rc($);(ae.isBookIdValid($)||F)&&v(F??$,!0,J?parseInt(J,10):1,Y?parseInt(Y,10):1)}})},[v,n]),U=g.useCallback(k=>{u?(k.key==="ArrowDown"||k.key==="ArrowUp")&&(typeof m<"u"&&m.current!==null?m.current.focus():typeof f<"u"&&f.current!==null&&f.current.focus(),k.preventDefault()):h(!0)},[u]),C=k=>{const{key:D}=k;D==="ArrowRight"||D==="ArrowLeft"||D==="ArrowDown"||D==="ArrowUp"||D==="Enter"||(x.current.dispatchEvent(new KeyboardEvent("keydown",{key:D})),x.current.focus())},_=k=>{const{key:D}=k;if(c===o){if(D==="Enter"){k.preventDefault(),v(o,!0,i);return}let $=0;if(D==="ArrowRight")if(i1)$=-1;else{k.preventDefault();return}else D==="ArrowDown"?$=6:D==="ArrowUp"&&($=-6);i+$<=0||i+$>rn(c)?l(0):$!==0&&(l(i+$),k.preventDefault())}};return g.useEffect(()=>{o===c?o===ae.bookNumberToId(e.bookNum)?l(e.chapterNum):l(1):l(0)},[c,e.bookNum,e.chapterNum,o]),g.useLayoutEffect(()=>{b(u)},[u]),g.useLayoutEffect(()=>{const k=setTimeout(()=>{if(w&&f.current&&m.current){const $=m.current.offsetTop-Zl;f.current.scrollTo({top:$,behavior:"instant"})}},10);return()=>{clearTimeout(k)}},[w]),a.jsx("div",{className:"pr-twp tw-flex",children:a.jsxs(or,{modal:!1,open:u,onOpenChange:E,children:[a.jsx(lo,{asChild:!0,children:a.jsx(Pl,{ref:x,value:n,handleSearch:R,handleKeyDown:U,handleOnClick:()=>{s(ae.bookNumberToId(e.bookNum)),d(ae.bookNumberToId(e.bookNum)),l(e.chapterNum>0?e.chapterNum:0),h(!0),x.current.focus()},onFocus:()=>{j.current=!0},handleSubmit:V,placeholder:`${ae.bookNumberToEnglishName(e.bookNum)} ${e.chapterNum}:${e.verseNum}`})}),a.jsxs(En,{className:"tw-m-1 tw-overflow-y-auto tw-p-0 tw-font-normal tw-text-foreground/80",style:{width:"233px",maxHeight:"500px",zIndex:"250"},onKeyDown:C,align:"start",ref:f,children:[a.jsx(Kl,{handleSort:()=>console.log("sorting"),handleLocationHistory:()=>console.log("location history"),handleBookmarks:()=>console.log("bookmarks")}),la.map((k,D)=>S(k).length>0&&a.jsxs("div",{children:[a.jsx(Wt,{className:"tw-font-semibold tw-text-foreground/80",children:Jl[k]}),S(k).map($=>a.jsx("div",{children:a.jsx(Yl,{bookId:$,handleSelectBook:()=>v($,!1),isSelected:o===$,handleHighlightBook:()=>d($),handleKeyDown:_,bookType:k,ref:J=>{o===$&&(m.current=J)},children:a.jsx(Wl,{handleSelectChapter:P,endChapter:rn($),activeChapter:e.bookNum===ae.bookIdToNumber($)?e.chapterNum:0,highlightedChapter:i,handleHighlightedChapter:J=>{l(J)}})})},$)),la.length-1!==D?a.jsx(jn,{}):void 0]},k))]})]})})}const hs=Xt.cva("pr-twp tw-inline-flex tw-items-center tw-justify-center tw-whitespace-nowrap tw-rounded-md tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-colors focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50",{variants:{variant:{default:"tw-bg-primary tw-text-primary-foreground hover:tw-bg-primary/90",destructive:"tw-bg-destructive tw-text-destructive-foreground hover:tw-bg-destructive/90",outline:"tw-border tw-border-input tw-bg-background hover:tw-bg-accent hover:tw-text-accent-foreground",secondary:"tw-bg-secondary tw-text-secondary-foreground hover:tw-bg-secondary/80",ghost:"hover:tw-bg-accent hover:tw-text-accent-foreground",link:"tw-text-primary tw-underline-offset-4 hover:tw-underline"},size:{default:"tw-h-10 tw-px-4 tw-py-2",sm:"tw-h-9 tw-rounded-md tw-px-3",lg:"tw-h-11 tw-rounded-md tw-px-8",icon:"tw-h-10 tw-w-10"}},defaultVariants:{variant:"default",size:"default"}}),fe=g.forwardRef(({className:e,variant:t,size:n,asChild:r=!1,...o},s)=>{const i=r?Ht.Slot:"button";return a.jsx(i,{className:N(hs({variant:t,size:n,className:e})),ref:s,...o})});fe.displayName="Button";const ac=Xt.cva("tw-text-sm tw-font-medium tw-leading-none peer-disabled:tw-cursor-not-allowed peer-disabled:tw-opacity-70"),qe=g.forwardRef(({className:e,...t},n)=>a.jsx(rs.Root,{ref:n,className:N("pr-twp",ac(),e),...t}));qe.displayName=rs.Root.displayName;const po=g.forwardRef(({className:e,...t},n)=>a.jsx(bn.Root,{className:N("pr-twp tw-grid tw-gap-2",e),...t,ref:n}));po.displayName=bn.Root.displayName;const Yn=g.forwardRef(({className:e,...t},n)=>a.jsx(bn.Item,{ref:n,className:N("pr-twp tw-aspect-square tw-h-4 tw-w-4 tw-rounded-full tw-border tw-border-primary tw-text-primary tw-ring-offset-background focus:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-cursor-not-allowed disabled:tw-opacity-50",e),...t,children:a.jsx(bn.Indicator,{className:"tw-flex tw-items-center tw-justify-center",children:a.jsx(Q.Circle,{className:"tw-h-2.5 tw-w-2.5 tw-fill-current tw-text-current"})})}));Yn.displayName=bn.Item.displayName;const sc=vn.Root,ic=vn.Trigger,gs=g.forwardRef(({className:e,align:t="center",sideOffset:n=4,...r},o)=>a.jsx(vn.Portal,{children:a.jsx(vn.Content,{ref:o,align:t,sideOffset:n,className:N("pr-twp tw-z-50 tw-w-72 tw-rounded-md tw-border tw-bg-popover tw-p-4 tw-text-popover-foreground tw-shadow-md tw-outline-none data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0 data-[state=closed]:tw-zoom-out-95 data-[state=open]:tw-zoom-in-95 data-[side=bottom]:tw-slide-in-from-top-2 data-[side=left]:tw-slide-in-from-right-2 data-[side=right]:tw-slide-in-from-left-2 data-[side=top]:tw-slide-in-from-bottom-2",e),...r})}));gs.displayName=vn.Content.displayName;const lc=be.Portal,bs=g.forwardRef(({className:e,...t},n)=>a.jsx(be.Overlay,{ref:n,className:N("tw-fixed tw-inset-0 tw-z-50 tw-bg-black/80 data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0",e),...t}));bs.displayName=be.Overlay.displayName;const cc=g.forwardRef(({className:e,children:t,...n},r)=>a.jsxs(lc,{children:[a.jsx(bs,{}),a.jsxs(be.Content,{ref:r,className:N("tw-fixed tw-left-[50%] tw-top-[50%] tw-z-50 tw-grid tw-w-full tw-max-w-lg tw-translate-x-[-50%] tw-translate-y-[-50%] tw-gap-4 tw-border tw-bg-background tw-p-6 tw-shadow-lg tw-duration-200 data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0 data-[state=closed]:tw-zoom-out-95 data-[state=open]:tw-zoom-in-95 data-[state=closed]:tw-slide-out-to-left-1/2 data-[state=closed]:tw-slide-out-to-top-[48%] data-[state=open]:tw-slide-in-from-left-1/2 data-[state=open]:tw-slide-in-from-top-[48%] sm:tw-rounded-lg",e),...n,children:[t,a.jsxs(be.Close,{className:"tw-absolute tw-right-4 tw-top-4 tw-rounded-sm tw-opacity-70 tw-ring-offset-background tw-transition-opacity hover:tw-opacity-100 focus:tw-outline-none focus:tw-ring-2 focus:tw-ring-ring focus:tw-ring-offset-2 disabled:tw-pointer-events-none data-[state=open]:tw-bg-accent data-[state=open]:tw-text-muted-foreground",children:[a.jsx(Q.X,{className:"tw-h-4 tw-w-4"}),a.jsx("span",{className:"tw-sr-only",children:"Close"})]})]})]}));cc.displayName=be.Content.displayName;const dc=g.forwardRef(({className:e,...t},n)=>a.jsx(be.Title,{ref:n,className:N("tw-text-lg tw-font-semibold tw-leading-none tw-tracking-tight",e),...t}));dc.displayName=be.Title.displayName;const uc=g.forwardRef(({className:e,...t},n)=>a.jsx(be.Description,{ref:n,className:N("tw-text-sm tw-text-muted-foreground",e),...t}));uc.displayName=be.Description.displayName;const vs=g.forwardRef(({className:e,...t},n)=>a.jsx(Oe.Command,{ref:n,className:N("tw-flex tw-h-full tw-w-full tw-flex-col tw-overflow-hidden tw-rounded-md tw-bg-popover tw-text-popover-foreground",e),...t}));vs.displayName=Oe.Command.displayName;const xs=g.forwardRef(({className:e,...t},n)=>a.jsxs("div",{className:"tw-flex tw-items-center tw-border-b tw-px-3",children:[a.jsx(Q.Search,{className:"tw-me-2 tw-h-4 tw-w-4 tw-shrink-0 tw-opacity-50"}),a.jsx(Oe.Command.Input,{ref:n,className:N("tw-flex tw-h-11 tw-w-full tw-rounded-md tw-bg-transparent tw-py-3 tw-text-sm tw-outline-none placeholder:tw-text-muted-foreground disabled:tw-cursor-not-allowed disabled:tw-opacity-50",e),...t})]}));xs.displayName=Oe.Command.Input.displayName;const ys=g.forwardRef(({className:e,...t},n)=>a.jsx(Oe.Command.List,{ref:n,className:N("tw-max-h-[300px] tw-overflow-y-auto tw-overflow-x-hidden",e),...t}));ys.displayName=Oe.Command.List.displayName;const Ns=g.forwardRef((e,t)=>a.jsx(Oe.Command.Empty,{ref:t,className:"tw-py-6 tw-text-center tw-text-sm",...e}));Ns.displayName=Oe.Command.Empty.displayName;const pc=g.forwardRef(({className:e,...t},n)=>a.jsx(Oe.Command.Group,{ref:n,className:N("tw-overflow-hidden tw-p-1 tw-text-foreground [&_[cmdk-group-heading]]:tw-px-2 [&_[cmdk-group-heading]]:tw-py-1.5 [&_[cmdk-group-heading]]:tw-text-xs [&_[cmdk-group-heading]]:tw-font-medium [&_[cmdk-group-heading]]:tw-text-muted-foreground",e),...t}));pc.displayName=Oe.Command.Group.displayName;const wc=g.forwardRef(({className:e,...t},n)=>a.jsx(Oe.Command.Separator,{ref:n,className:N("tw--mx-1 tw-h-px tw-bg-border",e),...t}));wc.displayName=Oe.Command.Separator.displayName;const ks=g.forwardRef(({className:e,...t},n)=>a.jsx(Oe.Command.Item,{ref:n,className:N("tw-relative tw-flex tw-cursor-default tw-select-none tw-items-center tw-rounded-sm tw-px-2 tw-py-1.5 tw-text-sm tw-outline-none data-[disabled=true]:tw-pointer-events-none data-[selected=true]:tw-bg-accent data-[selected=true]:tw-text-accent-foreground data-[disabled=true]:tw-opacity-50",e),...t}));ks.displayName=Oe.Command.Item.displayName;function fc(e){return typeof e=="string"?e:typeof e=="number"?e.toString():e.label}function Wn({id:e,options:t=[],buttonClassName:n,popoverContentClassName:r,value:o,onChange:s=()=>{},getOptionLabel:i=fc,buttonPlaceholder:l="",textPlaceholder:c="",commandEmptyMessage:d="No option found",buttonVariant:u="outline",dir:h="ltr",isDisabled:w=!1,...b}){const[x,f]=g.useState(!1);return a.jsxs(sc,{open:x,onOpenChange:f,...b,children:[a.jsx(ic,{asChild:!0,children:a.jsxs(fe,{variant:u,role:"combobox","aria-expanded":x,id:e,className:N("tw-w-[200px] tw-justify-between",n),disabled:w,children:[a.jsx("span",{className:"tw-overflow-hidden tw-text-ellipsis tw-whitespace-nowrap",children:o?i(o):l}),a.jsx(Q.ChevronsUpDown,{className:"tw-ms-2 tw-h-4 tw-w-4 tw-shrink-0 tw-opacity-50"})]})}),a.jsx(gs,{className:N("tw-w-[200px] tw-p-0",r),dir:h,children:a.jsxs(vs,{children:[a.jsx(xs,{dir:h,placeholder:c,className:"tw-text-inherit"}),a.jsx(Ns,{children:d}),a.jsx(ys,{children:t.map(m=>a.jsxs(ks,{value:i(m),onSelect:()=>{s(m),f(!1)},children:[a.jsx(Q.Check,{className:N("tw-me-2 tw-h-4 tw-w-4",{"tw-opacity-0":!o||i(o)!==i(m)})}),i(m)]},i(m)))})]})})]})}function Ss({startChapter:e,endChapter:t,handleSelectStartChapter:n,handleSelectEndChapter:r,isDisabled:o=!1,chapterCount:s}){const i=g.useMemo(()=>Array.from({length:s},(d,u)=>u+1),[s]),l=d=>{n(d),d>t&&r(d)},c=d=>{r(d),dd.toString(),value:e},"start chapter"),a.jsx(qe,{htmlFor:"end-chapters-combobox",children:"to"}),a.jsx(Wn,{isDisabled:o,onChange:c,buttonClassName:"tw-ml-2 tw-w-20",options:i,getOptionLabel:d=>d.toString(),value:t},"end chapter")]})}var Es=(e=>(e.CURRENT_BOOK="current book",e.CHOOSE_BOOKS="choose books",e))(Es||{});const mc=Object.freeze(["%webView_bookSelector_currentBook%","%webView_bookSelector_choose%","%webView_bookSelector_chooseBooks%"]),Tr=(e,t)=>e[t]??t;function hc({handleBookSelectionModeChange:e,currentBookName:t,onSelectBooks:n,selectedBookIds:r,chapterCount:o,endChapter:s,handleSelectEndChapter:i,startChapter:l,handleSelectStartChapter:c,localizedStrings:d}){const u=Tr(d,"%webView_bookSelector_currentBook%"),h=Tr(d,"%webView_bookSelector_choose%"),w=Tr(d,"%webView_bookSelector_chooseBooks%"),[b,x]=g.useState("current book"),f=m=>{x(m),e(m)};return a.jsx(po,{className:"pr-twp tw-flex",value:b,onValueChange:m=>f(m),children:a.jsxs("div",{className:"tw-flex tw-w-full tw-flex-col tw-gap-4",children:[a.jsxs("div",{className:"tw-grid tw-grid-cols-[25%,25%,50%]",children:[a.jsxs("div",{className:"tw-flex tw-items-center",children:[a.jsx(Yn,{value:"current book"}),a.jsx(qe,{className:"tw-ml-1",children:u})]}),a.jsx(qe,{className:"tw-flex tw-items-center",children:t}),a.jsx("div",{className:"tw-flex tw-items-center tw-justify-end",children:a.jsx(Ss,{isDisabled:b==="choose books",handleSelectStartChapter:c,handleSelectEndChapter:i,chapterCount:o,startChapter:l,endChapter:s})})]}),a.jsxs("div",{className:"tw-grid tw-grid-cols-[25%,50%,25%]",children:[a.jsxs("div",{className:"tw-flex tw-items-center",children:[a.jsx(Yn,{value:"choose books"}),a.jsx(qe,{className:"tw-ml-1",children:w})]}),a.jsx(qe,{className:"tw-flex tw-items-center",children:r.map(m=>ae.bookIdToEnglishName(m)).join(", ")}),a.jsx(fe,{disabled:b==="current book",onClick:()=>n(),children:h})]})]})})}function gc({table:e}){return a.jsxs(or,{children:[a.jsx(ts.DropdownMenuTrigger,{asChild:!0,children:a.jsxs(fe,{variant:"outline",size:"sm",className:"tw-ml-auto tw-hidden tw-h-8 lg:tw-flex",children:[a.jsx(Q.FilterIcon,{className:"tw-mr-2 tw-h-4 tw-w-4"}),"View"]})}),a.jsxs(En,{align:"end",className:"tw-w-[150px]",children:[a.jsx(Wt,{children:"Toggle columns"}),a.jsx(jn,{}),e.getAllColumns().filter(t=>t.getCanHide()).map(t=>a.jsx(ar,{className:"tw-capitalize",checked:t.getIsVisible(),onCheckedChange:n=>t.toggleVisibility(!!n),children:t.id},t.id))]})]})}const At=ge.Root,js=ge.Group,Bt=ge.Value,bt=g.forwardRef(({className:e,children:t,...n},r)=>a.jsxs(ge.Trigger,{ref:r,className:N("tw-flex tw-h-10 tw-w-full tw-items-center tw-justify-between tw-rounded-md tw-border tw-border-input tw-bg-background tw-px-3 tw-py-2 tw-text-sm tw-ring-offset-background placeholder:tw-text-muted-foreground focus:tw-outline-none focus:tw-ring-2 focus:tw-ring-ring focus:tw-ring-offset-2 disabled:tw-cursor-not-allowed disabled:tw-opacity-50 [&>span]:tw-line-clamp-1",e),...n,children:[t,a.jsx(ge.Icon,{asChild:!0,children:a.jsx(Q.ChevronDown,{className:"tw-h-4 tw-w-4 tw-opacity-50"})})]}));bt.displayName=ge.Trigger.displayName;const wo=g.forwardRef(({className:e,...t},n)=>a.jsx(ge.ScrollUpButton,{ref:n,className:N("tw-flex tw-cursor-default tw-items-center tw-justify-center tw-py-1",e),...t,children:a.jsx(Q.ChevronUp,{className:"tw-h-4 tw-w-4"})}));wo.displayName=ge.ScrollUpButton.displayName;const fo=g.forwardRef(({className:e,...t},n)=>a.jsx(ge.ScrollDownButton,{ref:n,className:N("tw-flex tw-cursor-default tw-items-center tw-justify-center tw-py-1",e),...t,children:a.jsx(Q.ChevronDown,{className:"tw-h-4 tw-w-4"})}));fo.displayName=ge.ScrollDownButton.displayName;const vt=g.forwardRef(({className:e,children:t,position:n="popper",...r},o)=>a.jsx(ge.Portal,{children:a.jsxs(ge.Content,{ref:o,className:N("pr-twp tw-relative tw-z-50 tw-max-h-96 tw-min-w-[8rem] tw-overflow-hidden tw-rounded-md tw-border tw-bg-popover tw-text-popover-foreground tw-shadow-md data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0 data-[state=closed]:tw-zoom-out-95 data-[state=open]:tw-zoom-in-95 data-[side=bottom]:tw-slide-in-from-top-2 data-[side=left]:tw-slide-in-from-right-2 data-[side=right]:tw-slide-in-from-left-2 data-[side=top]:tw-slide-in-from-bottom-2",n==="popper"&&"data-[side=bottom]:tw-translate-y-1 data-[side=left]:tw--translate-x-1 data-[side=right]:tw-translate-x-1 data-[side=top]:tw--translate-y-1",e),position:n,...r,children:[a.jsx(wo,{}),a.jsx(ge.Viewport,{className:N("tw-p-1",n==="popper"&&"tw-h-[var(--radix-select-trigger-height)] tw-w-full tw-min-w-[var(--radix-select-trigger-width)]"),children:t}),a.jsx(fo,{})]})}));vt.displayName=ge.Content.displayName;const Cs=g.forwardRef(({className:e,...t},n)=>a.jsx(ge.Label,{ref:n,className:N("tw-py-1.5 tw-pl-8 tw-pr-2 tw-text-sm tw-font-semibold",e),...t}));Cs.displayName=ge.Label.displayName;const Ae=g.forwardRef(({className:e,children:t,...n},r)=>a.jsxs(ge.Item,{ref:r,className:N("tw-relative tw-flex tw-w-full tw-cursor-default tw-select-none tw-items-center tw-rounded-sm tw-py-1.5 tw-pl-8 tw-pr-2 tw-text-sm tw-outline-none focus:tw-bg-accent focus:tw-text-accent-foreground data-[disabled]:tw-pointer-events-none data-[disabled]:tw-opacity-50",e),...n,children:[a.jsx("span",{className:"tw-absolute tw-left-2 tw-flex tw-h-3.5 tw-w-3.5 tw-items-center tw-justify-center",children:a.jsx(ge.ItemIndicator,{children:a.jsx(Q.Check,{className:"tw-h-4 tw-w-4"})})}),a.jsx(ge.ItemText,{children:t})]}));Ae.displayName=ge.Item.displayName;const Ts=g.forwardRef(({className:e,...t},n)=>a.jsx(ge.Separator,{ref:n,className:N("tw--mx-1 tw-my-1 tw-h-px tw-bg-muted",e),...t}));Ts.displayName=ge.Separator.displayName;function bc({table:e}){return a.jsx("div",{className:"tw-flex tw-items-center tw-justify-between tw-px-2 tw-pb-3 tw-pt-3",children:a.jsxs("div",{className:"tw-flex tw-items-center tw-space-x-6 lg:tw-space-x-8",children:[a.jsxs("div",{className:"tw-flex-1 tw-text-sm tw-text-muted-foreground",children:[e.getFilteredSelectedRowModel().rows.length," of"," ",e.getFilteredRowModel().rows.length," row(s) selected"]}),a.jsxs("div",{className:"tw-flex tw-items-center tw-space-x-2",children:[a.jsx("p",{className:"tw-text-nowrap tw-text-sm tw-font-medium",children:"Rows per page"}),a.jsxs(At,{value:`${e.getState().pagination.pageSize}`,onValueChange:t=>{e.setPageSize(Number(t))},children:[a.jsx(bt,{className:"tw-h-8 tw-w-[70px]",children:a.jsx(Bt,{placeholder:e.getState().pagination.pageSize})}),a.jsx(vt,{side:"top",children:[10,20,30,40,50].map(t=>a.jsx(Ae,{value:`${t}`,children:t},t))})]})]}),a.jsxs("div",{className:"tw-flex tw-w-[100px] tw-items-center tw-justify-center tw-text-sm tw-font-medium",children:["Page ",e.getState().pagination.pageIndex+1," of ",e.getPageCount()]}),a.jsxs("div",{className:"tw-flex tw-items-center tw-space-x-2",children:[a.jsxs(fe,{variant:"outline",size:"icon",className:"tw-hidden tw-h-8 tw-w-8 tw-p-0 lg:tw-flex",onClick:()=>e.setPageIndex(0),disabled:!e.getCanPreviousPage(),children:[a.jsx("span",{className:"tw-sr-only",children:"Go to first page"}),a.jsx(Q.ArrowLeftIcon,{className:"tw-h-4 tw-w-4"})]}),a.jsxs(fe,{variant:"outline",size:"icon",className:"tw-h-8 tw-w-8 tw-p-0",onClick:()=>e.previousPage(),disabled:!e.getCanPreviousPage(),children:[a.jsx("span",{className:"tw-sr-only",children:"Go to previous page"}),a.jsx(Q.ChevronLeftIcon,{className:"tw-h-4 tw-w-4"})]}),a.jsxs(fe,{variant:"outline",size:"icon",className:"tw-h-8 tw-w-8 tw-p-0",onClick:()=>e.nextPage(),disabled:!e.getCanNextPage(),children:[a.jsx("span",{className:"tw-sr-only",children:"Go to next page"}),a.jsx(Q.ChevronRightIcon,{className:"tw-h-4 tw-w-4"})]}),a.jsxs(fe,{variant:"outline",size:"icon",className:"tw-hidden tw-h-8 tw-w-8 tw-p-0 lg:tw-flex",onClick:()=>e.setPageIndex(e.getPageCount()-1),disabled:!e.getCanNextPage(),children:[a.jsx("span",{className:"tw-sr-only",children:"Go to last page"}),a.jsx(Q.ArrowRightIcon,{className:"tw-h-4 tw-w-4"})]})]})]})})}const Cn=g.forwardRef(({className:e,stickyHeader:t,...n},r)=>a.jsx("div",{className:N("pr-twp tw-relative tw-w-full",{"tw-overflow-auto":!t}),children:a.jsx("table",{ref:r,className:N("tw-w-full tw-caption-bottom tw-text-sm",e),...n})}));Cn.displayName="Table";const Tn=g.forwardRef(({className:e,stickyHeader:t,...n},r)=>a.jsx("thead",{ref:r,className:N({"tw-sticky tw-top-[-1px] tw-bg-background tw-drop-shadow-sm":t},"[&_tr]:tw-border-b",e),...n}));Tn.displayName="TableHeader";const Rn=g.forwardRef(({className:e,...t},n)=>a.jsx("tbody",{ref:n,className:N("[&_tr:last-child]:tw-border-0",e),...t}));Rn.displayName="TableBody";const Rs=g.forwardRef(({className:e,...t},n)=>a.jsx("tfoot",{ref:n,className:N("tw-border-t tw-bg-muted/50 tw-font-medium [&>tr]:last:tw-border-b-0",e),...t}));Rs.displayName="TableFooter";const Ze=g.forwardRef(({className:e,...t},n)=>a.jsx("tr",{ref:n,className:N("tw-border-b tw-transition-colors hover:tw-bg-muted/50 data-[state=selected]:tw-bg-muted",e),...t}));Ze.displayName="TableRow";const Vt=g.forwardRef(({className:e,...t},n)=>a.jsx("th",{ref:n,className:N("tw-h-12 tw-px-4 tw-text-start tw-align-middle tw-font-medium tw-text-muted-foreground [&:has([role=checkbox])]:tw-pe-0",e),...t}));Vt.displayName="TableHead";const xt=g.forwardRef(({className:e,...t},n)=>a.jsx("td",{ref:n,className:N("tw-p-4 tw-align-middle [&:has([role=checkbox])]:tw-pe-0",e),...t}));xt.displayName="TableCell";const Os=g.forwardRef(({className:e,...t},n)=>a.jsx("caption",{ref:n,className:N("tw-mt-4 tw-text-sm tw-text-muted-foreground",e),...t}));Os.displayName="TableCaption";function _s({columns:e,data:t,enablePagination:n=!1,showPaginationControls:r=!1,showColumnVisibilityControls:o=!1,stickyHeader:s=!1,onRowClickHandler:i=()=>{}}){var m;const[l,c]=g.useState([]),[d,u]=g.useState([]),[h,w]=g.useState({}),[b,x]=g.useState({}),f=Se.useReactTable({data:t,columns:e,getCoreRowModel:Se.getCoreRowModel(),...n&&{getPaginationRowModel:Se.getPaginationRowModel()},onSortingChange:c,getSortedRowModel:Se.getSortedRowModel(),onColumnFiltersChange:u,getFilteredRowModel:Se.getFilteredRowModel(),onColumnVisibilityChange:w,onRowSelectionChange:x,state:{sorting:l,columnFilters:d,columnVisibility:h,rowSelection:b}});return a.jsxs("div",{className:"pr-twp",children:[o&&a.jsx(gc,{table:f}),a.jsxs(Cn,{stickyHeader:s,children:[a.jsx(Tn,{stickyHeader:s,children:f.getHeaderGroups().map(S=>a.jsx(Ze,{children:S.headers.map(R=>a.jsx(Vt,{children:R.isPlaceholder?void 0:Se.flexRender(R.column.columnDef.header,R.getContext())},R.id))},S.id))}),a.jsx(Rn,{children:(m=f.getRowModel().rows)!=null&&m.length?f.getRowModel().rows.map(S=>a.jsx(Ze,{onClick:()=>i(S,f),"data-state":S.getIsSelected()&&"selected",children:S.getVisibleCells().map(R=>a.jsx(xt,{children:Se.flexRender(R.column.columnDef.cell,R.getContext())},R.id))},S.id)):a.jsx(Ze,{children:a.jsx(xt,{colSpan:e.length,className:"tw-h-24 tw-text-center",children:"No results."})})})]}),n&&a.jsxs("div",{className:"tw-flex tw-items-center tw-justify-end tw-space-x-2 tw-py-4",children:[a.jsx(fe,{variant:"outline",size:"sm",onClick:()=>f.previousPage(),disabled:!f.getCanPreviousPage(),children:"Previous"}),a.jsx(fe,{variant:"outline",size:"sm",onClick:()=>f.nextPage(),disabled:!f.getCanNextPage(),children:"Next"})]}),n&&r&&a.jsx(bc,{table:f})]})}function vc({occurrenceData:e,setScriptureReference:t,localizedStrings:n}){const r=n["%webView_inventory_occurrences_table_header_reference%"],o=n["%webView_inventory_occurrences_table_header_occurrence%"],s=g.useMemo(()=>{const i=[];return e.forEach(l=>{i.some(c=>W.deepEqual(c,l))||i.push(l)}),i},[e]);return a.jsxs(Cn,{stickyHeader:!0,children:[a.jsx(Tn,{stickyHeader:!0,children:a.jsxs(Ze,{children:[a.jsx(Vt,{children:r}),a.jsx(Vt,{children:o})]})}),a.jsx(Rn,{children:s.length>0&&s.map(i=>a.jsxs(Ze,{onClick:()=>{t(i.reference)},children:[a.jsx(xt,{children:`${ae.bookNumberToEnglishName(i.reference.bookNum)} ${i.reference.chapterNum}:${i.reference.verseNum}`}),a.jsx(xt,{children:i.text})]},`${i.reference.bookNum} ${i.reference.chapterNum}:${i.reference.verseNum}-${i.text}`))})]})}const sr=g.forwardRef(({className:e,...t},n)=>a.jsx(Ur.Root,{ref:n,className:N("tw-peer pr-twp tw-h-4 tw-w-4 tw-shrink-0 tw-rounded-sm tw-border tw-border-primary tw-ring-offset-background focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-cursor-not-allowed disabled:tw-opacity-50 data-[state=checked]:tw-bg-primary data-[state=checked]:tw-text-primary-foreground",e),...t,children:a.jsx(Ur.Indicator,{className:N("tw-flex tw-items-center tw-justify-center tw-text-current"),children:a.jsx(Q.Check,{className:"tw-h-4 tw-w-4"})})}));sr.displayName=Ur.Root.displayName;const Ps=e=>e.split(/(?:\r?\n|\r)|(?=(?:\\(?:v|c|id)))/g),Hr=e=>{const t=/^\\[vc]\s+(\d+)/,n=e.match(t);if(n)return+n[1]},Is=e=>{const t=e.match(/^\\id\s+([A-Za-z]+)/);return t?ae.bookIdToNumber(t[1]):0},Ms=(e,t,n)=>n.includes(e)?"unapproved":t.includes(e)?"approved":"unknown",$s=Xt.cva("pr-twp tw-inline-flex tw-items-center tw-justify-center tw-rounded-md tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-colors hover:tw-bg-muted hover:tw-text-muted-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50 data-[state=on]:tw-bg-accent data-[state=on]:tw-text-accent-foreground",{variants:{variant:{default:"tw-bg-transparent",outline:"tw-border tw-border-input tw-bg-transparent hover:tw-bg-accent hover:tw-text-accent-foreground"},size:{default:"tw-h-10 tw-px-3",sm:"tw-h-9 tw-px-2.5",lg:"tw-h-11 tw-px-5"}},defaultVariants:{variant:"default",size:"default"}}),xc=g.forwardRef(({className:e,variant:t,size:n,...r},o)=>a.jsx(os.Root,{ref:o,className:N($s({variant:t,size:n,className:e})),...r}));xc.displayName=os.Root.displayName;const Ds=g.createContext({size:"default",variant:"default"}),mo=g.forwardRef(({className:e,variant:t,size:n,children:r,...o},s)=>a.jsx(rr.Root,{ref:s,className:N("pr-twp tw-flex tw-items-center tw-justify-center tw-gap-1",e),...o,children:a.jsx(Ds.Provider,{value:{variant:t,size:n},children:r})}));mo.displayName=rr.Root.displayName;const fn=g.forwardRef(({className:e,children:t,variant:n,size:r,...o},s)=>{const i=g.useContext(Ds);return a.jsx(rr.Item,{ref:s,className:N($s({variant:i.variant||n,size:i.size||r}),e),...o,children:t})});fn.displayName=rr.Item.displayName;const ir=e=>e==="asc"?a.jsx(Q.ArrowUpIcon,{className:"tw-ms-2 tw-h-4 tw-w-4"}):e==="desc"?a.jsx(Q.ArrowDownIcon,{className:"tw-ms-2 tw-h-4 tw-w-4"}):a.jsx(Q.ArrowUpDownIcon,{className:"tw-ms-2 tw-h-4 tw-w-4"}),yc=e=>({accessorKey:"item",accessorFn:t=>t.items[0],header:({column:t})=>a.jsxs(fe,{variant:"ghost",onClick:()=>t.toggleSorting(void 0),children:[e,ir(t.getIsSorted())]})}),Nc=(e,t)=>({accessorKey:`item${t}`,accessorFn:n=>n.items[t],header:({column:n})=>a.jsxs(fe,{variant:"ghost",onClick:()=>n.toggleSorting(void 0),children:[e,ir(n.getIsSorted())]})}),kc=e=>({accessorKey:"count",header:({column:t})=>a.jsx("div",{className:"tw-flex tw-justify-end tw-tabular-nums",children:a.jsxs(fe,{variant:"ghost",onClick:()=>t.toggleSorting(void 0),children:[e,ir(t.getIsSorted())]})}),cell:({row:t})=>a.jsx("div",{className:"tw-flex tw-justify-end",children:t.getValue("count")})}),Rr=(e,t,n,r,o,s)=>{let i=[...n];e.forEach(c=>{t==="approved"?i.includes(c)||i.push(c):i=i.filter(d=>d!==c)}),r(i);let l=[...o];e.forEach(c=>{t==="unapproved"?l.includes(c)||l.push(c):l=l.filter(d=>d!==c)}),s(l)},Sc=(e,t,n,r,o)=>({accessorKey:"status",header:({column:s})=>a.jsx("div",{className:"tw-flex tw-justify-center",children:a.jsxs(fe,{variant:"ghost",onClick:()=>s.toggleSorting(void 0),children:[e,ir(s.getIsSorted())]})}),cell:({row:s})=>{const i=s.getValue("status"),l=s.getValue("item");return a.jsxs(mo,{value:i,variant:"outline",type:"single",children:[a.jsx(fn,{onClick:()=>Rr([l],"approved",t,n,r,o),value:"approved",children:a.jsx(Q.CircleCheckIcon,{})}),a.jsx(fn,{onClick:()=>Rr([l],"unapproved",t,n,r,o),value:"unapproved",children:a.jsx(Q.CircleXIcon,{})}),a.jsx(fn,{onClick:()=>Rr([l],"unknown",t,n,r,o),value:"unknown",children:a.jsx(Q.CircleHelpIcon,{})})]})}}),Ec=Object.freeze(["%webView_inventory_all%","%webView_inventory_approved%","%webView_inventory_unapproved%","%webView_inventory_unknown%","%webView_inventory_scope_currentBook%","%webView_inventory_scope_chapter%","%webView_inventory_scope_verse%","%webView_inventory_filter_text%","%webView_inventory_show_additional_items%","%webView_inventory_occurrences_table_header_reference%","%webView_inventory_occurrences_table_header_occurrence%"]),jc=(e,t,n)=>{let r=e;return t!=="all"&&(r=r.filter(o=>t==="approved"&&o.status==="approved"||t==="unapproved"&&o.status==="unapproved"||t==="unknown"&&o.status==="unknown")),n!==""&&(r=r.filter(o=>o.items[0].includes(n))),r},Cc=(e,t,n,r,o)=>{if(!e)return[];const s=[];let i=t.bookNum,l=t.chapterNum,c=t.verseNum;return Ps(e).forEach(u=>{u.startsWith("\\id")&&(i=Is(u),l=0,c=0),u.startsWith("\\c")&&(l=Hr(u),c=0),u.startsWith("\\v")&&(c=Hr(u),l===0&&(l=t.chapterNum));let h=o.exec(u)??void 0;for(;h;){const w=[];h.forEach(m=>w.push(m));const b=h.index,x=s.find(m=>W.deepEqual(m.items,w)),f={reference:{bookNum:i!==void 0?i:-1,chapterNum:l!==void 0?l:-1,verseNum:c!==void 0?c:-1},text:W.substring(u,Math.max(0,b-25),Math.min(b+25,u.length))};if(x)x.count+=1,x.occurrences.push(f);else{const m={items:w,count:1,status:Ms(w[0],n,r),occurrences:[f]};s.push(m)}h=o.exec(u)??void 0}}),s},Je=(e,t)=>e[t]??t;function Tc({scriptureReference:e,setScriptureReference:t,localizedStrings:n,extractItems:r,additionalItemsLabels:o,approvedItems:s,unapprovedItems:i,text:l,scope:c,onScopeChange:d,columns:u}){const h=Je(n,"%webView_inventory_all%"),w=Je(n,"%webView_inventory_approved%"),b=Je(n,"%webView_inventory_unapproved%"),x=Je(n,"%webView_inventory_unknown%"),f=Je(n,"%webView_inventory_scope_currentBook%"),m=Je(n,"%webView_inventory_scope_chapter%"),S=Je(n,"%webView_inventory_scope_verse%"),R=Je(n,"%webView_inventory_filter_text%"),j=Je(n,"%webView_inventory_show_additional_items%"),[E,v]=g.useState(!1),[P,V]=g.useState("all"),[U,C]=g.useState(""),[_,k]=g.useState([]),D=g.useMemo(()=>l?r instanceof RegExp?Cc(l,e,s,i,r):r(l,e,s,i):[],[l,r,e,s,i]),$=g.useMemo(()=>{if(E)return D;const y=[];return D.forEach(T=>{const z=T.items[0],L=y.find(B=>B.items[0]===z);L?(L.count+=T.count,L.occurrences=L.occurrences.concat(T.occurrences)):y.push({items:[z],count:T.count,occurrences:T.occurrences,status:T.status})}),y},[E,D]),J=g.useMemo(()=>jc($,P,U),[$,P,U]),Y=g.useMemo(()=>{var z,L;if(!E)return u;const y=(z=o==null?void 0:o.tableHeaders)==null?void 0:z.length;if(!y)return u;const T=[];for(let B=0;B{k([])},[J]);const F=(y,T)=>{T.setRowSelection(()=>{const z={};return z[y.index]=!0,z}),k(y.original.items)},te=y=>{if(y==="book"||y==="chapter"||y==="verse")d(y);else throw new Error(`Invalid scope value: ${y}`)},se=y=>{if(y==="all"||y==="approved"||y==="unapproved"||y==="unknown")V(y);else throw new Error(`Invalid status filter value: ${y}`)},oe=g.useMemo(()=>{if($.length===0||_.length===0)return[];const y=$.filter(T=>W.deepEqual(E?T.items:[T.items[0]],_));if(y.length>1)throw new Error("Selected item is not unique");return y[0].occurrences},[_,E,$]);return a.jsxs("div",{className:"pr-twp tw-flex tw-h-full tw-flex-col",children:[a.jsxs("div",{className:"tw-flex tw-items-stretch",children:[a.jsxs(At,{onValueChange:y=>se(y),defaultValue:P,children:[a.jsx(bt,{className:"tw-m-1",children:a.jsx(Bt,{placeholder:"Select filter"})}),a.jsxs(vt,{children:[a.jsx(Ae,{value:"all",children:h}),a.jsx(Ae,{value:"approved",children:w}),a.jsx(Ae,{value:"unapproved",children:b}),a.jsx(Ae,{value:"unknown",children:x})]})]}),a.jsxs(At,{onValueChange:y=>te(y),defaultValue:c,children:[a.jsx(bt,{className:"tw-m-1",children:a.jsx(Bt,{placeholder:"Select scope"})}),a.jsxs(vt,{children:[a.jsx(Ae,{value:"book",children:f}),a.jsx(Ae,{value:"chapter",children:m}),a.jsx(Ae,{value:"verse",children:S})]})]}),a.jsx(St,{className:"tw-m-1 tw-rounded-md tw-border",placeholder:R,value:U,onChange:y=>{C(y.target.value)}}),o&&a.jsxs("div",{className:"tw-m-1 tw-flex tw-items-center tw-rounded-md tw-border",children:[a.jsx(sr,{className:"tw-m-1",checked:E,onCheckedChange:y=>{k([]),v(y)}}),a.jsx(qe,{className:"tw-m-1 tw-flex-shrink-0 tw-whitespace-nowrap",children:(o==null?void 0:o.checkboxText)??j})]})]}),a.jsx("div",{className:"tw-m-1 tw-flex-1 tw-overflow-auto tw-rounded-md tw-border",children:a.jsx(_s,{columns:Y,data:J,onRowClickHandler:F,stickyHeader:!0})}),oe.length>0&&a.jsx("div",{className:"tw-m-1 tw-flex-1 tw-overflow-auto tw-rounded-md tw-border",children:a.jsx(vc,{occurrenceData:oe,setScriptureReference:t,localizedStrings:n})})]})}function As({onSearch:e,placeholder:t,isFullWidth:n}){const[r,o]=g.useState(""),s=i=>{o(i),e(i)};return a.jsx(St,{className:N("tw-flex tw-h-10 tw-rounded-md tw-border tw-border-input tw-bg-background tw-px-3 tw-py-2 tw-text-sm tw-ring-offset-background file:tw-border-0 file:tw-bg-transparent file:tw-text-sm file:tw-font-medium placeholder:tw-text-muted-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-[color:hsl(240,5%,64.9%)] focus-visible:tw-ring-offset-2 disabled:tw-cursor-not-allowed disabled:tw-opacity-50",{"tw-w-full":n}),placeholder:t,value:r,onChange:i=>s(i.target.value)})}const ho=g.forwardRef(({className:e,...t},n)=>a.jsx(_e.Root,{orientation:"vertical",ref:n,className:N("tw-flex tw-gap-1 tw-rounded-md tw-text-muted-foreground",e),...t}));ho.displayName=_e.List.displayName;const go=g.forwardRef(({className:e,...t},n)=>a.jsx(_e.List,{ref:n,className:N("tw-flex-fit tw-mlk-items-center tw-w-[124px] tw-justify-center tw-rounded-md tw-bg-muted tw-p-1 tw-text-muted-foreground",e),...t}));go.displayName=_e.List.displayName;const Bs=g.forwardRef(({className:e,...t},n)=>a.jsx(_e.Trigger,{ref:n,...t,className:N("overflow-clip tw-inline-flex tw-w-[116px] tw-cursor-pointer tw-items-center tw-justify-center tw-break-words tw-rounded-sm tw-border-0 tw-bg-muted tw-px-3 tw-py-1.5 tw-text-sm tw-font-medium tw-text-inherit tw-ring-offset-background tw-transition-all hover:tw-text-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50 data-[state=active]:tw-bg-background data-[state=active]:tw-text-foreground data-[state=active]:tw-shadow-sm",e)})),bo=g.forwardRef(({className:e,...t},n)=>a.jsx(_e.Content,{ref:n,className:N("tw-ms-5 tw-flex-grow tw-text-foreground tw-ring-offset-background focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2",e),...t}));bo.displayName=_e.Content.displayName;function Rc({tabList:e,onSearch:t,searchPlaceholder:n,headerTitle:r,isSearchBarFullWidth:o=!1,direction:s="ltr"}){return a.jsxs("div",{className:"pr-twp",children:[a.jsxs("div",{className:"tw-sticky tw-top-0 tw-space-y-2 tw-pb-2",children:[r?a.jsx("h1",{children:r}):"",a.jsx(As,{isFullWidth:o,onSearch:t,placeholder:n})]}),a.jsxs(ho,{dir:s,children:[a.jsx(go,{children:e.map(i=>a.jsx(Bs,{value:i.value,children:i.value},i.key))}),e.map(i=>a.jsx(bo,{value:i.value,children:i.content},i.key))]})]})}const lr=g.forwardRef(({className:e,orientation:t="horizontal",decorative:n=!0,...r},o)=>a.jsx(as.Root,{ref:o,decorative:n,orientation:t,className:N("pr-twp tw-shrink-0 tw-bg-border",t==="horizontal"?"tw-h-[1px] tw-w-full":"tw-h-full tw-w-[1px]",e),...r}));lr.displayName=as.Root.displayName;const Oc=be.Root,_c=be.Portal,Vs=M.forwardRef(({className:e,...t},n)=>a.jsx(be.Overlay,{className:N("tw-fixed tw-inset-0 tw-z-50 tw-bg-black/80 data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0",e),...t,ref:n}));Vs.displayName=be.Overlay.displayName;const Pc=Xt.cva("pr-twp tw-fixed tw-z-50 tw-gap-4 tw-bg-background tw-p-6 tw-shadow-lg tw-transition tw-ease-in-out data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-duration-300 data-[state=open]:tw-duration-500",{variants:{side:{top:"tw-inset-x-0 tw-top-0 tw-border-b data-[state=closed]:tw-slide-out-to-top data-[state=open]:tw-slide-in-from-top",bottom:"tw-inset-x-0 tw-bottom-0 tw-border-t data-[state=closed]:tw-slide-out-to-bottom data-[state=open]:tw-slide-in-from-bottom",left:"tw-inset-y-0 tw-left-0 tw-h-full tw-w-3/4 tw-border-r data-[state=closed]:tw-slide-out-to-left data-[state=open]:tw-slide-in-from-left sm:tw-max-w-sm",right:"tw-inset-y-0 tw-right-0 tw-h-full tw-w-3/4 tw- tw-border-l data-[state=closed]:tw-slide-out-to-right data-[state=open]:tw-slide-in-from-right sm:tw-max-w-sm"}},defaultVariants:{side:"right"}}),zs=M.forwardRef(({side:e="right",className:t,children:n,...r},o)=>a.jsxs(_c,{children:[a.jsx(Vs,{}),a.jsxs(be.Content,{ref:o,className:N(Pc({side:e}),t),...r,children:[n,a.jsxs(be.Close,{className:"tw-absolute tw-right-4 tw-top-4 tw-rounded-sm tw-opacity-70 tw-ring-offset-background tw-transition-opacity hover:tw-opacity-100 focus:tw-outline-none focus:tw-ring-2 focus:tw-ring-ring focus:tw-ring-offset-2 disabled:tw-pointer-events-none data-[state=open]:tw-bg-secondary",children:[a.jsx(Q.X,{className:"tw-h-4 tw-w-4"}),a.jsx("span",{className:"tw-sr-only",children:"Close"})]})]})]}));zs.displayName=be.Content.displayName;const Ic=M.forwardRef(({className:e,...t},n)=>a.jsx(be.Title,{ref:n,className:N("tw-text-lg tw-font-semibold tw-text-foreground",e),...t}));Ic.displayName=be.Title.displayName;const Mc=M.forwardRef(({className:e,...t},n)=>a.jsx(be.Description,{ref:n,className:N("tw-text-sm tw-text-muted-foreground",e),...t}));Mc.displayName=be.Description.displayName;function ca({className:e,...t}){return a.jsx("div",{className:N("pr-twp tw-animate-pulse tw-rounded-md tw-bg-muted",e),...t})}const $c=Sn.Provider,Dc=Sn.Root,Ac=Sn.Trigger,Ls=g.forwardRef(({className:e,sideOffset:t=4,...n},r)=>a.jsx(Sn.Content,{ref:r,sideOffset:t,className:N("pr-twp tw-z-50 tw-overflow-hidden tw-rounded-md tw-border tw-bg-popover tw-px-3 tw-py-1.5 tw-text-sm tw-text-popover-foreground tw-shadow-md tw-animate-in tw-fade-in-0 tw-zoom-in-95 data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=closed]:tw-zoom-out-95 data-[side=bottom]:tw-slide-in-from-top-2 data-[side=left]:tw-slide-in-from-right-2 data-[side=right]:tw-slide-in-from-left-2 data-[side=top]:tw-slide-in-from-bottom-2",e),...n}));Ls.displayName=Sn.Content.displayName;const Or=768;function Bc(){const[e,t]=M.useState(void 0);return M.useEffect(()=>{const n=window.matchMedia(`(max-width: ${Or-1}px)`),r=()=>{t(window.innerWidthn.removeEventListener("change",r)},[]),!!e}const Vc="sidebar:state",zc=60*60*24*7,Lc="16rem",Fc="18rem",Gc="3rem",Uc="b",Fs=g.createContext(void 0);function cr(){const e=g.useContext(Fs);if(!e)throw new Error("useSidebar must be used within a SidebarProvider.");return e}const Gs=g.forwardRef(({defaultOpen:e=!0,open:t,onOpenChange:n,className:r,style:o,children:s,...i},l)=>{const c=Bc(),[d,u]=g.useState(!1),[h,w]=g.useState(e),b=t??h,x=g.useCallback(R=>{const j=typeof R=="function"?R(b):R;n?n(j):w(j),document.cookie=`${Vc}=${j}; path=/; max-age=${zc}`},[n,b]),f=g.useCallback(()=>c?u(R=>!R):x(R=>!R),[c,x,u]);g.useEffect(()=>{const R=j=>{j.key===Uc&&(j.metaKey||j.ctrlKey)&&(j.preventDefault(),f())};return window.addEventListener("keydown",R),()=>window.removeEventListener("keydown",R)},[f]);const m=b?"expanded":"collapsed",S=g.useMemo(()=>({state:m,open:b,setOpen:x,isMobile:c,openMobile:d,setOpenMobile:u,toggleSidebar:f}),[m,b,x,c,d,u,f]);return a.jsx(Fs.Provider,{value:S,children:a.jsx($c,{delayDuration:0,children:a.jsx("div",{style:{"--sidebar-width":Lc,"--sidebar-width-icon":Gc,...o},className:N("tw-group/sidebar-wrapper pr-twp tw-flex tw-min-h-svh tw-w-full has-[[data-variant=inset]]:tw-bg-sidebar",r),ref:l,...i,children:s})})})});Gs.displayName="SidebarProvider";const Us=g.forwardRef(({side:e="left",variant:t="sidebar",collapsible:n="offcanvas",className:r,children:o,...s},i)=>{const{isMobile:l,state:c,openMobile:d,setOpenMobile:u}=cr();return n==="none"?a.jsx("div",{className:N("tw-flex tw-h-full tw-w-[--sidebar-width] tw-flex-col tw-bg-sidebar tw-text-sidebar-foreground",r),ref:i,...s,children:o}):l?a.jsx(Oc,{open:d,onOpenChange:u,...s,children:a.jsx(zs,{"data-sidebar":"sidebar","data-mobile":"true",className:"tw-w-[--sidebar-width] tw-bg-sidebar tw-p-0 tw-text-sidebar-foreground [&>button]:tw-hidden",style:{"--sidebar-width":Fc},side:e,children:a.jsx("div",{className:"tw-flex tw-h-full tw-w-full tw-flex-col",children:o})})}):a.jsxs("div",{ref:i,className:"tw-group tw-peer tw-hidden tw-text-sidebar-foreground md:tw-block","data-state":c,"data-collapsible":c==="collapsed"?n:"","data-variant":t,"data-side":e,children:[a.jsx("div",{className:N("tw-relative tw-h-svh tw-w-[--sidebar-width] tw-bg-transparent tw-transition-[width] tw-duration-200 tw-ease-linear","group-data-[collapsible=offcanvas]:tw-w-0","group-data-[side=right]:tw-rotate-180",t==="floating"||t==="inset"?"group-data-[collapsible=icon]:tw-w-[calc(var(--sidebar-width-icon)_+_theme(spacing.4))]":"group-data-[collapsible=icon]:tw-w-[--sidebar-width-icon]")}),a.jsx("div",{className:N("tw-absolute tw-inset-y-0 tw-z-10 tw-hidden tw-h-svh tw-w-[--sidebar-width] tw-transition-[left,right,width] tw-duration-200 tw-ease-linear md:tw-flex",e==="left"?"tw-left-0 group-data-[collapsible=offcanvas]:tw-left-[calc(var(--sidebar-width)*-1)]":"tw-right-0 group-data-[collapsible=offcanvas]:tw-right-[calc(var(--sidebar-width)*-1)]",t==="floating"||t==="inset"?"tw-p-2 group-data-[collapsible=icon]:tw-w-[calc(var(--sidebar-width-icon)_+_theme(spacing.4)_+2px)]":"group-data-[collapsible=icon]:tw-w-[--sidebar-width-icon] group-data-[side=left]:tw-border-r group-data-[side=right]:tw-border-l",r),...s,children:a.jsx("div",{"data-sidebar":"sidebar",className:"tw-flex tw-h-full tw-w-full tw-flex-col tw-bg-sidebar group-data-[variant=floating]:tw-rounded-lg group-data-[variant=floating]:tw-border group-data-[variant=floating]:tw-border-sidebar-border group-data-[variant=floating]:tw-shadow",children:o})})]})});Us.displayName="Sidebar";const qc=g.forwardRef(({className:e,onClick:t,...n},r)=>{const{toggleSidebar:o}=cr();return a.jsxs(fe,{ref:r,"data-sidebar":"trigger",variant:"ghost",size:"icon",className:N("tw-h-7 tw-w-7",e),onClick:s=>{t==null||t(s),o()},...n,children:[a.jsx(Q.PanelLeft,{}),a.jsx("span",{className:"tw-sr-only",children:"Toggle Sidebar"})]})});qc.displayName="SidebarTrigger";const Hc=g.forwardRef(({className:e,...t},n)=>{const{toggleSidebar:r}=cr();return a.jsx("button",{type:"button",ref:n,"data-sidebar":"rail","aria-label":"Toggle Sidebar",tabIndex:-1,onClick:r,title:"Toggle Sidebar",className:N("tw-absolute tw-inset-y-0 tw-z-20 tw-hidden tw-w-4 tw--translate-x-1/2 tw-transition-all tw-ease-linear after:tw-absolute after:tw-inset-y-0 after:tw-left-1/2 after:tw-w-[2px] hover:after:tw-bg-sidebar-border group-data-[side=left]:tw--right-4 group-data-[side=right]:tw-left-0 sm:tw-flex","[[data-side=left]_&]:tw-cursor-w-resize [[data-side=right]_&]:tw-cursor-e-resize","[[data-side=left][data-state=collapsed]_&]:tw-cursor-e-resize [[data-side=right][data-state=collapsed]_&]:tw-cursor-w-resize","group-data-[collapsible=offcanvas]:tw-translate-x-0 group-data-[collapsible=offcanvas]:after:tw-left-full group-data-[collapsible=offcanvas]:hover:tw-bg-sidebar","[[data-side=left][data-collapsible=offcanvas]_&]:tw--right-2","[[data-side=right][data-collapsible=offcanvas]_&]:tw--left-2",e),...t})});Hc.displayName="SidebarRail";const qs=g.forwardRef(({className:e,...t},n)=>a.jsx("main",{ref:n,className:N("tw-relative tw-flex tw-min-h-svh tw-flex-1 tw-flex-col tw-bg-background","peer-data-[variant=inset]:tw-min-h-[calc(100svh-theme(spacing.4))] md:peer-data-[variant=inset]:tw-m-2 md:peer-data-[state=collapsed]:peer-data-[variant=inset]:tw-ml-2 md:peer-data-[variant=inset]:tw-ml-0 md:peer-data-[variant=inset]:tw-rounded-xl md:peer-data-[variant=inset]:tw-shadow",e),...t}));qs.displayName="SidebarInset";const Xc=g.forwardRef(({className:e,...t},n)=>a.jsx(St,{ref:n,"data-sidebar":"input",className:N("tw-h-8 tw-w-full tw-bg-background tw-shadow-none focus-visible:tw-ring-2 focus-visible:tw-ring-sidebar-ring",e),...t}));Xc.displayName="SidebarInput";const Yc=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,"data-sidebar":"header",className:N("tw-flex tw-flex-col tw-gap-2 tw-p-2",e),...t}));Yc.displayName="SidebarHeader";const Wc=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,"data-sidebar":"footer",className:N("tw-flex tw-flex-col tw-gap-2 tw-p-2",e),...t}));Wc.displayName="SidebarFooter";const Kc=g.forwardRef(({className:e,...t},n)=>a.jsx(lr,{ref:n,"data-sidebar":"separator",className:N("tw-mx-2 tw-w-auto tw-bg-sidebar-border",e),...t}));Kc.displayName="SidebarSeparator";const Hs=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,"data-sidebar":"content",className:N("tw-flex tw-min-h-0 tw-flex-1 tw-flex-col tw-gap-2 tw-overflow-auto group-data-[collapsible=icon]:tw-overflow-hidden",e),...t}));Hs.displayName="SidebarContent";const Xr=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,"data-sidebar":"group",className:N("tw-relative tw-flex tw-w-full tw-min-w-0 tw-flex-col tw-p-2",e),...t}));Xr.displayName="SidebarGroup";const Yr=g.forwardRef(({className:e,asChild:t=!1,...n},r)=>{const o=t?Ht.Slot:"div";return a.jsx(o,{ref:r,"data-sidebar":"group-label",className:N("tw-flex tw-h-8 tw-shrink-0 tw-items-center tw-rounded-md tw-px-2 tw-text-xs tw-font-medium tw-text-sidebar-foreground/70 tw-outline-none tw-ring-sidebar-ring tw-transition-[margin,opa] tw-duration-200 tw-ease-linear focus-visible:tw-ring-2 [&>svg]:tw-size-4 [&>svg]:tw-shrink-0","group-data-[collapsible=icon]:tw--mt-8 group-data-[collapsible=icon]:tw-opacity-0",e),...n})});Yr.displayName="SidebarGroupLabel";const Jc=g.forwardRef(({className:e,asChild:t=!1,...n},r)=>{const o=t?Ht.Slot:"button";return a.jsx(o,{ref:r,"data-sidebar":"group-action",className:N("tw-absolute tw-right-3 tw-top-3.5 tw-flex tw-aspect-square tw-w-5 tw-items-center tw-justify-center tw-rounded-md tw-p-0 tw-text-sidebar-foreground tw-outline-none tw-ring-sidebar-ring tw-transition-transform hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground focus-visible:tw-ring-2 [&>svg]:tw-size-4 [&>svg]:tw-shrink-0","after:tw-absolute after:tw--inset-2 after:md:tw-hidden","group-data-[collapsible=icon]:tw-hidden",e),...n})});Jc.displayName="SidebarGroupAction";const Wr=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,"data-sidebar":"group-content",className:N("tw-w-full tw-text-sm",e),...t}));Wr.displayName="SidebarGroupContent";const Xs=g.forwardRef(({className:e,...t},n)=>a.jsx("ul",{ref:n,"data-sidebar":"menu",className:N("tw-flex tw-w-full tw-min-w-0 tw-flex-col tw-gap-1",e),...t}));Xs.displayName="SidebarMenu";const Ys=g.forwardRef(({className:e,...t},n)=>a.jsx("li",{ref:n,"data-sidebar":"menu-item",className:N("tw-group/menu-item tw-relative",e),...t}));Ys.displayName="SidebarMenuItem";const Zc=Xt.cva("tw-peer/menu-button tw-flex tw-w-full tw-items-center tw-gap-2 tw-overflow-hidden tw-rounded-md tw-p-2 tw-text-left tw-text-sm tw-outline-none tw-ring-sidebar-ring tw-transition-[width,height,padding] hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground focus-visible:tw-ring-2 active:tw-bg-sidebar-accent active:tw-text-sidebar-accent-foreground disabled:tw-pointer-events-none disabled:tw-opacity-50 tw-group-has-[[data-sidebar=menu-action]]/menu-item:pr-8 aria-disabled:tw-pointer-events-none aria-disabled:tw-opacity-50 data-[active=true]:tw-bg-sidebar-accent data-[active=true]:tw-font-medium data-[active=true]:tw-text-sidebar-accent-foreground data-[state=open]:hover:tw-bg-sidebar-accent data-[state=open]:hover:tw-text-sidebar-accent-foreground group-data-[collapsible=icon]:tw-!size-8 group-data-[collapsible=icon]:tw-!p-2 [&>span:last-child]:tw-truncate [&>svg]:tw-size-4 [&>svg]:tw-shrink-0",{variants:{variant:{default:"hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground",outline:"tw-bg-background tw-shadow-[0_0_0_1px_hsl(var(--sidebar-border))] hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground hover:tw-shadow-[0_0_0_1px_hsl(var(--sidebar-accent))]"},size:{default:"tw-h-8 tw-text-sm",sm:"tw-h-7 tw-text-xs",lg:"tw-h-12 tw-text-sm group-data-[collapsible=icon]:tw-!p-0"}},defaultVariants:{variant:"default",size:"default"}}),Ws=g.forwardRef(({asChild:e=!1,isActive:t=!1,variant:n="default",size:r="default",tooltip:o,className:s,...i},l)=>{const c=e?Ht.Slot:"button",{isMobile:d,state:u}=cr(),h=a.jsx(c,{ref:l,"data-sidebar":"menu-button","data-size":r,"data-active":t,className:N(Zc({variant:n,size:r}),s),...i});return o?(typeof o=="string"&&(o={children:o}),a.jsxs(Dc,{children:[a.jsx(Ac,{asChild:!0,children:h}),a.jsx(Ls,{side:"right",align:"center",hidden:u!=="collapsed"||d,...o})]})):h});Ws.displayName="SidebarMenuButton";const Qc=g.forwardRef(({className:e,asChild:t=!1,showOnHover:n=!1,...r},o)=>{const s=t?Ht.Slot:"button";return a.jsx(s,{ref:o,"data-sidebar":"menu-action",className:N("tw-peer-hover/menu-button:text-sidebar-accent-foreground tw-absolute tw-right-1 tw-top-1.5 tw-flex tw-aspect-square tw-w-5 tw-items-center tw-justify-center tw-rounded-md tw-p-0 tw-text-sidebar-foreground tw-outline-none tw-ring-sidebar-ring tw-transition-transform hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground focus-visible:tw-ring-2 [&>svg]:tw-size-4 [&>svg]:tw-shrink-0","after:tw-absolute after:tw--inset-2 after:md:tw-hidden","tw-peer-data-[size=sm]/menu-button:top-1","tw-peer-data-[size=default]/menu-button:top-1.5","tw-peer-data-[size=lg]/menu-button:top-2.5","group-data-[collapsible=icon]:tw-hidden",n&&"tw-group-focus-within/menu-item:opacity-100 tw-group-hover/menu-item:opacity-100 tw-peer-data-[active=true]/menu-button:text-sidebar-accent-foreground data-[state=open]:tw-opacity-100 md:tw-opacity-0",e),...r})});Qc.displayName="SidebarMenuAction";const ed=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,"data-sidebar":"menu-badge",className:N("tw-pointer-events-none tw-absolute tw-right-1 tw-flex tw-h-5 tw-min-w-5 tw-select-none tw-items-center tw-justify-center tw-rounded-md tw-px-1 tw-text-xs tw-font-medium tw-tabular-nums tw-text-sidebar-foreground","tw-peer-hover/menu-button:text-sidebar-accent-foreground tw-peer-data-[active=true]/menu-button:text-sidebar-accent-foreground","tw-peer-data-[size=sm]/menu-button:top-1","tw-peer-data-[size=default]/menu-button:top-1.5","tw-peer-data-[size=lg]/menu-button:top-2.5","group-data-[collapsible=icon]:tw-hidden",e),...t}));ed.displayName="SidebarMenuBadge";const td=g.forwardRef(({className:e,showIcon:t=!1,...n},r)=>{const o=g.useMemo(()=>`${Math.floor(Math.random()*40)+50}%`,[]);return a.jsxs("div",{ref:r,"data-sidebar":"menu-skeleton",className:N("tw-flex tw-h-8 tw-items-center tw-gap-2 tw-rounded-md tw-px-2",e),...n,children:[t&&a.jsx(ca,{className:"tw-size-4 tw-rounded-md","data-sidebar":"menu-skeleton-icon"}),a.jsx(ca,{className:"tw-h-4 tw-max-w-[--skeleton-width] tw-flex-1","data-sidebar":"menu-skeleton-text",style:{"--skeleton-width":o}})]})});td.displayName="SidebarMenuSkeleton";const nd=g.forwardRef(({className:e,...t},n)=>a.jsx("ul",{ref:n,"data-sidebar":"menu-sub",className:N("tw-mx-3.5 tw-flex tw-min-w-0 tw-translate-x-px tw-flex-col tw-gap-1 tw-border-l tw-border-sidebar-border tw-px-2.5 tw-py-0.5","group-data-[collapsible=icon]:tw-hidden",e),...t}));nd.displayName="SidebarMenuSub";const rd=g.forwardRef(({...e},t)=>a.jsx("li",{ref:t,...e}));rd.displayName="SidebarMenuSubItem";const od=g.forwardRef(({asChild:e=!1,size:t="md",isActive:n,className:r,...o},s)=>{const i=e?Ht.Slot:"a";return a.jsx(i,{ref:s,"data-sidebar":"menu-sub-button","data-size":t,"data-active":n,className:N("tw-flex tw-h-7 tw-min-w-0 tw--translate-x-px tw-items-center tw-gap-2 tw-overflow-hidden tw-rounded-md tw-px-2 tw-text-sidebar-foreground tw-outline-none tw-ring-sidebar-ring hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground focus-visible:tw-ring-2 active:tw-bg-sidebar-accent active:tw-text-sidebar-accent-foreground disabled:tw-pointer-events-none disabled:tw-opacity-50 aria-disabled:tw-pointer-events-none aria-disabled:tw-opacity-50 [&>span:last-child]:tw-truncate [&>svg]:tw-size-4 [&>svg]:tw-shrink-0 [&>svg]:tw-text-sidebar-accent-foreground","data-[active=true]:tw-bg-sidebar-accent data-[active=true]:tw-text-sidebar-accent-foreground",t==="sm"&&"tw-text-xs",t==="md"&&"tw-text-sm","group-data-[collapsible=icon]:tw-hidden",r),...o})});od.displayName="SidebarMenuSubButton";function Ks({id:e,extensionLabels:t,projectOptions:n,handleSelectSidebarItem:r,selectedSidebarItem:o}){const s=g.useCallback((l,c)=>{r(l,c)},[r]),i=g.useCallback(l=>{const c=n.find(d=>d.projectId===l);return c?c.projectName:l},[n]);return a.jsx(Us,{id:e,collapsible:"offcanvas",variant:"sidebar",children:a.jsxs(Hs,{children:[a.jsxs(Xr,{children:[a.jsx(Yr,{children:"Extensions"}),a.jsx(Wr,{children:a.jsx(Xs,{children:t.map(l=>a.jsx(Ys,{children:a.jsx(Ws,{onClick:()=>s(l),isActive:!(o!=null&&o.projectId)&&l===(o==null?void 0:o.label),children:l})},l))})})]}),a.jsxs(Xr,{children:[a.jsx(Yr,{children:"Projects"}),a.jsx(Wr,{children:a.jsx(Wn,{popoverContentClassName:"tw-z-[1000]",options:n.flatMap(l=>l.projectId),getOptionLabel:l=>i(l),buttonPlaceholder:"Type or select project",onChange:l=>{const c=i(l);s(c,l)},value:(o==null?void 0:o.projectId)??void 0})})]})]})})}function ad({id:e,direction:t="ltr",extensionLabels:n,projectOptions:r,children:o,handleSelectSidebarItem:s,selectedSidebarItem:i}){return a.jsxs(Gs,{dir:t,id:e,children:[a.jsx(Ks,{extensionLabels:n,projectOptions:r,handleSelectSidebarItem:s,selectedSidebarItem:i}),a.jsx(qs,{children:o})]})}const rt="scrBook",sd="scrRef",pt="source",id="details",ld="Scripture Reference",cd="Scripture Book",Js="Type",dd="Details";function ud(e,t){const n=t??!1;return[{accessorFn:r=>`${ae.bookNumberToId(r.start.bookNum)} ${r.start.chapterNum}:${r.start.verseNum}`,id:rt,header:(e==null?void 0:e.scriptureReferenceColumnName)??ld,cell:r=>{const o=r.row.original;return r.row.getIsGrouped()?ae.bookNumberToEnglishName(o.start.bookNum):r.row.groupingColumnId===rt?W.formatScrRef(o.start):void 0},getGroupingValue:r=>r.start.bookNum,sortingFn:(r,o)=>W.compareScrRefs(r.original.start,o.original.start),enableGrouping:!0},{accessorFn:r=>W.formatScrRef(r.start),id:sd,header:void 0,cell:r=>{const o=r.row.original;return r.row.getIsGrouped()?void 0:W.formatScrRef(o.start)},sortingFn:(r,o)=>W.compareScrRefs(r.original.start,o.original.start),enableGrouping:!1},{accessorFn:r=>r.source.displayName,id:pt,header:n?(e==null?void 0:e.typeColumnName)??Js:void 0,cell:r=>n||r.row.getIsGrouped()?r.getValue():void 0,getGroupingValue:r=>r.source.id,sortingFn:(r,o)=>r.original.source.displayName.localeCompare(o.original.source.displayName),enableGrouping:!0},{accessorFn:r=>r.detail,id,header:(e==null?void 0:e.detailsColumnName)??dd,cell:r=>r.getValue(),enableGrouping:!1}]}const pd=e=>{if(!("offset"in e.start))throw new Error("No offset available in range start");if(e.end&&!("offset"in e.end))throw new Error("No offset available in range end");const{offset:t}=e.start;let n=0;return e.end&&({offset:n}=e.end),!e.end||W.compareScrRefs(e.start,e.end)===0?`${W.scrRefToBBBCCCVVV(e.start)}+${t}`:`${W.scrRefToBBBCCCVVV(e.start)}+${t}-${W.scrRefToBBBCCCVVV(e.end)}+${n}`},da=e=>`${pd({start:e.start,end:e.end})} ${e.source.displayName} ${e.detail}`;function wd({sources:e,showColumnHeaders:t=!1,showSourceColumn:n=!1,scriptureReferenceColumnName:r,scriptureBookGroupName:o,typeColumnName:s,detailsColumnName:i,onRowSelected:l,direction:c="ltr"}){const[d,u]=g.useState([]),[h,w]=g.useState([{id:rt,desc:!1}]),[b,x]=g.useState({}),f=g.useMemo(()=>e.flatMap(C=>C.data.map(_=>({..._,source:C.source}))),[e]),m=g.useMemo(()=>ud({scriptureReferenceColumnName:r,typeColumnName:s,detailsColumnName:i},n),[r,s,i,n]);g.useEffect(()=>{d.includes(pt)?w([{id:pt,desc:!1},{id:rt,desc:!1}]):w([{id:rt,desc:!1}])},[d]);const S=Se.useReactTable({data:f,columns:m,state:{grouping:d,sorting:h,rowSelection:b},onGroupingChange:u,onSortingChange:w,onRowSelectionChange:x,getExpandedRowModel:Se.getExpandedRowModel(),getGroupedRowModel:Se.getGroupedRowModel(),getCoreRowModel:Se.getCoreRowModel(),getSortedRowModel:Se.getSortedRowModel(),getRowId:da,autoResetExpanded:!1,enableMultiRowSelection:!1,enableSubRowSelection:!1});g.useEffect(()=>{if(l){const C=S.getSelectedRowModel().rowsById,_=Object.keys(C);if(_.length===1){const k=f.find(D=>da(D)===_[0])||void 0;k&&l(k)}}},[b,f,l,S]);const R=o??cd,j=s??Js,E=[{label:"No Grouping",value:[]},{label:`Group by ${R}`,value:[rt]},{label:`Group by ${j}`,value:[pt]},{label:`Group by ${R} and ${j}`,value:[rt,pt]},{label:`Group by ${j} and ${R}`,value:[pt,rt]}],v=C=>{u(JSON.parse(C))},P=(C,_)=>{!C.getIsGrouped()&&!C.getIsSelected()&&C.getToggleSelectedHandler()(_)},V=(C,_)=>C.getIsGrouped()?"":N("banded-row",_%2===0?"even":"odd"),U=(C,_,k)=>{if(!((C==null?void 0:C.length)===0||_.depth{v(C)},children:[a.jsx(bt,{className:"tw-mb-1 tw-mt-2",children:a.jsx(Bt,{})}),a.jsx(vt,{position:"item-aligned",children:a.jsx(js,{children:E.map(C=>a.jsx(Ae,{value:JSON.stringify(C.value),children:C.label},C.label))})})]}),a.jsxs(Cn,{className:"tw-relative tw-flex tw-flex-col tw-overflow-y-auto tw-p-0",children:[t&&a.jsx(Tn,{children:S.getHeaderGroups().map(C=>a.jsx(Ze,{children:C.headers.filter(_=>_.column.columnDef.header).map(_=>a.jsx(Vt,{colSpan:_.colSpan,className:"top-0 tw-sticky",children:_.isPlaceholder?void 0:a.jsxs("div",{children:[_.column.getCanGroup()?a.jsx(fe,{variant:"ghost",title:`Toggle grouping by ${_.column.columnDef.header}`,onClick:_.column.getToggleGroupingHandler(),type:"button",children:_.column.getIsGrouped()?"🛑":"👊 "}):void 0," ",Se.flexRender(_.column.columnDef.header,_.getContext())]})},_.id))},C.id))}),a.jsx(Rn,{children:S.getRowModel().rows.map((C,_)=>a.jsx(Ze,{"data-state":C.getIsSelected()?"selected":"",className:N(V(C,_)),onClick:k=>P(C,k),children:C.getVisibleCells().map(k=>{if(!(k.getIsPlaceholder()||k.column.columnDef.enableGrouping&&!k.getIsGrouped()&&(k.column.columnDef.id!==pt||!n)))return a.jsx(xt,{className:N(k.column.columnDef.id,"tw-p-[1px]",U(d,C,k)),children:(()=>k.getIsGrouped()?a.jsxs(fe,{variant:"link",onClick:C.getToggleExpandedHandler(),type:"button",children:[C.getIsExpanded()&&a.jsx(Q.ChevronDown,{}),!C.getIsExpanded()&&(c==="ltr"?a.jsx(Q.ChevronRight,{}):a.jsx(Q.ChevronLeft,{}))," ",Se.flexRender(k.column.columnDef.cell,k.getContext())," (",C.subRows.length,")"]}):Se.flexRender(k.column.columnDef.cell,k.getContext()))()},k.id)})},C.id))})]})]})}const _r={[W.getLocalizeKeyForScrollGroupId("undefined")]:"Ø",[W.getLocalizeKeyForScrollGroupId(0)]:"A",[W.getLocalizeKeyForScrollGroupId(1)]:"B",[W.getLocalizeKeyForScrollGroupId(2)]:"C",[W.getLocalizeKeyForScrollGroupId(3)]:"D",[W.getLocalizeKeyForScrollGroupId(4)]:"E",[W.getLocalizeKeyForScrollGroupId(5)]:"F",[W.getLocalizeKeyForScrollGroupId(6)]:"G",[W.getLocalizeKeyForScrollGroupId(7)]:"H",[W.getLocalizeKeyForScrollGroupId(8)]:"I",[W.getLocalizeKeyForScrollGroupId(9)]:"J",[W.getLocalizeKeyForScrollGroupId(10)]:"K",[W.getLocalizeKeyForScrollGroupId(11)]:"L",[W.getLocalizeKeyForScrollGroupId(12)]:"M",[W.getLocalizeKeyForScrollGroupId(13)]:"N",[W.getLocalizeKeyForScrollGroupId(14)]:"O",[W.getLocalizeKeyForScrollGroupId(15)]:"P",[W.getLocalizeKeyForScrollGroupId(16)]:"Q",[W.getLocalizeKeyForScrollGroupId(17)]:"R",[W.getLocalizeKeyForScrollGroupId(18)]:"S",[W.getLocalizeKeyForScrollGroupId(19)]:"T",[W.getLocalizeKeyForScrollGroupId(20)]:"U",[W.getLocalizeKeyForScrollGroupId(21)]:"V",[W.getLocalizeKeyForScrollGroupId(22)]:"W",[W.getLocalizeKeyForScrollGroupId(23)]:"X",[W.getLocalizeKeyForScrollGroupId(24)]:"Y",[W.getLocalizeKeyForScrollGroupId(25)]:"Z"};function fd({availableScrollGroupIds:e,scrollGroupId:t,onChangeScrollGroupId:n,localizedStrings:r={}}){const o={..._r,...Object.fromEntries(Object.entries(r).map(([s,i])=>[s,s===i&&s in _r?_r[s]:i]))};return a.jsxs(At,{value:`${t}`,onValueChange:s=>n(s==="undefined"?void 0:parseInt(s,10)),children:[a.jsx(bt,{className:"pr-twp tw-w-auto",children:a.jsx(Bt,{placeholder:o[W.getLocalizeKeyForScrollGroupId(t)]??t})}),a.jsx(vt,{style:{zIndex:250},children:e.map(s=>a.jsx(Ae,{value:`${s}`,children:o[W.getLocalizeKeyForScrollGroupId(s)]},`${s}`))})]})}function md({children:e}){return a.jsx("div",{className:"pr-twp tw-grid",children:e})}function hd({primary:e,secondary:t,children:n,isLoading:r=!1,loadingMessage:o}){return a.jsxs("div",{className:"tw-flex tw-items-center tw-justify-between tw-space-x-4 tw-py-2",children:[a.jsxs("div",{children:[a.jsx("p",{className:"tw-text-sm tw-font-medium tw-leading-none",children:e}),a.jsx("p",{className:"tw-whitespace-normal tw-break-words tw-text-sm tw-text-muted-foreground",children:t})]}),r?a.jsx("p",{className:"tw-text-sm tw-text-muted-foreground",children:o}):a.jsx("div",{children:n})]})}function gd({primary:e,secondary:t,includeSeparator:n=!1}){return a.jsxs("div",{className:"tw-space-y-4 tw-py-2",children:[a.jsxs("div",{children:[a.jsx("h3",{className:"tw-text-lg tw-font-medium",children:e}),a.jsx("p",{className:"tw-text-sm tw-text-muted-foreground",children:t})]}),n?a.jsx(lr,{}):""]})}const vo=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,className:N("pr-twp tw-rounded-lg tw-border tw-bg-card tw-text-card-foreground tw-shadow-sm",e),...t}));vo.displayName="Card";const xo=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,className:N("pr-twp tw-flex tw-flex-col tw-space-y-1.5 tw-p-6",e),...t}));xo.displayName="CardHeader";const yo=g.forwardRef(({className:e,...t},n)=>a.jsx("h3",{ref:n,className:N("pr-twp tw-text-2xl tw-font-semibold tw-leading-none tw-tracking-tight",e),...t,children:t.children}));yo.displayName="CardTitle";const No=g.forwardRef(({className:e,...t},n)=>a.jsx("p",{ref:n,className:N("pr-twp tw-text-sm tw-text-muted-foreground",e),...t}));No.displayName="CardDescription";const Zs=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,className:N("pr-twp tw-p-6 tw-pt-0",e),...t}));Zs.displayName="CardContent";const Qs=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,className:N("pr-twp tw-flex tw-items-center tw-p-6 tw-pt-0",e),...t}));Qs.displayName="CardFooter";function bd({id:e,settingsGroupLabel:t,settingsGroupDescription:n,children:r}){return a.jsxs(vo,{id:e,children:[a.jsxs(xo,{children:[a.jsx(yo,{children:t}),n&&a.jsx(No,{children:n})]}),a.jsx(Ce.CardContent,{className:"tw-space-y-4",children:r})]})}function vd({id:e,className:t,listItems:n,selectedListItems:r,handleSelectListItem:o,createLabel:s}){return a.jsx("div",{id:e,className:t,children:n.map(i=>a.jsxs("div",{className:"tw-m-2 tw-flex tw-items-center",children:[a.jsx(sr,{className:"tw-mr-2 tw-align-middle",checked:r.includes(i),onCheckedChange:l=>o(i,l)}),a.jsx(qe,{children:s?s(i):i})]},i))})}function xd(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}function yd(e){if(e.__esModule)return e;var t=e.default;if(typeof t=="function"){var n=function r(){return this instanceof r?Reflect.construct(t,arguments,this.constructor):t.apply(this,arguments)};n.prototype=t.prototype}else n={};return Object.defineProperty(n,"__esModule",{value:!0}),Object.keys(e).forEach(function(r){var o=Object.getOwnPropertyDescriptor(e,r);Object.defineProperty(n,r,o.get?o:{enumerable:!0,get:function(){return e[r]}})}),n}var ko={},ei={exports:{}};(function(e){function t(n){return n&&n.__esModule?n:{default:n}}e.exports=t,e.exports.__esModule=!0,e.exports.default=e.exports})(ei);var Nd=ei.exports,Pr={};function So(e,t){return process.env.NODE_ENV==="production"?()=>null:function(...r){return e(...r)||t(...r)}}function O(){return O=Object.assign?Object.assign.bind():function(e){for(var t=1;t{t[n]=ti(e[n])}),t}function Qe(e,t,n={clone:!0}){const r=n.clone?O({},e):e;return mt(e)&&mt(t)&&Object.keys(t).forEach(o=>{o!=="__proto__"&&(mt(t[o])&&o in e&&mt(e[o])?r[o]=Qe(e[o],t[o],n):n.clone?r[o]=mt(t[o])?ti(t[o]):t[o]:r[o]=t[o])}),r}var Kr={exports:{}},zn={exports:{}},ie={};/** @license React v16.13.1 * react-is.production.min.js * * Copyright (c) Facebook, Inc. and its affiliates. * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. - */var la;function kd(){if(la)return ie;la=1;var e=typeof Symbol=="function"&&Symbol.for,t=e?Symbol.for("react.element"):60103,n=e?Symbol.for("react.portal"):60106,r=e?Symbol.for("react.fragment"):60107,o=e?Symbol.for("react.strict_mode"):60108,s=e?Symbol.for("react.profiler"):60114,i=e?Symbol.for("react.provider"):60109,l=e?Symbol.for("react.context"):60110,c=e?Symbol.for("react.async_mode"):60111,d=e?Symbol.for("react.concurrent_mode"):60111,u=e?Symbol.for("react.forward_ref"):60112,m=e?Symbol.for("react.suspense"):60113,w=e?Symbol.for("react.suspense_list"):60120,b=e?Symbol.for("react.memo"):60115,x=e?Symbol.for("react.lazy"):60116,f=e?Symbol.for("react.block"):60121,h=e?Symbol.for("react.fundamental"):60117,S=e?Symbol.for("react.responder"):60118,R=e?Symbol.for("react.scope"):60119;function j(v){if(typeof v=="object"&&v!==null){var P=v.$$typeof;switch(P){case t:switch(v=v.type,v){case c:case d:case r:case s:case o:case m:return v;default:switch(v=v&&v.$$typeof,v){case l:case u:case x:case b:case i:return v;default:return P}}case n:return P}}}function E(v){return j(v)===d}return ie.AsyncMode=c,ie.ConcurrentMode=d,ie.ContextConsumer=l,ie.ContextProvider=i,ie.Element=t,ie.ForwardRef=u,ie.Fragment=r,ie.Lazy=x,ie.Memo=b,ie.Portal=n,ie.Profiler=s,ie.StrictMode=o,ie.Suspense=m,ie.isAsyncMode=function(v){return E(v)||j(v)===c},ie.isConcurrentMode=E,ie.isContextConsumer=function(v){return j(v)===l},ie.isContextProvider=function(v){return j(v)===i},ie.isElement=function(v){return typeof v=="object"&&v!==null&&v.$$typeof===t},ie.isForwardRef=function(v){return j(v)===u},ie.isFragment=function(v){return j(v)===r},ie.isLazy=function(v){return j(v)===x},ie.isMemo=function(v){return j(v)===b},ie.isPortal=function(v){return j(v)===n},ie.isProfiler=function(v){return j(v)===s},ie.isStrictMode=function(v){return j(v)===o},ie.isSuspense=function(v){return j(v)===m},ie.isValidElementType=function(v){return typeof v=="string"||typeof v=="function"||v===r||v===d||v===s||v===o||v===m||v===w||typeof v=="object"&&v!==null&&(v.$$typeof===x||v.$$typeof===b||v.$$typeof===i||v.$$typeof===l||v.$$typeof===u||v.$$typeof===h||v.$$typeof===S||v.$$typeof===R||v.$$typeof===f)},ie.typeOf=j,ie}var le={};/** @license React v16.13.1 + */var ua;function kd(){if(ua)return ie;ua=1;var e=typeof Symbol=="function"&&Symbol.for,t=e?Symbol.for("react.element"):60103,n=e?Symbol.for("react.portal"):60106,r=e?Symbol.for("react.fragment"):60107,o=e?Symbol.for("react.strict_mode"):60108,s=e?Symbol.for("react.profiler"):60114,i=e?Symbol.for("react.provider"):60109,l=e?Symbol.for("react.context"):60110,c=e?Symbol.for("react.async_mode"):60111,d=e?Symbol.for("react.concurrent_mode"):60111,u=e?Symbol.for("react.forward_ref"):60112,h=e?Symbol.for("react.suspense"):60113,w=e?Symbol.for("react.suspense_list"):60120,b=e?Symbol.for("react.memo"):60115,x=e?Symbol.for("react.lazy"):60116,f=e?Symbol.for("react.block"):60121,m=e?Symbol.for("react.fundamental"):60117,S=e?Symbol.for("react.responder"):60118,R=e?Symbol.for("react.scope"):60119;function j(v){if(typeof v=="object"&&v!==null){var P=v.$$typeof;switch(P){case t:switch(v=v.type,v){case c:case d:case r:case s:case o:case h:return v;default:switch(v=v&&v.$$typeof,v){case l:case u:case x:case b:case i:return v;default:return P}}case n:return P}}}function E(v){return j(v)===d}return ie.AsyncMode=c,ie.ConcurrentMode=d,ie.ContextConsumer=l,ie.ContextProvider=i,ie.Element=t,ie.ForwardRef=u,ie.Fragment=r,ie.Lazy=x,ie.Memo=b,ie.Portal=n,ie.Profiler=s,ie.StrictMode=o,ie.Suspense=h,ie.isAsyncMode=function(v){return E(v)||j(v)===c},ie.isConcurrentMode=E,ie.isContextConsumer=function(v){return j(v)===l},ie.isContextProvider=function(v){return j(v)===i},ie.isElement=function(v){return typeof v=="object"&&v!==null&&v.$$typeof===t},ie.isForwardRef=function(v){return j(v)===u},ie.isFragment=function(v){return j(v)===r},ie.isLazy=function(v){return j(v)===x},ie.isMemo=function(v){return j(v)===b},ie.isPortal=function(v){return j(v)===n},ie.isProfiler=function(v){return j(v)===s},ie.isStrictMode=function(v){return j(v)===o},ie.isSuspense=function(v){return j(v)===h},ie.isValidElementType=function(v){return typeof v=="string"||typeof v=="function"||v===r||v===d||v===s||v===o||v===h||v===w||typeof v=="object"&&v!==null&&(v.$$typeof===x||v.$$typeof===b||v.$$typeof===i||v.$$typeof===l||v.$$typeof===u||v.$$typeof===m||v.$$typeof===S||v.$$typeof===R||v.$$typeof===f)},ie.typeOf=j,ie}var le={};/** @license React v16.13.1 * react-is.development.js * * Copyright (c) Facebook, Inc. and its affiliates. * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. - */var ca;function Sd(){return ca||(ca=1,process.env.NODE_ENV!=="production"&&function(){var e=typeof Symbol=="function"&&Symbol.for,t=e?Symbol.for("react.element"):60103,n=e?Symbol.for("react.portal"):60106,r=e?Symbol.for("react.fragment"):60107,o=e?Symbol.for("react.strict_mode"):60108,s=e?Symbol.for("react.profiler"):60114,i=e?Symbol.for("react.provider"):60109,l=e?Symbol.for("react.context"):60110,c=e?Symbol.for("react.async_mode"):60111,d=e?Symbol.for("react.concurrent_mode"):60111,u=e?Symbol.for("react.forward_ref"):60112,m=e?Symbol.for("react.suspense"):60113,w=e?Symbol.for("react.suspense_list"):60120,b=e?Symbol.for("react.memo"):60115,x=e?Symbol.for("react.lazy"):60116,f=e?Symbol.for("react.block"):60121,h=e?Symbol.for("react.fundamental"):60117,S=e?Symbol.for("react.responder"):60118,R=e?Symbol.for("react.scope"):60119;function j(I){return typeof I=="string"||typeof I=="function"||I===r||I===d||I===s||I===o||I===m||I===w||typeof I=="object"&&I!==null&&(I.$$typeof===x||I.$$typeof===b||I.$$typeof===i||I.$$typeof===l||I.$$typeof===u||I.$$typeof===h||I.$$typeof===S||I.$$typeof===R||I.$$typeof===f)}function E(I){if(typeof I=="object"&&I!==null){var ye=I.$$typeof;switch(ye){case t:var A=I.type;switch(A){case c:case d:case r:case s:case o:case m:return A;default:var xe=A&&A.$$typeof;switch(xe){case l:case u:case x:case b:case i:return xe;default:return ye}}case n:return ye}}}var v=c,P=d,V=l,U=i,T=t,_=u,k=r,D=x,$=b,J=n,Y=s,F=o,te=m,se=!1;function oe(I){return se||(se=!0,console.warn("The ReactIs.isAsyncMode() alias has been deprecated, and will be removed in React 17+. Update your code to use ReactIs.isConcurrentMode() instead. It has the exact same API.")),y(I)||E(I)===c}function y(I){return E(I)===d}function C(I){return E(I)===l}function z(I){return E(I)===i}function L(I){return typeof I=="object"&&I!==null&&I.$$typeof===t}function B(I){return E(I)===u}function X(I){return E(I)===r}function q(I){return E(I)===x}function H(I){return E(I)===b}function G(I){return E(I)===n}function K(I){return E(I)===s}function Z(I){return E(I)===o}function ue(I){return E(I)===m}le.AsyncMode=v,le.ConcurrentMode=P,le.ContextConsumer=V,le.ContextProvider=U,le.Element=T,le.ForwardRef=_,le.Fragment=k,le.Lazy=D,le.Memo=$,le.Portal=J,le.Profiler=Y,le.StrictMode=F,le.Suspense=te,le.isAsyncMode=oe,le.isConcurrentMode=y,le.isContextConsumer=C,le.isContextProvider=z,le.isElement=L,le.isForwardRef=B,le.isFragment=X,le.isLazy=q,le.isMemo=H,le.isPortal=G,le.isProfiler=K,le.isStrictMode=Z,le.isSuspense=ue,le.isValidElementType=j,le.typeOf=E}()),le}var da;function ni(){return da||(da=1,process.env.NODE_ENV==="production"?zn.exports=kd():zn.exports=Sd()),zn.exports}/* + */var pa;function Sd(){return pa||(pa=1,process.env.NODE_ENV!=="production"&&function(){var e=typeof Symbol=="function"&&Symbol.for,t=e?Symbol.for("react.element"):60103,n=e?Symbol.for("react.portal"):60106,r=e?Symbol.for("react.fragment"):60107,o=e?Symbol.for("react.strict_mode"):60108,s=e?Symbol.for("react.profiler"):60114,i=e?Symbol.for("react.provider"):60109,l=e?Symbol.for("react.context"):60110,c=e?Symbol.for("react.async_mode"):60111,d=e?Symbol.for("react.concurrent_mode"):60111,u=e?Symbol.for("react.forward_ref"):60112,h=e?Symbol.for("react.suspense"):60113,w=e?Symbol.for("react.suspense_list"):60120,b=e?Symbol.for("react.memo"):60115,x=e?Symbol.for("react.lazy"):60116,f=e?Symbol.for("react.block"):60121,m=e?Symbol.for("react.fundamental"):60117,S=e?Symbol.for("react.responder"):60118,R=e?Symbol.for("react.scope"):60119;function j(I){return typeof I=="string"||typeof I=="function"||I===r||I===d||I===s||I===o||I===h||I===w||typeof I=="object"&&I!==null&&(I.$$typeof===x||I.$$typeof===b||I.$$typeof===i||I.$$typeof===l||I.$$typeof===u||I.$$typeof===m||I.$$typeof===S||I.$$typeof===R||I.$$typeof===f)}function E(I){if(typeof I=="object"&&I!==null){var ye=I.$$typeof;switch(ye){case t:var A=I.type;switch(A){case c:case d:case r:case s:case o:case h:return A;default:var xe=A&&A.$$typeof;switch(xe){case l:case u:case x:case b:case i:return xe;default:return ye}}case n:return ye}}}var v=c,P=d,V=l,U=i,C=t,_=u,k=r,D=x,$=b,J=n,Y=s,F=o,te=h,se=!1;function oe(I){return se||(se=!0,console.warn("The ReactIs.isAsyncMode() alias has been deprecated, and will be removed in React 17+. Update your code to use ReactIs.isConcurrentMode() instead. It has the exact same API.")),y(I)||E(I)===c}function y(I){return E(I)===d}function T(I){return E(I)===l}function z(I){return E(I)===i}function L(I){return typeof I=="object"&&I!==null&&I.$$typeof===t}function B(I){return E(I)===u}function X(I){return E(I)===r}function q(I){return E(I)===x}function H(I){return E(I)===b}function G(I){return E(I)===n}function K(I){return E(I)===s}function Z(I){return E(I)===o}function ue(I){return E(I)===h}le.AsyncMode=v,le.ConcurrentMode=P,le.ContextConsumer=V,le.ContextProvider=U,le.Element=C,le.ForwardRef=_,le.Fragment=k,le.Lazy=D,le.Memo=$,le.Portal=J,le.Profiler=Y,le.StrictMode=F,le.Suspense=te,le.isAsyncMode=oe,le.isConcurrentMode=y,le.isContextConsumer=T,le.isContextProvider=z,le.isElement=L,le.isForwardRef=B,le.isFragment=X,le.isLazy=q,le.isMemo=H,le.isPortal=G,le.isProfiler=K,le.isStrictMode=Z,le.isSuspense=ue,le.isValidElementType=j,le.typeOf=E}()),le}var wa;function ni(){return wa||(wa=1,process.env.NODE_ENV==="production"?zn.exports=kd():zn.exports=Sd()),zn.exports}/* object-assign (c) Sindre Sorhus @license MIT -*/var Pr,ua;function Ed(){if(ua)return Pr;ua=1;var e=Object.getOwnPropertySymbols,t=Object.prototype.hasOwnProperty,n=Object.prototype.propertyIsEnumerable;function r(s){if(s==null)throw new TypeError("Object.assign cannot be called with null or undefined");return Object(s)}function o(){try{if(!Object.assign)return!1;var s=new String("abc");if(s[5]="de",Object.getOwnPropertyNames(s)[0]==="5")return!1;for(var i={},l=0;l<10;l++)i["_"+String.fromCharCode(l)]=l;var c=Object.getOwnPropertyNames(i).map(function(u){return i[u]});if(c.join("")!=="0123456789")return!1;var d={};return"abcdefghijklmnopqrst".split("").forEach(function(u){d[u]=u}),Object.keys(Object.assign({},d)).join("")==="abcdefghijklmnopqrst"}catch{return!1}}return Pr=o()?Object.assign:function(s,i){for(var l,c=r(s),d,u=1;u1?s("Invalid arguments supplied to oneOf, expected an array, got "+arguments.length+" arguments. A common mistake is to write oneOf(x, y, z) instead of oneOf([x, y, z])."):s("Invalid argument supplied to oneOf, expected an array.")),i;function C(z,L,B,X,q){for(var H=z[L],G=0;G0?", expected one of type ["+K.join(", ")+"]":"";return new f("Invalid "+H+" `"+G+"` supplied to "+("`"+q+"`"+ye+"."))}return h(L)}function _(){function y(C,z,L,B,X){return J(C[z])?null:new f("Invalid "+B+" `"+X+"` supplied to "+("`"+L+"`, expected a ReactNode."))}return h(y)}function k(y,C,z,L,B){return new f((y||"React class")+": "+C+" type `"+z+"."+L+"` is invalid; it must be a function, usually from the `prop-types` package, but received `"+B+"`.")}function D(y){function C(z,L,B,X,q){var H=z[L],G=F(H);if(G!=="object")return new f("Invalid "+X+" `"+q+"` of type `"+G+"` "+("supplied to `"+B+"`, expected `object`."));for(var K in y){var Z=y[K];if(typeof Z!="function")return k(B,X,q,K,te(Z));var ue=Z(H,K,B,X,q+"."+K,n);if(ue)return ue}return null}return h(C)}function $(y){function C(z,L,B,X,q){var H=z[L],G=F(H);if(G!=="object")return new f("Invalid "+X+" `"+q+"` of type `"+G+"` "+("supplied to `"+B+"`, expected `object`."));var K=t({},z[L],y);for(var Z in K){var ue=y[Z];if(r(y,Z)&&typeof ue!="function")return k(B,X,q,Z,te(ue));if(!ue)return new f("Invalid "+X+" `"+q+"` key `"+Z+"` supplied to `"+B+"`.\nBad object: "+JSON.stringify(z[L],null," ")+` -Valid keys: `+JSON.stringify(Object.keys(y),null," "));var I=ue(H,Z,B,X,q+"."+Z,n);if(I)return I}return null}return h(C)}function J(y){switch(typeof y){case"number":case"string":case"undefined":return!0;case"boolean":return!y;case"object":if(Array.isArray(y))return y.every(J);if(y===null||l(y))return!0;var C=m(y);if(C){var z=C.call(y),L;if(C!==y.entries){for(;!(L=z.next()).done;)if(!J(L.value))return!1}else for(;!(L=z.next()).done;){var B=L.value;if(B&&!J(B[1]))return!1}}else return!1;return!0;default:return!1}}function Y(y,C){return y==="symbol"?!0:C?C["@@toStringTag"]==="Symbol"||typeof Symbol=="function"&&C instanceof Symbol:!1}function F(y){var C=typeof y;return Array.isArray(y)?"array":y instanceof RegExp?"object":Y(C,y)?"symbol":C}function te(y){if(typeof y>"u"||y===null)return""+y;var C=F(y);if(C==="object"){if(y instanceof Date)return"date";if(y instanceof RegExp)return"regexp"}return C}function se(y){var C=te(y);switch(C){case"array":case"object":return"an "+C;case"boolean":case"date":case"regexp":return"a "+C;default:return C}}function oe(y){return!y.constructor||!y.constructor.name?w:y.constructor.name}return b.checkPropTypes=o,b.resetWarningCache=o.resetWarningCache,b.PropTypes=b,b},Dr}var Ar,ha;function Cd(){if(ha)return Ar;ha=1;var e=No();function t(){}function n(){}return n.resetWarningCache=t,Ar=function(){function r(i,l,c,d,u,m){if(m!==e){var w=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types");throw w.name="Invariant Violation",w}}r.isRequired=r;function o(){return r}var s={array:r,bigint:r,bool:r,func:r,number:r,object:r,string:r,symbol:r,any:r,arrayOf:o,element:r,elementType:r,instanceOf:o,node:r,objectOf:o,oneOf:o,oneOfType:o,shape:o,exact:o,checkPropTypes:n,resetWarningCache:t};return s.PropTypes=s,s},Ar}if(process.env.NODE_ENV!=="production"){var Rd=ni(),Od=!0;Xr.exports=Td()(Rd.isElement,Od)}else Xr.exports=Cd()();var _d=Xr.exports;const p=xd(_d);function Pd(e){const{prototype:t={}}=e;return!!t.isReactComponent}function oi(e,t,n,r,o){const s=e[t],i=o||t;if(s==null||typeof window>"u")return null;let l;const c=s.type;return typeof c=="function"&&!Pd(c)&&(l="Did you accidentally use a plain function component for an element instead?"),l!==void 0?new Error(`Invalid ${r} \`${i}\` supplied to \`${n}\`. Expected an element that can hold a ref. ${l} For more information see https://mui.com/r/caveat-with-refs-guide`):null}const ai=yo(p.element,oi);ai.isRequired=yo(p.element.isRequired,oi);const si=ai,Id="exact-prop: ​";function Md(e){return process.env.NODE_ENV==="production"?e:O({},e,{[Id]:t=>{const n=Object.keys(t).filter(r=>!e.hasOwnProperty(r));return n.length>0?new Error(`The following props are not supported: ${n.map(r=>`\`${r}\``).join(", ")}. Please remove them.`):null}})}function zt(e){let t="https://mui.com/production-error/?code="+e;for(let n=1;n1?s("Invalid arguments supplied to oneOf, expected an array, got "+arguments.length+" arguments. A common mistake is to write oneOf(x, y, z) instead of oneOf([x, y, z])."):s("Invalid argument supplied to oneOf, expected an array.")),i;function T(z,L,B,X,q){for(var H=z[L],G=0;G0?", expected one of type ["+K.join(", ")+"]":"";return new f("Invalid "+H+" `"+G+"` supplied to "+("`"+q+"`"+ye+"."))}return m(L)}function _(){function y(T,z,L,B,X){return J(T[z])?null:new f("Invalid "+B+" `"+X+"` supplied to "+("`"+L+"`, expected a ReactNode."))}return m(y)}function k(y,T,z,L,B){return new f((y||"React class")+": "+T+" type `"+z+"."+L+"` is invalid; it must be a function, usually from the `prop-types` package, but received `"+B+"`.")}function D(y){function T(z,L,B,X,q){var H=z[L],G=F(H);if(G!=="object")return new f("Invalid "+X+" `"+q+"` of type `"+G+"` "+("supplied to `"+B+"`, expected `object`."));for(var K in y){var Z=y[K];if(typeof Z!="function")return k(B,X,q,K,te(Z));var ue=Z(H,K,B,X,q+"."+K,n);if(ue)return ue}return null}return m(T)}function $(y){function T(z,L,B,X,q){var H=z[L],G=F(H);if(G!=="object")return new f("Invalid "+X+" `"+q+"` of type `"+G+"` "+("supplied to `"+B+"`, expected `object`."));var K=t({},z[L],y);for(var Z in K){var ue=y[Z];if(r(y,Z)&&typeof ue!="function")return k(B,X,q,Z,te(ue));if(!ue)return new f("Invalid "+X+" `"+q+"` key `"+Z+"` supplied to `"+B+"`.\nBad object: "+JSON.stringify(z[L],null," ")+` +Valid keys: `+JSON.stringify(Object.keys(y),null," "));var I=ue(H,Z,B,X,q+"."+Z,n);if(I)return I}return null}return m(T)}function J(y){switch(typeof y){case"number":case"string":case"undefined":return!0;case"boolean":return!y;case"object":if(Array.isArray(y))return y.every(J);if(y===null||l(y))return!0;var T=h(y);if(T){var z=T.call(y),L;if(T!==y.entries){for(;!(L=z.next()).done;)if(!J(L.value))return!1}else for(;!(L=z.next()).done;){var B=L.value;if(B&&!J(B[1]))return!1}}else return!1;return!0;default:return!1}}function Y(y,T){return y==="symbol"?!0:T?T["@@toStringTag"]==="Symbol"||typeof Symbol=="function"&&T instanceof Symbol:!1}function F(y){var T=typeof y;return Array.isArray(y)?"array":y instanceof RegExp?"object":Y(T,y)?"symbol":T}function te(y){if(typeof y>"u"||y===null)return""+y;var T=F(y);if(T==="object"){if(y instanceof Date)return"date";if(y instanceof RegExp)return"regexp"}return T}function se(y){var T=te(y);switch(T){case"array":case"object":return"an "+T;case"boolean":case"date":case"regexp":return"a "+T;default:return T}}function oe(y){return!y.constructor||!y.constructor.name?w:y.constructor.name}return b.checkPropTypes=o,b.resetWarningCache=o.resetWarningCache,b.PropTypes=b,b},Ar}var Br,va;function Td(){if(va)return Br;va=1;var e=Eo();function t(){}function n(){}return n.resetWarningCache=t,Br=function(){function r(i,l,c,d,u,h){if(h!==e){var w=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types");throw w.name="Invariant Violation",w}}r.isRequired=r;function o(){return r}var s={array:r,bigint:r,bool:r,func:r,number:r,object:r,string:r,symbol:r,any:r,arrayOf:o,element:r,elementType:r,instanceOf:o,node:r,objectOf:o,oneOf:o,oneOfType:o,shape:o,exact:o,checkPropTypes:n,resetWarningCache:t};return s.PropTypes=s,s},Br}if(process.env.NODE_ENV!=="production"){var Rd=ni(),Od=!0;Kr.exports=Cd()(Rd.isElement,Od)}else Kr.exports=Td()();var _d=Kr.exports;const p=xd(_d);function Pd(e){const{prototype:t={}}=e;return!!t.isReactComponent}function oi(e,t,n,r,o){const s=e[t],i=o||t;if(s==null||typeof window>"u")return null;let l;const c=s.type;return typeof c=="function"&&!Pd(c)&&(l="Did you accidentally use a plain function component for an element instead?"),l!==void 0?new Error(`Invalid ${r} \`${i}\` supplied to \`${n}\`. Expected an element that can hold a ref. ${l} For more information see https://mui.com/r/caveat-with-refs-guide`):null}const ai=So(p.element,oi);ai.isRequired=So(p.element.isRequired,oi);const si=ai,Id="exact-prop: ​";function Md(e){return process.env.NODE_ENV==="production"?e:O({},e,{[Id]:t=>{const n=Object.keys(t).filter(r=>!e.hasOwnProperty(r));return n.length>0?new Error(`The following props are not supported: ${n.map(r=>`\`${r}\``).join(", ")}. Please remove them.`):null}})}function zt(e){let t="https://mui.com/production-error/?code="+e;for(let n=1;nn==null?t:function(...o){t.apply(this,o),n.apply(this,o)},()=>{})}function Fd(e,t=166){let n;function r(...o){const s=()=>{e.apply(this,o)};clearTimeout(n),n=setTimeout(s,t)}return r.clear=()=>{clearTimeout(n)},r}function Gd(e,t){return process.env.NODE_ENV==="production"?()=>null:(n,r,o,s,i)=>{const l=o||"<>",c=i||r;return typeof n[r]<"u"?new Error(`The ${s} \`${c}\` of \`${l}\` is deprecated. ${t}`):null}}function Ud(e,t){var n,r;return M.isValidElement(e)&&t.indexOf((n=e.type.muiName)!=null?n:(r=e.type)==null||(r=r._payload)==null||(r=r.value)==null?void 0:r.muiName)!==-1}function Wn(e){return e&&e.ownerDocument||document}function qd(e){return Wn(e).defaultView||window}function Hd(e,t){if(process.env.NODE_ENV==="production")return()=>null;const n=t?O({},t.propTypes):null;return o=>(s,i,l,c,d,...u)=>{const m=d||i,w=n==null?void 0:n[m];if(w){const b=w(s,i,l,c,d,...u);if(b)return b}return typeof s[i]<"u"&&!s[o]?new Error(`The prop \`${m}\` of \`${e}\` can only be used together with the \`${o}\` prop.`):null}}function Kn(e,t){typeof e=="function"?e(t):e&&(e.current=t)}const Xd=typeof window<"u"?M.useLayoutEffect:M.useEffect,Lt=Xd;let ya=0;function Yd(e){const[t,n]=M.useState(e),r=e||t;return M.useEffect(()=>{t==null&&(ya+=1,n(`mui-${ya}`))},[t]),r}const Na=M["useId".toString()];function ci(e){if(Na!==void 0){const t=Na();return e??t}return Yd(e)}function Wd(e,t,n,r,o){if(process.env.NODE_ENV==="production")return null;const s=o||t;return typeof e[t]<"u"?new Error(`The prop \`${s}\` is not supported. Please remove it.`):null}function di({controlled:e,default:t,name:n,state:r="value"}){const{current:o}=M.useRef(e!==void 0),[s,i]=M.useState(t),l=o?e:s;if(process.env.NODE_ENV!=="production"){M.useEffect(()=>{o!==(e!==void 0)&&console.error([`MUI: A component is changing the ${o?"":"un"}controlled ${r} state of ${n} to be ${o?"un":""}controlled.`,"Elements should not switch from uncontrolled to controlled (or vice versa).",`Decide between using a controlled or uncontrolled ${n} element for the lifetime of the component.`,"The nature of the state is determined during the first render. It's considered controlled if the value is not `undefined`.","More info: https://fb.me/react-controlled-components"].join(` + */var ya;function Dd(){return ya||(ya=1,process.env.NODE_ENV!=="production"&&function(){var e=Symbol.for("react.element"),t=Symbol.for("react.portal"),n=Symbol.for("react.fragment"),r=Symbol.for("react.strict_mode"),o=Symbol.for("react.profiler"),s=Symbol.for("react.provider"),i=Symbol.for("react.context"),l=Symbol.for("react.server_context"),c=Symbol.for("react.forward_ref"),d=Symbol.for("react.suspense"),u=Symbol.for("react.suspense_list"),h=Symbol.for("react.memo"),w=Symbol.for("react.lazy"),b=Symbol.for("react.offscreen"),x=!1,f=!1,m=!1,S=!1,R=!1,j;j=Symbol.for("react.module.reference");function E(A){return!!(typeof A=="string"||typeof A=="function"||A===n||A===o||R||A===r||A===d||A===u||S||A===b||x||f||m||typeof A=="object"&&A!==null&&(A.$$typeof===w||A.$$typeof===h||A.$$typeof===s||A.$$typeof===i||A.$$typeof===c||A.$$typeof===j||A.getModuleId!==void 0))}function v(A){if(typeof A=="object"&&A!==null){var xe=A.$$typeof;switch(xe){case e:var Ge=A.type;switch(Ge){case n:case o:case r:case d:case u:return Ge;default:var lt=Ge&&Ge.$$typeof;switch(lt){case l:case i:case c:case w:case h:case s:return lt;default:return xe}}case t:return xe}}}var P=i,V=s,U=e,C=c,_=n,k=w,D=h,$=t,J=o,Y=r,F=d,te=u,se=!1,oe=!1;function y(A){return se||(se=!0,console.warn("The ReactIs.isAsyncMode() alias has been deprecated, and will be removed in React 18+.")),!1}function T(A){return oe||(oe=!0,console.warn("The ReactIs.isConcurrentMode() alias has been deprecated, and will be removed in React 18+.")),!1}function z(A){return v(A)===i}function L(A){return v(A)===s}function B(A){return typeof A=="object"&&A!==null&&A.$$typeof===e}function X(A){return v(A)===c}function q(A){return v(A)===n}function H(A){return v(A)===w}function G(A){return v(A)===h}function K(A){return v(A)===t}function Z(A){return v(A)===o}function ue(A){return v(A)===r}function I(A){return v(A)===d}function ye(A){return v(A)===u}de.ContextConsumer=P,de.ContextProvider=V,de.Element=U,de.ForwardRef=C,de.Fragment=_,de.Lazy=k,de.Memo=D,de.Portal=$,de.Profiler=J,de.StrictMode=Y,de.Suspense=F,de.SuspenseList=te,de.isAsyncMode=y,de.isConcurrentMode=T,de.isContextConsumer=z,de.isContextProvider=L,de.isElement=B,de.isForwardRef=X,de.isFragment=q,de.isLazy=H,de.isMemo=G,de.isPortal=K,de.isProfiler=Z,de.isStrictMode=ue,de.isSuspense=I,de.isSuspenseList=ye,de.isValidElementType=E,de.typeOf=v}()),de}process.env.NODE_ENV==="production"?Jr.exports=$d():Jr.exports=Dd();var Na=Jr.exports;const Ad=/^\s*function(?:\s|\s*\/\*.*\*\/\s*)+([^(\s/]*)\s*/;function Bd(e){const t=`${e}`.match(Ad);return t&&t[1]||""}function ii(e,t=""){return e.displayName||e.name||Bd(e)||t}function ka(e,t,n){const r=ii(t);return e.displayName||(r!==""?`${n}(${r})`:n)}function Vd(e){if(e!=null){if(typeof e=="string")return e;if(typeof e=="function")return ii(e,"Component");if(typeof e=="object")switch(e.$$typeof){case Na.ForwardRef:return ka(e,e.render,"ForwardRef");case Na.Memo:return ka(e,e.type,"memo");default:return}}}function xn(e,t,n,r,o){if(process.env.NODE_ENV==="production")return null;const s=e[t],i=o||t;return s==null?null:s&&s.nodeType!==1?new Error(`Invalid ${r} \`${i}\` supplied to \`${n}\`. Expected an HTMLElement.`):null}const zd=p.oneOfType([p.func,p.object]),li=zd;function Ye(e){if(typeof e!="string")throw new Error(process.env.NODE_ENV!=="production"?"MUI: `capitalize(string)` expects a string argument.":zt(7));return e.charAt(0).toUpperCase()+e.slice(1)}function Ld(...e){return e.reduce((t,n)=>n==null?t:function(...o){t.apply(this,o),n.apply(this,o)},()=>{})}function Fd(e,t=166){let n;function r(...o){const s=()=>{e.apply(this,o)};clearTimeout(n),n=setTimeout(s,t)}return r.clear=()=>{clearTimeout(n)},r}function Gd(e,t){return process.env.NODE_ENV==="production"?()=>null:(n,r,o,s,i)=>{const l=o||"<>",c=i||r;return typeof n[r]<"u"?new Error(`The ${s} \`${c}\` of \`${l}\` is deprecated. ${t}`):null}}function Ud(e,t){var n,r;return M.isValidElement(e)&&t.indexOf((n=e.type.muiName)!=null?n:(r=e.type)==null||(r=r._payload)==null||(r=r.value)==null?void 0:r.muiName)!==-1}function Kn(e){return e&&e.ownerDocument||document}function qd(e){return Kn(e).defaultView||window}function Hd(e,t){if(process.env.NODE_ENV==="production")return()=>null;const n=t?O({},t.propTypes):null;return o=>(s,i,l,c,d,...u)=>{const h=d||i,w=n==null?void 0:n[h];if(w){const b=w(s,i,l,c,d,...u);if(b)return b}return typeof s[i]<"u"&&!s[o]?new Error(`The prop \`${h}\` of \`${e}\` can only be used together with the \`${o}\` prop.`):null}}function Jn(e,t){typeof e=="function"?e(t):e&&(e.current=t)}const Xd=typeof window<"u"?M.useLayoutEffect:M.useEffect,Lt=Xd;let Sa=0;function Yd(e){const[t,n]=M.useState(e),r=e||t;return M.useEffect(()=>{t==null&&(Sa+=1,n(`mui-${Sa}`))},[t]),r}const Ea=M["useId".toString()];function ci(e){if(Ea!==void 0){const t=Ea();return e??t}return Yd(e)}function Wd(e,t,n,r,o){if(process.env.NODE_ENV==="production")return null;const s=o||t;return typeof e[t]<"u"?new Error(`The prop \`${s}\` is not supported. Please remove it.`):null}function di({controlled:e,default:t,name:n,state:r="value"}){const{current:o}=M.useRef(e!==void 0),[s,i]=M.useState(t),l=o?e:s;if(process.env.NODE_ENV!=="production"){M.useEffect(()=>{o!==(e!==void 0)&&console.error([`MUI: A component is changing the ${o?"":"un"}controlled ${r} state of ${n} to be ${o?"un":""}controlled.`,"Elements should not switch from uncontrolled to controlled (or vice versa).",`Decide between using a controlled or uncontrolled ${n} element for the lifetime of the component.`,"The nature of the state is determined during the first render. It's considered controlled if the value is not `undefined`.","More info: https://fb.me/react-controlled-components"].join(` `))},[r,n,e]);const{current:d}=M.useRef(t);M.useEffect(()=>{!o&&d!==t&&console.error([`MUI: A component is changing the default ${r} state of an uncontrolled ${n} after being initialized. To suppress this warning opt to use a controlled ${n}.`].join(` -`))},[JSON.stringify(t)])}const c=M.useCallback(d=>{o||i(d)},[]);return[l,c]}function Wr(e){const t=M.useRef(e);return Lt(()=>{t.current=e}),M.useRef((...n)=>(0,t.current)(...n)).current}function yt(...e){return M.useMemo(()=>e.every(t=>t==null)?null:t=>{e.forEach(n=>{Kn(n,t)})},e)}const ka={};function Kd(e,t){const n=M.useRef(ka);return n.current===ka&&(n.current=e(t)),n}const Jd=[];function Zd(e){M.useEffect(e,Jd)}class On{constructor(){this.currentId=null,this.clear=()=>{this.currentId!==null&&(clearTimeout(this.currentId),this.currentId=null)},this.disposeEffect=()=>this.clear}static create(){return new On}start(t,n){this.clear(),this.currentId=setTimeout(()=>{this.currentId=null,n()},t)}}function dn(){const e=Kd(On.create).current;return Zd(e.disposeEffect),e}let cr=!0,Kr=!1;const Qd=new On,eu={text:!0,search:!0,url:!0,tel:!0,email:!0,password:!0,number:!0,date:!0,month:!0,week:!0,time:!0,datetime:!0,"datetime-local":!0};function tu(e){const{type:t,tagName:n}=e;return!!(n==="INPUT"&&eu[t]&&!e.readOnly||n==="TEXTAREA"&&!e.readOnly||e.isContentEditable)}function nu(e){e.metaKey||e.altKey||e.ctrlKey||(cr=!0)}function Br(){cr=!1}function ru(){this.visibilityState==="hidden"&&Kr&&(cr=!0)}function ou(e){e.addEventListener("keydown",nu,!0),e.addEventListener("mousedown",Br,!0),e.addEventListener("pointerdown",Br,!0),e.addEventListener("touchstart",Br,!0),e.addEventListener("visibilitychange",ru,!0)}function au(e){const{target:t}=e;try{return t.matches(":focus-visible")}catch{}return cr||tu(t)}function ui(){const e=M.useCallback(o=>{o!=null&&ou(o.ownerDocument)},[]),t=M.useRef(!1);function n(){return t.current?(Kr=!0,Qd.start(100,()=>{Kr=!1}),t.current=!1,!0):!1}function r(o){return au(o)?(t.current=!0,!0):!1}return{isFocusVisibleRef:t,onFocus:r,onBlur:n,ref:e}}function pi(e,t){const n=O({},t);return Object.keys(e).forEach(r=>{if(r.toString().match(/^(components|slots)$/))n[r]=O({},e[r],n[r]);else if(r.toString().match(/^(componentsProps|slotProps)$/)){const o=e[r]||{},s=t[r];n[r]={},!s||!Object.keys(s)?n[r]=o:!o||!Object.keys(o)?n[r]=s:(n[r]=O({},s),Object.keys(o).forEach(i=>{n[r][i]=pi(o[i],s[i])}))}else n[r]===void 0&&(n[r]=e[r])}),n}function ko(e,t,n=void 0){const r={};return Object.keys(e).forEach(o=>{r[o]=e[o].reduce((s,i)=>{if(i){const l=t(i);l!==""&&s.push(l),n&&n[i]&&s.push(n[i])}return s},[]).join(" ")}),r}const Sa=e=>e,su=()=>{let e=Sa;return{configure(t){e=t},generate(t){return e(t)},reset(){e=Sa}}},iu=su(),wi=iu,fi={active:"active",checked:"checked",completed:"completed",disabled:"disabled",error:"error",expanded:"expanded",focused:"focused",focusVisible:"focusVisible",open:"open",readOnly:"readOnly",required:"required",selected:"selected"};function dr(e,t,n="Mui"){const r=fi[t];return r?`${n}-${r}`:`${wi.generate(e)}-${t}`}function mi(e,t,n="Mui"){const r={};return t.forEach(o=>{r[o]=dr(e,o,n)}),r}function lu(e,t=Number.MIN_SAFE_INTEGER,n=Number.MAX_SAFE_INTEGER){return Math.max(t,Math.min(e,n))}function Ne(e,t){if(e==null)return{};var n={},r=Object.keys(e),o,s;for(s=0;s=0)&&(n[o]=e[o]);return n}const cu=["values","unit","step"],du=e=>{const t=Object.keys(e).map(n=>({key:n,val:e[n]}))||[];return t.sort((n,r)=>n.val-r.val),t.reduce((n,r)=>O({},n,{[r.key]:r.val}),{})};function uu(e){const{values:t={xs:0,sm:600,md:900,lg:1200,xl:1536},unit:n="px",step:r=5}=e,o=Ne(e,cu),s=du(t),i=Object.keys(s);function l(w){return`@media (min-width:${typeof t[w]=="number"?t[w]:w}${n})`}function c(w){return`@media (max-width:${(typeof t[w]=="number"?t[w]:w)-r/100}${n})`}function d(w,b){const x=i.indexOf(b);return`@media (min-width:${typeof t[w]=="number"?t[w]:w}${n}) and (max-width:${(x!==-1&&typeof t[i[x]]=="number"?t[i[x]]:b)-r/100}${n})`}function u(w){return i.indexOf(w)+1`@media (min-width:${So[e]}px)`};function et(e,t,n){const r=e.theme||{};if(Array.isArray(t)){const s=r.breakpoints||Ea;return t.reduce((i,l,c)=>(i[s.up(s.keys[c])]=n(t[c]),i),{})}if(typeof t=="object"){const s=r.breakpoints||Ea;return Object.keys(t).reduce((i,l)=>{if(Object.keys(s.values||So).indexOf(l)!==-1){const c=s.up(l);i[c]=n(t[l],l)}else{const c=l;i[c]=t[c]}return i},{})}return n(t)}function mu(e={}){var t;return((t=e.keys)==null?void 0:t.reduce((r,o)=>{const s=e.up(o);return r[s]={},r},{}))||{}}function hu(e,t){return e.reduce((n,r)=>{const o=n[r];return(!o||Object.keys(o).length===0)&&delete n[r],n},t)}function ur(e,t,n=!0){if(!t||typeof t!="string")return null;if(e&&e.vars&&n){const r=`vars.${t}`.split(".").reduce((o,s)=>o&&o[s]?o[s]:null,e);if(r!=null)return r}return t.split(".").reduce((r,o)=>r&&r[o]!=null?r[o]:null,e)}function Jn(e,t,n,r=n){let o;return typeof e=="function"?o=e(n):Array.isArray(e)?o=e[n]||r:o=ur(e,n)||r,t&&(o=t(o,r,e)),o}function ve(e){const{prop:t,cssProperty:n=e.prop,themeKey:r,transform:o}=e,s=i=>{if(i[t]==null)return null;const l=i[t],c=i.theme,d=ur(c,r)||{};return et(i,l,m=>{let w=Jn(d,o,m);return m===w&&typeof m=="string"&&(w=Jn(d,o,`${t}${m==="default"?"":Ye(m)}`,m)),n===!1?w:{[n]:w}})};return s.propTypes=process.env.NODE_ENV!=="production"?{[t]:st}:{},s.filterProps=[t],s}function gu(e){const t={};return n=>(t[n]===void 0&&(t[n]=e(n)),t[n])}const bu={m:"margin",p:"padding"},vu={t:"Top",r:"Right",b:"Bottom",l:"Left",x:["Left","Right"],y:["Top","Bottom"]},ja={marginX:"mx",marginY:"my",paddingX:"px",paddingY:"py"},xu=gu(e=>{if(e.length>2)if(ja[e])e=ja[e];else return[e];const[t,n]=e.split(""),r=bu[t],o=vu[n]||"";return Array.isArray(o)?o.map(s=>r+s):[r+o]}),pr=["m","mt","mr","mb","ml","mx","my","margin","marginTop","marginRight","marginBottom","marginLeft","marginX","marginY","marginInline","marginInlineStart","marginInlineEnd","marginBlock","marginBlockStart","marginBlockEnd"],wr=["p","pt","pr","pb","pl","px","py","padding","paddingTop","paddingRight","paddingBottom","paddingLeft","paddingX","paddingY","paddingInline","paddingInlineStart","paddingInlineEnd","paddingBlock","paddingBlockStart","paddingBlockEnd"],yu=[...pr,...wr];function _n(e,t,n,r){var o;const s=(o=ur(e,t,!1))!=null?o:n;return typeof s=="number"?i=>typeof i=="string"?i:(process.env.NODE_ENV!=="production"&&typeof i!="number"&&console.error(`MUI: Expected ${r} argument to be a number or a string, got ${i}.`),s*i):Array.isArray(s)?i=>typeof i=="string"?i:(process.env.NODE_ENV!=="production"&&(Number.isInteger(i)?i>s.length-1&&console.error([`MUI: The value provided (${i}) overflows.`,`The supported values are: ${JSON.stringify(s)}.`,`${i} > ${s.length-1}, you need to add the missing values.`].join(` +`))},[JSON.stringify(t)])}const c=M.useCallback(d=>{o||i(d)},[]);return[l,c]}function Zr(e){const t=M.useRef(e);return Lt(()=>{t.current=e}),M.useRef((...n)=>(0,t.current)(...n)).current}function yt(...e){return M.useMemo(()=>e.every(t=>t==null)?null:t=>{e.forEach(n=>{Jn(n,t)})},e)}const ja={};function Kd(e,t){const n=M.useRef(ja);return n.current===ja&&(n.current=e(t)),n}const Jd=[];function Zd(e){M.useEffect(e,Jd)}class On{constructor(){this.currentId=null,this.clear=()=>{this.currentId!==null&&(clearTimeout(this.currentId),this.currentId=null)},this.disposeEffect=()=>this.clear}static create(){return new On}start(t,n){this.clear(),this.currentId=setTimeout(()=>{this.currentId=null,n()},t)}}function dn(){const e=Kd(On.create).current;return Zd(e.disposeEffect),e}let dr=!0,Qr=!1;const Qd=new On,eu={text:!0,search:!0,url:!0,tel:!0,email:!0,password:!0,number:!0,date:!0,month:!0,week:!0,time:!0,datetime:!0,"datetime-local":!0};function tu(e){const{type:t,tagName:n}=e;return!!(n==="INPUT"&&eu[t]&&!e.readOnly||n==="TEXTAREA"&&!e.readOnly||e.isContentEditable)}function nu(e){e.metaKey||e.altKey||e.ctrlKey||(dr=!0)}function Vr(){dr=!1}function ru(){this.visibilityState==="hidden"&&Qr&&(dr=!0)}function ou(e){e.addEventListener("keydown",nu,!0),e.addEventListener("mousedown",Vr,!0),e.addEventListener("pointerdown",Vr,!0),e.addEventListener("touchstart",Vr,!0),e.addEventListener("visibilitychange",ru,!0)}function au(e){const{target:t}=e;try{return t.matches(":focus-visible")}catch{}return dr||tu(t)}function ui(){const e=M.useCallback(o=>{o!=null&&ou(o.ownerDocument)},[]),t=M.useRef(!1);function n(){return t.current?(Qr=!0,Qd.start(100,()=>{Qr=!1}),t.current=!1,!0):!1}function r(o){return au(o)?(t.current=!0,!0):!1}return{isFocusVisibleRef:t,onFocus:r,onBlur:n,ref:e}}function pi(e,t){const n=O({},t);return Object.keys(e).forEach(r=>{if(r.toString().match(/^(components|slots)$/))n[r]=O({},e[r],n[r]);else if(r.toString().match(/^(componentsProps|slotProps)$/)){const o=e[r]||{},s=t[r];n[r]={},!s||!Object.keys(s)?n[r]=o:!o||!Object.keys(o)?n[r]=s:(n[r]=O({},s),Object.keys(o).forEach(i=>{n[r][i]=pi(o[i],s[i])}))}else n[r]===void 0&&(n[r]=e[r])}),n}function jo(e,t,n=void 0){const r={};return Object.keys(e).forEach(o=>{r[o]=e[o].reduce((s,i)=>{if(i){const l=t(i);l!==""&&s.push(l),n&&n[i]&&s.push(n[i])}return s},[]).join(" ")}),r}const Ca=e=>e,su=()=>{let e=Ca;return{configure(t){e=t},generate(t){return e(t)},reset(){e=Ca}}},iu=su(),wi=iu,fi={active:"active",checked:"checked",completed:"completed",disabled:"disabled",error:"error",expanded:"expanded",focused:"focused",focusVisible:"focusVisible",open:"open",readOnly:"readOnly",required:"required",selected:"selected"};function ur(e,t,n="Mui"){const r=fi[t];return r?`${n}-${r}`:`${wi.generate(e)}-${t}`}function mi(e,t,n="Mui"){const r={};return t.forEach(o=>{r[o]=ur(e,o,n)}),r}function lu(e,t=Number.MIN_SAFE_INTEGER,n=Number.MAX_SAFE_INTEGER){return Math.max(t,Math.min(e,n))}function Ne(e,t){if(e==null)return{};var n={},r=Object.keys(e),o,s;for(s=0;s=0)&&(n[o]=e[o]);return n}const cu=["values","unit","step"],du=e=>{const t=Object.keys(e).map(n=>({key:n,val:e[n]}))||[];return t.sort((n,r)=>n.val-r.val),t.reduce((n,r)=>O({},n,{[r.key]:r.val}),{})};function uu(e){const{values:t={xs:0,sm:600,md:900,lg:1200,xl:1536},unit:n="px",step:r=5}=e,o=Ne(e,cu),s=du(t),i=Object.keys(s);function l(w){return`@media (min-width:${typeof t[w]=="number"?t[w]:w}${n})`}function c(w){return`@media (max-width:${(typeof t[w]=="number"?t[w]:w)-r/100}${n})`}function d(w,b){const x=i.indexOf(b);return`@media (min-width:${typeof t[w]=="number"?t[w]:w}${n}) and (max-width:${(x!==-1&&typeof t[i[x]]=="number"?t[i[x]]:b)-r/100}${n})`}function u(w){return i.indexOf(w)+1`@media (min-width:${Co[e]}px)`};function et(e,t,n){const r=e.theme||{};if(Array.isArray(t)){const s=r.breakpoints||Ta;return t.reduce((i,l,c)=>(i[s.up(s.keys[c])]=n(t[c]),i),{})}if(typeof t=="object"){const s=r.breakpoints||Ta;return Object.keys(t).reduce((i,l)=>{if(Object.keys(s.values||Co).indexOf(l)!==-1){const c=s.up(l);i[c]=n(t[l],l)}else{const c=l;i[c]=t[c]}return i},{})}return n(t)}function mu(e={}){var t;return((t=e.keys)==null?void 0:t.reduce((r,o)=>{const s=e.up(o);return r[s]={},r},{}))||{}}function hu(e,t){return e.reduce((n,r)=>{const o=n[r];return(!o||Object.keys(o).length===0)&&delete n[r],n},t)}function pr(e,t,n=!0){if(!t||typeof t!="string")return null;if(e&&e.vars&&n){const r=`vars.${t}`.split(".").reduce((o,s)=>o&&o[s]?o[s]:null,e);if(r!=null)return r}return t.split(".").reduce((r,o)=>r&&r[o]!=null?r[o]:null,e)}function Zn(e,t,n,r=n){let o;return typeof e=="function"?o=e(n):Array.isArray(e)?o=e[n]||r:o=pr(e,n)||r,t&&(o=t(o,r,e)),o}function ve(e){const{prop:t,cssProperty:n=e.prop,themeKey:r,transform:o}=e,s=i=>{if(i[t]==null)return null;const l=i[t],c=i.theme,d=pr(c,r)||{};return et(i,l,h=>{let w=Zn(d,o,h);return h===w&&typeof h=="string"&&(w=Zn(d,o,`${t}${h==="default"?"":Ye(h)}`,h)),n===!1?w:{[n]:w}})};return s.propTypes=process.env.NODE_ENV!=="production"?{[t]:st}:{},s.filterProps=[t],s}function gu(e){const t={};return n=>(t[n]===void 0&&(t[n]=e(n)),t[n])}const bu={m:"margin",p:"padding"},vu={t:"Top",r:"Right",b:"Bottom",l:"Left",x:["Left","Right"],y:["Top","Bottom"]},Ra={marginX:"mx",marginY:"my",paddingX:"px",paddingY:"py"},xu=gu(e=>{if(e.length>2)if(Ra[e])e=Ra[e];else return[e];const[t,n]=e.split(""),r=bu[t],o=vu[n]||"";return Array.isArray(o)?o.map(s=>r+s):[r+o]}),wr=["m","mt","mr","mb","ml","mx","my","margin","marginTop","marginRight","marginBottom","marginLeft","marginX","marginY","marginInline","marginInlineStart","marginInlineEnd","marginBlock","marginBlockStart","marginBlockEnd"],fr=["p","pt","pr","pb","pl","px","py","padding","paddingTop","paddingRight","paddingBottom","paddingLeft","paddingX","paddingY","paddingInline","paddingInlineStart","paddingInlineEnd","paddingBlock","paddingBlockStart","paddingBlockEnd"],yu=[...wr,...fr];function _n(e,t,n,r){var o;const s=(o=pr(e,t,!1))!=null?o:n;return typeof s=="number"?i=>typeof i=="string"?i:(process.env.NODE_ENV!=="production"&&typeof i!="number"&&console.error(`MUI: Expected ${r} argument to be a number or a string, got ${i}.`),s*i):Array.isArray(s)?i=>typeof i=="string"?i:(process.env.NODE_ENV!=="production"&&(Number.isInteger(i)?i>s.length-1&&console.error([`MUI: The value provided (${i}) overflows.`,`The supported values are: ${JSON.stringify(s)}.`,`${i} > ${s.length-1}, you need to add the missing values.`].join(` `)):console.error([`MUI: The \`theme.${t}\` array type cannot be combined with non integer values.You should either use an integer value that can be used as index, or define the \`theme.${t}\` as a number.`].join(` `))),s[i]):typeof s=="function"?s:(process.env.NODE_ENV!=="production"&&console.error([`MUI: The \`theme.${t}\` value (${s}) is invalid.`,"It should be a number, an array or a function."].join(` -`)),()=>{})}function hi(e){return _n(e,"spacing",8,"spacing")}function Pn(e,t){if(typeof t=="string"||t==null)return t;const n=Math.abs(t),r=e(n);return t>=0?r:typeof r=="number"?-r:`-${r}`}function Nu(e,t){return n=>e.reduce((r,o)=>(r[o]=Pn(t,n),r),{})}function ku(e,t,n,r){if(t.indexOf(n)===-1)return null;const o=xu(n),s=Nu(o,r),i=e[n];return et(e,i,s)}function gi(e,t){const n=hi(e.theme);return Object.keys(e).map(r=>ku(e,t,r,n)).reduce(mn,{})}function me(e){return gi(e,pr)}me.propTypes=process.env.NODE_ENV!=="production"?pr.reduce((e,t)=>(e[t]=st,e),{}):{};me.filterProps=pr;function he(e){return gi(e,wr)}he.propTypes=process.env.NODE_ENV!=="production"?wr.reduce((e,t)=>(e[t]=st,e),{}):{};he.filterProps=wr;process.env.NODE_ENV!=="production"&&yu.reduce((e,t)=>(e[t]=st,e),{});function Su(e=8){if(e.mui)return e;const t=hi({spacing:e}),n=(...r)=>(process.env.NODE_ENV!=="production"&&(r.length<=4||console.error(`MUI: Too many arguments provided, expected between 0 and 4, got ${r.length}`)),(r.length===0?[1]:r).map(s=>{const i=t(s);return typeof i=="number"?`${i}px`:i}).join(" "));return n.mui=!0,n}function fr(...e){const t=e.reduce((r,o)=>(o.filterProps.forEach(s=>{r[s]=o}),r),{}),n=r=>Object.keys(r).reduce((o,s)=>t[s]?mn(o,t[s](r)):o,{});return n.propTypes=process.env.NODE_ENV!=="production"?e.reduce((r,o)=>Object.assign(r,o.propTypes),{}):{},n.filterProps=e.reduce((r,o)=>r.concat(o.filterProps),[]),n}function Be(e){return typeof e!="number"?e:`${e}px solid`}function Fe(e,t){return ve({prop:e,themeKey:"borders",transform:t})}const Eu=Fe("border",Be),ju=Fe("borderTop",Be),Tu=Fe("borderRight",Be),Cu=Fe("borderBottom",Be),Ru=Fe("borderLeft",Be),Ou=Fe("borderColor"),_u=Fe("borderTopColor"),Pu=Fe("borderRightColor"),Iu=Fe("borderBottomColor"),Mu=Fe("borderLeftColor"),$u=Fe("outline",Be),Du=Fe("outlineColor"),mr=e=>{if(e.borderRadius!==void 0&&e.borderRadius!==null){const t=_n(e.theme,"shape.borderRadius",4,"borderRadius"),n=r=>({borderRadius:Pn(t,r)});return et(e,e.borderRadius,n)}return null};mr.propTypes=process.env.NODE_ENV!=="production"?{borderRadius:st}:{};mr.filterProps=["borderRadius"];fr(Eu,ju,Tu,Cu,Ru,Ou,_u,Pu,Iu,Mu,mr,$u,Du);const hr=e=>{if(e.gap!==void 0&&e.gap!==null){const t=_n(e.theme,"spacing",8,"gap"),n=r=>({gap:Pn(t,r)});return et(e,e.gap,n)}return null};hr.propTypes=process.env.NODE_ENV!=="production"?{gap:st}:{};hr.filterProps=["gap"];const gr=e=>{if(e.columnGap!==void 0&&e.columnGap!==null){const t=_n(e.theme,"spacing",8,"columnGap"),n=r=>({columnGap:Pn(t,r)});return et(e,e.columnGap,n)}return null};gr.propTypes=process.env.NODE_ENV!=="production"?{columnGap:st}:{};gr.filterProps=["columnGap"];const br=e=>{if(e.rowGap!==void 0&&e.rowGap!==null){const t=_n(e.theme,"spacing",8,"rowGap"),n=r=>({rowGap:Pn(t,r)});return et(e,e.rowGap,n)}return null};br.propTypes=process.env.NODE_ENV!=="production"?{rowGap:st}:{};br.filterProps=["rowGap"];const Au=ve({prop:"gridColumn"}),Bu=ve({prop:"gridRow"}),Vu=ve({prop:"gridAutoFlow"}),zu=ve({prop:"gridAutoColumns"}),Lu=ve({prop:"gridAutoRows"}),Fu=ve({prop:"gridTemplateColumns"}),Gu=ve({prop:"gridTemplateRows"}),Uu=ve({prop:"gridTemplateAreas"}),qu=ve({prop:"gridArea"});fr(hr,gr,br,Au,Bu,Vu,zu,Lu,Fu,Gu,Uu,qu);function Dt(e,t){return t==="grey"?t:e}const Hu=ve({prop:"color",themeKey:"palette",transform:Dt}),Xu=ve({prop:"bgcolor",cssProperty:"backgroundColor",themeKey:"palette",transform:Dt}),Yu=ve({prop:"backgroundColor",themeKey:"palette",transform:Dt});fr(Hu,Xu,Yu);function Me(e){return e<=1&&e!==0?`${e*100}%`:e}const Wu=ve({prop:"width",transform:Me}),Eo=e=>{if(e.maxWidth!==void 0&&e.maxWidth!==null){const t=n=>{var r,o;const s=((r=e.theme)==null||(r=r.breakpoints)==null||(r=r.values)==null?void 0:r[n])||So[n];return s?((o=e.theme)==null||(o=o.breakpoints)==null?void 0:o.unit)!=="px"?{maxWidth:`${s}${e.theme.breakpoints.unit}`}:{maxWidth:s}:{maxWidth:Me(n)}};return et(e,e.maxWidth,t)}return null};Eo.filterProps=["maxWidth"];const Ku=ve({prop:"minWidth",transform:Me}),Ju=ve({prop:"height",transform:Me}),Zu=ve({prop:"maxHeight",transform:Me}),Qu=ve({prop:"minHeight",transform:Me});ve({prop:"size",cssProperty:"width",transform:Me});ve({prop:"size",cssProperty:"height",transform:Me});const ep=ve({prop:"boxSizing"});fr(Wu,Eo,Ku,Ju,Zu,Qu,ep);const tp={border:{themeKey:"borders",transform:Be},borderTop:{themeKey:"borders",transform:Be},borderRight:{themeKey:"borders",transform:Be},borderBottom:{themeKey:"borders",transform:Be},borderLeft:{themeKey:"borders",transform:Be},borderColor:{themeKey:"palette"},borderTopColor:{themeKey:"palette"},borderRightColor:{themeKey:"palette"},borderBottomColor:{themeKey:"palette"},borderLeftColor:{themeKey:"palette"},outline:{themeKey:"borders",transform:Be},outlineColor:{themeKey:"palette"},borderRadius:{themeKey:"shape.borderRadius",style:mr},color:{themeKey:"palette",transform:Dt},bgcolor:{themeKey:"palette",cssProperty:"backgroundColor",transform:Dt},backgroundColor:{themeKey:"palette",transform:Dt},p:{style:he},pt:{style:he},pr:{style:he},pb:{style:he},pl:{style:he},px:{style:he},py:{style:he},padding:{style:he},paddingTop:{style:he},paddingRight:{style:he},paddingBottom:{style:he},paddingLeft:{style:he},paddingX:{style:he},paddingY:{style:he},paddingInline:{style:he},paddingInlineStart:{style:he},paddingInlineEnd:{style:he},paddingBlock:{style:he},paddingBlockStart:{style:he},paddingBlockEnd:{style:he},m:{style:me},mt:{style:me},mr:{style:me},mb:{style:me},ml:{style:me},mx:{style:me},my:{style:me},margin:{style:me},marginTop:{style:me},marginRight:{style:me},marginBottom:{style:me},marginLeft:{style:me},marginX:{style:me},marginY:{style:me},marginInline:{style:me},marginInlineStart:{style:me},marginInlineEnd:{style:me},marginBlock:{style:me},marginBlockStart:{style:me},marginBlockEnd:{style:me},displayPrint:{cssProperty:!1,transform:e=>({"@media print":{display:e}})},display:{},overflow:{},textOverflow:{},visibility:{},whiteSpace:{},flexBasis:{},flexDirection:{},flexWrap:{},justifyContent:{},alignItems:{},alignContent:{},order:{},flex:{},flexGrow:{},flexShrink:{},alignSelf:{},justifyItems:{},justifySelf:{},gap:{style:hr},rowGap:{style:br},columnGap:{style:gr},gridColumn:{},gridRow:{},gridAutoFlow:{},gridAutoColumns:{},gridAutoRows:{},gridTemplateColumns:{},gridTemplateRows:{},gridTemplateAreas:{},gridArea:{},position:{},zIndex:{themeKey:"zIndex"},top:{},right:{},bottom:{},left:{},boxShadow:{themeKey:"shadows"},width:{transform:Me},maxWidth:{style:Eo},minWidth:{transform:Me},height:{transform:Me},maxHeight:{transform:Me},minHeight:{transform:Me},boxSizing:{},fontFamily:{themeKey:"typography"},fontSize:{themeKey:"typography"},fontStyle:{themeKey:"typography"},fontWeight:{themeKey:"typography"},letterSpacing:{},textTransform:{},lineHeight:{},textAlign:{},typography:{cssProperty:!1,themeKey:"typography"}},jo=tp;function np(...e){const t=e.reduce((r,o)=>r.concat(Object.keys(o)),[]),n=new Set(t);return e.every(r=>n.size===Object.keys(r).length)}function rp(e,t){return typeof e=="function"?e(t):e}function op(){function e(n,r,o,s){const i={[n]:r,theme:o},l=s[n];if(!l)return{[n]:r};const{cssProperty:c=n,themeKey:d,transform:u,style:m}=l;if(r==null)return null;if(d==="typography"&&r==="inherit")return{[n]:r};const w=ur(o,d)||{};return m?m(i):et(i,r,x=>{let f=Jn(w,u,x);return x===f&&typeof x=="string"&&(f=Jn(w,u,`${n}${x==="default"?"":Ye(x)}`,x)),c===!1?f:{[c]:f}})}function t(n){var r;const{sx:o,theme:s={}}=n||{};if(!o)return null;const i=(r=s.unstable_sxConfig)!=null?r:jo;function l(c){let d=c;if(typeof c=="function")d=c(s);else if(typeof c!="object")return c;if(!d)return null;const u=mu(s.breakpoints),m=Object.keys(u);let w=u;return Object.keys(d).forEach(b=>{const x=rp(d[b],s);if(x!=null)if(typeof x=="object")if(i[b])w=mn(w,e(b,x,s,i));else{const f=et({theme:s},x,h=>({[b]:h}));np(f,x)?w[b]=t({sx:x,theme:s}):w=mn(w,f)}else w=mn(w,e(b,x,s,i))}),hu(m,w)}return Array.isArray(o)?o.map(l):l(o)}return t}const bi=op();bi.filterProps=["sx"];const To=bi;function ap(e,t){const n=this;return n.vars&&typeof n.getColorSchemeSelector=="function"?{[n.getColorSchemeSelector(e).replace(/(\[[^\]]+\])/,"*:where($1)")]:t}:n.palette.mode===e?t:{}}const sp=["breakpoints","palette","spacing","shape"];function Co(e={},...t){const{breakpoints:n={},palette:r={},spacing:o,shape:s={}}=e,i=Ne(e,sp),l=uu(n),c=Su(o);let d=Qe({breakpoints:l,direction:"ltr",components:{},palette:O({mode:"light"},r),spacing:c,shape:O({},wu,s)},i);return d.applyStyles=ap,d=t.reduce((u,m)=>Qe(u,m),d),d.unstable_sxConfig=O({},jo,i==null?void 0:i.unstable_sxConfig),d.unstable_sx=function(m){return To({sx:m,theme:this})},d}function ip(e){return Object.keys(e).length===0}function vi(e=null){const t=M.useContext(Fr.ThemeContext);return!t||ip(t)?e:t}const lp=Co();function xi(e=lp){return vi(e)}const cp=["ownerState"],dp=["variants"],up=["name","slot","skipVariantsResolver","skipSx","overridesResolver"];function pp(e){return Object.keys(e).length===0}function wp(e){return typeof e=="string"&&e.charCodeAt(0)>96}function qn(e){return e!=="ownerState"&&e!=="theme"&&e!=="sx"&&e!=="as"}const fp=Co(),Ta=e=>e&&e.charAt(0).toLowerCase()+e.slice(1);function Ln({defaultTheme:e,theme:t,themeId:n}){return pp(t)?e:t[n]||t}function mp(e){return e?(t,n)=>n[e]:null}function Hn(e,t){let{ownerState:n}=t,r=Ne(t,cp);const o=typeof e=="function"?e(O({ownerState:n},r)):e;if(Array.isArray(o))return o.flatMap(s=>Hn(s,O({ownerState:n},r)));if(o&&typeof o=="object"&&Array.isArray(o.variants)){const{variants:s=[]}=o;let l=Ne(o,dp);return s.forEach(c=>{let d=!0;typeof c.props=="function"?d=c.props(O({ownerState:n},r,n)):Object.keys(c.props).forEach(u=>{(n==null?void 0:n[u])!==c.props[u]&&r[u]!==c.props[u]&&(d=!1)}),d&&(Array.isArray(l)||(l=[l]),l.push(typeof c.style=="function"?c.style(O({ownerState:n},r,n)):c.style))}),l}return o}function hp(e={}){const{themeId:t,defaultTheme:n=fp,rootShouldForwardProp:r=qn,slotShouldForwardProp:o=qn}=e,s=i=>To(O({},i,{theme:Ln(O({},i,{defaultTheme:n,themeId:t}))}));return s.__mui_systemSx=!0,(i,l={})=>{Fr.internal_processStyles(i,v=>v.filter(P=>!(P!=null&&P.__mui_systemSx)));const{name:c,slot:d,skipVariantsResolver:u,skipSx:m,overridesResolver:w=mp(Ta(d))}=l,b=Ne(l,up),x=u!==void 0?u:d&&d!=="Root"&&d!=="root"||!1,f=m||!1;let h;process.env.NODE_ENV!=="production"&&c&&(h=`${c}-${Ta(d||"Root")}`);let S=qn;d==="Root"||d==="root"?S=r:d?S=o:wp(i)&&(S=void 0);const R=Fr(i,O({shouldForwardProp:S,label:h},b)),j=v=>typeof v=="function"&&v.__emotion_real!==v||mt(v)?P=>Hn(v,O({},P,{theme:Ln({theme:P.theme,defaultTheme:n,themeId:t})})):v,E=(v,...P)=>{let V=j(v);const U=P?P.map(j):[];c&&w&&U.push(k=>{const D=Ln(O({},k,{defaultTheme:n,themeId:t}));if(!D.components||!D.components[c]||!D.components[c].styleOverrides)return null;const $=D.components[c].styleOverrides,J={};return Object.entries($).forEach(([Y,F])=>{J[Y]=Hn(F,O({},k,{theme:D}))}),w(k,J)}),c&&!x&&U.push(k=>{var D;const $=Ln(O({},k,{defaultTheme:n,themeId:t})),J=$==null||(D=$.components)==null||(D=D[c])==null?void 0:D.variants;return Hn({variants:J},O({},k,{theme:$}))}),f||U.push(s);const T=U.length-P.length;if(Array.isArray(v)&&T>0){const k=new Array(T).fill("");V=[...v,...k],V.raw=[...v.raw,...k]}const _=R(V,...U);if(process.env.NODE_ENV!=="production"){let k;c&&(k=`${c}${Ye(d||"")}`),k===void 0&&(k=`Styled(${Vd(i)})`),_.displayName=k}return i.muiName&&(_.muiName=i.muiName),_};return R.withConfig&&(E.withConfig=R.withConfig),E}}function gp(e){const{theme:t,name:n,props:r}=e;return!t||!t.components||!t.components[n]||!t.components[n].defaultProps?r:pi(t.components[n].defaultProps,r)}function bp({props:e,name:t,defaultTheme:n,themeId:r}){let o=xi(n);return r&&(o=o[r]||o),gp({theme:o,name:t,props:e})}function Ro(e,t=0,n=1){return process.env.NODE_ENV!=="production"&&(en)&&console.error(`MUI: The value provided ${e} is out of range [${t}, ${n}].`),lu(e,t,n)}function vp(e){e=e.slice(1);const t=new RegExp(`.{1,${e.length>=6?2:1}}`,"g");let n=e.match(t);return n&&n[0].length===1&&(n=n.map(r=>r+r)),n?`rgb${n.length===4?"a":""}(${n.map((r,o)=>o<3?parseInt(r,16):Math.round(parseInt(r,16)/255*1e3)/1e3).join(", ")})`:""}function Nt(e){if(e.type)return e;if(e.charAt(0)==="#")return Nt(vp(e));const t=e.indexOf("("),n=e.substring(0,t);if(["rgb","rgba","hsl","hsla","color"].indexOf(n)===-1)throw new Error(process.env.NODE_ENV!=="production"?`MUI: Unsupported \`${e}\` color. +`)),()=>{})}function hi(e){return _n(e,"spacing",8,"spacing")}function Pn(e,t){if(typeof t=="string"||t==null)return t;const n=Math.abs(t),r=e(n);return t>=0?r:typeof r=="number"?-r:`-${r}`}function Nu(e,t){return n=>e.reduce((r,o)=>(r[o]=Pn(t,n),r),{})}function ku(e,t,n,r){if(t.indexOf(n)===-1)return null;const o=xu(n),s=Nu(o,r),i=e[n];return et(e,i,s)}function gi(e,t){const n=hi(e.theme);return Object.keys(e).map(r=>ku(e,t,r,n)).reduce(mn,{})}function me(e){return gi(e,wr)}me.propTypes=process.env.NODE_ENV!=="production"?wr.reduce((e,t)=>(e[t]=st,e),{}):{};me.filterProps=wr;function he(e){return gi(e,fr)}he.propTypes=process.env.NODE_ENV!=="production"?fr.reduce((e,t)=>(e[t]=st,e),{}):{};he.filterProps=fr;process.env.NODE_ENV!=="production"&&yu.reduce((e,t)=>(e[t]=st,e),{});function Su(e=8){if(e.mui)return e;const t=hi({spacing:e}),n=(...r)=>(process.env.NODE_ENV!=="production"&&(r.length<=4||console.error(`MUI: Too many arguments provided, expected between 0 and 4, got ${r.length}`)),(r.length===0?[1]:r).map(s=>{const i=t(s);return typeof i=="number"?`${i}px`:i}).join(" "));return n.mui=!0,n}function mr(...e){const t=e.reduce((r,o)=>(o.filterProps.forEach(s=>{r[s]=o}),r),{}),n=r=>Object.keys(r).reduce((o,s)=>t[s]?mn(o,t[s](r)):o,{});return n.propTypes=process.env.NODE_ENV!=="production"?e.reduce((r,o)=>Object.assign(r,o.propTypes),{}):{},n.filterProps=e.reduce((r,o)=>r.concat(o.filterProps),[]),n}function Be(e){return typeof e!="number"?e:`${e}px solid`}function Fe(e,t){return ve({prop:e,themeKey:"borders",transform:t})}const Eu=Fe("border",Be),ju=Fe("borderTop",Be),Cu=Fe("borderRight",Be),Tu=Fe("borderBottom",Be),Ru=Fe("borderLeft",Be),Ou=Fe("borderColor"),_u=Fe("borderTopColor"),Pu=Fe("borderRightColor"),Iu=Fe("borderBottomColor"),Mu=Fe("borderLeftColor"),$u=Fe("outline",Be),Du=Fe("outlineColor"),hr=e=>{if(e.borderRadius!==void 0&&e.borderRadius!==null){const t=_n(e.theme,"shape.borderRadius",4,"borderRadius"),n=r=>({borderRadius:Pn(t,r)});return et(e,e.borderRadius,n)}return null};hr.propTypes=process.env.NODE_ENV!=="production"?{borderRadius:st}:{};hr.filterProps=["borderRadius"];mr(Eu,ju,Cu,Tu,Ru,Ou,_u,Pu,Iu,Mu,hr,$u,Du);const gr=e=>{if(e.gap!==void 0&&e.gap!==null){const t=_n(e.theme,"spacing",8,"gap"),n=r=>({gap:Pn(t,r)});return et(e,e.gap,n)}return null};gr.propTypes=process.env.NODE_ENV!=="production"?{gap:st}:{};gr.filterProps=["gap"];const br=e=>{if(e.columnGap!==void 0&&e.columnGap!==null){const t=_n(e.theme,"spacing",8,"columnGap"),n=r=>({columnGap:Pn(t,r)});return et(e,e.columnGap,n)}return null};br.propTypes=process.env.NODE_ENV!=="production"?{columnGap:st}:{};br.filterProps=["columnGap"];const vr=e=>{if(e.rowGap!==void 0&&e.rowGap!==null){const t=_n(e.theme,"spacing",8,"rowGap"),n=r=>({rowGap:Pn(t,r)});return et(e,e.rowGap,n)}return null};vr.propTypes=process.env.NODE_ENV!=="production"?{rowGap:st}:{};vr.filterProps=["rowGap"];const Au=ve({prop:"gridColumn"}),Bu=ve({prop:"gridRow"}),Vu=ve({prop:"gridAutoFlow"}),zu=ve({prop:"gridAutoColumns"}),Lu=ve({prop:"gridAutoRows"}),Fu=ve({prop:"gridTemplateColumns"}),Gu=ve({prop:"gridTemplateRows"}),Uu=ve({prop:"gridTemplateAreas"}),qu=ve({prop:"gridArea"});mr(gr,br,vr,Au,Bu,Vu,zu,Lu,Fu,Gu,Uu,qu);function Dt(e,t){return t==="grey"?t:e}const Hu=ve({prop:"color",themeKey:"palette",transform:Dt}),Xu=ve({prop:"bgcolor",cssProperty:"backgroundColor",themeKey:"palette",transform:Dt}),Yu=ve({prop:"backgroundColor",themeKey:"palette",transform:Dt});mr(Hu,Xu,Yu);function Me(e){return e<=1&&e!==0?`${e*100}%`:e}const Wu=ve({prop:"width",transform:Me}),To=e=>{if(e.maxWidth!==void 0&&e.maxWidth!==null){const t=n=>{var r,o;const s=((r=e.theme)==null||(r=r.breakpoints)==null||(r=r.values)==null?void 0:r[n])||Co[n];return s?((o=e.theme)==null||(o=o.breakpoints)==null?void 0:o.unit)!=="px"?{maxWidth:`${s}${e.theme.breakpoints.unit}`}:{maxWidth:s}:{maxWidth:Me(n)}};return et(e,e.maxWidth,t)}return null};To.filterProps=["maxWidth"];const Ku=ve({prop:"minWidth",transform:Me}),Ju=ve({prop:"height",transform:Me}),Zu=ve({prop:"maxHeight",transform:Me}),Qu=ve({prop:"minHeight",transform:Me});ve({prop:"size",cssProperty:"width",transform:Me});ve({prop:"size",cssProperty:"height",transform:Me});const ep=ve({prop:"boxSizing"});mr(Wu,To,Ku,Ju,Zu,Qu,ep);const tp={border:{themeKey:"borders",transform:Be},borderTop:{themeKey:"borders",transform:Be},borderRight:{themeKey:"borders",transform:Be},borderBottom:{themeKey:"borders",transform:Be},borderLeft:{themeKey:"borders",transform:Be},borderColor:{themeKey:"palette"},borderTopColor:{themeKey:"palette"},borderRightColor:{themeKey:"palette"},borderBottomColor:{themeKey:"palette"},borderLeftColor:{themeKey:"palette"},outline:{themeKey:"borders",transform:Be},outlineColor:{themeKey:"palette"},borderRadius:{themeKey:"shape.borderRadius",style:hr},color:{themeKey:"palette",transform:Dt},bgcolor:{themeKey:"palette",cssProperty:"backgroundColor",transform:Dt},backgroundColor:{themeKey:"palette",transform:Dt},p:{style:he},pt:{style:he},pr:{style:he},pb:{style:he},pl:{style:he},px:{style:he},py:{style:he},padding:{style:he},paddingTop:{style:he},paddingRight:{style:he},paddingBottom:{style:he},paddingLeft:{style:he},paddingX:{style:he},paddingY:{style:he},paddingInline:{style:he},paddingInlineStart:{style:he},paddingInlineEnd:{style:he},paddingBlock:{style:he},paddingBlockStart:{style:he},paddingBlockEnd:{style:he},m:{style:me},mt:{style:me},mr:{style:me},mb:{style:me},ml:{style:me},mx:{style:me},my:{style:me},margin:{style:me},marginTop:{style:me},marginRight:{style:me},marginBottom:{style:me},marginLeft:{style:me},marginX:{style:me},marginY:{style:me},marginInline:{style:me},marginInlineStart:{style:me},marginInlineEnd:{style:me},marginBlock:{style:me},marginBlockStart:{style:me},marginBlockEnd:{style:me},displayPrint:{cssProperty:!1,transform:e=>({"@media print":{display:e}})},display:{},overflow:{},textOverflow:{},visibility:{},whiteSpace:{},flexBasis:{},flexDirection:{},flexWrap:{},justifyContent:{},alignItems:{},alignContent:{},order:{},flex:{},flexGrow:{},flexShrink:{},alignSelf:{},justifyItems:{},justifySelf:{},gap:{style:gr},rowGap:{style:vr},columnGap:{style:br},gridColumn:{},gridRow:{},gridAutoFlow:{},gridAutoColumns:{},gridAutoRows:{},gridTemplateColumns:{},gridTemplateRows:{},gridTemplateAreas:{},gridArea:{},position:{},zIndex:{themeKey:"zIndex"},top:{},right:{},bottom:{},left:{},boxShadow:{themeKey:"shadows"},width:{transform:Me},maxWidth:{style:To},minWidth:{transform:Me},height:{transform:Me},maxHeight:{transform:Me},minHeight:{transform:Me},boxSizing:{},fontFamily:{themeKey:"typography"},fontSize:{themeKey:"typography"},fontStyle:{themeKey:"typography"},fontWeight:{themeKey:"typography"},letterSpacing:{},textTransform:{},lineHeight:{},textAlign:{},typography:{cssProperty:!1,themeKey:"typography"}},Ro=tp;function np(...e){const t=e.reduce((r,o)=>r.concat(Object.keys(o)),[]),n=new Set(t);return e.every(r=>n.size===Object.keys(r).length)}function rp(e,t){return typeof e=="function"?e(t):e}function op(){function e(n,r,o,s){const i={[n]:r,theme:o},l=s[n];if(!l)return{[n]:r};const{cssProperty:c=n,themeKey:d,transform:u,style:h}=l;if(r==null)return null;if(d==="typography"&&r==="inherit")return{[n]:r};const w=pr(o,d)||{};return h?h(i):et(i,r,x=>{let f=Zn(w,u,x);return x===f&&typeof x=="string"&&(f=Zn(w,u,`${n}${x==="default"?"":Ye(x)}`,x)),c===!1?f:{[c]:f}})}function t(n){var r;const{sx:o,theme:s={}}=n||{};if(!o)return null;const i=(r=s.unstable_sxConfig)!=null?r:Ro;function l(c){let d=c;if(typeof c=="function")d=c(s);else if(typeof c!="object")return c;if(!d)return null;const u=mu(s.breakpoints),h=Object.keys(u);let w=u;return Object.keys(d).forEach(b=>{const x=rp(d[b],s);if(x!=null)if(typeof x=="object")if(i[b])w=mn(w,e(b,x,s,i));else{const f=et({theme:s},x,m=>({[b]:m}));np(f,x)?w[b]=t({sx:x,theme:s}):w=mn(w,f)}else w=mn(w,e(b,x,s,i))}),hu(h,w)}return Array.isArray(o)?o.map(l):l(o)}return t}const bi=op();bi.filterProps=["sx"];const Oo=bi;function ap(e,t){const n=this;return n.vars&&typeof n.getColorSchemeSelector=="function"?{[n.getColorSchemeSelector(e).replace(/(\[[^\]]+\])/,"*:where($1)")]:t}:n.palette.mode===e?t:{}}const sp=["breakpoints","palette","spacing","shape"];function _o(e={},...t){const{breakpoints:n={},palette:r={},spacing:o,shape:s={}}=e,i=Ne(e,sp),l=uu(n),c=Su(o);let d=Qe({breakpoints:l,direction:"ltr",components:{},palette:O({mode:"light"},r),spacing:c,shape:O({},wu,s)},i);return d.applyStyles=ap,d=t.reduce((u,h)=>Qe(u,h),d),d.unstable_sxConfig=O({},Ro,i==null?void 0:i.unstable_sxConfig),d.unstable_sx=function(h){return Oo({sx:h,theme:this})},d}function ip(e){return Object.keys(e).length===0}function vi(e=null){const t=M.useContext(Gr.ThemeContext);return!t||ip(t)?e:t}const lp=_o();function xi(e=lp){return vi(e)}const cp=["ownerState"],dp=["variants"],up=["name","slot","skipVariantsResolver","skipSx","overridesResolver"];function pp(e){return Object.keys(e).length===0}function wp(e){return typeof e=="string"&&e.charCodeAt(0)>96}function qn(e){return e!=="ownerState"&&e!=="theme"&&e!=="sx"&&e!=="as"}const fp=_o(),Oa=e=>e&&e.charAt(0).toLowerCase()+e.slice(1);function Ln({defaultTheme:e,theme:t,themeId:n}){return pp(t)?e:t[n]||t}function mp(e){return e?(t,n)=>n[e]:null}function Hn(e,t){let{ownerState:n}=t,r=Ne(t,cp);const o=typeof e=="function"?e(O({ownerState:n},r)):e;if(Array.isArray(o))return o.flatMap(s=>Hn(s,O({ownerState:n},r)));if(o&&typeof o=="object"&&Array.isArray(o.variants)){const{variants:s=[]}=o;let l=Ne(o,dp);return s.forEach(c=>{let d=!0;typeof c.props=="function"?d=c.props(O({ownerState:n},r,n)):Object.keys(c.props).forEach(u=>{(n==null?void 0:n[u])!==c.props[u]&&r[u]!==c.props[u]&&(d=!1)}),d&&(Array.isArray(l)||(l=[l]),l.push(typeof c.style=="function"?c.style(O({ownerState:n},r,n)):c.style))}),l}return o}function hp(e={}){const{themeId:t,defaultTheme:n=fp,rootShouldForwardProp:r=qn,slotShouldForwardProp:o=qn}=e,s=i=>Oo(O({},i,{theme:Ln(O({},i,{defaultTheme:n,themeId:t}))}));return s.__mui_systemSx=!0,(i,l={})=>{Gr.internal_processStyles(i,v=>v.filter(P=>!(P!=null&&P.__mui_systemSx)));const{name:c,slot:d,skipVariantsResolver:u,skipSx:h,overridesResolver:w=mp(Oa(d))}=l,b=Ne(l,up),x=u!==void 0?u:d&&d!=="Root"&&d!=="root"||!1,f=h||!1;let m;process.env.NODE_ENV!=="production"&&c&&(m=`${c}-${Oa(d||"Root")}`);let S=qn;d==="Root"||d==="root"?S=r:d?S=o:wp(i)&&(S=void 0);const R=Gr(i,O({shouldForwardProp:S,label:m},b)),j=v=>typeof v=="function"&&v.__emotion_real!==v||mt(v)?P=>Hn(v,O({},P,{theme:Ln({theme:P.theme,defaultTheme:n,themeId:t})})):v,E=(v,...P)=>{let V=j(v);const U=P?P.map(j):[];c&&w&&U.push(k=>{const D=Ln(O({},k,{defaultTheme:n,themeId:t}));if(!D.components||!D.components[c]||!D.components[c].styleOverrides)return null;const $=D.components[c].styleOverrides,J={};return Object.entries($).forEach(([Y,F])=>{J[Y]=Hn(F,O({},k,{theme:D}))}),w(k,J)}),c&&!x&&U.push(k=>{var D;const $=Ln(O({},k,{defaultTheme:n,themeId:t})),J=$==null||(D=$.components)==null||(D=D[c])==null?void 0:D.variants;return Hn({variants:J},O({},k,{theme:$}))}),f||U.push(s);const C=U.length-P.length;if(Array.isArray(v)&&C>0){const k=new Array(C).fill("");V=[...v,...k],V.raw=[...v.raw,...k]}const _=R(V,...U);if(process.env.NODE_ENV!=="production"){let k;c&&(k=`${c}${Ye(d||"")}`),k===void 0&&(k=`Styled(${Vd(i)})`),_.displayName=k}return i.muiName&&(_.muiName=i.muiName),_};return R.withConfig&&(E.withConfig=R.withConfig),E}}function gp(e){const{theme:t,name:n,props:r}=e;return!t||!t.components||!t.components[n]||!t.components[n].defaultProps?r:pi(t.components[n].defaultProps,r)}function bp({props:e,name:t,defaultTheme:n,themeId:r}){let o=xi(n);return r&&(o=o[r]||o),gp({theme:o,name:t,props:e})}function Po(e,t=0,n=1){return process.env.NODE_ENV!=="production"&&(en)&&console.error(`MUI: The value provided ${e} is out of range [${t}, ${n}].`),lu(e,t,n)}function vp(e){e=e.slice(1);const t=new RegExp(`.{1,${e.length>=6?2:1}}`,"g");let n=e.match(t);return n&&n[0].length===1&&(n=n.map(r=>r+r)),n?`rgb${n.length===4?"a":""}(${n.map((r,o)=>o<3?parseInt(r,16):Math.round(parseInt(r,16)/255*1e3)/1e3).join(", ")})`:""}function Nt(e){if(e.type)return e;if(e.charAt(0)==="#")return Nt(vp(e));const t=e.indexOf("("),n=e.substring(0,t);if(["rgb","rgba","hsl","hsla","color"].indexOf(n)===-1)throw new Error(process.env.NODE_ENV!=="production"?`MUI: Unsupported \`${e}\` color. The following formats are supported: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color().`:zt(9,e));let r=e.substring(t+1,e.length-1),o;if(n==="color"){if(r=r.split(" "),o=r.shift(),r.length===4&&r[3].charAt(0)==="/"&&(r[3]=r[3].slice(1)),["srgb","display-p3","a98-rgb","prophoto-rgb","rec-2020"].indexOf(o)===-1)throw new Error(process.env.NODE_ENV!=="production"?`MUI: unsupported \`${o}\` color space. -The following color spaces are supported: srgb, display-p3, a98-rgb, prophoto-rgb, rec-2020.`:zt(10,o))}else r=r.split(",");return r=r.map(s=>parseFloat(s)),{type:n,values:r,colorSpace:o}}function vr(e){const{type:t,colorSpace:n}=e;let{values:r}=e;return t.indexOf("rgb")!==-1?r=r.map((o,s)=>s<3?parseInt(o,10):o):t.indexOf("hsl")!==-1&&(r[1]=`${r[1]}%`,r[2]=`${r[2]}%`),t.indexOf("color")!==-1?r=`${n} ${r.join(" ")}`:r=`${r.join(", ")}`,`${t}(${r})`}function xp(e){e=Nt(e);const{values:t}=e,n=t[0],r=t[1]/100,o=t[2]/100,s=r*Math.min(o,1-o),i=(d,u=(d+n/30)%12)=>o-s*Math.max(Math.min(u-3,9-u,1),-1);let l="rgb";const c=[Math.round(i(0)*255),Math.round(i(8)*255),Math.round(i(4)*255)];return e.type==="hsla"&&(l+="a",c.push(t[3])),vr({type:l,values:c})}function Ca(e){e=Nt(e);let t=e.type==="hsl"||e.type==="hsla"?Nt(xp(e)).values:e.values;return t=t.map(n=>(e.type!=="color"&&(n/=255),n<=.03928?n/12.92:((n+.055)/1.055)**2.4)),Number((.2126*t[0]+.7152*t[1]+.0722*t[2]).toFixed(3))}function Ra(e,t){const n=Ca(e),r=Ca(t);return(Math.max(n,r)+.05)/(Math.min(n,r)+.05)}function yi(e,t){return e=Nt(e),t=Ro(t),(e.type==="rgb"||e.type==="hsl")&&(e.type+="a"),e.type==="color"?e.values[3]=`/${t}`:e.values[3]=t,vr(e)}function yp(e,t){if(e=Nt(e),t=Ro(t),e.type.indexOf("hsl")!==-1)e.values[2]*=1-t;else if(e.type.indexOf("rgb")!==-1||e.type.indexOf("color")!==-1)for(let n=0;n<3;n+=1)e.values[n]*=1-t;return vr(e)}function Np(e,t){if(e=Nt(e),t=Ro(t),e.type.indexOf("hsl")!==-1)e.values[2]+=(100-e.values[2])*t;else if(e.type.indexOf("rgb")!==-1)for(let n=0;n<3;n+=1)e.values[n]+=(255-e.values[n])*t;else if(e.type.indexOf("color")!==-1)for(let n=0;n<3;n+=1)e.values[n]+=(1-e.values[n])*t;return vr(e)}function kp(e,t){return O({toolbar:{minHeight:56,[e.up("xs")]:{"@media (orientation: landscape)":{minHeight:48}},[e.up("sm")]:{minHeight:64}}},t)}const Sp={black:"#000",white:"#fff"},yn=Sp,Ep={50:"#fafafa",100:"#f5f5f5",200:"#eeeeee",300:"#e0e0e0",400:"#bdbdbd",500:"#9e9e9e",600:"#757575",700:"#616161",800:"#424242",900:"#212121",A100:"#f5f5f5",A200:"#eeeeee",A400:"#bdbdbd",A700:"#616161"},jp=Ep,Tp={50:"#f3e5f5",100:"#e1bee7",200:"#ce93d8",300:"#ba68c8",400:"#ab47bc",500:"#9c27b0",600:"#8e24aa",700:"#7b1fa2",800:"#6a1b9a",900:"#4a148c",A100:"#ea80fc",A200:"#e040fb",A400:"#d500f9",A700:"#aa00ff"},Rt=Tp,Cp={50:"#ffebee",100:"#ffcdd2",200:"#ef9a9a",300:"#e57373",400:"#ef5350",500:"#f44336",600:"#e53935",700:"#d32f2f",800:"#c62828",900:"#b71c1c",A100:"#ff8a80",A200:"#ff5252",A400:"#ff1744",A700:"#d50000"},Ot=Cp,Rp={50:"#fff3e0",100:"#ffe0b2",200:"#ffcc80",300:"#ffb74d",400:"#ffa726",500:"#ff9800",600:"#fb8c00",700:"#f57c00",800:"#ef6c00",900:"#e65100",A100:"#ffd180",A200:"#ffab40",A400:"#ff9100",A700:"#ff6d00"},on=Rp,Op={50:"#e3f2fd",100:"#bbdefb",200:"#90caf9",300:"#64b5f6",400:"#42a5f5",500:"#2196f3",600:"#1e88e5",700:"#1976d2",800:"#1565c0",900:"#0d47a1",A100:"#82b1ff",A200:"#448aff",A400:"#2979ff",A700:"#2962ff"},_t=Op,_p={50:"#e1f5fe",100:"#b3e5fc",200:"#81d4fa",300:"#4fc3f7",400:"#29b6f6",500:"#03a9f4",600:"#039be5",700:"#0288d1",800:"#0277bd",900:"#01579b",A100:"#80d8ff",A200:"#40c4ff",A400:"#00b0ff",A700:"#0091ea"},Pt=_p,Pp={50:"#e8f5e9",100:"#c8e6c9",200:"#a5d6a7",300:"#81c784",400:"#66bb6a",500:"#4caf50",600:"#43a047",700:"#388e3c",800:"#2e7d32",900:"#1b5e20",A100:"#b9f6ca",A200:"#69f0ae",A400:"#00e676",A700:"#00c853"},It=Pp,Ip=["mode","contrastThreshold","tonalOffset"],Oa={text:{primary:"rgba(0, 0, 0, 0.87)",secondary:"rgba(0, 0, 0, 0.6)",disabled:"rgba(0, 0, 0, 0.38)"},divider:"rgba(0, 0, 0, 0.12)",background:{paper:yn.white,default:yn.white},action:{active:"rgba(0, 0, 0, 0.54)",hover:"rgba(0, 0, 0, 0.04)",hoverOpacity:.04,selected:"rgba(0, 0, 0, 0.08)",selectedOpacity:.08,disabled:"rgba(0, 0, 0, 0.26)",disabledBackground:"rgba(0, 0, 0, 0.12)",disabledOpacity:.38,focus:"rgba(0, 0, 0, 0.12)",focusOpacity:.12,activatedOpacity:.12}},Vr={text:{primary:yn.white,secondary:"rgba(255, 255, 255, 0.7)",disabled:"rgba(255, 255, 255, 0.5)",icon:"rgba(255, 255, 255, 0.5)"},divider:"rgba(255, 255, 255, 0.12)",background:{paper:"#121212",default:"#121212"},action:{active:yn.white,hover:"rgba(255, 255, 255, 0.08)",hoverOpacity:.08,selected:"rgba(255, 255, 255, 0.16)",selectedOpacity:.16,disabled:"rgba(255, 255, 255, 0.3)",disabledBackground:"rgba(255, 255, 255, 0.12)",disabledOpacity:.38,focus:"rgba(255, 255, 255, 0.12)",focusOpacity:.12,activatedOpacity:.24}};function _a(e,t,n,r){const o=r.light||r,s=r.dark||r*1.5;e[t]||(e.hasOwnProperty(n)?e[t]=e[n]:t==="light"?e.light=Np(e.main,o):t==="dark"&&(e.dark=yp(e.main,s)))}function Mp(e="light"){return e==="dark"?{main:_t[200],light:_t[50],dark:_t[400]}:{main:_t[700],light:_t[400],dark:_t[800]}}function $p(e="light"){return e==="dark"?{main:Rt[200],light:Rt[50],dark:Rt[400]}:{main:Rt[500],light:Rt[300],dark:Rt[700]}}function Dp(e="light"){return e==="dark"?{main:Ot[500],light:Ot[300],dark:Ot[700]}:{main:Ot[700],light:Ot[400],dark:Ot[800]}}function Ap(e="light"){return e==="dark"?{main:Pt[400],light:Pt[300],dark:Pt[700]}:{main:Pt[700],light:Pt[500],dark:Pt[900]}}function Bp(e="light"){return e==="dark"?{main:It[400],light:It[300],dark:It[700]}:{main:It[800],light:It[500],dark:It[900]}}function Vp(e="light"){return e==="dark"?{main:on[400],light:on[300],dark:on[700]}:{main:"#ed6c02",light:on[500],dark:on[900]}}function zp(e){const{mode:t="light",contrastThreshold:n=3,tonalOffset:r=.2}=e,o=Ne(e,Ip),s=e.primary||Mp(t),i=e.secondary||$p(t),l=e.error||Dp(t),c=e.info||Ap(t),d=e.success||Bp(t),u=e.warning||Vp(t);function m(f){const h=Ra(f,Vr.text.primary)>=n?Vr.text.primary:Oa.text.primary;if(process.env.NODE_ENV!=="production"){const S=Ra(f,h);S<3&&console.error([`MUI: The contrast ratio of ${S}:1 for ${h} on ${f}`,"falls below the WCAG recommended absolute minimum contrast ratio of 3:1.","https://www.w3.org/TR/2008/REC-WCAG20-20081211/#visual-audio-contrast-contrast"].join(` -`))}return h}const w=({color:f,name:h,mainShade:S=500,lightShade:R=300,darkShade:j=700})=>{if(f=O({},f),!f.main&&f[S]&&(f.main=f[S]),!f.hasOwnProperty("main"))throw new Error(process.env.NODE_ENV!=="production"?`MUI: The color${h?` (${h})`:""} provided to augmentColor(color) is invalid. -The color object needs to have a \`main\` property or a \`${S}\` property.`:zt(11,h?` (${h})`:"",S));if(typeof f.main!="string")throw new Error(process.env.NODE_ENV!=="production"?`MUI: The color${h?` (${h})`:""} provided to augmentColor(color) is invalid. +The following color spaces are supported: srgb, display-p3, a98-rgb, prophoto-rgb, rec-2020.`:zt(10,o))}else r=r.split(",");return r=r.map(s=>parseFloat(s)),{type:n,values:r,colorSpace:o}}function xr(e){const{type:t,colorSpace:n}=e;let{values:r}=e;return t.indexOf("rgb")!==-1?r=r.map((o,s)=>s<3?parseInt(o,10):o):t.indexOf("hsl")!==-1&&(r[1]=`${r[1]}%`,r[2]=`${r[2]}%`),t.indexOf("color")!==-1?r=`${n} ${r.join(" ")}`:r=`${r.join(", ")}`,`${t}(${r})`}function xp(e){e=Nt(e);const{values:t}=e,n=t[0],r=t[1]/100,o=t[2]/100,s=r*Math.min(o,1-o),i=(d,u=(d+n/30)%12)=>o-s*Math.max(Math.min(u-3,9-u,1),-1);let l="rgb";const c=[Math.round(i(0)*255),Math.round(i(8)*255),Math.round(i(4)*255)];return e.type==="hsla"&&(l+="a",c.push(t[3])),xr({type:l,values:c})}function _a(e){e=Nt(e);let t=e.type==="hsl"||e.type==="hsla"?Nt(xp(e)).values:e.values;return t=t.map(n=>(e.type!=="color"&&(n/=255),n<=.03928?n/12.92:((n+.055)/1.055)**2.4)),Number((.2126*t[0]+.7152*t[1]+.0722*t[2]).toFixed(3))}function Pa(e,t){const n=_a(e),r=_a(t);return(Math.max(n,r)+.05)/(Math.min(n,r)+.05)}function yi(e,t){return e=Nt(e),t=Po(t),(e.type==="rgb"||e.type==="hsl")&&(e.type+="a"),e.type==="color"?e.values[3]=`/${t}`:e.values[3]=t,xr(e)}function yp(e,t){if(e=Nt(e),t=Po(t),e.type.indexOf("hsl")!==-1)e.values[2]*=1-t;else if(e.type.indexOf("rgb")!==-1||e.type.indexOf("color")!==-1)for(let n=0;n<3;n+=1)e.values[n]*=1-t;return xr(e)}function Np(e,t){if(e=Nt(e),t=Po(t),e.type.indexOf("hsl")!==-1)e.values[2]+=(100-e.values[2])*t;else if(e.type.indexOf("rgb")!==-1)for(let n=0;n<3;n+=1)e.values[n]+=(255-e.values[n])*t;else if(e.type.indexOf("color")!==-1)for(let n=0;n<3;n+=1)e.values[n]+=(1-e.values[n])*t;return xr(e)}function kp(e,t){return O({toolbar:{minHeight:56,[e.up("xs")]:{"@media (orientation: landscape)":{minHeight:48}},[e.up("sm")]:{minHeight:64}}},t)}const Sp={black:"#000",white:"#fff"},yn=Sp,Ep={50:"#fafafa",100:"#f5f5f5",200:"#eeeeee",300:"#e0e0e0",400:"#bdbdbd",500:"#9e9e9e",600:"#757575",700:"#616161",800:"#424242",900:"#212121",A100:"#f5f5f5",A200:"#eeeeee",A400:"#bdbdbd",A700:"#616161"},jp=Ep,Cp={50:"#f3e5f5",100:"#e1bee7",200:"#ce93d8",300:"#ba68c8",400:"#ab47bc",500:"#9c27b0",600:"#8e24aa",700:"#7b1fa2",800:"#6a1b9a",900:"#4a148c",A100:"#ea80fc",A200:"#e040fb",A400:"#d500f9",A700:"#aa00ff"},Rt=Cp,Tp={50:"#ffebee",100:"#ffcdd2",200:"#ef9a9a",300:"#e57373",400:"#ef5350",500:"#f44336",600:"#e53935",700:"#d32f2f",800:"#c62828",900:"#b71c1c",A100:"#ff8a80",A200:"#ff5252",A400:"#ff1744",A700:"#d50000"},Ot=Tp,Rp={50:"#fff3e0",100:"#ffe0b2",200:"#ffcc80",300:"#ffb74d",400:"#ffa726",500:"#ff9800",600:"#fb8c00",700:"#f57c00",800:"#ef6c00",900:"#e65100",A100:"#ffd180",A200:"#ffab40",A400:"#ff9100",A700:"#ff6d00"},on=Rp,Op={50:"#e3f2fd",100:"#bbdefb",200:"#90caf9",300:"#64b5f6",400:"#42a5f5",500:"#2196f3",600:"#1e88e5",700:"#1976d2",800:"#1565c0",900:"#0d47a1",A100:"#82b1ff",A200:"#448aff",A400:"#2979ff",A700:"#2962ff"},_t=Op,_p={50:"#e1f5fe",100:"#b3e5fc",200:"#81d4fa",300:"#4fc3f7",400:"#29b6f6",500:"#03a9f4",600:"#039be5",700:"#0288d1",800:"#0277bd",900:"#01579b",A100:"#80d8ff",A200:"#40c4ff",A400:"#00b0ff",A700:"#0091ea"},Pt=_p,Pp={50:"#e8f5e9",100:"#c8e6c9",200:"#a5d6a7",300:"#81c784",400:"#66bb6a",500:"#4caf50",600:"#43a047",700:"#388e3c",800:"#2e7d32",900:"#1b5e20",A100:"#b9f6ca",A200:"#69f0ae",A400:"#00e676",A700:"#00c853"},It=Pp,Ip=["mode","contrastThreshold","tonalOffset"],Ia={text:{primary:"rgba(0, 0, 0, 0.87)",secondary:"rgba(0, 0, 0, 0.6)",disabled:"rgba(0, 0, 0, 0.38)"},divider:"rgba(0, 0, 0, 0.12)",background:{paper:yn.white,default:yn.white},action:{active:"rgba(0, 0, 0, 0.54)",hover:"rgba(0, 0, 0, 0.04)",hoverOpacity:.04,selected:"rgba(0, 0, 0, 0.08)",selectedOpacity:.08,disabled:"rgba(0, 0, 0, 0.26)",disabledBackground:"rgba(0, 0, 0, 0.12)",disabledOpacity:.38,focus:"rgba(0, 0, 0, 0.12)",focusOpacity:.12,activatedOpacity:.12}},zr={text:{primary:yn.white,secondary:"rgba(255, 255, 255, 0.7)",disabled:"rgba(255, 255, 255, 0.5)",icon:"rgba(255, 255, 255, 0.5)"},divider:"rgba(255, 255, 255, 0.12)",background:{paper:"#121212",default:"#121212"},action:{active:yn.white,hover:"rgba(255, 255, 255, 0.08)",hoverOpacity:.08,selected:"rgba(255, 255, 255, 0.16)",selectedOpacity:.16,disabled:"rgba(255, 255, 255, 0.3)",disabledBackground:"rgba(255, 255, 255, 0.12)",disabledOpacity:.38,focus:"rgba(255, 255, 255, 0.12)",focusOpacity:.12,activatedOpacity:.24}};function Ma(e,t,n,r){const o=r.light||r,s=r.dark||r*1.5;e[t]||(e.hasOwnProperty(n)?e[t]=e[n]:t==="light"?e.light=Np(e.main,o):t==="dark"&&(e.dark=yp(e.main,s)))}function Mp(e="light"){return e==="dark"?{main:_t[200],light:_t[50],dark:_t[400]}:{main:_t[700],light:_t[400],dark:_t[800]}}function $p(e="light"){return e==="dark"?{main:Rt[200],light:Rt[50],dark:Rt[400]}:{main:Rt[500],light:Rt[300],dark:Rt[700]}}function Dp(e="light"){return e==="dark"?{main:Ot[500],light:Ot[300],dark:Ot[700]}:{main:Ot[700],light:Ot[400],dark:Ot[800]}}function Ap(e="light"){return e==="dark"?{main:Pt[400],light:Pt[300],dark:Pt[700]}:{main:Pt[700],light:Pt[500],dark:Pt[900]}}function Bp(e="light"){return e==="dark"?{main:It[400],light:It[300],dark:It[700]}:{main:It[800],light:It[500],dark:It[900]}}function Vp(e="light"){return e==="dark"?{main:on[400],light:on[300],dark:on[700]}:{main:"#ed6c02",light:on[500],dark:on[900]}}function zp(e){const{mode:t="light",contrastThreshold:n=3,tonalOffset:r=.2}=e,o=Ne(e,Ip),s=e.primary||Mp(t),i=e.secondary||$p(t),l=e.error||Dp(t),c=e.info||Ap(t),d=e.success||Bp(t),u=e.warning||Vp(t);function h(f){const m=Pa(f,zr.text.primary)>=n?zr.text.primary:Ia.text.primary;if(process.env.NODE_ENV!=="production"){const S=Pa(f,m);S<3&&console.error([`MUI: The contrast ratio of ${S}:1 for ${m} on ${f}`,"falls below the WCAG recommended absolute minimum contrast ratio of 3:1.","https://www.w3.org/TR/2008/REC-WCAG20-20081211/#visual-audio-contrast-contrast"].join(` +`))}return m}const w=({color:f,name:m,mainShade:S=500,lightShade:R=300,darkShade:j=700})=>{if(f=O({},f),!f.main&&f[S]&&(f.main=f[S]),!f.hasOwnProperty("main"))throw new Error(process.env.NODE_ENV!=="production"?`MUI: The color${m?` (${m})`:""} provided to augmentColor(color) is invalid. +The color object needs to have a \`main\` property or a \`${S}\` property.`:zt(11,m?` (${m})`:"",S));if(typeof f.main!="string")throw new Error(process.env.NODE_ENV!=="production"?`MUI: The color${m?` (${m})`:""} provided to augmentColor(color) is invalid. \`color.main\` should be a string, but \`${JSON.stringify(f.main)}\` was provided instead. Did you intend to use one of the following approaches? @@ -55,16 +55,16 @@ const theme1 = createTheme({ palette: { const theme2 = createTheme({ palette: { primary: { main: green[500] }, -} });`:zt(12,h?` (${h})`:"",JSON.stringify(f.main)));return _a(f,"light",R,r),_a(f,"dark",j,r),f.contrastText||(f.contrastText=m(f.main)),f},b={dark:Vr,light:Oa};return process.env.NODE_ENV!=="production"&&(b[t]||console.error(`MUI: The palette mode \`${t}\` is not supported.`)),Qe(O({common:O({},yn),mode:t,primary:w({color:s,name:"primary"}),secondary:w({color:i,name:"secondary",mainShade:"A400",lightShade:"A200",darkShade:"A700"}),error:w({color:l,name:"error"}),warning:w({color:u,name:"warning"}),info:w({color:c,name:"info"}),success:w({color:d,name:"success"}),grey:jp,contrastThreshold:n,getContrastText:m,augmentColor:w,tonalOffset:r},b[t]),o)}const Lp=["fontFamily","fontSize","fontWeightLight","fontWeightRegular","fontWeightMedium","fontWeightBold","htmlFontSize","allVariants","pxToRem"];function Fp(e){return Math.round(e*1e5)/1e5}const Pa={textTransform:"uppercase"},Ia='"Roboto", "Helvetica", "Arial", sans-serif';function Gp(e,t){const n=typeof t=="function"?t(e):t,{fontFamily:r=Ia,fontSize:o=14,fontWeightLight:s=300,fontWeightRegular:i=400,fontWeightMedium:l=500,fontWeightBold:c=700,htmlFontSize:d=16,allVariants:u,pxToRem:m}=n,w=Ne(n,Lp);process.env.NODE_ENV!=="production"&&(typeof o!="number"&&console.error("MUI: `fontSize` is required to be a number."),typeof d!="number"&&console.error("MUI: `htmlFontSize` is required to be a number."));const b=o/14,x=m||(S=>`${S/d*b}rem`),f=(S,R,j,E,v)=>O({fontFamily:r,fontWeight:S,fontSize:x(R),lineHeight:j},r===Ia?{letterSpacing:`${Fp(E/R)}em`}:{},v,u),h={h1:f(s,96,1.167,-1.5),h2:f(s,60,1.2,-.5),h3:f(i,48,1.167,0),h4:f(i,34,1.235,.25),h5:f(i,24,1.334,0),h6:f(l,20,1.6,.15),subtitle1:f(i,16,1.75,.15),subtitle2:f(l,14,1.57,.1),body1:f(i,16,1.5,.15),body2:f(i,14,1.43,.15),button:f(l,14,1.75,.4,Pa),caption:f(i,12,1.66,.4),overline:f(i,12,2.66,1,Pa),inherit:{fontFamily:"inherit",fontWeight:"inherit",fontSize:"inherit",lineHeight:"inherit",letterSpacing:"inherit"}};return Qe(O({htmlFontSize:d,pxToRem:x,fontFamily:r,fontSize:o,fontWeightLight:s,fontWeightRegular:i,fontWeightMedium:l,fontWeightBold:c},h),w,{clone:!1})}const Up=.2,qp=.14,Hp=.12;function we(...e){return[`${e[0]}px ${e[1]}px ${e[2]}px ${e[3]}px rgba(0,0,0,${Up})`,`${e[4]}px ${e[5]}px ${e[6]}px ${e[7]}px rgba(0,0,0,${qp})`,`${e[8]}px ${e[9]}px ${e[10]}px ${e[11]}px rgba(0,0,0,${Hp})`].join(",")}const Xp=["none",we(0,2,1,-1,0,1,1,0,0,1,3,0),we(0,3,1,-2,0,2,2,0,0,1,5,0),we(0,3,3,-2,0,3,4,0,0,1,8,0),we(0,2,4,-1,0,4,5,0,0,1,10,0),we(0,3,5,-1,0,5,8,0,0,1,14,0),we(0,3,5,-1,0,6,10,0,0,1,18,0),we(0,4,5,-2,0,7,10,1,0,2,16,1),we(0,5,5,-3,0,8,10,1,0,3,14,2),we(0,5,6,-3,0,9,12,1,0,3,16,2),we(0,6,6,-3,0,10,14,1,0,4,18,3),we(0,6,7,-4,0,11,15,1,0,4,20,3),we(0,7,8,-4,0,12,17,2,0,5,22,4),we(0,7,8,-4,0,13,19,2,0,5,24,4),we(0,7,9,-4,0,14,21,2,0,5,26,4),we(0,8,9,-5,0,15,22,2,0,6,28,5),we(0,8,10,-5,0,16,24,2,0,6,30,5),we(0,8,11,-5,0,17,26,2,0,6,32,5),we(0,9,11,-5,0,18,28,2,0,7,34,6),we(0,9,12,-6,0,19,29,2,0,7,36,6),we(0,10,13,-6,0,20,31,3,0,8,38,7),we(0,10,13,-6,0,21,33,3,0,8,40,7),we(0,10,14,-6,0,22,35,3,0,8,42,7),we(0,11,14,-7,0,23,36,3,0,9,44,8),we(0,11,15,-7,0,24,38,3,0,9,46,8)],Yp=Xp,Wp=["duration","easing","delay"],Kp={easeInOut:"cubic-bezier(0.4, 0, 0.2, 1)",easeOut:"cubic-bezier(0.0, 0, 0.2, 1)",easeIn:"cubic-bezier(0.4, 0, 1, 1)",sharp:"cubic-bezier(0.4, 0, 0.6, 1)"},Jp={shortest:150,shorter:200,short:250,standard:300,complex:375,enteringScreen:225,leavingScreen:195};function Ma(e){return`${Math.round(e)}ms`}function Zp(e){if(!e)return 0;const t=e/36;return Math.round((4+15*t**.25+t/5)*10)}function Qp(e){const t=O({},Kp,e.easing),n=O({},Jp,e.duration);return O({getAutoHeightDuration:Zp,create:(o=["all"],s={})=>{const{duration:i=n.standard,easing:l=t.easeInOut,delay:c=0}=s,d=Ne(s,Wp);if(process.env.NODE_ENV!=="production"){const u=w=>typeof w=="string",m=w=>!isNaN(parseFloat(w));!u(o)&&!Array.isArray(o)&&console.error('MUI: Argument "props" must be a string or Array.'),!m(i)&&!u(i)&&console.error(`MUI: Argument "duration" must be a number or a string but found ${i}.`),u(l)||console.error('MUI: Argument "easing" must be a string.'),!m(c)&&!u(c)&&console.error('MUI: Argument "delay" must be a number or a string.'),typeof s!="object"&&console.error(["MUI: Secong argument of transition.create must be an object.","Arguments should be either `create('prop1', options)` or `create(['prop1', 'prop2'], options)`"].join(` -`)),Object.keys(d).length!==0&&console.error(`MUI: Unrecognized argument(s) [${Object.keys(d).join(",")}].`)}return(Array.isArray(o)?o:[o]).map(u=>`${u} ${typeof i=="string"?i:Ma(i)} ${l} ${typeof c=="string"?c:Ma(c)}`).join(",")}},e,{easing:t,duration:n})}const ew={mobileStepper:1e3,fab:1050,speedDial:1050,appBar:1100,drawer:1200,modal:1300,snackbar:1400,tooltip:1500},tw=ew,nw=["breakpoints","mixins","spacing","palette","transitions","typography","shape"];function rw(e={},...t){const{mixins:n={},palette:r={},transitions:o={},typography:s={}}=e,i=Ne(e,nw);if(e.vars)throw new Error(process.env.NODE_ENV!=="production"?"MUI: `vars` is a private field used for CSS variables support.\nPlease use another name.":zt(18));const l=zp(r),c=Co(e);let d=Qe(c,{mixins:kp(c.breakpoints,n),palette:l,shadows:Yp.slice(),typography:Gp(l,s),transitions:Qp(o),zIndex:O({},tw)});if(d=Qe(d,i),d=t.reduce((u,m)=>Qe(u,m),d),process.env.NODE_ENV!=="production"){const u=["active","checked","completed","disabled","error","expanded","focused","focusVisible","required","selected"],m=(w,b)=>{let x;for(x in w){const f=w[x];if(u.indexOf(x)!==-1&&Object.keys(f).length>0){if(process.env.NODE_ENV!=="production"){const h=dr("",x);console.error([`MUI: The \`${b}\` component increases the CSS specificity of the \`${x}\` internal state.`,"You can not override it like this: ",JSON.stringify(w,null,2),"",`Instead, you need to use the '&.${h}' syntax:`,JSON.stringify({root:{[`&.${h}`]:f}},null,2),"","https://mui.com/r/state-classes-guide"].join(` -`))}w[x]={}}}};Object.keys(d.components).forEach(w=>{const b=d.components[w].styleOverrides;b&&w.indexOf("Mui")===0&&m(b,w)})}return d.unstable_sxConfig=O({},jo,i==null?void 0:i.unstable_sxConfig),d.unstable_sx=function(m){return To({sx:m,theme:this})},d}const ow=rw(),Oo=ow,_o="$$material";function Po({props:e,name:t}){return bp({props:e,name:t,defaultTheme:Oo,themeId:_o})}const aw=e=>qn(e)&&e!=="classes",sw=hp({themeId:_o,defaultTheme:Oo,rootShouldForwardProp:aw}),In=sw;function iw(e){return dr("MuiSvgIcon",e)}mi("MuiSvgIcon",["root","colorPrimary","colorSecondary","colorAction","colorError","colorDisabled","fontSizeInherit","fontSizeSmall","fontSizeMedium","fontSizeLarge"]);const lw=["children","className","color","component","fontSize","htmlColor","inheritViewBox","titleAccess","viewBox"],cw=e=>{const{color:t,fontSize:n,classes:r}=e,o={root:["root",t!=="inherit"&&`color${Ye(t)}`,`fontSize${Ye(n)}`]};return ko(o,iw,r)},dw=In("svg",{name:"MuiSvgIcon",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.root,n.color!=="inherit"&&t[`color${Ye(n.color)}`],t[`fontSize${Ye(n.fontSize)}`]]}})(({theme:e,ownerState:t})=>{var n,r,o,s,i,l,c,d,u,m,w,b,x;return{userSelect:"none",width:"1em",height:"1em",display:"inline-block",fill:t.hasSvgAsChild?void 0:"currentColor",flexShrink:0,transition:(n=e.transitions)==null||(r=n.create)==null?void 0:r.call(n,"fill",{duration:(o=e.transitions)==null||(o=o.duration)==null?void 0:o.shorter}),fontSize:{inherit:"inherit",small:((s=e.typography)==null||(i=s.pxToRem)==null?void 0:i.call(s,20))||"1.25rem",medium:((l=e.typography)==null||(c=l.pxToRem)==null?void 0:c.call(l,24))||"1.5rem",large:((d=e.typography)==null||(u=d.pxToRem)==null?void 0:u.call(d,35))||"2.1875rem"}[t.fontSize],color:(m=(w=(e.vars||e).palette)==null||(w=w[t.color])==null?void 0:w.main)!=null?m:{action:(b=(e.vars||e).palette)==null||(b=b.action)==null?void 0:b.active,disabled:(x=(e.vars||e).palette)==null||(x=x.action)==null?void 0:x.disabled,inherit:void 0}[t.color]}}),Io=M.forwardRef(function(t,n){const r=Po({props:t,name:"MuiSvgIcon"}),{children:o,className:s,color:i="inherit",component:l="svg",fontSize:c="medium",htmlColor:d,inheritViewBox:u=!1,titleAccess:m,viewBox:w="0 0 24 24"}=r,b=Ne(r,lw),x=M.isValidElement(o)&&o.type==="svg",f=O({},r,{color:i,component:l,fontSize:c,instanceFontSize:t.fontSize,inheritViewBox:u,viewBox:w,hasSvgAsChild:x}),h={};u||(h.viewBox=w);const S=cw(f);return a.jsxs(dw,O({as:l,className:ot(S.root,s),focusable:"false",color:d,"aria-hidden":m?void 0:!0,role:m?"img":void 0,ref:n},h,b,x&&o.props,{ownerState:f,children:[x?o.props.children:o,m?a.jsx("title",{children:m}):null]}))});process.env.NODE_ENV!=="production"&&(Io.propTypes={children:p.node,classes:p.object,className:p.string,color:p.oneOfType([p.oneOf(["inherit","action","disabled","primary","secondary","error","info","success","warning"]),p.string]),component:p.elementType,fontSize:p.oneOfType([p.oneOf(["inherit","large","medium","small"]),p.string]),htmlColor:p.string,inheritViewBox:p.bool,shapeRendering:p.string,sx:p.oneOfType([p.arrayOf(p.oneOfType([p.func,p.object,p.bool])),p.func,p.object]),titleAccess:p.string,viewBox:p.string});Io.muiName="SvgIcon";const $a=Io;function Ni(e,t){function n(r,o){return a.jsx($a,O({"data-testid":`${t}Icon`,ref:o},r,{children:e}))}return process.env.NODE_ENV!=="production"&&(n.displayName=`${t}Icon`),n.muiName=$a.muiName,M.memo(M.forwardRef(n))}const uw={configure:e=>{process.env.NODE_ENV!=="production"&&console.warn(["MUI: `ClassNameGenerator` import from `@mui/material/utils` is outdated and might cause unexpected issues.","","You should use `import { unstable_ClassNameGenerator } from '@mui/material/className'` instead","","The detail of the issue: https://github.com/mui/material-ui/issues/30011#issuecomment-1024993401","","The updated documentation: https://mui.com/guides/classname-generator/"].join(` -`)),wi.configure(e)}},pw=Object.freeze(Object.defineProperty({__proto__:null,capitalize:Ye,createChainedFunction:Ld,createSvgIcon:Ni,debounce:Fd,deprecatedPropType:Gd,isMuiElement:Ud,ownerDocument:Wn,ownerWindow:qd,requirePropFactory:Hd,setRef:Kn,unstable_ClassNameGenerator:uw,unstable_useEnhancedEffect:Lt,unstable_useId:ci,unsupportedProp:Wd,useControlled:di,useEventCallback:Wr,useForkRef:yt,useIsFocusVisible:ui},Symbol.toStringTag,{value:"Module"})),ww=yd(pw);var Da;function fw(){return Da||(Da=1,function(e){"use client";Object.defineProperty(e,"__esModule",{value:!0}),Object.defineProperty(e,"default",{enumerable:!0,get:function(){return t.createSvgIcon}});var t=ww}(_r)),_r}var mw=Nd;Object.defineProperty(xo,"__esModule",{value:!0});var ki=xo.default=void 0,hw=mw(fw()),gw=a;ki=xo.default=(0,hw.default)((0,gw.jsx)("path",{d:"m10 17 5-5-5-5z"}),"ArrowRight");function bw(e){return typeof e=="string"}function un(e,t,n){return e===void 0||bw(e)?t:O({},t,{ownerState:O({},t.ownerState,n)})}const vw={disableDefaultClasses:!1},xw=M.createContext(vw);function yw(e){const{disableDefaultClasses:t}=M.useContext(xw);return n=>t?"":e(n)}function Nw(e,t=[]){if(e===void 0)return{};const n={};return Object.keys(e).filter(r=>r.match(/^on[A-Z]/)&&typeof e[r]=="function"&&!t.includes(r)).forEach(r=>{n[r]=e[r]}),n}function kw(e,t,n){return typeof e=="function"?e(t,n):e}function Aa(e){if(e===void 0)return{};const t={};return Object.keys(e).filter(n=>!(n.match(/^on[A-Z]/)&&typeof e[n]=="function")).forEach(n=>{t[n]=e[n]}),t}function Sw(e){const{getSlotProps:t,additionalProps:n,externalSlotProps:r,externalForwardedProps:o,className:s}=e;if(!t){const b=ot(n==null?void 0:n.className,s,o==null?void 0:o.className,r==null?void 0:r.className),x=O({},n==null?void 0:n.style,o==null?void 0:o.style,r==null?void 0:r.style),f=O({},n,o,r);return b.length>0&&(f.className=b),Object.keys(x).length>0&&(f.style=x),{props:f,internalRef:void 0}}const i=Nw(O({},o,r)),l=Aa(r),c=Aa(o),d=t(i),u=ot(d==null?void 0:d.className,n==null?void 0:n.className,s,o==null?void 0:o.className,r==null?void 0:r.className),m=O({},d==null?void 0:d.style,n==null?void 0:n.style,o==null?void 0:o.style,r==null?void 0:r.style),w=O({},d,n,c,l);return u.length>0&&(w.className=u),Object.keys(m).length>0&&(w.style=m),{props:w,internalRef:d.ref}}const Ew=["elementType","externalSlotProps","ownerState","skipResolvingSlotProps"];function jw(e){var t;const{elementType:n,externalSlotProps:r,ownerState:o,skipResolvingSlotProps:s=!1}=e,i=Ne(e,Ew),l=s?{}:kw(r,o),{props:c,internalRef:d}=Sw(O({},i,{externalSlotProps:l})),u=yt(d,l==null?void 0:l.ref,(t=e.additionalProps)==null?void 0:t.ref);return un(n,O({},c,{ref:u}),o)}const Si="base";function Tw(e){return`${Si}--${e}`}function Cw(e,t){return`${Si}-${e}-${t}`}function Ei(e,t){const n=fi[t];return n?Tw(n):Cw(e,t)}function Rw(e,t){const n={};return t.forEach(r=>{n[r]=Ei(e,r)}),n}function Ow(e){return typeof e=="function"?e():e}const Zn=M.forwardRef(function(t,n){const{children:r,container:o,disablePortal:s=!1}=t,[i,l]=M.useState(null),c=yt(M.isValidElement(r)?r.ref:null,n);if(Lt(()=>{s||l(Ow(o)||document.body)},[o,s]),Lt(()=>{if(i&&!s)return Kn(n,i),()=>{Kn(n,null)}},[n,i,s]),s){if(M.isValidElement(r)){const d={ref:c};return M.cloneElement(r,d)}return a.jsx(M.Fragment,{children:r})}return a.jsx(M.Fragment,{children:i&&Ol.createPortal(r,i)})});process.env.NODE_ENV!=="production"&&(Zn.propTypes={children:p.node,container:p.oneOfType([xn,p.func]),disablePortal:p.bool});process.env.NODE_ENV!=="production"&&(Zn["propTypes"]=Md(Zn.propTypes));var Ce="top",ze="bottom",Le="right",Re="left",Mo="auto",Mn=[Ce,ze,Le,Re],Ft="start",Nn="end",_w="clippingParents",ji="viewport",an="popper",Pw="reference",Ba=Mn.reduce(function(e,t){return e.concat([t+"-"+Ft,t+"-"+Nn])},[]),Ti=[].concat(Mn,[Mo]).reduce(function(e,t){return e.concat([t,t+"-"+Ft,t+"-"+Nn])},[]),Iw="beforeRead",Mw="read",$w="afterRead",Dw="beforeMain",Aw="main",Bw="afterMain",Vw="beforeWrite",zw="write",Lw="afterWrite",Fw=[Iw,Mw,$w,Dw,Aw,Bw,Vw,zw,Lw];function We(e){return e?(e.nodeName||"").toLowerCase():null}function $e(e){if(e==null)return window;if(e.toString()!=="[object Window]"){var t=e.ownerDocument;return t&&t.defaultView||window}return e}function kt(e){var t=$e(e).Element;return e instanceof t||e instanceof Element}function Ve(e){var t=$e(e).HTMLElement;return e instanceof t||e instanceof HTMLElement}function $o(e){if(typeof ShadowRoot>"u")return!1;var t=$e(e).ShadowRoot;return e instanceof t||e instanceof ShadowRoot}function Gw(e){var t=e.state;Object.keys(t.elements).forEach(function(n){var r=t.styles[n]||{},o=t.attributes[n]||{},s=t.elements[n];!Ve(s)||!We(s)||(Object.assign(s.style,r),Object.keys(o).forEach(function(i){var l=o[i];l===!1?s.removeAttribute(i):s.setAttribute(i,l===!0?"":l)}))})}function Uw(e){var t=e.state,n={popper:{position:t.options.strategy,left:"0",top:"0",margin:"0"},arrow:{position:"absolute"},reference:{}};return Object.assign(t.elements.popper.style,n.popper),t.styles=n,t.elements.arrow&&Object.assign(t.elements.arrow.style,n.arrow),function(){Object.keys(t.elements).forEach(function(r){var o=t.elements[r],s=t.attributes[r]||{},i=Object.keys(t.styles.hasOwnProperty(r)?t.styles[r]:n[r]),l=i.reduce(function(c,d){return c[d]="",c},{});!Ve(o)||!We(o)||(Object.assign(o.style,l),Object.keys(s).forEach(function(c){o.removeAttribute(c)}))})}}const qw={name:"applyStyles",enabled:!0,phase:"write",fn:Gw,effect:Uw,requires:["computeStyles"]};function Xe(e){return e.split("-")[0]}var ht=Math.max,Qn=Math.min,Gt=Math.round;function Jr(){var e=navigator.userAgentData;return e!=null&&e.brands&&Array.isArray(e.brands)?e.brands.map(function(t){return t.brand+"/"+t.version}).join(" "):navigator.userAgent}function Ci(){return!/^((?!chrome|android).)*safari/i.test(Jr())}function Ut(e,t,n){t===void 0&&(t=!1),n===void 0&&(n=!1);var r=e.getBoundingClientRect(),o=1,s=1;t&&Ve(e)&&(o=e.offsetWidth>0&&Gt(r.width)/e.offsetWidth||1,s=e.offsetHeight>0&&Gt(r.height)/e.offsetHeight||1);var i=kt(e)?$e(e):window,l=i.visualViewport,c=!Ci()&&n,d=(r.left+(c&&l?l.offsetLeft:0))/o,u=(r.top+(c&&l?l.offsetTop:0))/s,m=r.width/o,w=r.height/s;return{width:m,height:w,top:u,right:d+m,bottom:u+w,left:d,x:d,y:u}}function Do(e){var t=Ut(e),n=e.offsetWidth,r=e.offsetHeight;return Math.abs(t.width-n)<=1&&(n=t.width),Math.abs(t.height-r)<=1&&(r=t.height),{x:e.offsetLeft,y:e.offsetTop,width:n,height:r}}function Ri(e,t){var n=t.getRootNode&&t.getRootNode();if(e.contains(t))return!0;if(n&&$o(n)){var r=t;do{if(r&&e.isSameNode(r))return!0;r=r.parentNode||r.host}while(r)}return!1}function tt(e){return $e(e).getComputedStyle(e)}function Hw(e){return["table","td","th"].indexOf(We(e))>=0}function it(e){return((kt(e)?e.ownerDocument:e.document)||window.document).documentElement}function xr(e){return We(e)==="html"?e:e.assignedSlot||e.parentNode||($o(e)?e.host:null)||it(e)}function Va(e){return!Ve(e)||tt(e).position==="fixed"?null:e.offsetParent}function Xw(e){var t=/firefox/i.test(Jr()),n=/Trident/i.test(Jr());if(n&&Ve(e)){var r=tt(e);if(r.position==="fixed")return null}var o=xr(e);for($o(o)&&(o=o.host);Ve(o)&&["html","body"].indexOf(We(o))<0;){var s=tt(o);if(s.transform!=="none"||s.perspective!=="none"||s.contain==="paint"||["transform","perspective"].indexOf(s.willChange)!==-1||t&&s.willChange==="filter"||t&&s.filter&&s.filter!=="none")return o;o=o.parentNode}return null}function $n(e){for(var t=$e(e),n=Va(e);n&&Hw(n)&&tt(n).position==="static";)n=Va(n);return n&&(We(n)==="html"||We(n)==="body"&&tt(n).position==="static")?t:n||Xw(e)||t}function Ao(e){return["top","bottom"].indexOf(e)>=0?"x":"y"}function hn(e,t,n){return ht(e,Qn(t,n))}function Yw(e,t,n){var r=hn(e,t,n);return r>n?n:r}function Oi(){return{top:0,right:0,bottom:0,left:0}}function _i(e){return Object.assign({},Oi(),e)}function Pi(e,t){return t.reduce(function(n,r){return n[r]=e,n},{})}var Ww=function(t,n){return t=typeof t=="function"?t(Object.assign({},n.rects,{placement:n.placement})):t,_i(typeof t!="number"?t:Pi(t,Mn))};function Kw(e){var t,n=e.state,r=e.name,o=e.options,s=n.elements.arrow,i=n.modifiersData.popperOffsets,l=Xe(n.placement),c=Ao(l),d=[Re,Le].indexOf(l)>=0,u=d?"height":"width";if(!(!s||!i)){var m=Ww(o.padding,n),w=Do(s),b=c==="y"?Ce:Re,x=c==="y"?ze:Le,f=n.rects.reference[u]+n.rects.reference[c]-i[c]-n.rects.popper[u],h=i[c]-n.rects.reference[c],S=$n(s),R=S?c==="y"?S.clientHeight||0:S.clientWidth||0:0,j=f/2-h/2,E=m[b],v=R-w[u]-m[x],P=R/2-w[u]/2+j,V=hn(E,P,v),U=c;n.modifiersData[r]=(t={},t[U]=V,t.centerOffset=V-P,t)}}function Jw(e){var t=e.state,n=e.options,r=n.element,o=r===void 0?"[data-popper-arrow]":r;o!=null&&(typeof o=="string"&&(o=t.elements.popper.querySelector(o),!o)||Ri(t.elements.popper,o)&&(t.elements.arrow=o))}const Zw={name:"arrow",enabled:!0,phase:"main",fn:Kw,effect:Jw,requires:["popperOffsets"],requiresIfExists:["preventOverflow"]};function qt(e){return e.split("-")[1]}var Qw={top:"auto",right:"auto",bottom:"auto",left:"auto"};function ef(e,t){var n=e.x,r=e.y,o=t.devicePixelRatio||1;return{x:Gt(n*o)/o||0,y:Gt(r*o)/o||0}}function za(e){var t,n=e.popper,r=e.popperRect,o=e.placement,s=e.variation,i=e.offsets,l=e.position,c=e.gpuAcceleration,d=e.adaptive,u=e.roundOffsets,m=e.isFixed,w=i.x,b=w===void 0?0:w,x=i.y,f=x===void 0?0:x,h=typeof u=="function"?u({x:b,y:f}):{x:b,y:f};b=h.x,f=h.y;var S=i.hasOwnProperty("x"),R=i.hasOwnProperty("y"),j=Re,E=Ce,v=window;if(d){var P=$n(n),V="clientHeight",U="clientWidth";if(P===$e(n)&&(P=it(n),tt(P).position!=="static"&&l==="absolute"&&(V="scrollHeight",U="scrollWidth")),P=P,o===Ce||(o===Re||o===Le)&&s===Nn){E=ze;var T=m&&P===v&&v.visualViewport?v.visualViewport.height:P[V];f-=T-r.height,f*=c?1:-1}if(o===Re||(o===Ce||o===ze)&&s===Nn){j=Le;var _=m&&P===v&&v.visualViewport?v.visualViewport.width:P[U];b-=_-r.width,b*=c?1:-1}}var k=Object.assign({position:l},d&&Qw),D=u===!0?ef({x:b,y:f},$e(n)):{x:b,y:f};if(b=D.x,f=D.y,c){var $;return Object.assign({},k,($={},$[E]=R?"0":"",$[j]=S?"0":"",$.transform=(v.devicePixelRatio||1)<=1?"translate("+b+"px, "+f+"px)":"translate3d("+b+"px, "+f+"px, 0)",$))}return Object.assign({},k,(t={},t[E]=R?f+"px":"",t[j]=S?b+"px":"",t.transform="",t))}function tf(e){var t=e.state,n=e.options,r=n.gpuAcceleration,o=r===void 0?!0:r,s=n.adaptive,i=s===void 0?!0:s,l=n.roundOffsets,c=l===void 0?!0:l,d={placement:Xe(t.placement),variation:qt(t.placement),popper:t.elements.popper,popperRect:t.rects.popper,gpuAcceleration:o,isFixed:t.options.strategy==="fixed"};t.modifiersData.popperOffsets!=null&&(t.styles.popper=Object.assign({},t.styles.popper,za(Object.assign({},d,{offsets:t.modifiersData.popperOffsets,position:t.options.strategy,adaptive:i,roundOffsets:c})))),t.modifiersData.arrow!=null&&(t.styles.arrow=Object.assign({},t.styles.arrow,za(Object.assign({},d,{offsets:t.modifiersData.arrow,position:"absolute",adaptive:!1,roundOffsets:c})))),t.attributes.popper=Object.assign({},t.attributes.popper,{"data-popper-placement":t.placement})}const nf={name:"computeStyles",enabled:!0,phase:"beforeWrite",fn:tf,data:{}};var Fn={passive:!0};function rf(e){var t=e.state,n=e.instance,r=e.options,o=r.scroll,s=o===void 0?!0:o,i=r.resize,l=i===void 0?!0:i,c=$e(t.elements.popper),d=[].concat(t.scrollParents.reference,t.scrollParents.popper);return s&&d.forEach(function(u){u.addEventListener("scroll",n.update,Fn)}),l&&c.addEventListener("resize",n.update,Fn),function(){s&&d.forEach(function(u){u.removeEventListener("scroll",n.update,Fn)}),l&&c.removeEventListener("resize",n.update,Fn)}}const of={name:"eventListeners",enabled:!0,phase:"write",fn:function(){},effect:rf,data:{}};var af={left:"right",right:"left",bottom:"top",top:"bottom"};function Xn(e){return e.replace(/left|right|bottom|top/g,function(t){return af[t]})}var sf={start:"end",end:"start"};function La(e){return e.replace(/start|end/g,function(t){return sf[t]})}function Bo(e){var t=$e(e),n=t.pageXOffset,r=t.pageYOffset;return{scrollLeft:n,scrollTop:r}}function Vo(e){return Ut(it(e)).left+Bo(e).scrollLeft}function lf(e,t){var n=$e(e),r=it(e),o=n.visualViewport,s=r.clientWidth,i=r.clientHeight,l=0,c=0;if(o){s=o.width,i=o.height;var d=Ci();(d||!d&&t==="fixed")&&(l=o.offsetLeft,c=o.offsetTop)}return{width:s,height:i,x:l+Vo(e),y:c}}function cf(e){var t,n=it(e),r=Bo(e),o=(t=e.ownerDocument)==null?void 0:t.body,s=ht(n.scrollWidth,n.clientWidth,o?o.scrollWidth:0,o?o.clientWidth:0),i=ht(n.scrollHeight,n.clientHeight,o?o.scrollHeight:0,o?o.clientHeight:0),l=-r.scrollLeft+Vo(e),c=-r.scrollTop;return tt(o||n).direction==="rtl"&&(l+=ht(n.clientWidth,o?o.clientWidth:0)-s),{width:s,height:i,x:l,y:c}}function zo(e){var t=tt(e),n=t.overflow,r=t.overflowX,o=t.overflowY;return/auto|scroll|overlay|hidden/.test(n+o+r)}function Ii(e){return["html","body","#document"].indexOf(We(e))>=0?e.ownerDocument.body:Ve(e)&&zo(e)?e:Ii(xr(e))}function gn(e,t){var n;t===void 0&&(t=[]);var r=Ii(e),o=r===((n=e.ownerDocument)==null?void 0:n.body),s=$e(r),i=o?[s].concat(s.visualViewport||[],zo(r)?r:[]):r,l=t.concat(i);return o?l:l.concat(gn(xr(i)))}function Zr(e){return Object.assign({},e,{left:e.x,top:e.y,right:e.x+e.width,bottom:e.y+e.height})}function df(e,t){var n=Ut(e,!1,t==="fixed");return n.top=n.top+e.clientTop,n.left=n.left+e.clientLeft,n.bottom=n.top+e.clientHeight,n.right=n.left+e.clientWidth,n.width=e.clientWidth,n.height=e.clientHeight,n.x=n.left,n.y=n.top,n}function Fa(e,t,n){return t===ji?Zr(lf(e,n)):kt(t)?df(t,n):Zr(cf(it(e)))}function uf(e){var t=gn(xr(e)),n=["absolute","fixed"].indexOf(tt(e).position)>=0,r=n&&Ve(e)?$n(e):e;return kt(r)?t.filter(function(o){return kt(o)&&Ri(o,r)&&We(o)!=="body"}):[]}function pf(e,t,n,r){var o=t==="clippingParents"?uf(e):[].concat(t),s=[].concat(o,[n]),i=s[0],l=s.reduce(function(c,d){var u=Fa(e,d,r);return c.top=ht(u.top,c.top),c.right=Qn(u.right,c.right),c.bottom=Qn(u.bottom,c.bottom),c.left=ht(u.left,c.left),c},Fa(e,i,r));return l.width=l.right-l.left,l.height=l.bottom-l.top,l.x=l.left,l.y=l.top,l}function Mi(e){var t=e.reference,n=e.element,r=e.placement,o=r?Xe(r):null,s=r?qt(r):null,i=t.x+t.width/2-n.width/2,l=t.y+t.height/2-n.height/2,c;switch(o){case Ce:c={x:i,y:t.y-n.height};break;case ze:c={x:i,y:t.y+t.height};break;case Le:c={x:t.x+t.width,y:l};break;case Re:c={x:t.x-n.width,y:l};break;default:c={x:t.x,y:t.y}}var d=o?Ao(o):null;if(d!=null){var u=d==="y"?"height":"width";switch(s){case Ft:c[d]=c[d]-(t[u]/2-n[u]/2);break;case Nn:c[d]=c[d]+(t[u]/2-n[u]/2);break}}return c}function kn(e,t){t===void 0&&(t={});var n=t,r=n.placement,o=r===void 0?e.placement:r,s=n.strategy,i=s===void 0?e.strategy:s,l=n.boundary,c=l===void 0?_w:l,d=n.rootBoundary,u=d===void 0?ji:d,m=n.elementContext,w=m===void 0?an:m,b=n.altBoundary,x=b===void 0?!1:b,f=n.padding,h=f===void 0?0:f,S=_i(typeof h!="number"?h:Pi(h,Mn)),R=w===an?Pw:an,j=e.rects.popper,E=e.elements[x?R:w],v=pf(kt(E)?E:E.contextElement||it(e.elements.popper),c,u,i),P=Ut(e.elements.reference),V=Mi({reference:P,element:j,strategy:"absolute",placement:o}),U=Zr(Object.assign({},j,V)),T=w===an?U:P,_={top:v.top-T.top+S.top,bottom:T.bottom-v.bottom+S.bottom,left:v.left-T.left+S.left,right:T.right-v.right+S.right},k=e.modifiersData.offset;if(w===an&&k){var D=k[o];Object.keys(_).forEach(function($){var J=[Le,ze].indexOf($)>=0?1:-1,Y=[Ce,ze].indexOf($)>=0?"y":"x";_[$]+=D[Y]*J})}return _}function wf(e,t){t===void 0&&(t={});var n=t,r=n.placement,o=n.boundary,s=n.rootBoundary,i=n.padding,l=n.flipVariations,c=n.allowedAutoPlacements,d=c===void 0?Ti:c,u=qt(r),m=u?l?Ba:Ba.filter(function(x){return qt(x)===u}):Mn,w=m.filter(function(x){return d.indexOf(x)>=0});w.length===0&&(w=m);var b=w.reduce(function(x,f){return x[f]=kn(e,{placement:f,boundary:o,rootBoundary:s,padding:i})[Xe(f)],x},{});return Object.keys(b).sort(function(x,f){return b[x]-b[f]})}function ff(e){if(Xe(e)===Mo)return[];var t=Xn(e);return[La(e),t,La(t)]}function mf(e){var t=e.state,n=e.options,r=e.name;if(!t.modifiersData[r]._skip){for(var o=n.mainAxis,s=o===void 0?!0:o,i=n.altAxis,l=i===void 0?!0:i,c=n.fallbackPlacements,d=n.padding,u=n.boundary,m=n.rootBoundary,w=n.altBoundary,b=n.flipVariations,x=b===void 0?!0:b,f=n.allowedAutoPlacements,h=t.options.placement,S=Xe(h),R=S===h,j=c||(R||!x?[Xn(h)]:ff(h)),E=[h].concat(j).reduce(function(B,X){return B.concat(Xe(X)===Mo?wf(t,{placement:X,boundary:u,rootBoundary:m,padding:d,flipVariations:x,allowedAutoPlacements:f}):X)},[]),v=t.rects.reference,P=t.rects.popper,V=new Map,U=!0,T=E[0],_=0;_=0,Y=J?"width":"height",F=kn(t,{placement:k,boundary:u,rootBoundary:m,altBoundary:w,padding:d}),te=J?$?Le:Re:$?ze:Ce;v[Y]>P[Y]&&(te=Xn(te));var se=Xn(te),oe=[];if(s&&oe.push(F[D]<=0),l&&oe.push(F[te]<=0,F[se]<=0),oe.every(function(B){return B})){T=k,U=!1;break}V.set(k,oe)}if(U)for(var y=x?3:1,C=function(X){var q=E.find(function(H){var G=V.get(H);if(G)return G.slice(0,X).every(function(K){return K})});if(q)return T=q,"break"},z=y;z>0;z--){var L=C(z);if(L==="break")break}t.placement!==T&&(t.modifiersData[r]._skip=!0,t.placement=T,t.reset=!0)}}const hf={name:"flip",enabled:!0,phase:"main",fn:mf,requiresIfExists:["offset"],data:{_skip:!1}};function Ga(e,t,n){return n===void 0&&(n={x:0,y:0}),{top:e.top-t.height-n.y,right:e.right-t.width+n.x,bottom:e.bottom-t.height+n.y,left:e.left-t.width-n.x}}function Ua(e){return[Ce,Le,ze,Re].some(function(t){return e[t]>=0})}function gf(e){var t=e.state,n=e.name,r=t.rects.reference,o=t.rects.popper,s=t.modifiersData.preventOverflow,i=kn(t,{elementContext:"reference"}),l=kn(t,{altBoundary:!0}),c=Ga(i,r),d=Ga(l,o,s),u=Ua(c),m=Ua(d);t.modifiersData[n]={referenceClippingOffsets:c,popperEscapeOffsets:d,isReferenceHidden:u,hasPopperEscaped:m},t.attributes.popper=Object.assign({},t.attributes.popper,{"data-popper-reference-hidden":u,"data-popper-escaped":m})}const bf={name:"hide",enabled:!0,phase:"main",requiresIfExists:["preventOverflow"],fn:gf};function vf(e,t,n){var r=Xe(e),o=[Re,Ce].indexOf(r)>=0?-1:1,s=typeof n=="function"?n(Object.assign({},t,{placement:e})):n,i=s[0],l=s[1];return i=i||0,l=(l||0)*o,[Re,Le].indexOf(r)>=0?{x:l,y:i}:{x:i,y:l}}function xf(e){var t=e.state,n=e.options,r=e.name,o=n.offset,s=o===void 0?[0,0]:o,i=Ti.reduce(function(u,m){return u[m]=vf(m,t.rects,s),u},{}),l=i[t.placement],c=l.x,d=l.y;t.modifiersData.popperOffsets!=null&&(t.modifiersData.popperOffsets.x+=c,t.modifiersData.popperOffsets.y+=d),t.modifiersData[r]=i}const yf={name:"offset",enabled:!0,phase:"main",requires:["popperOffsets"],fn:xf};function Nf(e){var t=e.state,n=e.name;t.modifiersData[n]=Mi({reference:t.rects.reference,element:t.rects.popper,strategy:"absolute",placement:t.placement})}const kf={name:"popperOffsets",enabled:!0,phase:"read",fn:Nf,data:{}};function Sf(e){return e==="x"?"y":"x"}function Ef(e){var t=e.state,n=e.options,r=e.name,o=n.mainAxis,s=o===void 0?!0:o,i=n.altAxis,l=i===void 0?!1:i,c=n.boundary,d=n.rootBoundary,u=n.altBoundary,m=n.padding,w=n.tether,b=w===void 0?!0:w,x=n.tetherOffset,f=x===void 0?0:x,h=kn(t,{boundary:c,rootBoundary:d,padding:m,altBoundary:u}),S=Xe(t.placement),R=qt(t.placement),j=!R,E=Ao(S),v=Sf(E),P=t.modifiersData.popperOffsets,V=t.rects.reference,U=t.rects.popper,T=typeof f=="function"?f(Object.assign({},t.rects,{placement:t.placement})):f,_=typeof T=="number"?{mainAxis:T,altAxis:T}:Object.assign({mainAxis:0,altAxis:0},T),k=t.modifiersData.offset?t.modifiersData.offset[t.placement]:null,D={x:0,y:0};if(P){if(s){var $,J=E==="y"?Ce:Re,Y=E==="y"?ze:Le,F=E==="y"?"height":"width",te=P[E],se=te+h[J],oe=te-h[Y],y=b?-U[F]/2:0,C=R===Ft?V[F]:U[F],z=R===Ft?-U[F]:-V[F],L=t.elements.arrow,B=b&&L?Do(L):{width:0,height:0},X=t.modifiersData["arrow#persistent"]?t.modifiersData["arrow#persistent"].padding:Oi(),q=X[J],H=X[Y],G=hn(0,V[F],B[F]),K=j?V[F]/2-y-G-q-_.mainAxis:C-G-q-_.mainAxis,Z=j?-V[F]/2+y+G+H+_.mainAxis:z+G+H+_.mainAxis,ue=t.elements.arrow&&$n(t.elements.arrow),I=ue?E==="y"?ue.clientTop||0:ue.clientLeft||0:0,ye=($=k==null?void 0:k[E])!=null?$:0,A=te+K-ye-I,xe=te+Z-ye,Ge=hn(b?Qn(se,A):se,te,b?ht(oe,xe):oe);P[E]=Ge,D[E]=Ge-te}if(l){var lt,Ee=E==="x"?Ce:Re,Dn=E==="x"?ze:Le,Ue=P[v],Et=v==="y"?"height":"width",ct=Ue+h[Ee],jt=Ue-h[Dn],Tt=[Ce,Re].indexOf(S)!==-1,Ct=(lt=k==null?void 0:k[v])!=null?lt:0,dt=Tt?ct:Ue-V[Et]-U[Et]-Ct+_.altAxis,Jt=Tt?Ue+V[Et]+U[Et]-Ct-_.altAxis:jt,An=b&&Tt?Yw(dt,Ue,Jt):hn(b?dt:ct,Ue,b?Jt:jt);P[v]=An,D[v]=An-Ue}t.modifiersData[r]=D}}const jf={name:"preventOverflow",enabled:!0,phase:"main",fn:Ef,requiresIfExists:["offset"]};function Tf(e){return{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}}function Cf(e){return e===$e(e)||!Ve(e)?Bo(e):Tf(e)}function Rf(e){var t=e.getBoundingClientRect(),n=Gt(t.width)/e.offsetWidth||1,r=Gt(t.height)/e.offsetHeight||1;return n!==1||r!==1}function Of(e,t,n){n===void 0&&(n=!1);var r=Ve(t),o=Ve(t)&&Rf(t),s=it(t),i=Ut(e,o,n),l={scrollLeft:0,scrollTop:0},c={x:0,y:0};return(r||!r&&!n)&&((We(t)!=="body"||zo(s))&&(l=Cf(t)),Ve(t)?(c=Ut(t,!0),c.x+=t.clientLeft,c.y+=t.clientTop):s&&(c.x=Vo(s))),{x:i.left+l.scrollLeft-c.x,y:i.top+l.scrollTop-c.y,width:i.width,height:i.height}}function _f(e){var t=new Map,n=new Set,r=[];e.forEach(function(s){t.set(s.name,s)});function o(s){n.add(s.name);var i=[].concat(s.requires||[],s.requiresIfExists||[]);i.forEach(function(l){if(!n.has(l)){var c=t.get(l);c&&o(c)}}),r.push(s)}return e.forEach(function(s){n.has(s.name)||o(s)}),r}function Pf(e){var t=_f(e);return Fw.reduce(function(n,r){return n.concat(t.filter(function(o){return o.phase===r}))},[])}function If(e){var t;return function(){return t||(t=new Promise(function(n){Promise.resolve().then(function(){t=void 0,n(e())})})),t}}function Mf(e){var t=e.reduce(function(n,r){var o=n[r.name];return n[r.name]=o?Object.assign({},o,r,{options:Object.assign({},o.options,r.options),data:Object.assign({},o.data,r.data)}):r,n},{});return Object.keys(t).map(function(n){return t[n]})}var qa={placement:"bottom",modifiers:[],strategy:"absolute"};function Ha(){for(var e=arguments.length,t=new Array(e),n=0;nko({root:["root"]},yw(Bf)),Uf={},qf=M.forwardRef(function(t,n){var r;const{anchorEl:o,children:s,direction:i,disablePortal:l,modifiers:c,open:d,placement:u,popperOptions:m,popperRef:w,slotProps:b={},slots:x={},TransitionProps:f}=t,h=Ne(t,Vf),S=M.useRef(null),R=yt(S,n),j=M.useRef(null),E=yt(j,w),v=M.useRef(E);Lt(()=>{v.current=E},[E]),M.useImperativeHandle(w,()=>j.current,[]);const P=Lf(u,i),[V,U]=M.useState(P),[T,_]=M.useState(er(o));M.useEffect(()=>{j.current&&j.current.forceUpdate()}),M.useEffect(()=>{o&&_(er(o))},[o]),Lt(()=>{if(!T||!d)return;const Y=se=>{U(se.placement)};if(process.env.NODE_ENV!=="production"&&T&&yr(T)&&T.nodeType===1){const se=T.getBoundingClientRect();process.env.NODE_ENV!=="test"&&se.top===0&&se.left===0&&se.right===0&&se.bottom===0&&console.warn(["MUI: The `anchorEl` prop provided to the component is invalid.","The anchor element should be part of the document layout.","Make sure the element is present in the document or that it's not display none."].join(` -`))}let F=[{name:"preventOverflow",options:{altBoundary:l}},{name:"flip",options:{altBoundary:l}},{name:"onUpdate",enabled:!0,phase:"afterWrite",fn:({state:se})=>{Y(se)}}];c!=null&&(F=F.concat(c)),m&&m.modifiers!=null&&(F=F.concat(m.modifiers));const te=Af(T,S.current,O({placement:P},m,{modifiers:F}));return v.current(te),()=>{te.destroy(),v.current(null)}},[T,l,c,d,m,P]);const k={placement:V};f!==null&&(k.TransitionProps=f);const D=Gf(),$=(r=x.root)!=null?r:"div",J=jw({elementType:$,externalSlotProps:b.root,externalForwardedProps:h,additionalProps:{role:"tooltip",ref:R},ownerState:t,className:D.root});return a.jsx($,O({},J,{children:typeof s=="function"?s(k):s}))}),Di=M.forwardRef(function(t,n){const{anchorEl:r,children:o,container:s,direction:i="ltr",disablePortal:l=!1,keepMounted:c=!1,modifiers:d,open:u,placement:m="bottom",popperOptions:w=Uf,popperRef:b,style:x,transition:f=!1,slotProps:h={},slots:S={}}=t,R=Ne(t,zf),[j,E]=M.useState(!0),v=()=>{E(!1)},P=()=>{E(!0)};if(!c&&!u&&(!f||j))return null;let V;if(s)V=s;else if(r){const _=er(r);V=_&&yr(_)?Wn(_).body:Wn(null).body}const U=!u&&c&&(!f||j)?"none":void 0,T=f?{in:u,onEnter:v,onExited:P}:void 0;return a.jsx(Zn,{disablePortal:l,container:V,children:a.jsx(qf,O({anchorEl:r,direction:i,disablePortal:l,modifiers:d,ref:n,open:f?!j:u,placement:m,popperOptions:w,popperRef:b,slotProps:h,slots:S},R,{style:O({position:"fixed",top:0,left:0,display:U},x),TransitionProps:T,children:o}))})});process.env.NODE_ENV!=="production"&&(Di.propTypes={anchorEl:yo(p.oneOfType([xn,p.object,p.func]),e=>{if(e.open){const t=er(e.anchorEl);if(t&&yr(t)&&t.nodeType===1){const n=t.getBoundingClientRect();if(process.env.NODE_ENV!=="test"&&n.top===0&&n.left===0&&n.right===0&&n.bottom===0)return new Error(["MUI: The `anchorEl` prop provided to the component is invalid.","The anchor element should be part of the document layout.","Make sure the element is present in the document or that it's not display none."].join(` +} });`:zt(12,m?` (${m})`:"",JSON.stringify(f.main)));return Ma(f,"light",R,r),Ma(f,"dark",j,r),f.contrastText||(f.contrastText=h(f.main)),f},b={dark:zr,light:Ia};return process.env.NODE_ENV!=="production"&&(b[t]||console.error(`MUI: The palette mode \`${t}\` is not supported.`)),Qe(O({common:O({},yn),mode:t,primary:w({color:s,name:"primary"}),secondary:w({color:i,name:"secondary",mainShade:"A400",lightShade:"A200",darkShade:"A700"}),error:w({color:l,name:"error"}),warning:w({color:u,name:"warning"}),info:w({color:c,name:"info"}),success:w({color:d,name:"success"}),grey:jp,contrastThreshold:n,getContrastText:h,augmentColor:w,tonalOffset:r},b[t]),o)}const Lp=["fontFamily","fontSize","fontWeightLight","fontWeightRegular","fontWeightMedium","fontWeightBold","htmlFontSize","allVariants","pxToRem"];function Fp(e){return Math.round(e*1e5)/1e5}const $a={textTransform:"uppercase"},Da='"Roboto", "Helvetica", "Arial", sans-serif';function Gp(e,t){const n=typeof t=="function"?t(e):t,{fontFamily:r=Da,fontSize:o=14,fontWeightLight:s=300,fontWeightRegular:i=400,fontWeightMedium:l=500,fontWeightBold:c=700,htmlFontSize:d=16,allVariants:u,pxToRem:h}=n,w=Ne(n,Lp);process.env.NODE_ENV!=="production"&&(typeof o!="number"&&console.error("MUI: `fontSize` is required to be a number."),typeof d!="number"&&console.error("MUI: `htmlFontSize` is required to be a number."));const b=o/14,x=h||(S=>`${S/d*b}rem`),f=(S,R,j,E,v)=>O({fontFamily:r,fontWeight:S,fontSize:x(R),lineHeight:j},r===Da?{letterSpacing:`${Fp(E/R)}em`}:{},v,u),m={h1:f(s,96,1.167,-1.5),h2:f(s,60,1.2,-.5),h3:f(i,48,1.167,0),h4:f(i,34,1.235,.25),h5:f(i,24,1.334,0),h6:f(l,20,1.6,.15),subtitle1:f(i,16,1.75,.15),subtitle2:f(l,14,1.57,.1),body1:f(i,16,1.5,.15),body2:f(i,14,1.43,.15),button:f(l,14,1.75,.4,$a),caption:f(i,12,1.66,.4),overline:f(i,12,2.66,1,$a),inherit:{fontFamily:"inherit",fontWeight:"inherit",fontSize:"inherit",lineHeight:"inherit",letterSpacing:"inherit"}};return Qe(O({htmlFontSize:d,pxToRem:x,fontFamily:r,fontSize:o,fontWeightLight:s,fontWeightRegular:i,fontWeightMedium:l,fontWeightBold:c},m),w,{clone:!1})}const Up=.2,qp=.14,Hp=.12;function we(...e){return[`${e[0]}px ${e[1]}px ${e[2]}px ${e[3]}px rgba(0,0,0,${Up})`,`${e[4]}px ${e[5]}px ${e[6]}px ${e[7]}px rgba(0,0,0,${qp})`,`${e[8]}px ${e[9]}px ${e[10]}px ${e[11]}px rgba(0,0,0,${Hp})`].join(",")}const Xp=["none",we(0,2,1,-1,0,1,1,0,0,1,3,0),we(0,3,1,-2,0,2,2,0,0,1,5,0),we(0,3,3,-2,0,3,4,0,0,1,8,0),we(0,2,4,-1,0,4,5,0,0,1,10,0),we(0,3,5,-1,0,5,8,0,0,1,14,0),we(0,3,5,-1,0,6,10,0,0,1,18,0),we(0,4,5,-2,0,7,10,1,0,2,16,1),we(0,5,5,-3,0,8,10,1,0,3,14,2),we(0,5,6,-3,0,9,12,1,0,3,16,2),we(0,6,6,-3,0,10,14,1,0,4,18,3),we(0,6,7,-4,0,11,15,1,0,4,20,3),we(0,7,8,-4,0,12,17,2,0,5,22,4),we(0,7,8,-4,0,13,19,2,0,5,24,4),we(0,7,9,-4,0,14,21,2,0,5,26,4),we(0,8,9,-5,0,15,22,2,0,6,28,5),we(0,8,10,-5,0,16,24,2,0,6,30,5),we(0,8,11,-5,0,17,26,2,0,6,32,5),we(0,9,11,-5,0,18,28,2,0,7,34,6),we(0,9,12,-6,0,19,29,2,0,7,36,6),we(0,10,13,-6,0,20,31,3,0,8,38,7),we(0,10,13,-6,0,21,33,3,0,8,40,7),we(0,10,14,-6,0,22,35,3,0,8,42,7),we(0,11,14,-7,0,23,36,3,0,9,44,8),we(0,11,15,-7,0,24,38,3,0,9,46,8)],Yp=Xp,Wp=["duration","easing","delay"],Kp={easeInOut:"cubic-bezier(0.4, 0, 0.2, 1)",easeOut:"cubic-bezier(0.0, 0, 0.2, 1)",easeIn:"cubic-bezier(0.4, 0, 1, 1)",sharp:"cubic-bezier(0.4, 0, 0.6, 1)"},Jp={shortest:150,shorter:200,short:250,standard:300,complex:375,enteringScreen:225,leavingScreen:195};function Aa(e){return`${Math.round(e)}ms`}function Zp(e){if(!e)return 0;const t=e/36;return Math.round((4+15*t**.25+t/5)*10)}function Qp(e){const t=O({},Kp,e.easing),n=O({},Jp,e.duration);return O({getAutoHeightDuration:Zp,create:(o=["all"],s={})=>{const{duration:i=n.standard,easing:l=t.easeInOut,delay:c=0}=s,d=Ne(s,Wp);if(process.env.NODE_ENV!=="production"){const u=w=>typeof w=="string",h=w=>!isNaN(parseFloat(w));!u(o)&&!Array.isArray(o)&&console.error('MUI: Argument "props" must be a string or Array.'),!h(i)&&!u(i)&&console.error(`MUI: Argument "duration" must be a number or a string but found ${i}.`),u(l)||console.error('MUI: Argument "easing" must be a string.'),!h(c)&&!u(c)&&console.error('MUI: Argument "delay" must be a number or a string.'),typeof s!="object"&&console.error(["MUI: Secong argument of transition.create must be an object.","Arguments should be either `create('prop1', options)` or `create(['prop1', 'prop2'], options)`"].join(` +`)),Object.keys(d).length!==0&&console.error(`MUI: Unrecognized argument(s) [${Object.keys(d).join(",")}].`)}return(Array.isArray(o)?o:[o]).map(u=>`${u} ${typeof i=="string"?i:Aa(i)} ${l} ${typeof c=="string"?c:Aa(c)}`).join(",")}},e,{easing:t,duration:n})}const ew={mobileStepper:1e3,fab:1050,speedDial:1050,appBar:1100,drawer:1200,modal:1300,snackbar:1400,tooltip:1500},tw=ew,nw=["breakpoints","mixins","spacing","palette","transitions","typography","shape"];function rw(e={},...t){const{mixins:n={},palette:r={},transitions:o={},typography:s={}}=e,i=Ne(e,nw);if(e.vars)throw new Error(process.env.NODE_ENV!=="production"?"MUI: `vars` is a private field used for CSS variables support.\nPlease use another name.":zt(18));const l=zp(r),c=_o(e);let d=Qe(c,{mixins:kp(c.breakpoints,n),palette:l,shadows:Yp.slice(),typography:Gp(l,s),transitions:Qp(o),zIndex:O({},tw)});if(d=Qe(d,i),d=t.reduce((u,h)=>Qe(u,h),d),process.env.NODE_ENV!=="production"){const u=["active","checked","completed","disabled","error","expanded","focused","focusVisible","required","selected"],h=(w,b)=>{let x;for(x in w){const f=w[x];if(u.indexOf(x)!==-1&&Object.keys(f).length>0){if(process.env.NODE_ENV!=="production"){const m=ur("",x);console.error([`MUI: The \`${b}\` component increases the CSS specificity of the \`${x}\` internal state.`,"You can not override it like this: ",JSON.stringify(w,null,2),"",`Instead, you need to use the '&.${m}' syntax:`,JSON.stringify({root:{[`&.${m}`]:f}},null,2),"","https://mui.com/r/state-classes-guide"].join(` +`))}w[x]={}}}};Object.keys(d.components).forEach(w=>{const b=d.components[w].styleOverrides;b&&w.indexOf("Mui")===0&&h(b,w)})}return d.unstable_sxConfig=O({},Ro,i==null?void 0:i.unstable_sxConfig),d.unstable_sx=function(h){return Oo({sx:h,theme:this})},d}const ow=rw(),Io=ow,Mo="$$material";function $o({props:e,name:t}){return bp({props:e,name:t,defaultTheme:Io,themeId:Mo})}const aw=e=>qn(e)&&e!=="classes",sw=hp({themeId:Mo,defaultTheme:Io,rootShouldForwardProp:aw}),In=sw;function iw(e){return ur("MuiSvgIcon",e)}mi("MuiSvgIcon",["root","colorPrimary","colorSecondary","colorAction","colorError","colorDisabled","fontSizeInherit","fontSizeSmall","fontSizeMedium","fontSizeLarge"]);const lw=["children","className","color","component","fontSize","htmlColor","inheritViewBox","titleAccess","viewBox"],cw=e=>{const{color:t,fontSize:n,classes:r}=e,o={root:["root",t!=="inherit"&&`color${Ye(t)}`,`fontSize${Ye(n)}`]};return jo(o,iw,r)},dw=In("svg",{name:"MuiSvgIcon",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.root,n.color!=="inherit"&&t[`color${Ye(n.color)}`],t[`fontSize${Ye(n.fontSize)}`]]}})(({theme:e,ownerState:t})=>{var n,r,o,s,i,l,c,d,u,h,w,b,x;return{userSelect:"none",width:"1em",height:"1em",display:"inline-block",fill:t.hasSvgAsChild?void 0:"currentColor",flexShrink:0,transition:(n=e.transitions)==null||(r=n.create)==null?void 0:r.call(n,"fill",{duration:(o=e.transitions)==null||(o=o.duration)==null?void 0:o.shorter}),fontSize:{inherit:"inherit",small:((s=e.typography)==null||(i=s.pxToRem)==null?void 0:i.call(s,20))||"1.25rem",medium:((l=e.typography)==null||(c=l.pxToRem)==null?void 0:c.call(l,24))||"1.5rem",large:((d=e.typography)==null||(u=d.pxToRem)==null?void 0:u.call(d,35))||"2.1875rem"}[t.fontSize],color:(h=(w=(e.vars||e).palette)==null||(w=w[t.color])==null?void 0:w.main)!=null?h:{action:(b=(e.vars||e).palette)==null||(b=b.action)==null?void 0:b.active,disabled:(x=(e.vars||e).palette)==null||(x=x.action)==null?void 0:x.disabled,inherit:void 0}[t.color]}}),Do=M.forwardRef(function(t,n){const r=$o({props:t,name:"MuiSvgIcon"}),{children:o,className:s,color:i="inherit",component:l="svg",fontSize:c="medium",htmlColor:d,inheritViewBox:u=!1,titleAccess:h,viewBox:w="0 0 24 24"}=r,b=Ne(r,lw),x=M.isValidElement(o)&&o.type==="svg",f=O({},r,{color:i,component:l,fontSize:c,instanceFontSize:t.fontSize,inheritViewBox:u,viewBox:w,hasSvgAsChild:x}),m={};u||(m.viewBox=w);const S=cw(f);return a.jsxs(dw,O({as:l,className:ot(S.root,s),focusable:"false",color:d,"aria-hidden":h?void 0:!0,role:h?"img":void 0,ref:n},m,b,x&&o.props,{ownerState:f,children:[x?o.props.children:o,h?a.jsx("title",{children:h}):null]}))});process.env.NODE_ENV!=="production"&&(Do.propTypes={children:p.node,classes:p.object,className:p.string,color:p.oneOfType([p.oneOf(["inherit","action","disabled","primary","secondary","error","info","success","warning"]),p.string]),component:p.elementType,fontSize:p.oneOfType([p.oneOf(["inherit","large","medium","small"]),p.string]),htmlColor:p.string,inheritViewBox:p.bool,shapeRendering:p.string,sx:p.oneOfType([p.arrayOf(p.oneOfType([p.func,p.object,p.bool])),p.func,p.object]),titleAccess:p.string,viewBox:p.string});Do.muiName="SvgIcon";const Ba=Do;function Ni(e,t){function n(r,o){return a.jsx(Ba,O({"data-testid":`${t}Icon`,ref:o},r,{children:e}))}return process.env.NODE_ENV!=="production"&&(n.displayName=`${t}Icon`),n.muiName=Ba.muiName,M.memo(M.forwardRef(n))}const uw={configure:e=>{process.env.NODE_ENV!=="production"&&console.warn(["MUI: `ClassNameGenerator` import from `@mui/material/utils` is outdated and might cause unexpected issues.","","You should use `import { unstable_ClassNameGenerator } from '@mui/material/className'` instead","","The detail of the issue: https://github.com/mui/material-ui/issues/30011#issuecomment-1024993401","","The updated documentation: https://mui.com/guides/classname-generator/"].join(` +`)),wi.configure(e)}},pw=Object.freeze(Object.defineProperty({__proto__:null,capitalize:Ye,createChainedFunction:Ld,createSvgIcon:Ni,debounce:Fd,deprecatedPropType:Gd,isMuiElement:Ud,ownerDocument:Kn,ownerWindow:qd,requirePropFactory:Hd,setRef:Jn,unstable_ClassNameGenerator:uw,unstable_useEnhancedEffect:Lt,unstable_useId:ci,unsupportedProp:Wd,useControlled:di,useEventCallback:Zr,useForkRef:yt,useIsFocusVisible:ui},Symbol.toStringTag,{value:"Module"})),ww=yd(pw);var Va;function fw(){return Va||(Va=1,function(e){"use client";Object.defineProperty(e,"__esModule",{value:!0}),Object.defineProperty(e,"default",{enumerable:!0,get:function(){return t.createSvgIcon}});var t=ww}(Pr)),Pr}var mw=Nd;Object.defineProperty(ko,"__esModule",{value:!0});var ki=ko.default=void 0,hw=mw(fw()),gw=a;ki=ko.default=(0,hw.default)((0,gw.jsx)("path",{d:"m10 17 5-5-5-5z"}),"ArrowRight");function bw(e){return typeof e=="string"}function un(e,t,n){return e===void 0||bw(e)?t:O({},t,{ownerState:O({},t.ownerState,n)})}const vw={disableDefaultClasses:!1},xw=M.createContext(vw);function yw(e){const{disableDefaultClasses:t}=M.useContext(xw);return n=>t?"":e(n)}function Nw(e,t=[]){if(e===void 0)return{};const n={};return Object.keys(e).filter(r=>r.match(/^on[A-Z]/)&&typeof e[r]=="function"&&!t.includes(r)).forEach(r=>{n[r]=e[r]}),n}function kw(e,t,n){return typeof e=="function"?e(t,n):e}function za(e){if(e===void 0)return{};const t={};return Object.keys(e).filter(n=>!(n.match(/^on[A-Z]/)&&typeof e[n]=="function")).forEach(n=>{t[n]=e[n]}),t}function Sw(e){const{getSlotProps:t,additionalProps:n,externalSlotProps:r,externalForwardedProps:o,className:s}=e;if(!t){const b=ot(n==null?void 0:n.className,s,o==null?void 0:o.className,r==null?void 0:r.className),x=O({},n==null?void 0:n.style,o==null?void 0:o.style,r==null?void 0:r.style),f=O({},n,o,r);return b.length>0&&(f.className=b),Object.keys(x).length>0&&(f.style=x),{props:f,internalRef:void 0}}const i=Nw(O({},o,r)),l=za(r),c=za(o),d=t(i),u=ot(d==null?void 0:d.className,n==null?void 0:n.className,s,o==null?void 0:o.className,r==null?void 0:r.className),h=O({},d==null?void 0:d.style,n==null?void 0:n.style,o==null?void 0:o.style,r==null?void 0:r.style),w=O({},d,n,c,l);return u.length>0&&(w.className=u),Object.keys(h).length>0&&(w.style=h),{props:w,internalRef:d.ref}}const Ew=["elementType","externalSlotProps","ownerState","skipResolvingSlotProps"];function jw(e){var t;const{elementType:n,externalSlotProps:r,ownerState:o,skipResolvingSlotProps:s=!1}=e,i=Ne(e,Ew),l=s?{}:kw(r,o),{props:c,internalRef:d}=Sw(O({},i,{externalSlotProps:l})),u=yt(d,l==null?void 0:l.ref,(t=e.additionalProps)==null?void 0:t.ref);return un(n,O({},c,{ref:u}),o)}const Si="base";function Cw(e){return`${Si}--${e}`}function Tw(e,t){return`${Si}-${e}-${t}`}function Ei(e,t){const n=fi[t];return n?Cw(n):Tw(e,t)}function Rw(e,t){const n={};return t.forEach(r=>{n[r]=Ei(e,r)}),n}function Ow(e){return typeof e=="function"?e():e}const Qn=M.forwardRef(function(t,n){const{children:r,container:o,disablePortal:s=!1}=t,[i,l]=M.useState(null),c=yt(M.isValidElement(r)?r.ref:null,n);if(Lt(()=>{s||l(Ow(o)||document.body)},[o,s]),Lt(()=>{if(i&&!s)return Jn(n,i),()=>{Jn(n,null)}},[n,i,s]),s){if(M.isValidElement(r)){const d={ref:c};return M.cloneElement(r,d)}return a.jsx(M.Fragment,{children:r})}return a.jsx(M.Fragment,{children:i&&Ol.createPortal(r,i)})});process.env.NODE_ENV!=="production"&&(Qn.propTypes={children:p.node,container:p.oneOfType([xn,p.func]),disablePortal:p.bool});process.env.NODE_ENV!=="production"&&(Qn["propTypes"]=Md(Qn.propTypes));var Te="top",ze="bottom",Le="right",Re="left",Ao="auto",Mn=[Te,ze,Le,Re],Ft="start",Nn="end",_w="clippingParents",ji="viewport",an="popper",Pw="reference",La=Mn.reduce(function(e,t){return e.concat([t+"-"+Ft,t+"-"+Nn])},[]),Ci=[].concat(Mn,[Ao]).reduce(function(e,t){return e.concat([t,t+"-"+Ft,t+"-"+Nn])},[]),Iw="beforeRead",Mw="read",$w="afterRead",Dw="beforeMain",Aw="main",Bw="afterMain",Vw="beforeWrite",zw="write",Lw="afterWrite",Fw=[Iw,Mw,$w,Dw,Aw,Bw,Vw,zw,Lw];function We(e){return e?(e.nodeName||"").toLowerCase():null}function $e(e){if(e==null)return window;if(e.toString()!=="[object Window]"){var t=e.ownerDocument;return t&&t.defaultView||window}return e}function kt(e){var t=$e(e).Element;return e instanceof t||e instanceof Element}function Ve(e){var t=$e(e).HTMLElement;return e instanceof t||e instanceof HTMLElement}function Bo(e){if(typeof ShadowRoot>"u")return!1;var t=$e(e).ShadowRoot;return e instanceof t||e instanceof ShadowRoot}function Gw(e){var t=e.state;Object.keys(t.elements).forEach(function(n){var r=t.styles[n]||{},o=t.attributes[n]||{},s=t.elements[n];!Ve(s)||!We(s)||(Object.assign(s.style,r),Object.keys(o).forEach(function(i){var l=o[i];l===!1?s.removeAttribute(i):s.setAttribute(i,l===!0?"":l)}))})}function Uw(e){var t=e.state,n={popper:{position:t.options.strategy,left:"0",top:"0",margin:"0"},arrow:{position:"absolute"},reference:{}};return Object.assign(t.elements.popper.style,n.popper),t.styles=n,t.elements.arrow&&Object.assign(t.elements.arrow.style,n.arrow),function(){Object.keys(t.elements).forEach(function(r){var o=t.elements[r],s=t.attributes[r]||{},i=Object.keys(t.styles.hasOwnProperty(r)?t.styles[r]:n[r]),l=i.reduce(function(c,d){return c[d]="",c},{});!Ve(o)||!We(o)||(Object.assign(o.style,l),Object.keys(s).forEach(function(c){o.removeAttribute(c)}))})}}const qw={name:"applyStyles",enabled:!0,phase:"write",fn:Gw,effect:Uw,requires:["computeStyles"]};function Xe(e){return e.split("-")[0]}var ht=Math.max,er=Math.min,Gt=Math.round;function eo(){var e=navigator.userAgentData;return e!=null&&e.brands&&Array.isArray(e.brands)?e.brands.map(function(t){return t.brand+"/"+t.version}).join(" "):navigator.userAgent}function Ti(){return!/^((?!chrome|android).)*safari/i.test(eo())}function Ut(e,t,n){t===void 0&&(t=!1),n===void 0&&(n=!1);var r=e.getBoundingClientRect(),o=1,s=1;t&&Ve(e)&&(o=e.offsetWidth>0&&Gt(r.width)/e.offsetWidth||1,s=e.offsetHeight>0&&Gt(r.height)/e.offsetHeight||1);var i=kt(e)?$e(e):window,l=i.visualViewport,c=!Ti()&&n,d=(r.left+(c&&l?l.offsetLeft:0))/o,u=(r.top+(c&&l?l.offsetTop:0))/s,h=r.width/o,w=r.height/s;return{width:h,height:w,top:u,right:d+h,bottom:u+w,left:d,x:d,y:u}}function Vo(e){var t=Ut(e),n=e.offsetWidth,r=e.offsetHeight;return Math.abs(t.width-n)<=1&&(n=t.width),Math.abs(t.height-r)<=1&&(r=t.height),{x:e.offsetLeft,y:e.offsetTop,width:n,height:r}}function Ri(e,t){var n=t.getRootNode&&t.getRootNode();if(e.contains(t))return!0;if(n&&Bo(n)){var r=t;do{if(r&&e.isSameNode(r))return!0;r=r.parentNode||r.host}while(r)}return!1}function tt(e){return $e(e).getComputedStyle(e)}function Hw(e){return["table","td","th"].indexOf(We(e))>=0}function it(e){return((kt(e)?e.ownerDocument:e.document)||window.document).documentElement}function yr(e){return We(e)==="html"?e:e.assignedSlot||e.parentNode||(Bo(e)?e.host:null)||it(e)}function Fa(e){return!Ve(e)||tt(e).position==="fixed"?null:e.offsetParent}function Xw(e){var t=/firefox/i.test(eo()),n=/Trident/i.test(eo());if(n&&Ve(e)){var r=tt(e);if(r.position==="fixed")return null}var o=yr(e);for(Bo(o)&&(o=o.host);Ve(o)&&["html","body"].indexOf(We(o))<0;){var s=tt(o);if(s.transform!=="none"||s.perspective!=="none"||s.contain==="paint"||["transform","perspective"].indexOf(s.willChange)!==-1||t&&s.willChange==="filter"||t&&s.filter&&s.filter!=="none")return o;o=o.parentNode}return null}function $n(e){for(var t=$e(e),n=Fa(e);n&&Hw(n)&&tt(n).position==="static";)n=Fa(n);return n&&(We(n)==="html"||We(n)==="body"&&tt(n).position==="static")?t:n||Xw(e)||t}function zo(e){return["top","bottom"].indexOf(e)>=0?"x":"y"}function hn(e,t,n){return ht(e,er(t,n))}function Yw(e,t,n){var r=hn(e,t,n);return r>n?n:r}function Oi(){return{top:0,right:0,bottom:0,left:0}}function _i(e){return Object.assign({},Oi(),e)}function Pi(e,t){return t.reduce(function(n,r){return n[r]=e,n},{})}var Ww=function(t,n){return t=typeof t=="function"?t(Object.assign({},n.rects,{placement:n.placement})):t,_i(typeof t!="number"?t:Pi(t,Mn))};function Kw(e){var t,n=e.state,r=e.name,o=e.options,s=n.elements.arrow,i=n.modifiersData.popperOffsets,l=Xe(n.placement),c=zo(l),d=[Re,Le].indexOf(l)>=0,u=d?"height":"width";if(!(!s||!i)){var h=Ww(o.padding,n),w=Vo(s),b=c==="y"?Te:Re,x=c==="y"?ze:Le,f=n.rects.reference[u]+n.rects.reference[c]-i[c]-n.rects.popper[u],m=i[c]-n.rects.reference[c],S=$n(s),R=S?c==="y"?S.clientHeight||0:S.clientWidth||0:0,j=f/2-m/2,E=h[b],v=R-w[u]-h[x],P=R/2-w[u]/2+j,V=hn(E,P,v),U=c;n.modifiersData[r]=(t={},t[U]=V,t.centerOffset=V-P,t)}}function Jw(e){var t=e.state,n=e.options,r=n.element,o=r===void 0?"[data-popper-arrow]":r;o!=null&&(typeof o=="string"&&(o=t.elements.popper.querySelector(o),!o)||Ri(t.elements.popper,o)&&(t.elements.arrow=o))}const Zw={name:"arrow",enabled:!0,phase:"main",fn:Kw,effect:Jw,requires:["popperOffsets"],requiresIfExists:["preventOverflow"]};function qt(e){return e.split("-")[1]}var Qw={top:"auto",right:"auto",bottom:"auto",left:"auto"};function ef(e,t){var n=e.x,r=e.y,o=t.devicePixelRatio||1;return{x:Gt(n*o)/o||0,y:Gt(r*o)/o||0}}function Ga(e){var t,n=e.popper,r=e.popperRect,o=e.placement,s=e.variation,i=e.offsets,l=e.position,c=e.gpuAcceleration,d=e.adaptive,u=e.roundOffsets,h=e.isFixed,w=i.x,b=w===void 0?0:w,x=i.y,f=x===void 0?0:x,m=typeof u=="function"?u({x:b,y:f}):{x:b,y:f};b=m.x,f=m.y;var S=i.hasOwnProperty("x"),R=i.hasOwnProperty("y"),j=Re,E=Te,v=window;if(d){var P=$n(n),V="clientHeight",U="clientWidth";if(P===$e(n)&&(P=it(n),tt(P).position!=="static"&&l==="absolute"&&(V="scrollHeight",U="scrollWidth")),P=P,o===Te||(o===Re||o===Le)&&s===Nn){E=ze;var C=h&&P===v&&v.visualViewport?v.visualViewport.height:P[V];f-=C-r.height,f*=c?1:-1}if(o===Re||(o===Te||o===ze)&&s===Nn){j=Le;var _=h&&P===v&&v.visualViewport?v.visualViewport.width:P[U];b-=_-r.width,b*=c?1:-1}}var k=Object.assign({position:l},d&&Qw),D=u===!0?ef({x:b,y:f},$e(n)):{x:b,y:f};if(b=D.x,f=D.y,c){var $;return Object.assign({},k,($={},$[E]=R?"0":"",$[j]=S?"0":"",$.transform=(v.devicePixelRatio||1)<=1?"translate("+b+"px, "+f+"px)":"translate3d("+b+"px, "+f+"px, 0)",$))}return Object.assign({},k,(t={},t[E]=R?f+"px":"",t[j]=S?b+"px":"",t.transform="",t))}function tf(e){var t=e.state,n=e.options,r=n.gpuAcceleration,o=r===void 0?!0:r,s=n.adaptive,i=s===void 0?!0:s,l=n.roundOffsets,c=l===void 0?!0:l,d={placement:Xe(t.placement),variation:qt(t.placement),popper:t.elements.popper,popperRect:t.rects.popper,gpuAcceleration:o,isFixed:t.options.strategy==="fixed"};t.modifiersData.popperOffsets!=null&&(t.styles.popper=Object.assign({},t.styles.popper,Ga(Object.assign({},d,{offsets:t.modifiersData.popperOffsets,position:t.options.strategy,adaptive:i,roundOffsets:c})))),t.modifiersData.arrow!=null&&(t.styles.arrow=Object.assign({},t.styles.arrow,Ga(Object.assign({},d,{offsets:t.modifiersData.arrow,position:"absolute",adaptive:!1,roundOffsets:c})))),t.attributes.popper=Object.assign({},t.attributes.popper,{"data-popper-placement":t.placement})}const nf={name:"computeStyles",enabled:!0,phase:"beforeWrite",fn:tf,data:{}};var Fn={passive:!0};function rf(e){var t=e.state,n=e.instance,r=e.options,o=r.scroll,s=o===void 0?!0:o,i=r.resize,l=i===void 0?!0:i,c=$e(t.elements.popper),d=[].concat(t.scrollParents.reference,t.scrollParents.popper);return s&&d.forEach(function(u){u.addEventListener("scroll",n.update,Fn)}),l&&c.addEventListener("resize",n.update,Fn),function(){s&&d.forEach(function(u){u.removeEventListener("scroll",n.update,Fn)}),l&&c.removeEventListener("resize",n.update,Fn)}}const of={name:"eventListeners",enabled:!0,phase:"write",fn:function(){},effect:rf,data:{}};var af={left:"right",right:"left",bottom:"top",top:"bottom"};function Xn(e){return e.replace(/left|right|bottom|top/g,function(t){return af[t]})}var sf={start:"end",end:"start"};function Ua(e){return e.replace(/start|end/g,function(t){return sf[t]})}function Lo(e){var t=$e(e),n=t.pageXOffset,r=t.pageYOffset;return{scrollLeft:n,scrollTop:r}}function Fo(e){return Ut(it(e)).left+Lo(e).scrollLeft}function lf(e,t){var n=$e(e),r=it(e),o=n.visualViewport,s=r.clientWidth,i=r.clientHeight,l=0,c=0;if(o){s=o.width,i=o.height;var d=Ti();(d||!d&&t==="fixed")&&(l=o.offsetLeft,c=o.offsetTop)}return{width:s,height:i,x:l+Fo(e),y:c}}function cf(e){var t,n=it(e),r=Lo(e),o=(t=e.ownerDocument)==null?void 0:t.body,s=ht(n.scrollWidth,n.clientWidth,o?o.scrollWidth:0,o?o.clientWidth:0),i=ht(n.scrollHeight,n.clientHeight,o?o.scrollHeight:0,o?o.clientHeight:0),l=-r.scrollLeft+Fo(e),c=-r.scrollTop;return tt(o||n).direction==="rtl"&&(l+=ht(n.clientWidth,o?o.clientWidth:0)-s),{width:s,height:i,x:l,y:c}}function Go(e){var t=tt(e),n=t.overflow,r=t.overflowX,o=t.overflowY;return/auto|scroll|overlay|hidden/.test(n+o+r)}function Ii(e){return["html","body","#document"].indexOf(We(e))>=0?e.ownerDocument.body:Ve(e)&&Go(e)?e:Ii(yr(e))}function gn(e,t){var n;t===void 0&&(t=[]);var r=Ii(e),o=r===((n=e.ownerDocument)==null?void 0:n.body),s=$e(r),i=o?[s].concat(s.visualViewport||[],Go(r)?r:[]):r,l=t.concat(i);return o?l:l.concat(gn(yr(i)))}function to(e){return Object.assign({},e,{left:e.x,top:e.y,right:e.x+e.width,bottom:e.y+e.height})}function df(e,t){var n=Ut(e,!1,t==="fixed");return n.top=n.top+e.clientTop,n.left=n.left+e.clientLeft,n.bottom=n.top+e.clientHeight,n.right=n.left+e.clientWidth,n.width=e.clientWidth,n.height=e.clientHeight,n.x=n.left,n.y=n.top,n}function qa(e,t,n){return t===ji?to(lf(e,n)):kt(t)?df(t,n):to(cf(it(e)))}function uf(e){var t=gn(yr(e)),n=["absolute","fixed"].indexOf(tt(e).position)>=0,r=n&&Ve(e)?$n(e):e;return kt(r)?t.filter(function(o){return kt(o)&&Ri(o,r)&&We(o)!=="body"}):[]}function pf(e,t,n,r){var o=t==="clippingParents"?uf(e):[].concat(t),s=[].concat(o,[n]),i=s[0],l=s.reduce(function(c,d){var u=qa(e,d,r);return c.top=ht(u.top,c.top),c.right=er(u.right,c.right),c.bottom=er(u.bottom,c.bottom),c.left=ht(u.left,c.left),c},qa(e,i,r));return l.width=l.right-l.left,l.height=l.bottom-l.top,l.x=l.left,l.y=l.top,l}function Mi(e){var t=e.reference,n=e.element,r=e.placement,o=r?Xe(r):null,s=r?qt(r):null,i=t.x+t.width/2-n.width/2,l=t.y+t.height/2-n.height/2,c;switch(o){case Te:c={x:i,y:t.y-n.height};break;case ze:c={x:i,y:t.y+t.height};break;case Le:c={x:t.x+t.width,y:l};break;case Re:c={x:t.x-n.width,y:l};break;default:c={x:t.x,y:t.y}}var d=o?zo(o):null;if(d!=null){var u=d==="y"?"height":"width";switch(s){case Ft:c[d]=c[d]-(t[u]/2-n[u]/2);break;case Nn:c[d]=c[d]+(t[u]/2-n[u]/2);break}}return c}function kn(e,t){t===void 0&&(t={});var n=t,r=n.placement,o=r===void 0?e.placement:r,s=n.strategy,i=s===void 0?e.strategy:s,l=n.boundary,c=l===void 0?_w:l,d=n.rootBoundary,u=d===void 0?ji:d,h=n.elementContext,w=h===void 0?an:h,b=n.altBoundary,x=b===void 0?!1:b,f=n.padding,m=f===void 0?0:f,S=_i(typeof m!="number"?m:Pi(m,Mn)),R=w===an?Pw:an,j=e.rects.popper,E=e.elements[x?R:w],v=pf(kt(E)?E:E.contextElement||it(e.elements.popper),c,u,i),P=Ut(e.elements.reference),V=Mi({reference:P,element:j,strategy:"absolute",placement:o}),U=to(Object.assign({},j,V)),C=w===an?U:P,_={top:v.top-C.top+S.top,bottom:C.bottom-v.bottom+S.bottom,left:v.left-C.left+S.left,right:C.right-v.right+S.right},k=e.modifiersData.offset;if(w===an&&k){var D=k[o];Object.keys(_).forEach(function($){var J=[Le,ze].indexOf($)>=0?1:-1,Y=[Te,ze].indexOf($)>=0?"y":"x";_[$]+=D[Y]*J})}return _}function wf(e,t){t===void 0&&(t={});var n=t,r=n.placement,o=n.boundary,s=n.rootBoundary,i=n.padding,l=n.flipVariations,c=n.allowedAutoPlacements,d=c===void 0?Ci:c,u=qt(r),h=u?l?La:La.filter(function(x){return qt(x)===u}):Mn,w=h.filter(function(x){return d.indexOf(x)>=0});w.length===0&&(w=h);var b=w.reduce(function(x,f){return x[f]=kn(e,{placement:f,boundary:o,rootBoundary:s,padding:i})[Xe(f)],x},{});return Object.keys(b).sort(function(x,f){return b[x]-b[f]})}function ff(e){if(Xe(e)===Ao)return[];var t=Xn(e);return[Ua(e),t,Ua(t)]}function mf(e){var t=e.state,n=e.options,r=e.name;if(!t.modifiersData[r]._skip){for(var o=n.mainAxis,s=o===void 0?!0:o,i=n.altAxis,l=i===void 0?!0:i,c=n.fallbackPlacements,d=n.padding,u=n.boundary,h=n.rootBoundary,w=n.altBoundary,b=n.flipVariations,x=b===void 0?!0:b,f=n.allowedAutoPlacements,m=t.options.placement,S=Xe(m),R=S===m,j=c||(R||!x?[Xn(m)]:ff(m)),E=[m].concat(j).reduce(function(B,X){return B.concat(Xe(X)===Ao?wf(t,{placement:X,boundary:u,rootBoundary:h,padding:d,flipVariations:x,allowedAutoPlacements:f}):X)},[]),v=t.rects.reference,P=t.rects.popper,V=new Map,U=!0,C=E[0],_=0;_=0,Y=J?"width":"height",F=kn(t,{placement:k,boundary:u,rootBoundary:h,altBoundary:w,padding:d}),te=J?$?Le:Re:$?ze:Te;v[Y]>P[Y]&&(te=Xn(te));var se=Xn(te),oe=[];if(s&&oe.push(F[D]<=0),l&&oe.push(F[te]<=0,F[se]<=0),oe.every(function(B){return B})){C=k,U=!1;break}V.set(k,oe)}if(U)for(var y=x?3:1,T=function(X){var q=E.find(function(H){var G=V.get(H);if(G)return G.slice(0,X).every(function(K){return K})});if(q)return C=q,"break"},z=y;z>0;z--){var L=T(z);if(L==="break")break}t.placement!==C&&(t.modifiersData[r]._skip=!0,t.placement=C,t.reset=!0)}}const hf={name:"flip",enabled:!0,phase:"main",fn:mf,requiresIfExists:["offset"],data:{_skip:!1}};function Ha(e,t,n){return n===void 0&&(n={x:0,y:0}),{top:e.top-t.height-n.y,right:e.right-t.width+n.x,bottom:e.bottom-t.height+n.y,left:e.left-t.width-n.x}}function Xa(e){return[Te,Le,ze,Re].some(function(t){return e[t]>=0})}function gf(e){var t=e.state,n=e.name,r=t.rects.reference,o=t.rects.popper,s=t.modifiersData.preventOverflow,i=kn(t,{elementContext:"reference"}),l=kn(t,{altBoundary:!0}),c=Ha(i,r),d=Ha(l,o,s),u=Xa(c),h=Xa(d);t.modifiersData[n]={referenceClippingOffsets:c,popperEscapeOffsets:d,isReferenceHidden:u,hasPopperEscaped:h},t.attributes.popper=Object.assign({},t.attributes.popper,{"data-popper-reference-hidden":u,"data-popper-escaped":h})}const bf={name:"hide",enabled:!0,phase:"main",requiresIfExists:["preventOverflow"],fn:gf};function vf(e,t,n){var r=Xe(e),o=[Re,Te].indexOf(r)>=0?-1:1,s=typeof n=="function"?n(Object.assign({},t,{placement:e})):n,i=s[0],l=s[1];return i=i||0,l=(l||0)*o,[Re,Le].indexOf(r)>=0?{x:l,y:i}:{x:i,y:l}}function xf(e){var t=e.state,n=e.options,r=e.name,o=n.offset,s=o===void 0?[0,0]:o,i=Ci.reduce(function(u,h){return u[h]=vf(h,t.rects,s),u},{}),l=i[t.placement],c=l.x,d=l.y;t.modifiersData.popperOffsets!=null&&(t.modifiersData.popperOffsets.x+=c,t.modifiersData.popperOffsets.y+=d),t.modifiersData[r]=i}const yf={name:"offset",enabled:!0,phase:"main",requires:["popperOffsets"],fn:xf};function Nf(e){var t=e.state,n=e.name;t.modifiersData[n]=Mi({reference:t.rects.reference,element:t.rects.popper,strategy:"absolute",placement:t.placement})}const kf={name:"popperOffsets",enabled:!0,phase:"read",fn:Nf,data:{}};function Sf(e){return e==="x"?"y":"x"}function Ef(e){var t=e.state,n=e.options,r=e.name,o=n.mainAxis,s=o===void 0?!0:o,i=n.altAxis,l=i===void 0?!1:i,c=n.boundary,d=n.rootBoundary,u=n.altBoundary,h=n.padding,w=n.tether,b=w===void 0?!0:w,x=n.tetherOffset,f=x===void 0?0:x,m=kn(t,{boundary:c,rootBoundary:d,padding:h,altBoundary:u}),S=Xe(t.placement),R=qt(t.placement),j=!R,E=zo(S),v=Sf(E),P=t.modifiersData.popperOffsets,V=t.rects.reference,U=t.rects.popper,C=typeof f=="function"?f(Object.assign({},t.rects,{placement:t.placement})):f,_=typeof C=="number"?{mainAxis:C,altAxis:C}:Object.assign({mainAxis:0,altAxis:0},C),k=t.modifiersData.offset?t.modifiersData.offset[t.placement]:null,D={x:0,y:0};if(P){if(s){var $,J=E==="y"?Te:Re,Y=E==="y"?ze:Le,F=E==="y"?"height":"width",te=P[E],se=te+m[J],oe=te-m[Y],y=b?-U[F]/2:0,T=R===Ft?V[F]:U[F],z=R===Ft?-U[F]:-V[F],L=t.elements.arrow,B=b&&L?Vo(L):{width:0,height:0},X=t.modifiersData["arrow#persistent"]?t.modifiersData["arrow#persistent"].padding:Oi(),q=X[J],H=X[Y],G=hn(0,V[F],B[F]),K=j?V[F]/2-y-G-q-_.mainAxis:T-G-q-_.mainAxis,Z=j?-V[F]/2+y+G+H+_.mainAxis:z+G+H+_.mainAxis,ue=t.elements.arrow&&$n(t.elements.arrow),I=ue?E==="y"?ue.clientTop||0:ue.clientLeft||0:0,ye=($=k==null?void 0:k[E])!=null?$:0,A=te+K-ye-I,xe=te+Z-ye,Ge=hn(b?er(se,A):se,te,b?ht(oe,xe):oe);P[E]=Ge,D[E]=Ge-te}if(l){var lt,Ee=E==="x"?Te:Re,Dn=E==="x"?ze:Le,Ue=P[v],Et=v==="y"?"height":"width",ct=Ue+m[Ee],jt=Ue-m[Dn],Ct=[Te,Re].indexOf(S)!==-1,Tt=(lt=k==null?void 0:k[v])!=null?lt:0,dt=Ct?ct:Ue-V[Et]-U[Et]-Tt+_.altAxis,Jt=Ct?Ue+V[Et]+U[Et]-Tt-_.altAxis:jt,An=b&&Ct?Yw(dt,Ue,Jt):hn(b?dt:ct,Ue,b?Jt:jt);P[v]=An,D[v]=An-Ue}t.modifiersData[r]=D}}const jf={name:"preventOverflow",enabled:!0,phase:"main",fn:Ef,requiresIfExists:["offset"]};function Cf(e){return{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}}function Tf(e){return e===$e(e)||!Ve(e)?Lo(e):Cf(e)}function Rf(e){var t=e.getBoundingClientRect(),n=Gt(t.width)/e.offsetWidth||1,r=Gt(t.height)/e.offsetHeight||1;return n!==1||r!==1}function Of(e,t,n){n===void 0&&(n=!1);var r=Ve(t),o=Ve(t)&&Rf(t),s=it(t),i=Ut(e,o,n),l={scrollLeft:0,scrollTop:0},c={x:0,y:0};return(r||!r&&!n)&&((We(t)!=="body"||Go(s))&&(l=Tf(t)),Ve(t)?(c=Ut(t,!0),c.x+=t.clientLeft,c.y+=t.clientTop):s&&(c.x=Fo(s))),{x:i.left+l.scrollLeft-c.x,y:i.top+l.scrollTop-c.y,width:i.width,height:i.height}}function _f(e){var t=new Map,n=new Set,r=[];e.forEach(function(s){t.set(s.name,s)});function o(s){n.add(s.name);var i=[].concat(s.requires||[],s.requiresIfExists||[]);i.forEach(function(l){if(!n.has(l)){var c=t.get(l);c&&o(c)}}),r.push(s)}return e.forEach(function(s){n.has(s.name)||o(s)}),r}function Pf(e){var t=_f(e);return Fw.reduce(function(n,r){return n.concat(t.filter(function(o){return o.phase===r}))},[])}function If(e){var t;return function(){return t||(t=new Promise(function(n){Promise.resolve().then(function(){t=void 0,n(e())})})),t}}function Mf(e){var t=e.reduce(function(n,r){var o=n[r.name];return n[r.name]=o?Object.assign({},o,r,{options:Object.assign({},o.options,r.options),data:Object.assign({},o.data,r.data)}):r,n},{});return Object.keys(t).map(function(n){return t[n]})}var Ya={placement:"bottom",modifiers:[],strategy:"absolute"};function Wa(){for(var e=arguments.length,t=new Array(e),n=0;njo({root:["root"]},yw(Bf)),Uf={},qf=M.forwardRef(function(t,n){var r;const{anchorEl:o,children:s,direction:i,disablePortal:l,modifiers:c,open:d,placement:u,popperOptions:h,popperRef:w,slotProps:b={},slots:x={},TransitionProps:f}=t,m=Ne(t,Vf),S=M.useRef(null),R=yt(S,n),j=M.useRef(null),E=yt(j,w),v=M.useRef(E);Lt(()=>{v.current=E},[E]),M.useImperativeHandle(w,()=>j.current,[]);const P=Lf(u,i),[V,U]=M.useState(P),[C,_]=M.useState(tr(o));M.useEffect(()=>{j.current&&j.current.forceUpdate()}),M.useEffect(()=>{o&&_(tr(o))},[o]),Lt(()=>{if(!C||!d)return;const Y=se=>{U(se.placement)};if(process.env.NODE_ENV!=="production"&&C&&Nr(C)&&C.nodeType===1){const se=C.getBoundingClientRect();process.env.NODE_ENV!=="test"&&se.top===0&&se.left===0&&se.right===0&&se.bottom===0&&console.warn(["MUI: The `anchorEl` prop provided to the component is invalid.","The anchor element should be part of the document layout.","Make sure the element is present in the document or that it's not display none."].join(` +`))}let F=[{name:"preventOverflow",options:{altBoundary:l}},{name:"flip",options:{altBoundary:l}},{name:"onUpdate",enabled:!0,phase:"afterWrite",fn:({state:se})=>{Y(se)}}];c!=null&&(F=F.concat(c)),h&&h.modifiers!=null&&(F=F.concat(h.modifiers));const te=Af(C,S.current,O({placement:P},h,{modifiers:F}));return v.current(te),()=>{te.destroy(),v.current(null)}},[C,l,c,d,h,P]);const k={placement:V};f!==null&&(k.TransitionProps=f);const D=Gf(),$=(r=x.root)!=null?r:"div",J=jw({elementType:$,externalSlotProps:b.root,externalForwardedProps:m,additionalProps:{role:"tooltip",ref:R},ownerState:t,className:D.root});return a.jsx($,O({},J,{children:typeof s=="function"?s(k):s}))}),Di=M.forwardRef(function(t,n){const{anchorEl:r,children:o,container:s,direction:i="ltr",disablePortal:l=!1,keepMounted:c=!1,modifiers:d,open:u,placement:h="bottom",popperOptions:w=Uf,popperRef:b,style:x,transition:f=!1,slotProps:m={},slots:S={}}=t,R=Ne(t,zf),[j,E]=M.useState(!0),v=()=>{E(!1)},P=()=>{E(!0)};if(!c&&!u&&(!f||j))return null;let V;if(s)V=s;else if(r){const _=tr(r);V=_&&Nr(_)?Kn(_).body:Kn(null).body}const U=!u&&c&&(!f||j)?"none":void 0,C=f?{in:u,onEnter:v,onExited:P}:void 0;return a.jsx(Qn,{disablePortal:l,container:V,children:a.jsx(qf,O({anchorEl:r,direction:i,disablePortal:l,modifiers:d,ref:n,open:f?!j:u,placement:h,popperOptions:w,popperRef:b,slotProps:m,slots:S},R,{style:O({position:"fixed",top:0,left:0,display:U},x),TransitionProps:C,children:o}))})});process.env.NODE_ENV!=="production"&&(Di.propTypes={anchorEl:So(p.oneOfType([xn,p.object,p.func]),e=>{if(e.open){const t=tr(e.anchorEl);if(t&&Nr(t)&&t.nodeType===1){const n=t.getBoundingClientRect();if(process.env.NODE_ENV!=="test"&&n.top===0&&n.left===0&&n.right===0&&n.bottom===0)return new Error(["MUI: The `anchorEl` prop provided to the component is invalid.","The anchor element should be part of the document layout.","Make sure the element is present in the document or that it's not display none."].join(` `))}else if(!t||typeof t.getBoundingClientRect!="function"||Ff(t)&&t.contextElement!=null&&t.contextElement.nodeType!==1)return new Error(["MUI: The `anchorEl` prop provided to the component is invalid.","It should be an HTML element instance or a virtualElement ","(https://popper.js.org/docs/v2/virtual-elements/)."].join(` -`))}return null}),children:p.oneOfType([p.node,p.func]),container:p.oneOfType([xn,p.func]),direction:p.oneOf(["ltr","rtl"]),disablePortal:p.bool,keepMounted:p.bool,modifiers:p.arrayOf(p.shape({data:p.object,effect:p.func,enabled:p.bool,fn:p.func,name:p.any,options:p.object,phase:p.oneOf(["afterMain","afterRead","afterWrite","beforeMain","beforeRead","beforeWrite","main","read","write"]),requires:p.arrayOf(p.string),requiresIfExists:p.arrayOf(p.string)})),open:p.bool.isRequired,placement:p.oneOf(["auto-end","auto-start","auto","bottom-end","bottom-start","bottom","left-end","left-start","left","right-end","right-start","right","top-end","top-start","top"]),popperOptions:p.shape({modifiers:p.array,onFirstUpdate:p.func,placement:p.oneOf(["auto-end","auto-start","auto","bottom-end","bottom-start","bottom","left-end","left-start","left","right-end","right-start","right","top-end","top-start","top"]),strategy:p.oneOf(["absolute","fixed"])}),popperRef:li,slotProps:p.shape({root:p.oneOfType([p.func,p.object])}),slots:p.shape({root:p.elementType}),transition:p.bool});function Ai(){const e=xi(Oo);return process.env.NODE_ENV!=="production"&&M.useDebugValue(e),e[_o]||e}function Qr(e,t){return Qr=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,o){return r.__proto__=o,r},Qr(e,t)}function Hf(e,t){e.prototype=Object.create(t.prototype),e.prototype.constructor=e,Qr(e,t)}const Xa={disabled:!1};var Xf=process.env.NODE_ENV!=="production"?p.oneOfType([p.number,p.shape({enter:p.number,exit:p.number,appear:p.number}).isRequired]):null;process.env.NODE_ENV!=="production"&&p.oneOfType([p.string,p.shape({enter:p.string,exit:p.string,active:p.string}),p.shape({enter:p.string,enterDone:p.string,enterActive:p.string,exit:p.string,exitDone:p.string,exitActive:p.string})]);const Bi=g.createContext(null);var Yf=function(t){return t.scrollTop},pn="unmounted",wt="exited",ft="entering",$t="entered",eo="exiting",nt=function(e){Hf(t,e);function t(r,o){var s;s=e.call(this,r,o)||this;var i=o,l=i&&!i.isMounting?r.enter:r.appear,c;return s.appearStatus=null,r.in?l?(c=wt,s.appearStatus=ft):c=$t:r.unmountOnExit||r.mountOnEnter?c=pn:c=wt,s.state={status:c},s.nextCallback=null,s}t.getDerivedStateFromProps=function(o,s){var i=o.in;return i&&s.status===pn?{status:wt}:null};var n=t.prototype;return n.componentDidMount=function(){this.updateStatus(!0,this.appearStatus)},n.componentDidUpdate=function(o){var s=null;if(o!==this.props){var i=this.state.status;this.props.in?i!==ft&&i!==$t&&(s=ft):(i===ft||i===$t)&&(s=eo)}this.updateStatus(!1,s)},n.componentWillUnmount=function(){this.cancelNextCallback()},n.getTimeouts=function(){var o=this.props.timeout,s,i,l;return s=i=l=o,o!=null&&typeof o!="number"&&(s=o.exit,i=o.enter,l=o.appear!==void 0?o.appear:i),{exit:s,enter:i,appear:l}},n.updateStatus=function(o,s){if(o===void 0&&(o=!1),s!==null)if(this.cancelNextCallback(),s===ft){if(this.props.unmountOnExit||this.props.mountOnEnter){var i=this.props.nodeRef?this.props.nodeRef.current:ln.findDOMNode(this);i&&Yf(i)}this.performEnter(o)}else this.performExit();else this.props.unmountOnExit&&this.state.status===wt&&this.setState({status:pn})},n.performEnter=function(o){var s=this,i=this.props.enter,l=this.context?this.context.isMounting:o,c=this.props.nodeRef?[l]:[ln.findDOMNode(this),l],d=c[0],u=c[1],m=this.getTimeouts(),w=l?m.appear:m.enter;if(!o&&!i||Xa.disabled){this.safeSetState({status:$t},function(){s.props.onEntered(d)});return}this.props.onEnter(d,u),this.safeSetState({status:ft},function(){s.props.onEntering(d,u),s.onTransitionEnd(w,function(){s.safeSetState({status:$t},function(){s.props.onEntered(d,u)})})})},n.performExit=function(){var o=this,s=this.props.exit,i=this.getTimeouts(),l=this.props.nodeRef?void 0:ln.findDOMNode(this);if(!s||Xa.disabled){this.safeSetState({status:wt},function(){o.props.onExited(l)});return}this.props.onExit(l),this.safeSetState({status:eo},function(){o.props.onExiting(l),o.onTransitionEnd(i.exit,function(){o.safeSetState({status:wt},function(){o.props.onExited(l)})})})},n.cancelNextCallback=function(){this.nextCallback!==null&&(this.nextCallback.cancel(),this.nextCallback=null)},n.safeSetState=function(o,s){s=this.setNextCallback(s),this.setState(o,s)},n.setNextCallback=function(o){var s=this,i=!0;return this.nextCallback=function(l){i&&(i=!1,s.nextCallback=null,o(l))},this.nextCallback.cancel=function(){i=!1},this.nextCallback},n.onTransitionEnd=function(o,s){this.setNextCallback(s);var i=this.props.nodeRef?this.props.nodeRef.current:ln.findDOMNode(this),l=o==null&&!this.props.addEndListener;if(!i||l){setTimeout(this.nextCallback,0);return}if(this.props.addEndListener){var c=this.props.nodeRef?[this.nextCallback]:[i,this.nextCallback],d=c[0],u=c[1];this.props.addEndListener(d,u)}o!=null&&setTimeout(this.nextCallback,o)},n.render=function(){var o=this.state.status;if(o===pn)return null;var s=this.props,i=s.children;s.in,s.mountOnEnter,s.unmountOnExit,s.appear,s.enter,s.exit,s.timeout,s.addEndListener,s.onEnter,s.onEntering,s.onEntered,s.onExit,s.onExiting,s.onExited,s.nodeRef;var l=Ne(s,["children","in","mountOnEnter","unmountOnExit","appear","enter","exit","timeout","addEndListener","onEnter","onEntering","onEntered","onExit","onExiting","onExited","nodeRef"]);return g.createElement(Bi.Provider,{value:null},typeof i=="function"?i(o,l):g.cloneElement(g.Children.only(i),l))},t}(g.Component);nt.contextType=Bi;nt.propTypes=process.env.NODE_ENV!=="production"?{nodeRef:p.shape({current:typeof Element>"u"?p.any:function(e,t,n,r,o,s){var i=e[t];return p.instanceOf(i&&"ownerDocument"in i?i.ownerDocument.defaultView.Element:Element)(e,t,n,r,o,s)}}),children:p.oneOfType([p.func.isRequired,p.element.isRequired]).isRequired,in:p.bool,mountOnEnter:p.bool,unmountOnExit:p.bool,appear:p.bool,enter:p.bool,exit:p.bool,timeout:function(t){var n=Xf;t.addEndListener||(n=n.isRequired);for(var r=arguments.length,o=new Array(r>1?r-1:0),s=1;se.scrollTop;function Ya(e,t){var n,r;const{timeout:o,easing:s,style:i={}}=e;return{duration:(n=i.transitionDuration)!=null?n:typeof o=="number"?o:o[t.mode]||0,easing:(r=i.transitionTimingFunction)!=null?r:typeof s=="object"?s[t.mode]:s,delay:i.transitionDelay}}const Jf=["addEndListener","appear","children","easing","in","onEnter","onEntered","onEntering","onExit","onExited","onExiting","style","timeout","TransitionComponent"];function to(e){return`scale(${e}, ${e**2})`}const Zf={entering:{opacity:1,transform:to(1)},entered:{opacity:1,transform:"none"}},zr=typeof navigator<"u"&&/^((?!chrome|android).)*(safari|mobile)/i.test(navigator.userAgent)&&/(os |version\/)15(.|_)4/i.test(navigator.userAgent),Lo=M.forwardRef(function(t,n){const{addEndListener:r,appear:o=!0,children:s,easing:i,in:l,onEnter:c,onEntered:d,onEntering:u,onExit:m,onExited:w,onExiting:b,style:x,timeout:f="auto",TransitionComponent:h=Wf}=t,S=Ne(t,Jf),R=dn(),j=M.useRef(),E=Ai(),v=M.useRef(null),P=yt(v,s.ref,n),V=Y=>F=>{if(Y){const te=v.current;F===void 0?Y(te):Y(te,F)}},U=V(u),T=V((Y,F)=>{Kf(Y);const{duration:te,delay:se,easing:oe}=Ya({style:x,timeout:f,easing:i},{mode:"enter"});let y;f==="auto"?(y=E.transitions.getAutoHeightDuration(Y.clientHeight),j.current=y):y=te,Y.style.transition=[E.transitions.create("opacity",{duration:y,delay:se}),E.transitions.create("transform",{duration:zr?y:y*.666,delay:se,easing:oe})].join(","),c&&c(Y,F)}),_=V(d),k=V(b),D=V(Y=>{const{duration:F,delay:te,easing:se}=Ya({style:x,timeout:f,easing:i},{mode:"exit"});let oe;f==="auto"?(oe=E.transitions.getAutoHeightDuration(Y.clientHeight),j.current=oe):oe=F,Y.style.transition=[E.transitions.create("opacity",{duration:oe,delay:te}),E.transitions.create("transform",{duration:zr?oe:oe*.666,delay:zr?te:te||oe*.333,easing:se})].join(","),Y.style.opacity=0,Y.style.transform=to(.75),m&&m(Y)}),$=V(w),J=Y=>{f==="auto"&&R.start(j.current||0,Y),r&&r(v.current,Y)};return a.jsx(h,O({appear:o,in:l,nodeRef:v,onEnter:T,onEntered:_,onEntering:U,onExit:D,onExited:$,onExiting:k,addEndListener:J,timeout:f==="auto"?null:f},S,{children:(Y,F)=>M.cloneElement(s,O({style:O({opacity:0,transform:to(.75),visibility:Y==="exited"&&!l?"hidden":void 0},Zf[Y],x,s.props.style),ref:P},F))}))});process.env.NODE_ENV!=="production"&&(Lo.propTypes={addEndListener:p.func,appear:p.bool,children:si.isRequired,easing:p.oneOfType([p.shape({enter:p.string,exit:p.string}),p.string]),in:p.bool,onEnter:p.func,onEntered:p.func,onEntering:p.func,onExit:p.func,onExited:p.func,onExiting:p.func,style:p.object,timeout:p.oneOfType([p.oneOf(["auto"]),p.number,p.shape({appear:p.number,enter:p.number,exit:p.number})])});Lo.muiSupportAuto=!0;const Wa=Lo,Qf=["anchorEl","component","components","componentsProps","container","disablePortal","keepMounted","modifiers","open","placement","popperOptions","popperRef","transition","slots","slotProps"],em=In(Di,{name:"MuiPopper",slot:"Root",overridesResolver:(e,t)=>t.root})({}),Vi=M.forwardRef(function(t,n){var r;const o=vi(),s=Po({props:t,name:"MuiPopper"}),{anchorEl:i,component:l,components:c,componentsProps:d,container:u,disablePortal:m,keepMounted:w,modifiers:b,open:x,placement:f,popperOptions:h,popperRef:S,transition:R,slots:j,slotProps:E}=s,v=Ne(s,Qf),P=(r=j==null?void 0:j.root)!=null?r:c==null?void 0:c.Root,V=O({anchorEl:i,container:u,disablePortal:m,keepMounted:w,modifiers:b,open:x,placement:f,popperOptions:h,popperRef:S,transition:R},v);return a.jsx(em,O({as:l,direction:o==null?void 0:o.direction,slots:{root:P},slotProps:E??d},V,{ref:n}))});process.env.NODE_ENV!=="production"&&(Vi.propTypes={anchorEl:p.oneOfType([xn,p.object,p.func]),children:p.oneOfType([p.node,p.func]),component:p.elementType,components:p.shape({Root:p.elementType}),componentsProps:p.shape({root:p.oneOfType([p.func,p.object])}),container:p.oneOfType([xn,p.func]),disablePortal:p.bool,keepMounted:p.bool,modifiers:p.arrayOf(p.shape({data:p.object,effect:p.func,enabled:p.bool,fn:p.func,name:p.any,options:p.object,phase:p.oneOf(["afterMain","afterRead","afterWrite","beforeMain","beforeRead","beforeWrite","main","read","write"]),requires:p.arrayOf(p.string),requiresIfExists:p.arrayOf(p.string)})),open:p.bool.isRequired,placement:p.oneOf(["auto-end","auto-start","auto","bottom-end","bottom-start","bottom","left-end","left-start","left","right-end","right-start","right","top-end","top-start","top"]),popperOptions:p.shape({modifiers:p.array,onFirstUpdate:p.func,placement:p.oneOf(["auto-end","auto-start","auto","bottom-end","bottom-start","bottom","left-end","left-start","left","right-end","right-start","right","top-end","top-start","top"]),strategy:p.oneOf(["absolute","fixed"])}),popperRef:li,slotProps:p.shape({root:p.oneOfType([p.func,p.object])}),slots:p.shape({root:p.elementType}),sx:p.oneOfType([p.arrayOf(p.oneOfType([p.func,p.object,p.bool])),p.func,p.object]),transition:p.bool});const zi=Vi;function tm(e){return dr("MuiTooltip",e)}const nm=mi("MuiTooltip",["popper","popperInteractive","popperArrow","popperClose","tooltip","tooltipArrow","touch","tooltipPlacementLeft","tooltipPlacementRight","tooltipPlacementTop","tooltipPlacementBottom","arrow"]),at=nm,rm=["arrow","children","classes","components","componentsProps","describeChild","disableFocusListener","disableHoverListener","disableInteractive","disableTouchListener","enterDelay","enterNextDelay","enterTouchDelay","followCursor","id","leaveDelay","leaveTouchDelay","onClose","onOpen","open","placement","PopperComponent","PopperProps","slotProps","slots","title","TransitionComponent","TransitionProps"];function om(e){return Math.round(e*1e5)/1e5}const am=e=>{const{classes:t,disableInteractive:n,arrow:r,touch:o,placement:s}=e,i={popper:["popper",!n&&"popperInteractive",r&&"popperArrow"],tooltip:["tooltip",r&&"tooltipArrow",o&&"touch",`tooltipPlacement${Ye(s.split("-")[0])}`],arrow:["arrow"]};return ko(i,tm,t)},sm=In(zi,{name:"MuiTooltip",slot:"Popper",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.popper,!n.disableInteractive&&t.popperInteractive,n.arrow&&t.popperArrow,!n.open&&t.popperClose]}})(({theme:e,ownerState:t,open:n})=>O({zIndex:(e.vars||e).zIndex.tooltip,pointerEvents:"none"},!t.disableInteractive&&{pointerEvents:"auto"},!n&&{pointerEvents:"none"},t.arrow&&{[`&[data-popper-placement*="bottom"] .${at.arrow}`]:{top:0,marginTop:"-0.71em","&::before":{transformOrigin:"0 100%"}},[`&[data-popper-placement*="top"] .${at.arrow}`]:{bottom:0,marginBottom:"-0.71em","&::before":{transformOrigin:"100% 0"}},[`&[data-popper-placement*="right"] .${at.arrow}`]:O({},t.isRtl?{right:0,marginRight:"-0.71em"}:{left:0,marginLeft:"-0.71em"},{height:"1em",width:"0.71em","&::before":{transformOrigin:"100% 100%"}}),[`&[data-popper-placement*="left"] .${at.arrow}`]:O({},t.isRtl?{left:0,marginLeft:"-0.71em"}:{right:0,marginRight:"-0.71em"},{height:"1em",width:"0.71em","&::before":{transformOrigin:"0 0"}})})),im=In("div",{name:"MuiTooltip",slot:"Tooltip",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.tooltip,n.touch&&t.touch,n.arrow&&t.tooltipArrow,t[`tooltipPlacement${Ye(n.placement.split("-")[0])}`]]}})(({theme:e,ownerState:t})=>O({backgroundColor:e.vars?e.vars.palette.Tooltip.bg:yi(e.palette.grey[700],.92),borderRadius:(e.vars||e).shape.borderRadius,color:(e.vars||e).palette.common.white,fontFamily:e.typography.fontFamily,padding:"4px 8px",fontSize:e.typography.pxToRem(11),maxWidth:300,margin:2,wordWrap:"break-word",fontWeight:e.typography.fontWeightMedium},t.arrow&&{position:"relative",margin:0},t.touch&&{padding:"8px 16px",fontSize:e.typography.pxToRem(14),lineHeight:`${om(16/14)}em`,fontWeight:e.typography.fontWeightRegular},{[`.${at.popper}[data-popper-placement*="left"] &`]:O({transformOrigin:"right center"},t.isRtl?O({marginLeft:"14px"},t.touch&&{marginLeft:"24px"}):O({marginRight:"14px"},t.touch&&{marginRight:"24px"})),[`.${at.popper}[data-popper-placement*="right"] &`]:O({transformOrigin:"left center"},t.isRtl?O({marginRight:"14px"},t.touch&&{marginRight:"24px"}):O({marginLeft:"14px"},t.touch&&{marginLeft:"24px"})),[`.${at.popper}[data-popper-placement*="top"] &`]:O({transformOrigin:"center bottom",marginBottom:"14px"},t.touch&&{marginBottom:"24px"}),[`.${at.popper}[data-popper-placement*="bottom"] &`]:O({transformOrigin:"center top",marginTop:"14px"},t.touch&&{marginTop:"24px"})})),lm=In("span",{name:"MuiTooltip",slot:"Arrow",overridesResolver:(e,t)=>t.arrow})(({theme:e})=>({overflow:"hidden",position:"absolute",width:"1em",height:"0.71em",boxSizing:"border-box",color:e.vars?e.vars.palette.Tooltip.bg:yi(e.palette.grey[700],.9),"&::before":{content:'""',margin:"auto",display:"block",width:"100%",height:"100%",backgroundColor:"currentColor",transform:"rotate(45deg)"}}));let Gn=!1;const Ka=new On;let sn={x:0,y:0};function Un(e,t){return n=>{t&&t(n),e(n)}}const Li=M.forwardRef(function(t,n){var r,o,s,i,l,c,d,u,m,w,b,x,f,h,S,R,j,E,v;const P=Po({props:t,name:"MuiTooltip"}),{arrow:V=!1,children:U,components:T={},componentsProps:_={},describeChild:k=!1,disableFocusListener:D=!1,disableHoverListener:$=!1,disableInteractive:J=!1,disableTouchListener:Y=!1,enterDelay:F=100,enterNextDelay:te=0,enterTouchDelay:se=700,followCursor:oe=!1,id:y,leaveDelay:C=0,leaveTouchDelay:z=1500,onClose:L,onOpen:B,open:X,placement:q="bottom",PopperComponent:H,PopperProps:G={},slotProps:K={},slots:Z={},title:ue,TransitionComponent:I=Wa,TransitionProps:ye}=P,A=Ne(P,rm),xe=M.isValidElement(U)?U:a.jsx("span",{children:U}),Ge=Ai(),lt=Ge.direction==="rtl",[Ee,Dn]=M.useState(),[Ue,Et]=M.useState(null),ct=M.useRef(!1),jt=J||oe,Tt=dn(),Ct=dn(),dt=dn(),Jt=dn(),[An,Go]=di({controlled:X,default:!1,name:"Tooltip",state:"open"});let Ke=An;if(process.env.NODE_ENV!=="production"){const{current:ee}=M.useRef(X!==void 0);M.useEffect(()=>{Ee&&Ee.disabled&&!ee&&ue!==""&&Ee.tagName.toLowerCase()==="button"&&console.error(["MUI: You are providing a disabled `button` child to the Tooltip component.","A disabled element does not fire events.","Tooltip needs to listen to the child element's events to display the title.","","Add a simple wrapper element, such as a `span`."].join(` -`))},[ue,Ee,ee])}const Nr=ci(y),Zt=M.useRef(),Bn=Wr(()=>{Zt.current!==void 0&&(document.body.style.WebkitUserSelect=Zt.current,Zt.current=void 0),Jt.clear()});M.useEffect(()=>Bn,[Bn]);const Uo=ee=>{Ka.clear(),Gn=!0,Go(!0),B&&!Ke&&B(ee)},Vn=Wr(ee=>{Ka.start(800+C,()=>{Gn=!1}),Go(!1),L&&Ke&&L(ee),Tt.start(Ge.transitions.duration.shortest,()=>{ct.current=!1})}),kr=ee=>{ct.current&&ee.type!=="touchstart"||(Ee&&Ee.removeAttribute("title"),Ct.clear(),dt.clear(),F||Gn&&te?Ct.start(Gn?te:F,()=>{Uo(ee)}):Uo(ee))},qo=ee=>{Ct.clear(),dt.start(C,()=>{Vn(ee)})},{isFocusVisibleRef:Ho,onBlur:rl,onFocus:ol,ref:al}=ui(),[,Xo]=M.useState(!1),Yo=ee=>{rl(ee),Ho.current===!1&&(Xo(!1),qo(ee))},Wo=ee=>{Ee||Dn(ee.currentTarget),ol(ee),Ho.current===!0&&(Xo(!0),kr(ee))},Ko=ee=>{ct.current=!0;const Pe=xe.props;Pe.onTouchStart&&Pe.onTouchStart(ee)},Jo=kr,Zo=qo,sl=ee=>{Ko(ee),dt.clear(),Tt.clear(),Bn(),Zt.current=document.body.style.WebkitUserSelect,document.body.style.WebkitUserSelect="none",Jt.start(se,()=>{document.body.style.WebkitUserSelect=Zt.current,kr(ee)})},il=ee=>{xe.props.onTouchEnd&&xe.props.onTouchEnd(ee),Bn(),dt.start(z,()=>{Vn(ee)})};M.useEffect(()=>{if(!Ke)return;function ee(Pe){(Pe.key==="Escape"||Pe.key==="Esc")&&Vn(Pe)}return document.addEventListener("keydown",ee),()=>{document.removeEventListener("keydown",ee)}},[Vn,Ke]);const ll=yt(xe.ref,al,Dn,n);!ue&&ue!==0&&(Ke=!1);const Sr=M.useRef(),cl=ee=>{const Pe=xe.props;Pe.onMouseMove&&Pe.onMouseMove(ee),sn={x:ee.clientX,y:ee.clientY},Sr.current&&Sr.current.update()},Qt={},Er=typeof ue=="string";k?(Qt.title=!Ke&&Er&&!$?ue:null,Qt["aria-describedby"]=Ke?Nr:null):(Qt["aria-label"]=Er?ue:null,Qt["aria-labelledby"]=Ke&&!Er?Nr:null);const De=O({},Qt,A,xe.props,{className:ot(A.className,xe.props.className),onTouchStart:Ko,ref:ll},oe?{onMouseMove:cl}:{});process.env.NODE_ENV!=="production"&&(De["data-mui-internal-clone-element"]=!0,M.useEffect(()=>{Ee&&!Ee.getAttribute("data-mui-internal-clone-element")&&console.error(["MUI: The `children` component of the Tooltip is not forwarding its props correctly.","Please make sure that props are spread on the same element that the ref is applied to."].join(` -`))},[Ee]));const en={};Y||(De.onTouchStart=sl,De.onTouchEnd=il),$||(De.onMouseOver=Un(Jo,De.onMouseOver),De.onMouseLeave=Un(Zo,De.onMouseLeave),jt||(en.onMouseOver=Jo,en.onMouseLeave=Zo)),D||(De.onFocus=Un(Wo,De.onFocus),De.onBlur=Un(Yo,De.onBlur),jt||(en.onFocus=Wo,en.onBlur=Yo)),process.env.NODE_ENV!=="production"&&xe.props.title&&console.error(["MUI: You have provided a `title` prop to the child of .",`Remove this title prop \`${xe.props.title}\` or the Tooltip component.`].join(` -`));const dl=M.useMemo(()=>{var ee;let Pe=[{name:"arrow",enabled:!!Ue,options:{element:Ue,padding:4}}];return(ee=G.popperOptions)!=null&&ee.modifiers&&(Pe=Pe.concat(G.popperOptions.modifiers)),O({},G.popperOptions,{modifiers:Pe})},[Ue,G]),tn=O({},P,{isRtl:lt,arrow:V,disableInteractive:jt,placement:q,PopperComponentProp:H,touch:ct.current}),jr=am(tn),Qo=(r=(o=Z.popper)!=null?o:T.Popper)!=null?r:sm,ea=(s=(i=(l=Z.transition)!=null?l:T.Transition)!=null?i:I)!=null?s:Wa,ta=(c=(d=Z.tooltip)!=null?d:T.Tooltip)!=null?c:im,na=(u=(m=Z.arrow)!=null?m:T.Arrow)!=null?u:lm,ul=un(Qo,O({},G,(w=K.popper)!=null?w:_.popper,{className:ot(jr.popper,G==null?void 0:G.className,(b=(x=K.popper)!=null?x:_.popper)==null?void 0:b.className)}),tn),pl=un(ea,O({},ye,(f=K.transition)!=null?f:_.transition),tn),wl=un(ta,O({},(h=K.tooltip)!=null?h:_.tooltip,{className:ot(jr.tooltip,(S=(R=K.tooltip)!=null?R:_.tooltip)==null?void 0:S.className)}),tn),fl=un(na,O({},(j=K.arrow)!=null?j:_.arrow,{className:ot(jr.arrow,(E=(v=K.arrow)!=null?v:_.arrow)==null?void 0:E.className)}),tn);return a.jsxs(M.Fragment,{children:[M.cloneElement(xe,De),a.jsx(Qo,O({as:H??zi,placement:q,anchorEl:oe?{getBoundingClientRect:()=>({top:sn.y,left:sn.x,right:sn.x,bottom:sn.y,width:0,height:0})}:Ee,popperRef:Sr,open:Ee?Ke:!1,id:Nr,transition:!0},en,ul,{popperOptions:dl,children:({TransitionProps:ee})=>a.jsx(ea,O({timeout:Ge.transitions.duration.shorter},ee,pl,{children:a.jsxs(ta,O({},wl,{children:[ue,V?a.jsx(na,O({},fl,{ref:Et})):null]}))}))}))]})});process.env.NODE_ENV!=="production"&&(Li.propTypes={arrow:p.bool,children:si.isRequired,classes:p.object,className:p.string,components:p.shape({Arrow:p.elementType,Popper:p.elementType,Tooltip:p.elementType,Transition:p.elementType}),componentsProps:p.shape({arrow:p.object,popper:p.object,tooltip:p.object,transition:p.object}),describeChild:p.bool,disableFocusListener:p.bool,disableHoverListener:p.bool,disableInteractive:p.bool,disableTouchListener:p.bool,enterDelay:p.number,enterNextDelay:p.number,enterTouchDelay:p.number,followCursor:p.bool,id:p.string,leaveDelay:p.number,leaveTouchDelay:p.number,onClose:p.func,onOpen:p.func,open:p.bool,placement:p.oneOf(["bottom-end","bottom-start","bottom","left-end","left-start","left","right-end","right-start","right","top-end","top-start","top"]),PopperComponent:p.elementType,PopperProps:p.object,slotProps:p.shape({arrow:p.object,popper:p.object,tooltip:p.object,transition:p.object}),slots:p.shape({arrow:p.elementType,popper:p.elementType,tooltip:p.elementType,transition:p.elementType}),sx:p.oneOfType([p.arrayOf(p.oneOfType([p.func,p.object,p.bool])),p.func,p.object]),title:p.node,TransitionComponent:p.elementType,TransitionProps:p.object});const cm=Li;function Ja(e,t,n){return e?a.jsx(Te.ListItemIcon,{className:`papi-menu-icon-${n?"leading":"trailing"}`,children:a.jsx("img",{src:e,alt:`${n?"Leading":"Trailing"} icon for ${t}`})}):void 0}function Fo(e){const{onClick:t,label:n,tooltip:r,allowForLeadingIcons:o=!0,iconPathBefore:s=void 0,iconPathAfter:i=void 0,hasAutoFocus:l=!1,className:c,isDisabled:d=!1,isDense:u=!0,isSubMenuParent:m=!1,hasDisabledGutters:w=!1,hasDivider:b=!1,focusVisibleClassName:x,id:f,children:h}=e,S=a.jsx(Te.MenuItem,{sx:{lineHeight:.8},autoFocus:l,className:c,disabled:d,dense:u,disableGutters:w,divider:b,focusVisibleClassName:x,onClick:t,id:f,children:n?a.jsxs(a.Fragment,{children:[Ja(s,n,!0),a.jsx(Te.ListItemText,{primary:n,inset:!s&&o}),m?a.jsx(Te.ListItemIcon,{className:"papi-menu-icon-trailing",children:a.jsx(ki,{})}):Ja(i,n,!1)]}):h});return r?a.jsx(cm,{title:r,placement:"right",children:a.jsx("div",{children:S})}):S}function Fi(e){return Object.entries(e.groups).map(([n,r])=>({id:n,group:r}))}function dm(e){const[t,n]=g.useState(void 0),{parentMenuItem:r,parentItemProps:o,menuDefinition:s}=e,i=d=>{n(d.currentTarget)},l=()=>{n(void 0)},c=()=>{let d=Fi(s).filter(u=>"menuItem"in u.group);if(!(r!=null&&r.id))throw new Error("A valid parent menu item is required for submenus.");return d=d.filter(u=>"menuItem"in u.group&&u.group.menuItem===r.id),a.jsx(Gi,{...e,includedGroups:d})};return a.jsxs(a.Fragment,{children:[a.jsx(Fo,{onClick:i,...o,isSubMenuParent:!0}),a.jsx(Te.Menu,{anchorEl:t,open:!!t,onClose:l,anchorOrigin:{vertical:"top",horizontal:"right"},transformOrigin:{vertical:"top",horizontal:"left"},children:c()},r.id)]})}const um=(e,t)=>t.filter(o=>o.group===e).sort((o,s)=>(o.order||0)-(s.order||0));function Gi(e){const{menuDefinition:t,onClick:n,commandHandler:r,includedGroups:o}=e,{items:s,allowForLeadingIcons:i}=g.useMemo(()=>{const u=o&&o.length>0?o:Fi(t).filter(x=>!("menuItem"in x.group)),m=Object.values(u).sort((x,f)=>(x.group.order||0)-(f.group.order||0)),w=[];m.forEach(x=>{um(x.id,t.items).forEach(f=>w.push({item:f,isLastItemInGroup:!1})),w.length>0&&(w[w.length-1].isLastItemInGroup=!0)}),w.length>0&&(w[w.length-1].isLastItemInGroup=!1);const b=w.some(x=>"iconPathBefore"in x.item&&x.item.iconPathBefore);return{items:w,allowForLeadingIcons:b}},[o,t]),l=({item:u,isLastItemInGroup:m})=>({className:"papi-menu-item",label:u.label,tooltip:u.tooltip,iconPathBefore:"iconPathBefore"in u?u.iconPathBefore:void 0,iconPathAfter:"iconPathAfter"in u?u.iconPathAfter:void 0,hasDivider:m,allowForLeadingIcons:i}),[c]=s;if(!c)return a.jsx("div",{});const d=c.item.group;return a.jsx("div",{role:"menu","aria-label":d,children:s.map((u,m)=>{const{item:w}=u,b=l(u);if("command"in w){const x=w.group+m;return a.jsx(Fo,{onClick:f=>{n==null||n(f),r(w)},...b},x)}return a.jsx(dm,{parentMenuItem:w,parentItemProps:b,...e},d+w.id)})},d)}function pm(e){const{menuDefinition:t,columnId:n}=e;let s=Object.entries(t.groups).map(([i,l])=>({id:i,group:l})).filter(i=>"column"in i.group);return n&&"columns"in t&&t.columns[n]&&(s=s.filter(i=>"column"in i.group&&i.group.column===n)),a.jsx(Gi,{...e,includedGroups:s})}function wm({commandHandler:e,menuDefinition:t,id:n,metadata:r,onClick:o,className:s}){return a.jsxs(Te.Grid,{id:n,item:!0,xs:"auto",role:"menu","aria-label":n,className:`papi-menu-column ${s??""}`,children:[a.jsx("h3",{"aria-label":r.label,className:`papi-menu-column-header ${s??""}`,children:r.label}),a.jsx(Te.List,{id:n,dense:!0,className:s??"",children:a.jsx(pm,{commandHandler:e,menuDefinition:t,columnId:n,onClick:o})})]})}function Ui({commandHandler:e,className:t,multiColumnMenu:n,id:r}){const{columns:o}=n,s=g.useMemo(()=>{const i=new Map;return Object.getOwnPropertyNames(o).forEach(l=>{if(l==="isExtensible")return;const c=l,d=o[c];typeof d=="object"&&typeof d.order=="number"&&!Number.isNaN(d.order)?i.set(d.order,{id:c,metadata:d}):console.warn(`Property ${l} (${typeof d}) on menu ${r} is not a valid column and is being ignored. This might indicate data corruption`)}),Array.from(i.values()).sort((l,c)=>(l.metadata.order||0)-(c.metadata.order||0))},[o,r]);return a.jsx(Te.Grid,{container:!0,spacing:0,className:`papi-multi-column-menu ${t??""}`,columns:s.length,role:"menu","aria-label":"GridMenu",id:r,children:s.map((i,l)=>a.jsx(wm,{commandHandler:e,menuDefinition:n,...i,className:t},l))})}function fm(e){return{preserveValue:!0,...e}}const tr=(e,t,n={})=>{const r=g.useRef(t);r.current=t;const o=g.useRef(n);o.current=fm(o.current);const[s,i]=g.useState(()=>r.current),[l,c]=g.useState(!0);return g.useEffect(()=>{let d=!0;return c(!!e),(async()=>{if(e){const u=await e();d&&(i(()=>u),c(!1))}})(),()=>{d=!1,o.current.preserveValue||i(()=>r.current)}},[e]),[s,l]},mm=Ni(a.jsx("path",{d:"M3 18h18v-2H3zm0-5h18v-2H3zm0-7v2h18V6z"}),"Menu");function qi({menuProvider:e,normalMenu:t,fullMenu:n,commandHandler:r,containerRef:o,className:s,ariaLabelPrefix:i,children:l}){const[c,d]=g.useState(!1),[u,m]=g.useState(!1),w=g.useCallback(()=>{c&&d(!1),m(!1)},[c]),b=g.useCallback(E=>{E.stopPropagation(),d(v=>{const P=!v;return P&&E.shiftKey?m(!0):P||m(!1),P})},[]),x=g.useCallback(E=>(w(),r(E)),[r,w]),[f,h]=g.useState({top:1,left:1});g.useEffect(()=>{if(c){const E=o==null?void 0:o.current;if(E){const v=E.getBoundingClientRect(),P=window.scrollY,V=window.scrollX,U=v.top+P+E.clientHeight,T=v.left+V;h({top:U,left:T})}}},[c,o]);const[S]=tr(g.useCallback(async()=>(e==null?void 0:e(!1))??t,[e,t,c]),t),[R]=tr(g.useCallback(async()=>(e==null?void 0:e(!0))??n??S,[e,n,S,c]),n??S),j=u&&R?R:S;return a.jsxs(a.Fragment,{children:[a.jsx(Te.IconButton,{sx:{paddingTop:0,paddingBottom:0},edge:"start",className:`papi-menuButton ${s??""}`,color:"inherit","aria-label":`${i??""} menu button`,onClick:b,children:l??a.jsx(mm,{})}),a.jsx(Te.Drawer,{className:`papi-menu-drawer ${s??""}`,anchor:"left",variant:"temporary",open:c,onClose:w,PaperProps:{className:"papi-menu-drawer-paper",style:{top:f.top,left:f.left}},children:j?a.jsx(Ui,{className:s,id:`${i??""} main menu`,commandHandler:x,multiColumnMenu:j}):void 0})]})}function hm({id:e,label:t,isDisabled:n=!1,tooltip:r,isTooltipSuppressed:o=!1,adjustMarginToAlignToEdge:s=!1,size:i="medium",className:l,onClick:c,children:d}){return a.jsx(Te.IconButton,{id:e,disabled:n,edge:s,size:i,"aria-label":t,title:o?void 0:r??t,className:`papi-icon-button ${l??""}`,onClick:c,children:d})}const Kt=g.forwardRef(({className:e,...t},n)=>a.jsx(Q.LoaderCircle,{size:35,className:N("tw-animate-spin",e),...t,ref:n}));Kt.displayName="Spinner";function gm({id:e,isDisabled:t=!1,hasError:n=!1,isFullWidth:r=!1,helperText:o,label:s,placeholder:i,isRequired:l=!1,className:c,defaultValue:d,value:u,onChange:m,onFocus:w,onBlur:b}){return a.jsxs("div",{className:N("tw-inline-grid tw-items-center tw-gap-1.5",{"tw-w-full":r}),children:[a.jsx(qe,{htmlFor:e,className:N({"tw-text-red-600":n,"tw-hidden":!s}),children:`${s}${l?"*":""}`}),a.jsx(St,{id:e,disabled:t,placeholder:i,required:l,className:N(c,{"tw-border-red-600":n}),defaultValue:d,value:u,onChange:m,onFocus:w,onBlur:b}),a.jsx("p",{className:N({"tw-hidden":!o}),children:o})]})}function bm({menuProvider:e,commandHandler:t,className:n,id:r,children:o}){const s=g.useRef(void 0);return a.jsx("div",{ref:s,style:{position:"relative"},children:a.jsx(Te.AppBar,{position:"static",id:r,children:a.jsxs(Te.Toolbar,{className:N("tw-bg-muted tw-text-muted-foreground",n),variant:"dense",children:[e?a.jsx(qi,{commandHandler:t,containerRef:s,menuProvider:e}):void 0,o?a.jsx("div",{className:"papi-toolbar-children",children:o}):void 0]})})})}const vm=Xt.cva("tw-relative tw-w-full tw-rounded-lg tw-border tw-p-4 [&>svg~*]:tw-pl-7 [&>svg+div]:tw-translate-y-[-3px] [&>svg]:tw-absolute [&>svg]:tw-left-4 [&>svg]:tw-top-4 [&>svg]:tw-text-foreground",{variants:{variant:{default:"tw-bg-background tw-text-foreground",destructive:"tw-border-destructive/50 tw-text-destructive dark:tw-border-destructive [&>svg]:tw-text-destructive"}},defaultVariants:{variant:"default"}}),Hi=g.forwardRef(({className:e,variant:t,...n},r)=>a.jsx("div",{ref:r,role:"alert",className:N(vm({variant:t}),e),...n}));Hi.displayName="Alert";const Xi=g.forwardRef(({className:e,...t},n)=>a.jsxs("h5",{ref:n,className:N("tw-mb-1 tw-font-medium tw-leading-none tw-tracking-tight",e),...t,children:[t.children," "]}));Xi.displayName="AlertTitle";const Yi=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,className:N("tw-text-sm [&_p]:tw-leading-relaxed",e),...t}));Yi.displayName="AlertDescription";function xm({...e}){return a.jsx(Qa.Toaster,{className:"tw-toaster tw-group",toastOptions:{classNames:{toast:"group toast group-[.toaster]:bg-background group-[.toaster]:text-foreground group-[.toaster]:border-border group-[.toaster]:shadow-lg",description:"group-[.toast]:text-muted-foreground",actionButton:"group-[.toast]:bg-primary group-[.toast]:text-primary-foreground",cancelButton:"group-[.toast]:bg-muted group-[.toast]:text-muted-foreground"}},...e})}const Wi=g.forwardRef(({className:e,...t},n)=>a.jsxs(cn.Root,{ref:n,className:N("pr-twp tw-relative tw-flex tw-w-full tw-touch-none tw-select-none tw-items-center",e),...t,children:[a.jsx(cn.Track,{className:"tw-relative tw-h-2 tw-w-full tw-grow tw-overflow-hidden tw-rounded-full tw-bg-secondary",children:a.jsx(cn.Range,{className:"tw-absolute tw-h-full tw-bg-primary"})}),a.jsx(cn.Thumb,{className:"tw-block tw-h-5 tw-w-5 tw-rounded-full tw-border-2 tw-border-primary tw-bg-background tw-ring-offset-background tw-transition-colors focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50"})]}));Wi.displayName=cn.Root.displayName;const Ki=g.forwardRef(({className:e,...t},n)=>a.jsx(Ur.Root,{className:N("tw-peer pr-twp tw-inline-flex tw-h-6 tw-w-11 tw-shrink-0 tw-cursor-pointer tw-items-center tw-rounded-full tw-border-2 tw-border-transparent tw-transition-colors focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 focus-visible:tw-ring-offset-background disabled:tw-cursor-not-allowed disabled:tw-opacity-50 data-[state=checked]:tw-bg-primary data-[state=unchecked]:tw-bg-input",e),...t,ref:n,children:a.jsx(Ur.Thumb,{className:N("pr-twp tw-pointer-events-none tw-block tw-h-5 tw-w-5 tw-rounded-full tw-bg-background tw-shadow-lg tw-ring-0 tw-transition-transform data-[state=checked]:tw-translate-x-5 data-[state=unchecked]:tw-translate-x-0")})}));Ki.displayName=Ur.Root.displayName;const ym=_e.Root,Ji=g.forwardRef(({className:e,...t},n)=>a.jsx(_e.List,{ref:n,className:N("tw-inline-flex tw-h-10 tw-items-center tw-justify-center tw-rounded-md tw-bg-muted tw-p-1 tw-text-muted-foreground",e),...t}));Ji.displayName=_e.List.displayName;const Zi=g.forwardRef(({className:e,...t},n)=>a.jsx(_e.Trigger,{ref:n,className:N("tw-inline-flex tw-items-center tw-justify-center tw-whitespace-nowrap tw-rounded-sm tw-px-3 tw-py-1.5 tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-all hover:tw-text-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50 data-[state=active]:tw-bg-background data-[state=active]:tw-text-foreground data-[state=active]:tw-shadow-sm",e),...t}));Zi.displayName=_e.Trigger.displayName;const Qi=g.forwardRef(({className:e,...t},n)=>a.jsx(_e.Content,{ref:n,className:N("tw-mt-2 tw-ring-offset-background focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2",e),...t}));Qi.displayName=_e.Content.displayName;function Nm({isInstalling:e,handleClick:t,buttonText:n,className:r,...o}){return a.jsx(fe,{className:N("tw-h-8 tw-rounded-md tw-text-white tw-transition tw-duration-300 tw-ease-in-out hover:tw-bg-blue-700",{"tw-cursor-not-allowed tw-bg-blue-700":e,"tw-bg-blue-600":!e,"tw-bg-white tw-text-blue-600 hover:tw-text-white":!n,"tw-w-20":n},r),onClick:t,...o,children:e?a.jsx(Kt,{size:15}):a.jsxs(a.Fragment,{children:[a.jsx(Q.Download,{size:25,className:N("tw-h-4 tw-w-4",{"tw-mr-1":n})}),n]})})}function km({isEnabling:e,handleClick:t,className:n,...r}){return a.jsx(fe,{className:N("tw-h-8 tw-rounded-md tw-bg-blue-600 tw-px-4 tw-text-white tw-transition tw-duration-300 tw-ease-in-out hover:tw-bg-blue-700",{"tw-cursor-not-allowed tw-bg-blue-700":e},n),onClick:t,...r,children:e?a.jsxs(a.Fragment,{children:[a.jsx(Kt,{size:15,className:"tw-mr-1 tw-text-white"}),"Enabling..."]}):"Enable"})}function Sm({isDisabling:e,handleClick:t,className:n,...r}){return a.jsx(fe,{className:N("tw-h-8 tw-rounded-md tw-bg-gray-300 tw-text-black tw-transition tw-duration-300 tw-ease-in-out hover:tw-bg-gray-400",{"tw-cursor-not-allowed tw-bg-gray-400":e},n),onClick:t,...r,children:e?a.jsxs(a.Fragment,{children:[a.jsx(Kt,{size:15,className:"tw-mr-1 tw-text-black"}),"Disabling..."]}):"Disable"})}function Em({isUpdating:e,handleClick:t,className:n,...r}){return a.jsx(fe,{className:N("tw-h-8 tw-rounded-md tw-bg-blue-600 tw-px-4 tw-text-white tw-transition tw-duration-300 tw-ease-in-out hover:tw-bg-blue-700 hover:tw-text-white",{"tw-cursor-not-allowed tw-bg-blue-700":e},n),onClick:t,...r,children:e?a.jsxs(a.Fragment,{children:[a.jsx(Kt,{size:15,className:"tw-mr-1 tw-text-white"}),"Updating..."]}):"Update"})}function jm({id:e,markdown:t,className:n,anchorTarget:r}){const o=g.useMemo(()=>({overrides:{a:{props:{target:r}}}}),[r]);return a.jsx("div",{id:e,className:N("pr-twp tw-prose",n),children:a.jsx(Rl,{options:o,children:t})})}const el=g.forwardRef((e,t)=>a.jsxs(fe,{ref:t,className:"tw-rounded-md tw-border tw-border-dashed tw-border-gray-400 tw-bg-white tw-px-4 tw-py-2 tw-text-black tw-transition tw-duration-300 tw-ease-in-out hover:tw-border-blue-600 hover:tw-bg-white hover:tw-text-blue-600",...e,children:[a.jsx(Q.Filter,{size:16,className:"tw-mr-2 tw-h-4 tw-w-4 tw-text-gray-700 hover:tw-text-blue-600"}),"Filter",a.jsx(Q.ChevronDown,{size:16,className:"tw-ml-2 tw-h-4 tw-w-4 tw-text-gray-700 hover:tw-text-blue-600"})]}));var tl=(e=>(e[e.Check=0]="Check",e[e.Radio=1]="Radio",e))(tl||{});function Tm({id:e,groups:t}){return a.jsx("div",{id:e,children:a.jsxs(rr,{children:[a.jsx(ao,{asChild:!0,children:a.jsx(el,{})}),a.jsx(En,{children:t.map(n=>a.jsxs("div",{children:[a.jsx(Wt,{children:n.label}),a.jsx(cs,{children:n.items.map(r=>a.jsx("div",{children:r.itemType===0?a.jsx(or,{onClick:r.onClick,children:r.label}):a.jsx(io,{onClick:r.onClick,value:r.label,children:r.label})},r.label))}),a.jsx(jn,{})]},n.label))})]})})}function Cm({id:e,message:t}){return a.jsx("div",{id:e,className:"tw-mb-20 tw-mt-20 tw-flex tw-items-center tw-justify-center",children:a.jsx("div",{className:"tw-w-3/4 tw-rounded-lg tw-bg-gray-100 tw-p-8 tw-text-center",children:a.jsx("p",{className:"tw-text-lg tw-text-gray-800",children:t})})})}function Rm({id:e,category:t,downloads:n,languages:r,moreInfoUrl:o}){const s=new W.NumberFormat("en",{notation:"compact",compactDisplay:"short"}).format(Object.values(n).reduce((l,c)=>l+c,0)),i=()=>{window.scrollTo(0,document.body.scrollHeight)};return a.jsxs("div",{id:e,className:"tw-flex tw-flex-wrap tw-items-start tw-space-x-4 tw-border-b tw-border-t tw-bg-white tw-pb-4 tw-pt-4",children:[a.jsxs("div",{className:"tw-flex tw-flex-col tw-items-center",children:[a.jsx("div",{className:"tw-flex tw-items-center tw-rounded-md tw-bg-gray-100 tw-px-2 tw-py-1",children:a.jsx("span",{className:"tw-text-xs tw-font-semibold tw-text-gray-700",children:t})}),a.jsx("span",{className:"tw-text-xs tw-text-gray-500",children:"CATEGORY"})]}),a.jsx("div",{className:"tw-mx-2 tw-h-10 tw-border-l tw-border-gray-300"}),a.jsxs("div",{className:"tw-flex tw-flex-col tw-items-center",children:[a.jsxs("div",{className:"tw-flex tw-items-center tw-rounded-md tw-bg-gray-100 tw-px-2 tw-py-1",children:[a.jsx(Q.User,{className:"tw-mr-1 tw-h-4 tw-w-4"}),a.jsx("span",{className:"tw-text-xs tw-font-semibold tw-text-gray-700",children:s})]}),a.jsx("span",{className:"tw-text-xs tw-text-gray-500",children:"USERS"})]}),a.jsx("div",{className:"tw-mx-2 tw-h-10 tw-border-l tw-border-gray-300"}),a.jsxs("div",{className:"tw-flex tw-flex-col tw-items-center",children:[a.jsx("div",{className:"tw-flex tw-items-center",children:r.slice(0,3).map(l=>a.jsx("span",{className:"tw-ml-1 tw-rounded-md tw-bg-gray-100 tw-px-2 tw-py-1 tw-text-xs tw-font-semibold tw-text-gray-700",children:l.toUpperCase()},l))}),r.length>3&&a.jsxs("button",{type:"button",onClick:()=>i(),className:"tw-text-xs tw-text-gray-500 tw-underline",children:["+",r.length-3," more languages"]})]}),a.jsx("div",{className:"tw-mx-2 tw-h-10 tw-border-l tw-border-gray-300"}),a.jsxs("div",{className:"tw-ml-auto tw-flex tw-flex-col tw-space-y-2",children:[a.jsxs("a",{href:o,target:"_blank",rel:"noreferrer",className:"tw-flex tw-items-center tw-text-xs tw-font-semibold tw-text-gray-500 tw-underline",children:["Website",a.jsx(Q.Link,{className:"tw-ml-1 tw-inline tw-h-4 tw-w-4"})]}),a.jsxs("a",{href:"https://example.com",target:"_blank",rel:"noreferrer",className:"tw-flex tw-items-center tw-text-xs tw-font-semibold tw-text-gray-500 tw-underline",children:["Support",a.jsx(Q.CircleHelp,{className:"tw-ml-1 tw-inline tw-h-4 tw-w-4"})]})]})]})}function nl({id:e,versionHistory:t}){const[n,r]=g.useState(!1),o=new Date;function s(l){const c=new Date(l),d=new Date(o.getTime()-c.getTime()),u=d.getUTCFullYear()-1970,m=d.getUTCMonth(),w=d.getUTCDate()-1;let b="";return u>0?b=`${u.toString()} year${u===1?"":"s"} ago`:m>0?b=`${m.toString()} month${m===1?"":"s"} ago`:w===0?b="today":b=`${w.toString()} day${w===1?"":"s"} ago`,b}const i=Object.entries(t).sort((l,c)=>c[0].localeCompare(l[0]));return a.jsxs("div",{id:e,children:[a.jsx("h3",{className:"tw-text-md tw-font-semibold",children:"What`s New"}),a.jsx("ul",{className:"tw-list-disc tw-pl-5 tw-pr-4 tw-text-xs tw-text-gray-600",children:(n?i:i.slice(0,5)).map(l=>a.jsxs("div",{className:"tw-mt-3 tw-flex tw-justify-between",children:[a.jsx("div",{className:"tw-text-gray-600",children:a.jsx("li",{className:"tw-prose tw-text-xs",children:a.jsx("span",{children:l[1].description})})}),a.jsxs("div",{className:"tw-justify-end tw-text-right",children:[a.jsxs("div",{children:["Version ",l[0]]}),a.jsx("div",{children:s(l[1].date)})]})]},l[0]))}),i.length>5&&a.jsx("button",{type:"button",onClick:()=>r(!n),className:"tw-text-xs tw-text-gray-500 tw-underline",children:n?"Show Less Version History":"Show All Version History"})]})}function Om({id:e,publisherDisplayName:t,fileSize:n,locales:r,versionHistory:o}){const s=g.useMemo(()=>W.formatBytes(n),[n]),l=(c=>{const d=new Intl.DisplayNames(navigator.language,{type:"language"});return c.map(u=>d.of(u))})(r);return a.jsx("div",{id:e,className:"tw-border-t tw-pb-4 tw-pt-4",children:a.jsxs("div",{className:"tw-md:flex-row tw-md:space-x-8 tw-flex tw-flex-col tw-space-x-0",children:[a.jsx(nl,{versionHistory:o}),a.jsx("div",{className:"tw-md:border-t-0 tw-md:border-l tw-md-h-auto tw-md-ml-8 tw-mt-4 tw-border-t tw-border-gray-300"}),a.jsxs("div",{className:"tw-md:mt-0 tw-mt-4 tw-flex-1 tw-space-y-3",children:[a.jsx("h2",{className:"tw-text-md tw-font-semibold",children:"Information"}),a.jsxs("div",{className:"tw-flex tw-items-start tw-justify-between tw-pr-4 tw-text-xs tw-text-gray-600",children:[a.jsxs("p",{className:"tw-flex tw-flex-col tw-justify-start",children:[a.jsx("span",{className:"tw-mb-2",children:"Publisher"}),a.jsx("span",{className:"tw-font-semibold",children:t}),a.jsx("span",{className:"tw-mb-2 tw-mt-4",children:"Size"}),a.jsx("span",{className:"tw-font-semibold",children:s})]}),a.jsx("div",{className:"tw-flex tw-w-3/4 tw-items-center tw-justify-between tw-text-xs tw-text-gray-600",children:a.jsxs("p",{className:"tw-flex tw-flex-col tw-justify-start",children:[a.jsx("span",{className:"tw-mb-2",children:"Languages"}),a.jsx("span",{className:"tw-font-semibold",children:l.join(", ")})]})})]})]})]})})}const _m=(e,t)=>{g.useEffect(()=>{if(!e)return()=>{};const n=e(t);return()=>{n()}},[e,t])},Lr=()=>!1,Pm=(e,t)=>{const[n]=tr(g.useCallback(async()=>{if(!e)return Lr;const r=await Promise.resolve(e(t));return async()=>r()},[t,e]),Lr,{preserveValue:!1});g.useEffect(()=>()=>{n!==Lr&&n()},[n])};Object.defineProperty(exports,"sonner",{enumerable:!0,get:()=>Qa.toast});exports.Alert=Hi;exports.AlertDescription=Yi;exports.AlertTitle=Xi;exports.BOOK_SELECTOR_STRING_KEYS=mc;exports.BookChapterControl=oc;exports.BookSelectionMode=Ns;exports.BookSelector=hc;exports.Button=fe;exports.Card=ho;exports.CardContent=Zs;exports.CardDescription=vo;exports.CardFooter=Qs;exports.CardHeader=go;exports.CardTitle=bo;exports.ChapterRangeSelector=ys;exports.Checkbox=ar;exports.Checklist=vd;exports.ComboBox=qr;exports.DataTable=Cs;exports.DisableButton=Sm;exports.DropdownMenu=rr;exports.DropdownMenuCheckboxItem=or;exports.DropdownMenuContent=En;exports.DropdownMenuGroup=cs;exports.DropdownMenuItem=so;exports.DropdownMenuItemType=tl;exports.DropdownMenuLabel=Wt;exports.DropdownMenuPortal=ql;exports.DropdownMenuRadioGroup=Xl;exports.DropdownMenuRadioItem=io;exports.DropdownMenuSeparator=jn;exports.DropdownMenuShortcut=ps;exports.DropdownMenuSub=Hl;exports.DropdownMenuSubContent=us;exports.DropdownMenuSubTrigger=ds;exports.DropdownMenuTrigger=ao;exports.EnableButton=km;exports.FilterButton=el;exports.FilterDropdown=Tm;exports.Footer=Om;exports.GridMenu=Ui;exports.HamburgerMenuButton=qi;exports.INVENTORY_STRING_KEYS=Ec;exports.IconButton=hm;exports.Input=St;exports.InstallButton=Nm;exports.Inventory=Cc;exports.Label=qe;exports.MarkdownRenderer=jm;exports.MenuItem=Fo;exports.MoreInfo=Rm;exports.NavigationContentSearch=Rc;exports.NoExtensionsFound=Cm;exports.RadioGroup=lo;exports.RadioGroupItem=Yn;exports.ScriptureResultsViewer=wd;exports.ScrollGroupSelector=fd;exports.SearchBar=Ms;exports.Select=At;exports.SelectContent=vt;exports.SelectGroup=ks;exports.SelectItem=Ae;exports.SelectLabel=Ss;exports.SelectScrollDownButton=uo;exports.SelectScrollUpButton=co;exports.SelectSeparator=Es;exports.SelectTrigger=bt;exports.SelectValue=Bt;exports.Separator=ir;exports.SettingsCard=bd;exports.SettingsList=md;exports.SettingsListHeader=gd;exports.SettingsListItem=hd;exports.SettingsSidebar=Ks;exports.SettingsSidebarContentSearch=ad;exports.Slider=Wi;exports.Sonner=xm;exports.Spinner=Kt;exports.Switch=Ki;exports.Table=Tn;exports.TableBody=Rn;exports.TableCaption=Ts;exports.TableCell=xt;exports.TableFooter=js;exports.TableHead=Vt;exports.TableHeader=Cn;exports.TableRow=Ze;exports.Tabs=ym;exports.TabsContent=Qi;exports.TabsList=Ji;exports.TabsTrigger=Zi;exports.TextField=gm;exports.ToggleGroup=po;exports.ToggleGroupItem=fn;exports.Toolbar=bm;exports.UpdateButton=Em;exports.VersionHistory=nl;exports.VerticalTabs=wo;exports.VerticalTabsContent=mo;exports.VerticalTabsList=fo;exports.VerticalTabsTrigger=$s;exports.buttonVariants=ws;exports.cn=N;exports.getBookNumFromId=Os;exports.getLinesFromUSFM=Rs;exports.getNumberFromUSFM=Hr;exports.getStatusForItem=_s;exports.inventoryCountColumn=kc;exports.inventoryItemColumn=yc;exports.inventoryStatusColumn=Sc;exports.useEvent=_m;exports.useEventAsync=Pm;exports.usePromise=tr;function Im(e,t="top"){if(!e||typeof document>"u")return;const n=document.head||document.querySelector("head"),r=n.querySelector(":first-child"),o=document.createElement("style");o.appendChild(document.createTextNode(e)),t==="top"&&r?n.insertBefore(o,r):n.appendChild(o)}Im(`*, ::before, ::after { +`))}return null}),children:p.oneOfType([p.node,p.func]),container:p.oneOfType([xn,p.func]),direction:p.oneOf(["ltr","rtl"]),disablePortal:p.bool,keepMounted:p.bool,modifiers:p.arrayOf(p.shape({data:p.object,effect:p.func,enabled:p.bool,fn:p.func,name:p.any,options:p.object,phase:p.oneOf(["afterMain","afterRead","afterWrite","beforeMain","beforeRead","beforeWrite","main","read","write"]),requires:p.arrayOf(p.string),requiresIfExists:p.arrayOf(p.string)})),open:p.bool.isRequired,placement:p.oneOf(["auto-end","auto-start","auto","bottom-end","bottom-start","bottom","left-end","left-start","left","right-end","right-start","right","top-end","top-start","top"]),popperOptions:p.shape({modifiers:p.array,onFirstUpdate:p.func,placement:p.oneOf(["auto-end","auto-start","auto","bottom-end","bottom-start","bottom","left-end","left-start","left","right-end","right-start","right","top-end","top-start","top"]),strategy:p.oneOf(["absolute","fixed"])}),popperRef:li,slotProps:p.shape({root:p.oneOfType([p.func,p.object])}),slots:p.shape({root:p.elementType}),transition:p.bool});function Ai(){const e=xi(Io);return process.env.NODE_ENV!=="production"&&M.useDebugValue(e),e[Mo]||e}function no(e,t){return no=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,o){return r.__proto__=o,r},no(e,t)}function Hf(e,t){e.prototype=Object.create(t.prototype),e.prototype.constructor=e,no(e,t)}const Ka={disabled:!1};var Xf=process.env.NODE_ENV!=="production"?p.oneOfType([p.number,p.shape({enter:p.number,exit:p.number,appear:p.number}).isRequired]):null;process.env.NODE_ENV!=="production"&&p.oneOfType([p.string,p.shape({enter:p.string,exit:p.string,active:p.string}),p.shape({enter:p.string,enterDone:p.string,enterActive:p.string,exit:p.string,exitDone:p.string,exitActive:p.string})]);const Bi=g.createContext(null);var Yf=function(t){return t.scrollTop},pn="unmounted",wt="exited",ft="entering",$t="entered",ro="exiting",nt=function(e){Hf(t,e);function t(r,o){var s;s=e.call(this,r,o)||this;var i=o,l=i&&!i.isMounting?r.enter:r.appear,c;return s.appearStatus=null,r.in?l?(c=wt,s.appearStatus=ft):c=$t:r.unmountOnExit||r.mountOnEnter?c=pn:c=wt,s.state={status:c},s.nextCallback=null,s}t.getDerivedStateFromProps=function(o,s){var i=o.in;return i&&s.status===pn?{status:wt}:null};var n=t.prototype;return n.componentDidMount=function(){this.updateStatus(!0,this.appearStatus)},n.componentDidUpdate=function(o){var s=null;if(o!==this.props){var i=this.state.status;this.props.in?i!==ft&&i!==$t&&(s=ft):(i===ft||i===$t)&&(s=ro)}this.updateStatus(!1,s)},n.componentWillUnmount=function(){this.cancelNextCallback()},n.getTimeouts=function(){var o=this.props.timeout,s,i,l;return s=i=l=o,o!=null&&typeof o!="number"&&(s=o.exit,i=o.enter,l=o.appear!==void 0?o.appear:i),{exit:s,enter:i,appear:l}},n.updateStatus=function(o,s){if(o===void 0&&(o=!1),s!==null)if(this.cancelNextCallback(),s===ft){if(this.props.unmountOnExit||this.props.mountOnEnter){var i=this.props.nodeRef?this.props.nodeRef.current:ln.findDOMNode(this);i&&Yf(i)}this.performEnter(o)}else this.performExit();else this.props.unmountOnExit&&this.state.status===wt&&this.setState({status:pn})},n.performEnter=function(o){var s=this,i=this.props.enter,l=this.context?this.context.isMounting:o,c=this.props.nodeRef?[l]:[ln.findDOMNode(this),l],d=c[0],u=c[1],h=this.getTimeouts(),w=l?h.appear:h.enter;if(!o&&!i||Ka.disabled){this.safeSetState({status:$t},function(){s.props.onEntered(d)});return}this.props.onEnter(d,u),this.safeSetState({status:ft},function(){s.props.onEntering(d,u),s.onTransitionEnd(w,function(){s.safeSetState({status:$t},function(){s.props.onEntered(d,u)})})})},n.performExit=function(){var o=this,s=this.props.exit,i=this.getTimeouts(),l=this.props.nodeRef?void 0:ln.findDOMNode(this);if(!s||Ka.disabled){this.safeSetState({status:wt},function(){o.props.onExited(l)});return}this.props.onExit(l),this.safeSetState({status:ro},function(){o.props.onExiting(l),o.onTransitionEnd(i.exit,function(){o.safeSetState({status:wt},function(){o.props.onExited(l)})})})},n.cancelNextCallback=function(){this.nextCallback!==null&&(this.nextCallback.cancel(),this.nextCallback=null)},n.safeSetState=function(o,s){s=this.setNextCallback(s),this.setState(o,s)},n.setNextCallback=function(o){var s=this,i=!0;return this.nextCallback=function(l){i&&(i=!1,s.nextCallback=null,o(l))},this.nextCallback.cancel=function(){i=!1},this.nextCallback},n.onTransitionEnd=function(o,s){this.setNextCallback(s);var i=this.props.nodeRef?this.props.nodeRef.current:ln.findDOMNode(this),l=o==null&&!this.props.addEndListener;if(!i||l){setTimeout(this.nextCallback,0);return}if(this.props.addEndListener){var c=this.props.nodeRef?[this.nextCallback]:[i,this.nextCallback],d=c[0],u=c[1];this.props.addEndListener(d,u)}o!=null&&setTimeout(this.nextCallback,o)},n.render=function(){var o=this.state.status;if(o===pn)return null;var s=this.props,i=s.children;s.in,s.mountOnEnter,s.unmountOnExit,s.appear,s.enter,s.exit,s.timeout,s.addEndListener,s.onEnter,s.onEntering,s.onEntered,s.onExit,s.onExiting,s.onExited,s.nodeRef;var l=Ne(s,["children","in","mountOnEnter","unmountOnExit","appear","enter","exit","timeout","addEndListener","onEnter","onEntering","onEntered","onExit","onExiting","onExited","nodeRef"]);return g.createElement(Bi.Provider,{value:null},typeof i=="function"?i(o,l):g.cloneElement(g.Children.only(i),l))},t}(g.Component);nt.contextType=Bi;nt.propTypes=process.env.NODE_ENV!=="production"?{nodeRef:p.shape({current:typeof Element>"u"?p.any:function(e,t,n,r,o,s){var i=e[t];return p.instanceOf(i&&"ownerDocument"in i?i.ownerDocument.defaultView.Element:Element)(e,t,n,r,o,s)}}),children:p.oneOfType([p.func.isRequired,p.element.isRequired]).isRequired,in:p.bool,mountOnEnter:p.bool,unmountOnExit:p.bool,appear:p.bool,enter:p.bool,exit:p.bool,timeout:function(t){var n=Xf;t.addEndListener||(n=n.isRequired);for(var r=arguments.length,o=new Array(r>1?r-1:0),s=1;se.scrollTop;function Ja(e,t){var n,r;const{timeout:o,easing:s,style:i={}}=e;return{duration:(n=i.transitionDuration)!=null?n:typeof o=="number"?o:o[t.mode]||0,easing:(r=i.transitionTimingFunction)!=null?r:typeof s=="object"?s[t.mode]:s,delay:i.transitionDelay}}const Jf=["addEndListener","appear","children","easing","in","onEnter","onEntered","onEntering","onExit","onExited","onExiting","style","timeout","TransitionComponent"];function oo(e){return`scale(${e}, ${e**2})`}const Zf={entering:{opacity:1,transform:oo(1)},entered:{opacity:1,transform:"none"}},Lr=typeof navigator<"u"&&/^((?!chrome|android).)*(safari|mobile)/i.test(navigator.userAgent)&&/(os |version\/)15(.|_)4/i.test(navigator.userAgent),Uo=M.forwardRef(function(t,n){const{addEndListener:r,appear:o=!0,children:s,easing:i,in:l,onEnter:c,onEntered:d,onEntering:u,onExit:h,onExited:w,onExiting:b,style:x,timeout:f="auto",TransitionComponent:m=Wf}=t,S=Ne(t,Jf),R=dn(),j=M.useRef(),E=Ai(),v=M.useRef(null),P=yt(v,s.ref,n),V=Y=>F=>{if(Y){const te=v.current;F===void 0?Y(te):Y(te,F)}},U=V(u),C=V((Y,F)=>{Kf(Y);const{duration:te,delay:se,easing:oe}=Ja({style:x,timeout:f,easing:i},{mode:"enter"});let y;f==="auto"?(y=E.transitions.getAutoHeightDuration(Y.clientHeight),j.current=y):y=te,Y.style.transition=[E.transitions.create("opacity",{duration:y,delay:se}),E.transitions.create("transform",{duration:Lr?y:y*.666,delay:se,easing:oe})].join(","),c&&c(Y,F)}),_=V(d),k=V(b),D=V(Y=>{const{duration:F,delay:te,easing:se}=Ja({style:x,timeout:f,easing:i},{mode:"exit"});let oe;f==="auto"?(oe=E.transitions.getAutoHeightDuration(Y.clientHeight),j.current=oe):oe=F,Y.style.transition=[E.transitions.create("opacity",{duration:oe,delay:te}),E.transitions.create("transform",{duration:Lr?oe:oe*.666,delay:Lr?te:te||oe*.333,easing:se})].join(","),Y.style.opacity=0,Y.style.transform=oo(.75),h&&h(Y)}),$=V(w),J=Y=>{f==="auto"&&R.start(j.current||0,Y),r&&r(v.current,Y)};return a.jsx(m,O({appear:o,in:l,nodeRef:v,onEnter:C,onEntered:_,onEntering:U,onExit:D,onExited:$,onExiting:k,addEndListener:J,timeout:f==="auto"?null:f},S,{children:(Y,F)=>M.cloneElement(s,O({style:O({opacity:0,transform:oo(.75),visibility:Y==="exited"&&!l?"hidden":void 0},Zf[Y],x,s.props.style),ref:P},F))}))});process.env.NODE_ENV!=="production"&&(Uo.propTypes={addEndListener:p.func,appear:p.bool,children:si.isRequired,easing:p.oneOfType([p.shape({enter:p.string,exit:p.string}),p.string]),in:p.bool,onEnter:p.func,onEntered:p.func,onEntering:p.func,onExit:p.func,onExited:p.func,onExiting:p.func,style:p.object,timeout:p.oneOfType([p.oneOf(["auto"]),p.number,p.shape({appear:p.number,enter:p.number,exit:p.number})])});Uo.muiSupportAuto=!0;const Za=Uo,Qf=["anchorEl","component","components","componentsProps","container","disablePortal","keepMounted","modifiers","open","placement","popperOptions","popperRef","transition","slots","slotProps"],em=In(Di,{name:"MuiPopper",slot:"Root",overridesResolver:(e,t)=>t.root})({}),Vi=M.forwardRef(function(t,n){var r;const o=vi(),s=$o({props:t,name:"MuiPopper"}),{anchorEl:i,component:l,components:c,componentsProps:d,container:u,disablePortal:h,keepMounted:w,modifiers:b,open:x,placement:f,popperOptions:m,popperRef:S,transition:R,slots:j,slotProps:E}=s,v=Ne(s,Qf),P=(r=j==null?void 0:j.root)!=null?r:c==null?void 0:c.Root,V=O({anchorEl:i,container:u,disablePortal:h,keepMounted:w,modifiers:b,open:x,placement:f,popperOptions:m,popperRef:S,transition:R},v);return a.jsx(em,O({as:l,direction:o==null?void 0:o.direction,slots:{root:P},slotProps:E??d},V,{ref:n}))});process.env.NODE_ENV!=="production"&&(Vi.propTypes={anchorEl:p.oneOfType([xn,p.object,p.func]),children:p.oneOfType([p.node,p.func]),component:p.elementType,components:p.shape({Root:p.elementType}),componentsProps:p.shape({root:p.oneOfType([p.func,p.object])}),container:p.oneOfType([xn,p.func]),disablePortal:p.bool,keepMounted:p.bool,modifiers:p.arrayOf(p.shape({data:p.object,effect:p.func,enabled:p.bool,fn:p.func,name:p.any,options:p.object,phase:p.oneOf(["afterMain","afterRead","afterWrite","beforeMain","beforeRead","beforeWrite","main","read","write"]),requires:p.arrayOf(p.string),requiresIfExists:p.arrayOf(p.string)})),open:p.bool.isRequired,placement:p.oneOf(["auto-end","auto-start","auto","bottom-end","bottom-start","bottom","left-end","left-start","left","right-end","right-start","right","top-end","top-start","top"]),popperOptions:p.shape({modifiers:p.array,onFirstUpdate:p.func,placement:p.oneOf(["auto-end","auto-start","auto","bottom-end","bottom-start","bottom","left-end","left-start","left","right-end","right-start","right","top-end","top-start","top"]),strategy:p.oneOf(["absolute","fixed"])}),popperRef:li,slotProps:p.shape({root:p.oneOfType([p.func,p.object])}),slots:p.shape({root:p.elementType}),sx:p.oneOfType([p.arrayOf(p.oneOfType([p.func,p.object,p.bool])),p.func,p.object]),transition:p.bool});const zi=Vi;function tm(e){return ur("MuiTooltip",e)}const nm=mi("MuiTooltip",["popper","popperInteractive","popperArrow","popperClose","tooltip","tooltipArrow","touch","tooltipPlacementLeft","tooltipPlacementRight","tooltipPlacementTop","tooltipPlacementBottom","arrow"]),at=nm,rm=["arrow","children","classes","components","componentsProps","describeChild","disableFocusListener","disableHoverListener","disableInteractive","disableTouchListener","enterDelay","enterNextDelay","enterTouchDelay","followCursor","id","leaveDelay","leaveTouchDelay","onClose","onOpen","open","placement","PopperComponent","PopperProps","slotProps","slots","title","TransitionComponent","TransitionProps"];function om(e){return Math.round(e*1e5)/1e5}const am=e=>{const{classes:t,disableInteractive:n,arrow:r,touch:o,placement:s}=e,i={popper:["popper",!n&&"popperInteractive",r&&"popperArrow"],tooltip:["tooltip",r&&"tooltipArrow",o&&"touch",`tooltipPlacement${Ye(s.split("-")[0])}`],arrow:["arrow"]};return jo(i,tm,t)},sm=In(zi,{name:"MuiTooltip",slot:"Popper",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.popper,!n.disableInteractive&&t.popperInteractive,n.arrow&&t.popperArrow,!n.open&&t.popperClose]}})(({theme:e,ownerState:t,open:n})=>O({zIndex:(e.vars||e).zIndex.tooltip,pointerEvents:"none"},!t.disableInteractive&&{pointerEvents:"auto"},!n&&{pointerEvents:"none"},t.arrow&&{[`&[data-popper-placement*="bottom"] .${at.arrow}`]:{top:0,marginTop:"-0.71em","&::before":{transformOrigin:"0 100%"}},[`&[data-popper-placement*="top"] .${at.arrow}`]:{bottom:0,marginBottom:"-0.71em","&::before":{transformOrigin:"100% 0"}},[`&[data-popper-placement*="right"] .${at.arrow}`]:O({},t.isRtl?{right:0,marginRight:"-0.71em"}:{left:0,marginLeft:"-0.71em"},{height:"1em",width:"0.71em","&::before":{transformOrigin:"100% 100%"}}),[`&[data-popper-placement*="left"] .${at.arrow}`]:O({},t.isRtl?{left:0,marginLeft:"-0.71em"}:{right:0,marginRight:"-0.71em"},{height:"1em",width:"0.71em","&::before":{transformOrigin:"0 0"}})})),im=In("div",{name:"MuiTooltip",slot:"Tooltip",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.tooltip,n.touch&&t.touch,n.arrow&&t.tooltipArrow,t[`tooltipPlacement${Ye(n.placement.split("-")[0])}`]]}})(({theme:e,ownerState:t})=>O({backgroundColor:e.vars?e.vars.palette.Tooltip.bg:yi(e.palette.grey[700],.92),borderRadius:(e.vars||e).shape.borderRadius,color:(e.vars||e).palette.common.white,fontFamily:e.typography.fontFamily,padding:"4px 8px",fontSize:e.typography.pxToRem(11),maxWidth:300,margin:2,wordWrap:"break-word",fontWeight:e.typography.fontWeightMedium},t.arrow&&{position:"relative",margin:0},t.touch&&{padding:"8px 16px",fontSize:e.typography.pxToRem(14),lineHeight:`${om(16/14)}em`,fontWeight:e.typography.fontWeightRegular},{[`.${at.popper}[data-popper-placement*="left"] &`]:O({transformOrigin:"right center"},t.isRtl?O({marginLeft:"14px"},t.touch&&{marginLeft:"24px"}):O({marginRight:"14px"},t.touch&&{marginRight:"24px"})),[`.${at.popper}[data-popper-placement*="right"] &`]:O({transformOrigin:"left center"},t.isRtl?O({marginRight:"14px"},t.touch&&{marginRight:"24px"}):O({marginLeft:"14px"},t.touch&&{marginLeft:"24px"})),[`.${at.popper}[data-popper-placement*="top"] &`]:O({transformOrigin:"center bottom",marginBottom:"14px"},t.touch&&{marginBottom:"24px"}),[`.${at.popper}[data-popper-placement*="bottom"] &`]:O({transformOrigin:"center top",marginTop:"14px"},t.touch&&{marginTop:"24px"})})),lm=In("span",{name:"MuiTooltip",slot:"Arrow",overridesResolver:(e,t)=>t.arrow})(({theme:e})=>({overflow:"hidden",position:"absolute",width:"1em",height:"0.71em",boxSizing:"border-box",color:e.vars?e.vars.palette.Tooltip.bg:yi(e.palette.grey[700],.9),"&::before":{content:'""',margin:"auto",display:"block",width:"100%",height:"100%",backgroundColor:"currentColor",transform:"rotate(45deg)"}}));let Gn=!1;const Qa=new On;let sn={x:0,y:0};function Un(e,t){return n=>{t&&t(n),e(n)}}const Li=M.forwardRef(function(t,n){var r,o,s,i,l,c,d,u,h,w,b,x,f,m,S,R,j,E,v;const P=$o({props:t,name:"MuiTooltip"}),{arrow:V=!1,children:U,components:C={},componentsProps:_={},describeChild:k=!1,disableFocusListener:D=!1,disableHoverListener:$=!1,disableInteractive:J=!1,disableTouchListener:Y=!1,enterDelay:F=100,enterNextDelay:te=0,enterTouchDelay:se=700,followCursor:oe=!1,id:y,leaveDelay:T=0,leaveTouchDelay:z=1500,onClose:L,onOpen:B,open:X,placement:q="bottom",PopperComponent:H,PopperProps:G={},slotProps:K={},slots:Z={},title:ue,TransitionComponent:I=Za,TransitionProps:ye}=P,A=Ne(P,rm),xe=M.isValidElement(U)?U:a.jsx("span",{children:U}),Ge=Ai(),lt=Ge.direction==="rtl",[Ee,Dn]=M.useState(),[Ue,Et]=M.useState(null),ct=M.useRef(!1),jt=J||oe,Ct=dn(),Tt=dn(),dt=dn(),Jt=dn(),[An,Ho]=di({controlled:X,default:!1,name:"Tooltip",state:"open"});let Ke=An;if(process.env.NODE_ENV!=="production"){const{current:ee}=M.useRef(X!==void 0);M.useEffect(()=>{Ee&&Ee.disabled&&!ee&&ue!==""&&Ee.tagName.toLowerCase()==="button"&&console.error(["MUI: You are providing a disabled `button` child to the Tooltip component.","A disabled element does not fire events.","Tooltip needs to listen to the child element's events to display the title.","","Add a simple wrapper element, such as a `span`."].join(` +`))},[ue,Ee,ee])}const kr=ci(y),Zt=M.useRef(),Bn=Zr(()=>{Zt.current!==void 0&&(document.body.style.WebkitUserSelect=Zt.current,Zt.current=void 0),Jt.clear()});M.useEffect(()=>Bn,[Bn]);const Xo=ee=>{Qa.clear(),Gn=!0,Ho(!0),B&&!Ke&&B(ee)},Vn=Zr(ee=>{Qa.start(800+T,()=>{Gn=!1}),Ho(!1),L&&Ke&&L(ee),Ct.start(Ge.transitions.duration.shortest,()=>{ct.current=!1})}),Sr=ee=>{ct.current&&ee.type!=="touchstart"||(Ee&&Ee.removeAttribute("title"),Tt.clear(),dt.clear(),F||Gn&&te?Tt.start(Gn?te:F,()=>{Xo(ee)}):Xo(ee))},Yo=ee=>{Tt.clear(),dt.start(T,()=>{Vn(ee)})},{isFocusVisibleRef:Wo,onBlur:rl,onFocus:ol,ref:al}=ui(),[,Ko]=M.useState(!1),Jo=ee=>{rl(ee),Wo.current===!1&&(Ko(!1),Yo(ee))},Zo=ee=>{Ee||Dn(ee.currentTarget),ol(ee),Wo.current===!0&&(Ko(!0),Sr(ee))},Qo=ee=>{ct.current=!0;const Pe=xe.props;Pe.onTouchStart&&Pe.onTouchStart(ee)},ea=Sr,ta=Yo,sl=ee=>{Qo(ee),dt.clear(),Ct.clear(),Bn(),Zt.current=document.body.style.WebkitUserSelect,document.body.style.WebkitUserSelect="none",Jt.start(se,()=>{document.body.style.WebkitUserSelect=Zt.current,Sr(ee)})},il=ee=>{xe.props.onTouchEnd&&xe.props.onTouchEnd(ee),Bn(),dt.start(z,()=>{Vn(ee)})};M.useEffect(()=>{if(!Ke)return;function ee(Pe){(Pe.key==="Escape"||Pe.key==="Esc")&&Vn(Pe)}return document.addEventListener("keydown",ee),()=>{document.removeEventListener("keydown",ee)}},[Vn,Ke]);const ll=yt(xe.ref,al,Dn,n);!ue&&ue!==0&&(Ke=!1);const Er=M.useRef(),cl=ee=>{const Pe=xe.props;Pe.onMouseMove&&Pe.onMouseMove(ee),sn={x:ee.clientX,y:ee.clientY},Er.current&&Er.current.update()},Qt={},jr=typeof ue=="string";k?(Qt.title=!Ke&&jr&&!$?ue:null,Qt["aria-describedby"]=Ke?kr:null):(Qt["aria-label"]=jr?ue:null,Qt["aria-labelledby"]=Ke&&!jr?kr:null);const De=O({},Qt,A,xe.props,{className:ot(A.className,xe.props.className),onTouchStart:Qo,ref:ll},oe?{onMouseMove:cl}:{});process.env.NODE_ENV!=="production"&&(De["data-mui-internal-clone-element"]=!0,M.useEffect(()=>{Ee&&!Ee.getAttribute("data-mui-internal-clone-element")&&console.error(["MUI: The `children` component of the Tooltip is not forwarding its props correctly.","Please make sure that props are spread on the same element that the ref is applied to."].join(` +`))},[Ee]));const en={};Y||(De.onTouchStart=sl,De.onTouchEnd=il),$||(De.onMouseOver=Un(ea,De.onMouseOver),De.onMouseLeave=Un(ta,De.onMouseLeave),jt||(en.onMouseOver=ea,en.onMouseLeave=ta)),D||(De.onFocus=Un(Zo,De.onFocus),De.onBlur=Un(Jo,De.onBlur),jt||(en.onFocus=Zo,en.onBlur=Jo)),process.env.NODE_ENV!=="production"&&xe.props.title&&console.error(["MUI: You have provided a `title` prop to the child of .",`Remove this title prop \`${xe.props.title}\` or the Tooltip component.`].join(` +`));const dl=M.useMemo(()=>{var ee;let Pe=[{name:"arrow",enabled:!!Ue,options:{element:Ue,padding:4}}];return(ee=G.popperOptions)!=null&&ee.modifiers&&(Pe=Pe.concat(G.popperOptions.modifiers)),O({},G.popperOptions,{modifiers:Pe})},[Ue,G]),tn=O({},P,{isRtl:lt,arrow:V,disableInteractive:jt,placement:q,PopperComponentProp:H,touch:ct.current}),Cr=am(tn),na=(r=(o=Z.popper)!=null?o:C.Popper)!=null?r:sm,ra=(s=(i=(l=Z.transition)!=null?l:C.Transition)!=null?i:I)!=null?s:Za,oa=(c=(d=Z.tooltip)!=null?d:C.Tooltip)!=null?c:im,aa=(u=(h=Z.arrow)!=null?h:C.Arrow)!=null?u:lm,ul=un(na,O({},G,(w=K.popper)!=null?w:_.popper,{className:ot(Cr.popper,G==null?void 0:G.className,(b=(x=K.popper)!=null?x:_.popper)==null?void 0:b.className)}),tn),pl=un(ra,O({},ye,(f=K.transition)!=null?f:_.transition),tn),wl=un(oa,O({},(m=K.tooltip)!=null?m:_.tooltip,{className:ot(Cr.tooltip,(S=(R=K.tooltip)!=null?R:_.tooltip)==null?void 0:S.className)}),tn),fl=un(aa,O({},(j=K.arrow)!=null?j:_.arrow,{className:ot(Cr.arrow,(E=(v=K.arrow)!=null?v:_.arrow)==null?void 0:E.className)}),tn);return a.jsxs(M.Fragment,{children:[M.cloneElement(xe,De),a.jsx(na,O({as:H??zi,placement:q,anchorEl:oe?{getBoundingClientRect:()=>({top:sn.y,left:sn.x,right:sn.x,bottom:sn.y,width:0,height:0})}:Ee,popperRef:Er,open:Ee?Ke:!1,id:kr,transition:!0},en,ul,{popperOptions:dl,children:({TransitionProps:ee})=>a.jsx(ra,O({timeout:Ge.transitions.duration.shorter},ee,pl,{children:a.jsxs(oa,O({},wl,{children:[ue,V?a.jsx(aa,O({},fl,{ref:Et})):null]}))}))}))]})});process.env.NODE_ENV!=="production"&&(Li.propTypes={arrow:p.bool,children:si.isRequired,classes:p.object,className:p.string,components:p.shape({Arrow:p.elementType,Popper:p.elementType,Tooltip:p.elementType,Transition:p.elementType}),componentsProps:p.shape({arrow:p.object,popper:p.object,tooltip:p.object,transition:p.object}),describeChild:p.bool,disableFocusListener:p.bool,disableHoverListener:p.bool,disableInteractive:p.bool,disableTouchListener:p.bool,enterDelay:p.number,enterNextDelay:p.number,enterTouchDelay:p.number,followCursor:p.bool,id:p.string,leaveDelay:p.number,leaveTouchDelay:p.number,onClose:p.func,onOpen:p.func,open:p.bool,placement:p.oneOf(["bottom-end","bottom-start","bottom","left-end","left-start","left","right-end","right-start","right","top-end","top-start","top"]),PopperComponent:p.elementType,PopperProps:p.object,slotProps:p.shape({arrow:p.object,popper:p.object,tooltip:p.object,transition:p.object}),slots:p.shape({arrow:p.elementType,popper:p.elementType,tooltip:p.elementType,transition:p.elementType}),sx:p.oneOfType([p.arrayOf(p.oneOfType([p.func,p.object,p.bool])),p.func,p.object]),title:p.node,TransitionComponent:p.elementType,TransitionProps:p.object});const cm=Li;function es(e,t,n){return e?a.jsx(Ce.ListItemIcon,{className:`papi-menu-icon-${n?"leading":"trailing"}`,children:a.jsx("img",{src:e,alt:`${n?"Leading":"Trailing"} icon for ${t}`})}):void 0}function qo(e){const{onClick:t,label:n,tooltip:r,allowForLeadingIcons:o=!0,iconPathBefore:s=void 0,iconPathAfter:i=void 0,hasAutoFocus:l=!1,className:c,isDisabled:d=!1,isDense:u=!0,isSubMenuParent:h=!1,hasDisabledGutters:w=!1,hasDivider:b=!1,focusVisibleClassName:x,id:f,children:m}=e,S=a.jsx(Ce.MenuItem,{sx:{lineHeight:.8},autoFocus:l,className:c,disabled:d,dense:u,disableGutters:w,divider:b,focusVisibleClassName:x,onClick:t,id:f,children:n?a.jsxs(a.Fragment,{children:[es(s,n,!0),a.jsx(Ce.ListItemText,{primary:n,inset:!s&&o}),h?a.jsx(Ce.ListItemIcon,{className:"papi-menu-icon-trailing",children:a.jsx(ki,{})}):es(i,n,!1)]}):m});return r?a.jsx(cm,{title:r,placement:"right",children:a.jsx("div",{children:S})}):S}function Fi(e){return Object.entries(e.groups).map(([n,r])=>({id:n,group:r}))}function dm(e){const[t,n]=g.useState(void 0),{parentMenuItem:r,parentItemProps:o,menuDefinition:s}=e,i=d=>{n(d.currentTarget)},l=()=>{n(void 0)},c=()=>{let d=Fi(s).filter(u=>"menuItem"in u.group);if(!(r!=null&&r.id))throw new Error("A valid parent menu item is required for submenus.");return d=d.filter(u=>"menuItem"in u.group&&u.group.menuItem===r.id),a.jsx(Gi,{...e,includedGroups:d})};return a.jsxs(a.Fragment,{children:[a.jsx(qo,{onClick:i,...o,isSubMenuParent:!0}),a.jsx(Ce.Menu,{anchorEl:t,open:!!t,onClose:l,anchorOrigin:{vertical:"top",horizontal:"right"},transformOrigin:{vertical:"top",horizontal:"left"},children:c()},r.id)]})}const um=(e,t)=>t.filter(o=>o.group===e).sort((o,s)=>(o.order||0)-(s.order||0));function Gi(e){const{menuDefinition:t,onClick:n,commandHandler:r,includedGroups:o}=e,{items:s,allowForLeadingIcons:i}=g.useMemo(()=>{const u=o&&o.length>0?o:Fi(t).filter(x=>!("menuItem"in x.group)),h=Object.values(u).sort((x,f)=>(x.group.order||0)-(f.group.order||0)),w=[];h.forEach(x=>{um(x.id,t.items).forEach(f=>w.push({item:f,isLastItemInGroup:!1})),w.length>0&&(w[w.length-1].isLastItemInGroup=!0)}),w.length>0&&(w[w.length-1].isLastItemInGroup=!1);const b=w.some(x=>"iconPathBefore"in x.item&&x.item.iconPathBefore);return{items:w,allowForLeadingIcons:b}},[o,t]),l=({item:u,isLastItemInGroup:h})=>({className:"papi-menu-item",label:u.label,tooltip:u.tooltip,iconPathBefore:"iconPathBefore"in u?u.iconPathBefore:void 0,iconPathAfter:"iconPathAfter"in u?u.iconPathAfter:void 0,hasDivider:h,allowForLeadingIcons:i}),[c]=s;if(!c)return a.jsx("div",{});const d=c.item.group;return a.jsx("div",{role:"menu","aria-label":d,children:s.map((u,h)=>{const{item:w}=u,b=l(u);if("command"in w){const x=w.group+h;return a.jsx(qo,{onClick:f=>{n==null||n(f),r(w)},...b},x)}return a.jsx(dm,{parentMenuItem:w,parentItemProps:b,...e},d+w.id)})},d)}function pm(e){const{menuDefinition:t,columnId:n}=e;let s=Object.entries(t.groups).map(([i,l])=>({id:i,group:l})).filter(i=>"column"in i.group);return n&&"columns"in t&&t.columns[n]&&(s=s.filter(i=>"column"in i.group&&i.group.column===n)),a.jsx(Gi,{...e,includedGroups:s})}function wm({commandHandler:e,menuDefinition:t,id:n,metadata:r,onClick:o,className:s}){return a.jsxs(Ce.Grid,{id:n,item:!0,xs:"auto",role:"menu","aria-label":n,className:`papi-menu-column ${s??""}`,children:[a.jsx("h3",{"aria-label":r.label,className:`papi-menu-column-header ${s??""}`,children:r.label}),a.jsx(Ce.List,{id:n,dense:!0,className:s??"",children:a.jsx(pm,{commandHandler:e,menuDefinition:t,columnId:n,onClick:o})})]})}function Ui({commandHandler:e,className:t,multiColumnMenu:n,id:r}){const{columns:o}=n,s=g.useMemo(()=>{const i=new Map;return Object.getOwnPropertyNames(o).forEach(l=>{if(l==="isExtensible")return;const c=l,d=o[c];typeof d=="object"&&typeof d.order=="number"&&!Number.isNaN(d.order)?i.set(d.order,{id:c,metadata:d}):console.warn(`Property ${l} (${typeof d}) on menu ${r} is not a valid column and is being ignored. This might indicate data corruption`)}),Array.from(i.values()).sort((l,c)=>(l.metadata.order||0)-(c.metadata.order||0))},[o,r]);return a.jsx(Ce.Grid,{container:!0,spacing:0,className:`papi-multi-column-menu ${t??""}`,columns:s.length,role:"menu","aria-label":"GridMenu",id:r,children:s.map((i,l)=>a.jsx(wm,{commandHandler:e,menuDefinition:n,...i,className:t},l))})}function fm(e){return{preserveValue:!0,...e}}const nr=(e,t,n={})=>{const r=g.useRef(t);r.current=t;const o=g.useRef(n);o.current=fm(o.current);const[s,i]=g.useState(()=>r.current),[l,c]=g.useState(!0);return g.useEffect(()=>{let d=!0;return c(!!e),(async()=>{if(e){const u=await e();d&&(i(()=>u),c(!1))}})(),()=>{d=!1,o.current.preserveValue||i(()=>r.current)}},[e]),[s,l]},mm=Ni(a.jsx("path",{d:"M3 18h18v-2H3zm0-5h18v-2H3zm0-7v2h18V6z"}),"Menu");function qi({menuProvider:e,normalMenu:t,fullMenu:n,commandHandler:r,containerRef:o,className:s,ariaLabelPrefix:i,children:l}){const[c,d]=g.useState(!1),[u,h]=g.useState(!1),w=g.useCallback(()=>{c&&d(!1),h(!1)},[c]),b=g.useCallback(E=>{E.stopPropagation(),d(v=>{const P=!v;return P&&E.shiftKey?h(!0):P||h(!1),P})},[]),x=g.useCallback(E=>(w(),r(E)),[r,w]),[f,m]=g.useState({top:1,left:1});g.useEffect(()=>{if(c){const E=o==null?void 0:o.current;if(E){const v=E.getBoundingClientRect(),P=window.scrollY,V=window.scrollX,U=v.top+P+E.clientHeight,C=v.left+V;m({top:U,left:C})}}},[c,o]);const[S]=nr(g.useCallback(async()=>(e==null?void 0:e(!1))??t,[e,t,c]),t),[R]=nr(g.useCallback(async()=>(e==null?void 0:e(!0))??n??S,[e,n,S,c]),n??S),j=u&&R?R:S;return a.jsxs(a.Fragment,{children:[a.jsx(Ce.IconButton,{sx:{paddingTop:0,paddingBottom:0},edge:"start",className:`papi-menuButton ${s??""}`,color:"inherit","aria-label":`${i??""} menu button`,onClick:b,children:l??a.jsx(mm,{})}),a.jsx(Ce.Drawer,{className:`papi-menu-drawer ${s??""}`,anchor:"left",variant:"temporary",open:c,onClose:w,PaperProps:{className:"papi-menu-drawer-paper",style:{top:f.top,left:f.left}},children:j?a.jsx(Ui,{className:s,id:`${i??""} main menu`,commandHandler:x,multiColumnMenu:j}):void 0})]})}function hm({id:e,label:t,isDisabled:n=!1,tooltip:r,isTooltipSuppressed:o=!1,adjustMarginToAlignToEdge:s=!1,size:i="medium",className:l,onClick:c,children:d}){return a.jsx(Ce.IconButton,{id:e,disabled:n,edge:s,size:i,"aria-label":t,title:o?void 0:r??t,className:`papi-icon-button ${l??""}`,onClick:c,children:d})}const Kt=g.forwardRef(({className:e,...t},n)=>a.jsx(Q.LoaderCircle,{size:35,className:N("tw-animate-spin",e),...t,ref:n}));Kt.displayName="Spinner";function gm({id:e,isDisabled:t=!1,hasError:n=!1,isFullWidth:r=!1,helperText:o,label:s,placeholder:i,isRequired:l=!1,className:c,defaultValue:d,value:u,onChange:h,onFocus:w,onBlur:b}){return a.jsxs("div",{className:N("tw-inline-grid tw-items-center tw-gap-1.5",{"tw-w-full":r}),children:[a.jsx(qe,{htmlFor:e,className:N({"tw-text-red-600":n,"tw-hidden":!s}),children:`${s}${l?"*":""}`}),a.jsx(St,{id:e,disabled:t,placeholder:i,required:l,className:N(c,{"tw-border-red-600":n}),defaultValue:d,value:u,onChange:h,onFocus:w,onBlur:b}),a.jsx("p",{className:N({"tw-hidden":!o}),children:o})]})}function bm({menuProvider:e,commandHandler:t,className:n,id:r,children:o}){const s=g.useRef(void 0);return a.jsx("div",{ref:s,style:{position:"relative"},children:a.jsx(Ce.AppBar,{position:"static",id:r,children:a.jsxs(Ce.Toolbar,{className:N("tw-bg-muted tw-text-muted-foreground",n),variant:"dense",children:[e?a.jsx(qi,{commandHandler:t,containerRef:s,menuProvider:e}):void 0,o?a.jsx("div",{className:"papi-toolbar-children",children:o}):void 0]})})})}const vm=Xt.cva("tw-relative tw-w-full tw-rounded-lg tw-border tw-p-4 [&>svg~*]:tw-pl-7 [&>svg+div]:tw-translate-y-[-3px] [&>svg]:tw-absolute [&>svg]:tw-left-4 [&>svg]:tw-top-4 [&>svg]:tw-text-foreground",{variants:{variant:{default:"tw-bg-background tw-text-foreground",destructive:"tw-border-destructive/50 tw-text-destructive dark:tw-border-destructive [&>svg]:tw-text-destructive"}},defaultVariants:{variant:"default"}}),Hi=g.forwardRef(({className:e,variant:t,...n},r)=>a.jsx("div",{ref:r,role:"alert",className:N(vm({variant:t}),e),...n}));Hi.displayName="Alert";const Xi=g.forwardRef(({className:e,...t},n)=>a.jsxs("h5",{ref:n,className:N("tw-mb-1 tw-font-medium tw-leading-none tw-tracking-tight",e),...t,children:[t.children," "]}));Xi.displayName="AlertTitle";const Yi=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,className:N("tw-text-sm [&_p]:tw-leading-relaxed",e),...t}));Yi.displayName="AlertDescription";function xm({...e}){return a.jsx(ns.Toaster,{className:"tw-toaster tw-group",toastOptions:{classNames:{toast:"group toast group-[.toaster]:bg-background group-[.toaster]:text-foreground group-[.toaster]:border-border group-[.toaster]:shadow-lg",description:"group-[.toast]:text-muted-foreground",actionButton:"group-[.toast]:bg-primary group-[.toast]:text-primary-foreground",cancelButton:"group-[.toast]:bg-muted group-[.toast]:text-muted-foreground"}},...e})}const Wi=g.forwardRef(({className:e,...t},n)=>a.jsxs(cn.Root,{ref:n,className:N("pr-twp tw-relative tw-flex tw-w-full tw-touch-none tw-select-none tw-items-center",e),...t,children:[a.jsx(cn.Track,{className:"tw-relative tw-h-2 tw-w-full tw-grow tw-overflow-hidden tw-rounded-full tw-bg-secondary",children:a.jsx(cn.Range,{className:"tw-absolute tw-h-full tw-bg-primary"})}),a.jsx(cn.Thumb,{className:"tw-block tw-h-5 tw-w-5 tw-rounded-full tw-border-2 tw-border-primary tw-bg-background tw-ring-offset-background tw-transition-colors focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50"})]}));Wi.displayName=cn.Root.displayName;const Ki=g.forwardRef(({className:e,...t},n)=>a.jsx(qr.Root,{className:N("tw-peer pr-twp tw-inline-flex tw-h-6 tw-w-11 tw-shrink-0 tw-cursor-pointer tw-items-center tw-rounded-full tw-border-2 tw-border-transparent tw-transition-colors focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 focus-visible:tw-ring-offset-background disabled:tw-cursor-not-allowed disabled:tw-opacity-50 data-[state=checked]:tw-bg-primary data-[state=unchecked]:tw-bg-input",e),...t,ref:n,children:a.jsx(qr.Thumb,{className:N("pr-twp tw-pointer-events-none tw-block tw-h-5 tw-w-5 tw-rounded-full tw-bg-background tw-shadow-lg tw-ring-0 tw-transition-transform data-[state=checked]:tw-translate-x-5 data-[state=unchecked]:tw-translate-x-0")})}));Ki.displayName=qr.Root.displayName;const ym=_e.Root,Ji=g.forwardRef(({className:e,...t},n)=>a.jsx(_e.List,{ref:n,className:N("tw-inline-flex tw-h-10 tw-items-center tw-justify-center tw-rounded-md tw-bg-muted tw-p-1 tw-text-muted-foreground",e),...t}));Ji.displayName=_e.List.displayName;const Zi=g.forwardRef(({className:e,...t},n)=>a.jsx(_e.Trigger,{ref:n,className:N("tw-inline-flex tw-items-center tw-justify-center tw-whitespace-nowrap tw-rounded-sm tw-px-3 tw-py-1.5 tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-all hover:tw-text-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50 data-[state=active]:tw-bg-background data-[state=active]:tw-text-foreground data-[state=active]:tw-shadow-sm",e),...t}));Zi.displayName=_e.Trigger.displayName;const Qi=g.forwardRef(({className:e,...t},n)=>a.jsx(_e.Content,{ref:n,className:N("tw-mt-2 tw-ring-offset-background focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2",e),...t}));Qi.displayName=_e.Content.displayName;function Nm({isInstalling:e,handleClick:t,buttonText:n,className:r,...o}){return a.jsx(fe,{className:N("tw-h-8 tw-rounded-md tw-text-white tw-transition tw-duration-300 tw-ease-in-out hover:tw-bg-blue-700",{"tw-cursor-not-allowed tw-bg-blue-700":e,"tw-bg-blue-600":!e,"tw-bg-white tw-text-blue-600 hover:tw-text-white":!n,"tw-w-20":n},r),onClick:t,...o,children:e?a.jsx(Kt,{size:15}):a.jsxs(a.Fragment,{children:[a.jsx(Q.Download,{size:25,className:N("tw-h-4 tw-w-4",{"tw-mr-1":n})}),n]})})}function km({isEnabling:e,handleClick:t,className:n,...r}){return a.jsx(fe,{className:N("tw-h-8 tw-rounded-md tw-bg-blue-600 tw-px-4 tw-text-white tw-transition tw-duration-300 tw-ease-in-out hover:tw-bg-blue-700",{"tw-cursor-not-allowed tw-bg-blue-700":e},n),onClick:t,...r,children:e?a.jsxs(a.Fragment,{children:[a.jsx(Kt,{size:15,className:"tw-mr-1 tw-text-white"}),"Enabling..."]}):"Enable"})}function Sm({isDisabling:e,handleClick:t,className:n,...r}){return a.jsx(fe,{className:N("tw-h-8 tw-rounded-md tw-bg-gray-300 tw-text-black tw-transition tw-duration-300 tw-ease-in-out hover:tw-bg-gray-400",{"tw-cursor-not-allowed tw-bg-gray-400":e},n),onClick:t,...r,children:e?a.jsxs(a.Fragment,{children:[a.jsx(Kt,{size:15,className:"tw-mr-1 tw-text-black"}),"Disabling..."]}):"Disable"})}function Em({isUpdating:e,handleClick:t,className:n,...r}){return a.jsx(fe,{className:N("tw-h-8 tw-rounded-md tw-bg-blue-600 tw-px-4 tw-text-white tw-transition tw-duration-300 tw-ease-in-out hover:tw-bg-blue-700 hover:tw-text-white",{"tw-cursor-not-allowed tw-bg-blue-700":e},n),onClick:t,...r,children:e?a.jsxs(a.Fragment,{children:[a.jsx(Kt,{size:15,className:"tw-mr-1 tw-text-white"}),"Updating..."]}):"Update"})}function jm({id:e,markdown:t,className:n,anchorTarget:r}){const o=g.useMemo(()=>({overrides:{a:{props:{target:r}}}}),[r]);return a.jsx("div",{id:e,className:N("pr-twp tw-prose",n),children:a.jsx(Rl,{options:o,children:t})})}const el=g.forwardRef((e,t)=>a.jsxs(fe,{ref:t,className:"tw-rounded-md tw-border tw-border-dashed tw-border-gray-400 tw-bg-white tw-px-4 tw-py-2 tw-text-black tw-transition tw-duration-300 tw-ease-in-out hover:tw-border-blue-600 hover:tw-bg-white hover:tw-text-blue-600",...e,children:[a.jsx(Q.Filter,{size:16,className:"tw-mr-2 tw-h-4 tw-w-4 tw-text-gray-700 hover:tw-text-blue-600"}),"Filter",a.jsx(Q.ChevronDown,{size:16,className:"tw-ml-2 tw-h-4 tw-w-4 tw-text-gray-700 hover:tw-text-blue-600"})]}));var tl=(e=>(e[e.Check=0]="Check",e[e.Radio=1]="Radio",e))(tl||{});function Cm({id:e,groups:t}){return a.jsx("div",{id:e,children:a.jsxs(or,{children:[a.jsx(lo,{asChild:!0,children:a.jsx(el,{})}),a.jsx(En,{children:t.map(n=>a.jsxs("div",{children:[a.jsx(Wt,{children:n.label}),a.jsx(ps,{children:n.items.map(r=>a.jsx("div",{children:r.itemType===0?a.jsx(ar,{onClick:r.onClick,children:r.label}):a.jsx(uo,{onClick:r.onClick,value:r.label,children:r.label})},r.label))}),a.jsx(jn,{})]},n.label))})]})})}function Tm({id:e,message:t}){return a.jsx("div",{id:e,className:"tw-mb-20 tw-mt-20 tw-flex tw-items-center tw-justify-center",children:a.jsx("div",{className:"tw-w-3/4 tw-rounded-lg tw-bg-gray-100 tw-p-8 tw-text-center",children:a.jsx("p",{className:"tw-text-lg tw-text-gray-800",children:t})})})}function Rm({id:e,category:t,downloads:n,languages:r,moreInfoUrl:o}){const s=new W.NumberFormat("en",{notation:"compact",compactDisplay:"short"}).format(Object.values(n).reduce((l,c)=>l+c,0)),i=()=>{window.scrollTo(0,document.body.scrollHeight)};return a.jsxs("div",{id:e,className:"tw-flex tw-flex-wrap tw-items-start tw-space-x-4 tw-border-b tw-border-t tw-bg-white tw-pb-4 tw-pt-4",children:[a.jsxs("div",{className:"tw-flex tw-flex-col tw-items-center",children:[a.jsx("div",{className:"tw-flex tw-items-center tw-rounded-md tw-bg-gray-100 tw-px-2 tw-py-1",children:a.jsx("span",{className:"tw-text-xs tw-font-semibold tw-text-gray-700",children:t})}),a.jsx("span",{className:"tw-text-xs tw-text-gray-500",children:"CATEGORY"})]}),a.jsx("div",{className:"tw-mx-2 tw-h-10 tw-border-l tw-border-gray-300"}),a.jsxs("div",{className:"tw-flex tw-flex-col tw-items-center",children:[a.jsxs("div",{className:"tw-flex tw-items-center tw-rounded-md tw-bg-gray-100 tw-px-2 tw-py-1",children:[a.jsx(Q.User,{className:"tw-mr-1 tw-h-4 tw-w-4"}),a.jsx("span",{className:"tw-text-xs tw-font-semibold tw-text-gray-700",children:s})]}),a.jsx("span",{className:"tw-text-xs tw-text-gray-500",children:"USERS"})]}),a.jsx("div",{className:"tw-mx-2 tw-h-10 tw-border-l tw-border-gray-300"}),a.jsxs("div",{className:"tw-flex tw-flex-col tw-items-center",children:[a.jsx("div",{className:"tw-flex tw-items-center",children:r.slice(0,3).map(l=>a.jsx("span",{className:"tw-ml-1 tw-rounded-md tw-bg-gray-100 tw-px-2 tw-py-1 tw-text-xs tw-font-semibold tw-text-gray-700",children:l.toUpperCase()},l))}),r.length>3&&a.jsxs("button",{type:"button",onClick:()=>i(),className:"tw-text-xs tw-text-gray-500 tw-underline",children:["+",r.length-3," more languages"]})]}),a.jsx("div",{className:"tw-mx-2 tw-h-10 tw-border-l tw-border-gray-300"}),a.jsxs("div",{className:"tw-ml-auto tw-flex tw-flex-col tw-space-y-2",children:[a.jsxs("a",{href:o,target:"_blank",rel:"noreferrer",className:"tw-flex tw-items-center tw-text-xs tw-font-semibold tw-text-gray-500 tw-underline",children:["Website",a.jsx(Q.Link,{className:"tw-ml-1 tw-inline tw-h-4 tw-w-4"})]}),a.jsxs("a",{href:"https://example.com",target:"_blank",rel:"noreferrer",className:"tw-flex tw-items-center tw-text-xs tw-font-semibold tw-text-gray-500 tw-underline",children:["Support",a.jsx(Q.CircleHelp,{className:"tw-ml-1 tw-inline tw-h-4 tw-w-4"})]})]})]})}function nl({id:e,versionHistory:t}){const[n,r]=g.useState(!1),o=new Date;function s(l){const c=new Date(l),d=new Date(o.getTime()-c.getTime()),u=d.getUTCFullYear()-1970,h=d.getUTCMonth(),w=d.getUTCDate()-1;let b="";return u>0?b=`${u.toString()} year${u===1?"":"s"} ago`:h>0?b=`${h.toString()} month${h===1?"":"s"} ago`:w===0?b="today":b=`${w.toString()} day${w===1?"":"s"} ago`,b}const i=Object.entries(t).sort((l,c)=>c[0].localeCompare(l[0]));return a.jsxs("div",{id:e,children:[a.jsx("h3",{className:"tw-text-md tw-font-semibold",children:"What`s New"}),a.jsx("ul",{className:"tw-list-disc tw-pl-5 tw-pr-4 tw-text-xs tw-text-gray-600",children:(n?i:i.slice(0,5)).map(l=>a.jsxs("div",{className:"tw-mt-3 tw-flex tw-justify-between",children:[a.jsx("div",{className:"tw-text-gray-600",children:a.jsx("li",{className:"tw-prose tw-text-xs",children:a.jsx("span",{children:l[1].description})})}),a.jsxs("div",{className:"tw-justify-end tw-text-right",children:[a.jsxs("div",{children:["Version ",l[0]]}),a.jsx("div",{children:s(l[1].date)})]})]},l[0]))}),i.length>5&&a.jsx("button",{type:"button",onClick:()=>r(!n),className:"tw-text-xs tw-text-gray-500 tw-underline",children:n?"Show Less Version History":"Show All Version History"})]})}function Om({id:e,publisherDisplayName:t,fileSize:n,locales:r,versionHistory:o}){const s=g.useMemo(()=>W.formatBytes(n),[n]),l=(c=>{const d=new Intl.DisplayNames(navigator.language,{type:"language"});return c.map(u=>d.of(u))})(r);return a.jsx("div",{id:e,className:"tw-border-t tw-pb-4 tw-pt-4",children:a.jsxs("div",{className:"tw-md:flex-row tw-md:space-x-8 tw-flex tw-flex-col tw-space-x-0",children:[a.jsx(nl,{versionHistory:o}),a.jsx("div",{className:"tw-md:border-t-0 tw-md:border-l tw-md-h-auto tw-md-ml-8 tw-mt-4 tw-border-t tw-border-gray-300"}),a.jsxs("div",{className:"tw-md:mt-0 tw-mt-4 tw-flex-1 tw-space-y-3",children:[a.jsx("h2",{className:"tw-text-md tw-font-semibold",children:"Information"}),a.jsxs("div",{className:"tw-flex tw-items-start tw-justify-between tw-pr-4 tw-text-xs tw-text-gray-600",children:[a.jsxs("p",{className:"tw-flex tw-flex-col tw-justify-start",children:[a.jsx("span",{className:"tw-mb-2",children:"Publisher"}),a.jsx("span",{className:"tw-font-semibold",children:t}),a.jsx("span",{className:"tw-mb-2 tw-mt-4",children:"Size"}),a.jsx("span",{className:"tw-font-semibold",children:s})]}),a.jsx("div",{className:"tw-flex tw-w-3/4 tw-items-center tw-justify-between tw-text-xs tw-text-gray-600",children:a.jsxs("p",{className:"tw-flex tw-flex-col tw-justify-start",children:[a.jsx("span",{className:"tw-mb-2",children:"Languages"}),a.jsx("span",{className:"tw-font-semibold",children:l.join(", ")})]})})]})]})]})})}const _m=(e,t)=>{g.useEffect(()=>{if(!e)return()=>{};const n=e(t);return()=>{n()}},[e,t])},Fr=()=>!1,Pm=(e,t)=>{const[n]=nr(g.useCallback(async()=>{if(!e)return Fr;const r=await Promise.resolve(e(t));return async()=>r()},[t,e]),Fr,{preserveValue:!1});g.useEffect(()=>()=>{n!==Fr&&n()},[n])};Object.defineProperty(exports,"sonner",{enumerable:!0,get:()=>ns.toast});exports.Alert=Hi;exports.AlertDescription=Yi;exports.AlertTitle=Xi;exports.BOOK_SELECTOR_STRING_KEYS=mc;exports.BookChapterControl=oc;exports.BookSelectionMode=Es;exports.BookSelector=hc;exports.Button=fe;exports.Card=vo;exports.CardContent=Zs;exports.CardDescription=No;exports.CardFooter=Qs;exports.CardHeader=xo;exports.CardTitle=yo;exports.ChapterRangeSelector=Ss;exports.Checkbox=sr;exports.Checklist=vd;exports.ComboBox=Wn;exports.DataTable=_s;exports.DisableButton=Sm;exports.DropdownMenu=or;exports.DropdownMenuCheckboxItem=ar;exports.DropdownMenuContent=En;exports.DropdownMenuGroup=ps;exports.DropdownMenuItem=co;exports.DropdownMenuItemType=tl;exports.DropdownMenuLabel=Wt;exports.DropdownMenuPortal=ql;exports.DropdownMenuRadioGroup=Xl;exports.DropdownMenuRadioItem=uo;exports.DropdownMenuSeparator=jn;exports.DropdownMenuShortcut=ms;exports.DropdownMenuSub=Hl;exports.DropdownMenuSubContent=fs;exports.DropdownMenuSubTrigger=ws;exports.DropdownMenuTrigger=lo;exports.EnableButton=km;exports.FilterButton=el;exports.FilterDropdown=Cm;exports.Footer=Om;exports.GridMenu=Ui;exports.HamburgerMenuButton=qi;exports.INVENTORY_STRING_KEYS=Ec;exports.IconButton=hm;exports.Input=St;exports.InstallButton=Nm;exports.Inventory=Tc;exports.Label=qe;exports.MarkdownRenderer=jm;exports.MenuItem=qo;exports.MoreInfo=Rm;exports.NavigationContentSearch=Rc;exports.NoExtensionsFound=Tm;exports.RadioGroup=po;exports.RadioGroupItem=Yn;exports.ScriptureResultsViewer=wd;exports.ScrollGroupSelector=fd;exports.SearchBar=As;exports.Select=At;exports.SelectContent=vt;exports.SelectGroup=js;exports.SelectItem=Ae;exports.SelectLabel=Cs;exports.SelectScrollDownButton=fo;exports.SelectScrollUpButton=wo;exports.SelectSeparator=Ts;exports.SelectTrigger=bt;exports.SelectValue=Bt;exports.Separator=lr;exports.SettingsCard=bd;exports.SettingsList=md;exports.SettingsListHeader=gd;exports.SettingsListItem=hd;exports.SettingsSidebar=Ks;exports.SettingsSidebarContentSearch=ad;exports.Slider=Wi;exports.Sonner=xm;exports.Spinner=Kt;exports.Switch=Ki;exports.Table=Cn;exports.TableBody=Rn;exports.TableCaption=Os;exports.TableCell=xt;exports.TableFooter=Rs;exports.TableHead=Vt;exports.TableHeader=Tn;exports.TableRow=Ze;exports.Tabs=ym;exports.TabsContent=Qi;exports.TabsList=Ji;exports.TabsTrigger=Zi;exports.TextField=gm;exports.ToggleGroup=mo;exports.ToggleGroupItem=fn;exports.Toolbar=bm;exports.UpdateButton=Em;exports.VersionHistory=nl;exports.VerticalTabs=ho;exports.VerticalTabsContent=bo;exports.VerticalTabsList=go;exports.VerticalTabsTrigger=Bs;exports.buttonVariants=hs;exports.cn=N;exports.getBookNumFromId=Is;exports.getLinesFromUSFM=Ps;exports.getNumberFromUSFM=Hr;exports.getStatusForItem=Ms;exports.inventoryCountColumn=kc;exports.inventoryItemColumn=yc;exports.inventoryStatusColumn=Sc;exports.useEvent=_m;exports.useEventAsync=Pm;exports.usePromise=nr;function Im(e,t="top"){if(!e||typeof document>"u")return;const n=document.head||document.querySelector("head"),r=n.querySelector(":first-child"),o=document.createElement("style");o.appendChild(document.createTextNode(e)),t==="top"&&r?n.insertBefore(o,r):n.appendChild(o)}Im(`*, ::before, ::after { --tw-border-spacing-x: 0; --tw-border-spacing-y: 0; --tw-translate-x: 0; @@ -1208,6 +1208,9 @@ video:where(.pr-twp,.pr-twp *) { .tw-z-50 { z-index: 50; } +.tw-z-\\[1000\\] { + z-index: 1000; +} .tw-col-span-2 { grid-column: span 2 / span 2; } @@ -3540,12 +3543,31 @@ video:where(.pr-twp,.pr-twp *) { [data-side=right] .\\[\\[data-side\\=right\\]_\\&\\]\\:tw-cursor-e-resize { cursor: e-resize; } -.banded-row:hover { +.papi-icon-button { + border: 0; + border-radius: 3em; cursor: pointer; + display: inline-block; } -.banded-row[data-state='selected']:hover { - cursor: default; +.papi-icon-button.primary { + background-color: #1ea7fd; + color: white; +} + +.papi-icon-button.secondary { + background-color: transparent; + color: #333; +} + +.papi-icon-button.paratext { + background-color: darkgreen; + color: greenyellow; +} + +.papi-icon-button.paratext.bright { + background-color: greenyellow; + color: darkgreen; } .papi-multi-column-menu { background-color: rgb(222, 222, 222); @@ -3581,32 +3603,6 @@ video:where(.pr-twp,.pr-twp *) { color: rgb(76, 106, 76); background-color: rgb(214, 255, 152); } -.papi-icon-button { - border: 0; - border-radius: 3em; - cursor: pointer; - display: inline-block; -} - -.papi-icon-button.primary { - background-color: #1ea7fd; - color: white; -} - -.papi-icon-button.secondary { - background-color: transparent; - color: #333; -} - -.papi-icon-button.paratext { - background-color: darkgreen; - color: greenyellow; -} - -.papi-icon-button.paratext.bright { - background-color: greenyellow; - color: darkgreen; -} .papi-menu-item { background-color: transparent; } @@ -3620,6 +3616,13 @@ video:where(.pr-twp,.pr-twp *) { max-width: 24px; max-height: 24px; } +.banded-row:hover { + cursor: pointer; +} + +.banded-row[data-state='selected']:hover { + cursor: default; +} .papi-menu-drawer-paper { height: fit-content !important; position: absolute !important; diff --git a/lib/platform-bible-react/dist/index.cjs.map b/lib/platform-bible-react/dist/index.cjs.map index d7fc7fa0ed..271c73b6fd 100644 --- a/lib/platform-bible-react/dist/index.cjs.map +++ b/lib/platform-bible-react/dist/index.cjs.map @@ -1 +1 @@ -{"version":3,"file":"index.cjs","sources":["../src/utils/shadcn-ui.util.ts","../src/components/shadcn-ui/input.tsx","../src/components/advanced/book-chapter-control/book-chapter-input.component.tsx","../../../node_modules/@sillsdev/scripture/dist/index.es.js","../src/components/shadcn-ui/dropdown-menu.tsx","../src/components/advanced/book-chapter-control/book-menu-item.component.tsx","../src/components/advanced/book-chapter-control/chapter-select.component.tsx","../src/components/advanced/book-chapter-control/go-to-menu-item.component.tsx","../src/components/advanced/book-chapter-control/book-chapter-control.component.tsx","../src/components/shadcn-ui/button.tsx","../src/components/shadcn-ui/label.tsx","../src/components/shadcn-ui/radio-group.tsx","../src/components/shadcn-ui/popover.tsx","../src/components/shadcn-ui/dialog.tsx","../src/components/shadcn-ui/command.tsx","../src/components/basics/combo-box.component.tsx","../src/components/basics/chapter-range-selector.component.tsx","../src/components/advanced/book-selector.component.tsx","../src/components/advanced/data-table/data-table-column-toggle.component.tsx","../src/components/shadcn-ui/select.tsx","../src/components/advanced/data-table/data-table-pagination.component.tsx","../src/components/shadcn-ui/table.tsx","../src/components/advanced/data-table/data-table.component.tsx","../src/components/advanced/inventory/occurrences-table.component.tsx","../src/components/shadcn-ui/checkbox.tsx","../src/components/advanced/inventory/inventory-utils.ts","../src/components/shadcn-ui/toggle.tsx","../src/components/shadcn-ui/toggle-group.tsx","../src/components/advanced/inventory/inventory-columns.tsx","../src/components/advanced/inventory/inventory.component.tsx","../src/components/basics/search-bar.component.tsx","../src/components/basics/tabs-vertical.tsx","../src/components/advanced/tab-navigation-content-search.component.tsx","../src/components/shadcn-ui/separator.tsx","../src/components/shadcn-ui/sheet.tsx","../src/components/shadcn-ui/skeleton.tsx","../src/components/shadcn-ui/tooltip.tsx","../src/components/hooks/use-mobile.tsx","../src/components/shadcn-ui/sidebar.tsx","../src/components/advanced/settings-components/settings-sidebar.component.tsx","../src/components/advanced/settings-components/settings-sidebar-content-search.component.tsx","../src/components/advanced/scripture-results-viewer/scripture-results-viewer.component.tsx","../src/components/advanced/scroll-group-selector.component.tsx","../src/components/advanced/settings-components/settings-list.component.tsx","../src/components/shadcn-ui/card.tsx","../src/components/advanced/settings-components/settings-card.component.tsx","../src/components/basics/checklist.component.tsx","../../../node_modules/@babel/runtime/helpers/interopRequireDefault.js","../../../node_modules/@mui/utils/chainPropTypes/chainPropTypes.js","../../../node_modules/@babel/runtime/helpers/esm/extends.js","../../../node_modules/@mui/utils/deepmerge/deepmerge.js","../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.production.min.js","../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.development.js","../../../node_modules/prop-types/node_modules/react-is/index.js","../../../node_modules/object-assign/index.js","../../../node_modules/prop-types/lib/ReactPropTypesSecret.js","../../../node_modules/prop-types/lib/has.js","../../../node_modules/prop-types/checkPropTypes.js","../../../node_modules/prop-types/factoryWithTypeCheckers.js","../../../node_modules/prop-types/factoryWithThrowingShims.js","../../../node_modules/prop-types/index.js","../../../node_modules/@mui/utils/elementAcceptingRef/elementAcceptingRef.js","../../../node_modules/@mui/utils/exactProp/exactProp.js","../../../node_modules/@mui/utils/formatMuiErrorMessage/formatMuiErrorMessage.js","../../../node_modules/react-is/cjs/react-is.production.min.js","../../../node_modules/react-is/cjs/react-is.development.js","../../../node_modules/react-is/index.js","../../../node_modules/@mui/utils/getDisplayName/getDisplayName.js","../../../node_modules/@mui/utils/HTMLElementType/HTMLElementType.js","../../../node_modules/@mui/utils/refType/refType.js","../../../node_modules/@mui/utils/capitalize/capitalize.js","../../../node_modules/@mui/utils/createChainedFunction/createChainedFunction.js","../../../node_modules/@mui/utils/debounce/debounce.js","../../../node_modules/@mui/utils/deprecatedPropType/deprecatedPropType.js","../../../node_modules/@mui/utils/isMuiElement/isMuiElement.js","../../../node_modules/@mui/utils/ownerDocument/ownerDocument.js","../../../node_modules/@mui/utils/ownerWindow/ownerWindow.js","../../../node_modules/@mui/utils/requirePropFactory/requirePropFactory.js","../../../node_modules/@mui/utils/setRef/setRef.js","../../../node_modules/@mui/utils/useEnhancedEffect/useEnhancedEffect.js","../../../node_modules/@mui/utils/useId/useId.js","../../../node_modules/@mui/utils/unsupportedProp/unsupportedProp.js","../../../node_modules/@mui/utils/useControlled/useControlled.js","../../../node_modules/@mui/utils/useEventCallback/useEventCallback.js","../../../node_modules/@mui/utils/useForkRef/useForkRef.js","../../../node_modules/@mui/utils/useLazyRef/useLazyRef.js","../../../node_modules/@mui/utils/useOnMount/useOnMount.js","../../../node_modules/@mui/utils/useTimeout/useTimeout.js","../../../node_modules/@mui/utils/useIsFocusVisible/useIsFocusVisible.js","../../../node_modules/@mui/utils/resolveProps/resolveProps.js","../../../node_modules/@mui/utils/composeClasses/composeClasses.js","../../../node_modules/@mui/utils/ClassNameGenerator/ClassNameGenerator.js","../../../node_modules/@mui/utils/generateUtilityClass/generateUtilityClass.js","../../../node_modules/@mui/utils/generateUtilityClasses/generateUtilityClasses.js","../../../node_modules/@mui/utils/clamp/clamp.js","../../../node_modules/@babel/runtime/helpers/esm/objectWithoutPropertiesLoose.js","../../../node_modules/@mui/system/esm/createTheme/createBreakpoints.js","../../../node_modules/@mui/system/esm/createTheme/shape.js","../../../node_modules/@mui/system/esm/responsivePropType.js","../../../node_modules/@mui/system/esm/merge.js","../../../node_modules/@mui/system/esm/breakpoints.js","../../../node_modules/@mui/system/esm/style.js","../../../node_modules/@mui/system/esm/memoize.js","../../../node_modules/@mui/system/esm/spacing.js","../../../node_modules/@mui/system/esm/createTheme/createSpacing.js","../../../node_modules/@mui/system/esm/compose.js","../../../node_modules/@mui/system/esm/borders.js","../../../node_modules/@mui/system/esm/cssGrid.js","../../../node_modules/@mui/system/esm/palette.js","../../../node_modules/@mui/system/esm/sizing.js","../../../node_modules/@mui/system/esm/styleFunctionSx/defaultSxConfig.js","../../../node_modules/@mui/system/esm/styleFunctionSx/styleFunctionSx.js","../../../node_modules/@mui/system/esm/createTheme/applyStyles.js","../../../node_modules/@mui/system/esm/createTheme/createTheme.js","../../../node_modules/@mui/system/esm/useThemeWithoutDefault.js","../../../node_modules/@mui/system/esm/useTheme.js","../../../node_modules/@mui/system/esm/createStyled.js","../../../node_modules/@mui/system/esm/useThemeProps/getThemeProps.js","../../../node_modules/@mui/system/esm/useThemeProps/useThemeProps.js","../../../node_modules/@mui/system/esm/colorManipulator.js","../../../node_modules/@mui/material/styles/createMixins.js","../../../node_modules/@mui/material/colors/common.js","../../../node_modules/@mui/material/colors/grey.js","../../../node_modules/@mui/material/colors/purple.js","../../../node_modules/@mui/material/colors/red.js","../../../node_modules/@mui/material/colors/orange.js","../../../node_modules/@mui/material/colors/blue.js","../../../node_modules/@mui/material/colors/lightBlue.js","../../../node_modules/@mui/material/colors/green.js","../../../node_modules/@mui/material/styles/createPalette.js","../../../node_modules/@mui/material/styles/createTypography.js","../../../node_modules/@mui/material/styles/shadows.js","../../../node_modules/@mui/material/styles/createTransitions.js","../../../node_modules/@mui/material/styles/zIndex.js","../../../node_modules/@mui/material/styles/createTheme.js","../../../node_modules/@mui/material/styles/defaultTheme.js","../../../node_modules/@mui/material/styles/identifier.js","../../../node_modules/@mui/material/styles/useThemeProps.js","../../../node_modules/@mui/material/styles/styled.js","../../../node_modules/@mui/material/SvgIcon/svgIconClasses.js","../../../node_modules/@mui/material/SvgIcon/SvgIcon.js","../../../node_modules/@mui/material/utils/createSvgIcon.js","../../../node_modules/@mui/material/utils/index.js","../../../node_modules/@mui/icons-material/utils/createSvgIcon.js","../../../node_modules/@mui/icons-material/ArrowRight.js","../../../node_modules/@mui/base/utils/isHostComponent.js","../../../node_modules/@mui/base/utils/appendOwnerState.js","../../../node_modules/@mui/base/utils/ClassNameConfigurator.js","../../../node_modules/@mui/base/utils/extractEventHandlers.js","../../../node_modules/@mui/base/utils/resolveComponentProps.js","../../../node_modules/@mui/base/utils/omitEventHandlers.js","../../../node_modules/@mui/base/utils/mergeSlotProps.js","../../../node_modules/@mui/base/utils/useSlotProps.js","../../../node_modules/@mui/base/generateUtilityClass/index.js","../../../node_modules/@mui/base/generateUtilityClasses/index.js","../../../node_modules/@mui/base/Portal/Portal.js","../../../node_modules/@popperjs/core/lib/enums.js","../../../node_modules/@popperjs/core/lib/dom-utils/getNodeName.js","../../../node_modules/@popperjs/core/lib/dom-utils/getWindow.js","../../../node_modules/@popperjs/core/lib/dom-utils/instanceOf.js","../../../node_modules/@popperjs/core/lib/modifiers/applyStyles.js","../../../node_modules/@popperjs/core/lib/utils/getBasePlacement.js","../../../node_modules/@popperjs/core/lib/utils/math.js","../../../node_modules/@popperjs/core/lib/utils/userAgent.js","../../../node_modules/@popperjs/core/lib/dom-utils/isLayoutViewport.js","../../../node_modules/@popperjs/core/lib/dom-utils/getBoundingClientRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/getLayoutRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/contains.js","../../../node_modules/@popperjs/core/lib/dom-utils/getComputedStyle.js","../../../node_modules/@popperjs/core/lib/dom-utils/isTableElement.js","../../../node_modules/@popperjs/core/lib/dom-utils/getDocumentElement.js","../../../node_modules/@popperjs/core/lib/dom-utils/getParentNode.js","../../../node_modules/@popperjs/core/lib/dom-utils/getOffsetParent.js","../../../node_modules/@popperjs/core/lib/utils/getMainAxisFromPlacement.js","../../../node_modules/@popperjs/core/lib/utils/within.js","../../../node_modules/@popperjs/core/lib/utils/getFreshSideObject.js","../../../node_modules/@popperjs/core/lib/utils/mergePaddingObject.js","../../../node_modules/@popperjs/core/lib/utils/expandToHashMap.js","../../../node_modules/@popperjs/core/lib/modifiers/arrow.js","../../../node_modules/@popperjs/core/lib/utils/getVariation.js","../../../node_modules/@popperjs/core/lib/modifiers/computeStyles.js","../../../node_modules/@popperjs/core/lib/modifiers/eventListeners.js","../../../node_modules/@popperjs/core/lib/utils/getOppositePlacement.js","../../../node_modules/@popperjs/core/lib/utils/getOppositeVariationPlacement.js","../../../node_modules/@popperjs/core/lib/dom-utils/getWindowScroll.js","../../../node_modules/@popperjs/core/lib/dom-utils/getWindowScrollBarX.js","../../../node_modules/@popperjs/core/lib/dom-utils/getViewportRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/getDocumentRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/isScrollParent.js","../../../node_modules/@popperjs/core/lib/dom-utils/getScrollParent.js","../../../node_modules/@popperjs/core/lib/dom-utils/listScrollParents.js","../../../node_modules/@popperjs/core/lib/utils/rectToClientRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/getClippingRect.js","../../../node_modules/@popperjs/core/lib/utils/computeOffsets.js","../../../node_modules/@popperjs/core/lib/utils/detectOverflow.js","../../../node_modules/@popperjs/core/lib/utils/computeAutoPlacement.js","../../../node_modules/@popperjs/core/lib/modifiers/flip.js","../../../node_modules/@popperjs/core/lib/modifiers/hide.js","../../../node_modules/@popperjs/core/lib/modifiers/offset.js","../../../node_modules/@popperjs/core/lib/modifiers/popperOffsets.js","../../../node_modules/@popperjs/core/lib/utils/getAltAxis.js","../../../node_modules/@popperjs/core/lib/modifiers/preventOverflow.js","../../../node_modules/@popperjs/core/lib/dom-utils/getHTMLElementScroll.js","../../../node_modules/@popperjs/core/lib/dom-utils/getNodeScroll.js","../../../node_modules/@popperjs/core/lib/dom-utils/getCompositeRect.js","../../../node_modules/@popperjs/core/lib/utils/orderModifiers.js","../../../node_modules/@popperjs/core/lib/utils/debounce.js","../../../node_modules/@popperjs/core/lib/utils/mergeByName.js","../../../node_modules/@popperjs/core/lib/createPopper.js","../../../node_modules/@popperjs/core/lib/popper.js","../../../node_modules/@mui/base/Popper/popperClasses.js","../../../node_modules/@mui/base/Popper/Popper.js","../../../node_modules/@mui/material/styles/useTheme.js","../../../node_modules/@babel/runtime/helpers/esm/setPrototypeOf.js","../../../node_modules/@babel/runtime/helpers/esm/inheritsLoose.js","../../../node_modules/react-transition-group/esm/config.js","../../../node_modules/react-transition-group/esm/utils/PropTypes.js","../../../node_modules/react-transition-group/esm/TransitionGroupContext.js","../../../node_modules/react-transition-group/esm/utils/reflow.js","../../../node_modules/react-transition-group/esm/Transition.js","../../../node_modules/@mui/material/transitions/utils.js","../../../node_modules/@mui/material/Grow/Grow.js","../../../node_modules/@mui/material/Popper/Popper.js","../../../node_modules/@mui/material/Tooltip/tooltipClasses.js","../../../node_modules/@mui/material/Tooltip/Tooltip.js","../src/components/mui/menu-item.component.tsx","../src/components/mui/grouped-menu-item-list.component.tsx","../src/components/mui/top-level-menu.component.tsx","../src/components/mui/grid-menu.component.tsx","../src/hooks/use-promise.hook.ts","../../../node_modules/@mui/icons-material/esm/Menu.js","../src/components/mui/hamburger-menu-button.component.tsx","../src/components/mui/icon-button.component.tsx","../src/components/basics/spinner.component.tsx","../src/components/basics/text-field.component.tsx","../src/components/mui/toolbar.component.tsx","../src/components/shadcn-ui/alert.tsx","../src/components/shadcn-ui/sonner.tsx","../src/components/shadcn-ui/slider.tsx","../src/components/shadcn-ui/switch.tsx","../src/components/shadcn-ui/tabs.tsx","../src/components/advanced/extension-marketplace/buttons/install-button.component.tsx","../src/components/advanced/extension-marketplace/buttons/enable-button.component.tsx","../src/components/advanced/extension-marketplace/buttons/disable-button.component.tsx","../src/components/advanced/extension-marketplace/buttons/update-button.component.tsx","../src/components/advanced/extension-marketplace/markdown-renderer.component.tsx","../src/components/advanced/extension-marketplace/buttons/filter-button.component.tsx","../src/components/advanced/extension-marketplace/filter-dropdown.component.tsx","../src/components/advanced/extension-marketplace/no-extensions-found.component.tsx","../src/components/advanced/extension-marketplace/more-info.component.tsx","../src/components/advanced/extension-marketplace/version-history.component.tsx","../src/components/advanced/extension-marketplace/footer.component.tsx","../src/hooks/use-event.hook.ts","../src/hooks/use-event-async.hook.ts"],"sourcesContent":["import { type ClassValue, clsx } from 'clsx';\nimport { extendTailwindMerge } from 'tailwind-merge';\n\nconst twMergeCustom = extendTailwindMerge({ prefix: 'tw-' });\n\n/**\n * Tailwind and CSS class application helper function. Uses\n * [`clsx`](https://www.npmjs.com/package/clsx) to make it easy to apply classes conditionally using\n * object syntax, and uses [`tailwind-merge`](https://www.npmjs.com/package/tailwind-merge) to make\n * it easy to merge/overwrite Tailwind classes in a programmer-logic-friendly way.\n *\n * Note: `tailwind-merge` is configured to use the prefix `tw-`, so you must use the same prefix\n * with any Tailwind classes you use with this function to successfully overwrite other Tailwind\n * classes. `platform-bible-react` is configured to use `tw-` as its Tailwind prefix, so any\n * Tailwind classes you pass into `platform-bible-react` components will be compared using the `tw-`\n * prefix.\n *\n * This function was popularized by\n * [shadcn/ui](https://ui.shadcn.com/docs/installation/manual#add-a-cn-helper). See [ByteGrad's\n * explanation video](https://www.youtube.com/watch?v=re2JFITR7TI) for more information.\n *\n * @example\n *\n * ```typescript\n * const borderShouldBeBlue = true;\n * const textShouldBeRed = true;\n * const heightShouldBe20 = false;\n * const classString = cn(\n * 'tw-bg-primary tw-h-10 tw-text-primary-foreground',\n * 'tw-bg-secondary',\n * {\n * 'tw-border-blue-500': borderShouldBeBlue,\n * 'tw-text-red-500': textShouldBeRed,\n * 'tw-h-20': heightShouldBe20,\n * },\n * 'some-class',\n * );\n * ```\n *\n * The resulting `classString` is `'tw-h-10 tw-bg-secondary tw-border-blue-500 tw-text-red-500\n * some-class'`\n *\n * - Notice that `'tw-bg-secondary'`, specified later, overwrote `'tw-bg-primary'`, specified earlier,\n * because they are Tailwind classes that affect the same css property\n * - Notice that `'tw-text-red-500'`, specified later, overwrote `'tw-text-primary-foreground'`,\n * specified earlier, because they are Tailwind classes that affect the same css property\n * - Notice that `'tw-h-20'`, specified later, did not overwrite `'tw-h-10'`, specified earlier,\n * because `'tw-h-20'` is part of a conditional class object and its value evaluated to `false`;\n * therefore it was not applied\n * - Notice that `'some-class'` was applied. This function is not limited only to Tailwind classes.\n *\n *\n * @param inputs Class strings or `clsx` conditional class objects to merge. Tailwind classes\n * specified later in the arguments overwrite similar Tailwind classes specified earlier in the\n * arguments\n * @returns Class string containing all applicable classes from the arguments based on the rules\n * described above\n */\n// shadcn/ui uses this export in its boilerplate code\n// eslint-disable-next-line import/prefer-default-export\nexport function cn(...inputs: ClassValue[]) {\n return twMergeCustom(clsx(inputs));\n}\n","import React from 'react';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport interface InputProps extends React.InputHTMLAttributes {}\n\nexport const Input = React.forwardRef(\n ({ className, type, ...props }, ref) => {\n return (\n \n );\n },\n);\nInput.displayName = 'Input';\n","import { FocusEventHandler, forwardRef, KeyboardEvent, MouseEventHandler } from 'react';\nimport { History } from 'lucide-react';\nimport { Input as ShadInput } from '@/components/shadcn-ui/input';\n\nexport type BookChapterInputProps = {\n handleSearch: (searchString: string) => void;\n handleKeyDown: (event: KeyboardEvent) => void;\n handleOnClick: MouseEventHandler;\n handleSubmit: () => void;\n onFocus?: FocusEventHandler;\n value: string;\n placeholder: string;\n};\n\n// Shadcn Input sets type to \"button\"- HAVE to prop spread before setting type\nconst BookChapterInput = forwardRef(\n (\n { handleSearch, handleKeyDown, handleOnClick, handleSubmit, ...props }: BookChapterInputProps,\n ref,\n ) => {\n return (\n
    \n handleSearch(event.target.value)}\n onKeyDown={(e) => {\n if (e.key === 'Enter') {\n handleSubmit();\n }\n handleKeyDown(e);\n }}\n onClick={handleOnClick}\n ref={ref}\n />\n {\n // eslint-disable-next-line no-console\n console.log('back in history');\n }}\n />\n
    \n );\n },\n);\n\nexport default BookChapterInput;\n","var P = Object.defineProperty;\nvar R = (t, e, s) => e in t ? P(t, e, { enumerable: !0, configurable: !0, writable: !0, value: s }) : t[e] = s;\nvar n = (t, e, s) => R(t, typeof e != \"symbol\" ? e + \"\" : e, s);\nclass _ {\n constructor() {\n n(this, \"books\");\n n(this, \"firstSelectedBookNum\");\n n(this, \"lastSelectedBookNum\");\n n(this, \"count\");\n n(this, \"selectedBookNumbers\");\n n(this, \"selectedBookIds\");\n }\n}\nconst N = [\n \"GEN\",\n \"EXO\",\n \"LEV\",\n \"NUM\",\n \"DEU\",\n \"JOS\",\n \"JDG\",\n \"RUT\",\n \"1SA\",\n \"2SA\",\n // 10\n \"1KI\",\n \"2KI\",\n \"1CH\",\n \"2CH\",\n \"EZR\",\n \"NEH\",\n \"EST\",\n \"JOB\",\n \"PSA\",\n \"PRO\",\n // 20\n \"ECC\",\n \"SNG\",\n \"ISA\",\n \"JER\",\n \"LAM\",\n \"EZK\",\n \"DAN\",\n \"HOS\",\n \"JOL\",\n \"AMO\",\n // 30\n \"OBA\",\n \"JON\",\n \"MIC\",\n \"NAM\",\n \"HAB\",\n \"ZEP\",\n \"HAG\",\n \"ZEC\",\n \"MAL\",\n \"MAT\",\n // 40\n \"MRK\",\n \"LUK\",\n \"JHN\",\n \"ACT\",\n \"ROM\",\n \"1CO\",\n \"2CO\",\n \"GAL\",\n \"EPH\",\n \"PHP\",\n // 50\n \"COL\",\n \"1TH\",\n \"2TH\",\n \"1TI\",\n \"2TI\",\n \"TIT\",\n \"PHM\",\n \"HEB\",\n \"JAS\",\n \"1PE\",\n // 60\n \"2PE\",\n \"1JN\",\n \"2JN\",\n \"3JN\",\n \"JUD\",\n \"REV\",\n \"TOB\",\n \"JDT\",\n \"ESG\",\n \"WIS\",\n // 70\n \"SIR\",\n \"BAR\",\n \"LJE\",\n \"S3Y\",\n \"SUS\",\n \"BEL\",\n \"1MA\",\n \"2MA\",\n \"3MA\",\n \"4MA\",\n // 80\n \"1ES\",\n \"2ES\",\n \"MAN\",\n \"PS2\",\n \"ODA\",\n \"PSS\",\n \"JSA\",\n // actual variant text for JOS, now in LXA text\n \"JDB\",\n // actual variant text for JDG, now in LXA text\n \"TBS\",\n // actual variant text for TOB, now in LXA text\n \"SST\",\n // actual variant text for SUS, now in LXA text // 90\n \"DNT\",\n // actual variant text for DAN, now in LXA text\n \"BLT\",\n // actual variant text for BEL, now in LXA text\n \"XXA\",\n \"XXB\",\n \"XXC\",\n \"XXD\",\n \"XXE\",\n \"XXF\",\n \"XXG\",\n \"FRT\",\n // 100\n \"BAK\",\n \"OTH\",\n \"3ES\",\n // Used previously but really should be 2ES\n \"EZA\",\n // Used to be called 4ES, but not actually in any known project\n \"5EZ\",\n // Used to be called 5ES, but not actually in any known project\n \"6EZ\",\n // Used to be called 6ES, but not actually in any known project\n \"INT\",\n \"CNC\",\n \"GLO\",\n \"TDX\",\n // 110\n \"NDX\",\n \"DAG\",\n \"PS3\",\n \"2BA\",\n \"LBA\",\n \"JUB\",\n \"ENO\",\n \"1MQ\",\n \"2MQ\",\n \"3MQ\",\n // 120\n \"REP\",\n \"4BA\",\n \"LAO\"\n], B = [\n \"XXA\",\n \"XXB\",\n \"XXC\",\n \"XXD\",\n \"XXE\",\n \"XXF\",\n \"XXG\",\n \"FRT\",\n \"BAK\",\n \"OTH\",\n \"INT\",\n \"CNC\",\n \"GLO\",\n \"TDX\",\n \"NDX\"\n], O = [\n \"Genesis\",\n \"Exodus\",\n \"Leviticus\",\n \"Numbers\",\n \"Deuteronomy\",\n \"Joshua\",\n \"Judges\",\n \"Ruth\",\n \"1 Samuel\",\n \"2 Samuel\",\n \"1 Kings\",\n \"2 Kings\",\n \"1 Chronicles\",\n \"2 Chronicles\",\n \"Ezra\",\n \"Nehemiah\",\n \"Esther (Hebrew)\",\n \"Job\",\n \"Psalms\",\n \"Proverbs\",\n \"Ecclesiastes\",\n \"Song of Songs\",\n \"Isaiah\",\n \"Jeremiah\",\n \"Lamentations\",\n \"Ezekiel\",\n \"Daniel (Hebrew)\",\n \"Hosea\",\n \"Joel\",\n \"Amos\",\n \"Obadiah\",\n \"Jonah\",\n \"Micah\",\n \"Nahum\",\n \"Habakkuk\",\n \"Zephaniah\",\n \"Haggai\",\n \"Zechariah\",\n \"Malachi\",\n \"Matthew\",\n \"Mark\",\n \"Luke\",\n \"John\",\n \"Acts\",\n \"Romans\",\n \"1 Corinthians\",\n \"2 Corinthians\",\n \"Galatians\",\n \"Ephesians\",\n \"Philippians\",\n \"Colossians\",\n \"1 Thessalonians\",\n \"2 Thessalonians\",\n \"1 Timothy\",\n \"2 Timothy\",\n \"Titus\",\n \"Philemon\",\n \"Hebrews\",\n \"James\",\n \"1 Peter\",\n \"2 Peter\",\n \"1 John\",\n \"2 John\",\n \"3 John\",\n \"Jude\",\n \"Revelation\",\n \"Tobit\",\n \"Judith\",\n \"Esther Greek\",\n \"Wisdom of Solomon\",\n \"Sirach (Ecclesiasticus)\",\n \"Baruch\",\n \"Letter of Jeremiah\",\n \"Song of 3 Young Men\",\n \"Susanna\",\n \"Bel and the Dragon\",\n \"1 Maccabees\",\n \"2 Maccabees\",\n \"3 Maccabees\",\n \"4 Maccabees\",\n \"1 Esdras (Greek)\",\n \"2 Esdras (Latin)\",\n \"Prayer of Manasseh\",\n \"Psalm 151\",\n \"Odes\",\n \"Psalms of Solomon\",\n // WARNING, if you change the spelling of the *obsolete* tag be sure to update\n // IsObsolete routine\n \"Joshua A. *obsolete*\",\n \"Judges B. *obsolete*\",\n \"Tobit S. *obsolete*\",\n \"Susanna Th. *obsolete*\",\n \"Daniel Th. *obsolete*\",\n \"Bel Th. *obsolete*\",\n \"Extra A\",\n \"Extra B\",\n \"Extra C\",\n \"Extra D\",\n \"Extra E\",\n \"Extra F\",\n \"Extra G\",\n \"Front Matter\",\n \"Back Matter\",\n \"Other Matter\",\n \"3 Ezra *obsolete*\",\n \"Apocalypse of Ezra\",\n \"5 Ezra (Latin Prologue)\",\n \"6 Ezra (Latin Epilogue)\",\n \"Introduction\",\n \"Concordance \",\n \"Glossary \",\n \"Topical Index\",\n \"Names Index\",\n \"Daniel Greek\",\n \"Psalms 152-155\",\n \"2 Baruch (Apocalypse)\",\n \"Letter of Baruch\",\n \"Jubilees\",\n \"Enoch\",\n \"1 Meqabyan\",\n \"2 Meqabyan\",\n \"3 Meqabyan\",\n \"Reproof (Proverbs 25-31)\",\n \"4 Baruch (Rest of Baruch)\",\n \"Laodiceans\"\n], S = K();\nfunction g(t, e = !0) {\n return e && (t = t.toUpperCase()), t in S ? S[t] : 0;\n}\nfunction k(t) {\n return g(t) > 0;\n}\nfunction x(t) {\n const e = typeof t == \"string\" ? g(t) : t;\n return e >= 40 && e <= 66;\n}\nfunction T(t) {\n return (typeof t == \"string\" ? g(t) : t) <= 39;\n}\nfunction X(t) {\n return t <= 66;\n}\nfunction V(t) {\n const e = typeof t == \"string\" ? g(t) : t;\n return w(e) && !X(e);\n}\nfunction* L() {\n for (let t = 1; t <= N.length; t++) yield t;\n}\nconst G = 1, A = N.length;\nfunction H() {\n return [\"XXA\", \"XXB\", \"XXC\", \"XXD\", \"XXE\", \"XXF\", \"XXG\"];\n}\nfunction C(t, e = \"***\") {\n const s = t - 1;\n return s < 0 || s >= N.length ? e : N[s];\n}\nfunction I(t) {\n return t <= 0 || t > A ? \"******\" : O[t - 1];\n}\nfunction y(t) {\n return I(g(t));\n}\nfunction w(t) {\n const e = typeof t == \"number\" ? C(t) : t;\n return k(e) && !B.includes(e);\n}\nfunction q(t) {\n const e = typeof t == \"number\" ? C(t) : t;\n return k(e) && B.includes(e);\n}\nfunction U(t) {\n return O[t - 1].includes(\"*obsolete*\");\n}\nfunction K() {\n const t = {};\n for (let e = 0; e < N.length; e++)\n t[N[e]] = e + 1;\n return t;\n}\nconst m = {\n allBookIds: N,\n nonCanonicalIds: B,\n bookIdToNumber: g,\n isBookIdValid: k,\n isBookNT: x,\n isBookOT: T,\n isBookOTNT: X,\n isBookDC: V,\n allBookNumbers: L,\n firstBook: G,\n lastBook: A,\n extraBooks: H,\n bookNumberToId: C,\n bookNumberToEnglishName: I,\n bookIdToEnglishName: y,\n isCanonical: w,\n isExtraMaterial: q,\n isObsolete: U\n};\nvar l = /* @__PURE__ */ ((t) => (t[t.Unknown = 0] = \"Unknown\", t[t.Original = 1] = \"Original\", t[t.Septuagint = 2] = \"Septuagint\", t[t.Vulgate = 3] = \"Vulgate\", t[t.English = 4] = \"English\", t[t.RussianProtestant = 5] = \"RussianProtestant\", t[t.RussianOrthodox = 6] = \"RussianOrthodox\", t))(l || {});\nconst h = class h {\n // private versInfo: Versification;\n constructor(e) {\n n(this, \"name\");\n n(this, \"fullPath\");\n n(this, \"isPresent\");\n n(this, \"hasVerseSegments\");\n n(this, \"isCustomized\");\n n(this, \"baseVersification\");\n n(this, \"scriptureBooks\");\n n(this, \"_type\");\n if (e == null)\n throw new Error(\"Argument undefined\");\n typeof e == \"string\" ? (this.name = e, this._type = l[e]) : (this._type = e, this.name = l[e]);\n }\n get type() {\n return this._type;\n }\n equals(e) {\n return !e.type || !this.type ? !1 : e.type === this.type;\n }\n};\nn(h, \"Original\", new h(l.Original)), n(h, \"Septuagint\", new h(l.Septuagint)), n(h, \"Vulgate\", new h(l.Vulgate)), n(h, \"English\", new h(l.English)), n(h, \"RussianProtestant\", new h(l.RussianProtestant)), n(h, \"RussianOrthodox\", new h(l.RussianOrthodox));\nlet c = h;\nfunction E(t, e) {\n const s = e[0];\n for (let r = 1; r < e.length; r++)\n t = t.split(e[r]).join(s);\n return t.split(s);\n}\nvar D = /* @__PURE__ */ ((t) => (t[t.Valid = 0] = \"Valid\", t[t.UnknownVersification = 1] = \"UnknownVersification\", t[t.OutOfRange = 2] = \"OutOfRange\", t[t.VerseOutOfOrder = 3] = \"VerseOutOfOrder\", t[t.VerseRepeated = 4] = \"VerseRepeated\", t))(D || {});\nconst i = class i {\n constructor(e, s, r, a) {\n /** Not yet implemented. */\n n(this, \"firstChapter\");\n /** Not yet implemented. */\n n(this, \"lastChapter\");\n /** Not yet implemented. */\n n(this, \"lastVerse\");\n /** Not yet implemented. */\n n(this, \"hasSegmentsDefined\");\n /** Not yet implemented. */\n n(this, \"text\");\n /** Not yet implemented. */\n n(this, \"BBBCCCVVVS\");\n /** Not yet implemented. */\n n(this, \"longHashCode\");\n /** The versification of the reference. */\n n(this, \"versification\");\n n(this, \"rtlMark\", \"‏\");\n n(this, \"_bookNum\", 0);\n n(this, \"_chapterNum\", 0);\n n(this, \"_verseNum\", 0);\n n(this, \"_verse\");\n if (r == null && a == null)\n if (e != null && typeof e == \"string\") {\n const o = e, u = s != null && s instanceof c ? s : void 0;\n this.setEmpty(u), this.parse(o);\n } else if (e != null && typeof e == \"number\") {\n const o = s != null && s instanceof c ? s : void 0;\n this.setEmpty(o), this._verseNum = e % i.chapterDigitShifter, this._chapterNum = Math.floor(\n e % i.bookDigitShifter / i.chapterDigitShifter\n ), this._bookNum = Math.floor(e / i.bookDigitShifter);\n } else if (s == null)\n if (e != null && e instanceof i) {\n const o = e;\n this._bookNum = o.bookNum, this._chapterNum = o.chapterNum, this._verseNum = o.verseNum, this._verse = o.verse, this.versification = o.versification;\n } else {\n if (e == null) return;\n const o = e instanceof c ? e : i.defaultVersification;\n this.setEmpty(o);\n }\n else\n throw new Error(\"VerseRef constructor not supported.\");\n else if (e != null && s != null && r != null)\n if (typeof e == \"string\" && typeof s == \"string\" && typeof r == \"string\")\n this.setEmpty(a), this.updateInternal(e, s, r);\n else if (typeof e == \"number\" && typeof s == \"number\" && typeof r == \"number\")\n this._bookNum = e, this._chapterNum = s, this._verseNum = r, this.versification = a ?? i.defaultVersification;\n else\n throw new Error(\"VerseRef constructor not supported.\");\n else\n throw new Error(\"VerseRef constructor not supported.\");\n }\n /**\n * Determines if the verse string is in a valid format (does not consider versification).\n */\n static isVerseParseable(e) {\n return e.length > 0 && \"0123456789\".includes(e[0]) && !e.endsWith(this.verseRangeSeparator) && !e.endsWith(this.verseSequenceIndicator);\n }\n /**\n * Tries to parse the specified string into a verse reference.\n * @param str - The string to attempt to parse.\n * @returns success: `true` if the specified string was successfully parsed, `false` otherwise.\n * @returns verseRef: The result of the parse if successful, or empty VerseRef if it failed\n */\n static tryParse(e) {\n let s;\n try {\n return s = new i(e), { success: !0, verseRef: s };\n } catch (r) {\n if (r instanceof v)\n return s = new i(), { success: !1, verseRef: s };\n throw r;\n }\n }\n /**\n * Gets the reference as a comparable integer where the book, chapter, and verse each occupy 3\n * digits.\n * @param bookNum - Book number (this is 1-based, not an index).\n * @param chapterNum - Chapter number.\n * @param verseNum - Verse number.\n * @returns The reference as a comparable integer where the book, chapter, and verse each occupy 3\n * digits.\n */\n static getBBBCCCVVV(e, s, r) {\n return e % i.bcvMaxValue * i.bookDigitShifter + (s >= 0 ? s % i.bcvMaxValue * i.chapterDigitShifter : 0) + (r >= 0 ? r % i.bcvMaxValue : 0);\n }\n /**\n * Deserializes a serialized VerseRef.\n * @param serializedVerseRef - Serialized VerseRef to create from.\n * @returns the deserialized VerseRef.\n */\n static fromJSON(e) {\n const { book: s, chapterNum: r, verseNum: a, verse: o, versificationStr: u } = e, f = o || a.toString();\n let d;\n return u && (d = new c(u)), s ? new i(s, r.toString(), f, d) : new i();\n }\n /**\n * Parses a verse string and gets the leading numeric portion as a number.\n * @param verseStr - verse string to parse\n * @returns true if the entire string could be parsed as a single, simple verse number (1-999);\n * false if the verse string represented a verse bridge, contained segment letters, or was invalid\n */\n static tryGetVerseNum(e) {\n let s;\n if (!e)\n return s = -1, { success: !0, vNum: s };\n s = 0;\n let r;\n for (let a = 0; a < e.length; a++) {\n if (r = e[a], r < \"0\" || r > \"9\")\n return a === 0 && (s = -1), { success: !1, vNum: s };\n if (s = s * 10 + +r - 0, s > i.bcvMaxValue)\n return s = -1, { success: !1, vNum: s };\n }\n return { success: !0, vNum: s };\n }\n /**\n * Checks to see if a VerseRef hasn't been set - all values are the default.\n */\n get isDefault() {\n return this.bookNum === 0 && this.chapterNum === 0 && this.verseNum === 0 && this.versification == null;\n }\n /**\n * Gets whether the verse contains multiple verses.\n */\n get hasMultiple() {\n return this._verse != null && (this._verse.includes(i.verseRangeSeparator) || this._verse.includes(i.verseSequenceIndicator));\n }\n /**\n * Gets or sets the book of the reference. Book is the 3-letter abbreviation in capital letters,\n * e.g. `'MAT'`.\n */\n get book() {\n return m.bookNumberToId(this.bookNum, \"\");\n }\n set book(e) {\n this.bookNum = m.bookIdToNumber(e);\n }\n /**\n * Gets or sets the chapter of the reference,. e.g. `'3'`.\n */\n get chapter() {\n return this.isDefault || this._chapterNum < 0 ? \"\" : this._chapterNum.toString();\n }\n set chapter(e) {\n const s = +e;\n this._chapterNum = Number.isInteger(s) ? s : -1;\n }\n /**\n * Gets or sets the verse of the reference, including range, segments, and sequences, e.g. `'4'`,\n * or `'4b-5a, 7'`.\n */\n get verse() {\n return this._verse != null ? this._verse : this.isDefault || this._verseNum < 0 ? \"\" : this._verseNum.toString();\n }\n set verse(e) {\n const { success: s, vNum: r } = i.tryGetVerseNum(e);\n this._verse = s ? void 0 : e.replace(this.rtlMark, \"\"), this._verseNum = r, !(this._verseNum >= 0) && ({ vNum: this._verseNum } = i.tryGetVerseNum(this._verse));\n }\n /**\n * Get or set Book based on book number, e.g. `42`.\n */\n get bookNum() {\n return this._bookNum;\n }\n set bookNum(e) {\n if (e <= 0 || e > m.lastBook)\n throw new v(\n \"BookNum must be greater than zero and less than or equal to last book\"\n );\n this._bookNum = e;\n }\n /**\n * Gets or sets the chapter number, e.g. `3`. `-1` if not valid.\n */\n get chapterNum() {\n return this._chapterNum;\n }\n set chapterNum(e) {\n this.chapterNum = e;\n }\n /**\n * Gets or sets verse start number, e.g. `4`. `-1` if not valid.\n */\n get verseNum() {\n return this._verseNum;\n }\n set verseNum(e) {\n this._verseNum = e;\n }\n /**\n * String representing the versification (should ONLY be used for serialization/deserialization).\n *\n * @remarks This is for backwards compatibility when ScrVers was an enumeration.\n */\n get versificationStr() {\n var e;\n return (e = this.versification) == null ? void 0 : e.name;\n }\n set versificationStr(e) {\n this.versification = this.versification != null ? new c(e) : void 0;\n }\n /**\n * Determines if the reference is valid.\n */\n get valid() {\n return this.validStatus === 0;\n }\n /**\n * Get the valid status for this reference.\n */\n get validStatus() {\n return this.validateVerse(i.verseRangeSeparators, i.verseSequenceIndicators);\n }\n /**\n * Gets the reference as a comparable integer where the book,\n * chapter, and verse each occupy three digits and the verse is 0.\n */\n get BBBCCC() {\n return i.getBBBCCCVVV(this._bookNum, this._chapterNum, 0);\n }\n /**\n * Gets the reference as a comparable integer where the book,\n * chapter, and verse each occupy three digits. If verse is not null\n * (i.e., this reference represents a complex reference with verse\n * segments or bridge) this cannot be used for an exact comparison.\n */\n get BBBCCCVVV() {\n return i.getBBBCCCVVV(this._bookNum, this._chapterNum, this._verseNum);\n }\n /**\n * Gets whether the verse is defined as an excluded verse in the versification.\n * Does not handle verse ranges.\n */\n // eslint-disable-next-line @typescript-eslint/class-literal-property-style\n get isExcluded() {\n return !1;\n }\n /**\n * Parses the reference in the specified string.\n * Optionally versification can follow reference as in GEN 3:11/4\n * Throw an exception if\n * - invalid book name\n * - chapter number is missing or not a number\n * - verse number is missing or does not start with a number\n * - versification is invalid\n * @param verseStr - string to parse e.g. 'MAT 3:11'\n */\n parse(e) {\n if (e = e.replace(this.rtlMark, \"\"), e.includes(\"/\")) {\n const o = e.split(\"/\");\n if (e = o[0], o.length > 1)\n try {\n const u = +o[1].trim();\n this.versification = new c(l[u]);\n } catch {\n throw new v(\"Invalid reference : \" + e);\n }\n }\n const s = e.trim().split(\" \");\n if (s.length !== 2)\n throw new v(\"Invalid reference : \" + e);\n const r = s[1].split(\":\"), a = +r[0];\n if (r.length !== 2 || m.bookIdToNumber(s[0]) === 0 || !Number.isInteger(a) || a < 0 || !i.isVerseParseable(r[1]))\n throw new v(\"Invalid reference : \" + e);\n this.updateInternal(s[0], r[0], r[1]);\n }\n /**\n * Simplifies this verse ref so that it has no bridging of verses or\n * verse segments like `'1a'`.\n */\n simplify() {\n this._verse = void 0;\n }\n /**\n * Makes a clone of the reference.\n *\n * @returns The cloned VerseRef.\n */\n clone() {\n return new i(this);\n }\n toString() {\n const e = this.book;\n return e === \"\" ? \"\" : `${e} ${this.chapter}:${this.verse}`;\n }\n toJSON() {\n let e = this.verse;\n (e === \"\" || e === this.verseNum.toString()) && (e = void 0);\n const s = {\n book: this.book,\n chapterNum: this.chapterNum,\n verseNum: this.verseNum,\n verse: e,\n versificationStr: this.versificationStr\n };\n return e || delete s.verse, s;\n }\n /**\n * Compares this `VerseRef` with supplied one.\n * @param verseRef - object to compare this one to.\n * @returns `true` if this `VerseRef` is equal to the supplied one, `false` otherwise.\n */\n equals(e) {\n return e instanceof i ? e._bookNum === this._bookNum && e._chapterNum === this._chapterNum && e._verseNum === this._verseNum && e.verse === this.verse && (e.versification == null && this.versification == null || e.versification != null && this.versification != null && e.versification.equals(this.versification)) : !1;\n }\n /**\n * Enumerate all individual verses contained in a VerseRef.\n * Verse ranges are indicated by \"-\" and consecutive verses by \",\"s.\n * Examples:\n * GEN 1:2 returns GEN 1:2\n * GEN 1:1a-3b,5 returns GEN 1:1a, GEN 1:2, GEN 1:3b, GEN 1:5\n * GEN 1:2a-2c returns //! ??????\n *\n * @param specifiedVersesOnly - if set to true return only verses that are\n * explicitly specified only, not verses within a range. Defaults to `false`.\n * @param verseRangeSeparators - Verse range separators.\n * Defaults to `VerseRef.verseRangeSeparators`.\n * @param verseSequenceSeparators - Verse sequence separators.\n * Defaults to `VerseRef.verseSequenceIndicators`.\n * @returns An array of all single verse references in this VerseRef.\n */\n allVerses(e = !1, s = i.verseRangeSeparators, r = i.verseSequenceIndicators) {\n if (this._verse == null || this.chapterNum <= 0)\n return [this.clone()];\n const a = [], o = E(this._verse, r);\n for (const u of o.map((f) => E(f, s))) {\n const f = this.clone();\n f.verse = u[0];\n const d = f.verseNum;\n if (a.push(f), u.length > 1) {\n const b = this.clone();\n if (b.verse = u[1], !e)\n for (let p = d + 1; p < b.verseNum; p++) {\n const J = new i(\n this._bookNum,\n this._chapterNum,\n p,\n this.versification\n );\n this.isExcluded || a.push(J);\n }\n a.push(b);\n }\n }\n return a;\n }\n /**\n * Validates a verse number using the supplied separators rather than the defaults.\n */\n validateVerse(e, s) {\n if (!this.verse)\n return this.internalValid;\n let r = 0;\n for (const a of this.allVerses(!0, e, s)) {\n const o = a.internalValid;\n if (o !== 0)\n return o;\n const u = a.BBBCCCVVV;\n if (r > u)\n return 3;\n if (r === u)\n return 4;\n r = u;\n }\n return 0;\n }\n /**\n * Gets whether a single verse reference is valid.\n */\n get internalValid() {\n return this.versification == null ? 1 : this._bookNum <= 0 || this._bookNum > m.lastBook ? 2 : (m.isCanonical(this._bookNum), 0);\n }\n setEmpty(e = i.defaultVersification) {\n this._bookNum = 0, this._chapterNum = -1, this._verse = void 0, this.versification = e;\n }\n updateInternal(e, s, r) {\n this.bookNum = m.bookIdToNumber(e), this.chapter = s, this.verse = r;\n }\n};\nn(i, \"defaultVersification\", c.English), n(i, \"verseRangeSeparator\", \"-\"), n(i, \"verseSequenceIndicator\", \",\"), n(i, \"verseRangeSeparators\", [i.verseRangeSeparator]), n(i, \"verseSequenceIndicators\", [i.verseSequenceIndicator]), n(i, \"chapterDigitShifter\", 1e3), n(i, \"bookDigitShifter\", i.chapterDigitShifter * i.chapterDigitShifter), n(i, \"bcvMaxValue\", i.chapterDigitShifter - 1), /**\n * The valid status of the VerseRef.\n */\nn(i, \"ValidStatusType\", D);\nlet M = i;\nclass v extends Error {\n}\nexport {\n _ as BookSet,\n m as Canon,\n c as ScrVers,\n l as ScrVersType,\n M as VerseRef,\n v as VerseRefException\n};\n//# sourceMappingURL=index.es.js.map\n","import React from 'react';\nimport * as DropdownMenuPrimitive from '@radix-ui/react-dropdown-menu';\nimport { Check, ChevronRight, Circle } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport const DropdownMenu = DropdownMenuPrimitive.Root;\n\nexport const DropdownMenuTrigger = DropdownMenuPrimitive.Trigger;\n\nexport const DropdownMenuGroup = DropdownMenuPrimitive.Group;\n\nexport const DropdownMenuPortal = DropdownMenuPrimitive.Portal;\n\nexport const DropdownMenuSub = DropdownMenuPrimitive.Sub;\n\nexport const DropdownMenuRadioGroup = DropdownMenuPrimitive.RadioGroup;\n\nexport type DropdownMenuSubTriggerProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.SubTrigger\n> & {\n className?: string;\n inset?: boolean;\n};\n\nexport type DropdownMenuSubContentProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.SubContent\n> & {\n className?: string;\n};\n\nexport type DropdownMenuContentProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Content\n> & {\n className?: string;\n sideOffset?: number;\n};\n\nexport type DropdownMenuItemProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Item\n> & {\n className?: string;\n inset?: boolean;\n};\n\nexport type DropdownMenuCheckboxItemProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.CheckboxItem\n> & {\n className?: string;\n checked?: boolean;\n};\n\nexport type DropdownMenuRadioItemProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.RadioItem\n> & {\n className?: string;\n};\n\nexport type DropdownMenuLabelProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Label\n> & {\n className?: string;\n inset?: boolean;\n};\n\nexport type DropdownMenuSeparatorProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Separator\n> & {\n className?: string;\n};\n\nexport type DropdownMenuShortcutProps = React.HTMLAttributes & {\n className?: string;\n};\n\nexport const DropdownMenuSubTrigger = React.forwardRef<\n React.ElementRef,\n DropdownMenuSubTriggerProps\n>(({ className, inset, children, ...props }, ref) => (\n \n {children}\n \n \n));\nDropdownMenuSubTrigger.displayName = DropdownMenuPrimitive.SubTrigger.displayName;\n\nexport const DropdownMenuSubContent = React.forwardRef<\n React.ElementRef,\n DropdownMenuSubContentProps\n>(({ className, ...props }, ref) => (\n \n));\nDropdownMenuSubContent.displayName = DropdownMenuPrimitive.SubContent.displayName;\n\nexport const DropdownMenuContent = React.forwardRef<\n React.ElementRef,\n DropdownMenuContentProps\n>(({ className, sideOffset = 4, ...props }, ref) => (\n \n \n \n));\nDropdownMenuContent.displayName = DropdownMenuPrimitive.Content.displayName;\n\n/**\n * TODO: fix: direction is not automatically handled by this component, so that shortcuts are\n * display always to the right\n */\nexport const DropdownMenuItem = React.forwardRef<\n React.ElementRef,\n DropdownMenuItemProps\n>(({ className, inset, ...props }, ref) => (\n \n));\nDropdownMenuItem.displayName = DropdownMenuPrimitive.Item.displayName;\n\nexport const DropdownMenuCheckboxItem = React.forwardRef<\n React.ElementRef,\n DropdownMenuCheckboxItemProps\n>(({ className, children, checked, ...props }, ref) => (\n \n \n \n \n \n \n {children}\n \n));\nDropdownMenuCheckboxItem.displayName = DropdownMenuPrimitive.CheckboxItem.displayName;\n\nexport const DropdownMenuRadioItem = React.forwardRef<\n React.ElementRef,\n DropdownMenuRadioItemProps\n>(({ className, children, ...props }, ref) => (\n \n \n \n \n \n \n {children}\n \n));\nDropdownMenuRadioItem.displayName = DropdownMenuPrimitive.RadioItem.displayName;\n\nexport const DropdownMenuLabel = React.forwardRef<\n React.ElementRef,\n DropdownMenuLabelProps\n>(({ className, inset, ...props }, ref) => (\n \n));\nDropdownMenuLabel.displayName = DropdownMenuPrimitive.Label.displayName;\n\nexport const DropdownMenuSeparator = React.forwardRef<\n React.ElementRef,\n DropdownMenuSeparatorProps\n>(({ className, ...props }, ref) => (\n \n));\nDropdownMenuSeparator.displayName = DropdownMenuPrimitive.Separator.displayName;\n\nexport function DropdownMenuShortcut({ className, ...props }: DropdownMenuShortcutProps) {\n return (\n \n );\n}\nDropdownMenuShortcut.displayName = 'DropdownMenuShortcut';\n","import { Canon } from '@sillsdev/scripture';\nimport { PropsWithChildren, KeyboardEvent, forwardRef } from 'react';\nimport { DropdownMenuItem as ShadDropdownMenuItem } from '@/components/shadcn-ui/dropdown-menu';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport type BookType = 'OT' | 'NT' | 'DC';\n\ntype BookMenuItemProps = PropsWithChildren<{\n /** String id of book */\n bookId: string;\n /** Callback to run when a book menu item is selected */\n handleSelectBook: () => void;\n /** Indicates if this menu item is currently selected */\n isSelected: boolean;\n /** Function that is called upon highlighting a book in the dropdown menu */\n handleHighlightBook: () => void;\n /**\n * Function that is called on pressing a key\n *\n * @param event Event that contains information about the key stroke\n */\n handleKeyDown: (event: KeyboardEvent) => void;\n /**\n * Type of book associated with this menu item, coordinates color labels ? Mock up has the labels\n * coordinated to genre\n */\n bookType: BookType;\n}>;\n\nconst BookMenuItem = forwardRef(\n (\n {\n bookId,\n handleSelectBook,\n isSelected,\n handleHighlightBook,\n handleKeyDown,\n bookType,\n children,\n }: BookMenuItemProps,\n ref,\n ) => {\n return (\n {\n // preventDefault() here prevents the entire dropdown menu from closing when selecting this item\n event.preventDefault();\n handleSelectBook();\n }}\n onKeyDown={(event: KeyboardEvent) => {\n handleKeyDown(event);\n }}\n onFocus={handleHighlightBook}\n onMouseMove={handleHighlightBook}\n >\n \n {Canon.bookIdToEnglishName(bookId)}\n \n {isSelected &&
    {children}
    }\n \n );\n },\n);\n\nexport default BookMenuItem;\n","import { cn } from '@/utils/shadcn-ui.util';\nimport { useCallback } from 'react';\n\nexport type ChapterSelectProps = {\n /**\n * Callback to run when a chapter div is selected\n *\n * @param chapterNumber Number of the chapter that has been selected\n */\n handleSelectChapter: (chapterNumber: number) => void;\n /** The highest chapter number in the book (of course equal to number of chapters in the book) */\n endChapter: number;\n /** The chapter number that is currently selected */\n activeChapter: number;\n /** The chapter number that is currently highlighted using keyboard or mouse navigation */\n highlightedChapter: number;\n /**\n * Callback to run when a chapter is highlighted by the user\n *\n * @param chapterNumber The chapter that is highlighted\n */\n handleHighlightedChapter: (chapterNumber: number) => void;\n};\n\nfunction ChapterSelect({\n handleSelectChapter,\n endChapter,\n activeChapter,\n highlightedChapter,\n handleHighlightedChapter,\n}: ChapterSelectProps) {\n const chapters = Array.from({ length: endChapter }, (_, i) => i + 1);\n\n const handleMouse = useCallback(\n (chapterNumber: number) => {\n handleHighlightedChapter(chapterNumber);\n },\n [handleHighlightedChapter],\n );\n\n return (\n
    \n {chapters.map((chapter) => (\n {\n event.preventDefault();\n event.stopPropagation();\n handleSelectChapter(chapter);\n }}\n role=\"button\"\n onKeyDown={(event) => {\n if (event.key === 'Enter') {\n handleSelectChapter(chapter);\n }\n }}\n tabIndex={0}\n onMouseMove={() => handleMouse(chapter)}\n >\n {chapter}\n
    \n ))}\n
    \n );\n}\n\nexport default ChapterSelect;\n","import { DropdownMenuLabel as ShadDropdownMenuLabel } from '@/components/shadcn-ui/dropdown-menu';\nimport { Bookmark, Clock, ArrowDownWideNarrow } from 'lucide-react';\n\nexport type GoToMenuItemProps = {\n handleSort: () => void;\n handleLocationHistory: () => void;\n handleBookmarks: () => void;\n};\n\nfunction GoToMenuItem({ handleSort, handleLocationHistory, handleBookmarks }: GoToMenuItemProps) {\n return (\n \n

    Go To

    \n
    \n \n \n \n
    \n
    \n );\n}\n\nexport default GoToMenuItem;\n","import BookChapterInput from '@/components/advanced/book-chapter-control/book-chapter-input.component';\nimport BookMenuItem, {\n BookType,\n} from '@/components/advanced/book-chapter-control/book-menu-item.component';\nimport ChapterSelect from '@/components/advanced/book-chapter-control/chapter-select.component';\nimport GoToMenuItem from '@/components/advanced/book-chapter-control/go-to-menu-item.component';\nimport {\n DropdownMenu as ShadDropdownMenu,\n DropdownMenuContent as ShadDropdownMenuContent,\n DropdownMenuLabel as ShadDropdownMenuLabel,\n DropdownMenuSeparator as ShadDropdownMenuSeparator,\n DropdownMenuTrigger as ShadDropdownMenuTrigger,\n} from '@/components/shadcn-ui/dropdown-menu';\nimport { Canon } from '@sillsdev/scripture';\nimport { ScriptureReference, getChaptersForBook } from 'platform-bible-utils';\nimport {\n KeyboardEvent as ReactKeyboardEvent,\n useCallback,\n useEffect,\n useLayoutEffect,\n useRef,\n useState,\n} from 'react';\n\ntype BookTypeLabels = {\n [bookType in BookType]: string;\n};\ntype BookChapterControlProps = {\n scrRef: ScriptureReference;\n handleSubmit: (scrRef: ScriptureReference) => void;\n};\n\nconst ALL_BOOK_IDS = Canon.allBookIds;\nconst BOOK_TYPE_LABELS: BookTypeLabels = {\n OT: 'Old Testament',\n NT: 'New Testament',\n DC: 'Deuterocanon',\n};\nconst BOOK_TYPE_ARRAY: BookType[] = ['OT', 'NT', 'DC'];\n// This is the height of three menu items to offset scrolling to the selected menu item\n// If you use menuItemRef.clientHeight- includes height of chapter div which is too big\nconst SCROLL_OFFSET = 32 + 32 + 32;\nconst SEARCH_QUERY_FORMATS = [\n /^(\\w+)$/i, // Matches a single word (book name or id)\n /^(\\w+)(?:\\s(\\d+))$/i, // Matches a word followed by a chapter number\n /^(\\w+)(?:\\s(\\d+):(\\d+))$/i, // Matches a word followed by a chapter and verse number\n];\nconst fetchGroupedBooks = (bookType: BookType) => {\n const groupedBooks = {\n OT: ALL_BOOK_IDS.filter((bookId) => Canon.isBookOT(bookId)),\n NT: ALL_BOOK_IDS.filter((bookId) => Canon.isBookNT(bookId)),\n DC: ALL_BOOK_IDS.filter((bookId) => Canon.isBookDC(bookId)),\n };\n return groupedBooks[bookType];\n};\nconst fetchEndChapter = (bookId: string) => {\n // getChaptersForBook returns -1 if not found in scrBookData\n // scrBookData only includes OT and NT, so all DC will return -1\n return getChaptersForBook(Canon.bookIdToNumber(bookId));\n};\n\n/**\n * Gets all of the English names from book ids\n *\n * @returns String[]\n */\nfunction getAllEnglishNames(): string[] {\n const allEnglishNames = ALL_BOOK_IDS.map((bookId) => {\n return Canon.bookIdToEnglishName(bookId);\n });\n return allEnglishNames;\n}\n\n/**\n * Determines if bookName is in allEnglishNames\n *\n * @param bookName Book English name\n * @returns True if bookName is included, false otherwise\n */\nfunction isValidBookEnglishName(bookName: string): boolean {\n return getAllEnglishNames().includes(bookName);\n}\n\n/**\n * Gets a bookId from given English name\n *\n * @param bookName Book English name\n * @returns BookId of provided bookName, undefined otherwise\n */\nfunction getBookIdFromEnglishName(bookName: string): string | undefined {\n // Convert bookName to lowercase and then capitalize the first letter\n const formattedBookName = bookName.toLowerCase().replace(/^\\w/, (c) => c.toUpperCase());\n\n if (isValidBookEnglishName(formattedBookName)) {\n const matchingBookId = ALL_BOOK_IDS.find((bookId) => {\n return Canon.bookIdToEnglishName(bookId) === formattedBookName;\n });\n return matchingBookId;\n }\n\n return undefined;\n}\n\nfunction BookChapterControl({ scrRef, handleSubmit }: BookChapterControlProps) {\n const [searchQuery, setSearchQuery] = useState('');\n const [selectedBookId, setSelectedBookId] = useState(\n Canon.bookNumberToId(scrRef.bookNum),\n );\n const [highlightedChapter, setHighlightedChapter] = useState(scrRef.chapterNum ?? 0);\n const [highlightedBookId, setHighlightedBookId] = useState(\n Canon.bookNumberToId(scrRef.bookNum),\n );\n const [isContentOpen, setIsContentOpen] = useState(false);\n const [isContentOpenDelayed, setIsContentOpenDelayed] = useState(isContentOpen);\n\n // This ref will always be defined\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const inputRef = useRef(undefined!);\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const contentRef = useRef(undefined!);\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const menuItemRef = useRef(undefined!);\n\n const fetchFilteredBooks = useCallback(\n (bookType: BookType) => {\n return fetchGroupedBooks(bookType).filter((bookId: string) => {\n const englishNameLowerCase = Canon.bookIdToEnglishName(bookId).toLowerCase();\n const normalizedQuery = searchQuery.replace(/[^a-zA-Z]/g, '').toLowerCase();\n return (\n englishNameLowerCase.includes(normalizedQuery) || // Match book name\n bookId.toLowerCase().includes(normalizedQuery) // Match book ID\n );\n });\n },\n [searchQuery],\n );\n\n const handleSearchInput = (searchString: string) => {\n setSearchQuery(searchString);\n };\n\n /**\n * Whether to prevent radix's logic from closing the dropdown. This is important because radix\n * tries to close the dropdown when the input first focuses, and we don't want it to do that. But\n * we don't want to prevent the dropdown from closing when we click away from the input, so we\n * don't want to just keep it open if the input is focused\n */\n const shouldPreventAutoClosing = useRef(false);\n\n const controlMenuState = useCallback((open: boolean) => {\n if (shouldPreventAutoClosing.current) {\n shouldPreventAutoClosing.current = false;\n return;\n }\n setIsContentOpen(open);\n }, []);\n\n const updateReference = useCallback(\n (bookId: string, shouldClose: boolean, chapter?: number, verse?: number) => {\n setHighlightedChapter(\n Canon.bookNumberToId(scrRef.bookNum) !== bookId ? 1 : scrRef.chapterNum,\n );\n\n if (shouldClose || fetchEndChapter(bookId) === -1) {\n handleSubmit({\n bookNum: Canon.bookIdToNumber(bookId),\n chapterNum: chapter || 1,\n verseNum: verse || 1,\n });\n\n setIsContentOpen(false);\n setSearchQuery('');\n return;\n }\n\n setSelectedBookId(selectedBookId !== bookId ? bookId : '');\n setIsContentOpen(!shouldClose);\n },\n [handleSubmit, scrRef.bookNum, scrRef.chapterNum, selectedBookId],\n );\n\n const handleSelectChapter = (chapterNumber: number) => {\n if (chapterNumber <= 0 || chapterNumber > fetchEndChapter(selectedBookId)) {\n return;\n }\n updateReference(selectedBookId, true, chapterNumber);\n };\n\n const handleInputSubmit = useCallback(() => {\n SEARCH_QUERY_FORMATS.forEach((format) => {\n const matches = searchQuery.match(format);\n if (matches) {\n // Book should be a bookId or an english name\n const [book, chapter = undefined, verse = undefined] = matches.slice(1);\n const englishName = getBookIdFromEnglishName(book);\n\n if (Canon.isBookIdValid(book) || englishName) {\n updateReference(\n englishName ?? book,\n true,\n chapter ? parseInt(chapter, 10) : 1,\n verse ? parseInt(verse, 10) : 1,\n );\n }\n }\n });\n }, [updateReference, searchQuery]);\n\n const handleKeyDownInput = useCallback(\n (event: ReactKeyboardEvent) => {\n if (!isContentOpen) {\n setIsContentOpen(true);\n } else if (event.key === 'ArrowDown' || event.key === 'ArrowUp') {\n if (\n typeof menuItemRef !== 'undefined' &&\n // Ref uses null\n // eslint-disable-next-line no-null/no-null\n menuItemRef.current !== null\n ) {\n menuItemRef.current.focus();\n } else if (\n typeof contentRef !== 'undefined' &&\n // Ref uses null\n // eslint-disable-next-line no-null/no-null\n contentRef.current !== null\n ) {\n contentRef.current.focus();\n }\n event.preventDefault();\n }\n },\n [isContentOpen],\n );\n\n const handleKeyDownContent = (event: ReactKeyboardEvent) => {\n // When the dropdown menu has focus, key strokes should give focus to the input component,\n // unless they're navigation keys (arrows and enter)\n const { key } = event;\n if (\n key === 'ArrowRight' ||\n key === 'ArrowLeft' ||\n key === 'ArrowDown' ||\n key === 'ArrowUp' ||\n key === 'Enter'\n ) {\n return;\n }\n\n inputRef.current.dispatchEvent(new KeyboardEvent('keydown', { key }));\n inputRef.current.focus();\n };\n\n const handleKeyDownMenuItem = (event: ReactKeyboardEvent) => {\n const { key } = event;\n if (highlightedBookId === selectedBookId) {\n if (key === 'Enter') {\n event.preventDefault();\n updateReference(selectedBookId, true, highlightedChapter);\n return;\n }\n\n let chapterOffSet = 0;\n if (key === 'ArrowRight') {\n if (highlightedChapter < fetchEndChapter(highlightedBookId)) {\n chapterOffSet = 1;\n } else {\n event.preventDefault();\n return;\n }\n } else if (key === 'ArrowLeft') {\n if (highlightedChapter > 1) {\n chapterOffSet = -1;\n } else {\n event.preventDefault();\n return;\n }\n } else if (key === 'ArrowDown') {\n chapterOffSet = 6;\n } else if (key === 'ArrowUp') {\n chapterOffSet = -6;\n }\n if (\n highlightedChapter + chapterOffSet <= 0 ||\n highlightedChapter + chapterOffSet > fetchEndChapter(highlightedBookId)\n ) {\n setHighlightedChapter(0);\n } else if (chapterOffSet !== 0) {\n setHighlightedChapter(highlightedChapter + chapterOffSet);\n event.preventDefault();\n }\n }\n };\n\n useEffect(() => {\n if (selectedBookId === highlightedBookId) {\n if (selectedBookId === Canon.bookNumberToId(scrRef.bookNum)) {\n setHighlightedChapter(scrRef.chapterNum);\n } else {\n setHighlightedChapter(1);\n }\n } else {\n setHighlightedChapter(0);\n }\n }, [highlightedBookId, scrRef.bookNum, scrRef.chapterNum, selectedBookId]);\n\n // The purpose of these useLayoutEffects and timeout is to delay the scroll just\n // enough so that the refs are defined and available when they are used after the timeout\n useLayoutEffect(() => {\n setIsContentOpenDelayed(isContentOpen);\n }, [isContentOpen]);\n\n useLayoutEffect(() => {\n const scrollTimeout = setTimeout(() => {\n if (isContentOpenDelayed && contentRef.current && menuItemRef.current) {\n const menuItemOffsetTop = menuItemRef.current.offsetTop;\n const scrollPosition = menuItemOffsetTop - SCROLL_OFFSET;\n contentRef.current.scrollTo({ top: scrollPosition, behavior: 'instant' });\n }\n }, 10);\n return () => {\n clearTimeout(scrollTimeout);\n };\n }, [isContentOpenDelayed]);\n\n return (\n
    \n \n \n {\n setSelectedBookId(Canon.bookNumberToId(scrRef.bookNum));\n setHighlightedBookId(Canon.bookNumberToId(scrRef.bookNum));\n setHighlightedChapter(scrRef.chapterNum > 0 ? scrRef.chapterNum : 0);\n setIsContentOpen(true);\n inputRef.current.focus();\n }}\n onFocus={() => {\n // Radix thinks we want to close because the input is being focused. Prevent that\n shouldPreventAutoClosing.current = true;\n }}\n handleSubmit={handleInputSubmit}\n placeholder={`${Canon.bookNumberToEnglishName(scrRef.bookNum)} ${scrRef.chapterNum}:${scrRef.verseNum}`}\n />\n \n \n console.log('sorting')}\n handleLocationHistory={() => console.log('location history')}\n handleBookmarks={() => console.log('bookmarks')}\n />\n {BOOK_TYPE_ARRAY.map(\n (bookType, bookTypeIndex) =>\n fetchFilteredBooks(bookType).length > 0 && (\n
    \n \n {BOOK_TYPE_LABELS[bookType]}\n \n\n {fetchFilteredBooks(bookType).map((bookId) => (\n
    \n updateReference(bookId, false)}\n isSelected={selectedBookId === bookId}\n handleHighlightBook={() => setHighlightedBookId(bookId)}\n handleKeyDown={handleKeyDownMenuItem}\n bookType={bookType}\n ref={(element: HTMLDivElement) => {\n if (selectedBookId === bookId) menuItemRef.current = element;\n }}\n >\n {\n setHighlightedChapter(chapterNumber);\n }}\n />\n \n
    \n ))}\n {BOOK_TYPE_ARRAY.length - 1 !== bookTypeIndex ? (\n \n ) : undefined}\n
    \n ),\n )}\n \n
    \n
    \n );\n}\n\nexport default BookChapterControl;\n","import React from 'react';\nimport { Slot } from '@radix-ui/react-slot';\nimport { cva, type VariantProps } from 'class-variance-authority';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport const buttonVariants = cva(\n 'pr-twp tw-inline-flex tw-items-center tw-justify-center tw-whitespace-nowrap tw-rounded-md tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-colors focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50',\n {\n variants: {\n variant: {\n default: 'tw-bg-primary tw-text-primary-foreground hover:tw-bg-primary/90',\n destructive: 'tw-bg-destructive tw-text-destructive-foreground hover:tw-bg-destructive/90',\n outline:\n 'tw-border tw-border-input tw-bg-background hover:tw-bg-accent hover:tw-text-accent-foreground',\n secondary: 'tw-bg-secondary tw-text-secondary-foreground hover:tw-bg-secondary/80',\n ghost: 'hover:tw-bg-accent hover:tw-text-accent-foreground',\n link: 'tw-text-primary tw-underline-offset-4 hover:tw-underline',\n },\n size: {\n default: 'tw-h-10 tw-px-4 tw-py-2',\n sm: 'tw-h-9 tw-rounded-md tw-px-3',\n lg: 'tw-h-11 tw-rounded-md tw-px-8',\n icon: 'tw-h-10 tw-w-10',\n },\n },\n defaultVariants: {\n variant: 'default',\n size: 'default',\n },\n },\n);\n\nexport interface ButtonProps\n extends React.ButtonHTMLAttributes,\n VariantProps {\n asChild?: boolean;\n}\n\nexport const Button = React.forwardRef(\n ({ className, variant, size, asChild = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'button';\n return (\n \n );\n },\n);\nButton.displayName = 'Button';\n","import React from 'react';\nimport * as LabelPrimitive from '@radix-ui/react-label';\nimport { cva, type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst labelVariants = cva(\n 'tw-text-sm tw-font-medium tw-leading-none peer-disabled:tw-cursor-not-allowed peer-disabled:tw-opacity-70',\n);\n\nexport const Label = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef & VariantProps\n>(({ className, ...props }, ref) => (\n \n));\nLabel.displayName = LabelPrimitive.Root.displayName;\n","import React from 'react';\nimport * as RadioGroupPrimitive from '@radix-ui/react-radio-group';\nimport { Circle } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst RadioGroup = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => {\n return (\n \n );\n});\nRadioGroup.displayName = RadioGroupPrimitive.Root.displayName;\n\nconst RadioGroupItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => {\n return (\n \n \n \n \n \n );\n});\nRadioGroupItem.displayName = RadioGroupPrimitive.Item.displayName;\n\nexport { RadioGroup, RadioGroupItem };\n","import React from 'react';\nimport * as PopoverPrimitive from '@radix-ui/react-popover';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Popover = PopoverPrimitive.Root;\n\nconst PopoverTrigger = PopoverPrimitive.Trigger;\n\nconst PopoverContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, align = 'center', sideOffset = 4, ...props }, ref) => (\n \n \n \n));\nPopoverContent.displayName = PopoverPrimitive.Content.displayName;\n\nexport { Popover, PopoverTrigger, PopoverContent };\n","import React from 'react';\nimport * as DialogPrimitive from '@radix-ui/react-dialog';\nimport { X } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Dialog = DialogPrimitive.Root;\n\nconst DialogTrigger = DialogPrimitive.Trigger;\n\nconst DialogPortal = DialogPrimitive.Portal;\n\nconst DialogClose = DialogPrimitive.Close;\n\nconst DialogOverlay = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nDialogOverlay.displayName = DialogPrimitive.Overlay.displayName;\n\nconst DialogContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, ...props }, ref) => (\n \n \n \n {children}\n \n \n Close\n \n \n \n));\nDialogContent.displayName = DialogPrimitive.Content.displayName;\n\nfunction DialogHeader({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nDialogHeader.displayName = 'DialogHeader';\n\nfunction DialogFooter({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nDialogFooter.displayName = 'DialogFooter';\n\nconst DialogTitle = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nDialogTitle.displayName = DialogPrimitive.Title.displayName;\n\nconst DialogDescription = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nDialogDescription.displayName = DialogPrimitive.Description.displayName;\n\nexport {\n Dialog,\n DialogPortal,\n DialogOverlay,\n DialogClose,\n DialogTrigger,\n DialogContent,\n DialogHeader,\n DialogFooter,\n DialogTitle,\n DialogDescription,\n};\n","import React from 'react';\nimport { type DialogProps } from '@radix-ui/react-dialog';\nimport { Command as CommandPrimitive } from 'cmdk';\nimport { Search } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Dialog, DialogContent } from '@/components/shadcn-ui/dialog';\n\nconst Command = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nCommand.displayName = CommandPrimitive.displayName;\n\ninterface CommandDialogProps extends DialogProps {}\n\nfunction CommandDialog({ children, ...props }: CommandDialogProps) {\n return (\n \n \n \n {children}\n \n \n \n );\n}\n\nconst CommandInput = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n
    \n \n \n
    \n));\n\nCommandInput.displayName = CommandPrimitive.Input.displayName;\n\nconst CommandList = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\n\nCommandList.displayName = CommandPrimitive.List.displayName;\n\nconst CommandEmpty = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>((props, ref) => (\n \n));\n\nCommandEmpty.displayName = CommandPrimitive.Empty.displayName;\n\nconst CommandGroup = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\n\nCommandGroup.displayName = CommandPrimitive.Group.displayName;\n\nconst CommandSeparator = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nCommandSeparator.displayName = CommandPrimitive.Separator.displayName;\n\nconst CommandItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\n\nCommandItem.displayName = CommandPrimitive.Item.displayName;\n\nfunction CommandShortcut({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nCommandShortcut.displayName = 'CommandShortcut';\n\nexport {\n Command,\n CommandDialog,\n CommandInput,\n CommandList,\n CommandEmpty,\n CommandGroup,\n CommandItem,\n CommandShortcut,\n CommandSeparator,\n};\n","import { useState } from 'react';\nimport { Check, ChevronsUpDown } from 'lucide-react';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport { Popover, PopoverContent, PopoverTrigger } from '@/components/shadcn-ui/popover';\nimport {\n Command,\n CommandEmpty,\n CommandInput,\n CommandItem,\n CommandList,\n} from '@/components/shadcn-ui/command';\nimport { PopoverProps } from '@radix-ui/react-popover';\n\nexport type ComboBoxLabelOption = { label: string };\nexport type ComboBoxOption = string | number | ComboBoxLabelOption;\n\nexport type ComboBoxProps = {\n /** Optional unique identifier */\n id?: string;\n /** Text label title for combobox */\n /** List of available options for the dropdown menu */\n options?: readonly T[];\n /** Additional css classes to help with unique styling of the combo box */\n className?: string;\n /**\n * The selected value that the combo box currently holds. Must be shallow equal to one of the\n * options entries.\n */\n value?: T;\n /** Triggers when content of textfield is changed */\n onChange?: (newValue: T) => void;\n /** Used to determine the string value for a given option. */\n getOptionLabel?: (option: ComboBoxOption) => string;\n /** Text displayed on button if `value` is undefined */\n buttonPlaceholder?: string;\n /** Placeholder text for text field */\n textPlaceholder?: string;\n /** Text to display when no options match input */\n commandEmptyMessage?: string;\n /** Variant of button */\n buttonVariant?: ButtonProps['variant'];\n /** Text direction ltr or rtl */\n dir?: Direction;\n /** Optional boolean to set if trigger should be disabled */\n isDisabled?: boolean;\n} & PopoverProps;\n\ntype Direction = 'ltr' | 'rtl';\n\nfunction getOptionLabelDefault(option: ComboBoxOption): string {\n if (typeof option === 'string') {\n return option;\n }\n if (typeof option === 'number') {\n return option.toString();\n }\n return option.label;\n}\n\n/**\n * Autocomplete input and command palette with a list of suggestions.\n *\n * Thanks to Shadcn for heavy inspiration and documentation\n * https://ui.shadcn.com/docs/components/combobox\n */\nfunction ComboBox({\n id,\n options = [],\n className,\n value,\n onChange = () => {},\n getOptionLabel = getOptionLabelDefault,\n buttonPlaceholder = '',\n textPlaceholder = '',\n commandEmptyMessage = 'No option found',\n buttonVariant = 'outline',\n dir = 'ltr',\n isDisabled = false,\n ...props\n}: ComboBoxProps) {\n const [open, setOpen] = useState(false);\n\n return (\n \n \n \n \n {value ? getOptionLabel(value) : buttonPlaceholder}\n \n \n \n \n \n \n \n {commandEmptyMessage}\n \n {options.map((option) => (\n {\n onChange(option);\n setOpen(false);\n }}\n >\n \n {getOptionLabel(option)}\n \n ))}\n \n \n \n \n );\n}\n\nexport default ComboBox;\n","import { useMemo } from 'react';\nimport ComboBox from '@/components/basics/combo-box.component';\nimport { Label } from '@/components/shadcn-ui/label';\n\nexport type ChapterRangeSelectorProps = {\n startChapter: number;\n endChapter: number;\n handleSelectStartChapter: (chapter: number) => void;\n handleSelectEndChapter: (chapter: number) => void;\n isDisabled?: boolean;\n chapterCount: number;\n};\n\nexport default function ChapterRangeSelector({\n startChapter,\n endChapter,\n handleSelectStartChapter,\n handleSelectEndChapter,\n isDisabled = false,\n chapterCount,\n}: ChapterRangeSelectorProps) {\n const chapterOptions = useMemo(\n () => Array.from({ length: chapterCount }, (_, index) => index + 1),\n [chapterCount],\n );\n\n const onChangeStartChapter = (value: number) => {\n handleSelectStartChapter(value);\n if (value > endChapter) {\n handleSelectEndChapter(value);\n }\n };\n\n const onChangeEndChapter = (value: number) => {\n handleSelectEndChapter(value);\n if (value < startChapter) {\n handleSelectStartChapter(value);\n }\n };\n\n return (\n <>\n \n option.toString()}\n value={startChapter}\n />\n\n \n option.toString()}\n value={endChapter}\n />\n \n );\n}\n","import { Button } from '@/components/shadcn-ui/button';\nimport { Label } from '@/components/shadcn-ui/label';\nimport { RadioGroup, RadioGroupItem } from '@/components/shadcn-ui/radio-group';\nimport { Canon } from '@sillsdev/scripture';\nimport { LocalizedStringValue } from 'platform-bible-utils';\nimport { useState } from 'react';\nimport ChapterRangeSelector, {\n ChapterRangeSelectorProps,\n} from '../basics/chapter-range-selector.component';\n\nexport enum BookSelectionMode {\n CURRENT_BOOK = 'current book',\n CHOOSE_BOOKS = 'choose books',\n}\n\n/**\n * Object containing all keys used for localization in this component. If you're using this\n * component in an extension, you can pass it into the useLocalizedStrings hook to easily obtain the\n * localized strings and pass them into the localizedStrings prop of this component\n */\nexport const BOOK_SELECTOR_STRING_KEYS = Object.freeze([\n '%webView_bookSelector_currentBook%',\n '%webView_bookSelector_choose%',\n '%webView_bookSelector_chooseBooks%',\n] as const);\n\nexport type BookSelectorLocalizedStrings = {\n [localizedInventoryKey in (typeof BOOK_SELECTOR_STRING_KEYS)[number]]?: LocalizedStringValue;\n};\n\n/**\n * Gets the localized value for the provided key\n *\n * @param strings Object containing localized string\n * @param key Key for a localized string\n * @returns The localized value for the provided key, if available. Returns the key if no localized\n * value is available\n */\nconst localizeString = (\n strings: BookSelectorLocalizedStrings,\n key: keyof BookSelectorLocalizedStrings,\n) => {\n return strings[key] ?? key;\n};\n\ntype BookSelectorProps = ChapterRangeSelectorProps & {\n handleBookSelectionModeChange: (newMode: BookSelectionMode) => void;\n currentBookName: string;\n onSelectBooks: () => void;\n selectedBookIds: string[];\n localizedStrings: BookSelectorLocalizedStrings;\n};\n\nexport default function BookSelector({\n handleBookSelectionModeChange,\n currentBookName,\n onSelectBooks,\n selectedBookIds,\n chapterCount,\n endChapter,\n handleSelectEndChapter,\n startChapter,\n handleSelectStartChapter,\n localizedStrings,\n}: BookSelectorProps) {\n const currentBookText = localizeString(localizedStrings, '%webView_bookSelector_currentBook%');\n const chooseText = localizeString(localizedStrings, '%webView_bookSelector_choose%');\n const chooseBooksText = localizeString(localizedStrings, '%webView_bookSelector_chooseBooks%');\n\n const [bookSelectionMode, setBookSelectionMode] = useState(\n BookSelectionMode.CURRENT_BOOK,\n );\n\n const onSelectionModeChange = (newMode: BookSelectionMode) => {\n setBookSelectionMode(newMode);\n handleBookSelectionModeChange(newMode);\n };\n\n return (\n onSelectionModeChange(value as BookSelectionMode)}\n >\n
    \n
    \n
    \n \n \n
    \n \n
    \n \n
    \n
    \n
    \n
    \n \n \n
    \n \n onSelectBooks()}\n >\n {chooseText}\n \n
    \n
    \n \n );\n}\n","import { DropdownMenuTrigger } from '@radix-ui/react-dropdown-menu';\nimport { FilterIcon } from 'lucide-react';\nimport { Table } from '@tanstack/react-table';\n\nimport { Button } from '@/components/shadcn-ui/button';\nimport {\n DropdownMenu,\n DropdownMenuCheckboxItem,\n DropdownMenuContent,\n DropdownMenuLabel,\n DropdownMenuSeparator,\n} from '@/components/shadcn-ui/dropdown-menu';\n\ninterface DataTableViewOptionsProps {\n table: Table;\n}\n\nfunction DataTableViewOptions({ table }: DataTableViewOptionsProps) {\n return (\n \n \n \n \n \n Toggle columns\n \n {table\n .getAllColumns()\n .filter((column) => column.getCanHide())\n .map((column) => {\n return (\n column.toggleVisibility(!!value)}\n >\n {column.id}\n \n );\n })}\n \n \n );\n}\n\nexport default DataTableViewOptions;\n","import React from 'react';\nimport * as SelectPrimitive from '@radix-ui/react-select';\nimport { Check, ChevronDown, ChevronUp } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Select = SelectPrimitive.Root;\n\nconst SelectGroup = SelectPrimitive.Group;\n\nconst SelectValue = SelectPrimitive.Value;\n\nconst SelectTrigger = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, ...props }, ref) => (\n span]:tw-line-clamp-1',\n className,\n )}\n {...props}\n >\n {children}\n \n \n \n \n));\nSelectTrigger.displayName = SelectPrimitive.Trigger.displayName;\n\nconst SelectScrollUpButton = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n));\nSelectScrollUpButton.displayName = SelectPrimitive.ScrollUpButton.displayName;\n\nconst SelectScrollDownButton = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n));\nSelectScrollDownButton.displayName = SelectPrimitive.ScrollDownButton.displayName;\n\nconst SelectContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, position = 'popper', ...props }, ref) => (\n \n \n \n \n {children}\n \n \n \n \n));\nSelectContent.displayName = SelectPrimitive.Content.displayName;\n\nconst SelectLabel = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSelectLabel.displayName = SelectPrimitive.Label.displayName;\n\nconst SelectItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, ...props }, ref) => (\n \n \n \n \n \n \n\n {children}\n \n));\nSelectItem.displayName = SelectPrimitive.Item.displayName;\n\nconst SelectSeparator = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSelectSeparator.displayName = SelectPrimitive.Separator.displayName;\n\nexport {\n Select,\n SelectGroup,\n SelectValue,\n SelectTrigger,\n SelectContent,\n SelectLabel,\n SelectItem,\n SelectSeparator,\n SelectScrollUpButton,\n SelectScrollDownButton,\n};\n","import { ChevronLeftIcon, ChevronRightIcon, ArrowLeftIcon, ArrowRightIcon } from 'lucide-react';\nimport { Table } from '@tanstack/react-table';\n\nimport { Button } from '@/components/shadcn-ui/button';\nimport {\n Select,\n SelectContent,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\n\ninterface DataTablePaginationProps {\n table: Table;\n}\n\nfunction DataTablePagination({ table }: DataTablePaginationProps) {\n return (\n
    \n
    \n
    \n {table.getFilteredSelectedRowModel().rows.length} of{' '}\n {table.getFilteredRowModel().rows.length} row(s) selected\n
    \n
    \n

    Rows per page

    \n {\n table.setPageSize(Number(value));\n }}\n >\n \n \n \n \n {[10, 20, 30, 40, 50].map((pageSize) => (\n \n {pageSize}\n \n ))}\n \n \n
    \n
    \n Page {table.getState().pagination.pageIndex + 1} of {table.getPageCount()}\n
    \n
    \n table.setPageIndex(0)}\n disabled={!table.getCanPreviousPage()}\n >\n Go to first page\n \n \n table.previousPage()}\n disabled={!table.getCanPreviousPage()}\n >\n Go to previous page\n \n \n table.nextPage()}\n disabled={!table.getCanNextPage()}\n >\n Go to next page\n \n \n table.setPageIndex(table.getPageCount() - 1)}\n disabled={!table.getCanNextPage()}\n >\n Go to last page\n \n \n
    \n
    \n
    \n );\n}\n\nexport default DataTablePagination;\n","import React from 'react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Table = React.forwardRef<\n HTMLTableElement,\n React.HTMLAttributes & { stickyHeader?: boolean }\n>(({ className, stickyHeader, ...props }, ref) => (\n
    \n \n
    \n));\nTable.displayName = 'Table';\n\nconst TableHeader = React.forwardRef<\n HTMLTableSectionElement,\n React.HTMLAttributes & { stickyHeader?: boolean }\n>(({ className, stickyHeader, ...props }, ref) => (\n \n));\nTableHeader.displayName = 'TableHeader';\n\nconst TableBody = React.forwardRef<\n HTMLTableSectionElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableBody.displayName = 'TableBody';\n\nconst TableFooter = React.forwardRef<\n HTMLTableSectionElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n tr]:last:tw-border-b-0', className)}\n {...props}\n />\n));\nTableFooter.displayName = 'TableFooter';\n\nconst TableRow = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nTableRow.displayName = 'TableRow';\n\nconst TableHead = React.forwardRef<\n HTMLTableCellElement,\n React.ThHTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableHead.displayName = 'TableHead';\n\nconst TableCell = React.forwardRef<\n HTMLTableCellElement,\n React.TdHTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableCell.displayName = 'TableCell';\n\nconst TableCaption = React.forwardRef<\n HTMLTableCaptionElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableCaption.displayName = 'TableCaption';\n\nexport { Table, TableHeader, TableBody, TableFooter, TableHead, TableRow, TableCell, TableCaption };\n","import { useState } from 'react';\n\nimport {\n ColumnFiltersState,\n flexRender,\n getCoreRowModel,\n getFilteredRowModel,\n getPaginationRowModel,\n getSortedRowModel,\n SortingState,\n ColumnDef as TSColumnDef,\n Row as TSRow,\n RowSelectionState as TSRowSelectionState,\n SortDirection as TSSortDirection,\n Table as TSTable,\n useReactTable,\n VisibilityState,\n} from '@tanstack/react-table';\n\nimport DataTableViewOptions from '@/components/advanced/data-table/data-table-column-toggle.component';\nimport DataTablePagination from '@/components/advanced/data-table/data-table-pagination.component';\nimport { Button } from '@/components/shadcn-ui/button';\nimport {\n Table,\n TableBody,\n TableCell,\n TableHead,\n TableHeader,\n TableRow,\n} from '@/components/shadcn-ui/table';\n\nexport type ColumnDef = TSColumnDef;\nexport type RowContents = TSRow;\nexport type TableContents = TSTable;\nexport type SortDirection = TSSortDirection;\nexport type RowSelectionState = TSRowSelectionState;\n\ninterface DataTableProps {\n columns: ColumnDef[];\n data: TData[];\n enablePagination?: boolean;\n showPaginationControls?: boolean;\n showColumnVisibilityControls?: boolean;\n stickyHeader?: boolean;\n onRowClickHandler?: (row: RowContents, table: TableContents) => void;\n}\n\n/**\n * Feature-rich table component that infuses our basic shadcn-based Table component with features\n * from TanStack's React Table library\n */\nfunction DataTable({\n columns,\n data,\n enablePagination = false,\n showPaginationControls = false,\n showColumnVisibilityControls = false,\n stickyHeader = false,\n onRowClickHandler = () => {},\n}: DataTableProps) {\n const [sorting, setSorting] = useState([]);\n const [columnFilters, setColumnFilters] = useState([]);\n const [columnVisibility, setColumnVisibility] = useState({});\n const [rowSelection, setRowSelection] = useState({});\n\n const table = useReactTable({\n data,\n columns,\n getCoreRowModel: getCoreRowModel(),\n ...(enablePagination && { getPaginationRowModel: getPaginationRowModel() }),\n onSortingChange: setSorting,\n getSortedRowModel: getSortedRowModel(),\n onColumnFiltersChange: setColumnFilters,\n getFilteredRowModel: getFilteredRowModel(),\n onColumnVisibilityChange: setColumnVisibility,\n onRowSelectionChange: setRowSelection,\n state: {\n sorting,\n columnFilters,\n columnVisibility,\n rowSelection,\n },\n });\n\n return (\n
    \n {showColumnVisibilityControls && }\n \n \n {table.getHeaderGroups().map((headerGroup) => (\n \n {headerGroup.headers.map((header) => {\n return (\n \n {header.isPlaceholder\n ? undefined\n : flexRender(header.column.columnDef.header, header.getContext())}\n \n );\n })}\n \n ))}\n \n \n {table.getRowModel().rows?.length ? (\n table.getRowModel().rows.map((row) => (\n onRowClickHandler(row, table)}\n key={row.id}\n data-state={row.getIsSelected() && 'selected'}\n >\n {row.getVisibleCells().map((cell) => (\n \n {flexRender(cell.column.columnDef.cell, cell.getContext())}\n \n ))}\n \n ))\n ) : (\n \n \n No results.\n \n \n )}\n \n
    \n {enablePagination && (\n
    \n table.previousPage()}\n disabled={!table.getCanPreviousPage()}\n >\n Previous\n \n table.nextPage()}\n disabled={!table.getCanNextPage()}\n >\n Next\n \n
    \n )}\n {enablePagination && showPaginationControls && }\n
    \n );\n}\n\nexport default DataTable;\n","import {\n Table,\n TableBody,\n TableCell,\n TableHead,\n TableHeader,\n TableRow,\n} from '@/components/shadcn-ui/table';\nimport { Canon } from '@sillsdev/scripture';\nimport { deepEqual, LanguageStrings, ScriptureReference } from 'platform-bible-utils';\nimport { useMemo } from 'react';\nimport { InventoryItemOccurrence } from './inventory-utils';\n\n/** Props for the OccurrencesTable component */\ntype OccurrencesTableProps = {\n /** Data that contains scriptures references and snippets of scripture */\n occurrenceData: InventoryItemOccurrence[];\n /** Callback function that is executed when the scripture reference is changed */\n setScriptureReference: (scriptureReference: ScriptureReference) => void;\n /**\n * Object with all localized strings that the OccurrencesTable needs to work well across multiple\n * languages\n */\n localizedStrings: LanguageStrings;\n};\n\n/**\n * Table that shows occurrences of specified inventory item(s). The first column shows the related\n * scripture reference. The second column shows the snippet of scripture that contains the specified\n * inventory item\n */\nfunction OccurrencesTable({\n occurrenceData,\n setScriptureReference,\n localizedStrings,\n}: OccurrencesTableProps) {\n const referenceHeaderText =\n localizedStrings['%webView_inventory_occurrences_table_header_reference%'];\n const occurrenceHeaderText =\n localizedStrings['%webView_inventory_occurrences_table_header_occurrence%'];\n\n const occurrences: InventoryItemOccurrence[] = useMemo(() => {\n const uniqueOccurrences: InventoryItemOccurrence[] = [];\n\n occurrenceData.forEach((occurrence) => {\n if (!uniqueOccurrences.some((uniqueOccurrence) => deepEqual(uniqueOccurrence, occurrence))) {\n uniqueOccurrences.push(occurrence);\n }\n });\n\n return uniqueOccurrences;\n }, [occurrenceData]);\n\n return (\n \n \n \n {referenceHeaderText}\n {occurrenceHeaderText}\n \n \n \n {occurrences.length > 0 &&\n occurrences.map((occurrence) => (\n {\n setScriptureReference(occurrence.reference);\n }}\n >\n {`${Canon.bookNumberToEnglishName(occurrence.reference.bookNum)} ${occurrence.reference.chapterNum}:${occurrence.reference.verseNum}`}\n {occurrence.text}\n \n ))}\n \n
    \n );\n}\n\nexport default OccurrencesTable;\n","import React from 'react';\nimport * as CheckboxPrimitive from '@radix-ui/react-checkbox';\nimport { Check } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Checkbox = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n \n \n));\nCheckbox.displayName = CheckboxPrimitive.Root.displayName;\n\nexport default Checkbox;\n","import { Canon } from '@sillsdev/scripture';\nimport { ScriptureReference } from 'platform-bible-utils';\n\n/* #region Types */\n\n/**\n * Status of items that appear in inventories. 'approved' and 'unapproved' items are defined in the\n * project's `Settings.xml`. All other items are defined as 'unknown'\n */\nexport type Status = 'approved' | 'unapproved' | 'unknown';\n\n/** Occurrence of item in inventory. Primarily used by table that shows occurrences */\nexport type InventoryItemOccurrence = {\n /** Reference to scripture where the item appears */\n reference: ScriptureReference;\n /** Snippet of scripture that contains the occurrence */\n text: string;\n};\n\n/** Data structure that contains all information on an item that is shown in an inventory */\nexport type InventoryTableData = {\n /**\n * The item (e.g. a character in the characters inventory, a marker in the marker inventory) In\n * most cases the array will only have one element. In case of additional items (e.g. the\n * preceding marker in the markers check), the primary item should be stored in the first index.\n * To show additional items in the inventory, make sure to configure the `additionalItemsLabels`\n * prop for the Inventory component\n */\n items: string[];\n /** The number of times this item occurs in the selected scope */\n count: number;\n /** The status of this item (see documentation for `Status` type for more information) */\n status: Status;\n /** Occurrences of this item in the scripture text for the selected scope */\n occurrences: InventoryItemOccurrence[];\n};\n\n/* #endregion */\n\n/* #region Functions */\n\n/**\n * Splits USFM string into shorter line-like segments\n *\n * @param text A single (likely very large) USFM string\n * @returns An array containing the input text, split into shorter segments\n */\nexport const getLinesFromUSFM = (text: string) => {\n // Splits on (CR)LF, CR, \\v, \\c and \\id\n return text.split(/(?:\\r?\\n|\\r)|(?=(?:\\\\(?:v|c|id)))/g);\n};\n\n/**\n * Extracts chapter or verse number from USFM strings that start with a \\c or \\v marker\n *\n * @param text USFM string that is expected to start with \\c or \\v marker\n * @returns Chapter or verse number if one is found. Else returns 0.\n */\nexport const getNumberFromUSFM = (text: string): number | undefined => {\n // Captures all digits that follow \\v or \\c markers followed by whitespace located at the start of a string\n const regex = /^\\\\[vc]\\s+(\\d+)/;\n const match = text.match(regex);\n\n if (match) {\n return +match[1];\n }\n return undefined;\n};\n\n/**\n * Gets book ID from USFM string that starts with the \\id marker, and returns book number for it\n *\n * @param text USFM string that is expected to start with \\id marker\n * @returns Book number corresponding to the \\id marker in the input text. Returns 0 if no marker is\n * found or the marker is not valid\n */\nexport const getBookNumFromId = (text: string): number => {\n // Captures all digits that follow an \\id marker followed by whitespace located at the start of a string\n const match = text.match(/^\\\\id\\s+([A-Za-z]+)/);\n if (match) {\n return Canon.bookIdToNumber(match[1]);\n }\n return 0;\n};\n\n/**\n * Gets the status for an item, typically used in the Inventory component\n *\n * @param item The item for which the status is being requested\n * @param approvedItems Array of approved items, typically as defined in `Settings.xml`\n * @param unapprovedItems Array of unapproved items, typically as defined in `Settings.xml`\n * @returns The status for the specified item\n */\nexport const getStatusForItem = (\n item: string,\n approvedItems: string[],\n unapprovedItems: string[],\n): Status => {\n if (unapprovedItems.includes(item)) return 'unapproved';\n if (approvedItems.includes(item)) return 'approved';\n return 'unknown';\n};\n\n/* #endregion */\n","import React from 'react';\nimport * as TogglePrimitive from '@radix-ui/react-toggle';\nimport { cva, type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst toggleVariants = cva(\n 'pr-twp tw-inline-flex tw-items-center tw-justify-center tw-rounded-md tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-colors hover:tw-bg-muted hover:tw-text-muted-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50 data-[state=on]:tw-bg-accent data-[state=on]:tw-text-accent-foreground',\n {\n variants: {\n variant: {\n default: 'tw-bg-transparent',\n outline:\n 'tw-border tw-border-input tw-bg-transparent hover:tw-bg-accent hover:tw-text-accent-foreground',\n },\n size: {\n default: 'tw-h-10 tw-px-3',\n sm: 'tw-h-9 tw-px-2.5',\n lg: 'tw-h-11 tw-px-5',\n },\n },\n defaultVariants: {\n variant: 'default',\n size: 'default',\n },\n },\n);\n\nconst Toggle = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef & VariantProps\n>(({ className, variant, size, ...props }, ref) => (\n \n));\n\nToggle.displayName = TogglePrimitive.Root.displayName;\n\nexport { Toggle, toggleVariants };\n","import React from 'react';\nimport * as ToggleGroupPrimitive from '@radix-ui/react-toggle-group';\nimport { type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { toggleVariants } from '@/components/shadcn-ui/toggle';\n\nconst ToggleGroupContext = React.createContext>({\n size: 'default',\n variant: 'default',\n});\n\nconst ToggleGroup = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef &\n VariantProps\n>(({ className, variant, size, children, ...props }, ref) => (\n \n \n {children}\n \n \n));\n\nToggleGroup.displayName = ToggleGroupPrimitive.Root.displayName;\n\nconst ToggleGroupItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef &\n VariantProps\n>(({ className, children, variant, size, ...props }, ref) => {\n const context = React.useContext(ToggleGroupContext);\n\n return (\n \n {children}\n \n );\n});\n\nToggleGroupItem.displayName = ToggleGroupPrimitive.Item.displayName;\n\nexport { ToggleGroup, ToggleGroupItem };\n","import { ColumnDef, SortDirection } from '@/components/advanced/data-table/data-table.component';\nimport { Button } from '@/components/shadcn-ui/button';\nimport { ToggleGroup, ToggleGroupItem } from '@/components/shadcn-ui/toggle-group';\nimport {\n ArrowDownIcon,\n ArrowUpDownIcon,\n ArrowUpIcon,\n CircleCheckIcon,\n CircleHelpIcon,\n CircleXIcon,\n} from 'lucide-react';\nimport { ReactNode } from 'react';\nimport { InventoryTableData, Status } from './inventory-utils';\n\n/**\n * Gets an icon that indicates the current sorting direction based on the provided input\n *\n * @param sortDirection Sorting direction. Can be ascending ('asc'), descending ('desc') or false (\n * i.e. not sorted)\n * @returns The appropriate sorting icon for the provided sorting direction\n */\nconst getSortingIcon = (sortDirection: false | SortDirection): ReactNode => {\n if (sortDirection === 'asc') {\n return ;\n }\n if (sortDirection === 'desc') {\n return ;\n }\n return ;\n};\n\n/**\n * Function that creates the item column for inventories\n *\n * @param itemLabel Localized label for the item column (e.g. 'Character', 'Repeated Word', etc.)\n * @returns Column that shows the inventory items. Should be used with the DataTable component\n */\nexport const inventoryItemColumn = (itemLabel: string): ColumnDef => {\n return {\n accessorKey: 'item',\n accessorFn: (row: InventoryTableData) => row.items[0],\n header: ({ column }) => (\n \n ),\n };\n};\n\n/**\n * Function that creates the additional item columns for inventories\n *\n * @param additionalItemLabel Localized label for the additional item column (e.g. 'Preceding\n * Marker')\n * @param additionalItemIndex Index that locates the desired item in the items array of the\n * inventory\n * @returns Column that shows additional inventory items. Should be used with the DataTable\n * component\n */\nexport const inventoryAdditionalItemColumn = (\n additionalItemLabel: string,\n additionalItemIndex: number,\n): ColumnDef => {\n return {\n accessorKey: `item${additionalItemIndex}`,\n accessorFn: (row: InventoryTableData) => row.items[additionalItemIndex],\n header: ({ column }) => (\n \n ),\n };\n};\n\n/**\n * Function that creates the count column for inventories. Should be used with the DataTable\n * component.\n *\n * @param itemLabel Localized label for the count column\n * @returns Column that shows the number of occurrences of the related inventory items\n */\nexport const inventoryCountColumn = (countLabel: string): ColumnDef => {\n return {\n accessorKey: 'count',\n header: ({ column }) => (\n
    \n \n
    \n ),\n cell: ({ row }) =>
    {row.getValue('count')}
    ,\n };\n};\n\n/**\n * Function that updates project settings when status for item(s) changes\n *\n * @param changedItems Array of items for which the status is being updated\n * @param newStatus The status that the items are being given\n * @param approvedItems Array of currently approved items\n * @param onApprovedItemsChange Callback function that stores the updated list of approved items\n * @param unapprovedItems Array of currently unapproved items\n * @param onUnapprovedItemsChange Callback function that stores the updated list of unapproved items\n */\nconst statusChangeHandler = (\n changedItems: string[],\n newStatus: Status,\n approvedItems: string[],\n onApprovedItemsChange: (items: string[]) => void,\n unapprovedItems: string[],\n onUnapprovedItemsChange: (items: string[]) => void,\n) => {\n let newApprovedItems: string[] = [...approvedItems];\n changedItems.forEach((item) => {\n if (newStatus === 'approved') {\n if (!newApprovedItems.includes(item)) {\n newApprovedItems.push(item);\n }\n } else {\n newApprovedItems = newApprovedItems.filter((validItem) => validItem !== item);\n }\n });\n onApprovedItemsChange(newApprovedItems);\n\n let newUnapprovedItems: string[] = [...unapprovedItems];\n changedItems.forEach((item) => {\n if (newStatus === 'unapproved') {\n if (!newUnapprovedItems.includes(item)) {\n newUnapprovedItems.push(item);\n }\n } else {\n newUnapprovedItems = newUnapprovedItems.filter((unapprovedItem) => unapprovedItem !== item);\n }\n });\n onUnapprovedItemsChange(newUnapprovedItems);\n};\n\n/**\n * Function that creates the status column for inventories. Should be used with the DataTable\n * component.\n *\n * @param statusLabel Localized label for the status column\n * @param approvedItems Array of approved items, typically as defined in `Settings.xml`\n * @param onApprovedItemsChange Callback function that stores the updated list of approved items\n * @param unapprovedItems Array of unapproved items, typically as defined in `Settings.xml`\n * @param onUnapprovedItemsChange Callback function that stores the updated list of unapproved items\n * @returns Column that shows the status buttons for the related inventory item. The button for the\n * current status of the item is selected\n */\nexport const inventoryStatusColumn = (\n statusLabel: string,\n approvedItems: string[],\n onApprovedItemsChange: (items: string[]) => void,\n unapprovedItems: string[],\n onUnapprovedItemsChange: (items: string[]) => void,\n): ColumnDef => {\n return {\n accessorKey: 'status',\n header: ({ column }) => {\n return (\n
    \n \n
    \n );\n },\n cell: ({ row }) => {\n const status: Status = row.getValue('status');\n const item: string = row.getValue('item');\n return (\n \n \n statusChangeHandler(\n [item],\n 'approved',\n approvedItems,\n onApprovedItemsChange,\n unapprovedItems,\n onUnapprovedItemsChange,\n )\n }\n value=\"approved\"\n >\n \n \n \n statusChangeHandler(\n [item],\n 'unapproved',\n approvedItems,\n onApprovedItemsChange,\n unapprovedItems,\n onUnapprovedItemsChange,\n )\n }\n value=\"unapproved\"\n >\n \n \n \n statusChangeHandler(\n [item],\n 'unknown',\n approvedItems,\n onApprovedItemsChange,\n unapprovedItems,\n onUnapprovedItemsChange,\n )\n }\n value=\"unknown\"\n >\n \n \n \n );\n },\n };\n};\n","import DataTable, {\n ColumnDef,\n RowContents,\n RowSelectionState,\n TableContents,\n} from '@/components/advanced/data-table/data-table.component';\nimport OccurrencesTable from '@/components/advanced/inventory/occurrences-table.component';\nimport Checkbox from '@/components/shadcn-ui/checkbox';\nimport { Input } from '@/components/shadcn-ui/input';\nimport { Label } from '@/components/shadcn-ui/label';\nimport {\n Select,\n SelectContent,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\nimport {\n deepEqual,\n LocalizedStringValue,\n ScriptureReference,\n substring,\n} from 'platform-bible-utils';\nimport { useEffect, useMemo, useState } from 'react';\nimport {\n getBookNumFromId,\n getLinesFromUSFM,\n getNumberFromUSFM,\n getStatusForItem,\n InventoryItemOccurrence,\n InventoryTableData,\n Status,\n} from './inventory-utils';\nimport { inventoryAdditionalItemColumn } from './inventory-columns';\n\n/**\n * Object containing all keys used for localization in this component. If you're using this\n * component in an extension, you can pass it into the useLocalizedStrings hook to easily obtain the\n * localized strings and pass them into the localizedStrings prop of this component\n */\nexport const INVENTORY_STRING_KEYS = Object.freeze([\n '%webView_inventory_all%',\n '%webView_inventory_approved%',\n '%webView_inventory_unapproved%',\n '%webView_inventory_unknown%',\n '%webView_inventory_scope_currentBook%',\n '%webView_inventory_scope_chapter%',\n '%webView_inventory_scope_verse%',\n '%webView_inventory_filter_text%',\n '%webView_inventory_show_additional_items%',\n '%webView_inventory_occurrences_table_header_reference%',\n '%webView_inventory_occurrences_table_header_occurrence%',\n] as const);\n\nexport type InventoryLocalizedStrings = {\n [localizedInventoryKey in (typeof INVENTORY_STRING_KEYS)[number]]?: LocalizedStringValue;\n};\n\n/** Scope of scripture that the inventory can operate on */\nexport type Scope = 'book' | 'chapter' | 'verse';\n\n/** Status values that the status filter can select from */\ntype StatusFilter = Status | 'all';\n\n/** Text labels for the inventory columns and the control components of additional inventory items */\ntype AdditionalItemsLabels = {\n checkboxText?: string;\n tableHeaders?: string[];\n};\n\n/**\n * Filters data that is shown in the DataTable section of the Inventory\n *\n * @param itemData All inventory items and their related information\n * @param statusFilter Allows filtering by status (i.e. show all items, or only items that are\n * 'approved', 'unapproved' or 'unknown')\n * @param textFilter Allows filtering by text. All items that include the filter text will be\n * selected.\n * @returns Array of items and their related information that are matched by the specified filters\n */\nconst filterItemData = (\n itemData: InventoryTableData[],\n statusFilter: StatusFilter,\n textFilter: string,\n): InventoryTableData[] => {\n let filteredItemData: InventoryTableData[] = itemData;\n\n if (statusFilter !== 'all') {\n filteredItemData = filteredItemData.filter(\n (item) =>\n (statusFilter === 'approved' && item.status === 'approved') ||\n (statusFilter === 'unapproved' && item.status === 'unapproved') ||\n (statusFilter === 'unknown' && item.status === 'unknown'),\n );\n }\n\n if (textFilter !== '')\n filteredItemData = filteredItemData.filter((item) => item.items[0].includes(textFilter));\n\n return filteredItemData;\n};\n\n/**\n * Turns array of strings into array of inventory items, along with their count and status\n *\n * @param text The source scripture text that is searched for inventory items\n * @param scriptureRef The scripture reference that the application is currently set to\n * @param approvedItems Array of approved items, typically as defined in `Settings.xml`\n * @param unapprovedItems Array of unapproved items, typically as defined in `Settings.xml`\n * @param itemRegex Regular expression that describes what items this Inventory should extract from\n * the provided scripture text\n * @returns Array of inventory items, along with their count and status\n */\nconst createTableData = (\n text: string | undefined,\n scriptureRef: ScriptureReference,\n approvedItems: string[],\n unapprovedItems: string[],\n itemRegex: RegExp,\n): InventoryTableData[] => {\n if (!text) return [];\n\n const tableData: InventoryTableData[] = [];\n\n let currentBook: number | undefined = scriptureRef.bookNum;\n let currentChapter: number | undefined = scriptureRef.chapterNum;\n let currentVerse: number | undefined = scriptureRef.verseNum;\n\n const lines = getLinesFromUSFM(text);\n\n lines.forEach((line: string) => {\n if (line.startsWith('\\\\id')) {\n currentBook = getBookNumFromId(line);\n currentChapter = 0;\n currentVerse = 0;\n }\n if (line.startsWith('\\\\c')) {\n currentChapter = getNumberFromUSFM(line);\n currentVerse = 0;\n }\n if (line.startsWith('\\\\v')) {\n currentVerse = getNumberFromUSFM(line);\n if (currentChapter === 0) {\n currentChapter = scriptureRef.chapterNum;\n }\n }\n\n let match: RegExpExecArray | undefined = itemRegex.exec(line) ?? undefined;\n while (match) {\n const items: string[] = [];\n match.forEach((item) => items.push(item));\n const itemIndex = match.index;\n const existingItem = tableData.find((tableEntry) => deepEqual(tableEntry.items, items));\n const newReference: InventoryItemOccurrence = {\n reference: {\n bookNum: currentBook !== undefined ? currentBook : -1,\n chapterNum: currentChapter !== undefined ? currentChapter : -1,\n verseNum: currentVerse !== undefined ? currentVerse : -1,\n },\n text: substring(line, Math.max(0, itemIndex - 25), Math.min(itemIndex + 25, line.length)),\n };\n if (existingItem) {\n existingItem.count += 1;\n existingItem.occurrences.push(newReference);\n } else {\n const newItem: InventoryTableData = {\n items,\n count: 1,\n status: getStatusForItem(items[0], approvedItems, unapprovedItems),\n occurrences: [newReference],\n };\n tableData.push(newItem);\n }\n\n match = itemRegex.exec(line) ?? undefined;\n }\n });\n\n return tableData;\n};\n\n/**\n * Gets the localized value for the provided key\n *\n * @param strings Object containing localized string\n * @param key Key for a localized string\n * @returns The localized value for the provided key, if available. Returns the key if no localized\n * value is available\n */\nconst localizeString = (\n strings: InventoryLocalizedStrings,\n key: keyof InventoryLocalizedStrings,\n) => {\n return strings[key] ?? key;\n};\n\n/** Props for the Inventory component */\ntype InventoryProps = {\n /** The scripture reference that the application is currently set to */\n scriptureReference: ScriptureReference;\n /** Callback function that is executed when the scripture reference is changed */\n setScriptureReference: (scriptureReference: ScriptureReference) => void;\n /**\n * Object with all localized strings that the Inventory needs to work well across multiple\n * languages. When using this component with Platform.Bible, you can import\n * `INVENTORY_STRING_KEYS` from this library, pass it in to the Platform's localization hook, and\n * pass the localized keys that are returned by the hook into this prop.\n */\n localizedStrings: InventoryLocalizedStrings;\n /**\n * The logic that finds the desired items in the source text. This can either be a Regular\n * expression that captures one or multiple items (preferred), or a custom function that builds\n * and return an InventoryDataTable[] manually. Note: In case the logic captures more than one\n * item (i.e. InventoryTableData.items has a length greater than 1), you must provide text labels\n * for the related columns and control elements to show by setting the `additionalItemsLabels`\n * prop\n */\n extractItems:\n | RegExp\n | ((\n text: string | undefined,\n scriptureRef: ScriptureReference,\n approvedItems: string[],\n unapprovedItems: string[],\n ) => InventoryTableData[]);\n /**\n * Text labels for control elements and additional column headers in case your Inventory has more\n * than one item to show (e.g. The 'Preceding Marker' in the Markers Inventory)\n */\n additionalItemsLabels?: AdditionalItemsLabels;\n /** Array of approved items, typically as defined in `Settings.xml` */\n approvedItems: string[];\n /** Array of unapproved items, typically as defined in `Settings.xml` */\n unapprovedItems: string[];\n /** The source scripture text that is searched for in inventory items */\n text: string | undefined;\n /** Scope of scripture that the inventory will operate on */\n scope: Scope;\n /** Callback function that is executed when the scope is changed from the Inventory */\n onScopeChange: (scope: Scope) => void;\n /**\n * Column definitions for the Inventory data table. The most commonly used column definitions are\n * pre-configured for your convenience and can be imported (e.g. inventoryItemColumn,\n * inventoryAdditionalItemColumn inventoryCountColumn, and inventoryStatusColumn). If you need any\n * other columns you can add these yourself\n */\n columns: ColumnDef[];\n};\n\n/** Inventory component that is used to view and control the status of provided project settings */\nexport default function Inventory({\n scriptureReference,\n setScriptureReference,\n localizedStrings,\n extractItems,\n additionalItemsLabels,\n approvedItems,\n unapprovedItems,\n text,\n scope,\n onScopeChange,\n columns,\n}: InventoryProps) {\n const allItemsText = localizeString(localizedStrings, '%webView_inventory_all%');\n const approvedItemsText = localizeString(localizedStrings, '%webView_inventory_approved%');\n const unapprovedItemsText = localizeString(localizedStrings, '%webView_inventory_unapproved%');\n const unknownItemsText = localizeString(localizedStrings, '%webView_inventory_unknown%');\n const scopeBookText = localizeString(localizedStrings, '%webView_inventory_scope_currentBook%');\n const scopeChapterText = localizeString(localizedStrings, '%webView_inventory_scope_chapter%');\n const scopeVerseText = localizeString(localizedStrings, '%webView_inventory_scope_verse%');\n const filterText = localizeString(localizedStrings, '%webView_inventory_filter_text%');\n const showAdditionalItemsText = localizeString(\n localizedStrings,\n '%webView_inventory_show_additional_items%',\n );\n\n const [showAdditionalItems, setShowAdditionalItems] = useState(false);\n const [statusFilter, setStatusFilter] = useState('all');\n const [textFilter, setTextFilter] = useState('');\n const [selectedItem, setSelectedItem] = useState([]);\n\n const tableData: InventoryTableData[] = useMemo(() => {\n if (!text) return [];\n if (extractItems instanceof RegExp)\n return createTableData(\n text,\n scriptureReference,\n approvedItems,\n unapprovedItems,\n extractItems,\n );\n return extractItems(text, scriptureReference, approvedItems, unapprovedItems);\n }, [text, extractItems, scriptureReference, approvedItems, unapprovedItems]);\n\n const reducedTableData: InventoryTableData[] = useMemo(() => {\n if (showAdditionalItems) return tableData;\n\n const newTableData: InventoryTableData[] = [];\n\n tableData.forEach((tableEntry) => {\n const firstItem = tableEntry.items[0];\n\n const existingEntry = newTableData.find(\n (newTableEntry) => newTableEntry.items[0] === firstItem,\n );\n\n if (existingEntry) {\n existingEntry.count += tableEntry.count;\n existingEntry.occurrences = existingEntry.occurrences.concat(tableEntry.occurrences);\n } else {\n newTableData.push({\n items: [firstItem],\n count: tableEntry.count,\n occurrences: tableEntry.occurrences,\n status: tableEntry.status,\n });\n }\n });\n\n return newTableData;\n }, [showAdditionalItems, tableData]);\n\n const filteredTableData: InventoryTableData[] = useMemo(() => {\n return filterItemData(reducedTableData, statusFilter, textFilter);\n }, [reducedTableData, statusFilter, textFilter]);\n\n const allColumns: ColumnDef[] = useMemo(() => {\n if (!showAdditionalItems) return columns;\n\n const numberOfAdditionalItems = additionalItemsLabels?.tableHeaders?.length;\n if (!numberOfAdditionalItems) return columns;\n\n const additionalColumns: ColumnDef[] = [];\n\n for (let index = 0; index < numberOfAdditionalItems; index++) {\n additionalColumns.push(\n inventoryAdditionalItemColumn(\n additionalItemsLabels?.tableHeaders?.[index] || 'Additional Item',\n index + 1,\n ),\n );\n }\n\n return [...additionalColumns, ...columns];\n }, [additionalItemsLabels?.tableHeaders, columns, showAdditionalItems]);\n\n useEffect(() => {\n setSelectedItem([]);\n }, [filteredTableData]);\n\n const rowClickHandler = (\n row: RowContents,\n table: TableContents,\n ) => {\n table.setRowSelection(() => {\n const newSelection: RowSelectionState = {};\n newSelection[row.index] = true;\n return newSelection;\n });\n\n setSelectedItem(row.original.items);\n };\n\n const handleScopeChange = (value: string) => {\n if (value === 'book' || value === 'chapter' || value === 'verse') {\n onScopeChange(value);\n } else {\n throw new Error(`Invalid scope value: ${value}`);\n }\n };\n\n const handleStatusFilterChange = (value: string) => {\n if (value === 'all' || value === 'approved' || value === 'unapproved' || value === 'unknown') {\n setStatusFilter(value);\n } else {\n throw new Error(`Invalid status filter value: ${value}`);\n }\n };\n\n const occurrenceData: InventoryItemOccurrence[] = useMemo(() => {\n if (reducedTableData.length === 0 || selectedItem.length === 0) return [];\n const occurrence = reducedTableData.filter((tableEntry: InventoryTableData) => {\n return deepEqual(\n showAdditionalItems ? tableEntry.items : [tableEntry.items[0]],\n selectedItem,\n );\n });\n if (occurrence.length > 1) throw new Error('Selected item is not unique');\n return occurrence[0].occurrences;\n }, [selectedItem, showAdditionalItems, reducedTableData]);\n\n return (\n
    \n
    \n handleStatusFilterChange(value)}\n defaultValue={statusFilter}\n >\n \n \n \n \n {allItemsText}\n {approvedItemsText}\n {unapprovedItemsText}\n {unknownItemsText}\n \n \n \n {\n setTextFilter(event.target.value);\n }}\n />\n {additionalItemsLabels && (\n
    \n {\n setSelectedItem([]);\n setShowAdditionalItems(checked);\n }}\n />\n \n
    \n )}\n
    \n
    \n \n
    \n {occurrenceData.length > 0 && (\n
    \n \n
    \n )}\n
    \n );\n}\n","import { Input } from '@/components/shadcn-ui/input';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { useState } from 'react';\n\nexport type SearchBarProps = {\n /**\n * Callback fired to handle the search query when button pressed\n *\n * @param searchQuery\n */\n onSearch: (searchQuery: string) => void;\n\n /** Optional string that appears in the search bar without a search string */\n placeholder?: string;\n\n /** Optional boolean to set the input base to full width */\n isFullWidth?: boolean;\n};\n\nexport default function SearchBar({ onSearch, placeholder, isFullWidth }: SearchBarProps) {\n const [searchQuery, setSearchQuery] = useState('');\n\n const handleInputChange = (searchString: string) => {\n setSearchQuery(searchString);\n onSearch(searchString);\n };\n\n return (\n handleInputChange(e.target.value)}\n />\n );\n}\n","// adapted from: https://github.com/shadcn-ui/ui/discussions/752\n\n'use client';\n\nimport { TabsContentProps, TabsListProps, TabsTriggerProps } from '@/components/shadcn-ui/tabs';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport * as TabsPrimitive from '@radix-ui/react-tabs';\nimport React from 'react';\n\nexport type VerticalTabsProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport type LeftTabsTriggerProps = TabsTriggerProps & {\n value: string;\n ref?: React.Ref;\n};\n\nexport const VerticalTabs = React.forwardRef<\n React.ElementRef,\n VerticalTabsProps\n>(({ className, ...props }, ref) => (\n \n));\n\nVerticalTabs.displayName = TabsPrimitive.List.displayName;\n\nexport const VerticalTabsList = React.forwardRef<\n React.ElementRef,\n TabsListProps\n>(({ className, ...props }, ref) => (\n \n));\nVerticalTabsList.displayName = TabsPrimitive.List.displayName;\n\nexport const VerticalTabsTrigger = React.forwardRef<\n React.ElementRef,\n LeftTabsTriggerProps\n>(({ className, ...props }, ref) => (\n \n));\n\nexport const VerticalTabsContent = React.forwardRef<\n React.ElementRef,\n TabsContentProps\n>(({ className, ...props }, ref) => (\n \n));\nVerticalTabsContent.displayName = TabsPrimitive.Content.displayName;\n","import SearchBar from '@/components/basics/search-bar.component';\nimport {\n VerticalTabs,\n VerticalTabsContent,\n VerticalTabsList,\n VerticalTabsTrigger,\n} from '@/components/basics/tabs-vertical';\nimport { ReactNode } from 'react';\n\nexport type TabKeyValueContent = {\n key: string;\n value: string;\n content: ReactNode;\n};\n\nexport type TabNavigationContentSearchProps = {\n /** List of values and keys for each tab this component should provide */\n tabList: TabKeyValueContent[];\n\n /** Handler to run when the value of the search bar changes */\n onSearch: (searchQuery: string) => void;\n\n /** Optional placeholder for the search bar */\n searchPlaceholder?: string;\n\n /** Optional title to include in the header */\n headerTitle?: string;\n\n /** Optional flag to make the search bar appear full width */\n isSearchBarFullWidth?: boolean;\n\n /** Text direction ltr or rtl */\n direction?: 'ltr' | 'rtl';\n};\n\nexport default function TabNavigationContentSearch({\n tabList,\n onSearch,\n searchPlaceholder,\n headerTitle,\n isSearchBarFullWidth = false,\n direction = 'ltr',\n}: TabNavigationContentSearchProps) {\n return (\n
    \n
    \n {headerTitle ?

    {headerTitle}

    : ''}\n \n
    \n \n \n {tabList.map((tab) => (\n \n {tab.value}\n \n ))}\n \n {tabList.map((tab) => (\n \n {tab.content}\n \n ))}\n \n
    \n );\n}\n","import React from 'react';\nimport * as SeparatorPrimitive from '@radix-ui/react-separator';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Separator = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, orientation = 'horizontal', decorative = true, ...props }, ref) => (\n \n));\nSeparator.displayName = SeparatorPrimitive.Root.displayName;\n\nexport { Separator };\n","'use client';\n\nimport * as React from 'react';\nimport * as SheetPrimitive from '@radix-ui/react-dialog';\nimport { cva, type VariantProps } from 'class-variance-authority';\nimport { X } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Sheet = SheetPrimitive.Root;\n\nconst SheetTrigger = SheetPrimitive.Trigger;\n\nconst SheetClose = SheetPrimitive.Close;\n\nconst SheetPortal = SheetPrimitive.Portal;\n\nconst SheetOverlay = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSheetOverlay.displayName = SheetPrimitive.Overlay.displayName;\n\nconst sheetVariants = cva(\n 'pr-twp tw-fixed tw-z-50 tw-gap-4 tw-bg-background tw-p-6 tw-shadow-lg tw-transition tw-ease-in-out data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-duration-300 data-[state=open]:tw-duration-500',\n {\n variants: {\n side: {\n top: 'tw-inset-x-0 tw-top-0 tw-border-b data-[state=closed]:tw-slide-out-to-top data-[state=open]:tw-slide-in-from-top',\n bottom:\n 'tw-inset-x-0 tw-bottom-0 tw-border-t data-[state=closed]:tw-slide-out-to-bottom data-[state=open]:tw-slide-in-from-bottom',\n left: 'tw-inset-y-0 tw-left-0 tw-h-full tw-w-3/4 tw-border-r data-[state=closed]:tw-slide-out-to-left data-[state=open]:tw-slide-in-from-left sm:tw-max-w-sm',\n right:\n 'tw-inset-y-0 tw-right-0 tw-h-full tw-w-3/4 tw- tw-border-l data-[state=closed]:tw-slide-out-to-right data-[state=open]:tw-slide-in-from-right sm:tw-max-w-sm',\n },\n },\n defaultVariants: {\n side: 'right',\n },\n },\n);\n\ninterface SheetContentProps\n extends React.ComponentPropsWithoutRef,\n VariantProps {}\n\nconst SheetContent = React.forwardRef<\n React.ElementRef,\n SheetContentProps\n>(({ side = 'right', className, children, ...props }, ref) => (\n \n \n \n {children}\n \n \n Close\n \n \n \n));\nSheetContent.displayName = SheetPrimitive.Content.displayName;\n\nfunction SheetHeader({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nSheetHeader.displayName = 'SheetHeader';\n\nfunction SheetFooter({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nSheetFooter.displayName = 'SheetFooter';\n\nconst SheetTitle = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSheetTitle.displayName = SheetPrimitive.Title.displayName;\n\nconst SheetDescription = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSheetDescription.displayName = SheetPrimitive.Description.displayName;\n\nexport {\n Sheet,\n SheetPortal,\n SheetOverlay,\n SheetTrigger,\n SheetClose,\n SheetContent,\n SheetHeader,\n SheetFooter,\n SheetTitle,\n SheetDescription,\n};\n","import React from 'react';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nfunction Skeleton({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\n\nexport { Skeleton };\n","import React from 'react';\nimport * as TooltipPrimitive from '@radix-ui/react-tooltip';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst TooltipProvider = TooltipPrimitive.Provider;\n\nconst Tooltip = TooltipPrimitive.Root;\n\nconst TooltipTrigger = TooltipPrimitive.Trigger;\n\nconst TooltipContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, sideOffset = 4, ...props }, ref) => (\n \n));\nTooltipContent.displayName = TooltipPrimitive.Content.displayName;\n\nexport { Tooltip, TooltipTrigger, TooltipContent, TooltipProvider };\n","import * as React from 'react';\n\nconst MOBILE_BREAKPOINT = 768;\n\nexport default function useIsMobile() {\n const [isMobile, setIsMobile] = React.useState(undefined);\n\n React.useEffect(() => {\n const mql = window.matchMedia(`(max-width: ${MOBILE_BREAKPOINT - 1}px)`);\n const onChange = () => {\n setIsMobile(window.innerWidth < MOBILE_BREAKPOINT);\n };\n mql.addEventListener('change', onChange);\n setIsMobile(window.innerWidth < MOBILE_BREAKPOINT);\n return () => mql.removeEventListener('change', onChange);\n }, []);\n\n return !!isMobile;\n}\n","import React from 'react';\nimport { Slot } from '@radix-ui/react-slot';\nimport { VariantProps, cva } from 'class-variance-authority';\nimport { PanelLeft } from 'lucide-react';\n\nimport { Button } from '@/components/shadcn-ui/button';\nimport { Input } from '@/components/shadcn-ui/input';\nimport { Separator } from '@/components/shadcn-ui/separator';\nimport { Sheet, SheetContent } from '@/components/shadcn-ui/sheet';\nimport { Skeleton } from '@/components/shadcn-ui/skeleton';\nimport {\n Tooltip,\n TooltipContent,\n TooltipProvider,\n TooltipTrigger,\n} from '@/components/shadcn-ui/tooltip';\nimport useIsMobile from '@/components/hooks/use-mobile';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst SIDEBAR_COOKIE_NAME = 'sidebar:state';\nconst SIDEBAR_COOKIE_MAX_AGE = 60 * 60 * 24 * 7;\nconst SIDEBAR_WIDTH = '16rem';\nconst SIDEBAR_WIDTH_MOBILE = '18rem';\nconst SIDEBAR_WIDTH_ICON = '3rem';\nconst SIDEBAR_KEYBOARD_SHORTCUT = 'b';\n\ntype SidebarContextProps = {\n state: 'expanded' | 'collapsed';\n open: boolean;\n setOpen: (open: boolean) => void;\n openMobile: boolean;\n setOpenMobile: (open: boolean) => void;\n isMobile: boolean;\n toggleSidebar: () => void;\n};\n\nconst SidebarContext = React.createContext(undefined);\n\nfunction useSidebar() {\n const context = React.useContext(SidebarContext);\n if (!context) {\n throw new Error('useSidebar must be used within a SidebarProvider.');\n }\n\n return context;\n}\n\nconst SidebarProvider = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & {\n defaultOpen?: boolean;\n open?: boolean;\n onOpenChange?: (open: boolean) => void;\n }\n>(\n (\n {\n defaultOpen = true,\n open: openProp,\n onOpenChange: setOpenProp,\n className,\n style,\n children,\n ...props\n },\n ref,\n ) => {\n const isMobile = useIsMobile();\n const [openMobile, setOpenMobile] = React.useState(false);\n\n // This is the internal state of the sidebar.\n // We use openProp and setOpenProp for control from outside the component.\n const [_open, _setOpen] = React.useState(defaultOpen);\n const isOpen = openProp ?? _open;\n const setOpen = React.useCallback(\n (value: boolean | ((value: boolean) => boolean)) => {\n const openState = typeof value === 'function' ? value(isOpen) : value;\n if (setOpenProp) {\n setOpenProp(openState);\n } else {\n _setOpen(openState);\n }\n\n // This sets the cookie to keep the sidebar state.\n document.cookie = `${SIDEBAR_COOKIE_NAME}=${openState}; path=/; max-age=${SIDEBAR_COOKIE_MAX_AGE}`;\n },\n [setOpenProp, isOpen],\n );\n\n // Helper to toggle the sidebar.\n const toggleSidebar = React.useCallback(() => {\n return isMobile ? setOpenMobile((open) => !open) : setOpen((open) => !open);\n }, [isMobile, setOpen, setOpenMobile]);\n\n // Adds a keyboard shortcut to toggle the sidebar.\n React.useEffect(() => {\n const handleKeyDown = (event: KeyboardEvent) => {\n if (event.key === SIDEBAR_KEYBOARD_SHORTCUT && (event.metaKey || event.ctrlKey)) {\n event.preventDefault();\n toggleSidebar();\n }\n };\n\n window.addEventListener('keydown', handleKeyDown);\n return () => window.removeEventListener('keydown', handleKeyDown);\n }, [toggleSidebar]);\n\n // We add a state so that we can do data-state=\"expanded\" or \"collapsed\".\n // This makes it easier to style the sidebar with Tailwind classes.\n const state = isOpen ? 'expanded' : 'collapsed';\n\n const contextValue = React.useMemo(\n () => ({\n state,\n open: isOpen,\n setOpen,\n isMobile,\n openMobile,\n setOpenMobile,\n toggleSidebar,\n }),\n [state, isOpen, setOpen, isMobile, openMobile, setOpenMobile, toggleSidebar],\n );\n\n return (\n \n \n \n {children}\n
    \n \n \n );\n },\n);\nSidebarProvider.displayName = 'SidebarProvider';\n\nconst Sidebar = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & {\n side?: 'left' | 'right';\n variant?: 'sidebar' | 'floating' | 'inset';\n collapsible?: 'offcanvas' | 'icon' | 'none';\n }\n>(\n (\n {\n side = 'left',\n variant = 'sidebar',\n collapsible = 'offcanvas',\n className,\n children,\n ...props\n },\n ref,\n ) => {\n const { isMobile, state, openMobile, setOpenMobile } = useSidebar();\n\n if (collapsible === 'none') {\n return (\n \n {children}\n
    \n );\n }\n\n if (isMobile) {\n return (\n \n button]:tw-hidden\"\n style={\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n {\n '--sidebar-width': SIDEBAR_WIDTH_MOBILE,\n } as React.CSSProperties\n }\n side={side}\n >\n
    {children}
    \n \n
    \n );\n }\n\n return (\n \n {/* This is what handles the sidebar gap on desktop */}\n \n \n \n {children}\n
    \n
    \n
    \n );\n },\n);\nSidebar.displayName = 'Sidebar';\n\nconst SidebarTrigger = React.forwardRef<\n React.ElementRef,\n React.ComponentProps\n>(({ className, onClick, ...props }, ref) => {\n const { toggleSidebar } = useSidebar();\n\n return (\n {\n onClick?.(event);\n toggleSidebar();\n }}\n {...props}\n >\n \n Toggle Sidebar\n \n );\n});\nSidebarTrigger.displayName = 'SidebarTrigger';\n\nconst SidebarRail = React.forwardRef>(\n ({ className, ...props }, ref) => {\n const { toggleSidebar } = useSidebar();\n\n return (\n \n );\n },\n);\nSidebarRail.displayName = 'SidebarRail';\n\nconst SidebarInset = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarInset.displayName = 'SidebarInset';\n\nconst SidebarInput = React.forwardRef<\n React.ElementRef,\n React.ComponentProps\n>(({ className, ...props }, ref) => {\n return (\n \n );\n});\nSidebarInput.displayName = 'SidebarInput';\n\nconst SidebarHeader = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarHeader.displayName = 'SidebarHeader';\n\nconst SidebarFooter = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarFooter.displayName = 'SidebarFooter';\n\nconst SidebarSeparator = React.forwardRef<\n React.ElementRef,\n React.ComponentProps\n>(({ className, ...props }, ref) => {\n return (\n \n );\n});\nSidebarSeparator.displayName = 'SidebarSeparator';\n\nconst SidebarContent = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarContent.displayName = 'SidebarContent';\n\nconst SidebarGroup = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarGroup.displayName = 'SidebarGroup';\n\nconst SidebarGroupLabel = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & { asChild?: boolean }\n>(({ className, asChild = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'div';\n\n return (\n svg]:tw-size-4 [&>svg]:tw-shrink-0',\n 'group-data-[collapsible=icon]:tw--mt-8 group-data-[collapsible=icon]:tw-opacity-0',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarGroupLabel.displayName = 'SidebarGroupLabel';\n\nconst SidebarGroupAction = React.forwardRef<\n HTMLButtonElement,\n React.ComponentProps<'button'> & { asChild?: boolean }\n>(({ className, asChild = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'button';\n\n return (\n svg]:tw-size-4 [&>svg]:tw-shrink-0',\n // Increases the hit area of the button on mobile.\n 'after:tw-absolute after:tw--inset-2 after:md:tw-hidden',\n 'group-data-[collapsible=icon]:tw-hidden',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarGroupAction.displayName = 'SidebarGroupAction';\n\nconst SidebarGroupContent = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarGroupContent.displayName = 'SidebarGroupContent';\n\nconst SidebarMenu = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenu.displayName = 'SidebarMenu';\n\nconst SidebarMenuItem = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenuItem.displayName = 'SidebarMenuItem';\n\nconst sidebarMenuButtonVariants = cva(\n 'tw-peer/menu-button tw-flex tw-w-full tw-items-center tw-gap-2 tw-overflow-hidden tw-rounded-md tw-p-2 tw-text-left tw-text-sm tw-outline-none tw-ring-sidebar-ring tw-transition-[width,height,padding] hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground focus-visible:tw-ring-2 active:tw-bg-sidebar-accent active:tw-text-sidebar-accent-foreground disabled:tw-pointer-events-none disabled:tw-opacity-50 tw-group-has-[[data-sidebar=menu-action]]/menu-item:pr-8 aria-disabled:tw-pointer-events-none aria-disabled:tw-opacity-50 data-[active=true]:tw-bg-sidebar-accent data-[active=true]:tw-font-medium data-[active=true]:tw-text-sidebar-accent-foreground data-[state=open]:hover:tw-bg-sidebar-accent data-[state=open]:hover:tw-text-sidebar-accent-foreground group-data-[collapsible=icon]:tw-!size-8 group-data-[collapsible=icon]:tw-!p-2 [&>span:last-child]:tw-truncate [&>svg]:tw-size-4 [&>svg]:tw-shrink-0',\n {\n variants: {\n variant: {\n default: 'hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground',\n outline:\n 'tw-bg-background tw-shadow-[0_0_0_1px_hsl(var(--sidebar-border))] hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground hover:tw-shadow-[0_0_0_1px_hsl(var(--sidebar-accent))]',\n },\n size: {\n default: 'tw-h-8 tw-text-sm',\n sm: 'tw-h-7 tw-text-xs',\n lg: 'tw-h-12 tw-text-sm group-data-[collapsible=icon]:tw-!p-0',\n },\n },\n defaultVariants: {\n variant: 'default',\n size: 'default',\n },\n },\n);\n\nconst SidebarMenuButton = React.forwardRef<\n HTMLButtonElement,\n React.ComponentProps<'button'> & {\n asChild?: boolean;\n isActive?: boolean;\n tooltip?: string | React.ComponentProps;\n } & VariantProps\n>(\n (\n {\n asChild = false,\n isActive = false,\n variant = 'default',\n size = 'default',\n tooltip,\n className,\n ...props\n },\n ref,\n ) => {\n const Comp = asChild ? Slot : 'button';\n const { isMobile, state } = useSidebar();\n\n const button = (\n \n );\n\n if (!tooltip) {\n return button;\n }\n\n if (typeof tooltip === 'string') {\n // eslint-disable-next-line no-param-reassign\n tooltip = {\n children: tooltip,\n };\n }\n\n return (\n \n {button}\n \n );\n },\n);\nSidebarMenuButton.displayName = 'SidebarMenuButton';\n\nconst SidebarMenuAction = React.forwardRef<\n HTMLButtonElement,\n React.ComponentProps<'button'> & {\n asChild?: boolean;\n showOnHover?: boolean;\n }\n>(({ className, asChild = false, showOnHover = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'button';\n\n return (\n svg]:tw-size-4 [&>svg]:tw-shrink-0',\n // Increases the hit area of the button on mobile.\n 'after:tw-absolute after:tw--inset-2 after:md:tw-hidden',\n 'tw-peer-data-[size=sm]/menu-button:top-1',\n 'tw-peer-data-[size=default]/menu-button:top-1.5',\n 'tw-peer-data-[size=lg]/menu-button:top-2.5',\n 'group-data-[collapsible=icon]:tw-hidden',\n showOnHover &&\n 'tw-group-focus-within/menu-item:opacity-100 tw-group-hover/menu-item:opacity-100 tw-peer-data-[active=true]/menu-button:text-sidebar-accent-foreground data-[state=open]:tw-opacity-100 md:tw-opacity-0',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarMenuAction.displayName = 'SidebarMenuAction';\n\nconst SidebarMenuBadge = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenuBadge.displayName = 'SidebarMenuBadge';\n\nconst SidebarMenuSkeleton = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & {\n showIcon?: boolean;\n }\n>(({ className, showIcon = false, ...props }, ref) => {\n // Random width between 50 to 90%.\n const width = React.useMemo(() => {\n return `${Math.floor(Math.random() * 40) + 50}%`;\n }, []);\n\n return (\n \n {showIcon && (\n \n )}\n \n
    \n );\n});\nSidebarMenuSkeleton.displayName = 'SidebarMenuSkeleton';\n\nconst SidebarMenuSub = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenuSub.displayName = 'SidebarMenuSub';\n\nconst SidebarMenuSubItem = React.forwardRef>(\n ({ ...props }, ref) =>
  • ,\n);\nSidebarMenuSubItem.displayName = 'SidebarMenuSubItem';\n\nconst SidebarMenuSubButton = React.forwardRef<\n HTMLAnchorElement,\n React.ComponentProps<'a'> & {\n asChild?: boolean;\n size?: 'sm' | 'md';\n isActive?: boolean;\n }\n>(({ asChild = false, size = 'md', isActive, className, ...props }, ref) => {\n const Comp = asChild ? Slot : 'a';\n\n return (\n span:last-child]:tw-truncate [&>svg]:tw-size-4 [&>svg]:tw-shrink-0 [&>svg]:tw-text-sidebar-accent-foreground',\n 'data-[active=true]:tw-bg-sidebar-accent data-[active=true]:tw-text-sidebar-accent-foreground',\n size === 'sm' && 'tw-text-xs',\n size === 'md' && 'tw-text-sm',\n 'group-data-[collapsible=icon]:tw-hidden',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarMenuSubButton.displayName = 'SidebarMenuSubButton';\n\nexport {\n Sidebar,\n SidebarContent,\n SidebarFooter,\n SidebarGroup,\n SidebarGroupAction,\n SidebarGroupContent,\n SidebarGroupLabel,\n SidebarHeader,\n SidebarInput,\n SidebarInset,\n SidebarMenu,\n SidebarMenuAction,\n SidebarMenuBadge,\n SidebarMenuButton,\n SidebarMenuItem,\n SidebarMenuSkeleton,\n SidebarMenuSub,\n SidebarMenuSubButton,\n SidebarMenuSubItem,\n SidebarProvider,\n SidebarRail,\n SidebarSeparator,\n SidebarTrigger,\n useSidebar,\n};\n","import { useState } from 'react';\nimport {\n Sidebar,\n SidebarContent,\n SidebarGroup,\n SidebarGroupLabel,\n SidebarGroupContent,\n SidebarMenu,\n SidebarMenuItem,\n SidebarMenuButton,\n} from '../../shadcn-ui/sidebar';\n\nexport type SettingsSidebarProps = {\n /** Optional id */\n id?: string;\n\n /** Extension labels to list in sidebar */\n extensionLabels: string[];\n\n /** Project labels to list in sidebar */\n // projectLabels: string[];\n\n handleSelectSidebarItem: (key: string, isProjectSetting: boolean) => void;\n};\n\nexport default function SettingsSidebar({\n id,\n extensionLabels,\n // projectLabels,\n handleSelectSidebarItem,\n}: SettingsSidebarProps) {\n const [selectedItem, setSelectedItem] = useState();\n\n const handleSelectItem = (item: string, isProjectSetting: boolean) => {\n setSelectedItem(item);\n handleSelectSidebarItem(item, isProjectSetting);\n };\n\n return (\n \n \n \n Extensions\n \n \n {extensionLabels.map((label) => (\n \n handleSelectItem(label, false)}\n isActive={label === selectedItem}\n >\n {label}\n \n \n ))}\n \n \n \n\n {/* \n Projects\n \n \n {projectLabels.map((label) => (\n \n handleSelectItem(label)}\n isActive={label === selectedItem}\n >\n {label}\n \n \n ))}\n \n \n */}\n \n \n );\n}\n","import { SidebarInset, SidebarProvider } from '@/components/shadcn-ui/sidebar';\n// import { ProjectSettingProperties, SettingProperties } from 'platform-bible-utils';\nimport { PropsWithChildren } from 'react';\nimport SettingsSidebar from './settings-sidebar.component';\n\nexport type SettingsSidebarContentSearchProps = {\n /** Text direction ltr or rtl */\n direction?: 'ltr' | 'rtl';\n\n extensionLabels: string[];\n // projectLabels: string[];\n handleSelectSidebarItem: (key: string, isProjectSetting: boolean) => void;\n // renderSettingsProperties: (extension: string) => SettingProperties;\n // renderProjectSettingsProperties: (project: string) => ProjectSettingProperties;\n} & PropsWithChildren;\n\nexport default function SettingsSidebarContentSearch({\n direction = 'ltr',\n extensionLabels,\n // projectLabels,\n children,\n handleSelectSidebarItem,\n // renderSettingsProperties,\n // renderProjectSettingsProperties.\n}: SettingsSidebarContentSearchProps) {\n return (\n \n \n {children}\n \n );\n}\n","import { Button } from '@/components/shadcn-ui/button';\nimport {\n Select,\n SelectContent,\n SelectGroup,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\nimport {\n Table,\n TableBody,\n TableCell,\n TableHead,\n TableHeader,\n TableRow,\n} from '@/components/shadcn-ui/table';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Canon } from '@sillsdev/scripture';\nimport {\n Cell,\n ColumnDef,\n flexRender,\n getCoreRowModel,\n getExpandedRowModel,\n getGroupedRowModel,\n getSortedRowModel,\n GroupingState,\n Row,\n RowSelectionState,\n SortingState,\n useReactTable,\n} from '@tanstack/react-table';\nimport '@/components/advanced/scripture-results-viewer/scripture-results-viewer.component.css';\nimport {\n compareScrRefs,\n formatScrRef,\n ScriptureSelection,\n scrRefToBBBCCCVVV,\n} from 'platform-bible-utils';\nimport { MouseEvent, useEffect, useMemo, useState } from 'react';\nimport { ChevronDown, ChevronLeft, ChevronRight } from 'lucide-react';\n\n/**\n * Information (e.g., a checking error or some other type of \"transient\" annotation) about something\n * noteworthy at a specific place in an instance of the Scriptures.\n */\nexport type ScriptureItemDetail = ScriptureSelection & {\n /**\n * Text of the error, note, etc. In the future, we might want to support something more than just\n * text so that a JSX element could be provided with a link or some other controls related to the\n * issue being reported.\n */\n detail: string;\n};\n\n/**\n * A uniquely identifiable source of results that can be displayed in the ScriptureResultsViewer.\n * Generally, the source will be a particular Scripture check, but there may be other types of\n * sources.\n */\nexport type ResultsSource = {\n /**\n * Uniquely identifies the source.\n *\n * @type {string}\n */\n id: string;\n\n /**\n * Name (potentially localized) of the source, suitable for display in the UI.\n *\n * @type {string}\n */\n displayName: string;\n};\n\nexport type ScriptureSrcItemDetail = ScriptureItemDetail & {\n /** Source/type of detail. Can be used for grouping. */\n source: ResultsSource;\n};\n\n/**\n * Represents a set of results keyed by Scripture reference. Generally, the source will be a\n * particular Scripture check, but this type also allows for other types of uniquely identifiable\n * sources.\n */\nexport type ResultsSet = {\n /**\n * The backing source associated with this set of results.\n *\n * @type {ResultsSource}\n */\n source: ResultsSource;\n\n /**\n * Array of Scripture item details (messages keyed by Scripture reference).\n *\n * @type {ScriptureItemDetail[]}\n */\n data: ScriptureItemDetail[];\n};\n\nconst scrBookColId = 'scrBook';\nconst scrRefColId = 'scrRef';\nconst typeColId = 'source';\nconst detailsColId = 'details';\n\nconst defaultScrRefColumnName = 'Scripture Reference';\nconst defaultScrBookGroupName = 'Scripture Book';\nconst defaultTypeColumnName = 'Type';\nconst defaultDetailsColumnName = 'Details';\n\nexport type ScriptureResultsViewerColumnInfo = {\n /** Optional header to display for the Reference column. Default value: 'Scripture Reference'. */\n scriptureReferenceColumnName?: string;\n\n /** Optional text to display to refer to the Scripture book group. Default value: 'Scripture Book'. */\n scriptureBookGroupName?: string;\n\n /** Optional header to display for the Type column. Default value: 'Type'. */\n typeColumnName?: string;\n\n /** Optional header to display for the Details column. Default value: 'Details' */\n detailsColumnName?: string;\n};\n\nexport type ScriptureResultsViewerProps = ScriptureResultsViewerColumnInfo & {\n /** Groups of ScriptureItemDetail objects from particular sources (e.g., Scripture checks) */\n sources: ResultsSet[];\n\n /** Flag indicating whether to display column headers. Default is false. */\n showColumnHeaders?: boolean;\n\n /** Flag indicating whether to display source column. Default is false. */\n showSourceColumn?: boolean;\n\n /** Callback function to notify when a row is selected */\n onRowSelected?: (selectedRow: ScriptureSrcItemDetail | undefined) => void;\n\n /** Text direction ltr or rtl */\n direction?: 'ltr' | 'rtl';\n};\n\nfunction getColumns(\n colInfo?: ScriptureResultsViewerColumnInfo,\n showSourceColumn?: boolean,\n): ColumnDef[] {\n const showSrcCol = showSourceColumn ?? false;\n return [\n {\n accessorFn: (row) =>\n `${Canon.bookNumberToId(row.start.bookNum)} ${row.start.chapterNum}:${row.start.verseNum}`,\n id: scrBookColId,\n header: colInfo?.scriptureReferenceColumnName ?? defaultScrRefColumnName,\n cell: (info) => {\n const row = info.row.original;\n if (info.row.getIsGrouped()) {\n return Canon.bookNumberToEnglishName(row.start.bookNum);\n }\n return info.row.groupingColumnId === scrBookColId ? formatScrRef(row.start) : undefined;\n },\n getGroupingValue: (row) => row.start.bookNum,\n sortingFn: (a, b) => {\n return compareScrRefs(a.original.start, b.original.start);\n },\n enableGrouping: true,\n },\n {\n accessorFn: (row) => formatScrRef(row.start),\n id: scrRefColId,\n header: undefined,\n cell: (info) => {\n const row = info.row.original;\n return info.row.getIsGrouped() ? undefined : formatScrRef(row.start);\n },\n sortingFn: (a, b) => {\n return compareScrRefs(a.original.start, b.original.start);\n },\n enableGrouping: false,\n },\n {\n accessorFn: (row) => row.source.displayName,\n id: typeColId,\n header: showSrcCol ? (colInfo?.typeColumnName ?? defaultTypeColumnName) : undefined,\n cell: (info) => (showSrcCol || info.row.getIsGrouped() ? info.getValue() : undefined),\n getGroupingValue: (row) => row.source.id,\n sortingFn: (a, b) =>\n a.original.source.displayName.localeCompare(b.original.source.displayName),\n enableGrouping: true,\n },\n {\n accessorFn: (row) => row.detail,\n id: detailsColId,\n header: colInfo?.detailsColumnName ?? defaultDetailsColumnName,\n cell: (info) => info.getValue(),\n enableGrouping: false,\n },\n ];\n}\n\nconst toRefOrRange = (scriptureSelection: ScriptureSelection) => {\n if (!('offset' in scriptureSelection.start))\n throw new Error('No offset available in range start');\n if (scriptureSelection.end && !('offset' in scriptureSelection.end))\n throw new Error('No offset available in range end');\n const { offset: offsetStart } = scriptureSelection.start;\n let offsetEnd: number = 0;\n if (scriptureSelection.end) ({ offset: offsetEnd } = scriptureSelection.end);\n if (\n !scriptureSelection.end ||\n compareScrRefs(scriptureSelection.start, scriptureSelection.end) === 0\n )\n return `${scrRefToBBBCCCVVV(scriptureSelection.start)}+${offsetStart}`;\n return `${scrRefToBBBCCCVVV(scriptureSelection.start)}+${offsetStart}-${scrRefToBBBCCCVVV(scriptureSelection.end)}+${offsetEnd}`;\n};\n\nconst getRowKey = (row: ScriptureSrcItemDetail) =>\n `${toRefOrRange({ start: row.start, end: row.end })} ${row.source.displayName} ${row.detail}`;\n\n/**\n * Component to display a combined list of detailed items from one or more sources, where the items\n * are keyed primarily by Scripture reference. This is particularly useful for displaying a list of\n * results from Scripture checks, but more generally could be used to display any \"results\" from any\n * source(s). The component allows for grouping by Scripture book, source, or both. By default, it\n * displays somewhat \"tree-like\" which allows it to be more horizontally compact and intuitive. But\n * it also has the option of displaying as a traditional table with column headings (with or without\n * the source column showing).\n */\nexport default function ScriptureResultsViewer({\n sources,\n showColumnHeaders = false,\n showSourceColumn = false,\n scriptureReferenceColumnName,\n scriptureBookGroupName,\n typeColumnName,\n detailsColumnName,\n onRowSelected,\n direction = 'ltr',\n}: ScriptureResultsViewerProps) {\n const [grouping, setGrouping] = useState([]);\n const [sorting, setSorting] = useState([{ id: scrBookColId, desc: false }]);\n const [rowSelection, setRowSelection] = useState({});\n\n const scriptureResults = useMemo(\n () =>\n sources.flatMap((source) => {\n return source.data.map((item) => ({\n ...item,\n source: source.source,\n }));\n }),\n [sources],\n );\n\n const columns = useMemo(\n () =>\n getColumns(\n {\n scriptureReferenceColumnName,\n typeColumnName,\n detailsColumnName,\n },\n showSourceColumn,\n ),\n [scriptureReferenceColumnName, typeColumnName, detailsColumnName, showSourceColumn],\n );\n\n useEffect(() => {\n // Ensure sorting is applied correctly when grouped by type\n if (grouping.includes(typeColId)) {\n setSorting([\n { id: typeColId, desc: false },\n { id: scrBookColId, desc: false },\n ]);\n } else {\n setSorting([{ id: scrBookColId, desc: false }]);\n }\n }, [grouping]);\n\n const table = useReactTable({\n data: scriptureResults,\n columns,\n state: {\n grouping,\n sorting,\n rowSelection,\n },\n onGroupingChange: setGrouping,\n onSortingChange: setSorting,\n onRowSelectionChange: setRowSelection,\n getExpandedRowModel: getExpandedRowModel(),\n getGroupedRowModel: getGroupedRowModel(),\n getCoreRowModel: getCoreRowModel(),\n getSortedRowModel: getSortedRowModel(),\n getRowId: getRowKey,\n autoResetExpanded: false,\n enableMultiRowSelection: false,\n enableSubRowSelection: false,\n });\n\n useEffect(() => {\n if (onRowSelected) {\n const selectedRows = table.getSelectedRowModel().rowsById;\n const keys = Object.keys(selectedRows);\n if (keys.length === 1) {\n const selectedRow = scriptureResults.find((row) => getRowKey(row) === keys[0]) || undefined;\n if (selectedRow) onRowSelected(selectedRow);\n }\n }\n }, [rowSelection, scriptureResults, onRowSelected, table]);\n\n // Define possible grouping options\n const scrBookGroupName = scriptureBookGroupName ?? defaultScrBookGroupName;\n const typeGroupName = typeColumnName ?? defaultTypeColumnName;\n\n const groupingOptions = [\n { label: 'No Grouping', value: [] },\n { label: `Group by ${scrBookGroupName}`, value: [scrBookColId] },\n { label: `Group by ${typeGroupName}`, value: [typeColId] },\n {\n label: `Group by ${scrBookGroupName} and ${typeGroupName}`,\n value: [scrBookColId, typeColId],\n },\n {\n label: `Group by ${typeGroupName} and ${scrBookGroupName}`,\n value: [typeColId, scrBookColId],\n },\n ];\n\n const handleSelectChange = (selectedGrouping: string) => {\n setGrouping(JSON.parse(selectedGrouping));\n };\n\n const handleRowClick = (row: Row, event: MouseEvent) => {\n if (!row.getIsGrouped() && !row.getIsSelected()) {\n row.getToggleSelectedHandler()(event);\n }\n };\n\n const getEvenOrOddBandingStyle = (row: Row, index: number) => {\n if (row.getIsGrouped()) return '';\n // UX has now said they don't think they want banding. I'm leaving in the code to\n // set even and odd styles, but there's nothing in the CSS to style them differently.\n // The \"even\" style used to also have tw-bg-neutral-300 (along with even) to create\n // a visual banding effect. That could be added back in if UX changes the decision.\n return cn('banded-row', index % 2 === 0 ? 'even' : 'odd');\n };\n\n const getIndent = (\n groupingState: GroupingState,\n row: Row,\n cell: Cell,\n ) => {\n if (groupingState?.length === 0 || row.depth < cell.column.getGroupedIndex()) return undefined;\n if (row.getIsGrouped()) {\n switch (row.depth) {\n case 1:\n return 'tw-ps-4';\n default:\n return undefined;\n }\n }\n switch (row.depth) {\n case 1:\n return 'tw-ps-8';\n case 2:\n return 'tw-ps-12';\n default:\n return undefined;\n }\n };\n\n return (\n
    \n {!showColumnHeaders && (\n {\n handleSelectChange(value);\n }}\n >\n \n \n \n \n \n {groupingOptions.map((option) => (\n \n {option.label}\n \n ))}\n \n \n \n )}\n \n {showColumnHeaders && (\n \n {table.getHeaderGroups().map((headerGroup) => (\n \n {headerGroup.headers\n .filter((h) => h.column.columnDef.header)\n .map((header) => (\n /* For sticky column headers to work, we probably need to change the default definition of the shadcn Table component. See https://github.com/shadcn-ui/ui/issues/1151 */\n \n {header.isPlaceholder ? undefined : (\n
    \n {header.column.getCanGroup() ? (\n \n {header.column.getIsGrouped() ? `🛑` : `👊 `}\n \n ) : undefined}{' '}\n {flexRender(header.column.columnDef.header, header.getContext())}\n
    \n )}\n
    \n ))}\n
    \n ))}\n
    \n )}\n \n {table.getRowModel().rows.map((row, rowIndex) => {\n return (\n handleRowClick(row, event)}\n >\n {row.getVisibleCells().map((cell) => {\n if (\n cell.getIsPlaceholder() ||\n (cell.column.columnDef.enableGrouping &&\n !cell.getIsGrouped() &&\n (cell.column.columnDef.id !== typeColId || !showSourceColumn))\n )\n return undefined;\n return (\n \n {(() => {\n if (cell.getIsGrouped()) {\n return (\n \n {row.getIsExpanded() && }\n {!row.getIsExpanded() &&\n (direction === 'ltr' ? : )}{' '}\n {flexRender(cell.column.columnDef.cell, cell.getContext())} (\n {row.subRows.length})\n \n );\n }\n\n // if (cell.getIsAggregated()) {\n // flexRender(\n // cell.column.columnDef.aggregatedCell ?? cell.column.columnDef.cell,\n // cell.getContext(),\n // );\n // }\n\n return flexRender(cell.column.columnDef.cell, cell.getContext());\n })()}\n \n );\n })}\n \n );\n })}\n \n
    \n
    \n );\n}\n","import {\n getLocalizeKeyForScrollGroupId,\n LanguageStrings,\n ScrollGroupId,\n} from 'platform-bible-utils';\nimport {\n Select,\n SelectContent,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\n\nconst DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS = {\n [getLocalizeKeyForScrollGroupId('undefined')]: 'Ø',\n [getLocalizeKeyForScrollGroupId(0)]: 'A',\n [getLocalizeKeyForScrollGroupId(1)]: 'B',\n [getLocalizeKeyForScrollGroupId(2)]: 'C',\n [getLocalizeKeyForScrollGroupId(3)]: 'D',\n [getLocalizeKeyForScrollGroupId(4)]: 'E',\n [getLocalizeKeyForScrollGroupId(5)]: 'F',\n [getLocalizeKeyForScrollGroupId(6)]: 'G',\n [getLocalizeKeyForScrollGroupId(7)]: 'H',\n [getLocalizeKeyForScrollGroupId(8)]: 'I',\n [getLocalizeKeyForScrollGroupId(9)]: 'J',\n [getLocalizeKeyForScrollGroupId(10)]: 'K',\n [getLocalizeKeyForScrollGroupId(11)]: 'L',\n [getLocalizeKeyForScrollGroupId(12)]: 'M',\n [getLocalizeKeyForScrollGroupId(13)]: 'N',\n [getLocalizeKeyForScrollGroupId(14)]: 'O',\n [getLocalizeKeyForScrollGroupId(15)]: 'P',\n [getLocalizeKeyForScrollGroupId(16)]: 'Q',\n [getLocalizeKeyForScrollGroupId(17)]: 'R',\n [getLocalizeKeyForScrollGroupId(18)]: 'S',\n [getLocalizeKeyForScrollGroupId(19)]: 'T',\n [getLocalizeKeyForScrollGroupId(20)]: 'U',\n [getLocalizeKeyForScrollGroupId(21)]: 'V',\n [getLocalizeKeyForScrollGroupId(22)]: 'W',\n [getLocalizeKeyForScrollGroupId(23)]: 'X',\n [getLocalizeKeyForScrollGroupId(24)]: 'Y',\n [getLocalizeKeyForScrollGroupId(25)]: 'Z',\n};\n\nexport type ScrollGroupSelectorProps = {\n /**\n * List of scroll group ids to show to the user. Either a {@link ScrollGroupId} or `undefined` for\n * no scroll group\n */\n availableScrollGroupIds: (ScrollGroupId | undefined)[];\n /** Currently selected scroll group id. `undefined` for no scroll group */\n scrollGroupId: ScrollGroupId | undefined;\n /** Callback function run when the user tries to change the scroll group id */\n onChangeScrollGroupId: (newScrollGroupId: ScrollGroupId | undefined) => void;\n /**\n * Localized strings to use for displaying scroll group ids. Must be an object whose keys are\n * `getLocalizeKeyForScrollGroupId(scrollGroupId)` for all scroll group ids (and `undefined` if\n * included) in {@link ScrollGroupSelectorProps.availableScrollGroupIds} and whose values are the\n * localized strings to use for those scroll group ids.\n *\n * Defaults to English localizations of English alphabet for scroll groups 0-25 (e.g. 0 is A) and\n * Ø for `undefined`. Will fill in any that are not provided with these English localizations.\n * Also, if any values match the keys, the English localization will be used. This is useful in\n * case you want to pass in a temporary version of the localized strings while your localized\n * strings load.\n *\n * @example\n *\n * ```typescript\n * const myScrollGroupIdLocalizedStrings = {\n * [getLocalizeKeyForScrollGroupId('undefined')]: 'Ø',\n * [getLocalizeKeyForScrollGroupId(0)]: 'A',\n * [getLocalizeKeyForScrollGroupId(1)]: 'B',\n * [getLocalizeKeyForScrollGroupId(2)]: 'C',\n * [getLocalizeKeyForScrollGroupId(3)]: 'D',\n * [getLocalizeKeyForScrollGroupId(4)]: 'E',\n * };\n * ```\n *\n * @example\n *\n * ```tsx\n * const availableScrollGroupIds = [undefined, 0, 1, 2, 3, 4];\n *\n * const localizeKeys = getLocalizeKeysForScrollGroupIds();\n *\n * const [localizedStrings] = useLocalizedStrings(localizeKeys);\n *\n * ...\n *\n * \n * ```\n */\n localizedStrings?: LanguageStrings;\n};\n\n/** Selector component for choosing a scroll group */\nexport default function ScrollGroupSelector({\n availableScrollGroupIds,\n scrollGroupId,\n onChangeScrollGroupId,\n localizedStrings = {},\n}: ScrollGroupSelectorProps) {\n const localizedStringsDefaulted = {\n ...DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS,\n ...Object.fromEntries(\n Object.entries(localizedStrings).map(\n ([localizedStringKey, localizedStringValue]: [string, string]) => [\n localizedStringKey,\n localizedStringKey === localizedStringValue &&\n localizedStringKey in DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS\n ? DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS[localizedStringKey]\n : localizedStringValue,\n ],\n ),\n ),\n };\n return (\n \n onChangeScrollGroupId(\n newScrollGroupString === 'undefined' ? undefined : parseInt(newScrollGroupString, 10),\n )\n }\n >\n \n \n \n \n {availableScrollGroupIds.map((scrollGroupOptionId) => (\n \n {localizedStringsDefaulted[getLocalizeKeyForScrollGroupId(scrollGroupOptionId)]}\n \n ))}\n \n \n );\n}\n","import { PropsWithChildren } from 'react';\nimport { Separator } from '@/components/shadcn-ui/separator';\n\n/** Props for the SettingsList component, currently just children */\ntype SettingsListProps = PropsWithChildren;\n\n/**\n * SettingsList component is a wrapper for list items. Rendered with a formatted div\n *\n * @param children To populate the list with\n * @returns Formatted div encompassing the children\n */\nexport function SettingsList({ children }: SettingsListProps) {\n return
    {children}
    ;\n}\n\n/** Props for SettingsListItem component */\ntype SettingsListItemProps = PropsWithChildren & {\n /** Primary text of the list item */\n primary: string;\n\n /** Optional text of the list item */\n secondary?: string | undefined;\n\n /** Optional boolean to display a message if the children aren't loaded yet. Defaults to false */\n isLoading?: boolean;\n\n /** Optional message to display if isLoading */\n loadingMessage?: string;\n};\n\n/**\n * SettingsListItem component is a common list item. Rendered with a formatted div\n *\n * @param primary Primary text of the list item\n * @param secondary Optional secondary text of the list item\n * @param isLoading Optional, to display a message if the action component isn't generated yet,\n * defaults to false\n * @param children The action component(s) to provide for this item\n * @param loadingMessage Optional, message to display if isLoading\n * @returns Formatted div encompassing the list item content\n */\nexport function SettingsListItem({\n primary,\n secondary,\n children,\n isLoading = false,\n loadingMessage,\n}: SettingsListItemProps) {\n return (\n
    \n
    \n

    {primary}

    \n

    \n {secondary}\n

    \n
    \n\n {isLoading ? (\n

    {loadingMessage}

    \n ) : (\n
    {children}
    \n )}\n
    \n );\n}\n\n/** Props for SettingsListHeader component */\ntype SettingsListHeaderProps = {\n /** The primary text of the list header */\n primary: string;\n\n /** Optional secondary text of the list header */\n secondary?: string | undefined;\n\n /** Optional boolean to include a separator underneath the secondary text. Defaults to false */\n includeSeparator?: boolean;\n};\n\n/**\n * SettingsListHeader component displays text above the list\n *\n * @param primary The primary text of the list header\n * @param secondary Optional secondary text of the list header\n * @param includeSeparator Optional boolean to include a separator underneath the secondary text.\n * Defaults to false\n * @returns Formatted div with list header content\n */\nexport function SettingsListHeader({\n primary,\n secondary,\n includeSeparator = false,\n}: SettingsListHeaderProps) {\n return (\n
    \n
    \n

    {primary}

    \n

    {secondary}

    \n
    \n {includeSeparator ? : ''}\n
    \n );\n}\n","import React from 'react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Card = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nCard.displayName = 'Card';\n\nconst CardHeader = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nCardHeader.displayName = 'CardHeader';\n\nconst CardTitle = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n {/* added because of https://github.com/jsx-eslint/eslint-plugin-jsx-a11y/blob/main/docs/rules/heading-has-content.md */}\n {props.children}\n \n ),\n);\nCardTitle.displayName = 'CardTitle';\n\nconst CardDescription = React.forwardRef<\n HTMLParagraphElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n

    \n));\nCardDescription.displayName = 'CardDescription';\n\nconst CardContent = React.forwardRef>(\n ({ className, ...props }, ref) => (\n

    \n ),\n);\nCardContent.displayName = 'CardContent';\n\nconst CardFooter = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nCardFooter.displayName = 'CardFooter';\n\nexport { Card, CardHeader, CardFooter, CardTitle, CardDescription, CardContent };\n","import { Card, CardDescription, CardHeader, CardTitle } from '@/components/shadcn-ui/card';\nimport { CardContent } from '@mui/material';\nimport { PropsWithChildren } from 'react';\n\ntype SettingsCardProps = PropsWithChildren & {\n settingsGroupLabel: string;\n settingsGroupDescription: string;\n};\n\nexport default function SettingsCard({\n settingsGroupLabel,\n settingsGroupDescription,\n children,\n}: SettingsCardProps) {\n return (\n \n \n {settingsGroupLabel}\n {settingsGroupDescription}\n \n {children}\n \n );\n}\n","import Checkbox from '@/components/shadcn-ui/checkbox';\nimport { Label } from '@/components/shadcn-ui/label';\n\nexport type ChecklistProps = {\n /** Optional string representing the id attribute of the Checklist */\n id?: string;\n /** Optional string representing CSS class name(s) for styling */\n className?: string;\n /** Array of strings representing the checkable items */\n listItems: string[];\n /** Array of strings representing the checked items */\n selectedListItems: string[];\n /**\n * Function that is called when a checkbox item is selected or deselected\n *\n * @param item The string description for this item\n * @param selected True if selected, false if not selected\n */\n handleSelectListItem: (item: string, selected: boolean) => void;\n\n /**\n * Optional function creates a label for a provided checkable item\n *\n * @param item The item for which a label is to be created\n * @returns A string representing the label text for the checkbox associated with that item\n */\n createLabel?: (item: string) => string;\n};\n\n/** Renders a list of checkboxes. Each checkbox corresponds to an item from the `listItems` array. */\nexport default function Checklist({\n id,\n className,\n listItems,\n selectedListItems,\n handleSelectListItem,\n createLabel,\n}: ChecklistProps) {\n return (\n
    \n {listItems.map((item) => (\n
    \n handleSelectListItem(item, value)}\n />\n \n
    \n ))}\n
    \n );\n}\n","function _interopRequireDefault(obj) {\n return obj && obj.__esModule ? obj : {\n \"default\": obj\n };\n}\nmodule.exports = _interopRequireDefault, module.exports.__esModule = true, module.exports[\"default\"] = module.exports;","export default function chainPropTypes(propType1, propType2) {\n if (process.env.NODE_ENV === 'production') {\n return () => null;\n }\n return function validate(...args) {\n return propType1(...args) || propType2(...args);\n };\n}","export default function _extends() {\n _extends = Object.assign ? Object.assign.bind() : function (target) {\n for (var i = 1; i < arguments.length; i++) {\n var source = arguments[i];\n for (var key in source) {\n if (Object.prototype.hasOwnProperty.call(source, key)) {\n target[key] = source[key];\n }\n }\n }\n return target;\n };\n return _extends.apply(this, arguments);\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\n// https://github.com/sindresorhus/is-plain-obj/blob/main/index.js\nexport function isPlainObject(item) {\n if (typeof item !== 'object' || item === null) {\n return false;\n }\n const prototype = Object.getPrototypeOf(item);\n return (prototype === null || prototype === Object.prototype || Object.getPrototypeOf(prototype) === null) && !(Symbol.toStringTag in item) && !(Symbol.iterator in item);\n}\nfunction deepClone(source) {\n if (!isPlainObject(source)) {\n return source;\n }\n const output = {};\n Object.keys(source).forEach(key => {\n output[key] = deepClone(source[key]);\n });\n return output;\n}\nexport default function deepmerge(target, source, options = {\n clone: true\n}) {\n const output = options.clone ? _extends({}, target) : target;\n if (isPlainObject(target) && isPlainObject(source)) {\n Object.keys(source).forEach(key => {\n // Avoid prototype pollution\n if (key === '__proto__') {\n return;\n }\n if (isPlainObject(source[key]) && key in target && isPlainObject(target[key])) {\n // Since `output` is a clone of `target` and we have narrowed `target` in this block we can cast to the same type.\n output[key] = deepmerge(target[key], source[key], options);\n } else if (options.clone) {\n output[key] = isPlainObject(source[key]) ? deepClone(source[key]) : source[key];\n } else {\n output[key] = source[key];\n }\n });\n }\n return output;\n}","/** @license React v16.13.1\n * react-is.production.min.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';var b=\"function\"===typeof Symbol&&Symbol.for,c=b?Symbol.for(\"react.element\"):60103,d=b?Symbol.for(\"react.portal\"):60106,e=b?Symbol.for(\"react.fragment\"):60107,f=b?Symbol.for(\"react.strict_mode\"):60108,g=b?Symbol.for(\"react.profiler\"):60114,h=b?Symbol.for(\"react.provider\"):60109,k=b?Symbol.for(\"react.context\"):60110,l=b?Symbol.for(\"react.async_mode\"):60111,m=b?Symbol.for(\"react.concurrent_mode\"):60111,n=b?Symbol.for(\"react.forward_ref\"):60112,p=b?Symbol.for(\"react.suspense\"):60113,q=b?\nSymbol.for(\"react.suspense_list\"):60120,r=b?Symbol.for(\"react.memo\"):60115,t=b?Symbol.for(\"react.lazy\"):60116,v=b?Symbol.for(\"react.block\"):60121,w=b?Symbol.for(\"react.fundamental\"):60117,x=b?Symbol.for(\"react.responder\"):60118,y=b?Symbol.for(\"react.scope\"):60119;\nfunction z(a){if(\"object\"===typeof a&&null!==a){var u=a.$$typeof;switch(u){case c:switch(a=a.type,a){case l:case m:case e:case g:case f:case p:return a;default:switch(a=a&&a.$$typeof,a){case k:case n:case t:case r:case h:return a;default:return u}}case d:return u}}}function A(a){return z(a)===m}exports.AsyncMode=l;exports.ConcurrentMode=m;exports.ContextConsumer=k;exports.ContextProvider=h;exports.Element=c;exports.ForwardRef=n;exports.Fragment=e;exports.Lazy=t;exports.Memo=r;exports.Portal=d;\nexports.Profiler=g;exports.StrictMode=f;exports.Suspense=p;exports.isAsyncMode=function(a){return A(a)||z(a)===l};exports.isConcurrentMode=A;exports.isContextConsumer=function(a){return z(a)===k};exports.isContextProvider=function(a){return z(a)===h};exports.isElement=function(a){return\"object\"===typeof a&&null!==a&&a.$$typeof===c};exports.isForwardRef=function(a){return z(a)===n};exports.isFragment=function(a){return z(a)===e};exports.isLazy=function(a){return z(a)===t};\nexports.isMemo=function(a){return z(a)===r};exports.isPortal=function(a){return z(a)===d};exports.isProfiler=function(a){return z(a)===g};exports.isStrictMode=function(a){return z(a)===f};exports.isSuspense=function(a){return z(a)===p};\nexports.isValidElementType=function(a){return\"string\"===typeof a||\"function\"===typeof a||a===e||a===m||a===g||a===f||a===p||a===q||\"object\"===typeof a&&null!==a&&(a.$$typeof===t||a.$$typeof===r||a.$$typeof===h||a.$$typeof===k||a.$$typeof===n||a.$$typeof===w||a.$$typeof===x||a.$$typeof===y||a.$$typeof===v)};exports.typeOf=z;\n","/** @license React v16.13.1\n * react-is.development.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\n\n\nif (process.env.NODE_ENV !== \"production\") {\n (function() {\n'use strict';\n\n// The Symbol used to tag the ReactElement-like types. If there is no native Symbol\n// nor polyfill, then a plain number is used for performance.\nvar hasSymbol = typeof Symbol === 'function' && Symbol.for;\nvar REACT_ELEMENT_TYPE = hasSymbol ? Symbol.for('react.element') : 0xeac7;\nvar REACT_PORTAL_TYPE = hasSymbol ? Symbol.for('react.portal') : 0xeaca;\nvar REACT_FRAGMENT_TYPE = hasSymbol ? Symbol.for('react.fragment') : 0xeacb;\nvar REACT_STRICT_MODE_TYPE = hasSymbol ? Symbol.for('react.strict_mode') : 0xeacc;\nvar REACT_PROFILER_TYPE = hasSymbol ? Symbol.for('react.profiler') : 0xead2;\nvar REACT_PROVIDER_TYPE = hasSymbol ? Symbol.for('react.provider') : 0xeacd;\nvar REACT_CONTEXT_TYPE = hasSymbol ? Symbol.for('react.context') : 0xeace; // TODO: We don't use AsyncMode or ConcurrentMode anymore. They were temporary\n// (unstable) APIs that have been removed. Can we remove the symbols?\n\nvar REACT_ASYNC_MODE_TYPE = hasSymbol ? Symbol.for('react.async_mode') : 0xeacf;\nvar REACT_CONCURRENT_MODE_TYPE = hasSymbol ? Symbol.for('react.concurrent_mode') : 0xeacf;\nvar REACT_FORWARD_REF_TYPE = hasSymbol ? Symbol.for('react.forward_ref') : 0xead0;\nvar REACT_SUSPENSE_TYPE = hasSymbol ? Symbol.for('react.suspense') : 0xead1;\nvar REACT_SUSPENSE_LIST_TYPE = hasSymbol ? Symbol.for('react.suspense_list') : 0xead8;\nvar REACT_MEMO_TYPE = hasSymbol ? Symbol.for('react.memo') : 0xead3;\nvar REACT_LAZY_TYPE = hasSymbol ? Symbol.for('react.lazy') : 0xead4;\nvar REACT_BLOCK_TYPE = hasSymbol ? Symbol.for('react.block') : 0xead9;\nvar REACT_FUNDAMENTAL_TYPE = hasSymbol ? Symbol.for('react.fundamental') : 0xead5;\nvar REACT_RESPONDER_TYPE = hasSymbol ? Symbol.for('react.responder') : 0xead6;\nvar REACT_SCOPE_TYPE = hasSymbol ? Symbol.for('react.scope') : 0xead7;\n\nfunction isValidElementType(type) {\n return typeof type === 'string' || typeof type === 'function' || // Note: its typeof might be other than 'symbol' or 'number' if it's a polyfill.\n type === REACT_FRAGMENT_TYPE || type === REACT_CONCURRENT_MODE_TYPE || type === REACT_PROFILER_TYPE || type === REACT_STRICT_MODE_TYPE || type === REACT_SUSPENSE_TYPE || type === REACT_SUSPENSE_LIST_TYPE || typeof type === 'object' && type !== null && (type.$$typeof === REACT_LAZY_TYPE || type.$$typeof === REACT_MEMO_TYPE || type.$$typeof === REACT_PROVIDER_TYPE || type.$$typeof === REACT_CONTEXT_TYPE || type.$$typeof === REACT_FORWARD_REF_TYPE || type.$$typeof === REACT_FUNDAMENTAL_TYPE || type.$$typeof === REACT_RESPONDER_TYPE || type.$$typeof === REACT_SCOPE_TYPE || type.$$typeof === REACT_BLOCK_TYPE);\n}\n\nfunction typeOf(object) {\n if (typeof object === 'object' && object !== null) {\n var $$typeof = object.$$typeof;\n\n switch ($$typeof) {\n case REACT_ELEMENT_TYPE:\n var type = object.type;\n\n switch (type) {\n case REACT_ASYNC_MODE_TYPE:\n case REACT_CONCURRENT_MODE_TYPE:\n case REACT_FRAGMENT_TYPE:\n case REACT_PROFILER_TYPE:\n case REACT_STRICT_MODE_TYPE:\n case REACT_SUSPENSE_TYPE:\n return type;\n\n default:\n var $$typeofType = type && type.$$typeof;\n\n switch ($$typeofType) {\n case REACT_CONTEXT_TYPE:\n case REACT_FORWARD_REF_TYPE:\n case REACT_LAZY_TYPE:\n case REACT_MEMO_TYPE:\n case REACT_PROVIDER_TYPE:\n return $$typeofType;\n\n default:\n return $$typeof;\n }\n\n }\n\n case REACT_PORTAL_TYPE:\n return $$typeof;\n }\n }\n\n return undefined;\n} // AsyncMode is deprecated along with isAsyncMode\n\nvar AsyncMode = REACT_ASYNC_MODE_TYPE;\nvar ConcurrentMode = REACT_CONCURRENT_MODE_TYPE;\nvar ContextConsumer = REACT_CONTEXT_TYPE;\nvar ContextProvider = REACT_PROVIDER_TYPE;\nvar Element = REACT_ELEMENT_TYPE;\nvar ForwardRef = REACT_FORWARD_REF_TYPE;\nvar Fragment = REACT_FRAGMENT_TYPE;\nvar Lazy = REACT_LAZY_TYPE;\nvar Memo = REACT_MEMO_TYPE;\nvar Portal = REACT_PORTAL_TYPE;\nvar Profiler = REACT_PROFILER_TYPE;\nvar StrictMode = REACT_STRICT_MODE_TYPE;\nvar Suspense = REACT_SUSPENSE_TYPE;\nvar hasWarnedAboutDeprecatedIsAsyncMode = false; // AsyncMode should be deprecated\n\nfunction isAsyncMode(object) {\n {\n if (!hasWarnedAboutDeprecatedIsAsyncMode) {\n hasWarnedAboutDeprecatedIsAsyncMode = true; // Using console['warn'] to evade Babel and ESLint\n\n console['warn']('The ReactIs.isAsyncMode() alias has been deprecated, ' + 'and will be removed in React 17+. Update your code to use ' + 'ReactIs.isConcurrentMode() instead. It has the exact same API.');\n }\n }\n\n return isConcurrentMode(object) || typeOf(object) === REACT_ASYNC_MODE_TYPE;\n}\nfunction isConcurrentMode(object) {\n return typeOf(object) === REACT_CONCURRENT_MODE_TYPE;\n}\nfunction isContextConsumer(object) {\n return typeOf(object) === REACT_CONTEXT_TYPE;\n}\nfunction isContextProvider(object) {\n return typeOf(object) === REACT_PROVIDER_TYPE;\n}\nfunction isElement(object) {\n return typeof object === 'object' && object !== null && object.$$typeof === REACT_ELEMENT_TYPE;\n}\nfunction isForwardRef(object) {\n return typeOf(object) === REACT_FORWARD_REF_TYPE;\n}\nfunction isFragment(object) {\n return typeOf(object) === REACT_FRAGMENT_TYPE;\n}\nfunction isLazy(object) {\n return typeOf(object) === REACT_LAZY_TYPE;\n}\nfunction isMemo(object) {\n return typeOf(object) === REACT_MEMO_TYPE;\n}\nfunction isPortal(object) {\n return typeOf(object) === REACT_PORTAL_TYPE;\n}\nfunction isProfiler(object) {\n return typeOf(object) === REACT_PROFILER_TYPE;\n}\nfunction isStrictMode(object) {\n return typeOf(object) === REACT_STRICT_MODE_TYPE;\n}\nfunction isSuspense(object) {\n return typeOf(object) === REACT_SUSPENSE_TYPE;\n}\n\nexports.AsyncMode = AsyncMode;\nexports.ConcurrentMode = ConcurrentMode;\nexports.ContextConsumer = ContextConsumer;\nexports.ContextProvider = ContextProvider;\nexports.Element = Element;\nexports.ForwardRef = ForwardRef;\nexports.Fragment = Fragment;\nexports.Lazy = Lazy;\nexports.Memo = Memo;\nexports.Portal = Portal;\nexports.Profiler = Profiler;\nexports.StrictMode = StrictMode;\nexports.Suspense = Suspense;\nexports.isAsyncMode = isAsyncMode;\nexports.isConcurrentMode = isConcurrentMode;\nexports.isContextConsumer = isContextConsumer;\nexports.isContextProvider = isContextProvider;\nexports.isElement = isElement;\nexports.isForwardRef = isForwardRef;\nexports.isFragment = isFragment;\nexports.isLazy = isLazy;\nexports.isMemo = isMemo;\nexports.isPortal = isPortal;\nexports.isProfiler = isProfiler;\nexports.isStrictMode = isStrictMode;\nexports.isSuspense = isSuspense;\nexports.isValidElementType = isValidElementType;\nexports.typeOf = typeOf;\n })();\n}\n","'use strict';\n\nif (process.env.NODE_ENV === 'production') {\n module.exports = require('./cjs/react-is.production.min.js');\n} else {\n module.exports = require('./cjs/react-is.development.js');\n}\n","/*\nobject-assign\n(c) Sindre Sorhus\n@license MIT\n*/\n\n'use strict';\n/* eslint-disable no-unused-vars */\nvar getOwnPropertySymbols = Object.getOwnPropertySymbols;\nvar hasOwnProperty = Object.prototype.hasOwnProperty;\nvar propIsEnumerable = Object.prototype.propertyIsEnumerable;\n\nfunction toObject(val) {\n\tif (val === null || val === undefined) {\n\t\tthrow new TypeError('Object.assign cannot be called with null or undefined');\n\t}\n\n\treturn Object(val);\n}\n\nfunction shouldUseNative() {\n\ttry {\n\t\tif (!Object.assign) {\n\t\t\treturn false;\n\t\t}\n\n\t\t// Detect buggy property enumeration order in older V8 versions.\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=4118\n\t\tvar test1 = new String('abc'); // eslint-disable-line no-new-wrappers\n\t\ttest1[5] = 'de';\n\t\tif (Object.getOwnPropertyNames(test1)[0] === '5') {\n\t\t\treturn false;\n\t\t}\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=3056\n\t\tvar test2 = {};\n\t\tfor (var i = 0; i < 10; i++) {\n\t\t\ttest2['_' + String.fromCharCode(i)] = i;\n\t\t}\n\t\tvar order2 = Object.getOwnPropertyNames(test2).map(function (n) {\n\t\t\treturn test2[n];\n\t\t});\n\t\tif (order2.join('') !== '0123456789') {\n\t\t\treturn false;\n\t\t}\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=3056\n\t\tvar test3 = {};\n\t\t'abcdefghijklmnopqrst'.split('').forEach(function (letter) {\n\t\t\ttest3[letter] = letter;\n\t\t});\n\t\tif (Object.keys(Object.assign({}, test3)).join('') !==\n\t\t\t\t'abcdefghijklmnopqrst') {\n\t\t\treturn false;\n\t\t}\n\n\t\treturn true;\n\t} catch (err) {\n\t\t// We don't expect any of the above to throw, but better to be safe.\n\t\treturn false;\n\t}\n}\n\nmodule.exports = shouldUseNative() ? Object.assign : function (target, source) {\n\tvar from;\n\tvar to = toObject(target);\n\tvar symbols;\n\n\tfor (var s = 1; s < arguments.length; s++) {\n\t\tfrom = Object(arguments[s]);\n\n\t\tfor (var key in from) {\n\t\t\tif (hasOwnProperty.call(from, key)) {\n\t\t\t\tto[key] = from[key];\n\t\t\t}\n\t\t}\n\n\t\tif (getOwnPropertySymbols) {\n\t\t\tsymbols = getOwnPropertySymbols(from);\n\t\t\tfor (var i = 0; i < symbols.length; i++) {\n\t\t\t\tif (propIsEnumerable.call(from, symbols[i])) {\n\t\t\t\t\tto[symbols[i]] = from[symbols[i]];\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\n\treturn to;\n};\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar ReactPropTypesSecret = 'SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED';\n\nmodule.exports = ReactPropTypesSecret;\n","module.exports = Function.call.bind(Object.prototype.hasOwnProperty);\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar printWarning = function() {};\n\nif (process.env.NODE_ENV !== 'production') {\n var ReactPropTypesSecret = require('./lib/ReactPropTypesSecret');\n var loggedTypeFailures = {};\n var has = require('./lib/has');\n\n printWarning = function(text) {\n var message = 'Warning: ' + text;\n if (typeof console !== 'undefined') {\n console.error(message);\n }\n try {\n // --- Welcome to debugging React ---\n // This error was thrown as a convenience so that you can use this stack\n // to find the callsite that caused this warning to fire.\n throw new Error(message);\n } catch (x) { /**/ }\n };\n}\n\n/**\n * Assert that the values match with the type specs.\n * Error messages are memorized and will only be shown once.\n *\n * @param {object} typeSpecs Map of name to a ReactPropType\n * @param {object} values Runtime values that need to be type-checked\n * @param {string} location e.g. \"prop\", \"context\", \"child context\"\n * @param {string} componentName Name of the component for error messages.\n * @param {?Function} getStack Returns the component stack.\n * @private\n */\nfunction checkPropTypes(typeSpecs, values, location, componentName, getStack) {\n if (process.env.NODE_ENV !== 'production') {\n for (var typeSpecName in typeSpecs) {\n if (has(typeSpecs, typeSpecName)) {\n var error;\n // Prop type validation may throw. In case they do, we don't want to\n // fail the render phase where it didn't fail before. So we log it.\n // After these have been cleaned up, we'll let them throw.\n try {\n // This is intentionally an invariant that gets caught. It's the same\n // behavior as without this statement except with a better message.\n if (typeof typeSpecs[typeSpecName] !== 'function') {\n var err = Error(\n (componentName || 'React class') + ': ' + location + ' type `' + typeSpecName + '` is invalid; ' +\n 'it must be a function, usually from the `prop-types` package, but received `' + typeof typeSpecs[typeSpecName] + '`.' +\n 'This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.'\n );\n err.name = 'Invariant Violation';\n throw err;\n }\n error = typeSpecs[typeSpecName](values, typeSpecName, componentName, location, null, ReactPropTypesSecret);\n } catch (ex) {\n error = ex;\n }\n if (error && !(error instanceof Error)) {\n printWarning(\n (componentName || 'React class') + ': type specification of ' +\n location + ' `' + typeSpecName + '` is invalid; the type checker ' +\n 'function must return `null` or an `Error` but returned a ' + typeof error + '. ' +\n 'You may have forgotten to pass an argument to the type checker ' +\n 'creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and ' +\n 'shape all require an argument).'\n );\n }\n if (error instanceof Error && !(error.message in loggedTypeFailures)) {\n // Only monitor this failure once because there tends to be a lot of the\n // same error.\n loggedTypeFailures[error.message] = true;\n\n var stack = getStack ? getStack() : '';\n\n printWarning(\n 'Failed ' + location + ' type: ' + error.message + (stack != null ? stack : '')\n );\n }\n }\n }\n }\n}\n\n/**\n * Resets warning cache when testing.\n *\n * @private\n */\ncheckPropTypes.resetWarningCache = function() {\n if (process.env.NODE_ENV !== 'production') {\n loggedTypeFailures = {};\n }\n}\n\nmodule.exports = checkPropTypes;\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar ReactIs = require('react-is');\nvar assign = require('object-assign');\n\nvar ReactPropTypesSecret = require('./lib/ReactPropTypesSecret');\nvar has = require('./lib/has');\nvar checkPropTypes = require('./checkPropTypes');\n\nvar printWarning = function() {};\n\nif (process.env.NODE_ENV !== 'production') {\n printWarning = function(text) {\n var message = 'Warning: ' + text;\n if (typeof console !== 'undefined') {\n console.error(message);\n }\n try {\n // --- Welcome to debugging React ---\n // This error was thrown as a convenience so that you can use this stack\n // to find the callsite that caused this warning to fire.\n throw new Error(message);\n } catch (x) {}\n };\n}\n\nfunction emptyFunctionThatReturnsNull() {\n return null;\n}\n\nmodule.exports = function(isValidElement, throwOnDirectAccess) {\n /* global Symbol */\n var ITERATOR_SYMBOL = typeof Symbol === 'function' && Symbol.iterator;\n var FAUX_ITERATOR_SYMBOL = '@@iterator'; // Before Symbol spec.\n\n /**\n * Returns the iterator method function contained on the iterable object.\n *\n * Be sure to invoke the function with the iterable as context:\n *\n * var iteratorFn = getIteratorFn(myIterable);\n * if (iteratorFn) {\n * var iterator = iteratorFn.call(myIterable);\n * ...\n * }\n *\n * @param {?object} maybeIterable\n * @return {?function}\n */\n function getIteratorFn(maybeIterable) {\n var iteratorFn = maybeIterable && (ITERATOR_SYMBOL && maybeIterable[ITERATOR_SYMBOL] || maybeIterable[FAUX_ITERATOR_SYMBOL]);\n if (typeof iteratorFn === 'function') {\n return iteratorFn;\n }\n }\n\n /**\n * Collection of methods that allow declaration and validation of props that are\n * supplied to React components. Example usage:\n *\n * var Props = require('ReactPropTypes');\n * var MyArticle = React.createClass({\n * propTypes: {\n * // An optional string prop named \"description\".\n * description: Props.string,\n *\n * // A required enum prop named \"category\".\n * category: Props.oneOf(['News','Photos']).isRequired,\n *\n * // A prop named \"dialog\" that requires an instance of Dialog.\n * dialog: Props.instanceOf(Dialog).isRequired\n * },\n * render: function() { ... }\n * });\n *\n * A more formal specification of how these methods are used:\n *\n * type := array|bool|func|object|number|string|oneOf([...])|instanceOf(...)\n * decl := ReactPropTypes.{type}(.isRequired)?\n *\n * Each and every declaration produces a function with the same signature. This\n * allows the creation of custom validation functions. For example:\n *\n * var MyLink = React.createClass({\n * propTypes: {\n * // An optional string or URI prop named \"href\".\n * href: function(props, propName, componentName) {\n * var propValue = props[propName];\n * if (propValue != null && typeof propValue !== 'string' &&\n * !(propValue instanceof URI)) {\n * return new Error(\n * 'Expected a string or an URI for ' + propName + ' in ' +\n * componentName\n * );\n * }\n * }\n * },\n * render: function() {...}\n * });\n *\n * @internal\n */\n\n var ANONYMOUS = '<>';\n\n // Important!\n // Keep this list in sync with production version in `./factoryWithThrowingShims.js`.\n var ReactPropTypes = {\n array: createPrimitiveTypeChecker('array'),\n bigint: createPrimitiveTypeChecker('bigint'),\n bool: createPrimitiveTypeChecker('boolean'),\n func: createPrimitiveTypeChecker('function'),\n number: createPrimitiveTypeChecker('number'),\n object: createPrimitiveTypeChecker('object'),\n string: createPrimitiveTypeChecker('string'),\n symbol: createPrimitiveTypeChecker('symbol'),\n\n any: createAnyTypeChecker(),\n arrayOf: createArrayOfTypeChecker,\n element: createElementTypeChecker(),\n elementType: createElementTypeTypeChecker(),\n instanceOf: createInstanceTypeChecker,\n node: createNodeChecker(),\n objectOf: createObjectOfTypeChecker,\n oneOf: createEnumTypeChecker,\n oneOfType: createUnionTypeChecker,\n shape: createShapeTypeChecker,\n exact: createStrictShapeTypeChecker,\n };\n\n /**\n * inlined Object.is polyfill to avoid requiring consumers ship their own\n * https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object/is\n */\n /*eslint-disable no-self-compare*/\n function is(x, y) {\n // SameValue algorithm\n if (x === y) {\n // Steps 1-5, 7-10\n // Steps 6.b-6.e: +0 != -0\n return x !== 0 || 1 / x === 1 / y;\n } else {\n // Step 6.a: NaN == NaN\n return x !== x && y !== y;\n }\n }\n /*eslint-enable no-self-compare*/\n\n /**\n * We use an Error-like object for backward compatibility as people may call\n * PropTypes directly and inspect their output. However, we don't use real\n * Errors anymore. We don't inspect their stack anyway, and creating them\n * is prohibitively expensive if they are created too often, such as what\n * happens in oneOfType() for any type before the one that matched.\n */\n function PropTypeError(message, data) {\n this.message = message;\n this.data = data && typeof data === 'object' ? data: {};\n this.stack = '';\n }\n // Make `instanceof Error` still work for returned errors.\n PropTypeError.prototype = Error.prototype;\n\n function createChainableTypeChecker(validate) {\n if (process.env.NODE_ENV !== 'production') {\n var manualPropTypeCallCache = {};\n var manualPropTypeWarningCount = 0;\n }\n function checkType(isRequired, props, propName, componentName, location, propFullName, secret) {\n componentName = componentName || ANONYMOUS;\n propFullName = propFullName || propName;\n\n if (secret !== ReactPropTypesSecret) {\n if (throwOnDirectAccess) {\n // New behavior only for users of `prop-types` package\n var err = new Error(\n 'Calling PropTypes validators directly is not supported by the `prop-types` package. ' +\n 'Use `PropTypes.checkPropTypes()` to call them. ' +\n 'Read more at http://fb.me/use-check-prop-types'\n );\n err.name = 'Invariant Violation';\n throw err;\n } else if (process.env.NODE_ENV !== 'production' && typeof console !== 'undefined') {\n // Old behavior for people using React.PropTypes\n var cacheKey = componentName + ':' + propName;\n if (\n !manualPropTypeCallCache[cacheKey] &&\n // Avoid spamming the console because they are often not actionable except for lib authors\n manualPropTypeWarningCount < 3\n ) {\n printWarning(\n 'You are manually calling a React.PropTypes validation ' +\n 'function for the `' + propFullName + '` prop on `' + componentName + '`. This is deprecated ' +\n 'and will throw in the standalone `prop-types` package. ' +\n 'You may be seeing this warning due to a third-party PropTypes ' +\n 'library. See https://fb.me/react-warning-dont-call-proptypes ' + 'for details.'\n );\n manualPropTypeCallCache[cacheKey] = true;\n manualPropTypeWarningCount++;\n }\n }\n }\n if (props[propName] == null) {\n if (isRequired) {\n if (props[propName] === null) {\n return new PropTypeError('The ' + location + ' `' + propFullName + '` is marked as required ' + ('in `' + componentName + '`, but its value is `null`.'));\n }\n return new PropTypeError('The ' + location + ' `' + propFullName + '` is marked as required in ' + ('`' + componentName + '`, but its value is `undefined`.'));\n }\n return null;\n } else {\n return validate(props, propName, componentName, location, propFullName);\n }\n }\n\n var chainedCheckType = checkType.bind(null, false);\n chainedCheckType.isRequired = checkType.bind(null, true);\n\n return chainedCheckType;\n }\n\n function createPrimitiveTypeChecker(expectedType) {\n function validate(props, propName, componentName, location, propFullName, secret) {\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== expectedType) {\n // `propValue` being instance of, say, date/regexp, pass the 'object'\n // check, but we can offer a more precise error message here rather than\n // 'of type `object`'.\n var preciseType = getPreciseType(propValue);\n\n return new PropTypeError(\n 'Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + preciseType + '` supplied to `' + componentName + '`, expected ') + ('`' + expectedType + '`.'),\n {expectedType: expectedType}\n );\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createAnyTypeChecker() {\n return createChainableTypeChecker(emptyFunctionThatReturnsNull);\n }\n\n function createArrayOfTypeChecker(typeChecker) {\n function validate(props, propName, componentName, location, propFullName) {\n if (typeof typeChecker !== 'function') {\n return new PropTypeError('Property `' + propFullName + '` of component `' + componentName + '` has invalid PropType notation inside arrayOf.');\n }\n var propValue = props[propName];\n if (!Array.isArray(propValue)) {\n var propType = getPropType(propValue);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected an array.'));\n }\n for (var i = 0; i < propValue.length; i++) {\n var error = typeChecker(propValue, i, componentName, location, propFullName + '[' + i + ']', ReactPropTypesSecret);\n if (error instanceof Error) {\n return error;\n }\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createElementTypeChecker() {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n if (!isValidElement(propValue)) {\n var propType = getPropType(propValue);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected a single ReactElement.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createElementTypeTypeChecker() {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n if (!ReactIs.isValidElementType(propValue)) {\n var propType = getPropType(propValue);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected a single ReactElement type.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createInstanceTypeChecker(expectedClass) {\n function validate(props, propName, componentName, location, propFullName) {\n if (!(props[propName] instanceof expectedClass)) {\n var expectedClassName = expectedClass.name || ANONYMOUS;\n var actualClassName = getClassName(props[propName]);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + actualClassName + '` supplied to `' + componentName + '`, expected ') + ('instance of `' + expectedClassName + '`.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createEnumTypeChecker(expectedValues) {\n if (!Array.isArray(expectedValues)) {\n if (process.env.NODE_ENV !== 'production') {\n if (arguments.length > 1) {\n printWarning(\n 'Invalid arguments supplied to oneOf, expected an array, got ' + arguments.length + ' arguments. ' +\n 'A common mistake is to write oneOf(x, y, z) instead of oneOf([x, y, z]).'\n );\n } else {\n printWarning('Invalid argument supplied to oneOf, expected an array.');\n }\n }\n return emptyFunctionThatReturnsNull;\n }\n\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n for (var i = 0; i < expectedValues.length; i++) {\n if (is(propValue, expectedValues[i])) {\n return null;\n }\n }\n\n var valuesString = JSON.stringify(expectedValues, function replacer(key, value) {\n var type = getPreciseType(value);\n if (type === 'symbol') {\n return String(value);\n }\n return value;\n });\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of value `' + String(propValue) + '` ' + ('supplied to `' + componentName + '`, expected one of ' + valuesString + '.'));\n }\n return createChainableTypeChecker(validate);\n }\n\n function createObjectOfTypeChecker(typeChecker) {\n function validate(props, propName, componentName, location, propFullName) {\n if (typeof typeChecker !== 'function') {\n return new PropTypeError('Property `' + propFullName + '` of component `' + componentName + '` has invalid PropType notation inside objectOf.');\n }\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== 'object') {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected an object.'));\n }\n for (var key in propValue) {\n if (has(propValue, key)) {\n var error = typeChecker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret);\n if (error instanceof Error) {\n return error;\n }\n }\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createUnionTypeChecker(arrayOfTypeCheckers) {\n if (!Array.isArray(arrayOfTypeCheckers)) {\n process.env.NODE_ENV !== 'production' ? printWarning('Invalid argument supplied to oneOfType, expected an instance of array.') : void 0;\n return emptyFunctionThatReturnsNull;\n }\n\n for (var i = 0; i < arrayOfTypeCheckers.length; i++) {\n var checker = arrayOfTypeCheckers[i];\n if (typeof checker !== 'function') {\n printWarning(\n 'Invalid argument supplied to oneOfType. Expected an array of check functions, but ' +\n 'received ' + getPostfixForTypeWarning(checker) + ' at index ' + i + '.'\n );\n return emptyFunctionThatReturnsNull;\n }\n }\n\n function validate(props, propName, componentName, location, propFullName) {\n var expectedTypes = [];\n for (var i = 0; i < arrayOfTypeCheckers.length; i++) {\n var checker = arrayOfTypeCheckers[i];\n var checkerResult = checker(props, propName, componentName, location, propFullName, ReactPropTypesSecret);\n if (checkerResult == null) {\n return null;\n }\n if (checkerResult.data && has(checkerResult.data, 'expectedType')) {\n expectedTypes.push(checkerResult.data.expectedType);\n }\n }\n var expectedTypesMessage = (expectedTypes.length > 0) ? ', expected one of type [' + expectedTypes.join(', ') + ']': '';\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` supplied to ' + ('`' + componentName + '`' + expectedTypesMessage + '.'));\n }\n return createChainableTypeChecker(validate);\n }\n\n function createNodeChecker() {\n function validate(props, propName, componentName, location, propFullName) {\n if (!isNode(props[propName])) {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` supplied to ' + ('`' + componentName + '`, expected a ReactNode.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function invalidValidatorError(componentName, location, propFullName, key, type) {\n return new PropTypeError(\n (componentName || 'React class') + ': ' + location + ' type `' + propFullName + '.' + key + '` is invalid; ' +\n 'it must be a function, usually from the `prop-types` package, but received `' + type + '`.'\n );\n }\n\n function createShapeTypeChecker(shapeTypes) {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== 'object') {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type `' + propType + '` ' + ('supplied to `' + componentName + '`, expected `object`.'));\n }\n for (var key in shapeTypes) {\n var checker = shapeTypes[key];\n if (typeof checker !== 'function') {\n return invalidValidatorError(componentName, location, propFullName, key, getPreciseType(checker));\n }\n var error = checker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret);\n if (error) {\n return error;\n }\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createStrictShapeTypeChecker(shapeTypes) {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== 'object') {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type `' + propType + '` ' + ('supplied to `' + componentName + '`, expected `object`.'));\n }\n // We need to check all keys in case some are required but missing from props.\n var allKeys = assign({}, props[propName], shapeTypes);\n for (var key in allKeys) {\n var checker = shapeTypes[key];\n if (has(shapeTypes, key) && typeof checker !== 'function') {\n return invalidValidatorError(componentName, location, propFullName, key, getPreciseType(checker));\n }\n if (!checker) {\n return new PropTypeError(\n 'Invalid ' + location + ' `' + propFullName + '` key `' + key + '` supplied to `' + componentName + '`.' +\n '\\nBad object: ' + JSON.stringify(props[propName], null, ' ') +\n '\\nValid keys: ' + JSON.stringify(Object.keys(shapeTypes), null, ' ')\n );\n }\n var error = checker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret);\n if (error) {\n return error;\n }\n }\n return null;\n }\n\n return createChainableTypeChecker(validate);\n }\n\n function isNode(propValue) {\n switch (typeof propValue) {\n case 'number':\n case 'string':\n case 'undefined':\n return true;\n case 'boolean':\n return !propValue;\n case 'object':\n if (Array.isArray(propValue)) {\n return propValue.every(isNode);\n }\n if (propValue === null || isValidElement(propValue)) {\n return true;\n }\n\n var iteratorFn = getIteratorFn(propValue);\n if (iteratorFn) {\n var iterator = iteratorFn.call(propValue);\n var step;\n if (iteratorFn !== propValue.entries) {\n while (!(step = iterator.next()).done) {\n if (!isNode(step.value)) {\n return false;\n }\n }\n } else {\n // Iterator will provide entry [k,v] tuples rather than values.\n while (!(step = iterator.next()).done) {\n var entry = step.value;\n if (entry) {\n if (!isNode(entry[1])) {\n return false;\n }\n }\n }\n }\n } else {\n return false;\n }\n\n return true;\n default:\n return false;\n }\n }\n\n function isSymbol(propType, propValue) {\n // Native Symbol.\n if (propType === 'symbol') {\n return true;\n }\n\n // falsy value can't be a Symbol\n if (!propValue) {\n return false;\n }\n\n // 19.4.3.5 Symbol.prototype[@@toStringTag] === 'Symbol'\n if (propValue['@@toStringTag'] === 'Symbol') {\n return true;\n }\n\n // Fallback for non-spec compliant Symbols which are polyfilled.\n if (typeof Symbol === 'function' && propValue instanceof Symbol) {\n return true;\n }\n\n return false;\n }\n\n // Equivalent of `typeof` but with special handling for array and regexp.\n function getPropType(propValue) {\n var propType = typeof propValue;\n if (Array.isArray(propValue)) {\n return 'array';\n }\n if (propValue instanceof RegExp) {\n // Old webkits (at least until Android 4.0) return 'function' rather than\n // 'object' for typeof a RegExp. We'll normalize this here so that /bla/\n // passes PropTypes.object.\n return 'object';\n }\n if (isSymbol(propType, propValue)) {\n return 'symbol';\n }\n return propType;\n }\n\n // This handles more types than `getPropType`. Only used for error messages.\n // See `createPrimitiveTypeChecker`.\n function getPreciseType(propValue) {\n if (typeof propValue === 'undefined' || propValue === null) {\n return '' + propValue;\n }\n var propType = getPropType(propValue);\n if (propType === 'object') {\n if (propValue instanceof Date) {\n return 'date';\n } else if (propValue instanceof RegExp) {\n return 'regexp';\n }\n }\n return propType;\n }\n\n // Returns a string that is postfixed to a warning about an invalid type.\n // For example, \"undefined\" or \"of type array\"\n function getPostfixForTypeWarning(value) {\n var type = getPreciseType(value);\n switch (type) {\n case 'array':\n case 'object':\n return 'an ' + type;\n case 'boolean':\n case 'date':\n case 'regexp':\n return 'a ' + type;\n default:\n return type;\n }\n }\n\n // Returns class name of the object, if any.\n function getClassName(propValue) {\n if (!propValue.constructor || !propValue.constructor.name) {\n return ANONYMOUS;\n }\n return propValue.constructor.name;\n }\n\n ReactPropTypes.checkPropTypes = checkPropTypes;\n ReactPropTypes.resetWarningCache = checkPropTypes.resetWarningCache;\n ReactPropTypes.PropTypes = ReactPropTypes;\n\n return ReactPropTypes;\n};\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar ReactPropTypesSecret = require('./lib/ReactPropTypesSecret');\n\nfunction emptyFunction() {}\nfunction emptyFunctionWithReset() {}\nemptyFunctionWithReset.resetWarningCache = emptyFunction;\n\nmodule.exports = function() {\n function shim(props, propName, componentName, location, propFullName, secret) {\n if (secret === ReactPropTypesSecret) {\n // It is still safe when called from React.\n return;\n }\n var err = new Error(\n 'Calling PropTypes validators directly is not supported by the `prop-types` package. ' +\n 'Use PropTypes.checkPropTypes() to call them. ' +\n 'Read more at http://fb.me/use-check-prop-types'\n );\n err.name = 'Invariant Violation';\n throw err;\n };\n shim.isRequired = shim;\n function getShim() {\n return shim;\n };\n // Important!\n // Keep this list in sync with production version in `./factoryWithTypeCheckers.js`.\n var ReactPropTypes = {\n array: shim,\n bigint: shim,\n bool: shim,\n func: shim,\n number: shim,\n object: shim,\n string: shim,\n symbol: shim,\n\n any: shim,\n arrayOf: getShim,\n element: shim,\n elementType: shim,\n instanceOf: getShim,\n node: shim,\n objectOf: getShim,\n oneOf: getShim,\n oneOfType: getShim,\n shape: getShim,\n exact: getShim,\n\n checkPropTypes: emptyFunctionWithReset,\n resetWarningCache: emptyFunction\n };\n\n ReactPropTypes.PropTypes = ReactPropTypes;\n\n return ReactPropTypes;\n};\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\nif (process.env.NODE_ENV !== 'production') {\n var ReactIs = require('react-is');\n\n // By explicitly using `prop-types` you are opting into new development behavior.\n // http://fb.me/prop-types-in-prod\n var throwOnDirectAccess = true;\n module.exports = require('./factoryWithTypeCheckers')(ReactIs.isElement, throwOnDirectAccess);\n} else {\n // By explicitly using `prop-types` you are opting into new production behavior.\n // http://fb.me/prop-types-in-prod\n module.exports = require('./factoryWithThrowingShims')();\n}\n","import PropTypes from 'prop-types';\nimport chainPropTypes from '../chainPropTypes';\nfunction isClassComponent(elementType) {\n // elementType.prototype?.isReactComponent\n const {\n prototype = {}\n } = elementType;\n return Boolean(prototype.isReactComponent);\n}\nfunction acceptingRef(props, propName, componentName, location, propFullName) {\n const element = props[propName];\n const safePropName = propFullName || propName;\n if (element == null ||\n // When server-side rendering React doesn't warn either.\n // This is not an accurate check for SSR.\n // This is only in place for Emotion compat.\n // TODO: Revisit once https://github.com/facebook/react/issues/20047 is resolved.\n typeof window === 'undefined') {\n return null;\n }\n let warningHint;\n const elementType = element.type;\n /**\n * Blacklisting instead of whitelisting\n *\n * Blacklisting will miss some components, such as React.Fragment. Those will at least\n * trigger a warning in React.\n * We can't whitelist because there is no safe way to detect React.forwardRef\n * or class components. \"Safe\" means there's no public API.\n *\n */\n if (typeof elementType === 'function' && !isClassComponent(elementType)) {\n warningHint = 'Did you accidentally use a plain function component for an element instead?';\n }\n if (warningHint !== undefined) {\n return new Error(`Invalid ${location} \\`${safePropName}\\` supplied to \\`${componentName}\\`. ` + `Expected an element that can hold a ref. ${warningHint} ` + 'For more information see https://mui.com/r/caveat-with-refs-guide');\n }\n return null;\n}\nconst elementAcceptingRef = chainPropTypes(PropTypes.element, acceptingRef);\nelementAcceptingRef.isRequired = chainPropTypes(PropTypes.element.isRequired, acceptingRef);\nexport default elementAcceptingRef;","import _extends from \"@babel/runtime/helpers/esm/extends\";\n// This module is based on https://github.com/airbnb/prop-types-exact repository.\n// However, in order to reduce the number of dependencies and to remove some extra safe checks\n// the module was forked.\n\nconst specialProperty = 'exact-prop: \\u200b';\nexport default function exactProp(propTypes) {\n if (process.env.NODE_ENV === 'production') {\n return propTypes;\n }\n return _extends({}, propTypes, {\n [specialProperty]: props => {\n const unsupportedProps = Object.keys(props).filter(prop => !propTypes.hasOwnProperty(prop));\n if (unsupportedProps.length > 0) {\n return new Error(`The following props are not supported: ${unsupportedProps.map(prop => `\\`${prop}\\``).join(', ')}. Please remove them.`);\n }\n return null;\n }\n });\n}","/**\n * WARNING: Don't import this directly.\n * Use `MuiError` from `@mui/internal-babel-macros/MuiError.macro` instead.\n * @param {number} code\n */\nexport default function formatMuiErrorMessage(code) {\n // Apply babel-plugin-transform-template-literals in loose mode\n // loose mode is safe if we're concatenating primitives\n // see https://babeljs.io/docs/en/babel-plugin-transform-template-literals#loose\n /* eslint-disable prefer-template */\n let url = 'https://mui.com/production-error/?code=' + code;\n for (let i = 1; i < arguments.length; i += 1) {\n // rest params over-transpile for this case\n // eslint-disable-next-line prefer-rest-params\n url += '&args[]=' + encodeURIComponent(arguments[i]);\n }\n return 'Minified MUI error #' + code + '; visit ' + url + ' for the full message.';\n /* eslint-enable prefer-template */\n}","/**\n * @license React\n * react-is.production.min.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n'use strict';var b=Symbol.for(\"react.element\"),c=Symbol.for(\"react.portal\"),d=Symbol.for(\"react.fragment\"),e=Symbol.for(\"react.strict_mode\"),f=Symbol.for(\"react.profiler\"),g=Symbol.for(\"react.provider\"),h=Symbol.for(\"react.context\"),k=Symbol.for(\"react.server_context\"),l=Symbol.for(\"react.forward_ref\"),m=Symbol.for(\"react.suspense\"),n=Symbol.for(\"react.suspense_list\"),p=Symbol.for(\"react.memo\"),q=Symbol.for(\"react.lazy\"),t=Symbol.for(\"react.offscreen\"),u;u=Symbol.for(\"react.module.reference\");\nfunction v(a){if(\"object\"===typeof a&&null!==a){var r=a.$$typeof;switch(r){case b:switch(a=a.type,a){case d:case f:case e:case m:case n:return a;default:switch(a=a&&a.$$typeof,a){case k:case h:case l:case q:case p:case g:return a;default:return r}}case c:return r}}}exports.ContextConsumer=h;exports.ContextProvider=g;exports.Element=b;exports.ForwardRef=l;exports.Fragment=d;exports.Lazy=q;exports.Memo=p;exports.Portal=c;exports.Profiler=f;exports.StrictMode=e;exports.Suspense=m;\nexports.SuspenseList=n;exports.isAsyncMode=function(){return!1};exports.isConcurrentMode=function(){return!1};exports.isContextConsumer=function(a){return v(a)===h};exports.isContextProvider=function(a){return v(a)===g};exports.isElement=function(a){return\"object\"===typeof a&&null!==a&&a.$$typeof===b};exports.isForwardRef=function(a){return v(a)===l};exports.isFragment=function(a){return v(a)===d};exports.isLazy=function(a){return v(a)===q};exports.isMemo=function(a){return v(a)===p};\nexports.isPortal=function(a){return v(a)===c};exports.isProfiler=function(a){return v(a)===f};exports.isStrictMode=function(a){return v(a)===e};exports.isSuspense=function(a){return v(a)===m};exports.isSuspenseList=function(a){return v(a)===n};\nexports.isValidElementType=function(a){return\"string\"===typeof a||\"function\"===typeof a||a===d||a===f||a===e||a===m||a===n||a===t||\"object\"===typeof a&&null!==a&&(a.$$typeof===q||a.$$typeof===p||a.$$typeof===g||a.$$typeof===h||a.$$typeof===l||a.$$typeof===u||void 0!==a.getModuleId)?!0:!1};exports.typeOf=v;\n","/**\n * @license React\n * react-is.development.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nif (process.env.NODE_ENV !== \"production\") {\n (function() {\n'use strict';\n\n// ATTENTION\n// When adding new symbols to this file,\n// Please consider also adding to 'react-devtools-shared/src/backend/ReactSymbols'\n// The Symbol used to tag the ReactElement-like types.\nvar REACT_ELEMENT_TYPE = Symbol.for('react.element');\nvar REACT_PORTAL_TYPE = Symbol.for('react.portal');\nvar REACT_FRAGMENT_TYPE = Symbol.for('react.fragment');\nvar REACT_STRICT_MODE_TYPE = Symbol.for('react.strict_mode');\nvar REACT_PROFILER_TYPE = Symbol.for('react.profiler');\nvar REACT_PROVIDER_TYPE = Symbol.for('react.provider');\nvar REACT_CONTEXT_TYPE = Symbol.for('react.context');\nvar REACT_SERVER_CONTEXT_TYPE = Symbol.for('react.server_context');\nvar REACT_FORWARD_REF_TYPE = Symbol.for('react.forward_ref');\nvar REACT_SUSPENSE_TYPE = Symbol.for('react.suspense');\nvar REACT_SUSPENSE_LIST_TYPE = Symbol.for('react.suspense_list');\nvar REACT_MEMO_TYPE = Symbol.for('react.memo');\nvar REACT_LAZY_TYPE = Symbol.for('react.lazy');\nvar REACT_OFFSCREEN_TYPE = Symbol.for('react.offscreen');\n\n// -----------------------------------------------------------------------------\n\nvar enableScopeAPI = false; // Experimental Create Event Handle API.\nvar enableCacheElement = false;\nvar enableTransitionTracing = false; // No known bugs, but needs performance testing\n\nvar enableLegacyHidden = false; // Enables unstable_avoidThisFallback feature in Fiber\n// stuff. Intended to enable React core members to more easily debug scheduling\n// issues in DEV builds.\n\nvar enableDebugTracing = false; // Track which Fiber(s) schedule render work.\n\nvar REACT_MODULE_REFERENCE;\n\n{\n REACT_MODULE_REFERENCE = Symbol.for('react.module.reference');\n}\n\nfunction isValidElementType(type) {\n if (typeof type === 'string' || typeof type === 'function') {\n return true;\n } // Note: typeof might be other than 'symbol' or 'number' (e.g. if it's a polyfill).\n\n\n if (type === REACT_FRAGMENT_TYPE || type === REACT_PROFILER_TYPE || enableDebugTracing || type === REACT_STRICT_MODE_TYPE || type === REACT_SUSPENSE_TYPE || type === REACT_SUSPENSE_LIST_TYPE || enableLegacyHidden || type === REACT_OFFSCREEN_TYPE || enableScopeAPI || enableCacheElement || enableTransitionTracing ) {\n return true;\n }\n\n if (typeof type === 'object' && type !== null) {\n if (type.$$typeof === REACT_LAZY_TYPE || type.$$typeof === REACT_MEMO_TYPE || type.$$typeof === REACT_PROVIDER_TYPE || type.$$typeof === REACT_CONTEXT_TYPE || type.$$typeof === REACT_FORWARD_REF_TYPE || // This needs to include all possible module reference object\n // types supported by any Flight configuration anywhere since\n // we don't know which Flight build this will end up being used\n // with.\n type.$$typeof === REACT_MODULE_REFERENCE || type.getModuleId !== undefined) {\n return true;\n }\n }\n\n return false;\n}\n\nfunction typeOf(object) {\n if (typeof object === 'object' && object !== null) {\n var $$typeof = object.$$typeof;\n\n switch ($$typeof) {\n case REACT_ELEMENT_TYPE:\n var type = object.type;\n\n switch (type) {\n case REACT_FRAGMENT_TYPE:\n case REACT_PROFILER_TYPE:\n case REACT_STRICT_MODE_TYPE:\n case REACT_SUSPENSE_TYPE:\n case REACT_SUSPENSE_LIST_TYPE:\n return type;\n\n default:\n var $$typeofType = type && type.$$typeof;\n\n switch ($$typeofType) {\n case REACT_SERVER_CONTEXT_TYPE:\n case REACT_CONTEXT_TYPE:\n case REACT_FORWARD_REF_TYPE:\n case REACT_LAZY_TYPE:\n case REACT_MEMO_TYPE:\n case REACT_PROVIDER_TYPE:\n return $$typeofType;\n\n default:\n return $$typeof;\n }\n\n }\n\n case REACT_PORTAL_TYPE:\n return $$typeof;\n }\n }\n\n return undefined;\n}\nvar ContextConsumer = REACT_CONTEXT_TYPE;\nvar ContextProvider = REACT_PROVIDER_TYPE;\nvar Element = REACT_ELEMENT_TYPE;\nvar ForwardRef = REACT_FORWARD_REF_TYPE;\nvar Fragment = REACT_FRAGMENT_TYPE;\nvar Lazy = REACT_LAZY_TYPE;\nvar Memo = REACT_MEMO_TYPE;\nvar Portal = REACT_PORTAL_TYPE;\nvar Profiler = REACT_PROFILER_TYPE;\nvar StrictMode = REACT_STRICT_MODE_TYPE;\nvar Suspense = REACT_SUSPENSE_TYPE;\nvar SuspenseList = REACT_SUSPENSE_LIST_TYPE;\nvar hasWarnedAboutDeprecatedIsAsyncMode = false;\nvar hasWarnedAboutDeprecatedIsConcurrentMode = false; // AsyncMode should be deprecated\n\nfunction isAsyncMode(object) {\n {\n if (!hasWarnedAboutDeprecatedIsAsyncMode) {\n hasWarnedAboutDeprecatedIsAsyncMode = true; // Using console['warn'] to evade Babel and ESLint\n\n console['warn']('The ReactIs.isAsyncMode() alias has been deprecated, ' + 'and will be removed in React 18+.');\n }\n }\n\n return false;\n}\nfunction isConcurrentMode(object) {\n {\n if (!hasWarnedAboutDeprecatedIsConcurrentMode) {\n hasWarnedAboutDeprecatedIsConcurrentMode = true; // Using console['warn'] to evade Babel and ESLint\n\n console['warn']('The ReactIs.isConcurrentMode() alias has been deprecated, ' + 'and will be removed in React 18+.');\n }\n }\n\n return false;\n}\nfunction isContextConsumer(object) {\n return typeOf(object) === REACT_CONTEXT_TYPE;\n}\nfunction isContextProvider(object) {\n return typeOf(object) === REACT_PROVIDER_TYPE;\n}\nfunction isElement(object) {\n return typeof object === 'object' && object !== null && object.$$typeof === REACT_ELEMENT_TYPE;\n}\nfunction isForwardRef(object) {\n return typeOf(object) === REACT_FORWARD_REF_TYPE;\n}\nfunction isFragment(object) {\n return typeOf(object) === REACT_FRAGMENT_TYPE;\n}\nfunction isLazy(object) {\n return typeOf(object) === REACT_LAZY_TYPE;\n}\nfunction isMemo(object) {\n return typeOf(object) === REACT_MEMO_TYPE;\n}\nfunction isPortal(object) {\n return typeOf(object) === REACT_PORTAL_TYPE;\n}\nfunction isProfiler(object) {\n return typeOf(object) === REACT_PROFILER_TYPE;\n}\nfunction isStrictMode(object) {\n return typeOf(object) === REACT_STRICT_MODE_TYPE;\n}\nfunction isSuspense(object) {\n return typeOf(object) === REACT_SUSPENSE_TYPE;\n}\nfunction isSuspenseList(object) {\n return typeOf(object) === REACT_SUSPENSE_LIST_TYPE;\n}\n\nexports.ContextConsumer = ContextConsumer;\nexports.ContextProvider = ContextProvider;\nexports.Element = Element;\nexports.ForwardRef = ForwardRef;\nexports.Fragment = Fragment;\nexports.Lazy = Lazy;\nexports.Memo = Memo;\nexports.Portal = Portal;\nexports.Profiler = Profiler;\nexports.StrictMode = StrictMode;\nexports.Suspense = Suspense;\nexports.SuspenseList = SuspenseList;\nexports.isAsyncMode = isAsyncMode;\nexports.isConcurrentMode = isConcurrentMode;\nexports.isContextConsumer = isContextConsumer;\nexports.isContextProvider = isContextProvider;\nexports.isElement = isElement;\nexports.isForwardRef = isForwardRef;\nexports.isFragment = isFragment;\nexports.isLazy = isLazy;\nexports.isMemo = isMemo;\nexports.isPortal = isPortal;\nexports.isProfiler = isProfiler;\nexports.isStrictMode = isStrictMode;\nexports.isSuspense = isSuspense;\nexports.isSuspenseList = isSuspenseList;\nexports.isValidElementType = isValidElementType;\nexports.typeOf = typeOf;\n })();\n}\n","'use strict';\n\nif (process.env.NODE_ENV === 'production') {\n module.exports = require('./cjs/react-is.production.min.js');\n} else {\n module.exports = require('./cjs/react-is.development.js');\n}\n","import { ForwardRef, Memo } from 'react-is';\n\n// Simplified polyfill for IE11 support\n// https://github.com/JamesMGreene/Function.name/blob/58b314d4a983110c3682f1228f845d39ccca1817/Function.name.js#L3\nconst fnNameMatchRegex = /^\\s*function(?:\\s|\\s*\\/\\*.*\\*\\/\\s*)+([^(\\s/]*)\\s*/;\nexport function getFunctionName(fn) {\n const match = `${fn}`.match(fnNameMatchRegex);\n const name = match && match[1];\n return name || '';\n}\nfunction getFunctionComponentName(Component, fallback = '') {\n return Component.displayName || Component.name || getFunctionName(Component) || fallback;\n}\nfunction getWrappedName(outerType, innerType, wrapperName) {\n const functionName = getFunctionComponentName(innerType);\n return outerType.displayName || (functionName !== '' ? `${wrapperName}(${functionName})` : wrapperName);\n}\n\n/**\n * cherry-pick from\n * https://github.com/facebook/react/blob/769b1f270e1251d9dbdce0fcbd9e92e502d059b8/packages/shared/getComponentName.js\n * originally forked from recompose/getDisplayName with added IE11 support\n */\nexport default function getDisplayName(Component) {\n if (Component == null) {\n return undefined;\n }\n if (typeof Component === 'string') {\n return Component;\n }\n if (typeof Component === 'function') {\n return getFunctionComponentName(Component, 'Component');\n }\n\n // TypeScript can't have components as objects but they exist in the form of `memo` or `Suspense`\n if (typeof Component === 'object') {\n switch (Component.$$typeof) {\n case ForwardRef:\n return getWrappedName(Component, Component.render, 'ForwardRef');\n case Memo:\n return getWrappedName(Component, Component.type, 'memo');\n default:\n return undefined;\n }\n }\n return undefined;\n}","export default function HTMLElementType(props, propName, componentName, location, propFullName) {\n if (process.env.NODE_ENV === 'production') {\n return null;\n }\n const propValue = props[propName];\n const safePropName = propFullName || propName;\n if (propValue == null) {\n return null;\n }\n if (propValue && propValue.nodeType !== 1) {\n return new Error(`Invalid ${location} \\`${safePropName}\\` supplied to \\`${componentName}\\`. ` + `Expected an HTMLElement.`);\n }\n return null;\n}","import PropTypes from 'prop-types';\nconst refType = PropTypes.oneOfType([PropTypes.func, PropTypes.object]);\nexport default refType;","import _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\n// It should to be noted that this function isn't equivalent to `text-transform: capitalize`.\n//\n// A strict capitalization should uppercase the first letter of each word in the sentence.\n// We only handle the first word.\nexport default function capitalize(string) {\n if (typeof string !== 'string') {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: \\`capitalize(string)\\` expects a string argument.` : _formatMuiErrorMessage(7));\n }\n return string.charAt(0).toUpperCase() + string.slice(1);\n}","/**\n * Safe chained function.\n *\n * Will only create a new function if needed,\n * otherwise will pass back existing functions or null.\n */\nexport default function createChainedFunction(...funcs) {\n return funcs.reduce((acc, func) => {\n if (func == null) {\n return acc;\n }\n return function chainedFunction(...args) {\n acc.apply(this, args);\n func.apply(this, args);\n };\n }, () => {});\n}","// Corresponds to 10 frames at 60 Hz.\n// A few bytes payload overhead when lodash/debounce is ~3 kB and debounce ~300 B.\nexport default function debounce(func, wait = 166) {\n let timeout;\n function debounced(...args) {\n const later = () => {\n // @ts-ignore\n func.apply(this, args);\n };\n clearTimeout(timeout);\n timeout = setTimeout(later, wait);\n }\n debounced.clear = () => {\n clearTimeout(timeout);\n };\n return debounced;\n}","export default function deprecatedPropType(validator, reason) {\n if (process.env.NODE_ENV === 'production') {\n return () => null;\n }\n return (props, propName, componentName, location, propFullName) => {\n const componentNameSafe = componentName || '<>';\n const propFullNameSafe = propFullName || propName;\n if (typeof props[propName] !== 'undefined') {\n return new Error(`The ${location} \\`${propFullNameSafe}\\` of ` + `\\`${componentNameSafe}\\` is deprecated. ${reason}`);\n }\n return null;\n };\n}","import * as React from 'react';\nexport default function isMuiElement(element, muiNames) {\n var _muiName, _element$type;\n return /*#__PURE__*/React.isValidElement(element) && muiNames.indexOf( // For server components `muiName` is avaialble in element.type._payload.value.muiName\n // relevant info - https://github.com/facebook/react/blob/2807d781a08db8e9873687fccc25c0f12b4fb3d4/packages/react/src/ReactLazy.js#L45\n // eslint-disable-next-line no-underscore-dangle\n (_muiName = element.type.muiName) != null ? _muiName : (_element$type = element.type) == null || (_element$type = _element$type._payload) == null || (_element$type = _element$type.value) == null ? void 0 : _element$type.muiName) !== -1;\n}","export default function ownerDocument(node) {\n return node && node.ownerDocument || document;\n}","import ownerDocument from '../ownerDocument';\nexport default function ownerWindow(node) {\n const doc = ownerDocument(node);\n return doc.defaultView || window;\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nexport default function requirePropFactory(componentNameInError, Component) {\n if (process.env.NODE_ENV === 'production') {\n return () => null;\n }\n\n // eslint-disable-next-line react/forbid-foreign-prop-types\n const prevPropTypes = Component ? _extends({}, Component.propTypes) : null;\n const requireProp = requiredProp => (props, propName, componentName, location, propFullName, ...args) => {\n const propFullNameSafe = propFullName || propName;\n const defaultTypeChecker = prevPropTypes == null ? void 0 : prevPropTypes[propFullNameSafe];\n if (defaultTypeChecker) {\n const typeCheckerResult = defaultTypeChecker(props, propName, componentName, location, propFullName, ...args);\n if (typeCheckerResult) {\n return typeCheckerResult;\n }\n }\n if (typeof props[propName] !== 'undefined' && !props[requiredProp]) {\n return new Error(`The prop \\`${propFullNameSafe}\\` of ` + `\\`${componentNameInError}\\` can only be used together with the \\`${requiredProp}\\` prop.`);\n }\n return null;\n };\n return requireProp;\n}","/**\n * TODO v5: consider making it private\n *\n * passes {value} to {ref}\n *\n * WARNING: Be sure to only call this inside a callback that is passed as a ref.\n * Otherwise, make sure to cleanup the previous {ref} if it changes. See\n * https://github.com/mui/material-ui/issues/13539\n *\n * Useful if you want to expose the ref of an inner component to the public API\n * while still using it inside the component.\n * @param ref A ref callback or ref object. If anything falsy, this is a no-op.\n */\nexport default function setRef(ref, value) {\n if (typeof ref === 'function') {\n ref(value);\n } else if (ref) {\n ref.current = value;\n }\n}","'use client';\n\nimport * as React from 'react';\n\n/**\n * A version of `React.useLayoutEffect` that does not show a warning when server-side rendering.\n * This is useful for effects that are only needed for client-side rendering but not for SSR.\n *\n * Before you use this hook, make sure to read https://gist.github.com/gaearon/e7d97cdf38a2907924ea12e4ebdf3c85\n * and confirm it doesn't apply to your use-case.\n */\nconst useEnhancedEffect = typeof window !== 'undefined' ? React.useLayoutEffect : React.useEffect;\nexport default useEnhancedEffect;","'use client';\n\nimport * as React from 'react';\nlet globalId = 0;\nfunction useGlobalId(idOverride) {\n const [defaultId, setDefaultId] = React.useState(idOverride);\n const id = idOverride || defaultId;\n React.useEffect(() => {\n if (defaultId == null) {\n // Fallback to this default id when possible.\n // Use the incrementing value for client-side rendering only.\n // We can't use it server-side.\n // If you want to use random values please consider the Birthday Problem: https://en.wikipedia.org/wiki/Birthday_problem\n globalId += 1;\n setDefaultId(`mui-${globalId}`);\n }\n }, [defaultId]);\n return id;\n}\n\n// downstream bundlers may remove unnecessary concatenation, but won't remove toString call -- Workaround for https://github.com/webpack/webpack/issues/14814\nconst maybeReactUseId = React['useId'.toString()];\n/**\n *\n * @example
    \n * @param idOverride\n * @returns {string}\n */\nexport default function useId(idOverride) {\n if (maybeReactUseId !== undefined) {\n const reactId = maybeReactUseId();\n return idOverride != null ? idOverride : reactId;\n }\n // eslint-disable-next-line react-hooks/rules-of-hooks -- `React.useId` is invariant at runtime.\n return useGlobalId(idOverride);\n}","export default function unsupportedProp(props, propName, componentName, location, propFullName) {\n if (process.env.NODE_ENV === 'production') {\n return null;\n }\n const propFullNameSafe = propFullName || propName;\n if (typeof props[propName] !== 'undefined') {\n return new Error(`The prop \\`${propFullNameSafe}\\` is not supported. Please remove it.`);\n }\n return null;\n}","'use client';\n\n/* eslint-disable react-hooks/rules-of-hooks, react-hooks/exhaustive-deps */\nimport * as React from 'react';\nexport default function useControlled({\n controlled,\n default: defaultProp,\n name,\n state = 'value'\n}) {\n // isControlled is ignored in the hook dependency lists as it should never change.\n const {\n current: isControlled\n } = React.useRef(controlled !== undefined);\n const [valueState, setValue] = React.useState(defaultProp);\n const value = isControlled ? controlled : valueState;\n if (process.env.NODE_ENV !== 'production') {\n React.useEffect(() => {\n if (isControlled !== (controlled !== undefined)) {\n console.error([`MUI: A component is changing the ${isControlled ? '' : 'un'}controlled ${state} state of ${name} to be ${isControlled ? 'un' : ''}controlled.`, 'Elements should not switch from uncontrolled to controlled (or vice versa).', `Decide between using a controlled or uncontrolled ${name} ` + 'element for the lifetime of the component.', \"The nature of the state is determined during the first render. It's considered controlled if the value is not `undefined`.\", 'More info: https://fb.me/react-controlled-components'].join('\\n'));\n }\n }, [state, name, controlled]);\n const {\n current: defaultValue\n } = React.useRef(defaultProp);\n React.useEffect(() => {\n if (!isControlled && defaultValue !== defaultProp) {\n console.error([`MUI: A component is changing the default ${state} state of an uncontrolled ${name} after being initialized. ` + `To suppress this warning opt to use a controlled ${name}.`].join('\\n'));\n }\n }, [JSON.stringify(defaultProp)]);\n }\n const setValueIfUncontrolled = React.useCallback(newValue => {\n if (!isControlled) {\n setValue(newValue);\n }\n }, []);\n return [value, setValueIfUncontrolled];\n}","'use client';\n\nimport * as React from 'react';\nimport useEnhancedEffect from '../useEnhancedEffect';\n\n/**\n * Inspired by https://github.com/facebook/react/issues/14099#issuecomment-440013892\n * See RFC in https://github.com/reactjs/rfcs/pull/220\n */\n\nfunction useEventCallback(fn) {\n const ref = React.useRef(fn);\n useEnhancedEffect(() => {\n ref.current = fn;\n });\n return React.useRef((...args) =>\n // @ts-expect-error hide `this`\n (0, ref.current)(...args)).current;\n}\nexport default useEventCallback;","'use client';\n\nimport * as React from 'react';\nimport setRef from '../setRef';\nexport default function useForkRef(...refs) {\n /**\n * This will create a new function if the refs passed to this hook change and are all defined.\n * This means react will call the old forkRef with `null` and the new forkRef\n * with the ref. Cleanup naturally emerges from this behavior.\n */\n return React.useMemo(() => {\n if (refs.every(ref => ref == null)) {\n return null;\n }\n return instance => {\n refs.forEach(ref => {\n setRef(ref, instance);\n });\n };\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, refs);\n}","'use client';\n\nimport * as React from 'react';\nconst UNINITIALIZED = {};\n\n/**\n * A React.useRef() that is initialized lazily with a function. Note that it accepts an optional\n * initialization argument, so the initialization function doesn't need to be an inline closure.\n *\n * @usage\n * const ref = useLazyRef(sortColumns, columns)\n */\nexport default function useLazyRef(init, initArg) {\n const ref = React.useRef(UNINITIALIZED);\n if (ref.current === UNINITIALIZED) {\n ref.current = init(initArg);\n }\n return ref;\n}","'use client';\n\nimport * as React from 'react';\nconst EMPTY = [];\n\n/**\n * A React.useEffect equivalent that runs once, when the component is mounted.\n */\nexport default function useOnMount(fn) {\n /* eslint-disable react-hooks/exhaustive-deps */\n React.useEffect(fn, EMPTY);\n /* eslint-enable react-hooks/exhaustive-deps */\n}","'use client';\n\nimport useLazyRef from '../useLazyRef/useLazyRef';\nimport useOnMount from '../useOnMount/useOnMount';\nexport class Timeout {\n constructor() {\n this.currentId = null;\n this.clear = () => {\n if (this.currentId !== null) {\n clearTimeout(this.currentId);\n this.currentId = null;\n }\n };\n this.disposeEffect = () => {\n return this.clear;\n };\n }\n static create() {\n return new Timeout();\n }\n /**\n * Executes `fn` after `delay`, clearing any previously scheduled call.\n */\n start(delay, fn) {\n this.clear();\n this.currentId = setTimeout(() => {\n this.currentId = null;\n fn();\n }, delay);\n }\n}\nexport default function useTimeout() {\n const timeout = useLazyRef(Timeout.create).current;\n useOnMount(timeout.disposeEffect);\n return timeout;\n}","'use client';\n\n// based on https://github.com/WICG/focus-visible/blob/v4.1.5/src/focus-visible.js\nimport * as React from 'react';\nimport { Timeout } from '../useTimeout/useTimeout';\nlet hadKeyboardEvent = true;\nlet hadFocusVisibleRecently = false;\nconst hadFocusVisibleRecentlyTimeout = new Timeout();\nconst inputTypesWhitelist = {\n text: true,\n search: true,\n url: true,\n tel: true,\n email: true,\n password: true,\n number: true,\n date: true,\n month: true,\n week: true,\n time: true,\n datetime: true,\n 'datetime-local': true\n};\n\n/**\n * Computes whether the given element should automatically trigger the\n * `focus-visible` class being added, i.e. whether it should always match\n * `:focus-visible` when focused.\n * @param {Element} node\n * @returns {boolean}\n */\nfunction focusTriggersKeyboardModality(node) {\n const {\n type,\n tagName\n } = node;\n if (tagName === 'INPUT' && inputTypesWhitelist[type] && !node.readOnly) {\n return true;\n }\n if (tagName === 'TEXTAREA' && !node.readOnly) {\n return true;\n }\n if (node.isContentEditable) {\n return true;\n }\n return false;\n}\n\n/**\n * Keep track of our keyboard modality state with `hadKeyboardEvent`.\n * If the most recent user interaction was via the keyboard;\n * and the key press did not include a meta, alt/option, or control key;\n * then the modality is keyboard. Otherwise, the modality is not keyboard.\n * @param {KeyboardEvent} event\n */\nfunction handleKeyDown(event) {\n if (event.metaKey || event.altKey || event.ctrlKey) {\n return;\n }\n hadKeyboardEvent = true;\n}\n\n/**\n * If at any point a user clicks with a pointing device, ensure that we change\n * the modality away from keyboard.\n * This avoids the situation where a user presses a key on an already focused\n * element, and then clicks on a different element, focusing it with a\n * pointing device, while we still think we're in keyboard modality.\n */\nfunction handlePointerDown() {\n hadKeyboardEvent = false;\n}\nfunction handleVisibilityChange() {\n if (this.visibilityState === 'hidden') {\n // If the tab becomes active again, the browser will handle calling focus\n // on the element (Safari actually calls it twice).\n // If this tab change caused a blur on an element with focus-visible,\n // re-apply the class when the user switches back to the tab.\n if (hadFocusVisibleRecently) {\n hadKeyboardEvent = true;\n }\n }\n}\nfunction prepare(doc) {\n doc.addEventListener('keydown', handleKeyDown, true);\n doc.addEventListener('mousedown', handlePointerDown, true);\n doc.addEventListener('pointerdown', handlePointerDown, true);\n doc.addEventListener('touchstart', handlePointerDown, true);\n doc.addEventListener('visibilitychange', handleVisibilityChange, true);\n}\nexport function teardown(doc) {\n doc.removeEventListener('keydown', handleKeyDown, true);\n doc.removeEventListener('mousedown', handlePointerDown, true);\n doc.removeEventListener('pointerdown', handlePointerDown, true);\n doc.removeEventListener('touchstart', handlePointerDown, true);\n doc.removeEventListener('visibilitychange', handleVisibilityChange, true);\n}\nfunction isFocusVisible(event) {\n const {\n target\n } = event;\n try {\n return target.matches(':focus-visible');\n } catch (error) {\n // Browsers not implementing :focus-visible will throw a SyntaxError.\n // We use our own heuristic for those browsers.\n // Rethrow might be better if it's not the expected error but do we really\n // want to crash if focus-visible malfunctioned?\n }\n\n // No need for validFocusTarget check. The user does that by attaching it to\n // focusable events only.\n return hadKeyboardEvent || focusTriggersKeyboardModality(target);\n}\nexport default function useIsFocusVisible() {\n const ref = React.useCallback(node => {\n if (node != null) {\n prepare(node.ownerDocument);\n }\n }, []);\n const isFocusVisibleRef = React.useRef(false);\n\n /**\n * Should be called if a blur event is fired\n */\n function handleBlurVisible() {\n // checking against potential state variable does not suffice if we focus and blur synchronously.\n // React wouldn't have time to trigger a re-render so `focusVisible` would be stale.\n // Ideally we would adjust `isFocusVisible(event)` to look at `relatedTarget` for blur events.\n // This doesn't work in IE11 due to https://github.com/facebook/react/issues/3751\n // TODO: check again if React releases their internal changes to focus event handling (https://github.com/facebook/react/pull/19186).\n if (isFocusVisibleRef.current) {\n // To detect a tab/window switch, we look for a blur event followed\n // rapidly by a visibility change.\n // If we don't see a visibility change within 100ms, it's probably a\n // regular focus change.\n hadFocusVisibleRecently = true;\n hadFocusVisibleRecentlyTimeout.start(100, () => {\n hadFocusVisibleRecently = false;\n });\n isFocusVisibleRef.current = false;\n return true;\n }\n return false;\n }\n\n /**\n * Should be called if a blur event is fired\n */\n function handleFocusVisible(event) {\n if (isFocusVisible(event)) {\n isFocusVisibleRef.current = true;\n return true;\n }\n return false;\n }\n return {\n isFocusVisibleRef,\n onFocus: handleFocusVisible,\n onBlur: handleBlurVisible,\n ref\n };\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\n/**\n * Add keys, values of `defaultProps` that does not exist in `props`\n * @param {object} defaultProps\n * @param {object} props\n * @returns {object} resolved props\n */\nexport default function resolveProps(defaultProps, props) {\n const output = _extends({}, props);\n Object.keys(defaultProps).forEach(propName => {\n if (propName.toString().match(/^(components|slots)$/)) {\n output[propName] = _extends({}, defaultProps[propName], output[propName]);\n } else if (propName.toString().match(/^(componentsProps|slotProps)$/)) {\n const defaultSlotProps = defaultProps[propName] || {};\n const slotProps = props[propName];\n output[propName] = {};\n if (!slotProps || !Object.keys(slotProps)) {\n // Reduce the iteration if the slot props is empty\n output[propName] = defaultSlotProps;\n } else if (!defaultSlotProps || !Object.keys(defaultSlotProps)) {\n // Reduce the iteration if the default slot props is empty\n output[propName] = slotProps;\n } else {\n output[propName] = _extends({}, slotProps);\n Object.keys(defaultSlotProps).forEach(slotPropName => {\n output[propName][slotPropName] = resolveProps(defaultSlotProps[slotPropName], slotProps[slotPropName]);\n });\n }\n } else if (output[propName] === undefined) {\n output[propName] = defaultProps[propName];\n }\n });\n return output;\n}","export default function composeClasses(slots, getUtilityClass, classes = undefined) {\n const output = {};\n Object.keys(slots).forEach(\n // `Object.keys(slots)` can't be wider than `T` because we infer `T` from `slots`.\n // @ts-expect-error https://github.com/microsoft/TypeScript/pull/12253#issuecomment-263132208\n slot => {\n output[slot] = slots[slot].reduce((acc, key) => {\n if (key) {\n const utilityClass = getUtilityClass(key);\n if (utilityClass !== '') {\n acc.push(utilityClass);\n }\n if (classes && classes[key]) {\n acc.push(classes[key]);\n }\n }\n return acc;\n }, []).join(' ');\n });\n return output;\n}","const defaultGenerator = componentName => componentName;\nconst createClassNameGenerator = () => {\n let generate = defaultGenerator;\n return {\n configure(generator) {\n generate = generator;\n },\n generate(componentName) {\n return generate(componentName);\n },\n reset() {\n generate = defaultGenerator;\n }\n };\n};\nconst ClassNameGenerator = createClassNameGenerator();\nexport default ClassNameGenerator;","import ClassNameGenerator from '../ClassNameGenerator';\nexport const globalStateClasses = {\n active: 'active',\n checked: 'checked',\n completed: 'completed',\n disabled: 'disabled',\n error: 'error',\n expanded: 'expanded',\n focused: 'focused',\n focusVisible: 'focusVisible',\n open: 'open',\n readOnly: 'readOnly',\n required: 'required',\n selected: 'selected'\n};\nexport default function generateUtilityClass(componentName, slot, globalStatePrefix = 'Mui') {\n const globalStateClass = globalStateClasses[slot];\n return globalStateClass ? `${globalStatePrefix}-${globalStateClass}` : `${ClassNameGenerator.generate(componentName)}-${slot}`;\n}\nexport function isGlobalState(slot) {\n return globalStateClasses[slot] !== undefined;\n}","import generateUtilityClass from '../generateUtilityClass';\nexport default function generateUtilityClasses(componentName, slots, globalStatePrefix = 'Mui') {\n const result = {};\n slots.forEach(slot => {\n result[slot] = generateUtilityClass(componentName, slot, globalStatePrefix);\n });\n return result;\n}","function clamp(val, min = Number.MIN_SAFE_INTEGER, max = Number.MAX_SAFE_INTEGER) {\n return Math.max(min, Math.min(val, max));\n}\nexport default clamp;","export default function _objectWithoutPropertiesLoose(source, excluded) {\n if (source == null) return {};\n var target = {};\n var sourceKeys = Object.keys(source);\n var key, i;\n for (i = 0; i < sourceKeys.length; i++) {\n key = sourceKeys[i];\n if (excluded.indexOf(key) >= 0) continue;\n target[key] = source[key];\n }\n return target;\n}","import _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nconst _excluded = [\"values\", \"unit\", \"step\"];\n// Sorted ASC by size. That's important.\n// It can't be configured as it's used statically for propTypes.\nexport const breakpointKeys = ['xs', 'sm', 'md', 'lg', 'xl'];\nconst sortBreakpointsValues = values => {\n const breakpointsAsArray = Object.keys(values).map(key => ({\n key,\n val: values[key]\n })) || [];\n // Sort in ascending order\n breakpointsAsArray.sort((breakpoint1, breakpoint2) => breakpoint1.val - breakpoint2.val);\n return breakpointsAsArray.reduce((acc, obj) => {\n return _extends({}, acc, {\n [obj.key]: obj.val\n });\n }, {});\n};\n\n// Keep in mind that @media is inclusive by the CSS specification.\nexport default function createBreakpoints(breakpoints) {\n const {\n // The breakpoint **start** at this value.\n // For instance with the first breakpoint xs: [xs, sm).\n values = {\n xs: 0,\n // phone\n sm: 600,\n // tablet\n md: 900,\n // small laptop\n lg: 1200,\n // desktop\n xl: 1536 // large screen\n },\n unit = 'px',\n step = 5\n } = breakpoints,\n other = _objectWithoutPropertiesLoose(breakpoints, _excluded);\n const sortedValues = sortBreakpointsValues(values);\n const keys = Object.keys(sortedValues);\n function up(key) {\n const value = typeof values[key] === 'number' ? values[key] : key;\n return `@media (min-width:${value}${unit})`;\n }\n function down(key) {\n const value = typeof values[key] === 'number' ? values[key] : key;\n return `@media (max-width:${value - step / 100}${unit})`;\n }\n function between(start, end) {\n const endIndex = keys.indexOf(end);\n return `@media (min-width:${typeof values[start] === 'number' ? values[start] : start}${unit}) and ` + `(max-width:${(endIndex !== -1 && typeof values[keys[endIndex]] === 'number' ? values[keys[endIndex]] : end) - step / 100}${unit})`;\n }\n function only(key) {\n if (keys.indexOf(key) + 1 < keys.length) {\n return between(key, keys[keys.indexOf(key) + 1]);\n }\n return up(key);\n }\n function not(key) {\n // handle first and last key separately, for better readability\n const keyIndex = keys.indexOf(key);\n if (keyIndex === 0) {\n return up(keys[1]);\n }\n if (keyIndex === keys.length - 1) {\n return down(keys[keyIndex]);\n }\n return between(key, keys[keys.indexOf(key) + 1]).replace('@media', '@media not all and');\n }\n return _extends({\n keys,\n values: sortedValues,\n up,\n down,\n between,\n only,\n not,\n unit\n }, other);\n}","const shape = {\n borderRadius: 4\n};\nexport default shape;","import PropTypes from 'prop-types';\nconst responsivePropType = process.env.NODE_ENV !== 'production' ? PropTypes.oneOfType([PropTypes.number, PropTypes.string, PropTypes.object, PropTypes.array]) : {};\nexport default responsivePropType;","import deepmerge from '@mui/utils/deepmerge';\nfunction merge(acc, item) {\n if (!item) {\n return acc;\n }\n return deepmerge(acc, item, {\n clone: false // No need to clone deep, it's way faster.\n });\n}\nexport default merge;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport PropTypes from 'prop-types';\nimport deepmerge from '@mui/utils/deepmerge';\nimport merge from './merge';\n\n// The breakpoint **start** at this value.\n// For instance with the first breakpoint xs: [xs, sm[.\nexport const values = {\n xs: 0,\n // phone\n sm: 600,\n // tablet\n md: 900,\n // small laptop\n lg: 1200,\n // desktop\n xl: 1536 // large screen\n};\nconst defaultBreakpoints = {\n // Sorted ASC by size. That's important.\n // It can't be configured as it's used statically for propTypes.\n keys: ['xs', 'sm', 'md', 'lg', 'xl'],\n up: key => `@media (min-width:${values[key]}px)`\n};\nexport function handleBreakpoints(props, propValue, styleFromPropValue) {\n const theme = props.theme || {};\n if (Array.isArray(propValue)) {\n const themeBreakpoints = theme.breakpoints || defaultBreakpoints;\n return propValue.reduce((acc, item, index) => {\n acc[themeBreakpoints.up(themeBreakpoints.keys[index])] = styleFromPropValue(propValue[index]);\n return acc;\n }, {});\n }\n if (typeof propValue === 'object') {\n const themeBreakpoints = theme.breakpoints || defaultBreakpoints;\n return Object.keys(propValue).reduce((acc, breakpoint) => {\n // key is breakpoint\n if (Object.keys(themeBreakpoints.values || values).indexOf(breakpoint) !== -1) {\n const mediaKey = themeBreakpoints.up(breakpoint);\n acc[mediaKey] = styleFromPropValue(propValue[breakpoint], breakpoint);\n } else {\n const cssKey = breakpoint;\n acc[cssKey] = propValue[cssKey];\n }\n return acc;\n }, {});\n }\n const output = styleFromPropValue(propValue);\n return output;\n}\nfunction breakpoints(styleFunction) {\n // false positive\n // eslint-disable-next-line react/function-component-definition\n const newStyleFunction = props => {\n const theme = props.theme || {};\n const base = styleFunction(props);\n const themeBreakpoints = theme.breakpoints || defaultBreakpoints;\n const extended = themeBreakpoints.keys.reduce((acc, key) => {\n if (props[key]) {\n acc = acc || {};\n acc[themeBreakpoints.up(key)] = styleFunction(_extends({\n theme\n }, props[key]));\n }\n return acc;\n }, null);\n return merge(base, extended);\n };\n newStyleFunction.propTypes = process.env.NODE_ENV !== 'production' ? _extends({}, styleFunction.propTypes, {\n xs: PropTypes.object,\n sm: PropTypes.object,\n md: PropTypes.object,\n lg: PropTypes.object,\n xl: PropTypes.object\n }) : {};\n newStyleFunction.filterProps = ['xs', 'sm', 'md', 'lg', 'xl', ...styleFunction.filterProps];\n return newStyleFunction;\n}\nexport function createEmptyBreakpointObject(breakpointsInput = {}) {\n var _breakpointsInput$key;\n const breakpointsInOrder = (_breakpointsInput$key = breakpointsInput.keys) == null ? void 0 : _breakpointsInput$key.reduce((acc, key) => {\n const breakpointStyleKey = breakpointsInput.up(key);\n acc[breakpointStyleKey] = {};\n return acc;\n }, {});\n return breakpointsInOrder || {};\n}\nexport function removeUnusedBreakpoints(breakpointKeys, style) {\n return breakpointKeys.reduce((acc, key) => {\n const breakpointOutput = acc[key];\n const isBreakpointUnused = !breakpointOutput || Object.keys(breakpointOutput).length === 0;\n if (isBreakpointUnused) {\n delete acc[key];\n }\n return acc;\n }, style);\n}\nexport function mergeBreakpointsInOrder(breakpointsInput, ...styles) {\n const emptyBreakpoints = createEmptyBreakpointObject(breakpointsInput);\n const mergedOutput = [emptyBreakpoints, ...styles].reduce((prev, next) => deepmerge(prev, next), {});\n return removeUnusedBreakpoints(Object.keys(emptyBreakpoints), mergedOutput);\n}\n\n// compute base for responsive values; e.g.,\n// [1,2,3] => {xs: true, sm: true, md: true}\n// {xs: 1, sm: 2, md: 3} => {xs: true, sm: true, md: true}\nexport function computeBreakpointsBase(breakpointValues, themeBreakpoints) {\n // fixed value\n if (typeof breakpointValues !== 'object') {\n return {};\n }\n const base = {};\n const breakpointsKeys = Object.keys(themeBreakpoints);\n if (Array.isArray(breakpointValues)) {\n breakpointsKeys.forEach((breakpoint, i) => {\n if (i < breakpointValues.length) {\n base[breakpoint] = true;\n }\n });\n } else {\n breakpointsKeys.forEach(breakpoint => {\n if (breakpointValues[breakpoint] != null) {\n base[breakpoint] = true;\n }\n });\n }\n return base;\n}\nexport function resolveBreakpointValues({\n values: breakpointValues,\n breakpoints: themeBreakpoints,\n base: customBase\n}) {\n const base = customBase || computeBreakpointsBase(breakpointValues, themeBreakpoints);\n const keys = Object.keys(base);\n if (keys.length === 0) {\n return breakpointValues;\n }\n let previous;\n return keys.reduce((acc, breakpoint, i) => {\n if (Array.isArray(breakpointValues)) {\n acc[breakpoint] = breakpointValues[i] != null ? breakpointValues[i] : breakpointValues[previous];\n previous = i;\n } else if (typeof breakpointValues === 'object') {\n acc[breakpoint] = breakpointValues[breakpoint] != null ? breakpointValues[breakpoint] : breakpointValues[previous];\n previous = breakpoint;\n } else {\n acc[breakpoint] = breakpointValues;\n }\n return acc;\n }, {});\n}\nexport default breakpoints;","import capitalize from '@mui/utils/capitalize';\nimport responsivePropType from './responsivePropType';\nimport { handleBreakpoints } from './breakpoints';\nexport function getPath(obj, path, checkVars = true) {\n if (!path || typeof path !== 'string') {\n return null;\n }\n\n // Check if CSS variables are used\n if (obj && obj.vars && checkVars) {\n const val = `vars.${path}`.split('.').reduce((acc, item) => acc && acc[item] ? acc[item] : null, obj);\n if (val != null) {\n return val;\n }\n }\n return path.split('.').reduce((acc, item) => {\n if (acc && acc[item] != null) {\n return acc[item];\n }\n return null;\n }, obj);\n}\nexport function getStyleValue(themeMapping, transform, propValueFinal, userValue = propValueFinal) {\n let value;\n if (typeof themeMapping === 'function') {\n value = themeMapping(propValueFinal);\n } else if (Array.isArray(themeMapping)) {\n value = themeMapping[propValueFinal] || userValue;\n } else {\n value = getPath(themeMapping, propValueFinal) || userValue;\n }\n if (transform) {\n value = transform(value, userValue, themeMapping);\n }\n return value;\n}\nfunction style(options) {\n const {\n prop,\n cssProperty = options.prop,\n themeKey,\n transform\n } = options;\n\n // false positive\n // eslint-disable-next-line react/function-component-definition\n const fn = props => {\n if (props[prop] == null) {\n return null;\n }\n const propValue = props[prop];\n const theme = props.theme;\n const themeMapping = getPath(theme, themeKey) || {};\n const styleFromPropValue = propValueFinal => {\n let value = getStyleValue(themeMapping, transform, propValueFinal);\n if (propValueFinal === value && typeof propValueFinal === 'string') {\n // Haven't found value\n value = getStyleValue(themeMapping, transform, `${prop}${propValueFinal === 'default' ? '' : capitalize(propValueFinal)}`, propValueFinal);\n }\n if (cssProperty === false) {\n return value;\n }\n return {\n [cssProperty]: value\n };\n };\n return handleBreakpoints(props, propValue, styleFromPropValue);\n };\n fn.propTypes = process.env.NODE_ENV !== 'production' ? {\n [prop]: responsivePropType\n } : {};\n fn.filterProps = [prop];\n return fn;\n}\nexport default style;","export default function memoize(fn) {\n const cache = {};\n return arg => {\n if (cache[arg] === undefined) {\n cache[arg] = fn(arg);\n }\n return cache[arg];\n };\n}","import responsivePropType from './responsivePropType';\nimport { handleBreakpoints } from './breakpoints';\nimport { getPath } from './style';\nimport merge from './merge';\nimport memoize from './memoize';\nconst properties = {\n m: 'margin',\n p: 'padding'\n};\nconst directions = {\n t: 'Top',\n r: 'Right',\n b: 'Bottom',\n l: 'Left',\n x: ['Left', 'Right'],\n y: ['Top', 'Bottom']\n};\nconst aliases = {\n marginX: 'mx',\n marginY: 'my',\n paddingX: 'px',\n paddingY: 'py'\n};\n\n// memoize() impact:\n// From 300,000 ops/sec\n// To 350,000 ops/sec\nconst getCssProperties = memoize(prop => {\n // It's not a shorthand notation.\n if (prop.length > 2) {\n if (aliases[prop]) {\n prop = aliases[prop];\n } else {\n return [prop];\n }\n }\n const [a, b] = prop.split('');\n const property = properties[a];\n const direction = directions[b] || '';\n return Array.isArray(direction) ? direction.map(dir => property + dir) : [property + direction];\n});\nexport const marginKeys = ['m', 'mt', 'mr', 'mb', 'ml', 'mx', 'my', 'margin', 'marginTop', 'marginRight', 'marginBottom', 'marginLeft', 'marginX', 'marginY', 'marginInline', 'marginInlineStart', 'marginInlineEnd', 'marginBlock', 'marginBlockStart', 'marginBlockEnd'];\nexport const paddingKeys = ['p', 'pt', 'pr', 'pb', 'pl', 'px', 'py', 'padding', 'paddingTop', 'paddingRight', 'paddingBottom', 'paddingLeft', 'paddingX', 'paddingY', 'paddingInline', 'paddingInlineStart', 'paddingInlineEnd', 'paddingBlock', 'paddingBlockStart', 'paddingBlockEnd'];\nconst spacingKeys = [...marginKeys, ...paddingKeys];\nexport function createUnaryUnit(theme, themeKey, defaultValue, propName) {\n var _getPath;\n const themeSpacing = (_getPath = getPath(theme, themeKey, false)) != null ? _getPath : defaultValue;\n if (typeof themeSpacing === 'number') {\n return abs => {\n if (typeof abs === 'string') {\n return abs;\n }\n if (process.env.NODE_ENV !== 'production') {\n if (typeof abs !== 'number') {\n console.error(`MUI: Expected ${propName} argument to be a number or a string, got ${abs}.`);\n }\n }\n return themeSpacing * abs;\n };\n }\n if (Array.isArray(themeSpacing)) {\n return abs => {\n if (typeof abs === 'string') {\n return abs;\n }\n if (process.env.NODE_ENV !== 'production') {\n if (!Number.isInteger(abs)) {\n console.error([`MUI: The \\`theme.${themeKey}\\` array type cannot be combined with non integer values.` + `You should either use an integer value that can be used as index, or define the \\`theme.${themeKey}\\` as a number.`].join('\\n'));\n } else if (abs > themeSpacing.length - 1) {\n console.error([`MUI: The value provided (${abs}) overflows.`, `The supported values are: ${JSON.stringify(themeSpacing)}.`, `${abs} > ${themeSpacing.length - 1}, you need to add the missing values.`].join('\\n'));\n }\n }\n return themeSpacing[abs];\n };\n }\n if (typeof themeSpacing === 'function') {\n return themeSpacing;\n }\n if (process.env.NODE_ENV !== 'production') {\n console.error([`MUI: The \\`theme.${themeKey}\\` value (${themeSpacing}) is invalid.`, 'It should be a number, an array or a function.'].join('\\n'));\n }\n return () => undefined;\n}\nexport function createUnarySpacing(theme) {\n return createUnaryUnit(theme, 'spacing', 8, 'spacing');\n}\nexport function getValue(transformer, propValue) {\n if (typeof propValue === 'string' || propValue == null) {\n return propValue;\n }\n const abs = Math.abs(propValue);\n const transformed = transformer(abs);\n if (propValue >= 0) {\n return transformed;\n }\n if (typeof transformed === 'number') {\n return -transformed;\n }\n return `-${transformed}`;\n}\nexport function getStyleFromPropValue(cssProperties, transformer) {\n return propValue => cssProperties.reduce((acc, cssProperty) => {\n acc[cssProperty] = getValue(transformer, propValue);\n return acc;\n }, {});\n}\nfunction resolveCssProperty(props, keys, prop, transformer) {\n // Using a hash computation over an array iteration could be faster, but with only 28 items,\n // it's doesn't worth the bundle size.\n if (keys.indexOf(prop) === -1) {\n return null;\n }\n const cssProperties = getCssProperties(prop);\n const styleFromPropValue = getStyleFromPropValue(cssProperties, transformer);\n const propValue = props[prop];\n return handleBreakpoints(props, propValue, styleFromPropValue);\n}\nfunction style(props, keys) {\n const transformer = createUnarySpacing(props.theme);\n return Object.keys(props).map(prop => resolveCssProperty(props, keys, prop, transformer)).reduce(merge, {});\n}\nexport function margin(props) {\n return style(props, marginKeys);\n}\nmargin.propTypes = process.env.NODE_ENV !== 'production' ? marginKeys.reduce((obj, key) => {\n obj[key] = responsivePropType;\n return obj;\n}, {}) : {};\nmargin.filterProps = marginKeys;\nexport function padding(props) {\n return style(props, paddingKeys);\n}\npadding.propTypes = process.env.NODE_ENV !== 'production' ? paddingKeys.reduce((obj, key) => {\n obj[key] = responsivePropType;\n return obj;\n}, {}) : {};\npadding.filterProps = paddingKeys;\nfunction spacing(props) {\n return style(props, spacingKeys);\n}\nspacing.propTypes = process.env.NODE_ENV !== 'production' ? spacingKeys.reduce((obj, key) => {\n obj[key] = responsivePropType;\n return obj;\n}, {}) : {};\nspacing.filterProps = spacingKeys;\nexport default spacing;","import { createUnarySpacing } from '../spacing';\n\n// The different signatures imply different meaning for their arguments that can't be expressed structurally.\n// We express the difference with variable names.\n\nexport default function createSpacing(spacingInput = 8) {\n // Already transformed.\n if (spacingInput.mui) {\n return spacingInput;\n }\n\n // Material Design layouts are visually balanced. Most measurements align to an 8dp grid, which aligns both spacing and the overall layout.\n // Smaller components, such as icons, can align to a 4dp grid.\n // https://m2.material.io/design/layout/understanding-layout.html\n const transform = createUnarySpacing({\n spacing: spacingInput\n });\n const spacing = (...argsInput) => {\n if (process.env.NODE_ENV !== 'production') {\n if (!(argsInput.length <= 4)) {\n console.error(`MUI: Too many arguments provided, expected between 0 and 4, got ${argsInput.length}`);\n }\n }\n const args = argsInput.length === 0 ? [1] : argsInput;\n return args.map(argument => {\n const output = transform(argument);\n return typeof output === 'number' ? `${output}px` : output;\n }).join(' ');\n };\n spacing.mui = true;\n return spacing;\n}","import merge from './merge';\nfunction compose(...styles) {\n const handlers = styles.reduce((acc, style) => {\n style.filterProps.forEach(prop => {\n acc[prop] = style;\n });\n return acc;\n }, {});\n\n // false positive\n // eslint-disable-next-line react/function-component-definition\n const fn = props => {\n return Object.keys(props).reduce((acc, prop) => {\n if (handlers[prop]) {\n return merge(acc, handlers[prop](props));\n }\n return acc;\n }, {});\n };\n fn.propTypes = process.env.NODE_ENV !== 'production' ? styles.reduce((acc, style) => Object.assign(acc, style.propTypes), {}) : {};\n fn.filterProps = styles.reduce((acc, style) => acc.concat(style.filterProps), []);\n return fn;\n}\nexport default compose;","import responsivePropType from './responsivePropType';\nimport style from './style';\nimport compose from './compose';\nimport { createUnaryUnit, getValue } from './spacing';\nimport { handleBreakpoints } from './breakpoints';\nexport function borderTransform(value) {\n if (typeof value !== 'number') {\n return value;\n }\n return `${value}px solid`;\n}\nfunction createBorderStyle(prop, transform) {\n return style({\n prop,\n themeKey: 'borders',\n transform\n });\n}\nexport const border = createBorderStyle('border', borderTransform);\nexport const borderTop = createBorderStyle('borderTop', borderTransform);\nexport const borderRight = createBorderStyle('borderRight', borderTransform);\nexport const borderBottom = createBorderStyle('borderBottom', borderTransform);\nexport const borderLeft = createBorderStyle('borderLeft', borderTransform);\nexport const borderColor = createBorderStyle('borderColor');\nexport const borderTopColor = createBorderStyle('borderTopColor');\nexport const borderRightColor = createBorderStyle('borderRightColor');\nexport const borderBottomColor = createBorderStyle('borderBottomColor');\nexport const borderLeftColor = createBorderStyle('borderLeftColor');\nexport const outline = createBorderStyle('outline', borderTransform);\nexport const outlineColor = createBorderStyle('outlineColor');\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const borderRadius = props => {\n if (props.borderRadius !== undefined && props.borderRadius !== null) {\n const transformer = createUnaryUnit(props.theme, 'shape.borderRadius', 4, 'borderRadius');\n const styleFromPropValue = propValue => ({\n borderRadius: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.borderRadius, styleFromPropValue);\n }\n return null;\n};\nborderRadius.propTypes = process.env.NODE_ENV !== 'production' ? {\n borderRadius: responsivePropType\n} : {};\nborderRadius.filterProps = ['borderRadius'];\nconst borders = compose(border, borderTop, borderRight, borderBottom, borderLeft, borderColor, borderTopColor, borderRightColor, borderBottomColor, borderLeftColor, borderRadius, outline, outlineColor);\nexport default borders;","import style from './style';\nimport compose from './compose';\nimport { createUnaryUnit, getValue } from './spacing';\nimport { handleBreakpoints } from './breakpoints';\nimport responsivePropType from './responsivePropType';\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const gap = props => {\n if (props.gap !== undefined && props.gap !== null) {\n const transformer = createUnaryUnit(props.theme, 'spacing', 8, 'gap');\n const styleFromPropValue = propValue => ({\n gap: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.gap, styleFromPropValue);\n }\n return null;\n};\ngap.propTypes = process.env.NODE_ENV !== 'production' ? {\n gap: responsivePropType\n} : {};\ngap.filterProps = ['gap'];\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const columnGap = props => {\n if (props.columnGap !== undefined && props.columnGap !== null) {\n const transformer = createUnaryUnit(props.theme, 'spacing', 8, 'columnGap');\n const styleFromPropValue = propValue => ({\n columnGap: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.columnGap, styleFromPropValue);\n }\n return null;\n};\ncolumnGap.propTypes = process.env.NODE_ENV !== 'production' ? {\n columnGap: responsivePropType\n} : {};\ncolumnGap.filterProps = ['columnGap'];\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const rowGap = props => {\n if (props.rowGap !== undefined && props.rowGap !== null) {\n const transformer = createUnaryUnit(props.theme, 'spacing', 8, 'rowGap');\n const styleFromPropValue = propValue => ({\n rowGap: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.rowGap, styleFromPropValue);\n }\n return null;\n};\nrowGap.propTypes = process.env.NODE_ENV !== 'production' ? {\n rowGap: responsivePropType\n} : {};\nrowGap.filterProps = ['rowGap'];\nexport const gridColumn = style({\n prop: 'gridColumn'\n});\nexport const gridRow = style({\n prop: 'gridRow'\n});\nexport const gridAutoFlow = style({\n prop: 'gridAutoFlow'\n});\nexport const gridAutoColumns = style({\n prop: 'gridAutoColumns'\n});\nexport const gridAutoRows = style({\n prop: 'gridAutoRows'\n});\nexport const gridTemplateColumns = style({\n prop: 'gridTemplateColumns'\n});\nexport const gridTemplateRows = style({\n prop: 'gridTemplateRows'\n});\nexport const gridTemplateAreas = style({\n prop: 'gridTemplateAreas'\n});\nexport const gridArea = style({\n prop: 'gridArea'\n});\nconst grid = compose(gap, columnGap, rowGap, gridColumn, gridRow, gridAutoFlow, gridAutoColumns, gridAutoRows, gridTemplateColumns, gridTemplateRows, gridTemplateAreas, gridArea);\nexport default grid;","import style from './style';\nimport compose from './compose';\nexport function paletteTransform(value, userValue) {\n if (userValue === 'grey') {\n return userValue;\n }\n return value;\n}\nexport const color = style({\n prop: 'color',\n themeKey: 'palette',\n transform: paletteTransform\n});\nexport const bgcolor = style({\n prop: 'bgcolor',\n cssProperty: 'backgroundColor',\n themeKey: 'palette',\n transform: paletteTransform\n});\nexport const backgroundColor = style({\n prop: 'backgroundColor',\n themeKey: 'palette',\n transform: paletteTransform\n});\nconst palette = compose(color, bgcolor, backgroundColor);\nexport default palette;","import style from './style';\nimport compose from './compose';\nimport { handleBreakpoints, values as breakpointsValues } from './breakpoints';\nexport function sizingTransform(value) {\n return value <= 1 && value !== 0 ? `${value * 100}%` : value;\n}\nexport const width = style({\n prop: 'width',\n transform: sizingTransform\n});\nexport const maxWidth = props => {\n if (props.maxWidth !== undefined && props.maxWidth !== null) {\n const styleFromPropValue = propValue => {\n var _props$theme, _props$theme2;\n const breakpoint = ((_props$theme = props.theme) == null || (_props$theme = _props$theme.breakpoints) == null || (_props$theme = _props$theme.values) == null ? void 0 : _props$theme[propValue]) || breakpointsValues[propValue];\n if (!breakpoint) {\n return {\n maxWidth: sizingTransform(propValue)\n };\n }\n if (((_props$theme2 = props.theme) == null || (_props$theme2 = _props$theme2.breakpoints) == null ? void 0 : _props$theme2.unit) !== 'px') {\n return {\n maxWidth: `${breakpoint}${props.theme.breakpoints.unit}`\n };\n }\n return {\n maxWidth: breakpoint\n };\n };\n return handleBreakpoints(props, props.maxWidth, styleFromPropValue);\n }\n return null;\n};\nmaxWidth.filterProps = ['maxWidth'];\nexport const minWidth = style({\n prop: 'minWidth',\n transform: sizingTransform\n});\nexport const height = style({\n prop: 'height',\n transform: sizingTransform\n});\nexport const maxHeight = style({\n prop: 'maxHeight',\n transform: sizingTransform\n});\nexport const minHeight = style({\n prop: 'minHeight',\n transform: sizingTransform\n});\nexport const sizeWidth = style({\n prop: 'size',\n cssProperty: 'width',\n transform: sizingTransform\n});\nexport const sizeHeight = style({\n prop: 'size',\n cssProperty: 'height',\n transform: sizingTransform\n});\nexport const boxSizing = style({\n prop: 'boxSizing'\n});\nconst sizing = compose(width, maxWidth, minWidth, height, maxHeight, minHeight, boxSizing);\nexport default sizing;","import { padding, margin } from '../spacing';\nimport { borderRadius, borderTransform } from '../borders';\nimport { gap, rowGap, columnGap } from '../cssGrid';\nimport { paletteTransform } from '../palette';\nimport { maxWidth, sizingTransform } from '../sizing';\nconst defaultSxConfig = {\n // borders\n border: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderTop: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderRight: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderBottom: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderLeft: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderColor: {\n themeKey: 'palette'\n },\n borderTopColor: {\n themeKey: 'palette'\n },\n borderRightColor: {\n themeKey: 'palette'\n },\n borderBottomColor: {\n themeKey: 'palette'\n },\n borderLeftColor: {\n themeKey: 'palette'\n },\n outline: {\n themeKey: 'borders',\n transform: borderTransform\n },\n outlineColor: {\n themeKey: 'palette'\n },\n borderRadius: {\n themeKey: 'shape.borderRadius',\n style: borderRadius\n },\n // palette\n color: {\n themeKey: 'palette',\n transform: paletteTransform\n },\n bgcolor: {\n themeKey: 'palette',\n cssProperty: 'backgroundColor',\n transform: paletteTransform\n },\n backgroundColor: {\n themeKey: 'palette',\n transform: paletteTransform\n },\n // spacing\n p: {\n style: padding\n },\n pt: {\n style: padding\n },\n pr: {\n style: padding\n },\n pb: {\n style: padding\n },\n pl: {\n style: padding\n },\n px: {\n style: padding\n },\n py: {\n style: padding\n },\n padding: {\n style: padding\n },\n paddingTop: {\n style: padding\n },\n paddingRight: {\n style: padding\n },\n paddingBottom: {\n style: padding\n },\n paddingLeft: {\n style: padding\n },\n paddingX: {\n style: padding\n },\n paddingY: {\n style: padding\n },\n paddingInline: {\n style: padding\n },\n paddingInlineStart: {\n style: padding\n },\n paddingInlineEnd: {\n style: padding\n },\n paddingBlock: {\n style: padding\n },\n paddingBlockStart: {\n style: padding\n },\n paddingBlockEnd: {\n style: padding\n },\n m: {\n style: margin\n },\n mt: {\n style: margin\n },\n mr: {\n style: margin\n },\n mb: {\n style: margin\n },\n ml: {\n style: margin\n },\n mx: {\n style: margin\n },\n my: {\n style: margin\n },\n margin: {\n style: margin\n },\n marginTop: {\n style: margin\n },\n marginRight: {\n style: margin\n },\n marginBottom: {\n style: margin\n },\n marginLeft: {\n style: margin\n },\n marginX: {\n style: margin\n },\n marginY: {\n style: margin\n },\n marginInline: {\n style: margin\n },\n marginInlineStart: {\n style: margin\n },\n marginInlineEnd: {\n style: margin\n },\n marginBlock: {\n style: margin\n },\n marginBlockStart: {\n style: margin\n },\n marginBlockEnd: {\n style: margin\n },\n // display\n displayPrint: {\n cssProperty: false,\n transform: value => ({\n '@media print': {\n display: value\n }\n })\n },\n display: {},\n overflow: {},\n textOverflow: {},\n visibility: {},\n whiteSpace: {},\n // flexbox\n flexBasis: {},\n flexDirection: {},\n flexWrap: {},\n justifyContent: {},\n alignItems: {},\n alignContent: {},\n order: {},\n flex: {},\n flexGrow: {},\n flexShrink: {},\n alignSelf: {},\n justifyItems: {},\n justifySelf: {},\n // grid\n gap: {\n style: gap\n },\n rowGap: {\n style: rowGap\n },\n columnGap: {\n style: columnGap\n },\n gridColumn: {},\n gridRow: {},\n gridAutoFlow: {},\n gridAutoColumns: {},\n gridAutoRows: {},\n gridTemplateColumns: {},\n gridTemplateRows: {},\n gridTemplateAreas: {},\n gridArea: {},\n // positions\n position: {},\n zIndex: {\n themeKey: 'zIndex'\n },\n top: {},\n right: {},\n bottom: {},\n left: {},\n // shadows\n boxShadow: {\n themeKey: 'shadows'\n },\n // sizing\n width: {\n transform: sizingTransform\n },\n maxWidth: {\n style: maxWidth\n },\n minWidth: {\n transform: sizingTransform\n },\n height: {\n transform: sizingTransform\n },\n maxHeight: {\n transform: sizingTransform\n },\n minHeight: {\n transform: sizingTransform\n },\n boxSizing: {},\n // typography\n fontFamily: {\n themeKey: 'typography'\n },\n fontSize: {\n themeKey: 'typography'\n },\n fontStyle: {\n themeKey: 'typography'\n },\n fontWeight: {\n themeKey: 'typography'\n },\n letterSpacing: {},\n textTransform: {},\n lineHeight: {},\n textAlign: {},\n typography: {\n cssProperty: false,\n themeKey: 'typography'\n }\n};\nexport default defaultSxConfig;","import capitalize from '@mui/utils/capitalize';\nimport merge from '../merge';\nimport { getPath, getStyleValue as getValue } from '../style';\nimport { handleBreakpoints, createEmptyBreakpointObject, removeUnusedBreakpoints } from '../breakpoints';\nimport defaultSxConfig from './defaultSxConfig';\nfunction objectsHaveSameKeys(...objects) {\n const allKeys = objects.reduce((keys, object) => keys.concat(Object.keys(object)), []);\n const union = new Set(allKeys);\n return objects.every(object => union.size === Object.keys(object).length);\n}\nfunction callIfFn(maybeFn, arg) {\n return typeof maybeFn === 'function' ? maybeFn(arg) : maybeFn;\n}\n\n// eslint-disable-next-line @typescript-eslint/naming-convention\nexport function unstable_createStyleFunctionSx() {\n function getThemeValue(prop, val, theme, config) {\n const props = {\n [prop]: val,\n theme\n };\n const options = config[prop];\n if (!options) {\n return {\n [prop]: val\n };\n }\n const {\n cssProperty = prop,\n themeKey,\n transform,\n style\n } = options;\n if (val == null) {\n return null;\n }\n\n // TODO v6: remove, see https://github.com/mui/material-ui/pull/38123\n if (themeKey === 'typography' && val === 'inherit') {\n return {\n [prop]: val\n };\n }\n const themeMapping = getPath(theme, themeKey) || {};\n if (style) {\n return style(props);\n }\n const styleFromPropValue = propValueFinal => {\n let value = getValue(themeMapping, transform, propValueFinal);\n if (propValueFinal === value && typeof propValueFinal === 'string') {\n // Haven't found value\n value = getValue(themeMapping, transform, `${prop}${propValueFinal === 'default' ? '' : capitalize(propValueFinal)}`, propValueFinal);\n }\n if (cssProperty === false) {\n return value;\n }\n return {\n [cssProperty]: value\n };\n };\n return handleBreakpoints(props, val, styleFromPropValue);\n }\n function styleFunctionSx(props) {\n var _theme$unstable_sxCon;\n const {\n sx,\n theme = {}\n } = props || {};\n if (!sx) {\n return null; // Emotion & styled-components will neglect null\n }\n const config = (_theme$unstable_sxCon = theme.unstable_sxConfig) != null ? _theme$unstable_sxCon : defaultSxConfig;\n\n /*\n * Receive `sxInput` as object or callback\n * and then recursively check keys & values to create media query object styles.\n * (the result will be used in `styled`)\n */\n function traverse(sxInput) {\n let sxObject = sxInput;\n if (typeof sxInput === 'function') {\n sxObject = sxInput(theme);\n } else if (typeof sxInput !== 'object') {\n // value\n return sxInput;\n }\n if (!sxObject) {\n return null;\n }\n const emptyBreakpoints = createEmptyBreakpointObject(theme.breakpoints);\n const breakpointsKeys = Object.keys(emptyBreakpoints);\n let css = emptyBreakpoints;\n Object.keys(sxObject).forEach(styleKey => {\n const value = callIfFn(sxObject[styleKey], theme);\n if (value !== null && value !== undefined) {\n if (typeof value === 'object') {\n if (config[styleKey]) {\n css = merge(css, getThemeValue(styleKey, value, theme, config));\n } else {\n const breakpointsValues = handleBreakpoints({\n theme\n }, value, x => ({\n [styleKey]: x\n }));\n if (objectsHaveSameKeys(breakpointsValues, value)) {\n css[styleKey] = styleFunctionSx({\n sx: value,\n theme\n });\n } else {\n css = merge(css, breakpointsValues);\n }\n }\n } else {\n css = merge(css, getThemeValue(styleKey, value, theme, config));\n }\n }\n });\n return removeUnusedBreakpoints(breakpointsKeys, css);\n }\n return Array.isArray(sx) ? sx.map(traverse) : traverse(sx);\n }\n return styleFunctionSx;\n}\nconst styleFunctionSx = unstable_createStyleFunctionSx();\nstyleFunctionSx.filterProps = ['sx'];\nexport default styleFunctionSx;","/**\n * A universal utility to style components with multiple color modes. Always use it from the theme object.\n * It works with:\n * - [Basic theme](https://mui.com/material-ui/customization/dark-mode/)\n * - [CSS theme variables](https://mui.com/material-ui/experimental-api/css-theme-variables/overview/)\n * - Zero-runtime engine\n *\n * Tips: Use an array over object spread and place `theme.applyStyles()` last.\n *\n * ✅ [{ background: '#e5e5e5' }, theme.applyStyles('dark', { background: '#1c1c1c' })]\n *\n * 🚫 { background: '#e5e5e5', ...theme.applyStyles('dark', { background: '#1c1c1c' })}\n *\n * @example\n * 1. using with `styled`:\n * ```jsx\n * const Component = styled('div')(({ theme }) => [\n * { background: '#e5e5e5' },\n * theme.applyStyles('dark', {\n * background: '#1c1c1c',\n * color: '#fff',\n * }),\n * ]);\n * ```\n *\n * @example\n * 2. using with `sx` prop:\n * ```jsx\n * [\n * { background: '#e5e5e5' },\n * theme.applyStyles('dark', {\n * background: '#1c1c1c',\n * color: '#fff',\n * }),\n * ]}\n * />\n * ```\n *\n * @example\n * 3. theming a component:\n * ```jsx\n * extendTheme({\n * components: {\n * MuiButton: {\n * styleOverrides: {\n * root: ({ theme }) => [\n * { background: '#e5e5e5' },\n * theme.applyStyles('dark', {\n * background: '#1c1c1c',\n * color: '#fff',\n * }),\n * ],\n * },\n * }\n * }\n * })\n *```\n */\nexport default function applyStyles(key, styles) {\n // @ts-expect-error this is 'any' type\n const theme = this;\n if (theme.vars && typeof theme.getColorSchemeSelector === 'function') {\n // If CssVarsProvider is used as a provider,\n // returns '* :where([data-mui-color-scheme=\"light|dark\"]) &'\n const selector = theme.getColorSchemeSelector(key).replace(/(\\[[^\\]]+\\])/, '*:where($1)');\n return {\n [selector]: styles\n };\n }\n if (theme.palette.mode === key) {\n return styles;\n }\n return {};\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"breakpoints\", \"palette\", \"spacing\", \"shape\"];\nimport deepmerge from '@mui/utils/deepmerge';\nimport createBreakpoints from './createBreakpoints';\nimport shape from './shape';\nimport createSpacing from './createSpacing';\nimport styleFunctionSx from '../styleFunctionSx/styleFunctionSx';\nimport defaultSxConfig from '../styleFunctionSx/defaultSxConfig';\nimport applyStyles from './applyStyles';\nfunction createTheme(options = {}, ...args) {\n const {\n breakpoints: breakpointsInput = {},\n palette: paletteInput = {},\n spacing: spacingInput,\n shape: shapeInput = {}\n } = options,\n other = _objectWithoutPropertiesLoose(options, _excluded);\n const breakpoints = createBreakpoints(breakpointsInput);\n const spacing = createSpacing(spacingInput);\n let muiTheme = deepmerge({\n breakpoints,\n direction: 'ltr',\n components: {},\n // Inject component definitions.\n palette: _extends({\n mode: 'light'\n }, paletteInput),\n spacing,\n shape: _extends({}, shape, shapeInput)\n }, other);\n muiTheme.applyStyles = applyStyles;\n muiTheme = args.reduce((acc, argument) => deepmerge(acc, argument), muiTheme);\n muiTheme.unstable_sxConfig = _extends({}, defaultSxConfig, other == null ? void 0 : other.unstable_sxConfig);\n muiTheme.unstable_sx = function sx(props) {\n return styleFunctionSx({\n sx: props,\n theme: this\n });\n };\n return muiTheme;\n}\nexport default createTheme;","'use client';\n\nimport * as React from 'react';\nimport { ThemeContext } from '@mui/styled-engine';\nfunction isObjectEmpty(obj) {\n return Object.keys(obj).length === 0;\n}\nfunction useTheme(defaultTheme = null) {\n const contextTheme = React.useContext(ThemeContext);\n return !contextTheme || isObjectEmpty(contextTheme) ? defaultTheme : contextTheme;\n}\nexport default useTheme;","'use client';\n\nimport createTheme from './createTheme';\nimport useThemeWithoutDefault from './useThemeWithoutDefault';\nexport const systemDefaultTheme = createTheme();\nfunction useTheme(defaultTheme = systemDefaultTheme) {\n return useThemeWithoutDefault(defaultTheme);\n}\nexport default useTheme;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"ownerState\"],\n _excluded2 = [\"variants\"],\n _excluded3 = [\"name\", \"slot\", \"skipVariantsResolver\", \"skipSx\", \"overridesResolver\"];\n/* eslint-disable no-underscore-dangle */\nimport styledEngineStyled, { internal_processStyles as processStyles } from '@mui/styled-engine';\nimport { isPlainObject } from '@mui/utils/deepmerge';\nimport capitalize from '@mui/utils/capitalize';\nimport getDisplayName from '@mui/utils/getDisplayName';\nimport createTheme from './createTheme';\nimport styleFunctionSx from './styleFunctionSx';\nfunction isEmpty(obj) {\n return Object.keys(obj).length === 0;\n}\n\n// https://github.com/emotion-js/emotion/blob/26ded6109fcd8ca9875cc2ce4564fee678a3f3c5/packages/styled/src/utils.js#L40\nfunction isStringTag(tag) {\n return typeof tag === 'string' &&\n // 96 is one less than the char code\n // for \"a\" so this is checking that\n // it's a lowercase character\n tag.charCodeAt(0) > 96;\n}\n\n// Update /system/styled/#api in case if this changes\nexport function shouldForwardProp(prop) {\n return prop !== 'ownerState' && prop !== 'theme' && prop !== 'sx' && prop !== 'as';\n}\nexport const systemDefaultTheme = createTheme();\nconst lowercaseFirstLetter = string => {\n if (!string) {\n return string;\n }\n return string.charAt(0).toLowerCase() + string.slice(1);\n};\nfunction resolveTheme({\n defaultTheme,\n theme,\n themeId\n}) {\n return isEmpty(theme) ? defaultTheme : theme[themeId] || theme;\n}\nfunction defaultOverridesResolver(slot) {\n if (!slot) {\n return null;\n }\n return (props, styles) => styles[slot];\n}\nfunction processStyleArg(callableStyle, _ref) {\n let {\n ownerState\n } = _ref,\n props = _objectWithoutPropertiesLoose(_ref, _excluded);\n const resolvedStylesArg = typeof callableStyle === 'function' ? callableStyle(_extends({\n ownerState\n }, props)) : callableStyle;\n if (Array.isArray(resolvedStylesArg)) {\n return resolvedStylesArg.flatMap(resolvedStyle => processStyleArg(resolvedStyle, _extends({\n ownerState\n }, props)));\n }\n if (!!resolvedStylesArg && typeof resolvedStylesArg === 'object' && Array.isArray(resolvedStylesArg.variants)) {\n const {\n variants = []\n } = resolvedStylesArg,\n otherStyles = _objectWithoutPropertiesLoose(resolvedStylesArg, _excluded2);\n let result = otherStyles;\n variants.forEach(variant => {\n let isMatch = true;\n if (typeof variant.props === 'function') {\n isMatch = variant.props(_extends({\n ownerState\n }, props, ownerState));\n } else {\n Object.keys(variant.props).forEach(key => {\n if ((ownerState == null ? void 0 : ownerState[key]) !== variant.props[key] && props[key] !== variant.props[key]) {\n isMatch = false;\n }\n });\n }\n if (isMatch) {\n if (!Array.isArray(result)) {\n result = [result];\n }\n result.push(typeof variant.style === 'function' ? variant.style(_extends({\n ownerState\n }, props, ownerState)) : variant.style);\n }\n });\n return result;\n }\n return resolvedStylesArg;\n}\nexport default function createStyled(input = {}) {\n const {\n themeId,\n defaultTheme = systemDefaultTheme,\n rootShouldForwardProp = shouldForwardProp,\n slotShouldForwardProp = shouldForwardProp\n } = input;\n const systemSx = props => {\n return styleFunctionSx(_extends({}, props, {\n theme: resolveTheme(_extends({}, props, {\n defaultTheme,\n themeId\n }))\n }));\n };\n systemSx.__mui_systemSx = true;\n return (tag, inputOptions = {}) => {\n // Filter out the `sx` style function from the previous styled component to prevent unnecessary styles generated by the composite components.\n processStyles(tag, styles => styles.filter(style => !(style != null && style.__mui_systemSx)));\n const {\n name: componentName,\n slot: componentSlot,\n skipVariantsResolver: inputSkipVariantsResolver,\n skipSx: inputSkipSx,\n // TODO v6: remove `lowercaseFirstLetter()` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n overridesResolver = defaultOverridesResolver(lowercaseFirstLetter(componentSlot))\n } = inputOptions,\n options = _objectWithoutPropertiesLoose(inputOptions, _excluded3);\n\n // if skipVariantsResolver option is defined, take the value, otherwise, true for root and false for other slots.\n const skipVariantsResolver = inputSkipVariantsResolver !== undefined ? inputSkipVariantsResolver :\n // TODO v6: remove `Root` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n componentSlot && componentSlot !== 'Root' && componentSlot !== 'root' || false;\n const skipSx = inputSkipSx || false;\n let label;\n if (process.env.NODE_ENV !== 'production') {\n if (componentName) {\n // TODO v6: remove `lowercaseFirstLetter()` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n label = `${componentName}-${lowercaseFirstLetter(componentSlot || 'Root')}`;\n }\n }\n let shouldForwardPropOption = shouldForwardProp;\n\n // TODO v6: remove `Root` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n if (componentSlot === 'Root' || componentSlot === 'root') {\n shouldForwardPropOption = rootShouldForwardProp;\n } else if (componentSlot) {\n // any other slot specified\n shouldForwardPropOption = slotShouldForwardProp;\n } else if (isStringTag(tag)) {\n // for string (html) tag, preserve the behavior in emotion & styled-components.\n shouldForwardPropOption = undefined;\n }\n const defaultStyledResolver = styledEngineStyled(tag, _extends({\n shouldForwardProp: shouldForwardPropOption,\n label\n }, options));\n const transformStyleArg = stylesArg => {\n // On the server Emotion doesn't use React.forwardRef for creating components, so the created\n // component stays as a function. This condition makes sure that we do not interpolate functions\n // which are basically components used as a selectors.\n if (typeof stylesArg === 'function' && stylesArg.__emotion_real !== stylesArg || isPlainObject(stylesArg)) {\n return props => processStyleArg(stylesArg, _extends({}, props, {\n theme: resolveTheme({\n theme: props.theme,\n defaultTheme,\n themeId\n })\n }));\n }\n return stylesArg;\n };\n const muiStyledResolver = (styleArg, ...expressions) => {\n let transformedStyleArg = transformStyleArg(styleArg);\n const expressionsWithDefaultTheme = expressions ? expressions.map(transformStyleArg) : [];\n if (componentName && overridesResolver) {\n expressionsWithDefaultTheme.push(props => {\n const theme = resolveTheme(_extends({}, props, {\n defaultTheme,\n themeId\n }));\n if (!theme.components || !theme.components[componentName] || !theme.components[componentName].styleOverrides) {\n return null;\n }\n const styleOverrides = theme.components[componentName].styleOverrides;\n const resolvedStyleOverrides = {};\n // TODO: v7 remove iteration and use `resolveStyleArg(styleOverrides[slot])` directly\n Object.entries(styleOverrides).forEach(([slotKey, slotStyle]) => {\n resolvedStyleOverrides[slotKey] = processStyleArg(slotStyle, _extends({}, props, {\n theme\n }));\n });\n return overridesResolver(props, resolvedStyleOverrides);\n });\n }\n if (componentName && !skipVariantsResolver) {\n expressionsWithDefaultTheme.push(props => {\n var _theme$components;\n const theme = resolveTheme(_extends({}, props, {\n defaultTheme,\n themeId\n }));\n const themeVariants = theme == null || (_theme$components = theme.components) == null || (_theme$components = _theme$components[componentName]) == null ? void 0 : _theme$components.variants;\n return processStyleArg({\n variants: themeVariants\n }, _extends({}, props, {\n theme\n }));\n });\n }\n if (!skipSx) {\n expressionsWithDefaultTheme.push(systemSx);\n }\n const numOfCustomFnsApplied = expressionsWithDefaultTheme.length - expressions.length;\n if (Array.isArray(styleArg) && numOfCustomFnsApplied > 0) {\n const placeholders = new Array(numOfCustomFnsApplied).fill('');\n // If the type is array, than we need to add placeholders in the template for the overrides, variants and the sx styles.\n transformedStyleArg = [...styleArg, ...placeholders];\n transformedStyleArg.raw = [...styleArg.raw, ...placeholders];\n }\n const Component = defaultStyledResolver(transformedStyleArg, ...expressionsWithDefaultTheme);\n if (process.env.NODE_ENV !== 'production') {\n let displayName;\n if (componentName) {\n displayName = `${componentName}${capitalize(componentSlot || '')}`;\n }\n if (displayName === undefined) {\n displayName = `Styled(${getDisplayName(tag)})`;\n }\n Component.displayName = displayName;\n }\n if (tag.muiName) {\n Component.muiName = tag.muiName;\n }\n return Component;\n };\n if (defaultStyledResolver.withConfig) {\n muiStyledResolver.withConfig = defaultStyledResolver.withConfig;\n }\n return muiStyledResolver;\n };\n}","import resolveProps from '@mui/utils/resolveProps';\nexport default function getThemeProps(params) {\n const {\n theme,\n name,\n props\n } = params;\n if (!theme || !theme.components || !theme.components[name] || !theme.components[name].defaultProps) {\n return props;\n }\n return resolveProps(theme.components[name].defaultProps, props);\n}","'use client';\n\nimport getThemeProps from './getThemeProps';\nimport useTheme from '../useTheme';\nexport default function useThemeProps({\n props,\n name,\n defaultTheme,\n themeId\n}) {\n let theme = useTheme(defaultTheme);\n if (themeId) {\n theme = theme[themeId] || theme;\n }\n const mergedProps = getThemeProps({\n theme,\n name,\n props\n });\n return mergedProps;\n}","import _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\n/* eslint-disable @typescript-eslint/naming-convention */\nimport clamp from '@mui/utils/clamp';\n/**\n * Returns a number whose value is limited to the given range.\n * @param {number} value The value to be clamped\n * @param {number} min The lower boundary of the output range\n * @param {number} max The upper boundary of the output range\n * @returns {number} A number in the range [min, max]\n */\nfunction clampWrapper(value, min = 0, max = 1) {\n if (process.env.NODE_ENV !== 'production') {\n if (value < min || value > max) {\n console.error(`MUI: The value provided ${value} is out of range [${min}, ${max}].`);\n }\n }\n return clamp(value, min, max);\n}\n\n/**\n * Converts a color from CSS hex format to CSS rgb format.\n * @param {string} color - Hex color, i.e. #nnn or #nnnnnn\n * @returns {string} A CSS rgb color string\n */\nexport function hexToRgb(color) {\n color = color.slice(1);\n const re = new RegExp(`.{1,${color.length >= 6 ? 2 : 1}}`, 'g');\n let colors = color.match(re);\n if (colors && colors[0].length === 1) {\n colors = colors.map(n => n + n);\n }\n return colors ? `rgb${colors.length === 4 ? 'a' : ''}(${colors.map((n, index) => {\n return index < 3 ? parseInt(n, 16) : Math.round(parseInt(n, 16) / 255 * 1000) / 1000;\n }).join(', ')})` : '';\n}\nfunction intToHex(int) {\n const hex = int.toString(16);\n return hex.length === 1 ? `0${hex}` : hex;\n}\n\n/**\n * Returns an object with the type and values of a color.\n *\n * Note: Does not support rgb % values.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @returns {object} - A MUI color object: {type: string, values: number[]}\n */\nexport function decomposeColor(color) {\n // Idempotent\n if (color.type) {\n return color;\n }\n if (color.charAt(0) === '#') {\n return decomposeColor(hexToRgb(color));\n }\n const marker = color.indexOf('(');\n const type = color.substring(0, marker);\n if (['rgb', 'rgba', 'hsl', 'hsla', 'color'].indexOf(type) === -1) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: Unsupported \\`${color}\\` color.\nThe following formats are supported: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color().` : _formatMuiErrorMessage(9, color));\n }\n let values = color.substring(marker + 1, color.length - 1);\n let colorSpace;\n if (type === 'color') {\n values = values.split(' ');\n colorSpace = values.shift();\n if (values.length === 4 && values[3].charAt(0) === '/') {\n values[3] = values[3].slice(1);\n }\n if (['srgb', 'display-p3', 'a98-rgb', 'prophoto-rgb', 'rec-2020'].indexOf(colorSpace) === -1) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: unsupported \\`${colorSpace}\\` color space.\nThe following color spaces are supported: srgb, display-p3, a98-rgb, prophoto-rgb, rec-2020.` : _formatMuiErrorMessage(10, colorSpace));\n }\n } else {\n values = values.split(',');\n }\n values = values.map(value => parseFloat(value));\n return {\n type,\n values,\n colorSpace\n };\n}\n\n/**\n * Returns a channel created from the input color.\n *\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @returns {string} - The channel for the color, that can be used in rgba or hsla colors\n */\nexport const colorChannel = color => {\n const decomposedColor = decomposeColor(color);\n return decomposedColor.values.slice(0, 3).map((val, idx) => decomposedColor.type.indexOf('hsl') !== -1 && idx !== 0 ? `${val}%` : val).join(' ');\n};\nexport const private_safeColorChannel = (color, warning) => {\n try {\n return colorChannel(color);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n};\n\n/**\n * Converts a color object with type and values to a string.\n * @param {object} color - Decomposed color\n * @param {string} color.type - One of: 'rgb', 'rgba', 'hsl', 'hsla', 'color'\n * @param {array} color.values - [n,n,n] or [n,n,n,n]\n * @returns {string} A CSS color string\n */\nexport function recomposeColor(color) {\n const {\n type,\n colorSpace\n } = color;\n let {\n values\n } = color;\n if (type.indexOf('rgb') !== -1) {\n // Only convert the first 3 values to int (i.e. not alpha)\n values = values.map((n, i) => i < 3 ? parseInt(n, 10) : n);\n } else if (type.indexOf('hsl') !== -1) {\n values[1] = `${values[1]}%`;\n values[2] = `${values[2]}%`;\n }\n if (type.indexOf('color') !== -1) {\n values = `${colorSpace} ${values.join(' ')}`;\n } else {\n values = `${values.join(', ')}`;\n }\n return `${type}(${values})`;\n}\n\n/**\n * Converts a color from CSS rgb format to CSS hex format.\n * @param {string} color - RGB color, i.e. rgb(n, n, n)\n * @returns {string} A CSS rgb color string, i.e. #nnnnnn\n */\nexport function rgbToHex(color) {\n // Idempotent\n if (color.indexOf('#') === 0) {\n return color;\n }\n const {\n values\n } = decomposeColor(color);\n return `#${values.map((n, i) => intToHex(i === 3 ? Math.round(255 * n) : n)).join('')}`;\n}\n\n/**\n * Converts a color from hsl format to rgb format.\n * @param {string} color - HSL color values\n * @returns {string} rgb color values\n */\nexport function hslToRgb(color) {\n color = decomposeColor(color);\n const {\n values\n } = color;\n const h = values[0];\n const s = values[1] / 100;\n const l = values[2] / 100;\n const a = s * Math.min(l, 1 - l);\n const f = (n, k = (n + h / 30) % 12) => l - a * Math.max(Math.min(k - 3, 9 - k, 1), -1);\n let type = 'rgb';\n const rgb = [Math.round(f(0) * 255), Math.round(f(8) * 255), Math.round(f(4) * 255)];\n if (color.type === 'hsla') {\n type += 'a';\n rgb.push(values[3]);\n }\n return recomposeColor({\n type,\n values: rgb\n });\n}\n/**\n * The relative brightness of any point in a color space,\n * normalized to 0 for darkest black and 1 for lightest white.\n *\n * Formula: https://www.w3.org/TR/WCAG20-TECHS/G17.html#G17-tests\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @returns {number} The relative brightness of the color in the range 0 - 1\n */\nexport function getLuminance(color) {\n color = decomposeColor(color);\n let rgb = color.type === 'hsl' || color.type === 'hsla' ? decomposeColor(hslToRgb(color)).values : color.values;\n rgb = rgb.map(val => {\n if (color.type !== 'color') {\n val /= 255; // normalized\n }\n return val <= 0.03928 ? val / 12.92 : ((val + 0.055) / 1.055) ** 2.4;\n });\n\n // Truncate at 3 digits\n return Number((0.2126 * rgb[0] + 0.7152 * rgb[1] + 0.0722 * rgb[2]).toFixed(3));\n}\n\n/**\n * Calculates the contrast ratio between two colors.\n *\n * Formula: https://www.w3.org/TR/WCAG20-TECHS/G17.html#G17-tests\n * @param {string} foreground - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla()\n * @param {string} background - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla()\n * @returns {number} A contrast ratio value in the range 0 - 21.\n */\nexport function getContrastRatio(foreground, background) {\n const lumA = getLuminance(foreground);\n const lumB = getLuminance(background);\n return (Math.max(lumA, lumB) + 0.05) / (Math.min(lumA, lumB) + 0.05);\n}\n\n/**\n * Sets the absolute transparency of a color.\n * Any existing alpha values are overwritten.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} value - value to set the alpha channel to in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function alpha(color, value) {\n color = decomposeColor(color);\n value = clampWrapper(value);\n if (color.type === 'rgb' || color.type === 'hsl') {\n color.type += 'a';\n }\n if (color.type === 'color') {\n color.values[3] = `/${value}`;\n } else {\n color.values[3] = value;\n }\n return recomposeColor(color);\n}\nexport function private_safeAlpha(color, value, warning) {\n try {\n return alpha(color, value);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Darkens a color.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} coefficient - multiplier in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function darken(color, coefficient) {\n color = decomposeColor(color);\n coefficient = clampWrapper(coefficient);\n if (color.type.indexOf('hsl') !== -1) {\n color.values[2] *= 1 - coefficient;\n } else if (color.type.indexOf('rgb') !== -1 || color.type.indexOf('color') !== -1) {\n for (let i = 0; i < 3; i += 1) {\n color.values[i] *= 1 - coefficient;\n }\n }\n return recomposeColor(color);\n}\nexport function private_safeDarken(color, coefficient, warning) {\n try {\n return darken(color, coefficient);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Lightens a color.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} coefficient - multiplier in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function lighten(color, coefficient) {\n color = decomposeColor(color);\n coefficient = clampWrapper(coefficient);\n if (color.type.indexOf('hsl') !== -1) {\n color.values[2] += (100 - color.values[2]) * coefficient;\n } else if (color.type.indexOf('rgb') !== -1) {\n for (let i = 0; i < 3; i += 1) {\n color.values[i] += (255 - color.values[i]) * coefficient;\n }\n } else if (color.type.indexOf('color') !== -1) {\n for (let i = 0; i < 3; i += 1) {\n color.values[i] += (1 - color.values[i]) * coefficient;\n }\n }\n return recomposeColor(color);\n}\nexport function private_safeLighten(color, coefficient, warning) {\n try {\n return lighten(color, coefficient);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Darken or lighten a color, depending on its luminance.\n * Light colors are darkened, dark colors are lightened.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} coefficient=0.15 - multiplier in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function emphasize(color, coefficient = 0.15) {\n return getLuminance(color) > 0.5 ? darken(color, coefficient) : lighten(color, coefficient);\n}\nexport function private_safeEmphasize(color, coefficient, warning) {\n try {\n return emphasize(color, coefficient);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Blend a transparent overlay color with a background color, resulting in a single\n * RGB color.\n * @param {string} background - CSS color\n * @param {string} overlay - CSS color\n * @param {number} opacity - Opacity multiplier in the range 0 - 1\n * @param {number} [gamma=1.0] - Gamma correction factor. For gamma-correct blending, 2.2 is usual.\n */\nexport function blend(background, overlay, opacity, gamma = 1.0) {\n const blendChannel = (b, o) => Math.round((b ** (1 / gamma) * (1 - opacity) + o ** (1 / gamma) * opacity) ** gamma);\n const backgroundColor = decomposeColor(background);\n const overlayColor = decomposeColor(overlay);\n const rgb = [blendChannel(backgroundColor.values[0], overlayColor.values[0]), blendChannel(backgroundColor.values[1], overlayColor.values[1]), blendChannel(backgroundColor.values[2], overlayColor.values[2])];\n return recomposeColor({\n type: 'rgb',\n values: rgb\n });\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nexport default function createMixins(breakpoints, mixins) {\n return _extends({\n toolbar: {\n minHeight: 56,\n [breakpoints.up('xs')]: {\n '@media (orientation: landscape)': {\n minHeight: 48\n }\n },\n [breakpoints.up('sm')]: {\n minHeight: 64\n }\n }\n }, mixins);\n}","const common = {\n black: '#000',\n white: '#fff'\n};\nexport default common;","const grey = {\n 50: '#fafafa',\n 100: '#f5f5f5',\n 200: '#eeeeee',\n 300: '#e0e0e0',\n 400: '#bdbdbd',\n 500: '#9e9e9e',\n 600: '#757575',\n 700: '#616161',\n 800: '#424242',\n 900: '#212121',\n A100: '#f5f5f5',\n A200: '#eeeeee',\n A400: '#bdbdbd',\n A700: '#616161'\n};\nexport default grey;","const purple = {\n 50: '#f3e5f5',\n 100: '#e1bee7',\n 200: '#ce93d8',\n 300: '#ba68c8',\n 400: '#ab47bc',\n 500: '#9c27b0',\n 600: '#8e24aa',\n 700: '#7b1fa2',\n 800: '#6a1b9a',\n 900: '#4a148c',\n A100: '#ea80fc',\n A200: '#e040fb',\n A400: '#d500f9',\n A700: '#aa00ff'\n};\nexport default purple;","const red = {\n 50: '#ffebee',\n 100: '#ffcdd2',\n 200: '#ef9a9a',\n 300: '#e57373',\n 400: '#ef5350',\n 500: '#f44336',\n 600: '#e53935',\n 700: '#d32f2f',\n 800: '#c62828',\n 900: '#b71c1c',\n A100: '#ff8a80',\n A200: '#ff5252',\n A400: '#ff1744',\n A700: '#d50000'\n};\nexport default red;","const orange = {\n 50: '#fff3e0',\n 100: '#ffe0b2',\n 200: '#ffcc80',\n 300: '#ffb74d',\n 400: '#ffa726',\n 500: '#ff9800',\n 600: '#fb8c00',\n 700: '#f57c00',\n 800: '#ef6c00',\n 900: '#e65100',\n A100: '#ffd180',\n A200: '#ffab40',\n A400: '#ff9100',\n A700: '#ff6d00'\n};\nexport default orange;","const blue = {\n 50: '#e3f2fd',\n 100: '#bbdefb',\n 200: '#90caf9',\n 300: '#64b5f6',\n 400: '#42a5f5',\n 500: '#2196f3',\n 600: '#1e88e5',\n 700: '#1976d2',\n 800: '#1565c0',\n 900: '#0d47a1',\n A100: '#82b1ff',\n A200: '#448aff',\n A400: '#2979ff',\n A700: '#2962ff'\n};\nexport default blue;","const lightBlue = {\n 50: '#e1f5fe',\n 100: '#b3e5fc',\n 200: '#81d4fa',\n 300: '#4fc3f7',\n 400: '#29b6f6',\n 500: '#03a9f4',\n 600: '#039be5',\n 700: '#0288d1',\n 800: '#0277bd',\n 900: '#01579b',\n A100: '#80d8ff',\n A200: '#40c4ff',\n A400: '#00b0ff',\n A700: '#0091ea'\n};\nexport default lightBlue;","const green = {\n 50: '#e8f5e9',\n 100: '#c8e6c9',\n 200: '#a5d6a7',\n 300: '#81c784',\n 400: '#66bb6a',\n 500: '#4caf50',\n 600: '#43a047',\n 700: '#388e3c',\n 800: '#2e7d32',\n 900: '#1b5e20',\n A100: '#b9f6ca',\n A200: '#69f0ae',\n A400: '#00e676',\n A700: '#00c853'\n};\nexport default green;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\nconst _excluded = [\"mode\", \"contrastThreshold\", \"tonalOffset\"];\nimport { deepmerge } from '@mui/utils';\nimport { darken, getContrastRatio, lighten } from '@mui/system';\nimport common from '../colors/common';\nimport grey from '../colors/grey';\nimport purple from '../colors/purple';\nimport red from '../colors/red';\nimport orange from '../colors/orange';\nimport blue from '../colors/blue';\nimport lightBlue from '../colors/lightBlue';\nimport green from '../colors/green';\nexport const light = {\n // The colors used to style the text.\n text: {\n // The most important text.\n primary: 'rgba(0, 0, 0, 0.87)',\n // Secondary text.\n secondary: 'rgba(0, 0, 0, 0.6)',\n // Disabled text have even lower visual prominence.\n disabled: 'rgba(0, 0, 0, 0.38)'\n },\n // The color used to divide different elements.\n divider: 'rgba(0, 0, 0, 0.12)',\n // The background colors used to style the surfaces.\n // Consistency between these values is important.\n background: {\n paper: common.white,\n default: common.white\n },\n // The colors used to style the action elements.\n action: {\n // The color of an active action like an icon button.\n active: 'rgba(0, 0, 0, 0.54)',\n // The color of an hovered action.\n hover: 'rgba(0, 0, 0, 0.04)',\n hoverOpacity: 0.04,\n // The color of a selected action.\n selected: 'rgba(0, 0, 0, 0.08)',\n selectedOpacity: 0.08,\n // The color of a disabled action.\n disabled: 'rgba(0, 0, 0, 0.26)',\n // The background color of a disabled action.\n disabledBackground: 'rgba(0, 0, 0, 0.12)',\n disabledOpacity: 0.38,\n focus: 'rgba(0, 0, 0, 0.12)',\n focusOpacity: 0.12,\n activatedOpacity: 0.12\n }\n};\nexport const dark = {\n text: {\n primary: common.white,\n secondary: 'rgba(255, 255, 255, 0.7)',\n disabled: 'rgba(255, 255, 255, 0.5)',\n icon: 'rgba(255, 255, 255, 0.5)'\n },\n divider: 'rgba(255, 255, 255, 0.12)',\n background: {\n paper: '#121212',\n default: '#121212'\n },\n action: {\n active: common.white,\n hover: 'rgba(255, 255, 255, 0.08)',\n hoverOpacity: 0.08,\n selected: 'rgba(255, 255, 255, 0.16)',\n selectedOpacity: 0.16,\n disabled: 'rgba(255, 255, 255, 0.3)',\n disabledBackground: 'rgba(255, 255, 255, 0.12)',\n disabledOpacity: 0.38,\n focus: 'rgba(255, 255, 255, 0.12)',\n focusOpacity: 0.12,\n activatedOpacity: 0.24\n }\n};\nfunction addLightOrDark(intent, direction, shade, tonalOffset) {\n const tonalOffsetLight = tonalOffset.light || tonalOffset;\n const tonalOffsetDark = tonalOffset.dark || tonalOffset * 1.5;\n if (!intent[direction]) {\n if (intent.hasOwnProperty(shade)) {\n intent[direction] = intent[shade];\n } else if (direction === 'light') {\n intent.light = lighten(intent.main, tonalOffsetLight);\n } else if (direction === 'dark') {\n intent.dark = darken(intent.main, tonalOffsetDark);\n }\n }\n}\nfunction getDefaultPrimary(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: blue[200],\n light: blue[50],\n dark: blue[400]\n };\n }\n return {\n main: blue[700],\n light: blue[400],\n dark: blue[800]\n };\n}\nfunction getDefaultSecondary(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: purple[200],\n light: purple[50],\n dark: purple[400]\n };\n }\n return {\n main: purple[500],\n light: purple[300],\n dark: purple[700]\n };\n}\nfunction getDefaultError(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: red[500],\n light: red[300],\n dark: red[700]\n };\n }\n return {\n main: red[700],\n light: red[400],\n dark: red[800]\n };\n}\nfunction getDefaultInfo(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: lightBlue[400],\n light: lightBlue[300],\n dark: lightBlue[700]\n };\n }\n return {\n main: lightBlue[700],\n light: lightBlue[500],\n dark: lightBlue[900]\n };\n}\nfunction getDefaultSuccess(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: green[400],\n light: green[300],\n dark: green[700]\n };\n }\n return {\n main: green[800],\n light: green[500],\n dark: green[900]\n };\n}\nfunction getDefaultWarning(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: orange[400],\n light: orange[300],\n dark: orange[700]\n };\n }\n return {\n main: '#ed6c02',\n // closest to orange[800] that pass 3:1.\n light: orange[500],\n dark: orange[900]\n };\n}\nexport default function createPalette(palette) {\n const {\n mode = 'light',\n contrastThreshold = 3,\n tonalOffset = 0.2\n } = palette,\n other = _objectWithoutPropertiesLoose(palette, _excluded);\n const primary = palette.primary || getDefaultPrimary(mode);\n const secondary = palette.secondary || getDefaultSecondary(mode);\n const error = palette.error || getDefaultError(mode);\n const info = palette.info || getDefaultInfo(mode);\n const success = palette.success || getDefaultSuccess(mode);\n const warning = palette.warning || getDefaultWarning(mode);\n\n // Use the same logic as\n // Bootstrap: https://github.com/twbs/bootstrap/blob/1d6e3710dd447de1a200f29e8fa521f8a0908f70/scss/_functions.scss#L59\n // and material-components-web https://github.com/material-components/material-components-web/blob/ac46b8863c4dab9fc22c4c662dc6bd1b65dd652f/packages/mdc-theme/_functions.scss#L54\n function getContrastText(background) {\n const contrastText = getContrastRatio(background, dark.text.primary) >= contrastThreshold ? dark.text.primary : light.text.primary;\n if (process.env.NODE_ENV !== 'production') {\n const contrast = getContrastRatio(background, contrastText);\n if (contrast < 3) {\n console.error([`MUI: The contrast ratio of ${contrast}:1 for ${contrastText} on ${background}`, 'falls below the WCAG recommended absolute minimum contrast ratio of 3:1.', 'https://www.w3.org/TR/2008/REC-WCAG20-20081211/#visual-audio-contrast-contrast'].join('\\n'));\n }\n }\n return contrastText;\n }\n const augmentColor = ({\n color,\n name,\n mainShade = 500,\n lightShade = 300,\n darkShade = 700\n }) => {\n color = _extends({}, color);\n if (!color.main && color[mainShade]) {\n color.main = color[mainShade];\n }\n if (!color.hasOwnProperty('main')) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: The color${name ? ` (${name})` : ''} provided to augmentColor(color) is invalid.\nThe color object needs to have a \\`main\\` property or a \\`${mainShade}\\` property.` : _formatMuiErrorMessage(11, name ? ` (${name})` : '', mainShade));\n }\n if (typeof color.main !== 'string') {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: The color${name ? ` (${name})` : ''} provided to augmentColor(color) is invalid.\n\\`color.main\\` should be a string, but \\`${JSON.stringify(color.main)}\\` was provided instead.\n\nDid you intend to use one of the following approaches?\n\nimport { green } from \"@mui/material/colors\";\n\nconst theme1 = createTheme({ palette: {\n primary: green,\n} });\n\nconst theme2 = createTheme({ palette: {\n primary: { main: green[500] },\n} });` : _formatMuiErrorMessage(12, name ? ` (${name})` : '', JSON.stringify(color.main)));\n }\n addLightOrDark(color, 'light', lightShade, tonalOffset);\n addLightOrDark(color, 'dark', darkShade, tonalOffset);\n if (!color.contrastText) {\n color.contrastText = getContrastText(color.main);\n }\n return color;\n };\n const modes = {\n dark,\n light\n };\n if (process.env.NODE_ENV !== 'production') {\n if (!modes[mode]) {\n console.error(`MUI: The palette mode \\`${mode}\\` is not supported.`);\n }\n }\n const paletteOutput = deepmerge(_extends({\n // A collection of common colors.\n common: _extends({}, common),\n // prevent mutable object.\n // The palette mode, can be light or dark.\n mode,\n // The colors used to represent primary interface elements for a user.\n primary: augmentColor({\n color: primary,\n name: 'primary'\n }),\n // The colors used to represent secondary interface elements for a user.\n secondary: augmentColor({\n color: secondary,\n name: 'secondary',\n mainShade: 'A400',\n lightShade: 'A200',\n darkShade: 'A700'\n }),\n // The colors used to represent interface elements that the user should be made aware of.\n error: augmentColor({\n color: error,\n name: 'error'\n }),\n // The colors used to represent potentially dangerous actions or important messages.\n warning: augmentColor({\n color: warning,\n name: 'warning'\n }),\n // The colors used to present information to the user that is neutral and not necessarily important.\n info: augmentColor({\n color: info,\n name: 'info'\n }),\n // The colors used to indicate the successful completion of an action that user triggered.\n success: augmentColor({\n color: success,\n name: 'success'\n }),\n // The grey colors.\n grey,\n // Used by `getContrastText()` to maximize the contrast between\n // the background and the text.\n contrastThreshold,\n // Takes a background color and returns the text color that maximizes the contrast.\n getContrastText,\n // Generate a rich color object.\n augmentColor,\n // Used by the functions below to shift a color's luminance by approximately\n // two indexes within its tonal palette.\n // E.g., shift from Red 500 to Red 300 or Red 700.\n tonalOffset\n }, modes[mode]), other);\n return paletteOutput;\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"fontFamily\", \"fontSize\", \"fontWeightLight\", \"fontWeightRegular\", \"fontWeightMedium\", \"fontWeightBold\", \"htmlFontSize\", \"allVariants\", \"pxToRem\"];\nimport { deepmerge } from '@mui/utils';\nfunction round(value) {\n return Math.round(value * 1e5) / 1e5;\n}\nconst caseAllCaps = {\n textTransform: 'uppercase'\n};\nconst defaultFontFamily = '\"Roboto\", \"Helvetica\", \"Arial\", sans-serif';\n\n/**\n * @see @link{https://m2.material.io/design/typography/the-type-system.html}\n * @see @link{https://m2.material.io/design/typography/understanding-typography.html}\n */\nexport default function createTypography(palette, typography) {\n const _ref = typeof typography === 'function' ? typography(palette) : typography,\n {\n fontFamily = defaultFontFamily,\n // The default font size of the Material Specification.\n fontSize = 14,\n // px\n fontWeightLight = 300,\n fontWeightRegular = 400,\n fontWeightMedium = 500,\n fontWeightBold = 700,\n // Tell MUI what's the font-size on the html element.\n // 16px is the default font-size used by browsers.\n htmlFontSize = 16,\n // Apply the CSS properties to all the variants.\n allVariants,\n pxToRem: pxToRem2\n } = _ref,\n other = _objectWithoutPropertiesLoose(_ref, _excluded);\n if (process.env.NODE_ENV !== 'production') {\n if (typeof fontSize !== 'number') {\n console.error('MUI: `fontSize` is required to be a number.');\n }\n if (typeof htmlFontSize !== 'number') {\n console.error('MUI: `htmlFontSize` is required to be a number.');\n }\n }\n const coef = fontSize / 14;\n const pxToRem = pxToRem2 || (size => `${size / htmlFontSize * coef}rem`);\n const buildVariant = (fontWeight, size, lineHeight, letterSpacing, casing) => _extends({\n fontFamily,\n fontWeight,\n fontSize: pxToRem(size),\n // Unitless following https://meyerweb.com/eric/thoughts/2006/02/08/unitless-line-heights/\n lineHeight\n }, fontFamily === defaultFontFamily ? {\n letterSpacing: `${round(letterSpacing / size)}em`\n } : {}, casing, allVariants);\n const variants = {\n h1: buildVariant(fontWeightLight, 96, 1.167, -1.5),\n h2: buildVariant(fontWeightLight, 60, 1.2, -0.5),\n h3: buildVariant(fontWeightRegular, 48, 1.167, 0),\n h4: buildVariant(fontWeightRegular, 34, 1.235, 0.25),\n h5: buildVariant(fontWeightRegular, 24, 1.334, 0),\n h6: buildVariant(fontWeightMedium, 20, 1.6, 0.15),\n subtitle1: buildVariant(fontWeightRegular, 16, 1.75, 0.15),\n subtitle2: buildVariant(fontWeightMedium, 14, 1.57, 0.1),\n body1: buildVariant(fontWeightRegular, 16, 1.5, 0.15),\n body2: buildVariant(fontWeightRegular, 14, 1.43, 0.15),\n button: buildVariant(fontWeightMedium, 14, 1.75, 0.4, caseAllCaps),\n caption: buildVariant(fontWeightRegular, 12, 1.66, 0.4),\n overline: buildVariant(fontWeightRegular, 12, 2.66, 1, caseAllCaps),\n // TODO v6: Remove handling of 'inherit' variant from the theme as it is already handled in Material UI's Typography component. Also, remember to remove the associated types.\n inherit: {\n fontFamily: 'inherit',\n fontWeight: 'inherit',\n fontSize: 'inherit',\n lineHeight: 'inherit',\n letterSpacing: 'inherit'\n }\n };\n return deepmerge(_extends({\n htmlFontSize,\n pxToRem,\n fontFamily,\n fontSize,\n fontWeightLight,\n fontWeightRegular,\n fontWeightMedium,\n fontWeightBold\n }, variants), other, {\n clone: false // No need to clone deep\n });\n}","const shadowKeyUmbraOpacity = 0.2;\nconst shadowKeyPenumbraOpacity = 0.14;\nconst shadowAmbientShadowOpacity = 0.12;\nfunction createShadow(...px) {\n return [`${px[0]}px ${px[1]}px ${px[2]}px ${px[3]}px rgba(0,0,0,${shadowKeyUmbraOpacity})`, `${px[4]}px ${px[5]}px ${px[6]}px ${px[7]}px rgba(0,0,0,${shadowKeyPenumbraOpacity})`, `${px[8]}px ${px[9]}px ${px[10]}px ${px[11]}px rgba(0,0,0,${shadowAmbientShadowOpacity})`].join(',');\n}\n\n// Values from https://github.com/material-components/material-components-web/blob/be8747f94574669cb5e7add1a7c54fa41a89cec7/packages/mdc-elevation/_variables.scss\nconst shadows = ['none', createShadow(0, 2, 1, -1, 0, 1, 1, 0, 0, 1, 3, 0), createShadow(0, 3, 1, -2, 0, 2, 2, 0, 0, 1, 5, 0), createShadow(0, 3, 3, -2, 0, 3, 4, 0, 0, 1, 8, 0), createShadow(0, 2, 4, -1, 0, 4, 5, 0, 0, 1, 10, 0), createShadow(0, 3, 5, -1, 0, 5, 8, 0, 0, 1, 14, 0), createShadow(0, 3, 5, -1, 0, 6, 10, 0, 0, 1, 18, 0), createShadow(0, 4, 5, -2, 0, 7, 10, 1, 0, 2, 16, 1), createShadow(0, 5, 5, -3, 0, 8, 10, 1, 0, 3, 14, 2), createShadow(0, 5, 6, -3, 0, 9, 12, 1, 0, 3, 16, 2), createShadow(0, 6, 6, -3, 0, 10, 14, 1, 0, 4, 18, 3), createShadow(0, 6, 7, -4, 0, 11, 15, 1, 0, 4, 20, 3), createShadow(0, 7, 8, -4, 0, 12, 17, 2, 0, 5, 22, 4), createShadow(0, 7, 8, -4, 0, 13, 19, 2, 0, 5, 24, 4), createShadow(0, 7, 9, -4, 0, 14, 21, 2, 0, 5, 26, 4), createShadow(0, 8, 9, -5, 0, 15, 22, 2, 0, 6, 28, 5), createShadow(0, 8, 10, -5, 0, 16, 24, 2, 0, 6, 30, 5), createShadow(0, 8, 11, -5, 0, 17, 26, 2, 0, 6, 32, 5), createShadow(0, 9, 11, -5, 0, 18, 28, 2, 0, 7, 34, 6), createShadow(0, 9, 12, -6, 0, 19, 29, 2, 0, 7, 36, 6), createShadow(0, 10, 13, -6, 0, 20, 31, 3, 0, 8, 38, 7), createShadow(0, 10, 13, -6, 0, 21, 33, 3, 0, 8, 40, 7), createShadow(0, 10, 14, -6, 0, 22, 35, 3, 0, 8, 42, 7), createShadow(0, 11, 14, -7, 0, 23, 36, 3, 0, 9, 44, 8), createShadow(0, 11, 15, -7, 0, 24, 38, 3, 0, 9, 46, 8)];\nexport default shadows;","import _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nconst _excluded = [\"duration\", \"easing\", \"delay\"];\n// Follow https://material.google.com/motion/duration-easing.html#duration-easing-natural-easing-curves\n// to learn the context in which each easing should be used.\nexport const easing = {\n // This is the most common easing curve.\n easeInOut: 'cubic-bezier(0.4, 0, 0.2, 1)',\n // Objects enter the screen at full velocity from off-screen and\n // slowly decelerate to a resting point.\n easeOut: 'cubic-bezier(0.0, 0, 0.2, 1)',\n // Objects leave the screen at full velocity. They do not decelerate when off-screen.\n easeIn: 'cubic-bezier(0.4, 0, 1, 1)',\n // The sharp curve is used by objects that may return to the screen at any time.\n sharp: 'cubic-bezier(0.4, 0, 0.6, 1)'\n};\n\n// Follow https://m2.material.io/guidelines/motion/duration-easing.html#duration-easing-common-durations\n// to learn when use what timing\nexport const duration = {\n shortest: 150,\n shorter: 200,\n short: 250,\n // most basic recommended timing\n standard: 300,\n // this is to be used in complex animations\n complex: 375,\n // recommended when something is entering screen\n enteringScreen: 225,\n // recommended when something is leaving screen\n leavingScreen: 195\n};\nfunction formatMs(milliseconds) {\n return `${Math.round(milliseconds)}ms`;\n}\nfunction getAutoHeightDuration(height) {\n if (!height) {\n return 0;\n }\n const constant = height / 36;\n\n // https://www.wolframalpha.com/input/?i=(4+%2B+15+*+(x+%2F+36+)+**+0.25+%2B+(x+%2F+36)+%2F+5)+*+10\n return Math.round((4 + 15 * constant ** 0.25 + constant / 5) * 10);\n}\nexport default function createTransitions(inputTransitions) {\n const mergedEasing = _extends({}, easing, inputTransitions.easing);\n const mergedDuration = _extends({}, duration, inputTransitions.duration);\n const create = (props = ['all'], options = {}) => {\n const {\n duration: durationOption = mergedDuration.standard,\n easing: easingOption = mergedEasing.easeInOut,\n delay = 0\n } = options,\n other = _objectWithoutPropertiesLoose(options, _excluded);\n if (process.env.NODE_ENV !== 'production') {\n const isString = value => typeof value === 'string';\n // IE11 support, replace with Number.isNaN\n // eslint-disable-next-line no-restricted-globals\n const isNumber = value => !isNaN(parseFloat(value));\n if (!isString(props) && !Array.isArray(props)) {\n console.error('MUI: Argument \"props\" must be a string or Array.');\n }\n if (!isNumber(durationOption) && !isString(durationOption)) {\n console.error(`MUI: Argument \"duration\" must be a number or a string but found ${durationOption}.`);\n }\n if (!isString(easingOption)) {\n console.error('MUI: Argument \"easing\" must be a string.');\n }\n if (!isNumber(delay) && !isString(delay)) {\n console.error('MUI: Argument \"delay\" must be a number or a string.');\n }\n if (typeof options !== 'object') {\n console.error(['MUI: Secong argument of transition.create must be an object.', \"Arguments should be either `create('prop1', options)` or `create(['prop1', 'prop2'], options)`\"].join('\\n'));\n }\n if (Object.keys(other).length !== 0) {\n console.error(`MUI: Unrecognized argument(s) [${Object.keys(other).join(',')}].`);\n }\n }\n return (Array.isArray(props) ? props : [props]).map(animatedProp => `${animatedProp} ${typeof durationOption === 'string' ? durationOption : formatMs(durationOption)} ${easingOption} ${typeof delay === 'string' ? delay : formatMs(delay)}`).join(',');\n };\n return _extends({\n getAutoHeightDuration,\n create\n }, inputTransitions, {\n easing: mergedEasing,\n duration: mergedDuration\n });\n}","// We need to centralize the zIndex definitions as they work\n// like global values in the browser.\nconst zIndex = {\n mobileStepper: 1000,\n fab: 1050,\n speedDial: 1050,\n appBar: 1100,\n drawer: 1200,\n modal: 1300,\n snackbar: 1400,\n tooltip: 1500\n};\nexport default zIndex;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\nconst _excluded = [\"breakpoints\", \"mixins\", \"spacing\", \"palette\", \"transitions\", \"typography\", \"shape\"];\nimport { deepmerge } from '@mui/utils';\nimport { createTheme as systemCreateTheme, unstable_defaultSxConfig as defaultSxConfig, unstable_styleFunctionSx as styleFunctionSx } from '@mui/system';\nimport generateUtilityClass from '@mui/utils/generateUtilityClass';\nimport createMixins from './createMixins';\nimport createPalette from './createPalette';\nimport createTypography from './createTypography';\nimport shadows from './shadows';\nimport createTransitions from './createTransitions';\nimport zIndex from './zIndex';\nfunction createTheme(options = {}, ...args) {\n const {\n mixins: mixinsInput = {},\n palette: paletteInput = {},\n transitions: transitionsInput = {},\n typography: typographyInput = {}\n } = options,\n other = _objectWithoutPropertiesLoose(options, _excluded);\n if (options.vars) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: \\`vars\\` is a private field used for CSS variables support.\nPlease use another name.` : _formatMuiErrorMessage(18));\n }\n const palette = createPalette(paletteInput);\n const systemTheme = systemCreateTheme(options);\n let muiTheme = deepmerge(systemTheme, {\n mixins: createMixins(systemTheme.breakpoints, mixinsInput),\n palette,\n // Don't use [...shadows] until you've verified its transpiled code is not invoking the iterator protocol.\n shadows: shadows.slice(),\n typography: createTypography(palette, typographyInput),\n transitions: createTransitions(transitionsInput),\n zIndex: _extends({}, zIndex)\n });\n muiTheme = deepmerge(muiTheme, other);\n muiTheme = args.reduce((acc, argument) => deepmerge(acc, argument), muiTheme);\n if (process.env.NODE_ENV !== 'production') {\n // TODO v6: Refactor to use globalStateClassesMapping from @mui/utils once `readOnly` state class is used in Rating component.\n const stateClasses = ['active', 'checked', 'completed', 'disabled', 'error', 'expanded', 'focused', 'focusVisible', 'required', 'selected'];\n const traverse = (node, component) => {\n let key;\n\n // eslint-disable-next-line guard-for-in, no-restricted-syntax\n for (key in node) {\n const child = node[key];\n if (stateClasses.indexOf(key) !== -1 && Object.keys(child).length > 0) {\n if (process.env.NODE_ENV !== 'production') {\n const stateClass = generateUtilityClass('', key);\n console.error([`MUI: The \\`${component}\\` component increases ` + `the CSS specificity of the \\`${key}\\` internal state.`, 'You can not override it like this: ', JSON.stringify(node, null, 2), '', `Instead, you need to use the '&.${stateClass}' syntax:`, JSON.stringify({\n root: {\n [`&.${stateClass}`]: child\n }\n }, null, 2), '', 'https://mui.com/r/state-classes-guide'].join('\\n'));\n }\n // Remove the style to prevent global conflicts.\n node[key] = {};\n }\n }\n };\n Object.keys(muiTheme.components).forEach(component => {\n const styleOverrides = muiTheme.components[component].styleOverrides;\n if (styleOverrides && component.indexOf('Mui') === 0) {\n traverse(styleOverrides, component);\n }\n });\n }\n muiTheme.unstable_sxConfig = _extends({}, defaultSxConfig, other == null ? void 0 : other.unstable_sxConfig);\n muiTheme.unstable_sx = function sx(props) {\n return styleFunctionSx({\n sx: props,\n theme: this\n });\n };\n return muiTheme;\n}\nlet warnedOnce = false;\nexport function createMuiTheme(...args) {\n if (process.env.NODE_ENV !== 'production') {\n if (!warnedOnce) {\n warnedOnce = true;\n console.error(['MUI: the createMuiTheme function was renamed to createTheme.', '', \"You should use `import { createTheme } from '@mui/material/styles'`\"].join('\\n'));\n }\n }\n return createTheme(...args);\n}\nexport default createTheme;","'use client';\n\nimport createTheme from './createTheme';\nconst defaultTheme = createTheme();\nexport default defaultTheme;","export default '$$material';","'use client';\n\nimport { useThemeProps as systemUseThemeProps } from '@mui/system';\nimport defaultTheme from './defaultTheme';\nimport THEME_ID from './identifier';\nexport default function useThemeProps({\n props,\n name\n}) {\n return systemUseThemeProps({\n props,\n name,\n defaultTheme,\n themeId: THEME_ID\n });\n}","'use client';\n\nimport { createStyled, shouldForwardProp } from '@mui/system';\nimport defaultTheme from './defaultTheme';\nimport THEME_ID from './identifier';\nexport const rootShouldForwardProp = prop => shouldForwardProp(prop) && prop !== 'classes';\nexport const slotShouldForwardProp = shouldForwardProp;\nconst styled = createStyled({\n themeId: THEME_ID,\n defaultTheme,\n rootShouldForwardProp\n});\nexport default styled;","import generateUtilityClasses from '@mui/utils/generateUtilityClasses';\nimport generateUtilityClass from '@mui/utils/generateUtilityClass';\nexport function getSvgIconUtilityClass(slot) {\n return generateUtilityClass('MuiSvgIcon', slot);\n}\nconst svgIconClasses = generateUtilityClasses('MuiSvgIcon', ['root', 'colorPrimary', 'colorSecondary', 'colorAction', 'colorError', 'colorDisabled', 'fontSizeInherit', 'fontSizeSmall', 'fontSizeMedium', 'fontSizeLarge']);\nexport default svgIconClasses;","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"children\", \"className\", \"color\", \"component\", \"fontSize\", \"htmlColor\", \"inheritViewBox\", \"titleAccess\", \"viewBox\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport clsx from 'clsx';\nimport { unstable_composeClasses as composeClasses } from '@mui/base/composeClasses';\nimport capitalize from '../utils/capitalize';\nimport useThemeProps from '../styles/useThemeProps';\nimport styled from '../styles/styled';\nimport { getSvgIconUtilityClass } from './svgIconClasses';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nimport { jsxs as _jsxs } from \"react/jsx-runtime\";\nconst useUtilityClasses = ownerState => {\n const {\n color,\n fontSize,\n classes\n } = ownerState;\n const slots = {\n root: ['root', color !== 'inherit' && `color${capitalize(color)}`, `fontSize${capitalize(fontSize)}`]\n };\n return composeClasses(slots, getSvgIconUtilityClass, classes);\n};\nconst SvgIconRoot = styled('svg', {\n name: 'MuiSvgIcon',\n slot: 'Root',\n overridesResolver: (props, styles) => {\n const {\n ownerState\n } = props;\n return [styles.root, ownerState.color !== 'inherit' && styles[`color${capitalize(ownerState.color)}`], styles[`fontSize${capitalize(ownerState.fontSize)}`]];\n }\n})(({\n theme,\n ownerState\n}) => {\n var _theme$transitions, _theme$transitions$cr, _theme$transitions2, _theme$typography, _theme$typography$pxT, _theme$typography2, _theme$typography2$px, _theme$typography3, _theme$typography3$px, _palette$ownerState$c, _palette, _palette2, _palette3;\n return {\n userSelect: 'none',\n width: '1em',\n height: '1em',\n display: 'inline-block',\n // the will define the property that has `currentColor`\n // e.g. heroicons uses fill=\"none\" and stroke=\"currentColor\"\n fill: ownerState.hasSvgAsChild ? undefined : 'currentColor',\n flexShrink: 0,\n transition: (_theme$transitions = theme.transitions) == null || (_theme$transitions$cr = _theme$transitions.create) == null ? void 0 : _theme$transitions$cr.call(_theme$transitions, 'fill', {\n duration: (_theme$transitions2 = theme.transitions) == null || (_theme$transitions2 = _theme$transitions2.duration) == null ? void 0 : _theme$transitions2.shorter\n }),\n fontSize: {\n inherit: 'inherit',\n small: ((_theme$typography = theme.typography) == null || (_theme$typography$pxT = _theme$typography.pxToRem) == null ? void 0 : _theme$typography$pxT.call(_theme$typography, 20)) || '1.25rem',\n medium: ((_theme$typography2 = theme.typography) == null || (_theme$typography2$px = _theme$typography2.pxToRem) == null ? void 0 : _theme$typography2$px.call(_theme$typography2, 24)) || '1.5rem',\n large: ((_theme$typography3 = theme.typography) == null || (_theme$typography3$px = _theme$typography3.pxToRem) == null ? void 0 : _theme$typography3$px.call(_theme$typography3, 35)) || '2.1875rem'\n }[ownerState.fontSize],\n // TODO v5 deprecate, v6 remove for sx\n color: (_palette$ownerState$c = (_palette = (theme.vars || theme).palette) == null || (_palette = _palette[ownerState.color]) == null ? void 0 : _palette.main) != null ? _palette$ownerState$c : {\n action: (_palette2 = (theme.vars || theme).palette) == null || (_palette2 = _palette2.action) == null ? void 0 : _palette2.active,\n disabled: (_palette3 = (theme.vars || theme).palette) == null || (_palette3 = _palette3.action) == null ? void 0 : _palette3.disabled,\n inherit: undefined\n }[ownerState.color]\n };\n});\nconst SvgIcon = /*#__PURE__*/React.forwardRef(function SvgIcon(inProps, ref) {\n const props = useThemeProps({\n props: inProps,\n name: 'MuiSvgIcon'\n });\n const {\n children,\n className,\n color = 'inherit',\n component = 'svg',\n fontSize = 'medium',\n htmlColor,\n inheritViewBox = false,\n titleAccess,\n viewBox = '0 0 24 24'\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const hasSvgAsChild = /*#__PURE__*/React.isValidElement(children) && children.type === 'svg';\n const ownerState = _extends({}, props, {\n color,\n component,\n fontSize,\n instanceFontSize: inProps.fontSize,\n inheritViewBox,\n viewBox,\n hasSvgAsChild\n });\n const more = {};\n if (!inheritViewBox) {\n more.viewBox = viewBox;\n }\n const classes = useUtilityClasses(ownerState);\n return /*#__PURE__*/_jsxs(SvgIconRoot, _extends({\n as: component,\n className: clsx(classes.root, className),\n focusable: \"false\",\n color: htmlColor,\n \"aria-hidden\": titleAccess ? undefined : true,\n role: titleAccess ? 'img' : undefined,\n ref: ref\n }, more, other, hasSvgAsChild && children.props, {\n ownerState: ownerState,\n children: [hasSvgAsChild ? children.props.children : children, titleAccess ? /*#__PURE__*/_jsx(\"title\", {\n children: titleAccess\n }) : null]\n }));\n});\nprocess.env.NODE_ENV !== \"production\" ? SvgIcon.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the d.ts file and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * Node passed into the SVG element.\n */\n children: PropTypes.node,\n /**\n * Override or extend the styles applied to the component.\n */\n classes: PropTypes.object,\n /**\n * @ignore\n */\n className: PropTypes.string,\n /**\n * The color of the component.\n * It supports both default and custom theme colors, which can be added as shown in the\n * [palette customization guide](https://mui.com/material-ui/customization/palette/#custom-colors).\n * You can use the `htmlColor` prop to apply a color attribute to the SVG element.\n * @default 'inherit'\n */\n color: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.oneOf(['inherit', 'action', 'disabled', 'primary', 'secondary', 'error', 'info', 'success', 'warning']), PropTypes.string]),\n /**\n * The component used for the root node.\n * Either a string to use a HTML element or a component.\n */\n component: PropTypes.elementType,\n /**\n * The fontSize applied to the icon. Defaults to 24px, but can be configure to inherit font size.\n * @default 'medium'\n */\n fontSize: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.oneOf(['inherit', 'large', 'medium', 'small']), PropTypes.string]),\n /**\n * Applies a color attribute to the SVG element.\n */\n htmlColor: PropTypes.string,\n /**\n * If `true`, the root node will inherit the custom `component`'s viewBox and the `viewBox`\n * prop will be ignored.\n * Useful when you want to reference a custom `component` and have `SvgIcon` pass that\n * `component`'s viewBox to the root node.\n * @default false\n */\n inheritViewBox: PropTypes.bool,\n /**\n * The shape-rendering attribute. The behavior of the different options is described on the\n * [MDN Web Docs](https://developer.mozilla.org/en-US/docs/Web/SVG/Attribute/shape-rendering).\n * If you are having issues with blurry icons you should investigate this prop.\n */\n shapeRendering: PropTypes.string,\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Provides a human-readable title for the element that contains it.\n * https://www.w3.org/TR/SVG-access/#Equivalent\n */\n titleAccess: PropTypes.string,\n /**\n * Allows you to redefine what the coordinates without units mean inside an SVG element.\n * For example, if the SVG element is 500 (width) by 200 (height),\n * and you pass viewBox=\"0 0 50 20\",\n * this means that the coordinates inside the SVG will go from the top left corner (0,0)\n * to bottom right (50,20) and each unit will be worth 10px.\n * @default '0 0 24 24'\n */\n viewBox: PropTypes.string\n} : void 0;\nSvgIcon.muiName = 'SvgIcon';\nexport default SvgIcon;","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport * as React from 'react';\nimport SvgIcon from '../SvgIcon';\n\n/**\n * Private module reserved for @mui packages.\n */\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nexport default function createSvgIcon(path, displayName) {\n function Component(props, ref) {\n return /*#__PURE__*/_jsx(SvgIcon, _extends({\n \"data-testid\": `${displayName}Icon`,\n ref: ref\n }, props, {\n children: path\n }));\n }\n if (process.env.NODE_ENV !== 'production') {\n // Need to set `displayName` on the inner component for React.memo.\n // React prior to 16.14 ignores `displayName` on the wrapper.\n Component.displayName = `${displayName}Icon`;\n }\n Component.muiName = SvgIcon.muiName;\n return /*#__PURE__*/React.memo( /*#__PURE__*/React.forwardRef(Component));\n}","'use client';\n\nimport { unstable_ClassNameGenerator as ClassNameGenerator } from '@mui/base/ClassNameGenerator';\nexport { default as capitalize } from './capitalize';\nexport { default as createChainedFunction } from './createChainedFunction';\nexport { default as createSvgIcon } from './createSvgIcon';\nexport { default as debounce } from './debounce';\nexport { default as deprecatedPropType } from './deprecatedPropType';\nexport { default as isMuiElement } from './isMuiElement';\nexport { default as ownerDocument } from './ownerDocument';\nexport { default as ownerWindow } from './ownerWindow';\nexport { default as requirePropFactory } from './requirePropFactory';\nexport { default as setRef } from './setRef';\nexport { default as unstable_useEnhancedEffect } from './useEnhancedEffect';\nexport { default as unstable_useId } from './useId';\nexport { default as unsupportedProp } from './unsupportedProp';\nexport { default as useControlled } from './useControlled';\nexport { default as useEventCallback } from './useEventCallback';\nexport { default as useForkRef } from './useForkRef';\nexport { default as useIsFocusVisible } from './useIsFocusVisible';\n// TODO: remove this export once ClassNameGenerator is stable\n// eslint-disable-next-line @typescript-eslint/naming-convention\nexport const unstable_ClassNameGenerator = {\n configure: generator => {\n if (process.env.NODE_ENV !== 'production') {\n console.warn(['MUI: `ClassNameGenerator` import from `@mui/material/utils` is outdated and might cause unexpected issues.', '', \"You should use `import { unstable_ClassNameGenerator } from '@mui/material/className'` instead\", '', 'The detail of the issue: https://github.com/mui/material-ui/issues/30011#issuecomment-1024993401', '', 'The updated documentation: https://mui.com/guides/classname-generator/'].join('\\n'));\n }\n ClassNameGenerator.configure(generator);\n }\n};","\"use strict\";\n'use client';\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nObject.defineProperty(exports, \"default\", {\n enumerable: true,\n get: function () {\n return _utils.createSvgIcon;\n }\n});\nvar _utils = require(\"@mui/material/utils\");","\"use strict\";\n\"use client\";\n\nvar _interopRequireDefault = require(\"@babel/runtime/helpers/interopRequireDefault\");\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = void 0;\nvar _createSvgIcon = _interopRequireDefault(require(\"./utils/createSvgIcon\"));\nvar _jsxRuntime = require(\"react/jsx-runtime\");\nvar _default = exports.default = (0, _createSvgIcon.default)( /*#__PURE__*/(0, _jsxRuntime.jsx)(\"path\", {\n d: \"m10 17 5-5-5-5z\"\n}), 'ArrowRight');","/**\n * Determines if a given element is a DOM element name (i.e. not a React component).\n */\nexport function isHostComponent(element) {\n return typeof element === 'string';\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport { isHostComponent } from './isHostComponent';\n\n/**\n * Type of the ownerState based on the type of an element it applies to.\n * This resolves to the provided OwnerState for React components and `undefined` for host components.\n * Falls back to `OwnerState | undefined` when the exact type can't be determined in development time.\n */\n\n/**\n * Appends the ownerState object to the props, merging with the existing one if necessary.\n *\n * @param elementType Type of the element that owns the `existingProps`. If the element is a DOM node or undefined, `ownerState` is not applied.\n * @param otherProps Props of the element.\n * @param ownerState\n */\nexport function appendOwnerState(elementType, otherProps, ownerState) {\n if (elementType === undefined || isHostComponent(elementType)) {\n return otherProps;\n }\n return _extends({}, otherProps, {\n ownerState: _extends({}, otherProps.ownerState, ownerState)\n });\n}","'use client';\n\nimport * as React from 'react';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nconst defaultContextValue = {\n disableDefaultClasses: false\n};\nconst ClassNameConfiguratorContext = /*#__PURE__*/React.createContext(defaultContextValue);\n/**\n * @ignore - internal hook.\n *\n * Wraps the `generateUtilityClass` function and controls how the classes are generated.\n * Currently it only affects whether the classes are applied or not.\n *\n * @returns Function to be called with the `generateUtilityClass` function specific to a component to generate the classes.\n */\nexport function useClassNamesOverride(generateUtilityClass) {\n const {\n disableDefaultClasses\n } = React.useContext(ClassNameConfiguratorContext);\n return slot => {\n if (disableDefaultClasses) {\n return '';\n }\n return generateUtilityClass(slot);\n };\n}\n\n/**\n * Allows to configure the components within to not apply any built-in classes.\n */\nexport function ClassNameConfigurator(props) {\n const {\n disableDefaultClasses,\n children\n } = props;\n const contextValue = React.useMemo(() => ({\n disableDefaultClasses: disableDefaultClasses != null ? disableDefaultClasses : false\n }), [disableDefaultClasses]);\n return /*#__PURE__*/_jsx(ClassNameConfiguratorContext.Provider, {\n value: contextValue,\n children: children\n });\n}","/**\n * Extracts event handlers from a given object.\n * A prop is considered an event handler if it is a function and its name starts with `on`.\n *\n * @param object An object to extract event handlers from.\n * @param excludeKeys An array of keys to exclude from the returned object.\n */\nexport function extractEventHandlers(object, excludeKeys = []) {\n if (object === undefined) {\n return {};\n }\n const result = {};\n Object.keys(object).filter(prop => prop.match(/^on[A-Z]/) && typeof object[prop] === 'function' && !excludeKeys.includes(prop)).forEach(prop => {\n result[prop] = object[prop];\n });\n return result;\n}","/**\n * If `componentProps` is a function, calls it with the provided `ownerState`.\n * Otherwise, just returns `componentProps`.\n */\nexport function resolveComponentProps(componentProps, ownerState, slotState) {\n if (typeof componentProps === 'function') {\n return componentProps(ownerState, slotState);\n }\n return componentProps;\n}","/**\n * Removes event handlers from the given object.\n * A field is considered an event handler if it is a function with a name beginning with `on`.\n *\n * @param object Object to remove event handlers from.\n * @returns Object with event handlers removed.\n */\nexport function omitEventHandlers(object) {\n if (object === undefined) {\n return {};\n }\n const result = {};\n Object.keys(object).filter(prop => !(prop.match(/^on[A-Z]/) && typeof object[prop] === 'function')).forEach(prop => {\n result[prop] = object[prop];\n });\n return result;\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport clsx from 'clsx';\nimport { extractEventHandlers } from './extractEventHandlers';\nimport { omitEventHandlers } from './omitEventHandlers';\n/**\n * Merges the slot component internal props (usually coming from a hook)\n * with the externally provided ones.\n *\n * The merge order is (the latter overrides the former):\n * 1. The internal props (specified as a getter function to work with get*Props hook result)\n * 2. Additional props (specified internally on a Base UI component)\n * 3. External props specified on the owner component. These should only be used on a root slot.\n * 4. External props specified in the `slotProps.*` prop.\n * 5. The `className` prop - combined from all the above.\n * @param parameters\n * @returns\n */\nexport function mergeSlotProps(parameters) {\n const {\n getSlotProps,\n additionalProps,\n externalSlotProps,\n externalForwardedProps,\n className\n } = parameters;\n if (!getSlotProps) {\n // The simpler case - getSlotProps is not defined, so no internal event handlers are defined,\n // so we can simply merge all the props without having to worry about extracting event handlers.\n const joinedClasses = clsx(additionalProps == null ? void 0 : additionalProps.className, className, externalForwardedProps == null ? void 0 : externalForwardedProps.className, externalSlotProps == null ? void 0 : externalSlotProps.className);\n const mergedStyle = _extends({}, additionalProps == null ? void 0 : additionalProps.style, externalForwardedProps == null ? void 0 : externalForwardedProps.style, externalSlotProps == null ? void 0 : externalSlotProps.style);\n const props = _extends({}, additionalProps, externalForwardedProps, externalSlotProps);\n if (joinedClasses.length > 0) {\n props.className = joinedClasses;\n }\n if (Object.keys(mergedStyle).length > 0) {\n props.style = mergedStyle;\n }\n return {\n props,\n internalRef: undefined\n };\n }\n\n // In this case, getSlotProps is responsible for calling the external event handlers.\n // We don't need to include them in the merged props because of this.\n\n const eventHandlers = extractEventHandlers(_extends({}, externalForwardedProps, externalSlotProps));\n const componentsPropsWithoutEventHandlers = omitEventHandlers(externalSlotProps);\n const otherPropsWithoutEventHandlers = omitEventHandlers(externalForwardedProps);\n const internalSlotProps = getSlotProps(eventHandlers);\n\n // The order of classes is important here.\n // Emotion (that we use in libraries consuming Base UI) depends on this order\n // to properly override style. It requires the most important classes to be last\n // (see https://github.com/mui/material-ui/pull/33205) for the related discussion.\n const joinedClasses = clsx(internalSlotProps == null ? void 0 : internalSlotProps.className, additionalProps == null ? void 0 : additionalProps.className, className, externalForwardedProps == null ? void 0 : externalForwardedProps.className, externalSlotProps == null ? void 0 : externalSlotProps.className);\n const mergedStyle = _extends({}, internalSlotProps == null ? void 0 : internalSlotProps.style, additionalProps == null ? void 0 : additionalProps.style, externalForwardedProps == null ? void 0 : externalForwardedProps.style, externalSlotProps == null ? void 0 : externalSlotProps.style);\n const props = _extends({}, internalSlotProps, additionalProps, otherPropsWithoutEventHandlers, componentsPropsWithoutEventHandlers);\n if (joinedClasses.length > 0) {\n props.className = joinedClasses;\n }\n if (Object.keys(mergedStyle).length > 0) {\n props.style = mergedStyle;\n }\n return {\n props,\n internalRef: internalSlotProps.ref\n };\n}","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"elementType\", \"externalSlotProps\", \"ownerState\", \"skipResolvingSlotProps\"];\nimport { unstable_useForkRef as useForkRef } from '@mui/utils';\nimport { appendOwnerState } from './appendOwnerState';\nimport { mergeSlotProps } from './mergeSlotProps';\nimport { resolveComponentProps } from './resolveComponentProps';\n/**\n * @ignore - do not document.\n * Builds the props to be passed into the slot of an unstyled component.\n * It merges the internal props of the component with the ones supplied by the user, allowing to customize the behavior.\n * If the slot component is not a host component, it also merges in the `ownerState`.\n *\n * @param parameters.getSlotProps - A function that returns the props to be passed to the slot component.\n */\nexport function useSlotProps(parameters) {\n var _parameters$additiona;\n const {\n elementType,\n externalSlotProps,\n ownerState,\n skipResolvingSlotProps = false\n } = parameters,\n rest = _objectWithoutPropertiesLoose(parameters, _excluded);\n const resolvedComponentsProps = skipResolvingSlotProps ? {} : resolveComponentProps(externalSlotProps, ownerState);\n const {\n props: mergedProps,\n internalRef\n } = mergeSlotProps(_extends({}, rest, {\n externalSlotProps: resolvedComponentsProps\n }));\n const ref = useForkRef(internalRef, resolvedComponentsProps == null ? void 0 : resolvedComponentsProps.ref, (_parameters$additiona = parameters.additionalProps) == null ? void 0 : _parameters$additiona.ref);\n const props = appendOwnerState(elementType, _extends({}, mergedProps, {\n ref\n }), ownerState);\n return props;\n}","import { globalStateClasses } from '@mui/utils/generateUtilityClass';\nconst GLOBAL_CLASS_PREFIX = 'base';\nfunction buildStateClass(state) {\n return `${GLOBAL_CLASS_PREFIX}--${state}`;\n}\nfunction buildSlotClass(componentName, slot) {\n return `${GLOBAL_CLASS_PREFIX}-${componentName}-${slot}`;\n}\nexport function generateUtilityClass(componentName, slot) {\n const globalStateClass = globalStateClasses[slot];\n return globalStateClass ? buildStateClass(globalStateClass) : buildSlotClass(componentName, slot);\n}\nexport function isGlobalState(slot) {\n return globalStateClasses[slot] !== undefined;\n}","import { generateUtilityClass } from '../generateUtilityClass';\nexport function generateUtilityClasses(componentName, slots) {\n const result = {};\n slots.forEach(slot => {\n result[slot] = generateUtilityClass(componentName, slot);\n });\n return result;\n}","'use client';\n\nimport * as React from 'react';\nimport * as ReactDOM from 'react-dom';\nimport PropTypes from 'prop-types';\nimport { exactProp, HTMLElementType, unstable_useEnhancedEffect as useEnhancedEffect, unstable_useForkRef as useForkRef, unstable_setRef as setRef } from '@mui/utils';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nfunction getContainer(container) {\n return typeof container === 'function' ? container() : container;\n}\n\n/**\n * Portals provide a first-class way to render children into a DOM node\n * that exists outside the DOM hierarchy of the parent component.\n *\n * Demos:\n *\n * - [Portal](https://mui.com/base-ui/react-portal/)\n *\n * API:\n *\n * - [Portal API](https://mui.com/base-ui/react-portal/components-api/#portal)\n */\nconst Portal = /*#__PURE__*/React.forwardRef(function Portal(props, forwardedRef) {\n const {\n children,\n container,\n disablePortal = false\n } = props;\n const [mountNode, setMountNode] = React.useState(null);\n // @ts-expect-error TODO upstream fix\n const handleRef = useForkRef( /*#__PURE__*/React.isValidElement(children) ? children.ref : null, forwardedRef);\n useEnhancedEffect(() => {\n if (!disablePortal) {\n setMountNode(getContainer(container) || document.body);\n }\n }, [container, disablePortal]);\n useEnhancedEffect(() => {\n if (mountNode && !disablePortal) {\n setRef(forwardedRef, mountNode);\n return () => {\n setRef(forwardedRef, null);\n };\n }\n return undefined;\n }, [forwardedRef, mountNode, disablePortal]);\n if (disablePortal) {\n if ( /*#__PURE__*/React.isValidElement(children)) {\n const newProps = {\n ref: handleRef\n };\n return /*#__PURE__*/React.cloneElement(children, newProps);\n }\n return /*#__PURE__*/_jsx(React.Fragment, {\n children: children\n });\n }\n return /*#__PURE__*/_jsx(React.Fragment, {\n children: mountNode ? /*#__PURE__*/ReactDOM.createPortal(children, mountNode) : mountNode\n });\n});\nprocess.env.NODE_ENV !== \"production\" ? Portal.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * The children to render into the `container`.\n */\n children: PropTypes.node,\n /**\n * An HTML element or function that returns one.\n * The `container` will have the portal children appended to it.\n *\n * You can also provide a callback, which is called in a React layout effect.\n * This lets you set the container from a ref, and also makes server-side rendering possible.\n *\n * By default, it uses the body of the top-level document object,\n * so it's simply `document.body` most of the time.\n */\n container: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.func]),\n /**\n * The `children` will be under the DOM hierarchy of the parent component.\n * @default false\n */\n disablePortal: PropTypes.bool\n} : void 0;\nif (process.env.NODE_ENV !== 'production') {\n // eslint-disable-next-line\n Portal['propTypes' + ''] = exactProp(Portal.propTypes);\n}\nexport { Portal };","export var top = 'top';\nexport var bottom = 'bottom';\nexport var right = 'right';\nexport var left = 'left';\nexport var auto = 'auto';\nexport var basePlacements = [top, bottom, right, left];\nexport var start = 'start';\nexport var end = 'end';\nexport var clippingParents = 'clippingParents';\nexport var viewport = 'viewport';\nexport var popper = 'popper';\nexport var reference = 'reference';\nexport var variationPlacements = /*#__PURE__*/basePlacements.reduce(function (acc, placement) {\n return acc.concat([placement + \"-\" + start, placement + \"-\" + end]);\n}, []);\nexport var placements = /*#__PURE__*/[].concat(basePlacements, [auto]).reduce(function (acc, placement) {\n return acc.concat([placement, placement + \"-\" + start, placement + \"-\" + end]);\n}, []); // modifiers that need to read the DOM\n\nexport var beforeRead = 'beforeRead';\nexport var read = 'read';\nexport var afterRead = 'afterRead'; // pure-logic modifiers\n\nexport var beforeMain = 'beforeMain';\nexport var main = 'main';\nexport var afterMain = 'afterMain'; // modifier with the purpose to write to the DOM (or write into a framework state)\n\nexport var beforeWrite = 'beforeWrite';\nexport var write = 'write';\nexport var afterWrite = 'afterWrite';\nexport var modifierPhases = [beforeRead, read, afterRead, beforeMain, main, afterMain, beforeWrite, write, afterWrite];","export default function getNodeName(element) {\n return element ? (element.nodeName || '').toLowerCase() : null;\n}","export default function getWindow(node) {\n if (node == null) {\n return window;\n }\n\n if (node.toString() !== '[object Window]') {\n var ownerDocument = node.ownerDocument;\n return ownerDocument ? ownerDocument.defaultView || window : window;\n }\n\n return node;\n}","import getWindow from \"./getWindow.js\";\n\nfunction isElement(node) {\n var OwnElement = getWindow(node).Element;\n return node instanceof OwnElement || node instanceof Element;\n}\n\nfunction isHTMLElement(node) {\n var OwnElement = getWindow(node).HTMLElement;\n return node instanceof OwnElement || node instanceof HTMLElement;\n}\n\nfunction isShadowRoot(node) {\n // IE 11 has no ShadowRoot\n if (typeof ShadowRoot === 'undefined') {\n return false;\n }\n\n var OwnElement = getWindow(node).ShadowRoot;\n return node instanceof OwnElement || node instanceof ShadowRoot;\n}\n\nexport { isElement, isHTMLElement, isShadowRoot };","import getNodeName from \"../dom-utils/getNodeName.js\";\nimport { isHTMLElement } from \"../dom-utils/instanceOf.js\"; // This modifier takes the styles prepared by the `computeStyles` modifier\n// and applies them to the HTMLElements such as popper and arrow\n\nfunction applyStyles(_ref) {\n var state = _ref.state;\n Object.keys(state.elements).forEach(function (name) {\n var style = state.styles[name] || {};\n var attributes = state.attributes[name] || {};\n var element = state.elements[name]; // arrow is optional + virtual elements\n\n if (!isHTMLElement(element) || !getNodeName(element)) {\n return;\n } // Flow doesn't support to extend this property, but it's the most\n // effective way to apply styles to an HTMLElement\n // $FlowFixMe[cannot-write]\n\n\n Object.assign(element.style, style);\n Object.keys(attributes).forEach(function (name) {\n var value = attributes[name];\n\n if (value === false) {\n element.removeAttribute(name);\n } else {\n element.setAttribute(name, value === true ? '' : value);\n }\n });\n });\n}\n\nfunction effect(_ref2) {\n var state = _ref2.state;\n var initialStyles = {\n popper: {\n position: state.options.strategy,\n left: '0',\n top: '0',\n margin: '0'\n },\n arrow: {\n position: 'absolute'\n },\n reference: {}\n };\n Object.assign(state.elements.popper.style, initialStyles.popper);\n state.styles = initialStyles;\n\n if (state.elements.arrow) {\n Object.assign(state.elements.arrow.style, initialStyles.arrow);\n }\n\n return function () {\n Object.keys(state.elements).forEach(function (name) {\n var element = state.elements[name];\n var attributes = state.attributes[name] || {};\n var styleProperties = Object.keys(state.styles.hasOwnProperty(name) ? state.styles[name] : initialStyles[name]); // Set all values to an empty string to unset them\n\n var style = styleProperties.reduce(function (style, property) {\n style[property] = '';\n return style;\n }, {}); // arrow is optional + virtual elements\n\n if (!isHTMLElement(element) || !getNodeName(element)) {\n return;\n }\n\n Object.assign(element.style, style);\n Object.keys(attributes).forEach(function (attribute) {\n element.removeAttribute(attribute);\n });\n });\n };\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'applyStyles',\n enabled: true,\n phase: 'write',\n fn: applyStyles,\n effect: effect,\n requires: ['computeStyles']\n};","import { auto } from \"../enums.js\";\nexport default function getBasePlacement(placement) {\n return placement.split('-')[0];\n}","export var max = Math.max;\nexport var min = Math.min;\nexport var round = Math.round;","export default function getUAString() {\n var uaData = navigator.userAgentData;\n\n if (uaData != null && uaData.brands && Array.isArray(uaData.brands)) {\n return uaData.brands.map(function (item) {\n return item.brand + \"/\" + item.version;\n }).join(' ');\n }\n\n return navigator.userAgent;\n}","import getUAString from \"../utils/userAgent.js\";\nexport default function isLayoutViewport() {\n return !/^((?!chrome|android).)*safari/i.test(getUAString());\n}","import { isElement, isHTMLElement } from \"./instanceOf.js\";\nimport { round } from \"../utils/math.js\";\nimport getWindow from \"./getWindow.js\";\nimport isLayoutViewport from \"./isLayoutViewport.js\";\nexport default function getBoundingClientRect(element, includeScale, isFixedStrategy) {\n if (includeScale === void 0) {\n includeScale = false;\n }\n\n if (isFixedStrategy === void 0) {\n isFixedStrategy = false;\n }\n\n var clientRect = element.getBoundingClientRect();\n var scaleX = 1;\n var scaleY = 1;\n\n if (includeScale && isHTMLElement(element)) {\n scaleX = element.offsetWidth > 0 ? round(clientRect.width) / element.offsetWidth || 1 : 1;\n scaleY = element.offsetHeight > 0 ? round(clientRect.height) / element.offsetHeight || 1 : 1;\n }\n\n var _ref = isElement(element) ? getWindow(element) : window,\n visualViewport = _ref.visualViewport;\n\n var addVisualOffsets = !isLayoutViewport() && isFixedStrategy;\n var x = (clientRect.left + (addVisualOffsets && visualViewport ? visualViewport.offsetLeft : 0)) / scaleX;\n var y = (clientRect.top + (addVisualOffsets && visualViewport ? visualViewport.offsetTop : 0)) / scaleY;\n var width = clientRect.width / scaleX;\n var height = clientRect.height / scaleY;\n return {\n width: width,\n height: height,\n top: y,\n right: x + width,\n bottom: y + height,\n left: x,\n x: x,\n y: y\n };\n}","import getBoundingClientRect from \"./getBoundingClientRect.js\"; // Returns the layout rect of an element relative to its offsetParent. Layout\n// means it doesn't take into account transforms.\n\nexport default function getLayoutRect(element) {\n var clientRect = getBoundingClientRect(element); // Use the clientRect sizes if it's not been transformed.\n // Fixes https://github.com/popperjs/popper-core/issues/1223\n\n var width = element.offsetWidth;\n var height = element.offsetHeight;\n\n if (Math.abs(clientRect.width - width) <= 1) {\n width = clientRect.width;\n }\n\n if (Math.abs(clientRect.height - height) <= 1) {\n height = clientRect.height;\n }\n\n return {\n x: element.offsetLeft,\n y: element.offsetTop,\n width: width,\n height: height\n };\n}","import { isShadowRoot } from \"./instanceOf.js\";\nexport default function contains(parent, child) {\n var rootNode = child.getRootNode && child.getRootNode(); // First, attempt with faster native method\n\n if (parent.contains(child)) {\n return true;\n } // then fallback to custom implementation with Shadow DOM support\n else if (rootNode && isShadowRoot(rootNode)) {\n var next = child;\n\n do {\n if (next && parent.isSameNode(next)) {\n return true;\n } // $FlowFixMe[prop-missing]: need a better way to handle this...\n\n\n next = next.parentNode || next.host;\n } while (next);\n } // Give up, the result is false\n\n\n return false;\n}","import getWindow from \"./getWindow.js\";\nexport default function getComputedStyle(element) {\n return getWindow(element).getComputedStyle(element);\n}","import getNodeName from \"./getNodeName.js\";\nexport default function isTableElement(element) {\n return ['table', 'td', 'th'].indexOf(getNodeName(element)) >= 0;\n}","import { isElement } from \"./instanceOf.js\";\nexport default function getDocumentElement(element) {\n // $FlowFixMe[incompatible-return]: assume body is always available\n return ((isElement(element) ? element.ownerDocument : // $FlowFixMe[prop-missing]\n element.document) || window.document).documentElement;\n}","import getNodeName from \"./getNodeName.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport { isShadowRoot } from \"./instanceOf.js\";\nexport default function getParentNode(element) {\n if (getNodeName(element) === 'html') {\n return element;\n }\n\n return (// this is a quicker (but less type safe) way to save quite some bytes from the bundle\n // $FlowFixMe[incompatible-return]\n // $FlowFixMe[prop-missing]\n element.assignedSlot || // step into the shadow DOM of the parent of a slotted node\n element.parentNode || ( // DOM Element detected\n isShadowRoot(element) ? element.host : null) || // ShadowRoot detected\n // $FlowFixMe[incompatible-call]: HTMLElement is a Node\n getDocumentElement(element) // fallback\n\n );\n}","import getWindow from \"./getWindow.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport getComputedStyle from \"./getComputedStyle.js\";\nimport { isHTMLElement, isShadowRoot } from \"./instanceOf.js\";\nimport isTableElement from \"./isTableElement.js\";\nimport getParentNode from \"./getParentNode.js\";\nimport getUAString from \"../utils/userAgent.js\";\n\nfunction getTrueOffsetParent(element) {\n if (!isHTMLElement(element) || // https://github.com/popperjs/popper-core/issues/837\n getComputedStyle(element).position === 'fixed') {\n return null;\n }\n\n return element.offsetParent;\n} // `.offsetParent` reports `null` for fixed elements, while absolute elements\n// return the containing block\n\n\nfunction getContainingBlock(element) {\n var isFirefox = /firefox/i.test(getUAString());\n var isIE = /Trident/i.test(getUAString());\n\n if (isIE && isHTMLElement(element)) {\n // In IE 9, 10 and 11 fixed elements containing block is always established by the viewport\n var elementCss = getComputedStyle(element);\n\n if (elementCss.position === 'fixed') {\n return null;\n }\n }\n\n var currentNode = getParentNode(element);\n\n if (isShadowRoot(currentNode)) {\n currentNode = currentNode.host;\n }\n\n while (isHTMLElement(currentNode) && ['html', 'body'].indexOf(getNodeName(currentNode)) < 0) {\n var css = getComputedStyle(currentNode); // This is non-exhaustive but covers the most common CSS properties that\n // create a containing block.\n // https://developer.mozilla.org/en-US/docs/Web/CSS/Containing_block#identifying_the_containing_block\n\n if (css.transform !== 'none' || css.perspective !== 'none' || css.contain === 'paint' || ['transform', 'perspective'].indexOf(css.willChange) !== -1 || isFirefox && css.willChange === 'filter' || isFirefox && css.filter && css.filter !== 'none') {\n return currentNode;\n } else {\n currentNode = currentNode.parentNode;\n }\n }\n\n return null;\n} // Gets the closest ancestor positioned element. Handles some edge cases,\n// such as table ancestors and cross browser bugs.\n\n\nexport default function getOffsetParent(element) {\n var window = getWindow(element);\n var offsetParent = getTrueOffsetParent(element);\n\n while (offsetParent && isTableElement(offsetParent) && getComputedStyle(offsetParent).position === 'static') {\n offsetParent = getTrueOffsetParent(offsetParent);\n }\n\n if (offsetParent && (getNodeName(offsetParent) === 'html' || getNodeName(offsetParent) === 'body' && getComputedStyle(offsetParent).position === 'static')) {\n return window;\n }\n\n return offsetParent || getContainingBlock(element) || window;\n}","export default function getMainAxisFromPlacement(placement) {\n return ['top', 'bottom'].indexOf(placement) >= 0 ? 'x' : 'y';\n}","import { max as mathMax, min as mathMin } from \"./math.js\";\nexport function within(min, value, max) {\n return mathMax(min, mathMin(value, max));\n}\nexport function withinMaxClamp(min, value, max) {\n var v = within(min, value, max);\n return v > max ? max : v;\n}","export default function getFreshSideObject() {\n return {\n top: 0,\n right: 0,\n bottom: 0,\n left: 0\n };\n}","import getFreshSideObject from \"./getFreshSideObject.js\";\nexport default function mergePaddingObject(paddingObject) {\n return Object.assign({}, getFreshSideObject(), paddingObject);\n}","export default function expandToHashMap(value, keys) {\n return keys.reduce(function (hashMap, key) {\n hashMap[key] = value;\n return hashMap;\n }, {});\n}","import getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getLayoutRect from \"../dom-utils/getLayoutRect.js\";\nimport contains from \"../dom-utils/contains.js\";\nimport getOffsetParent from \"../dom-utils/getOffsetParent.js\";\nimport getMainAxisFromPlacement from \"../utils/getMainAxisFromPlacement.js\";\nimport { within } from \"../utils/within.js\";\nimport mergePaddingObject from \"../utils/mergePaddingObject.js\";\nimport expandToHashMap from \"../utils/expandToHashMap.js\";\nimport { left, right, basePlacements, top, bottom } from \"../enums.js\"; // eslint-disable-next-line import/no-unused-modules\n\nvar toPaddingObject = function toPaddingObject(padding, state) {\n padding = typeof padding === 'function' ? padding(Object.assign({}, state.rects, {\n placement: state.placement\n })) : padding;\n return mergePaddingObject(typeof padding !== 'number' ? padding : expandToHashMap(padding, basePlacements));\n};\n\nfunction arrow(_ref) {\n var _state$modifiersData$;\n\n var state = _ref.state,\n name = _ref.name,\n options = _ref.options;\n var arrowElement = state.elements.arrow;\n var popperOffsets = state.modifiersData.popperOffsets;\n var basePlacement = getBasePlacement(state.placement);\n var axis = getMainAxisFromPlacement(basePlacement);\n var isVertical = [left, right].indexOf(basePlacement) >= 0;\n var len = isVertical ? 'height' : 'width';\n\n if (!arrowElement || !popperOffsets) {\n return;\n }\n\n var paddingObject = toPaddingObject(options.padding, state);\n var arrowRect = getLayoutRect(arrowElement);\n var minProp = axis === 'y' ? top : left;\n var maxProp = axis === 'y' ? bottom : right;\n var endDiff = state.rects.reference[len] + state.rects.reference[axis] - popperOffsets[axis] - state.rects.popper[len];\n var startDiff = popperOffsets[axis] - state.rects.reference[axis];\n var arrowOffsetParent = getOffsetParent(arrowElement);\n var clientSize = arrowOffsetParent ? axis === 'y' ? arrowOffsetParent.clientHeight || 0 : arrowOffsetParent.clientWidth || 0 : 0;\n var centerToReference = endDiff / 2 - startDiff / 2; // Make sure the arrow doesn't overflow the popper if the center point is\n // outside of the popper bounds\n\n var min = paddingObject[minProp];\n var max = clientSize - arrowRect[len] - paddingObject[maxProp];\n var center = clientSize / 2 - arrowRect[len] / 2 + centerToReference;\n var offset = within(min, center, max); // Prevents breaking syntax highlighting...\n\n var axisProp = axis;\n state.modifiersData[name] = (_state$modifiersData$ = {}, _state$modifiersData$[axisProp] = offset, _state$modifiersData$.centerOffset = offset - center, _state$modifiersData$);\n}\n\nfunction effect(_ref2) {\n var state = _ref2.state,\n options = _ref2.options;\n var _options$element = options.element,\n arrowElement = _options$element === void 0 ? '[data-popper-arrow]' : _options$element;\n\n if (arrowElement == null) {\n return;\n } // CSS selector\n\n\n if (typeof arrowElement === 'string') {\n arrowElement = state.elements.popper.querySelector(arrowElement);\n\n if (!arrowElement) {\n return;\n }\n }\n\n if (!contains(state.elements.popper, arrowElement)) {\n return;\n }\n\n state.elements.arrow = arrowElement;\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'arrow',\n enabled: true,\n phase: 'main',\n fn: arrow,\n effect: effect,\n requires: ['popperOffsets'],\n requiresIfExists: ['preventOverflow']\n};","export default function getVariation(placement) {\n return placement.split('-')[1];\n}","import { top, left, right, bottom, end } from \"../enums.js\";\nimport getOffsetParent from \"../dom-utils/getOffsetParent.js\";\nimport getWindow from \"../dom-utils/getWindow.js\";\nimport getDocumentElement from \"../dom-utils/getDocumentElement.js\";\nimport getComputedStyle from \"../dom-utils/getComputedStyle.js\";\nimport getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getVariation from \"../utils/getVariation.js\";\nimport { round } from \"../utils/math.js\"; // eslint-disable-next-line import/no-unused-modules\n\nvar unsetSides = {\n top: 'auto',\n right: 'auto',\n bottom: 'auto',\n left: 'auto'\n}; // Round the offsets to the nearest suitable subpixel based on the DPR.\n// Zooming can change the DPR, but it seems to report a value that will\n// cleanly divide the values into the appropriate subpixels.\n\nfunction roundOffsetsByDPR(_ref, win) {\n var x = _ref.x,\n y = _ref.y;\n var dpr = win.devicePixelRatio || 1;\n return {\n x: round(x * dpr) / dpr || 0,\n y: round(y * dpr) / dpr || 0\n };\n}\n\nexport function mapToStyles(_ref2) {\n var _Object$assign2;\n\n var popper = _ref2.popper,\n popperRect = _ref2.popperRect,\n placement = _ref2.placement,\n variation = _ref2.variation,\n offsets = _ref2.offsets,\n position = _ref2.position,\n gpuAcceleration = _ref2.gpuAcceleration,\n adaptive = _ref2.adaptive,\n roundOffsets = _ref2.roundOffsets,\n isFixed = _ref2.isFixed;\n var _offsets$x = offsets.x,\n x = _offsets$x === void 0 ? 0 : _offsets$x,\n _offsets$y = offsets.y,\n y = _offsets$y === void 0 ? 0 : _offsets$y;\n\n var _ref3 = typeof roundOffsets === 'function' ? roundOffsets({\n x: x,\n y: y\n }) : {\n x: x,\n y: y\n };\n\n x = _ref3.x;\n y = _ref3.y;\n var hasX = offsets.hasOwnProperty('x');\n var hasY = offsets.hasOwnProperty('y');\n var sideX = left;\n var sideY = top;\n var win = window;\n\n if (adaptive) {\n var offsetParent = getOffsetParent(popper);\n var heightProp = 'clientHeight';\n var widthProp = 'clientWidth';\n\n if (offsetParent === getWindow(popper)) {\n offsetParent = getDocumentElement(popper);\n\n if (getComputedStyle(offsetParent).position !== 'static' && position === 'absolute') {\n heightProp = 'scrollHeight';\n widthProp = 'scrollWidth';\n }\n } // $FlowFixMe[incompatible-cast]: force type refinement, we compare offsetParent with window above, but Flow doesn't detect it\n\n\n offsetParent = offsetParent;\n\n if (placement === top || (placement === left || placement === right) && variation === end) {\n sideY = bottom;\n var offsetY = isFixed && offsetParent === win && win.visualViewport ? win.visualViewport.height : // $FlowFixMe[prop-missing]\n offsetParent[heightProp];\n y -= offsetY - popperRect.height;\n y *= gpuAcceleration ? 1 : -1;\n }\n\n if (placement === left || (placement === top || placement === bottom) && variation === end) {\n sideX = right;\n var offsetX = isFixed && offsetParent === win && win.visualViewport ? win.visualViewport.width : // $FlowFixMe[prop-missing]\n offsetParent[widthProp];\n x -= offsetX - popperRect.width;\n x *= gpuAcceleration ? 1 : -1;\n }\n }\n\n var commonStyles = Object.assign({\n position: position\n }, adaptive && unsetSides);\n\n var _ref4 = roundOffsets === true ? roundOffsetsByDPR({\n x: x,\n y: y\n }, getWindow(popper)) : {\n x: x,\n y: y\n };\n\n x = _ref4.x;\n y = _ref4.y;\n\n if (gpuAcceleration) {\n var _Object$assign;\n\n return Object.assign({}, commonStyles, (_Object$assign = {}, _Object$assign[sideY] = hasY ? '0' : '', _Object$assign[sideX] = hasX ? '0' : '', _Object$assign.transform = (win.devicePixelRatio || 1) <= 1 ? \"translate(\" + x + \"px, \" + y + \"px)\" : \"translate3d(\" + x + \"px, \" + y + \"px, 0)\", _Object$assign));\n }\n\n return Object.assign({}, commonStyles, (_Object$assign2 = {}, _Object$assign2[sideY] = hasY ? y + \"px\" : '', _Object$assign2[sideX] = hasX ? x + \"px\" : '', _Object$assign2.transform = '', _Object$assign2));\n}\n\nfunction computeStyles(_ref5) {\n var state = _ref5.state,\n options = _ref5.options;\n var _options$gpuAccelerat = options.gpuAcceleration,\n gpuAcceleration = _options$gpuAccelerat === void 0 ? true : _options$gpuAccelerat,\n _options$adaptive = options.adaptive,\n adaptive = _options$adaptive === void 0 ? true : _options$adaptive,\n _options$roundOffsets = options.roundOffsets,\n roundOffsets = _options$roundOffsets === void 0 ? true : _options$roundOffsets;\n var commonStyles = {\n placement: getBasePlacement(state.placement),\n variation: getVariation(state.placement),\n popper: state.elements.popper,\n popperRect: state.rects.popper,\n gpuAcceleration: gpuAcceleration,\n isFixed: state.options.strategy === 'fixed'\n };\n\n if (state.modifiersData.popperOffsets != null) {\n state.styles.popper = Object.assign({}, state.styles.popper, mapToStyles(Object.assign({}, commonStyles, {\n offsets: state.modifiersData.popperOffsets,\n position: state.options.strategy,\n adaptive: adaptive,\n roundOffsets: roundOffsets\n })));\n }\n\n if (state.modifiersData.arrow != null) {\n state.styles.arrow = Object.assign({}, state.styles.arrow, mapToStyles(Object.assign({}, commonStyles, {\n offsets: state.modifiersData.arrow,\n position: 'absolute',\n adaptive: false,\n roundOffsets: roundOffsets\n })));\n }\n\n state.attributes.popper = Object.assign({}, state.attributes.popper, {\n 'data-popper-placement': state.placement\n });\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'computeStyles',\n enabled: true,\n phase: 'beforeWrite',\n fn: computeStyles,\n data: {}\n};","import getWindow from \"../dom-utils/getWindow.js\"; // eslint-disable-next-line import/no-unused-modules\n\nvar passive = {\n passive: true\n};\n\nfunction effect(_ref) {\n var state = _ref.state,\n instance = _ref.instance,\n options = _ref.options;\n var _options$scroll = options.scroll,\n scroll = _options$scroll === void 0 ? true : _options$scroll,\n _options$resize = options.resize,\n resize = _options$resize === void 0 ? true : _options$resize;\n var window = getWindow(state.elements.popper);\n var scrollParents = [].concat(state.scrollParents.reference, state.scrollParents.popper);\n\n if (scroll) {\n scrollParents.forEach(function (scrollParent) {\n scrollParent.addEventListener('scroll', instance.update, passive);\n });\n }\n\n if (resize) {\n window.addEventListener('resize', instance.update, passive);\n }\n\n return function () {\n if (scroll) {\n scrollParents.forEach(function (scrollParent) {\n scrollParent.removeEventListener('scroll', instance.update, passive);\n });\n }\n\n if (resize) {\n window.removeEventListener('resize', instance.update, passive);\n }\n };\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'eventListeners',\n enabled: true,\n phase: 'write',\n fn: function fn() {},\n effect: effect,\n data: {}\n};","var hash = {\n left: 'right',\n right: 'left',\n bottom: 'top',\n top: 'bottom'\n};\nexport default function getOppositePlacement(placement) {\n return placement.replace(/left|right|bottom|top/g, function (matched) {\n return hash[matched];\n });\n}","var hash = {\n start: 'end',\n end: 'start'\n};\nexport default function getOppositeVariationPlacement(placement) {\n return placement.replace(/start|end/g, function (matched) {\n return hash[matched];\n });\n}","import getWindow from \"./getWindow.js\";\nexport default function getWindowScroll(node) {\n var win = getWindow(node);\n var scrollLeft = win.pageXOffset;\n var scrollTop = win.pageYOffset;\n return {\n scrollLeft: scrollLeft,\n scrollTop: scrollTop\n };\n}","import getBoundingClientRect from \"./getBoundingClientRect.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport getWindowScroll from \"./getWindowScroll.js\";\nexport default function getWindowScrollBarX(element) {\n // If has a CSS width greater than the viewport, then this will be\n // incorrect for RTL.\n // Popper 1 is broken in this case and never had a bug report so let's assume\n // it's not an issue. I don't think anyone ever specifies width on \n // anyway.\n // Browsers where the left scrollbar doesn't cause an issue report `0` for\n // this (e.g. Edge 2019, IE11, Safari)\n return getBoundingClientRect(getDocumentElement(element)).left + getWindowScroll(element).scrollLeft;\n}","import getWindow from \"./getWindow.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport getWindowScrollBarX from \"./getWindowScrollBarX.js\";\nimport isLayoutViewport from \"./isLayoutViewport.js\";\nexport default function getViewportRect(element, strategy) {\n var win = getWindow(element);\n var html = getDocumentElement(element);\n var visualViewport = win.visualViewport;\n var width = html.clientWidth;\n var height = html.clientHeight;\n var x = 0;\n var y = 0;\n\n if (visualViewport) {\n width = visualViewport.width;\n height = visualViewport.height;\n var layoutViewport = isLayoutViewport();\n\n if (layoutViewport || !layoutViewport && strategy === 'fixed') {\n x = visualViewport.offsetLeft;\n y = visualViewport.offsetTop;\n }\n }\n\n return {\n width: width,\n height: height,\n x: x + getWindowScrollBarX(element),\n y: y\n };\n}","import getDocumentElement from \"./getDocumentElement.js\";\nimport getComputedStyle from \"./getComputedStyle.js\";\nimport getWindowScrollBarX from \"./getWindowScrollBarX.js\";\nimport getWindowScroll from \"./getWindowScroll.js\";\nimport { max } from \"../utils/math.js\"; // Gets the entire size of the scrollable document area, even extending outside\n// of the `` and `` rect bounds if horizontally scrollable\n\nexport default function getDocumentRect(element) {\n var _element$ownerDocumen;\n\n var html = getDocumentElement(element);\n var winScroll = getWindowScroll(element);\n var body = (_element$ownerDocumen = element.ownerDocument) == null ? void 0 : _element$ownerDocumen.body;\n var width = max(html.scrollWidth, html.clientWidth, body ? body.scrollWidth : 0, body ? body.clientWidth : 0);\n var height = max(html.scrollHeight, html.clientHeight, body ? body.scrollHeight : 0, body ? body.clientHeight : 0);\n var x = -winScroll.scrollLeft + getWindowScrollBarX(element);\n var y = -winScroll.scrollTop;\n\n if (getComputedStyle(body || html).direction === 'rtl') {\n x += max(html.clientWidth, body ? body.clientWidth : 0) - width;\n }\n\n return {\n width: width,\n height: height,\n x: x,\n y: y\n };\n}","import getComputedStyle from \"./getComputedStyle.js\";\nexport default function isScrollParent(element) {\n // Firefox wants us to check `-x` and `-y` variations as well\n var _getComputedStyle = getComputedStyle(element),\n overflow = _getComputedStyle.overflow,\n overflowX = _getComputedStyle.overflowX,\n overflowY = _getComputedStyle.overflowY;\n\n return /auto|scroll|overlay|hidden/.test(overflow + overflowY + overflowX);\n}","import getParentNode from \"./getParentNode.js\";\nimport isScrollParent from \"./isScrollParent.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport { isHTMLElement } from \"./instanceOf.js\";\nexport default function getScrollParent(node) {\n if (['html', 'body', '#document'].indexOf(getNodeName(node)) >= 0) {\n // $FlowFixMe[incompatible-return]: assume body is always available\n return node.ownerDocument.body;\n }\n\n if (isHTMLElement(node) && isScrollParent(node)) {\n return node;\n }\n\n return getScrollParent(getParentNode(node));\n}","import getScrollParent from \"./getScrollParent.js\";\nimport getParentNode from \"./getParentNode.js\";\nimport getWindow from \"./getWindow.js\";\nimport isScrollParent from \"./isScrollParent.js\";\n/*\ngiven a DOM element, return the list of all scroll parents, up the list of ancesors\nuntil we get to the top window object. This list is what we attach scroll listeners\nto, because if any of these parent elements scroll, we'll need to re-calculate the\nreference element's position.\n*/\n\nexport default function listScrollParents(element, list) {\n var _element$ownerDocumen;\n\n if (list === void 0) {\n list = [];\n }\n\n var scrollParent = getScrollParent(element);\n var isBody = scrollParent === ((_element$ownerDocumen = element.ownerDocument) == null ? void 0 : _element$ownerDocumen.body);\n var win = getWindow(scrollParent);\n var target = isBody ? [win].concat(win.visualViewport || [], isScrollParent(scrollParent) ? scrollParent : []) : scrollParent;\n var updatedList = list.concat(target);\n return isBody ? updatedList : // $FlowFixMe[incompatible-call]: isBody tells us target will be an HTMLElement here\n updatedList.concat(listScrollParents(getParentNode(target)));\n}","export default function rectToClientRect(rect) {\n return Object.assign({}, rect, {\n left: rect.x,\n top: rect.y,\n right: rect.x + rect.width,\n bottom: rect.y + rect.height\n });\n}","import { viewport } from \"../enums.js\";\nimport getViewportRect from \"./getViewportRect.js\";\nimport getDocumentRect from \"./getDocumentRect.js\";\nimport listScrollParents from \"./listScrollParents.js\";\nimport getOffsetParent from \"./getOffsetParent.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport getComputedStyle from \"./getComputedStyle.js\";\nimport { isElement, isHTMLElement } from \"./instanceOf.js\";\nimport getBoundingClientRect from \"./getBoundingClientRect.js\";\nimport getParentNode from \"./getParentNode.js\";\nimport contains from \"./contains.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport rectToClientRect from \"../utils/rectToClientRect.js\";\nimport { max, min } from \"../utils/math.js\";\n\nfunction getInnerBoundingClientRect(element, strategy) {\n var rect = getBoundingClientRect(element, false, strategy === 'fixed');\n rect.top = rect.top + element.clientTop;\n rect.left = rect.left + element.clientLeft;\n rect.bottom = rect.top + element.clientHeight;\n rect.right = rect.left + element.clientWidth;\n rect.width = element.clientWidth;\n rect.height = element.clientHeight;\n rect.x = rect.left;\n rect.y = rect.top;\n return rect;\n}\n\nfunction getClientRectFromMixedType(element, clippingParent, strategy) {\n return clippingParent === viewport ? rectToClientRect(getViewportRect(element, strategy)) : isElement(clippingParent) ? getInnerBoundingClientRect(clippingParent, strategy) : rectToClientRect(getDocumentRect(getDocumentElement(element)));\n} // A \"clipping parent\" is an overflowable container with the characteristic of\n// clipping (or hiding) overflowing elements with a position different from\n// `initial`\n\n\nfunction getClippingParents(element) {\n var clippingParents = listScrollParents(getParentNode(element));\n var canEscapeClipping = ['absolute', 'fixed'].indexOf(getComputedStyle(element).position) >= 0;\n var clipperElement = canEscapeClipping && isHTMLElement(element) ? getOffsetParent(element) : element;\n\n if (!isElement(clipperElement)) {\n return [];\n } // $FlowFixMe[incompatible-return]: https://github.com/facebook/flow/issues/1414\n\n\n return clippingParents.filter(function (clippingParent) {\n return isElement(clippingParent) && contains(clippingParent, clipperElement) && getNodeName(clippingParent) !== 'body';\n });\n} // Gets the maximum area that the element is visible in due to any number of\n// clipping parents\n\n\nexport default function getClippingRect(element, boundary, rootBoundary, strategy) {\n var mainClippingParents = boundary === 'clippingParents' ? getClippingParents(element) : [].concat(boundary);\n var clippingParents = [].concat(mainClippingParents, [rootBoundary]);\n var firstClippingParent = clippingParents[0];\n var clippingRect = clippingParents.reduce(function (accRect, clippingParent) {\n var rect = getClientRectFromMixedType(element, clippingParent, strategy);\n accRect.top = max(rect.top, accRect.top);\n accRect.right = min(rect.right, accRect.right);\n accRect.bottom = min(rect.bottom, accRect.bottom);\n accRect.left = max(rect.left, accRect.left);\n return accRect;\n }, getClientRectFromMixedType(element, firstClippingParent, strategy));\n clippingRect.width = clippingRect.right - clippingRect.left;\n clippingRect.height = clippingRect.bottom - clippingRect.top;\n clippingRect.x = clippingRect.left;\n clippingRect.y = clippingRect.top;\n return clippingRect;\n}","import getBasePlacement from \"./getBasePlacement.js\";\nimport getVariation from \"./getVariation.js\";\nimport getMainAxisFromPlacement from \"./getMainAxisFromPlacement.js\";\nimport { top, right, bottom, left, start, end } from \"../enums.js\";\nexport default function computeOffsets(_ref) {\n var reference = _ref.reference,\n element = _ref.element,\n placement = _ref.placement;\n var basePlacement = placement ? getBasePlacement(placement) : null;\n var variation = placement ? getVariation(placement) : null;\n var commonX = reference.x + reference.width / 2 - element.width / 2;\n var commonY = reference.y + reference.height / 2 - element.height / 2;\n var offsets;\n\n switch (basePlacement) {\n case top:\n offsets = {\n x: commonX,\n y: reference.y - element.height\n };\n break;\n\n case bottom:\n offsets = {\n x: commonX,\n y: reference.y + reference.height\n };\n break;\n\n case right:\n offsets = {\n x: reference.x + reference.width,\n y: commonY\n };\n break;\n\n case left:\n offsets = {\n x: reference.x - element.width,\n y: commonY\n };\n break;\n\n default:\n offsets = {\n x: reference.x,\n y: reference.y\n };\n }\n\n var mainAxis = basePlacement ? getMainAxisFromPlacement(basePlacement) : null;\n\n if (mainAxis != null) {\n var len = mainAxis === 'y' ? 'height' : 'width';\n\n switch (variation) {\n case start:\n offsets[mainAxis] = offsets[mainAxis] - (reference[len] / 2 - element[len] / 2);\n break;\n\n case end:\n offsets[mainAxis] = offsets[mainAxis] + (reference[len] / 2 - element[len] / 2);\n break;\n\n default:\n }\n }\n\n return offsets;\n}","import getClippingRect from \"../dom-utils/getClippingRect.js\";\nimport getDocumentElement from \"../dom-utils/getDocumentElement.js\";\nimport getBoundingClientRect from \"../dom-utils/getBoundingClientRect.js\";\nimport computeOffsets from \"./computeOffsets.js\";\nimport rectToClientRect from \"./rectToClientRect.js\";\nimport { clippingParents, reference, popper, bottom, top, right, basePlacements, viewport } from \"../enums.js\";\nimport { isElement } from \"../dom-utils/instanceOf.js\";\nimport mergePaddingObject from \"./mergePaddingObject.js\";\nimport expandToHashMap from \"./expandToHashMap.js\"; // eslint-disable-next-line import/no-unused-modules\n\nexport default function detectOverflow(state, options) {\n if (options === void 0) {\n options = {};\n }\n\n var _options = options,\n _options$placement = _options.placement,\n placement = _options$placement === void 0 ? state.placement : _options$placement,\n _options$strategy = _options.strategy,\n strategy = _options$strategy === void 0 ? state.strategy : _options$strategy,\n _options$boundary = _options.boundary,\n boundary = _options$boundary === void 0 ? clippingParents : _options$boundary,\n _options$rootBoundary = _options.rootBoundary,\n rootBoundary = _options$rootBoundary === void 0 ? viewport : _options$rootBoundary,\n _options$elementConte = _options.elementContext,\n elementContext = _options$elementConte === void 0 ? popper : _options$elementConte,\n _options$altBoundary = _options.altBoundary,\n altBoundary = _options$altBoundary === void 0 ? false : _options$altBoundary,\n _options$padding = _options.padding,\n padding = _options$padding === void 0 ? 0 : _options$padding;\n var paddingObject = mergePaddingObject(typeof padding !== 'number' ? padding : expandToHashMap(padding, basePlacements));\n var altContext = elementContext === popper ? reference : popper;\n var popperRect = state.rects.popper;\n var element = state.elements[altBoundary ? altContext : elementContext];\n var clippingClientRect = getClippingRect(isElement(element) ? element : element.contextElement || getDocumentElement(state.elements.popper), boundary, rootBoundary, strategy);\n var referenceClientRect = getBoundingClientRect(state.elements.reference);\n var popperOffsets = computeOffsets({\n reference: referenceClientRect,\n element: popperRect,\n strategy: 'absolute',\n placement: placement\n });\n var popperClientRect = rectToClientRect(Object.assign({}, popperRect, popperOffsets));\n var elementClientRect = elementContext === popper ? popperClientRect : referenceClientRect; // positive = overflowing the clipping rect\n // 0 or negative = within the clipping rect\n\n var overflowOffsets = {\n top: clippingClientRect.top - elementClientRect.top + paddingObject.top,\n bottom: elementClientRect.bottom - clippingClientRect.bottom + paddingObject.bottom,\n left: clippingClientRect.left - elementClientRect.left + paddingObject.left,\n right: elementClientRect.right - clippingClientRect.right + paddingObject.right\n };\n var offsetData = state.modifiersData.offset; // Offsets can be applied only to the popper element\n\n if (elementContext === popper && offsetData) {\n var offset = offsetData[placement];\n Object.keys(overflowOffsets).forEach(function (key) {\n var multiply = [right, bottom].indexOf(key) >= 0 ? 1 : -1;\n var axis = [top, bottom].indexOf(key) >= 0 ? 'y' : 'x';\n overflowOffsets[key] += offset[axis] * multiply;\n });\n }\n\n return overflowOffsets;\n}","import getVariation from \"./getVariation.js\";\nimport { variationPlacements, basePlacements, placements as allPlacements } from \"../enums.js\";\nimport detectOverflow from \"./detectOverflow.js\";\nimport getBasePlacement from \"./getBasePlacement.js\";\nexport default function computeAutoPlacement(state, options) {\n if (options === void 0) {\n options = {};\n }\n\n var _options = options,\n placement = _options.placement,\n boundary = _options.boundary,\n rootBoundary = _options.rootBoundary,\n padding = _options.padding,\n flipVariations = _options.flipVariations,\n _options$allowedAutoP = _options.allowedAutoPlacements,\n allowedAutoPlacements = _options$allowedAutoP === void 0 ? allPlacements : _options$allowedAutoP;\n var variation = getVariation(placement);\n var placements = variation ? flipVariations ? variationPlacements : variationPlacements.filter(function (placement) {\n return getVariation(placement) === variation;\n }) : basePlacements;\n var allowedPlacements = placements.filter(function (placement) {\n return allowedAutoPlacements.indexOf(placement) >= 0;\n });\n\n if (allowedPlacements.length === 0) {\n allowedPlacements = placements;\n } // $FlowFixMe[incompatible-type]: Flow seems to have problems with two array unions...\n\n\n var overflows = allowedPlacements.reduce(function (acc, placement) {\n acc[placement] = detectOverflow(state, {\n placement: placement,\n boundary: boundary,\n rootBoundary: rootBoundary,\n padding: padding\n })[getBasePlacement(placement)];\n return acc;\n }, {});\n return Object.keys(overflows).sort(function (a, b) {\n return overflows[a] - overflows[b];\n });\n}","import getOppositePlacement from \"../utils/getOppositePlacement.js\";\nimport getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getOppositeVariationPlacement from \"../utils/getOppositeVariationPlacement.js\";\nimport detectOverflow from \"../utils/detectOverflow.js\";\nimport computeAutoPlacement from \"../utils/computeAutoPlacement.js\";\nimport { bottom, top, start, right, left, auto } from \"../enums.js\";\nimport getVariation from \"../utils/getVariation.js\"; // eslint-disable-next-line import/no-unused-modules\n\nfunction getExpandedFallbackPlacements(placement) {\n if (getBasePlacement(placement) === auto) {\n return [];\n }\n\n var oppositePlacement = getOppositePlacement(placement);\n return [getOppositeVariationPlacement(placement), oppositePlacement, getOppositeVariationPlacement(oppositePlacement)];\n}\n\nfunction flip(_ref) {\n var state = _ref.state,\n options = _ref.options,\n name = _ref.name;\n\n if (state.modifiersData[name]._skip) {\n return;\n }\n\n var _options$mainAxis = options.mainAxis,\n checkMainAxis = _options$mainAxis === void 0 ? true : _options$mainAxis,\n _options$altAxis = options.altAxis,\n checkAltAxis = _options$altAxis === void 0 ? true : _options$altAxis,\n specifiedFallbackPlacements = options.fallbackPlacements,\n padding = options.padding,\n boundary = options.boundary,\n rootBoundary = options.rootBoundary,\n altBoundary = options.altBoundary,\n _options$flipVariatio = options.flipVariations,\n flipVariations = _options$flipVariatio === void 0 ? true : _options$flipVariatio,\n allowedAutoPlacements = options.allowedAutoPlacements;\n var preferredPlacement = state.options.placement;\n var basePlacement = getBasePlacement(preferredPlacement);\n var isBasePlacement = basePlacement === preferredPlacement;\n var fallbackPlacements = specifiedFallbackPlacements || (isBasePlacement || !flipVariations ? [getOppositePlacement(preferredPlacement)] : getExpandedFallbackPlacements(preferredPlacement));\n var placements = [preferredPlacement].concat(fallbackPlacements).reduce(function (acc, placement) {\n return acc.concat(getBasePlacement(placement) === auto ? computeAutoPlacement(state, {\n placement: placement,\n boundary: boundary,\n rootBoundary: rootBoundary,\n padding: padding,\n flipVariations: flipVariations,\n allowedAutoPlacements: allowedAutoPlacements\n }) : placement);\n }, []);\n var referenceRect = state.rects.reference;\n var popperRect = state.rects.popper;\n var checksMap = new Map();\n var makeFallbackChecks = true;\n var firstFittingPlacement = placements[0];\n\n for (var i = 0; i < placements.length; i++) {\n var placement = placements[i];\n\n var _basePlacement = getBasePlacement(placement);\n\n var isStartVariation = getVariation(placement) === start;\n var isVertical = [top, bottom].indexOf(_basePlacement) >= 0;\n var len = isVertical ? 'width' : 'height';\n var overflow = detectOverflow(state, {\n placement: placement,\n boundary: boundary,\n rootBoundary: rootBoundary,\n altBoundary: altBoundary,\n padding: padding\n });\n var mainVariationSide = isVertical ? isStartVariation ? right : left : isStartVariation ? bottom : top;\n\n if (referenceRect[len] > popperRect[len]) {\n mainVariationSide = getOppositePlacement(mainVariationSide);\n }\n\n var altVariationSide = getOppositePlacement(mainVariationSide);\n var checks = [];\n\n if (checkMainAxis) {\n checks.push(overflow[_basePlacement] <= 0);\n }\n\n if (checkAltAxis) {\n checks.push(overflow[mainVariationSide] <= 0, overflow[altVariationSide] <= 0);\n }\n\n if (checks.every(function (check) {\n return check;\n })) {\n firstFittingPlacement = placement;\n makeFallbackChecks = false;\n break;\n }\n\n checksMap.set(placement, checks);\n }\n\n if (makeFallbackChecks) {\n // `2` may be desired in some cases – research later\n var numberOfChecks = flipVariations ? 3 : 1;\n\n var _loop = function _loop(_i) {\n var fittingPlacement = placements.find(function (placement) {\n var checks = checksMap.get(placement);\n\n if (checks) {\n return checks.slice(0, _i).every(function (check) {\n return check;\n });\n }\n });\n\n if (fittingPlacement) {\n firstFittingPlacement = fittingPlacement;\n return \"break\";\n }\n };\n\n for (var _i = numberOfChecks; _i > 0; _i--) {\n var _ret = _loop(_i);\n\n if (_ret === \"break\") break;\n }\n }\n\n if (state.placement !== firstFittingPlacement) {\n state.modifiersData[name]._skip = true;\n state.placement = firstFittingPlacement;\n state.reset = true;\n }\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'flip',\n enabled: true,\n phase: 'main',\n fn: flip,\n requiresIfExists: ['offset'],\n data: {\n _skip: false\n }\n};","import { top, bottom, left, right } from \"../enums.js\";\nimport detectOverflow from \"../utils/detectOverflow.js\";\n\nfunction getSideOffsets(overflow, rect, preventedOffsets) {\n if (preventedOffsets === void 0) {\n preventedOffsets = {\n x: 0,\n y: 0\n };\n }\n\n return {\n top: overflow.top - rect.height - preventedOffsets.y,\n right: overflow.right - rect.width + preventedOffsets.x,\n bottom: overflow.bottom - rect.height + preventedOffsets.y,\n left: overflow.left - rect.width - preventedOffsets.x\n };\n}\n\nfunction isAnySideFullyClipped(overflow) {\n return [top, right, bottom, left].some(function (side) {\n return overflow[side] >= 0;\n });\n}\n\nfunction hide(_ref) {\n var state = _ref.state,\n name = _ref.name;\n var referenceRect = state.rects.reference;\n var popperRect = state.rects.popper;\n var preventedOffsets = state.modifiersData.preventOverflow;\n var referenceOverflow = detectOverflow(state, {\n elementContext: 'reference'\n });\n var popperAltOverflow = detectOverflow(state, {\n altBoundary: true\n });\n var referenceClippingOffsets = getSideOffsets(referenceOverflow, referenceRect);\n var popperEscapeOffsets = getSideOffsets(popperAltOverflow, popperRect, preventedOffsets);\n var isReferenceHidden = isAnySideFullyClipped(referenceClippingOffsets);\n var hasPopperEscaped = isAnySideFullyClipped(popperEscapeOffsets);\n state.modifiersData[name] = {\n referenceClippingOffsets: referenceClippingOffsets,\n popperEscapeOffsets: popperEscapeOffsets,\n isReferenceHidden: isReferenceHidden,\n hasPopperEscaped: hasPopperEscaped\n };\n state.attributes.popper = Object.assign({}, state.attributes.popper, {\n 'data-popper-reference-hidden': isReferenceHidden,\n 'data-popper-escaped': hasPopperEscaped\n });\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'hide',\n enabled: true,\n phase: 'main',\n requiresIfExists: ['preventOverflow'],\n fn: hide\n};","import getBasePlacement from \"../utils/getBasePlacement.js\";\nimport { top, left, right, placements } from \"../enums.js\"; // eslint-disable-next-line import/no-unused-modules\n\nexport function distanceAndSkiddingToXY(placement, rects, offset) {\n var basePlacement = getBasePlacement(placement);\n var invertDistance = [left, top].indexOf(basePlacement) >= 0 ? -1 : 1;\n\n var _ref = typeof offset === 'function' ? offset(Object.assign({}, rects, {\n placement: placement\n })) : offset,\n skidding = _ref[0],\n distance = _ref[1];\n\n skidding = skidding || 0;\n distance = (distance || 0) * invertDistance;\n return [left, right].indexOf(basePlacement) >= 0 ? {\n x: distance,\n y: skidding\n } : {\n x: skidding,\n y: distance\n };\n}\n\nfunction offset(_ref2) {\n var state = _ref2.state,\n options = _ref2.options,\n name = _ref2.name;\n var _options$offset = options.offset,\n offset = _options$offset === void 0 ? [0, 0] : _options$offset;\n var data = placements.reduce(function (acc, placement) {\n acc[placement] = distanceAndSkiddingToXY(placement, state.rects, offset);\n return acc;\n }, {});\n var _data$state$placement = data[state.placement],\n x = _data$state$placement.x,\n y = _data$state$placement.y;\n\n if (state.modifiersData.popperOffsets != null) {\n state.modifiersData.popperOffsets.x += x;\n state.modifiersData.popperOffsets.y += y;\n }\n\n state.modifiersData[name] = data;\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'offset',\n enabled: true,\n phase: 'main',\n requires: ['popperOffsets'],\n fn: offset\n};","import computeOffsets from \"../utils/computeOffsets.js\";\n\nfunction popperOffsets(_ref) {\n var state = _ref.state,\n name = _ref.name;\n // Offsets are the actual position the popper needs to have to be\n // properly positioned near its reference element\n // This is the most basic placement, and will be adjusted by\n // the modifiers in the next step\n state.modifiersData[name] = computeOffsets({\n reference: state.rects.reference,\n element: state.rects.popper,\n strategy: 'absolute',\n placement: state.placement\n });\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'popperOffsets',\n enabled: true,\n phase: 'read',\n fn: popperOffsets,\n data: {}\n};","export default function getAltAxis(axis) {\n return axis === 'x' ? 'y' : 'x';\n}","import { top, left, right, bottom, start } from \"../enums.js\";\nimport getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getMainAxisFromPlacement from \"../utils/getMainAxisFromPlacement.js\";\nimport getAltAxis from \"../utils/getAltAxis.js\";\nimport { within, withinMaxClamp } from \"../utils/within.js\";\nimport getLayoutRect from \"../dom-utils/getLayoutRect.js\";\nimport getOffsetParent from \"../dom-utils/getOffsetParent.js\";\nimport detectOverflow from \"../utils/detectOverflow.js\";\nimport getVariation from \"../utils/getVariation.js\";\nimport getFreshSideObject from \"../utils/getFreshSideObject.js\";\nimport { min as mathMin, max as mathMax } from \"../utils/math.js\";\n\nfunction preventOverflow(_ref) {\n var state = _ref.state,\n options = _ref.options,\n name = _ref.name;\n var _options$mainAxis = options.mainAxis,\n checkMainAxis = _options$mainAxis === void 0 ? true : _options$mainAxis,\n _options$altAxis = options.altAxis,\n checkAltAxis = _options$altAxis === void 0 ? false : _options$altAxis,\n boundary = options.boundary,\n rootBoundary = options.rootBoundary,\n altBoundary = options.altBoundary,\n padding = options.padding,\n _options$tether = options.tether,\n tether = _options$tether === void 0 ? true : _options$tether,\n _options$tetherOffset = options.tetherOffset,\n tetherOffset = _options$tetherOffset === void 0 ? 0 : _options$tetherOffset;\n var overflow = detectOverflow(state, {\n boundary: boundary,\n rootBoundary: rootBoundary,\n padding: padding,\n altBoundary: altBoundary\n });\n var basePlacement = getBasePlacement(state.placement);\n var variation = getVariation(state.placement);\n var isBasePlacement = !variation;\n var mainAxis = getMainAxisFromPlacement(basePlacement);\n var altAxis = getAltAxis(mainAxis);\n var popperOffsets = state.modifiersData.popperOffsets;\n var referenceRect = state.rects.reference;\n var popperRect = state.rects.popper;\n var tetherOffsetValue = typeof tetherOffset === 'function' ? tetherOffset(Object.assign({}, state.rects, {\n placement: state.placement\n })) : tetherOffset;\n var normalizedTetherOffsetValue = typeof tetherOffsetValue === 'number' ? {\n mainAxis: tetherOffsetValue,\n altAxis: tetherOffsetValue\n } : Object.assign({\n mainAxis: 0,\n altAxis: 0\n }, tetherOffsetValue);\n var offsetModifierState = state.modifiersData.offset ? state.modifiersData.offset[state.placement] : null;\n var data = {\n x: 0,\n y: 0\n };\n\n if (!popperOffsets) {\n return;\n }\n\n if (checkMainAxis) {\n var _offsetModifierState$;\n\n var mainSide = mainAxis === 'y' ? top : left;\n var altSide = mainAxis === 'y' ? bottom : right;\n var len = mainAxis === 'y' ? 'height' : 'width';\n var offset = popperOffsets[mainAxis];\n var min = offset + overflow[mainSide];\n var max = offset - overflow[altSide];\n var additive = tether ? -popperRect[len] / 2 : 0;\n var minLen = variation === start ? referenceRect[len] : popperRect[len];\n var maxLen = variation === start ? -popperRect[len] : -referenceRect[len]; // We need to include the arrow in the calculation so the arrow doesn't go\n // outside the reference bounds\n\n var arrowElement = state.elements.arrow;\n var arrowRect = tether && arrowElement ? getLayoutRect(arrowElement) : {\n width: 0,\n height: 0\n };\n var arrowPaddingObject = state.modifiersData['arrow#persistent'] ? state.modifiersData['arrow#persistent'].padding : getFreshSideObject();\n var arrowPaddingMin = arrowPaddingObject[mainSide];\n var arrowPaddingMax = arrowPaddingObject[altSide]; // If the reference length is smaller than the arrow length, we don't want\n // to include its full size in the calculation. If the reference is small\n // and near the edge of a boundary, the popper can overflow even if the\n // reference is not overflowing as well (e.g. virtual elements with no\n // width or height)\n\n var arrowLen = within(0, referenceRect[len], arrowRect[len]);\n var minOffset = isBasePlacement ? referenceRect[len] / 2 - additive - arrowLen - arrowPaddingMin - normalizedTetherOffsetValue.mainAxis : minLen - arrowLen - arrowPaddingMin - normalizedTetherOffsetValue.mainAxis;\n var maxOffset = isBasePlacement ? -referenceRect[len] / 2 + additive + arrowLen + arrowPaddingMax + normalizedTetherOffsetValue.mainAxis : maxLen + arrowLen + arrowPaddingMax + normalizedTetherOffsetValue.mainAxis;\n var arrowOffsetParent = state.elements.arrow && getOffsetParent(state.elements.arrow);\n var clientOffset = arrowOffsetParent ? mainAxis === 'y' ? arrowOffsetParent.clientTop || 0 : arrowOffsetParent.clientLeft || 0 : 0;\n var offsetModifierValue = (_offsetModifierState$ = offsetModifierState == null ? void 0 : offsetModifierState[mainAxis]) != null ? _offsetModifierState$ : 0;\n var tetherMin = offset + minOffset - offsetModifierValue - clientOffset;\n var tetherMax = offset + maxOffset - offsetModifierValue;\n var preventedOffset = within(tether ? mathMin(min, tetherMin) : min, offset, tether ? mathMax(max, tetherMax) : max);\n popperOffsets[mainAxis] = preventedOffset;\n data[mainAxis] = preventedOffset - offset;\n }\n\n if (checkAltAxis) {\n var _offsetModifierState$2;\n\n var _mainSide = mainAxis === 'x' ? top : left;\n\n var _altSide = mainAxis === 'x' ? bottom : right;\n\n var _offset = popperOffsets[altAxis];\n\n var _len = altAxis === 'y' ? 'height' : 'width';\n\n var _min = _offset + overflow[_mainSide];\n\n var _max = _offset - overflow[_altSide];\n\n var isOriginSide = [top, left].indexOf(basePlacement) !== -1;\n\n var _offsetModifierValue = (_offsetModifierState$2 = offsetModifierState == null ? void 0 : offsetModifierState[altAxis]) != null ? _offsetModifierState$2 : 0;\n\n var _tetherMin = isOriginSide ? _min : _offset - referenceRect[_len] - popperRect[_len] - _offsetModifierValue + normalizedTetherOffsetValue.altAxis;\n\n var _tetherMax = isOriginSide ? _offset + referenceRect[_len] + popperRect[_len] - _offsetModifierValue - normalizedTetherOffsetValue.altAxis : _max;\n\n var _preventedOffset = tether && isOriginSide ? withinMaxClamp(_tetherMin, _offset, _tetherMax) : within(tether ? _tetherMin : _min, _offset, tether ? _tetherMax : _max);\n\n popperOffsets[altAxis] = _preventedOffset;\n data[altAxis] = _preventedOffset - _offset;\n }\n\n state.modifiersData[name] = data;\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'preventOverflow',\n enabled: true,\n phase: 'main',\n fn: preventOverflow,\n requiresIfExists: ['offset']\n};","export default function getHTMLElementScroll(element) {\n return {\n scrollLeft: element.scrollLeft,\n scrollTop: element.scrollTop\n };\n}","import getWindowScroll from \"./getWindowScroll.js\";\nimport getWindow from \"./getWindow.js\";\nimport { isHTMLElement } from \"./instanceOf.js\";\nimport getHTMLElementScroll from \"./getHTMLElementScroll.js\";\nexport default function getNodeScroll(node) {\n if (node === getWindow(node) || !isHTMLElement(node)) {\n return getWindowScroll(node);\n } else {\n return getHTMLElementScroll(node);\n }\n}","import getBoundingClientRect from \"./getBoundingClientRect.js\";\nimport getNodeScroll from \"./getNodeScroll.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport { isHTMLElement } from \"./instanceOf.js\";\nimport getWindowScrollBarX from \"./getWindowScrollBarX.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport isScrollParent from \"./isScrollParent.js\";\nimport { round } from \"../utils/math.js\";\n\nfunction isElementScaled(element) {\n var rect = element.getBoundingClientRect();\n var scaleX = round(rect.width) / element.offsetWidth || 1;\n var scaleY = round(rect.height) / element.offsetHeight || 1;\n return scaleX !== 1 || scaleY !== 1;\n} // Returns the composite rect of an element relative to its offsetParent.\n// Composite means it takes into account transforms as well as layout.\n\n\nexport default function getCompositeRect(elementOrVirtualElement, offsetParent, isFixed) {\n if (isFixed === void 0) {\n isFixed = false;\n }\n\n var isOffsetParentAnElement = isHTMLElement(offsetParent);\n var offsetParentIsScaled = isHTMLElement(offsetParent) && isElementScaled(offsetParent);\n var documentElement = getDocumentElement(offsetParent);\n var rect = getBoundingClientRect(elementOrVirtualElement, offsetParentIsScaled, isFixed);\n var scroll = {\n scrollLeft: 0,\n scrollTop: 0\n };\n var offsets = {\n x: 0,\n y: 0\n };\n\n if (isOffsetParentAnElement || !isOffsetParentAnElement && !isFixed) {\n if (getNodeName(offsetParent) !== 'body' || // https://github.com/popperjs/popper-core/issues/1078\n isScrollParent(documentElement)) {\n scroll = getNodeScroll(offsetParent);\n }\n\n if (isHTMLElement(offsetParent)) {\n offsets = getBoundingClientRect(offsetParent, true);\n offsets.x += offsetParent.clientLeft;\n offsets.y += offsetParent.clientTop;\n } else if (documentElement) {\n offsets.x = getWindowScrollBarX(documentElement);\n }\n }\n\n return {\n x: rect.left + scroll.scrollLeft - offsets.x,\n y: rect.top + scroll.scrollTop - offsets.y,\n width: rect.width,\n height: rect.height\n };\n}","import { modifierPhases } from \"../enums.js\"; // source: https://stackoverflow.com/questions/49875255\n\nfunction order(modifiers) {\n var map = new Map();\n var visited = new Set();\n var result = [];\n modifiers.forEach(function (modifier) {\n map.set(modifier.name, modifier);\n }); // On visiting object, check for its dependencies and visit them recursively\n\n function sort(modifier) {\n visited.add(modifier.name);\n var requires = [].concat(modifier.requires || [], modifier.requiresIfExists || []);\n requires.forEach(function (dep) {\n if (!visited.has(dep)) {\n var depModifier = map.get(dep);\n\n if (depModifier) {\n sort(depModifier);\n }\n }\n });\n result.push(modifier);\n }\n\n modifiers.forEach(function (modifier) {\n if (!visited.has(modifier.name)) {\n // check for visited object\n sort(modifier);\n }\n });\n return result;\n}\n\nexport default function orderModifiers(modifiers) {\n // order based on dependencies\n var orderedModifiers = order(modifiers); // order based on phase\n\n return modifierPhases.reduce(function (acc, phase) {\n return acc.concat(orderedModifiers.filter(function (modifier) {\n return modifier.phase === phase;\n }));\n }, []);\n}","export default function debounce(fn) {\n var pending;\n return function () {\n if (!pending) {\n pending = new Promise(function (resolve) {\n Promise.resolve().then(function () {\n pending = undefined;\n resolve(fn());\n });\n });\n }\n\n return pending;\n };\n}","export default function mergeByName(modifiers) {\n var merged = modifiers.reduce(function (merged, current) {\n var existing = merged[current.name];\n merged[current.name] = existing ? Object.assign({}, existing, current, {\n options: Object.assign({}, existing.options, current.options),\n data: Object.assign({}, existing.data, current.data)\n }) : current;\n return merged;\n }, {}); // IE11 does not support Object.values\n\n return Object.keys(merged).map(function (key) {\n return merged[key];\n });\n}","import getCompositeRect from \"./dom-utils/getCompositeRect.js\";\nimport getLayoutRect from \"./dom-utils/getLayoutRect.js\";\nimport listScrollParents from \"./dom-utils/listScrollParents.js\";\nimport getOffsetParent from \"./dom-utils/getOffsetParent.js\";\nimport orderModifiers from \"./utils/orderModifiers.js\";\nimport debounce from \"./utils/debounce.js\";\nimport mergeByName from \"./utils/mergeByName.js\";\nimport detectOverflow from \"./utils/detectOverflow.js\";\nimport { isElement } from \"./dom-utils/instanceOf.js\";\nvar DEFAULT_OPTIONS = {\n placement: 'bottom',\n modifiers: [],\n strategy: 'absolute'\n};\n\nfunction areValidElements() {\n for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {\n args[_key] = arguments[_key];\n }\n\n return !args.some(function (element) {\n return !(element && typeof element.getBoundingClientRect === 'function');\n });\n}\n\nexport function popperGenerator(generatorOptions) {\n if (generatorOptions === void 0) {\n generatorOptions = {};\n }\n\n var _generatorOptions = generatorOptions,\n _generatorOptions$def = _generatorOptions.defaultModifiers,\n defaultModifiers = _generatorOptions$def === void 0 ? [] : _generatorOptions$def,\n _generatorOptions$def2 = _generatorOptions.defaultOptions,\n defaultOptions = _generatorOptions$def2 === void 0 ? DEFAULT_OPTIONS : _generatorOptions$def2;\n return function createPopper(reference, popper, options) {\n if (options === void 0) {\n options = defaultOptions;\n }\n\n var state = {\n placement: 'bottom',\n orderedModifiers: [],\n options: Object.assign({}, DEFAULT_OPTIONS, defaultOptions),\n modifiersData: {},\n elements: {\n reference: reference,\n popper: popper\n },\n attributes: {},\n styles: {}\n };\n var effectCleanupFns = [];\n var isDestroyed = false;\n var instance = {\n state: state,\n setOptions: function setOptions(setOptionsAction) {\n var options = typeof setOptionsAction === 'function' ? setOptionsAction(state.options) : setOptionsAction;\n cleanupModifierEffects();\n state.options = Object.assign({}, defaultOptions, state.options, options);\n state.scrollParents = {\n reference: isElement(reference) ? listScrollParents(reference) : reference.contextElement ? listScrollParents(reference.contextElement) : [],\n popper: listScrollParents(popper)\n }; // Orders the modifiers based on their dependencies and `phase`\n // properties\n\n var orderedModifiers = orderModifiers(mergeByName([].concat(defaultModifiers, state.options.modifiers))); // Strip out disabled modifiers\n\n state.orderedModifiers = orderedModifiers.filter(function (m) {\n return m.enabled;\n });\n runModifierEffects();\n return instance.update();\n },\n // Sync update – it will always be executed, even if not necessary. This\n // is useful for low frequency updates where sync behavior simplifies the\n // logic.\n // For high frequency updates (e.g. `resize` and `scroll` events), always\n // prefer the async Popper#update method\n forceUpdate: function forceUpdate() {\n if (isDestroyed) {\n return;\n }\n\n var _state$elements = state.elements,\n reference = _state$elements.reference,\n popper = _state$elements.popper; // Don't proceed if `reference` or `popper` are not valid elements\n // anymore\n\n if (!areValidElements(reference, popper)) {\n return;\n } // Store the reference and popper rects to be read by modifiers\n\n\n state.rects = {\n reference: getCompositeRect(reference, getOffsetParent(popper), state.options.strategy === 'fixed'),\n popper: getLayoutRect(popper)\n }; // Modifiers have the ability to reset the current update cycle. The\n // most common use case for this is the `flip` modifier changing the\n // placement, which then needs to re-run all the modifiers, because the\n // logic was previously ran for the previous placement and is therefore\n // stale/incorrect\n\n state.reset = false;\n state.placement = state.options.placement; // On each update cycle, the `modifiersData` property for each modifier\n // is filled with the initial data specified by the modifier. This means\n // it doesn't persist and is fresh on each update.\n // To ensure persistent data, use `${name}#persistent`\n\n state.orderedModifiers.forEach(function (modifier) {\n return state.modifiersData[modifier.name] = Object.assign({}, modifier.data);\n });\n\n for (var index = 0; index < state.orderedModifiers.length; index++) {\n if (state.reset === true) {\n state.reset = false;\n index = -1;\n continue;\n }\n\n var _state$orderedModifie = state.orderedModifiers[index],\n fn = _state$orderedModifie.fn,\n _state$orderedModifie2 = _state$orderedModifie.options,\n _options = _state$orderedModifie2 === void 0 ? {} : _state$orderedModifie2,\n name = _state$orderedModifie.name;\n\n if (typeof fn === 'function') {\n state = fn({\n state: state,\n options: _options,\n name: name,\n instance: instance\n }) || state;\n }\n }\n },\n // Async and optimistically optimized update – it will not be executed if\n // not necessary (debounced to run at most once-per-tick)\n update: debounce(function () {\n return new Promise(function (resolve) {\n instance.forceUpdate();\n resolve(state);\n });\n }),\n destroy: function destroy() {\n cleanupModifierEffects();\n isDestroyed = true;\n }\n };\n\n if (!areValidElements(reference, popper)) {\n return instance;\n }\n\n instance.setOptions(options).then(function (state) {\n if (!isDestroyed && options.onFirstUpdate) {\n options.onFirstUpdate(state);\n }\n }); // Modifiers have the ability to execute arbitrary code before the first\n // update cycle runs. They will be executed in the same order as the update\n // cycle. This is useful when a modifier adds some persistent data that\n // other modifiers need to use, but the modifier is run after the dependent\n // one.\n\n function runModifierEffects() {\n state.orderedModifiers.forEach(function (_ref) {\n var name = _ref.name,\n _ref$options = _ref.options,\n options = _ref$options === void 0 ? {} : _ref$options,\n effect = _ref.effect;\n\n if (typeof effect === 'function') {\n var cleanupFn = effect({\n state: state,\n name: name,\n instance: instance,\n options: options\n });\n\n var noopFn = function noopFn() {};\n\n effectCleanupFns.push(cleanupFn || noopFn);\n }\n });\n }\n\n function cleanupModifierEffects() {\n effectCleanupFns.forEach(function (fn) {\n return fn();\n });\n effectCleanupFns = [];\n }\n\n return instance;\n };\n}\nexport var createPopper = /*#__PURE__*/popperGenerator(); // eslint-disable-next-line import/no-unused-modules\n\nexport { detectOverflow };","import { popperGenerator, detectOverflow } from \"./createPopper.js\";\nimport eventListeners from \"./modifiers/eventListeners.js\";\nimport popperOffsets from \"./modifiers/popperOffsets.js\";\nimport computeStyles from \"./modifiers/computeStyles.js\";\nimport applyStyles from \"./modifiers/applyStyles.js\";\nimport offset from \"./modifiers/offset.js\";\nimport flip from \"./modifiers/flip.js\";\nimport preventOverflow from \"./modifiers/preventOverflow.js\";\nimport arrow from \"./modifiers/arrow.js\";\nimport hide from \"./modifiers/hide.js\";\nvar defaultModifiers = [eventListeners, popperOffsets, computeStyles, applyStyles, offset, flip, preventOverflow, arrow, hide];\nvar createPopper = /*#__PURE__*/popperGenerator({\n defaultModifiers: defaultModifiers\n}); // eslint-disable-next-line import/no-unused-modules\n\nexport { createPopper, popperGenerator, defaultModifiers, detectOverflow }; // eslint-disable-next-line import/no-unused-modules\n\nexport { createPopper as createPopperLite } from \"./popper-lite.js\"; // eslint-disable-next-line import/no-unused-modules\n\nexport * from \"./modifiers/index.js\";","import { generateUtilityClass } from '../generateUtilityClass';\nimport { generateUtilityClasses } from '../generateUtilityClasses';\nconst COMPONENT_NAME = 'Popper';\nexport function getPopperUtilityClass(slot) {\n return generateUtilityClass(COMPONENT_NAME, slot);\n}\nexport const popperClasses = generateUtilityClasses(COMPONENT_NAME, ['root']);","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"anchorEl\", \"children\", \"direction\", \"disablePortal\", \"modifiers\", \"open\", \"placement\", \"popperOptions\", \"popperRef\", \"slotProps\", \"slots\", \"TransitionProps\", \"ownerState\"],\n _excluded2 = [\"anchorEl\", \"children\", \"container\", \"direction\", \"disablePortal\", \"keepMounted\", \"modifiers\", \"open\", \"placement\", \"popperOptions\", \"popperRef\", \"style\", \"transition\", \"slotProps\", \"slots\"];\nimport * as React from 'react';\nimport { chainPropTypes, HTMLElementType, refType, unstable_ownerDocument as ownerDocument, unstable_useEnhancedEffect as useEnhancedEffect, unstable_useForkRef as useForkRef } from '@mui/utils';\nimport { createPopper } from '@popperjs/core';\nimport PropTypes from 'prop-types';\nimport { unstable_composeClasses as composeClasses } from '../composeClasses';\nimport { Portal } from '../Portal';\nimport { getPopperUtilityClass } from './popperClasses';\nimport { useSlotProps } from '../utils';\nimport { useClassNamesOverride } from '../utils/ClassNameConfigurator';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nfunction flipPlacement(placement, direction) {\n if (direction === 'ltr') {\n return placement;\n }\n switch (placement) {\n case 'bottom-end':\n return 'bottom-start';\n case 'bottom-start':\n return 'bottom-end';\n case 'top-end':\n return 'top-start';\n case 'top-start':\n return 'top-end';\n default:\n return placement;\n }\n}\nfunction resolveAnchorEl(anchorEl) {\n return typeof anchorEl === 'function' ? anchorEl() : anchorEl;\n}\nfunction isHTMLElement(element) {\n return element.nodeType !== undefined;\n}\nfunction isVirtualElement(element) {\n return !isHTMLElement(element);\n}\nconst useUtilityClasses = () => {\n const slots = {\n root: ['root']\n };\n return composeClasses(slots, useClassNamesOverride(getPopperUtilityClass));\n};\nconst defaultPopperOptions = {};\nconst PopperTooltip = /*#__PURE__*/React.forwardRef(function PopperTooltip(props, forwardedRef) {\n var _slots$root;\n const {\n anchorEl,\n children,\n direction,\n disablePortal,\n modifiers,\n open,\n placement: initialPlacement,\n popperOptions,\n popperRef: popperRefProp,\n slotProps = {},\n slots = {},\n TransitionProps\n // @ts-ignore internal logic\n // prevent from spreading to DOM, it can come from the parent component e.g. Select.\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const tooltipRef = React.useRef(null);\n const ownRef = useForkRef(tooltipRef, forwardedRef);\n const popperRef = React.useRef(null);\n const handlePopperRef = useForkRef(popperRef, popperRefProp);\n const handlePopperRefRef = React.useRef(handlePopperRef);\n useEnhancedEffect(() => {\n handlePopperRefRef.current = handlePopperRef;\n }, [handlePopperRef]);\n React.useImperativeHandle(popperRefProp, () => popperRef.current, []);\n const rtlPlacement = flipPlacement(initialPlacement, direction);\n /**\n * placement initialized from prop but can change during lifetime if modifiers.flip.\n * modifiers.flip is essentially a flip for controlled/uncontrolled behavior\n */\n const [placement, setPlacement] = React.useState(rtlPlacement);\n const [resolvedAnchorElement, setResolvedAnchorElement] = React.useState(resolveAnchorEl(anchorEl));\n React.useEffect(() => {\n if (popperRef.current) {\n popperRef.current.forceUpdate();\n }\n });\n React.useEffect(() => {\n if (anchorEl) {\n setResolvedAnchorElement(resolveAnchorEl(anchorEl));\n }\n }, [anchorEl]);\n useEnhancedEffect(() => {\n if (!resolvedAnchorElement || !open) {\n return undefined;\n }\n const handlePopperUpdate = data => {\n setPlacement(data.placement);\n };\n if (process.env.NODE_ENV !== 'production') {\n if (resolvedAnchorElement && isHTMLElement(resolvedAnchorElement) && resolvedAnchorElement.nodeType === 1) {\n const box = resolvedAnchorElement.getBoundingClientRect();\n if (process.env.NODE_ENV !== 'test' && box.top === 0 && box.left === 0 && box.right === 0 && box.bottom === 0) {\n console.warn(['MUI: The `anchorEl` prop provided to the component is invalid.', 'The anchor element should be part of the document layout.', \"Make sure the element is present in the document or that it's not display none.\"].join('\\n'));\n }\n }\n }\n let popperModifiers = [{\n name: 'preventOverflow',\n options: {\n altBoundary: disablePortal\n }\n }, {\n name: 'flip',\n options: {\n altBoundary: disablePortal\n }\n }, {\n name: 'onUpdate',\n enabled: true,\n phase: 'afterWrite',\n fn: ({\n state\n }) => {\n handlePopperUpdate(state);\n }\n }];\n if (modifiers != null) {\n popperModifiers = popperModifiers.concat(modifiers);\n }\n if (popperOptions && popperOptions.modifiers != null) {\n popperModifiers = popperModifiers.concat(popperOptions.modifiers);\n }\n const popper = createPopper(resolvedAnchorElement, tooltipRef.current, _extends({\n placement: rtlPlacement\n }, popperOptions, {\n modifiers: popperModifiers\n }));\n handlePopperRefRef.current(popper);\n return () => {\n popper.destroy();\n handlePopperRefRef.current(null);\n };\n }, [resolvedAnchorElement, disablePortal, modifiers, open, popperOptions, rtlPlacement]);\n const childProps = {\n placement: placement\n };\n if (TransitionProps !== null) {\n childProps.TransitionProps = TransitionProps;\n }\n const classes = useUtilityClasses();\n const Root = (_slots$root = slots.root) != null ? _slots$root : 'div';\n const rootProps = useSlotProps({\n elementType: Root,\n externalSlotProps: slotProps.root,\n externalForwardedProps: other,\n additionalProps: {\n role: 'tooltip',\n ref: ownRef\n },\n ownerState: props,\n className: classes.root\n });\n return /*#__PURE__*/_jsx(Root, _extends({}, rootProps, {\n children: typeof children === 'function' ? children(childProps) : children\n }));\n});\n\n/**\n * Poppers rely on the 3rd party library [Popper.js](https://popper.js.org/docs/v2/) for positioning.\n *\n * Demos:\n *\n * - [Popper](https://mui.com/base-ui/react-popper/)\n *\n * API:\n *\n * - [Popper API](https://mui.com/base-ui/react-popper/components-api/#popper)\n */\nconst Popper = /*#__PURE__*/React.forwardRef(function Popper(props, forwardedRef) {\n const {\n anchorEl,\n children,\n container: containerProp,\n direction = 'ltr',\n disablePortal = false,\n keepMounted = false,\n modifiers,\n open,\n placement = 'bottom',\n popperOptions = defaultPopperOptions,\n popperRef,\n style,\n transition = false,\n slotProps = {},\n slots = {}\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded2);\n const [exited, setExited] = React.useState(true);\n const handleEnter = () => {\n setExited(false);\n };\n const handleExited = () => {\n setExited(true);\n };\n if (!keepMounted && !open && (!transition || exited)) {\n return null;\n }\n\n // If the container prop is provided, use that\n // If the anchorEl prop is provided, use its parent body element as the container\n // If neither are provided let the Modal take care of choosing the container\n let container;\n if (containerProp) {\n container = containerProp;\n } else if (anchorEl) {\n const resolvedAnchorEl = resolveAnchorEl(anchorEl);\n container = resolvedAnchorEl && isHTMLElement(resolvedAnchorEl) ? ownerDocument(resolvedAnchorEl).body : ownerDocument(null).body;\n }\n const display = !open && keepMounted && (!transition || exited) ? 'none' : undefined;\n const transitionProps = transition ? {\n in: open,\n onEnter: handleEnter,\n onExited: handleExited\n } : undefined;\n return /*#__PURE__*/_jsx(Portal, {\n disablePortal: disablePortal,\n container: container,\n children: /*#__PURE__*/_jsx(PopperTooltip, _extends({\n anchorEl: anchorEl,\n direction: direction,\n disablePortal: disablePortal,\n modifiers: modifiers,\n ref: forwardedRef,\n open: transition ? !exited : open,\n placement: placement,\n popperOptions: popperOptions,\n popperRef: popperRef,\n slotProps: slotProps,\n slots: slots\n }, other, {\n style: _extends({\n // Prevents scroll issue, waiting for Popper.js to add this style once initiated.\n position: 'fixed',\n // Fix Popper.js display issue\n top: 0,\n left: 0,\n display\n }, style),\n TransitionProps: transitionProps,\n children: children\n }))\n });\n});\nprocess.env.NODE_ENV !== \"production\" ? Popper.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * An HTML element, [virtualElement](https://popper.js.org/docs/v2/virtual-elements/),\n * or a function that returns either.\n * It's used to set the position of the popper.\n * The return value will passed as the reference object of the Popper instance.\n */\n anchorEl: chainPropTypes(PropTypes.oneOfType([HTMLElementType, PropTypes.object, PropTypes.func]), props => {\n if (props.open) {\n const resolvedAnchorEl = resolveAnchorEl(props.anchorEl);\n if (resolvedAnchorEl && isHTMLElement(resolvedAnchorEl) && resolvedAnchorEl.nodeType === 1) {\n const box = resolvedAnchorEl.getBoundingClientRect();\n if (process.env.NODE_ENV !== 'test' && box.top === 0 && box.left === 0 && box.right === 0 && box.bottom === 0) {\n return new Error(['MUI: The `anchorEl` prop provided to the component is invalid.', 'The anchor element should be part of the document layout.', \"Make sure the element is present in the document or that it's not display none.\"].join('\\n'));\n }\n } else if (!resolvedAnchorEl || typeof resolvedAnchorEl.getBoundingClientRect !== 'function' || isVirtualElement(resolvedAnchorEl) && resolvedAnchorEl.contextElement != null && resolvedAnchorEl.contextElement.nodeType !== 1) {\n return new Error(['MUI: The `anchorEl` prop provided to the component is invalid.', 'It should be an HTML element instance or a virtualElement ', '(https://popper.js.org/docs/v2/virtual-elements/).'].join('\\n'));\n }\n }\n return null;\n }),\n /**\n * Popper render function or node.\n */\n children: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.node, PropTypes.func]),\n /**\n * An HTML element or function that returns one.\n * The `container` will have the portal children appended to it.\n *\n * You can also provide a callback, which is called in a React layout effect.\n * This lets you set the container from a ref, and also makes server-side rendering possible.\n *\n * By default, it uses the body of the top-level document object,\n * so it's simply `document.body` most of the time.\n */\n container: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.func]),\n /**\n * Direction of the text.\n * @default 'ltr'\n */\n direction: PropTypes.oneOf(['ltr', 'rtl']),\n /**\n * The `children` will be under the DOM hierarchy of the parent component.\n * @default false\n */\n disablePortal: PropTypes.bool,\n /**\n * Always keep the children in the DOM.\n * This prop can be useful in SEO situation or\n * when you want to maximize the responsiveness of the Popper.\n * @default false\n */\n keepMounted: PropTypes.bool,\n /**\n * Popper.js is based on a \"plugin-like\" architecture,\n * most of its features are fully encapsulated \"modifiers\".\n *\n * A modifier is a function that is called each time Popper.js needs to\n * compute the position of the popper.\n * For this reason, modifiers should be very performant to avoid bottlenecks.\n * To learn how to create a modifier, [read the modifiers documentation](https://popper.js.org/docs/v2/modifiers/).\n */\n modifiers: PropTypes.arrayOf(PropTypes.shape({\n data: PropTypes.object,\n effect: PropTypes.func,\n enabled: PropTypes.bool,\n fn: PropTypes.func,\n name: PropTypes.any,\n options: PropTypes.object,\n phase: PropTypes.oneOf(['afterMain', 'afterRead', 'afterWrite', 'beforeMain', 'beforeRead', 'beforeWrite', 'main', 'read', 'write']),\n requires: PropTypes.arrayOf(PropTypes.string),\n requiresIfExists: PropTypes.arrayOf(PropTypes.string)\n })),\n /**\n * If `true`, the component is shown.\n */\n open: PropTypes.bool.isRequired,\n /**\n * Popper placement.\n * @default 'bottom'\n */\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n /**\n * Options provided to the [`Popper.js`](https://popper.js.org/docs/v2/constructors/#options) instance.\n * @default {}\n */\n popperOptions: PropTypes.shape({\n modifiers: PropTypes.array,\n onFirstUpdate: PropTypes.func,\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n strategy: PropTypes.oneOf(['absolute', 'fixed'])\n }),\n /**\n * A ref that points to the used popper instance.\n */\n popperRef: refType,\n /**\n * The props used for each slot inside the Popper.\n * @default {}\n */\n slotProps: PropTypes.shape({\n root: PropTypes.oneOfType([PropTypes.func, PropTypes.object])\n }),\n /**\n * The components used for each slot inside the Popper.\n * Either a string to use a HTML element or a component.\n * @default {}\n */\n slots: PropTypes.shape({\n root: PropTypes.elementType\n }),\n /**\n * Help supporting a react-transition-group/Transition component.\n * @default false\n */\n transition: PropTypes.bool\n} : void 0;\nexport { Popper };","'use client';\n\nimport * as React from 'react';\nimport { useTheme as useThemeSystem } from '@mui/system';\nimport defaultTheme from './defaultTheme';\nimport THEME_ID from './identifier';\nexport default function useTheme() {\n const theme = useThemeSystem(defaultTheme);\n if (process.env.NODE_ENV !== 'production') {\n // eslint-disable-next-line react-hooks/rules-of-hooks\n React.useDebugValue(theme);\n }\n return theme[THEME_ID] || theme;\n}","export default function _setPrototypeOf(o, p) {\n _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function _setPrototypeOf(o, p) {\n o.__proto__ = p;\n return o;\n };\n return _setPrototypeOf(o, p);\n}","import setPrototypeOf from \"./setPrototypeOf.js\";\nexport default function _inheritsLoose(subClass, superClass) {\n subClass.prototype = Object.create(superClass.prototype);\n subClass.prototype.constructor = subClass;\n setPrototypeOf(subClass, superClass);\n}","export default {\n disabled: false\n};","import PropTypes from 'prop-types';\nexport var timeoutsShape = process.env.NODE_ENV !== 'production' ? PropTypes.oneOfType([PropTypes.number, PropTypes.shape({\n enter: PropTypes.number,\n exit: PropTypes.number,\n appear: PropTypes.number\n}).isRequired]) : null;\nexport var classNamesShape = process.env.NODE_ENV !== 'production' ? PropTypes.oneOfType([PropTypes.string, PropTypes.shape({\n enter: PropTypes.string,\n exit: PropTypes.string,\n active: PropTypes.string\n}), PropTypes.shape({\n enter: PropTypes.string,\n enterDone: PropTypes.string,\n enterActive: PropTypes.string,\n exit: PropTypes.string,\n exitDone: PropTypes.string,\n exitActive: PropTypes.string\n})]) : null;","import React from 'react';\nexport default React.createContext(null);","export var forceReflow = function forceReflow(node) {\n return node.scrollTop;\n};","import _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _inheritsLoose from \"@babel/runtime/helpers/esm/inheritsLoose\";\nimport PropTypes from 'prop-types';\nimport React from 'react';\nimport ReactDOM from 'react-dom';\nimport config from './config';\nimport { timeoutsShape } from './utils/PropTypes';\nimport TransitionGroupContext from './TransitionGroupContext';\nimport { forceReflow } from './utils/reflow';\nexport var UNMOUNTED = 'unmounted';\nexport var EXITED = 'exited';\nexport var ENTERING = 'entering';\nexport var ENTERED = 'entered';\nexport var EXITING = 'exiting';\n/**\n * The Transition component lets you describe a transition from one component\n * state to another _over time_ with a simple declarative API. Most commonly\n * it's used to animate the mounting and unmounting of a component, but can also\n * be used to describe in-place transition states as well.\n *\n * ---\n *\n * **Note**: `Transition` is a platform-agnostic base component. If you're using\n * transitions in CSS, you'll probably want to use\n * [`CSSTransition`](https://reactcommunity.org/react-transition-group/css-transition)\n * instead. It inherits all the features of `Transition`, but contains\n * additional features necessary to play nice with CSS transitions (hence the\n * name of the component).\n *\n * ---\n *\n * By default the `Transition` component does not alter the behavior of the\n * component it renders, it only tracks \"enter\" and \"exit\" states for the\n * components. It's up to you to give meaning and effect to those states. For\n * example we can add styles to a component when it enters or exits:\n *\n * ```jsx\n * import { Transition } from 'react-transition-group';\n *\n * const duration = 300;\n *\n * const defaultStyle = {\n * transition: `opacity ${duration}ms ease-in-out`,\n * opacity: 0,\n * }\n *\n * const transitionStyles = {\n * entering: { opacity: 1 },\n * entered: { opacity: 1 },\n * exiting: { opacity: 0 },\n * exited: { opacity: 0 },\n * };\n *\n * const Fade = ({ in: inProp }) => (\n * \n * {state => (\n *
    \n * I'm a fade Transition!\n *
    \n * )}\n *
    \n * );\n * ```\n *\n * There are 4 main states a Transition can be in:\n * - `'entering'`\n * - `'entered'`\n * - `'exiting'`\n * - `'exited'`\n *\n * Transition state is toggled via the `in` prop. When `true` the component\n * begins the \"Enter\" stage. During this stage, the component will shift from\n * its current transition state, to `'entering'` for the duration of the\n * transition and then to the `'entered'` stage once it's complete. Let's take\n * the following example (we'll use the\n * [useState](https://reactjs.org/docs/hooks-reference.html#usestate) hook):\n *\n * ```jsx\n * function App() {\n * const [inProp, setInProp] = useState(false);\n * return (\n *
    \n * \n * {state => (\n * // ...\n * )}\n * \n * \n *
    \n * );\n * }\n * ```\n *\n * When the button is clicked the component will shift to the `'entering'` state\n * and stay there for 500ms (the value of `timeout`) before it finally switches\n * to `'entered'`.\n *\n * When `in` is `false` the same thing happens except the state moves from\n * `'exiting'` to `'exited'`.\n */\n\nvar Transition = /*#__PURE__*/function (_React$Component) {\n _inheritsLoose(Transition, _React$Component);\n\n function Transition(props, context) {\n var _this;\n\n _this = _React$Component.call(this, props, context) || this;\n var parentGroup = context; // In the context of a TransitionGroup all enters are really appears\n\n var appear = parentGroup && !parentGroup.isMounting ? props.enter : props.appear;\n var initialStatus;\n _this.appearStatus = null;\n\n if (props.in) {\n if (appear) {\n initialStatus = EXITED;\n _this.appearStatus = ENTERING;\n } else {\n initialStatus = ENTERED;\n }\n } else {\n if (props.unmountOnExit || props.mountOnEnter) {\n initialStatus = UNMOUNTED;\n } else {\n initialStatus = EXITED;\n }\n }\n\n _this.state = {\n status: initialStatus\n };\n _this.nextCallback = null;\n return _this;\n }\n\n Transition.getDerivedStateFromProps = function getDerivedStateFromProps(_ref, prevState) {\n var nextIn = _ref.in;\n\n if (nextIn && prevState.status === UNMOUNTED) {\n return {\n status: EXITED\n };\n }\n\n return null;\n } // getSnapshotBeforeUpdate(prevProps) {\n // let nextStatus = null\n // if (prevProps !== this.props) {\n // const { status } = this.state\n // if (this.props.in) {\n // if (status !== ENTERING && status !== ENTERED) {\n // nextStatus = ENTERING\n // }\n // } else {\n // if (status === ENTERING || status === ENTERED) {\n // nextStatus = EXITING\n // }\n // }\n // }\n // return { nextStatus }\n // }\n ;\n\n var _proto = Transition.prototype;\n\n _proto.componentDidMount = function componentDidMount() {\n this.updateStatus(true, this.appearStatus);\n };\n\n _proto.componentDidUpdate = function componentDidUpdate(prevProps) {\n var nextStatus = null;\n\n if (prevProps !== this.props) {\n var status = this.state.status;\n\n if (this.props.in) {\n if (status !== ENTERING && status !== ENTERED) {\n nextStatus = ENTERING;\n }\n } else {\n if (status === ENTERING || status === ENTERED) {\n nextStatus = EXITING;\n }\n }\n }\n\n this.updateStatus(false, nextStatus);\n };\n\n _proto.componentWillUnmount = function componentWillUnmount() {\n this.cancelNextCallback();\n };\n\n _proto.getTimeouts = function getTimeouts() {\n var timeout = this.props.timeout;\n var exit, enter, appear;\n exit = enter = appear = timeout;\n\n if (timeout != null && typeof timeout !== 'number') {\n exit = timeout.exit;\n enter = timeout.enter; // TODO: remove fallback for next major\n\n appear = timeout.appear !== undefined ? timeout.appear : enter;\n }\n\n return {\n exit: exit,\n enter: enter,\n appear: appear\n };\n };\n\n _proto.updateStatus = function updateStatus(mounting, nextStatus) {\n if (mounting === void 0) {\n mounting = false;\n }\n\n if (nextStatus !== null) {\n // nextStatus will always be ENTERING or EXITING.\n this.cancelNextCallback();\n\n if (nextStatus === ENTERING) {\n if (this.props.unmountOnExit || this.props.mountOnEnter) {\n var node = this.props.nodeRef ? this.props.nodeRef.current : ReactDOM.findDOMNode(this); // https://github.com/reactjs/react-transition-group/pull/749\n // With unmountOnExit or mountOnEnter, the enter animation should happen at the transition between `exited` and `entering`.\n // To make the animation happen, we have to separate each rendering and avoid being processed as batched.\n\n if (node) forceReflow(node);\n }\n\n this.performEnter(mounting);\n } else {\n this.performExit();\n }\n } else if (this.props.unmountOnExit && this.state.status === EXITED) {\n this.setState({\n status: UNMOUNTED\n });\n }\n };\n\n _proto.performEnter = function performEnter(mounting) {\n var _this2 = this;\n\n var enter = this.props.enter;\n var appearing = this.context ? this.context.isMounting : mounting;\n\n var _ref2 = this.props.nodeRef ? [appearing] : [ReactDOM.findDOMNode(this), appearing],\n maybeNode = _ref2[0],\n maybeAppearing = _ref2[1];\n\n var timeouts = this.getTimeouts();\n var enterTimeout = appearing ? timeouts.appear : timeouts.enter; // no enter animation skip right to ENTERED\n // if we are mounting and running this it means appear _must_ be set\n\n if (!mounting && !enter || config.disabled) {\n this.safeSetState({\n status: ENTERED\n }, function () {\n _this2.props.onEntered(maybeNode);\n });\n return;\n }\n\n this.props.onEnter(maybeNode, maybeAppearing);\n this.safeSetState({\n status: ENTERING\n }, function () {\n _this2.props.onEntering(maybeNode, maybeAppearing);\n\n _this2.onTransitionEnd(enterTimeout, function () {\n _this2.safeSetState({\n status: ENTERED\n }, function () {\n _this2.props.onEntered(maybeNode, maybeAppearing);\n });\n });\n });\n };\n\n _proto.performExit = function performExit() {\n var _this3 = this;\n\n var exit = this.props.exit;\n var timeouts = this.getTimeouts();\n var maybeNode = this.props.nodeRef ? undefined : ReactDOM.findDOMNode(this); // no exit animation skip right to EXITED\n\n if (!exit || config.disabled) {\n this.safeSetState({\n status: EXITED\n }, function () {\n _this3.props.onExited(maybeNode);\n });\n return;\n }\n\n this.props.onExit(maybeNode);\n this.safeSetState({\n status: EXITING\n }, function () {\n _this3.props.onExiting(maybeNode);\n\n _this3.onTransitionEnd(timeouts.exit, function () {\n _this3.safeSetState({\n status: EXITED\n }, function () {\n _this3.props.onExited(maybeNode);\n });\n });\n });\n };\n\n _proto.cancelNextCallback = function cancelNextCallback() {\n if (this.nextCallback !== null) {\n this.nextCallback.cancel();\n this.nextCallback = null;\n }\n };\n\n _proto.safeSetState = function safeSetState(nextState, callback) {\n // This shouldn't be necessary, but there are weird race conditions with\n // setState callbacks and unmounting in testing, so always make sure that\n // we can cancel any pending setState callbacks after we unmount.\n callback = this.setNextCallback(callback);\n this.setState(nextState, callback);\n };\n\n _proto.setNextCallback = function setNextCallback(callback) {\n var _this4 = this;\n\n var active = true;\n\n this.nextCallback = function (event) {\n if (active) {\n active = false;\n _this4.nextCallback = null;\n callback(event);\n }\n };\n\n this.nextCallback.cancel = function () {\n active = false;\n };\n\n return this.nextCallback;\n };\n\n _proto.onTransitionEnd = function onTransitionEnd(timeout, handler) {\n this.setNextCallback(handler);\n var node = this.props.nodeRef ? this.props.nodeRef.current : ReactDOM.findDOMNode(this);\n var doesNotHaveTimeoutOrListener = timeout == null && !this.props.addEndListener;\n\n if (!node || doesNotHaveTimeoutOrListener) {\n setTimeout(this.nextCallback, 0);\n return;\n }\n\n if (this.props.addEndListener) {\n var _ref3 = this.props.nodeRef ? [this.nextCallback] : [node, this.nextCallback],\n maybeNode = _ref3[0],\n maybeNextCallback = _ref3[1];\n\n this.props.addEndListener(maybeNode, maybeNextCallback);\n }\n\n if (timeout != null) {\n setTimeout(this.nextCallback, timeout);\n }\n };\n\n _proto.render = function render() {\n var status = this.state.status;\n\n if (status === UNMOUNTED) {\n return null;\n }\n\n var _this$props = this.props,\n children = _this$props.children,\n _in = _this$props.in,\n _mountOnEnter = _this$props.mountOnEnter,\n _unmountOnExit = _this$props.unmountOnExit,\n _appear = _this$props.appear,\n _enter = _this$props.enter,\n _exit = _this$props.exit,\n _timeout = _this$props.timeout,\n _addEndListener = _this$props.addEndListener,\n _onEnter = _this$props.onEnter,\n _onEntering = _this$props.onEntering,\n _onEntered = _this$props.onEntered,\n _onExit = _this$props.onExit,\n _onExiting = _this$props.onExiting,\n _onExited = _this$props.onExited,\n _nodeRef = _this$props.nodeRef,\n childProps = _objectWithoutPropertiesLoose(_this$props, [\"children\", \"in\", \"mountOnEnter\", \"unmountOnExit\", \"appear\", \"enter\", \"exit\", \"timeout\", \"addEndListener\", \"onEnter\", \"onEntering\", \"onEntered\", \"onExit\", \"onExiting\", \"onExited\", \"nodeRef\"]);\n\n return (\n /*#__PURE__*/\n // allows for nested Transitions\n React.createElement(TransitionGroupContext.Provider, {\n value: null\n }, typeof children === 'function' ? children(status, childProps) : React.cloneElement(React.Children.only(children), childProps))\n );\n };\n\n return Transition;\n}(React.Component);\n\nTransition.contextType = TransitionGroupContext;\nTransition.propTypes = process.env.NODE_ENV !== \"production\" ? {\n /**\n * A React reference to DOM element that need to transition:\n * https://stackoverflow.com/a/51127130/4671932\n *\n * - When `nodeRef` prop is used, `node` is not passed to callback functions\n * (e.g. `onEnter`) because user already has direct access to the node.\n * - When changing `key` prop of `Transition` in a `TransitionGroup` a new\n * `nodeRef` need to be provided to `Transition` with changed `key` prop\n * (see\n * [test/CSSTransition-test.js](https://github.com/reactjs/react-transition-group/blob/13435f897b3ab71f6e19d724f145596f5910581c/test/CSSTransition-test.js#L362-L437)).\n */\n nodeRef: PropTypes.shape({\n current: typeof Element === 'undefined' ? PropTypes.any : function (propValue, key, componentName, location, propFullName, secret) {\n var value = propValue[key];\n return PropTypes.instanceOf(value && 'ownerDocument' in value ? value.ownerDocument.defaultView.Element : Element)(propValue, key, componentName, location, propFullName, secret);\n }\n }),\n\n /**\n * A `function` child can be used instead of a React element. This function is\n * called with the current transition status (`'entering'`, `'entered'`,\n * `'exiting'`, `'exited'`), which can be used to apply context\n * specific props to a component.\n *\n * ```jsx\n * \n * {state => (\n * \n * )}\n * \n * ```\n */\n children: PropTypes.oneOfType([PropTypes.func.isRequired, PropTypes.element.isRequired]).isRequired,\n\n /**\n * Show the component; triggers the enter or exit states\n */\n in: PropTypes.bool,\n\n /**\n * By default the child component is mounted immediately along with\n * the parent `Transition` component. If you want to \"lazy mount\" the component on the\n * first `in={true}` you can set `mountOnEnter`. After the first enter transition the component will stay\n * mounted, even on \"exited\", unless you also specify `unmountOnExit`.\n */\n mountOnEnter: PropTypes.bool,\n\n /**\n * By default the child component stays mounted after it reaches the `'exited'` state.\n * Set `unmountOnExit` if you'd prefer to unmount the component after it finishes exiting.\n */\n unmountOnExit: PropTypes.bool,\n\n /**\n * By default the child component does not perform the enter transition when\n * it first mounts, regardless of the value of `in`. If you want this\n * behavior, set both `appear` and `in` to `true`.\n *\n * > **Note**: there are no special appear states like `appearing`/`appeared`, this prop\n * > only adds an additional enter transition. However, in the\n * > `` component that first enter transition does result in\n * > additional `.appear-*` classes, that way you can choose to style it\n * > differently.\n */\n appear: PropTypes.bool,\n\n /**\n * Enable or disable enter transitions.\n */\n enter: PropTypes.bool,\n\n /**\n * Enable or disable exit transitions.\n */\n exit: PropTypes.bool,\n\n /**\n * The duration of the transition, in milliseconds.\n * Required unless `addEndListener` is provided.\n *\n * You may specify a single timeout for all transitions:\n *\n * ```jsx\n * timeout={500}\n * ```\n *\n * or individually:\n *\n * ```jsx\n * timeout={{\n * appear: 500,\n * enter: 300,\n * exit: 500,\n * }}\n * ```\n *\n * - `appear` defaults to the value of `enter`\n * - `enter` defaults to `0`\n * - `exit` defaults to `0`\n *\n * @type {number | { enter?: number, exit?: number, appear?: number }}\n */\n timeout: function timeout(props) {\n var pt = timeoutsShape;\n if (!props.addEndListener) pt = pt.isRequired;\n\n for (var _len = arguments.length, args = new Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) {\n args[_key - 1] = arguments[_key];\n }\n\n return pt.apply(void 0, [props].concat(args));\n },\n\n /**\n * Add a custom transition end trigger. Called with the transitioning\n * DOM node and a `done` callback. Allows for more fine grained transition end\n * logic. Timeouts are still used as a fallback if provided.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * ```jsx\n * addEndListener={(node, done) => {\n * // use the css transitionend event to mark the finish of a transition\n * node.addEventListener('transitionend', done, false);\n * }}\n * ```\n */\n addEndListener: PropTypes.func,\n\n /**\n * Callback fired before the \"entering\" status is applied. An extra parameter\n * `isAppearing` is supplied to indicate if the enter stage is occurring on the initial mount\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement, isAppearing: bool) -> void\n */\n onEnter: PropTypes.func,\n\n /**\n * Callback fired after the \"entering\" status is applied. An extra parameter\n * `isAppearing` is supplied to indicate if the enter stage is occurring on the initial mount\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement, isAppearing: bool)\n */\n onEntering: PropTypes.func,\n\n /**\n * Callback fired after the \"entered\" status is applied. An extra parameter\n * `isAppearing` is supplied to indicate if the enter stage is occurring on the initial mount\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement, isAppearing: bool) -> void\n */\n onEntered: PropTypes.func,\n\n /**\n * Callback fired before the \"exiting\" status is applied.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement) -> void\n */\n onExit: PropTypes.func,\n\n /**\n * Callback fired after the \"exiting\" status is applied.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement) -> void\n */\n onExiting: PropTypes.func,\n\n /**\n * Callback fired after the \"exited\" status is applied.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed\n *\n * @type Function(node: HtmlElement) -> void\n */\n onExited: PropTypes.func\n} : {}; // Name the function so it is clearer in the documentation\n\nfunction noop() {}\n\nTransition.defaultProps = {\n in: false,\n mountOnEnter: false,\n unmountOnExit: false,\n appear: false,\n enter: true,\n exit: true,\n onEnter: noop,\n onEntering: noop,\n onEntered: noop,\n onExit: noop,\n onExiting: noop,\n onExited: noop\n};\nTransition.UNMOUNTED = UNMOUNTED;\nTransition.EXITED = EXITED;\nTransition.ENTERING = ENTERING;\nTransition.ENTERED = ENTERED;\nTransition.EXITING = EXITING;\nexport default Transition;","export const reflow = node => node.scrollTop;\nexport function getTransitionProps(props, options) {\n var _style$transitionDura, _style$transitionTimi;\n const {\n timeout,\n easing,\n style = {}\n } = props;\n return {\n duration: (_style$transitionDura = style.transitionDuration) != null ? _style$transitionDura : typeof timeout === 'number' ? timeout : timeout[options.mode] || 0,\n easing: (_style$transitionTimi = style.transitionTimingFunction) != null ? _style$transitionTimi : typeof easing === 'object' ? easing[options.mode] : easing,\n delay: style.transitionDelay\n };\n}","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"addEndListener\", \"appear\", \"children\", \"easing\", \"in\", \"onEnter\", \"onEntered\", \"onEntering\", \"onExit\", \"onExited\", \"onExiting\", \"style\", \"timeout\", \"TransitionComponent\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport { elementAcceptingRef, unstable_useTimeout as useTimeout } from '@mui/utils';\nimport { Transition } from 'react-transition-group';\nimport useTheme from '../styles/useTheme';\nimport { getTransitionProps, reflow } from '../transitions/utils';\nimport useForkRef from '../utils/useForkRef';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nfunction getScale(value) {\n return `scale(${value}, ${value ** 2})`;\n}\nconst styles = {\n entering: {\n opacity: 1,\n transform: getScale(1)\n },\n entered: {\n opacity: 1,\n transform: 'none'\n }\n};\n\n/*\n TODO v6: remove\n Conditionally apply a workaround for the CSS transition bug in Safari 15.4 / WebKit browsers.\n */\nconst isWebKit154 = typeof navigator !== 'undefined' && /^((?!chrome|android).)*(safari|mobile)/i.test(navigator.userAgent) && /(os |version\\/)15(.|_)4/i.test(navigator.userAgent);\n\n/**\n * The Grow transition is used by the [Tooltip](/material-ui/react-tooltip/) and\n * [Popover](/material-ui/react-popover/) components.\n * It uses [react-transition-group](https://github.com/reactjs/react-transition-group) internally.\n */\nconst Grow = /*#__PURE__*/React.forwardRef(function Grow(props, ref) {\n const {\n addEndListener,\n appear = true,\n children,\n easing,\n in: inProp,\n onEnter,\n onEntered,\n onEntering,\n onExit,\n onExited,\n onExiting,\n style,\n timeout = 'auto',\n // eslint-disable-next-line react/prop-types\n TransitionComponent = Transition\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const timer = useTimeout();\n const autoTimeout = React.useRef();\n const theme = useTheme();\n const nodeRef = React.useRef(null);\n const handleRef = useForkRef(nodeRef, children.ref, ref);\n const normalizedTransitionCallback = callback => maybeIsAppearing => {\n if (callback) {\n const node = nodeRef.current;\n\n // onEnterXxx and onExitXxx callbacks have a different arguments.length value.\n if (maybeIsAppearing === undefined) {\n callback(node);\n } else {\n callback(node, maybeIsAppearing);\n }\n }\n };\n const handleEntering = normalizedTransitionCallback(onEntering);\n const handleEnter = normalizedTransitionCallback((node, isAppearing) => {\n reflow(node); // So the animation always start from the start.\n\n const {\n duration: transitionDuration,\n delay,\n easing: transitionTimingFunction\n } = getTransitionProps({\n style,\n timeout,\n easing\n }, {\n mode: 'enter'\n });\n let duration;\n if (timeout === 'auto') {\n duration = theme.transitions.getAutoHeightDuration(node.clientHeight);\n autoTimeout.current = duration;\n } else {\n duration = transitionDuration;\n }\n node.style.transition = [theme.transitions.create('opacity', {\n duration,\n delay\n }), theme.transitions.create('transform', {\n duration: isWebKit154 ? duration : duration * 0.666,\n delay,\n easing: transitionTimingFunction\n })].join(',');\n if (onEnter) {\n onEnter(node, isAppearing);\n }\n });\n const handleEntered = normalizedTransitionCallback(onEntered);\n const handleExiting = normalizedTransitionCallback(onExiting);\n const handleExit = normalizedTransitionCallback(node => {\n const {\n duration: transitionDuration,\n delay,\n easing: transitionTimingFunction\n } = getTransitionProps({\n style,\n timeout,\n easing\n }, {\n mode: 'exit'\n });\n let duration;\n if (timeout === 'auto') {\n duration = theme.transitions.getAutoHeightDuration(node.clientHeight);\n autoTimeout.current = duration;\n } else {\n duration = transitionDuration;\n }\n node.style.transition = [theme.transitions.create('opacity', {\n duration,\n delay\n }), theme.transitions.create('transform', {\n duration: isWebKit154 ? duration : duration * 0.666,\n delay: isWebKit154 ? delay : delay || duration * 0.333,\n easing: transitionTimingFunction\n })].join(',');\n node.style.opacity = 0;\n node.style.transform = getScale(0.75);\n if (onExit) {\n onExit(node);\n }\n });\n const handleExited = normalizedTransitionCallback(onExited);\n const handleAddEndListener = next => {\n if (timeout === 'auto') {\n timer.start(autoTimeout.current || 0, next);\n }\n if (addEndListener) {\n // Old call signature before `react-transition-group` implemented `nodeRef`\n addEndListener(nodeRef.current, next);\n }\n };\n return /*#__PURE__*/_jsx(TransitionComponent, _extends({\n appear: appear,\n in: inProp,\n nodeRef: nodeRef,\n onEnter: handleEnter,\n onEntered: handleEntered,\n onEntering: handleEntering,\n onExit: handleExit,\n onExited: handleExited,\n onExiting: handleExiting,\n addEndListener: handleAddEndListener,\n timeout: timeout === 'auto' ? null : timeout\n }, other, {\n children: (state, childProps) => {\n return /*#__PURE__*/React.cloneElement(children, _extends({\n style: _extends({\n opacity: 0,\n transform: getScale(0.75),\n visibility: state === 'exited' && !inProp ? 'hidden' : undefined\n }, styles[state], style, children.props.style),\n ref: handleRef\n }, childProps));\n }\n }));\n});\nprocess.env.NODE_ENV !== \"production\" ? Grow.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the d.ts file and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * Add a custom transition end trigger. Called with the transitioning DOM\n * node and a done callback. Allows for more fine grained transition end\n * logic. Note: Timeouts are still used as a fallback if provided.\n */\n addEndListener: PropTypes.func,\n /**\n * Perform the enter transition when it first mounts if `in` is also `true`.\n * Set this to `false` to disable this behavior.\n * @default true\n */\n appear: PropTypes.bool,\n /**\n * A single child content element.\n */\n children: elementAcceptingRef.isRequired,\n /**\n * The transition timing function.\n * You may specify a single easing or a object containing enter and exit values.\n */\n easing: PropTypes.oneOfType([PropTypes.shape({\n enter: PropTypes.string,\n exit: PropTypes.string\n }), PropTypes.string]),\n /**\n * If `true`, the component will transition in.\n */\n in: PropTypes.bool,\n /**\n * @ignore\n */\n onEnter: PropTypes.func,\n /**\n * @ignore\n */\n onEntered: PropTypes.func,\n /**\n * @ignore\n */\n onEntering: PropTypes.func,\n /**\n * @ignore\n */\n onExit: PropTypes.func,\n /**\n * @ignore\n */\n onExited: PropTypes.func,\n /**\n * @ignore\n */\n onExiting: PropTypes.func,\n /**\n * @ignore\n */\n style: PropTypes.object,\n /**\n * The duration for the transition, in milliseconds.\n * You may specify a single timeout for all transitions, or individually with an object.\n *\n * Set to 'auto' to automatically calculate transition time based on height.\n * @default 'auto'\n */\n timeout: PropTypes.oneOfType([PropTypes.oneOf(['auto']), PropTypes.number, PropTypes.shape({\n appear: PropTypes.number,\n enter: PropTypes.number,\n exit: PropTypes.number\n })])\n} : void 0;\nGrow.muiSupportAuto = true;\nexport default Grow;","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"anchorEl\", \"component\", \"components\", \"componentsProps\", \"container\", \"disablePortal\", \"keepMounted\", \"modifiers\", \"open\", \"placement\", \"popperOptions\", \"popperRef\", \"transition\", \"slots\", \"slotProps\"];\nimport { Popper as BasePopper } from '@mui/base/Popper';\nimport { useThemeWithoutDefault as useTheme } from '@mui/system';\nimport { HTMLElementType, refType } from '@mui/utils';\nimport PropTypes from 'prop-types';\nimport * as React from 'react';\nimport { styled, useThemeProps } from '../styles';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nconst PopperRoot = styled(BasePopper, {\n name: 'MuiPopper',\n slot: 'Root',\n overridesResolver: (props, styles) => styles.root\n})({});\n\n/**\n *\n * Demos:\n *\n * - [Autocomplete](https://mui.com/material-ui/react-autocomplete/)\n * - [Menu](https://mui.com/material-ui/react-menu/)\n * - [Popper](https://mui.com/material-ui/react-popper/)\n *\n * API:\n *\n * - [Popper API](https://mui.com/material-ui/api/popper/)\n */\nconst Popper = /*#__PURE__*/React.forwardRef(function Popper(inProps, ref) {\n var _slots$root;\n const theme = useTheme();\n const props = useThemeProps({\n props: inProps,\n name: 'MuiPopper'\n });\n const {\n anchorEl,\n component,\n components,\n componentsProps,\n container,\n disablePortal,\n keepMounted,\n modifiers,\n open,\n placement,\n popperOptions,\n popperRef,\n transition,\n slots,\n slotProps\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const RootComponent = (_slots$root = slots == null ? void 0 : slots.root) != null ? _slots$root : components == null ? void 0 : components.Root;\n const otherProps = _extends({\n anchorEl,\n container,\n disablePortal,\n keepMounted,\n modifiers,\n open,\n placement,\n popperOptions,\n popperRef,\n transition\n }, other);\n return /*#__PURE__*/_jsx(PopperRoot, _extends({\n as: component,\n direction: theme == null ? void 0 : theme.direction,\n slots: {\n root: RootComponent\n },\n slotProps: slotProps != null ? slotProps : componentsProps\n }, otherProps, {\n ref: ref\n }));\n});\nprocess.env.NODE_ENV !== \"production\" ? Popper.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * An HTML element, [virtualElement](https://popper.js.org/docs/v2/virtual-elements/),\n * or a function that returns either.\n * It's used to set the position of the popper.\n * The return value will passed as the reference object of the Popper instance.\n */\n anchorEl: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.object, PropTypes.func]),\n /**\n * Popper render function or node.\n */\n children: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.node, PropTypes.func]),\n /**\n * The component used for the root node.\n * Either a string to use a HTML element or a component.\n */\n component: PropTypes.elementType,\n /**\n * The components used for each slot inside the Popper.\n * Either a string to use a HTML element or a component.\n * @default {}\n */\n components: PropTypes.shape({\n Root: PropTypes.elementType\n }),\n /**\n * The props used for each slot inside the Popper.\n * @default {}\n */\n componentsProps: PropTypes.shape({\n root: PropTypes.oneOfType([PropTypes.func, PropTypes.object])\n }),\n /**\n * An HTML element or function that returns one.\n * The `container` will have the portal children appended to it.\n *\n * You can also provide a callback, which is called in a React layout effect.\n * This lets you set the container from a ref, and also makes server-side rendering possible.\n *\n * By default, it uses the body of the top-level document object,\n * so it's simply `document.body` most of the time.\n */\n container: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.func]),\n /**\n * The `children` will be under the DOM hierarchy of the parent component.\n * @default false\n */\n disablePortal: PropTypes.bool,\n /**\n * Always keep the children in the DOM.\n * This prop can be useful in SEO situation or\n * when you want to maximize the responsiveness of the Popper.\n * @default false\n */\n keepMounted: PropTypes.bool,\n /**\n * Popper.js is based on a \"plugin-like\" architecture,\n * most of its features are fully encapsulated \"modifiers\".\n *\n * A modifier is a function that is called each time Popper.js needs to\n * compute the position of the popper.\n * For this reason, modifiers should be very performant to avoid bottlenecks.\n * To learn how to create a modifier, [read the modifiers documentation](https://popper.js.org/docs/v2/modifiers/).\n */\n modifiers: PropTypes.arrayOf(PropTypes.shape({\n data: PropTypes.object,\n effect: PropTypes.func,\n enabled: PropTypes.bool,\n fn: PropTypes.func,\n name: PropTypes.any,\n options: PropTypes.object,\n phase: PropTypes.oneOf(['afterMain', 'afterRead', 'afterWrite', 'beforeMain', 'beforeRead', 'beforeWrite', 'main', 'read', 'write']),\n requires: PropTypes.arrayOf(PropTypes.string),\n requiresIfExists: PropTypes.arrayOf(PropTypes.string)\n })),\n /**\n * If `true`, the component is shown.\n */\n open: PropTypes.bool.isRequired,\n /**\n * Popper placement.\n * @default 'bottom'\n */\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n /**\n * Options provided to the [`Popper.js`](https://popper.js.org/docs/v2/constructors/#options) instance.\n * @default {}\n */\n popperOptions: PropTypes.shape({\n modifiers: PropTypes.array,\n onFirstUpdate: PropTypes.func,\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n strategy: PropTypes.oneOf(['absolute', 'fixed'])\n }),\n /**\n * A ref that points to the used popper instance.\n */\n popperRef: refType,\n /**\n * The props used for each slot inside the Popper.\n * @default {}\n */\n slotProps: PropTypes.shape({\n root: PropTypes.oneOfType([PropTypes.func, PropTypes.object])\n }),\n /**\n * The components used for each slot inside the Popper.\n * Either a string to use a HTML element or a component.\n * @default {}\n */\n slots: PropTypes.shape({\n root: PropTypes.elementType\n }),\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Help supporting a react-transition-group/Transition component.\n * @default false\n */\n transition: PropTypes.bool\n} : void 0;\nexport default Popper;","import generateUtilityClasses from '@mui/utils/generateUtilityClasses';\nimport generateUtilityClass from '@mui/utils/generateUtilityClass';\nexport function getTooltipUtilityClass(slot) {\n return generateUtilityClass('MuiTooltip', slot);\n}\nconst tooltipClasses = generateUtilityClasses('MuiTooltip', ['popper', 'popperInteractive', 'popperArrow', 'popperClose', 'tooltip', 'tooltipArrow', 'touch', 'tooltipPlacementLeft', 'tooltipPlacementRight', 'tooltipPlacementTop', 'tooltipPlacementBottom', 'arrow']);\nexport default tooltipClasses;","'use client';\n\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nconst _excluded = [\"arrow\", \"children\", \"classes\", \"components\", \"componentsProps\", \"describeChild\", \"disableFocusListener\", \"disableHoverListener\", \"disableInteractive\", \"disableTouchListener\", \"enterDelay\", \"enterNextDelay\", \"enterTouchDelay\", \"followCursor\", \"id\", \"leaveDelay\", \"leaveTouchDelay\", \"onClose\", \"onOpen\", \"open\", \"placement\", \"PopperComponent\", \"PopperProps\", \"slotProps\", \"slots\", \"title\", \"TransitionComponent\", \"TransitionProps\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport clsx from 'clsx';\nimport { elementAcceptingRef, unstable_useTimeout as useTimeout, unstable_Timeout as Timeout } from '@mui/utils';\nimport { unstable_composeClasses as composeClasses, appendOwnerState } from '@mui/base';\nimport { alpha } from '@mui/system';\nimport styled from '../styles/styled';\nimport useTheme from '../styles/useTheme';\nimport useThemeProps from '../styles/useThemeProps';\nimport capitalize from '../utils/capitalize';\nimport Grow from '../Grow';\nimport Popper from '../Popper';\nimport useEventCallback from '../utils/useEventCallback';\nimport useForkRef from '../utils/useForkRef';\nimport useId from '../utils/useId';\nimport useIsFocusVisible from '../utils/useIsFocusVisible';\nimport useControlled from '../utils/useControlled';\nimport tooltipClasses, { getTooltipUtilityClass } from './tooltipClasses';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nimport { jsxs as _jsxs } from \"react/jsx-runtime\";\nfunction round(value) {\n return Math.round(value * 1e5) / 1e5;\n}\nconst useUtilityClasses = ownerState => {\n const {\n classes,\n disableInteractive,\n arrow,\n touch,\n placement\n } = ownerState;\n const slots = {\n popper: ['popper', !disableInteractive && 'popperInteractive', arrow && 'popperArrow'],\n tooltip: ['tooltip', arrow && 'tooltipArrow', touch && 'touch', `tooltipPlacement${capitalize(placement.split('-')[0])}`],\n arrow: ['arrow']\n };\n return composeClasses(slots, getTooltipUtilityClass, classes);\n};\nconst TooltipPopper = styled(Popper, {\n name: 'MuiTooltip',\n slot: 'Popper',\n overridesResolver: (props, styles) => {\n const {\n ownerState\n } = props;\n return [styles.popper, !ownerState.disableInteractive && styles.popperInteractive, ownerState.arrow && styles.popperArrow, !ownerState.open && styles.popperClose];\n }\n})(({\n theme,\n ownerState,\n open\n}) => _extends({\n zIndex: (theme.vars || theme).zIndex.tooltip,\n pointerEvents: 'none'\n}, !ownerState.disableInteractive && {\n pointerEvents: 'auto'\n}, !open && {\n pointerEvents: 'none'\n}, ownerState.arrow && {\n [`&[data-popper-placement*=\"bottom\"] .${tooltipClasses.arrow}`]: {\n top: 0,\n marginTop: '-0.71em',\n '&::before': {\n transformOrigin: '0 100%'\n }\n },\n [`&[data-popper-placement*=\"top\"] .${tooltipClasses.arrow}`]: {\n bottom: 0,\n marginBottom: '-0.71em',\n '&::before': {\n transformOrigin: '100% 0'\n }\n },\n [`&[data-popper-placement*=\"right\"] .${tooltipClasses.arrow}`]: _extends({}, !ownerState.isRtl ? {\n left: 0,\n marginLeft: '-0.71em'\n } : {\n right: 0,\n marginRight: '-0.71em'\n }, {\n height: '1em',\n width: '0.71em',\n '&::before': {\n transformOrigin: '100% 100%'\n }\n }),\n [`&[data-popper-placement*=\"left\"] .${tooltipClasses.arrow}`]: _extends({}, !ownerState.isRtl ? {\n right: 0,\n marginRight: '-0.71em'\n } : {\n left: 0,\n marginLeft: '-0.71em'\n }, {\n height: '1em',\n width: '0.71em',\n '&::before': {\n transformOrigin: '0 0'\n }\n })\n}));\nconst TooltipTooltip = styled('div', {\n name: 'MuiTooltip',\n slot: 'Tooltip',\n overridesResolver: (props, styles) => {\n const {\n ownerState\n } = props;\n return [styles.tooltip, ownerState.touch && styles.touch, ownerState.arrow && styles.tooltipArrow, styles[`tooltipPlacement${capitalize(ownerState.placement.split('-')[0])}`]];\n }\n})(({\n theme,\n ownerState\n}) => _extends({\n backgroundColor: theme.vars ? theme.vars.palette.Tooltip.bg : alpha(theme.palette.grey[700], 0.92),\n borderRadius: (theme.vars || theme).shape.borderRadius,\n color: (theme.vars || theme).palette.common.white,\n fontFamily: theme.typography.fontFamily,\n padding: '4px 8px',\n fontSize: theme.typography.pxToRem(11),\n maxWidth: 300,\n margin: 2,\n wordWrap: 'break-word',\n fontWeight: theme.typography.fontWeightMedium\n}, ownerState.arrow && {\n position: 'relative',\n margin: 0\n}, ownerState.touch && {\n padding: '8px 16px',\n fontSize: theme.typography.pxToRem(14),\n lineHeight: `${round(16 / 14)}em`,\n fontWeight: theme.typography.fontWeightRegular\n}, {\n [`.${tooltipClasses.popper}[data-popper-placement*=\"left\"] &`]: _extends({\n transformOrigin: 'right center'\n }, !ownerState.isRtl ? _extends({\n marginRight: '14px'\n }, ownerState.touch && {\n marginRight: '24px'\n }) : _extends({\n marginLeft: '14px'\n }, ownerState.touch && {\n marginLeft: '24px'\n })),\n [`.${tooltipClasses.popper}[data-popper-placement*=\"right\"] &`]: _extends({\n transformOrigin: 'left center'\n }, !ownerState.isRtl ? _extends({\n marginLeft: '14px'\n }, ownerState.touch && {\n marginLeft: '24px'\n }) : _extends({\n marginRight: '14px'\n }, ownerState.touch && {\n marginRight: '24px'\n })),\n [`.${tooltipClasses.popper}[data-popper-placement*=\"top\"] &`]: _extends({\n transformOrigin: 'center bottom',\n marginBottom: '14px'\n }, ownerState.touch && {\n marginBottom: '24px'\n }),\n [`.${tooltipClasses.popper}[data-popper-placement*=\"bottom\"] &`]: _extends({\n transformOrigin: 'center top',\n marginTop: '14px'\n }, ownerState.touch && {\n marginTop: '24px'\n })\n}));\nconst TooltipArrow = styled('span', {\n name: 'MuiTooltip',\n slot: 'Arrow',\n overridesResolver: (props, styles) => styles.arrow\n})(({\n theme\n}) => ({\n overflow: 'hidden',\n position: 'absolute',\n width: '1em',\n height: '0.71em' /* = width / sqrt(2) = (length of the hypotenuse) */,\n boxSizing: 'border-box',\n color: theme.vars ? theme.vars.palette.Tooltip.bg : alpha(theme.palette.grey[700], 0.9),\n '&::before': {\n content: '\"\"',\n margin: 'auto',\n display: 'block',\n width: '100%',\n height: '100%',\n backgroundColor: 'currentColor',\n transform: 'rotate(45deg)'\n }\n}));\nlet hystersisOpen = false;\nconst hystersisTimer = new Timeout();\nlet cursorPosition = {\n x: 0,\n y: 0\n};\nexport function testReset() {\n hystersisOpen = false;\n hystersisTimer.clear();\n}\nfunction composeEventHandler(handler, eventHandler) {\n return event => {\n if (eventHandler) {\n eventHandler(event);\n }\n handler(event);\n };\n}\n\n// TODO v6: Remove PopperComponent, PopperProps, TransitionComponent and TransitionProps.\nconst Tooltip = /*#__PURE__*/React.forwardRef(function Tooltip(inProps, ref) {\n var _ref, _slots$popper, _ref2, _ref3, _slots$transition, _ref4, _slots$tooltip, _ref5, _slots$arrow, _slotProps$popper, _ref6, _slotProps$popper2, _slotProps$transition, _slotProps$tooltip, _ref7, _slotProps$tooltip2, _slotProps$arrow, _ref8, _slotProps$arrow2;\n const props = useThemeProps({\n props: inProps,\n name: 'MuiTooltip'\n });\n const {\n arrow = false,\n children: childrenProp,\n components = {},\n componentsProps = {},\n describeChild = false,\n disableFocusListener = false,\n disableHoverListener = false,\n disableInteractive: disableInteractiveProp = false,\n disableTouchListener = false,\n enterDelay = 100,\n enterNextDelay = 0,\n enterTouchDelay = 700,\n followCursor = false,\n id: idProp,\n leaveDelay = 0,\n leaveTouchDelay = 1500,\n onClose,\n onOpen,\n open: openProp,\n placement = 'bottom',\n PopperComponent: PopperComponentProp,\n PopperProps = {},\n slotProps = {},\n slots = {},\n title,\n TransitionComponent: TransitionComponentProp = Grow,\n TransitionProps\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n\n // to prevent runtime errors, developers will need to provide a child as a React element anyway.\n const children = /*#__PURE__*/React.isValidElement(childrenProp) ? childrenProp : /*#__PURE__*/_jsx(\"span\", {\n children: childrenProp\n });\n const theme = useTheme();\n const isRtl = theme.direction === 'rtl';\n const [childNode, setChildNode] = React.useState();\n const [arrowRef, setArrowRef] = React.useState(null);\n const ignoreNonTouchEvents = React.useRef(false);\n const disableInteractive = disableInteractiveProp || followCursor;\n const closeTimer = useTimeout();\n const enterTimer = useTimeout();\n const leaveTimer = useTimeout();\n const touchTimer = useTimeout();\n const [openState, setOpenState] = useControlled({\n controlled: openProp,\n default: false,\n name: 'Tooltip',\n state: 'open'\n });\n let open = openState;\n if (process.env.NODE_ENV !== 'production') {\n // eslint-disable-next-line react-hooks/rules-of-hooks\n const {\n current: isControlled\n } = React.useRef(openProp !== undefined);\n\n // eslint-disable-next-line react-hooks/rules-of-hooks\n React.useEffect(() => {\n if (childNode && childNode.disabled && !isControlled && title !== '' && childNode.tagName.toLowerCase() === 'button') {\n console.error(['MUI: You are providing a disabled `button` child to the Tooltip component.', 'A disabled element does not fire events.', \"Tooltip needs to listen to the child element's events to display the title.\", '', 'Add a simple wrapper element, such as a `span`.'].join('\\n'));\n }\n }, [title, childNode, isControlled]);\n }\n const id = useId(idProp);\n const prevUserSelect = React.useRef();\n const stopTouchInteraction = useEventCallback(() => {\n if (prevUserSelect.current !== undefined) {\n document.body.style.WebkitUserSelect = prevUserSelect.current;\n prevUserSelect.current = undefined;\n }\n touchTimer.clear();\n });\n React.useEffect(() => stopTouchInteraction, [stopTouchInteraction]);\n const handleOpen = event => {\n hystersisTimer.clear();\n hystersisOpen = true;\n\n // The mouseover event will trigger for every nested element in the tooltip.\n // We can skip rerendering when the tooltip is already open.\n // We are using the mouseover event instead of the mouseenter event to fix a hide/show issue.\n setOpenState(true);\n if (onOpen && !open) {\n onOpen(event);\n }\n };\n const handleClose = useEventCallback(\n /**\n * @param {React.SyntheticEvent | Event} event\n */\n event => {\n hystersisTimer.start(800 + leaveDelay, () => {\n hystersisOpen = false;\n });\n setOpenState(false);\n if (onClose && open) {\n onClose(event);\n }\n closeTimer.start(theme.transitions.duration.shortest, () => {\n ignoreNonTouchEvents.current = false;\n });\n });\n const handleEnter = event => {\n if (ignoreNonTouchEvents.current && event.type !== 'touchstart') {\n return;\n }\n\n // Remove the title ahead of time.\n // We don't want to wait for the next render commit.\n // We would risk displaying two tooltips at the same time (native + this one).\n if (childNode) {\n childNode.removeAttribute('title');\n }\n enterTimer.clear();\n leaveTimer.clear();\n if (enterDelay || hystersisOpen && enterNextDelay) {\n enterTimer.start(hystersisOpen ? enterNextDelay : enterDelay, () => {\n handleOpen(event);\n });\n } else {\n handleOpen(event);\n }\n };\n const handleLeave = event => {\n enterTimer.clear();\n leaveTimer.start(leaveDelay, () => {\n handleClose(event);\n });\n };\n const {\n isFocusVisibleRef,\n onBlur: handleBlurVisible,\n onFocus: handleFocusVisible,\n ref: focusVisibleRef\n } = useIsFocusVisible();\n // We don't necessarily care about the focusVisible state (which is safe to access via ref anyway).\n // We just need to re-render the Tooltip if the focus-visible state changes.\n const [, setChildIsFocusVisible] = React.useState(false);\n const handleBlur = event => {\n handleBlurVisible(event);\n if (isFocusVisibleRef.current === false) {\n setChildIsFocusVisible(false);\n handleLeave(event);\n }\n };\n const handleFocus = event => {\n // Workaround for https://github.com/facebook/react/issues/7769\n // The autoFocus of React might trigger the event before the componentDidMount.\n // We need to account for this eventuality.\n if (!childNode) {\n setChildNode(event.currentTarget);\n }\n handleFocusVisible(event);\n if (isFocusVisibleRef.current === true) {\n setChildIsFocusVisible(true);\n handleEnter(event);\n }\n };\n const detectTouchStart = event => {\n ignoreNonTouchEvents.current = true;\n const childrenProps = children.props;\n if (childrenProps.onTouchStart) {\n childrenProps.onTouchStart(event);\n }\n };\n const handleMouseOver = handleEnter;\n const handleMouseLeave = handleLeave;\n const handleTouchStart = event => {\n detectTouchStart(event);\n leaveTimer.clear();\n closeTimer.clear();\n stopTouchInteraction();\n prevUserSelect.current = document.body.style.WebkitUserSelect;\n // Prevent iOS text selection on long-tap.\n document.body.style.WebkitUserSelect = 'none';\n touchTimer.start(enterTouchDelay, () => {\n document.body.style.WebkitUserSelect = prevUserSelect.current;\n handleEnter(event);\n });\n };\n const handleTouchEnd = event => {\n if (children.props.onTouchEnd) {\n children.props.onTouchEnd(event);\n }\n stopTouchInteraction();\n leaveTimer.start(leaveTouchDelay, () => {\n handleClose(event);\n });\n };\n React.useEffect(() => {\n if (!open) {\n return undefined;\n }\n\n /**\n * @param {KeyboardEvent} nativeEvent\n */\n function handleKeyDown(nativeEvent) {\n // IE11, Edge (prior to using Bink?) use 'Esc'\n if (nativeEvent.key === 'Escape' || nativeEvent.key === 'Esc') {\n handleClose(nativeEvent);\n }\n }\n document.addEventListener('keydown', handleKeyDown);\n return () => {\n document.removeEventListener('keydown', handleKeyDown);\n };\n }, [handleClose, open]);\n const handleRef = useForkRef(children.ref, focusVisibleRef, setChildNode, ref);\n\n // There is no point in displaying an empty tooltip.\n // So we exclude all falsy values, except 0, which is valid.\n if (!title && title !== 0) {\n open = false;\n }\n const popperRef = React.useRef();\n const handleMouseMove = event => {\n const childrenProps = children.props;\n if (childrenProps.onMouseMove) {\n childrenProps.onMouseMove(event);\n }\n cursorPosition = {\n x: event.clientX,\n y: event.clientY\n };\n if (popperRef.current) {\n popperRef.current.update();\n }\n };\n const nameOrDescProps = {};\n const titleIsString = typeof title === 'string';\n if (describeChild) {\n nameOrDescProps.title = !open && titleIsString && !disableHoverListener ? title : null;\n nameOrDescProps['aria-describedby'] = open ? id : null;\n } else {\n nameOrDescProps['aria-label'] = titleIsString ? title : null;\n nameOrDescProps['aria-labelledby'] = open && !titleIsString ? id : null;\n }\n const childrenProps = _extends({}, nameOrDescProps, other, children.props, {\n className: clsx(other.className, children.props.className),\n onTouchStart: detectTouchStart,\n ref: handleRef\n }, followCursor ? {\n onMouseMove: handleMouseMove\n } : {});\n if (process.env.NODE_ENV !== 'production') {\n childrenProps['data-mui-internal-clone-element'] = true;\n\n // eslint-disable-next-line react-hooks/rules-of-hooks\n React.useEffect(() => {\n if (childNode && !childNode.getAttribute('data-mui-internal-clone-element')) {\n console.error(['MUI: The `children` component of the Tooltip is not forwarding its props correctly.', 'Please make sure that props are spread on the same element that the ref is applied to.'].join('\\n'));\n }\n }, [childNode]);\n }\n const interactiveWrapperListeners = {};\n if (!disableTouchListener) {\n childrenProps.onTouchStart = handleTouchStart;\n childrenProps.onTouchEnd = handleTouchEnd;\n }\n if (!disableHoverListener) {\n childrenProps.onMouseOver = composeEventHandler(handleMouseOver, childrenProps.onMouseOver);\n childrenProps.onMouseLeave = composeEventHandler(handleMouseLeave, childrenProps.onMouseLeave);\n if (!disableInteractive) {\n interactiveWrapperListeners.onMouseOver = handleMouseOver;\n interactiveWrapperListeners.onMouseLeave = handleMouseLeave;\n }\n }\n if (!disableFocusListener) {\n childrenProps.onFocus = composeEventHandler(handleFocus, childrenProps.onFocus);\n childrenProps.onBlur = composeEventHandler(handleBlur, childrenProps.onBlur);\n if (!disableInteractive) {\n interactiveWrapperListeners.onFocus = handleFocus;\n interactiveWrapperListeners.onBlur = handleBlur;\n }\n }\n if (process.env.NODE_ENV !== 'production') {\n if (children.props.title) {\n console.error(['MUI: You have provided a `title` prop to the child of .', `Remove this title prop \\`${children.props.title}\\` or the Tooltip component.`].join('\\n'));\n }\n }\n const popperOptions = React.useMemo(() => {\n var _PopperProps$popperOp;\n let tooltipModifiers = [{\n name: 'arrow',\n enabled: Boolean(arrowRef),\n options: {\n element: arrowRef,\n padding: 4\n }\n }];\n if ((_PopperProps$popperOp = PopperProps.popperOptions) != null && _PopperProps$popperOp.modifiers) {\n tooltipModifiers = tooltipModifiers.concat(PopperProps.popperOptions.modifiers);\n }\n return _extends({}, PopperProps.popperOptions, {\n modifiers: tooltipModifiers\n });\n }, [arrowRef, PopperProps]);\n const ownerState = _extends({}, props, {\n isRtl,\n arrow,\n disableInteractive,\n placement,\n PopperComponentProp,\n touch: ignoreNonTouchEvents.current\n });\n const classes = useUtilityClasses(ownerState);\n const PopperComponent = (_ref = (_slots$popper = slots.popper) != null ? _slots$popper : components.Popper) != null ? _ref : TooltipPopper;\n const TransitionComponent = (_ref2 = (_ref3 = (_slots$transition = slots.transition) != null ? _slots$transition : components.Transition) != null ? _ref3 : TransitionComponentProp) != null ? _ref2 : Grow;\n const TooltipComponent = (_ref4 = (_slots$tooltip = slots.tooltip) != null ? _slots$tooltip : components.Tooltip) != null ? _ref4 : TooltipTooltip;\n const ArrowComponent = (_ref5 = (_slots$arrow = slots.arrow) != null ? _slots$arrow : components.Arrow) != null ? _ref5 : TooltipArrow;\n const popperProps = appendOwnerState(PopperComponent, _extends({}, PopperProps, (_slotProps$popper = slotProps.popper) != null ? _slotProps$popper : componentsProps.popper, {\n className: clsx(classes.popper, PopperProps == null ? void 0 : PopperProps.className, (_ref6 = (_slotProps$popper2 = slotProps.popper) != null ? _slotProps$popper2 : componentsProps.popper) == null ? void 0 : _ref6.className)\n }), ownerState);\n const transitionProps = appendOwnerState(TransitionComponent, _extends({}, TransitionProps, (_slotProps$transition = slotProps.transition) != null ? _slotProps$transition : componentsProps.transition), ownerState);\n const tooltipProps = appendOwnerState(TooltipComponent, _extends({}, (_slotProps$tooltip = slotProps.tooltip) != null ? _slotProps$tooltip : componentsProps.tooltip, {\n className: clsx(classes.tooltip, (_ref7 = (_slotProps$tooltip2 = slotProps.tooltip) != null ? _slotProps$tooltip2 : componentsProps.tooltip) == null ? void 0 : _ref7.className)\n }), ownerState);\n const tooltipArrowProps = appendOwnerState(ArrowComponent, _extends({}, (_slotProps$arrow = slotProps.arrow) != null ? _slotProps$arrow : componentsProps.arrow, {\n className: clsx(classes.arrow, (_ref8 = (_slotProps$arrow2 = slotProps.arrow) != null ? _slotProps$arrow2 : componentsProps.arrow) == null ? void 0 : _ref8.className)\n }), ownerState);\n return /*#__PURE__*/_jsxs(React.Fragment, {\n children: [/*#__PURE__*/React.cloneElement(children, childrenProps), /*#__PURE__*/_jsx(PopperComponent, _extends({\n as: PopperComponentProp != null ? PopperComponentProp : Popper,\n placement: placement,\n anchorEl: followCursor ? {\n getBoundingClientRect: () => ({\n top: cursorPosition.y,\n left: cursorPosition.x,\n right: cursorPosition.x,\n bottom: cursorPosition.y,\n width: 0,\n height: 0\n })\n } : childNode,\n popperRef: popperRef,\n open: childNode ? open : false,\n id: id,\n transition: true\n }, interactiveWrapperListeners, popperProps, {\n popperOptions: popperOptions,\n children: ({\n TransitionProps: TransitionPropsInner\n }) => /*#__PURE__*/_jsx(TransitionComponent, _extends({\n timeout: theme.transitions.duration.shorter\n }, TransitionPropsInner, transitionProps, {\n children: /*#__PURE__*/_jsxs(TooltipComponent, _extends({}, tooltipProps, {\n children: [title, arrow ? /*#__PURE__*/_jsx(ArrowComponent, _extends({}, tooltipArrowProps, {\n ref: setArrowRef\n })) : null]\n }))\n }))\n }))]\n });\n});\nprocess.env.NODE_ENV !== \"production\" ? Tooltip.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the d.ts file and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * If `true`, adds an arrow to the tooltip.\n * @default false\n */\n arrow: PropTypes.bool,\n /**\n * Tooltip reference element.\n */\n children: elementAcceptingRef.isRequired,\n /**\n * Override or extend the styles applied to the component.\n */\n classes: PropTypes.object,\n /**\n * @ignore\n */\n className: PropTypes.string,\n /**\n * The components used for each slot inside.\n *\n * This prop is an alias for the `slots` prop.\n * It's recommended to use the `slots` prop instead.\n *\n * @default {}\n */\n components: PropTypes.shape({\n Arrow: PropTypes.elementType,\n Popper: PropTypes.elementType,\n Tooltip: PropTypes.elementType,\n Transition: PropTypes.elementType\n }),\n /**\n * The extra props for the slot components.\n * You can override the existing props or add new ones.\n *\n * This prop is an alias for the `slotProps` prop.\n * It's recommended to use the `slotProps` prop instead, as `componentsProps` will be deprecated in the future.\n *\n * @default {}\n */\n componentsProps: PropTypes.shape({\n arrow: PropTypes.object,\n popper: PropTypes.object,\n tooltip: PropTypes.object,\n transition: PropTypes.object\n }),\n /**\n * Set to `true` if the `title` acts as an accessible description.\n * By default the `title` acts as an accessible label for the child.\n * @default false\n */\n describeChild: PropTypes.bool,\n /**\n * Do not respond to focus-visible events.\n * @default false\n */\n disableFocusListener: PropTypes.bool,\n /**\n * Do not respond to hover events.\n * @default false\n */\n disableHoverListener: PropTypes.bool,\n /**\n * Makes a tooltip not interactive, i.e. it will close when the user\n * hovers over the tooltip before the `leaveDelay` is expired.\n * @default false\n */\n disableInteractive: PropTypes.bool,\n /**\n * Do not respond to long press touch events.\n * @default false\n */\n disableTouchListener: PropTypes.bool,\n /**\n * The number of milliseconds to wait before showing the tooltip.\n * This prop won't impact the enter touch delay (`enterTouchDelay`).\n * @default 100\n */\n enterDelay: PropTypes.number,\n /**\n * The number of milliseconds to wait before showing the tooltip when one was already recently opened.\n * @default 0\n */\n enterNextDelay: PropTypes.number,\n /**\n * The number of milliseconds a user must touch the element before showing the tooltip.\n * @default 700\n */\n enterTouchDelay: PropTypes.number,\n /**\n * If `true`, the tooltip follow the cursor over the wrapped element.\n * @default false\n */\n followCursor: PropTypes.bool,\n /**\n * This prop is used to help implement the accessibility logic.\n * If you don't provide this prop. It falls back to a randomly generated id.\n */\n id: PropTypes.string,\n /**\n * The number of milliseconds to wait before hiding the tooltip.\n * This prop won't impact the leave touch delay (`leaveTouchDelay`).\n * @default 0\n */\n leaveDelay: PropTypes.number,\n /**\n * The number of milliseconds after the user stops touching an element before hiding the tooltip.\n * @default 1500\n */\n leaveTouchDelay: PropTypes.number,\n /**\n * Callback fired when the component requests to be closed.\n *\n * @param {React.SyntheticEvent} event The event source of the callback.\n */\n onClose: PropTypes.func,\n /**\n * Callback fired when the component requests to be open.\n *\n * @param {React.SyntheticEvent} event The event source of the callback.\n */\n onOpen: PropTypes.func,\n /**\n * If `true`, the component is shown.\n */\n open: PropTypes.bool,\n /**\n * Tooltip placement.\n * @default 'bottom'\n */\n placement: PropTypes.oneOf(['bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n /**\n * The component used for the popper.\n * @default Popper\n */\n PopperComponent: PropTypes.elementType,\n /**\n * Props applied to the [`Popper`](/material-ui/api/popper/) element.\n * @default {}\n */\n PopperProps: PropTypes.object,\n /**\n * The extra props for the slot components.\n * You can override the existing props or add new ones.\n *\n * This prop is an alias for the `componentsProps` prop, which will be deprecated in the future.\n *\n * @default {}\n */\n slotProps: PropTypes.shape({\n arrow: PropTypes.object,\n popper: PropTypes.object,\n tooltip: PropTypes.object,\n transition: PropTypes.object\n }),\n /**\n * The components used for each slot inside.\n *\n * This prop is an alias for the `components` prop, which will be deprecated in the future.\n *\n * @default {}\n */\n slots: PropTypes.shape({\n arrow: PropTypes.elementType,\n popper: PropTypes.elementType,\n tooltip: PropTypes.elementType,\n transition: PropTypes.elementType\n }),\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Tooltip title. Zero-length titles string, undefined, null and false are never displayed.\n */\n title: PropTypes.node,\n /**\n * The component used for the transition.\n * [Follow this guide](/material-ui/transitions/#transitioncomponent-prop) to learn more about the requirements for this component.\n * @default Grow\n */\n TransitionComponent: PropTypes.elementType,\n /**\n * Props applied to the transition element.\n * By default, the element is based on this [`Transition`](http://reactcommunity.org/react-transition-group/transition/) component.\n */\n TransitionProps: PropTypes.object\n} : void 0;\nexport default Tooltip;","import '@/components/mui/menu-item.component.css';\nimport ArrowRightIcon from '@mui/icons-material/ArrowRight';\nimport {\n ListItemIcon as MuiListItemIcon,\n ListItemText as MuiListItemText,\n MenuItem as MuiMenuItem,\n} from '@mui/material';\nimport Tooltip from '@mui/material/Tooltip';\nimport { Localized, ReferencedItem, SingleColumnMenu } from 'platform-bible-utils';\nimport { MouseEvent, PropsWithChildren } from 'react';\n\ntype MenuItemInfoBase = {\n /** Text (displayable in the UI) as the name of the menu item */\n label: string;\n /** Text to display when the mouse hovers over the menu item */\n tooltip?: string;\n};\n\nexport type Command = MenuItemInfoBase & {\n /** Command to execute (string.string) */\n command: string;\n};\n\ntype SubMenu = MenuItemInfoBase & {\n /** Command to execute (string.string) */\n items: MenuItemInfo[];\n};\n\nexport interface CommandHandler {\n (command: Command): void;\n}\n\nexport type MenuPropsBase = {\n /*\n * The JSON defining the menu whose items are to be rendered. This will typically be one of the\n * menus in the \"defs\" in a Platform.Bible menu (see PlatformMenus). The schema for this is\n * menuDocumentSchema (at the end of menus.model.ts). Note that while this is a\n * \"SingleColumnMenu\", somewhat bizarrely, a MultiColumnMenu is a SingleColumnMenu, so it really\n * could be a MultiColumnMenu, in which case, column had better be defined so it can be used\n * to filter out the actual groups and items to display on the column.\n */\n menuDefinition: Localized;\n\n commandHandler: CommandHandler;\n\n /**\n * Additional action to perform when any menu item is clicked. Allows the caller to handle event\n * (e.g., to close the menu).\n */\n onClick?: (event: MouseEvent) => void;\n};\n\nexport type MenuItemListProps = MenuPropsBase & {\n /** Optional unique (column) identifier */\n columnId?: ReferencedItem;\n};\n\nexport type MenuItemProps = Omit &\n PropsWithChildren<{\n /** Optional unique identifier */\n id?: string;\n\n onClick: (event: MouseEvent) => void;\n }>;\n\ntype MenuItemInfo = (Command | SubMenu) & {\n /**\n * If specified, menu item will be inset if it does not have a leading icon.\n *\n * @default true\n */\n allowForLeadingIcons?: boolean;\n /**\n * If specified, the path to the icon image to display on the leading side of the menu text.\n *\n * @default undefined (no leading icon will be shown)\n */\n iconPathBefore?: string;\n /**\n * If specified, the path to the icon image to display on the trailing side of the menu text.\n *\n * @default undefined (no trailing icon will be shown)\n */\n iconPathAfter?: string;\n /**\n * If true, list item is focused during the first mount\n *\n * @default false\n */\n hasAutoFocus?: boolean;\n\n /** Additional css classes to help with unique styling of the menu item */\n className?: string;\n\n /**\n * If true, the menu item will appear disabled and it will not respond to clicks or mouse hovers.\n *\n * @default false\n */\n isDisabled?: boolean;\n\n /**\n * If true, compact vertical padding designed for keyboard and mouse input is used.\n *\n * @default true\n */\n isDense?: boolean;\n\n /**\n * If true, a right-arrow icon will be displayed (iconPathAfter, if specified, will be ignored).\n *\n * @default false\n */\n isSubMenuParent?: boolean;\n\n /**\n * If true, the left and right padding is removed\n *\n * @default false\n */\n hasDisabledGutters?: boolean;\n\n /**\n * If true, a 1px light border is added to bottom of menu item\n *\n * @default false\n */\n hasDivider?: boolean;\n\n /** Help identify which element has keyboard focus */\n focusVisibleClassName?: string;\n\n /** If it's a submenu, it should have the items property */\n items?: MenuItemInfo[];\n};\n\nfunction getIcon(icon: string | undefined, menuLabel: string, leading: boolean) {\n return icon ? (\n \n {`${leading\n \n ) : undefined;\n}\n\nexport default function MenuItem(props: MenuItemProps) {\n const {\n onClick,\n label,\n tooltip,\n allowForLeadingIcons = true,\n iconPathBefore = undefined,\n iconPathAfter = undefined,\n hasAutoFocus = false,\n className,\n isDisabled = false,\n isDense = true,\n isSubMenuParent = false,\n hasDisabledGutters = false,\n hasDivider = false,\n focusVisibleClassName,\n id,\n children,\n } = props;\n\n const menuItem = (\n \n {label ? (\n <>\n {getIcon(iconPathBefore, label, true)}\n \n {isSubMenuParent ? (\n \n \n \n ) : (\n getIcon(iconPathAfter, label, false)\n )}\n \n ) : (\n children\n )}\n \n );\n\n return tooltip ? (\n \n
    {menuItem}
    \n
    \n ) : (\n menuItem\n );\n}\n","import MenuItem, {\n MenuItemListProps,\n MenuItemProps,\n MenuPropsBase,\n} from '@/components/mui/menu-item.component';\nimport { Menu } from '@mui/material';\nimport {\n Localized,\n MenuGroupDetailsInSubMenu,\n MenuItemContainingCommand,\n MenuItemContainingSubmenu,\n OrderedExtensibleContainer,\n ReferencedItem,\n SingleColumnMenu,\n} from 'platform-bible-utils';\nimport { MouseEvent, useMemo, useState } from 'react';\n\n/**\n * All the exported types in this file should be regarded as \"internal\" (i.e., they should not be\n * exposed via index.ts).\n */\n\nexport type GroupedMenuPropsBase = MenuPropsBase & {\n /** Optional unique (column) identifier */\n columnId?: ReferencedItem;\n};\n\nexport type GroupedMenuItemListProps = MenuItemListProps & {\n /**\n * If the menuDefinition includes \"top-level\" groups (i.e., those that belong to a column as\n * opposed to those that belong to a submenu) that should not be included in the list, then this\n * array specifies which groups to include. Likewise, for a submenu, this list indicates which\n * groups are pertinent for that submenu. So then for a context menu this property need not be\n * specified since it is a top-level menu based on a \"true\" SingleColumnMenu (i.e., one that is\n * not a MultiColumnMenu).\n */\n includedGroups?: {\n id: string;\n group: Localized;\n }[];\n};\n\ninterface ItemInfo {\n item: Localized;\n isLastItemInGroup: boolean;\n}\n\ntype SubMenuProps = MenuPropsBase & {\n parentMenuItem: Localized;\n parentItemProps: Omit, 'iconPathAfter'>;\n};\n\nfunction getAllGroups(menuDefinition: Localized) {\n const groupEntries = Object.entries(menuDefinition.groups);\n // Convert array of entries to array of objects with id and group properties\n return groupEntries.map(([key, value]) => ({ id: key, group: value }));\n}\n\nfunction SubMenu(props: SubMenuProps) {\n const [anchorEl, setAnchorEl] = useState(undefined);\n\n const { parentMenuItem, parentItemProps, menuDefinition } = props;\n\n const handleParentMenuItemClick = (event: MouseEvent) => {\n setAnchorEl(event.currentTarget);\n };\n\n const handleClose = () => {\n setAnchorEl(undefined);\n };\n\n const renderSubMenuItems = () => {\n let includedGroups = getAllGroups(menuDefinition).filter((g) => 'menuItem' in g.group);\n\n // Ensure valid parent menu was provided. (If not, submenu will contain all groups!)\n if (!parentMenuItem?.id) throw new Error('A valid parent menu item is required for submenus.');\n\n // When laying out a submenu, only include groups associated with the provided parent menu.\n // Note: without the (annoying) redundant check that the included groups\n // have the menuItem field, TS doesn't think it exists.\n includedGroups = includedGroups.filter(\n (group) => 'menuItem' in group.group && group.group.menuItem === parentMenuItem.id,\n );\n\n return ;\n };\n\n return (\n <>\n \n \n {renderSubMenuItems()}\n \n \n );\n}\n\nconst getOrderedGroupItems = (\n groupId: string,\n allItems: Localized[],\n) => {\n // Filter items that belong to the specified group\n const itemsForGroup = allItems.filter((item) => item.group === groupId);\n // Sort items based on order\n const sortedItems = itemsForGroup.sort((a, b) => (a.order || 0) - (b.order || 0));\n return sortedItems;\n};\n\n/**\n * This component is internal; it does not need to be exposed to the outside world since it is not\n * useful on its own. It is used to generate and lay out the MenuItems that appear either on a\n * top-level menu (in a GridMenu or ContextMenu) or in a submenu.\n */\nexport default function GroupedMenuItemList(menuProps: GroupedMenuItemListProps) {\n const { menuDefinition, onClick, commandHandler, includedGroups } = menuProps;\n\n const { items, allowForLeadingIcons } = useMemo(() => {\n const groupsToInclude =\n includedGroups && includedGroups.length > 0\n ? includedGroups\n : // We're apparently laying out a single-column menu (presumably a context menu). In this\n // case, all groups should be included except ones that belong to a submenu.\n getAllGroups(menuDefinition).filter((g) => !('menuItem' in g.group));\n\n const sortedGroups = Object.values(groupsToInclude).sort(\n (a, b) => (a.group.order || 0) - (b.group.order || 0),\n );\n\n const itemArray: ItemInfo[] = [];\n\n sortedGroups.forEach((group) => {\n getOrderedGroupItems(group.id, menuDefinition.items).forEach((item) =>\n itemArray.push({ item, isLastItemInGroup: false }),\n );\n if (itemArray.length > 0) itemArray[itemArray.length - 1].isLastItemInGroup = true;\n });\n\n // No divider after last item in final group.\n if (itemArray.length > 0) itemArray[itemArray.length - 1].isLastItemInGroup = false;\n\n const allowSpaceForLeadingIcons = itemArray.some(\n (i) => 'iconPathBefore' in i.item && i.item.iconPathBefore,\n );\n\n return { items: itemArray, allowForLeadingIcons: allowSpaceForLeadingIcons };\n }, [includedGroups, menuDefinition]);\n\n // Create props for MenuItem component including setting hasDivider for the last item in a group\n const createMenuItemProps = ({ item, isLastItemInGroup }: ItemInfo) => {\n const menuItemProps = {\n className: 'papi-menu-item',\n label: item.label,\n tooltip: item.tooltip,\n iconPathBefore: 'iconPathBefore' in item ? item.iconPathBefore : undefined,\n iconPathAfter: 'iconPathAfter' in item ? item.iconPathAfter : undefined,\n hasDivider: isLastItemInGroup, // Set hasDivider to true for the last item in a group\n allowForLeadingIcons,\n };\n\n return menuItemProps;\n };\n\n const [firstItem] = items;\n\n if (!firstItem) return
    ;\n\n const divKey = firstItem.item.group;\n\n return (\n
    \n {items.map((itemInfo, index) => {\n const { item } = itemInfo;\n const menuItemProps = createMenuItemProps(itemInfo);\n if ('command' in item) {\n const key = item.group + index;\n return (\n ) => {\n onClick?.(event);\n commandHandler(item);\n }}\n {...menuItemProps}\n />\n );\n }\n return (\n \n );\n })}\n
    \n );\n}\n","import GroupedMenuItemList from '@/components/mui/grouped-menu-item-list.component';\nimport { MenuItemListProps } from '@/components/mui/menu-item.component';\nimport { MultiColumnMenu } from 'platform-bible-utils';\n\n/**\n * This component is internal; it does not need to be exposed to the outside world since it is not\n * useful on its own. Use either GridMenu or ContextMenu.\n */\nexport default function TopLevelMenu(props: MenuItemListProps) {\n const { menuDefinition, columnId } = props;\n\n const groupEntries = Object.entries(menuDefinition.groups);\n // Convert array of entries to array of objects with id and group properties\n const groups = groupEntries.map(([key, value]) => ({ id: key, group: value }));\n let includedGroups = groups.filter((g) => 'column' in g.group);\n\n // Check if column is provided and menuDefinition is a MultiColumnMenu\n if (\n columnId &&\n 'columns' in menuDefinition &&\n // Without this type assertion, TS doesn't know what columns is.\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n (menuDefinition as MultiColumnMenu).columns[columnId]\n ) {\n // When laying out a single column in a MultiColumnMenu, only include groups associated with\n // the provided column. Note: without the (annoying) redundant check that the included groups\n // have the colum field, TS doesn't think it exists.\n includedGroups = includedGroups.filter(\n (g) => 'column' in g.group && g.group.column === columnId,\n );\n }\n\n return ;\n}\n","import '@/components/mui/grid-menu.component.css';\nimport { GroupedMenuPropsBase } from '@/components/mui/grouped-menu-item-list.component';\nimport { CommandHandler } from '@/components/mui/menu-item.component';\nimport TopLevelMenu from '@/components/mui/top-level-menu.component';\nimport { Grid, List } from '@mui/material';\nimport {\n Localized,\n MenuColumnWithHeader,\n MultiColumnMenu,\n ReferencedItem,\n} from 'platform-bible-utils';\nimport { useMemo } from 'react';\n\ntype ColumnInfo = {\n /*\n * The ID (`${string}.${string}`) of a specific menu column.\n */\n id: ReferencedItem;\n\n /*\n * Metadata (label, order, etc.) for a specific menu column.\n */\n metadata: Localized;\n};\n\ntype MenuColumnProps = ColumnInfo &\n GroupedMenuPropsBase & {\n /** Additional css classes to help with unique styling of the menu column */\n className?: string;\n };\n\nexport type GridMenuInfo = {\n /** The menu object containing information about the columns, groups, and items to display. */\n multiColumnMenu: Localized;\n};\n\nexport type GridMenuProps = GridMenuInfo & {\n /** Optional unique identifier */\n id?: string;\n\n commandHandler: CommandHandler;\n\n /** Additional css classes to help with unique styling of the grid menu */\n className?: string;\n};\n\nfunction MenuColumn({\n commandHandler,\n menuDefinition,\n id,\n metadata,\n onClick,\n className,\n}: MenuColumnProps) {\n return (\n \n

    \n {metadata.label}\n

    \n {/* It would seem as though this List component were unnecessary, since it only contains one\n thing, but the \"dense\" property does affect the layout of the items (in a way I don't fully\n understand). There might be a better way. */}\n \n \n \n \n );\n}\n\nexport default function GridMenu({\n commandHandler,\n className,\n multiColumnMenu,\n id,\n}: GridMenuProps) {\n const { columns } = multiColumnMenu;\n\n const sortedColumns = useMemo(() => {\n const columnNumbers = new Map();\n Object.getOwnPropertyNames(columns).forEach((columnName: string) => {\n // We know for sure there is a (boolean) property 'isExtensible' that we are not interested in.\n if (columnName === 'isExtensible') return;\n // TS doesn't allow `columnName` above to be a ReferencedItem even though the type says it is\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const columnId = columnName as ReferencedItem;\n const column = columns[columnId];\n // As of right now (and hopefully forever after), all remaining properties of the\n // ColumnsWithHeaders object are columns whose property names are the IDs of the columns.\n // This is an additional (redundant) sanity check. Specifically we're interested in\n // MenuColumnWithHeader objects, which TypeScript now \"knows\" we have, but at runtime all we\n // can check for is that it's an object with a valid numeric order field. That's likely good\n // enough.\n if (\n typeof column === 'object' &&\n typeof column.order === 'number' &&\n !Number.isNaN(column.order)\n )\n columnNumbers.set(column.order, { id: columnId, metadata: column });\n else\n console.warn(\n `Property ${columnName} (${typeof column}) on menu ${id} is not a valid column and is being ignored. This might indicate data corruption`,\n );\n });\n\n // Extract values and sort them based on the 'order' property\n return Array.from(columnNumbers.values()).sort((a, b) => {\n return (a.metadata.order || 0) - (b.metadata.order || 0);\n });\n }, [columns, id]);\n\n // We might need something like this if we need to be able to prevent empty columns\n // sortedColumns.filter((c) => multiColumnMenu.groups.some((g) => 'column' in g && (g as .column)...\n\n return (\n \n {sortedColumns.map((col, index) => (\n \n ))}\n \n );\n}\n","import { useEffect, useRef, useState } from 'react';\n\nexport type UsePromiseOptions = {\n /**\n * Whether to leave the value as the most recent resolved promise value or set it back to\n * defaultValue while running the promise again. Defaults to true\n */\n preserveValue?: boolean;\n};\n\n/** Set up defaults for options for usePromise hook */\nfunction getUsePromiseOptionsDefaults(options: UsePromiseOptions): UsePromiseOptions {\n return {\n preserveValue: true,\n ...options,\n };\n}\n\n/**\n * Awaits a promise and returns a loading value while the promise is unresolved\n *\n * @param promiseFactoryCallback A function that returns the promise to await. If this callback is\n * undefined, the current value will be returned (defaultValue unless it was previously changed\n * and `options.preserveValue` is true), and there will be no loading.\n *\n * WARNING: MUST BE STABLE - const or wrapped in useCallback. The reference must not be updated\n * every render\n * @param defaultValue The initial value to return while first awaiting the promise. If\n * `options.preserveValue` is false, this value is also shown while awaiting the promise on\n * subsequent calls.\n *\n * Note: this parameter is internally assigned to a `ref`, so changing it will not cause any hooks\n * to re-run with its new value. This means that, if the `promiseFactoryCallback` changes and\n * `options.preserveValue` is `false`, the returned value will be set to the current\n * `defaultValue`. However, the returned value will not be updated if`defaultValue` changes.\n * @param options Various options for adjusting how this hook runs the `promiseFactoryCallback`\n *\n * Note: this parameter is internally assigned to a `ref`, so changing it will not cause any hooks\n * to re-run with its new value. However, the latest `options.preserveValue` will always be used\n * appropriately to determine whether to preserve the returned value when changing the\n * `promiseFactoryCallback`\n * @returns `[value, isLoading]`\n *\n * - `value`: the current value for the promise, either the defaultValue or the resolved promise value\n * - `isLoading`: whether the promise is waiting to be resolved\n */\nconst usePromise = (\n promiseFactoryCallback: (() => Promise) | undefined,\n defaultValue: T,\n options: UsePromiseOptions = {},\n): [value: T, isLoading: boolean] => {\n // Use defaultValue as a ref so it doesn't update dependency arrays\n const defaultValueRef = useRef(defaultValue);\n defaultValueRef.current = defaultValue;\n // Use options as a ref so it doesn't update dependency arrays\n const optionsDefaultedRef = useRef(options);\n optionsDefaultedRef.current = getUsePromiseOptionsDefaults(optionsDefaultedRef.current);\n\n const [value, setValue] = useState(() => defaultValueRef.current);\n const [isLoading, setIsLoading] = useState(true);\n useEffect(() => {\n let promiseIsCurrent = true;\n // If a promiseFactoryCallback was provided, we are loading. Otherwise, there is no loading to do\n setIsLoading(!!promiseFactoryCallback);\n (async () => {\n // If there is a callback to run, run it\n if (promiseFactoryCallback) {\n const result = await promiseFactoryCallback();\n // If the promise was not already replaced, update the value\n if (promiseIsCurrent) {\n setValue(() => result);\n setIsLoading(false);\n }\n }\n })();\n\n return () => {\n // Mark this promise as old and not to be used\n promiseIsCurrent = false;\n if (!optionsDefaultedRef.current.preserveValue) setValue(() => defaultValueRef.current);\n };\n }, [promiseFactoryCallback]);\n\n return [value, isLoading];\n};\nexport default usePromise;\n","\"use client\";\n\nimport createSvgIcon from './utils/createSvgIcon';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nexport default createSvgIcon( /*#__PURE__*/_jsx(\"path\", {\n d: \"M3 18h18v-2H3zm0-5h18v-2H3zm0-7v2h18V6z\"\n}), 'Menu');","import GridMenu from '@/components/mui/grid-menu.component';\nimport { Command, CommandHandler } from '@/components/mui/menu-item.component';\nimport usePromise from '@/hooks/use-promise.hook';\nimport { Menu as MenuIcon } from '@mui/icons-material';\nimport { Drawer, IconButton } from '@mui/material';\nimport { Localized, MultiColumnMenu } from 'platform-bible-utils';\nimport {\n MouseEvent,\n MutableRefObject,\n PropsWithChildren,\n useCallback,\n useEffect,\n useState,\n} from 'react';\n\nexport interface MultiColumnMenuProvider {\n (isSupportAndDevelopment: boolean): Promise>;\n}\n\nexport type HamburgerMenuButtonProps = PropsWithChildren & {\n /** The handler to use for menu commands (and eventually toolbar commands). */\n commandHandler: CommandHandler;\n\n /**\n * Optional reference to the \"div\" container that determines the where the menu should appear. If\n * not defined, then (1,1) used.\n */\n containerRef?: MutableRefObject;\n\n /**\n * The delegate to use to get the menu data. If not specified or if it returns undefined, the data\n * in normalMenu or fullMenu property will be used.\n */\n menuProvider?: MultiColumnMenuProvider;\n\n /**\n * The menu data to show when the menu is opened if the menuProvider property is not defined.\n * (This allows for a default or test-only static menu to be used.)\n */\n normalMenu?: Localized;\n\n /**\n * The menu data to show for \"full\" menu (when opened with the SHIFT key pressed) if the\n * menuProvider property is not defined. (This allows for a default or test-only static menu to be\n * used.)\n */\n fullMenu?: Localized;\n\n /** Additional css class(es) to help with unique styling of the sub-components */\n className?: string;\n\n /** Value to use as prefix for ARIA labels on interactive sub-components */\n ariaLabelPrefix?: string;\n};\n\nexport default function HamburgerMenuButton({\n menuProvider,\n normalMenu,\n fullMenu,\n commandHandler,\n containerRef,\n className,\n ariaLabelPrefix,\n children,\n}: HamburgerMenuButtonProps) {\n const [isMenuOpen, setMenuOpen] = useState(false);\n const [showFullMenu, setShowFullMenu] = useState(false);\n\n const handleMenuItemClick = useCallback(() => {\n if (isMenuOpen) setMenuOpen(false);\n setShowFullMenu(false);\n }, [isMenuOpen]);\n\n const handleMenuButtonClick = useCallback((e: MouseEvent) => {\n e.stopPropagation();\n setMenuOpen((prevIsOpen) => {\n const isOpening = !prevIsOpen;\n if (isOpening && e.shiftKey) setShowFullMenu(true);\n else if (!isOpening) setShowFullMenu(false);\n return isOpening;\n });\n }, []);\n\n const menuCommandHandler = useCallback(\n (command: Command) => {\n handleMenuItemClick();\n return commandHandler(command);\n },\n [commandHandler, handleMenuItemClick],\n );\n\n const [offset, setOffset] = useState({ top: 1, left: 1 });\n\n useEffect(() => {\n if (isMenuOpen) {\n const node = containerRef?.current;\n if (node) {\n const rect = node.getBoundingClientRect();\n const scrollTop = window.scrollY;\n const scrollLeft = window.scrollX;\n const top = rect.top + scrollTop + node.clientHeight;\n const left = rect.left + scrollLeft;\n setOffset({ top, left });\n }\n }\n }, [isMenuOpen, containerRef]);\n\n const [normalMenuData] = usePromise(\n useCallback(async () => {\n return menuProvider?.(false) ?? normalMenu;\n // isMenuOpen needs to be included for the menu contents to reevaluate when reopened\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [menuProvider, normalMenu, isMenuOpen]),\n normalMenu,\n );\n\n const [fullMenuData] = usePromise(\n useCallback(async () => {\n return menuProvider?.(true) ?? fullMenu ?? normalMenuData;\n // isMenuOpen needs to be included for the menu contents to reevaluate when reopened\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [menuProvider, fullMenu, normalMenuData, isMenuOpen]),\n fullMenu ?? normalMenuData,\n );\n\n const menu = showFullMenu && fullMenuData ? fullMenuData : normalMenuData;\n\n return (\n <>\n \n {children ?? }\n \n \n {menu ? (\n \n ) : undefined}\n \n \n );\n}\n","import '@/components/mui/icon-button.component.css';\nimport { IconButton as MuiIconButton } from '@mui/material';\nimport { MouseEventHandler, PropsWithChildren } from 'react';\n\nexport type IconButtonProps = PropsWithChildren<{\n /** Optional unique identifier */\n id?: string;\n /**\n * Required. Used as both the tooltip (aka, title) and the aria-label (used for accessibility,\n * testing, etc.), unless a distinct tooltip is supplied.\n */\n label: string;\n /**\n * Enabled status of button\n *\n * @default false\n */\n isDisabled?: boolean;\n /** Optional tooltip to display if different from the aria-label. */\n tooltip?: string;\n /** If true, no tooltip will be displayed. */\n isTooltipSuppressed?: boolean;\n /**\n * If given, uses a negative margin to counteract the padding on one side (this is often helpful\n * for aligning the left or right side of the icon with content above or below, without ruining\n * the border size and shape).\n *\n * @default false\n */\n adjustMarginToAlignToEdge?: 'end' | 'start' | false;\n /**\n * The size of the component. small is equivalent to the dense button styling.\n *\n * @default false\n */\n size: 'small' | 'medium' | 'large';\n /** Additional css classes to help with unique styling of the button */\n className?: string;\n /** Optional click handler */\n onClick?: MouseEventHandler;\n}>;\n\n/**\n * Iconic button a user can click to do something\n *\n * Thanks to MUI for heavy inspiration and documentation\n * https://mui.com/material-ui/getting-started/overview/\n */\nfunction IconButton({\n id,\n label,\n isDisabled = false,\n tooltip,\n isTooltipSuppressed = false,\n adjustMarginToAlignToEdge = false,\n size = 'medium',\n className,\n onClick,\n children,\n}: IconButtonProps) {\n return (\n \n {children /* the icon to display */}\n \n );\n}\n\nexport default IconButton;\n","import { cn } from '@/utils/shadcn-ui.util';\nimport { LoaderCircle, LucideProps } from 'lucide-react';\nimport { forwardRef } from 'react';\n\nexport type SpinnerProps = LucideProps;\n\nconst Spinner = forwardRef(({ className, ...props }, ref) => {\n return (\n \n );\n});\n\nSpinner.displayName = 'Spinner';\n\nexport default Spinner;\n","import { Input as ShadInput } from '@/components/shadcn-ui/input';\nimport { Label as ShadLabel } from '@/components/shadcn-ui/label';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { ChangeEventHandler, FocusEventHandler } from 'react';\n\nexport type TextFieldProps = {\n /** Optional unique identifier */\n id?: string;\n /**\n * If `true`, the component is disabled.\n *\n * @default false\n */\n isDisabled?: boolean;\n /**\n * If `true`, the label is displayed in an error state.\n *\n * @default false\n */\n hasError?: boolean;\n /**\n * If `true`, the input will take up the full width of its container.\n *\n * @default false\n */\n isFullWidth?: boolean;\n /** Text that gives the user instructions on what contents the TextField expects */\n helperText?: string;\n /** The title of the TextField */\n label?: string;\n /** The short hint displayed in the `input` before the user enters a value. */\n placeholder?: string;\n /**\n * If `true`, the label is displayed as required and the `input` element is required.\n *\n * @default false\n */\n isRequired?: boolean;\n /** Additional css classes to help with unique styling of the text field */\n className?: string;\n /** Starting value for the text field if it is not controlled */\n defaultValue?: string | number;\n /** Value of the text field if controlled */\n value?: string | number;\n /** Triggers when content of textfield is changed */\n onChange?: ChangeEventHandler;\n /** Triggers when textfield gets focus */\n onFocus?: FocusEventHandler;\n /** Triggers when textfield loses focus */\n onBlur?: FocusEventHandler;\n};\n\n/**\n * Text input field\n *\n * Thanks to Shadcn for heavy inspiration and documentation\n * https://ui.shadcn.com/docs/components/input#with-label\n */\nfunction TextField({\n id,\n isDisabled = false,\n hasError = false,\n isFullWidth = false,\n helperText,\n label,\n placeholder,\n isRequired = false,\n className,\n defaultValue,\n value,\n onChange,\n onFocus,\n onBlur,\n}: TextFieldProps) {\n return (\n
    \n {`${label}${isRequired ? '*' : ''}`}\n \n

    {helperText}

    \n
    \n );\n}\n\nexport default TextField;\n","import HamburgerMenuButton, {\n MultiColumnMenuProvider,\n} from '@/components/mui/hamburger-menu-button.component';\nimport { CommandHandler } from '@/components/mui/menu-item.component';\nimport '@/components/mui/toolbar.component.css';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { AppBar, Toolbar as MuiToolbar } from '@mui/material';\nimport { PropsWithChildren, useRef } from 'react';\n\nexport type ToolbarProps = PropsWithChildren<{\n /** The handler to use for menu commands (and eventually toolbar commands). */\n commandHandler: CommandHandler;\n\n /**\n * The optional delegate to use to get the menu data. If not specified, the \"hamburger\" menu will\n * not display.\n */\n menuProvider?: MultiColumnMenuProvider;\n\n /** Optional unique identifier */\n id?: string;\n\n /** Additional css classes to help with unique styling of the toolbar */\n className?: string;\n}>;\n\nexport default function Toolbar({\n menuProvider,\n commandHandler,\n className,\n id,\n children,\n}: ToolbarProps) {\n // This ref will always be defined\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const containerRef = useRef(undefined!);\n\n return (\n
    \n \n \n {menuProvider ? (\n \n ) : undefined}\n {children ?
    {children}
    : undefined}\n \n
    \n
    \n );\n}\n","import React from 'react';\nimport { cva, type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst alertVariants = cva(\n 'tw-relative tw-w-full tw-rounded-lg tw-border tw-p-4 [&>svg~*]:tw-pl-7 [&>svg+div]:tw-translate-y-[-3px] [&>svg]:tw-absolute [&>svg]:tw-left-4 [&>svg]:tw-top-4 [&>svg]:tw-text-foreground',\n {\n variants: {\n variant: {\n default: 'tw-bg-background tw-text-foreground',\n destructive:\n 'tw-border-destructive/50 tw-text-destructive dark:tw-border-destructive [&>svg]:tw-text-destructive',\n },\n },\n defaultVariants: {\n variant: 'default',\n },\n },\n);\n\nconst Alert = React.forwardRef<\n HTMLDivElement,\n React.HTMLAttributes & VariantProps\n>(({ className, variant, ...props }, ref) => (\n
    \n));\nAlert.displayName = 'Alert';\n\nconst AlertTitle = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n {/* added because of https://github.com/jsx-eslint/eslint-plugin-jsx-a11y/blob/main/docs/rules/heading-has-content.md */}\n {props.children}{' '}\n \n ),\n);\nAlertTitle.displayName = 'AlertTitle';\n\nconst AlertDescription = React.forwardRef<\n HTMLParagraphElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n
    \n));\nAlertDescription.displayName = 'AlertDescription';\n\nexport { Alert, AlertTitle, AlertDescription };\n","import { ComponentProps } from 'react';\nimport { toast as sonner, Toaster } from 'sonner';\n\ntype SonnerProps = ComponentProps;\n\nfunction Sonner({ ...props }: SonnerProps) {\n return (\n \n );\n}\n\n// The re-export of the sonner function was added manually\nexport { Sonner, sonner };\n","import React from 'react';\nimport * as SliderPrimitive from '@radix-ui/react-slider';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Slider = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n \n \n \n));\nSlider.displayName = SliderPrimitive.Root.displayName;\n\nexport { Slider };\n","import React from 'react';\nimport * as SwitchPrimitives from '@radix-ui/react-switch';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Switch = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n));\nSwitch.displayName = SwitchPrimitives.Root.displayName;\n\nexport { Switch };\n","import React from 'react';\nimport * as TabsPrimitive from '@radix-ui/react-tabs';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport const Tabs = TabsPrimitive.Root;\n\nexport type TabsListProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport type TabsTriggerProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport type TabsContentProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport const TabsList = React.forwardRef<\n React.ElementRef,\n TabsListProps\n>(({ className, ...props }, ref) => (\n \n));\nTabsList.displayName = TabsPrimitive.List.displayName;\n\nexport const TabsTrigger = React.forwardRef<\n React.ElementRef,\n TabsTriggerProps\n>(({ className, ...props }, ref) => (\n \n));\nTabsTrigger.displayName = TabsPrimitive.Trigger.displayName;\n\nexport const TabsContent = React.forwardRef<\n React.ElementRef,\n TabsContentProps\n>(({ className, ...props }, ref) => (\n \n));\nTabsContent.displayName = TabsPrimitive.Content.displayName;\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Download } from 'lucide-react';\n\ntype InstallButtonProps = {\n /** The installing boolean value determines the state of the button. */\n isInstalling: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n /** Optional text for the button. */\n buttonText?: string;\n} & ButtonProps;\n\n/**\n * The InstallButton component is a button designed for initiating installs. It includes visuals for\n * active installing and idle states.\n *\n * @param isInstalling The installing boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @param buttonText Optional text for the button.\n * @returns A install button.\n */\nexport default function InstallButton({\n isInstalling,\n handleClick,\n buttonText,\n className,\n ...props\n}: InstallButtonProps) {\n return (\n \n {isInstalling ? (\n \n ) : (\n <>\n \n {buttonText}\n \n )}\n \n );\n}\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\n\ntype EnableButtonProps = {\n /** The enabling boolean value determines the state of the button. */\n isEnabling: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n} & ButtonProps;\n\n/**\n * The EnableButton component is a button designed for initiating enabling of downloads. It includes\n * visuals for active enabling and idle states.\n *\n * @param isEnabling The enabling boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @returns A button that can be used to enable.\n */\nexport default function EnableButton({\n isEnabling,\n handleClick,\n className,\n ...props\n}: EnableButtonProps) {\n return (\n \n {isEnabling ? (\n <>\n \n Enabling...\n \n ) : (\n 'Enable'\n )}\n \n );\n}\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\n\ntype DisableButtonProps = {\n /** The disabling boolean value determines the state of the button. */\n isDisabling: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n} & ButtonProps;\n\n/**\n * The DisableButton component is a button designed for initiating disabling of downloads. It\n * includes visuals for active disabling and idle states.\n *\n * @param isDisabling The disabling boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @returns A button that can be used to disable.\n */\nexport default function DisableButton({\n isDisabling,\n handleClick,\n className,\n ...props\n}: DisableButtonProps) {\n return (\n \n {isDisabling ? (\n <>\n \n Disabling...\n \n ) : (\n 'Disable'\n )}\n \n );\n}\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\n\ntype UpdateButtonProps = {\n /** The updating boolean value determines the state of the button. */\n isUpdating: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n} & ButtonProps;\n\n/**\n * The UpdateButton component is a button designed for initiating updates for downloaded extensions.\n * It includes visuals for active updating and idle states.\n *\n * @param isUpdating The updating boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @returns A button that can be used to update.\n */\nexport default function UpdateButton({\n isUpdating,\n handleClick,\n className,\n ...props\n}: UpdateButtonProps) {\n return (\n \n {isUpdating ? (\n <>\n \n Updating...\n \n ) : (\n 'Update'\n )}\n \n );\n}\n","import { cn } from '@/utils/shadcn-ui.util';\nimport Markdown, { MarkdownToJSX } from 'markdown-to-jsx';\nimport { useMemo } from 'react';\n\ninterface MarkdownRendererProps {\n /** Optional unique identifier */\n id?: string;\n /** The markdown string to render */\n markdown: string;\n className?: string;\n /**\n * The [`target` attribute for `a` html\n * tags](https://developer.mozilla.org/en-US/docs/Web/HTML/Element/a#target). Defaults to not\n * adding a `target` to `a` tags\n */\n anchorTarget?: string;\n}\n\n/**\n * This component renders markdown content given a markdown string. It uses typography styles from\n * the platform.\n *\n * @param markdown The markdown string to render.\n * @param id Optional unique identifier\n * @returns A div containing the rendered markdown content.\n */\nexport default function MarkdownRenderer({\n id,\n markdown,\n className,\n anchorTarget,\n}: MarkdownRendererProps) {\n const options: MarkdownToJSX.Options = useMemo(\n () => ({\n overrides: {\n a: {\n props: {\n target: anchorTarget,\n },\n },\n },\n }),\n [anchorTarget],\n );\n return (\n
    \n {markdown}\n
    \n );\n}\n","import { Filter, ChevronDown } from 'lucide-react';\nimport { forwardRef } from 'react';\nimport { Button } from '@/components/shadcn-ui/button';\n\n/**\n * The FilterButton component is a button designed for initiating filtering of data. It is designed\n * to be used with the dropdown menu. It uses forwardRef to pass the button to the dropdown trigger\n * asChild.\n *\n * @returns A button that can be used to filter.\n */\nconst FilterButton = forwardRef((props, ref) => {\n return (\n \n \n Filter\n \n \n );\n});\n\nexport default FilterButton;\n","import {\n DropdownMenu,\n DropdownMenuTrigger,\n DropdownMenuContent,\n DropdownMenuLabel,\n DropdownMenuGroup,\n DropdownMenuCheckboxItem,\n DropdownMenuRadioItem,\n DropdownMenuSeparator,\n} from '@/components/shadcn-ui/dropdown-menu';\nimport FilterButton from './buttons/filter-button.component';\n\nexport enum DropdownMenuItemType {\n Check,\n Radio,\n}\n\nexport type DropdownItem = {\n /** The label is the text that will be displayed on the dropdown item. */\n label: string;\n /** The itemType determines the DropdownMenuItemType type as either Check or Radio. */\n itemType: DropdownMenuItemType;\n /** The onClick function is called when the item is clicked. */\n onClick: () => void;\n};\n\nexport type DropdownGroup = {\n /**\n * The label is the text that will be displayed on the dropdown group. It is used to categorize\n * the items in the group.\n */\n label: string;\n /** The items array contains the items that will be displayed in the dropdown group */\n items: DropdownItem[];\n};\n\nexport type FilterDropdownProps = {\n /** Object unique identifier */\n id?: string;\n /** The groups array contains the groups that will be displayed in the dropdown */\n groups: DropdownGroup[];\n}; // TODO: extend the props later\n\n/**\n * The FilterDropdown component is a dropdown designed for filtering content. It includes groups of\n * items that can be checkboxes or radio items.\n *\n * @param id Optional unique identifier\n * @param groups The groups array contains the groups that will be displayed in the dropdown\n * @returns A filter dropdown.\n */\nexport default function FilterDropdown({ id, groups }: FilterDropdownProps) {\n return (\n
    \n {/* TODO: remove this once the DropDown Menu shadcn has an id prop */}\n \n \n \n \n \n {groups.map((group) => (\n
    \n {group.label}\n \n {group.items.map((item) => (\n
    \n {item.itemType === DropdownMenuItemType.Check ? (\n \n {item.label}\n \n ) : (\n \n {item.label}\n \n )}\n
    \n ))}\n
    \n \n
    \n ))}\n
    \n
    \n
    \n );\n}\n","interface NoExtensionsFoundProps {\n /** Optional unique identifier */\n id?: string;\n /** The message to display */\n message: string;\n}\n/**\n * This component displays a message to the user when no extensions are found in the marketplace.\n *\n * @param id Optional unique identifier\n * @param message The message to display.\n * @returns {JSX.Element} - Returns the message component that displays the message to the user.\n */\nexport default function NoExtensionsFound({ id, message }: NoExtensionsFoundProps) {\n return (\n
    \n
    \n

    {message}

    \n
    \n
    \n );\n}\n","import { CircleHelp, Link as LucideLink, User } from 'lucide-react';\nimport { NumberFormat } from 'platform-bible-utils';\n\n/** Interface that stores the parameters passed to the More Info component */\ninterface MoreInfoProps {\n /** Optional unique identifier */\n id?: string;\n /** The category of the extension */\n category: string;\n /** The number of downloads for the extension */\n downloads: Record;\n /** The languages supported by the extension */\n languages: string[];\n /** The URL to the more info page of the extension */\n moreInfoUrl: string;\n}\n/**\n * This component displays the more info section of the extension which includes the category,\n * number of downloads, languages, and links to the website and support\n *\n * @param id Optional unique identifier\n * @param category The category of the extension\n * @param downloads The number of downloads for the extension\n * @param languages The languages supported by the extension\n * @param moreInfoUrl The URL to the more info page of the extension\n * @returns {JSX.Element} - Returns the more info component that displays the category, number of\n * downloads, languages, and links to the website and support\n */\nexport default function MoreInfo({\n id,\n category,\n downloads,\n languages,\n moreInfoUrl,\n}: MoreInfoProps) {\n /**\n * This constant formats the number of downloads into a more readable format.\n *\n * @example 1000 -> 1K\n *\n * @example 1000000 -> 1M\n *\n * @returns The formatted number of downloads\n */\n const numberFormatted = new NumberFormat('en', {\n notation: 'compact',\n compactDisplay: 'short',\n }).format(Object.values(downloads).reduce((a: number, b: number) => a + b, 0));\n\n /** This function scrolls the window to the bottom of the page. */\n const handleScrollToBottom = () => {\n window.scrollTo(0, document.body.scrollHeight);\n };\n\n return (\n \n
    \n
    \n {category}\n
    \n CATEGORY\n
    \n
    \n
    \n
    \n \n {numberFormatted}\n
    \n USERS\n
    \n
    \n
    \n
    \n {languages.slice(0, 3).map((locale) => (\n \n {locale.toUpperCase()}\n \n ))}\n
    \n {languages.length > 3 && (\n handleScrollToBottom()}\n className=\"tw-text-xs tw-text-gray-500 tw-underline\"\n >\n +{languages.length - 3} more languages\n \n )}\n
    \n
    \n
    \n \n Website\n \n \n \n Support\n \n \n
    \n
    \n );\n}\n","import { useState } from 'react';\n\nexport type VersionInformation = {\n /** Date the version was published */\n date: string;\n /** Description of the changes in the version */\n description: string;\n};\n\n/** Type to store the version history information */\nexport type VersionHistoryType = Record;\n\n/** Interface that stores the parameters passed to the Version History component */\ninterface VersionHistoryProps {\n /** Optional unique identifier */\n id?: string;\n /** Object containing the versions mapped with their information */\n versionHistory: VersionHistoryType;\n}\n\n/**\n * Component to render the version history information shown in the footer component. Lists the 5\n * most recent versions, with the options to show all versions by pressing a button.\n *\n * @param versionHistory Object containing the versions mapped with their information\n * @param id Optional unique identifier\n * @returns Rendered version history for the Footer component\n */\nexport default function VersionHistory({ id, versionHistory }: VersionHistoryProps) {\n const [showAllVersions, setShowAllVersions] = useState(false);\n const currentDate = new Date();\n\n /**\n * Function to format the time string for the version history in the form of 'X year(s) ago'.\n *\n * @param dateString ISO Date string to determine the time string from\n * @returns Formatted time string\n */\n function formatTimeString(dateString: string) {\n const date = new Date(dateString);\n const dateDiff = new Date(currentDate.getTime() - date.getTime());\n const yearDiff = dateDiff.getUTCFullYear() - 1970;\n const monthDiff = dateDiff.getUTCMonth();\n const dayDiff = dateDiff.getUTCDate() - 1;\n\n // Determines how long ago the version was published\n let timeString = '';\n if (yearDiff > 0) {\n timeString = `${yearDiff.toString()} year${yearDiff === 1 ? '' : 's'} ago`;\n } else if (monthDiff > 0) {\n timeString = `${monthDiff.toString()} month${monthDiff === 1 ? '' : 's'} ago`;\n } else if (dayDiff === 0) {\n timeString = 'today';\n } else {\n timeString = `${dayDiff.toString()} day${dayDiff === 1 ? '' : 's'} ago`;\n }\n\n return timeString;\n }\n\n // Sorts the version history by version number\n const sortedEntries = Object.entries(versionHistory).sort((a, b) => b[0].localeCompare(a[0]));\n\n return (\n
    \n

    What`s New

    \n
      \n {(showAllVersions ? sortedEntries : sortedEntries.slice(0, 5)).map((entry) => (\n
      \n
      \n
    • \n {entry[1].description}\n
    • \n
      \n
      \n
      Version {entry[0]}
      \n
      {formatTimeString(entry[1].date)}
      \n
      \n
      \n ))}\n
    \n {sortedEntries.length > 5 && (\n setShowAllVersions(!showAllVersions)}\n className=\"tw-text-xs tw-text-gray-500 tw-underline\"\n >\n {showAllVersions ? 'Show Less Version History' : 'Show All Version History'}\n \n )}\n
    \n );\n}\n","import { useMemo } from 'react';\nimport { formatBytes } from 'platform-bible-utils';\nimport VersionHistory, { VersionHistoryType } from './version-history.component';\n\n/** Interface to store the parameters passed to the Footer component */\ninterface FooterProps {\n /** Optional unique identifier */\n id?: string;\n /** Name of the publisher */\n publisherDisplayName: string;\n /** Size of the extension file in bytes */\n fileSize: number;\n /** List of language codes supported by the extension */\n locales: string[];\n /** Object containing the version history mapped with their information */\n versionHistory: VersionHistoryType;\n}\n\n/**\n * Component to render the footer for the extension details which contains information on the\n * publisher, version history, languages, and file size.\n *\n * @param id Optional unique identifier\n * @param publisherDisplayName Name of the publisher\n * @param fileSize Size of the extension file in bytes\n * @param locales List of language codes supported by the extension\n * @param versionHistory Object containing the version history mapped with their information\n * @returns The rendered Footer component\n */\nexport default function Footer({\n id,\n publisherDisplayName,\n fileSize,\n locales,\n versionHistory,\n}: FooterProps) {\n /** Formats the file size into a human-readable format */\n const formattedFileSize = useMemo(() => formatBytes(fileSize), [fileSize]);\n\n /**\n * This function gets the display names of the languages based on the language codes.\n *\n * @param codes The list of language codes\n * @returns The list of language names\n */\n const getLanguageNames = (codes: string[]) => {\n const displayNames = new Intl.DisplayNames(navigator.language, { type: 'language' });\n return codes.map((code) => displayNames.of(code));\n };\n\n const languageNames = getLanguageNames(locales);\n\n return (\n
    \n
    \n \n
    \n
    \n

    Information

    \n
    \n

    \n Publisher\n {publisherDisplayName}\n Size\n {formattedFileSize}\n

    \n
    \n

    \n Languages\n {languageNames.join(', ')}\n

    \n
    \n
    \n
    \n
    \n
    \n );\n}\n","import { PlatformEvent, PlatformEventHandler } from 'platform-bible-utils';\nimport { useEffect } from 'react';\n\n/**\n * Adds an event handler to an event so the event handler runs when the event is emitted. Use\n * `papi.network.getNetworkEvent` to use a networked event with this hook.\n *\n * @param event The event to subscribe to.\n *\n * - If event is a `PlatformEvent`, that event will be used\n * - If event is undefined, the callback will not be subscribed. Useful if the event is not yet\n * available for example\n *\n * @param eventHandler The callback to run when the event is emitted\n *\n * WARNING: MUST BE STABLE - const or wrapped in useCallback. The reference must not be updated\n * every render\n */\nconst useEvent = (\n event: PlatformEvent | undefined,\n eventHandler: PlatformEventHandler,\n) => {\n useEffect(() => {\n // Do nothing if the event is not provided (in case the event is not yet available, for example)\n if (!event) return () => {};\n\n const unsubscriber = event(eventHandler);\n return () => {\n unsubscriber();\n };\n }, [event, eventHandler]);\n};\nexport default useEvent;\n","import { useCallback, useEffect } from 'react';\nimport { PlatformEvent, PlatformEventAsync, PlatformEventHandler } from 'platform-bible-utils';\nimport usePromise from './use-promise.hook';\n\nconst noopUnsubscriber = () => false;\n\n/**\n * Adds an event handler to an asynchronously subscribing/unsubscribing event so the event handler\n * runs when the event is emitted. Use `papi.network.getNetworkEvent` to use a networked event with\n * this hook.\n *\n * @param event The asynchronously (un)subscribing event to subscribe to.\n *\n * - If event is a `PlatformEvent` or `PlatformEventAsync`, that event will be used\n * - If event is undefined, the callback will not be subscribed. Useful if the event is not yet\n * available for example\n *\n * @param eventHandler The callback to run when the event is emitted\n *\n * WARNING: MUST BE STABLE - const or wrapped in useCallback. The reference must not be updated\n * every render\n */\nconst useEventAsync = (\n event: PlatformEvent | PlatformEventAsync | undefined,\n eventHandler: PlatformEventHandler,\n) => {\n // Subscribe to the event asynchronously\n const [unsubscribe] = usePromise(\n useCallback(async () => {\n // Do nothing if the event is not provided (in case the event is not yet available, for example)\n if (!event) return noopUnsubscriber;\n\n // Wrap subscribe and unsubscribe in promises to allow normal events to be used as well\n const unsub = await Promise.resolve(event(eventHandler));\n return async () => unsub();\n }, [eventHandler, event]),\n noopUnsubscriber,\n // We want the unsubscriber to return to default value immediately upon changing subscription\n // So the useEffect below will unsubscribe asap\n { preserveValue: false },\n );\n\n // Unsubscribe from the event asynchronously (but we aren't awaiting the unsub)\n useEffect(() => {\n return () => {\n if (unsubscribe !== noopUnsubscriber) {\n unsubscribe();\n }\n };\n }, [unsubscribe]);\n};\n\nexport default useEventAsync;\n"],"names":["twMergeCustom","extendTailwindMerge","cn","inputs","clsx","Input","React","className","type","props","ref","jsx","BookChapterInput","forwardRef","handleSearch","handleKeyDown","handleOnClick","handleSubmit","jsxs","ShadInput","event","e","History","P","R","t","s","n","N","B","O","S","K","g","k","x","T","X","V","w","L","G","A","H","C","I","y","q","U","m","l","h","c","E","D","i","a","o","u","v","f","d","b","p","J","DropdownMenu","DropdownMenuPrimitive","DropdownMenuTrigger","DropdownMenuGroup","DropdownMenuPortal","DropdownMenuSub","DropdownMenuRadioGroup","DropdownMenuSubTrigger","inset","children","ChevronRight","DropdownMenuSubContent","DropdownMenuContent","sideOffset","DropdownMenuItem","DropdownMenuCheckboxItem","checked","Check","DropdownMenuRadioItem","Circle","DropdownMenuLabel","DropdownMenuSeparator","DropdownMenuShortcut","BookMenuItem","bookId","handleSelectBook","isSelected","handleHighlightBook","bookType","ShadDropdownMenuItem","Canon","ChapterSelect","handleSelectChapter","endChapter","activeChapter","highlightedChapter","handleHighlightedChapter","chapters","_","handleMouse","useCallback","chapterNumber","chapter","GoToMenuItem","handleSort","handleLocationHistory","handleBookmarks","ShadDropdownMenuLabel","ArrowDownWideNarrow","Clock","Bookmark","ALL_BOOK_IDS","BOOK_TYPE_LABELS","BOOK_TYPE_ARRAY","SCROLL_OFFSET","SEARCH_QUERY_FORMATS","fetchGroupedBooks","fetchEndChapter","getChaptersForBook","getAllEnglishNames","isValidBookEnglishName","bookName","getBookIdFromEnglishName","formattedBookName","BookChapterControl","scrRef","searchQuery","setSearchQuery","useState","selectedBookId","setSelectedBookId","setHighlightedChapter","highlightedBookId","setHighlightedBookId","isContentOpen","setIsContentOpen","isContentOpenDelayed","setIsContentOpenDelayed","inputRef","useRef","contentRef","menuItemRef","fetchFilteredBooks","englishNameLowerCase","normalizedQuery","handleSearchInput","searchString","shouldPreventAutoClosing","controlMenuState","open","updateReference","shouldClose","verse","handleInputSubmit","format","matches","book","englishName","handleKeyDownInput","handleKeyDownContent","key","handleKeyDownMenuItem","chapterOffSet","useEffect","useLayoutEffect","scrollTimeout","scrollPosition","ShadDropdownMenu","ShadDropdownMenuTrigger","ShadDropdownMenuContent","bookTypeIndex","element","ShadDropdownMenuSeparator","buttonVariants","cva","Button","variant","size","asChild","Comp","Slot","labelVariants","Label","LabelPrimitive","RadioGroup","RadioGroupPrimitive","RadioGroupItem","Popover","PopoverPrimitive","PopoverTrigger","PopoverContent","align","DialogPortal","DialogPrimitive","DialogOverlay","DialogContent","DialogTitle","DialogDescription","Command","CommandPrimitive","CommandInput","Search","CommandList","CommandEmpty","CommandGroup","CommandSeparator","CommandItem","getOptionLabelDefault","option","ComboBox","id","options","value","onChange","getOptionLabel","buttonPlaceholder","textPlaceholder","commandEmptyMessage","buttonVariant","dir","isDisabled","setOpen","ChevronsUpDown","ChapterRangeSelector","startChapter","handleSelectStartChapter","handleSelectEndChapter","chapterCount","chapterOptions","useMemo","index","onChangeStartChapter","onChangeEndChapter","Fragment","BookSelectionMode","BOOK_SELECTOR_STRING_KEYS","localizeString","strings","BookSelector","handleBookSelectionModeChange","currentBookName","onSelectBooks","selectedBookIds","localizedStrings","currentBookText","chooseText","chooseBooksText","bookSelectionMode","setBookSelectionMode","onSelectionModeChange","newMode","DataTableViewOptions","table","FilterIcon","column","Select","SelectPrimitive","SelectGroup","SelectValue","SelectTrigger","ChevronDown","SelectScrollUpButton","ChevronUp","SelectScrollDownButton","SelectContent","position","SelectLabel","SelectItem","SelectSeparator","DataTablePagination","pageSize","ArrowLeftIcon","ChevronLeftIcon","ChevronRightIcon","ArrowRightIcon","Table","stickyHeader","TableHeader","TableBody","TableFooter","TableRow","TableHead","TableCell","TableCaption","DataTable","columns","data","enablePagination","showPaginationControls","showColumnVisibilityControls","onRowClickHandler","sorting","setSorting","columnFilters","setColumnFilters","columnVisibility","setColumnVisibility","rowSelection","setRowSelection","useReactTable","getCoreRowModel","getPaginationRowModel","getSortedRowModel","getFilteredRowModel","headerGroup","header","flexRender","_a","row","cell","OccurrencesTable","occurrenceData","setScriptureReference","referenceHeaderText","occurrenceHeaderText","occurrences","uniqueOccurrences","occurrence","uniqueOccurrence","deepEqual","Checkbox","CheckboxPrimitive","getLinesFromUSFM","text","getNumberFromUSFM","regex","match","getBookNumFromId","getStatusForItem","item","approvedItems","unapprovedItems","toggleVariants","Toggle","TogglePrimitive","ToggleGroupContext","ToggleGroup","ToggleGroupPrimitive","ToggleGroupItem","context","getSortingIcon","sortDirection","ArrowUpIcon","ArrowDownIcon","ArrowUpDownIcon","inventoryItemColumn","itemLabel","inventoryAdditionalItemColumn","additionalItemLabel","additionalItemIndex","inventoryCountColumn","countLabel","statusChangeHandler","changedItems","newStatus","onApprovedItemsChange","onUnapprovedItemsChange","newApprovedItems","validItem","newUnapprovedItems","unapprovedItem","inventoryStatusColumn","statusLabel","status","CircleCheckIcon","CircleXIcon","CircleHelpIcon","INVENTORY_STRING_KEYS","filterItemData","itemData","statusFilter","textFilter","filteredItemData","createTableData","scriptureRef","itemRegex","tableData","currentBook","currentChapter","currentVerse","line","items","itemIndex","existingItem","tableEntry","newReference","substring","newItem","Inventory","scriptureReference","extractItems","additionalItemsLabels","scope","onScopeChange","allItemsText","approvedItemsText","unapprovedItemsText","unknownItemsText","scopeBookText","scopeChapterText","scopeVerseText","filterText","showAdditionalItemsText","showAdditionalItems","setShowAdditionalItems","setStatusFilter","setTextFilter","selectedItem","setSelectedItem","reducedTableData","newTableData","firstItem","existingEntry","newTableEntry","filteredTableData","allColumns","numberOfAdditionalItems","additionalColumns","_b","rowClickHandler","newSelection","handleScopeChange","handleStatusFilterChange","SearchBar","onSearch","placeholder","isFullWidth","handleInputChange","VerticalTabs","TabsPrimitive","VerticalTabsList","VerticalTabsTrigger","VerticalTabsContent","TabNavigationContentSearch","tabList","searchPlaceholder","headerTitle","isSearchBarFullWidth","direction","tab","Separator","orientation","decorative","SeparatorPrimitive","Sheet","SheetPrimitive","SheetPortal","SheetOverlay","sheetVariants","SheetContent","side","SheetTitle","SheetDescription","Skeleton","TooltipProvider","TooltipPrimitive","Tooltip","TooltipTrigger","TooltipContent","MOBILE_BREAKPOINT","useIsMobile","isMobile","setIsMobile","mql","SIDEBAR_COOKIE_NAME","SIDEBAR_COOKIE_MAX_AGE","SIDEBAR_WIDTH","SIDEBAR_WIDTH_MOBILE","SIDEBAR_WIDTH_ICON","SIDEBAR_KEYBOARD_SHORTCUT","SidebarContext","useSidebar","SidebarProvider","defaultOpen","openProp","setOpenProp","style","openMobile","setOpenMobile","_open","_setOpen","isOpen","openState","toggleSidebar","state","contextValue","Sidebar","collapsible","SidebarTrigger","onClick","PanelLeft","SidebarRail","SidebarInset","SidebarInput","SidebarHeader","SidebarFooter","SidebarSeparator","SidebarContent","SidebarGroup","SidebarGroupLabel","SidebarGroupAction","SidebarGroupContent","SidebarMenu","SidebarMenuItem","sidebarMenuButtonVariants","SidebarMenuButton","isActive","tooltip","button","SidebarMenuAction","showOnHover","SidebarMenuBadge","SidebarMenuSkeleton","showIcon","width","SidebarMenuSub","SidebarMenuSubItem","SidebarMenuSubButton","SettingsSidebar","extensionLabels","handleSelectSidebarItem","handleSelectItem","isProjectSetting","label","SettingsSidebarContentSearch","scrBookColId","scrRefColId","typeColId","detailsColId","defaultScrRefColumnName","defaultScrBookGroupName","defaultTypeColumnName","defaultDetailsColumnName","getColumns","colInfo","showSourceColumn","showSrcCol","info","formatScrRef","compareScrRefs","toRefOrRange","scriptureSelection","offsetStart","offsetEnd","scrRefToBBBCCCVVV","getRowKey","ScriptureResultsViewer","sources","showColumnHeaders","scriptureReferenceColumnName","scriptureBookGroupName","typeColumnName","detailsColumnName","onRowSelected","grouping","setGrouping","scriptureResults","source","getExpandedRowModel","getGroupedRowModel","selectedRows","keys","selectedRow","scrBookGroupName","typeGroupName","groupingOptions","handleSelectChange","selectedGrouping","handleRowClick","getEvenOrOddBandingStyle","getIndent","groupingState","rowIndex","ChevronLeft","DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS","getLocalizeKeyForScrollGroupId","ScrollGroupSelector","availableScrollGroupIds","scrollGroupId","onChangeScrollGroupId","localizedStringsDefaulted","localizedStringKey","localizedStringValue","newScrollGroupString","scrollGroupOptionId","SettingsList","SettingsListItem","primary","secondary","isLoading","loadingMessage","SettingsListHeader","includeSeparator","Card","CardHeader","CardTitle","CardDescription","CardContent","CardFooter","SettingsCard","settingsGroupLabel","settingsGroupDescription","Checklist","listItems","selectedListItems","handleSelectListItem","createLabel","_interopRequireDefault","obj","module","chainPropTypes","propType1","propType2","args","_extends","target","isPlainObject","prototype","deepClone","output","deepmerge","r","z","reactIs_production_min","hasSymbol","REACT_ELEMENT_TYPE","REACT_PORTAL_TYPE","REACT_FRAGMENT_TYPE","REACT_STRICT_MODE_TYPE","REACT_PROFILER_TYPE","REACT_PROVIDER_TYPE","REACT_CONTEXT_TYPE","REACT_ASYNC_MODE_TYPE","REACT_CONCURRENT_MODE_TYPE","REACT_FORWARD_REF_TYPE","REACT_SUSPENSE_TYPE","REACT_SUSPENSE_LIST_TYPE","REACT_MEMO_TYPE","REACT_LAZY_TYPE","REACT_BLOCK_TYPE","REACT_FUNDAMENTAL_TYPE","REACT_RESPONDER_TYPE","REACT_SCOPE_TYPE","isValidElementType","typeOf","object","$$typeof","$$typeofType","AsyncMode","ConcurrentMode","ContextConsumer","ContextProvider","Element","ForwardRef","Lazy","Memo","Portal","Profiler","StrictMode","Suspense","hasWarnedAboutDeprecatedIsAsyncMode","isAsyncMode","isConcurrentMode","isContextConsumer","isContextProvider","isElement","isForwardRef","isFragment","isLazy","isMemo","isPortal","isProfiler","isStrictMode","isSuspense","reactIs_development","reactIsModule","require$$0","require$$1","getOwnPropertySymbols","hasOwnProperty","propIsEnumerable","toObject","val","shouldUseNative","test1","test2","order2","test3","letter","objectAssign","from","to","symbols","ReactPropTypesSecret","ReactPropTypesSecret_1","has","printWarning","loggedTypeFailures","message","checkPropTypes","typeSpecs","values","location","componentName","getStack","typeSpecName","error","err","ex","stack","checkPropTypes_1","ReactIs","assign","require$$2","require$$3","require$$4","emptyFunctionThatReturnsNull","factoryWithTypeCheckers","isValidElement","throwOnDirectAccess","ITERATOR_SYMBOL","FAUX_ITERATOR_SYMBOL","getIteratorFn","maybeIterable","iteratorFn","ANONYMOUS","ReactPropTypes","createPrimitiveTypeChecker","createAnyTypeChecker","createArrayOfTypeChecker","createElementTypeChecker","createElementTypeTypeChecker","createInstanceTypeChecker","createNodeChecker","createObjectOfTypeChecker","createEnumTypeChecker","createUnionTypeChecker","createShapeTypeChecker","createStrictShapeTypeChecker","is","PropTypeError","createChainableTypeChecker","validate","manualPropTypeCallCache","manualPropTypeWarningCount","checkType","isRequired","propName","propFullName","secret","cacheKey","chainedCheckType","expectedType","propValue","propType","getPropType","preciseType","getPreciseType","typeChecker","expectedClass","expectedClassName","actualClassName","getClassName","expectedValues","valuesString","arrayOfTypeCheckers","checker","getPostfixForTypeWarning","expectedTypes","checkerResult","expectedTypesMessage","isNode","invalidValidatorError","shapeTypes","allKeys","iterator","step","entry","isSymbol","emptyFunction","emptyFunctionWithReset","factoryWithThrowingShims","shim","getShim","propTypesModule","isClassComponent","elementType","acceptingRef","safePropName","warningHint","elementAcceptingRef","PropTypes","elementAcceptingRef$1","specialProperty","exactProp","propTypes","unsupportedProps","prop","formatMuiErrorMessage","code","url","REACT_SERVER_CONTEXT_TYPE","REACT_OFFSCREEN_TYPE","enableScopeAPI","enableCacheElement","enableTransitionTracing","enableLegacyHidden","enableDebugTracing","REACT_MODULE_REFERENCE","SuspenseList","hasWarnedAboutDeprecatedIsConcurrentMode","isSuspenseList","fnNameMatchRegex","getFunctionName","fn","getFunctionComponentName","Component","fallback","getWrappedName","outerType","innerType","wrapperName","functionName","getDisplayName","HTMLElementType","refType","refType$1","capitalize","string","_formatMuiErrorMessage","createChainedFunction","funcs","acc","func","debounce","wait","timeout","debounced","later","deprecatedPropType","validator","reason","componentNameSafe","propFullNameSafe","isMuiElement","muiNames","_muiName","_element$type","ownerDocument","node","ownerWindow","requirePropFactory","componentNameInError","prevPropTypes","requiredProp","defaultTypeChecker","typeCheckerResult","setRef","useEnhancedEffect","useEnhancedEffect$1","globalId","useGlobalId","idOverride","defaultId","setDefaultId","maybeReactUseId","useId","reactId","unsupportedProp","useControlled","controlled","defaultProp","name","isControlled","valueState","setValue","defaultValue","setValueIfUncontrolled","newValue","useEventCallback","useForkRef","refs","instance","UNINITIALIZED","useLazyRef","init","initArg","EMPTY","useOnMount","Timeout","delay","useTimeout","hadKeyboardEvent","hadFocusVisibleRecently","hadFocusVisibleRecentlyTimeout","inputTypesWhitelist","focusTriggersKeyboardModality","tagName","handlePointerDown","handleVisibilityChange","prepare","doc","isFocusVisible","useIsFocusVisible","isFocusVisibleRef","handleBlurVisible","handleFocusVisible","resolveProps","defaultProps","defaultSlotProps","slotProps","slotPropName","composeClasses","slots","getUtilityClass","classes","slot","utilityClass","defaultGenerator","createClassNameGenerator","generate","generator","ClassNameGenerator","ClassNameGenerator$1","globalStateClasses","generateUtilityClass","globalStatePrefix","globalStateClass","generateUtilityClasses","result","clamp","min","max","_objectWithoutPropertiesLoose","excluded","sourceKeys","_excluded","sortBreakpointsValues","breakpointsAsArray","breakpoint1","breakpoint2","createBreakpoints","breakpoints","unit","other","sortedValues","up","down","between","start","end","endIndex","only","not","keyIndex","shape","shape$1","responsivePropType","responsivePropType$1","merge","defaultBreakpoints","handleBreakpoints","styleFromPropValue","theme","themeBreakpoints","breakpoint","mediaKey","cssKey","createEmptyBreakpointObject","breakpointsInput","_breakpointsInput$key","breakpointStyleKey","removeUnusedBreakpoints","breakpointKeys","breakpointOutput","getPath","path","checkVars","getStyleValue","themeMapping","transform","propValueFinal","userValue","cssProperty","themeKey","memoize","cache","arg","properties","directions","aliases","getCssProperties","property","marginKeys","paddingKeys","spacingKeys","createUnaryUnit","_getPath","themeSpacing","abs","createUnarySpacing","getValue","transformer","transformed","getStyleFromPropValue","cssProperties","resolveCssProperty","margin","padding","createSpacing","spacingInput","spacing","argsInput","argument","compose","styles","handlers","borderTransform","createBorderStyle","border","borderTop","borderRight","borderBottom","borderLeft","borderColor","borderTopColor","borderRightColor","borderBottomColor","borderLeftColor","outline","outlineColor","borderRadius","gap","columnGap","rowGap","gridColumn","gridRow","gridAutoFlow","gridAutoColumns","gridAutoRows","gridTemplateColumns","gridTemplateRows","gridTemplateAreas","gridArea","paletteTransform","color","bgcolor","backgroundColor","sizingTransform","maxWidth","_props$theme","_props$theme2","breakpointsValues","minWidth","height","maxHeight","minHeight","boxSizing","defaultSxConfig","defaultSxConfig$1","objectsHaveSameKeys","objects","union","callIfFn","maybeFn","unstable_createStyleFunctionSx","getThemeValue","config","styleFunctionSx","_theme$unstable_sxCon","sx","traverse","sxInput","sxObject","emptyBreakpoints","breakpointsKeys","css","styleKey","styleFunctionSx$1","applyStyles","createTheme","paletteInput","shapeInput","muiTheme","isObjectEmpty","useTheme","defaultTheme","contextTheme","ThemeContext","systemDefaultTheme","useThemeWithoutDefault","_excluded2","_excluded3","isEmpty","isStringTag","tag","shouldForwardProp","lowercaseFirstLetter","resolveTheme","themeId","defaultOverridesResolver","processStyleArg","callableStyle","_ref","ownerState","resolvedStylesArg","resolvedStyle","variants","isMatch","createStyled","input","rootShouldForwardProp","slotShouldForwardProp","systemSx","inputOptions","processStyles","componentSlot","inputSkipVariantsResolver","inputSkipSx","overridesResolver","skipVariantsResolver","skipSx","shouldForwardPropOption","defaultStyledResolver","styledEngineStyled","transformStyleArg","stylesArg","muiStyledResolver","styleArg","expressions","transformedStyleArg","expressionsWithDefaultTheme","styleOverrides","resolvedStyleOverrides","slotKey","slotStyle","_theme$components","themeVariants","numOfCustomFnsApplied","placeholders","displayName","getThemeProps","params","useThemeProps","clampWrapper","hexToRgb","re","colors","decomposeColor","marker","colorSpace","recomposeColor","hslToRgb","rgb","getLuminance","getContrastRatio","foreground","background","lumA","lumB","alpha","darken","coefficient","lighten","createMixins","mixins","common","common$1","grey","grey$1","purple","purple$1","red","red$1","orange","orange$1","blue","blue$1","lightBlue","lightBlue$1","green","green$1","light","dark","addLightOrDark","intent","shade","tonalOffset","tonalOffsetLight","tonalOffsetDark","getDefaultPrimary","mode","getDefaultSecondary","getDefaultError","getDefaultInfo","getDefaultSuccess","getDefaultWarning","createPalette","palette","contrastThreshold","success","warning","getContrastText","contrastText","contrast","augmentColor","mainShade","lightShade","darkShade","modes","round","caseAllCaps","defaultFontFamily","createTypography","typography","fontFamily","fontSize","fontWeightLight","fontWeightRegular","fontWeightMedium","fontWeightBold","htmlFontSize","allVariants","pxToRem2","coef","pxToRem","buildVariant","fontWeight","lineHeight","letterSpacing","casing","shadowKeyUmbraOpacity","shadowKeyPenumbraOpacity","shadowAmbientShadowOpacity","createShadow","px","shadows","shadows$1","easing","duration","formatMs","milliseconds","getAutoHeightDuration","constant","createTransitions","inputTransitions","mergedEasing","mergedDuration","durationOption","easingOption","isString","isNumber","animatedProp","zIndex","zIndex$1","mixinsInput","transitionsInput","typographyInput","systemTheme","systemCreateTheme","stateClasses","component","child","stateClass","defaultTheme$1","THEME_ID","systemUseThemeProps","styled","styled$1","getSvgIconUtilityClass","useUtilityClasses","SvgIconRoot","_theme$transitions","_theme$transitions$cr","_theme$transitions2","_theme$typography","_theme$typography$pxT","_theme$typography2","_theme$typography2$px","_theme$typography3","_theme$typography3$px","_palette$ownerState$c","_palette","_palette2","_palette3","SvgIcon","inProps","htmlColor","inheritViewBox","titleAccess","viewBox","hasSvgAsChild","more","_jsxs","_jsx","SvgIcon$1","createSvgIcon","unstable_ClassNameGenerator","exports","_utils","ArrowRight","default_1","_createSvgIcon","_jsxRuntime","isHostComponent","appendOwnerState","otherProps","defaultContextValue","ClassNameConfiguratorContext","useClassNamesOverride","disableDefaultClasses","extractEventHandlers","excludeKeys","resolveComponentProps","componentProps","slotState","omitEventHandlers","mergeSlotProps","parameters","getSlotProps","additionalProps","externalSlotProps","externalForwardedProps","joinedClasses","mergedStyle","eventHandlers","componentsPropsWithoutEventHandlers","otherPropsWithoutEventHandlers","internalSlotProps","useSlotProps","_parameters$additiona","skipResolvingSlotProps","rest","resolvedComponentsProps","mergedProps","internalRef","GLOBAL_CLASS_PREFIX","buildStateClass","buildSlotClass","getContainer","container","forwardedRef","disablePortal","mountNode","setMountNode","handleRef","newProps","ReactDOM","top","bottom","right","left","auto","basePlacements","clippingParents","viewport","popper","reference","variationPlacements","placement","placements","beforeRead","read","afterRead","beforeMain","main","afterMain","beforeWrite","write","afterWrite","modifierPhases","getNodeName","getWindow","OwnElement","isHTMLElement","isShadowRoot","attributes","effect","_ref2","initialStyles","styleProperties","attribute","applyStyles$1","getBasePlacement","getUAString","uaData","isLayoutViewport","getBoundingClientRect","includeScale","isFixedStrategy","clientRect","scaleX","scaleY","visualViewport","addVisualOffsets","getLayoutRect","contains","parent","rootNode","next","getComputedStyle","isTableElement","getDocumentElement","getParentNode","getTrueOffsetParent","getContainingBlock","isFirefox","isIE","elementCss","currentNode","getOffsetParent","window","offsetParent","getMainAxisFromPlacement","within","mathMax","mathMin","withinMaxClamp","getFreshSideObject","mergePaddingObject","paddingObject","expandToHashMap","hashMap","toPaddingObject","arrow","_state$modifiersData$","arrowElement","popperOffsets","basePlacement","axis","isVertical","len","arrowRect","minProp","maxProp","endDiff","startDiff","arrowOffsetParent","clientSize","centerToReference","center","offset","axisProp","_options$element","arrow$1","getVariation","unsetSides","roundOffsetsByDPR","win","dpr","mapToStyles","_Object$assign2","popperRect","variation","offsets","gpuAcceleration","adaptive","roundOffsets","isFixed","_offsets$x","_offsets$y","_ref3","hasX","hasY","sideX","sideY","heightProp","widthProp","offsetY","offsetX","commonStyles","_ref4","_Object$assign","computeStyles","_ref5","_options$gpuAccelerat","_options$adaptive","_options$roundOffsets","computeStyles$1","passive","_options$scroll","scroll","_options$resize","resize","scrollParents","scrollParent","eventListeners","hash","getOppositePlacement","matched","getOppositeVariationPlacement","getWindowScroll","scrollLeft","scrollTop","getWindowScrollBarX","getViewportRect","strategy","html","layoutViewport","getDocumentRect","_element$ownerDocumen","winScroll","body","isScrollParent","_getComputedStyle","overflow","overflowX","overflowY","getScrollParent","listScrollParents","list","isBody","updatedList","rectToClientRect","rect","getInnerBoundingClientRect","getClientRectFromMixedType","clippingParent","getClippingParents","canEscapeClipping","clipperElement","getClippingRect","boundary","rootBoundary","mainClippingParents","firstClippingParent","clippingRect","accRect","computeOffsets","commonX","commonY","mainAxis","detectOverflow","_options","_options$placement","_options$strategy","_options$boundary","_options$rootBoundary","_options$elementConte","elementContext","_options$altBoundary","altBoundary","_options$padding","altContext","clippingClientRect","referenceClientRect","popperClientRect","elementClientRect","overflowOffsets","offsetData","multiply","computeAutoPlacement","flipVariations","_options$allowedAutoP","allowedAutoPlacements","allPlacements","allowedPlacements","overflows","getExpandedFallbackPlacements","oppositePlacement","flip","_options$mainAxis","checkMainAxis","_options$altAxis","checkAltAxis","specifiedFallbackPlacements","_options$flipVariatio","preferredPlacement","isBasePlacement","fallbackPlacements","referenceRect","checksMap","makeFallbackChecks","firstFittingPlacement","_basePlacement","isStartVariation","mainVariationSide","altVariationSide","checks","check","numberOfChecks","_loop","_i","fittingPlacement","_ret","flip$1","getSideOffsets","preventedOffsets","isAnySideFullyClipped","hide","referenceOverflow","popperAltOverflow","referenceClippingOffsets","popperEscapeOffsets","isReferenceHidden","hasPopperEscaped","hide$1","distanceAndSkiddingToXY","rects","invertDistance","skidding","distance","_options$offset","_data$state$placement","offset$1","popperOffsets$1","getAltAxis","preventOverflow","_options$tether","tether","_options$tetherOffset","tetherOffset","altAxis","tetherOffsetValue","normalizedTetherOffsetValue","offsetModifierState","_offsetModifierState$","mainSide","altSide","additive","minLen","maxLen","arrowPaddingObject","arrowPaddingMin","arrowPaddingMax","arrowLen","minOffset","maxOffset","clientOffset","offsetModifierValue","tetherMin","tetherMax","preventedOffset","_offsetModifierState$2","_mainSide","_altSide","_offset","_len","_min","_max","isOriginSide","_offsetModifierValue","_tetherMin","_tetherMax","_preventedOffset","preventOverflow$1","getHTMLElementScroll","getNodeScroll","isElementScaled","getCompositeRect","elementOrVirtualElement","isOffsetParentAnElement","offsetParentIsScaled","documentElement","order","modifiers","map","visited","modifier","sort","requires","dep","depModifier","orderModifiers","orderedModifiers","phase","pending","resolve","mergeByName","merged","current","existing","DEFAULT_OPTIONS","areValidElements","_key","popperGenerator","generatorOptions","_generatorOptions","_generatorOptions$def","defaultModifiers","_generatorOptions$def2","defaultOptions","effectCleanupFns","isDestroyed","setOptionsAction","cleanupModifierEffects","runModifierEffects","_state$elements","_state$orderedModifie","_state$orderedModifie2","_ref$options","cleanupFn","noopFn","createPopper","COMPONENT_NAME","getPopperUtilityClass","flipPlacement","resolveAnchorEl","anchorEl","isVirtualElement","defaultPopperOptions","PopperTooltip","_slots$root","initialPlacement","popperOptions","popperRefProp","TransitionProps","tooltipRef","ownRef","popperRef","handlePopperRef","handlePopperRefRef","rtlPlacement","setPlacement","resolvedAnchorElement","setResolvedAnchorElement","handlePopperUpdate","box","popperModifiers","childProps","Root","rootProps","Popper","containerProp","keepMounted","transition","exited","setExited","handleEnter","handleExited","resolvedAnchorEl","display","transitionProps","useThemeSystem","_setPrototypeOf","_inheritsLoose","subClass","superClass","setPrototypeOf","timeoutsShape","TransitionGroupContext","forceReflow","UNMOUNTED","EXITED","ENTERING","ENTERED","EXITING","Transition","_React$Component","_this","parentGroup","appear","initialStatus","prevState","nextIn","_proto","prevProps","nextStatus","exit","enter","mounting","_this2","appearing","maybeNode","maybeAppearing","timeouts","enterTimeout","_this3","nextState","callback","_this4","active","handler","doesNotHaveTimeoutOrListener","maybeNextCallback","_this$props","pt","noop","Transition$1","reflow","getTransitionProps","_style$transitionDura","_style$transitionTimi","getScale","isWebKit154","Grow","addEndListener","inProp","onEnter","onEntered","onEntering","onExit","onExited","onExiting","TransitionComponent","timer","autoTimeout","nodeRef","normalizedTransitionCallback","maybeIsAppearing","handleEntering","isAppearing","transitionDuration","transitionTimingFunction","handleEntered","handleExiting","handleExit","handleAddEndListener","Grow$1","PopperRoot","BasePopper","components","componentsProps","RootComponent","Popper$1","getTooltipUtilityClass","tooltipClasses","tooltipClasses$1","disableInteractive","touch","TooltipPopper","TooltipTooltip","TooltipArrow","hystersisOpen","hystersisTimer","cursorPosition","composeEventHandler","eventHandler","_slots$popper","_slots$transition","_slots$tooltip","_slots$arrow","_slotProps$popper","_ref6","_slotProps$popper2","_slotProps$transition","_slotProps$tooltip","_ref7","_slotProps$tooltip2","_slotProps$arrow","_ref8","_slotProps$arrow2","childrenProp","describeChild","disableFocusListener","disableHoverListener","disableInteractiveProp","disableTouchListener","enterDelay","enterNextDelay","enterTouchDelay","followCursor","idProp","leaveDelay","leaveTouchDelay","onClose","onOpen","PopperComponentProp","PopperProps","title","TransitionComponentProp","isRtl","childNode","setChildNode","arrowRef","setArrowRef","ignoreNonTouchEvents","closeTimer","enterTimer","leaveTimer","touchTimer","setOpenState","prevUserSelect","stopTouchInteraction","handleOpen","handleClose","handleLeave","focusVisibleRef","setChildIsFocusVisible","handleBlur","handleFocus","detectTouchStart","childrenProps","handleMouseOver","handleMouseLeave","handleTouchStart","handleTouchEnd","nativeEvent","handleMouseMove","nameOrDescProps","titleIsString","interactiveWrapperListeners","_PopperProps$popperOp","tooltipModifiers","PopperComponent","TooltipComponent","ArrowComponent","popperProps","tooltipProps","tooltipArrowProps","TransitionPropsInner","Tooltip$1","getIcon","icon","menuLabel","leading","MuiListItemIcon","MenuItem","allowForLeadingIcons","iconPathBefore","iconPathAfter","hasAutoFocus","isDense","isSubMenuParent","hasDisabledGutters","hasDivider","focusVisibleClassName","menuItem","MuiMenuItem","MuiListItemText","getAllGroups","menuDefinition","SubMenu","setAnchorEl","parentMenuItem","parentItemProps","handleParentMenuItemClick","renderSubMenuItems","includedGroups","group","GroupedMenuItemList","Menu","getOrderedGroupItems","groupId","allItems","menuProps","commandHandler","groupsToInclude","sortedGroups","itemArray","allowSpaceForLeadingIcons","createMenuItemProps","isLastItemInGroup","divKey","itemInfo","menuItemProps","TopLevelMenu","columnId","MenuColumn","metadata","Grid","List","GridMenu","multiColumnMenu","sortedColumns","columnNumbers","columnName","col","getUsePromiseOptionsDefaults","usePromise","promiseFactoryCallback","defaultValueRef","optionsDefaultedRef","setIsLoading","promiseIsCurrent","MenuIcon","HamburgerMenuButton","menuProvider","normalMenu","fullMenu","containerRef","ariaLabelPrefix","isMenuOpen","setMenuOpen","showFullMenu","setShowFullMenu","handleMenuItemClick","handleMenuButtonClick","prevIsOpen","isOpening","menuCommandHandler","command","setOffset","normalMenuData","fullMenuData","menu","IconButton","Drawer","isTooltipSuppressed","adjustMarginToAlignToEdge","MuiIconButton","Spinner","LoaderCircle","TextField","hasError","helperText","onFocus","onBlur","ShadLabel","Toolbar","AppBar","MuiToolbar","alertVariants","Alert","AlertTitle","AlertDescription","Sonner","Toaster","Slider","SliderPrimitive","Switch","SwitchPrimitives","Tabs","TabsList","TabsTrigger","TabsContent","InstallButton","isInstalling","handleClick","buttonText","Download","EnableButton","isEnabling","DisableButton","isDisabling","UpdateButton","isUpdating","MarkdownRenderer","markdown","anchorTarget","Markdown","FilterButton","Filter","DropdownMenuItemType","DropdownMenuItemType2","FilterDropdown","groups","NoExtensionsFound","MoreInfo","category","downloads","languages","moreInfoUrl","numberFormatted","NumberFormat","handleScrollToBottom","User","locale","LucideLink","CircleHelp","VersionHistory","versionHistory","showAllVersions","setShowAllVersions","currentDate","formatTimeString","dateString","date","dateDiff","yearDiff","monthDiff","dayDiff","timeString","sortedEntries","Footer","publisherDisplayName","fileSize","locales","formattedFileSize","formatBytes","languageNames","codes","displayNames","useEvent","unsubscriber","noopUnsubscriber","useEventAsync","unsubscribe","unsub"],"mappings":"28CAGA,MAAMA,GAAgBC,GAAAA,oBAAoB,CAAE,OAAQ,KAAO,CAAA,EAyDpD,SAASC,KAAMC,EAAsB,CACnC,OAAAH,GAAcI,GAAAA,KAAKD,CAAM,CAAC,CACnC,CCzDO,MAAME,GAAQC,EAAM,WACzB,CAAC,CAAE,UAAAC,EAAW,KAAAC,EAAM,GAAGC,CAAA,EAASC,IAE5BC,EAAA,IAAC,QAAA,CACC,KAAAH,EACA,UAAWN,EACT,sbACAK,CACF,EACA,IAAAG,EAEC,GAAGD,CAAA,CAAA,CAIZ,EACAJ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EA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MAEA,MAEA,MAEA,MAEA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,MAEA,MAEA,MAEA,MAEA,MACA,MACA,MACA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,KACF,EAAGC,GAAI,CACL,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,KACF,EAAGC,GAAI,CACL,UACA,SACA,YACA,UACA,cACA,SACA,SACA,OACA,WACA,WACA,UACA,UACA,eACA,eACA,OACA,WACA,kBACA,MACA,SACA,WACA,eACA,gBACA,SACA,WACA,eACA,UACA,kBACA,QACA,OACA,OACA,UACA,QACA,QACA,QACA,WACA,YACA,SACA,YACA,UACA,UACA,OACA,OACA,OACA,OACA,SACA,gBACA,gBACA,YACA,YACA,cACA,aACA,kBACA,kBACA,YACA,YACA,QACA,WACA,UACA,QACA,UACA,UACA,SACA,SACA,SACA,OACA,aACA,QACA,SACA,eACA,oBACA,0BACA,SACA,qBACA,sBACA,UACA,qBACA,cACA,cACA,cACA,cACA,mBACA,mBACA,qBACA,YACA,OACA,oBAGA,uBACA,uBACA,sBACA,yBACA,wBACA,qBACA,UACA,UACA,UACA,UACA,UACA,UACA,UACA,eACA,cACA,eACA,oBACA,qBACA,0BACA,0BACA,eACA,eACA,YACA,gBACA,cACA,eACA,iBACA,wBACA,mBACA,WACA,QACA,aACA,aACA,aACA,2BACA,4BACA,YACF,EAAGC,GAAIC,KACP,SAASC,GAAER,EAAGJ,EAAI,GAAI,CACpB,OAAOA,IAAMI,EAAIA,EAAE,YAAa,GAAGA,KAAKM,GAAIA,GAAEN,CAAC,EAAI,CACrD,CACA,SAASS,GAAET,EAAG,CACZ,OAAOQ,GAAER,CAAC,EAAI,CAChB,CACA,SAASU,GAAEV,EAAG,CACZ,MAAMJ,EAAI,OAAOI,GAAK,SAAWQ,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EACD,WAAY,CACV,SAAU,UACV,UAAWA,EACZ,EACD,YAAa,CACX,SAAU,SACX,EACD,eAAgB,CACd,SAAU,SACX,EACD,iBAAkB,CAChB,SAAU,SACX,EACD,kBAAmB,CACjB,SAAU,SACX,EACD,gBAAiB,CACf,SAAU,SACX,EACD,QAAS,CACP,SAAU,UACV,UAAWA,EACZ,EACD,aAAc,CACZ,SAAU,SACX,EACD,aAAc,CACZ,SAAU,qBACV,MAAOc,EACR,EAED,MAAO,CACL,SAAU,UACV,UAAWa,EACZ,EACD,QAAS,CACP,SAAU,UACV,YAAa,kBACb,UAAWA,EACZ,EACD,gBAAiB,CACf,SAAU,UACV,UAAWA,EACZ,EAED,EAAG,CACD,MAAOpC,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,QAAS,CACP,MAAOA,EACR,EACD,WAAY,CACV,MAAOA,EACR,EACD,aAAc,CACZ,MAAOA,EACR,EACD,cAAe,CACb,MAAOA,EACR,EACD,YAAa,CACX,MAAOA,EACR,EACD,SAAU,CACR,MAAOA,EACR,EACD,SAAU,CACR,MAAOA,EACR,EACD,cAAe,CACb,MAAOA,EACR,EACD,mBAAoB,CAClB,MAAOA,EACR,EACD,iBAAkB,CAChB,MAAOA,EACR,EACD,aAAc,CACZ,MAAOA,EACR,EACD,kBAAmB,CACjB,MAAOA,EACR,EACD,gBAAiB,CACf,MAAOA,EACR,EACD,EAAG,CACD,MAAOD,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,OAAQ,CACN,MAAOA,EACR,EACD,UAAW,CACT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;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","x_google_ignoreList":[3,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,83,84,85,86,87,88,89,90,91,92,93,94,95,96,97,98,99,100,101,102,103,104,105,106,107,108,109,110,111,112,113,114,115,116,117,118,119,120,121,122,123,124,125,126,127,128,129,130,131,132,133,134,135,136,137,138,139,140,141,142,143,144,145,146,147,148,149,150,151,152,153,154,155,156,157,158,159,160,161,162,163,164,165,166,167,168,169,170,171,172,173,174,175,176,177,178,179,180,181,182,183,184,185,186,187,188,189,190,191,192,193,194,195,196,197,198,199,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,230]} \ No newline at end of file +{"version":3,"file":"index.cjs","sources":["../src/utils/shadcn-ui.util.ts","../src/components/shadcn-ui/input.tsx","../src/components/advanced/book-chapter-control/book-chapter-input.component.tsx","../../../node_modules/@sillsdev/scripture/dist/index.es.js","../src/components/shadcn-ui/dropdown-menu.tsx","../src/components/advanced/book-chapter-control/book-menu-item.component.tsx","../src/components/advanced/book-chapter-control/chapter-select.component.tsx","../src/components/advanced/book-chapter-control/go-to-menu-item.component.tsx","../src/components/advanced/book-chapter-control/book-chapter-control.component.tsx","../src/components/shadcn-ui/button.tsx","../src/components/shadcn-ui/label.tsx","../src/components/shadcn-ui/radio-group.tsx","../src/components/shadcn-ui/popover.tsx","../src/components/shadcn-ui/dialog.tsx","../src/components/shadcn-ui/command.tsx","../src/components/basics/combo-box.component.tsx","../src/components/basics/chapter-range-selector.component.tsx","../src/components/advanced/book-selector.component.tsx","../src/components/advanced/data-table/data-table-column-toggle.component.tsx","../src/components/shadcn-ui/select.tsx","../src/components/advanced/data-table/data-table-pagination.component.tsx","../src/components/shadcn-ui/table.tsx","../src/components/advanced/data-table/data-table.component.tsx","../src/components/advanced/inventory/occurrences-table.component.tsx","../src/components/shadcn-ui/checkbox.tsx","../src/components/advanced/inventory/inventory-utils.ts","../src/components/shadcn-ui/toggle.tsx","../src/components/shadcn-ui/toggle-group.tsx","../src/components/advanced/inventory/inventory-columns.tsx","../src/components/advanced/inventory/inventory.component.tsx","../src/components/basics/search-bar.component.tsx","../src/components/basics/tabs-vertical.tsx","../src/components/advanced/tab-navigation-content-search.component.tsx","../src/components/shadcn-ui/separator.tsx","../src/components/shadcn-ui/sheet.tsx","../src/components/shadcn-ui/skeleton.tsx","../src/components/shadcn-ui/tooltip.tsx","../src/components/hooks/use-mobile.tsx","../src/components/shadcn-ui/sidebar.tsx","../src/components/advanced/settings-components/settings-sidebar.component.tsx","../src/components/advanced/settings-components/settings-sidebar-content-search.component.tsx","../src/components/advanced/scripture-results-viewer/scripture-results-viewer.component.tsx","../src/components/advanced/scroll-group-selector.component.tsx","../src/components/advanced/settings-components/settings-list.component.tsx","../src/components/shadcn-ui/card.tsx","../src/components/advanced/settings-components/settings-card.component.tsx","../src/components/basics/checklist.component.tsx","../../../node_modules/@babel/runtime/helpers/interopRequireDefault.js","../../../node_modules/@mui/utils/chainPropTypes/chainPropTypes.js","../../../node_modules/@babel/runtime/helpers/esm/extends.js","../../../node_modules/@mui/utils/deepmerge/deepmerge.js","../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.production.min.js","../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.development.js","../../../node_modules/prop-types/node_modules/react-is/index.js","../../../node_modules/object-assign/index.js","../../../node_modules/prop-types/lib/ReactPropTypesSecret.js","../../../node_modules/prop-types/lib/has.js","../../../node_modules/prop-types/checkPropTypes.js","../../../node_modules/prop-types/factoryWithTypeCheckers.js","../../../node_modules/prop-types/factoryWithThrowingShims.js","../../../node_modules/prop-types/index.js","../../../node_modules/@mui/utils/elementAcceptingRef/elementAcceptingRef.js","../../../node_modules/@mui/utils/exactProp/exactProp.js","../../../node_modules/@mui/utils/formatMuiErrorMessage/formatMuiErrorMessage.js","../../../node_modules/react-is/cjs/react-is.production.min.js","../../../node_modules/react-is/cjs/react-is.development.js","../../../node_modules/react-is/index.js","../../../node_modules/@mui/utils/getDisplayName/getDisplayName.js","../../../node_modules/@mui/utils/HTMLElementType/HTMLElementType.js","../../../node_modules/@mui/utils/refType/refType.js","../../../node_modules/@mui/utils/capitalize/capitalize.js","../../../node_modules/@mui/utils/createChainedFunction/createChainedFunction.js","../../../node_modules/@mui/utils/debounce/debounce.js","../../../node_modules/@mui/utils/deprecatedPropType/deprecatedPropType.js","../../../node_modules/@mui/utils/isMuiElement/isMuiElement.js","../../../node_modules/@mui/utils/ownerDocument/ownerDocument.js","../../../node_modules/@mui/utils/ownerWindow/ownerWindow.js","../../../node_modules/@mui/utils/requirePropFactory/requirePropFactory.js","../../../node_modules/@mui/utils/setRef/setRef.js","../../../node_modules/@mui/utils/useEnhancedEffect/useEnhancedEffect.js","../../../node_modules/@mui/utils/useId/useId.js","../../../node_modules/@mui/utils/unsupportedProp/unsupportedProp.js","../../../node_modules/@mui/utils/useControlled/useControlled.js","../../../node_modules/@mui/utils/useEventCallback/useEventCallback.js","../../../node_modules/@mui/utils/useForkRef/useForkRef.js","../../../node_modules/@mui/utils/useLazyRef/useLazyRef.js","../../../node_modules/@mui/utils/useOnMount/useOnMount.js","../../../node_modules/@mui/utils/useTimeout/useTimeout.js","../../../node_modules/@mui/utils/useIsFocusVisible/useIsFocusVisible.js","../../../node_modules/@mui/utils/resolveProps/resolveProps.js","../../../node_modules/@mui/utils/composeClasses/composeClasses.js","../../../node_modules/@mui/utils/ClassNameGenerator/ClassNameGenerator.js","../../../node_modules/@mui/utils/generateUtilityClass/generateUtilityClass.js","../../../node_modules/@mui/utils/generateUtilityClasses/generateUtilityClasses.js","../../../node_modules/@mui/utils/clamp/clamp.js","../../../node_modules/@babel/runtime/helpers/esm/objectWithoutPropertiesLoose.js","../../../node_modules/@mui/system/esm/createTheme/createBreakpoints.js","../../../node_modules/@mui/system/esm/createTheme/shape.js","../../../node_modules/@mui/system/esm/responsivePropType.js","../../../node_modules/@mui/system/esm/merge.js","../../../node_modules/@mui/system/esm/breakpoints.js","../../../node_modules/@mui/system/esm/style.js","../../../node_modules/@mui/system/esm/memoize.js","../../../node_modules/@mui/system/esm/spacing.js","../../../node_modules/@mui/system/esm/createTheme/createSpacing.js","../../../node_modules/@mui/system/esm/compose.js","../../../node_modules/@mui/system/esm/borders.js","../../../node_modules/@mui/system/esm/cssGrid.js","../../../node_modules/@mui/system/esm/palette.js","../../../node_modules/@mui/system/esm/sizing.js","../../../node_modules/@mui/system/esm/styleFunctionSx/defaultSxConfig.js","../../../node_modules/@mui/system/esm/styleFunctionSx/styleFunctionSx.js","../../../node_modules/@mui/system/esm/createTheme/applyStyles.js","../../../node_modules/@mui/system/esm/createTheme/createTheme.js","../../../node_modules/@mui/system/esm/useThemeWithoutDefault.js","../../../node_modules/@mui/system/esm/useTheme.js","../../../node_modules/@mui/system/esm/createStyled.js","../../../node_modules/@mui/system/esm/useThemeProps/getThemeProps.js","../../../node_modules/@mui/system/esm/useThemeProps/useThemeProps.js","../../../node_modules/@mui/system/esm/colorManipulator.js","../../../node_modules/@mui/material/styles/createMixins.js","../../../node_modules/@mui/material/colors/common.js","../../../node_modules/@mui/material/colors/grey.js","../../../node_modules/@mui/material/colors/purple.js","../../../node_modules/@mui/material/colors/red.js","../../../node_modules/@mui/material/colors/orange.js","../../../node_modules/@mui/material/colors/blue.js","../../../node_modules/@mui/material/colors/lightBlue.js","../../../node_modules/@mui/material/colors/green.js","../../../node_modules/@mui/material/styles/createPalette.js","../../../node_modules/@mui/material/styles/createTypography.js","../../../node_modules/@mui/material/styles/shadows.js","../../../node_modules/@mui/material/styles/createTransitions.js","../../../node_modules/@mui/material/styles/zIndex.js","../../../node_modules/@mui/material/styles/createTheme.js","../../../node_modules/@mui/material/styles/defaultTheme.js","../../../node_modules/@mui/material/styles/identifier.js","../../../node_modules/@mui/material/styles/useThemeProps.js","../../../node_modules/@mui/material/styles/styled.js","../../../node_modules/@mui/material/SvgIcon/svgIconClasses.js","../../../node_modules/@mui/material/SvgIcon/SvgIcon.js","../../../node_modules/@mui/material/utils/createSvgIcon.js","../../../node_modules/@mui/material/utils/index.js","../../../node_modules/@mui/icons-material/utils/createSvgIcon.js","../../../node_modules/@mui/icons-material/ArrowRight.js","../../../node_modules/@mui/base/utils/isHostComponent.js","../../../node_modules/@mui/base/utils/appendOwnerState.js","../../../node_modules/@mui/base/utils/ClassNameConfigurator.js","../../../node_modules/@mui/base/utils/extractEventHandlers.js","../../../node_modules/@mui/base/utils/resolveComponentProps.js","../../../node_modules/@mui/base/utils/omitEventHandlers.js","../../../node_modules/@mui/base/utils/mergeSlotProps.js","../../../node_modules/@mui/base/utils/useSlotProps.js","../../../node_modules/@mui/base/generateUtilityClass/index.js","../../../node_modules/@mui/base/generateUtilityClasses/index.js","../../../node_modules/@mui/base/Portal/Portal.js","../../../node_modules/@popperjs/core/lib/enums.js","../../../node_modules/@popperjs/core/lib/dom-utils/getNodeName.js","../../../node_modules/@popperjs/core/lib/dom-utils/getWindow.js","../../../node_modules/@popperjs/core/lib/dom-utils/instanceOf.js","../../../node_modules/@popperjs/core/lib/modifiers/applyStyles.js","../../../node_modules/@popperjs/core/lib/utils/getBasePlacement.js","../../../node_modules/@popperjs/core/lib/utils/math.js","../../../node_modules/@popperjs/core/lib/utils/userAgent.js","../../../node_modules/@popperjs/core/lib/dom-utils/isLayoutViewport.js","../../../node_modules/@popperjs/core/lib/dom-utils/getBoundingClientRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/getLayoutRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/contains.js","../../../node_modules/@popperjs/core/lib/dom-utils/getComputedStyle.js","../../../node_modules/@popperjs/core/lib/dom-utils/isTableElement.js","../../../node_modules/@popperjs/core/lib/dom-utils/getDocumentElement.js","../../../node_modules/@popperjs/core/lib/dom-utils/getParentNode.js","../../../node_modules/@popperjs/core/lib/dom-utils/getOffsetParent.js","../../../node_modules/@popperjs/core/lib/utils/getMainAxisFromPlacement.js","../../../node_modules/@popperjs/core/lib/utils/within.js","../../../node_modules/@popperjs/core/lib/utils/getFreshSideObject.js","../../../node_modules/@popperjs/core/lib/utils/mergePaddingObject.js","../../../node_modules/@popperjs/core/lib/utils/expandToHashMap.js","../../../node_modules/@popperjs/core/lib/modifiers/arrow.js","../../../node_modules/@popperjs/core/lib/utils/getVariation.js","../../../node_modules/@popperjs/core/lib/modifiers/computeStyles.js","../../../node_modules/@popperjs/core/lib/modifiers/eventListeners.js","../../../node_modules/@popperjs/core/lib/utils/getOppositePlacement.js","../../../node_modules/@popperjs/core/lib/utils/getOppositeVariationPlacement.js","../../../node_modules/@popperjs/core/lib/dom-utils/getWindowScroll.js","../../../node_modules/@popperjs/core/lib/dom-utils/getWindowScrollBarX.js","../../../node_modules/@popperjs/core/lib/dom-utils/getViewportRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/getDocumentRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/isScrollParent.js","../../../node_modules/@popperjs/core/lib/dom-utils/getScrollParent.js","../../../node_modules/@popperjs/core/lib/dom-utils/listScrollParents.js","../../../node_modules/@popperjs/core/lib/utils/rectToClientRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/getClippingRect.js","../../../node_modules/@popperjs/core/lib/utils/computeOffsets.js","../../../node_modules/@popperjs/core/lib/utils/detectOverflow.js","../../../node_modules/@popperjs/core/lib/utils/computeAutoPlacement.js","../../../node_modules/@popperjs/core/lib/modifiers/flip.js","../../../node_modules/@popperjs/core/lib/modifiers/hide.js","../../../node_modules/@popperjs/core/lib/modifiers/offset.js","../../../node_modules/@popperjs/core/lib/modifiers/popperOffsets.js","../../../node_modules/@popperjs/core/lib/utils/getAltAxis.js","../../../node_modules/@popperjs/core/lib/modifiers/preventOverflow.js","../../../node_modules/@popperjs/core/lib/dom-utils/getHTMLElementScroll.js","../../../node_modules/@popperjs/core/lib/dom-utils/getNodeScroll.js","../../../node_modules/@popperjs/core/lib/dom-utils/getCompositeRect.js","../../../node_modules/@popperjs/core/lib/utils/orderModifiers.js","../../../node_modules/@popperjs/core/lib/utils/debounce.js","../../../node_modules/@popperjs/core/lib/utils/mergeByName.js","../../../node_modules/@popperjs/core/lib/createPopper.js","../../../node_modules/@popperjs/core/lib/popper.js","../../../node_modules/@mui/base/Popper/popperClasses.js","../../../node_modules/@mui/base/Popper/Popper.js","../../../node_modules/@mui/material/styles/useTheme.js","../../../node_modules/@babel/runtime/helpers/esm/setPrototypeOf.js","../../../node_modules/@babel/runtime/helpers/esm/inheritsLoose.js","../../../node_modules/react-transition-group/esm/config.js","../../../node_modules/react-transition-group/esm/utils/PropTypes.js","../../../node_modules/react-transition-group/esm/TransitionGroupContext.js","../../../node_modules/react-transition-group/esm/utils/reflow.js","../../../node_modules/react-transition-group/esm/Transition.js","../../../node_modules/@mui/material/transitions/utils.js","../../../node_modules/@mui/material/Grow/Grow.js","../../../node_modules/@mui/material/Popper/Popper.js","../../../node_modules/@mui/material/Tooltip/tooltipClasses.js","../../../node_modules/@mui/material/Tooltip/Tooltip.js","../src/components/mui/menu-item.component.tsx","../src/components/mui/grouped-menu-item-list.component.tsx","../src/components/mui/top-level-menu.component.tsx","../src/components/mui/grid-menu.component.tsx","../src/hooks/use-promise.hook.ts","../../../node_modules/@mui/icons-material/esm/Menu.js","../src/components/mui/hamburger-menu-button.component.tsx","../src/components/mui/icon-button.component.tsx","../src/components/basics/spinner.component.tsx","../src/components/basics/text-field.component.tsx","../src/components/mui/toolbar.component.tsx","../src/components/shadcn-ui/alert.tsx","../src/components/shadcn-ui/sonner.tsx","../src/components/shadcn-ui/slider.tsx","../src/components/shadcn-ui/switch.tsx","../src/components/shadcn-ui/tabs.tsx","../src/components/advanced/extension-marketplace/buttons/install-button.component.tsx","../src/components/advanced/extension-marketplace/buttons/enable-button.component.tsx","../src/components/advanced/extension-marketplace/buttons/disable-button.component.tsx","../src/components/advanced/extension-marketplace/buttons/update-button.component.tsx","../src/components/advanced/extension-marketplace/markdown-renderer.component.tsx","../src/components/advanced/extension-marketplace/buttons/filter-button.component.tsx","../src/components/advanced/extension-marketplace/filter-dropdown.component.tsx","../src/components/advanced/extension-marketplace/no-extensions-found.component.tsx","../src/components/advanced/extension-marketplace/more-info.component.tsx","../src/components/advanced/extension-marketplace/version-history.component.tsx","../src/components/advanced/extension-marketplace/footer.component.tsx","../src/hooks/use-event.hook.ts","../src/hooks/use-event-async.hook.ts"],"sourcesContent":["import { type ClassValue, clsx } from 'clsx';\nimport { extendTailwindMerge } from 'tailwind-merge';\n\nconst twMergeCustom = extendTailwindMerge({ prefix: 'tw-' });\n\n/**\n * Tailwind and CSS class application helper function. Uses\n * [`clsx`](https://www.npmjs.com/package/clsx) to make it easy to apply classes conditionally using\n * object syntax, and uses [`tailwind-merge`](https://www.npmjs.com/package/tailwind-merge) to make\n * it easy to merge/overwrite Tailwind classes in a programmer-logic-friendly way.\n *\n * Note: `tailwind-merge` is configured to use the prefix `tw-`, so you must use the same prefix\n * with any Tailwind classes you use with this function to successfully overwrite other Tailwind\n * classes. `platform-bible-react` is configured to use `tw-` as its Tailwind prefix, so any\n * Tailwind classes you pass into `platform-bible-react` components will be compared using the `tw-`\n * prefix.\n *\n * This function was popularized by\n * [shadcn/ui](https://ui.shadcn.com/docs/installation/manual#add-a-cn-helper). See [ByteGrad's\n * explanation video](https://www.youtube.com/watch?v=re2JFITR7TI) for more information.\n *\n * @example\n *\n * ```typescript\n * const borderShouldBeBlue = true;\n * const textShouldBeRed = true;\n * const heightShouldBe20 = false;\n * const classString = cn(\n * 'tw-bg-primary tw-h-10 tw-text-primary-foreground',\n * 'tw-bg-secondary',\n * {\n * 'tw-border-blue-500': borderShouldBeBlue,\n * 'tw-text-red-500': textShouldBeRed,\n * 'tw-h-20': heightShouldBe20,\n * },\n * 'some-class',\n * );\n * ```\n *\n * The resulting `classString` is `'tw-h-10 tw-bg-secondary tw-border-blue-500 tw-text-red-500\n * some-class'`\n *\n * - Notice that `'tw-bg-secondary'`, specified later, overwrote `'tw-bg-primary'`, specified earlier,\n * because they are Tailwind classes that affect the same css property\n * - Notice that `'tw-text-red-500'`, specified later, overwrote `'tw-text-primary-foreground'`,\n * specified earlier, because they are Tailwind classes that affect the same css property\n * - Notice that `'tw-h-20'`, specified later, did not overwrite `'tw-h-10'`, specified earlier,\n * because `'tw-h-20'` is part of a conditional class object and its value evaluated to `false`;\n * therefore it was not applied\n * - Notice that `'some-class'` was applied. This function is not limited only to Tailwind classes.\n *\n *\n * @param inputs Class strings or `clsx` conditional class objects to merge. Tailwind classes\n * specified later in the arguments overwrite similar Tailwind classes specified earlier in the\n * arguments\n * @returns Class string containing all applicable classes from the arguments based on the rules\n * described above\n */\n// shadcn/ui uses this export in its boilerplate code\n// eslint-disable-next-line import/prefer-default-export\nexport function cn(...inputs: ClassValue[]) {\n return twMergeCustom(clsx(inputs));\n}\n","import React from 'react';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport interface InputProps extends React.InputHTMLAttributes {}\n\nexport const Input = React.forwardRef(\n ({ className, type, ...props }, ref) => {\n return (\n \n );\n },\n);\nInput.displayName = 'Input';\n","import { FocusEventHandler, forwardRef, KeyboardEvent, MouseEventHandler } from 'react';\nimport { History } from 'lucide-react';\nimport { Input as ShadInput } from '@/components/shadcn-ui/input';\n\nexport type BookChapterInputProps = {\n handleSearch: (searchString: string) => void;\n handleKeyDown: (event: KeyboardEvent) => void;\n handleOnClick: MouseEventHandler;\n handleSubmit: () => void;\n onFocus?: FocusEventHandler;\n value: string;\n placeholder: string;\n};\n\n// Shadcn Input sets type to \"button\"- HAVE to prop spread before setting type\nconst BookChapterInput = forwardRef(\n (\n { handleSearch, handleKeyDown, handleOnClick, handleSubmit, ...props }: BookChapterInputProps,\n ref,\n ) => {\n return (\n
    \n handleSearch(event.target.value)}\n onKeyDown={(e) => {\n if (e.key === 'Enter') {\n handleSubmit();\n }\n handleKeyDown(e);\n }}\n onClick={handleOnClick}\n ref={ref}\n />\n {\n // eslint-disable-next-line no-console\n console.log('back in history');\n }}\n />\n
    \n );\n },\n);\n\nexport default BookChapterInput;\n","var P = Object.defineProperty;\nvar R = (t, e, s) => e in t ? P(t, e, { enumerable: !0, configurable: !0, writable: !0, value: s }) : t[e] = s;\nvar n = (t, e, s) => R(t, typeof e != \"symbol\" ? e + \"\" : e, s);\nclass _ {\n constructor() {\n n(this, \"books\");\n n(this, \"firstSelectedBookNum\");\n n(this, \"lastSelectedBookNum\");\n n(this, \"count\");\n n(this, \"selectedBookNumbers\");\n n(this, \"selectedBookIds\");\n }\n}\nconst N = [\n \"GEN\",\n \"EXO\",\n \"LEV\",\n \"NUM\",\n \"DEU\",\n \"JOS\",\n \"JDG\",\n \"RUT\",\n \"1SA\",\n \"2SA\",\n // 10\n \"1KI\",\n \"2KI\",\n \"1CH\",\n \"2CH\",\n \"EZR\",\n \"NEH\",\n \"EST\",\n \"JOB\",\n \"PSA\",\n \"PRO\",\n // 20\n \"ECC\",\n \"SNG\",\n \"ISA\",\n \"JER\",\n \"LAM\",\n \"EZK\",\n \"DAN\",\n \"HOS\",\n \"JOL\",\n \"AMO\",\n // 30\n \"OBA\",\n \"JON\",\n \"MIC\",\n \"NAM\",\n \"HAB\",\n \"ZEP\",\n \"HAG\",\n \"ZEC\",\n \"MAL\",\n \"MAT\",\n // 40\n \"MRK\",\n \"LUK\",\n \"JHN\",\n \"ACT\",\n \"ROM\",\n \"1CO\",\n \"2CO\",\n \"GAL\",\n \"EPH\",\n \"PHP\",\n // 50\n \"COL\",\n \"1TH\",\n \"2TH\",\n \"1TI\",\n \"2TI\",\n \"TIT\",\n \"PHM\",\n \"HEB\",\n \"JAS\",\n \"1PE\",\n // 60\n \"2PE\",\n \"1JN\",\n \"2JN\",\n \"3JN\",\n \"JUD\",\n \"REV\",\n \"TOB\",\n \"JDT\",\n \"ESG\",\n \"WIS\",\n // 70\n \"SIR\",\n \"BAR\",\n \"LJE\",\n \"S3Y\",\n \"SUS\",\n \"BEL\",\n \"1MA\",\n \"2MA\",\n \"3MA\",\n \"4MA\",\n // 80\n \"1ES\",\n \"2ES\",\n \"MAN\",\n \"PS2\",\n \"ODA\",\n \"PSS\",\n \"JSA\",\n // actual variant text for JOS, now in LXA text\n \"JDB\",\n // actual variant text for JDG, now in LXA text\n \"TBS\",\n // actual variant text for TOB, now in LXA text\n \"SST\",\n // actual variant text for SUS, now in LXA text // 90\n \"DNT\",\n // actual variant text for DAN, now in LXA text\n \"BLT\",\n // actual variant text for BEL, now in LXA text\n \"XXA\",\n \"XXB\",\n \"XXC\",\n \"XXD\",\n \"XXE\",\n \"XXF\",\n \"XXG\",\n \"FRT\",\n // 100\n \"BAK\",\n \"OTH\",\n \"3ES\",\n // Used previously but really should be 2ES\n \"EZA\",\n // Used to be called 4ES, but not actually in any known project\n \"5EZ\",\n // Used to be called 5ES, but not actually in any known project\n \"6EZ\",\n // Used to be called 6ES, but not actually in any known project\n \"INT\",\n \"CNC\",\n \"GLO\",\n \"TDX\",\n // 110\n \"NDX\",\n \"DAG\",\n \"PS3\",\n \"2BA\",\n \"LBA\",\n \"JUB\",\n \"ENO\",\n \"1MQ\",\n \"2MQ\",\n \"3MQ\",\n // 120\n \"REP\",\n \"4BA\",\n \"LAO\"\n], B = [\n \"XXA\",\n \"XXB\",\n \"XXC\",\n \"XXD\",\n \"XXE\",\n \"XXF\",\n \"XXG\",\n \"FRT\",\n \"BAK\",\n \"OTH\",\n \"INT\",\n \"CNC\",\n \"GLO\",\n \"TDX\",\n \"NDX\"\n], O = [\n \"Genesis\",\n \"Exodus\",\n \"Leviticus\",\n \"Numbers\",\n \"Deuteronomy\",\n \"Joshua\",\n \"Judges\",\n \"Ruth\",\n \"1 Samuel\",\n \"2 Samuel\",\n \"1 Kings\",\n \"2 Kings\",\n \"1 Chronicles\",\n \"2 Chronicles\",\n \"Ezra\",\n \"Nehemiah\",\n \"Esther (Hebrew)\",\n \"Job\",\n \"Psalms\",\n \"Proverbs\",\n \"Ecclesiastes\",\n \"Song of Songs\",\n \"Isaiah\",\n \"Jeremiah\",\n \"Lamentations\",\n \"Ezekiel\",\n \"Daniel (Hebrew)\",\n \"Hosea\",\n \"Joel\",\n \"Amos\",\n \"Obadiah\",\n \"Jonah\",\n \"Micah\",\n \"Nahum\",\n \"Habakkuk\",\n \"Zephaniah\",\n \"Haggai\",\n \"Zechariah\",\n \"Malachi\",\n \"Matthew\",\n \"Mark\",\n \"Luke\",\n \"John\",\n \"Acts\",\n \"Romans\",\n \"1 Corinthians\",\n \"2 Corinthians\",\n \"Galatians\",\n \"Ephesians\",\n \"Philippians\",\n \"Colossians\",\n \"1 Thessalonians\",\n \"2 Thessalonians\",\n \"1 Timothy\",\n \"2 Timothy\",\n \"Titus\",\n \"Philemon\",\n \"Hebrews\",\n \"James\",\n \"1 Peter\",\n \"2 Peter\",\n \"1 John\",\n \"2 John\",\n \"3 John\",\n \"Jude\",\n \"Revelation\",\n \"Tobit\",\n \"Judith\",\n \"Esther Greek\",\n \"Wisdom of Solomon\",\n \"Sirach (Ecclesiasticus)\",\n \"Baruch\",\n \"Letter of Jeremiah\",\n \"Song of 3 Young Men\",\n \"Susanna\",\n \"Bel and the Dragon\",\n \"1 Maccabees\",\n \"2 Maccabees\",\n \"3 Maccabees\",\n \"4 Maccabees\",\n \"1 Esdras (Greek)\",\n \"2 Esdras (Latin)\",\n \"Prayer of Manasseh\",\n \"Psalm 151\",\n \"Odes\",\n \"Psalms of Solomon\",\n // WARNING, if you change the spelling of the *obsolete* tag be sure to update\n // IsObsolete routine\n \"Joshua A. *obsolete*\",\n \"Judges B. *obsolete*\",\n \"Tobit S. *obsolete*\",\n \"Susanna Th. *obsolete*\",\n \"Daniel Th. *obsolete*\",\n \"Bel Th. *obsolete*\",\n \"Extra A\",\n \"Extra B\",\n \"Extra C\",\n \"Extra D\",\n \"Extra E\",\n \"Extra F\",\n \"Extra G\",\n \"Front Matter\",\n \"Back Matter\",\n \"Other Matter\",\n \"3 Ezra *obsolete*\",\n \"Apocalypse of Ezra\",\n \"5 Ezra (Latin Prologue)\",\n \"6 Ezra (Latin Epilogue)\",\n \"Introduction\",\n \"Concordance \",\n \"Glossary \",\n \"Topical Index\",\n \"Names Index\",\n \"Daniel Greek\",\n \"Psalms 152-155\",\n \"2 Baruch (Apocalypse)\",\n \"Letter of Baruch\",\n \"Jubilees\",\n \"Enoch\",\n \"1 Meqabyan\",\n \"2 Meqabyan\",\n \"3 Meqabyan\",\n \"Reproof (Proverbs 25-31)\",\n \"4 Baruch (Rest of Baruch)\",\n \"Laodiceans\"\n], S = K();\nfunction g(t, e = !0) {\n return e && (t = t.toUpperCase()), t in S ? S[t] : 0;\n}\nfunction k(t) {\n return g(t) > 0;\n}\nfunction x(t) {\n const e = typeof t == \"string\" ? g(t) : t;\n return e >= 40 && e <= 66;\n}\nfunction T(t) {\n return (typeof t == \"string\" ? g(t) : t) <= 39;\n}\nfunction X(t) {\n return t <= 66;\n}\nfunction V(t) {\n const e = typeof t == \"string\" ? g(t) : t;\n return w(e) && !X(e);\n}\nfunction* L() {\n for (let t = 1; t <= N.length; t++) yield t;\n}\nconst G = 1, A = N.length;\nfunction H() {\n return [\"XXA\", \"XXB\", \"XXC\", \"XXD\", \"XXE\", \"XXF\", \"XXG\"];\n}\nfunction C(t, e = \"***\") {\n const s = t - 1;\n return s < 0 || s >= N.length ? e : N[s];\n}\nfunction I(t) {\n return t <= 0 || t > A ? \"******\" : O[t - 1];\n}\nfunction y(t) {\n return I(g(t));\n}\nfunction w(t) {\n const e = typeof t == \"number\" ? C(t) : t;\n return k(e) && !B.includes(e);\n}\nfunction q(t) {\n const e = typeof t == \"number\" ? C(t) : t;\n return k(e) && B.includes(e);\n}\nfunction U(t) {\n return O[t - 1].includes(\"*obsolete*\");\n}\nfunction K() {\n const t = {};\n for (let e = 0; e < N.length; e++)\n t[N[e]] = e + 1;\n return t;\n}\nconst m = {\n allBookIds: N,\n nonCanonicalIds: B,\n bookIdToNumber: g,\n isBookIdValid: k,\n isBookNT: x,\n isBookOT: T,\n isBookOTNT: X,\n isBookDC: V,\n allBookNumbers: L,\n firstBook: G,\n lastBook: A,\n extraBooks: H,\n bookNumberToId: C,\n bookNumberToEnglishName: I,\n bookIdToEnglishName: y,\n isCanonical: w,\n isExtraMaterial: q,\n isObsolete: U\n};\nvar l = /* @__PURE__ */ ((t) => (t[t.Unknown = 0] = \"Unknown\", t[t.Original = 1] = \"Original\", t[t.Septuagint = 2] = \"Septuagint\", t[t.Vulgate = 3] = \"Vulgate\", t[t.English = 4] = \"English\", t[t.RussianProtestant = 5] = \"RussianProtestant\", t[t.RussianOrthodox = 6] = \"RussianOrthodox\", t))(l || {});\nconst h = class h {\n // private versInfo: Versification;\n constructor(e) {\n n(this, \"name\");\n n(this, \"fullPath\");\n n(this, \"isPresent\");\n n(this, \"hasVerseSegments\");\n n(this, \"isCustomized\");\n n(this, \"baseVersification\");\n n(this, \"scriptureBooks\");\n n(this, \"_type\");\n if (e == null)\n throw new Error(\"Argument undefined\");\n typeof e == \"string\" ? (this.name = e, this._type = l[e]) : (this._type = e, this.name = l[e]);\n }\n get type() {\n return this._type;\n }\n equals(e) {\n return !e.type || !this.type ? !1 : e.type === this.type;\n }\n};\nn(h, \"Original\", new h(l.Original)), n(h, \"Septuagint\", new h(l.Septuagint)), n(h, \"Vulgate\", new h(l.Vulgate)), n(h, \"English\", new h(l.English)), n(h, \"RussianProtestant\", new h(l.RussianProtestant)), n(h, \"RussianOrthodox\", new h(l.RussianOrthodox));\nlet c = h;\nfunction E(t, e) {\n const s = e[0];\n for (let r = 1; r < e.length; r++)\n t = t.split(e[r]).join(s);\n return t.split(s);\n}\nvar D = /* @__PURE__ */ ((t) => (t[t.Valid = 0] = \"Valid\", t[t.UnknownVersification = 1] = \"UnknownVersification\", t[t.OutOfRange = 2] = \"OutOfRange\", t[t.VerseOutOfOrder = 3] = \"VerseOutOfOrder\", t[t.VerseRepeated = 4] = \"VerseRepeated\", t))(D || {});\nconst i = class i {\n constructor(e, s, r, a) {\n /** Not yet implemented. */\n n(this, \"firstChapter\");\n /** Not yet implemented. */\n n(this, \"lastChapter\");\n /** Not yet implemented. */\n n(this, \"lastVerse\");\n /** Not yet implemented. */\n n(this, \"hasSegmentsDefined\");\n /** Not yet implemented. */\n n(this, \"text\");\n /** Not yet implemented. */\n n(this, \"BBBCCCVVVS\");\n /** Not yet implemented. */\n n(this, \"longHashCode\");\n /** The versification of the reference. */\n n(this, \"versification\");\n n(this, \"rtlMark\", \"‏\");\n n(this, \"_bookNum\", 0);\n n(this, \"_chapterNum\", 0);\n n(this, \"_verseNum\", 0);\n n(this, \"_verse\");\n if (r == null && a == null)\n if (e != null && typeof e == \"string\") {\n const o = e, u = s != null && s instanceof c ? s : void 0;\n this.setEmpty(u), this.parse(o);\n } else if (e != null && typeof e == \"number\") {\n const o = s != null && s instanceof c ? s : void 0;\n this.setEmpty(o), this._verseNum = e % i.chapterDigitShifter, this._chapterNum = Math.floor(\n e % i.bookDigitShifter / i.chapterDigitShifter\n ), this._bookNum = Math.floor(e / i.bookDigitShifter);\n } else if (s == null)\n if (e != null && e instanceof i) {\n const o = e;\n this._bookNum = o.bookNum, this._chapterNum = o.chapterNum, this._verseNum = o.verseNum, this._verse = o.verse, this.versification = o.versification;\n } else {\n if (e == null) return;\n const o = e instanceof c ? e : i.defaultVersification;\n this.setEmpty(o);\n }\n else\n throw new Error(\"VerseRef constructor not supported.\");\n else if (e != null && s != null && r != null)\n if (typeof e == \"string\" && typeof s == \"string\" && typeof r == \"string\")\n this.setEmpty(a), this.updateInternal(e, s, r);\n else if (typeof e == \"number\" && typeof s == \"number\" && typeof r == \"number\")\n this._bookNum = e, this._chapterNum = s, this._verseNum = r, this.versification = a ?? i.defaultVersification;\n else\n throw new Error(\"VerseRef constructor not supported.\");\n else\n throw new Error(\"VerseRef constructor not supported.\");\n }\n /**\n * Determines if the verse string is in a valid format (does not consider versification).\n */\n static isVerseParseable(e) {\n return e.length > 0 && \"0123456789\".includes(e[0]) && !e.endsWith(this.verseRangeSeparator) && !e.endsWith(this.verseSequenceIndicator);\n }\n /**\n * Tries to parse the specified string into a verse reference.\n * @param str - The string to attempt to parse.\n * @returns success: `true` if the specified string was successfully parsed, `false` otherwise.\n * @returns verseRef: The result of the parse if successful, or empty VerseRef if it failed\n */\n static tryParse(e) {\n let s;\n try {\n return s = new i(e), { success: !0, verseRef: s };\n } catch (r) {\n if (r instanceof v)\n return s = new i(), { success: !1, verseRef: s };\n throw r;\n }\n }\n /**\n * Gets the reference as a comparable integer where the book, chapter, and verse each occupy 3\n * digits.\n * @param bookNum - Book number (this is 1-based, not an index).\n * @param chapterNum - Chapter number.\n * @param verseNum - Verse number.\n * @returns The reference as a comparable integer where the book, chapter, and verse each occupy 3\n * digits.\n */\n static getBBBCCCVVV(e, s, r) {\n return e % i.bcvMaxValue * i.bookDigitShifter + (s >= 0 ? s % i.bcvMaxValue * i.chapterDigitShifter : 0) + (r >= 0 ? r % i.bcvMaxValue : 0);\n }\n /**\n * Deserializes a serialized VerseRef.\n * @param serializedVerseRef - Serialized VerseRef to create from.\n * @returns the deserialized VerseRef.\n */\n static fromJSON(e) {\n const { book: s, chapterNum: r, verseNum: a, verse: o, versificationStr: u } = e, f = o || a.toString();\n let d;\n return u && (d = new c(u)), s ? new i(s, r.toString(), f, d) : new i();\n }\n /**\n * Parses a verse string and gets the leading numeric portion as a number.\n * @param verseStr - verse string to parse\n * @returns true if the entire string could be parsed as a single, simple verse number (1-999);\n * false if the verse string represented a verse bridge, contained segment letters, or was invalid\n */\n static tryGetVerseNum(e) {\n let s;\n if (!e)\n return s = -1, { success: !0, vNum: s };\n s = 0;\n let r;\n for (let a = 0; a < e.length; a++) {\n if (r = e[a], r < \"0\" || r > \"9\")\n return a === 0 && (s = -1), { success: !1, vNum: s };\n if (s = s * 10 + +r - 0, s > i.bcvMaxValue)\n return s = -1, { success: !1, vNum: s };\n }\n return { success: !0, vNum: s };\n }\n /**\n * Checks to see if a VerseRef hasn't been set - all values are the default.\n */\n get isDefault() {\n return this.bookNum === 0 && this.chapterNum === 0 && this.verseNum === 0 && this.versification == null;\n }\n /**\n * Gets whether the verse contains multiple verses.\n */\n get hasMultiple() {\n return this._verse != null && (this._verse.includes(i.verseRangeSeparator) || this._verse.includes(i.verseSequenceIndicator));\n }\n /**\n * Gets or sets the book of the reference. Book is the 3-letter abbreviation in capital letters,\n * e.g. `'MAT'`.\n */\n get book() {\n return m.bookNumberToId(this.bookNum, \"\");\n }\n set book(e) {\n this.bookNum = m.bookIdToNumber(e);\n }\n /**\n * Gets or sets the chapter of the reference,. e.g. `'3'`.\n */\n get chapter() {\n return this.isDefault || this._chapterNum < 0 ? \"\" : this._chapterNum.toString();\n }\n set chapter(e) {\n const s = +e;\n this._chapterNum = Number.isInteger(s) ? s : -1;\n }\n /**\n * Gets or sets the verse of the reference, including range, segments, and sequences, e.g. `'4'`,\n * or `'4b-5a, 7'`.\n */\n get verse() {\n return this._verse != null ? this._verse : this.isDefault || this._verseNum < 0 ? \"\" : this._verseNum.toString();\n }\n set verse(e) {\n const { success: s, vNum: r } = i.tryGetVerseNum(e);\n this._verse = s ? void 0 : e.replace(this.rtlMark, \"\"), this._verseNum = r, !(this._verseNum >= 0) && ({ vNum: this._verseNum } = i.tryGetVerseNum(this._verse));\n }\n /**\n * Get or set Book based on book number, e.g. `42`.\n */\n get bookNum() {\n return this._bookNum;\n }\n set bookNum(e) {\n if (e <= 0 || e > m.lastBook)\n throw new v(\n \"BookNum must be greater than zero and less than or equal to last book\"\n );\n this._bookNum = e;\n }\n /**\n * Gets or sets the chapter number, e.g. `3`. `-1` if not valid.\n */\n get chapterNum() {\n return this._chapterNum;\n }\n set chapterNum(e) {\n this.chapterNum = e;\n }\n /**\n * Gets or sets verse start number, e.g. `4`. `-1` if not valid.\n */\n get verseNum() {\n return this._verseNum;\n }\n set verseNum(e) {\n this._verseNum = e;\n }\n /**\n * String representing the versification (should ONLY be used for serialization/deserialization).\n *\n * @remarks This is for backwards compatibility when ScrVers was an enumeration.\n */\n get versificationStr() {\n var e;\n return (e = this.versification) == null ? void 0 : e.name;\n }\n set versificationStr(e) {\n this.versification = this.versification != null ? new c(e) : void 0;\n }\n /**\n * Determines if the reference is valid.\n */\n get valid() {\n return this.validStatus === 0;\n }\n /**\n * Get the valid status for this reference.\n */\n get validStatus() {\n return this.validateVerse(i.verseRangeSeparators, i.verseSequenceIndicators);\n }\n /**\n * Gets the reference as a comparable integer where the book,\n * chapter, and verse each occupy three digits and the verse is 0.\n */\n get BBBCCC() {\n return i.getBBBCCCVVV(this._bookNum, this._chapterNum, 0);\n }\n /**\n * Gets the reference as a comparable integer where the book,\n * chapter, and verse each occupy three digits. If verse is not null\n * (i.e., this reference represents a complex reference with verse\n * segments or bridge) this cannot be used for an exact comparison.\n */\n get BBBCCCVVV() {\n return i.getBBBCCCVVV(this._bookNum, this._chapterNum, this._verseNum);\n }\n /**\n * Gets whether the verse is defined as an excluded verse in the versification.\n * Does not handle verse ranges.\n */\n // eslint-disable-next-line @typescript-eslint/class-literal-property-style\n get isExcluded() {\n return !1;\n }\n /**\n * Parses the reference in the specified string.\n * Optionally versification can follow reference as in GEN 3:11/4\n * Throw an exception if\n * - invalid book name\n * - chapter number is missing or not a number\n * - verse number is missing or does not start with a number\n * - versification is invalid\n * @param verseStr - string to parse e.g. 'MAT 3:11'\n */\n parse(e) {\n if (e = e.replace(this.rtlMark, \"\"), e.includes(\"/\")) {\n const o = e.split(\"/\");\n if (e = o[0], o.length > 1)\n try {\n const u = +o[1].trim();\n this.versification = new c(l[u]);\n } catch {\n throw new v(\"Invalid reference : \" + e);\n }\n }\n const s = e.trim().split(\" \");\n if (s.length !== 2)\n throw new v(\"Invalid reference : \" + e);\n const r = s[1].split(\":\"), a = +r[0];\n if (r.length !== 2 || m.bookIdToNumber(s[0]) === 0 || !Number.isInteger(a) || a < 0 || !i.isVerseParseable(r[1]))\n throw new v(\"Invalid reference : \" + e);\n this.updateInternal(s[0], r[0], r[1]);\n }\n /**\n * Simplifies this verse ref so that it has no bridging of verses or\n * verse segments like `'1a'`.\n */\n simplify() {\n this._verse = void 0;\n }\n /**\n * Makes a clone of the reference.\n *\n * @returns The cloned VerseRef.\n */\n clone() {\n return new i(this);\n }\n toString() {\n const e = this.book;\n return e === \"\" ? \"\" : `${e} ${this.chapter}:${this.verse}`;\n }\n toJSON() {\n let e = this.verse;\n (e === \"\" || e === this.verseNum.toString()) && (e = void 0);\n const s = {\n book: this.book,\n chapterNum: this.chapterNum,\n verseNum: this.verseNum,\n verse: e,\n versificationStr: this.versificationStr\n };\n return e || delete s.verse, s;\n }\n /**\n * Compares this `VerseRef` with supplied one.\n * @param verseRef - object to compare this one to.\n * @returns `true` if this `VerseRef` is equal to the supplied one, `false` otherwise.\n */\n equals(e) {\n return e instanceof i ? e._bookNum === this._bookNum && e._chapterNum === this._chapterNum && e._verseNum === this._verseNum && e.verse === this.verse && (e.versification == null && this.versification == null || e.versification != null && this.versification != null && e.versification.equals(this.versification)) : !1;\n }\n /**\n * Enumerate all individual verses contained in a VerseRef.\n * Verse ranges are indicated by \"-\" and consecutive verses by \",\"s.\n * Examples:\n * GEN 1:2 returns GEN 1:2\n * GEN 1:1a-3b,5 returns GEN 1:1a, GEN 1:2, GEN 1:3b, GEN 1:5\n * GEN 1:2a-2c returns //! ??????\n *\n * @param specifiedVersesOnly - if set to true return only verses that are\n * explicitly specified only, not verses within a range. Defaults to `false`.\n * @param verseRangeSeparators - Verse range separators.\n * Defaults to `VerseRef.verseRangeSeparators`.\n * @param verseSequenceSeparators - Verse sequence separators.\n * Defaults to `VerseRef.verseSequenceIndicators`.\n * @returns An array of all single verse references in this VerseRef.\n */\n allVerses(e = !1, s = i.verseRangeSeparators, r = i.verseSequenceIndicators) {\n if (this._verse == null || this.chapterNum <= 0)\n return [this.clone()];\n const a = [], o = E(this._verse, r);\n for (const u of o.map((f) => E(f, s))) {\n const f = this.clone();\n f.verse = u[0];\n const d = f.verseNum;\n if (a.push(f), u.length > 1) {\n const b = this.clone();\n if (b.verse = u[1], !e)\n for (let p = d + 1; p < b.verseNum; p++) {\n const J = new i(\n this._bookNum,\n this._chapterNum,\n p,\n this.versification\n );\n this.isExcluded || a.push(J);\n }\n a.push(b);\n }\n }\n return a;\n }\n /**\n * Validates a verse number using the supplied separators rather than the defaults.\n */\n validateVerse(e, s) {\n if (!this.verse)\n return this.internalValid;\n let r = 0;\n for (const a of this.allVerses(!0, e, s)) {\n const o = a.internalValid;\n if (o !== 0)\n return o;\n const u = a.BBBCCCVVV;\n if (r > u)\n return 3;\n if (r === u)\n return 4;\n r = u;\n }\n return 0;\n }\n /**\n * Gets whether a single verse reference is valid.\n */\n get internalValid() {\n return this.versification == null ? 1 : this._bookNum <= 0 || this._bookNum > m.lastBook ? 2 : (m.isCanonical(this._bookNum), 0);\n }\n setEmpty(e = i.defaultVersification) {\n this._bookNum = 0, this._chapterNum = -1, this._verse = void 0, this.versification = e;\n }\n updateInternal(e, s, r) {\n this.bookNum = m.bookIdToNumber(e), this.chapter = s, this.verse = r;\n }\n};\nn(i, \"defaultVersification\", c.English), n(i, \"verseRangeSeparator\", \"-\"), n(i, \"verseSequenceIndicator\", \",\"), n(i, \"verseRangeSeparators\", [i.verseRangeSeparator]), n(i, \"verseSequenceIndicators\", [i.verseSequenceIndicator]), n(i, \"chapterDigitShifter\", 1e3), n(i, \"bookDigitShifter\", i.chapterDigitShifter * i.chapterDigitShifter), n(i, \"bcvMaxValue\", i.chapterDigitShifter - 1), /**\n * The valid status of the VerseRef.\n */\nn(i, \"ValidStatusType\", D);\nlet M = i;\nclass v extends Error {\n}\nexport {\n _ as BookSet,\n m as Canon,\n c as ScrVers,\n l as ScrVersType,\n M as VerseRef,\n v as VerseRefException\n};\n//# sourceMappingURL=index.es.js.map\n","import React from 'react';\nimport * as DropdownMenuPrimitive from '@radix-ui/react-dropdown-menu';\nimport { Check, ChevronRight, Circle } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport const DropdownMenu = DropdownMenuPrimitive.Root;\n\nexport const DropdownMenuTrigger = DropdownMenuPrimitive.Trigger;\n\nexport const DropdownMenuGroup = DropdownMenuPrimitive.Group;\n\nexport const DropdownMenuPortal = DropdownMenuPrimitive.Portal;\n\nexport const DropdownMenuSub = DropdownMenuPrimitive.Sub;\n\nexport const DropdownMenuRadioGroup = DropdownMenuPrimitive.RadioGroup;\n\nexport type DropdownMenuSubTriggerProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.SubTrigger\n> & {\n className?: string;\n inset?: boolean;\n};\n\nexport type DropdownMenuSubContentProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.SubContent\n> & {\n className?: string;\n};\n\nexport type DropdownMenuContentProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Content\n> & {\n className?: string;\n sideOffset?: number;\n};\n\nexport type DropdownMenuItemProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Item\n> & {\n className?: string;\n inset?: boolean;\n};\n\nexport type DropdownMenuCheckboxItemProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.CheckboxItem\n> & {\n className?: string;\n checked?: boolean;\n};\n\nexport type DropdownMenuRadioItemProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.RadioItem\n> & {\n className?: string;\n};\n\nexport type DropdownMenuLabelProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Label\n> & {\n className?: string;\n inset?: boolean;\n};\n\nexport type DropdownMenuSeparatorProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Separator\n> & {\n className?: string;\n};\n\nexport type DropdownMenuShortcutProps = React.HTMLAttributes & {\n className?: string;\n};\n\nexport const DropdownMenuSubTrigger = React.forwardRef<\n React.ElementRef,\n DropdownMenuSubTriggerProps\n>(({ className, inset, children, ...props }, ref) => (\n \n {children}\n \n \n));\nDropdownMenuSubTrigger.displayName = DropdownMenuPrimitive.SubTrigger.displayName;\n\nexport const DropdownMenuSubContent = React.forwardRef<\n React.ElementRef,\n DropdownMenuSubContentProps\n>(({ className, ...props }, ref) => (\n \n));\nDropdownMenuSubContent.displayName = DropdownMenuPrimitive.SubContent.displayName;\n\nexport const DropdownMenuContent = React.forwardRef<\n React.ElementRef,\n DropdownMenuContentProps\n>(({ className, sideOffset = 4, ...props }, ref) => (\n \n \n \n));\nDropdownMenuContent.displayName = DropdownMenuPrimitive.Content.displayName;\n\n/**\n * TODO: fix: direction is not automatically handled by this component, so that shortcuts are\n * display always to the right\n */\nexport const DropdownMenuItem = React.forwardRef<\n React.ElementRef,\n DropdownMenuItemProps\n>(({ className, inset, ...props }, ref) => (\n \n));\nDropdownMenuItem.displayName = DropdownMenuPrimitive.Item.displayName;\n\nexport const DropdownMenuCheckboxItem = React.forwardRef<\n React.ElementRef,\n DropdownMenuCheckboxItemProps\n>(({ className, children, checked, ...props }, ref) => (\n \n \n \n \n \n \n {children}\n \n));\nDropdownMenuCheckboxItem.displayName = DropdownMenuPrimitive.CheckboxItem.displayName;\n\nexport const DropdownMenuRadioItem = React.forwardRef<\n React.ElementRef,\n DropdownMenuRadioItemProps\n>(({ className, children, ...props }, ref) => (\n \n \n \n \n \n \n {children}\n \n));\nDropdownMenuRadioItem.displayName = DropdownMenuPrimitive.RadioItem.displayName;\n\nexport const DropdownMenuLabel = React.forwardRef<\n React.ElementRef,\n DropdownMenuLabelProps\n>(({ className, inset, ...props }, ref) => (\n \n));\nDropdownMenuLabel.displayName = DropdownMenuPrimitive.Label.displayName;\n\nexport const DropdownMenuSeparator = React.forwardRef<\n React.ElementRef,\n DropdownMenuSeparatorProps\n>(({ className, ...props }, ref) => (\n \n));\nDropdownMenuSeparator.displayName = DropdownMenuPrimitive.Separator.displayName;\n\nexport function DropdownMenuShortcut({ className, ...props }: DropdownMenuShortcutProps) {\n return (\n \n );\n}\nDropdownMenuShortcut.displayName = 'DropdownMenuShortcut';\n","import { Canon } from '@sillsdev/scripture';\nimport { PropsWithChildren, KeyboardEvent, forwardRef } from 'react';\nimport { DropdownMenuItem as ShadDropdownMenuItem } from '@/components/shadcn-ui/dropdown-menu';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport type BookType = 'OT' | 'NT' | 'DC';\n\ntype BookMenuItemProps = PropsWithChildren<{\n /** String id of book */\n bookId: string;\n /** Callback to run when a book menu item is selected */\n handleSelectBook: () => void;\n /** Indicates if this menu item is currently selected */\n isSelected: boolean;\n /** Function that is called upon highlighting a book in the dropdown menu */\n handleHighlightBook: () => void;\n /**\n * Function that is called on pressing a key\n *\n * @param event Event that contains information about the key stroke\n */\n handleKeyDown: (event: KeyboardEvent) => void;\n /**\n * Type of book associated with this menu item, coordinates color labels ? Mock up has the labels\n * coordinated to genre\n */\n bookType: BookType;\n}>;\n\nconst BookMenuItem = forwardRef(\n (\n {\n bookId,\n handleSelectBook,\n isSelected,\n handleHighlightBook,\n handleKeyDown,\n bookType,\n children,\n }: BookMenuItemProps,\n ref,\n ) => {\n return (\n {\n // preventDefault() here prevents the entire dropdown menu from closing when selecting this item\n event.preventDefault();\n handleSelectBook();\n }}\n onKeyDown={(event: KeyboardEvent) => {\n handleKeyDown(event);\n }}\n onFocus={handleHighlightBook}\n onMouseMove={handleHighlightBook}\n >\n \n {Canon.bookIdToEnglishName(bookId)}\n \n {isSelected &&
    {children}
    }\n \n );\n },\n);\n\nexport default BookMenuItem;\n","import { cn } from '@/utils/shadcn-ui.util';\nimport { useCallback } from 'react';\n\nexport type ChapterSelectProps = {\n /**\n * Callback to run when a chapter div is selected\n *\n * @param chapterNumber Number of the chapter that has been selected\n */\n handleSelectChapter: (chapterNumber: number) => void;\n /** The highest chapter number in the book (of course equal to number of chapters in the book) */\n endChapter: number;\n /** The chapter number that is currently selected */\n activeChapter: number;\n /** The chapter number that is currently highlighted using keyboard or mouse navigation */\n highlightedChapter: number;\n /**\n * Callback to run when a chapter is highlighted by the user\n *\n * @param chapterNumber The chapter that is highlighted\n */\n handleHighlightedChapter: (chapterNumber: number) => void;\n};\n\nfunction ChapterSelect({\n handleSelectChapter,\n endChapter,\n activeChapter,\n highlightedChapter,\n handleHighlightedChapter,\n}: ChapterSelectProps) {\n const chapters = Array.from({ length: endChapter }, (_, i) => i + 1);\n\n const handleMouse = useCallback(\n (chapterNumber: number) => {\n handleHighlightedChapter(chapterNumber);\n },\n [handleHighlightedChapter],\n );\n\n return (\n
    \n {chapters.map((chapter) => (\n {\n event.preventDefault();\n event.stopPropagation();\n handleSelectChapter(chapter);\n }}\n role=\"button\"\n onKeyDown={(event) => {\n if (event.key === 'Enter') {\n handleSelectChapter(chapter);\n }\n }}\n tabIndex={0}\n onMouseMove={() => handleMouse(chapter)}\n >\n {chapter}\n
    \n ))}\n
    \n );\n}\n\nexport default ChapterSelect;\n","import { DropdownMenuLabel as ShadDropdownMenuLabel } from '@/components/shadcn-ui/dropdown-menu';\nimport { Bookmark, Clock, ArrowDownWideNarrow } from 'lucide-react';\n\nexport type GoToMenuItemProps = {\n handleSort: () => void;\n handleLocationHistory: () => void;\n handleBookmarks: () => void;\n};\n\nfunction GoToMenuItem({ handleSort, handleLocationHistory, handleBookmarks }: GoToMenuItemProps) {\n return (\n \n

    Go To

    \n
    \n \n \n \n
    \n
    \n );\n}\n\nexport default GoToMenuItem;\n","import BookChapterInput from '@/components/advanced/book-chapter-control/book-chapter-input.component';\nimport BookMenuItem, {\n BookType,\n} from '@/components/advanced/book-chapter-control/book-menu-item.component';\nimport ChapterSelect from '@/components/advanced/book-chapter-control/chapter-select.component';\nimport GoToMenuItem from '@/components/advanced/book-chapter-control/go-to-menu-item.component';\nimport {\n DropdownMenu as ShadDropdownMenu,\n DropdownMenuContent as ShadDropdownMenuContent,\n DropdownMenuLabel as ShadDropdownMenuLabel,\n DropdownMenuSeparator as ShadDropdownMenuSeparator,\n DropdownMenuTrigger as ShadDropdownMenuTrigger,\n} from '@/components/shadcn-ui/dropdown-menu';\nimport { Canon } from '@sillsdev/scripture';\nimport { ScriptureReference, getChaptersForBook } from 'platform-bible-utils';\nimport {\n KeyboardEvent as ReactKeyboardEvent,\n useCallback,\n useEffect,\n useLayoutEffect,\n useRef,\n useState,\n} from 'react';\n\ntype BookTypeLabels = {\n [bookType in BookType]: string;\n};\ntype BookChapterControlProps = {\n scrRef: ScriptureReference;\n handleSubmit: (scrRef: ScriptureReference) => void;\n};\n\nconst ALL_BOOK_IDS = Canon.allBookIds;\nconst BOOK_TYPE_LABELS: BookTypeLabels = {\n OT: 'Old Testament',\n NT: 'New Testament',\n DC: 'Deuterocanon',\n};\nconst BOOK_TYPE_ARRAY: BookType[] = ['OT', 'NT', 'DC'];\n// This is the height of three menu items to offset scrolling to the selected menu item\n// If you use menuItemRef.clientHeight- includes height of chapter div which is too big\nconst SCROLL_OFFSET = 32 + 32 + 32;\nconst SEARCH_QUERY_FORMATS = [\n /^(\\w+)$/i, // Matches a single word (book name or id)\n /^(\\w+)(?:\\s(\\d+))$/i, // Matches a word followed by a chapter number\n /^(\\w+)(?:\\s(\\d+):(\\d+))$/i, // Matches a word followed by a chapter and verse number\n];\nconst fetchGroupedBooks = (bookType: BookType) => {\n const groupedBooks = {\n OT: ALL_BOOK_IDS.filter((bookId) => Canon.isBookOT(bookId)),\n NT: ALL_BOOK_IDS.filter((bookId) => Canon.isBookNT(bookId)),\n DC: ALL_BOOK_IDS.filter((bookId) => Canon.isBookDC(bookId)),\n };\n return groupedBooks[bookType];\n};\nconst fetchEndChapter = (bookId: string) => {\n // getChaptersForBook returns -1 if not found in scrBookData\n // scrBookData only includes OT and NT, so all DC will return -1\n return getChaptersForBook(Canon.bookIdToNumber(bookId));\n};\n\n/**\n * Gets all of the English names from book ids\n *\n * @returns String[]\n */\nfunction getAllEnglishNames(): string[] {\n const allEnglishNames = ALL_BOOK_IDS.map((bookId) => {\n return Canon.bookIdToEnglishName(bookId);\n });\n return allEnglishNames;\n}\n\n/**\n * Determines if bookName is in allEnglishNames\n *\n * @param bookName Book English name\n * @returns True if bookName is included, false otherwise\n */\nfunction isValidBookEnglishName(bookName: string): boolean {\n return getAllEnglishNames().includes(bookName);\n}\n\n/**\n * Gets a bookId from given English name\n *\n * @param bookName Book English name\n * @returns BookId of provided bookName, undefined otherwise\n */\nfunction getBookIdFromEnglishName(bookName: string): string | undefined {\n // Convert bookName to lowercase and then capitalize the first letter\n const formattedBookName = bookName.toLowerCase().replace(/^\\w/, (c) => c.toUpperCase());\n\n if (isValidBookEnglishName(formattedBookName)) {\n const matchingBookId = ALL_BOOK_IDS.find((bookId) => {\n return Canon.bookIdToEnglishName(bookId) === formattedBookName;\n });\n return matchingBookId;\n }\n\n return undefined;\n}\n\nfunction BookChapterControl({ scrRef, handleSubmit }: BookChapterControlProps) {\n const [searchQuery, setSearchQuery] = useState('');\n const [selectedBookId, setSelectedBookId] = useState(\n Canon.bookNumberToId(scrRef.bookNum),\n );\n const [highlightedChapter, setHighlightedChapter] = useState(scrRef.chapterNum ?? 0);\n const [highlightedBookId, setHighlightedBookId] = useState(\n Canon.bookNumberToId(scrRef.bookNum),\n );\n const [isContentOpen, setIsContentOpen] = useState(false);\n const [isContentOpenDelayed, setIsContentOpenDelayed] = useState(isContentOpen);\n\n // This ref will always be defined\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const inputRef = useRef(undefined!);\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const contentRef = useRef(undefined!);\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const menuItemRef = useRef(undefined!);\n\n const fetchFilteredBooks = useCallback(\n (bookType: BookType) => {\n return fetchGroupedBooks(bookType).filter((bookId: string) => {\n const englishNameLowerCase = Canon.bookIdToEnglishName(bookId).toLowerCase();\n const normalizedQuery = searchQuery.replace(/[^a-zA-Z]/g, '').toLowerCase();\n return (\n englishNameLowerCase.includes(normalizedQuery) || // Match book name\n bookId.toLowerCase().includes(normalizedQuery) // Match book ID\n );\n });\n },\n [searchQuery],\n );\n\n const handleSearchInput = (searchString: string) => {\n setSearchQuery(searchString);\n };\n\n /**\n * Whether to prevent radix's logic from closing the dropdown. This is important because radix\n * tries to close the dropdown when the input first focuses, and we don't want it to do that. But\n * we don't want to prevent the dropdown from closing when we click away from the input, so we\n * don't want to just keep it open if the input is focused\n */\n const shouldPreventAutoClosing = useRef(false);\n\n const controlMenuState = useCallback((open: boolean) => {\n if (shouldPreventAutoClosing.current) {\n shouldPreventAutoClosing.current = false;\n return;\n }\n setIsContentOpen(open);\n }, []);\n\n const updateReference = useCallback(\n (bookId: string, shouldClose: boolean, chapter?: number, verse?: number) => {\n setHighlightedChapter(\n Canon.bookNumberToId(scrRef.bookNum) !== bookId ? 1 : scrRef.chapterNum,\n );\n\n if (shouldClose || fetchEndChapter(bookId) === -1) {\n handleSubmit({\n bookNum: Canon.bookIdToNumber(bookId),\n chapterNum: chapter || 1,\n verseNum: verse || 1,\n });\n\n setIsContentOpen(false);\n setSearchQuery('');\n return;\n }\n\n setSelectedBookId(selectedBookId !== bookId ? bookId : '');\n setIsContentOpen(!shouldClose);\n },\n [handleSubmit, scrRef.bookNum, scrRef.chapterNum, selectedBookId],\n );\n\n const handleSelectChapter = (chapterNumber: number) => {\n if (chapterNumber <= 0 || chapterNumber > fetchEndChapter(selectedBookId)) {\n return;\n }\n updateReference(selectedBookId, true, chapterNumber);\n };\n\n const handleInputSubmit = useCallback(() => {\n SEARCH_QUERY_FORMATS.forEach((format) => {\n const matches = searchQuery.match(format);\n if (matches) {\n // Book should be a bookId or an english name\n const [book, chapter = undefined, verse = undefined] = matches.slice(1);\n const englishName = getBookIdFromEnglishName(book);\n\n if (Canon.isBookIdValid(book) || englishName) {\n updateReference(\n englishName ?? book,\n true,\n chapter ? parseInt(chapter, 10) : 1,\n verse ? parseInt(verse, 10) : 1,\n );\n }\n }\n });\n }, [updateReference, searchQuery]);\n\n const handleKeyDownInput = useCallback(\n (event: ReactKeyboardEvent) => {\n if (!isContentOpen) {\n setIsContentOpen(true);\n } else if (event.key === 'ArrowDown' || event.key === 'ArrowUp') {\n if (\n typeof menuItemRef !== 'undefined' &&\n // Ref uses null\n // eslint-disable-next-line no-null/no-null\n menuItemRef.current !== null\n ) {\n menuItemRef.current.focus();\n } else if (\n typeof contentRef !== 'undefined' &&\n // Ref uses null\n // eslint-disable-next-line no-null/no-null\n contentRef.current !== null\n ) {\n contentRef.current.focus();\n }\n event.preventDefault();\n }\n },\n [isContentOpen],\n );\n\n const handleKeyDownContent = (event: ReactKeyboardEvent) => {\n // When the dropdown menu has focus, key strokes should give focus to the input component,\n // unless they're navigation keys (arrows and enter)\n const { key } = event;\n if (\n key === 'ArrowRight' ||\n key === 'ArrowLeft' ||\n key === 'ArrowDown' ||\n key === 'ArrowUp' ||\n key === 'Enter'\n ) {\n return;\n }\n\n inputRef.current.dispatchEvent(new KeyboardEvent('keydown', { key }));\n inputRef.current.focus();\n };\n\n const handleKeyDownMenuItem = (event: ReactKeyboardEvent) => {\n const { key } = event;\n if (highlightedBookId === selectedBookId) {\n if (key === 'Enter') {\n event.preventDefault();\n updateReference(selectedBookId, true, highlightedChapter);\n return;\n }\n\n let chapterOffSet = 0;\n if (key === 'ArrowRight') {\n if (highlightedChapter < fetchEndChapter(highlightedBookId)) {\n chapterOffSet = 1;\n } else {\n event.preventDefault();\n return;\n }\n } else if (key === 'ArrowLeft') {\n if (highlightedChapter > 1) {\n chapterOffSet = -1;\n } else {\n event.preventDefault();\n return;\n }\n } else if (key === 'ArrowDown') {\n chapterOffSet = 6;\n } else if (key === 'ArrowUp') {\n chapterOffSet = -6;\n }\n if (\n highlightedChapter + chapterOffSet <= 0 ||\n highlightedChapter + chapterOffSet > fetchEndChapter(highlightedBookId)\n ) {\n setHighlightedChapter(0);\n } else if (chapterOffSet !== 0) {\n setHighlightedChapter(highlightedChapter + chapterOffSet);\n event.preventDefault();\n }\n }\n };\n\n useEffect(() => {\n if (selectedBookId === highlightedBookId) {\n if (selectedBookId === Canon.bookNumberToId(scrRef.bookNum)) {\n setHighlightedChapter(scrRef.chapterNum);\n } else {\n setHighlightedChapter(1);\n }\n } else {\n setHighlightedChapter(0);\n }\n }, [highlightedBookId, scrRef.bookNum, scrRef.chapterNum, selectedBookId]);\n\n // The purpose of these useLayoutEffects and timeout is to delay the scroll just\n // enough so that the refs are defined and available when they are used after the timeout\n useLayoutEffect(() => {\n setIsContentOpenDelayed(isContentOpen);\n }, [isContentOpen]);\n\n useLayoutEffect(() => {\n const scrollTimeout = setTimeout(() => {\n if (isContentOpenDelayed && contentRef.current && menuItemRef.current) {\n const menuItemOffsetTop = menuItemRef.current.offsetTop;\n const scrollPosition = menuItemOffsetTop - SCROLL_OFFSET;\n contentRef.current.scrollTo({ top: scrollPosition, behavior: 'instant' });\n }\n }, 10);\n return () => {\n clearTimeout(scrollTimeout);\n };\n }, [isContentOpenDelayed]);\n\n return (\n
    \n \n \n {\n setSelectedBookId(Canon.bookNumberToId(scrRef.bookNum));\n setHighlightedBookId(Canon.bookNumberToId(scrRef.bookNum));\n setHighlightedChapter(scrRef.chapterNum > 0 ? scrRef.chapterNum : 0);\n setIsContentOpen(true);\n inputRef.current.focus();\n }}\n onFocus={() => {\n // Radix thinks we want to close because the input is being focused. Prevent that\n shouldPreventAutoClosing.current = true;\n }}\n handleSubmit={handleInputSubmit}\n placeholder={`${Canon.bookNumberToEnglishName(scrRef.bookNum)} ${scrRef.chapterNum}:${scrRef.verseNum}`}\n />\n \n \n console.log('sorting')}\n handleLocationHistory={() => console.log('location history')}\n handleBookmarks={() => console.log('bookmarks')}\n />\n {BOOK_TYPE_ARRAY.map(\n (bookType, bookTypeIndex) =>\n fetchFilteredBooks(bookType).length > 0 && (\n
    \n \n {BOOK_TYPE_LABELS[bookType]}\n \n\n {fetchFilteredBooks(bookType).map((bookId) => (\n
    \n updateReference(bookId, false)}\n isSelected={selectedBookId === bookId}\n handleHighlightBook={() => setHighlightedBookId(bookId)}\n handleKeyDown={handleKeyDownMenuItem}\n bookType={bookType}\n ref={(element: HTMLDivElement) => {\n if (selectedBookId === bookId) menuItemRef.current = element;\n }}\n >\n {\n setHighlightedChapter(chapterNumber);\n }}\n />\n \n
    \n ))}\n {BOOK_TYPE_ARRAY.length - 1 !== bookTypeIndex ? (\n \n ) : undefined}\n
    \n ),\n )}\n \n
    \n
    \n );\n}\n\nexport default BookChapterControl;\n","import React from 'react';\nimport { Slot } from '@radix-ui/react-slot';\nimport { cva, type VariantProps } from 'class-variance-authority';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport const buttonVariants = cva(\n 'pr-twp tw-inline-flex tw-items-center tw-justify-center tw-whitespace-nowrap tw-rounded-md tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-colors focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50',\n {\n variants: {\n variant: {\n default: 'tw-bg-primary tw-text-primary-foreground hover:tw-bg-primary/90',\n destructive: 'tw-bg-destructive tw-text-destructive-foreground hover:tw-bg-destructive/90',\n outline:\n 'tw-border tw-border-input tw-bg-background hover:tw-bg-accent hover:tw-text-accent-foreground',\n secondary: 'tw-bg-secondary tw-text-secondary-foreground hover:tw-bg-secondary/80',\n ghost: 'hover:tw-bg-accent hover:tw-text-accent-foreground',\n link: 'tw-text-primary tw-underline-offset-4 hover:tw-underline',\n },\n size: {\n default: 'tw-h-10 tw-px-4 tw-py-2',\n sm: 'tw-h-9 tw-rounded-md tw-px-3',\n lg: 'tw-h-11 tw-rounded-md tw-px-8',\n icon: 'tw-h-10 tw-w-10',\n },\n },\n defaultVariants: {\n variant: 'default',\n size: 'default',\n },\n },\n);\n\nexport interface ButtonProps\n extends React.ButtonHTMLAttributes,\n VariantProps {\n asChild?: boolean;\n}\n\nexport const Button = React.forwardRef(\n ({ className, variant, size, asChild = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'button';\n return (\n \n );\n },\n);\nButton.displayName = 'Button';\n","import React from 'react';\nimport * as LabelPrimitive from '@radix-ui/react-label';\nimport { cva, type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst labelVariants = cva(\n 'tw-text-sm tw-font-medium tw-leading-none peer-disabled:tw-cursor-not-allowed peer-disabled:tw-opacity-70',\n);\n\nexport const Label = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef & VariantProps\n>(({ className, ...props }, ref) => (\n \n));\nLabel.displayName = LabelPrimitive.Root.displayName;\n","import React from 'react';\nimport * as RadioGroupPrimitive from '@radix-ui/react-radio-group';\nimport { Circle } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst RadioGroup = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => {\n return (\n \n );\n});\nRadioGroup.displayName = RadioGroupPrimitive.Root.displayName;\n\nconst RadioGroupItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => {\n return (\n \n \n \n \n \n );\n});\nRadioGroupItem.displayName = RadioGroupPrimitive.Item.displayName;\n\nexport { RadioGroup, RadioGroupItem };\n","import React from 'react';\nimport * as PopoverPrimitive from '@radix-ui/react-popover';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Popover = PopoverPrimitive.Root;\n\nconst PopoverTrigger = PopoverPrimitive.Trigger;\n\nconst PopoverContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, align = 'center', sideOffset = 4, ...props }, ref) => (\n \n \n \n));\nPopoverContent.displayName = PopoverPrimitive.Content.displayName;\n\nexport { Popover, PopoverTrigger, PopoverContent };\n","import React from 'react';\nimport * as DialogPrimitive from '@radix-ui/react-dialog';\nimport { X } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Dialog = DialogPrimitive.Root;\n\nconst DialogTrigger = DialogPrimitive.Trigger;\n\nconst DialogPortal = DialogPrimitive.Portal;\n\nconst DialogClose = DialogPrimitive.Close;\n\nconst DialogOverlay = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nDialogOverlay.displayName = DialogPrimitive.Overlay.displayName;\n\nconst DialogContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, ...props }, ref) => (\n \n \n \n {children}\n \n \n Close\n \n \n \n));\nDialogContent.displayName = DialogPrimitive.Content.displayName;\n\nfunction DialogHeader({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nDialogHeader.displayName = 'DialogHeader';\n\nfunction DialogFooter({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nDialogFooter.displayName = 'DialogFooter';\n\nconst DialogTitle = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nDialogTitle.displayName = DialogPrimitive.Title.displayName;\n\nconst DialogDescription = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nDialogDescription.displayName = DialogPrimitive.Description.displayName;\n\nexport {\n Dialog,\n DialogPortal,\n DialogOverlay,\n DialogClose,\n DialogTrigger,\n DialogContent,\n DialogHeader,\n DialogFooter,\n DialogTitle,\n DialogDescription,\n};\n","import React from 'react';\nimport { type DialogProps } from '@radix-ui/react-dialog';\nimport { Command as CommandPrimitive } from 'cmdk';\nimport { Search } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Dialog, DialogContent } from '@/components/shadcn-ui/dialog';\n\nconst Command = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nCommand.displayName = CommandPrimitive.displayName;\n\ninterface CommandDialogProps extends DialogProps {}\n\nfunction CommandDialog({ children, ...props }: CommandDialogProps) {\n return (\n \n \n \n {children}\n \n \n \n );\n}\n\nconst CommandInput = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n
    \n \n \n
    \n));\n\nCommandInput.displayName = CommandPrimitive.Input.displayName;\n\nconst CommandList = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\n\nCommandList.displayName = CommandPrimitive.List.displayName;\n\nconst CommandEmpty = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>((props, ref) => (\n \n));\n\nCommandEmpty.displayName = CommandPrimitive.Empty.displayName;\n\nconst CommandGroup = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\n\nCommandGroup.displayName = CommandPrimitive.Group.displayName;\n\nconst CommandSeparator = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nCommandSeparator.displayName = CommandPrimitive.Separator.displayName;\n\nconst CommandItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\n\nCommandItem.displayName = CommandPrimitive.Item.displayName;\n\nfunction CommandShortcut({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nCommandShortcut.displayName = 'CommandShortcut';\n\nexport {\n Command,\n CommandDialog,\n CommandInput,\n CommandList,\n CommandEmpty,\n CommandGroup,\n CommandItem,\n CommandShortcut,\n CommandSeparator,\n};\n","import { useState } from 'react';\nimport { Check, ChevronsUpDown } from 'lucide-react';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport { Popover, PopoverContent, PopoverTrigger } from '@/components/shadcn-ui/popover';\nimport {\n Command,\n CommandEmpty,\n CommandInput,\n CommandItem,\n CommandList,\n} from '@/components/shadcn-ui/command';\nimport { PopoverProps } from '@radix-ui/react-popover';\n\nexport type ComboBoxLabelOption = { label: string };\nexport type ComboBoxOption = string | number | ComboBoxLabelOption;\n\nexport type ComboBoxProps = {\n /** Optional unique identifier */\n id?: string;\n /** Text label title for combobox */\n /** List of available options for the dropdown menu */\n options?: readonly T[];\n /** Additional css classes to help with unique styling of the combo box button */\n buttonClassName?: string;\n /** Additional css classes to help with unique styling of the combo box popover */\n popoverContentClassName?: string;\n /**\n * The selected value that the combo box currently holds. Must be shallow equal to one of the\n * options entries.\n */\n value?: T;\n /** Triggers when content of textfield is changed */\n onChange?: (newValue: T) => void;\n /** Used to determine the string value for a given option. */\n getOptionLabel?: (option: ComboBoxOption) => string;\n /** Text displayed on button if `value` is undefined */\n buttonPlaceholder?: string;\n /** Placeholder text for text field */\n textPlaceholder?: string;\n /** Text to display when no options match input */\n commandEmptyMessage?: string;\n /** Variant of button */\n buttonVariant?: ButtonProps['variant'];\n /** Text direction ltr or rtl */\n dir?: Direction;\n /** Optional boolean to set if trigger should be disabled */\n isDisabled?: boolean;\n} & PopoverProps;\n\ntype Direction = 'ltr' | 'rtl';\n\nfunction getOptionLabelDefault(option: ComboBoxOption): string {\n if (typeof option === 'string') {\n return option;\n }\n if (typeof option === 'number') {\n return option.toString();\n }\n return option.label;\n}\n\n/**\n * Autocomplete input and command palette with a list of suggestions.\n *\n * Thanks to Shadcn for heavy inspiration and documentation\n * https://ui.shadcn.com/docs/components/combobox\n */\nfunction ComboBox({\n id,\n options = [],\n buttonClassName,\n popoverContentClassName,\n value,\n onChange = () => {},\n getOptionLabel = getOptionLabelDefault,\n buttonPlaceholder = '',\n textPlaceholder = '',\n commandEmptyMessage = 'No option found',\n buttonVariant = 'outline',\n dir = 'ltr',\n isDisabled = false,\n ...props\n}: ComboBoxProps) {\n const [open, setOpen] = useState(false);\n\n return (\n \n \n \n \n {value ? getOptionLabel(value) : buttonPlaceholder}\n \n \n \n \n \n \n \n {commandEmptyMessage}\n \n {options.map((option) => (\n {\n onChange(option);\n setOpen(false);\n }}\n >\n \n {getOptionLabel(option)}\n \n ))}\n \n \n \n \n );\n}\n\nexport default ComboBox;\n","import { useMemo } from 'react';\nimport ComboBox from '@/components/basics/combo-box.component';\nimport { Label } from '@/components/shadcn-ui/label';\n\nexport type ChapterRangeSelectorProps = {\n startChapter: number;\n endChapter: number;\n handleSelectStartChapter: (chapter: number) => void;\n handleSelectEndChapter: (chapter: number) => void;\n isDisabled?: boolean;\n chapterCount: number;\n};\n\nexport default function ChapterRangeSelector({\n startChapter,\n endChapter,\n handleSelectStartChapter,\n handleSelectEndChapter,\n isDisabled = false,\n chapterCount,\n}: ChapterRangeSelectorProps) {\n const chapterOptions = useMemo(\n () => Array.from({ length: chapterCount }, (_, index) => index + 1),\n [chapterCount],\n );\n\n const onChangeStartChapter = (value: number) => {\n handleSelectStartChapter(value);\n if (value > endChapter) {\n handleSelectEndChapter(value);\n }\n };\n\n const onChangeEndChapter = (value: number) => {\n handleSelectEndChapter(value);\n if (value < startChapter) {\n handleSelectStartChapter(value);\n }\n };\n\n return (\n <>\n \n option.toString()}\n value={startChapter}\n />\n\n \n option.toString()}\n value={endChapter}\n />\n \n );\n}\n","import { Button } from '@/components/shadcn-ui/button';\nimport { Label } from '@/components/shadcn-ui/label';\nimport { RadioGroup, RadioGroupItem } from '@/components/shadcn-ui/radio-group';\nimport { Canon } from '@sillsdev/scripture';\nimport { LocalizedStringValue } from 'platform-bible-utils';\nimport { useState } from 'react';\nimport ChapterRangeSelector, {\n ChapterRangeSelectorProps,\n} from '../basics/chapter-range-selector.component';\n\nexport enum BookSelectionMode {\n CURRENT_BOOK = 'current book',\n CHOOSE_BOOKS = 'choose books',\n}\n\n/**\n * Object containing all keys used for localization in this component. If you're using this\n * component in an extension, you can pass it into the useLocalizedStrings hook to easily obtain the\n * localized strings and pass them into the localizedStrings prop of this component\n */\nexport const BOOK_SELECTOR_STRING_KEYS = Object.freeze([\n '%webView_bookSelector_currentBook%',\n '%webView_bookSelector_choose%',\n '%webView_bookSelector_chooseBooks%',\n] as const);\n\nexport type BookSelectorLocalizedStrings = {\n [localizedInventoryKey in (typeof BOOK_SELECTOR_STRING_KEYS)[number]]?: LocalizedStringValue;\n};\n\n/**\n * Gets the localized value for the provided key\n *\n * @param strings Object containing localized string\n * @param key Key for a localized string\n * @returns The localized value for the provided key, if available. Returns the key if no localized\n * value is available\n */\nconst localizeString = (\n strings: BookSelectorLocalizedStrings,\n key: keyof BookSelectorLocalizedStrings,\n) => {\n return strings[key] ?? key;\n};\n\ntype BookSelectorProps = ChapterRangeSelectorProps & {\n handleBookSelectionModeChange: (newMode: BookSelectionMode) => void;\n currentBookName: string;\n onSelectBooks: () => void;\n selectedBookIds: string[];\n localizedStrings: BookSelectorLocalizedStrings;\n};\n\nexport default function BookSelector({\n handleBookSelectionModeChange,\n currentBookName,\n onSelectBooks,\n selectedBookIds,\n chapterCount,\n endChapter,\n handleSelectEndChapter,\n startChapter,\n handleSelectStartChapter,\n localizedStrings,\n}: BookSelectorProps) {\n const currentBookText = localizeString(localizedStrings, '%webView_bookSelector_currentBook%');\n const chooseText = localizeString(localizedStrings, '%webView_bookSelector_choose%');\n const chooseBooksText = localizeString(localizedStrings, '%webView_bookSelector_chooseBooks%');\n\n const [bookSelectionMode, setBookSelectionMode] = useState(\n BookSelectionMode.CURRENT_BOOK,\n );\n\n const onSelectionModeChange = (newMode: BookSelectionMode) => {\n setBookSelectionMode(newMode);\n handleBookSelectionModeChange(newMode);\n };\n\n return (\n onSelectionModeChange(value as BookSelectionMode)}\n >\n
    \n
    \n
    \n \n \n
    \n \n
    \n \n
    \n
    \n
    \n
    \n \n \n
    \n \n onSelectBooks()}\n >\n {chooseText}\n \n
    \n
    \n \n );\n}\n","import { DropdownMenuTrigger } from '@radix-ui/react-dropdown-menu';\nimport { FilterIcon } from 'lucide-react';\nimport { Table } from '@tanstack/react-table';\n\nimport { Button } from '@/components/shadcn-ui/button';\nimport {\n DropdownMenu,\n DropdownMenuCheckboxItem,\n DropdownMenuContent,\n DropdownMenuLabel,\n DropdownMenuSeparator,\n} from '@/components/shadcn-ui/dropdown-menu';\n\ninterface DataTableViewOptionsProps {\n table: Table;\n}\n\nfunction DataTableViewOptions({ table }: DataTableViewOptionsProps) {\n return (\n \n \n \n \n \n Toggle columns\n \n {table\n .getAllColumns()\n .filter((column) => column.getCanHide())\n .map((column) => {\n return (\n column.toggleVisibility(!!value)}\n >\n {column.id}\n \n );\n })}\n \n \n );\n}\n\nexport default DataTableViewOptions;\n","import React from 'react';\nimport * as SelectPrimitive from '@radix-ui/react-select';\nimport { Check, ChevronDown, ChevronUp } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Select = SelectPrimitive.Root;\n\nconst SelectGroup = SelectPrimitive.Group;\n\nconst SelectValue = SelectPrimitive.Value;\n\nconst SelectTrigger = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, ...props }, ref) => (\n span]:tw-line-clamp-1',\n className,\n )}\n {...props}\n >\n {children}\n \n \n \n \n));\nSelectTrigger.displayName = SelectPrimitive.Trigger.displayName;\n\nconst SelectScrollUpButton = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n));\nSelectScrollUpButton.displayName = SelectPrimitive.ScrollUpButton.displayName;\n\nconst SelectScrollDownButton = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n));\nSelectScrollDownButton.displayName = SelectPrimitive.ScrollDownButton.displayName;\n\nconst SelectContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, position = 'popper', ...props }, ref) => (\n \n \n \n \n {children}\n \n \n \n \n));\nSelectContent.displayName = SelectPrimitive.Content.displayName;\n\nconst SelectLabel = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSelectLabel.displayName = SelectPrimitive.Label.displayName;\n\nconst SelectItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, ...props }, ref) => (\n \n \n \n \n \n \n\n {children}\n \n));\nSelectItem.displayName = SelectPrimitive.Item.displayName;\n\nconst SelectSeparator = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSelectSeparator.displayName = SelectPrimitive.Separator.displayName;\n\nexport {\n Select,\n SelectGroup,\n SelectValue,\n SelectTrigger,\n SelectContent,\n SelectLabel,\n SelectItem,\n SelectSeparator,\n SelectScrollUpButton,\n SelectScrollDownButton,\n};\n","import { ChevronLeftIcon, ChevronRightIcon, ArrowLeftIcon, ArrowRightIcon } from 'lucide-react';\nimport { Table } from '@tanstack/react-table';\n\nimport { Button } from '@/components/shadcn-ui/button';\nimport {\n Select,\n SelectContent,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\n\ninterface DataTablePaginationProps {\n table: Table;\n}\n\nfunction DataTablePagination({ table }: DataTablePaginationProps) {\n return (\n
    \n
    \n
    \n {table.getFilteredSelectedRowModel().rows.length} of{' '}\n {table.getFilteredRowModel().rows.length} row(s) selected\n
    \n
    \n

    Rows per page

    \n {\n table.setPageSize(Number(value));\n }}\n >\n \n \n \n \n {[10, 20, 30, 40, 50].map((pageSize) => (\n \n {pageSize}\n \n ))}\n \n \n
    \n
    \n Page {table.getState().pagination.pageIndex + 1} of {table.getPageCount()}\n
    \n
    \n table.setPageIndex(0)}\n disabled={!table.getCanPreviousPage()}\n >\n Go to first page\n \n \n table.previousPage()}\n disabled={!table.getCanPreviousPage()}\n >\n Go to previous page\n \n \n table.nextPage()}\n disabled={!table.getCanNextPage()}\n >\n Go to next page\n \n \n table.setPageIndex(table.getPageCount() - 1)}\n disabled={!table.getCanNextPage()}\n >\n Go to last page\n \n \n
    \n
    \n
    \n );\n}\n\nexport default DataTablePagination;\n","import React from 'react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Table = React.forwardRef<\n HTMLTableElement,\n React.HTMLAttributes & { stickyHeader?: boolean }\n>(({ className, stickyHeader, ...props }, ref) => (\n
    \n \n
    \n));\nTable.displayName = 'Table';\n\nconst TableHeader = React.forwardRef<\n HTMLTableSectionElement,\n React.HTMLAttributes & { stickyHeader?: boolean }\n>(({ className, stickyHeader, ...props }, ref) => (\n \n));\nTableHeader.displayName = 'TableHeader';\n\nconst TableBody = React.forwardRef<\n HTMLTableSectionElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableBody.displayName = 'TableBody';\n\nconst TableFooter = React.forwardRef<\n HTMLTableSectionElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n tr]:last:tw-border-b-0', className)}\n {...props}\n />\n));\nTableFooter.displayName = 'TableFooter';\n\nconst TableRow = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nTableRow.displayName = 'TableRow';\n\nconst TableHead = React.forwardRef<\n HTMLTableCellElement,\n React.ThHTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableHead.displayName = 'TableHead';\n\nconst TableCell = React.forwardRef<\n HTMLTableCellElement,\n React.TdHTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableCell.displayName = 'TableCell';\n\nconst TableCaption = React.forwardRef<\n HTMLTableCaptionElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableCaption.displayName = 'TableCaption';\n\nexport { Table, TableHeader, TableBody, TableFooter, TableHead, TableRow, TableCell, TableCaption };\n","import { useState } from 'react';\n\nimport {\n ColumnFiltersState,\n flexRender,\n getCoreRowModel,\n getFilteredRowModel,\n getPaginationRowModel,\n getSortedRowModel,\n SortingState,\n ColumnDef as TSColumnDef,\n Row as TSRow,\n RowSelectionState as TSRowSelectionState,\n SortDirection as TSSortDirection,\n Table as TSTable,\n useReactTable,\n VisibilityState,\n} from '@tanstack/react-table';\n\nimport DataTableViewOptions from '@/components/advanced/data-table/data-table-column-toggle.component';\nimport DataTablePagination from '@/components/advanced/data-table/data-table-pagination.component';\nimport { Button } from '@/components/shadcn-ui/button';\nimport {\n Table,\n TableBody,\n TableCell,\n TableHead,\n TableHeader,\n TableRow,\n} from '@/components/shadcn-ui/table';\n\nexport type ColumnDef = TSColumnDef;\nexport type RowContents = TSRow;\nexport type TableContents = TSTable;\nexport type SortDirection = TSSortDirection;\nexport type RowSelectionState = TSRowSelectionState;\n\ninterface DataTableProps {\n columns: ColumnDef[];\n data: TData[];\n enablePagination?: boolean;\n showPaginationControls?: boolean;\n showColumnVisibilityControls?: boolean;\n stickyHeader?: boolean;\n onRowClickHandler?: (row: RowContents, table: TableContents) => void;\n}\n\n/**\n * Feature-rich table component that infuses our basic shadcn-based Table component with features\n * from TanStack's React Table library\n */\nfunction DataTable({\n columns,\n data,\n enablePagination = false,\n showPaginationControls = false,\n showColumnVisibilityControls = false,\n stickyHeader = false,\n onRowClickHandler = () => {},\n}: DataTableProps) {\n const [sorting, setSorting] = useState([]);\n const [columnFilters, setColumnFilters] = useState([]);\n const [columnVisibility, setColumnVisibility] = useState({});\n const [rowSelection, setRowSelection] = useState({});\n\n const table = useReactTable({\n data,\n columns,\n getCoreRowModel: getCoreRowModel(),\n ...(enablePagination && { getPaginationRowModel: getPaginationRowModel() }),\n onSortingChange: setSorting,\n getSortedRowModel: getSortedRowModel(),\n onColumnFiltersChange: setColumnFilters,\n getFilteredRowModel: getFilteredRowModel(),\n onColumnVisibilityChange: setColumnVisibility,\n onRowSelectionChange: setRowSelection,\n state: {\n sorting,\n columnFilters,\n columnVisibility,\n rowSelection,\n },\n });\n\n return (\n
    \n {showColumnVisibilityControls && }\n \n \n {table.getHeaderGroups().map((headerGroup) => (\n \n {headerGroup.headers.map((header) => {\n return (\n \n {header.isPlaceholder\n ? undefined\n : flexRender(header.column.columnDef.header, header.getContext())}\n \n );\n })}\n \n ))}\n \n \n {table.getRowModel().rows?.length ? (\n table.getRowModel().rows.map((row) => (\n onRowClickHandler(row, table)}\n key={row.id}\n data-state={row.getIsSelected() && 'selected'}\n >\n {row.getVisibleCells().map((cell) => (\n \n {flexRender(cell.column.columnDef.cell, cell.getContext())}\n \n ))}\n \n ))\n ) : (\n \n \n No results.\n \n \n )}\n \n
    \n {enablePagination && (\n
    \n table.previousPage()}\n disabled={!table.getCanPreviousPage()}\n >\n Previous\n \n table.nextPage()}\n disabled={!table.getCanNextPage()}\n >\n Next\n \n
    \n )}\n {enablePagination && showPaginationControls && }\n
    \n );\n}\n\nexport default DataTable;\n","import {\n Table,\n TableBody,\n TableCell,\n TableHead,\n TableHeader,\n TableRow,\n} from '@/components/shadcn-ui/table';\nimport { Canon } from '@sillsdev/scripture';\nimport { deepEqual, LanguageStrings, ScriptureReference } from 'platform-bible-utils';\nimport { useMemo } from 'react';\nimport { InventoryItemOccurrence } from './inventory-utils';\n\n/** Props for the OccurrencesTable component */\ntype OccurrencesTableProps = {\n /** Data that contains scriptures references and snippets of scripture */\n occurrenceData: InventoryItemOccurrence[];\n /** Callback function that is executed when the scripture reference is changed */\n setScriptureReference: (scriptureReference: ScriptureReference) => void;\n /**\n * Object with all localized strings that the OccurrencesTable needs to work well across multiple\n * languages\n */\n localizedStrings: LanguageStrings;\n};\n\n/**\n * Table that shows occurrences of specified inventory item(s). The first column shows the related\n * scripture reference. The second column shows the snippet of scripture that contains the specified\n * inventory item\n */\nfunction OccurrencesTable({\n occurrenceData,\n setScriptureReference,\n localizedStrings,\n}: OccurrencesTableProps) {\n const referenceHeaderText =\n localizedStrings['%webView_inventory_occurrences_table_header_reference%'];\n const occurrenceHeaderText =\n localizedStrings['%webView_inventory_occurrences_table_header_occurrence%'];\n\n const occurrences: InventoryItemOccurrence[] = useMemo(() => {\n const uniqueOccurrences: InventoryItemOccurrence[] = [];\n\n occurrenceData.forEach((occurrence) => {\n if (!uniqueOccurrences.some((uniqueOccurrence) => deepEqual(uniqueOccurrence, occurrence))) {\n uniqueOccurrences.push(occurrence);\n }\n });\n\n return uniqueOccurrences;\n }, [occurrenceData]);\n\n return (\n \n \n \n {referenceHeaderText}\n {occurrenceHeaderText}\n \n \n \n {occurrences.length > 0 &&\n occurrences.map((occurrence) => (\n {\n setScriptureReference(occurrence.reference);\n }}\n >\n {`${Canon.bookNumberToEnglishName(occurrence.reference.bookNum)} ${occurrence.reference.chapterNum}:${occurrence.reference.verseNum}`}\n {occurrence.text}\n \n ))}\n \n
    \n );\n}\n\nexport default OccurrencesTable;\n","import React from 'react';\nimport * as CheckboxPrimitive from '@radix-ui/react-checkbox';\nimport { Check } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Checkbox = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n \n \n));\nCheckbox.displayName = CheckboxPrimitive.Root.displayName;\n\nexport default Checkbox;\n","import { Canon } from '@sillsdev/scripture';\nimport { ScriptureReference } from 'platform-bible-utils';\n\n/* #region Types */\n\n/**\n * Status of items that appear in inventories. 'approved' and 'unapproved' items are defined in the\n * project's `Settings.xml`. All other items are defined as 'unknown'\n */\nexport type Status = 'approved' | 'unapproved' | 'unknown';\n\n/** Occurrence of item in inventory. Primarily used by table that shows occurrences */\nexport type InventoryItemOccurrence = {\n /** Reference to scripture where the item appears */\n reference: ScriptureReference;\n /** Snippet of scripture that contains the occurrence */\n text: string;\n};\n\n/** Data structure that contains all information on an item that is shown in an inventory */\nexport type InventoryTableData = {\n /**\n * The item (e.g. a character in the characters inventory, a marker in the marker inventory) In\n * most cases the array will only have one element. In case of additional items (e.g. the\n * preceding marker in the markers check), the primary item should be stored in the first index.\n * To show additional items in the inventory, make sure to configure the `additionalItemsLabels`\n * prop for the Inventory component\n */\n items: string[];\n /** The number of times this item occurs in the selected scope */\n count: number;\n /** The status of this item (see documentation for `Status` type for more information) */\n status: Status;\n /** Occurrences of this item in the scripture text for the selected scope */\n occurrences: InventoryItemOccurrence[];\n};\n\n/* #endregion */\n\n/* #region Functions */\n\n/**\n * Splits USFM string into shorter line-like segments\n *\n * @param text A single (likely very large) USFM string\n * @returns An array containing the input text, split into shorter segments\n */\nexport const getLinesFromUSFM = (text: string) => {\n // Splits on (CR)LF, CR, \\v, \\c and \\id\n return text.split(/(?:\\r?\\n|\\r)|(?=(?:\\\\(?:v|c|id)))/g);\n};\n\n/**\n * Extracts chapter or verse number from USFM strings that start with a \\c or \\v marker\n *\n * @param text USFM string that is expected to start with \\c or \\v marker\n * @returns Chapter or verse number if one is found. Else returns 0.\n */\nexport const getNumberFromUSFM = (text: string): number | undefined => {\n // Captures all digits that follow \\v or \\c markers followed by whitespace located at the start of a string\n const regex = /^\\\\[vc]\\s+(\\d+)/;\n const match = text.match(regex);\n\n if (match) {\n return +match[1];\n }\n return undefined;\n};\n\n/**\n * Gets book ID from USFM string that starts with the \\id marker, and returns book number for it\n *\n * @param text USFM string that is expected to start with \\id marker\n * @returns Book number corresponding to the \\id marker in the input text. Returns 0 if no marker is\n * found or the marker is not valid\n */\nexport const getBookNumFromId = (text: string): number => {\n // Captures all digits that follow an \\id marker followed by whitespace located at the start of a string\n const match = text.match(/^\\\\id\\s+([A-Za-z]+)/);\n if (match) {\n return Canon.bookIdToNumber(match[1]);\n }\n return 0;\n};\n\n/**\n * Gets the status for an item, typically used in the Inventory component\n *\n * @param item The item for which the status is being requested\n * @param approvedItems Array of approved items, typically as defined in `Settings.xml`\n * @param unapprovedItems Array of unapproved items, typically as defined in `Settings.xml`\n * @returns The status for the specified item\n */\nexport const getStatusForItem = (\n item: string,\n approvedItems: string[],\n unapprovedItems: string[],\n): Status => {\n if (unapprovedItems.includes(item)) return 'unapproved';\n if (approvedItems.includes(item)) return 'approved';\n return 'unknown';\n};\n\n/* #endregion */\n","import React from 'react';\nimport * as TogglePrimitive from '@radix-ui/react-toggle';\nimport { cva, type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst toggleVariants = cva(\n 'pr-twp tw-inline-flex tw-items-center tw-justify-center tw-rounded-md tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-colors hover:tw-bg-muted hover:tw-text-muted-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50 data-[state=on]:tw-bg-accent data-[state=on]:tw-text-accent-foreground',\n {\n variants: {\n variant: {\n default: 'tw-bg-transparent',\n outline:\n 'tw-border tw-border-input tw-bg-transparent hover:tw-bg-accent hover:tw-text-accent-foreground',\n },\n size: {\n default: 'tw-h-10 tw-px-3',\n sm: 'tw-h-9 tw-px-2.5',\n lg: 'tw-h-11 tw-px-5',\n },\n },\n defaultVariants: {\n variant: 'default',\n size: 'default',\n },\n },\n);\n\nconst Toggle = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef & VariantProps\n>(({ className, variant, size, ...props }, ref) => (\n \n));\n\nToggle.displayName = TogglePrimitive.Root.displayName;\n\nexport { Toggle, toggleVariants };\n","import React from 'react';\nimport * as ToggleGroupPrimitive from '@radix-ui/react-toggle-group';\nimport { type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { toggleVariants } from '@/components/shadcn-ui/toggle';\n\nconst ToggleGroupContext = React.createContext>({\n size: 'default',\n variant: 'default',\n});\n\nconst ToggleGroup = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef &\n VariantProps\n>(({ className, variant, size, children, ...props }, ref) => (\n \n \n {children}\n \n \n));\n\nToggleGroup.displayName = ToggleGroupPrimitive.Root.displayName;\n\nconst ToggleGroupItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef &\n VariantProps\n>(({ className, children, variant, size, ...props }, ref) => {\n const context = React.useContext(ToggleGroupContext);\n\n return (\n \n {children}\n \n );\n});\n\nToggleGroupItem.displayName = ToggleGroupPrimitive.Item.displayName;\n\nexport { ToggleGroup, ToggleGroupItem };\n","import { ColumnDef, SortDirection } from '@/components/advanced/data-table/data-table.component';\nimport { Button } from '@/components/shadcn-ui/button';\nimport { ToggleGroup, ToggleGroupItem } from '@/components/shadcn-ui/toggle-group';\nimport {\n ArrowDownIcon,\n ArrowUpDownIcon,\n ArrowUpIcon,\n CircleCheckIcon,\n CircleHelpIcon,\n CircleXIcon,\n} from 'lucide-react';\nimport { ReactNode } from 'react';\nimport { InventoryTableData, Status } from './inventory-utils';\n\n/**\n * Gets an icon that indicates the current sorting direction based on the provided input\n *\n * @param sortDirection Sorting direction. Can be ascending ('asc'), descending ('desc') or false (\n * i.e. not sorted)\n * @returns The appropriate sorting icon for the provided sorting direction\n */\nconst getSortingIcon = (sortDirection: false | SortDirection): ReactNode => {\n if (sortDirection === 'asc') {\n return ;\n }\n if (sortDirection === 'desc') {\n return ;\n }\n return ;\n};\n\n/**\n * Function that creates the item column for inventories\n *\n * @param itemLabel Localized label for the item column (e.g. 'Character', 'Repeated Word', etc.)\n * @returns Column that shows the inventory items. Should be used with the DataTable component\n */\nexport const inventoryItemColumn = (itemLabel: string): ColumnDef => {\n return {\n accessorKey: 'item',\n accessorFn: (row: InventoryTableData) => row.items[0],\n header: ({ column }) => (\n \n ),\n };\n};\n\n/**\n * Function that creates the additional item columns for inventories\n *\n * @param additionalItemLabel Localized label for the additional item column (e.g. 'Preceding\n * Marker')\n * @param additionalItemIndex Index that locates the desired item in the items array of the\n * inventory\n * @returns Column that shows additional inventory items. Should be used with the DataTable\n * component\n */\nexport const inventoryAdditionalItemColumn = (\n additionalItemLabel: string,\n additionalItemIndex: number,\n): ColumnDef => {\n return {\n accessorKey: `item${additionalItemIndex}`,\n accessorFn: (row: InventoryTableData) => row.items[additionalItemIndex],\n header: ({ column }) => (\n \n ),\n };\n};\n\n/**\n * Function that creates the count column for inventories. Should be used with the DataTable\n * component.\n *\n * @param itemLabel Localized label for the count column\n * @returns Column that shows the number of occurrences of the related inventory items\n */\nexport const inventoryCountColumn = (countLabel: string): ColumnDef => {\n return {\n accessorKey: 'count',\n header: ({ column }) => (\n
    \n \n
    \n ),\n cell: ({ row }) =>
    {row.getValue('count')}
    ,\n };\n};\n\n/**\n * Function that updates project settings when status for item(s) changes\n *\n * @param changedItems Array of items for which the status is being updated\n * @param newStatus The status that the items are being given\n * @param approvedItems Array of currently approved items\n * @param onApprovedItemsChange Callback function that stores the updated list of approved items\n * @param unapprovedItems Array of currently unapproved items\n * @param onUnapprovedItemsChange Callback function that stores the updated list of unapproved items\n */\nconst statusChangeHandler = (\n changedItems: string[],\n newStatus: Status,\n approvedItems: string[],\n onApprovedItemsChange: (items: string[]) => void,\n unapprovedItems: string[],\n onUnapprovedItemsChange: (items: string[]) => void,\n) => {\n let newApprovedItems: string[] = [...approvedItems];\n changedItems.forEach((item) => {\n if (newStatus === 'approved') {\n if (!newApprovedItems.includes(item)) {\n newApprovedItems.push(item);\n }\n } else {\n newApprovedItems = newApprovedItems.filter((validItem) => validItem !== item);\n }\n });\n onApprovedItemsChange(newApprovedItems);\n\n let newUnapprovedItems: string[] = [...unapprovedItems];\n changedItems.forEach((item) => {\n if (newStatus === 'unapproved') {\n if (!newUnapprovedItems.includes(item)) {\n newUnapprovedItems.push(item);\n }\n } else {\n newUnapprovedItems = newUnapprovedItems.filter((unapprovedItem) => unapprovedItem !== item);\n }\n });\n onUnapprovedItemsChange(newUnapprovedItems);\n};\n\n/**\n * Function that creates the status column for inventories. Should be used with the DataTable\n * component.\n *\n * @param statusLabel Localized label for the status column\n * @param approvedItems Array of approved items, typically as defined in `Settings.xml`\n * @param onApprovedItemsChange Callback function that stores the updated list of approved items\n * @param unapprovedItems Array of unapproved items, typically as defined in `Settings.xml`\n * @param onUnapprovedItemsChange Callback function that stores the updated list of unapproved items\n * @returns Column that shows the status buttons for the related inventory item. The button for the\n * current status of the item is selected\n */\nexport const inventoryStatusColumn = (\n statusLabel: string,\n approvedItems: string[],\n onApprovedItemsChange: (items: string[]) => void,\n unapprovedItems: string[],\n onUnapprovedItemsChange: (items: string[]) => void,\n): ColumnDef => {\n return {\n accessorKey: 'status',\n header: ({ column }) => {\n return (\n
    \n \n
    \n );\n },\n cell: ({ row }) => {\n const status: Status = row.getValue('status');\n const item: string = row.getValue('item');\n return (\n \n \n statusChangeHandler(\n [item],\n 'approved',\n approvedItems,\n onApprovedItemsChange,\n unapprovedItems,\n onUnapprovedItemsChange,\n )\n }\n value=\"approved\"\n >\n \n \n \n statusChangeHandler(\n [item],\n 'unapproved',\n approvedItems,\n onApprovedItemsChange,\n unapprovedItems,\n onUnapprovedItemsChange,\n )\n }\n value=\"unapproved\"\n >\n \n \n \n statusChangeHandler(\n [item],\n 'unknown',\n approvedItems,\n onApprovedItemsChange,\n unapprovedItems,\n onUnapprovedItemsChange,\n )\n }\n value=\"unknown\"\n >\n \n \n \n );\n },\n };\n};\n","import DataTable, {\n ColumnDef,\n RowContents,\n RowSelectionState,\n TableContents,\n} from '@/components/advanced/data-table/data-table.component';\nimport OccurrencesTable from '@/components/advanced/inventory/occurrences-table.component';\nimport Checkbox from '@/components/shadcn-ui/checkbox';\nimport { Input } from '@/components/shadcn-ui/input';\nimport { Label } from '@/components/shadcn-ui/label';\nimport {\n Select,\n SelectContent,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\nimport {\n deepEqual,\n LocalizedStringValue,\n ScriptureReference,\n substring,\n} from 'platform-bible-utils';\nimport { useEffect, useMemo, useState } from 'react';\nimport {\n getBookNumFromId,\n getLinesFromUSFM,\n getNumberFromUSFM,\n getStatusForItem,\n InventoryItemOccurrence,\n InventoryTableData,\n Status,\n} from './inventory-utils';\nimport { inventoryAdditionalItemColumn } from './inventory-columns';\n\n/**\n * Object containing all keys used for localization in this component. If you're using this\n * component in an extension, you can pass it into the useLocalizedStrings hook to easily obtain the\n * localized strings and pass them into the localizedStrings prop of this component\n */\nexport const INVENTORY_STRING_KEYS = Object.freeze([\n '%webView_inventory_all%',\n '%webView_inventory_approved%',\n '%webView_inventory_unapproved%',\n '%webView_inventory_unknown%',\n '%webView_inventory_scope_currentBook%',\n '%webView_inventory_scope_chapter%',\n '%webView_inventory_scope_verse%',\n '%webView_inventory_filter_text%',\n '%webView_inventory_show_additional_items%',\n '%webView_inventory_occurrences_table_header_reference%',\n '%webView_inventory_occurrences_table_header_occurrence%',\n] as const);\n\nexport type InventoryLocalizedStrings = {\n [localizedInventoryKey in (typeof INVENTORY_STRING_KEYS)[number]]?: LocalizedStringValue;\n};\n\n/** Scope of scripture that the inventory can operate on */\nexport type Scope = 'book' | 'chapter' | 'verse';\n\n/** Status values that the status filter can select from */\ntype StatusFilter = Status | 'all';\n\n/** Text labels for the inventory columns and the control components of additional inventory items */\ntype AdditionalItemsLabels = {\n checkboxText?: string;\n tableHeaders?: string[];\n};\n\n/**\n * Filters data that is shown in the DataTable section of the Inventory\n *\n * @param itemData All inventory items and their related information\n * @param statusFilter Allows filtering by status (i.e. show all items, or only items that are\n * 'approved', 'unapproved' or 'unknown')\n * @param textFilter Allows filtering by text. All items that include the filter text will be\n * selected.\n * @returns Array of items and their related information that are matched by the specified filters\n */\nconst filterItemData = (\n itemData: InventoryTableData[],\n statusFilter: StatusFilter,\n textFilter: string,\n): InventoryTableData[] => {\n let filteredItemData: InventoryTableData[] = itemData;\n\n if (statusFilter !== 'all') {\n filteredItemData = filteredItemData.filter(\n (item) =>\n (statusFilter === 'approved' && item.status === 'approved') ||\n (statusFilter === 'unapproved' && item.status === 'unapproved') ||\n (statusFilter === 'unknown' && item.status === 'unknown'),\n );\n }\n\n if (textFilter !== '')\n filteredItemData = filteredItemData.filter((item) => item.items[0].includes(textFilter));\n\n return filteredItemData;\n};\n\n/**\n * Turns array of strings into array of inventory items, along with their count and status\n *\n * @param text The source scripture text that is searched for inventory items\n * @param scriptureRef The scripture reference that the application is currently set to\n * @param approvedItems Array of approved items, typically as defined in `Settings.xml`\n * @param unapprovedItems Array of unapproved items, typically as defined in `Settings.xml`\n * @param itemRegex Regular expression that describes what items this Inventory should extract from\n * the provided scripture text\n * @returns Array of inventory items, along with their count and status\n */\nconst createTableData = (\n text: string | undefined,\n scriptureRef: ScriptureReference,\n approvedItems: string[],\n unapprovedItems: string[],\n itemRegex: RegExp,\n): InventoryTableData[] => {\n if (!text) return [];\n\n const tableData: InventoryTableData[] = [];\n\n let currentBook: number | undefined = scriptureRef.bookNum;\n let currentChapter: number | undefined = scriptureRef.chapterNum;\n let currentVerse: number | undefined = scriptureRef.verseNum;\n\n const lines = getLinesFromUSFM(text);\n\n lines.forEach((line: string) => {\n if (line.startsWith('\\\\id')) {\n currentBook = getBookNumFromId(line);\n currentChapter = 0;\n currentVerse = 0;\n }\n if (line.startsWith('\\\\c')) {\n currentChapter = getNumberFromUSFM(line);\n currentVerse = 0;\n }\n if (line.startsWith('\\\\v')) {\n currentVerse = getNumberFromUSFM(line);\n if (currentChapter === 0) {\n currentChapter = scriptureRef.chapterNum;\n }\n }\n\n let match: RegExpExecArray | undefined = itemRegex.exec(line) ?? undefined;\n while (match) {\n const items: string[] = [];\n match.forEach((item) => items.push(item));\n const itemIndex = match.index;\n const existingItem = tableData.find((tableEntry) => deepEqual(tableEntry.items, items));\n const newReference: InventoryItemOccurrence = {\n reference: {\n bookNum: currentBook !== undefined ? currentBook : -1,\n chapterNum: currentChapter !== undefined ? currentChapter : -1,\n verseNum: currentVerse !== undefined ? currentVerse : -1,\n },\n text: substring(line, Math.max(0, itemIndex - 25), Math.min(itemIndex + 25, line.length)),\n };\n if (existingItem) {\n existingItem.count += 1;\n existingItem.occurrences.push(newReference);\n } else {\n const newItem: InventoryTableData = {\n items,\n count: 1,\n status: getStatusForItem(items[0], approvedItems, unapprovedItems),\n occurrences: [newReference],\n };\n tableData.push(newItem);\n }\n\n match = itemRegex.exec(line) ?? undefined;\n }\n });\n\n return tableData;\n};\n\n/**\n * Gets the localized value for the provided key\n *\n * @param strings Object containing localized string\n * @param key Key for a localized string\n * @returns The localized value for the provided key, if available. Returns the key if no localized\n * value is available\n */\nconst localizeString = (\n strings: InventoryLocalizedStrings,\n key: keyof InventoryLocalizedStrings,\n) => {\n return strings[key] ?? key;\n};\n\n/** Props for the Inventory component */\ntype InventoryProps = {\n /** The scripture reference that the application is currently set to */\n scriptureReference: ScriptureReference;\n /** Callback function that is executed when the scripture reference is changed */\n setScriptureReference: (scriptureReference: ScriptureReference) => void;\n /**\n * Object with all localized strings that the Inventory needs to work well across multiple\n * languages. When using this component with Platform.Bible, you can import\n * `INVENTORY_STRING_KEYS` from this library, pass it in to the Platform's localization hook, and\n * pass the localized keys that are returned by the hook into this prop.\n */\n localizedStrings: InventoryLocalizedStrings;\n /**\n * The logic that finds the desired items in the source text. This can either be a Regular\n * expression that captures one or multiple items (preferred), or a custom function that builds\n * and return an InventoryDataTable[] manually. Note: In case the logic captures more than one\n * item (i.e. InventoryTableData.items has a length greater than 1), you must provide text labels\n * for the related columns and control elements to show by setting the `additionalItemsLabels`\n * prop\n */\n extractItems:\n | RegExp\n | ((\n text: string | undefined,\n scriptureRef: ScriptureReference,\n approvedItems: string[],\n unapprovedItems: string[],\n ) => InventoryTableData[]);\n /**\n * Text labels for control elements and additional column headers in case your Inventory has more\n * than one item to show (e.g. The 'Preceding Marker' in the Markers Inventory)\n */\n additionalItemsLabels?: AdditionalItemsLabels;\n /** Array of approved items, typically as defined in `Settings.xml` */\n approvedItems: string[];\n /** Array of unapproved items, typically as defined in `Settings.xml` */\n unapprovedItems: string[];\n /** The source scripture text that is searched for in inventory items */\n text: string | undefined;\n /** Scope of scripture that the inventory will operate on */\n scope: Scope;\n /** Callback function that is executed when the scope is changed from the Inventory */\n onScopeChange: (scope: Scope) => void;\n /**\n * Column definitions for the Inventory data table. The most commonly used column definitions are\n * pre-configured for your convenience and can be imported (e.g. inventoryItemColumn,\n * inventoryAdditionalItemColumn inventoryCountColumn, and inventoryStatusColumn). If you need any\n * other columns you can add these yourself\n */\n columns: ColumnDef[];\n};\n\n/** Inventory component that is used to view and control the status of provided project settings */\nexport default function Inventory({\n scriptureReference,\n setScriptureReference,\n localizedStrings,\n extractItems,\n additionalItemsLabels,\n approvedItems,\n unapprovedItems,\n text,\n scope,\n onScopeChange,\n columns,\n}: InventoryProps) {\n const allItemsText = localizeString(localizedStrings, '%webView_inventory_all%');\n const approvedItemsText = localizeString(localizedStrings, '%webView_inventory_approved%');\n const unapprovedItemsText = localizeString(localizedStrings, '%webView_inventory_unapproved%');\n const unknownItemsText = localizeString(localizedStrings, '%webView_inventory_unknown%');\n const scopeBookText = localizeString(localizedStrings, '%webView_inventory_scope_currentBook%');\n const scopeChapterText = localizeString(localizedStrings, '%webView_inventory_scope_chapter%');\n const scopeVerseText = localizeString(localizedStrings, '%webView_inventory_scope_verse%');\n const filterText = localizeString(localizedStrings, '%webView_inventory_filter_text%');\n const showAdditionalItemsText = localizeString(\n localizedStrings,\n '%webView_inventory_show_additional_items%',\n );\n\n const [showAdditionalItems, setShowAdditionalItems] = useState(false);\n const [statusFilter, setStatusFilter] = useState('all');\n const [textFilter, setTextFilter] = useState('');\n const [selectedItem, setSelectedItem] = useState([]);\n\n const tableData: InventoryTableData[] = useMemo(() => {\n if (!text) return [];\n if (extractItems instanceof RegExp)\n return createTableData(\n text,\n scriptureReference,\n approvedItems,\n unapprovedItems,\n extractItems,\n );\n return extractItems(text, scriptureReference, approvedItems, unapprovedItems);\n }, [text, extractItems, scriptureReference, approvedItems, unapprovedItems]);\n\n const reducedTableData: InventoryTableData[] = useMemo(() => {\n if (showAdditionalItems) return tableData;\n\n const newTableData: InventoryTableData[] = [];\n\n tableData.forEach((tableEntry) => {\n const firstItem = tableEntry.items[0];\n\n const existingEntry = newTableData.find(\n (newTableEntry) => newTableEntry.items[0] === firstItem,\n );\n\n if (existingEntry) {\n existingEntry.count += tableEntry.count;\n existingEntry.occurrences = existingEntry.occurrences.concat(tableEntry.occurrences);\n } else {\n newTableData.push({\n items: [firstItem],\n count: tableEntry.count,\n occurrences: tableEntry.occurrences,\n status: tableEntry.status,\n });\n }\n });\n\n return newTableData;\n }, [showAdditionalItems, tableData]);\n\n const filteredTableData: InventoryTableData[] = useMemo(() => {\n return filterItemData(reducedTableData, statusFilter, textFilter);\n }, [reducedTableData, statusFilter, textFilter]);\n\n const allColumns: ColumnDef[] = useMemo(() => {\n if (!showAdditionalItems) return columns;\n\n const numberOfAdditionalItems = additionalItemsLabels?.tableHeaders?.length;\n if (!numberOfAdditionalItems) return columns;\n\n const additionalColumns: ColumnDef[] = [];\n\n for (let index = 0; index < numberOfAdditionalItems; index++) {\n additionalColumns.push(\n inventoryAdditionalItemColumn(\n additionalItemsLabels?.tableHeaders?.[index] || 'Additional Item',\n index + 1,\n ),\n );\n }\n\n return [...additionalColumns, ...columns];\n }, [additionalItemsLabels?.tableHeaders, columns, showAdditionalItems]);\n\n useEffect(() => {\n setSelectedItem([]);\n }, [filteredTableData]);\n\n const rowClickHandler = (\n row: RowContents,\n table: TableContents,\n ) => {\n table.setRowSelection(() => {\n const newSelection: RowSelectionState = {};\n newSelection[row.index] = true;\n return newSelection;\n });\n\n setSelectedItem(row.original.items);\n };\n\n const handleScopeChange = (value: string) => {\n if (value === 'book' || value === 'chapter' || value === 'verse') {\n onScopeChange(value);\n } else {\n throw new Error(`Invalid scope value: ${value}`);\n }\n };\n\n const handleStatusFilterChange = (value: string) => {\n if (value === 'all' || value === 'approved' || value === 'unapproved' || value === 'unknown') {\n setStatusFilter(value);\n } else {\n throw new Error(`Invalid status filter value: ${value}`);\n }\n };\n\n const occurrenceData: InventoryItemOccurrence[] = useMemo(() => {\n if (reducedTableData.length === 0 || selectedItem.length === 0) return [];\n const occurrence = reducedTableData.filter((tableEntry: InventoryTableData) => {\n return deepEqual(\n showAdditionalItems ? tableEntry.items : [tableEntry.items[0]],\n selectedItem,\n );\n });\n if (occurrence.length > 1) throw new Error('Selected item is not unique');\n return occurrence[0].occurrences;\n }, [selectedItem, showAdditionalItems, reducedTableData]);\n\n return (\n
    \n
    \n handleStatusFilterChange(value)}\n defaultValue={statusFilter}\n >\n \n \n \n \n {allItemsText}\n {approvedItemsText}\n {unapprovedItemsText}\n {unknownItemsText}\n \n \n \n {\n setTextFilter(event.target.value);\n }}\n />\n {additionalItemsLabels && (\n
    \n {\n setSelectedItem([]);\n setShowAdditionalItems(checked);\n }}\n />\n \n
    \n )}\n
    \n
    \n \n
    \n {occurrenceData.length > 0 && (\n
    \n \n
    \n )}\n
    \n );\n}\n","import { Input } from '@/components/shadcn-ui/input';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { useState } from 'react';\n\nexport type SearchBarProps = {\n /**\n * Callback fired to handle the search query when button pressed\n *\n * @param searchQuery\n */\n onSearch: (searchQuery: string) => void;\n\n /** Optional string that appears in the search bar without a search string */\n placeholder?: string;\n\n /** Optional boolean to set the input base to full width */\n isFullWidth?: boolean;\n};\n\nexport default function SearchBar({ onSearch, placeholder, isFullWidth }: SearchBarProps) {\n const [searchQuery, setSearchQuery] = useState('');\n\n const handleInputChange = (searchString: string) => {\n setSearchQuery(searchString);\n onSearch(searchString);\n };\n\n return (\n handleInputChange(e.target.value)}\n />\n );\n}\n","// adapted from: https://github.com/shadcn-ui/ui/discussions/752\n\n'use client';\n\nimport { TabsContentProps, TabsListProps, TabsTriggerProps } from '@/components/shadcn-ui/tabs';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport * as TabsPrimitive from '@radix-ui/react-tabs';\nimport React from 'react';\n\nexport type VerticalTabsProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport type LeftTabsTriggerProps = TabsTriggerProps & {\n value: string;\n ref?: React.Ref;\n};\n\nexport const VerticalTabs = React.forwardRef<\n React.ElementRef,\n VerticalTabsProps\n>(({ className, ...props }, ref) => (\n \n));\n\nVerticalTabs.displayName = TabsPrimitive.List.displayName;\n\nexport const VerticalTabsList = React.forwardRef<\n React.ElementRef,\n TabsListProps\n>(({ className, ...props }, ref) => (\n \n));\nVerticalTabsList.displayName = TabsPrimitive.List.displayName;\n\nexport const VerticalTabsTrigger = React.forwardRef<\n React.ElementRef,\n LeftTabsTriggerProps\n>(({ className, ...props }, ref) => (\n \n));\n\nexport const VerticalTabsContent = React.forwardRef<\n React.ElementRef,\n TabsContentProps\n>(({ className, ...props }, ref) => (\n \n));\nVerticalTabsContent.displayName = TabsPrimitive.Content.displayName;\n","import SearchBar from '@/components/basics/search-bar.component';\nimport {\n VerticalTabs,\n VerticalTabsContent,\n VerticalTabsList,\n VerticalTabsTrigger,\n} from '@/components/basics/tabs-vertical';\nimport { ReactNode } from 'react';\n\nexport type TabKeyValueContent = {\n key: string;\n value: string;\n content: ReactNode;\n};\n\nexport type TabNavigationContentSearchProps = {\n /** List of values and keys for each tab this component should provide */\n tabList: TabKeyValueContent[];\n\n /** Handler to run when the value of the search bar changes */\n onSearch: (searchQuery: string) => void;\n\n /** Optional placeholder for the search bar */\n searchPlaceholder?: string;\n\n /** Optional title to include in the header */\n headerTitle?: string;\n\n /** Optional flag to make the search bar appear full width */\n isSearchBarFullWidth?: boolean;\n\n /** Text direction ltr or rtl */\n direction?: 'ltr' | 'rtl';\n};\n\nexport default function TabNavigationContentSearch({\n tabList,\n onSearch,\n searchPlaceholder,\n headerTitle,\n isSearchBarFullWidth = false,\n direction = 'ltr',\n}: TabNavigationContentSearchProps) {\n return (\n
    \n
    \n {headerTitle ?

    {headerTitle}

    : ''}\n \n
    \n \n \n {tabList.map((tab) => (\n \n {tab.value}\n \n ))}\n \n {tabList.map((tab) => (\n \n {tab.content}\n \n ))}\n \n
    \n );\n}\n","import React from 'react';\nimport * as SeparatorPrimitive from '@radix-ui/react-separator';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Separator = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, orientation = 'horizontal', decorative = true, ...props }, ref) => (\n \n));\nSeparator.displayName = SeparatorPrimitive.Root.displayName;\n\nexport { Separator };\n","'use client';\n\nimport * as React from 'react';\nimport * as SheetPrimitive from '@radix-ui/react-dialog';\nimport { cva, type VariantProps } from 'class-variance-authority';\nimport { X } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Sheet = SheetPrimitive.Root;\n\nconst SheetTrigger = SheetPrimitive.Trigger;\n\nconst SheetClose = SheetPrimitive.Close;\n\nconst SheetPortal = SheetPrimitive.Portal;\n\nconst SheetOverlay = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSheetOverlay.displayName = SheetPrimitive.Overlay.displayName;\n\nconst sheetVariants = cva(\n 'pr-twp tw-fixed tw-z-50 tw-gap-4 tw-bg-background tw-p-6 tw-shadow-lg tw-transition tw-ease-in-out data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-duration-300 data-[state=open]:tw-duration-500',\n {\n variants: {\n side: {\n top: 'tw-inset-x-0 tw-top-0 tw-border-b data-[state=closed]:tw-slide-out-to-top data-[state=open]:tw-slide-in-from-top',\n bottom:\n 'tw-inset-x-0 tw-bottom-0 tw-border-t data-[state=closed]:tw-slide-out-to-bottom data-[state=open]:tw-slide-in-from-bottom',\n left: 'tw-inset-y-0 tw-left-0 tw-h-full tw-w-3/4 tw-border-r data-[state=closed]:tw-slide-out-to-left data-[state=open]:tw-slide-in-from-left sm:tw-max-w-sm',\n right:\n 'tw-inset-y-0 tw-right-0 tw-h-full tw-w-3/4 tw- tw-border-l data-[state=closed]:tw-slide-out-to-right data-[state=open]:tw-slide-in-from-right sm:tw-max-w-sm',\n },\n },\n defaultVariants: {\n side: 'right',\n },\n },\n);\n\ninterface SheetContentProps\n extends React.ComponentPropsWithoutRef,\n VariantProps {}\n\nconst SheetContent = React.forwardRef<\n React.ElementRef,\n SheetContentProps\n>(({ side = 'right', className, children, ...props }, ref) => (\n \n \n \n {children}\n \n \n Close\n \n \n \n));\nSheetContent.displayName = SheetPrimitive.Content.displayName;\n\nfunction SheetHeader({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nSheetHeader.displayName = 'SheetHeader';\n\nfunction SheetFooter({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nSheetFooter.displayName = 'SheetFooter';\n\nconst SheetTitle = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSheetTitle.displayName = SheetPrimitive.Title.displayName;\n\nconst SheetDescription = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSheetDescription.displayName = SheetPrimitive.Description.displayName;\n\nexport {\n Sheet,\n SheetPortal,\n SheetOverlay,\n SheetTrigger,\n SheetClose,\n SheetContent,\n SheetHeader,\n SheetFooter,\n SheetTitle,\n SheetDescription,\n};\n","import React from 'react';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nfunction Skeleton({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\n\nexport { Skeleton };\n","import React from 'react';\nimport * as TooltipPrimitive from '@radix-ui/react-tooltip';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst TooltipProvider = TooltipPrimitive.Provider;\n\nconst Tooltip = TooltipPrimitive.Root;\n\nconst TooltipTrigger = TooltipPrimitive.Trigger;\n\nconst TooltipContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, sideOffset = 4, ...props }, ref) => (\n \n));\nTooltipContent.displayName = TooltipPrimitive.Content.displayName;\n\nexport { Tooltip, TooltipTrigger, TooltipContent, TooltipProvider };\n","import * as React from 'react';\n\nconst MOBILE_BREAKPOINT = 768;\n\nexport default function useIsMobile() {\n const [isMobile, setIsMobile] = React.useState(undefined);\n\n React.useEffect(() => {\n const mql = window.matchMedia(`(max-width: ${MOBILE_BREAKPOINT - 1}px)`);\n const onChange = () => {\n setIsMobile(window.innerWidth < MOBILE_BREAKPOINT);\n };\n mql.addEventListener('change', onChange);\n setIsMobile(window.innerWidth < MOBILE_BREAKPOINT);\n return () => mql.removeEventListener('change', onChange);\n }, []);\n\n return !!isMobile;\n}\n","import React from 'react';\nimport { Slot } from '@radix-ui/react-slot';\nimport { VariantProps, cva } from 'class-variance-authority';\nimport { PanelLeft } from 'lucide-react';\n\nimport { Button } from '@/components/shadcn-ui/button';\nimport { Input } from '@/components/shadcn-ui/input';\nimport { Separator } from '@/components/shadcn-ui/separator';\nimport { Sheet, SheetContent } from '@/components/shadcn-ui/sheet';\nimport { Skeleton } from '@/components/shadcn-ui/skeleton';\nimport {\n Tooltip,\n TooltipContent,\n TooltipProvider,\n TooltipTrigger,\n} from '@/components/shadcn-ui/tooltip';\nimport useIsMobile from '@/components/hooks/use-mobile';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst SIDEBAR_COOKIE_NAME = 'sidebar:state';\nconst SIDEBAR_COOKIE_MAX_AGE = 60 * 60 * 24 * 7;\nconst SIDEBAR_WIDTH = '16rem';\nconst SIDEBAR_WIDTH_MOBILE = '18rem';\nconst SIDEBAR_WIDTH_ICON = '3rem';\nconst SIDEBAR_KEYBOARD_SHORTCUT = 'b';\n\ntype SidebarContextProps = {\n state: 'expanded' | 'collapsed';\n open: boolean;\n setOpen: (open: boolean) => void;\n openMobile: boolean;\n setOpenMobile: (open: boolean) => void;\n isMobile: boolean;\n toggleSidebar: () => void;\n};\n\nconst SidebarContext = React.createContext(undefined);\n\nfunction useSidebar() {\n const context = React.useContext(SidebarContext);\n if (!context) {\n throw new Error('useSidebar must be used within a SidebarProvider.');\n }\n\n return context;\n}\n\nconst SidebarProvider = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & {\n defaultOpen?: boolean;\n open?: boolean;\n onOpenChange?: (open: boolean) => void;\n }\n>(\n (\n {\n defaultOpen = true,\n open: openProp,\n onOpenChange: setOpenProp,\n className,\n style,\n children,\n ...props\n },\n ref,\n ) => {\n const isMobile = useIsMobile();\n const [openMobile, setOpenMobile] = React.useState(false);\n\n // This is the internal state of the sidebar.\n // We use openProp and setOpenProp for control from outside the component.\n const [_open, _setOpen] = React.useState(defaultOpen);\n const isOpen = openProp ?? _open;\n const setOpen = React.useCallback(\n (value: boolean | ((value: boolean) => boolean)) => {\n const openState = typeof value === 'function' ? value(isOpen) : value;\n if (setOpenProp) {\n setOpenProp(openState);\n } else {\n _setOpen(openState);\n }\n\n // This sets the cookie to keep the sidebar state.\n document.cookie = `${SIDEBAR_COOKIE_NAME}=${openState}; path=/; max-age=${SIDEBAR_COOKIE_MAX_AGE}`;\n },\n [setOpenProp, isOpen],\n );\n\n // Helper to toggle the sidebar.\n const toggleSidebar = React.useCallback(() => {\n return isMobile ? setOpenMobile((open) => !open) : setOpen((open) => !open);\n }, [isMobile, setOpen, setOpenMobile]);\n\n // Adds a keyboard shortcut to toggle the sidebar.\n React.useEffect(() => {\n const handleKeyDown = (event: KeyboardEvent) => {\n if (event.key === SIDEBAR_KEYBOARD_SHORTCUT && (event.metaKey || event.ctrlKey)) {\n event.preventDefault();\n toggleSidebar();\n }\n };\n\n window.addEventListener('keydown', handleKeyDown);\n return () => window.removeEventListener('keydown', handleKeyDown);\n }, [toggleSidebar]);\n\n // We add a state so that we can do data-state=\"expanded\" or \"collapsed\".\n // This makes it easier to style the sidebar with Tailwind classes.\n const state = isOpen ? 'expanded' : 'collapsed';\n\n const contextValue = React.useMemo(\n () => ({\n state,\n open: isOpen,\n setOpen,\n isMobile,\n openMobile,\n setOpenMobile,\n toggleSidebar,\n }),\n [state, isOpen, setOpen, isMobile, openMobile, setOpenMobile, toggleSidebar],\n );\n\n return (\n \n \n \n {children}\n
    \n \n \n );\n },\n);\nSidebarProvider.displayName = 'SidebarProvider';\n\nconst Sidebar = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & {\n side?: 'left' | 'right';\n variant?: 'sidebar' | 'floating' | 'inset';\n collapsible?: 'offcanvas' | 'icon' | 'none';\n }\n>(\n (\n {\n side = 'left',\n variant = 'sidebar',\n collapsible = 'offcanvas',\n className,\n children,\n ...props\n },\n ref,\n ) => {\n const { isMobile, state, openMobile, setOpenMobile } = useSidebar();\n\n if (collapsible === 'none') {\n return (\n \n {children}\n
    \n );\n }\n\n if (isMobile) {\n return (\n \n button]:tw-hidden\"\n style={\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n {\n '--sidebar-width': SIDEBAR_WIDTH_MOBILE,\n } as React.CSSProperties\n }\n side={side}\n >\n
    {children}
    \n \n
    \n );\n }\n\n return (\n \n {/* This is what handles the sidebar gap on desktop */}\n \n \n \n {children}\n
    \n
    \n
    \n );\n },\n);\nSidebar.displayName = 'Sidebar';\n\nconst SidebarTrigger = React.forwardRef<\n React.ElementRef,\n React.ComponentProps\n>(({ className, onClick, ...props }, ref) => {\n const { toggleSidebar } = useSidebar();\n\n return (\n {\n onClick?.(event);\n toggleSidebar();\n }}\n {...props}\n >\n \n Toggle Sidebar\n \n );\n});\nSidebarTrigger.displayName = 'SidebarTrigger';\n\nconst SidebarRail = React.forwardRef>(\n ({ className, ...props }, ref) => {\n const { toggleSidebar } = useSidebar();\n\n return (\n \n );\n },\n);\nSidebarRail.displayName = 'SidebarRail';\n\nconst SidebarInset = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarInset.displayName = 'SidebarInset';\n\nconst SidebarInput = React.forwardRef<\n React.ElementRef,\n React.ComponentProps\n>(({ className, ...props }, ref) => {\n return (\n \n );\n});\nSidebarInput.displayName = 'SidebarInput';\n\nconst SidebarHeader = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarHeader.displayName = 'SidebarHeader';\n\nconst SidebarFooter = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarFooter.displayName = 'SidebarFooter';\n\nconst SidebarSeparator = React.forwardRef<\n React.ElementRef,\n React.ComponentProps\n>(({ className, ...props }, ref) => {\n return (\n \n );\n});\nSidebarSeparator.displayName = 'SidebarSeparator';\n\nconst SidebarContent = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarContent.displayName = 'SidebarContent';\n\nconst SidebarGroup = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarGroup.displayName = 'SidebarGroup';\n\nconst SidebarGroupLabel = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & { asChild?: boolean }\n>(({ className, asChild = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'div';\n\n return (\n svg]:tw-size-4 [&>svg]:tw-shrink-0',\n 'group-data-[collapsible=icon]:tw--mt-8 group-data-[collapsible=icon]:tw-opacity-0',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarGroupLabel.displayName = 'SidebarGroupLabel';\n\nconst SidebarGroupAction = React.forwardRef<\n HTMLButtonElement,\n React.ComponentProps<'button'> & { asChild?: boolean }\n>(({ className, asChild = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'button';\n\n return (\n svg]:tw-size-4 [&>svg]:tw-shrink-0',\n // Increases the hit area of the button on mobile.\n 'after:tw-absolute after:tw--inset-2 after:md:tw-hidden',\n 'group-data-[collapsible=icon]:tw-hidden',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarGroupAction.displayName = 'SidebarGroupAction';\n\nconst SidebarGroupContent = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarGroupContent.displayName = 'SidebarGroupContent';\n\nconst SidebarMenu = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenu.displayName = 'SidebarMenu';\n\nconst SidebarMenuItem = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenuItem.displayName = 'SidebarMenuItem';\n\nconst sidebarMenuButtonVariants = cva(\n 'tw-peer/menu-button tw-flex tw-w-full tw-items-center tw-gap-2 tw-overflow-hidden tw-rounded-md tw-p-2 tw-text-left tw-text-sm tw-outline-none tw-ring-sidebar-ring tw-transition-[width,height,padding] hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground focus-visible:tw-ring-2 active:tw-bg-sidebar-accent active:tw-text-sidebar-accent-foreground disabled:tw-pointer-events-none disabled:tw-opacity-50 tw-group-has-[[data-sidebar=menu-action]]/menu-item:pr-8 aria-disabled:tw-pointer-events-none aria-disabled:tw-opacity-50 data-[active=true]:tw-bg-sidebar-accent data-[active=true]:tw-font-medium data-[active=true]:tw-text-sidebar-accent-foreground data-[state=open]:hover:tw-bg-sidebar-accent data-[state=open]:hover:tw-text-sidebar-accent-foreground group-data-[collapsible=icon]:tw-!size-8 group-data-[collapsible=icon]:tw-!p-2 [&>span:last-child]:tw-truncate [&>svg]:tw-size-4 [&>svg]:tw-shrink-0',\n {\n variants: {\n variant: {\n default: 'hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground',\n outline:\n 'tw-bg-background tw-shadow-[0_0_0_1px_hsl(var(--sidebar-border))] hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground hover:tw-shadow-[0_0_0_1px_hsl(var(--sidebar-accent))]',\n },\n size: {\n default: 'tw-h-8 tw-text-sm',\n sm: 'tw-h-7 tw-text-xs',\n lg: 'tw-h-12 tw-text-sm group-data-[collapsible=icon]:tw-!p-0',\n },\n },\n defaultVariants: {\n variant: 'default',\n size: 'default',\n },\n },\n);\n\nconst SidebarMenuButton = React.forwardRef<\n HTMLButtonElement,\n React.ComponentProps<'button'> & {\n asChild?: boolean;\n isActive?: boolean;\n tooltip?: string | React.ComponentProps;\n } & VariantProps\n>(\n (\n {\n asChild = false,\n isActive = false,\n variant = 'default',\n size = 'default',\n tooltip,\n className,\n ...props\n },\n ref,\n ) => {\n const Comp = asChild ? Slot : 'button';\n const { isMobile, state } = useSidebar();\n\n const button = (\n \n );\n\n if (!tooltip) {\n return button;\n }\n\n if (typeof tooltip === 'string') {\n // eslint-disable-next-line no-param-reassign\n tooltip = {\n children: tooltip,\n };\n }\n\n return (\n \n {button}\n \n );\n },\n);\nSidebarMenuButton.displayName = 'SidebarMenuButton';\n\nconst SidebarMenuAction = React.forwardRef<\n HTMLButtonElement,\n React.ComponentProps<'button'> & {\n asChild?: boolean;\n showOnHover?: boolean;\n }\n>(({ className, asChild = false, showOnHover = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'button';\n\n return (\n svg]:tw-size-4 [&>svg]:tw-shrink-0',\n // Increases the hit area of the button on mobile.\n 'after:tw-absolute after:tw--inset-2 after:md:tw-hidden',\n 'tw-peer-data-[size=sm]/menu-button:top-1',\n 'tw-peer-data-[size=default]/menu-button:top-1.5',\n 'tw-peer-data-[size=lg]/menu-button:top-2.5',\n 'group-data-[collapsible=icon]:tw-hidden',\n showOnHover &&\n 'tw-group-focus-within/menu-item:opacity-100 tw-group-hover/menu-item:opacity-100 tw-peer-data-[active=true]/menu-button:text-sidebar-accent-foreground data-[state=open]:tw-opacity-100 md:tw-opacity-0',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarMenuAction.displayName = 'SidebarMenuAction';\n\nconst SidebarMenuBadge = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenuBadge.displayName = 'SidebarMenuBadge';\n\nconst SidebarMenuSkeleton = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & {\n showIcon?: boolean;\n }\n>(({ className, showIcon = false, ...props }, ref) => {\n // Random width between 50 to 90%.\n const width = React.useMemo(() => {\n return `${Math.floor(Math.random() * 40) + 50}%`;\n }, []);\n\n return (\n \n {showIcon && (\n \n )}\n \n
    \n );\n});\nSidebarMenuSkeleton.displayName = 'SidebarMenuSkeleton';\n\nconst SidebarMenuSub = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenuSub.displayName = 'SidebarMenuSub';\n\nconst SidebarMenuSubItem = React.forwardRef>(\n ({ ...props }, ref) =>
  • ,\n);\nSidebarMenuSubItem.displayName = 'SidebarMenuSubItem';\n\nconst SidebarMenuSubButton = React.forwardRef<\n HTMLAnchorElement,\n React.ComponentProps<'a'> & {\n asChild?: boolean;\n size?: 'sm' | 'md';\n isActive?: boolean;\n }\n>(({ asChild = false, size = 'md', isActive, className, ...props }, ref) => {\n const Comp = asChild ? Slot : 'a';\n\n return (\n span:last-child]:tw-truncate [&>svg]:tw-size-4 [&>svg]:tw-shrink-0 [&>svg]:tw-text-sidebar-accent-foreground',\n 'data-[active=true]:tw-bg-sidebar-accent data-[active=true]:tw-text-sidebar-accent-foreground',\n size === 'sm' && 'tw-text-xs',\n size === 'md' && 'tw-text-sm',\n 'group-data-[collapsible=icon]:tw-hidden',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarMenuSubButton.displayName = 'SidebarMenuSubButton';\n\nexport {\n Sidebar,\n SidebarContent,\n SidebarFooter,\n SidebarGroup,\n SidebarGroupAction,\n SidebarGroupContent,\n SidebarGroupLabel,\n SidebarHeader,\n SidebarInput,\n SidebarInset,\n SidebarMenu,\n SidebarMenuAction,\n SidebarMenuBadge,\n SidebarMenuButton,\n SidebarMenuItem,\n SidebarMenuSkeleton,\n SidebarMenuSub,\n SidebarMenuSubButton,\n SidebarMenuSubItem,\n SidebarProvider,\n SidebarRail,\n SidebarSeparator,\n SidebarTrigger,\n useSidebar,\n};\n","import ComboBox, { ComboBoxOption } from '@/components/basics/combo-box.component';\nimport {\n Sidebar,\n SidebarContent,\n SidebarGroup,\n SidebarGroupLabel,\n SidebarGroupContent,\n SidebarMenu,\n SidebarMenuItem,\n SidebarMenuButton,\n} from '@/components/shadcn-ui/sidebar';\nimport { useCallback } from 'react';\n\nexport type SelectedSettingsSidebarItem = {\n label: string;\n projectId?: string;\n};\n\nexport type ProjectOptions = { projectId: string; projectName: string };\n\nexport type SettingsSidebarProps = {\n /** Optional id for testing */\n id?: string;\n\n /** Extension labels from contribution */\n extensionLabels: string[];\n\n /** Project names and ids */\n projectOptions: ProjectOptions[];\n\n /** Handler for selecting a sidebar item */\n handleSelectSidebarItem: (key: string, projectId?: string) => void;\n\n /** The current selected value in the sidebar */\n selectedSidebarItem: SelectedSettingsSidebarItem | undefined;\n};\n\nexport default function SettingsSidebar({\n id,\n extensionLabels,\n projectOptions,\n handleSelectSidebarItem,\n selectedSidebarItem,\n}: SettingsSidebarProps) {\n const handleSelectItem = useCallback(\n (item: string, projectId?: string) => {\n handleSelectSidebarItem(item, projectId);\n },\n [handleSelectSidebarItem],\n );\n\n const getProjectNameFromProjectId = useCallback(\n (projectId: string) => {\n const project = projectOptions.find((option) => option.projectId === projectId);\n return project ? project.projectName : projectId;\n },\n [projectOptions],\n );\n\n return (\n \n \n \n Extensions\n \n \n {extensionLabels.map((label) => (\n \n handleSelectItem(label)}\n isActive={\n !selectedSidebarItem?.projectId && label === selectedSidebarItem?.label\n }\n >\n {label}\n \n \n ))}\n \n \n \n \n Projects\n \n option.projectId)}\n getOptionLabel={(projectId: ComboBoxOption) => {\n // This function expects a ComboBoxOption, but we know it is a string\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n return getProjectNameFromProjectId(projectId as string);\n }}\n buttonPlaceholder=\"Type or select project\"\n onChange={(projectId: string) => {\n const selectedProjectName = getProjectNameFromProjectId(projectId);\n handleSelectItem(selectedProjectName, projectId);\n }}\n value={selectedSidebarItem?.projectId ?? undefined}\n />\n \n \n \n \n );\n}\n","import { SidebarInset, SidebarProvider } from '@/components/shadcn-ui/sidebar';\nimport { PropsWithChildren } from 'react';\nimport SettingsSidebar, { SettingsSidebarProps } from './settings-sidebar.component';\n\nexport type SettingsSidebarContentSearchProps = SettingsSidebarProps &\n PropsWithChildren & {\n /** Optional id for testing */\n id?: string;\n\n /** Text direction ltr or rtl */\n direction?: 'ltr' | 'rtl';\n };\n\nexport default function SettingsSidebarContentSearch({\n id,\n direction = 'ltr',\n extensionLabels,\n projectOptions,\n children,\n handleSelectSidebarItem,\n selectedSidebarItem,\n}: SettingsSidebarContentSearchProps) {\n return (\n \n \n {children}\n \n );\n}\n","import { Button } from '@/components/shadcn-ui/button';\nimport {\n Select,\n SelectContent,\n SelectGroup,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\nimport {\n Table,\n TableBody,\n TableCell,\n TableHead,\n TableHeader,\n TableRow,\n} from '@/components/shadcn-ui/table';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Canon } from '@sillsdev/scripture';\nimport {\n Cell,\n ColumnDef,\n flexRender,\n getCoreRowModel,\n getExpandedRowModel,\n getGroupedRowModel,\n getSortedRowModel,\n GroupingState,\n Row,\n RowSelectionState,\n SortingState,\n useReactTable,\n} from '@tanstack/react-table';\nimport '@/components/advanced/scripture-results-viewer/scripture-results-viewer.component.css';\nimport {\n compareScrRefs,\n formatScrRef,\n ScriptureSelection,\n scrRefToBBBCCCVVV,\n} from 'platform-bible-utils';\nimport { MouseEvent, useEffect, useMemo, useState } from 'react';\nimport { ChevronDown, ChevronLeft, ChevronRight } from 'lucide-react';\n\n/**\n * Information (e.g., a checking error or some other type of \"transient\" annotation) about something\n * noteworthy at a specific place in an instance of the Scriptures.\n */\nexport type ScriptureItemDetail = ScriptureSelection & {\n /**\n * Text of the error, note, etc. In the future, we might want to support something more than just\n * text so that a JSX element could be provided with a link or some other controls related to the\n * issue being reported.\n */\n detail: string;\n};\n\n/**\n * A uniquely identifiable source of results that can be displayed in the ScriptureResultsViewer.\n * Generally, the source will be a particular Scripture check, but there may be other types of\n * sources.\n */\nexport type ResultsSource = {\n /**\n * Uniquely identifies the source.\n *\n * @type {string}\n */\n id: string;\n\n /**\n * Name (potentially localized) of the source, suitable for display in the UI.\n *\n * @type {string}\n */\n displayName: string;\n};\n\nexport type ScriptureSrcItemDetail = ScriptureItemDetail & {\n /** Source/type of detail. Can be used for grouping. */\n source: ResultsSource;\n};\n\n/**\n * Represents a set of results keyed by Scripture reference. Generally, the source will be a\n * particular Scripture check, but this type also allows for other types of uniquely identifiable\n * sources.\n */\nexport type ResultsSet = {\n /**\n * The backing source associated with this set of results.\n *\n * @type {ResultsSource}\n */\n source: ResultsSource;\n\n /**\n * Array of Scripture item details (messages keyed by Scripture reference).\n *\n * @type {ScriptureItemDetail[]}\n */\n data: ScriptureItemDetail[];\n};\n\nconst scrBookColId = 'scrBook';\nconst scrRefColId = 'scrRef';\nconst typeColId = 'source';\nconst detailsColId = 'details';\n\nconst defaultScrRefColumnName = 'Scripture Reference';\nconst defaultScrBookGroupName = 'Scripture Book';\nconst defaultTypeColumnName = 'Type';\nconst defaultDetailsColumnName = 'Details';\n\nexport type ScriptureResultsViewerColumnInfo = {\n /** Optional header to display for the Reference column. Default value: 'Scripture Reference'. */\n scriptureReferenceColumnName?: string;\n\n /** Optional text to display to refer to the Scripture book group. Default value: 'Scripture Book'. */\n scriptureBookGroupName?: string;\n\n /** Optional header to display for the Type column. Default value: 'Type'. */\n typeColumnName?: string;\n\n /** Optional header to display for the Details column. Default value: 'Details' */\n detailsColumnName?: string;\n};\n\nexport type ScriptureResultsViewerProps = ScriptureResultsViewerColumnInfo & {\n /** Groups of ScriptureItemDetail objects from particular sources (e.g., Scripture checks) */\n sources: ResultsSet[];\n\n /** Flag indicating whether to display column headers. Default is false. */\n showColumnHeaders?: boolean;\n\n /** Flag indicating whether to display source column. Default is false. */\n showSourceColumn?: boolean;\n\n /** Callback function to notify when a row is selected */\n onRowSelected?: (selectedRow: ScriptureSrcItemDetail | undefined) => void;\n\n /** Text direction ltr or rtl */\n direction?: 'ltr' | 'rtl';\n};\n\nfunction getColumns(\n colInfo?: ScriptureResultsViewerColumnInfo,\n showSourceColumn?: boolean,\n): ColumnDef[] {\n const showSrcCol = showSourceColumn ?? false;\n return [\n {\n accessorFn: (row) =>\n `${Canon.bookNumberToId(row.start.bookNum)} ${row.start.chapterNum}:${row.start.verseNum}`,\n id: scrBookColId,\n header: colInfo?.scriptureReferenceColumnName ?? defaultScrRefColumnName,\n cell: (info) => {\n const row = info.row.original;\n if (info.row.getIsGrouped()) {\n return Canon.bookNumberToEnglishName(row.start.bookNum);\n }\n return info.row.groupingColumnId === scrBookColId ? formatScrRef(row.start) : undefined;\n },\n getGroupingValue: (row) => row.start.bookNum,\n sortingFn: (a, b) => {\n return compareScrRefs(a.original.start, b.original.start);\n },\n enableGrouping: true,\n },\n {\n accessorFn: (row) => formatScrRef(row.start),\n id: scrRefColId,\n header: undefined,\n cell: (info) => {\n const row = info.row.original;\n return info.row.getIsGrouped() ? undefined : formatScrRef(row.start);\n },\n sortingFn: (a, b) => {\n return compareScrRefs(a.original.start, b.original.start);\n },\n enableGrouping: false,\n },\n {\n accessorFn: (row) => row.source.displayName,\n id: typeColId,\n header: showSrcCol ? (colInfo?.typeColumnName ?? defaultTypeColumnName) : undefined,\n cell: (info) => (showSrcCol || info.row.getIsGrouped() ? info.getValue() : undefined),\n getGroupingValue: (row) => row.source.id,\n sortingFn: (a, b) =>\n a.original.source.displayName.localeCompare(b.original.source.displayName),\n enableGrouping: true,\n },\n {\n accessorFn: (row) => row.detail,\n id: detailsColId,\n header: colInfo?.detailsColumnName ?? defaultDetailsColumnName,\n cell: (info) => info.getValue(),\n enableGrouping: false,\n },\n ];\n}\n\nconst toRefOrRange = (scriptureSelection: ScriptureSelection) => {\n if (!('offset' in scriptureSelection.start))\n throw new Error('No offset available in range start');\n if (scriptureSelection.end && !('offset' in scriptureSelection.end))\n throw new Error('No offset available in range end');\n const { offset: offsetStart } = scriptureSelection.start;\n let offsetEnd: number = 0;\n if (scriptureSelection.end) ({ offset: offsetEnd } = scriptureSelection.end);\n if (\n !scriptureSelection.end ||\n compareScrRefs(scriptureSelection.start, scriptureSelection.end) === 0\n )\n return `${scrRefToBBBCCCVVV(scriptureSelection.start)}+${offsetStart}`;\n return `${scrRefToBBBCCCVVV(scriptureSelection.start)}+${offsetStart}-${scrRefToBBBCCCVVV(scriptureSelection.end)}+${offsetEnd}`;\n};\n\nconst getRowKey = (row: ScriptureSrcItemDetail) =>\n `${toRefOrRange({ start: row.start, end: row.end })} ${row.source.displayName} ${row.detail}`;\n\n/**\n * Component to display a combined list of detailed items from one or more sources, where the items\n * are keyed primarily by Scripture reference. This is particularly useful for displaying a list of\n * results from Scripture checks, but more generally could be used to display any \"results\" from any\n * source(s). The component allows for grouping by Scripture book, source, or both. By default, it\n * displays somewhat \"tree-like\" which allows it to be more horizontally compact and intuitive. But\n * it also has the option of displaying as a traditional table with column headings (with or without\n * the source column showing).\n */\nexport default function ScriptureResultsViewer({\n sources,\n showColumnHeaders = false,\n showSourceColumn = false,\n scriptureReferenceColumnName,\n scriptureBookGroupName,\n typeColumnName,\n detailsColumnName,\n onRowSelected,\n direction = 'ltr',\n}: ScriptureResultsViewerProps) {\n const [grouping, setGrouping] = useState([]);\n const [sorting, setSorting] = useState([{ id: scrBookColId, desc: false }]);\n const [rowSelection, setRowSelection] = useState({});\n\n const scriptureResults = useMemo(\n () =>\n sources.flatMap((source) => {\n return source.data.map((item) => ({\n ...item,\n source: source.source,\n }));\n }),\n [sources],\n );\n\n const columns = useMemo(\n () =>\n getColumns(\n {\n scriptureReferenceColumnName,\n typeColumnName,\n detailsColumnName,\n },\n showSourceColumn,\n ),\n [scriptureReferenceColumnName, typeColumnName, detailsColumnName, showSourceColumn],\n );\n\n useEffect(() => {\n // Ensure sorting is applied correctly when grouped by type\n if (grouping.includes(typeColId)) {\n setSorting([\n { id: typeColId, desc: false },\n { id: scrBookColId, desc: false },\n ]);\n } else {\n setSorting([{ id: scrBookColId, desc: false }]);\n }\n }, [grouping]);\n\n const table = useReactTable({\n data: scriptureResults,\n columns,\n state: {\n grouping,\n sorting,\n rowSelection,\n },\n onGroupingChange: setGrouping,\n onSortingChange: setSorting,\n onRowSelectionChange: setRowSelection,\n getExpandedRowModel: getExpandedRowModel(),\n getGroupedRowModel: getGroupedRowModel(),\n getCoreRowModel: getCoreRowModel(),\n getSortedRowModel: getSortedRowModel(),\n getRowId: getRowKey,\n autoResetExpanded: false,\n enableMultiRowSelection: false,\n enableSubRowSelection: false,\n });\n\n useEffect(() => {\n if (onRowSelected) {\n const selectedRows = table.getSelectedRowModel().rowsById;\n const keys = Object.keys(selectedRows);\n if (keys.length === 1) {\n const selectedRow = scriptureResults.find((row) => getRowKey(row) === keys[0]) || undefined;\n if (selectedRow) onRowSelected(selectedRow);\n }\n }\n }, [rowSelection, scriptureResults, onRowSelected, table]);\n\n // Define possible grouping options\n const scrBookGroupName = scriptureBookGroupName ?? defaultScrBookGroupName;\n const typeGroupName = typeColumnName ?? defaultTypeColumnName;\n\n const groupingOptions = [\n { label: 'No Grouping', value: [] },\n { label: `Group by ${scrBookGroupName}`, value: [scrBookColId] },\n { label: `Group by ${typeGroupName}`, value: [typeColId] },\n {\n label: `Group by ${scrBookGroupName} and ${typeGroupName}`,\n value: [scrBookColId, typeColId],\n },\n {\n label: `Group by ${typeGroupName} and ${scrBookGroupName}`,\n value: [typeColId, scrBookColId],\n },\n ];\n\n const handleSelectChange = (selectedGrouping: string) => {\n setGrouping(JSON.parse(selectedGrouping));\n };\n\n const handleRowClick = (row: Row, event: MouseEvent) => {\n if (!row.getIsGrouped() && !row.getIsSelected()) {\n row.getToggleSelectedHandler()(event);\n }\n };\n\n const getEvenOrOddBandingStyle = (row: Row, index: number) => {\n if (row.getIsGrouped()) return '';\n // UX has now said they don't think they want banding. I'm leaving in the code to\n // set even and odd styles, but there's nothing in the CSS to style them differently.\n // The \"even\" style used to also have tw-bg-neutral-300 (along with even) to create\n // a visual banding effect. That could be added back in if UX changes the decision.\n return cn('banded-row', index % 2 === 0 ? 'even' : 'odd');\n };\n\n const getIndent = (\n groupingState: GroupingState,\n row: Row,\n cell: Cell,\n ) => {\n if (groupingState?.length === 0 || row.depth < cell.column.getGroupedIndex()) return undefined;\n if (row.getIsGrouped()) {\n switch (row.depth) {\n case 1:\n return 'tw-ps-4';\n default:\n return undefined;\n }\n }\n switch (row.depth) {\n case 1:\n return 'tw-ps-8';\n case 2:\n return 'tw-ps-12';\n default:\n return undefined;\n }\n };\n\n return (\n
    \n {!showColumnHeaders && (\n {\n handleSelectChange(value);\n }}\n >\n \n \n \n \n \n {groupingOptions.map((option) => (\n \n {option.label}\n \n ))}\n \n \n \n )}\n \n {showColumnHeaders && (\n \n {table.getHeaderGroups().map((headerGroup) => (\n \n {headerGroup.headers\n .filter((h) => h.column.columnDef.header)\n .map((header) => (\n /* For sticky column headers to work, we probably need to change the default definition of the shadcn Table component. See https://github.com/shadcn-ui/ui/issues/1151 */\n \n {header.isPlaceholder ? undefined : (\n
    \n {header.column.getCanGroup() ? (\n \n {header.column.getIsGrouped() ? `🛑` : `👊 `}\n \n ) : undefined}{' '}\n {flexRender(header.column.columnDef.header, header.getContext())}\n
    \n )}\n
    \n ))}\n
    \n ))}\n
    \n )}\n \n {table.getRowModel().rows.map((row, rowIndex) => {\n return (\n handleRowClick(row, event)}\n >\n {row.getVisibleCells().map((cell) => {\n if (\n cell.getIsPlaceholder() ||\n (cell.column.columnDef.enableGrouping &&\n !cell.getIsGrouped() &&\n (cell.column.columnDef.id !== typeColId || !showSourceColumn))\n )\n return undefined;\n return (\n \n {(() => {\n if (cell.getIsGrouped()) {\n return (\n \n {row.getIsExpanded() && }\n {!row.getIsExpanded() &&\n (direction === 'ltr' ? : )}{' '}\n {flexRender(cell.column.columnDef.cell, cell.getContext())} (\n {row.subRows.length})\n \n );\n }\n\n // if (cell.getIsAggregated()) {\n // flexRender(\n // cell.column.columnDef.aggregatedCell ?? cell.column.columnDef.cell,\n // cell.getContext(),\n // );\n // }\n\n return flexRender(cell.column.columnDef.cell, cell.getContext());\n })()}\n \n );\n })}\n \n );\n })}\n \n
    \n
    \n );\n}\n","import {\n getLocalizeKeyForScrollGroupId,\n LanguageStrings,\n ScrollGroupId,\n} from 'platform-bible-utils';\nimport {\n Select,\n SelectContent,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\n\nconst DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS = {\n [getLocalizeKeyForScrollGroupId('undefined')]: 'Ø',\n [getLocalizeKeyForScrollGroupId(0)]: 'A',\n [getLocalizeKeyForScrollGroupId(1)]: 'B',\n [getLocalizeKeyForScrollGroupId(2)]: 'C',\n [getLocalizeKeyForScrollGroupId(3)]: 'D',\n [getLocalizeKeyForScrollGroupId(4)]: 'E',\n [getLocalizeKeyForScrollGroupId(5)]: 'F',\n [getLocalizeKeyForScrollGroupId(6)]: 'G',\n [getLocalizeKeyForScrollGroupId(7)]: 'H',\n [getLocalizeKeyForScrollGroupId(8)]: 'I',\n [getLocalizeKeyForScrollGroupId(9)]: 'J',\n [getLocalizeKeyForScrollGroupId(10)]: 'K',\n [getLocalizeKeyForScrollGroupId(11)]: 'L',\n [getLocalizeKeyForScrollGroupId(12)]: 'M',\n [getLocalizeKeyForScrollGroupId(13)]: 'N',\n [getLocalizeKeyForScrollGroupId(14)]: 'O',\n [getLocalizeKeyForScrollGroupId(15)]: 'P',\n [getLocalizeKeyForScrollGroupId(16)]: 'Q',\n [getLocalizeKeyForScrollGroupId(17)]: 'R',\n [getLocalizeKeyForScrollGroupId(18)]: 'S',\n [getLocalizeKeyForScrollGroupId(19)]: 'T',\n [getLocalizeKeyForScrollGroupId(20)]: 'U',\n [getLocalizeKeyForScrollGroupId(21)]: 'V',\n [getLocalizeKeyForScrollGroupId(22)]: 'W',\n [getLocalizeKeyForScrollGroupId(23)]: 'X',\n [getLocalizeKeyForScrollGroupId(24)]: 'Y',\n [getLocalizeKeyForScrollGroupId(25)]: 'Z',\n};\n\nexport type ScrollGroupSelectorProps = {\n /**\n * List of scroll group ids to show to the user. Either a {@link ScrollGroupId} or `undefined` for\n * no scroll group\n */\n availableScrollGroupIds: (ScrollGroupId | undefined)[];\n /** Currently selected scroll group id. `undefined` for no scroll group */\n scrollGroupId: ScrollGroupId | undefined;\n /** Callback function run when the user tries to change the scroll group id */\n onChangeScrollGroupId: (newScrollGroupId: ScrollGroupId | undefined) => void;\n /**\n * Localized strings to use for displaying scroll group ids. Must be an object whose keys are\n * `getLocalizeKeyForScrollGroupId(scrollGroupId)` for all scroll group ids (and `undefined` if\n * included) in {@link ScrollGroupSelectorProps.availableScrollGroupIds} and whose values are the\n * localized strings to use for those scroll group ids.\n *\n * Defaults to English localizations of English alphabet for scroll groups 0-25 (e.g. 0 is A) and\n * Ø for `undefined`. Will fill in any that are not provided with these English localizations.\n * Also, if any values match the keys, the English localization will be used. This is useful in\n * case you want to pass in a temporary version of the localized strings while your localized\n * strings load.\n *\n * @example\n *\n * ```typescript\n * const myScrollGroupIdLocalizedStrings = {\n * [getLocalizeKeyForScrollGroupId('undefined')]: 'Ø',\n * [getLocalizeKeyForScrollGroupId(0)]: 'A',\n * [getLocalizeKeyForScrollGroupId(1)]: 'B',\n * [getLocalizeKeyForScrollGroupId(2)]: 'C',\n * [getLocalizeKeyForScrollGroupId(3)]: 'D',\n * [getLocalizeKeyForScrollGroupId(4)]: 'E',\n * };\n * ```\n *\n * @example\n *\n * ```tsx\n * const availableScrollGroupIds = [undefined, 0, 1, 2, 3, 4];\n *\n * const localizeKeys = getLocalizeKeysForScrollGroupIds();\n *\n * const [localizedStrings] = useLocalizedStrings(localizeKeys);\n *\n * ...\n *\n * \n * ```\n */\n localizedStrings?: LanguageStrings;\n};\n\n/** Selector component for choosing a scroll group */\nexport default function ScrollGroupSelector({\n availableScrollGroupIds,\n scrollGroupId,\n onChangeScrollGroupId,\n localizedStrings = {},\n}: ScrollGroupSelectorProps) {\n const localizedStringsDefaulted = {\n ...DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS,\n ...Object.fromEntries(\n Object.entries(localizedStrings).map(\n ([localizedStringKey, localizedStringValue]: [string, string]) => [\n localizedStringKey,\n localizedStringKey === localizedStringValue &&\n localizedStringKey in DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS\n ? DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS[localizedStringKey]\n : localizedStringValue,\n ],\n ),\n ),\n };\n return (\n \n onChangeScrollGroupId(\n newScrollGroupString === 'undefined' ? undefined : parseInt(newScrollGroupString, 10),\n )\n }\n >\n \n \n \n \n {availableScrollGroupIds.map((scrollGroupOptionId) => (\n \n {localizedStringsDefaulted[getLocalizeKeyForScrollGroupId(scrollGroupOptionId)]}\n \n ))}\n \n \n );\n}\n","import { PropsWithChildren } from 'react';\nimport { Separator } from '@/components/shadcn-ui/separator';\n\n/** Props for the SettingsList component, currently just children */\ntype SettingsListProps = PropsWithChildren;\n\n/**\n * SettingsList component is a wrapper for list items. Rendered with a formatted div\n *\n * @param children To populate the list with\n * @returns Formatted div encompassing the children\n */\nexport function SettingsList({ children }: SettingsListProps) {\n return
    {children}
    ;\n}\n\n/** Props for SettingsListItem component */\ntype SettingsListItemProps = PropsWithChildren & {\n /** Primary text of the list item */\n primary: string;\n\n /** Optional text of the list item */\n secondary?: string | undefined;\n\n /** Optional boolean to display a message if the children aren't loaded yet. Defaults to false */\n isLoading?: boolean;\n\n /** Optional message to display if isLoading */\n loadingMessage?: string;\n};\n\n/**\n * SettingsListItem component is a common list item. Rendered with a formatted div\n *\n * @param primary Primary text of the list item\n * @param secondary Optional secondary text of the list item\n * @param isLoading Optional, to display a message if the action component isn't generated yet,\n * defaults to false\n * @param children The action component(s) to provide for this item\n * @param loadingMessage Optional, message to display if isLoading\n * @returns Formatted div encompassing the list item content\n */\nexport function SettingsListItem({\n primary,\n secondary,\n children,\n isLoading = false,\n loadingMessage,\n}: SettingsListItemProps) {\n return (\n
    \n
    \n

    {primary}

    \n

    \n {secondary}\n

    \n
    \n\n {isLoading ? (\n

    {loadingMessage}

    \n ) : (\n
    {children}
    \n )}\n
    \n );\n}\n\n/** Props for SettingsListHeader component */\ntype SettingsListHeaderProps = {\n /** The primary text of the list header */\n primary: string;\n\n /** Optional secondary text of the list header */\n secondary?: string | undefined;\n\n /** Optional boolean to include a separator underneath the secondary text. Defaults to false */\n includeSeparator?: boolean;\n};\n\n/**\n * SettingsListHeader component displays text above the list\n *\n * @param primary The primary text of the list header\n * @param secondary Optional secondary text of the list header\n * @param includeSeparator Optional boolean to include a separator underneath the secondary text.\n * Defaults to false\n * @returns Formatted div with list header content\n */\nexport function SettingsListHeader({\n primary,\n secondary,\n includeSeparator = false,\n}: SettingsListHeaderProps) {\n return (\n
    \n
    \n

    {primary}

    \n

    {secondary}

    \n
    \n {includeSeparator ? : ''}\n
    \n );\n}\n","import React from 'react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Card = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nCard.displayName = 'Card';\n\nconst CardHeader = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nCardHeader.displayName = 'CardHeader';\n\nconst CardTitle = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n {/* added because of https://github.com/jsx-eslint/eslint-plugin-jsx-a11y/blob/main/docs/rules/heading-has-content.md */}\n {props.children}\n \n ),\n);\nCardTitle.displayName = 'CardTitle';\n\nconst CardDescription = React.forwardRef<\n HTMLParagraphElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n

    \n));\nCardDescription.displayName = 'CardDescription';\n\nconst CardContent = React.forwardRef>(\n ({ className, ...props }, ref) => (\n

    \n ),\n);\nCardContent.displayName = 'CardContent';\n\nconst CardFooter = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nCardFooter.displayName = 'CardFooter';\n\nexport { Card, CardHeader, CardFooter, CardTitle, CardDescription, CardContent };\n","import { Card, CardDescription, CardHeader, CardTitle } from '@/components/shadcn-ui/card';\nimport { CardContent } from '@mui/material';\nimport { PropsWithChildren } from 'react';\n\ntype SettingsCardProps = PropsWithChildren & {\n /** Optional id for testing */\n id?: string;\n\n /** Label of the settings group */\n settingsGroupLabel: string;\n\n /** Optional description of the settings group */\n settingsGroupDescription?: string;\n};\n\nexport default function SettingsCard({\n id,\n settingsGroupLabel,\n settingsGroupDescription,\n children,\n}: SettingsCardProps) {\n return (\n \n \n {settingsGroupLabel}\n {settingsGroupDescription && {settingsGroupDescription}}\n \n {children}\n \n );\n}\n","import Checkbox from '@/components/shadcn-ui/checkbox';\nimport { Label } from '@/components/shadcn-ui/label';\n\nexport type ChecklistProps = {\n /** Optional string representing the id attribute of the Checklist */\n id?: string;\n /** Optional string representing CSS class name(s) for styling */\n className?: string;\n /** Array of strings representing the checkable items */\n listItems: string[];\n /** Array of strings representing the checked items */\n selectedListItems: string[];\n /**\n * Function that is called when a checkbox item is selected or deselected\n *\n * @param item The string description for this item\n * @param selected True if selected, false if not selected\n */\n handleSelectListItem: (item: string, selected: boolean) => void;\n\n /**\n * Optional function creates a label for a provided checkable item\n *\n * @param item The item for which a label is to be created\n * @returns A string representing the label text for the checkbox associated with that item\n */\n createLabel?: (item: string) => string;\n};\n\n/** Renders a list of checkboxes. Each checkbox corresponds to an item from the `listItems` array. */\nexport default function Checklist({\n id,\n className,\n listItems,\n selectedListItems,\n handleSelectListItem,\n createLabel,\n}: ChecklistProps) {\n return (\n
    \n {listItems.map((item) => (\n
    \n handleSelectListItem(item, value)}\n />\n \n
    \n ))}\n
    \n );\n}\n","function _interopRequireDefault(obj) {\n return obj && obj.__esModule ? obj : {\n \"default\": obj\n };\n}\nmodule.exports = _interopRequireDefault, module.exports.__esModule = true, module.exports[\"default\"] = module.exports;","export default function chainPropTypes(propType1, propType2) {\n if (process.env.NODE_ENV === 'production') {\n return () => null;\n }\n return function validate(...args) {\n return propType1(...args) || propType2(...args);\n };\n}","export default function _extends() {\n _extends = Object.assign ? Object.assign.bind() : function (target) {\n for (var i = 1; i < arguments.length; i++) {\n var source = arguments[i];\n for (var key in source) {\n if (Object.prototype.hasOwnProperty.call(source, key)) {\n target[key] = source[key];\n }\n }\n }\n return target;\n };\n return _extends.apply(this, arguments);\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\n// https://github.com/sindresorhus/is-plain-obj/blob/main/index.js\nexport function isPlainObject(item) {\n if (typeof item !== 'object' || item === null) {\n return false;\n }\n const prototype = Object.getPrototypeOf(item);\n return (prototype === null || prototype === Object.prototype || Object.getPrototypeOf(prototype) === null) && !(Symbol.toStringTag in item) && !(Symbol.iterator in item);\n}\nfunction deepClone(source) {\n if (!isPlainObject(source)) {\n return source;\n }\n const output = {};\n Object.keys(source).forEach(key => {\n output[key] = deepClone(source[key]);\n });\n return output;\n}\nexport default function deepmerge(target, source, options = {\n clone: true\n}) {\n const output = options.clone ? _extends({}, target) : target;\n if (isPlainObject(target) && isPlainObject(source)) {\n Object.keys(source).forEach(key => {\n // Avoid prototype pollution\n if (key === '__proto__') {\n return;\n }\n if (isPlainObject(source[key]) && key in target && isPlainObject(target[key])) {\n // Since `output` is a clone of `target` and we have narrowed `target` in this block we can cast to the same type.\n output[key] = deepmerge(target[key], source[key], options);\n } else if (options.clone) {\n output[key] = isPlainObject(source[key]) ? deepClone(source[key]) : source[key];\n } else {\n output[key] = source[key];\n }\n });\n }\n return output;\n}","/** @license React v16.13.1\n * react-is.production.min.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';var b=\"function\"===typeof Symbol&&Symbol.for,c=b?Symbol.for(\"react.element\"):60103,d=b?Symbol.for(\"react.portal\"):60106,e=b?Symbol.for(\"react.fragment\"):60107,f=b?Symbol.for(\"react.strict_mode\"):60108,g=b?Symbol.for(\"react.profiler\"):60114,h=b?Symbol.for(\"react.provider\"):60109,k=b?Symbol.for(\"react.context\"):60110,l=b?Symbol.for(\"react.async_mode\"):60111,m=b?Symbol.for(\"react.concurrent_mode\"):60111,n=b?Symbol.for(\"react.forward_ref\"):60112,p=b?Symbol.for(\"react.suspense\"):60113,q=b?\nSymbol.for(\"react.suspense_list\"):60120,r=b?Symbol.for(\"react.memo\"):60115,t=b?Symbol.for(\"react.lazy\"):60116,v=b?Symbol.for(\"react.block\"):60121,w=b?Symbol.for(\"react.fundamental\"):60117,x=b?Symbol.for(\"react.responder\"):60118,y=b?Symbol.for(\"react.scope\"):60119;\nfunction z(a){if(\"object\"===typeof a&&null!==a){var u=a.$$typeof;switch(u){case c:switch(a=a.type,a){case l:case m:case e:case g:case f:case p:return a;default:switch(a=a&&a.$$typeof,a){case k:case n:case t:case r:case h:return a;default:return u}}case d:return u}}}function A(a){return z(a)===m}exports.AsyncMode=l;exports.ConcurrentMode=m;exports.ContextConsumer=k;exports.ContextProvider=h;exports.Element=c;exports.ForwardRef=n;exports.Fragment=e;exports.Lazy=t;exports.Memo=r;exports.Portal=d;\nexports.Profiler=g;exports.StrictMode=f;exports.Suspense=p;exports.isAsyncMode=function(a){return A(a)||z(a)===l};exports.isConcurrentMode=A;exports.isContextConsumer=function(a){return z(a)===k};exports.isContextProvider=function(a){return z(a)===h};exports.isElement=function(a){return\"object\"===typeof a&&null!==a&&a.$$typeof===c};exports.isForwardRef=function(a){return z(a)===n};exports.isFragment=function(a){return z(a)===e};exports.isLazy=function(a){return z(a)===t};\nexports.isMemo=function(a){return z(a)===r};exports.isPortal=function(a){return z(a)===d};exports.isProfiler=function(a){return z(a)===g};exports.isStrictMode=function(a){return z(a)===f};exports.isSuspense=function(a){return z(a)===p};\nexports.isValidElementType=function(a){return\"string\"===typeof a||\"function\"===typeof a||a===e||a===m||a===g||a===f||a===p||a===q||\"object\"===typeof a&&null!==a&&(a.$$typeof===t||a.$$typeof===r||a.$$typeof===h||a.$$typeof===k||a.$$typeof===n||a.$$typeof===w||a.$$typeof===x||a.$$typeof===y||a.$$typeof===v)};exports.typeOf=z;\n","/** @license React v16.13.1\n * react-is.development.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\n\n\nif (process.env.NODE_ENV !== \"production\") {\n (function() {\n'use strict';\n\n// The Symbol used to tag the ReactElement-like types. If there is no native Symbol\n// nor polyfill, then a plain number is used for performance.\nvar hasSymbol = typeof Symbol === 'function' && Symbol.for;\nvar REACT_ELEMENT_TYPE = hasSymbol ? Symbol.for('react.element') : 0xeac7;\nvar REACT_PORTAL_TYPE = hasSymbol ? Symbol.for('react.portal') : 0xeaca;\nvar REACT_FRAGMENT_TYPE = hasSymbol ? Symbol.for('react.fragment') : 0xeacb;\nvar REACT_STRICT_MODE_TYPE = hasSymbol ? Symbol.for('react.strict_mode') : 0xeacc;\nvar REACT_PROFILER_TYPE = hasSymbol ? Symbol.for('react.profiler') : 0xead2;\nvar REACT_PROVIDER_TYPE = hasSymbol ? Symbol.for('react.provider') : 0xeacd;\nvar REACT_CONTEXT_TYPE = hasSymbol ? Symbol.for('react.context') : 0xeace; // TODO: We don't use AsyncMode or ConcurrentMode anymore. They were temporary\n// (unstable) APIs that have been removed. Can we remove the symbols?\n\nvar REACT_ASYNC_MODE_TYPE = hasSymbol ? Symbol.for('react.async_mode') : 0xeacf;\nvar REACT_CONCURRENT_MODE_TYPE = hasSymbol ? Symbol.for('react.concurrent_mode') : 0xeacf;\nvar REACT_FORWARD_REF_TYPE = hasSymbol ? Symbol.for('react.forward_ref') : 0xead0;\nvar REACT_SUSPENSE_TYPE = hasSymbol ? Symbol.for('react.suspense') : 0xead1;\nvar REACT_SUSPENSE_LIST_TYPE = hasSymbol ? Symbol.for('react.suspense_list') : 0xead8;\nvar REACT_MEMO_TYPE = hasSymbol ? Symbol.for('react.memo') : 0xead3;\nvar REACT_LAZY_TYPE = hasSymbol ? Symbol.for('react.lazy') : 0xead4;\nvar REACT_BLOCK_TYPE = hasSymbol ? Symbol.for('react.block') : 0xead9;\nvar REACT_FUNDAMENTAL_TYPE = hasSymbol ? Symbol.for('react.fundamental') : 0xead5;\nvar REACT_RESPONDER_TYPE = hasSymbol ? Symbol.for('react.responder') : 0xead6;\nvar REACT_SCOPE_TYPE = hasSymbol ? Symbol.for('react.scope') : 0xead7;\n\nfunction isValidElementType(type) {\n return typeof type === 'string' || typeof type === 'function' || // Note: its typeof might be other than 'symbol' or 'number' if it's a polyfill.\n type === REACT_FRAGMENT_TYPE || type === REACT_CONCURRENT_MODE_TYPE || type === REACT_PROFILER_TYPE || type === REACT_STRICT_MODE_TYPE || type === REACT_SUSPENSE_TYPE || type === REACT_SUSPENSE_LIST_TYPE || typeof type === 'object' && type !== null && (type.$$typeof === REACT_LAZY_TYPE || type.$$typeof === REACT_MEMO_TYPE || type.$$typeof === REACT_PROVIDER_TYPE || type.$$typeof === REACT_CONTEXT_TYPE || type.$$typeof === REACT_FORWARD_REF_TYPE || type.$$typeof === REACT_FUNDAMENTAL_TYPE || type.$$typeof === REACT_RESPONDER_TYPE || type.$$typeof === REACT_SCOPE_TYPE || type.$$typeof === REACT_BLOCK_TYPE);\n}\n\nfunction typeOf(object) {\n if (typeof object === 'object' && object !== null) {\n var $$typeof = object.$$typeof;\n\n switch ($$typeof) {\n case REACT_ELEMENT_TYPE:\n var type = object.type;\n\n switch (type) {\n case REACT_ASYNC_MODE_TYPE:\n case REACT_CONCURRENT_MODE_TYPE:\n case REACT_FRAGMENT_TYPE:\n case REACT_PROFILER_TYPE:\n case REACT_STRICT_MODE_TYPE:\n case REACT_SUSPENSE_TYPE:\n return type;\n\n default:\n var $$typeofType = type && type.$$typeof;\n\n switch ($$typeofType) {\n case REACT_CONTEXT_TYPE:\n case REACT_FORWARD_REF_TYPE:\n case REACT_LAZY_TYPE:\n case REACT_MEMO_TYPE:\n case REACT_PROVIDER_TYPE:\n return $$typeofType;\n\n default:\n return $$typeof;\n }\n\n }\n\n case REACT_PORTAL_TYPE:\n return $$typeof;\n }\n }\n\n return undefined;\n} // AsyncMode is deprecated along with isAsyncMode\n\nvar AsyncMode = REACT_ASYNC_MODE_TYPE;\nvar ConcurrentMode = REACT_CONCURRENT_MODE_TYPE;\nvar ContextConsumer = REACT_CONTEXT_TYPE;\nvar ContextProvider = REACT_PROVIDER_TYPE;\nvar Element = REACT_ELEMENT_TYPE;\nvar ForwardRef = REACT_FORWARD_REF_TYPE;\nvar Fragment = REACT_FRAGMENT_TYPE;\nvar Lazy = REACT_LAZY_TYPE;\nvar Memo = REACT_MEMO_TYPE;\nvar Portal = REACT_PORTAL_TYPE;\nvar Profiler = REACT_PROFILER_TYPE;\nvar StrictMode = REACT_STRICT_MODE_TYPE;\nvar Suspense = REACT_SUSPENSE_TYPE;\nvar hasWarnedAboutDeprecatedIsAsyncMode = false; // AsyncMode should be deprecated\n\nfunction isAsyncMode(object) {\n {\n if (!hasWarnedAboutDeprecatedIsAsyncMode) {\n hasWarnedAboutDeprecatedIsAsyncMode = true; // Using console['warn'] to evade Babel and ESLint\n\n console['warn']('The ReactIs.isAsyncMode() alias has been deprecated, ' + 'and will be removed in React 17+. Update your code to use ' + 'ReactIs.isConcurrentMode() instead. It has the exact same API.');\n }\n }\n\n return isConcurrentMode(object) || typeOf(object) === REACT_ASYNC_MODE_TYPE;\n}\nfunction isConcurrentMode(object) {\n return typeOf(object) === REACT_CONCURRENT_MODE_TYPE;\n}\nfunction isContextConsumer(object) {\n return typeOf(object) === REACT_CONTEXT_TYPE;\n}\nfunction isContextProvider(object) {\n return typeOf(object) === REACT_PROVIDER_TYPE;\n}\nfunction isElement(object) {\n return typeof object === 'object' && object !== null && object.$$typeof === REACT_ELEMENT_TYPE;\n}\nfunction isForwardRef(object) {\n return typeOf(object) === REACT_FORWARD_REF_TYPE;\n}\nfunction isFragment(object) {\n return typeOf(object) === REACT_FRAGMENT_TYPE;\n}\nfunction isLazy(object) {\n return typeOf(object) === REACT_LAZY_TYPE;\n}\nfunction isMemo(object) {\n return typeOf(object) === REACT_MEMO_TYPE;\n}\nfunction isPortal(object) {\n return typeOf(object) === REACT_PORTAL_TYPE;\n}\nfunction isProfiler(object) {\n return typeOf(object) === REACT_PROFILER_TYPE;\n}\nfunction isStrictMode(object) {\n return typeOf(object) === REACT_STRICT_MODE_TYPE;\n}\nfunction isSuspense(object) {\n return typeOf(object) === REACT_SUSPENSE_TYPE;\n}\n\nexports.AsyncMode = AsyncMode;\nexports.ConcurrentMode = ConcurrentMode;\nexports.ContextConsumer = ContextConsumer;\nexports.ContextProvider = ContextProvider;\nexports.Element = Element;\nexports.ForwardRef = ForwardRef;\nexports.Fragment = Fragment;\nexports.Lazy = Lazy;\nexports.Memo = Memo;\nexports.Portal = Portal;\nexports.Profiler = Profiler;\nexports.StrictMode = StrictMode;\nexports.Suspense = Suspense;\nexports.isAsyncMode = isAsyncMode;\nexports.isConcurrentMode = isConcurrentMode;\nexports.isContextConsumer = isContextConsumer;\nexports.isContextProvider = isContextProvider;\nexports.isElement = isElement;\nexports.isForwardRef = isForwardRef;\nexports.isFragment = isFragment;\nexports.isLazy = isLazy;\nexports.isMemo = isMemo;\nexports.isPortal = isPortal;\nexports.isProfiler = isProfiler;\nexports.isStrictMode = isStrictMode;\nexports.isSuspense = isSuspense;\nexports.isValidElementType = isValidElementType;\nexports.typeOf = typeOf;\n })();\n}\n","'use strict';\n\nif (process.env.NODE_ENV === 'production') {\n module.exports = require('./cjs/react-is.production.min.js');\n} else {\n module.exports = require('./cjs/react-is.development.js');\n}\n","/*\nobject-assign\n(c) Sindre Sorhus\n@license MIT\n*/\n\n'use strict';\n/* eslint-disable no-unused-vars */\nvar getOwnPropertySymbols = Object.getOwnPropertySymbols;\nvar hasOwnProperty = Object.prototype.hasOwnProperty;\nvar propIsEnumerable = Object.prototype.propertyIsEnumerable;\n\nfunction toObject(val) {\n\tif (val === null || val === undefined) {\n\t\tthrow new TypeError('Object.assign cannot be called with null or undefined');\n\t}\n\n\treturn Object(val);\n}\n\nfunction shouldUseNative() {\n\ttry {\n\t\tif (!Object.assign) {\n\t\t\treturn false;\n\t\t}\n\n\t\t// Detect buggy property enumeration order in older V8 versions.\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=4118\n\t\tvar test1 = new String('abc'); // eslint-disable-line no-new-wrappers\n\t\ttest1[5] = 'de';\n\t\tif (Object.getOwnPropertyNames(test1)[0] === '5') {\n\t\t\treturn false;\n\t\t}\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=3056\n\t\tvar test2 = {};\n\t\tfor (var i = 0; i < 10; i++) {\n\t\t\ttest2['_' + String.fromCharCode(i)] = i;\n\t\t}\n\t\tvar order2 = Object.getOwnPropertyNames(test2).map(function (n) {\n\t\t\treturn test2[n];\n\t\t});\n\t\tif (order2.join('') !== '0123456789') {\n\t\t\treturn false;\n\t\t}\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=3056\n\t\tvar test3 = {};\n\t\t'abcdefghijklmnopqrst'.split('').forEach(function (letter) {\n\t\t\ttest3[letter] = letter;\n\t\t});\n\t\tif (Object.keys(Object.assign({}, test3)).join('') !==\n\t\t\t\t'abcdefghijklmnopqrst') {\n\t\t\treturn false;\n\t\t}\n\n\t\treturn true;\n\t} catch (err) {\n\t\t// We don't expect any of the above to throw, but better to be safe.\n\t\treturn false;\n\t}\n}\n\nmodule.exports = shouldUseNative() ? Object.assign : function (target, source) {\n\tvar from;\n\tvar to = toObject(target);\n\tvar symbols;\n\n\tfor (var s = 1; s < arguments.length; s++) {\n\t\tfrom = Object(arguments[s]);\n\n\t\tfor (var key in from) {\n\t\t\tif (hasOwnProperty.call(from, key)) {\n\t\t\t\tto[key] = from[key];\n\t\t\t}\n\t\t}\n\n\t\tif (getOwnPropertySymbols) {\n\t\t\tsymbols = getOwnPropertySymbols(from);\n\t\t\tfor (var i = 0; i < symbols.length; i++) {\n\t\t\t\tif (propIsEnumerable.call(from, symbols[i])) {\n\t\t\t\t\tto[symbols[i]] = from[symbols[i]];\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\n\treturn to;\n};\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar ReactPropTypesSecret = 'SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED';\n\nmodule.exports = ReactPropTypesSecret;\n","module.exports = Function.call.bind(Object.prototype.hasOwnProperty);\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar printWarning = function() {};\n\nif (process.env.NODE_ENV !== 'production') {\n var ReactPropTypesSecret = require('./lib/ReactPropTypesSecret');\n var loggedTypeFailures = {};\n var has = require('./lib/has');\n\n printWarning = function(text) {\n var message = 'Warning: ' + text;\n if (typeof console !== 'undefined') {\n console.error(message);\n }\n try {\n // --- Welcome to debugging React ---\n // This error was thrown as a convenience so that you can use this stack\n // to find the callsite that caused this warning to fire.\n throw new Error(message);\n } catch (x) { /**/ }\n };\n}\n\n/**\n * Assert that the values match with the type specs.\n * Error messages are memorized and will only be shown once.\n *\n * @param {object} typeSpecs Map of name to a ReactPropType\n * @param {object} values Runtime values that need to be type-checked\n * @param {string} location e.g. \"prop\", \"context\", \"child context\"\n * @param {string} componentName Name of the component for error messages.\n * @param {?Function} getStack Returns the component stack.\n * @private\n */\nfunction checkPropTypes(typeSpecs, values, location, componentName, getStack) {\n if (process.env.NODE_ENV !== 'production') {\n for (var typeSpecName in typeSpecs) {\n if (has(typeSpecs, typeSpecName)) {\n var error;\n // Prop type validation may throw. In case they do, we don't want to\n // fail the render phase where it didn't fail before. So we log it.\n // After these have been cleaned up, we'll let them throw.\n try {\n // This is intentionally an invariant that gets caught. It's the same\n // behavior as without this statement except with a better message.\n if (typeof typeSpecs[typeSpecName] !== 'function') {\n var err = Error(\n (componentName || 'React class') + ': ' + location + ' type `' + typeSpecName + '` is invalid; ' +\n 'it must be a function, usually from the `prop-types` package, but received `' + typeof typeSpecs[typeSpecName] + '`.' +\n 'This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.'\n );\n err.name = 'Invariant Violation';\n throw err;\n }\n error = typeSpecs[typeSpecName](values, typeSpecName, componentName, location, null, ReactPropTypesSecret);\n } catch (ex) {\n error = ex;\n }\n if (error && !(error instanceof Error)) {\n printWarning(\n (componentName || 'React class') + ': type specification of ' +\n location + ' `' + typeSpecName + '` is invalid; the type checker ' +\n 'function must return `null` or an `Error` but returned a ' + typeof error + '. ' +\n 'You may have forgotten to pass an argument to the type checker ' +\n 'creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and ' +\n 'shape all require an argument).'\n );\n }\n if (error instanceof Error && !(error.message in loggedTypeFailures)) {\n // Only monitor this failure once because there tends to be a lot of the\n // same error.\n loggedTypeFailures[error.message] = true;\n\n var stack = getStack ? getStack() : '';\n\n printWarning(\n 'Failed ' + location + ' type: ' + error.message + (stack != null ? stack : '')\n );\n }\n }\n }\n }\n}\n\n/**\n * Resets warning cache when testing.\n *\n * @private\n */\ncheckPropTypes.resetWarningCache = function() {\n if (process.env.NODE_ENV !== 'production') {\n loggedTypeFailures = {};\n }\n}\n\nmodule.exports = checkPropTypes;\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar ReactIs = require('react-is');\nvar assign = require('object-assign');\n\nvar ReactPropTypesSecret = require('./lib/ReactPropTypesSecret');\nvar has = require('./lib/has');\nvar checkPropTypes = require('./checkPropTypes');\n\nvar printWarning = function() {};\n\nif (process.env.NODE_ENV !== 'production') {\n printWarning = function(text) {\n var message = 'Warning: ' + text;\n if (typeof console !== 'undefined') {\n console.error(message);\n }\n try {\n // --- Welcome to debugging React ---\n // This error was thrown as a convenience so that you can use this stack\n // to find the callsite that caused this warning to fire.\n throw new Error(message);\n } catch (x) {}\n };\n}\n\nfunction emptyFunctionThatReturnsNull() {\n return null;\n}\n\nmodule.exports = function(isValidElement, throwOnDirectAccess) {\n /* global Symbol */\n var ITERATOR_SYMBOL = typeof Symbol === 'function' && Symbol.iterator;\n var FAUX_ITERATOR_SYMBOL = '@@iterator'; // Before Symbol spec.\n\n /**\n * Returns the iterator method function contained on the iterable object.\n *\n * Be sure to invoke the function with the iterable as context:\n *\n * var iteratorFn = getIteratorFn(myIterable);\n * if (iteratorFn) {\n * var iterator = iteratorFn.call(myIterable);\n * ...\n * }\n *\n * @param {?object} maybeIterable\n * @return {?function}\n */\n function getIteratorFn(maybeIterable) {\n var iteratorFn = maybeIterable && (ITERATOR_SYMBOL && maybeIterable[ITERATOR_SYMBOL] || maybeIterable[FAUX_ITERATOR_SYMBOL]);\n if (typeof iteratorFn === 'function') {\n return iteratorFn;\n }\n }\n\n /**\n * Collection of methods that allow declaration and validation of props that are\n * supplied to React components. Example usage:\n *\n * var Props = require('ReactPropTypes');\n * var MyArticle = React.createClass({\n * propTypes: {\n * // An optional string prop named \"description\".\n * description: Props.string,\n *\n * // A required enum prop named \"category\".\n * category: Props.oneOf(['News','Photos']).isRequired,\n *\n * // A prop named \"dialog\" that requires an instance of Dialog.\n * dialog: Props.instanceOf(Dialog).isRequired\n * },\n * render: function() { ... }\n * });\n *\n * A more formal specification of how these methods are used:\n *\n * type := array|bool|func|object|number|string|oneOf([...])|instanceOf(...)\n * decl := ReactPropTypes.{type}(.isRequired)?\n *\n * Each and every declaration produces a function with the same signature. This\n * allows the creation of custom validation functions. For example:\n *\n * var MyLink = React.createClass({\n * propTypes: {\n * // An optional string or URI prop named \"href\".\n * href: function(props, propName, componentName) {\n * var propValue = props[propName];\n * if (propValue != null && typeof propValue !== 'string' &&\n * !(propValue instanceof URI)) {\n * return new Error(\n * 'Expected a string or an URI for ' + propName + ' in ' +\n * componentName\n * );\n * }\n * }\n * },\n * render: function() {...}\n * });\n *\n * @internal\n */\n\n var ANONYMOUS = '<>';\n\n // Important!\n // Keep this list in sync with production version in `./factoryWithThrowingShims.js`.\n var ReactPropTypes = {\n array: createPrimitiveTypeChecker('array'),\n bigint: createPrimitiveTypeChecker('bigint'),\n bool: createPrimitiveTypeChecker('boolean'),\n func: createPrimitiveTypeChecker('function'),\n number: createPrimitiveTypeChecker('number'),\n object: createPrimitiveTypeChecker('object'),\n string: createPrimitiveTypeChecker('string'),\n symbol: createPrimitiveTypeChecker('symbol'),\n\n any: createAnyTypeChecker(),\n arrayOf: createArrayOfTypeChecker,\n element: createElementTypeChecker(),\n elementType: createElementTypeTypeChecker(),\n instanceOf: createInstanceTypeChecker,\n node: createNodeChecker(),\n objectOf: createObjectOfTypeChecker,\n oneOf: createEnumTypeChecker,\n oneOfType: createUnionTypeChecker,\n shape: createShapeTypeChecker,\n exact: createStrictShapeTypeChecker,\n };\n\n /**\n * inlined Object.is polyfill to avoid requiring consumers ship their own\n * https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object/is\n */\n /*eslint-disable no-self-compare*/\n function is(x, y) {\n // SameValue algorithm\n if (x === y) {\n // Steps 1-5, 7-10\n // Steps 6.b-6.e: +0 != -0\n return x !== 0 || 1 / x === 1 / y;\n } else {\n // Step 6.a: NaN == NaN\n return x !== x && y !== y;\n }\n }\n /*eslint-enable no-self-compare*/\n\n /**\n * We use an Error-like object for backward compatibility as people may call\n * PropTypes directly and inspect their output. However, we don't use real\n * Errors anymore. We don't inspect their stack anyway, and creating them\n * is prohibitively expensive if they are created too often, such as what\n * happens in oneOfType() for any type before the one that matched.\n */\n function PropTypeError(message, data) {\n this.message = message;\n this.data = data && typeof data === 'object' ? data: {};\n this.stack = '';\n }\n // Make `instanceof Error` still work for returned errors.\n PropTypeError.prototype = Error.prototype;\n\n function createChainableTypeChecker(validate) {\n if (process.env.NODE_ENV !== 'production') {\n var manualPropTypeCallCache = {};\n var manualPropTypeWarningCount = 0;\n }\n function checkType(isRequired, props, propName, componentName, location, propFullName, secret) {\n componentName = componentName || ANONYMOUS;\n propFullName = propFullName || propName;\n\n if (secret !== ReactPropTypesSecret) {\n if (throwOnDirectAccess) {\n // New behavior only for users of `prop-types` package\n var err = new Error(\n 'Calling PropTypes validators directly is not supported by the `prop-types` package. ' +\n 'Use `PropTypes.checkPropTypes()` to call them. ' +\n 'Read more at http://fb.me/use-check-prop-types'\n );\n err.name = 'Invariant Violation';\n throw err;\n } else if (process.env.NODE_ENV !== 'production' && typeof console !== 'undefined') {\n // Old behavior for people using React.PropTypes\n var cacheKey = componentName + ':' + propName;\n if (\n !manualPropTypeCallCache[cacheKey] &&\n // Avoid spamming the console because they are often not actionable except for lib authors\n manualPropTypeWarningCount < 3\n ) {\n printWarning(\n 'You are manually calling a React.PropTypes validation ' +\n 'function for the `' + propFullName + '` prop on `' + componentName + '`. This is deprecated ' +\n 'and will throw in the standalone `prop-types` package. ' +\n 'You may be seeing this warning due to a third-party PropTypes ' +\n 'library. See https://fb.me/react-warning-dont-call-proptypes ' + 'for details.'\n );\n manualPropTypeCallCache[cacheKey] = true;\n manualPropTypeWarningCount++;\n }\n }\n }\n if (props[propName] == null) {\n if (isRequired) {\n if (props[propName] === null) {\n return new PropTypeError('The ' + location + ' `' + propFullName + '` is marked as required ' + ('in `' + componentName + '`, but its value is `null`.'));\n }\n return new PropTypeError('The ' + location + ' `' + propFullName + '` is marked as required in ' + ('`' + componentName + '`, but its value is `undefined`.'));\n }\n return null;\n } else {\n return validate(props, propName, componentName, location, propFullName);\n }\n }\n\n var chainedCheckType = checkType.bind(null, false);\n chainedCheckType.isRequired = checkType.bind(null, true);\n\n return chainedCheckType;\n }\n\n function createPrimitiveTypeChecker(expectedType) {\n function validate(props, propName, componentName, location, propFullName, secret) {\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== expectedType) {\n // `propValue` being instance of, say, date/regexp, pass the 'object'\n // check, but we can offer a more precise error message here rather than\n // 'of type `object`'.\n var preciseType = getPreciseType(propValue);\n\n return new PropTypeError(\n 'Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + preciseType + '` supplied to `' + componentName + '`, expected ') + ('`' + expectedType + '`.'),\n {expectedType: expectedType}\n );\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createAnyTypeChecker() {\n return createChainableTypeChecker(emptyFunctionThatReturnsNull);\n }\n\n function createArrayOfTypeChecker(typeChecker) {\n function validate(props, propName, componentName, location, propFullName) {\n if (typeof typeChecker !== 'function') {\n return new PropTypeError('Property `' + propFullName + '` of component `' + componentName + '` has invalid PropType notation inside arrayOf.');\n }\n var propValue = props[propName];\n if (!Array.isArray(propValue)) {\n var propType = getPropType(propValue);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected an array.'));\n }\n for (var i = 0; i < propValue.length; i++) {\n var error = typeChecker(propValue, i, componentName, location, propFullName + '[' + i + ']', ReactPropTypesSecret);\n if (error instanceof Error) {\n return error;\n }\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createElementTypeChecker() {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n if (!isValidElement(propValue)) {\n var propType = getPropType(propValue);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected a single ReactElement.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createElementTypeTypeChecker() {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n if (!ReactIs.isValidElementType(propValue)) {\n var propType = getPropType(propValue);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected a single ReactElement type.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createInstanceTypeChecker(expectedClass) {\n function validate(props, propName, componentName, location, propFullName) {\n if (!(props[propName] instanceof expectedClass)) {\n var expectedClassName = expectedClass.name || ANONYMOUS;\n var actualClassName = getClassName(props[propName]);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + actualClassName + '` supplied to `' + componentName + '`, expected ') + ('instance of `' + expectedClassName + '`.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createEnumTypeChecker(expectedValues) {\n if (!Array.isArray(expectedValues)) {\n if (process.env.NODE_ENV !== 'production') {\n if (arguments.length > 1) {\n printWarning(\n 'Invalid arguments supplied to oneOf, expected an array, got ' + arguments.length + ' arguments. ' +\n 'A common mistake is to write oneOf(x, y, z) instead of oneOf([x, y, z]).'\n );\n } else {\n printWarning('Invalid argument supplied to oneOf, expected an array.');\n }\n }\n return emptyFunctionThatReturnsNull;\n }\n\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n for (var i = 0; i < expectedValues.length; i++) {\n if (is(propValue, expectedValues[i])) {\n return null;\n }\n }\n\n var valuesString = JSON.stringify(expectedValues, function replacer(key, value) {\n var type = getPreciseType(value);\n if (type === 'symbol') {\n return String(value);\n }\n return value;\n });\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of value `' + String(propValue) + '` ' + ('supplied to `' + componentName + '`, expected one of ' + valuesString + '.'));\n }\n return createChainableTypeChecker(validate);\n }\n\n function createObjectOfTypeChecker(typeChecker) {\n function validate(props, propName, componentName, location, propFullName) {\n if (typeof typeChecker !== 'function') {\n return new PropTypeError('Property `' + propFullName + '` of component `' + componentName + '` has invalid PropType notation inside objectOf.');\n }\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== 'object') {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected an object.'));\n }\n for (var key in propValue) {\n if (has(propValue, key)) {\n var error = typeChecker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret);\n if (error instanceof Error) {\n return error;\n }\n }\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createUnionTypeChecker(arrayOfTypeCheckers) {\n if (!Array.isArray(arrayOfTypeCheckers)) {\n process.env.NODE_ENV !== 'production' ? printWarning('Invalid argument supplied to oneOfType, expected an instance of array.') : void 0;\n return emptyFunctionThatReturnsNull;\n }\n\n for (var i = 0; i < arrayOfTypeCheckers.length; i++) {\n var checker = arrayOfTypeCheckers[i];\n if (typeof checker !== 'function') {\n printWarning(\n 'Invalid argument supplied to oneOfType. Expected an array of check functions, but ' +\n 'received ' + getPostfixForTypeWarning(checker) + ' at index ' + i + '.'\n );\n return emptyFunctionThatReturnsNull;\n }\n }\n\n function validate(props, propName, componentName, location, propFullName) {\n var expectedTypes = [];\n for (var i = 0; i < arrayOfTypeCheckers.length; i++) {\n var checker = arrayOfTypeCheckers[i];\n var checkerResult = checker(props, propName, componentName, location, propFullName, ReactPropTypesSecret);\n if (checkerResult == null) {\n return null;\n }\n if (checkerResult.data && has(checkerResult.data, 'expectedType')) {\n expectedTypes.push(checkerResult.data.expectedType);\n }\n }\n var expectedTypesMessage = (expectedTypes.length > 0) ? ', expected one of type [' + expectedTypes.join(', ') + ']': '';\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` supplied to ' + ('`' + componentName + '`' + expectedTypesMessage + '.'));\n }\n return createChainableTypeChecker(validate);\n }\n\n function createNodeChecker() {\n function validate(props, propName, componentName, location, propFullName) {\n if (!isNode(props[propName])) {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` supplied to ' + ('`' + componentName + '`, expected a ReactNode.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function invalidValidatorError(componentName, location, propFullName, key, type) {\n return new PropTypeError(\n (componentName || 'React class') + ': ' + location + ' type `' + propFullName + '.' + key + '` is invalid; ' +\n 'it must be a function, usually from the `prop-types` package, but received `' + type + '`.'\n );\n }\n\n function createShapeTypeChecker(shapeTypes) {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== 'object') {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type `' + propType + '` ' + ('supplied to `' + componentName + '`, expected `object`.'));\n }\n for (var key in shapeTypes) {\n var checker = shapeTypes[key];\n if (typeof checker !== 'function') {\n return invalidValidatorError(componentName, location, propFullName, key, getPreciseType(checker));\n }\n var error = checker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret);\n if (error) {\n return error;\n }\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createStrictShapeTypeChecker(shapeTypes) {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== 'object') {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type `' + propType + '` ' + ('supplied to `' + componentName + '`, expected `object`.'));\n }\n // We need to check all keys in case some are required but missing from props.\n var allKeys = assign({}, props[propName], shapeTypes);\n for (var key in allKeys) {\n var checker = shapeTypes[key];\n if (has(shapeTypes, key) && typeof checker !== 'function') {\n return invalidValidatorError(componentName, location, propFullName, key, getPreciseType(checker));\n }\n if (!checker) {\n return new PropTypeError(\n 'Invalid ' + location + ' `' + propFullName + '` key `' + key + '` supplied to `' + componentName + '`.' +\n '\\nBad object: ' + JSON.stringify(props[propName], null, ' ') +\n '\\nValid keys: ' + JSON.stringify(Object.keys(shapeTypes), null, ' ')\n );\n }\n var error = checker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret);\n if (error) {\n return error;\n }\n }\n return null;\n }\n\n return createChainableTypeChecker(validate);\n }\n\n function isNode(propValue) {\n switch (typeof propValue) {\n case 'number':\n case 'string':\n case 'undefined':\n return true;\n case 'boolean':\n return !propValue;\n case 'object':\n if (Array.isArray(propValue)) {\n return propValue.every(isNode);\n }\n if (propValue === null || isValidElement(propValue)) {\n return true;\n }\n\n var iteratorFn = getIteratorFn(propValue);\n if (iteratorFn) {\n var iterator = iteratorFn.call(propValue);\n var step;\n if (iteratorFn !== propValue.entries) {\n while (!(step = iterator.next()).done) {\n if (!isNode(step.value)) {\n return false;\n }\n }\n } else {\n // Iterator will provide entry [k,v] tuples rather than values.\n while (!(step = iterator.next()).done) {\n var entry = step.value;\n if (entry) {\n if (!isNode(entry[1])) {\n return false;\n }\n }\n }\n }\n } else {\n return false;\n }\n\n return true;\n default:\n return false;\n }\n }\n\n function isSymbol(propType, propValue) {\n // Native Symbol.\n if (propType === 'symbol') {\n return true;\n }\n\n // falsy value can't be a Symbol\n if (!propValue) {\n return false;\n }\n\n // 19.4.3.5 Symbol.prototype[@@toStringTag] === 'Symbol'\n if (propValue['@@toStringTag'] === 'Symbol') {\n return true;\n }\n\n // Fallback for non-spec compliant Symbols which are polyfilled.\n if (typeof Symbol === 'function' && propValue instanceof Symbol) {\n return true;\n }\n\n return false;\n }\n\n // Equivalent of `typeof` but with special handling for array and regexp.\n function getPropType(propValue) {\n var propType = typeof propValue;\n if (Array.isArray(propValue)) {\n return 'array';\n }\n if (propValue instanceof RegExp) {\n // Old webkits (at least until Android 4.0) return 'function' rather than\n // 'object' for typeof a RegExp. We'll normalize this here so that /bla/\n // passes PropTypes.object.\n return 'object';\n }\n if (isSymbol(propType, propValue)) {\n return 'symbol';\n }\n return propType;\n }\n\n // This handles more types than `getPropType`. Only used for error messages.\n // See `createPrimitiveTypeChecker`.\n function getPreciseType(propValue) {\n if (typeof propValue === 'undefined' || propValue === null) {\n return '' + propValue;\n }\n var propType = getPropType(propValue);\n if (propType === 'object') {\n if (propValue instanceof Date) {\n return 'date';\n } else if (propValue instanceof RegExp) {\n return 'regexp';\n }\n }\n return propType;\n }\n\n // Returns a string that is postfixed to a warning about an invalid type.\n // For example, \"undefined\" or \"of type array\"\n function getPostfixForTypeWarning(value) {\n var type = getPreciseType(value);\n switch (type) {\n case 'array':\n case 'object':\n return 'an ' + type;\n case 'boolean':\n case 'date':\n case 'regexp':\n return 'a ' + type;\n default:\n return type;\n }\n }\n\n // Returns class name of the object, if any.\n function getClassName(propValue) {\n if (!propValue.constructor || !propValue.constructor.name) {\n return ANONYMOUS;\n }\n return propValue.constructor.name;\n }\n\n ReactPropTypes.checkPropTypes = checkPropTypes;\n ReactPropTypes.resetWarningCache = checkPropTypes.resetWarningCache;\n ReactPropTypes.PropTypes = ReactPropTypes;\n\n return ReactPropTypes;\n};\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar ReactPropTypesSecret = require('./lib/ReactPropTypesSecret');\n\nfunction emptyFunction() {}\nfunction emptyFunctionWithReset() {}\nemptyFunctionWithReset.resetWarningCache = emptyFunction;\n\nmodule.exports = function() {\n function shim(props, propName, componentName, location, propFullName, secret) {\n if (secret === ReactPropTypesSecret) {\n // It is still safe when called from React.\n return;\n }\n var err = new Error(\n 'Calling PropTypes validators directly is not supported by the `prop-types` package. ' +\n 'Use PropTypes.checkPropTypes() to call them. ' +\n 'Read more at http://fb.me/use-check-prop-types'\n );\n err.name = 'Invariant Violation';\n throw err;\n };\n shim.isRequired = shim;\n function getShim() {\n return shim;\n };\n // Important!\n // Keep this list in sync with production version in `./factoryWithTypeCheckers.js`.\n var ReactPropTypes = {\n array: shim,\n bigint: shim,\n bool: shim,\n func: shim,\n number: shim,\n object: shim,\n string: shim,\n symbol: shim,\n\n any: shim,\n arrayOf: getShim,\n element: shim,\n elementType: shim,\n instanceOf: getShim,\n node: shim,\n objectOf: getShim,\n oneOf: getShim,\n oneOfType: getShim,\n shape: getShim,\n exact: getShim,\n\n checkPropTypes: emptyFunctionWithReset,\n resetWarningCache: emptyFunction\n };\n\n ReactPropTypes.PropTypes = ReactPropTypes;\n\n return ReactPropTypes;\n};\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\nif (process.env.NODE_ENV !== 'production') {\n var ReactIs = require('react-is');\n\n // By explicitly using `prop-types` you are opting into new development behavior.\n // http://fb.me/prop-types-in-prod\n var throwOnDirectAccess = true;\n module.exports = require('./factoryWithTypeCheckers')(ReactIs.isElement, throwOnDirectAccess);\n} else {\n // By explicitly using `prop-types` you are opting into new production behavior.\n // http://fb.me/prop-types-in-prod\n module.exports = require('./factoryWithThrowingShims')();\n}\n","import PropTypes from 'prop-types';\nimport chainPropTypes from '../chainPropTypes';\nfunction isClassComponent(elementType) {\n // elementType.prototype?.isReactComponent\n const {\n prototype = {}\n } = elementType;\n return Boolean(prototype.isReactComponent);\n}\nfunction acceptingRef(props, propName, componentName, location, propFullName) {\n const element = props[propName];\n const safePropName = propFullName || propName;\n if (element == null ||\n // When server-side rendering React doesn't warn either.\n // This is not an accurate check for SSR.\n // This is only in place for Emotion compat.\n // TODO: Revisit once https://github.com/facebook/react/issues/20047 is resolved.\n typeof window === 'undefined') {\n return null;\n }\n let warningHint;\n const elementType = element.type;\n /**\n * Blacklisting instead of whitelisting\n *\n * Blacklisting will miss some components, such as React.Fragment. Those will at least\n * trigger a warning in React.\n * We can't whitelist because there is no safe way to detect React.forwardRef\n * or class components. \"Safe\" means there's no public API.\n *\n */\n if (typeof elementType === 'function' && !isClassComponent(elementType)) {\n warningHint = 'Did you accidentally use a plain function component for an element instead?';\n }\n if (warningHint !== undefined) {\n return new Error(`Invalid ${location} \\`${safePropName}\\` supplied to \\`${componentName}\\`. ` + `Expected an element that can hold a ref. ${warningHint} ` + 'For more information see https://mui.com/r/caveat-with-refs-guide');\n }\n return null;\n}\nconst elementAcceptingRef = chainPropTypes(PropTypes.element, acceptingRef);\nelementAcceptingRef.isRequired = chainPropTypes(PropTypes.element.isRequired, acceptingRef);\nexport default elementAcceptingRef;","import _extends from \"@babel/runtime/helpers/esm/extends\";\n// This module is based on https://github.com/airbnb/prop-types-exact repository.\n// However, in order to reduce the number of dependencies and to remove some extra safe checks\n// the module was forked.\n\nconst specialProperty = 'exact-prop: \\u200b';\nexport default function exactProp(propTypes) {\n if (process.env.NODE_ENV === 'production') {\n return propTypes;\n }\n return _extends({}, propTypes, {\n [specialProperty]: props => {\n const unsupportedProps = Object.keys(props).filter(prop => !propTypes.hasOwnProperty(prop));\n if (unsupportedProps.length > 0) {\n return new Error(`The following props are not supported: ${unsupportedProps.map(prop => `\\`${prop}\\``).join(', ')}. Please remove them.`);\n }\n return null;\n }\n });\n}","/**\n * WARNING: Don't import this directly.\n * Use `MuiError` from `@mui/internal-babel-macros/MuiError.macro` instead.\n * @param {number} code\n */\nexport default function formatMuiErrorMessage(code) {\n // Apply babel-plugin-transform-template-literals in loose mode\n // loose mode is safe if we're concatenating primitives\n // see https://babeljs.io/docs/en/babel-plugin-transform-template-literals#loose\n /* eslint-disable prefer-template */\n let url = 'https://mui.com/production-error/?code=' + code;\n for (let i = 1; i < arguments.length; i += 1) {\n // rest params over-transpile for this case\n // eslint-disable-next-line prefer-rest-params\n url += '&args[]=' + encodeURIComponent(arguments[i]);\n }\n return 'Minified MUI error #' + code + '; visit ' + url + ' for the full message.';\n /* eslint-enable prefer-template */\n}","/**\n * @license React\n * react-is.production.min.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n'use strict';var b=Symbol.for(\"react.element\"),c=Symbol.for(\"react.portal\"),d=Symbol.for(\"react.fragment\"),e=Symbol.for(\"react.strict_mode\"),f=Symbol.for(\"react.profiler\"),g=Symbol.for(\"react.provider\"),h=Symbol.for(\"react.context\"),k=Symbol.for(\"react.server_context\"),l=Symbol.for(\"react.forward_ref\"),m=Symbol.for(\"react.suspense\"),n=Symbol.for(\"react.suspense_list\"),p=Symbol.for(\"react.memo\"),q=Symbol.for(\"react.lazy\"),t=Symbol.for(\"react.offscreen\"),u;u=Symbol.for(\"react.module.reference\");\nfunction v(a){if(\"object\"===typeof a&&null!==a){var r=a.$$typeof;switch(r){case b:switch(a=a.type,a){case d:case f:case e:case m:case n:return a;default:switch(a=a&&a.$$typeof,a){case k:case h:case l:case q:case p:case g:return a;default:return r}}case c:return r}}}exports.ContextConsumer=h;exports.ContextProvider=g;exports.Element=b;exports.ForwardRef=l;exports.Fragment=d;exports.Lazy=q;exports.Memo=p;exports.Portal=c;exports.Profiler=f;exports.StrictMode=e;exports.Suspense=m;\nexports.SuspenseList=n;exports.isAsyncMode=function(){return!1};exports.isConcurrentMode=function(){return!1};exports.isContextConsumer=function(a){return v(a)===h};exports.isContextProvider=function(a){return v(a)===g};exports.isElement=function(a){return\"object\"===typeof a&&null!==a&&a.$$typeof===b};exports.isForwardRef=function(a){return v(a)===l};exports.isFragment=function(a){return v(a)===d};exports.isLazy=function(a){return v(a)===q};exports.isMemo=function(a){return v(a)===p};\nexports.isPortal=function(a){return v(a)===c};exports.isProfiler=function(a){return v(a)===f};exports.isStrictMode=function(a){return v(a)===e};exports.isSuspense=function(a){return v(a)===m};exports.isSuspenseList=function(a){return v(a)===n};\nexports.isValidElementType=function(a){return\"string\"===typeof a||\"function\"===typeof a||a===d||a===f||a===e||a===m||a===n||a===t||\"object\"===typeof a&&null!==a&&(a.$$typeof===q||a.$$typeof===p||a.$$typeof===g||a.$$typeof===h||a.$$typeof===l||a.$$typeof===u||void 0!==a.getModuleId)?!0:!1};exports.typeOf=v;\n","/**\n * @license React\n * react-is.development.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nif (process.env.NODE_ENV !== \"production\") {\n (function() {\n'use strict';\n\n// ATTENTION\n// When adding new symbols to this file,\n// Please consider also adding to 'react-devtools-shared/src/backend/ReactSymbols'\n// The Symbol used to tag the ReactElement-like types.\nvar REACT_ELEMENT_TYPE = Symbol.for('react.element');\nvar REACT_PORTAL_TYPE = Symbol.for('react.portal');\nvar REACT_FRAGMENT_TYPE = Symbol.for('react.fragment');\nvar REACT_STRICT_MODE_TYPE = Symbol.for('react.strict_mode');\nvar REACT_PROFILER_TYPE = Symbol.for('react.profiler');\nvar REACT_PROVIDER_TYPE = Symbol.for('react.provider');\nvar REACT_CONTEXT_TYPE = Symbol.for('react.context');\nvar REACT_SERVER_CONTEXT_TYPE = Symbol.for('react.server_context');\nvar REACT_FORWARD_REF_TYPE = Symbol.for('react.forward_ref');\nvar REACT_SUSPENSE_TYPE = Symbol.for('react.suspense');\nvar REACT_SUSPENSE_LIST_TYPE = Symbol.for('react.suspense_list');\nvar REACT_MEMO_TYPE = Symbol.for('react.memo');\nvar REACT_LAZY_TYPE = Symbol.for('react.lazy');\nvar REACT_OFFSCREEN_TYPE = Symbol.for('react.offscreen');\n\n// -----------------------------------------------------------------------------\n\nvar enableScopeAPI = false; // Experimental Create Event Handle API.\nvar enableCacheElement = false;\nvar enableTransitionTracing = false; // No known bugs, but needs performance testing\n\nvar enableLegacyHidden = false; // Enables unstable_avoidThisFallback feature in Fiber\n// stuff. Intended to enable React core members to more easily debug scheduling\n// issues in DEV builds.\n\nvar enableDebugTracing = false; // Track which Fiber(s) schedule render work.\n\nvar REACT_MODULE_REFERENCE;\n\n{\n REACT_MODULE_REFERENCE = Symbol.for('react.module.reference');\n}\n\nfunction isValidElementType(type) {\n if (typeof type === 'string' || typeof type === 'function') {\n return true;\n } // Note: typeof might be other than 'symbol' or 'number' (e.g. if it's a polyfill).\n\n\n if (type === REACT_FRAGMENT_TYPE || type === REACT_PROFILER_TYPE || enableDebugTracing || type === REACT_STRICT_MODE_TYPE || type === REACT_SUSPENSE_TYPE || type === REACT_SUSPENSE_LIST_TYPE || enableLegacyHidden || type === REACT_OFFSCREEN_TYPE || enableScopeAPI || enableCacheElement || enableTransitionTracing ) {\n return true;\n }\n\n if (typeof type === 'object' && type !== null) {\n if (type.$$typeof === REACT_LAZY_TYPE || type.$$typeof === REACT_MEMO_TYPE || type.$$typeof === REACT_PROVIDER_TYPE || type.$$typeof === REACT_CONTEXT_TYPE || type.$$typeof === REACT_FORWARD_REF_TYPE || // This needs to include all possible module reference object\n // types supported by any Flight configuration anywhere since\n // we don't know which Flight build this will end up being used\n // with.\n type.$$typeof === REACT_MODULE_REFERENCE || type.getModuleId !== undefined) {\n return true;\n }\n }\n\n return false;\n}\n\nfunction typeOf(object) {\n if (typeof object === 'object' && object !== null) {\n var $$typeof = object.$$typeof;\n\n switch ($$typeof) {\n case REACT_ELEMENT_TYPE:\n var type = object.type;\n\n switch (type) {\n case REACT_FRAGMENT_TYPE:\n case REACT_PROFILER_TYPE:\n case REACT_STRICT_MODE_TYPE:\n case REACT_SUSPENSE_TYPE:\n case REACT_SUSPENSE_LIST_TYPE:\n return type;\n\n default:\n var $$typeofType = type && type.$$typeof;\n\n switch ($$typeofType) {\n case REACT_SERVER_CONTEXT_TYPE:\n case REACT_CONTEXT_TYPE:\n case REACT_FORWARD_REF_TYPE:\n case REACT_LAZY_TYPE:\n case REACT_MEMO_TYPE:\n case REACT_PROVIDER_TYPE:\n return $$typeofType;\n\n default:\n return $$typeof;\n }\n\n }\n\n case REACT_PORTAL_TYPE:\n return $$typeof;\n }\n }\n\n return undefined;\n}\nvar ContextConsumer = REACT_CONTEXT_TYPE;\nvar ContextProvider = REACT_PROVIDER_TYPE;\nvar Element = REACT_ELEMENT_TYPE;\nvar ForwardRef = REACT_FORWARD_REF_TYPE;\nvar Fragment = REACT_FRAGMENT_TYPE;\nvar Lazy = REACT_LAZY_TYPE;\nvar Memo = REACT_MEMO_TYPE;\nvar Portal = REACT_PORTAL_TYPE;\nvar Profiler = REACT_PROFILER_TYPE;\nvar StrictMode = REACT_STRICT_MODE_TYPE;\nvar Suspense = REACT_SUSPENSE_TYPE;\nvar SuspenseList = REACT_SUSPENSE_LIST_TYPE;\nvar hasWarnedAboutDeprecatedIsAsyncMode = false;\nvar hasWarnedAboutDeprecatedIsConcurrentMode = false; // AsyncMode should be deprecated\n\nfunction isAsyncMode(object) {\n {\n if (!hasWarnedAboutDeprecatedIsAsyncMode) {\n hasWarnedAboutDeprecatedIsAsyncMode = true; // Using console['warn'] to evade Babel and ESLint\n\n console['warn']('The ReactIs.isAsyncMode() alias has been deprecated, ' + 'and will be removed in React 18+.');\n }\n }\n\n return false;\n}\nfunction isConcurrentMode(object) {\n {\n if (!hasWarnedAboutDeprecatedIsConcurrentMode) {\n hasWarnedAboutDeprecatedIsConcurrentMode = true; // Using console['warn'] to evade Babel and ESLint\n\n console['warn']('The ReactIs.isConcurrentMode() alias has been deprecated, ' + 'and will be removed in React 18+.');\n }\n }\n\n return false;\n}\nfunction isContextConsumer(object) {\n return typeOf(object) === REACT_CONTEXT_TYPE;\n}\nfunction isContextProvider(object) {\n return typeOf(object) === REACT_PROVIDER_TYPE;\n}\nfunction isElement(object) {\n return typeof object === 'object' && object !== null && object.$$typeof === REACT_ELEMENT_TYPE;\n}\nfunction isForwardRef(object) {\n return typeOf(object) === REACT_FORWARD_REF_TYPE;\n}\nfunction isFragment(object) {\n return typeOf(object) === REACT_FRAGMENT_TYPE;\n}\nfunction isLazy(object) {\n return typeOf(object) === REACT_LAZY_TYPE;\n}\nfunction isMemo(object) {\n return typeOf(object) === REACT_MEMO_TYPE;\n}\nfunction isPortal(object) {\n return typeOf(object) === REACT_PORTAL_TYPE;\n}\nfunction isProfiler(object) {\n return typeOf(object) === REACT_PROFILER_TYPE;\n}\nfunction isStrictMode(object) {\n return typeOf(object) === REACT_STRICT_MODE_TYPE;\n}\nfunction isSuspense(object) {\n return typeOf(object) === REACT_SUSPENSE_TYPE;\n}\nfunction isSuspenseList(object) {\n return typeOf(object) === REACT_SUSPENSE_LIST_TYPE;\n}\n\nexports.ContextConsumer = ContextConsumer;\nexports.ContextProvider = ContextProvider;\nexports.Element = Element;\nexports.ForwardRef = ForwardRef;\nexports.Fragment = Fragment;\nexports.Lazy = Lazy;\nexports.Memo = Memo;\nexports.Portal = Portal;\nexports.Profiler = Profiler;\nexports.StrictMode = StrictMode;\nexports.Suspense = Suspense;\nexports.SuspenseList = SuspenseList;\nexports.isAsyncMode = isAsyncMode;\nexports.isConcurrentMode = isConcurrentMode;\nexports.isContextConsumer = isContextConsumer;\nexports.isContextProvider = isContextProvider;\nexports.isElement = isElement;\nexports.isForwardRef = isForwardRef;\nexports.isFragment = isFragment;\nexports.isLazy = isLazy;\nexports.isMemo = isMemo;\nexports.isPortal = isPortal;\nexports.isProfiler = isProfiler;\nexports.isStrictMode = isStrictMode;\nexports.isSuspense = isSuspense;\nexports.isSuspenseList = isSuspenseList;\nexports.isValidElementType = isValidElementType;\nexports.typeOf = typeOf;\n })();\n}\n","'use strict';\n\nif (process.env.NODE_ENV === 'production') {\n module.exports = require('./cjs/react-is.production.min.js');\n} else {\n module.exports = require('./cjs/react-is.development.js');\n}\n","import { ForwardRef, Memo } from 'react-is';\n\n// Simplified polyfill for IE11 support\n// https://github.com/JamesMGreene/Function.name/blob/58b314d4a983110c3682f1228f845d39ccca1817/Function.name.js#L3\nconst fnNameMatchRegex = /^\\s*function(?:\\s|\\s*\\/\\*.*\\*\\/\\s*)+([^(\\s/]*)\\s*/;\nexport function getFunctionName(fn) {\n const match = `${fn}`.match(fnNameMatchRegex);\n const name = match && match[1];\n return name || '';\n}\nfunction getFunctionComponentName(Component, fallback = '') {\n return Component.displayName || Component.name || getFunctionName(Component) || fallback;\n}\nfunction getWrappedName(outerType, innerType, wrapperName) {\n const functionName = getFunctionComponentName(innerType);\n return outerType.displayName || (functionName !== '' ? `${wrapperName}(${functionName})` : wrapperName);\n}\n\n/**\n * cherry-pick from\n * https://github.com/facebook/react/blob/769b1f270e1251d9dbdce0fcbd9e92e502d059b8/packages/shared/getComponentName.js\n * originally forked from recompose/getDisplayName with added IE11 support\n */\nexport default function getDisplayName(Component) {\n if (Component == null) {\n return undefined;\n }\n if (typeof Component === 'string') {\n return Component;\n }\n if (typeof Component === 'function') {\n return getFunctionComponentName(Component, 'Component');\n }\n\n // TypeScript can't have components as objects but they exist in the form of `memo` or `Suspense`\n if (typeof Component === 'object') {\n switch (Component.$$typeof) {\n case ForwardRef:\n return getWrappedName(Component, Component.render, 'ForwardRef');\n case Memo:\n return getWrappedName(Component, Component.type, 'memo');\n default:\n return undefined;\n }\n }\n return undefined;\n}","export default function HTMLElementType(props, propName, componentName, location, propFullName) {\n if (process.env.NODE_ENV === 'production') {\n return null;\n }\n const propValue = props[propName];\n const safePropName = propFullName || propName;\n if (propValue == null) {\n return null;\n }\n if (propValue && propValue.nodeType !== 1) {\n return new Error(`Invalid ${location} \\`${safePropName}\\` supplied to \\`${componentName}\\`. ` + `Expected an HTMLElement.`);\n }\n return null;\n}","import PropTypes from 'prop-types';\nconst refType = PropTypes.oneOfType([PropTypes.func, PropTypes.object]);\nexport default refType;","import _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\n// It should to be noted that this function isn't equivalent to `text-transform: capitalize`.\n//\n// A strict capitalization should uppercase the first letter of each word in the sentence.\n// We only handle the first word.\nexport default function capitalize(string) {\n if (typeof string !== 'string') {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: \\`capitalize(string)\\` expects a string argument.` : _formatMuiErrorMessage(7));\n }\n return string.charAt(0).toUpperCase() + string.slice(1);\n}","/**\n * Safe chained function.\n *\n * Will only create a new function if needed,\n * otherwise will pass back existing functions or null.\n */\nexport default function createChainedFunction(...funcs) {\n return funcs.reduce((acc, func) => {\n if (func == null) {\n return acc;\n }\n return function chainedFunction(...args) {\n acc.apply(this, args);\n func.apply(this, args);\n };\n }, () => {});\n}","// Corresponds to 10 frames at 60 Hz.\n// A few bytes payload overhead when lodash/debounce is ~3 kB and debounce ~300 B.\nexport default function debounce(func, wait = 166) {\n let timeout;\n function debounced(...args) {\n const later = () => {\n // @ts-ignore\n func.apply(this, args);\n };\n clearTimeout(timeout);\n timeout = setTimeout(later, wait);\n }\n debounced.clear = () => {\n clearTimeout(timeout);\n };\n return debounced;\n}","export default function deprecatedPropType(validator, reason) {\n if (process.env.NODE_ENV === 'production') {\n return () => null;\n }\n return (props, propName, componentName, location, propFullName) => {\n const componentNameSafe = componentName || '<>';\n const propFullNameSafe = propFullName || propName;\n if (typeof props[propName] !== 'undefined') {\n return new Error(`The ${location} \\`${propFullNameSafe}\\` of ` + `\\`${componentNameSafe}\\` is deprecated. ${reason}`);\n }\n return null;\n };\n}","import * as React from 'react';\nexport default function isMuiElement(element, muiNames) {\n var _muiName, _element$type;\n return /*#__PURE__*/React.isValidElement(element) && muiNames.indexOf( // For server components `muiName` is avaialble in element.type._payload.value.muiName\n // relevant info - https://github.com/facebook/react/blob/2807d781a08db8e9873687fccc25c0f12b4fb3d4/packages/react/src/ReactLazy.js#L45\n // eslint-disable-next-line no-underscore-dangle\n (_muiName = element.type.muiName) != null ? _muiName : (_element$type = element.type) == null || (_element$type = _element$type._payload) == null || (_element$type = _element$type.value) == null ? void 0 : _element$type.muiName) !== -1;\n}","export default function ownerDocument(node) {\n return node && node.ownerDocument || document;\n}","import ownerDocument from '../ownerDocument';\nexport default function ownerWindow(node) {\n const doc = ownerDocument(node);\n return doc.defaultView || window;\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nexport default function requirePropFactory(componentNameInError, Component) {\n if (process.env.NODE_ENV === 'production') {\n return () => null;\n }\n\n // eslint-disable-next-line react/forbid-foreign-prop-types\n const prevPropTypes = Component ? _extends({}, Component.propTypes) : null;\n const requireProp = requiredProp => (props, propName, componentName, location, propFullName, ...args) => {\n const propFullNameSafe = propFullName || propName;\n const defaultTypeChecker = prevPropTypes == null ? void 0 : prevPropTypes[propFullNameSafe];\n if (defaultTypeChecker) {\n const typeCheckerResult = defaultTypeChecker(props, propName, componentName, location, propFullName, ...args);\n if (typeCheckerResult) {\n return typeCheckerResult;\n }\n }\n if (typeof props[propName] !== 'undefined' && !props[requiredProp]) {\n return new Error(`The prop \\`${propFullNameSafe}\\` of ` + `\\`${componentNameInError}\\` can only be used together with the \\`${requiredProp}\\` prop.`);\n }\n return null;\n };\n return requireProp;\n}","/**\n * TODO v5: consider making it private\n *\n * passes {value} to {ref}\n *\n * WARNING: Be sure to only call this inside a callback that is passed as a ref.\n * Otherwise, make sure to cleanup the previous {ref} if it changes. See\n * https://github.com/mui/material-ui/issues/13539\n *\n * Useful if you want to expose the ref of an inner component to the public API\n * while still using it inside the component.\n * @param ref A ref callback or ref object. If anything falsy, this is a no-op.\n */\nexport default function setRef(ref, value) {\n if (typeof ref === 'function') {\n ref(value);\n } else if (ref) {\n ref.current = value;\n }\n}","'use client';\n\nimport * as React from 'react';\n\n/**\n * A version of `React.useLayoutEffect` that does not show a warning when server-side rendering.\n * This is useful for effects that are only needed for client-side rendering but not for SSR.\n *\n * Before you use this hook, make sure to read https://gist.github.com/gaearon/e7d97cdf38a2907924ea12e4ebdf3c85\n * and confirm it doesn't apply to your use-case.\n */\nconst useEnhancedEffect = typeof window !== 'undefined' ? React.useLayoutEffect : React.useEffect;\nexport default useEnhancedEffect;","'use client';\n\nimport * as React from 'react';\nlet globalId = 0;\nfunction useGlobalId(idOverride) {\n const [defaultId, setDefaultId] = React.useState(idOverride);\n const id = idOverride || defaultId;\n React.useEffect(() => {\n if (defaultId == null) {\n // Fallback to this default id when possible.\n // Use the incrementing value for client-side rendering only.\n // We can't use it server-side.\n // If you want to use random values please consider the Birthday Problem: https://en.wikipedia.org/wiki/Birthday_problem\n globalId += 1;\n setDefaultId(`mui-${globalId}`);\n }\n }, [defaultId]);\n return id;\n}\n\n// downstream bundlers may remove unnecessary concatenation, but won't remove toString call -- Workaround for https://github.com/webpack/webpack/issues/14814\nconst maybeReactUseId = React['useId'.toString()];\n/**\n *\n * @example
    \n * @param idOverride\n * @returns {string}\n */\nexport default function useId(idOverride) {\n if (maybeReactUseId !== undefined) {\n const reactId = maybeReactUseId();\n return idOverride != null ? idOverride : reactId;\n }\n // eslint-disable-next-line react-hooks/rules-of-hooks -- `React.useId` is invariant at runtime.\n return useGlobalId(idOverride);\n}","export default function unsupportedProp(props, propName, componentName, location, propFullName) {\n if (process.env.NODE_ENV === 'production') {\n return null;\n }\n const propFullNameSafe = propFullName || propName;\n if (typeof props[propName] !== 'undefined') {\n return new Error(`The prop \\`${propFullNameSafe}\\` is not supported. Please remove it.`);\n }\n return null;\n}","'use client';\n\n/* eslint-disable react-hooks/rules-of-hooks, react-hooks/exhaustive-deps */\nimport * as React from 'react';\nexport default function useControlled({\n controlled,\n default: defaultProp,\n name,\n state = 'value'\n}) {\n // isControlled is ignored in the hook dependency lists as it should never change.\n const {\n current: isControlled\n } = React.useRef(controlled !== undefined);\n const [valueState, setValue] = React.useState(defaultProp);\n const value = isControlled ? controlled : valueState;\n if (process.env.NODE_ENV !== 'production') {\n React.useEffect(() => {\n if (isControlled !== (controlled !== undefined)) {\n console.error([`MUI: A component is changing the ${isControlled ? '' : 'un'}controlled ${state} state of ${name} to be ${isControlled ? 'un' : ''}controlled.`, 'Elements should not switch from uncontrolled to controlled (or vice versa).', `Decide between using a controlled or uncontrolled ${name} ` + 'element for the lifetime of the component.', \"The nature of the state is determined during the first render. It's considered controlled if the value is not `undefined`.\", 'More info: https://fb.me/react-controlled-components'].join('\\n'));\n }\n }, [state, name, controlled]);\n const {\n current: defaultValue\n } = React.useRef(defaultProp);\n React.useEffect(() => {\n if (!isControlled && defaultValue !== defaultProp) {\n console.error([`MUI: A component is changing the default ${state} state of an uncontrolled ${name} after being initialized. ` + `To suppress this warning opt to use a controlled ${name}.`].join('\\n'));\n }\n }, [JSON.stringify(defaultProp)]);\n }\n const setValueIfUncontrolled = React.useCallback(newValue => {\n if (!isControlled) {\n setValue(newValue);\n }\n }, []);\n return [value, setValueIfUncontrolled];\n}","'use client';\n\nimport * as React from 'react';\nimport useEnhancedEffect from '../useEnhancedEffect';\n\n/**\n * Inspired by https://github.com/facebook/react/issues/14099#issuecomment-440013892\n * See RFC in https://github.com/reactjs/rfcs/pull/220\n */\n\nfunction useEventCallback(fn) {\n const ref = React.useRef(fn);\n useEnhancedEffect(() => {\n ref.current = fn;\n });\n return React.useRef((...args) =>\n // @ts-expect-error hide `this`\n (0, ref.current)(...args)).current;\n}\nexport default useEventCallback;","'use client';\n\nimport * as React from 'react';\nimport setRef from '../setRef';\nexport default function useForkRef(...refs) {\n /**\n * This will create a new function if the refs passed to this hook change and are all defined.\n * This means react will call the old forkRef with `null` and the new forkRef\n * with the ref. Cleanup naturally emerges from this behavior.\n */\n return React.useMemo(() => {\n if (refs.every(ref => ref == null)) {\n return null;\n }\n return instance => {\n refs.forEach(ref => {\n setRef(ref, instance);\n });\n };\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, refs);\n}","'use client';\n\nimport * as React from 'react';\nconst UNINITIALIZED = {};\n\n/**\n * A React.useRef() that is initialized lazily with a function. Note that it accepts an optional\n * initialization argument, so the initialization function doesn't need to be an inline closure.\n *\n * @usage\n * const ref = useLazyRef(sortColumns, columns)\n */\nexport default function useLazyRef(init, initArg) {\n const ref = React.useRef(UNINITIALIZED);\n if (ref.current === UNINITIALIZED) {\n ref.current = init(initArg);\n }\n return ref;\n}","'use client';\n\nimport * as React from 'react';\nconst EMPTY = [];\n\n/**\n * A React.useEffect equivalent that runs once, when the component is mounted.\n */\nexport default function useOnMount(fn) {\n /* eslint-disable react-hooks/exhaustive-deps */\n React.useEffect(fn, EMPTY);\n /* eslint-enable react-hooks/exhaustive-deps */\n}","'use client';\n\nimport useLazyRef from '../useLazyRef/useLazyRef';\nimport useOnMount from '../useOnMount/useOnMount';\nexport class Timeout {\n constructor() {\n this.currentId = null;\n this.clear = () => {\n if (this.currentId !== null) {\n clearTimeout(this.currentId);\n this.currentId = null;\n }\n };\n this.disposeEffect = () => {\n return this.clear;\n };\n }\n static create() {\n return new Timeout();\n }\n /**\n * Executes `fn` after `delay`, clearing any previously scheduled call.\n */\n start(delay, fn) {\n this.clear();\n this.currentId = setTimeout(() => {\n this.currentId = null;\n fn();\n }, delay);\n }\n}\nexport default function useTimeout() {\n const timeout = useLazyRef(Timeout.create).current;\n useOnMount(timeout.disposeEffect);\n return timeout;\n}","'use client';\n\n// based on https://github.com/WICG/focus-visible/blob/v4.1.5/src/focus-visible.js\nimport * as React from 'react';\nimport { Timeout } from '../useTimeout/useTimeout';\nlet hadKeyboardEvent = true;\nlet hadFocusVisibleRecently = false;\nconst hadFocusVisibleRecentlyTimeout = new Timeout();\nconst inputTypesWhitelist = {\n text: true,\n search: true,\n url: true,\n tel: true,\n email: true,\n password: true,\n number: true,\n date: true,\n month: true,\n week: true,\n time: true,\n datetime: true,\n 'datetime-local': true\n};\n\n/**\n * Computes whether the given element should automatically trigger the\n * `focus-visible` class being added, i.e. whether it should always match\n * `:focus-visible` when focused.\n * @param {Element} node\n * @returns {boolean}\n */\nfunction focusTriggersKeyboardModality(node) {\n const {\n type,\n tagName\n } = node;\n if (tagName === 'INPUT' && inputTypesWhitelist[type] && !node.readOnly) {\n return true;\n }\n if (tagName === 'TEXTAREA' && !node.readOnly) {\n return true;\n }\n if (node.isContentEditable) {\n return true;\n }\n return false;\n}\n\n/**\n * Keep track of our keyboard modality state with `hadKeyboardEvent`.\n * If the most recent user interaction was via the keyboard;\n * and the key press did not include a meta, alt/option, or control key;\n * then the modality is keyboard. Otherwise, the modality is not keyboard.\n * @param {KeyboardEvent} event\n */\nfunction handleKeyDown(event) {\n if (event.metaKey || event.altKey || event.ctrlKey) {\n return;\n }\n hadKeyboardEvent = true;\n}\n\n/**\n * If at any point a user clicks with a pointing device, ensure that we change\n * the modality away from keyboard.\n * This avoids the situation where a user presses a key on an already focused\n * element, and then clicks on a different element, focusing it with a\n * pointing device, while we still think we're in keyboard modality.\n */\nfunction handlePointerDown() {\n hadKeyboardEvent = false;\n}\nfunction handleVisibilityChange() {\n if (this.visibilityState === 'hidden') {\n // If the tab becomes active again, the browser will handle calling focus\n // on the element (Safari actually calls it twice).\n // If this tab change caused a blur on an element with focus-visible,\n // re-apply the class when the user switches back to the tab.\n if (hadFocusVisibleRecently) {\n hadKeyboardEvent = true;\n }\n }\n}\nfunction prepare(doc) {\n doc.addEventListener('keydown', handleKeyDown, true);\n doc.addEventListener('mousedown', handlePointerDown, true);\n doc.addEventListener('pointerdown', handlePointerDown, true);\n doc.addEventListener('touchstart', handlePointerDown, true);\n doc.addEventListener('visibilitychange', handleVisibilityChange, true);\n}\nexport function teardown(doc) {\n doc.removeEventListener('keydown', handleKeyDown, true);\n doc.removeEventListener('mousedown', handlePointerDown, true);\n doc.removeEventListener('pointerdown', handlePointerDown, true);\n doc.removeEventListener('touchstart', handlePointerDown, true);\n doc.removeEventListener('visibilitychange', handleVisibilityChange, true);\n}\nfunction isFocusVisible(event) {\n const {\n target\n } = event;\n try {\n return target.matches(':focus-visible');\n } catch (error) {\n // Browsers not implementing :focus-visible will throw a SyntaxError.\n // We use our own heuristic for those browsers.\n // Rethrow might be better if it's not the expected error but do we really\n // want to crash if focus-visible malfunctioned?\n }\n\n // No need for validFocusTarget check. The user does that by attaching it to\n // focusable events only.\n return hadKeyboardEvent || focusTriggersKeyboardModality(target);\n}\nexport default function useIsFocusVisible() {\n const ref = React.useCallback(node => {\n if (node != null) {\n prepare(node.ownerDocument);\n }\n }, []);\n const isFocusVisibleRef = React.useRef(false);\n\n /**\n * Should be called if a blur event is fired\n */\n function handleBlurVisible() {\n // checking against potential state variable does not suffice if we focus and blur synchronously.\n // React wouldn't have time to trigger a re-render so `focusVisible` would be stale.\n // Ideally we would adjust `isFocusVisible(event)` to look at `relatedTarget` for blur events.\n // This doesn't work in IE11 due to https://github.com/facebook/react/issues/3751\n // TODO: check again if React releases their internal changes to focus event handling (https://github.com/facebook/react/pull/19186).\n if (isFocusVisibleRef.current) {\n // To detect a tab/window switch, we look for a blur event followed\n // rapidly by a visibility change.\n // If we don't see a visibility change within 100ms, it's probably a\n // regular focus change.\n hadFocusVisibleRecently = true;\n hadFocusVisibleRecentlyTimeout.start(100, () => {\n hadFocusVisibleRecently = false;\n });\n isFocusVisibleRef.current = false;\n return true;\n }\n return false;\n }\n\n /**\n * Should be called if a blur event is fired\n */\n function handleFocusVisible(event) {\n if (isFocusVisible(event)) {\n isFocusVisibleRef.current = true;\n return true;\n }\n return false;\n }\n return {\n isFocusVisibleRef,\n onFocus: handleFocusVisible,\n onBlur: handleBlurVisible,\n ref\n };\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\n/**\n * Add keys, values of `defaultProps` that does not exist in `props`\n * @param {object} defaultProps\n * @param {object} props\n * @returns {object} resolved props\n */\nexport default function resolveProps(defaultProps, props) {\n const output = _extends({}, props);\n Object.keys(defaultProps).forEach(propName => {\n if (propName.toString().match(/^(components|slots)$/)) {\n output[propName] = _extends({}, defaultProps[propName], output[propName]);\n } else if (propName.toString().match(/^(componentsProps|slotProps)$/)) {\n const defaultSlotProps = defaultProps[propName] || {};\n const slotProps = props[propName];\n output[propName] = {};\n if (!slotProps || !Object.keys(slotProps)) {\n // Reduce the iteration if the slot props is empty\n output[propName] = defaultSlotProps;\n } else if (!defaultSlotProps || !Object.keys(defaultSlotProps)) {\n // Reduce the iteration if the default slot props is empty\n output[propName] = slotProps;\n } else {\n output[propName] = _extends({}, slotProps);\n Object.keys(defaultSlotProps).forEach(slotPropName => {\n output[propName][slotPropName] = resolveProps(defaultSlotProps[slotPropName], slotProps[slotPropName]);\n });\n }\n } else if (output[propName] === undefined) {\n output[propName] = defaultProps[propName];\n }\n });\n return output;\n}","export default function composeClasses(slots, getUtilityClass, classes = undefined) {\n const output = {};\n Object.keys(slots).forEach(\n // `Object.keys(slots)` can't be wider than `T` because we infer `T` from `slots`.\n // @ts-expect-error https://github.com/microsoft/TypeScript/pull/12253#issuecomment-263132208\n slot => {\n output[slot] = slots[slot].reduce((acc, key) => {\n if (key) {\n const utilityClass = getUtilityClass(key);\n if (utilityClass !== '') {\n acc.push(utilityClass);\n }\n if (classes && classes[key]) {\n acc.push(classes[key]);\n }\n }\n return acc;\n }, []).join(' ');\n });\n return output;\n}","const defaultGenerator = componentName => componentName;\nconst createClassNameGenerator = () => {\n let generate = defaultGenerator;\n return {\n configure(generator) {\n generate = generator;\n },\n generate(componentName) {\n return generate(componentName);\n },\n reset() {\n generate = defaultGenerator;\n }\n };\n};\nconst ClassNameGenerator = createClassNameGenerator();\nexport default ClassNameGenerator;","import ClassNameGenerator from '../ClassNameGenerator';\nexport const globalStateClasses = {\n active: 'active',\n checked: 'checked',\n completed: 'completed',\n disabled: 'disabled',\n error: 'error',\n expanded: 'expanded',\n focused: 'focused',\n focusVisible: 'focusVisible',\n open: 'open',\n readOnly: 'readOnly',\n required: 'required',\n selected: 'selected'\n};\nexport default function generateUtilityClass(componentName, slot, globalStatePrefix = 'Mui') {\n const globalStateClass = globalStateClasses[slot];\n return globalStateClass ? `${globalStatePrefix}-${globalStateClass}` : `${ClassNameGenerator.generate(componentName)}-${slot}`;\n}\nexport function isGlobalState(slot) {\n return globalStateClasses[slot] !== undefined;\n}","import generateUtilityClass from '../generateUtilityClass';\nexport default function generateUtilityClasses(componentName, slots, globalStatePrefix = 'Mui') {\n const result = {};\n slots.forEach(slot => {\n result[slot] = generateUtilityClass(componentName, slot, globalStatePrefix);\n });\n return result;\n}","function clamp(val, min = Number.MIN_SAFE_INTEGER, max = Number.MAX_SAFE_INTEGER) {\n return Math.max(min, Math.min(val, max));\n}\nexport default clamp;","export default function _objectWithoutPropertiesLoose(source, excluded) {\n if (source == null) return {};\n var target = {};\n var sourceKeys = Object.keys(source);\n var key, i;\n for (i = 0; i < sourceKeys.length; i++) {\n key = sourceKeys[i];\n if (excluded.indexOf(key) >= 0) continue;\n target[key] = source[key];\n }\n return target;\n}","import _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nconst _excluded = [\"values\", \"unit\", \"step\"];\n// Sorted ASC by size. That's important.\n// It can't be configured as it's used statically for propTypes.\nexport const breakpointKeys = ['xs', 'sm', 'md', 'lg', 'xl'];\nconst sortBreakpointsValues = values => {\n const breakpointsAsArray = Object.keys(values).map(key => ({\n key,\n val: values[key]\n })) || [];\n // Sort in ascending order\n breakpointsAsArray.sort((breakpoint1, breakpoint2) => breakpoint1.val - breakpoint2.val);\n return breakpointsAsArray.reduce((acc, obj) => {\n return _extends({}, acc, {\n [obj.key]: obj.val\n });\n }, {});\n};\n\n// Keep in mind that @media is inclusive by the CSS specification.\nexport default function createBreakpoints(breakpoints) {\n const {\n // The breakpoint **start** at this value.\n // For instance with the first breakpoint xs: [xs, sm).\n values = {\n xs: 0,\n // phone\n sm: 600,\n // tablet\n md: 900,\n // small laptop\n lg: 1200,\n // desktop\n xl: 1536 // large screen\n },\n unit = 'px',\n step = 5\n } = breakpoints,\n other = _objectWithoutPropertiesLoose(breakpoints, _excluded);\n const sortedValues = sortBreakpointsValues(values);\n const keys = Object.keys(sortedValues);\n function up(key) {\n const value = typeof values[key] === 'number' ? values[key] : key;\n return `@media (min-width:${value}${unit})`;\n }\n function down(key) {\n const value = typeof values[key] === 'number' ? values[key] : key;\n return `@media (max-width:${value - step / 100}${unit})`;\n }\n function between(start, end) {\n const endIndex = keys.indexOf(end);\n return `@media (min-width:${typeof values[start] === 'number' ? values[start] : start}${unit}) and ` + `(max-width:${(endIndex !== -1 && typeof values[keys[endIndex]] === 'number' ? values[keys[endIndex]] : end) - step / 100}${unit})`;\n }\n function only(key) {\n if (keys.indexOf(key) + 1 < keys.length) {\n return between(key, keys[keys.indexOf(key) + 1]);\n }\n return up(key);\n }\n function not(key) {\n // handle first and last key separately, for better readability\n const keyIndex = keys.indexOf(key);\n if (keyIndex === 0) {\n return up(keys[1]);\n }\n if (keyIndex === keys.length - 1) {\n return down(keys[keyIndex]);\n }\n return between(key, keys[keys.indexOf(key) + 1]).replace('@media', '@media not all and');\n }\n return _extends({\n keys,\n values: sortedValues,\n up,\n down,\n between,\n only,\n not,\n unit\n }, other);\n}","const shape = {\n borderRadius: 4\n};\nexport default shape;","import PropTypes from 'prop-types';\nconst responsivePropType = process.env.NODE_ENV !== 'production' ? PropTypes.oneOfType([PropTypes.number, PropTypes.string, PropTypes.object, PropTypes.array]) : {};\nexport default responsivePropType;","import deepmerge from '@mui/utils/deepmerge';\nfunction merge(acc, item) {\n if (!item) {\n return acc;\n }\n return deepmerge(acc, item, {\n clone: false // No need to clone deep, it's way faster.\n });\n}\nexport default merge;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport PropTypes from 'prop-types';\nimport deepmerge from '@mui/utils/deepmerge';\nimport merge from './merge';\n\n// The breakpoint **start** at this value.\n// For instance with the first breakpoint xs: [xs, sm[.\nexport const values = {\n xs: 0,\n // phone\n sm: 600,\n // tablet\n md: 900,\n // small laptop\n lg: 1200,\n // desktop\n xl: 1536 // large screen\n};\nconst defaultBreakpoints = {\n // Sorted ASC by size. That's important.\n // It can't be configured as it's used statically for propTypes.\n keys: ['xs', 'sm', 'md', 'lg', 'xl'],\n up: key => `@media (min-width:${values[key]}px)`\n};\nexport function handleBreakpoints(props, propValue, styleFromPropValue) {\n const theme = props.theme || {};\n if (Array.isArray(propValue)) {\n const themeBreakpoints = theme.breakpoints || defaultBreakpoints;\n return propValue.reduce((acc, item, index) => {\n acc[themeBreakpoints.up(themeBreakpoints.keys[index])] = styleFromPropValue(propValue[index]);\n return acc;\n }, {});\n }\n if (typeof propValue === 'object') {\n const themeBreakpoints = theme.breakpoints || defaultBreakpoints;\n return Object.keys(propValue).reduce((acc, breakpoint) => {\n // key is breakpoint\n if (Object.keys(themeBreakpoints.values || values).indexOf(breakpoint) !== -1) {\n const mediaKey = themeBreakpoints.up(breakpoint);\n acc[mediaKey] = styleFromPropValue(propValue[breakpoint], breakpoint);\n } else {\n const cssKey = breakpoint;\n acc[cssKey] = propValue[cssKey];\n }\n return acc;\n }, {});\n }\n const output = styleFromPropValue(propValue);\n return output;\n}\nfunction breakpoints(styleFunction) {\n // false positive\n // eslint-disable-next-line react/function-component-definition\n const newStyleFunction = props => {\n const theme = props.theme || {};\n const base = styleFunction(props);\n const themeBreakpoints = theme.breakpoints || defaultBreakpoints;\n const extended = themeBreakpoints.keys.reduce((acc, key) => {\n if (props[key]) {\n acc = acc || {};\n acc[themeBreakpoints.up(key)] = styleFunction(_extends({\n theme\n }, props[key]));\n }\n return acc;\n }, null);\n return merge(base, extended);\n };\n newStyleFunction.propTypes = process.env.NODE_ENV !== 'production' ? _extends({}, styleFunction.propTypes, {\n xs: PropTypes.object,\n sm: PropTypes.object,\n md: PropTypes.object,\n lg: PropTypes.object,\n xl: PropTypes.object\n }) : {};\n newStyleFunction.filterProps = ['xs', 'sm', 'md', 'lg', 'xl', ...styleFunction.filterProps];\n return newStyleFunction;\n}\nexport function createEmptyBreakpointObject(breakpointsInput = {}) {\n var _breakpointsInput$key;\n const breakpointsInOrder = (_breakpointsInput$key = breakpointsInput.keys) == null ? void 0 : _breakpointsInput$key.reduce((acc, key) => {\n const breakpointStyleKey = breakpointsInput.up(key);\n acc[breakpointStyleKey] = {};\n return acc;\n }, {});\n return breakpointsInOrder || {};\n}\nexport function removeUnusedBreakpoints(breakpointKeys, style) {\n return breakpointKeys.reduce((acc, key) => {\n const breakpointOutput = acc[key];\n const isBreakpointUnused = !breakpointOutput || Object.keys(breakpointOutput).length === 0;\n if (isBreakpointUnused) {\n delete acc[key];\n }\n return acc;\n }, style);\n}\nexport function mergeBreakpointsInOrder(breakpointsInput, ...styles) {\n const emptyBreakpoints = createEmptyBreakpointObject(breakpointsInput);\n const mergedOutput = [emptyBreakpoints, ...styles].reduce((prev, next) => deepmerge(prev, next), {});\n return removeUnusedBreakpoints(Object.keys(emptyBreakpoints), mergedOutput);\n}\n\n// compute base for responsive values; e.g.,\n// [1,2,3] => {xs: true, sm: true, md: true}\n// {xs: 1, sm: 2, md: 3} => {xs: true, sm: true, md: true}\nexport function computeBreakpointsBase(breakpointValues, themeBreakpoints) {\n // fixed value\n if (typeof breakpointValues !== 'object') {\n return {};\n }\n const base = {};\n const breakpointsKeys = Object.keys(themeBreakpoints);\n if (Array.isArray(breakpointValues)) {\n breakpointsKeys.forEach((breakpoint, i) => {\n if (i < breakpointValues.length) {\n base[breakpoint] = true;\n }\n });\n } else {\n breakpointsKeys.forEach(breakpoint => {\n if (breakpointValues[breakpoint] != null) {\n base[breakpoint] = true;\n }\n });\n }\n return base;\n}\nexport function resolveBreakpointValues({\n values: breakpointValues,\n breakpoints: themeBreakpoints,\n base: customBase\n}) {\n const base = customBase || computeBreakpointsBase(breakpointValues, themeBreakpoints);\n const keys = Object.keys(base);\n if (keys.length === 0) {\n return breakpointValues;\n }\n let previous;\n return keys.reduce((acc, breakpoint, i) => {\n if (Array.isArray(breakpointValues)) {\n acc[breakpoint] = breakpointValues[i] != null ? breakpointValues[i] : breakpointValues[previous];\n previous = i;\n } else if (typeof breakpointValues === 'object') {\n acc[breakpoint] = breakpointValues[breakpoint] != null ? breakpointValues[breakpoint] : breakpointValues[previous];\n previous = breakpoint;\n } else {\n acc[breakpoint] = breakpointValues;\n }\n return acc;\n }, {});\n}\nexport default breakpoints;","import capitalize from '@mui/utils/capitalize';\nimport responsivePropType from './responsivePropType';\nimport { handleBreakpoints } from './breakpoints';\nexport function getPath(obj, path, checkVars = true) {\n if (!path || typeof path !== 'string') {\n return null;\n }\n\n // Check if CSS variables are used\n if (obj && obj.vars && checkVars) {\n const val = `vars.${path}`.split('.').reduce((acc, item) => acc && acc[item] ? acc[item] : null, obj);\n if (val != null) {\n return val;\n }\n }\n return path.split('.').reduce((acc, item) => {\n if (acc && acc[item] != null) {\n return acc[item];\n }\n return null;\n }, obj);\n}\nexport function getStyleValue(themeMapping, transform, propValueFinal, userValue = propValueFinal) {\n let value;\n if (typeof themeMapping === 'function') {\n value = themeMapping(propValueFinal);\n } else if (Array.isArray(themeMapping)) {\n value = themeMapping[propValueFinal] || userValue;\n } else {\n value = getPath(themeMapping, propValueFinal) || userValue;\n }\n if (transform) {\n value = transform(value, userValue, themeMapping);\n }\n return value;\n}\nfunction style(options) {\n const {\n prop,\n cssProperty = options.prop,\n themeKey,\n transform\n } = options;\n\n // false positive\n // eslint-disable-next-line react/function-component-definition\n const fn = props => {\n if (props[prop] == null) {\n return null;\n }\n const propValue = props[prop];\n const theme = props.theme;\n const themeMapping = getPath(theme, themeKey) || {};\n const styleFromPropValue = propValueFinal => {\n let value = getStyleValue(themeMapping, transform, propValueFinal);\n if (propValueFinal === value && typeof propValueFinal === 'string') {\n // Haven't found value\n value = getStyleValue(themeMapping, transform, `${prop}${propValueFinal === 'default' ? '' : capitalize(propValueFinal)}`, propValueFinal);\n }\n if (cssProperty === false) {\n return value;\n }\n return {\n [cssProperty]: value\n };\n };\n return handleBreakpoints(props, propValue, styleFromPropValue);\n };\n fn.propTypes = process.env.NODE_ENV !== 'production' ? {\n [prop]: responsivePropType\n } : {};\n fn.filterProps = [prop];\n return fn;\n}\nexport default style;","export default function memoize(fn) {\n const cache = {};\n return arg => {\n if (cache[arg] === undefined) {\n cache[arg] = fn(arg);\n }\n return cache[arg];\n };\n}","import responsivePropType from './responsivePropType';\nimport { handleBreakpoints } from './breakpoints';\nimport { getPath } from './style';\nimport merge from './merge';\nimport memoize from './memoize';\nconst properties = {\n m: 'margin',\n p: 'padding'\n};\nconst directions = {\n t: 'Top',\n r: 'Right',\n b: 'Bottom',\n l: 'Left',\n x: ['Left', 'Right'],\n y: ['Top', 'Bottom']\n};\nconst aliases = {\n marginX: 'mx',\n marginY: 'my',\n paddingX: 'px',\n paddingY: 'py'\n};\n\n// memoize() impact:\n// From 300,000 ops/sec\n// To 350,000 ops/sec\nconst getCssProperties = memoize(prop => {\n // It's not a shorthand notation.\n if (prop.length > 2) {\n if (aliases[prop]) {\n prop = aliases[prop];\n } else {\n return [prop];\n }\n }\n const [a, b] = prop.split('');\n const property = properties[a];\n const direction = directions[b] || '';\n return Array.isArray(direction) ? direction.map(dir => property + dir) : [property + direction];\n});\nexport const marginKeys = ['m', 'mt', 'mr', 'mb', 'ml', 'mx', 'my', 'margin', 'marginTop', 'marginRight', 'marginBottom', 'marginLeft', 'marginX', 'marginY', 'marginInline', 'marginInlineStart', 'marginInlineEnd', 'marginBlock', 'marginBlockStart', 'marginBlockEnd'];\nexport const paddingKeys = ['p', 'pt', 'pr', 'pb', 'pl', 'px', 'py', 'padding', 'paddingTop', 'paddingRight', 'paddingBottom', 'paddingLeft', 'paddingX', 'paddingY', 'paddingInline', 'paddingInlineStart', 'paddingInlineEnd', 'paddingBlock', 'paddingBlockStart', 'paddingBlockEnd'];\nconst spacingKeys = [...marginKeys, ...paddingKeys];\nexport function createUnaryUnit(theme, themeKey, defaultValue, propName) {\n var _getPath;\n const themeSpacing = (_getPath = getPath(theme, themeKey, false)) != null ? _getPath : defaultValue;\n if (typeof themeSpacing === 'number') {\n return abs => {\n if (typeof abs === 'string') {\n return abs;\n }\n if (process.env.NODE_ENV !== 'production') {\n if (typeof abs !== 'number') {\n console.error(`MUI: Expected ${propName} argument to be a number or a string, got ${abs}.`);\n }\n }\n return themeSpacing * abs;\n };\n }\n if (Array.isArray(themeSpacing)) {\n return abs => {\n if (typeof abs === 'string') {\n return abs;\n }\n if (process.env.NODE_ENV !== 'production') {\n if (!Number.isInteger(abs)) {\n console.error([`MUI: The \\`theme.${themeKey}\\` array type cannot be combined with non integer values.` + `You should either use an integer value that can be used as index, or define the \\`theme.${themeKey}\\` as a number.`].join('\\n'));\n } else if (abs > themeSpacing.length - 1) {\n console.error([`MUI: The value provided (${abs}) overflows.`, `The supported values are: ${JSON.stringify(themeSpacing)}.`, `${abs} > ${themeSpacing.length - 1}, you need to add the missing values.`].join('\\n'));\n }\n }\n return themeSpacing[abs];\n };\n }\n if (typeof themeSpacing === 'function') {\n return themeSpacing;\n }\n if (process.env.NODE_ENV !== 'production') {\n console.error([`MUI: The \\`theme.${themeKey}\\` value (${themeSpacing}) is invalid.`, 'It should be a number, an array or a function.'].join('\\n'));\n }\n return () => undefined;\n}\nexport function createUnarySpacing(theme) {\n return createUnaryUnit(theme, 'spacing', 8, 'spacing');\n}\nexport function getValue(transformer, propValue) {\n if (typeof propValue === 'string' || propValue == null) {\n return propValue;\n }\n const abs = Math.abs(propValue);\n const transformed = transformer(abs);\n if (propValue >= 0) {\n return transformed;\n }\n if (typeof transformed === 'number') {\n return -transformed;\n }\n return `-${transformed}`;\n}\nexport function getStyleFromPropValue(cssProperties, transformer) {\n return propValue => cssProperties.reduce((acc, cssProperty) => {\n acc[cssProperty] = getValue(transformer, propValue);\n return acc;\n }, {});\n}\nfunction resolveCssProperty(props, keys, prop, transformer) {\n // Using a hash computation over an array iteration could be faster, but with only 28 items,\n // it's doesn't worth the bundle size.\n if (keys.indexOf(prop) === -1) {\n return null;\n }\n const cssProperties = getCssProperties(prop);\n const styleFromPropValue = getStyleFromPropValue(cssProperties, transformer);\n const propValue = props[prop];\n return handleBreakpoints(props, propValue, styleFromPropValue);\n}\nfunction style(props, keys) {\n const transformer = createUnarySpacing(props.theme);\n return Object.keys(props).map(prop => resolveCssProperty(props, keys, prop, transformer)).reduce(merge, {});\n}\nexport function margin(props) {\n return style(props, marginKeys);\n}\nmargin.propTypes = process.env.NODE_ENV !== 'production' ? marginKeys.reduce((obj, key) => {\n obj[key] = responsivePropType;\n return obj;\n}, {}) : {};\nmargin.filterProps = marginKeys;\nexport function padding(props) {\n return style(props, paddingKeys);\n}\npadding.propTypes = process.env.NODE_ENV !== 'production' ? paddingKeys.reduce((obj, key) => {\n obj[key] = responsivePropType;\n return obj;\n}, {}) : {};\npadding.filterProps = paddingKeys;\nfunction spacing(props) {\n return style(props, spacingKeys);\n}\nspacing.propTypes = process.env.NODE_ENV !== 'production' ? spacingKeys.reduce((obj, key) => {\n obj[key] = responsivePropType;\n return obj;\n}, {}) : {};\nspacing.filterProps = spacingKeys;\nexport default spacing;","import { createUnarySpacing } from '../spacing';\n\n// The different signatures imply different meaning for their arguments that can't be expressed structurally.\n// We express the difference with variable names.\n\nexport default function createSpacing(spacingInput = 8) {\n // Already transformed.\n if (spacingInput.mui) {\n return spacingInput;\n }\n\n // Material Design layouts are visually balanced. Most measurements align to an 8dp grid, which aligns both spacing and the overall layout.\n // Smaller components, such as icons, can align to a 4dp grid.\n // https://m2.material.io/design/layout/understanding-layout.html\n const transform = createUnarySpacing({\n spacing: spacingInput\n });\n const spacing = (...argsInput) => {\n if (process.env.NODE_ENV !== 'production') {\n if (!(argsInput.length <= 4)) {\n console.error(`MUI: Too many arguments provided, expected between 0 and 4, got ${argsInput.length}`);\n }\n }\n const args = argsInput.length === 0 ? [1] : argsInput;\n return args.map(argument => {\n const output = transform(argument);\n return typeof output === 'number' ? `${output}px` : output;\n }).join(' ');\n };\n spacing.mui = true;\n return spacing;\n}","import merge from './merge';\nfunction compose(...styles) {\n const handlers = styles.reduce((acc, style) => {\n style.filterProps.forEach(prop => {\n acc[prop] = style;\n });\n return acc;\n }, {});\n\n // false positive\n // eslint-disable-next-line react/function-component-definition\n const fn = props => {\n return Object.keys(props).reduce((acc, prop) => {\n if (handlers[prop]) {\n return merge(acc, handlers[prop](props));\n }\n return acc;\n }, {});\n };\n fn.propTypes = process.env.NODE_ENV !== 'production' ? styles.reduce((acc, style) => Object.assign(acc, style.propTypes), {}) : {};\n fn.filterProps = styles.reduce((acc, style) => acc.concat(style.filterProps), []);\n return fn;\n}\nexport default compose;","import responsivePropType from './responsivePropType';\nimport style from './style';\nimport compose from './compose';\nimport { createUnaryUnit, getValue } from './spacing';\nimport { handleBreakpoints } from './breakpoints';\nexport function borderTransform(value) {\n if (typeof value !== 'number') {\n return value;\n }\n return `${value}px solid`;\n}\nfunction createBorderStyle(prop, transform) {\n return style({\n prop,\n themeKey: 'borders',\n transform\n });\n}\nexport const border = createBorderStyle('border', borderTransform);\nexport const borderTop = createBorderStyle('borderTop', borderTransform);\nexport const borderRight = createBorderStyle('borderRight', borderTransform);\nexport const borderBottom = createBorderStyle('borderBottom', borderTransform);\nexport const borderLeft = createBorderStyle('borderLeft', borderTransform);\nexport const borderColor = createBorderStyle('borderColor');\nexport const borderTopColor = createBorderStyle('borderTopColor');\nexport const borderRightColor = createBorderStyle('borderRightColor');\nexport const borderBottomColor = createBorderStyle('borderBottomColor');\nexport const borderLeftColor = createBorderStyle('borderLeftColor');\nexport const outline = createBorderStyle('outline', borderTransform);\nexport const outlineColor = createBorderStyle('outlineColor');\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const borderRadius = props => {\n if (props.borderRadius !== undefined && props.borderRadius !== null) {\n const transformer = createUnaryUnit(props.theme, 'shape.borderRadius', 4, 'borderRadius');\n const styleFromPropValue = propValue => ({\n borderRadius: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.borderRadius, styleFromPropValue);\n }\n return null;\n};\nborderRadius.propTypes = process.env.NODE_ENV !== 'production' ? {\n borderRadius: responsivePropType\n} : {};\nborderRadius.filterProps = ['borderRadius'];\nconst borders = compose(border, borderTop, borderRight, borderBottom, borderLeft, borderColor, borderTopColor, borderRightColor, borderBottomColor, borderLeftColor, borderRadius, outline, outlineColor);\nexport default borders;","import style from './style';\nimport compose from './compose';\nimport { createUnaryUnit, getValue } from './spacing';\nimport { handleBreakpoints } from './breakpoints';\nimport responsivePropType from './responsivePropType';\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const gap = props => {\n if (props.gap !== undefined && props.gap !== null) {\n const transformer = createUnaryUnit(props.theme, 'spacing', 8, 'gap');\n const styleFromPropValue = propValue => ({\n gap: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.gap, styleFromPropValue);\n }\n return null;\n};\ngap.propTypes = process.env.NODE_ENV !== 'production' ? {\n gap: responsivePropType\n} : {};\ngap.filterProps = ['gap'];\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const columnGap = props => {\n if (props.columnGap !== undefined && props.columnGap !== null) {\n const transformer = createUnaryUnit(props.theme, 'spacing', 8, 'columnGap');\n const styleFromPropValue = propValue => ({\n columnGap: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.columnGap, styleFromPropValue);\n }\n return null;\n};\ncolumnGap.propTypes = process.env.NODE_ENV !== 'production' ? {\n columnGap: responsivePropType\n} : {};\ncolumnGap.filterProps = ['columnGap'];\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const rowGap = props => {\n if (props.rowGap !== undefined && props.rowGap !== null) {\n const transformer = createUnaryUnit(props.theme, 'spacing', 8, 'rowGap');\n const styleFromPropValue = propValue => ({\n rowGap: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.rowGap, styleFromPropValue);\n }\n return null;\n};\nrowGap.propTypes = process.env.NODE_ENV !== 'production' ? {\n rowGap: responsivePropType\n} : {};\nrowGap.filterProps = ['rowGap'];\nexport const gridColumn = style({\n prop: 'gridColumn'\n});\nexport const gridRow = style({\n prop: 'gridRow'\n});\nexport const gridAutoFlow = style({\n prop: 'gridAutoFlow'\n});\nexport const gridAutoColumns = style({\n prop: 'gridAutoColumns'\n});\nexport const gridAutoRows = style({\n prop: 'gridAutoRows'\n});\nexport const gridTemplateColumns = style({\n prop: 'gridTemplateColumns'\n});\nexport const gridTemplateRows = style({\n prop: 'gridTemplateRows'\n});\nexport const gridTemplateAreas = style({\n prop: 'gridTemplateAreas'\n});\nexport const gridArea = style({\n prop: 'gridArea'\n});\nconst grid = compose(gap, columnGap, rowGap, gridColumn, gridRow, gridAutoFlow, gridAutoColumns, gridAutoRows, gridTemplateColumns, gridTemplateRows, gridTemplateAreas, gridArea);\nexport default grid;","import style from './style';\nimport compose from './compose';\nexport function paletteTransform(value, userValue) {\n if (userValue === 'grey') {\n return userValue;\n }\n return value;\n}\nexport const color = style({\n prop: 'color',\n themeKey: 'palette',\n transform: paletteTransform\n});\nexport const bgcolor = style({\n prop: 'bgcolor',\n cssProperty: 'backgroundColor',\n themeKey: 'palette',\n transform: paletteTransform\n});\nexport const backgroundColor = style({\n prop: 'backgroundColor',\n themeKey: 'palette',\n transform: paletteTransform\n});\nconst palette = compose(color, bgcolor, backgroundColor);\nexport default palette;","import style from './style';\nimport compose from './compose';\nimport { handleBreakpoints, values as breakpointsValues } from './breakpoints';\nexport function sizingTransform(value) {\n return value <= 1 && value !== 0 ? `${value * 100}%` : value;\n}\nexport const width = style({\n prop: 'width',\n transform: sizingTransform\n});\nexport const maxWidth = props => {\n if (props.maxWidth !== undefined && props.maxWidth !== null) {\n const styleFromPropValue = propValue => {\n var _props$theme, _props$theme2;\n const breakpoint = ((_props$theme = props.theme) == null || (_props$theme = _props$theme.breakpoints) == null || (_props$theme = _props$theme.values) == null ? void 0 : _props$theme[propValue]) || breakpointsValues[propValue];\n if (!breakpoint) {\n return {\n maxWidth: sizingTransform(propValue)\n };\n }\n if (((_props$theme2 = props.theme) == null || (_props$theme2 = _props$theme2.breakpoints) == null ? void 0 : _props$theme2.unit) !== 'px') {\n return {\n maxWidth: `${breakpoint}${props.theme.breakpoints.unit}`\n };\n }\n return {\n maxWidth: breakpoint\n };\n };\n return handleBreakpoints(props, props.maxWidth, styleFromPropValue);\n }\n return null;\n};\nmaxWidth.filterProps = ['maxWidth'];\nexport const minWidth = style({\n prop: 'minWidth',\n transform: sizingTransform\n});\nexport const height = style({\n prop: 'height',\n transform: sizingTransform\n});\nexport const maxHeight = style({\n prop: 'maxHeight',\n transform: sizingTransform\n});\nexport const minHeight = style({\n prop: 'minHeight',\n transform: sizingTransform\n});\nexport const sizeWidth = style({\n prop: 'size',\n cssProperty: 'width',\n transform: sizingTransform\n});\nexport const sizeHeight = style({\n prop: 'size',\n cssProperty: 'height',\n transform: sizingTransform\n});\nexport const boxSizing = style({\n prop: 'boxSizing'\n});\nconst sizing = compose(width, maxWidth, minWidth, height, maxHeight, minHeight, boxSizing);\nexport default sizing;","import { padding, margin } from '../spacing';\nimport { borderRadius, borderTransform } from '../borders';\nimport { gap, rowGap, columnGap } from '../cssGrid';\nimport { paletteTransform } from '../palette';\nimport { maxWidth, sizingTransform } from '../sizing';\nconst defaultSxConfig = {\n // borders\n border: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderTop: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderRight: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderBottom: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderLeft: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderColor: {\n themeKey: 'palette'\n },\n borderTopColor: {\n themeKey: 'palette'\n },\n borderRightColor: {\n themeKey: 'palette'\n },\n borderBottomColor: {\n themeKey: 'palette'\n },\n borderLeftColor: {\n themeKey: 'palette'\n },\n outline: {\n themeKey: 'borders',\n transform: borderTransform\n },\n outlineColor: {\n themeKey: 'palette'\n },\n borderRadius: {\n themeKey: 'shape.borderRadius',\n style: borderRadius\n },\n // palette\n color: {\n themeKey: 'palette',\n transform: paletteTransform\n },\n bgcolor: {\n themeKey: 'palette',\n cssProperty: 'backgroundColor',\n transform: paletteTransform\n },\n backgroundColor: {\n themeKey: 'palette',\n transform: paletteTransform\n },\n // spacing\n p: {\n style: padding\n },\n pt: {\n style: padding\n },\n pr: {\n style: padding\n },\n pb: {\n style: padding\n },\n pl: {\n style: padding\n },\n px: {\n style: padding\n },\n py: {\n style: padding\n },\n padding: {\n style: padding\n },\n paddingTop: {\n style: padding\n },\n paddingRight: {\n style: padding\n },\n paddingBottom: {\n style: padding\n },\n paddingLeft: {\n style: padding\n },\n paddingX: {\n style: padding\n },\n paddingY: {\n style: padding\n },\n paddingInline: {\n style: padding\n },\n paddingInlineStart: {\n style: padding\n },\n paddingInlineEnd: {\n style: padding\n },\n paddingBlock: {\n style: padding\n },\n paddingBlockStart: {\n style: padding\n },\n paddingBlockEnd: {\n style: padding\n },\n m: {\n style: margin\n },\n mt: {\n style: margin\n },\n mr: {\n style: margin\n },\n mb: {\n style: margin\n },\n ml: {\n style: margin\n },\n mx: {\n style: margin\n },\n my: {\n style: margin\n },\n margin: {\n style: margin\n },\n marginTop: {\n style: margin\n },\n marginRight: {\n style: margin\n },\n marginBottom: {\n style: margin\n },\n marginLeft: {\n style: margin\n },\n marginX: {\n style: margin\n },\n marginY: {\n style: margin\n },\n marginInline: {\n style: margin\n },\n marginInlineStart: {\n style: margin\n },\n marginInlineEnd: {\n style: margin\n },\n marginBlock: {\n style: margin\n },\n marginBlockStart: {\n style: margin\n },\n marginBlockEnd: {\n style: margin\n },\n // display\n displayPrint: {\n cssProperty: false,\n transform: value => ({\n '@media print': {\n display: value\n }\n })\n },\n display: {},\n overflow: {},\n textOverflow: {},\n visibility: {},\n whiteSpace: {},\n // flexbox\n flexBasis: {},\n flexDirection: {},\n flexWrap: {},\n justifyContent: {},\n alignItems: {},\n alignContent: {},\n order: {},\n flex: {},\n flexGrow: {},\n flexShrink: {},\n alignSelf: {},\n justifyItems: {},\n justifySelf: {},\n // grid\n gap: {\n style: gap\n },\n rowGap: {\n style: rowGap\n },\n columnGap: {\n style: columnGap\n },\n gridColumn: {},\n gridRow: {},\n gridAutoFlow: {},\n gridAutoColumns: {},\n gridAutoRows: {},\n gridTemplateColumns: {},\n gridTemplateRows: {},\n gridTemplateAreas: {},\n gridArea: {},\n // positions\n position: {},\n zIndex: {\n themeKey: 'zIndex'\n },\n top: {},\n right: {},\n bottom: {},\n left: {},\n // shadows\n boxShadow: {\n themeKey: 'shadows'\n },\n // sizing\n width: {\n transform: sizingTransform\n },\n maxWidth: {\n style: maxWidth\n },\n minWidth: {\n transform: sizingTransform\n },\n height: {\n transform: sizingTransform\n },\n maxHeight: {\n transform: sizingTransform\n },\n minHeight: {\n transform: sizingTransform\n },\n boxSizing: {},\n // typography\n fontFamily: {\n themeKey: 'typography'\n },\n fontSize: {\n themeKey: 'typography'\n },\n fontStyle: {\n themeKey: 'typography'\n },\n fontWeight: {\n themeKey: 'typography'\n },\n letterSpacing: {},\n textTransform: {},\n lineHeight: {},\n textAlign: {},\n typography: {\n cssProperty: false,\n themeKey: 'typography'\n }\n};\nexport default defaultSxConfig;","import capitalize from '@mui/utils/capitalize';\nimport merge from '../merge';\nimport { getPath, getStyleValue as getValue } from '../style';\nimport { handleBreakpoints, createEmptyBreakpointObject, removeUnusedBreakpoints } from '../breakpoints';\nimport defaultSxConfig from './defaultSxConfig';\nfunction objectsHaveSameKeys(...objects) {\n const allKeys = objects.reduce((keys, object) => keys.concat(Object.keys(object)), []);\n const union = new Set(allKeys);\n return objects.every(object => union.size === Object.keys(object).length);\n}\nfunction callIfFn(maybeFn, arg) {\n return typeof maybeFn === 'function' ? maybeFn(arg) : maybeFn;\n}\n\n// eslint-disable-next-line @typescript-eslint/naming-convention\nexport function unstable_createStyleFunctionSx() {\n function getThemeValue(prop, val, theme, config) {\n const props = {\n [prop]: val,\n theme\n };\n const options = config[prop];\n if (!options) {\n return {\n [prop]: val\n };\n }\n const {\n cssProperty = prop,\n themeKey,\n transform,\n style\n } = options;\n if (val == null) {\n return null;\n }\n\n // TODO v6: remove, see https://github.com/mui/material-ui/pull/38123\n if (themeKey === 'typography' && val === 'inherit') {\n return {\n [prop]: val\n };\n }\n const themeMapping = getPath(theme, themeKey) || {};\n if (style) {\n return style(props);\n }\n const styleFromPropValue = propValueFinal => {\n let value = getValue(themeMapping, transform, propValueFinal);\n if (propValueFinal === value && typeof propValueFinal === 'string') {\n // Haven't found value\n value = getValue(themeMapping, transform, `${prop}${propValueFinal === 'default' ? '' : capitalize(propValueFinal)}`, propValueFinal);\n }\n if (cssProperty === false) {\n return value;\n }\n return {\n [cssProperty]: value\n };\n };\n return handleBreakpoints(props, val, styleFromPropValue);\n }\n function styleFunctionSx(props) {\n var _theme$unstable_sxCon;\n const {\n sx,\n theme = {}\n } = props || {};\n if (!sx) {\n return null; // Emotion & styled-components will neglect null\n }\n const config = (_theme$unstable_sxCon = theme.unstable_sxConfig) != null ? _theme$unstable_sxCon : defaultSxConfig;\n\n /*\n * Receive `sxInput` as object or callback\n * and then recursively check keys & values to create media query object styles.\n * (the result will be used in `styled`)\n */\n function traverse(sxInput) {\n let sxObject = sxInput;\n if (typeof sxInput === 'function') {\n sxObject = sxInput(theme);\n } else if (typeof sxInput !== 'object') {\n // value\n return sxInput;\n }\n if (!sxObject) {\n return null;\n }\n const emptyBreakpoints = createEmptyBreakpointObject(theme.breakpoints);\n const breakpointsKeys = Object.keys(emptyBreakpoints);\n let css = emptyBreakpoints;\n Object.keys(sxObject).forEach(styleKey => {\n const value = callIfFn(sxObject[styleKey], theme);\n if (value !== null && value !== undefined) {\n if (typeof value === 'object') {\n if (config[styleKey]) {\n css = merge(css, getThemeValue(styleKey, value, theme, config));\n } else {\n const breakpointsValues = handleBreakpoints({\n theme\n }, value, x => ({\n [styleKey]: x\n }));\n if (objectsHaveSameKeys(breakpointsValues, value)) {\n css[styleKey] = styleFunctionSx({\n sx: value,\n theme\n });\n } else {\n css = merge(css, breakpointsValues);\n }\n }\n } else {\n css = merge(css, getThemeValue(styleKey, value, theme, config));\n }\n }\n });\n return removeUnusedBreakpoints(breakpointsKeys, css);\n }\n return Array.isArray(sx) ? sx.map(traverse) : traverse(sx);\n }\n return styleFunctionSx;\n}\nconst styleFunctionSx = unstable_createStyleFunctionSx();\nstyleFunctionSx.filterProps = ['sx'];\nexport default styleFunctionSx;","/**\n * A universal utility to style components with multiple color modes. Always use it from the theme object.\n * It works with:\n * - [Basic theme](https://mui.com/material-ui/customization/dark-mode/)\n * - [CSS theme variables](https://mui.com/material-ui/experimental-api/css-theme-variables/overview/)\n * - Zero-runtime engine\n *\n * Tips: Use an array over object spread and place `theme.applyStyles()` last.\n *\n * ✅ [{ background: '#e5e5e5' }, theme.applyStyles('dark', { background: '#1c1c1c' })]\n *\n * 🚫 { background: '#e5e5e5', ...theme.applyStyles('dark', { background: '#1c1c1c' })}\n *\n * @example\n * 1. using with `styled`:\n * ```jsx\n * const Component = styled('div')(({ theme }) => [\n * { background: '#e5e5e5' },\n * theme.applyStyles('dark', {\n * background: '#1c1c1c',\n * color: '#fff',\n * }),\n * ]);\n * ```\n *\n * @example\n * 2. using with `sx` prop:\n * ```jsx\n * [\n * { background: '#e5e5e5' },\n * theme.applyStyles('dark', {\n * background: '#1c1c1c',\n * color: '#fff',\n * }),\n * ]}\n * />\n * ```\n *\n * @example\n * 3. theming a component:\n * ```jsx\n * extendTheme({\n * components: {\n * MuiButton: {\n * styleOverrides: {\n * root: ({ theme }) => [\n * { background: '#e5e5e5' },\n * theme.applyStyles('dark', {\n * background: '#1c1c1c',\n * color: '#fff',\n * }),\n * ],\n * },\n * }\n * }\n * })\n *```\n */\nexport default function applyStyles(key, styles) {\n // @ts-expect-error this is 'any' type\n const theme = this;\n if (theme.vars && typeof theme.getColorSchemeSelector === 'function') {\n // If CssVarsProvider is used as a provider,\n // returns '* :where([data-mui-color-scheme=\"light|dark\"]) &'\n const selector = theme.getColorSchemeSelector(key).replace(/(\\[[^\\]]+\\])/, '*:where($1)');\n return {\n [selector]: styles\n };\n }\n if (theme.palette.mode === key) {\n return styles;\n }\n return {};\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"breakpoints\", \"palette\", \"spacing\", \"shape\"];\nimport deepmerge from '@mui/utils/deepmerge';\nimport createBreakpoints from './createBreakpoints';\nimport shape from './shape';\nimport createSpacing from './createSpacing';\nimport styleFunctionSx from '../styleFunctionSx/styleFunctionSx';\nimport defaultSxConfig from '../styleFunctionSx/defaultSxConfig';\nimport applyStyles from './applyStyles';\nfunction createTheme(options = {}, ...args) {\n const {\n breakpoints: breakpointsInput = {},\n palette: paletteInput = {},\n spacing: spacingInput,\n shape: shapeInput = {}\n } = options,\n other = _objectWithoutPropertiesLoose(options, _excluded);\n const breakpoints = createBreakpoints(breakpointsInput);\n const spacing = createSpacing(spacingInput);\n let muiTheme = deepmerge({\n breakpoints,\n direction: 'ltr',\n components: {},\n // Inject component definitions.\n palette: _extends({\n mode: 'light'\n }, paletteInput),\n spacing,\n shape: _extends({}, shape, shapeInput)\n }, other);\n muiTheme.applyStyles = applyStyles;\n muiTheme = args.reduce((acc, argument) => deepmerge(acc, argument), muiTheme);\n muiTheme.unstable_sxConfig = _extends({}, defaultSxConfig, other == null ? void 0 : other.unstable_sxConfig);\n muiTheme.unstable_sx = function sx(props) {\n return styleFunctionSx({\n sx: props,\n theme: this\n });\n };\n return muiTheme;\n}\nexport default createTheme;","'use client';\n\nimport * as React from 'react';\nimport { ThemeContext } from '@mui/styled-engine';\nfunction isObjectEmpty(obj) {\n return Object.keys(obj).length === 0;\n}\nfunction useTheme(defaultTheme = null) {\n const contextTheme = React.useContext(ThemeContext);\n return !contextTheme || isObjectEmpty(contextTheme) ? defaultTheme : contextTheme;\n}\nexport default useTheme;","'use client';\n\nimport createTheme from './createTheme';\nimport useThemeWithoutDefault from './useThemeWithoutDefault';\nexport const systemDefaultTheme = createTheme();\nfunction useTheme(defaultTheme = systemDefaultTheme) {\n return useThemeWithoutDefault(defaultTheme);\n}\nexport default useTheme;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"ownerState\"],\n _excluded2 = [\"variants\"],\n _excluded3 = [\"name\", \"slot\", \"skipVariantsResolver\", \"skipSx\", \"overridesResolver\"];\n/* eslint-disable no-underscore-dangle */\nimport styledEngineStyled, { internal_processStyles as processStyles } from '@mui/styled-engine';\nimport { isPlainObject } from '@mui/utils/deepmerge';\nimport capitalize from '@mui/utils/capitalize';\nimport getDisplayName from '@mui/utils/getDisplayName';\nimport createTheme from './createTheme';\nimport styleFunctionSx from './styleFunctionSx';\nfunction isEmpty(obj) {\n return Object.keys(obj).length === 0;\n}\n\n// https://github.com/emotion-js/emotion/blob/26ded6109fcd8ca9875cc2ce4564fee678a3f3c5/packages/styled/src/utils.js#L40\nfunction isStringTag(tag) {\n return typeof tag === 'string' &&\n // 96 is one less than the char code\n // for \"a\" so this is checking that\n // it's a lowercase character\n tag.charCodeAt(0) > 96;\n}\n\n// Update /system/styled/#api in case if this changes\nexport function shouldForwardProp(prop) {\n return prop !== 'ownerState' && prop !== 'theme' && prop !== 'sx' && prop !== 'as';\n}\nexport const systemDefaultTheme = createTheme();\nconst lowercaseFirstLetter = string => {\n if (!string) {\n return string;\n }\n return string.charAt(0).toLowerCase() + string.slice(1);\n};\nfunction resolveTheme({\n defaultTheme,\n theme,\n themeId\n}) {\n return isEmpty(theme) ? defaultTheme : theme[themeId] || theme;\n}\nfunction defaultOverridesResolver(slot) {\n if (!slot) {\n return null;\n }\n return (props, styles) => styles[slot];\n}\nfunction processStyleArg(callableStyle, _ref) {\n let {\n ownerState\n } = _ref,\n props = _objectWithoutPropertiesLoose(_ref, _excluded);\n const resolvedStylesArg = typeof callableStyle === 'function' ? callableStyle(_extends({\n ownerState\n }, props)) : callableStyle;\n if (Array.isArray(resolvedStylesArg)) {\n return resolvedStylesArg.flatMap(resolvedStyle => processStyleArg(resolvedStyle, _extends({\n ownerState\n }, props)));\n }\n if (!!resolvedStylesArg && typeof resolvedStylesArg === 'object' && Array.isArray(resolvedStylesArg.variants)) {\n const {\n variants = []\n } = resolvedStylesArg,\n otherStyles = _objectWithoutPropertiesLoose(resolvedStylesArg, _excluded2);\n let result = otherStyles;\n variants.forEach(variant => {\n let isMatch = true;\n if (typeof variant.props === 'function') {\n isMatch = variant.props(_extends({\n ownerState\n }, props, ownerState));\n } else {\n Object.keys(variant.props).forEach(key => {\n if ((ownerState == null ? void 0 : ownerState[key]) !== variant.props[key] && props[key] !== variant.props[key]) {\n isMatch = false;\n }\n });\n }\n if (isMatch) {\n if (!Array.isArray(result)) {\n result = [result];\n }\n result.push(typeof variant.style === 'function' ? variant.style(_extends({\n ownerState\n }, props, ownerState)) : variant.style);\n }\n });\n return result;\n }\n return resolvedStylesArg;\n}\nexport default function createStyled(input = {}) {\n const {\n themeId,\n defaultTheme = systemDefaultTheme,\n rootShouldForwardProp = shouldForwardProp,\n slotShouldForwardProp = shouldForwardProp\n } = input;\n const systemSx = props => {\n return styleFunctionSx(_extends({}, props, {\n theme: resolveTheme(_extends({}, props, {\n defaultTheme,\n themeId\n }))\n }));\n };\n systemSx.__mui_systemSx = true;\n return (tag, inputOptions = {}) => {\n // Filter out the `sx` style function from the previous styled component to prevent unnecessary styles generated by the composite components.\n processStyles(tag, styles => styles.filter(style => !(style != null && style.__mui_systemSx)));\n const {\n name: componentName,\n slot: componentSlot,\n skipVariantsResolver: inputSkipVariantsResolver,\n skipSx: inputSkipSx,\n // TODO v6: remove `lowercaseFirstLetter()` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n overridesResolver = defaultOverridesResolver(lowercaseFirstLetter(componentSlot))\n } = inputOptions,\n options = _objectWithoutPropertiesLoose(inputOptions, _excluded3);\n\n // if skipVariantsResolver option is defined, take the value, otherwise, true for root and false for other slots.\n const skipVariantsResolver = inputSkipVariantsResolver !== undefined ? inputSkipVariantsResolver :\n // TODO v6: remove `Root` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n componentSlot && componentSlot !== 'Root' && componentSlot !== 'root' || false;\n const skipSx = inputSkipSx || false;\n let label;\n if (process.env.NODE_ENV !== 'production') {\n if (componentName) {\n // TODO v6: remove `lowercaseFirstLetter()` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n label = `${componentName}-${lowercaseFirstLetter(componentSlot || 'Root')}`;\n }\n }\n let shouldForwardPropOption = shouldForwardProp;\n\n // TODO v6: remove `Root` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n if (componentSlot === 'Root' || componentSlot === 'root') {\n shouldForwardPropOption = rootShouldForwardProp;\n } else if (componentSlot) {\n // any other slot specified\n shouldForwardPropOption = slotShouldForwardProp;\n } else if (isStringTag(tag)) {\n // for string (html) tag, preserve the behavior in emotion & styled-components.\n shouldForwardPropOption = undefined;\n }\n const defaultStyledResolver = styledEngineStyled(tag, _extends({\n shouldForwardProp: shouldForwardPropOption,\n label\n }, options));\n const transformStyleArg = stylesArg => {\n // On the server Emotion doesn't use React.forwardRef for creating components, so the created\n // component stays as a function. This condition makes sure that we do not interpolate functions\n // which are basically components used as a selectors.\n if (typeof stylesArg === 'function' && stylesArg.__emotion_real !== stylesArg || isPlainObject(stylesArg)) {\n return props => processStyleArg(stylesArg, _extends({}, props, {\n theme: resolveTheme({\n theme: props.theme,\n defaultTheme,\n themeId\n })\n }));\n }\n return stylesArg;\n };\n const muiStyledResolver = (styleArg, ...expressions) => {\n let transformedStyleArg = transformStyleArg(styleArg);\n const expressionsWithDefaultTheme = expressions ? expressions.map(transformStyleArg) : [];\n if (componentName && overridesResolver) {\n expressionsWithDefaultTheme.push(props => {\n const theme = resolveTheme(_extends({}, props, {\n defaultTheme,\n themeId\n }));\n if (!theme.components || !theme.components[componentName] || !theme.components[componentName].styleOverrides) {\n return null;\n }\n const styleOverrides = theme.components[componentName].styleOverrides;\n const resolvedStyleOverrides = {};\n // TODO: v7 remove iteration and use `resolveStyleArg(styleOverrides[slot])` directly\n Object.entries(styleOverrides).forEach(([slotKey, slotStyle]) => {\n resolvedStyleOverrides[slotKey] = processStyleArg(slotStyle, _extends({}, props, {\n theme\n }));\n });\n return overridesResolver(props, resolvedStyleOverrides);\n });\n }\n if (componentName && !skipVariantsResolver) {\n expressionsWithDefaultTheme.push(props => {\n var _theme$components;\n const theme = resolveTheme(_extends({}, props, {\n defaultTheme,\n themeId\n }));\n const themeVariants = theme == null || (_theme$components = theme.components) == null || (_theme$components = _theme$components[componentName]) == null ? void 0 : _theme$components.variants;\n return processStyleArg({\n variants: themeVariants\n }, _extends({}, props, {\n theme\n }));\n });\n }\n if (!skipSx) {\n expressionsWithDefaultTheme.push(systemSx);\n }\n const numOfCustomFnsApplied = expressionsWithDefaultTheme.length - expressions.length;\n if (Array.isArray(styleArg) && numOfCustomFnsApplied > 0) {\n const placeholders = new Array(numOfCustomFnsApplied).fill('');\n // If the type is array, than we need to add placeholders in the template for the overrides, variants and the sx styles.\n transformedStyleArg = [...styleArg, ...placeholders];\n transformedStyleArg.raw = [...styleArg.raw, ...placeholders];\n }\n const Component = defaultStyledResolver(transformedStyleArg, ...expressionsWithDefaultTheme);\n if (process.env.NODE_ENV !== 'production') {\n let displayName;\n if (componentName) {\n displayName = `${componentName}${capitalize(componentSlot || '')}`;\n }\n if (displayName === undefined) {\n displayName = `Styled(${getDisplayName(tag)})`;\n }\n Component.displayName = displayName;\n }\n if (tag.muiName) {\n Component.muiName = tag.muiName;\n }\n return Component;\n };\n if (defaultStyledResolver.withConfig) {\n muiStyledResolver.withConfig = defaultStyledResolver.withConfig;\n }\n return muiStyledResolver;\n };\n}","import resolveProps from '@mui/utils/resolveProps';\nexport default function getThemeProps(params) {\n const {\n theme,\n name,\n props\n } = params;\n if (!theme || !theme.components || !theme.components[name] || !theme.components[name].defaultProps) {\n return props;\n }\n return resolveProps(theme.components[name].defaultProps, props);\n}","'use client';\n\nimport getThemeProps from './getThemeProps';\nimport useTheme from '../useTheme';\nexport default function useThemeProps({\n props,\n name,\n defaultTheme,\n themeId\n}) {\n let theme = useTheme(defaultTheme);\n if (themeId) {\n theme = theme[themeId] || theme;\n }\n const mergedProps = getThemeProps({\n theme,\n name,\n props\n });\n return mergedProps;\n}","import _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\n/* eslint-disable @typescript-eslint/naming-convention */\nimport clamp from '@mui/utils/clamp';\n/**\n * Returns a number whose value is limited to the given range.\n * @param {number} value The value to be clamped\n * @param {number} min The lower boundary of the output range\n * @param {number} max The upper boundary of the output range\n * @returns {number} A number in the range [min, max]\n */\nfunction clampWrapper(value, min = 0, max = 1) {\n if (process.env.NODE_ENV !== 'production') {\n if (value < min || value > max) {\n console.error(`MUI: The value provided ${value} is out of range [${min}, ${max}].`);\n }\n }\n return clamp(value, min, max);\n}\n\n/**\n * Converts a color from CSS hex format to CSS rgb format.\n * @param {string} color - Hex color, i.e. #nnn or #nnnnnn\n * @returns {string} A CSS rgb color string\n */\nexport function hexToRgb(color) {\n color = color.slice(1);\n const re = new RegExp(`.{1,${color.length >= 6 ? 2 : 1}}`, 'g');\n let colors = color.match(re);\n if (colors && colors[0].length === 1) {\n colors = colors.map(n => n + n);\n }\n return colors ? `rgb${colors.length === 4 ? 'a' : ''}(${colors.map((n, index) => {\n return index < 3 ? parseInt(n, 16) : Math.round(parseInt(n, 16) / 255 * 1000) / 1000;\n }).join(', ')})` : '';\n}\nfunction intToHex(int) {\n const hex = int.toString(16);\n return hex.length === 1 ? `0${hex}` : hex;\n}\n\n/**\n * Returns an object with the type and values of a color.\n *\n * Note: Does not support rgb % values.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @returns {object} - A MUI color object: {type: string, values: number[]}\n */\nexport function decomposeColor(color) {\n // Idempotent\n if (color.type) {\n return color;\n }\n if (color.charAt(0) === '#') {\n return decomposeColor(hexToRgb(color));\n }\n const marker = color.indexOf('(');\n const type = color.substring(0, marker);\n if (['rgb', 'rgba', 'hsl', 'hsla', 'color'].indexOf(type) === -1) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: Unsupported \\`${color}\\` color.\nThe following formats are supported: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color().` : _formatMuiErrorMessage(9, color));\n }\n let values = color.substring(marker + 1, color.length - 1);\n let colorSpace;\n if (type === 'color') {\n values = values.split(' ');\n colorSpace = values.shift();\n if (values.length === 4 && values[3].charAt(0) === '/') {\n values[3] = values[3].slice(1);\n }\n if (['srgb', 'display-p3', 'a98-rgb', 'prophoto-rgb', 'rec-2020'].indexOf(colorSpace) === -1) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: unsupported \\`${colorSpace}\\` color space.\nThe following color spaces are supported: srgb, display-p3, a98-rgb, prophoto-rgb, rec-2020.` : _formatMuiErrorMessage(10, colorSpace));\n }\n } else {\n values = values.split(',');\n }\n values = values.map(value => parseFloat(value));\n return {\n type,\n values,\n colorSpace\n };\n}\n\n/**\n * Returns a channel created from the input color.\n *\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @returns {string} - The channel for the color, that can be used in rgba or hsla colors\n */\nexport const colorChannel = color => {\n const decomposedColor = decomposeColor(color);\n return decomposedColor.values.slice(0, 3).map((val, idx) => decomposedColor.type.indexOf('hsl') !== -1 && idx !== 0 ? `${val}%` : val).join(' ');\n};\nexport const private_safeColorChannel = (color, warning) => {\n try {\n return colorChannel(color);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n};\n\n/**\n * Converts a color object with type and values to a string.\n * @param {object} color - Decomposed color\n * @param {string} color.type - One of: 'rgb', 'rgba', 'hsl', 'hsla', 'color'\n * @param {array} color.values - [n,n,n] or [n,n,n,n]\n * @returns {string} A CSS color string\n */\nexport function recomposeColor(color) {\n const {\n type,\n colorSpace\n } = color;\n let {\n values\n } = color;\n if (type.indexOf('rgb') !== -1) {\n // Only convert the first 3 values to int (i.e. not alpha)\n values = values.map((n, i) => i < 3 ? parseInt(n, 10) : n);\n } else if (type.indexOf('hsl') !== -1) {\n values[1] = `${values[1]}%`;\n values[2] = `${values[2]}%`;\n }\n if (type.indexOf('color') !== -1) {\n values = `${colorSpace} ${values.join(' ')}`;\n } else {\n values = `${values.join(', ')}`;\n }\n return `${type}(${values})`;\n}\n\n/**\n * Converts a color from CSS rgb format to CSS hex format.\n * @param {string} color - RGB color, i.e. rgb(n, n, n)\n * @returns {string} A CSS rgb color string, i.e. #nnnnnn\n */\nexport function rgbToHex(color) {\n // Idempotent\n if (color.indexOf('#') === 0) {\n return color;\n }\n const {\n values\n } = decomposeColor(color);\n return `#${values.map((n, i) => intToHex(i === 3 ? Math.round(255 * n) : n)).join('')}`;\n}\n\n/**\n * Converts a color from hsl format to rgb format.\n * @param {string} color - HSL color values\n * @returns {string} rgb color values\n */\nexport function hslToRgb(color) {\n color = decomposeColor(color);\n const {\n values\n } = color;\n const h = values[0];\n const s = values[1] / 100;\n const l = values[2] / 100;\n const a = s * Math.min(l, 1 - l);\n const f = (n, k = (n + h / 30) % 12) => l - a * Math.max(Math.min(k - 3, 9 - k, 1), -1);\n let type = 'rgb';\n const rgb = [Math.round(f(0) * 255), Math.round(f(8) * 255), Math.round(f(4) * 255)];\n if (color.type === 'hsla') {\n type += 'a';\n rgb.push(values[3]);\n }\n return recomposeColor({\n type,\n values: rgb\n });\n}\n/**\n * The relative brightness of any point in a color space,\n * normalized to 0 for darkest black and 1 for lightest white.\n *\n * Formula: https://www.w3.org/TR/WCAG20-TECHS/G17.html#G17-tests\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @returns {number} The relative brightness of the color in the range 0 - 1\n */\nexport function getLuminance(color) {\n color = decomposeColor(color);\n let rgb = color.type === 'hsl' || color.type === 'hsla' ? decomposeColor(hslToRgb(color)).values : color.values;\n rgb = rgb.map(val => {\n if (color.type !== 'color') {\n val /= 255; // normalized\n }\n return val <= 0.03928 ? val / 12.92 : ((val + 0.055) / 1.055) ** 2.4;\n });\n\n // Truncate at 3 digits\n return Number((0.2126 * rgb[0] + 0.7152 * rgb[1] + 0.0722 * rgb[2]).toFixed(3));\n}\n\n/**\n * Calculates the contrast ratio between two colors.\n *\n * Formula: https://www.w3.org/TR/WCAG20-TECHS/G17.html#G17-tests\n * @param {string} foreground - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla()\n * @param {string} background - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla()\n * @returns {number} A contrast ratio value in the range 0 - 21.\n */\nexport function getContrastRatio(foreground, background) {\n const lumA = getLuminance(foreground);\n const lumB = getLuminance(background);\n return (Math.max(lumA, lumB) + 0.05) / (Math.min(lumA, lumB) + 0.05);\n}\n\n/**\n * Sets the absolute transparency of a color.\n * Any existing alpha values are overwritten.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} value - value to set the alpha channel to in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function alpha(color, value) {\n color = decomposeColor(color);\n value = clampWrapper(value);\n if (color.type === 'rgb' || color.type === 'hsl') {\n color.type += 'a';\n }\n if (color.type === 'color') {\n color.values[3] = `/${value}`;\n } else {\n color.values[3] = value;\n }\n return recomposeColor(color);\n}\nexport function private_safeAlpha(color, value, warning) {\n try {\n return alpha(color, value);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Darkens a color.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} coefficient - multiplier in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function darken(color, coefficient) {\n color = decomposeColor(color);\n coefficient = clampWrapper(coefficient);\n if (color.type.indexOf('hsl') !== -1) {\n color.values[2] *= 1 - coefficient;\n } else if (color.type.indexOf('rgb') !== -1 || color.type.indexOf('color') !== -1) {\n for (let i = 0; i < 3; i += 1) {\n color.values[i] *= 1 - coefficient;\n }\n }\n return recomposeColor(color);\n}\nexport function private_safeDarken(color, coefficient, warning) {\n try {\n return darken(color, coefficient);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Lightens a color.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} coefficient - multiplier in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function lighten(color, coefficient) {\n color = decomposeColor(color);\n coefficient = clampWrapper(coefficient);\n if (color.type.indexOf('hsl') !== -1) {\n color.values[2] += (100 - color.values[2]) * coefficient;\n } else if (color.type.indexOf('rgb') !== -1) {\n for (let i = 0; i < 3; i += 1) {\n color.values[i] += (255 - color.values[i]) * coefficient;\n }\n } else if (color.type.indexOf('color') !== -1) {\n for (let i = 0; i < 3; i += 1) {\n color.values[i] += (1 - color.values[i]) * coefficient;\n }\n }\n return recomposeColor(color);\n}\nexport function private_safeLighten(color, coefficient, warning) {\n try {\n return lighten(color, coefficient);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Darken or lighten a color, depending on its luminance.\n * Light colors are darkened, dark colors are lightened.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} coefficient=0.15 - multiplier in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function emphasize(color, coefficient = 0.15) {\n return getLuminance(color) > 0.5 ? darken(color, coefficient) : lighten(color, coefficient);\n}\nexport function private_safeEmphasize(color, coefficient, warning) {\n try {\n return emphasize(color, coefficient);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Blend a transparent overlay color with a background color, resulting in a single\n * RGB color.\n * @param {string} background - CSS color\n * @param {string} overlay - CSS color\n * @param {number} opacity - Opacity multiplier in the range 0 - 1\n * @param {number} [gamma=1.0] - Gamma correction factor. For gamma-correct blending, 2.2 is usual.\n */\nexport function blend(background, overlay, opacity, gamma = 1.0) {\n const blendChannel = (b, o) => Math.round((b ** (1 / gamma) * (1 - opacity) + o ** (1 / gamma) * opacity) ** gamma);\n const backgroundColor = decomposeColor(background);\n const overlayColor = decomposeColor(overlay);\n const rgb = [blendChannel(backgroundColor.values[0], overlayColor.values[0]), blendChannel(backgroundColor.values[1], overlayColor.values[1]), blendChannel(backgroundColor.values[2], overlayColor.values[2])];\n return recomposeColor({\n type: 'rgb',\n values: rgb\n });\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nexport default function createMixins(breakpoints, mixins) {\n return _extends({\n toolbar: {\n minHeight: 56,\n [breakpoints.up('xs')]: {\n '@media (orientation: landscape)': {\n minHeight: 48\n }\n },\n [breakpoints.up('sm')]: {\n minHeight: 64\n }\n }\n }, mixins);\n}","const common = {\n black: '#000',\n white: '#fff'\n};\nexport default common;","const grey = {\n 50: '#fafafa',\n 100: '#f5f5f5',\n 200: '#eeeeee',\n 300: '#e0e0e0',\n 400: '#bdbdbd',\n 500: '#9e9e9e',\n 600: '#757575',\n 700: '#616161',\n 800: '#424242',\n 900: '#212121',\n A100: '#f5f5f5',\n A200: '#eeeeee',\n A400: '#bdbdbd',\n A700: '#616161'\n};\nexport default grey;","const purple = {\n 50: '#f3e5f5',\n 100: '#e1bee7',\n 200: '#ce93d8',\n 300: '#ba68c8',\n 400: '#ab47bc',\n 500: '#9c27b0',\n 600: '#8e24aa',\n 700: '#7b1fa2',\n 800: '#6a1b9a',\n 900: '#4a148c',\n A100: '#ea80fc',\n A200: '#e040fb',\n A400: '#d500f9',\n A700: '#aa00ff'\n};\nexport default purple;","const red = {\n 50: '#ffebee',\n 100: '#ffcdd2',\n 200: '#ef9a9a',\n 300: '#e57373',\n 400: '#ef5350',\n 500: '#f44336',\n 600: '#e53935',\n 700: '#d32f2f',\n 800: '#c62828',\n 900: '#b71c1c',\n A100: '#ff8a80',\n A200: '#ff5252',\n A400: '#ff1744',\n A700: '#d50000'\n};\nexport default red;","const orange = {\n 50: '#fff3e0',\n 100: '#ffe0b2',\n 200: '#ffcc80',\n 300: '#ffb74d',\n 400: '#ffa726',\n 500: '#ff9800',\n 600: '#fb8c00',\n 700: '#f57c00',\n 800: '#ef6c00',\n 900: '#e65100',\n A100: '#ffd180',\n A200: '#ffab40',\n A400: '#ff9100',\n A700: '#ff6d00'\n};\nexport default orange;","const blue = {\n 50: '#e3f2fd',\n 100: '#bbdefb',\n 200: '#90caf9',\n 300: '#64b5f6',\n 400: '#42a5f5',\n 500: '#2196f3',\n 600: '#1e88e5',\n 700: '#1976d2',\n 800: '#1565c0',\n 900: '#0d47a1',\n A100: '#82b1ff',\n A200: '#448aff',\n A400: '#2979ff',\n A700: '#2962ff'\n};\nexport default blue;","const lightBlue = {\n 50: '#e1f5fe',\n 100: '#b3e5fc',\n 200: '#81d4fa',\n 300: '#4fc3f7',\n 400: '#29b6f6',\n 500: '#03a9f4',\n 600: '#039be5',\n 700: '#0288d1',\n 800: '#0277bd',\n 900: '#01579b',\n A100: '#80d8ff',\n A200: '#40c4ff',\n A400: '#00b0ff',\n A700: '#0091ea'\n};\nexport default lightBlue;","const green = {\n 50: '#e8f5e9',\n 100: '#c8e6c9',\n 200: '#a5d6a7',\n 300: '#81c784',\n 400: '#66bb6a',\n 500: '#4caf50',\n 600: '#43a047',\n 700: '#388e3c',\n 800: '#2e7d32',\n 900: '#1b5e20',\n A100: '#b9f6ca',\n A200: '#69f0ae',\n A400: '#00e676',\n A700: '#00c853'\n};\nexport default green;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\nconst _excluded = [\"mode\", \"contrastThreshold\", \"tonalOffset\"];\nimport { deepmerge } from '@mui/utils';\nimport { darken, getContrastRatio, lighten } from '@mui/system';\nimport common from '../colors/common';\nimport grey from '../colors/grey';\nimport purple from '../colors/purple';\nimport red from '../colors/red';\nimport orange from '../colors/orange';\nimport blue from '../colors/blue';\nimport lightBlue from '../colors/lightBlue';\nimport green from '../colors/green';\nexport const light = {\n // The colors used to style the text.\n text: {\n // The most important text.\n primary: 'rgba(0, 0, 0, 0.87)',\n // Secondary text.\n secondary: 'rgba(0, 0, 0, 0.6)',\n // Disabled text have even lower visual prominence.\n disabled: 'rgba(0, 0, 0, 0.38)'\n },\n // The color used to divide different elements.\n divider: 'rgba(0, 0, 0, 0.12)',\n // The background colors used to style the surfaces.\n // Consistency between these values is important.\n background: {\n paper: common.white,\n default: common.white\n },\n // The colors used to style the action elements.\n action: {\n // The color of an active action like an icon button.\n active: 'rgba(0, 0, 0, 0.54)',\n // The color of an hovered action.\n hover: 'rgba(0, 0, 0, 0.04)',\n hoverOpacity: 0.04,\n // The color of a selected action.\n selected: 'rgba(0, 0, 0, 0.08)',\n selectedOpacity: 0.08,\n // The color of a disabled action.\n disabled: 'rgba(0, 0, 0, 0.26)',\n // The background color of a disabled action.\n disabledBackground: 'rgba(0, 0, 0, 0.12)',\n disabledOpacity: 0.38,\n focus: 'rgba(0, 0, 0, 0.12)',\n focusOpacity: 0.12,\n activatedOpacity: 0.12\n }\n};\nexport const dark = {\n text: {\n primary: common.white,\n secondary: 'rgba(255, 255, 255, 0.7)',\n disabled: 'rgba(255, 255, 255, 0.5)',\n icon: 'rgba(255, 255, 255, 0.5)'\n },\n divider: 'rgba(255, 255, 255, 0.12)',\n background: {\n paper: '#121212',\n default: '#121212'\n },\n action: {\n active: common.white,\n hover: 'rgba(255, 255, 255, 0.08)',\n hoverOpacity: 0.08,\n selected: 'rgba(255, 255, 255, 0.16)',\n selectedOpacity: 0.16,\n disabled: 'rgba(255, 255, 255, 0.3)',\n disabledBackground: 'rgba(255, 255, 255, 0.12)',\n disabledOpacity: 0.38,\n focus: 'rgba(255, 255, 255, 0.12)',\n focusOpacity: 0.12,\n activatedOpacity: 0.24\n }\n};\nfunction addLightOrDark(intent, direction, shade, tonalOffset) {\n const tonalOffsetLight = tonalOffset.light || tonalOffset;\n const tonalOffsetDark = tonalOffset.dark || tonalOffset * 1.5;\n if (!intent[direction]) {\n if (intent.hasOwnProperty(shade)) {\n intent[direction] = intent[shade];\n } else if (direction === 'light') {\n intent.light = lighten(intent.main, tonalOffsetLight);\n } else if (direction === 'dark') {\n intent.dark = darken(intent.main, tonalOffsetDark);\n }\n }\n}\nfunction getDefaultPrimary(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: blue[200],\n light: blue[50],\n dark: blue[400]\n };\n }\n return {\n main: blue[700],\n light: blue[400],\n dark: blue[800]\n };\n}\nfunction getDefaultSecondary(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: purple[200],\n light: purple[50],\n dark: purple[400]\n };\n }\n return {\n main: purple[500],\n light: purple[300],\n dark: purple[700]\n };\n}\nfunction getDefaultError(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: red[500],\n light: red[300],\n dark: red[700]\n };\n }\n return {\n main: red[700],\n light: red[400],\n dark: red[800]\n };\n}\nfunction getDefaultInfo(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: lightBlue[400],\n light: lightBlue[300],\n dark: lightBlue[700]\n };\n }\n return {\n main: lightBlue[700],\n light: lightBlue[500],\n dark: lightBlue[900]\n };\n}\nfunction getDefaultSuccess(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: green[400],\n light: green[300],\n dark: green[700]\n };\n }\n return {\n main: green[800],\n light: green[500],\n dark: green[900]\n };\n}\nfunction getDefaultWarning(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: orange[400],\n light: orange[300],\n dark: orange[700]\n };\n }\n return {\n main: '#ed6c02',\n // closest to orange[800] that pass 3:1.\n light: orange[500],\n dark: orange[900]\n };\n}\nexport default function createPalette(palette) {\n const {\n mode = 'light',\n contrastThreshold = 3,\n tonalOffset = 0.2\n } = palette,\n other = _objectWithoutPropertiesLoose(palette, _excluded);\n const primary = palette.primary || getDefaultPrimary(mode);\n const secondary = palette.secondary || getDefaultSecondary(mode);\n const error = palette.error || getDefaultError(mode);\n const info = palette.info || getDefaultInfo(mode);\n const success = palette.success || getDefaultSuccess(mode);\n const warning = palette.warning || getDefaultWarning(mode);\n\n // Use the same logic as\n // Bootstrap: https://github.com/twbs/bootstrap/blob/1d6e3710dd447de1a200f29e8fa521f8a0908f70/scss/_functions.scss#L59\n // and material-components-web https://github.com/material-components/material-components-web/blob/ac46b8863c4dab9fc22c4c662dc6bd1b65dd652f/packages/mdc-theme/_functions.scss#L54\n function getContrastText(background) {\n const contrastText = getContrastRatio(background, dark.text.primary) >= contrastThreshold ? dark.text.primary : light.text.primary;\n if (process.env.NODE_ENV !== 'production') {\n const contrast = getContrastRatio(background, contrastText);\n if (contrast < 3) {\n console.error([`MUI: The contrast ratio of ${contrast}:1 for ${contrastText} on ${background}`, 'falls below the WCAG recommended absolute minimum contrast ratio of 3:1.', 'https://www.w3.org/TR/2008/REC-WCAG20-20081211/#visual-audio-contrast-contrast'].join('\\n'));\n }\n }\n return contrastText;\n }\n const augmentColor = ({\n color,\n name,\n mainShade = 500,\n lightShade = 300,\n darkShade = 700\n }) => {\n color = _extends({}, color);\n if (!color.main && color[mainShade]) {\n color.main = color[mainShade];\n }\n if (!color.hasOwnProperty('main')) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: The color${name ? ` (${name})` : ''} provided to augmentColor(color) is invalid.\nThe color object needs to have a \\`main\\` property or a \\`${mainShade}\\` property.` : _formatMuiErrorMessage(11, name ? ` (${name})` : '', mainShade));\n }\n if (typeof color.main !== 'string') {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: The color${name ? ` (${name})` : ''} provided to augmentColor(color) is invalid.\n\\`color.main\\` should be a string, but \\`${JSON.stringify(color.main)}\\` was provided instead.\n\nDid you intend to use one of the following approaches?\n\nimport { green } from \"@mui/material/colors\";\n\nconst theme1 = createTheme({ palette: {\n primary: green,\n} });\n\nconst theme2 = createTheme({ palette: {\n primary: { main: green[500] },\n} });` : _formatMuiErrorMessage(12, name ? ` (${name})` : '', JSON.stringify(color.main)));\n }\n addLightOrDark(color, 'light', lightShade, tonalOffset);\n addLightOrDark(color, 'dark', darkShade, tonalOffset);\n if (!color.contrastText) {\n color.contrastText = getContrastText(color.main);\n }\n return color;\n };\n const modes = {\n dark,\n light\n };\n if (process.env.NODE_ENV !== 'production') {\n if (!modes[mode]) {\n console.error(`MUI: The palette mode \\`${mode}\\` is not supported.`);\n }\n }\n const paletteOutput = deepmerge(_extends({\n // A collection of common colors.\n common: _extends({}, common),\n // prevent mutable object.\n // The palette mode, can be light or dark.\n mode,\n // The colors used to represent primary interface elements for a user.\n primary: augmentColor({\n color: primary,\n name: 'primary'\n }),\n // The colors used to represent secondary interface elements for a user.\n secondary: augmentColor({\n color: secondary,\n name: 'secondary',\n mainShade: 'A400',\n lightShade: 'A200',\n darkShade: 'A700'\n }),\n // The colors used to represent interface elements that the user should be made aware of.\n error: augmentColor({\n color: error,\n name: 'error'\n }),\n // The colors used to represent potentially dangerous actions or important messages.\n warning: augmentColor({\n color: warning,\n name: 'warning'\n }),\n // The colors used to present information to the user that is neutral and not necessarily important.\n info: augmentColor({\n color: info,\n name: 'info'\n }),\n // The colors used to indicate the successful completion of an action that user triggered.\n success: augmentColor({\n color: success,\n name: 'success'\n }),\n // The grey colors.\n grey,\n // Used by `getContrastText()` to maximize the contrast between\n // the background and the text.\n contrastThreshold,\n // Takes a background color and returns the text color that maximizes the contrast.\n getContrastText,\n // Generate a rich color object.\n augmentColor,\n // Used by the functions below to shift a color's luminance by approximately\n // two indexes within its tonal palette.\n // E.g., shift from Red 500 to Red 300 or Red 700.\n tonalOffset\n }, modes[mode]), other);\n return paletteOutput;\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"fontFamily\", \"fontSize\", \"fontWeightLight\", \"fontWeightRegular\", \"fontWeightMedium\", \"fontWeightBold\", \"htmlFontSize\", \"allVariants\", \"pxToRem\"];\nimport { deepmerge } from '@mui/utils';\nfunction round(value) {\n return Math.round(value * 1e5) / 1e5;\n}\nconst caseAllCaps = {\n textTransform: 'uppercase'\n};\nconst defaultFontFamily = '\"Roboto\", \"Helvetica\", \"Arial\", sans-serif';\n\n/**\n * @see @link{https://m2.material.io/design/typography/the-type-system.html}\n * @see @link{https://m2.material.io/design/typography/understanding-typography.html}\n */\nexport default function createTypography(palette, typography) {\n const _ref = typeof typography === 'function' ? typography(palette) : typography,\n {\n fontFamily = defaultFontFamily,\n // The default font size of the Material Specification.\n fontSize = 14,\n // px\n fontWeightLight = 300,\n fontWeightRegular = 400,\n fontWeightMedium = 500,\n fontWeightBold = 700,\n // Tell MUI what's the font-size on the html element.\n // 16px is the default font-size used by browsers.\n htmlFontSize = 16,\n // Apply the CSS properties to all the variants.\n allVariants,\n pxToRem: pxToRem2\n } = _ref,\n other = _objectWithoutPropertiesLoose(_ref, _excluded);\n if (process.env.NODE_ENV !== 'production') {\n if (typeof fontSize !== 'number') {\n console.error('MUI: `fontSize` is required to be a number.');\n }\n if (typeof htmlFontSize !== 'number') {\n console.error('MUI: `htmlFontSize` is required to be a number.');\n }\n }\n const coef = fontSize / 14;\n const pxToRem = pxToRem2 || (size => `${size / htmlFontSize * coef}rem`);\n const buildVariant = (fontWeight, size, lineHeight, letterSpacing, casing) => _extends({\n fontFamily,\n fontWeight,\n fontSize: pxToRem(size),\n // Unitless following https://meyerweb.com/eric/thoughts/2006/02/08/unitless-line-heights/\n lineHeight\n }, fontFamily === defaultFontFamily ? {\n letterSpacing: `${round(letterSpacing / size)}em`\n } : {}, casing, allVariants);\n const variants = {\n h1: buildVariant(fontWeightLight, 96, 1.167, -1.5),\n h2: buildVariant(fontWeightLight, 60, 1.2, -0.5),\n h3: buildVariant(fontWeightRegular, 48, 1.167, 0),\n h4: buildVariant(fontWeightRegular, 34, 1.235, 0.25),\n h5: buildVariant(fontWeightRegular, 24, 1.334, 0),\n h6: buildVariant(fontWeightMedium, 20, 1.6, 0.15),\n subtitle1: buildVariant(fontWeightRegular, 16, 1.75, 0.15),\n subtitle2: buildVariant(fontWeightMedium, 14, 1.57, 0.1),\n body1: buildVariant(fontWeightRegular, 16, 1.5, 0.15),\n body2: buildVariant(fontWeightRegular, 14, 1.43, 0.15),\n button: buildVariant(fontWeightMedium, 14, 1.75, 0.4, caseAllCaps),\n caption: buildVariant(fontWeightRegular, 12, 1.66, 0.4),\n overline: buildVariant(fontWeightRegular, 12, 2.66, 1, caseAllCaps),\n // TODO v6: Remove handling of 'inherit' variant from the theme as it is already handled in Material UI's Typography component. Also, remember to remove the associated types.\n inherit: {\n fontFamily: 'inherit',\n fontWeight: 'inherit',\n fontSize: 'inherit',\n lineHeight: 'inherit',\n letterSpacing: 'inherit'\n }\n };\n return deepmerge(_extends({\n htmlFontSize,\n pxToRem,\n fontFamily,\n fontSize,\n fontWeightLight,\n fontWeightRegular,\n fontWeightMedium,\n fontWeightBold\n }, variants), other, {\n clone: false // No need to clone deep\n });\n}","const shadowKeyUmbraOpacity = 0.2;\nconst shadowKeyPenumbraOpacity = 0.14;\nconst shadowAmbientShadowOpacity = 0.12;\nfunction createShadow(...px) {\n return [`${px[0]}px ${px[1]}px ${px[2]}px ${px[3]}px rgba(0,0,0,${shadowKeyUmbraOpacity})`, `${px[4]}px ${px[5]}px ${px[6]}px ${px[7]}px rgba(0,0,0,${shadowKeyPenumbraOpacity})`, `${px[8]}px ${px[9]}px ${px[10]}px ${px[11]}px rgba(0,0,0,${shadowAmbientShadowOpacity})`].join(',');\n}\n\n// Values from https://github.com/material-components/material-components-web/blob/be8747f94574669cb5e7add1a7c54fa41a89cec7/packages/mdc-elevation/_variables.scss\nconst shadows = ['none', createShadow(0, 2, 1, -1, 0, 1, 1, 0, 0, 1, 3, 0), createShadow(0, 3, 1, -2, 0, 2, 2, 0, 0, 1, 5, 0), createShadow(0, 3, 3, -2, 0, 3, 4, 0, 0, 1, 8, 0), createShadow(0, 2, 4, -1, 0, 4, 5, 0, 0, 1, 10, 0), createShadow(0, 3, 5, -1, 0, 5, 8, 0, 0, 1, 14, 0), createShadow(0, 3, 5, -1, 0, 6, 10, 0, 0, 1, 18, 0), createShadow(0, 4, 5, -2, 0, 7, 10, 1, 0, 2, 16, 1), createShadow(0, 5, 5, -3, 0, 8, 10, 1, 0, 3, 14, 2), createShadow(0, 5, 6, -3, 0, 9, 12, 1, 0, 3, 16, 2), createShadow(0, 6, 6, -3, 0, 10, 14, 1, 0, 4, 18, 3), createShadow(0, 6, 7, -4, 0, 11, 15, 1, 0, 4, 20, 3), createShadow(0, 7, 8, -4, 0, 12, 17, 2, 0, 5, 22, 4), createShadow(0, 7, 8, -4, 0, 13, 19, 2, 0, 5, 24, 4), createShadow(0, 7, 9, -4, 0, 14, 21, 2, 0, 5, 26, 4), createShadow(0, 8, 9, -5, 0, 15, 22, 2, 0, 6, 28, 5), createShadow(0, 8, 10, -5, 0, 16, 24, 2, 0, 6, 30, 5), createShadow(0, 8, 11, -5, 0, 17, 26, 2, 0, 6, 32, 5), createShadow(0, 9, 11, -5, 0, 18, 28, 2, 0, 7, 34, 6), createShadow(0, 9, 12, -6, 0, 19, 29, 2, 0, 7, 36, 6), createShadow(0, 10, 13, -6, 0, 20, 31, 3, 0, 8, 38, 7), createShadow(0, 10, 13, -6, 0, 21, 33, 3, 0, 8, 40, 7), createShadow(0, 10, 14, -6, 0, 22, 35, 3, 0, 8, 42, 7), createShadow(0, 11, 14, -7, 0, 23, 36, 3, 0, 9, 44, 8), createShadow(0, 11, 15, -7, 0, 24, 38, 3, 0, 9, 46, 8)];\nexport default shadows;","import _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nconst _excluded = [\"duration\", \"easing\", \"delay\"];\n// Follow https://material.google.com/motion/duration-easing.html#duration-easing-natural-easing-curves\n// to learn the context in which each easing should be used.\nexport const easing = {\n // This is the most common easing curve.\n easeInOut: 'cubic-bezier(0.4, 0, 0.2, 1)',\n // Objects enter the screen at full velocity from off-screen and\n // slowly decelerate to a resting point.\n easeOut: 'cubic-bezier(0.0, 0, 0.2, 1)',\n // Objects leave the screen at full velocity. They do not decelerate when off-screen.\n easeIn: 'cubic-bezier(0.4, 0, 1, 1)',\n // The sharp curve is used by objects that may return to the screen at any time.\n sharp: 'cubic-bezier(0.4, 0, 0.6, 1)'\n};\n\n// Follow https://m2.material.io/guidelines/motion/duration-easing.html#duration-easing-common-durations\n// to learn when use what timing\nexport const duration = {\n shortest: 150,\n shorter: 200,\n short: 250,\n // most basic recommended timing\n standard: 300,\n // this is to be used in complex animations\n complex: 375,\n // recommended when something is entering screen\n enteringScreen: 225,\n // recommended when something is leaving screen\n leavingScreen: 195\n};\nfunction formatMs(milliseconds) {\n return `${Math.round(milliseconds)}ms`;\n}\nfunction getAutoHeightDuration(height) {\n if (!height) {\n return 0;\n }\n const constant = height / 36;\n\n // https://www.wolframalpha.com/input/?i=(4+%2B+15+*+(x+%2F+36+)+**+0.25+%2B+(x+%2F+36)+%2F+5)+*+10\n return Math.round((4 + 15 * constant ** 0.25 + constant / 5) * 10);\n}\nexport default function createTransitions(inputTransitions) {\n const mergedEasing = _extends({}, easing, inputTransitions.easing);\n const mergedDuration = _extends({}, duration, inputTransitions.duration);\n const create = (props = ['all'], options = {}) => {\n const {\n duration: durationOption = mergedDuration.standard,\n easing: easingOption = mergedEasing.easeInOut,\n delay = 0\n } = options,\n other = _objectWithoutPropertiesLoose(options, _excluded);\n if (process.env.NODE_ENV !== 'production') {\n const isString = value => typeof value === 'string';\n // IE11 support, replace with Number.isNaN\n // eslint-disable-next-line no-restricted-globals\n const isNumber = value => !isNaN(parseFloat(value));\n if (!isString(props) && !Array.isArray(props)) {\n console.error('MUI: Argument \"props\" must be a string or Array.');\n }\n if (!isNumber(durationOption) && !isString(durationOption)) {\n console.error(`MUI: Argument \"duration\" must be a number or a string but found ${durationOption}.`);\n }\n if (!isString(easingOption)) {\n console.error('MUI: Argument \"easing\" must be a string.');\n }\n if (!isNumber(delay) && !isString(delay)) {\n console.error('MUI: Argument \"delay\" must be a number or a string.');\n }\n if (typeof options !== 'object') {\n console.error(['MUI: Secong argument of transition.create must be an object.', \"Arguments should be either `create('prop1', options)` or `create(['prop1', 'prop2'], options)`\"].join('\\n'));\n }\n if (Object.keys(other).length !== 0) {\n console.error(`MUI: Unrecognized argument(s) [${Object.keys(other).join(',')}].`);\n }\n }\n return (Array.isArray(props) ? props : [props]).map(animatedProp => `${animatedProp} ${typeof durationOption === 'string' ? durationOption : formatMs(durationOption)} ${easingOption} ${typeof delay === 'string' ? delay : formatMs(delay)}`).join(',');\n };\n return _extends({\n getAutoHeightDuration,\n create\n }, inputTransitions, {\n easing: mergedEasing,\n duration: mergedDuration\n });\n}","// We need to centralize the zIndex definitions as they work\n// like global values in the browser.\nconst zIndex = {\n mobileStepper: 1000,\n fab: 1050,\n speedDial: 1050,\n appBar: 1100,\n drawer: 1200,\n modal: 1300,\n snackbar: 1400,\n tooltip: 1500\n};\nexport default zIndex;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\nconst _excluded = [\"breakpoints\", \"mixins\", \"spacing\", \"palette\", \"transitions\", \"typography\", \"shape\"];\nimport { deepmerge } from '@mui/utils';\nimport { createTheme as systemCreateTheme, unstable_defaultSxConfig as defaultSxConfig, unstable_styleFunctionSx as styleFunctionSx } from '@mui/system';\nimport generateUtilityClass from '@mui/utils/generateUtilityClass';\nimport createMixins from './createMixins';\nimport createPalette from './createPalette';\nimport createTypography from './createTypography';\nimport shadows from './shadows';\nimport createTransitions from './createTransitions';\nimport zIndex from './zIndex';\nfunction createTheme(options = {}, ...args) {\n const {\n mixins: mixinsInput = {},\n palette: paletteInput = {},\n transitions: transitionsInput = {},\n typography: typographyInput = {}\n } = options,\n other = _objectWithoutPropertiesLoose(options, _excluded);\n if (options.vars) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: \\`vars\\` is a private field used for CSS variables support.\nPlease use another name.` : _formatMuiErrorMessage(18));\n }\n const palette = createPalette(paletteInput);\n const systemTheme = systemCreateTheme(options);\n let muiTheme = deepmerge(systemTheme, {\n mixins: createMixins(systemTheme.breakpoints, mixinsInput),\n palette,\n // Don't use [...shadows] until you've verified its transpiled code is not invoking the iterator protocol.\n shadows: shadows.slice(),\n typography: createTypography(palette, typographyInput),\n transitions: createTransitions(transitionsInput),\n zIndex: _extends({}, zIndex)\n });\n muiTheme = deepmerge(muiTheme, other);\n muiTheme = args.reduce((acc, argument) => deepmerge(acc, argument), muiTheme);\n if (process.env.NODE_ENV !== 'production') {\n // TODO v6: Refactor to use globalStateClassesMapping from @mui/utils once `readOnly` state class is used in Rating component.\n const stateClasses = ['active', 'checked', 'completed', 'disabled', 'error', 'expanded', 'focused', 'focusVisible', 'required', 'selected'];\n const traverse = (node, component) => {\n let key;\n\n // eslint-disable-next-line guard-for-in, no-restricted-syntax\n for (key in node) {\n const child = node[key];\n if (stateClasses.indexOf(key) !== -1 && Object.keys(child).length > 0) {\n if (process.env.NODE_ENV !== 'production') {\n const stateClass = generateUtilityClass('', key);\n console.error([`MUI: The \\`${component}\\` component increases ` + `the CSS specificity of the \\`${key}\\` internal state.`, 'You can not override it like this: ', JSON.stringify(node, null, 2), '', `Instead, you need to use the '&.${stateClass}' syntax:`, JSON.stringify({\n root: {\n [`&.${stateClass}`]: child\n }\n }, null, 2), '', 'https://mui.com/r/state-classes-guide'].join('\\n'));\n }\n // Remove the style to prevent global conflicts.\n node[key] = {};\n }\n }\n };\n Object.keys(muiTheme.components).forEach(component => {\n const styleOverrides = muiTheme.components[component].styleOverrides;\n if (styleOverrides && component.indexOf('Mui') === 0) {\n traverse(styleOverrides, component);\n }\n });\n }\n muiTheme.unstable_sxConfig = _extends({}, defaultSxConfig, other == null ? void 0 : other.unstable_sxConfig);\n muiTheme.unstable_sx = function sx(props) {\n return styleFunctionSx({\n sx: props,\n theme: this\n });\n };\n return muiTheme;\n}\nlet warnedOnce = false;\nexport function createMuiTheme(...args) {\n if (process.env.NODE_ENV !== 'production') {\n if (!warnedOnce) {\n warnedOnce = true;\n console.error(['MUI: the createMuiTheme function was renamed to createTheme.', '', \"You should use `import { createTheme } from '@mui/material/styles'`\"].join('\\n'));\n }\n }\n return createTheme(...args);\n}\nexport default createTheme;","'use client';\n\nimport createTheme from './createTheme';\nconst defaultTheme = createTheme();\nexport default defaultTheme;","export default '$$material';","'use client';\n\nimport { useThemeProps as systemUseThemeProps } from '@mui/system';\nimport defaultTheme from './defaultTheme';\nimport THEME_ID from './identifier';\nexport default function useThemeProps({\n props,\n name\n}) {\n return systemUseThemeProps({\n props,\n name,\n defaultTheme,\n themeId: THEME_ID\n });\n}","'use client';\n\nimport { createStyled, shouldForwardProp } from '@mui/system';\nimport defaultTheme from './defaultTheme';\nimport THEME_ID from './identifier';\nexport const rootShouldForwardProp = prop => shouldForwardProp(prop) && prop !== 'classes';\nexport const slotShouldForwardProp = shouldForwardProp;\nconst styled = createStyled({\n themeId: THEME_ID,\n defaultTheme,\n rootShouldForwardProp\n});\nexport default styled;","import generateUtilityClasses from '@mui/utils/generateUtilityClasses';\nimport generateUtilityClass from '@mui/utils/generateUtilityClass';\nexport function getSvgIconUtilityClass(slot) {\n return generateUtilityClass('MuiSvgIcon', slot);\n}\nconst svgIconClasses = generateUtilityClasses('MuiSvgIcon', ['root', 'colorPrimary', 'colorSecondary', 'colorAction', 'colorError', 'colorDisabled', 'fontSizeInherit', 'fontSizeSmall', 'fontSizeMedium', 'fontSizeLarge']);\nexport default svgIconClasses;","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"children\", \"className\", \"color\", \"component\", \"fontSize\", \"htmlColor\", \"inheritViewBox\", \"titleAccess\", \"viewBox\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport clsx from 'clsx';\nimport { unstable_composeClasses as composeClasses } from '@mui/base/composeClasses';\nimport capitalize from '../utils/capitalize';\nimport useThemeProps from '../styles/useThemeProps';\nimport styled from '../styles/styled';\nimport { getSvgIconUtilityClass } from './svgIconClasses';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nimport { jsxs as _jsxs } from \"react/jsx-runtime\";\nconst useUtilityClasses = ownerState => {\n const {\n color,\n fontSize,\n classes\n } = ownerState;\n const slots = {\n root: ['root', color !== 'inherit' && `color${capitalize(color)}`, `fontSize${capitalize(fontSize)}`]\n };\n return composeClasses(slots, getSvgIconUtilityClass, classes);\n};\nconst SvgIconRoot = styled('svg', {\n name: 'MuiSvgIcon',\n slot: 'Root',\n overridesResolver: (props, styles) => {\n const {\n ownerState\n } = props;\n return [styles.root, ownerState.color !== 'inherit' && styles[`color${capitalize(ownerState.color)}`], styles[`fontSize${capitalize(ownerState.fontSize)}`]];\n }\n})(({\n theme,\n ownerState\n}) => {\n var _theme$transitions, _theme$transitions$cr, _theme$transitions2, _theme$typography, _theme$typography$pxT, _theme$typography2, _theme$typography2$px, _theme$typography3, _theme$typography3$px, _palette$ownerState$c, _palette, _palette2, _palette3;\n return {\n userSelect: 'none',\n width: '1em',\n height: '1em',\n display: 'inline-block',\n // the will define the property that has `currentColor`\n // e.g. heroicons uses fill=\"none\" and stroke=\"currentColor\"\n fill: ownerState.hasSvgAsChild ? undefined : 'currentColor',\n flexShrink: 0,\n transition: (_theme$transitions = theme.transitions) == null || (_theme$transitions$cr = _theme$transitions.create) == null ? void 0 : _theme$transitions$cr.call(_theme$transitions, 'fill', {\n duration: (_theme$transitions2 = theme.transitions) == null || (_theme$transitions2 = _theme$transitions2.duration) == null ? void 0 : _theme$transitions2.shorter\n }),\n fontSize: {\n inherit: 'inherit',\n small: ((_theme$typography = theme.typography) == null || (_theme$typography$pxT = _theme$typography.pxToRem) == null ? void 0 : _theme$typography$pxT.call(_theme$typography, 20)) || '1.25rem',\n medium: ((_theme$typography2 = theme.typography) == null || (_theme$typography2$px = _theme$typography2.pxToRem) == null ? void 0 : _theme$typography2$px.call(_theme$typography2, 24)) || '1.5rem',\n large: ((_theme$typography3 = theme.typography) == null || (_theme$typography3$px = _theme$typography3.pxToRem) == null ? void 0 : _theme$typography3$px.call(_theme$typography3, 35)) || '2.1875rem'\n }[ownerState.fontSize],\n // TODO v5 deprecate, v6 remove for sx\n color: (_palette$ownerState$c = (_palette = (theme.vars || theme).palette) == null || (_palette = _palette[ownerState.color]) == null ? void 0 : _palette.main) != null ? _palette$ownerState$c : {\n action: (_palette2 = (theme.vars || theme).palette) == null || (_palette2 = _palette2.action) == null ? void 0 : _palette2.active,\n disabled: (_palette3 = (theme.vars || theme).palette) == null || (_palette3 = _palette3.action) == null ? void 0 : _palette3.disabled,\n inherit: undefined\n }[ownerState.color]\n };\n});\nconst SvgIcon = /*#__PURE__*/React.forwardRef(function SvgIcon(inProps, ref) {\n const props = useThemeProps({\n props: inProps,\n name: 'MuiSvgIcon'\n });\n const {\n children,\n className,\n color = 'inherit',\n component = 'svg',\n fontSize = 'medium',\n htmlColor,\n inheritViewBox = false,\n titleAccess,\n viewBox = '0 0 24 24'\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const hasSvgAsChild = /*#__PURE__*/React.isValidElement(children) && children.type === 'svg';\n const ownerState = _extends({}, props, {\n color,\n component,\n fontSize,\n instanceFontSize: inProps.fontSize,\n inheritViewBox,\n viewBox,\n hasSvgAsChild\n });\n const more = {};\n if (!inheritViewBox) {\n more.viewBox = viewBox;\n }\n const classes = useUtilityClasses(ownerState);\n return /*#__PURE__*/_jsxs(SvgIconRoot, _extends({\n as: component,\n className: clsx(classes.root, className),\n focusable: \"false\",\n color: htmlColor,\n \"aria-hidden\": titleAccess ? undefined : true,\n role: titleAccess ? 'img' : undefined,\n ref: ref\n }, more, other, hasSvgAsChild && children.props, {\n ownerState: ownerState,\n children: [hasSvgAsChild ? children.props.children : children, titleAccess ? /*#__PURE__*/_jsx(\"title\", {\n children: titleAccess\n }) : null]\n }));\n});\nprocess.env.NODE_ENV !== \"production\" ? SvgIcon.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the d.ts file and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * Node passed into the SVG element.\n */\n children: PropTypes.node,\n /**\n * Override or extend the styles applied to the component.\n */\n classes: PropTypes.object,\n /**\n * @ignore\n */\n className: PropTypes.string,\n /**\n * The color of the component.\n * It supports both default and custom theme colors, which can be added as shown in the\n * [palette customization guide](https://mui.com/material-ui/customization/palette/#custom-colors).\n * You can use the `htmlColor` prop to apply a color attribute to the SVG element.\n * @default 'inherit'\n */\n color: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.oneOf(['inherit', 'action', 'disabled', 'primary', 'secondary', 'error', 'info', 'success', 'warning']), PropTypes.string]),\n /**\n * The component used for the root node.\n * Either a string to use a HTML element or a component.\n */\n component: PropTypes.elementType,\n /**\n * The fontSize applied to the icon. Defaults to 24px, but can be configure to inherit font size.\n * @default 'medium'\n */\n fontSize: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.oneOf(['inherit', 'large', 'medium', 'small']), PropTypes.string]),\n /**\n * Applies a color attribute to the SVG element.\n */\n htmlColor: PropTypes.string,\n /**\n * If `true`, the root node will inherit the custom `component`'s viewBox and the `viewBox`\n * prop will be ignored.\n * Useful when you want to reference a custom `component` and have `SvgIcon` pass that\n * `component`'s viewBox to the root node.\n * @default false\n */\n inheritViewBox: PropTypes.bool,\n /**\n * The shape-rendering attribute. The behavior of the different options is described on the\n * [MDN Web Docs](https://developer.mozilla.org/en-US/docs/Web/SVG/Attribute/shape-rendering).\n * If you are having issues with blurry icons you should investigate this prop.\n */\n shapeRendering: PropTypes.string,\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Provides a human-readable title for the element that contains it.\n * https://www.w3.org/TR/SVG-access/#Equivalent\n */\n titleAccess: PropTypes.string,\n /**\n * Allows you to redefine what the coordinates without units mean inside an SVG element.\n * For example, if the SVG element is 500 (width) by 200 (height),\n * and you pass viewBox=\"0 0 50 20\",\n * this means that the coordinates inside the SVG will go from the top left corner (0,0)\n * to bottom right (50,20) and each unit will be worth 10px.\n * @default '0 0 24 24'\n */\n viewBox: PropTypes.string\n} : void 0;\nSvgIcon.muiName = 'SvgIcon';\nexport default SvgIcon;","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport * as React from 'react';\nimport SvgIcon from '../SvgIcon';\n\n/**\n * Private module reserved for @mui packages.\n */\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nexport default function createSvgIcon(path, displayName) {\n function Component(props, ref) {\n return /*#__PURE__*/_jsx(SvgIcon, _extends({\n \"data-testid\": `${displayName}Icon`,\n ref: ref\n }, props, {\n children: path\n }));\n }\n if (process.env.NODE_ENV !== 'production') {\n // Need to set `displayName` on the inner component for React.memo.\n // React prior to 16.14 ignores `displayName` on the wrapper.\n Component.displayName = `${displayName}Icon`;\n }\n Component.muiName = SvgIcon.muiName;\n return /*#__PURE__*/React.memo( /*#__PURE__*/React.forwardRef(Component));\n}","'use client';\n\nimport { unstable_ClassNameGenerator as ClassNameGenerator } from '@mui/base/ClassNameGenerator';\nexport { default as capitalize } from './capitalize';\nexport { default as createChainedFunction } from './createChainedFunction';\nexport { default as createSvgIcon } from './createSvgIcon';\nexport { default as debounce } from './debounce';\nexport { default as deprecatedPropType } from './deprecatedPropType';\nexport { default as isMuiElement } from './isMuiElement';\nexport { default as ownerDocument } from './ownerDocument';\nexport { default as ownerWindow } from './ownerWindow';\nexport { default as requirePropFactory } from './requirePropFactory';\nexport { default as setRef } from './setRef';\nexport { default as unstable_useEnhancedEffect } from './useEnhancedEffect';\nexport { default as unstable_useId } from './useId';\nexport { default as unsupportedProp } from './unsupportedProp';\nexport { default as useControlled } from './useControlled';\nexport { default as useEventCallback } from './useEventCallback';\nexport { default as useForkRef } from './useForkRef';\nexport { default as useIsFocusVisible } from './useIsFocusVisible';\n// TODO: remove this export once ClassNameGenerator is stable\n// eslint-disable-next-line @typescript-eslint/naming-convention\nexport const unstable_ClassNameGenerator = {\n configure: generator => {\n if (process.env.NODE_ENV !== 'production') {\n console.warn(['MUI: `ClassNameGenerator` import from `@mui/material/utils` is outdated and might cause unexpected issues.', '', \"You should use `import { unstable_ClassNameGenerator } from '@mui/material/className'` instead\", '', 'The detail of the issue: https://github.com/mui/material-ui/issues/30011#issuecomment-1024993401', '', 'The updated documentation: https://mui.com/guides/classname-generator/'].join('\\n'));\n }\n ClassNameGenerator.configure(generator);\n }\n};","\"use strict\";\n'use client';\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nObject.defineProperty(exports, \"default\", {\n enumerable: true,\n get: function () {\n return _utils.createSvgIcon;\n }\n});\nvar _utils = require(\"@mui/material/utils\");","\"use strict\";\n\"use client\";\n\nvar _interopRequireDefault = require(\"@babel/runtime/helpers/interopRequireDefault\");\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = void 0;\nvar _createSvgIcon = _interopRequireDefault(require(\"./utils/createSvgIcon\"));\nvar _jsxRuntime = require(\"react/jsx-runtime\");\nvar _default = exports.default = (0, _createSvgIcon.default)( /*#__PURE__*/(0, _jsxRuntime.jsx)(\"path\", {\n d: \"m10 17 5-5-5-5z\"\n}), 'ArrowRight');","/**\n * Determines if a given element is a DOM element name (i.e. not a React component).\n */\nexport function isHostComponent(element) {\n return typeof element === 'string';\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport { isHostComponent } from './isHostComponent';\n\n/**\n * Type of the ownerState based on the type of an element it applies to.\n * This resolves to the provided OwnerState for React components and `undefined` for host components.\n * Falls back to `OwnerState | undefined` when the exact type can't be determined in development time.\n */\n\n/**\n * Appends the ownerState object to the props, merging with the existing one if necessary.\n *\n * @param elementType Type of the element that owns the `existingProps`. If the element is a DOM node or undefined, `ownerState` is not applied.\n * @param otherProps Props of the element.\n * @param ownerState\n */\nexport function appendOwnerState(elementType, otherProps, ownerState) {\n if (elementType === undefined || isHostComponent(elementType)) {\n return otherProps;\n }\n return _extends({}, otherProps, {\n ownerState: _extends({}, otherProps.ownerState, ownerState)\n });\n}","'use client';\n\nimport * as React from 'react';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nconst defaultContextValue = {\n disableDefaultClasses: false\n};\nconst ClassNameConfiguratorContext = /*#__PURE__*/React.createContext(defaultContextValue);\n/**\n * @ignore - internal hook.\n *\n * Wraps the `generateUtilityClass` function and controls how the classes are generated.\n * Currently it only affects whether the classes are applied or not.\n *\n * @returns Function to be called with the `generateUtilityClass` function specific to a component to generate the classes.\n */\nexport function useClassNamesOverride(generateUtilityClass) {\n const {\n disableDefaultClasses\n } = React.useContext(ClassNameConfiguratorContext);\n return slot => {\n if (disableDefaultClasses) {\n return '';\n }\n return generateUtilityClass(slot);\n };\n}\n\n/**\n * Allows to configure the components within to not apply any built-in classes.\n */\nexport function ClassNameConfigurator(props) {\n const {\n disableDefaultClasses,\n children\n } = props;\n const contextValue = React.useMemo(() => ({\n disableDefaultClasses: disableDefaultClasses != null ? disableDefaultClasses : false\n }), [disableDefaultClasses]);\n return /*#__PURE__*/_jsx(ClassNameConfiguratorContext.Provider, {\n value: contextValue,\n children: children\n });\n}","/**\n * Extracts event handlers from a given object.\n * A prop is considered an event handler if it is a function and its name starts with `on`.\n *\n * @param object An object to extract event handlers from.\n * @param excludeKeys An array of keys to exclude from the returned object.\n */\nexport function extractEventHandlers(object, excludeKeys = []) {\n if (object === undefined) {\n return {};\n }\n const result = {};\n Object.keys(object).filter(prop => prop.match(/^on[A-Z]/) && typeof object[prop] === 'function' && !excludeKeys.includes(prop)).forEach(prop => {\n result[prop] = object[prop];\n });\n return result;\n}","/**\n * If `componentProps` is a function, calls it with the provided `ownerState`.\n * Otherwise, just returns `componentProps`.\n */\nexport function resolveComponentProps(componentProps, ownerState, slotState) {\n if (typeof componentProps === 'function') {\n return componentProps(ownerState, slotState);\n }\n return componentProps;\n}","/**\n * Removes event handlers from the given object.\n * A field is considered an event handler if it is a function with a name beginning with `on`.\n *\n * @param object Object to remove event handlers from.\n * @returns Object with event handlers removed.\n */\nexport function omitEventHandlers(object) {\n if (object === undefined) {\n return {};\n }\n const result = {};\n Object.keys(object).filter(prop => !(prop.match(/^on[A-Z]/) && typeof object[prop] === 'function')).forEach(prop => {\n result[prop] = object[prop];\n });\n return result;\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport clsx from 'clsx';\nimport { extractEventHandlers } from './extractEventHandlers';\nimport { omitEventHandlers } from './omitEventHandlers';\n/**\n * Merges the slot component internal props (usually coming from a hook)\n * with the externally provided ones.\n *\n * The merge order is (the latter overrides the former):\n * 1. The internal props (specified as a getter function to work with get*Props hook result)\n * 2. Additional props (specified internally on a Base UI component)\n * 3. External props specified on the owner component. These should only be used on a root slot.\n * 4. External props specified in the `slotProps.*` prop.\n * 5. The `className` prop - combined from all the above.\n * @param parameters\n * @returns\n */\nexport function mergeSlotProps(parameters) {\n const {\n getSlotProps,\n additionalProps,\n externalSlotProps,\n externalForwardedProps,\n className\n } = parameters;\n if (!getSlotProps) {\n // The simpler case - getSlotProps is not defined, so no internal event handlers are defined,\n // so we can simply merge all the props without having to worry about extracting event handlers.\n const joinedClasses = clsx(additionalProps == null ? void 0 : additionalProps.className, className, externalForwardedProps == null ? void 0 : externalForwardedProps.className, externalSlotProps == null ? void 0 : externalSlotProps.className);\n const mergedStyle = _extends({}, additionalProps == null ? void 0 : additionalProps.style, externalForwardedProps == null ? void 0 : externalForwardedProps.style, externalSlotProps == null ? void 0 : externalSlotProps.style);\n const props = _extends({}, additionalProps, externalForwardedProps, externalSlotProps);\n if (joinedClasses.length > 0) {\n props.className = joinedClasses;\n }\n if (Object.keys(mergedStyle).length > 0) {\n props.style = mergedStyle;\n }\n return {\n props,\n internalRef: undefined\n };\n }\n\n // In this case, getSlotProps is responsible for calling the external event handlers.\n // We don't need to include them in the merged props because of this.\n\n const eventHandlers = extractEventHandlers(_extends({}, externalForwardedProps, externalSlotProps));\n const componentsPropsWithoutEventHandlers = omitEventHandlers(externalSlotProps);\n const otherPropsWithoutEventHandlers = omitEventHandlers(externalForwardedProps);\n const internalSlotProps = getSlotProps(eventHandlers);\n\n // The order of classes is important here.\n // Emotion (that we use in libraries consuming Base UI) depends on this order\n // to properly override style. It requires the most important classes to be last\n // (see https://github.com/mui/material-ui/pull/33205) for the related discussion.\n const joinedClasses = clsx(internalSlotProps == null ? void 0 : internalSlotProps.className, additionalProps == null ? void 0 : additionalProps.className, className, externalForwardedProps == null ? void 0 : externalForwardedProps.className, externalSlotProps == null ? void 0 : externalSlotProps.className);\n const mergedStyle = _extends({}, internalSlotProps == null ? void 0 : internalSlotProps.style, additionalProps == null ? void 0 : additionalProps.style, externalForwardedProps == null ? void 0 : externalForwardedProps.style, externalSlotProps == null ? void 0 : externalSlotProps.style);\n const props = _extends({}, internalSlotProps, additionalProps, otherPropsWithoutEventHandlers, componentsPropsWithoutEventHandlers);\n if (joinedClasses.length > 0) {\n props.className = joinedClasses;\n }\n if (Object.keys(mergedStyle).length > 0) {\n props.style = mergedStyle;\n }\n return {\n props,\n internalRef: internalSlotProps.ref\n };\n}","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"elementType\", \"externalSlotProps\", \"ownerState\", \"skipResolvingSlotProps\"];\nimport { unstable_useForkRef as useForkRef } from '@mui/utils';\nimport { appendOwnerState } from './appendOwnerState';\nimport { mergeSlotProps } from './mergeSlotProps';\nimport { resolveComponentProps } from './resolveComponentProps';\n/**\n * @ignore - do not document.\n * Builds the props to be passed into the slot of an unstyled component.\n * It merges the internal props of the component with the ones supplied by the user, allowing to customize the behavior.\n * If the slot component is not a host component, it also merges in the `ownerState`.\n *\n * @param parameters.getSlotProps - A function that returns the props to be passed to the slot component.\n */\nexport function useSlotProps(parameters) {\n var _parameters$additiona;\n const {\n elementType,\n externalSlotProps,\n ownerState,\n skipResolvingSlotProps = false\n } = parameters,\n rest = _objectWithoutPropertiesLoose(parameters, _excluded);\n const resolvedComponentsProps = skipResolvingSlotProps ? {} : resolveComponentProps(externalSlotProps, ownerState);\n const {\n props: mergedProps,\n internalRef\n } = mergeSlotProps(_extends({}, rest, {\n externalSlotProps: resolvedComponentsProps\n }));\n const ref = useForkRef(internalRef, resolvedComponentsProps == null ? void 0 : resolvedComponentsProps.ref, (_parameters$additiona = parameters.additionalProps) == null ? void 0 : _parameters$additiona.ref);\n const props = appendOwnerState(elementType, _extends({}, mergedProps, {\n ref\n }), ownerState);\n return props;\n}","import { globalStateClasses } from '@mui/utils/generateUtilityClass';\nconst GLOBAL_CLASS_PREFIX = 'base';\nfunction buildStateClass(state) {\n return `${GLOBAL_CLASS_PREFIX}--${state}`;\n}\nfunction buildSlotClass(componentName, slot) {\n return `${GLOBAL_CLASS_PREFIX}-${componentName}-${slot}`;\n}\nexport function generateUtilityClass(componentName, slot) {\n const globalStateClass = globalStateClasses[slot];\n return globalStateClass ? buildStateClass(globalStateClass) : buildSlotClass(componentName, slot);\n}\nexport function isGlobalState(slot) {\n return globalStateClasses[slot] !== undefined;\n}","import { generateUtilityClass } from '../generateUtilityClass';\nexport function generateUtilityClasses(componentName, slots) {\n const result = {};\n slots.forEach(slot => {\n result[slot] = generateUtilityClass(componentName, slot);\n });\n return result;\n}","'use client';\n\nimport * as React from 'react';\nimport * as ReactDOM from 'react-dom';\nimport PropTypes from 'prop-types';\nimport { exactProp, HTMLElementType, unstable_useEnhancedEffect as useEnhancedEffect, unstable_useForkRef as useForkRef, unstable_setRef as setRef } from '@mui/utils';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nfunction getContainer(container) {\n return typeof container === 'function' ? container() : container;\n}\n\n/**\n * Portals provide a first-class way to render children into a DOM node\n * that exists outside the DOM hierarchy of the parent component.\n *\n * Demos:\n *\n * - [Portal](https://mui.com/base-ui/react-portal/)\n *\n * API:\n *\n * - [Portal API](https://mui.com/base-ui/react-portal/components-api/#portal)\n */\nconst Portal = /*#__PURE__*/React.forwardRef(function Portal(props, forwardedRef) {\n const {\n children,\n container,\n disablePortal = false\n } = props;\n const [mountNode, setMountNode] = React.useState(null);\n // @ts-expect-error TODO upstream fix\n const handleRef = useForkRef( /*#__PURE__*/React.isValidElement(children) ? children.ref : null, forwardedRef);\n useEnhancedEffect(() => {\n if (!disablePortal) {\n setMountNode(getContainer(container) || document.body);\n }\n }, [container, disablePortal]);\n useEnhancedEffect(() => {\n if (mountNode && !disablePortal) {\n setRef(forwardedRef, mountNode);\n return () => {\n setRef(forwardedRef, null);\n };\n }\n return undefined;\n }, [forwardedRef, mountNode, disablePortal]);\n if (disablePortal) {\n if ( /*#__PURE__*/React.isValidElement(children)) {\n const newProps = {\n ref: handleRef\n };\n return /*#__PURE__*/React.cloneElement(children, newProps);\n }\n return /*#__PURE__*/_jsx(React.Fragment, {\n children: children\n });\n }\n return /*#__PURE__*/_jsx(React.Fragment, {\n children: mountNode ? /*#__PURE__*/ReactDOM.createPortal(children, mountNode) : mountNode\n });\n});\nprocess.env.NODE_ENV !== \"production\" ? Portal.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * The children to render into the `container`.\n */\n children: PropTypes.node,\n /**\n * An HTML element or function that returns one.\n * The `container` will have the portal children appended to it.\n *\n * You can also provide a callback, which is called in a React layout effect.\n * This lets you set the container from a ref, and also makes server-side rendering possible.\n *\n * By default, it uses the body of the top-level document object,\n * so it's simply `document.body` most of the time.\n */\n container: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.func]),\n /**\n * The `children` will be under the DOM hierarchy of the parent component.\n * @default false\n */\n disablePortal: PropTypes.bool\n} : void 0;\nif (process.env.NODE_ENV !== 'production') {\n // eslint-disable-next-line\n Portal['propTypes' + ''] = exactProp(Portal.propTypes);\n}\nexport { Portal };","export var top = 'top';\nexport var bottom = 'bottom';\nexport var right = 'right';\nexport var left = 'left';\nexport var auto = 'auto';\nexport var basePlacements = [top, bottom, right, left];\nexport var start = 'start';\nexport var end = 'end';\nexport var clippingParents = 'clippingParents';\nexport var viewport = 'viewport';\nexport var popper = 'popper';\nexport var reference = 'reference';\nexport var variationPlacements = /*#__PURE__*/basePlacements.reduce(function (acc, placement) {\n return acc.concat([placement + \"-\" + start, placement + \"-\" + end]);\n}, []);\nexport var placements = /*#__PURE__*/[].concat(basePlacements, [auto]).reduce(function (acc, placement) {\n return acc.concat([placement, placement + \"-\" + start, placement + \"-\" + end]);\n}, []); // modifiers that need to read the DOM\n\nexport var beforeRead = 'beforeRead';\nexport var read = 'read';\nexport var afterRead = 'afterRead'; // pure-logic modifiers\n\nexport var beforeMain = 'beforeMain';\nexport var main = 'main';\nexport var afterMain = 'afterMain'; // modifier with the purpose to write to the DOM (or write into a framework state)\n\nexport var beforeWrite = 'beforeWrite';\nexport var write = 'write';\nexport var afterWrite = 'afterWrite';\nexport var modifierPhases = [beforeRead, read, afterRead, beforeMain, main, afterMain, beforeWrite, write, afterWrite];","export default function getNodeName(element) {\n return element ? (element.nodeName || '').toLowerCase() : null;\n}","export default function getWindow(node) {\n if (node == null) {\n return window;\n }\n\n if (node.toString() !== '[object Window]') {\n var ownerDocument = node.ownerDocument;\n return ownerDocument ? ownerDocument.defaultView || window : window;\n }\n\n return node;\n}","import getWindow from \"./getWindow.js\";\n\nfunction isElement(node) {\n var OwnElement = getWindow(node).Element;\n return node instanceof OwnElement || node instanceof Element;\n}\n\nfunction isHTMLElement(node) {\n var OwnElement = getWindow(node).HTMLElement;\n return node instanceof OwnElement || node instanceof HTMLElement;\n}\n\nfunction isShadowRoot(node) {\n // IE 11 has no ShadowRoot\n if (typeof ShadowRoot === 'undefined') {\n return false;\n }\n\n var OwnElement = getWindow(node).ShadowRoot;\n return node instanceof OwnElement || node instanceof ShadowRoot;\n}\n\nexport { isElement, isHTMLElement, isShadowRoot };","import getNodeName from \"../dom-utils/getNodeName.js\";\nimport { isHTMLElement } from \"../dom-utils/instanceOf.js\"; // This modifier takes the styles prepared by the `computeStyles` modifier\n// and applies them to the HTMLElements such as popper and arrow\n\nfunction applyStyles(_ref) {\n var state = _ref.state;\n Object.keys(state.elements).forEach(function (name) {\n var style = state.styles[name] || {};\n var attributes = state.attributes[name] || {};\n var element = state.elements[name]; // arrow is optional + virtual elements\n\n if (!isHTMLElement(element) || !getNodeName(element)) {\n return;\n } // Flow doesn't support to extend this property, but it's the most\n // effective way to apply styles to an HTMLElement\n // $FlowFixMe[cannot-write]\n\n\n Object.assign(element.style, style);\n Object.keys(attributes).forEach(function (name) {\n var value = attributes[name];\n\n if (value === false) {\n element.removeAttribute(name);\n } else {\n element.setAttribute(name, value === true ? '' : value);\n }\n });\n });\n}\n\nfunction effect(_ref2) {\n var state = _ref2.state;\n var initialStyles = {\n popper: {\n position: state.options.strategy,\n left: '0',\n top: '0',\n margin: '0'\n },\n arrow: {\n position: 'absolute'\n },\n reference: {}\n };\n Object.assign(state.elements.popper.style, initialStyles.popper);\n state.styles = initialStyles;\n\n if (state.elements.arrow) {\n Object.assign(state.elements.arrow.style, initialStyles.arrow);\n }\n\n return function () {\n Object.keys(state.elements).forEach(function (name) {\n var element = state.elements[name];\n var attributes = state.attributes[name] || {};\n var styleProperties = Object.keys(state.styles.hasOwnProperty(name) ? state.styles[name] : initialStyles[name]); // Set all values to an empty string to unset them\n\n var style = styleProperties.reduce(function (style, property) {\n style[property] = '';\n return style;\n }, {}); // arrow is optional + virtual elements\n\n if (!isHTMLElement(element) || !getNodeName(element)) {\n return;\n }\n\n Object.assign(element.style, style);\n Object.keys(attributes).forEach(function (attribute) {\n element.removeAttribute(attribute);\n });\n });\n };\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'applyStyles',\n enabled: true,\n phase: 'write',\n fn: applyStyles,\n effect: effect,\n requires: ['computeStyles']\n};","import { auto } from \"../enums.js\";\nexport default function getBasePlacement(placement) {\n return placement.split('-')[0];\n}","export var max = Math.max;\nexport var min = Math.min;\nexport var round = Math.round;","export default function getUAString() {\n var uaData = navigator.userAgentData;\n\n if (uaData != null && uaData.brands && Array.isArray(uaData.brands)) {\n return uaData.brands.map(function (item) {\n return item.brand + \"/\" + item.version;\n }).join(' ');\n }\n\n return navigator.userAgent;\n}","import getUAString from \"../utils/userAgent.js\";\nexport default function isLayoutViewport() {\n return !/^((?!chrome|android).)*safari/i.test(getUAString());\n}","import { isElement, isHTMLElement } from \"./instanceOf.js\";\nimport { round } from \"../utils/math.js\";\nimport getWindow from \"./getWindow.js\";\nimport isLayoutViewport from \"./isLayoutViewport.js\";\nexport default function getBoundingClientRect(element, includeScale, isFixedStrategy) {\n if (includeScale === void 0) {\n includeScale = false;\n }\n\n if (isFixedStrategy === void 0) {\n isFixedStrategy = false;\n }\n\n var clientRect = element.getBoundingClientRect();\n var scaleX = 1;\n var scaleY = 1;\n\n if (includeScale && isHTMLElement(element)) {\n scaleX = element.offsetWidth > 0 ? round(clientRect.width) / element.offsetWidth || 1 : 1;\n scaleY = element.offsetHeight > 0 ? round(clientRect.height) / element.offsetHeight || 1 : 1;\n }\n\n var _ref = isElement(element) ? getWindow(element) : window,\n visualViewport = _ref.visualViewport;\n\n var addVisualOffsets = !isLayoutViewport() && isFixedStrategy;\n var x = (clientRect.left + (addVisualOffsets && visualViewport ? visualViewport.offsetLeft : 0)) / scaleX;\n var y = (clientRect.top + (addVisualOffsets && visualViewport ? visualViewport.offsetTop : 0)) / scaleY;\n var width = clientRect.width / scaleX;\n var height = clientRect.height / scaleY;\n return {\n width: width,\n height: height,\n top: y,\n right: x + width,\n bottom: y + height,\n left: x,\n x: x,\n y: y\n };\n}","import getBoundingClientRect from \"./getBoundingClientRect.js\"; // Returns the layout rect of an element relative to its offsetParent. Layout\n// means it doesn't take into account transforms.\n\nexport default function getLayoutRect(element) {\n var clientRect = getBoundingClientRect(element); // Use the clientRect sizes if it's not been transformed.\n // Fixes https://github.com/popperjs/popper-core/issues/1223\n\n var width = element.offsetWidth;\n var height = element.offsetHeight;\n\n if (Math.abs(clientRect.width - width) <= 1) {\n width = clientRect.width;\n }\n\n if (Math.abs(clientRect.height - height) <= 1) {\n height = clientRect.height;\n }\n\n return {\n x: element.offsetLeft,\n y: element.offsetTop,\n width: width,\n height: height\n };\n}","import { isShadowRoot } from \"./instanceOf.js\";\nexport default function contains(parent, child) {\n var rootNode = child.getRootNode && child.getRootNode(); // First, attempt with faster native method\n\n if (parent.contains(child)) {\n return true;\n } // then fallback to custom implementation with Shadow DOM support\n else if (rootNode && isShadowRoot(rootNode)) {\n var next = child;\n\n do {\n if (next && parent.isSameNode(next)) {\n return true;\n } // $FlowFixMe[prop-missing]: need a better way to handle this...\n\n\n next = next.parentNode || next.host;\n } while (next);\n } // Give up, the result is false\n\n\n return false;\n}","import getWindow from \"./getWindow.js\";\nexport default function getComputedStyle(element) {\n return getWindow(element).getComputedStyle(element);\n}","import getNodeName from \"./getNodeName.js\";\nexport default function isTableElement(element) {\n return ['table', 'td', 'th'].indexOf(getNodeName(element)) >= 0;\n}","import { isElement } from \"./instanceOf.js\";\nexport default function getDocumentElement(element) {\n // $FlowFixMe[incompatible-return]: assume body is always available\n return ((isElement(element) ? element.ownerDocument : // $FlowFixMe[prop-missing]\n element.document) || window.document).documentElement;\n}","import getNodeName from \"./getNodeName.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport { isShadowRoot } from \"./instanceOf.js\";\nexport default function getParentNode(element) {\n if (getNodeName(element) === 'html') {\n return element;\n }\n\n return (// this is a quicker (but less type safe) way to save quite some bytes from the bundle\n // $FlowFixMe[incompatible-return]\n // $FlowFixMe[prop-missing]\n element.assignedSlot || // step into the shadow DOM of the parent of a slotted node\n element.parentNode || ( // DOM Element detected\n isShadowRoot(element) ? element.host : null) || // ShadowRoot detected\n // $FlowFixMe[incompatible-call]: HTMLElement is a Node\n getDocumentElement(element) // fallback\n\n );\n}","import getWindow from \"./getWindow.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport getComputedStyle from \"./getComputedStyle.js\";\nimport { isHTMLElement, isShadowRoot } from \"./instanceOf.js\";\nimport isTableElement from \"./isTableElement.js\";\nimport getParentNode from \"./getParentNode.js\";\nimport getUAString from \"../utils/userAgent.js\";\n\nfunction getTrueOffsetParent(element) {\n if (!isHTMLElement(element) || // https://github.com/popperjs/popper-core/issues/837\n getComputedStyle(element).position === 'fixed') {\n return null;\n }\n\n return element.offsetParent;\n} // `.offsetParent` reports `null` for fixed elements, while absolute elements\n// return the containing block\n\n\nfunction getContainingBlock(element) {\n var isFirefox = /firefox/i.test(getUAString());\n var isIE = /Trident/i.test(getUAString());\n\n if (isIE && isHTMLElement(element)) {\n // In IE 9, 10 and 11 fixed elements containing block is always established by the viewport\n var elementCss = getComputedStyle(element);\n\n if (elementCss.position === 'fixed') {\n return null;\n }\n }\n\n var currentNode = getParentNode(element);\n\n if (isShadowRoot(currentNode)) {\n currentNode = currentNode.host;\n }\n\n while (isHTMLElement(currentNode) && ['html', 'body'].indexOf(getNodeName(currentNode)) < 0) {\n var css = getComputedStyle(currentNode); // This is non-exhaustive but covers the most common CSS properties that\n // create a containing block.\n // https://developer.mozilla.org/en-US/docs/Web/CSS/Containing_block#identifying_the_containing_block\n\n if (css.transform !== 'none' || css.perspective !== 'none' || css.contain === 'paint' || ['transform', 'perspective'].indexOf(css.willChange) !== -1 || isFirefox && css.willChange === 'filter' || isFirefox && css.filter && css.filter !== 'none') {\n return currentNode;\n } else {\n currentNode = currentNode.parentNode;\n }\n }\n\n return null;\n} // Gets the closest ancestor positioned element. Handles some edge cases,\n// such as table ancestors and cross browser bugs.\n\n\nexport default function getOffsetParent(element) {\n var window = getWindow(element);\n var offsetParent = getTrueOffsetParent(element);\n\n while (offsetParent && isTableElement(offsetParent) && getComputedStyle(offsetParent).position === 'static') {\n offsetParent = getTrueOffsetParent(offsetParent);\n }\n\n if (offsetParent && (getNodeName(offsetParent) === 'html' || getNodeName(offsetParent) === 'body' && getComputedStyle(offsetParent).position === 'static')) {\n return window;\n }\n\n return offsetParent || getContainingBlock(element) || window;\n}","export default function getMainAxisFromPlacement(placement) {\n return ['top', 'bottom'].indexOf(placement) >= 0 ? 'x' : 'y';\n}","import { max as mathMax, min as mathMin } from \"./math.js\";\nexport function within(min, value, max) {\n return mathMax(min, mathMin(value, max));\n}\nexport function withinMaxClamp(min, value, max) {\n var v = within(min, value, max);\n return v > max ? max : v;\n}","export default function getFreshSideObject() {\n return {\n top: 0,\n right: 0,\n bottom: 0,\n left: 0\n };\n}","import getFreshSideObject from \"./getFreshSideObject.js\";\nexport default function mergePaddingObject(paddingObject) {\n return Object.assign({}, getFreshSideObject(), paddingObject);\n}","export default function expandToHashMap(value, keys) {\n return keys.reduce(function (hashMap, key) {\n hashMap[key] = value;\n return hashMap;\n }, {});\n}","import getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getLayoutRect from \"../dom-utils/getLayoutRect.js\";\nimport contains from \"../dom-utils/contains.js\";\nimport getOffsetParent from \"../dom-utils/getOffsetParent.js\";\nimport getMainAxisFromPlacement from \"../utils/getMainAxisFromPlacement.js\";\nimport { within } from \"../utils/within.js\";\nimport mergePaddingObject from \"../utils/mergePaddingObject.js\";\nimport expandToHashMap from \"../utils/expandToHashMap.js\";\nimport { left, right, basePlacements, top, bottom } from \"../enums.js\"; // eslint-disable-next-line import/no-unused-modules\n\nvar toPaddingObject = function toPaddingObject(padding, state) {\n padding = typeof padding === 'function' ? padding(Object.assign({}, state.rects, {\n placement: state.placement\n })) : padding;\n return mergePaddingObject(typeof padding !== 'number' ? padding : expandToHashMap(padding, basePlacements));\n};\n\nfunction arrow(_ref) {\n var _state$modifiersData$;\n\n var state = _ref.state,\n name = _ref.name,\n options = _ref.options;\n var arrowElement = state.elements.arrow;\n var popperOffsets = state.modifiersData.popperOffsets;\n var basePlacement = getBasePlacement(state.placement);\n var axis = getMainAxisFromPlacement(basePlacement);\n var isVertical = [left, right].indexOf(basePlacement) >= 0;\n var len = isVertical ? 'height' : 'width';\n\n if (!arrowElement || !popperOffsets) {\n return;\n }\n\n var paddingObject = toPaddingObject(options.padding, state);\n var arrowRect = getLayoutRect(arrowElement);\n var minProp = axis === 'y' ? top : left;\n var maxProp = axis === 'y' ? bottom : right;\n var endDiff = state.rects.reference[len] + state.rects.reference[axis] - popperOffsets[axis] - state.rects.popper[len];\n var startDiff = popperOffsets[axis] - state.rects.reference[axis];\n var arrowOffsetParent = getOffsetParent(arrowElement);\n var clientSize = arrowOffsetParent ? axis === 'y' ? arrowOffsetParent.clientHeight || 0 : arrowOffsetParent.clientWidth || 0 : 0;\n var centerToReference = endDiff / 2 - startDiff / 2; // Make sure the arrow doesn't overflow the popper if the center point is\n // outside of the popper bounds\n\n var min = paddingObject[minProp];\n var max = clientSize - arrowRect[len] - paddingObject[maxProp];\n var center = clientSize / 2 - arrowRect[len] / 2 + centerToReference;\n var offset = within(min, center, max); // Prevents breaking syntax highlighting...\n\n var axisProp = axis;\n state.modifiersData[name] = (_state$modifiersData$ = {}, _state$modifiersData$[axisProp] = offset, _state$modifiersData$.centerOffset = offset - center, _state$modifiersData$);\n}\n\nfunction effect(_ref2) {\n var state = _ref2.state,\n options = _ref2.options;\n var _options$element = options.element,\n arrowElement = _options$element === void 0 ? '[data-popper-arrow]' : _options$element;\n\n if (arrowElement == null) {\n return;\n } // CSS selector\n\n\n if (typeof arrowElement === 'string') {\n arrowElement = state.elements.popper.querySelector(arrowElement);\n\n if (!arrowElement) {\n return;\n }\n }\n\n if (!contains(state.elements.popper, arrowElement)) {\n return;\n }\n\n state.elements.arrow = arrowElement;\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'arrow',\n enabled: true,\n phase: 'main',\n fn: arrow,\n effect: effect,\n requires: ['popperOffsets'],\n requiresIfExists: ['preventOverflow']\n};","export default function getVariation(placement) {\n return placement.split('-')[1];\n}","import { top, left, right, bottom, end } from \"../enums.js\";\nimport getOffsetParent from \"../dom-utils/getOffsetParent.js\";\nimport getWindow from \"../dom-utils/getWindow.js\";\nimport getDocumentElement from \"../dom-utils/getDocumentElement.js\";\nimport getComputedStyle from \"../dom-utils/getComputedStyle.js\";\nimport getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getVariation from \"../utils/getVariation.js\";\nimport { round } from \"../utils/math.js\"; // eslint-disable-next-line import/no-unused-modules\n\nvar unsetSides = {\n top: 'auto',\n right: 'auto',\n bottom: 'auto',\n left: 'auto'\n}; // Round the offsets to the nearest suitable subpixel based on the DPR.\n// Zooming can change the DPR, but it seems to report a value that will\n// cleanly divide the values into the appropriate subpixels.\n\nfunction roundOffsetsByDPR(_ref, win) {\n var x = _ref.x,\n y = _ref.y;\n var dpr = win.devicePixelRatio || 1;\n return {\n x: round(x * dpr) / dpr || 0,\n y: round(y * dpr) / dpr || 0\n };\n}\n\nexport function mapToStyles(_ref2) {\n var _Object$assign2;\n\n var popper = _ref2.popper,\n popperRect = _ref2.popperRect,\n placement = _ref2.placement,\n variation = _ref2.variation,\n offsets = _ref2.offsets,\n position = _ref2.position,\n gpuAcceleration = _ref2.gpuAcceleration,\n adaptive = _ref2.adaptive,\n roundOffsets = _ref2.roundOffsets,\n isFixed = _ref2.isFixed;\n var _offsets$x = offsets.x,\n x = _offsets$x === void 0 ? 0 : _offsets$x,\n _offsets$y = offsets.y,\n y = _offsets$y === void 0 ? 0 : _offsets$y;\n\n var _ref3 = typeof roundOffsets === 'function' ? roundOffsets({\n x: x,\n y: y\n }) : {\n x: x,\n y: y\n };\n\n x = _ref3.x;\n y = _ref3.y;\n var hasX = offsets.hasOwnProperty('x');\n var hasY = offsets.hasOwnProperty('y');\n var sideX = left;\n var sideY = top;\n var win = window;\n\n if (adaptive) {\n var offsetParent = getOffsetParent(popper);\n var heightProp = 'clientHeight';\n var widthProp = 'clientWidth';\n\n if (offsetParent === getWindow(popper)) {\n offsetParent = getDocumentElement(popper);\n\n if (getComputedStyle(offsetParent).position !== 'static' && position === 'absolute') {\n heightProp = 'scrollHeight';\n widthProp = 'scrollWidth';\n }\n } // $FlowFixMe[incompatible-cast]: force type refinement, we compare offsetParent with window above, but Flow doesn't detect it\n\n\n offsetParent = offsetParent;\n\n if (placement === top || (placement === left || placement === right) && variation === end) {\n sideY = bottom;\n var offsetY = isFixed && offsetParent === win && win.visualViewport ? win.visualViewport.height : // $FlowFixMe[prop-missing]\n offsetParent[heightProp];\n y -= offsetY - popperRect.height;\n y *= gpuAcceleration ? 1 : -1;\n }\n\n if (placement === left || (placement === top || placement === bottom) && variation === end) {\n sideX = right;\n var offsetX = isFixed && offsetParent === win && win.visualViewport ? win.visualViewport.width : // $FlowFixMe[prop-missing]\n offsetParent[widthProp];\n x -= offsetX - popperRect.width;\n x *= gpuAcceleration ? 1 : -1;\n }\n }\n\n var commonStyles = Object.assign({\n position: position\n }, adaptive && unsetSides);\n\n var _ref4 = roundOffsets === true ? roundOffsetsByDPR({\n x: x,\n y: y\n }, getWindow(popper)) : {\n x: x,\n y: y\n };\n\n x = _ref4.x;\n y = _ref4.y;\n\n if (gpuAcceleration) {\n var _Object$assign;\n\n return Object.assign({}, commonStyles, (_Object$assign = {}, _Object$assign[sideY] = hasY ? '0' : '', _Object$assign[sideX] = hasX ? '0' : '', _Object$assign.transform = (win.devicePixelRatio || 1) <= 1 ? \"translate(\" + x + \"px, \" + y + \"px)\" : \"translate3d(\" + x + \"px, \" + y + \"px, 0)\", _Object$assign));\n }\n\n return Object.assign({}, commonStyles, (_Object$assign2 = {}, _Object$assign2[sideY] = hasY ? y + \"px\" : '', _Object$assign2[sideX] = hasX ? x + \"px\" : '', _Object$assign2.transform = '', _Object$assign2));\n}\n\nfunction computeStyles(_ref5) {\n var state = _ref5.state,\n options = _ref5.options;\n var _options$gpuAccelerat = options.gpuAcceleration,\n gpuAcceleration = _options$gpuAccelerat === void 0 ? true : _options$gpuAccelerat,\n _options$adaptive = options.adaptive,\n adaptive = _options$adaptive === void 0 ? true : _options$adaptive,\n _options$roundOffsets = options.roundOffsets,\n roundOffsets = _options$roundOffsets === void 0 ? true : _options$roundOffsets;\n var commonStyles = {\n placement: getBasePlacement(state.placement),\n variation: getVariation(state.placement),\n popper: state.elements.popper,\n popperRect: state.rects.popper,\n gpuAcceleration: gpuAcceleration,\n isFixed: state.options.strategy === 'fixed'\n };\n\n if (state.modifiersData.popperOffsets != null) {\n state.styles.popper = Object.assign({}, state.styles.popper, mapToStyles(Object.assign({}, commonStyles, {\n offsets: state.modifiersData.popperOffsets,\n position: state.options.strategy,\n adaptive: adaptive,\n roundOffsets: roundOffsets\n })));\n }\n\n if (state.modifiersData.arrow != null) {\n state.styles.arrow = Object.assign({}, state.styles.arrow, mapToStyles(Object.assign({}, commonStyles, {\n offsets: state.modifiersData.arrow,\n position: 'absolute',\n adaptive: false,\n roundOffsets: roundOffsets\n })));\n }\n\n state.attributes.popper = Object.assign({}, state.attributes.popper, {\n 'data-popper-placement': state.placement\n });\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'computeStyles',\n enabled: true,\n phase: 'beforeWrite',\n fn: computeStyles,\n data: {}\n};","import getWindow from \"../dom-utils/getWindow.js\"; // eslint-disable-next-line import/no-unused-modules\n\nvar passive = {\n passive: true\n};\n\nfunction effect(_ref) {\n var state = _ref.state,\n instance = _ref.instance,\n options = _ref.options;\n var _options$scroll = options.scroll,\n scroll = _options$scroll === void 0 ? true : _options$scroll,\n _options$resize = options.resize,\n resize = _options$resize === void 0 ? true : _options$resize;\n var window = getWindow(state.elements.popper);\n var scrollParents = [].concat(state.scrollParents.reference, state.scrollParents.popper);\n\n if (scroll) {\n scrollParents.forEach(function (scrollParent) {\n scrollParent.addEventListener('scroll', instance.update, passive);\n });\n }\n\n if (resize) {\n window.addEventListener('resize', instance.update, passive);\n }\n\n return function () {\n if (scroll) {\n scrollParents.forEach(function (scrollParent) {\n scrollParent.removeEventListener('scroll', instance.update, passive);\n });\n }\n\n if (resize) {\n window.removeEventListener('resize', instance.update, passive);\n }\n };\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'eventListeners',\n enabled: true,\n phase: 'write',\n fn: function fn() {},\n effect: effect,\n data: {}\n};","var hash = {\n left: 'right',\n right: 'left',\n bottom: 'top',\n top: 'bottom'\n};\nexport default function getOppositePlacement(placement) {\n return placement.replace(/left|right|bottom|top/g, function (matched) {\n return hash[matched];\n });\n}","var hash = {\n start: 'end',\n end: 'start'\n};\nexport default function getOppositeVariationPlacement(placement) {\n return placement.replace(/start|end/g, function (matched) {\n return hash[matched];\n });\n}","import getWindow from \"./getWindow.js\";\nexport default function getWindowScroll(node) {\n var win = getWindow(node);\n var scrollLeft = win.pageXOffset;\n var scrollTop = win.pageYOffset;\n return {\n scrollLeft: scrollLeft,\n scrollTop: scrollTop\n };\n}","import getBoundingClientRect from \"./getBoundingClientRect.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport getWindowScroll from \"./getWindowScroll.js\";\nexport default function getWindowScrollBarX(element) {\n // If has a CSS width greater than the viewport, then this will be\n // incorrect for RTL.\n // Popper 1 is broken in this case and never had a bug report so let's assume\n // it's not an issue. I don't think anyone ever specifies width on \n // anyway.\n // Browsers where the left scrollbar doesn't cause an issue report `0` for\n // this (e.g. Edge 2019, IE11, Safari)\n return getBoundingClientRect(getDocumentElement(element)).left + getWindowScroll(element).scrollLeft;\n}","import getWindow from \"./getWindow.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport getWindowScrollBarX from \"./getWindowScrollBarX.js\";\nimport isLayoutViewport from \"./isLayoutViewport.js\";\nexport default function getViewportRect(element, strategy) {\n var win = getWindow(element);\n var html = getDocumentElement(element);\n var visualViewport = win.visualViewport;\n var width = html.clientWidth;\n var height = html.clientHeight;\n var x = 0;\n var y = 0;\n\n if (visualViewport) {\n width = visualViewport.width;\n height = visualViewport.height;\n var layoutViewport = isLayoutViewport();\n\n if (layoutViewport || !layoutViewport && strategy === 'fixed') {\n x = visualViewport.offsetLeft;\n y = visualViewport.offsetTop;\n }\n }\n\n return {\n width: width,\n height: height,\n x: x + getWindowScrollBarX(element),\n y: y\n };\n}","import getDocumentElement from \"./getDocumentElement.js\";\nimport getComputedStyle from \"./getComputedStyle.js\";\nimport getWindowScrollBarX from \"./getWindowScrollBarX.js\";\nimport getWindowScroll from \"./getWindowScroll.js\";\nimport { max } from \"../utils/math.js\"; // Gets the entire size of the scrollable document area, even extending outside\n// of the `` and `` rect bounds if horizontally scrollable\n\nexport default function getDocumentRect(element) {\n var _element$ownerDocumen;\n\n var html = getDocumentElement(element);\n var winScroll = getWindowScroll(element);\n var body = (_element$ownerDocumen = element.ownerDocument) == null ? void 0 : _element$ownerDocumen.body;\n var width = max(html.scrollWidth, html.clientWidth, body ? body.scrollWidth : 0, body ? body.clientWidth : 0);\n var height = max(html.scrollHeight, html.clientHeight, body ? body.scrollHeight : 0, body ? body.clientHeight : 0);\n var x = -winScroll.scrollLeft + getWindowScrollBarX(element);\n var y = -winScroll.scrollTop;\n\n if (getComputedStyle(body || html).direction === 'rtl') {\n x += max(html.clientWidth, body ? body.clientWidth : 0) - width;\n }\n\n return {\n width: width,\n height: height,\n x: x,\n y: y\n };\n}","import getComputedStyle from \"./getComputedStyle.js\";\nexport default function isScrollParent(element) {\n // Firefox wants us to check `-x` and `-y` variations as well\n var _getComputedStyle = getComputedStyle(element),\n overflow = _getComputedStyle.overflow,\n overflowX = _getComputedStyle.overflowX,\n overflowY = _getComputedStyle.overflowY;\n\n return /auto|scroll|overlay|hidden/.test(overflow + overflowY + overflowX);\n}","import getParentNode from \"./getParentNode.js\";\nimport isScrollParent from \"./isScrollParent.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport { isHTMLElement } from \"./instanceOf.js\";\nexport default function getScrollParent(node) {\n if (['html', 'body', '#document'].indexOf(getNodeName(node)) >= 0) {\n // $FlowFixMe[incompatible-return]: assume body is always available\n return node.ownerDocument.body;\n }\n\n if (isHTMLElement(node) && isScrollParent(node)) {\n return node;\n }\n\n return getScrollParent(getParentNode(node));\n}","import getScrollParent from \"./getScrollParent.js\";\nimport getParentNode from \"./getParentNode.js\";\nimport getWindow from \"./getWindow.js\";\nimport isScrollParent from \"./isScrollParent.js\";\n/*\ngiven a DOM element, return the list of all scroll parents, up the list of ancesors\nuntil we get to the top window object. This list is what we attach scroll listeners\nto, because if any of these parent elements scroll, we'll need to re-calculate the\nreference element's position.\n*/\n\nexport default function listScrollParents(element, list) {\n var _element$ownerDocumen;\n\n if (list === void 0) {\n list = [];\n }\n\n var scrollParent = getScrollParent(element);\n var isBody = scrollParent === ((_element$ownerDocumen = element.ownerDocument) == null ? void 0 : _element$ownerDocumen.body);\n var win = getWindow(scrollParent);\n var target = isBody ? [win].concat(win.visualViewport || [], isScrollParent(scrollParent) ? scrollParent : []) : scrollParent;\n var updatedList = list.concat(target);\n return isBody ? updatedList : // $FlowFixMe[incompatible-call]: isBody tells us target will be an HTMLElement here\n updatedList.concat(listScrollParents(getParentNode(target)));\n}","export default function rectToClientRect(rect) {\n return Object.assign({}, rect, {\n left: rect.x,\n top: rect.y,\n right: rect.x + rect.width,\n bottom: rect.y + rect.height\n });\n}","import { viewport } from \"../enums.js\";\nimport getViewportRect from \"./getViewportRect.js\";\nimport getDocumentRect from \"./getDocumentRect.js\";\nimport listScrollParents from \"./listScrollParents.js\";\nimport getOffsetParent from \"./getOffsetParent.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport getComputedStyle from \"./getComputedStyle.js\";\nimport { isElement, isHTMLElement } from \"./instanceOf.js\";\nimport getBoundingClientRect from \"./getBoundingClientRect.js\";\nimport getParentNode from \"./getParentNode.js\";\nimport contains from \"./contains.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport rectToClientRect from \"../utils/rectToClientRect.js\";\nimport { max, min } from \"../utils/math.js\";\n\nfunction getInnerBoundingClientRect(element, strategy) {\n var rect = getBoundingClientRect(element, false, strategy === 'fixed');\n rect.top = rect.top + element.clientTop;\n rect.left = rect.left + element.clientLeft;\n rect.bottom = rect.top + element.clientHeight;\n rect.right = rect.left + element.clientWidth;\n rect.width = element.clientWidth;\n rect.height = element.clientHeight;\n rect.x = rect.left;\n rect.y = rect.top;\n return rect;\n}\n\nfunction getClientRectFromMixedType(element, clippingParent, strategy) {\n return clippingParent === viewport ? rectToClientRect(getViewportRect(element, strategy)) : isElement(clippingParent) ? getInnerBoundingClientRect(clippingParent, strategy) : rectToClientRect(getDocumentRect(getDocumentElement(element)));\n} // A \"clipping parent\" is an overflowable container with the characteristic of\n// clipping (or hiding) overflowing elements with a position different from\n// `initial`\n\n\nfunction getClippingParents(element) {\n var clippingParents = listScrollParents(getParentNode(element));\n var canEscapeClipping = ['absolute', 'fixed'].indexOf(getComputedStyle(element).position) >= 0;\n var clipperElement = canEscapeClipping && isHTMLElement(element) ? getOffsetParent(element) : element;\n\n if (!isElement(clipperElement)) {\n return [];\n } // $FlowFixMe[incompatible-return]: https://github.com/facebook/flow/issues/1414\n\n\n return clippingParents.filter(function (clippingParent) {\n return isElement(clippingParent) && contains(clippingParent, clipperElement) && getNodeName(clippingParent) !== 'body';\n });\n} // Gets the maximum area that the element is visible in due to any number of\n// clipping parents\n\n\nexport default function getClippingRect(element, boundary, rootBoundary, strategy) {\n var mainClippingParents = boundary === 'clippingParents' ? getClippingParents(element) : [].concat(boundary);\n var clippingParents = [].concat(mainClippingParents, [rootBoundary]);\n var firstClippingParent = clippingParents[0];\n var clippingRect = clippingParents.reduce(function (accRect, clippingParent) {\n var rect = getClientRectFromMixedType(element, clippingParent, strategy);\n accRect.top = max(rect.top, accRect.top);\n accRect.right = min(rect.right, accRect.right);\n accRect.bottom = min(rect.bottom, accRect.bottom);\n accRect.left = max(rect.left, accRect.left);\n return accRect;\n }, getClientRectFromMixedType(element, firstClippingParent, strategy));\n clippingRect.width = clippingRect.right - clippingRect.left;\n clippingRect.height = clippingRect.bottom - clippingRect.top;\n clippingRect.x = clippingRect.left;\n clippingRect.y = clippingRect.top;\n return clippingRect;\n}","import getBasePlacement from \"./getBasePlacement.js\";\nimport getVariation from \"./getVariation.js\";\nimport getMainAxisFromPlacement from \"./getMainAxisFromPlacement.js\";\nimport { top, right, bottom, left, start, end } from \"../enums.js\";\nexport default function computeOffsets(_ref) {\n var reference = _ref.reference,\n element = _ref.element,\n placement = _ref.placement;\n var basePlacement = placement ? getBasePlacement(placement) : null;\n var variation = placement ? getVariation(placement) : null;\n var commonX = reference.x + reference.width / 2 - element.width / 2;\n var commonY = reference.y + reference.height / 2 - element.height / 2;\n var offsets;\n\n switch (basePlacement) {\n case top:\n offsets = {\n x: commonX,\n y: reference.y - element.height\n };\n break;\n\n case bottom:\n offsets = {\n x: commonX,\n y: reference.y + reference.height\n };\n break;\n\n case right:\n offsets = {\n x: reference.x + reference.width,\n y: commonY\n };\n break;\n\n case left:\n offsets = {\n x: reference.x - element.width,\n y: commonY\n };\n break;\n\n default:\n offsets = {\n x: reference.x,\n y: reference.y\n };\n }\n\n var mainAxis = basePlacement ? getMainAxisFromPlacement(basePlacement) : null;\n\n if (mainAxis != null) {\n var len = mainAxis === 'y' ? 'height' : 'width';\n\n switch (variation) {\n case start:\n offsets[mainAxis] = offsets[mainAxis] - (reference[len] / 2 - element[len] / 2);\n break;\n\n case end:\n offsets[mainAxis] = offsets[mainAxis] + (reference[len] / 2 - element[len] / 2);\n break;\n\n default:\n }\n }\n\n return offsets;\n}","import getClippingRect from \"../dom-utils/getClippingRect.js\";\nimport getDocumentElement from \"../dom-utils/getDocumentElement.js\";\nimport getBoundingClientRect from \"../dom-utils/getBoundingClientRect.js\";\nimport computeOffsets from \"./computeOffsets.js\";\nimport rectToClientRect from \"./rectToClientRect.js\";\nimport { clippingParents, reference, popper, bottom, top, right, basePlacements, viewport } from \"../enums.js\";\nimport { isElement } from \"../dom-utils/instanceOf.js\";\nimport mergePaddingObject from \"./mergePaddingObject.js\";\nimport expandToHashMap from \"./expandToHashMap.js\"; // eslint-disable-next-line import/no-unused-modules\n\nexport default function detectOverflow(state, options) {\n if (options === void 0) {\n options = {};\n }\n\n var _options = options,\n _options$placement = _options.placement,\n placement = _options$placement === void 0 ? state.placement : _options$placement,\n _options$strategy = _options.strategy,\n strategy = _options$strategy === void 0 ? state.strategy : _options$strategy,\n _options$boundary = _options.boundary,\n boundary = _options$boundary === void 0 ? clippingParents : _options$boundary,\n _options$rootBoundary = _options.rootBoundary,\n rootBoundary = _options$rootBoundary === void 0 ? viewport : _options$rootBoundary,\n _options$elementConte = _options.elementContext,\n elementContext = _options$elementConte === void 0 ? popper : _options$elementConte,\n _options$altBoundary = _options.altBoundary,\n altBoundary = _options$altBoundary === void 0 ? false : _options$altBoundary,\n _options$padding = _options.padding,\n padding = _options$padding === void 0 ? 0 : _options$padding;\n var paddingObject = mergePaddingObject(typeof padding !== 'number' ? padding : expandToHashMap(padding, basePlacements));\n var altContext = elementContext === popper ? reference : popper;\n var popperRect = state.rects.popper;\n var element = state.elements[altBoundary ? altContext : elementContext];\n var clippingClientRect = getClippingRect(isElement(element) ? element : element.contextElement || getDocumentElement(state.elements.popper), boundary, rootBoundary, strategy);\n var referenceClientRect = getBoundingClientRect(state.elements.reference);\n var popperOffsets = computeOffsets({\n reference: referenceClientRect,\n element: popperRect,\n strategy: 'absolute',\n placement: placement\n });\n var popperClientRect = rectToClientRect(Object.assign({}, popperRect, popperOffsets));\n var elementClientRect = elementContext === popper ? popperClientRect : referenceClientRect; // positive = overflowing the clipping rect\n // 0 or negative = within the clipping rect\n\n var overflowOffsets = {\n top: clippingClientRect.top - elementClientRect.top + paddingObject.top,\n bottom: elementClientRect.bottom - clippingClientRect.bottom + paddingObject.bottom,\n left: clippingClientRect.left - elementClientRect.left + paddingObject.left,\n right: elementClientRect.right - clippingClientRect.right + paddingObject.right\n };\n var offsetData = state.modifiersData.offset; // Offsets can be applied only to the popper element\n\n if (elementContext === popper && offsetData) {\n var offset = offsetData[placement];\n Object.keys(overflowOffsets).forEach(function (key) {\n var multiply = [right, bottom].indexOf(key) >= 0 ? 1 : -1;\n var axis = [top, bottom].indexOf(key) >= 0 ? 'y' : 'x';\n overflowOffsets[key] += offset[axis] * multiply;\n });\n }\n\n return overflowOffsets;\n}","import getVariation from \"./getVariation.js\";\nimport { variationPlacements, basePlacements, placements as allPlacements } from \"../enums.js\";\nimport detectOverflow from \"./detectOverflow.js\";\nimport getBasePlacement from \"./getBasePlacement.js\";\nexport default function computeAutoPlacement(state, options) {\n if (options === void 0) {\n options = {};\n }\n\n var _options = options,\n placement = _options.placement,\n boundary = _options.boundary,\n rootBoundary = _options.rootBoundary,\n padding = _options.padding,\n flipVariations = _options.flipVariations,\n _options$allowedAutoP = _options.allowedAutoPlacements,\n allowedAutoPlacements = _options$allowedAutoP === void 0 ? allPlacements : _options$allowedAutoP;\n var variation = getVariation(placement);\n var placements = variation ? flipVariations ? variationPlacements : variationPlacements.filter(function (placement) {\n return getVariation(placement) === variation;\n }) : basePlacements;\n var allowedPlacements = placements.filter(function (placement) {\n return allowedAutoPlacements.indexOf(placement) >= 0;\n });\n\n if (allowedPlacements.length === 0) {\n allowedPlacements = placements;\n } // $FlowFixMe[incompatible-type]: Flow seems to have problems with two array unions...\n\n\n var overflows = allowedPlacements.reduce(function (acc, placement) {\n acc[placement] = detectOverflow(state, {\n placement: placement,\n boundary: boundary,\n rootBoundary: rootBoundary,\n padding: padding\n })[getBasePlacement(placement)];\n return acc;\n }, {});\n return Object.keys(overflows).sort(function (a, b) {\n return overflows[a] - overflows[b];\n });\n}","import getOppositePlacement from \"../utils/getOppositePlacement.js\";\nimport getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getOppositeVariationPlacement from \"../utils/getOppositeVariationPlacement.js\";\nimport detectOverflow from \"../utils/detectOverflow.js\";\nimport computeAutoPlacement from \"../utils/computeAutoPlacement.js\";\nimport { bottom, top, start, right, left, auto } from \"../enums.js\";\nimport getVariation from \"../utils/getVariation.js\"; // eslint-disable-next-line import/no-unused-modules\n\nfunction getExpandedFallbackPlacements(placement) {\n if (getBasePlacement(placement) === auto) {\n return [];\n }\n\n var oppositePlacement = getOppositePlacement(placement);\n return [getOppositeVariationPlacement(placement), oppositePlacement, getOppositeVariationPlacement(oppositePlacement)];\n}\n\nfunction flip(_ref) {\n var state = _ref.state,\n options = _ref.options,\n name = _ref.name;\n\n if (state.modifiersData[name]._skip) {\n return;\n }\n\n var _options$mainAxis = options.mainAxis,\n checkMainAxis = _options$mainAxis === void 0 ? true : _options$mainAxis,\n _options$altAxis = options.altAxis,\n checkAltAxis = _options$altAxis === void 0 ? true : _options$altAxis,\n specifiedFallbackPlacements = options.fallbackPlacements,\n padding = options.padding,\n boundary = options.boundary,\n rootBoundary = options.rootBoundary,\n altBoundary = options.altBoundary,\n _options$flipVariatio = options.flipVariations,\n flipVariations = _options$flipVariatio === void 0 ? true : _options$flipVariatio,\n allowedAutoPlacements = options.allowedAutoPlacements;\n var preferredPlacement = state.options.placement;\n var basePlacement = getBasePlacement(preferredPlacement);\n var isBasePlacement = basePlacement === preferredPlacement;\n var fallbackPlacements = specifiedFallbackPlacements || (isBasePlacement || !flipVariations ? [getOppositePlacement(preferredPlacement)] : getExpandedFallbackPlacements(preferredPlacement));\n var placements = [preferredPlacement].concat(fallbackPlacements).reduce(function (acc, placement) {\n return acc.concat(getBasePlacement(placement) === auto ? computeAutoPlacement(state, {\n placement: placement,\n boundary: boundary,\n rootBoundary: rootBoundary,\n padding: padding,\n flipVariations: flipVariations,\n allowedAutoPlacements: allowedAutoPlacements\n }) : placement);\n }, []);\n var referenceRect = state.rects.reference;\n var popperRect = state.rects.popper;\n var checksMap = new Map();\n var makeFallbackChecks = true;\n var firstFittingPlacement = placements[0];\n\n for (var i = 0; i < placements.length; i++) {\n var placement = placements[i];\n\n var _basePlacement = getBasePlacement(placement);\n\n var isStartVariation = getVariation(placement) === start;\n var isVertical = [top, bottom].indexOf(_basePlacement) >= 0;\n var len = isVertical ? 'width' : 'height';\n var overflow = detectOverflow(state, {\n placement: placement,\n boundary: boundary,\n rootBoundary: rootBoundary,\n altBoundary: altBoundary,\n padding: padding\n });\n var mainVariationSide = isVertical ? isStartVariation ? right : left : isStartVariation ? bottom : top;\n\n if (referenceRect[len] > popperRect[len]) {\n mainVariationSide = getOppositePlacement(mainVariationSide);\n }\n\n var altVariationSide = getOppositePlacement(mainVariationSide);\n var checks = [];\n\n if (checkMainAxis) {\n checks.push(overflow[_basePlacement] <= 0);\n }\n\n if (checkAltAxis) {\n checks.push(overflow[mainVariationSide] <= 0, overflow[altVariationSide] <= 0);\n }\n\n if (checks.every(function (check) {\n return check;\n })) {\n firstFittingPlacement = placement;\n makeFallbackChecks = false;\n break;\n }\n\n checksMap.set(placement, checks);\n }\n\n if (makeFallbackChecks) {\n // `2` may be desired in some cases – research later\n var numberOfChecks = flipVariations ? 3 : 1;\n\n var _loop = function _loop(_i) {\n var fittingPlacement = placements.find(function (placement) {\n var checks = checksMap.get(placement);\n\n if (checks) {\n return checks.slice(0, _i).every(function (check) {\n return check;\n });\n }\n });\n\n if (fittingPlacement) {\n firstFittingPlacement = fittingPlacement;\n return \"break\";\n }\n };\n\n for (var _i = numberOfChecks; _i > 0; _i--) {\n var _ret = _loop(_i);\n\n if (_ret === \"break\") break;\n }\n }\n\n if (state.placement !== firstFittingPlacement) {\n state.modifiersData[name]._skip = true;\n state.placement = firstFittingPlacement;\n state.reset = true;\n }\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'flip',\n enabled: true,\n phase: 'main',\n fn: flip,\n requiresIfExists: ['offset'],\n data: {\n _skip: false\n }\n};","import { top, bottom, left, right } from \"../enums.js\";\nimport detectOverflow from \"../utils/detectOverflow.js\";\n\nfunction getSideOffsets(overflow, rect, preventedOffsets) {\n if (preventedOffsets === void 0) {\n preventedOffsets = {\n x: 0,\n y: 0\n };\n }\n\n return {\n top: overflow.top - rect.height - preventedOffsets.y,\n right: overflow.right - rect.width + preventedOffsets.x,\n bottom: overflow.bottom - rect.height + preventedOffsets.y,\n left: overflow.left - rect.width - preventedOffsets.x\n };\n}\n\nfunction isAnySideFullyClipped(overflow) {\n return [top, right, bottom, left].some(function (side) {\n return overflow[side] >= 0;\n });\n}\n\nfunction hide(_ref) {\n var state = _ref.state,\n name = _ref.name;\n var referenceRect = state.rects.reference;\n var popperRect = state.rects.popper;\n var preventedOffsets = state.modifiersData.preventOverflow;\n var referenceOverflow = detectOverflow(state, {\n elementContext: 'reference'\n });\n var popperAltOverflow = detectOverflow(state, {\n altBoundary: true\n });\n var referenceClippingOffsets = getSideOffsets(referenceOverflow, referenceRect);\n var popperEscapeOffsets = getSideOffsets(popperAltOverflow, popperRect, preventedOffsets);\n var isReferenceHidden = isAnySideFullyClipped(referenceClippingOffsets);\n var hasPopperEscaped = isAnySideFullyClipped(popperEscapeOffsets);\n state.modifiersData[name] = {\n referenceClippingOffsets: referenceClippingOffsets,\n popperEscapeOffsets: popperEscapeOffsets,\n isReferenceHidden: isReferenceHidden,\n hasPopperEscaped: hasPopperEscaped\n };\n state.attributes.popper = Object.assign({}, state.attributes.popper, {\n 'data-popper-reference-hidden': isReferenceHidden,\n 'data-popper-escaped': hasPopperEscaped\n });\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'hide',\n enabled: true,\n phase: 'main',\n requiresIfExists: ['preventOverflow'],\n fn: hide\n};","import getBasePlacement from \"../utils/getBasePlacement.js\";\nimport { top, left, right, placements } from \"../enums.js\"; // eslint-disable-next-line import/no-unused-modules\n\nexport function distanceAndSkiddingToXY(placement, rects, offset) {\n var basePlacement = getBasePlacement(placement);\n var invertDistance = [left, top].indexOf(basePlacement) >= 0 ? -1 : 1;\n\n var _ref = typeof offset === 'function' ? offset(Object.assign({}, rects, {\n placement: placement\n })) : offset,\n skidding = _ref[0],\n distance = _ref[1];\n\n skidding = skidding || 0;\n distance = (distance || 0) * invertDistance;\n return [left, right].indexOf(basePlacement) >= 0 ? {\n x: distance,\n y: skidding\n } : {\n x: skidding,\n y: distance\n };\n}\n\nfunction offset(_ref2) {\n var state = _ref2.state,\n options = _ref2.options,\n name = _ref2.name;\n var _options$offset = options.offset,\n offset = _options$offset === void 0 ? [0, 0] : _options$offset;\n var data = placements.reduce(function (acc, placement) {\n acc[placement] = distanceAndSkiddingToXY(placement, state.rects, offset);\n return acc;\n }, {});\n var _data$state$placement = data[state.placement],\n x = _data$state$placement.x,\n y = _data$state$placement.y;\n\n if (state.modifiersData.popperOffsets != null) {\n state.modifiersData.popperOffsets.x += x;\n state.modifiersData.popperOffsets.y += y;\n }\n\n state.modifiersData[name] = data;\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'offset',\n enabled: true,\n phase: 'main',\n requires: ['popperOffsets'],\n fn: offset\n};","import computeOffsets from \"../utils/computeOffsets.js\";\n\nfunction popperOffsets(_ref) {\n var state = _ref.state,\n name = _ref.name;\n // Offsets are the actual position the popper needs to have to be\n // properly positioned near its reference element\n // This is the most basic placement, and will be adjusted by\n // the modifiers in the next step\n state.modifiersData[name] = computeOffsets({\n reference: state.rects.reference,\n element: state.rects.popper,\n strategy: 'absolute',\n placement: state.placement\n });\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'popperOffsets',\n enabled: true,\n phase: 'read',\n fn: popperOffsets,\n data: {}\n};","export default function getAltAxis(axis) {\n return axis === 'x' ? 'y' : 'x';\n}","import { top, left, right, bottom, start } from \"../enums.js\";\nimport getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getMainAxisFromPlacement from \"../utils/getMainAxisFromPlacement.js\";\nimport getAltAxis from \"../utils/getAltAxis.js\";\nimport { within, withinMaxClamp } from \"../utils/within.js\";\nimport getLayoutRect from \"../dom-utils/getLayoutRect.js\";\nimport getOffsetParent from \"../dom-utils/getOffsetParent.js\";\nimport detectOverflow from \"../utils/detectOverflow.js\";\nimport getVariation from \"../utils/getVariation.js\";\nimport getFreshSideObject from \"../utils/getFreshSideObject.js\";\nimport { min as mathMin, max as mathMax } from \"../utils/math.js\";\n\nfunction preventOverflow(_ref) {\n var state = _ref.state,\n options = _ref.options,\n name = _ref.name;\n var _options$mainAxis = options.mainAxis,\n checkMainAxis = _options$mainAxis === void 0 ? true : _options$mainAxis,\n _options$altAxis = options.altAxis,\n checkAltAxis = _options$altAxis === void 0 ? false : _options$altAxis,\n boundary = options.boundary,\n rootBoundary = options.rootBoundary,\n altBoundary = options.altBoundary,\n padding = options.padding,\n _options$tether = options.tether,\n tether = _options$tether === void 0 ? true : _options$tether,\n _options$tetherOffset = options.tetherOffset,\n tetherOffset = _options$tetherOffset === void 0 ? 0 : _options$tetherOffset;\n var overflow = detectOverflow(state, {\n boundary: boundary,\n rootBoundary: rootBoundary,\n padding: padding,\n altBoundary: altBoundary\n });\n var basePlacement = getBasePlacement(state.placement);\n var variation = getVariation(state.placement);\n var isBasePlacement = !variation;\n var mainAxis = getMainAxisFromPlacement(basePlacement);\n var altAxis = getAltAxis(mainAxis);\n var popperOffsets = state.modifiersData.popperOffsets;\n var referenceRect = state.rects.reference;\n var popperRect = state.rects.popper;\n var tetherOffsetValue = typeof tetherOffset === 'function' ? tetherOffset(Object.assign({}, state.rects, {\n placement: state.placement\n })) : tetherOffset;\n var normalizedTetherOffsetValue = typeof tetherOffsetValue === 'number' ? {\n mainAxis: tetherOffsetValue,\n altAxis: tetherOffsetValue\n } : Object.assign({\n mainAxis: 0,\n altAxis: 0\n }, tetherOffsetValue);\n var offsetModifierState = state.modifiersData.offset ? state.modifiersData.offset[state.placement] : null;\n var data = {\n x: 0,\n y: 0\n };\n\n if (!popperOffsets) {\n return;\n }\n\n if (checkMainAxis) {\n var _offsetModifierState$;\n\n var mainSide = mainAxis === 'y' ? top : left;\n var altSide = mainAxis === 'y' ? bottom : right;\n var len = mainAxis === 'y' ? 'height' : 'width';\n var offset = popperOffsets[mainAxis];\n var min = offset + overflow[mainSide];\n var max = offset - overflow[altSide];\n var additive = tether ? -popperRect[len] / 2 : 0;\n var minLen = variation === start ? referenceRect[len] : popperRect[len];\n var maxLen = variation === start ? -popperRect[len] : -referenceRect[len]; // We need to include the arrow in the calculation so the arrow doesn't go\n // outside the reference bounds\n\n var arrowElement = state.elements.arrow;\n var arrowRect = tether && arrowElement ? getLayoutRect(arrowElement) : {\n width: 0,\n height: 0\n };\n var arrowPaddingObject = state.modifiersData['arrow#persistent'] ? state.modifiersData['arrow#persistent'].padding : getFreshSideObject();\n var arrowPaddingMin = arrowPaddingObject[mainSide];\n var arrowPaddingMax = arrowPaddingObject[altSide]; // If the reference length is smaller than the arrow length, we don't want\n // to include its full size in the calculation. If the reference is small\n // and near the edge of a boundary, the popper can overflow even if the\n // reference is not overflowing as well (e.g. virtual elements with no\n // width or height)\n\n var arrowLen = within(0, referenceRect[len], arrowRect[len]);\n var minOffset = isBasePlacement ? referenceRect[len] / 2 - additive - arrowLen - arrowPaddingMin - normalizedTetherOffsetValue.mainAxis : minLen - arrowLen - arrowPaddingMin - normalizedTetherOffsetValue.mainAxis;\n var maxOffset = isBasePlacement ? -referenceRect[len] / 2 + additive + arrowLen + arrowPaddingMax + normalizedTetherOffsetValue.mainAxis : maxLen + arrowLen + arrowPaddingMax + normalizedTetherOffsetValue.mainAxis;\n var arrowOffsetParent = state.elements.arrow && getOffsetParent(state.elements.arrow);\n var clientOffset = arrowOffsetParent ? mainAxis === 'y' ? arrowOffsetParent.clientTop || 0 : arrowOffsetParent.clientLeft || 0 : 0;\n var offsetModifierValue = (_offsetModifierState$ = offsetModifierState == null ? void 0 : offsetModifierState[mainAxis]) != null ? _offsetModifierState$ : 0;\n var tetherMin = offset + minOffset - offsetModifierValue - clientOffset;\n var tetherMax = offset + maxOffset - offsetModifierValue;\n var preventedOffset = within(tether ? mathMin(min, tetherMin) : min, offset, tether ? mathMax(max, tetherMax) : max);\n popperOffsets[mainAxis] = preventedOffset;\n data[mainAxis] = preventedOffset - offset;\n }\n\n if (checkAltAxis) {\n var _offsetModifierState$2;\n\n var _mainSide = mainAxis === 'x' ? top : left;\n\n var _altSide = mainAxis === 'x' ? bottom : right;\n\n var _offset = popperOffsets[altAxis];\n\n var _len = altAxis === 'y' ? 'height' : 'width';\n\n var _min = _offset + overflow[_mainSide];\n\n var _max = _offset - overflow[_altSide];\n\n var isOriginSide = [top, left].indexOf(basePlacement) !== -1;\n\n var _offsetModifierValue = (_offsetModifierState$2 = offsetModifierState == null ? void 0 : offsetModifierState[altAxis]) != null ? _offsetModifierState$2 : 0;\n\n var _tetherMin = isOriginSide ? _min : _offset - referenceRect[_len] - popperRect[_len] - _offsetModifierValue + normalizedTetherOffsetValue.altAxis;\n\n var _tetherMax = isOriginSide ? _offset + referenceRect[_len] + popperRect[_len] - _offsetModifierValue - normalizedTetherOffsetValue.altAxis : _max;\n\n var _preventedOffset = tether && isOriginSide ? withinMaxClamp(_tetherMin, _offset, _tetherMax) : within(tether ? _tetherMin : _min, _offset, tether ? _tetherMax : _max);\n\n popperOffsets[altAxis] = _preventedOffset;\n data[altAxis] = _preventedOffset - _offset;\n }\n\n state.modifiersData[name] = data;\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'preventOverflow',\n enabled: true,\n phase: 'main',\n fn: preventOverflow,\n requiresIfExists: ['offset']\n};","export default function getHTMLElementScroll(element) {\n return {\n scrollLeft: element.scrollLeft,\n scrollTop: element.scrollTop\n };\n}","import getWindowScroll from \"./getWindowScroll.js\";\nimport getWindow from \"./getWindow.js\";\nimport { isHTMLElement } from \"./instanceOf.js\";\nimport getHTMLElementScroll from \"./getHTMLElementScroll.js\";\nexport default function getNodeScroll(node) {\n if (node === getWindow(node) || !isHTMLElement(node)) {\n return getWindowScroll(node);\n } else {\n return getHTMLElementScroll(node);\n }\n}","import getBoundingClientRect from \"./getBoundingClientRect.js\";\nimport getNodeScroll from \"./getNodeScroll.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport { isHTMLElement } from \"./instanceOf.js\";\nimport getWindowScrollBarX from \"./getWindowScrollBarX.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport isScrollParent from \"./isScrollParent.js\";\nimport { round } from \"../utils/math.js\";\n\nfunction isElementScaled(element) {\n var rect = element.getBoundingClientRect();\n var scaleX = round(rect.width) / element.offsetWidth || 1;\n var scaleY = round(rect.height) / element.offsetHeight || 1;\n return scaleX !== 1 || scaleY !== 1;\n} // Returns the composite rect of an element relative to its offsetParent.\n// Composite means it takes into account transforms as well as layout.\n\n\nexport default function getCompositeRect(elementOrVirtualElement, offsetParent, isFixed) {\n if (isFixed === void 0) {\n isFixed = false;\n }\n\n var isOffsetParentAnElement = isHTMLElement(offsetParent);\n var offsetParentIsScaled = isHTMLElement(offsetParent) && isElementScaled(offsetParent);\n var documentElement = getDocumentElement(offsetParent);\n var rect = getBoundingClientRect(elementOrVirtualElement, offsetParentIsScaled, isFixed);\n var scroll = {\n scrollLeft: 0,\n scrollTop: 0\n };\n var offsets = {\n x: 0,\n y: 0\n };\n\n if (isOffsetParentAnElement || !isOffsetParentAnElement && !isFixed) {\n if (getNodeName(offsetParent) !== 'body' || // https://github.com/popperjs/popper-core/issues/1078\n isScrollParent(documentElement)) {\n scroll = getNodeScroll(offsetParent);\n }\n\n if (isHTMLElement(offsetParent)) {\n offsets = getBoundingClientRect(offsetParent, true);\n offsets.x += offsetParent.clientLeft;\n offsets.y += offsetParent.clientTop;\n } else if (documentElement) {\n offsets.x = getWindowScrollBarX(documentElement);\n }\n }\n\n return {\n x: rect.left + scroll.scrollLeft - offsets.x,\n y: rect.top + scroll.scrollTop - offsets.y,\n width: rect.width,\n height: rect.height\n };\n}","import { modifierPhases } from \"../enums.js\"; // source: https://stackoverflow.com/questions/49875255\n\nfunction order(modifiers) {\n var map = new Map();\n var visited = new Set();\n var result = [];\n modifiers.forEach(function (modifier) {\n map.set(modifier.name, modifier);\n }); // On visiting object, check for its dependencies and visit them recursively\n\n function sort(modifier) {\n visited.add(modifier.name);\n var requires = [].concat(modifier.requires || [], modifier.requiresIfExists || []);\n requires.forEach(function (dep) {\n if (!visited.has(dep)) {\n var depModifier = map.get(dep);\n\n if (depModifier) {\n sort(depModifier);\n }\n }\n });\n result.push(modifier);\n }\n\n modifiers.forEach(function (modifier) {\n if (!visited.has(modifier.name)) {\n // check for visited object\n sort(modifier);\n }\n });\n return result;\n}\n\nexport default function orderModifiers(modifiers) {\n // order based on dependencies\n var orderedModifiers = order(modifiers); // order based on phase\n\n return modifierPhases.reduce(function (acc, phase) {\n return acc.concat(orderedModifiers.filter(function (modifier) {\n return modifier.phase === phase;\n }));\n }, []);\n}","export default function debounce(fn) {\n var pending;\n return function () {\n if (!pending) {\n pending = new Promise(function (resolve) {\n Promise.resolve().then(function () {\n pending = undefined;\n resolve(fn());\n });\n });\n }\n\n return pending;\n };\n}","export default function mergeByName(modifiers) {\n var merged = modifiers.reduce(function (merged, current) {\n var existing = merged[current.name];\n merged[current.name] = existing ? Object.assign({}, existing, current, {\n options: Object.assign({}, existing.options, current.options),\n data: Object.assign({}, existing.data, current.data)\n }) : current;\n return merged;\n }, {}); // IE11 does not support Object.values\n\n return Object.keys(merged).map(function (key) {\n return merged[key];\n });\n}","import getCompositeRect from \"./dom-utils/getCompositeRect.js\";\nimport getLayoutRect from \"./dom-utils/getLayoutRect.js\";\nimport listScrollParents from \"./dom-utils/listScrollParents.js\";\nimport getOffsetParent from \"./dom-utils/getOffsetParent.js\";\nimport orderModifiers from \"./utils/orderModifiers.js\";\nimport debounce from \"./utils/debounce.js\";\nimport mergeByName from \"./utils/mergeByName.js\";\nimport detectOverflow from \"./utils/detectOverflow.js\";\nimport { isElement } from \"./dom-utils/instanceOf.js\";\nvar DEFAULT_OPTIONS = {\n placement: 'bottom',\n modifiers: [],\n strategy: 'absolute'\n};\n\nfunction areValidElements() {\n for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {\n args[_key] = arguments[_key];\n }\n\n return !args.some(function (element) {\n return !(element && typeof element.getBoundingClientRect === 'function');\n });\n}\n\nexport function popperGenerator(generatorOptions) {\n if (generatorOptions === void 0) {\n generatorOptions = {};\n }\n\n var _generatorOptions = generatorOptions,\n _generatorOptions$def = _generatorOptions.defaultModifiers,\n defaultModifiers = _generatorOptions$def === void 0 ? [] : _generatorOptions$def,\n _generatorOptions$def2 = _generatorOptions.defaultOptions,\n defaultOptions = _generatorOptions$def2 === void 0 ? DEFAULT_OPTIONS : _generatorOptions$def2;\n return function createPopper(reference, popper, options) {\n if (options === void 0) {\n options = defaultOptions;\n }\n\n var state = {\n placement: 'bottom',\n orderedModifiers: [],\n options: Object.assign({}, DEFAULT_OPTIONS, defaultOptions),\n modifiersData: {},\n elements: {\n reference: reference,\n popper: popper\n },\n attributes: {},\n styles: {}\n };\n var effectCleanupFns = [];\n var isDestroyed = false;\n var instance = {\n state: state,\n setOptions: function setOptions(setOptionsAction) {\n var options = typeof setOptionsAction === 'function' ? setOptionsAction(state.options) : setOptionsAction;\n cleanupModifierEffects();\n state.options = Object.assign({}, defaultOptions, state.options, options);\n state.scrollParents = {\n reference: isElement(reference) ? listScrollParents(reference) : reference.contextElement ? listScrollParents(reference.contextElement) : [],\n popper: listScrollParents(popper)\n }; // Orders the modifiers based on their dependencies and `phase`\n // properties\n\n var orderedModifiers = orderModifiers(mergeByName([].concat(defaultModifiers, state.options.modifiers))); // Strip out disabled modifiers\n\n state.orderedModifiers = orderedModifiers.filter(function (m) {\n return m.enabled;\n });\n runModifierEffects();\n return instance.update();\n },\n // Sync update – it will always be executed, even if not necessary. This\n // is useful for low frequency updates where sync behavior simplifies the\n // logic.\n // For high frequency updates (e.g. `resize` and `scroll` events), always\n // prefer the async Popper#update method\n forceUpdate: function forceUpdate() {\n if (isDestroyed) {\n return;\n }\n\n var _state$elements = state.elements,\n reference = _state$elements.reference,\n popper = _state$elements.popper; // Don't proceed if `reference` or `popper` are not valid elements\n // anymore\n\n if (!areValidElements(reference, popper)) {\n return;\n } // Store the reference and popper rects to be read by modifiers\n\n\n state.rects = {\n reference: getCompositeRect(reference, getOffsetParent(popper), state.options.strategy === 'fixed'),\n popper: getLayoutRect(popper)\n }; // Modifiers have the ability to reset the current update cycle. The\n // most common use case for this is the `flip` modifier changing the\n // placement, which then needs to re-run all the modifiers, because the\n // logic was previously ran for the previous placement and is therefore\n // stale/incorrect\n\n state.reset = false;\n state.placement = state.options.placement; // On each update cycle, the `modifiersData` property for each modifier\n // is filled with the initial data specified by the modifier. This means\n // it doesn't persist and is fresh on each update.\n // To ensure persistent data, use `${name}#persistent`\n\n state.orderedModifiers.forEach(function (modifier) {\n return state.modifiersData[modifier.name] = Object.assign({}, modifier.data);\n });\n\n for (var index = 0; index < state.orderedModifiers.length; index++) {\n if (state.reset === true) {\n state.reset = false;\n index = -1;\n continue;\n }\n\n var _state$orderedModifie = state.orderedModifiers[index],\n fn = _state$orderedModifie.fn,\n _state$orderedModifie2 = _state$orderedModifie.options,\n _options = _state$orderedModifie2 === void 0 ? {} : _state$orderedModifie2,\n name = _state$orderedModifie.name;\n\n if (typeof fn === 'function') {\n state = fn({\n state: state,\n options: _options,\n name: name,\n instance: instance\n }) || state;\n }\n }\n },\n // Async and optimistically optimized update – it will not be executed if\n // not necessary (debounced to run at most once-per-tick)\n update: debounce(function () {\n return new Promise(function (resolve) {\n instance.forceUpdate();\n resolve(state);\n });\n }),\n destroy: function destroy() {\n cleanupModifierEffects();\n isDestroyed = true;\n }\n };\n\n if (!areValidElements(reference, popper)) {\n return instance;\n }\n\n instance.setOptions(options).then(function (state) {\n if (!isDestroyed && options.onFirstUpdate) {\n options.onFirstUpdate(state);\n }\n }); // Modifiers have the ability to execute arbitrary code before the first\n // update cycle runs. They will be executed in the same order as the update\n // cycle. This is useful when a modifier adds some persistent data that\n // other modifiers need to use, but the modifier is run after the dependent\n // one.\n\n function runModifierEffects() {\n state.orderedModifiers.forEach(function (_ref) {\n var name = _ref.name,\n _ref$options = _ref.options,\n options = _ref$options === void 0 ? {} : _ref$options,\n effect = _ref.effect;\n\n if (typeof effect === 'function') {\n var cleanupFn = effect({\n state: state,\n name: name,\n instance: instance,\n options: options\n });\n\n var noopFn = function noopFn() {};\n\n effectCleanupFns.push(cleanupFn || noopFn);\n }\n });\n }\n\n function cleanupModifierEffects() {\n effectCleanupFns.forEach(function (fn) {\n return fn();\n });\n effectCleanupFns = [];\n }\n\n return instance;\n };\n}\nexport var createPopper = /*#__PURE__*/popperGenerator(); // eslint-disable-next-line import/no-unused-modules\n\nexport { detectOverflow };","import { popperGenerator, detectOverflow } from \"./createPopper.js\";\nimport eventListeners from \"./modifiers/eventListeners.js\";\nimport popperOffsets from \"./modifiers/popperOffsets.js\";\nimport computeStyles from \"./modifiers/computeStyles.js\";\nimport applyStyles from \"./modifiers/applyStyles.js\";\nimport offset from \"./modifiers/offset.js\";\nimport flip from \"./modifiers/flip.js\";\nimport preventOverflow from \"./modifiers/preventOverflow.js\";\nimport arrow from \"./modifiers/arrow.js\";\nimport hide from \"./modifiers/hide.js\";\nvar defaultModifiers = [eventListeners, popperOffsets, computeStyles, applyStyles, offset, flip, preventOverflow, arrow, hide];\nvar createPopper = /*#__PURE__*/popperGenerator({\n defaultModifiers: defaultModifiers\n}); // eslint-disable-next-line import/no-unused-modules\n\nexport { createPopper, popperGenerator, defaultModifiers, detectOverflow }; // eslint-disable-next-line import/no-unused-modules\n\nexport { createPopper as createPopperLite } from \"./popper-lite.js\"; // eslint-disable-next-line import/no-unused-modules\n\nexport * from \"./modifiers/index.js\";","import { generateUtilityClass } from '../generateUtilityClass';\nimport { generateUtilityClasses } from '../generateUtilityClasses';\nconst COMPONENT_NAME = 'Popper';\nexport function getPopperUtilityClass(slot) {\n return generateUtilityClass(COMPONENT_NAME, slot);\n}\nexport const popperClasses = generateUtilityClasses(COMPONENT_NAME, ['root']);","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"anchorEl\", \"children\", \"direction\", \"disablePortal\", \"modifiers\", \"open\", \"placement\", \"popperOptions\", \"popperRef\", \"slotProps\", \"slots\", \"TransitionProps\", \"ownerState\"],\n _excluded2 = [\"anchorEl\", \"children\", \"container\", \"direction\", \"disablePortal\", \"keepMounted\", \"modifiers\", \"open\", \"placement\", \"popperOptions\", \"popperRef\", \"style\", \"transition\", \"slotProps\", \"slots\"];\nimport * as React from 'react';\nimport { chainPropTypes, HTMLElementType, refType, unstable_ownerDocument as ownerDocument, unstable_useEnhancedEffect as useEnhancedEffect, unstable_useForkRef as useForkRef } from '@mui/utils';\nimport { createPopper } from '@popperjs/core';\nimport PropTypes from 'prop-types';\nimport { unstable_composeClasses as composeClasses } from '../composeClasses';\nimport { Portal } from '../Portal';\nimport { getPopperUtilityClass } from './popperClasses';\nimport { useSlotProps } from '../utils';\nimport { useClassNamesOverride } from '../utils/ClassNameConfigurator';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nfunction flipPlacement(placement, direction) {\n if (direction === 'ltr') {\n return placement;\n }\n switch (placement) {\n case 'bottom-end':\n return 'bottom-start';\n case 'bottom-start':\n return 'bottom-end';\n case 'top-end':\n return 'top-start';\n case 'top-start':\n return 'top-end';\n default:\n return placement;\n }\n}\nfunction resolveAnchorEl(anchorEl) {\n return typeof anchorEl === 'function' ? anchorEl() : anchorEl;\n}\nfunction isHTMLElement(element) {\n return element.nodeType !== undefined;\n}\nfunction isVirtualElement(element) {\n return !isHTMLElement(element);\n}\nconst useUtilityClasses = () => {\n const slots = {\n root: ['root']\n };\n return composeClasses(slots, useClassNamesOverride(getPopperUtilityClass));\n};\nconst defaultPopperOptions = {};\nconst PopperTooltip = /*#__PURE__*/React.forwardRef(function PopperTooltip(props, forwardedRef) {\n var _slots$root;\n const {\n anchorEl,\n children,\n direction,\n disablePortal,\n modifiers,\n open,\n placement: initialPlacement,\n popperOptions,\n popperRef: popperRefProp,\n slotProps = {},\n slots = {},\n TransitionProps\n // @ts-ignore internal logic\n // prevent from spreading to DOM, it can come from the parent component e.g. Select.\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const tooltipRef = React.useRef(null);\n const ownRef = useForkRef(tooltipRef, forwardedRef);\n const popperRef = React.useRef(null);\n const handlePopperRef = useForkRef(popperRef, popperRefProp);\n const handlePopperRefRef = React.useRef(handlePopperRef);\n useEnhancedEffect(() => {\n handlePopperRefRef.current = handlePopperRef;\n }, [handlePopperRef]);\n React.useImperativeHandle(popperRefProp, () => popperRef.current, []);\n const rtlPlacement = flipPlacement(initialPlacement, direction);\n /**\n * placement initialized from prop but can change during lifetime if modifiers.flip.\n * modifiers.flip is essentially a flip for controlled/uncontrolled behavior\n */\n const [placement, setPlacement] = React.useState(rtlPlacement);\n const [resolvedAnchorElement, setResolvedAnchorElement] = React.useState(resolveAnchorEl(anchorEl));\n React.useEffect(() => {\n if (popperRef.current) {\n popperRef.current.forceUpdate();\n }\n });\n React.useEffect(() => {\n if (anchorEl) {\n setResolvedAnchorElement(resolveAnchorEl(anchorEl));\n }\n }, [anchorEl]);\n useEnhancedEffect(() => {\n if (!resolvedAnchorElement || !open) {\n return undefined;\n }\n const handlePopperUpdate = data => {\n setPlacement(data.placement);\n };\n if (process.env.NODE_ENV !== 'production') {\n if (resolvedAnchorElement && isHTMLElement(resolvedAnchorElement) && resolvedAnchorElement.nodeType === 1) {\n const box = resolvedAnchorElement.getBoundingClientRect();\n if (process.env.NODE_ENV !== 'test' && box.top === 0 && box.left === 0 && box.right === 0 && box.bottom === 0) {\n console.warn(['MUI: The `anchorEl` prop provided to the component is invalid.', 'The anchor element should be part of the document layout.', \"Make sure the element is present in the document or that it's not display none.\"].join('\\n'));\n }\n }\n }\n let popperModifiers = [{\n name: 'preventOverflow',\n options: {\n altBoundary: disablePortal\n }\n }, {\n name: 'flip',\n options: {\n altBoundary: disablePortal\n }\n }, {\n name: 'onUpdate',\n enabled: true,\n phase: 'afterWrite',\n fn: ({\n state\n }) => {\n handlePopperUpdate(state);\n }\n }];\n if (modifiers != null) {\n popperModifiers = popperModifiers.concat(modifiers);\n }\n if (popperOptions && popperOptions.modifiers != null) {\n popperModifiers = popperModifiers.concat(popperOptions.modifiers);\n }\n const popper = createPopper(resolvedAnchorElement, tooltipRef.current, _extends({\n placement: rtlPlacement\n }, popperOptions, {\n modifiers: popperModifiers\n }));\n handlePopperRefRef.current(popper);\n return () => {\n popper.destroy();\n handlePopperRefRef.current(null);\n };\n }, [resolvedAnchorElement, disablePortal, modifiers, open, popperOptions, rtlPlacement]);\n const childProps = {\n placement: placement\n };\n if (TransitionProps !== null) {\n childProps.TransitionProps = TransitionProps;\n }\n const classes = useUtilityClasses();\n const Root = (_slots$root = slots.root) != null ? _slots$root : 'div';\n const rootProps = useSlotProps({\n elementType: Root,\n externalSlotProps: slotProps.root,\n externalForwardedProps: other,\n additionalProps: {\n role: 'tooltip',\n ref: ownRef\n },\n ownerState: props,\n className: classes.root\n });\n return /*#__PURE__*/_jsx(Root, _extends({}, rootProps, {\n children: typeof children === 'function' ? children(childProps) : children\n }));\n});\n\n/**\n * Poppers rely on the 3rd party library [Popper.js](https://popper.js.org/docs/v2/) for positioning.\n *\n * Demos:\n *\n * - [Popper](https://mui.com/base-ui/react-popper/)\n *\n * API:\n *\n * - [Popper API](https://mui.com/base-ui/react-popper/components-api/#popper)\n */\nconst Popper = /*#__PURE__*/React.forwardRef(function Popper(props, forwardedRef) {\n const {\n anchorEl,\n children,\n container: containerProp,\n direction = 'ltr',\n disablePortal = false,\n keepMounted = false,\n modifiers,\n open,\n placement = 'bottom',\n popperOptions = defaultPopperOptions,\n popperRef,\n style,\n transition = false,\n slotProps = {},\n slots = {}\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded2);\n const [exited, setExited] = React.useState(true);\n const handleEnter = () => {\n setExited(false);\n };\n const handleExited = () => {\n setExited(true);\n };\n if (!keepMounted && !open && (!transition || exited)) {\n return null;\n }\n\n // If the container prop is provided, use that\n // If the anchorEl prop is provided, use its parent body element as the container\n // If neither are provided let the Modal take care of choosing the container\n let container;\n if (containerProp) {\n container = containerProp;\n } else if (anchorEl) {\n const resolvedAnchorEl = resolveAnchorEl(anchorEl);\n container = resolvedAnchorEl && isHTMLElement(resolvedAnchorEl) ? ownerDocument(resolvedAnchorEl).body : ownerDocument(null).body;\n }\n const display = !open && keepMounted && (!transition || exited) ? 'none' : undefined;\n const transitionProps = transition ? {\n in: open,\n onEnter: handleEnter,\n onExited: handleExited\n } : undefined;\n return /*#__PURE__*/_jsx(Portal, {\n disablePortal: disablePortal,\n container: container,\n children: /*#__PURE__*/_jsx(PopperTooltip, _extends({\n anchorEl: anchorEl,\n direction: direction,\n disablePortal: disablePortal,\n modifiers: modifiers,\n ref: forwardedRef,\n open: transition ? !exited : open,\n placement: placement,\n popperOptions: popperOptions,\n popperRef: popperRef,\n slotProps: slotProps,\n slots: slots\n }, other, {\n style: _extends({\n // Prevents scroll issue, waiting for Popper.js to add this style once initiated.\n position: 'fixed',\n // Fix Popper.js display issue\n top: 0,\n left: 0,\n display\n }, style),\n TransitionProps: transitionProps,\n children: children\n }))\n });\n});\nprocess.env.NODE_ENV !== \"production\" ? Popper.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * An HTML element, [virtualElement](https://popper.js.org/docs/v2/virtual-elements/),\n * or a function that returns either.\n * It's used to set the position of the popper.\n * The return value will passed as the reference object of the Popper instance.\n */\n anchorEl: chainPropTypes(PropTypes.oneOfType([HTMLElementType, PropTypes.object, PropTypes.func]), props => {\n if (props.open) {\n const resolvedAnchorEl = resolveAnchorEl(props.anchorEl);\n if (resolvedAnchorEl && isHTMLElement(resolvedAnchorEl) && resolvedAnchorEl.nodeType === 1) {\n const box = resolvedAnchorEl.getBoundingClientRect();\n if (process.env.NODE_ENV !== 'test' && box.top === 0 && box.left === 0 && box.right === 0 && box.bottom === 0) {\n return new Error(['MUI: The `anchorEl` prop provided to the component is invalid.', 'The anchor element should be part of the document layout.', \"Make sure the element is present in the document or that it's not display none.\"].join('\\n'));\n }\n } else if (!resolvedAnchorEl || typeof resolvedAnchorEl.getBoundingClientRect !== 'function' || isVirtualElement(resolvedAnchorEl) && resolvedAnchorEl.contextElement != null && resolvedAnchorEl.contextElement.nodeType !== 1) {\n return new Error(['MUI: The `anchorEl` prop provided to the component is invalid.', 'It should be an HTML element instance or a virtualElement ', '(https://popper.js.org/docs/v2/virtual-elements/).'].join('\\n'));\n }\n }\n return null;\n }),\n /**\n * Popper render function or node.\n */\n children: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.node, PropTypes.func]),\n /**\n * An HTML element or function that returns one.\n * The `container` will have the portal children appended to it.\n *\n * You can also provide a callback, which is called in a React layout effect.\n * This lets you set the container from a ref, and also makes server-side rendering possible.\n *\n * By default, it uses the body of the top-level document object,\n * so it's simply `document.body` most of the time.\n */\n container: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.func]),\n /**\n * Direction of the text.\n * @default 'ltr'\n */\n direction: PropTypes.oneOf(['ltr', 'rtl']),\n /**\n * The `children` will be under the DOM hierarchy of the parent component.\n * @default false\n */\n disablePortal: PropTypes.bool,\n /**\n * Always keep the children in the DOM.\n * This prop can be useful in SEO situation or\n * when you want to maximize the responsiveness of the Popper.\n * @default false\n */\n keepMounted: PropTypes.bool,\n /**\n * Popper.js is based on a \"plugin-like\" architecture,\n * most of its features are fully encapsulated \"modifiers\".\n *\n * A modifier is a function that is called each time Popper.js needs to\n * compute the position of the popper.\n * For this reason, modifiers should be very performant to avoid bottlenecks.\n * To learn how to create a modifier, [read the modifiers documentation](https://popper.js.org/docs/v2/modifiers/).\n */\n modifiers: PropTypes.arrayOf(PropTypes.shape({\n data: PropTypes.object,\n effect: PropTypes.func,\n enabled: PropTypes.bool,\n fn: PropTypes.func,\n name: PropTypes.any,\n options: PropTypes.object,\n phase: PropTypes.oneOf(['afterMain', 'afterRead', 'afterWrite', 'beforeMain', 'beforeRead', 'beforeWrite', 'main', 'read', 'write']),\n requires: PropTypes.arrayOf(PropTypes.string),\n requiresIfExists: PropTypes.arrayOf(PropTypes.string)\n })),\n /**\n * If `true`, the component is shown.\n */\n open: PropTypes.bool.isRequired,\n /**\n * Popper placement.\n * @default 'bottom'\n */\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n /**\n * Options provided to the [`Popper.js`](https://popper.js.org/docs/v2/constructors/#options) instance.\n * @default {}\n */\n popperOptions: PropTypes.shape({\n modifiers: PropTypes.array,\n onFirstUpdate: PropTypes.func,\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n strategy: PropTypes.oneOf(['absolute', 'fixed'])\n }),\n /**\n * A ref that points to the used popper instance.\n */\n popperRef: refType,\n /**\n * The props used for each slot inside the Popper.\n * @default {}\n */\n slotProps: PropTypes.shape({\n root: PropTypes.oneOfType([PropTypes.func, PropTypes.object])\n }),\n /**\n * The components used for each slot inside the Popper.\n * Either a string to use a HTML element or a component.\n * @default {}\n */\n slots: PropTypes.shape({\n root: PropTypes.elementType\n }),\n /**\n * Help supporting a react-transition-group/Transition component.\n * @default false\n */\n transition: PropTypes.bool\n} : void 0;\nexport { Popper };","'use client';\n\nimport * as React from 'react';\nimport { useTheme as useThemeSystem } from '@mui/system';\nimport defaultTheme from './defaultTheme';\nimport THEME_ID from './identifier';\nexport default function useTheme() {\n const theme = useThemeSystem(defaultTheme);\n if (process.env.NODE_ENV !== 'production') {\n // eslint-disable-next-line react-hooks/rules-of-hooks\n React.useDebugValue(theme);\n }\n return theme[THEME_ID] || theme;\n}","export default function _setPrototypeOf(o, p) {\n _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function _setPrototypeOf(o, p) {\n o.__proto__ = p;\n return o;\n };\n return _setPrototypeOf(o, p);\n}","import setPrototypeOf from \"./setPrototypeOf.js\";\nexport default function _inheritsLoose(subClass, superClass) {\n subClass.prototype = Object.create(superClass.prototype);\n subClass.prototype.constructor = subClass;\n setPrototypeOf(subClass, superClass);\n}","export default {\n disabled: false\n};","import PropTypes from 'prop-types';\nexport var timeoutsShape = process.env.NODE_ENV !== 'production' ? PropTypes.oneOfType([PropTypes.number, PropTypes.shape({\n enter: PropTypes.number,\n exit: PropTypes.number,\n appear: PropTypes.number\n}).isRequired]) : null;\nexport var classNamesShape = process.env.NODE_ENV !== 'production' ? PropTypes.oneOfType([PropTypes.string, PropTypes.shape({\n enter: PropTypes.string,\n exit: PropTypes.string,\n active: PropTypes.string\n}), PropTypes.shape({\n enter: PropTypes.string,\n enterDone: PropTypes.string,\n enterActive: PropTypes.string,\n exit: PropTypes.string,\n exitDone: PropTypes.string,\n exitActive: PropTypes.string\n})]) : null;","import React from 'react';\nexport default React.createContext(null);","export var forceReflow = function forceReflow(node) {\n return node.scrollTop;\n};","import _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _inheritsLoose from \"@babel/runtime/helpers/esm/inheritsLoose\";\nimport PropTypes from 'prop-types';\nimport React from 'react';\nimport ReactDOM from 'react-dom';\nimport config from './config';\nimport { timeoutsShape } from './utils/PropTypes';\nimport TransitionGroupContext from './TransitionGroupContext';\nimport { forceReflow } from './utils/reflow';\nexport var UNMOUNTED = 'unmounted';\nexport var EXITED = 'exited';\nexport var ENTERING = 'entering';\nexport var ENTERED = 'entered';\nexport var EXITING = 'exiting';\n/**\n * The Transition component lets you describe a transition from one component\n * state to another _over time_ with a simple declarative API. Most commonly\n * it's used to animate the mounting and unmounting of a component, but can also\n * be used to describe in-place transition states as well.\n *\n * ---\n *\n * **Note**: `Transition` is a platform-agnostic base component. If you're using\n * transitions in CSS, you'll probably want to use\n * [`CSSTransition`](https://reactcommunity.org/react-transition-group/css-transition)\n * instead. It inherits all the features of `Transition`, but contains\n * additional features necessary to play nice with CSS transitions (hence the\n * name of the component).\n *\n * ---\n *\n * By default the `Transition` component does not alter the behavior of the\n * component it renders, it only tracks \"enter\" and \"exit\" states for the\n * components. It's up to you to give meaning and effect to those states. For\n * example we can add styles to a component when it enters or exits:\n *\n * ```jsx\n * import { Transition } from 'react-transition-group';\n *\n * const duration = 300;\n *\n * const defaultStyle = {\n * transition: `opacity ${duration}ms ease-in-out`,\n * opacity: 0,\n * }\n *\n * const transitionStyles = {\n * entering: { opacity: 1 },\n * entered: { opacity: 1 },\n * exiting: { opacity: 0 },\n * exited: { opacity: 0 },\n * };\n *\n * const Fade = ({ in: inProp }) => (\n * \n * {state => (\n *
    \n * I'm a fade Transition!\n *
    \n * )}\n *
    \n * );\n * ```\n *\n * There are 4 main states a Transition can be in:\n * - `'entering'`\n * - `'entered'`\n * - `'exiting'`\n * - `'exited'`\n *\n * Transition state is toggled via the `in` prop. When `true` the component\n * begins the \"Enter\" stage. During this stage, the component will shift from\n * its current transition state, to `'entering'` for the duration of the\n * transition and then to the `'entered'` stage once it's complete. Let's take\n * the following example (we'll use the\n * [useState](https://reactjs.org/docs/hooks-reference.html#usestate) hook):\n *\n * ```jsx\n * function App() {\n * const [inProp, setInProp] = useState(false);\n * return (\n *
    \n * \n * {state => (\n * // ...\n * )}\n * \n * \n *
    \n * );\n * }\n * ```\n *\n * When the button is clicked the component will shift to the `'entering'` state\n * and stay there for 500ms (the value of `timeout`) before it finally switches\n * to `'entered'`.\n *\n * When `in` is `false` the same thing happens except the state moves from\n * `'exiting'` to `'exited'`.\n */\n\nvar Transition = /*#__PURE__*/function (_React$Component) {\n _inheritsLoose(Transition, _React$Component);\n\n function Transition(props, context) {\n var _this;\n\n _this = _React$Component.call(this, props, context) || this;\n var parentGroup = context; // In the context of a TransitionGroup all enters are really appears\n\n var appear = parentGroup && !parentGroup.isMounting ? props.enter : props.appear;\n var initialStatus;\n _this.appearStatus = null;\n\n if (props.in) {\n if (appear) {\n initialStatus = EXITED;\n _this.appearStatus = ENTERING;\n } else {\n initialStatus = ENTERED;\n }\n } else {\n if (props.unmountOnExit || props.mountOnEnter) {\n initialStatus = UNMOUNTED;\n } else {\n initialStatus = EXITED;\n }\n }\n\n _this.state = {\n status: initialStatus\n };\n _this.nextCallback = null;\n return _this;\n }\n\n Transition.getDerivedStateFromProps = function getDerivedStateFromProps(_ref, prevState) {\n var nextIn = _ref.in;\n\n if (nextIn && prevState.status === UNMOUNTED) {\n return {\n status: EXITED\n };\n }\n\n return null;\n } // getSnapshotBeforeUpdate(prevProps) {\n // let nextStatus = null\n // if (prevProps !== this.props) {\n // const { status } = this.state\n // if (this.props.in) {\n // if (status !== ENTERING && status !== ENTERED) {\n // nextStatus = ENTERING\n // }\n // } else {\n // if (status === ENTERING || status === ENTERED) {\n // nextStatus = EXITING\n // }\n // }\n // }\n // return { nextStatus }\n // }\n ;\n\n var _proto = Transition.prototype;\n\n _proto.componentDidMount = function componentDidMount() {\n this.updateStatus(true, this.appearStatus);\n };\n\n _proto.componentDidUpdate = function componentDidUpdate(prevProps) {\n var nextStatus = null;\n\n if (prevProps !== this.props) {\n var status = this.state.status;\n\n if (this.props.in) {\n if (status !== ENTERING && status !== ENTERED) {\n nextStatus = ENTERING;\n }\n } else {\n if (status === ENTERING || status === ENTERED) {\n nextStatus = EXITING;\n }\n }\n }\n\n this.updateStatus(false, nextStatus);\n };\n\n _proto.componentWillUnmount = function componentWillUnmount() {\n this.cancelNextCallback();\n };\n\n _proto.getTimeouts = function getTimeouts() {\n var timeout = this.props.timeout;\n var exit, enter, appear;\n exit = enter = appear = timeout;\n\n if (timeout != null && typeof timeout !== 'number') {\n exit = timeout.exit;\n enter = timeout.enter; // TODO: remove fallback for next major\n\n appear = timeout.appear !== undefined ? timeout.appear : enter;\n }\n\n return {\n exit: exit,\n enter: enter,\n appear: appear\n };\n };\n\n _proto.updateStatus = function updateStatus(mounting, nextStatus) {\n if (mounting === void 0) {\n mounting = false;\n }\n\n if (nextStatus !== null) {\n // nextStatus will always be ENTERING or EXITING.\n this.cancelNextCallback();\n\n if (nextStatus === ENTERING) {\n if (this.props.unmountOnExit || this.props.mountOnEnter) {\n var node = this.props.nodeRef ? this.props.nodeRef.current : ReactDOM.findDOMNode(this); // https://github.com/reactjs/react-transition-group/pull/749\n // With unmountOnExit or mountOnEnter, the enter animation should happen at the transition between `exited` and `entering`.\n // To make the animation happen, we have to separate each rendering and avoid being processed as batched.\n\n if (node) forceReflow(node);\n }\n\n this.performEnter(mounting);\n } else {\n this.performExit();\n }\n } else if (this.props.unmountOnExit && this.state.status === EXITED) {\n this.setState({\n status: UNMOUNTED\n });\n }\n };\n\n _proto.performEnter = function performEnter(mounting) {\n var _this2 = this;\n\n var enter = this.props.enter;\n var appearing = this.context ? this.context.isMounting : mounting;\n\n var _ref2 = this.props.nodeRef ? [appearing] : [ReactDOM.findDOMNode(this), appearing],\n maybeNode = _ref2[0],\n maybeAppearing = _ref2[1];\n\n var timeouts = this.getTimeouts();\n var enterTimeout = appearing ? timeouts.appear : timeouts.enter; // no enter animation skip right to ENTERED\n // if we are mounting and running this it means appear _must_ be set\n\n if (!mounting && !enter || config.disabled) {\n this.safeSetState({\n status: ENTERED\n }, function () {\n _this2.props.onEntered(maybeNode);\n });\n return;\n }\n\n this.props.onEnter(maybeNode, maybeAppearing);\n this.safeSetState({\n status: ENTERING\n }, function () {\n _this2.props.onEntering(maybeNode, maybeAppearing);\n\n _this2.onTransitionEnd(enterTimeout, function () {\n _this2.safeSetState({\n status: ENTERED\n }, function () {\n _this2.props.onEntered(maybeNode, maybeAppearing);\n });\n });\n });\n };\n\n _proto.performExit = function performExit() {\n var _this3 = this;\n\n var exit = this.props.exit;\n var timeouts = this.getTimeouts();\n var maybeNode = this.props.nodeRef ? undefined : ReactDOM.findDOMNode(this); // no exit animation skip right to EXITED\n\n if (!exit || config.disabled) {\n this.safeSetState({\n status: EXITED\n }, function () {\n _this3.props.onExited(maybeNode);\n });\n return;\n }\n\n this.props.onExit(maybeNode);\n this.safeSetState({\n status: EXITING\n }, function () {\n _this3.props.onExiting(maybeNode);\n\n _this3.onTransitionEnd(timeouts.exit, function () {\n _this3.safeSetState({\n status: EXITED\n }, function () {\n _this3.props.onExited(maybeNode);\n });\n });\n });\n };\n\n _proto.cancelNextCallback = function cancelNextCallback() {\n if (this.nextCallback !== null) {\n this.nextCallback.cancel();\n this.nextCallback = null;\n }\n };\n\n _proto.safeSetState = function safeSetState(nextState, callback) {\n // This shouldn't be necessary, but there are weird race conditions with\n // setState callbacks and unmounting in testing, so always make sure that\n // we can cancel any pending setState callbacks after we unmount.\n callback = this.setNextCallback(callback);\n this.setState(nextState, callback);\n };\n\n _proto.setNextCallback = function setNextCallback(callback) {\n var _this4 = this;\n\n var active = true;\n\n this.nextCallback = function (event) {\n if (active) {\n active = false;\n _this4.nextCallback = null;\n callback(event);\n }\n };\n\n this.nextCallback.cancel = function () {\n active = false;\n };\n\n return this.nextCallback;\n };\n\n _proto.onTransitionEnd = function onTransitionEnd(timeout, handler) {\n this.setNextCallback(handler);\n var node = this.props.nodeRef ? this.props.nodeRef.current : ReactDOM.findDOMNode(this);\n var doesNotHaveTimeoutOrListener = timeout == null && !this.props.addEndListener;\n\n if (!node || doesNotHaveTimeoutOrListener) {\n setTimeout(this.nextCallback, 0);\n return;\n }\n\n if (this.props.addEndListener) {\n var _ref3 = this.props.nodeRef ? [this.nextCallback] : [node, this.nextCallback],\n maybeNode = _ref3[0],\n maybeNextCallback = _ref3[1];\n\n this.props.addEndListener(maybeNode, maybeNextCallback);\n }\n\n if (timeout != null) {\n setTimeout(this.nextCallback, timeout);\n }\n };\n\n _proto.render = function render() {\n var status = this.state.status;\n\n if (status === UNMOUNTED) {\n return null;\n }\n\n var _this$props = this.props,\n children = _this$props.children,\n _in = _this$props.in,\n _mountOnEnter = _this$props.mountOnEnter,\n _unmountOnExit = _this$props.unmountOnExit,\n _appear = _this$props.appear,\n _enter = _this$props.enter,\n _exit = _this$props.exit,\n _timeout = _this$props.timeout,\n _addEndListener = _this$props.addEndListener,\n _onEnter = _this$props.onEnter,\n _onEntering = _this$props.onEntering,\n _onEntered = _this$props.onEntered,\n _onExit = _this$props.onExit,\n _onExiting = _this$props.onExiting,\n _onExited = _this$props.onExited,\n _nodeRef = _this$props.nodeRef,\n childProps = _objectWithoutPropertiesLoose(_this$props, [\"children\", \"in\", \"mountOnEnter\", \"unmountOnExit\", \"appear\", \"enter\", \"exit\", \"timeout\", \"addEndListener\", \"onEnter\", \"onEntering\", \"onEntered\", \"onExit\", \"onExiting\", \"onExited\", \"nodeRef\"]);\n\n return (\n /*#__PURE__*/\n // allows for nested Transitions\n React.createElement(TransitionGroupContext.Provider, {\n value: null\n }, typeof children === 'function' ? children(status, childProps) : React.cloneElement(React.Children.only(children), childProps))\n );\n };\n\n return Transition;\n}(React.Component);\n\nTransition.contextType = TransitionGroupContext;\nTransition.propTypes = process.env.NODE_ENV !== \"production\" ? {\n /**\n * A React reference to DOM element that need to transition:\n * https://stackoverflow.com/a/51127130/4671932\n *\n * - When `nodeRef` prop is used, `node` is not passed to callback functions\n * (e.g. `onEnter`) because user already has direct access to the node.\n * - When changing `key` prop of `Transition` in a `TransitionGroup` a new\n * `nodeRef` need to be provided to `Transition` with changed `key` prop\n * (see\n * [test/CSSTransition-test.js](https://github.com/reactjs/react-transition-group/blob/13435f897b3ab71f6e19d724f145596f5910581c/test/CSSTransition-test.js#L362-L437)).\n */\n nodeRef: PropTypes.shape({\n current: typeof Element === 'undefined' ? PropTypes.any : function (propValue, key, componentName, location, propFullName, secret) {\n var value = propValue[key];\n return PropTypes.instanceOf(value && 'ownerDocument' in value ? value.ownerDocument.defaultView.Element : Element)(propValue, key, componentName, location, propFullName, secret);\n }\n }),\n\n /**\n * A `function` child can be used instead of a React element. This function is\n * called with the current transition status (`'entering'`, `'entered'`,\n * `'exiting'`, `'exited'`), which can be used to apply context\n * specific props to a component.\n *\n * ```jsx\n * \n * {state => (\n * \n * )}\n * \n * ```\n */\n children: PropTypes.oneOfType([PropTypes.func.isRequired, PropTypes.element.isRequired]).isRequired,\n\n /**\n * Show the component; triggers the enter or exit states\n */\n in: PropTypes.bool,\n\n /**\n * By default the child component is mounted immediately along with\n * the parent `Transition` component. If you want to \"lazy mount\" the component on the\n * first `in={true}` you can set `mountOnEnter`. After the first enter transition the component will stay\n * mounted, even on \"exited\", unless you also specify `unmountOnExit`.\n */\n mountOnEnter: PropTypes.bool,\n\n /**\n * By default the child component stays mounted after it reaches the `'exited'` state.\n * Set `unmountOnExit` if you'd prefer to unmount the component after it finishes exiting.\n */\n unmountOnExit: PropTypes.bool,\n\n /**\n * By default the child component does not perform the enter transition when\n * it first mounts, regardless of the value of `in`. If you want this\n * behavior, set both `appear` and `in` to `true`.\n *\n * > **Note**: there are no special appear states like `appearing`/`appeared`, this prop\n * > only adds an additional enter transition. However, in the\n * > `` component that first enter transition does result in\n * > additional `.appear-*` classes, that way you can choose to style it\n * > differently.\n */\n appear: PropTypes.bool,\n\n /**\n * Enable or disable enter transitions.\n */\n enter: PropTypes.bool,\n\n /**\n * Enable or disable exit transitions.\n */\n exit: PropTypes.bool,\n\n /**\n * The duration of the transition, in milliseconds.\n * Required unless `addEndListener` is provided.\n *\n * You may specify a single timeout for all transitions:\n *\n * ```jsx\n * timeout={500}\n * ```\n *\n * or individually:\n *\n * ```jsx\n * timeout={{\n * appear: 500,\n * enter: 300,\n * exit: 500,\n * }}\n * ```\n *\n * - `appear` defaults to the value of `enter`\n * - `enter` defaults to `0`\n * - `exit` defaults to `0`\n *\n * @type {number | { enter?: number, exit?: number, appear?: number }}\n */\n timeout: function timeout(props) {\n var pt = timeoutsShape;\n if (!props.addEndListener) pt = pt.isRequired;\n\n for (var _len = arguments.length, args = new Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) {\n args[_key - 1] = arguments[_key];\n }\n\n return pt.apply(void 0, [props].concat(args));\n },\n\n /**\n * Add a custom transition end trigger. Called with the transitioning\n * DOM node and a `done` callback. Allows for more fine grained transition end\n * logic. Timeouts are still used as a fallback if provided.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * ```jsx\n * addEndListener={(node, done) => {\n * // use the css transitionend event to mark the finish of a transition\n * node.addEventListener('transitionend', done, false);\n * }}\n * ```\n */\n addEndListener: PropTypes.func,\n\n /**\n * Callback fired before the \"entering\" status is applied. An extra parameter\n * `isAppearing` is supplied to indicate if the enter stage is occurring on the initial mount\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement, isAppearing: bool) -> void\n */\n onEnter: PropTypes.func,\n\n /**\n * Callback fired after the \"entering\" status is applied. An extra parameter\n * `isAppearing` is supplied to indicate if the enter stage is occurring on the initial mount\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement, isAppearing: bool)\n */\n onEntering: PropTypes.func,\n\n /**\n * Callback fired after the \"entered\" status is applied. An extra parameter\n * `isAppearing` is supplied to indicate if the enter stage is occurring on the initial mount\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement, isAppearing: bool) -> void\n */\n onEntered: PropTypes.func,\n\n /**\n * Callback fired before the \"exiting\" status is applied.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement) -> void\n */\n onExit: PropTypes.func,\n\n /**\n * Callback fired after the \"exiting\" status is applied.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement) -> void\n */\n onExiting: PropTypes.func,\n\n /**\n * Callback fired after the \"exited\" status is applied.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed\n *\n * @type Function(node: HtmlElement) -> void\n */\n onExited: PropTypes.func\n} : {}; // Name the function so it is clearer in the documentation\n\nfunction noop() {}\n\nTransition.defaultProps = {\n in: false,\n mountOnEnter: false,\n unmountOnExit: false,\n appear: false,\n enter: true,\n exit: true,\n onEnter: noop,\n onEntering: noop,\n onEntered: noop,\n onExit: noop,\n onExiting: noop,\n onExited: noop\n};\nTransition.UNMOUNTED = UNMOUNTED;\nTransition.EXITED = EXITED;\nTransition.ENTERING = ENTERING;\nTransition.ENTERED = ENTERED;\nTransition.EXITING = EXITING;\nexport default Transition;","export const reflow = node => node.scrollTop;\nexport function getTransitionProps(props, options) {\n var _style$transitionDura, _style$transitionTimi;\n const {\n timeout,\n easing,\n style = {}\n } = props;\n return {\n duration: (_style$transitionDura = style.transitionDuration) != null ? _style$transitionDura : typeof timeout === 'number' ? timeout : timeout[options.mode] || 0,\n easing: (_style$transitionTimi = style.transitionTimingFunction) != null ? _style$transitionTimi : typeof easing === 'object' ? easing[options.mode] : easing,\n delay: style.transitionDelay\n };\n}","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"addEndListener\", \"appear\", \"children\", \"easing\", \"in\", \"onEnter\", \"onEntered\", \"onEntering\", \"onExit\", \"onExited\", \"onExiting\", \"style\", \"timeout\", \"TransitionComponent\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport { elementAcceptingRef, unstable_useTimeout as useTimeout } from '@mui/utils';\nimport { Transition } from 'react-transition-group';\nimport useTheme from '../styles/useTheme';\nimport { getTransitionProps, reflow } from '../transitions/utils';\nimport useForkRef from '../utils/useForkRef';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nfunction getScale(value) {\n return `scale(${value}, ${value ** 2})`;\n}\nconst styles = {\n entering: {\n opacity: 1,\n transform: getScale(1)\n },\n entered: {\n opacity: 1,\n transform: 'none'\n }\n};\n\n/*\n TODO v6: remove\n Conditionally apply a workaround for the CSS transition bug in Safari 15.4 / WebKit browsers.\n */\nconst isWebKit154 = typeof navigator !== 'undefined' && /^((?!chrome|android).)*(safari|mobile)/i.test(navigator.userAgent) && /(os |version\\/)15(.|_)4/i.test(navigator.userAgent);\n\n/**\n * The Grow transition is used by the [Tooltip](/material-ui/react-tooltip/) and\n * [Popover](/material-ui/react-popover/) components.\n * It uses [react-transition-group](https://github.com/reactjs/react-transition-group) internally.\n */\nconst Grow = /*#__PURE__*/React.forwardRef(function Grow(props, ref) {\n const {\n addEndListener,\n appear = true,\n children,\n easing,\n in: inProp,\n onEnter,\n onEntered,\n onEntering,\n onExit,\n onExited,\n onExiting,\n style,\n timeout = 'auto',\n // eslint-disable-next-line react/prop-types\n TransitionComponent = Transition\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const timer = useTimeout();\n const autoTimeout = React.useRef();\n const theme = useTheme();\n const nodeRef = React.useRef(null);\n const handleRef = useForkRef(nodeRef, children.ref, ref);\n const normalizedTransitionCallback = callback => maybeIsAppearing => {\n if (callback) {\n const node = nodeRef.current;\n\n // onEnterXxx and onExitXxx callbacks have a different arguments.length value.\n if (maybeIsAppearing === undefined) {\n callback(node);\n } else {\n callback(node, maybeIsAppearing);\n }\n }\n };\n const handleEntering = normalizedTransitionCallback(onEntering);\n const handleEnter = normalizedTransitionCallback((node, isAppearing) => {\n reflow(node); // So the animation always start from the start.\n\n const {\n duration: transitionDuration,\n delay,\n easing: transitionTimingFunction\n } = getTransitionProps({\n style,\n timeout,\n easing\n }, {\n mode: 'enter'\n });\n let duration;\n if (timeout === 'auto') {\n duration = theme.transitions.getAutoHeightDuration(node.clientHeight);\n autoTimeout.current = duration;\n } else {\n duration = transitionDuration;\n }\n node.style.transition = [theme.transitions.create('opacity', {\n duration,\n delay\n }), theme.transitions.create('transform', {\n duration: isWebKit154 ? duration : duration * 0.666,\n delay,\n easing: transitionTimingFunction\n })].join(',');\n if (onEnter) {\n onEnter(node, isAppearing);\n }\n });\n const handleEntered = normalizedTransitionCallback(onEntered);\n const handleExiting = normalizedTransitionCallback(onExiting);\n const handleExit = normalizedTransitionCallback(node => {\n const {\n duration: transitionDuration,\n delay,\n easing: transitionTimingFunction\n } = getTransitionProps({\n style,\n timeout,\n easing\n }, {\n mode: 'exit'\n });\n let duration;\n if (timeout === 'auto') {\n duration = theme.transitions.getAutoHeightDuration(node.clientHeight);\n autoTimeout.current = duration;\n } else {\n duration = transitionDuration;\n }\n node.style.transition = [theme.transitions.create('opacity', {\n duration,\n delay\n }), theme.transitions.create('transform', {\n duration: isWebKit154 ? duration : duration * 0.666,\n delay: isWebKit154 ? delay : delay || duration * 0.333,\n easing: transitionTimingFunction\n })].join(',');\n node.style.opacity = 0;\n node.style.transform = getScale(0.75);\n if (onExit) {\n onExit(node);\n }\n });\n const handleExited = normalizedTransitionCallback(onExited);\n const handleAddEndListener = next => {\n if (timeout === 'auto') {\n timer.start(autoTimeout.current || 0, next);\n }\n if (addEndListener) {\n // Old call signature before `react-transition-group` implemented `nodeRef`\n addEndListener(nodeRef.current, next);\n }\n };\n return /*#__PURE__*/_jsx(TransitionComponent, _extends({\n appear: appear,\n in: inProp,\n nodeRef: nodeRef,\n onEnter: handleEnter,\n onEntered: handleEntered,\n onEntering: handleEntering,\n onExit: handleExit,\n onExited: handleExited,\n onExiting: handleExiting,\n addEndListener: handleAddEndListener,\n timeout: timeout === 'auto' ? null : timeout\n }, other, {\n children: (state, childProps) => {\n return /*#__PURE__*/React.cloneElement(children, _extends({\n style: _extends({\n opacity: 0,\n transform: getScale(0.75),\n visibility: state === 'exited' && !inProp ? 'hidden' : undefined\n }, styles[state], style, children.props.style),\n ref: handleRef\n }, childProps));\n }\n }));\n});\nprocess.env.NODE_ENV !== \"production\" ? Grow.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the d.ts file and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * Add a custom transition end trigger. Called with the transitioning DOM\n * node and a done callback. Allows for more fine grained transition end\n * logic. Note: Timeouts are still used as a fallback if provided.\n */\n addEndListener: PropTypes.func,\n /**\n * Perform the enter transition when it first mounts if `in` is also `true`.\n * Set this to `false` to disable this behavior.\n * @default true\n */\n appear: PropTypes.bool,\n /**\n * A single child content element.\n */\n children: elementAcceptingRef.isRequired,\n /**\n * The transition timing function.\n * You may specify a single easing or a object containing enter and exit values.\n */\n easing: PropTypes.oneOfType([PropTypes.shape({\n enter: PropTypes.string,\n exit: PropTypes.string\n }), PropTypes.string]),\n /**\n * If `true`, the component will transition in.\n */\n in: PropTypes.bool,\n /**\n * @ignore\n */\n onEnter: PropTypes.func,\n /**\n * @ignore\n */\n onEntered: PropTypes.func,\n /**\n * @ignore\n */\n onEntering: PropTypes.func,\n /**\n * @ignore\n */\n onExit: PropTypes.func,\n /**\n * @ignore\n */\n onExited: PropTypes.func,\n /**\n * @ignore\n */\n onExiting: PropTypes.func,\n /**\n * @ignore\n */\n style: PropTypes.object,\n /**\n * The duration for the transition, in milliseconds.\n * You may specify a single timeout for all transitions, or individually with an object.\n *\n * Set to 'auto' to automatically calculate transition time based on height.\n * @default 'auto'\n */\n timeout: PropTypes.oneOfType([PropTypes.oneOf(['auto']), PropTypes.number, PropTypes.shape({\n appear: PropTypes.number,\n enter: PropTypes.number,\n exit: PropTypes.number\n })])\n} : void 0;\nGrow.muiSupportAuto = true;\nexport default Grow;","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"anchorEl\", \"component\", \"components\", \"componentsProps\", \"container\", \"disablePortal\", \"keepMounted\", \"modifiers\", \"open\", \"placement\", \"popperOptions\", \"popperRef\", \"transition\", \"slots\", \"slotProps\"];\nimport { Popper as BasePopper } from '@mui/base/Popper';\nimport { useThemeWithoutDefault as useTheme } from '@mui/system';\nimport { HTMLElementType, refType } from '@mui/utils';\nimport PropTypes from 'prop-types';\nimport * as React from 'react';\nimport { styled, useThemeProps } from '../styles';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nconst PopperRoot = styled(BasePopper, {\n name: 'MuiPopper',\n slot: 'Root',\n overridesResolver: (props, styles) => styles.root\n})({});\n\n/**\n *\n * Demos:\n *\n * - [Autocomplete](https://mui.com/material-ui/react-autocomplete/)\n * - [Menu](https://mui.com/material-ui/react-menu/)\n * - [Popper](https://mui.com/material-ui/react-popper/)\n *\n * API:\n *\n * - [Popper API](https://mui.com/material-ui/api/popper/)\n */\nconst Popper = /*#__PURE__*/React.forwardRef(function Popper(inProps, ref) {\n var _slots$root;\n const theme = useTheme();\n const props = useThemeProps({\n props: inProps,\n name: 'MuiPopper'\n });\n const {\n anchorEl,\n component,\n components,\n componentsProps,\n container,\n disablePortal,\n keepMounted,\n modifiers,\n open,\n placement,\n popperOptions,\n popperRef,\n transition,\n slots,\n slotProps\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const RootComponent = (_slots$root = slots == null ? void 0 : slots.root) != null ? _slots$root : components == null ? void 0 : components.Root;\n const otherProps = _extends({\n anchorEl,\n container,\n disablePortal,\n keepMounted,\n modifiers,\n open,\n placement,\n popperOptions,\n popperRef,\n transition\n }, other);\n return /*#__PURE__*/_jsx(PopperRoot, _extends({\n as: component,\n direction: theme == null ? void 0 : theme.direction,\n slots: {\n root: RootComponent\n },\n slotProps: slotProps != null ? slotProps : componentsProps\n }, otherProps, {\n ref: ref\n }));\n});\nprocess.env.NODE_ENV !== \"production\" ? Popper.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * An HTML element, [virtualElement](https://popper.js.org/docs/v2/virtual-elements/),\n * or a function that returns either.\n * It's used to set the position of the popper.\n * The return value will passed as the reference object of the Popper instance.\n */\n anchorEl: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.object, PropTypes.func]),\n /**\n * Popper render function or node.\n */\n children: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.node, PropTypes.func]),\n /**\n * The component used for the root node.\n * Either a string to use a HTML element or a component.\n */\n component: PropTypes.elementType,\n /**\n * The components used for each slot inside the Popper.\n * Either a string to use a HTML element or a component.\n * @default {}\n */\n components: PropTypes.shape({\n Root: PropTypes.elementType\n }),\n /**\n * The props used for each slot inside the Popper.\n * @default {}\n */\n componentsProps: PropTypes.shape({\n root: PropTypes.oneOfType([PropTypes.func, PropTypes.object])\n }),\n /**\n * An HTML element or function that returns one.\n * The `container` will have the portal children appended to it.\n *\n * You can also provide a callback, which is called in a React layout effect.\n * This lets you set the container from a ref, and also makes server-side rendering possible.\n *\n * By default, it uses the body of the top-level document object,\n * so it's simply `document.body` most of the time.\n */\n container: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.func]),\n /**\n * The `children` will be under the DOM hierarchy of the parent component.\n * @default false\n */\n disablePortal: PropTypes.bool,\n /**\n * Always keep the children in the DOM.\n * This prop can be useful in SEO situation or\n * when you want to maximize the responsiveness of the Popper.\n * @default false\n */\n keepMounted: PropTypes.bool,\n /**\n * Popper.js is based on a \"plugin-like\" architecture,\n * most of its features are fully encapsulated \"modifiers\".\n *\n * A modifier is a function that is called each time Popper.js needs to\n * compute the position of the popper.\n * For this reason, modifiers should be very performant to avoid bottlenecks.\n * To learn how to create a modifier, [read the modifiers documentation](https://popper.js.org/docs/v2/modifiers/).\n */\n modifiers: PropTypes.arrayOf(PropTypes.shape({\n data: PropTypes.object,\n effect: PropTypes.func,\n enabled: PropTypes.bool,\n fn: PropTypes.func,\n name: PropTypes.any,\n options: PropTypes.object,\n phase: PropTypes.oneOf(['afterMain', 'afterRead', 'afterWrite', 'beforeMain', 'beforeRead', 'beforeWrite', 'main', 'read', 'write']),\n requires: PropTypes.arrayOf(PropTypes.string),\n requiresIfExists: PropTypes.arrayOf(PropTypes.string)\n })),\n /**\n * If `true`, the component is shown.\n */\n open: PropTypes.bool.isRequired,\n /**\n * Popper placement.\n * @default 'bottom'\n */\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n /**\n * Options provided to the [`Popper.js`](https://popper.js.org/docs/v2/constructors/#options) instance.\n * @default {}\n */\n popperOptions: PropTypes.shape({\n modifiers: PropTypes.array,\n onFirstUpdate: PropTypes.func,\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n strategy: PropTypes.oneOf(['absolute', 'fixed'])\n }),\n /**\n * A ref that points to the used popper instance.\n */\n popperRef: refType,\n /**\n * The props used for each slot inside the Popper.\n * @default {}\n */\n slotProps: PropTypes.shape({\n root: PropTypes.oneOfType([PropTypes.func, PropTypes.object])\n }),\n /**\n * The components used for each slot inside the Popper.\n * Either a string to use a HTML element or a component.\n * @default {}\n */\n slots: PropTypes.shape({\n root: PropTypes.elementType\n }),\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Help supporting a react-transition-group/Transition component.\n * @default false\n */\n transition: PropTypes.bool\n} : void 0;\nexport default Popper;","import generateUtilityClasses from '@mui/utils/generateUtilityClasses';\nimport generateUtilityClass from '@mui/utils/generateUtilityClass';\nexport function getTooltipUtilityClass(slot) {\n return generateUtilityClass('MuiTooltip', slot);\n}\nconst tooltipClasses = generateUtilityClasses('MuiTooltip', ['popper', 'popperInteractive', 'popperArrow', 'popperClose', 'tooltip', 'tooltipArrow', 'touch', 'tooltipPlacementLeft', 'tooltipPlacementRight', 'tooltipPlacementTop', 'tooltipPlacementBottom', 'arrow']);\nexport default tooltipClasses;","'use client';\n\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nconst _excluded = [\"arrow\", \"children\", \"classes\", \"components\", \"componentsProps\", \"describeChild\", \"disableFocusListener\", \"disableHoverListener\", \"disableInteractive\", \"disableTouchListener\", \"enterDelay\", \"enterNextDelay\", \"enterTouchDelay\", \"followCursor\", \"id\", \"leaveDelay\", \"leaveTouchDelay\", \"onClose\", \"onOpen\", \"open\", \"placement\", \"PopperComponent\", \"PopperProps\", \"slotProps\", \"slots\", \"title\", \"TransitionComponent\", \"TransitionProps\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport clsx from 'clsx';\nimport { elementAcceptingRef, unstable_useTimeout as useTimeout, unstable_Timeout as Timeout } from '@mui/utils';\nimport { unstable_composeClasses as composeClasses, appendOwnerState } from '@mui/base';\nimport { alpha } from '@mui/system';\nimport styled from '../styles/styled';\nimport useTheme from '../styles/useTheme';\nimport useThemeProps from '../styles/useThemeProps';\nimport capitalize from '../utils/capitalize';\nimport Grow from '../Grow';\nimport Popper from '../Popper';\nimport useEventCallback from '../utils/useEventCallback';\nimport useForkRef from '../utils/useForkRef';\nimport useId from '../utils/useId';\nimport useIsFocusVisible from '../utils/useIsFocusVisible';\nimport useControlled from '../utils/useControlled';\nimport tooltipClasses, { getTooltipUtilityClass } from './tooltipClasses';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nimport { jsxs as _jsxs } from \"react/jsx-runtime\";\nfunction round(value) {\n return Math.round(value * 1e5) / 1e5;\n}\nconst useUtilityClasses = ownerState => {\n const {\n classes,\n disableInteractive,\n arrow,\n touch,\n placement\n } = ownerState;\n const slots = {\n popper: ['popper', !disableInteractive && 'popperInteractive', arrow && 'popperArrow'],\n tooltip: ['tooltip', arrow && 'tooltipArrow', touch && 'touch', `tooltipPlacement${capitalize(placement.split('-')[0])}`],\n arrow: ['arrow']\n };\n return composeClasses(slots, getTooltipUtilityClass, classes);\n};\nconst TooltipPopper = styled(Popper, {\n name: 'MuiTooltip',\n slot: 'Popper',\n overridesResolver: (props, styles) => {\n const {\n ownerState\n } = props;\n return [styles.popper, !ownerState.disableInteractive && styles.popperInteractive, ownerState.arrow && styles.popperArrow, !ownerState.open && styles.popperClose];\n }\n})(({\n theme,\n ownerState,\n open\n}) => _extends({\n zIndex: (theme.vars || theme).zIndex.tooltip,\n pointerEvents: 'none'\n}, !ownerState.disableInteractive && {\n pointerEvents: 'auto'\n}, !open && {\n pointerEvents: 'none'\n}, ownerState.arrow && {\n [`&[data-popper-placement*=\"bottom\"] .${tooltipClasses.arrow}`]: {\n top: 0,\n marginTop: '-0.71em',\n '&::before': {\n transformOrigin: '0 100%'\n }\n },\n [`&[data-popper-placement*=\"top\"] .${tooltipClasses.arrow}`]: {\n bottom: 0,\n marginBottom: '-0.71em',\n '&::before': {\n transformOrigin: '100% 0'\n }\n },\n [`&[data-popper-placement*=\"right\"] .${tooltipClasses.arrow}`]: _extends({}, !ownerState.isRtl ? {\n left: 0,\n marginLeft: '-0.71em'\n } : {\n right: 0,\n marginRight: '-0.71em'\n }, {\n height: '1em',\n width: '0.71em',\n '&::before': {\n transformOrigin: '100% 100%'\n }\n }),\n [`&[data-popper-placement*=\"left\"] .${tooltipClasses.arrow}`]: _extends({}, !ownerState.isRtl ? {\n right: 0,\n marginRight: '-0.71em'\n } : {\n left: 0,\n marginLeft: '-0.71em'\n }, {\n height: '1em',\n width: '0.71em',\n '&::before': {\n transformOrigin: '0 0'\n }\n })\n}));\nconst TooltipTooltip = styled('div', {\n name: 'MuiTooltip',\n slot: 'Tooltip',\n overridesResolver: (props, styles) => {\n const {\n ownerState\n } = props;\n return [styles.tooltip, ownerState.touch && styles.touch, ownerState.arrow && styles.tooltipArrow, styles[`tooltipPlacement${capitalize(ownerState.placement.split('-')[0])}`]];\n }\n})(({\n theme,\n ownerState\n}) => _extends({\n backgroundColor: theme.vars ? theme.vars.palette.Tooltip.bg : alpha(theme.palette.grey[700], 0.92),\n borderRadius: (theme.vars || theme).shape.borderRadius,\n color: (theme.vars || theme).palette.common.white,\n fontFamily: theme.typography.fontFamily,\n padding: '4px 8px',\n fontSize: theme.typography.pxToRem(11),\n maxWidth: 300,\n margin: 2,\n wordWrap: 'break-word',\n fontWeight: theme.typography.fontWeightMedium\n}, ownerState.arrow && {\n position: 'relative',\n margin: 0\n}, ownerState.touch && {\n padding: '8px 16px',\n fontSize: theme.typography.pxToRem(14),\n lineHeight: `${round(16 / 14)}em`,\n fontWeight: theme.typography.fontWeightRegular\n}, {\n [`.${tooltipClasses.popper}[data-popper-placement*=\"left\"] &`]: _extends({\n transformOrigin: 'right center'\n }, !ownerState.isRtl ? _extends({\n marginRight: '14px'\n }, ownerState.touch && {\n marginRight: '24px'\n }) : _extends({\n marginLeft: '14px'\n }, ownerState.touch && {\n marginLeft: '24px'\n })),\n [`.${tooltipClasses.popper}[data-popper-placement*=\"right\"] &`]: _extends({\n transformOrigin: 'left center'\n }, !ownerState.isRtl ? _extends({\n marginLeft: '14px'\n }, ownerState.touch && {\n marginLeft: '24px'\n }) : _extends({\n marginRight: '14px'\n }, ownerState.touch && {\n marginRight: '24px'\n })),\n [`.${tooltipClasses.popper}[data-popper-placement*=\"top\"] &`]: _extends({\n transformOrigin: 'center bottom',\n marginBottom: '14px'\n }, ownerState.touch && {\n marginBottom: '24px'\n }),\n [`.${tooltipClasses.popper}[data-popper-placement*=\"bottom\"] &`]: _extends({\n transformOrigin: 'center top',\n marginTop: '14px'\n }, ownerState.touch && {\n marginTop: '24px'\n })\n}));\nconst TooltipArrow = styled('span', {\n name: 'MuiTooltip',\n slot: 'Arrow',\n overridesResolver: (props, styles) => styles.arrow\n})(({\n theme\n}) => ({\n overflow: 'hidden',\n position: 'absolute',\n width: '1em',\n height: '0.71em' /* = width / sqrt(2) = (length of the hypotenuse) */,\n boxSizing: 'border-box',\n color: theme.vars ? theme.vars.palette.Tooltip.bg : alpha(theme.palette.grey[700], 0.9),\n '&::before': {\n content: '\"\"',\n margin: 'auto',\n display: 'block',\n width: '100%',\n height: '100%',\n backgroundColor: 'currentColor',\n transform: 'rotate(45deg)'\n }\n}));\nlet hystersisOpen = false;\nconst hystersisTimer = new Timeout();\nlet cursorPosition = {\n x: 0,\n y: 0\n};\nexport function testReset() {\n hystersisOpen = false;\n hystersisTimer.clear();\n}\nfunction composeEventHandler(handler, eventHandler) {\n return event => {\n if (eventHandler) {\n eventHandler(event);\n }\n handler(event);\n };\n}\n\n// TODO v6: Remove PopperComponent, PopperProps, TransitionComponent and TransitionProps.\nconst Tooltip = /*#__PURE__*/React.forwardRef(function Tooltip(inProps, ref) {\n var _ref, _slots$popper, _ref2, _ref3, _slots$transition, _ref4, _slots$tooltip, _ref5, _slots$arrow, _slotProps$popper, _ref6, _slotProps$popper2, _slotProps$transition, _slotProps$tooltip, _ref7, _slotProps$tooltip2, _slotProps$arrow, _ref8, _slotProps$arrow2;\n const props = useThemeProps({\n props: inProps,\n name: 'MuiTooltip'\n });\n const {\n arrow = false,\n children: childrenProp,\n components = {},\n componentsProps = {},\n describeChild = false,\n disableFocusListener = false,\n disableHoverListener = false,\n disableInteractive: disableInteractiveProp = false,\n disableTouchListener = false,\n enterDelay = 100,\n enterNextDelay = 0,\n enterTouchDelay = 700,\n followCursor = false,\n id: idProp,\n leaveDelay = 0,\n leaveTouchDelay = 1500,\n onClose,\n onOpen,\n open: openProp,\n placement = 'bottom',\n PopperComponent: PopperComponentProp,\n PopperProps = {},\n slotProps = {},\n slots = {},\n title,\n TransitionComponent: TransitionComponentProp = Grow,\n TransitionProps\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n\n // to prevent runtime errors, developers will need to provide a child as a React element anyway.\n const children = /*#__PURE__*/React.isValidElement(childrenProp) ? childrenProp : /*#__PURE__*/_jsx(\"span\", {\n children: childrenProp\n });\n const theme = useTheme();\n const isRtl = theme.direction === 'rtl';\n const [childNode, setChildNode] = React.useState();\n const [arrowRef, setArrowRef] = React.useState(null);\n const ignoreNonTouchEvents = React.useRef(false);\n const disableInteractive = disableInteractiveProp || followCursor;\n const closeTimer = useTimeout();\n const enterTimer = useTimeout();\n const leaveTimer = useTimeout();\n const touchTimer = useTimeout();\n const [openState, setOpenState] = useControlled({\n controlled: openProp,\n default: false,\n name: 'Tooltip',\n state: 'open'\n });\n let open = openState;\n if (process.env.NODE_ENV !== 'production') {\n // eslint-disable-next-line react-hooks/rules-of-hooks\n const {\n current: isControlled\n } = React.useRef(openProp !== undefined);\n\n // eslint-disable-next-line react-hooks/rules-of-hooks\n React.useEffect(() => {\n if (childNode && childNode.disabled && !isControlled && title !== '' && childNode.tagName.toLowerCase() === 'button') {\n console.error(['MUI: You are providing a disabled `button` child to the Tooltip component.', 'A disabled element does not fire events.', \"Tooltip needs to listen to the child element's events to display the title.\", '', 'Add a simple wrapper element, such as a `span`.'].join('\\n'));\n }\n }, [title, childNode, isControlled]);\n }\n const id = useId(idProp);\n const prevUserSelect = React.useRef();\n const stopTouchInteraction = useEventCallback(() => {\n if (prevUserSelect.current !== undefined) {\n document.body.style.WebkitUserSelect = prevUserSelect.current;\n prevUserSelect.current = undefined;\n }\n touchTimer.clear();\n });\n React.useEffect(() => stopTouchInteraction, [stopTouchInteraction]);\n const handleOpen = event => {\n hystersisTimer.clear();\n hystersisOpen = true;\n\n // The mouseover event will trigger for every nested element in the tooltip.\n // We can skip rerendering when the tooltip is already open.\n // We are using the mouseover event instead of the mouseenter event to fix a hide/show issue.\n setOpenState(true);\n if (onOpen && !open) {\n onOpen(event);\n }\n };\n const handleClose = useEventCallback(\n /**\n * @param {React.SyntheticEvent | Event} event\n */\n event => {\n hystersisTimer.start(800 + leaveDelay, () => {\n hystersisOpen = false;\n });\n setOpenState(false);\n if (onClose && open) {\n onClose(event);\n }\n closeTimer.start(theme.transitions.duration.shortest, () => {\n ignoreNonTouchEvents.current = false;\n });\n });\n const handleEnter = event => {\n if (ignoreNonTouchEvents.current && event.type !== 'touchstart') {\n return;\n }\n\n // Remove the title ahead of time.\n // We don't want to wait for the next render commit.\n // We would risk displaying two tooltips at the same time (native + this one).\n if (childNode) {\n childNode.removeAttribute('title');\n }\n enterTimer.clear();\n leaveTimer.clear();\n if (enterDelay || hystersisOpen && enterNextDelay) {\n enterTimer.start(hystersisOpen ? enterNextDelay : enterDelay, () => {\n handleOpen(event);\n });\n } else {\n handleOpen(event);\n }\n };\n const handleLeave = event => {\n enterTimer.clear();\n leaveTimer.start(leaveDelay, () => {\n handleClose(event);\n });\n };\n const {\n isFocusVisibleRef,\n onBlur: handleBlurVisible,\n onFocus: handleFocusVisible,\n ref: focusVisibleRef\n } = useIsFocusVisible();\n // We don't necessarily care about the focusVisible state (which is safe to access via ref anyway).\n // We just need to re-render the Tooltip if the focus-visible state changes.\n const [, setChildIsFocusVisible] = React.useState(false);\n const handleBlur = event => {\n handleBlurVisible(event);\n if (isFocusVisibleRef.current === false) {\n setChildIsFocusVisible(false);\n handleLeave(event);\n }\n };\n const handleFocus = event => {\n // Workaround for https://github.com/facebook/react/issues/7769\n // The autoFocus of React might trigger the event before the componentDidMount.\n // We need to account for this eventuality.\n if (!childNode) {\n setChildNode(event.currentTarget);\n }\n handleFocusVisible(event);\n if (isFocusVisibleRef.current === true) {\n setChildIsFocusVisible(true);\n handleEnter(event);\n }\n };\n const detectTouchStart = event => {\n ignoreNonTouchEvents.current = true;\n const childrenProps = children.props;\n if (childrenProps.onTouchStart) {\n childrenProps.onTouchStart(event);\n }\n };\n const handleMouseOver = handleEnter;\n const handleMouseLeave = handleLeave;\n const handleTouchStart = event => {\n detectTouchStart(event);\n leaveTimer.clear();\n closeTimer.clear();\n stopTouchInteraction();\n prevUserSelect.current = document.body.style.WebkitUserSelect;\n // Prevent iOS text selection on long-tap.\n document.body.style.WebkitUserSelect = 'none';\n touchTimer.start(enterTouchDelay, () => {\n document.body.style.WebkitUserSelect = prevUserSelect.current;\n handleEnter(event);\n });\n };\n const handleTouchEnd = event => {\n if (children.props.onTouchEnd) {\n children.props.onTouchEnd(event);\n }\n stopTouchInteraction();\n leaveTimer.start(leaveTouchDelay, () => {\n handleClose(event);\n });\n };\n React.useEffect(() => {\n if (!open) {\n return undefined;\n }\n\n /**\n * @param {KeyboardEvent} nativeEvent\n */\n function handleKeyDown(nativeEvent) {\n // IE11, Edge (prior to using Bink?) use 'Esc'\n if (nativeEvent.key === 'Escape' || nativeEvent.key === 'Esc') {\n handleClose(nativeEvent);\n }\n }\n document.addEventListener('keydown', handleKeyDown);\n return () => {\n document.removeEventListener('keydown', handleKeyDown);\n };\n }, [handleClose, open]);\n const handleRef = useForkRef(children.ref, focusVisibleRef, setChildNode, ref);\n\n // There is no point in displaying an empty tooltip.\n // So we exclude all falsy values, except 0, which is valid.\n if (!title && title !== 0) {\n open = false;\n }\n const popperRef = React.useRef();\n const handleMouseMove = event => {\n const childrenProps = children.props;\n if (childrenProps.onMouseMove) {\n childrenProps.onMouseMove(event);\n }\n cursorPosition = {\n x: event.clientX,\n y: event.clientY\n };\n if (popperRef.current) {\n popperRef.current.update();\n }\n };\n const nameOrDescProps = {};\n const titleIsString = typeof title === 'string';\n if (describeChild) {\n nameOrDescProps.title = !open && titleIsString && !disableHoverListener ? title : null;\n nameOrDescProps['aria-describedby'] = open ? id : null;\n } else {\n nameOrDescProps['aria-label'] = titleIsString ? title : null;\n nameOrDescProps['aria-labelledby'] = open && !titleIsString ? id : null;\n }\n const childrenProps = _extends({}, nameOrDescProps, other, children.props, {\n className: clsx(other.className, children.props.className),\n onTouchStart: detectTouchStart,\n ref: handleRef\n }, followCursor ? {\n onMouseMove: handleMouseMove\n } : {});\n if (process.env.NODE_ENV !== 'production') {\n childrenProps['data-mui-internal-clone-element'] = true;\n\n // eslint-disable-next-line react-hooks/rules-of-hooks\n React.useEffect(() => {\n if (childNode && !childNode.getAttribute('data-mui-internal-clone-element')) {\n console.error(['MUI: The `children` component of the Tooltip is not forwarding its props correctly.', 'Please make sure that props are spread on the same element that the ref is applied to.'].join('\\n'));\n }\n }, [childNode]);\n }\n const interactiveWrapperListeners = {};\n if (!disableTouchListener) {\n childrenProps.onTouchStart = handleTouchStart;\n childrenProps.onTouchEnd = handleTouchEnd;\n }\n if (!disableHoverListener) {\n childrenProps.onMouseOver = composeEventHandler(handleMouseOver, childrenProps.onMouseOver);\n childrenProps.onMouseLeave = composeEventHandler(handleMouseLeave, childrenProps.onMouseLeave);\n if (!disableInteractive) {\n interactiveWrapperListeners.onMouseOver = handleMouseOver;\n interactiveWrapperListeners.onMouseLeave = handleMouseLeave;\n }\n }\n if (!disableFocusListener) {\n childrenProps.onFocus = composeEventHandler(handleFocus, childrenProps.onFocus);\n childrenProps.onBlur = composeEventHandler(handleBlur, childrenProps.onBlur);\n if (!disableInteractive) {\n interactiveWrapperListeners.onFocus = handleFocus;\n interactiveWrapperListeners.onBlur = handleBlur;\n }\n }\n if (process.env.NODE_ENV !== 'production') {\n if (children.props.title) {\n console.error(['MUI: You have provided a `title` prop to the child of .', `Remove this title prop \\`${children.props.title}\\` or the Tooltip component.`].join('\\n'));\n }\n }\n const popperOptions = React.useMemo(() => {\n var _PopperProps$popperOp;\n let tooltipModifiers = [{\n name: 'arrow',\n enabled: Boolean(arrowRef),\n options: {\n element: arrowRef,\n padding: 4\n }\n }];\n if ((_PopperProps$popperOp = PopperProps.popperOptions) != null && _PopperProps$popperOp.modifiers) {\n tooltipModifiers = tooltipModifiers.concat(PopperProps.popperOptions.modifiers);\n }\n return _extends({}, PopperProps.popperOptions, {\n modifiers: tooltipModifiers\n });\n }, [arrowRef, PopperProps]);\n const ownerState = _extends({}, props, {\n isRtl,\n arrow,\n disableInteractive,\n placement,\n PopperComponentProp,\n touch: ignoreNonTouchEvents.current\n });\n const classes = useUtilityClasses(ownerState);\n const PopperComponent = (_ref = (_slots$popper = slots.popper) != null ? _slots$popper : components.Popper) != null ? _ref : TooltipPopper;\n const TransitionComponent = (_ref2 = (_ref3 = (_slots$transition = slots.transition) != null ? _slots$transition : components.Transition) != null ? _ref3 : TransitionComponentProp) != null ? _ref2 : Grow;\n const TooltipComponent = (_ref4 = (_slots$tooltip = slots.tooltip) != null ? _slots$tooltip : components.Tooltip) != null ? _ref4 : TooltipTooltip;\n const ArrowComponent = (_ref5 = (_slots$arrow = slots.arrow) != null ? _slots$arrow : components.Arrow) != null ? _ref5 : TooltipArrow;\n const popperProps = appendOwnerState(PopperComponent, _extends({}, PopperProps, (_slotProps$popper = slotProps.popper) != null ? _slotProps$popper : componentsProps.popper, {\n className: clsx(classes.popper, PopperProps == null ? void 0 : PopperProps.className, (_ref6 = (_slotProps$popper2 = slotProps.popper) != null ? _slotProps$popper2 : componentsProps.popper) == null ? void 0 : _ref6.className)\n }), ownerState);\n const transitionProps = appendOwnerState(TransitionComponent, _extends({}, TransitionProps, (_slotProps$transition = slotProps.transition) != null ? _slotProps$transition : componentsProps.transition), ownerState);\n const tooltipProps = appendOwnerState(TooltipComponent, _extends({}, (_slotProps$tooltip = slotProps.tooltip) != null ? _slotProps$tooltip : componentsProps.tooltip, {\n className: clsx(classes.tooltip, (_ref7 = (_slotProps$tooltip2 = slotProps.tooltip) != null ? _slotProps$tooltip2 : componentsProps.tooltip) == null ? void 0 : _ref7.className)\n }), ownerState);\n const tooltipArrowProps = appendOwnerState(ArrowComponent, _extends({}, (_slotProps$arrow = slotProps.arrow) != null ? _slotProps$arrow : componentsProps.arrow, {\n className: clsx(classes.arrow, (_ref8 = (_slotProps$arrow2 = slotProps.arrow) != null ? _slotProps$arrow2 : componentsProps.arrow) == null ? void 0 : _ref8.className)\n }), ownerState);\n return /*#__PURE__*/_jsxs(React.Fragment, {\n children: [/*#__PURE__*/React.cloneElement(children, childrenProps), /*#__PURE__*/_jsx(PopperComponent, _extends({\n as: PopperComponentProp != null ? PopperComponentProp : Popper,\n placement: placement,\n anchorEl: followCursor ? {\n getBoundingClientRect: () => ({\n top: cursorPosition.y,\n left: cursorPosition.x,\n right: cursorPosition.x,\n bottom: cursorPosition.y,\n width: 0,\n height: 0\n })\n } : childNode,\n popperRef: popperRef,\n open: childNode ? open : false,\n id: id,\n transition: true\n }, interactiveWrapperListeners, popperProps, {\n popperOptions: popperOptions,\n children: ({\n TransitionProps: TransitionPropsInner\n }) => /*#__PURE__*/_jsx(TransitionComponent, _extends({\n timeout: theme.transitions.duration.shorter\n }, TransitionPropsInner, transitionProps, {\n children: /*#__PURE__*/_jsxs(TooltipComponent, _extends({}, tooltipProps, {\n children: [title, arrow ? /*#__PURE__*/_jsx(ArrowComponent, _extends({}, tooltipArrowProps, {\n ref: setArrowRef\n })) : null]\n }))\n }))\n }))]\n });\n});\nprocess.env.NODE_ENV !== \"production\" ? Tooltip.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the d.ts file and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * If `true`, adds an arrow to the tooltip.\n * @default false\n */\n arrow: PropTypes.bool,\n /**\n * Tooltip reference element.\n */\n children: elementAcceptingRef.isRequired,\n /**\n * Override or extend the styles applied to the component.\n */\n classes: PropTypes.object,\n /**\n * @ignore\n */\n className: PropTypes.string,\n /**\n * The components used for each slot inside.\n *\n * This prop is an alias for the `slots` prop.\n * It's recommended to use the `slots` prop instead.\n *\n * @default {}\n */\n components: PropTypes.shape({\n Arrow: PropTypes.elementType,\n Popper: PropTypes.elementType,\n Tooltip: PropTypes.elementType,\n Transition: PropTypes.elementType\n }),\n /**\n * The extra props for the slot components.\n * You can override the existing props or add new ones.\n *\n * This prop is an alias for the `slotProps` prop.\n * It's recommended to use the `slotProps` prop instead, as `componentsProps` will be deprecated in the future.\n *\n * @default {}\n */\n componentsProps: PropTypes.shape({\n arrow: PropTypes.object,\n popper: PropTypes.object,\n tooltip: PropTypes.object,\n transition: PropTypes.object\n }),\n /**\n * Set to `true` if the `title` acts as an accessible description.\n * By default the `title` acts as an accessible label for the child.\n * @default false\n */\n describeChild: PropTypes.bool,\n /**\n * Do not respond to focus-visible events.\n * @default false\n */\n disableFocusListener: PropTypes.bool,\n /**\n * Do not respond to hover events.\n * @default false\n */\n disableHoverListener: PropTypes.bool,\n /**\n * Makes a tooltip not interactive, i.e. it will close when the user\n * hovers over the tooltip before the `leaveDelay` is expired.\n * @default false\n */\n disableInteractive: PropTypes.bool,\n /**\n * Do not respond to long press touch events.\n * @default false\n */\n disableTouchListener: PropTypes.bool,\n /**\n * The number of milliseconds to wait before showing the tooltip.\n * This prop won't impact the enter touch delay (`enterTouchDelay`).\n * @default 100\n */\n enterDelay: PropTypes.number,\n /**\n * The number of milliseconds to wait before showing the tooltip when one was already recently opened.\n * @default 0\n */\n enterNextDelay: PropTypes.number,\n /**\n * The number of milliseconds a user must touch the element before showing the tooltip.\n * @default 700\n */\n enterTouchDelay: PropTypes.number,\n /**\n * If `true`, the tooltip follow the cursor over the wrapped element.\n * @default false\n */\n followCursor: PropTypes.bool,\n /**\n * This prop is used to help implement the accessibility logic.\n * If you don't provide this prop. It falls back to a randomly generated id.\n */\n id: PropTypes.string,\n /**\n * The number of milliseconds to wait before hiding the tooltip.\n * This prop won't impact the leave touch delay (`leaveTouchDelay`).\n * @default 0\n */\n leaveDelay: PropTypes.number,\n /**\n * The number of milliseconds after the user stops touching an element before hiding the tooltip.\n * @default 1500\n */\n leaveTouchDelay: PropTypes.number,\n /**\n * Callback fired when the component requests to be closed.\n *\n * @param {React.SyntheticEvent} event The event source of the callback.\n */\n onClose: PropTypes.func,\n /**\n * Callback fired when the component requests to be open.\n *\n * @param {React.SyntheticEvent} event The event source of the callback.\n */\n onOpen: PropTypes.func,\n /**\n * If `true`, the component is shown.\n */\n open: PropTypes.bool,\n /**\n * Tooltip placement.\n * @default 'bottom'\n */\n placement: PropTypes.oneOf(['bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n /**\n * The component used for the popper.\n * @default Popper\n */\n PopperComponent: PropTypes.elementType,\n /**\n * Props applied to the [`Popper`](/material-ui/api/popper/) element.\n * @default {}\n */\n PopperProps: PropTypes.object,\n /**\n * The extra props for the slot components.\n * You can override the existing props or add new ones.\n *\n * This prop is an alias for the `componentsProps` prop, which will be deprecated in the future.\n *\n * @default {}\n */\n slotProps: PropTypes.shape({\n arrow: PropTypes.object,\n popper: PropTypes.object,\n tooltip: PropTypes.object,\n transition: PropTypes.object\n }),\n /**\n * The components used for each slot inside.\n *\n * This prop is an alias for the `components` prop, which will be deprecated in the future.\n *\n * @default {}\n */\n slots: PropTypes.shape({\n arrow: PropTypes.elementType,\n popper: PropTypes.elementType,\n tooltip: PropTypes.elementType,\n transition: PropTypes.elementType\n }),\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Tooltip title. Zero-length titles string, undefined, null and false are never displayed.\n */\n title: PropTypes.node,\n /**\n * The component used for the transition.\n * [Follow this guide](/material-ui/transitions/#transitioncomponent-prop) to learn more about the requirements for this component.\n * @default Grow\n */\n TransitionComponent: PropTypes.elementType,\n /**\n * Props applied to the transition element.\n * By default, the element is based on this [`Transition`](http://reactcommunity.org/react-transition-group/transition/) component.\n */\n TransitionProps: PropTypes.object\n} : void 0;\nexport default Tooltip;","import '@/components/mui/menu-item.component.css';\nimport ArrowRightIcon from '@mui/icons-material/ArrowRight';\nimport {\n ListItemIcon as MuiListItemIcon,\n ListItemText as MuiListItemText,\n MenuItem as MuiMenuItem,\n} from '@mui/material';\nimport Tooltip from '@mui/material/Tooltip';\nimport { Localized, ReferencedItem, SingleColumnMenu } from 'platform-bible-utils';\nimport { MouseEvent, PropsWithChildren } from 'react';\n\ntype MenuItemInfoBase = {\n /** Text (displayable in the UI) as the name of the menu item */\n label: string;\n /** Text to display when the mouse hovers over the menu item */\n tooltip?: string;\n};\n\nexport type Command = MenuItemInfoBase & {\n /** Command to execute (string.string) */\n command: string;\n};\n\ntype SubMenu = MenuItemInfoBase & {\n /** Command to execute (string.string) */\n items: MenuItemInfo[];\n};\n\nexport interface CommandHandler {\n (command: Command): void;\n}\n\nexport type MenuPropsBase = {\n /*\n * The JSON defining the menu whose items are to be rendered. This will typically be one of the\n * menus in the \"defs\" in a Platform.Bible menu (see PlatformMenus). The schema for this is\n * menuDocumentSchema (at the end of menus.model.ts). Note that while this is a\n * \"SingleColumnMenu\", somewhat bizarrely, a MultiColumnMenu is a SingleColumnMenu, so it really\n * could be a MultiColumnMenu, in which case, column had better be defined so it can be used\n * to filter out the actual groups and items to display on the column.\n */\n menuDefinition: Localized;\n\n commandHandler: CommandHandler;\n\n /**\n * Additional action to perform when any menu item is clicked. Allows the caller to handle event\n * (e.g., to close the menu).\n */\n onClick?: (event: MouseEvent) => void;\n};\n\nexport type MenuItemListProps = MenuPropsBase & {\n /** Optional unique (column) identifier */\n columnId?: ReferencedItem;\n};\n\nexport type MenuItemProps = Omit &\n PropsWithChildren<{\n /** Optional unique identifier */\n id?: string;\n\n onClick: (event: MouseEvent) => void;\n }>;\n\ntype MenuItemInfo = (Command | SubMenu) & {\n /**\n * If specified, menu item will be inset if it does not have a leading icon.\n *\n * @default true\n */\n allowForLeadingIcons?: boolean;\n /**\n * If specified, the path to the icon image to display on the leading side of the menu text.\n *\n * @default undefined (no leading icon will be shown)\n */\n iconPathBefore?: string;\n /**\n * If specified, the path to the icon image to display on the trailing side of the menu text.\n *\n * @default undefined (no trailing icon will be shown)\n */\n iconPathAfter?: string;\n /**\n * If true, list item is focused during the first mount\n *\n * @default false\n */\n hasAutoFocus?: boolean;\n\n /** Additional css classes to help with unique styling of the menu item */\n className?: string;\n\n /**\n * If true, the menu item will appear disabled and it will not respond to clicks or mouse hovers.\n *\n * @default false\n */\n isDisabled?: boolean;\n\n /**\n * If true, compact vertical padding designed for keyboard and mouse input is used.\n *\n * @default true\n */\n isDense?: boolean;\n\n /**\n * If true, a right-arrow icon will be displayed (iconPathAfter, if specified, will be ignored).\n *\n * @default false\n */\n isSubMenuParent?: boolean;\n\n /**\n * If true, the left and right padding is removed\n *\n * @default false\n */\n hasDisabledGutters?: boolean;\n\n /**\n * If true, a 1px light border is added to bottom of menu item\n *\n * @default false\n */\n hasDivider?: boolean;\n\n /** Help identify which element has keyboard focus */\n focusVisibleClassName?: string;\n\n /** If it's a submenu, it should have the items property */\n items?: MenuItemInfo[];\n};\n\nfunction getIcon(icon: string | undefined, menuLabel: string, leading: boolean) {\n return icon ? (\n \n {`${leading\n \n ) : undefined;\n}\n\nexport default function MenuItem(props: MenuItemProps) {\n const {\n onClick,\n label,\n tooltip,\n allowForLeadingIcons = true,\n iconPathBefore = undefined,\n iconPathAfter = undefined,\n hasAutoFocus = false,\n className,\n isDisabled = false,\n isDense = true,\n isSubMenuParent = false,\n hasDisabledGutters = false,\n hasDivider = false,\n focusVisibleClassName,\n id,\n children,\n } = props;\n\n const menuItem = (\n \n {label ? (\n <>\n {getIcon(iconPathBefore, label, true)}\n \n {isSubMenuParent ? (\n \n \n \n ) : (\n getIcon(iconPathAfter, label, false)\n )}\n \n ) : (\n children\n )}\n \n );\n\n return tooltip ? (\n \n
    {menuItem}
    \n
    \n ) : (\n menuItem\n );\n}\n","import MenuItem, {\n MenuItemListProps,\n MenuItemProps,\n MenuPropsBase,\n} from '@/components/mui/menu-item.component';\nimport { Menu } from '@mui/material';\nimport {\n Localized,\n MenuGroupDetailsInSubMenu,\n MenuItemContainingCommand,\n MenuItemContainingSubmenu,\n OrderedExtensibleContainer,\n ReferencedItem,\n SingleColumnMenu,\n} from 'platform-bible-utils';\nimport { MouseEvent, useMemo, useState } from 'react';\n\n/**\n * All the exported types in this file should be regarded as \"internal\" (i.e., they should not be\n * exposed via index.ts).\n */\n\nexport type GroupedMenuPropsBase = MenuPropsBase & {\n /** Optional unique (column) identifier */\n columnId?: ReferencedItem;\n};\n\nexport type GroupedMenuItemListProps = MenuItemListProps & {\n /**\n * If the menuDefinition includes \"top-level\" groups (i.e., those that belong to a column as\n * opposed to those that belong to a submenu) that should not be included in the list, then this\n * array specifies which groups to include. Likewise, for a submenu, this list indicates which\n * groups are pertinent for that submenu. So then for a context menu this property need not be\n * specified since it is a top-level menu based on a \"true\" SingleColumnMenu (i.e., one that is\n * not a MultiColumnMenu).\n */\n includedGroups?: {\n id: string;\n group: Localized;\n }[];\n};\n\ninterface ItemInfo {\n item: Localized;\n isLastItemInGroup: boolean;\n}\n\ntype SubMenuProps = MenuPropsBase & {\n parentMenuItem: Localized;\n parentItemProps: Omit, 'iconPathAfter'>;\n};\n\nfunction getAllGroups(menuDefinition: Localized) {\n const groupEntries = Object.entries(menuDefinition.groups);\n // Convert array of entries to array of objects with id and group properties\n return groupEntries.map(([key, value]) => ({ id: key, group: value }));\n}\n\nfunction SubMenu(props: SubMenuProps) {\n const [anchorEl, setAnchorEl] = useState(undefined);\n\n const { parentMenuItem, parentItemProps, menuDefinition } = props;\n\n const handleParentMenuItemClick = (event: MouseEvent) => {\n setAnchorEl(event.currentTarget);\n };\n\n const handleClose = () => {\n setAnchorEl(undefined);\n };\n\n const renderSubMenuItems = () => {\n let includedGroups = getAllGroups(menuDefinition).filter((g) => 'menuItem' in g.group);\n\n // Ensure valid parent menu was provided. (If not, submenu will contain all groups!)\n if (!parentMenuItem?.id) throw new Error('A valid parent menu item is required for submenus.');\n\n // When laying out a submenu, only include groups associated with the provided parent menu.\n // Note: without the (annoying) redundant check that the included groups\n // have the menuItem field, TS doesn't think it exists.\n includedGroups = includedGroups.filter(\n (group) => 'menuItem' in group.group && group.group.menuItem === parentMenuItem.id,\n );\n\n return ;\n };\n\n return (\n <>\n \n \n {renderSubMenuItems()}\n \n \n );\n}\n\nconst getOrderedGroupItems = (\n groupId: string,\n allItems: Localized[],\n) => {\n // Filter items that belong to the specified group\n const itemsForGroup = allItems.filter((item) => item.group === groupId);\n // Sort items based on order\n const sortedItems = itemsForGroup.sort((a, b) => (a.order || 0) - (b.order || 0));\n return sortedItems;\n};\n\n/**\n * This component is internal; it does not need to be exposed to the outside world since it is not\n * useful on its own. It is used to generate and lay out the MenuItems that appear either on a\n * top-level menu (in a GridMenu or ContextMenu) or in a submenu.\n */\nexport default function GroupedMenuItemList(menuProps: GroupedMenuItemListProps) {\n const { menuDefinition, onClick, commandHandler, includedGroups } = menuProps;\n\n const { items, allowForLeadingIcons } = useMemo(() => {\n const groupsToInclude =\n includedGroups && includedGroups.length > 0\n ? includedGroups\n : // We're apparently laying out a single-column menu (presumably a context menu). In this\n // case, all groups should be included except ones that belong to a submenu.\n getAllGroups(menuDefinition).filter((g) => !('menuItem' in g.group));\n\n const sortedGroups = Object.values(groupsToInclude).sort(\n (a, b) => (a.group.order || 0) - (b.group.order || 0),\n );\n\n const itemArray: ItemInfo[] = [];\n\n sortedGroups.forEach((group) => {\n getOrderedGroupItems(group.id, menuDefinition.items).forEach((item) =>\n itemArray.push({ item, isLastItemInGroup: false }),\n );\n if (itemArray.length > 0) itemArray[itemArray.length - 1].isLastItemInGroup = true;\n });\n\n // No divider after last item in final group.\n if (itemArray.length > 0) itemArray[itemArray.length - 1].isLastItemInGroup = false;\n\n const allowSpaceForLeadingIcons = itemArray.some(\n (i) => 'iconPathBefore' in i.item && i.item.iconPathBefore,\n );\n\n return { items: itemArray, allowForLeadingIcons: allowSpaceForLeadingIcons };\n }, [includedGroups, menuDefinition]);\n\n // Create props for MenuItem component including setting hasDivider for the last item in a group\n const createMenuItemProps = ({ item, isLastItemInGroup }: ItemInfo) => {\n const menuItemProps = {\n className: 'papi-menu-item',\n label: item.label,\n tooltip: item.tooltip,\n iconPathBefore: 'iconPathBefore' in item ? item.iconPathBefore : undefined,\n iconPathAfter: 'iconPathAfter' in item ? item.iconPathAfter : undefined,\n hasDivider: isLastItemInGroup, // Set hasDivider to true for the last item in a group\n allowForLeadingIcons,\n };\n\n return menuItemProps;\n };\n\n const [firstItem] = items;\n\n if (!firstItem) return
    ;\n\n const divKey = firstItem.item.group;\n\n return (\n
    \n {items.map((itemInfo, index) => {\n const { item } = itemInfo;\n const menuItemProps = createMenuItemProps(itemInfo);\n if ('command' in item) {\n const key = item.group + index;\n return (\n ) => {\n onClick?.(event);\n commandHandler(item);\n }}\n {...menuItemProps}\n />\n );\n }\n return (\n \n );\n })}\n
    \n );\n}\n","import GroupedMenuItemList from '@/components/mui/grouped-menu-item-list.component';\nimport { MenuItemListProps } from '@/components/mui/menu-item.component';\nimport { MultiColumnMenu } from 'platform-bible-utils';\n\n/**\n * This component is internal; it does not need to be exposed to the outside world since it is not\n * useful on its own. Use either GridMenu or ContextMenu.\n */\nexport default function TopLevelMenu(props: MenuItemListProps) {\n const { menuDefinition, columnId } = props;\n\n const groupEntries = Object.entries(menuDefinition.groups);\n // Convert array of entries to array of objects with id and group properties\n const groups = groupEntries.map(([key, value]) => ({ id: key, group: value }));\n let includedGroups = groups.filter((g) => 'column' in g.group);\n\n // Check if column is provided and menuDefinition is a MultiColumnMenu\n if (\n columnId &&\n 'columns' in menuDefinition &&\n // Without this type assertion, TS doesn't know what columns is.\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n (menuDefinition as MultiColumnMenu).columns[columnId]\n ) {\n // When laying out a single column in a MultiColumnMenu, only include groups associated with\n // the provided column. Note: without the (annoying) redundant check that the included groups\n // have the colum field, TS doesn't think it exists.\n includedGroups = includedGroups.filter(\n (g) => 'column' in g.group && g.group.column === columnId,\n );\n }\n\n return ;\n}\n","import '@/components/mui/grid-menu.component.css';\nimport { GroupedMenuPropsBase } from '@/components/mui/grouped-menu-item-list.component';\nimport { CommandHandler } from '@/components/mui/menu-item.component';\nimport TopLevelMenu from '@/components/mui/top-level-menu.component';\nimport { Grid, List } from '@mui/material';\nimport {\n Localized,\n MenuColumnWithHeader,\n MultiColumnMenu,\n ReferencedItem,\n} from 'platform-bible-utils';\nimport { useMemo } from 'react';\n\ntype ColumnInfo = {\n /*\n * The ID (`${string}.${string}`) of a specific menu column.\n */\n id: ReferencedItem;\n\n /*\n * Metadata (label, order, etc.) for a specific menu column.\n */\n metadata: Localized;\n};\n\ntype MenuColumnProps = ColumnInfo &\n GroupedMenuPropsBase & {\n /** Additional css classes to help with unique styling of the menu column */\n className?: string;\n };\n\nexport type GridMenuInfo = {\n /** The menu object containing information about the columns, groups, and items to display. */\n multiColumnMenu: Localized;\n};\n\nexport type GridMenuProps = GridMenuInfo & {\n /** Optional unique identifier */\n id?: string;\n\n commandHandler: CommandHandler;\n\n /** Additional css classes to help with unique styling of the grid menu */\n className?: string;\n};\n\nfunction MenuColumn({\n commandHandler,\n menuDefinition,\n id,\n metadata,\n onClick,\n className,\n}: MenuColumnProps) {\n return (\n \n

    \n {metadata.label}\n

    \n {/* It would seem as though this List component were unnecessary, since it only contains one\n thing, but the \"dense\" property does affect the layout of the items (in a way I don't fully\n understand). There might be a better way. */}\n \n \n \n \n );\n}\n\nexport default function GridMenu({\n commandHandler,\n className,\n multiColumnMenu,\n id,\n}: GridMenuProps) {\n const { columns } = multiColumnMenu;\n\n const sortedColumns = useMemo(() => {\n const columnNumbers = new Map();\n Object.getOwnPropertyNames(columns).forEach((columnName: string) => {\n // We know for sure there is a (boolean) property 'isExtensible' that we are not interested in.\n if (columnName === 'isExtensible') return;\n // TS doesn't allow `columnName` above to be a ReferencedItem even though the type says it is\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const columnId = columnName as ReferencedItem;\n const column = columns[columnId];\n // As of right now (and hopefully forever after), all remaining properties of the\n // ColumnsWithHeaders object are columns whose property names are the IDs of the columns.\n // This is an additional (redundant) sanity check. Specifically we're interested in\n // MenuColumnWithHeader objects, which TypeScript now \"knows\" we have, but at runtime all we\n // can check for is that it's an object with a valid numeric order field. That's likely good\n // enough.\n if (\n typeof column === 'object' &&\n typeof column.order === 'number' &&\n !Number.isNaN(column.order)\n )\n columnNumbers.set(column.order, { id: columnId, metadata: column });\n else\n console.warn(\n `Property ${columnName} (${typeof column}) on menu ${id} is not a valid column and is being ignored. This might indicate data corruption`,\n );\n });\n\n // Extract values and sort them based on the 'order' property\n return Array.from(columnNumbers.values()).sort((a, b) => {\n return (a.metadata.order || 0) - (b.metadata.order || 0);\n });\n }, [columns, id]);\n\n // We might need something like this if we need to be able to prevent empty columns\n // sortedColumns.filter((c) => multiColumnMenu.groups.some((g) => 'column' in g && (g as .column)...\n\n return (\n \n {sortedColumns.map((col, index) => (\n \n ))}\n \n );\n}\n","import { useEffect, useRef, useState } from 'react';\n\nexport type UsePromiseOptions = {\n /**\n * Whether to leave the value as the most recent resolved promise value or set it back to\n * defaultValue while running the promise again. Defaults to true\n */\n preserveValue?: boolean;\n};\n\n/** Set up defaults for options for usePromise hook */\nfunction getUsePromiseOptionsDefaults(options: UsePromiseOptions): UsePromiseOptions {\n return {\n preserveValue: true,\n ...options,\n };\n}\n\n/**\n * Awaits a promise and returns a loading value while the promise is unresolved\n *\n * @param promiseFactoryCallback A function that returns the promise to await. If this callback is\n * undefined, the current value will be returned (defaultValue unless it was previously changed\n * and `options.preserveValue` is true), and there will be no loading.\n *\n * WARNING: MUST BE STABLE - const or wrapped in useCallback. The reference must not be updated\n * every render\n * @param defaultValue The initial value to return while first awaiting the promise. If\n * `options.preserveValue` is false, this value is also shown while awaiting the promise on\n * subsequent calls.\n *\n * Note: this parameter is internally assigned to a `ref`, so changing it will not cause any hooks\n * to re-run with its new value. This means that, if the `promiseFactoryCallback` changes and\n * `options.preserveValue` is `false`, the returned value will be set to the current\n * `defaultValue`. However, the returned value will not be updated if`defaultValue` changes.\n * @param options Various options for adjusting how this hook runs the `promiseFactoryCallback`\n *\n * Note: this parameter is internally assigned to a `ref`, so changing it will not cause any hooks\n * to re-run with its new value. However, the latest `options.preserveValue` will always be used\n * appropriately to determine whether to preserve the returned value when changing the\n * `promiseFactoryCallback`\n * @returns `[value, isLoading]`\n *\n * - `value`: the current value for the promise, either the defaultValue or the resolved promise value\n * - `isLoading`: whether the promise is waiting to be resolved\n */\nconst usePromise = (\n promiseFactoryCallback: (() => Promise) | undefined,\n defaultValue: T,\n options: UsePromiseOptions = {},\n): [value: T, isLoading: boolean] => {\n // Use defaultValue as a ref so it doesn't update dependency arrays\n const defaultValueRef = useRef(defaultValue);\n defaultValueRef.current = defaultValue;\n // Use options as a ref so it doesn't update dependency arrays\n const optionsDefaultedRef = useRef(options);\n optionsDefaultedRef.current = getUsePromiseOptionsDefaults(optionsDefaultedRef.current);\n\n const [value, setValue] = useState(() => defaultValueRef.current);\n const [isLoading, setIsLoading] = useState(true);\n useEffect(() => {\n let promiseIsCurrent = true;\n // If a promiseFactoryCallback was provided, we are loading. Otherwise, there is no loading to do\n setIsLoading(!!promiseFactoryCallback);\n (async () => {\n // If there is a callback to run, run it\n if (promiseFactoryCallback) {\n const result = await promiseFactoryCallback();\n // If the promise was not already replaced, update the value\n if (promiseIsCurrent) {\n setValue(() => result);\n setIsLoading(false);\n }\n }\n })();\n\n return () => {\n // Mark this promise as old and not to be used\n promiseIsCurrent = false;\n if (!optionsDefaultedRef.current.preserveValue) setValue(() => defaultValueRef.current);\n };\n }, [promiseFactoryCallback]);\n\n return [value, isLoading];\n};\nexport default usePromise;\n","\"use client\";\n\nimport createSvgIcon from './utils/createSvgIcon';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nexport default createSvgIcon( /*#__PURE__*/_jsx(\"path\", {\n d: \"M3 18h18v-2H3zm0-5h18v-2H3zm0-7v2h18V6z\"\n}), 'Menu');","import GridMenu from '@/components/mui/grid-menu.component';\nimport { Command, CommandHandler } from '@/components/mui/menu-item.component';\nimport usePromise from '@/hooks/use-promise.hook';\nimport { Menu as MenuIcon } from '@mui/icons-material';\nimport { Drawer, IconButton } from '@mui/material';\nimport { Localized, MultiColumnMenu } from 'platform-bible-utils';\nimport {\n MouseEvent,\n MutableRefObject,\n PropsWithChildren,\n useCallback,\n useEffect,\n useState,\n} from 'react';\n\nexport interface MultiColumnMenuProvider {\n (isSupportAndDevelopment: boolean): Promise>;\n}\n\nexport type HamburgerMenuButtonProps = PropsWithChildren & {\n /** The handler to use for menu commands (and eventually toolbar commands). */\n commandHandler: CommandHandler;\n\n /**\n * Optional reference to the \"div\" container that determines the where the menu should appear. If\n * not defined, then (1,1) used.\n */\n containerRef?: MutableRefObject;\n\n /**\n * The delegate to use to get the menu data. If not specified or if it returns undefined, the data\n * in normalMenu or fullMenu property will be used.\n */\n menuProvider?: MultiColumnMenuProvider;\n\n /**\n * The menu data to show when the menu is opened if the menuProvider property is not defined.\n * (This allows for a default or test-only static menu to be used.)\n */\n normalMenu?: Localized;\n\n /**\n * The menu data to show for \"full\" menu (when opened with the SHIFT key pressed) if the\n * menuProvider property is not defined. (This allows for a default or test-only static menu to be\n * used.)\n */\n fullMenu?: Localized;\n\n /** Additional css class(es) to help with unique styling of the sub-components */\n className?: string;\n\n /** Value to use as prefix for ARIA labels on interactive sub-components */\n ariaLabelPrefix?: string;\n};\n\nexport default function HamburgerMenuButton({\n menuProvider,\n normalMenu,\n fullMenu,\n commandHandler,\n containerRef,\n className,\n ariaLabelPrefix,\n children,\n}: HamburgerMenuButtonProps) {\n const [isMenuOpen, setMenuOpen] = useState(false);\n const [showFullMenu, setShowFullMenu] = useState(false);\n\n const handleMenuItemClick = useCallback(() => {\n if (isMenuOpen) setMenuOpen(false);\n setShowFullMenu(false);\n }, [isMenuOpen]);\n\n const handleMenuButtonClick = useCallback((e: MouseEvent) => {\n e.stopPropagation();\n setMenuOpen((prevIsOpen) => {\n const isOpening = !prevIsOpen;\n if (isOpening && e.shiftKey) setShowFullMenu(true);\n else if (!isOpening) setShowFullMenu(false);\n return isOpening;\n });\n }, []);\n\n const menuCommandHandler = useCallback(\n (command: Command) => {\n handleMenuItemClick();\n return commandHandler(command);\n },\n [commandHandler, handleMenuItemClick],\n );\n\n const [offset, setOffset] = useState({ top: 1, left: 1 });\n\n useEffect(() => {\n if (isMenuOpen) {\n const node = containerRef?.current;\n if (node) {\n const rect = node.getBoundingClientRect();\n const scrollTop = window.scrollY;\n const scrollLeft = window.scrollX;\n const top = rect.top + scrollTop + node.clientHeight;\n const left = rect.left + scrollLeft;\n setOffset({ top, left });\n }\n }\n }, [isMenuOpen, containerRef]);\n\n const [normalMenuData] = usePromise(\n useCallback(async () => {\n return menuProvider?.(false) ?? normalMenu;\n // isMenuOpen needs to be included for the menu contents to reevaluate when reopened\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [menuProvider, normalMenu, isMenuOpen]),\n normalMenu,\n );\n\n const [fullMenuData] = usePromise(\n useCallback(async () => {\n return menuProvider?.(true) ?? fullMenu ?? normalMenuData;\n // isMenuOpen needs to be included for the menu contents to reevaluate when reopened\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [menuProvider, fullMenu, normalMenuData, isMenuOpen]),\n fullMenu ?? normalMenuData,\n );\n\n const menu = showFullMenu && fullMenuData ? fullMenuData : normalMenuData;\n\n return (\n <>\n \n {children ?? }\n \n \n {menu ? (\n \n ) : undefined}\n \n \n );\n}\n","import '@/components/mui/icon-button.component.css';\nimport { IconButton as MuiIconButton } from '@mui/material';\nimport { MouseEventHandler, PropsWithChildren } from 'react';\n\nexport type IconButtonProps = PropsWithChildren<{\n /** Optional unique identifier */\n id?: string;\n /**\n * Required. Used as both the tooltip (aka, title) and the aria-label (used for accessibility,\n * testing, etc.), unless a distinct tooltip is supplied.\n */\n label: string;\n /**\n * Enabled status of button\n *\n * @default false\n */\n isDisabled?: boolean;\n /** Optional tooltip to display if different from the aria-label. */\n tooltip?: string;\n /** If true, no tooltip will be displayed. */\n isTooltipSuppressed?: boolean;\n /**\n * If given, uses a negative margin to counteract the padding on one side (this is often helpful\n * for aligning the left or right side of the icon with content above or below, without ruining\n * the border size and shape).\n *\n * @default false\n */\n adjustMarginToAlignToEdge?: 'end' | 'start' | false;\n /**\n * The size of the component. small is equivalent to the dense button styling.\n *\n * @default false\n */\n size: 'small' | 'medium' | 'large';\n /** Additional css classes to help with unique styling of the button */\n className?: string;\n /** Optional click handler */\n onClick?: MouseEventHandler;\n}>;\n\n/**\n * Iconic button a user can click to do something\n *\n * Thanks to MUI for heavy inspiration and documentation\n * https://mui.com/material-ui/getting-started/overview/\n */\nfunction IconButton({\n id,\n label,\n isDisabled = false,\n tooltip,\n isTooltipSuppressed = false,\n adjustMarginToAlignToEdge = false,\n size = 'medium',\n className,\n onClick,\n children,\n}: IconButtonProps) {\n return (\n \n {children /* the icon to display */}\n \n );\n}\n\nexport default IconButton;\n","import { cn } from '@/utils/shadcn-ui.util';\nimport { LoaderCircle, LucideProps } from 'lucide-react';\nimport { forwardRef } from 'react';\n\nexport type SpinnerProps = LucideProps;\n\nconst Spinner = forwardRef(({ className, ...props }, ref) => {\n return (\n \n );\n});\n\nSpinner.displayName = 'Spinner';\n\nexport default Spinner;\n","import { Input as ShadInput } from '@/components/shadcn-ui/input';\nimport { Label as ShadLabel } from '@/components/shadcn-ui/label';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { ChangeEventHandler, FocusEventHandler } from 'react';\n\nexport type TextFieldProps = {\n /** Optional unique identifier */\n id?: string;\n /**\n * If `true`, the component is disabled.\n *\n * @default false\n */\n isDisabled?: boolean;\n /**\n * If `true`, the label is displayed in an error state.\n *\n * @default false\n */\n hasError?: boolean;\n /**\n * If `true`, the input will take up the full width of its container.\n *\n * @default false\n */\n isFullWidth?: boolean;\n /** Text that gives the user instructions on what contents the TextField expects */\n helperText?: string;\n /** The title of the TextField */\n label?: string;\n /** The short hint displayed in the `input` before the user enters a value. */\n placeholder?: string;\n /**\n * If `true`, the label is displayed as required and the `input` element is required.\n *\n * @default false\n */\n isRequired?: boolean;\n /** Additional css classes to help with unique styling of the text field */\n className?: string;\n /** Starting value for the text field if it is not controlled */\n defaultValue?: string | number;\n /** Value of the text field if controlled */\n value?: string | number;\n /** Triggers when content of textfield is changed */\n onChange?: ChangeEventHandler;\n /** Triggers when textfield gets focus */\n onFocus?: FocusEventHandler;\n /** Triggers when textfield loses focus */\n onBlur?: FocusEventHandler;\n};\n\n/**\n * Text input field\n *\n * Thanks to Shadcn for heavy inspiration and documentation\n * https://ui.shadcn.com/docs/components/input#with-label\n */\nfunction TextField({\n id,\n isDisabled = false,\n hasError = false,\n isFullWidth = false,\n helperText,\n label,\n placeholder,\n isRequired = false,\n className,\n defaultValue,\n value,\n onChange,\n onFocus,\n onBlur,\n}: TextFieldProps) {\n return (\n
    \n {`${label}${isRequired ? '*' : ''}`}\n \n

    {helperText}

    \n
    \n );\n}\n\nexport default TextField;\n","import HamburgerMenuButton, {\n MultiColumnMenuProvider,\n} from '@/components/mui/hamburger-menu-button.component';\nimport { CommandHandler } from '@/components/mui/menu-item.component';\nimport '@/components/mui/toolbar.component.css';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { AppBar, Toolbar as MuiToolbar } from '@mui/material';\nimport { PropsWithChildren, useRef } from 'react';\n\nexport type ToolbarProps = PropsWithChildren<{\n /** The handler to use for menu commands (and eventually toolbar commands). */\n commandHandler: CommandHandler;\n\n /**\n * The optional delegate to use to get the menu data. If not specified, the \"hamburger\" menu will\n * not display.\n */\n menuProvider?: MultiColumnMenuProvider;\n\n /** Optional unique identifier */\n id?: string;\n\n /** Additional css classes to help with unique styling of the toolbar */\n className?: string;\n}>;\n\nexport default function Toolbar({\n menuProvider,\n commandHandler,\n className,\n id,\n children,\n}: ToolbarProps) {\n // This ref will always be defined\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const containerRef = useRef(undefined!);\n\n return (\n
    \n \n \n {menuProvider ? (\n \n ) : undefined}\n {children ?
    {children}
    : undefined}\n \n
    \n
    \n );\n}\n","import React from 'react';\nimport { cva, type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst alertVariants = cva(\n 'tw-relative tw-w-full tw-rounded-lg tw-border tw-p-4 [&>svg~*]:tw-pl-7 [&>svg+div]:tw-translate-y-[-3px] [&>svg]:tw-absolute [&>svg]:tw-left-4 [&>svg]:tw-top-4 [&>svg]:tw-text-foreground',\n {\n variants: {\n variant: {\n default: 'tw-bg-background tw-text-foreground',\n destructive:\n 'tw-border-destructive/50 tw-text-destructive dark:tw-border-destructive [&>svg]:tw-text-destructive',\n },\n },\n defaultVariants: {\n variant: 'default',\n },\n },\n);\n\nconst Alert = React.forwardRef<\n HTMLDivElement,\n React.HTMLAttributes & VariantProps\n>(({ className, variant, ...props }, ref) => (\n
    \n));\nAlert.displayName = 'Alert';\n\nconst AlertTitle = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n {/* added because of https://github.com/jsx-eslint/eslint-plugin-jsx-a11y/blob/main/docs/rules/heading-has-content.md */}\n {props.children}{' '}\n \n ),\n);\nAlertTitle.displayName = 'AlertTitle';\n\nconst AlertDescription = React.forwardRef<\n HTMLParagraphElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n
    \n));\nAlertDescription.displayName = 'AlertDescription';\n\nexport { Alert, AlertTitle, AlertDescription };\n","import { ComponentProps } from 'react';\nimport { toast as sonner, Toaster } from 'sonner';\n\ntype SonnerProps = ComponentProps;\n\nfunction Sonner({ ...props }: SonnerProps) {\n return (\n \n );\n}\n\n// The re-export of the sonner function was added manually\nexport { Sonner, sonner };\n","import React from 'react';\nimport * as SliderPrimitive from '@radix-ui/react-slider';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Slider = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n \n \n \n));\nSlider.displayName = SliderPrimitive.Root.displayName;\n\nexport { Slider };\n","import React from 'react';\nimport * as SwitchPrimitives from '@radix-ui/react-switch';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Switch = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n));\nSwitch.displayName = SwitchPrimitives.Root.displayName;\n\nexport { Switch };\n","import React from 'react';\nimport * as TabsPrimitive from '@radix-ui/react-tabs';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport const Tabs = TabsPrimitive.Root;\n\nexport type TabsListProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport type TabsTriggerProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport type TabsContentProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport const TabsList = React.forwardRef<\n React.ElementRef,\n TabsListProps\n>(({ className, ...props }, ref) => (\n \n));\nTabsList.displayName = TabsPrimitive.List.displayName;\n\nexport const TabsTrigger = React.forwardRef<\n React.ElementRef,\n TabsTriggerProps\n>(({ className, ...props }, ref) => (\n \n));\nTabsTrigger.displayName = TabsPrimitive.Trigger.displayName;\n\nexport const TabsContent = React.forwardRef<\n React.ElementRef,\n TabsContentProps\n>(({ className, ...props }, ref) => (\n \n));\nTabsContent.displayName = TabsPrimitive.Content.displayName;\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Download } from 'lucide-react';\n\ntype InstallButtonProps = {\n /** The installing boolean value determines the state of the button. */\n isInstalling: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n /** Optional text for the button. */\n buttonText?: string;\n} & ButtonProps;\n\n/**\n * The InstallButton component is a button designed for initiating installs. It includes visuals for\n * active installing and idle states.\n *\n * @param isInstalling The installing boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @param buttonText Optional text for the button.\n * @returns A install button.\n */\nexport default function InstallButton({\n isInstalling,\n handleClick,\n buttonText,\n className,\n ...props\n}: InstallButtonProps) {\n return (\n \n {isInstalling ? (\n \n ) : (\n <>\n \n {buttonText}\n \n )}\n \n );\n}\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\n\ntype EnableButtonProps = {\n /** The enabling boolean value determines the state of the button. */\n isEnabling: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n} & ButtonProps;\n\n/**\n * The EnableButton component is a button designed for initiating enabling of downloads. It includes\n * visuals for active enabling and idle states.\n *\n * @param isEnabling The enabling boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @returns A button that can be used to enable.\n */\nexport default function EnableButton({\n isEnabling,\n handleClick,\n className,\n ...props\n}: EnableButtonProps) {\n return (\n \n {isEnabling ? (\n <>\n \n Enabling...\n \n ) : (\n 'Enable'\n )}\n \n );\n}\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\n\ntype DisableButtonProps = {\n /** The disabling boolean value determines the state of the button. */\n isDisabling: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n} & ButtonProps;\n\n/**\n * The DisableButton component is a button designed for initiating disabling of downloads. It\n * includes visuals for active disabling and idle states.\n *\n * @param isDisabling The disabling boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @returns A button that can be used to disable.\n */\nexport default function DisableButton({\n isDisabling,\n handleClick,\n className,\n ...props\n}: DisableButtonProps) {\n return (\n \n {isDisabling ? (\n <>\n \n Disabling...\n \n ) : (\n 'Disable'\n )}\n \n );\n}\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\n\ntype UpdateButtonProps = {\n /** The updating boolean value determines the state of the button. */\n isUpdating: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n} & ButtonProps;\n\n/**\n * The UpdateButton component is a button designed for initiating updates for downloaded extensions.\n * It includes visuals for active updating and idle states.\n *\n * @param isUpdating The updating boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @returns A button that can be used to update.\n */\nexport default function UpdateButton({\n isUpdating,\n handleClick,\n className,\n ...props\n}: UpdateButtonProps) {\n return (\n \n {isUpdating ? (\n <>\n \n Updating...\n \n ) : (\n 'Update'\n )}\n \n );\n}\n","import { cn } from '@/utils/shadcn-ui.util';\nimport Markdown, { MarkdownToJSX } from 'markdown-to-jsx';\nimport { useMemo } from 'react';\n\ninterface MarkdownRendererProps {\n /** Optional unique identifier */\n id?: string;\n /** The markdown string to render */\n markdown: string;\n className?: string;\n /**\n * The [`target` attribute for `a` html\n * tags](https://developer.mozilla.org/en-US/docs/Web/HTML/Element/a#target). Defaults to not\n * adding a `target` to `a` tags\n */\n anchorTarget?: string;\n}\n\n/**\n * This component renders markdown content given a markdown string. It uses typography styles from\n * the platform.\n *\n * @param markdown The markdown string to render.\n * @param id Optional unique identifier\n * @returns A div containing the rendered markdown content.\n */\nexport default function MarkdownRenderer({\n id,\n markdown,\n className,\n anchorTarget,\n}: MarkdownRendererProps) {\n const options: MarkdownToJSX.Options = useMemo(\n () => ({\n overrides: {\n a: {\n props: {\n target: anchorTarget,\n },\n },\n },\n }),\n [anchorTarget],\n );\n return (\n
    \n {markdown}\n
    \n );\n}\n","import { Filter, ChevronDown } from 'lucide-react';\nimport { forwardRef } from 'react';\nimport { Button } from '@/components/shadcn-ui/button';\n\n/**\n * The FilterButton component is a button designed for initiating filtering of data. It is designed\n * to be used with the dropdown menu. It uses forwardRef to pass the button to the dropdown trigger\n * asChild.\n *\n * @returns A button that can be used to filter.\n */\nconst FilterButton = forwardRef((props, ref) => {\n return (\n \n \n Filter\n \n \n );\n});\n\nexport default FilterButton;\n","import {\n DropdownMenu,\n DropdownMenuTrigger,\n DropdownMenuContent,\n DropdownMenuLabel,\n DropdownMenuGroup,\n DropdownMenuCheckboxItem,\n DropdownMenuRadioItem,\n DropdownMenuSeparator,\n} from '@/components/shadcn-ui/dropdown-menu';\nimport FilterButton from './buttons/filter-button.component';\n\nexport enum DropdownMenuItemType {\n Check,\n Radio,\n}\n\nexport type DropdownItem = {\n /** The label is the text that will be displayed on the dropdown item. */\n label: string;\n /** The itemType determines the DropdownMenuItemType type as either Check or Radio. */\n itemType: DropdownMenuItemType;\n /** The onClick function is called when the item is clicked. */\n onClick: () => void;\n};\n\nexport type DropdownGroup = {\n /**\n * The label is the text that will be displayed on the dropdown group. It is used to categorize\n * the items in the group.\n */\n label: string;\n /** The items array contains the items that will be displayed in the dropdown group */\n items: DropdownItem[];\n};\n\nexport type FilterDropdownProps = {\n /** Object unique identifier */\n id?: string;\n /** The groups array contains the groups that will be displayed in the dropdown */\n groups: DropdownGroup[];\n}; // TODO: extend the props later\n\n/**\n * The FilterDropdown component is a dropdown designed for filtering content. It includes groups of\n * items that can be checkboxes or radio items.\n *\n * @param id Optional unique identifier\n * @param groups The groups array contains the groups that will be displayed in the dropdown\n * @returns A filter dropdown.\n */\nexport default function FilterDropdown({ id, groups }: FilterDropdownProps) {\n return (\n
    \n {/* TODO: remove this once the DropDown Menu shadcn has an id prop */}\n \n \n \n \n \n {groups.map((group) => (\n
    \n {group.label}\n \n {group.items.map((item) => (\n
    \n {item.itemType === DropdownMenuItemType.Check ? (\n \n {item.label}\n \n ) : (\n \n {item.label}\n \n )}\n
    \n ))}\n
    \n \n
    \n ))}\n
    \n
    \n
    \n );\n}\n","interface NoExtensionsFoundProps {\n /** Optional unique identifier */\n id?: string;\n /** The message to display */\n message: string;\n}\n/**\n * This component displays a message to the user when no extensions are found in the marketplace.\n *\n * @param id Optional unique identifier\n * @param message The message to display.\n * @returns {JSX.Element} - Returns the message component that displays the message to the user.\n */\nexport default function NoExtensionsFound({ id, message }: NoExtensionsFoundProps) {\n return (\n
    \n
    \n

    {message}

    \n
    \n
    \n );\n}\n","import { CircleHelp, Link as LucideLink, User } from 'lucide-react';\nimport { NumberFormat } from 'platform-bible-utils';\n\n/** Interface that stores the parameters passed to the More Info component */\ninterface MoreInfoProps {\n /** Optional unique identifier */\n id?: string;\n /** The category of the extension */\n category: string;\n /** The number of downloads for the extension */\n downloads: Record;\n /** The languages supported by the extension */\n languages: string[];\n /** The URL to the more info page of the extension */\n moreInfoUrl: string;\n}\n/**\n * This component displays the more info section of the extension which includes the category,\n * number of downloads, languages, and links to the website and support\n *\n * @param id Optional unique identifier\n * @param category The category of the extension\n * @param downloads The number of downloads for the extension\n * @param languages The languages supported by the extension\n * @param moreInfoUrl The URL to the more info page of the extension\n * @returns {JSX.Element} - Returns the more info component that displays the category, number of\n * downloads, languages, and links to the website and support\n */\nexport default function MoreInfo({\n id,\n category,\n downloads,\n languages,\n moreInfoUrl,\n}: MoreInfoProps) {\n /**\n * This constant formats the number of downloads into a more readable format.\n *\n * @example 1000 -> 1K\n *\n * @example 1000000 -> 1M\n *\n * @returns The formatted number of downloads\n */\n const numberFormatted = new NumberFormat('en', {\n notation: 'compact',\n compactDisplay: 'short',\n }).format(Object.values(downloads).reduce((a: number, b: number) => a + b, 0));\n\n /** This function scrolls the window to the bottom of the page. */\n const handleScrollToBottom = () => {\n window.scrollTo(0, document.body.scrollHeight);\n };\n\n return (\n \n
    \n
    \n {category}\n
    \n CATEGORY\n
    \n
    \n
    \n
    \n \n {numberFormatted}\n
    \n USERS\n
    \n
    \n
    \n
    \n {languages.slice(0, 3).map((locale) => (\n \n {locale.toUpperCase()}\n \n ))}\n
    \n {languages.length > 3 && (\n handleScrollToBottom()}\n className=\"tw-text-xs tw-text-gray-500 tw-underline\"\n >\n +{languages.length - 3} more languages\n \n )}\n
    \n
    \n
    \n \n Website\n \n \n \n Support\n \n \n
    \n
    \n );\n}\n","import { useState } from 'react';\n\nexport type VersionInformation = {\n /** Date the version was published */\n date: string;\n /** Description of the changes in the version */\n description: string;\n};\n\n/** Type to store the version history information */\nexport type VersionHistoryType = Record;\n\n/** Interface that stores the parameters passed to the Version History component */\ninterface VersionHistoryProps {\n /** Optional unique identifier */\n id?: string;\n /** Object containing the versions mapped with their information */\n versionHistory: VersionHistoryType;\n}\n\n/**\n * Component to render the version history information shown in the footer component. Lists the 5\n * most recent versions, with the options to show all versions by pressing a button.\n *\n * @param versionHistory Object containing the versions mapped with their information\n * @param id Optional unique identifier\n * @returns Rendered version history for the Footer component\n */\nexport default function VersionHistory({ id, versionHistory }: VersionHistoryProps) {\n const [showAllVersions, setShowAllVersions] = useState(false);\n const currentDate = new Date();\n\n /**\n * Function to format the time string for the version history in the form of 'X year(s) ago'.\n *\n * @param dateString ISO Date string to determine the time string from\n * @returns Formatted time string\n */\n function formatTimeString(dateString: string) {\n const date = new Date(dateString);\n const dateDiff = new Date(currentDate.getTime() - date.getTime());\n const yearDiff = dateDiff.getUTCFullYear() - 1970;\n const monthDiff = dateDiff.getUTCMonth();\n const dayDiff = dateDiff.getUTCDate() - 1;\n\n // Determines how long ago the version was published\n let timeString = '';\n if (yearDiff > 0) {\n timeString = `${yearDiff.toString()} year${yearDiff === 1 ? '' : 's'} ago`;\n } else if (monthDiff > 0) {\n timeString = `${monthDiff.toString()} month${monthDiff === 1 ? '' : 's'} ago`;\n } else if (dayDiff === 0) {\n timeString = 'today';\n } else {\n timeString = `${dayDiff.toString()} day${dayDiff === 1 ? '' : 's'} ago`;\n }\n\n return timeString;\n }\n\n // Sorts the version history by version number\n const sortedEntries = Object.entries(versionHistory).sort((a, b) => b[0].localeCompare(a[0]));\n\n return (\n
    \n

    What`s New

    \n
      \n {(showAllVersions ? sortedEntries : sortedEntries.slice(0, 5)).map((entry) => (\n
      \n
      \n
    • \n {entry[1].description}\n
    • \n
      \n
      \n
      Version {entry[0]}
      \n
      {formatTimeString(entry[1].date)}
      \n
      \n
      \n ))}\n
    \n {sortedEntries.length > 5 && (\n setShowAllVersions(!showAllVersions)}\n className=\"tw-text-xs tw-text-gray-500 tw-underline\"\n >\n {showAllVersions ? 'Show Less Version History' : 'Show All Version History'}\n \n )}\n
    \n );\n}\n","import { useMemo } from 'react';\nimport { formatBytes } from 'platform-bible-utils';\nimport VersionHistory, { VersionHistoryType } from './version-history.component';\n\n/** Interface to store the parameters passed to the Footer component */\ninterface FooterProps {\n /** Optional unique identifier */\n id?: string;\n /** Name of the publisher */\n publisherDisplayName: string;\n /** Size of the extension file in bytes */\n fileSize: number;\n /** List of language codes supported by the extension */\n locales: string[];\n /** Object containing the version history mapped with their information */\n versionHistory: VersionHistoryType;\n}\n\n/**\n * Component to render the footer for the extension details which contains information on the\n * publisher, version history, languages, and file size.\n *\n * @param id Optional unique identifier\n * @param publisherDisplayName Name of the publisher\n * @param fileSize Size of the extension file in bytes\n * @param locales List of language codes supported by the extension\n * @param versionHistory Object containing the version history mapped with their information\n * @returns The rendered Footer component\n */\nexport default function Footer({\n id,\n publisherDisplayName,\n fileSize,\n locales,\n versionHistory,\n}: FooterProps) {\n /** Formats the file size into a human-readable format */\n const formattedFileSize = useMemo(() => formatBytes(fileSize), [fileSize]);\n\n /**\n * This function gets the display names of the languages based on the language codes.\n *\n * @param codes The list of language codes\n * @returns The list of language names\n */\n const getLanguageNames = (codes: string[]) => {\n const displayNames = new Intl.DisplayNames(navigator.language, { type: 'language' });\n return codes.map((code) => displayNames.of(code));\n };\n\n const languageNames = getLanguageNames(locales);\n\n return (\n
    \n
    \n \n
    \n
    \n

    Information

    \n
    \n

    \n Publisher\n {publisherDisplayName}\n Size\n {formattedFileSize}\n

    \n
    \n

    \n Languages\n {languageNames.join(', ')}\n

    \n
    \n
    \n
    \n
    \n
    \n );\n}\n","import { PlatformEvent, PlatformEventHandler } from 'platform-bible-utils';\nimport { useEffect } from 'react';\n\n/**\n * Adds an event handler to an event so the event handler runs when the event is emitted. Use\n * `papi.network.getNetworkEvent` to use a networked event with this hook.\n *\n * @param event The event to subscribe to.\n *\n * - If event is a `PlatformEvent`, that event will be used\n * - If event is undefined, the callback will not be subscribed. Useful if the event is not yet\n * available for example\n *\n * @param eventHandler The callback to run when the event is emitted\n *\n * WARNING: MUST BE STABLE - const or wrapped in useCallback. The reference must not be updated\n * every render\n */\nconst useEvent = (\n event: PlatformEvent | undefined,\n eventHandler: PlatformEventHandler,\n) => {\n useEffect(() => {\n // Do nothing if the event is not provided (in case the event is not yet available, for example)\n if (!event) return () => {};\n\n const unsubscriber = event(eventHandler);\n return () => {\n unsubscriber();\n };\n }, [event, eventHandler]);\n};\nexport default useEvent;\n","import { useCallback, useEffect } from 'react';\nimport { PlatformEvent, PlatformEventAsync, PlatformEventHandler } from 'platform-bible-utils';\nimport usePromise from './use-promise.hook';\n\nconst noopUnsubscriber = () => false;\n\n/**\n * Adds an event handler to an asynchronously subscribing/unsubscribing event so the event handler\n * runs when the event is emitted. Use `papi.network.getNetworkEvent` to use a networked event with\n * this hook.\n *\n * @param event The asynchronously (un)subscribing event to subscribe to.\n *\n * - If event is a `PlatformEvent` or `PlatformEventAsync`, that event will be used\n * - If event is undefined, the callback will not be subscribed. Useful if the event is not yet\n * available for example\n *\n * @param eventHandler The callback to run when the event is emitted\n *\n * WARNING: MUST BE STABLE - const or wrapped in useCallback. The reference must not be updated\n * every render\n */\nconst useEventAsync = (\n event: PlatformEvent | PlatformEventAsync | undefined,\n eventHandler: PlatformEventHandler,\n) => {\n // Subscribe to the event asynchronously\n const [unsubscribe] = usePromise(\n useCallback(async () => {\n // Do nothing if the event is not provided (in case the event is not yet available, for example)\n if (!event) return noopUnsubscriber;\n\n // Wrap subscribe and unsubscribe in promises to allow normal events to be used as well\n const unsub = await Promise.resolve(event(eventHandler));\n return async () => unsub();\n }, [eventHandler, event]),\n noopUnsubscriber,\n // We want the unsubscriber to return to default value immediately upon changing subscription\n // So the useEffect below will unsubscribe asap\n { preserveValue: false },\n );\n\n // Unsubscribe from the event asynchronously (but we aren't awaiting the unsub)\n useEffect(() => {\n return () => {\n if (unsubscribe !== noopUnsubscriber) {\n unsubscribe();\n }\n };\n }, [unsubscribe]);\n};\n\nexport default useEventAsync;\n"],"names":["twMergeCustom","extendTailwindMerge","cn","inputs","clsx","Input","React","className","type","props","ref","jsx","BookChapterInput","forwardRef","handleSearch","handleKeyDown","handleOnClick","handleSubmit","jsxs","ShadInput","event","e","History","P","R","t","s","n","N","B","O","S","K","g","k","x","T","X","V","w","L","G","A","H","C","I","y","q","U","m","l","h","c","E","D","i","a","o","u","v","f","d","b","p","J","DropdownMenu","DropdownMenuPrimitive","DropdownMenuTrigger","DropdownMenuGroup","DropdownMenuPortal","DropdownMenuSub","DropdownMenuRadioGroup","DropdownMenuSubTrigger","inset","children","ChevronRight","DropdownMenuSubContent","DropdownMenuContent","sideOffset","DropdownMenuItem","DropdownMenuCheckboxItem","checked","Check","DropdownMenuRadioItem","Circle","DropdownMenuLabel","DropdownMenuSeparator","DropdownMenuShortcut","BookMenuItem","bookId","handleSelectBook","isSelected","handleHighlightBook","bookType","ShadDropdownMenuItem","Canon","ChapterSelect","handleSelectChapter","endChapter","activeChapter","highlightedChapter","handleHighlightedChapter","chapters","_","handleMouse","useCallback","chapterNumber","chapter","GoToMenuItem","handleSort","handleLocationHistory","handleBookmarks","ShadDropdownMenuLabel","ArrowDownWideNarrow","Clock","Bookmark","ALL_BOOK_IDS","BOOK_TYPE_LABELS","BOOK_TYPE_ARRAY","SCROLL_OFFSET","SEARCH_QUERY_FORMATS","fetchGroupedBooks","fetchEndChapter","getChaptersForBook","getAllEnglishNames","isValidBookEnglishName","bookName","getBookIdFromEnglishName","formattedBookName","BookChapterControl","scrRef","searchQuery","setSearchQuery","useState","selectedBookId","setSelectedBookId","setHighlightedChapter","highlightedBookId","setHighlightedBookId","isContentOpen","setIsContentOpen","isContentOpenDelayed","setIsContentOpenDelayed","inputRef","useRef","contentRef","menuItemRef","fetchFilteredBooks","englishNameLowerCase","normalizedQuery","handleSearchInput","searchString","shouldPreventAutoClosing","controlMenuState","open","updateReference","shouldClose","verse","handleInputSubmit","format","matches","book","englishName","handleKeyDownInput","handleKeyDownContent","key","handleKeyDownMenuItem","chapterOffSet","useEffect","useLayoutEffect","scrollTimeout","scrollPosition","ShadDropdownMenu","ShadDropdownMenuTrigger","ShadDropdownMenuContent","bookTypeIndex","element","ShadDropdownMenuSeparator","buttonVariants","cva","Button","variant","size","asChild","Comp","Slot","labelVariants","Label","LabelPrimitive","RadioGroup","RadioGroupPrimitive","RadioGroupItem","Popover","PopoverPrimitive","PopoverTrigger","PopoverContent","align","DialogPortal","DialogPrimitive","DialogOverlay","DialogContent","DialogTitle","DialogDescription","Command","CommandPrimitive","CommandInput","Search","CommandList","CommandEmpty","CommandGroup","CommandSeparator","CommandItem","getOptionLabelDefault","option","ComboBox","id","options","buttonClassName","popoverContentClassName","value","onChange","getOptionLabel","buttonPlaceholder","textPlaceholder","commandEmptyMessage","buttonVariant","dir","isDisabled","setOpen","ChevronsUpDown","ChapterRangeSelector","startChapter","handleSelectStartChapter","handleSelectEndChapter","chapterCount","chapterOptions","useMemo","index","onChangeStartChapter","onChangeEndChapter","Fragment","BookSelectionMode","BOOK_SELECTOR_STRING_KEYS","localizeString","strings","BookSelector","handleBookSelectionModeChange","currentBookName","onSelectBooks","selectedBookIds","localizedStrings","currentBookText","chooseText","chooseBooksText","bookSelectionMode","setBookSelectionMode","onSelectionModeChange","newMode","DataTableViewOptions","table","FilterIcon","column","Select","SelectPrimitive","SelectGroup","SelectValue","SelectTrigger","ChevronDown","SelectScrollUpButton","ChevronUp","SelectScrollDownButton","SelectContent","position","SelectLabel","SelectItem","SelectSeparator","DataTablePagination","pageSize","ArrowLeftIcon","ChevronLeftIcon","ChevronRightIcon","ArrowRightIcon","Table","stickyHeader","TableHeader","TableBody","TableFooter","TableRow","TableHead","TableCell","TableCaption","DataTable","columns","data","enablePagination","showPaginationControls","showColumnVisibilityControls","onRowClickHandler","sorting","setSorting","columnFilters","setColumnFilters","columnVisibility","setColumnVisibility","rowSelection","setRowSelection","useReactTable","getCoreRowModel","getPaginationRowModel","getSortedRowModel","getFilteredRowModel","headerGroup","header","flexRender","_a","row","cell","OccurrencesTable","occurrenceData","setScriptureReference","referenceHeaderText","occurrenceHeaderText","occurrences","uniqueOccurrences","occurrence","uniqueOccurrence","deepEqual","Checkbox","CheckboxPrimitive","getLinesFromUSFM","text","getNumberFromUSFM","regex","match","getBookNumFromId","getStatusForItem","item","approvedItems","unapprovedItems","toggleVariants","Toggle","TogglePrimitive","ToggleGroupContext","ToggleGroup","ToggleGroupPrimitive","ToggleGroupItem","context","getSortingIcon","sortDirection","ArrowUpIcon","ArrowDownIcon","ArrowUpDownIcon","inventoryItemColumn","itemLabel","inventoryAdditionalItemColumn","additionalItemLabel","additionalItemIndex","inventoryCountColumn","countLabel","statusChangeHandler","changedItems","newStatus","onApprovedItemsChange","onUnapprovedItemsChange","newApprovedItems","validItem","newUnapprovedItems","unapprovedItem","inventoryStatusColumn","statusLabel","status","CircleCheckIcon","CircleXIcon","CircleHelpIcon","INVENTORY_STRING_KEYS","filterItemData","itemData","statusFilter","textFilter","filteredItemData","createTableData","scriptureRef","itemRegex","tableData","currentBook","currentChapter","currentVerse","line","items","itemIndex","existingItem","tableEntry","newReference","substring","newItem","Inventory","scriptureReference","extractItems","additionalItemsLabels","scope","onScopeChange","allItemsText","approvedItemsText","unapprovedItemsText","unknownItemsText","scopeBookText","scopeChapterText","scopeVerseText","filterText","showAdditionalItemsText","showAdditionalItems","setShowAdditionalItems","setStatusFilter","setTextFilter","selectedItem","setSelectedItem","reducedTableData","newTableData","firstItem","existingEntry","newTableEntry","filteredTableData","allColumns","numberOfAdditionalItems","additionalColumns","_b","rowClickHandler","newSelection","handleScopeChange","handleStatusFilterChange","SearchBar","onSearch","placeholder","isFullWidth","handleInputChange","VerticalTabs","TabsPrimitive","VerticalTabsList","VerticalTabsTrigger","VerticalTabsContent","TabNavigationContentSearch","tabList","searchPlaceholder","headerTitle","isSearchBarFullWidth","direction","tab","Separator","orientation","decorative","SeparatorPrimitive","Sheet","SheetPrimitive","SheetPortal","SheetOverlay","sheetVariants","SheetContent","side","SheetTitle","SheetDescription","Skeleton","TooltipProvider","TooltipPrimitive","Tooltip","TooltipTrigger","TooltipContent","MOBILE_BREAKPOINT","useIsMobile","isMobile","setIsMobile","mql","SIDEBAR_COOKIE_NAME","SIDEBAR_COOKIE_MAX_AGE","SIDEBAR_WIDTH","SIDEBAR_WIDTH_MOBILE","SIDEBAR_WIDTH_ICON","SIDEBAR_KEYBOARD_SHORTCUT","SidebarContext","useSidebar","SidebarProvider","defaultOpen","openProp","setOpenProp","style","openMobile","setOpenMobile","_open","_setOpen","isOpen","openState","toggleSidebar","state","contextValue","Sidebar","collapsible","SidebarTrigger","onClick","PanelLeft","SidebarRail","SidebarInset","SidebarInput","SidebarHeader","SidebarFooter","SidebarSeparator","SidebarContent","SidebarGroup","SidebarGroupLabel","SidebarGroupAction","SidebarGroupContent","SidebarMenu","SidebarMenuItem","sidebarMenuButtonVariants","SidebarMenuButton","isActive","tooltip","button","SidebarMenuAction","showOnHover","SidebarMenuBadge","SidebarMenuSkeleton","showIcon","width","SidebarMenuSub","SidebarMenuSubItem","SidebarMenuSubButton","SettingsSidebar","extensionLabels","projectOptions","handleSelectSidebarItem","selectedSidebarItem","handleSelectItem","projectId","getProjectNameFromProjectId","project","label","selectedProjectName","SettingsSidebarContentSearch","scrBookColId","scrRefColId","typeColId","detailsColId","defaultScrRefColumnName","defaultScrBookGroupName","defaultTypeColumnName","defaultDetailsColumnName","getColumns","colInfo","showSourceColumn","showSrcCol","info","formatScrRef","compareScrRefs","toRefOrRange","scriptureSelection","offsetStart","offsetEnd","scrRefToBBBCCCVVV","getRowKey","ScriptureResultsViewer","sources","showColumnHeaders","scriptureReferenceColumnName","scriptureBookGroupName","typeColumnName","detailsColumnName","onRowSelected","grouping","setGrouping","scriptureResults","source","getExpandedRowModel","getGroupedRowModel","selectedRows","keys","selectedRow","scrBookGroupName","typeGroupName","groupingOptions","handleSelectChange","selectedGrouping","handleRowClick","getEvenOrOddBandingStyle","getIndent","groupingState","rowIndex","ChevronLeft","DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS","getLocalizeKeyForScrollGroupId","ScrollGroupSelector","availableScrollGroupIds","scrollGroupId","onChangeScrollGroupId","localizedStringsDefaulted","localizedStringKey","localizedStringValue","newScrollGroupString","scrollGroupOptionId","SettingsList","SettingsListItem","primary","secondary","isLoading","loadingMessage","SettingsListHeader","includeSeparator","Card","CardHeader","CardTitle","CardDescription","CardContent","CardFooter","SettingsCard","settingsGroupLabel","settingsGroupDescription","Checklist","listItems","selectedListItems","handleSelectListItem","createLabel","_interopRequireDefault","obj","module","chainPropTypes","propType1","propType2","args","_extends","target","isPlainObject","prototype","deepClone","output","deepmerge","r","z","reactIs_production_min","hasSymbol","REACT_ELEMENT_TYPE","REACT_PORTAL_TYPE","REACT_FRAGMENT_TYPE","REACT_STRICT_MODE_TYPE","REACT_PROFILER_TYPE","REACT_PROVIDER_TYPE","REACT_CONTEXT_TYPE","REACT_ASYNC_MODE_TYPE","REACT_CONCURRENT_MODE_TYPE","REACT_FORWARD_REF_TYPE","REACT_SUSPENSE_TYPE","REACT_SUSPENSE_LIST_TYPE","REACT_MEMO_TYPE","REACT_LAZY_TYPE","REACT_BLOCK_TYPE","REACT_FUNDAMENTAL_TYPE","REACT_RESPONDER_TYPE","REACT_SCOPE_TYPE","isValidElementType","typeOf","object","$$typeof","$$typeofType","AsyncMode","ConcurrentMode","ContextConsumer","ContextProvider","Element","ForwardRef","Lazy","Memo","Portal","Profiler","StrictMode","Suspense","hasWarnedAboutDeprecatedIsAsyncMode","isAsyncMode","isConcurrentMode","isContextConsumer","isContextProvider","isElement","isForwardRef","isFragment","isLazy","isMemo","isPortal","isProfiler","isStrictMode","isSuspense","reactIs_development","reactIsModule","require$$0","require$$1","getOwnPropertySymbols","hasOwnProperty","propIsEnumerable","toObject","val","shouldUseNative","test1","test2","order2","test3","letter","objectAssign","from","to","symbols","ReactPropTypesSecret","ReactPropTypesSecret_1","has","printWarning","loggedTypeFailures","message","checkPropTypes","typeSpecs","values","location","componentName","getStack","typeSpecName","error","err","ex","stack","checkPropTypes_1","ReactIs","assign","require$$2","require$$3","require$$4","emptyFunctionThatReturnsNull","factoryWithTypeCheckers","isValidElement","throwOnDirectAccess","ITERATOR_SYMBOL","FAUX_ITERATOR_SYMBOL","getIteratorFn","maybeIterable","iteratorFn","ANONYMOUS","ReactPropTypes","createPrimitiveTypeChecker","createAnyTypeChecker","createArrayOfTypeChecker","createElementTypeChecker","createElementTypeTypeChecker","createInstanceTypeChecker","createNodeChecker","createObjectOfTypeChecker","createEnumTypeChecker","createUnionTypeChecker","createShapeTypeChecker","createStrictShapeTypeChecker","is","PropTypeError","createChainableTypeChecker","validate","manualPropTypeCallCache","manualPropTypeWarningCount","checkType","isRequired","propName","propFullName","secret","cacheKey","chainedCheckType","expectedType","propValue","propType","getPropType","preciseType","getPreciseType","typeChecker","expectedClass","expectedClassName","actualClassName","getClassName","expectedValues","valuesString","arrayOfTypeCheckers","checker","getPostfixForTypeWarning","expectedTypes","checkerResult","expectedTypesMessage","isNode","invalidValidatorError","shapeTypes","allKeys","iterator","step","entry","isSymbol","emptyFunction","emptyFunctionWithReset","factoryWithThrowingShims","shim","getShim","propTypesModule","isClassComponent","elementType","acceptingRef","safePropName","warningHint","elementAcceptingRef","PropTypes","elementAcceptingRef$1","specialProperty","exactProp","propTypes","unsupportedProps","prop","formatMuiErrorMessage","code","url","REACT_SERVER_CONTEXT_TYPE","REACT_OFFSCREEN_TYPE","enableScopeAPI","enableCacheElement","enableTransitionTracing","enableLegacyHidden","enableDebugTracing","REACT_MODULE_REFERENCE","SuspenseList","hasWarnedAboutDeprecatedIsConcurrentMode","isSuspenseList","fnNameMatchRegex","getFunctionName","fn","getFunctionComponentName","Component","fallback","getWrappedName","outerType","innerType","wrapperName","functionName","getDisplayName","HTMLElementType","refType","refType$1","capitalize","string","_formatMuiErrorMessage","createChainedFunction","funcs","acc","func","debounce","wait","timeout","debounced","later","deprecatedPropType","validator","reason","componentNameSafe","propFullNameSafe","isMuiElement","muiNames","_muiName","_element$type","ownerDocument","node","ownerWindow","requirePropFactory","componentNameInError","prevPropTypes","requiredProp","defaultTypeChecker","typeCheckerResult","setRef","useEnhancedEffect","useEnhancedEffect$1","globalId","useGlobalId","idOverride","defaultId","setDefaultId","maybeReactUseId","useId","reactId","unsupportedProp","useControlled","controlled","defaultProp","name","isControlled","valueState","setValue","defaultValue","setValueIfUncontrolled","newValue","useEventCallback","useForkRef","refs","instance","UNINITIALIZED","useLazyRef","init","initArg","EMPTY","useOnMount","Timeout","delay","useTimeout","hadKeyboardEvent","hadFocusVisibleRecently","hadFocusVisibleRecentlyTimeout","inputTypesWhitelist","focusTriggersKeyboardModality","tagName","handlePointerDown","handleVisibilityChange","prepare","doc","isFocusVisible","useIsFocusVisible","isFocusVisibleRef","handleBlurVisible","handleFocusVisible","resolveProps","defaultProps","defaultSlotProps","slotProps","slotPropName","composeClasses","slots","getUtilityClass","classes","slot","utilityClass","defaultGenerator","createClassNameGenerator","generate","generator","ClassNameGenerator","ClassNameGenerator$1","globalStateClasses","generateUtilityClass","globalStatePrefix","globalStateClass","generateUtilityClasses","result","clamp","min","max","_objectWithoutPropertiesLoose","excluded","sourceKeys","_excluded","sortBreakpointsValues","breakpointsAsArray","breakpoint1","breakpoint2","createBreakpoints","breakpoints","unit","other","sortedValues","up","down","between","start","end","endIndex","only","not","keyIndex","shape","shape$1","responsivePropType","responsivePropType$1","merge","defaultBreakpoints","handleBreakpoints","styleFromPropValue","theme","themeBreakpoints","breakpoint","mediaKey","cssKey","createEmptyBreakpointObject","breakpointsInput","_breakpointsInput$key","breakpointStyleKey","removeUnusedBreakpoints","breakpointKeys","breakpointOutput","getPath","path","checkVars","getStyleValue","themeMapping","transform","propValueFinal","userValue","cssProperty","themeKey","memoize","cache","arg","properties","directions","aliases","getCssProperties","property","marginKeys","paddingKeys","spacingKeys","createUnaryUnit","_getPath","themeSpacing","abs","createUnarySpacing","getValue","transformer","transformed","getStyleFromPropValue","cssProperties","resolveCssProperty","margin","padding","createSpacing","spacingInput","spacing","argsInput","argument","compose","styles","handlers","borderTransform","createBorderStyle","border","borderTop","borderRight","borderBottom","borderLeft","borderColor","borderTopColor","borderRightColor","borderBottomColor","borderLeftColor","outline","outlineColor","borderRadius","gap","columnGap","rowGap","gridColumn","gridRow","gridAutoFlow","gridAutoColumns","gridAutoRows","gridTemplateColumns","gridTemplateRows","gridTemplateAreas","gridArea","paletteTransform","color","bgcolor","backgroundColor","sizingTransform","maxWidth","_props$theme","_props$theme2","breakpointsValues","minWidth","height","maxHeight","minHeight","boxSizing","defaultSxConfig","defaultSxConfig$1","objectsHaveSameKeys","objects","union","callIfFn","maybeFn","unstable_createStyleFunctionSx","getThemeValue","config","styleFunctionSx","_theme$unstable_sxCon","sx","traverse","sxInput","sxObject","emptyBreakpoints","breakpointsKeys","css","styleKey","styleFunctionSx$1","applyStyles","createTheme","paletteInput","shapeInput","muiTheme","isObjectEmpty","useTheme","defaultTheme","contextTheme","ThemeContext","systemDefaultTheme","useThemeWithoutDefault","_excluded2","_excluded3","isEmpty","isStringTag","tag","shouldForwardProp","lowercaseFirstLetter","resolveTheme","themeId","defaultOverridesResolver","processStyleArg","callableStyle","_ref","ownerState","resolvedStylesArg","resolvedStyle","variants","isMatch","createStyled","input","rootShouldForwardProp","slotShouldForwardProp","systemSx","inputOptions","processStyles","componentSlot","inputSkipVariantsResolver","inputSkipSx","overridesResolver","skipVariantsResolver","skipSx","shouldForwardPropOption","defaultStyledResolver","styledEngineStyled","transformStyleArg","stylesArg","muiStyledResolver","styleArg","expressions","transformedStyleArg","expressionsWithDefaultTheme","styleOverrides","resolvedStyleOverrides","slotKey","slotStyle","_theme$components","themeVariants","numOfCustomFnsApplied","placeholders","displayName","getThemeProps","params","useThemeProps","clampWrapper","hexToRgb","re","colors","decomposeColor","marker","colorSpace","recomposeColor","hslToRgb","rgb","getLuminance","getContrastRatio","foreground","background","lumA","lumB","alpha","darken","coefficient","lighten","createMixins","mixins","common","common$1","grey","grey$1","purple","purple$1","red","red$1","orange","orange$1","blue","blue$1","lightBlue","lightBlue$1","green","green$1","light","dark","addLightOrDark","intent","shade","tonalOffset","tonalOffsetLight","tonalOffsetDark","getDefaultPrimary","mode","getDefaultSecondary","getDefaultError","getDefaultInfo","getDefaultSuccess","getDefaultWarning","createPalette","palette","contrastThreshold","success","warning","getContrastText","contrastText","contrast","augmentColor","mainShade","lightShade","darkShade","modes","round","caseAllCaps","defaultFontFamily","createTypography","typography","fontFamily","fontSize","fontWeightLight","fontWeightRegular","fontWeightMedium","fontWeightBold","htmlFontSize","allVariants","pxToRem2","coef","pxToRem","buildVariant","fontWeight","lineHeight","letterSpacing","casing","shadowKeyUmbraOpacity","shadowKeyPenumbraOpacity","shadowAmbientShadowOpacity","createShadow","px","shadows","shadows$1","easing","duration","formatMs","milliseconds","getAutoHeightDuration","constant","createTransitions","inputTransitions","mergedEasing","mergedDuration","durationOption","easingOption","isString","isNumber","animatedProp","zIndex","zIndex$1","mixinsInput","transitionsInput","typographyInput","systemTheme","systemCreateTheme","stateClasses","component","child","stateClass","defaultTheme$1","THEME_ID","systemUseThemeProps","styled","styled$1","getSvgIconUtilityClass","useUtilityClasses","SvgIconRoot","_theme$transitions","_theme$transitions$cr","_theme$transitions2","_theme$typography","_theme$typography$pxT","_theme$typography2","_theme$typography2$px","_theme$typography3","_theme$typography3$px","_palette$ownerState$c","_palette","_palette2","_palette3","SvgIcon","inProps","htmlColor","inheritViewBox","titleAccess","viewBox","hasSvgAsChild","more","_jsxs","_jsx","SvgIcon$1","createSvgIcon","unstable_ClassNameGenerator","exports","_utils","ArrowRight","default_1","_createSvgIcon","_jsxRuntime","isHostComponent","appendOwnerState","otherProps","defaultContextValue","ClassNameConfiguratorContext","useClassNamesOverride","disableDefaultClasses","extractEventHandlers","excludeKeys","resolveComponentProps","componentProps","slotState","omitEventHandlers","mergeSlotProps","parameters","getSlotProps","additionalProps","externalSlotProps","externalForwardedProps","joinedClasses","mergedStyle","eventHandlers","componentsPropsWithoutEventHandlers","otherPropsWithoutEventHandlers","internalSlotProps","useSlotProps","_parameters$additiona","skipResolvingSlotProps","rest","resolvedComponentsProps","mergedProps","internalRef","GLOBAL_CLASS_PREFIX","buildStateClass","buildSlotClass","getContainer","container","forwardedRef","disablePortal","mountNode","setMountNode","handleRef","newProps","ReactDOM","top","bottom","right","left","auto","basePlacements","clippingParents","viewport","popper","reference","variationPlacements","placement","placements","beforeRead","read","afterRead","beforeMain","main","afterMain","beforeWrite","write","afterWrite","modifierPhases","getNodeName","getWindow","OwnElement","isHTMLElement","isShadowRoot","attributes","effect","_ref2","initialStyles","styleProperties","attribute","applyStyles$1","getBasePlacement","getUAString","uaData","isLayoutViewport","getBoundingClientRect","includeScale","isFixedStrategy","clientRect","scaleX","scaleY","visualViewport","addVisualOffsets","getLayoutRect","contains","parent","rootNode","next","getComputedStyle","isTableElement","getDocumentElement","getParentNode","getTrueOffsetParent","getContainingBlock","isFirefox","isIE","elementCss","currentNode","getOffsetParent","window","offsetParent","getMainAxisFromPlacement","within","mathMax","mathMin","withinMaxClamp","getFreshSideObject","mergePaddingObject","paddingObject","expandToHashMap","hashMap","toPaddingObject","arrow","_state$modifiersData$","arrowElement","popperOffsets","basePlacement","axis","isVertical","len","arrowRect","minProp","maxProp","endDiff","startDiff","arrowOffsetParent","clientSize","centerToReference","center","offset","axisProp","_options$element","arrow$1","getVariation","unsetSides","roundOffsetsByDPR","win","dpr","mapToStyles","_Object$assign2","popperRect","variation","offsets","gpuAcceleration","adaptive","roundOffsets","isFixed","_offsets$x","_offsets$y","_ref3","hasX","hasY","sideX","sideY","heightProp","widthProp","offsetY","offsetX","commonStyles","_ref4","_Object$assign","computeStyles","_ref5","_options$gpuAccelerat","_options$adaptive","_options$roundOffsets","computeStyles$1","passive","_options$scroll","scroll","_options$resize","resize","scrollParents","scrollParent","eventListeners","hash","getOppositePlacement","matched","getOppositeVariationPlacement","getWindowScroll","scrollLeft","scrollTop","getWindowScrollBarX","getViewportRect","strategy","html","layoutViewport","getDocumentRect","_element$ownerDocumen","winScroll","body","isScrollParent","_getComputedStyle","overflow","overflowX","overflowY","getScrollParent","listScrollParents","list","isBody","updatedList","rectToClientRect","rect","getInnerBoundingClientRect","getClientRectFromMixedType","clippingParent","getClippingParents","canEscapeClipping","clipperElement","getClippingRect","boundary","rootBoundary","mainClippingParents","firstClippingParent","clippingRect","accRect","computeOffsets","commonX","commonY","mainAxis","detectOverflow","_options","_options$placement","_options$strategy","_options$boundary","_options$rootBoundary","_options$elementConte","elementContext","_options$altBoundary","altBoundary","_options$padding","altContext","clippingClientRect","referenceClientRect","popperClientRect","elementClientRect","overflowOffsets","offsetData","multiply","computeAutoPlacement","flipVariations","_options$allowedAutoP","allowedAutoPlacements","allPlacements","allowedPlacements","overflows","getExpandedFallbackPlacements","oppositePlacement","flip","_options$mainAxis","checkMainAxis","_options$altAxis","checkAltAxis","specifiedFallbackPlacements","_options$flipVariatio","preferredPlacement","isBasePlacement","fallbackPlacements","referenceRect","checksMap","makeFallbackChecks","firstFittingPlacement","_basePlacement","isStartVariation","mainVariationSide","altVariationSide","checks","check","numberOfChecks","_loop","_i","fittingPlacement","_ret","flip$1","getSideOffsets","preventedOffsets","isAnySideFullyClipped","hide","referenceOverflow","popperAltOverflow","referenceClippingOffsets","popperEscapeOffsets","isReferenceHidden","hasPopperEscaped","hide$1","distanceAndSkiddingToXY","rects","invertDistance","skidding","distance","_options$offset","_data$state$placement","offset$1","popperOffsets$1","getAltAxis","preventOverflow","_options$tether","tether","_options$tetherOffset","tetherOffset","altAxis","tetherOffsetValue","normalizedTetherOffsetValue","offsetModifierState","_offsetModifierState$","mainSide","altSide","additive","minLen","maxLen","arrowPaddingObject","arrowPaddingMin","arrowPaddingMax","arrowLen","minOffset","maxOffset","clientOffset","offsetModifierValue","tetherMin","tetherMax","preventedOffset","_offsetModifierState$2","_mainSide","_altSide","_offset","_len","_min","_max","isOriginSide","_offsetModifierValue","_tetherMin","_tetherMax","_preventedOffset","preventOverflow$1","getHTMLElementScroll","getNodeScroll","isElementScaled","getCompositeRect","elementOrVirtualElement","isOffsetParentAnElement","offsetParentIsScaled","documentElement","order","modifiers","map","visited","modifier","sort","requires","dep","depModifier","orderModifiers","orderedModifiers","phase","pending","resolve","mergeByName","merged","current","existing","DEFAULT_OPTIONS","areValidElements","_key","popperGenerator","generatorOptions","_generatorOptions","_generatorOptions$def","defaultModifiers","_generatorOptions$def2","defaultOptions","effectCleanupFns","isDestroyed","setOptionsAction","cleanupModifierEffects","runModifierEffects","_state$elements","_state$orderedModifie","_state$orderedModifie2","_ref$options","cleanupFn","noopFn","createPopper","COMPONENT_NAME","getPopperUtilityClass","flipPlacement","resolveAnchorEl","anchorEl","isVirtualElement","defaultPopperOptions","PopperTooltip","_slots$root","initialPlacement","popperOptions","popperRefProp","TransitionProps","tooltipRef","ownRef","popperRef","handlePopperRef","handlePopperRefRef","rtlPlacement","setPlacement","resolvedAnchorElement","setResolvedAnchorElement","handlePopperUpdate","box","popperModifiers","childProps","Root","rootProps","Popper","containerProp","keepMounted","transition","exited","setExited","handleEnter","handleExited","resolvedAnchorEl","display","transitionProps","useThemeSystem","_setPrototypeOf","_inheritsLoose","subClass","superClass","setPrototypeOf","timeoutsShape","TransitionGroupContext","forceReflow","UNMOUNTED","EXITED","ENTERING","ENTERED","EXITING","Transition","_React$Component","_this","parentGroup","appear","initialStatus","prevState","nextIn","_proto","prevProps","nextStatus","exit","enter","mounting","_this2","appearing","maybeNode","maybeAppearing","timeouts","enterTimeout","_this3","nextState","callback","_this4","active","handler","doesNotHaveTimeoutOrListener","maybeNextCallback","_this$props","pt","noop","Transition$1","reflow","getTransitionProps","_style$transitionDura","_style$transitionTimi","getScale","isWebKit154","Grow","addEndListener","inProp","onEnter","onEntered","onEntering","onExit","onExited","onExiting","TransitionComponent","timer","autoTimeout","nodeRef","normalizedTransitionCallback","maybeIsAppearing","handleEntering","isAppearing","transitionDuration","transitionTimingFunction","handleEntered","handleExiting","handleExit","handleAddEndListener","Grow$1","PopperRoot","BasePopper","components","componentsProps","RootComponent","Popper$1","getTooltipUtilityClass","tooltipClasses","tooltipClasses$1","disableInteractive","touch","TooltipPopper","TooltipTooltip","TooltipArrow","hystersisOpen","hystersisTimer","cursorPosition","composeEventHandler","eventHandler","_slots$popper","_slots$transition","_slots$tooltip","_slots$arrow","_slotProps$popper","_ref6","_slotProps$popper2","_slotProps$transition","_slotProps$tooltip","_ref7","_slotProps$tooltip2","_slotProps$arrow","_ref8","_slotProps$arrow2","childrenProp","describeChild","disableFocusListener","disableHoverListener","disableInteractiveProp","disableTouchListener","enterDelay","enterNextDelay","enterTouchDelay","followCursor","idProp","leaveDelay","leaveTouchDelay","onClose","onOpen","PopperComponentProp","PopperProps","title","TransitionComponentProp","isRtl","childNode","setChildNode","arrowRef","setArrowRef","ignoreNonTouchEvents","closeTimer","enterTimer","leaveTimer","touchTimer","setOpenState","prevUserSelect","stopTouchInteraction","handleOpen","handleClose","handleLeave","focusVisibleRef","setChildIsFocusVisible","handleBlur","handleFocus","detectTouchStart","childrenProps","handleMouseOver","handleMouseLeave","handleTouchStart","handleTouchEnd","nativeEvent","handleMouseMove","nameOrDescProps","titleIsString","interactiveWrapperListeners","_PopperProps$popperOp","tooltipModifiers","PopperComponent","TooltipComponent","ArrowComponent","popperProps","tooltipProps","tooltipArrowProps","TransitionPropsInner","Tooltip$1","getIcon","icon","menuLabel","leading","MuiListItemIcon","MenuItem","allowForLeadingIcons","iconPathBefore","iconPathAfter","hasAutoFocus","isDense","isSubMenuParent","hasDisabledGutters","hasDivider","focusVisibleClassName","menuItem","MuiMenuItem","MuiListItemText","getAllGroups","menuDefinition","SubMenu","setAnchorEl","parentMenuItem","parentItemProps","handleParentMenuItemClick","renderSubMenuItems","includedGroups","group","GroupedMenuItemList","Menu","getOrderedGroupItems","groupId","allItems","menuProps","commandHandler","groupsToInclude","sortedGroups","itemArray","allowSpaceForLeadingIcons","createMenuItemProps","isLastItemInGroup","divKey","itemInfo","menuItemProps","TopLevelMenu","columnId","MenuColumn","metadata","Grid","List","GridMenu","multiColumnMenu","sortedColumns","columnNumbers","columnName","col","getUsePromiseOptionsDefaults","usePromise","promiseFactoryCallback","defaultValueRef","optionsDefaultedRef","setIsLoading","promiseIsCurrent","MenuIcon","HamburgerMenuButton","menuProvider","normalMenu","fullMenu","containerRef","ariaLabelPrefix","isMenuOpen","setMenuOpen","showFullMenu","setShowFullMenu","handleMenuItemClick","handleMenuButtonClick","prevIsOpen","isOpening","menuCommandHandler","command","setOffset","normalMenuData","fullMenuData","menu","IconButton","Drawer","isTooltipSuppressed","adjustMarginToAlignToEdge","MuiIconButton","Spinner","LoaderCircle","TextField","hasError","helperText","onFocus","onBlur","ShadLabel","Toolbar","AppBar","MuiToolbar","alertVariants","Alert","AlertTitle","AlertDescription","Sonner","Toaster","Slider","SliderPrimitive","Switch","SwitchPrimitives","Tabs","TabsList","TabsTrigger","TabsContent","InstallButton","isInstalling","handleClick","buttonText","Download","EnableButton","isEnabling","DisableButton","isDisabling","UpdateButton","isUpdating","MarkdownRenderer","markdown","anchorTarget","Markdown","FilterButton","Filter","DropdownMenuItemType","DropdownMenuItemType2","FilterDropdown","groups","NoExtensionsFound","MoreInfo","category","downloads","languages","moreInfoUrl","numberFormatted","NumberFormat","handleScrollToBottom","User","locale","LucideLink","CircleHelp","VersionHistory","versionHistory","showAllVersions","setShowAllVersions","currentDate","formatTimeString","dateString","date","dateDiff","yearDiff","monthDiff","dayDiff","timeString","sortedEntries","Footer","publisherDisplayName","fileSize","locales","formattedFileSize","formatBytes","languageNames","codes","displayNames","useEvent","unsubscriber","noopUnsubscriber","useEventAsync","unsubscribe","unsub"],"mappings":"28CAGA,MAAMA,GAAgBC,GAAAA,oBAAoB,CAAE,OAAQ,KAAO,CAAA,EAyDpD,SAASC,KAAMC,EAAsB,CACnC,OAAAH,GAAcI,GAAAA,KAAKD,CAAM,CAAC,CACnC,CCzDO,MAAME,GAAQC,EAAM,WACzB,CAAC,CAAE,UAAAC,EAAW,KAAAC,EAAM,GAAGC,CAAA,EAASC,IAE5BC,EAAA,IAAC,QAAA,CACC,KAAAH,EACA,UAAWN,EACT,sbACAK,CACF,EACA,IAAAG,EAEC,GAAGD,CAAA,CAAA,CAIZ,EACAJ,GAAM,YAAc,QCNpB,MAAMO,GAAmBC,EAAA,WACvB,CACE,CAAE,aAAAC,EAAc,cAAAC,EAAe,cAAAC,EAAe,aAAAC,EAAc,GAAGR,CAAM,EACrEC,IAGEQ,EAAA,KAAC,MAAI,CAAA,UAAU,cACb,SAAA,CAAAP,EAAA,IAACQ,GAAA,CACE,GAAGV,EACJ,KAAK,OACL,UAAU,0JACV,SAAWW,GAAUN,EAAaM,EAAM,OAAO,KAAK,EACpD,UAAYC,GAAM,CACZA,EAAE,MAAQ,SACCJ,IAEfF,EAAcM,CAAC,CACjB,EACA,QAASL,EACT,IAAAN,CAAA,CACF,EACAC,EAAA,IAACW,EAAA,QAAA,CACC,UAAU,8HACV,QAAS,IAAM,CAEb,QAAQ,IAAI,iBAAiB,CAC/B,CAAA,CACF,CACF,CAAA,CAAA,CAGN,EC9CA,IAAIC,GAAI,OAAO,eACXC,GAAI,CAACC,EAAGJ,EAAGK,IAAML,KAAKI,EAAIF,GAAEE,EAAGJ,EAAG,CAAE,WAAY,GAAI,aAAc,GAAI,SAAU,GAAI,MAAOK,CAAC,CAAE,EAAID,EAAEJ,CAAC,EAAIK,EACzGC,GAAI,CAACF,EAAGJ,EAAGK,IAAMF,GAAEC,EAAG,OAAOJ,GAAK,SAAWA,EAAI,GAAKA,EAAGK,CAAC,EAW9D,MAAME,GAAI,CACR,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MAEA,MAEA,MAEA,MAEA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,MAEA,MAEA,MAEA,MAEA,MACA,MACA,MACA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,KACF,EAAGC,GAAI,CACL,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,KACF,EAAGC,GAAI,CACL,UACA,SACA,YACA,UACA,cACA,SACA,SACA,OACA,WACA,WACA,UACA,UACA,eACA,eACA,OACA,WACA,kBACA,MACA,SACA,WACA,eACA,gBACA,SACA,WACA,eACA,UACA,kBACA,QACA,OACA,OACA,UACA,QACA,QACA,QACA,WACA,YACA,SACA,YACA,UACA,UACA,OACA,OACA,OACA,OACA,SACA,gBACA,gBACA,YACA,YACA,cACA,aACA,kBACA,kBACA,YACA,YACA,QACA,WACA,UACA,QACA,UACA,UACA,SACA,SACA,SACA,OACA,aACA,QACA,SACA,eACA,oBACA,0BACA,SACA,qBACA,sBACA,UACA,qBACA,cACA,cACA,cACA,cACA,mBACA,mBACA,qBACA,YACA,OACA,oBAGA,uBACA,uBACA,sBACA,yBACA,wBACA,qBACA,UACA,UACA,UACA,UACA,UACA,UACA,UACA,eACA,cACA,eACA,oBACA,qBACA,0BACA,0BACA,eACA,eACA,YACA,gBACA,cACA,eACA,iBACA,wBACA,mBACA,WACA,QACA,aACA,aACA,aACA,2BACA,4BACA,YACF,EAAGC,GAAIC,KACP,SAASC,GAAER,EAAGJ,EAAI,GAAI,CACpB,OAAOA,IAAMI,EAAIA,EAAE,YAAa,GAAGA,KAAKM,GAAIA,GAAEN,CAAC,EAAI,CACrD,CACA,SAASS,GAAET,EAAG,CACZ,OAAOQ,GAAER,CAAC,EAAI,CAChB,CACA,SAASU,GAAEV,EAAG,CACZ,MAAMJ,EAAI,OAAOI,GAAK,SAAWQ,GAAER,CAAC,EAAIA,EACxC,OAAOJ,GAAK,IAAMA,GAAK,EACzB,CACA,SAASe,GAAEX,EAAG,CACZ,OAAQ,OAAOA,GAAK,SAAWQ,GAAER,CAAC,EAAIA,IAAM,EAC9C,CACA,SAASY,GAAEZ,EAAG,CACZ,OAAOA,GAAK,EACd,CACA,SAASa,GAAEb,EAAG,CACZ,MAAMJ,EAAI,OAAOI,GAAK,SAAWQ,GAAER,CAAC,EAAIA,EACxC,OAAOc,GAAElB,CAAC,GAAK,CAACgB,GAAEhB,CAAC,CACrB,CACA,SAAUmB,IAAI,CACZ,QAASf,EAAI,EAAGA,GAAKG,GAAE,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;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","x_google_ignoreList":[3,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,83,84,85,86,87,88,89,90,91,92,93,94,95,96,97,98,99,100,101,102,103,104,105,106,107,108,109,110,111,112,113,114,115,116,117,118,119,120,121,122,123,124,125,126,127,128,129,130,131,132,133,134,135,136,137,138,139,140,141,142,143,144,145,146,147,148,149,150,151,152,153,154,155,156,157,158,159,160,161,162,163,164,165,166,167,168,169,170,171,172,173,174,175,176,177,178,179,180,181,182,183,184,185,186,187,188,189,190,191,192,193,194,195,196,197,198,199,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,230]} \ No newline at end of file diff --git a/lib/platform-bible-react/dist/index.d.ts b/lib/platform-bible-react/dist/index.d.ts index 7f379c0577..def11c4f2c 100644 --- a/lib/platform-bible-react/dist/index.d.ts +++ b/lib/platform-bible-react/dist/index.d.ts @@ -432,22 +432,34 @@ export type TabNavigationContentSearchProps = { direction?: "ltr" | "rtl"; }; declare function TabNavigationContentSearch({ tabList, onSearch, searchPlaceholder, headerTitle, isSearchBarFullWidth, direction, }: TabNavigationContentSearchProps): import("react/jsx-runtime").JSX.Element; +export type SelectedSettingsSidebarItem = { + label: string; + projectId?: string; +}; +export type ProjectOptions = { + projectId: string; + projectName: string; +}; export type SettingsSidebarProps = { - /** Optional id */ + /** Optional id for testing */ id?: string; - /** Extension labels to list in sidebar */ + /** Extension labels from contribution */ extensionLabels: string[]; - /** Project labels to list in sidebar */ - handleSelectSidebarItem: (key: string, isProjectSetting: boolean) => void; -}; -export function SettingsSidebar({ id, extensionLabels, handleSelectSidebarItem, }: SettingsSidebarProps): import("react/jsx-runtime").JSX.Element; -export type SettingsSidebarContentSearchProps = { + /** Project names and ids */ + projectOptions: ProjectOptions[]; + /** Handler for selecting a sidebar item */ + handleSelectSidebarItem: (key: string, projectId?: string) => void; + /** The current selected value in the sidebar */ + selectedSidebarItem: SelectedSettingsSidebarItem | undefined; +}; +export function SettingsSidebar({ id, extensionLabels, projectOptions, handleSelectSidebarItem, selectedSidebarItem, }: SettingsSidebarProps): import("react/jsx-runtime").JSX.Element; +export type SettingsSidebarContentSearchProps = SettingsSidebarProps & React$1.PropsWithChildren & { + /** Optional id for testing */ + id?: string; /** Text direction ltr or rtl */ direction?: "ltr" | "rtl"; - extensionLabels: string[]; - handleSelectSidebarItem: (key: string, isProjectSetting: boolean) => void; -} & React$1.PropsWithChildren; -export function SettingsSidebarContentSearch({ direction, extensionLabels, children, handleSelectSidebarItem, }: SettingsSidebarContentSearchProps): import("react/jsx-runtime").JSX.Element; +}; +export function SettingsSidebarContentSearch({ id, direction, extensionLabels, projectOptions, children, handleSelectSidebarItem, selectedSidebarItem, }: SettingsSidebarContentSearchProps): import("react/jsx-runtime").JSX.Element; /** * Information (e.g., a checking error or some other type of "transient" annotation) about something * noteworthy at a specific place in an instance of the Scriptures. @@ -639,10 +651,14 @@ export type SettingsListHeaderProps = { */ export declare function SettingsListHeader({ primary, secondary, includeSeparator, }: SettingsListHeaderProps): import("react/jsx-runtime").JSX.Element; export type SettingsCardProps = React$1.PropsWithChildren & { + /** Optional id for testing */ + id?: string; + /** Label of the settings group */ settingsGroupLabel: string; - settingsGroupDescription: string; + /** Optional description of the settings group */ + settingsGroupDescription?: string; }; -export function SettingsCard({ settingsGroupLabel, settingsGroupDescription, children, }: SettingsCardProps): import("react/jsx-runtime").JSX.Element; +export function SettingsCard({ id, settingsGroupLabel, settingsGroupDescription, children, }: SettingsCardProps): import("react/jsx-runtime").JSX.Element; export type ChecklistProps = { /** Optional string representing the id attribute of the Checklist */ id?: string; @@ -687,8 +703,10 @@ export type ComboBoxProps = { /** Text label title for combobox */ /** List of available options for the dropdown menu */ options?: readonly T[]; - /** Additional css classes to help with unique styling of the combo box */ - className?: string; + /** Additional css classes to help with unique styling of the combo box button */ + buttonClassName?: string; + /** Additional css classes to help with unique styling of the combo box popover */ + popoverContentClassName?: string; /** * The selected value that the combo box currently holds. Must be shallow equal to one of the * options entries. @@ -718,7 +736,7 @@ export type Direction = "ltr" | "rtl"; * Thanks to Shadcn for heavy inspiration and documentation * https://ui.shadcn.com/docs/components/combobox */ -export declare function ComboBox({ id, options, className, value, onChange, getOptionLabel, buttonPlaceholder, textPlaceholder, commandEmptyMessage, buttonVariant, dir, isDisabled, ...props }: ComboBoxProps): import("react/jsx-runtime").JSX.Element; +export declare function ComboBox({ id, options, buttonClassName, popoverContentClassName, value, onChange, getOptionLabel, buttonPlaceholder, textPlaceholder, commandEmptyMessage, buttonVariant, dir, isDisabled, ...props }: ComboBoxProps): import("react/jsx-runtime").JSX.Element; export type MenuItemInfoBase = { /** Text (displayable in the UI) as the name of the menu item */ label: string; diff --git a/lib/platform-bible-react/dist/index.js b/lib/platform-bible-react/dist/index.js index c901aa810b..5e55e5c7b7 100644 --- a/lib/platform-bible-react/dist/index.js +++ b/lib/platform-bible-react/dist/index.js @@ -1,28 +1,28 @@ import Qs, { jsx as s, jsxs as x, Fragment as ie } from "react/jsx-runtime"; import * as M from "react"; -import T, { forwardRef as Qn, useCallback as Bt, useState as ut, useRef as ge, useEffect as ae, useLayoutEffect as Ko, useMemo as $t } from "react"; -import { History as tl, ChevronRight as Wa, Check as tr, Circle as qa, ArrowDownWideNarrow as el, Clock as nl, Bookmark as rl, X as Ka, Search as ol, ChevronsUpDown as al, FilterIcon as il, ChevronDown as er, ChevronUp as sl, ArrowLeftIcon as ll, ChevronLeftIcon as cl, ChevronRightIcon as dl, ArrowRightIcon as pl, CircleCheckIcon as ul, CircleXIcon as wl, CircleHelpIcon as fl, ArrowUpIcon as ml, ArrowDownIcon as hl, ArrowUpDownIcon as gl, PanelLeft as bl, ChevronLeft as vl, LoaderCircle as yl, Download as xl, Filter as Nl, User as kl, Link as El, CircleHelp as Sl } from "lucide-react"; +import T, { forwardRef as Qn, useCallback as Tt, useState as ut, useRef as ge, useEffect as ae, useLayoutEffect as ta, useMemo as At } from "react"; +import { History as tl, ChevronRight as Ja, Check as tr, Circle as Za, ArrowDownWideNarrow as el, Clock as nl, Bookmark as rl, X as Qa, Search as ol, ChevronsUpDown as al, FilterIcon as il, ChevronDown as er, ChevronUp as sl, ArrowLeftIcon as ll, ChevronLeftIcon as cl, ChevronRightIcon as dl, ArrowRightIcon as pl, CircleCheckIcon as ul, CircleXIcon as wl, CircleHelpIcon as fl, ArrowUpIcon as ml, ArrowDownIcon as hl, ArrowUpDownIcon as gl, PanelLeft as bl, ChevronLeft as vl, LoaderCircle as yl, Download as xl, Filter as Nl, User as kl, Link as El, CircleHelp as Sl } from "lucide-react"; import be, { clsx as Tl } from "clsx"; import { extendTailwindMerge as Cl } from "tailwind-merge"; import * as wt from "@radix-ui/react-dropdown-menu"; import { DropdownMenuTrigger as Ol } from "@radix-ui/react-dropdown-menu"; -import { getChaptersForBook as Rl, deepEqual as ao, substring as _l, formatScrRef as Or, compareScrRefs as Hr, scrRefToBBBCCCVVV as Rr, getLocalizeKeyForScrollGroupId as pt, NumberFormat as Pl, formatBytes as $l } from "platform-bible-utils"; +import { getChaptersForBook as Rl, deepEqual as co, substring as _l, formatScrRef as Or, compareScrRefs as Hr, scrRefToBBBCCCVVV as Rr, getLocalizeKeyForScrollGroupId as pt, NumberFormat as Pl, formatBytes as $l } from "platform-bible-utils"; import { Slot as He } from "@radix-ui/react-slot"; import { cva as Xe } from "class-variance-authority"; -import * as Ja from "@radix-ui/react-label"; +import * as ti from "@radix-ui/react-label"; import * as mn from "@radix-ui/react-radio-group"; import * as hn from "@radix-ui/react-popover"; -import { Command as Ot } from "cmdk"; +import { Command as Rt } from "cmdk"; import * as vt from "@radix-ui/react-dialog"; -import { useReactTable as Za, getCoreRowModel as Qa, getPaginationRowModel as Il, getSortedRowModel as ti, getFilteredRowModel as Al, flexRender as dn, getExpandedRowModel as Ml, getGroupedRowModel as Dl } from "@tanstack/react-table"; +import { useReactTable as ei, getCoreRowModel as ni, getPaginationRowModel as Al, getSortedRowModel as ri, getFilteredRowModel as Il, flexRender as dn, getExpandedRowModel as Ml, getGroupedRowModel as Dl } from "@tanstack/react-table"; import * as bt from "@radix-ui/react-select"; import * as Xr from "@radix-ui/react-checkbox"; import * as nr from "@radix-ui/react-toggle-group"; -import * as ei from "@radix-ui/react-toggle"; -import * as Rt from "@radix-ui/react-tabs"; -import * as ni from "@radix-ui/react-separator"; +import * as oi from "@radix-ui/react-toggle"; +import * as _t from "@radix-ui/react-tabs"; +import * as ai from "@radix-ui/react-separator"; import * as En from "@radix-ui/react-tooltip"; -import { CardContent as Bl, MenuItem as jl, ListItemText as Vl, ListItemIcon as ri, Menu as zl, Grid as oi, List as Ll, IconButton as ai, Drawer as Fl, AppBar as Ul, Toolbar as Gl } from "@mui/material"; +import { CardContent as Bl, MenuItem as jl, ListItemText as Vl, ListItemIcon as ii, Menu as zl, Grid as si, List as Ll, IconButton as li, Drawer as Fl, AppBar as Ul, Toolbar as Gl } from "@mui/material"; import Hl, { ThemeContext as Xl, internal_processStyles as Yl } from "@mui/styled-engine"; import * as Wl from "react-dom"; import Bn from "react-dom"; @@ -223,7 +223,7 @@ const ye = [ "REP", "4BA", "LAO" -], io = [ +], po = [ "XXA", "XXB", "XXC", @@ -239,7 +239,7 @@ const ye = [ "GLO", "TDX", "NDX" -], ii = [ +], ci = [ "Genesis", "Exodus", "Leviticus", @@ -365,11 +365,11 @@ const ye = [ "Reproof (Proverbs 25-31)", "4 Baruch (Rest of Baruch)", "Laodiceans" -], Jo = dc(); +], ea = dc(); function We(t, e = !0) { - return e && (t = t.toUpperCase()), t in Jo ? Jo[t] : 0; + return e && (t = t.toUpperCase()), t in ea ? ea[t] : 0; } -function so(t) { +function uo(t) { return We(t) > 0; } function ec(t) { @@ -379,41 +379,41 @@ function ec(t) { function nc(t) { return (typeof t == "string" ? We(t) : t) <= 39; } -function si(t) { +function di(t) { return t <= 66; } function rc(t) { const e = typeof t == "string" ? We(t) : t; - return di(e) && !si(e); + return wi(e) && !di(e); } function* oc() { for (let t = 1; t <= ye.length; t++) yield t; } -const ac = 1, li = ye.length; +const ac = 1, pi = ye.length; function ic() { return ["XXA", "XXB", "XXC", "XXD", "XXE", "XXF", "XXG"]; } -function lo(t, e = "***") { +function wo(t, e = "***") { const n = t - 1; return n < 0 || n >= ye.length ? e : ye[n]; } -function ci(t) { - return t <= 0 || t > li ? "******" : ii[t - 1]; +function ui(t) { + return t <= 0 || t > pi ? "******" : ci[t - 1]; } function sc(t) { - return ci(We(t)); + return ui(We(t)); } -function di(t) { - const e = typeof t == "number" ? lo(t) : t; - return so(e) && !io.includes(e); +function wi(t) { + const e = typeof t == "number" ? wo(t) : t; + return uo(e) && !po.includes(e); } function lc(t) { - const e = typeof t == "number" ? lo(t) : t; - return so(e) && io.includes(e); + const e = typeof t == "number" ? wo(t) : t; + return uo(e) && po.includes(e); } function cc(t) { - return ii[t - 1].includes("*obsolete*"); + return ci[t - 1].includes("*obsolete*"); } function dc() { const t = {}; @@ -423,26 +423,26 @@ function dc() { } const ot = { allBookIds: ye, - nonCanonicalIds: io, + nonCanonicalIds: po, bookIdToNumber: We, - isBookIdValid: so, + isBookIdValid: uo, isBookNT: ec, isBookOT: nc, - isBookOTNT: si, + isBookOTNT: di, isBookDC: rc, allBookNumbers: oc, firstBook: ac, - lastBook: li, + lastBook: pi, extraBooks: ic, - bookNumberToId: lo, - bookNumberToEnglishName: ci, + bookNumberToId: wo, + bookNumberToEnglishName: ui, bookIdToEnglishName: sc, - isCanonical: di, + isCanonical: wi, isExtraMaterial: lc, isObsolete: cc }; var Ht = /* @__PURE__ */ ((t) => (t[t.Unknown = 0] = "Unknown", t[t.Original = 1] = "Original", t[t.Septuagint = 2] = "Septuagint", t[t.Vulgate = 3] = "Vulgate", t[t.English = 4] = "English", t[t.RussianProtestant = 5] = "RussianProtestant", t[t.RussianOrthodox = 6] = "RussianOrthodox", t))(Ht || {}); -const Pt = class { +const $t = class { // private versInfo: Versification; constructor(e) { if (et(this, "name"), et(this, "fullPath"), et(this, "isPresent"), et(this, "hasVerseSegments"), et(this, "isCustomized"), et(this, "baseVersification"), et(this, "scriptureBooks"), et(this, "_type"), e == null) @@ -456,15 +456,15 @@ const Pt = class { return !e.type || !this.type ? !1 : e.type === this.type; } }; -et(Pt, "Original", new Pt(Ht.Original)), et(Pt, "Septuagint", new Pt(Ht.Septuagint)), et(Pt, "Vulgate", new Pt(Ht.Vulgate)), et(Pt, "English", new Pt(Ht.English)), et(Pt, "RussianProtestant", new Pt(Ht.RussianProtestant)), et(Pt, "RussianOrthodox", new Pt(Ht.RussianOrthodox)); -let ue = Pt; -function Zo(t, e) { +et($t, "Original", new $t(Ht.Original)), et($t, "Septuagint", new $t(Ht.Septuagint)), et($t, "Vulgate", new $t(Ht.Vulgate)), et($t, "English", new $t(Ht.English)), et($t, "RussianProtestant", new $t(Ht.RussianProtestant)), et($t, "RussianOrthodox", new $t(Ht.RussianOrthodox)); +let ue = $t; +function na(t, e) { const n = e[0]; for (let r = 1; r < e.length; r++) t = t.split(e[r]).join(n); return t.split(n); } -var pi = /* @__PURE__ */ ((t) => (t[t.Valid = 0] = "Valid", t[t.UnknownVersification = 1] = "UnknownVersification", t[t.OutOfRange = 2] = "OutOfRange", t[t.VerseOutOfOrder = 3] = "VerseOutOfOrder", t[t.VerseRepeated = 4] = "VerseRepeated", t))(pi || {}); +var fi = /* @__PURE__ */ ((t) => (t[t.Valid = 0] = "Valid", t[t.UnknownVersification = 1] = "UnknownVersification", t[t.OutOfRange = 2] = "OutOfRange", t[t.VerseOutOfOrder = 3] = "VerseOutOfOrder", t[t.VerseRepeated = 4] = "VerseRepeated", t))(fi || {}); const St = class nt { constructor(e, n, r, o) { if (et(this, "firstChapter"), et(this, "lastChapter"), et(this, "lastVerse"), et(this, "hasSegmentsDefined"), et(this, "text"), et(this, "BBBCCCVVVS"), et(this, "longHashCode"), et(this, "versification"), et(this, "rtlMark", "‏"), et(this, "_bookNum", 0), et(this, "_chapterNum", 0), et(this, "_verseNum", 0), et(this, "_verse"), r == null && o == null) @@ -771,8 +771,8 @@ const St = class nt { allVerses(e = !1, n = nt.verseRangeSeparators, r = nt.verseSequenceIndicators) { if (this._verse == null || this.chapterNum <= 0) return [this.clone()]; - const o = [], a = Zo(this._verse, r); - for (const i of a.map((l) => Zo(l, n))) { + const o = [], a = na(this._verse, r); + for (const i of a.map((l) => na(l, n))) { const l = this.clone(); l.verse = i[0]; const c = l.verseNum; @@ -780,13 +780,13 @@ const St = class nt { const d = this.clone(); if (d.verse = i[1], !e) for (let p = c + 1; p < d.verseNum; p++) { - const m = new nt( + const h = new nt( this._bookNum, this._chapterNum, p, this.versification ); - this.isExcluded || o.push(m); + this.isExcluded || o.push(h); } o.push(d); } @@ -829,10 +829,10 @@ const St = class nt { et(St, "defaultVersification", ue.English), et(St, "verseRangeSeparator", "-"), et(St, "verseSequenceIndicator", ","), et(St, "verseRangeSeparators", [St.verseRangeSeparator]), et(St, "verseSequenceIndicators", [St.verseSequenceIndicator]), et(St, "chapterDigitShifter", 1e3), et(St, "bookDigitShifter", St.chapterDigitShifter * St.chapterDigitShifter), et(St, "bcvMaxValue", St.chapterDigitShifter - 1), /** * The valid status of the VerseRef. */ -et(St, "ValidStatusType", pi); +et(St, "ValidStatusType", fi); class tn extends Error { } -const co = wt.Root, ui = wt.Trigger, pc = wt.Group, mh = wt.Portal, hh = wt.Sub, gh = wt.RadioGroup, uc = T.forwardRef(({ className: t, inset: e, children: n, ...r }, o) => /* @__PURE__ */ x( +const fo = wt.Root, mi = wt.Trigger, pc = wt.Group, mh = wt.Portal, hh = wt.Sub, gh = wt.RadioGroup, uc = T.forwardRef(({ className: t, inset: e, children: n, ...r }, o) => /* @__PURE__ */ x( wt.SubTrigger, { ref: o, @@ -844,7 +844,7 @@ const co = wt.Root, ui = wt.Trigger, pc = wt.Group, mh = wt.Portal, hh = wt.Sub, ...r, children: [ n, - /* @__PURE__ */ s(Wa, { className: "tw-ml-auto tw-h-4 tw-w-4" }) + /* @__PURE__ */ s(Ja, { className: "tw-ml-auto tw-h-4 tw-w-4" }) ] } )); @@ -875,7 +875,7 @@ const rr = T.forwardRef(({ className: t, sideOffset: e = 4, ...n }, r) => /* @__ } ) })); rr.displayName = wt.Content.displayName; -const wi = T.forwardRef(({ className: t, inset: e, ...n }, r) => /* @__PURE__ */ s( +const hi = T.forwardRef(({ className: t, inset: e, ...n }, r) => /* @__PURE__ */ s( wt.Item, { ref: r, @@ -888,8 +888,8 @@ const wi = T.forwardRef(({ className: t, inset: e, ...n }, r) => /* @__PURE__ */ ...n } )); -wi.displayName = wt.Item.displayName; -const po = T.forwardRef(({ className: t, children: e, checked: n, ...r }, o) => /* @__PURE__ */ x( +hi.displayName = wt.Item.displayName; +const mo = T.forwardRef(({ className: t, children: e, checked: n, ...r }, o) => /* @__PURE__ */ x( wt.CheckboxItem, { ref: o, @@ -905,8 +905,8 @@ const po = T.forwardRef(({ className: t, children: e, checked: n, ...r }, o) => ] } )); -po.displayName = wt.CheckboxItem.displayName; -const fi = T.forwardRef(({ className: t, children: e, ...n }, r) => /* @__PURE__ */ x( +mo.displayName = wt.CheckboxItem.displayName; +const gi = T.forwardRef(({ className: t, children: e, ...n }, r) => /* @__PURE__ */ x( wt.RadioItem, { ref: r, @@ -916,12 +916,12 @@ const fi = T.forwardRef(({ className: t, children: e, ...n }, r) => /* @__PURE__ ), ...n, children: [ - /* @__PURE__ */ s("span", { className: "tw-absolute tw-left-2 tw-flex tw-h-3.5 tw-w-3.5 tw-items-center tw-justify-center", children: /* @__PURE__ */ s(wt.ItemIndicator, { children: /* @__PURE__ */ s(qa, { className: "tw-h-2 tw-w-2 tw-fill-current" }) }) }), + /* @__PURE__ */ s("span", { className: "tw-absolute tw-left-2 tw-flex tw-h-3.5 tw-w-3.5 tw-items-center tw-justify-center", children: /* @__PURE__ */ s(wt.ItemIndicator, { children: /* @__PURE__ */ s(Za, { className: "tw-h-2 tw-w-2 tw-fill-current" }) }) }), e ] } )); -fi.displayName = wt.RadioItem.displayName; +gi.displayName = wt.RadioItem.displayName; const Sn = T.forwardRef(({ className: t, inset: e, ...n }, r) => /* @__PURE__ */ s( wt.Label, { @@ -960,7 +960,7 @@ const mc = Qn( bookType: a, children: i }, l) => /* @__PURE__ */ x( - wi, + hi, { ref: l, textValue: t, @@ -1005,7 +1005,7 @@ function hc({ highlightedChapter: r, handleHighlightedChapter: o }) { - const a = Array.from({ length: e }, (l, c) => c + 1), i = Bt( + const a = Array.from({ length: e }, (l, c) => c + 1), i = Tt( (l) => { o(l); }, @@ -1067,7 +1067,7 @@ const pn = ot.allBookIds, bc = { OT: "Old Testament", NT: "New Testament", DC: "Deuterocanon" -}, Qo = ["OT", "NT", "DC"], vc = 32 + 32 + 32, yc = [ +}, ra = ["OT", "NT", "DC"], vc = 32 + 32 + 32, yc = [ /^(\w+)$/i, // Matches a single word (book name or id) /^(\w+)(?:\s(\d+))$/i, @@ -1095,7 +1095,7 @@ function bh({ scrRef: t, handleSubmit: e }) { ot.bookNumberToId(t.bookNum) ), [i, l] = ut(t.chapterNum ?? 0), [c, d] = ut( ot.bookNumberToId(t.bookNum) - ), [p, m] = ut(!1), [w, g] = ut(p), v = ge(void 0), f = ge(void 0), h = ge(void 0), E = Bt( + ), [p, h] = ut(!1), [w, g] = ut(p), v = ge(void 0), f = ge(void 0), m = ge(void 0), E = Tt( (k) => xc(k).filter((B) => { const D = ot.bookIdToEnglishName(B).toLowerCase(), J = n.replace(/[^a-zA-Z]/g, "").toLowerCase(); return D.includes(J) || // Match book name @@ -1104,13 +1104,13 @@ function bh({ scrRef: t, handleSubmit: e }) { [n] ), _ = (k) => { r(k); - }, C = ge(!1), S = Bt((k) => { + }, C = ge(!1), S = Tt((k) => { if (C.current) { C.current = !1; return; } - m(k); - }, []), b = Bt( + h(k); + }, []), b = Tt( (k, B, D, J) => { if (l( ot.bookNumberToId(t.bookNum) !== k ? 1 : t.chapterNum @@ -1119,15 +1119,15 @@ function bh({ scrRef: t, handleSubmit: e }) { bookNum: ot.bookIdToNumber(k), chapterNum: D || 1, verseNum: J || 1 - }), m(!1), r(""); + }), h(!1), r(""); return; } - a(o !== k ? k : ""), m(!B); + a(o !== k ? k : ""), h(!B); }, [e, t.bookNum, t.chapterNum, o] - ), I = (k) => { + ), A = (k) => { k <= 0 || k > en(o) || b(o, !0, k); - }, z = Bt(() => { + }, z = Tt(() => { yc.forEach((k) => { const B = n.match(k); if (B) { @@ -1140,13 +1140,13 @@ function bh({ scrRef: t, handleSubmit: e }) { ); } }); - }, [b, n]), H = Bt( + }, [b, n]), H = Tt( (k) => { - p ? (k.key === "ArrowDown" || k.key === "ArrowUp") && (typeof h < "u" && // Ref uses null + p ? (k.key === "ArrowDown" || k.key === "ArrowUp") && (typeof m < "u" && // Ref uses null // eslint-disable-next-line no-null/no-null - h.current !== null ? h.current.focus() : typeof f < "u" && // Ref uses null + m.current !== null ? m.current.focus() : typeof f < "u" && // Ref uses null // eslint-disable-next-line no-null/no-null - f.current !== null && f.current.focus(), k.preventDefault()) : m(!0); + f.current !== null && f.current.focus(), k.preventDefault()) : h(!0); }, [p] ), O = (k) => { @@ -1181,20 +1181,20 @@ function bh({ scrRef: t, handleSubmit: e }) { }; return ae(() => { o === c ? o === ot.bookNumberToId(t.bookNum) ? l(t.chapterNum) : l(1) : l(0); - }, [c, t.bookNum, t.chapterNum, o]), Ko(() => { + }, [c, t.bookNum, t.chapterNum, o]), ta(() => { g(p); - }, [p]), Ko(() => { + }, [p]), ta(() => { const k = setTimeout(() => { - if (w && f.current && h.current) { - const D = h.current.offsetTop - vc; + if (w && f.current && m.current) { + const D = m.current.offsetTop - vc; f.current.scrollTo({ top: D, behavior: "instant" }); } }, 10); return () => { clearTimeout(k); }; - }, [w]), /* @__PURE__ */ s("div", { className: "pr-twp tw-flex", children: /* @__PURE__ */ x(co, { modal: !1, open: p, onOpenChange: S, children: [ - /* @__PURE__ */ s(ui, { asChild: !0, children: /* @__PURE__ */ s( + }, [w]), /* @__PURE__ */ s("div", { className: "pr-twp tw-flex", children: /* @__PURE__ */ x(fo, { modal: !1, open: p, onOpenChange: S, children: [ + /* @__PURE__ */ s(mi, { asChild: !0, children: /* @__PURE__ */ s( Zl, { ref: v, @@ -1202,7 +1202,7 @@ function bh({ scrRef: t, handleSubmit: e }) { handleSearch: _, handleKeyDown: H, handleOnClick: () => { - a(ot.bookNumberToId(t.bookNum)), d(ot.bookNumberToId(t.bookNum)), l(t.chapterNum > 0 ? t.chapterNum : 0), m(!0), v.current.focus(); + a(ot.bookNumberToId(t.bookNum)), d(ot.bookNumberToId(t.bookNum)), l(t.chapterNum > 0 ? t.chapterNum : 0), h(!0), v.current.focus(); }, onFocus: () => { C.current = !0; @@ -1228,7 +1228,7 @@ function bh({ scrRef: t, handleSubmit: e }) { handleBookmarks: () => console.log("bookmarks") } ), - Qo.map( + ra.map( (k, B) => E(k).length > 0 && /* @__PURE__ */ x("div", { children: [ /* @__PURE__ */ s(Sn, { className: "tw-font-semibold tw-text-foreground/80", children: bc[k] }), E(k).map((D) => /* @__PURE__ */ s("div", { children: /* @__PURE__ */ s( @@ -1241,12 +1241,12 @@ function bh({ scrRef: t, handleSubmit: e }) { handleKeyDown: $, bookType: k, ref: (J) => { - o === D && (h.current = J); + o === D && (m.current = J); }, children: /* @__PURE__ */ s( hc, { - handleSelectChapter: I, + handleSelectChapter: A, endChapter: en(D), activeChapter: t.bookNum === ot.bookIdToNumber(D) ? t.chapterNum : 0, highlightedChapter: i, @@ -1257,7 +1257,7 @@ function bh({ scrRef: t, handleSubmit: e }) { ) } ) }, D)), - Qo.length - 1 !== B ? /* @__PURE__ */ s(or, {}) : void 0 + ra.length - 1 !== B ? /* @__PURE__ */ s(or, {}) : void 0 ] }, k) ) ] @@ -1295,9 +1295,9 @@ const Sc = Xe( gt.displayName = "Button"; const Tc = Xe( "tw-text-sm tw-font-medium tw-leading-none peer-disabled:tw-cursor-not-allowed peer-disabled:tw-opacity-70" -), Xt = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s(Ja.Root, { ref: n, className: N("pr-twp", Tc(), t), ...e })); -Xt.displayName = Ja.Root.displayName; -const mi = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( +), Xt = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s(ti.Root, { ref: n, className: N("pr-twp", Tc(), t), ...e })); +Xt.displayName = ti.Root.displayName; +const bi = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( mn.Root, { className: N("pr-twp tw-grid tw-gap-2", t), @@ -1305,7 +1305,7 @@ const mi = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( ref: n } )); -mi.displayName = mn.Root.displayName; +bi.displayName = mn.Root.displayName; const Wr = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( mn.Item, { @@ -1315,11 +1315,11 @@ const Wr = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( t ), ...e, - children: /* @__PURE__ */ s(mn.Indicator, { className: "tw-flex tw-items-center tw-justify-center", children: /* @__PURE__ */ s(qa, { className: "tw-h-2.5 tw-w-2.5 tw-fill-current tw-text-current" }) }) + children: /* @__PURE__ */ s(mn.Indicator, { className: "tw-flex tw-items-center tw-justify-center", children: /* @__PURE__ */ s(Za, { className: "tw-h-2.5 tw-w-2.5 tw-fill-current tw-text-current" }) }) } )); Wr.displayName = mn.Item.displayName; -const Cc = hn.Root, Oc = hn.Trigger, hi = T.forwardRef(({ className: t, align: e = "center", sideOffset: n = 4, ...r }, o) => /* @__PURE__ */ s(hn.Portal, { children: /* @__PURE__ */ s( +const Cc = hn.Root, Oc = hn.Trigger, vi = T.forwardRef(({ className: t, align: e = "center", sideOffset: n = 4, ...r }, o) => /* @__PURE__ */ s(hn.Portal, { children: /* @__PURE__ */ s( hn.Content, { ref: o, @@ -1332,8 +1332,8 @@ const Cc = hn.Root, Oc = hn.Trigger, hi = T.forwardRef(({ className: t, align: e ...r } ) })); -hi.displayName = hn.Content.displayName; -const Rc = vt.Portal, gi = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( +vi.displayName = hn.Content.displayName; +const Rc = vt.Portal, yi = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( vt.Overlay, { ref: n, @@ -1344,9 +1344,9 @@ const Rc = vt.Portal, gi = T.forwardRef(({ className: t, ...e }, n) => /* @__PUR ...e } )); -gi.displayName = vt.Overlay.displayName; +yi.displayName = vt.Overlay.displayName; const _c = T.forwardRef(({ className: t, children: e, ...n }, r) => /* @__PURE__ */ x(Rc, { children: [ - /* @__PURE__ */ s(gi, {}), + /* @__PURE__ */ s(yi, {}), /* @__PURE__ */ x( vt.Content, { @@ -1359,7 +1359,7 @@ const _c = T.forwardRef(({ className: t, children: e, ...n }, r) => /* @__PURE__ children: [ e, /* @__PURE__ */ x(vt.Close, { className: "tw-absolute tw-right-4 tw-top-4 tw-rounded-sm tw-opacity-70 tw-ring-offset-background tw-transition-opacity hover:tw-opacity-100 focus:tw-outline-none focus:tw-ring-2 focus:tw-ring-ring focus:tw-ring-offset-2 disabled:tw-pointer-events-none data-[state=open]:tw-bg-accent data-[state=open]:tw-text-muted-foreground", children: [ - /* @__PURE__ */ s(Ka, { className: "tw-h-4 tw-w-4" }), + /* @__PURE__ */ s(Qa, { className: "tw-h-4 tw-w-4" }), /* @__PURE__ */ s("span", { className: "tw-sr-only", children: "Close" }) ] }) ] @@ -1385,8 +1385,8 @@ const $c = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( } )); $c.displayName = vt.Description.displayName; -const bi = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( - Ot, +const xi = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( + Rt, { ref: n, className: N( @@ -1396,11 +1396,11 @@ const bi = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( ...e } )); -bi.displayName = Ot.displayName; -const vi = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ x("div", { className: "tw-flex tw-items-center tw-border-b tw-px-3", children: [ +xi.displayName = Rt.displayName; +const Ni = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ x("div", { className: "tw-flex tw-items-center tw-border-b tw-px-3", children: [ /* @__PURE__ */ s(ol, { className: "tw-me-2 tw-h-4 tw-w-4 tw-shrink-0 tw-opacity-50" }), /* @__PURE__ */ s( - Ot.Input, + Rt.Input, { ref: n, className: N( @@ -1411,20 +1411,20 @@ const vi = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ x("div", } ) ] })); -vi.displayName = Ot.Input.displayName; -const yi = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( - Ot.List, +Ni.displayName = Rt.Input.displayName; +const ki = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( + Rt.List, { ref: n, className: N("tw-max-h-[300px] tw-overflow-y-auto tw-overflow-x-hidden", t), ...e } )); -yi.displayName = Ot.List.displayName; -const xi = T.forwardRef((t, e) => /* @__PURE__ */ s(Ot.Empty, { ref: e, className: "tw-py-6 tw-text-center tw-text-sm", ...t })); -xi.displayName = Ot.Empty.displayName; -const Ic = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( - Ot.Group, +ki.displayName = Rt.List.displayName; +const Ei = T.forwardRef((t, e) => /* @__PURE__ */ s(Rt.Empty, { ref: e, className: "tw-py-6 tw-text-center tw-text-sm", ...t })); +Ei.displayName = Rt.Empty.displayName; +const Ac = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( + Rt.Group, { ref: n, className: N( @@ -1434,18 +1434,18 @@ const Ic = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( ...e } )); -Ic.displayName = Ot.Group.displayName; -const Ac = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( - Ot.Separator, +Ac.displayName = Rt.Group.displayName; +const Ic = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( + Rt.Separator, { ref: n, className: N("tw--mx-1 tw-h-px tw-bg-border", t), ...e } )); -Ac.displayName = Ot.Separator.displayName; -const Ni = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( - Ot.Item, +Ic.displayName = Rt.Separator.displayName; +const Si = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( + Rt.Item, { ref: n, className: N( @@ -1455,66 +1455,67 @@ const Ni = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( ...e } )); -Ni.displayName = Ot.Item.displayName; +Si.displayName = Rt.Item.displayName; function Mc(t) { return typeof t == "string" ? t : typeof t == "number" ? t.toString() : t.label; } -function ta({ +function qr({ id: t, options: e = [], - className: n, - value: r, - onChange: o = () => { + buttonClassName: n, + popoverContentClassName: r, + value: o, + onChange: a = () => { }, - getOptionLabel: a = Mc, - buttonPlaceholder: i = "", - textPlaceholder: l = "", - commandEmptyMessage: c = "No option found", - buttonVariant: d = "outline", - dir: p = "ltr", - isDisabled: m = !1, - ...w + getOptionLabel: i = Mc, + buttonPlaceholder: l = "", + textPlaceholder: c = "", + commandEmptyMessage: d = "No option found", + buttonVariant: p = "outline", + dir: h = "ltr", + isDisabled: w = !1, + ...g }) { - const [g, v] = ut(!1); - return /* @__PURE__ */ x(Cc, { open: g, onOpenChange: v, ...w, children: [ + const [v, f] = ut(!1); + return /* @__PURE__ */ x(Cc, { open: v, onOpenChange: f, ...g, children: [ /* @__PURE__ */ s(Oc, { asChild: !0, children: /* @__PURE__ */ x( gt, { - variant: d, + variant: p, role: "combobox", - "aria-expanded": g, + "aria-expanded": v, id: t, className: N("tw-w-[200px] tw-justify-between", n), - disabled: m, + disabled: w, children: [ - /* @__PURE__ */ s("span", { className: "tw-overflow-hidden tw-text-ellipsis tw-whitespace-nowrap", children: r ? a(r) : i }), + /* @__PURE__ */ s("span", { className: "tw-overflow-hidden tw-text-ellipsis tw-whitespace-nowrap", children: o ? i(o) : l }), /* @__PURE__ */ s(al, { className: "tw-ms-2 tw-h-4 tw-w-4 tw-shrink-0 tw-opacity-50" }) ] } ) }), - /* @__PURE__ */ s(hi, { className: "tw-w-[200px] tw-p-0", dir: p, children: /* @__PURE__ */ x(bi, { children: [ - /* @__PURE__ */ s(vi, { dir: p, placeholder: l, className: "tw-text-inherit" }), - /* @__PURE__ */ s(xi, { children: c }), - /* @__PURE__ */ s(yi, { children: e.map((f) => /* @__PURE__ */ x( - Ni, + /* @__PURE__ */ s(vi, { className: N("tw-w-[200px] tw-p-0", r), dir: h, children: /* @__PURE__ */ x(xi, { children: [ + /* @__PURE__ */ s(Ni, { dir: h, placeholder: c, className: "tw-text-inherit" }), + /* @__PURE__ */ s(Ei, { children: d }), + /* @__PURE__ */ s(ki, { children: e.map((m) => /* @__PURE__ */ x( + Si, { - value: a(f), + value: i(m), onSelect: () => { - o(f), v(!1); + a(m), f(!1); }, children: [ /* @__PURE__ */ s( tr, { className: N("tw-me-2 tw-h-4 tw-w-4", { - "tw-opacity-0": !r || a(r) !== a(f) + "tw-opacity-0": !o || i(o) !== i(m) }) } ), - a(f) + i(m) ] }, - a(f) + i(m) )) }) ] }) }) ] }); @@ -1527,20 +1528,20 @@ function Dc({ isDisabled: o = !1, chapterCount: a }) { - const i = $t( + const i = At( () => Array.from({ length: a }, (d, p) => p + 1), [a] ); return /* @__PURE__ */ x(ie, { children: [ /* @__PURE__ */ s(Xt, { htmlFor: "start-chapters-combobox", children: "Chapters" }), /* @__PURE__ */ s( - ta, + qr, { isDisabled: o, onChange: (d) => { n(d), d > e && r(d); }, - className: "tw-ml-2 tw-mr-2 tw-w-20", + buttonClassName: "tw-ml-2 tw-mr-2 tw-w-20", options: i, getOptionLabel: (d) => d.toString(), value: t @@ -1549,13 +1550,13 @@ function Dc({ ), /* @__PURE__ */ s(Xt, { htmlFor: "end-chapters-combobox", children: "to" }), /* @__PURE__ */ s( - ta, + qr, { isDisabled: o, onChange: (d) => { r(d), d < t && n(d); }, - className: "tw-ml-2 tw-w-20", + buttonClassName: "tw-ml-2 tw-w-20", options: i, getOptionLabel: (d) => d.toString(), value: e @@ -1582,18 +1583,18 @@ function yh({ handleSelectStartChapter: c, localizedStrings: d }) { - const p = _r(d, "%webView_bookSelector_currentBook%"), m = _r(d, "%webView_bookSelector_choose%"), w = _r(d, "%webView_bookSelector_chooseBooks%"), [g, v] = ut( + const p = _r(d, "%webView_bookSelector_currentBook%"), h = _r(d, "%webView_bookSelector_choose%"), w = _r(d, "%webView_bookSelector_chooseBooks%"), [g, v] = ut( "current book" /* CURRENT_BOOK */ - ), f = (h) => { - v(h), t(h); + ), f = (m) => { + v(m), t(m); }; return /* @__PURE__ */ s( - mi, + bi, { className: "pr-twp tw-flex", value: g, - onValueChange: (h) => f(h), + onValueChange: (m) => f(m), children: /* @__PURE__ */ x("div", { className: "tw-flex tw-w-full tw-flex-col tw-gap-4", children: [ /* @__PURE__ */ x("div", { className: "tw-grid tw-grid-cols-[25%,25%,50%]", children: [ /* @__PURE__ */ x("div", { className: "tw-flex tw-items-center", children: [ @@ -1624,13 +1625,13 @@ function yh({ }), /* @__PURE__ */ s(Xt, { className: "tw-ml-1", children: w }) ] }), - /* @__PURE__ */ s(Xt, { className: "tw-flex tw-items-center", children: r.map((h) => ot.bookIdToEnglishName(h)).join(", ") }), + /* @__PURE__ */ s(Xt, { className: "tw-flex tw-items-center", children: r.map((m) => ot.bookIdToEnglishName(m)).join(", ") }), /* @__PURE__ */ s( gt, { disabled: g === "current book", onClick: () => n(), - children: m + children: h } ) ] }) @@ -1639,7 +1640,7 @@ function yh({ ); } function jc({ table: t }) { - return /* @__PURE__ */ x(co, { children: [ + return /* @__PURE__ */ x(fo, { children: [ /* @__PURE__ */ s(Ol, { asChild: !0, children: /* @__PURE__ */ x(gt, { variant: "outline", size: "sm", className: "tw-ml-auto tw-hidden tw-h-8 lg:tw-flex", children: [ /* @__PURE__ */ s(il, { className: "tw-mr-2 tw-h-4 tw-w-4" }), "View" @@ -1648,7 +1649,7 @@ function jc({ table: t }) { /* @__PURE__ */ s(Sn, { children: "Toggle columns" }), /* @__PURE__ */ s(or, {}), t.getAllColumns().filter((e) => e.getCanHide()).map((e) => /* @__PURE__ */ s( - po, + mo, { className: "tw-capitalize", checked: e.getIsVisible(), @@ -1676,7 +1677,7 @@ const gn = bt.Root, Vc = bt.Group, bn = bt.Value, De = T.forwardRef(({ className } )); De.displayName = bt.Trigger.displayName; -const ki = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( +const Ti = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( bt.ScrollUpButton, { ref: n, @@ -1685,8 +1686,8 @@ const ki = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( children: /* @__PURE__ */ s(sl, { className: "tw-h-4 tw-w-4" }) } )); -ki.displayName = bt.ScrollUpButton.displayName; -const Ei = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( +Ti.displayName = bt.ScrollUpButton.displayName; +const Ci = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( bt.ScrollDownButton, { ref: n, @@ -1695,7 +1696,7 @@ const Ei = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( children: /* @__PURE__ */ s(er, { className: "tw-h-4 tw-w-4" }) } )); -Ei.displayName = bt.ScrollDownButton.displayName; +Ci.displayName = bt.ScrollDownButton.displayName; const Be = T.forwardRef(({ className: t, children: e, position: n = "popper", ...r }, o) => /* @__PURE__ */ s(bt.Portal, { children: /* @__PURE__ */ x( bt.Content, { @@ -1708,7 +1709,7 @@ const Be = T.forwardRef(({ className: t, children: e, position: n = "popper", .. position: n, ...r, children: [ - /* @__PURE__ */ s(ki, {}), + /* @__PURE__ */ s(Ti, {}), /* @__PURE__ */ s( bt.Viewport, { @@ -1719,7 +1720,7 @@ const Be = T.forwardRef(({ className: t, children: e, position: n = "popper", .. children: e } ), - /* @__PURE__ */ s(Ei, {}) + /* @__PURE__ */ s(Ci, {}) ] } ) })); @@ -1936,22 +1937,22 @@ function Hc({ onRowClickHandler: i = () => { } }) { - var h; - const [l, c] = ut([]), [d, p] = ut([]), [m, w] = ut({}), [g, v] = ut({}), f = Za({ + var m; + const [l, c] = ut([]), [d, p] = ut([]), [h, w] = ut({}), [g, v] = ut({}), f = ei({ data: e, columns: t, - getCoreRowModel: Qa(), - ...n && { getPaginationRowModel: Il() }, + getCoreRowModel: ni(), + ...n && { getPaginationRowModel: Al() }, onSortingChange: c, - getSortedRowModel: ti(), + getSortedRowModel: ri(), onColumnFiltersChange: p, - getFilteredRowModel: Al(), + getFilteredRowModel: Il(), onColumnVisibilityChange: w, onRowSelectionChange: v, state: { sorting: l, columnFilters: d, - columnVisibility: m, + columnVisibility: h, rowSelection: g } }); @@ -1959,7 +1960,7 @@ function Hc({ o && /* @__PURE__ */ s(jc, { table: f }), /* @__PURE__ */ x(ar, { stickyHeader: a, children: [ /* @__PURE__ */ s(ir, { stickyHeader: a, children: f.getHeaderGroups().map((E) => /* @__PURE__ */ s(oe, { children: E.headers.map((_) => /* @__PURE__ */ s(vn, { children: _.isPlaceholder ? void 0 : dn(_.column.columnDef.header, _.getContext()) }, _.id)) }, E.id)) }), - /* @__PURE__ */ s(sr, { children: (h = f.getRowModel().rows) != null && h.length ? f.getRowModel().rows.map((E) => /* @__PURE__ */ s( + /* @__PURE__ */ s(sr, { children: (m = f.getRowModel().rows) != null && m.length ? f.getRowModel().rows.map((E) => /* @__PURE__ */ s( oe, { onClick: () => i(E, f), @@ -1999,10 +2000,10 @@ function Xc({ setScriptureReference: e, localizedStrings: n }) { - const r = n["%webView_inventory_occurrences_table_header_reference%"], o = n["%webView_inventory_occurrences_table_header_occurrence%"], a = $t(() => { + const r = n["%webView_inventory_occurrences_table_header_reference%"], o = n["%webView_inventory_occurrences_table_header_occurrence%"], a = At(() => { const i = []; return t.forEach((l) => { - i.some((c) => ao(c, l)) || i.push(l); + i.some((c) => co(c, l)) || i.push(l); }), i; }, [t]); return /* @__PURE__ */ x(ar, { stickyHeader: !0, children: [ @@ -2025,7 +2026,7 @@ function Xc({ )) }) ] }); } -const uo = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( +const ho = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( Xr.Root, { ref: n, @@ -2043,15 +2044,15 @@ const uo = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( ) } )); -uo.displayName = Xr.Root.displayName; -const Yc = (t) => t.split(/(?:\r?\n|\r)|(?=(?:\\(?:v|c|id)))/g), ea = (t) => { +ho.displayName = Xr.Root.displayName; +const Yc = (t) => t.split(/(?:\r?\n|\r)|(?=(?:\\(?:v|c|id)))/g), oa = (t) => { const e = /^\\[vc]\s+(\d+)/, n = t.match(e); if (n) return +n[1]; }, Wc = (t) => { const e = t.match(/^\\id\s+([A-Za-z]+)/); return e ? ot.bookIdToNumber(e[1]) : 0; -}, qc = (t, e, n) => n.includes(t) ? "unapproved" : e.includes(t) ? "approved" : "unknown", Si = Xe( +}, qc = (t, e, n) => n.includes(t) ? "unapproved" : e.includes(t) ? "approved" : "unknown", Oi = Xe( "pr-twp tw-inline-flex tw-items-center tw-justify-center tw-rounded-md tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-colors hover:tw-bg-muted hover:tw-text-muted-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50 data-[state=on]:tw-bg-accent data-[state=on]:tw-text-accent-foreground", { variants: { @@ -2071,25 +2072,25 @@ const Yc = (t) => t.split(/(?:\r?\n|\r)|(?=(?:\\(?:v|c|id)))/g), ea = (t) => { } } ), Kc = T.forwardRef(({ className: t, variant: e, size: n, ...r }, o) => /* @__PURE__ */ s( - ei.Root, + oi.Root, { ref: o, - className: N(Si({ variant: e, size: n, className: t })), + className: N(Oi({ variant: e, size: n, className: t })), ...r } )); -Kc.displayName = ei.Root.displayName; -const Ti = T.createContext({ +Kc.displayName = oi.Root.displayName; +const Ri = T.createContext({ size: "default", variant: "default" -}), Ci = T.forwardRef(({ className: t, variant: e, size: n, children: r, ...o }, a) => /* @__PURE__ */ s( +}), _i = T.forwardRef(({ className: t, variant: e, size: n, children: r, ...o }, a) => /* @__PURE__ */ s( nr.Root, { ref: a, className: N("pr-twp tw-flex tw-items-center tw-justify-center tw-gap-1", t), ...o, children: /* @__PURE__ */ s( - Ti.Provider, + Ri.Provider, { value: { variant: e, size: n }, children: r @@ -2097,15 +2098,15 @@ const Ti = T.createContext({ ) } )); -Ci.displayName = nr.Root.displayName; +_i.displayName = nr.Root.displayName; const Un = T.forwardRef(({ className: t, children: e, variant: n, size: r, ...o }, a) => { - const i = T.useContext(Ti); + const i = T.useContext(Ri); return /* @__PURE__ */ s( nr.Item, { ref: a, className: N( - Si({ + Oi({ variant: i.variant || n, size: i.size || r }), @@ -2155,7 +2156,7 @@ const lr = (t) => t === "asc" ? /* @__PURE__ */ s(ml, { className: "tw-ms-2 tw-h ] }) }), cell: ({ row: a }) => { const i = a.getValue("status"), l = a.getValue("item"); - return /* @__PURE__ */ x(Ci, { value: i, variant: "outline", type: "single", children: [ + return /* @__PURE__ */ x(_i, { value: i, variant: "outline", type: "single", children: [ /* @__PURE__ */ s( Un, { @@ -2226,12 +2227,12 @@ const lr = (t) => t === "asc" ? /* @__PURE__ */ s(ml, { className: "tw-ms-2 tw-h const a = []; let i = e.bookNum, l = e.chapterNum, c = e.verseNum; return Yc(t).forEach((p) => { - p.startsWith("\\id") && (i = Wc(p), l = 0, c = 0), p.startsWith("\\c") && (l = ea(p), c = 0), p.startsWith("\\v") && (c = ea(p), l === 0 && (l = e.chapterNum)); - let m = o.exec(p) ?? void 0; - for (; m; ) { + p.startsWith("\\id") && (i = Wc(p), l = 0, c = 0), p.startsWith("\\c") && (l = oa(p), c = 0), p.startsWith("\\v") && (c = oa(p), l === 0 && (l = e.chapterNum)); + let h = o.exec(p) ?? void 0; + for (; h; ) { const w = []; - m.forEach((h) => w.push(h)); - const g = m.index, v = a.find((h) => ao(h.items, w)), f = { + h.forEach((m) => w.push(m)); + const g = h.index, v = a.find((m) => co(m.items, w)), f = { reference: { bookNum: i !== void 0 ? i : -1, chapterNum: l !== void 0 ? l : -1, @@ -2242,15 +2243,15 @@ const lr = (t) => t === "asc" ? /* @__PURE__ */ s(ml, { className: "tw-ms-2 tw-h if (v) v.count += 1, v.occurrences.push(f); else { - const h = { + const m = { items: w, count: 1, status: qc(w[0], n, r), occurrences: [f] }; - a.push(h); + a.push(m); } - m = o.exec(p) ?? void 0; + h = o.exec(p) ?? void 0; } }), a; }, Jt = (t, e) => t[e] ?? e; @@ -2267,16 +2268,16 @@ function Sh({ onScopeChange: d, columns: p }) { - const m = Jt(n, "%webView_inventory_all%"), w = Jt(n, "%webView_inventory_approved%"), g = Jt(n, "%webView_inventory_unapproved%"), v = Jt(n, "%webView_inventory_unknown%"), f = Jt(n, "%webView_inventory_scope_currentBook%"), h = Jt(n, "%webView_inventory_scope_chapter%"), E = Jt(n, "%webView_inventory_scope_verse%"), _ = Jt(n, "%webView_inventory_filter_text%"), C = Jt( + const h = Jt(n, "%webView_inventory_all%"), w = Jt(n, "%webView_inventory_approved%"), g = Jt(n, "%webView_inventory_unapproved%"), v = Jt(n, "%webView_inventory_unknown%"), f = Jt(n, "%webView_inventory_scope_currentBook%"), m = Jt(n, "%webView_inventory_scope_chapter%"), E = Jt(n, "%webView_inventory_scope_verse%"), _ = Jt(n, "%webView_inventory_filter_text%"), C = Jt( n, "%webView_inventory_show_additional_items%" - ), [S, b] = ut(!1), [I, z] = ut("all"), [H, O] = ut(""), [$, k] = ut([]), B = $t(() => l ? r instanceof RegExp ? Qc( + ), [S, b] = ut(!1), [A, z] = ut("all"), [H, O] = ut(""), [$, k] = ut([]), B = At(() => l ? r instanceof RegExp ? Qc( l, t, a, i, r - ) : r(l, t, a, i) : [], [l, r, t, a, i]), D = $t(() => { + ) : r(l, t, a, i) : [], [l, r, t, a, i]), D = At(() => { if (S) return B; const y = []; @@ -2291,7 +2292,7 @@ function Sh({ status: R.status }); }), y; - }, [S, B]), J = $t(() => Zc(D, I, H), [D, I, H]), q = $t(() => { + }, [S, B]), J = At(() => Zc(D, A, H), [D, A, H]), q = At(() => { var L, F; if (!S) return p; @@ -2326,10 +2327,10 @@ function Sh({ z(y); else throw new Error(`Invalid status filter value: ${y}`); - }, rt = $t(() => { + }, rt = At(() => { if (D.length === 0 || $.length === 0) return []; - const y = D.filter((R) => ao( + const y = D.filter((R) => co( S ? R.items : [R.items[0]], $ )); @@ -2343,11 +2344,11 @@ function Sh({ gn, { onValueChange: (y) => at(y), - defaultValue: I, + defaultValue: A, children: [ /* @__PURE__ */ s(De, { className: "tw-m-1", children: /* @__PURE__ */ s(bn, { placeholder: "Select filter" }) }), /* @__PURE__ */ x(Be, { children: [ - /* @__PURE__ */ s(Gt, { value: "all", children: m }), + /* @__PURE__ */ s(Gt, { value: "all", children: h }), /* @__PURE__ */ s(Gt, { value: "approved", children: w }), /* @__PURE__ */ s(Gt, { value: "unapproved", children: g }), /* @__PURE__ */ s(Gt, { value: "unknown", children: v }) @@ -2359,7 +2360,7 @@ function Sh({ /* @__PURE__ */ s(De, { className: "tw-m-1", children: /* @__PURE__ */ s(bn, { placeholder: "Select scope" }) }), /* @__PURE__ */ x(Be, { children: [ /* @__PURE__ */ s(Gt, { value: "book", children: f }), - /* @__PURE__ */ s(Gt, { value: "chapter", children: h }), + /* @__PURE__ */ s(Gt, { value: "chapter", children: m }), /* @__PURE__ */ s(Gt, { value: "verse", children: E }) ] }) ] }), @@ -2376,7 +2377,7 @@ function Sh({ ), o && /* @__PURE__ */ x("div", { className: "tw-m-1 tw-flex tw-items-center tw-rounded-md tw-border", children: [ /* @__PURE__ */ s( - uo, + ho, { className: "tw-m-1", checked: S, @@ -2424,8 +2425,8 @@ function td({ onSearch: t, placeholder: e, isFullWidth: n }) { } ); } -const Oi = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( - Rt.Root, +const Pi = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( + _t.Root, { orientation: "vertical", ref: n, @@ -2433,9 +2434,9 @@ const Oi = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( ...e } )); -Oi.displayName = Rt.List.displayName; -const Ri = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( - Rt.List, +Pi.displayName = _t.List.displayName; +const $i = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( + _t.List, { ref: n, className: N( @@ -2445,9 +2446,9 @@ const Ri = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( ...e } )); -Ri.displayName = Rt.List.displayName; +$i.displayName = _t.List.displayName; const ed = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( - Rt.Trigger, + _t.Trigger, { ref: n, ...e, @@ -2456,8 +2457,8 @@ const ed = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( t ) } -)), _i = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( - Rt.Content, +)), Ai = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( + _t.Content, { ref: n, className: N( @@ -2468,7 +2469,7 @@ const ed = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( ...e } )); -_i.displayName = Rt.Content.displayName; +Ai.displayName = _t.Content.displayName; function Th({ tabList: t, onSearch: e, @@ -2489,14 +2490,14 @@ function Th({ } ) ] }), - /* @__PURE__ */ x(Oi, { dir: a, children: [ - /* @__PURE__ */ s(Ri, { children: t.map((i) => /* @__PURE__ */ s(ed, { value: i.value, children: i.value }, i.key)) }), - t.map((i) => /* @__PURE__ */ s(_i, { value: i.value, children: i.content }, i.key)) + /* @__PURE__ */ x(Pi, { dir: a, children: [ + /* @__PURE__ */ s($i, { children: t.map((i) => /* @__PURE__ */ s(ed, { value: i.value, children: i.value }, i.key)) }), + t.map((i) => /* @__PURE__ */ s(Ai, { value: i.value, children: i.content }, i.key)) ] }) ] }); } -const wo = T.forwardRef(({ className: t, orientation: e = "horizontal", decorative: n = !0, ...r }, o) => /* @__PURE__ */ s( - ni.Root, +const go = T.forwardRef(({ className: t, orientation: e = "horizontal", decorative: n = !0, ...r }, o) => /* @__PURE__ */ s( + ai.Root, { ref: o, decorative: n, @@ -2509,8 +2510,8 @@ const wo = T.forwardRef(({ className: t, orientation: e = "horizontal", decorati ...r } )); -wo.displayName = ni.Root.displayName; -const nd = vt.Root, rd = vt.Portal, Pi = M.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( +go.displayName = ai.Root.displayName; +const nd = vt.Root, rd = vt.Portal, Ii = M.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( vt.Overlay, { className: N( @@ -2521,7 +2522,7 @@ const nd = vt.Root, rd = vt.Portal, Pi = M.forwardRef(({ className: t, ...e }, n ref: n } )); -Pi.displayName = vt.Overlay.displayName; +Ii.displayName = vt.Overlay.displayName; const od = Xe( "pr-twp tw-fixed tw-z-50 tw-gap-4 tw-bg-background tw-p-6 tw-shadow-lg tw-transition tw-ease-in-out data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-duration-300 data-[state=open]:tw-duration-500", { @@ -2537,17 +2538,17 @@ const od = Xe( side: "right" } } -), $i = M.forwardRef(({ side: t = "right", className: e, children: n, ...r }, o) => /* @__PURE__ */ x(rd, { children: [ - /* @__PURE__ */ s(Pi, {}), +), Mi = M.forwardRef(({ side: t = "right", className: e, children: n, ...r }, o) => /* @__PURE__ */ x(rd, { children: [ + /* @__PURE__ */ s(Ii, {}), /* @__PURE__ */ x(vt.Content, { ref: o, className: N(od({ side: t }), e), ...r, children: [ n, /* @__PURE__ */ x(vt.Close, { className: "tw-absolute tw-right-4 tw-top-4 tw-rounded-sm tw-opacity-70 tw-ring-offset-background tw-transition-opacity hover:tw-opacity-100 focus:tw-outline-none focus:tw-ring-2 focus:tw-ring-ring focus:tw-ring-offset-2 disabled:tw-pointer-events-none data-[state=open]:tw-bg-secondary", children: [ - /* @__PURE__ */ s(Ka, { className: "tw-h-4 tw-w-4" }), + /* @__PURE__ */ s(Qa, { className: "tw-h-4 tw-w-4" }), /* @__PURE__ */ s("span", { className: "tw-sr-only", children: "Close" }) ] }) ] }) ] })); -$i.displayName = vt.Content.displayName; +Mi.displayName = vt.Content.displayName; const ad = M.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( vt.Title, { @@ -2566,7 +2567,7 @@ const id = M.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( } )); id.displayName = vt.Description.displayName; -function na({ className: t, ...e }) { +function aa({ className: t, ...e }) { return /* @__PURE__ */ s( "div", { @@ -2575,7 +2576,7 @@ function na({ className: t, ...e }) { } ); } -const sd = En.Provider, ld = En.Root, cd = En.Trigger, Ii = T.forwardRef(({ className: t, sideOffset: e = 4, ...n }, r) => /* @__PURE__ */ s( +const sd = En.Provider, ld = En.Root, cd = En.Trigger, Di = T.forwardRef(({ className: t, sideOffset: e = 4, ...n }, r) => /* @__PURE__ */ s( En.Content, { ref: r, @@ -2587,7 +2588,7 @@ const sd = En.Provider, ld = En.Root, cd = En.Trigger, Ii = T.forwardRef(({ clas ...n } )); -Ii.displayName = En.Content.displayName; +Di.displayName = En.Content.displayName; const $r = 768; function dd() { const [t, e] = M.useState(void 0); @@ -2598,14 +2599,14 @@ function dd() { return n.addEventListener("change", r), e(window.innerWidth < $r), () => n.removeEventListener("change", r); }, []), !!t; } -const pd = "sidebar:state", ud = 60 * 60 * 24 * 7, wd = "16rem", fd = "18rem", md = "3rem", hd = "b", Ai = T.createContext(void 0); +const pd = "sidebar:state", ud = 60 * 60 * 24 * 7, wd = "16rem", fd = "18rem", md = "3rem", hd = "b", Bi = T.createContext(void 0); function cr() { - const t = T.useContext(Ai); + const t = T.useContext(Bi); if (!t) throw new Error("useSidebar must be used within a SidebarProvider."); return t; } -const Mi = T.forwardRef( +const ji = T.forwardRef( ({ defaultOpen: t = !0, open: e, @@ -2615,7 +2616,7 @@ const Mi = T.forwardRef( children: a, ...i }, l) => { - const c = dd(), [d, p] = T.useState(!1), [m, w] = T.useState(t), g = e ?? m, v = T.useCallback( + const c = dd(), [d, p] = T.useState(!1), [h, w] = T.useState(t), g = e ?? h, v = T.useCallback( (_) => { const C = typeof _ == "function" ? _(g) : _; n ? n(C) : w(C), document.cookie = `${pd}=${C}; path=/; max-age=${ud}`; @@ -2628,9 +2629,9 @@ const Mi = T.forwardRef( }; return window.addEventListener("keydown", _), () => window.removeEventListener("keydown", _); }, [f]); - const h = g ? "expanded" : "collapsed", E = T.useMemo( + const m = g ? "expanded" : "collapsed", E = T.useMemo( () => ({ - state: h, + state: m, open: g, setOpen: v, isMobile: c, @@ -2638,9 +2639,9 @@ const Mi = T.forwardRef( setOpenMobile: p, toggleSidebar: f }), - [h, g, v, c, d, p, f] + [m, g, v, c, d, p, f] ); - return /* @__PURE__ */ s(Ai.Provider, { value: E, children: /* @__PURE__ */ s(sd, { delayDuration: 0, children: /* @__PURE__ */ s( + return /* @__PURE__ */ s(Bi.Provider, { value: E, children: /* @__PURE__ */ s(sd, { delayDuration: 0, children: /* @__PURE__ */ s( "div", { style: ( @@ -2662,8 +2663,8 @@ const Mi = T.forwardRef( ) }) }); } ); -Mi.displayName = "SidebarProvider"; -const Di = T.forwardRef( +ji.displayName = "SidebarProvider"; +const Vi = T.forwardRef( ({ side: t = "left", variant: e = "sidebar", @@ -2685,7 +2686,7 @@ const Di = T.forwardRef( children: o } ) : l ? /* @__PURE__ */ s(nd, { open: d, onOpenChange: p, ...a, children: /* @__PURE__ */ s( - $i, + Mi, { "data-sidebar": "sidebar", "data-mobile": "true", @@ -2747,7 +2748,7 @@ const Di = T.forwardRef( ); } ); -Di.displayName = "Sidebar"; +Vi.displayName = "Sidebar"; const gd = T.forwardRef(({ className: t, onClick: e, ...n }, r) => { const { toggleSidebar: o } = cr(); return /* @__PURE__ */ x( @@ -2798,7 +2799,7 @@ const bd = T.forwardRef( } ); bd.displayName = "SidebarRail"; -const Bi = T.forwardRef( +const zi = T.forwardRef( ({ className: t, ...e }, n) => /* @__PURE__ */ s( "main", { @@ -2812,7 +2813,7 @@ const Bi = T.forwardRef( } ) ); -Bi.displayName = "SidebarInset"; +zi.displayName = "SidebarInset"; const vd = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( Ye, { @@ -2851,7 +2852,7 @@ const xd = T.forwardRef( ); xd.displayName = "SidebarFooter"; const Nd = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( - wo, + go, { ref: n, "data-sidebar": "separator", @@ -2860,7 +2861,7 @@ const Nd = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( } )); Nd.displayName = "SidebarSeparator"; -const ji = T.forwardRef( +const Li = T.forwardRef( ({ className: t, ...e }, n) => /* @__PURE__ */ s( "div", { @@ -2874,8 +2875,8 @@ const ji = T.forwardRef( } ) ); -ji.displayName = "SidebarContent"; -const Vi = T.forwardRef( +Li.displayName = "SidebarContent"; +const Kr = T.forwardRef( ({ className: t, ...e }, n) => /* @__PURE__ */ s( "div", { @@ -2886,8 +2887,8 @@ const Vi = T.forwardRef( } ) ); -Vi.displayName = "SidebarGroup"; -const zi = T.forwardRef(({ className: t, asChild: e = !1, ...n }, r) => /* @__PURE__ */ s( +Kr.displayName = "SidebarGroup"; +const Jr = T.forwardRef(({ className: t, asChild: e = !1, ...n }, r) => /* @__PURE__ */ s( e ? He : "div", { ref: r, @@ -2900,7 +2901,7 @@ const zi = T.forwardRef(({ className: t, asChild: e = !1, ...n }, r) => /* @__PU ...n } )); -zi.displayName = "SidebarGroupLabel"; +Jr.displayName = "SidebarGroupLabel"; const kd = T.forwardRef(({ className: t, asChild: e = !1, ...n }, r) => /* @__PURE__ */ s( e ? He : "button", { @@ -2917,7 +2918,7 @@ const kd = T.forwardRef(({ className: t, asChild: e = !1, ...n }, r) => /* @__PU } )); kd.displayName = "SidebarGroupAction"; -const Li = T.forwardRef( +const Zr = T.forwardRef( ({ className: t, ...e }, n) => /* @__PURE__ */ s( "div", { @@ -2928,7 +2929,7 @@ const Li = T.forwardRef( } ) ); -Li.displayName = "SidebarGroupContent"; +Zr.displayName = "SidebarGroupContent"; const Fi = T.forwardRef( ({ className: t, ...e }, n) => /* @__PURE__ */ s( "ul", @@ -2982,7 +2983,7 @@ const Ed = Xe( className: a, ...i }, l) => { - const c = t ? He : "button", { isMobile: d, state: p } = cr(), m = /* @__PURE__ */ s( + const c = t ? He : "button", { isMobile: d, state: p } = cr(), h = /* @__PURE__ */ s( c, { ref: l, @@ -2996,9 +2997,9 @@ const Ed = Xe( return o ? (typeof o == "string" && (o = { children: o }), /* @__PURE__ */ x(ld, { children: [ - /* @__PURE__ */ s(cd, { asChild: !0, children: m }), + /* @__PURE__ */ s(cd, { asChild: !0, children: h }), /* @__PURE__ */ s( - Ii, + Di, { side: "right", align: "center", @@ -3006,7 +3007,7 @@ const Ed = Xe( ...o } ) - ] })) : m; + ] })) : h; } ); Gi.displayName = "SidebarMenuButton"; @@ -3060,9 +3061,9 @@ const Cd = T.forwardRef(({ className: t, showIcon: e = !1, ...n }, r) => { className: N("tw-flex tw-h-8 tw-items-center tw-gap-2 tw-rounded-md tw-px-2", t), ...n, children: [ - e && /* @__PURE__ */ s(na, { className: "tw-size-4 tw-rounded-md", "data-sidebar": "menu-skeleton-icon" }), + e && /* @__PURE__ */ s(aa, { className: "tw-size-4 tw-rounded-md", "data-sidebar": "menu-skeleton-icon" }), /* @__PURE__ */ s( - na, + aa, { className: "tw-h-4 tw-max-w-[--skeleton-width] tw-flex-1", "data-sidebar": "menu-skeleton-text", @@ -3121,52 +3122,83 @@ _d.displayName = "SidebarMenuSubButton"; function Pd({ id: t, extensionLabels: e, - // projectLabels, - handleSelectSidebarItem: n + projectOptions: n, + handleSelectSidebarItem: r, + selectedSidebarItem: o }) { - const [r, o] = ut(), a = (i, l) => { - o(i), n(i, l); - }; - return /* @__PURE__ */ s(Di, { id: t, collapsible: "offcanvas", variant: "sidebar", children: /* @__PURE__ */ s(ji, { children: /* @__PURE__ */ x(Vi, { children: [ - /* @__PURE__ */ s(zi, { children: "Extensions" }), - /* @__PURE__ */ s(Li, { children: /* @__PURE__ */ s(Fi, { children: e.map((i) => /* @__PURE__ */ s(Ui, { children: /* @__PURE__ */ s( - Gi, - { - onClick: () => a(i, !1), - isActive: i === r, - children: i - } - ) }, i)) }) }) - ] }) }) }); + const a = Tt( + (l, c) => { + r(l, c); + }, + [r] + ), i = Tt( + (l) => { + const c = n.find((d) => d.projectId === l); + return c ? c.projectName : l; + }, + [n] + ); + return /* @__PURE__ */ s(Vi, { id: t, collapsible: "offcanvas", variant: "sidebar", children: /* @__PURE__ */ x(Li, { children: [ + /* @__PURE__ */ x(Kr, { children: [ + /* @__PURE__ */ s(Jr, { children: "Extensions" }), + /* @__PURE__ */ s(Zr, { children: /* @__PURE__ */ s(Fi, { children: e.map((l) => /* @__PURE__ */ s(Ui, { children: /* @__PURE__ */ s( + Gi, + { + onClick: () => a(l), + isActive: !(o != null && o.projectId) && l === (o == null ? void 0 : o.label), + children: l + } + ) }, l)) }) }) + ] }), + /* @__PURE__ */ x(Kr, { children: [ + /* @__PURE__ */ s(Jr, { children: "Projects" }), + /* @__PURE__ */ s(Zr, { children: /* @__PURE__ */ s( + qr, + { + popoverContentClassName: "tw-z-[1000]", + options: n.flatMap((l) => l.projectId), + getOptionLabel: (l) => i(l), + buttonPlaceholder: "Type or select project", + onChange: (l) => { + const c = i(l); + a(c, l); + }, + value: (o == null ? void 0 : o.projectId) ?? void 0 + } + ) }) + ] }) + ] }) }); } function Ch({ - direction: t = "ltr", - extensionLabels: e, - // projectLabels, - children: n, - handleSelectSidebarItem: r - // renderSettingsProperties, - // renderProjectSettingsProperties. + id: t, + direction: e = "ltr", + extensionLabels: n, + projectOptions: r, + children: o, + handleSelectSidebarItem: a, + selectedSidebarItem: i }) { - return /* @__PURE__ */ x(Mi, { dir: t, children: [ + return /* @__PURE__ */ x(ji, { dir: e, id: t, children: [ /* @__PURE__ */ s( Pd, { - extensionLabels: e, - handleSelectSidebarItem: r + extensionLabels: n, + projectOptions: r, + handleSelectSidebarItem: a, + selectedSidebarItem: i } ), - /* @__PURE__ */ s(Bi, { children: n }) + /* @__PURE__ */ s(zi, { children: o }) ] }); } -const ne = "scrBook", $d = "scrRef", we = "source", Id = "details", Ad = "Scripture Reference", Md = "Scripture Book", Hi = "Type", Dd = "Details"; +const ne = "scrBook", $d = "scrRef", we = "source", Ad = "details", Id = "Scripture Reference", Md = "Scripture Book", Hi = "Type", Dd = "Details"; function Bd(t, e) { const n = e ?? !1; return [ { accessorFn: (r) => `${ot.bookNumberToId(r.start.bookNum)} ${r.start.chapterNum}:${r.start.verseNum}`, id: ne, - header: (t == null ? void 0 : t.scriptureReferenceColumnName) ?? Ad, + header: (t == null ? void 0 : t.scriptureReferenceColumnName) ?? Id, cell: (r) => { const o = r.row.original; return r.row.getIsGrouped() ? ot.bookNumberToEnglishName(o.start.bookNum) : r.row.groupingColumnId === ne ? Or(o.start) : void 0; @@ -3197,7 +3229,7 @@ function Bd(t, e) { }, { accessorFn: (r) => r.detail, - id: Id, + id: Ad, header: (t == null ? void 0 : t.detailsColumnName) ?? Dd, cell: (r) => r.getValue(), enableGrouping: !1 @@ -3212,7 +3244,7 @@ const jd = (t) => { const { offset: e } = t.start; let n = 0; return t.end && ({ offset: n } = t.end), !t.end || Hr(t.start, t.end) === 0 ? `${Rr(t.start)}+${e}` : `${Rr(t.start)}+${e}-${Rr(t.end)}+${n}`; -}, ra = (t) => `${jd({ start: t.start, end: t.end })} ${t.source.displayName} ${t.detail}`; +}, ia = (t) => `${jd({ start: t.start, end: t.end })} ${t.source.displayName} ${t.detail}`; function Oh({ sources: t, showColumnHeaders: e = !1, @@ -3224,13 +3256,13 @@ function Oh({ onRowSelected: l, direction: c = "ltr" }) { - const [d, p] = ut([]), [m, w] = ut([{ id: ne, desc: !1 }]), [g, v] = ut({}), f = $t( + const [d, p] = ut([]), [h, w] = ut([{ id: ne, desc: !1 }]), [g, v] = ut({}), f = At( () => t.flatMap((O) => O.data.map(($) => ({ ...$, source: O.source }))), [t] - ), h = $t( + ), m = At( () => Bd( { scriptureReferenceColumnName: r, @@ -3247,12 +3279,12 @@ function Oh({ { id: ne, desc: !1 } ]) : w([{ id: ne, desc: !1 }]); }, [d]); - const E = Za({ + const E = ei({ data: f, - columns: h, + columns: m, state: { grouping: d, - sorting: m, + sorting: h, rowSelection: g }, onGroupingChange: p, @@ -3260,9 +3292,9 @@ function Oh({ onRowSelectionChange: v, getExpandedRowModel: Ml(), getGroupedRowModel: Dl(), - getCoreRowModel: Qa(), - getSortedRowModel: ti(), - getRowId: ra, + getCoreRowModel: ni(), + getSortedRowModel: ri(), + getRowId: ia, autoResetExpanded: !1, enableMultiRowSelection: !1, enableSubRowSelection: !1 @@ -3271,7 +3303,7 @@ function Oh({ if (l) { const O = E.getSelectedRowModel().rowsById, $ = Object.keys(O); if ($.length === 1) { - const k = f.find((B) => ra(B) === $[0]) || void 0; + const k = f.find((B) => ia(B) === $[0]) || void 0; k && l(k); } } @@ -3290,7 +3322,7 @@ function Oh({ } ], b = (O) => { p(JSON.parse(O)); - }, I = (O, $) => { + }, A = (O, $) => { !O.getIsGrouped() && !O.getIsSelected() && O.getToggleSelectedHandler()($); }, z = (O, $) => O.getIsGrouped() ? "" : N("banded-row", $ % 2 === 0 ? "even" : "odd"), H = (O, $, k) => { if (!((O == null ? void 0 : O.length) === 0 || $.depth < k.column.getGroupedIndex())) { @@ -3348,7 +3380,7 @@ function Oh({ { "data-state": O.getIsSelected() ? "selected" : "", className: N(z(O, $)), - onClick: (k) => I(O, k), + onClick: (k) => A(O, k), children: O.getVisibleCells().map((k) => { if (!(k.getIsPlaceholder() || k.column.columnDef.enableGrouping && !k.getIsGrouped() && (k.column.columnDef.id !== we || !n))) return /* @__PURE__ */ s( @@ -3367,7 +3399,7 @@ function Oh({ type: "button", children: [ O.getIsExpanded() && /* @__PURE__ */ s(er, {}), - !O.getIsExpanded() && (c === "ltr" ? /* @__PURE__ */ s(Wa, {}) : /* @__PURE__ */ s(vl, {})), + !O.getIsExpanded() && (c === "ltr" ? /* @__PURE__ */ s(Ja, {}) : /* @__PURE__ */ s(vl, {})), " ", dn(k.column.columnDef.cell, k.getContext()), " (", @@ -3386,7 +3418,7 @@ function Oh({ ] }) ] }); } -const Ir = { +const Ar = { [pt("undefined")]: "Ø", [pt(0)]: "A", [pt(1)]: "B", @@ -3422,12 +3454,12 @@ function Rh({ localizedStrings: r = {} }) { const o = { - ...Ir, + ...Ar, ...Object.fromEntries( Object.entries(r).map( ([a, i]) => [ a, - a === i && a in Ir ? Ir[a] : i + a === i && a in Ar ? Ar[a] : i ] ) ) @@ -3485,7 +3517,7 @@ function $h({ /* @__PURE__ */ s("h3", { className: "tw-text-lg tw-font-medium", children: t }), /* @__PURE__ */ s("p", { className: "tw-text-sm tw-text-muted-foreground", children: e }) ] }), - n ? /* @__PURE__ */ s(wo, {}) : "" + n ? /* @__PURE__ */ s(go, {}) : "" ] }); } const Xi = T.forwardRef( @@ -3545,20 +3577,21 @@ const zd = T.forwardRef( ) ); zd.displayName = "CardFooter"; -function Ih({ - settingsGroupLabel: t, - settingsGroupDescription: e, - children: n +function Ah({ + id: t, + settingsGroupLabel: e, + settingsGroupDescription: n, + children: r }) { - return /* @__PURE__ */ x(Xi, { children: [ + return /* @__PURE__ */ x(Xi, { id: t, children: [ /* @__PURE__ */ x(Yi, { children: [ - /* @__PURE__ */ s(Wi, { children: t }), - /* @__PURE__ */ s(qi, { children: e }) + /* @__PURE__ */ s(Wi, { children: e }), + n && /* @__PURE__ */ s(qi, { children: n }) ] }), - /* @__PURE__ */ s(Bl, { className: "tw-space-y-4", children: n }) + /* @__PURE__ */ s(Bl, { className: "tw-space-y-4", children: r }) ] }); } -function Ah({ +function Ih({ id: t, className: e, listItems: n, @@ -3568,7 +3601,7 @@ function Ah({ }) { return /* @__PURE__ */ s("div", { id: t, className: e, children: n.map((i) => /* @__PURE__ */ x("div", { className: "tw-m-2 tw-flex tw-items-center", children: [ /* @__PURE__ */ s( - uo, + ho, { className: "tw-mr-2 tw-align-middle", checked: r.includes(i), @@ -3602,7 +3635,7 @@ function Fd(t) { }); }), n; } -var fo = {}, Ki = { exports: {} }; +var bo = {}, Ki = { exports: {} }; (function(t) { function e(n) { return n && n.__esModule ? n : { @@ -3611,8 +3644,8 @@ var fo = {}, Ki = { exports: {} }; } t.exports = e, t.exports.__esModule = !0, t.exports.default = t.exports; })(Ki); -var Ud = Ki.exports, Ar = {}; -function mo(t, e) { +var Ud = Ki.exports, Ir = {}; +function vo(t, e) { return process.env.NODE_ENV === "production" ? () => null : function(...r) { return t(...r) || e(...r); }; @@ -3649,7 +3682,7 @@ function Zt(t, e, n = { o !== "__proto__" && (he(e[o]) && o in t && he(t[o]) ? r[o] = Zt(t[o], e[o], n) : n.clone ? r[o] = he(e[o]) ? Ji(e[o]) : e[o] : r[o] = e[o]); }), r; } -var qr = { exports: {} }, jn = { exports: {} }, it = {}; +var Qr = { exports: {} }, jn = { exports: {} }, it = {}; /** @license React v16.13.1 * react-is.production.min.js * @@ -3658,16 +3691,16 @@ var qr = { exports: {} }, jn = { exports: {} }, it = {}; * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. */ -var oa; +var sa; function Gd() { - if (oa) + if (sa) return it; - oa = 1; - var t = typeof Symbol == "function" && Symbol.for, e = t ? Symbol.for("react.element") : 60103, n = t ? Symbol.for("react.portal") : 60106, r = t ? Symbol.for("react.fragment") : 60107, o = t ? Symbol.for("react.strict_mode") : 60108, a = t ? Symbol.for("react.profiler") : 60114, i = t ? Symbol.for("react.provider") : 60109, l = t ? Symbol.for("react.context") : 60110, c = t ? Symbol.for("react.async_mode") : 60111, d = t ? Symbol.for("react.concurrent_mode") : 60111, p = t ? Symbol.for("react.forward_ref") : 60112, m = t ? Symbol.for("react.suspense") : 60113, w = t ? Symbol.for("react.suspense_list") : 60120, g = t ? Symbol.for("react.memo") : 60115, v = t ? Symbol.for("react.lazy") : 60116, f = t ? Symbol.for("react.block") : 60121, h = t ? Symbol.for("react.fundamental") : 60117, E = t ? Symbol.for("react.responder") : 60118, _ = t ? Symbol.for("react.scope") : 60119; + sa = 1; + var t = typeof Symbol == "function" && Symbol.for, e = t ? Symbol.for("react.element") : 60103, n = t ? Symbol.for("react.portal") : 60106, r = t ? Symbol.for("react.fragment") : 60107, o = t ? Symbol.for("react.strict_mode") : 60108, a = t ? Symbol.for("react.profiler") : 60114, i = t ? Symbol.for("react.provider") : 60109, l = t ? Symbol.for("react.context") : 60110, c = t ? Symbol.for("react.async_mode") : 60111, d = t ? Symbol.for("react.concurrent_mode") : 60111, p = t ? Symbol.for("react.forward_ref") : 60112, h = t ? Symbol.for("react.suspense") : 60113, w = t ? Symbol.for("react.suspense_list") : 60120, g = t ? Symbol.for("react.memo") : 60115, v = t ? Symbol.for("react.lazy") : 60116, f = t ? Symbol.for("react.block") : 60121, m = t ? Symbol.for("react.fundamental") : 60117, E = t ? Symbol.for("react.responder") : 60118, _ = t ? Symbol.for("react.scope") : 60119; function C(b) { if (typeof b == "object" && b !== null) { - var I = b.$$typeof; - switch (I) { + var A = b.$$typeof; + switch (A) { case e: switch (b = b.type, b) { case c: @@ -3675,7 +3708,7 @@ function Gd() { case r: case a: case o: - case m: + case h: return b; default: switch (b = b && b.$$typeof, b) { @@ -3686,18 +3719,18 @@ function Gd() { case i: return b; default: - return I; + return A; } } case n: - return I; + return A; } } } function S(b) { return C(b) === d; } - return it.AsyncMode = c, it.ConcurrentMode = d, it.ContextConsumer = l, it.ContextProvider = i, it.Element = e, it.ForwardRef = p, it.Fragment = r, it.Lazy = v, it.Memo = g, it.Portal = n, it.Profiler = a, it.StrictMode = o, it.Suspense = m, it.isAsyncMode = function(b) { + return it.AsyncMode = c, it.ConcurrentMode = d, it.ContextConsumer = l, it.ContextProvider = i, it.Element = e, it.ForwardRef = p, it.Fragment = r, it.Lazy = v, it.Memo = g, it.Portal = n, it.Profiler = a, it.StrictMode = o, it.Suspense = h, it.isAsyncMode = function(b) { return S(b) || C(b) === c; }, it.isConcurrentMode = S, it.isContextConsumer = function(b) { return C(b) === l; @@ -3720,9 +3753,9 @@ function Gd() { }, it.isStrictMode = function(b) { return C(b) === o; }, it.isSuspense = function(b) { - return C(b) === m; + return C(b) === h; }, it.isValidElementType = function(b) { - return typeof b == "string" || typeof b == "function" || b === r || b === d || b === a || b === o || b === m || b === w || typeof b == "object" && b !== null && (b.$$typeof === v || b.$$typeof === g || b.$$typeof === i || b.$$typeof === l || b.$$typeof === p || b.$$typeof === h || b.$$typeof === E || b.$$typeof === _ || b.$$typeof === f); + return typeof b == "string" || typeof b == "function" || b === r || b === d || b === a || b === o || b === h || b === w || typeof b == "object" && b !== null && (b.$$typeof === v || b.$$typeof === g || b.$$typeof === i || b.$$typeof === l || b.$$typeof === p || b.$$typeof === m || b.$$typeof === E || b.$$typeof === _ || b.$$typeof === f); }, it.typeOf = C, it; } var st = {}; @@ -3734,27 +3767,27 @@ var st = {}; * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. */ -var aa; +var la; function Hd() { - return aa || (aa = 1, process.env.NODE_ENV !== "production" && function() { - var t = typeof Symbol == "function" && Symbol.for, e = t ? Symbol.for("react.element") : 60103, n = t ? Symbol.for("react.portal") : 60106, r = t ? Symbol.for("react.fragment") : 60107, o = t ? Symbol.for("react.strict_mode") : 60108, a = t ? Symbol.for("react.profiler") : 60114, i = t ? Symbol.for("react.provider") : 60109, l = t ? Symbol.for("react.context") : 60110, c = t ? Symbol.for("react.async_mode") : 60111, d = t ? Symbol.for("react.concurrent_mode") : 60111, p = t ? Symbol.for("react.forward_ref") : 60112, m = t ? Symbol.for("react.suspense") : 60113, w = t ? Symbol.for("react.suspense_list") : 60120, g = t ? Symbol.for("react.memo") : 60115, v = t ? Symbol.for("react.lazy") : 60116, f = t ? Symbol.for("react.block") : 60121, h = t ? Symbol.for("react.fundamental") : 60117, E = t ? Symbol.for("react.responder") : 60118, _ = t ? Symbol.for("react.scope") : 60119; - function C(A) { - return typeof A == "string" || typeof A == "function" || // Note: its typeof might be other than 'symbol' or 'number' if it's a polyfill. - A === r || A === d || A === a || A === o || A === m || A === w || typeof A == "object" && A !== null && (A.$$typeof === v || A.$$typeof === g || A.$$typeof === i || A.$$typeof === l || A.$$typeof === p || A.$$typeof === h || A.$$typeof === E || A.$$typeof === _ || A.$$typeof === f); - } - function S(A) { - if (typeof A == "object" && A !== null) { - var Nt = A.$$typeof; + return la || (la = 1, process.env.NODE_ENV !== "production" && function() { + var t = typeof Symbol == "function" && Symbol.for, e = t ? Symbol.for("react.element") : 60103, n = t ? Symbol.for("react.portal") : 60106, r = t ? Symbol.for("react.fragment") : 60107, o = t ? Symbol.for("react.strict_mode") : 60108, a = t ? Symbol.for("react.profiler") : 60114, i = t ? Symbol.for("react.provider") : 60109, l = t ? Symbol.for("react.context") : 60110, c = t ? Symbol.for("react.async_mode") : 60111, d = t ? Symbol.for("react.concurrent_mode") : 60111, p = t ? Symbol.for("react.forward_ref") : 60112, h = t ? Symbol.for("react.suspense") : 60113, w = t ? Symbol.for("react.suspense_list") : 60120, g = t ? Symbol.for("react.memo") : 60115, v = t ? Symbol.for("react.lazy") : 60116, f = t ? Symbol.for("react.block") : 60121, m = t ? Symbol.for("react.fundamental") : 60117, E = t ? Symbol.for("react.responder") : 60118, _ = t ? Symbol.for("react.scope") : 60119; + function C(I) { + return typeof I == "string" || typeof I == "function" || // Note: its typeof might be other than 'symbol' or 'number' if it's a polyfill. + I === r || I === d || I === a || I === o || I === h || I === w || typeof I == "object" && I !== null && (I.$$typeof === v || I.$$typeof === g || I.$$typeof === i || I.$$typeof === l || I.$$typeof === p || I.$$typeof === m || I.$$typeof === E || I.$$typeof === _ || I.$$typeof === f); + } + function S(I) { + if (typeof I == "object" && I !== null) { + var Nt = I.$$typeof; switch (Nt) { case e: - var j = A.type; + var j = I.type; switch (j) { case c: case d: case r: case a: case o: - case m: + case h: return j; default: var xt = j && j.$$typeof; @@ -3774,63 +3807,63 @@ function Hd() { } } } - var b = c, I = d, z = l, H = i, O = e, $ = p, k = r, B = v, D = g, J = n, q = a, U = o, tt = m, at = !1; - function rt(A) { - return at || (at = !0, console.warn("The ReactIs.isAsyncMode() alias has been deprecated, and will be removed in React 17+. Update your code to use ReactIs.isConcurrentMode() instead. It has the exact same API.")), y(A) || S(A) === c; + var b = c, A = d, z = l, H = i, O = e, $ = p, k = r, B = v, D = g, J = n, q = a, U = o, tt = h, at = !1; + function rt(I) { + return at || (at = !0, console.warn("The ReactIs.isAsyncMode() alias has been deprecated, and will be removed in React 17+. Update your code to use ReactIs.isConcurrentMode() instead. It has the exact same API.")), y(I) || S(I) === c; } - function y(A) { - return S(A) === d; + function y(I) { + return S(I) === d; } - function R(A) { - return S(A) === l; + function R(I) { + return S(I) === l; } - function L(A) { - return S(A) === i; + function L(I) { + return S(I) === i; } - function F(A) { - return typeof A == "object" && A !== null && A.$$typeof === e; + function F(I) { + return typeof I == "object" && I !== null && I.$$typeof === e; } - function V(A) { - return S(A) === p; + function V(I) { + return S(I) === p; } - function W(A) { - return S(A) === r; + function W(I) { + return S(I) === r; } - function X(A) { - return S(A) === v; + function X(I) { + return S(I) === v; } - function Y(A) { - return S(A) === g; + function Y(I) { + return S(I) === g; } - function G(A) { - return S(A) === n; + function G(I) { + return S(I) === n; } - function K(A) { - return S(A) === a; + function K(I) { + return S(I) === a; } - function Z(A) { - return S(A) === o; + function Z(I) { + return S(I) === o; } - function dt(A) { - return S(A) === m; + function dt(I) { + return S(I) === h; } - st.AsyncMode = b, st.ConcurrentMode = I, st.ContextConsumer = z, st.ContextProvider = H, st.Element = O, st.ForwardRef = $, st.Fragment = k, st.Lazy = B, st.Memo = D, st.Portal = J, st.Profiler = q, st.StrictMode = U, st.Suspense = tt, st.isAsyncMode = rt, st.isConcurrentMode = y, st.isContextConsumer = R, st.isContextProvider = L, st.isElement = F, st.isForwardRef = V, st.isFragment = W, st.isLazy = X, st.isMemo = Y, st.isPortal = G, st.isProfiler = K, st.isStrictMode = Z, st.isSuspense = dt, st.isValidElementType = C, st.typeOf = S; + st.AsyncMode = b, st.ConcurrentMode = A, st.ContextConsumer = z, st.ContextProvider = H, st.Element = O, st.ForwardRef = $, st.Fragment = k, st.Lazy = B, st.Memo = D, st.Portal = J, st.Profiler = q, st.StrictMode = U, st.Suspense = tt, st.isAsyncMode = rt, st.isConcurrentMode = y, st.isContextConsumer = R, st.isContextProvider = L, st.isElement = F, st.isForwardRef = V, st.isFragment = W, st.isLazy = X, st.isMemo = Y, st.isPortal = G, st.isProfiler = K, st.isStrictMode = Z, st.isSuspense = dt, st.isValidElementType = C, st.typeOf = S; }()), st; } -var ia; +var ca; function Zi() { - return ia || (ia = 1, process.env.NODE_ENV === "production" ? jn.exports = Gd() : jn.exports = Hd()), jn.exports; + return ca || (ca = 1, process.env.NODE_ENV === "production" ? jn.exports = Gd() : jn.exports = Hd()), jn.exports; } /* object-assign (c) Sindre Sorhus @license MIT */ -var Mr, sa; +var Mr, da; function Xd() { - if (sa) + if (da) return Mr; - sa = 1; + da = 1; var t = Object.getOwnPropertySymbols, e = Object.prototype.hasOwnProperty, n = Object.prototype.propertyIsEnumerable; function r(a) { if (a == null) @@ -3862,8 +3895,8 @@ function Xd() { return Mr = o() ? Object.assign : function(a, i) { for (var l, c = r(a), d, p = 1; p < arguments.length; p++) { l = Object(arguments[p]); - for (var m in l) - e.call(l, m) && (c[m] = l[m]); + for (var h in l) + e.call(l, h) && (c[h] = l[h]); if (t) { d = t(l); for (var w = 0; w < d.length; w++) @@ -3873,27 +3906,27 @@ function Xd() { return c; }, Mr; } -var Dr, la; -function ho() { - if (la) +var Dr, pa; +function yo() { + if (pa) return Dr; - la = 1; + pa = 1; var t = "SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED"; return Dr = t, Dr; } -var Br, ca; +var Br, ua; function Qi() { - return ca || (ca = 1, Br = Function.call.bind(Object.prototype.hasOwnProperty)), Br; + return ua || (ua = 1, Br = Function.call.bind(Object.prototype.hasOwnProperty)), Br; } -var jr, da; +var jr, wa; function Yd() { - if (da) + if (wa) return jr; - da = 1; + wa = 1; var t = function() { }; if (process.env.NODE_ENV !== "production") { - var e = ho(), n = {}, r = Qi(); + var e = yo(), n = {}, r = Qi(); t = function(a) { var i = "Warning: " + a; typeof console < "u" && console.error(i); @@ -3907,7 +3940,7 @@ function Yd() { if (process.env.NODE_ENV !== "production") { for (var p in a) if (r(a, p)) { - var m; + var h; try { if (typeof a[p] != "function") { var w = Error( @@ -3915,17 +3948,17 @@ function Yd() { ); throw w.name = "Invariant Violation", w; } - m = a[p](i, p, c, l, null, e); + h = a[p](i, p, c, l, null, e); } catch (v) { - m = v; + h = v; } - if (m && !(m instanceof Error) && t( - (c || "React class") + ": type specification of " + l + " `" + p + "` is invalid; the type checker function must return `null` or an `Error` but returned a " + typeof m + ". You may have forgotten to pass an argument to the type checker creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and shape all require an argument)." - ), m instanceof Error && !(m.message in n)) { - n[m.message] = !0; + if (h && !(h instanceof Error) && t( + (c || "React class") + ": type specification of " + l + " `" + p + "` is invalid; the type checker function must return `null` or an `Error` but returned a " + typeof h + ". You may have forgotten to pass an argument to the type checker creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and shape all require an argument)." + ), h instanceof Error && !(h.message in n)) { + n[h.message] = !0; var g = d ? d() : ""; t( - "Failed " + l + " type: " + m.message + (g ?? "") + "Failed " + l + " type: " + h.message + (g ?? "") ); } } @@ -3935,12 +3968,12 @@ function Yd() { process.env.NODE_ENV !== "production" && (n = {}); }, jr = o, jr; } -var Vr, pa; +var Vr, fa; function Wd() { - if (pa) + if (fa) return Vr; - pa = 1; - var t = Zi(), e = Xd(), n = ho(), r = Qi(), o = Yd(), a = function() { + fa = 1; + var t = Zi(), e = Xd(), n = yo(), r = Qi(), o = Yd(), a = function() { }; process.env.NODE_ENV !== "production" && (a = function(l) { var c = "Warning: " + l; @@ -3955,7 +3988,7 @@ function Wd() { } return Vr = function(l, c) { var d = typeof Symbol == "function" && Symbol.iterator, p = "@@iterator"; - function m(y) { + function h(y) { var R = y && (d && y[d] || y[p]); if (typeof R == "function") return R; @@ -3973,7 +4006,7 @@ function Wd() { arrayOf: C, element: S(), elementType: b(), - instanceOf: I, + instanceOf: A, node: $(), objectOf: H, oneOf: z, @@ -3988,16 +4021,16 @@ function Wd() { this.message = y, this.data = R && typeof R == "object" ? R : {}, this.stack = ""; } f.prototype = Error.prototype; - function h(y) { + function m(y) { if (process.env.NODE_ENV !== "production") var R = {}, L = 0; function F(W, X, Y, G, K, Z, dt) { if (G = G || w, Z = Z || Y, dt !== n) { if (c) { - var A = new Error( + var I = new Error( "Calling PropTypes validators directly is not supported by the `prop-types` package. Use `PropTypes.checkPropTypes()` to call them. Read more at http://fb.me/use-check-prop-types" ); - throw A.name = "Invariant Violation", A; + throw I.name = "Invariant Violation", I; } else if (process.env.NODE_ENV !== "production" && typeof console < "u") { var Nt = G + ":" + Y; !R[Nt] && // Avoid spamming the console because they are often not actionable except for lib authors @@ -4023,10 +4056,10 @@ function Wd() { } return null; } - return h(R); + return m(R); } function _() { - return h(i); + return m(i); } function C(y) { function R(L, F, V, W, X) { @@ -4044,7 +4077,7 @@ function Wd() { } return null; } - return h(R); + return m(R); } function S() { function y(R, L, F, V, W) { @@ -4055,7 +4088,7 @@ function Wd() { } return null; } - return h(y); + return m(y); } function b() { function y(R, L, F, V, W) { @@ -4066,9 +4099,9 @@ function Wd() { } return null; } - return h(y); + return m(y); } - function I(y) { + function A(y) { function R(L, F, V, W, X) { if (!(L[F] instanceof y)) { var Y = y.name || w, G = rt(L[F]); @@ -4076,7 +4109,7 @@ function Wd() { } return null; } - return h(R); + return m(R); } function z(y) { if (!Array.isArray(y)) @@ -4087,13 +4120,13 @@ function Wd() { for (var Y = L[F], G = 0; G < y.length; G++) if (v(Y, y[G])) return null; - var K = JSON.stringify(y, function(dt, A) { - var Nt = tt(A); - return Nt === "symbol" ? String(A) : A; + var K = JSON.stringify(y, function(dt, I) { + var Nt = tt(I); + return Nt === "symbol" ? String(I) : I; }); return new f("Invalid " + W + " `" + X + "` of value `" + String(Y) + "` " + ("supplied to `" + V + "`, expected one of " + K + ".")); } - return h(R); + return m(R); } function H(y) { function R(L, F, V, W, X) { @@ -4110,7 +4143,7 @@ function Wd() { } return null; } - return h(R); + return m(R); } function O(y) { if (!Array.isArray(y)) @@ -4124,21 +4157,21 @@ function Wd() { } function F(V, W, X, Y, G) { for (var K = [], Z = 0; Z < y.length; Z++) { - var dt = y[Z], A = dt(V, W, X, Y, G, n); - if (A == null) + var dt = y[Z], I = dt(V, W, X, Y, G, n); + if (I == null) return null; - A.data && r(A.data, "expectedType") && K.push(A.data.expectedType); + I.data && r(I.data, "expectedType") && K.push(I.data.expectedType); } var Nt = K.length > 0 ? ", expected one of type [" + K.join(", ") + "]" : ""; return new f("Invalid " + Y + " `" + G + "` supplied to " + ("`" + X + "`" + Nt + ".")); } - return h(F); + return m(F); } function $() { function y(R, L, F, V, W) { return J(R[L]) ? null : new f("Invalid " + V + " `" + W + "` supplied to " + ("`" + F + "`, expected a ReactNode.")); } - return h(y); + return m(y); } function k(y, R, L, F, V) { return new f( @@ -4160,7 +4193,7 @@ function Wd() { } return null; } - return h(R); + return m(R); } function D(y) { function R(L, F, V, W, X) { @@ -4177,13 +4210,13 @@ function Wd() { "Invalid " + W + " `" + X + "` key `" + Z + "` supplied to `" + V + "`.\nBad object: " + JSON.stringify(L[F], null, " ") + ` Valid keys: ` + JSON.stringify(Object.keys(y), null, " ") ); - var A = dt(Y, Z, V, W, X + "." + Z, n); - if (A) - return A; + var I = dt(Y, Z, V, W, X + "." + Z, n); + if (I) + return I; } return null; } - return h(R); + return m(R); } function J(y) { switch (typeof y) { @@ -4198,7 +4231,7 @@ Valid keys: ` + JSON.stringify(Object.keys(y), null, " ") return y.every(J); if (y === null || l(y)) return !0; - var R = m(y); + var R = h(y); if (R) { var L = R.call(y), F; if (R !== y.entries) { @@ -4257,19 +4290,19 @@ Valid keys: ` + JSON.stringify(Object.keys(y), null, " ") return g.checkPropTypes = o, g.resetWarningCache = o.resetWarningCache, g.PropTypes = g, g; }, Vr; } -var zr, ua; +var zr, ma; function qd() { - if (ua) + if (ma) return zr; - ua = 1; - var t = ho(); + ma = 1; + var t = yo(); function e() { } function n() { } return n.resetWarningCache = e, zr = function() { - function r(i, l, c, d, p, m) { - if (m !== t) { + function r(i, l, c, d, p, h) { + if (h !== t) { var w = new Error( "Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types" ); @@ -4308,10 +4341,10 @@ function qd() { } if (process.env.NODE_ENV !== "production") { var Kd = Zi(), Jd = !0; - qr.exports = Wd()(Kd.isElement, Jd); + Qr.exports = Wd()(Kd.isElement, Jd); } else - qr.exports = qd()(); -var Zd = qr.exports; + Qr.exports = qd()(); +var Zd = Qr.exports; const u = /* @__PURE__ */ Ld(Zd); function Qd(t) { const { @@ -4331,8 +4364,8 @@ function ts(t, e, n, r, o) { const c = a.type; return typeof c == "function" && !Qd(c) && (l = "Did you accidentally use a plain function component for an element instead?"), l !== void 0 ? new Error(`Invalid ${r} \`${i}\` supplied to \`${n}\`. Expected an element that can hold a ref. ${l} For more information see https://mui.com/r/caveat-with-refs-guide`) : null; } -const es = mo(u.element, ts); -es.isRequired = mo(u.element.isRequired, ts); +const es = vo(u.element, ts); +es.isRequired = vo(u.element.isRequired, ts); const ns = es, tp = "exact-prop: ​"; function ep(t) { return process.env.NODE_ENV === "production" ? t : P({}, t, { @@ -4348,7 +4381,7 @@ function Ve(t) { e += "&args[]=" + encodeURIComponent(arguments[n]); return "Minified MUI error #" + t + "; visit " + e + " for the full message."; } -var Kr = { exports: {} }, lt = {}; +var to = { exports: {} }, lt = {}; /** * @license React * react-is.production.min.js @@ -4358,34 +4391,34 @@ var Kr = { exports: {} }, lt = {}; * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. */ -var wa; +var ha; function np() { - if (wa) + if (ha) return lt; - wa = 1; - var t = Symbol.for("react.element"), e = Symbol.for("react.portal"), n = Symbol.for("react.fragment"), r = Symbol.for("react.strict_mode"), o = Symbol.for("react.profiler"), a = Symbol.for("react.provider"), i = Symbol.for("react.context"), l = Symbol.for("react.server_context"), c = Symbol.for("react.forward_ref"), d = Symbol.for("react.suspense"), p = Symbol.for("react.suspense_list"), m = Symbol.for("react.memo"), w = Symbol.for("react.lazy"), g = Symbol.for("react.offscreen"), v; + ha = 1; + var t = Symbol.for("react.element"), e = Symbol.for("react.portal"), n = Symbol.for("react.fragment"), r = Symbol.for("react.strict_mode"), o = Symbol.for("react.profiler"), a = Symbol.for("react.provider"), i = Symbol.for("react.context"), l = Symbol.for("react.server_context"), c = Symbol.for("react.forward_ref"), d = Symbol.for("react.suspense"), p = Symbol.for("react.suspense_list"), h = Symbol.for("react.memo"), w = Symbol.for("react.lazy"), g = Symbol.for("react.offscreen"), v; v = Symbol.for("react.module.reference"); - function f(h) { - if (typeof h == "object" && h !== null) { - var E = h.$$typeof; + function f(m) { + if (typeof m == "object" && m !== null) { + var E = m.$$typeof; switch (E) { case t: - switch (h = h.type, h) { + switch (m = m.type, m) { case n: case o: case r: case d: case p: - return h; + return m; default: - switch (h = h && h.$$typeof, h) { + switch (m = m && m.$$typeof, m) { case l: case i: case c: case w: - case m: + case h: case a: - return h; + return m; default: return E; } @@ -4395,36 +4428,36 @@ function np() { } } } - return lt.ContextConsumer = i, lt.ContextProvider = a, lt.Element = t, lt.ForwardRef = c, lt.Fragment = n, lt.Lazy = w, lt.Memo = m, lt.Portal = e, lt.Profiler = o, lt.StrictMode = r, lt.Suspense = d, lt.SuspenseList = p, lt.isAsyncMode = function() { + return lt.ContextConsumer = i, lt.ContextProvider = a, lt.Element = t, lt.ForwardRef = c, lt.Fragment = n, lt.Lazy = w, lt.Memo = h, lt.Portal = e, lt.Profiler = o, lt.StrictMode = r, lt.Suspense = d, lt.SuspenseList = p, lt.isAsyncMode = function() { return !1; }, lt.isConcurrentMode = function() { return !1; - }, lt.isContextConsumer = function(h) { - return f(h) === i; - }, lt.isContextProvider = function(h) { - return f(h) === a; - }, lt.isElement = function(h) { - return typeof h == "object" && h !== null && h.$$typeof === t; - }, lt.isForwardRef = function(h) { - return f(h) === c; - }, lt.isFragment = function(h) { - return f(h) === n; - }, lt.isLazy = function(h) { - return f(h) === w; - }, lt.isMemo = function(h) { - return f(h) === m; - }, lt.isPortal = function(h) { - return f(h) === e; - }, lt.isProfiler = function(h) { - return f(h) === o; - }, lt.isStrictMode = function(h) { - return f(h) === r; - }, lt.isSuspense = function(h) { - return f(h) === d; - }, lt.isSuspenseList = function(h) { - return f(h) === p; - }, lt.isValidElementType = function(h) { - return typeof h == "string" || typeof h == "function" || h === n || h === o || h === r || h === d || h === p || h === g || typeof h == "object" && h !== null && (h.$$typeof === w || h.$$typeof === m || h.$$typeof === a || h.$$typeof === i || h.$$typeof === c || h.$$typeof === v || h.getModuleId !== void 0); + }, lt.isContextConsumer = function(m) { + return f(m) === i; + }, lt.isContextProvider = function(m) { + return f(m) === a; + }, lt.isElement = function(m) { + return typeof m == "object" && m !== null && m.$$typeof === t; + }, lt.isForwardRef = function(m) { + return f(m) === c; + }, lt.isFragment = function(m) { + return f(m) === n; + }, lt.isLazy = function(m) { + return f(m) === w; + }, lt.isMemo = function(m) { + return f(m) === h; + }, lt.isPortal = function(m) { + return f(m) === e; + }, lt.isProfiler = function(m) { + return f(m) === o; + }, lt.isStrictMode = function(m) { + return f(m) === r; + }, lt.isSuspense = function(m) { + return f(m) === d; + }, lt.isSuspenseList = function(m) { + return f(m) === p; + }, lt.isValidElementType = function(m) { + return typeof m == "string" || typeof m == "function" || m === n || m === o || m === r || m === d || m === p || m === g || typeof m == "object" && m !== null && (m.$$typeof === w || m.$$typeof === h || m.$$typeof === a || m.$$typeof === i || m.$$typeof === c || m.$$typeof === v || m.getModuleId !== void 0); }, lt.typeOf = f, lt; } var ct = {}; @@ -4437,13 +4470,13 @@ var ct = {}; * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. */ -var fa; +var ga; function rp() { - return fa || (fa = 1, process.env.NODE_ENV !== "production" && function() { - var t = Symbol.for("react.element"), e = Symbol.for("react.portal"), n = Symbol.for("react.fragment"), r = Symbol.for("react.strict_mode"), o = Symbol.for("react.profiler"), a = Symbol.for("react.provider"), i = Symbol.for("react.context"), l = Symbol.for("react.server_context"), c = Symbol.for("react.forward_ref"), d = Symbol.for("react.suspense"), p = Symbol.for("react.suspense_list"), m = Symbol.for("react.memo"), w = Symbol.for("react.lazy"), g = Symbol.for("react.offscreen"), v = !1, f = !1, h = !1, E = !1, _ = !1, C; + return ga || (ga = 1, process.env.NODE_ENV !== "production" && function() { + var t = Symbol.for("react.element"), e = Symbol.for("react.portal"), n = Symbol.for("react.fragment"), r = Symbol.for("react.strict_mode"), o = Symbol.for("react.profiler"), a = Symbol.for("react.provider"), i = Symbol.for("react.context"), l = Symbol.for("react.server_context"), c = Symbol.for("react.forward_ref"), d = Symbol.for("react.suspense"), p = Symbol.for("react.suspense_list"), h = Symbol.for("react.memo"), w = Symbol.for("react.lazy"), g = Symbol.for("react.offscreen"), v = !1, f = !1, m = !1, E = !1, _ = !1, C; C = Symbol.for("react.module.reference"); function S(j) { - return !!(typeof j == "string" || typeof j == "function" || j === n || j === o || _ || j === r || j === d || j === p || E || j === g || v || f || h || typeof j == "object" && j !== null && (j.$$typeof === w || j.$$typeof === m || j.$$typeof === a || j.$$typeof === i || j.$$typeof === c || // This needs to include all possible module reference object + return !!(typeof j == "string" || typeof j == "function" || j === n || j === o || _ || j === r || j === d || j === p || E || j === g || v || f || m || typeof j == "object" && j !== null && (j.$$typeof === w || j.$$typeof === h || j.$$typeof === a || j.$$typeof === i || j.$$typeof === c || // This needs to include all possible module reference object // types supported by any Flight configuration anywhere since // we don't know which Flight build this will end up being used // with. @@ -4469,7 +4502,7 @@ function rp() { case i: case c: case w: - case m: + case h: case a: return ce; default: @@ -4481,7 +4514,7 @@ function rp() { } } } - var I = i, z = a, H = t, O = c, $ = n, k = w, B = m, D = e, J = o, q = r, U = d, tt = p, at = !1, rt = !1; + var A = i, z = a, H = t, O = c, $ = n, k = w, B = h, D = e, J = o, q = r, U = d, tt = p, at = !1, rt = !1; function y(j) { return at || (at = !0, console.warn("The ReactIs.isAsyncMode() alias has been deprecated, and will be removed in React 18+.")), !1; } @@ -4507,7 +4540,7 @@ function rp() { return b(j) === w; } function G(j) { - return b(j) === m; + return b(j) === h; } function K(j) { return b(j) === e; @@ -4518,17 +4551,17 @@ function rp() { function dt(j) { return b(j) === r; } - function A(j) { + function I(j) { return b(j) === d; } function Nt(j) { return b(j) === p; } - ct.ContextConsumer = I, ct.ContextProvider = z, ct.Element = H, ct.ForwardRef = O, ct.Fragment = $, ct.Lazy = k, ct.Memo = B, ct.Portal = D, ct.Profiler = J, ct.StrictMode = q, ct.Suspense = U, ct.SuspenseList = tt, ct.isAsyncMode = y, ct.isConcurrentMode = R, ct.isContextConsumer = L, ct.isContextProvider = F, ct.isElement = V, ct.isForwardRef = W, ct.isFragment = X, ct.isLazy = Y, ct.isMemo = G, ct.isPortal = K, ct.isProfiler = Z, ct.isStrictMode = dt, ct.isSuspense = A, ct.isSuspenseList = Nt, ct.isValidElementType = S, ct.typeOf = b; + ct.ContextConsumer = A, ct.ContextProvider = z, ct.Element = H, ct.ForwardRef = O, ct.Fragment = $, ct.Lazy = k, ct.Memo = B, ct.Portal = D, ct.Profiler = J, ct.StrictMode = q, ct.Suspense = U, ct.SuspenseList = tt, ct.isAsyncMode = y, ct.isConcurrentMode = R, ct.isContextConsumer = L, ct.isContextProvider = F, ct.isElement = V, ct.isForwardRef = W, ct.isFragment = X, ct.isLazy = Y, ct.isMemo = G, ct.isPortal = K, ct.isProfiler = Z, ct.isStrictMode = dt, ct.isSuspense = I, ct.isSuspenseList = Nt, ct.isValidElementType = S, ct.typeOf = b; }()), ct; } -process.env.NODE_ENV === "production" ? Kr.exports = np() : Kr.exports = rp(); -var ma = Kr.exports; +process.env.NODE_ENV === "production" ? to.exports = np() : to.exports = rp(); +var ba = to.exports; const op = /^\s*function(?:\s|\s*\/\*.*\*\/\s*)+([^(\s/]*)\s*/; function ap(t) { const e = `${t}`.match(op); @@ -4537,7 +4570,7 @@ function ap(t) { function rs(t, e = "") { return t.displayName || t.name || ap(t) || e; } -function ha(t, e, n) { +function va(t, e, n) { const r = rs(e); return t.displayName || (r !== "" ? `${n}(${r})` : n); } @@ -4549,10 +4582,10 @@ function ip(t) { return rs(t, "Component"); if (typeof t == "object") switch (t.$$typeof) { - case ma.ForwardRef: - return ha(t, t.render, "ForwardRef"); - case ma.Memo: - return ha(t, t.type, "memo"); + case ba.ForwardRef: + return va(t, t.render, "ForwardRef"); + case ba.Memo: + return va(t, t.type, "memo"); default: return; } @@ -4614,30 +4647,30 @@ function wp(t, e) { return () => null; const n = e ? P({}, e.propTypes) : null; return (o) => (a, i, l, c, d, ...p) => { - const m = d || i, w = n == null ? void 0 : n[m]; + const h = d || i, w = n == null ? void 0 : n[h]; if (w) { const g = w(a, i, l, c, d, ...p); if (g) return g; } - return typeof a[i] < "u" && !a[o] ? new Error(`The prop \`${m}\` of \`${t}\` can only be used together with the \`${o}\` prop.`) : null; + return typeof a[i] < "u" && !a[o] ? new Error(`The prop \`${h}\` of \`${t}\` can only be used together with the \`${o}\` prop.`) : null; }; } function Wn(t, e) { typeof t == "function" ? t(e) : t && (t.current = e); } const fp = typeof window < "u" ? M.useLayoutEffect : M.useEffect, ze = fp; -let ga = 0; +let ya = 0; function mp(t) { const [e, n] = M.useState(t), r = t || e; return M.useEffect(() => { - e == null && (ga += 1, n(`mui-${ga}`)); + e == null && (ya += 1, n(`mui-${ya}`)); }, [e]), r; } -const ba = M["useId".toString()]; +const xa = M["useId".toString()]; function as(t) { - if (ba !== void 0) { - const e = ba(); + if (xa !== void 0) { + const e = xa(); return t ?? e; } return mp(t); @@ -4675,7 +4708,7 @@ function is({ }, []); return [l, c]; } -function Jr(t) { +function eo(t) { const e = M.useRef(t); return ze(() => { e.current = t; @@ -4691,10 +4724,10 @@ function xe(...t) { }); }, t); } -const va = {}; +const Na = {}; function gp(t, e) { - const n = M.useRef(va); - return n.current === va && (n.current = t(e)), n; + const n = M.useRef(Na); + return n.current === Na && (n.current = t(e)), n; } const bp = []; function vp(t) { @@ -4722,7 +4755,7 @@ function sn() { const t = gp(Tn.create).current; return vp(t.disposeEffect), t; } -let dr = !0, Zr = !1; +let dr = !0, no = !1; const yp = new Tn(), xp = { text: !0, search: !0, @@ -4752,7 +4785,7 @@ function Lr() { dr = !1; } function Ep() { - this.visibilityState === "hidden" && Zr && (dr = !0); + this.visibilityState === "hidden" && no && (dr = !0); } function Sp(t) { t.addEventListener("keydown", kp, !0), t.addEventListener("mousedown", Lr, !0), t.addEventListener("pointerdown", Lr, !0), t.addEventListener("touchstart", Lr, !0), t.addEventListener("visibilitychange", Ep, !0); @@ -4772,8 +4805,8 @@ function ss() { o != null && Sp(o.ownerDocument); }, []), e = M.useRef(!1); function n() { - return e.current ? (Zr = !0, yp.start(100, () => { - Zr = !1; + return e.current ? (no = !0, yp.start(100, () => { + no = !1; }), e.current = !1, !0) : !1; } function r(o) { @@ -4800,7 +4833,7 @@ function ls(t, e) { n[r] === void 0 && (n[r] = t[r]); }), n; } -function go(t, e, n = void 0) { +function xo(t, e, n = void 0) { const r = {}; return Object.keys(t).forEach( // `Object.keys(slots)` can't be wider than `T` because we infer `T` from `slots`. @@ -4816,8 +4849,8 @@ function go(t, e, n = void 0) { } ), r; } -const ya = (t) => t, Cp = () => { - let t = ya; +const ka = (t) => t, Cp = () => { + let t = ka; return { configure(e) { t = e; @@ -4826,7 +4859,7 @@ const ya = (t) => t, Cp = () => { return t(e); }, reset() { - t = ya; + t = ka; } }; }, Op = Cp(), cs = Op, ds = { @@ -4905,7 +4938,7 @@ function $p(t) { function p(w) { return i.indexOf(w) + 1 < i.length ? d(w, i[i.indexOf(w) + 1]) : l(w); } - function m(w) { + function h(w) { const g = i.indexOf(w); return g === 0 ? l(i[1]) : g === i.length - 1 ? c(i[g]) : d(w, i[i.indexOf(w) + 1]).replace("@media", "@media not all and"); } @@ -4916,20 +4949,20 @@ function $p(t) { down: c, between: d, only: p, - not: m, + not: h, unit: n }, o); } -const Ip = { +const Ap = { borderRadius: 4 -}, Ap = Ip, Mp = process.env.NODE_ENV !== "production" ? u.oneOfType([u.number, u.string, u.object, u.array]) : {}, se = Mp; +}, Ip = Ap, Mp = process.env.NODE_ENV !== "production" ? u.oneOfType([u.number, u.string, u.object, u.array]) : {}, se = Mp; function un(t, e) { return e ? Zt(t, e, { clone: !1 // No need to clone deep, it's way faster. }) : t; } -const bo = { +const No = { xs: 0, // phone sm: 600, @@ -4940,22 +4973,22 @@ const bo = { // desktop xl: 1536 // large screen -}, xa = { +}, Ea = { // Sorted ASC by size. That's important. // It can't be configured as it's used statically for propTypes. keys: ["xs", "sm", "md", "lg", "xl"], - up: (t) => `@media (min-width:${bo[t]}px)` + up: (t) => `@media (min-width:${No[t]}px)` }; function Qt(t, e, n) { const r = t.theme || {}; if (Array.isArray(e)) { - const a = r.breakpoints || xa; + const a = r.breakpoints || Ea; return e.reduce((i, l, c) => (i[a.up(a.keys[c])] = n(e[c]), i), {}); } if (typeof e == "object") { - const a = r.breakpoints || xa; + const a = r.breakpoints || Ea; return Object.keys(e).reduce((i, l) => { - if (Object.keys(a.values || bo).indexOf(l) !== -1) { + if (Object.keys(a.values || No).indexOf(l) !== -1) { const c = a.up(l); i[c] = n(e[l], l); } else { @@ -5004,9 +5037,9 @@ function yt(t) { if (i[e] == null) return null; const l = i[e], c = i.theme, d = ur(c, r) || {}; - return Qt(i, l, (m) => { - let w = qn(d, o, m); - return m === w && typeof m == "string" && (w = qn(d, o, `${e}${m === "default" ? "" : Wt(m)}`, m)), n === !1 ? w : { + return Qt(i, l, (h) => { + let w = qn(d, o, h); + return h === w && typeof h == "string" && (w = qn(d, o, `${e}${h === "default" ? "" : Wt(h)}`, h)), n === !1 ? w : { [n]: w }; }); @@ -5029,15 +5062,15 @@ const Vp = { l: "Left", x: ["Left", "Right"], y: ["Top", "Bottom"] -}, Na = { +}, Sa = { marginX: "mx", marginY: "my", paddingX: "px", paddingY: "py" }, Lp = jp((t) => { if (t.length > 2) - if (Na[t]) - t = Na[t]; + if (Sa[t]) + t = Sa[t]; else return [t]; const [e, n] = t.split(""), r = Vp[e], o = zp[n] || ""; @@ -5102,7 +5135,7 @@ function mr(...t) { }), r), {}), n = (r) => Object.keys(r).reduce((o, a) => e[a] ? un(o, e[a](r)) : o, {}); return n.propTypes = process.env.NODE_ENV !== "production" ? t.reduce((r, o) => Object.assign(r, o.propTypes), {}) : {}, n.filterProps = t.reduce((r, o) => r.concat(o.filterProps), []), n; } -function Dt(t) { +function Bt(t) { return typeof t != "number" ? t : `${t}px solid`; } function Lt(t, e) { @@ -5112,7 +5145,7 @@ function Lt(t, e) { transform: e }); } -const Xp = Lt("border", Dt), Yp = Lt("borderTop", Dt), Wp = Lt("borderRight", Dt), qp = Lt("borderBottom", Dt), Kp = Lt("borderLeft", Dt), Jp = Lt("borderColor"), Zp = Lt("borderTopColor"), Qp = Lt("borderRightColor"), tu = Lt("borderBottomColor"), eu = Lt("borderLeftColor"), nu = Lt("outline", Dt), ru = Lt("outlineColor"), hr = (t) => { +const Xp = Lt("border", Bt), Yp = Lt("borderTop", Bt), Wp = Lt("borderRight", Bt), qp = Lt("borderBottom", Bt), Kp = Lt("borderLeft", Bt), Jp = Lt("borderColor"), Zp = Lt("borderTopColor"), Qp = Lt("borderRightColor"), tu = Lt("borderBottomColor"), eu = Lt("borderLeftColor"), nu = Lt("outline", Bt), ru = Lt("outlineColor"), hr = (t) => { if (t.borderRadius !== void 0 && t.borderRadius !== null) { const e = Cn(t.theme, "shape.borderRadius", 4, "borderRadius"), n = (r) => ({ borderRadius: On(e, r) @@ -5209,11 +5242,11 @@ function It(t) { const hu = yt({ prop: "width", transform: It -}), vo = (t) => { +}), ko = (t) => { if (t.maxWidth !== void 0 && t.maxWidth !== null) { const e = (n) => { var r, o; - const a = ((r = t.theme) == null || (r = r.breakpoints) == null || (r = r.values) == null ? void 0 : r[n]) || bo[n]; + const a = ((r = t.theme) == null || (r = r.breakpoints) == null || (r = r.values) == null ? void 0 : r[n]) || No[n]; return a ? ((o = t.theme) == null || (o = o.breakpoints) == null ? void 0 : o.unit) !== "px" ? { maxWidth: `${a}${t.theme.breakpoints.unit}` } : { @@ -5226,7 +5259,7 @@ const hu = yt({ } return null; }; -vo.filterProps = ["maxWidth"]; +ko.filterProps = ["maxWidth"]; const gu = yt({ prop: "minWidth", transform: It @@ -5253,28 +5286,28 @@ yt({ const xu = yt({ prop: "boxSizing" }); -mr(hu, vo, gu, bu, vu, yu, xu); +mr(hu, ko, gu, bu, vu, yu, xu); const Nu = { // borders border: { themeKey: "borders", - transform: Dt + transform: Bt }, borderTop: { themeKey: "borders", - transform: Dt + transform: Bt }, borderRight: { themeKey: "borders", - transform: Dt + transform: Bt }, borderBottom: { themeKey: "borders", - transform: Dt + transform: Bt }, borderLeft: { themeKey: "borders", - transform: Dt + transform: Bt }, borderColor: { themeKey: "palette" @@ -5293,7 +5326,7 @@ const Nu = { }, outline: { themeKey: "borders", - transform: Dt + transform: Bt }, outlineColor: { themeKey: "palette" @@ -5502,7 +5535,7 @@ const Nu = { transform: It }, maxWidth: { - style: vo + style: ko }, minWidth: { transform: It @@ -5538,7 +5571,7 @@ const Nu = { cssProperty: !1, themeKey: "typography" } -}, yo = Nu; +}, Eo = Nu; function ku(...t) { const e = t.reduce((r, o) => r.concat(Object.keys(o)), []), n = new Set(e); return t.every((r) => n.size === Object.keys(r).length); @@ -5560,7 +5593,7 @@ function Su() { cssProperty: c = n, themeKey: d, transform: p, - style: m + style: h } = l; if (r == null) return null; @@ -5569,7 +5602,7 @@ function Su() { [n]: r }; const w = ur(o, d) || {}; - return m ? m(i) : Qt(i, r, (v) => { + return h ? h(i) : Qt(i, r, (v) => { let f = qn(w, p, v); return v === f && typeof v == "string" && (f = qn(w, p, `${n}${v === "default" ? "" : Wt(v)}`, v)), c === !1 ? f : { [c]: f @@ -5584,7 +5617,7 @@ function Su() { } = n || {}; if (!o) return null; - const i = (r = a.unstable_sxConfig) != null ? r : yo; + const i = (r = a.unstable_sxConfig) != null ? r : Eo; function l(c) { let d = c; if (typeof c == "function") @@ -5593,7 +5626,7 @@ function Su() { return c; if (!d) return null; - const p = Dp(a.breakpoints), m = Object.keys(p); + const p = Dp(a.breakpoints), h = Object.keys(p); let w = p; return Object.keys(d).forEach((g) => { const v = Eu(d[g], a); @@ -5604,8 +5637,8 @@ function Su() { else { const f = Qt({ theme: a - }, v, (h) => ({ - [g]: h + }, v, (m) => ({ + [g]: m })); ku(f, v) ? w[g] = e({ sx: v, @@ -5614,7 +5647,7 @@ function Su() { } else w = un(w, t(g, v, a, i)); - }), Bp(m, w); + }), Bp(h, w); } return Array.isArray(o) ? o.map(l) : l(o); } @@ -5622,7 +5655,7 @@ function Su() { } const fs = Su(); fs.filterProps = ["sx"]; -const xo = fs; +const So = fs; function Tu(t, e) { const n = this; return n.vars && typeof n.getColorSchemeSelector == "function" ? { @@ -5630,7 +5663,7 @@ function Tu(t, e) { } : n.palette.mode === t ? e : {}; } const Cu = ["breakpoints", "palette", "spacing", "shape"]; -function No(t = {}, ...e) { +function To(t = {}, ...e) { const { breakpoints: n = {}, palette: r = {}, @@ -5646,11 +5679,11 @@ function No(t = {}, ...e) { mode: "light" }, r), spacing: c, - shape: P({}, Ap, a) + shape: P({}, Ip, a) }, i); - return d.applyStyles = Tu, d = e.reduce((p, m) => Zt(p, m), d), d.unstable_sxConfig = P({}, yo, i == null ? void 0 : i.unstable_sxConfig), d.unstable_sx = function(m) { - return xo({ - sx: m, + return d.applyStyles = Tu, d = e.reduce((p, h) => Zt(p, h), d), d.unstable_sxConfig = P({}, Eo, i == null ? void 0 : i.unstable_sxConfig), d.unstable_sx = function(h) { + return So({ + sx: h, theme: this }); }, d; @@ -5662,15 +5695,15 @@ function ms(t = null) { const e = M.useContext(Xl); return !e || Ou(e) ? t : e; } -const Ru = No(); +const Ru = To(); function hs(t = Ru) { return ms(t); } const _u = ["ownerState"], Pu = ["variants"], $u = ["name", "slot", "skipVariantsResolver", "skipSx", "overridesResolver"]; -function Iu(t) { +function Au(t) { return Object.keys(t).length === 0; } -function Au(t) { +function Iu(t) { return typeof t == "string" && // 96 is one less than the char code // for "a" so this is checking that // it's a lowercase character @@ -5679,13 +5712,13 @@ function Au(t) { function Gn(t) { return t !== "ownerState" && t !== "theme" && t !== "sx" && t !== "as"; } -const Mu = No(), ka = (t) => t && t.charAt(0).toLowerCase() + t.slice(1); +const Mu = To(), Ta = (t) => t && t.charAt(0).toLowerCase() + t.slice(1); function Vn({ defaultTheme: t, theme: e, themeId: n }) { - return Iu(e) ? t : e[n] || e; + return Au(e) ? t : e[n] || e; } function Du(t) { return t ? (e, n) => n[t] : null; @@ -5725,43 +5758,43 @@ function Bu(t = {}) { defaultTheme: n = Mu, rootShouldForwardProp: r = Gn, slotShouldForwardProp: o = Gn - } = t, a = (i) => xo(P({}, i, { + } = t, a = (i) => So(P({}, i, { theme: Vn(P({}, i, { defaultTheme: n, themeId: e })) })); return a.__mui_systemSx = !0, (i, l = {}) => { - Yl(i, (b) => b.filter((I) => !(I != null && I.__mui_systemSx))); + Yl(i, (b) => b.filter((A) => !(A != null && A.__mui_systemSx))); const { name: c, slot: d, skipVariantsResolver: p, - skipSx: m, + skipSx: h, // TODO v6: remove `lowercaseFirstLetter()` in the next major release // For more details: https://github.com/mui/material-ui/pull/37908 - overridesResolver: w = Du(ka(d)) + overridesResolver: w = Du(Ta(d)) } = l, g = kt(l, $u), v = p !== void 0 ? p : ( // TODO v6: remove `Root` in the next major release // For more details: https://github.com/mui/material-ui/pull/37908 d && d !== "Root" && d !== "root" || !1 - ), f = m || !1; - let h; - process.env.NODE_ENV !== "production" && c && (h = `${c}-${ka(d || "Root")}`); + ), f = h || !1; + let m; + process.env.NODE_ENV !== "production" && c && (m = `${c}-${Ta(d || "Root")}`); let E = Gn; - d === "Root" || d === "root" ? E = r : d ? E = o : Au(i) && (E = void 0); + d === "Root" || d === "root" ? E = r : d ? E = o : Iu(i) && (E = void 0); const _ = Hl(i, P({ shouldForwardProp: E, - label: h - }, g)), C = (b) => typeof b == "function" && b.__emotion_real !== b || he(b) ? (I) => Hn(b, P({}, I, { + label: m + }, g)), C = (b) => typeof b == "function" && b.__emotion_real !== b || he(b) ? (A) => Hn(b, P({}, A, { theme: Vn({ - theme: I.theme, + theme: A.theme, defaultTheme: n, themeId: e }) - })) : b, S = (b, ...I) => { + })) : b, S = (b, ...A) => { let z = C(b); - const H = I ? I.map(C) : []; + const H = A ? A.map(C) : []; c && w && H.push((k) => { const B = Vn(P({}, k, { defaultTheme: n, @@ -5787,7 +5820,7 @@ function Bu(t = {}) { theme: D })); }), f || H.push(a); - const O = H.length - I.length; + const O = H.length - A.length; if (Array.isArray(b) && O > 0) { const k = new Array(O).fill(""); z = [...b, ...k], z.raw = [...b.raw, ...k]; @@ -5823,7 +5856,7 @@ function Vu({ props: t }); } -function ko(t, e = 0, n = 1) { +function Co(t, e = 0, n = 1) { return process.env.NODE_ENV !== "production" && (t < e || t > n) && console.error(`MUI: The value provided ${t} is out of range [${e}, ${n}].`), Rp(t, e, n); } function zu(t) { @@ -5876,20 +5909,20 @@ function Lu(t) { values: c }); } -function Ea(t) { +function Ca(t) { t = Ne(t); let e = t.type === "hsl" || t.type === "hsla" ? Ne(Lu(t)).values : t.values; return e = e.map((n) => (t.type !== "color" && (n /= 255), n <= 0.03928 ? n / 12.92 : ((n + 0.055) / 1.055) ** 2.4)), Number((0.2126 * e[0] + 0.7152 * e[1] + 0.0722 * e[2]).toFixed(3)); } -function Sa(t, e) { - const n = Ea(t), r = Ea(e); +function Oa(t, e) { + const n = Ca(t), r = Ca(e); return (Math.max(n, r) + 0.05) / (Math.min(n, r) + 0.05); } function gs(t, e) { - return t = Ne(t), e = ko(e), (t.type === "rgb" || t.type === "hsl") && (t.type += "a"), t.type === "color" ? t.values[3] = `/${e}` : t.values[3] = e, yr(t); + return t = Ne(t), e = Co(e), (t.type === "rgb" || t.type === "hsl") && (t.type += "a"), t.type === "color" ? t.values[3] = `/${e}` : t.values[3] = e, yr(t); } function Fu(t, e) { - if (t = Ne(t), e = ko(e), t.type.indexOf("hsl") !== -1) + if (t = Ne(t), e = Co(e), t.type.indexOf("hsl") !== -1) t.values[2] *= 1 - e; else if (t.type.indexOf("rgb") !== -1 || t.type.indexOf("color") !== -1) for (let n = 0; n < 3; n += 1) @@ -5897,7 +5930,7 @@ function Fu(t, e) { return yr(t); } function Uu(t, e) { - if (t = Ne(t), e = ko(e), t.type.indexOf("hsl") !== -1) + if (t = Ne(t), e = Co(e), t.type.indexOf("hsl") !== -1) t.values[2] += (100 - t.values[2]) * e; else if (t.type.indexOf("rgb") !== -1) for (let n = 0; n < 3; n += 1) @@ -6030,7 +6063,7 @@ const Hu = { A200: "#69f0ae", A400: "#00e676", A700: "#00c853" -}, $e = Qu, tw = ["mode", "contrastThreshold", "tonalOffset"], Ta = { +}, $e = Qu, tw = ["mode", "contrastThreshold", "tonalOffset"], Ra = { // The colors used to style the text. text: { // The most important text. @@ -6093,7 +6126,7 @@ const Hu = { activatedOpacity: 0.24 } }; -function Ca(t, e, n, r) { +function _a(t, e, n, r) { const o = r.light || r, a = r.dark || r * 1.5; t[e] || (t.hasOwnProperty(n) ? t[e] = t[n] : e === "light" ? t.light = Uu(t.main, o) : e === "dark" && (t.dark = Fu(t.main, a))); } @@ -6170,27 +6203,27 @@ function sw(t) { contrastThreshold: n = 3, tonalOffset: r = 0.2 } = t, o = kt(t, tw), a = t.primary || ew(e), i = t.secondary || nw(e), l = t.error || rw(e), c = t.info || ow(e), d = t.success || aw(e), p = t.warning || iw(e); - function m(f) { - const h = Sa(f, Fr.text.primary) >= n ? Fr.text.primary : Ta.text.primary; + function h(f) { + const m = Oa(f, Fr.text.primary) >= n ? Fr.text.primary : Ra.text.primary; if (process.env.NODE_ENV !== "production") { - const E = Sa(f, h); - E < 3 && console.error([`MUI: The contrast ratio of ${E}:1 for ${h} on ${f}`, "falls below the WCAG recommended absolute minimum contrast ratio of 3:1.", "https://www.w3.org/TR/2008/REC-WCAG20-20081211/#visual-audio-contrast-contrast"].join(` + const E = Oa(f, m); + E < 3 && console.error([`MUI: The contrast ratio of ${E}:1 for ${m} on ${f}`, "falls below the WCAG recommended absolute minimum contrast ratio of 3:1.", "https://www.w3.org/TR/2008/REC-WCAG20-20081211/#visual-audio-contrast-contrast"].join(` `)); } - return h; + return m; } const w = ({ color: f, - name: h, + name: m, mainShade: E = 500, lightShade: _ = 300, darkShade: C = 700 }) => { if (f = P({}, f), !f.main && f[E] && (f.main = f[E]), !f.hasOwnProperty("main")) - throw new Error(process.env.NODE_ENV !== "production" ? `MUI: The color${h ? ` (${h})` : ""} provided to augmentColor(color) is invalid. -The color object needs to have a \`main\` property or a \`${E}\` property.` : Ve(11, h ? ` (${h})` : "", E)); + throw new Error(process.env.NODE_ENV !== "production" ? `MUI: The color${m ? ` (${m})` : ""} provided to augmentColor(color) is invalid. +The color object needs to have a \`main\` property or a \`${E}\` property.` : Ve(11, m ? ` (${m})` : "", E)); if (typeof f.main != "string") - throw new Error(process.env.NODE_ENV !== "production" ? `MUI: The color${h ? ` (${h})` : ""} provided to augmentColor(color) is invalid. + throw new Error(process.env.NODE_ENV !== "production" ? `MUI: The color${m ? ` (${m})` : ""} provided to augmentColor(color) is invalid. \`color.main\` should be a string, but \`${JSON.stringify(f.main)}\` was provided instead. Did you intend to use one of the following approaches? @@ -6203,11 +6236,11 @@ const theme1 = createTheme({ palette: { const theme2 = createTheme({ palette: { primary: { main: green[500] }, -} });` : Ve(12, h ? ` (${h})` : "", JSON.stringify(f.main))); - return Ca(f, "light", _, r), Ca(f, "dark", C, r), f.contrastText || (f.contrastText = m(f.main)), f; +} });` : Ve(12, m ? ` (${m})` : "", JSON.stringify(f.main))); + return _a(f, "light", _, r), _a(f, "dark", C, r), f.contrastText || (f.contrastText = h(f.main)), f; }, g = { dark: Fr, - light: Ta + light: Ra }; return process.env.NODE_ENV !== "production" && (g[e] || console.error(`MUI: The palette mode \`${e}\` is not supported.`)), Zt(P({ // A collection of common colors. @@ -6254,7 +6287,7 @@ const theme2 = createTheme({ palette: { // the background and the text. contrastThreshold: n, // Takes a background color and returns the text color that maximizes the contrast. - getContrastText: m, + getContrastText: h, // Generate a rich color object. augmentColor: w, // Used by the functions below to shift a color's luminance by approximately @@ -6267,12 +6300,12 @@ const lw = ["fontFamily", "fontSize", "fontWeightLight", "fontWeightRegular", "f function cw(t) { return Math.round(t * 1e5) / 1e5; } -const Oa = { +const Pa = { textTransform: "uppercase" -}, Ra = '"Roboto", "Helvetica", "Arial", sans-serif'; +}, $a = '"Roboto", "Helvetica", "Arial", sans-serif'; function dw(t, e) { const n = typeof e == "function" ? e(t) : e, { - fontFamily: r = Ra, + fontFamily: r = $a, // The default font size of the Material Specification. fontSize: o = 14, // px @@ -6285,18 +6318,18 @@ function dw(t, e) { htmlFontSize: d = 16, // Apply the CSS properties to all the variants. allVariants: p, - pxToRem: m + pxToRem: h } = n, w = kt(n, lw); process.env.NODE_ENV !== "production" && (typeof o != "number" && console.error("MUI: `fontSize` is required to be a number."), typeof d != "number" && console.error("MUI: `htmlFontSize` is required to be a number.")); - const g = o / 14, v = m || ((E) => `${E / d * g}rem`), f = (E, _, C, S, b) => P({ + const g = o / 14, v = h || ((E) => `${E / d * g}rem`), f = (E, _, C, S, b) => P({ fontFamily: r, fontWeight: E, fontSize: v(_), // Unitless following https://meyerweb.com/eric/thoughts/2006/02/08/unitless-line-heights/ lineHeight: C - }, r === Ra ? { + }, r === $a ? { letterSpacing: `${cw(S / _)}em` - } : {}, b, p), h = { + } : {}, b, p), m = { h1: f(a, 96, 1.167, -1.5), h2: f(a, 60, 1.2, -0.5), h3: f(i, 48, 1.167, 0), @@ -6307,9 +6340,9 @@ function dw(t, e) { subtitle2: f(l, 14, 1.57, 0.1), body1: f(i, 16, 1.5, 0.15), body2: f(i, 14, 1.43, 0.15), - button: f(l, 14, 1.75, 0.4, Oa), + button: f(l, 14, 1.75, 0.4, Pa), caption: f(i, 12, 1.66, 0.4), - overline: f(i, 12, 2.66, 1, Oa), + overline: f(i, 12, 2.66, 1, Pa), // TODO v6: Remove handling of 'inherit' variant from the theme as it is already handled in Material UI's Typography component. Also, remember to remove the associated types. inherit: { fontFamily: "inherit", @@ -6328,7 +6361,7 @@ function dw(t, e) { fontWeightRegular: i, fontWeightMedium: l, fontWeightBold: c - }, h), w, { + }, m), w, { clone: !1 // No need to clone deep }); @@ -6360,7 +6393,7 @@ const fw = ["none", ft(0, 2, 1, -1, 0, 1, 1, 0, 0, 1, 3, 0), ft(0, 3, 1, -2, 0, // recommended when something is leaving screen leavingScreen: 195 }; -function _a(t) { +function Aa(t) { return `${Math.round(t)}ms`; } function vw(t) { @@ -6380,11 +6413,11 @@ function yw(t) { delay: c = 0 } = a, d = kt(a, hw); if (process.env.NODE_ENV !== "production") { - const p = (w) => typeof w == "string", m = (w) => !isNaN(parseFloat(w)); - !p(o) && !Array.isArray(o) && console.error('MUI: Argument "props" must be a string or Array.'), !m(i) && !p(i) && console.error(`MUI: Argument "duration" must be a number or a string but found ${i}.`), p(l) || console.error('MUI: Argument "easing" must be a string.'), !m(c) && !p(c) && console.error('MUI: Argument "delay" must be a number or a string.'), typeof a != "object" && console.error(["MUI: Secong argument of transition.create must be an object.", "Arguments should be either `create('prop1', options)` or `create(['prop1', 'prop2'], options)`"].join(` + const p = (w) => typeof w == "string", h = (w) => !isNaN(parseFloat(w)); + !p(o) && !Array.isArray(o) && console.error('MUI: Argument "props" must be a string or Array.'), !h(i) && !p(i) && console.error(`MUI: Argument "duration" must be a number or a string but found ${i}.`), p(l) || console.error('MUI: Argument "easing" must be a string.'), !h(c) && !p(c) && console.error('MUI: Argument "delay" must be a number or a string.'), typeof a != "object" && console.error(["MUI: Secong argument of transition.create must be an object.", "Arguments should be either `create('prop1', options)` or `create(['prop1', 'prop2'], options)`"].join(` `)), Object.keys(d).length !== 0 && console.error(`MUI: Unrecognized argument(s) [${Object.keys(d).join(",")}].`); } - return (Array.isArray(o) ? o : [o]).map((p) => `${p} ${typeof i == "string" ? i : _a(i)} ${l} ${typeof c == "string" ? c : _a(c)}`).join(","); + return (Array.isArray(o) ? o : [o]).map((p) => `${p} ${typeof i == "string" ? i : Aa(i)} ${l} ${typeof c == "string" ? c : Aa(c)}`).join(","); } }, t, { easing: e, @@ -6410,7 +6443,7 @@ function Ew(t = {}, ...e) { } = t, i = kt(t, kw); if (t.vars) throw new Error(process.env.NODE_ENV !== "production" ? "MUI: `vars` is a private field used for CSS variables support.\nPlease use another name." : Ve(18)); - const l = sw(r), c = No(t); + const l = sw(r), c = To(t); let d = Zt(c, { mixins: Gu(c.breakpoints, n), palette: l, @@ -6420,17 +6453,17 @@ function Ew(t = {}, ...e) { transitions: yw(o), zIndex: P({}, Nw) }); - if (d = Zt(d, i), d = e.reduce((p, m) => Zt(p, m), d), process.env.NODE_ENV !== "production") { - const p = ["active", "checked", "completed", "disabled", "error", "expanded", "focused", "focusVisible", "required", "selected"], m = (w, g) => { + if (d = Zt(d, i), d = e.reduce((p, h) => Zt(p, h), d), process.env.NODE_ENV !== "production") { + const p = ["active", "checked", "completed", "disabled", "error", "expanded", "focused", "focusVisible", "required", "selected"], h = (w, g) => { let v; for (v in w) { const f = w[v]; if (p.indexOf(v) !== -1 && Object.keys(f).length > 0) { if (process.env.NODE_ENV !== "production") { - const h = pr("", v); - console.error([`MUI: The \`${g}\` component increases the CSS specificity of the \`${v}\` internal state.`, "You can not override it like this: ", JSON.stringify(w, null, 2), "", `Instead, you need to use the '&.${h}' syntax:`, JSON.stringify({ + const m = pr("", v); + console.error([`MUI: The \`${g}\` component increases the CSS specificity of the \`${v}\` internal state.`, "You can not override it like this: ", JSON.stringify(w, null, 2), "", `Instead, you need to use the '&.${m}' syntax:`, JSON.stringify({ root: { - [`&.${h}`]: f + [`&.${m}`]: f } }, null, 2), "", "https://mui.com/r/state-classes-guide"].join(` `)); @@ -6441,31 +6474,31 @@ function Ew(t = {}, ...e) { }; Object.keys(d.components).forEach((w) => { const g = d.components[w].styleOverrides; - g && w.indexOf("Mui") === 0 && m(g, w); + g && w.indexOf("Mui") === 0 && h(g, w); }); } - return d.unstable_sxConfig = P({}, yo, i == null ? void 0 : i.unstable_sxConfig), d.unstable_sx = function(m) { - return xo({ - sx: m, + return d.unstable_sxConfig = P({}, Eo, i == null ? void 0 : i.unstable_sxConfig), d.unstable_sx = function(h) { + return So({ + sx: h, theme: this }); }, d; } -const Sw = Ew(), Eo = Sw, So = "$$material"; -function To({ +const Sw = Ew(), Oo = Sw, Ro = "$$material"; +function _o({ props: t, name: e }) { return Vu({ props: t, name: e, - defaultTheme: Eo, - themeId: So + defaultTheme: Oo, + themeId: Ro }); } const Tw = (t) => Gn(t) && t !== "classes", Cw = Bu({ - themeId: So, - defaultTheme: Eo, + themeId: Ro, + defaultTheme: Oo, rootShouldForwardProp: Tw }), Rn = Cw; function Ow(t) { @@ -6480,7 +6513,7 @@ const Rw = ["children", "className", "color", "component", "fontSize", "htmlColo } = t, o = { root: ["root", e !== "inherit" && `color${Wt(e)}`, `fontSize${Wt(n)}`] }; - return go(o, Ow, r); + return xo(o, Ow, r); }, Pw = Rn("svg", { name: "MuiSvgIcon", slot: "Root", @@ -6494,7 +6527,7 @@ const Rw = ["children", "className", "color", "component", "fontSize", "htmlColo theme: t, ownerState: e }) => { - var n, r, o, a, i, l, c, d, p, m, w, g, v; + var n, r, o, a, i, l, c, d, p, h, w, g, v; return { userSelect: "none", width: "1em", @@ -6514,14 +6547,14 @@ const Rw = ["children", "className", "color", "component", "fontSize", "htmlColo large: ((d = t.typography) == null || (p = d.pxToRem) == null ? void 0 : p.call(d, 35)) || "2.1875rem" }[e.fontSize], // TODO v5 deprecate, v6 remove for sx - color: (m = (w = (t.vars || t).palette) == null || (w = w[e.color]) == null ? void 0 : w.main) != null ? m : { + color: (h = (w = (t.vars || t).palette) == null || (w = w[e.color]) == null ? void 0 : w.main) != null ? h : { action: (g = (t.vars || t).palette) == null || (g = g.action) == null ? void 0 : g.active, disabled: (v = (t.vars || t).palette) == null || (v = v.action) == null ? void 0 : v.disabled, inherit: void 0 }[e.color] }; -}), Co = /* @__PURE__ */ M.forwardRef(function(e, n) { - const r = To({ +}), Po = /* @__PURE__ */ M.forwardRef(function(e, n) { + const r = _o({ props: e, name: "MuiSvgIcon" }), { @@ -6532,7 +6565,7 @@ const Rw = ["children", "className", "color", "component", "fontSize", "htmlColo fontSize: c = "medium", htmlColor: d, inheritViewBox: p = !1, - titleAccess: m, + titleAccess: h, viewBox: w = "0 0 24 24" } = r, g = kt(r, Rw), v = /* @__PURE__ */ M.isValidElement(o) && o.type === "svg", f = P({}, r, { color: i, @@ -6542,25 +6575,25 @@ const Rw = ["children", "className", "color", "component", "fontSize", "htmlColo inheritViewBox: p, viewBox: w, hasSvgAsChild: v - }), h = {}; - p || (h.viewBox = w); + }), m = {}; + p || (m.viewBox = w); const E = _w(f); return /* @__PURE__ */ x(Pw, P({ as: l, className: be(E.root, a), focusable: "false", color: d, - "aria-hidden": m ? void 0 : !0, - role: m ? "img" : void 0, + "aria-hidden": h ? void 0 : !0, + role: h ? "img" : void 0, ref: n - }, h, g, v && o.props, { + }, m, g, v && o.props, { ownerState: f, - children: [v ? o.props.children : o, m ? /* @__PURE__ */ s("title", { - children: m + children: [v ? o.props.children : o, h ? /* @__PURE__ */ s("title", { + children: h }) : null] })); }); -process.env.NODE_ENV !== "production" && (Co.propTypes = { +process.env.NODE_ENV !== "production" && (Po.propTypes = { // ┌────────────────────────────── Warning ──────────────────────────────┐ // │ These PropTypes are generated from the TypeScript type definitions. │ // │ To update them, edit the d.ts file and run `pnpm proptypes`. │ @@ -6632,25 +6665,25 @@ process.env.NODE_ENV !== "production" && (Co.propTypes = { */ viewBox: u.string }); -Co.muiName = "SvgIcon"; -const Pa = Co; +Po.muiName = "SvgIcon"; +const Ia = Po; function bs(t, e) { function n(r, o) { - return /* @__PURE__ */ s(Pa, P({ + return /* @__PURE__ */ s(Ia, P({ "data-testid": `${e}Icon`, ref: o }, r, { children: t })); } - return process.env.NODE_ENV !== "production" && (n.displayName = `${e}Icon`), n.muiName = Pa.muiName, /* @__PURE__ */ M.memo(/* @__PURE__ */ M.forwardRef(n)); + return process.env.NODE_ENV !== "production" && (n.displayName = `${e}Icon`), n.muiName = Ia.muiName, /* @__PURE__ */ M.memo(/* @__PURE__ */ M.forwardRef(n)); } const $w = { configure: (t) => { process.env.NODE_ENV !== "production" && console.warn(["MUI: `ClassNameGenerator` import from `@mui/material/utils` is outdated and might cause unexpected issues.", "", "You should use `import { unstable_ClassNameGenerator } from '@mui/material/className'` instead", "", "The detail of the issue: https://github.com/mui/material-ui/issues/30011#issuecomment-1024993401", "", "The updated documentation: https://mui.com/guides/classname-generator/"].join(` `)), cs.configure(t); } -}, Iw = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({ +}, Aw = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({ __proto__: null, capitalize: Wt, createChainedFunction: lp, @@ -6667,13 +6700,13 @@ const $w = { unstable_useId: as, unsupportedProp: hp, useControlled: is, - useEventCallback: Jr, + useEventCallback: eo, useForkRef: xe, useIsFocusVisible: ss -}, Symbol.toStringTag, { value: "Module" })), Aw = /* @__PURE__ */ Fd(Iw); -var $a; +}, Symbol.toStringTag, { value: "Module" })), Iw = /* @__PURE__ */ Fd(Aw); +var Ma; function Mw() { - return $a || ($a = 1, function(t) { + return Ma || (Ma = 1, function(t) { "use client"; Object.defineProperty(t, "__esModule", { value: !0 @@ -6683,15 +6716,15 @@ function Mw() { return e.createSvgIcon; } }); - var e = Aw; - }(Ar)), Ar; + var e = Iw; + }(Ir)), Ir; } var Dw = Ud; -Object.defineProperty(fo, "__esModule", { +Object.defineProperty(bo, "__esModule", { value: !0 }); -var vs = fo.default = void 0, Bw = Dw(Mw()), jw = Qs; -vs = fo.default = (0, Bw.default)(/* @__PURE__ */ (0, jw.jsx)("path", { +var vs = bo.default = void 0, Bw = Dw(Mw()), jw = Qs; +vs = bo.default = (0, Bw.default)(/* @__PURE__ */ (0, jw.jsx)("path", { d: "m10 17 5-5-5-5z" }), "ArrowRight"); function Vw(t) { @@ -6722,7 +6755,7 @@ function Uw(t, e = []) { function Gw(t, e, n) { return typeof t == "function" ? t(e, n) : t; } -function Ia(t) { +function Da(t) { if (t === void 0) return {}; const e = {}; @@ -6745,8 +6778,8 @@ function Hw(t) { internalRef: void 0 }; } - const i = Uw(P({}, o, r)), l = Ia(r), c = Ia(o), d = e(i), p = be(d == null ? void 0 : d.className, n == null ? void 0 : n.className, a, o == null ? void 0 : o.className, r == null ? void 0 : r.className), m = P({}, d == null ? void 0 : d.style, n == null ? void 0 : n.style, o == null ? void 0 : o.style, r == null ? void 0 : r.style), w = P({}, d, n, c, l); - return p.length > 0 && (w.className = p), Object.keys(m).length > 0 && (w.style = m), { + const i = Uw(P({}, o, r)), l = Da(r), c = Da(o), d = e(i), p = be(d == null ? void 0 : d.className, n == null ? void 0 : n.className, a, o == null ? void 0 : o.className, r == null ? void 0 : r.className), h = P({}, d == null ? void 0 : d.style, n == null ? void 0 : n.style, o == null ? void 0 : o.style, r == null ? void 0 : r.style), w = P({}, d, n, c, l); + return p.length > 0 && (w.className = p), Object.keys(h).length > 0 && (w.style = h), { props: w, internalRef: d.ref }; @@ -6844,15 +6877,15 @@ process.env.NODE_ENV !== "production" && (Kn.propTypes = { disablePortal: u.bool }); process.env.NODE_ENV !== "production" && (Kn["propTypes"] = ep(Kn.propTypes)); -var Tt = "top", Vt = "bottom", zt = "right", Ct = "left", Oo = "auto", _n = [Tt, Vt, zt, Ct], Le = "start", Nn = "end", Zw = "clippingParents", Ns = "viewport", rn = "popper", Qw = "reference", Aa = /* @__PURE__ */ _n.reduce(function(t, e) { +var Ct = "top", Vt = "bottom", zt = "right", Ot = "left", $o = "auto", _n = [Ct, Vt, zt, Ot], Le = "start", Nn = "end", Zw = "clippingParents", Ns = "viewport", rn = "popper", Qw = "reference", Ba = /* @__PURE__ */ _n.reduce(function(t, e) { return t.concat([e + "-" + Le, e + "-" + Nn]); -}, []), ks = /* @__PURE__ */ [].concat(_n, [Oo]).reduce(function(t, e) { +}, []), ks = /* @__PURE__ */ [].concat(_n, [$o]).reduce(function(t, e) { return t.concat([e, e + "-" + Le, e + "-" + Nn]); }, []), tf = "beforeRead", ef = "read", nf = "afterRead", rf = "beforeMain", of = "main", af = "afterMain", sf = "beforeWrite", lf = "write", cf = "afterWrite", df = [tf, ef, nf, rf, of, af, sf, lf, cf]; function qt(t) { return t ? (t.nodeName || "").toLowerCase() : null; } -function At(t) { +function Mt(t) { if (t == null) return window; if (t.toString() !== "[object Window]") { @@ -6862,17 +6895,17 @@ function At(t) { return t; } function ke(t) { - var e = At(t).Element; + var e = Mt(t).Element; return t instanceof e || t instanceof Element; } function jt(t) { - var e = At(t).HTMLElement; + var e = Mt(t).HTMLElement; return t instanceof e || t instanceof HTMLElement; } -function Ro(t) { +function Ao(t) { if (typeof ShadowRoot > "u") return !1; - var e = At(t).ShadowRoot; + var e = Mt(t).ShadowRoot; return t instanceof e || t instanceof ShadowRoot; } function pf(t) { @@ -6921,32 +6954,32 @@ function Yt(t) { return t.split("-")[0]; } var ve = Math.max, Jn = Math.min, Fe = Math.round; -function Qr() { +function ro() { var t = navigator.userAgentData; return t != null && t.brands && Array.isArray(t.brands) ? t.brands.map(function(e) { return e.brand + "/" + e.version; }).join(" ") : navigator.userAgent; } function Es() { - return !/^((?!chrome|android).)*safari/i.test(Qr()); + return !/^((?!chrome|android).)*safari/i.test(ro()); } function Ue(t, e, n) { e === void 0 && (e = !1), n === void 0 && (n = !1); var r = t.getBoundingClientRect(), o = 1, a = 1; e && jt(t) && (o = t.offsetWidth > 0 && Fe(r.width) / t.offsetWidth || 1, a = t.offsetHeight > 0 && Fe(r.height) / t.offsetHeight || 1); - var i = ke(t) ? At(t) : window, l = i.visualViewport, c = !Es() && n, d = (r.left + (c && l ? l.offsetLeft : 0)) / o, p = (r.top + (c && l ? l.offsetTop : 0)) / a, m = r.width / o, w = r.height / a; + var i = ke(t) ? Mt(t) : window, l = i.visualViewport, c = !Es() && n, d = (r.left + (c && l ? l.offsetLeft : 0)) / o, p = (r.top + (c && l ? l.offsetTop : 0)) / a, h = r.width / o, w = r.height / a; return { - width: m, + width: h, height: w, top: p, - right: d + m, + right: d + h, bottom: p + w, left: d, x: d, y: p }; } -function _o(t) { +function Io(t) { var e = Ue(t), n = t.offsetWidth, r = t.offsetHeight; return Math.abs(e.width - n) <= 1 && (n = e.width), Math.abs(e.height - r) <= 1 && (r = e.height), { x: t.offsetLeft, @@ -6959,7 +6992,7 @@ function Ss(t, e) { var n = e.getRootNode && e.getRootNode(); if (t.contains(e)) return !0; - if (n && Ro(n)) { + if (n && Ao(n)) { var r = e; do { if (r && t.isSameNode(r)) @@ -6970,7 +7003,7 @@ function Ss(t, e) { return !1; } function te(t) { - return At(t).getComputedStyle(t); + return Mt(t).getComputedStyle(t); } function ff(t) { return ["table", "td", "th"].indexOf(qt(t)) >= 0; @@ -6988,24 +7021,24 @@ function xr(t) { // $FlowFixMe[prop-missing] t.assignedSlot || // step into the shadow DOM of the parent of a slotted node t.parentNode || // DOM Element detected - (Ro(t) ? t.host : null) || // ShadowRoot detected + (Ao(t) ? t.host : null) || // ShadowRoot detected // $FlowFixMe[incompatible-call]: HTMLElement is a Node le(t) ); } -function Ma(t) { +function ja(t) { return !jt(t) || // https://github.com/popperjs/popper-core/issues/837 te(t).position === "fixed" ? null : t.offsetParent; } function mf(t) { - var e = /firefox/i.test(Qr()), n = /Trident/i.test(Qr()); + var e = /firefox/i.test(ro()), n = /Trident/i.test(ro()); if (n && jt(t)) { var r = te(t); if (r.position === "fixed") return null; } var o = xr(t); - for (Ro(o) && (o = o.host); jt(o) && ["html", "body"].indexOf(qt(o)) < 0; ) { + for (Ao(o) && (o = o.host); jt(o) && ["html", "body"].indexOf(qt(o)) < 0; ) { var a = te(o); if (a.transform !== "none" || a.perspective !== "none" || a.contain === "paint" || ["transform", "perspective"].indexOf(a.willChange) !== -1 || e && a.willChange === "filter" || e && a.filter && a.filter !== "none") return o; @@ -7014,11 +7047,11 @@ function mf(t) { return null; } function Pn(t) { - for (var e = At(t), n = Ma(t); n && ff(n) && te(n).position === "static"; ) - n = Ma(n); + for (var e = Mt(t), n = ja(t); n && ff(n) && te(n).position === "static"; ) + n = ja(n); return n && (qt(n) === "html" || qt(n) === "body" && te(n).position === "static") ? e : n || mf(t) || e; } -function Po(t) { +function Mo(t) { return ["top", "bottom"].indexOf(t) >= 0 ? "x" : "y"; } function wn(t, e, n) { @@ -7050,10 +7083,10 @@ var gf = function(e, n) { })) : e, Cs(typeof e != "number" ? e : Os(e, _n)); }; function bf(t) { - var e, n = t.state, r = t.name, o = t.options, a = n.elements.arrow, i = n.modifiersData.popperOffsets, l = Yt(n.placement), c = Po(l), d = [Ct, zt].indexOf(l) >= 0, p = d ? "height" : "width"; + var e, n = t.state, r = t.name, o = t.options, a = n.elements.arrow, i = n.modifiersData.popperOffsets, l = Yt(n.placement), c = Mo(l), d = [Ot, zt].indexOf(l) >= 0, p = d ? "height" : "width"; if (!(!a || !i)) { - var m = gf(o.padding, n), w = _o(a), g = c === "y" ? Tt : Ct, v = c === "y" ? Vt : zt, f = n.rects.reference[p] + n.rects.reference[c] - i[c] - n.rects.popper[p], h = i[c] - n.rects.reference[c], E = Pn(a), _ = E ? c === "y" ? E.clientHeight || 0 : E.clientWidth || 0 : 0, C = f / 2 - h / 2, S = m[g], b = _ - w[p] - m[v], I = _ / 2 - w[p] / 2 + C, z = wn(S, I, b), H = c; - n.modifiersData[r] = (e = {}, e[H] = z, e.centerOffset = z - I, e); + var h = gf(o.padding, n), w = Io(a), g = c === "y" ? Ct : Ot, v = c === "y" ? Vt : zt, f = n.rects.reference[p] + n.rects.reference[c] - i[c] - n.rects.popper[p], m = i[c] - n.rects.reference[c], E = Pn(a), _ = E ? c === "y" ? E.clientHeight || 0 : E.clientWidth || 0 : 0, C = f / 2 - m / 2, S = h[g], b = _ - w[p] - h[v], A = _ / 2 - w[p] / 2 + C, z = wn(S, A, b), H = c; + n.modifiersData[r] = (e = {}, e[H] = z, e.centerOffset = z - A, e); } } function vf(t) { @@ -7085,31 +7118,31 @@ function Nf(t, e) { y: Fe(r * o) / o || 0 }; } -function Da(t) { - var e, n = t.popper, r = t.popperRect, o = t.placement, a = t.variation, i = t.offsets, l = t.position, c = t.gpuAcceleration, d = t.adaptive, p = t.roundOffsets, m = t.isFixed, w = i.x, g = w === void 0 ? 0 : w, v = i.y, f = v === void 0 ? 0 : v, h = typeof p == "function" ? p({ +function Va(t) { + var e, n = t.popper, r = t.popperRect, o = t.placement, a = t.variation, i = t.offsets, l = t.position, c = t.gpuAcceleration, d = t.adaptive, p = t.roundOffsets, h = t.isFixed, w = i.x, g = w === void 0 ? 0 : w, v = i.y, f = v === void 0 ? 0 : v, m = typeof p == "function" ? p({ x: g, y: f }) : { x: g, y: f }; - g = h.x, f = h.y; - var E = i.hasOwnProperty("x"), _ = i.hasOwnProperty("y"), C = Ct, S = Tt, b = window; + g = m.x, f = m.y; + var E = i.hasOwnProperty("x"), _ = i.hasOwnProperty("y"), C = Ot, S = Ct, b = window; if (d) { - var I = Pn(n), z = "clientHeight", H = "clientWidth"; - if (I === At(n) && (I = le(n), te(I).position !== "static" && l === "absolute" && (z = "scrollHeight", H = "scrollWidth")), I = I, o === Tt || (o === Ct || o === zt) && a === Nn) { + var A = Pn(n), z = "clientHeight", H = "clientWidth"; + if (A === Mt(n) && (A = le(n), te(A).position !== "static" && l === "absolute" && (z = "scrollHeight", H = "scrollWidth")), A = A, o === Ct || (o === Ot || o === zt) && a === Nn) { S = Vt; - var O = m && I === b && b.visualViewport ? b.visualViewport.height : ( + var O = h && A === b && b.visualViewport ? b.visualViewport.height : ( // $FlowFixMe[prop-missing] - I[z] + A[z] ); f -= O - r.height, f *= c ? 1 : -1; } - if (o === Ct || (o === Tt || o === Vt) && a === Nn) { + if (o === Ot || (o === Ct || o === Vt) && a === Nn) { C = zt; - var $ = m && I === b && b.visualViewport ? b.visualViewport.width : ( + var $ = h && A === b && b.visualViewport ? b.visualViewport.width : ( // $FlowFixMe[prop-missing] - I[H] + A[H] ); g -= $ - r.width, g *= c ? 1 : -1; } @@ -7119,7 +7152,7 @@ function Da(t) { }, d && xf), B = p === !0 ? Nf({ x: g, y: f - }, At(n)) : { + }, Mt(n)) : { x: g, y: f }; @@ -7138,12 +7171,12 @@ function kf(t) { gpuAcceleration: o, isFixed: e.options.strategy === "fixed" }; - e.modifiersData.popperOffsets != null && (e.styles.popper = Object.assign({}, e.styles.popper, Da(Object.assign({}, d, { + e.modifiersData.popperOffsets != null && (e.styles.popper = Object.assign({}, e.styles.popper, Va(Object.assign({}, d, { offsets: e.modifiersData.popperOffsets, position: e.options.strategy, adaptive: i, roundOffsets: c - })))), e.modifiersData.arrow != null && (e.styles.arrow = Object.assign({}, e.styles.arrow, Da(Object.assign({}, d, { + })))), e.modifiersData.arrow != null && (e.styles.arrow = Object.assign({}, e.styles.arrow, Va(Object.assign({}, d, { offsets: e.modifiersData.arrow, position: "absolute", adaptive: !1, @@ -7163,7 +7196,7 @@ var zn = { passive: !0 }; function Sf(t) { - var e = t.state, n = t.instance, r = t.options, o = r.scroll, a = o === void 0 ? !0 : o, i = r.resize, l = i === void 0 ? !0 : i, c = At(e.elements.popper), d = [].concat(e.scrollParents.reference, e.scrollParents.popper); + var e = t.state, n = t.instance, r = t.options, o = r.scroll, a = o === void 0 ? !0 : o, i = r.resize, l = i === void 0 ? !0 : i, c = Mt(e.elements.popper), d = [].concat(e.scrollParents.reference, e.scrollParents.popper); return a && d.forEach(function(p) { p.addEventListener("scroll", n.update, zn); }), l && c.addEventListener("resize", n.update, zn), function() { @@ -7196,23 +7229,23 @@ var Of = { start: "end", end: "start" }; -function Ba(t) { +function za(t) { return t.replace(/start|end/g, function(e) { return Of[e]; }); } -function $o(t) { - var e = At(t), n = e.pageXOffset, r = e.pageYOffset; +function Do(t) { + var e = Mt(t), n = e.pageXOffset, r = e.pageYOffset; return { scrollLeft: n, scrollTop: r }; } -function Io(t) { - return Ue(le(t)).left + $o(t).scrollLeft; +function Bo(t) { + return Ue(le(t)).left + Do(t).scrollLeft; } function Rf(t, e) { - var n = At(t), r = le(t), o = n.visualViewport, a = r.clientWidth, i = r.clientHeight, l = 0, c = 0; + var n = Mt(t), r = le(t), o = n.visualViewport, a = r.clientWidth, i = r.clientHeight, l = 0, c = 0; if (o) { a = o.width, i = o.height; var d = Es(); @@ -7221,12 +7254,12 @@ function Rf(t, e) { return { width: a, height: i, - x: l + Io(t), + x: l + Bo(t), y: c }; } function _f(t) { - var e, n = le(t), r = $o(t), o = (e = t.ownerDocument) == null ? void 0 : e.body, a = ve(n.scrollWidth, n.clientWidth, o ? o.scrollWidth : 0, o ? o.clientWidth : 0), i = ve(n.scrollHeight, n.clientHeight, o ? o.scrollHeight : 0, o ? o.clientHeight : 0), l = -r.scrollLeft + Io(t), c = -r.scrollTop; + var e, n = le(t), r = Do(t), o = (e = t.ownerDocument) == null ? void 0 : e.body, a = ve(n.scrollWidth, n.clientWidth, o ? o.scrollWidth : 0, o ? o.clientWidth : 0), i = ve(n.scrollHeight, n.clientHeight, o ? o.scrollHeight : 0, o ? o.clientHeight : 0), l = -r.scrollLeft + Bo(t), c = -r.scrollTop; return te(o || n).direction === "rtl" && (l += ve(n.clientWidth, o ? o.clientWidth : 0) - a), { width: a, height: i, @@ -7234,23 +7267,23 @@ function _f(t) { y: c }; } -function Ao(t) { +function jo(t) { var e = te(t), n = e.overflow, r = e.overflowX, o = e.overflowY; return /auto|scroll|overlay|hidden/.test(n + o + r); } function Rs(t) { - return ["html", "body", "#document"].indexOf(qt(t)) >= 0 ? t.ownerDocument.body : jt(t) && Ao(t) ? t : Rs(xr(t)); + return ["html", "body", "#document"].indexOf(qt(t)) >= 0 ? t.ownerDocument.body : jt(t) && jo(t) ? t : Rs(xr(t)); } function fn(t, e) { var n; e === void 0 && (e = []); - var r = Rs(t), o = r === ((n = t.ownerDocument) == null ? void 0 : n.body), a = At(r), i = o ? [a].concat(a.visualViewport || [], Ao(r) ? r : []) : r, l = e.concat(i); + var r = Rs(t), o = r === ((n = t.ownerDocument) == null ? void 0 : n.body), a = Mt(r), i = o ? [a].concat(a.visualViewport || [], jo(r) ? r : []) : r, l = e.concat(i); return o ? l : ( // $FlowFixMe[incompatible-call]: isBody tells us target will be an HTMLElement here l.concat(fn(xr(i))) ); } -function to(t) { +function oo(t) { return Object.assign({}, t, { left: t.x, top: t.y, @@ -7262,8 +7295,8 @@ function Pf(t, e) { var n = Ue(t, !1, e === "fixed"); return n.top = n.top + t.clientTop, n.left = n.left + t.clientLeft, n.bottom = n.top + t.clientHeight, n.right = n.left + t.clientWidth, n.width = t.clientWidth, n.height = t.clientHeight, n.x = n.left, n.y = n.top, n; } -function ja(t, e, n) { - return e === Ns ? to(Rf(t, n)) : ke(e) ? Pf(e, n) : to(_f(le(t))); +function La(t, e, n) { + return e === Ns ? oo(Rf(t, n)) : ke(e) ? Pf(e, n) : oo(_f(le(t))); } function $f(t) { var e = fn(xr(t)), n = ["absolute", "fixed"].indexOf(te(t).position) >= 0, r = n && jt(t) ? Pn(t) : t; @@ -7271,17 +7304,17 @@ function $f(t) { return ke(o) && Ss(o, r) && qt(o) !== "body"; }) : []; } -function If(t, e, n, r) { +function Af(t, e, n, r) { var o = e === "clippingParents" ? $f(t) : [].concat(e), a = [].concat(o, [n]), i = a[0], l = a.reduce(function(c, d) { - var p = ja(t, d, r); + var p = La(t, d, r); return c.top = ve(p.top, c.top), c.right = Jn(p.right, c.right), c.bottom = Jn(p.bottom, c.bottom), c.left = ve(p.left, c.left), c; - }, ja(t, i, r)); + }, La(t, i, r)); return l.width = l.right - l.left, l.height = l.bottom - l.top, l.x = l.left, l.y = l.top, l; } function _s(t) { var e = t.reference, n = t.element, r = t.placement, o = r ? Yt(r) : null, a = r ? Ge(r) : null, i = e.x + e.width / 2 - n.width / 2, l = e.y + e.height / 2 - n.height / 2, c; switch (o) { - case Tt: + case Ct: c = { x: i, y: e.y - n.height @@ -7299,7 +7332,7 @@ function _s(t) { y: l }; break; - case Ct: + case Ot: c = { x: e.x - n.width, y: l @@ -7311,7 +7344,7 @@ function _s(t) { y: e.y }; } - var d = o ? Po(o) : null; + var d = o ? Mo(o) : null; if (d != null) { var p = d === "y" ? "height" : "width"; switch (a) { @@ -7327,12 +7360,12 @@ function _s(t) { } function kn(t, e) { e === void 0 && (e = {}); - var n = e, r = n.placement, o = r === void 0 ? t.placement : r, a = n.strategy, i = a === void 0 ? t.strategy : a, l = n.boundary, c = l === void 0 ? Zw : l, d = n.rootBoundary, p = d === void 0 ? Ns : d, m = n.elementContext, w = m === void 0 ? rn : m, g = n.altBoundary, v = g === void 0 ? !1 : g, f = n.padding, h = f === void 0 ? 0 : f, E = Cs(typeof h != "number" ? h : Os(h, _n)), _ = w === rn ? Qw : rn, C = t.rects.popper, S = t.elements[v ? _ : w], b = If(ke(S) ? S : S.contextElement || le(t.elements.popper), c, p, i), I = Ue(t.elements.reference), z = _s({ - reference: I, + var n = e, r = n.placement, o = r === void 0 ? t.placement : r, a = n.strategy, i = a === void 0 ? t.strategy : a, l = n.boundary, c = l === void 0 ? Zw : l, d = n.rootBoundary, p = d === void 0 ? Ns : d, h = n.elementContext, w = h === void 0 ? rn : h, g = n.altBoundary, v = g === void 0 ? !1 : g, f = n.padding, m = f === void 0 ? 0 : f, E = Cs(typeof m != "number" ? m : Os(m, _n)), _ = w === rn ? Qw : rn, C = t.rects.popper, S = t.elements[v ? _ : w], b = Af(ke(S) ? S : S.contextElement || le(t.elements.popper), c, p, i), A = Ue(t.elements.reference), z = _s({ + reference: A, element: C, strategy: "absolute", placement: o - }), H = to(Object.assign({}, C, z)), O = w === rn ? H : I, $ = { + }), H = oo(Object.assign({}, C, z)), O = w === rn ? H : A, $ = { top: b.top - O.top + E.top, bottom: O.bottom - b.bottom + E.bottom, left: b.left - O.left + E.left, @@ -7341,20 +7374,20 @@ function kn(t, e) { if (w === rn && k) { var B = k[o]; Object.keys($).forEach(function(D) { - var J = [zt, Vt].indexOf(D) >= 0 ? 1 : -1, q = [Tt, Vt].indexOf(D) >= 0 ? "y" : "x"; + var J = [zt, Vt].indexOf(D) >= 0 ? 1 : -1, q = [Ct, Vt].indexOf(D) >= 0 ? "y" : "x"; $[D] += B[q] * J; }); } return $; } -function Af(t, e) { +function If(t, e) { e === void 0 && (e = {}); - var n = e, r = n.placement, o = n.boundary, a = n.rootBoundary, i = n.padding, l = n.flipVariations, c = n.allowedAutoPlacements, d = c === void 0 ? ks : c, p = Ge(r), m = p ? l ? Aa : Aa.filter(function(v) { + var n = e, r = n.placement, o = n.boundary, a = n.rootBoundary, i = n.padding, l = n.flipVariations, c = n.allowedAutoPlacements, d = c === void 0 ? ks : c, p = Ge(r), h = p ? l ? Ba : Ba.filter(function(v) { return Ge(v) === p; - }) : _n, w = m.filter(function(v) { + }) : _n, w = h.filter(function(v) { return d.indexOf(v) >= 0; }); - w.length === 0 && (w = m); + w.length === 0 && (w = h); var g = w.reduce(function(v, f) { return v[f] = kn(t, { placement: f, @@ -7368,32 +7401,32 @@ function Af(t, e) { }); } function Mf(t) { - if (Yt(t) === Oo) + if (Yt(t) === $o) return []; var e = Xn(t); - return [Ba(t), e, Ba(e)]; + return [za(t), e, za(e)]; } function Df(t) { var e = t.state, n = t.options, r = t.name; if (!e.modifiersData[r]._skip) { - for (var o = n.mainAxis, a = o === void 0 ? !0 : o, i = n.altAxis, l = i === void 0 ? !0 : i, c = n.fallbackPlacements, d = n.padding, p = n.boundary, m = n.rootBoundary, w = n.altBoundary, g = n.flipVariations, v = g === void 0 ? !0 : g, f = n.allowedAutoPlacements, h = e.options.placement, E = Yt(h), _ = E === h, C = c || (_ || !v ? [Xn(h)] : Mf(h)), S = [h].concat(C).reduce(function(V, W) { - return V.concat(Yt(W) === Oo ? Af(e, { + for (var o = n.mainAxis, a = o === void 0 ? !0 : o, i = n.altAxis, l = i === void 0 ? !0 : i, c = n.fallbackPlacements, d = n.padding, p = n.boundary, h = n.rootBoundary, w = n.altBoundary, g = n.flipVariations, v = g === void 0 ? !0 : g, f = n.allowedAutoPlacements, m = e.options.placement, E = Yt(m), _ = E === m, C = c || (_ || !v ? [Xn(m)] : Mf(m)), S = [m].concat(C).reduce(function(V, W) { + return V.concat(Yt(W) === $o ? If(e, { placement: W, boundary: p, - rootBoundary: m, + rootBoundary: h, padding: d, flipVariations: v, allowedAutoPlacements: f }) : W); - }, []), b = e.rects.reference, I = e.rects.popper, z = /* @__PURE__ */ new Map(), H = !0, O = S[0], $ = 0; $ < S.length; $++) { - var k = S[$], B = Yt(k), D = Ge(k) === Le, J = [Tt, Vt].indexOf(B) >= 0, q = J ? "width" : "height", U = kn(e, { + }, []), b = e.rects.reference, A = e.rects.popper, z = /* @__PURE__ */ new Map(), H = !0, O = S[0], $ = 0; $ < S.length; $++) { + var k = S[$], B = Yt(k), D = Ge(k) === Le, J = [Ct, Vt].indexOf(B) >= 0, q = J ? "width" : "height", U = kn(e, { placement: k, boundary: p, - rootBoundary: m, + rootBoundary: h, altBoundary: w, padding: d - }), tt = J ? D ? zt : Ct : D ? Vt : Tt; - b[q] > I[q] && (tt = Xn(tt)); + }), tt = J ? D ? zt : Ot : D ? Vt : Ct; + b[q] > A[q] && (tt = Xn(tt)); var at = Xn(tt), rt = []; if (a && rt.push(U[B] <= 0), l && rt.push(U[tt] <= 0, U[at] <= 0), rt.every(function(V) { return V; @@ -7432,7 +7465,7 @@ const Bf = { _skip: !1 } }; -function Va(t, e, n) { +function Fa(t, e, n) { return n === void 0 && (n = { x: 0, y: 0 @@ -7443,8 +7476,8 @@ function Va(t, e, n) { left: t.left - e.width - n.x }; } -function za(t) { - return [Tt, zt, Vt, Ct].some(function(e) { +function Ua(t) { + return [Ct, zt, Vt, Ot].some(function(e) { return t[e] >= 0; }); } @@ -7453,15 +7486,15 @@ function jf(t) { elementContext: "reference" }), l = kn(e, { altBoundary: !0 - }), c = Va(i, r), d = Va(l, o, a), p = za(c), m = za(d); + }), c = Fa(i, r), d = Fa(l, o, a), p = Ua(c), h = Ua(d); e.modifiersData[n] = { referenceClippingOffsets: c, popperEscapeOffsets: d, isReferenceHidden: p, - hasPopperEscaped: m + hasPopperEscaped: h }, e.attributes.popper = Object.assign({}, e.attributes.popper, { "data-popper-reference-hidden": p, - "data-popper-escaped": m + "data-popper-escaped": h }); } const Vf = { @@ -7472,10 +7505,10 @@ const Vf = { fn: jf }; function zf(t, e, n) { - var r = Yt(t), o = [Ct, Tt].indexOf(r) >= 0 ? -1 : 1, a = typeof n == "function" ? n(Object.assign({}, e, { + var r = Yt(t), o = [Ot, Ct].indexOf(r) >= 0 ? -1 : 1, a = typeof n == "function" ? n(Object.assign({}, e, { placement: t })) : n, i = a[0], l = a[1]; - return i = i || 0, l = (l || 0) * o, [Ct, zt].indexOf(r) >= 0 ? { + return i = i || 0, l = (l || 0) * o, [Ot, zt].indexOf(r) >= 0 ? { x: l, y: i } : { @@ -7484,8 +7517,8 @@ function zf(t, e, n) { }; } function Lf(t) { - var e = t.state, n = t.options, r = t.name, o = n.offset, a = o === void 0 ? [0, 0] : o, i = ks.reduce(function(p, m) { - return p[m] = zf(m, e.rects, a), p; + var e = t.state, n = t.options, r = t.name, o = n.offset, a = o === void 0 ? [0, 0] : o, i = ks.reduce(function(p, h) { + return p[h] = zf(h, e.rects, a), p; }, {}), l = i[e.placement], c = l.x, d = l.y; e.modifiersData.popperOffsets != null && (e.modifiersData.popperOffsets.x += c, e.modifiersData.popperOffsets.y += d), e.modifiersData[r] = i; } @@ -7516,12 +7549,12 @@ function Hf(t) { return t === "x" ? "y" : "x"; } function Xf(t) { - var e = t.state, n = t.options, r = t.name, o = n.mainAxis, a = o === void 0 ? !0 : o, i = n.altAxis, l = i === void 0 ? !1 : i, c = n.boundary, d = n.rootBoundary, p = n.altBoundary, m = n.padding, w = n.tether, g = w === void 0 ? !0 : w, v = n.tetherOffset, f = v === void 0 ? 0 : v, h = kn(e, { + var e = t.state, n = t.options, r = t.name, o = n.mainAxis, a = o === void 0 ? !0 : o, i = n.altAxis, l = i === void 0 ? !1 : i, c = n.boundary, d = n.rootBoundary, p = n.altBoundary, h = n.padding, w = n.tether, g = w === void 0 ? !0 : w, v = n.tetherOffset, f = v === void 0 ? 0 : v, m = kn(e, { boundary: c, rootBoundary: d, - padding: m, + padding: h, altBoundary: p - }), E = Yt(e.placement), _ = Ge(e.placement), C = !_, S = Po(E), b = Hf(S), I = e.modifiersData.popperOffsets, z = e.rects.reference, H = e.rects.popper, O = typeof f == "function" ? f(Object.assign({}, e.rects, { + }), E = Yt(e.placement), _ = Ge(e.placement), C = !_, S = Mo(E), b = Hf(S), A = e.modifiersData.popperOffsets, z = e.rects.reference, H = e.rects.popper, O = typeof f == "function" ? f(Object.assign({}, e.rects, { placement: e.placement })) : f, $ = typeof O == "number" ? { mainAxis: O, @@ -7533,17 +7566,17 @@ function Xf(t) { x: 0, y: 0 }; - if (I) { + if (A) { if (a) { - var D, J = S === "y" ? Tt : Ct, q = S === "y" ? Vt : zt, U = S === "y" ? "height" : "width", tt = I[S], at = tt + h[J], rt = tt - h[q], y = g ? -H[U] / 2 : 0, R = _ === Le ? z[U] : H[U], L = _ === Le ? -H[U] : -z[U], F = e.elements.arrow, V = g && F ? _o(F) : { + var D, J = S === "y" ? Ct : Ot, q = S === "y" ? Vt : zt, U = S === "y" ? "height" : "width", tt = A[S], at = tt + m[J], rt = tt - m[q], y = g ? -H[U] / 2 : 0, R = _ === Le ? z[U] : H[U], L = _ === Le ? -H[U] : -z[U], F = e.elements.arrow, V = g && F ? Io(F) : { width: 0, height: 0 - }, W = e.modifiersData["arrow#persistent"] ? e.modifiersData["arrow#persistent"].padding : Ts(), X = W[J], Y = W[q], G = wn(0, z[U], V[U]), K = C ? z[U] / 2 - y - G - X - $.mainAxis : R - G - X - $.mainAxis, Z = C ? -z[U] / 2 + y + G + Y + $.mainAxis : L + G + Y + $.mainAxis, dt = e.elements.arrow && Pn(e.elements.arrow), A = dt ? S === "y" ? dt.clientTop || 0 : dt.clientLeft || 0 : 0, Nt = (D = k == null ? void 0 : k[S]) != null ? D : 0, j = tt + K - Nt - A, xt = tt + Z - Nt, Ft = wn(g ? Jn(at, j) : at, tt, g ? ve(rt, xt) : rt); - I[S] = Ft, B[S] = Ft - tt; + }, W = e.modifiersData["arrow#persistent"] ? e.modifiersData["arrow#persistent"].padding : Ts(), X = W[J], Y = W[q], G = wn(0, z[U], V[U]), K = C ? z[U] / 2 - y - G - X - $.mainAxis : R - G - X - $.mainAxis, Z = C ? -z[U] / 2 + y + G + Y + $.mainAxis : L + G + Y + $.mainAxis, dt = e.elements.arrow && Pn(e.elements.arrow), I = dt ? S === "y" ? dt.clientTop || 0 : dt.clientLeft || 0 : 0, Nt = (D = k == null ? void 0 : k[S]) != null ? D : 0, j = tt + K - Nt - I, xt = tt + Z - Nt, Ft = wn(g ? Jn(at, j) : at, tt, g ? ve(rt, xt) : rt); + A[S] = Ft, B[S] = Ft - tt; } if (l) { - var ce, Et = S === "x" ? Tt : Ct, In = S === "x" ? Vt : zt, Ut = I[b], Ee = b === "y" ? "height" : "width", de = Ut + h[Et], Se = Ut - h[In], Te = [Tt, Ct].indexOf(E) !== -1, Ce = (ce = k == null ? void 0 : k[b]) != null ? ce : 0, pe = Te ? de : Ut - z[Ee] - H[Ee] - Ce + $.altAxis, qe = Te ? Ut + z[Ee] + H[Ee] - Ce - $.altAxis : Se, An = g && Te ? hf(pe, Ut, qe) : wn(g ? pe : de, Ut, g ? qe : Se); - I[b] = An, B[b] = An - Ut; + var ce, Et = S === "x" ? Ct : Ot, An = S === "x" ? Vt : zt, Ut = A[b], Ee = b === "y" ? "height" : "width", de = Ut + m[Et], Se = Ut - m[An], Te = [Ct, Ot].indexOf(E) !== -1, Ce = (ce = k == null ? void 0 : k[b]) != null ? ce : 0, pe = Te ? de : Ut - z[Ee] - H[Ee] - Ce + $.altAxis, qe = Te ? Ut + z[Ee] + H[Ee] - Ce - $.altAxis : Se, In = g && Te ? hf(pe, Ut, qe) : wn(g ? pe : de, Ut, g ? qe : Se); + A[b] = In, B[b] = In - Ut; } e.modifiersData[r] = B; } @@ -7562,7 +7595,7 @@ function Wf(t) { }; } function qf(t) { - return t === At(t) || !jt(t) ? $o(t) : Wf(t); + return t === Mt(t) || !jt(t) ? Do(t) : Wf(t); } function Kf(t) { var e = t.getBoundingClientRect(), n = Fe(e.width) / t.offsetWidth || 1, r = Fe(e.height) / t.offsetHeight || 1; @@ -7578,7 +7611,7 @@ function Jf(t, e, n) { y: 0 }; return (r || !r && !n) && ((qt(e) !== "body" || // https://github.com/popperjs/popper-core/issues/1078 - Ao(a)) && (l = qf(e)), jt(e) ? (c = Ue(e, !0), c.x += e.clientLeft, c.y += e.clientTop) : a && (c.x = Io(a))), { + jo(a)) && (l = qf(e)), jt(e) ? (c = Ue(e, !0), c.x += e.clientLeft, c.y += e.clientTop) : a && (c.x = Bo(a))), { x: i.left + l.scrollLeft - c.x, y: i.top + l.scrollTop - c.y, width: i.width, @@ -7634,12 +7667,12 @@ function em(t) { return e[n]; }); } -var La = { +var Ga = { placement: "bottom", modifiers: [], strategy: "absolute" }; -function Fa() { +function Ha() { for (var t = arguments.length, e = new Array(t), n = 0; n < t; n++) e[n] = arguments[n]; return !e.some(function(r) { @@ -7648,13 +7681,13 @@ function Fa() { } function nm(t) { t === void 0 && (t = {}); - var e = t, n = e.defaultModifiers, r = n === void 0 ? [] : n, o = e.defaultOptions, a = o === void 0 ? La : o; + var e = t, n = e.defaultModifiers, r = n === void 0 ? [] : n, o = e.defaultOptions, a = o === void 0 ? Ga : o; return function(l, c, d) { d === void 0 && (d = a); var p = { placement: "bottom", orderedModifiers: [], - options: Object.assign({}, La, a), + options: Object.assign({}, Ga, a), modifiersData: {}, elements: { reference: l, @@ -7662,7 +7695,7 @@ function nm(t) { }, attributes: {}, styles: {} - }, m = [], w = !1, g = { + }, h = [], w = !1, g = { state: p, setOptions: function(E) { var _ = typeof E == "function" ? E(p.options) : E; @@ -7683,10 +7716,10 @@ function nm(t) { forceUpdate: function() { if (!w) { var E = p.elements, _ = E.reference, C = E.popper; - if (Fa(_, C)) { + if (Ha(_, C)) { p.rects = { reference: Jf(_, Pn(C), p.options.strategy === "fixed"), - popper: _o(C) + popper: Io(C) }, p.reset = !1, p.placement = p.options.placement, p.orderedModifiers.forEach(function($) { return p.modifiersData[$.name] = Object.assign({}, $.data); }); @@ -7695,8 +7728,8 @@ function nm(t) { p.reset = !1, S = -1; continue; } - var b = p.orderedModifiers[S], I = b.fn, z = b.options, H = z === void 0 ? {} : z, O = b.name; - typeof I == "function" && (p = I({ + var b = p.orderedModifiers[S], A = b.fn, z = b.options, H = z === void 0 ? {} : z, O = b.name; + typeof A == "function" && (p = A({ state: p, options: H, name: O, @@ -7709,38 +7742,38 @@ function nm(t) { // Async and optimistically optimized update – it will not be executed if // not necessary (debounced to run at most once-per-tick) update: tm(function() { - return new Promise(function(h) { - g.forceUpdate(), h(p); + return new Promise(function(m) { + g.forceUpdate(), m(p); }); }), destroy: function() { f(), w = !0; } }; - if (!Fa(l, c)) + if (!Ha(l, c)) return g; - g.setOptions(d).then(function(h) { - !w && d.onFirstUpdate && d.onFirstUpdate(h); + g.setOptions(d).then(function(m) { + !w && d.onFirstUpdate && d.onFirstUpdate(m); }); function v() { - p.orderedModifiers.forEach(function(h) { - var E = h.name, _ = h.options, C = _ === void 0 ? {} : _, S = h.effect; + p.orderedModifiers.forEach(function(m) { + var E = m.name, _ = m.options, C = _ === void 0 ? {} : _, S = m.effect; if (typeof S == "function") { var b = S({ state: p, name: E, instance: g, options: C - }), I = function() { + }), A = function() { }; - m.push(b || I); + h.push(b || A); } }); } function f() { - m.forEach(function(h) { - return h(); - }), m = []; + h.forEach(function(m) { + return m(); + }), h = []; } return g; }; @@ -7779,7 +7812,7 @@ function Nr(t) { function cm(t) { return !Nr(t); } -const dm = () => go({ +const dm = () => xo({ root: ["root"] }, Fw(am)), pm = {}, um = /* @__PURE__ */ M.forwardRef(function(e, n) { var r; @@ -7791,18 +7824,18 @@ const dm = () => go({ modifiers: c, open: d, placement: p, - popperOptions: m, + popperOptions: h, popperRef: w, slotProps: g = {}, slots: v = {}, TransitionProps: f // @ts-ignore internal logic // prevent from spreading to DOM, it can come from the parent component e.g. Select. - } = e, h = kt(e, im), E = M.useRef(null), _ = xe(E, n), C = M.useRef(null), S = xe(C, w), b = M.useRef(S); + } = e, m = kt(e, im), E = M.useRef(null), _ = xe(E, n), C = M.useRef(null), S = xe(C, w), b = M.useRef(S); ze(() => { b.current = S; }, [S]), M.useImperativeHandle(w, () => C.current, []); - const I = lm(p, i), [z, H] = M.useState(I), [O, $] = M.useState(Zn(o)); + const A = lm(p, i), [z, H] = M.useState(A), [O, $] = M.useState(Zn(o)); M.useEffect(() => { C.current && C.current.forceUpdate(); }), M.useEffect(() => { @@ -7838,16 +7871,16 @@ const dm = () => go({ q(at); } }]; - c != null && (U = U.concat(c)), m && m.modifiers != null && (U = U.concat(m.modifiers)); + c != null && (U = U.concat(c)), h && h.modifiers != null && (U = U.concat(h.modifiers)); const tt = om(O, E.current, P({ - placement: I - }, m, { + placement: A + }, h, { modifiers: U })); return b.current(tt), () => { tt.destroy(), b.current(null); }; - }, [O, l, c, d, m, I]); + }, [O, l, c, d, h, A]); const k = { placement: z }; @@ -7855,7 +7888,7 @@ const dm = () => go({ const B = dm(), D = (r = v.root) != null ? r : "div", J = Yw({ elementType: D, externalSlotProps: g.root, - externalForwardedProps: h, + externalForwardedProps: m, additionalProps: { role: "tooltip", ref: _ @@ -7876,16 +7909,16 @@ const dm = () => go({ keepMounted: c = !1, modifiers: d, open: p, - placement: m = "bottom", + placement: h = "bottom", popperOptions: w = pm, popperRef: g, style: v, transition: f = !1, - slotProps: h = {}, + slotProps: m = {}, slots: E = {} } = e, _ = kt(e, sm), [C, S] = M.useState(!0), b = () => { S(!1); - }, I = () => { + }, A = () => { S(!0); }; if (!c && !p && (!f || C)) @@ -7900,7 +7933,7 @@ const dm = () => go({ const H = !p && c && (!f || C) ? "none" : void 0, O = f ? { in: p, onEnter: b, - onExited: I + onExited: A } : void 0; return /* @__PURE__ */ s(Kn, { disablePortal: l, @@ -7912,10 +7945,10 @@ const dm = () => go({ modifiers: d, ref: n, open: f ? !C : p, - placement: m, + placement: h, popperOptions: w, popperRef: g, - slotProps: h, + slotProps: m, slots: E }, _, { style: P({ @@ -7942,7 +7975,7 @@ process.env.NODE_ENV !== "production" && ($s.propTypes = { * It's used to set the position of the popper. * The return value will passed as the reference object of the Popper instance. */ - anchorEl: mo(u.oneOfType([yn, u.object, u.func]), (t) => { + anchorEl: vo(u.oneOfType([yn, u.object, u.func]), (t) => { if (t.open) { const e = Zn(t.anchorEl); if (e && Nr(e) && e.nodeType === 1) { @@ -8052,19 +8085,19 @@ process.env.NODE_ENV !== "production" && ($s.propTypes = { */ transition: u.bool }); -function Is() { - const t = hs(Eo); - return process.env.NODE_ENV !== "production" && M.useDebugValue(t), t[So] || t; +function As() { + const t = hs(Oo); + return process.env.NODE_ENV !== "production" && M.useDebugValue(t), t[Ro] || t; } -function eo(t, e) { - return eo = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function(r, o) { +function ao(t, e) { + return ao = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function(r, o) { return r.__proto__ = o, r; - }, eo(t, e); + }, ao(t, e); } function wm(t, e) { - t.prototype = Object.create(e.prototype), t.prototype.constructor = t, eo(t, e); + t.prototype = Object.create(e.prototype), t.prototype.constructor = t, ao(t, e); } -const Ua = { +const Xa = { disabled: !1 }; var fm = process.env.NODE_ENV !== "production" ? u.oneOfType([u.number, u.shape({ @@ -8084,16 +8117,16 @@ process.env.NODE_ENV !== "production" && u.oneOfType([u.string, u.shape({ exitDone: u.string, exitActive: u.string })]); -const As = T.createContext(null); +const Is = T.createContext(null); var mm = function(e) { return e.scrollTop; -}, cn = "unmounted", fe = "exited", me = "entering", Ae = "entered", no = "exiting", ee = /* @__PURE__ */ function(t) { +}, cn = "unmounted", fe = "exited", me = "entering", Ie = "entered", io = "exiting", ee = /* @__PURE__ */ function(t) { wm(e, t); function e(r, o) { var a; a = t.call(this, r, o) || this; var i = o, l = i && !i.isMounting ? r.enter : r.appear, c; - return a.appearStatus = null, r.in ? l ? (c = fe, a.appearStatus = me) : c = Ae : r.unmountOnExit || r.mountOnEnter ? c = cn : c = fe, a.state = { + return a.appearStatus = null, r.in ? l ? (c = fe, a.appearStatus = me) : c = Ie : r.unmountOnExit || r.mountOnEnter ? c = cn : c = fe, a.state = { status: c }, a.nextCallback = null, a; } @@ -8110,7 +8143,7 @@ var mm = function(e) { var a = null; if (o !== this.props) { var i = this.state.status; - this.props.in ? i !== me && i !== Ae && (a = me) : (i === me || i === Ae) && (a = no); + this.props.in ? i !== me && i !== Ie && (a = me) : (i === me || i === Ie) && (a = io); } this.updateStatus(!1, a); }, n.componentWillUnmount = function() { @@ -8137,10 +8170,10 @@ var mm = function(e) { status: cn }); }, n.performEnter = function(o) { - var a = this, i = this.props.enter, l = this.context ? this.context.isMounting : o, c = this.props.nodeRef ? [l] : [Bn.findDOMNode(this), l], d = c[0], p = c[1], m = this.getTimeouts(), w = l ? m.appear : m.enter; - if (!o && !i || Ua.disabled) { + var a = this, i = this.props.enter, l = this.context ? this.context.isMounting : o, c = this.props.nodeRef ? [l] : [Bn.findDOMNode(this), l], d = c[0], p = c[1], h = this.getTimeouts(), w = l ? h.appear : h.enter; + if (!o && !i || Xa.disabled) { this.safeSetState({ - status: Ae + status: Ie }, function() { a.props.onEntered(d); }); @@ -8151,7 +8184,7 @@ var mm = function(e) { }, function() { a.props.onEntering(d, p), a.onTransitionEnd(w, function() { a.safeSetState({ - status: Ae + status: Ie }, function() { a.props.onEntered(d, p); }); @@ -8159,7 +8192,7 @@ var mm = function(e) { }); }, n.performExit = function() { var o = this, a = this.props.exit, i = this.getTimeouts(), l = this.props.nodeRef ? void 0 : Bn.findDOMNode(this); - if (!a || Ua.disabled) { + if (!a || Xa.disabled) { this.safeSetState({ status: fe }, function() { @@ -8168,7 +8201,7 @@ var mm = function(e) { return; } this.props.onExit(l), this.safeSetState({ - status: no + status: io }, function() { o.props.onExiting(l), o.onTransitionEnd(i.exit, function() { o.safeSetState({ @@ -8210,13 +8243,13 @@ var mm = function(e) { var l = kt(a, ["children", "in", "mountOnEnter", "unmountOnExit", "appear", "enter", "exit", "timeout", "addEndListener", "onEnter", "onEntering", "onEntered", "onExit", "onExiting", "onExited", "nodeRef"]); return ( // allows for nested Transitions - /* @__PURE__ */ T.createElement(As.Provider, { + /* @__PURE__ */ T.createElement(Is.Provider, { value: null }, typeof i == "function" ? i(o, l) : T.cloneElement(T.Children.only(i), l)) ); }, e; }(T.Component); -ee.contextType = As; +ee.contextType = Is; ee.propTypes = process.env.NODE_ENV !== "production" ? { /** * A React reference to DOM element that need to transition: @@ -8386,7 +8419,7 @@ ee.propTypes = process.env.NODE_ENV !== "production" ? { */ onExited: u.func } : {}; -function Ie() { +function Ae() { } ee.defaultProps = { in: !1, @@ -8395,20 +8428,20 @@ ee.defaultProps = { appear: !1, enter: !0, exit: !0, - onEnter: Ie, - onEntering: Ie, - onEntered: Ie, - onExit: Ie, - onExiting: Ie, - onExited: Ie + onEnter: Ae, + onEntering: Ae, + onEntered: Ae, + onExit: Ae, + onExiting: Ae, + onExited: Ae }; ee.UNMOUNTED = cn; ee.EXITED = fe; ee.ENTERING = me; -ee.ENTERED = Ae; -ee.EXITING = no; +ee.ENTERED = Ie; +ee.EXITING = io; const hm = ee, gm = (t) => t.scrollTop; -function Ga(t, e) { +function Ya(t, e) { var n, r; const { timeout: o, @@ -8422,19 +8455,19 @@ function Ga(t, e) { }; } const bm = ["addEndListener", "appear", "children", "easing", "in", "onEnter", "onEntered", "onEntering", "onExit", "onExited", "onExiting", "style", "timeout", "TransitionComponent"]; -function ro(t) { +function so(t) { return `scale(${t}, ${t ** 2})`; } const vm = { entering: { opacity: 1, - transform: ro(1) + transform: so(1) }, entered: { opacity: 1, transform: "none" } -}, Ur = typeof navigator < "u" && /^((?!chrome|android).)*(safari|mobile)/i.test(navigator.userAgent) && /(os |version\/)15(.|_)4/i.test(navigator.userAgent), Mo = /* @__PURE__ */ M.forwardRef(function(e, n) { +}, Ur = typeof navigator < "u" && /^((?!chrome|android).)*(safari|mobile)/i.test(navigator.userAgent) && /(os |version\/)15(.|_)4/i.test(navigator.userAgent), Vo = /* @__PURE__ */ M.forwardRef(function(e, n) { const { addEndListener: r, appear: o = !0, @@ -8444,14 +8477,14 @@ const vm = { onEnter: c, onEntered: d, onEntering: p, - onExit: m, + onExit: h, onExited: w, onExiting: g, style: v, timeout: f = "auto", // eslint-disable-next-line react/prop-types - TransitionComponent: h = hm - } = e, E = kt(e, bm), _ = sn(), C = M.useRef(), S = Is(), b = M.useRef(null), I = xe(b, a.ref, n), z = (q) => (U) => { + TransitionComponent: m = hm + } = e, E = kt(e, bm), _ = sn(), C = M.useRef(), S = As(), b = M.useRef(null), A = xe(b, a.ref, n), z = (q) => (U) => { if (q) { const tt = b.current; U === void 0 ? q(tt) : q(tt, U); @@ -8462,7 +8495,7 @@ const vm = { duration: tt, delay: at, easing: rt - } = Ga({ + } = Ya({ style: v, timeout: f, easing: i @@ -8483,7 +8516,7 @@ const vm = { duration: U, delay: tt, easing: at - } = Ga({ + } = Ya({ style: v, timeout: f, easing: i @@ -8498,9 +8531,9 @@ const vm = { duration: Ur ? rt : rt * 0.666, delay: Ur ? tt : tt || rt * 0.333, easing: at - })].join(","), q.style.opacity = 0, q.style.transform = ro(0.75), m && m(q); + })].join(","), q.style.opacity = 0, q.style.transform = so(0.75), h && h(q); }), D = z(w); - return /* @__PURE__ */ s(h, P({ + return /* @__PURE__ */ s(m, P({ appear: o, in: l, nodeRef: b, @@ -8518,14 +8551,14 @@ const vm = { children: (q, U) => /* @__PURE__ */ M.cloneElement(a, P({ style: P({ opacity: 0, - transform: ro(0.75), + transform: so(0.75), visibility: q === "exited" && !l ? "hidden" : void 0 }, vm[q], v, a.props.style), - ref: I + ref: A }, U)) })); }); -process.env.NODE_ENV !== "production" && (Mo.propTypes = { +process.env.NODE_ENV !== "production" && (Vo.propTypes = { // ┌────────────────────────────── Warning ──────────────────────────────┐ // │ These PropTypes are generated from the TypeScript type definitions. │ // │ To update them, edit the d.ts file and run `pnpm proptypes`. │ @@ -8599,14 +8632,14 @@ process.env.NODE_ENV !== "production" && (Mo.propTypes = { exit: u.number })]) }); -Mo.muiSupportAuto = !0; -const Ha = Mo, ym = ["anchorEl", "component", "components", "componentsProps", "container", "disablePortal", "keepMounted", "modifiers", "open", "placement", "popperOptions", "popperRef", "transition", "slots", "slotProps"], xm = Rn($s, { +Vo.muiSupportAuto = !0; +const Wa = Vo, ym = ["anchorEl", "component", "components", "componentsProps", "container", "disablePortal", "keepMounted", "modifiers", "open", "placement", "popperOptions", "popperRef", "transition", "slots", "slotProps"], xm = Rn($s, { name: "MuiPopper", slot: "Root", overridesResolver: (t, e) => e.root })({}), Ms = /* @__PURE__ */ M.forwardRef(function(e, n) { var r; - const o = ms(), a = To({ + const o = ms(), a = _o({ props: e, name: "MuiPopper" }), { @@ -8615,25 +8648,25 @@ const Ha = Mo, ym = ["anchorEl", "component", "components", "componentsProps", " components: c, componentsProps: d, container: p, - disablePortal: m, + disablePortal: h, keepMounted: w, modifiers: g, open: v, placement: f, - popperOptions: h, + popperOptions: m, popperRef: E, transition: _, slots: C, slotProps: S - } = a, b = kt(a, ym), I = (r = C == null ? void 0 : C.root) != null ? r : c == null ? void 0 : c.Root, z = P({ + } = a, b = kt(a, ym), A = (r = C == null ? void 0 : C.root) != null ? r : c == null ? void 0 : c.Root, z = P({ anchorEl: i, container: p, - disablePortal: m, + disablePortal: h, keepMounted: w, modifiers: g, open: v, placement: f, - popperOptions: h, + popperOptions: m, popperRef: E, transition: _ }, b); @@ -8641,7 +8674,7 @@ const Ha = Mo, ym = ["anchorEl", "component", "components", "componentsProps", " as: l, direction: o == null ? void 0 : o.direction, slots: { - root: I + root: A }, slotProps: S ?? d }, z, { @@ -8795,7 +8828,7 @@ const Tm = (t) => { tooltip: ["tooltip", r && "tooltipArrow", o && "touch", `tooltipPlacement${Wt(a.split("-")[0])}`], arrow: ["arrow"] }; - return go(i, Nm, e); + return xo(i, Nm, e); }, Cm = Rn(Ds, { name: "MuiTooltip", slot: "Popper", @@ -8947,7 +8980,7 @@ const Tm = (t) => { } })); let Ln = !1; -const Xa = new Tn(); +const qa = new Tn(); let on = { x: 0, y: 0 @@ -8958,8 +8991,8 @@ function Fn(t, e) { }; } const Bs = /* @__PURE__ */ M.forwardRef(function(e, n) { - var r, o, a, i, l, c, d, p, m, w, g, v, f, h, E, _, C, S, b; - const I = To({ + var r, o, a, i, l, c, d, p, h, w, g, v, f, m, E, _, C, S, b; + const A = _o({ props: e, name: "MuiTooltip" }), { @@ -8988,17 +9021,17 @@ const Bs = /* @__PURE__ */ M.forwardRef(function(e, n) { slotProps: K = {}, slots: Z = {}, title: dt, - TransitionComponent: A = Ha, + TransitionComponent: I = Wa, TransitionProps: Nt - } = I, j = kt(I, Em), xt = /* @__PURE__ */ M.isValidElement(H) ? H : /* @__PURE__ */ s("span", { + } = A, j = kt(A, Em), xt = /* @__PURE__ */ M.isValidElement(H) ? H : /* @__PURE__ */ s("span", { children: H - }), Ft = Is(), ce = Ft.direction === "rtl", [Et, In] = M.useState(), [Ut, Ee] = M.useState(null), de = M.useRef(!1), Se = J || rt, Te = sn(), Ce = sn(), pe = sn(), qe = sn(), [An, Do] = is({ + }), Ft = As(), ce = Ft.direction === "rtl", [Et, An] = M.useState(), [Ut, Ee] = M.useState(null), de = M.useRef(!1), Se = J || rt, Te = sn(), Ce = sn(), pe = sn(), qe = sn(), [In, zo] = is({ controlled: W, default: !1, name: "Tooltip", state: "open" }); - let Kt = An; + let Kt = In; if (process.env.NODE_ENV !== "production") { const { current: Q @@ -9008,46 +9041,46 @@ const Bs = /* @__PURE__ */ M.forwardRef(function(e, n) { `)); }, [dt, Et, Q]); } - const kr = as(y), Ke = M.useRef(), Mn = Jr(() => { + const kr = as(y), Ke = M.useRef(), Mn = eo(() => { Ke.current !== void 0 && (document.body.style.WebkitUserSelect = Ke.current, Ke.current = void 0), qe.clear(); }); M.useEffect(() => Mn, [Mn]); - const Bo = (Q) => { - Xa.clear(), Ln = !0, Do(!0), V && !Kt && V(Q); - }, Dn = Jr( + const Lo = (Q) => { + qa.clear(), Ln = !0, zo(!0), V && !Kt && V(Q); + }, Dn = eo( /** * @param {React.SyntheticEvent | Event} event */ (Q) => { - Xa.start(800 + R, () => { + qa.start(800 + R, () => { Ln = !1; - }), Do(!1), F && Kt && F(Q), Te.start(Ft.transitions.duration.shortest, () => { + }), zo(!1), F && Kt && F(Q), Te.start(Ft.transitions.duration.shortest, () => { de.current = !1; }); } ), Er = (Q) => { de.current && Q.type !== "touchstart" || (Et && Et.removeAttribute("title"), Ce.clear(), pe.clear(), U || Ln && tt ? Ce.start(Ln ? tt : U, () => { - Bo(Q); - }) : Bo(Q)); - }, jo = (Q) => { + Lo(Q); + }) : Lo(Q)); + }, Fo = (Q) => { Ce.clear(), pe.start(R, () => { Dn(Q); }); }, { - isFocusVisibleRef: Vo, + isFocusVisibleRef: Uo, onBlur: Ls, onFocus: Fs, ref: Us - } = ss(), [, zo] = M.useState(!1), Lo = (Q) => { - Ls(Q), Vo.current === !1 && (zo(!1), jo(Q)); - }, Fo = (Q) => { - Et || In(Q.currentTarget), Fs(Q), Vo.current === !0 && (zo(!0), Er(Q)); - }, Uo = (Q) => { + } = ss(), [, Go] = M.useState(!1), Ho = (Q) => { + Ls(Q), Uo.current === !1 && (Go(!1), Fo(Q)); + }, Xo = (Q) => { + Et || An(Q.currentTarget), Fs(Q), Uo.current === !0 && (Go(!0), Er(Q)); + }, Yo = (Q) => { de.current = !0; - const _t = xt.props; - _t.onTouchStart && _t.onTouchStart(Q); - }, Go = Er, Ho = jo, Gs = (Q) => { - Uo(Q), pe.clear(), Te.clear(), Mn(), Ke.current = document.body.style.WebkitUserSelect, document.body.style.WebkitUserSelect = "none", qe.start(at, () => { + const Pt = xt.props; + Pt.onTouchStart && Pt.onTouchStart(Q); + }, Wo = Er, qo = Fo, Gs = (Q) => { + Yo(Q), pe.clear(), Te.clear(), Mn(), Ke.current = document.body.style.WebkitUserSelect, document.body.style.WebkitUserSelect = "none", qe.start(at, () => { document.body.style.WebkitUserSelect = Ke.current, Er(Q); }); }, Hs = (Q) => { @@ -9058,40 +9091,40 @@ const Bs = /* @__PURE__ */ M.forwardRef(function(e, n) { M.useEffect(() => { if (!Kt) return; - function Q(_t) { - (_t.key === "Escape" || _t.key === "Esc") && Dn(_t); + function Q(Pt) { + (Pt.key === "Escape" || Pt.key === "Esc") && Dn(Pt); } return document.addEventListener("keydown", Q), () => { document.removeEventListener("keydown", Q); }; }, [Dn, Kt]); - const Xs = xe(xt.ref, Us, In, n); + const Xs = xe(xt.ref, Us, An, n); !dt && dt !== 0 && (Kt = !1); const Sr = M.useRef(), Ys = (Q) => { - const _t = xt.props; - _t.onMouseMove && _t.onMouseMove(Q), on = { + const Pt = xt.props; + Pt.onMouseMove && Pt.onMouseMove(Q), on = { x: Q.clientX, y: Q.clientY }, Sr.current && Sr.current.update(); }, Je = {}, Tr = typeof dt == "string"; k ? (Je.title = !Kt && Tr && !D ? dt : null, Je["aria-describedby"] = Kt ? kr : null) : (Je["aria-label"] = Tr ? dt : null, Je["aria-labelledby"] = Kt && !Tr ? kr : null); - const Mt = P({}, Je, j, xt.props, { + const Dt = P({}, Je, j, xt.props, { className: be(j.className, xt.props.className), - onTouchStart: Uo, + onTouchStart: Yo, ref: Xs }, rt ? { onMouseMove: Ys } : {}); - process.env.NODE_ENV !== "production" && (Mt["data-mui-internal-clone-element"] = !0, M.useEffect(() => { + process.env.NODE_ENV !== "production" && (Dt["data-mui-internal-clone-element"] = !0, M.useEffect(() => { Et && !Et.getAttribute("data-mui-internal-clone-element") && console.error(["MUI: The `children` component of the Tooltip is not forwarding its props correctly.", "Please make sure that props are spread on the same element that the ref is applied to."].join(` `)); }, [Et])); const Ze = {}; - q || (Mt.onTouchStart = Gs, Mt.onTouchEnd = Hs), D || (Mt.onMouseOver = Fn(Go, Mt.onMouseOver), Mt.onMouseLeave = Fn(Ho, Mt.onMouseLeave), Se || (Ze.onMouseOver = Go, Ze.onMouseLeave = Ho)), B || (Mt.onFocus = Fn(Fo, Mt.onFocus), Mt.onBlur = Fn(Lo, Mt.onBlur), Se || (Ze.onFocus = Fo, Ze.onBlur = Lo)), process.env.NODE_ENV !== "production" && xt.props.title && console.error(["MUI: You have provided a `title` prop to the child of .", `Remove this title prop \`${xt.props.title}\` or the Tooltip component.`].join(` + q || (Dt.onTouchStart = Gs, Dt.onTouchEnd = Hs), D || (Dt.onMouseOver = Fn(Wo, Dt.onMouseOver), Dt.onMouseLeave = Fn(qo, Dt.onMouseLeave), Se || (Ze.onMouseOver = Wo, Ze.onMouseLeave = qo)), B || (Dt.onFocus = Fn(Xo, Dt.onFocus), Dt.onBlur = Fn(Ho, Dt.onBlur), Se || (Ze.onFocus = Xo, Ze.onBlur = Ho)), process.env.NODE_ENV !== "production" && xt.props.title && console.error(["MUI: You have provided a `title` prop to the child of .", `Remove this title prop \`${xt.props.title}\` or the Tooltip component.`].join(` `)); const Ws = M.useMemo(() => { var Q; - let _t = [{ + let Pt = [{ name: "arrow", enabled: !!Ut, options: { @@ -9099,25 +9132,25 @@ const Bs = /* @__PURE__ */ M.forwardRef(function(e, n) { padding: 4 } }]; - return (Q = G.popperOptions) != null && Q.modifiers && (_t = _t.concat(G.popperOptions.modifiers)), P({}, G.popperOptions, { - modifiers: _t + return (Q = G.popperOptions) != null && Q.modifiers && (Pt = Pt.concat(G.popperOptions.modifiers)), P({}, G.popperOptions, { + modifiers: Pt }); - }, [Ut, G]), Qe = P({}, I, { + }, [Ut, G]), Qe = P({}, A, { isRtl: ce, arrow: z, disableInteractive: Se, placement: X, PopperComponentProp: Y, touch: de.current - }), Cr = Tm(Qe), Xo = (r = (o = Z.popper) != null ? o : O.Popper) != null ? r : Cm, Yo = (a = (i = (l = Z.transition) != null ? l : O.Transition) != null ? i : A) != null ? a : Ha, Wo = (c = (d = Z.tooltip) != null ? d : O.Tooltip) != null ? c : Om, qo = (p = (m = Z.arrow) != null ? m : O.Arrow) != null ? p : Rm, qs = ln(Xo, P({}, G, (w = K.popper) != null ? w : $.popper, { + }), Cr = Tm(Qe), Ko = (r = (o = Z.popper) != null ? o : O.Popper) != null ? r : Cm, Jo = (a = (i = (l = Z.transition) != null ? l : O.Transition) != null ? i : I) != null ? a : Wa, Zo = (c = (d = Z.tooltip) != null ? d : O.Tooltip) != null ? c : Om, Qo = (p = (h = Z.arrow) != null ? h : O.Arrow) != null ? p : Rm, qs = ln(Ko, P({}, G, (w = K.popper) != null ? w : $.popper, { className: be(Cr.popper, G == null ? void 0 : G.className, (g = (v = K.popper) != null ? v : $.popper) == null ? void 0 : g.className) - }), Qe), Ks = ln(Yo, P({}, Nt, (f = K.transition) != null ? f : $.transition), Qe), Js = ln(Wo, P({}, (h = K.tooltip) != null ? h : $.tooltip, { + }), Qe), Ks = ln(Jo, P({}, Nt, (f = K.transition) != null ? f : $.transition), Qe), Js = ln(Zo, P({}, (m = K.tooltip) != null ? m : $.tooltip, { className: be(Cr.tooltip, (E = (_ = K.tooltip) != null ? _ : $.tooltip) == null ? void 0 : E.className) - }), Qe), Zs = ln(qo, P({}, (C = K.arrow) != null ? C : $.arrow, { + }), Qe), Zs = ln(Qo, P({}, (C = K.arrow) != null ? C : $.arrow, { className: be(Cr.arrow, (S = (b = K.arrow) != null ? b : $.arrow) == null ? void 0 : S.className) }), Qe); return /* @__PURE__ */ x(M.Fragment, { - children: [/* @__PURE__ */ M.cloneElement(xt, Mt), /* @__PURE__ */ s(Xo, P({ + children: [/* @__PURE__ */ M.cloneElement(xt, Dt), /* @__PURE__ */ s(Ko, P({ as: Y ?? Ds, placement: X, anchorEl: rt ? { @@ -9138,11 +9171,11 @@ const Bs = /* @__PURE__ */ M.forwardRef(function(e, n) { popperOptions: Ws, children: ({ TransitionProps: Q - }) => /* @__PURE__ */ s(Yo, P({ + }) => /* @__PURE__ */ s(Jo, P({ timeout: Ft.transitions.duration.shorter }, Q, Ks, { - children: /* @__PURE__ */ x(Wo, P({}, Js, { - children: [dt, z ? /* @__PURE__ */ s(qo, P({}, Zs, { + children: /* @__PURE__ */ x(Zo, P({}, Js, { + children: [dt, z ? /* @__PURE__ */ s(Qo, P({}, Zs, { ref: Ee })) : null] })) @@ -9344,8 +9377,8 @@ process.env.NODE_ENV !== "production" && (Bs.propTypes = { TransitionProps: u.object }); const _m = Bs; -function Ya(t, e, n) { - return t ? /* @__PURE__ */ s(ri, { className: `papi-menu-icon-${n ? "leading" : "trailing"}`, children: /* @__PURE__ */ s("img", { src: t, alt: `${n ? "Leading" : "Trailing"} icon for ${e}` }) }) : void 0; +function Ka(t, e, n) { + return t ? /* @__PURE__ */ s(ii, { className: `papi-menu-icon-${n ? "leading" : "trailing"}`, children: /* @__PURE__ */ s("img", { src: t, alt: `${n ? "Leading" : "Trailing"} icon for ${e}` }) }) : void 0; } function js(t) { const { @@ -9359,12 +9392,12 @@ function js(t) { className: c, isDisabled: d = !1, isDense: p = !0, - isSubMenuParent: m = !1, + isSubMenuParent: h = !1, hasDisabledGutters: w = !1, hasDivider: g = !1, focusVisibleClassName: v, id: f, - children: h + children: m } = t, E = /* @__PURE__ */ s( jl, { @@ -9379,10 +9412,10 @@ function js(t) { onClick: e, id: f, children: n ? /* @__PURE__ */ x(ie, { children: [ - Ya(a, n, !0), + Ka(a, n, !0), /* @__PURE__ */ s(Vl, { primary: n, inset: !a && o }), - m ? /* @__PURE__ */ s(ri, { className: "papi-menu-icon-trailing", children: /* @__PURE__ */ s(vs, {}) }) : Ya(i, n, !1) - ] }) : h + h ? /* @__PURE__ */ s(ii, { className: "papi-menu-icon-trailing", children: /* @__PURE__ */ s(vs, {}) }) : Ka(i, n, !1) + ] }) : m } ); return r ? /* @__PURE__ */ s(_m, { title: r, placement: "right", children: /* @__PURE__ */ s("div", { children: E }) }) : E; @@ -9427,15 +9460,15 @@ function Pm(t) { } const $m = (t, e) => e.filter((o) => o.group === t).sort((o, a) => (o.order || 0) - (a.order || 0)); function zs(t) { - const { menuDefinition: e, onClick: n, commandHandler: r, includedGroups: o } = t, { items: a, allowForLeadingIcons: i } = $t(() => { + const { menuDefinition: e, onClick: n, commandHandler: r, includedGroups: o } = t, { items: a, allowForLeadingIcons: i } = At(() => { const p = o && o.length > 0 ? o : ( // We're apparently laying out a single-column menu (presumably a context menu). In this // case, all groups should be included except ones that belong to a submenu. Vs(e).filter((v) => !("menuItem" in v.group)) - ), m = Object.values(p).sort( + ), h = Object.values(p).sort( (v, f) => (v.group.order || 0) - (f.group.order || 0) ), w = []; - m.forEach((v) => { + h.forEach((v) => { $m(v.id, e.items).forEach( (f) => w.push({ item: f, isLastItemInGroup: !1 }) ), w.length > 0 && (w[w.length - 1].isLastItemInGroup = !0); @@ -9444,23 +9477,23 @@ function zs(t) { (v) => "iconPathBefore" in v.item && v.item.iconPathBefore ); return { items: w, allowForLeadingIcons: g }; - }, [o, e]), l = ({ item: p, isLastItemInGroup: m }) => ({ + }, [o, e]), l = ({ item: p, isLastItemInGroup: h }) => ({ className: "papi-menu-item", label: p.label, tooltip: p.tooltip, iconPathBefore: "iconPathBefore" in p ? p.iconPathBefore : void 0, iconPathAfter: "iconPathAfter" in p ? p.iconPathAfter : void 0, - hasDivider: m, + hasDivider: h, // Set hasDivider to true for the last item in a group allowForLeadingIcons: i }), [c] = a; if (!c) return /* @__PURE__ */ s("div", {}); const d = c.item.group; - return /* @__PURE__ */ s("div", { role: "menu", "aria-label": d, children: a.map((p, m) => { + return /* @__PURE__ */ s("div", { role: "menu", "aria-label": d, children: a.map((p, h) => { const { item: w } = p, g = l(p); if ("command" in w) { - const v = w.group + m; + const v = w.group + h; return /* @__PURE__ */ s( js, { @@ -9483,7 +9516,7 @@ function zs(t) { ); }) }, d); } -function Im(t) { +function Am(t) { const { menuDefinition: e, columnId: n } = t; let a = Object.entries(e.groups).map(([i, l]) => ({ id: i, group: l })).filter((i) => "column" in i.group); return n && "columns" in e && // Without this type assertion, TS doesn't know what columns is. @@ -9492,7 +9525,7 @@ function Im(t) { (i) => "column" in i.group && i.group.column === n )), /* @__PURE__ */ s(zs, { ...t, includedGroups: a }); } -function Am({ +function Im({ commandHandler: t, menuDefinition: e, id: n, @@ -9501,7 +9534,7 @@ function Am({ className: a }) { return /* @__PURE__ */ x( - oi, + si, { id: n, item: !0, @@ -9512,7 +9545,7 @@ function Am({ children: [ /* @__PURE__ */ s("h3", { "aria-label": r.label, className: `papi-menu-column-header ${a ?? ""}`, children: r.label }), /* @__PURE__ */ s(Ll, { id: n, dense: !0, className: a ?? "", children: /* @__PURE__ */ s( - Im, + Am, { commandHandler: t, menuDefinition: e, @@ -9530,7 +9563,7 @@ function Mm({ multiColumnMenu: n, id: r }) { - const { columns: o } = n, a = $t(() => { + const { columns: o } = n, a = At(() => { const i = /* @__PURE__ */ new Map(); return Object.getOwnPropertyNames(o).forEach((l) => { if (l === "isExtensible") @@ -9542,7 +9575,7 @@ function Mm({ }), Array.from(i.values()).sort((l, c) => (l.metadata.order || 0) - (c.metadata.order || 0)); }, [o, r]); return /* @__PURE__ */ s( - oi, + si, { container: !0, spacing: 0, @@ -9552,7 +9585,7 @@ function Mm({ "aria-label": "GridMenu", id: r, children: a.map((i, l) => /* @__PURE__ */ s( - Am, + Im, { commandHandler: t, menuDefinition: n, @@ -9570,7 +9603,7 @@ function Dm(t) { ...t }; } -const oo = (t, e, n = {}) => { +const lo = (t, e, n = {}) => { const r = ge(e); r.current = e; const o = ge(n); @@ -9600,36 +9633,36 @@ function jm({ ariaLabelPrefix: i, children: l }) { - const [c, d] = ut(!1), [p, m] = ut(!1), w = Bt(() => { - c && d(!1), m(!1); - }, [c]), g = Bt((S) => { + const [c, d] = ut(!1), [p, h] = ut(!1), w = Tt(() => { + c && d(!1), h(!1); + }, [c]), g = Tt((S) => { S.stopPropagation(), d((b) => { - const I = !b; - return I && S.shiftKey ? m(!0) : I || m(!1), I; + const A = !b; + return A && S.shiftKey ? h(!0) : A || h(!1), A; }); - }, []), v = Bt( + }, []), v = Tt( (S) => (w(), r(S)), [r, w] - ), [f, h] = ut({ top: 1, left: 1 }); + ), [f, m] = ut({ top: 1, left: 1 }); ae(() => { if (c) { const S = o == null ? void 0 : o.current; if (S) { - const b = S.getBoundingClientRect(), I = window.scrollY, z = window.scrollX, H = b.top + I + S.clientHeight, O = b.left + z; - h({ top: H, left: O }); + const b = S.getBoundingClientRect(), A = window.scrollY, z = window.scrollX, H = b.top + A + S.clientHeight, O = b.left + z; + m({ top: H, left: O }); } } }, [c, o]); - const [E] = oo( - Bt(async () => (t == null ? void 0 : t(!1)) ?? e, [t, e, c]), + const [E] = lo( + Tt(async () => (t == null ? void 0 : t(!1)) ?? e, [t, e, c]), e - ), [_] = oo( - Bt(async () => (t == null ? void 0 : t(!0)) ?? n ?? E, [t, n, E, c]), + ), [_] = lo( + Tt(async () => (t == null ? void 0 : t(!0)) ?? n ?? E, [t, n, E, c]), n ?? E ), C = p && _ ? _ : E; return /* @__PURE__ */ x(ie, { children: [ /* @__PURE__ */ s( - ai, + li, { sx: { paddingTop: 0, @@ -9684,7 +9717,7 @@ function Mh({ children: d }) { return /* @__PURE__ */ s( - ai, + li, { id: t, disabled: n, @@ -9712,7 +9745,7 @@ function Dh({ className: c, defaultValue: d, value: p, - onChange: m, + onChange: h, onFocus: w, onBlur: g }) { @@ -9738,7 +9771,7 @@ function Dh({ className: N(c, { "tw-border-red-600": n }), defaultValue: d, value: p, - onChange: m, + onChange: h, onFocus: w, onBlur: g } @@ -9858,8 +9891,8 @@ const Gm = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( } )); Gm.displayName = Yr.Root.displayName; -const Vh = Rt.Root, Hm = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( - Rt.List, +const Vh = _t.Root, Hm = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( + _t.List, { ref: n, className: N( @@ -9869,9 +9902,9 @@ const Vh = Rt.Root, Hm = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE_ ...e } )); -Hm.displayName = Rt.List.displayName; +Hm.displayName = _t.List.displayName; const Xm = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( - Rt.Trigger, + _t.Trigger, { ref: n, className: N( @@ -9881,9 +9914,9 @@ const Xm = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( ...e } )); -Xm.displayName = Rt.Trigger.displayName; +Xm.displayName = _t.Trigger.displayName; const Ym = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( - Rt.Content, + _t.Content, { ref: n, className: N( @@ -9893,7 +9926,7 @@ const Ym = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( ...e } )); -Ym.displayName = Rt.Content.displayName; +Ym.displayName = _t.Content.displayName; function zh({ isInstalling: t, handleClick: e, @@ -10004,7 +10037,7 @@ function Gh({ className: n, anchorTarget: r }) { - const o = $t( + const o = At( () => ({ overrides: { a: { @@ -10039,11 +10072,11 @@ const Wm = Qn((t, e) => /* @__PURE__ */ x( )); var qm = /* @__PURE__ */ ((t) => (t[t.Check = 0] = "Check", t[t.Radio = 1] = "Radio", t))(qm || {}); function Hh({ id: t, groups: e }) { - return /* @__PURE__ */ s("div", { id: t, children: /* @__PURE__ */ x(co, { children: [ - /* @__PURE__ */ s(ui, { asChild: !0, children: /* @__PURE__ */ s(Wm, {}) }), + return /* @__PURE__ */ s("div", { id: t, children: /* @__PURE__ */ x(fo, { children: [ + /* @__PURE__ */ s(mi, { asChild: !0, children: /* @__PURE__ */ s(Wm, {}) }), /* @__PURE__ */ s(rr, { children: e.map((n) => /* @__PURE__ */ x("div", { children: [ /* @__PURE__ */ s(Sn, { children: n.label }), - /* @__PURE__ */ s(pc, { children: n.items.map((r) => /* @__PURE__ */ s("div", { children: r.itemType === 0 ? /* @__PURE__ */ s(po, { onClick: r.onClick, children: r.label }) : /* @__PURE__ */ s(fi, { onClick: r.onClick, value: r.label, children: r.label }) }, r.label)) }), + /* @__PURE__ */ s(pc, { children: n.items.map((r) => /* @__PURE__ */ s("div", { children: r.itemType === 0 ? /* @__PURE__ */ s(mo, { onClick: r.onClick, children: r.label }) : /* @__PURE__ */ s(gi, { onClick: r.onClick, value: r.label, children: r.label }) }, r.label)) }), /* @__PURE__ */ s(or, {}) ] }, n.label)) }) ] }) }); @@ -10142,9 +10175,9 @@ function Yh({ function Km({ id: t, versionHistory: e }) { const [n, r] = ut(!1), o = /* @__PURE__ */ new Date(); function a(l) { - const c = new Date(l), d = new Date(o.getTime() - c.getTime()), p = d.getUTCFullYear() - 1970, m = d.getUTCMonth(), w = d.getUTCDate() - 1; + const c = new Date(l), d = new Date(o.getTime() - c.getTime()), p = d.getUTCFullYear() - 1970, h = d.getUTCMonth(), w = d.getUTCDate() - 1; let g = ""; - return p > 0 ? g = `${p.toString()} year${p === 1 ? "" : "s"} ago` : m > 0 ? g = `${m.toString()} month${m === 1 ? "" : "s"} ago` : w === 0 ? g = "today" : g = `${w.toString()} day${w === 1 ? "" : "s"} ago`, g; + return p > 0 ? g = `${p.toString()} year${p === 1 ? "" : "s"} ago` : h > 0 ? g = `${h.toString()} month${h === 1 ? "" : "s"} ago` : w === 0 ? g = "today" : g = `${w.toString()} day${w === 1 ? "" : "s"} ago`, g; } const i = Object.entries(e).sort((l, c) => c[0].localeCompare(l[0])); return /* @__PURE__ */ x("div", { id: t, children: [ @@ -10177,7 +10210,7 @@ function Wh({ locales: r, versionHistory: o }) { - const a = $t(() => $l(n), [n]), l = ((c) => { + const a = At(() => $l(n), [n]), l = ((c) => { const d = new Intl.DisplayNames(navigator.language, { type: "language" }); return c.map((p) => d.of(p)); })(r); @@ -10212,8 +10245,8 @@ const qh = (t, e) => { }; }, [t, e]); }, Gr = () => !1, Kh = (t, e) => { - const [n] = oo( - Bt(async () => { + const [n] = lo( + Tt(async () => { if (!t) return Gr; const r = await Promise.resolve(t(e)); @@ -11378,6 +11411,9 @@ video:where(.pr-twp,.pr-twp *) { .tw-z-50 { z-index: 50; } +.tw-z-\\[1000\\] { + z-index: 1000; +} .tw-col-span-2 { grid-column: span 2 / span 2; } @@ -13710,12 +13746,31 @@ video:where(.pr-twp,.pr-twp *) { [data-side=right] .\\[\\[data-side\\=right\\]_\\&\\]\\:tw-cursor-e-resize { cursor: e-resize; } -.banded-row:hover { +.papi-icon-button { + border: 0; + border-radius: 3em; cursor: pointer; + display: inline-block; } -.banded-row[data-state='selected']:hover { - cursor: default; +.papi-icon-button.primary { + background-color: #1ea7fd; + color: white; +} + +.papi-icon-button.secondary { + background-color: transparent; + color: #333; +} + +.papi-icon-button.paratext { + background-color: darkgreen; + color: greenyellow; +} + +.papi-icon-button.paratext.bright { + background-color: greenyellow; + color: darkgreen; } .papi-multi-column-menu { background-color: rgb(222, 222, 222); @@ -13751,32 +13806,6 @@ video:where(.pr-twp,.pr-twp *) { color: rgb(76, 106, 76); background-color: rgb(214, 255, 152); } -.papi-icon-button { - border: 0; - border-radius: 3em; - cursor: pointer; - display: inline-block; -} - -.papi-icon-button.primary { - background-color: #1ea7fd; - color: white; -} - -.papi-icon-button.secondary { - background-color: transparent; - color: #333; -} - -.papi-icon-button.paratext { - background-color: darkgreen; - color: greenyellow; -} - -.papi-icon-button.paratext.bright { - background-color: greenyellow; - color: darkgreen; -} .papi-menu-item { background-color: transparent; } @@ -13790,6 +13819,13 @@ video:where(.pr-twp,.pr-twp *) { max-width: 24px; max-height: 24px; } +.banded-row:hover { + cursor: pointer; +} + +.banded-row[data-state='selected']:hover { + cursor: default; +} .papi-menu-drawer-paper { height: fit-content !important; position: absolute !important; @@ -13817,27 +13853,27 @@ export { Yi as CardHeader, Wi as CardTitle, Dc as ChapterRangeSelector, - uo as Checkbox, - Ah as Checklist, - ta as ComboBox, + ho as Checkbox, + Ih as Checklist, + qr as ComboBox, Hc as DataTable, Fh as DisableButton, - co as DropdownMenu, - po as DropdownMenuCheckboxItem, + fo as DropdownMenu, + mo as DropdownMenuCheckboxItem, rr as DropdownMenuContent, pc as DropdownMenuGroup, - wi as DropdownMenuItem, + hi as DropdownMenuItem, qm as DropdownMenuItemType, Sn as DropdownMenuLabel, mh as DropdownMenuPortal, gh as DropdownMenuRadioGroup, - fi as DropdownMenuRadioItem, + gi as DropdownMenuRadioItem, or as DropdownMenuSeparator, fc as DropdownMenuShortcut, hh as DropdownMenuSub, wc as DropdownMenuSubContent, uc as DropdownMenuSubTrigger, - ui as DropdownMenuTrigger, + mi as DropdownMenuTrigger, Lh as EnableButton, Wm as FilterButton, Hh as FilterDropdown, @@ -13855,7 +13891,7 @@ export { Yh as MoreInfo, Th as NavigationContentSearch, Xh as NoExtensionsFound, - mi as RadioGroup, + bi as RadioGroup, Wr as RadioGroupItem, Oh as ScriptureResultsViewer, Rh as ScrollGroupSelector, @@ -13865,13 +13901,13 @@ export { Vc as SelectGroup, Gt as SelectItem, zc as SelectLabel, - Ei as SelectScrollDownButton, - ki as SelectScrollUpButton, + Ci as SelectScrollDownButton, + Ti as SelectScrollUpButton, Lc as SelectSeparator, De as SelectTrigger, bn as SelectValue, - wo as Separator, - Ih as SettingsCard, + go as Separator, + Ah as SettingsCard, _h as SettingsList, $h as SettingsListHeader, Ph as SettingsListItem, @@ -13894,20 +13930,20 @@ export { Hm as TabsList, Xm as TabsTrigger, Dh as TextField, - Ci as ToggleGroup, + _i as ToggleGroup, Un as ToggleGroupItem, Bh as Toolbar, Uh as UpdateButton, Km as VersionHistory, - Oi as VerticalTabs, - _i as VerticalTabsContent, - Ri as VerticalTabsList, + Pi as VerticalTabs, + Ai as VerticalTabsContent, + $i as VerticalTabsList, ed as VerticalTabsTrigger, Sc as buttonVariants, N as cn, Wc as getBookNumFromId, Yc as getLinesFromUSFM, - ea as getNumberFromUSFM, + oa as getNumberFromUSFM, qc as getStatusForItem, Nh as inventoryCountColumn, xh as inventoryItemColumn, @@ -13915,6 +13951,6 @@ export { Qh as sonner, qh as useEvent, Kh as useEventAsync, - oo as usePromise + lo as usePromise }; //# sourceMappingURL=index.js.map diff --git a/lib/platform-bible-react/dist/index.js.map b/lib/platform-bible-react/dist/index.js.map index 7f2e3ad564..0c8db16fd2 100644 --- a/lib/platform-bible-react/dist/index.js.map +++ b/lib/platform-bible-react/dist/index.js.map @@ -1 +1 @@ -{"version":3,"file":"index.js","sources":["../src/utils/shadcn-ui.util.ts","../src/components/shadcn-ui/input.tsx","../src/components/advanced/book-chapter-control/book-chapter-input.component.tsx","../../../node_modules/@sillsdev/scripture/dist/index.es.js","../src/components/shadcn-ui/dropdown-menu.tsx","../src/components/advanced/book-chapter-control/book-menu-item.component.tsx","../src/components/advanced/book-chapter-control/chapter-select.component.tsx","../src/components/advanced/book-chapter-control/go-to-menu-item.component.tsx","../src/components/advanced/book-chapter-control/book-chapter-control.component.tsx","../src/components/shadcn-ui/button.tsx","../src/components/shadcn-ui/label.tsx","../src/components/shadcn-ui/radio-group.tsx","../src/components/shadcn-ui/popover.tsx","../src/components/shadcn-ui/dialog.tsx","../src/components/shadcn-ui/command.tsx","../src/components/basics/combo-box.component.tsx","../src/components/basics/chapter-range-selector.component.tsx","../src/components/advanced/book-selector.component.tsx","../src/components/advanced/data-table/data-table-column-toggle.component.tsx","../src/components/shadcn-ui/select.tsx","../src/components/advanced/data-table/data-table-pagination.component.tsx","../src/components/shadcn-ui/table.tsx","../src/components/advanced/data-table/data-table.component.tsx","../src/components/advanced/inventory/occurrences-table.component.tsx","../src/components/shadcn-ui/checkbox.tsx","../src/components/advanced/inventory/inventory-utils.ts","../src/components/shadcn-ui/toggle.tsx","../src/components/shadcn-ui/toggle-group.tsx","../src/components/advanced/inventory/inventory-columns.tsx","../src/components/advanced/inventory/inventory.component.tsx","../src/components/basics/search-bar.component.tsx","../src/components/basics/tabs-vertical.tsx","../src/components/advanced/tab-navigation-content-search.component.tsx","../src/components/shadcn-ui/separator.tsx","../src/components/shadcn-ui/sheet.tsx","../src/components/shadcn-ui/skeleton.tsx","../src/components/shadcn-ui/tooltip.tsx","../src/components/hooks/use-mobile.tsx","../src/components/shadcn-ui/sidebar.tsx","../src/components/advanced/settings-components/settings-sidebar.component.tsx","../src/components/advanced/settings-components/settings-sidebar-content-search.component.tsx","../src/components/advanced/scripture-results-viewer/scripture-results-viewer.component.tsx","../src/components/advanced/scroll-group-selector.component.tsx","../src/components/advanced/settings-components/settings-list.component.tsx","../src/components/shadcn-ui/card.tsx","../src/components/advanced/settings-components/settings-card.component.tsx","../src/components/basics/checklist.component.tsx","../../../node_modules/@babel/runtime/helpers/interopRequireDefault.js","../../../node_modules/@mui/utils/chainPropTypes/chainPropTypes.js","../../../node_modules/@babel/runtime/helpers/esm/extends.js","../../../node_modules/@mui/utils/deepmerge/deepmerge.js","../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.production.min.js","../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.development.js","../../../node_modules/prop-types/node_modules/react-is/index.js","../../../node_modules/object-assign/index.js","../../../node_modules/prop-types/lib/ReactPropTypesSecret.js","../../../node_modules/prop-types/lib/has.js","../../../node_modules/prop-types/checkPropTypes.js","../../../node_modules/prop-types/factoryWithTypeCheckers.js","../../../node_modules/prop-types/factoryWithThrowingShims.js","../../../node_modules/prop-types/index.js","../../../node_modules/@mui/utils/elementAcceptingRef/elementAcceptingRef.js","../../../node_modules/@mui/utils/exactProp/exactProp.js","../../../node_modules/@mui/utils/formatMuiErrorMessage/formatMuiErrorMessage.js","../../../node_modules/react-is/cjs/react-is.production.min.js","../../../node_modules/react-is/cjs/react-is.development.js","../../../node_modules/react-is/index.js","../../../node_modules/@mui/utils/getDisplayName/getDisplayName.js","../../../node_modules/@mui/utils/HTMLElementType/HTMLElementType.js","../../../node_modules/@mui/utils/refType/refType.js","../../../node_modules/@mui/utils/capitalize/capitalize.js","../../../node_modules/@mui/utils/createChainedFunction/createChainedFunction.js","../../../node_modules/@mui/utils/debounce/debounce.js","../../../node_modules/@mui/utils/deprecatedPropType/deprecatedPropType.js","../../../node_modules/@mui/utils/isMuiElement/isMuiElement.js","../../../node_modules/@mui/utils/ownerDocument/ownerDocument.js","../../../node_modules/@mui/utils/ownerWindow/ownerWindow.js","../../../node_modules/@mui/utils/requirePropFactory/requirePropFactory.js","../../../node_modules/@mui/utils/setRef/setRef.js","../../../node_modules/@mui/utils/useEnhancedEffect/useEnhancedEffect.js","../../../node_modules/@mui/utils/useId/useId.js","../../../node_modules/@mui/utils/unsupportedProp/unsupportedProp.js","../../../node_modules/@mui/utils/useControlled/useControlled.js","../../../node_modules/@mui/utils/useEventCallback/useEventCallback.js","../../../node_modules/@mui/utils/useForkRef/useForkRef.js","../../../node_modules/@mui/utils/useLazyRef/useLazyRef.js","../../../node_modules/@mui/utils/useOnMount/useOnMount.js","../../../node_modules/@mui/utils/useTimeout/useTimeout.js","../../../node_modules/@mui/utils/useIsFocusVisible/useIsFocusVisible.js","../../../node_modules/@mui/utils/resolveProps/resolveProps.js","../../../node_modules/@mui/utils/composeClasses/composeClasses.js","../../../node_modules/@mui/utils/ClassNameGenerator/ClassNameGenerator.js","../../../node_modules/@mui/utils/generateUtilityClass/generateUtilityClass.js","../../../node_modules/@mui/utils/generateUtilityClasses/generateUtilityClasses.js","../../../node_modules/@mui/utils/clamp/clamp.js","../../../node_modules/@babel/runtime/helpers/esm/objectWithoutPropertiesLoose.js","../../../node_modules/@mui/system/esm/createTheme/createBreakpoints.js","../../../node_modules/@mui/system/esm/createTheme/shape.js","../../../node_modules/@mui/system/esm/responsivePropType.js","../../../node_modules/@mui/system/esm/merge.js","../../../node_modules/@mui/system/esm/breakpoints.js","../../../node_modules/@mui/system/esm/style.js","../../../node_modules/@mui/system/esm/memoize.js","../../../node_modules/@mui/system/esm/spacing.js","../../../node_modules/@mui/system/esm/createTheme/createSpacing.js","../../../node_modules/@mui/system/esm/compose.js","../../../node_modules/@mui/system/esm/borders.js","../../../node_modules/@mui/system/esm/cssGrid.js","../../../node_modules/@mui/system/esm/palette.js","../../../node_modules/@mui/system/esm/sizing.js","../../../node_modules/@mui/system/esm/styleFunctionSx/defaultSxConfig.js","../../../node_modules/@mui/system/esm/styleFunctionSx/styleFunctionSx.js","../../../node_modules/@mui/system/esm/createTheme/applyStyles.js","../../../node_modules/@mui/system/esm/createTheme/createTheme.js","../../../node_modules/@mui/system/esm/useThemeWithoutDefault.js","../../../node_modules/@mui/system/esm/useTheme.js","../../../node_modules/@mui/system/esm/createStyled.js","../../../node_modules/@mui/system/esm/useThemeProps/getThemeProps.js","../../../node_modules/@mui/system/esm/useThemeProps/useThemeProps.js","../../../node_modules/@mui/system/esm/colorManipulator.js","../../../node_modules/@mui/material/styles/createMixins.js","../../../node_modules/@mui/material/colors/common.js","../../../node_modules/@mui/material/colors/grey.js","../../../node_modules/@mui/material/colors/purple.js","../../../node_modules/@mui/material/colors/red.js","../../../node_modules/@mui/material/colors/orange.js","../../../node_modules/@mui/material/colors/blue.js","../../../node_modules/@mui/material/colors/lightBlue.js","../../../node_modules/@mui/material/colors/green.js","../../../node_modules/@mui/material/styles/createPalette.js","../../../node_modules/@mui/material/styles/createTypography.js","../../../node_modules/@mui/material/styles/shadows.js","../../../node_modules/@mui/material/styles/createTransitions.js","../../../node_modules/@mui/material/styles/zIndex.js","../../../node_modules/@mui/material/styles/createTheme.js","../../../node_modules/@mui/material/styles/defaultTheme.js","../../../node_modules/@mui/material/styles/identifier.js","../../../node_modules/@mui/material/styles/useThemeProps.js","../../../node_modules/@mui/material/styles/styled.js","../../../node_modules/@mui/material/SvgIcon/svgIconClasses.js","../../../node_modules/@mui/material/SvgIcon/SvgIcon.js","../../../node_modules/@mui/material/utils/createSvgIcon.js","../../../node_modules/@mui/material/utils/index.js","../../../node_modules/@mui/icons-material/utils/createSvgIcon.js","../../../node_modules/@mui/icons-material/ArrowRight.js","../../../node_modules/@mui/base/utils/isHostComponent.js","../../../node_modules/@mui/base/utils/appendOwnerState.js","../../../node_modules/@mui/base/utils/ClassNameConfigurator.js","../../../node_modules/@mui/base/utils/extractEventHandlers.js","../../../node_modules/@mui/base/utils/resolveComponentProps.js","../../../node_modules/@mui/base/utils/omitEventHandlers.js","../../../node_modules/@mui/base/utils/mergeSlotProps.js","../../../node_modules/@mui/base/utils/useSlotProps.js","../../../node_modules/@mui/base/generateUtilityClass/index.js","../../../node_modules/@mui/base/generateUtilityClasses/index.js","../../../node_modules/@mui/base/Portal/Portal.js","../../../node_modules/@popperjs/core/lib/enums.js","../../../node_modules/@popperjs/core/lib/dom-utils/getNodeName.js","../../../node_modules/@popperjs/core/lib/dom-utils/getWindow.js","../../../node_modules/@popperjs/core/lib/dom-utils/instanceOf.js","../../../node_modules/@popperjs/core/lib/modifiers/applyStyles.js","../../../node_modules/@popperjs/core/lib/utils/getBasePlacement.js","../../../node_modules/@popperjs/core/lib/utils/math.js","../../../node_modules/@popperjs/core/lib/utils/userAgent.js","../../../node_modules/@popperjs/core/lib/dom-utils/isLayoutViewport.js","../../../node_modules/@popperjs/core/lib/dom-utils/getBoundingClientRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/getLayoutRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/contains.js","../../../node_modules/@popperjs/core/lib/dom-utils/getComputedStyle.js","../../../node_modules/@popperjs/core/lib/dom-utils/isTableElement.js","../../../node_modules/@popperjs/core/lib/dom-utils/getDocumentElement.js","../../../node_modules/@popperjs/core/lib/dom-utils/getParentNode.js","../../../node_modules/@popperjs/core/lib/dom-utils/getOffsetParent.js","../../../node_modules/@popperjs/core/lib/utils/getMainAxisFromPlacement.js","../../../node_modules/@popperjs/core/lib/utils/within.js","../../../node_modules/@popperjs/core/lib/utils/getFreshSideObject.js","../../../node_modules/@popperjs/core/lib/utils/mergePaddingObject.js","../../../node_modules/@popperjs/core/lib/utils/expandToHashMap.js","../../../node_modules/@popperjs/core/lib/modifiers/arrow.js","../../../node_modules/@popperjs/core/lib/utils/getVariation.js","../../../node_modules/@popperjs/core/lib/modifiers/computeStyles.js","../../../node_modules/@popperjs/core/lib/modifiers/eventListeners.js","../../../node_modules/@popperjs/core/lib/utils/getOppositePlacement.js","../../../node_modules/@popperjs/core/lib/utils/getOppositeVariationPlacement.js","../../../node_modules/@popperjs/core/lib/dom-utils/getWindowScroll.js","../../../node_modules/@popperjs/core/lib/dom-utils/getWindowScrollBarX.js","../../../node_modules/@popperjs/core/lib/dom-utils/getViewportRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/getDocumentRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/isScrollParent.js","../../../node_modules/@popperjs/core/lib/dom-utils/getScrollParent.js","../../../node_modules/@popperjs/core/lib/dom-utils/listScrollParents.js","../../../node_modules/@popperjs/core/lib/utils/rectToClientRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/getClippingRect.js","../../../node_modules/@popperjs/core/lib/utils/computeOffsets.js","../../../node_modules/@popperjs/core/lib/utils/detectOverflow.js","../../../node_modules/@popperjs/core/lib/utils/computeAutoPlacement.js","../../../node_modules/@popperjs/core/lib/modifiers/flip.js","../../../node_modules/@popperjs/core/lib/modifiers/hide.js","../../../node_modules/@popperjs/core/lib/modifiers/offset.js","../../../node_modules/@popperjs/core/lib/modifiers/popperOffsets.js","../../../node_modules/@popperjs/core/lib/utils/getAltAxis.js","../../../node_modules/@popperjs/core/lib/modifiers/preventOverflow.js","../../../node_modules/@popperjs/core/lib/dom-utils/getHTMLElementScroll.js","../../../node_modules/@popperjs/core/lib/dom-utils/getNodeScroll.js","../../../node_modules/@popperjs/core/lib/dom-utils/getCompositeRect.js","../../../node_modules/@popperjs/core/lib/utils/orderModifiers.js","../../../node_modules/@popperjs/core/lib/utils/debounce.js","../../../node_modules/@popperjs/core/lib/utils/mergeByName.js","../../../node_modules/@popperjs/core/lib/createPopper.js","../../../node_modules/@popperjs/core/lib/popper.js","../../../node_modules/@mui/base/Popper/popperClasses.js","../../../node_modules/@mui/base/Popper/Popper.js","../../../node_modules/@mui/material/styles/useTheme.js","../../../node_modules/@babel/runtime/helpers/esm/setPrototypeOf.js","../../../node_modules/@babel/runtime/helpers/esm/inheritsLoose.js","../../../node_modules/react-transition-group/esm/config.js","../../../node_modules/react-transition-group/esm/utils/PropTypes.js","../../../node_modules/react-transition-group/esm/TransitionGroupContext.js","../../../node_modules/react-transition-group/esm/utils/reflow.js","../../../node_modules/react-transition-group/esm/Transition.js","../../../node_modules/@mui/material/transitions/utils.js","../../../node_modules/@mui/material/Grow/Grow.js","../../../node_modules/@mui/material/Popper/Popper.js","../../../node_modules/@mui/material/Tooltip/tooltipClasses.js","../../../node_modules/@mui/material/Tooltip/Tooltip.js","../src/components/mui/menu-item.component.tsx","../src/components/mui/grouped-menu-item-list.component.tsx","../src/components/mui/top-level-menu.component.tsx","../src/components/mui/grid-menu.component.tsx","../src/hooks/use-promise.hook.ts","../../../node_modules/@mui/icons-material/esm/Menu.js","../src/components/mui/hamburger-menu-button.component.tsx","../src/components/mui/icon-button.component.tsx","../src/components/basics/spinner.component.tsx","../src/components/basics/text-field.component.tsx","../src/components/mui/toolbar.component.tsx","../src/components/shadcn-ui/alert.tsx","../src/components/shadcn-ui/sonner.tsx","../src/components/shadcn-ui/slider.tsx","../src/components/shadcn-ui/switch.tsx","../src/components/shadcn-ui/tabs.tsx","../src/components/advanced/extension-marketplace/buttons/install-button.component.tsx","../src/components/advanced/extension-marketplace/buttons/enable-button.component.tsx","../src/components/advanced/extension-marketplace/buttons/disable-button.component.tsx","../src/components/advanced/extension-marketplace/buttons/update-button.component.tsx","../src/components/advanced/extension-marketplace/markdown-renderer.component.tsx","../src/components/advanced/extension-marketplace/buttons/filter-button.component.tsx","../src/components/advanced/extension-marketplace/filter-dropdown.component.tsx","../src/components/advanced/extension-marketplace/no-extensions-found.component.tsx","../src/components/advanced/extension-marketplace/more-info.component.tsx","../src/components/advanced/extension-marketplace/version-history.component.tsx","../src/components/advanced/extension-marketplace/footer.component.tsx","../src/hooks/use-event.hook.ts","../src/hooks/use-event-async.hook.ts"],"sourcesContent":["import { type ClassValue, clsx } from 'clsx';\nimport { extendTailwindMerge } from 'tailwind-merge';\n\nconst twMergeCustom = extendTailwindMerge({ prefix: 'tw-' });\n\n/**\n * Tailwind and CSS class application helper function. Uses\n * [`clsx`](https://www.npmjs.com/package/clsx) to make it easy to apply classes conditionally using\n * object syntax, and uses [`tailwind-merge`](https://www.npmjs.com/package/tailwind-merge) to make\n * it easy to merge/overwrite Tailwind classes in a programmer-logic-friendly way.\n *\n * Note: `tailwind-merge` is configured to use the prefix `tw-`, so you must use the same prefix\n * with any Tailwind classes you use with this function to successfully overwrite other Tailwind\n * classes. `platform-bible-react` is configured to use `tw-` as its Tailwind prefix, so any\n * Tailwind classes you pass into `platform-bible-react` components will be compared using the `tw-`\n * prefix.\n *\n * This function was popularized by\n * [shadcn/ui](https://ui.shadcn.com/docs/installation/manual#add-a-cn-helper). See [ByteGrad's\n * explanation video](https://www.youtube.com/watch?v=re2JFITR7TI) for more information.\n *\n * @example\n *\n * ```typescript\n * const borderShouldBeBlue = true;\n * const textShouldBeRed = true;\n * const heightShouldBe20 = false;\n * const classString = cn(\n * 'tw-bg-primary tw-h-10 tw-text-primary-foreground',\n * 'tw-bg-secondary',\n * {\n * 'tw-border-blue-500': borderShouldBeBlue,\n * 'tw-text-red-500': textShouldBeRed,\n * 'tw-h-20': heightShouldBe20,\n * },\n * 'some-class',\n * );\n * ```\n *\n * The resulting `classString` is `'tw-h-10 tw-bg-secondary tw-border-blue-500 tw-text-red-500\n * some-class'`\n *\n * - Notice that `'tw-bg-secondary'`, specified later, overwrote `'tw-bg-primary'`, specified earlier,\n * because they are Tailwind classes that affect the same css property\n * - Notice that `'tw-text-red-500'`, specified later, overwrote `'tw-text-primary-foreground'`,\n * specified earlier, because they are Tailwind classes that affect the same css property\n * - Notice that `'tw-h-20'`, specified later, did not overwrite `'tw-h-10'`, specified earlier,\n * because `'tw-h-20'` is part of a conditional class object and its value evaluated to `false`;\n * therefore it was not applied\n * - Notice that `'some-class'` was applied. This function is not limited only to Tailwind classes.\n *\n *\n * @param inputs Class strings or `clsx` conditional class objects to merge. Tailwind classes\n * specified later in the arguments overwrite similar Tailwind classes specified earlier in the\n * arguments\n * @returns Class string containing all applicable classes from the arguments based on the rules\n * described above\n */\n// shadcn/ui uses this export in its boilerplate code\n// eslint-disable-next-line import/prefer-default-export\nexport function cn(...inputs: ClassValue[]) {\n return twMergeCustom(clsx(inputs));\n}\n","import React from 'react';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport interface InputProps extends React.InputHTMLAttributes {}\n\nexport const Input = React.forwardRef(\n ({ className, type, ...props }, ref) => {\n return (\n \n );\n },\n);\nInput.displayName = 'Input';\n","import { FocusEventHandler, forwardRef, KeyboardEvent, MouseEventHandler } from 'react';\nimport { History } from 'lucide-react';\nimport { Input as ShadInput } from '@/components/shadcn-ui/input';\n\nexport type BookChapterInputProps = {\n handleSearch: (searchString: string) => void;\n handleKeyDown: (event: KeyboardEvent) => void;\n handleOnClick: MouseEventHandler;\n handleSubmit: () => void;\n onFocus?: FocusEventHandler;\n value: string;\n placeholder: string;\n};\n\n// Shadcn Input sets type to \"button\"- HAVE to prop spread before setting type\nconst BookChapterInput = forwardRef(\n (\n { handleSearch, handleKeyDown, handleOnClick, handleSubmit, ...props }: BookChapterInputProps,\n ref,\n ) => {\n return (\n
    \n handleSearch(event.target.value)}\n onKeyDown={(e) => {\n if (e.key === 'Enter') {\n handleSubmit();\n }\n handleKeyDown(e);\n }}\n onClick={handleOnClick}\n ref={ref}\n />\n {\n // eslint-disable-next-line no-console\n console.log('back in history');\n }}\n />\n
    \n );\n },\n);\n\nexport default BookChapterInput;\n","var P = Object.defineProperty;\nvar R = (t, e, s) => e in t ? P(t, e, { enumerable: !0, configurable: !0, writable: !0, value: s }) : t[e] = s;\nvar n = (t, e, s) => R(t, typeof e != \"symbol\" ? e + \"\" : e, s);\nclass _ {\n constructor() {\n n(this, \"books\");\n n(this, \"firstSelectedBookNum\");\n n(this, \"lastSelectedBookNum\");\n n(this, \"count\");\n n(this, \"selectedBookNumbers\");\n n(this, \"selectedBookIds\");\n }\n}\nconst N = [\n \"GEN\",\n \"EXO\",\n \"LEV\",\n \"NUM\",\n \"DEU\",\n \"JOS\",\n \"JDG\",\n \"RUT\",\n \"1SA\",\n \"2SA\",\n // 10\n \"1KI\",\n \"2KI\",\n \"1CH\",\n \"2CH\",\n \"EZR\",\n \"NEH\",\n \"EST\",\n \"JOB\",\n \"PSA\",\n \"PRO\",\n // 20\n \"ECC\",\n \"SNG\",\n \"ISA\",\n \"JER\",\n \"LAM\",\n \"EZK\",\n \"DAN\",\n \"HOS\",\n \"JOL\",\n \"AMO\",\n // 30\n \"OBA\",\n \"JON\",\n \"MIC\",\n \"NAM\",\n \"HAB\",\n \"ZEP\",\n \"HAG\",\n \"ZEC\",\n \"MAL\",\n \"MAT\",\n // 40\n \"MRK\",\n \"LUK\",\n \"JHN\",\n \"ACT\",\n \"ROM\",\n \"1CO\",\n \"2CO\",\n \"GAL\",\n \"EPH\",\n \"PHP\",\n // 50\n \"COL\",\n \"1TH\",\n \"2TH\",\n \"1TI\",\n \"2TI\",\n \"TIT\",\n \"PHM\",\n \"HEB\",\n \"JAS\",\n \"1PE\",\n // 60\n \"2PE\",\n \"1JN\",\n \"2JN\",\n \"3JN\",\n \"JUD\",\n \"REV\",\n \"TOB\",\n \"JDT\",\n \"ESG\",\n \"WIS\",\n // 70\n \"SIR\",\n \"BAR\",\n \"LJE\",\n \"S3Y\",\n \"SUS\",\n \"BEL\",\n \"1MA\",\n \"2MA\",\n \"3MA\",\n \"4MA\",\n // 80\n \"1ES\",\n \"2ES\",\n \"MAN\",\n \"PS2\",\n \"ODA\",\n \"PSS\",\n \"JSA\",\n // actual variant text for JOS, now in LXA text\n \"JDB\",\n // actual variant text for JDG, now in LXA text\n \"TBS\",\n // actual variant text for TOB, now in LXA text\n \"SST\",\n // actual variant text for SUS, now in LXA text // 90\n \"DNT\",\n // actual variant text for DAN, now in LXA text\n \"BLT\",\n // actual variant text for BEL, now in LXA text\n \"XXA\",\n \"XXB\",\n \"XXC\",\n \"XXD\",\n \"XXE\",\n \"XXF\",\n \"XXG\",\n \"FRT\",\n // 100\n \"BAK\",\n \"OTH\",\n \"3ES\",\n // Used previously but really should be 2ES\n \"EZA\",\n // Used to be called 4ES, but not actually in any known project\n \"5EZ\",\n // Used to be called 5ES, but not actually in any known project\n \"6EZ\",\n // Used to be called 6ES, but not actually in any known project\n \"INT\",\n \"CNC\",\n \"GLO\",\n \"TDX\",\n // 110\n \"NDX\",\n \"DAG\",\n \"PS3\",\n \"2BA\",\n \"LBA\",\n \"JUB\",\n \"ENO\",\n \"1MQ\",\n \"2MQ\",\n \"3MQ\",\n // 120\n \"REP\",\n \"4BA\",\n \"LAO\"\n], B = [\n \"XXA\",\n \"XXB\",\n \"XXC\",\n \"XXD\",\n \"XXE\",\n \"XXF\",\n \"XXG\",\n \"FRT\",\n \"BAK\",\n \"OTH\",\n \"INT\",\n \"CNC\",\n \"GLO\",\n \"TDX\",\n \"NDX\"\n], O = [\n \"Genesis\",\n \"Exodus\",\n \"Leviticus\",\n \"Numbers\",\n \"Deuteronomy\",\n \"Joshua\",\n \"Judges\",\n \"Ruth\",\n \"1 Samuel\",\n \"2 Samuel\",\n \"1 Kings\",\n \"2 Kings\",\n \"1 Chronicles\",\n \"2 Chronicles\",\n \"Ezra\",\n \"Nehemiah\",\n \"Esther (Hebrew)\",\n \"Job\",\n \"Psalms\",\n \"Proverbs\",\n \"Ecclesiastes\",\n \"Song of Songs\",\n \"Isaiah\",\n \"Jeremiah\",\n \"Lamentations\",\n \"Ezekiel\",\n \"Daniel (Hebrew)\",\n \"Hosea\",\n \"Joel\",\n \"Amos\",\n \"Obadiah\",\n \"Jonah\",\n \"Micah\",\n \"Nahum\",\n \"Habakkuk\",\n \"Zephaniah\",\n \"Haggai\",\n \"Zechariah\",\n \"Malachi\",\n \"Matthew\",\n \"Mark\",\n \"Luke\",\n \"John\",\n \"Acts\",\n \"Romans\",\n \"1 Corinthians\",\n \"2 Corinthians\",\n \"Galatians\",\n \"Ephesians\",\n \"Philippians\",\n \"Colossians\",\n \"1 Thessalonians\",\n \"2 Thessalonians\",\n \"1 Timothy\",\n \"2 Timothy\",\n \"Titus\",\n \"Philemon\",\n \"Hebrews\",\n \"James\",\n \"1 Peter\",\n \"2 Peter\",\n \"1 John\",\n \"2 John\",\n \"3 John\",\n \"Jude\",\n \"Revelation\",\n \"Tobit\",\n \"Judith\",\n \"Esther Greek\",\n \"Wisdom of Solomon\",\n \"Sirach (Ecclesiasticus)\",\n \"Baruch\",\n \"Letter of Jeremiah\",\n \"Song of 3 Young Men\",\n \"Susanna\",\n \"Bel and the Dragon\",\n \"1 Maccabees\",\n \"2 Maccabees\",\n \"3 Maccabees\",\n \"4 Maccabees\",\n \"1 Esdras (Greek)\",\n \"2 Esdras (Latin)\",\n \"Prayer of Manasseh\",\n \"Psalm 151\",\n \"Odes\",\n \"Psalms of Solomon\",\n // WARNING, if you change the spelling of the *obsolete* tag be sure to update\n // IsObsolete routine\n \"Joshua A. *obsolete*\",\n \"Judges B. *obsolete*\",\n \"Tobit S. *obsolete*\",\n \"Susanna Th. *obsolete*\",\n \"Daniel Th. *obsolete*\",\n \"Bel Th. *obsolete*\",\n \"Extra A\",\n \"Extra B\",\n \"Extra C\",\n \"Extra D\",\n \"Extra E\",\n \"Extra F\",\n \"Extra G\",\n \"Front Matter\",\n \"Back Matter\",\n \"Other Matter\",\n \"3 Ezra *obsolete*\",\n \"Apocalypse of Ezra\",\n \"5 Ezra (Latin Prologue)\",\n \"6 Ezra (Latin Epilogue)\",\n \"Introduction\",\n \"Concordance \",\n \"Glossary \",\n \"Topical Index\",\n \"Names Index\",\n \"Daniel Greek\",\n \"Psalms 152-155\",\n \"2 Baruch (Apocalypse)\",\n \"Letter of Baruch\",\n \"Jubilees\",\n \"Enoch\",\n \"1 Meqabyan\",\n \"2 Meqabyan\",\n \"3 Meqabyan\",\n \"Reproof (Proverbs 25-31)\",\n \"4 Baruch (Rest of Baruch)\",\n \"Laodiceans\"\n], S = K();\nfunction g(t, e = !0) {\n return e && (t = t.toUpperCase()), t in S ? S[t] : 0;\n}\nfunction k(t) {\n return g(t) > 0;\n}\nfunction x(t) {\n const e = typeof t == \"string\" ? g(t) : t;\n return e >= 40 && e <= 66;\n}\nfunction T(t) {\n return (typeof t == \"string\" ? g(t) : t) <= 39;\n}\nfunction X(t) {\n return t <= 66;\n}\nfunction V(t) {\n const e = typeof t == \"string\" ? g(t) : t;\n return w(e) && !X(e);\n}\nfunction* L() {\n for (let t = 1; t <= N.length; t++) yield t;\n}\nconst G = 1, A = N.length;\nfunction H() {\n return [\"XXA\", \"XXB\", \"XXC\", \"XXD\", \"XXE\", \"XXF\", \"XXG\"];\n}\nfunction C(t, e = \"***\") {\n const s = t - 1;\n return s < 0 || s >= N.length ? e : N[s];\n}\nfunction I(t) {\n return t <= 0 || t > A ? \"******\" : O[t - 1];\n}\nfunction y(t) {\n return I(g(t));\n}\nfunction w(t) {\n const e = typeof t == \"number\" ? C(t) : t;\n return k(e) && !B.includes(e);\n}\nfunction q(t) {\n const e = typeof t == \"number\" ? C(t) : t;\n return k(e) && B.includes(e);\n}\nfunction U(t) {\n return O[t - 1].includes(\"*obsolete*\");\n}\nfunction K() {\n const t = {};\n for (let e = 0; e < N.length; e++)\n t[N[e]] = e + 1;\n return t;\n}\nconst m = {\n allBookIds: N,\n nonCanonicalIds: B,\n bookIdToNumber: g,\n isBookIdValid: k,\n isBookNT: x,\n isBookOT: T,\n isBookOTNT: X,\n isBookDC: V,\n allBookNumbers: L,\n firstBook: G,\n lastBook: A,\n extraBooks: H,\n bookNumberToId: C,\n bookNumberToEnglishName: I,\n bookIdToEnglishName: y,\n isCanonical: w,\n isExtraMaterial: q,\n isObsolete: U\n};\nvar l = /* @__PURE__ */ ((t) => (t[t.Unknown = 0] = \"Unknown\", t[t.Original = 1] = \"Original\", t[t.Septuagint = 2] = \"Septuagint\", t[t.Vulgate = 3] = \"Vulgate\", t[t.English = 4] = \"English\", t[t.RussianProtestant = 5] = \"RussianProtestant\", t[t.RussianOrthodox = 6] = \"RussianOrthodox\", t))(l || {});\nconst h = class h {\n // private versInfo: Versification;\n constructor(e) {\n n(this, \"name\");\n n(this, \"fullPath\");\n n(this, \"isPresent\");\n n(this, \"hasVerseSegments\");\n n(this, \"isCustomized\");\n n(this, \"baseVersification\");\n n(this, \"scriptureBooks\");\n n(this, \"_type\");\n if (e == null)\n throw new Error(\"Argument undefined\");\n typeof e == \"string\" ? (this.name = e, this._type = l[e]) : (this._type = e, this.name = l[e]);\n }\n get type() {\n return this._type;\n }\n equals(e) {\n return !e.type || !this.type ? !1 : e.type === this.type;\n }\n};\nn(h, \"Original\", new h(l.Original)), n(h, \"Septuagint\", new h(l.Septuagint)), n(h, \"Vulgate\", new h(l.Vulgate)), n(h, \"English\", new h(l.English)), n(h, \"RussianProtestant\", new h(l.RussianProtestant)), n(h, \"RussianOrthodox\", new h(l.RussianOrthodox));\nlet c = h;\nfunction E(t, e) {\n const s = e[0];\n for (let r = 1; r < e.length; r++)\n t = t.split(e[r]).join(s);\n return t.split(s);\n}\nvar D = /* @__PURE__ */ ((t) => (t[t.Valid = 0] = \"Valid\", t[t.UnknownVersification = 1] = \"UnknownVersification\", t[t.OutOfRange = 2] = \"OutOfRange\", t[t.VerseOutOfOrder = 3] = \"VerseOutOfOrder\", t[t.VerseRepeated = 4] = \"VerseRepeated\", t))(D || {});\nconst i = class i {\n constructor(e, s, r, a) {\n /** Not yet implemented. */\n n(this, \"firstChapter\");\n /** Not yet implemented. */\n n(this, \"lastChapter\");\n /** Not yet implemented. */\n n(this, \"lastVerse\");\n /** Not yet implemented. */\n n(this, \"hasSegmentsDefined\");\n /** Not yet implemented. */\n n(this, \"text\");\n /** Not yet implemented. */\n n(this, \"BBBCCCVVVS\");\n /** Not yet implemented. */\n n(this, \"longHashCode\");\n /** The versification of the reference. */\n n(this, \"versification\");\n n(this, \"rtlMark\", \"‏\");\n n(this, \"_bookNum\", 0);\n n(this, \"_chapterNum\", 0);\n n(this, \"_verseNum\", 0);\n n(this, \"_verse\");\n if (r == null && a == null)\n if (e != null && typeof e == \"string\") {\n const o = e, u = s != null && s instanceof c ? s : void 0;\n this.setEmpty(u), this.parse(o);\n } else if (e != null && typeof e == \"number\") {\n const o = s != null && s instanceof c ? s : void 0;\n this.setEmpty(o), this._verseNum = e % i.chapterDigitShifter, this._chapterNum = Math.floor(\n e % i.bookDigitShifter / i.chapterDigitShifter\n ), this._bookNum = Math.floor(e / i.bookDigitShifter);\n } else if (s == null)\n if (e != null && e instanceof i) {\n const o = e;\n this._bookNum = o.bookNum, this._chapterNum = o.chapterNum, this._verseNum = o.verseNum, this._verse = o.verse, this.versification = o.versification;\n } else {\n if (e == null) return;\n const o = e instanceof c ? e : i.defaultVersification;\n this.setEmpty(o);\n }\n else\n throw new Error(\"VerseRef constructor not supported.\");\n else if (e != null && s != null && r != null)\n if (typeof e == \"string\" && typeof s == \"string\" && typeof r == \"string\")\n this.setEmpty(a), this.updateInternal(e, s, r);\n else if (typeof e == \"number\" && typeof s == \"number\" && typeof r == \"number\")\n this._bookNum = e, this._chapterNum = s, this._verseNum = r, this.versification = a ?? i.defaultVersification;\n else\n throw new Error(\"VerseRef constructor not supported.\");\n else\n throw new Error(\"VerseRef constructor not supported.\");\n }\n /**\n * Determines if the verse string is in a valid format (does not consider versification).\n */\n static isVerseParseable(e) {\n return e.length > 0 && \"0123456789\".includes(e[0]) && !e.endsWith(this.verseRangeSeparator) && !e.endsWith(this.verseSequenceIndicator);\n }\n /**\n * Tries to parse the specified string into a verse reference.\n * @param str - The string to attempt to parse.\n * @returns success: `true` if the specified string was successfully parsed, `false` otherwise.\n * @returns verseRef: The result of the parse if successful, or empty VerseRef if it failed\n */\n static tryParse(e) {\n let s;\n try {\n return s = new i(e), { success: !0, verseRef: s };\n } catch (r) {\n if (r instanceof v)\n return s = new i(), { success: !1, verseRef: s };\n throw r;\n }\n }\n /**\n * Gets the reference as a comparable integer where the book, chapter, and verse each occupy 3\n * digits.\n * @param bookNum - Book number (this is 1-based, not an index).\n * @param chapterNum - Chapter number.\n * @param verseNum - Verse number.\n * @returns The reference as a comparable integer where the book, chapter, and verse each occupy 3\n * digits.\n */\n static getBBBCCCVVV(e, s, r) {\n return e % i.bcvMaxValue * i.bookDigitShifter + (s >= 0 ? s % i.bcvMaxValue * i.chapterDigitShifter : 0) + (r >= 0 ? r % i.bcvMaxValue : 0);\n }\n /**\n * Deserializes a serialized VerseRef.\n * @param serializedVerseRef - Serialized VerseRef to create from.\n * @returns the deserialized VerseRef.\n */\n static fromJSON(e) {\n const { book: s, chapterNum: r, verseNum: a, verse: o, versificationStr: u } = e, f = o || a.toString();\n let d;\n return u && (d = new c(u)), s ? new i(s, r.toString(), f, d) : new i();\n }\n /**\n * Parses a verse string and gets the leading numeric portion as a number.\n * @param verseStr - verse string to parse\n * @returns true if the entire string could be parsed as a single, simple verse number (1-999);\n * false if the verse string represented a verse bridge, contained segment letters, or was invalid\n */\n static tryGetVerseNum(e) {\n let s;\n if (!e)\n return s = -1, { success: !0, vNum: s };\n s = 0;\n let r;\n for (let a = 0; a < e.length; a++) {\n if (r = e[a], r < \"0\" || r > \"9\")\n return a === 0 && (s = -1), { success: !1, vNum: s };\n if (s = s * 10 + +r - 0, s > i.bcvMaxValue)\n return s = -1, { success: !1, vNum: s };\n }\n return { success: !0, vNum: s };\n }\n /**\n * Checks to see if a VerseRef hasn't been set - all values are the default.\n */\n get isDefault() {\n return this.bookNum === 0 && this.chapterNum === 0 && this.verseNum === 0 && this.versification == null;\n }\n /**\n * Gets whether the verse contains multiple verses.\n */\n get hasMultiple() {\n return this._verse != null && (this._verse.includes(i.verseRangeSeparator) || this._verse.includes(i.verseSequenceIndicator));\n }\n /**\n * Gets or sets the book of the reference. Book is the 3-letter abbreviation in capital letters,\n * e.g. `'MAT'`.\n */\n get book() {\n return m.bookNumberToId(this.bookNum, \"\");\n }\n set book(e) {\n this.bookNum = m.bookIdToNumber(e);\n }\n /**\n * Gets or sets the chapter of the reference,. e.g. `'3'`.\n */\n get chapter() {\n return this.isDefault || this._chapterNum < 0 ? \"\" : this._chapterNum.toString();\n }\n set chapter(e) {\n const s = +e;\n this._chapterNum = Number.isInteger(s) ? s : -1;\n }\n /**\n * Gets or sets the verse of the reference, including range, segments, and sequences, e.g. `'4'`,\n * or `'4b-5a, 7'`.\n */\n get verse() {\n return this._verse != null ? this._verse : this.isDefault || this._verseNum < 0 ? \"\" : this._verseNum.toString();\n }\n set verse(e) {\n const { success: s, vNum: r } = i.tryGetVerseNum(e);\n this._verse = s ? void 0 : e.replace(this.rtlMark, \"\"), this._verseNum = r, !(this._verseNum >= 0) && ({ vNum: this._verseNum } = i.tryGetVerseNum(this._verse));\n }\n /**\n * Get or set Book based on book number, e.g. `42`.\n */\n get bookNum() {\n return this._bookNum;\n }\n set bookNum(e) {\n if (e <= 0 || e > m.lastBook)\n throw new v(\n \"BookNum must be greater than zero and less than or equal to last book\"\n );\n this._bookNum = e;\n }\n /**\n * Gets or sets the chapter number, e.g. `3`. `-1` if not valid.\n */\n get chapterNum() {\n return this._chapterNum;\n }\n set chapterNum(e) {\n this.chapterNum = e;\n }\n /**\n * Gets or sets verse start number, e.g. `4`. `-1` if not valid.\n */\n get verseNum() {\n return this._verseNum;\n }\n set verseNum(e) {\n this._verseNum = e;\n }\n /**\n * String representing the versification (should ONLY be used for serialization/deserialization).\n *\n * @remarks This is for backwards compatibility when ScrVers was an enumeration.\n */\n get versificationStr() {\n var e;\n return (e = this.versification) == null ? void 0 : e.name;\n }\n set versificationStr(e) {\n this.versification = this.versification != null ? new c(e) : void 0;\n }\n /**\n * Determines if the reference is valid.\n */\n get valid() {\n return this.validStatus === 0;\n }\n /**\n * Get the valid status for this reference.\n */\n get validStatus() {\n return this.validateVerse(i.verseRangeSeparators, i.verseSequenceIndicators);\n }\n /**\n * Gets the reference as a comparable integer where the book,\n * chapter, and verse each occupy three digits and the verse is 0.\n */\n get BBBCCC() {\n return i.getBBBCCCVVV(this._bookNum, this._chapterNum, 0);\n }\n /**\n * Gets the reference as a comparable integer where the book,\n * chapter, and verse each occupy three digits. If verse is not null\n * (i.e., this reference represents a complex reference with verse\n * segments or bridge) this cannot be used for an exact comparison.\n */\n get BBBCCCVVV() {\n return i.getBBBCCCVVV(this._bookNum, this._chapterNum, this._verseNum);\n }\n /**\n * Gets whether the verse is defined as an excluded verse in the versification.\n * Does not handle verse ranges.\n */\n // eslint-disable-next-line @typescript-eslint/class-literal-property-style\n get isExcluded() {\n return !1;\n }\n /**\n * Parses the reference in the specified string.\n * Optionally versification can follow reference as in GEN 3:11/4\n * Throw an exception if\n * - invalid book name\n * - chapter number is missing or not a number\n * - verse number is missing or does not start with a number\n * - versification is invalid\n * @param verseStr - string to parse e.g. 'MAT 3:11'\n */\n parse(e) {\n if (e = e.replace(this.rtlMark, \"\"), e.includes(\"/\")) {\n const o = e.split(\"/\");\n if (e = o[0], o.length > 1)\n try {\n const u = +o[1].trim();\n this.versification = new c(l[u]);\n } catch {\n throw new v(\"Invalid reference : \" + e);\n }\n }\n const s = e.trim().split(\" \");\n if (s.length !== 2)\n throw new v(\"Invalid reference : \" + e);\n const r = s[1].split(\":\"), a = +r[0];\n if (r.length !== 2 || m.bookIdToNumber(s[0]) === 0 || !Number.isInteger(a) || a < 0 || !i.isVerseParseable(r[1]))\n throw new v(\"Invalid reference : \" + e);\n this.updateInternal(s[0], r[0], r[1]);\n }\n /**\n * Simplifies this verse ref so that it has no bridging of verses or\n * verse segments like `'1a'`.\n */\n simplify() {\n this._verse = void 0;\n }\n /**\n * Makes a clone of the reference.\n *\n * @returns The cloned VerseRef.\n */\n clone() {\n return new i(this);\n }\n toString() {\n const e = this.book;\n return e === \"\" ? \"\" : `${e} ${this.chapter}:${this.verse}`;\n }\n toJSON() {\n let e = this.verse;\n (e === \"\" || e === this.verseNum.toString()) && (e = void 0);\n const s = {\n book: this.book,\n chapterNum: this.chapterNum,\n verseNum: this.verseNum,\n verse: e,\n versificationStr: this.versificationStr\n };\n return e || delete s.verse, s;\n }\n /**\n * Compares this `VerseRef` with supplied one.\n * @param verseRef - object to compare this one to.\n * @returns `true` if this `VerseRef` is equal to the supplied one, `false` otherwise.\n */\n equals(e) {\n return e instanceof i ? e._bookNum === this._bookNum && e._chapterNum === this._chapterNum && e._verseNum === this._verseNum && e.verse === this.verse && (e.versification == null && this.versification == null || e.versification != null && this.versification != null && e.versification.equals(this.versification)) : !1;\n }\n /**\n * Enumerate all individual verses contained in a VerseRef.\n * Verse ranges are indicated by \"-\" and consecutive verses by \",\"s.\n * Examples:\n * GEN 1:2 returns GEN 1:2\n * GEN 1:1a-3b,5 returns GEN 1:1a, GEN 1:2, GEN 1:3b, GEN 1:5\n * GEN 1:2a-2c returns //! ??????\n *\n * @param specifiedVersesOnly - if set to true return only verses that are\n * explicitly specified only, not verses within a range. Defaults to `false`.\n * @param verseRangeSeparators - Verse range separators.\n * Defaults to `VerseRef.verseRangeSeparators`.\n * @param verseSequenceSeparators - Verse sequence separators.\n * Defaults to `VerseRef.verseSequenceIndicators`.\n * @returns An array of all single verse references in this VerseRef.\n */\n allVerses(e = !1, s = i.verseRangeSeparators, r = i.verseSequenceIndicators) {\n if (this._verse == null || this.chapterNum <= 0)\n return [this.clone()];\n const a = [], o = E(this._verse, r);\n for (const u of o.map((f) => E(f, s))) {\n const f = this.clone();\n f.verse = u[0];\n const d = f.verseNum;\n if (a.push(f), u.length > 1) {\n const b = this.clone();\n if (b.verse = u[1], !e)\n for (let p = d + 1; p < b.verseNum; p++) {\n const J = new i(\n this._bookNum,\n this._chapterNum,\n p,\n this.versification\n );\n this.isExcluded || a.push(J);\n }\n a.push(b);\n }\n }\n return a;\n }\n /**\n * Validates a verse number using the supplied separators rather than the defaults.\n */\n validateVerse(e, s) {\n if (!this.verse)\n return this.internalValid;\n let r = 0;\n for (const a of this.allVerses(!0, e, s)) {\n const o = a.internalValid;\n if (o !== 0)\n return o;\n const u = a.BBBCCCVVV;\n if (r > u)\n return 3;\n if (r === u)\n return 4;\n r = u;\n }\n return 0;\n }\n /**\n * Gets whether a single verse reference is valid.\n */\n get internalValid() {\n return this.versification == null ? 1 : this._bookNum <= 0 || this._bookNum > m.lastBook ? 2 : (m.isCanonical(this._bookNum), 0);\n }\n setEmpty(e = i.defaultVersification) {\n this._bookNum = 0, this._chapterNum = -1, this._verse = void 0, this.versification = e;\n }\n updateInternal(e, s, r) {\n this.bookNum = m.bookIdToNumber(e), this.chapter = s, this.verse = r;\n }\n};\nn(i, \"defaultVersification\", c.English), n(i, \"verseRangeSeparator\", \"-\"), n(i, \"verseSequenceIndicator\", \",\"), n(i, \"verseRangeSeparators\", [i.verseRangeSeparator]), n(i, \"verseSequenceIndicators\", [i.verseSequenceIndicator]), n(i, \"chapterDigitShifter\", 1e3), n(i, \"bookDigitShifter\", i.chapterDigitShifter * i.chapterDigitShifter), n(i, \"bcvMaxValue\", i.chapterDigitShifter - 1), /**\n * The valid status of the VerseRef.\n */\nn(i, \"ValidStatusType\", D);\nlet M = i;\nclass v extends Error {\n}\nexport {\n _ as BookSet,\n m as Canon,\n c as ScrVers,\n l as ScrVersType,\n M as VerseRef,\n v as VerseRefException\n};\n//# sourceMappingURL=index.es.js.map\n","import React from 'react';\nimport * as DropdownMenuPrimitive from '@radix-ui/react-dropdown-menu';\nimport { Check, ChevronRight, Circle } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport const DropdownMenu = DropdownMenuPrimitive.Root;\n\nexport const DropdownMenuTrigger = DropdownMenuPrimitive.Trigger;\n\nexport const DropdownMenuGroup = DropdownMenuPrimitive.Group;\n\nexport const DropdownMenuPortal = DropdownMenuPrimitive.Portal;\n\nexport const DropdownMenuSub = DropdownMenuPrimitive.Sub;\n\nexport const DropdownMenuRadioGroup = DropdownMenuPrimitive.RadioGroup;\n\nexport type DropdownMenuSubTriggerProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.SubTrigger\n> & {\n className?: string;\n inset?: boolean;\n};\n\nexport type DropdownMenuSubContentProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.SubContent\n> & {\n className?: string;\n};\n\nexport type DropdownMenuContentProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Content\n> & {\n className?: string;\n sideOffset?: number;\n};\n\nexport type DropdownMenuItemProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Item\n> & {\n className?: string;\n inset?: boolean;\n};\n\nexport type DropdownMenuCheckboxItemProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.CheckboxItem\n> & {\n className?: string;\n checked?: boolean;\n};\n\nexport type DropdownMenuRadioItemProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.RadioItem\n> & {\n className?: string;\n};\n\nexport type DropdownMenuLabelProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Label\n> & {\n className?: string;\n inset?: boolean;\n};\n\nexport type DropdownMenuSeparatorProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Separator\n> & {\n className?: string;\n};\n\nexport type DropdownMenuShortcutProps = React.HTMLAttributes & {\n className?: string;\n};\n\nexport const DropdownMenuSubTrigger = React.forwardRef<\n React.ElementRef,\n DropdownMenuSubTriggerProps\n>(({ className, inset, children, ...props }, ref) => (\n \n {children}\n \n \n));\nDropdownMenuSubTrigger.displayName = DropdownMenuPrimitive.SubTrigger.displayName;\n\nexport const DropdownMenuSubContent = React.forwardRef<\n React.ElementRef,\n DropdownMenuSubContentProps\n>(({ className, ...props }, ref) => (\n \n));\nDropdownMenuSubContent.displayName = DropdownMenuPrimitive.SubContent.displayName;\n\nexport const DropdownMenuContent = React.forwardRef<\n React.ElementRef,\n DropdownMenuContentProps\n>(({ className, sideOffset = 4, ...props }, ref) => (\n \n \n \n));\nDropdownMenuContent.displayName = DropdownMenuPrimitive.Content.displayName;\n\n/**\n * TODO: fix: direction is not automatically handled by this component, so that shortcuts are\n * display always to the right\n */\nexport const DropdownMenuItem = React.forwardRef<\n React.ElementRef,\n DropdownMenuItemProps\n>(({ className, inset, ...props }, ref) => (\n \n));\nDropdownMenuItem.displayName = DropdownMenuPrimitive.Item.displayName;\n\nexport const DropdownMenuCheckboxItem = React.forwardRef<\n React.ElementRef,\n DropdownMenuCheckboxItemProps\n>(({ className, children, checked, ...props }, ref) => (\n \n \n \n \n \n \n {children}\n \n));\nDropdownMenuCheckboxItem.displayName = DropdownMenuPrimitive.CheckboxItem.displayName;\n\nexport const DropdownMenuRadioItem = React.forwardRef<\n React.ElementRef,\n DropdownMenuRadioItemProps\n>(({ className, children, ...props }, ref) => (\n \n \n \n \n \n \n {children}\n \n));\nDropdownMenuRadioItem.displayName = DropdownMenuPrimitive.RadioItem.displayName;\n\nexport const DropdownMenuLabel = React.forwardRef<\n React.ElementRef,\n DropdownMenuLabelProps\n>(({ className, inset, ...props }, ref) => (\n \n));\nDropdownMenuLabel.displayName = DropdownMenuPrimitive.Label.displayName;\n\nexport const DropdownMenuSeparator = React.forwardRef<\n React.ElementRef,\n DropdownMenuSeparatorProps\n>(({ className, ...props }, ref) => (\n \n));\nDropdownMenuSeparator.displayName = DropdownMenuPrimitive.Separator.displayName;\n\nexport function DropdownMenuShortcut({ className, ...props }: DropdownMenuShortcutProps) {\n return (\n \n );\n}\nDropdownMenuShortcut.displayName = 'DropdownMenuShortcut';\n","import { Canon } from '@sillsdev/scripture';\nimport { PropsWithChildren, KeyboardEvent, forwardRef } from 'react';\nimport { DropdownMenuItem as ShadDropdownMenuItem } from '@/components/shadcn-ui/dropdown-menu';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport type BookType = 'OT' | 'NT' | 'DC';\n\ntype BookMenuItemProps = PropsWithChildren<{\n /** String id of book */\n bookId: string;\n /** Callback to run when a book menu item is selected */\n handleSelectBook: () => void;\n /** Indicates if this menu item is currently selected */\n isSelected: boolean;\n /** Function that is called upon highlighting a book in the dropdown menu */\n handleHighlightBook: () => void;\n /**\n * Function that is called on pressing a key\n *\n * @param event Event that contains information about the key stroke\n */\n handleKeyDown: (event: KeyboardEvent) => void;\n /**\n * Type of book associated with this menu item, coordinates color labels ? Mock up has the labels\n * coordinated to genre\n */\n bookType: BookType;\n}>;\n\nconst BookMenuItem = forwardRef(\n (\n {\n bookId,\n handleSelectBook,\n isSelected,\n handleHighlightBook,\n handleKeyDown,\n bookType,\n children,\n }: BookMenuItemProps,\n ref,\n ) => {\n return (\n {\n // preventDefault() here prevents the entire dropdown menu from closing when selecting this item\n event.preventDefault();\n handleSelectBook();\n }}\n onKeyDown={(event: KeyboardEvent) => {\n handleKeyDown(event);\n }}\n onFocus={handleHighlightBook}\n onMouseMove={handleHighlightBook}\n >\n \n {Canon.bookIdToEnglishName(bookId)}\n \n {isSelected &&
    {children}
    }\n \n );\n },\n);\n\nexport default BookMenuItem;\n","import { cn } from '@/utils/shadcn-ui.util';\nimport { useCallback } from 'react';\n\nexport type ChapterSelectProps = {\n /**\n * Callback to run when a chapter div is selected\n *\n * @param chapterNumber Number of the chapter that has been selected\n */\n handleSelectChapter: (chapterNumber: number) => void;\n /** The highest chapter number in the book (of course equal to number of chapters in the book) */\n endChapter: number;\n /** The chapter number that is currently selected */\n activeChapter: number;\n /** The chapter number that is currently highlighted using keyboard or mouse navigation */\n highlightedChapter: number;\n /**\n * Callback to run when a chapter is highlighted by the user\n *\n * @param chapterNumber The chapter that is highlighted\n */\n handleHighlightedChapter: (chapterNumber: number) => void;\n};\n\nfunction ChapterSelect({\n handleSelectChapter,\n endChapter,\n activeChapter,\n highlightedChapter,\n handleHighlightedChapter,\n}: ChapterSelectProps) {\n const chapters = Array.from({ length: endChapter }, (_, i) => i + 1);\n\n const handleMouse = useCallback(\n (chapterNumber: number) => {\n handleHighlightedChapter(chapterNumber);\n },\n [handleHighlightedChapter],\n );\n\n return (\n
    \n {chapters.map((chapter) => (\n {\n event.preventDefault();\n event.stopPropagation();\n handleSelectChapter(chapter);\n }}\n role=\"button\"\n onKeyDown={(event) => {\n if (event.key === 'Enter') {\n handleSelectChapter(chapter);\n }\n }}\n tabIndex={0}\n onMouseMove={() => handleMouse(chapter)}\n >\n {chapter}\n
    \n ))}\n
    \n );\n}\n\nexport default ChapterSelect;\n","import { DropdownMenuLabel as ShadDropdownMenuLabel } from '@/components/shadcn-ui/dropdown-menu';\nimport { Bookmark, Clock, ArrowDownWideNarrow } from 'lucide-react';\n\nexport type GoToMenuItemProps = {\n handleSort: () => void;\n handleLocationHistory: () => void;\n handleBookmarks: () => void;\n};\n\nfunction GoToMenuItem({ handleSort, handleLocationHistory, handleBookmarks }: GoToMenuItemProps) {\n return (\n \n

    Go To

    \n
    \n \n \n \n
    \n
    \n );\n}\n\nexport default GoToMenuItem;\n","import BookChapterInput from '@/components/advanced/book-chapter-control/book-chapter-input.component';\nimport BookMenuItem, {\n BookType,\n} from '@/components/advanced/book-chapter-control/book-menu-item.component';\nimport ChapterSelect from '@/components/advanced/book-chapter-control/chapter-select.component';\nimport GoToMenuItem from '@/components/advanced/book-chapter-control/go-to-menu-item.component';\nimport {\n DropdownMenu as ShadDropdownMenu,\n DropdownMenuContent as ShadDropdownMenuContent,\n DropdownMenuLabel as ShadDropdownMenuLabel,\n DropdownMenuSeparator as ShadDropdownMenuSeparator,\n DropdownMenuTrigger as ShadDropdownMenuTrigger,\n} from '@/components/shadcn-ui/dropdown-menu';\nimport { Canon } from '@sillsdev/scripture';\nimport { ScriptureReference, getChaptersForBook } from 'platform-bible-utils';\nimport {\n KeyboardEvent as ReactKeyboardEvent,\n useCallback,\n useEffect,\n useLayoutEffect,\n useRef,\n useState,\n} from 'react';\n\ntype BookTypeLabels = {\n [bookType in BookType]: string;\n};\ntype BookChapterControlProps = {\n scrRef: ScriptureReference;\n handleSubmit: (scrRef: ScriptureReference) => void;\n};\n\nconst ALL_BOOK_IDS = Canon.allBookIds;\nconst BOOK_TYPE_LABELS: BookTypeLabels = {\n OT: 'Old Testament',\n NT: 'New Testament',\n DC: 'Deuterocanon',\n};\nconst BOOK_TYPE_ARRAY: BookType[] = ['OT', 'NT', 'DC'];\n// This is the height of three menu items to offset scrolling to the selected menu item\n// If you use menuItemRef.clientHeight- includes height of chapter div which is too big\nconst SCROLL_OFFSET = 32 + 32 + 32;\nconst SEARCH_QUERY_FORMATS = [\n /^(\\w+)$/i, // Matches a single word (book name or id)\n /^(\\w+)(?:\\s(\\d+))$/i, // Matches a word followed by a chapter number\n /^(\\w+)(?:\\s(\\d+):(\\d+))$/i, // Matches a word followed by a chapter and verse number\n];\nconst fetchGroupedBooks = (bookType: BookType) => {\n const groupedBooks = {\n OT: ALL_BOOK_IDS.filter((bookId) => Canon.isBookOT(bookId)),\n NT: ALL_BOOK_IDS.filter((bookId) => Canon.isBookNT(bookId)),\n DC: ALL_BOOK_IDS.filter((bookId) => Canon.isBookDC(bookId)),\n };\n return groupedBooks[bookType];\n};\nconst fetchEndChapter = (bookId: string) => {\n // getChaptersForBook returns -1 if not found in scrBookData\n // scrBookData only includes OT and NT, so all DC will return -1\n return getChaptersForBook(Canon.bookIdToNumber(bookId));\n};\n\n/**\n * Gets all of the English names from book ids\n *\n * @returns String[]\n */\nfunction getAllEnglishNames(): string[] {\n const allEnglishNames = ALL_BOOK_IDS.map((bookId) => {\n return Canon.bookIdToEnglishName(bookId);\n });\n return allEnglishNames;\n}\n\n/**\n * Determines if bookName is in allEnglishNames\n *\n * @param bookName Book English name\n * @returns True if bookName is included, false otherwise\n */\nfunction isValidBookEnglishName(bookName: string): boolean {\n return getAllEnglishNames().includes(bookName);\n}\n\n/**\n * Gets a bookId from given English name\n *\n * @param bookName Book English name\n * @returns BookId of provided bookName, undefined otherwise\n */\nfunction getBookIdFromEnglishName(bookName: string): string | undefined {\n // Convert bookName to lowercase and then capitalize the first letter\n const formattedBookName = bookName.toLowerCase().replace(/^\\w/, (c) => c.toUpperCase());\n\n if (isValidBookEnglishName(formattedBookName)) {\n const matchingBookId = ALL_BOOK_IDS.find((bookId) => {\n return Canon.bookIdToEnglishName(bookId) === formattedBookName;\n });\n return matchingBookId;\n }\n\n return undefined;\n}\n\nfunction BookChapterControl({ scrRef, handleSubmit }: BookChapterControlProps) {\n const [searchQuery, setSearchQuery] = useState('');\n const [selectedBookId, setSelectedBookId] = useState(\n Canon.bookNumberToId(scrRef.bookNum),\n );\n const [highlightedChapter, setHighlightedChapter] = useState(scrRef.chapterNum ?? 0);\n const [highlightedBookId, setHighlightedBookId] = useState(\n Canon.bookNumberToId(scrRef.bookNum),\n );\n const [isContentOpen, setIsContentOpen] = useState(false);\n const [isContentOpenDelayed, setIsContentOpenDelayed] = useState(isContentOpen);\n\n // This ref will always be defined\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const inputRef = useRef(undefined!);\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const contentRef = useRef(undefined!);\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const menuItemRef = useRef(undefined!);\n\n const fetchFilteredBooks = useCallback(\n (bookType: BookType) => {\n return fetchGroupedBooks(bookType).filter((bookId: string) => {\n const englishNameLowerCase = Canon.bookIdToEnglishName(bookId).toLowerCase();\n const normalizedQuery = searchQuery.replace(/[^a-zA-Z]/g, '').toLowerCase();\n return (\n englishNameLowerCase.includes(normalizedQuery) || // Match book name\n bookId.toLowerCase().includes(normalizedQuery) // Match book ID\n );\n });\n },\n [searchQuery],\n );\n\n const handleSearchInput = (searchString: string) => {\n setSearchQuery(searchString);\n };\n\n /**\n * Whether to prevent radix's logic from closing the dropdown. This is important because radix\n * tries to close the dropdown when the input first focuses, and we don't want it to do that. But\n * we don't want to prevent the dropdown from closing when we click away from the input, so we\n * don't want to just keep it open if the input is focused\n */\n const shouldPreventAutoClosing = useRef(false);\n\n const controlMenuState = useCallback((open: boolean) => {\n if (shouldPreventAutoClosing.current) {\n shouldPreventAutoClosing.current = false;\n return;\n }\n setIsContentOpen(open);\n }, []);\n\n const updateReference = useCallback(\n (bookId: string, shouldClose: boolean, chapter?: number, verse?: number) => {\n setHighlightedChapter(\n Canon.bookNumberToId(scrRef.bookNum) !== bookId ? 1 : scrRef.chapterNum,\n );\n\n if (shouldClose || fetchEndChapter(bookId) === -1) {\n handleSubmit({\n bookNum: Canon.bookIdToNumber(bookId),\n chapterNum: chapter || 1,\n verseNum: verse || 1,\n });\n\n setIsContentOpen(false);\n setSearchQuery('');\n return;\n }\n\n setSelectedBookId(selectedBookId !== bookId ? bookId : '');\n setIsContentOpen(!shouldClose);\n },\n [handleSubmit, scrRef.bookNum, scrRef.chapterNum, selectedBookId],\n );\n\n const handleSelectChapter = (chapterNumber: number) => {\n if (chapterNumber <= 0 || chapterNumber > fetchEndChapter(selectedBookId)) {\n return;\n }\n updateReference(selectedBookId, true, chapterNumber);\n };\n\n const handleInputSubmit = useCallback(() => {\n SEARCH_QUERY_FORMATS.forEach((format) => {\n const matches = searchQuery.match(format);\n if (matches) {\n // Book should be a bookId or an english name\n const [book, chapter = undefined, verse = undefined] = matches.slice(1);\n const englishName = getBookIdFromEnglishName(book);\n\n if (Canon.isBookIdValid(book) || englishName) {\n updateReference(\n englishName ?? book,\n true,\n chapter ? parseInt(chapter, 10) : 1,\n verse ? parseInt(verse, 10) : 1,\n );\n }\n }\n });\n }, [updateReference, searchQuery]);\n\n const handleKeyDownInput = useCallback(\n (event: ReactKeyboardEvent) => {\n if (!isContentOpen) {\n setIsContentOpen(true);\n } else if (event.key === 'ArrowDown' || event.key === 'ArrowUp') {\n if (\n typeof menuItemRef !== 'undefined' &&\n // Ref uses null\n // eslint-disable-next-line no-null/no-null\n menuItemRef.current !== null\n ) {\n menuItemRef.current.focus();\n } else if (\n typeof contentRef !== 'undefined' &&\n // Ref uses null\n // eslint-disable-next-line no-null/no-null\n contentRef.current !== null\n ) {\n contentRef.current.focus();\n }\n event.preventDefault();\n }\n },\n [isContentOpen],\n );\n\n const handleKeyDownContent = (event: ReactKeyboardEvent) => {\n // When the dropdown menu has focus, key strokes should give focus to the input component,\n // unless they're navigation keys (arrows and enter)\n const { key } = event;\n if (\n key === 'ArrowRight' ||\n key === 'ArrowLeft' ||\n key === 'ArrowDown' ||\n key === 'ArrowUp' ||\n key === 'Enter'\n ) {\n return;\n }\n\n inputRef.current.dispatchEvent(new KeyboardEvent('keydown', { key }));\n inputRef.current.focus();\n };\n\n const handleKeyDownMenuItem = (event: ReactKeyboardEvent) => {\n const { key } = event;\n if (highlightedBookId === selectedBookId) {\n if (key === 'Enter') {\n event.preventDefault();\n updateReference(selectedBookId, true, highlightedChapter);\n return;\n }\n\n let chapterOffSet = 0;\n if (key === 'ArrowRight') {\n if (highlightedChapter < fetchEndChapter(highlightedBookId)) {\n chapterOffSet = 1;\n } else {\n event.preventDefault();\n return;\n }\n } else if (key === 'ArrowLeft') {\n if (highlightedChapter > 1) {\n chapterOffSet = -1;\n } else {\n event.preventDefault();\n return;\n }\n } else if (key === 'ArrowDown') {\n chapterOffSet = 6;\n } else if (key === 'ArrowUp') {\n chapterOffSet = -6;\n }\n if (\n highlightedChapter + chapterOffSet <= 0 ||\n highlightedChapter + chapterOffSet > fetchEndChapter(highlightedBookId)\n ) {\n setHighlightedChapter(0);\n } else if (chapterOffSet !== 0) {\n setHighlightedChapter(highlightedChapter + chapterOffSet);\n event.preventDefault();\n }\n }\n };\n\n useEffect(() => {\n if (selectedBookId === highlightedBookId) {\n if (selectedBookId === Canon.bookNumberToId(scrRef.bookNum)) {\n setHighlightedChapter(scrRef.chapterNum);\n } else {\n setHighlightedChapter(1);\n }\n } else {\n setHighlightedChapter(0);\n }\n }, [highlightedBookId, scrRef.bookNum, scrRef.chapterNum, selectedBookId]);\n\n // The purpose of these useLayoutEffects and timeout is to delay the scroll just\n // enough so that the refs are defined and available when they are used after the timeout\n useLayoutEffect(() => {\n setIsContentOpenDelayed(isContentOpen);\n }, [isContentOpen]);\n\n useLayoutEffect(() => {\n const scrollTimeout = setTimeout(() => {\n if (isContentOpenDelayed && contentRef.current && menuItemRef.current) {\n const menuItemOffsetTop = menuItemRef.current.offsetTop;\n const scrollPosition = menuItemOffsetTop - SCROLL_OFFSET;\n contentRef.current.scrollTo({ top: scrollPosition, behavior: 'instant' });\n }\n }, 10);\n return () => {\n clearTimeout(scrollTimeout);\n };\n }, [isContentOpenDelayed]);\n\n return (\n
    \n \n \n {\n setSelectedBookId(Canon.bookNumberToId(scrRef.bookNum));\n setHighlightedBookId(Canon.bookNumberToId(scrRef.bookNum));\n setHighlightedChapter(scrRef.chapterNum > 0 ? scrRef.chapterNum : 0);\n setIsContentOpen(true);\n inputRef.current.focus();\n }}\n onFocus={() => {\n // Radix thinks we want to close because the input is being focused. Prevent that\n shouldPreventAutoClosing.current = true;\n }}\n handleSubmit={handleInputSubmit}\n placeholder={`${Canon.bookNumberToEnglishName(scrRef.bookNum)} ${scrRef.chapterNum}:${scrRef.verseNum}`}\n />\n \n \n console.log('sorting')}\n handleLocationHistory={() => console.log('location history')}\n handleBookmarks={() => console.log('bookmarks')}\n />\n {BOOK_TYPE_ARRAY.map(\n (bookType, bookTypeIndex) =>\n fetchFilteredBooks(bookType).length > 0 && (\n
    \n \n {BOOK_TYPE_LABELS[bookType]}\n \n\n {fetchFilteredBooks(bookType).map((bookId) => (\n
    \n updateReference(bookId, false)}\n isSelected={selectedBookId === bookId}\n handleHighlightBook={() => setHighlightedBookId(bookId)}\n handleKeyDown={handleKeyDownMenuItem}\n bookType={bookType}\n ref={(element: HTMLDivElement) => {\n if (selectedBookId === bookId) menuItemRef.current = element;\n }}\n >\n {\n setHighlightedChapter(chapterNumber);\n }}\n />\n \n
    \n ))}\n {BOOK_TYPE_ARRAY.length - 1 !== bookTypeIndex ? (\n \n ) : undefined}\n
    \n ),\n )}\n \n
    \n
    \n );\n}\n\nexport default BookChapterControl;\n","import React from 'react';\nimport { Slot } from '@radix-ui/react-slot';\nimport { cva, type VariantProps } from 'class-variance-authority';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport const buttonVariants = cva(\n 'pr-twp tw-inline-flex tw-items-center tw-justify-center tw-whitespace-nowrap tw-rounded-md tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-colors focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50',\n {\n variants: {\n variant: {\n default: 'tw-bg-primary tw-text-primary-foreground hover:tw-bg-primary/90',\n destructive: 'tw-bg-destructive tw-text-destructive-foreground hover:tw-bg-destructive/90',\n outline:\n 'tw-border tw-border-input tw-bg-background hover:tw-bg-accent hover:tw-text-accent-foreground',\n secondary: 'tw-bg-secondary tw-text-secondary-foreground hover:tw-bg-secondary/80',\n ghost: 'hover:tw-bg-accent hover:tw-text-accent-foreground',\n link: 'tw-text-primary tw-underline-offset-4 hover:tw-underline',\n },\n size: {\n default: 'tw-h-10 tw-px-4 tw-py-2',\n sm: 'tw-h-9 tw-rounded-md tw-px-3',\n lg: 'tw-h-11 tw-rounded-md tw-px-8',\n icon: 'tw-h-10 tw-w-10',\n },\n },\n defaultVariants: {\n variant: 'default',\n size: 'default',\n },\n },\n);\n\nexport interface ButtonProps\n extends React.ButtonHTMLAttributes,\n VariantProps {\n asChild?: boolean;\n}\n\nexport const Button = React.forwardRef(\n ({ className, variant, size, asChild = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'button';\n return (\n \n );\n },\n);\nButton.displayName = 'Button';\n","import React from 'react';\nimport * as LabelPrimitive from '@radix-ui/react-label';\nimport { cva, type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst labelVariants = cva(\n 'tw-text-sm tw-font-medium tw-leading-none peer-disabled:tw-cursor-not-allowed peer-disabled:tw-opacity-70',\n);\n\nexport const Label = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef & VariantProps\n>(({ className, ...props }, ref) => (\n \n));\nLabel.displayName = LabelPrimitive.Root.displayName;\n","import React from 'react';\nimport * as RadioGroupPrimitive from '@radix-ui/react-radio-group';\nimport { Circle } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst RadioGroup = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => {\n return (\n \n );\n});\nRadioGroup.displayName = RadioGroupPrimitive.Root.displayName;\n\nconst RadioGroupItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => {\n return (\n \n \n \n \n \n );\n});\nRadioGroupItem.displayName = RadioGroupPrimitive.Item.displayName;\n\nexport { RadioGroup, RadioGroupItem };\n","import React from 'react';\nimport * as PopoverPrimitive from '@radix-ui/react-popover';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Popover = PopoverPrimitive.Root;\n\nconst PopoverTrigger = PopoverPrimitive.Trigger;\n\nconst PopoverContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, align = 'center', sideOffset = 4, ...props }, ref) => (\n \n \n \n));\nPopoverContent.displayName = PopoverPrimitive.Content.displayName;\n\nexport { Popover, PopoverTrigger, PopoverContent };\n","import React from 'react';\nimport * as DialogPrimitive from '@radix-ui/react-dialog';\nimport { X } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Dialog = DialogPrimitive.Root;\n\nconst DialogTrigger = DialogPrimitive.Trigger;\n\nconst DialogPortal = DialogPrimitive.Portal;\n\nconst DialogClose = DialogPrimitive.Close;\n\nconst DialogOverlay = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nDialogOverlay.displayName = DialogPrimitive.Overlay.displayName;\n\nconst DialogContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, ...props }, ref) => (\n \n \n \n {children}\n \n \n Close\n \n \n \n));\nDialogContent.displayName = DialogPrimitive.Content.displayName;\n\nfunction DialogHeader({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nDialogHeader.displayName = 'DialogHeader';\n\nfunction DialogFooter({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nDialogFooter.displayName = 'DialogFooter';\n\nconst DialogTitle = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nDialogTitle.displayName = DialogPrimitive.Title.displayName;\n\nconst DialogDescription = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nDialogDescription.displayName = DialogPrimitive.Description.displayName;\n\nexport {\n Dialog,\n DialogPortal,\n DialogOverlay,\n DialogClose,\n DialogTrigger,\n DialogContent,\n DialogHeader,\n DialogFooter,\n DialogTitle,\n DialogDescription,\n};\n","import React from 'react';\nimport { type DialogProps } from '@radix-ui/react-dialog';\nimport { Command as CommandPrimitive } from 'cmdk';\nimport { Search } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Dialog, DialogContent } from '@/components/shadcn-ui/dialog';\n\nconst Command = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nCommand.displayName = CommandPrimitive.displayName;\n\ninterface CommandDialogProps extends DialogProps {}\n\nfunction CommandDialog({ children, ...props }: CommandDialogProps) {\n return (\n \n \n \n {children}\n \n \n \n );\n}\n\nconst CommandInput = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n
    \n \n \n
    \n));\n\nCommandInput.displayName = CommandPrimitive.Input.displayName;\n\nconst CommandList = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\n\nCommandList.displayName = CommandPrimitive.List.displayName;\n\nconst CommandEmpty = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>((props, ref) => (\n \n));\n\nCommandEmpty.displayName = CommandPrimitive.Empty.displayName;\n\nconst CommandGroup = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\n\nCommandGroup.displayName = CommandPrimitive.Group.displayName;\n\nconst CommandSeparator = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nCommandSeparator.displayName = CommandPrimitive.Separator.displayName;\n\nconst CommandItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\n\nCommandItem.displayName = CommandPrimitive.Item.displayName;\n\nfunction CommandShortcut({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nCommandShortcut.displayName = 'CommandShortcut';\n\nexport {\n Command,\n CommandDialog,\n CommandInput,\n CommandList,\n CommandEmpty,\n CommandGroup,\n CommandItem,\n CommandShortcut,\n CommandSeparator,\n};\n","import { useState } from 'react';\nimport { Check, ChevronsUpDown } from 'lucide-react';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport { Popover, PopoverContent, PopoverTrigger } from '@/components/shadcn-ui/popover';\nimport {\n Command,\n CommandEmpty,\n CommandInput,\n CommandItem,\n CommandList,\n} from '@/components/shadcn-ui/command';\nimport { PopoverProps } from '@radix-ui/react-popover';\n\nexport type ComboBoxLabelOption = { label: string };\nexport type ComboBoxOption = string | number | ComboBoxLabelOption;\n\nexport type ComboBoxProps = {\n /** Optional unique identifier */\n id?: string;\n /** Text label title for combobox */\n /** List of available options for the dropdown menu */\n options?: readonly T[];\n /** Additional css classes to help with unique styling of the combo box */\n className?: string;\n /**\n * The selected value that the combo box currently holds. Must be shallow equal to one of the\n * options entries.\n */\n value?: T;\n /** Triggers when content of textfield is changed */\n onChange?: (newValue: T) => void;\n /** Used to determine the string value for a given option. */\n getOptionLabel?: (option: ComboBoxOption) => string;\n /** Text displayed on button if `value` is undefined */\n buttonPlaceholder?: string;\n /** Placeholder text for text field */\n textPlaceholder?: string;\n /** Text to display when no options match input */\n commandEmptyMessage?: string;\n /** Variant of button */\n buttonVariant?: ButtonProps['variant'];\n /** Text direction ltr or rtl */\n dir?: Direction;\n /** Optional boolean to set if trigger should be disabled */\n isDisabled?: boolean;\n} & PopoverProps;\n\ntype Direction = 'ltr' | 'rtl';\n\nfunction getOptionLabelDefault(option: ComboBoxOption): string {\n if (typeof option === 'string') {\n return option;\n }\n if (typeof option === 'number') {\n return option.toString();\n }\n return option.label;\n}\n\n/**\n * Autocomplete input and command palette with a list of suggestions.\n *\n * Thanks to Shadcn for heavy inspiration and documentation\n * https://ui.shadcn.com/docs/components/combobox\n */\nfunction ComboBox({\n id,\n options = [],\n className,\n value,\n onChange = () => {},\n getOptionLabel = getOptionLabelDefault,\n buttonPlaceholder = '',\n textPlaceholder = '',\n commandEmptyMessage = 'No option found',\n buttonVariant = 'outline',\n dir = 'ltr',\n isDisabled = false,\n ...props\n}: ComboBoxProps) {\n const [open, setOpen] = useState(false);\n\n return (\n \n \n \n \n {value ? getOptionLabel(value) : buttonPlaceholder}\n \n \n \n \n \n \n \n {commandEmptyMessage}\n \n {options.map((option) => (\n {\n onChange(option);\n setOpen(false);\n }}\n >\n \n {getOptionLabel(option)}\n \n ))}\n \n \n \n \n );\n}\n\nexport default ComboBox;\n","import { useMemo } from 'react';\nimport ComboBox from '@/components/basics/combo-box.component';\nimport { Label } from '@/components/shadcn-ui/label';\n\nexport type ChapterRangeSelectorProps = {\n startChapter: number;\n endChapter: number;\n handleSelectStartChapter: (chapter: number) => void;\n handleSelectEndChapter: (chapter: number) => void;\n isDisabled?: boolean;\n chapterCount: number;\n};\n\nexport default function ChapterRangeSelector({\n startChapter,\n endChapter,\n handleSelectStartChapter,\n handleSelectEndChapter,\n isDisabled = false,\n chapterCount,\n}: ChapterRangeSelectorProps) {\n const chapterOptions = useMemo(\n () => Array.from({ length: chapterCount }, (_, index) => index + 1),\n [chapterCount],\n );\n\n const onChangeStartChapter = (value: number) => {\n handleSelectStartChapter(value);\n if (value > endChapter) {\n handleSelectEndChapter(value);\n }\n };\n\n const onChangeEndChapter = (value: number) => {\n handleSelectEndChapter(value);\n if (value < startChapter) {\n handleSelectStartChapter(value);\n }\n };\n\n return (\n <>\n \n option.toString()}\n value={startChapter}\n />\n\n \n option.toString()}\n value={endChapter}\n />\n \n );\n}\n","import { Button } from '@/components/shadcn-ui/button';\nimport { Label } from '@/components/shadcn-ui/label';\nimport { RadioGroup, RadioGroupItem } from '@/components/shadcn-ui/radio-group';\nimport { Canon } from '@sillsdev/scripture';\nimport { LocalizedStringValue } from 'platform-bible-utils';\nimport { useState } from 'react';\nimport ChapterRangeSelector, {\n ChapterRangeSelectorProps,\n} from '../basics/chapter-range-selector.component';\n\nexport enum BookSelectionMode {\n CURRENT_BOOK = 'current book',\n CHOOSE_BOOKS = 'choose books',\n}\n\n/**\n * Object containing all keys used for localization in this component. If you're using this\n * component in an extension, you can pass it into the useLocalizedStrings hook to easily obtain the\n * localized strings and pass them into the localizedStrings prop of this component\n */\nexport const BOOK_SELECTOR_STRING_KEYS = Object.freeze([\n '%webView_bookSelector_currentBook%',\n '%webView_bookSelector_choose%',\n '%webView_bookSelector_chooseBooks%',\n] as const);\n\nexport type BookSelectorLocalizedStrings = {\n [localizedInventoryKey in (typeof BOOK_SELECTOR_STRING_KEYS)[number]]?: LocalizedStringValue;\n};\n\n/**\n * Gets the localized value for the provided key\n *\n * @param strings Object containing localized string\n * @param key Key for a localized string\n * @returns The localized value for the provided key, if available. Returns the key if no localized\n * value is available\n */\nconst localizeString = (\n strings: BookSelectorLocalizedStrings,\n key: keyof BookSelectorLocalizedStrings,\n) => {\n return strings[key] ?? key;\n};\n\ntype BookSelectorProps = ChapterRangeSelectorProps & {\n handleBookSelectionModeChange: (newMode: BookSelectionMode) => void;\n currentBookName: string;\n onSelectBooks: () => void;\n selectedBookIds: string[];\n localizedStrings: BookSelectorLocalizedStrings;\n};\n\nexport default function BookSelector({\n handleBookSelectionModeChange,\n currentBookName,\n onSelectBooks,\n selectedBookIds,\n chapterCount,\n endChapter,\n handleSelectEndChapter,\n startChapter,\n handleSelectStartChapter,\n localizedStrings,\n}: BookSelectorProps) {\n const currentBookText = localizeString(localizedStrings, '%webView_bookSelector_currentBook%');\n const chooseText = localizeString(localizedStrings, '%webView_bookSelector_choose%');\n const chooseBooksText = localizeString(localizedStrings, '%webView_bookSelector_chooseBooks%');\n\n const [bookSelectionMode, setBookSelectionMode] = useState(\n BookSelectionMode.CURRENT_BOOK,\n );\n\n const onSelectionModeChange = (newMode: BookSelectionMode) => {\n setBookSelectionMode(newMode);\n handleBookSelectionModeChange(newMode);\n };\n\n return (\n onSelectionModeChange(value as BookSelectionMode)}\n >\n
    \n
    \n
    \n \n \n
    \n \n
    \n \n
    \n
    \n
    \n
    \n \n \n
    \n \n onSelectBooks()}\n >\n {chooseText}\n \n
    \n
    \n \n );\n}\n","import { DropdownMenuTrigger } from '@radix-ui/react-dropdown-menu';\nimport { FilterIcon } from 'lucide-react';\nimport { Table } from '@tanstack/react-table';\n\nimport { Button } from '@/components/shadcn-ui/button';\nimport {\n DropdownMenu,\n DropdownMenuCheckboxItem,\n DropdownMenuContent,\n DropdownMenuLabel,\n DropdownMenuSeparator,\n} from '@/components/shadcn-ui/dropdown-menu';\n\ninterface DataTableViewOptionsProps {\n table: Table;\n}\n\nfunction DataTableViewOptions({ table }: DataTableViewOptionsProps) {\n return (\n \n \n \n \n \n Toggle columns\n \n {table\n .getAllColumns()\n .filter((column) => column.getCanHide())\n .map((column) => {\n return (\n column.toggleVisibility(!!value)}\n >\n {column.id}\n \n );\n })}\n \n \n );\n}\n\nexport default DataTableViewOptions;\n","import React from 'react';\nimport * as SelectPrimitive from '@radix-ui/react-select';\nimport { Check, ChevronDown, ChevronUp } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Select = SelectPrimitive.Root;\n\nconst SelectGroup = SelectPrimitive.Group;\n\nconst SelectValue = SelectPrimitive.Value;\n\nconst SelectTrigger = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, ...props }, ref) => (\n span]:tw-line-clamp-1',\n className,\n )}\n {...props}\n >\n {children}\n \n \n \n \n));\nSelectTrigger.displayName = SelectPrimitive.Trigger.displayName;\n\nconst SelectScrollUpButton = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n));\nSelectScrollUpButton.displayName = SelectPrimitive.ScrollUpButton.displayName;\n\nconst SelectScrollDownButton = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n));\nSelectScrollDownButton.displayName = SelectPrimitive.ScrollDownButton.displayName;\n\nconst SelectContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, position = 'popper', ...props }, ref) => (\n \n \n \n \n {children}\n \n \n \n \n));\nSelectContent.displayName = SelectPrimitive.Content.displayName;\n\nconst SelectLabel = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSelectLabel.displayName = SelectPrimitive.Label.displayName;\n\nconst SelectItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, ...props }, ref) => (\n \n \n \n \n \n \n\n {children}\n \n));\nSelectItem.displayName = SelectPrimitive.Item.displayName;\n\nconst SelectSeparator = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSelectSeparator.displayName = SelectPrimitive.Separator.displayName;\n\nexport {\n Select,\n SelectGroup,\n SelectValue,\n SelectTrigger,\n SelectContent,\n SelectLabel,\n SelectItem,\n SelectSeparator,\n SelectScrollUpButton,\n SelectScrollDownButton,\n};\n","import { ChevronLeftIcon, ChevronRightIcon, ArrowLeftIcon, ArrowRightIcon } from 'lucide-react';\nimport { Table } from '@tanstack/react-table';\n\nimport { Button } from '@/components/shadcn-ui/button';\nimport {\n Select,\n SelectContent,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\n\ninterface DataTablePaginationProps {\n table: Table;\n}\n\nfunction DataTablePagination({ table }: DataTablePaginationProps) {\n return (\n
    \n
    \n
    \n {table.getFilteredSelectedRowModel().rows.length} of{' '}\n {table.getFilteredRowModel().rows.length} row(s) selected\n
    \n
    \n

    Rows per page

    \n {\n table.setPageSize(Number(value));\n }}\n >\n \n \n \n \n {[10, 20, 30, 40, 50].map((pageSize) => (\n \n {pageSize}\n \n ))}\n \n \n
    \n
    \n Page {table.getState().pagination.pageIndex + 1} of {table.getPageCount()}\n
    \n
    \n table.setPageIndex(0)}\n disabled={!table.getCanPreviousPage()}\n >\n Go to first page\n \n \n table.previousPage()}\n disabled={!table.getCanPreviousPage()}\n >\n Go to previous page\n \n \n table.nextPage()}\n disabled={!table.getCanNextPage()}\n >\n Go to next page\n \n \n table.setPageIndex(table.getPageCount() - 1)}\n disabled={!table.getCanNextPage()}\n >\n Go to last page\n \n \n
    \n
    \n
    \n );\n}\n\nexport default DataTablePagination;\n","import React from 'react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Table = React.forwardRef<\n HTMLTableElement,\n React.HTMLAttributes & { stickyHeader?: boolean }\n>(({ className, stickyHeader, ...props }, ref) => (\n
    \n \n
    \n));\nTable.displayName = 'Table';\n\nconst TableHeader = React.forwardRef<\n HTMLTableSectionElement,\n React.HTMLAttributes & { stickyHeader?: boolean }\n>(({ className, stickyHeader, ...props }, ref) => (\n \n));\nTableHeader.displayName = 'TableHeader';\n\nconst TableBody = React.forwardRef<\n HTMLTableSectionElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableBody.displayName = 'TableBody';\n\nconst TableFooter = React.forwardRef<\n HTMLTableSectionElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n tr]:last:tw-border-b-0', className)}\n {...props}\n />\n));\nTableFooter.displayName = 'TableFooter';\n\nconst TableRow = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nTableRow.displayName = 'TableRow';\n\nconst TableHead = React.forwardRef<\n HTMLTableCellElement,\n React.ThHTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableHead.displayName = 'TableHead';\n\nconst TableCell = React.forwardRef<\n HTMLTableCellElement,\n React.TdHTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableCell.displayName = 'TableCell';\n\nconst TableCaption = React.forwardRef<\n HTMLTableCaptionElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableCaption.displayName = 'TableCaption';\n\nexport { Table, TableHeader, TableBody, TableFooter, TableHead, TableRow, TableCell, TableCaption };\n","import { useState } from 'react';\n\nimport {\n ColumnFiltersState,\n flexRender,\n getCoreRowModel,\n getFilteredRowModel,\n getPaginationRowModel,\n getSortedRowModel,\n SortingState,\n ColumnDef as TSColumnDef,\n Row as TSRow,\n RowSelectionState as TSRowSelectionState,\n SortDirection as TSSortDirection,\n Table as TSTable,\n useReactTable,\n VisibilityState,\n} from '@tanstack/react-table';\n\nimport DataTableViewOptions from '@/components/advanced/data-table/data-table-column-toggle.component';\nimport DataTablePagination from '@/components/advanced/data-table/data-table-pagination.component';\nimport { Button } from '@/components/shadcn-ui/button';\nimport {\n Table,\n TableBody,\n TableCell,\n TableHead,\n TableHeader,\n TableRow,\n} from '@/components/shadcn-ui/table';\n\nexport type ColumnDef = TSColumnDef;\nexport type RowContents = TSRow;\nexport type TableContents = TSTable;\nexport type SortDirection = TSSortDirection;\nexport type RowSelectionState = TSRowSelectionState;\n\ninterface DataTableProps {\n columns: ColumnDef[];\n data: TData[];\n enablePagination?: boolean;\n showPaginationControls?: boolean;\n showColumnVisibilityControls?: boolean;\n stickyHeader?: boolean;\n onRowClickHandler?: (row: RowContents, table: TableContents) => void;\n}\n\n/**\n * Feature-rich table component that infuses our basic shadcn-based Table component with features\n * from TanStack's React Table library\n */\nfunction DataTable({\n columns,\n data,\n enablePagination = false,\n showPaginationControls = false,\n showColumnVisibilityControls = false,\n stickyHeader = false,\n onRowClickHandler = () => {},\n}: DataTableProps) {\n const [sorting, setSorting] = useState([]);\n const [columnFilters, setColumnFilters] = useState([]);\n const [columnVisibility, setColumnVisibility] = useState({});\n const [rowSelection, setRowSelection] = useState({});\n\n const table = useReactTable({\n data,\n columns,\n getCoreRowModel: getCoreRowModel(),\n ...(enablePagination && { getPaginationRowModel: getPaginationRowModel() }),\n onSortingChange: setSorting,\n getSortedRowModel: getSortedRowModel(),\n onColumnFiltersChange: setColumnFilters,\n getFilteredRowModel: getFilteredRowModel(),\n onColumnVisibilityChange: setColumnVisibility,\n onRowSelectionChange: setRowSelection,\n state: {\n sorting,\n columnFilters,\n columnVisibility,\n rowSelection,\n },\n });\n\n return (\n
    \n {showColumnVisibilityControls && }\n \n \n {table.getHeaderGroups().map((headerGroup) => (\n \n {headerGroup.headers.map((header) => {\n return (\n \n {header.isPlaceholder\n ? undefined\n : flexRender(header.column.columnDef.header, header.getContext())}\n \n );\n })}\n \n ))}\n \n \n {table.getRowModel().rows?.length ? (\n table.getRowModel().rows.map((row) => (\n onRowClickHandler(row, table)}\n key={row.id}\n data-state={row.getIsSelected() && 'selected'}\n >\n {row.getVisibleCells().map((cell) => (\n \n {flexRender(cell.column.columnDef.cell, cell.getContext())}\n \n ))}\n \n ))\n ) : (\n \n \n No results.\n \n \n )}\n \n
    \n {enablePagination && (\n
    \n table.previousPage()}\n disabled={!table.getCanPreviousPage()}\n >\n Previous\n \n table.nextPage()}\n disabled={!table.getCanNextPage()}\n >\n Next\n \n
    \n )}\n {enablePagination && showPaginationControls && }\n
    \n );\n}\n\nexport default DataTable;\n","import {\n Table,\n TableBody,\n TableCell,\n TableHead,\n TableHeader,\n TableRow,\n} from '@/components/shadcn-ui/table';\nimport { Canon } from '@sillsdev/scripture';\nimport { deepEqual, LanguageStrings, ScriptureReference } from 'platform-bible-utils';\nimport { useMemo } from 'react';\nimport { InventoryItemOccurrence } from './inventory-utils';\n\n/** Props for the OccurrencesTable component */\ntype OccurrencesTableProps = {\n /** Data that contains scriptures references and snippets of scripture */\n occurrenceData: InventoryItemOccurrence[];\n /** Callback function that is executed when the scripture reference is changed */\n setScriptureReference: (scriptureReference: ScriptureReference) => void;\n /**\n * Object with all localized strings that the OccurrencesTable needs to work well across multiple\n * languages\n */\n localizedStrings: LanguageStrings;\n};\n\n/**\n * Table that shows occurrences of specified inventory item(s). The first column shows the related\n * scripture reference. The second column shows the snippet of scripture that contains the specified\n * inventory item\n */\nfunction OccurrencesTable({\n occurrenceData,\n setScriptureReference,\n localizedStrings,\n}: OccurrencesTableProps) {\n const referenceHeaderText =\n localizedStrings['%webView_inventory_occurrences_table_header_reference%'];\n const occurrenceHeaderText =\n localizedStrings['%webView_inventory_occurrences_table_header_occurrence%'];\n\n const occurrences: InventoryItemOccurrence[] = useMemo(() => {\n const uniqueOccurrences: InventoryItemOccurrence[] = [];\n\n occurrenceData.forEach((occurrence) => {\n if (!uniqueOccurrences.some((uniqueOccurrence) => deepEqual(uniqueOccurrence, occurrence))) {\n uniqueOccurrences.push(occurrence);\n }\n });\n\n return uniqueOccurrences;\n }, [occurrenceData]);\n\n return (\n \n \n \n {referenceHeaderText}\n {occurrenceHeaderText}\n \n \n \n {occurrences.length > 0 &&\n occurrences.map((occurrence) => (\n {\n setScriptureReference(occurrence.reference);\n }}\n >\n {`${Canon.bookNumberToEnglishName(occurrence.reference.bookNum)} ${occurrence.reference.chapterNum}:${occurrence.reference.verseNum}`}\n {occurrence.text}\n \n ))}\n \n
    \n );\n}\n\nexport default OccurrencesTable;\n","import React from 'react';\nimport * as CheckboxPrimitive from '@radix-ui/react-checkbox';\nimport { Check } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Checkbox = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n \n \n));\nCheckbox.displayName = CheckboxPrimitive.Root.displayName;\n\nexport default Checkbox;\n","import { Canon } from '@sillsdev/scripture';\nimport { ScriptureReference } from 'platform-bible-utils';\n\n/* #region Types */\n\n/**\n * Status of items that appear in inventories. 'approved' and 'unapproved' items are defined in the\n * project's `Settings.xml`. All other items are defined as 'unknown'\n */\nexport type Status = 'approved' | 'unapproved' | 'unknown';\n\n/** Occurrence of item in inventory. Primarily used by table that shows occurrences */\nexport type InventoryItemOccurrence = {\n /** Reference to scripture where the item appears */\n reference: ScriptureReference;\n /** Snippet of scripture that contains the occurrence */\n text: string;\n};\n\n/** Data structure that contains all information on an item that is shown in an inventory */\nexport type InventoryTableData = {\n /**\n * The item (e.g. a character in the characters inventory, a marker in the marker inventory) In\n * most cases the array will only have one element. In case of additional items (e.g. the\n * preceding marker in the markers check), the primary item should be stored in the first index.\n * To show additional items in the inventory, make sure to configure the `additionalItemsLabels`\n * prop for the Inventory component\n */\n items: string[];\n /** The number of times this item occurs in the selected scope */\n count: number;\n /** The status of this item (see documentation for `Status` type for more information) */\n status: Status;\n /** Occurrences of this item in the scripture text for the selected scope */\n occurrences: InventoryItemOccurrence[];\n};\n\n/* #endregion */\n\n/* #region Functions */\n\n/**\n * Splits USFM string into shorter line-like segments\n *\n * @param text A single (likely very large) USFM string\n * @returns An array containing the input text, split into shorter segments\n */\nexport const getLinesFromUSFM = (text: string) => {\n // Splits on (CR)LF, CR, \\v, \\c and \\id\n return text.split(/(?:\\r?\\n|\\r)|(?=(?:\\\\(?:v|c|id)))/g);\n};\n\n/**\n * Extracts chapter or verse number from USFM strings that start with a \\c or \\v marker\n *\n * @param text USFM string that is expected to start with \\c or \\v marker\n * @returns Chapter or verse number if one is found. Else returns 0.\n */\nexport const getNumberFromUSFM = (text: string): number | undefined => {\n // Captures all digits that follow \\v or \\c markers followed by whitespace located at the start of a string\n const regex = /^\\\\[vc]\\s+(\\d+)/;\n const match = text.match(regex);\n\n if (match) {\n return +match[1];\n }\n return undefined;\n};\n\n/**\n * Gets book ID from USFM string that starts with the \\id marker, and returns book number for it\n *\n * @param text USFM string that is expected to start with \\id marker\n * @returns Book number corresponding to the \\id marker in the input text. Returns 0 if no marker is\n * found or the marker is not valid\n */\nexport const getBookNumFromId = (text: string): number => {\n // Captures all digits that follow an \\id marker followed by whitespace located at the start of a string\n const match = text.match(/^\\\\id\\s+([A-Za-z]+)/);\n if (match) {\n return Canon.bookIdToNumber(match[1]);\n }\n return 0;\n};\n\n/**\n * Gets the status for an item, typically used in the Inventory component\n *\n * @param item The item for which the status is being requested\n * @param approvedItems Array of approved items, typically as defined in `Settings.xml`\n * @param unapprovedItems Array of unapproved items, typically as defined in `Settings.xml`\n * @returns The status for the specified item\n */\nexport const getStatusForItem = (\n item: string,\n approvedItems: string[],\n unapprovedItems: string[],\n): Status => {\n if (unapprovedItems.includes(item)) return 'unapproved';\n if (approvedItems.includes(item)) return 'approved';\n return 'unknown';\n};\n\n/* #endregion */\n","import React from 'react';\nimport * as TogglePrimitive from '@radix-ui/react-toggle';\nimport { cva, type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst toggleVariants = cva(\n 'pr-twp tw-inline-flex tw-items-center tw-justify-center tw-rounded-md tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-colors hover:tw-bg-muted hover:tw-text-muted-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50 data-[state=on]:tw-bg-accent data-[state=on]:tw-text-accent-foreground',\n {\n variants: {\n variant: {\n default: 'tw-bg-transparent',\n outline:\n 'tw-border tw-border-input tw-bg-transparent hover:tw-bg-accent hover:tw-text-accent-foreground',\n },\n size: {\n default: 'tw-h-10 tw-px-3',\n sm: 'tw-h-9 tw-px-2.5',\n lg: 'tw-h-11 tw-px-5',\n },\n },\n defaultVariants: {\n variant: 'default',\n size: 'default',\n },\n },\n);\n\nconst Toggle = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef & VariantProps\n>(({ className, variant, size, ...props }, ref) => (\n \n));\n\nToggle.displayName = TogglePrimitive.Root.displayName;\n\nexport { Toggle, toggleVariants };\n","import React from 'react';\nimport * as ToggleGroupPrimitive from '@radix-ui/react-toggle-group';\nimport { type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { toggleVariants } from '@/components/shadcn-ui/toggle';\n\nconst ToggleGroupContext = React.createContext>({\n size: 'default',\n variant: 'default',\n});\n\nconst ToggleGroup = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef &\n VariantProps\n>(({ className, variant, size, children, ...props }, ref) => (\n \n \n {children}\n \n \n));\n\nToggleGroup.displayName = ToggleGroupPrimitive.Root.displayName;\n\nconst ToggleGroupItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef &\n VariantProps\n>(({ className, children, variant, size, ...props }, ref) => {\n const context = React.useContext(ToggleGroupContext);\n\n return (\n \n {children}\n \n );\n});\n\nToggleGroupItem.displayName = ToggleGroupPrimitive.Item.displayName;\n\nexport { ToggleGroup, ToggleGroupItem };\n","import { ColumnDef, SortDirection } from '@/components/advanced/data-table/data-table.component';\nimport { Button } from '@/components/shadcn-ui/button';\nimport { ToggleGroup, ToggleGroupItem } from '@/components/shadcn-ui/toggle-group';\nimport {\n ArrowDownIcon,\n ArrowUpDownIcon,\n ArrowUpIcon,\n CircleCheckIcon,\n CircleHelpIcon,\n CircleXIcon,\n} from 'lucide-react';\nimport { ReactNode } from 'react';\nimport { InventoryTableData, Status } from './inventory-utils';\n\n/**\n * Gets an icon that indicates the current sorting direction based on the provided input\n *\n * @param sortDirection Sorting direction. Can be ascending ('asc'), descending ('desc') or false (\n * i.e. not sorted)\n * @returns The appropriate sorting icon for the provided sorting direction\n */\nconst getSortingIcon = (sortDirection: false | SortDirection): ReactNode => {\n if (sortDirection === 'asc') {\n return ;\n }\n if (sortDirection === 'desc') {\n return ;\n }\n return ;\n};\n\n/**\n * Function that creates the item column for inventories\n *\n * @param itemLabel Localized label for the item column (e.g. 'Character', 'Repeated Word', etc.)\n * @returns Column that shows the inventory items. Should be used with the DataTable component\n */\nexport const inventoryItemColumn = (itemLabel: string): ColumnDef => {\n return {\n accessorKey: 'item',\n accessorFn: (row: InventoryTableData) => row.items[0],\n header: ({ column }) => (\n \n ),\n };\n};\n\n/**\n * Function that creates the additional item columns for inventories\n *\n * @param additionalItemLabel Localized label for the additional item column (e.g. 'Preceding\n * Marker')\n * @param additionalItemIndex Index that locates the desired item in the items array of the\n * inventory\n * @returns Column that shows additional inventory items. Should be used with the DataTable\n * component\n */\nexport const inventoryAdditionalItemColumn = (\n additionalItemLabel: string,\n additionalItemIndex: number,\n): ColumnDef => {\n return {\n accessorKey: `item${additionalItemIndex}`,\n accessorFn: (row: InventoryTableData) => row.items[additionalItemIndex],\n header: ({ column }) => (\n \n ),\n };\n};\n\n/**\n * Function that creates the count column for inventories. Should be used with the DataTable\n * component.\n *\n * @param itemLabel Localized label for the count column\n * @returns Column that shows the number of occurrences of the related inventory items\n */\nexport const inventoryCountColumn = (countLabel: string): ColumnDef => {\n return {\n accessorKey: 'count',\n header: ({ column }) => (\n
    \n \n
    \n ),\n cell: ({ row }) =>
    {row.getValue('count')}
    ,\n };\n};\n\n/**\n * Function that updates project settings when status for item(s) changes\n *\n * @param changedItems Array of items for which the status is being updated\n * @param newStatus The status that the items are being given\n * @param approvedItems Array of currently approved items\n * @param onApprovedItemsChange Callback function that stores the updated list of approved items\n * @param unapprovedItems Array of currently unapproved items\n * @param onUnapprovedItemsChange Callback function that stores the updated list of unapproved items\n */\nconst statusChangeHandler = (\n changedItems: string[],\n newStatus: Status,\n approvedItems: string[],\n onApprovedItemsChange: (items: string[]) => void,\n unapprovedItems: string[],\n onUnapprovedItemsChange: (items: string[]) => void,\n) => {\n let newApprovedItems: string[] = [...approvedItems];\n changedItems.forEach((item) => {\n if (newStatus === 'approved') {\n if (!newApprovedItems.includes(item)) {\n newApprovedItems.push(item);\n }\n } else {\n newApprovedItems = newApprovedItems.filter((validItem) => validItem !== item);\n }\n });\n onApprovedItemsChange(newApprovedItems);\n\n let newUnapprovedItems: string[] = [...unapprovedItems];\n changedItems.forEach((item) => {\n if (newStatus === 'unapproved') {\n if (!newUnapprovedItems.includes(item)) {\n newUnapprovedItems.push(item);\n }\n } else {\n newUnapprovedItems = newUnapprovedItems.filter((unapprovedItem) => unapprovedItem !== item);\n }\n });\n onUnapprovedItemsChange(newUnapprovedItems);\n};\n\n/**\n * Function that creates the status column for inventories. Should be used with the DataTable\n * component.\n *\n * @param statusLabel Localized label for the status column\n * @param approvedItems Array of approved items, typically as defined in `Settings.xml`\n * @param onApprovedItemsChange Callback function that stores the updated list of approved items\n * @param unapprovedItems Array of unapproved items, typically as defined in `Settings.xml`\n * @param onUnapprovedItemsChange Callback function that stores the updated list of unapproved items\n * @returns Column that shows the status buttons for the related inventory item. The button for the\n * current status of the item is selected\n */\nexport const inventoryStatusColumn = (\n statusLabel: string,\n approvedItems: string[],\n onApprovedItemsChange: (items: string[]) => void,\n unapprovedItems: string[],\n onUnapprovedItemsChange: (items: string[]) => void,\n): ColumnDef => {\n return {\n accessorKey: 'status',\n header: ({ column }) => {\n return (\n
    \n \n
    \n );\n },\n cell: ({ row }) => {\n const status: Status = row.getValue('status');\n const item: string = row.getValue('item');\n return (\n \n \n statusChangeHandler(\n [item],\n 'approved',\n approvedItems,\n onApprovedItemsChange,\n unapprovedItems,\n onUnapprovedItemsChange,\n )\n }\n value=\"approved\"\n >\n \n \n \n statusChangeHandler(\n [item],\n 'unapproved',\n approvedItems,\n onApprovedItemsChange,\n unapprovedItems,\n onUnapprovedItemsChange,\n )\n }\n value=\"unapproved\"\n >\n \n \n \n statusChangeHandler(\n [item],\n 'unknown',\n approvedItems,\n onApprovedItemsChange,\n unapprovedItems,\n onUnapprovedItemsChange,\n )\n }\n value=\"unknown\"\n >\n \n \n \n );\n },\n };\n};\n","import DataTable, {\n ColumnDef,\n RowContents,\n RowSelectionState,\n TableContents,\n} from '@/components/advanced/data-table/data-table.component';\nimport OccurrencesTable from '@/components/advanced/inventory/occurrences-table.component';\nimport Checkbox from '@/components/shadcn-ui/checkbox';\nimport { Input } from '@/components/shadcn-ui/input';\nimport { Label } from '@/components/shadcn-ui/label';\nimport {\n Select,\n SelectContent,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\nimport {\n deepEqual,\n LocalizedStringValue,\n ScriptureReference,\n substring,\n} from 'platform-bible-utils';\nimport { useEffect, useMemo, useState } from 'react';\nimport {\n getBookNumFromId,\n getLinesFromUSFM,\n getNumberFromUSFM,\n getStatusForItem,\n InventoryItemOccurrence,\n InventoryTableData,\n Status,\n} from './inventory-utils';\nimport { inventoryAdditionalItemColumn } from './inventory-columns';\n\n/**\n * Object containing all keys used for localization in this component. If you're using this\n * component in an extension, you can pass it into the useLocalizedStrings hook to easily obtain the\n * localized strings and pass them into the localizedStrings prop of this component\n */\nexport const INVENTORY_STRING_KEYS = Object.freeze([\n '%webView_inventory_all%',\n '%webView_inventory_approved%',\n '%webView_inventory_unapproved%',\n '%webView_inventory_unknown%',\n '%webView_inventory_scope_currentBook%',\n '%webView_inventory_scope_chapter%',\n '%webView_inventory_scope_verse%',\n '%webView_inventory_filter_text%',\n '%webView_inventory_show_additional_items%',\n '%webView_inventory_occurrences_table_header_reference%',\n '%webView_inventory_occurrences_table_header_occurrence%',\n] as const);\n\nexport type InventoryLocalizedStrings = {\n [localizedInventoryKey in (typeof INVENTORY_STRING_KEYS)[number]]?: LocalizedStringValue;\n};\n\n/** Scope of scripture that the inventory can operate on */\nexport type Scope = 'book' | 'chapter' | 'verse';\n\n/** Status values that the status filter can select from */\ntype StatusFilter = Status | 'all';\n\n/** Text labels for the inventory columns and the control components of additional inventory items */\ntype AdditionalItemsLabels = {\n checkboxText?: string;\n tableHeaders?: string[];\n};\n\n/**\n * Filters data that is shown in the DataTable section of the Inventory\n *\n * @param itemData All inventory items and their related information\n * @param statusFilter Allows filtering by status (i.e. show all items, or only items that are\n * 'approved', 'unapproved' or 'unknown')\n * @param textFilter Allows filtering by text. All items that include the filter text will be\n * selected.\n * @returns Array of items and their related information that are matched by the specified filters\n */\nconst filterItemData = (\n itemData: InventoryTableData[],\n statusFilter: StatusFilter,\n textFilter: string,\n): InventoryTableData[] => {\n let filteredItemData: InventoryTableData[] = itemData;\n\n if (statusFilter !== 'all') {\n filteredItemData = filteredItemData.filter(\n (item) =>\n (statusFilter === 'approved' && item.status === 'approved') ||\n (statusFilter === 'unapproved' && item.status === 'unapproved') ||\n (statusFilter === 'unknown' && item.status === 'unknown'),\n );\n }\n\n if (textFilter !== '')\n filteredItemData = filteredItemData.filter((item) => item.items[0].includes(textFilter));\n\n return filteredItemData;\n};\n\n/**\n * Turns array of strings into array of inventory items, along with their count and status\n *\n * @param text The source scripture text that is searched for inventory items\n * @param scriptureRef The scripture reference that the application is currently set to\n * @param approvedItems Array of approved items, typically as defined in `Settings.xml`\n * @param unapprovedItems Array of unapproved items, typically as defined in `Settings.xml`\n * @param itemRegex Regular expression that describes what items this Inventory should extract from\n * the provided scripture text\n * @returns Array of inventory items, along with their count and status\n */\nconst createTableData = (\n text: string | undefined,\n scriptureRef: ScriptureReference,\n approvedItems: string[],\n unapprovedItems: string[],\n itemRegex: RegExp,\n): InventoryTableData[] => {\n if (!text) return [];\n\n const tableData: InventoryTableData[] = [];\n\n let currentBook: number | undefined = scriptureRef.bookNum;\n let currentChapter: number | undefined = scriptureRef.chapterNum;\n let currentVerse: number | undefined = scriptureRef.verseNum;\n\n const lines = getLinesFromUSFM(text);\n\n lines.forEach((line: string) => {\n if (line.startsWith('\\\\id')) {\n currentBook = getBookNumFromId(line);\n currentChapter = 0;\n currentVerse = 0;\n }\n if (line.startsWith('\\\\c')) {\n currentChapter = getNumberFromUSFM(line);\n currentVerse = 0;\n }\n if (line.startsWith('\\\\v')) {\n currentVerse = getNumberFromUSFM(line);\n if (currentChapter === 0) {\n currentChapter = scriptureRef.chapterNum;\n }\n }\n\n let match: RegExpExecArray | undefined = itemRegex.exec(line) ?? undefined;\n while (match) {\n const items: string[] = [];\n match.forEach((item) => items.push(item));\n const itemIndex = match.index;\n const existingItem = tableData.find((tableEntry) => deepEqual(tableEntry.items, items));\n const newReference: InventoryItemOccurrence = {\n reference: {\n bookNum: currentBook !== undefined ? currentBook : -1,\n chapterNum: currentChapter !== undefined ? currentChapter : -1,\n verseNum: currentVerse !== undefined ? currentVerse : -1,\n },\n text: substring(line, Math.max(0, itemIndex - 25), Math.min(itemIndex + 25, line.length)),\n };\n if (existingItem) {\n existingItem.count += 1;\n existingItem.occurrences.push(newReference);\n } else {\n const newItem: InventoryTableData = {\n items,\n count: 1,\n status: getStatusForItem(items[0], approvedItems, unapprovedItems),\n occurrences: [newReference],\n };\n tableData.push(newItem);\n }\n\n match = itemRegex.exec(line) ?? undefined;\n }\n });\n\n return tableData;\n};\n\n/**\n * Gets the localized value for the provided key\n *\n * @param strings Object containing localized string\n * @param key Key for a localized string\n * @returns The localized value for the provided key, if available. Returns the key if no localized\n * value is available\n */\nconst localizeString = (\n strings: InventoryLocalizedStrings,\n key: keyof InventoryLocalizedStrings,\n) => {\n return strings[key] ?? key;\n};\n\n/** Props for the Inventory component */\ntype InventoryProps = {\n /** The scripture reference that the application is currently set to */\n scriptureReference: ScriptureReference;\n /** Callback function that is executed when the scripture reference is changed */\n setScriptureReference: (scriptureReference: ScriptureReference) => void;\n /**\n * Object with all localized strings that the Inventory needs to work well across multiple\n * languages. When using this component with Platform.Bible, you can import\n * `INVENTORY_STRING_KEYS` from this library, pass it in to the Platform's localization hook, and\n * pass the localized keys that are returned by the hook into this prop.\n */\n localizedStrings: InventoryLocalizedStrings;\n /**\n * The logic that finds the desired items in the source text. This can either be a Regular\n * expression that captures one or multiple items (preferred), or a custom function that builds\n * and return an InventoryDataTable[] manually. Note: In case the logic captures more than one\n * item (i.e. InventoryTableData.items has a length greater than 1), you must provide text labels\n * for the related columns and control elements to show by setting the `additionalItemsLabels`\n * prop\n */\n extractItems:\n | RegExp\n | ((\n text: string | undefined,\n scriptureRef: ScriptureReference,\n approvedItems: string[],\n unapprovedItems: string[],\n ) => InventoryTableData[]);\n /**\n * Text labels for control elements and additional column headers in case your Inventory has more\n * than one item to show (e.g. The 'Preceding Marker' in the Markers Inventory)\n */\n additionalItemsLabels?: AdditionalItemsLabels;\n /** Array of approved items, typically as defined in `Settings.xml` */\n approvedItems: string[];\n /** Array of unapproved items, typically as defined in `Settings.xml` */\n unapprovedItems: string[];\n /** The source scripture text that is searched for in inventory items */\n text: string | undefined;\n /** Scope of scripture that the inventory will operate on */\n scope: Scope;\n /** Callback function that is executed when the scope is changed from the Inventory */\n onScopeChange: (scope: Scope) => void;\n /**\n * Column definitions for the Inventory data table. The most commonly used column definitions are\n * pre-configured for your convenience and can be imported (e.g. inventoryItemColumn,\n * inventoryAdditionalItemColumn inventoryCountColumn, and inventoryStatusColumn). If you need any\n * other columns you can add these yourself\n */\n columns: ColumnDef[];\n};\n\n/** Inventory component that is used to view and control the status of provided project settings */\nexport default function Inventory({\n scriptureReference,\n setScriptureReference,\n localizedStrings,\n extractItems,\n additionalItemsLabels,\n approvedItems,\n unapprovedItems,\n text,\n scope,\n onScopeChange,\n columns,\n}: InventoryProps) {\n const allItemsText = localizeString(localizedStrings, '%webView_inventory_all%');\n const approvedItemsText = localizeString(localizedStrings, '%webView_inventory_approved%');\n const unapprovedItemsText = localizeString(localizedStrings, '%webView_inventory_unapproved%');\n const unknownItemsText = localizeString(localizedStrings, '%webView_inventory_unknown%');\n const scopeBookText = localizeString(localizedStrings, '%webView_inventory_scope_currentBook%');\n const scopeChapterText = localizeString(localizedStrings, '%webView_inventory_scope_chapter%');\n const scopeVerseText = localizeString(localizedStrings, '%webView_inventory_scope_verse%');\n const filterText = localizeString(localizedStrings, '%webView_inventory_filter_text%');\n const showAdditionalItemsText = localizeString(\n localizedStrings,\n '%webView_inventory_show_additional_items%',\n );\n\n const [showAdditionalItems, setShowAdditionalItems] = useState(false);\n const [statusFilter, setStatusFilter] = useState('all');\n const [textFilter, setTextFilter] = useState('');\n const [selectedItem, setSelectedItem] = useState([]);\n\n const tableData: InventoryTableData[] = useMemo(() => {\n if (!text) return [];\n if (extractItems instanceof RegExp)\n return createTableData(\n text,\n scriptureReference,\n approvedItems,\n unapprovedItems,\n extractItems,\n );\n return extractItems(text, scriptureReference, approvedItems, unapprovedItems);\n }, [text, extractItems, scriptureReference, approvedItems, unapprovedItems]);\n\n const reducedTableData: InventoryTableData[] = useMemo(() => {\n if (showAdditionalItems) return tableData;\n\n const newTableData: InventoryTableData[] = [];\n\n tableData.forEach((tableEntry) => {\n const firstItem = tableEntry.items[0];\n\n const existingEntry = newTableData.find(\n (newTableEntry) => newTableEntry.items[0] === firstItem,\n );\n\n if (existingEntry) {\n existingEntry.count += tableEntry.count;\n existingEntry.occurrences = existingEntry.occurrences.concat(tableEntry.occurrences);\n } else {\n newTableData.push({\n items: [firstItem],\n count: tableEntry.count,\n occurrences: tableEntry.occurrences,\n status: tableEntry.status,\n });\n }\n });\n\n return newTableData;\n }, [showAdditionalItems, tableData]);\n\n const filteredTableData: InventoryTableData[] = useMemo(() => {\n return filterItemData(reducedTableData, statusFilter, textFilter);\n }, [reducedTableData, statusFilter, textFilter]);\n\n const allColumns: ColumnDef[] = useMemo(() => {\n if (!showAdditionalItems) return columns;\n\n const numberOfAdditionalItems = additionalItemsLabels?.tableHeaders?.length;\n if (!numberOfAdditionalItems) return columns;\n\n const additionalColumns: ColumnDef[] = [];\n\n for (let index = 0; index < numberOfAdditionalItems; index++) {\n additionalColumns.push(\n inventoryAdditionalItemColumn(\n additionalItemsLabels?.tableHeaders?.[index] || 'Additional Item',\n index + 1,\n ),\n );\n }\n\n return [...additionalColumns, ...columns];\n }, [additionalItemsLabels?.tableHeaders, columns, showAdditionalItems]);\n\n useEffect(() => {\n setSelectedItem([]);\n }, [filteredTableData]);\n\n const rowClickHandler = (\n row: RowContents,\n table: TableContents,\n ) => {\n table.setRowSelection(() => {\n const newSelection: RowSelectionState = {};\n newSelection[row.index] = true;\n return newSelection;\n });\n\n setSelectedItem(row.original.items);\n };\n\n const handleScopeChange = (value: string) => {\n if (value === 'book' || value === 'chapter' || value === 'verse') {\n onScopeChange(value);\n } else {\n throw new Error(`Invalid scope value: ${value}`);\n }\n };\n\n const handleStatusFilterChange = (value: string) => {\n if (value === 'all' || value === 'approved' || value === 'unapproved' || value === 'unknown') {\n setStatusFilter(value);\n } else {\n throw new Error(`Invalid status filter value: ${value}`);\n }\n };\n\n const occurrenceData: InventoryItemOccurrence[] = useMemo(() => {\n if (reducedTableData.length === 0 || selectedItem.length === 0) return [];\n const occurrence = reducedTableData.filter((tableEntry: InventoryTableData) => {\n return deepEqual(\n showAdditionalItems ? tableEntry.items : [tableEntry.items[0]],\n selectedItem,\n );\n });\n if (occurrence.length > 1) throw new Error('Selected item is not unique');\n return occurrence[0].occurrences;\n }, [selectedItem, showAdditionalItems, reducedTableData]);\n\n return (\n
    \n
    \n handleStatusFilterChange(value)}\n defaultValue={statusFilter}\n >\n \n \n \n \n {allItemsText}\n {approvedItemsText}\n {unapprovedItemsText}\n {unknownItemsText}\n \n \n \n {\n setTextFilter(event.target.value);\n }}\n />\n {additionalItemsLabels && (\n
    \n {\n setSelectedItem([]);\n setShowAdditionalItems(checked);\n }}\n />\n \n
    \n )}\n
    \n
    \n \n
    \n {occurrenceData.length > 0 && (\n
    \n \n
    \n )}\n
    \n );\n}\n","import { Input } from '@/components/shadcn-ui/input';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { useState } from 'react';\n\nexport type SearchBarProps = {\n /**\n * Callback fired to handle the search query when button pressed\n *\n * @param searchQuery\n */\n onSearch: (searchQuery: string) => void;\n\n /** Optional string that appears in the search bar without a search string */\n placeholder?: string;\n\n /** Optional boolean to set the input base to full width */\n isFullWidth?: boolean;\n};\n\nexport default function SearchBar({ onSearch, placeholder, isFullWidth }: SearchBarProps) {\n const [searchQuery, setSearchQuery] = useState('');\n\n const handleInputChange = (searchString: string) => {\n setSearchQuery(searchString);\n onSearch(searchString);\n };\n\n return (\n handleInputChange(e.target.value)}\n />\n );\n}\n","// adapted from: https://github.com/shadcn-ui/ui/discussions/752\n\n'use client';\n\nimport { TabsContentProps, TabsListProps, TabsTriggerProps } from '@/components/shadcn-ui/tabs';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport * as TabsPrimitive from '@radix-ui/react-tabs';\nimport React from 'react';\n\nexport type VerticalTabsProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport type LeftTabsTriggerProps = TabsTriggerProps & {\n value: string;\n ref?: React.Ref;\n};\n\nexport const VerticalTabs = React.forwardRef<\n React.ElementRef,\n VerticalTabsProps\n>(({ className, ...props }, ref) => (\n \n));\n\nVerticalTabs.displayName = TabsPrimitive.List.displayName;\n\nexport const VerticalTabsList = React.forwardRef<\n React.ElementRef,\n TabsListProps\n>(({ className, ...props }, ref) => (\n \n));\nVerticalTabsList.displayName = TabsPrimitive.List.displayName;\n\nexport const VerticalTabsTrigger = React.forwardRef<\n React.ElementRef,\n LeftTabsTriggerProps\n>(({ className, ...props }, ref) => (\n \n));\n\nexport const VerticalTabsContent = React.forwardRef<\n React.ElementRef,\n TabsContentProps\n>(({ className, ...props }, ref) => (\n \n));\nVerticalTabsContent.displayName = TabsPrimitive.Content.displayName;\n","import SearchBar from '@/components/basics/search-bar.component';\nimport {\n VerticalTabs,\n VerticalTabsContent,\n VerticalTabsList,\n VerticalTabsTrigger,\n} from '@/components/basics/tabs-vertical';\nimport { ReactNode } from 'react';\n\nexport type TabKeyValueContent = {\n key: string;\n value: string;\n content: ReactNode;\n};\n\nexport type TabNavigationContentSearchProps = {\n /** List of values and keys for each tab this component should provide */\n tabList: TabKeyValueContent[];\n\n /** Handler to run when the value of the search bar changes */\n onSearch: (searchQuery: string) => void;\n\n /** Optional placeholder for the search bar */\n searchPlaceholder?: string;\n\n /** Optional title to include in the header */\n headerTitle?: string;\n\n /** Optional flag to make the search bar appear full width */\n isSearchBarFullWidth?: boolean;\n\n /** Text direction ltr or rtl */\n direction?: 'ltr' | 'rtl';\n};\n\nexport default function TabNavigationContentSearch({\n tabList,\n onSearch,\n searchPlaceholder,\n headerTitle,\n isSearchBarFullWidth = false,\n direction = 'ltr',\n}: TabNavigationContentSearchProps) {\n return (\n
    \n
    \n {headerTitle ?

    {headerTitle}

    : ''}\n \n
    \n \n \n {tabList.map((tab) => (\n \n {tab.value}\n \n ))}\n \n {tabList.map((tab) => (\n \n {tab.content}\n \n ))}\n \n
    \n );\n}\n","import React from 'react';\nimport * as SeparatorPrimitive from '@radix-ui/react-separator';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Separator = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, orientation = 'horizontal', decorative = true, ...props }, ref) => (\n \n));\nSeparator.displayName = SeparatorPrimitive.Root.displayName;\n\nexport { Separator };\n","'use client';\n\nimport * as React from 'react';\nimport * as SheetPrimitive from '@radix-ui/react-dialog';\nimport { cva, type VariantProps } from 'class-variance-authority';\nimport { X } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Sheet = SheetPrimitive.Root;\n\nconst SheetTrigger = SheetPrimitive.Trigger;\n\nconst SheetClose = SheetPrimitive.Close;\n\nconst SheetPortal = SheetPrimitive.Portal;\n\nconst SheetOverlay = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSheetOverlay.displayName = SheetPrimitive.Overlay.displayName;\n\nconst sheetVariants = cva(\n 'pr-twp tw-fixed tw-z-50 tw-gap-4 tw-bg-background tw-p-6 tw-shadow-lg tw-transition tw-ease-in-out data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-duration-300 data-[state=open]:tw-duration-500',\n {\n variants: {\n side: {\n top: 'tw-inset-x-0 tw-top-0 tw-border-b data-[state=closed]:tw-slide-out-to-top data-[state=open]:tw-slide-in-from-top',\n bottom:\n 'tw-inset-x-0 tw-bottom-0 tw-border-t data-[state=closed]:tw-slide-out-to-bottom data-[state=open]:tw-slide-in-from-bottom',\n left: 'tw-inset-y-0 tw-left-0 tw-h-full tw-w-3/4 tw-border-r data-[state=closed]:tw-slide-out-to-left data-[state=open]:tw-slide-in-from-left sm:tw-max-w-sm',\n right:\n 'tw-inset-y-0 tw-right-0 tw-h-full tw-w-3/4 tw- tw-border-l data-[state=closed]:tw-slide-out-to-right data-[state=open]:tw-slide-in-from-right sm:tw-max-w-sm',\n },\n },\n defaultVariants: {\n side: 'right',\n },\n },\n);\n\ninterface SheetContentProps\n extends React.ComponentPropsWithoutRef,\n VariantProps {}\n\nconst SheetContent = React.forwardRef<\n React.ElementRef,\n SheetContentProps\n>(({ side = 'right', className, children, ...props }, ref) => (\n \n \n \n {children}\n \n \n Close\n \n \n \n));\nSheetContent.displayName = SheetPrimitive.Content.displayName;\n\nfunction SheetHeader({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nSheetHeader.displayName = 'SheetHeader';\n\nfunction SheetFooter({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nSheetFooter.displayName = 'SheetFooter';\n\nconst SheetTitle = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSheetTitle.displayName = SheetPrimitive.Title.displayName;\n\nconst SheetDescription = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSheetDescription.displayName = SheetPrimitive.Description.displayName;\n\nexport {\n Sheet,\n SheetPortal,\n SheetOverlay,\n SheetTrigger,\n SheetClose,\n SheetContent,\n SheetHeader,\n SheetFooter,\n SheetTitle,\n SheetDescription,\n};\n","import React from 'react';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nfunction Skeleton({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\n\nexport { Skeleton };\n","import React from 'react';\nimport * as TooltipPrimitive from '@radix-ui/react-tooltip';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst TooltipProvider = TooltipPrimitive.Provider;\n\nconst Tooltip = TooltipPrimitive.Root;\n\nconst TooltipTrigger = TooltipPrimitive.Trigger;\n\nconst TooltipContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, sideOffset = 4, ...props }, ref) => (\n \n));\nTooltipContent.displayName = TooltipPrimitive.Content.displayName;\n\nexport { Tooltip, TooltipTrigger, TooltipContent, TooltipProvider };\n","import * as React from 'react';\n\nconst MOBILE_BREAKPOINT = 768;\n\nexport default function useIsMobile() {\n const [isMobile, setIsMobile] = React.useState(undefined);\n\n React.useEffect(() => {\n const mql = window.matchMedia(`(max-width: ${MOBILE_BREAKPOINT - 1}px)`);\n const onChange = () => {\n setIsMobile(window.innerWidth < MOBILE_BREAKPOINT);\n };\n mql.addEventListener('change', onChange);\n setIsMobile(window.innerWidth < MOBILE_BREAKPOINT);\n return () => mql.removeEventListener('change', onChange);\n }, []);\n\n return !!isMobile;\n}\n","import React from 'react';\nimport { Slot } from '@radix-ui/react-slot';\nimport { VariantProps, cva } from 'class-variance-authority';\nimport { PanelLeft } from 'lucide-react';\n\nimport { Button } from '@/components/shadcn-ui/button';\nimport { Input } from '@/components/shadcn-ui/input';\nimport { Separator } from '@/components/shadcn-ui/separator';\nimport { Sheet, SheetContent } from '@/components/shadcn-ui/sheet';\nimport { Skeleton } from '@/components/shadcn-ui/skeleton';\nimport {\n Tooltip,\n TooltipContent,\n TooltipProvider,\n TooltipTrigger,\n} from '@/components/shadcn-ui/tooltip';\nimport useIsMobile from '@/components/hooks/use-mobile';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst SIDEBAR_COOKIE_NAME = 'sidebar:state';\nconst SIDEBAR_COOKIE_MAX_AGE = 60 * 60 * 24 * 7;\nconst SIDEBAR_WIDTH = '16rem';\nconst SIDEBAR_WIDTH_MOBILE = '18rem';\nconst SIDEBAR_WIDTH_ICON = '3rem';\nconst SIDEBAR_KEYBOARD_SHORTCUT = 'b';\n\ntype SidebarContextProps = {\n state: 'expanded' | 'collapsed';\n open: boolean;\n setOpen: (open: boolean) => void;\n openMobile: boolean;\n setOpenMobile: (open: boolean) => void;\n isMobile: boolean;\n toggleSidebar: () => void;\n};\n\nconst SidebarContext = React.createContext(undefined);\n\nfunction useSidebar() {\n const context = React.useContext(SidebarContext);\n if (!context) {\n throw new Error('useSidebar must be used within a SidebarProvider.');\n }\n\n return context;\n}\n\nconst SidebarProvider = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & {\n defaultOpen?: boolean;\n open?: boolean;\n onOpenChange?: (open: boolean) => void;\n }\n>(\n (\n {\n defaultOpen = true,\n open: openProp,\n onOpenChange: setOpenProp,\n className,\n style,\n children,\n ...props\n },\n ref,\n ) => {\n const isMobile = useIsMobile();\n const [openMobile, setOpenMobile] = React.useState(false);\n\n // This is the internal state of the sidebar.\n // We use openProp and setOpenProp for control from outside the component.\n const [_open, _setOpen] = React.useState(defaultOpen);\n const isOpen = openProp ?? _open;\n const setOpen = React.useCallback(\n (value: boolean | ((value: boolean) => boolean)) => {\n const openState = typeof value === 'function' ? value(isOpen) : value;\n if (setOpenProp) {\n setOpenProp(openState);\n } else {\n _setOpen(openState);\n }\n\n // This sets the cookie to keep the sidebar state.\n document.cookie = `${SIDEBAR_COOKIE_NAME}=${openState}; path=/; max-age=${SIDEBAR_COOKIE_MAX_AGE}`;\n },\n [setOpenProp, isOpen],\n );\n\n // Helper to toggle the sidebar.\n const toggleSidebar = React.useCallback(() => {\n return isMobile ? setOpenMobile((open) => !open) : setOpen((open) => !open);\n }, [isMobile, setOpen, setOpenMobile]);\n\n // Adds a keyboard shortcut to toggle the sidebar.\n React.useEffect(() => {\n const handleKeyDown = (event: KeyboardEvent) => {\n if (event.key === SIDEBAR_KEYBOARD_SHORTCUT && (event.metaKey || event.ctrlKey)) {\n event.preventDefault();\n toggleSidebar();\n }\n };\n\n window.addEventListener('keydown', handleKeyDown);\n return () => window.removeEventListener('keydown', handleKeyDown);\n }, [toggleSidebar]);\n\n // We add a state so that we can do data-state=\"expanded\" or \"collapsed\".\n // This makes it easier to style the sidebar with Tailwind classes.\n const state = isOpen ? 'expanded' : 'collapsed';\n\n const contextValue = React.useMemo(\n () => ({\n state,\n open: isOpen,\n setOpen,\n isMobile,\n openMobile,\n setOpenMobile,\n toggleSidebar,\n }),\n [state, isOpen, setOpen, isMobile, openMobile, setOpenMobile, toggleSidebar],\n );\n\n return (\n \n \n \n {children}\n
    \n \n \n );\n },\n);\nSidebarProvider.displayName = 'SidebarProvider';\n\nconst Sidebar = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & {\n side?: 'left' | 'right';\n variant?: 'sidebar' | 'floating' | 'inset';\n collapsible?: 'offcanvas' | 'icon' | 'none';\n }\n>(\n (\n {\n side = 'left',\n variant = 'sidebar',\n collapsible = 'offcanvas',\n className,\n children,\n ...props\n },\n ref,\n ) => {\n const { isMobile, state, openMobile, setOpenMobile } = useSidebar();\n\n if (collapsible === 'none') {\n return (\n \n {children}\n
    \n );\n }\n\n if (isMobile) {\n return (\n \n button]:tw-hidden\"\n style={\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n {\n '--sidebar-width': SIDEBAR_WIDTH_MOBILE,\n } as React.CSSProperties\n }\n side={side}\n >\n
    {children}
    \n \n
    \n );\n }\n\n return (\n \n {/* This is what handles the sidebar gap on desktop */}\n \n \n \n {children}\n
    \n
    \n
    \n );\n },\n);\nSidebar.displayName = 'Sidebar';\n\nconst SidebarTrigger = React.forwardRef<\n React.ElementRef,\n React.ComponentProps\n>(({ className, onClick, ...props }, ref) => {\n const { toggleSidebar } = useSidebar();\n\n return (\n {\n onClick?.(event);\n toggleSidebar();\n }}\n {...props}\n >\n \n Toggle Sidebar\n \n );\n});\nSidebarTrigger.displayName = 'SidebarTrigger';\n\nconst SidebarRail = React.forwardRef>(\n ({ className, ...props }, ref) => {\n const { toggleSidebar } = useSidebar();\n\n return (\n \n );\n },\n);\nSidebarRail.displayName = 'SidebarRail';\n\nconst SidebarInset = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarInset.displayName = 'SidebarInset';\n\nconst SidebarInput = React.forwardRef<\n React.ElementRef,\n React.ComponentProps\n>(({ className, ...props }, ref) => {\n return (\n \n );\n});\nSidebarInput.displayName = 'SidebarInput';\n\nconst SidebarHeader = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarHeader.displayName = 'SidebarHeader';\n\nconst SidebarFooter = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarFooter.displayName = 'SidebarFooter';\n\nconst SidebarSeparator = React.forwardRef<\n React.ElementRef,\n React.ComponentProps\n>(({ className, ...props }, ref) => {\n return (\n \n );\n});\nSidebarSeparator.displayName = 'SidebarSeparator';\n\nconst SidebarContent = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarContent.displayName = 'SidebarContent';\n\nconst SidebarGroup = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarGroup.displayName = 'SidebarGroup';\n\nconst SidebarGroupLabel = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & { asChild?: boolean }\n>(({ className, asChild = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'div';\n\n return (\n svg]:tw-size-4 [&>svg]:tw-shrink-0',\n 'group-data-[collapsible=icon]:tw--mt-8 group-data-[collapsible=icon]:tw-opacity-0',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarGroupLabel.displayName = 'SidebarGroupLabel';\n\nconst SidebarGroupAction = React.forwardRef<\n HTMLButtonElement,\n React.ComponentProps<'button'> & { asChild?: boolean }\n>(({ className, asChild = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'button';\n\n return (\n svg]:tw-size-4 [&>svg]:tw-shrink-0',\n // Increases the hit area of the button on mobile.\n 'after:tw-absolute after:tw--inset-2 after:md:tw-hidden',\n 'group-data-[collapsible=icon]:tw-hidden',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarGroupAction.displayName = 'SidebarGroupAction';\n\nconst SidebarGroupContent = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarGroupContent.displayName = 'SidebarGroupContent';\n\nconst SidebarMenu = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenu.displayName = 'SidebarMenu';\n\nconst SidebarMenuItem = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenuItem.displayName = 'SidebarMenuItem';\n\nconst sidebarMenuButtonVariants = cva(\n 'tw-peer/menu-button tw-flex tw-w-full tw-items-center tw-gap-2 tw-overflow-hidden tw-rounded-md tw-p-2 tw-text-left tw-text-sm tw-outline-none tw-ring-sidebar-ring tw-transition-[width,height,padding] hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground focus-visible:tw-ring-2 active:tw-bg-sidebar-accent active:tw-text-sidebar-accent-foreground disabled:tw-pointer-events-none disabled:tw-opacity-50 tw-group-has-[[data-sidebar=menu-action]]/menu-item:pr-8 aria-disabled:tw-pointer-events-none aria-disabled:tw-opacity-50 data-[active=true]:tw-bg-sidebar-accent data-[active=true]:tw-font-medium data-[active=true]:tw-text-sidebar-accent-foreground data-[state=open]:hover:tw-bg-sidebar-accent data-[state=open]:hover:tw-text-sidebar-accent-foreground group-data-[collapsible=icon]:tw-!size-8 group-data-[collapsible=icon]:tw-!p-2 [&>span:last-child]:tw-truncate [&>svg]:tw-size-4 [&>svg]:tw-shrink-0',\n {\n variants: {\n variant: {\n default: 'hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground',\n outline:\n 'tw-bg-background tw-shadow-[0_0_0_1px_hsl(var(--sidebar-border))] hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground hover:tw-shadow-[0_0_0_1px_hsl(var(--sidebar-accent))]',\n },\n size: {\n default: 'tw-h-8 tw-text-sm',\n sm: 'tw-h-7 tw-text-xs',\n lg: 'tw-h-12 tw-text-sm group-data-[collapsible=icon]:tw-!p-0',\n },\n },\n defaultVariants: {\n variant: 'default',\n size: 'default',\n },\n },\n);\n\nconst SidebarMenuButton = React.forwardRef<\n HTMLButtonElement,\n React.ComponentProps<'button'> & {\n asChild?: boolean;\n isActive?: boolean;\n tooltip?: string | React.ComponentProps;\n } & VariantProps\n>(\n (\n {\n asChild = false,\n isActive = false,\n variant = 'default',\n size = 'default',\n tooltip,\n className,\n ...props\n },\n ref,\n ) => {\n const Comp = asChild ? Slot : 'button';\n const { isMobile, state } = useSidebar();\n\n const button = (\n \n );\n\n if (!tooltip) {\n return button;\n }\n\n if (typeof tooltip === 'string') {\n // eslint-disable-next-line no-param-reassign\n tooltip = {\n children: tooltip,\n };\n }\n\n return (\n \n {button}\n \n );\n },\n);\nSidebarMenuButton.displayName = 'SidebarMenuButton';\n\nconst SidebarMenuAction = React.forwardRef<\n HTMLButtonElement,\n React.ComponentProps<'button'> & {\n asChild?: boolean;\n showOnHover?: boolean;\n }\n>(({ className, asChild = false, showOnHover = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'button';\n\n return (\n svg]:tw-size-4 [&>svg]:tw-shrink-0',\n // Increases the hit area of the button on mobile.\n 'after:tw-absolute after:tw--inset-2 after:md:tw-hidden',\n 'tw-peer-data-[size=sm]/menu-button:top-1',\n 'tw-peer-data-[size=default]/menu-button:top-1.5',\n 'tw-peer-data-[size=lg]/menu-button:top-2.5',\n 'group-data-[collapsible=icon]:tw-hidden',\n showOnHover &&\n 'tw-group-focus-within/menu-item:opacity-100 tw-group-hover/menu-item:opacity-100 tw-peer-data-[active=true]/menu-button:text-sidebar-accent-foreground data-[state=open]:tw-opacity-100 md:tw-opacity-0',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarMenuAction.displayName = 'SidebarMenuAction';\n\nconst SidebarMenuBadge = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenuBadge.displayName = 'SidebarMenuBadge';\n\nconst SidebarMenuSkeleton = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & {\n showIcon?: boolean;\n }\n>(({ className, showIcon = false, ...props }, ref) => {\n // Random width between 50 to 90%.\n const width = React.useMemo(() => {\n return `${Math.floor(Math.random() * 40) + 50}%`;\n }, []);\n\n return (\n \n {showIcon && (\n \n )}\n \n
    \n );\n});\nSidebarMenuSkeleton.displayName = 'SidebarMenuSkeleton';\n\nconst SidebarMenuSub = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenuSub.displayName = 'SidebarMenuSub';\n\nconst SidebarMenuSubItem = React.forwardRef>(\n ({ ...props }, ref) =>
  • ,\n);\nSidebarMenuSubItem.displayName = 'SidebarMenuSubItem';\n\nconst SidebarMenuSubButton = React.forwardRef<\n HTMLAnchorElement,\n React.ComponentProps<'a'> & {\n asChild?: boolean;\n size?: 'sm' | 'md';\n isActive?: boolean;\n }\n>(({ asChild = false, size = 'md', isActive, className, ...props }, ref) => {\n const Comp = asChild ? Slot : 'a';\n\n return (\n span:last-child]:tw-truncate [&>svg]:tw-size-4 [&>svg]:tw-shrink-0 [&>svg]:tw-text-sidebar-accent-foreground',\n 'data-[active=true]:tw-bg-sidebar-accent data-[active=true]:tw-text-sidebar-accent-foreground',\n size === 'sm' && 'tw-text-xs',\n size === 'md' && 'tw-text-sm',\n 'group-data-[collapsible=icon]:tw-hidden',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarMenuSubButton.displayName = 'SidebarMenuSubButton';\n\nexport {\n Sidebar,\n SidebarContent,\n SidebarFooter,\n SidebarGroup,\n SidebarGroupAction,\n SidebarGroupContent,\n SidebarGroupLabel,\n SidebarHeader,\n SidebarInput,\n SidebarInset,\n SidebarMenu,\n SidebarMenuAction,\n SidebarMenuBadge,\n SidebarMenuButton,\n SidebarMenuItem,\n SidebarMenuSkeleton,\n SidebarMenuSub,\n SidebarMenuSubButton,\n SidebarMenuSubItem,\n SidebarProvider,\n SidebarRail,\n SidebarSeparator,\n SidebarTrigger,\n useSidebar,\n};\n","import { useState } from 'react';\nimport {\n Sidebar,\n SidebarContent,\n SidebarGroup,\n SidebarGroupLabel,\n SidebarGroupContent,\n SidebarMenu,\n SidebarMenuItem,\n SidebarMenuButton,\n} from '../../shadcn-ui/sidebar';\n\nexport type SettingsSidebarProps = {\n /** Optional id */\n id?: string;\n\n /** Extension labels to list in sidebar */\n extensionLabels: string[];\n\n /** Project labels to list in sidebar */\n // projectLabels: string[];\n\n handleSelectSidebarItem: (key: string, isProjectSetting: boolean) => void;\n};\n\nexport default function SettingsSidebar({\n id,\n extensionLabels,\n // projectLabels,\n handleSelectSidebarItem,\n}: SettingsSidebarProps) {\n const [selectedItem, setSelectedItem] = useState();\n\n const handleSelectItem = (item: string, isProjectSetting: boolean) => {\n setSelectedItem(item);\n handleSelectSidebarItem(item, isProjectSetting);\n };\n\n return (\n \n \n \n Extensions\n \n \n {extensionLabels.map((label) => (\n \n handleSelectItem(label, false)}\n isActive={label === selectedItem}\n >\n {label}\n \n \n ))}\n \n \n \n\n {/* \n Projects\n \n \n {projectLabels.map((label) => (\n \n handleSelectItem(label)}\n isActive={label === selectedItem}\n >\n {label}\n \n \n ))}\n \n \n */}\n \n \n );\n}\n","import { SidebarInset, SidebarProvider } from '@/components/shadcn-ui/sidebar';\n// import { ProjectSettingProperties, SettingProperties } from 'platform-bible-utils';\nimport { PropsWithChildren } from 'react';\nimport SettingsSidebar from './settings-sidebar.component';\n\nexport type SettingsSidebarContentSearchProps = {\n /** Text direction ltr or rtl */\n direction?: 'ltr' | 'rtl';\n\n extensionLabels: string[];\n // projectLabels: string[];\n handleSelectSidebarItem: (key: string, isProjectSetting: boolean) => void;\n // renderSettingsProperties: (extension: string) => SettingProperties;\n // renderProjectSettingsProperties: (project: string) => ProjectSettingProperties;\n} & PropsWithChildren;\n\nexport default function SettingsSidebarContentSearch({\n direction = 'ltr',\n extensionLabels,\n // projectLabels,\n children,\n handleSelectSidebarItem,\n // renderSettingsProperties,\n // renderProjectSettingsProperties.\n}: SettingsSidebarContentSearchProps) {\n return (\n \n \n {children}\n \n );\n}\n","import { Button } from '@/components/shadcn-ui/button';\nimport {\n Select,\n SelectContent,\n SelectGroup,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\nimport {\n Table,\n TableBody,\n TableCell,\n TableHead,\n TableHeader,\n TableRow,\n} from '@/components/shadcn-ui/table';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Canon } from '@sillsdev/scripture';\nimport {\n Cell,\n ColumnDef,\n flexRender,\n getCoreRowModel,\n getExpandedRowModel,\n getGroupedRowModel,\n getSortedRowModel,\n GroupingState,\n Row,\n RowSelectionState,\n SortingState,\n useReactTable,\n} from '@tanstack/react-table';\nimport '@/components/advanced/scripture-results-viewer/scripture-results-viewer.component.css';\nimport {\n compareScrRefs,\n formatScrRef,\n ScriptureSelection,\n scrRefToBBBCCCVVV,\n} from 'platform-bible-utils';\nimport { MouseEvent, useEffect, useMemo, useState } from 'react';\nimport { ChevronDown, ChevronLeft, ChevronRight } from 'lucide-react';\n\n/**\n * Information (e.g., a checking error or some other type of \"transient\" annotation) about something\n * noteworthy at a specific place in an instance of the Scriptures.\n */\nexport type ScriptureItemDetail = ScriptureSelection & {\n /**\n * Text of the error, note, etc. In the future, we might want to support something more than just\n * text so that a JSX element could be provided with a link or some other controls related to the\n * issue being reported.\n */\n detail: string;\n};\n\n/**\n * A uniquely identifiable source of results that can be displayed in the ScriptureResultsViewer.\n * Generally, the source will be a particular Scripture check, but there may be other types of\n * sources.\n */\nexport type ResultsSource = {\n /**\n * Uniquely identifies the source.\n *\n * @type {string}\n */\n id: string;\n\n /**\n * Name (potentially localized) of the source, suitable for display in the UI.\n *\n * @type {string}\n */\n displayName: string;\n};\n\nexport type ScriptureSrcItemDetail = ScriptureItemDetail & {\n /** Source/type of detail. Can be used for grouping. */\n source: ResultsSource;\n};\n\n/**\n * Represents a set of results keyed by Scripture reference. Generally, the source will be a\n * particular Scripture check, but this type also allows for other types of uniquely identifiable\n * sources.\n */\nexport type ResultsSet = {\n /**\n * The backing source associated with this set of results.\n *\n * @type {ResultsSource}\n */\n source: ResultsSource;\n\n /**\n * Array of Scripture item details (messages keyed by Scripture reference).\n *\n * @type {ScriptureItemDetail[]}\n */\n data: ScriptureItemDetail[];\n};\n\nconst scrBookColId = 'scrBook';\nconst scrRefColId = 'scrRef';\nconst typeColId = 'source';\nconst detailsColId = 'details';\n\nconst defaultScrRefColumnName = 'Scripture Reference';\nconst defaultScrBookGroupName = 'Scripture Book';\nconst defaultTypeColumnName = 'Type';\nconst defaultDetailsColumnName = 'Details';\n\nexport type ScriptureResultsViewerColumnInfo = {\n /** Optional header to display for the Reference column. Default value: 'Scripture Reference'. */\n scriptureReferenceColumnName?: string;\n\n /** Optional text to display to refer to the Scripture book group. Default value: 'Scripture Book'. */\n scriptureBookGroupName?: string;\n\n /** Optional header to display for the Type column. Default value: 'Type'. */\n typeColumnName?: string;\n\n /** Optional header to display for the Details column. Default value: 'Details' */\n detailsColumnName?: string;\n};\n\nexport type ScriptureResultsViewerProps = ScriptureResultsViewerColumnInfo & {\n /** Groups of ScriptureItemDetail objects from particular sources (e.g., Scripture checks) */\n sources: ResultsSet[];\n\n /** Flag indicating whether to display column headers. Default is false. */\n showColumnHeaders?: boolean;\n\n /** Flag indicating whether to display source column. Default is false. */\n showSourceColumn?: boolean;\n\n /** Callback function to notify when a row is selected */\n onRowSelected?: (selectedRow: ScriptureSrcItemDetail | undefined) => void;\n\n /** Text direction ltr or rtl */\n direction?: 'ltr' | 'rtl';\n};\n\nfunction getColumns(\n colInfo?: ScriptureResultsViewerColumnInfo,\n showSourceColumn?: boolean,\n): ColumnDef[] {\n const showSrcCol = showSourceColumn ?? false;\n return [\n {\n accessorFn: (row) =>\n `${Canon.bookNumberToId(row.start.bookNum)} ${row.start.chapterNum}:${row.start.verseNum}`,\n id: scrBookColId,\n header: colInfo?.scriptureReferenceColumnName ?? defaultScrRefColumnName,\n cell: (info) => {\n const row = info.row.original;\n if (info.row.getIsGrouped()) {\n return Canon.bookNumberToEnglishName(row.start.bookNum);\n }\n return info.row.groupingColumnId === scrBookColId ? formatScrRef(row.start) : undefined;\n },\n getGroupingValue: (row) => row.start.bookNum,\n sortingFn: (a, b) => {\n return compareScrRefs(a.original.start, b.original.start);\n },\n enableGrouping: true,\n },\n {\n accessorFn: (row) => formatScrRef(row.start),\n id: scrRefColId,\n header: undefined,\n cell: (info) => {\n const row = info.row.original;\n return info.row.getIsGrouped() ? undefined : formatScrRef(row.start);\n },\n sortingFn: (a, b) => {\n return compareScrRefs(a.original.start, b.original.start);\n },\n enableGrouping: false,\n },\n {\n accessorFn: (row) => row.source.displayName,\n id: typeColId,\n header: showSrcCol ? (colInfo?.typeColumnName ?? defaultTypeColumnName) : undefined,\n cell: (info) => (showSrcCol || info.row.getIsGrouped() ? info.getValue() : undefined),\n getGroupingValue: (row) => row.source.id,\n sortingFn: (a, b) =>\n a.original.source.displayName.localeCompare(b.original.source.displayName),\n enableGrouping: true,\n },\n {\n accessorFn: (row) => row.detail,\n id: detailsColId,\n header: colInfo?.detailsColumnName ?? defaultDetailsColumnName,\n cell: (info) => info.getValue(),\n enableGrouping: false,\n },\n ];\n}\n\nconst toRefOrRange = (scriptureSelection: ScriptureSelection) => {\n if (!('offset' in scriptureSelection.start))\n throw new Error('No offset available in range start');\n if (scriptureSelection.end && !('offset' in scriptureSelection.end))\n throw new Error('No offset available in range end');\n const { offset: offsetStart } = scriptureSelection.start;\n let offsetEnd: number = 0;\n if (scriptureSelection.end) ({ offset: offsetEnd } = scriptureSelection.end);\n if (\n !scriptureSelection.end ||\n compareScrRefs(scriptureSelection.start, scriptureSelection.end) === 0\n )\n return `${scrRefToBBBCCCVVV(scriptureSelection.start)}+${offsetStart}`;\n return `${scrRefToBBBCCCVVV(scriptureSelection.start)}+${offsetStart}-${scrRefToBBBCCCVVV(scriptureSelection.end)}+${offsetEnd}`;\n};\n\nconst getRowKey = (row: ScriptureSrcItemDetail) =>\n `${toRefOrRange({ start: row.start, end: row.end })} ${row.source.displayName} ${row.detail}`;\n\n/**\n * Component to display a combined list of detailed items from one or more sources, where the items\n * are keyed primarily by Scripture reference. This is particularly useful for displaying a list of\n * results from Scripture checks, but more generally could be used to display any \"results\" from any\n * source(s). The component allows for grouping by Scripture book, source, or both. By default, it\n * displays somewhat \"tree-like\" which allows it to be more horizontally compact and intuitive. But\n * it also has the option of displaying as a traditional table with column headings (with or without\n * the source column showing).\n */\nexport default function ScriptureResultsViewer({\n sources,\n showColumnHeaders = false,\n showSourceColumn = false,\n scriptureReferenceColumnName,\n scriptureBookGroupName,\n typeColumnName,\n detailsColumnName,\n onRowSelected,\n direction = 'ltr',\n}: ScriptureResultsViewerProps) {\n const [grouping, setGrouping] = useState([]);\n const [sorting, setSorting] = useState([{ id: scrBookColId, desc: false }]);\n const [rowSelection, setRowSelection] = useState({});\n\n const scriptureResults = useMemo(\n () =>\n sources.flatMap((source) => {\n return source.data.map((item) => ({\n ...item,\n source: source.source,\n }));\n }),\n [sources],\n );\n\n const columns = useMemo(\n () =>\n getColumns(\n {\n scriptureReferenceColumnName,\n typeColumnName,\n detailsColumnName,\n },\n showSourceColumn,\n ),\n [scriptureReferenceColumnName, typeColumnName, detailsColumnName, showSourceColumn],\n );\n\n useEffect(() => {\n // Ensure sorting is applied correctly when grouped by type\n if (grouping.includes(typeColId)) {\n setSorting([\n { id: typeColId, desc: false },\n { id: scrBookColId, desc: false },\n ]);\n } else {\n setSorting([{ id: scrBookColId, desc: false }]);\n }\n }, [grouping]);\n\n const table = useReactTable({\n data: scriptureResults,\n columns,\n state: {\n grouping,\n sorting,\n rowSelection,\n },\n onGroupingChange: setGrouping,\n onSortingChange: setSorting,\n onRowSelectionChange: setRowSelection,\n getExpandedRowModel: getExpandedRowModel(),\n getGroupedRowModel: getGroupedRowModel(),\n getCoreRowModel: getCoreRowModel(),\n getSortedRowModel: getSortedRowModel(),\n getRowId: getRowKey,\n autoResetExpanded: false,\n enableMultiRowSelection: false,\n enableSubRowSelection: false,\n });\n\n useEffect(() => {\n if (onRowSelected) {\n const selectedRows = table.getSelectedRowModel().rowsById;\n const keys = Object.keys(selectedRows);\n if (keys.length === 1) {\n const selectedRow = scriptureResults.find((row) => getRowKey(row) === keys[0]) || undefined;\n if (selectedRow) onRowSelected(selectedRow);\n }\n }\n }, [rowSelection, scriptureResults, onRowSelected, table]);\n\n // Define possible grouping options\n const scrBookGroupName = scriptureBookGroupName ?? defaultScrBookGroupName;\n const typeGroupName = typeColumnName ?? defaultTypeColumnName;\n\n const groupingOptions = [\n { label: 'No Grouping', value: [] },\n { label: `Group by ${scrBookGroupName}`, value: [scrBookColId] },\n { label: `Group by ${typeGroupName}`, value: [typeColId] },\n {\n label: `Group by ${scrBookGroupName} and ${typeGroupName}`,\n value: [scrBookColId, typeColId],\n },\n {\n label: `Group by ${typeGroupName} and ${scrBookGroupName}`,\n value: [typeColId, scrBookColId],\n },\n ];\n\n const handleSelectChange = (selectedGrouping: string) => {\n setGrouping(JSON.parse(selectedGrouping));\n };\n\n const handleRowClick = (row: Row, event: MouseEvent) => {\n if (!row.getIsGrouped() && !row.getIsSelected()) {\n row.getToggleSelectedHandler()(event);\n }\n };\n\n const getEvenOrOddBandingStyle = (row: Row, index: number) => {\n if (row.getIsGrouped()) return '';\n // UX has now said they don't think they want banding. I'm leaving in the code to\n // set even and odd styles, but there's nothing in the CSS to style them differently.\n // The \"even\" style used to also have tw-bg-neutral-300 (along with even) to create\n // a visual banding effect. That could be added back in if UX changes the decision.\n return cn('banded-row', index % 2 === 0 ? 'even' : 'odd');\n };\n\n const getIndent = (\n groupingState: GroupingState,\n row: Row,\n cell: Cell,\n ) => {\n if (groupingState?.length === 0 || row.depth < cell.column.getGroupedIndex()) return undefined;\n if (row.getIsGrouped()) {\n switch (row.depth) {\n case 1:\n return 'tw-ps-4';\n default:\n return undefined;\n }\n }\n switch (row.depth) {\n case 1:\n return 'tw-ps-8';\n case 2:\n return 'tw-ps-12';\n default:\n return undefined;\n }\n };\n\n return (\n
    \n {!showColumnHeaders && (\n {\n handleSelectChange(value);\n }}\n >\n \n \n \n \n \n {groupingOptions.map((option) => (\n \n {option.label}\n \n ))}\n \n \n \n )}\n \n {showColumnHeaders && (\n \n {table.getHeaderGroups().map((headerGroup) => (\n \n {headerGroup.headers\n .filter((h) => h.column.columnDef.header)\n .map((header) => (\n /* For sticky column headers to work, we probably need to change the default definition of the shadcn Table component. See https://github.com/shadcn-ui/ui/issues/1151 */\n \n {header.isPlaceholder ? undefined : (\n
    \n {header.column.getCanGroup() ? (\n \n {header.column.getIsGrouped() ? `🛑` : `👊 `}\n \n ) : undefined}{' '}\n {flexRender(header.column.columnDef.header, header.getContext())}\n
    \n )}\n
    \n ))}\n
    \n ))}\n
    \n )}\n \n {table.getRowModel().rows.map((row, rowIndex) => {\n return (\n handleRowClick(row, event)}\n >\n {row.getVisibleCells().map((cell) => {\n if (\n cell.getIsPlaceholder() ||\n (cell.column.columnDef.enableGrouping &&\n !cell.getIsGrouped() &&\n (cell.column.columnDef.id !== typeColId || !showSourceColumn))\n )\n return undefined;\n return (\n \n {(() => {\n if (cell.getIsGrouped()) {\n return (\n \n {row.getIsExpanded() && }\n {!row.getIsExpanded() &&\n (direction === 'ltr' ? : )}{' '}\n {flexRender(cell.column.columnDef.cell, cell.getContext())} (\n {row.subRows.length})\n \n );\n }\n\n // if (cell.getIsAggregated()) {\n // flexRender(\n // cell.column.columnDef.aggregatedCell ?? cell.column.columnDef.cell,\n // cell.getContext(),\n // );\n // }\n\n return flexRender(cell.column.columnDef.cell, cell.getContext());\n })()}\n \n );\n })}\n \n );\n })}\n \n
    \n
    \n );\n}\n","import {\n getLocalizeKeyForScrollGroupId,\n LanguageStrings,\n ScrollGroupId,\n} from 'platform-bible-utils';\nimport {\n Select,\n SelectContent,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\n\nconst DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS = {\n [getLocalizeKeyForScrollGroupId('undefined')]: 'Ø',\n [getLocalizeKeyForScrollGroupId(0)]: 'A',\n [getLocalizeKeyForScrollGroupId(1)]: 'B',\n [getLocalizeKeyForScrollGroupId(2)]: 'C',\n [getLocalizeKeyForScrollGroupId(3)]: 'D',\n [getLocalizeKeyForScrollGroupId(4)]: 'E',\n [getLocalizeKeyForScrollGroupId(5)]: 'F',\n [getLocalizeKeyForScrollGroupId(6)]: 'G',\n [getLocalizeKeyForScrollGroupId(7)]: 'H',\n [getLocalizeKeyForScrollGroupId(8)]: 'I',\n [getLocalizeKeyForScrollGroupId(9)]: 'J',\n [getLocalizeKeyForScrollGroupId(10)]: 'K',\n [getLocalizeKeyForScrollGroupId(11)]: 'L',\n [getLocalizeKeyForScrollGroupId(12)]: 'M',\n [getLocalizeKeyForScrollGroupId(13)]: 'N',\n [getLocalizeKeyForScrollGroupId(14)]: 'O',\n [getLocalizeKeyForScrollGroupId(15)]: 'P',\n [getLocalizeKeyForScrollGroupId(16)]: 'Q',\n [getLocalizeKeyForScrollGroupId(17)]: 'R',\n [getLocalizeKeyForScrollGroupId(18)]: 'S',\n [getLocalizeKeyForScrollGroupId(19)]: 'T',\n [getLocalizeKeyForScrollGroupId(20)]: 'U',\n [getLocalizeKeyForScrollGroupId(21)]: 'V',\n [getLocalizeKeyForScrollGroupId(22)]: 'W',\n [getLocalizeKeyForScrollGroupId(23)]: 'X',\n [getLocalizeKeyForScrollGroupId(24)]: 'Y',\n [getLocalizeKeyForScrollGroupId(25)]: 'Z',\n};\n\nexport type ScrollGroupSelectorProps = {\n /**\n * List of scroll group ids to show to the user. Either a {@link ScrollGroupId} or `undefined` for\n * no scroll group\n */\n availableScrollGroupIds: (ScrollGroupId | undefined)[];\n /** Currently selected scroll group id. `undefined` for no scroll group */\n scrollGroupId: ScrollGroupId | undefined;\n /** Callback function run when the user tries to change the scroll group id */\n onChangeScrollGroupId: (newScrollGroupId: ScrollGroupId | undefined) => void;\n /**\n * Localized strings to use for displaying scroll group ids. Must be an object whose keys are\n * `getLocalizeKeyForScrollGroupId(scrollGroupId)` for all scroll group ids (and `undefined` if\n * included) in {@link ScrollGroupSelectorProps.availableScrollGroupIds} and whose values are the\n * localized strings to use for those scroll group ids.\n *\n * Defaults to English localizations of English alphabet for scroll groups 0-25 (e.g. 0 is A) and\n * Ø for `undefined`. Will fill in any that are not provided with these English localizations.\n * Also, if any values match the keys, the English localization will be used. This is useful in\n * case you want to pass in a temporary version of the localized strings while your localized\n * strings load.\n *\n * @example\n *\n * ```typescript\n * const myScrollGroupIdLocalizedStrings = {\n * [getLocalizeKeyForScrollGroupId('undefined')]: 'Ø',\n * [getLocalizeKeyForScrollGroupId(0)]: 'A',\n * [getLocalizeKeyForScrollGroupId(1)]: 'B',\n * [getLocalizeKeyForScrollGroupId(2)]: 'C',\n * [getLocalizeKeyForScrollGroupId(3)]: 'D',\n * [getLocalizeKeyForScrollGroupId(4)]: 'E',\n * };\n * ```\n *\n * @example\n *\n * ```tsx\n * const availableScrollGroupIds = [undefined, 0, 1, 2, 3, 4];\n *\n * const localizeKeys = getLocalizeKeysForScrollGroupIds();\n *\n * const [localizedStrings] = useLocalizedStrings(localizeKeys);\n *\n * ...\n *\n * \n * ```\n */\n localizedStrings?: LanguageStrings;\n};\n\n/** Selector component for choosing a scroll group */\nexport default function ScrollGroupSelector({\n availableScrollGroupIds,\n scrollGroupId,\n onChangeScrollGroupId,\n localizedStrings = {},\n}: ScrollGroupSelectorProps) {\n const localizedStringsDefaulted = {\n ...DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS,\n ...Object.fromEntries(\n Object.entries(localizedStrings).map(\n ([localizedStringKey, localizedStringValue]: [string, string]) => [\n localizedStringKey,\n localizedStringKey === localizedStringValue &&\n localizedStringKey in DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS\n ? DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS[localizedStringKey]\n : localizedStringValue,\n ],\n ),\n ),\n };\n return (\n \n onChangeScrollGroupId(\n newScrollGroupString === 'undefined' ? undefined : parseInt(newScrollGroupString, 10),\n )\n }\n >\n \n \n \n \n {availableScrollGroupIds.map((scrollGroupOptionId) => (\n \n {localizedStringsDefaulted[getLocalizeKeyForScrollGroupId(scrollGroupOptionId)]}\n \n ))}\n \n \n );\n}\n","import { PropsWithChildren } from 'react';\nimport { Separator } from '@/components/shadcn-ui/separator';\n\n/** Props for the SettingsList component, currently just children */\ntype SettingsListProps = PropsWithChildren;\n\n/**\n * SettingsList component is a wrapper for list items. Rendered with a formatted div\n *\n * @param children To populate the list with\n * @returns Formatted div encompassing the children\n */\nexport function SettingsList({ children }: SettingsListProps) {\n return
    {children}
    ;\n}\n\n/** Props for SettingsListItem component */\ntype SettingsListItemProps = PropsWithChildren & {\n /** Primary text of the list item */\n primary: string;\n\n /** Optional text of the list item */\n secondary?: string | undefined;\n\n /** Optional boolean to display a message if the children aren't loaded yet. Defaults to false */\n isLoading?: boolean;\n\n /** Optional message to display if isLoading */\n loadingMessage?: string;\n};\n\n/**\n * SettingsListItem component is a common list item. Rendered with a formatted div\n *\n * @param primary Primary text of the list item\n * @param secondary Optional secondary text of the list item\n * @param isLoading Optional, to display a message if the action component isn't generated yet,\n * defaults to false\n * @param children The action component(s) to provide for this item\n * @param loadingMessage Optional, message to display if isLoading\n * @returns Formatted div encompassing the list item content\n */\nexport function SettingsListItem({\n primary,\n secondary,\n children,\n isLoading = false,\n loadingMessage,\n}: SettingsListItemProps) {\n return (\n
    \n
    \n

    {primary}

    \n

    \n {secondary}\n

    \n
    \n\n {isLoading ? (\n

    {loadingMessage}

    \n ) : (\n
    {children}
    \n )}\n
    \n );\n}\n\n/** Props for SettingsListHeader component */\ntype SettingsListHeaderProps = {\n /** The primary text of the list header */\n primary: string;\n\n /** Optional secondary text of the list header */\n secondary?: string | undefined;\n\n /** Optional boolean to include a separator underneath the secondary text. Defaults to false */\n includeSeparator?: boolean;\n};\n\n/**\n * SettingsListHeader component displays text above the list\n *\n * @param primary The primary text of the list header\n * @param secondary Optional secondary text of the list header\n * @param includeSeparator Optional boolean to include a separator underneath the secondary text.\n * Defaults to false\n * @returns Formatted div with list header content\n */\nexport function SettingsListHeader({\n primary,\n secondary,\n includeSeparator = false,\n}: SettingsListHeaderProps) {\n return (\n
    \n
    \n

    {primary}

    \n

    {secondary}

    \n
    \n {includeSeparator ? : ''}\n
    \n );\n}\n","import React from 'react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Card = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nCard.displayName = 'Card';\n\nconst CardHeader = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nCardHeader.displayName = 'CardHeader';\n\nconst CardTitle = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n {/* added because of https://github.com/jsx-eslint/eslint-plugin-jsx-a11y/blob/main/docs/rules/heading-has-content.md */}\n {props.children}\n \n ),\n);\nCardTitle.displayName = 'CardTitle';\n\nconst CardDescription = React.forwardRef<\n HTMLParagraphElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n

    \n));\nCardDescription.displayName = 'CardDescription';\n\nconst CardContent = React.forwardRef>(\n ({ className, ...props }, ref) => (\n

    \n ),\n);\nCardContent.displayName = 'CardContent';\n\nconst CardFooter = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nCardFooter.displayName = 'CardFooter';\n\nexport { Card, CardHeader, CardFooter, CardTitle, CardDescription, CardContent };\n","import { Card, CardDescription, CardHeader, CardTitle } from '@/components/shadcn-ui/card';\nimport { CardContent } from '@mui/material';\nimport { PropsWithChildren } from 'react';\n\ntype SettingsCardProps = PropsWithChildren & {\n settingsGroupLabel: string;\n settingsGroupDescription: string;\n};\n\nexport default function SettingsCard({\n settingsGroupLabel,\n settingsGroupDescription,\n children,\n}: SettingsCardProps) {\n return (\n \n \n {settingsGroupLabel}\n {settingsGroupDescription}\n \n {children}\n \n );\n}\n","import Checkbox from '@/components/shadcn-ui/checkbox';\nimport { Label } from '@/components/shadcn-ui/label';\n\nexport type ChecklistProps = {\n /** Optional string representing the id attribute of the Checklist */\n id?: string;\n /** Optional string representing CSS class name(s) for styling */\n className?: string;\n /** Array of strings representing the checkable items */\n listItems: string[];\n /** Array of strings representing the checked items */\n selectedListItems: string[];\n /**\n * Function that is called when a checkbox item is selected or deselected\n *\n * @param item The string description for this item\n * @param selected True if selected, false if not selected\n */\n handleSelectListItem: (item: string, selected: boolean) => void;\n\n /**\n * Optional function creates a label for a provided checkable item\n *\n * @param item The item for which a label is to be created\n * @returns A string representing the label text for the checkbox associated with that item\n */\n createLabel?: (item: string) => string;\n};\n\n/** Renders a list of checkboxes. Each checkbox corresponds to an item from the `listItems` array. */\nexport default function Checklist({\n id,\n className,\n listItems,\n selectedListItems,\n handleSelectListItem,\n createLabel,\n}: ChecklistProps) {\n return (\n
    \n {listItems.map((item) => (\n
    \n handleSelectListItem(item, value)}\n />\n \n
    \n ))}\n
    \n );\n}\n","function _interopRequireDefault(obj) {\n return obj && obj.__esModule ? obj : {\n \"default\": obj\n };\n}\nmodule.exports = _interopRequireDefault, module.exports.__esModule = true, module.exports[\"default\"] = module.exports;","export default function chainPropTypes(propType1, propType2) {\n if (process.env.NODE_ENV === 'production') {\n return () => null;\n }\n return function validate(...args) {\n return propType1(...args) || propType2(...args);\n };\n}","export default function _extends() {\n _extends = Object.assign ? Object.assign.bind() : function (target) {\n for (var i = 1; i < arguments.length; i++) {\n var source = arguments[i];\n for (var key in source) {\n if (Object.prototype.hasOwnProperty.call(source, key)) {\n target[key] = source[key];\n }\n }\n }\n return target;\n };\n return _extends.apply(this, arguments);\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\n// https://github.com/sindresorhus/is-plain-obj/blob/main/index.js\nexport function isPlainObject(item) {\n if (typeof item !== 'object' || item === null) {\n return false;\n }\n const prototype = Object.getPrototypeOf(item);\n return (prototype === null || prototype === Object.prototype || Object.getPrototypeOf(prototype) === null) && !(Symbol.toStringTag in item) && !(Symbol.iterator in item);\n}\nfunction deepClone(source) {\n if (!isPlainObject(source)) {\n return source;\n }\n const output = {};\n Object.keys(source).forEach(key => {\n output[key] = deepClone(source[key]);\n });\n return output;\n}\nexport default function deepmerge(target, source, options = {\n clone: true\n}) {\n const output = options.clone ? _extends({}, target) : target;\n if (isPlainObject(target) && isPlainObject(source)) {\n Object.keys(source).forEach(key => {\n // Avoid prototype pollution\n if (key === '__proto__') {\n return;\n }\n if (isPlainObject(source[key]) && key in target && isPlainObject(target[key])) {\n // Since `output` is a clone of `target` and we have narrowed `target` in this block we can cast to the same type.\n output[key] = deepmerge(target[key], source[key], options);\n } else if (options.clone) {\n output[key] = isPlainObject(source[key]) ? deepClone(source[key]) : source[key];\n } else {\n output[key] = source[key];\n }\n });\n }\n return output;\n}","/** @license React v16.13.1\n * react-is.production.min.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';var b=\"function\"===typeof Symbol&&Symbol.for,c=b?Symbol.for(\"react.element\"):60103,d=b?Symbol.for(\"react.portal\"):60106,e=b?Symbol.for(\"react.fragment\"):60107,f=b?Symbol.for(\"react.strict_mode\"):60108,g=b?Symbol.for(\"react.profiler\"):60114,h=b?Symbol.for(\"react.provider\"):60109,k=b?Symbol.for(\"react.context\"):60110,l=b?Symbol.for(\"react.async_mode\"):60111,m=b?Symbol.for(\"react.concurrent_mode\"):60111,n=b?Symbol.for(\"react.forward_ref\"):60112,p=b?Symbol.for(\"react.suspense\"):60113,q=b?\nSymbol.for(\"react.suspense_list\"):60120,r=b?Symbol.for(\"react.memo\"):60115,t=b?Symbol.for(\"react.lazy\"):60116,v=b?Symbol.for(\"react.block\"):60121,w=b?Symbol.for(\"react.fundamental\"):60117,x=b?Symbol.for(\"react.responder\"):60118,y=b?Symbol.for(\"react.scope\"):60119;\nfunction z(a){if(\"object\"===typeof a&&null!==a){var u=a.$$typeof;switch(u){case c:switch(a=a.type,a){case l:case m:case e:case g:case f:case p:return a;default:switch(a=a&&a.$$typeof,a){case k:case n:case t:case r:case h:return a;default:return u}}case d:return u}}}function A(a){return z(a)===m}exports.AsyncMode=l;exports.ConcurrentMode=m;exports.ContextConsumer=k;exports.ContextProvider=h;exports.Element=c;exports.ForwardRef=n;exports.Fragment=e;exports.Lazy=t;exports.Memo=r;exports.Portal=d;\nexports.Profiler=g;exports.StrictMode=f;exports.Suspense=p;exports.isAsyncMode=function(a){return A(a)||z(a)===l};exports.isConcurrentMode=A;exports.isContextConsumer=function(a){return z(a)===k};exports.isContextProvider=function(a){return z(a)===h};exports.isElement=function(a){return\"object\"===typeof a&&null!==a&&a.$$typeof===c};exports.isForwardRef=function(a){return z(a)===n};exports.isFragment=function(a){return z(a)===e};exports.isLazy=function(a){return z(a)===t};\nexports.isMemo=function(a){return z(a)===r};exports.isPortal=function(a){return z(a)===d};exports.isProfiler=function(a){return z(a)===g};exports.isStrictMode=function(a){return z(a)===f};exports.isSuspense=function(a){return z(a)===p};\nexports.isValidElementType=function(a){return\"string\"===typeof a||\"function\"===typeof a||a===e||a===m||a===g||a===f||a===p||a===q||\"object\"===typeof a&&null!==a&&(a.$$typeof===t||a.$$typeof===r||a.$$typeof===h||a.$$typeof===k||a.$$typeof===n||a.$$typeof===w||a.$$typeof===x||a.$$typeof===y||a.$$typeof===v)};exports.typeOf=z;\n","/** @license React v16.13.1\n * react-is.development.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\n\n\nif (process.env.NODE_ENV !== \"production\") {\n (function() {\n'use strict';\n\n// The Symbol used to tag the ReactElement-like types. If there is no native Symbol\n// nor polyfill, then a plain number is used for performance.\nvar hasSymbol = typeof Symbol === 'function' && Symbol.for;\nvar REACT_ELEMENT_TYPE = hasSymbol ? Symbol.for('react.element') : 0xeac7;\nvar REACT_PORTAL_TYPE = hasSymbol ? Symbol.for('react.portal') : 0xeaca;\nvar REACT_FRAGMENT_TYPE = hasSymbol ? Symbol.for('react.fragment') : 0xeacb;\nvar REACT_STRICT_MODE_TYPE = hasSymbol ? Symbol.for('react.strict_mode') : 0xeacc;\nvar REACT_PROFILER_TYPE = hasSymbol ? Symbol.for('react.profiler') : 0xead2;\nvar REACT_PROVIDER_TYPE = hasSymbol ? Symbol.for('react.provider') : 0xeacd;\nvar REACT_CONTEXT_TYPE = hasSymbol ? Symbol.for('react.context') : 0xeace; // TODO: We don't use AsyncMode or ConcurrentMode anymore. They were temporary\n// (unstable) APIs that have been removed. Can we remove the symbols?\n\nvar REACT_ASYNC_MODE_TYPE = hasSymbol ? Symbol.for('react.async_mode') : 0xeacf;\nvar REACT_CONCURRENT_MODE_TYPE = hasSymbol ? Symbol.for('react.concurrent_mode') : 0xeacf;\nvar REACT_FORWARD_REF_TYPE = hasSymbol ? Symbol.for('react.forward_ref') : 0xead0;\nvar REACT_SUSPENSE_TYPE = hasSymbol ? Symbol.for('react.suspense') : 0xead1;\nvar REACT_SUSPENSE_LIST_TYPE = hasSymbol ? Symbol.for('react.suspense_list') : 0xead8;\nvar REACT_MEMO_TYPE = hasSymbol ? Symbol.for('react.memo') : 0xead3;\nvar REACT_LAZY_TYPE = hasSymbol ? Symbol.for('react.lazy') : 0xead4;\nvar REACT_BLOCK_TYPE = hasSymbol ? Symbol.for('react.block') : 0xead9;\nvar REACT_FUNDAMENTAL_TYPE = hasSymbol ? Symbol.for('react.fundamental') : 0xead5;\nvar REACT_RESPONDER_TYPE = hasSymbol ? Symbol.for('react.responder') : 0xead6;\nvar REACT_SCOPE_TYPE = hasSymbol ? Symbol.for('react.scope') : 0xead7;\n\nfunction isValidElementType(type) {\n return typeof type === 'string' || typeof type === 'function' || // Note: its typeof might be other than 'symbol' or 'number' if it's a polyfill.\n type === REACT_FRAGMENT_TYPE || type === REACT_CONCURRENT_MODE_TYPE || type === REACT_PROFILER_TYPE || type === REACT_STRICT_MODE_TYPE || type === REACT_SUSPENSE_TYPE || type === REACT_SUSPENSE_LIST_TYPE || typeof type === 'object' && type !== null && (type.$$typeof === REACT_LAZY_TYPE || type.$$typeof === REACT_MEMO_TYPE || type.$$typeof === REACT_PROVIDER_TYPE || type.$$typeof === REACT_CONTEXT_TYPE || type.$$typeof === REACT_FORWARD_REF_TYPE || type.$$typeof === REACT_FUNDAMENTAL_TYPE || type.$$typeof === REACT_RESPONDER_TYPE || type.$$typeof === REACT_SCOPE_TYPE || type.$$typeof === REACT_BLOCK_TYPE);\n}\n\nfunction typeOf(object) {\n if (typeof object === 'object' && object !== null) {\n var $$typeof = object.$$typeof;\n\n switch ($$typeof) {\n case REACT_ELEMENT_TYPE:\n var type = object.type;\n\n switch (type) {\n case REACT_ASYNC_MODE_TYPE:\n case REACT_CONCURRENT_MODE_TYPE:\n case REACT_FRAGMENT_TYPE:\n case REACT_PROFILER_TYPE:\n case REACT_STRICT_MODE_TYPE:\n case REACT_SUSPENSE_TYPE:\n return type;\n\n default:\n var $$typeofType = type && type.$$typeof;\n\n switch ($$typeofType) {\n case REACT_CONTEXT_TYPE:\n case REACT_FORWARD_REF_TYPE:\n case REACT_LAZY_TYPE:\n case REACT_MEMO_TYPE:\n case REACT_PROVIDER_TYPE:\n return $$typeofType;\n\n default:\n return $$typeof;\n }\n\n }\n\n case REACT_PORTAL_TYPE:\n return $$typeof;\n }\n }\n\n return undefined;\n} // AsyncMode is deprecated along with isAsyncMode\n\nvar AsyncMode = REACT_ASYNC_MODE_TYPE;\nvar ConcurrentMode = REACT_CONCURRENT_MODE_TYPE;\nvar ContextConsumer = REACT_CONTEXT_TYPE;\nvar ContextProvider = REACT_PROVIDER_TYPE;\nvar Element = REACT_ELEMENT_TYPE;\nvar ForwardRef = REACT_FORWARD_REF_TYPE;\nvar Fragment = REACT_FRAGMENT_TYPE;\nvar Lazy = REACT_LAZY_TYPE;\nvar Memo = REACT_MEMO_TYPE;\nvar Portal = REACT_PORTAL_TYPE;\nvar Profiler = REACT_PROFILER_TYPE;\nvar StrictMode = REACT_STRICT_MODE_TYPE;\nvar Suspense = REACT_SUSPENSE_TYPE;\nvar hasWarnedAboutDeprecatedIsAsyncMode = false; // AsyncMode should be deprecated\n\nfunction isAsyncMode(object) {\n {\n if (!hasWarnedAboutDeprecatedIsAsyncMode) {\n hasWarnedAboutDeprecatedIsAsyncMode = true; // Using console['warn'] to evade Babel and ESLint\n\n console['warn']('The ReactIs.isAsyncMode() alias has been deprecated, ' + 'and will be removed in React 17+. Update your code to use ' + 'ReactIs.isConcurrentMode() instead. It has the exact same API.');\n }\n }\n\n return isConcurrentMode(object) || typeOf(object) === REACT_ASYNC_MODE_TYPE;\n}\nfunction isConcurrentMode(object) {\n return typeOf(object) === REACT_CONCURRENT_MODE_TYPE;\n}\nfunction isContextConsumer(object) {\n return typeOf(object) === REACT_CONTEXT_TYPE;\n}\nfunction isContextProvider(object) {\n return typeOf(object) === REACT_PROVIDER_TYPE;\n}\nfunction isElement(object) {\n return typeof object === 'object' && object !== null && object.$$typeof === REACT_ELEMENT_TYPE;\n}\nfunction isForwardRef(object) {\n return typeOf(object) === REACT_FORWARD_REF_TYPE;\n}\nfunction isFragment(object) {\n return typeOf(object) === REACT_FRAGMENT_TYPE;\n}\nfunction isLazy(object) {\n return typeOf(object) === REACT_LAZY_TYPE;\n}\nfunction isMemo(object) {\n return typeOf(object) === REACT_MEMO_TYPE;\n}\nfunction isPortal(object) {\n return typeOf(object) === REACT_PORTAL_TYPE;\n}\nfunction isProfiler(object) {\n return typeOf(object) === REACT_PROFILER_TYPE;\n}\nfunction isStrictMode(object) {\n return typeOf(object) === REACT_STRICT_MODE_TYPE;\n}\nfunction isSuspense(object) {\n return typeOf(object) === REACT_SUSPENSE_TYPE;\n}\n\nexports.AsyncMode = AsyncMode;\nexports.ConcurrentMode = ConcurrentMode;\nexports.ContextConsumer = ContextConsumer;\nexports.ContextProvider = ContextProvider;\nexports.Element = Element;\nexports.ForwardRef = ForwardRef;\nexports.Fragment = Fragment;\nexports.Lazy = Lazy;\nexports.Memo = Memo;\nexports.Portal = Portal;\nexports.Profiler = Profiler;\nexports.StrictMode = StrictMode;\nexports.Suspense = Suspense;\nexports.isAsyncMode = isAsyncMode;\nexports.isConcurrentMode = isConcurrentMode;\nexports.isContextConsumer = isContextConsumer;\nexports.isContextProvider = isContextProvider;\nexports.isElement = isElement;\nexports.isForwardRef = isForwardRef;\nexports.isFragment = isFragment;\nexports.isLazy = isLazy;\nexports.isMemo = isMemo;\nexports.isPortal = isPortal;\nexports.isProfiler = isProfiler;\nexports.isStrictMode = isStrictMode;\nexports.isSuspense = isSuspense;\nexports.isValidElementType = isValidElementType;\nexports.typeOf = typeOf;\n })();\n}\n","'use strict';\n\nif (process.env.NODE_ENV === 'production') {\n module.exports = require('./cjs/react-is.production.min.js');\n} else {\n module.exports = require('./cjs/react-is.development.js');\n}\n","/*\nobject-assign\n(c) Sindre Sorhus\n@license MIT\n*/\n\n'use strict';\n/* eslint-disable no-unused-vars */\nvar getOwnPropertySymbols = Object.getOwnPropertySymbols;\nvar hasOwnProperty = Object.prototype.hasOwnProperty;\nvar propIsEnumerable = Object.prototype.propertyIsEnumerable;\n\nfunction toObject(val) {\n\tif (val === null || val === undefined) {\n\t\tthrow new TypeError('Object.assign cannot be called with null or undefined');\n\t}\n\n\treturn Object(val);\n}\n\nfunction shouldUseNative() {\n\ttry {\n\t\tif (!Object.assign) {\n\t\t\treturn false;\n\t\t}\n\n\t\t// Detect buggy property enumeration order in older V8 versions.\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=4118\n\t\tvar test1 = new String('abc'); // eslint-disable-line no-new-wrappers\n\t\ttest1[5] = 'de';\n\t\tif (Object.getOwnPropertyNames(test1)[0] === '5') {\n\t\t\treturn false;\n\t\t}\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=3056\n\t\tvar test2 = {};\n\t\tfor (var i = 0; i < 10; i++) {\n\t\t\ttest2['_' + String.fromCharCode(i)] = i;\n\t\t}\n\t\tvar order2 = Object.getOwnPropertyNames(test2).map(function (n) {\n\t\t\treturn test2[n];\n\t\t});\n\t\tif (order2.join('') !== '0123456789') {\n\t\t\treturn false;\n\t\t}\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=3056\n\t\tvar test3 = {};\n\t\t'abcdefghijklmnopqrst'.split('').forEach(function (letter) {\n\t\t\ttest3[letter] = letter;\n\t\t});\n\t\tif (Object.keys(Object.assign({}, test3)).join('') !==\n\t\t\t\t'abcdefghijklmnopqrst') {\n\t\t\treturn false;\n\t\t}\n\n\t\treturn true;\n\t} catch (err) {\n\t\t// We don't expect any of the above to throw, but better to be safe.\n\t\treturn false;\n\t}\n}\n\nmodule.exports = shouldUseNative() ? Object.assign : function (target, source) {\n\tvar from;\n\tvar to = toObject(target);\n\tvar symbols;\n\n\tfor (var s = 1; s < arguments.length; s++) {\n\t\tfrom = Object(arguments[s]);\n\n\t\tfor (var key in from) {\n\t\t\tif (hasOwnProperty.call(from, key)) {\n\t\t\t\tto[key] = from[key];\n\t\t\t}\n\t\t}\n\n\t\tif (getOwnPropertySymbols) {\n\t\t\tsymbols = getOwnPropertySymbols(from);\n\t\t\tfor (var i = 0; i < symbols.length; i++) {\n\t\t\t\tif (propIsEnumerable.call(from, symbols[i])) {\n\t\t\t\t\tto[symbols[i]] = from[symbols[i]];\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\n\treturn to;\n};\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar ReactPropTypesSecret = 'SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED';\n\nmodule.exports = ReactPropTypesSecret;\n","module.exports = Function.call.bind(Object.prototype.hasOwnProperty);\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar printWarning = function() {};\n\nif (process.env.NODE_ENV !== 'production') {\n var ReactPropTypesSecret = require('./lib/ReactPropTypesSecret');\n var loggedTypeFailures = {};\n var has = require('./lib/has');\n\n printWarning = function(text) {\n var message = 'Warning: ' + text;\n if (typeof console !== 'undefined') {\n console.error(message);\n }\n try {\n // --- Welcome to debugging React ---\n // This error was thrown as a convenience so that you can use this stack\n // to find the callsite that caused this warning to fire.\n throw new Error(message);\n } catch (x) { /**/ }\n };\n}\n\n/**\n * Assert that the values match with the type specs.\n * Error messages are memorized and will only be shown once.\n *\n * @param {object} typeSpecs Map of name to a ReactPropType\n * @param {object} values Runtime values that need to be type-checked\n * @param {string} location e.g. \"prop\", \"context\", \"child context\"\n * @param {string} componentName Name of the component for error messages.\n * @param {?Function} getStack Returns the component stack.\n * @private\n */\nfunction checkPropTypes(typeSpecs, values, location, componentName, getStack) {\n if (process.env.NODE_ENV !== 'production') {\n for (var typeSpecName in typeSpecs) {\n if (has(typeSpecs, typeSpecName)) {\n var error;\n // Prop type validation may throw. In case they do, we don't want to\n // fail the render phase where it didn't fail before. So we log it.\n // After these have been cleaned up, we'll let them throw.\n try {\n // This is intentionally an invariant that gets caught. It's the same\n // behavior as without this statement except with a better message.\n if (typeof typeSpecs[typeSpecName] !== 'function') {\n var err = Error(\n (componentName || 'React class') + ': ' + location + ' type `' + typeSpecName + '` is invalid; ' +\n 'it must be a function, usually from the `prop-types` package, but received `' + typeof typeSpecs[typeSpecName] + '`.' +\n 'This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.'\n );\n err.name = 'Invariant Violation';\n throw err;\n }\n error = typeSpecs[typeSpecName](values, typeSpecName, componentName, location, null, ReactPropTypesSecret);\n } catch (ex) {\n error = ex;\n }\n if (error && !(error instanceof Error)) {\n printWarning(\n (componentName || 'React class') + ': type specification of ' +\n location + ' `' + typeSpecName + '` is invalid; the type checker ' +\n 'function must return `null` or an `Error` but returned a ' + typeof error + '. ' +\n 'You may have forgotten to pass an argument to the type checker ' +\n 'creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and ' +\n 'shape all require an argument).'\n );\n }\n if (error instanceof Error && !(error.message in loggedTypeFailures)) {\n // Only monitor this failure once because there tends to be a lot of the\n // same error.\n loggedTypeFailures[error.message] = true;\n\n var stack = getStack ? getStack() : '';\n\n printWarning(\n 'Failed ' + location + ' type: ' + error.message + (stack != null ? stack : '')\n );\n }\n }\n }\n }\n}\n\n/**\n * Resets warning cache when testing.\n *\n * @private\n */\ncheckPropTypes.resetWarningCache = function() {\n if (process.env.NODE_ENV !== 'production') {\n loggedTypeFailures = {};\n }\n}\n\nmodule.exports = checkPropTypes;\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar ReactIs = require('react-is');\nvar assign = require('object-assign');\n\nvar ReactPropTypesSecret = require('./lib/ReactPropTypesSecret');\nvar has = require('./lib/has');\nvar checkPropTypes = require('./checkPropTypes');\n\nvar printWarning = function() {};\n\nif (process.env.NODE_ENV !== 'production') {\n printWarning = function(text) {\n var message = 'Warning: ' + text;\n if (typeof console !== 'undefined') {\n console.error(message);\n }\n try {\n // --- Welcome to debugging React ---\n // This error was thrown as a convenience so that you can use this stack\n // to find the callsite that caused this warning to fire.\n throw new Error(message);\n } catch (x) {}\n };\n}\n\nfunction emptyFunctionThatReturnsNull() {\n return null;\n}\n\nmodule.exports = function(isValidElement, throwOnDirectAccess) {\n /* global Symbol */\n var ITERATOR_SYMBOL = typeof Symbol === 'function' && Symbol.iterator;\n var FAUX_ITERATOR_SYMBOL = '@@iterator'; // Before Symbol spec.\n\n /**\n * Returns the iterator method function contained on the iterable object.\n *\n * Be sure to invoke the function with the iterable as context:\n *\n * var iteratorFn = getIteratorFn(myIterable);\n * if (iteratorFn) {\n * var iterator = iteratorFn.call(myIterable);\n * ...\n * }\n *\n * @param {?object} maybeIterable\n * @return {?function}\n */\n function getIteratorFn(maybeIterable) {\n var iteratorFn = maybeIterable && (ITERATOR_SYMBOL && maybeIterable[ITERATOR_SYMBOL] || maybeIterable[FAUX_ITERATOR_SYMBOL]);\n if (typeof iteratorFn === 'function') {\n return iteratorFn;\n }\n }\n\n /**\n * Collection of methods that allow declaration and validation of props that are\n * supplied to React components. Example usage:\n *\n * var Props = require('ReactPropTypes');\n * var MyArticle = React.createClass({\n * propTypes: {\n * // An optional string prop named \"description\".\n * description: Props.string,\n *\n * // A required enum prop named \"category\".\n * category: Props.oneOf(['News','Photos']).isRequired,\n *\n * // A prop named \"dialog\" that requires an instance of Dialog.\n * dialog: Props.instanceOf(Dialog).isRequired\n * },\n * render: function() { ... }\n * });\n *\n * A more formal specification of how these methods are used:\n *\n * type := array|bool|func|object|number|string|oneOf([...])|instanceOf(...)\n * decl := ReactPropTypes.{type}(.isRequired)?\n *\n * Each and every declaration produces a function with the same signature. This\n * allows the creation of custom validation functions. For example:\n *\n * var MyLink = React.createClass({\n * propTypes: {\n * // An optional string or URI prop named \"href\".\n * href: function(props, propName, componentName) {\n * var propValue = props[propName];\n * if (propValue != null && typeof propValue !== 'string' &&\n * !(propValue instanceof URI)) {\n * return new Error(\n * 'Expected a string or an URI for ' + propName + ' in ' +\n * componentName\n * );\n * }\n * }\n * },\n * render: function() {...}\n * });\n *\n * @internal\n */\n\n var ANONYMOUS = '<>';\n\n // Important!\n // Keep this list in sync with production version in `./factoryWithThrowingShims.js`.\n var ReactPropTypes = {\n array: createPrimitiveTypeChecker('array'),\n bigint: createPrimitiveTypeChecker('bigint'),\n bool: createPrimitiveTypeChecker('boolean'),\n func: createPrimitiveTypeChecker('function'),\n number: createPrimitiveTypeChecker('number'),\n object: createPrimitiveTypeChecker('object'),\n string: createPrimitiveTypeChecker('string'),\n symbol: createPrimitiveTypeChecker('symbol'),\n\n any: createAnyTypeChecker(),\n arrayOf: createArrayOfTypeChecker,\n element: createElementTypeChecker(),\n elementType: createElementTypeTypeChecker(),\n instanceOf: createInstanceTypeChecker,\n node: createNodeChecker(),\n objectOf: createObjectOfTypeChecker,\n oneOf: createEnumTypeChecker,\n oneOfType: createUnionTypeChecker,\n shape: createShapeTypeChecker,\n exact: createStrictShapeTypeChecker,\n };\n\n /**\n * inlined Object.is polyfill to avoid requiring consumers ship their own\n * https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object/is\n */\n /*eslint-disable no-self-compare*/\n function is(x, y) {\n // SameValue algorithm\n if (x === y) {\n // Steps 1-5, 7-10\n // Steps 6.b-6.e: +0 != -0\n return x !== 0 || 1 / x === 1 / y;\n } else {\n // Step 6.a: NaN == NaN\n return x !== x && y !== y;\n }\n }\n /*eslint-enable no-self-compare*/\n\n /**\n * We use an Error-like object for backward compatibility as people may call\n * PropTypes directly and inspect their output. However, we don't use real\n * Errors anymore. We don't inspect their stack anyway, and creating them\n * is prohibitively expensive if they are created too often, such as what\n * happens in oneOfType() for any type before the one that matched.\n */\n function PropTypeError(message, data) {\n this.message = message;\n this.data = data && typeof data === 'object' ? data: {};\n this.stack = '';\n }\n // Make `instanceof Error` still work for returned errors.\n PropTypeError.prototype = Error.prototype;\n\n function createChainableTypeChecker(validate) {\n if (process.env.NODE_ENV !== 'production') {\n var manualPropTypeCallCache = {};\n var manualPropTypeWarningCount = 0;\n }\n function checkType(isRequired, props, propName, componentName, location, propFullName, secret) {\n componentName = componentName || ANONYMOUS;\n propFullName = propFullName || propName;\n\n if (secret !== ReactPropTypesSecret) {\n if (throwOnDirectAccess) {\n // New behavior only for users of `prop-types` package\n var err = new Error(\n 'Calling PropTypes validators directly is not supported by the `prop-types` package. ' +\n 'Use `PropTypes.checkPropTypes()` to call them. ' +\n 'Read more at http://fb.me/use-check-prop-types'\n );\n err.name = 'Invariant Violation';\n throw err;\n } else if (process.env.NODE_ENV !== 'production' && typeof console !== 'undefined') {\n // Old behavior for people using React.PropTypes\n var cacheKey = componentName + ':' + propName;\n if (\n !manualPropTypeCallCache[cacheKey] &&\n // Avoid spamming the console because they are often not actionable except for lib authors\n manualPropTypeWarningCount < 3\n ) {\n printWarning(\n 'You are manually calling a React.PropTypes validation ' +\n 'function for the `' + propFullName + '` prop on `' + componentName + '`. This is deprecated ' +\n 'and will throw in the standalone `prop-types` package. ' +\n 'You may be seeing this warning due to a third-party PropTypes ' +\n 'library. See https://fb.me/react-warning-dont-call-proptypes ' + 'for details.'\n );\n manualPropTypeCallCache[cacheKey] = true;\n manualPropTypeWarningCount++;\n }\n }\n }\n if (props[propName] == null) {\n if (isRequired) {\n if (props[propName] === null) {\n return new PropTypeError('The ' + location + ' `' + propFullName + '` is marked as required ' + ('in `' + componentName + '`, but its value is `null`.'));\n }\n return new PropTypeError('The ' + location + ' `' + propFullName + '` is marked as required in ' + ('`' + componentName + '`, but its value is `undefined`.'));\n }\n return null;\n } else {\n return validate(props, propName, componentName, location, propFullName);\n }\n }\n\n var chainedCheckType = checkType.bind(null, false);\n chainedCheckType.isRequired = checkType.bind(null, true);\n\n return chainedCheckType;\n }\n\n function createPrimitiveTypeChecker(expectedType) {\n function validate(props, propName, componentName, location, propFullName, secret) {\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== expectedType) {\n // `propValue` being instance of, say, date/regexp, pass the 'object'\n // check, but we can offer a more precise error message here rather than\n // 'of type `object`'.\n var preciseType = getPreciseType(propValue);\n\n return new PropTypeError(\n 'Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + preciseType + '` supplied to `' + componentName + '`, expected ') + ('`' + expectedType + '`.'),\n {expectedType: expectedType}\n );\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createAnyTypeChecker() {\n return createChainableTypeChecker(emptyFunctionThatReturnsNull);\n }\n\n function createArrayOfTypeChecker(typeChecker) {\n function validate(props, propName, componentName, location, propFullName) {\n if (typeof typeChecker !== 'function') {\n return new PropTypeError('Property `' + propFullName + '` of component `' + componentName + '` has invalid PropType notation inside arrayOf.');\n }\n var propValue = props[propName];\n if (!Array.isArray(propValue)) {\n var propType = getPropType(propValue);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected an array.'));\n }\n for (var i = 0; i < propValue.length; i++) {\n var error = typeChecker(propValue, i, componentName, location, propFullName + '[' + i + ']', ReactPropTypesSecret);\n if (error instanceof Error) {\n return error;\n }\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createElementTypeChecker() {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n if (!isValidElement(propValue)) {\n var propType = getPropType(propValue);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected a single ReactElement.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createElementTypeTypeChecker() {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n if (!ReactIs.isValidElementType(propValue)) {\n var propType = getPropType(propValue);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected a single ReactElement type.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createInstanceTypeChecker(expectedClass) {\n function validate(props, propName, componentName, location, propFullName) {\n if (!(props[propName] instanceof expectedClass)) {\n var expectedClassName = expectedClass.name || ANONYMOUS;\n var actualClassName = getClassName(props[propName]);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + actualClassName + '` supplied to `' + componentName + '`, expected ') + ('instance of `' + expectedClassName + '`.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createEnumTypeChecker(expectedValues) {\n if (!Array.isArray(expectedValues)) {\n if (process.env.NODE_ENV !== 'production') {\n if (arguments.length > 1) {\n printWarning(\n 'Invalid arguments supplied to oneOf, expected an array, got ' + arguments.length + ' arguments. ' +\n 'A common mistake is to write oneOf(x, y, z) instead of oneOf([x, y, z]).'\n );\n } else {\n printWarning('Invalid argument supplied to oneOf, expected an array.');\n }\n }\n return emptyFunctionThatReturnsNull;\n }\n\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n for (var i = 0; i < expectedValues.length; i++) {\n if (is(propValue, expectedValues[i])) {\n return null;\n }\n }\n\n var valuesString = JSON.stringify(expectedValues, function replacer(key, value) {\n var type = getPreciseType(value);\n if (type === 'symbol') {\n return String(value);\n }\n return value;\n });\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of value `' + String(propValue) + '` ' + ('supplied to `' + componentName + '`, expected one of ' + valuesString + '.'));\n }\n return createChainableTypeChecker(validate);\n }\n\n function createObjectOfTypeChecker(typeChecker) {\n function validate(props, propName, componentName, location, propFullName) {\n if (typeof typeChecker !== 'function') {\n return new PropTypeError('Property `' + propFullName + '` of component `' + componentName + '` has invalid PropType notation inside objectOf.');\n }\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== 'object') {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected an object.'));\n }\n for (var key in propValue) {\n if (has(propValue, key)) {\n var error = typeChecker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret);\n if (error instanceof Error) {\n return error;\n }\n }\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createUnionTypeChecker(arrayOfTypeCheckers) {\n if (!Array.isArray(arrayOfTypeCheckers)) {\n process.env.NODE_ENV !== 'production' ? printWarning('Invalid argument supplied to oneOfType, expected an instance of array.') : void 0;\n return emptyFunctionThatReturnsNull;\n }\n\n for (var i = 0; i < arrayOfTypeCheckers.length; i++) {\n var checker = arrayOfTypeCheckers[i];\n if (typeof checker !== 'function') {\n printWarning(\n 'Invalid argument supplied to oneOfType. Expected an array of check functions, but ' +\n 'received ' + getPostfixForTypeWarning(checker) + ' at index ' + i + '.'\n );\n return emptyFunctionThatReturnsNull;\n }\n }\n\n function validate(props, propName, componentName, location, propFullName) {\n var expectedTypes = [];\n for (var i = 0; i < arrayOfTypeCheckers.length; i++) {\n var checker = arrayOfTypeCheckers[i];\n var checkerResult = checker(props, propName, componentName, location, propFullName, ReactPropTypesSecret);\n if (checkerResult == null) {\n return null;\n }\n if (checkerResult.data && has(checkerResult.data, 'expectedType')) {\n expectedTypes.push(checkerResult.data.expectedType);\n }\n }\n var expectedTypesMessage = (expectedTypes.length > 0) ? ', expected one of type [' + expectedTypes.join(', ') + ']': '';\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` supplied to ' + ('`' + componentName + '`' + expectedTypesMessage + '.'));\n }\n return createChainableTypeChecker(validate);\n }\n\n function createNodeChecker() {\n function validate(props, propName, componentName, location, propFullName) {\n if (!isNode(props[propName])) {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` supplied to ' + ('`' + componentName + '`, expected a ReactNode.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function invalidValidatorError(componentName, location, propFullName, key, type) {\n return new PropTypeError(\n (componentName || 'React class') + ': ' + location + ' type `' + propFullName + '.' + key + '` is invalid; ' +\n 'it must be a function, usually from the `prop-types` package, but received `' + type + '`.'\n );\n }\n\n function createShapeTypeChecker(shapeTypes) {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== 'object') {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type `' + propType + '` ' + ('supplied to `' + componentName + '`, expected `object`.'));\n }\n for (var key in shapeTypes) {\n var checker = shapeTypes[key];\n if (typeof checker !== 'function') {\n return invalidValidatorError(componentName, location, propFullName, key, getPreciseType(checker));\n }\n var error = checker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret);\n if (error) {\n return error;\n }\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createStrictShapeTypeChecker(shapeTypes) {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== 'object') {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type `' + propType + '` ' + ('supplied to `' + componentName + '`, expected `object`.'));\n }\n // We need to check all keys in case some are required but missing from props.\n var allKeys = assign({}, props[propName], shapeTypes);\n for (var key in allKeys) {\n var checker = shapeTypes[key];\n if (has(shapeTypes, key) && typeof checker !== 'function') {\n return invalidValidatorError(componentName, location, propFullName, key, getPreciseType(checker));\n }\n if (!checker) {\n return new PropTypeError(\n 'Invalid ' + location + ' `' + propFullName + '` key `' + key + '` supplied to `' + componentName + '`.' +\n '\\nBad object: ' + JSON.stringify(props[propName], null, ' ') +\n '\\nValid keys: ' + JSON.stringify(Object.keys(shapeTypes), null, ' ')\n );\n }\n var error = checker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret);\n if (error) {\n return error;\n }\n }\n return null;\n }\n\n return createChainableTypeChecker(validate);\n }\n\n function isNode(propValue) {\n switch (typeof propValue) {\n case 'number':\n case 'string':\n case 'undefined':\n return true;\n case 'boolean':\n return !propValue;\n case 'object':\n if (Array.isArray(propValue)) {\n return propValue.every(isNode);\n }\n if (propValue === null || isValidElement(propValue)) {\n return true;\n }\n\n var iteratorFn = getIteratorFn(propValue);\n if (iteratorFn) {\n var iterator = iteratorFn.call(propValue);\n var step;\n if (iteratorFn !== propValue.entries) {\n while (!(step = iterator.next()).done) {\n if (!isNode(step.value)) {\n return false;\n }\n }\n } else {\n // Iterator will provide entry [k,v] tuples rather than values.\n while (!(step = iterator.next()).done) {\n var entry = step.value;\n if (entry) {\n if (!isNode(entry[1])) {\n return false;\n }\n }\n }\n }\n } else {\n return false;\n }\n\n return true;\n default:\n return false;\n }\n }\n\n function isSymbol(propType, propValue) {\n // Native Symbol.\n if (propType === 'symbol') {\n return true;\n }\n\n // falsy value can't be a Symbol\n if (!propValue) {\n return false;\n }\n\n // 19.4.3.5 Symbol.prototype[@@toStringTag] === 'Symbol'\n if (propValue['@@toStringTag'] === 'Symbol') {\n return true;\n }\n\n // Fallback for non-spec compliant Symbols which are polyfilled.\n if (typeof Symbol === 'function' && propValue instanceof Symbol) {\n return true;\n }\n\n return false;\n }\n\n // Equivalent of `typeof` but with special handling for array and regexp.\n function getPropType(propValue) {\n var propType = typeof propValue;\n if (Array.isArray(propValue)) {\n return 'array';\n }\n if (propValue instanceof RegExp) {\n // Old webkits (at least until Android 4.0) return 'function' rather than\n // 'object' for typeof a RegExp. We'll normalize this here so that /bla/\n // passes PropTypes.object.\n return 'object';\n }\n if (isSymbol(propType, propValue)) {\n return 'symbol';\n }\n return propType;\n }\n\n // This handles more types than `getPropType`. Only used for error messages.\n // See `createPrimitiveTypeChecker`.\n function getPreciseType(propValue) {\n if (typeof propValue === 'undefined' || propValue === null) {\n return '' + propValue;\n }\n var propType = getPropType(propValue);\n if (propType === 'object') {\n if (propValue instanceof Date) {\n return 'date';\n } else if (propValue instanceof RegExp) {\n return 'regexp';\n }\n }\n return propType;\n }\n\n // Returns a string that is postfixed to a warning about an invalid type.\n // For example, \"undefined\" or \"of type array\"\n function getPostfixForTypeWarning(value) {\n var type = getPreciseType(value);\n switch (type) {\n case 'array':\n case 'object':\n return 'an ' + type;\n case 'boolean':\n case 'date':\n case 'regexp':\n return 'a ' + type;\n default:\n return type;\n }\n }\n\n // Returns class name of the object, if any.\n function getClassName(propValue) {\n if (!propValue.constructor || !propValue.constructor.name) {\n return ANONYMOUS;\n }\n return propValue.constructor.name;\n }\n\n ReactPropTypes.checkPropTypes = checkPropTypes;\n ReactPropTypes.resetWarningCache = checkPropTypes.resetWarningCache;\n ReactPropTypes.PropTypes = ReactPropTypes;\n\n return ReactPropTypes;\n};\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar ReactPropTypesSecret = require('./lib/ReactPropTypesSecret');\n\nfunction emptyFunction() {}\nfunction emptyFunctionWithReset() {}\nemptyFunctionWithReset.resetWarningCache = emptyFunction;\n\nmodule.exports = function() {\n function shim(props, propName, componentName, location, propFullName, secret) {\n if (secret === ReactPropTypesSecret) {\n // It is still safe when called from React.\n return;\n }\n var err = new Error(\n 'Calling PropTypes validators directly is not supported by the `prop-types` package. ' +\n 'Use PropTypes.checkPropTypes() to call them. ' +\n 'Read more at http://fb.me/use-check-prop-types'\n );\n err.name = 'Invariant Violation';\n throw err;\n };\n shim.isRequired = shim;\n function getShim() {\n return shim;\n };\n // Important!\n // Keep this list in sync with production version in `./factoryWithTypeCheckers.js`.\n var ReactPropTypes = {\n array: shim,\n bigint: shim,\n bool: shim,\n func: shim,\n number: shim,\n object: shim,\n string: shim,\n symbol: shim,\n\n any: shim,\n arrayOf: getShim,\n element: shim,\n elementType: shim,\n instanceOf: getShim,\n node: shim,\n objectOf: getShim,\n oneOf: getShim,\n oneOfType: getShim,\n shape: getShim,\n exact: getShim,\n\n checkPropTypes: emptyFunctionWithReset,\n resetWarningCache: emptyFunction\n };\n\n ReactPropTypes.PropTypes = ReactPropTypes;\n\n return ReactPropTypes;\n};\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\nif (process.env.NODE_ENV !== 'production') {\n var ReactIs = require('react-is');\n\n // By explicitly using `prop-types` you are opting into new development behavior.\n // http://fb.me/prop-types-in-prod\n var throwOnDirectAccess = true;\n module.exports = require('./factoryWithTypeCheckers')(ReactIs.isElement, throwOnDirectAccess);\n} else {\n // By explicitly using `prop-types` you are opting into new production behavior.\n // http://fb.me/prop-types-in-prod\n module.exports = require('./factoryWithThrowingShims')();\n}\n","import PropTypes from 'prop-types';\nimport chainPropTypes from '../chainPropTypes';\nfunction isClassComponent(elementType) {\n // elementType.prototype?.isReactComponent\n const {\n prototype = {}\n } = elementType;\n return Boolean(prototype.isReactComponent);\n}\nfunction acceptingRef(props, propName, componentName, location, propFullName) {\n const element = props[propName];\n const safePropName = propFullName || propName;\n if (element == null ||\n // When server-side rendering React doesn't warn either.\n // This is not an accurate check for SSR.\n // This is only in place for Emotion compat.\n // TODO: Revisit once https://github.com/facebook/react/issues/20047 is resolved.\n typeof window === 'undefined') {\n return null;\n }\n let warningHint;\n const elementType = element.type;\n /**\n * Blacklisting instead of whitelisting\n *\n * Blacklisting will miss some components, such as React.Fragment. Those will at least\n * trigger a warning in React.\n * We can't whitelist because there is no safe way to detect React.forwardRef\n * or class components. \"Safe\" means there's no public API.\n *\n */\n if (typeof elementType === 'function' && !isClassComponent(elementType)) {\n warningHint = 'Did you accidentally use a plain function component for an element instead?';\n }\n if (warningHint !== undefined) {\n return new Error(`Invalid ${location} \\`${safePropName}\\` supplied to \\`${componentName}\\`. ` + `Expected an element that can hold a ref. ${warningHint} ` + 'For more information see https://mui.com/r/caveat-with-refs-guide');\n }\n return null;\n}\nconst elementAcceptingRef = chainPropTypes(PropTypes.element, acceptingRef);\nelementAcceptingRef.isRequired = chainPropTypes(PropTypes.element.isRequired, acceptingRef);\nexport default elementAcceptingRef;","import _extends from \"@babel/runtime/helpers/esm/extends\";\n// This module is based on https://github.com/airbnb/prop-types-exact repository.\n// However, in order to reduce the number of dependencies and to remove some extra safe checks\n// the module was forked.\n\nconst specialProperty = 'exact-prop: \\u200b';\nexport default function exactProp(propTypes) {\n if (process.env.NODE_ENV === 'production') {\n return propTypes;\n }\n return _extends({}, propTypes, {\n [specialProperty]: props => {\n const unsupportedProps = Object.keys(props).filter(prop => !propTypes.hasOwnProperty(prop));\n if (unsupportedProps.length > 0) {\n return new Error(`The following props are not supported: ${unsupportedProps.map(prop => `\\`${prop}\\``).join(', ')}. Please remove them.`);\n }\n return null;\n }\n });\n}","/**\n * WARNING: Don't import this directly.\n * Use `MuiError` from `@mui/internal-babel-macros/MuiError.macro` instead.\n * @param {number} code\n */\nexport default function formatMuiErrorMessage(code) {\n // Apply babel-plugin-transform-template-literals in loose mode\n // loose mode is safe if we're concatenating primitives\n // see https://babeljs.io/docs/en/babel-plugin-transform-template-literals#loose\n /* eslint-disable prefer-template */\n let url = 'https://mui.com/production-error/?code=' + code;\n for (let i = 1; i < arguments.length; i += 1) {\n // rest params over-transpile for this case\n // eslint-disable-next-line prefer-rest-params\n url += '&args[]=' + encodeURIComponent(arguments[i]);\n }\n return 'Minified MUI error #' + code + '; visit ' + url + ' for the full message.';\n /* eslint-enable prefer-template */\n}","/**\n * @license React\n * react-is.production.min.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n'use strict';var b=Symbol.for(\"react.element\"),c=Symbol.for(\"react.portal\"),d=Symbol.for(\"react.fragment\"),e=Symbol.for(\"react.strict_mode\"),f=Symbol.for(\"react.profiler\"),g=Symbol.for(\"react.provider\"),h=Symbol.for(\"react.context\"),k=Symbol.for(\"react.server_context\"),l=Symbol.for(\"react.forward_ref\"),m=Symbol.for(\"react.suspense\"),n=Symbol.for(\"react.suspense_list\"),p=Symbol.for(\"react.memo\"),q=Symbol.for(\"react.lazy\"),t=Symbol.for(\"react.offscreen\"),u;u=Symbol.for(\"react.module.reference\");\nfunction v(a){if(\"object\"===typeof a&&null!==a){var r=a.$$typeof;switch(r){case b:switch(a=a.type,a){case d:case f:case e:case m:case n:return a;default:switch(a=a&&a.$$typeof,a){case k:case h:case l:case q:case p:case g:return a;default:return r}}case c:return r}}}exports.ContextConsumer=h;exports.ContextProvider=g;exports.Element=b;exports.ForwardRef=l;exports.Fragment=d;exports.Lazy=q;exports.Memo=p;exports.Portal=c;exports.Profiler=f;exports.StrictMode=e;exports.Suspense=m;\nexports.SuspenseList=n;exports.isAsyncMode=function(){return!1};exports.isConcurrentMode=function(){return!1};exports.isContextConsumer=function(a){return v(a)===h};exports.isContextProvider=function(a){return v(a)===g};exports.isElement=function(a){return\"object\"===typeof a&&null!==a&&a.$$typeof===b};exports.isForwardRef=function(a){return v(a)===l};exports.isFragment=function(a){return v(a)===d};exports.isLazy=function(a){return v(a)===q};exports.isMemo=function(a){return v(a)===p};\nexports.isPortal=function(a){return v(a)===c};exports.isProfiler=function(a){return v(a)===f};exports.isStrictMode=function(a){return v(a)===e};exports.isSuspense=function(a){return v(a)===m};exports.isSuspenseList=function(a){return v(a)===n};\nexports.isValidElementType=function(a){return\"string\"===typeof a||\"function\"===typeof a||a===d||a===f||a===e||a===m||a===n||a===t||\"object\"===typeof a&&null!==a&&(a.$$typeof===q||a.$$typeof===p||a.$$typeof===g||a.$$typeof===h||a.$$typeof===l||a.$$typeof===u||void 0!==a.getModuleId)?!0:!1};exports.typeOf=v;\n","/**\n * @license React\n * react-is.development.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nif (process.env.NODE_ENV !== \"production\") {\n (function() {\n'use strict';\n\n// ATTENTION\n// When adding new symbols to this file,\n// Please consider also adding to 'react-devtools-shared/src/backend/ReactSymbols'\n// The Symbol used to tag the ReactElement-like types.\nvar REACT_ELEMENT_TYPE = Symbol.for('react.element');\nvar REACT_PORTAL_TYPE = Symbol.for('react.portal');\nvar REACT_FRAGMENT_TYPE = Symbol.for('react.fragment');\nvar REACT_STRICT_MODE_TYPE = Symbol.for('react.strict_mode');\nvar REACT_PROFILER_TYPE = Symbol.for('react.profiler');\nvar REACT_PROVIDER_TYPE = Symbol.for('react.provider');\nvar REACT_CONTEXT_TYPE = Symbol.for('react.context');\nvar REACT_SERVER_CONTEXT_TYPE = Symbol.for('react.server_context');\nvar REACT_FORWARD_REF_TYPE = Symbol.for('react.forward_ref');\nvar REACT_SUSPENSE_TYPE = Symbol.for('react.suspense');\nvar REACT_SUSPENSE_LIST_TYPE = Symbol.for('react.suspense_list');\nvar REACT_MEMO_TYPE = Symbol.for('react.memo');\nvar REACT_LAZY_TYPE = Symbol.for('react.lazy');\nvar REACT_OFFSCREEN_TYPE = Symbol.for('react.offscreen');\n\n// -----------------------------------------------------------------------------\n\nvar enableScopeAPI = false; // Experimental Create Event Handle API.\nvar enableCacheElement = false;\nvar enableTransitionTracing = false; // No known bugs, but needs performance testing\n\nvar enableLegacyHidden = false; // Enables unstable_avoidThisFallback feature in Fiber\n// stuff. Intended to enable React core members to more easily debug scheduling\n// issues in DEV builds.\n\nvar enableDebugTracing = false; // Track which Fiber(s) schedule render work.\n\nvar REACT_MODULE_REFERENCE;\n\n{\n REACT_MODULE_REFERENCE = Symbol.for('react.module.reference');\n}\n\nfunction isValidElementType(type) {\n if (typeof type === 'string' || typeof type === 'function') {\n return true;\n } // Note: typeof might be other than 'symbol' or 'number' (e.g. if it's a polyfill).\n\n\n if (type === REACT_FRAGMENT_TYPE || type === REACT_PROFILER_TYPE || enableDebugTracing || type === REACT_STRICT_MODE_TYPE || type === REACT_SUSPENSE_TYPE || type === REACT_SUSPENSE_LIST_TYPE || enableLegacyHidden || type === REACT_OFFSCREEN_TYPE || enableScopeAPI || enableCacheElement || enableTransitionTracing ) {\n return true;\n }\n\n if (typeof type === 'object' && type !== null) {\n if (type.$$typeof === REACT_LAZY_TYPE || type.$$typeof === REACT_MEMO_TYPE || type.$$typeof === REACT_PROVIDER_TYPE || type.$$typeof === REACT_CONTEXT_TYPE || type.$$typeof === REACT_FORWARD_REF_TYPE || // This needs to include all possible module reference object\n // types supported by any Flight configuration anywhere since\n // we don't know which Flight build this will end up being used\n // with.\n type.$$typeof === REACT_MODULE_REFERENCE || type.getModuleId !== undefined) {\n return true;\n }\n }\n\n return false;\n}\n\nfunction typeOf(object) {\n if (typeof object === 'object' && object !== null) {\n var $$typeof = object.$$typeof;\n\n switch ($$typeof) {\n case REACT_ELEMENT_TYPE:\n var type = object.type;\n\n switch (type) {\n case REACT_FRAGMENT_TYPE:\n case REACT_PROFILER_TYPE:\n case REACT_STRICT_MODE_TYPE:\n case REACT_SUSPENSE_TYPE:\n case REACT_SUSPENSE_LIST_TYPE:\n return type;\n\n default:\n var $$typeofType = type && type.$$typeof;\n\n switch ($$typeofType) {\n case REACT_SERVER_CONTEXT_TYPE:\n case REACT_CONTEXT_TYPE:\n case REACT_FORWARD_REF_TYPE:\n case REACT_LAZY_TYPE:\n case REACT_MEMO_TYPE:\n case REACT_PROVIDER_TYPE:\n return $$typeofType;\n\n default:\n return $$typeof;\n }\n\n }\n\n case REACT_PORTAL_TYPE:\n return $$typeof;\n }\n }\n\n return undefined;\n}\nvar ContextConsumer = REACT_CONTEXT_TYPE;\nvar ContextProvider = REACT_PROVIDER_TYPE;\nvar Element = REACT_ELEMENT_TYPE;\nvar ForwardRef = REACT_FORWARD_REF_TYPE;\nvar Fragment = REACT_FRAGMENT_TYPE;\nvar Lazy = REACT_LAZY_TYPE;\nvar Memo = REACT_MEMO_TYPE;\nvar Portal = REACT_PORTAL_TYPE;\nvar Profiler = REACT_PROFILER_TYPE;\nvar StrictMode = REACT_STRICT_MODE_TYPE;\nvar Suspense = REACT_SUSPENSE_TYPE;\nvar SuspenseList = REACT_SUSPENSE_LIST_TYPE;\nvar hasWarnedAboutDeprecatedIsAsyncMode = false;\nvar hasWarnedAboutDeprecatedIsConcurrentMode = false; // AsyncMode should be deprecated\n\nfunction isAsyncMode(object) {\n {\n if (!hasWarnedAboutDeprecatedIsAsyncMode) {\n hasWarnedAboutDeprecatedIsAsyncMode = true; // Using console['warn'] to evade Babel and ESLint\n\n console['warn']('The ReactIs.isAsyncMode() alias has been deprecated, ' + 'and will be removed in React 18+.');\n }\n }\n\n return false;\n}\nfunction isConcurrentMode(object) {\n {\n if (!hasWarnedAboutDeprecatedIsConcurrentMode) {\n hasWarnedAboutDeprecatedIsConcurrentMode = true; // Using console['warn'] to evade Babel and ESLint\n\n console['warn']('The ReactIs.isConcurrentMode() alias has been deprecated, ' + 'and will be removed in React 18+.');\n }\n }\n\n return false;\n}\nfunction isContextConsumer(object) {\n return typeOf(object) === REACT_CONTEXT_TYPE;\n}\nfunction isContextProvider(object) {\n return typeOf(object) === REACT_PROVIDER_TYPE;\n}\nfunction isElement(object) {\n return typeof object === 'object' && object !== null && object.$$typeof === REACT_ELEMENT_TYPE;\n}\nfunction isForwardRef(object) {\n return typeOf(object) === REACT_FORWARD_REF_TYPE;\n}\nfunction isFragment(object) {\n return typeOf(object) === REACT_FRAGMENT_TYPE;\n}\nfunction isLazy(object) {\n return typeOf(object) === REACT_LAZY_TYPE;\n}\nfunction isMemo(object) {\n return typeOf(object) === REACT_MEMO_TYPE;\n}\nfunction isPortal(object) {\n return typeOf(object) === REACT_PORTAL_TYPE;\n}\nfunction isProfiler(object) {\n return typeOf(object) === REACT_PROFILER_TYPE;\n}\nfunction isStrictMode(object) {\n return typeOf(object) === REACT_STRICT_MODE_TYPE;\n}\nfunction isSuspense(object) {\n return typeOf(object) === REACT_SUSPENSE_TYPE;\n}\nfunction isSuspenseList(object) {\n return typeOf(object) === REACT_SUSPENSE_LIST_TYPE;\n}\n\nexports.ContextConsumer = ContextConsumer;\nexports.ContextProvider = ContextProvider;\nexports.Element = Element;\nexports.ForwardRef = ForwardRef;\nexports.Fragment = Fragment;\nexports.Lazy = Lazy;\nexports.Memo = Memo;\nexports.Portal = Portal;\nexports.Profiler = Profiler;\nexports.StrictMode = StrictMode;\nexports.Suspense = Suspense;\nexports.SuspenseList = SuspenseList;\nexports.isAsyncMode = isAsyncMode;\nexports.isConcurrentMode = isConcurrentMode;\nexports.isContextConsumer = isContextConsumer;\nexports.isContextProvider = isContextProvider;\nexports.isElement = isElement;\nexports.isForwardRef = isForwardRef;\nexports.isFragment = isFragment;\nexports.isLazy = isLazy;\nexports.isMemo = isMemo;\nexports.isPortal = isPortal;\nexports.isProfiler = isProfiler;\nexports.isStrictMode = isStrictMode;\nexports.isSuspense = isSuspense;\nexports.isSuspenseList = isSuspenseList;\nexports.isValidElementType = isValidElementType;\nexports.typeOf = typeOf;\n })();\n}\n","'use strict';\n\nif (process.env.NODE_ENV === 'production') {\n module.exports = require('./cjs/react-is.production.min.js');\n} else {\n module.exports = require('./cjs/react-is.development.js');\n}\n","import { ForwardRef, Memo } from 'react-is';\n\n// Simplified polyfill for IE11 support\n// https://github.com/JamesMGreene/Function.name/blob/58b314d4a983110c3682f1228f845d39ccca1817/Function.name.js#L3\nconst fnNameMatchRegex = /^\\s*function(?:\\s|\\s*\\/\\*.*\\*\\/\\s*)+([^(\\s/]*)\\s*/;\nexport function getFunctionName(fn) {\n const match = `${fn}`.match(fnNameMatchRegex);\n const name = match && match[1];\n return name || '';\n}\nfunction getFunctionComponentName(Component, fallback = '') {\n return Component.displayName || Component.name || getFunctionName(Component) || fallback;\n}\nfunction getWrappedName(outerType, innerType, wrapperName) {\n const functionName = getFunctionComponentName(innerType);\n return outerType.displayName || (functionName !== '' ? `${wrapperName}(${functionName})` : wrapperName);\n}\n\n/**\n * cherry-pick from\n * https://github.com/facebook/react/blob/769b1f270e1251d9dbdce0fcbd9e92e502d059b8/packages/shared/getComponentName.js\n * originally forked from recompose/getDisplayName with added IE11 support\n */\nexport default function getDisplayName(Component) {\n if (Component == null) {\n return undefined;\n }\n if (typeof Component === 'string') {\n return Component;\n }\n if (typeof Component === 'function') {\n return getFunctionComponentName(Component, 'Component');\n }\n\n // TypeScript can't have components as objects but they exist in the form of `memo` or `Suspense`\n if (typeof Component === 'object') {\n switch (Component.$$typeof) {\n case ForwardRef:\n return getWrappedName(Component, Component.render, 'ForwardRef');\n case Memo:\n return getWrappedName(Component, Component.type, 'memo');\n default:\n return undefined;\n }\n }\n return undefined;\n}","export default function HTMLElementType(props, propName, componentName, location, propFullName) {\n if (process.env.NODE_ENV === 'production') {\n return null;\n }\n const propValue = props[propName];\n const safePropName = propFullName || propName;\n if (propValue == null) {\n return null;\n }\n if (propValue && propValue.nodeType !== 1) {\n return new Error(`Invalid ${location} \\`${safePropName}\\` supplied to \\`${componentName}\\`. ` + `Expected an HTMLElement.`);\n }\n return null;\n}","import PropTypes from 'prop-types';\nconst refType = PropTypes.oneOfType([PropTypes.func, PropTypes.object]);\nexport default refType;","import _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\n// It should to be noted that this function isn't equivalent to `text-transform: capitalize`.\n//\n// A strict capitalization should uppercase the first letter of each word in the sentence.\n// We only handle the first word.\nexport default function capitalize(string) {\n if (typeof string !== 'string') {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: \\`capitalize(string)\\` expects a string argument.` : _formatMuiErrorMessage(7));\n }\n return string.charAt(0).toUpperCase() + string.slice(1);\n}","/**\n * Safe chained function.\n *\n * Will only create a new function if needed,\n * otherwise will pass back existing functions or null.\n */\nexport default function createChainedFunction(...funcs) {\n return funcs.reduce((acc, func) => {\n if (func == null) {\n return acc;\n }\n return function chainedFunction(...args) {\n acc.apply(this, args);\n func.apply(this, args);\n };\n }, () => {});\n}","// Corresponds to 10 frames at 60 Hz.\n// A few bytes payload overhead when lodash/debounce is ~3 kB and debounce ~300 B.\nexport default function debounce(func, wait = 166) {\n let timeout;\n function debounced(...args) {\n const later = () => {\n // @ts-ignore\n func.apply(this, args);\n };\n clearTimeout(timeout);\n timeout = setTimeout(later, wait);\n }\n debounced.clear = () => {\n clearTimeout(timeout);\n };\n return debounced;\n}","export default function deprecatedPropType(validator, reason) {\n if (process.env.NODE_ENV === 'production') {\n return () => null;\n }\n return (props, propName, componentName, location, propFullName) => {\n const componentNameSafe = componentName || '<>';\n const propFullNameSafe = propFullName || propName;\n if (typeof props[propName] !== 'undefined') {\n return new Error(`The ${location} \\`${propFullNameSafe}\\` of ` + `\\`${componentNameSafe}\\` is deprecated. ${reason}`);\n }\n return null;\n };\n}","import * as React from 'react';\nexport default function isMuiElement(element, muiNames) {\n var _muiName, _element$type;\n return /*#__PURE__*/React.isValidElement(element) && muiNames.indexOf( // For server components `muiName` is avaialble in element.type._payload.value.muiName\n // relevant info - https://github.com/facebook/react/blob/2807d781a08db8e9873687fccc25c0f12b4fb3d4/packages/react/src/ReactLazy.js#L45\n // eslint-disable-next-line no-underscore-dangle\n (_muiName = element.type.muiName) != null ? _muiName : (_element$type = element.type) == null || (_element$type = _element$type._payload) == null || (_element$type = _element$type.value) == null ? void 0 : _element$type.muiName) !== -1;\n}","export default function ownerDocument(node) {\n return node && node.ownerDocument || document;\n}","import ownerDocument from '../ownerDocument';\nexport default function ownerWindow(node) {\n const doc = ownerDocument(node);\n return doc.defaultView || window;\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nexport default function requirePropFactory(componentNameInError, Component) {\n if (process.env.NODE_ENV === 'production') {\n return () => null;\n }\n\n // eslint-disable-next-line react/forbid-foreign-prop-types\n const prevPropTypes = Component ? _extends({}, Component.propTypes) : null;\n const requireProp = requiredProp => (props, propName, componentName, location, propFullName, ...args) => {\n const propFullNameSafe = propFullName || propName;\n const defaultTypeChecker = prevPropTypes == null ? void 0 : prevPropTypes[propFullNameSafe];\n if (defaultTypeChecker) {\n const typeCheckerResult = defaultTypeChecker(props, propName, componentName, location, propFullName, ...args);\n if (typeCheckerResult) {\n return typeCheckerResult;\n }\n }\n if (typeof props[propName] !== 'undefined' && !props[requiredProp]) {\n return new Error(`The prop \\`${propFullNameSafe}\\` of ` + `\\`${componentNameInError}\\` can only be used together with the \\`${requiredProp}\\` prop.`);\n }\n return null;\n };\n return requireProp;\n}","/**\n * TODO v5: consider making it private\n *\n * passes {value} to {ref}\n *\n * WARNING: Be sure to only call this inside a callback that is passed as a ref.\n * Otherwise, make sure to cleanup the previous {ref} if it changes. See\n * https://github.com/mui/material-ui/issues/13539\n *\n * Useful if you want to expose the ref of an inner component to the public API\n * while still using it inside the component.\n * @param ref A ref callback or ref object. If anything falsy, this is a no-op.\n */\nexport default function setRef(ref, value) {\n if (typeof ref === 'function') {\n ref(value);\n } else if (ref) {\n ref.current = value;\n }\n}","'use client';\n\nimport * as React from 'react';\n\n/**\n * A version of `React.useLayoutEffect` that does not show a warning when server-side rendering.\n * This is useful for effects that are only needed for client-side rendering but not for SSR.\n *\n * Before you use this hook, make sure to read https://gist.github.com/gaearon/e7d97cdf38a2907924ea12e4ebdf3c85\n * and confirm it doesn't apply to your use-case.\n */\nconst useEnhancedEffect = typeof window !== 'undefined' ? React.useLayoutEffect : React.useEffect;\nexport default useEnhancedEffect;","'use client';\n\nimport * as React from 'react';\nlet globalId = 0;\nfunction useGlobalId(idOverride) {\n const [defaultId, setDefaultId] = React.useState(idOverride);\n const id = idOverride || defaultId;\n React.useEffect(() => {\n if (defaultId == null) {\n // Fallback to this default id when possible.\n // Use the incrementing value for client-side rendering only.\n // We can't use it server-side.\n // If you want to use random values please consider the Birthday Problem: https://en.wikipedia.org/wiki/Birthday_problem\n globalId += 1;\n setDefaultId(`mui-${globalId}`);\n }\n }, [defaultId]);\n return id;\n}\n\n// downstream bundlers may remove unnecessary concatenation, but won't remove toString call -- Workaround for https://github.com/webpack/webpack/issues/14814\nconst maybeReactUseId = React['useId'.toString()];\n/**\n *\n * @example
    \n * @param idOverride\n * @returns {string}\n */\nexport default function useId(idOverride) {\n if (maybeReactUseId !== undefined) {\n const reactId = maybeReactUseId();\n return idOverride != null ? idOverride : reactId;\n }\n // eslint-disable-next-line react-hooks/rules-of-hooks -- `React.useId` is invariant at runtime.\n return useGlobalId(idOverride);\n}","export default function unsupportedProp(props, propName, componentName, location, propFullName) {\n if (process.env.NODE_ENV === 'production') {\n return null;\n }\n const propFullNameSafe = propFullName || propName;\n if (typeof props[propName] !== 'undefined') {\n return new Error(`The prop \\`${propFullNameSafe}\\` is not supported. Please remove it.`);\n }\n return null;\n}","'use client';\n\n/* eslint-disable react-hooks/rules-of-hooks, react-hooks/exhaustive-deps */\nimport * as React from 'react';\nexport default function useControlled({\n controlled,\n default: defaultProp,\n name,\n state = 'value'\n}) {\n // isControlled is ignored in the hook dependency lists as it should never change.\n const {\n current: isControlled\n } = React.useRef(controlled !== undefined);\n const [valueState, setValue] = React.useState(defaultProp);\n const value = isControlled ? controlled : valueState;\n if (process.env.NODE_ENV !== 'production') {\n React.useEffect(() => {\n if (isControlled !== (controlled !== undefined)) {\n console.error([`MUI: A component is changing the ${isControlled ? '' : 'un'}controlled ${state} state of ${name} to be ${isControlled ? 'un' : ''}controlled.`, 'Elements should not switch from uncontrolled to controlled (or vice versa).', `Decide between using a controlled or uncontrolled ${name} ` + 'element for the lifetime of the component.', \"The nature of the state is determined during the first render. It's considered controlled if the value is not `undefined`.\", 'More info: https://fb.me/react-controlled-components'].join('\\n'));\n }\n }, [state, name, controlled]);\n const {\n current: defaultValue\n } = React.useRef(defaultProp);\n React.useEffect(() => {\n if (!isControlled && defaultValue !== defaultProp) {\n console.error([`MUI: A component is changing the default ${state} state of an uncontrolled ${name} after being initialized. ` + `To suppress this warning opt to use a controlled ${name}.`].join('\\n'));\n }\n }, [JSON.stringify(defaultProp)]);\n }\n const setValueIfUncontrolled = React.useCallback(newValue => {\n if (!isControlled) {\n setValue(newValue);\n }\n }, []);\n return [value, setValueIfUncontrolled];\n}","'use client';\n\nimport * as React from 'react';\nimport useEnhancedEffect from '../useEnhancedEffect';\n\n/**\n * Inspired by https://github.com/facebook/react/issues/14099#issuecomment-440013892\n * See RFC in https://github.com/reactjs/rfcs/pull/220\n */\n\nfunction useEventCallback(fn) {\n const ref = React.useRef(fn);\n useEnhancedEffect(() => {\n ref.current = fn;\n });\n return React.useRef((...args) =>\n // @ts-expect-error hide `this`\n (0, ref.current)(...args)).current;\n}\nexport default useEventCallback;","'use client';\n\nimport * as React from 'react';\nimport setRef from '../setRef';\nexport default function useForkRef(...refs) {\n /**\n * This will create a new function if the refs passed to this hook change and are all defined.\n * This means react will call the old forkRef with `null` and the new forkRef\n * with the ref. Cleanup naturally emerges from this behavior.\n */\n return React.useMemo(() => {\n if (refs.every(ref => ref == null)) {\n return null;\n }\n return instance => {\n refs.forEach(ref => {\n setRef(ref, instance);\n });\n };\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, refs);\n}","'use client';\n\nimport * as React from 'react';\nconst UNINITIALIZED = {};\n\n/**\n * A React.useRef() that is initialized lazily with a function. Note that it accepts an optional\n * initialization argument, so the initialization function doesn't need to be an inline closure.\n *\n * @usage\n * const ref = useLazyRef(sortColumns, columns)\n */\nexport default function useLazyRef(init, initArg) {\n const ref = React.useRef(UNINITIALIZED);\n if (ref.current === UNINITIALIZED) {\n ref.current = init(initArg);\n }\n return ref;\n}","'use client';\n\nimport * as React from 'react';\nconst EMPTY = [];\n\n/**\n * A React.useEffect equivalent that runs once, when the component is mounted.\n */\nexport default function useOnMount(fn) {\n /* eslint-disable react-hooks/exhaustive-deps */\n React.useEffect(fn, EMPTY);\n /* eslint-enable react-hooks/exhaustive-deps */\n}","'use client';\n\nimport useLazyRef from '../useLazyRef/useLazyRef';\nimport useOnMount from '../useOnMount/useOnMount';\nexport class Timeout {\n constructor() {\n this.currentId = null;\n this.clear = () => {\n if (this.currentId !== null) {\n clearTimeout(this.currentId);\n this.currentId = null;\n }\n };\n this.disposeEffect = () => {\n return this.clear;\n };\n }\n static create() {\n return new Timeout();\n }\n /**\n * Executes `fn` after `delay`, clearing any previously scheduled call.\n */\n start(delay, fn) {\n this.clear();\n this.currentId = setTimeout(() => {\n this.currentId = null;\n fn();\n }, delay);\n }\n}\nexport default function useTimeout() {\n const timeout = useLazyRef(Timeout.create).current;\n useOnMount(timeout.disposeEffect);\n return timeout;\n}","'use client';\n\n// based on https://github.com/WICG/focus-visible/blob/v4.1.5/src/focus-visible.js\nimport * as React from 'react';\nimport { Timeout } from '../useTimeout/useTimeout';\nlet hadKeyboardEvent = true;\nlet hadFocusVisibleRecently = false;\nconst hadFocusVisibleRecentlyTimeout = new Timeout();\nconst inputTypesWhitelist = {\n text: true,\n search: true,\n url: true,\n tel: true,\n email: true,\n password: true,\n number: true,\n date: true,\n month: true,\n week: true,\n time: true,\n datetime: true,\n 'datetime-local': true\n};\n\n/**\n * Computes whether the given element should automatically trigger the\n * `focus-visible` class being added, i.e. whether it should always match\n * `:focus-visible` when focused.\n * @param {Element} node\n * @returns {boolean}\n */\nfunction focusTriggersKeyboardModality(node) {\n const {\n type,\n tagName\n } = node;\n if (tagName === 'INPUT' && inputTypesWhitelist[type] && !node.readOnly) {\n return true;\n }\n if (tagName === 'TEXTAREA' && !node.readOnly) {\n return true;\n }\n if (node.isContentEditable) {\n return true;\n }\n return false;\n}\n\n/**\n * Keep track of our keyboard modality state with `hadKeyboardEvent`.\n * If the most recent user interaction was via the keyboard;\n * and the key press did not include a meta, alt/option, or control key;\n * then the modality is keyboard. Otherwise, the modality is not keyboard.\n * @param {KeyboardEvent} event\n */\nfunction handleKeyDown(event) {\n if (event.metaKey || event.altKey || event.ctrlKey) {\n return;\n }\n hadKeyboardEvent = true;\n}\n\n/**\n * If at any point a user clicks with a pointing device, ensure that we change\n * the modality away from keyboard.\n * This avoids the situation where a user presses a key on an already focused\n * element, and then clicks on a different element, focusing it with a\n * pointing device, while we still think we're in keyboard modality.\n */\nfunction handlePointerDown() {\n hadKeyboardEvent = false;\n}\nfunction handleVisibilityChange() {\n if (this.visibilityState === 'hidden') {\n // If the tab becomes active again, the browser will handle calling focus\n // on the element (Safari actually calls it twice).\n // If this tab change caused a blur on an element with focus-visible,\n // re-apply the class when the user switches back to the tab.\n if (hadFocusVisibleRecently) {\n hadKeyboardEvent = true;\n }\n }\n}\nfunction prepare(doc) {\n doc.addEventListener('keydown', handleKeyDown, true);\n doc.addEventListener('mousedown', handlePointerDown, true);\n doc.addEventListener('pointerdown', handlePointerDown, true);\n doc.addEventListener('touchstart', handlePointerDown, true);\n doc.addEventListener('visibilitychange', handleVisibilityChange, true);\n}\nexport function teardown(doc) {\n doc.removeEventListener('keydown', handleKeyDown, true);\n doc.removeEventListener('mousedown', handlePointerDown, true);\n doc.removeEventListener('pointerdown', handlePointerDown, true);\n doc.removeEventListener('touchstart', handlePointerDown, true);\n doc.removeEventListener('visibilitychange', handleVisibilityChange, true);\n}\nfunction isFocusVisible(event) {\n const {\n target\n } = event;\n try {\n return target.matches(':focus-visible');\n } catch (error) {\n // Browsers not implementing :focus-visible will throw a SyntaxError.\n // We use our own heuristic for those browsers.\n // Rethrow might be better if it's not the expected error but do we really\n // want to crash if focus-visible malfunctioned?\n }\n\n // No need for validFocusTarget check. The user does that by attaching it to\n // focusable events only.\n return hadKeyboardEvent || focusTriggersKeyboardModality(target);\n}\nexport default function useIsFocusVisible() {\n const ref = React.useCallback(node => {\n if (node != null) {\n prepare(node.ownerDocument);\n }\n }, []);\n const isFocusVisibleRef = React.useRef(false);\n\n /**\n * Should be called if a blur event is fired\n */\n function handleBlurVisible() {\n // checking against potential state variable does not suffice if we focus and blur synchronously.\n // React wouldn't have time to trigger a re-render so `focusVisible` would be stale.\n // Ideally we would adjust `isFocusVisible(event)` to look at `relatedTarget` for blur events.\n // This doesn't work in IE11 due to https://github.com/facebook/react/issues/3751\n // TODO: check again if React releases their internal changes to focus event handling (https://github.com/facebook/react/pull/19186).\n if (isFocusVisibleRef.current) {\n // To detect a tab/window switch, we look for a blur event followed\n // rapidly by a visibility change.\n // If we don't see a visibility change within 100ms, it's probably a\n // regular focus change.\n hadFocusVisibleRecently = true;\n hadFocusVisibleRecentlyTimeout.start(100, () => {\n hadFocusVisibleRecently = false;\n });\n isFocusVisibleRef.current = false;\n return true;\n }\n return false;\n }\n\n /**\n * Should be called if a blur event is fired\n */\n function handleFocusVisible(event) {\n if (isFocusVisible(event)) {\n isFocusVisibleRef.current = true;\n return true;\n }\n return false;\n }\n return {\n isFocusVisibleRef,\n onFocus: handleFocusVisible,\n onBlur: handleBlurVisible,\n ref\n };\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\n/**\n * Add keys, values of `defaultProps` that does not exist in `props`\n * @param {object} defaultProps\n * @param {object} props\n * @returns {object} resolved props\n */\nexport default function resolveProps(defaultProps, props) {\n const output = _extends({}, props);\n Object.keys(defaultProps).forEach(propName => {\n if (propName.toString().match(/^(components|slots)$/)) {\n output[propName] = _extends({}, defaultProps[propName], output[propName]);\n } else if (propName.toString().match(/^(componentsProps|slotProps)$/)) {\n const defaultSlotProps = defaultProps[propName] || {};\n const slotProps = props[propName];\n output[propName] = {};\n if (!slotProps || !Object.keys(slotProps)) {\n // Reduce the iteration if the slot props is empty\n output[propName] = defaultSlotProps;\n } else if (!defaultSlotProps || !Object.keys(defaultSlotProps)) {\n // Reduce the iteration if the default slot props is empty\n output[propName] = slotProps;\n } else {\n output[propName] = _extends({}, slotProps);\n Object.keys(defaultSlotProps).forEach(slotPropName => {\n output[propName][slotPropName] = resolveProps(defaultSlotProps[slotPropName], slotProps[slotPropName]);\n });\n }\n } else if (output[propName] === undefined) {\n output[propName] = defaultProps[propName];\n }\n });\n return output;\n}","export default function composeClasses(slots, getUtilityClass, classes = undefined) {\n const output = {};\n Object.keys(slots).forEach(\n // `Object.keys(slots)` can't be wider than `T` because we infer `T` from `slots`.\n // @ts-expect-error https://github.com/microsoft/TypeScript/pull/12253#issuecomment-263132208\n slot => {\n output[slot] = slots[slot].reduce((acc, key) => {\n if (key) {\n const utilityClass = getUtilityClass(key);\n if (utilityClass !== '') {\n acc.push(utilityClass);\n }\n if (classes && classes[key]) {\n acc.push(classes[key]);\n }\n }\n return acc;\n }, []).join(' ');\n });\n return output;\n}","const defaultGenerator = componentName => componentName;\nconst createClassNameGenerator = () => {\n let generate = defaultGenerator;\n return {\n configure(generator) {\n generate = generator;\n },\n generate(componentName) {\n return generate(componentName);\n },\n reset() {\n generate = defaultGenerator;\n }\n };\n};\nconst ClassNameGenerator = createClassNameGenerator();\nexport default ClassNameGenerator;","import ClassNameGenerator from '../ClassNameGenerator';\nexport const globalStateClasses = {\n active: 'active',\n checked: 'checked',\n completed: 'completed',\n disabled: 'disabled',\n error: 'error',\n expanded: 'expanded',\n focused: 'focused',\n focusVisible: 'focusVisible',\n open: 'open',\n readOnly: 'readOnly',\n required: 'required',\n selected: 'selected'\n};\nexport default function generateUtilityClass(componentName, slot, globalStatePrefix = 'Mui') {\n const globalStateClass = globalStateClasses[slot];\n return globalStateClass ? `${globalStatePrefix}-${globalStateClass}` : `${ClassNameGenerator.generate(componentName)}-${slot}`;\n}\nexport function isGlobalState(slot) {\n return globalStateClasses[slot] !== undefined;\n}","import generateUtilityClass from '../generateUtilityClass';\nexport default function generateUtilityClasses(componentName, slots, globalStatePrefix = 'Mui') {\n const result = {};\n slots.forEach(slot => {\n result[slot] = generateUtilityClass(componentName, slot, globalStatePrefix);\n });\n return result;\n}","function clamp(val, min = Number.MIN_SAFE_INTEGER, max = Number.MAX_SAFE_INTEGER) {\n return Math.max(min, Math.min(val, max));\n}\nexport default clamp;","export default function _objectWithoutPropertiesLoose(source, excluded) {\n if (source == null) return {};\n var target = {};\n var sourceKeys = Object.keys(source);\n var key, i;\n for (i = 0; i < sourceKeys.length; i++) {\n key = sourceKeys[i];\n if (excluded.indexOf(key) >= 0) continue;\n target[key] = source[key];\n }\n return target;\n}","import _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nconst _excluded = [\"values\", \"unit\", \"step\"];\n// Sorted ASC by size. That's important.\n// It can't be configured as it's used statically for propTypes.\nexport const breakpointKeys = ['xs', 'sm', 'md', 'lg', 'xl'];\nconst sortBreakpointsValues = values => {\n const breakpointsAsArray = Object.keys(values).map(key => ({\n key,\n val: values[key]\n })) || [];\n // Sort in ascending order\n breakpointsAsArray.sort((breakpoint1, breakpoint2) => breakpoint1.val - breakpoint2.val);\n return breakpointsAsArray.reduce((acc, obj) => {\n return _extends({}, acc, {\n [obj.key]: obj.val\n });\n }, {});\n};\n\n// Keep in mind that @media is inclusive by the CSS specification.\nexport default function createBreakpoints(breakpoints) {\n const {\n // The breakpoint **start** at this value.\n // For instance with the first breakpoint xs: [xs, sm).\n values = {\n xs: 0,\n // phone\n sm: 600,\n // tablet\n md: 900,\n // small laptop\n lg: 1200,\n // desktop\n xl: 1536 // large screen\n },\n unit = 'px',\n step = 5\n } = breakpoints,\n other = _objectWithoutPropertiesLoose(breakpoints, _excluded);\n const sortedValues = sortBreakpointsValues(values);\n const keys = Object.keys(sortedValues);\n function up(key) {\n const value = typeof values[key] === 'number' ? values[key] : key;\n return `@media (min-width:${value}${unit})`;\n }\n function down(key) {\n const value = typeof values[key] === 'number' ? values[key] : key;\n return `@media (max-width:${value - step / 100}${unit})`;\n }\n function between(start, end) {\n const endIndex = keys.indexOf(end);\n return `@media (min-width:${typeof values[start] === 'number' ? values[start] : start}${unit}) and ` + `(max-width:${(endIndex !== -1 && typeof values[keys[endIndex]] === 'number' ? values[keys[endIndex]] : end) - step / 100}${unit})`;\n }\n function only(key) {\n if (keys.indexOf(key) + 1 < keys.length) {\n return between(key, keys[keys.indexOf(key) + 1]);\n }\n return up(key);\n }\n function not(key) {\n // handle first and last key separately, for better readability\n const keyIndex = keys.indexOf(key);\n if (keyIndex === 0) {\n return up(keys[1]);\n }\n if (keyIndex === keys.length - 1) {\n return down(keys[keyIndex]);\n }\n return between(key, keys[keys.indexOf(key) + 1]).replace('@media', '@media not all and');\n }\n return _extends({\n keys,\n values: sortedValues,\n up,\n down,\n between,\n only,\n not,\n unit\n }, other);\n}","const shape = {\n borderRadius: 4\n};\nexport default shape;","import PropTypes from 'prop-types';\nconst responsivePropType = process.env.NODE_ENV !== 'production' ? PropTypes.oneOfType([PropTypes.number, PropTypes.string, PropTypes.object, PropTypes.array]) : {};\nexport default responsivePropType;","import deepmerge from '@mui/utils/deepmerge';\nfunction merge(acc, item) {\n if (!item) {\n return acc;\n }\n return deepmerge(acc, item, {\n clone: false // No need to clone deep, it's way faster.\n });\n}\nexport default merge;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport PropTypes from 'prop-types';\nimport deepmerge from '@mui/utils/deepmerge';\nimport merge from './merge';\n\n// The breakpoint **start** at this value.\n// For instance with the first breakpoint xs: [xs, sm[.\nexport const values = {\n xs: 0,\n // phone\n sm: 600,\n // tablet\n md: 900,\n // small laptop\n lg: 1200,\n // desktop\n xl: 1536 // large screen\n};\nconst defaultBreakpoints = {\n // Sorted ASC by size. That's important.\n // It can't be configured as it's used statically for propTypes.\n keys: ['xs', 'sm', 'md', 'lg', 'xl'],\n up: key => `@media (min-width:${values[key]}px)`\n};\nexport function handleBreakpoints(props, propValue, styleFromPropValue) {\n const theme = props.theme || {};\n if (Array.isArray(propValue)) {\n const themeBreakpoints = theme.breakpoints || defaultBreakpoints;\n return propValue.reduce((acc, item, index) => {\n acc[themeBreakpoints.up(themeBreakpoints.keys[index])] = styleFromPropValue(propValue[index]);\n return acc;\n }, {});\n }\n if (typeof propValue === 'object') {\n const themeBreakpoints = theme.breakpoints || defaultBreakpoints;\n return Object.keys(propValue).reduce((acc, breakpoint) => {\n // key is breakpoint\n if (Object.keys(themeBreakpoints.values || values).indexOf(breakpoint) !== -1) {\n const mediaKey = themeBreakpoints.up(breakpoint);\n acc[mediaKey] = styleFromPropValue(propValue[breakpoint], breakpoint);\n } else {\n const cssKey = breakpoint;\n acc[cssKey] = propValue[cssKey];\n }\n return acc;\n }, {});\n }\n const output = styleFromPropValue(propValue);\n return output;\n}\nfunction breakpoints(styleFunction) {\n // false positive\n // eslint-disable-next-line react/function-component-definition\n const newStyleFunction = props => {\n const theme = props.theme || {};\n const base = styleFunction(props);\n const themeBreakpoints = theme.breakpoints || defaultBreakpoints;\n const extended = themeBreakpoints.keys.reduce((acc, key) => {\n if (props[key]) {\n acc = acc || {};\n acc[themeBreakpoints.up(key)] = styleFunction(_extends({\n theme\n }, props[key]));\n }\n return acc;\n }, null);\n return merge(base, extended);\n };\n newStyleFunction.propTypes = process.env.NODE_ENV !== 'production' ? _extends({}, styleFunction.propTypes, {\n xs: PropTypes.object,\n sm: PropTypes.object,\n md: PropTypes.object,\n lg: PropTypes.object,\n xl: PropTypes.object\n }) : {};\n newStyleFunction.filterProps = ['xs', 'sm', 'md', 'lg', 'xl', ...styleFunction.filterProps];\n return newStyleFunction;\n}\nexport function createEmptyBreakpointObject(breakpointsInput = {}) {\n var _breakpointsInput$key;\n const breakpointsInOrder = (_breakpointsInput$key = breakpointsInput.keys) == null ? void 0 : _breakpointsInput$key.reduce((acc, key) => {\n const breakpointStyleKey = breakpointsInput.up(key);\n acc[breakpointStyleKey] = {};\n return acc;\n }, {});\n return breakpointsInOrder || {};\n}\nexport function removeUnusedBreakpoints(breakpointKeys, style) {\n return breakpointKeys.reduce((acc, key) => {\n const breakpointOutput = acc[key];\n const isBreakpointUnused = !breakpointOutput || Object.keys(breakpointOutput).length === 0;\n if (isBreakpointUnused) {\n delete acc[key];\n }\n return acc;\n }, style);\n}\nexport function mergeBreakpointsInOrder(breakpointsInput, ...styles) {\n const emptyBreakpoints = createEmptyBreakpointObject(breakpointsInput);\n const mergedOutput = [emptyBreakpoints, ...styles].reduce((prev, next) => deepmerge(prev, next), {});\n return removeUnusedBreakpoints(Object.keys(emptyBreakpoints), mergedOutput);\n}\n\n// compute base for responsive values; e.g.,\n// [1,2,3] => {xs: true, sm: true, md: true}\n// {xs: 1, sm: 2, md: 3} => {xs: true, sm: true, md: true}\nexport function computeBreakpointsBase(breakpointValues, themeBreakpoints) {\n // fixed value\n if (typeof breakpointValues !== 'object') {\n return {};\n }\n const base = {};\n const breakpointsKeys = Object.keys(themeBreakpoints);\n if (Array.isArray(breakpointValues)) {\n breakpointsKeys.forEach((breakpoint, i) => {\n if (i < breakpointValues.length) {\n base[breakpoint] = true;\n }\n });\n } else {\n breakpointsKeys.forEach(breakpoint => {\n if (breakpointValues[breakpoint] != null) {\n base[breakpoint] = true;\n }\n });\n }\n return base;\n}\nexport function resolveBreakpointValues({\n values: breakpointValues,\n breakpoints: themeBreakpoints,\n base: customBase\n}) {\n const base = customBase || computeBreakpointsBase(breakpointValues, themeBreakpoints);\n const keys = Object.keys(base);\n if (keys.length === 0) {\n return breakpointValues;\n }\n let previous;\n return keys.reduce((acc, breakpoint, i) => {\n if (Array.isArray(breakpointValues)) {\n acc[breakpoint] = breakpointValues[i] != null ? breakpointValues[i] : breakpointValues[previous];\n previous = i;\n } else if (typeof breakpointValues === 'object') {\n acc[breakpoint] = breakpointValues[breakpoint] != null ? breakpointValues[breakpoint] : breakpointValues[previous];\n previous = breakpoint;\n } else {\n acc[breakpoint] = breakpointValues;\n }\n return acc;\n }, {});\n}\nexport default breakpoints;","import capitalize from '@mui/utils/capitalize';\nimport responsivePropType from './responsivePropType';\nimport { handleBreakpoints } from './breakpoints';\nexport function getPath(obj, path, checkVars = true) {\n if (!path || typeof path !== 'string') {\n return null;\n }\n\n // Check if CSS variables are used\n if (obj && obj.vars && checkVars) {\n const val = `vars.${path}`.split('.').reduce((acc, item) => acc && acc[item] ? acc[item] : null, obj);\n if (val != null) {\n return val;\n }\n }\n return path.split('.').reduce((acc, item) => {\n if (acc && acc[item] != null) {\n return acc[item];\n }\n return null;\n }, obj);\n}\nexport function getStyleValue(themeMapping, transform, propValueFinal, userValue = propValueFinal) {\n let value;\n if (typeof themeMapping === 'function') {\n value = themeMapping(propValueFinal);\n } else if (Array.isArray(themeMapping)) {\n value = themeMapping[propValueFinal] || userValue;\n } else {\n value = getPath(themeMapping, propValueFinal) || userValue;\n }\n if (transform) {\n value = transform(value, userValue, themeMapping);\n }\n return value;\n}\nfunction style(options) {\n const {\n prop,\n cssProperty = options.prop,\n themeKey,\n transform\n } = options;\n\n // false positive\n // eslint-disable-next-line react/function-component-definition\n const fn = props => {\n if (props[prop] == null) {\n return null;\n }\n const propValue = props[prop];\n const theme = props.theme;\n const themeMapping = getPath(theme, themeKey) || {};\n const styleFromPropValue = propValueFinal => {\n let value = getStyleValue(themeMapping, transform, propValueFinal);\n if (propValueFinal === value && typeof propValueFinal === 'string') {\n // Haven't found value\n value = getStyleValue(themeMapping, transform, `${prop}${propValueFinal === 'default' ? '' : capitalize(propValueFinal)}`, propValueFinal);\n }\n if (cssProperty === false) {\n return value;\n }\n return {\n [cssProperty]: value\n };\n };\n return handleBreakpoints(props, propValue, styleFromPropValue);\n };\n fn.propTypes = process.env.NODE_ENV !== 'production' ? {\n [prop]: responsivePropType\n } : {};\n fn.filterProps = [prop];\n return fn;\n}\nexport default style;","export default function memoize(fn) {\n const cache = {};\n return arg => {\n if (cache[arg] === undefined) {\n cache[arg] = fn(arg);\n }\n return cache[arg];\n };\n}","import responsivePropType from './responsivePropType';\nimport { handleBreakpoints } from './breakpoints';\nimport { getPath } from './style';\nimport merge from './merge';\nimport memoize from './memoize';\nconst properties = {\n m: 'margin',\n p: 'padding'\n};\nconst directions = {\n t: 'Top',\n r: 'Right',\n b: 'Bottom',\n l: 'Left',\n x: ['Left', 'Right'],\n y: ['Top', 'Bottom']\n};\nconst aliases = {\n marginX: 'mx',\n marginY: 'my',\n paddingX: 'px',\n paddingY: 'py'\n};\n\n// memoize() impact:\n// From 300,000 ops/sec\n// To 350,000 ops/sec\nconst getCssProperties = memoize(prop => {\n // It's not a shorthand notation.\n if (prop.length > 2) {\n if (aliases[prop]) {\n prop = aliases[prop];\n } else {\n return [prop];\n }\n }\n const [a, b] = prop.split('');\n const property = properties[a];\n const direction = directions[b] || '';\n return Array.isArray(direction) ? direction.map(dir => property + dir) : [property + direction];\n});\nexport const marginKeys = ['m', 'mt', 'mr', 'mb', 'ml', 'mx', 'my', 'margin', 'marginTop', 'marginRight', 'marginBottom', 'marginLeft', 'marginX', 'marginY', 'marginInline', 'marginInlineStart', 'marginInlineEnd', 'marginBlock', 'marginBlockStart', 'marginBlockEnd'];\nexport const paddingKeys = ['p', 'pt', 'pr', 'pb', 'pl', 'px', 'py', 'padding', 'paddingTop', 'paddingRight', 'paddingBottom', 'paddingLeft', 'paddingX', 'paddingY', 'paddingInline', 'paddingInlineStart', 'paddingInlineEnd', 'paddingBlock', 'paddingBlockStart', 'paddingBlockEnd'];\nconst spacingKeys = [...marginKeys, ...paddingKeys];\nexport function createUnaryUnit(theme, themeKey, defaultValue, propName) {\n var _getPath;\n const themeSpacing = (_getPath = getPath(theme, themeKey, false)) != null ? _getPath : defaultValue;\n if (typeof themeSpacing === 'number') {\n return abs => {\n if (typeof abs === 'string') {\n return abs;\n }\n if (process.env.NODE_ENV !== 'production') {\n if (typeof abs !== 'number') {\n console.error(`MUI: Expected ${propName} argument to be a number or a string, got ${abs}.`);\n }\n }\n return themeSpacing * abs;\n };\n }\n if (Array.isArray(themeSpacing)) {\n return abs => {\n if (typeof abs === 'string') {\n return abs;\n }\n if (process.env.NODE_ENV !== 'production') {\n if (!Number.isInteger(abs)) {\n console.error([`MUI: The \\`theme.${themeKey}\\` array type cannot be combined with non integer values.` + `You should either use an integer value that can be used as index, or define the \\`theme.${themeKey}\\` as a number.`].join('\\n'));\n } else if (abs > themeSpacing.length - 1) {\n console.error([`MUI: The value provided (${abs}) overflows.`, `The supported values are: ${JSON.stringify(themeSpacing)}.`, `${abs} > ${themeSpacing.length - 1}, you need to add the missing values.`].join('\\n'));\n }\n }\n return themeSpacing[abs];\n };\n }\n if (typeof themeSpacing === 'function') {\n return themeSpacing;\n }\n if (process.env.NODE_ENV !== 'production') {\n console.error([`MUI: The \\`theme.${themeKey}\\` value (${themeSpacing}) is invalid.`, 'It should be a number, an array or a function.'].join('\\n'));\n }\n return () => undefined;\n}\nexport function createUnarySpacing(theme) {\n return createUnaryUnit(theme, 'spacing', 8, 'spacing');\n}\nexport function getValue(transformer, propValue) {\n if (typeof propValue === 'string' || propValue == null) {\n return propValue;\n }\n const abs = Math.abs(propValue);\n const transformed = transformer(abs);\n if (propValue >= 0) {\n return transformed;\n }\n if (typeof transformed === 'number') {\n return -transformed;\n }\n return `-${transformed}`;\n}\nexport function getStyleFromPropValue(cssProperties, transformer) {\n return propValue => cssProperties.reduce((acc, cssProperty) => {\n acc[cssProperty] = getValue(transformer, propValue);\n return acc;\n }, {});\n}\nfunction resolveCssProperty(props, keys, prop, transformer) {\n // Using a hash computation over an array iteration could be faster, but with only 28 items,\n // it's doesn't worth the bundle size.\n if (keys.indexOf(prop) === -1) {\n return null;\n }\n const cssProperties = getCssProperties(prop);\n const styleFromPropValue = getStyleFromPropValue(cssProperties, transformer);\n const propValue = props[prop];\n return handleBreakpoints(props, propValue, styleFromPropValue);\n}\nfunction style(props, keys) {\n const transformer = createUnarySpacing(props.theme);\n return Object.keys(props).map(prop => resolveCssProperty(props, keys, prop, transformer)).reduce(merge, {});\n}\nexport function margin(props) {\n return style(props, marginKeys);\n}\nmargin.propTypes = process.env.NODE_ENV !== 'production' ? marginKeys.reduce((obj, key) => {\n obj[key] = responsivePropType;\n return obj;\n}, {}) : {};\nmargin.filterProps = marginKeys;\nexport function padding(props) {\n return style(props, paddingKeys);\n}\npadding.propTypes = process.env.NODE_ENV !== 'production' ? paddingKeys.reduce((obj, key) => {\n obj[key] = responsivePropType;\n return obj;\n}, {}) : {};\npadding.filterProps = paddingKeys;\nfunction spacing(props) {\n return style(props, spacingKeys);\n}\nspacing.propTypes = process.env.NODE_ENV !== 'production' ? spacingKeys.reduce((obj, key) => {\n obj[key] = responsivePropType;\n return obj;\n}, {}) : {};\nspacing.filterProps = spacingKeys;\nexport default spacing;","import { createUnarySpacing } from '../spacing';\n\n// The different signatures imply different meaning for their arguments that can't be expressed structurally.\n// We express the difference with variable names.\n\nexport default function createSpacing(spacingInput = 8) {\n // Already transformed.\n if (spacingInput.mui) {\n return spacingInput;\n }\n\n // Material Design layouts are visually balanced. Most measurements align to an 8dp grid, which aligns both spacing and the overall layout.\n // Smaller components, such as icons, can align to a 4dp grid.\n // https://m2.material.io/design/layout/understanding-layout.html\n const transform = createUnarySpacing({\n spacing: spacingInput\n });\n const spacing = (...argsInput) => {\n if (process.env.NODE_ENV !== 'production') {\n if (!(argsInput.length <= 4)) {\n console.error(`MUI: Too many arguments provided, expected between 0 and 4, got ${argsInput.length}`);\n }\n }\n const args = argsInput.length === 0 ? [1] : argsInput;\n return args.map(argument => {\n const output = transform(argument);\n return typeof output === 'number' ? `${output}px` : output;\n }).join(' ');\n };\n spacing.mui = true;\n return spacing;\n}","import merge from './merge';\nfunction compose(...styles) {\n const handlers = styles.reduce((acc, style) => {\n style.filterProps.forEach(prop => {\n acc[prop] = style;\n });\n return acc;\n }, {});\n\n // false positive\n // eslint-disable-next-line react/function-component-definition\n const fn = props => {\n return Object.keys(props).reduce((acc, prop) => {\n if (handlers[prop]) {\n return merge(acc, handlers[prop](props));\n }\n return acc;\n }, {});\n };\n fn.propTypes = process.env.NODE_ENV !== 'production' ? styles.reduce((acc, style) => Object.assign(acc, style.propTypes), {}) : {};\n fn.filterProps = styles.reduce((acc, style) => acc.concat(style.filterProps), []);\n return fn;\n}\nexport default compose;","import responsivePropType from './responsivePropType';\nimport style from './style';\nimport compose from './compose';\nimport { createUnaryUnit, getValue } from './spacing';\nimport { handleBreakpoints } from './breakpoints';\nexport function borderTransform(value) {\n if (typeof value !== 'number') {\n return value;\n }\n return `${value}px solid`;\n}\nfunction createBorderStyle(prop, transform) {\n return style({\n prop,\n themeKey: 'borders',\n transform\n });\n}\nexport const border = createBorderStyle('border', borderTransform);\nexport const borderTop = createBorderStyle('borderTop', borderTransform);\nexport const borderRight = createBorderStyle('borderRight', borderTransform);\nexport const borderBottom = createBorderStyle('borderBottom', borderTransform);\nexport const borderLeft = createBorderStyle('borderLeft', borderTransform);\nexport const borderColor = createBorderStyle('borderColor');\nexport const borderTopColor = createBorderStyle('borderTopColor');\nexport const borderRightColor = createBorderStyle('borderRightColor');\nexport const borderBottomColor = createBorderStyle('borderBottomColor');\nexport const borderLeftColor = createBorderStyle('borderLeftColor');\nexport const outline = createBorderStyle('outline', borderTransform);\nexport const outlineColor = createBorderStyle('outlineColor');\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const borderRadius = props => {\n if (props.borderRadius !== undefined && props.borderRadius !== null) {\n const transformer = createUnaryUnit(props.theme, 'shape.borderRadius', 4, 'borderRadius');\n const styleFromPropValue = propValue => ({\n borderRadius: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.borderRadius, styleFromPropValue);\n }\n return null;\n};\nborderRadius.propTypes = process.env.NODE_ENV !== 'production' ? {\n borderRadius: responsivePropType\n} : {};\nborderRadius.filterProps = ['borderRadius'];\nconst borders = compose(border, borderTop, borderRight, borderBottom, borderLeft, borderColor, borderTopColor, borderRightColor, borderBottomColor, borderLeftColor, borderRadius, outline, outlineColor);\nexport default borders;","import style from './style';\nimport compose from './compose';\nimport { createUnaryUnit, getValue } from './spacing';\nimport { handleBreakpoints } from './breakpoints';\nimport responsivePropType from './responsivePropType';\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const gap = props => {\n if (props.gap !== undefined && props.gap !== null) {\n const transformer = createUnaryUnit(props.theme, 'spacing', 8, 'gap');\n const styleFromPropValue = propValue => ({\n gap: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.gap, styleFromPropValue);\n }\n return null;\n};\ngap.propTypes = process.env.NODE_ENV !== 'production' ? {\n gap: responsivePropType\n} : {};\ngap.filterProps = ['gap'];\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const columnGap = props => {\n if (props.columnGap !== undefined && props.columnGap !== null) {\n const transformer = createUnaryUnit(props.theme, 'spacing', 8, 'columnGap');\n const styleFromPropValue = propValue => ({\n columnGap: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.columnGap, styleFromPropValue);\n }\n return null;\n};\ncolumnGap.propTypes = process.env.NODE_ENV !== 'production' ? {\n columnGap: responsivePropType\n} : {};\ncolumnGap.filterProps = ['columnGap'];\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const rowGap = props => {\n if (props.rowGap !== undefined && props.rowGap !== null) {\n const transformer = createUnaryUnit(props.theme, 'spacing', 8, 'rowGap');\n const styleFromPropValue = propValue => ({\n rowGap: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.rowGap, styleFromPropValue);\n }\n return null;\n};\nrowGap.propTypes = process.env.NODE_ENV !== 'production' ? {\n rowGap: responsivePropType\n} : {};\nrowGap.filterProps = ['rowGap'];\nexport const gridColumn = style({\n prop: 'gridColumn'\n});\nexport const gridRow = style({\n prop: 'gridRow'\n});\nexport const gridAutoFlow = style({\n prop: 'gridAutoFlow'\n});\nexport const gridAutoColumns = style({\n prop: 'gridAutoColumns'\n});\nexport const gridAutoRows = style({\n prop: 'gridAutoRows'\n});\nexport const gridTemplateColumns = style({\n prop: 'gridTemplateColumns'\n});\nexport const gridTemplateRows = style({\n prop: 'gridTemplateRows'\n});\nexport const gridTemplateAreas = style({\n prop: 'gridTemplateAreas'\n});\nexport const gridArea = style({\n prop: 'gridArea'\n});\nconst grid = compose(gap, columnGap, rowGap, gridColumn, gridRow, gridAutoFlow, gridAutoColumns, gridAutoRows, gridTemplateColumns, gridTemplateRows, gridTemplateAreas, gridArea);\nexport default grid;","import style from './style';\nimport compose from './compose';\nexport function paletteTransform(value, userValue) {\n if (userValue === 'grey') {\n return userValue;\n }\n return value;\n}\nexport const color = style({\n prop: 'color',\n themeKey: 'palette',\n transform: paletteTransform\n});\nexport const bgcolor = style({\n prop: 'bgcolor',\n cssProperty: 'backgroundColor',\n themeKey: 'palette',\n transform: paletteTransform\n});\nexport const backgroundColor = style({\n prop: 'backgroundColor',\n themeKey: 'palette',\n transform: paletteTransform\n});\nconst palette = compose(color, bgcolor, backgroundColor);\nexport default palette;","import style from './style';\nimport compose from './compose';\nimport { handleBreakpoints, values as breakpointsValues } from './breakpoints';\nexport function sizingTransform(value) {\n return value <= 1 && value !== 0 ? `${value * 100}%` : value;\n}\nexport const width = style({\n prop: 'width',\n transform: sizingTransform\n});\nexport const maxWidth = props => {\n if (props.maxWidth !== undefined && props.maxWidth !== null) {\n const styleFromPropValue = propValue => {\n var _props$theme, _props$theme2;\n const breakpoint = ((_props$theme = props.theme) == null || (_props$theme = _props$theme.breakpoints) == null || (_props$theme = _props$theme.values) == null ? void 0 : _props$theme[propValue]) || breakpointsValues[propValue];\n if (!breakpoint) {\n return {\n maxWidth: sizingTransform(propValue)\n };\n }\n if (((_props$theme2 = props.theme) == null || (_props$theme2 = _props$theme2.breakpoints) == null ? void 0 : _props$theme2.unit) !== 'px') {\n return {\n maxWidth: `${breakpoint}${props.theme.breakpoints.unit}`\n };\n }\n return {\n maxWidth: breakpoint\n };\n };\n return handleBreakpoints(props, props.maxWidth, styleFromPropValue);\n }\n return null;\n};\nmaxWidth.filterProps = ['maxWidth'];\nexport const minWidth = style({\n prop: 'minWidth',\n transform: sizingTransform\n});\nexport const height = style({\n prop: 'height',\n transform: sizingTransform\n});\nexport const maxHeight = style({\n prop: 'maxHeight',\n transform: sizingTransform\n});\nexport const minHeight = style({\n prop: 'minHeight',\n transform: sizingTransform\n});\nexport const sizeWidth = style({\n prop: 'size',\n cssProperty: 'width',\n transform: sizingTransform\n});\nexport const sizeHeight = style({\n prop: 'size',\n cssProperty: 'height',\n transform: sizingTransform\n});\nexport const boxSizing = style({\n prop: 'boxSizing'\n});\nconst sizing = compose(width, maxWidth, minWidth, height, maxHeight, minHeight, boxSizing);\nexport default sizing;","import { padding, margin } from '../spacing';\nimport { borderRadius, borderTransform } from '../borders';\nimport { gap, rowGap, columnGap } from '../cssGrid';\nimport { paletteTransform } from '../palette';\nimport { maxWidth, sizingTransform } from '../sizing';\nconst defaultSxConfig = {\n // borders\n border: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderTop: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderRight: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderBottom: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderLeft: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderColor: {\n themeKey: 'palette'\n },\n borderTopColor: {\n themeKey: 'palette'\n },\n borderRightColor: {\n themeKey: 'palette'\n },\n borderBottomColor: {\n themeKey: 'palette'\n },\n borderLeftColor: {\n themeKey: 'palette'\n },\n outline: {\n themeKey: 'borders',\n transform: borderTransform\n },\n outlineColor: {\n themeKey: 'palette'\n },\n borderRadius: {\n themeKey: 'shape.borderRadius',\n style: borderRadius\n },\n // palette\n color: {\n themeKey: 'palette',\n transform: paletteTransform\n },\n bgcolor: {\n themeKey: 'palette',\n cssProperty: 'backgroundColor',\n transform: paletteTransform\n },\n backgroundColor: {\n themeKey: 'palette',\n transform: paletteTransform\n },\n // spacing\n p: {\n style: padding\n },\n pt: {\n style: padding\n },\n pr: {\n style: padding\n },\n pb: {\n style: padding\n },\n pl: {\n style: padding\n },\n px: {\n style: padding\n },\n py: {\n style: padding\n },\n padding: {\n style: padding\n },\n paddingTop: {\n style: padding\n },\n paddingRight: {\n style: padding\n },\n paddingBottom: {\n style: padding\n },\n paddingLeft: {\n style: padding\n },\n paddingX: {\n style: padding\n },\n paddingY: {\n style: padding\n },\n paddingInline: {\n style: padding\n },\n paddingInlineStart: {\n style: padding\n },\n paddingInlineEnd: {\n style: padding\n },\n paddingBlock: {\n style: padding\n },\n paddingBlockStart: {\n style: padding\n },\n paddingBlockEnd: {\n style: padding\n },\n m: {\n style: margin\n },\n mt: {\n style: margin\n },\n mr: {\n style: margin\n },\n mb: {\n style: margin\n },\n ml: {\n style: margin\n },\n mx: {\n style: margin\n },\n my: {\n style: margin\n },\n margin: {\n style: margin\n },\n marginTop: {\n style: margin\n },\n marginRight: {\n style: margin\n },\n marginBottom: {\n style: margin\n },\n marginLeft: {\n style: margin\n },\n marginX: {\n style: margin\n },\n marginY: {\n style: margin\n },\n marginInline: {\n style: margin\n },\n marginInlineStart: {\n style: margin\n },\n marginInlineEnd: {\n style: margin\n },\n marginBlock: {\n style: margin\n },\n marginBlockStart: {\n style: margin\n },\n marginBlockEnd: {\n style: margin\n },\n // display\n displayPrint: {\n cssProperty: false,\n transform: value => ({\n '@media print': {\n display: value\n }\n })\n },\n display: {},\n overflow: {},\n textOverflow: {},\n visibility: {},\n whiteSpace: {},\n // flexbox\n flexBasis: {},\n flexDirection: {},\n flexWrap: {},\n justifyContent: {},\n alignItems: {},\n alignContent: {},\n order: {},\n flex: {},\n flexGrow: {},\n flexShrink: {},\n alignSelf: {},\n justifyItems: {},\n justifySelf: {},\n // grid\n gap: {\n style: gap\n },\n rowGap: {\n style: rowGap\n },\n columnGap: {\n style: columnGap\n },\n gridColumn: {},\n gridRow: {},\n gridAutoFlow: {},\n gridAutoColumns: {},\n gridAutoRows: {},\n gridTemplateColumns: {},\n gridTemplateRows: {},\n gridTemplateAreas: {},\n gridArea: {},\n // positions\n position: {},\n zIndex: {\n themeKey: 'zIndex'\n },\n top: {},\n right: {},\n bottom: {},\n left: {},\n // shadows\n boxShadow: {\n themeKey: 'shadows'\n },\n // sizing\n width: {\n transform: sizingTransform\n },\n maxWidth: {\n style: maxWidth\n },\n minWidth: {\n transform: sizingTransform\n },\n height: {\n transform: sizingTransform\n },\n maxHeight: {\n transform: sizingTransform\n },\n minHeight: {\n transform: sizingTransform\n },\n boxSizing: {},\n // typography\n fontFamily: {\n themeKey: 'typography'\n },\n fontSize: {\n themeKey: 'typography'\n },\n fontStyle: {\n themeKey: 'typography'\n },\n fontWeight: {\n themeKey: 'typography'\n },\n letterSpacing: {},\n textTransform: {},\n lineHeight: {},\n textAlign: {},\n typography: {\n cssProperty: false,\n themeKey: 'typography'\n }\n};\nexport default defaultSxConfig;","import capitalize from '@mui/utils/capitalize';\nimport merge from '../merge';\nimport { getPath, getStyleValue as getValue } from '../style';\nimport { handleBreakpoints, createEmptyBreakpointObject, removeUnusedBreakpoints } from '../breakpoints';\nimport defaultSxConfig from './defaultSxConfig';\nfunction objectsHaveSameKeys(...objects) {\n const allKeys = objects.reduce((keys, object) => keys.concat(Object.keys(object)), []);\n const union = new Set(allKeys);\n return objects.every(object => union.size === Object.keys(object).length);\n}\nfunction callIfFn(maybeFn, arg) {\n return typeof maybeFn === 'function' ? maybeFn(arg) : maybeFn;\n}\n\n// eslint-disable-next-line @typescript-eslint/naming-convention\nexport function unstable_createStyleFunctionSx() {\n function getThemeValue(prop, val, theme, config) {\n const props = {\n [prop]: val,\n theme\n };\n const options = config[prop];\n if (!options) {\n return {\n [prop]: val\n };\n }\n const {\n cssProperty = prop,\n themeKey,\n transform,\n style\n } = options;\n if (val == null) {\n return null;\n }\n\n // TODO v6: remove, see https://github.com/mui/material-ui/pull/38123\n if (themeKey === 'typography' && val === 'inherit') {\n return {\n [prop]: val\n };\n }\n const themeMapping = getPath(theme, themeKey) || {};\n if (style) {\n return style(props);\n }\n const styleFromPropValue = propValueFinal => {\n let value = getValue(themeMapping, transform, propValueFinal);\n if (propValueFinal === value && typeof propValueFinal === 'string') {\n // Haven't found value\n value = getValue(themeMapping, transform, `${prop}${propValueFinal === 'default' ? '' : capitalize(propValueFinal)}`, propValueFinal);\n }\n if (cssProperty === false) {\n return value;\n }\n return {\n [cssProperty]: value\n };\n };\n return handleBreakpoints(props, val, styleFromPropValue);\n }\n function styleFunctionSx(props) {\n var _theme$unstable_sxCon;\n const {\n sx,\n theme = {}\n } = props || {};\n if (!sx) {\n return null; // Emotion & styled-components will neglect null\n }\n const config = (_theme$unstable_sxCon = theme.unstable_sxConfig) != null ? _theme$unstable_sxCon : defaultSxConfig;\n\n /*\n * Receive `sxInput` as object or callback\n * and then recursively check keys & values to create media query object styles.\n * (the result will be used in `styled`)\n */\n function traverse(sxInput) {\n let sxObject = sxInput;\n if (typeof sxInput === 'function') {\n sxObject = sxInput(theme);\n } else if (typeof sxInput !== 'object') {\n // value\n return sxInput;\n }\n if (!sxObject) {\n return null;\n }\n const emptyBreakpoints = createEmptyBreakpointObject(theme.breakpoints);\n const breakpointsKeys = Object.keys(emptyBreakpoints);\n let css = emptyBreakpoints;\n Object.keys(sxObject).forEach(styleKey => {\n const value = callIfFn(sxObject[styleKey], theme);\n if (value !== null && value !== undefined) {\n if (typeof value === 'object') {\n if (config[styleKey]) {\n css = merge(css, getThemeValue(styleKey, value, theme, config));\n } else {\n const breakpointsValues = handleBreakpoints({\n theme\n }, value, x => ({\n [styleKey]: x\n }));\n if (objectsHaveSameKeys(breakpointsValues, value)) {\n css[styleKey] = styleFunctionSx({\n sx: value,\n theme\n });\n } else {\n css = merge(css, breakpointsValues);\n }\n }\n } else {\n css = merge(css, getThemeValue(styleKey, value, theme, config));\n }\n }\n });\n return removeUnusedBreakpoints(breakpointsKeys, css);\n }\n return Array.isArray(sx) ? sx.map(traverse) : traverse(sx);\n }\n return styleFunctionSx;\n}\nconst styleFunctionSx = unstable_createStyleFunctionSx();\nstyleFunctionSx.filterProps = ['sx'];\nexport default styleFunctionSx;","/**\n * A universal utility to style components with multiple color modes. Always use it from the theme object.\n * It works with:\n * - [Basic theme](https://mui.com/material-ui/customization/dark-mode/)\n * - [CSS theme variables](https://mui.com/material-ui/experimental-api/css-theme-variables/overview/)\n * - Zero-runtime engine\n *\n * Tips: Use an array over object spread and place `theme.applyStyles()` last.\n *\n * ✅ [{ background: '#e5e5e5' }, theme.applyStyles('dark', { background: '#1c1c1c' })]\n *\n * 🚫 { background: '#e5e5e5', ...theme.applyStyles('dark', { background: '#1c1c1c' })}\n *\n * @example\n * 1. using with `styled`:\n * ```jsx\n * const Component = styled('div')(({ theme }) => [\n * { background: '#e5e5e5' },\n * theme.applyStyles('dark', {\n * background: '#1c1c1c',\n * color: '#fff',\n * }),\n * ]);\n * ```\n *\n * @example\n * 2. using with `sx` prop:\n * ```jsx\n * [\n * { background: '#e5e5e5' },\n * theme.applyStyles('dark', {\n * background: '#1c1c1c',\n * color: '#fff',\n * }),\n * ]}\n * />\n * ```\n *\n * @example\n * 3. theming a component:\n * ```jsx\n * extendTheme({\n * components: {\n * MuiButton: {\n * styleOverrides: {\n * root: ({ theme }) => [\n * { background: '#e5e5e5' },\n * theme.applyStyles('dark', {\n * background: '#1c1c1c',\n * color: '#fff',\n * }),\n * ],\n * },\n * }\n * }\n * })\n *```\n */\nexport default function applyStyles(key, styles) {\n // @ts-expect-error this is 'any' type\n const theme = this;\n if (theme.vars && typeof theme.getColorSchemeSelector === 'function') {\n // If CssVarsProvider is used as a provider,\n // returns '* :where([data-mui-color-scheme=\"light|dark\"]) &'\n const selector = theme.getColorSchemeSelector(key).replace(/(\\[[^\\]]+\\])/, '*:where($1)');\n return {\n [selector]: styles\n };\n }\n if (theme.palette.mode === key) {\n return styles;\n }\n return {};\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"breakpoints\", \"palette\", \"spacing\", \"shape\"];\nimport deepmerge from '@mui/utils/deepmerge';\nimport createBreakpoints from './createBreakpoints';\nimport shape from './shape';\nimport createSpacing from './createSpacing';\nimport styleFunctionSx from '../styleFunctionSx/styleFunctionSx';\nimport defaultSxConfig from '../styleFunctionSx/defaultSxConfig';\nimport applyStyles from './applyStyles';\nfunction createTheme(options = {}, ...args) {\n const {\n breakpoints: breakpointsInput = {},\n palette: paletteInput = {},\n spacing: spacingInput,\n shape: shapeInput = {}\n } = options,\n other = _objectWithoutPropertiesLoose(options, _excluded);\n const breakpoints = createBreakpoints(breakpointsInput);\n const spacing = createSpacing(spacingInput);\n let muiTheme = deepmerge({\n breakpoints,\n direction: 'ltr',\n components: {},\n // Inject component definitions.\n palette: _extends({\n mode: 'light'\n }, paletteInput),\n spacing,\n shape: _extends({}, shape, shapeInput)\n }, other);\n muiTheme.applyStyles = applyStyles;\n muiTheme = args.reduce((acc, argument) => deepmerge(acc, argument), muiTheme);\n muiTheme.unstable_sxConfig = _extends({}, defaultSxConfig, other == null ? void 0 : other.unstable_sxConfig);\n muiTheme.unstable_sx = function sx(props) {\n return styleFunctionSx({\n sx: props,\n theme: this\n });\n };\n return muiTheme;\n}\nexport default createTheme;","'use client';\n\nimport * as React from 'react';\nimport { ThemeContext } from '@mui/styled-engine';\nfunction isObjectEmpty(obj) {\n return Object.keys(obj).length === 0;\n}\nfunction useTheme(defaultTheme = null) {\n const contextTheme = React.useContext(ThemeContext);\n return !contextTheme || isObjectEmpty(contextTheme) ? defaultTheme : contextTheme;\n}\nexport default useTheme;","'use client';\n\nimport createTheme from './createTheme';\nimport useThemeWithoutDefault from './useThemeWithoutDefault';\nexport const systemDefaultTheme = createTheme();\nfunction useTheme(defaultTheme = systemDefaultTheme) {\n return useThemeWithoutDefault(defaultTheme);\n}\nexport default useTheme;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"ownerState\"],\n _excluded2 = [\"variants\"],\n _excluded3 = [\"name\", \"slot\", \"skipVariantsResolver\", \"skipSx\", \"overridesResolver\"];\n/* eslint-disable no-underscore-dangle */\nimport styledEngineStyled, { internal_processStyles as processStyles } from '@mui/styled-engine';\nimport { isPlainObject } from '@mui/utils/deepmerge';\nimport capitalize from '@mui/utils/capitalize';\nimport getDisplayName from '@mui/utils/getDisplayName';\nimport createTheme from './createTheme';\nimport styleFunctionSx from './styleFunctionSx';\nfunction isEmpty(obj) {\n return Object.keys(obj).length === 0;\n}\n\n// https://github.com/emotion-js/emotion/blob/26ded6109fcd8ca9875cc2ce4564fee678a3f3c5/packages/styled/src/utils.js#L40\nfunction isStringTag(tag) {\n return typeof tag === 'string' &&\n // 96 is one less than the char code\n // for \"a\" so this is checking that\n // it's a lowercase character\n tag.charCodeAt(0) > 96;\n}\n\n// Update /system/styled/#api in case if this changes\nexport function shouldForwardProp(prop) {\n return prop !== 'ownerState' && prop !== 'theme' && prop !== 'sx' && prop !== 'as';\n}\nexport const systemDefaultTheme = createTheme();\nconst lowercaseFirstLetter = string => {\n if (!string) {\n return string;\n }\n return string.charAt(0).toLowerCase() + string.slice(1);\n};\nfunction resolveTheme({\n defaultTheme,\n theme,\n themeId\n}) {\n return isEmpty(theme) ? defaultTheme : theme[themeId] || theme;\n}\nfunction defaultOverridesResolver(slot) {\n if (!slot) {\n return null;\n }\n return (props, styles) => styles[slot];\n}\nfunction processStyleArg(callableStyle, _ref) {\n let {\n ownerState\n } = _ref,\n props = _objectWithoutPropertiesLoose(_ref, _excluded);\n const resolvedStylesArg = typeof callableStyle === 'function' ? callableStyle(_extends({\n ownerState\n }, props)) : callableStyle;\n if (Array.isArray(resolvedStylesArg)) {\n return resolvedStylesArg.flatMap(resolvedStyle => processStyleArg(resolvedStyle, _extends({\n ownerState\n }, props)));\n }\n if (!!resolvedStylesArg && typeof resolvedStylesArg === 'object' && Array.isArray(resolvedStylesArg.variants)) {\n const {\n variants = []\n } = resolvedStylesArg,\n otherStyles = _objectWithoutPropertiesLoose(resolvedStylesArg, _excluded2);\n let result = otherStyles;\n variants.forEach(variant => {\n let isMatch = true;\n if (typeof variant.props === 'function') {\n isMatch = variant.props(_extends({\n ownerState\n }, props, ownerState));\n } else {\n Object.keys(variant.props).forEach(key => {\n if ((ownerState == null ? void 0 : ownerState[key]) !== variant.props[key] && props[key] !== variant.props[key]) {\n isMatch = false;\n }\n });\n }\n if (isMatch) {\n if (!Array.isArray(result)) {\n result = [result];\n }\n result.push(typeof variant.style === 'function' ? variant.style(_extends({\n ownerState\n }, props, ownerState)) : variant.style);\n }\n });\n return result;\n }\n return resolvedStylesArg;\n}\nexport default function createStyled(input = {}) {\n const {\n themeId,\n defaultTheme = systemDefaultTheme,\n rootShouldForwardProp = shouldForwardProp,\n slotShouldForwardProp = shouldForwardProp\n } = input;\n const systemSx = props => {\n return styleFunctionSx(_extends({}, props, {\n theme: resolveTheme(_extends({}, props, {\n defaultTheme,\n themeId\n }))\n }));\n };\n systemSx.__mui_systemSx = true;\n return (tag, inputOptions = {}) => {\n // Filter out the `sx` style function from the previous styled component to prevent unnecessary styles generated by the composite components.\n processStyles(tag, styles => styles.filter(style => !(style != null && style.__mui_systemSx)));\n const {\n name: componentName,\n slot: componentSlot,\n skipVariantsResolver: inputSkipVariantsResolver,\n skipSx: inputSkipSx,\n // TODO v6: remove `lowercaseFirstLetter()` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n overridesResolver = defaultOverridesResolver(lowercaseFirstLetter(componentSlot))\n } = inputOptions,\n options = _objectWithoutPropertiesLoose(inputOptions, _excluded3);\n\n // if skipVariantsResolver option is defined, take the value, otherwise, true for root and false for other slots.\n const skipVariantsResolver = inputSkipVariantsResolver !== undefined ? inputSkipVariantsResolver :\n // TODO v6: remove `Root` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n componentSlot && componentSlot !== 'Root' && componentSlot !== 'root' || false;\n const skipSx = inputSkipSx || false;\n let label;\n if (process.env.NODE_ENV !== 'production') {\n if (componentName) {\n // TODO v6: remove `lowercaseFirstLetter()` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n label = `${componentName}-${lowercaseFirstLetter(componentSlot || 'Root')}`;\n }\n }\n let shouldForwardPropOption = shouldForwardProp;\n\n // TODO v6: remove `Root` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n if (componentSlot === 'Root' || componentSlot === 'root') {\n shouldForwardPropOption = rootShouldForwardProp;\n } else if (componentSlot) {\n // any other slot specified\n shouldForwardPropOption = slotShouldForwardProp;\n } else if (isStringTag(tag)) {\n // for string (html) tag, preserve the behavior in emotion & styled-components.\n shouldForwardPropOption = undefined;\n }\n const defaultStyledResolver = styledEngineStyled(tag, _extends({\n shouldForwardProp: shouldForwardPropOption,\n label\n }, options));\n const transformStyleArg = stylesArg => {\n // On the server Emotion doesn't use React.forwardRef for creating components, so the created\n // component stays as a function. This condition makes sure that we do not interpolate functions\n // which are basically components used as a selectors.\n if (typeof stylesArg === 'function' && stylesArg.__emotion_real !== stylesArg || isPlainObject(stylesArg)) {\n return props => processStyleArg(stylesArg, _extends({}, props, {\n theme: resolveTheme({\n theme: props.theme,\n defaultTheme,\n themeId\n })\n }));\n }\n return stylesArg;\n };\n const muiStyledResolver = (styleArg, ...expressions) => {\n let transformedStyleArg = transformStyleArg(styleArg);\n const expressionsWithDefaultTheme = expressions ? expressions.map(transformStyleArg) : [];\n if (componentName && overridesResolver) {\n expressionsWithDefaultTheme.push(props => {\n const theme = resolveTheme(_extends({}, props, {\n defaultTheme,\n themeId\n }));\n if (!theme.components || !theme.components[componentName] || !theme.components[componentName].styleOverrides) {\n return null;\n }\n const styleOverrides = theme.components[componentName].styleOverrides;\n const resolvedStyleOverrides = {};\n // TODO: v7 remove iteration and use `resolveStyleArg(styleOverrides[slot])` directly\n Object.entries(styleOverrides).forEach(([slotKey, slotStyle]) => {\n resolvedStyleOverrides[slotKey] = processStyleArg(slotStyle, _extends({}, props, {\n theme\n }));\n });\n return overridesResolver(props, resolvedStyleOverrides);\n });\n }\n if (componentName && !skipVariantsResolver) {\n expressionsWithDefaultTheme.push(props => {\n var _theme$components;\n const theme = resolveTheme(_extends({}, props, {\n defaultTheme,\n themeId\n }));\n const themeVariants = theme == null || (_theme$components = theme.components) == null || (_theme$components = _theme$components[componentName]) == null ? void 0 : _theme$components.variants;\n return processStyleArg({\n variants: themeVariants\n }, _extends({}, props, {\n theme\n }));\n });\n }\n if (!skipSx) {\n expressionsWithDefaultTheme.push(systemSx);\n }\n const numOfCustomFnsApplied = expressionsWithDefaultTheme.length - expressions.length;\n if (Array.isArray(styleArg) && numOfCustomFnsApplied > 0) {\n const placeholders = new Array(numOfCustomFnsApplied).fill('');\n // If the type is array, than we need to add placeholders in the template for the overrides, variants and the sx styles.\n transformedStyleArg = [...styleArg, ...placeholders];\n transformedStyleArg.raw = [...styleArg.raw, ...placeholders];\n }\n const Component = defaultStyledResolver(transformedStyleArg, ...expressionsWithDefaultTheme);\n if (process.env.NODE_ENV !== 'production') {\n let displayName;\n if (componentName) {\n displayName = `${componentName}${capitalize(componentSlot || '')}`;\n }\n if (displayName === undefined) {\n displayName = `Styled(${getDisplayName(tag)})`;\n }\n Component.displayName = displayName;\n }\n if (tag.muiName) {\n Component.muiName = tag.muiName;\n }\n return Component;\n };\n if (defaultStyledResolver.withConfig) {\n muiStyledResolver.withConfig = defaultStyledResolver.withConfig;\n }\n return muiStyledResolver;\n };\n}","import resolveProps from '@mui/utils/resolveProps';\nexport default function getThemeProps(params) {\n const {\n theme,\n name,\n props\n } = params;\n if (!theme || !theme.components || !theme.components[name] || !theme.components[name].defaultProps) {\n return props;\n }\n return resolveProps(theme.components[name].defaultProps, props);\n}","'use client';\n\nimport getThemeProps from './getThemeProps';\nimport useTheme from '../useTheme';\nexport default function useThemeProps({\n props,\n name,\n defaultTheme,\n themeId\n}) {\n let theme = useTheme(defaultTheme);\n if (themeId) {\n theme = theme[themeId] || theme;\n }\n const mergedProps = getThemeProps({\n theme,\n name,\n props\n });\n return mergedProps;\n}","import _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\n/* eslint-disable @typescript-eslint/naming-convention */\nimport clamp from '@mui/utils/clamp';\n/**\n * Returns a number whose value is limited to the given range.\n * @param {number} value The value to be clamped\n * @param {number} min The lower boundary of the output range\n * @param {number} max The upper boundary of the output range\n * @returns {number} A number in the range [min, max]\n */\nfunction clampWrapper(value, min = 0, max = 1) {\n if (process.env.NODE_ENV !== 'production') {\n if (value < min || value > max) {\n console.error(`MUI: The value provided ${value} is out of range [${min}, ${max}].`);\n }\n }\n return clamp(value, min, max);\n}\n\n/**\n * Converts a color from CSS hex format to CSS rgb format.\n * @param {string} color - Hex color, i.e. #nnn or #nnnnnn\n * @returns {string} A CSS rgb color string\n */\nexport function hexToRgb(color) {\n color = color.slice(1);\n const re = new RegExp(`.{1,${color.length >= 6 ? 2 : 1}}`, 'g');\n let colors = color.match(re);\n if (colors && colors[0].length === 1) {\n colors = colors.map(n => n + n);\n }\n return colors ? `rgb${colors.length === 4 ? 'a' : ''}(${colors.map((n, index) => {\n return index < 3 ? parseInt(n, 16) : Math.round(parseInt(n, 16) / 255 * 1000) / 1000;\n }).join(', ')})` : '';\n}\nfunction intToHex(int) {\n const hex = int.toString(16);\n return hex.length === 1 ? `0${hex}` : hex;\n}\n\n/**\n * Returns an object with the type and values of a color.\n *\n * Note: Does not support rgb % values.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @returns {object} - A MUI color object: {type: string, values: number[]}\n */\nexport function decomposeColor(color) {\n // Idempotent\n if (color.type) {\n return color;\n }\n if (color.charAt(0) === '#') {\n return decomposeColor(hexToRgb(color));\n }\n const marker = color.indexOf('(');\n const type = color.substring(0, marker);\n if (['rgb', 'rgba', 'hsl', 'hsla', 'color'].indexOf(type) === -1) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: Unsupported \\`${color}\\` color.\nThe following formats are supported: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color().` : _formatMuiErrorMessage(9, color));\n }\n let values = color.substring(marker + 1, color.length - 1);\n let colorSpace;\n if (type === 'color') {\n values = values.split(' ');\n colorSpace = values.shift();\n if (values.length === 4 && values[3].charAt(0) === '/') {\n values[3] = values[3].slice(1);\n }\n if (['srgb', 'display-p3', 'a98-rgb', 'prophoto-rgb', 'rec-2020'].indexOf(colorSpace) === -1) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: unsupported \\`${colorSpace}\\` color space.\nThe following color spaces are supported: srgb, display-p3, a98-rgb, prophoto-rgb, rec-2020.` : _formatMuiErrorMessage(10, colorSpace));\n }\n } else {\n values = values.split(',');\n }\n values = values.map(value => parseFloat(value));\n return {\n type,\n values,\n colorSpace\n };\n}\n\n/**\n * Returns a channel created from the input color.\n *\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @returns {string} - The channel for the color, that can be used in rgba or hsla colors\n */\nexport const colorChannel = color => {\n const decomposedColor = decomposeColor(color);\n return decomposedColor.values.slice(0, 3).map((val, idx) => decomposedColor.type.indexOf('hsl') !== -1 && idx !== 0 ? `${val}%` : val).join(' ');\n};\nexport const private_safeColorChannel = (color, warning) => {\n try {\n return colorChannel(color);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n};\n\n/**\n * Converts a color object with type and values to a string.\n * @param {object} color - Decomposed color\n * @param {string} color.type - One of: 'rgb', 'rgba', 'hsl', 'hsla', 'color'\n * @param {array} color.values - [n,n,n] or [n,n,n,n]\n * @returns {string} A CSS color string\n */\nexport function recomposeColor(color) {\n const {\n type,\n colorSpace\n } = color;\n let {\n values\n } = color;\n if (type.indexOf('rgb') !== -1) {\n // Only convert the first 3 values to int (i.e. not alpha)\n values = values.map((n, i) => i < 3 ? parseInt(n, 10) : n);\n } else if (type.indexOf('hsl') !== -1) {\n values[1] = `${values[1]}%`;\n values[2] = `${values[2]}%`;\n }\n if (type.indexOf('color') !== -1) {\n values = `${colorSpace} ${values.join(' ')}`;\n } else {\n values = `${values.join(', ')}`;\n }\n return `${type}(${values})`;\n}\n\n/**\n * Converts a color from CSS rgb format to CSS hex format.\n * @param {string} color - RGB color, i.e. rgb(n, n, n)\n * @returns {string} A CSS rgb color string, i.e. #nnnnnn\n */\nexport function rgbToHex(color) {\n // Idempotent\n if (color.indexOf('#') === 0) {\n return color;\n }\n const {\n values\n } = decomposeColor(color);\n return `#${values.map((n, i) => intToHex(i === 3 ? Math.round(255 * n) : n)).join('')}`;\n}\n\n/**\n * Converts a color from hsl format to rgb format.\n * @param {string} color - HSL color values\n * @returns {string} rgb color values\n */\nexport function hslToRgb(color) {\n color = decomposeColor(color);\n const {\n values\n } = color;\n const h = values[0];\n const s = values[1] / 100;\n const l = values[2] / 100;\n const a = s * Math.min(l, 1 - l);\n const f = (n, k = (n + h / 30) % 12) => l - a * Math.max(Math.min(k - 3, 9 - k, 1), -1);\n let type = 'rgb';\n const rgb = [Math.round(f(0) * 255), Math.round(f(8) * 255), Math.round(f(4) * 255)];\n if (color.type === 'hsla') {\n type += 'a';\n rgb.push(values[3]);\n }\n return recomposeColor({\n type,\n values: rgb\n });\n}\n/**\n * The relative brightness of any point in a color space,\n * normalized to 0 for darkest black and 1 for lightest white.\n *\n * Formula: https://www.w3.org/TR/WCAG20-TECHS/G17.html#G17-tests\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @returns {number} The relative brightness of the color in the range 0 - 1\n */\nexport function getLuminance(color) {\n color = decomposeColor(color);\n let rgb = color.type === 'hsl' || color.type === 'hsla' ? decomposeColor(hslToRgb(color)).values : color.values;\n rgb = rgb.map(val => {\n if (color.type !== 'color') {\n val /= 255; // normalized\n }\n return val <= 0.03928 ? val / 12.92 : ((val + 0.055) / 1.055) ** 2.4;\n });\n\n // Truncate at 3 digits\n return Number((0.2126 * rgb[0] + 0.7152 * rgb[1] + 0.0722 * rgb[2]).toFixed(3));\n}\n\n/**\n * Calculates the contrast ratio between two colors.\n *\n * Formula: https://www.w3.org/TR/WCAG20-TECHS/G17.html#G17-tests\n * @param {string} foreground - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla()\n * @param {string} background - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla()\n * @returns {number} A contrast ratio value in the range 0 - 21.\n */\nexport function getContrastRatio(foreground, background) {\n const lumA = getLuminance(foreground);\n const lumB = getLuminance(background);\n return (Math.max(lumA, lumB) + 0.05) / (Math.min(lumA, lumB) + 0.05);\n}\n\n/**\n * Sets the absolute transparency of a color.\n * Any existing alpha values are overwritten.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} value - value to set the alpha channel to in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function alpha(color, value) {\n color = decomposeColor(color);\n value = clampWrapper(value);\n if (color.type === 'rgb' || color.type === 'hsl') {\n color.type += 'a';\n }\n if (color.type === 'color') {\n color.values[3] = `/${value}`;\n } else {\n color.values[3] = value;\n }\n return recomposeColor(color);\n}\nexport function private_safeAlpha(color, value, warning) {\n try {\n return alpha(color, value);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Darkens a color.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} coefficient - multiplier in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function darken(color, coefficient) {\n color = decomposeColor(color);\n coefficient = clampWrapper(coefficient);\n if (color.type.indexOf('hsl') !== -1) {\n color.values[2] *= 1 - coefficient;\n } else if (color.type.indexOf('rgb') !== -1 || color.type.indexOf('color') !== -1) {\n for (let i = 0; i < 3; i += 1) {\n color.values[i] *= 1 - coefficient;\n }\n }\n return recomposeColor(color);\n}\nexport function private_safeDarken(color, coefficient, warning) {\n try {\n return darken(color, coefficient);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Lightens a color.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} coefficient - multiplier in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function lighten(color, coefficient) {\n color = decomposeColor(color);\n coefficient = clampWrapper(coefficient);\n if (color.type.indexOf('hsl') !== -1) {\n color.values[2] += (100 - color.values[2]) * coefficient;\n } else if (color.type.indexOf('rgb') !== -1) {\n for (let i = 0; i < 3; i += 1) {\n color.values[i] += (255 - color.values[i]) * coefficient;\n }\n } else if (color.type.indexOf('color') !== -1) {\n for (let i = 0; i < 3; i += 1) {\n color.values[i] += (1 - color.values[i]) * coefficient;\n }\n }\n return recomposeColor(color);\n}\nexport function private_safeLighten(color, coefficient, warning) {\n try {\n return lighten(color, coefficient);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Darken or lighten a color, depending on its luminance.\n * Light colors are darkened, dark colors are lightened.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} coefficient=0.15 - multiplier in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function emphasize(color, coefficient = 0.15) {\n return getLuminance(color) > 0.5 ? darken(color, coefficient) : lighten(color, coefficient);\n}\nexport function private_safeEmphasize(color, coefficient, warning) {\n try {\n return emphasize(color, coefficient);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Blend a transparent overlay color with a background color, resulting in a single\n * RGB color.\n * @param {string} background - CSS color\n * @param {string} overlay - CSS color\n * @param {number} opacity - Opacity multiplier in the range 0 - 1\n * @param {number} [gamma=1.0] - Gamma correction factor. For gamma-correct blending, 2.2 is usual.\n */\nexport function blend(background, overlay, opacity, gamma = 1.0) {\n const blendChannel = (b, o) => Math.round((b ** (1 / gamma) * (1 - opacity) + o ** (1 / gamma) * opacity) ** gamma);\n const backgroundColor = decomposeColor(background);\n const overlayColor = decomposeColor(overlay);\n const rgb = [blendChannel(backgroundColor.values[0], overlayColor.values[0]), blendChannel(backgroundColor.values[1], overlayColor.values[1]), blendChannel(backgroundColor.values[2], overlayColor.values[2])];\n return recomposeColor({\n type: 'rgb',\n values: rgb\n });\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nexport default function createMixins(breakpoints, mixins) {\n return _extends({\n toolbar: {\n minHeight: 56,\n [breakpoints.up('xs')]: {\n '@media (orientation: landscape)': {\n minHeight: 48\n }\n },\n [breakpoints.up('sm')]: {\n minHeight: 64\n }\n }\n }, mixins);\n}","const common = {\n black: '#000',\n white: '#fff'\n};\nexport default common;","const grey = {\n 50: '#fafafa',\n 100: '#f5f5f5',\n 200: '#eeeeee',\n 300: '#e0e0e0',\n 400: '#bdbdbd',\n 500: '#9e9e9e',\n 600: '#757575',\n 700: '#616161',\n 800: '#424242',\n 900: '#212121',\n A100: '#f5f5f5',\n A200: '#eeeeee',\n A400: '#bdbdbd',\n A700: '#616161'\n};\nexport default grey;","const purple = {\n 50: '#f3e5f5',\n 100: '#e1bee7',\n 200: '#ce93d8',\n 300: '#ba68c8',\n 400: '#ab47bc',\n 500: '#9c27b0',\n 600: '#8e24aa',\n 700: '#7b1fa2',\n 800: '#6a1b9a',\n 900: '#4a148c',\n A100: '#ea80fc',\n A200: '#e040fb',\n A400: '#d500f9',\n A700: '#aa00ff'\n};\nexport default purple;","const red = {\n 50: '#ffebee',\n 100: '#ffcdd2',\n 200: '#ef9a9a',\n 300: '#e57373',\n 400: '#ef5350',\n 500: '#f44336',\n 600: '#e53935',\n 700: '#d32f2f',\n 800: '#c62828',\n 900: '#b71c1c',\n A100: '#ff8a80',\n A200: '#ff5252',\n A400: '#ff1744',\n A700: '#d50000'\n};\nexport default red;","const orange = {\n 50: '#fff3e0',\n 100: '#ffe0b2',\n 200: '#ffcc80',\n 300: '#ffb74d',\n 400: '#ffa726',\n 500: '#ff9800',\n 600: '#fb8c00',\n 700: '#f57c00',\n 800: '#ef6c00',\n 900: '#e65100',\n A100: '#ffd180',\n A200: '#ffab40',\n A400: '#ff9100',\n A700: '#ff6d00'\n};\nexport default orange;","const blue = {\n 50: '#e3f2fd',\n 100: '#bbdefb',\n 200: '#90caf9',\n 300: '#64b5f6',\n 400: '#42a5f5',\n 500: '#2196f3',\n 600: '#1e88e5',\n 700: '#1976d2',\n 800: '#1565c0',\n 900: '#0d47a1',\n A100: '#82b1ff',\n A200: '#448aff',\n A400: '#2979ff',\n A700: '#2962ff'\n};\nexport default blue;","const lightBlue = {\n 50: '#e1f5fe',\n 100: '#b3e5fc',\n 200: '#81d4fa',\n 300: '#4fc3f7',\n 400: '#29b6f6',\n 500: '#03a9f4',\n 600: '#039be5',\n 700: '#0288d1',\n 800: '#0277bd',\n 900: '#01579b',\n A100: '#80d8ff',\n A200: '#40c4ff',\n A400: '#00b0ff',\n A700: '#0091ea'\n};\nexport default lightBlue;","const green = {\n 50: '#e8f5e9',\n 100: '#c8e6c9',\n 200: '#a5d6a7',\n 300: '#81c784',\n 400: '#66bb6a',\n 500: '#4caf50',\n 600: '#43a047',\n 700: '#388e3c',\n 800: '#2e7d32',\n 900: '#1b5e20',\n A100: '#b9f6ca',\n A200: '#69f0ae',\n A400: '#00e676',\n A700: '#00c853'\n};\nexport default green;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\nconst _excluded = [\"mode\", \"contrastThreshold\", \"tonalOffset\"];\nimport { deepmerge } from '@mui/utils';\nimport { darken, getContrastRatio, lighten } from '@mui/system';\nimport common from '../colors/common';\nimport grey from '../colors/grey';\nimport purple from '../colors/purple';\nimport red from '../colors/red';\nimport orange from '../colors/orange';\nimport blue from '../colors/blue';\nimport lightBlue from '../colors/lightBlue';\nimport green from '../colors/green';\nexport const light = {\n // The colors used to style the text.\n text: {\n // The most important text.\n primary: 'rgba(0, 0, 0, 0.87)',\n // Secondary text.\n secondary: 'rgba(0, 0, 0, 0.6)',\n // Disabled text have even lower visual prominence.\n disabled: 'rgba(0, 0, 0, 0.38)'\n },\n // The color used to divide different elements.\n divider: 'rgba(0, 0, 0, 0.12)',\n // The background colors used to style the surfaces.\n // Consistency between these values is important.\n background: {\n paper: common.white,\n default: common.white\n },\n // The colors used to style the action elements.\n action: {\n // The color of an active action like an icon button.\n active: 'rgba(0, 0, 0, 0.54)',\n // The color of an hovered action.\n hover: 'rgba(0, 0, 0, 0.04)',\n hoverOpacity: 0.04,\n // The color of a selected action.\n selected: 'rgba(0, 0, 0, 0.08)',\n selectedOpacity: 0.08,\n // The color of a disabled action.\n disabled: 'rgba(0, 0, 0, 0.26)',\n // The background color of a disabled action.\n disabledBackground: 'rgba(0, 0, 0, 0.12)',\n disabledOpacity: 0.38,\n focus: 'rgba(0, 0, 0, 0.12)',\n focusOpacity: 0.12,\n activatedOpacity: 0.12\n }\n};\nexport const dark = {\n text: {\n primary: common.white,\n secondary: 'rgba(255, 255, 255, 0.7)',\n disabled: 'rgba(255, 255, 255, 0.5)',\n icon: 'rgba(255, 255, 255, 0.5)'\n },\n divider: 'rgba(255, 255, 255, 0.12)',\n background: {\n paper: '#121212',\n default: '#121212'\n },\n action: {\n active: common.white,\n hover: 'rgba(255, 255, 255, 0.08)',\n hoverOpacity: 0.08,\n selected: 'rgba(255, 255, 255, 0.16)',\n selectedOpacity: 0.16,\n disabled: 'rgba(255, 255, 255, 0.3)',\n disabledBackground: 'rgba(255, 255, 255, 0.12)',\n disabledOpacity: 0.38,\n focus: 'rgba(255, 255, 255, 0.12)',\n focusOpacity: 0.12,\n activatedOpacity: 0.24\n }\n};\nfunction addLightOrDark(intent, direction, shade, tonalOffset) {\n const tonalOffsetLight = tonalOffset.light || tonalOffset;\n const tonalOffsetDark = tonalOffset.dark || tonalOffset * 1.5;\n if (!intent[direction]) {\n if (intent.hasOwnProperty(shade)) {\n intent[direction] = intent[shade];\n } else if (direction === 'light') {\n intent.light = lighten(intent.main, tonalOffsetLight);\n } else if (direction === 'dark') {\n intent.dark = darken(intent.main, tonalOffsetDark);\n }\n }\n}\nfunction getDefaultPrimary(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: blue[200],\n light: blue[50],\n dark: blue[400]\n };\n }\n return {\n main: blue[700],\n light: blue[400],\n dark: blue[800]\n };\n}\nfunction getDefaultSecondary(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: purple[200],\n light: purple[50],\n dark: purple[400]\n };\n }\n return {\n main: purple[500],\n light: purple[300],\n dark: purple[700]\n };\n}\nfunction getDefaultError(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: red[500],\n light: red[300],\n dark: red[700]\n };\n }\n return {\n main: red[700],\n light: red[400],\n dark: red[800]\n };\n}\nfunction getDefaultInfo(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: lightBlue[400],\n light: lightBlue[300],\n dark: lightBlue[700]\n };\n }\n return {\n main: lightBlue[700],\n light: lightBlue[500],\n dark: lightBlue[900]\n };\n}\nfunction getDefaultSuccess(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: green[400],\n light: green[300],\n dark: green[700]\n };\n }\n return {\n main: green[800],\n light: green[500],\n dark: green[900]\n };\n}\nfunction getDefaultWarning(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: orange[400],\n light: orange[300],\n dark: orange[700]\n };\n }\n return {\n main: '#ed6c02',\n // closest to orange[800] that pass 3:1.\n light: orange[500],\n dark: orange[900]\n };\n}\nexport default function createPalette(palette) {\n const {\n mode = 'light',\n contrastThreshold = 3,\n tonalOffset = 0.2\n } = palette,\n other = _objectWithoutPropertiesLoose(palette, _excluded);\n const primary = palette.primary || getDefaultPrimary(mode);\n const secondary = palette.secondary || getDefaultSecondary(mode);\n const error = palette.error || getDefaultError(mode);\n const info = palette.info || getDefaultInfo(mode);\n const success = palette.success || getDefaultSuccess(mode);\n const warning = palette.warning || getDefaultWarning(mode);\n\n // Use the same logic as\n // Bootstrap: https://github.com/twbs/bootstrap/blob/1d6e3710dd447de1a200f29e8fa521f8a0908f70/scss/_functions.scss#L59\n // and material-components-web https://github.com/material-components/material-components-web/blob/ac46b8863c4dab9fc22c4c662dc6bd1b65dd652f/packages/mdc-theme/_functions.scss#L54\n function getContrastText(background) {\n const contrastText = getContrastRatio(background, dark.text.primary) >= contrastThreshold ? dark.text.primary : light.text.primary;\n if (process.env.NODE_ENV !== 'production') {\n const contrast = getContrastRatio(background, contrastText);\n if (contrast < 3) {\n console.error([`MUI: The contrast ratio of ${contrast}:1 for ${contrastText} on ${background}`, 'falls below the WCAG recommended absolute minimum contrast ratio of 3:1.', 'https://www.w3.org/TR/2008/REC-WCAG20-20081211/#visual-audio-contrast-contrast'].join('\\n'));\n }\n }\n return contrastText;\n }\n const augmentColor = ({\n color,\n name,\n mainShade = 500,\n lightShade = 300,\n darkShade = 700\n }) => {\n color = _extends({}, color);\n if (!color.main && color[mainShade]) {\n color.main = color[mainShade];\n }\n if (!color.hasOwnProperty('main')) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: The color${name ? ` (${name})` : ''} provided to augmentColor(color) is invalid.\nThe color object needs to have a \\`main\\` property or a \\`${mainShade}\\` property.` : _formatMuiErrorMessage(11, name ? ` (${name})` : '', mainShade));\n }\n if (typeof color.main !== 'string') {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: The color${name ? ` (${name})` : ''} provided to augmentColor(color) is invalid.\n\\`color.main\\` should be a string, but \\`${JSON.stringify(color.main)}\\` was provided instead.\n\nDid you intend to use one of the following approaches?\n\nimport { green } from \"@mui/material/colors\";\n\nconst theme1 = createTheme({ palette: {\n primary: green,\n} });\n\nconst theme2 = createTheme({ palette: {\n primary: { main: green[500] },\n} });` : _formatMuiErrorMessage(12, name ? ` (${name})` : '', JSON.stringify(color.main)));\n }\n addLightOrDark(color, 'light', lightShade, tonalOffset);\n addLightOrDark(color, 'dark', darkShade, tonalOffset);\n if (!color.contrastText) {\n color.contrastText = getContrastText(color.main);\n }\n return color;\n };\n const modes = {\n dark,\n light\n };\n if (process.env.NODE_ENV !== 'production') {\n if (!modes[mode]) {\n console.error(`MUI: The palette mode \\`${mode}\\` is not supported.`);\n }\n }\n const paletteOutput = deepmerge(_extends({\n // A collection of common colors.\n common: _extends({}, common),\n // prevent mutable object.\n // The palette mode, can be light or dark.\n mode,\n // The colors used to represent primary interface elements for a user.\n primary: augmentColor({\n color: primary,\n name: 'primary'\n }),\n // The colors used to represent secondary interface elements for a user.\n secondary: augmentColor({\n color: secondary,\n name: 'secondary',\n mainShade: 'A400',\n lightShade: 'A200',\n darkShade: 'A700'\n }),\n // The colors used to represent interface elements that the user should be made aware of.\n error: augmentColor({\n color: error,\n name: 'error'\n }),\n // The colors used to represent potentially dangerous actions or important messages.\n warning: augmentColor({\n color: warning,\n name: 'warning'\n }),\n // The colors used to present information to the user that is neutral and not necessarily important.\n info: augmentColor({\n color: info,\n name: 'info'\n }),\n // The colors used to indicate the successful completion of an action that user triggered.\n success: augmentColor({\n color: success,\n name: 'success'\n }),\n // The grey colors.\n grey,\n // Used by `getContrastText()` to maximize the contrast between\n // the background and the text.\n contrastThreshold,\n // Takes a background color and returns the text color that maximizes the contrast.\n getContrastText,\n // Generate a rich color object.\n augmentColor,\n // Used by the functions below to shift a color's luminance by approximately\n // two indexes within its tonal palette.\n // E.g., shift from Red 500 to Red 300 or Red 700.\n tonalOffset\n }, modes[mode]), other);\n return paletteOutput;\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"fontFamily\", \"fontSize\", \"fontWeightLight\", \"fontWeightRegular\", \"fontWeightMedium\", \"fontWeightBold\", \"htmlFontSize\", \"allVariants\", \"pxToRem\"];\nimport { deepmerge } from '@mui/utils';\nfunction round(value) {\n return Math.round(value * 1e5) / 1e5;\n}\nconst caseAllCaps = {\n textTransform: 'uppercase'\n};\nconst defaultFontFamily = '\"Roboto\", \"Helvetica\", \"Arial\", sans-serif';\n\n/**\n * @see @link{https://m2.material.io/design/typography/the-type-system.html}\n * @see @link{https://m2.material.io/design/typography/understanding-typography.html}\n */\nexport default function createTypography(palette, typography) {\n const _ref = typeof typography === 'function' ? typography(palette) : typography,\n {\n fontFamily = defaultFontFamily,\n // The default font size of the Material Specification.\n fontSize = 14,\n // px\n fontWeightLight = 300,\n fontWeightRegular = 400,\n fontWeightMedium = 500,\n fontWeightBold = 700,\n // Tell MUI what's the font-size on the html element.\n // 16px is the default font-size used by browsers.\n htmlFontSize = 16,\n // Apply the CSS properties to all the variants.\n allVariants,\n pxToRem: pxToRem2\n } = _ref,\n other = _objectWithoutPropertiesLoose(_ref, _excluded);\n if (process.env.NODE_ENV !== 'production') {\n if (typeof fontSize !== 'number') {\n console.error('MUI: `fontSize` is required to be a number.');\n }\n if (typeof htmlFontSize !== 'number') {\n console.error('MUI: `htmlFontSize` is required to be a number.');\n }\n }\n const coef = fontSize / 14;\n const pxToRem = pxToRem2 || (size => `${size / htmlFontSize * coef}rem`);\n const buildVariant = (fontWeight, size, lineHeight, letterSpacing, casing) => _extends({\n fontFamily,\n fontWeight,\n fontSize: pxToRem(size),\n // Unitless following https://meyerweb.com/eric/thoughts/2006/02/08/unitless-line-heights/\n lineHeight\n }, fontFamily === defaultFontFamily ? {\n letterSpacing: `${round(letterSpacing / size)}em`\n } : {}, casing, allVariants);\n const variants = {\n h1: buildVariant(fontWeightLight, 96, 1.167, -1.5),\n h2: buildVariant(fontWeightLight, 60, 1.2, -0.5),\n h3: buildVariant(fontWeightRegular, 48, 1.167, 0),\n h4: buildVariant(fontWeightRegular, 34, 1.235, 0.25),\n h5: buildVariant(fontWeightRegular, 24, 1.334, 0),\n h6: buildVariant(fontWeightMedium, 20, 1.6, 0.15),\n subtitle1: buildVariant(fontWeightRegular, 16, 1.75, 0.15),\n subtitle2: buildVariant(fontWeightMedium, 14, 1.57, 0.1),\n body1: buildVariant(fontWeightRegular, 16, 1.5, 0.15),\n body2: buildVariant(fontWeightRegular, 14, 1.43, 0.15),\n button: buildVariant(fontWeightMedium, 14, 1.75, 0.4, caseAllCaps),\n caption: buildVariant(fontWeightRegular, 12, 1.66, 0.4),\n overline: buildVariant(fontWeightRegular, 12, 2.66, 1, caseAllCaps),\n // TODO v6: Remove handling of 'inherit' variant from the theme as it is already handled in Material UI's Typography component. Also, remember to remove the associated types.\n inherit: {\n fontFamily: 'inherit',\n fontWeight: 'inherit',\n fontSize: 'inherit',\n lineHeight: 'inherit',\n letterSpacing: 'inherit'\n }\n };\n return deepmerge(_extends({\n htmlFontSize,\n pxToRem,\n fontFamily,\n fontSize,\n fontWeightLight,\n fontWeightRegular,\n fontWeightMedium,\n fontWeightBold\n }, variants), other, {\n clone: false // No need to clone deep\n });\n}","const shadowKeyUmbraOpacity = 0.2;\nconst shadowKeyPenumbraOpacity = 0.14;\nconst shadowAmbientShadowOpacity = 0.12;\nfunction createShadow(...px) {\n return [`${px[0]}px ${px[1]}px ${px[2]}px ${px[3]}px rgba(0,0,0,${shadowKeyUmbraOpacity})`, `${px[4]}px ${px[5]}px ${px[6]}px ${px[7]}px rgba(0,0,0,${shadowKeyPenumbraOpacity})`, `${px[8]}px ${px[9]}px ${px[10]}px ${px[11]}px rgba(0,0,0,${shadowAmbientShadowOpacity})`].join(',');\n}\n\n// Values from https://github.com/material-components/material-components-web/blob/be8747f94574669cb5e7add1a7c54fa41a89cec7/packages/mdc-elevation/_variables.scss\nconst shadows = ['none', createShadow(0, 2, 1, -1, 0, 1, 1, 0, 0, 1, 3, 0), createShadow(0, 3, 1, -2, 0, 2, 2, 0, 0, 1, 5, 0), createShadow(0, 3, 3, -2, 0, 3, 4, 0, 0, 1, 8, 0), createShadow(0, 2, 4, -1, 0, 4, 5, 0, 0, 1, 10, 0), createShadow(0, 3, 5, -1, 0, 5, 8, 0, 0, 1, 14, 0), createShadow(0, 3, 5, -1, 0, 6, 10, 0, 0, 1, 18, 0), createShadow(0, 4, 5, -2, 0, 7, 10, 1, 0, 2, 16, 1), createShadow(0, 5, 5, -3, 0, 8, 10, 1, 0, 3, 14, 2), createShadow(0, 5, 6, -3, 0, 9, 12, 1, 0, 3, 16, 2), createShadow(0, 6, 6, -3, 0, 10, 14, 1, 0, 4, 18, 3), createShadow(0, 6, 7, -4, 0, 11, 15, 1, 0, 4, 20, 3), createShadow(0, 7, 8, -4, 0, 12, 17, 2, 0, 5, 22, 4), createShadow(0, 7, 8, -4, 0, 13, 19, 2, 0, 5, 24, 4), createShadow(0, 7, 9, -4, 0, 14, 21, 2, 0, 5, 26, 4), createShadow(0, 8, 9, -5, 0, 15, 22, 2, 0, 6, 28, 5), createShadow(0, 8, 10, -5, 0, 16, 24, 2, 0, 6, 30, 5), createShadow(0, 8, 11, -5, 0, 17, 26, 2, 0, 6, 32, 5), createShadow(0, 9, 11, -5, 0, 18, 28, 2, 0, 7, 34, 6), createShadow(0, 9, 12, -6, 0, 19, 29, 2, 0, 7, 36, 6), createShadow(0, 10, 13, -6, 0, 20, 31, 3, 0, 8, 38, 7), createShadow(0, 10, 13, -6, 0, 21, 33, 3, 0, 8, 40, 7), createShadow(0, 10, 14, -6, 0, 22, 35, 3, 0, 8, 42, 7), createShadow(0, 11, 14, -7, 0, 23, 36, 3, 0, 9, 44, 8), createShadow(0, 11, 15, -7, 0, 24, 38, 3, 0, 9, 46, 8)];\nexport default shadows;","import _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nconst _excluded = [\"duration\", \"easing\", \"delay\"];\n// Follow https://material.google.com/motion/duration-easing.html#duration-easing-natural-easing-curves\n// to learn the context in which each easing should be used.\nexport const easing = {\n // This is the most common easing curve.\n easeInOut: 'cubic-bezier(0.4, 0, 0.2, 1)',\n // Objects enter the screen at full velocity from off-screen and\n // slowly decelerate to a resting point.\n easeOut: 'cubic-bezier(0.0, 0, 0.2, 1)',\n // Objects leave the screen at full velocity. They do not decelerate when off-screen.\n easeIn: 'cubic-bezier(0.4, 0, 1, 1)',\n // The sharp curve is used by objects that may return to the screen at any time.\n sharp: 'cubic-bezier(0.4, 0, 0.6, 1)'\n};\n\n// Follow https://m2.material.io/guidelines/motion/duration-easing.html#duration-easing-common-durations\n// to learn when use what timing\nexport const duration = {\n shortest: 150,\n shorter: 200,\n short: 250,\n // most basic recommended timing\n standard: 300,\n // this is to be used in complex animations\n complex: 375,\n // recommended when something is entering screen\n enteringScreen: 225,\n // recommended when something is leaving screen\n leavingScreen: 195\n};\nfunction formatMs(milliseconds) {\n return `${Math.round(milliseconds)}ms`;\n}\nfunction getAutoHeightDuration(height) {\n if (!height) {\n return 0;\n }\n const constant = height / 36;\n\n // https://www.wolframalpha.com/input/?i=(4+%2B+15+*+(x+%2F+36+)+**+0.25+%2B+(x+%2F+36)+%2F+5)+*+10\n return Math.round((4 + 15 * constant ** 0.25 + constant / 5) * 10);\n}\nexport default function createTransitions(inputTransitions) {\n const mergedEasing = _extends({}, easing, inputTransitions.easing);\n const mergedDuration = _extends({}, duration, inputTransitions.duration);\n const create = (props = ['all'], options = {}) => {\n const {\n duration: durationOption = mergedDuration.standard,\n easing: easingOption = mergedEasing.easeInOut,\n delay = 0\n } = options,\n other = _objectWithoutPropertiesLoose(options, _excluded);\n if (process.env.NODE_ENV !== 'production') {\n const isString = value => typeof value === 'string';\n // IE11 support, replace with Number.isNaN\n // eslint-disable-next-line no-restricted-globals\n const isNumber = value => !isNaN(parseFloat(value));\n if (!isString(props) && !Array.isArray(props)) {\n console.error('MUI: Argument \"props\" must be a string or Array.');\n }\n if (!isNumber(durationOption) && !isString(durationOption)) {\n console.error(`MUI: Argument \"duration\" must be a number or a string but found ${durationOption}.`);\n }\n if (!isString(easingOption)) {\n console.error('MUI: Argument \"easing\" must be a string.');\n }\n if (!isNumber(delay) && !isString(delay)) {\n console.error('MUI: Argument \"delay\" must be a number or a string.');\n }\n if (typeof options !== 'object') {\n console.error(['MUI: Secong argument of transition.create must be an object.', \"Arguments should be either `create('prop1', options)` or `create(['prop1', 'prop2'], options)`\"].join('\\n'));\n }\n if (Object.keys(other).length !== 0) {\n console.error(`MUI: Unrecognized argument(s) [${Object.keys(other).join(',')}].`);\n }\n }\n return (Array.isArray(props) ? props : [props]).map(animatedProp => `${animatedProp} ${typeof durationOption === 'string' ? durationOption : formatMs(durationOption)} ${easingOption} ${typeof delay === 'string' ? delay : formatMs(delay)}`).join(',');\n };\n return _extends({\n getAutoHeightDuration,\n create\n }, inputTransitions, {\n easing: mergedEasing,\n duration: mergedDuration\n });\n}","// We need to centralize the zIndex definitions as they work\n// like global values in the browser.\nconst zIndex = {\n mobileStepper: 1000,\n fab: 1050,\n speedDial: 1050,\n appBar: 1100,\n drawer: 1200,\n modal: 1300,\n snackbar: 1400,\n tooltip: 1500\n};\nexport default zIndex;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\nconst _excluded = [\"breakpoints\", \"mixins\", \"spacing\", \"palette\", \"transitions\", \"typography\", \"shape\"];\nimport { deepmerge } from '@mui/utils';\nimport { createTheme as systemCreateTheme, unstable_defaultSxConfig as defaultSxConfig, unstable_styleFunctionSx as styleFunctionSx } from '@mui/system';\nimport generateUtilityClass from '@mui/utils/generateUtilityClass';\nimport createMixins from './createMixins';\nimport createPalette from './createPalette';\nimport createTypography from './createTypography';\nimport shadows from './shadows';\nimport createTransitions from './createTransitions';\nimport zIndex from './zIndex';\nfunction createTheme(options = {}, ...args) {\n const {\n mixins: mixinsInput = {},\n palette: paletteInput = {},\n transitions: transitionsInput = {},\n typography: typographyInput = {}\n } = options,\n other = _objectWithoutPropertiesLoose(options, _excluded);\n if (options.vars) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: \\`vars\\` is a private field used for CSS variables support.\nPlease use another name.` : _formatMuiErrorMessage(18));\n }\n const palette = createPalette(paletteInput);\n const systemTheme = systemCreateTheme(options);\n let muiTheme = deepmerge(systemTheme, {\n mixins: createMixins(systemTheme.breakpoints, mixinsInput),\n palette,\n // Don't use [...shadows] until you've verified its transpiled code is not invoking the iterator protocol.\n shadows: shadows.slice(),\n typography: createTypography(palette, typographyInput),\n transitions: createTransitions(transitionsInput),\n zIndex: _extends({}, zIndex)\n });\n muiTheme = deepmerge(muiTheme, other);\n muiTheme = args.reduce((acc, argument) => deepmerge(acc, argument), muiTheme);\n if (process.env.NODE_ENV !== 'production') {\n // TODO v6: Refactor to use globalStateClassesMapping from @mui/utils once `readOnly` state class is used in Rating component.\n const stateClasses = ['active', 'checked', 'completed', 'disabled', 'error', 'expanded', 'focused', 'focusVisible', 'required', 'selected'];\n const traverse = (node, component) => {\n let key;\n\n // eslint-disable-next-line guard-for-in, no-restricted-syntax\n for (key in node) {\n const child = node[key];\n if (stateClasses.indexOf(key) !== -1 && Object.keys(child).length > 0) {\n if (process.env.NODE_ENV !== 'production') {\n const stateClass = generateUtilityClass('', key);\n console.error([`MUI: The \\`${component}\\` component increases ` + `the CSS specificity of the \\`${key}\\` internal state.`, 'You can not override it like this: ', JSON.stringify(node, null, 2), '', `Instead, you need to use the '&.${stateClass}' syntax:`, JSON.stringify({\n root: {\n [`&.${stateClass}`]: child\n }\n }, null, 2), '', 'https://mui.com/r/state-classes-guide'].join('\\n'));\n }\n // Remove the style to prevent global conflicts.\n node[key] = {};\n }\n }\n };\n Object.keys(muiTheme.components).forEach(component => {\n const styleOverrides = muiTheme.components[component].styleOverrides;\n if (styleOverrides && component.indexOf('Mui') === 0) {\n traverse(styleOverrides, component);\n }\n });\n }\n muiTheme.unstable_sxConfig = _extends({}, defaultSxConfig, other == null ? void 0 : other.unstable_sxConfig);\n muiTheme.unstable_sx = function sx(props) {\n return styleFunctionSx({\n sx: props,\n theme: this\n });\n };\n return muiTheme;\n}\nlet warnedOnce = false;\nexport function createMuiTheme(...args) {\n if (process.env.NODE_ENV !== 'production') {\n if (!warnedOnce) {\n warnedOnce = true;\n console.error(['MUI: the createMuiTheme function was renamed to createTheme.', '', \"You should use `import { createTheme } from '@mui/material/styles'`\"].join('\\n'));\n }\n }\n return createTheme(...args);\n}\nexport default createTheme;","'use client';\n\nimport createTheme from './createTheme';\nconst defaultTheme = createTheme();\nexport default defaultTheme;","export default '$$material';","'use client';\n\nimport { useThemeProps as systemUseThemeProps } from '@mui/system';\nimport defaultTheme from './defaultTheme';\nimport THEME_ID from './identifier';\nexport default function useThemeProps({\n props,\n name\n}) {\n return systemUseThemeProps({\n props,\n name,\n defaultTheme,\n themeId: THEME_ID\n });\n}","'use client';\n\nimport { createStyled, shouldForwardProp } from '@mui/system';\nimport defaultTheme from './defaultTheme';\nimport THEME_ID from './identifier';\nexport const rootShouldForwardProp = prop => shouldForwardProp(prop) && prop !== 'classes';\nexport const slotShouldForwardProp = shouldForwardProp;\nconst styled = createStyled({\n themeId: THEME_ID,\n defaultTheme,\n rootShouldForwardProp\n});\nexport default styled;","import generateUtilityClasses from '@mui/utils/generateUtilityClasses';\nimport generateUtilityClass from '@mui/utils/generateUtilityClass';\nexport function getSvgIconUtilityClass(slot) {\n return generateUtilityClass('MuiSvgIcon', slot);\n}\nconst svgIconClasses = generateUtilityClasses('MuiSvgIcon', ['root', 'colorPrimary', 'colorSecondary', 'colorAction', 'colorError', 'colorDisabled', 'fontSizeInherit', 'fontSizeSmall', 'fontSizeMedium', 'fontSizeLarge']);\nexport default svgIconClasses;","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"children\", \"className\", \"color\", \"component\", \"fontSize\", \"htmlColor\", \"inheritViewBox\", \"titleAccess\", \"viewBox\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport clsx from 'clsx';\nimport { unstable_composeClasses as composeClasses } from '@mui/base/composeClasses';\nimport capitalize from '../utils/capitalize';\nimport useThemeProps from '../styles/useThemeProps';\nimport styled from '../styles/styled';\nimport { getSvgIconUtilityClass } from './svgIconClasses';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nimport { jsxs as _jsxs } from \"react/jsx-runtime\";\nconst useUtilityClasses = ownerState => {\n const {\n color,\n fontSize,\n classes\n } = ownerState;\n const slots = {\n root: ['root', color !== 'inherit' && `color${capitalize(color)}`, `fontSize${capitalize(fontSize)}`]\n };\n return composeClasses(slots, getSvgIconUtilityClass, classes);\n};\nconst SvgIconRoot = styled('svg', {\n name: 'MuiSvgIcon',\n slot: 'Root',\n overridesResolver: (props, styles) => {\n const {\n ownerState\n } = props;\n return [styles.root, ownerState.color !== 'inherit' && styles[`color${capitalize(ownerState.color)}`], styles[`fontSize${capitalize(ownerState.fontSize)}`]];\n }\n})(({\n theme,\n ownerState\n}) => {\n var _theme$transitions, _theme$transitions$cr, _theme$transitions2, _theme$typography, _theme$typography$pxT, _theme$typography2, _theme$typography2$px, _theme$typography3, _theme$typography3$px, _palette$ownerState$c, _palette, _palette2, _palette3;\n return {\n userSelect: 'none',\n width: '1em',\n height: '1em',\n display: 'inline-block',\n // the will define the property that has `currentColor`\n // e.g. heroicons uses fill=\"none\" and stroke=\"currentColor\"\n fill: ownerState.hasSvgAsChild ? undefined : 'currentColor',\n flexShrink: 0,\n transition: (_theme$transitions = theme.transitions) == null || (_theme$transitions$cr = _theme$transitions.create) == null ? void 0 : _theme$transitions$cr.call(_theme$transitions, 'fill', {\n duration: (_theme$transitions2 = theme.transitions) == null || (_theme$transitions2 = _theme$transitions2.duration) == null ? void 0 : _theme$transitions2.shorter\n }),\n fontSize: {\n inherit: 'inherit',\n small: ((_theme$typography = theme.typography) == null || (_theme$typography$pxT = _theme$typography.pxToRem) == null ? void 0 : _theme$typography$pxT.call(_theme$typography, 20)) || '1.25rem',\n medium: ((_theme$typography2 = theme.typography) == null || (_theme$typography2$px = _theme$typography2.pxToRem) == null ? void 0 : _theme$typography2$px.call(_theme$typography2, 24)) || '1.5rem',\n large: ((_theme$typography3 = theme.typography) == null || (_theme$typography3$px = _theme$typography3.pxToRem) == null ? void 0 : _theme$typography3$px.call(_theme$typography3, 35)) || '2.1875rem'\n }[ownerState.fontSize],\n // TODO v5 deprecate, v6 remove for sx\n color: (_palette$ownerState$c = (_palette = (theme.vars || theme).palette) == null || (_palette = _palette[ownerState.color]) == null ? void 0 : _palette.main) != null ? _palette$ownerState$c : {\n action: (_palette2 = (theme.vars || theme).palette) == null || (_palette2 = _palette2.action) == null ? void 0 : _palette2.active,\n disabled: (_palette3 = (theme.vars || theme).palette) == null || (_palette3 = _palette3.action) == null ? void 0 : _palette3.disabled,\n inherit: undefined\n }[ownerState.color]\n };\n});\nconst SvgIcon = /*#__PURE__*/React.forwardRef(function SvgIcon(inProps, ref) {\n const props = useThemeProps({\n props: inProps,\n name: 'MuiSvgIcon'\n });\n const {\n children,\n className,\n color = 'inherit',\n component = 'svg',\n fontSize = 'medium',\n htmlColor,\n inheritViewBox = false,\n titleAccess,\n viewBox = '0 0 24 24'\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const hasSvgAsChild = /*#__PURE__*/React.isValidElement(children) && children.type === 'svg';\n const ownerState = _extends({}, props, {\n color,\n component,\n fontSize,\n instanceFontSize: inProps.fontSize,\n inheritViewBox,\n viewBox,\n hasSvgAsChild\n });\n const more = {};\n if (!inheritViewBox) {\n more.viewBox = viewBox;\n }\n const classes = useUtilityClasses(ownerState);\n return /*#__PURE__*/_jsxs(SvgIconRoot, _extends({\n as: component,\n className: clsx(classes.root, className),\n focusable: \"false\",\n color: htmlColor,\n \"aria-hidden\": titleAccess ? undefined : true,\n role: titleAccess ? 'img' : undefined,\n ref: ref\n }, more, other, hasSvgAsChild && children.props, {\n ownerState: ownerState,\n children: [hasSvgAsChild ? children.props.children : children, titleAccess ? /*#__PURE__*/_jsx(\"title\", {\n children: titleAccess\n }) : null]\n }));\n});\nprocess.env.NODE_ENV !== \"production\" ? SvgIcon.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the d.ts file and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * Node passed into the SVG element.\n */\n children: PropTypes.node,\n /**\n * Override or extend the styles applied to the component.\n */\n classes: PropTypes.object,\n /**\n * @ignore\n */\n className: PropTypes.string,\n /**\n * The color of the component.\n * It supports both default and custom theme colors, which can be added as shown in the\n * [palette customization guide](https://mui.com/material-ui/customization/palette/#custom-colors).\n * You can use the `htmlColor` prop to apply a color attribute to the SVG element.\n * @default 'inherit'\n */\n color: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.oneOf(['inherit', 'action', 'disabled', 'primary', 'secondary', 'error', 'info', 'success', 'warning']), PropTypes.string]),\n /**\n * The component used for the root node.\n * Either a string to use a HTML element or a component.\n */\n component: PropTypes.elementType,\n /**\n * The fontSize applied to the icon. Defaults to 24px, but can be configure to inherit font size.\n * @default 'medium'\n */\n fontSize: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.oneOf(['inherit', 'large', 'medium', 'small']), PropTypes.string]),\n /**\n * Applies a color attribute to the SVG element.\n */\n htmlColor: PropTypes.string,\n /**\n * If `true`, the root node will inherit the custom `component`'s viewBox and the `viewBox`\n * prop will be ignored.\n * Useful when you want to reference a custom `component` and have `SvgIcon` pass that\n * `component`'s viewBox to the root node.\n * @default false\n */\n inheritViewBox: PropTypes.bool,\n /**\n * The shape-rendering attribute. The behavior of the different options is described on the\n * [MDN Web Docs](https://developer.mozilla.org/en-US/docs/Web/SVG/Attribute/shape-rendering).\n * If you are having issues with blurry icons you should investigate this prop.\n */\n shapeRendering: PropTypes.string,\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Provides a human-readable title for the element that contains it.\n * https://www.w3.org/TR/SVG-access/#Equivalent\n */\n titleAccess: PropTypes.string,\n /**\n * Allows you to redefine what the coordinates without units mean inside an SVG element.\n * For example, if the SVG element is 500 (width) by 200 (height),\n * and you pass viewBox=\"0 0 50 20\",\n * this means that the coordinates inside the SVG will go from the top left corner (0,0)\n * to bottom right (50,20) and each unit will be worth 10px.\n * @default '0 0 24 24'\n */\n viewBox: PropTypes.string\n} : void 0;\nSvgIcon.muiName = 'SvgIcon';\nexport default SvgIcon;","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport * as React from 'react';\nimport SvgIcon from '../SvgIcon';\n\n/**\n * Private module reserved for @mui packages.\n */\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nexport default function createSvgIcon(path, displayName) {\n function Component(props, ref) {\n return /*#__PURE__*/_jsx(SvgIcon, _extends({\n \"data-testid\": `${displayName}Icon`,\n ref: ref\n }, props, {\n children: path\n }));\n }\n if (process.env.NODE_ENV !== 'production') {\n // Need to set `displayName` on the inner component for React.memo.\n // React prior to 16.14 ignores `displayName` on the wrapper.\n Component.displayName = `${displayName}Icon`;\n }\n Component.muiName = SvgIcon.muiName;\n return /*#__PURE__*/React.memo( /*#__PURE__*/React.forwardRef(Component));\n}","'use client';\n\nimport { unstable_ClassNameGenerator as ClassNameGenerator } from '@mui/base/ClassNameGenerator';\nexport { default as capitalize } from './capitalize';\nexport { default as createChainedFunction } from './createChainedFunction';\nexport { default as createSvgIcon } from './createSvgIcon';\nexport { default as debounce } from './debounce';\nexport { default as deprecatedPropType } from './deprecatedPropType';\nexport { default as isMuiElement } from './isMuiElement';\nexport { default as ownerDocument } from './ownerDocument';\nexport { default as ownerWindow } from './ownerWindow';\nexport { default as requirePropFactory } from './requirePropFactory';\nexport { default as setRef } from './setRef';\nexport { default as unstable_useEnhancedEffect } from './useEnhancedEffect';\nexport { default as unstable_useId } from './useId';\nexport { default as unsupportedProp } from './unsupportedProp';\nexport { default as useControlled } from './useControlled';\nexport { default as useEventCallback } from './useEventCallback';\nexport { default as useForkRef } from './useForkRef';\nexport { default as useIsFocusVisible } from './useIsFocusVisible';\n// TODO: remove this export once ClassNameGenerator is stable\n// eslint-disable-next-line @typescript-eslint/naming-convention\nexport const unstable_ClassNameGenerator = {\n configure: generator => {\n if (process.env.NODE_ENV !== 'production') {\n console.warn(['MUI: `ClassNameGenerator` import from `@mui/material/utils` is outdated and might cause unexpected issues.', '', \"You should use `import { unstable_ClassNameGenerator } from '@mui/material/className'` instead\", '', 'The detail of the issue: https://github.com/mui/material-ui/issues/30011#issuecomment-1024993401', '', 'The updated documentation: https://mui.com/guides/classname-generator/'].join('\\n'));\n }\n ClassNameGenerator.configure(generator);\n }\n};","\"use strict\";\n'use client';\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nObject.defineProperty(exports, \"default\", {\n enumerable: true,\n get: function () {\n return _utils.createSvgIcon;\n }\n});\nvar _utils = require(\"@mui/material/utils\");","\"use strict\";\n\"use client\";\n\nvar _interopRequireDefault = require(\"@babel/runtime/helpers/interopRequireDefault\");\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = void 0;\nvar _createSvgIcon = _interopRequireDefault(require(\"./utils/createSvgIcon\"));\nvar _jsxRuntime = require(\"react/jsx-runtime\");\nvar _default = exports.default = (0, _createSvgIcon.default)( /*#__PURE__*/(0, _jsxRuntime.jsx)(\"path\", {\n d: \"m10 17 5-5-5-5z\"\n}), 'ArrowRight');","/**\n * Determines if a given element is a DOM element name (i.e. not a React component).\n */\nexport function isHostComponent(element) {\n return typeof element === 'string';\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport { isHostComponent } from './isHostComponent';\n\n/**\n * Type of the ownerState based on the type of an element it applies to.\n * This resolves to the provided OwnerState for React components and `undefined` for host components.\n * Falls back to `OwnerState | undefined` when the exact type can't be determined in development time.\n */\n\n/**\n * Appends the ownerState object to the props, merging with the existing one if necessary.\n *\n * @param elementType Type of the element that owns the `existingProps`. If the element is a DOM node or undefined, `ownerState` is not applied.\n * @param otherProps Props of the element.\n * @param ownerState\n */\nexport function appendOwnerState(elementType, otherProps, ownerState) {\n if (elementType === undefined || isHostComponent(elementType)) {\n return otherProps;\n }\n return _extends({}, otherProps, {\n ownerState: _extends({}, otherProps.ownerState, ownerState)\n });\n}","'use client';\n\nimport * as React from 'react';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nconst defaultContextValue = {\n disableDefaultClasses: false\n};\nconst ClassNameConfiguratorContext = /*#__PURE__*/React.createContext(defaultContextValue);\n/**\n * @ignore - internal hook.\n *\n * Wraps the `generateUtilityClass` function and controls how the classes are generated.\n * Currently it only affects whether the classes are applied or not.\n *\n * @returns Function to be called with the `generateUtilityClass` function specific to a component to generate the classes.\n */\nexport function useClassNamesOverride(generateUtilityClass) {\n const {\n disableDefaultClasses\n } = React.useContext(ClassNameConfiguratorContext);\n return slot => {\n if (disableDefaultClasses) {\n return '';\n }\n return generateUtilityClass(slot);\n };\n}\n\n/**\n * Allows to configure the components within to not apply any built-in classes.\n */\nexport function ClassNameConfigurator(props) {\n const {\n disableDefaultClasses,\n children\n } = props;\n const contextValue = React.useMemo(() => ({\n disableDefaultClasses: disableDefaultClasses != null ? disableDefaultClasses : false\n }), [disableDefaultClasses]);\n return /*#__PURE__*/_jsx(ClassNameConfiguratorContext.Provider, {\n value: contextValue,\n children: children\n });\n}","/**\n * Extracts event handlers from a given object.\n * A prop is considered an event handler if it is a function and its name starts with `on`.\n *\n * @param object An object to extract event handlers from.\n * @param excludeKeys An array of keys to exclude from the returned object.\n */\nexport function extractEventHandlers(object, excludeKeys = []) {\n if (object === undefined) {\n return {};\n }\n const result = {};\n Object.keys(object).filter(prop => prop.match(/^on[A-Z]/) && typeof object[prop] === 'function' && !excludeKeys.includes(prop)).forEach(prop => {\n result[prop] = object[prop];\n });\n return result;\n}","/**\n * If `componentProps` is a function, calls it with the provided `ownerState`.\n * Otherwise, just returns `componentProps`.\n */\nexport function resolveComponentProps(componentProps, ownerState, slotState) {\n if (typeof componentProps === 'function') {\n return componentProps(ownerState, slotState);\n }\n return componentProps;\n}","/**\n * Removes event handlers from the given object.\n * A field is considered an event handler if it is a function with a name beginning with `on`.\n *\n * @param object Object to remove event handlers from.\n * @returns Object with event handlers removed.\n */\nexport function omitEventHandlers(object) {\n if (object === undefined) {\n return {};\n }\n const result = {};\n Object.keys(object).filter(prop => !(prop.match(/^on[A-Z]/) && typeof object[prop] === 'function')).forEach(prop => {\n result[prop] = object[prop];\n });\n return result;\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport clsx from 'clsx';\nimport { extractEventHandlers } from './extractEventHandlers';\nimport { omitEventHandlers } from './omitEventHandlers';\n/**\n * Merges the slot component internal props (usually coming from a hook)\n * with the externally provided ones.\n *\n * The merge order is (the latter overrides the former):\n * 1. The internal props (specified as a getter function to work with get*Props hook result)\n * 2. Additional props (specified internally on a Base UI component)\n * 3. External props specified on the owner component. These should only be used on a root slot.\n * 4. External props specified in the `slotProps.*` prop.\n * 5. The `className` prop - combined from all the above.\n * @param parameters\n * @returns\n */\nexport function mergeSlotProps(parameters) {\n const {\n getSlotProps,\n additionalProps,\n externalSlotProps,\n externalForwardedProps,\n className\n } = parameters;\n if (!getSlotProps) {\n // The simpler case - getSlotProps is not defined, so no internal event handlers are defined,\n // so we can simply merge all the props without having to worry about extracting event handlers.\n const joinedClasses = clsx(additionalProps == null ? void 0 : additionalProps.className, className, externalForwardedProps == null ? void 0 : externalForwardedProps.className, externalSlotProps == null ? void 0 : externalSlotProps.className);\n const mergedStyle = _extends({}, additionalProps == null ? void 0 : additionalProps.style, externalForwardedProps == null ? void 0 : externalForwardedProps.style, externalSlotProps == null ? void 0 : externalSlotProps.style);\n const props = _extends({}, additionalProps, externalForwardedProps, externalSlotProps);\n if (joinedClasses.length > 0) {\n props.className = joinedClasses;\n }\n if (Object.keys(mergedStyle).length > 0) {\n props.style = mergedStyle;\n }\n return {\n props,\n internalRef: undefined\n };\n }\n\n // In this case, getSlotProps is responsible for calling the external event handlers.\n // We don't need to include them in the merged props because of this.\n\n const eventHandlers = extractEventHandlers(_extends({}, externalForwardedProps, externalSlotProps));\n const componentsPropsWithoutEventHandlers = omitEventHandlers(externalSlotProps);\n const otherPropsWithoutEventHandlers = omitEventHandlers(externalForwardedProps);\n const internalSlotProps = getSlotProps(eventHandlers);\n\n // The order of classes is important here.\n // Emotion (that we use in libraries consuming Base UI) depends on this order\n // to properly override style. It requires the most important classes to be last\n // (see https://github.com/mui/material-ui/pull/33205) for the related discussion.\n const joinedClasses = clsx(internalSlotProps == null ? void 0 : internalSlotProps.className, additionalProps == null ? void 0 : additionalProps.className, className, externalForwardedProps == null ? void 0 : externalForwardedProps.className, externalSlotProps == null ? void 0 : externalSlotProps.className);\n const mergedStyle = _extends({}, internalSlotProps == null ? void 0 : internalSlotProps.style, additionalProps == null ? void 0 : additionalProps.style, externalForwardedProps == null ? void 0 : externalForwardedProps.style, externalSlotProps == null ? void 0 : externalSlotProps.style);\n const props = _extends({}, internalSlotProps, additionalProps, otherPropsWithoutEventHandlers, componentsPropsWithoutEventHandlers);\n if (joinedClasses.length > 0) {\n props.className = joinedClasses;\n }\n if (Object.keys(mergedStyle).length > 0) {\n props.style = mergedStyle;\n }\n return {\n props,\n internalRef: internalSlotProps.ref\n };\n}","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"elementType\", \"externalSlotProps\", \"ownerState\", \"skipResolvingSlotProps\"];\nimport { unstable_useForkRef as useForkRef } from '@mui/utils';\nimport { appendOwnerState } from './appendOwnerState';\nimport { mergeSlotProps } from './mergeSlotProps';\nimport { resolveComponentProps } from './resolveComponentProps';\n/**\n * @ignore - do not document.\n * Builds the props to be passed into the slot of an unstyled component.\n * It merges the internal props of the component with the ones supplied by the user, allowing to customize the behavior.\n * If the slot component is not a host component, it also merges in the `ownerState`.\n *\n * @param parameters.getSlotProps - A function that returns the props to be passed to the slot component.\n */\nexport function useSlotProps(parameters) {\n var _parameters$additiona;\n const {\n elementType,\n externalSlotProps,\n ownerState,\n skipResolvingSlotProps = false\n } = parameters,\n rest = _objectWithoutPropertiesLoose(parameters, _excluded);\n const resolvedComponentsProps = skipResolvingSlotProps ? {} : resolveComponentProps(externalSlotProps, ownerState);\n const {\n props: mergedProps,\n internalRef\n } = mergeSlotProps(_extends({}, rest, {\n externalSlotProps: resolvedComponentsProps\n }));\n const ref = useForkRef(internalRef, resolvedComponentsProps == null ? void 0 : resolvedComponentsProps.ref, (_parameters$additiona = parameters.additionalProps) == null ? void 0 : _parameters$additiona.ref);\n const props = appendOwnerState(elementType, _extends({}, mergedProps, {\n ref\n }), ownerState);\n return props;\n}","import { globalStateClasses } from '@mui/utils/generateUtilityClass';\nconst GLOBAL_CLASS_PREFIX = 'base';\nfunction buildStateClass(state) {\n return `${GLOBAL_CLASS_PREFIX}--${state}`;\n}\nfunction buildSlotClass(componentName, slot) {\n return `${GLOBAL_CLASS_PREFIX}-${componentName}-${slot}`;\n}\nexport function generateUtilityClass(componentName, slot) {\n const globalStateClass = globalStateClasses[slot];\n return globalStateClass ? buildStateClass(globalStateClass) : buildSlotClass(componentName, slot);\n}\nexport function isGlobalState(slot) {\n return globalStateClasses[slot] !== undefined;\n}","import { generateUtilityClass } from '../generateUtilityClass';\nexport function generateUtilityClasses(componentName, slots) {\n const result = {};\n slots.forEach(slot => {\n result[slot] = generateUtilityClass(componentName, slot);\n });\n return result;\n}","'use client';\n\nimport * as React from 'react';\nimport * as ReactDOM from 'react-dom';\nimport PropTypes from 'prop-types';\nimport { exactProp, HTMLElementType, unstable_useEnhancedEffect as useEnhancedEffect, unstable_useForkRef as useForkRef, unstable_setRef as setRef } from '@mui/utils';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nfunction getContainer(container) {\n return typeof container === 'function' ? container() : container;\n}\n\n/**\n * Portals provide a first-class way to render children into a DOM node\n * that exists outside the DOM hierarchy of the parent component.\n *\n * Demos:\n *\n * - [Portal](https://mui.com/base-ui/react-portal/)\n *\n * API:\n *\n * - [Portal API](https://mui.com/base-ui/react-portal/components-api/#portal)\n */\nconst Portal = /*#__PURE__*/React.forwardRef(function Portal(props, forwardedRef) {\n const {\n children,\n container,\n disablePortal = false\n } = props;\n const [mountNode, setMountNode] = React.useState(null);\n // @ts-expect-error TODO upstream fix\n const handleRef = useForkRef( /*#__PURE__*/React.isValidElement(children) ? children.ref : null, forwardedRef);\n useEnhancedEffect(() => {\n if (!disablePortal) {\n setMountNode(getContainer(container) || document.body);\n }\n }, [container, disablePortal]);\n useEnhancedEffect(() => {\n if (mountNode && !disablePortal) {\n setRef(forwardedRef, mountNode);\n return () => {\n setRef(forwardedRef, null);\n };\n }\n return undefined;\n }, [forwardedRef, mountNode, disablePortal]);\n if (disablePortal) {\n if ( /*#__PURE__*/React.isValidElement(children)) {\n const newProps = {\n ref: handleRef\n };\n return /*#__PURE__*/React.cloneElement(children, newProps);\n }\n return /*#__PURE__*/_jsx(React.Fragment, {\n children: children\n });\n }\n return /*#__PURE__*/_jsx(React.Fragment, {\n children: mountNode ? /*#__PURE__*/ReactDOM.createPortal(children, mountNode) : mountNode\n });\n});\nprocess.env.NODE_ENV !== \"production\" ? Portal.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * The children to render into the `container`.\n */\n children: PropTypes.node,\n /**\n * An HTML element or function that returns one.\n * The `container` will have the portal children appended to it.\n *\n * You can also provide a callback, which is called in a React layout effect.\n * This lets you set the container from a ref, and also makes server-side rendering possible.\n *\n * By default, it uses the body of the top-level document object,\n * so it's simply `document.body` most of the time.\n */\n container: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.func]),\n /**\n * The `children` will be under the DOM hierarchy of the parent component.\n * @default false\n */\n disablePortal: PropTypes.bool\n} : void 0;\nif (process.env.NODE_ENV !== 'production') {\n // eslint-disable-next-line\n Portal['propTypes' + ''] = exactProp(Portal.propTypes);\n}\nexport { Portal };","export var top = 'top';\nexport var bottom = 'bottom';\nexport var right = 'right';\nexport var left = 'left';\nexport var auto = 'auto';\nexport var basePlacements = [top, bottom, right, left];\nexport var start = 'start';\nexport var end = 'end';\nexport var clippingParents = 'clippingParents';\nexport var viewport = 'viewport';\nexport var popper = 'popper';\nexport var reference = 'reference';\nexport var variationPlacements = /*#__PURE__*/basePlacements.reduce(function (acc, placement) {\n return acc.concat([placement + \"-\" + start, placement + \"-\" + end]);\n}, []);\nexport var placements = /*#__PURE__*/[].concat(basePlacements, [auto]).reduce(function (acc, placement) {\n return acc.concat([placement, placement + \"-\" + start, placement + \"-\" + end]);\n}, []); // modifiers that need to read the DOM\n\nexport var beforeRead = 'beforeRead';\nexport var read = 'read';\nexport var afterRead = 'afterRead'; // pure-logic modifiers\n\nexport var beforeMain = 'beforeMain';\nexport var main = 'main';\nexport var afterMain = 'afterMain'; // modifier with the purpose to write to the DOM (or write into a framework state)\n\nexport var beforeWrite = 'beforeWrite';\nexport var write = 'write';\nexport var afterWrite = 'afterWrite';\nexport var modifierPhases = [beforeRead, read, afterRead, beforeMain, main, afterMain, beforeWrite, write, afterWrite];","export default function getNodeName(element) {\n return element ? (element.nodeName || '').toLowerCase() : null;\n}","export default function getWindow(node) {\n if (node == null) {\n return window;\n }\n\n if (node.toString() !== '[object Window]') {\n var ownerDocument = node.ownerDocument;\n return ownerDocument ? ownerDocument.defaultView || window : window;\n }\n\n return node;\n}","import getWindow from \"./getWindow.js\";\n\nfunction isElement(node) {\n var OwnElement = getWindow(node).Element;\n return node instanceof OwnElement || node instanceof Element;\n}\n\nfunction isHTMLElement(node) {\n var OwnElement = getWindow(node).HTMLElement;\n return node instanceof OwnElement || node instanceof HTMLElement;\n}\n\nfunction isShadowRoot(node) {\n // IE 11 has no ShadowRoot\n if (typeof ShadowRoot === 'undefined') {\n return false;\n }\n\n var OwnElement = getWindow(node).ShadowRoot;\n return node instanceof OwnElement || node instanceof ShadowRoot;\n}\n\nexport { isElement, isHTMLElement, isShadowRoot };","import getNodeName from \"../dom-utils/getNodeName.js\";\nimport { isHTMLElement } from \"../dom-utils/instanceOf.js\"; // This modifier takes the styles prepared by the `computeStyles` modifier\n// and applies them to the HTMLElements such as popper and arrow\n\nfunction applyStyles(_ref) {\n var state = _ref.state;\n Object.keys(state.elements).forEach(function (name) {\n var style = state.styles[name] || {};\n var attributes = state.attributes[name] || {};\n var element = state.elements[name]; // arrow is optional + virtual elements\n\n if (!isHTMLElement(element) || !getNodeName(element)) {\n return;\n } // Flow doesn't support to extend this property, but it's the most\n // effective way to apply styles to an HTMLElement\n // $FlowFixMe[cannot-write]\n\n\n Object.assign(element.style, style);\n Object.keys(attributes).forEach(function (name) {\n var value = attributes[name];\n\n if (value === false) {\n element.removeAttribute(name);\n } else {\n element.setAttribute(name, value === true ? '' : value);\n }\n });\n });\n}\n\nfunction effect(_ref2) {\n var state = _ref2.state;\n var initialStyles = {\n popper: {\n position: state.options.strategy,\n left: '0',\n top: '0',\n margin: '0'\n },\n arrow: {\n position: 'absolute'\n },\n reference: {}\n };\n Object.assign(state.elements.popper.style, initialStyles.popper);\n state.styles = initialStyles;\n\n if (state.elements.arrow) {\n Object.assign(state.elements.arrow.style, initialStyles.arrow);\n }\n\n return function () {\n Object.keys(state.elements).forEach(function (name) {\n var element = state.elements[name];\n var attributes = state.attributes[name] || {};\n var styleProperties = Object.keys(state.styles.hasOwnProperty(name) ? state.styles[name] : initialStyles[name]); // Set all values to an empty string to unset them\n\n var style = styleProperties.reduce(function (style, property) {\n style[property] = '';\n return style;\n }, {}); // arrow is optional + virtual elements\n\n if (!isHTMLElement(element) || !getNodeName(element)) {\n return;\n }\n\n Object.assign(element.style, style);\n Object.keys(attributes).forEach(function (attribute) {\n element.removeAttribute(attribute);\n });\n });\n };\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'applyStyles',\n enabled: true,\n phase: 'write',\n fn: applyStyles,\n effect: effect,\n requires: ['computeStyles']\n};","import { auto } from \"../enums.js\";\nexport default function getBasePlacement(placement) {\n return placement.split('-')[0];\n}","export var max = Math.max;\nexport var min = Math.min;\nexport var round = Math.round;","export default function getUAString() {\n var uaData = navigator.userAgentData;\n\n if (uaData != null && uaData.brands && Array.isArray(uaData.brands)) {\n return uaData.brands.map(function (item) {\n return item.brand + \"/\" + item.version;\n }).join(' ');\n }\n\n return navigator.userAgent;\n}","import getUAString from \"../utils/userAgent.js\";\nexport default function isLayoutViewport() {\n return !/^((?!chrome|android).)*safari/i.test(getUAString());\n}","import { isElement, isHTMLElement } from \"./instanceOf.js\";\nimport { round } from \"../utils/math.js\";\nimport getWindow from \"./getWindow.js\";\nimport isLayoutViewport from \"./isLayoutViewport.js\";\nexport default function getBoundingClientRect(element, includeScale, isFixedStrategy) {\n if (includeScale === void 0) {\n includeScale = false;\n }\n\n if (isFixedStrategy === void 0) {\n isFixedStrategy = false;\n }\n\n var clientRect = element.getBoundingClientRect();\n var scaleX = 1;\n var scaleY = 1;\n\n if (includeScale && isHTMLElement(element)) {\n scaleX = element.offsetWidth > 0 ? round(clientRect.width) / element.offsetWidth || 1 : 1;\n scaleY = element.offsetHeight > 0 ? round(clientRect.height) / element.offsetHeight || 1 : 1;\n }\n\n var _ref = isElement(element) ? getWindow(element) : window,\n visualViewport = _ref.visualViewport;\n\n var addVisualOffsets = !isLayoutViewport() && isFixedStrategy;\n var x = (clientRect.left + (addVisualOffsets && visualViewport ? visualViewport.offsetLeft : 0)) / scaleX;\n var y = (clientRect.top + (addVisualOffsets && visualViewport ? visualViewport.offsetTop : 0)) / scaleY;\n var width = clientRect.width / scaleX;\n var height = clientRect.height / scaleY;\n return {\n width: width,\n height: height,\n top: y,\n right: x + width,\n bottom: y + height,\n left: x,\n x: x,\n y: y\n };\n}","import getBoundingClientRect from \"./getBoundingClientRect.js\"; // Returns the layout rect of an element relative to its offsetParent. Layout\n// means it doesn't take into account transforms.\n\nexport default function getLayoutRect(element) {\n var clientRect = getBoundingClientRect(element); // Use the clientRect sizes if it's not been transformed.\n // Fixes https://github.com/popperjs/popper-core/issues/1223\n\n var width = element.offsetWidth;\n var height = element.offsetHeight;\n\n if (Math.abs(clientRect.width - width) <= 1) {\n width = clientRect.width;\n }\n\n if (Math.abs(clientRect.height - height) <= 1) {\n height = clientRect.height;\n }\n\n return {\n x: element.offsetLeft,\n y: element.offsetTop,\n width: width,\n height: height\n };\n}","import { isShadowRoot } from \"./instanceOf.js\";\nexport default function contains(parent, child) {\n var rootNode = child.getRootNode && child.getRootNode(); // First, attempt with faster native method\n\n if (parent.contains(child)) {\n return true;\n } // then fallback to custom implementation with Shadow DOM support\n else if (rootNode && isShadowRoot(rootNode)) {\n var next = child;\n\n do {\n if (next && parent.isSameNode(next)) {\n return true;\n } // $FlowFixMe[prop-missing]: need a better way to handle this...\n\n\n next = next.parentNode || next.host;\n } while (next);\n } // Give up, the result is false\n\n\n return false;\n}","import getWindow from \"./getWindow.js\";\nexport default function getComputedStyle(element) {\n return getWindow(element).getComputedStyle(element);\n}","import getNodeName from \"./getNodeName.js\";\nexport default function isTableElement(element) {\n return ['table', 'td', 'th'].indexOf(getNodeName(element)) >= 0;\n}","import { isElement } from \"./instanceOf.js\";\nexport default function getDocumentElement(element) {\n // $FlowFixMe[incompatible-return]: assume body is always available\n return ((isElement(element) ? element.ownerDocument : // $FlowFixMe[prop-missing]\n element.document) || window.document).documentElement;\n}","import getNodeName from \"./getNodeName.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport { isShadowRoot } from \"./instanceOf.js\";\nexport default function getParentNode(element) {\n if (getNodeName(element) === 'html') {\n return element;\n }\n\n return (// this is a quicker (but less type safe) way to save quite some bytes from the bundle\n // $FlowFixMe[incompatible-return]\n // $FlowFixMe[prop-missing]\n element.assignedSlot || // step into the shadow DOM of the parent of a slotted node\n element.parentNode || ( // DOM Element detected\n isShadowRoot(element) ? element.host : null) || // ShadowRoot detected\n // $FlowFixMe[incompatible-call]: HTMLElement is a Node\n getDocumentElement(element) // fallback\n\n );\n}","import getWindow from \"./getWindow.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport getComputedStyle from \"./getComputedStyle.js\";\nimport { isHTMLElement, isShadowRoot } from \"./instanceOf.js\";\nimport isTableElement from \"./isTableElement.js\";\nimport getParentNode from \"./getParentNode.js\";\nimport getUAString from \"../utils/userAgent.js\";\n\nfunction getTrueOffsetParent(element) {\n if (!isHTMLElement(element) || // https://github.com/popperjs/popper-core/issues/837\n getComputedStyle(element).position === 'fixed') {\n return null;\n }\n\n return element.offsetParent;\n} // `.offsetParent` reports `null` for fixed elements, while absolute elements\n// return the containing block\n\n\nfunction getContainingBlock(element) {\n var isFirefox = /firefox/i.test(getUAString());\n var isIE = /Trident/i.test(getUAString());\n\n if (isIE && isHTMLElement(element)) {\n // In IE 9, 10 and 11 fixed elements containing block is always established by the viewport\n var elementCss = getComputedStyle(element);\n\n if (elementCss.position === 'fixed') {\n return null;\n }\n }\n\n var currentNode = getParentNode(element);\n\n if (isShadowRoot(currentNode)) {\n currentNode = currentNode.host;\n }\n\n while (isHTMLElement(currentNode) && ['html', 'body'].indexOf(getNodeName(currentNode)) < 0) {\n var css = getComputedStyle(currentNode); // This is non-exhaustive but covers the most common CSS properties that\n // create a containing block.\n // https://developer.mozilla.org/en-US/docs/Web/CSS/Containing_block#identifying_the_containing_block\n\n if (css.transform !== 'none' || css.perspective !== 'none' || css.contain === 'paint' || ['transform', 'perspective'].indexOf(css.willChange) !== -1 || isFirefox && css.willChange === 'filter' || isFirefox && css.filter && css.filter !== 'none') {\n return currentNode;\n } else {\n currentNode = currentNode.parentNode;\n }\n }\n\n return null;\n} // Gets the closest ancestor positioned element. Handles some edge cases,\n// such as table ancestors and cross browser bugs.\n\n\nexport default function getOffsetParent(element) {\n var window = getWindow(element);\n var offsetParent = getTrueOffsetParent(element);\n\n while (offsetParent && isTableElement(offsetParent) && getComputedStyle(offsetParent).position === 'static') {\n offsetParent = getTrueOffsetParent(offsetParent);\n }\n\n if (offsetParent && (getNodeName(offsetParent) === 'html' || getNodeName(offsetParent) === 'body' && getComputedStyle(offsetParent).position === 'static')) {\n return window;\n }\n\n return offsetParent || getContainingBlock(element) || window;\n}","export default function getMainAxisFromPlacement(placement) {\n return ['top', 'bottom'].indexOf(placement) >= 0 ? 'x' : 'y';\n}","import { max as mathMax, min as mathMin } from \"./math.js\";\nexport function within(min, value, max) {\n return mathMax(min, mathMin(value, max));\n}\nexport function withinMaxClamp(min, value, max) {\n var v = within(min, value, max);\n return v > max ? max : v;\n}","export default function getFreshSideObject() {\n return {\n top: 0,\n right: 0,\n bottom: 0,\n left: 0\n };\n}","import getFreshSideObject from \"./getFreshSideObject.js\";\nexport default function mergePaddingObject(paddingObject) {\n return Object.assign({}, getFreshSideObject(), paddingObject);\n}","export default function expandToHashMap(value, keys) {\n return keys.reduce(function (hashMap, key) {\n hashMap[key] = value;\n return hashMap;\n }, {});\n}","import getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getLayoutRect from \"../dom-utils/getLayoutRect.js\";\nimport contains from \"../dom-utils/contains.js\";\nimport getOffsetParent from \"../dom-utils/getOffsetParent.js\";\nimport getMainAxisFromPlacement from \"../utils/getMainAxisFromPlacement.js\";\nimport { within } from \"../utils/within.js\";\nimport mergePaddingObject from \"../utils/mergePaddingObject.js\";\nimport expandToHashMap from \"../utils/expandToHashMap.js\";\nimport { left, right, basePlacements, top, bottom } from \"../enums.js\"; // eslint-disable-next-line import/no-unused-modules\n\nvar toPaddingObject = function toPaddingObject(padding, state) {\n padding = typeof padding === 'function' ? padding(Object.assign({}, state.rects, {\n placement: state.placement\n })) : padding;\n return mergePaddingObject(typeof padding !== 'number' ? padding : expandToHashMap(padding, basePlacements));\n};\n\nfunction arrow(_ref) {\n var _state$modifiersData$;\n\n var state = _ref.state,\n name = _ref.name,\n options = _ref.options;\n var arrowElement = state.elements.arrow;\n var popperOffsets = state.modifiersData.popperOffsets;\n var basePlacement = getBasePlacement(state.placement);\n var axis = getMainAxisFromPlacement(basePlacement);\n var isVertical = [left, right].indexOf(basePlacement) >= 0;\n var len = isVertical ? 'height' : 'width';\n\n if (!arrowElement || !popperOffsets) {\n return;\n }\n\n var paddingObject = toPaddingObject(options.padding, state);\n var arrowRect = getLayoutRect(arrowElement);\n var minProp = axis === 'y' ? top : left;\n var maxProp = axis === 'y' ? bottom : right;\n var endDiff = state.rects.reference[len] + state.rects.reference[axis] - popperOffsets[axis] - state.rects.popper[len];\n var startDiff = popperOffsets[axis] - state.rects.reference[axis];\n var arrowOffsetParent = getOffsetParent(arrowElement);\n var clientSize = arrowOffsetParent ? axis === 'y' ? arrowOffsetParent.clientHeight || 0 : arrowOffsetParent.clientWidth || 0 : 0;\n var centerToReference = endDiff / 2 - startDiff / 2; // Make sure the arrow doesn't overflow the popper if the center point is\n // outside of the popper bounds\n\n var min = paddingObject[minProp];\n var max = clientSize - arrowRect[len] - paddingObject[maxProp];\n var center = clientSize / 2 - arrowRect[len] / 2 + centerToReference;\n var offset = within(min, center, max); // Prevents breaking syntax highlighting...\n\n var axisProp = axis;\n state.modifiersData[name] = (_state$modifiersData$ = {}, _state$modifiersData$[axisProp] = offset, _state$modifiersData$.centerOffset = offset - center, _state$modifiersData$);\n}\n\nfunction effect(_ref2) {\n var state = _ref2.state,\n options = _ref2.options;\n var _options$element = options.element,\n arrowElement = _options$element === void 0 ? '[data-popper-arrow]' : _options$element;\n\n if (arrowElement == null) {\n return;\n } // CSS selector\n\n\n if (typeof arrowElement === 'string') {\n arrowElement = state.elements.popper.querySelector(arrowElement);\n\n if (!arrowElement) {\n return;\n }\n }\n\n if (!contains(state.elements.popper, arrowElement)) {\n return;\n }\n\n state.elements.arrow = arrowElement;\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'arrow',\n enabled: true,\n phase: 'main',\n fn: arrow,\n effect: effect,\n requires: ['popperOffsets'],\n requiresIfExists: ['preventOverflow']\n};","export default function getVariation(placement) {\n return placement.split('-')[1];\n}","import { top, left, right, bottom, end } from \"../enums.js\";\nimport getOffsetParent from \"../dom-utils/getOffsetParent.js\";\nimport getWindow from \"../dom-utils/getWindow.js\";\nimport getDocumentElement from \"../dom-utils/getDocumentElement.js\";\nimport getComputedStyle from \"../dom-utils/getComputedStyle.js\";\nimport getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getVariation from \"../utils/getVariation.js\";\nimport { round } from \"../utils/math.js\"; // eslint-disable-next-line import/no-unused-modules\n\nvar unsetSides = {\n top: 'auto',\n right: 'auto',\n bottom: 'auto',\n left: 'auto'\n}; // Round the offsets to the nearest suitable subpixel based on the DPR.\n// Zooming can change the DPR, but it seems to report a value that will\n// cleanly divide the values into the appropriate subpixels.\n\nfunction roundOffsetsByDPR(_ref, win) {\n var x = _ref.x,\n y = _ref.y;\n var dpr = win.devicePixelRatio || 1;\n return {\n x: round(x * dpr) / dpr || 0,\n y: round(y * dpr) / dpr || 0\n };\n}\n\nexport function mapToStyles(_ref2) {\n var _Object$assign2;\n\n var popper = _ref2.popper,\n popperRect = _ref2.popperRect,\n placement = _ref2.placement,\n variation = _ref2.variation,\n offsets = _ref2.offsets,\n position = _ref2.position,\n gpuAcceleration = _ref2.gpuAcceleration,\n adaptive = _ref2.adaptive,\n roundOffsets = _ref2.roundOffsets,\n isFixed = _ref2.isFixed;\n var _offsets$x = offsets.x,\n x = _offsets$x === void 0 ? 0 : _offsets$x,\n _offsets$y = offsets.y,\n y = _offsets$y === void 0 ? 0 : _offsets$y;\n\n var _ref3 = typeof roundOffsets === 'function' ? roundOffsets({\n x: x,\n y: y\n }) : {\n x: x,\n y: y\n };\n\n x = _ref3.x;\n y = _ref3.y;\n var hasX = offsets.hasOwnProperty('x');\n var hasY = offsets.hasOwnProperty('y');\n var sideX = left;\n var sideY = top;\n var win = window;\n\n if (adaptive) {\n var offsetParent = getOffsetParent(popper);\n var heightProp = 'clientHeight';\n var widthProp = 'clientWidth';\n\n if (offsetParent === getWindow(popper)) {\n offsetParent = getDocumentElement(popper);\n\n if (getComputedStyle(offsetParent).position !== 'static' && position === 'absolute') {\n heightProp = 'scrollHeight';\n widthProp = 'scrollWidth';\n }\n } // $FlowFixMe[incompatible-cast]: force type refinement, we compare offsetParent with window above, but Flow doesn't detect it\n\n\n offsetParent = offsetParent;\n\n if (placement === top || (placement === left || placement === right) && variation === end) {\n sideY = bottom;\n var offsetY = isFixed && offsetParent === win && win.visualViewport ? win.visualViewport.height : // $FlowFixMe[prop-missing]\n offsetParent[heightProp];\n y -= offsetY - popperRect.height;\n y *= gpuAcceleration ? 1 : -1;\n }\n\n if (placement === left || (placement === top || placement === bottom) && variation === end) {\n sideX = right;\n var offsetX = isFixed && offsetParent === win && win.visualViewport ? win.visualViewport.width : // $FlowFixMe[prop-missing]\n offsetParent[widthProp];\n x -= offsetX - popperRect.width;\n x *= gpuAcceleration ? 1 : -1;\n }\n }\n\n var commonStyles = Object.assign({\n position: position\n }, adaptive && unsetSides);\n\n var _ref4 = roundOffsets === true ? roundOffsetsByDPR({\n x: x,\n y: y\n }, getWindow(popper)) : {\n x: x,\n y: y\n };\n\n x = _ref4.x;\n y = _ref4.y;\n\n if (gpuAcceleration) {\n var _Object$assign;\n\n return Object.assign({}, commonStyles, (_Object$assign = {}, _Object$assign[sideY] = hasY ? '0' : '', _Object$assign[sideX] = hasX ? '0' : '', _Object$assign.transform = (win.devicePixelRatio || 1) <= 1 ? \"translate(\" + x + \"px, \" + y + \"px)\" : \"translate3d(\" + x + \"px, \" + y + \"px, 0)\", _Object$assign));\n }\n\n return Object.assign({}, commonStyles, (_Object$assign2 = {}, _Object$assign2[sideY] = hasY ? y + \"px\" : '', _Object$assign2[sideX] = hasX ? x + \"px\" : '', _Object$assign2.transform = '', _Object$assign2));\n}\n\nfunction computeStyles(_ref5) {\n var state = _ref5.state,\n options = _ref5.options;\n var _options$gpuAccelerat = options.gpuAcceleration,\n gpuAcceleration = _options$gpuAccelerat === void 0 ? true : _options$gpuAccelerat,\n _options$adaptive = options.adaptive,\n adaptive = _options$adaptive === void 0 ? true : _options$adaptive,\n _options$roundOffsets = options.roundOffsets,\n roundOffsets = _options$roundOffsets === void 0 ? true : _options$roundOffsets;\n var commonStyles = {\n placement: getBasePlacement(state.placement),\n variation: getVariation(state.placement),\n popper: state.elements.popper,\n popperRect: state.rects.popper,\n gpuAcceleration: gpuAcceleration,\n isFixed: state.options.strategy === 'fixed'\n };\n\n if (state.modifiersData.popperOffsets != null) {\n state.styles.popper = Object.assign({}, state.styles.popper, mapToStyles(Object.assign({}, commonStyles, {\n offsets: state.modifiersData.popperOffsets,\n position: state.options.strategy,\n adaptive: adaptive,\n roundOffsets: roundOffsets\n })));\n }\n\n if (state.modifiersData.arrow != null) {\n state.styles.arrow = Object.assign({}, state.styles.arrow, mapToStyles(Object.assign({}, commonStyles, {\n offsets: state.modifiersData.arrow,\n position: 'absolute',\n adaptive: false,\n roundOffsets: roundOffsets\n })));\n }\n\n state.attributes.popper = Object.assign({}, state.attributes.popper, {\n 'data-popper-placement': state.placement\n });\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'computeStyles',\n enabled: true,\n phase: 'beforeWrite',\n fn: computeStyles,\n data: {}\n};","import getWindow from \"../dom-utils/getWindow.js\"; // eslint-disable-next-line import/no-unused-modules\n\nvar passive = {\n passive: true\n};\n\nfunction effect(_ref) {\n var state = _ref.state,\n instance = _ref.instance,\n options = _ref.options;\n var _options$scroll = options.scroll,\n scroll = _options$scroll === void 0 ? true : _options$scroll,\n _options$resize = options.resize,\n resize = _options$resize === void 0 ? true : _options$resize;\n var window = getWindow(state.elements.popper);\n var scrollParents = [].concat(state.scrollParents.reference, state.scrollParents.popper);\n\n if (scroll) {\n scrollParents.forEach(function (scrollParent) {\n scrollParent.addEventListener('scroll', instance.update, passive);\n });\n }\n\n if (resize) {\n window.addEventListener('resize', instance.update, passive);\n }\n\n return function () {\n if (scroll) {\n scrollParents.forEach(function (scrollParent) {\n scrollParent.removeEventListener('scroll', instance.update, passive);\n });\n }\n\n if (resize) {\n window.removeEventListener('resize', instance.update, passive);\n }\n };\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'eventListeners',\n enabled: true,\n phase: 'write',\n fn: function fn() {},\n effect: effect,\n data: {}\n};","var hash = {\n left: 'right',\n right: 'left',\n bottom: 'top',\n top: 'bottom'\n};\nexport default function getOppositePlacement(placement) {\n return placement.replace(/left|right|bottom|top/g, function (matched) {\n return hash[matched];\n });\n}","var hash = {\n start: 'end',\n end: 'start'\n};\nexport default function getOppositeVariationPlacement(placement) {\n return placement.replace(/start|end/g, function (matched) {\n return hash[matched];\n });\n}","import getWindow from \"./getWindow.js\";\nexport default function getWindowScroll(node) {\n var win = getWindow(node);\n var scrollLeft = win.pageXOffset;\n var scrollTop = win.pageYOffset;\n return {\n scrollLeft: scrollLeft,\n scrollTop: scrollTop\n };\n}","import getBoundingClientRect from \"./getBoundingClientRect.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport getWindowScroll from \"./getWindowScroll.js\";\nexport default function getWindowScrollBarX(element) {\n // If has a CSS width greater than the viewport, then this will be\n // incorrect for RTL.\n // Popper 1 is broken in this case and never had a bug report so let's assume\n // it's not an issue. I don't think anyone ever specifies width on \n // anyway.\n // Browsers where the left scrollbar doesn't cause an issue report `0` for\n // this (e.g. Edge 2019, IE11, Safari)\n return getBoundingClientRect(getDocumentElement(element)).left + getWindowScroll(element).scrollLeft;\n}","import getWindow from \"./getWindow.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport getWindowScrollBarX from \"./getWindowScrollBarX.js\";\nimport isLayoutViewport from \"./isLayoutViewport.js\";\nexport default function getViewportRect(element, strategy) {\n var win = getWindow(element);\n var html = getDocumentElement(element);\n var visualViewport = win.visualViewport;\n var width = html.clientWidth;\n var height = html.clientHeight;\n var x = 0;\n var y = 0;\n\n if (visualViewport) {\n width = visualViewport.width;\n height = visualViewport.height;\n var layoutViewport = isLayoutViewport();\n\n if (layoutViewport || !layoutViewport && strategy === 'fixed') {\n x = visualViewport.offsetLeft;\n y = visualViewport.offsetTop;\n }\n }\n\n return {\n width: width,\n height: height,\n x: x + getWindowScrollBarX(element),\n y: y\n };\n}","import getDocumentElement from \"./getDocumentElement.js\";\nimport getComputedStyle from \"./getComputedStyle.js\";\nimport getWindowScrollBarX from \"./getWindowScrollBarX.js\";\nimport getWindowScroll from \"./getWindowScroll.js\";\nimport { max } from \"../utils/math.js\"; // Gets the entire size of the scrollable document area, even extending outside\n// of the `` and `` rect bounds if horizontally scrollable\n\nexport default function getDocumentRect(element) {\n var _element$ownerDocumen;\n\n var html = getDocumentElement(element);\n var winScroll = getWindowScroll(element);\n var body = (_element$ownerDocumen = element.ownerDocument) == null ? void 0 : _element$ownerDocumen.body;\n var width = max(html.scrollWidth, html.clientWidth, body ? body.scrollWidth : 0, body ? body.clientWidth : 0);\n var height = max(html.scrollHeight, html.clientHeight, body ? body.scrollHeight : 0, body ? body.clientHeight : 0);\n var x = -winScroll.scrollLeft + getWindowScrollBarX(element);\n var y = -winScroll.scrollTop;\n\n if (getComputedStyle(body || html).direction === 'rtl') {\n x += max(html.clientWidth, body ? body.clientWidth : 0) - width;\n }\n\n return {\n width: width,\n height: height,\n x: x,\n y: y\n };\n}","import getComputedStyle from \"./getComputedStyle.js\";\nexport default function isScrollParent(element) {\n // Firefox wants us to check `-x` and `-y` variations as well\n var _getComputedStyle = getComputedStyle(element),\n overflow = _getComputedStyle.overflow,\n overflowX = _getComputedStyle.overflowX,\n overflowY = _getComputedStyle.overflowY;\n\n return /auto|scroll|overlay|hidden/.test(overflow + overflowY + overflowX);\n}","import getParentNode from \"./getParentNode.js\";\nimport isScrollParent from \"./isScrollParent.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport { isHTMLElement } from \"./instanceOf.js\";\nexport default function getScrollParent(node) {\n if (['html', 'body', '#document'].indexOf(getNodeName(node)) >= 0) {\n // $FlowFixMe[incompatible-return]: assume body is always available\n return node.ownerDocument.body;\n }\n\n if (isHTMLElement(node) && isScrollParent(node)) {\n return node;\n }\n\n return getScrollParent(getParentNode(node));\n}","import getScrollParent from \"./getScrollParent.js\";\nimport getParentNode from \"./getParentNode.js\";\nimport getWindow from \"./getWindow.js\";\nimport isScrollParent from \"./isScrollParent.js\";\n/*\ngiven a DOM element, return the list of all scroll parents, up the list of ancesors\nuntil we get to the top window object. This list is what we attach scroll listeners\nto, because if any of these parent elements scroll, we'll need to re-calculate the\nreference element's position.\n*/\n\nexport default function listScrollParents(element, list) {\n var _element$ownerDocumen;\n\n if (list === void 0) {\n list = [];\n }\n\n var scrollParent = getScrollParent(element);\n var isBody = scrollParent === ((_element$ownerDocumen = element.ownerDocument) == null ? void 0 : _element$ownerDocumen.body);\n var win = getWindow(scrollParent);\n var target = isBody ? [win].concat(win.visualViewport || [], isScrollParent(scrollParent) ? scrollParent : []) : scrollParent;\n var updatedList = list.concat(target);\n return isBody ? updatedList : // $FlowFixMe[incompatible-call]: isBody tells us target will be an HTMLElement here\n updatedList.concat(listScrollParents(getParentNode(target)));\n}","export default function rectToClientRect(rect) {\n return Object.assign({}, rect, {\n left: rect.x,\n top: rect.y,\n right: rect.x + rect.width,\n bottom: rect.y + rect.height\n });\n}","import { viewport } from \"../enums.js\";\nimport getViewportRect from \"./getViewportRect.js\";\nimport getDocumentRect from \"./getDocumentRect.js\";\nimport listScrollParents from \"./listScrollParents.js\";\nimport getOffsetParent from \"./getOffsetParent.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport getComputedStyle from \"./getComputedStyle.js\";\nimport { isElement, isHTMLElement } from \"./instanceOf.js\";\nimport getBoundingClientRect from \"./getBoundingClientRect.js\";\nimport getParentNode from \"./getParentNode.js\";\nimport contains from \"./contains.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport rectToClientRect from \"../utils/rectToClientRect.js\";\nimport { max, min } from \"../utils/math.js\";\n\nfunction getInnerBoundingClientRect(element, strategy) {\n var rect = getBoundingClientRect(element, false, strategy === 'fixed');\n rect.top = rect.top + element.clientTop;\n rect.left = rect.left + element.clientLeft;\n rect.bottom = rect.top + element.clientHeight;\n rect.right = rect.left + element.clientWidth;\n rect.width = element.clientWidth;\n rect.height = element.clientHeight;\n rect.x = rect.left;\n rect.y = rect.top;\n return rect;\n}\n\nfunction getClientRectFromMixedType(element, clippingParent, strategy) {\n return clippingParent === viewport ? rectToClientRect(getViewportRect(element, strategy)) : isElement(clippingParent) ? getInnerBoundingClientRect(clippingParent, strategy) : rectToClientRect(getDocumentRect(getDocumentElement(element)));\n} // A \"clipping parent\" is an overflowable container with the characteristic of\n// clipping (or hiding) overflowing elements with a position different from\n// `initial`\n\n\nfunction getClippingParents(element) {\n var clippingParents = listScrollParents(getParentNode(element));\n var canEscapeClipping = ['absolute', 'fixed'].indexOf(getComputedStyle(element).position) >= 0;\n var clipperElement = canEscapeClipping && isHTMLElement(element) ? getOffsetParent(element) : element;\n\n if (!isElement(clipperElement)) {\n return [];\n } // $FlowFixMe[incompatible-return]: https://github.com/facebook/flow/issues/1414\n\n\n return clippingParents.filter(function (clippingParent) {\n return isElement(clippingParent) && contains(clippingParent, clipperElement) && getNodeName(clippingParent) !== 'body';\n });\n} // Gets the maximum area that the element is visible in due to any number of\n// clipping parents\n\n\nexport default function getClippingRect(element, boundary, rootBoundary, strategy) {\n var mainClippingParents = boundary === 'clippingParents' ? getClippingParents(element) : [].concat(boundary);\n var clippingParents = [].concat(mainClippingParents, [rootBoundary]);\n var firstClippingParent = clippingParents[0];\n var clippingRect = clippingParents.reduce(function (accRect, clippingParent) {\n var rect = getClientRectFromMixedType(element, clippingParent, strategy);\n accRect.top = max(rect.top, accRect.top);\n accRect.right = min(rect.right, accRect.right);\n accRect.bottom = min(rect.bottom, accRect.bottom);\n accRect.left = max(rect.left, accRect.left);\n return accRect;\n }, getClientRectFromMixedType(element, firstClippingParent, strategy));\n clippingRect.width = clippingRect.right - clippingRect.left;\n clippingRect.height = clippingRect.bottom - clippingRect.top;\n clippingRect.x = clippingRect.left;\n clippingRect.y = clippingRect.top;\n return clippingRect;\n}","import getBasePlacement from \"./getBasePlacement.js\";\nimport getVariation from \"./getVariation.js\";\nimport getMainAxisFromPlacement from \"./getMainAxisFromPlacement.js\";\nimport { top, right, bottom, left, start, end } from \"../enums.js\";\nexport default function computeOffsets(_ref) {\n var reference = _ref.reference,\n element = _ref.element,\n placement = _ref.placement;\n var basePlacement = placement ? getBasePlacement(placement) : null;\n var variation = placement ? getVariation(placement) : null;\n var commonX = reference.x + reference.width / 2 - element.width / 2;\n var commonY = reference.y + reference.height / 2 - element.height / 2;\n var offsets;\n\n switch (basePlacement) {\n case top:\n offsets = {\n x: commonX,\n y: reference.y - element.height\n };\n break;\n\n case bottom:\n offsets = {\n x: commonX,\n y: reference.y + reference.height\n };\n break;\n\n case right:\n offsets = {\n x: reference.x + reference.width,\n y: commonY\n };\n break;\n\n case left:\n offsets = {\n x: reference.x - element.width,\n y: commonY\n };\n break;\n\n default:\n offsets = {\n x: reference.x,\n y: reference.y\n };\n }\n\n var mainAxis = basePlacement ? getMainAxisFromPlacement(basePlacement) : null;\n\n if (mainAxis != null) {\n var len = mainAxis === 'y' ? 'height' : 'width';\n\n switch (variation) {\n case start:\n offsets[mainAxis] = offsets[mainAxis] - (reference[len] / 2 - element[len] / 2);\n break;\n\n case end:\n offsets[mainAxis] = offsets[mainAxis] + (reference[len] / 2 - element[len] / 2);\n break;\n\n default:\n }\n }\n\n return offsets;\n}","import getClippingRect from \"../dom-utils/getClippingRect.js\";\nimport getDocumentElement from \"../dom-utils/getDocumentElement.js\";\nimport getBoundingClientRect from \"../dom-utils/getBoundingClientRect.js\";\nimport computeOffsets from \"./computeOffsets.js\";\nimport rectToClientRect from \"./rectToClientRect.js\";\nimport { clippingParents, reference, popper, bottom, top, right, basePlacements, viewport } from \"../enums.js\";\nimport { isElement } from \"../dom-utils/instanceOf.js\";\nimport mergePaddingObject from \"./mergePaddingObject.js\";\nimport expandToHashMap from \"./expandToHashMap.js\"; // eslint-disable-next-line import/no-unused-modules\n\nexport default function detectOverflow(state, options) {\n if (options === void 0) {\n options = {};\n }\n\n var _options = options,\n _options$placement = _options.placement,\n placement = _options$placement === void 0 ? state.placement : _options$placement,\n _options$strategy = _options.strategy,\n strategy = _options$strategy === void 0 ? state.strategy : _options$strategy,\n _options$boundary = _options.boundary,\n boundary = _options$boundary === void 0 ? clippingParents : _options$boundary,\n _options$rootBoundary = _options.rootBoundary,\n rootBoundary = _options$rootBoundary === void 0 ? viewport : _options$rootBoundary,\n _options$elementConte = _options.elementContext,\n elementContext = _options$elementConte === void 0 ? popper : _options$elementConte,\n _options$altBoundary = _options.altBoundary,\n altBoundary = _options$altBoundary === void 0 ? false : _options$altBoundary,\n _options$padding = _options.padding,\n padding = _options$padding === void 0 ? 0 : _options$padding;\n var paddingObject = mergePaddingObject(typeof padding !== 'number' ? padding : expandToHashMap(padding, basePlacements));\n var altContext = elementContext === popper ? reference : popper;\n var popperRect = state.rects.popper;\n var element = state.elements[altBoundary ? altContext : elementContext];\n var clippingClientRect = getClippingRect(isElement(element) ? element : element.contextElement || getDocumentElement(state.elements.popper), boundary, rootBoundary, strategy);\n var referenceClientRect = getBoundingClientRect(state.elements.reference);\n var popperOffsets = computeOffsets({\n reference: referenceClientRect,\n element: popperRect,\n strategy: 'absolute',\n placement: placement\n });\n var popperClientRect = rectToClientRect(Object.assign({}, popperRect, popperOffsets));\n var elementClientRect = elementContext === popper ? popperClientRect : referenceClientRect; // positive = overflowing the clipping rect\n // 0 or negative = within the clipping rect\n\n var overflowOffsets = {\n top: clippingClientRect.top - elementClientRect.top + paddingObject.top,\n bottom: elementClientRect.bottom - clippingClientRect.bottom + paddingObject.bottom,\n left: clippingClientRect.left - elementClientRect.left + paddingObject.left,\n right: elementClientRect.right - clippingClientRect.right + paddingObject.right\n };\n var offsetData = state.modifiersData.offset; // Offsets can be applied only to the popper element\n\n if (elementContext === popper && offsetData) {\n var offset = offsetData[placement];\n Object.keys(overflowOffsets).forEach(function (key) {\n var multiply = [right, bottom].indexOf(key) >= 0 ? 1 : -1;\n var axis = [top, bottom].indexOf(key) >= 0 ? 'y' : 'x';\n overflowOffsets[key] += offset[axis] * multiply;\n });\n }\n\n return overflowOffsets;\n}","import getVariation from \"./getVariation.js\";\nimport { variationPlacements, basePlacements, placements as allPlacements } from \"../enums.js\";\nimport detectOverflow from \"./detectOverflow.js\";\nimport getBasePlacement from \"./getBasePlacement.js\";\nexport default function computeAutoPlacement(state, options) {\n if (options === void 0) {\n options = {};\n }\n\n var _options = options,\n placement = _options.placement,\n boundary = _options.boundary,\n rootBoundary = _options.rootBoundary,\n padding = _options.padding,\n flipVariations = _options.flipVariations,\n _options$allowedAutoP = _options.allowedAutoPlacements,\n allowedAutoPlacements = _options$allowedAutoP === void 0 ? allPlacements : _options$allowedAutoP;\n var variation = getVariation(placement);\n var placements = variation ? flipVariations ? variationPlacements : variationPlacements.filter(function (placement) {\n return getVariation(placement) === variation;\n }) : basePlacements;\n var allowedPlacements = placements.filter(function (placement) {\n return allowedAutoPlacements.indexOf(placement) >= 0;\n });\n\n if (allowedPlacements.length === 0) {\n allowedPlacements = placements;\n } // $FlowFixMe[incompatible-type]: Flow seems to have problems with two array unions...\n\n\n var overflows = allowedPlacements.reduce(function (acc, placement) {\n acc[placement] = detectOverflow(state, {\n placement: placement,\n boundary: boundary,\n rootBoundary: rootBoundary,\n padding: padding\n })[getBasePlacement(placement)];\n return acc;\n }, {});\n return Object.keys(overflows).sort(function (a, b) {\n return overflows[a] - overflows[b];\n });\n}","import getOppositePlacement from \"../utils/getOppositePlacement.js\";\nimport getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getOppositeVariationPlacement from \"../utils/getOppositeVariationPlacement.js\";\nimport detectOverflow from \"../utils/detectOverflow.js\";\nimport computeAutoPlacement from \"../utils/computeAutoPlacement.js\";\nimport { bottom, top, start, right, left, auto } from \"../enums.js\";\nimport getVariation from \"../utils/getVariation.js\"; // eslint-disable-next-line import/no-unused-modules\n\nfunction getExpandedFallbackPlacements(placement) {\n if (getBasePlacement(placement) === auto) {\n return [];\n }\n\n var oppositePlacement = getOppositePlacement(placement);\n return [getOppositeVariationPlacement(placement), oppositePlacement, getOppositeVariationPlacement(oppositePlacement)];\n}\n\nfunction flip(_ref) {\n var state = _ref.state,\n options = _ref.options,\n name = _ref.name;\n\n if (state.modifiersData[name]._skip) {\n return;\n }\n\n var _options$mainAxis = options.mainAxis,\n checkMainAxis = _options$mainAxis === void 0 ? true : _options$mainAxis,\n _options$altAxis = options.altAxis,\n checkAltAxis = _options$altAxis === void 0 ? true : _options$altAxis,\n specifiedFallbackPlacements = options.fallbackPlacements,\n padding = options.padding,\n boundary = options.boundary,\n rootBoundary = options.rootBoundary,\n altBoundary = options.altBoundary,\n _options$flipVariatio = options.flipVariations,\n flipVariations = _options$flipVariatio === void 0 ? true : _options$flipVariatio,\n allowedAutoPlacements = options.allowedAutoPlacements;\n var preferredPlacement = state.options.placement;\n var basePlacement = getBasePlacement(preferredPlacement);\n var isBasePlacement = basePlacement === preferredPlacement;\n var fallbackPlacements = specifiedFallbackPlacements || (isBasePlacement || !flipVariations ? [getOppositePlacement(preferredPlacement)] : getExpandedFallbackPlacements(preferredPlacement));\n var placements = [preferredPlacement].concat(fallbackPlacements).reduce(function (acc, placement) {\n return acc.concat(getBasePlacement(placement) === auto ? computeAutoPlacement(state, {\n placement: placement,\n boundary: boundary,\n rootBoundary: rootBoundary,\n padding: padding,\n flipVariations: flipVariations,\n allowedAutoPlacements: allowedAutoPlacements\n }) : placement);\n }, []);\n var referenceRect = state.rects.reference;\n var popperRect = state.rects.popper;\n var checksMap = new Map();\n var makeFallbackChecks = true;\n var firstFittingPlacement = placements[0];\n\n for (var i = 0; i < placements.length; i++) {\n var placement = placements[i];\n\n var _basePlacement = getBasePlacement(placement);\n\n var isStartVariation = getVariation(placement) === start;\n var isVertical = [top, bottom].indexOf(_basePlacement) >= 0;\n var len = isVertical ? 'width' : 'height';\n var overflow = detectOverflow(state, {\n placement: placement,\n boundary: boundary,\n rootBoundary: rootBoundary,\n altBoundary: altBoundary,\n padding: padding\n });\n var mainVariationSide = isVertical ? isStartVariation ? right : left : isStartVariation ? bottom : top;\n\n if (referenceRect[len] > popperRect[len]) {\n mainVariationSide = getOppositePlacement(mainVariationSide);\n }\n\n var altVariationSide = getOppositePlacement(mainVariationSide);\n var checks = [];\n\n if (checkMainAxis) {\n checks.push(overflow[_basePlacement] <= 0);\n }\n\n if (checkAltAxis) {\n checks.push(overflow[mainVariationSide] <= 0, overflow[altVariationSide] <= 0);\n }\n\n if (checks.every(function (check) {\n return check;\n })) {\n firstFittingPlacement = placement;\n makeFallbackChecks = false;\n break;\n }\n\n checksMap.set(placement, checks);\n }\n\n if (makeFallbackChecks) {\n // `2` may be desired in some cases – research later\n var numberOfChecks = flipVariations ? 3 : 1;\n\n var _loop = function _loop(_i) {\n var fittingPlacement = placements.find(function (placement) {\n var checks = checksMap.get(placement);\n\n if (checks) {\n return checks.slice(0, _i).every(function (check) {\n return check;\n });\n }\n });\n\n if (fittingPlacement) {\n firstFittingPlacement = fittingPlacement;\n return \"break\";\n }\n };\n\n for (var _i = numberOfChecks; _i > 0; _i--) {\n var _ret = _loop(_i);\n\n if (_ret === \"break\") break;\n }\n }\n\n if (state.placement !== firstFittingPlacement) {\n state.modifiersData[name]._skip = true;\n state.placement = firstFittingPlacement;\n state.reset = true;\n }\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'flip',\n enabled: true,\n phase: 'main',\n fn: flip,\n requiresIfExists: ['offset'],\n data: {\n _skip: false\n }\n};","import { top, bottom, left, right } from \"../enums.js\";\nimport detectOverflow from \"../utils/detectOverflow.js\";\n\nfunction getSideOffsets(overflow, rect, preventedOffsets) {\n if (preventedOffsets === void 0) {\n preventedOffsets = {\n x: 0,\n y: 0\n };\n }\n\n return {\n top: overflow.top - rect.height - preventedOffsets.y,\n right: overflow.right - rect.width + preventedOffsets.x,\n bottom: overflow.bottom - rect.height + preventedOffsets.y,\n left: overflow.left - rect.width - preventedOffsets.x\n };\n}\n\nfunction isAnySideFullyClipped(overflow) {\n return [top, right, bottom, left].some(function (side) {\n return overflow[side] >= 0;\n });\n}\n\nfunction hide(_ref) {\n var state = _ref.state,\n name = _ref.name;\n var referenceRect = state.rects.reference;\n var popperRect = state.rects.popper;\n var preventedOffsets = state.modifiersData.preventOverflow;\n var referenceOverflow = detectOverflow(state, {\n elementContext: 'reference'\n });\n var popperAltOverflow = detectOverflow(state, {\n altBoundary: true\n });\n var referenceClippingOffsets = getSideOffsets(referenceOverflow, referenceRect);\n var popperEscapeOffsets = getSideOffsets(popperAltOverflow, popperRect, preventedOffsets);\n var isReferenceHidden = isAnySideFullyClipped(referenceClippingOffsets);\n var hasPopperEscaped = isAnySideFullyClipped(popperEscapeOffsets);\n state.modifiersData[name] = {\n referenceClippingOffsets: referenceClippingOffsets,\n popperEscapeOffsets: popperEscapeOffsets,\n isReferenceHidden: isReferenceHidden,\n hasPopperEscaped: hasPopperEscaped\n };\n state.attributes.popper = Object.assign({}, state.attributes.popper, {\n 'data-popper-reference-hidden': isReferenceHidden,\n 'data-popper-escaped': hasPopperEscaped\n });\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'hide',\n enabled: true,\n phase: 'main',\n requiresIfExists: ['preventOverflow'],\n fn: hide\n};","import getBasePlacement from \"../utils/getBasePlacement.js\";\nimport { top, left, right, placements } from \"../enums.js\"; // eslint-disable-next-line import/no-unused-modules\n\nexport function distanceAndSkiddingToXY(placement, rects, offset) {\n var basePlacement = getBasePlacement(placement);\n var invertDistance = [left, top].indexOf(basePlacement) >= 0 ? -1 : 1;\n\n var _ref = typeof offset === 'function' ? offset(Object.assign({}, rects, {\n placement: placement\n })) : offset,\n skidding = _ref[0],\n distance = _ref[1];\n\n skidding = skidding || 0;\n distance = (distance || 0) * invertDistance;\n return [left, right].indexOf(basePlacement) >= 0 ? {\n x: distance,\n y: skidding\n } : {\n x: skidding,\n y: distance\n };\n}\n\nfunction offset(_ref2) {\n var state = _ref2.state,\n options = _ref2.options,\n name = _ref2.name;\n var _options$offset = options.offset,\n offset = _options$offset === void 0 ? [0, 0] : _options$offset;\n var data = placements.reduce(function (acc, placement) {\n acc[placement] = distanceAndSkiddingToXY(placement, state.rects, offset);\n return acc;\n }, {});\n var _data$state$placement = data[state.placement],\n x = _data$state$placement.x,\n y = _data$state$placement.y;\n\n if (state.modifiersData.popperOffsets != null) {\n state.modifiersData.popperOffsets.x += x;\n state.modifiersData.popperOffsets.y += y;\n }\n\n state.modifiersData[name] = data;\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'offset',\n enabled: true,\n phase: 'main',\n requires: ['popperOffsets'],\n fn: offset\n};","import computeOffsets from \"../utils/computeOffsets.js\";\n\nfunction popperOffsets(_ref) {\n var state = _ref.state,\n name = _ref.name;\n // Offsets are the actual position the popper needs to have to be\n // properly positioned near its reference element\n // This is the most basic placement, and will be adjusted by\n // the modifiers in the next step\n state.modifiersData[name] = computeOffsets({\n reference: state.rects.reference,\n element: state.rects.popper,\n strategy: 'absolute',\n placement: state.placement\n });\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'popperOffsets',\n enabled: true,\n phase: 'read',\n fn: popperOffsets,\n data: {}\n};","export default function getAltAxis(axis) {\n return axis === 'x' ? 'y' : 'x';\n}","import { top, left, right, bottom, start } from \"../enums.js\";\nimport getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getMainAxisFromPlacement from \"../utils/getMainAxisFromPlacement.js\";\nimport getAltAxis from \"../utils/getAltAxis.js\";\nimport { within, withinMaxClamp } from \"../utils/within.js\";\nimport getLayoutRect from \"../dom-utils/getLayoutRect.js\";\nimport getOffsetParent from \"../dom-utils/getOffsetParent.js\";\nimport detectOverflow from \"../utils/detectOverflow.js\";\nimport getVariation from \"../utils/getVariation.js\";\nimport getFreshSideObject from \"../utils/getFreshSideObject.js\";\nimport { min as mathMin, max as mathMax } from \"../utils/math.js\";\n\nfunction preventOverflow(_ref) {\n var state = _ref.state,\n options = _ref.options,\n name = _ref.name;\n var _options$mainAxis = options.mainAxis,\n checkMainAxis = _options$mainAxis === void 0 ? true : _options$mainAxis,\n _options$altAxis = options.altAxis,\n checkAltAxis = _options$altAxis === void 0 ? false : _options$altAxis,\n boundary = options.boundary,\n rootBoundary = options.rootBoundary,\n altBoundary = options.altBoundary,\n padding = options.padding,\n _options$tether = options.tether,\n tether = _options$tether === void 0 ? true : _options$tether,\n _options$tetherOffset = options.tetherOffset,\n tetherOffset = _options$tetherOffset === void 0 ? 0 : _options$tetherOffset;\n var overflow = detectOverflow(state, {\n boundary: boundary,\n rootBoundary: rootBoundary,\n padding: padding,\n altBoundary: altBoundary\n });\n var basePlacement = getBasePlacement(state.placement);\n var variation = getVariation(state.placement);\n var isBasePlacement = !variation;\n var mainAxis = getMainAxisFromPlacement(basePlacement);\n var altAxis = getAltAxis(mainAxis);\n var popperOffsets = state.modifiersData.popperOffsets;\n var referenceRect = state.rects.reference;\n var popperRect = state.rects.popper;\n var tetherOffsetValue = typeof tetherOffset === 'function' ? tetherOffset(Object.assign({}, state.rects, {\n placement: state.placement\n })) : tetherOffset;\n var normalizedTetherOffsetValue = typeof tetherOffsetValue === 'number' ? {\n mainAxis: tetherOffsetValue,\n altAxis: tetherOffsetValue\n } : Object.assign({\n mainAxis: 0,\n altAxis: 0\n }, tetherOffsetValue);\n var offsetModifierState = state.modifiersData.offset ? state.modifiersData.offset[state.placement] : null;\n var data = {\n x: 0,\n y: 0\n };\n\n if (!popperOffsets) {\n return;\n }\n\n if (checkMainAxis) {\n var _offsetModifierState$;\n\n var mainSide = mainAxis === 'y' ? top : left;\n var altSide = mainAxis === 'y' ? bottom : right;\n var len = mainAxis === 'y' ? 'height' : 'width';\n var offset = popperOffsets[mainAxis];\n var min = offset + overflow[mainSide];\n var max = offset - overflow[altSide];\n var additive = tether ? -popperRect[len] / 2 : 0;\n var minLen = variation === start ? referenceRect[len] : popperRect[len];\n var maxLen = variation === start ? -popperRect[len] : -referenceRect[len]; // We need to include the arrow in the calculation so the arrow doesn't go\n // outside the reference bounds\n\n var arrowElement = state.elements.arrow;\n var arrowRect = tether && arrowElement ? getLayoutRect(arrowElement) : {\n width: 0,\n height: 0\n };\n var arrowPaddingObject = state.modifiersData['arrow#persistent'] ? state.modifiersData['arrow#persistent'].padding : getFreshSideObject();\n var arrowPaddingMin = arrowPaddingObject[mainSide];\n var arrowPaddingMax = arrowPaddingObject[altSide]; // If the reference length is smaller than the arrow length, we don't want\n // to include its full size in the calculation. If the reference is small\n // and near the edge of a boundary, the popper can overflow even if the\n // reference is not overflowing as well (e.g. virtual elements with no\n // width or height)\n\n var arrowLen = within(0, referenceRect[len], arrowRect[len]);\n var minOffset = isBasePlacement ? referenceRect[len] / 2 - additive - arrowLen - arrowPaddingMin - normalizedTetherOffsetValue.mainAxis : minLen - arrowLen - arrowPaddingMin - normalizedTetherOffsetValue.mainAxis;\n var maxOffset = isBasePlacement ? -referenceRect[len] / 2 + additive + arrowLen + arrowPaddingMax + normalizedTetherOffsetValue.mainAxis : maxLen + arrowLen + arrowPaddingMax + normalizedTetherOffsetValue.mainAxis;\n var arrowOffsetParent = state.elements.arrow && getOffsetParent(state.elements.arrow);\n var clientOffset = arrowOffsetParent ? mainAxis === 'y' ? arrowOffsetParent.clientTop || 0 : arrowOffsetParent.clientLeft || 0 : 0;\n var offsetModifierValue = (_offsetModifierState$ = offsetModifierState == null ? void 0 : offsetModifierState[mainAxis]) != null ? _offsetModifierState$ : 0;\n var tetherMin = offset + minOffset - offsetModifierValue - clientOffset;\n var tetherMax = offset + maxOffset - offsetModifierValue;\n var preventedOffset = within(tether ? mathMin(min, tetherMin) : min, offset, tether ? mathMax(max, tetherMax) : max);\n popperOffsets[mainAxis] = preventedOffset;\n data[mainAxis] = preventedOffset - offset;\n }\n\n if (checkAltAxis) {\n var _offsetModifierState$2;\n\n var _mainSide = mainAxis === 'x' ? top : left;\n\n var _altSide = mainAxis === 'x' ? bottom : right;\n\n var _offset = popperOffsets[altAxis];\n\n var _len = altAxis === 'y' ? 'height' : 'width';\n\n var _min = _offset + overflow[_mainSide];\n\n var _max = _offset - overflow[_altSide];\n\n var isOriginSide = [top, left].indexOf(basePlacement) !== -1;\n\n var _offsetModifierValue = (_offsetModifierState$2 = offsetModifierState == null ? void 0 : offsetModifierState[altAxis]) != null ? _offsetModifierState$2 : 0;\n\n var _tetherMin = isOriginSide ? _min : _offset - referenceRect[_len] - popperRect[_len] - _offsetModifierValue + normalizedTetherOffsetValue.altAxis;\n\n var _tetherMax = isOriginSide ? _offset + referenceRect[_len] + popperRect[_len] - _offsetModifierValue - normalizedTetherOffsetValue.altAxis : _max;\n\n var _preventedOffset = tether && isOriginSide ? withinMaxClamp(_tetherMin, _offset, _tetherMax) : within(tether ? _tetherMin : _min, _offset, tether ? _tetherMax : _max);\n\n popperOffsets[altAxis] = _preventedOffset;\n data[altAxis] = _preventedOffset - _offset;\n }\n\n state.modifiersData[name] = data;\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'preventOverflow',\n enabled: true,\n phase: 'main',\n fn: preventOverflow,\n requiresIfExists: ['offset']\n};","export default function getHTMLElementScroll(element) {\n return {\n scrollLeft: element.scrollLeft,\n scrollTop: element.scrollTop\n };\n}","import getWindowScroll from \"./getWindowScroll.js\";\nimport getWindow from \"./getWindow.js\";\nimport { isHTMLElement } from \"./instanceOf.js\";\nimport getHTMLElementScroll from \"./getHTMLElementScroll.js\";\nexport default function getNodeScroll(node) {\n if (node === getWindow(node) || !isHTMLElement(node)) {\n return getWindowScroll(node);\n } else {\n return getHTMLElementScroll(node);\n }\n}","import getBoundingClientRect from \"./getBoundingClientRect.js\";\nimport getNodeScroll from \"./getNodeScroll.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport { isHTMLElement } from \"./instanceOf.js\";\nimport getWindowScrollBarX from \"./getWindowScrollBarX.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport isScrollParent from \"./isScrollParent.js\";\nimport { round } from \"../utils/math.js\";\n\nfunction isElementScaled(element) {\n var rect = element.getBoundingClientRect();\n var scaleX = round(rect.width) / element.offsetWidth || 1;\n var scaleY = round(rect.height) / element.offsetHeight || 1;\n return scaleX !== 1 || scaleY !== 1;\n} // Returns the composite rect of an element relative to its offsetParent.\n// Composite means it takes into account transforms as well as layout.\n\n\nexport default function getCompositeRect(elementOrVirtualElement, offsetParent, isFixed) {\n if (isFixed === void 0) {\n isFixed = false;\n }\n\n var isOffsetParentAnElement = isHTMLElement(offsetParent);\n var offsetParentIsScaled = isHTMLElement(offsetParent) && isElementScaled(offsetParent);\n var documentElement = getDocumentElement(offsetParent);\n var rect = getBoundingClientRect(elementOrVirtualElement, offsetParentIsScaled, isFixed);\n var scroll = {\n scrollLeft: 0,\n scrollTop: 0\n };\n var offsets = {\n x: 0,\n y: 0\n };\n\n if (isOffsetParentAnElement || !isOffsetParentAnElement && !isFixed) {\n if (getNodeName(offsetParent) !== 'body' || // https://github.com/popperjs/popper-core/issues/1078\n isScrollParent(documentElement)) {\n scroll = getNodeScroll(offsetParent);\n }\n\n if (isHTMLElement(offsetParent)) {\n offsets = getBoundingClientRect(offsetParent, true);\n offsets.x += offsetParent.clientLeft;\n offsets.y += offsetParent.clientTop;\n } else if (documentElement) {\n offsets.x = getWindowScrollBarX(documentElement);\n }\n }\n\n return {\n x: rect.left + scroll.scrollLeft - offsets.x,\n y: rect.top + scroll.scrollTop - offsets.y,\n width: rect.width,\n height: rect.height\n };\n}","import { modifierPhases } from \"../enums.js\"; // source: https://stackoverflow.com/questions/49875255\n\nfunction order(modifiers) {\n var map = new Map();\n var visited = new Set();\n var result = [];\n modifiers.forEach(function (modifier) {\n map.set(modifier.name, modifier);\n }); // On visiting object, check for its dependencies and visit them recursively\n\n function sort(modifier) {\n visited.add(modifier.name);\n var requires = [].concat(modifier.requires || [], modifier.requiresIfExists || []);\n requires.forEach(function (dep) {\n if (!visited.has(dep)) {\n var depModifier = map.get(dep);\n\n if (depModifier) {\n sort(depModifier);\n }\n }\n });\n result.push(modifier);\n }\n\n modifiers.forEach(function (modifier) {\n if (!visited.has(modifier.name)) {\n // check for visited object\n sort(modifier);\n }\n });\n return result;\n}\n\nexport default function orderModifiers(modifiers) {\n // order based on dependencies\n var orderedModifiers = order(modifiers); // order based on phase\n\n return modifierPhases.reduce(function (acc, phase) {\n return acc.concat(orderedModifiers.filter(function (modifier) {\n return modifier.phase === phase;\n }));\n }, []);\n}","export default function debounce(fn) {\n var pending;\n return function () {\n if (!pending) {\n pending = new Promise(function (resolve) {\n Promise.resolve().then(function () {\n pending = undefined;\n resolve(fn());\n });\n });\n }\n\n return pending;\n };\n}","export default function mergeByName(modifiers) {\n var merged = modifiers.reduce(function (merged, current) {\n var existing = merged[current.name];\n merged[current.name] = existing ? Object.assign({}, existing, current, {\n options: Object.assign({}, existing.options, current.options),\n data: Object.assign({}, existing.data, current.data)\n }) : current;\n return merged;\n }, {}); // IE11 does not support Object.values\n\n return Object.keys(merged).map(function (key) {\n return merged[key];\n });\n}","import getCompositeRect from \"./dom-utils/getCompositeRect.js\";\nimport getLayoutRect from \"./dom-utils/getLayoutRect.js\";\nimport listScrollParents from \"./dom-utils/listScrollParents.js\";\nimport getOffsetParent from \"./dom-utils/getOffsetParent.js\";\nimport orderModifiers from \"./utils/orderModifiers.js\";\nimport debounce from \"./utils/debounce.js\";\nimport mergeByName from \"./utils/mergeByName.js\";\nimport detectOverflow from \"./utils/detectOverflow.js\";\nimport { isElement } from \"./dom-utils/instanceOf.js\";\nvar DEFAULT_OPTIONS = {\n placement: 'bottom',\n modifiers: [],\n strategy: 'absolute'\n};\n\nfunction areValidElements() {\n for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {\n args[_key] = arguments[_key];\n }\n\n return !args.some(function (element) {\n return !(element && typeof element.getBoundingClientRect === 'function');\n });\n}\n\nexport function popperGenerator(generatorOptions) {\n if (generatorOptions === void 0) {\n generatorOptions = {};\n }\n\n var _generatorOptions = generatorOptions,\n _generatorOptions$def = _generatorOptions.defaultModifiers,\n defaultModifiers = _generatorOptions$def === void 0 ? [] : _generatorOptions$def,\n _generatorOptions$def2 = _generatorOptions.defaultOptions,\n defaultOptions = _generatorOptions$def2 === void 0 ? DEFAULT_OPTIONS : _generatorOptions$def2;\n return function createPopper(reference, popper, options) {\n if (options === void 0) {\n options = defaultOptions;\n }\n\n var state = {\n placement: 'bottom',\n orderedModifiers: [],\n options: Object.assign({}, DEFAULT_OPTIONS, defaultOptions),\n modifiersData: {},\n elements: {\n reference: reference,\n popper: popper\n },\n attributes: {},\n styles: {}\n };\n var effectCleanupFns = [];\n var isDestroyed = false;\n var instance = {\n state: state,\n setOptions: function setOptions(setOptionsAction) {\n var options = typeof setOptionsAction === 'function' ? setOptionsAction(state.options) : setOptionsAction;\n cleanupModifierEffects();\n state.options = Object.assign({}, defaultOptions, state.options, options);\n state.scrollParents = {\n reference: isElement(reference) ? listScrollParents(reference) : reference.contextElement ? listScrollParents(reference.contextElement) : [],\n popper: listScrollParents(popper)\n }; // Orders the modifiers based on their dependencies and `phase`\n // properties\n\n var orderedModifiers = orderModifiers(mergeByName([].concat(defaultModifiers, state.options.modifiers))); // Strip out disabled modifiers\n\n state.orderedModifiers = orderedModifiers.filter(function (m) {\n return m.enabled;\n });\n runModifierEffects();\n return instance.update();\n },\n // Sync update – it will always be executed, even if not necessary. This\n // is useful for low frequency updates where sync behavior simplifies the\n // logic.\n // For high frequency updates (e.g. `resize` and `scroll` events), always\n // prefer the async Popper#update method\n forceUpdate: function forceUpdate() {\n if (isDestroyed) {\n return;\n }\n\n var _state$elements = state.elements,\n reference = _state$elements.reference,\n popper = _state$elements.popper; // Don't proceed if `reference` or `popper` are not valid elements\n // anymore\n\n if (!areValidElements(reference, popper)) {\n return;\n } // Store the reference and popper rects to be read by modifiers\n\n\n state.rects = {\n reference: getCompositeRect(reference, getOffsetParent(popper), state.options.strategy === 'fixed'),\n popper: getLayoutRect(popper)\n }; // Modifiers have the ability to reset the current update cycle. The\n // most common use case for this is the `flip` modifier changing the\n // placement, which then needs to re-run all the modifiers, because the\n // logic was previously ran for the previous placement and is therefore\n // stale/incorrect\n\n state.reset = false;\n state.placement = state.options.placement; // On each update cycle, the `modifiersData` property for each modifier\n // is filled with the initial data specified by the modifier. This means\n // it doesn't persist and is fresh on each update.\n // To ensure persistent data, use `${name}#persistent`\n\n state.orderedModifiers.forEach(function (modifier) {\n return state.modifiersData[modifier.name] = Object.assign({}, modifier.data);\n });\n\n for (var index = 0; index < state.orderedModifiers.length; index++) {\n if (state.reset === true) {\n state.reset = false;\n index = -1;\n continue;\n }\n\n var _state$orderedModifie = state.orderedModifiers[index],\n fn = _state$orderedModifie.fn,\n _state$orderedModifie2 = _state$orderedModifie.options,\n _options = _state$orderedModifie2 === void 0 ? {} : _state$orderedModifie2,\n name = _state$orderedModifie.name;\n\n if (typeof fn === 'function') {\n state = fn({\n state: state,\n options: _options,\n name: name,\n instance: instance\n }) || state;\n }\n }\n },\n // Async and optimistically optimized update – it will not be executed if\n // not necessary (debounced to run at most once-per-tick)\n update: debounce(function () {\n return new Promise(function (resolve) {\n instance.forceUpdate();\n resolve(state);\n });\n }),\n destroy: function destroy() {\n cleanupModifierEffects();\n isDestroyed = true;\n }\n };\n\n if (!areValidElements(reference, popper)) {\n return instance;\n }\n\n instance.setOptions(options).then(function (state) {\n if (!isDestroyed && options.onFirstUpdate) {\n options.onFirstUpdate(state);\n }\n }); // Modifiers have the ability to execute arbitrary code before the first\n // update cycle runs. They will be executed in the same order as the update\n // cycle. This is useful when a modifier adds some persistent data that\n // other modifiers need to use, but the modifier is run after the dependent\n // one.\n\n function runModifierEffects() {\n state.orderedModifiers.forEach(function (_ref) {\n var name = _ref.name,\n _ref$options = _ref.options,\n options = _ref$options === void 0 ? {} : _ref$options,\n effect = _ref.effect;\n\n if (typeof effect === 'function') {\n var cleanupFn = effect({\n state: state,\n name: name,\n instance: instance,\n options: options\n });\n\n var noopFn = function noopFn() {};\n\n effectCleanupFns.push(cleanupFn || noopFn);\n }\n });\n }\n\n function cleanupModifierEffects() {\n effectCleanupFns.forEach(function (fn) {\n return fn();\n });\n effectCleanupFns = [];\n }\n\n return instance;\n };\n}\nexport var createPopper = /*#__PURE__*/popperGenerator(); // eslint-disable-next-line import/no-unused-modules\n\nexport { detectOverflow };","import { popperGenerator, detectOverflow } from \"./createPopper.js\";\nimport eventListeners from \"./modifiers/eventListeners.js\";\nimport popperOffsets from \"./modifiers/popperOffsets.js\";\nimport computeStyles from \"./modifiers/computeStyles.js\";\nimport applyStyles from \"./modifiers/applyStyles.js\";\nimport offset from \"./modifiers/offset.js\";\nimport flip from \"./modifiers/flip.js\";\nimport preventOverflow from \"./modifiers/preventOverflow.js\";\nimport arrow from \"./modifiers/arrow.js\";\nimport hide from \"./modifiers/hide.js\";\nvar defaultModifiers = [eventListeners, popperOffsets, computeStyles, applyStyles, offset, flip, preventOverflow, arrow, hide];\nvar createPopper = /*#__PURE__*/popperGenerator({\n defaultModifiers: defaultModifiers\n}); // eslint-disable-next-line import/no-unused-modules\n\nexport { createPopper, popperGenerator, defaultModifiers, detectOverflow }; // eslint-disable-next-line import/no-unused-modules\n\nexport { createPopper as createPopperLite } from \"./popper-lite.js\"; // eslint-disable-next-line import/no-unused-modules\n\nexport * from \"./modifiers/index.js\";","import { generateUtilityClass } from '../generateUtilityClass';\nimport { generateUtilityClasses } from '../generateUtilityClasses';\nconst COMPONENT_NAME = 'Popper';\nexport function getPopperUtilityClass(slot) {\n return generateUtilityClass(COMPONENT_NAME, slot);\n}\nexport const popperClasses = generateUtilityClasses(COMPONENT_NAME, ['root']);","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"anchorEl\", \"children\", \"direction\", \"disablePortal\", \"modifiers\", \"open\", \"placement\", \"popperOptions\", \"popperRef\", \"slotProps\", \"slots\", \"TransitionProps\", \"ownerState\"],\n _excluded2 = [\"anchorEl\", \"children\", \"container\", \"direction\", \"disablePortal\", \"keepMounted\", \"modifiers\", \"open\", \"placement\", \"popperOptions\", \"popperRef\", \"style\", \"transition\", \"slotProps\", \"slots\"];\nimport * as React from 'react';\nimport { chainPropTypes, HTMLElementType, refType, unstable_ownerDocument as ownerDocument, unstable_useEnhancedEffect as useEnhancedEffect, unstable_useForkRef as useForkRef } from '@mui/utils';\nimport { createPopper } from '@popperjs/core';\nimport PropTypes from 'prop-types';\nimport { unstable_composeClasses as composeClasses } from '../composeClasses';\nimport { Portal } from '../Portal';\nimport { getPopperUtilityClass } from './popperClasses';\nimport { useSlotProps } from '../utils';\nimport { useClassNamesOverride } from '../utils/ClassNameConfigurator';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nfunction flipPlacement(placement, direction) {\n if (direction === 'ltr') {\n return placement;\n }\n switch (placement) {\n case 'bottom-end':\n return 'bottom-start';\n case 'bottom-start':\n return 'bottom-end';\n case 'top-end':\n return 'top-start';\n case 'top-start':\n return 'top-end';\n default:\n return placement;\n }\n}\nfunction resolveAnchorEl(anchorEl) {\n return typeof anchorEl === 'function' ? anchorEl() : anchorEl;\n}\nfunction isHTMLElement(element) {\n return element.nodeType !== undefined;\n}\nfunction isVirtualElement(element) {\n return !isHTMLElement(element);\n}\nconst useUtilityClasses = () => {\n const slots = {\n root: ['root']\n };\n return composeClasses(slots, useClassNamesOverride(getPopperUtilityClass));\n};\nconst defaultPopperOptions = {};\nconst PopperTooltip = /*#__PURE__*/React.forwardRef(function PopperTooltip(props, forwardedRef) {\n var _slots$root;\n const {\n anchorEl,\n children,\n direction,\n disablePortal,\n modifiers,\n open,\n placement: initialPlacement,\n popperOptions,\n popperRef: popperRefProp,\n slotProps = {},\n slots = {},\n TransitionProps\n // @ts-ignore internal logic\n // prevent from spreading to DOM, it can come from the parent component e.g. Select.\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const tooltipRef = React.useRef(null);\n const ownRef = useForkRef(tooltipRef, forwardedRef);\n const popperRef = React.useRef(null);\n const handlePopperRef = useForkRef(popperRef, popperRefProp);\n const handlePopperRefRef = React.useRef(handlePopperRef);\n useEnhancedEffect(() => {\n handlePopperRefRef.current = handlePopperRef;\n }, [handlePopperRef]);\n React.useImperativeHandle(popperRefProp, () => popperRef.current, []);\n const rtlPlacement = flipPlacement(initialPlacement, direction);\n /**\n * placement initialized from prop but can change during lifetime if modifiers.flip.\n * modifiers.flip is essentially a flip for controlled/uncontrolled behavior\n */\n const [placement, setPlacement] = React.useState(rtlPlacement);\n const [resolvedAnchorElement, setResolvedAnchorElement] = React.useState(resolveAnchorEl(anchorEl));\n React.useEffect(() => {\n if (popperRef.current) {\n popperRef.current.forceUpdate();\n }\n });\n React.useEffect(() => {\n if (anchorEl) {\n setResolvedAnchorElement(resolveAnchorEl(anchorEl));\n }\n }, [anchorEl]);\n useEnhancedEffect(() => {\n if (!resolvedAnchorElement || !open) {\n return undefined;\n }\n const handlePopperUpdate = data => {\n setPlacement(data.placement);\n };\n if (process.env.NODE_ENV !== 'production') {\n if (resolvedAnchorElement && isHTMLElement(resolvedAnchorElement) && resolvedAnchorElement.nodeType === 1) {\n const box = resolvedAnchorElement.getBoundingClientRect();\n if (process.env.NODE_ENV !== 'test' && box.top === 0 && box.left === 0 && box.right === 0 && box.bottom === 0) {\n console.warn(['MUI: The `anchorEl` prop provided to the component is invalid.', 'The anchor element should be part of the document layout.', \"Make sure the element is present in the document or that it's not display none.\"].join('\\n'));\n }\n }\n }\n let popperModifiers = [{\n name: 'preventOverflow',\n options: {\n altBoundary: disablePortal\n }\n }, {\n name: 'flip',\n options: {\n altBoundary: disablePortal\n }\n }, {\n name: 'onUpdate',\n enabled: true,\n phase: 'afterWrite',\n fn: ({\n state\n }) => {\n handlePopperUpdate(state);\n }\n }];\n if (modifiers != null) {\n popperModifiers = popperModifiers.concat(modifiers);\n }\n if (popperOptions && popperOptions.modifiers != null) {\n popperModifiers = popperModifiers.concat(popperOptions.modifiers);\n }\n const popper = createPopper(resolvedAnchorElement, tooltipRef.current, _extends({\n placement: rtlPlacement\n }, popperOptions, {\n modifiers: popperModifiers\n }));\n handlePopperRefRef.current(popper);\n return () => {\n popper.destroy();\n handlePopperRefRef.current(null);\n };\n }, [resolvedAnchorElement, disablePortal, modifiers, open, popperOptions, rtlPlacement]);\n const childProps = {\n placement: placement\n };\n if (TransitionProps !== null) {\n childProps.TransitionProps = TransitionProps;\n }\n const classes = useUtilityClasses();\n const Root = (_slots$root = slots.root) != null ? _slots$root : 'div';\n const rootProps = useSlotProps({\n elementType: Root,\n externalSlotProps: slotProps.root,\n externalForwardedProps: other,\n additionalProps: {\n role: 'tooltip',\n ref: ownRef\n },\n ownerState: props,\n className: classes.root\n });\n return /*#__PURE__*/_jsx(Root, _extends({}, rootProps, {\n children: typeof children === 'function' ? children(childProps) : children\n }));\n});\n\n/**\n * Poppers rely on the 3rd party library [Popper.js](https://popper.js.org/docs/v2/) for positioning.\n *\n * Demos:\n *\n * - [Popper](https://mui.com/base-ui/react-popper/)\n *\n * API:\n *\n * - [Popper API](https://mui.com/base-ui/react-popper/components-api/#popper)\n */\nconst Popper = /*#__PURE__*/React.forwardRef(function Popper(props, forwardedRef) {\n const {\n anchorEl,\n children,\n container: containerProp,\n direction = 'ltr',\n disablePortal = false,\n keepMounted = false,\n modifiers,\n open,\n placement = 'bottom',\n popperOptions = defaultPopperOptions,\n popperRef,\n style,\n transition = false,\n slotProps = {},\n slots = {}\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded2);\n const [exited, setExited] = React.useState(true);\n const handleEnter = () => {\n setExited(false);\n };\n const handleExited = () => {\n setExited(true);\n };\n if (!keepMounted && !open && (!transition || exited)) {\n return null;\n }\n\n // If the container prop is provided, use that\n // If the anchorEl prop is provided, use its parent body element as the container\n // If neither are provided let the Modal take care of choosing the container\n let container;\n if (containerProp) {\n container = containerProp;\n } else if (anchorEl) {\n const resolvedAnchorEl = resolveAnchorEl(anchorEl);\n container = resolvedAnchorEl && isHTMLElement(resolvedAnchorEl) ? ownerDocument(resolvedAnchorEl).body : ownerDocument(null).body;\n }\n const display = !open && keepMounted && (!transition || exited) ? 'none' : undefined;\n const transitionProps = transition ? {\n in: open,\n onEnter: handleEnter,\n onExited: handleExited\n } : undefined;\n return /*#__PURE__*/_jsx(Portal, {\n disablePortal: disablePortal,\n container: container,\n children: /*#__PURE__*/_jsx(PopperTooltip, _extends({\n anchorEl: anchorEl,\n direction: direction,\n disablePortal: disablePortal,\n modifiers: modifiers,\n ref: forwardedRef,\n open: transition ? !exited : open,\n placement: placement,\n popperOptions: popperOptions,\n popperRef: popperRef,\n slotProps: slotProps,\n slots: slots\n }, other, {\n style: _extends({\n // Prevents scroll issue, waiting for Popper.js to add this style once initiated.\n position: 'fixed',\n // Fix Popper.js display issue\n top: 0,\n left: 0,\n display\n }, style),\n TransitionProps: transitionProps,\n children: children\n }))\n });\n});\nprocess.env.NODE_ENV !== \"production\" ? Popper.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * An HTML element, [virtualElement](https://popper.js.org/docs/v2/virtual-elements/),\n * or a function that returns either.\n * It's used to set the position of the popper.\n * The return value will passed as the reference object of the Popper instance.\n */\n anchorEl: chainPropTypes(PropTypes.oneOfType([HTMLElementType, PropTypes.object, PropTypes.func]), props => {\n if (props.open) {\n const resolvedAnchorEl = resolveAnchorEl(props.anchorEl);\n if (resolvedAnchorEl && isHTMLElement(resolvedAnchorEl) && resolvedAnchorEl.nodeType === 1) {\n const box = resolvedAnchorEl.getBoundingClientRect();\n if (process.env.NODE_ENV !== 'test' && box.top === 0 && box.left === 0 && box.right === 0 && box.bottom === 0) {\n return new Error(['MUI: The `anchorEl` prop provided to the component is invalid.', 'The anchor element should be part of the document layout.', \"Make sure the element is present in the document or that it's not display none.\"].join('\\n'));\n }\n } else if (!resolvedAnchorEl || typeof resolvedAnchorEl.getBoundingClientRect !== 'function' || isVirtualElement(resolvedAnchorEl) && resolvedAnchorEl.contextElement != null && resolvedAnchorEl.contextElement.nodeType !== 1) {\n return new Error(['MUI: The `anchorEl` prop provided to the component is invalid.', 'It should be an HTML element instance or a virtualElement ', '(https://popper.js.org/docs/v2/virtual-elements/).'].join('\\n'));\n }\n }\n return null;\n }),\n /**\n * Popper render function or node.\n */\n children: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.node, PropTypes.func]),\n /**\n * An HTML element or function that returns one.\n * The `container` will have the portal children appended to it.\n *\n * You can also provide a callback, which is called in a React layout effect.\n * This lets you set the container from a ref, and also makes server-side rendering possible.\n *\n * By default, it uses the body of the top-level document object,\n * so it's simply `document.body` most of the time.\n */\n container: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.func]),\n /**\n * Direction of the text.\n * @default 'ltr'\n */\n direction: PropTypes.oneOf(['ltr', 'rtl']),\n /**\n * The `children` will be under the DOM hierarchy of the parent component.\n * @default false\n */\n disablePortal: PropTypes.bool,\n /**\n * Always keep the children in the DOM.\n * This prop can be useful in SEO situation or\n * when you want to maximize the responsiveness of the Popper.\n * @default false\n */\n keepMounted: PropTypes.bool,\n /**\n * Popper.js is based on a \"plugin-like\" architecture,\n * most of its features are fully encapsulated \"modifiers\".\n *\n * A modifier is a function that is called each time Popper.js needs to\n * compute the position of the popper.\n * For this reason, modifiers should be very performant to avoid bottlenecks.\n * To learn how to create a modifier, [read the modifiers documentation](https://popper.js.org/docs/v2/modifiers/).\n */\n modifiers: PropTypes.arrayOf(PropTypes.shape({\n data: PropTypes.object,\n effect: PropTypes.func,\n enabled: PropTypes.bool,\n fn: PropTypes.func,\n name: PropTypes.any,\n options: PropTypes.object,\n phase: PropTypes.oneOf(['afterMain', 'afterRead', 'afterWrite', 'beforeMain', 'beforeRead', 'beforeWrite', 'main', 'read', 'write']),\n requires: PropTypes.arrayOf(PropTypes.string),\n requiresIfExists: PropTypes.arrayOf(PropTypes.string)\n })),\n /**\n * If `true`, the component is shown.\n */\n open: PropTypes.bool.isRequired,\n /**\n * Popper placement.\n * @default 'bottom'\n */\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n /**\n * Options provided to the [`Popper.js`](https://popper.js.org/docs/v2/constructors/#options) instance.\n * @default {}\n */\n popperOptions: PropTypes.shape({\n modifiers: PropTypes.array,\n onFirstUpdate: PropTypes.func,\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n strategy: PropTypes.oneOf(['absolute', 'fixed'])\n }),\n /**\n * A ref that points to the used popper instance.\n */\n popperRef: refType,\n /**\n * The props used for each slot inside the Popper.\n * @default {}\n */\n slotProps: PropTypes.shape({\n root: PropTypes.oneOfType([PropTypes.func, PropTypes.object])\n }),\n /**\n * The components used for each slot inside the Popper.\n * Either a string to use a HTML element or a component.\n * @default {}\n */\n slots: PropTypes.shape({\n root: PropTypes.elementType\n }),\n /**\n * Help supporting a react-transition-group/Transition component.\n * @default false\n */\n transition: PropTypes.bool\n} : void 0;\nexport { Popper };","'use client';\n\nimport * as React from 'react';\nimport { useTheme as useThemeSystem } from '@mui/system';\nimport defaultTheme from './defaultTheme';\nimport THEME_ID from './identifier';\nexport default function useTheme() {\n const theme = useThemeSystem(defaultTheme);\n if (process.env.NODE_ENV !== 'production') {\n // eslint-disable-next-line react-hooks/rules-of-hooks\n React.useDebugValue(theme);\n }\n return theme[THEME_ID] || theme;\n}","export default function _setPrototypeOf(o, p) {\n _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function _setPrototypeOf(o, p) {\n o.__proto__ = p;\n return o;\n };\n return _setPrototypeOf(o, p);\n}","import setPrototypeOf from \"./setPrototypeOf.js\";\nexport default function _inheritsLoose(subClass, superClass) {\n subClass.prototype = Object.create(superClass.prototype);\n subClass.prototype.constructor = subClass;\n setPrototypeOf(subClass, superClass);\n}","export default {\n disabled: false\n};","import PropTypes from 'prop-types';\nexport var timeoutsShape = process.env.NODE_ENV !== 'production' ? PropTypes.oneOfType([PropTypes.number, PropTypes.shape({\n enter: PropTypes.number,\n exit: PropTypes.number,\n appear: PropTypes.number\n}).isRequired]) : null;\nexport var classNamesShape = process.env.NODE_ENV !== 'production' ? PropTypes.oneOfType([PropTypes.string, PropTypes.shape({\n enter: PropTypes.string,\n exit: PropTypes.string,\n active: PropTypes.string\n}), PropTypes.shape({\n enter: PropTypes.string,\n enterDone: PropTypes.string,\n enterActive: PropTypes.string,\n exit: PropTypes.string,\n exitDone: PropTypes.string,\n exitActive: PropTypes.string\n})]) : null;","import React from 'react';\nexport default React.createContext(null);","export var forceReflow = function forceReflow(node) {\n return node.scrollTop;\n};","import _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _inheritsLoose from \"@babel/runtime/helpers/esm/inheritsLoose\";\nimport PropTypes from 'prop-types';\nimport React from 'react';\nimport ReactDOM from 'react-dom';\nimport config from './config';\nimport { timeoutsShape } from './utils/PropTypes';\nimport TransitionGroupContext from './TransitionGroupContext';\nimport { forceReflow } from './utils/reflow';\nexport var UNMOUNTED = 'unmounted';\nexport var EXITED = 'exited';\nexport var ENTERING = 'entering';\nexport var ENTERED = 'entered';\nexport var EXITING = 'exiting';\n/**\n * The Transition component lets you describe a transition from one component\n * state to another _over time_ with a simple declarative API. Most commonly\n * it's used to animate the mounting and unmounting of a component, but can also\n * be used to describe in-place transition states as well.\n *\n * ---\n *\n * **Note**: `Transition` is a platform-agnostic base component. If you're using\n * transitions in CSS, you'll probably want to use\n * [`CSSTransition`](https://reactcommunity.org/react-transition-group/css-transition)\n * instead. It inherits all the features of `Transition`, but contains\n * additional features necessary to play nice with CSS transitions (hence the\n * name of the component).\n *\n * ---\n *\n * By default the `Transition` component does not alter the behavior of the\n * component it renders, it only tracks \"enter\" and \"exit\" states for the\n * components. It's up to you to give meaning and effect to those states. For\n * example we can add styles to a component when it enters or exits:\n *\n * ```jsx\n * import { Transition } from 'react-transition-group';\n *\n * const duration = 300;\n *\n * const defaultStyle = {\n * transition: `opacity ${duration}ms ease-in-out`,\n * opacity: 0,\n * }\n *\n * const transitionStyles = {\n * entering: { opacity: 1 },\n * entered: { opacity: 1 },\n * exiting: { opacity: 0 },\n * exited: { opacity: 0 },\n * };\n *\n * const Fade = ({ in: inProp }) => (\n * \n * {state => (\n *
    \n * I'm a fade Transition!\n *
    \n * )}\n *
    \n * );\n * ```\n *\n * There are 4 main states a Transition can be in:\n * - `'entering'`\n * - `'entered'`\n * - `'exiting'`\n * - `'exited'`\n *\n * Transition state is toggled via the `in` prop. When `true` the component\n * begins the \"Enter\" stage. During this stage, the component will shift from\n * its current transition state, to `'entering'` for the duration of the\n * transition and then to the `'entered'` stage once it's complete. Let's take\n * the following example (we'll use the\n * [useState](https://reactjs.org/docs/hooks-reference.html#usestate) hook):\n *\n * ```jsx\n * function App() {\n * const [inProp, setInProp] = useState(false);\n * return (\n *
    \n * \n * {state => (\n * // ...\n * )}\n * \n * \n *
    \n * );\n * }\n * ```\n *\n * When the button is clicked the component will shift to the `'entering'` state\n * and stay there for 500ms (the value of `timeout`) before it finally switches\n * to `'entered'`.\n *\n * When `in` is `false` the same thing happens except the state moves from\n * `'exiting'` to `'exited'`.\n */\n\nvar Transition = /*#__PURE__*/function (_React$Component) {\n _inheritsLoose(Transition, _React$Component);\n\n function Transition(props, context) {\n var _this;\n\n _this = _React$Component.call(this, props, context) || this;\n var parentGroup = context; // In the context of a TransitionGroup all enters are really appears\n\n var appear = parentGroup && !parentGroup.isMounting ? props.enter : props.appear;\n var initialStatus;\n _this.appearStatus = null;\n\n if (props.in) {\n if (appear) {\n initialStatus = EXITED;\n _this.appearStatus = ENTERING;\n } else {\n initialStatus = ENTERED;\n }\n } else {\n if (props.unmountOnExit || props.mountOnEnter) {\n initialStatus = UNMOUNTED;\n } else {\n initialStatus = EXITED;\n }\n }\n\n _this.state = {\n status: initialStatus\n };\n _this.nextCallback = null;\n return _this;\n }\n\n Transition.getDerivedStateFromProps = function getDerivedStateFromProps(_ref, prevState) {\n var nextIn = _ref.in;\n\n if (nextIn && prevState.status === UNMOUNTED) {\n return {\n status: EXITED\n };\n }\n\n return null;\n } // getSnapshotBeforeUpdate(prevProps) {\n // let nextStatus = null\n // if (prevProps !== this.props) {\n // const { status } = this.state\n // if (this.props.in) {\n // if (status !== ENTERING && status !== ENTERED) {\n // nextStatus = ENTERING\n // }\n // } else {\n // if (status === ENTERING || status === ENTERED) {\n // nextStatus = EXITING\n // }\n // }\n // }\n // return { nextStatus }\n // }\n ;\n\n var _proto = Transition.prototype;\n\n _proto.componentDidMount = function componentDidMount() {\n this.updateStatus(true, this.appearStatus);\n };\n\n _proto.componentDidUpdate = function componentDidUpdate(prevProps) {\n var nextStatus = null;\n\n if (prevProps !== this.props) {\n var status = this.state.status;\n\n if (this.props.in) {\n if (status !== ENTERING && status !== ENTERED) {\n nextStatus = ENTERING;\n }\n } else {\n if (status === ENTERING || status === ENTERED) {\n nextStatus = EXITING;\n }\n }\n }\n\n this.updateStatus(false, nextStatus);\n };\n\n _proto.componentWillUnmount = function componentWillUnmount() {\n this.cancelNextCallback();\n };\n\n _proto.getTimeouts = function getTimeouts() {\n var timeout = this.props.timeout;\n var exit, enter, appear;\n exit = enter = appear = timeout;\n\n if (timeout != null && typeof timeout !== 'number') {\n exit = timeout.exit;\n enter = timeout.enter; // TODO: remove fallback for next major\n\n appear = timeout.appear !== undefined ? timeout.appear : enter;\n }\n\n return {\n exit: exit,\n enter: enter,\n appear: appear\n };\n };\n\n _proto.updateStatus = function updateStatus(mounting, nextStatus) {\n if (mounting === void 0) {\n mounting = false;\n }\n\n if (nextStatus !== null) {\n // nextStatus will always be ENTERING or EXITING.\n this.cancelNextCallback();\n\n if (nextStatus === ENTERING) {\n if (this.props.unmountOnExit || this.props.mountOnEnter) {\n var node = this.props.nodeRef ? this.props.nodeRef.current : ReactDOM.findDOMNode(this); // https://github.com/reactjs/react-transition-group/pull/749\n // With unmountOnExit or mountOnEnter, the enter animation should happen at the transition between `exited` and `entering`.\n // To make the animation happen, we have to separate each rendering and avoid being processed as batched.\n\n if (node) forceReflow(node);\n }\n\n this.performEnter(mounting);\n } else {\n this.performExit();\n }\n } else if (this.props.unmountOnExit && this.state.status === EXITED) {\n this.setState({\n status: UNMOUNTED\n });\n }\n };\n\n _proto.performEnter = function performEnter(mounting) {\n var _this2 = this;\n\n var enter = this.props.enter;\n var appearing = this.context ? this.context.isMounting : mounting;\n\n var _ref2 = this.props.nodeRef ? [appearing] : [ReactDOM.findDOMNode(this), appearing],\n maybeNode = _ref2[0],\n maybeAppearing = _ref2[1];\n\n var timeouts = this.getTimeouts();\n var enterTimeout = appearing ? timeouts.appear : timeouts.enter; // no enter animation skip right to ENTERED\n // if we are mounting and running this it means appear _must_ be set\n\n if (!mounting && !enter || config.disabled) {\n this.safeSetState({\n status: ENTERED\n }, function () {\n _this2.props.onEntered(maybeNode);\n });\n return;\n }\n\n this.props.onEnter(maybeNode, maybeAppearing);\n this.safeSetState({\n status: ENTERING\n }, function () {\n _this2.props.onEntering(maybeNode, maybeAppearing);\n\n _this2.onTransitionEnd(enterTimeout, function () {\n _this2.safeSetState({\n status: ENTERED\n }, function () {\n _this2.props.onEntered(maybeNode, maybeAppearing);\n });\n });\n });\n };\n\n _proto.performExit = function performExit() {\n var _this3 = this;\n\n var exit = this.props.exit;\n var timeouts = this.getTimeouts();\n var maybeNode = this.props.nodeRef ? undefined : ReactDOM.findDOMNode(this); // no exit animation skip right to EXITED\n\n if (!exit || config.disabled) {\n this.safeSetState({\n status: EXITED\n }, function () {\n _this3.props.onExited(maybeNode);\n });\n return;\n }\n\n this.props.onExit(maybeNode);\n this.safeSetState({\n status: EXITING\n }, function () {\n _this3.props.onExiting(maybeNode);\n\n _this3.onTransitionEnd(timeouts.exit, function () {\n _this3.safeSetState({\n status: EXITED\n }, function () {\n _this3.props.onExited(maybeNode);\n });\n });\n });\n };\n\n _proto.cancelNextCallback = function cancelNextCallback() {\n if (this.nextCallback !== null) {\n this.nextCallback.cancel();\n this.nextCallback = null;\n }\n };\n\n _proto.safeSetState = function safeSetState(nextState, callback) {\n // This shouldn't be necessary, but there are weird race conditions with\n // setState callbacks and unmounting in testing, so always make sure that\n // we can cancel any pending setState callbacks after we unmount.\n callback = this.setNextCallback(callback);\n this.setState(nextState, callback);\n };\n\n _proto.setNextCallback = function setNextCallback(callback) {\n var _this4 = this;\n\n var active = true;\n\n this.nextCallback = function (event) {\n if (active) {\n active = false;\n _this4.nextCallback = null;\n callback(event);\n }\n };\n\n this.nextCallback.cancel = function () {\n active = false;\n };\n\n return this.nextCallback;\n };\n\n _proto.onTransitionEnd = function onTransitionEnd(timeout, handler) {\n this.setNextCallback(handler);\n var node = this.props.nodeRef ? this.props.nodeRef.current : ReactDOM.findDOMNode(this);\n var doesNotHaveTimeoutOrListener = timeout == null && !this.props.addEndListener;\n\n if (!node || doesNotHaveTimeoutOrListener) {\n setTimeout(this.nextCallback, 0);\n return;\n }\n\n if (this.props.addEndListener) {\n var _ref3 = this.props.nodeRef ? [this.nextCallback] : [node, this.nextCallback],\n maybeNode = _ref3[0],\n maybeNextCallback = _ref3[1];\n\n this.props.addEndListener(maybeNode, maybeNextCallback);\n }\n\n if (timeout != null) {\n setTimeout(this.nextCallback, timeout);\n }\n };\n\n _proto.render = function render() {\n var status = this.state.status;\n\n if (status === UNMOUNTED) {\n return null;\n }\n\n var _this$props = this.props,\n children = _this$props.children,\n _in = _this$props.in,\n _mountOnEnter = _this$props.mountOnEnter,\n _unmountOnExit = _this$props.unmountOnExit,\n _appear = _this$props.appear,\n _enter = _this$props.enter,\n _exit = _this$props.exit,\n _timeout = _this$props.timeout,\n _addEndListener = _this$props.addEndListener,\n _onEnter = _this$props.onEnter,\n _onEntering = _this$props.onEntering,\n _onEntered = _this$props.onEntered,\n _onExit = _this$props.onExit,\n _onExiting = _this$props.onExiting,\n _onExited = _this$props.onExited,\n _nodeRef = _this$props.nodeRef,\n childProps = _objectWithoutPropertiesLoose(_this$props, [\"children\", \"in\", \"mountOnEnter\", \"unmountOnExit\", \"appear\", \"enter\", \"exit\", \"timeout\", \"addEndListener\", \"onEnter\", \"onEntering\", \"onEntered\", \"onExit\", \"onExiting\", \"onExited\", \"nodeRef\"]);\n\n return (\n /*#__PURE__*/\n // allows for nested Transitions\n React.createElement(TransitionGroupContext.Provider, {\n value: null\n }, typeof children === 'function' ? children(status, childProps) : React.cloneElement(React.Children.only(children), childProps))\n );\n };\n\n return Transition;\n}(React.Component);\n\nTransition.contextType = TransitionGroupContext;\nTransition.propTypes = process.env.NODE_ENV !== \"production\" ? {\n /**\n * A React reference to DOM element that need to transition:\n * https://stackoverflow.com/a/51127130/4671932\n *\n * - When `nodeRef` prop is used, `node` is not passed to callback functions\n * (e.g. `onEnter`) because user already has direct access to the node.\n * - When changing `key` prop of `Transition` in a `TransitionGroup` a new\n * `nodeRef` need to be provided to `Transition` with changed `key` prop\n * (see\n * [test/CSSTransition-test.js](https://github.com/reactjs/react-transition-group/blob/13435f897b3ab71f6e19d724f145596f5910581c/test/CSSTransition-test.js#L362-L437)).\n */\n nodeRef: PropTypes.shape({\n current: typeof Element === 'undefined' ? PropTypes.any : function (propValue, key, componentName, location, propFullName, secret) {\n var value = propValue[key];\n return PropTypes.instanceOf(value && 'ownerDocument' in value ? value.ownerDocument.defaultView.Element : Element)(propValue, key, componentName, location, propFullName, secret);\n }\n }),\n\n /**\n * A `function` child can be used instead of a React element. This function is\n * called with the current transition status (`'entering'`, `'entered'`,\n * `'exiting'`, `'exited'`), which can be used to apply context\n * specific props to a component.\n *\n * ```jsx\n * \n * {state => (\n * \n * )}\n * \n * ```\n */\n children: PropTypes.oneOfType([PropTypes.func.isRequired, PropTypes.element.isRequired]).isRequired,\n\n /**\n * Show the component; triggers the enter or exit states\n */\n in: PropTypes.bool,\n\n /**\n * By default the child component is mounted immediately along with\n * the parent `Transition` component. If you want to \"lazy mount\" the component on the\n * first `in={true}` you can set `mountOnEnter`. After the first enter transition the component will stay\n * mounted, even on \"exited\", unless you also specify `unmountOnExit`.\n */\n mountOnEnter: PropTypes.bool,\n\n /**\n * By default the child component stays mounted after it reaches the `'exited'` state.\n * Set `unmountOnExit` if you'd prefer to unmount the component after it finishes exiting.\n */\n unmountOnExit: PropTypes.bool,\n\n /**\n * By default the child component does not perform the enter transition when\n * it first mounts, regardless of the value of `in`. If you want this\n * behavior, set both `appear` and `in` to `true`.\n *\n * > **Note**: there are no special appear states like `appearing`/`appeared`, this prop\n * > only adds an additional enter transition. However, in the\n * > `` component that first enter transition does result in\n * > additional `.appear-*` classes, that way you can choose to style it\n * > differently.\n */\n appear: PropTypes.bool,\n\n /**\n * Enable or disable enter transitions.\n */\n enter: PropTypes.bool,\n\n /**\n * Enable or disable exit transitions.\n */\n exit: PropTypes.bool,\n\n /**\n * The duration of the transition, in milliseconds.\n * Required unless `addEndListener` is provided.\n *\n * You may specify a single timeout for all transitions:\n *\n * ```jsx\n * timeout={500}\n * ```\n *\n * or individually:\n *\n * ```jsx\n * timeout={{\n * appear: 500,\n * enter: 300,\n * exit: 500,\n * }}\n * ```\n *\n * - `appear` defaults to the value of `enter`\n * - `enter` defaults to `0`\n * - `exit` defaults to `0`\n *\n * @type {number | { enter?: number, exit?: number, appear?: number }}\n */\n timeout: function timeout(props) {\n var pt = timeoutsShape;\n if (!props.addEndListener) pt = pt.isRequired;\n\n for (var _len = arguments.length, args = new Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) {\n args[_key - 1] = arguments[_key];\n }\n\n return pt.apply(void 0, [props].concat(args));\n },\n\n /**\n * Add a custom transition end trigger. Called with the transitioning\n * DOM node and a `done` callback. Allows for more fine grained transition end\n * logic. Timeouts are still used as a fallback if provided.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * ```jsx\n * addEndListener={(node, done) => {\n * // use the css transitionend event to mark the finish of a transition\n * node.addEventListener('transitionend', done, false);\n * }}\n * ```\n */\n addEndListener: PropTypes.func,\n\n /**\n * Callback fired before the \"entering\" status is applied. An extra parameter\n * `isAppearing` is supplied to indicate if the enter stage is occurring on the initial mount\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement, isAppearing: bool) -> void\n */\n onEnter: PropTypes.func,\n\n /**\n * Callback fired after the \"entering\" status is applied. An extra parameter\n * `isAppearing` is supplied to indicate if the enter stage is occurring on the initial mount\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement, isAppearing: bool)\n */\n onEntering: PropTypes.func,\n\n /**\n * Callback fired after the \"entered\" status is applied. An extra parameter\n * `isAppearing` is supplied to indicate if the enter stage is occurring on the initial mount\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement, isAppearing: bool) -> void\n */\n onEntered: PropTypes.func,\n\n /**\n * Callback fired before the \"exiting\" status is applied.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement) -> void\n */\n onExit: PropTypes.func,\n\n /**\n * Callback fired after the \"exiting\" status is applied.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement) -> void\n */\n onExiting: PropTypes.func,\n\n /**\n * Callback fired after the \"exited\" status is applied.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed\n *\n * @type Function(node: HtmlElement) -> void\n */\n onExited: PropTypes.func\n} : {}; // Name the function so it is clearer in the documentation\n\nfunction noop() {}\n\nTransition.defaultProps = {\n in: false,\n mountOnEnter: false,\n unmountOnExit: false,\n appear: false,\n enter: true,\n exit: true,\n onEnter: noop,\n onEntering: noop,\n onEntered: noop,\n onExit: noop,\n onExiting: noop,\n onExited: noop\n};\nTransition.UNMOUNTED = UNMOUNTED;\nTransition.EXITED = EXITED;\nTransition.ENTERING = ENTERING;\nTransition.ENTERED = ENTERED;\nTransition.EXITING = EXITING;\nexport default Transition;","export const reflow = node => node.scrollTop;\nexport function getTransitionProps(props, options) {\n var _style$transitionDura, _style$transitionTimi;\n const {\n timeout,\n easing,\n style = {}\n } = props;\n return {\n duration: (_style$transitionDura = style.transitionDuration) != null ? _style$transitionDura : typeof timeout === 'number' ? timeout : timeout[options.mode] || 0,\n easing: (_style$transitionTimi = style.transitionTimingFunction) != null ? _style$transitionTimi : typeof easing === 'object' ? easing[options.mode] : easing,\n delay: style.transitionDelay\n };\n}","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"addEndListener\", \"appear\", \"children\", \"easing\", \"in\", \"onEnter\", \"onEntered\", \"onEntering\", \"onExit\", \"onExited\", \"onExiting\", \"style\", \"timeout\", \"TransitionComponent\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport { elementAcceptingRef, unstable_useTimeout as useTimeout } from '@mui/utils';\nimport { Transition } from 'react-transition-group';\nimport useTheme from '../styles/useTheme';\nimport { getTransitionProps, reflow } from '../transitions/utils';\nimport useForkRef from '../utils/useForkRef';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nfunction getScale(value) {\n return `scale(${value}, ${value ** 2})`;\n}\nconst styles = {\n entering: {\n opacity: 1,\n transform: getScale(1)\n },\n entered: {\n opacity: 1,\n transform: 'none'\n }\n};\n\n/*\n TODO v6: remove\n Conditionally apply a workaround for the CSS transition bug in Safari 15.4 / WebKit browsers.\n */\nconst isWebKit154 = typeof navigator !== 'undefined' && /^((?!chrome|android).)*(safari|mobile)/i.test(navigator.userAgent) && /(os |version\\/)15(.|_)4/i.test(navigator.userAgent);\n\n/**\n * The Grow transition is used by the [Tooltip](/material-ui/react-tooltip/) and\n * [Popover](/material-ui/react-popover/) components.\n * It uses [react-transition-group](https://github.com/reactjs/react-transition-group) internally.\n */\nconst Grow = /*#__PURE__*/React.forwardRef(function Grow(props, ref) {\n const {\n addEndListener,\n appear = true,\n children,\n easing,\n in: inProp,\n onEnter,\n onEntered,\n onEntering,\n onExit,\n onExited,\n onExiting,\n style,\n timeout = 'auto',\n // eslint-disable-next-line react/prop-types\n TransitionComponent = Transition\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const timer = useTimeout();\n const autoTimeout = React.useRef();\n const theme = useTheme();\n const nodeRef = React.useRef(null);\n const handleRef = useForkRef(nodeRef, children.ref, ref);\n const normalizedTransitionCallback = callback => maybeIsAppearing => {\n if (callback) {\n const node = nodeRef.current;\n\n // onEnterXxx and onExitXxx callbacks have a different arguments.length value.\n if (maybeIsAppearing === undefined) {\n callback(node);\n } else {\n callback(node, maybeIsAppearing);\n }\n }\n };\n const handleEntering = normalizedTransitionCallback(onEntering);\n const handleEnter = normalizedTransitionCallback((node, isAppearing) => {\n reflow(node); // So the animation always start from the start.\n\n const {\n duration: transitionDuration,\n delay,\n easing: transitionTimingFunction\n } = getTransitionProps({\n style,\n timeout,\n easing\n }, {\n mode: 'enter'\n });\n let duration;\n if (timeout === 'auto') {\n duration = theme.transitions.getAutoHeightDuration(node.clientHeight);\n autoTimeout.current = duration;\n } else {\n duration = transitionDuration;\n }\n node.style.transition = [theme.transitions.create('opacity', {\n duration,\n delay\n }), theme.transitions.create('transform', {\n duration: isWebKit154 ? duration : duration * 0.666,\n delay,\n easing: transitionTimingFunction\n })].join(',');\n if (onEnter) {\n onEnter(node, isAppearing);\n }\n });\n const handleEntered = normalizedTransitionCallback(onEntered);\n const handleExiting = normalizedTransitionCallback(onExiting);\n const handleExit = normalizedTransitionCallback(node => {\n const {\n duration: transitionDuration,\n delay,\n easing: transitionTimingFunction\n } = getTransitionProps({\n style,\n timeout,\n easing\n }, {\n mode: 'exit'\n });\n let duration;\n if (timeout === 'auto') {\n duration = theme.transitions.getAutoHeightDuration(node.clientHeight);\n autoTimeout.current = duration;\n } else {\n duration = transitionDuration;\n }\n node.style.transition = [theme.transitions.create('opacity', {\n duration,\n delay\n }), theme.transitions.create('transform', {\n duration: isWebKit154 ? duration : duration * 0.666,\n delay: isWebKit154 ? delay : delay || duration * 0.333,\n easing: transitionTimingFunction\n })].join(',');\n node.style.opacity = 0;\n node.style.transform = getScale(0.75);\n if (onExit) {\n onExit(node);\n }\n });\n const handleExited = normalizedTransitionCallback(onExited);\n const handleAddEndListener = next => {\n if (timeout === 'auto') {\n timer.start(autoTimeout.current || 0, next);\n }\n if (addEndListener) {\n // Old call signature before `react-transition-group` implemented `nodeRef`\n addEndListener(nodeRef.current, next);\n }\n };\n return /*#__PURE__*/_jsx(TransitionComponent, _extends({\n appear: appear,\n in: inProp,\n nodeRef: nodeRef,\n onEnter: handleEnter,\n onEntered: handleEntered,\n onEntering: handleEntering,\n onExit: handleExit,\n onExited: handleExited,\n onExiting: handleExiting,\n addEndListener: handleAddEndListener,\n timeout: timeout === 'auto' ? null : timeout\n }, other, {\n children: (state, childProps) => {\n return /*#__PURE__*/React.cloneElement(children, _extends({\n style: _extends({\n opacity: 0,\n transform: getScale(0.75),\n visibility: state === 'exited' && !inProp ? 'hidden' : undefined\n }, styles[state], style, children.props.style),\n ref: handleRef\n }, childProps));\n }\n }));\n});\nprocess.env.NODE_ENV !== \"production\" ? Grow.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the d.ts file and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * Add a custom transition end trigger. Called with the transitioning DOM\n * node and a done callback. Allows for more fine grained transition end\n * logic. Note: Timeouts are still used as a fallback if provided.\n */\n addEndListener: PropTypes.func,\n /**\n * Perform the enter transition when it first mounts if `in` is also `true`.\n * Set this to `false` to disable this behavior.\n * @default true\n */\n appear: PropTypes.bool,\n /**\n * A single child content element.\n */\n children: elementAcceptingRef.isRequired,\n /**\n * The transition timing function.\n * You may specify a single easing or a object containing enter and exit values.\n */\n easing: PropTypes.oneOfType([PropTypes.shape({\n enter: PropTypes.string,\n exit: PropTypes.string\n }), PropTypes.string]),\n /**\n * If `true`, the component will transition in.\n */\n in: PropTypes.bool,\n /**\n * @ignore\n */\n onEnter: PropTypes.func,\n /**\n * @ignore\n */\n onEntered: PropTypes.func,\n /**\n * @ignore\n */\n onEntering: PropTypes.func,\n /**\n * @ignore\n */\n onExit: PropTypes.func,\n /**\n * @ignore\n */\n onExited: PropTypes.func,\n /**\n * @ignore\n */\n onExiting: PropTypes.func,\n /**\n * @ignore\n */\n style: PropTypes.object,\n /**\n * The duration for the transition, in milliseconds.\n * You may specify a single timeout for all transitions, or individually with an object.\n *\n * Set to 'auto' to automatically calculate transition time based on height.\n * @default 'auto'\n */\n timeout: PropTypes.oneOfType([PropTypes.oneOf(['auto']), PropTypes.number, PropTypes.shape({\n appear: PropTypes.number,\n enter: PropTypes.number,\n exit: PropTypes.number\n })])\n} : void 0;\nGrow.muiSupportAuto = true;\nexport default Grow;","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"anchorEl\", \"component\", \"components\", \"componentsProps\", \"container\", \"disablePortal\", \"keepMounted\", \"modifiers\", \"open\", \"placement\", \"popperOptions\", \"popperRef\", \"transition\", \"slots\", \"slotProps\"];\nimport { Popper as BasePopper } from '@mui/base/Popper';\nimport { useThemeWithoutDefault as useTheme } from '@mui/system';\nimport { HTMLElementType, refType } from '@mui/utils';\nimport PropTypes from 'prop-types';\nimport * as React from 'react';\nimport { styled, useThemeProps } from '../styles';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nconst PopperRoot = styled(BasePopper, {\n name: 'MuiPopper',\n slot: 'Root',\n overridesResolver: (props, styles) => styles.root\n})({});\n\n/**\n *\n * Demos:\n *\n * - [Autocomplete](https://mui.com/material-ui/react-autocomplete/)\n * - [Menu](https://mui.com/material-ui/react-menu/)\n * - [Popper](https://mui.com/material-ui/react-popper/)\n *\n * API:\n *\n * - [Popper API](https://mui.com/material-ui/api/popper/)\n */\nconst Popper = /*#__PURE__*/React.forwardRef(function Popper(inProps, ref) {\n var _slots$root;\n const theme = useTheme();\n const props = useThemeProps({\n props: inProps,\n name: 'MuiPopper'\n });\n const {\n anchorEl,\n component,\n components,\n componentsProps,\n container,\n disablePortal,\n keepMounted,\n modifiers,\n open,\n placement,\n popperOptions,\n popperRef,\n transition,\n slots,\n slotProps\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const RootComponent = (_slots$root = slots == null ? void 0 : slots.root) != null ? _slots$root : components == null ? void 0 : components.Root;\n const otherProps = _extends({\n anchorEl,\n container,\n disablePortal,\n keepMounted,\n modifiers,\n open,\n placement,\n popperOptions,\n popperRef,\n transition\n }, other);\n return /*#__PURE__*/_jsx(PopperRoot, _extends({\n as: component,\n direction: theme == null ? void 0 : theme.direction,\n slots: {\n root: RootComponent\n },\n slotProps: slotProps != null ? slotProps : componentsProps\n }, otherProps, {\n ref: ref\n }));\n});\nprocess.env.NODE_ENV !== \"production\" ? Popper.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * An HTML element, [virtualElement](https://popper.js.org/docs/v2/virtual-elements/),\n * or a function that returns either.\n * It's used to set the position of the popper.\n * The return value will passed as the reference object of the Popper instance.\n */\n anchorEl: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.object, PropTypes.func]),\n /**\n * Popper render function or node.\n */\n children: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.node, PropTypes.func]),\n /**\n * The component used for the root node.\n * Either a string to use a HTML element or a component.\n */\n component: PropTypes.elementType,\n /**\n * The components used for each slot inside the Popper.\n * Either a string to use a HTML element or a component.\n * @default {}\n */\n components: PropTypes.shape({\n Root: PropTypes.elementType\n }),\n /**\n * The props used for each slot inside the Popper.\n * @default {}\n */\n componentsProps: PropTypes.shape({\n root: PropTypes.oneOfType([PropTypes.func, PropTypes.object])\n }),\n /**\n * An HTML element or function that returns one.\n * The `container` will have the portal children appended to it.\n *\n * You can also provide a callback, which is called in a React layout effect.\n * This lets you set the container from a ref, and also makes server-side rendering possible.\n *\n * By default, it uses the body of the top-level document object,\n * so it's simply `document.body` most of the time.\n */\n container: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.func]),\n /**\n * The `children` will be under the DOM hierarchy of the parent component.\n * @default false\n */\n disablePortal: PropTypes.bool,\n /**\n * Always keep the children in the DOM.\n * This prop can be useful in SEO situation or\n * when you want to maximize the responsiveness of the Popper.\n * @default false\n */\n keepMounted: PropTypes.bool,\n /**\n * Popper.js is based on a \"plugin-like\" architecture,\n * most of its features are fully encapsulated \"modifiers\".\n *\n * A modifier is a function that is called each time Popper.js needs to\n * compute the position of the popper.\n * For this reason, modifiers should be very performant to avoid bottlenecks.\n * To learn how to create a modifier, [read the modifiers documentation](https://popper.js.org/docs/v2/modifiers/).\n */\n modifiers: PropTypes.arrayOf(PropTypes.shape({\n data: PropTypes.object,\n effect: PropTypes.func,\n enabled: PropTypes.bool,\n fn: PropTypes.func,\n name: PropTypes.any,\n options: PropTypes.object,\n phase: PropTypes.oneOf(['afterMain', 'afterRead', 'afterWrite', 'beforeMain', 'beforeRead', 'beforeWrite', 'main', 'read', 'write']),\n requires: PropTypes.arrayOf(PropTypes.string),\n requiresIfExists: PropTypes.arrayOf(PropTypes.string)\n })),\n /**\n * If `true`, the component is shown.\n */\n open: PropTypes.bool.isRequired,\n /**\n * Popper placement.\n * @default 'bottom'\n */\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n /**\n * Options provided to the [`Popper.js`](https://popper.js.org/docs/v2/constructors/#options) instance.\n * @default {}\n */\n popperOptions: PropTypes.shape({\n modifiers: PropTypes.array,\n onFirstUpdate: PropTypes.func,\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n strategy: PropTypes.oneOf(['absolute', 'fixed'])\n }),\n /**\n * A ref that points to the used popper instance.\n */\n popperRef: refType,\n /**\n * The props used for each slot inside the Popper.\n * @default {}\n */\n slotProps: PropTypes.shape({\n root: PropTypes.oneOfType([PropTypes.func, PropTypes.object])\n }),\n /**\n * The components used for each slot inside the Popper.\n * Either a string to use a HTML element or a component.\n * @default {}\n */\n slots: PropTypes.shape({\n root: PropTypes.elementType\n }),\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Help supporting a react-transition-group/Transition component.\n * @default false\n */\n transition: PropTypes.bool\n} : void 0;\nexport default Popper;","import generateUtilityClasses from '@mui/utils/generateUtilityClasses';\nimport generateUtilityClass from '@mui/utils/generateUtilityClass';\nexport function getTooltipUtilityClass(slot) {\n return generateUtilityClass('MuiTooltip', slot);\n}\nconst tooltipClasses = generateUtilityClasses('MuiTooltip', ['popper', 'popperInteractive', 'popperArrow', 'popperClose', 'tooltip', 'tooltipArrow', 'touch', 'tooltipPlacementLeft', 'tooltipPlacementRight', 'tooltipPlacementTop', 'tooltipPlacementBottom', 'arrow']);\nexport default tooltipClasses;","'use client';\n\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nconst _excluded = [\"arrow\", \"children\", \"classes\", \"components\", \"componentsProps\", \"describeChild\", \"disableFocusListener\", \"disableHoverListener\", \"disableInteractive\", \"disableTouchListener\", \"enterDelay\", \"enterNextDelay\", \"enterTouchDelay\", \"followCursor\", \"id\", \"leaveDelay\", \"leaveTouchDelay\", \"onClose\", \"onOpen\", \"open\", \"placement\", \"PopperComponent\", \"PopperProps\", \"slotProps\", \"slots\", \"title\", \"TransitionComponent\", \"TransitionProps\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport clsx from 'clsx';\nimport { elementAcceptingRef, unstable_useTimeout as useTimeout, unstable_Timeout as Timeout } from '@mui/utils';\nimport { unstable_composeClasses as composeClasses, appendOwnerState } from '@mui/base';\nimport { alpha } from '@mui/system';\nimport styled from '../styles/styled';\nimport useTheme from '../styles/useTheme';\nimport useThemeProps from '../styles/useThemeProps';\nimport capitalize from '../utils/capitalize';\nimport Grow from '../Grow';\nimport Popper from '../Popper';\nimport useEventCallback from '../utils/useEventCallback';\nimport useForkRef from '../utils/useForkRef';\nimport useId from '../utils/useId';\nimport useIsFocusVisible from '../utils/useIsFocusVisible';\nimport useControlled from '../utils/useControlled';\nimport tooltipClasses, { getTooltipUtilityClass } from './tooltipClasses';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nimport { jsxs as _jsxs } from \"react/jsx-runtime\";\nfunction round(value) {\n return Math.round(value * 1e5) / 1e5;\n}\nconst useUtilityClasses = ownerState => {\n const {\n classes,\n disableInteractive,\n arrow,\n touch,\n placement\n } = ownerState;\n const slots = {\n popper: ['popper', !disableInteractive && 'popperInteractive', arrow && 'popperArrow'],\n tooltip: ['tooltip', arrow && 'tooltipArrow', touch && 'touch', `tooltipPlacement${capitalize(placement.split('-')[0])}`],\n arrow: ['arrow']\n };\n return composeClasses(slots, getTooltipUtilityClass, classes);\n};\nconst TooltipPopper = styled(Popper, {\n name: 'MuiTooltip',\n slot: 'Popper',\n overridesResolver: (props, styles) => {\n const {\n ownerState\n } = props;\n return [styles.popper, !ownerState.disableInteractive && styles.popperInteractive, ownerState.arrow && styles.popperArrow, !ownerState.open && styles.popperClose];\n }\n})(({\n theme,\n ownerState,\n open\n}) => _extends({\n zIndex: (theme.vars || theme).zIndex.tooltip,\n pointerEvents: 'none'\n}, !ownerState.disableInteractive && {\n pointerEvents: 'auto'\n}, !open && {\n pointerEvents: 'none'\n}, ownerState.arrow && {\n [`&[data-popper-placement*=\"bottom\"] .${tooltipClasses.arrow}`]: {\n top: 0,\n marginTop: '-0.71em',\n '&::before': {\n transformOrigin: '0 100%'\n }\n },\n [`&[data-popper-placement*=\"top\"] .${tooltipClasses.arrow}`]: {\n bottom: 0,\n marginBottom: '-0.71em',\n '&::before': {\n transformOrigin: '100% 0'\n }\n },\n [`&[data-popper-placement*=\"right\"] .${tooltipClasses.arrow}`]: _extends({}, !ownerState.isRtl ? {\n left: 0,\n marginLeft: '-0.71em'\n } : {\n right: 0,\n marginRight: '-0.71em'\n }, {\n height: '1em',\n width: '0.71em',\n '&::before': {\n transformOrigin: '100% 100%'\n }\n }),\n [`&[data-popper-placement*=\"left\"] .${tooltipClasses.arrow}`]: _extends({}, !ownerState.isRtl ? {\n right: 0,\n marginRight: '-0.71em'\n } : {\n left: 0,\n marginLeft: '-0.71em'\n }, {\n height: '1em',\n width: '0.71em',\n '&::before': {\n transformOrigin: '0 0'\n }\n })\n}));\nconst TooltipTooltip = styled('div', {\n name: 'MuiTooltip',\n slot: 'Tooltip',\n overridesResolver: (props, styles) => {\n const {\n ownerState\n } = props;\n return [styles.tooltip, ownerState.touch && styles.touch, ownerState.arrow && styles.tooltipArrow, styles[`tooltipPlacement${capitalize(ownerState.placement.split('-')[0])}`]];\n }\n})(({\n theme,\n ownerState\n}) => _extends({\n backgroundColor: theme.vars ? theme.vars.palette.Tooltip.bg : alpha(theme.palette.grey[700], 0.92),\n borderRadius: (theme.vars || theme).shape.borderRadius,\n color: (theme.vars || theme).palette.common.white,\n fontFamily: theme.typography.fontFamily,\n padding: '4px 8px',\n fontSize: theme.typography.pxToRem(11),\n maxWidth: 300,\n margin: 2,\n wordWrap: 'break-word',\n fontWeight: theme.typography.fontWeightMedium\n}, ownerState.arrow && {\n position: 'relative',\n margin: 0\n}, ownerState.touch && {\n padding: '8px 16px',\n fontSize: theme.typography.pxToRem(14),\n lineHeight: `${round(16 / 14)}em`,\n fontWeight: theme.typography.fontWeightRegular\n}, {\n [`.${tooltipClasses.popper}[data-popper-placement*=\"left\"] &`]: _extends({\n transformOrigin: 'right center'\n }, !ownerState.isRtl ? _extends({\n marginRight: '14px'\n }, ownerState.touch && {\n marginRight: '24px'\n }) : _extends({\n marginLeft: '14px'\n }, ownerState.touch && {\n marginLeft: '24px'\n })),\n [`.${tooltipClasses.popper}[data-popper-placement*=\"right\"] &`]: _extends({\n transformOrigin: 'left center'\n }, !ownerState.isRtl ? _extends({\n marginLeft: '14px'\n }, ownerState.touch && {\n marginLeft: '24px'\n }) : _extends({\n marginRight: '14px'\n }, ownerState.touch && {\n marginRight: '24px'\n })),\n [`.${tooltipClasses.popper}[data-popper-placement*=\"top\"] &`]: _extends({\n transformOrigin: 'center bottom',\n marginBottom: '14px'\n }, ownerState.touch && {\n marginBottom: '24px'\n }),\n [`.${tooltipClasses.popper}[data-popper-placement*=\"bottom\"] &`]: _extends({\n transformOrigin: 'center top',\n marginTop: '14px'\n }, ownerState.touch && {\n marginTop: '24px'\n })\n}));\nconst TooltipArrow = styled('span', {\n name: 'MuiTooltip',\n slot: 'Arrow',\n overridesResolver: (props, styles) => styles.arrow\n})(({\n theme\n}) => ({\n overflow: 'hidden',\n position: 'absolute',\n width: '1em',\n height: '0.71em' /* = width / sqrt(2) = (length of the hypotenuse) */,\n boxSizing: 'border-box',\n color: theme.vars ? theme.vars.palette.Tooltip.bg : alpha(theme.palette.grey[700], 0.9),\n '&::before': {\n content: '\"\"',\n margin: 'auto',\n display: 'block',\n width: '100%',\n height: '100%',\n backgroundColor: 'currentColor',\n transform: 'rotate(45deg)'\n }\n}));\nlet hystersisOpen = false;\nconst hystersisTimer = new Timeout();\nlet cursorPosition = {\n x: 0,\n y: 0\n};\nexport function testReset() {\n hystersisOpen = false;\n hystersisTimer.clear();\n}\nfunction composeEventHandler(handler, eventHandler) {\n return event => {\n if (eventHandler) {\n eventHandler(event);\n }\n handler(event);\n };\n}\n\n// TODO v6: Remove PopperComponent, PopperProps, TransitionComponent and TransitionProps.\nconst Tooltip = /*#__PURE__*/React.forwardRef(function Tooltip(inProps, ref) {\n var _ref, _slots$popper, _ref2, _ref3, _slots$transition, _ref4, _slots$tooltip, _ref5, _slots$arrow, _slotProps$popper, _ref6, _slotProps$popper2, _slotProps$transition, _slotProps$tooltip, _ref7, _slotProps$tooltip2, _slotProps$arrow, _ref8, _slotProps$arrow2;\n const props = useThemeProps({\n props: inProps,\n name: 'MuiTooltip'\n });\n const {\n arrow = false,\n children: childrenProp,\n components = {},\n componentsProps = {},\n describeChild = false,\n disableFocusListener = false,\n disableHoverListener = false,\n disableInteractive: disableInteractiveProp = false,\n disableTouchListener = false,\n enterDelay = 100,\n enterNextDelay = 0,\n enterTouchDelay = 700,\n followCursor = false,\n id: idProp,\n leaveDelay = 0,\n leaveTouchDelay = 1500,\n onClose,\n onOpen,\n open: openProp,\n placement = 'bottom',\n PopperComponent: PopperComponentProp,\n PopperProps = {},\n slotProps = {},\n slots = {},\n title,\n TransitionComponent: TransitionComponentProp = Grow,\n TransitionProps\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n\n // to prevent runtime errors, developers will need to provide a child as a React element anyway.\n const children = /*#__PURE__*/React.isValidElement(childrenProp) ? childrenProp : /*#__PURE__*/_jsx(\"span\", {\n children: childrenProp\n });\n const theme = useTheme();\n const isRtl = theme.direction === 'rtl';\n const [childNode, setChildNode] = React.useState();\n const [arrowRef, setArrowRef] = React.useState(null);\n const ignoreNonTouchEvents = React.useRef(false);\n const disableInteractive = disableInteractiveProp || followCursor;\n const closeTimer = useTimeout();\n const enterTimer = useTimeout();\n const leaveTimer = useTimeout();\n const touchTimer = useTimeout();\n const [openState, setOpenState] = useControlled({\n controlled: openProp,\n default: false,\n name: 'Tooltip',\n state: 'open'\n });\n let open = openState;\n if (process.env.NODE_ENV !== 'production') {\n // eslint-disable-next-line react-hooks/rules-of-hooks\n const {\n current: isControlled\n } = React.useRef(openProp !== undefined);\n\n // eslint-disable-next-line react-hooks/rules-of-hooks\n React.useEffect(() => {\n if (childNode && childNode.disabled && !isControlled && title !== '' && childNode.tagName.toLowerCase() === 'button') {\n console.error(['MUI: You are providing a disabled `button` child to the Tooltip component.', 'A disabled element does not fire events.', \"Tooltip needs to listen to the child element's events to display the title.\", '', 'Add a simple wrapper element, such as a `span`.'].join('\\n'));\n }\n }, [title, childNode, isControlled]);\n }\n const id = useId(idProp);\n const prevUserSelect = React.useRef();\n const stopTouchInteraction = useEventCallback(() => {\n if (prevUserSelect.current !== undefined) {\n document.body.style.WebkitUserSelect = prevUserSelect.current;\n prevUserSelect.current = undefined;\n }\n touchTimer.clear();\n });\n React.useEffect(() => stopTouchInteraction, [stopTouchInteraction]);\n const handleOpen = event => {\n hystersisTimer.clear();\n hystersisOpen = true;\n\n // The mouseover event will trigger for every nested element in the tooltip.\n // We can skip rerendering when the tooltip is already open.\n // We are using the mouseover event instead of the mouseenter event to fix a hide/show issue.\n setOpenState(true);\n if (onOpen && !open) {\n onOpen(event);\n }\n };\n const handleClose = useEventCallback(\n /**\n * @param {React.SyntheticEvent | Event} event\n */\n event => {\n hystersisTimer.start(800 + leaveDelay, () => {\n hystersisOpen = false;\n });\n setOpenState(false);\n if (onClose && open) {\n onClose(event);\n }\n closeTimer.start(theme.transitions.duration.shortest, () => {\n ignoreNonTouchEvents.current = false;\n });\n });\n const handleEnter = event => {\n if (ignoreNonTouchEvents.current && event.type !== 'touchstart') {\n return;\n }\n\n // Remove the title ahead of time.\n // We don't want to wait for the next render commit.\n // We would risk displaying two tooltips at the same time (native + this one).\n if (childNode) {\n childNode.removeAttribute('title');\n }\n enterTimer.clear();\n leaveTimer.clear();\n if (enterDelay || hystersisOpen && enterNextDelay) {\n enterTimer.start(hystersisOpen ? enterNextDelay : enterDelay, () => {\n handleOpen(event);\n });\n } else {\n handleOpen(event);\n }\n };\n const handleLeave = event => {\n enterTimer.clear();\n leaveTimer.start(leaveDelay, () => {\n handleClose(event);\n });\n };\n const {\n isFocusVisibleRef,\n onBlur: handleBlurVisible,\n onFocus: handleFocusVisible,\n ref: focusVisibleRef\n } = useIsFocusVisible();\n // We don't necessarily care about the focusVisible state (which is safe to access via ref anyway).\n // We just need to re-render the Tooltip if the focus-visible state changes.\n const [, setChildIsFocusVisible] = React.useState(false);\n const handleBlur = event => {\n handleBlurVisible(event);\n if (isFocusVisibleRef.current === false) {\n setChildIsFocusVisible(false);\n handleLeave(event);\n }\n };\n const handleFocus = event => {\n // Workaround for https://github.com/facebook/react/issues/7769\n // The autoFocus of React might trigger the event before the componentDidMount.\n // We need to account for this eventuality.\n if (!childNode) {\n setChildNode(event.currentTarget);\n }\n handleFocusVisible(event);\n if (isFocusVisibleRef.current === true) {\n setChildIsFocusVisible(true);\n handleEnter(event);\n }\n };\n const detectTouchStart = event => {\n ignoreNonTouchEvents.current = true;\n const childrenProps = children.props;\n if (childrenProps.onTouchStart) {\n childrenProps.onTouchStart(event);\n }\n };\n const handleMouseOver = handleEnter;\n const handleMouseLeave = handleLeave;\n const handleTouchStart = event => {\n detectTouchStart(event);\n leaveTimer.clear();\n closeTimer.clear();\n stopTouchInteraction();\n prevUserSelect.current = document.body.style.WebkitUserSelect;\n // Prevent iOS text selection on long-tap.\n document.body.style.WebkitUserSelect = 'none';\n touchTimer.start(enterTouchDelay, () => {\n document.body.style.WebkitUserSelect = prevUserSelect.current;\n handleEnter(event);\n });\n };\n const handleTouchEnd = event => {\n if (children.props.onTouchEnd) {\n children.props.onTouchEnd(event);\n }\n stopTouchInteraction();\n leaveTimer.start(leaveTouchDelay, () => {\n handleClose(event);\n });\n };\n React.useEffect(() => {\n if (!open) {\n return undefined;\n }\n\n /**\n * @param {KeyboardEvent} nativeEvent\n */\n function handleKeyDown(nativeEvent) {\n // IE11, Edge (prior to using Bink?) use 'Esc'\n if (nativeEvent.key === 'Escape' || nativeEvent.key === 'Esc') {\n handleClose(nativeEvent);\n }\n }\n document.addEventListener('keydown', handleKeyDown);\n return () => {\n document.removeEventListener('keydown', handleKeyDown);\n };\n }, [handleClose, open]);\n const handleRef = useForkRef(children.ref, focusVisibleRef, setChildNode, ref);\n\n // There is no point in displaying an empty tooltip.\n // So we exclude all falsy values, except 0, which is valid.\n if (!title && title !== 0) {\n open = false;\n }\n const popperRef = React.useRef();\n const handleMouseMove = event => {\n const childrenProps = children.props;\n if (childrenProps.onMouseMove) {\n childrenProps.onMouseMove(event);\n }\n cursorPosition = {\n x: event.clientX,\n y: event.clientY\n };\n if (popperRef.current) {\n popperRef.current.update();\n }\n };\n const nameOrDescProps = {};\n const titleIsString = typeof title === 'string';\n if (describeChild) {\n nameOrDescProps.title = !open && titleIsString && !disableHoverListener ? title : null;\n nameOrDescProps['aria-describedby'] = open ? id : null;\n } else {\n nameOrDescProps['aria-label'] = titleIsString ? title : null;\n nameOrDescProps['aria-labelledby'] = open && !titleIsString ? id : null;\n }\n const childrenProps = _extends({}, nameOrDescProps, other, children.props, {\n className: clsx(other.className, children.props.className),\n onTouchStart: detectTouchStart,\n ref: handleRef\n }, followCursor ? {\n onMouseMove: handleMouseMove\n } : {});\n if (process.env.NODE_ENV !== 'production') {\n childrenProps['data-mui-internal-clone-element'] = true;\n\n // eslint-disable-next-line react-hooks/rules-of-hooks\n React.useEffect(() => {\n if (childNode && !childNode.getAttribute('data-mui-internal-clone-element')) {\n console.error(['MUI: The `children` component of the Tooltip is not forwarding its props correctly.', 'Please make sure that props are spread on the same element that the ref is applied to.'].join('\\n'));\n }\n }, [childNode]);\n }\n const interactiveWrapperListeners = {};\n if (!disableTouchListener) {\n childrenProps.onTouchStart = handleTouchStart;\n childrenProps.onTouchEnd = handleTouchEnd;\n }\n if (!disableHoverListener) {\n childrenProps.onMouseOver = composeEventHandler(handleMouseOver, childrenProps.onMouseOver);\n childrenProps.onMouseLeave = composeEventHandler(handleMouseLeave, childrenProps.onMouseLeave);\n if (!disableInteractive) {\n interactiveWrapperListeners.onMouseOver = handleMouseOver;\n interactiveWrapperListeners.onMouseLeave = handleMouseLeave;\n }\n }\n if (!disableFocusListener) {\n childrenProps.onFocus = composeEventHandler(handleFocus, childrenProps.onFocus);\n childrenProps.onBlur = composeEventHandler(handleBlur, childrenProps.onBlur);\n if (!disableInteractive) {\n interactiveWrapperListeners.onFocus = handleFocus;\n interactiveWrapperListeners.onBlur = handleBlur;\n }\n }\n if (process.env.NODE_ENV !== 'production') {\n if (children.props.title) {\n console.error(['MUI: You have provided a `title` prop to the child of .', `Remove this title prop \\`${children.props.title}\\` or the Tooltip component.`].join('\\n'));\n }\n }\n const popperOptions = React.useMemo(() => {\n var _PopperProps$popperOp;\n let tooltipModifiers = [{\n name: 'arrow',\n enabled: Boolean(arrowRef),\n options: {\n element: arrowRef,\n padding: 4\n }\n }];\n if ((_PopperProps$popperOp = PopperProps.popperOptions) != null && _PopperProps$popperOp.modifiers) {\n tooltipModifiers = tooltipModifiers.concat(PopperProps.popperOptions.modifiers);\n }\n return _extends({}, PopperProps.popperOptions, {\n modifiers: tooltipModifiers\n });\n }, [arrowRef, PopperProps]);\n const ownerState = _extends({}, props, {\n isRtl,\n arrow,\n disableInteractive,\n placement,\n PopperComponentProp,\n touch: ignoreNonTouchEvents.current\n });\n const classes = useUtilityClasses(ownerState);\n const PopperComponent = (_ref = (_slots$popper = slots.popper) != null ? _slots$popper : components.Popper) != null ? _ref : TooltipPopper;\n const TransitionComponent = (_ref2 = (_ref3 = (_slots$transition = slots.transition) != null ? _slots$transition : components.Transition) != null ? _ref3 : TransitionComponentProp) != null ? _ref2 : Grow;\n const TooltipComponent = (_ref4 = (_slots$tooltip = slots.tooltip) != null ? _slots$tooltip : components.Tooltip) != null ? _ref4 : TooltipTooltip;\n const ArrowComponent = (_ref5 = (_slots$arrow = slots.arrow) != null ? _slots$arrow : components.Arrow) != null ? _ref5 : TooltipArrow;\n const popperProps = appendOwnerState(PopperComponent, _extends({}, PopperProps, (_slotProps$popper = slotProps.popper) != null ? _slotProps$popper : componentsProps.popper, {\n className: clsx(classes.popper, PopperProps == null ? void 0 : PopperProps.className, (_ref6 = (_slotProps$popper2 = slotProps.popper) != null ? _slotProps$popper2 : componentsProps.popper) == null ? void 0 : _ref6.className)\n }), ownerState);\n const transitionProps = appendOwnerState(TransitionComponent, _extends({}, TransitionProps, (_slotProps$transition = slotProps.transition) != null ? _slotProps$transition : componentsProps.transition), ownerState);\n const tooltipProps = appendOwnerState(TooltipComponent, _extends({}, (_slotProps$tooltip = slotProps.tooltip) != null ? _slotProps$tooltip : componentsProps.tooltip, {\n className: clsx(classes.tooltip, (_ref7 = (_slotProps$tooltip2 = slotProps.tooltip) != null ? _slotProps$tooltip2 : componentsProps.tooltip) == null ? void 0 : _ref7.className)\n }), ownerState);\n const tooltipArrowProps = appendOwnerState(ArrowComponent, _extends({}, (_slotProps$arrow = slotProps.arrow) != null ? _slotProps$arrow : componentsProps.arrow, {\n className: clsx(classes.arrow, (_ref8 = (_slotProps$arrow2 = slotProps.arrow) != null ? _slotProps$arrow2 : componentsProps.arrow) == null ? void 0 : _ref8.className)\n }), ownerState);\n return /*#__PURE__*/_jsxs(React.Fragment, {\n children: [/*#__PURE__*/React.cloneElement(children, childrenProps), /*#__PURE__*/_jsx(PopperComponent, _extends({\n as: PopperComponentProp != null ? PopperComponentProp : Popper,\n placement: placement,\n anchorEl: followCursor ? {\n getBoundingClientRect: () => ({\n top: cursorPosition.y,\n left: cursorPosition.x,\n right: cursorPosition.x,\n bottom: cursorPosition.y,\n width: 0,\n height: 0\n })\n } : childNode,\n popperRef: popperRef,\n open: childNode ? open : false,\n id: id,\n transition: true\n }, interactiveWrapperListeners, popperProps, {\n popperOptions: popperOptions,\n children: ({\n TransitionProps: TransitionPropsInner\n }) => /*#__PURE__*/_jsx(TransitionComponent, _extends({\n timeout: theme.transitions.duration.shorter\n }, TransitionPropsInner, transitionProps, {\n children: /*#__PURE__*/_jsxs(TooltipComponent, _extends({}, tooltipProps, {\n children: [title, arrow ? /*#__PURE__*/_jsx(ArrowComponent, _extends({}, tooltipArrowProps, {\n ref: setArrowRef\n })) : null]\n }))\n }))\n }))]\n });\n});\nprocess.env.NODE_ENV !== \"production\" ? Tooltip.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the d.ts file and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * If `true`, adds an arrow to the tooltip.\n * @default false\n */\n arrow: PropTypes.bool,\n /**\n * Tooltip reference element.\n */\n children: elementAcceptingRef.isRequired,\n /**\n * Override or extend the styles applied to the component.\n */\n classes: PropTypes.object,\n /**\n * @ignore\n */\n className: PropTypes.string,\n /**\n * The components used for each slot inside.\n *\n * This prop is an alias for the `slots` prop.\n * It's recommended to use the `slots` prop instead.\n *\n * @default {}\n */\n components: PropTypes.shape({\n Arrow: PropTypes.elementType,\n Popper: PropTypes.elementType,\n Tooltip: PropTypes.elementType,\n Transition: PropTypes.elementType\n }),\n /**\n * The extra props for the slot components.\n * You can override the existing props or add new ones.\n *\n * This prop is an alias for the `slotProps` prop.\n * It's recommended to use the `slotProps` prop instead, as `componentsProps` will be deprecated in the future.\n *\n * @default {}\n */\n componentsProps: PropTypes.shape({\n arrow: PropTypes.object,\n popper: PropTypes.object,\n tooltip: PropTypes.object,\n transition: PropTypes.object\n }),\n /**\n * Set to `true` if the `title` acts as an accessible description.\n * By default the `title` acts as an accessible label for the child.\n * @default false\n */\n describeChild: PropTypes.bool,\n /**\n * Do not respond to focus-visible events.\n * @default false\n */\n disableFocusListener: PropTypes.bool,\n /**\n * Do not respond to hover events.\n * @default false\n */\n disableHoverListener: PropTypes.bool,\n /**\n * Makes a tooltip not interactive, i.e. it will close when the user\n * hovers over the tooltip before the `leaveDelay` is expired.\n * @default false\n */\n disableInteractive: PropTypes.bool,\n /**\n * Do not respond to long press touch events.\n * @default false\n */\n disableTouchListener: PropTypes.bool,\n /**\n * The number of milliseconds to wait before showing the tooltip.\n * This prop won't impact the enter touch delay (`enterTouchDelay`).\n * @default 100\n */\n enterDelay: PropTypes.number,\n /**\n * The number of milliseconds to wait before showing the tooltip when one was already recently opened.\n * @default 0\n */\n enterNextDelay: PropTypes.number,\n /**\n * The number of milliseconds a user must touch the element before showing the tooltip.\n * @default 700\n */\n enterTouchDelay: PropTypes.number,\n /**\n * If `true`, the tooltip follow the cursor over the wrapped element.\n * @default false\n */\n followCursor: PropTypes.bool,\n /**\n * This prop is used to help implement the accessibility logic.\n * If you don't provide this prop. It falls back to a randomly generated id.\n */\n id: PropTypes.string,\n /**\n * The number of milliseconds to wait before hiding the tooltip.\n * This prop won't impact the leave touch delay (`leaveTouchDelay`).\n * @default 0\n */\n leaveDelay: PropTypes.number,\n /**\n * The number of milliseconds after the user stops touching an element before hiding the tooltip.\n * @default 1500\n */\n leaveTouchDelay: PropTypes.number,\n /**\n * Callback fired when the component requests to be closed.\n *\n * @param {React.SyntheticEvent} event The event source of the callback.\n */\n onClose: PropTypes.func,\n /**\n * Callback fired when the component requests to be open.\n *\n * @param {React.SyntheticEvent} event The event source of the callback.\n */\n onOpen: PropTypes.func,\n /**\n * If `true`, the component is shown.\n */\n open: PropTypes.bool,\n /**\n * Tooltip placement.\n * @default 'bottom'\n */\n placement: PropTypes.oneOf(['bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n /**\n * The component used for the popper.\n * @default Popper\n */\n PopperComponent: PropTypes.elementType,\n /**\n * Props applied to the [`Popper`](/material-ui/api/popper/) element.\n * @default {}\n */\n PopperProps: PropTypes.object,\n /**\n * The extra props for the slot components.\n * You can override the existing props or add new ones.\n *\n * This prop is an alias for the `componentsProps` prop, which will be deprecated in the future.\n *\n * @default {}\n */\n slotProps: PropTypes.shape({\n arrow: PropTypes.object,\n popper: PropTypes.object,\n tooltip: PropTypes.object,\n transition: PropTypes.object\n }),\n /**\n * The components used for each slot inside.\n *\n * This prop is an alias for the `components` prop, which will be deprecated in the future.\n *\n * @default {}\n */\n slots: PropTypes.shape({\n arrow: PropTypes.elementType,\n popper: PropTypes.elementType,\n tooltip: PropTypes.elementType,\n transition: PropTypes.elementType\n }),\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Tooltip title. Zero-length titles string, undefined, null and false are never displayed.\n */\n title: PropTypes.node,\n /**\n * The component used for the transition.\n * [Follow this guide](/material-ui/transitions/#transitioncomponent-prop) to learn more about the requirements for this component.\n * @default Grow\n */\n TransitionComponent: PropTypes.elementType,\n /**\n * Props applied to the transition element.\n * By default, the element is based on this [`Transition`](http://reactcommunity.org/react-transition-group/transition/) component.\n */\n TransitionProps: PropTypes.object\n} : void 0;\nexport default Tooltip;","import '@/components/mui/menu-item.component.css';\nimport ArrowRightIcon from '@mui/icons-material/ArrowRight';\nimport {\n ListItemIcon as MuiListItemIcon,\n ListItemText as MuiListItemText,\n MenuItem as MuiMenuItem,\n} from '@mui/material';\nimport Tooltip from '@mui/material/Tooltip';\nimport { Localized, ReferencedItem, SingleColumnMenu } from 'platform-bible-utils';\nimport { MouseEvent, PropsWithChildren } from 'react';\n\ntype MenuItemInfoBase = {\n /** Text (displayable in the UI) as the name of the menu item */\n label: string;\n /** Text to display when the mouse hovers over the menu item */\n tooltip?: string;\n};\n\nexport type Command = MenuItemInfoBase & {\n /** Command to execute (string.string) */\n command: string;\n};\n\ntype SubMenu = MenuItemInfoBase & {\n /** Command to execute (string.string) */\n items: MenuItemInfo[];\n};\n\nexport interface CommandHandler {\n (command: Command): void;\n}\n\nexport type MenuPropsBase = {\n /*\n * The JSON defining the menu whose items are to be rendered. This will typically be one of the\n * menus in the \"defs\" in a Platform.Bible menu (see PlatformMenus). The schema for this is\n * menuDocumentSchema (at the end of menus.model.ts). Note that while this is a\n * \"SingleColumnMenu\", somewhat bizarrely, a MultiColumnMenu is a SingleColumnMenu, so it really\n * could be a MultiColumnMenu, in which case, column had better be defined so it can be used\n * to filter out the actual groups and items to display on the column.\n */\n menuDefinition: Localized;\n\n commandHandler: CommandHandler;\n\n /**\n * Additional action to perform when any menu item is clicked. Allows the caller to handle event\n * (e.g., to close the menu).\n */\n onClick?: (event: MouseEvent) => void;\n};\n\nexport type MenuItemListProps = MenuPropsBase & {\n /** Optional unique (column) identifier */\n columnId?: ReferencedItem;\n};\n\nexport type MenuItemProps = Omit &\n PropsWithChildren<{\n /** Optional unique identifier */\n id?: string;\n\n onClick: (event: MouseEvent) => void;\n }>;\n\ntype MenuItemInfo = (Command | SubMenu) & {\n /**\n * If specified, menu item will be inset if it does not have a leading icon.\n *\n * @default true\n */\n allowForLeadingIcons?: boolean;\n /**\n * If specified, the path to the icon image to display on the leading side of the menu text.\n *\n * @default undefined (no leading icon will be shown)\n */\n iconPathBefore?: string;\n /**\n * If specified, the path to the icon image to display on the trailing side of the menu text.\n *\n * @default undefined (no trailing icon will be shown)\n */\n iconPathAfter?: string;\n /**\n * If true, list item is focused during the first mount\n *\n * @default false\n */\n hasAutoFocus?: boolean;\n\n /** Additional css classes to help with unique styling of the menu item */\n className?: string;\n\n /**\n * If true, the menu item will appear disabled and it will not respond to clicks or mouse hovers.\n *\n * @default false\n */\n isDisabled?: boolean;\n\n /**\n * If true, compact vertical padding designed for keyboard and mouse input is used.\n *\n * @default true\n */\n isDense?: boolean;\n\n /**\n * If true, a right-arrow icon will be displayed (iconPathAfter, if specified, will be ignored).\n *\n * @default false\n */\n isSubMenuParent?: boolean;\n\n /**\n * If true, the left and right padding is removed\n *\n * @default false\n */\n hasDisabledGutters?: boolean;\n\n /**\n * If true, a 1px light border is added to bottom of menu item\n *\n * @default false\n */\n hasDivider?: boolean;\n\n /** Help identify which element has keyboard focus */\n focusVisibleClassName?: string;\n\n /** If it's a submenu, it should have the items property */\n items?: MenuItemInfo[];\n};\n\nfunction getIcon(icon: string | undefined, menuLabel: string, leading: boolean) {\n return icon ? (\n \n {`${leading\n \n ) : undefined;\n}\n\nexport default function MenuItem(props: MenuItemProps) {\n const {\n onClick,\n label,\n tooltip,\n allowForLeadingIcons = true,\n iconPathBefore = undefined,\n iconPathAfter = undefined,\n hasAutoFocus = false,\n className,\n isDisabled = false,\n isDense = true,\n isSubMenuParent = false,\n hasDisabledGutters = false,\n hasDivider = false,\n focusVisibleClassName,\n id,\n children,\n } = props;\n\n const menuItem = (\n \n {label ? (\n <>\n {getIcon(iconPathBefore, label, true)}\n \n {isSubMenuParent ? (\n \n \n \n ) : (\n getIcon(iconPathAfter, label, false)\n )}\n \n ) : (\n children\n )}\n \n );\n\n return tooltip ? (\n \n
    {menuItem}
    \n
    \n ) : (\n menuItem\n );\n}\n","import MenuItem, {\n MenuItemListProps,\n MenuItemProps,\n MenuPropsBase,\n} from '@/components/mui/menu-item.component';\nimport { Menu } from '@mui/material';\nimport {\n Localized,\n MenuGroupDetailsInSubMenu,\n MenuItemContainingCommand,\n MenuItemContainingSubmenu,\n OrderedExtensibleContainer,\n ReferencedItem,\n SingleColumnMenu,\n} from 'platform-bible-utils';\nimport { MouseEvent, useMemo, useState } from 'react';\n\n/**\n * All the exported types in this file should be regarded as \"internal\" (i.e., they should not be\n * exposed via index.ts).\n */\n\nexport type GroupedMenuPropsBase = MenuPropsBase & {\n /** Optional unique (column) identifier */\n columnId?: ReferencedItem;\n};\n\nexport type GroupedMenuItemListProps = MenuItemListProps & {\n /**\n * If the menuDefinition includes \"top-level\" groups (i.e., those that belong to a column as\n * opposed to those that belong to a submenu) that should not be included in the list, then this\n * array specifies which groups to include. Likewise, for a submenu, this list indicates which\n * groups are pertinent for that submenu. So then for a context menu this property need not be\n * specified since it is a top-level menu based on a \"true\" SingleColumnMenu (i.e., one that is\n * not a MultiColumnMenu).\n */\n includedGroups?: {\n id: string;\n group: Localized;\n }[];\n};\n\ninterface ItemInfo {\n item: Localized;\n isLastItemInGroup: boolean;\n}\n\ntype SubMenuProps = MenuPropsBase & {\n parentMenuItem: Localized;\n parentItemProps: Omit, 'iconPathAfter'>;\n};\n\nfunction getAllGroups(menuDefinition: Localized) {\n const groupEntries = Object.entries(menuDefinition.groups);\n // Convert array of entries to array of objects with id and group properties\n return groupEntries.map(([key, value]) => ({ id: key, group: value }));\n}\n\nfunction SubMenu(props: SubMenuProps) {\n const [anchorEl, setAnchorEl] = useState(undefined);\n\n const { parentMenuItem, parentItemProps, menuDefinition } = props;\n\n const handleParentMenuItemClick = (event: MouseEvent) => {\n setAnchorEl(event.currentTarget);\n };\n\n const handleClose = () => {\n setAnchorEl(undefined);\n };\n\n const renderSubMenuItems = () => {\n let includedGroups = getAllGroups(menuDefinition).filter((g) => 'menuItem' in g.group);\n\n // Ensure valid parent menu was provided. (If not, submenu will contain all groups!)\n if (!parentMenuItem?.id) throw new Error('A valid parent menu item is required for submenus.');\n\n // When laying out a submenu, only include groups associated with the provided parent menu.\n // Note: without the (annoying) redundant check that the included groups\n // have the menuItem field, TS doesn't think it exists.\n includedGroups = includedGroups.filter(\n (group) => 'menuItem' in group.group && group.group.menuItem === parentMenuItem.id,\n );\n\n return ;\n };\n\n return (\n <>\n \n \n {renderSubMenuItems()}\n \n \n );\n}\n\nconst getOrderedGroupItems = (\n groupId: string,\n allItems: Localized[],\n) => {\n // Filter items that belong to the specified group\n const itemsForGroup = allItems.filter((item) => item.group === groupId);\n // Sort items based on order\n const sortedItems = itemsForGroup.sort((a, b) => (a.order || 0) - (b.order || 0));\n return sortedItems;\n};\n\n/**\n * This component is internal; it does not need to be exposed to the outside world since it is not\n * useful on its own. It is used to generate and lay out the MenuItems that appear either on a\n * top-level menu (in a GridMenu or ContextMenu) or in a submenu.\n */\nexport default function GroupedMenuItemList(menuProps: GroupedMenuItemListProps) {\n const { menuDefinition, onClick, commandHandler, includedGroups } = menuProps;\n\n const { items, allowForLeadingIcons } = useMemo(() => {\n const groupsToInclude =\n includedGroups && includedGroups.length > 0\n ? includedGroups\n : // We're apparently laying out a single-column menu (presumably a context menu). In this\n // case, all groups should be included except ones that belong to a submenu.\n getAllGroups(menuDefinition).filter((g) => !('menuItem' in g.group));\n\n const sortedGroups = Object.values(groupsToInclude).sort(\n (a, b) => (a.group.order || 0) - (b.group.order || 0),\n );\n\n const itemArray: ItemInfo[] = [];\n\n sortedGroups.forEach((group) => {\n getOrderedGroupItems(group.id, menuDefinition.items).forEach((item) =>\n itemArray.push({ item, isLastItemInGroup: false }),\n );\n if (itemArray.length > 0) itemArray[itemArray.length - 1].isLastItemInGroup = true;\n });\n\n // No divider after last item in final group.\n if (itemArray.length > 0) itemArray[itemArray.length - 1].isLastItemInGroup = false;\n\n const allowSpaceForLeadingIcons = itemArray.some(\n (i) => 'iconPathBefore' in i.item && i.item.iconPathBefore,\n );\n\n return { items: itemArray, allowForLeadingIcons: allowSpaceForLeadingIcons };\n }, [includedGroups, menuDefinition]);\n\n // Create props for MenuItem component including setting hasDivider for the last item in a group\n const createMenuItemProps = ({ item, isLastItemInGroup }: ItemInfo) => {\n const menuItemProps = {\n className: 'papi-menu-item',\n label: item.label,\n tooltip: item.tooltip,\n iconPathBefore: 'iconPathBefore' in item ? item.iconPathBefore : undefined,\n iconPathAfter: 'iconPathAfter' in item ? item.iconPathAfter : undefined,\n hasDivider: isLastItemInGroup, // Set hasDivider to true for the last item in a group\n allowForLeadingIcons,\n };\n\n return menuItemProps;\n };\n\n const [firstItem] = items;\n\n if (!firstItem) return
    ;\n\n const divKey = firstItem.item.group;\n\n return (\n
    \n {items.map((itemInfo, index) => {\n const { item } = itemInfo;\n const menuItemProps = createMenuItemProps(itemInfo);\n if ('command' in item) {\n const key = item.group + index;\n return (\n ) => {\n onClick?.(event);\n commandHandler(item);\n }}\n {...menuItemProps}\n />\n );\n }\n return (\n \n );\n })}\n
    \n );\n}\n","import GroupedMenuItemList from '@/components/mui/grouped-menu-item-list.component';\nimport { MenuItemListProps } from '@/components/mui/menu-item.component';\nimport { MultiColumnMenu } from 'platform-bible-utils';\n\n/**\n * This component is internal; it does not need to be exposed to the outside world since it is not\n * useful on its own. Use either GridMenu or ContextMenu.\n */\nexport default function TopLevelMenu(props: MenuItemListProps) {\n const { menuDefinition, columnId } = props;\n\n const groupEntries = Object.entries(menuDefinition.groups);\n // Convert array of entries to array of objects with id and group properties\n const groups = groupEntries.map(([key, value]) => ({ id: key, group: value }));\n let includedGroups = groups.filter((g) => 'column' in g.group);\n\n // Check if column is provided and menuDefinition is a MultiColumnMenu\n if (\n columnId &&\n 'columns' in menuDefinition &&\n // Without this type assertion, TS doesn't know what columns is.\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n (menuDefinition as MultiColumnMenu).columns[columnId]\n ) {\n // When laying out a single column in a MultiColumnMenu, only include groups associated with\n // the provided column. Note: without the (annoying) redundant check that the included groups\n // have the colum field, TS doesn't think it exists.\n includedGroups = includedGroups.filter(\n (g) => 'column' in g.group && g.group.column === columnId,\n );\n }\n\n return ;\n}\n","import '@/components/mui/grid-menu.component.css';\nimport { GroupedMenuPropsBase } from '@/components/mui/grouped-menu-item-list.component';\nimport { CommandHandler } from '@/components/mui/menu-item.component';\nimport TopLevelMenu from '@/components/mui/top-level-menu.component';\nimport { Grid, List } from '@mui/material';\nimport {\n Localized,\n MenuColumnWithHeader,\n MultiColumnMenu,\n ReferencedItem,\n} from 'platform-bible-utils';\nimport { useMemo } from 'react';\n\ntype ColumnInfo = {\n /*\n * The ID (`${string}.${string}`) of a specific menu column.\n */\n id: ReferencedItem;\n\n /*\n * Metadata (label, order, etc.) for a specific menu column.\n */\n metadata: Localized;\n};\n\ntype MenuColumnProps = ColumnInfo &\n GroupedMenuPropsBase & {\n /** Additional css classes to help with unique styling of the menu column */\n className?: string;\n };\n\nexport type GridMenuInfo = {\n /** The menu object containing information about the columns, groups, and items to display. */\n multiColumnMenu: Localized;\n};\n\nexport type GridMenuProps = GridMenuInfo & {\n /** Optional unique identifier */\n id?: string;\n\n commandHandler: CommandHandler;\n\n /** Additional css classes to help with unique styling of the grid menu */\n className?: string;\n};\n\nfunction MenuColumn({\n commandHandler,\n menuDefinition,\n id,\n metadata,\n onClick,\n className,\n}: MenuColumnProps) {\n return (\n \n

    \n {metadata.label}\n

    \n {/* It would seem as though this List component were unnecessary, since it only contains one\n thing, but the \"dense\" property does affect the layout of the items (in a way I don't fully\n understand). There might be a better way. */}\n \n \n \n \n );\n}\n\nexport default function GridMenu({\n commandHandler,\n className,\n multiColumnMenu,\n id,\n}: GridMenuProps) {\n const { columns } = multiColumnMenu;\n\n const sortedColumns = useMemo(() => {\n const columnNumbers = new Map();\n Object.getOwnPropertyNames(columns).forEach((columnName: string) => {\n // We know for sure there is a (boolean) property 'isExtensible' that we are not interested in.\n if (columnName === 'isExtensible') return;\n // TS doesn't allow `columnName` above to be a ReferencedItem even though the type says it is\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const columnId = columnName as ReferencedItem;\n const column = columns[columnId];\n // As of right now (and hopefully forever after), all remaining properties of the\n // ColumnsWithHeaders object are columns whose property names are the IDs of the columns.\n // This is an additional (redundant) sanity check. Specifically we're interested in\n // MenuColumnWithHeader objects, which TypeScript now \"knows\" we have, but at runtime all we\n // can check for is that it's an object with a valid numeric order field. That's likely good\n // enough.\n if (\n typeof column === 'object' &&\n typeof column.order === 'number' &&\n !Number.isNaN(column.order)\n )\n columnNumbers.set(column.order, { id: columnId, metadata: column });\n else\n console.warn(\n `Property ${columnName} (${typeof column}) on menu ${id} is not a valid column and is being ignored. This might indicate data corruption`,\n );\n });\n\n // Extract values and sort them based on the 'order' property\n return Array.from(columnNumbers.values()).sort((a, b) => {\n return (a.metadata.order || 0) - (b.metadata.order || 0);\n });\n }, [columns, id]);\n\n // We might need something like this if we need to be able to prevent empty columns\n // sortedColumns.filter((c) => multiColumnMenu.groups.some((g) => 'column' in g && (g as .column)...\n\n return (\n \n {sortedColumns.map((col, index) => (\n \n ))}\n \n );\n}\n","import { useEffect, useRef, useState } from 'react';\n\nexport type UsePromiseOptions = {\n /**\n * Whether to leave the value as the most recent resolved promise value or set it back to\n * defaultValue while running the promise again. Defaults to true\n */\n preserveValue?: boolean;\n};\n\n/** Set up defaults for options for usePromise hook */\nfunction getUsePromiseOptionsDefaults(options: UsePromiseOptions): UsePromiseOptions {\n return {\n preserveValue: true,\n ...options,\n };\n}\n\n/**\n * Awaits a promise and returns a loading value while the promise is unresolved\n *\n * @param promiseFactoryCallback A function that returns the promise to await. If this callback is\n * undefined, the current value will be returned (defaultValue unless it was previously changed\n * and `options.preserveValue` is true), and there will be no loading.\n *\n * WARNING: MUST BE STABLE - const or wrapped in useCallback. The reference must not be updated\n * every render\n * @param defaultValue The initial value to return while first awaiting the promise. If\n * `options.preserveValue` is false, this value is also shown while awaiting the promise on\n * subsequent calls.\n *\n * Note: this parameter is internally assigned to a `ref`, so changing it will not cause any hooks\n * to re-run with its new value. This means that, if the `promiseFactoryCallback` changes and\n * `options.preserveValue` is `false`, the returned value will be set to the current\n * `defaultValue`. However, the returned value will not be updated if`defaultValue` changes.\n * @param options Various options for adjusting how this hook runs the `promiseFactoryCallback`\n *\n * Note: this parameter is internally assigned to a `ref`, so changing it will not cause any hooks\n * to re-run with its new value. However, the latest `options.preserveValue` will always be used\n * appropriately to determine whether to preserve the returned value when changing the\n * `promiseFactoryCallback`\n * @returns `[value, isLoading]`\n *\n * - `value`: the current value for the promise, either the defaultValue or the resolved promise value\n * - `isLoading`: whether the promise is waiting to be resolved\n */\nconst usePromise = (\n promiseFactoryCallback: (() => Promise) | undefined,\n defaultValue: T,\n options: UsePromiseOptions = {},\n): [value: T, isLoading: boolean] => {\n // Use defaultValue as a ref so it doesn't update dependency arrays\n const defaultValueRef = useRef(defaultValue);\n defaultValueRef.current = defaultValue;\n // Use options as a ref so it doesn't update dependency arrays\n const optionsDefaultedRef = useRef(options);\n optionsDefaultedRef.current = getUsePromiseOptionsDefaults(optionsDefaultedRef.current);\n\n const [value, setValue] = useState(() => defaultValueRef.current);\n const [isLoading, setIsLoading] = useState(true);\n useEffect(() => {\n let promiseIsCurrent = true;\n // If a promiseFactoryCallback was provided, we are loading. Otherwise, there is no loading to do\n setIsLoading(!!promiseFactoryCallback);\n (async () => {\n // If there is a callback to run, run it\n if (promiseFactoryCallback) {\n const result = await promiseFactoryCallback();\n // If the promise was not already replaced, update the value\n if (promiseIsCurrent) {\n setValue(() => result);\n setIsLoading(false);\n }\n }\n })();\n\n return () => {\n // Mark this promise as old and not to be used\n promiseIsCurrent = false;\n if (!optionsDefaultedRef.current.preserveValue) setValue(() => defaultValueRef.current);\n };\n }, [promiseFactoryCallback]);\n\n return [value, isLoading];\n};\nexport default usePromise;\n","\"use client\";\n\nimport createSvgIcon from './utils/createSvgIcon';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nexport default createSvgIcon( /*#__PURE__*/_jsx(\"path\", {\n d: \"M3 18h18v-2H3zm0-5h18v-2H3zm0-7v2h18V6z\"\n}), 'Menu');","import GridMenu from '@/components/mui/grid-menu.component';\nimport { Command, CommandHandler } from '@/components/mui/menu-item.component';\nimport usePromise from '@/hooks/use-promise.hook';\nimport { Menu as MenuIcon } from '@mui/icons-material';\nimport { Drawer, IconButton } from '@mui/material';\nimport { Localized, MultiColumnMenu } from 'platform-bible-utils';\nimport {\n MouseEvent,\n MutableRefObject,\n PropsWithChildren,\n useCallback,\n useEffect,\n useState,\n} from 'react';\n\nexport interface MultiColumnMenuProvider {\n (isSupportAndDevelopment: boolean): Promise>;\n}\n\nexport type HamburgerMenuButtonProps = PropsWithChildren & {\n /** The handler to use for menu commands (and eventually toolbar commands). */\n commandHandler: CommandHandler;\n\n /**\n * Optional reference to the \"div\" container that determines the where the menu should appear. If\n * not defined, then (1,1) used.\n */\n containerRef?: MutableRefObject;\n\n /**\n * The delegate to use to get the menu data. If not specified or if it returns undefined, the data\n * in normalMenu or fullMenu property will be used.\n */\n menuProvider?: MultiColumnMenuProvider;\n\n /**\n * The menu data to show when the menu is opened if the menuProvider property is not defined.\n * (This allows for a default or test-only static menu to be used.)\n */\n normalMenu?: Localized;\n\n /**\n * The menu data to show for \"full\" menu (when opened with the SHIFT key pressed) if the\n * menuProvider property is not defined. (This allows for a default or test-only static menu to be\n * used.)\n */\n fullMenu?: Localized;\n\n /** Additional css class(es) to help with unique styling of the sub-components */\n className?: string;\n\n /** Value to use as prefix for ARIA labels on interactive sub-components */\n ariaLabelPrefix?: string;\n};\n\nexport default function HamburgerMenuButton({\n menuProvider,\n normalMenu,\n fullMenu,\n commandHandler,\n containerRef,\n className,\n ariaLabelPrefix,\n children,\n}: HamburgerMenuButtonProps) {\n const [isMenuOpen, setMenuOpen] = useState(false);\n const [showFullMenu, setShowFullMenu] = useState(false);\n\n const handleMenuItemClick = useCallback(() => {\n if (isMenuOpen) setMenuOpen(false);\n setShowFullMenu(false);\n }, [isMenuOpen]);\n\n const handleMenuButtonClick = useCallback((e: MouseEvent) => {\n e.stopPropagation();\n setMenuOpen((prevIsOpen) => {\n const isOpening = !prevIsOpen;\n if (isOpening && e.shiftKey) setShowFullMenu(true);\n else if (!isOpening) setShowFullMenu(false);\n return isOpening;\n });\n }, []);\n\n const menuCommandHandler = useCallback(\n (command: Command) => {\n handleMenuItemClick();\n return commandHandler(command);\n },\n [commandHandler, handleMenuItemClick],\n );\n\n const [offset, setOffset] = useState({ top: 1, left: 1 });\n\n useEffect(() => {\n if (isMenuOpen) {\n const node = containerRef?.current;\n if (node) {\n const rect = node.getBoundingClientRect();\n const scrollTop = window.scrollY;\n const scrollLeft = window.scrollX;\n const top = rect.top + scrollTop + node.clientHeight;\n const left = rect.left + scrollLeft;\n setOffset({ top, left });\n }\n }\n }, [isMenuOpen, containerRef]);\n\n const [normalMenuData] = usePromise(\n useCallback(async () => {\n return menuProvider?.(false) ?? normalMenu;\n // isMenuOpen needs to be included for the menu contents to reevaluate when reopened\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [menuProvider, normalMenu, isMenuOpen]),\n normalMenu,\n );\n\n const [fullMenuData] = usePromise(\n useCallback(async () => {\n return menuProvider?.(true) ?? fullMenu ?? normalMenuData;\n // isMenuOpen needs to be included for the menu contents to reevaluate when reopened\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [menuProvider, fullMenu, normalMenuData, isMenuOpen]),\n fullMenu ?? normalMenuData,\n );\n\n const menu = showFullMenu && fullMenuData ? fullMenuData : normalMenuData;\n\n return (\n <>\n \n {children ?? }\n \n \n {menu ? (\n \n ) : undefined}\n \n \n );\n}\n","import '@/components/mui/icon-button.component.css';\nimport { IconButton as MuiIconButton } from '@mui/material';\nimport { MouseEventHandler, PropsWithChildren } from 'react';\n\nexport type IconButtonProps = PropsWithChildren<{\n /** Optional unique identifier */\n id?: string;\n /**\n * Required. Used as both the tooltip (aka, title) and the aria-label (used for accessibility,\n * testing, etc.), unless a distinct tooltip is supplied.\n */\n label: string;\n /**\n * Enabled status of button\n *\n * @default false\n */\n isDisabled?: boolean;\n /** Optional tooltip to display if different from the aria-label. */\n tooltip?: string;\n /** If true, no tooltip will be displayed. */\n isTooltipSuppressed?: boolean;\n /**\n * If given, uses a negative margin to counteract the padding on one side (this is often helpful\n * for aligning the left or right side of the icon with content above or below, without ruining\n * the border size and shape).\n *\n * @default false\n */\n adjustMarginToAlignToEdge?: 'end' | 'start' | false;\n /**\n * The size of the component. small is equivalent to the dense button styling.\n *\n * @default false\n */\n size: 'small' | 'medium' | 'large';\n /** Additional css classes to help with unique styling of the button */\n className?: string;\n /** Optional click handler */\n onClick?: MouseEventHandler;\n}>;\n\n/**\n * Iconic button a user can click to do something\n *\n * Thanks to MUI for heavy inspiration and documentation\n * https://mui.com/material-ui/getting-started/overview/\n */\nfunction IconButton({\n id,\n label,\n isDisabled = false,\n tooltip,\n isTooltipSuppressed = false,\n adjustMarginToAlignToEdge = false,\n size = 'medium',\n className,\n onClick,\n children,\n}: IconButtonProps) {\n return (\n \n {children /* the icon to display */}\n \n );\n}\n\nexport default IconButton;\n","import { cn } from '@/utils/shadcn-ui.util';\nimport { LoaderCircle, LucideProps } from 'lucide-react';\nimport { forwardRef } from 'react';\n\nexport type SpinnerProps = LucideProps;\n\nconst Spinner = forwardRef(({ className, ...props }, ref) => {\n return (\n \n );\n});\n\nSpinner.displayName = 'Spinner';\n\nexport default Spinner;\n","import { Input as ShadInput } from '@/components/shadcn-ui/input';\nimport { Label as ShadLabel } from '@/components/shadcn-ui/label';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { ChangeEventHandler, FocusEventHandler } from 'react';\n\nexport type TextFieldProps = {\n /** Optional unique identifier */\n id?: string;\n /**\n * If `true`, the component is disabled.\n *\n * @default false\n */\n isDisabled?: boolean;\n /**\n * If `true`, the label is displayed in an error state.\n *\n * @default false\n */\n hasError?: boolean;\n /**\n * If `true`, the input will take up the full width of its container.\n *\n * @default false\n */\n isFullWidth?: boolean;\n /** Text that gives the user instructions on what contents the TextField expects */\n helperText?: string;\n /** The title of the TextField */\n label?: string;\n /** The short hint displayed in the `input` before the user enters a value. */\n placeholder?: string;\n /**\n * If `true`, the label is displayed as required and the `input` element is required.\n *\n * @default false\n */\n isRequired?: boolean;\n /** Additional css classes to help with unique styling of the text field */\n className?: string;\n /** Starting value for the text field if it is not controlled */\n defaultValue?: string | number;\n /** Value of the text field if controlled */\n value?: string | number;\n /** Triggers when content of textfield is changed */\n onChange?: ChangeEventHandler;\n /** Triggers when textfield gets focus */\n onFocus?: FocusEventHandler;\n /** Triggers when textfield loses focus */\n onBlur?: FocusEventHandler;\n};\n\n/**\n * Text input field\n *\n * Thanks to Shadcn for heavy inspiration and documentation\n * https://ui.shadcn.com/docs/components/input#with-label\n */\nfunction TextField({\n id,\n isDisabled = false,\n hasError = false,\n isFullWidth = false,\n helperText,\n label,\n placeholder,\n isRequired = false,\n className,\n defaultValue,\n value,\n onChange,\n onFocus,\n onBlur,\n}: TextFieldProps) {\n return (\n
    \n {`${label}${isRequired ? '*' : ''}`}\n \n

    {helperText}

    \n
    \n );\n}\n\nexport default TextField;\n","import HamburgerMenuButton, {\n MultiColumnMenuProvider,\n} from '@/components/mui/hamburger-menu-button.component';\nimport { CommandHandler } from '@/components/mui/menu-item.component';\nimport '@/components/mui/toolbar.component.css';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { AppBar, Toolbar as MuiToolbar } from '@mui/material';\nimport { PropsWithChildren, useRef } from 'react';\n\nexport type ToolbarProps = PropsWithChildren<{\n /** The handler to use for menu commands (and eventually toolbar commands). */\n commandHandler: CommandHandler;\n\n /**\n * The optional delegate to use to get the menu data. If not specified, the \"hamburger\" menu will\n * not display.\n */\n menuProvider?: MultiColumnMenuProvider;\n\n /** Optional unique identifier */\n id?: string;\n\n /** Additional css classes to help with unique styling of the toolbar */\n className?: string;\n}>;\n\nexport default function Toolbar({\n menuProvider,\n commandHandler,\n className,\n id,\n children,\n}: ToolbarProps) {\n // This ref will always be defined\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const containerRef = useRef(undefined!);\n\n return (\n
    \n \n \n {menuProvider ? (\n \n ) : undefined}\n {children ?
    {children}
    : undefined}\n \n
    \n
    \n );\n}\n","import React from 'react';\nimport { cva, type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst alertVariants = cva(\n 'tw-relative tw-w-full tw-rounded-lg tw-border tw-p-4 [&>svg~*]:tw-pl-7 [&>svg+div]:tw-translate-y-[-3px] [&>svg]:tw-absolute [&>svg]:tw-left-4 [&>svg]:tw-top-4 [&>svg]:tw-text-foreground',\n {\n variants: {\n variant: {\n default: 'tw-bg-background tw-text-foreground',\n destructive:\n 'tw-border-destructive/50 tw-text-destructive dark:tw-border-destructive [&>svg]:tw-text-destructive',\n },\n },\n defaultVariants: {\n variant: 'default',\n },\n },\n);\n\nconst Alert = React.forwardRef<\n HTMLDivElement,\n React.HTMLAttributes & VariantProps\n>(({ className, variant, ...props }, ref) => (\n
    \n));\nAlert.displayName = 'Alert';\n\nconst AlertTitle = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n {/* added because of https://github.com/jsx-eslint/eslint-plugin-jsx-a11y/blob/main/docs/rules/heading-has-content.md */}\n {props.children}{' '}\n \n ),\n);\nAlertTitle.displayName = 'AlertTitle';\n\nconst AlertDescription = React.forwardRef<\n HTMLParagraphElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n
    \n));\nAlertDescription.displayName = 'AlertDescription';\n\nexport { Alert, AlertTitle, AlertDescription };\n","import { ComponentProps } from 'react';\nimport { toast as sonner, Toaster } from 'sonner';\n\ntype SonnerProps = ComponentProps;\n\nfunction Sonner({ ...props }: SonnerProps) {\n return (\n \n );\n}\n\n// The re-export of the sonner function was added manually\nexport { Sonner, sonner };\n","import React from 'react';\nimport * as SliderPrimitive from '@radix-ui/react-slider';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Slider = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n \n \n \n));\nSlider.displayName = SliderPrimitive.Root.displayName;\n\nexport { Slider };\n","import React from 'react';\nimport * as SwitchPrimitives from '@radix-ui/react-switch';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Switch = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n));\nSwitch.displayName = SwitchPrimitives.Root.displayName;\n\nexport { Switch };\n","import React from 'react';\nimport * as TabsPrimitive from '@radix-ui/react-tabs';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport const Tabs = TabsPrimitive.Root;\n\nexport type TabsListProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport type TabsTriggerProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport type TabsContentProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport const TabsList = React.forwardRef<\n React.ElementRef,\n TabsListProps\n>(({ className, ...props }, ref) => (\n \n));\nTabsList.displayName = TabsPrimitive.List.displayName;\n\nexport const TabsTrigger = React.forwardRef<\n React.ElementRef,\n TabsTriggerProps\n>(({ className, ...props }, ref) => (\n \n));\nTabsTrigger.displayName = TabsPrimitive.Trigger.displayName;\n\nexport const TabsContent = React.forwardRef<\n React.ElementRef,\n TabsContentProps\n>(({ className, ...props }, ref) => (\n \n));\nTabsContent.displayName = TabsPrimitive.Content.displayName;\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Download } from 'lucide-react';\n\ntype InstallButtonProps = {\n /** The installing boolean value determines the state of the button. */\n isInstalling: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n /** Optional text for the button. */\n buttonText?: string;\n} & ButtonProps;\n\n/**\n * The InstallButton component is a button designed for initiating installs. It includes visuals for\n * active installing and idle states.\n *\n * @param isInstalling The installing boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @param buttonText Optional text for the button.\n * @returns A install button.\n */\nexport default function InstallButton({\n isInstalling,\n handleClick,\n buttonText,\n className,\n ...props\n}: InstallButtonProps) {\n return (\n \n {isInstalling ? (\n \n ) : (\n <>\n \n {buttonText}\n \n )}\n \n );\n}\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\n\ntype EnableButtonProps = {\n /** The enabling boolean value determines the state of the button. */\n isEnabling: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n} & ButtonProps;\n\n/**\n * The EnableButton component is a button designed for initiating enabling of downloads. It includes\n * visuals for active enabling and idle states.\n *\n * @param isEnabling The enabling boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @returns A button that can be used to enable.\n */\nexport default function EnableButton({\n isEnabling,\n handleClick,\n className,\n ...props\n}: EnableButtonProps) {\n return (\n \n {isEnabling ? (\n <>\n \n Enabling...\n \n ) : (\n 'Enable'\n )}\n \n );\n}\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\n\ntype DisableButtonProps = {\n /** The disabling boolean value determines the state of the button. */\n isDisabling: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n} & ButtonProps;\n\n/**\n * The DisableButton component is a button designed for initiating disabling of downloads. It\n * includes visuals for active disabling and idle states.\n *\n * @param isDisabling The disabling boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @returns A button that can be used to disable.\n */\nexport default function DisableButton({\n isDisabling,\n handleClick,\n className,\n ...props\n}: DisableButtonProps) {\n return (\n \n {isDisabling ? (\n <>\n \n Disabling...\n \n ) : (\n 'Disable'\n )}\n \n );\n}\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\n\ntype UpdateButtonProps = {\n /** The updating boolean value determines the state of the button. */\n isUpdating: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n} & ButtonProps;\n\n/**\n * The UpdateButton component is a button designed for initiating updates for downloaded extensions.\n * It includes visuals for active updating and idle states.\n *\n * @param isUpdating The updating boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @returns A button that can be used to update.\n */\nexport default function UpdateButton({\n isUpdating,\n handleClick,\n className,\n ...props\n}: UpdateButtonProps) {\n return (\n \n {isUpdating ? (\n <>\n \n Updating...\n \n ) : (\n 'Update'\n )}\n \n );\n}\n","import { cn } from '@/utils/shadcn-ui.util';\nimport Markdown, { MarkdownToJSX } from 'markdown-to-jsx';\nimport { useMemo } from 'react';\n\ninterface MarkdownRendererProps {\n /** Optional unique identifier */\n id?: string;\n /** The markdown string to render */\n markdown: string;\n className?: string;\n /**\n * The [`target` attribute for `a` html\n * tags](https://developer.mozilla.org/en-US/docs/Web/HTML/Element/a#target). Defaults to not\n * adding a `target` to `a` tags\n */\n anchorTarget?: string;\n}\n\n/**\n * This component renders markdown content given a markdown string. It uses typography styles from\n * the platform.\n *\n * @param markdown The markdown string to render.\n * @param id Optional unique identifier\n * @returns A div containing the rendered markdown content.\n */\nexport default function MarkdownRenderer({\n id,\n markdown,\n className,\n anchorTarget,\n}: MarkdownRendererProps) {\n const options: MarkdownToJSX.Options = useMemo(\n () => ({\n overrides: {\n a: {\n props: {\n target: anchorTarget,\n },\n },\n },\n }),\n [anchorTarget],\n );\n return (\n
    \n {markdown}\n
    \n );\n}\n","import { Filter, ChevronDown } from 'lucide-react';\nimport { forwardRef } from 'react';\nimport { Button } from '@/components/shadcn-ui/button';\n\n/**\n * The FilterButton component is a button designed for initiating filtering of data. It is designed\n * to be used with the dropdown menu. It uses forwardRef to pass the button to the dropdown trigger\n * asChild.\n *\n * @returns A button that can be used to filter.\n */\nconst FilterButton = forwardRef((props, ref) => {\n return (\n \n \n Filter\n \n \n );\n});\n\nexport default FilterButton;\n","import {\n DropdownMenu,\n DropdownMenuTrigger,\n DropdownMenuContent,\n DropdownMenuLabel,\n DropdownMenuGroup,\n DropdownMenuCheckboxItem,\n DropdownMenuRadioItem,\n DropdownMenuSeparator,\n} from '@/components/shadcn-ui/dropdown-menu';\nimport FilterButton from './buttons/filter-button.component';\n\nexport enum DropdownMenuItemType {\n Check,\n Radio,\n}\n\nexport type DropdownItem = {\n /** The label is the text that will be displayed on the dropdown item. */\n label: string;\n /** The itemType determines the DropdownMenuItemType type as either Check or Radio. */\n itemType: DropdownMenuItemType;\n /** The onClick function is called when the item is clicked. */\n onClick: () => void;\n};\n\nexport type DropdownGroup = {\n /**\n * The label is the text that will be displayed on the dropdown group. It is used to categorize\n * the items in the group.\n */\n label: string;\n /** The items array contains the items that will be displayed in the dropdown group */\n items: DropdownItem[];\n};\n\nexport type FilterDropdownProps = {\n /** Object unique identifier */\n id?: string;\n /** The groups array contains the groups that will be displayed in the dropdown */\n groups: DropdownGroup[];\n}; // TODO: extend the props later\n\n/**\n * The FilterDropdown component is a dropdown designed for filtering content. It includes groups of\n * items that can be checkboxes or radio items.\n *\n * @param id Optional unique identifier\n * @param groups The groups array contains the groups that will be displayed in the dropdown\n * @returns A filter dropdown.\n */\nexport default function FilterDropdown({ id, groups }: FilterDropdownProps) {\n return (\n
    \n {/* TODO: remove this once the DropDown Menu shadcn has an id prop */}\n \n \n \n \n \n {groups.map((group) => (\n
    \n {group.label}\n \n {group.items.map((item) => (\n
    \n {item.itemType === DropdownMenuItemType.Check ? (\n \n {item.label}\n \n ) : (\n \n {item.label}\n \n )}\n
    \n ))}\n
    \n \n
    \n ))}\n
    \n
    \n
    \n );\n}\n","interface NoExtensionsFoundProps {\n /** Optional unique identifier */\n id?: string;\n /** The message to display */\n message: string;\n}\n/**\n * This component displays a message to the user when no extensions are found in the marketplace.\n *\n * @param id Optional unique identifier\n * @param message The message to display.\n * @returns {JSX.Element} - Returns the message component that displays the message to the user.\n */\nexport default function NoExtensionsFound({ id, message }: NoExtensionsFoundProps) {\n return (\n
    \n
    \n

    {message}

    \n
    \n
    \n );\n}\n","import { CircleHelp, Link as LucideLink, User } from 'lucide-react';\nimport { NumberFormat } from 'platform-bible-utils';\n\n/** Interface that stores the parameters passed to the More Info component */\ninterface MoreInfoProps {\n /** Optional unique identifier */\n id?: string;\n /** The category of the extension */\n category: string;\n /** The number of downloads for the extension */\n downloads: Record;\n /** The languages supported by the extension */\n languages: string[];\n /** The URL to the more info page of the extension */\n moreInfoUrl: string;\n}\n/**\n * This component displays the more info section of the extension which includes the category,\n * number of downloads, languages, and links to the website and support\n *\n * @param id Optional unique identifier\n * @param category The category of the extension\n * @param downloads The number of downloads for the extension\n * @param languages The languages supported by the extension\n * @param moreInfoUrl The URL to the more info page of the extension\n * @returns {JSX.Element} - Returns the more info component that displays the category, number of\n * downloads, languages, and links to the website and support\n */\nexport default function MoreInfo({\n id,\n category,\n downloads,\n languages,\n moreInfoUrl,\n}: MoreInfoProps) {\n /**\n * This constant formats the number of downloads into a more readable format.\n *\n * @example 1000 -> 1K\n *\n * @example 1000000 -> 1M\n *\n * @returns The formatted number of downloads\n */\n const numberFormatted = new NumberFormat('en', {\n notation: 'compact',\n compactDisplay: 'short',\n }).format(Object.values(downloads).reduce((a: number, b: number) => a + b, 0));\n\n /** This function scrolls the window to the bottom of the page. */\n const handleScrollToBottom = () => {\n window.scrollTo(0, document.body.scrollHeight);\n };\n\n return (\n \n
    \n
    \n {category}\n
    \n CATEGORY\n
    \n
    \n
    \n
    \n \n {numberFormatted}\n
    \n USERS\n
    \n
    \n
    \n
    \n {languages.slice(0, 3).map((locale) => (\n \n {locale.toUpperCase()}\n \n ))}\n
    \n {languages.length > 3 && (\n handleScrollToBottom()}\n className=\"tw-text-xs tw-text-gray-500 tw-underline\"\n >\n +{languages.length - 3} more languages\n \n )}\n
    \n
    \n
    \n \n Website\n \n \n \n Support\n \n \n
    \n
    \n );\n}\n","import { useState } from 'react';\n\nexport type VersionInformation = {\n /** Date the version was published */\n date: string;\n /** Description of the changes in the version */\n description: string;\n};\n\n/** Type to store the version history information */\nexport type VersionHistoryType = Record;\n\n/** Interface that stores the parameters passed to the Version History component */\ninterface VersionHistoryProps {\n /** Optional unique identifier */\n id?: string;\n /** Object containing the versions mapped with their information */\n versionHistory: VersionHistoryType;\n}\n\n/**\n * Component to render the version history information shown in the footer component. Lists the 5\n * most recent versions, with the options to show all versions by pressing a button.\n *\n * @param versionHistory Object containing the versions mapped with their information\n * @param id Optional unique identifier\n * @returns Rendered version history for the Footer component\n */\nexport default function VersionHistory({ id, versionHistory }: VersionHistoryProps) {\n const [showAllVersions, setShowAllVersions] = useState(false);\n const currentDate = new Date();\n\n /**\n * Function to format the time string for the version history in the form of 'X year(s) ago'.\n *\n * @param dateString ISO Date string to determine the time string from\n * @returns Formatted time string\n */\n function formatTimeString(dateString: string) {\n const date = new Date(dateString);\n const dateDiff = new Date(currentDate.getTime() - date.getTime());\n const yearDiff = dateDiff.getUTCFullYear() - 1970;\n const monthDiff = dateDiff.getUTCMonth();\n const dayDiff = dateDiff.getUTCDate() - 1;\n\n // Determines how long ago the version was published\n let timeString = '';\n if (yearDiff > 0) {\n timeString = `${yearDiff.toString()} year${yearDiff === 1 ? '' : 's'} ago`;\n } else if (monthDiff > 0) {\n timeString = `${monthDiff.toString()} month${monthDiff === 1 ? '' : 's'} ago`;\n } else if (dayDiff === 0) {\n timeString = 'today';\n } else {\n timeString = `${dayDiff.toString()} day${dayDiff === 1 ? '' : 's'} ago`;\n }\n\n return timeString;\n }\n\n // Sorts the version history by version number\n const sortedEntries = Object.entries(versionHistory).sort((a, b) => b[0].localeCompare(a[0]));\n\n return (\n
    \n

    What`s New

    \n
      \n {(showAllVersions ? sortedEntries : sortedEntries.slice(0, 5)).map((entry) => (\n
      \n
      \n
    • \n {entry[1].description}\n
    • \n
      \n
      \n
      Version {entry[0]}
      \n
      {formatTimeString(entry[1].date)}
      \n
      \n
      \n ))}\n
    \n {sortedEntries.length > 5 && (\n setShowAllVersions(!showAllVersions)}\n className=\"tw-text-xs tw-text-gray-500 tw-underline\"\n >\n {showAllVersions ? 'Show Less Version History' : 'Show All Version History'}\n \n )}\n
    \n );\n}\n","import { useMemo } from 'react';\nimport { formatBytes } from 'platform-bible-utils';\nimport VersionHistory, { VersionHistoryType } from './version-history.component';\n\n/** Interface to store the parameters passed to the Footer component */\ninterface FooterProps {\n /** Optional unique identifier */\n id?: string;\n /** Name of the publisher */\n publisherDisplayName: string;\n /** Size of the extension file in bytes */\n fileSize: number;\n /** List of language codes supported by the extension */\n locales: string[];\n /** Object containing the version history mapped with their information */\n versionHistory: VersionHistoryType;\n}\n\n/**\n * Component to render the footer for the extension details which contains information on the\n * publisher, version history, languages, and file size.\n *\n * @param id Optional unique identifier\n * @param publisherDisplayName Name of the publisher\n * @param fileSize Size of the extension file in bytes\n * @param locales List of language codes supported by the extension\n * @param versionHistory Object containing the version history mapped with their information\n * @returns The rendered Footer component\n */\nexport default function Footer({\n id,\n publisherDisplayName,\n fileSize,\n locales,\n versionHistory,\n}: FooterProps) {\n /** Formats the file size into a human-readable format */\n const formattedFileSize = useMemo(() => formatBytes(fileSize), [fileSize]);\n\n /**\n * This function gets the display names of the languages based on the language codes.\n *\n * @param codes The list of language codes\n * @returns The list of language names\n */\n const getLanguageNames = (codes: string[]) => {\n const displayNames = new Intl.DisplayNames(navigator.language, { type: 'language' });\n return codes.map((code) => displayNames.of(code));\n };\n\n const languageNames = getLanguageNames(locales);\n\n return (\n
    \n
    \n \n
    \n
    \n

    Information

    \n
    \n

    \n Publisher\n {publisherDisplayName}\n Size\n {formattedFileSize}\n

    \n
    \n

    \n Languages\n {languageNames.join(', ')}\n

    \n
    \n
    \n
    \n
    \n
    \n );\n}\n","import { PlatformEvent, PlatformEventHandler } from 'platform-bible-utils';\nimport { useEffect } from 'react';\n\n/**\n * Adds an event handler to an event so the event handler runs when the event is emitted. Use\n * `papi.network.getNetworkEvent` to use a networked event with this hook.\n *\n * @param event The event to subscribe to.\n *\n * - If event is a `PlatformEvent`, that event will be used\n * - If event is undefined, the callback will not be subscribed. Useful if the event is not yet\n * available for example\n *\n * @param eventHandler The callback to run when the event is emitted\n *\n * WARNING: MUST BE STABLE - const or wrapped in useCallback. The reference must not be updated\n * every render\n */\nconst useEvent = (\n event: PlatformEvent | undefined,\n eventHandler: PlatformEventHandler,\n) => {\n useEffect(() => {\n // Do nothing if the event is not provided (in case the event is not yet available, for example)\n if (!event) return () => {};\n\n const unsubscriber = event(eventHandler);\n return () => {\n unsubscriber();\n };\n }, [event, eventHandler]);\n};\nexport default useEvent;\n","import { useCallback, useEffect } from 'react';\nimport { PlatformEvent, PlatformEventAsync, PlatformEventHandler } from 'platform-bible-utils';\nimport usePromise from './use-promise.hook';\n\nconst noopUnsubscriber = () => false;\n\n/**\n * Adds an event handler to an asynchronously subscribing/unsubscribing event so the event handler\n * runs when the event is emitted. Use `papi.network.getNetworkEvent` to use a networked event with\n * this hook.\n *\n * @param event The asynchronously (un)subscribing event to subscribe to.\n *\n * - If event is a `PlatformEvent` or `PlatformEventAsync`, that event will be used\n * - If event is undefined, the callback will not be subscribed. Useful if the event is not yet\n * available for example\n *\n * @param eventHandler The callback to run when the event is emitted\n *\n * WARNING: MUST BE STABLE - const or wrapped in useCallback. The reference must not be updated\n * every render\n */\nconst useEventAsync = (\n event: PlatformEvent | PlatformEventAsync | undefined,\n eventHandler: PlatformEventHandler,\n) => {\n // Subscribe to the event asynchronously\n const [unsubscribe] = usePromise(\n useCallback(async () => {\n // Do nothing if the event is not provided (in case the event is not yet available, for example)\n if (!event) return noopUnsubscriber;\n\n // Wrap subscribe and unsubscribe in promises to allow normal events to be used as well\n const unsub = await Promise.resolve(event(eventHandler));\n return async () => unsub();\n }, [eventHandler, event]),\n noopUnsubscriber,\n // We want the unsubscriber to return to default value immediately upon changing subscription\n // So the useEffect below will unsubscribe asap\n { preserveValue: false },\n );\n\n // Unsubscribe from the event asynchronously (but we aren't awaiting the unsub)\n useEffect(() => {\n return () => {\n if (unsubscribe !== noopUnsubscriber) {\n unsubscribe();\n }\n };\n }, [unsubscribe]);\n};\n\nexport default useEventAsync;\n"],"names":["twMergeCustom","extendTailwindMerge","cn","inputs","clsx","Input","React","className","type","props","ref","jsx","BookChapterInput","forwardRef","handleSearch","handleKeyDown","handleOnClick","handleSubmit","jsxs","ShadInput","event","e","History","P","R","s","n","N","B","O","S","K","g","k","x","T","X","V","w","L","G","A","H","C","I","y","q","U","m","l","h","c","E","D","i","a","o","u","v","f","d","b","J","DropdownMenu","DropdownMenuPrimitive","DropdownMenuTrigger","DropdownMenuGroup","DropdownMenuPortal","DropdownMenuSub","DropdownMenuRadioGroup","DropdownMenuSubTrigger","inset","children","ChevronRight","DropdownMenuSubContent","DropdownMenuContent","sideOffset","DropdownMenuItem","DropdownMenuCheckboxItem","checked","Check","DropdownMenuRadioItem","Circle","DropdownMenuLabel","DropdownMenuSeparator","DropdownMenuShortcut","BookMenuItem","bookId","handleSelectBook","isSelected","handleHighlightBook","bookType","ShadDropdownMenuItem","Canon","ChapterSelect","handleSelectChapter","endChapter","activeChapter","highlightedChapter","handleHighlightedChapter","chapters","_","handleMouse","useCallback","chapterNumber","chapter","GoToMenuItem","handleSort","handleLocationHistory","handleBookmarks","ShadDropdownMenuLabel","ArrowDownWideNarrow","Clock","Bookmark","ALL_BOOK_IDS","BOOK_TYPE_LABELS","BOOK_TYPE_ARRAY","SCROLL_OFFSET","SEARCH_QUERY_FORMATS","fetchGroupedBooks","fetchEndChapter","getChaptersForBook","getAllEnglishNames","isValidBookEnglishName","bookName","getBookIdFromEnglishName","formattedBookName","BookChapterControl","scrRef","searchQuery","setSearchQuery","useState","selectedBookId","setSelectedBookId","setHighlightedChapter","highlightedBookId","setHighlightedBookId","isContentOpen","setIsContentOpen","isContentOpenDelayed","setIsContentOpenDelayed","inputRef","useRef","contentRef","menuItemRef","fetchFilteredBooks","englishNameLowerCase","normalizedQuery","handleSearchInput","searchString","shouldPreventAutoClosing","controlMenuState","open","updateReference","shouldClose","verse","handleInputSubmit","format","matches","book","englishName","handleKeyDownInput","handleKeyDownContent","key","handleKeyDownMenuItem","chapterOffSet","useEffect","useLayoutEffect","scrollTimeout","scrollPosition","ShadDropdownMenu","ShadDropdownMenuTrigger","ShadDropdownMenuContent","bookTypeIndex","element","ShadDropdownMenuSeparator","buttonVariants","cva","Button","variant","size","asChild","Slot","labelVariants","Label","LabelPrimitive","RadioGroup","RadioGroupPrimitive","RadioGroupItem","Popover","PopoverPrimitive","PopoverTrigger","PopoverContent","align","DialogPortal","DialogPrimitive","DialogOverlay","DialogContent","DialogTitle","DialogDescription","Command","CommandPrimitive","CommandInput","Search","CommandList","CommandEmpty","CommandGroup","CommandSeparator","CommandItem","getOptionLabelDefault","option","ComboBox","id","options","value","onChange","getOptionLabel","buttonPlaceholder","textPlaceholder","commandEmptyMessage","buttonVariant","dir","isDisabled","setOpen","ChevronsUpDown","ChapterRangeSelector","startChapter","handleSelectStartChapter","handleSelectEndChapter","chapterCount","chapterOptions","useMemo","index","Fragment","BookSelectionMode","BOOK_SELECTOR_STRING_KEYS","localizeString","strings","BookSelector","handleBookSelectionModeChange","currentBookName","onSelectBooks","selectedBookIds","localizedStrings","currentBookText","chooseText","chooseBooksText","bookSelectionMode","setBookSelectionMode","onSelectionModeChange","newMode","DataTableViewOptions","table","FilterIcon","column","Select","SelectPrimitive","SelectGroup","SelectValue","SelectTrigger","ChevronDown","SelectScrollUpButton","ChevronUp","SelectScrollDownButton","SelectContent","position","SelectLabel","SelectItem","SelectSeparator","DataTablePagination","pageSize","ArrowLeftIcon","ChevronLeftIcon","ChevronRightIcon","ArrowRightIcon","Table","stickyHeader","TableHeader","TableBody","TableFooter","TableRow","TableHead","TableCell","TableCaption","DataTable","columns","data","enablePagination","showPaginationControls","showColumnVisibilityControls","onRowClickHandler","sorting","setSorting","columnFilters","setColumnFilters","columnVisibility","setColumnVisibility","rowSelection","setRowSelection","useReactTable","getCoreRowModel","getPaginationRowModel","getSortedRowModel","getFilteredRowModel","headerGroup","header","flexRender","_a","row","cell","OccurrencesTable","occurrenceData","setScriptureReference","referenceHeaderText","occurrenceHeaderText","occurrences","uniqueOccurrences","occurrence","uniqueOccurrence","deepEqual","Checkbox","CheckboxPrimitive","getLinesFromUSFM","text","getNumberFromUSFM","regex","match","getBookNumFromId","getStatusForItem","item","approvedItems","unapprovedItems","toggleVariants","Toggle","TogglePrimitive","ToggleGroupContext","ToggleGroup","ToggleGroupPrimitive","ToggleGroupItem","context","getSortingIcon","sortDirection","ArrowUpIcon","ArrowDownIcon","ArrowUpDownIcon","inventoryItemColumn","itemLabel","inventoryAdditionalItemColumn","additionalItemLabel","additionalItemIndex","inventoryCountColumn","countLabel","statusChangeHandler","changedItems","newStatus","onApprovedItemsChange","onUnapprovedItemsChange","newApprovedItems","validItem","newUnapprovedItems","unapprovedItem","inventoryStatusColumn","statusLabel","status","CircleCheckIcon","CircleXIcon","CircleHelpIcon","INVENTORY_STRING_KEYS","filterItemData","itemData","statusFilter","textFilter","filteredItemData","createTableData","scriptureRef","itemRegex","tableData","currentBook","currentChapter","currentVerse","line","items","itemIndex","existingItem","tableEntry","newReference","substring","newItem","Inventory","scriptureReference","extractItems","additionalItemsLabels","scope","onScopeChange","allItemsText","approvedItemsText","unapprovedItemsText","unknownItemsText","scopeBookText","scopeChapterText","scopeVerseText","filterText","showAdditionalItemsText","showAdditionalItems","setShowAdditionalItems","setStatusFilter","setTextFilter","selectedItem","setSelectedItem","reducedTableData","newTableData","firstItem","existingEntry","newTableEntry","filteredTableData","allColumns","numberOfAdditionalItems","additionalColumns","_b","rowClickHandler","newSelection","handleScopeChange","handleStatusFilterChange","SearchBar","onSearch","placeholder","isFullWidth","handleInputChange","VerticalTabs","TabsPrimitive","VerticalTabsList","VerticalTabsTrigger","VerticalTabsContent","TabNavigationContentSearch","tabList","searchPlaceholder","headerTitle","isSearchBarFullWidth","direction","tab","Separator","orientation","decorative","SeparatorPrimitive","Sheet","SheetPrimitive","SheetPortal","SheetOverlay","sheetVariants","SheetContent","side","SheetTitle","SheetDescription","Skeleton","TooltipProvider","TooltipPrimitive","Tooltip","TooltipTrigger","TooltipContent","MOBILE_BREAKPOINT","useIsMobile","isMobile","setIsMobile","mql","SIDEBAR_COOKIE_NAME","SIDEBAR_COOKIE_MAX_AGE","SIDEBAR_WIDTH","SIDEBAR_WIDTH_MOBILE","SIDEBAR_WIDTH_ICON","SIDEBAR_KEYBOARD_SHORTCUT","SidebarContext","useSidebar","SidebarProvider","defaultOpen","openProp","setOpenProp","style","openMobile","setOpenMobile","_open","_setOpen","isOpen","openState","toggleSidebar","state","contextValue","Sidebar","collapsible","SidebarTrigger","onClick","PanelLeft","SidebarRail","SidebarInset","SidebarInput","SidebarHeader","SidebarFooter","SidebarSeparator","SidebarContent","SidebarGroup","SidebarGroupLabel","SidebarGroupAction","SidebarGroupContent","SidebarMenu","SidebarMenuItem","sidebarMenuButtonVariants","SidebarMenuButton","isActive","tooltip","Comp","button","SidebarMenuAction","showOnHover","SidebarMenuBadge","SidebarMenuSkeleton","showIcon","width","SidebarMenuSub","SidebarMenuSubItem","SidebarMenuSubButton","SettingsSidebar","extensionLabels","handleSelectSidebarItem","handleSelectItem","isProjectSetting","label","SettingsSidebarContentSearch","scrBookColId","scrRefColId","typeColId","detailsColId","defaultScrRefColumnName","defaultScrBookGroupName","defaultTypeColumnName","defaultDetailsColumnName","getColumns","colInfo","showSourceColumn","showSrcCol","info","formatScrRef","compareScrRefs","toRefOrRange","scriptureSelection","offsetStart","offsetEnd","scrRefToBBBCCCVVV","getRowKey","ScriptureResultsViewer","sources","showColumnHeaders","scriptureReferenceColumnName","scriptureBookGroupName","typeColumnName","detailsColumnName","onRowSelected","grouping","setGrouping","scriptureResults","source","getExpandedRowModel","getGroupedRowModel","selectedRows","keys","selectedRow","scrBookGroupName","typeGroupName","groupingOptions","handleSelectChange","selectedGrouping","handleRowClick","getEvenOrOddBandingStyle","getIndent","groupingState","rowIndex","ChevronLeft","DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS","getLocalizeKeyForScrollGroupId","ScrollGroupSelector","availableScrollGroupIds","scrollGroupId","onChangeScrollGroupId","localizedStringsDefaulted","localizedStringKey","localizedStringValue","newScrollGroupString","scrollGroupOptionId","SettingsList","SettingsListItem","primary","secondary","isLoading","loadingMessage","SettingsListHeader","includeSeparator","Card","CardHeader","CardTitle","CardDescription","CardContent","CardFooter","SettingsCard","settingsGroupLabel","settingsGroupDescription","Checklist","listItems","selectedListItems","handleSelectListItem","createLabel","_interopRequireDefault","obj","module","chainPropTypes","propType1","propType2","args","_extends","target","isPlainObject","prototype","deepClone","output","deepmerge","p","r","t","z","reactIs_production_min","hasSymbol","REACT_ELEMENT_TYPE","REACT_PORTAL_TYPE","REACT_FRAGMENT_TYPE","REACT_STRICT_MODE_TYPE","REACT_PROFILER_TYPE","REACT_PROVIDER_TYPE","REACT_CONTEXT_TYPE","REACT_ASYNC_MODE_TYPE","REACT_CONCURRENT_MODE_TYPE","REACT_FORWARD_REF_TYPE","REACT_SUSPENSE_TYPE","REACT_SUSPENSE_LIST_TYPE","REACT_MEMO_TYPE","REACT_LAZY_TYPE","REACT_BLOCK_TYPE","REACT_FUNDAMENTAL_TYPE","REACT_RESPONDER_TYPE","REACT_SCOPE_TYPE","isValidElementType","typeOf","object","$$typeof","$$typeofType","AsyncMode","ConcurrentMode","ContextConsumer","ContextProvider","Element","ForwardRef","Lazy","Memo","Portal","Profiler","StrictMode","Suspense","hasWarnedAboutDeprecatedIsAsyncMode","isAsyncMode","isConcurrentMode","isContextConsumer","isContextProvider","isElement","isForwardRef","isFragment","isLazy","isMemo","isPortal","isProfiler","isStrictMode","isSuspense","reactIs_development","reactIsModule","require$$0","require$$1","getOwnPropertySymbols","hasOwnProperty","propIsEnumerable","toObject","val","shouldUseNative","test1","test2","order2","test3","letter","objectAssign","from","to","symbols","ReactPropTypesSecret","ReactPropTypesSecret_1","has","printWarning","loggedTypeFailures","message","checkPropTypes","typeSpecs","values","location","componentName","getStack","typeSpecName","error","err","ex","stack","checkPropTypes_1","ReactIs","assign","require$$2","require$$3","require$$4","emptyFunctionThatReturnsNull","factoryWithTypeCheckers","isValidElement","throwOnDirectAccess","ITERATOR_SYMBOL","FAUX_ITERATOR_SYMBOL","getIteratorFn","maybeIterable","iteratorFn","ANONYMOUS","ReactPropTypes","createPrimitiveTypeChecker","createAnyTypeChecker","createArrayOfTypeChecker","createElementTypeChecker","createElementTypeTypeChecker","createInstanceTypeChecker","createNodeChecker","createObjectOfTypeChecker","createEnumTypeChecker","createUnionTypeChecker","createShapeTypeChecker","createStrictShapeTypeChecker","is","PropTypeError","createChainableTypeChecker","validate","manualPropTypeCallCache","manualPropTypeWarningCount","checkType","isRequired","propName","propFullName","secret","cacheKey","chainedCheckType","expectedType","propValue","propType","getPropType","preciseType","getPreciseType","typeChecker","expectedClass","expectedClassName","actualClassName","getClassName","expectedValues","valuesString","arrayOfTypeCheckers","checker","getPostfixForTypeWarning","expectedTypes","checkerResult","expectedTypesMessage","isNode","invalidValidatorError","shapeTypes","allKeys","iterator","step","entry","isSymbol","emptyFunction","emptyFunctionWithReset","factoryWithThrowingShims","shim","getShim","propTypesModule","isClassComponent","elementType","acceptingRef","safePropName","warningHint","elementAcceptingRef","PropTypes","elementAcceptingRef$1","specialProperty","exactProp","propTypes","unsupportedProps","prop","formatMuiErrorMessage","code","url","REACT_SERVER_CONTEXT_TYPE","REACT_OFFSCREEN_TYPE","enableScopeAPI","enableCacheElement","enableTransitionTracing","enableLegacyHidden","enableDebugTracing","REACT_MODULE_REFERENCE","SuspenseList","hasWarnedAboutDeprecatedIsConcurrentMode","isSuspenseList","fnNameMatchRegex","getFunctionName","fn","getFunctionComponentName","Component","fallback","getWrappedName","outerType","innerType","wrapperName","functionName","getDisplayName","HTMLElementType","refType","refType$1","capitalize","string","_formatMuiErrorMessage","createChainedFunction","funcs","acc","func","debounce","wait","timeout","debounced","later","deprecatedPropType","validator","reason","componentNameSafe","propFullNameSafe","isMuiElement","muiNames","_muiName","_element$type","ownerDocument","node","ownerWindow","requirePropFactory","componentNameInError","prevPropTypes","requiredProp","defaultTypeChecker","typeCheckerResult","setRef","useEnhancedEffect","useEnhancedEffect$1","globalId","useGlobalId","idOverride","defaultId","setDefaultId","maybeReactUseId","useId","reactId","unsupportedProp","useControlled","controlled","defaultProp","name","isControlled","valueState","setValue","defaultValue","setValueIfUncontrolled","newValue","useEventCallback","useForkRef","refs","instance","UNINITIALIZED","useLazyRef","init","initArg","EMPTY","useOnMount","Timeout","delay","useTimeout","hadKeyboardEvent","hadFocusVisibleRecently","hadFocusVisibleRecentlyTimeout","inputTypesWhitelist","focusTriggersKeyboardModality","tagName","handlePointerDown","handleVisibilityChange","prepare","doc","isFocusVisible","useIsFocusVisible","isFocusVisibleRef","handleBlurVisible","handleFocusVisible","resolveProps","defaultProps","defaultSlotProps","slotProps","slotPropName","composeClasses","slots","getUtilityClass","classes","slot","utilityClass","defaultGenerator","createClassNameGenerator","generate","generator","ClassNameGenerator","ClassNameGenerator$1","globalStateClasses","generateUtilityClass","globalStatePrefix","globalStateClass","generateUtilityClasses","result","clamp","min","max","_objectWithoutPropertiesLoose","excluded","sourceKeys","_excluded","sortBreakpointsValues","breakpointsAsArray","breakpoint1","breakpoint2","createBreakpoints","breakpoints","unit","other","sortedValues","up","down","between","start","end","endIndex","only","not","keyIndex","shape","shape$1","responsivePropType","responsivePropType$1","merge","defaultBreakpoints","handleBreakpoints","styleFromPropValue","theme","themeBreakpoints","breakpoint","mediaKey","cssKey","createEmptyBreakpointObject","breakpointsInput","_breakpointsInput$key","breakpointStyleKey","removeUnusedBreakpoints","breakpointKeys","breakpointOutput","getPath","path","checkVars","getStyleValue","themeMapping","transform","propValueFinal","userValue","cssProperty","themeKey","memoize","cache","arg","properties","directions","aliases","getCssProperties","property","marginKeys","paddingKeys","spacingKeys","createUnaryUnit","_getPath","themeSpacing","abs","createUnarySpacing","getValue","transformer","transformed","getStyleFromPropValue","cssProperties","resolveCssProperty","margin","padding","createSpacing","spacingInput","spacing","argsInput","argument","compose","styles","handlers","borderTransform","createBorderStyle","border","borderTop","borderRight","borderBottom","borderLeft","borderColor","borderTopColor","borderRightColor","borderBottomColor","borderLeftColor","outline","outlineColor","borderRadius","gap","columnGap","rowGap","gridColumn","gridRow","gridAutoFlow","gridAutoColumns","gridAutoRows","gridTemplateColumns","gridTemplateRows","gridTemplateAreas","gridArea","paletteTransform","color","bgcolor","backgroundColor","sizingTransform","maxWidth","_props$theme","_props$theme2","breakpointsValues","minWidth","height","maxHeight","minHeight","boxSizing","defaultSxConfig","defaultSxConfig$1","objectsHaveSameKeys","objects","union","callIfFn","maybeFn","unstable_createStyleFunctionSx","getThemeValue","config","styleFunctionSx","_theme$unstable_sxCon","sx","traverse","sxInput","sxObject","emptyBreakpoints","breakpointsKeys","css","styleKey","styleFunctionSx$1","applyStyles","createTheme","paletteInput","shapeInput","muiTheme","isObjectEmpty","useTheme","defaultTheme","contextTheme","ThemeContext","systemDefaultTheme","useThemeWithoutDefault","_excluded2","_excluded3","isEmpty","isStringTag","tag","shouldForwardProp","lowercaseFirstLetter","resolveTheme","themeId","defaultOverridesResolver","processStyleArg","callableStyle","_ref","ownerState","resolvedStylesArg","resolvedStyle","variants","isMatch","createStyled","input","rootShouldForwardProp","slotShouldForwardProp","systemSx","inputOptions","processStyles","componentSlot","inputSkipVariantsResolver","inputSkipSx","overridesResolver","skipVariantsResolver","skipSx","shouldForwardPropOption","defaultStyledResolver","styledEngineStyled","transformStyleArg","stylesArg","muiStyledResolver","styleArg","expressions","transformedStyleArg","expressionsWithDefaultTheme","styleOverrides","resolvedStyleOverrides","slotKey","slotStyle","_theme$components","themeVariants","numOfCustomFnsApplied","placeholders","displayName","getThemeProps","params","useThemeProps","clampWrapper","hexToRgb","re","colors","decomposeColor","marker","colorSpace","recomposeColor","hslToRgb","rgb","getLuminance","getContrastRatio","foreground","background","lumA","lumB","alpha","darken","coefficient","lighten","createMixins","mixins","common","common$1","grey","grey$1","purple","purple$1","red","red$1","orange","orange$1","blue","blue$1","lightBlue","lightBlue$1","green","green$1","light","dark","addLightOrDark","intent","shade","tonalOffset","tonalOffsetLight","tonalOffsetDark","getDefaultPrimary","mode","getDefaultSecondary","getDefaultError","getDefaultInfo","getDefaultSuccess","getDefaultWarning","createPalette","palette","contrastThreshold","success","warning","getContrastText","contrastText","contrast","augmentColor","mainShade","lightShade","darkShade","modes","round","caseAllCaps","defaultFontFamily","createTypography","typography","fontFamily","fontSize","fontWeightLight","fontWeightRegular","fontWeightMedium","fontWeightBold","htmlFontSize","allVariants","pxToRem2","coef","pxToRem","buildVariant","fontWeight","lineHeight","letterSpacing","casing","shadowKeyUmbraOpacity","shadowKeyPenumbraOpacity","shadowAmbientShadowOpacity","createShadow","px","shadows","shadows$1","easing","duration","formatMs","milliseconds","getAutoHeightDuration","constant","createTransitions","inputTransitions","mergedEasing","mergedDuration","durationOption","easingOption","isString","isNumber","animatedProp","zIndex","zIndex$1","mixinsInput","transitionsInput","typographyInput","systemTheme","systemCreateTheme","stateClasses","component","child","stateClass","defaultTheme$1","THEME_ID","systemUseThemeProps","styled","styled$1","getSvgIconUtilityClass","useUtilityClasses","SvgIconRoot","_theme$transitions","_theme$transitions$cr","_theme$transitions2","_theme$typography","_theme$typography$pxT","_theme$typography2","_theme$typography2$px","_theme$typography3","_theme$typography3$px","_palette$ownerState$c","_palette","_palette2","_palette3","SvgIcon","inProps","htmlColor","inheritViewBox","titleAccess","viewBox","hasSvgAsChild","more","_jsxs","_jsx","SvgIcon$1","createSvgIcon","unstable_ClassNameGenerator","exports","_utils","ArrowRight","default_1","_createSvgIcon","_jsxRuntime","isHostComponent","appendOwnerState","otherProps","defaultContextValue","ClassNameConfiguratorContext","useClassNamesOverride","disableDefaultClasses","extractEventHandlers","excludeKeys","resolveComponentProps","componentProps","slotState","omitEventHandlers","mergeSlotProps","parameters","getSlotProps","additionalProps","externalSlotProps","externalForwardedProps","joinedClasses","mergedStyle","eventHandlers","componentsPropsWithoutEventHandlers","otherPropsWithoutEventHandlers","internalSlotProps","useSlotProps","_parameters$additiona","skipResolvingSlotProps","rest","resolvedComponentsProps","mergedProps","internalRef","GLOBAL_CLASS_PREFIX","buildStateClass","buildSlotClass","getContainer","container","forwardedRef","disablePortal","mountNode","setMountNode","handleRef","newProps","ReactDOM","top","bottom","right","left","auto","basePlacements","clippingParents","viewport","popper","reference","variationPlacements","placement","placements","beforeRead","read","afterRead","beforeMain","main","afterMain","beforeWrite","write","afterWrite","modifierPhases","getNodeName","getWindow","OwnElement","isHTMLElement","isShadowRoot","attributes","effect","_ref2","initialStyles","styleProperties","attribute","applyStyles$1","getBasePlacement","getUAString","uaData","isLayoutViewport","getBoundingClientRect","includeScale","isFixedStrategy","clientRect","scaleX","scaleY","visualViewport","addVisualOffsets","getLayoutRect","contains","parent","rootNode","next","getComputedStyle","isTableElement","getDocumentElement","getParentNode","getTrueOffsetParent","getContainingBlock","isFirefox","isIE","elementCss","currentNode","getOffsetParent","window","offsetParent","getMainAxisFromPlacement","within","mathMax","mathMin","withinMaxClamp","getFreshSideObject","mergePaddingObject","paddingObject","expandToHashMap","hashMap","toPaddingObject","arrow","_state$modifiersData$","arrowElement","popperOffsets","basePlacement","axis","isVertical","len","arrowRect","minProp","maxProp","endDiff","startDiff","arrowOffsetParent","clientSize","centerToReference","center","offset","axisProp","_options$element","arrow$1","getVariation","unsetSides","roundOffsetsByDPR","win","dpr","mapToStyles","_Object$assign2","popperRect","variation","offsets","gpuAcceleration","adaptive","roundOffsets","isFixed","_offsets$x","_offsets$y","_ref3","hasX","hasY","sideX","sideY","heightProp","widthProp","offsetY","offsetX","commonStyles","_ref4","_Object$assign","computeStyles","_ref5","_options$gpuAccelerat","_options$adaptive","_options$roundOffsets","computeStyles$1","passive","_options$scroll","scroll","_options$resize","resize","scrollParents","scrollParent","eventListeners","hash","getOppositePlacement","matched","getOppositeVariationPlacement","getWindowScroll","scrollLeft","scrollTop","getWindowScrollBarX","getViewportRect","strategy","html","layoutViewport","getDocumentRect","_element$ownerDocumen","winScroll","body","isScrollParent","_getComputedStyle","overflow","overflowX","overflowY","getScrollParent","listScrollParents","list","isBody","updatedList","rectToClientRect","rect","getInnerBoundingClientRect","getClientRectFromMixedType","clippingParent","getClippingParents","canEscapeClipping","clipperElement","getClippingRect","boundary","rootBoundary","mainClippingParents","firstClippingParent","clippingRect","accRect","computeOffsets","commonX","commonY","mainAxis","detectOverflow","_options","_options$placement","_options$strategy","_options$boundary","_options$rootBoundary","_options$elementConte","elementContext","_options$altBoundary","altBoundary","_options$padding","altContext","clippingClientRect","referenceClientRect","popperClientRect","elementClientRect","overflowOffsets","offsetData","multiply","computeAutoPlacement","flipVariations","_options$allowedAutoP","allowedAutoPlacements","allPlacements","allowedPlacements","overflows","getExpandedFallbackPlacements","oppositePlacement","flip","_options$mainAxis","checkMainAxis","_options$altAxis","checkAltAxis","specifiedFallbackPlacements","_options$flipVariatio","preferredPlacement","isBasePlacement","fallbackPlacements","referenceRect","checksMap","makeFallbackChecks","firstFittingPlacement","_basePlacement","isStartVariation","mainVariationSide","altVariationSide","checks","check","numberOfChecks","_loop","_i","fittingPlacement","_ret","flip$1","getSideOffsets","preventedOffsets","isAnySideFullyClipped","hide","referenceOverflow","popperAltOverflow","referenceClippingOffsets","popperEscapeOffsets","isReferenceHidden","hasPopperEscaped","hide$1","distanceAndSkiddingToXY","rects","invertDistance","skidding","distance","_options$offset","_data$state$placement","offset$1","popperOffsets$1","getAltAxis","preventOverflow","_options$tether","tether","_options$tetherOffset","tetherOffset","altAxis","tetherOffsetValue","normalizedTetherOffsetValue","offsetModifierState","_offsetModifierState$","mainSide","altSide","additive","minLen","maxLen","arrowPaddingObject","arrowPaddingMin","arrowPaddingMax","arrowLen","minOffset","maxOffset","clientOffset","offsetModifierValue","tetherMin","tetherMax","preventedOffset","_offsetModifierState$2","_mainSide","_altSide","_offset","_len","_min","_max","isOriginSide","_offsetModifierValue","_tetherMin","_tetherMax","_preventedOffset","preventOverflow$1","getHTMLElementScroll","getNodeScroll","isElementScaled","getCompositeRect","elementOrVirtualElement","isOffsetParentAnElement","offsetParentIsScaled","documentElement","order","modifiers","map","visited","modifier","sort","requires","dep","depModifier","orderModifiers","orderedModifiers","phase","pending","resolve","mergeByName","merged","current","existing","DEFAULT_OPTIONS","areValidElements","_key","popperGenerator","generatorOptions","_generatorOptions","_generatorOptions$def","defaultModifiers","_generatorOptions$def2","defaultOptions","effectCleanupFns","isDestroyed","setOptionsAction","cleanupModifierEffects","runModifierEffects","_state$elements","_state$orderedModifie","_state$orderedModifie2","_ref$options","cleanupFn","noopFn","createPopper","COMPONENT_NAME","getPopperUtilityClass","flipPlacement","resolveAnchorEl","anchorEl","isVirtualElement","defaultPopperOptions","PopperTooltip","_slots$root","initialPlacement","popperOptions","popperRefProp","TransitionProps","tooltipRef","ownRef","popperRef","handlePopperRef","handlePopperRefRef","rtlPlacement","setPlacement","resolvedAnchorElement","setResolvedAnchorElement","handlePopperUpdate","box","popperModifiers","childProps","Root","rootProps","Popper","containerProp","keepMounted","transition","exited","setExited","handleEnter","handleExited","resolvedAnchorEl","display","transitionProps","useThemeSystem","_setPrototypeOf","_inheritsLoose","subClass","superClass","setPrototypeOf","timeoutsShape","TransitionGroupContext","forceReflow","UNMOUNTED","EXITED","ENTERING","ENTERED","EXITING","Transition","_React$Component","_this","parentGroup","appear","initialStatus","prevState","nextIn","_proto","prevProps","nextStatus","exit","enter","mounting","_this2","appearing","maybeNode","maybeAppearing","timeouts","enterTimeout","_this3","nextState","callback","_this4","active","handler","doesNotHaveTimeoutOrListener","maybeNextCallback","_this$props","pt","noop","Transition$1","reflow","getTransitionProps","_style$transitionDura","_style$transitionTimi","getScale","isWebKit154","Grow","addEndListener","inProp","onEnter","onEntered","onEntering","onExit","onExited","onExiting","TransitionComponent","timer","autoTimeout","nodeRef","normalizedTransitionCallback","maybeIsAppearing","handleEntering","isAppearing","transitionDuration","transitionTimingFunction","handleEntered","handleExiting","handleExit","Grow$1","PopperRoot","BasePopper","components","componentsProps","RootComponent","Popper$1","getTooltipUtilityClass","tooltipClasses","tooltipClasses$1","disableInteractive","touch","TooltipPopper","TooltipTooltip","TooltipArrow","hystersisOpen","hystersisTimer","cursorPosition","composeEventHandler","eventHandler","_slots$popper","_slots$transition","_slots$tooltip","_slots$arrow","_slotProps$popper","_ref6","_slotProps$popper2","_slotProps$transition","_slotProps$tooltip","_ref7","_slotProps$tooltip2","_slotProps$arrow","_ref8","_slotProps$arrow2","childrenProp","describeChild","disableFocusListener","disableHoverListener","disableInteractiveProp","disableTouchListener","enterDelay","enterNextDelay","enterTouchDelay","followCursor","idProp","leaveDelay","leaveTouchDelay","onClose","onOpen","PopperComponentProp","PopperProps","title","TransitionComponentProp","isRtl","childNode","setChildNode","arrowRef","setArrowRef","ignoreNonTouchEvents","closeTimer","enterTimer","leaveTimer","touchTimer","setOpenState","prevUserSelect","stopTouchInteraction","handleOpen","handleClose","handleLeave","focusVisibleRef","setChildIsFocusVisible","handleBlur","handleFocus","detectTouchStart","childrenProps","handleMouseOver","handleMouseLeave","handleTouchStart","handleTouchEnd","nativeEvent","handleMouseMove","nameOrDescProps","titleIsString","interactiveWrapperListeners","_PopperProps$popperOp","tooltipModifiers","PopperComponent","TooltipComponent","ArrowComponent","popperProps","tooltipProps","tooltipArrowProps","TransitionPropsInner","Tooltip$1","getIcon","icon","menuLabel","leading","MuiListItemIcon","MenuItem","allowForLeadingIcons","iconPathBefore","iconPathAfter","hasAutoFocus","isDense","isSubMenuParent","hasDisabledGutters","hasDivider","focusVisibleClassName","menuItem","MuiMenuItem","MuiListItemText","getAllGroups","menuDefinition","SubMenu","setAnchorEl","parentMenuItem","parentItemProps","handleParentMenuItemClick","renderSubMenuItems","includedGroups","group","GroupedMenuItemList","Menu","getOrderedGroupItems","groupId","allItems","menuProps","commandHandler","groupsToInclude","sortedGroups","itemArray","allowSpaceForLeadingIcons","createMenuItemProps","isLastItemInGroup","divKey","itemInfo","menuItemProps","TopLevelMenu","columnId","MenuColumn","metadata","Grid","List","GridMenu","multiColumnMenu","sortedColumns","columnNumbers","columnName","col","getUsePromiseOptionsDefaults","usePromise","promiseFactoryCallback","defaultValueRef","optionsDefaultedRef","setIsLoading","promiseIsCurrent","MenuIcon","HamburgerMenuButton","menuProvider","normalMenu","fullMenu","containerRef","ariaLabelPrefix","isMenuOpen","setMenuOpen","showFullMenu","setShowFullMenu","handleMenuItemClick","handleMenuButtonClick","prevIsOpen","isOpening","menuCommandHandler","command","setOffset","normalMenuData","fullMenuData","menu","IconButton","Drawer","isTooltipSuppressed","adjustMarginToAlignToEdge","MuiIconButton","Spinner","LoaderCircle","TextField","hasError","helperText","onFocus","onBlur","ShadLabel","Toolbar","AppBar","MuiToolbar","alertVariants","Alert","AlertTitle","AlertDescription","Sonner","Toaster","Slider","SliderPrimitive","Switch","SwitchPrimitives","Tabs","TabsList","TabsTrigger","TabsContent","InstallButton","isInstalling","handleClick","buttonText","Download","EnableButton","isEnabling","DisableButton","isDisabling","UpdateButton","isUpdating","MarkdownRenderer","markdown","anchorTarget","Markdown","FilterButton","Filter","DropdownMenuItemType","DropdownMenuItemType2","FilterDropdown","groups","NoExtensionsFound","MoreInfo","category","downloads","languages","moreInfoUrl","numberFormatted","NumberFormat","handleScrollToBottom","User","locale","LucideLink","CircleHelp","VersionHistory","versionHistory","showAllVersions","setShowAllVersions","currentDate","formatTimeString","dateString","date","dateDiff","yearDiff","monthDiff","dayDiff","timeString","sortedEntries","Footer","publisherDisplayName","fileSize","locales","formattedFileSize","formatBytes","languageNames","codes","displayNames","useEvent","unsubscriber","noopUnsubscriber","useEventAsync","unsubscribe","unsub"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAGA,MAAMA,KAAgBC,GAAoB,E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;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","x_google_ignoreList":[3,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,83,84,85,86,87,88,89,90,91,92,93,94,95,96,97,98,99,100,101,102,103,104,105,106,107,108,109,110,111,112,113,114,115,116,117,118,119,120,121,122,123,124,125,126,127,128,129,130,131,132,133,134,135,136,137,138,139,140,141,142,143,144,145,146,147,148,149,150,151,152,153,154,155,156,157,158,159,160,161,162,163,164,165,166,167,168,169,170,171,172,173,174,175,176,177,178,179,180,181,182,183,184,185,186,187,188,189,190,191,192,193,194,195,196,197,198,199,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,230]} \ No newline at end of file +{"version":3,"file":"index.js","sources":["../src/utils/shadcn-ui.util.ts","../src/components/shadcn-ui/input.tsx","../src/components/advanced/book-chapter-control/book-chapter-input.component.tsx","../../../node_modules/@sillsdev/scripture/dist/index.es.js","../src/components/shadcn-ui/dropdown-menu.tsx","../src/components/advanced/book-chapter-control/book-menu-item.component.tsx","../src/components/advanced/book-chapter-control/chapter-select.component.tsx","../src/components/advanced/book-chapter-control/go-to-menu-item.component.tsx","../src/components/advanced/book-chapter-control/book-chapter-control.component.tsx","../src/components/shadcn-ui/button.tsx","../src/components/shadcn-ui/label.tsx","../src/components/shadcn-ui/radio-group.tsx","../src/components/shadcn-ui/popover.tsx","../src/components/shadcn-ui/dialog.tsx","../src/components/shadcn-ui/command.tsx","../src/components/basics/combo-box.component.tsx","../src/components/basics/chapter-range-selector.component.tsx","../src/components/advanced/book-selector.component.tsx","../src/components/advanced/data-table/data-table-column-toggle.component.tsx","../src/components/shadcn-ui/select.tsx","../src/components/advanced/data-table/data-table-pagination.component.tsx","../src/components/shadcn-ui/table.tsx","../src/components/advanced/data-table/data-table.component.tsx","../src/components/advanced/inventory/occurrences-table.component.tsx","../src/components/shadcn-ui/checkbox.tsx","../src/components/advanced/inventory/inventory-utils.ts","../src/components/shadcn-ui/toggle.tsx","../src/components/shadcn-ui/toggle-group.tsx","../src/components/advanced/inventory/inventory-columns.tsx","../src/components/advanced/inventory/inventory.component.tsx","../src/components/basics/search-bar.component.tsx","../src/components/basics/tabs-vertical.tsx","../src/components/advanced/tab-navigation-content-search.component.tsx","../src/components/shadcn-ui/separator.tsx","../src/components/shadcn-ui/sheet.tsx","../src/components/shadcn-ui/skeleton.tsx","../src/components/shadcn-ui/tooltip.tsx","../src/components/hooks/use-mobile.tsx","../src/components/shadcn-ui/sidebar.tsx","../src/components/advanced/settings-components/settings-sidebar.component.tsx","../src/components/advanced/settings-components/settings-sidebar-content-search.component.tsx","../src/components/advanced/scripture-results-viewer/scripture-results-viewer.component.tsx","../src/components/advanced/scroll-group-selector.component.tsx","../src/components/advanced/settings-components/settings-list.component.tsx","../src/components/shadcn-ui/card.tsx","../src/components/advanced/settings-components/settings-card.component.tsx","../src/components/basics/checklist.component.tsx","../../../node_modules/@babel/runtime/helpers/interopRequireDefault.js","../../../node_modules/@mui/utils/chainPropTypes/chainPropTypes.js","../../../node_modules/@babel/runtime/helpers/esm/extends.js","../../../node_modules/@mui/utils/deepmerge/deepmerge.js","../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.production.min.js","../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.development.js","../../../node_modules/prop-types/node_modules/react-is/index.js","../../../node_modules/object-assign/index.js","../../../node_modules/prop-types/lib/ReactPropTypesSecret.js","../../../node_modules/prop-types/lib/has.js","../../../node_modules/prop-types/checkPropTypes.js","../../../node_modules/prop-types/factoryWithTypeCheckers.js","../../../node_modules/prop-types/factoryWithThrowingShims.js","../../../node_modules/prop-types/index.js","../../../node_modules/@mui/utils/elementAcceptingRef/elementAcceptingRef.js","../../../node_modules/@mui/utils/exactProp/exactProp.js","../../../node_modules/@mui/utils/formatMuiErrorMessage/formatMuiErrorMessage.js","../../../node_modules/react-is/cjs/react-is.production.min.js","../../../node_modules/react-is/cjs/react-is.development.js","../../../node_modules/react-is/index.js","../../../node_modules/@mui/utils/getDisplayName/getDisplayName.js","../../../node_modules/@mui/utils/HTMLElementType/HTMLElementType.js","../../../node_modules/@mui/utils/refType/refType.js","../../../node_modules/@mui/utils/capitalize/capitalize.js","../../../node_modules/@mui/utils/createChainedFunction/createChainedFunction.js","../../../node_modules/@mui/utils/debounce/debounce.js","../../../node_modules/@mui/utils/deprecatedPropType/deprecatedPropType.js","../../../node_modules/@mui/utils/isMuiElement/isMuiElement.js","../../../node_modules/@mui/utils/ownerDocument/ownerDocument.js","../../../node_modules/@mui/utils/ownerWindow/ownerWindow.js","../../../node_modules/@mui/utils/requirePropFactory/requirePropFactory.js","../../../node_modules/@mui/utils/setRef/setRef.js","../../../node_modules/@mui/utils/useEnhancedEffect/useEnhancedEffect.js","../../../node_modules/@mui/utils/useId/useId.js","../../../node_modules/@mui/utils/unsupportedProp/unsupportedProp.js","../../../node_modules/@mui/utils/useControlled/useControlled.js","../../../node_modules/@mui/utils/useEventCallback/useEventCallback.js","../../../node_modules/@mui/utils/useForkRef/useForkRef.js","../../../node_modules/@mui/utils/useLazyRef/useLazyRef.js","../../../node_modules/@mui/utils/useOnMount/useOnMount.js","../../../node_modules/@mui/utils/useTimeout/useTimeout.js","../../../node_modules/@mui/utils/useIsFocusVisible/useIsFocusVisible.js","../../../node_modules/@mui/utils/resolveProps/resolveProps.js","../../../node_modules/@mui/utils/composeClasses/composeClasses.js","../../../node_modules/@mui/utils/ClassNameGenerator/ClassNameGenerator.js","../../../node_modules/@mui/utils/generateUtilityClass/generateUtilityClass.js","../../../node_modules/@mui/utils/generateUtilityClasses/generateUtilityClasses.js","../../../node_modules/@mui/utils/clamp/clamp.js","../../../node_modules/@babel/runtime/helpers/esm/objectWithoutPropertiesLoose.js","../../../node_modules/@mui/system/esm/createTheme/createBreakpoints.js","../../../node_modules/@mui/system/esm/createTheme/shape.js","../../../node_modules/@mui/system/esm/responsivePropType.js","../../../node_modules/@mui/system/esm/merge.js","../../../node_modules/@mui/system/esm/breakpoints.js","../../../node_modules/@mui/system/esm/style.js","../../../node_modules/@mui/system/esm/memoize.js","../../../node_modules/@mui/system/esm/spacing.js","../../../node_modules/@mui/system/esm/createTheme/createSpacing.js","../../../node_modules/@mui/system/esm/compose.js","../../../node_modules/@mui/system/esm/borders.js","../../../node_modules/@mui/system/esm/cssGrid.js","../../../node_modules/@mui/system/esm/palette.js","../../../node_modules/@mui/system/esm/sizing.js","../../../node_modules/@mui/system/esm/styleFunctionSx/defaultSxConfig.js","../../../node_modules/@mui/system/esm/styleFunctionSx/styleFunctionSx.js","../../../node_modules/@mui/system/esm/createTheme/applyStyles.js","../../../node_modules/@mui/system/esm/createTheme/createTheme.js","../../../node_modules/@mui/system/esm/useThemeWithoutDefault.js","../../../node_modules/@mui/system/esm/useTheme.js","../../../node_modules/@mui/system/esm/createStyled.js","../../../node_modules/@mui/system/esm/useThemeProps/getThemeProps.js","../../../node_modules/@mui/system/esm/useThemeProps/useThemeProps.js","../../../node_modules/@mui/system/esm/colorManipulator.js","../../../node_modules/@mui/material/styles/createMixins.js","../../../node_modules/@mui/material/colors/common.js","../../../node_modules/@mui/material/colors/grey.js","../../../node_modules/@mui/material/colors/purple.js","../../../node_modules/@mui/material/colors/red.js","../../../node_modules/@mui/material/colors/orange.js","../../../node_modules/@mui/material/colors/blue.js","../../../node_modules/@mui/material/colors/lightBlue.js","../../../node_modules/@mui/material/colors/green.js","../../../node_modules/@mui/material/styles/createPalette.js","../../../node_modules/@mui/material/styles/createTypography.js","../../../node_modules/@mui/material/styles/shadows.js","../../../node_modules/@mui/material/styles/createTransitions.js","../../../node_modules/@mui/material/styles/zIndex.js","../../../node_modules/@mui/material/styles/createTheme.js","../../../node_modules/@mui/material/styles/defaultTheme.js","../../../node_modules/@mui/material/styles/identifier.js","../../../node_modules/@mui/material/styles/useThemeProps.js","../../../node_modules/@mui/material/styles/styled.js","../../../node_modules/@mui/material/SvgIcon/svgIconClasses.js","../../../node_modules/@mui/material/SvgIcon/SvgIcon.js","../../../node_modules/@mui/material/utils/createSvgIcon.js","../../../node_modules/@mui/material/utils/index.js","../../../node_modules/@mui/icons-material/utils/createSvgIcon.js","../../../node_modules/@mui/icons-material/ArrowRight.js","../../../node_modules/@mui/base/utils/isHostComponent.js","../../../node_modules/@mui/base/utils/appendOwnerState.js","../../../node_modules/@mui/base/utils/ClassNameConfigurator.js","../../../node_modules/@mui/base/utils/extractEventHandlers.js","../../../node_modules/@mui/base/utils/resolveComponentProps.js","../../../node_modules/@mui/base/utils/omitEventHandlers.js","../../../node_modules/@mui/base/utils/mergeSlotProps.js","../../../node_modules/@mui/base/utils/useSlotProps.js","../../../node_modules/@mui/base/generateUtilityClass/index.js","../../../node_modules/@mui/base/generateUtilityClasses/index.js","../../../node_modules/@mui/base/Portal/Portal.js","../../../node_modules/@popperjs/core/lib/enums.js","../../../node_modules/@popperjs/core/lib/dom-utils/getNodeName.js","../../../node_modules/@popperjs/core/lib/dom-utils/getWindow.js","../../../node_modules/@popperjs/core/lib/dom-utils/instanceOf.js","../../../node_modules/@popperjs/core/lib/modifiers/applyStyles.js","../../../node_modules/@popperjs/core/lib/utils/getBasePlacement.js","../../../node_modules/@popperjs/core/lib/utils/math.js","../../../node_modules/@popperjs/core/lib/utils/userAgent.js","../../../node_modules/@popperjs/core/lib/dom-utils/isLayoutViewport.js","../../../node_modules/@popperjs/core/lib/dom-utils/getBoundingClientRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/getLayoutRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/contains.js","../../../node_modules/@popperjs/core/lib/dom-utils/getComputedStyle.js","../../../node_modules/@popperjs/core/lib/dom-utils/isTableElement.js","../../../node_modules/@popperjs/core/lib/dom-utils/getDocumentElement.js","../../../node_modules/@popperjs/core/lib/dom-utils/getParentNode.js","../../../node_modules/@popperjs/core/lib/dom-utils/getOffsetParent.js","../../../node_modules/@popperjs/core/lib/utils/getMainAxisFromPlacement.js","../../../node_modules/@popperjs/core/lib/utils/within.js","../../../node_modules/@popperjs/core/lib/utils/getFreshSideObject.js","../../../node_modules/@popperjs/core/lib/utils/mergePaddingObject.js","../../../node_modules/@popperjs/core/lib/utils/expandToHashMap.js","../../../node_modules/@popperjs/core/lib/modifiers/arrow.js","../../../node_modules/@popperjs/core/lib/utils/getVariation.js","../../../node_modules/@popperjs/core/lib/modifiers/computeStyles.js","../../../node_modules/@popperjs/core/lib/modifiers/eventListeners.js","../../../node_modules/@popperjs/core/lib/utils/getOppositePlacement.js","../../../node_modules/@popperjs/core/lib/utils/getOppositeVariationPlacement.js","../../../node_modules/@popperjs/core/lib/dom-utils/getWindowScroll.js","../../../node_modules/@popperjs/core/lib/dom-utils/getWindowScrollBarX.js","../../../node_modules/@popperjs/core/lib/dom-utils/getViewportRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/getDocumentRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/isScrollParent.js","../../../node_modules/@popperjs/core/lib/dom-utils/getScrollParent.js","../../../node_modules/@popperjs/core/lib/dom-utils/listScrollParents.js","../../../node_modules/@popperjs/core/lib/utils/rectToClientRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/getClippingRect.js","../../../node_modules/@popperjs/core/lib/utils/computeOffsets.js","../../../node_modules/@popperjs/core/lib/utils/detectOverflow.js","../../../node_modules/@popperjs/core/lib/utils/computeAutoPlacement.js","../../../node_modules/@popperjs/core/lib/modifiers/flip.js","../../../node_modules/@popperjs/core/lib/modifiers/hide.js","../../../node_modules/@popperjs/core/lib/modifiers/offset.js","../../../node_modules/@popperjs/core/lib/modifiers/popperOffsets.js","../../../node_modules/@popperjs/core/lib/utils/getAltAxis.js","../../../node_modules/@popperjs/core/lib/modifiers/preventOverflow.js","../../../node_modules/@popperjs/core/lib/dom-utils/getHTMLElementScroll.js","../../../node_modules/@popperjs/core/lib/dom-utils/getNodeScroll.js","../../../node_modules/@popperjs/core/lib/dom-utils/getCompositeRect.js","../../../node_modules/@popperjs/core/lib/utils/orderModifiers.js","../../../node_modules/@popperjs/core/lib/utils/debounce.js","../../../node_modules/@popperjs/core/lib/utils/mergeByName.js","../../../node_modules/@popperjs/core/lib/createPopper.js","../../../node_modules/@popperjs/core/lib/popper.js","../../../node_modules/@mui/base/Popper/popperClasses.js","../../../node_modules/@mui/base/Popper/Popper.js","../../../node_modules/@mui/material/styles/useTheme.js","../../../node_modules/@babel/runtime/helpers/esm/setPrototypeOf.js","../../../node_modules/@babel/runtime/helpers/esm/inheritsLoose.js","../../../node_modules/react-transition-group/esm/config.js","../../../node_modules/react-transition-group/esm/utils/PropTypes.js","../../../node_modules/react-transition-group/esm/TransitionGroupContext.js","../../../node_modules/react-transition-group/esm/utils/reflow.js","../../../node_modules/react-transition-group/esm/Transition.js","../../../node_modules/@mui/material/transitions/utils.js","../../../node_modules/@mui/material/Grow/Grow.js","../../../node_modules/@mui/material/Popper/Popper.js","../../../node_modules/@mui/material/Tooltip/tooltipClasses.js","../../../node_modules/@mui/material/Tooltip/Tooltip.js","../src/components/mui/menu-item.component.tsx","../src/components/mui/grouped-menu-item-list.component.tsx","../src/components/mui/top-level-menu.component.tsx","../src/components/mui/grid-menu.component.tsx","../src/hooks/use-promise.hook.ts","../../../node_modules/@mui/icons-material/esm/Menu.js","../src/components/mui/hamburger-menu-button.component.tsx","../src/components/mui/icon-button.component.tsx","../src/components/basics/spinner.component.tsx","../src/components/basics/text-field.component.tsx","../src/components/mui/toolbar.component.tsx","../src/components/shadcn-ui/alert.tsx","../src/components/shadcn-ui/sonner.tsx","../src/components/shadcn-ui/slider.tsx","../src/components/shadcn-ui/switch.tsx","../src/components/shadcn-ui/tabs.tsx","../src/components/advanced/extension-marketplace/buttons/install-button.component.tsx","../src/components/advanced/extension-marketplace/buttons/enable-button.component.tsx","../src/components/advanced/extension-marketplace/buttons/disable-button.component.tsx","../src/components/advanced/extension-marketplace/buttons/update-button.component.tsx","../src/components/advanced/extension-marketplace/markdown-renderer.component.tsx","../src/components/advanced/extension-marketplace/buttons/filter-button.component.tsx","../src/components/advanced/extension-marketplace/filter-dropdown.component.tsx","../src/components/advanced/extension-marketplace/no-extensions-found.component.tsx","../src/components/advanced/extension-marketplace/more-info.component.tsx","../src/components/advanced/extension-marketplace/version-history.component.tsx","../src/components/advanced/extension-marketplace/footer.component.tsx","../src/hooks/use-event.hook.ts","../src/hooks/use-event-async.hook.ts"],"sourcesContent":["import { type ClassValue, clsx } from 'clsx';\nimport { extendTailwindMerge } from 'tailwind-merge';\n\nconst twMergeCustom = extendTailwindMerge({ prefix: 'tw-' });\n\n/**\n * Tailwind and CSS class application helper function. Uses\n * [`clsx`](https://www.npmjs.com/package/clsx) to make it easy to apply classes conditionally using\n * object syntax, and uses [`tailwind-merge`](https://www.npmjs.com/package/tailwind-merge) to make\n * it easy to merge/overwrite Tailwind classes in a programmer-logic-friendly way.\n *\n * Note: `tailwind-merge` is configured to use the prefix `tw-`, so you must use the same prefix\n * with any Tailwind classes you use with this function to successfully overwrite other Tailwind\n * classes. `platform-bible-react` is configured to use `tw-` as its Tailwind prefix, so any\n * Tailwind classes you pass into `platform-bible-react` components will be compared using the `tw-`\n * prefix.\n *\n * This function was popularized by\n * [shadcn/ui](https://ui.shadcn.com/docs/installation/manual#add-a-cn-helper). See [ByteGrad's\n * explanation video](https://www.youtube.com/watch?v=re2JFITR7TI) for more information.\n *\n * @example\n *\n * ```typescript\n * const borderShouldBeBlue = true;\n * const textShouldBeRed = true;\n * const heightShouldBe20 = false;\n * const classString = cn(\n * 'tw-bg-primary tw-h-10 tw-text-primary-foreground',\n * 'tw-bg-secondary',\n * {\n * 'tw-border-blue-500': borderShouldBeBlue,\n * 'tw-text-red-500': textShouldBeRed,\n * 'tw-h-20': heightShouldBe20,\n * },\n * 'some-class',\n * );\n * ```\n *\n * The resulting `classString` is `'tw-h-10 tw-bg-secondary tw-border-blue-500 tw-text-red-500\n * some-class'`\n *\n * - Notice that `'tw-bg-secondary'`, specified later, overwrote `'tw-bg-primary'`, specified earlier,\n * because they are Tailwind classes that affect the same css property\n * - Notice that `'tw-text-red-500'`, specified later, overwrote `'tw-text-primary-foreground'`,\n * specified earlier, because they are Tailwind classes that affect the same css property\n * - Notice that `'tw-h-20'`, specified later, did not overwrite `'tw-h-10'`, specified earlier,\n * because `'tw-h-20'` is part of a conditional class object and its value evaluated to `false`;\n * therefore it was not applied\n * - Notice that `'some-class'` was applied. This function is not limited only to Tailwind classes.\n *\n *\n * @param inputs Class strings or `clsx` conditional class objects to merge. Tailwind classes\n * specified later in the arguments overwrite similar Tailwind classes specified earlier in the\n * arguments\n * @returns Class string containing all applicable classes from the arguments based on the rules\n * described above\n */\n// shadcn/ui uses this export in its boilerplate code\n// eslint-disable-next-line import/prefer-default-export\nexport function cn(...inputs: ClassValue[]) {\n return twMergeCustom(clsx(inputs));\n}\n","import React from 'react';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport interface InputProps extends React.InputHTMLAttributes {}\n\nexport const Input = React.forwardRef(\n ({ className, type, ...props }, ref) => {\n return (\n \n );\n },\n);\nInput.displayName = 'Input';\n","import { FocusEventHandler, forwardRef, KeyboardEvent, MouseEventHandler } from 'react';\nimport { History } from 'lucide-react';\nimport { Input as ShadInput } from '@/components/shadcn-ui/input';\n\nexport type BookChapterInputProps = {\n handleSearch: (searchString: string) => void;\n handleKeyDown: (event: KeyboardEvent) => void;\n handleOnClick: MouseEventHandler;\n handleSubmit: () => void;\n onFocus?: FocusEventHandler;\n value: string;\n placeholder: string;\n};\n\n// Shadcn Input sets type to \"button\"- HAVE to prop spread before setting type\nconst BookChapterInput = forwardRef(\n (\n { handleSearch, handleKeyDown, handleOnClick, handleSubmit, ...props }: BookChapterInputProps,\n ref,\n ) => {\n return (\n
    \n handleSearch(event.target.value)}\n onKeyDown={(e) => {\n if (e.key === 'Enter') {\n handleSubmit();\n }\n handleKeyDown(e);\n }}\n onClick={handleOnClick}\n ref={ref}\n />\n {\n // eslint-disable-next-line no-console\n console.log('back in history');\n }}\n />\n
    \n );\n },\n);\n\nexport default BookChapterInput;\n","var P = Object.defineProperty;\nvar R = (t, e, s) => e in t ? P(t, e, { enumerable: !0, configurable: !0, writable: !0, value: s }) : t[e] = s;\nvar n = (t, e, s) => R(t, typeof e != \"symbol\" ? e + \"\" : e, s);\nclass _ {\n constructor() {\n n(this, \"books\");\n n(this, \"firstSelectedBookNum\");\n n(this, \"lastSelectedBookNum\");\n n(this, \"count\");\n n(this, \"selectedBookNumbers\");\n n(this, \"selectedBookIds\");\n }\n}\nconst N = [\n \"GEN\",\n \"EXO\",\n \"LEV\",\n \"NUM\",\n \"DEU\",\n \"JOS\",\n \"JDG\",\n \"RUT\",\n \"1SA\",\n \"2SA\",\n // 10\n \"1KI\",\n \"2KI\",\n \"1CH\",\n \"2CH\",\n \"EZR\",\n \"NEH\",\n \"EST\",\n \"JOB\",\n \"PSA\",\n \"PRO\",\n // 20\n \"ECC\",\n \"SNG\",\n \"ISA\",\n \"JER\",\n \"LAM\",\n \"EZK\",\n \"DAN\",\n \"HOS\",\n \"JOL\",\n \"AMO\",\n // 30\n \"OBA\",\n \"JON\",\n \"MIC\",\n \"NAM\",\n \"HAB\",\n \"ZEP\",\n \"HAG\",\n \"ZEC\",\n \"MAL\",\n \"MAT\",\n // 40\n \"MRK\",\n \"LUK\",\n \"JHN\",\n \"ACT\",\n \"ROM\",\n \"1CO\",\n \"2CO\",\n \"GAL\",\n \"EPH\",\n \"PHP\",\n // 50\n \"COL\",\n \"1TH\",\n \"2TH\",\n \"1TI\",\n \"2TI\",\n \"TIT\",\n \"PHM\",\n \"HEB\",\n \"JAS\",\n \"1PE\",\n // 60\n \"2PE\",\n \"1JN\",\n \"2JN\",\n \"3JN\",\n \"JUD\",\n \"REV\",\n \"TOB\",\n \"JDT\",\n \"ESG\",\n \"WIS\",\n // 70\n \"SIR\",\n \"BAR\",\n \"LJE\",\n \"S3Y\",\n \"SUS\",\n \"BEL\",\n \"1MA\",\n \"2MA\",\n \"3MA\",\n \"4MA\",\n // 80\n \"1ES\",\n \"2ES\",\n \"MAN\",\n \"PS2\",\n \"ODA\",\n \"PSS\",\n \"JSA\",\n // actual variant text for JOS, now in LXA text\n \"JDB\",\n // actual variant text for JDG, now in LXA text\n \"TBS\",\n // actual variant text for TOB, now in LXA text\n \"SST\",\n // actual variant text for SUS, now in LXA text // 90\n \"DNT\",\n // actual variant text for DAN, now in LXA text\n \"BLT\",\n // actual variant text for BEL, now in LXA text\n \"XXA\",\n \"XXB\",\n \"XXC\",\n \"XXD\",\n \"XXE\",\n \"XXF\",\n \"XXG\",\n \"FRT\",\n // 100\n \"BAK\",\n \"OTH\",\n \"3ES\",\n // Used previously but really should be 2ES\n \"EZA\",\n // Used to be called 4ES, but not actually in any known project\n \"5EZ\",\n // Used to be called 5ES, but not actually in any known project\n \"6EZ\",\n // Used to be called 6ES, but not actually in any known project\n \"INT\",\n \"CNC\",\n \"GLO\",\n \"TDX\",\n // 110\n \"NDX\",\n \"DAG\",\n \"PS3\",\n \"2BA\",\n \"LBA\",\n \"JUB\",\n \"ENO\",\n \"1MQ\",\n \"2MQ\",\n \"3MQ\",\n // 120\n \"REP\",\n \"4BA\",\n \"LAO\"\n], B = [\n \"XXA\",\n \"XXB\",\n \"XXC\",\n \"XXD\",\n \"XXE\",\n \"XXF\",\n \"XXG\",\n \"FRT\",\n \"BAK\",\n \"OTH\",\n \"INT\",\n \"CNC\",\n \"GLO\",\n \"TDX\",\n \"NDX\"\n], O = [\n \"Genesis\",\n \"Exodus\",\n \"Leviticus\",\n \"Numbers\",\n \"Deuteronomy\",\n \"Joshua\",\n \"Judges\",\n \"Ruth\",\n \"1 Samuel\",\n \"2 Samuel\",\n \"1 Kings\",\n \"2 Kings\",\n \"1 Chronicles\",\n \"2 Chronicles\",\n \"Ezra\",\n \"Nehemiah\",\n \"Esther (Hebrew)\",\n \"Job\",\n \"Psalms\",\n \"Proverbs\",\n \"Ecclesiastes\",\n \"Song of Songs\",\n \"Isaiah\",\n \"Jeremiah\",\n \"Lamentations\",\n \"Ezekiel\",\n \"Daniel (Hebrew)\",\n \"Hosea\",\n \"Joel\",\n \"Amos\",\n \"Obadiah\",\n \"Jonah\",\n \"Micah\",\n \"Nahum\",\n \"Habakkuk\",\n \"Zephaniah\",\n \"Haggai\",\n \"Zechariah\",\n \"Malachi\",\n \"Matthew\",\n \"Mark\",\n \"Luke\",\n \"John\",\n \"Acts\",\n \"Romans\",\n \"1 Corinthians\",\n \"2 Corinthians\",\n \"Galatians\",\n \"Ephesians\",\n \"Philippians\",\n \"Colossians\",\n \"1 Thessalonians\",\n \"2 Thessalonians\",\n \"1 Timothy\",\n \"2 Timothy\",\n \"Titus\",\n \"Philemon\",\n \"Hebrews\",\n \"James\",\n \"1 Peter\",\n \"2 Peter\",\n \"1 John\",\n \"2 John\",\n \"3 John\",\n \"Jude\",\n \"Revelation\",\n \"Tobit\",\n \"Judith\",\n \"Esther Greek\",\n \"Wisdom of Solomon\",\n \"Sirach (Ecclesiasticus)\",\n \"Baruch\",\n \"Letter of Jeremiah\",\n \"Song of 3 Young Men\",\n \"Susanna\",\n \"Bel and the Dragon\",\n \"1 Maccabees\",\n \"2 Maccabees\",\n \"3 Maccabees\",\n \"4 Maccabees\",\n \"1 Esdras (Greek)\",\n \"2 Esdras (Latin)\",\n \"Prayer of Manasseh\",\n \"Psalm 151\",\n \"Odes\",\n \"Psalms of Solomon\",\n // WARNING, if you change the spelling of the *obsolete* tag be sure to update\n // IsObsolete routine\n \"Joshua A. *obsolete*\",\n \"Judges B. *obsolete*\",\n \"Tobit S. *obsolete*\",\n \"Susanna Th. *obsolete*\",\n \"Daniel Th. *obsolete*\",\n \"Bel Th. *obsolete*\",\n \"Extra A\",\n \"Extra B\",\n \"Extra C\",\n \"Extra D\",\n \"Extra E\",\n \"Extra F\",\n \"Extra G\",\n \"Front Matter\",\n \"Back Matter\",\n \"Other Matter\",\n \"3 Ezra *obsolete*\",\n \"Apocalypse of Ezra\",\n \"5 Ezra (Latin Prologue)\",\n \"6 Ezra (Latin Epilogue)\",\n \"Introduction\",\n \"Concordance \",\n \"Glossary \",\n \"Topical Index\",\n \"Names Index\",\n \"Daniel Greek\",\n \"Psalms 152-155\",\n \"2 Baruch (Apocalypse)\",\n \"Letter of Baruch\",\n \"Jubilees\",\n \"Enoch\",\n \"1 Meqabyan\",\n \"2 Meqabyan\",\n \"3 Meqabyan\",\n \"Reproof (Proverbs 25-31)\",\n \"4 Baruch (Rest of Baruch)\",\n \"Laodiceans\"\n], S = K();\nfunction g(t, e = !0) {\n return e && (t = t.toUpperCase()), t in S ? S[t] : 0;\n}\nfunction k(t) {\n return g(t) > 0;\n}\nfunction x(t) {\n const e = typeof t == \"string\" ? g(t) : t;\n return e >= 40 && e <= 66;\n}\nfunction T(t) {\n return (typeof t == \"string\" ? g(t) : t) <= 39;\n}\nfunction X(t) {\n return t <= 66;\n}\nfunction V(t) {\n const e = typeof t == \"string\" ? g(t) : t;\n return w(e) && !X(e);\n}\nfunction* L() {\n for (let t = 1; t <= N.length; t++) yield t;\n}\nconst G = 1, A = N.length;\nfunction H() {\n return [\"XXA\", \"XXB\", \"XXC\", \"XXD\", \"XXE\", \"XXF\", \"XXG\"];\n}\nfunction C(t, e = \"***\") {\n const s = t - 1;\n return s < 0 || s >= N.length ? e : N[s];\n}\nfunction I(t) {\n return t <= 0 || t > A ? \"******\" : O[t - 1];\n}\nfunction y(t) {\n return I(g(t));\n}\nfunction w(t) {\n const e = typeof t == \"number\" ? C(t) : t;\n return k(e) && !B.includes(e);\n}\nfunction q(t) {\n const e = typeof t == \"number\" ? C(t) : t;\n return k(e) && B.includes(e);\n}\nfunction U(t) {\n return O[t - 1].includes(\"*obsolete*\");\n}\nfunction K() {\n const t = {};\n for (let e = 0; e < N.length; e++)\n t[N[e]] = e + 1;\n return t;\n}\nconst m = {\n allBookIds: N,\n nonCanonicalIds: B,\n bookIdToNumber: g,\n isBookIdValid: k,\n isBookNT: x,\n isBookOT: T,\n isBookOTNT: X,\n isBookDC: V,\n allBookNumbers: L,\n firstBook: G,\n lastBook: A,\n extraBooks: H,\n bookNumberToId: C,\n bookNumberToEnglishName: I,\n bookIdToEnglishName: y,\n isCanonical: w,\n isExtraMaterial: q,\n isObsolete: U\n};\nvar l = /* @__PURE__ */ ((t) => (t[t.Unknown = 0] = \"Unknown\", t[t.Original = 1] = \"Original\", t[t.Septuagint = 2] = \"Septuagint\", t[t.Vulgate = 3] = \"Vulgate\", t[t.English = 4] = \"English\", t[t.RussianProtestant = 5] = \"RussianProtestant\", t[t.RussianOrthodox = 6] = \"RussianOrthodox\", t))(l || {});\nconst h = class h {\n // private versInfo: Versification;\n constructor(e) {\n n(this, \"name\");\n n(this, \"fullPath\");\n n(this, \"isPresent\");\n n(this, \"hasVerseSegments\");\n n(this, \"isCustomized\");\n n(this, \"baseVersification\");\n n(this, \"scriptureBooks\");\n n(this, \"_type\");\n if (e == null)\n throw new Error(\"Argument undefined\");\n typeof e == \"string\" ? (this.name = e, this._type = l[e]) : (this._type = e, this.name = l[e]);\n }\n get type() {\n return this._type;\n }\n equals(e) {\n return !e.type || !this.type ? !1 : e.type === this.type;\n }\n};\nn(h, \"Original\", new h(l.Original)), n(h, \"Septuagint\", new h(l.Septuagint)), n(h, \"Vulgate\", new h(l.Vulgate)), n(h, \"English\", new h(l.English)), n(h, \"RussianProtestant\", new h(l.RussianProtestant)), n(h, \"RussianOrthodox\", new h(l.RussianOrthodox));\nlet c = h;\nfunction E(t, e) {\n const s = e[0];\n for (let r = 1; r < e.length; r++)\n t = t.split(e[r]).join(s);\n return t.split(s);\n}\nvar D = /* @__PURE__ */ ((t) => (t[t.Valid = 0] = \"Valid\", t[t.UnknownVersification = 1] = \"UnknownVersification\", t[t.OutOfRange = 2] = \"OutOfRange\", t[t.VerseOutOfOrder = 3] = \"VerseOutOfOrder\", t[t.VerseRepeated = 4] = \"VerseRepeated\", t))(D || {});\nconst i = class i {\n constructor(e, s, r, a) {\n /** Not yet implemented. */\n n(this, \"firstChapter\");\n /** Not yet implemented. */\n n(this, \"lastChapter\");\n /** Not yet implemented. */\n n(this, \"lastVerse\");\n /** Not yet implemented. */\n n(this, \"hasSegmentsDefined\");\n /** Not yet implemented. */\n n(this, \"text\");\n /** Not yet implemented. */\n n(this, \"BBBCCCVVVS\");\n /** Not yet implemented. */\n n(this, \"longHashCode\");\n /** The versification of the reference. */\n n(this, \"versification\");\n n(this, \"rtlMark\", \"‏\");\n n(this, \"_bookNum\", 0);\n n(this, \"_chapterNum\", 0);\n n(this, \"_verseNum\", 0);\n n(this, \"_verse\");\n if (r == null && a == null)\n if (e != null && typeof e == \"string\") {\n const o = e, u = s != null && s instanceof c ? s : void 0;\n this.setEmpty(u), this.parse(o);\n } else if (e != null && typeof e == \"number\") {\n const o = s != null && s instanceof c ? s : void 0;\n this.setEmpty(o), this._verseNum = e % i.chapterDigitShifter, this._chapterNum = Math.floor(\n e % i.bookDigitShifter / i.chapterDigitShifter\n ), this._bookNum = Math.floor(e / i.bookDigitShifter);\n } else if (s == null)\n if (e != null && e instanceof i) {\n const o = e;\n this._bookNum = o.bookNum, this._chapterNum = o.chapterNum, this._verseNum = o.verseNum, this._verse = o.verse, this.versification = o.versification;\n } else {\n if (e == null) return;\n const o = e instanceof c ? e : i.defaultVersification;\n this.setEmpty(o);\n }\n else\n throw new Error(\"VerseRef constructor not supported.\");\n else if (e != null && s != null && r != null)\n if (typeof e == \"string\" && typeof s == \"string\" && typeof r == \"string\")\n this.setEmpty(a), this.updateInternal(e, s, r);\n else if (typeof e == \"number\" && typeof s == \"number\" && typeof r == \"number\")\n this._bookNum = e, this._chapterNum = s, this._verseNum = r, this.versification = a ?? i.defaultVersification;\n else\n throw new Error(\"VerseRef constructor not supported.\");\n else\n throw new Error(\"VerseRef constructor not supported.\");\n }\n /**\n * Determines if the verse string is in a valid format (does not consider versification).\n */\n static isVerseParseable(e) {\n return e.length > 0 && \"0123456789\".includes(e[0]) && !e.endsWith(this.verseRangeSeparator) && !e.endsWith(this.verseSequenceIndicator);\n }\n /**\n * Tries to parse the specified string into a verse reference.\n * @param str - The string to attempt to parse.\n * @returns success: `true` if the specified string was successfully parsed, `false` otherwise.\n * @returns verseRef: The result of the parse if successful, or empty VerseRef if it failed\n */\n static tryParse(e) {\n let s;\n try {\n return s = new i(e), { success: !0, verseRef: s };\n } catch (r) {\n if (r instanceof v)\n return s = new i(), { success: !1, verseRef: s };\n throw r;\n }\n }\n /**\n * Gets the reference as a comparable integer where the book, chapter, and verse each occupy 3\n * digits.\n * @param bookNum - Book number (this is 1-based, not an index).\n * @param chapterNum - Chapter number.\n * @param verseNum - Verse number.\n * @returns The reference as a comparable integer where the book, chapter, and verse each occupy 3\n * digits.\n */\n static getBBBCCCVVV(e, s, r) {\n return e % i.bcvMaxValue * i.bookDigitShifter + (s >= 0 ? s % i.bcvMaxValue * i.chapterDigitShifter : 0) + (r >= 0 ? r % i.bcvMaxValue : 0);\n }\n /**\n * Deserializes a serialized VerseRef.\n * @param serializedVerseRef - Serialized VerseRef to create from.\n * @returns the deserialized VerseRef.\n */\n static fromJSON(e) {\n const { book: s, chapterNum: r, verseNum: a, verse: o, versificationStr: u } = e, f = o || a.toString();\n let d;\n return u && (d = new c(u)), s ? new i(s, r.toString(), f, d) : new i();\n }\n /**\n * Parses a verse string and gets the leading numeric portion as a number.\n * @param verseStr - verse string to parse\n * @returns true if the entire string could be parsed as a single, simple verse number (1-999);\n * false if the verse string represented a verse bridge, contained segment letters, or was invalid\n */\n static tryGetVerseNum(e) {\n let s;\n if (!e)\n return s = -1, { success: !0, vNum: s };\n s = 0;\n let r;\n for (let a = 0; a < e.length; a++) {\n if (r = e[a], r < \"0\" || r > \"9\")\n return a === 0 && (s = -1), { success: !1, vNum: s };\n if (s = s * 10 + +r - 0, s > i.bcvMaxValue)\n return s = -1, { success: !1, vNum: s };\n }\n return { success: !0, vNum: s };\n }\n /**\n * Checks to see if a VerseRef hasn't been set - all values are the default.\n */\n get isDefault() {\n return this.bookNum === 0 && this.chapterNum === 0 && this.verseNum === 0 && this.versification == null;\n }\n /**\n * Gets whether the verse contains multiple verses.\n */\n get hasMultiple() {\n return this._verse != null && (this._verse.includes(i.verseRangeSeparator) || this._verse.includes(i.verseSequenceIndicator));\n }\n /**\n * Gets or sets the book of the reference. Book is the 3-letter abbreviation in capital letters,\n * e.g. `'MAT'`.\n */\n get book() {\n return m.bookNumberToId(this.bookNum, \"\");\n }\n set book(e) {\n this.bookNum = m.bookIdToNumber(e);\n }\n /**\n * Gets or sets the chapter of the reference,. e.g. `'3'`.\n */\n get chapter() {\n return this.isDefault || this._chapterNum < 0 ? \"\" : this._chapterNum.toString();\n }\n set chapter(e) {\n const s = +e;\n this._chapterNum = Number.isInteger(s) ? s : -1;\n }\n /**\n * Gets or sets the verse of the reference, including range, segments, and sequences, e.g. `'4'`,\n * or `'4b-5a, 7'`.\n */\n get verse() {\n return this._verse != null ? this._verse : this.isDefault || this._verseNum < 0 ? \"\" : this._verseNum.toString();\n }\n set verse(e) {\n const { success: s, vNum: r } = i.tryGetVerseNum(e);\n this._verse = s ? void 0 : e.replace(this.rtlMark, \"\"), this._verseNum = r, !(this._verseNum >= 0) && ({ vNum: this._verseNum } = i.tryGetVerseNum(this._verse));\n }\n /**\n * Get or set Book based on book number, e.g. `42`.\n */\n get bookNum() {\n return this._bookNum;\n }\n set bookNum(e) {\n if (e <= 0 || e > m.lastBook)\n throw new v(\n \"BookNum must be greater than zero and less than or equal to last book\"\n );\n this._bookNum = e;\n }\n /**\n * Gets or sets the chapter number, e.g. `3`. `-1` if not valid.\n */\n get chapterNum() {\n return this._chapterNum;\n }\n set chapterNum(e) {\n this.chapterNum = e;\n }\n /**\n * Gets or sets verse start number, e.g. `4`. `-1` if not valid.\n */\n get verseNum() {\n return this._verseNum;\n }\n set verseNum(e) {\n this._verseNum = e;\n }\n /**\n * String representing the versification (should ONLY be used for serialization/deserialization).\n *\n * @remarks This is for backwards compatibility when ScrVers was an enumeration.\n */\n get versificationStr() {\n var e;\n return (e = this.versification) == null ? void 0 : e.name;\n }\n set versificationStr(e) {\n this.versification = this.versification != null ? new c(e) : void 0;\n }\n /**\n * Determines if the reference is valid.\n */\n get valid() {\n return this.validStatus === 0;\n }\n /**\n * Get the valid status for this reference.\n */\n get validStatus() {\n return this.validateVerse(i.verseRangeSeparators, i.verseSequenceIndicators);\n }\n /**\n * Gets the reference as a comparable integer where the book,\n * chapter, and verse each occupy three digits and the verse is 0.\n */\n get BBBCCC() {\n return i.getBBBCCCVVV(this._bookNum, this._chapterNum, 0);\n }\n /**\n * Gets the reference as a comparable integer where the book,\n * chapter, and verse each occupy three digits. If verse is not null\n * (i.e., this reference represents a complex reference with verse\n * segments or bridge) this cannot be used for an exact comparison.\n */\n get BBBCCCVVV() {\n return i.getBBBCCCVVV(this._bookNum, this._chapterNum, this._verseNum);\n }\n /**\n * Gets whether the verse is defined as an excluded verse in the versification.\n * Does not handle verse ranges.\n */\n // eslint-disable-next-line @typescript-eslint/class-literal-property-style\n get isExcluded() {\n return !1;\n }\n /**\n * Parses the reference in the specified string.\n * Optionally versification can follow reference as in GEN 3:11/4\n * Throw an exception if\n * - invalid book name\n * - chapter number is missing or not a number\n * - verse number is missing or does not start with a number\n * - versification is invalid\n * @param verseStr - string to parse e.g. 'MAT 3:11'\n */\n parse(e) {\n if (e = e.replace(this.rtlMark, \"\"), e.includes(\"/\")) {\n const o = e.split(\"/\");\n if (e = o[0], o.length > 1)\n try {\n const u = +o[1].trim();\n this.versification = new c(l[u]);\n } catch {\n throw new v(\"Invalid reference : \" + e);\n }\n }\n const s = e.trim().split(\" \");\n if (s.length !== 2)\n throw new v(\"Invalid reference : \" + e);\n const r = s[1].split(\":\"), a = +r[0];\n if (r.length !== 2 || m.bookIdToNumber(s[0]) === 0 || !Number.isInteger(a) || a < 0 || !i.isVerseParseable(r[1]))\n throw new v(\"Invalid reference : \" + e);\n this.updateInternal(s[0], r[0], r[1]);\n }\n /**\n * Simplifies this verse ref so that it has no bridging of verses or\n * verse segments like `'1a'`.\n */\n simplify() {\n this._verse = void 0;\n }\n /**\n * Makes a clone of the reference.\n *\n * @returns The cloned VerseRef.\n */\n clone() {\n return new i(this);\n }\n toString() {\n const e = this.book;\n return e === \"\" ? \"\" : `${e} ${this.chapter}:${this.verse}`;\n }\n toJSON() {\n let e = this.verse;\n (e === \"\" || e === this.verseNum.toString()) && (e = void 0);\n const s = {\n book: this.book,\n chapterNum: this.chapterNum,\n verseNum: this.verseNum,\n verse: e,\n versificationStr: this.versificationStr\n };\n return e || delete s.verse, s;\n }\n /**\n * Compares this `VerseRef` with supplied one.\n * @param verseRef - object to compare this one to.\n * @returns `true` if this `VerseRef` is equal to the supplied one, `false` otherwise.\n */\n equals(e) {\n return e instanceof i ? e._bookNum === this._bookNum && e._chapterNum === this._chapterNum && e._verseNum === this._verseNum && e.verse === this.verse && (e.versification == null && this.versification == null || e.versification != null && this.versification != null && e.versification.equals(this.versification)) : !1;\n }\n /**\n * Enumerate all individual verses contained in a VerseRef.\n * Verse ranges are indicated by \"-\" and consecutive verses by \",\"s.\n * Examples:\n * GEN 1:2 returns GEN 1:2\n * GEN 1:1a-3b,5 returns GEN 1:1a, GEN 1:2, GEN 1:3b, GEN 1:5\n * GEN 1:2a-2c returns //! ??????\n *\n * @param specifiedVersesOnly - if set to true return only verses that are\n * explicitly specified only, not verses within a range. Defaults to `false`.\n * @param verseRangeSeparators - Verse range separators.\n * Defaults to `VerseRef.verseRangeSeparators`.\n * @param verseSequenceSeparators - Verse sequence separators.\n * Defaults to `VerseRef.verseSequenceIndicators`.\n * @returns An array of all single verse references in this VerseRef.\n */\n allVerses(e = !1, s = i.verseRangeSeparators, r = i.verseSequenceIndicators) {\n if (this._verse == null || this.chapterNum <= 0)\n return [this.clone()];\n const a = [], o = E(this._verse, r);\n for (const u of o.map((f) => E(f, s))) {\n const f = this.clone();\n f.verse = u[0];\n const d = f.verseNum;\n if (a.push(f), u.length > 1) {\n const b = this.clone();\n if (b.verse = u[1], !e)\n for (let p = d + 1; p < b.verseNum; p++) {\n const J = new i(\n this._bookNum,\n this._chapterNum,\n p,\n this.versification\n );\n this.isExcluded || a.push(J);\n }\n a.push(b);\n }\n }\n return a;\n }\n /**\n * Validates a verse number using the supplied separators rather than the defaults.\n */\n validateVerse(e, s) {\n if (!this.verse)\n return this.internalValid;\n let r = 0;\n for (const a of this.allVerses(!0, e, s)) {\n const o = a.internalValid;\n if (o !== 0)\n return o;\n const u = a.BBBCCCVVV;\n if (r > u)\n return 3;\n if (r === u)\n return 4;\n r = u;\n }\n return 0;\n }\n /**\n * Gets whether a single verse reference is valid.\n */\n get internalValid() {\n return this.versification == null ? 1 : this._bookNum <= 0 || this._bookNum > m.lastBook ? 2 : (m.isCanonical(this._bookNum), 0);\n }\n setEmpty(e = i.defaultVersification) {\n this._bookNum = 0, this._chapterNum = -1, this._verse = void 0, this.versification = e;\n }\n updateInternal(e, s, r) {\n this.bookNum = m.bookIdToNumber(e), this.chapter = s, this.verse = r;\n }\n};\nn(i, \"defaultVersification\", c.English), n(i, \"verseRangeSeparator\", \"-\"), n(i, \"verseSequenceIndicator\", \",\"), n(i, \"verseRangeSeparators\", [i.verseRangeSeparator]), n(i, \"verseSequenceIndicators\", [i.verseSequenceIndicator]), n(i, \"chapterDigitShifter\", 1e3), n(i, \"bookDigitShifter\", i.chapterDigitShifter * i.chapterDigitShifter), n(i, \"bcvMaxValue\", i.chapterDigitShifter - 1), /**\n * The valid status of the VerseRef.\n */\nn(i, \"ValidStatusType\", D);\nlet M = i;\nclass v extends Error {\n}\nexport {\n _ as BookSet,\n m as Canon,\n c as ScrVers,\n l as ScrVersType,\n M as VerseRef,\n v as VerseRefException\n};\n//# sourceMappingURL=index.es.js.map\n","import React from 'react';\nimport * as DropdownMenuPrimitive from '@radix-ui/react-dropdown-menu';\nimport { Check, ChevronRight, Circle } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport const DropdownMenu = DropdownMenuPrimitive.Root;\n\nexport const DropdownMenuTrigger = DropdownMenuPrimitive.Trigger;\n\nexport const DropdownMenuGroup = DropdownMenuPrimitive.Group;\n\nexport const DropdownMenuPortal = DropdownMenuPrimitive.Portal;\n\nexport const DropdownMenuSub = DropdownMenuPrimitive.Sub;\n\nexport const DropdownMenuRadioGroup = DropdownMenuPrimitive.RadioGroup;\n\nexport type DropdownMenuSubTriggerProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.SubTrigger\n> & {\n className?: string;\n inset?: boolean;\n};\n\nexport type DropdownMenuSubContentProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.SubContent\n> & {\n className?: string;\n};\n\nexport type DropdownMenuContentProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Content\n> & {\n className?: string;\n sideOffset?: number;\n};\n\nexport type DropdownMenuItemProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Item\n> & {\n className?: string;\n inset?: boolean;\n};\n\nexport type DropdownMenuCheckboxItemProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.CheckboxItem\n> & {\n className?: string;\n checked?: boolean;\n};\n\nexport type DropdownMenuRadioItemProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.RadioItem\n> & {\n className?: string;\n};\n\nexport type DropdownMenuLabelProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Label\n> & {\n className?: string;\n inset?: boolean;\n};\n\nexport type DropdownMenuSeparatorProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Separator\n> & {\n className?: string;\n};\n\nexport type DropdownMenuShortcutProps = React.HTMLAttributes & {\n className?: string;\n};\n\nexport const DropdownMenuSubTrigger = React.forwardRef<\n React.ElementRef,\n DropdownMenuSubTriggerProps\n>(({ className, inset, children, ...props }, ref) => (\n \n {children}\n \n \n));\nDropdownMenuSubTrigger.displayName = DropdownMenuPrimitive.SubTrigger.displayName;\n\nexport const DropdownMenuSubContent = React.forwardRef<\n React.ElementRef,\n DropdownMenuSubContentProps\n>(({ className, ...props }, ref) => (\n \n));\nDropdownMenuSubContent.displayName = DropdownMenuPrimitive.SubContent.displayName;\n\nexport const DropdownMenuContent = React.forwardRef<\n React.ElementRef,\n DropdownMenuContentProps\n>(({ className, sideOffset = 4, ...props }, ref) => (\n \n \n \n));\nDropdownMenuContent.displayName = DropdownMenuPrimitive.Content.displayName;\n\n/**\n * TODO: fix: direction is not automatically handled by this component, so that shortcuts are\n * display always to the right\n */\nexport const DropdownMenuItem = React.forwardRef<\n React.ElementRef,\n DropdownMenuItemProps\n>(({ className, inset, ...props }, ref) => (\n \n));\nDropdownMenuItem.displayName = DropdownMenuPrimitive.Item.displayName;\n\nexport const DropdownMenuCheckboxItem = React.forwardRef<\n React.ElementRef,\n DropdownMenuCheckboxItemProps\n>(({ className, children, checked, ...props }, ref) => (\n \n \n \n \n \n \n {children}\n \n));\nDropdownMenuCheckboxItem.displayName = DropdownMenuPrimitive.CheckboxItem.displayName;\n\nexport const DropdownMenuRadioItem = React.forwardRef<\n React.ElementRef,\n DropdownMenuRadioItemProps\n>(({ className, children, ...props }, ref) => (\n \n \n \n \n \n \n {children}\n \n));\nDropdownMenuRadioItem.displayName = DropdownMenuPrimitive.RadioItem.displayName;\n\nexport const DropdownMenuLabel = React.forwardRef<\n React.ElementRef,\n DropdownMenuLabelProps\n>(({ className, inset, ...props }, ref) => (\n \n));\nDropdownMenuLabel.displayName = DropdownMenuPrimitive.Label.displayName;\n\nexport const DropdownMenuSeparator = React.forwardRef<\n React.ElementRef,\n DropdownMenuSeparatorProps\n>(({ className, ...props }, ref) => (\n \n));\nDropdownMenuSeparator.displayName = DropdownMenuPrimitive.Separator.displayName;\n\nexport function DropdownMenuShortcut({ className, ...props }: DropdownMenuShortcutProps) {\n return (\n \n );\n}\nDropdownMenuShortcut.displayName = 'DropdownMenuShortcut';\n","import { Canon } from '@sillsdev/scripture';\nimport { PropsWithChildren, KeyboardEvent, forwardRef } from 'react';\nimport { DropdownMenuItem as ShadDropdownMenuItem } from '@/components/shadcn-ui/dropdown-menu';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport type BookType = 'OT' | 'NT' | 'DC';\n\ntype BookMenuItemProps = PropsWithChildren<{\n /** String id of book */\n bookId: string;\n /** Callback to run when a book menu item is selected */\n handleSelectBook: () => void;\n /** Indicates if this menu item is currently selected */\n isSelected: boolean;\n /** Function that is called upon highlighting a book in the dropdown menu */\n handleHighlightBook: () => void;\n /**\n * Function that is called on pressing a key\n *\n * @param event Event that contains information about the key stroke\n */\n handleKeyDown: (event: KeyboardEvent) => void;\n /**\n * Type of book associated with this menu item, coordinates color labels ? Mock up has the labels\n * coordinated to genre\n */\n bookType: BookType;\n}>;\n\nconst BookMenuItem = forwardRef(\n (\n {\n bookId,\n handleSelectBook,\n isSelected,\n handleHighlightBook,\n handleKeyDown,\n bookType,\n children,\n }: BookMenuItemProps,\n ref,\n ) => {\n return (\n {\n // preventDefault() here prevents the entire dropdown menu from closing when selecting this item\n event.preventDefault();\n handleSelectBook();\n }}\n onKeyDown={(event: KeyboardEvent) => {\n handleKeyDown(event);\n }}\n onFocus={handleHighlightBook}\n onMouseMove={handleHighlightBook}\n >\n \n {Canon.bookIdToEnglishName(bookId)}\n \n {isSelected &&
    {children}
    }\n \n );\n },\n);\n\nexport default BookMenuItem;\n","import { cn } from '@/utils/shadcn-ui.util';\nimport { useCallback } from 'react';\n\nexport type ChapterSelectProps = {\n /**\n * Callback to run when a chapter div is selected\n *\n * @param chapterNumber Number of the chapter that has been selected\n */\n handleSelectChapter: (chapterNumber: number) => void;\n /** The highest chapter number in the book (of course equal to number of chapters in the book) */\n endChapter: number;\n /** The chapter number that is currently selected */\n activeChapter: number;\n /** The chapter number that is currently highlighted using keyboard or mouse navigation */\n highlightedChapter: number;\n /**\n * Callback to run when a chapter is highlighted by the user\n *\n * @param chapterNumber The chapter that is highlighted\n */\n handleHighlightedChapter: (chapterNumber: number) => void;\n};\n\nfunction ChapterSelect({\n handleSelectChapter,\n endChapter,\n activeChapter,\n highlightedChapter,\n handleHighlightedChapter,\n}: ChapterSelectProps) {\n const chapters = Array.from({ length: endChapter }, (_, i) => i + 1);\n\n const handleMouse = useCallback(\n (chapterNumber: number) => {\n handleHighlightedChapter(chapterNumber);\n },\n [handleHighlightedChapter],\n );\n\n return (\n
    \n {chapters.map((chapter) => (\n {\n event.preventDefault();\n event.stopPropagation();\n handleSelectChapter(chapter);\n }}\n role=\"button\"\n onKeyDown={(event) => {\n if (event.key === 'Enter') {\n handleSelectChapter(chapter);\n }\n }}\n tabIndex={0}\n onMouseMove={() => handleMouse(chapter)}\n >\n {chapter}\n
    \n ))}\n
    \n );\n}\n\nexport default ChapterSelect;\n","import { DropdownMenuLabel as ShadDropdownMenuLabel } from '@/components/shadcn-ui/dropdown-menu';\nimport { Bookmark, Clock, ArrowDownWideNarrow } from 'lucide-react';\n\nexport type GoToMenuItemProps = {\n handleSort: () => void;\n handleLocationHistory: () => void;\n handleBookmarks: () => void;\n};\n\nfunction GoToMenuItem({ handleSort, handleLocationHistory, handleBookmarks }: GoToMenuItemProps) {\n return (\n \n

    Go To

    \n
    \n \n \n \n
    \n
    \n );\n}\n\nexport default GoToMenuItem;\n","import BookChapterInput from '@/components/advanced/book-chapter-control/book-chapter-input.component';\nimport BookMenuItem, {\n BookType,\n} from '@/components/advanced/book-chapter-control/book-menu-item.component';\nimport ChapterSelect from '@/components/advanced/book-chapter-control/chapter-select.component';\nimport GoToMenuItem from '@/components/advanced/book-chapter-control/go-to-menu-item.component';\nimport {\n DropdownMenu as ShadDropdownMenu,\n DropdownMenuContent as ShadDropdownMenuContent,\n DropdownMenuLabel as ShadDropdownMenuLabel,\n DropdownMenuSeparator as ShadDropdownMenuSeparator,\n DropdownMenuTrigger as ShadDropdownMenuTrigger,\n} from '@/components/shadcn-ui/dropdown-menu';\nimport { Canon } from '@sillsdev/scripture';\nimport { ScriptureReference, getChaptersForBook } from 'platform-bible-utils';\nimport {\n KeyboardEvent as ReactKeyboardEvent,\n useCallback,\n useEffect,\n useLayoutEffect,\n useRef,\n useState,\n} from 'react';\n\ntype BookTypeLabels = {\n [bookType in BookType]: string;\n};\ntype BookChapterControlProps = {\n scrRef: ScriptureReference;\n handleSubmit: (scrRef: ScriptureReference) => void;\n};\n\nconst ALL_BOOK_IDS = Canon.allBookIds;\nconst BOOK_TYPE_LABELS: BookTypeLabels = {\n OT: 'Old Testament',\n NT: 'New Testament',\n DC: 'Deuterocanon',\n};\nconst BOOK_TYPE_ARRAY: BookType[] = ['OT', 'NT', 'DC'];\n// This is the height of three menu items to offset scrolling to the selected menu item\n// If you use menuItemRef.clientHeight- includes height of chapter div which is too big\nconst SCROLL_OFFSET = 32 + 32 + 32;\nconst SEARCH_QUERY_FORMATS = [\n /^(\\w+)$/i, // Matches a single word (book name or id)\n /^(\\w+)(?:\\s(\\d+))$/i, // Matches a word followed by a chapter number\n /^(\\w+)(?:\\s(\\d+):(\\d+))$/i, // Matches a word followed by a chapter and verse number\n];\nconst fetchGroupedBooks = (bookType: BookType) => {\n const groupedBooks = {\n OT: ALL_BOOK_IDS.filter((bookId) => Canon.isBookOT(bookId)),\n NT: ALL_BOOK_IDS.filter((bookId) => Canon.isBookNT(bookId)),\n DC: ALL_BOOK_IDS.filter((bookId) => Canon.isBookDC(bookId)),\n };\n return groupedBooks[bookType];\n};\nconst fetchEndChapter = (bookId: string) => {\n // getChaptersForBook returns -1 if not found in scrBookData\n // scrBookData only includes OT and NT, so all DC will return -1\n return getChaptersForBook(Canon.bookIdToNumber(bookId));\n};\n\n/**\n * Gets all of the English names from book ids\n *\n * @returns String[]\n */\nfunction getAllEnglishNames(): string[] {\n const allEnglishNames = ALL_BOOK_IDS.map((bookId) => {\n return Canon.bookIdToEnglishName(bookId);\n });\n return allEnglishNames;\n}\n\n/**\n * Determines if bookName is in allEnglishNames\n *\n * @param bookName Book English name\n * @returns True if bookName is included, false otherwise\n */\nfunction isValidBookEnglishName(bookName: string): boolean {\n return getAllEnglishNames().includes(bookName);\n}\n\n/**\n * Gets a bookId from given English name\n *\n * @param bookName Book English name\n * @returns BookId of provided bookName, undefined otherwise\n */\nfunction getBookIdFromEnglishName(bookName: string): string | undefined {\n // Convert bookName to lowercase and then capitalize the first letter\n const formattedBookName = bookName.toLowerCase().replace(/^\\w/, (c) => c.toUpperCase());\n\n if (isValidBookEnglishName(formattedBookName)) {\n const matchingBookId = ALL_BOOK_IDS.find((bookId) => {\n return Canon.bookIdToEnglishName(bookId) === formattedBookName;\n });\n return matchingBookId;\n }\n\n return undefined;\n}\n\nfunction BookChapterControl({ scrRef, handleSubmit }: BookChapterControlProps) {\n const [searchQuery, setSearchQuery] = useState('');\n const [selectedBookId, setSelectedBookId] = useState(\n Canon.bookNumberToId(scrRef.bookNum),\n );\n const [highlightedChapter, setHighlightedChapter] = useState(scrRef.chapterNum ?? 0);\n const [highlightedBookId, setHighlightedBookId] = useState(\n Canon.bookNumberToId(scrRef.bookNum),\n );\n const [isContentOpen, setIsContentOpen] = useState(false);\n const [isContentOpenDelayed, setIsContentOpenDelayed] = useState(isContentOpen);\n\n // This ref will always be defined\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const inputRef = useRef(undefined!);\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const contentRef = useRef(undefined!);\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const menuItemRef = useRef(undefined!);\n\n const fetchFilteredBooks = useCallback(\n (bookType: BookType) => {\n return fetchGroupedBooks(bookType).filter((bookId: string) => {\n const englishNameLowerCase = Canon.bookIdToEnglishName(bookId).toLowerCase();\n const normalizedQuery = searchQuery.replace(/[^a-zA-Z]/g, '').toLowerCase();\n return (\n englishNameLowerCase.includes(normalizedQuery) || // Match book name\n bookId.toLowerCase().includes(normalizedQuery) // Match book ID\n );\n });\n },\n [searchQuery],\n );\n\n const handleSearchInput = (searchString: string) => {\n setSearchQuery(searchString);\n };\n\n /**\n * Whether to prevent radix's logic from closing the dropdown. This is important because radix\n * tries to close the dropdown when the input first focuses, and we don't want it to do that. But\n * we don't want to prevent the dropdown from closing when we click away from the input, so we\n * don't want to just keep it open if the input is focused\n */\n const shouldPreventAutoClosing = useRef(false);\n\n const controlMenuState = useCallback((open: boolean) => {\n if (shouldPreventAutoClosing.current) {\n shouldPreventAutoClosing.current = false;\n return;\n }\n setIsContentOpen(open);\n }, []);\n\n const updateReference = useCallback(\n (bookId: string, shouldClose: boolean, chapter?: number, verse?: number) => {\n setHighlightedChapter(\n Canon.bookNumberToId(scrRef.bookNum) !== bookId ? 1 : scrRef.chapterNum,\n );\n\n if (shouldClose || fetchEndChapter(bookId) === -1) {\n handleSubmit({\n bookNum: Canon.bookIdToNumber(bookId),\n chapterNum: chapter || 1,\n verseNum: verse || 1,\n });\n\n setIsContentOpen(false);\n setSearchQuery('');\n return;\n }\n\n setSelectedBookId(selectedBookId !== bookId ? bookId : '');\n setIsContentOpen(!shouldClose);\n },\n [handleSubmit, scrRef.bookNum, scrRef.chapterNum, selectedBookId],\n );\n\n const handleSelectChapter = (chapterNumber: number) => {\n if (chapterNumber <= 0 || chapterNumber > fetchEndChapter(selectedBookId)) {\n return;\n }\n updateReference(selectedBookId, true, chapterNumber);\n };\n\n const handleInputSubmit = useCallback(() => {\n SEARCH_QUERY_FORMATS.forEach((format) => {\n const matches = searchQuery.match(format);\n if (matches) {\n // Book should be a bookId or an english name\n const [book, chapter = undefined, verse = undefined] = matches.slice(1);\n const englishName = getBookIdFromEnglishName(book);\n\n if (Canon.isBookIdValid(book) || englishName) {\n updateReference(\n englishName ?? book,\n true,\n chapter ? parseInt(chapter, 10) : 1,\n verse ? parseInt(verse, 10) : 1,\n );\n }\n }\n });\n }, [updateReference, searchQuery]);\n\n const handleKeyDownInput = useCallback(\n (event: ReactKeyboardEvent) => {\n if (!isContentOpen) {\n setIsContentOpen(true);\n } else if (event.key === 'ArrowDown' || event.key === 'ArrowUp') {\n if (\n typeof menuItemRef !== 'undefined' &&\n // Ref uses null\n // eslint-disable-next-line no-null/no-null\n menuItemRef.current !== null\n ) {\n menuItemRef.current.focus();\n } else if (\n typeof contentRef !== 'undefined' &&\n // Ref uses null\n // eslint-disable-next-line no-null/no-null\n contentRef.current !== null\n ) {\n contentRef.current.focus();\n }\n event.preventDefault();\n }\n },\n [isContentOpen],\n );\n\n const handleKeyDownContent = (event: ReactKeyboardEvent) => {\n // When the dropdown menu has focus, key strokes should give focus to the input component,\n // unless they're navigation keys (arrows and enter)\n const { key } = event;\n if (\n key === 'ArrowRight' ||\n key === 'ArrowLeft' ||\n key === 'ArrowDown' ||\n key === 'ArrowUp' ||\n key === 'Enter'\n ) {\n return;\n }\n\n inputRef.current.dispatchEvent(new KeyboardEvent('keydown', { key }));\n inputRef.current.focus();\n };\n\n const handleKeyDownMenuItem = (event: ReactKeyboardEvent) => {\n const { key } = event;\n if (highlightedBookId === selectedBookId) {\n if (key === 'Enter') {\n event.preventDefault();\n updateReference(selectedBookId, true, highlightedChapter);\n return;\n }\n\n let chapterOffSet = 0;\n if (key === 'ArrowRight') {\n if (highlightedChapter < fetchEndChapter(highlightedBookId)) {\n chapterOffSet = 1;\n } else {\n event.preventDefault();\n return;\n }\n } else if (key === 'ArrowLeft') {\n if (highlightedChapter > 1) {\n chapterOffSet = -1;\n } else {\n event.preventDefault();\n return;\n }\n } else if (key === 'ArrowDown') {\n chapterOffSet = 6;\n } else if (key === 'ArrowUp') {\n chapterOffSet = -6;\n }\n if (\n highlightedChapter + chapterOffSet <= 0 ||\n highlightedChapter + chapterOffSet > fetchEndChapter(highlightedBookId)\n ) {\n setHighlightedChapter(0);\n } else if (chapterOffSet !== 0) {\n setHighlightedChapter(highlightedChapter + chapterOffSet);\n event.preventDefault();\n }\n }\n };\n\n useEffect(() => {\n if (selectedBookId === highlightedBookId) {\n if (selectedBookId === Canon.bookNumberToId(scrRef.bookNum)) {\n setHighlightedChapter(scrRef.chapterNum);\n } else {\n setHighlightedChapter(1);\n }\n } else {\n setHighlightedChapter(0);\n }\n }, [highlightedBookId, scrRef.bookNum, scrRef.chapterNum, selectedBookId]);\n\n // The purpose of these useLayoutEffects and timeout is to delay the scroll just\n // enough so that the refs are defined and available when they are used after the timeout\n useLayoutEffect(() => {\n setIsContentOpenDelayed(isContentOpen);\n }, [isContentOpen]);\n\n useLayoutEffect(() => {\n const scrollTimeout = setTimeout(() => {\n if (isContentOpenDelayed && contentRef.current && menuItemRef.current) {\n const menuItemOffsetTop = menuItemRef.current.offsetTop;\n const scrollPosition = menuItemOffsetTop - SCROLL_OFFSET;\n contentRef.current.scrollTo({ top: scrollPosition, behavior: 'instant' });\n }\n }, 10);\n return () => {\n clearTimeout(scrollTimeout);\n };\n }, [isContentOpenDelayed]);\n\n return (\n
    \n \n \n {\n setSelectedBookId(Canon.bookNumberToId(scrRef.bookNum));\n setHighlightedBookId(Canon.bookNumberToId(scrRef.bookNum));\n setHighlightedChapter(scrRef.chapterNum > 0 ? scrRef.chapterNum : 0);\n setIsContentOpen(true);\n inputRef.current.focus();\n }}\n onFocus={() => {\n // Radix thinks we want to close because the input is being focused. Prevent that\n shouldPreventAutoClosing.current = true;\n }}\n handleSubmit={handleInputSubmit}\n placeholder={`${Canon.bookNumberToEnglishName(scrRef.bookNum)} ${scrRef.chapterNum}:${scrRef.verseNum}`}\n />\n \n \n console.log('sorting')}\n handleLocationHistory={() => console.log('location history')}\n handleBookmarks={() => console.log('bookmarks')}\n />\n {BOOK_TYPE_ARRAY.map(\n (bookType, bookTypeIndex) =>\n fetchFilteredBooks(bookType).length > 0 && (\n
    \n \n {BOOK_TYPE_LABELS[bookType]}\n \n\n {fetchFilteredBooks(bookType).map((bookId) => (\n
    \n updateReference(bookId, false)}\n isSelected={selectedBookId === bookId}\n handleHighlightBook={() => setHighlightedBookId(bookId)}\n handleKeyDown={handleKeyDownMenuItem}\n bookType={bookType}\n ref={(element: HTMLDivElement) => {\n if (selectedBookId === bookId) menuItemRef.current = element;\n }}\n >\n {\n setHighlightedChapter(chapterNumber);\n }}\n />\n \n
    \n ))}\n {BOOK_TYPE_ARRAY.length - 1 !== bookTypeIndex ? (\n \n ) : undefined}\n
    \n ),\n )}\n \n
    \n
    \n );\n}\n\nexport default BookChapterControl;\n","import React from 'react';\nimport { Slot } from '@radix-ui/react-slot';\nimport { cva, type VariantProps } from 'class-variance-authority';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport const buttonVariants = cva(\n 'pr-twp tw-inline-flex tw-items-center tw-justify-center tw-whitespace-nowrap tw-rounded-md tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-colors focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50',\n {\n variants: {\n variant: {\n default: 'tw-bg-primary tw-text-primary-foreground hover:tw-bg-primary/90',\n destructive: 'tw-bg-destructive tw-text-destructive-foreground hover:tw-bg-destructive/90',\n outline:\n 'tw-border tw-border-input tw-bg-background hover:tw-bg-accent hover:tw-text-accent-foreground',\n secondary: 'tw-bg-secondary tw-text-secondary-foreground hover:tw-bg-secondary/80',\n ghost: 'hover:tw-bg-accent hover:tw-text-accent-foreground',\n link: 'tw-text-primary tw-underline-offset-4 hover:tw-underline',\n },\n size: {\n default: 'tw-h-10 tw-px-4 tw-py-2',\n sm: 'tw-h-9 tw-rounded-md tw-px-3',\n lg: 'tw-h-11 tw-rounded-md tw-px-8',\n icon: 'tw-h-10 tw-w-10',\n },\n },\n defaultVariants: {\n variant: 'default',\n size: 'default',\n },\n },\n);\n\nexport interface ButtonProps\n extends React.ButtonHTMLAttributes,\n VariantProps {\n asChild?: boolean;\n}\n\nexport const Button = React.forwardRef(\n ({ className, variant, size, asChild = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'button';\n return (\n \n );\n },\n);\nButton.displayName = 'Button';\n","import React from 'react';\nimport * as LabelPrimitive from '@radix-ui/react-label';\nimport { cva, type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst labelVariants = cva(\n 'tw-text-sm tw-font-medium tw-leading-none peer-disabled:tw-cursor-not-allowed peer-disabled:tw-opacity-70',\n);\n\nexport const Label = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef & VariantProps\n>(({ className, ...props }, ref) => (\n \n));\nLabel.displayName = LabelPrimitive.Root.displayName;\n","import React from 'react';\nimport * as RadioGroupPrimitive from '@radix-ui/react-radio-group';\nimport { Circle } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst RadioGroup = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => {\n return (\n \n );\n});\nRadioGroup.displayName = RadioGroupPrimitive.Root.displayName;\n\nconst RadioGroupItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => {\n return (\n \n \n \n \n \n );\n});\nRadioGroupItem.displayName = RadioGroupPrimitive.Item.displayName;\n\nexport { RadioGroup, RadioGroupItem };\n","import React from 'react';\nimport * as PopoverPrimitive from '@radix-ui/react-popover';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Popover = PopoverPrimitive.Root;\n\nconst PopoverTrigger = PopoverPrimitive.Trigger;\n\nconst PopoverContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, align = 'center', sideOffset = 4, ...props }, ref) => (\n \n \n \n));\nPopoverContent.displayName = PopoverPrimitive.Content.displayName;\n\nexport { Popover, PopoverTrigger, PopoverContent };\n","import React from 'react';\nimport * as DialogPrimitive from '@radix-ui/react-dialog';\nimport { X } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Dialog = DialogPrimitive.Root;\n\nconst DialogTrigger = DialogPrimitive.Trigger;\n\nconst DialogPortal = DialogPrimitive.Portal;\n\nconst DialogClose = DialogPrimitive.Close;\n\nconst DialogOverlay = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nDialogOverlay.displayName = DialogPrimitive.Overlay.displayName;\n\nconst DialogContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, ...props }, ref) => (\n \n \n \n {children}\n \n \n Close\n \n \n \n));\nDialogContent.displayName = DialogPrimitive.Content.displayName;\n\nfunction DialogHeader({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nDialogHeader.displayName = 'DialogHeader';\n\nfunction DialogFooter({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nDialogFooter.displayName = 'DialogFooter';\n\nconst DialogTitle = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nDialogTitle.displayName = DialogPrimitive.Title.displayName;\n\nconst DialogDescription = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nDialogDescription.displayName = DialogPrimitive.Description.displayName;\n\nexport {\n Dialog,\n DialogPortal,\n DialogOverlay,\n DialogClose,\n DialogTrigger,\n DialogContent,\n DialogHeader,\n DialogFooter,\n DialogTitle,\n DialogDescription,\n};\n","import React from 'react';\nimport { type DialogProps } from '@radix-ui/react-dialog';\nimport { Command as CommandPrimitive } from 'cmdk';\nimport { Search } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Dialog, DialogContent } from '@/components/shadcn-ui/dialog';\n\nconst Command = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nCommand.displayName = CommandPrimitive.displayName;\n\ninterface CommandDialogProps extends DialogProps {}\n\nfunction CommandDialog({ children, ...props }: CommandDialogProps) {\n return (\n \n \n \n {children}\n \n \n \n );\n}\n\nconst CommandInput = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n
    \n \n \n
    \n));\n\nCommandInput.displayName = CommandPrimitive.Input.displayName;\n\nconst CommandList = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\n\nCommandList.displayName = CommandPrimitive.List.displayName;\n\nconst CommandEmpty = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>((props, ref) => (\n \n));\n\nCommandEmpty.displayName = CommandPrimitive.Empty.displayName;\n\nconst CommandGroup = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\n\nCommandGroup.displayName = CommandPrimitive.Group.displayName;\n\nconst CommandSeparator = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nCommandSeparator.displayName = CommandPrimitive.Separator.displayName;\n\nconst CommandItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\n\nCommandItem.displayName = CommandPrimitive.Item.displayName;\n\nfunction CommandShortcut({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nCommandShortcut.displayName = 'CommandShortcut';\n\nexport {\n Command,\n CommandDialog,\n CommandInput,\n CommandList,\n CommandEmpty,\n CommandGroup,\n CommandItem,\n CommandShortcut,\n CommandSeparator,\n};\n","import { useState } from 'react';\nimport { Check, ChevronsUpDown } from 'lucide-react';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport { Popover, PopoverContent, PopoverTrigger } from '@/components/shadcn-ui/popover';\nimport {\n Command,\n CommandEmpty,\n CommandInput,\n CommandItem,\n CommandList,\n} from '@/components/shadcn-ui/command';\nimport { PopoverProps } from '@radix-ui/react-popover';\n\nexport type ComboBoxLabelOption = { label: string };\nexport type ComboBoxOption = string | number | ComboBoxLabelOption;\n\nexport type ComboBoxProps = {\n /** Optional unique identifier */\n id?: string;\n /** Text label title for combobox */\n /** List of available options for the dropdown menu */\n options?: readonly T[];\n /** Additional css classes to help with unique styling of the combo box button */\n buttonClassName?: string;\n /** Additional css classes to help with unique styling of the combo box popover */\n popoverContentClassName?: string;\n /**\n * The selected value that the combo box currently holds. Must be shallow equal to one of the\n * options entries.\n */\n value?: T;\n /** Triggers when content of textfield is changed */\n onChange?: (newValue: T) => void;\n /** Used to determine the string value for a given option. */\n getOptionLabel?: (option: ComboBoxOption) => string;\n /** Text displayed on button if `value` is undefined */\n buttonPlaceholder?: string;\n /** Placeholder text for text field */\n textPlaceholder?: string;\n /** Text to display when no options match input */\n commandEmptyMessage?: string;\n /** Variant of button */\n buttonVariant?: ButtonProps['variant'];\n /** Text direction ltr or rtl */\n dir?: Direction;\n /** Optional boolean to set if trigger should be disabled */\n isDisabled?: boolean;\n} & PopoverProps;\n\ntype Direction = 'ltr' | 'rtl';\n\nfunction getOptionLabelDefault(option: ComboBoxOption): string {\n if (typeof option === 'string') {\n return option;\n }\n if (typeof option === 'number') {\n return option.toString();\n }\n return option.label;\n}\n\n/**\n * Autocomplete input and command palette with a list of suggestions.\n *\n * Thanks to Shadcn for heavy inspiration and documentation\n * https://ui.shadcn.com/docs/components/combobox\n */\nfunction ComboBox({\n id,\n options = [],\n buttonClassName,\n popoverContentClassName,\n value,\n onChange = () => {},\n getOptionLabel = getOptionLabelDefault,\n buttonPlaceholder = '',\n textPlaceholder = '',\n commandEmptyMessage = 'No option found',\n buttonVariant = 'outline',\n dir = 'ltr',\n isDisabled = false,\n ...props\n}: ComboBoxProps) {\n const [open, setOpen] = useState(false);\n\n return (\n \n \n \n \n {value ? getOptionLabel(value) : buttonPlaceholder}\n \n \n \n \n \n \n \n {commandEmptyMessage}\n \n {options.map((option) => (\n {\n onChange(option);\n setOpen(false);\n }}\n >\n \n {getOptionLabel(option)}\n \n ))}\n \n \n \n \n );\n}\n\nexport default ComboBox;\n","import { useMemo } from 'react';\nimport ComboBox from '@/components/basics/combo-box.component';\nimport { Label } from '@/components/shadcn-ui/label';\n\nexport type ChapterRangeSelectorProps = {\n startChapter: number;\n endChapter: number;\n handleSelectStartChapter: (chapter: number) => void;\n handleSelectEndChapter: (chapter: number) => void;\n isDisabled?: boolean;\n chapterCount: number;\n};\n\nexport default function ChapterRangeSelector({\n startChapter,\n endChapter,\n handleSelectStartChapter,\n handleSelectEndChapter,\n isDisabled = false,\n chapterCount,\n}: ChapterRangeSelectorProps) {\n const chapterOptions = useMemo(\n () => Array.from({ length: chapterCount }, (_, index) => index + 1),\n [chapterCount],\n );\n\n const onChangeStartChapter = (value: number) => {\n handleSelectStartChapter(value);\n if (value > endChapter) {\n handleSelectEndChapter(value);\n }\n };\n\n const onChangeEndChapter = (value: number) => {\n handleSelectEndChapter(value);\n if (value < startChapter) {\n handleSelectStartChapter(value);\n }\n };\n\n return (\n <>\n \n option.toString()}\n value={startChapter}\n />\n\n \n option.toString()}\n value={endChapter}\n />\n \n );\n}\n","import { Button } from '@/components/shadcn-ui/button';\nimport { Label } from '@/components/shadcn-ui/label';\nimport { RadioGroup, RadioGroupItem } from '@/components/shadcn-ui/radio-group';\nimport { Canon } from '@sillsdev/scripture';\nimport { LocalizedStringValue } from 'platform-bible-utils';\nimport { useState } from 'react';\nimport ChapterRangeSelector, {\n ChapterRangeSelectorProps,\n} from '../basics/chapter-range-selector.component';\n\nexport enum BookSelectionMode {\n CURRENT_BOOK = 'current book',\n CHOOSE_BOOKS = 'choose books',\n}\n\n/**\n * Object containing all keys used for localization in this component. If you're using this\n * component in an extension, you can pass it into the useLocalizedStrings hook to easily obtain the\n * localized strings and pass them into the localizedStrings prop of this component\n */\nexport const BOOK_SELECTOR_STRING_KEYS = Object.freeze([\n '%webView_bookSelector_currentBook%',\n '%webView_bookSelector_choose%',\n '%webView_bookSelector_chooseBooks%',\n] as const);\n\nexport type BookSelectorLocalizedStrings = {\n [localizedInventoryKey in (typeof BOOK_SELECTOR_STRING_KEYS)[number]]?: LocalizedStringValue;\n};\n\n/**\n * Gets the localized value for the provided key\n *\n * @param strings Object containing localized string\n * @param key Key for a localized string\n * @returns The localized value for the provided key, if available. Returns the key if no localized\n * value is available\n */\nconst localizeString = (\n strings: BookSelectorLocalizedStrings,\n key: keyof BookSelectorLocalizedStrings,\n) => {\n return strings[key] ?? key;\n};\n\ntype BookSelectorProps = ChapterRangeSelectorProps & {\n handleBookSelectionModeChange: (newMode: BookSelectionMode) => void;\n currentBookName: string;\n onSelectBooks: () => void;\n selectedBookIds: string[];\n localizedStrings: BookSelectorLocalizedStrings;\n};\n\nexport default function BookSelector({\n handleBookSelectionModeChange,\n currentBookName,\n onSelectBooks,\n selectedBookIds,\n chapterCount,\n endChapter,\n handleSelectEndChapter,\n startChapter,\n handleSelectStartChapter,\n localizedStrings,\n}: BookSelectorProps) {\n const currentBookText = localizeString(localizedStrings, '%webView_bookSelector_currentBook%');\n const chooseText = localizeString(localizedStrings, '%webView_bookSelector_choose%');\n const chooseBooksText = localizeString(localizedStrings, '%webView_bookSelector_chooseBooks%');\n\n const [bookSelectionMode, setBookSelectionMode] = useState(\n BookSelectionMode.CURRENT_BOOK,\n );\n\n const onSelectionModeChange = (newMode: BookSelectionMode) => {\n setBookSelectionMode(newMode);\n handleBookSelectionModeChange(newMode);\n };\n\n return (\n onSelectionModeChange(value as BookSelectionMode)}\n >\n
    \n
    \n
    \n \n \n
    \n \n
    \n \n
    \n
    \n
    \n
    \n \n \n
    \n \n onSelectBooks()}\n >\n {chooseText}\n \n
    \n
    \n \n );\n}\n","import { DropdownMenuTrigger } from '@radix-ui/react-dropdown-menu';\nimport { FilterIcon } from 'lucide-react';\nimport { Table } from '@tanstack/react-table';\n\nimport { Button } from '@/components/shadcn-ui/button';\nimport {\n DropdownMenu,\n DropdownMenuCheckboxItem,\n DropdownMenuContent,\n DropdownMenuLabel,\n DropdownMenuSeparator,\n} from '@/components/shadcn-ui/dropdown-menu';\n\ninterface DataTableViewOptionsProps {\n table: Table;\n}\n\nfunction DataTableViewOptions({ table }: DataTableViewOptionsProps) {\n return (\n \n \n \n \n \n Toggle columns\n \n {table\n .getAllColumns()\n .filter((column) => column.getCanHide())\n .map((column) => {\n return (\n column.toggleVisibility(!!value)}\n >\n {column.id}\n \n );\n })}\n \n \n );\n}\n\nexport default DataTableViewOptions;\n","import React from 'react';\nimport * as SelectPrimitive from '@radix-ui/react-select';\nimport { Check, ChevronDown, ChevronUp } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Select = SelectPrimitive.Root;\n\nconst SelectGroup = SelectPrimitive.Group;\n\nconst SelectValue = SelectPrimitive.Value;\n\nconst SelectTrigger = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, ...props }, ref) => (\n span]:tw-line-clamp-1',\n className,\n )}\n {...props}\n >\n {children}\n \n \n \n \n));\nSelectTrigger.displayName = SelectPrimitive.Trigger.displayName;\n\nconst SelectScrollUpButton = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n));\nSelectScrollUpButton.displayName = SelectPrimitive.ScrollUpButton.displayName;\n\nconst SelectScrollDownButton = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n));\nSelectScrollDownButton.displayName = SelectPrimitive.ScrollDownButton.displayName;\n\nconst SelectContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, position = 'popper', ...props }, ref) => (\n \n \n \n \n {children}\n \n \n \n \n));\nSelectContent.displayName = SelectPrimitive.Content.displayName;\n\nconst SelectLabel = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSelectLabel.displayName = SelectPrimitive.Label.displayName;\n\nconst SelectItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, ...props }, ref) => (\n \n \n \n \n \n \n\n {children}\n \n));\nSelectItem.displayName = SelectPrimitive.Item.displayName;\n\nconst SelectSeparator = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSelectSeparator.displayName = SelectPrimitive.Separator.displayName;\n\nexport {\n Select,\n SelectGroup,\n SelectValue,\n SelectTrigger,\n SelectContent,\n SelectLabel,\n SelectItem,\n SelectSeparator,\n SelectScrollUpButton,\n SelectScrollDownButton,\n};\n","import { ChevronLeftIcon, ChevronRightIcon, ArrowLeftIcon, ArrowRightIcon } from 'lucide-react';\nimport { Table } from '@tanstack/react-table';\n\nimport { Button } from '@/components/shadcn-ui/button';\nimport {\n Select,\n SelectContent,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\n\ninterface DataTablePaginationProps {\n table: Table;\n}\n\nfunction DataTablePagination({ table }: DataTablePaginationProps) {\n return (\n
    \n
    \n
    \n {table.getFilteredSelectedRowModel().rows.length} of{' '}\n {table.getFilteredRowModel().rows.length} row(s) selected\n
    \n
    \n

    Rows per page

    \n {\n table.setPageSize(Number(value));\n }}\n >\n \n \n \n \n {[10, 20, 30, 40, 50].map((pageSize) => (\n \n {pageSize}\n \n ))}\n \n \n
    \n
    \n Page {table.getState().pagination.pageIndex + 1} of {table.getPageCount()}\n
    \n
    \n table.setPageIndex(0)}\n disabled={!table.getCanPreviousPage()}\n >\n Go to first page\n \n \n table.previousPage()}\n disabled={!table.getCanPreviousPage()}\n >\n Go to previous page\n \n \n table.nextPage()}\n disabled={!table.getCanNextPage()}\n >\n Go to next page\n \n \n table.setPageIndex(table.getPageCount() - 1)}\n disabled={!table.getCanNextPage()}\n >\n Go to last page\n \n \n
    \n
    \n
    \n );\n}\n\nexport default DataTablePagination;\n","import React from 'react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Table = React.forwardRef<\n HTMLTableElement,\n React.HTMLAttributes & { stickyHeader?: boolean }\n>(({ className, stickyHeader, ...props }, ref) => (\n
    \n \n
    \n));\nTable.displayName = 'Table';\n\nconst TableHeader = React.forwardRef<\n HTMLTableSectionElement,\n React.HTMLAttributes & { stickyHeader?: boolean }\n>(({ className, stickyHeader, ...props }, ref) => (\n \n));\nTableHeader.displayName = 'TableHeader';\n\nconst TableBody = React.forwardRef<\n HTMLTableSectionElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableBody.displayName = 'TableBody';\n\nconst TableFooter = React.forwardRef<\n HTMLTableSectionElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n tr]:last:tw-border-b-0', className)}\n {...props}\n />\n));\nTableFooter.displayName = 'TableFooter';\n\nconst TableRow = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nTableRow.displayName = 'TableRow';\n\nconst TableHead = React.forwardRef<\n HTMLTableCellElement,\n React.ThHTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableHead.displayName = 'TableHead';\n\nconst TableCell = React.forwardRef<\n HTMLTableCellElement,\n React.TdHTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableCell.displayName = 'TableCell';\n\nconst TableCaption = React.forwardRef<\n HTMLTableCaptionElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableCaption.displayName = 'TableCaption';\n\nexport { Table, TableHeader, TableBody, TableFooter, TableHead, TableRow, TableCell, TableCaption };\n","import { useState } from 'react';\n\nimport {\n ColumnFiltersState,\n flexRender,\n getCoreRowModel,\n getFilteredRowModel,\n getPaginationRowModel,\n getSortedRowModel,\n SortingState,\n ColumnDef as TSColumnDef,\n Row as TSRow,\n RowSelectionState as TSRowSelectionState,\n SortDirection as TSSortDirection,\n Table as TSTable,\n useReactTable,\n VisibilityState,\n} from '@tanstack/react-table';\n\nimport DataTableViewOptions from '@/components/advanced/data-table/data-table-column-toggle.component';\nimport DataTablePagination from '@/components/advanced/data-table/data-table-pagination.component';\nimport { Button } from '@/components/shadcn-ui/button';\nimport {\n Table,\n TableBody,\n TableCell,\n TableHead,\n TableHeader,\n TableRow,\n} from '@/components/shadcn-ui/table';\n\nexport type ColumnDef = TSColumnDef;\nexport type RowContents = TSRow;\nexport type TableContents = TSTable;\nexport type SortDirection = TSSortDirection;\nexport type RowSelectionState = TSRowSelectionState;\n\ninterface DataTableProps {\n columns: ColumnDef[];\n data: TData[];\n enablePagination?: boolean;\n showPaginationControls?: boolean;\n showColumnVisibilityControls?: boolean;\n stickyHeader?: boolean;\n onRowClickHandler?: (row: RowContents, table: TableContents) => void;\n}\n\n/**\n * Feature-rich table component that infuses our basic shadcn-based Table component with features\n * from TanStack's React Table library\n */\nfunction DataTable({\n columns,\n data,\n enablePagination = false,\n showPaginationControls = false,\n showColumnVisibilityControls = false,\n stickyHeader = false,\n onRowClickHandler = () => {},\n}: DataTableProps) {\n const [sorting, setSorting] = useState([]);\n const [columnFilters, setColumnFilters] = useState([]);\n const [columnVisibility, setColumnVisibility] = useState({});\n const [rowSelection, setRowSelection] = useState({});\n\n const table = useReactTable({\n data,\n columns,\n getCoreRowModel: getCoreRowModel(),\n ...(enablePagination && { getPaginationRowModel: getPaginationRowModel() }),\n onSortingChange: setSorting,\n getSortedRowModel: getSortedRowModel(),\n onColumnFiltersChange: setColumnFilters,\n getFilteredRowModel: getFilteredRowModel(),\n onColumnVisibilityChange: setColumnVisibility,\n onRowSelectionChange: setRowSelection,\n state: {\n sorting,\n columnFilters,\n columnVisibility,\n rowSelection,\n },\n });\n\n return (\n
    \n {showColumnVisibilityControls && }\n \n \n {table.getHeaderGroups().map((headerGroup) => (\n \n {headerGroup.headers.map((header) => {\n return (\n \n {header.isPlaceholder\n ? undefined\n : flexRender(header.column.columnDef.header, header.getContext())}\n \n );\n })}\n \n ))}\n \n \n {table.getRowModel().rows?.length ? (\n table.getRowModel().rows.map((row) => (\n onRowClickHandler(row, table)}\n key={row.id}\n data-state={row.getIsSelected() && 'selected'}\n >\n {row.getVisibleCells().map((cell) => (\n \n {flexRender(cell.column.columnDef.cell, cell.getContext())}\n \n ))}\n \n ))\n ) : (\n \n \n No results.\n \n \n )}\n \n
    \n {enablePagination && (\n
    \n table.previousPage()}\n disabled={!table.getCanPreviousPage()}\n >\n Previous\n \n table.nextPage()}\n disabled={!table.getCanNextPage()}\n >\n Next\n \n
    \n )}\n {enablePagination && showPaginationControls && }\n
    \n );\n}\n\nexport default DataTable;\n","import {\n Table,\n TableBody,\n TableCell,\n TableHead,\n TableHeader,\n TableRow,\n} from '@/components/shadcn-ui/table';\nimport { Canon } from '@sillsdev/scripture';\nimport { deepEqual, LanguageStrings, ScriptureReference } from 'platform-bible-utils';\nimport { useMemo } from 'react';\nimport { InventoryItemOccurrence } from './inventory-utils';\n\n/** Props for the OccurrencesTable component */\ntype OccurrencesTableProps = {\n /** Data that contains scriptures references and snippets of scripture */\n occurrenceData: InventoryItemOccurrence[];\n /** Callback function that is executed when the scripture reference is changed */\n setScriptureReference: (scriptureReference: ScriptureReference) => void;\n /**\n * Object with all localized strings that the OccurrencesTable needs to work well across multiple\n * languages\n */\n localizedStrings: LanguageStrings;\n};\n\n/**\n * Table that shows occurrences of specified inventory item(s). The first column shows the related\n * scripture reference. The second column shows the snippet of scripture that contains the specified\n * inventory item\n */\nfunction OccurrencesTable({\n occurrenceData,\n setScriptureReference,\n localizedStrings,\n}: OccurrencesTableProps) {\n const referenceHeaderText =\n localizedStrings['%webView_inventory_occurrences_table_header_reference%'];\n const occurrenceHeaderText =\n localizedStrings['%webView_inventory_occurrences_table_header_occurrence%'];\n\n const occurrences: InventoryItemOccurrence[] = useMemo(() => {\n const uniqueOccurrences: InventoryItemOccurrence[] = [];\n\n occurrenceData.forEach((occurrence) => {\n if (!uniqueOccurrences.some((uniqueOccurrence) => deepEqual(uniqueOccurrence, occurrence))) {\n uniqueOccurrences.push(occurrence);\n }\n });\n\n return uniqueOccurrences;\n }, [occurrenceData]);\n\n return (\n \n \n \n {referenceHeaderText}\n {occurrenceHeaderText}\n \n \n \n {occurrences.length > 0 &&\n occurrences.map((occurrence) => (\n {\n setScriptureReference(occurrence.reference);\n }}\n >\n {`${Canon.bookNumberToEnglishName(occurrence.reference.bookNum)} ${occurrence.reference.chapterNum}:${occurrence.reference.verseNum}`}\n {occurrence.text}\n \n ))}\n \n
    \n );\n}\n\nexport default OccurrencesTable;\n","import React from 'react';\nimport * as CheckboxPrimitive from '@radix-ui/react-checkbox';\nimport { Check } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Checkbox = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n \n \n));\nCheckbox.displayName = CheckboxPrimitive.Root.displayName;\n\nexport default Checkbox;\n","import { Canon } from '@sillsdev/scripture';\nimport { ScriptureReference } from 'platform-bible-utils';\n\n/* #region Types */\n\n/**\n * Status of items that appear in inventories. 'approved' and 'unapproved' items are defined in the\n * project's `Settings.xml`. All other items are defined as 'unknown'\n */\nexport type Status = 'approved' | 'unapproved' | 'unknown';\n\n/** Occurrence of item in inventory. Primarily used by table that shows occurrences */\nexport type InventoryItemOccurrence = {\n /** Reference to scripture where the item appears */\n reference: ScriptureReference;\n /** Snippet of scripture that contains the occurrence */\n text: string;\n};\n\n/** Data structure that contains all information on an item that is shown in an inventory */\nexport type InventoryTableData = {\n /**\n * The item (e.g. a character in the characters inventory, a marker in the marker inventory) In\n * most cases the array will only have one element. In case of additional items (e.g. the\n * preceding marker in the markers check), the primary item should be stored in the first index.\n * To show additional items in the inventory, make sure to configure the `additionalItemsLabels`\n * prop for the Inventory component\n */\n items: string[];\n /** The number of times this item occurs in the selected scope */\n count: number;\n /** The status of this item (see documentation for `Status` type for more information) */\n status: Status;\n /** Occurrences of this item in the scripture text for the selected scope */\n occurrences: InventoryItemOccurrence[];\n};\n\n/* #endregion */\n\n/* #region Functions */\n\n/**\n * Splits USFM string into shorter line-like segments\n *\n * @param text A single (likely very large) USFM string\n * @returns An array containing the input text, split into shorter segments\n */\nexport const getLinesFromUSFM = (text: string) => {\n // Splits on (CR)LF, CR, \\v, \\c and \\id\n return text.split(/(?:\\r?\\n|\\r)|(?=(?:\\\\(?:v|c|id)))/g);\n};\n\n/**\n * Extracts chapter or verse number from USFM strings that start with a \\c or \\v marker\n *\n * @param text USFM string that is expected to start with \\c or \\v marker\n * @returns Chapter or verse number if one is found. Else returns 0.\n */\nexport const getNumberFromUSFM = (text: string): number | undefined => {\n // Captures all digits that follow \\v or \\c markers followed by whitespace located at the start of a string\n const regex = /^\\\\[vc]\\s+(\\d+)/;\n const match = text.match(regex);\n\n if (match) {\n return +match[1];\n }\n return undefined;\n};\n\n/**\n * Gets book ID from USFM string that starts with the \\id marker, and returns book number for it\n *\n * @param text USFM string that is expected to start with \\id marker\n * @returns Book number corresponding to the \\id marker in the input text. Returns 0 if no marker is\n * found or the marker is not valid\n */\nexport const getBookNumFromId = (text: string): number => {\n // Captures all digits that follow an \\id marker followed by whitespace located at the start of a string\n const match = text.match(/^\\\\id\\s+([A-Za-z]+)/);\n if (match) {\n return Canon.bookIdToNumber(match[1]);\n }\n return 0;\n};\n\n/**\n * Gets the status for an item, typically used in the Inventory component\n *\n * @param item The item for which the status is being requested\n * @param approvedItems Array of approved items, typically as defined in `Settings.xml`\n * @param unapprovedItems Array of unapproved items, typically as defined in `Settings.xml`\n * @returns The status for the specified item\n */\nexport const getStatusForItem = (\n item: string,\n approvedItems: string[],\n unapprovedItems: string[],\n): Status => {\n if (unapprovedItems.includes(item)) return 'unapproved';\n if (approvedItems.includes(item)) return 'approved';\n return 'unknown';\n};\n\n/* #endregion */\n","import React from 'react';\nimport * as TogglePrimitive from '@radix-ui/react-toggle';\nimport { cva, type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst toggleVariants = cva(\n 'pr-twp tw-inline-flex tw-items-center tw-justify-center tw-rounded-md tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-colors hover:tw-bg-muted hover:tw-text-muted-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50 data-[state=on]:tw-bg-accent data-[state=on]:tw-text-accent-foreground',\n {\n variants: {\n variant: {\n default: 'tw-bg-transparent',\n outline:\n 'tw-border tw-border-input tw-bg-transparent hover:tw-bg-accent hover:tw-text-accent-foreground',\n },\n size: {\n default: 'tw-h-10 tw-px-3',\n sm: 'tw-h-9 tw-px-2.5',\n lg: 'tw-h-11 tw-px-5',\n },\n },\n defaultVariants: {\n variant: 'default',\n size: 'default',\n },\n },\n);\n\nconst Toggle = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef & VariantProps\n>(({ className, variant, size, ...props }, ref) => (\n \n));\n\nToggle.displayName = TogglePrimitive.Root.displayName;\n\nexport { Toggle, toggleVariants };\n","import React from 'react';\nimport * as ToggleGroupPrimitive from '@radix-ui/react-toggle-group';\nimport { type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { toggleVariants } from '@/components/shadcn-ui/toggle';\n\nconst ToggleGroupContext = React.createContext>({\n size: 'default',\n variant: 'default',\n});\n\nconst ToggleGroup = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef &\n VariantProps\n>(({ className, variant, size, children, ...props }, ref) => (\n \n \n {children}\n \n \n));\n\nToggleGroup.displayName = ToggleGroupPrimitive.Root.displayName;\n\nconst ToggleGroupItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef &\n VariantProps\n>(({ className, children, variant, size, ...props }, ref) => {\n const context = React.useContext(ToggleGroupContext);\n\n return (\n \n {children}\n \n );\n});\n\nToggleGroupItem.displayName = ToggleGroupPrimitive.Item.displayName;\n\nexport { ToggleGroup, ToggleGroupItem };\n","import { ColumnDef, SortDirection } from '@/components/advanced/data-table/data-table.component';\nimport { Button } from '@/components/shadcn-ui/button';\nimport { ToggleGroup, ToggleGroupItem } from '@/components/shadcn-ui/toggle-group';\nimport {\n ArrowDownIcon,\n ArrowUpDownIcon,\n ArrowUpIcon,\n CircleCheckIcon,\n CircleHelpIcon,\n CircleXIcon,\n} from 'lucide-react';\nimport { ReactNode } from 'react';\nimport { InventoryTableData, Status } from './inventory-utils';\n\n/**\n * Gets an icon that indicates the current sorting direction based on the provided input\n *\n * @param sortDirection Sorting direction. Can be ascending ('asc'), descending ('desc') or false (\n * i.e. not sorted)\n * @returns The appropriate sorting icon for the provided sorting direction\n */\nconst getSortingIcon = (sortDirection: false | SortDirection): ReactNode => {\n if (sortDirection === 'asc') {\n return ;\n }\n if (sortDirection === 'desc') {\n return ;\n }\n return ;\n};\n\n/**\n * Function that creates the item column for inventories\n *\n * @param itemLabel Localized label for the item column (e.g. 'Character', 'Repeated Word', etc.)\n * @returns Column that shows the inventory items. Should be used with the DataTable component\n */\nexport const inventoryItemColumn = (itemLabel: string): ColumnDef => {\n return {\n accessorKey: 'item',\n accessorFn: (row: InventoryTableData) => row.items[0],\n header: ({ column }) => (\n \n ),\n };\n};\n\n/**\n * Function that creates the additional item columns for inventories\n *\n * @param additionalItemLabel Localized label for the additional item column (e.g. 'Preceding\n * Marker')\n * @param additionalItemIndex Index that locates the desired item in the items array of the\n * inventory\n * @returns Column that shows additional inventory items. Should be used with the DataTable\n * component\n */\nexport const inventoryAdditionalItemColumn = (\n additionalItemLabel: string,\n additionalItemIndex: number,\n): ColumnDef => {\n return {\n accessorKey: `item${additionalItemIndex}`,\n accessorFn: (row: InventoryTableData) => row.items[additionalItemIndex],\n header: ({ column }) => (\n \n ),\n };\n};\n\n/**\n * Function that creates the count column for inventories. Should be used with the DataTable\n * component.\n *\n * @param itemLabel Localized label for the count column\n * @returns Column that shows the number of occurrences of the related inventory items\n */\nexport const inventoryCountColumn = (countLabel: string): ColumnDef => {\n return {\n accessorKey: 'count',\n header: ({ column }) => (\n
    \n \n
    \n ),\n cell: ({ row }) =>
    {row.getValue('count')}
    ,\n };\n};\n\n/**\n * Function that updates project settings when status for item(s) changes\n *\n * @param changedItems Array of items for which the status is being updated\n * @param newStatus The status that the items are being given\n * @param approvedItems Array of currently approved items\n * @param onApprovedItemsChange Callback function that stores the updated list of approved items\n * @param unapprovedItems Array of currently unapproved items\n * @param onUnapprovedItemsChange Callback function that stores the updated list of unapproved items\n */\nconst statusChangeHandler = (\n changedItems: string[],\n newStatus: Status,\n approvedItems: string[],\n onApprovedItemsChange: (items: string[]) => void,\n unapprovedItems: string[],\n onUnapprovedItemsChange: (items: string[]) => void,\n) => {\n let newApprovedItems: string[] = [...approvedItems];\n changedItems.forEach((item) => {\n if (newStatus === 'approved') {\n if (!newApprovedItems.includes(item)) {\n newApprovedItems.push(item);\n }\n } else {\n newApprovedItems = newApprovedItems.filter((validItem) => validItem !== item);\n }\n });\n onApprovedItemsChange(newApprovedItems);\n\n let newUnapprovedItems: string[] = [...unapprovedItems];\n changedItems.forEach((item) => {\n if (newStatus === 'unapproved') {\n if (!newUnapprovedItems.includes(item)) {\n newUnapprovedItems.push(item);\n }\n } else {\n newUnapprovedItems = newUnapprovedItems.filter((unapprovedItem) => unapprovedItem !== item);\n }\n });\n onUnapprovedItemsChange(newUnapprovedItems);\n};\n\n/**\n * Function that creates the status column for inventories. Should be used with the DataTable\n * component.\n *\n * @param statusLabel Localized label for the status column\n * @param approvedItems Array of approved items, typically as defined in `Settings.xml`\n * @param onApprovedItemsChange Callback function that stores the updated list of approved items\n * @param unapprovedItems Array of unapproved items, typically as defined in `Settings.xml`\n * @param onUnapprovedItemsChange Callback function that stores the updated list of unapproved items\n * @returns Column that shows the status buttons for the related inventory item. The button for the\n * current status of the item is selected\n */\nexport const inventoryStatusColumn = (\n statusLabel: string,\n approvedItems: string[],\n onApprovedItemsChange: (items: string[]) => void,\n unapprovedItems: string[],\n onUnapprovedItemsChange: (items: string[]) => void,\n): ColumnDef => {\n return {\n accessorKey: 'status',\n header: ({ column }) => {\n return (\n
    \n \n
    \n );\n },\n cell: ({ row }) => {\n const status: Status = row.getValue('status');\n const item: string = row.getValue('item');\n return (\n \n \n statusChangeHandler(\n [item],\n 'approved',\n approvedItems,\n onApprovedItemsChange,\n unapprovedItems,\n onUnapprovedItemsChange,\n )\n }\n value=\"approved\"\n >\n \n \n \n statusChangeHandler(\n [item],\n 'unapproved',\n approvedItems,\n onApprovedItemsChange,\n unapprovedItems,\n onUnapprovedItemsChange,\n )\n }\n value=\"unapproved\"\n >\n \n \n \n statusChangeHandler(\n [item],\n 'unknown',\n approvedItems,\n onApprovedItemsChange,\n unapprovedItems,\n onUnapprovedItemsChange,\n )\n }\n value=\"unknown\"\n >\n \n \n \n );\n },\n };\n};\n","import DataTable, {\n ColumnDef,\n RowContents,\n RowSelectionState,\n TableContents,\n} from '@/components/advanced/data-table/data-table.component';\nimport OccurrencesTable from '@/components/advanced/inventory/occurrences-table.component';\nimport Checkbox from '@/components/shadcn-ui/checkbox';\nimport { Input } from '@/components/shadcn-ui/input';\nimport { Label } from '@/components/shadcn-ui/label';\nimport {\n Select,\n SelectContent,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\nimport {\n deepEqual,\n LocalizedStringValue,\n ScriptureReference,\n substring,\n} from 'platform-bible-utils';\nimport { useEffect, useMemo, useState } from 'react';\nimport {\n getBookNumFromId,\n getLinesFromUSFM,\n getNumberFromUSFM,\n getStatusForItem,\n InventoryItemOccurrence,\n InventoryTableData,\n Status,\n} from './inventory-utils';\nimport { inventoryAdditionalItemColumn } from './inventory-columns';\n\n/**\n * Object containing all keys used for localization in this component. If you're using this\n * component in an extension, you can pass it into the useLocalizedStrings hook to easily obtain the\n * localized strings and pass them into the localizedStrings prop of this component\n */\nexport const INVENTORY_STRING_KEYS = Object.freeze([\n '%webView_inventory_all%',\n '%webView_inventory_approved%',\n '%webView_inventory_unapproved%',\n '%webView_inventory_unknown%',\n '%webView_inventory_scope_currentBook%',\n '%webView_inventory_scope_chapter%',\n '%webView_inventory_scope_verse%',\n '%webView_inventory_filter_text%',\n '%webView_inventory_show_additional_items%',\n '%webView_inventory_occurrences_table_header_reference%',\n '%webView_inventory_occurrences_table_header_occurrence%',\n] as const);\n\nexport type InventoryLocalizedStrings = {\n [localizedInventoryKey in (typeof INVENTORY_STRING_KEYS)[number]]?: LocalizedStringValue;\n};\n\n/** Scope of scripture that the inventory can operate on */\nexport type Scope = 'book' | 'chapter' | 'verse';\n\n/** Status values that the status filter can select from */\ntype StatusFilter = Status | 'all';\n\n/** Text labels for the inventory columns and the control components of additional inventory items */\ntype AdditionalItemsLabels = {\n checkboxText?: string;\n tableHeaders?: string[];\n};\n\n/**\n * Filters data that is shown in the DataTable section of the Inventory\n *\n * @param itemData All inventory items and their related information\n * @param statusFilter Allows filtering by status (i.e. show all items, or only items that are\n * 'approved', 'unapproved' or 'unknown')\n * @param textFilter Allows filtering by text. All items that include the filter text will be\n * selected.\n * @returns Array of items and their related information that are matched by the specified filters\n */\nconst filterItemData = (\n itemData: InventoryTableData[],\n statusFilter: StatusFilter,\n textFilter: string,\n): InventoryTableData[] => {\n let filteredItemData: InventoryTableData[] = itemData;\n\n if (statusFilter !== 'all') {\n filteredItemData = filteredItemData.filter(\n (item) =>\n (statusFilter === 'approved' && item.status === 'approved') ||\n (statusFilter === 'unapproved' && item.status === 'unapproved') ||\n (statusFilter === 'unknown' && item.status === 'unknown'),\n );\n }\n\n if (textFilter !== '')\n filteredItemData = filteredItemData.filter((item) => item.items[0].includes(textFilter));\n\n return filteredItemData;\n};\n\n/**\n * Turns array of strings into array of inventory items, along with their count and status\n *\n * @param text The source scripture text that is searched for inventory items\n * @param scriptureRef The scripture reference that the application is currently set to\n * @param approvedItems Array of approved items, typically as defined in `Settings.xml`\n * @param unapprovedItems Array of unapproved items, typically as defined in `Settings.xml`\n * @param itemRegex Regular expression that describes what items this Inventory should extract from\n * the provided scripture text\n * @returns Array of inventory items, along with their count and status\n */\nconst createTableData = (\n text: string | undefined,\n scriptureRef: ScriptureReference,\n approvedItems: string[],\n unapprovedItems: string[],\n itemRegex: RegExp,\n): InventoryTableData[] => {\n if (!text) return [];\n\n const tableData: InventoryTableData[] = [];\n\n let currentBook: number | undefined = scriptureRef.bookNum;\n let currentChapter: number | undefined = scriptureRef.chapterNum;\n let currentVerse: number | undefined = scriptureRef.verseNum;\n\n const lines = getLinesFromUSFM(text);\n\n lines.forEach((line: string) => {\n if (line.startsWith('\\\\id')) {\n currentBook = getBookNumFromId(line);\n currentChapter = 0;\n currentVerse = 0;\n }\n if (line.startsWith('\\\\c')) {\n currentChapter = getNumberFromUSFM(line);\n currentVerse = 0;\n }\n if (line.startsWith('\\\\v')) {\n currentVerse = getNumberFromUSFM(line);\n if (currentChapter === 0) {\n currentChapter = scriptureRef.chapterNum;\n }\n }\n\n let match: RegExpExecArray | undefined = itemRegex.exec(line) ?? undefined;\n while (match) {\n const items: string[] = [];\n match.forEach((item) => items.push(item));\n const itemIndex = match.index;\n const existingItem = tableData.find((tableEntry) => deepEqual(tableEntry.items, items));\n const newReference: InventoryItemOccurrence = {\n reference: {\n bookNum: currentBook !== undefined ? currentBook : -1,\n chapterNum: currentChapter !== undefined ? currentChapter : -1,\n verseNum: currentVerse !== undefined ? currentVerse : -1,\n },\n text: substring(line, Math.max(0, itemIndex - 25), Math.min(itemIndex + 25, line.length)),\n };\n if (existingItem) {\n existingItem.count += 1;\n existingItem.occurrences.push(newReference);\n } else {\n const newItem: InventoryTableData = {\n items,\n count: 1,\n status: getStatusForItem(items[0], approvedItems, unapprovedItems),\n occurrences: [newReference],\n };\n tableData.push(newItem);\n }\n\n match = itemRegex.exec(line) ?? undefined;\n }\n });\n\n return tableData;\n};\n\n/**\n * Gets the localized value for the provided key\n *\n * @param strings Object containing localized string\n * @param key Key for a localized string\n * @returns The localized value for the provided key, if available. Returns the key if no localized\n * value is available\n */\nconst localizeString = (\n strings: InventoryLocalizedStrings,\n key: keyof InventoryLocalizedStrings,\n) => {\n return strings[key] ?? key;\n};\n\n/** Props for the Inventory component */\ntype InventoryProps = {\n /** The scripture reference that the application is currently set to */\n scriptureReference: ScriptureReference;\n /** Callback function that is executed when the scripture reference is changed */\n setScriptureReference: (scriptureReference: ScriptureReference) => void;\n /**\n * Object with all localized strings that the Inventory needs to work well across multiple\n * languages. When using this component with Platform.Bible, you can import\n * `INVENTORY_STRING_KEYS` from this library, pass it in to the Platform's localization hook, and\n * pass the localized keys that are returned by the hook into this prop.\n */\n localizedStrings: InventoryLocalizedStrings;\n /**\n * The logic that finds the desired items in the source text. This can either be a Regular\n * expression that captures one or multiple items (preferred), or a custom function that builds\n * and return an InventoryDataTable[] manually. Note: In case the logic captures more than one\n * item (i.e. InventoryTableData.items has a length greater than 1), you must provide text labels\n * for the related columns and control elements to show by setting the `additionalItemsLabels`\n * prop\n */\n extractItems:\n | RegExp\n | ((\n text: string | undefined,\n scriptureRef: ScriptureReference,\n approvedItems: string[],\n unapprovedItems: string[],\n ) => InventoryTableData[]);\n /**\n * Text labels for control elements and additional column headers in case your Inventory has more\n * than one item to show (e.g. The 'Preceding Marker' in the Markers Inventory)\n */\n additionalItemsLabels?: AdditionalItemsLabels;\n /** Array of approved items, typically as defined in `Settings.xml` */\n approvedItems: string[];\n /** Array of unapproved items, typically as defined in `Settings.xml` */\n unapprovedItems: string[];\n /** The source scripture text that is searched for in inventory items */\n text: string | undefined;\n /** Scope of scripture that the inventory will operate on */\n scope: Scope;\n /** Callback function that is executed when the scope is changed from the Inventory */\n onScopeChange: (scope: Scope) => void;\n /**\n * Column definitions for the Inventory data table. The most commonly used column definitions are\n * pre-configured for your convenience and can be imported (e.g. inventoryItemColumn,\n * inventoryAdditionalItemColumn inventoryCountColumn, and inventoryStatusColumn). If you need any\n * other columns you can add these yourself\n */\n columns: ColumnDef[];\n};\n\n/** Inventory component that is used to view and control the status of provided project settings */\nexport default function Inventory({\n scriptureReference,\n setScriptureReference,\n localizedStrings,\n extractItems,\n additionalItemsLabels,\n approvedItems,\n unapprovedItems,\n text,\n scope,\n onScopeChange,\n columns,\n}: InventoryProps) {\n const allItemsText = localizeString(localizedStrings, '%webView_inventory_all%');\n const approvedItemsText = localizeString(localizedStrings, '%webView_inventory_approved%');\n const unapprovedItemsText = localizeString(localizedStrings, '%webView_inventory_unapproved%');\n const unknownItemsText = localizeString(localizedStrings, '%webView_inventory_unknown%');\n const scopeBookText = localizeString(localizedStrings, '%webView_inventory_scope_currentBook%');\n const scopeChapterText = localizeString(localizedStrings, '%webView_inventory_scope_chapter%');\n const scopeVerseText = localizeString(localizedStrings, '%webView_inventory_scope_verse%');\n const filterText = localizeString(localizedStrings, '%webView_inventory_filter_text%');\n const showAdditionalItemsText = localizeString(\n localizedStrings,\n '%webView_inventory_show_additional_items%',\n );\n\n const [showAdditionalItems, setShowAdditionalItems] = useState(false);\n const [statusFilter, setStatusFilter] = useState('all');\n const [textFilter, setTextFilter] = useState('');\n const [selectedItem, setSelectedItem] = useState([]);\n\n const tableData: InventoryTableData[] = useMemo(() => {\n if (!text) return [];\n if (extractItems instanceof RegExp)\n return createTableData(\n text,\n scriptureReference,\n approvedItems,\n unapprovedItems,\n extractItems,\n );\n return extractItems(text, scriptureReference, approvedItems, unapprovedItems);\n }, [text, extractItems, scriptureReference, approvedItems, unapprovedItems]);\n\n const reducedTableData: InventoryTableData[] = useMemo(() => {\n if (showAdditionalItems) return tableData;\n\n const newTableData: InventoryTableData[] = [];\n\n tableData.forEach((tableEntry) => {\n const firstItem = tableEntry.items[0];\n\n const existingEntry = newTableData.find(\n (newTableEntry) => newTableEntry.items[0] === firstItem,\n );\n\n if (existingEntry) {\n existingEntry.count += tableEntry.count;\n existingEntry.occurrences = existingEntry.occurrences.concat(tableEntry.occurrences);\n } else {\n newTableData.push({\n items: [firstItem],\n count: tableEntry.count,\n occurrences: tableEntry.occurrences,\n status: tableEntry.status,\n });\n }\n });\n\n return newTableData;\n }, [showAdditionalItems, tableData]);\n\n const filteredTableData: InventoryTableData[] = useMemo(() => {\n return filterItemData(reducedTableData, statusFilter, textFilter);\n }, [reducedTableData, statusFilter, textFilter]);\n\n const allColumns: ColumnDef[] = useMemo(() => {\n if (!showAdditionalItems) return columns;\n\n const numberOfAdditionalItems = additionalItemsLabels?.tableHeaders?.length;\n if (!numberOfAdditionalItems) return columns;\n\n const additionalColumns: ColumnDef[] = [];\n\n for (let index = 0; index < numberOfAdditionalItems; index++) {\n additionalColumns.push(\n inventoryAdditionalItemColumn(\n additionalItemsLabels?.tableHeaders?.[index] || 'Additional Item',\n index + 1,\n ),\n );\n }\n\n return [...additionalColumns, ...columns];\n }, [additionalItemsLabels?.tableHeaders, columns, showAdditionalItems]);\n\n useEffect(() => {\n setSelectedItem([]);\n }, [filteredTableData]);\n\n const rowClickHandler = (\n row: RowContents,\n table: TableContents,\n ) => {\n table.setRowSelection(() => {\n const newSelection: RowSelectionState = {};\n newSelection[row.index] = true;\n return newSelection;\n });\n\n setSelectedItem(row.original.items);\n };\n\n const handleScopeChange = (value: string) => {\n if (value === 'book' || value === 'chapter' || value === 'verse') {\n onScopeChange(value);\n } else {\n throw new Error(`Invalid scope value: ${value}`);\n }\n };\n\n const handleStatusFilterChange = (value: string) => {\n if (value === 'all' || value === 'approved' || value === 'unapproved' || value === 'unknown') {\n setStatusFilter(value);\n } else {\n throw new Error(`Invalid status filter value: ${value}`);\n }\n };\n\n const occurrenceData: InventoryItemOccurrence[] = useMemo(() => {\n if (reducedTableData.length === 0 || selectedItem.length === 0) return [];\n const occurrence = reducedTableData.filter((tableEntry: InventoryTableData) => {\n return deepEqual(\n showAdditionalItems ? tableEntry.items : [tableEntry.items[0]],\n selectedItem,\n );\n });\n if (occurrence.length > 1) throw new Error('Selected item is not unique');\n return occurrence[0].occurrences;\n }, [selectedItem, showAdditionalItems, reducedTableData]);\n\n return (\n
    \n
    \n handleStatusFilterChange(value)}\n defaultValue={statusFilter}\n >\n \n \n \n \n {allItemsText}\n {approvedItemsText}\n {unapprovedItemsText}\n {unknownItemsText}\n \n \n \n {\n setTextFilter(event.target.value);\n }}\n />\n {additionalItemsLabels && (\n
    \n {\n setSelectedItem([]);\n setShowAdditionalItems(checked);\n }}\n />\n \n
    \n )}\n
    \n
    \n \n
    \n {occurrenceData.length > 0 && (\n
    \n \n
    \n )}\n
    \n );\n}\n","import { Input } from '@/components/shadcn-ui/input';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { useState } from 'react';\n\nexport type SearchBarProps = {\n /**\n * Callback fired to handle the search query when button pressed\n *\n * @param searchQuery\n */\n onSearch: (searchQuery: string) => void;\n\n /** Optional string that appears in the search bar without a search string */\n placeholder?: string;\n\n /** Optional boolean to set the input base to full width */\n isFullWidth?: boolean;\n};\n\nexport default function SearchBar({ onSearch, placeholder, isFullWidth }: SearchBarProps) {\n const [searchQuery, setSearchQuery] = useState('');\n\n const handleInputChange = (searchString: string) => {\n setSearchQuery(searchString);\n onSearch(searchString);\n };\n\n return (\n handleInputChange(e.target.value)}\n />\n );\n}\n","// adapted from: https://github.com/shadcn-ui/ui/discussions/752\n\n'use client';\n\nimport { TabsContentProps, TabsListProps, TabsTriggerProps } from '@/components/shadcn-ui/tabs';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport * as TabsPrimitive from '@radix-ui/react-tabs';\nimport React from 'react';\n\nexport type VerticalTabsProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport type LeftTabsTriggerProps = TabsTriggerProps & {\n value: string;\n ref?: React.Ref;\n};\n\nexport const VerticalTabs = React.forwardRef<\n React.ElementRef,\n VerticalTabsProps\n>(({ className, ...props }, ref) => (\n \n));\n\nVerticalTabs.displayName = TabsPrimitive.List.displayName;\n\nexport const VerticalTabsList = React.forwardRef<\n React.ElementRef,\n TabsListProps\n>(({ className, ...props }, ref) => (\n \n));\nVerticalTabsList.displayName = TabsPrimitive.List.displayName;\n\nexport const VerticalTabsTrigger = React.forwardRef<\n React.ElementRef,\n LeftTabsTriggerProps\n>(({ className, ...props }, ref) => (\n \n));\n\nexport const VerticalTabsContent = React.forwardRef<\n React.ElementRef,\n TabsContentProps\n>(({ className, ...props }, ref) => (\n \n));\nVerticalTabsContent.displayName = TabsPrimitive.Content.displayName;\n","import SearchBar from '@/components/basics/search-bar.component';\nimport {\n VerticalTabs,\n VerticalTabsContent,\n VerticalTabsList,\n VerticalTabsTrigger,\n} from '@/components/basics/tabs-vertical';\nimport { ReactNode } from 'react';\n\nexport type TabKeyValueContent = {\n key: string;\n value: string;\n content: ReactNode;\n};\n\nexport type TabNavigationContentSearchProps = {\n /** List of values and keys for each tab this component should provide */\n tabList: TabKeyValueContent[];\n\n /** Handler to run when the value of the search bar changes */\n onSearch: (searchQuery: string) => void;\n\n /** Optional placeholder for the search bar */\n searchPlaceholder?: string;\n\n /** Optional title to include in the header */\n headerTitle?: string;\n\n /** Optional flag to make the search bar appear full width */\n isSearchBarFullWidth?: boolean;\n\n /** Text direction ltr or rtl */\n direction?: 'ltr' | 'rtl';\n};\n\nexport default function TabNavigationContentSearch({\n tabList,\n onSearch,\n searchPlaceholder,\n headerTitle,\n isSearchBarFullWidth = false,\n direction = 'ltr',\n}: TabNavigationContentSearchProps) {\n return (\n
    \n
    \n {headerTitle ?

    {headerTitle}

    : ''}\n \n
    \n \n \n {tabList.map((tab) => (\n \n {tab.value}\n \n ))}\n \n {tabList.map((tab) => (\n \n {tab.content}\n \n ))}\n \n
    \n );\n}\n","import React from 'react';\nimport * as SeparatorPrimitive from '@radix-ui/react-separator';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Separator = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, orientation = 'horizontal', decorative = true, ...props }, ref) => (\n \n));\nSeparator.displayName = SeparatorPrimitive.Root.displayName;\n\nexport { Separator };\n","'use client';\n\nimport * as React from 'react';\nimport * as SheetPrimitive from '@radix-ui/react-dialog';\nimport { cva, type VariantProps } from 'class-variance-authority';\nimport { X } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Sheet = SheetPrimitive.Root;\n\nconst SheetTrigger = SheetPrimitive.Trigger;\n\nconst SheetClose = SheetPrimitive.Close;\n\nconst SheetPortal = SheetPrimitive.Portal;\n\nconst SheetOverlay = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSheetOverlay.displayName = SheetPrimitive.Overlay.displayName;\n\nconst sheetVariants = cva(\n 'pr-twp tw-fixed tw-z-50 tw-gap-4 tw-bg-background tw-p-6 tw-shadow-lg tw-transition tw-ease-in-out data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-duration-300 data-[state=open]:tw-duration-500',\n {\n variants: {\n side: {\n top: 'tw-inset-x-0 tw-top-0 tw-border-b data-[state=closed]:tw-slide-out-to-top data-[state=open]:tw-slide-in-from-top',\n bottom:\n 'tw-inset-x-0 tw-bottom-0 tw-border-t data-[state=closed]:tw-slide-out-to-bottom data-[state=open]:tw-slide-in-from-bottom',\n left: 'tw-inset-y-0 tw-left-0 tw-h-full tw-w-3/4 tw-border-r data-[state=closed]:tw-slide-out-to-left data-[state=open]:tw-slide-in-from-left sm:tw-max-w-sm',\n right:\n 'tw-inset-y-0 tw-right-0 tw-h-full tw-w-3/4 tw- tw-border-l data-[state=closed]:tw-slide-out-to-right data-[state=open]:tw-slide-in-from-right sm:tw-max-w-sm',\n },\n },\n defaultVariants: {\n side: 'right',\n },\n },\n);\n\ninterface SheetContentProps\n extends React.ComponentPropsWithoutRef,\n VariantProps {}\n\nconst SheetContent = React.forwardRef<\n React.ElementRef,\n SheetContentProps\n>(({ side = 'right', className, children, ...props }, ref) => (\n \n \n \n {children}\n \n \n Close\n \n \n \n));\nSheetContent.displayName = SheetPrimitive.Content.displayName;\n\nfunction SheetHeader({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nSheetHeader.displayName = 'SheetHeader';\n\nfunction SheetFooter({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nSheetFooter.displayName = 'SheetFooter';\n\nconst SheetTitle = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSheetTitle.displayName = SheetPrimitive.Title.displayName;\n\nconst SheetDescription = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSheetDescription.displayName = SheetPrimitive.Description.displayName;\n\nexport {\n Sheet,\n SheetPortal,\n SheetOverlay,\n SheetTrigger,\n SheetClose,\n SheetContent,\n SheetHeader,\n SheetFooter,\n SheetTitle,\n SheetDescription,\n};\n","import React from 'react';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nfunction Skeleton({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\n\nexport { Skeleton };\n","import React from 'react';\nimport * as TooltipPrimitive from '@radix-ui/react-tooltip';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst TooltipProvider = TooltipPrimitive.Provider;\n\nconst Tooltip = TooltipPrimitive.Root;\n\nconst TooltipTrigger = TooltipPrimitive.Trigger;\n\nconst TooltipContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, sideOffset = 4, ...props }, ref) => (\n \n));\nTooltipContent.displayName = TooltipPrimitive.Content.displayName;\n\nexport { Tooltip, TooltipTrigger, TooltipContent, TooltipProvider };\n","import * as React from 'react';\n\nconst MOBILE_BREAKPOINT = 768;\n\nexport default function useIsMobile() {\n const [isMobile, setIsMobile] = React.useState(undefined);\n\n React.useEffect(() => {\n const mql = window.matchMedia(`(max-width: ${MOBILE_BREAKPOINT - 1}px)`);\n const onChange = () => {\n setIsMobile(window.innerWidth < MOBILE_BREAKPOINT);\n };\n mql.addEventListener('change', onChange);\n setIsMobile(window.innerWidth < MOBILE_BREAKPOINT);\n return () => mql.removeEventListener('change', onChange);\n }, []);\n\n return !!isMobile;\n}\n","import React from 'react';\nimport { Slot } from '@radix-ui/react-slot';\nimport { VariantProps, cva } from 'class-variance-authority';\nimport { PanelLeft } from 'lucide-react';\n\nimport { Button } from '@/components/shadcn-ui/button';\nimport { Input } from '@/components/shadcn-ui/input';\nimport { Separator } from '@/components/shadcn-ui/separator';\nimport { Sheet, SheetContent } from '@/components/shadcn-ui/sheet';\nimport { Skeleton } from '@/components/shadcn-ui/skeleton';\nimport {\n Tooltip,\n TooltipContent,\n TooltipProvider,\n TooltipTrigger,\n} from '@/components/shadcn-ui/tooltip';\nimport useIsMobile from '@/components/hooks/use-mobile';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst SIDEBAR_COOKIE_NAME = 'sidebar:state';\nconst SIDEBAR_COOKIE_MAX_AGE = 60 * 60 * 24 * 7;\nconst SIDEBAR_WIDTH = '16rem';\nconst SIDEBAR_WIDTH_MOBILE = '18rem';\nconst SIDEBAR_WIDTH_ICON = '3rem';\nconst SIDEBAR_KEYBOARD_SHORTCUT = 'b';\n\ntype SidebarContextProps = {\n state: 'expanded' | 'collapsed';\n open: boolean;\n setOpen: (open: boolean) => void;\n openMobile: boolean;\n setOpenMobile: (open: boolean) => void;\n isMobile: boolean;\n toggleSidebar: () => void;\n};\n\nconst SidebarContext = React.createContext(undefined);\n\nfunction useSidebar() {\n const context = React.useContext(SidebarContext);\n if (!context) {\n throw new Error('useSidebar must be used within a SidebarProvider.');\n }\n\n return context;\n}\n\nconst SidebarProvider = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & {\n defaultOpen?: boolean;\n open?: boolean;\n onOpenChange?: (open: boolean) => void;\n }\n>(\n (\n {\n defaultOpen = true,\n open: openProp,\n onOpenChange: setOpenProp,\n className,\n style,\n children,\n ...props\n },\n ref,\n ) => {\n const isMobile = useIsMobile();\n const [openMobile, setOpenMobile] = React.useState(false);\n\n // This is the internal state of the sidebar.\n // We use openProp and setOpenProp for control from outside the component.\n const [_open, _setOpen] = React.useState(defaultOpen);\n const isOpen = openProp ?? _open;\n const setOpen = React.useCallback(\n (value: boolean | ((value: boolean) => boolean)) => {\n const openState = typeof value === 'function' ? value(isOpen) : value;\n if (setOpenProp) {\n setOpenProp(openState);\n } else {\n _setOpen(openState);\n }\n\n // This sets the cookie to keep the sidebar state.\n document.cookie = `${SIDEBAR_COOKIE_NAME}=${openState}; path=/; max-age=${SIDEBAR_COOKIE_MAX_AGE}`;\n },\n [setOpenProp, isOpen],\n );\n\n // Helper to toggle the sidebar.\n const toggleSidebar = React.useCallback(() => {\n return isMobile ? setOpenMobile((open) => !open) : setOpen((open) => !open);\n }, [isMobile, setOpen, setOpenMobile]);\n\n // Adds a keyboard shortcut to toggle the sidebar.\n React.useEffect(() => {\n const handleKeyDown = (event: KeyboardEvent) => {\n if (event.key === SIDEBAR_KEYBOARD_SHORTCUT && (event.metaKey || event.ctrlKey)) {\n event.preventDefault();\n toggleSidebar();\n }\n };\n\n window.addEventListener('keydown', handleKeyDown);\n return () => window.removeEventListener('keydown', handleKeyDown);\n }, [toggleSidebar]);\n\n // We add a state so that we can do data-state=\"expanded\" or \"collapsed\".\n // This makes it easier to style the sidebar with Tailwind classes.\n const state = isOpen ? 'expanded' : 'collapsed';\n\n const contextValue = React.useMemo(\n () => ({\n state,\n open: isOpen,\n setOpen,\n isMobile,\n openMobile,\n setOpenMobile,\n toggleSidebar,\n }),\n [state, isOpen, setOpen, isMobile, openMobile, setOpenMobile, toggleSidebar],\n );\n\n return (\n \n \n \n {children}\n
    \n \n \n );\n },\n);\nSidebarProvider.displayName = 'SidebarProvider';\n\nconst Sidebar = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & {\n side?: 'left' | 'right';\n variant?: 'sidebar' | 'floating' | 'inset';\n collapsible?: 'offcanvas' | 'icon' | 'none';\n }\n>(\n (\n {\n side = 'left',\n variant = 'sidebar',\n collapsible = 'offcanvas',\n className,\n children,\n ...props\n },\n ref,\n ) => {\n const { isMobile, state, openMobile, setOpenMobile } = useSidebar();\n\n if (collapsible === 'none') {\n return (\n \n {children}\n
    \n );\n }\n\n if (isMobile) {\n return (\n \n button]:tw-hidden\"\n style={\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n {\n '--sidebar-width': SIDEBAR_WIDTH_MOBILE,\n } as React.CSSProperties\n }\n side={side}\n >\n
    {children}
    \n \n
    \n );\n }\n\n return (\n \n {/* This is what handles the sidebar gap on desktop */}\n \n \n \n {children}\n
    \n
    \n
    \n );\n },\n);\nSidebar.displayName = 'Sidebar';\n\nconst SidebarTrigger = React.forwardRef<\n React.ElementRef,\n React.ComponentProps\n>(({ className, onClick, ...props }, ref) => {\n const { toggleSidebar } = useSidebar();\n\n return (\n {\n onClick?.(event);\n toggleSidebar();\n }}\n {...props}\n >\n \n Toggle Sidebar\n \n );\n});\nSidebarTrigger.displayName = 'SidebarTrigger';\n\nconst SidebarRail = React.forwardRef>(\n ({ className, ...props }, ref) => {\n const { toggleSidebar } = useSidebar();\n\n return (\n \n );\n },\n);\nSidebarRail.displayName = 'SidebarRail';\n\nconst SidebarInset = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarInset.displayName = 'SidebarInset';\n\nconst SidebarInput = React.forwardRef<\n React.ElementRef,\n React.ComponentProps\n>(({ className, ...props }, ref) => {\n return (\n \n );\n});\nSidebarInput.displayName = 'SidebarInput';\n\nconst SidebarHeader = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarHeader.displayName = 'SidebarHeader';\n\nconst SidebarFooter = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarFooter.displayName = 'SidebarFooter';\n\nconst SidebarSeparator = React.forwardRef<\n React.ElementRef,\n React.ComponentProps\n>(({ className, ...props }, ref) => {\n return (\n \n );\n});\nSidebarSeparator.displayName = 'SidebarSeparator';\n\nconst SidebarContent = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarContent.displayName = 'SidebarContent';\n\nconst SidebarGroup = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarGroup.displayName = 'SidebarGroup';\n\nconst SidebarGroupLabel = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & { asChild?: boolean }\n>(({ className, asChild = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'div';\n\n return (\n svg]:tw-size-4 [&>svg]:tw-shrink-0',\n 'group-data-[collapsible=icon]:tw--mt-8 group-data-[collapsible=icon]:tw-opacity-0',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarGroupLabel.displayName = 'SidebarGroupLabel';\n\nconst SidebarGroupAction = React.forwardRef<\n HTMLButtonElement,\n React.ComponentProps<'button'> & { asChild?: boolean }\n>(({ className, asChild = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'button';\n\n return (\n svg]:tw-size-4 [&>svg]:tw-shrink-0',\n // Increases the hit area of the button on mobile.\n 'after:tw-absolute after:tw--inset-2 after:md:tw-hidden',\n 'group-data-[collapsible=icon]:tw-hidden',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarGroupAction.displayName = 'SidebarGroupAction';\n\nconst SidebarGroupContent = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarGroupContent.displayName = 'SidebarGroupContent';\n\nconst SidebarMenu = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenu.displayName = 'SidebarMenu';\n\nconst SidebarMenuItem = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenuItem.displayName = 'SidebarMenuItem';\n\nconst sidebarMenuButtonVariants = cva(\n 'tw-peer/menu-button tw-flex tw-w-full tw-items-center tw-gap-2 tw-overflow-hidden tw-rounded-md tw-p-2 tw-text-left tw-text-sm tw-outline-none tw-ring-sidebar-ring tw-transition-[width,height,padding] hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground focus-visible:tw-ring-2 active:tw-bg-sidebar-accent active:tw-text-sidebar-accent-foreground disabled:tw-pointer-events-none disabled:tw-opacity-50 tw-group-has-[[data-sidebar=menu-action]]/menu-item:pr-8 aria-disabled:tw-pointer-events-none aria-disabled:tw-opacity-50 data-[active=true]:tw-bg-sidebar-accent data-[active=true]:tw-font-medium data-[active=true]:tw-text-sidebar-accent-foreground data-[state=open]:hover:tw-bg-sidebar-accent data-[state=open]:hover:tw-text-sidebar-accent-foreground group-data-[collapsible=icon]:tw-!size-8 group-data-[collapsible=icon]:tw-!p-2 [&>span:last-child]:tw-truncate [&>svg]:tw-size-4 [&>svg]:tw-shrink-0',\n {\n variants: {\n variant: {\n default: 'hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground',\n outline:\n 'tw-bg-background tw-shadow-[0_0_0_1px_hsl(var(--sidebar-border))] hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground hover:tw-shadow-[0_0_0_1px_hsl(var(--sidebar-accent))]',\n },\n size: {\n default: 'tw-h-8 tw-text-sm',\n sm: 'tw-h-7 tw-text-xs',\n lg: 'tw-h-12 tw-text-sm group-data-[collapsible=icon]:tw-!p-0',\n },\n },\n defaultVariants: {\n variant: 'default',\n size: 'default',\n },\n },\n);\n\nconst SidebarMenuButton = React.forwardRef<\n HTMLButtonElement,\n React.ComponentProps<'button'> & {\n asChild?: boolean;\n isActive?: boolean;\n tooltip?: string | React.ComponentProps;\n } & VariantProps\n>(\n (\n {\n asChild = false,\n isActive = false,\n variant = 'default',\n size = 'default',\n tooltip,\n className,\n ...props\n },\n ref,\n ) => {\n const Comp = asChild ? Slot : 'button';\n const { isMobile, state } = useSidebar();\n\n const button = (\n \n );\n\n if (!tooltip) {\n return button;\n }\n\n if (typeof tooltip === 'string') {\n // eslint-disable-next-line no-param-reassign\n tooltip = {\n children: tooltip,\n };\n }\n\n return (\n \n {button}\n \n );\n },\n);\nSidebarMenuButton.displayName = 'SidebarMenuButton';\n\nconst SidebarMenuAction = React.forwardRef<\n HTMLButtonElement,\n React.ComponentProps<'button'> & {\n asChild?: boolean;\n showOnHover?: boolean;\n }\n>(({ className, asChild = false, showOnHover = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'button';\n\n return (\n svg]:tw-size-4 [&>svg]:tw-shrink-0',\n // Increases the hit area of the button on mobile.\n 'after:tw-absolute after:tw--inset-2 after:md:tw-hidden',\n 'tw-peer-data-[size=sm]/menu-button:top-1',\n 'tw-peer-data-[size=default]/menu-button:top-1.5',\n 'tw-peer-data-[size=lg]/menu-button:top-2.5',\n 'group-data-[collapsible=icon]:tw-hidden',\n showOnHover &&\n 'tw-group-focus-within/menu-item:opacity-100 tw-group-hover/menu-item:opacity-100 tw-peer-data-[active=true]/menu-button:text-sidebar-accent-foreground data-[state=open]:tw-opacity-100 md:tw-opacity-0',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarMenuAction.displayName = 'SidebarMenuAction';\n\nconst SidebarMenuBadge = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenuBadge.displayName = 'SidebarMenuBadge';\n\nconst SidebarMenuSkeleton = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & {\n showIcon?: boolean;\n }\n>(({ className, showIcon = false, ...props }, ref) => {\n // Random width between 50 to 90%.\n const width = React.useMemo(() => {\n return `${Math.floor(Math.random() * 40) + 50}%`;\n }, []);\n\n return (\n \n {showIcon && (\n \n )}\n \n
    \n );\n});\nSidebarMenuSkeleton.displayName = 'SidebarMenuSkeleton';\n\nconst SidebarMenuSub = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenuSub.displayName = 'SidebarMenuSub';\n\nconst SidebarMenuSubItem = React.forwardRef>(\n ({ ...props }, ref) =>
  • ,\n);\nSidebarMenuSubItem.displayName = 'SidebarMenuSubItem';\n\nconst SidebarMenuSubButton = React.forwardRef<\n HTMLAnchorElement,\n React.ComponentProps<'a'> & {\n asChild?: boolean;\n size?: 'sm' | 'md';\n isActive?: boolean;\n }\n>(({ asChild = false, size = 'md', isActive, className, ...props }, ref) => {\n const Comp = asChild ? Slot : 'a';\n\n return (\n span:last-child]:tw-truncate [&>svg]:tw-size-4 [&>svg]:tw-shrink-0 [&>svg]:tw-text-sidebar-accent-foreground',\n 'data-[active=true]:tw-bg-sidebar-accent data-[active=true]:tw-text-sidebar-accent-foreground',\n size === 'sm' && 'tw-text-xs',\n size === 'md' && 'tw-text-sm',\n 'group-data-[collapsible=icon]:tw-hidden',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarMenuSubButton.displayName = 'SidebarMenuSubButton';\n\nexport {\n Sidebar,\n SidebarContent,\n SidebarFooter,\n SidebarGroup,\n SidebarGroupAction,\n SidebarGroupContent,\n SidebarGroupLabel,\n SidebarHeader,\n SidebarInput,\n SidebarInset,\n SidebarMenu,\n SidebarMenuAction,\n SidebarMenuBadge,\n SidebarMenuButton,\n SidebarMenuItem,\n SidebarMenuSkeleton,\n SidebarMenuSub,\n SidebarMenuSubButton,\n SidebarMenuSubItem,\n SidebarProvider,\n SidebarRail,\n SidebarSeparator,\n SidebarTrigger,\n useSidebar,\n};\n","import ComboBox, { ComboBoxOption } from '@/components/basics/combo-box.component';\nimport {\n Sidebar,\n SidebarContent,\n SidebarGroup,\n SidebarGroupLabel,\n SidebarGroupContent,\n SidebarMenu,\n SidebarMenuItem,\n SidebarMenuButton,\n} from '@/components/shadcn-ui/sidebar';\nimport { useCallback } from 'react';\n\nexport type SelectedSettingsSidebarItem = {\n label: string;\n projectId?: string;\n};\n\nexport type ProjectOptions = { projectId: string; projectName: string };\n\nexport type SettingsSidebarProps = {\n /** Optional id for testing */\n id?: string;\n\n /** Extension labels from contribution */\n extensionLabels: string[];\n\n /** Project names and ids */\n projectOptions: ProjectOptions[];\n\n /** Handler for selecting a sidebar item */\n handleSelectSidebarItem: (key: string, projectId?: string) => void;\n\n /** The current selected value in the sidebar */\n selectedSidebarItem: SelectedSettingsSidebarItem | undefined;\n};\n\nexport default function SettingsSidebar({\n id,\n extensionLabels,\n projectOptions,\n handleSelectSidebarItem,\n selectedSidebarItem,\n}: SettingsSidebarProps) {\n const handleSelectItem = useCallback(\n (item: string, projectId?: string) => {\n handleSelectSidebarItem(item, projectId);\n },\n [handleSelectSidebarItem],\n );\n\n const getProjectNameFromProjectId = useCallback(\n (projectId: string) => {\n const project = projectOptions.find((option) => option.projectId === projectId);\n return project ? project.projectName : projectId;\n },\n [projectOptions],\n );\n\n return (\n \n \n \n Extensions\n \n \n {extensionLabels.map((label) => (\n \n handleSelectItem(label)}\n isActive={\n !selectedSidebarItem?.projectId && label === selectedSidebarItem?.label\n }\n >\n {label}\n \n \n ))}\n \n \n \n \n Projects\n \n option.projectId)}\n getOptionLabel={(projectId: ComboBoxOption) => {\n // This function expects a ComboBoxOption, but we know it is a string\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n return getProjectNameFromProjectId(projectId as string);\n }}\n buttonPlaceholder=\"Type or select project\"\n onChange={(projectId: string) => {\n const selectedProjectName = getProjectNameFromProjectId(projectId);\n handleSelectItem(selectedProjectName, projectId);\n }}\n value={selectedSidebarItem?.projectId ?? undefined}\n />\n \n \n \n \n );\n}\n","import { SidebarInset, SidebarProvider } from '@/components/shadcn-ui/sidebar';\nimport { PropsWithChildren } from 'react';\nimport SettingsSidebar, { SettingsSidebarProps } from './settings-sidebar.component';\n\nexport type SettingsSidebarContentSearchProps = SettingsSidebarProps &\n PropsWithChildren & {\n /** Optional id for testing */\n id?: string;\n\n /** Text direction ltr or rtl */\n direction?: 'ltr' | 'rtl';\n };\n\nexport default function SettingsSidebarContentSearch({\n id,\n direction = 'ltr',\n extensionLabels,\n projectOptions,\n children,\n handleSelectSidebarItem,\n selectedSidebarItem,\n}: SettingsSidebarContentSearchProps) {\n return (\n \n \n {children}\n \n );\n}\n","import { Button } from '@/components/shadcn-ui/button';\nimport {\n Select,\n SelectContent,\n SelectGroup,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\nimport {\n Table,\n TableBody,\n TableCell,\n TableHead,\n TableHeader,\n TableRow,\n} from '@/components/shadcn-ui/table';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Canon } from '@sillsdev/scripture';\nimport {\n Cell,\n ColumnDef,\n flexRender,\n getCoreRowModel,\n getExpandedRowModel,\n getGroupedRowModel,\n getSortedRowModel,\n GroupingState,\n Row,\n RowSelectionState,\n SortingState,\n useReactTable,\n} from '@tanstack/react-table';\nimport '@/components/advanced/scripture-results-viewer/scripture-results-viewer.component.css';\nimport {\n compareScrRefs,\n formatScrRef,\n ScriptureSelection,\n scrRefToBBBCCCVVV,\n} from 'platform-bible-utils';\nimport { MouseEvent, useEffect, useMemo, useState } from 'react';\nimport { ChevronDown, ChevronLeft, ChevronRight } from 'lucide-react';\n\n/**\n * Information (e.g., a checking error or some other type of \"transient\" annotation) about something\n * noteworthy at a specific place in an instance of the Scriptures.\n */\nexport type ScriptureItemDetail = ScriptureSelection & {\n /**\n * Text of the error, note, etc. In the future, we might want to support something more than just\n * text so that a JSX element could be provided with a link or some other controls related to the\n * issue being reported.\n */\n detail: string;\n};\n\n/**\n * A uniquely identifiable source of results that can be displayed in the ScriptureResultsViewer.\n * Generally, the source will be a particular Scripture check, but there may be other types of\n * sources.\n */\nexport type ResultsSource = {\n /**\n * Uniquely identifies the source.\n *\n * @type {string}\n */\n id: string;\n\n /**\n * Name (potentially localized) of the source, suitable for display in the UI.\n *\n * @type {string}\n */\n displayName: string;\n};\n\nexport type ScriptureSrcItemDetail = ScriptureItemDetail & {\n /** Source/type of detail. Can be used for grouping. */\n source: ResultsSource;\n};\n\n/**\n * Represents a set of results keyed by Scripture reference. Generally, the source will be a\n * particular Scripture check, but this type also allows for other types of uniquely identifiable\n * sources.\n */\nexport type ResultsSet = {\n /**\n * The backing source associated with this set of results.\n *\n * @type {ResultsSource}\n */\n source: ResultsSource;\n\n /**\n * Array of Scripture item details (messages keyed by Scripture reference).\n *\n * @type {ScriptureItemDetail[]}\n */\n data: ScriptureItemDetail[];\n};\n\nconst scrBookColId = 'scrBook';\nconst scrRefColId = 'scrRef';\nconst typeColId = 'source';\nconst detailsColId = 'details';\n\nconst defaultScrRefColumnName = 'Scripture Reference';\nconst defaultScrBookGroupName = 'Scripture Book';\nconst defaultTypeColumnName = 'Type';\nconst defaultDetailsColumnName = 'Details';\n\nexport type ScriptureResultsViewerColumnInfo = {\n /** Optional header to display for the Reference column. Default value: 'Scripture Reference'. */\n scriptureReferenceColumnName?: string;\n\n /** Optional text to display to refer to the Scripture book group. Default value: 'Scripture Book'. */\n scriptureBookGroupName?: string;\n\n /** Optional header to display for the Type column. Default value: 'Type'. */\n typeColumnName?: string;\n\n /** Optional header to display for the Details column. Default value: 'Details' */\n detailsColumnName?: string;\n};\n\nexport type ScriptureResultsViewerProps = ScriptureResultsViewerColumnInfo & {\n /** Groups of ScriptureItemDetail objects from particular sources (e.g., Scripture checks) */\n sources: ResultsSet[];\n\n /** Flag indicating whether to display column headers. Default is false. */\n showColumnHeaders?: boolean;\n\n /** Flag indicating whether to display source column. Default is false. */\n showSourceColumn?: boolean;\n\n /** Callback function to notify when a row is selected */\n onRowSelected?: (selectedRow: ScriptureSrcItemDetail | undefined) => void;\n\n /** Text direction ltr or rtl */\n direction?: 'ltr' | 'rtl';\n};\n\nfunction getColumns(\n colInfo?: ScriptureResultsViewerColumnInfo,\n showSourceColumn?: boolean,\n): ColumnDef[] {\n const showSrcCol = showSourceColumn ?? false;\n return [\n {\n accessorFn: (row) =>\n `${Canon.bookNumberToId(row.start.bookNum)} ${row.start.chapterNum}:${row.start.verseNum}`,\n id: scrBookColId,\n header: colInfo?.scriptureReferenceColumnName ?? defaultScrRefColumnName,\n cell: (info) => {\n const row = info.row.original;\n if (info.row.getIsGrouped()) {\n return Canon.bookNumberToEnglishName(row.start.bookNum);\n }\n return info.row.groupingColumnId === scrBookColId ? formatScrRef(row.start) : undefined;\n },\n getGroupingValue: (row) => row.start.bookNum,\n sortingFn: (a, b) => {\n return compareScrRefs(a.original.start, b.original.start);\n },\n enableGrouping: true,\n },\n {\n accessorFn: (row) => formatScrRef(row.start),\n id: scrRefColId,\n header: undefined,\n cell: (info) => {\n const row = info.row.original;\n return info.row.getIsGrouped() ? undefined : formatScrRef(row.start);\n },\n sortingFn: (a, b) => {\n return compareScrRefs(a.original.start, b.original.start);\n },\n enableGrouping: false,\n },\n {\n accessorFn: (row) => row.source.displayName,\n id: typeColId,\n header: showSrcCol ? (colInfo?.typeColumnName ?? defaultTypeColumnName) : undefined,\n cell: (info) => (showSrcCol || info.row.getIsGrouped() ? info.getValue() : undefined),\n getGroupingValue: (row) => row.source.id,\n sortingFn: (a, b) =>\n a.original.source.displayName.localeCompare(b.original.source.displayName),\n enableGrouping: true,\n },\n {\n accessorFn: (row) => row.detail,\n id: detailsColId,\n header: colInfo?.detailsColumnName ?? defaultDetailsColumnName,\n cell: (info) => info.getValue(),\n enableGrouping: false,\n },\n ];\n}\n\nconst toRefOrRange = (scriptureSelection: ScriptureSelection) => {\n if (!('offset' in scriptureSelection.start))\n throw new Error('No offset available in range start');\n if (scriptureSelection.end && !('offset' in scriptureSelection.end))\n throw new Error('No offset available in range end');\n const { offset: offsetStart } = scriptureSelection.start;\n let offsetEnd: number = 0;\n if (scriptureSelection.end) ({ offset: offsetEnd } = scriptureSelection.end);\n if (\n !scriptureSelection.end ||\n compareScrRefs(scriptureSelection.start, scriptureSelection.end) === 0\n )\n return `${scrRefToBBBCCCVVV(scriptureSelection.start)}+${offsetStart}`;\n return `${scrRefToBBBCCCVVV(scriptureSelection.start)}+${offsetStart}-${scrRefToBBBCCCVVV(scriptureSelection.end)}+${offsetEnd}`;\n};\n\nconst getRowKey = (row: ScriptureSrcItemDetail) =>\n `${toRefOrRange({ start: row.start, end: row.end })} ${row.source.displayName} ${row.detail}`;\n\n/**\n * Component to display a combined list of detailed items from one or more sources, where the items\n * are keyed primarily by Scripture reference. This is particularly useful for displaying a list of\n * results from Scripture checks, but more generally could be used to display any \"results\" from any\n * source(s). The component allows for grouping by Scripture book, source, or both. By default, it\n * displays somewhat \"tree-like\" which allows it to be more horizontally compact and intuitive. But\n * it also has the option of displaying as a traditional table with column headings (with or without\n * the source column showing).\n */\nexport default function ScriptureResultsViewer({\n sources,\n showColumnHeaders = false,\n showSourceColumn = false,\n scriptureReferenceColumnName,\n scriptureBookGroupName,\n typeColumnName,\n detailsColumnName,\n onRowSelected,\n direction = 'ltr',\n}: ScriptureResultsViewerProps) {\n const [grouping, setGrouping] = useState([]);\n const [sorting, setSorting] = useState([{ id: scrBookColId, desc: false }]);\n const [rowSelection, setRowSelection] = useState({});\n\n const scriptureResults = useMemo(\n () =>\n sources.flatMap((source) => {\n return source.data.map((item) => ({\n ...item,\n source: source.source,\n }));\n }),\n [sources],\n );\n\n const columns = useMemo(\n () =>\n getColumns(\n {\n scriptureReferenceColumnName,\n typeColumnName,\n detailsColumnName,\n },\n showSourceColumn,\n ),\n [scriptureReferenceColumnName, typeColumnName, detailsColumnName, showSourceColumn],\n );\n\n useEffect(() => {\n // Ensure sorting is applied correctly when grouped by type\n if (grouping.includes(typeColId)) {\n setSorting([\n { id: typeColId, desc: false },\n { id: scrBookColId, desc: false },\n ]);\n } else {\n setSorting([{ id: scrBookColId, desc: false }]);\n }\n }, [grouping]);\n\n const table = useReactTable({\n data: scriptureResults,\n columns,\n state: {\n grouping,\n sorting,\n rowSelection,\n },\n onGroupingChange: setGrouping,\n onSortingChange: setSorting,\n onRowSelectionChange: setRowSelection,\n getExpandedRowModel: getExpandedRowModel(),\n getGroupedRowModel: getGroupedRowModel(),\n getCoreRowModel: getCoreRowModel(),\n getSortedRowModel: getSortedRowModel(),\n getRowId: getRowKey,\n autoResetExpanded: false,\n enableMultiRowSelection: false,\n enableSubRowSelection: false,\n });\n\n useEffect(() => {\n if (onRowSelected) {\n const selectedRows = table.getSelectedRowModel().rowsById;\n const keys = Object.keys(selectedRows);\n if (keys.length === 1) {\n const selectedRow = scriptureResults.find((row) => getRowKey(row) === keys[0]) || undefined;\n if (selectedRow) onRowSelected(selectedRow);\n }\n }\n }, [rowSelection, scriptureResults, onRowSelected, table]);\n\n // Define possible grouping options\n const scrBookGroupName = scriptureBookGroupName ?? defaultScrBookGroupName;\n const typeGroupName = typeColumnName ?? defaultTypeColumnName;\n\n const groupingOptions = [\n { label: 'No Grouping', value: [] },\n { label: `Group by ${scrBookGroupName}`, value: [scrBookColId] },\n { label: `Group by ${typeGroupName}`, value: [typeColId] },\n {\n label: `Group by ${scrBookGroupName} and ${typeGroupName}`,\n value: [scrBookColId, typeColId],\n },\n {\n label: `Group by ${typeGroupName} and ${scrBookGroupName}`,\n value: [typeColId, scrBookColId],\n },\n ];\n\n const handleSelectChange = (selectedGrouping: string) => {\n setGrouping(JSON.parse(selectedGrouping));\n };\n\n const handleRowClick = (row: Row, event: MouseEvent) => {\n if (!row.getIsGrouped() && !row.getIsSelected()) {\n row.getToggleSelectedHandler()(event);\n }\n };\n\n const getEvenOrOddBandingStyle = (row: Row, index: number) => {\n if (row.getIsGrouped()) return '';\n // UX has now said they don't think they want banding. I'm leaving in the code to\n // set even and odd styles, but there's nothing in the CSS to style them differently.\n // The \"even\" style used to also have tw-bg-neutral-300 (along with even) to create\n // a visual banding effect. That could be added back in if UX changes the decision.\n return cn('banded-row', index % 2 === 0 ? 'even' : 'odd');\n };\n\n const getIndent = (\n groupingState: GroupingState,\n row: Row,\n cell: Cell,\n ) => {\n if (groupingState?.length === 0 || row.depth < cell.column.getGroupedIndex()) return undefined;\n if (row.getIsGrouped()) {\n switch (row.depth) {\n case 1:\n return 'tw-ps-4';\n default:\n return undefined;\n }\n }\n switch (row.depth) {\n case 1:\n return 'tw-ps-8';\n case 2:\n return 'tw-ps-12';\n default:\n return undefined;\n }\n };\n\n return (\n
    \n {!showColumnHeaders && (\n {\n handleSelectChange(value);\n }}\n >\n \n \n \n \n \n {groupingOptions.map((option) => (\n \n {option.label}\n \n ))}\n \n \n \n )}\n \n {showColumnHeaders && (\n \n {table.getHeaderGroups().map((headerGroup) => (\n \n {headerGroup.headers\n .filter((h) => h.column.columnDef.header)\n .map((header) => (\n /* For sticky column headers to work, we probably need to change the default definition of the shadcn Table component. See https://github.com/shadcn-ui/ui/issues/1151 */\n \n {header.isPlaceholder ? undefined : (\n
    \n {header.column.getCanGroup() ? (\n \n {header.column.getIsGrouped() ? `🛑` : `👊 `}\n \n ) : undefined}{' '}\n {flexRender(header.column.columnDef.header, header.getContext())}\n
    \n )}\n
    \n ))}\n
    \n ))}\n
    \n )}\n \n {table.getRowModel().rows.map((row, rowIndex) => {\n return (\n handleRowClick(row, event)}\n >\n {row.getVisibleCells().map((cell) => {\n if (\n cell.getIsPlaceholder() ||\n (cell.column.columnDef.enableGrouping &&\n !cell.getIsGrouped() &&\n (cell.column.columnDef.id !== typeColId || !showSourceColumn))\n )\n return undefined;\n return (\n \n {(() => {\n if (cell.getIsGrouped()) {\n return (\n \n {row.getIsExpanded() && }\n {!row.getIsExpanded() &&\n (direction === 'ltr' ? : )}{' '}\n {flexRender(cell.column.columnDef.cell, cell.getContext())} (\n {row.subRows.length})\n \n );\n }\n\n // if (cell.getIsAggregated()) {\n // flexRender(\n // cell.column.columnDef.aggregatedCell ?? cell.column.columnDef.cell,\n // cell.getContext(),\n // );\n // }\n\n return flexRender(cell.column.columnDef.cell, cell.getContext());\n })()}\n \n );\n })}\n \n );\n })}\n \n
    \n
    \n );\n}\n","import {\n getLocalizeKeyForScrollGroupId,\n LanguageStrings,\n ScrollGroupId,\n} from 'platform-bible-utils';\nimport {\n Select,\n SelectContent,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\n\nconst DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS = {\n [getLocalizeKeyForScrollGroupId('undefined')]: 'Ø',\n [getLocalizeKeyForScrollGroupId(0)]: 'A',\n [getLocalizeKeyForScrollGroupId(1)]: 'B',\n [getLocalizeKeyForScrollGroupId(2)]: 'C',\n [getLocalizeKeyForScrollGroupId(3)]: 'D',\n [getLocalizeKeyForScrollGroupId(4)]: 'E',\n [getLocalizeKeyForScrollGroupId(5)]: 'F',\n [getLocalizeKeyForScrollGroupId(6)]: 'G',\n [getLocalizeKeyForScrollGroupId(7)]: 'H',\n [getLocalizeKeyForScrollGroupId(8)]: 'I',\n [getLocalizeKeyForScrollGroupId(9)]: 'J',\n [getLocalizeKeyForScrollGroupId(10)]: 'K',\n [getLocalizeKeyForScrollGroupId(11)]: 'L',\n [getLocalizeKeyForScrollGroupId(12)]: 'M',\n [getLocalizeKeyForScrollGroupId(13)]: 'N',\n [getLocalizeKeyForScrollGroupId(14)]: 'O',\n [getLocalizeKeyForScrollGroupId(15)]: 'P',\n [getLocalizeKeyForScrollGroupId(16)]: 'Q',\n [getLocalizeKeyForScrollGroupId(17)]: 'R',\n [getLocalizeKeyForScrollGroupId(18)]: 'S',\n [getLocalizeKeyForScrollGroupId(19)]: 'T',\n [getLocalizeKeyForScrollGroupId(20)]: 'U',\n [getLocalizeKeyForScrollGroupId(21)]: 'V',\n [getLocalizeKeyForScrollGroupId(22)]: 'W',\n [getLocalizeKeyForScrollGroupId(23)]: 'X',\n [getLocalizeKeyForScrollGroupId(24)]: 'Y',\n [getLocalizeKeyForScrollGroupId(25)]: 'Z',\n};\n\nexport type ScrollGroupSelectorProps = {\n /**\n * List of scroll group ids to show to the user. Either a {@link ScrollGroupId} or `undefined` for\n * no scroll group\n */\n availableScrollGroupIds: (ScrollGroupId | undefined)[];\n /** Currently selected scroll group id. `undefined` for no scroll group */\n scrollGroupId: ScrollGroupId | undefined;\n /** Callback function run when the user tries to change the scroll group id */\n onChangeScrollGroupId: (newScrollGroupId: ScrollGroupId | undefined) => void;\n /**\n * Localized strings to use for displaying scroll group ids. Must be an object whose keys are\n * `getLocalizeKeyForScrollGroupId(scrollGroupId)` for all scroll group ids (and `undefined` if\n * included) in {@link ScrollGroupSelectorProps.availableScrollGroupIds} and whose values are the\n * localized strings to use for those scroll group ids.\n *\n * Defaults to English localizations of English alphabet for scroll groups 0-25 (e.g. 0 is A) and\n * Ø for `undefined`. Will fill in any that are not provided with these English localizations.\n * Also, if any values match the keys, the English localization will be used. This is useful in\n * case you want to pass in a temporary version of the localized strings while your localized\n * strings load.\n *\n * @example\n *\n * ```typescript\n * const myScrollGroupIdLocalizedStrings = {\n * [getLocalizeKeyForScrollGroupId('undefined')]: 'Ø',\n * [getLocalizeKeyForScrollGroupId(0)]: 'A',\n * [getLocalizeKeyForScrollGroupId(1)]: 'B',\n * [getLocalizeKeyForScrollGroupId(2)]: 'C',\n * [getLocalizeKeyForScrollGroupId(3)]: 'D',\n * [getLocalizeKeyForScrollGroupId(4)]: 'E',\n * };\n * ```\n *\n * @example\n *\n * ```tsx\n * const availableScrollGroupIds = [undefined, 0, 1, 2, 3, 4];\n *\n * const localizeKeys = getLocalizeKeysForScrollGroupIds();\n *\n * const [localizedStrings] = useLocalizedStrings(localizeKeys);\n *\n * ...\n *\n * \n * ```\n */\n localizedStrings?: LanguageStrings;\n};\n\n/** Selector component for choosing a scroll group */\nexport default function ScrollGroupSelector({\n availableScrollGroupIds,\n scrollGroupId,\n onChangeScrollGroupId,\n localizedStrings = {},\n}: ScrollGroupSelectorProps) {\n const localizedStringsDefaulted = {\n ...DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS,\n ...Object.fromEntries(\n Object.entries(localizedStrings).map(\n ([localizedStringKey, localizedStringValue]: [string, string]) => [\n localizedStringKey,\n localizedStringKey === localizedStringValue &&\n localizedStringKey in DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS\n ? DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS[localizedStringKey]\n : localizedStringValue,\n ],\n ),\n ),\n };\n return (\n \n onChangeScrollGroupId(\n newScrollGroupString === 'undefined' ? undefined : parseInt(newScrollGroupString, 10),\n )\n }\n >\n \n \n \n \n {availableScrollGroupIds.map((scrollGroupOptionId) => (\n \n {localizedStringsDefaulted[getLocalizeKeyForScrollGroupId(scrollGroupOptionId)]}\n \n ))}\n \n \n );\n}\n","import { PropsWithChildren } from 'react';\nimport { Separator } from '@/components/shadcn-ui/separator';\n\n/** Props for the SettingsList component, currently just children */\ntype SettingsListProps = PropsWithChildren;\n\n/**\n * SettingsList component is a wrapper for list items. Rendered with a formatted div\n *\n * @param children To populate the list with\n * @returns Formatted div encompassing the children\n */\nexport function SettingsList({ children }: SettingsListProps) {\n return
    {children}
    ;\n}\n\n/** Props for SettingsListItem component */\ntype SettingsListItemProps = PropsWithChildren & {\n /** Primary text of the list item */\n primary: string;\n\n /** Optional text of the list item */\n secondary?: string | undefined;\n\n /** Optional boolean to display a message if the children aren't loaded yet. Defaults to false */\n isLoading?: boolean;\n\n /** Optional message to display if isLoading */\n loadingMessage?: string;\n};\n\n/**\n * SettingsListItem component is a common list item. Rendered with a formatted div\n *\n * @param primary Primary text of the list item\n * @param secondary Optional secondary text of the list item\n * @param isLoading Optional, to display a message if the action component isn't generated yet,\n * defaults to false\n * @param children The action component(s) to provide for this item\n * @param loadingMessage Optional, message to display if isLoading\n * @returns Formatted div encompassing the list item content\n */\nexport function SettingsListItem({\n primary,\n secondary,\n children,\n isLoading = false,\n loadingMessage,\n}: SettingsListItemProps) {\n return (\n
    \n
    \n

    {primary}

    \n

    \n {secondary}\n

    \n
    \n\n {isLoading ? (\n

    {loadingMessage}

    \n ) : (\n
    {children}
    \n )}\n
    \n );\n}\n\n/** Props for SettingsListHeader component */\ntype SettingsListHeaderProps = {\n /** The primary text of the list header */\n primary: string;\n\n /** Optional secondary text of the list header */\n secondary?: string | undefined;\n\n /** Optional boolean to include a separator underneath the secondary text. Defaults to false */\n includeSeparator?: boolean;\n};\n\n/**\n * SettingsListHeader component displays text above the list\n *\n * @param primary The primary text of the list header\n * @param secondary Optional secondary text of the list header\n * @param includeSeparator Optional boolean to include a separator underneath the secondary text.\n * Defaults to false\n * @returns Formatted div with list header content\n */\nexport function SettingsListHeader({\n primary,\n secondary,\n includeSeparator = false,\n}: SettingsListHeaderProps) {\n return (\n
    \n
    \n

    {primary}

    \n

    {secondary}

    \n
    \n {includeSeparator ? : ''}\n
    \n );\n}\n","import React from 'react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Card = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nCard.displayName = 'Card';\n\nconst CardHeader = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nCardHeader.displayName = 'CardHeader';\n\nconst CardTitle = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n {/* added because of https://github.com/jsx-eslint/eslint-plugin-jsx-a11y/blob/main/docs/rules/heading-has-content.md */}\n {props.children}\n \n ),\n);\nCardTitle.displayName = 'CardTitle';\n\nconst CardDescription = React.forwardRef<\n HTMLParagraphElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n

    \n));\nCardDescription.displayName = 'CardDescription';\n\nconst CardContent = React.forwardRef>(\n ({ className, ...props }, ref) => (\n

    \n ),\n);\nCardContent.displayName = 'CardContent';\n\nconst CardFooter = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nCardFooter.displayName = 'CardFooter';\n\nexport { Card, CardHeader, CardFooter, CardTitle, CardDescription, CardContent };\n","import { Card, CardDescription, CardHeader, CardTitle } from '@/components/shadcn-ui/card';\nimport { CardContent } from '@mui/material';\nimport { PropsWithChildren } from 'react';\n\ntype SettingsCardProps = PropsWithChildren & {\n /** Optional id for testing */\n id?: string;\n\n /** Label of the settings group */\n settingsGroupLabel: string;\n\n /** Optional description of the settings group */\n settingsGroupDescription?: string;\n};\n\nexport default function SettingsCard({\n id,\n settingsGroupLabel,\n settingsGroupDescription,\n children,\n}: SettingsCardProps) {\n return (\n \n \n {settingsGroupLabel}\n {settingsGroupDescription && {settingsGroupDescription}}\n \n {children}\n \n );\n}\n","import Checkbox from '@/components/shadcn-ui/checkbox';\nimport { Label } from '@/components/shadcn-ui/label';\n\nexport type ChecklistProps = {\n /** Optional string representing the id attribute of the Checklist */\n id?: string;\n /** Optional string representing CSS class name(s) for styling */\n className?: string;\n /** Array of strings representing the checkable items */\n listItems: string[];\n /** Array of strings representing the checked items */\n selectedListItems: string[];\n /**\n * Function that is called when a checkbox item is selected or deselected\n *\n * @param item The string description for this item\n * @param selected True if selected, false if not selected\n */\n handleSelectListItem: (item: string, selected: boolean) => void;\n\n /**\n * Optional function creates a label for a provided checkable item\n *\n * @param item The item for which a label is to be created\n * @returns A string representing the label text for the checkbox associated with that item\n */\n createLabel?: (item: string) => string;\n};\n\n/** Renders a list of checkboxes. Each checkbox corresponds to an item from the `listItems` array. */\nexport default function Checklist({\n id,\n className,\n listItems,\n selectedListItems,\n handleSelectListItem,\n createLabel,\n}: ChecklistProps) {\n return (\n
    \n {listItems.map((item) => (\n
    \n handleSelectListItem(item, value)}\n />\n \n
    \n ))}\n
    \n );\n}\n","function _interopRequireDefault(obj) {\n return obj && obj.__esModule ? obj : {\n \"default\": obj\n };\n}\nmodule.exports = _interopRequireDefault, module.exports.__esModule = true, module.exports[\"default\"] = module.exports;","export default function chainPropTypes(propType1, propType2) {\n if (process.env.NODE_ENV === 'production') {\n return () => null;\n }\n return function validate(...args) {\n return propType1(...args) || propType2(...args);\n };\n}","export default function _extends() {\n _extends = Object.assign ? Object.assign.bind() : function (target) {\n for (var i = 1; i < arguments.length; i++) {\n var source = arguments[i];\n for (var key in source) {\n if (Object.prototype.hasOwnProperty.call(source, key)) {\n target[key] = source[key];\n }\n }\n }\n return target;\n };\n return _extends.apply(this, arguments);\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\n// https://github.com/sindresorhus/is-plain-obj/blob/main/index.js\nexport function isPlainObject(item) {\n if (typeof item !== 'object' || item === null) {\n return false;\n }\n const prototype = Object.getPrototypeOf(item);\n return (prototype === null || prototype === Object.prototype || Object.getPrototypeOf(prototype) === null) && !(Symbol.toStringTag in item) && !(Symbol.iterator in item);\n}\nfunction deepClone(source) {\n if (!isPlainObject(source)) {\n return source;\n }\n const output = {};\n Object.keys(source).forEach(key => {\n output[key] = deepClone(source[key]);\n });\n return output;\n}\nexport default function deepmerge(target, source, options = {\n clone: true\n}) {\n const output = options.clone ? _extends({}, target) : target;\n if (isPlainObject(target) && isPlainObject(source)) {\n Object.keys(source).forEach(key => {\n // Avoid prototype pollution\n if (key === '__proto__') {\n return;\n }\n if (isPlainObject(source[key]) && key in target && isPlainObject(target[key])) {\n // Since `output` is a clone of `target` and we have narrowed `target` in this block we can cast to the same type.\n output[key] = deepmerge(target[key], source[key], options);\n } else if (options.clone) {\n output[key] = isPlainObject(source[key]) ? deepClone(source[key]) : source[key];\n } else {\n output[key] = source[key];\n }\n });\n }\n return output;\n}","/** @license React v16.13.1\n * react-is.production.min.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';var b=\"function\"===typeof Symbol&&Symbol.for,c=b?Symbol.for(\"react.element\"):60103,d=b?Symbol.for(\"react.portal\"):60106,e=b?Symbol.for(\"react.fragment\"):60107,f=b?Symbol.for(\"react.strict_mode\"):60108,g=b?Symbol.for(\"react.profiler\"):60114,h=b?Symbol.for(\"react.provider\"):60109,k=b?Symbol.for(\"react.context\"):60110,l=b?Symbol.for(\"react.async_mode\"):60111,m=b?Symbol.for(\"react.concurrent_mode\"):60111,n=b?Symbol.for(\"react.forward_ref\"):60112,p=b?Symbol.for(\"react.suspense\"):60113,q=b?\nSymbol.for(\"react.suspense_list\"):60120,r=b?Symbol.for(\"react.memo\"):60115,t=b?Symbol.for(\"react.lazy\"):60116,v=b?Symbol.for(\"react.block\"):60121,w=b?Symbol.for(\"react.fundamental\"):60117,x=b?Symbol.for(\"react.responder\"):60118,y=b?Symbol.for(\"react.scope\"):60119;\nfunction z(a){if(\"object\"===typeof a&&null!==a){var u=a.$$typeof;switch(u){case c:switch(a=a.type,a){case l:case m:case e:case g:case f:case p:return a;default:switch(a=a&&a.$$typeof,a){case k:case n:case t:case r:case h:return a;default:return u}}case d:return u}}}function A(a){return z(a)===m}exports.AsyncMode=l;exports.ConcurrentMode=m;exports.ContextConsumer=k;exports.ContextProvider=h;exports.Element=c;exports.ForwardRef=n;exports.Fragment=e;exports.Lazy=t;exports.Memo=r;exports.Portal=d;\nexports.Profiler=g;exports.StrictMode=f;exports.Suspense=p;exports.isAsyncMode=function(a){return A(a)||z(a)===l};exports.isConcurrentMode=A;exports.isContextConsumer=function(a){return z(a)===k};exports.isContextProvider=function(a){return z(a)===h};exports.isElement=function(a){return\"object\"===typeof a&&null!==a&&a.$$typeof===c};exports.isForwardRef=function(a){return z(a)===n};exports.isFragment=function(a){return z(a)===e};exports.isLazy=function(a){return z(a)===t};\nexports.isMemo=function(a){return z(a)===r};exports.isPortal=function(a){return z(a)===d};exports.isProfiler=function(a){return z(a)===g};exports.isStrictMode=function(a){return z(a)===f};exports.isSuspense=function(a){return z(a)===p};\nexports.isValidElementType=function(a){return\"string\"===typeof a||\"function\"===typeof a||a===e||a===m||a===g||a===f||a===p||a===q||\"object\"===typeof a&&null!==a&&(a.$$typeof===t||a.$$typeof===r||a.$$typeof===h||a.$$typeof===k||a.$$typeof===n||a.$$typeof===w||a.$$typeof===x||a.$$typeof===y||a.$$typeof===v)};exports.typeOf=z;\n","/** @license React v16.13.1\n * react-is.development.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\n\n\nif (process.env.NODE_ENV !== \"production\") {\n (function() {\n'use strict';\n\n// The Symbol used to tag the ReactElement-like types. If there is no native Symbol\n// nor polyfill, then a plain number is used for performance.\nvar hasSymbol = typeof Symbol === 'function' && Symbol.for;\nvar REACT_ELEMENT_TYPE = hasSymbol ? Symbol.for('react.element') : 0xeac7;\nvar REACT_PORTAL_TYPE = hasSymbol ? Symbol.for('react.portal') : 0xeaca;\nvar REACT_FRAGMENT_TYPE = hasSymbol ? Symbol.for('react.fragment') : 0xeacb;\nvar REACT_STRICT_MODE_TYPE = hasSymbol ? Symbol.for('react.strict_mode') : 0xeacc;\nvar REACT_PROFILER_TYPE = hasSymbol ? Symbol.for('react.profiler') : 0xead2;\nvar REACT_PROVIDER_TYPE = hasSymbol ? Symbol.for('react.provider') : 0xeacd;\nvar REACT_CONTEXT_TYPE = hasSymbol ? Symbol.for('react.context') : 0xeace; // TODO: We don't use AsyncMode or ConcurrentMode anymore. They were temporary\n// (unstable) APIs that have been removed. Can we remove the symbols?\n\nvar REACT_ASYNC_MODE_TYPE = hasSymbol ? Symbol.for('react.async_mode') : 0xeacf;\nvar REACT_CONCURRENT_MODE_TYPE = hasSymbol ? Symbol.for('react.concurrent_mode') : 0xeacf;\nvar REACT_FORWARD_REF_TYPE = hasSymbol ? Symbol.for('react.forward_ref') : 0xead0;\nvar REACT_SUSPENSE_TYPE = hasSymbol ? Symbol.for('react.suspense') : 0xead1;\nvar REACT_SUSPENSE_LIST_TYPE = hasSymbol ? Symbol.for('react.suspense_list') : 0xead8;\nvar REACT_MEMO_TYPE = hasSymbol ? Symbol.for('react.memo') : 0xead3;\nvar REACT_LAZY_TYPE = hasSymbol ? Symbol.for('react.lazy') : 0xead4;\nvar REACT_BLOCK_TYPE = hasSymbol ? Symbol.for('react.block') : 0xead9;\nvar REACT_FUNDAMENTAL_TYPE = hasSymbol ? Symbol.for('react.fundamental') : 0xead5;\nvar REACT_RESPONDER_TYPE = hasSymbol ? Symbol.for('react.responder') : 0xead6;\nvar REACT_SCOPE_TYPE = hasSymbol ? Symbol.for('react.scope') : 0xead7;\n\nfunction isValidElementType(type) {\n return typeof type === 'string' || typeof type === 'function' || // Note: its typeof might be other than 'symbol' or 'number' if it's a polyfill.\n type === REACT_FRAGMENT_TYPE || type === REACT_CONCURRENT_MODE_TYPE || type === REACT_PROFILER_TYPE || type === REACT_STRICT_MODE_TYPE || type === REACT_SUSPENSE_TYPE || type === REACT_SUSPENSE_LIST_TYPE || typeof type === 'object' && type !== null && (type.$$typeof === REACT_LAZY_TYPE || type.$$typeof === REACT_MEMO_TYPE || type.$$typeof === REACT_PROVIDER_TYPE || type.$$typeof === REACT_CONTEXT_TYPE || type.$$typeof === REACT_FORWARD_REF_TYPE || type.$$typeof === REACT_FUNDAMENTAL_TYPE || type.$$typeof === REACT_RESPONDER_TYPE || type.$$typeof === REACT_SCOPE_TYPE || type.$$typeof === REACT_BLOCK_TYPE);\n}\n\nfunction typeOf(object) {\n if (typeof object === 'object' && object !== null) {\n var $$typeof = object.$$typeof;\n\n switch ($$typeof) {\n case REACT_ELEMENT_TYPE:\n var type = object.type;\n\n switch (type) {\n case REACT_ASYNC_MODE_TYPE:\n case REACT_CONCURRENT_MODE_TYPE:\n case REACT_FRAGMENT_TYPE:\n case REACT_PROFILER_TYPE:\n case REACT_STRICT_MODE_TYPE:\n case REACT_SUSPENSE_TYPE:\n return type;\n\n default:\n var $$typeofType = type && type.$$typeof;\n\n switch ($$typeofType) {\n case REACT_CONTEXT_TYPE:\n case REACT_FORWARD_REF_TYPE:\n case REACT_LAZY_TYPE:\n case REACT_MEMO_TYPE:\n case REACT_PROVIDER_TYPE:\n return $$typeofType;\n\n default:\n return $$typeof;\n }\n\n }\n\n case REACT_PORTAL_TYPE:\n return $$typeof;\n }\n }\n\n return undefined;\n} // AsyncMode is deprecated along with isAsyncMode\n\nvar AsyncMode = REACT_ASYNC_MODE_TYPE;\nvar ConcurrentMode = REACT_CONCURRENT_MODE_TYPE;\nvar ContextConsumer = REACT_CONTEXT_TYPE;\nvar ContextProvider = REACT_PROVIDER_TYPE;\nvar Element = REACT_ELEMENT_TYPE;\nvar ForwardRef = REACT_FORWARD_REF_TYPE;\nvar Fragment = REACT_FRAGMENT_TYPE;\nvar Lazy = REACT_LAZY_TYPE;\nvar Memo = REACT_MEMO_TYPE;\nvar Portal = REACT_PORTAL_TYPE;\nvar Profiler = REACT_PROFILER_TYPE;\nvar StrictMode = REACT_STRICT_MODE_TYPE;\nvar Suspense = REACT_SUSPENSE_TYPE;\nvar hasWarnedAboutDeprecatedIsAsyncMode = false; // AsyncMode should be deprecated\n\nfunction isAsyncMode(object) {\n {\n if (!hasWarnedAboutDeprecatedIsAsyncMode) {\n hasWarnedAboutDeprecatedIsAsyncMode = true; // Using console['warn'] to evade Babel and ESLint\n\n console['warn']('The ReactIs.isAsyncMode() alias has been deprecated, ' + 'and will be removed in React 17+. Update your code to use ' + 'ReactIs.isConcurrentMode() instead. It has the exact same API.');\n }\n }\n\n return isConcurrentMode(object) || typeOf(object) === REACT_ASYNC_MODE_TYPE;\n}\nfunction isConcurrentMode(object) {\n return typeOf(object) === REACT_CONCURRENT_MODE_TYPE;\n}\nfunction isContextConsumer(object) {\n return typeOf(object) === REACT_CONTEXT_TYPE;\n}\nfunction isContextProvider(object) {\n return typeOf(object) === REACT_PROVIDER_TYPE;\n}\nfunction isElement(object) {\n return typeof object === 'object' && object !== null && object.$$typeof === REACT_ELEMENT_TYPE;\n}\nfunction isForwardRef(object) {\n return typeOf(object) === REACT_FORWARD_REF_TYPE;\n}\nfunction isFragment(object) {\n return typeOf(object) === REACT_FRAGMENT_TYPE;\n}\nfunction isLazy(object) {\n return typeOf(object) === REACT_LAZY_TYPE;\n}\nfunction isMemo(object) {\n return typeOf(object) === REACT_MEMO_TYPE;\n}\nfunction isPortal(object) {\n return typeOf(object) === REACT_PORTAL_TYPE;\n}\nfunction isProfiler(object) {\n return typeOf(object) === REACT_PROFILER_TYPE;\n}\nfunction isStrictMode(object) {\n return typeOf(object) === REACT_STRICT_MODE_TYPE;\n}\nfunction isSuspense(object) {\n return typeOf(object) === REACT_SUSPENSE_TYPE;\n}\n\nexports.AsyncMode = AsyncMode;\nexports.ConcurrentMode = ConcurrentMode;\nexports.ContextConsumer = ContextConsumer;\nexports.ContextProvider = ContextProvider;\nexports.Element = Element;\nexports.ForwardRef = ForwardRef;\nexports.Fragment = Fragment;\nexports.Lazy = Lazy;\nexports.Memo = Memo;\nexports.Portal = Portal;\nexports.Profiler = Profiler;\nexports.StrictMode = StrictMode;\nexports.Suspense = Suspense;\nexports.isAsyncMode = isAsyncMode;\nexports.isConcurrentMode = isConcurrentMode;\nexports.isContextConsumer = isContextConsumer;\nexports.isContextProvider = isContextProvider;\nexports.isElement = isElement;\nexports.isForwardRef = isForwardRef;\nexports.isFragment = isFragment;\nexports.isLazy = isLazy;\nexports.isMemo = isMemo;\nexports.isPortal = isPortal;\nexports.isProfiler = isProfiler;\nexports.isStrictMode = isStrictMode;\nexports.isSuspense = isSuspense;\nexports.isValidElementType = isValidElementType;\nexports.typeOf = typeOf;\n })();\n}\n","'use strict';\n\nif (process.env.NODE_ENV === 'production') {\n module.exports = require('./cjs/react-is.production.min.js');\n} else {\n module.exports = require('./cjs/react-is.development.js');\n}\n","/*\nobject-assign\n(c) Sindre Sorhus\n@license MIT\n*/\n\n'use strict';\n/* eslint-disable no-unused-vars */\nvar getOwnPropertySymbols = Object.getOwnPropertySymbols;\nvar hasOwnProperty = Object.prototype.hasOwnProperty;\nvar propIsEnumerable = Object.prototype.propertyIsEnumerable;\n\nfunction toObject(val) {\n\tif (val === null || val === undefined) {\n\t\tthrow new TypeError('Object.assign cannot be called with null or undefined');\n\t}\n\n\treturn Object(val);\n}\n\nfunction shouldUseNative() {\n\ttry {\n\t\tif (!Object.assign) {\n\t\t\treturn false;\n\t\t}\n\n\t\t// Detect buggy property enumeration order in older V8 versions.\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=4118\n\t\tvar test1 = new String('abc'); // eslint-disable-line no-new-wrappers\n\t\ttest1[5] = 'de';\n\t\tif (Object.getOwnPropertyNames(test1)[0] === '5') {\n\t\t\treturn false;\n\t\t}\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=3056\n\t\tvar test2 = {};\n\t\tfor (var i = 0; i < 10; i++) {\n\t\t\ttest2['_' + String.fromCharCode(i)] = i;\n\t\t}\n\t\tvar order2 = Object.getOwnPropertyNames(test2).map(function (n) {\n\t\t\treturn test2[n];\n\t\t});\n\t\tif (order2.join('') !== '0123456789') {\n\t\t\treturn false;\n\t\t}\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=3056\n\t\tvar test3 = {};\n\t\t'abcdefghijklmnopqrst'.split('').forEach(function (letter) {\n\t\t\ttest3[letter] = letter;\n\t\t});\n\t\tif (Object.keys(Object.assign({}, test3)).join('') !==\n\t\t\t\t'abcdefghijklmnopqrst') {\n\t\t\treturn false;\n\t\t}\n\n\t\treturn true;\n\t} catch (err) {\n\t\t// We don't expect any of the above to throw, but better to be safe.\n\t\treturn false;\n\t}\n}\n\nmodule.exports = shouldUseNative() ? Object.assign : function (target, source) {\n\tvar from;\n\tvar to = toObject(target);\n\tvar symbols;\n\n\tfor (var s = 1; s < arguments.length; s++) {\n\t\tfrom = Object(arguments[s]);\n\n\t\tfor (var key in from) {\n\t\t\tif (hasOwnProperty.call(from, key)) {\n\t\t\t\tto[key] = from[key];\n\t\t\t}\n\t\t}\n\n\t\tif (getOwnPropertySymbols) {\n\t\t\tsymbols = getOwnPropertySymbols(from);\n\t\t\tfor (var i = 0; i < symbols.length; i++) {\n\t\t\t\tif (propIsEnumerable.call(from, symbols[i])) {\n\t\t\t\t\tto[symbols[i]] = from[symbols[i]];\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\n\treturn to;\n};\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar ReactPropTypesSecret = 'SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED';\n\nmodule.exports = ReactPropTypesSecret;\n","module.exports = Function.call.bind(Object.prototype.hasOwnProperty);\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar printWarning = function() {};\n\nif (process.env.NODE_ENV !== 'production') {\n var ReactPropTypesSecret = require('./lib/ReactPropTypesSecret');\n var loggedTypeFailures = {};\n var has = require('./lib/has');\n\n printWarning = function(text) {\n var message = 'Warning: ' + text;\n if (typeof console !== 'undefined') {\n console.error(message);\n }\n try {\n // --- Welcome to debugging React ---\n // This error was thrown as a convenience so that you can use this stack\n // to find the callsite that caused this warning to fire.\n throw new Error(message);\n } catch (x) { /**/ }\n };\n}\n\n/**\n * Assert that the values match with the type specs.\n * Error messages are memorized and will only be shown once.\n *\n * @param {object} typeSpecs Map of name to a ReactPropType\n * @param {object} values Runtime values that need to be type-checked\n * @param {string} location e.g. \"prop\", \"context\", \"child context\"\n * @param {string} componentName Name of the component for error messages.\n * @param {?Function} getStack Returns the component stack.\n * @private\n */\nfunction checkPropTypes(typeSpecs, values, location, componentName, getStack) {\n if (process.env.NODE_ENV !== 'production') {\n for (var typeSpecName in typeSpecs) {\n if (has(typeSpecs, typeSpecName)) {\n var error;\n // Prop type validation may throw. In case they do, we don't want to\n // fail the render phase where it didn't fail before. So we log it.\n // After these have been cleaned up, we'll let them throw.\n try {\n // This is intentionally an invariant that gets caught. It's the same\n // behavior as without this statement except with a better message.\n if (typeof typeSpecs[typeSpecName] !== 'function') {\n var err = Error(\n (componentName || 'React class') + ': ' + location + ' type `' + typeSpecName + '` is invalid; ' +\n 'it must be a function, usually from the `prop-types` package, but received `' + typeof typeSpecs[typeSpecName] + '`.' +\n 'This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.'\n );\n err.name = 'Invariant Violation';\n throw err;\n }\n error = typeSpecs[typeSpecName](values, typeSpecName, componentName, location, null, ReactPropTypesSecret);\n } catch (ex) {\n error = ex;\n }\n if (error && !(error instanceof Error)) {\n printWarning(\n (componentName || 'React class') + ': type specification of ' +\n location + ' `' + typeSpecName + '` is invalid; the type checker ' +\n 'function must return `null` or an `Error` but returned a ' + typeof error + '. ' +\n 'You may have forgotten to pass an argument to the type checker ' +\n 'creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and ' +\n 'shape all require an argument).'\n );\n }\n if (error instanceof Error && !(error.message in loggedTypeFailures)) {\n // Only monitor this failure once because there tends to be a lot of the\n // same error.\n loggedTypeFailures[error.message] = true;\n\n var stack = getStack ? getStack() : '';\n\n printWarning(\n 'Failed ' + location + ' type: ' + error.message + (stack != null ? stack : '')\n );\n }\n }\n }\n }\n}\n\n/**\n * Resets warning cache when testing.\n *\n * @private\n */\ncheckPropTypes.resetWarningCache = function() {\n if (process.env.NODE_ENV !== 'production') {\n loggedTypeFailures = {};\n }\n}\n\nmodule.exports = checkPropTypes;\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar ReactIs = require('react-is');\nvar assign = require('object-assign');\n\nvar ReactPropTypesSecret = require('./lib/ReactPropTypesSecret');\nvar has = require('./lib/has');\nvar checkPropTypes = require('./checkPropTypes');\n\nvar printWarning = function() {};\n\nif (process.env.NODE_ENV !== 'production') {\n printWarning = function(text) {\n var message = 'Warning: ' + text;\n if (typeof console !== 'undefined') {\n console.error(message);\n }\n try {\n // --- Welcome to debugging React ---\n // This error was thrown as a convenience so that you can use this stack\n // to find the callsite that caused this warning to fire.\n throw new Error(message);\n } catch (x) {}\n };\n}\n\nfunction emptyFunctionThatReturnsNull() {\n return null;\n}\n\nmodule.exports = function(isValidElement, throwOnDirectAccess) {\n /* global Symbol */\n var ITERATOR_SYMBOL = typeof Symbol === 'function' && Symbol.iterator;\n var FAUX_ITERATOR_SYMBOL = '@@iterator'; // Before Symbol spec.\n\n /**\n * Returns the iterator method function contained on the iterable object.\n *\n * Be sure to invoke the function with the iterable as context:\n *\n * var iteratorFn = getIteratorFn(myIterable);\n * if (iteratorFn) {\n * var iterator = iteratorFn.call(myIterable);\n * ...\n * }\n *\n * @param {?object} maybeIterable\n * @return {?function}\n */\n function getIteratorFn(maybeIterable) {\n var iteratorFn = maybeIterable && (ITERATOR_SYMBOL && maybeIterable[ITERATOR_SYMBOL] || maybeIterable[FAUX_ITERATOR_SYMBOL]);\n if (typeof iteratorFn === 'function') {\n return iteratorFn;\n }\n }\n\n /**\n * Collection of methods that allow declaration and validation of props that are\n * supplied to React components. Example usage:\n *\n * var Props = require('ReactPropTypes');\n * var MyArticle = React.createClass({\n * propTypes: {\n * // An optional string prop named \"description\".\n * description: Props.string,\n *\n * // A required enum prop named \"category\".\n * category: Props.oneOf(['News','Photos']).isRequired,\n *\n * // A prop named \"dialog\" that requires an instance of Dialog.\n * dialog: Props.instanceOf(Dialog).isRequired\n * },\n * render: function() { ... }\n * });\n *\n * A more formal specification of how these methods are used:\n *\n * type := array|bool|func|object|number|string|oneOf([...])|instanceOf(...)\n * decl := ReactPropTypes.{type}(.isRequired)?\n *\n * Each and every declaration produces a function with the same signature. This\n * allows the creation of custom validation functions. For example:\n *\n * var MyLink = React.createClass({\n * propTypes: {\n * // An optional string or URI prop named \"href\".\n * href: function(props, propName, componentName) {\n * var propValue = props[propName];\n * if (propValue != null && typeof propValue !== 'string' &&\n * !(propValue instanceof URI)) {\n * return new Error(\n * 'Expected a string or an URI for ' + propName + ' in ' +\n * componentName\n * );\n * }\n * }\n * },\n * render: function() {...}\n * });\n *\n * @internal\n */\n\n var ANONYMOUS = '<>';\n\n // Important!\n // Keep this list in sync with production version in `./factoryWithThrowingShims.js`.\n var ReactPropTypes = {\n array: createPrimitiveTypeChecker('array'),\n bigint: createPrimitiveTypeChecker('bigint'),\n bool: createPrimitiveTypeChecker('boolean'),\n func: createPrimitiveTypeChecker('function'),\n number: createPrimitiveTypeChecker('number'),\n object: createPrimitiveTypeChecker('object'),\n string: createPrimitiveTypeChecker('string'),\n symbol: createPrimitiveTypeChecker('symbol'),\n\n any: createAnyTypeChecker(),\n arrayOf: createArrayOfTypeChecker,\n element: createElementTypeChecker(),\n elementType: createElementTypeTypeChecker(),\n instanceOf: createInstanceTypeChecker,\n node: createNodeChecker(),\n objectOf: createObjectOfTypeChecker,\n oneOf: createEnumTypeChecker,\n oneOfType: createUnionTypeChecker,\n shape: createShapeTypeChecker,\n exact: createStrictShapeTypeChecker,\n };\n\n /**\n * inlined Object.is polyfill to avoid requiring consumers ship their own\n * https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object/is\n */\n /*eslint-disable no-self-compare*/\n function is(x, y) {\n // SameValue algorithm\n if (x === y) {\n // Steps 1-5, 7-10\n // Steps 6.b-6.e: +0 != -0\n return x !== 0 || 1 / x === 1 / y;\n } else {\n // Step 6.a: NaN == NaN\n return x !== x && y !== y;\n }\n }\n /*eslint-enable no-self-compare*/\n\n /**\n * We use an Error-like object for backward compatibility as people may call\n * PropTypes directly and inspect their output. However, we don't use real\n * Errors anymore. We don't inspect their stack anyway, and creating them\n * is prohibitively expensive if they are created too often, such as what\n * happens in oneOfType() for any type before the one that matched.\n */\n function PropTypeError(message, data) {\n this.message = message;\n this.data = data && typeof data === 'object' ? data: {};\n this.stack = '';\n }\n // Make `instanceof Error` still work for returned errors.\n PropTypeError.prototype = Error.prototype;\n\n function createChainableTypeChecker(validate) {\n if (process.env.NODE_ENV !== 'production') {\n var manualPropTypeCallCache = {};\n var manualPropTypeWarningCount = 0;\n }\n function checkType(isRequired, props, propName, componentName, location, propFullName, secret) {\n componentName = componentName || ANONYMOUS;\n propFullName = propFullName || propName;\n\n if (secret !== ReactPropTypesSecret) {\n if (throwOnDirectAccess) {\n // New behavior only for users of `prop-types` package\n var err = new Error(\n 'Calling PropTypes validators directly is not supported by the `prop-types` package. ' +\n 'Use `PropTypes.checkPropTypes()` to call them. ' +\n 'Read more at http://fb.me/use-check-prop-types'\n );\n err.name = 'Invariant Violation';\n throw err;\n } else if (process.env.NODE_ENV !== 'production' && typeof console !== 'undefined') {\n // Old behavior for people using React.PropTypes\n var cacheKey = componentName + ':' + propName;\n if (\n !manualPropTypeCallCache[cacheKey] &&\n // Avoid spamming the console because they are often not actionable except for lib authors\n manualPropTypeWarningCount < 3\n ) {\n printWarning(\n 'You are manually calling a React.PropTypes validation ' +\n 'function for the `' + propFullName + '` prop on `' + componentName + '`. This is deprecated ' +\n 'and will throw in the standalone `prop-types` package. ' +\n 'You may be seeing this warning due to a third-party PropTypes ' +\n 'library. See https://fb.me/react-warning-dont-call-proptypes ' + 'for details.'\n );\n manualPropTypeCallCache[cacheKey] = true;\n manualPropTypeWarningCount++;\n }\n }\n }\n if (props[propName] == null) {\n if (isRequired) {\n if (props[propName] === null) {\n return new PropTypeError('The ' + location + ' `' + propFullName + '` is marked as required ' + ('in `' + componentName + '`, but its value is `null`.'));\n }\n return new PropTypeError('The ' + location + ' `' + propFullName + '` is marked as required in ' + ('`' + componentName + '`, but its value is `undefined`.'));\n }\n return null;\n } else {\n return validate(props, propName, componentName, location, propFullName);\n }\n }\n\n var chainedCheckType = checkType.bind(null, false);\n chainedCheckType.isRequired = checkType.bind(null, true);\n\n return chainedCheckType;\n }\n\n function createPrimitiveTypeChecker(expectedType) {\n function validate(props, propName, componentName, location, propFullName, secret) {\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== expectedType) {\n // `propValue` being instance of, say, date/regexp, pass the 'object'\n // check, but we can offer a more precise error message here rather than\n // 'of type `object`'.\n var preciseType = getPreciseType(propValue);\n\n return new PropTypeError(\n 'Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + preciseType + '` supplied to `' + componentName + '`, expected ') + ('`' + expectedType + '`.'),\n {expectedType: expectedType}\n );\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createAnyTypeChecker() {\n return createChainableTypeChecker(emptyFunctionThatReturnsNull);\n }\n\n function createArrayOfTypeChecker(typeChecker) {\n function validate(props, propName, componentName, location, propFullName) {\n if (typeof typeChecker !== 'function') {\n return new PropTypeError('Property `' + propFullName + '` of component `' + componentName + '` has invalid PropType notation inside arrayOf.');\n }\n var propValue = props[propName];\n if (!Array.isArray(propValue)) {\n var propType = getPropType(propValue);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected an array.'));\n }\n for (var i = 0; i < propValue.length; i++) {\n var error = typeChecker(propValue, i, componentName, location, propFullName + '[' + i + ']', ReactPropTypesSecret);\n if (error instanceof Error) {\n return error;\n }\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createElementTypeChecker() {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n if (!isValidElement(propValue)) {\n var propType = getPropType(propValue);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected a single ReactElement.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createElementTypeTypeChecker() {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n if (!ReactIs.isValidElementType(propValue)) {\n var propType = getPropType(propValue);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected a single ReactElement type.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createInstanceTypeChecker(expectedClass) {\n function validate(props, propName, componentName, location, propFullName) {\n if (!(props[propName] instanceof expectedClass)) {\n var expectedClassName = expectedClass.name || ANONYMOUS;\n var actualClassName = getClassName(props[propName]);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + actualClassName + '` supplied to `' + componentName + '`, expected ') + ('instance of `' + expectedClassName + '`.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createEnumTypeChecker(expectedValues) {\n if (!Array.isArray(expectedValues)) {\n if (process.env.NODE_ENV !== 'production') {\n if (arguments.length > 1) {\n printWarning(\n 'Invalid arguments supplied to oneOf, expected an array, got ' + arguments.length + ' arguments. ' +\n 'A common mistake is to write oneOf(x, y, z) instead of oneOf([x, y, z]).'\n );\n } else {\n printWarning('Invalid argument supplied to oneOf, expected an array.');\n }\n }\n return emptyFunctionThatReturnsNull;\n }\n\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n for (var i = 0; i < expectedValues.length; i++) {\n if (is(propValue, expectedValues[i])) {\n return null;\n }\n }\n\n var valuesString = JSON.stringify(expectedValues, function replacer(key, value) {\n var type = getPreciseType(value);\n if (type === 'symbol') {\n return String(value);\n }\n return value;\n });\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of value `' + String(propValue) + '` ' + ('supplied to `' + componentName + '`, expected one of ' + valuesString + '.'));\n }\n return createChainableTypeChecker(validate);\n }\n\n function createObjectOfTypeChecker(typeChecker) {\n function validate(props, propName, componentName, location, propFullName) {\n if (typeof typeChecker !== 'function') {\n return new PropTypeError('Property `' + propFullName + '` of component `' + componentName + '` has invalid PropType notation inside objectOf.');\n }\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== 'object') {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected an object.'));\n }\n for (var key in propValue) {\n if (has(propValue, key)) {\n var error = typeChecker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret);\n if (error instanceof Error) {\n return error;\n }\n }\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createUnionTypeChecker(arrayOfTypeCheckers) {\n if (!Array.isArray(arrayOfTypeCheckers)) {\n process.env.NODE_ENV !== 'production' ? printWarning('Invalid argument supplied to oneOfType, expected an instance of array.') : void 0;\n return emptyFunctionThatReturnsNull;\n }\n\n for (var i = 0; i < arrayOfTypeCheckers.length; i++) {\n var checker = arrayOfTypeCheckers[i];\n if (typeof checker !== 'function') {\n printWarning(\n 'Invalid argument supplied to oneOfType. Expected an array of check functions, but ' +\n 'received ' + getPostfixForTypeWarning(checker) + ' at index ' + i + '.'\n );\n return emptyFunctionThatReturnsNull;\n }\n }\n\n function validate(props, propName, componentName, location, propFullName) {\n var expectedTypes = [];\n for (var i = 0; i < arrayOfTypeCheckers.length; i++) {\n var checker = arrayOfTypeCheckers[i];\n var checkerResult = checker(props, propName, componentName, location, propFullName, ReactPropTypesSecret);\n if (checkerResult == null) {\n return null;\n }\n if (checkerResult.data && has(checkerResult.data, 'expectedType')) {\n expectedTypes.push(checkerResult.data.expectedType);\n }\n }\n var expectedTypesMessage = (expectedTypes.length > 0) ? ', expected one of type [' + expectedTypes.join(', ') + ']': '';\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` supplied to ' + ('`' + componentName + '`' + expectedTypesMessage + '.'));\n }\n return createChainableTypeChecker(validate);\n }\n\n function createNodeChecker() {\n function validate(props, propName, componentName, location, propFullName) {\n if (!isNode(props[propName])) {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` supplied to ' + ('`' + componentName + '`, expected a ReactNode.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function invalidValidatorError(componentName, location, propFullName, key, type) {\n return new PropTypeError(\n (componentName || 'React class') + ': ' + location + ' type `' + propFullName + '.' + key + '` is invalid; ' +\n 'it must be a function, usually from the `prop-types` package, but received `' + type + '`.'\n );\n }\n\n function createShapeTypeChecker(shapeTypes) {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== 'object') {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type `' + propType + '` ' + ('supplied to `' + componentName + '`, expected `object`.'));\n }\n for (var key in shapeTypes) {\n var checker = shapeTypes[key];\n if (typeof checker !== 'function') {\n return invalidValidatorError(componentName, location, propFullName, key, getPreciseType(checker));\n }\n var error = checker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret);\n if (error) {\n return error;\n }\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createStrictShapeTypeChecker(shapeTypes) {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== 'object') {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type `' + propType + '` ' + ('supplied to `' + componentName + '`, expected `object`.'));\n }\n // We need to check all keys in case some are required but missing from props.\n var allKeys = assign({}, props[propName], shapeTypes);\n for (var key in allKeys) {\n var checker = shapeTypes[key];\n if (has(shapeTypes, key) && typeof checker !== 'function') {\n return invalidValidatorError(componentName, location, propFullName, key, getPreciseType(checker));\n }\n if (!checker) {\n return new PropTypeError(\n 'Invalid ' + location + ' `' + propFullName + '` key `' + key + '` supplied to `' + componentName + '`.' +\n '\\nBad object: ' + JSON.stringify(props[propName], null, ' ') +\n '\\nValid keys: ' + JSON.stringify(Object.keys(shapeTypes), null, ' ')\n );\n }\n var error = checker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret);\n if (error) {\n return error;\n }\n }\n return null;\n }\n\n return createChainableTypeChecker(validate);\n }\n\n function isNode(propValue) {\n switch (typeof propValue) {\n case 'number':\n case 'string':\n case 'undefined':\n return true;\n case 'boolean':\n return !propValue;\n case 'object':\n if (Array.isArray(propValue)) {\n return propValue.every(isNode);\n }\n if (propValue === null || isValidElement(propValue)) {\n return true;\n }\n\n var iteratorFn = getIteratorFn(propValue);\n if (iteratorFn) {\n var iterator = iteratorFn.call(propValue);\n var step;\n if (iteratorFn !== propValue.entries) {\n while (!(step = iterator.next()).done) {\n if (!isNode(step.value)) {\n return false;\n }\n }\n } else {\n // Iterator will provide entry [k,v] tuples rather than values.\n while (!(step = iterator.next()).done) {\n var entry = step.value;\n if (entry) {\n if (!isNode(entry[1])) {\n return false;\n }\n }\n }\n }\n } else {\n return false;\n }\n\n return true;\n default:\n return false;\n }\n }\n\n function isSymbol(propType, propValue) {\n // Native Symbol.\n if (propType === 'symbol') {\n return true;\n }\n\n // falsy value can't be a Symbol\n if (!propValue) {\n return false;\n }\n\n // 19.4.3.5 Symbol.prototype[@@toStringTag] === 'Symbol'\n if (propValue['@@toStringTag'] === 'Symbol') {\n return true;\n }\n\n // Fallback for non-spec compliant Symbols which are polyfilled.\n if (typeof Symbol === 'function' && propValue instanceof Symbol) {\n return true;\n }\n\n return false;\n }\n\n // Equivalent of `typeof` but with special handling for array and regexp.\n function getPropType(propValue) {\n var propType = typeof propValue;\n if (Array.isArray(propValue)) {\n return 'array';\n }\n if (propValue instanceof RegExp) {\n // Old webkits (at least until Android 4.0) return 'function' rather than\n // 'object' for typeof a RegExp. We'll normalize this here so that /bla/\n // passes PropTypes.object.\n return 'object';\n }\n if (isSymbol(propType, propValue)) {\n return 'symbol';\n }\n return propType;\n }\n\n // This handles more types than `getPropType`. Only used for error messages.\n // See `createPrimitiveTypeChecker`.\n function getPreciseType(propValue) {\n if (typeof propValue === 'undefined' || propValue === null) {\n return '' + propValue;\n }\n var propType = getPropType(propValue);\n if (propType === 'object') {\n if (propValue instanceof Date) {\n return 'date';\n } else if (propValue instanceof RegExp) {\n return 'regexp';\n }\n }\n return propType;\n }\n\n // Returns a string that is postfixed to a warning about an invalid type.\n // For example, \"undefined\" or \"of type array\"\n function getPostfixForTypeWarning(value) {\n var type = getPreciseType(value);\n switch (type) {\n case 'array':\n case 'object':\n return 'an ' + type;\n case 'boolean':\n case 'date':\n case 'regexp':\n return 'a ' + type;\n default:\n return type;\n }\n }\n\n // Returns class name of the object, if any.\n function getClassName(propValue) {\n if (!propValue.constructor || !propValue.constructor.name) {\n return ANONYMOUS;\n }\n return propValue.constructor.name;\n }\n\n ReactPropTypes.checkPropTypes = checkPropTypes;\n ReactPropTypes.resetWarningCache = checkPropTypes.resetWarningCache;\n ReactPropTypes.PropTypes = ReactPropTypes;\n\n return ReactPropTypes;\n};\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar ReactPropTypesSecret = require('./lib/ReactPropTypesSecret');\n\nfunction emptyFunction() {}\nfunction emptyFunctionWithReset() {}\nemptyFunctionWithReset.resetWarningCache = emptyFunction;\n\nmodule.exports = function() {\n function shim(props, propName, componentName, location, propFullName, secret) {\n if (secret === ReactPropTypesSecret) {\n // It is still safe when called from React.\n return;\n }\n var err = new Error(\n 'Calling PropTypes validators directly is not supported by the `prop-types` package. ' +\n 'Use PropTypes.checkPropTypes() to call them. ' +\n 'Read more at http://fb.me/use-check-prop-types'\n );\n err.name = 'Invariant Violation';\n throw err;\n };\n shim.isRequired = shim;\n function getShim() {\n return shim;\n };\n // Important!\n // Keep this list in sync with production version in `./factoryWithTypeCheckers.js`.\n var ReactPropTypes = {\n array: shim,\n bigint: shim,\n bool: shim,\n func: shim,\n number: shim,\n object: shim,\n string: shim,\n symbol: shim,\n\n any: shim,\n arrayOf: getShim,\n element: shim,\n elementType: shim,\n instanceOf: getShim,\n node: shim,\n objectOf: getShim,\n oneOf: getShim,\n oneOfType: getShim,\n shape: getShim,\n exact: getShim,\n\n checkPropTypes: emptyFunctionWithReset,\n resetWarningCache: emptyFunction\n };\n\n ReactPropTypes.PropTypes = ReactPropTypes;\n\n return ReactPropTypes;\n};\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\nif (process.env.NODE_ENV !== 'production') {\n var ReactIs = require('react-is');\n\n // By explicitly using `prop-types` you are opting into new development behavior.\n // http://fb.me/prop-types-in-prod\n var throwOnDirectAccess = true;\n module.exports = require('./factoryWithTypeCheckers')(ReactIs.isElement, throwOnDirectAccess);\n} else {\n // By explicitly using `prop-types` you are opting into new production behavior.\n // http://fb.me/prop-types-in-prod\n module.exports = require('./factoryWithThrowingShims')();\n}\n","import PropTypes from 'prop-types';\nimport chainPropTypes from '../chainPropTypes';\nfunction isClassComponent(elementType) {\n // elementType.prototype?.isReactComponent\n const {\n prototype = {}\n } = elementType;\n return Boolean(prototype.isReactComponent);\n}\nfunction acceptingRef(props, propName, componentName, location, propFullName) {\n const element = props[propName];\n const safePropName = propFullName || propName;\n if (element == null ||\n // When server-side rendering React doesn't warn either.\n // This is not an accurate check for SSR.\n // This is only in place for Emotion compat.\n // TODO: Revisit once https://github.com/facebook/react/issues/20047 is resolved.\n typeof window === 'undefined') {\n return null;\n }\n let warningHint;\n const elementType = element.type;\n /**\n * Blacklisting instead of whitelisting\n *\n * Blacklisting will miss some components, such as React.Fragment. Those will at least\n * trigger a warning in React.\n * We can't whitelist because there is no safe way to detect React.forwardRef\n * or class components. \"Safe\" means there's no public API.\n *\n */\n if (typeof elementType === 'function' && !isClassComponent(elementType)) {\n warningHint = 'Did you accidentally use a plain function component for an element instead?';\n }\n if (warningHint !== undefined) {\n return new Error(`Invalid ${location} \\`${safePropName}\\` supplied to \\`${componentName}\\`. ` + `Expected an element that can hold a ref. ${warningHint} ` + 'For more information see https://mui.com/r/caveat-with-refs-guide');\n }\n return null;\n}\nconst elementAcceptingRef = chainPropTypes(PropTypes.element, acceptingRef);\nelementAcceptingRef.isRequired = chainPropTypes(PropTypes.element.isRequired, acceptingRef);\nexport default elementAcceptingRef;","import _extends from \"@babel/runtime/helpers/esm/extends\";\n// This module is based on https://github.com/airbnb/prop-types-exact repository.\n// However, in order to reduce the number of dependencies and to remove some extra safe checks\n// the module was forked.\n\nconst specialProperty = 'exact-prop: \\u200b';\nexport default function exactProp(propTypes) {\n if (process.env.NODE_ENV === 'production') {\n return propTypes;\n }\n return _extends({}, propTypes, {\n [specialProperty]: props => {\n const unsupportedProps = Object.keys(props).filter(prop => !propTypes.hasOwnProperty(prop));\n if (unsupportedProps.length > 0) {\n return new Error(`The following props are not supported: ${unsupportedProps.map(prop => `\\`${prop}\\``).join(', ')}. Please remove them.`);\n }\n return null;\n }\n });\n}","/**\n * WARNING: Don't import this directly.\n * Use `MuiError` from `@mui/internal-babel-macros/MuiError.macro` instead.\n * @param {number} code\n */\nexport default function formatMuiErrorMessage(code) {\n // Apply babel-plugin-transform-template-literals in loose mode\n // loose mode is safe if we're concatenating primitives\n // see https://babeljs.io/docs/en/babel-plugin-transform-template-literals#loose\n /* eslint-disable prefer-template */\n let url = 'https://mui.com/production-error/?code=' + code;\n for (let i = 1; i < arguments.length; i += 1) {\n // rest params over-transpile for this case\n // eslint-disable-next-line prefer-rest-params\n url += '&args[]=' + encodeURIComponent(arguments[i]);\n }\n return 'Minified MUI error #' + code + '; visit ' + url + ' for the full message.';\n /* eslint-enable prefer-template */\n}","/**\n * @license React\n * react-is.production.min.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n'use strict';var b=Symbol.for(\"react.element\"),c=Symbol.for(\"react.portal\"),d=Symbol.for(\"react.fragment\"),e=Symbol.for(\"react.strict_mode\"),f=Symbol.for(\"react.profiler\"),g=Symbol.for(\"react.provider\"),h=Symbol.for(\"react.context\"),k=Symbol.for(\"react.server_context\"),l=Symbol.for(\"react.forward_ref\"),m=Symbol.for(\"react.suspense\"),n=Symbol.for(\"react.suspense_list\"),p=Symbol.for(\"react.memo\"),q=Symbol.for(\"react.lazy\"),t=Symbol.for(\"react.offscreen\"),u;u=Symbol.for(\"react.module.reference\");\nfunction v(a){if(\"object\"===typeof a&&null!==a){var r=a.$$typeof;switch(r){case b:switch(a=a.type,a){case d:case f:case e:case m:case n:return a;default:switch(a=a&&a.$$typeof,a){case k:case h:case l:case q:case p:case g:return a;default:return r}}case c:return r}}}exports.ContextConsumer=h;exports.ContextProvider=g;exports.Element=b;exports.ForwardRef=l;exports.Fragment=d;exports.Lazy=q;exports.Memo=p;exports.Portal=c;exports.Profiler=f;exports.StrictMode=e;exports.Suspense=m;\nexports.SuspenseList=n;exports.isAsyncMode=function(){return!1};exports.isConcurrentMode=function(){return!1};exports.isContextConsumer=function(a){return v(a)===h};exports.isContextProvider=function(a){return v(a)===g};exports.isElement=function(a){return\"object\"===typeof a&&null!==a&&a.$$typeof===b};exports.isForwardRef=function(a){return v(a)===l};exports.isFragment=function(a){return v(a)===d};exports.isLazy=function(a){return v(a)===q};exports.isMemo=function(a){return v(a)===p};\nexports.isPortal=function(a){return v(a)===c};exports.isProfiler=function(a){return v(a)===f};exports.isStrictMode=function(a){return v(a)===e};exports.isSuspense=function(a){return v(a)===m};exports.isSuspenseList=function(a){return v(a)===n};\nexports.isValidElementType=function(a){return\"string\"===typeof a||\"function\"===typeof a||a===d||a===f||a===e||a===m||a===n||a===t||\"object\"===typeof a&&null!==a&&(a.$$typeof===q||a.$$typeof===p||a.$$typeof===g||a.$$typeof===h||a.$$typeof===l||a.$$typeof===u||void 0!==a.getModuleId)?!0:!1};exports.typeOf=v;\n","/**\n * @license React\n * react-is.development.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nif (process.env.NODE_ENV !== \"production\") {\n (function() {\n'use strict';\n\n// ATTENTION\n// When adding new symbols to this file,\n// Please consider also adding to 'react-devtools-shared/src/backend/ReactSymbols'\n// The Symbol used to tag the ReactElement-like types.\nvar REACT_ELEMENT_TYPE = Symbol.for('react.element');\nvar REACT_PORTAL_TYPE = Symbol.for('react.portal');\nvar REACT_FRAGMENT_TYPE = Symbol.for('react.fragment');\nvar REACT_STRICT_MODE_TYPE = Symbol.for('react.strict_mode');\nvar REACT_PROFILER_TYPE = Symbol.for('react.profiler');\nvar REACT_PROVIDER_TYPE = Symbol.for('react.provider');\nvar REACT_CONTEXT_TYPE = Symbol.for('react.context');\nvar REACT_SERVER_CONTEXT_TYPE = Symbol.for('react.server_context');\nvar REACT_FORWARD_REF_TYPE = Symbol.for('react.forward_ref');\nvar REACT_SUSPENSE_TYPE = Symbol.for('react.suspense');\nvar REACT_SUSPENSE_LIST_TYPE = Symbol.for('react.suspense_list');\nvar REACT_MEMO_TYPE = Symbol.for('react.memo');\nvar REACT_LAZY_TYPE = Symbol.for('react.lazy');\nvar REACT_OFFSCREEN_TYPE = Symbol.for('react.offscreen');\n\n// -----------------------------------------------------------------------------\n\nvar enableScopeAPI = false; // Experimental Create Event Handle API.\nvar enableCacheElement = false;\nvar enableTransitionTracing = false; // No known bugs, but needs performance testing\n\nvar enableLegacyHidden = false; // Enables unstable_avoidThisFallback feature in Fiber\n// stuff. Intended to enable React core members to more easily debug scheduling\n// issues in DEV builds.\n\nvar enableDebugTracing = false; // Track which Fiber(s) schedule render work.\n\nvar REACT_MODULE_REFERENCE;\n\n{\n REACT_MODULE_REFERENCE = Symbol.for('react.module.reference');\n}\n\nfunction isValidElementType(type) {\n if (typeof type === 'string' || typeof type === 'function') {\n return true;\n } // Note: typeof might be other than 'symbol' or 'number' (e.g. if it's a polyfill).\n\n\n if (type === REACT_FRAGMENT_TYPE || type === REACT_PROFILER_TYPE || enableDebugTracing || type === REACT_STRICT_MODE_TYPE || type === REACT_SUSPENSE_TYPE || type === REACT_SUSPENSE_LIST_TYPE || enableLegacyHidden || type === REACT_OFFSCREEN_TYPE || enableScopeAPI || enableCacheElement || enableTransitionTracing ) {\n return true;\n }\n\n if (typeof type === 'object' && type !== null) {\n if (type.$$typeof === REACT_LAZY_TYPE || type.$$typeof === REACT_MEMO_TYPE || type.$$typeof === REACT_PROVIDER_TYPE || type.$$typeof === REACT_CONTEXT_TYPE || type.$$typeof === REACT_FORWARD_REF_TYPE || // This needs to include all possible module reference object\n // types supported by any Flight configuration anywhere since\n // we don't know which Flight build this will end up being used\n // with.\n type.$$typeof === REACT_MODULE_REFERENCE || type.getModuleId !== undefined) {\n return true;\n }\n }\n\n return false;\n}\n\nfunction typeOf(object) {\n if (typeof object === 'object' && object !== null) {\n var $$typeof = object.$$typeof;\n\n switch ($$typeof) {\n case REACT_ELEMENT_TYPE:\n var type = object.type;\n\n switch (type) {\n case REACT_FRAGMENT_TYPE:\n case REACT_PROFILER_TYPE:\n case REACT_STRICT_MODE_TYPE:\n case REACT_SUSPENSE_TYPE:\n case REACT_SUSPENSE_LIST_TYPE:\n return type;\n\n default:\n var $$typeofType = type && type.$$typeof;\n\n switch ($$typeofType) {\n case REACT_SERVER_CONTEXT_TYPE:\n case REACT_CONTEXT_TYPE:\n case REACT_FORWARD_REF_TYPE:\n case REACT_LAZY_TYPE:\n case REACT_MEMO_TYPE:\n case REACT_PROVIDER_TYPE:\n return $$typeofType;\n\n default:\n return $$typeof;\n }\n\n }\n\n case REACT_PORTAL_TYPE:\n return $$typeof;\n }\n }\n\n return undefined;\n}\nvar ContextConsumer = REACT_CONTEXT_TYPE;\nvar ContextProvider = REACT_PROVIDER_TYPE;\nvar Element = REACT_ELEMENT_TYPE;\nvar ForwardRef = REACT_FORWARD_REF_TYPE;\nvar Fragment = REACT_FRAGMENT_TYPE;\nvar Lazy = REACT_LAZY_TYPE;\nvar Memo = REACT_MEMO_TYPE;\nvar Portal = REACT_PORTAL_TYPE;\nvar Profiler = REACT_PROFILER_TYPE;\nvar StrictMode = REACT_STRICT_MODE_TYPE;\nvar Suspense = REACT_SUSPENSE_TYPE;\nvar SuspenseList = REACT_SUSPENSE_LIST_TYPE;\nvar hasWarnedAboutDeprecatedIsAsyncMode = false;\nvar hasWarnedAboutDeprecatedIsConcurrentMode = false; // AsyncMode should be deprecated\n\nfunction isAsyncMode(object) {\n {\n if (!hasWarnedAboutDeprecatedIsAsyncMode) {\n hasWarnedAboutDeprecatedIsAsyncMode = true; // Using console['warn'] to evade Babel and ESLint\n\n console['warn']('The ReactIs.isAsyncMode() alias has been deprecated, ' + 'and will be removed in React 18+.');\n }\n }\n\n return false;\n}\nfunction isConcurrentMode(object) {\n {\n if (!hasWarnedAboutDeprecatedIsConcurrentMode) {\n hasWarnedAboutDeprecatedIsConcurrentMode = true; // Using console['warn'] to evade Babel and ESLint\n\n console['warn']('The ReactIs.isConcurrentMode() alias has been deprecated, ' + 'and will be removed in React 18+.');\n }\n }\n\n return false;\n}\nfunction isContextConsumer(object) {\n return typeOf(object) === REACT_CONTEXT_TYPE;\n}\nfunction isContextProvider(object) {\n return typeOf(object) === REACT_PROVIDER_TYPE;\n}\nfunction isElement(object) {\n return typeof object === 'object' && object !== null && object.$$typeof === REACT_ELEMENT_TYPE;\n}\nfunction isForwardRef(object) {\n return typeOf(object) === REACT_FORWARD_REF_TYPE;\n}\nfunction isFragment(object) {\n return typeOf(object) === REACT_FRAGMENT_TYPE;\n}\nfunction isLazy(object) {\n return typeOf(object) === REACT_LAZY_TYPE;\n}\nfunction isMemo(object) {\n return typeOf(object) === REACT_MEMO_TYPE;\n}\nfunction isPortal(object) {\n return typeOf(object) === REACT_PORTAL_TYPE;\n}\nfunction isProfiler(object) {\n return typeOf(object) === REACT_PROFILER_TYPE;\n}\nfunction isStrictMode(object) {\n return typeOf(object) === REACT_STRICT_MODE_TYPE;\n}\nfunction isSuspense(object) {\n return typeOf(object) === REACT_SUSPENSE_TYPE;\n}\nfunction isSuspenseList(object) {\n return typeOf(object) === REACT_SUSPENSE_LIST_TYPE;\n}\n\nexports.ContextConsumer = ContextConsumer;\nexports.ContextProvider = ContextProvider;\nexports.Element = Element;\nexports.ForwardRef = ForwardRef;\nexports.Fragment = Fragment;\nexports.Lazy = Lazy;\nexports.Memo = Memo;\nexports.Portal = Portal;\nexports.Profiler = Profiler;\nexports.StrictMode = StrictMode;\nexports.Suspense = Suspense;\nexports.SuspenseList = SuspenseList;\nexports.isAsyncMode = isAsyncMode;\nexports.isConcurrentMode = isConcurrentMode;\nexports.isContextConsumer = isContextConsumer;\nexports.isContextProvider = isContextProvider;\nexports.isElement = isElement;\nexports.isForwardRef = isForwardRef;\nexports.isFragment = isFragment;\nexports.isLazy = isLazy;\nexports.isMemo = isMemo;\nexports.isPortal = isPortal;\nexports.isProfiler = isProfiler;\nexports.isStrictMode = isStrictMode;\nexports.isSuspense = isSuspense;\nexports.isSuspenseList = isSuspenseList;\nexports.isValidElementType = isValidElementType;\nexports.typeOf = typeOf;\n })();\n}\n","'use strict';\n\nif (process.env.NODE_ENV === 'production') {\n module.exports = require('./cjs/react-is.production.min.js');\n} else {\n module.exports = require('./cjs/react-is.development.js');\n}\n","import { ForwardRef, Memo } from 'react-is';\n\n// Simplified polyfill for IE11 support\n// https://github.com/JamesMGreene/Function.name/blob/58b314d4a983110c3682f1228f845d39ccca1817/Function.name.js#L3\nconst fnNameMatchRegex = /^\\s*function(?:\\s|\\s*\\/\\*.*\\*\\/\\s*)+([^(\\s/]*)\\s*/;\nexport function getFunctionName(fn) {\n const match = `${fn}`.match(fnNameMatchRegex);\n const name = match && match[1];\n return name || '';\n}\nfunction getFunctionComponentName(Component, fallback = '') {\n return Component.displayName || Component.name || getFunctionName(Component) || fallback;\n}\nfunction getWrappedName(outerType, innerType, wrapperName) {\n const functionName = getFunctionComponentName(innerType);\n return outerType.displayName || (functionName !== '' ? `${wrapperName}(${functionName})` : wrapperName);\n}\n\n/**\n * cherry-pick from\n * https://github.com/facebook/react/blob/769b1f270e1251d9dbdce0fcbd9e92e502d059b8/packages/shared/getComponentName.js\n * originally forked from recompose/getDisplayName with added IE11 support\n */\nexport default function getDisplayName(Component) {\n if (Component == null) {\n return undefined;\n }\n if (typeof Component === 'string') {\n return Component;\n }\n if (typeof Component === 'function') {\n return getFunctionComponentName(Component, 'Component');\n }\n\n // TypeScript can't have components as objects but they exist in the form of `memo` or `Suspense`\n if (typeof Component === 'object') {\n switch (Component.$$typeof) {\n case ForwardRef:\n return getWrappedName(Component, Component.render, 'ForwardRef');\n case Memo:\n return getWrappedName(Component, Component.type, 'memo');\n default:\n return undefined;\n }\n }\n return undefined;\n}","export default function HTMLElementType(props, propName, componentName, location, propFullName) {\n if (process.env.NODE_ENV === 'production') {\n return null;\n }\n const propValue = props[propName];\n const safePropName = propFullName || propName;\n if (propValue == null) {\n return null;\n }\n if (propValue && propValue.nodeType !== 1) {\n return new Error(`Invalid ${location} \\`${safePropName}\\` supplied to \\`${componentName}\\`. ` + `Expected an HTMLElement.`);\n }\n return null;\n}","import PropTypes from 'prop-types';\nconst refType = PropTypes.oneOfType([PropTypes.func, PropTypes.object]);\nexport default refType;","import _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\n// It should to be noted that this function isn't equivalent to `text-transform: capitalize`.\n//\n// A strict capitalization should uppercase the first letter of each word in the sentence.\n// We only handle the first word.\nexport default function capitalize(string) {\n if (typeof string !== 'string') {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: \\`capitalize(string)\\` expects a string argument.` : _formatMuiErrorMessage(7));\n }\n return string.charAt(0).toUpperCase() + string.slice(1);\n}","/**\n * Safe chained function.\n *\n * Will only create a new function if needed,\n * otherwise will pass back existing functions or null.\n */\nexport default function createChainedFunction(...funcs) {\n return funcs.reduce((acc, func) => {\n if (func == null) {\n return acc;\n }\n return function chainedFunction(...args) {\n acc.apply(this, args);\n func.apply(this, args);\n };\n }, () => {});\n}","// Corresponds to 10 frames at 60 Hz.\n// A few bytes payload overhead when lodash/debounce is ~3 kB and debounce ~300 B.\nexport default function debounce(func, wait = 166) {\n let timeout;\n function debounced(...args) {\n const later = () => {\n // @ts-ignore\n func.apply(this, args);\n };\n clearTimeout(timeout);\n timeout = setTimeout(later, wait);\n }\n debounced.clear = () => {\n clearTimeout(timeout);\n };\n return debounced;\n}","export default function deprecatedPropType(validator, reason) {\n if (process.env.NODE_ENV === 'production') {\n return () => null;\n }\n return (props, propName, componentName, location, propFullName) => {\n const componentNameSafe = componentName || '<>';\n const propFullNameSafe = propFullName || propName;\n if (typeof props[propName] !== 'undefined') {\n return new Error(`The ${location} \\`${propFullNameSafe}\\` of ` + `\\`${componentNameSafe}\\` is deprecated. ${reason}`);\n }\n return null;\n };\n}","import * as React from 'react';\nexport default function isMuiElement(element, muiNames) {\n var _muiName, _element$type;\n return /*#__PURE__*/React.isValidElement(element) && muiNames.indexOf( // For server components `muiName` is avaialble in element.type._payload.value.muiName\n // relevant info - https://github.com/facebook/react/blob/2807d781a08db8e9873687fccc25c0f12b4fb3d4/packages/react/src/ReactLazy.js#L45\n // eslint-disable-next-line no-underscore-dangle\n (_muiName = element.type.muiName) != null ? _muiName : (_element$type = element.type) == null || (_element$type = _element$type._payload) == null || (_element$type = _element$type.value) == null ? void 0 : _element$type.muiName) !== -1;\n}","export default function ownerDocument(node) {\n return node && node.ownerDocument || document;\n}","import ownerDocument from '../ownerDocument';\nexport default function ownerWindow(node) {\n const doc = ownerDocument(node);\n return doc.defaultView || window;\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nexport default function requirePropFactory(componentNameInError, Component) {\n if (process.env.NODE_ENV === 'production') {\n return () => null;\n }\n\n // eslint-disable-next-line react/forbid-foreign-prop-types\n const prevPropTypes = Component ? _extends({}, Component.propTypes) : null;\n const requireProp = requiredProp => (props, propName, componentName, location, propFullName, ...args) => {\n const propFullNameSafe = propFullName || propName;\n const defaultTypeChecker = prevPropTypes == null ? void 0 : prevPropTypes[propFullNameSafe];\n if (defaultTypeChecker) {\n const typeCheckerResult = defaultTypeChecker(props, propName, componentName, location, propFullName, ...args);\n if (typeCheckerResult) {\n return typeCheckerResult;\n }\n }\n if (typeof props[propName] !== 'undefined' && !props[requiredProp]) {\n return new Error(`The prop \\`${propFullNameSafe}\\` of ` + `\\`${componentNameInError}\\` can only be used together with the \\`${requiredProp}\\` prop.`);\n }\n return null;\n };\n return requireProp;\n}","/**\n * TODO v5: consider making it private\n *\n * passes {value} to {ref}\n *\n * WARNING: Be sure to only call this inside a callback that is passed as a ref.\n * Otherwise, make sure to cleanup the previous {ref} if it changes. See\n * https://github.com/mui/material-ui/issues/13539\n *\n * Useful if you want to expose the ref of an inner component to the public API\n * while still using it inside the component.\n * @param ref A ref callback or ref object. If anything falsy, this is a no-op.\n */\nexport default function setRef(ref, value) {\n if (typeof ref === 'function') {\n ref(value);\n } else if (ref) {\n ref.current = value;\n }\n}","'use client';\n\nimport * as React from 'react';\n\n/**\n * A version of `React.useLayoutEffect` that does not show a warning when server-side rendering.\n * This is useful for effects that are only needed for client-side rendering but not for SSR.\n *\n * Before you use this hook, make sure to read https://gist.github.com/gaearon/e7d97cdf38a2907924ea12e4ebdf3c85\n * and confirm it doesn't apply to your use-case.\n */\nconst useEnhancedEffect = typeof window !== 'undefined' ? React.useLayoutEffect : React.useEffect;\nexport default useEnhancedEffect;","'use client';\n\nimport * as React from 'react';\nlet globalId = 0;\nfunction useGlobalId(idOverride) {\n const [defaultId, setDefaultId] = React.useState(idOverride);\n const id = idOverride || defaultId;\n React.useEffect(() => {\n if (defaultId == null) {\n // Fallback to this default id when possible.\n // Use the incrementing value for client-side rendering only.\n // We can't use it server-side.\n // If you want to use random values please consider the Birthday Problem: https://en.wikipedia.org/wiki/Birthday_problem\n globalId += 1;\n setDefaultId(`mui-${globalId}`);\n }\n }, [defaultId]);\n return id;\n}\n\n// downstream bundlers may remove unnecessary concatenation, but won't remove toString call -- Workaround for https://github.com/webpack/webpack/issues/14814\nconst maybeReactUseId = React['useId'.toString()];\n/**\n *\n * @example
    \n * @param idOverride\n * @returns {string}\n */\nexport default function useId(idOverride) {\n if (maybeReactUseId !== undefined) {\n const reactId = maybeReactUseId();\n return idOverride != null ? idOverride : reactId;\n }\n // eslint-disable-next-line react-hooks/rules-of-hooks -- `React.useId` is invariant at runtime.\n return useGlobalId(idOverride);\n}","export default function unsupportedProp(props, propName, componentName, location, propFullName) {\n if (process.env.NODE_ENV === 'production') {\n return null;\n }\n const propFullNameSafe = propFullName || propName;\n if (typeof props[propName] !== 'undefined') {\n return new Error(`The prop \\`${propFullNameSafe}\\` is not supported. Please remove it.`);\n }\n return null;\n}","'use client';\n\n/* eslint-disable react-hooks/rules-of-hooks, react-hooks/exhaustive-deps */\nimport * as React from 'react';\nexport default function useControlled({\n controlled,\n default: defaultProp,\n name,\n state = 'value'\n}) {\n // isControlled is ignored in the hook dependency lists as it should never change.\n const {\n current: isControlled\n } = React.useRef(controlled !== undefined);\n const [valueState, setValue] = React.useState(defaultProp);\n const value = isControlled ? controlled : valueState;\n if (process.env.NODE_ENV !== 'production') {\n React.useEffect(() => {\n if (isControlled !== (controlled !== undefined)) {\n console.error([`MUI: A component is changing the ${isControlled ? '' : 'un'}controlled ${state} state of ${name} to be ${isControlled ? 'un' : ''}controlled.`, 'Elements should not switch from uncontrolled to controlled (or vice versa).', `Decide between using a controlled or uncontrolled ${name} ` + 'element for the lifetime of the component.', \"The nature of the state is determined during the first render. It's considered controlled if the value is not `undefined`.\", 'More info: https://fb.me/react-controlled-components'].join('\\n'));\n }\n }, [state, name, controlled]);\n const {\n current: defaultValue\n } = React.useRef(defaultProp);\n React.useEffect(() => {\n if (!isControlled && defaultValue !== defaultProp) {\n console.error([`MUI: A component is changing the default ${state} state of an uncontrolled ${name} after being initialized. ` + `To suppress this warning opt to use a controlled ${name}.`].join('\\n'));\n }\n }, [JSON.stringify(defaultProp)]);\n }\n const setValueIfUncontrolled = React.useCallback(newValue => {\n if (!isControlled) {\n setValue(newValue);\n }\n }, []);\n return [value, setValueIfUncontrolled];\n}","'use client';\n\nimport * as React from 'react';\nimport useEnhancedEffect from '../useEnhancedEffect';\n\n/**\n * Inspired by https://github.com/facebook/react/issues/14099#issuecomment-440013892\n * See RFC in https://github.com/reactjs/rfcs/pull/220\n */\n\nfunction useEventCallback(fn) {\n const ref = React.useRef(fn);\n useEnhancedEffect(() => {\n ref.current = fn;\n });\n return React.useRef((...args) =>\n // @ts-expect-error hide `this`\n (0, ref.current)(...args)).current;\n}\nexport default useEventCallback;","'use client';\n\nimport * as React from 'react';\nimport setRef from '../setRef';\nexport default function useForkRef(...refs) {\n /**\n * This will create a new function if the refs passed to this hook change and are all defined.\n * This means react will call the old forkRef with `null` and the new forkRef\n * with the ref. Cleanup naturally emerges from this behavior.\n */\n return React.useMemo(() => {\n if (refs.every(ref => ref == null)) {\n return null;\n }\n return instance => {\n refs.forEach(ref => {\n setRef(ref, instance);\n });\n };\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, refs);\n}","'use client';\n\nimport * as React from 'react';\nconst UNINITIALIZED = {};\n\n/**\n * A React.useRef() that is initialized lazily with a function. Note that it accepts an optional\n * initialization argument, so the initialization function doesn't need to be an inline closure.\n *\n * @usage\n * const ref = useLazyRef(sortColumns, columns)\n */\nexport default function useLazyRef(init, initArg) {\n const ref = React.useRef(UNINITIALIZED);\n if (ref.current === UNINITIALIZED) {\n ref.current = init(initArg);\n }\n return ref;\n}","'use client';\n\nimport * as React from 'react';\nconst EMPTY = [];\n\n/**\n * A React.useEffect equivalent that runs once, when the component is mounted.\n */\nexport default function useOnMount(fn) {\n /* eslint-disable react-hooks/exhaustive-deps */\n React.useEffect(fn, EMPTY);\n /* eslint-enable react-hooks/exhaustive-deps */\n}","'use client';\n\nimport useLazyRef from '../useLazyRef/useLazyRef';\nimport useOnMount from '../useOnMount/useOnMount';\nexport class Timeout {\n constructor() {\n this.currentId = null;\n this.clear = () => {\n if (this.currentId !== null) {\n clearTimeout(this.currentId);\n this.currentId = null;\n }\n };\n this.disposeEffect = () => {\n return this.clear;\n };\n }\n static create() {\n return new Timeout();\n }\n /**\n * Executes `fn` after `delay`, clearing any previously scheduled call.\n */\n start(delay, fn) {\n this.clear();\n this.currentId = setTimeout(() => {\n this.currentId = null;\n fn();\n }, delay);\n }\n}\nexport default function useTimeout() {\n const timeout = useLazyRef(Timeout.create).current;\n useOnMount(timeout.disposeEffect);\n return timeout;\n}","'use client';\n\n// based on https://github.com/WICG/focus-visible/blob/v4.1.5/src/focus-visible.js\nimport * as React from 'react';\nimport { Timeout } from '../useTimeout/useTimeout';\nlet hadKeyboardEvent = true;\nlet hadFocusVisibleRecently = false;\nconst hadFocusVisibleRecentlyTimeout = new Timeout();\nconst inputTypesWhitelist = {\n text: true,\n search: true,\n url: true,\n tel: true,\n email: true,\n password: true,\n number: true,\n date: true,\n month: true,\n week: true,\n time: true,\n datetime: true,\n 'datetime-local': true\n};\n\n/**\n * Computes whether the given element should automatically trigger the\n * `focus-visible` class being added, i.e. whether it should always match\n * `:focus-visible` when focused.\n * @param {Element} node\n * @returns {boolean}\n */\nfunction focusTriggersKeyboardModality(node) {\n const {\n type,\n tagName\n } = node;\n if (tagName === 'INPUT' && inputTypesWhitelist[type] && !node.readOnly) {\n return true;\n }\n if (tagName === 'TEXTAREA' && !node.readOnly) {\n return true;\n }\n if (node.isContentEditable) {\n return true;\n }\n return false;\n}\n\n/**\n * Keep track of our keyboard modality state with `hadKeyboardEvent`.\n * If the most recent user interaction was via the keyboard;\n * and the key press did not include a meta, alt/option, or control key;\n * then the modality is keyboard. Otherwise, the modality is not keyboard.\n * @param {KeyboardEvent} event\n */\nfunction handleKeyDown(event) {\n if (event.metaKey || event.altKey || event.ctrlKey) {\n return;\n }\n hadKeyboardEvent = true;\n}\n\n/**\n * If at any point a user clicks with a pointing device, ensure that we change\n * the modality away from keyboard.\n * This avoids the situation where a user presses a key on an already focused\n * element, and then clicks on a different element, focusing it with a\n * pointing device, while we still think we're in keyboard modality.\n */\nfunction handlePointerDown() {\n hadKeyboardEvent = false;\n}\nfunction handleVisibilityChange() {\n if (this.visibilityState === 'hidden') {\n // If the tab becomes active again, the browser will handle calling focus\n // on the element (Safari actually calls it twice).\n // If this tab change caused a blur on an element with focus-visible,\n // re-apply the class when the user switches back to the tab.\n if (hadFocusVisibleRecently) {\n hadKeyboardEvent = true;\n }\n }\n}\nfunction prepare(doc) {\n doc.addEventListener('keydown', handleKeyDown, true);\n doc.addEventListener('mousedown', handlePointerDown, true);\n doc.addEventListener('pointerdown', handlePointerDown, true);\n doc.addEventListener('touchstart', handlePointerDown, true);\n doc.addEventListener('visibilitychange', handleVisibilityChange, true);\n}\nexport function teardown(doc) {\n doc.removeEventListener('keydown', handleKeyDown, true);\n doc.removeEventListener('mousedown', handlePointerDown, true);\n doc.removeEventListener('pointerdown', handlePointerDown, true);\n doc.removeEventListener('touchstart', handlePointerDown, true);\n doc.removeEventListener('visibilitychange', handleVisibilityChange, true);\n}\nfunction isFocusVisible(event) {\n const {\n target\n } = event;\n try {\n return target.matches(':focus-visible');\n } catch (error) {\n // Browsers not implementing :focus-visible will throw a SyntaxError.\n // We use our own heuristic for those browsers.\n // Rethrow might be better if it's not the expected error but do we really\n // want to crash if focus-visible malfunctioned?\n }\n\n // No need for validFocusTarget check. The user does that by attaching it to\n // focusable events only.\n return hadKeyboardEvent || focusTriggersKeyboardModality(target);\n}\nexport default function useIsFocusVisible() {\n const ref = React.useCallback(node => {\n if (node != null) {\n prepare(node.ownerDocument);\n }\n }, []);\n const isFocusVisibleRef = React.useRef(false);\n\n /**\n * Should be called if a blur event is fired\n */\n function handleBlurVisible() {\n // checking against potential state variable does not suffice if we focus and blur synchronously.\n // React wouldn't have time to trigger a re-render so `focusVisible` would be stale.\n // Ideally we would adjust `isFocusVisible(event)` to look at `relatedTarget` for blur events.\n // This doesn't work in IE11 due to https://github.com/facebook/react/issues/3751\n // TODO: check again if React releases their internal changes to focus event handling (https://github.com/facebook/react/pull/19186).\n if (isFocusVisibleRef.current) {\n // To detect a tab/window switch, we look for a blur event followed\n // rapidly by a visibility change.\n // If we don't see a visibility change within 100ms, it's probably a\n // regular focus change.\n hadFocusVisibleRecently = true;\n hadFocusVisibleRecentlyTimeout.start(100, () => {\n hadFocusVisibleRecently = false;\n });\n isFocusVisibleRef.current = false;\n return true;\n }\n return false;\n }\n\n /**\n * Should be called if a blur event is fired\n */\n function handleFocusVisible(event) {\n if (isFocusVisible(event)) {\n isFocusVisibleRef.current = true;\n return true;\n }\n return false;\n }\n return {\n isFocusVisibleRef,\n onFocus: handleFocusVisible,\n onBlur: handleBlurVisible,\n ref\n };\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\n/**\n * Add keys, values of `defaultProps` that does not exist in `props`\n * @param {object} defaultProps\n * @param {object} props\n * @returns {object} resolved props\n */\nexport default function resolveProps(defaultProps, props) {\n const output = _extends({}, props);\n Object.keys(defaultProps).forEach(propName => {\n if (propName.toString().match(/^(components|slots)$/)) {\n output[propName] = _extends({}, defaultProps[propName], output[propName]);\n } else if (propName.toString().match(/^(componentsProps|slotProps)$/)) {\n const defaultSlotProps = defaultProps[propName] || {};\n const slotProps = props[propName];\n output[propName] = {};\n if (!slotProps || !Object.keys(slotProps)) {\n // Reduce the iteration if the slot props is empty\n output[propName] = defaultSlotProps;\n } else if (!defaultSlotProps || !Object.keys(defaultSlotProps)) {\n // Reduce the iteration if the default slot props is empty\n output[propName] = slotProps;\n } else {\n output[propName] = _extends({}, slotProps);\n Object.keys(defaultSlotProps).forEach(slotPropName => {\n output[propName][slotPropName] = resolveProps(defaultSlotProps[slotPropName], slotProps[slotPropName]);\n });\n }\n } else if (output[propName] === undefined) {\n output[propName] = defaultProps[propName];\n }\n });\n return output;\n}","export default function composeClasses(slots, getUtilityClass, classes = undefined) {\n const output = {};\n Object.keys(slots).forEach(\n // `Object.keys(slots)` can't be wider than `T` because we infer `T` from `slots`.\n // @ts-expect-error https://github.com/microsoft/TypeScript/pull/12253#issuecomment-263132208\n slot => {\n output[slot] = slots[slot].reduce((acc, key) => {\n if (key) {\n const utilityClass = getUtilityClass(key);\n if (utilityClass !== '') {\n acc.push(utilityClass);\n }\n if (classes && classes[key]) {\n acc.push(classes[key]);\n }\n }\n return acc;\n }, []).join(' ');\n });\n return output;\n}","const defaultGenerator = componentName => componentName;\nconst createClassNameGenerator = () => {\n let generate = defaultGenerator;\n return {\n configure(generator) {\n generate = generator;\n },\n generate(componentName) {\n return generate(componentName);\n },\n reset() {\n generate = defaultGenerator;\n }\n };\n};\nconst ClassNameGenerator = createClassNameGenerator();\nexport default ClassNameGenerator;","import ClassNameGenerator from '../ClassNameGenerator';\nexport const globalStateClasses = {\n active: 'active',\n checked: 'checked',\n completed: 'completed',\n disabled: 'disabled',\n error: 'error',\n expanded: 'expanded',\n focused: 'focused',\n focusVisible: 'focusVisible',\n open: 'open',\n readOnly: 'readOnly',\n required: 'required',\n selected: 'selected'\n};\nexport default function generateUtilityClass(componentName, slot, globalStatePrefix = 'Mui') {\n const globalStateClass = globalStateClasses[slot];\n return globalStateClass ? `${globalStatePrefix}-${globalStateClass}` : `${ClassNameGenerator.generate(componentName)}-${slot}`;\n}\nexport function isGlobalState(slot) {\n return globalStateClasses[slot] !== undefined;\n}","import generateUtilityClass from '../generateUtilityClass';\nexport default function generateUtilityClasses(componentName, slots, globalStatePrefix = 'Mui') {\n const result = {};\n slots.forEach(slot => {\n result[slot] = generateUtilityClass(componentName, slot, globalStatePrefix);\n });\n return result;\n}","function clamp(val, min = Number.MIN_SAFE_INTEGER, max = Number.MAX_SAFE_INTEGER) {\n return Math.max(min, Math.min(val, max));\n}\nexport default clamp;","export default function _objectWithoutPropertiesLoose(source, excluded) {\n if (source == null) return {};\n var target = {};\n var sourceKeys = Object.keys(source);\n var key, i;\n for (i = 0; i < sourceKeys.length; i++) {\n key = sourceKeys[i];\n if (excluded.indexOf(key) >= 0) continue;\n target[key] = source[key];\n }\n return target;\n}","import _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nconst _excluded = [\"values\", \"unit\", \"step\"];\n// Sorted ASC by size. That's important.\n// It can't be configured as it's used statically for propTypes.\nexport const breakpointKeys = ['xs', 'sm', 'md', 'lg', 'xl'];\nconst sortBreakpointsValues = values => {\n const breakpointsAsArray = Object.keys(values).map(key => ({\n key,\n val: values[key]\n })) || [];\n // Sort in ascending order\n breakpointsAsArray.sort((breakpoint1, breakpoint2) => breakpoint1.val - breakpoint2.val);\n return breakpointsAsArray.reduce((acc, obj) => {\n return _extends({}, acc, {\n [obj.key]: obj.val\n });\n }, {});\n};\n\n// Keep in mind that @media is inclusive by the CSS specification.\nexport default function createBreakpoints(breakpoints) {\n const {\n // The breakpoint **start** at this value.\n // For instance with the first breakpoint xs: [xs, sm).\n values = {\n xs: 0,\n // phone\n sm: 600,\n // tablet\n md: 900,\n // small laptop\n lg: 1200,\n // desktop\n xl: 1536 // large screen\n },\n unit = 'px',\n step = 5\n } = breakpoints,\n other = _objectWithoutPropertiesLoose(breakpoints, _excluded);\n const sortedValues = sortBreakpointsValues(values);\n const keys = Object.keys(sortedValues);\n function up(key) {\n const value = typeof values[key] === 'number' ? values[key] : key;\n return `@media (min-width:${value}${unit})`;\n }\n function down(key) {\n const value = typeof values[key] === 'number' ? values[key] : key;\n return `@media (max-width:${value - step / 100}${unit})`;\n }\n function between(start, end) {\n const endIndex = keys.indexOf(end);\n return `@media (min-width:${typeof values[start] === 'number' ? values[start] : start}${unit}) and ` + `(max-width:${(endIndex !== -1 && typeof values[keys[endIndex]] === 'number' ? values[keys[endIndex]] : end) - step / 100}${unit})`;\n }\n function only(key) {\n if (keys.indexOf(key) + 1 < keys.length) {\n return between(key, keys[keys.indexOf(key) + 1]);\n }\n return up(key);\n }\n function not(key) {\n // handle first and last key separately, for better readability\n const keyIndex = keys.indexOf(key);\n if (keyIndex === 0) {\n return up(keys[1]);\n }\n if (keyIndex === keys.length - 1) {\n return down(keys[keyIndex]);\n }\n return between(key, keys[keys.indexOf(key) + 1]).replace('@media', '@media not all and');\n }\n return _extends({\n keys,\n values: sortedValues,\n up,\n down,\n between,\n only,\n not,\n unit\n }, other);\n}","const shape = {\n borderRadius: 4\n};\nexport default shape;","import PropTypes from 'prop-types';\nconst responsivePropType = process.env.NODE_ENV !== 'production' ? PropTypes.oneOfType([PropTypes.number, PropTypes.string, PropTypes.object, PropTypes.array]) : {};\nexport default responsivePropType;","import deepmerge from '@mui/utils/deepmerge';\nfunction merge(acc, item) {\n if (!item) {\n return acc;\n }\n return deepmerge(acc, item, {\n clone: false // No need to clone deep, it's way faster.\n });\n}\nexport default merge;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport PropTypes from 'prop-types';\nimport deepmerge from '@mui/utils/deepmerge';\nimport merge from './merge';\n\n// The breakpoint **start** at this value.\n// For instance with the first breakpoint xs: [xs, sm[.\nexport const values = {\n xs: 0,\n // phone\n sm: 600,\n // tablet\n md: 900,\n // small laptop\n lg: 1200,\n // desktop\n xl: 1536 // large screen\n};\nconst defaultBreakpoints = {\n // Sorted ASC by size. That's important.\n // It can't be configured as it's used statically for propTypes.\n keys: ['xs', 'sm', 'md', 'lg', 'xl'],\n up: key => `@media (min-width:${values[key]}px)`\n};\nexport function handleBreakpoints(props, propValue, styleFromPropValue) {\n const theme = props.theme || {};\n if (Array.isArray(propValue)) {\n const themeBreakpoints = theme.breakpoints || defaultBreakpoints;\n return propValue.reduce((acc, item, index) => {\n acc[themeBreakpoints.up(themeBreakpoints.keys[index])] = styleFromPropValue(propValue[index]);\n return acc;\n }, {});\n }\n if (typeof propValue === 'object') {\n const themeBreakpoints = theme.breakpoints || defaultBreakpoints;\n return Object.keys(propValue).reduce((acc, breakpoint) => {\n // key is breakpoint\n if (Object.keys(themeBreakpoints.values || values).indexOf(breakpoint) !== -1) {\n const mediaKey = themeBreakpoints.up(breakpoint);\n acc[mediaKey] = styleFromPropValue(propValue[breakpoint], breakpoint);\n } else {\n const cssKey = breakpoint;\n acc[cssKey] = propValue[cssKey];\n }\n return acc;\n }, {});\n }\n const output = styleFromPropValue(propValue);\n return output;\n}\nfunction breakpoints(styleFunction) {\n // false positive\n // eslint-disable-next-line react/function-component-definition\n const newStyleFunction = props => {\n const theme = props.theme || {};\n const base = styleFunction(props);\n const themeBreakpoints = theme.breakpoints || defaultBreakpoints;\n const extended = themeBreakpoints.keys.reduce((acc, key) => {\n if (props[key]) {\n acc = acc || {};\n acc[themeBreakpoints.up(key)] = styleFunction(_extends({\n theme\n }, props[key]));\n }\n return acc;\n }, null);\n return merge(base, extended);\n };\n newStyleFunction.propTypes = process.env.NODE_ENV !== 'production' ? _extends({}, styleFunction.propTypes, {\n xs: PropTypes.object,\n sm: PropTypes.object,\n md: PropTypes.object,\n lg: PropTypes.object,\n xl: PropTypes.object\n }) : {};\n newStyleFunction.filterProps = ['xs', 'sm', 'md', 'lg', 'xl', ...styleFunction.filterProps];\n return newStyleFunction;\n}\nexport function createEmptyBreakpointObject(breakpointsInput = {}) {\n var _breakpointsInput$key;\n const breakpointsInOrder = (_breakpointsInput$key = breakpointsInput.keys) == null ? void 0 : _breakpointsInput$key.reduce((acc, key) => {\n const breakpointStyleKey = breakpointsInput.up(key);\n acc[breakpointStyleKey] = {};\n return acc;\n }, {});\n return breakpointsInOrder || {};\n}\nexport function removeUnusedBreakpoints(breakpointKeys, style) {\n return breakpointKeys.reduce((acc, key) => {\n const breakpointOutput = acc[key];\n const isBreakpointUnused = !breakpointOutput || Object.keys(breakpointOutput).length === 0;\n if (isBreakpointUnused) {\n delete acc[key];\n }\n return acc;\n }, style);\n}\nexport function mergeBreakpointsInOrder(breakpointsInput, ...styles) {\n const emptyBreakpoints = createEmptyBreakpointObject(breakpointsInput);\n const mergedOutput = [emptyBreakpoints, ...styles].reduce((prev, next) => deepmerge(prev, next), {});\n return removeUnusedBreakpoints(Object.keys(emptyBreakpoints), mergedOutput);\n}\n\n// compute base for responsive values; e.g.,\n// [1,2,3] => {xs: true, sm: true, md: true}\n// {xs: 1, sm: 2, md: 3} => {xs: true, sm: true, md: true}\nexport function computeBreakpointsBase(breakpointValues, themeBreakpoints) {\n // fixed value\n if (typeof breakpointValues !== 'object') {\n return {};\n }\n const base = {};\n const breakpointsKeys = Object.keys(themeBreakpoints);\n if (Array.isArray(breakpointValues)) {\n breakpointsKeys.forEach((breakpoint, i) => {\n if (i < breakpointValues.length) {\n base[breakpoint] = true;\n }\n });\n } else {\n breakpointsKeys.forEach(breakpoint => {\n if (breakpointValues[breakpoint] != null) {\n base[breakpoint] = true;\n }\n });\n }\n return base;\n}\nexport function resolveBreakpointValues({\n values: breakpointValues,\n breakpoints: themeBreakpoints,\n base: customBase\n}) {\n const base = customBase || computeBreakpointsBase(breakpointValues, themeBreakpoints);\n const keys = Object.keys(base);\n if (keys.length === 0) {\n return breakpointValues;\n }\n let previous;\n return keys.reduce((acc, breakpoint, i) => {\n if (Array.isArray(breakpointValues)) {\n acc[breakpoint] = breakpointValues[i] != null ? breakpointValues[i] : breakpointValues[previous];\n previous = i;\n } else if (typeof breakpointValues === 'object') {\n acc[breakpoint] = breakpointValues[breakpoint] != null ? breakpointValues[breakpoint] : breakpointValues[previous];\n previous = breakpoint;\n } else {\n acc[breakpoint] = breakpointValues;\n }\n return acc;\n }, {});\n}\nexport default breakpoints;","import capitalize from '@mui/utils/capitalize';\nimport responsivePropType from './responsivePropType';\nimport { handleBreakpoints } from './breakpoints';\nexport function getPath(obj, path, checkVars = true) {\n if (!path || typeof path !== 'string') {\n return null;\n }\n\n // Check if CSS variables are used\n if (obj && obj.vars && checkVars) {\n const val = `vars.${path}`.split('.').reduce((acc, item) => acc && acc[item] ? acc[item] : null, obj);\n if (val != null) {\n return val;\n }\n }\n return path.split('.').reduce((acc, item) => {\n if (acc && acc[item] != null) {\n return acc[item];\n }\n return null;\n }, obj);\n}\nexport function getStyleValue(themeMapping, transform, propValueFinal, userValue = propValueFinal) {\n let value;\n if (typeof themeMapping === 'function') {\n value = themeMapping(propValueFinal);\n } else if (Array.isArray(themeMapping)) {\n value = themeMapping[propValueFinal] || userValue;\n } else {\n value = getPath(themeMapping, propValueFinal) || userValue;\n }\n if (transform) {\n value = transform(value, userValue, themeMapping);\n }\n return value;\n}\nfunction style(options) {\n const {\n prop,\n cssProperty = options.prop,\n themeKey,\n transform\n } = options;\n\n // false positive\n // eslint-disable-next-line react/function-component-definition\n const fn = props => {\n if (props[prop] == null) {\n return null;\n }\n const propValue = props[prop];\n const theme = props.theme;\n const themeMapping = getPath(theme, themeKey) || {};\n const styleFromPropValue = propValueFinal => {\n let value = getStyleValue(themeMapping, transform, propValueFinal);\n if (propValueFinal === value && typeof propValueFinal === 'string') {\n // Haven't found value\n value = getStyleValue(themeMapping, transform, `${prop}${propValueFinal === 'default' ? '' : capitalize(propValueFinal)}`, propValueFinal);\n }\n if (cssProperty === false) {\n return value;\n }\n return {\n [cssProperty]: value\n };\n };\n return handleBreakpoints(props, propValue, styleFromPropValue);\n };\n fn.propTypes = process.env.NODE_ENV !== 'production' ? {\n [prop]: responsivePropType\n } : {};\n fn.filterProps = [prop];\n return fn;\n}\nexport default style;","export default function memoize(fn) {\n const cache = {};\n return arg => {\n if (cache[arg] === undefined) {\n cache[arg] = fn(arg);\n }\n return cache[arg];\n };\n}","import responsivePropType from './responsivePropType';\nimport { handleBreakpoints } from './breakpoints';\nimport { getPath } from './style';\nimport merge from './merge';\nimport memoize from './memoize';\nconst properties = {\n m: 'margin',\n p: 'padding'\n};\nconst directions = {\n t: 'Top',\n r: 'Right',\n b: 'Bottom',\n l: 'Left',\n x: ['Left', 'Right'],\n y: ['Top', 'Bottom']\n};\nconst aliases = {\n marginX: 'mx',\n marginY: 'my',\n paddingX: 'px',\n paddingY: 'py'\n};\n\n// memoize() impact:\n// From 300,000 ops/sec\n// To 350,000 ops/sec\nconst getCssProperties = memoize(prop => {\n // It's not a shorthand notation.\n if (prop.length > 2) {\n if (aliases[prop]) {\n prop = aliases[prop];\n } else {\n return [prop];\n }\n }\n const [a, b] = prop.split('');\n const property = properties[a];\n const direction = directions[b] || '';\n return Array.isArray(direction) ? direction.map(dir => property + dir) : [property + direction];\n});\nexport const marginKeys = ['m', 'mt', 'mr', 'mb', 'ml', 'mx', 'my', 'margin', 'marginTop', 'marginRight', 'marginBottom', 'marginLeft', 'marginX', 'marginY', 'marginInline', 'marginInlineStart', 'marginInlineEnd', 'marginBlock', 'marginBlockStart', 'marginBlockEnd'];\nexport const paddingKeys = ['p', 'pt', 'pr', 'pb', 'pl', 'px', 'py', 'padding', 'paddingTop', 'paddingRight', 'paddingBottom', 'paddingLeft', 'paddingX', 'paddingY', 'paddingInline', 'paddingInlineStart', 'paddingInlineEnd', 'paddingBlock', 'paddingBlockStart', 'paddingBlockEnd'];\nconst spacingKeys = [...marginKeys, ...paddingKeys];\nexport function createUnaryUnit(theme, themeKey, defaultValue, propName) {\n var _getPath;\n const themeSpacing = (_getPath = getPath(theme, themeKey, false)) != null ? _getPath : defaultValue;\n if (typeof themeSpacing === 'number') {\n return abs => {\n if (typeof abs === 'string') {\n return abs;\n }\n if (process.env.NODE_ENV !== 'production') {\n if (typeof abs !== 'number') {\n console.error(`MUI: Expected ${propName} argument to be a number or a string, got ${abs}.`);\n }\n }\n return themeSpacing * abs;\n };\n }\n if (Array.isArray(themeSpacing)) {\n return abs => {\n if (typeof abs === 'string') {\n return abs;\n }\n if (process.env.NODE_ENV !== 'production') {\n if (!Number.isInteger(abs)) {\n console.error([`MUI: The \\`theme.${themeKey}\\` array type cannot be combined with non integer values.` + `You should either use an integer value that can be used as index, or define the \\`theme.${themeKey}\\` as a number.`].join('\\n'));\n } else if (abs > themeSpacing.length - 1) {\n console.error([`MUI: The value provided (${abs}) overflows.`, `The supported values are: ${JSON.stringify(themeSpacing)}.`, `${abs} > ${themeSpacing.length - 1}, you need to add the missing values.`].join('\\n'));\n }\n }\n return themeSpacing[abs];\n };\n }\n if (typeof themeSpacing === 'function') {\n return themeSpacing;\n }\n if (process.env.NODE_ENV !== 'production') {\n console.error([`MUI: The \\`theme.${themeKey}\\` value (${themeSpacing}) is invalid.`, 'It should be a number, an array or a function.'].join('\\n'));\n }\n return () => undefined;\n}\nexport function createUnarySpacing(theme) {\n return createUnaryUnit(theme, 'spacing', 8, 'spacing');\n}\nexport function getValue(transformer, propValue) {\n if (typeof propValue === 'string' || propValue == null) {\n return propValue;\n }\n const abs = Math.abs(propValue);\n const transformed = transformer(abs);\n if (propValue >= 0) {\n return transformed;\n }\n if (typeof transformed === 'number') {\n return -transformed;\n }\n return `-${transformed}`;\n}\nexport function getStyleFromPropValue(cssProperties, transformer) {\n return propValue => cssProperties.reduce((acc, cssProperty) => {\n acc[cssProperty] = getValue(transformer, propValue);\n return acc;\n }, {});\n}\nfunction resolveCssProperty(props, keys, prop, transformer) {\n // Using a hash computation over an array iteration could be faster, but with only 28 items,\n // it's doesn't worth the bundle size.\n if (keys.indexOf(prop) === -1) {\n return null;\n }\n const cssProperties = getCssProperties(prop);\n const styleFromPropValue = getStyleFromPropValue(cssProperties, transformer);\n const propValue = props[prop];\n return handleBreakpoints(props, propValue, styleFromPropValue);\n}\nfunction style(props, keys) {\n const transformer = createUnarySpacing(props.theme);\n return Object.keys(props).map(prop => resolveCssProperty(props, keys, prop, transformer)).reduce(merge, {});\n}\nexport function margin(props) {\n return style(props, marginKeys);\n}\nmargin.propTypes = process.env.NODE_ENV !== 'production' ? marginKeys.reduce((obj, key) => {\n obj[key] = responsivePropType;\n return obj;\n}, {}) : {};\nmargin.filterProps = marginKeys;\nexport function padding(props) {\n return style(props, paddingKeys);\n}\npadding.propTypes = process.env.NODE_ENV !== 'production' ? paddingKeys.reduce((obj, key) => {\n obj[key] = responsivePropType;\n return obj;\n}, {}) : {};\npadding.filterProps = paddingKeys;\nfunction spacing(props) {\n return style(props, spacingKeys);\n}\nspacing.propTypes = process.env.NODE_ENV !== 'production' ? spacingKeys.reduce((obj, key) => {\n obj[key] = responsivePropType;\n return obj;\n}, {}) : {};\nspacing.filterProps = spacingKeys;\nexport default spacing;","import { createUnarySpacing } from '../spacing';\n\n// The different signatures imply different meaning for their arguments that can't be expressed structurally.\n// We express the difference with variable names.\n\nexport default function createSpacing(spacingInput = 8) {\n // Already transformed.\n if (spacingInput.mui) {\n return spacingInput;\n }\n\n // Material Design layouts are visually balanced. Most measurements align to an 8dp grid, which aligns both spacing and the overall layout.\n // Smaller components, such as icons, can align to a 4dp grid.\n // https://m2.material.io/design/layout/understanding-layout.html\n const transform = createUnarySpacing({\n spacing: spacingInput\n });\n const spacing = (...argsInput) => {\n if (process.env.NODE_ENV !== 'production') {\n if (!(argsInput.length <= 4)) {\n console.error(`MUI: Too many arguments provided, expected between 0 and 4, got ${argsInput.length}`);\n }\n }\n const args = argsInput.length === 0 ? [1] : argsInput;\n return args.map(argument => {\n const output = transform(argument);\n return typeof output === 'number' ? `${output}px` : output;\n }).join(' ');\n };\n spacing.mui = true;\n return spacing;\n}","import merge from './merge';\nfunction compose(...styles) {\n const handlers = styles.reduce((acc, style) => {\n style.filterProps.forEach(prop => {\n acc[prop] = style;\n });\n return acc;\n }, {});\n\n // false positive\n // eslint-disable-next-line react/function-component-definition\n const fn = props => {\n return Object.keys(props).reduce((acc, prop) => {\n if (handlers[prop]) {\n return merge(acc, handlers[prop](props));\n }\n return acc;\n }, {});\n };\n fn.propTypes = process.env.NODE_ENV !== 'production' ? styles.reduce((acc, style) => Object.assign(acc, style.propTypes), {}) : {};\n fn.filterProps = styles.reduce((acc, style) => acc.concat(style.filterProps), []);\n return fn;\n}\nexport default compose;","import responsivePropType from './responsivePropType';\nimport style from './style';\nimport compose from './compose';\nimport { createUnaryUnit, getValue } from './spacing';\nimport { handleBreakpoints } from './breakpoints';\nexport function borderTransform(value) {\n if (typeof value !== 'number') {\n return value;\n }\n return `${value}px solid`;\n}\nfunction createBorderStyle(prop, transform) {\n return style({\n prop,\n themeKey: 'borders',\n transform\n });\n}\nexport const border = createBorderStyle('border', borderTransform);\nexport const borderTop = createBorderStyle('borderTop', borderTransform);\nexport const borderRight = createBorderStyle('borderRight', borderTransform);\nexport const borderBottom = createBorderStyle('borderBottom', borderTransform);\nexport const borderLeft = createBorderStyle('borderLeft', borderTransform);\nexport const borderColor = createBorderStyle('borderColor');\nexport const borderTopColor = createBorderStyle('borderTopColor');\nexport const borderRightColor = createBorderStyle('borderRightColor');\nexport const borderBottomColor = createBorderStyle('borderBottomColor');\nexport const borderLeftColor = createBorderStyle('borderLeftColor');\nexport const outline = createBorderStyle('outline', borderTransform);\nexport const outlineColor = createBorderStyle('outlineColor');\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const borderRadius = props => {\n if (props.borderRadius !== undefined && props.borderRadius !== null) {\n const transformer = createUnaryUnit(props.theme, 'shape.borderRadius', 4, 'borderRadius');\n const styleFromPropValue = propValue => ({\n borderRadius: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.borderRadius, styleFromPropValue);\n }\n return null;\n};\nborderRadius.propTypes = process.env.NODE_ENV !== 'production' ? {\n borderRadius: responsivePropType\n} : {};\nborderRadius.filterProps = ['borderRadius'];\nconst borders = compose(border, borderTop, borderRight, borderBottom, borderLeft, borderColor, borderTopColor, borderRightColor, borderBottomColor, borderLeftColor, borderRadius, outline, outlineColor);\nexport default borders;","import style from './style';\nimport compose from './compose';\nimport { createUnaryUnit, getValue } from './spacing';\nimport { handleBreakpoints } from './breakpoints';\nimport responsivePropType from './responsivePropType';\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const gap = props => {\n if (props.gap !== undefined && props.gap !== null) {\n const transformer = createUnaryUnit(props.theme, 'spacing', 8, 'gap');\n const styleFromPropValue = propValue => ({\n gap: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.gap, styleFromPropValue);\n }\n return null;\n};\ngap.propTypes = process.env.NODE_ENV !== 'production' ? {\n gap: responsivePropType\n} : {};\ngap.filterProps = ['gap'];\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const columnGap = props => {\n if (props.columnGap !== undefined && props.columnGap !== null) {\n const transformer = createUnaryUnit(props.theme, 'spacing', 8, 'columnGap');\n const styleFromPropValue = propValue => ({\n columnGap: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.columnGap, styleFromPropValue);\n }\n return null;\n};\ncolumnGap.propTypes = process.env.NODE_ENV !== 'production' ? {\n columnGap: responsivePropType\n} : {};\ncolumnGap.filterProps = ['columnGap'];\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const rowGap = props => {\n if (props.rowGap !== undefined && props.rowGap !== null) {\n const transformer = createUnaryUnit(props.theme, 'spacing', 8, 'rowGap');\n const styleFromPropValue = propValue => ({\n rowGap: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.rowGap, styleFromPropValue);\n }\n return null;\n};\nrowGap.propTypes = process.env.NODE_ENV !== 'production' ? {\n rowGap: responsivePropType\n} : {};\nrowGap.filterProps = ['rowGap'];\nexport const gridColumn = style({\n prop: 'gridColumn'\n});\nexport const gridRow = style({\n prop: 'gridRow'\n});\nexport const gridAutoFlow = style({\n prop: 'gridAutoFlow'\n});\nexport const gridAutoColumns = style({\n prop: 'gridAutoColumns'\n});\nexport const gridAutoRows = style({\n prop: 'gridAutoRows'\n});\nexport const gridTemplateColumns = style({\n prop: 'gridTemplateColumns'\n});\nexport const gridTemplateRows = style({\n prop: 'gridTemplateRows'\n});\nexport const gridTemplateAreas = style({\n prop: 'gridTemplateAreas'\n});\nexport const gridArea = style({\n prop: 'gridArea'\n});\nconst grid = compose(gap, columnGap, rowGap, gridColumn, gridRow, gridAutoFlow, gridAutoColumns, gridAutoRows, gridTemplateColumns, gridTemplateRows, gridTemplateAreas, gridArea);\nexport default grid;","import style from './style';\nimport compose from './compose';\nexport function paletteTransform(value, userValue) {\n if (userValue === 'grey') {\n return userValue;\n }\n return value;\n}\nexport const color = style({\n prop: 'color',\n themeKey: 'palette',\n transform: paletteTransform\n});\nexport const bgcolor = style({\n prop: 'bgcolor',\n cssProperty: 'backgroundColor',\n themeKey: 'palette',\n transform: paletteTransform\n});\nexport const backgroundColor = style({\n prop: 'backgroundColor',\n themeKey: 'palette',\n transform: paletteTransform\n});\nconst palette = compose(color, bgcolor, backgroundColor);\nexport default palette;","import style from './style';\nimport compose from './compose';\nimport { handleBreakpoints, values as breakpointsValues } from './breakpoints';\nexport function sizingTransform(value) {\n return value <= 1 && value !== 0 ? `${value * 100}%` : value;\n}\nexport const width = style({\n prop: 'width',\n transform: sizingTransform\n});\nexport const maxWidth = props => {\n if (props.maxWidth !== undefined && props.maxWidth !== null) {\n const styleFromPropValue = propValue => {\n var _props$theme, _props$theme2;\n const breakpoint = ((_props$theme = props.theme) == null || (_props$theme = _props$theme.breakpoints) == null || (_props$theme = _props$theme.values) == null ? void 0 : _props$theme[propValue]) || breakpointsValues[propValue];\n if (!breakpoint) {\n return {\n maxWidth: sizingTransform(propValue)\n };\n }\n if (((_props$theme2 = props.theme) == null || (_props$theme2 = _props$theme2.breakpoints) == null ? void 0 : _props$theme2.unit) !== 'px') {\n return {\n maxWidth: `${breakpoint}${props.theme.breakpoints.unit}`\n };\n }\n return {\n maxWidth: breakpoint\n };\n };\n return handleBreakpoints(props, props.maxWidth, styleFromPropValue);\n }\n return null;\n};\nmaxWidth.filterProps = ['maxWidth'];\nexport const minWidth = style({\n prop: 'minWidth',\n transform: sizingTransform\n});\nexport const height = style({\n prop: 'height',\n transform: sizingTransform\n});\nexport const maxHeight = style({\n prop: 'maxHeight',\n transform: sizingTransform\n});\nexport const minHeight = style({\n prop: 'minHeight',\n transform: sizingTransform\n});\nexport const sizeWidth = style({\n prop: 'size',\n cssProperty: 'width',\n transform: sizingTransform\n});\nexport const sizeHeight = style({\n prop: 'size',\n cssProperty: 'height',\n transform: sizingTransform\n});\nexport const boxSizing = style({\n prop: 'boxSizing'\n});\nconst sizing = compose(width, maxWidth, minWidth, height, maxHeight, minHeight, boxSizing);\nexport default sizing;","import { padding, margin } from '../spacing';\nimport { borderRadius, borderTransform } from '../borders';\nimport { gap, rowGap, columnGap } from '../cssGrid';\nimport { paletteTransform } from '../palette';\nimport { maxWidth, sizingTransform } from '../sizing';\nconst defaultSxConfig = {\n // borders\n border: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderTop: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderRight: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderBottom: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderLeft: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderColor: {\n themeKey: 'palette'\n },\n borderTopColor: {\n themeKey: 'palette'\n },\n borderRightColor: {\n themeKey: 'palette'\n },\n borderBottomColor: {\n themeKey: 'palette'\n },\n borderLeftColor: {\n themeKey: 'palette'\n },\n outline: {\n themeKey: 'borders',\n transform: borderTransform\n },\n outlineColor: {\n themeKey: 'palette'\n },\n borderRadius: {\n themeKey: 'shape.borderRadius',\n style: borderRadius\n },\n // palette\n color: {\n themeKey: 'palette',\n transform: paletteTransform\n },\n bgcolor: {\n themeKey: 'palette',\n cssProperty: 'backgroundColor',\n transform: paletteTransform\n },\n backgroundColor: {\n themeKey: 'palette',\n transform: paletteTransform\n },\n // spacing\n p: {\n style: padding\n },\n pt: {\n style: padding\n },\n pr: {\n style: padding\n },\n pb: {\n style: padding\n },\n pl: {\n style: padding\n },\n px: {\n style: padding\n },\n py: {\n style: padding\n },\n padding: {\n style: padding\n },\n paddingTop: {\n style: padding\n },\n paddingRight: {\n style: padding\n },\n paddingBottom: {\n style: padding\n },\n paddingLeft: {\n style: padding\n },\n paddingX: {\n style: padding\n },\n paddingY: {\n style: padding\n },\n paddingInline: {\n style: padding\n },\n paddingInlineStart: {\n style: padding\n },\n paddingInlineEnd: {\n style: padding\n },\n paddingBlock: {\n style: padding\n },\n paddingBlockStart: {\n style: padding\n },\n paddingBlockEnd: {\n style: padding\n },\n m: {\n style: margin\n },\n mt: {\n style: margin\n },\n mr: {\n style: margin\n },\n mb: {\n style: margin\n },\n ml: {\n style: margin\n },\n mx: {\n style: margin\n },\n my: {\n style: margin\n },\n margin: {\n style: margin\n },\n marginTop: {\n style: margin\n },\n marginRight: {\n style: margin\n },\n marginBottom: {\n style: margin\n },\n marginLeft: {\n style: margin\n },\n marginX: {\n style: margin\n },\n marginY: {\n style: margin\n },\n marginInline: {\n style: margin\n },\n marginInlineStart: {\n style: margin\n },\n marginInlineEnd: {\n style: margin\n },\n marginBlock: {\n style: margin\n },\n marginBlockStart: {\n style: margin\n },\n marginBlockEnd: {\n style: margin\n },\n // display\n displayPrint: {\n cssProperty: false,\n transform: value => ({\n '@media print': {\n display: value\n }\n })\n },\n display: {},\n overflow: {},\n textOverflow: {},\n visibility: {},\n whiteSpace: {},\n // flexbox\n flexBasis: {},\n flexDirection: {},\n flexWrap: {},\n justifyContent: {},\n alignItems: {},\n alignContent: {},\n order: {},\n flex: {},\n flexGrow: {},\n flexShrink: {},\n alignSelf: {},\n justifyItems: {},\n justifySelf: {},\n // grid\n gap: {\n style: gap\n },\n rowGap: {\n style: rowGap\n },\n columnGap: {\n style: columnGap\n },\n gridColumn: {},\n gridRow: {},\n gridAutoFlow: {},\n gridAutoColumns: {},\n gridAutoRows: {},\n gridTemplateColumns: {},\n gridTemplateRows: {},\n gridTemplateAreas: {},\n gridArea: {},\n // positions\n position: {},\n zIndex: {\n themeKey: 'zIndex'\n },\n top: {},\n right: {},\n bottom: {},\n left: {},\n // shadows\n boxShadow: {\n themeKey: 'shadows'\n },\n // sizing\n width: {\n transform: sizingTransform\n },\n maxWidth: {\n style: maxWidth\n },\n minWidth: {\n transform: sizingTransform\n },\n height: {\n transform: sizingTransform\n },\n maxHeight: {\n transform: sizingTransform\n },\n minHeight: {\n transform: sizingTransform\n },\n boxSizing: {},\n // typography\n fontFamily: {\n themeKey: 'typography'\n },\n fontSize: {\n themeKey: 'typography'\n },\n fontStyle: {\n themeKey: 'typography'\n },\n fontWeight: {\n themeKey: 'typography'\n },\n letterSpacing: {},\n textTransform: {},\n lineHeight: {},\n textAlign: {},\n typography: {\n cssProperty: false,\n themeKey: 'typography'\n }\n};\nexport default defaultSxConfig;","import capitalize from '@mui/utils/capitalize';\nimport merge from '../merge';\nimport { getPath, getStyleValue as getValue } from '../style';\nimport { handleBreakpoints, createEmptyBreakpointObject, removeUnusedBreakpoints } from '../breakpoints';\nimport defaultSxConfig from './defaultSxConfig';\nfunction objectsHaveSameKeys(...objects) {\n const allKeys = objects.reduce((keys, object) => keys.concat(Object.keys(object)), []);\n const union = new Set(allKeys);\n return objects.every(object => union.size === Object.keys(object).length);\n}\nfunction callIfFn(maybeFn, arg) {\n return typeof maybeFn === 'function' ? maybeFn(arg) : maybeFn;\n}\n\n// eslint-disable-next-line @typescript-eslint/naming-convention\nexport function unstable_createStyleFunctionSx() {\n function getThemeValue(prop, val, theme, config) {\n const props = {\n [prop]: val,\n theme\n };\n const options = config[prop];\n if (!options) {\n return {\n [prop]: val\n };\n }\n const {\n cssProperty = prop,\n themeKey,\n transform,\n style\n } = options;\n if (val == null) {\n return null;\n }\n\n // TODO v6: remove, see https://github.com/mui/material-ui/pull/38123\n if (themeKey === 'typography' && val === 'inherit') {\n return {\n [prop]: val\n };\n }\n const themeMapping = getPath(theme, themeKey) || {};\n if (style) {\n return style(props);\n }\n const styleFromPropValue = propValueFinal => {\n let value = getValue(themeMapping, transform, propValueFinal);\n if (propValueFinal === value && typeof propValueFinal === 'string') {\n // Haven't found value\n value = getValue(themeMapping, transform, `${prop}${propValueFinal === 'default' ? '' : capitalize(propValueFinal)}`, propValueFinal);\n }\n if (cssProperty === false) {\n return value;\n }\n return {\n [cssProperty]: value\n };\n };\n return handleBreakpoints(props, val, styleFromPropValue);\n }\n function styleFunctionSx(props) {\n var _theme$unstable_sxCon;\n const {\n sx,\n theme = {}\n } = props || {};\n if (!sx) {\n return null; // Emotion & styled-components will neglect null\n }\n const config = (_theme$unstable_sxCon = theme.unstable_sxConfig) != null ? _theme$unstable_sxCon : defaultSxConfig;\n\n /*\n * Receive `sxInput` as object or callback\n * and then recursively check keys & values to create media query object styles.\n * (the result will be used in `styled`)\n */\n function traverse(sxInput) {\n let sxObject = sxInput;\n if (typeof sxInput === 'function') {\n sxObject = sxInput(theme);\n } else if (typeof sxInput !== 'object') {\n // value\n return sxInput;\n }\n if (!sxObject) {\n return null;\n }\n const emptyBreakpoints = createEmptyBreakpointObject(theme.breakpoints);\n const breakpointsKeys = Object.keys(emptyBreakpoints);\n let css = emptyBreakpoints;\n Object.keys(sxObject).forEach(styleKey => {\n const value = callIfFn(sxObject[styleKey], theme);\n if (value !== null && value !== undefined) {\n if (typeof value === 'object') {\n if (config[styleKey]) {\n css = merge(css, getThemeValue(styleKey, value, theme, config));\n } else {\n const breakpointsValues = handleBreakpoints({\n theme\n }, value, x => ({\n [styleKey]: x\n }));\n if (objectsHaveSameKeys(breakpointsValues, value)) {\n css[styleKey] = styleFunctionSx({\n sx: value,\n theme\n });\n } else {\n css = merge(css, breakpointsValues);\n }\n }\n } else {\n css = merge(css, getThemeValue(styleKey, value, theme, config));\n }\n }\n });\n return removeUnusedBreakpoints(breakpointsKeys, css);\n }\n return Array.isArray(sx) ? sx.map(traverse) : traverse(sx);\n }\n return styleFunctionSx;\n}\nconst styleFunctionSx = unstable_createStyleFunctionSx();\nstyleFunctionSx.filterProps = ['sx'];\nexport default styleFunctionSx;","/**\n * A universal utility to style components with multiple color modes. Always use it from the theme object.\n * It works with:\n * - [Basic theme](https://mui.com/material-ui/customization/dark-mode/)\n * - [CSS theme variables](https://mui.com/material-ui/experimental-api/css-theme-variables/overview/)\n * - Zero-runtime engine\n *\n * Tips: Use an array over object spread and place `theme.applyStyles()` last.\n *\n * ✅ [{ background: '#e5e5e5' }, theme.applyStyles('dark', { background: '#1c1c1c' })]\n *\n * 🚫 { background: '#e5e5e5', ...theme.applyStyles('dark', { background: '#1c1c1c' })}\n *\n * @example\n * 1. using with `styled`:\n * ```jsx\n * const Component = styled('div')(({ theme }) => [\n * { background: '#e5e5e5' },\n * theme.applyStyles('dark', {\n * background: '#1c1c1c',\n * color: '#fff',\n * }),\n * ]);\n * ```\n *\n * @example\n * 2. using with `sx` prop:\n * ```jsx\n * [\n * { background: '#e5e5e5' },\n * theme.applyStyles('dark', {\n * background: '#1c1c1c',\n * color: '#fff',\n * }),\n * ]}\n * />\n * ```\n *\n * @example\n * 3. theming a component:\n * ```jsx\n * extendTheme({\n * components: {\n * MuiButton: {\n * styleOverrides: {\n * root: ({ theme }) => [\n * { background: '#e5e5e5' },\n * theme.applyStyles('dark', {\n * background: '#1c1c1c',\n * color: '#fff',\n * }),\n * ],\n * },\n * }\n * }\n * })\n *```\n */\nexport default function applyStyles(key, styles) {\n // @ts-expect-error this is 'any' type\n const theme = this;\n if (theme.vars && typeof theme.getColorSchemeSelector === 'function') {\n // If CssVarsProvider is used as a provider,\n // returns '* :where([data-mui-color-scheme=\"light|dark\"]) &'\n const selector = theme.getColorSchemeSelector(key).replace(/(\\[[^\\]]+\\])/, '*:where($1)');\n return {\n [selector]: styles\n };\n }\n if (theme.palette.mode === key) {\n return styles;\n }\n return {};\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"breakpoints\", \"palette\", \"spacing\", \"shape\"];\nimport deepmerge from '@mui/utils/deepmerge';\nimport createBreakpoints from './createBreakpoints';\nimport shape from './shape';\nimport createSpacing from './createSpacing';\nimport styleFunctionSx from '../styleFunctionSx/styleFunctionSx';\nimport defaultSxConfig from '../styleFunctionSx/defaultSxConfig';\nimport applyStyles from './applyStyles';\nfunction createTheme(options = {}, ...args) {\n const {\n breakpoints: breakpointsInput = {},\n palette: paletteInput = {},\n spacing: spacingInput,\n shape: shapeInput = {}\n } = options,\n other = _objectWithoutPropertiesLoose(options, _excluded);\n const breakpoints = createBreakpoints(breakpointsInput);\n const spacing = createSpacing(spacingInput);\n let muiTheme = deepmerge({\n breakpoints,\n direction: 'ltr',\n components: {},\n // Inject component definitions.\n palette: _extends({\n mode: 'light'\n }, paletteInput),\n spacing,\n shape: _extends({}, shape, shapeInput)\n }, other);\n muiTheme.applyStyles = applyStyles;\n muiTheme = args.reduce((acc, argument) => deepmerge(acc, argument), muiTheme);\n muiTheme.unstable_sxConfig = _extends({}, defaultSxConfig, other == null ? void 0 : other.unstable_sxConfig);\n muiTheme.unstable_sx = function sx(props) {\n return styleFunctionSx({\n sx: props,\n theme: this\n });\n };\n return muiTheme;\n}\nexport default createTheme;","'use client';\n\nimport * as React from 'react';\nimport { ThemeContext } from '@mui/styled-engine';\nfunction isObjectEmpty(obj) {\n return Object.keys(obj).length === 0;\n}\nfunction useTheme(defaultTheme = null) {\n const contextTheme = React.useContext(ThemeContext);\n return !contextTheme || isObjectEmpty(contextTheme) ? defaultTheme : contextTheme;\n}\nexport default useTheme;","'use client';\n\nimport createTheme from './createTheme';\nimport useThemeWithoutDefault from './useThemeWithoutDefault';\nexport const systemDefaultTheme = createTheme();\nfunction useTheme(defaultTheme = systemDefaultTheme) {\n return useThemeWithoutDefault(defaultTheme);\n}\nexport default useTheme;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"ownerState\"],\n _excluded2 = [\"variants\"],\n _excluded3 = [\"name\", \"slot\", \"skipVariantsResolver\", \"skipSx\", \"overridesResolver\"];\n/* eslint-disable no-underscore-dangle */\nimport styledEngineStyled, { internal_processStyles as processStyles } from '@mui/styled-engine';\nimport { isPlainObject } from '@mui/utils/deepmerge';\nimport capitalize from '@mui/utils/capitalize';\nimport getDisplayName from '@mui/utils/getDisplayName';\nimport createTheme from './createTheme';\nimport styleFunctionSx from './styleFunctionSx';\nfunction isEmpty(obj) {\n return Object.keys(obj).length === 0;\n}\n\n// https://github.com/emotion-js/emotion/blob/26ded6109fcd8ca9875cc2ce4564fee678a3f3c5/packages/styled/src/utils.js#L40\nfunction isStringTag(tag) {\n return typeof tag === 'string' &&\n // 96 is one less than the char code\n // for \"a\" so this is checking that\n // it's a lowercase character\n tag.charCodeAt(0) > 96;\n}\n\n// Update /system/styled/#api in case if this changes\nexport function shouldForwardProp(prop) {\n return prop !== 'ownerState' && prop !== 'theme' && prop !== 'sx' && prop !== 'as';\n}\nexport const systemDefaultTheme = createTheme();\nconst lowercaseFirstLetter = string => {\n if (!string) {\n return string;\n }\n return string.charAt(0).toLowerCase() + string.slice(1);\n};\nfunction resolveTheme({\n defaultTheme,\n theme,\n themeId\n}) {\n return isEmpty(theme) ? defaultTheme : theme[themeId] || theme;\n}\nfunction defaultOverridesResolver(slot) {\n if (!slot) {\n return null;\n }\n return (props, styles) => styles[slot];\n}\nfunction processStyleArg(callableStyle, _ref) {\n let {\n ownerState\n } = _ref,\n props = _objectWithoutPropertiesLoose(_ref, _excluded);\n const resolvedStylesArg = typeof callableStyle === 'function' ? callableStyle(_extends({\n ownerState\n }, props)) : callableStyle;\n if (Array.isArray(resolvedStylesArg)) {\n return resolvedStylesArg.flatMap(resolvedStyle => processStyleArg(resolvedStyle, _extends({\n ownerState\n }, props)));\n }\n if (!!resolvedStylesArg && typeof resolvedStylesArg === 'object' && Array.isArray(resolvedStylesArg.variants)) {\n const {\n variants = []\n } = resolvedStylesArg,\n otherStyles = _objectWithoutPropertiesLoose(resolvedStylesArg, _excluded2);\n let result = otherStyles;\n variants.forEach(variant => {\n let isMatch = true;\n if (typeof variant.props === 'function') {\n isMatch = variant.props(_extends({\n ownerState\n }, props, ownerState));\n } else {\n Object.keys(variant.props).forEach(key => {\n if ((ownerState == null ? void 0 : ownerState[key]) !== variant.props[key] && props[key] !== variant.props[key]) {\n isMatch = false;\n }\n });\n }\n if (isMatch) {\n if (!Array.isArray(result)) {\n result = [result];\n }\n result.push(typeof variant.style === 'function' ? variant.style(_extends({\n ownerState\n }, props, ownerState)) : variant.style);\n }\n });\n return result;\n }\n return resolvedStylesArg;\n}\nexport default function createStyled(input = {}) {\n const {\n themeId,\n defaultTheme = systemDefaultTheme,\n rootShouldForwardProp = shouldForwardProp,\n slotShouldForwardProp = shouldForwardProp\n } = input;\n const systemSx = props => {\n return styleFunctionSx(_extends({}, props, {\n theme: resolveTheme(_extends({}, props, {\n defaultTheme,\n themeId\n }))\n }));\n };\n systemSx.__mui_systemSx = true;\n return (tag, inputOptions = {}) => {\n // Filter out the `sx` style function from the previous styled component to prevent unnecessary styles generated by the composite components.\n processStyles(tag, styles => styles.filter(style => !(style != null && style.__mui_systemSx)));\n const {\n name: componentName,\n slot: componentSlot,\n skipVariantsResolver: inputSkipVariantsResolver,\n skipSx: inputSkipSx,\n // TODO v6: remove `lowercaseFirstLetter()` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n overridesResolver = defaultOverridesResolver(lowercaseFirstLetter(componentSlot))\n } = inputOptions,\n options = _objectWithoutPropertiesLoose(inputOptions, _excluded3);\n\n // if skipVariantsResolver option is defined, take the value, otherwise, true for root and false for other slots.\n const skipVariantsResolver = inputSkipVariantsResolver !== undefined ? inputSkipVariantsResolver :\n // TODO v6: remove `Root` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n componentSlot && componentSlot !== 'Root' && componentSlot !== 'root' || false;\n const skipSx = inputSkipSx || false;\n let label;\n if (process.env.NODE_ENV !== 'production') {\n if (componentName) {\n // TODO v6: remove `lowercaseFirstLetter()` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n label = `${componentName}-${lowercaseFirstLetter(componentSlot || 'Root')}`;\n }\n }\n let shouldForwardPropOption = shouldForwardProp;\n\n // TODO v6: remove `Root` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n if (componentSlot === 'Root' || componentSlot === 'root') {\n shouldForwardPropOption = rootShouldForwardProp;\n } else if (componentSlot) {\n // any other slot specified\n shouldForwardPropOption = slotShouldForwardProp;\n } else if (isStringTag(tag)) {\n // for string (html) tag, preserve the behavior in emotion & styled-components.\n shouldForwardPropOption = undefined;\n }\n const defaultStyledResolver = styledEngineStyled(tag, _extends({\n shouldForwardProp: shouldForwardPropOption,\n label\n }, options));\n const transformStyleArg = stylesArg => {\n // On the server Emotion doesn't use React.forwardRef for creating components, so the created\n // component stays as a function. This condition makes sure that we do not interpolate functions\n // which are basically components used as a selectors.\n if (typeof stylesArg === 'function' && stylesArg.__emotion_real !== stylesArg || isPlainObject(stylesArg)) {\n return props => processStyleArg(stylesArg, _extends({}, props, {\n theme: resolveTheme({\n theme: props.theme,\n defaultTheme,\n themeId\n })\n }));\n }\n return stylesArg;\n };\n const muiStyledResolver = (styleArg, ...expressions) => {\n let transformedStyleArg = transformStyleArg(styleArg);\n const expressionsWithDefaultTheme = expressions ? expressions.map(transformStyleArg) : [];\n if (componentName && overridesResolver) {\n expressionsWithDefaultTheme.push(props => {\n const theme = resolveTheme(_extends({}, props, {\n defaultTheme,\n themeId\n }));\n if (!theme.components || !theme.components[componentName] || !theme.components[componentName].styleOverrides) {\n return null;\n }\n const styleOverrides = theme.components[componentName].styleOverrides;\n const resolvedStyleOverrides = {};\n // TODO: v7 remove iteration and use `resolveStyleArg(styleOverrides[slot])` directly\n Object.entries(styleOverrides).forEach(([slotKey, slotStyle]) => {\n resolvedStyleOverrides[slotKey] = processStyleArg(slotStyle, _extends({}, props, {\n theme\n }));\n });\n return overridesResolver(props, resolvedStyleOverrides);\n });\n }\n if (componentName && !skipVariantsResolver) {\n expressionsWithDefaultTheme.push(props => {\n var _theme$components;\n const theme = resolveTheme(_extends({}, props, {\n defaultTheme,\n themeId\n }));\n const themeVariants = theme == null || (_theme$components = theme.components) == null || (_theme$components = _theme$components[componentName]) == null ? void 0 : _theme$components.variants;\n return processStyleArg({\n variants: themeVariants\n }, _extends({}, props, {\n theme\n }));\n });\n }\n if (!skipSx) {\n expressionsWithDefaultTheme.push(systemSx);\n }\n const numOfCustomFnsApplied = expressionsWithDefaultTheme.length - expressions.length;\n if (Array.isArray(styleArg) && numOfCustomFnsApplied > 0) {\n const placeholders = new Array(numOfCustomFnsApplied).fill('');\n // If the type is array, than we need to add placeholders in the template for the overrides, variants and the sx styles.\n transformedStyleArg = [...styleArg, ...placeholders];\n transformedStyleArg.raw = [...styleArg.raw, ...placeholders];\n }\n const Component = defaultStyledResolver(transformedStyleArg, ...expressionsWithDefaultTheme);\n if (process.env.NODE_ENV !== 'production') {\n let displayName;\n if (componentName) {\n displayName = `${componentName}${capitalize(componentSlot || '')}`;\n }\n if (displayName === undefined) {\n displayName = `Styled(${getDisplayName(tag)})`;\n }\n Component.displayName = displayName;\n }\n if (tag.muiName) {\n Component.muiName = tag.muiName;\n }\n return Component;\n };\n if (defaultStyledResolver.withConfig) {\n muiStyledResolver.withConfig = defaultStyledResolver.withConfig;\n }\n return muiStyledResolver;\n };\n}","import resolveProps from '@mui/utils/resolveProps';\nexport default function getThemeProps(params) {\n const {\n theme,\n name,\n props\n } = params;\n if (!theme || !theme.components || !theme.components[name] || !theme.components[name].defaultProps) {\n return props;\n }\n return resolveProps(theme.components[name].defaultProps, props);\n}","'use client';\n\nimport getThemeProps from './getThemeProps';\nimport useTheme from '../useTheme';\nexport default function useThemeProps({\n props,\n name,\n defaultTheme,\n themeId\n}) {\n let theme = useTheme(defaultTheme);\n if (themeId) {\n theme = theme[themeId] || theme;\n }\n const mergedProps = getThemeProps({\n theme,\n name,\n props\n });\n return mergedProps;\n}","import _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\n/* eslint-disable @typescript-eslint/naming-convention */\nimport clamp from '@mui/utils/clamp';\n/**\n * Returns a number whose value is limited to the given range.\n * @param {number} value The value to be clamped\n * @param {number} min The lower boundary of the output range\n * @param {number} max The upper boundary of the output range\n * @returns {number} A number in the range [min, max]\n */\nfunction clampWrapper(value, min = 0, max = 1) {\n if (process.env.NODE_ENV !== 'production') {\n if (value < min || value > max) {\n console.error(`MUI: The value provided ${value} is out of range [${min}, ${max}].`);\n }\n }\n return clamp(value, min, max);\n}\n\n/**\n * Converts a color from CSS hex format to CSS rgb format.\n * @param {string} color - Hex color, i.e. #nnn or #nnnnnn\n * @returns {string} A CSS rgb color string\n */\nexport function hexToRgb(color) {\n color = color.slice(1);\n const re = new RegExp(`.{1,${color.length >= 6 ? 2 : 1}}`, 'g');\n let colors = color.match(re);\n if (colors && colors[0].length === 1) {\n colors = colors.map(n => n + n);\n }\n return colors ? `rgb${colors.length === 4 ? 'a' : ''}(${colors.map((n, index) => {\n return index < 3 ? parseInt(n, 16) : Math.round(parseInt(n, 16) / 255 * 1000) / 1000;\n }).join(', ')})` : '';\n}\nfunction intToHex(int) {\n const hex = int.toString(16);\n return hex.length === 1 ? `0${hex}` : hex;\n}\n\n/**\n * Returns an object with the type and values of a color.\n *\n * Note: Does not support rgb % values.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @returns {object} - A MUI color object: {type: string, values: number[]}\n */\nexport function decomposeColor(color) {\n // Idempotent\n if (color.type) {\n return color;\n }\n if (color.charAt(0) === '#') {\n return decomposeColor(hexToRgb(color));\n }\n const marker = color.indexOf('(');\n const type = color.substring(0, marker);\n if (['rgb', 'rgba', 'hsl', 'hsla', 'color'].indexOf(type) === -1) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: Unsupported \\`${color}\\` color.\nThe following formats are supported: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color().` : _formatMuiErrorMessage(9, color));\n }\n let values = color.substring(marker + 1, color.length - 1);\n let colorSpace;\n if (type === 'color') {\n values = values.split(' ');\n colorSpace = values.shift();\n if (values.length === 4 && values[3].charAt(0) === '/') {\n values[3] = values[3].slice(1);\n }\n if (['srgb', 'display-p3', 'a98-rgb', 'prophoto-rgb', 'rec-2020'].indexOf(colorSpace) === -1) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: unsupported \\`${colorSpace}\\` color space.\nThe following color spaces are supported: srgb, display-p3, a98-rgb, prophoto-rgb, rec-2020.` : _formatMuiErrorMessage(10, colorSpace));\n }\n } else {\n values = values.split(',');\n }\n values = values.map(value => parseFloat(value));\n return {\n type,\n values,\n colorSpace\n };\n}\n\n/**\n * Returns a channel created from the input color.\n *\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @returns {string} - The channel for the color, that can be used in rgba or hsla colors\n */\nexport const colorChannel = color => {\n const decomposedColor = decomposeColor(color);\n return decomposedColor.values.slice(0, 3).map((val, idx) => decomposedColor.type.indexOf('hsl') !== -1 && idx !== 0 ? `${val}%` : val).join(' ');\n};\nexport const private_safeColorChannel = (color, warning) => {\n try {\n return colorChannel(color);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n};\n\n/**\n * Converts a color object with type and values to a string.\n * @param {object} color - Decomposed color\n * @param {string} color.type - One of: 'rgb', 'rgba', 'hsl', 'hsla', 'color'\n * @param {array} color.values - [n,n,n] or [n,n,n,n]\n * @returns {string} A CSS color string\n */\nexport function recomposeColor(color) {\n const {\n type,\n colorSpace\n } = color;\n let {\n values\n } = color;\n if (type.indexOf('rgb') !== -1) {\n // Only convert the first 3 values to int (i.e. not alpha)\n values = values.map((n, i) => i < 3 ? parseInt(n, 10) : n);\n } else if (type.indexOf('hsl') !== -1) {\n values[1] = `${values[1]}%`;\n values[2] = `${values[2]}%`;\n }\n if (type.indexOf('color') !== -1) {\n values = `${colorSpace} ${values.join(' ')}`;\n } else {\n values = `${values.join(', ')}`;\n }\n return `${type}(${values})`;\n}\n\n/**\n * Converts a color from CSS rgb format to CSS hex format.\n * @param {string} color - RGB color, i.e. rgb(n, n, n)\n * @returns {string} A CSS rgb color string, i.e. #nnnnnn\n */\nexport function rgbToHex(color) {\n // Idempotent\n if (color.indexOf('#') === 0) {\n return color;\n }\n const {\n values\n } = decomposeColor(color);\n return `#${values.map((n, i) => intToHex(i === 3 ? Math.round(255 * n) : n)).join('')}`;\n}\n\n/**\n * Converts a color from hsl format to rgb format.\n * @param {string} color - HSL color values\n * @returns {string} rgb color values\n */\nexport function hslToRgb(color) {\n color = decomposeColor(color);\n const {\n values\n } = color;\n const h = values[0];\n const s = values[1] / 100;\n const l = values[2] / 100;\n const a = s * Math.min(l, 1 - l);\n const f = (n, k = (n + h / 30) % 12) => l - a * Math.max(Math.min(k - 3, 9 - k, 1), -1);\n let type = 'rgb';\n const rgb = [Math.round(f(0) * 255), Math.round(f(8) * 255), Math.round(f(4) * 255)];\n if (color.type === 'hsla') {\n type += 'a';\n rgb.push(values[3]);\n }\n return recomposeColor({\n type,\n values: rgb\n });\n}\n/**\n * The relative brightness of any point in a color space,\n * normalized to 0 for darkest black and 1 for lightest white.\n *\n * Formula: https://www.w3.org/TR/WCAG20-TECHS/G17.html#G17-tests\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @returns {number} The relative brightness of the color in the range 0 - 1\n */\nexport function getLuminance(color) {\n color = decomposeColor(color);\n let rgb = color.type === 'hsl' || color.type === 'hsla' ? decomposeColor(hslToRgb(color)).values : color.values;\n rgb = rgb.map(val => {\n if (color.type !== 'color') {\n val /= 255; // normalized\n }\n return val <= 0.03928 ? val / 12.92 : ((val + 0.055) / 1.055) ** 2.4;\n });\n\n // Truncate at 3 digits\n return Number((0.2126 * rgb[0] + 0.7152 * rgb[1] + 0.0722 * rgb[2]).toFixed(3));\n}\n\n/**\n * Calculates the contrast ratio between two colors.\n *\n * Formula: https://www.w3.org/TR/WCAG20-TECHS/G17.html#G17-tests\n * @param {string} foreground - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla()\n * @param {string} background - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla()\n * @returns {number} A contrast ratio value in the range 0 - 21.\n */\nexport function getContrastRatio(foreground, background) {\n const lumA = getLuminance(foreground);\n const lumB = getLuminance(background);\n return (Math.max(lumA, lumB) + 0.05) / (Math.min(lumA, lumB) + 0.05);\n}\n\n/**\n * Sets the absolute transparency of a color.\n * Any existing alpha values are overwritten.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} value - value to set the alpha channel to in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function alpha(color, value) {\n color = decomposeColor(color);\n value = clampWrapper(value);\n if (color.type === 'rgb' || color.type === 'hsl') {\n color.type += 'a';\n }\n if (color.type === 'color') {\n color.values[3] = `/${value}`;\n } else {\n color.values[3] = value;\n }\n return recomposeColor(color);\n}\nexport function private_safeAlpha(color, value, warning) {\n try {\n return alpha(color, value);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Darkens a color.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} coefficient - multiplier in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function darken(color, coefficient) {\n color = decomposeColor(color);\n coefficient = clampWrapper(coefficient);\n if (color.type.indexOf('hsl') !== -1) {\n color.values[2] *= 1 - coefficient;\n } else if (color.type.indexOf('rgb') !== -1 || color.type.indexOf('color') !== -1) {\n for (let i = 0; i < 3; i += 1) {\n color.values[i] *= 1 - coefficient;\n }\n }\n return recomposeColor(color);\n}\nexport function private_safeDarken(color, coefficient, warning) {\n try {\n return darken(color, coefficient);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Lightens a color.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} coefficient - multiplier in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function lighten(color, coefficient) {\n color = decomposeColor(color);\n coefficient = clampWrapper(coefficient);\n if (color.type.indexOf('hsl') !== -1) {\n color.values[2] += (100 - color.values[2]) * coefficient;\n } else if (color.type.indexOf('rgb') !== -1) {\n for (let i = 0; i < 3; i += 1) {\n color.values[i] += (255 - color.values[i]) * coefficient;\n }\n } else if (color.type.indexOf('color') !== -1) {\n for (let i = 0; i < 3; i += 1) {\n color.values[i] += (1 - color.values[i]) * coefficient;\n }\n }\n return recomposeColor(color);\n}\nexport function private_safeLighten(color, coefficient, warning) {\n try {\n return lighten(color, coefficient);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Darken or lighten a color, depending on its luminance.\n * Light colors are darkened, dark colors are lightened.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} coefficient=0.15 - multiplier in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function emphasize(color, coefficient = 0.15) {\n return getLuminance(color) > 0.5 ? darken(color, coefficient) : lighten(color, coefficient);\n}\nexport function private_safeEmphasize(color, coefficient, warning) {\n try {\n return emphasize(color, coefficient);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Blend a transparent overlay color with a background color, resulting in a single\n * RGB color.\n * @param {string} background - CSS color\n * @param {string} overlay - CSS color\n * @param {number} opacity - Opacity multiplier in the range 0 - 1\n * @param {number} [gamma=1.0] - Gamma correction factor. For gamma-correct blending, 2.2 is usual.\n */\nexport function blend(background, overlay, opacity, gamma = 1.0) {\n const blendChannel = (b, o) => Math.round((b ** (1 / gamma) * (1 - opacity) + o ** (1 / gamma) * opacity) ** gamma);\n const backgroundColor = decomposeColor(background);\n const overlayColor = decomposeColor(overlay);\n const rgb = [blendChannel(backgroundColor.values[0], overlayColor.values[0]), blendChannel(backgroundColor.values[1], overlayColor.values[1]), blendChannel(backgroundColor.values[2], overlayColor.values[2])];\n return recomposeColor({\n type: 'rgb',\n values: rgb\n });\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nexport default function createMixins(breakpoints, mixins) {\n return _extends({\n toolbar: {\n minHeight: 56,\n [breakpoints.up('xs')]: {\n '@media (orientation: landscape)': {\n minHeight: 48\n }\n },\n [breakpoints.up('sm')]: {\n minHeight: 64\n }\n }\n }, mixins);\n}","const common = {\n black: '#000',\n white: '#fff'\n};\nexport default common;","const grey = {\n 50: '#fafafa',\n 100: '#f5f5f5',\n 200: '#eeeeee',\n 300: '#e0e0e0',\n 400: '#bdbdbd',\n 500: '#9e9e9e',\n 600: '#757575',\n 700: '#616161',\n 800: '#424242',\n 900: '#212121',\n A100: '#f5f5f5',\n A200: '#eeeeee',\n A400: '#bdbdbd',\n A700: '#616161'\n};\nexport default grey;","const purple = {\n 50: '#f3e5f5',\n 100: '#e1bee7',\n 200: '#ce93d8',\n 300: '#ba68c8',\n 400: '#ab47bc',\n 500: '#9c27b0',\n 600: '#8e24aa',\n 700: '#7b1fa2',\n 800: '#6a1b9a',\n 900: '#4a148c',\n A100: '#ea80fc',\n A200: '#e040fb',\n A400: '#d500f9',\n A700: '#aa00ff'\n};\nexport default purple;","const red = {\n 50: '#ffebee',\n 100: '#ffcdd2',\n 200: '#ef9a9a',\n 300: '#e57373',\n 400: '#ef5350',\n 500: '#f44336',\n 600: '#e53935',\n 700: '#d32f2f',\n 800: '#c62828',\n 900: '#b71c1c',\n A100: '#ff8a80',\n A200: '#ff5252',\n A400: '#ff1744',\n A700: '#d50000'\n};\nexport default red;","const orange = {\n 50: '#fff3e0',\n 100: '#ffe0b2',\n 200: '#ffcc80',\n 300: '#ffb74d',\n 400: '#ffa726',\n 500: '#ff9800',\n 600: '#fb8c00',\n 700: '#f57c00',\n 800: '#ef6c00',\n 900: '#e65100',\n A100: '#ffd180',\n A200: '#ffab40',\n A400: '#ff9100',\n A700: '#ff6d00'\n};\nexport default orange;","const blue = {\n 50: '#e3f2fd',\n 100: '#bbdefb',\n 200: '#90caf9',\n 300: '#64b5f6',\n 400: '#42a5f5',\n 500: '#2196f3',\n 600: '#1e88e5',\n 700: '#1976d2',\n 800: '#1565c0',\n 900: '#0d47a1',\n A100: '#82b1ff',\n A200: '#448aff',\n A400: '#2979ff',\n A700: '#2962ff'\n};\nexport default blue;","const lightBlue = {\n 50: '#e1f5fe',\n 100: '#b3e5fc',\n 200: '#81d4fa',\n 300: '#4fc3f7',\n 400: '#29b6f6',\n 500: '#03a9f4',\n 600: '#039be5',\n 700: '#0288d1',\n 800: '#0277bd',\n 900: '#01579b',\n A100: '#80d8ff',\n A200: '#40c4ff',\n A400: '#00b0ff',\n A700: '#0091ea'\n};\nexport default lightBlue;","const green = {\n 50: '#e8f5e9',\n 100: '#c8e6c9',\n 200: '#a5d6a7',\n 300: '#81c784',\n 400: '#66bb6a',\n 500: '#4caf50',\n 600: '#43a047',\n 700: '#388e3c',\n 800: '#2e7d32',\n 900: '#1b5e20',\n A100: '#b9f6ca',\n A200: '#69f0ae',\n A400: '#00e676',\n A700: '#00c853'\n};\nexport default green;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\nconst _excluded = [\"mode\", \"contrastThreshold\", \"tonalOffset\"];\nimport { deepmerge } from '@mui/utils';\nimport { darken, getContrastRatio, lighten } from '@mui/system';\nimport common from '../colors/common';\nimport grey from '../colors/grey';\nimport purple from '../colors/purple';\nimport red from '../colors/red';\nimport orange from '../colors/orange';\nimport blue from '../colors/blue';\nimport lightBlue from '../colors/lightBlue';\nimport green from '../colors/green';\nexport const light = {\n // The colors used to style the text.\n text: {\n // The most important text.\n primary: 'rgba(0, 0, 0, 0.87)',\n // Secondary text.\n secondary: 'rgba(0, 0, 0, 0.6)',\n // Disabled text have even lower visual prominence.\n disabled: 'rgba(0, 0, 0, 0.38)'\n },\n // The color used to divide different elements.\n divider: 'rgba(0, 0, 0, 0.12)',\n // The background colors used to style the surfaces.\n // Consistency between these values is important.\n background: {\n paper: common.white,\n default: common.white\n },\n // The colors used to style the action elements.\n action: {\n // The color of an active action like an icon button.\n active: 'rgba(0, 0, 0, 0.54)',\n // The color of an hovered action.\n hover: 'rgba(0, 0, 0, 0.04)',\n hoverOpacity: 0.04,\n // The color of a selected action.\n selected: 'rgba(0, 0, 0, 0.08)',\n selectedOpacity: 0.08,\n // The color of a disabled action.\n disabled: 'rgba(0, 0, 0, 0.26)',\n // The background color of a disabled action.\n disabledBackground: 'rgba(0, 0, 0, 0.12)',\n disabledOpacity: 0.38,\n focus: 'rgba(0, 0, 0, 0.12)',\n focusOpacity: 0.12,\n activatedOpacity: 0.12\n }\n};\nexport const dark = {\n text: {\n primary: common.white,\n secondary: 'rgba(255, 255, 255, 0.7)',\n disabled: 'rgba(255, 255, 255, 0.5)',\n icon: 'rgba(255, 255, 255, 0.5)'\n },\n divider: 'rgba(255, 255, 255, 0.12)',\n background: {\n paper: '#121212',\n default: '#121212'\n },\n action: {\n active: common.white,\n hover: 'rgba(255, 255, 255, 0.08)',\n hoverOpacity: 0.08,\n selected: 'rgba(255, 255, 255, 0.16)',\n selectedOpacity: 0.16,\n disabled: 'rgba(255, 255, 255, 0.3)',\n disabledBackground: 'rgba(255, 255, 255, 0.12)',\n disabledOpacity: 0.38,\n focus: 'rgba(255, 255, 255, 0.12)',\n focusOpacity: 0.12,\n activatedOpacity: 0.24\n }\n};\nfunction addLightOrDark(intent, direction, shade, tonalOffset) {\n const tonalOffsetLight = tonalOffset.light || tonalOffset;\n const tonalOffsetDark = tonalOffset.dark || tonalOffset * 1.5;\n if (!intent[direction]) {\n if (intent.hasOwnProperty(shade)) {\n intent[direction] = intent[shade];\n } else if (direction === 'light') {\n intent.light = lighten(intent.main, tonalOffsetLight);\n } else if (direction === 'dark') {\n intent.dark = darken(intent.main, tonalOffsetDark);\n }\n }\n}\nfunction getDefaultPrimary(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: blue[200],\n light: blue[50],\n dark: blue[400]\n };\n }\n return {\n main: blue[700],\n light: blue[400],\n dark: blue[800]\n };\n}\nfunction getDefaultSecondary(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: purple[200],\n light: purple[50],\n dark: purple[400]\n };\n }\n return {\n main: purple[500],\n light: purple[300],\n dark: purple[700]\n };\n}\nfunction getDefaultError(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: red[500],\n light: red[300],\n dark: red[700]\n };\n }\n return {\n main: red[700],\n light: red[400],\n dark: red[800]\n };\n}\nfunction getDefaultInfo(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: lightBlue[400],\n light: lightBlue[300],\n dark: lightBlue[700]\n };\n }\n return {\n main: lightBlue[700],\n light: lightBlue[500],\n dark: lightBlue[900]\n };\n}\nfunction getDefaultSuccess(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: green[400],\n light: green[300],\n dark: green[700]\n };\n }\n return {\n main: green[800],\n light: green[500],\n dark: green[900]\n };\n}\nfunction getDefaultWarning(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: orange[400],\n light: orange[300],\n dark: orange[700]\n };\n }\n return {\n main: '#ed6c02',\n // closest to orange[800] that pass 3:1.\n light: orange[500],\n dark: orange[900]\n };\n}\nexport default function createPalette(palette) {\n const {\n mode = 'light',\n contrastThreshold = 3,\n tonalOffset = 0.2\n } = palette,\n other = _objectWithoutPropertiesLoose(palette, _excluded);\n const primary = palette.primary || getDefaultPrimary(mode);\n const secondary = palette.secondary || getDefaultSecondary(mode);\n const error = palette.error || getDefaultError(mode);\n const info = palette.info || getDefaultInfo(mode);\n const success = palette.success || getDefaultSuccess(mode);\n const warning = palette.warning || getDefaultWarning(mode);\n\n // Use the same logic as\n // Bootstrap: https://github.com/twbs/bootstrap/blob/1d6e3710dd447de1a200f29e8fa521f8a0908f70/scss/_functions.scss#L59\n // and material-components-web https://github.com/material-components/material-components-web/blob/ac46b8863c4dab9fc22c4c662dc6bd1b65dd652f/packages/mdc-theme/_functions.scss#L54\n function getContrastText(background) {\n const contrastText = getContrastRatio(background, dark.text.primary) >= contrastThreshold ? dark.text.primary : light.text.primary;\n if (process.env.NODE_ENV !== 'production') {\n const contrast = getContrastRatio(background, contrastText);\n if (contrast < 3) {\n console.error([`MUI: The contrast ratio of ${contrast}:1 for ${contrastText} on ${background}`, 'falls below the WCAG recommended absolute minimum contrast ratio of 3:1.', 'https://www.w3.org/TR/2008/REC-WCAG20-20081211/#visual-audio-contrast-contrast'].join('\\n'));\n }\n }\n return contrastText;\n }\n const augmentColor = ({\n color,\n name,\n mainShade = 500,\n lightShade = 300,\n darkShade = 700\n }) => {\n color = _extends({}, color);\n if (!color.main && color[mainShade]) {\n color.main = color[mainShade];\n }\n if (!color.hasOwnProperty('main')) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: The color${name ? ` (${name})` : ''} provided to augmentColor(color) is invalid.\nThe color object needs to have a \\`main\\` property or a \\`${mainShade}\\` property.` : _formatMuiErrorMessage(11, name ? ` (${name})` : '', mainShade));\n }\n if (typeof color.main !== 'string') {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: The color${name ? ` (${name})` : ''} provided to augmentColor(color) is invalid.\n\\`color.main\\` should be a string, but \\`${JSON.stringify(color.main)}\\` was provided instead.\n\nDid you intend to use one of the following approaches?\n\nimport { green } from \"@mui/material/colors\";\n\nconst theme1 = createTheme({ palette: {\n primary: green,\n} });\n\nconst theme2 = createTheme({ palette: {\n primary: { main: green[500] },\n} });` : _formatMuiErrorMessage(12, name ? ` (${name})` : '', JSON.stringify(color.main)));\n }\n addLightOrDark(color, 'light', lightShade, tonalOffset);\n addLightOrDark(color, 'dark', darkShade, tonalOffset);\n if (!color.contrastText) {\n color.contrastText = getContrastText(color.main);\n }\n return color;\n };\n const modes = {\n dark,\n light\n };\n if (process.env.NODE_ENV !== 'production') {\n if (!modes[mode]) {\n console.error(`MUI: The palette mode \\`${mode}\\` is not supported.`);\n }\n }\n const paletteOutput = deepmerge(_extends({\n // A collection of common colors.\n common: _extends({}, common),\n // prevent mutable object.\n // The palette mode, can be light or dark.\n mode,\n // The colors used to represent primary interface elements for a user.\n primary: augmentColor({\n color: primary,\n name: 'primary'\n }),\n // The colors used to represent secondary interface elements for a user.\n secondary: augmentColor({\n color: secondary,\n name: 'secondary',\n mainShade: 'A400',\n lightShade: 'A200',\n darkShade: 'A700'\n }),\n // The colors used to represent interface elements that the user should be made aware of.\n error: augmentColor({\n color: error,\n name: 'error'\n }),\n // The colors used to represent potentially dangerous actions or important messages.\n warning: augmentColor({\n color: warning,\n name: 'warning'\n }),\n // The colors used to present information to the user that is neutral and not necessarily important.\n info: augmentColor({\n color: info,\n name: 'info'\n }),\n // The colors used to indicate the successful completion of an action that user triggered.\n success: augmentColor({\n color: success,\n name: 'success'\n }),\n // The grey colors.\n grey,\n // Used by `getContrastText()` to maximize the contrast between\n // the background and the text.\n contrastThreshold,\n // Takes a background color and returns the text color that maximizes the contrast.\n getContrastText,\n // Generate a rich color object.\n augmentColor,\n // Used by the functions below to shift a color's luminance by approximately\n // two indexes within its tonal palette.\n // E.g., shift from Red 500 to Red 300 or Red 700.\n tonalOffset\n }, modes[mode]), other);\n return paletteOutput;\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"fontFamily\", \"fontSize\", \"fontWeightLight\", \"fontWeightRegular\", \"fontWeightMedium\", \"fontWeightBold\", \"htmlFontSize\", \"allVariants\", \"pxToRem\"];\nimport { deepmerge } from '@mui/utils';\nfunction round(value) {\n return Math.round(value * 1e5) / 1e5;\n}\nconst caseAllCaps = {\n textTransform: 'uppercase'\n};\nconst defaultFontFamily = '\"Roboto\", \"Helvetica\", \"Arial\", sans-serif';\n\n/**\n * @see @link{https://m2.material.io/design/typography/the-type-system.html}\n * @see @link{https://m2.material.io/design/typography/understanding-typography.html}\n */\nexport default function createTypography(palette, typography) {\n const _ref = typeof typography === 'function' ? typography(palette) : typography,\n {\n fontFamily = defaultFontFamily,\n // The default font size of the Material Specification.\n fontSize = 14,\n // px\n fontWeightLight = 300,\n fontWeightRegular = 400,\n fontWeightMedium = 500,\n fontWeightBold = 700,\n // Tell MUI what's the font-size on the html element.\n // 16px is the default font-size used by browsers.\n htmlFontSize = 16,\n // Apply the CSS properties to all the variants.\n allVariants,\n pxToRem: pxToRem2\n } = _ref,\n other = _objectWithoutPropertiesLoose(_ref, _excluded);\n if (process.env.NODE_ENV !== 'production') {\n if (typeof fontSize !== 'number') {\n console.error('MUI: `fontSize` is required to be a number.');\n }\n if (typeof htmlFontSize !== 'number') {\n console.error('MUI: `htmlFontSize` is required to be a number.');\n }\n }\n const coef = fontSize / 14;\n const pxToRem = pxToRem2 || (size => `${size / htmlFontSize * coef}rem`);\n const buildVariant = (fontWeight, size, lineHeight, letterSpacing, casing) => _extends({\n fontFamily,\n fontWeight,\n fontSize: pxToRem(size),\n // Unitless following https://meyerweb.com/eric/thoughts/2006/02/08/unitless-line-heights/\n lineHeight\n }, fontFamily === defaultFontFamily ? {\n letterSpacing: `${round(letterSpacing / size)}em`\n } : {}, casing, allVariants);\n const variants = {\n h1: buildVariant(fontWeightLight, 96, 1.167, -1.5),\n h2: buildVariant(fontWeightLight, 60, 1.2, -0.5),\n h3: buildVariant(fontWeightRegular, 48, 1.167, 0),\n h4: buildVariant(fontWeightRegular, 34, 1.235, 0.25),\n h5: buildVariant(fontWeightRegular, 24, 1.334, 0),\n h6: buildVariant(fontWeightMedium, 20, 1.6, 0.15),\n subtitle1: buildVariant(fontWeightRegular, 16, 1.75, 0.15),\n subtitle2: buildVariant(fontWeightMedium, 14, 1.57, 0.1),\n body1: buildVariant(fontWeightRegular, 16, 1.5, 0.15),\n body2: buildVariant(fontWeightRegular, 14, 1.43, 0.15),\n button: buildVariant(fontWeightMedium, 14, 1.75, 0.4, caseAllCaps),\n caption: buildVariant(fontWeightRegular, 12, 1.66, 0.4),\n overline: buildVariant(fontWeightRegular, 12, 2.66, 1, caseAllCaps),\n // TODO v6: Remove handling of 'inherit' variant from the theme as it is already handled in Material UI's Typography component. Also, remember to remove the associated types.\n inherit: {\n fontFamily: 'inherit',\n fontWeight: 'inherit',\n fontSize: 'inherit',\n lineHeight: 'inherit',\n letterSpacing: 'inherit'\n }\n };\n return deepmerge(_extends({\n htmlFontSize,\n pxToRem,\n fontFamily,\n fontSize,\n fontWeightLight,\n fontWeightRegular,\n fontWeightMedium,\n fontWeightBold\n }, variants), other, {\n clone: false // No need to clone deep\n });\n}","const shadowKeyUmbraOpacity = 0.2;\nconst shadowKeyPenumbraOpacity = 0.14;\nconst shadowAmbientShadowOpacity = 0.12;\nfunction createShadow(...px) {\n return [`${px[0]}px ${px[1]}px ${px[2]}px ${px[3]}px rgba(0,0,0,${shadowKeyUmbraOpacity})`, `${px[4]}px ${px[5]}px ${px[6]}px ${px[7]}px rgba(0,0,0,${shadowKeyPenumbraOpacity})`, `${px[8]}px ${px[9]}px ${px[10]}px ${px[11]}px rgba(0,0,0,${shadowAmbientShadowOpacity})`].join(',');\n}\n\n// Values from https://github.com/material-components/material-components-web/blob/be8747f94574669cb5e7add1a7c54fa41a89cec7/packages/mdc-elevation/_variables.scss\nconst shadows = ['none', createShadow(0, 2, 1, -1, 0, 1, 1, 0, 0, 1, 3, 0), createShadow(0, 3, 1, -2, 0, 2, 2, 0, 0, 1, 5, 0), createShadow(0, 3, 3, -2, 0, 3, 4, 0, 0, 1, 8, 0), createShadow(0, 2, 4, -1, 0, 4, 5, 0, 0, 1, 10, 0), createShadow(0, 3, 5, -1, 0, 5, 8, 0, 0, 1, 14, 0), createShadow(0, 3, 5, -1, 0, 6, 10, 0, 0, 1, 18, 0), createShadow(0, 4, 5, -2, 0, 7, 10, 1, 0, 2, 16, 1), createShadow(0, 5, 5, -3, 0, 8, 10, 1, 0, 3, 14, 2), createShadow(0, 5, 6, -3, 0, 9, 12, 1, 0, 3, 16, 2), createShadow(0, 6, 6, -3, 0, 10, 14, 1, 0, 4, 18, 3), createShadow(0, 6, 7, -4, 0, 11, 15, 1, 0, 4, 20, 3), createShadow(0, 7, 8, -4, 0, 12, 17, 2, 0, 5, 22, 4), createShadow(0, 7, 8, -4, 0, 13, 19, 2, 0, 5, 24, 4), createShadow(0, 7, 9, -4, 0, 14, 21, 2, 0, 5, 26, 4), createShadow(0, 8, 9, -5, 0, 15, 22, 2, 0, 6, 28, 5), createShadow(0, 8, 10, -5, 0, 16, 24, 2, 0, 6, 30, 5), createShadow(0, 8, 11, -5, 0, 17, 26, 2, 0, 6, 32, 5), createShadow(0, 9, 11, -5, 0, 18, 28, 2, 0, 7, 34, 6), createShadow(0, 9, 12, -6, 0, 19, 29, 2, 0, 7, 36, 6), createShadow(0, 10, 13, -6, 0, 20, 31, 3, 0, 8, 38, 7), createShadow(0, 10, 13, -6, 0, 21, 33, 3, 0, 8, 40, 7), createShadow(0, 10, 14, -6, 0, 22, 35, 3, 0, 8, 42, 7), createShadow(0, 11, 14, -7, 0, 23, 36, 3, 0, 9, 44, 8), createShadow(0, 11, 15, -7, 0, 24, 38, 3, 0, 9, 46, 8)];\nexport default shadows;","import _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nconst _excluded = [\"duration\", \"easing\", \"delay\"];\n// Follow https://material.google.com/motion/duration-easing.html#duration-easing-natural-easing-curves\n// to learn the context in which each easing should be used.\nexport const easing = {\n // This is the most common easing curve.\n easeInOut: 'cubic-bezier(0.4, 0, 0.2, 1)',\n // Objects enter the screen at full velocity from off-screen and\n // slowly decelerate to a resting point.\n easeOut: 'cubic-bezier(0.0, 0, 0.2, 1)',\n // Objects leave the screen at full velocity. They do not decelerate when off-screen.\n easeIn: 'cubic-bezier(0.4, 0, 1, 1)',\n // The sharp curve is used by objects that may return to the screen at any time.\n sharp: 'cubic-bezier(0.4, 0, 0.6, 1)'\n};\n\n// Follow https://m2.material.io/guidelines/motion/duration-easing.html#duration-easing-common-durations\n// to learn when use what timing\nexport const duration = {\n shortest: 150,\n shorter: 200,\n short: 250,\n // most basic recommended timing\n standard: 300,\n // this is to be used in complex animations\n complex: 375,\n // recommended when something is entering screen\n enteringScreen: 225,\n // recommended when something is leaving screen\n leavingScreen: 195\n};\nfunction formatMs(milliseconds) {\n return `${Math.round(milliseconds)}ms`;\n}\nfunction getAutoHeightDuration(height) {\n if (!height) {\n return 0;\n }\n const constant = height / 36;\n\n // https://www.wolframalpha.com/input/?i=(4+%2B+15+*+(x+%2F+36+)+**+0.25+%2B+(x+%2F+36)+%2F+5)+*+10\n return Math.round((4 + 15 * constant ** 0.25 + constant / 5) * 10);\n}\nexport default function createTransitions(inputTransitions) {\n const mergedEasing = _extends({}, easing, inputTransitions.easing);\n const mergedDuration = _extends({}, duration, inputTransitions.duration);\n const create = (props = ['all'], options = {}) => {\n const {\n duration: durationOption = mergedDuration.standard,\n easing: easingOption = mergedEasing.easeInOut,\n delay = 0\n } = options,\n other = _objectWithoutPropertiesLoose(options, _excluded);\n if (process.env.NODE_ENV !== 'production') {\n const isString = value => typeof value === 'string';\n // IE11 support, replace with Number.isNaN\n // eslint-disable-next-line no-restricted-globals\n const isNumber = value => !isNaN(parseFloat(value));\n if (!isString(props) && !Array.isArray(props)) {\n console.error('MUI: Argument \"props\" must be a string or Array.');\n }\n if (!isNumber(durationOption) && !isString(durationOption)) {\n console.error(`MUI: Argument \"duration\" must be a number or a string but found ${durationOption}.`);\n }\n if (!isString(easingOption)) {\n console.error('MUI: Argument \"easing\" must be a string.');\n }\n if (!isNumber(delay) && !isString(delay)) {\n console.error('MUI: Argument \"delay\" must be a number or a string.');\n }\n if (typeof options !== 'object') {\n console.error(['MUI: Secong argument of transition.create must be an object.', \"Arguments should be either `create('prop1', options)` or `create(['prop1', 'prop2'], options)`\"].join('\\n'));\n }\n if (Object.keys(other).length !== 0) {\n console.error(`MUI: Unrecognized argument(s) [${Object.keys(other).join(',')}].`);\n }\n }\n return (Array.isArray(props) ? props : [props]).map(animatedProp => `${animatedProp} ${typeof durationOption === 'string' ? durationOption : formatMs(durationOption)} ${easingOption} ${typeof delay === 'string' ? delay : formatMs(delay)}`).join(',');\n };\n return _extends({\n getAutoHeightDuration,\n create\n }, inputTransitions, {\n easing: mergedEasing,\n duration: mergedDuration\n });\n}","// We need to centralize the zIndex definitions as they work\n// like global values in the browser.\nconst zIndex = {\n mobileStepper: 1000,\n fab: 1050,\n speedDial: 1050,\n appBar: 1100,\n drawer: 1200,\n modal: 1300,\n snackbar: 1400,\n tooltip: 1500\n};\nexport default zIndex;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\nconst _excluded = [\"breakpoints\", \"mixins\", \"spacing\", \"palette\", \"transitions\", \"typography\", \"shape\"];\nimport { deepmerge } from '@mui/utils';\nimport { createTheme as systemCreateTheme, unstable_defaultSxConfig as defaultSxConfig, unstable_styleFunctionSx as styleFunctionSx } from '@mui/system';\nimport generateUtilityClass from '@mui/utils/generateUtilityClass';\nimport createMixins from './createMixins';\nimport createPalette from './createPalette';\nimport createTypography from './createTypography';\nimport shadows from './shadows';\nimport createTransitions from './createTransitions';\nimport zIndex from './zIndex';\nfunction createTheme(options = {}, ...args) {\n const {\n mixins: mixinsInput = {},\n palette: paletteInput = {},\n transitions: transitionsInput = {},\n typography: typographyInput = {}\n } = options,\n other = _objectWithoutPropertiesLoose(options, _excluded);\n if (options.vars) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: \\`vars\\` is a private field used for CSS variables support.\nPlease use another name.` : _formatMuiErrorMessage(18));\n }\n const palette = createPalette(paletteInput);\n const systemTheme = systemCreateTheme(options);\n let muiTheme = deepmerge(systemTheme, {\n mixins: createMixins(systemTheme.breakpoints, mixinsInput),\n palette,\n // Don't use [...shadows] until you've verified its transpiled code is not invoking the iterator protocol.\n shadows: shadows.slice(),\n typography: createTypography(palette, typographyInput),\n transitions: createTransitions(transitionsInput),\n zIndex: _extends({}, zIndex)\n });\n muiTheme = deepmerge(muiTheme, other);\n muiTheme = args.reduce((acc, argument) => deepmerge(acc, argument), muiTheme);\n if (process.env.NODE_ENV !== 'production') {\n // TODO v6: Refactor to use globalStateClassesMapping from @mui/utils once `readOnly` state class is used in Rating component.\n const stateClasses = ['active', 'checked', 'completed', 'disabled', 'error', 'expanded', 'focused', 'focusVisible', 'required', 'selected'];\n const traverse = (node, component) => {\n let key;\n\n // eslint-disable-next-line guard-for-in, no-restricted-syntax\n for (key in node) {\n const child = node[key];\n if (stateClasses.indexOf(key) !== -1 && Object.keys(child).length > 0) {\n if (process.env.NODE_ENV !== 'production') {\n const stateClass = generateUtilityClass('', key);\n console.error([`MUI: The \\`${component}\\` component increases ` + `the CSS specificity of the \\`${key}\\` internal state.`, 'You can not override it like this: ', JSON.stringify(node, null, 2), '', `Instead, you need to use the '&.${stateClass}' syntax:`, JSON.stringify({\n root: {\n [`&.${stateClass}`]: child\n }\n }, null, 2), '', 'https://mui.com/r/state-classes-guide'].join('\\n'));\n }\n // Remove the style to prevent global conflicts.\n node[key] = {};\n }\n }\n };\n Object.keys(muiTheme.components).forEach(component => {\n const styleOverrides = muiTheme.components[component].styleOverrides;\n if (styleOverrides && component.indexOf('Mui') === 0) {\n traverse(styleOverrides, component);\n }\n });\n }\n muiTheme.unstable_sxConfig = _extends({}, defaultSxConfig, other == null ? void 0 : other.unstable_sxConfig);\n muiTheme.unstable_sx = function sx(props) {\n return styleFunctionSx({\n sx: props,\n theme: this\n });\n };\n return muiTheme;\n}\nlet warnedOnce = false;\nexport function createMuiTheme(...args) {\n if (process.env.NODE_ENV !== 'production') {\n if (!warnedOnce) {\n warnedOnce = true;\n console.error(['MUI: the createMuiTheme function was renamed to createTheme.', '', \"You should use `import { createTheme } from '@mui/material/styles'`\"].join('\\n'));\n }\n }\n return createTheme(...args);\n}\nexport default createTheme;","'use client';\n\nimport createTheme from './createTheme';\nconst defaultTheme = createTheme();\nexport default defaultTheme;","export default '$$material';","'use client';\n\nimport { useThemeProps as systemUseThemeProps } from '@mui/system';\nimport defaultTheme from './defaultTheme';\nimport THEME_ID from './identifier';\nexport default function useThemeProps({\n props,\n name\n}) {\n return systemUseThemeProps({\n props,\n name,\n defaultTheme,\n themeId: THEME_ID\n });\n}","'use client';\n\nimport { createStyled, shouldForwardProp } from '@mui/system';\nimport defaultTheme from './defaultTheme';\nimport THEME_ID from './identifier';\nexport const rootShouldForwardProp = prop => shouldForwardProp(prop) && prop !== 'classes';\nexport const slotShouldForwardProp = shouldForwardProp;\nconst styled = createStyled({\n themeId: THEME_ID,\n defaultTheme,\n rootShouldForwardProp\n});\nexport default styled;","import generateUtilityClasses from '@mui/utils/generateUtilityClasses';\nimport generateUtilityClass from '@mui/utils/generateUtilityClass';\nexport function getSvgIconUtilityClass(slot) {\n return generateUtilityClass('MuiSvgIcon', slot);\n}\nconst svgIconClasses = generateUtilityClasses('MuiSvgIcon', ['root', 'colorPrimary', 'colorSecondary', 'colorAction', 'colorError', 'colorDisabled', 'fontSizeInherit', 'fontSizeSmall', 'fontSizeMedium', 'fontSizeLarge']);\nexport default svgIconClasses;","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"children\", \"className\", \"color\", \"component\", \"fontSize\", \"htmlColor\", \"inheritViewBox\", \"titleAccess\", \"viewBox\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport clsx from 'clsx';\nimport { unstable_composeClasses as composeClasses } from '@mui/base/composeClasses';\nimport capitalize from '../utils/capitalize';\nimport useThemeProps from '../styles/useThemeProps';\nimport styled from '../styles/styled';\nimport { getSvgIconUtilityClass } from './svgIconClasses';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nimport { jsxs as _jsxs } from \"react/jsx-runtime\";\nconst useUtilityClasses = ownerState => {\n const {\n color,\n fontSize,\n classes\n } = ownerState;\n const slots = {\n root: ['root', color !== 'inherit' && `color${capitalize(color)}`, `fontSize${capitalize(fontSize)}`]\n };\n return composeClasses(slots, getSvgIconUtilityClass, classes);\n};\nconst SvgIconRoot = styled('svg', {\n name: 'MuiSvgIcon',\n slot: 'Root',\n overridesResolver: (props, styles) => {\n const {\n ownerState\n } = props;\n return [styles.root, ownerState.color !== 'inherit' && styles[`color${capitalize(ownerState.color)}`], styles[`fontSize${capitalize(ownerState.fontSize)}`]];\n }\n})(({\n theme,\n ownerState\n}) => {\n var _theme$transitions, _theme$transitions$cr, _theme$transitions2, _theme$typography, _theme$typography$pxT, _theme$typography2, _theme$typography2$px, _theme$typography3, _theme$typography3$px, _palette$ownerState$c, _palette, _palette2, _palette3;\n return {\n userSelect: 'none',\n width: '1em',\n height: '1em',\n display: 'inline-block',\n // the will define the property that has `currentColor`\n // e.g. heroicons uses fill=\"none\" and stroke=\"currentColor\"\n fill: ownerState.hasSvgAsChild ? undefined : 'currentColor',\n flexShrink: 0,\n transition: (_theme$transitions = theme.transitions) == null || (_theme$transitions$cr = _theme$transitions.create) == null ? void 0 : _theme$transitions$cr.call(_theme$transitions, 'fill', {\n duration: (_theme$transitions2 = theme.transitions) == null || (_theme$transitions2 = _theme$transitions2.duration) == null ? void 0 : _theme$transitions2.shorter\n }),\n fontSize: {\n inherit: 'inherit',\n small: ((_theme$typography = theme.typography) == null || (_theme$typography$pxT = _theme$typography.pxToRem) == null ? void 0 : _theme$typography$pxT.call(_theme$typography, 20)) || '1.25rem',\n medium: ((_theme$typography2 = theme.typography) == null || (_theme$typography2$px = _theme$typography2.pxToRem) == null ? void 0 : _theme$typography2$px.call(_theme$typography2, 24)) || '1.5rem',\n large: ((_theme$typography3 = theme.typography) == null || (_theme$typography3$px = _theme$typography3.pxToRem) == null ? void 0 : _theme$typography3$px.call(_theme$typography3, 35)) || '2.1875rem'\n }[ownerState.fontSize],\n // TODO v5 deprecate, v6 remove for sx\n color: (_palette$ownerState$c = (_palette = (theme.vars || theme).palette) == null || (_palette = _palette[ownerState.color]) == null ? void 0 : _palette.main) != null ? _palette$ownerState$c : {\n action: (_palette2 = (theme.vars || theme).palette) == null || (_palette2 = _palette2.action) == null ? void 0 : _palette2.active,\n disabled: (_palette3 = (theme.vars || theme).palette) == null || (_palette3 = _palette3.action) == null ? void 0 : _palette3.disabled,\n inherit: undefined\n }[ownerState.color]\n };\n});\nconst SvgIcon = /*#__PURE__*/React.forwardRef(function SvgIcon(inProps, ref) {\n const props = useThemeProps({\n props: inProps,\n name: 'MuiSvgIcon'\n });\n const {\n children,\n className,\n color = 'inherit',\n component = 'svg',\n fontSize = 'medium',\n htmlColor,\n inheritViewBox = false,\n titleAccess,\n viewBox = '0 0 24 24'\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const hasSvgAsChild = /*#__PURE__*/React.isValidElement(children) && children.type === 'svg';\n const ownerState = _extends({}, props, {\n color,\n component,\n fontSize,\n instanceFontSize: inProps.fontSize,\n inheritViewBox,\n viewBox,\n hasSvgAsChild\n });\n const more = {};\n if (!inheritViewBox) {\n more.viewBox = viewBox;\n }\n const classes = useUtilityClasses(ownerState);\n return /*#__PURE__*/_jsxs(SvgIconRoot, _extends({\n as: component,\n className: clsx(classes.root, className),\n focusable: \"false\",\n color: htmlColor,\n \"aria-hidden\": titleAccess ? undefined : true,\n role: titleAccess ? 'img' : undefined,\n ref: ref\n }, more, other, hasSvgAsChild && children.props, {\n ownerState: ownerState,\n children: [hasSvgAsChild ? children.props.children : children, titleAccess ? /*#__PURE__*/_jsx(\"title\", {\n children: titleAccess\n }) : null]\n }));\n});\nprocess.env.NODE_ENV !== \"production\" ? SvgIcon.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the d.ts file and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * Node passed into the SVG element.\n */\n children: PropTypes.node,\n /**\n * Override or extend the styles applied to the component.\n */\n classes: PropTypes.object,\n /**\n * @ignore\n */\n className: PropTypes.string,\n /**\n * The color of the component.\n * It supports both default and custom theme colors, which can be added as shown in the\n * [palette customization guide](https://mui.com/material-ui/customization/palette/#custom-colors).\n * You can use the `htmlColor` prop to apply a color attribute to the SVG element.\n * @default 'inherit'\n */\n color: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.oneOf(['inherit', 'action', 'disabled', 'primary', 'secondary', 'error', 'info', 'success', 'warning']), PropTypes.string]),\n /**\n * The component used for the root node.\n * Either a string to use a HTML element or a component.\n */\n component: PropTypes.elementType,\n /**\n * The fontSize applied to the icon. Defaults to 24px, but can be configure to inherit font size.\n * @default 'medium'\n */\n fontSize: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.oneOf(['inherit', 'large', 'medium', 'small']), PropTypes.string]),\n /**\n * Applies a color attribute to the SVG element.\n */\n htmlColor: PropTypes.string,\n /**\n * If `true`, the root node will inherit the custom `component`'s viewBox and the `viewBox`\n * prop will be ignored.\n * Useful when you want to reference a custom `component` and have `SvgIcon` pass that\n * `component`'s viewBox to the root node.\n * @default false\n */\n inheritViewBox: PropTypes.bool,\n /**\n * The shape-rendering attribute. The behavior of the different options is described on the\n * [MDN Web Docs](https://developer.mozilla.org/en-US/docs/Web/SVG/Attribute/shape-rendering).\n * If you are having issues with blurry icons you should investigate this prop.\n */\n shapeRendering: PropTypes.string,\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Provides a human-readable title for the element that contains it.\n * https://www.w3.org/TR/SVG-access/#Equivalent\n */\n titleAccess: PropTypes.string,\n /**\n * Allows you to redefine what the coordinates without units mean inside an SVG element.\n * For example, if the SVG element is 500 (width) by 200 (height),\n * and you pass viewBox=\"0 0 50 20\",\n * this means that the coordinates inside the SVG will go from the top left corner (0,0)\n * to bottom right (50,20) and each unit will be worth 10px.\n * @default '0 0 24 24'\n */\n viewBox: PropTypes.string\n} : void 0;\nSvgIcon.muiName = 'SvgIcon';\nexport default SvgIcon;","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport * as React from 'react';\nimport SvgIcon from '../SvgIcon';\n\n/**\n * Private module reserved for @mui packages.\n */\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nexport default function createSvgIcon(path, displayName) {\n function Component(props, ref) {\n return /*#__PURE__*/_jsx(SvgIcon, _extends({\n \"data-testid\": `${displayName}Icon`,\n ref: ref\n }, props, {\n children: path\n }));\n }\n if (process.env.NODE_ENV !== 'production') {\n // Need to set `displayName` on the inner component for React.memo.\n // React prior to 16.14 ignores `displayName` on the wrapper.\n Component.displayName = `${displayName}Icon`;\n }\n Component.muiName = SvgIcon.muiName;\n return /*#__PURE__*/React.memo( /*#__PURE__*/React.forwardRef(Component));\n}","'use client';\n\nimport { unstable_ClassNameGenerator as ClassNameGenerator } from '@mui/base/ClassNameGenerator';\nexport { default as capitalize } from './capitalize';\nexport { default as createChainedFunction } from './createChainedFunction';\nexport { default as createSvgIcon } from './createSvgIcon';\nexport { default as debounce } from './debounce';\nexport { default as deprecatedPropType } from './deprecatedPropType';\nexport { default as isMuiElement } from './isMuiElement';\nexport { default as ownerDocument } from './ownerDocument';\nexport { default as ownerWindow } from './ownerWindow';\nexport { default as requirePropFactory } from './requirePropFactory';\nexport { default as setRef } from './setRef';\nexport { default as unstable_useEnhancedEffect } from './useEnhancedEffect';\nexport { default as unstable_useId } from './useId';\nexport { default as unsupportedProp } from './unsupportedProp';\nexport { default as useControlled } from './useControlled';\nexport { default as useEventCallback } from './useEventCallback';\nexport { default as useForkRef } from './useForkRef';\nexport { default as useIsFocusVisible } from './useIsFocusVisible';\n// TODO: remove this export once ClassNameGenerator is stable\n// eslint-disable-next-line @typescript-eslint/naming-convention\nexport const unstable_ClassNameGenerator = {\n configure: generator => {\n if (process.env.NODE_ENV !== 'production') {\n console.warn(['MUI: `ClassNameGenerator` import from `@mui/material/utils` is outdated and might cause unexpected issues.', '', \"You should use `import { unstable_ClassNameGenerator } from '@mui/material/className'` instead\", '', 'The detail of the issue: https://github.com/mui/material-ui/issues/30011#issuecomment-1024993401', '', 'The updated documentation: https://mui.com/guides/classname-generator/'].join('\\n'));\n }\n ClassNameGenerator.configure(generator);\n }\n};","\"use strict\";\n'use client';\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nObject.defineProperty(exports, \"default\", {\n enumerable: true,\n get: function () {\n return _utils.createSvgIcon;\n }\n});\nvar _utils = require(\"@mui/material/utils\");","\"use strict\";\n\"use client\";\n\nvar _interopRequireDefault = require(\"@babel/runtime/helpers/interopRequireDefault\");\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = void 0;\nvar _createSvgIcon = _interopRequireDefault(require(\"./utils/createSvgIcon\"));\nvar _jsxRuntime = require(\"react/jsx-runtime\");\nvar _default = exports.default = (0, _createSvgIcon.default)( /*#__PURE__*/(0, _jsxRuntime.jsx)(\"path\", {\n d: \"m10 17 5-5-5-5z\"\n}), 'ArrowRight');","/**\n * Determines if a given element is a DOM element name (i.e. not a React component).\n */\nexport function isHostComponent(element) {\n return typeof element === 'string';\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport { isHostComponent } from './isHostComponent';\n\n/**\n * Type of the ownerState based on the type of an element it applies to.\n * This resolves to the provided OwnerState for React components and `undefined` for host components.\n * Falls back to `OwnerState | undefined` when the exact type can't be determined in development time.\n */\n\n/**\n * Appends the ownerState object to the props, merging with the existing one if necessary.\n *\n * @param elementType Type of the element that owns the `existingProps`. If the element is a DOM node or undefined, `ownerState` is not applied.\n * @param otherProps Props of the element.\n * @param ownerState\n */\nexport function appendOwnerState(elementType, otherProps, ownerState) {\n if (elementType === undefined || isHostComponent(elementType)) {\n return otherProps;\n }\n return _extends({}, otherProps, {\n ownerState: _extends({}, otherProps.ownerState, ownerState)\n });\n}","'use client';\n\nimport * as React from 'react';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nconst defaultContextValue = {\n disableDefaultClasses: false\n};\nconst ClassNameConfiguratorContext = /*#__PURE__*/React.createContext(defaultContextValue);\n/**\n * @ignore - internal hook.\n *\n * Wraps the `generateUtilityClass` function and controls how the classes are generated.\n * Currently it only affects whether the classes are applied or not.\n *\n * @returns Function to be called with the `generateUtilityClass` function specific to a component to generate the classes.\n */\nexport function useClassNamesOverride(generateUtilityClass) {\n const {\n disableDefaultClasses\n } = React.useContext(ClassNameConfiguratorContext);\n return slot => {\n if (disableDefaultClasses) {\n return '';\n }\n return generateUtilityClass(slot);\n };\n}\n\n/**\n * Allows to configure the components within to not apply any built-in classes.\n */\nexport function ClassNameConfigurator(props) {\n const {\n disableDefaultClasses,\n children\n } = props;\n const contextValue = React.useMemo(() => ({\n disableDefaultClasses: disableDefaultClasses != null ? disableDefaultClasses : false\n }), [disableDefaultClasses]);\n return /*#__PURE__*/_jsx(ClassNameConfiguratorContext.Provider, {\n value: contextValue,\n children: children\n });\n}","/**\n * Extracts event handlers from a given object.\n * A prop is considered an event handler if it is a function and its name starts with `on`.\n *\n * @param object An object to extract event handlers from.\n * @param excludeKeys An array of keys to exclude from the returned object.\n */\nexport function extractEventHandlers(object, excludeKeys = []) {\n if (object === undefined) {\n return {};\n }\n const result = {};\n Object.keys(object).filter(prop => prop.match(/^on[A-Z]/) && typeof object[prop] === 'function' && !excludeKeys.includes(prop)).forEach(prop => {\n result[prop] = object[prop];\n });\n return result;\n}","/**\n * If `componentProps` is a function, calls it with the provided `ownerState`.\n * Otherwise, just returns `componentProps`.\n */\nexport function resolveComponentProps(componentProps, ownerState, slotState) {\n if (typeof componentProps === 'function') {\n return componentProps(ownerState, slotState);\n }\n return componentProps;\n}","/**\n * Removes event handlers from the given object.\n * A field is considered an event handler if it is a function with a name beginning with `on`.\n *\n * @param object Object to remove event handlers from.\n * @returns Object with event handlers removed.\n */\nexport function omitEventHandlers(object) {\n if (object === undefined) {\n return {};\n }\n const result = {};\n Object.keys(object).filter(prop => !(prop.match(/^on[A-Z]/) && typeof object[prop] === 'function')).forEach(prop => {\n result[prop] = object[prop];\n });\n return result;\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport clsx from 'clsx';\nimport { extractEventHandlers } from './extractEventHandlers';\nimport { omitEventHandlers } from './omitEventHandlers';\n/**\n * Merges the slot component internal props (usually coming from a hook)\n * with the externally provided ones.\n *\n * The merge order is (the latter overrides the former):\n * 1. The internal props (specified as a getter function to work with get*Props hook result)\n * 2. Additional props (specified internally on a Base UI component)\n * 3. External props specified on the owner component. These should only be used on a root slot.\n * 4. External props specified in the `slotProps.*` prop.\n * 5. The `className` prop - combined from all the above.\n * @param parameters\n * @returns\n */\nexport function mergeSlotProps(parameters) {\n const {\n getSlotProps,\n additionalProps,\n externalSlotProps,\n externalForwardedProps,\n className\n } = parameters;\n if (!getSlotProps) {\n // The simpler case - getSlotProps is not defined, so no internal event handlers are defined,\n // so we can simply merge all the props without having to worry about extracting event handlers.\n const joinedClasses = clsx(additionalProps == null ? void 0 : additionalProps.className, className, externalForwardedProps == null ? void 0 : externalForwardedProps.className, externalSlotProps == null ? void 0 : externalSlotProps.className);\n const mergedStyle = _extends({}, additionalProps == null ? void 0 : additionalProps.style, externalForwardedProps == null ? void 0 : externalForwardedProps.style, externalSlotProps == null ? void 0 : externalSlotProps.style);\n const props = _extends({}, additionalProps, externalForwardedProps, externalSlotProps);\n if (joinedClasses.length > 0) {\n props.className = joinedClasses;\n }\n if (Object.keys(mergedStyle).length > 0) {\n props.style = mergedStyle;\n }\n return {\n props,\n internalRef: undefined\n };\n }\n\n // In this case, getSlotProps is responsible for calling the external event handlers.\n // We don't need to include them in the merged props because of this.\n\n const eventHandlers = extractEventHandlers(_extends({}, externalForwardedProps, externalSlotProps));\n const componentsPropsWithoutEventHandlers = omitEventHandlers(externalSlotProps);\n const otherPropsWithoutEventHandlers = omitEventHandlers(externalForwardedProps);\n const internalSlotProps = getSlotProps(eventHandlers);\n\n // The order of classes is important here.\n // Emotion (that we use in libraries consuming Base UI) depends on this order\n // to properly override style. It requires the most important classes to be last\n // (see https://github.com/mui/material-ui/pull/33205) for the related discussion.\n const joinedClasses = clsx(internalSlotProps == null ? void 0 : internalSlotProps.className, additionalProps == null ? void 0 : additionalProps.className, className, externalForwardedProps == null ? void 0 : externalForwardedProps.className, externalSlotProps == null ? void 0 : externalSlotProps.className);\n const mergedStyle = _extends({}, internalSlotProps == null ? void 0 : internalSlotProps.style, additionalProps == null ? void 0 : additionalProps.style, externalForwardedProps == null ? void 0 : externalForwardedProps.style, externalSlotProps == null ? void 0 : externalSlotProps.style);\n const props = _extends({}, internalSlotProps, additionalProps, otherPropsWithoutEventHandlers, componentsPropsWithoutEventHandlers);\n if (joinedClasses.length > 0) {\n props.className = joinedClasses;\n }\n if (Object.keys(mergedStyle).length > 0) {\n props.style = mergedStyle;\n }\n return {\n props,\n internalRef: internalSlotProps.ref\n };\n}","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"elementType\", \"externalSlotProps\", \"ownerState\", \"skipResolvingSlotProps\"];\nimport { unstable_useForkRef as useForkRef } from '@mui/utils';\nimport { appendOwnerState } from './appendOwnerState';\nimport { mergeSlotProps } from './mergeSlotProps';\nimport { resolveComponentProps } from './resolveComponentProps';\n/**\n * @ignore - do not document.\n * Builds the props to be passed into the slot of an unstyled component.\n * It merges the internal props of the component with the ones supplied by the user, allowing to customize the behavior.\n * If the slot component is not a host component, it also merges in the `ownerState`.\n *\n * @param parameters.getSlotProps - A function that returns the props to be passed to the slot component.\n */\nexport function useSlotProps(parameters) {\n var _parameters$additiona;\n const {\n elementType,\n externalSlotProps,\n ownerState,\n skipResolvingSlotProps = false\n } = parameters,\n rest = _objectWithoutPropertiesLoose(parameters, _excluded);\n const resolvedComponentsProps = skipResolvingSlotProps ? {} : resolveComponentProps(externalSlotProps, ownerState);\n const {\n props: mergedProps,\n internalRef\n } = mergeSlotProps(_extends({}, rest, {\n externalSlotProps: resolvedComponentsProps\n }));\n const ref = useForkRef(internalRef, resolvedComponentsProps == null ? void 0 : resolvedComponentsProps.ref, (_parameters$additiona = parameters.additionalProps) == null ? void 0 : _parameters$additiona.ref);\n const props = appendOwnerState(elementType, _extends({}, mergedProps, {\n ref\n }), ownerState);\n return props;\n}","import { globalStateClasses } from '@mui/utils/generateUtilityClass';\nconst GLOBAL_CLASS_PREFIX = 'base';\nfunction buildStateClass(state) {\n return `${GLOBAL_CLASS_PREFIX}--${state}`;\n}\nfunction buildSlotClass(componentName, slot) {\n return `${GLOBAL_CLASS_PREFIX}-${componentName}-${slot}`;\n}\nexport function generateUtilityClass(componentName, slot) {\n const globalStateClass = globalStateClasses[slot];\n return globalStateClass ? buildStateClass(globalStateClass) : buildSlotClass(componentName, slot);\n}\nexport function isGlobalState(slot) {\n return globalStateClasses[slot] !== undefined;\n}","import { generateUtilityClass } from '../generateUtilityClass';\nexport function generateUtilityClasses(componentName, slots) {\n const result = {};\n slots.forEach(slot => {\n result[slot] = generateUtilityClass(componentName, slot);\n });\n return result;\n}","'use client';\n\nimport * as React from 'react';\nimport * as ReactDOM from 'react-dom';\nimport PropTypes from 'prop-types';\nimport { exactProp, HTMLElementType, unstable_useEnhancedEffect as useEnhancedEffect, unstable_useForkRef as useForkRef, unstable_setRef as setRef } from '@mui/utils';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nfunction getContainer(container) {\n return typeof container === 'function' ? container() : container;\n}\n\n/**\n * Portals provide a first-class way to render children into a DOM node\n * that exists outside the DOM hierarchy of the parent component.\n *\n * Demos:\n *\n * - [Portal](https://mui.com/base-ui/react-portal/)\n *\n * API:\n *\n * - [Portal API](https://mui.com/base-ui/react-portal/components-api/#portal)\n */\nconst Portal = /*#__PURE__*/React.forwardRef(function Portal(props, forwardedRef) {\n const {\n children,\n container,\n disablePortal = false\n } = props;\n const [mountNode, setMountNode] = React.useState(null);\n // @ts-expect-error TODO upstream fix\n const handleRef = useForkRef( /*#__PURE__*/React.isValidElement(children) ? children.ref : null, forwardedRef);\n useEnhancedEffect(() => {\n if (!disablePortal) {\n setMountNode(getContainer(container) || document.body);\n }\n }, [container, disablePortal]);\n useEnhancedEffect(() => {\n if (mountNode && !disablePortal) {\n setRef(forwardedRef, mountNode);\n return () => {\n setRef(forwardedRef, null);\n };\n }\n return undefined;\n }, [forwardedRef, mountNode, disablePortal]);\n if (disablePortal) {\n if ( /*#__PURE__*/React.isValidElement(children)) {\n const newProps = {\n ref: handleRef\n };\n return /*#__PURE__*/React.cloneElement(children, newProps);\n }\n return /*#__PURE__*/_jsx(React.Fragment, {\n children: children\n });\n }\n return /*#__PURE__*/_jsx(React.Fragment, {\n children: mountNode ? /*#__PURE__*/ReactDOM.createPortal(children, mountNode) : mountNode\n });\n});\nprocess.env.NODE_ENV !== \"production\" ? Portal.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * The children to render into the `container`.\n */\n children: PropTypes.node,\n /**\n * An HTML element or function that returns one.\n * The `container` will have the portal children appended to it.\n *\n * You can also provide a callback, which is called in a React layout effect.\n * This lets you set the container from a ref, and also makes server-side rendering possible.\n *\n * By default, it uses the body of the top-level document object,\n * so it's simply `document.body` most of the time.\n */\n container: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.func]),\n /**\n * The `children` will be under the DOM hierarchy of the parent component.\n * @default false\n */\n disablePortal: PropTypes.bool\n} : void 0;\nif (process.env.NODE_ENV !== 'production') {\n // eslint-disable-next-line\n Portal['propTypes' + ''] = exactProp(Portal.propTypes);\n}\nexport { Portal };","export var top = 'top';\nexport var bottom = 'bottom';\nexport var right = 'right';\nexport var left = 'left';\nexport var auto = 'auto';\nexport var basePlacements = [top, bottom, right, left];\nexport var start = 'start';\nexport var end = 'end';\nexport var clippingParents = 'clippingParents';\nexport var viewport = 'viewport';\nexport var popper = 'popper';\nexport var reference = 'reference';\nexport var variationPlacements = /*#__PURE__*/basePlacements.reduce(function (acc, placement) {\n return acc.concat([placement + \"-\" + start, placement + \"-\" + end]);\n}, []);\nexport var placements = /*#__PURE__*/[].concat(basePlacements, [auto]).reduce(function (acc, placement) {\n return acc.concat([placement, placement + \"-\" + start, placement + \"-\" + end]);\n}, []); // modifiers that need to read the DOM\n\nexport var beforeRead = 'beforeRead';\nexport var read = 'read';\nexport var afterRead = 'afterRead'; // pure-logic modifiers\n\nexport var beforeMain = 'beforeMain';\nexport var main = 'main';\nexport var afterMain = 'afterMain'; // modifier with the purpose to write to the DOM (or write into a framework state)\n\nexport var beforeWrite = 'beforeWrite';\nexport var write = 'write';\nexport var afterWrite = 'afterWrite';\nexport var modifierPhases = [beforeRead, read, afterRead, beforeMain, main, afterMain, beforeWrite, write, afterWrite];","export default function getNodeName(element) {\n return element ? (element.nodeName || '').toLowerCase() : null;\n}","export default function getWindow(node) {\n if (node == null) {\n return window;\n }\n\n if (node.toString() !== '[object Window]') {\n var ownerDocument = node.ownerDocument;\n return ownerDocument ? ownerDocument.defaultView || window : window;\n }\n\n return node;\n}","import getWindow from \"./getWindow.js\";\n\nfunction isElement(node) {\n var OwnElement = getWindow(node).Element;\n return node instanceof OwnElement || node instanceof Element;\n}\n\nfunction isHTMLElement(node) {\n var OwnElement = getWindow(node).HTMLElement;\n return node instanceof OwnElement || node instanceof HTMLElement;\n}\n\nfunction isShadowRoot(node) {\n // IE 11 has no ShadowRoot\n if (typeof ShadowRoot === 'undefined') {\n return false;\n }\n\n var OwnElement = getWindow(node).ShadowRoot;\n return node instanceof OwnElement || node instanceof ShadowRoot;\n}\n\nexport { isElement, isHTMLElement, isShadowRoot };","import getNodeName from \"../dom-utils/getNodeName.js\";\nimport { isHTMLElement } from \"../dom-utils/instanceOf.js\"; // This modifier takes the styles prepared by the `computeStyles` modifier\n// and applies them to the HTMLElements such as popper and arrow\n\nfunction applyStyles(_ref) {\n var state = _ref.state;\n Object.keys(state.elements).forEach(function (name) {\n var style = state.styles[name] || {};\n var attributes = state.attributes[name] || {};\n var element = state.elements[name]; // arrow is optional + virtual elements\n\n if (!isHTMLElement(element) || !getNodeName(element)) {\n return;\n } // Flow doesn't support to extend this property, but it's the most\n // effective way to apply styles to an HTMLElement\n // $FlowFixMe[cannot-write]\n\n\n Object.assign(element.style, style);\n Object.keys(attributes).forEach(function (name) {\n var value = attributes[name];\n\n if (value === false) {\n element.removeAttribute(name);\n } else {\n element.setAttribute(name, value === true ? '' : value);\n }\n });\n });\n}\n\nfunction effect(_ref2) {\n var state = _ref2.state;\n var initialStyles = {\n popper: {\n position: state.options.strategy,\n left: '0',\n top: '0',\n margin: '0'\n },\n arrow: {\n position: 'absolute'\n },\n reference: {}\n };\n Object.assign(state.elements.popper.style, initialStyles.popper);\n state.styles = initialStyles;\n\n if (state.elements.arrow) {\n Object.assign(state.elements.arrow.style, initialStyles.arrow);\n }\n\n return function () {\n Object.keys(state.elements).forEach(function (name) {\n var element = state.elements[name];\n var attributes = state.attributes[name] || {};\n var styleProperties = Object.keys(state.styles.hasOwnProperty(name) ? state.styles[name] : initialStyles[name]); // Set all values to an empty string to unset them\n\n var style = styleProperties.reduce(function (style, property) {\n style[property] = '';\n return style;\n }, {}); // arrow is optional + virtual elements\n\n if (!isHTMLElement(element) || !getNodeName(element)) {\n return;\n }\n\n Object.assign(element.style, style);\n Object.keys(attributes).forEach(function (attribute) {\n element.removeAttribute(attribute);\n });\n });\n };\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'applyStyles',\n enabled: true,\n phase: 'write',\n fn: applyStyles,\n effect: effect,\n requires: ['computeStyles']\n};","import { auto } from \"../enums.js\";\nexport default function getBasePlacement(placement) {\n return placement.split('-')[0];\n}","export var max = Math.max;\nexport var min = Math.min;\nexport var round = Math.round;","export default function getUAString() {\n var uaData = navigator.userAgentData;\n\n if (uaData != null && uaData.brands && Array.isArray(uaData.brands)) {\n return uaData.brands.map(function (item) {\n return item.brand + \"/\" + item.version;\n }).join(' ');\n }\n\n return navigator.userAgent;\n}","import getUAString from \"../utils/userAgent.js\";\nexport default function isLayoutViewport() {\n return !/^((?!chrome|android).)*safari/i.test(getUAString());\n}","import { isElement, isHTMLElement } from \"./instanceOf.js\";\nimport { round } from \"../utils/math.js\";\nimport getWindow from \"./getWindow.js\";\nimport isLayoutViewport from \"./isLayoutViewport.js\";\nexport default function getBoundingClientRect(element, includeScale, isFixedStrategy) {\n if (includeScale === void 0) {\n includeScale = false;\n }\n\n if (isFixedStrategy === void 0) {\n isFixedStrategy = false;\n }\n\n var clientRect = element.getBoundingClientRect();\n var scaleX = 1;\n var scaleY = 1;\n\n if (includeScale && isHTMLElement(element)) {\n scaleX = element.offsetWidth > 0 ? round(clientRect.width) / element.offsetWidth || 1 : 1;\n scaleY = element.offsetHeight > 0 ? round(clientRect.height) / element.offsetHeight || 1 : 1;\n }\n\n var _ref = isElement(element) ? getWindow(element) : window,\n visualViewport = _ref.visualViewport;\n\n var addVisualOffsets = !isLayoutViewport() && isFixedStrategy;\n var x = (clientRect.left + (addVisualOffsets && visualViewport ? visualViewport.offsetLeft : 0)) / scaleX;\n var y = (clientRect.top + (addVisualOffsets && visualViewport ? visualViewport.offsetTop : 0)) / scaleY;\n var width = clientRect.width / scaleX;\n var height = clientRect.height / scaleY;\n return {\n width: width,\n height: height,\n top: y,\n right: x + width,\n bottom: y + height,\n left: x,\n x: x,\n y: y\n };\n}","import getBoundingClientRect from \"./getBoundingClientRect.js\"; // Returns the layout rect of an element relative to its offsetParent. Layout\n// means it doesn't take into account transforms.\n\nexport default function getLayoutRect(element) {\n var clientRect = getBoundingClientRect(element); // Use the clientRect sizes if it's not been transformed.\n // Fixes https://github.com/popperjs/popper-core/issues/1223\n\n var width = element.offsetWidth;\n var height = element.offsetHeight;\n\n if (Math.abs(clientRect.width - width) <= 1) {\n width = clientRect.width;\n }\n\n if (Math.abs(clientRect.height - height) <= 1) {\n height = clientRect.height;\n }\n\n return {\n x: element.offsetLeft,\n y: element.offsetTop,\n width: width,\n height: height\n };\n}","import { isShadowRoot } from \"./instanceOf.js\";\nexport default function contains(parent, child) {\n var rootNode = child.getRootNode && child.getRootNode(); // First, attempt with faster native method\n\n if (parent.contains(child)) {\n return true;\n } // then fallback to custom implementation with Shadow DOM support\n else if (rootNode && isShadowRoot(rootNode)) {\n var next = child;\n\n do {\n if (next && parent.isSameNode(next)) {\n return true;\n } // $FlowFixMe[prop-missing]: need a better way to handle this...\n\n\n next = next.parentNode || next.host;\n } while (next);\n } // Give up, the result is false\n\n\n return false;\n}","import getWindow from \"./getWindow.js\";\nexport default function getComputedStyle(element) {\n return getWindow(element).getComputedStyle(element);\n}","import getNodeName from \"./getNodeName.js\";\nexport default function isTableElement(element) {\n return ['table', 'td', 'th'].indexOf(getNodeName(element)) >= 0;\n}","import { isElement } from \"./instanceOf.js\";\nexport default function getDocumentElement(element) {\n // $FlowFixMe[incompatible-return]: assume body is always available\n return ((isElement(element) ? element.ownerDocument : // $FlowFixMe[prop-missing]\n element.document) || window.document).documentElement;\n}","import getNodeName from \"./getNodeName.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport { isShadowRoot } from \"./instanceOf.js\";\nexport default function getParentNode(element) {\n if (getNodeName(element) === 'html') {\n return element;\n }\n\n return (// this is a quicker (but less type safe) way to save quite some bytes from the bundle\n // $FlowFixMe[incompatible-return]\n // $FlowFixMe[prop-missing]\n element.assignedSlot || // step into the shadow DOM of the parent of a slotted node\n element.parentNode || ( // DOM Element detected\n isShadowRoot(element) ? element.host : null) || // ShadowRoot detected\n // $FlowFixMe[incompatible-call]: HTMLElement is a Node\n getDocumentElement(element) // fallback\n\n );\n}","import getWindow from \"./getWindow.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport getComputedStyle from \"./getComputedStyle.js\";\nimport { isHTMLElement, isShadowRoot } from \"./instanceOf.js\";\nimport isTableElement from \"./isTableElement.js\";\nimport getParentNode from \"./getParentNode.js\";\nimport getUAString from \"../utils/userAgent.js\";\n\nfunction getTrueOffsetParent(element) {\n if (!isHTMLElement(element) || // https://github.com/popperjs/popper-core/issues/837\n getComputedStyle(element).position === 'fixed') {\n return null;\n }\n\n return element.offsetParent;\n} // `.offsetParent` reports `null` for fixed elements, while absolute elements\n// return the containing block\n\n\nfunction getContainingBlock(element) {\n var isFirefox = /firefox/i.test(getUAString());\n var isIE = /Trident/i.test(getUAString());\n\n if (isIE && isHTMLElement(element)) {\n // In IE 9, 10 and 11 fixed elements containing block is always established by the viewport\n var elementCss = getComputedStyle(element);\n\n if (elementCss.position === 'fixed') {\n return null;\n }\n }\n\n var currentNode = getParentNode(element);\n\n if (isShadowRoot(currentNode)) {\n currentNode = currentNode.host;\n }\n\n while (isHTMLElement(currentNode) && ['html', 'body'].indexOf(getNodeName(currentNode)) < 0) {\n var css = getComputedStyle(currentNode); // This is non-exhaustive but covers the most common CSS properties that\n // create a containing block.\n // https://developer.mozilla.org/en-US/docs/Web/CSS/Containing_block#identifying_the_containing_block\n\n if (css.transform !== 'none' || css.perspective !== 'none' || css.contain === 'paint' || ['transform', 'perspective'].indexOf(css.willChange) !== -1 || isFirefox && css.willChange === 'filter' || isFirefox && css.filter && css.filter !== 'none') {\n return currentNode;\n } else {\n currentNode = currentNode.parentNode;\n }\n }\n\n return null;\n} // Gets the closest ancestor positioned element. Handles some edge cases,\n// such as table ancestors and cross browser bugs.\n\n\nexport default function getOffsetParent(element) {\n var window = getWindow(element);\n var offsetParent = getTrueOffsetParent(element);\n\n while (offsetParent && isTableElement(offsetParent) && getComputedStyle(offsetParent).position === 'static') {\n offsetParent = getTrueOffsetParent(offsetParent);\n }\n\n if (offsetParent && (getNodeName(offsetParent) === 'html' || getNodeName(offsetParent) === 'body' && getComputedStyle(offsetParent).position === 'static')) {\n return window;\n }\n\n return offsetParent || getContainingBlock(element) || window;\n}","export default function getMainAxisFromPlacement(placement) {\n return ['top', 'bottom'].indexOf(placement) >= 0 ? 'x' : 'y';\n}","import { max as mathMax, min as mathMin } from \"./math.js\";\nexport function within(min, value, max) {\n return mathMax(min, mathMin(value, max));\n}\nexport function withinMaxClamp(min, value, max) {\n var v = within(min, value, max);\n return v > max ? max : v;\n}","export default function getFreshSideObject() {\n return {\n top: 0,\n right: 0,\n bottom: 0,\n left: 0\n };\n}","import getFreshSideObject from \"./getFreshSideObject.js\";\nexport default function mergePaddingObject(paddingObject) {\n return Object.assign({}, getFreshSideObject(), paddingObject);\n}","export default function expandToHashMap(value, keys) {\n return keys.reduce(function (hashMap, key) {\n hashMap[key] = value;\n return hashMap;\n }, {});\n}","import getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getLayoutRect from \"../dom-utils/getLayoutRect.js\";\nimport contains from \"../dom-utils/contains.js\";\nimport getOffsetParent from \"../dom-utils/getOffsetParent.js\";\nimport getMainAxisFromPlacement from \"../utils/getMainAxisFromPlacement.js\";\nimport { within } from \"../utils/within.js\";\nimport mergePaddingObject from \"../utils/mergePaddingObject.js\";\nimport expandToHashMap from \"../utils/expandToHashMap.js\";\nimport { left, right, basePlacements, top, bottom } from \"../enums.js\"; // eslint-disable-next-line import/no-unused-modules\n\nvar toPaddingObject = function toPaddingObject(padding, state) {\n padding = typeof padding === 'function' ? padding(Object.assign({}, state.rects, {\n placement: state.placement\n })) : padding;\n return mergePaddingObject(typeof padding !== 'number' ? padding : expandToHashMap(padding, basePlacements));\n};\n\nfunction arrow(_ref) {\n var _state$modifiersData$;\n\n var state = _ref.state,\n name = _ref.name,\n options = _ref.options;\n var arrowElement = state.elements.arrow;\n var popperOffsets = state.modifiersData.popperOffsets;\n var basePlacement = getBasePlacement(state.placement);\n var axis = getMainAxisFromPlacement(basePlacement);\n var isVertical = [left, right].indexOf(basePlacement) >= 0;\n var len = isVertical ? 'height' : 'width';\n\n if (!arrowElement || !popperOffsets) {\n return;\n }\n\n var paddingObject = toPaddingObject(options.padding, state);\n var arrowRect = getLayoutRect(arrowElement);\n var minProp = axis === 'y' ? top : left;\n var maxProp = axis === 'y' ? bottom : right;\n var endDiff = state.rects.reference[len] + state.rects.reference[axis] - popperOffsets[axis] - state.rects.popper[len];\n var startDiff = popperOffsets[axis] - state.rects.reference[axis];\n var arrowOffsetParent = getOffsetParent(arrowElement);\n var clientSize = arrowOffsetParent ? axis === 'y' ? arrowOffsetParent.clientHeight || 0 : arrowOffsetParent.clientWidth || 0 : 0;\n var centerToReference = endDiff / 2 - startDiff / 2; // Make sure the arrow doesn't overflow the popper if the center point is\n // outside of the popper bounds\n\n var min = paddingObject[minProp];\n var max = clientSize - arrowRect[len] - paddingObject[maxProp];\n var center = clientSize / 2 - arrowRect[len] / 2 + centerToReference;\n var offset = within(min, center, max); // Prevents breaking syntax highlighting...\n\n var axisProp = axis;\n state.modifiersData[name] = (_state$modifiersData$ = {}, _state$modifiersData$[axisProp] = offset, _state$modifiersData$.centerOffset = offset - center, _state$modifiersData$);\n}\n\nfunction effect(_ref2) {\n var state = _ref2.state,\n options = _ref2.options;\n var _options$element = options.element,\n arrowElement = _options$element === void 0 ? '[data-popper-arrow]' : _options$element;\n\n if (arrowElement == null) {\n return;\n } // CSS selector\n\n\n if (typeof arrowElement === 'string') {\n arrowElement = state.elements.popper.querySelector(arrowElement);\n\n if (!arrowElement) {\n return;\n }\n }\n\n if (!contains(state.elements.popper, arrowElement)) {\n return;\n }\n\n state.elements.arrow = arrowElement;\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'arrow',\n enabled: true,\n phase: 'main',\n fn: arrow,\n effect: effect,\n requires: ['popperOffsets'],\n requiresIfExists: ['preventOverflow']\n};","export default function getVariation(placement) {\n return placement.split('-')[1];\n}","import { top, left, right, bottom, end } from \"../enums.js\";\nimport getOffsetParent from \"../dom-utils/getOffsetParent.js\";\nimport getWindow from \"../dom-utils/getWindow.js\";\nimport getDocumentElement from \"../dom-utils/getDocumentElement.js\";\nimport getComputedStyle from \"../dom-utils/getComputedStyle.js\";\nimport getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getVariation from \"../utils/getVariation.js\";\nimport { round } from \"../utils/math.js\"; // eslint-disable-next-line import/no-unused-modules\n\nvar unsetSides = {\n top: 'auto',\n right: 'auto',\n bottom: 'auto',\n left: 'auto'\n}; // Round the offsets to the nearest suitable subpixel based on the DPR.\n// Zooming can change the DPR, but it seems to report a value that will\n// cleanly divide the values into the appropriate subpixels.\n\nfunction roundOffsetsByDPR(_ref, win) {\n var x = _ref.x,\n y = _ref.y;\n var dpr = win.devicePixelRatio || 1;\n return {\n x: round(x * dpr) / dpr || 0,\n y: round(y * dpr) / dpr || 0\n };\n}\n\nexport function mapToStyles(_ref2) {\n var _Object$assign2;\n\n var popper = _ref2.popper,\n popperRect = _ref2.popperRect,\n placement = _ref2.placement,\n variation = _ref2.variation,\n offsets = _ref2.offsets,\n position = _ref2.position,\n gpuAcceleration = _ref2.gpuAcceleration,\n adaptive = _ref2.adaptive,\n roundOffsets = _ref2.roundOffsets,\n isFixed = _ref2.isFixed;\n var _offsets$x = offsets.x,\n x = _offsets$x === void 0 ? 0 : _offsets$x,\n _offsets$y = offsets.y,\n y = _offsets$y === void 0 ? 0 : _offsets$y;\n\n var _ref3 = typeof roundOffsets === 'function' ? roundOffsets({\n x: x,\n y: y\n }) : {\n x: x,\n y: y\n };\n\n x = _ref3.x;\n y = _ref3.y;\n var hasX = offsets.hasOwnProperty('x');\n var hasY = offsets.hasOwnProperty('y');\n var sideX = left;\n var sideY = top;\n var win = window;\n\n if (adaptive) {\n var offsetParent = getOffsetParent(popper);\n var heightProp = 'clientHeight';\n var widthProp = 'clientWidth';\n\n if (offsetParent === getWindow(popper)) {\n offsetParent = getDocumentElement(popper);\n\n if (getComputedStyle(offsetParent).position !== 'static' && position === 'absolute') {\n heightProp = 'scrollHeight';\n widthProp = 'scrollWidth';\n }\n } // $FlowFixMe[incompatible-cast]: force type refinement, we compare offsetParent with window above, but Flow doesn't detect it\n\n\n offsetParent = offsetParent;\n\n if (placement === top || (placement === left || placement === right) && variation === end) {\n sideY = bottom;\n var offsetY = isFixed && offsetParent === win && win.visualViewport ? win.visualViewport.height : // $FlowFixMe[prop-missing]\n offsetParent[heightProp];\n y -= offsetY - popperRect.height;\n y *= gpuAcceleration ? 1 : -1;\n }\n\n if (placement === left || (placement === top || placement === bottom) && variation === end) {\n sideX = right;\n var offsetX = isFixed && offsetParent === win && win.visualViewport ? win.visualViewport.width : // $FlowFixMe[prop-missing]\n offsetParent[widthProp];\n x -= offsetX - popperRect.width;\n x *= gpuAcceleration ? 1 : -1;\n }\n }\n\n var commonStyles = Object.assign({\n position: position\n }, adaptive && unsetSides);\n\n var _ref4 = roundOffsets === true ? roundOffsetsByDPR({\n x: x,\n y: y\n }, getWindow(popper)) : {\n x: x,\n y: y\n };\n\n x = _ref4.x;\n y = _ref4.y;\n\n if (gpuAcceleration) {\n var _Object$assign;\n\n return Object.assign({}, commonStyles, (_Object$assign = {}, _Object$assign[sideY] = hasY ? '0' : '', _Object$assign[sideX] = hasX ? '0' : '', _Object$assign.transform = (win.devicePixelRatio || 1) <= 1 ? \"translate(\" + x + \"px, \" + y + \"px)\" : \"translate3d(\" + x + \"px, \" + y + \"px, 0)\", _Object$assign));\n }\n\n return Object.assign({}, commonStyles, (_Object$assign2 = {}, _Object$assign2[sideY] = hasY ? y + \"px\" : '', _Object$assign2[sideX] = hasX ? x + \"px\" : '', _Object$assign2.transform = '', _Object$assign2));\n}\n\nfunction computeStyles(_ref5) {\n var state = _ref5.state,\n options = _ref5.options;\n var _options$gpuAccelerat = options.gpuAcceleration,\n gpuAcceleration = _options$gpuAccelerat === void 0 ? true : _options$gpuAccelerat,\n _options$adaptive = options.adaptive,\n adaptive = _options$adaptive === void 0 ? true : _options$adaptive,\n _options$roundOffsets = options.roundOffsets,\n roundOffsets = _options$roundOffsets === void 0 ? true : _options$roundOffsets;\n var commonStyles = {\n placement: getBasePlacement(state.placement),\n variation: getVariation(state.placement),\n popper: state.elements.popper,\n popperRect: state.rects.popper,\n gpuAcceleration: gpuAcceleration,\n isFixed: state.options.strategy === 'fixed'\n };\n\n if (state.modifiersData.popperOffsets != null) {\n state.styles.popper = Object.assign({}, state.styles.popper, mapToStyles(Object.assign({}, commonStyles, {\n offsets: state.modifiersData.popperOffsets,\n position: state.options.strategy,\n adaptive: adaptive,\n roundOffsets: roundOffsets\n })));\n }\n\n if (state.modifiersData.arrow != null) {\n state.styles.arrow = Object.assign({}, state.styles.arrow, mapToStyles(Object.assign({}, commonStyles, {\n offsets: state.modifiersData.arrow,\n position: 'absolute',\n adaptive: false,\n roundOffsets: roundOffsets\n })));\n }\n\n state.attributes.popper = Object.assign({}, state.attributes.popper, {\n 'data-popper-placement': state.placement\n });\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'computeStyles',\n enabled: true,\n phase: 'beforeWrite',\n fn: computeStyles,\n data: {}\n};","import getWindow from \"../dom-utils/getWindow.js\"; // eslint-disable-next-line import/no-unused-modules\n\nvar passive = {\n passive: true\n};\n\nfunction effect(_ref) {\n var state = _ref.state,\n instance = _ref.instance,\n options = _ref.options;\n var _options$scroll = options.scroll,\n scroll = _options$scroll === void 0 ? true : _options$scroll,\n _options$resize = options.resize,\n resize = _options$resize === void 0 ? true : _options$resize;\n var window = getWindow(state.elements.popper);\n var scrollParents = [].concat(state.scrollParents.reference, state.scrollParents.popper);\n\n if (scroll) {\n scrollParents.forEach(function (scrollParent) {\n scrollParent.addEventListener('scroll', instance.update, passive);\n });\n }\n\n if (resize) {\n window.addEventListener('resize', instance.update, passive);\n }\n\n return function () {\n if (scroll) {\n scrollParents.forEach(function (scrollParent) {\n scrollParent.removeEventListener('scroll', instance.update, passive);\n });\n }\n\n if (resize) {\n window.removeEventListener('resize', instance.update, passive);\n }\n };\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'eventListeners',\n enabled: true,\n phase: 'write',\n fn: function fn() {},\n effect: effect,\n data: {}\n};","var hash = {\n left: 'right',\n right: 'left',\n bottom: 'top',\n top: 'bottom'\n};\nexport default function getOppositePlacement(placement) {\n return placement.replace(/left|right|bottom|top/g, function (matched) {\n return hash[matched];\n });\n}","var hash = {\n start: 'end',\n end: 'start'\n};\nexport default function getOppositeVariationPlacement(placement) {\n return placement.replace(/start|end/g, function (matched) {\n return hash[matched];\n });\n}","import getWindow from \"./getWindow.js\";\nexport default function getWindowScroll(node) {\n var win = getWindow(node);\n var scrollLeft = win.pageXOffset;\n var scrollTop = win.pageYOffset;\n return {\n scrollLeft: scrollLeft,\n scrollTop: scrollTop\n };\n}","import getBoundingClientRect from \"./getBoundingClientRect.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport getWindowScroll from \"./getWindowScroll.js\";\nexport default function getWindowScrollBarX(element) {\n // If has a CSS width greater than the viewport, then this will be\n // incorrect for RTL.\n // Popper 1 is broken in this case and never had a bug report so let's assume\n // it's not an issue. I don't think anyone ever specifies width on \n // anyway.\n // Browsers where the left scrollbar doesn't cause an issue report `0` for\n // this (e.g. Edge 2019, IE11, Safari)\n return getBoundingClientRect(getDocumentElement(element)).left + getWindowScroll(element).scrollLeft;\n}","import getWindow from \"./getWindow.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport getWindowScrollBarX from \"./getWindowScrollBarX.js\";\nimport isLayoutViewport from \"./isLayoutViewport.js\";\nexport default function getViewportRect(element, strategy) {\n var win = getWindow(element);\n var html = getDocumentElement(element);\n var visualViewport = win.visualViewport;\n var width = html.clientWidth;\n var height = html.clientHeight;\n var x = 0;\n var y = 0;\n\n if (visualViewport) {\n width = visualViewport.width;\n height = visualViewport.height;\n var layoutViewport = isLayoutViewport();\n\n if (layoutViewport || !layoutViewport && strategy === 'fixed') {\n x = visualViewport.offsetLeft;\n y = visualViewport.offsetTop;\n }\n }\n\n return {\n width: width,\n height: height,\n x: x + getWindowScrollBarX(element),\n y: y\n };\n}","import getDocumentElement from \"./getDocumentElement.js\";\nimport getComputedStyle from \"./getComputedStyle.js\";\nimport getWindowScrollBarX from \"./getWindowScrollBarX.js\";\nimport getWindowScroll from \"./getWindowScroll.js\";\nimport { max } from \"../utils/math.js\"; // Gets the entire size of the scrollable document area, even extending outside\n// of the `` and `` rect bounds if horizontally scrollable\n\nexport default function getDocumentRect(element) {\n var _element$ownerDocumen;\n\n var html = getDocumentElement(element);\n var winScroll = getWindowScroll(element);\n var body = (_element$ownerDocumen = element.ownerDocument) == null ? void 0 : _element$ownerDocumen.body;\n var width = max(html.scrollWidth, html.clientWidth, body ? body.scrollWidth : 0, body ? body.clientWidth : 0);\n var height = max(html.scrollHeight, html.clientHeight, body ? body.scrollHeight : 0, body ? body.clientHeight : 0);\n var x = -winScroll.scrollLeft + getWindowScrollBarX(element);\n var y = -winScroll.scrollTop;\n\n if (getComputedStyle(body || html).direction === 'rtl') {\n x += max(html.clientWidth, body ? body.clientWidth : 0) - width;\n }\n\n return {\n width: width,\n height: height,\n x: x,\n y: y\n };\n}","import getComputedStyle from \"./getComputedStyle.js\";\nexport default function isScrollParent(element) {\n // Firefox wants us to check `-x` and `-y` variations as well\n var _getComputedStyle = getComputedStyle(element),\n overflow = _getComputedStyle.overflow,\n overflowX = _getComputedStyle.overflowX,\n overflowY = _getComputedStyle.overflowY;\n\n return /auto|scroll|overlay|hidden/.test(overflow + overflowY + overflowX);\n}","import getParentNode from \"./getParentNode.js\";\nimport isScrollParent from \"./isScrollParent.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport { isHTMLElement } from \"./instanceOf.js\";\nexport default function getScrollParent(node) {\n if (['html', 'body', '#document'].indexOf(getNodeName(node)) >= 0) {\n // $FlowFixMe[incompatible-return]: assume body is always available\n return node.ownerDocument.body;\n }\n\n if (isHTMLElement(node) && isScrollParent(node)) {\n return node;\n }\n\n return getScrollParent(getParentNode(node));\n}","import getScrollParent from \"./getScrollParent.js\";\nimport getParentNode from \"./getParentNode.js\";\nimport getWindow from \"./getWindow.js\";\nimport isScrollParent from \"./isScrollParent.js\";\n/*\ngiven a DOM element, return the list of all scroll parents, up the list of ancesors\nuntil we get to the top window object. This list is what we attach scroll listeners\nto, because if any of these parent elements scroll, we'll need to re-calculate the\nreference element's position.\n*/\n\nexport default function listScrollParents(element, list) {\n var _element$ownerDocumen;\n\n if (list === void 0) {\n list = [];\n }\n\n var scrollParent = getScrollParent(element);\n var isBody = scrollParent === ((_element$ownerDocumen = element.ownerDocument) == null ? void 0 : _element$ownerDocumen.body);\n var win = getWindow(scrollParent);\n var target = isBody ? [win].concat(win.visualViewport || [], isScrollParent(scrollParent) ? scrollParent : []) : scrollParent;\n var updatedList = list.concat(target);\n return isBody ? updatedList : // $FlowFixMe[incompatible-call]: isBody tells us target will be an HTMLElement here\n updatedList.concat(listScrollParents(getParentNode(target)));\n}","export default function rectToClientRect(rect) {\n return Object.assign({}, rect, {\n left: rect.x,\n top: rect.y,\n right: rect.x + rect.width,\n bottom: rect.y + rect.height\n });\n}","import { viewport } from \"../enums.js\";\nimport getViewportRect from \"./getViewportRect.js\";\nimport getDocumentRect from \"./getDocumentRect.js\";\nimport listScrollParents from \"./listScrollParents.js\";\nimport getOffsetParent from \"./getOffsetParent.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport getComputedStyle from \"./getComputedStyle.js\";\nimport { isElement, isHTMLElement } from \"./instanceOf.js\";\nimport getBoundingClientRect from \"./getBoundingClientRect.js\";\nimport getParentNode from \"./getParentNode.js\";\nimport contains from \"./contains.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport rectToClientRect from \"../utils/rectToClientRect.js\";\nimport { max, min } from \"../utils/math.js\";\n\nfunction getInnerBoundingClientRect(element, strategy) {\n var rect = getBoundingClientRect(element, false, strategy === 'fixed');\n rect.top = rect.top + element.clientTop;\n rect.left = rect.left + element.clientLeft;\n rect.bottom = rect.top + element.clientHeight;\n rect.right = rect.left + element.clientWidth;\n rect.width = element.clientWidth;\n rect.height = element.clientHeight;\n rect.x = rect.left;\n rect.y = rect.top;\n return rect;\n}\n\nfunction getClientRectFromMixedType(element, clippingParent, strategy) {\n return clippingParent === viewport ? rectToClientRect(getViewportRect(element, strategy)) : isElement(clippingParent) ? getInnerBoundingClientRect(clippingParent, strategy) : rectToClientRect(getDocumentRect(getDocumentElement(element)));\n} // A \"clipping parent\" is an overflowable container with the characteristic of\n// clipping (or hiding) overflowing elements with a position different from\n// `initial`\n\n\nfunction getClippingParents(element) {\n var clippingParents = listScrollParents(getParentNode(element));\n var canEscapeClipping = ['absolute', 'fixed'].indexOf(getComputedStyle(element).position) >= 0;\n var clipperElement = canEscapeClipping && isHTMLElement(element) ? getOffsetParent(element) : element;\n\n if (!isElement(clipperElement)) {\n return [];\n } // $FlowFixMe[incompatible-return]: https://github.com/facebook/flow/issues/1414\n\n\n return clippingParents.filter(function (clippingParent) {\n return isElement(clippingParent) && contains(clippingParent, clipperElement) && getNodeName(clippingParent) !== 'body';\n });\n} // Gets the maximum area that the element is visible in due to any number of\n// clipping parents\n\n\nexport default function getClippingRect(element, boundary, rootBoundary, strategy) {\n var mainClippingParents = boundary === 'clippingParents' ? getClippingParents(element) : [].concat(boundary);\n var clippingParents = [].concat(mainClippingParents, [rootBoundary]);\n var firstClippingParent = clippingParents[0];\n var clippingRect = clippingParents.reduce(function (accRect, clippingParent) {\n var rect = getClientRectFromMixedType(element, clippingParent, strategy);\n accRect.top = max(rect.top, accRect.top);\n accRect.right = min(rect.right, accRect.right);\n accRect.bottom = min(rect.bottom, accRect.bottom);\n accRect.left = max(rect.left, accRect.left);\n return accRect;\n }, getClientRectFromMixedType(element, firstClippingParent, strategy));\n clippingRect.width = clippingRect.right - clippingRect.left;\n clippingRect.height = clippingRect.bottom - clippingRect.top;\n clippingRect.x = clippingRect.left;\n clippingRect.y = clippingRect.top;\n return clippingRect;\n}","import getBasePlacement from \"./getBasePlacement.js\";\nimport getVariation from \"./getVariation.js\";\nimport getMainAxisFromPlacement from \"./getMainAxisFromPlacement.js\";\nimport { top, right, bottom, left, start, end } from \"../enums.js\";\nexport default function computeOffsets(_ref) {\n var reference = _ref.reference,\n element = _ref.element,\n placement = _ref.placement;\n var basePlacement = placement ? getBasePlacement(placement) : null;\n var variation = placement ? getVariation(placement) : null;\n var commonX = reference.x + reference.width / 2 - element.width / 2;\n var commonY = reference.y + reference.height / 2 - element.height / 2;\n var offsets;\n\n switch (basePlacement) {\n case top:\n offsets = {\n x: commonX,\n y: reference.y - element.height\n };\n break;\n\n case bottom:\n offsets = {\n x: commonX,\n y: reference.y + reference.height\n };\n break;\n\n case right:\n offsets = {\n x: reference.x + reference.width,\n y: commonY\n };\n break;\n\n case left:\n offsets = {\n x: reference.x - element.width,\n y: commonY\n };\n break;\n\n default:\n offsets = {\n x: reference.x,\n y: reference.y\n };\n }\n\n var mainAxis = basePlacement ? getMainAxisFromPlacement(basePlacement) : null;\n\n if (mainAxis != null) {\n var len = mainAxis === 'y' ? 'height' : 'width';\n\n switch (variation) {\n case start:\n offsets[mainAxis] = offsets[mainAxis] - (reference[len] / 2 - element[len] / 2);\n break;\n\n case end:\n offsets[mainAxis] = offsets[mainAxis] + (reference[len] / 2 - element[len] / 2);\n break;\n\n default:\n }\n }\n\n return offsets;\n}","import getClippingRect from \"../dom-utils/getClippingRect.js\";\nimport getDocumentElement from \"../dom-utils/getDocumentElement.js\";\nimport getBoundingClientRect from \"../dom-utils/getBoundingClientRect.js\";\nimport computeOffsets from \"./computeOffsets.js\";\nimport rectToClientRect from \"./rectToClientRect.js\";\nimport { clippingParents, reference, popper, bottom, top, right, basePlacements, viewport } from \"../enums.js\";\nimport { isElement } from \"../dom-utils/instanceOf.js\";\nimport mergePaddingObject from \"./mergePaddingObject.js\";\nimport expandToHashMap from \"./expandToHashMap.js\"; // eslint-disable-next-line import/no-unused-modules\n\nexport default function detectOverflow(state, options) {\n if (options === void 0) {\n options = {};\n }\n\n var _options = options,\n _options$placement = _options.placement,\n placement = _options$placement === void 0 ? state.placement : _options$placement,\n _options$strategy = _options.strategy,\n strategy = _options$strategy === void 0 ? state.strategy : _options$strategy,\n _options$boundary = _options.boundary,\n boundary = _options$boundary === void 0 ? clippingParents : _options$boundary,\n _options$rootBoundary = _options.rootBoundary,\n rootBoundary = _options$rootBoundary === void 0 ? viewport : _options$rootBoundary,\n _options$elementConte = _options.elementContext,\n elementContext = _options$elementConte === void 0 ? popper : _options$elementConte,\n _options$altBoundary = _options.altBoundary,\n altBoundary = _options$altBoundary === void 0 ? false : _options$altBoundary,\n _options$padding = _options.padding,\n padding = _options$padding === void 0 ? 0 : _options$padding;\n var paddingObject = mergePaddingObject(typeof padding !== 'number' ? padding : expandToHashMap(padding, basePlacements));\n var altContext = elementContext === popper ? reference : popper;\n var popperRect = state.rects.popper;\n var element = state.elements[altBoundary ? altContext : elementContext];\n var clippingClientRect = getClippingRect(isElement(element) ? element : element.contextElement || getDocumentElement(state.elements.popper), boundary, rootBoundary, strategy);\n var referenceClientRect = getBoundingClientRect(state.elements.reference);\n var popperOffsets = computeOffsets({\n reference: referenceClientRect,\n element: popperRect,\n strategy: 'absolute',\n placement: placement\n });\n var popperClientRect = rectToClientRect(Object.assign({}, popperRect, popperOffsets));\n var elementClientRect = elementContext === popper ? popperClientRect : referenceClientRect; // positive = overflowing the clipping rect\n // 0 or negative = within the clipping rect\n\n var overflowOffsets = {\n top: clippingClientRect.top - elementClientRect.top + paddingObject.top,\n bottom: elementClientRect.bottom - clippingClientRect.bottom + paddingObject.bottom,\n left: clippingClientRect.left - elementClientRect.left + paddingObject.left,\n right: elementClientRect.right - clippingClientRect.right + paddingObject.right\n };\n var offsetData = state.modifiersData.offset; // Offsets can be applied only to the popper element\n\n if (elementContext === popper && offsetData) {\n var offset = offsetData[placement];\n Object.keys(overflowOffsets).forEach(function (key) {\n var multiply = [right, bottom].indexOf(key) >= 0 ? 1 : -1;\n var axis = [top, bottom].indexOf(key) >= 0 ? 'y' : 'x';\n overflowOffsets[key] += offset[axis] * multiply;\n });\n }\n\n return overflowOffsets;\n}","import getVariation from \"./getVariation.js\";\nimport { variationPlacements, basePlacements, placements as allPlacements } from \"../enums.js\";\nimport detectOverflow from \"./detectOverflow.js\";\nimport getBasePlacement from \"./getBasePlacement.js\";\nexport default function computeAutoPlacement(state, options) {\n if (options === void 0) {\n options = {};\n }\n\n var _options = options,\n placement = _options.placement,\n boundary = _options.boundary,\n rootBoundary = _options.rootBoundary,\n padding = _options.padding,\n flipVariations = _options.flipVariations,\n _options$allowedAutoP = _options.allowedAutoPlacements,\n allowedAutoPlacements = _options$allowedAutoP === void 0 ? allPlacements : _options$allowedAutoP;\n var variation = getVariation(placement);\n var placements = variation ? flipVariations ? variationPlacements : variationPlacements.filter(function (placement) {\n return getVariation(placement) === variation;\n }) : basePlacements;\n var allowedPlacements = placements.filter(function (placement) {\n return allowedAutoPlacements.indexOf(placement) >= 0;\n });\n\n if (allowedPlacements.length === 0) {\n allowedPlacements = placements;\n } // $FlowFixMe[incompatible-type]: Flow seems to have problems with two array unions...\n\n\n var overflows = allowedPlacements.reduce(function (acc, placement) {\n acc[placement] = detectOverflow(state, {\n placement: placement,\n boundary: boundary,\n rootBoundary: rootBoundary,\n padding: padding\n })[getBasePlacement(placement)];\n return acc;\n }, {});\n return Object.keys(overflows).sort(function (a, b) {\n return overflows[a] - overflows[b];\n });\n}","import getOppositePlacement from \"../utils/getOppositePlacement.js\";\nimport getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getOppositeVariationPlacement from \"../utils/getOppositeVariationPlacement.js\";\nimport detectOverflow from \"../utils/detectOverflow.js\";\nimport computeAutoPlacement from \"../utils/computeAutoPlacement.js\";\nimport { bottom, top, start, right, left, auto } from \"../enums.js\";\nimport getVariation from \"../utils/getVariation.js\"; // eslint-disable-next-line import/no-unused-modules\n\nfunction getExpandedFallbackPlacements(placement) {\n if (getBasePlacement(placement) === auto) {\n return [];\n }\n\n var oppositePlacement = getOppositePlacement(placement);\n return [getOppositeVariationPlacement(placement), oppositePlacement, getOppositeVariationPlacement(oppositePlacement)];\n}\n\nfunction flip(_ref) {\n var state = _ref.state,\n options = _ref.options,\n name = _ref.name;\n\n if (state.modifiersData[name]._skip) {\n return;\n }\n\n var _options$mainAxis = options.mainAxis,\n checkMainAxis = _options$mainAxis === void 0 ? true : _options$mainAxis,\n _options$altAxis = options.altAxis,\n checkAltAxis = _options$altAxis === void 0 ? true : _options$altAxis,\n specifiedFallbackPlacements = options.fallbackPlacements,\n padding = options.padding,\n boundary = options.boundary,\n rootBoundary = options.rootBoundary,\n altBoundary = options.altBoundary,\n _options$flipVariatio = options.flipVariations,\n flipVariations = _options$flipVariatio === void 0 ? true : _options$flipVariatio,\n allowedAutoPlacements = options.allowedAutoPlacements;\n var preferredPlacement = state.options.placement;\n var basePlacement = getBasePlacement(preferredPlacement);\n var isBasePlacement = basePlacement === preferredPlacement;\n var fallbackPlacements = specifiedFallbackPlacements || (isBasePlacement || !flipVariations ? [getOppositePlacement(preferredPlacement)] : getExpandedFallbackPlacements(preferredPlacement));\n var placements = [preferredPlacement].concat(fallbackPlacements).reduce(function (acc, placement) {\n return acc.concat(getBasePlacement(placement) === auto ? computeAutoPlacement(state, {\n placement: placement,\n boundary: boundary,\n rootBoundary: rootBoundary,\n padding: padding,\n flipVariations: flipVariations,\n allowedAutoPlacements: allowedAutoPlacements\n }) : placement);\n }, []);\n var referenceRect = state.rects.reference;\n var popperRect = state.rects.popper;\n var checksMap = new Map();\n var makeFallbackChecks = true;\n var firstFittingPlacement = placements[0];\n\n for (var i = 0; i < placements.length; i++) {\n var placement = placements[i];\n\n var _basePlacement = getBasePlacement(placement);\n\n var isStartVariation = getVariation(placement) === start;\n var isVertical = [top, bottom].indexOf(_basePlacement) >= 0;\n var len = isVertical ? 'width' : 'height';\n var overflow = detectOverflow(state, {\n placement: placement,\n boundary: boundary,\n rootBoundary: rootBoundary,\n altBoundary: altBoundary,\n padding: padding\n });\n var mainVariationSide = isVertical ? isStartVariation ? right : left : isStartVariation ? bottom : top;\n\n if (referenceRect[len] > popperRect[len]) {\n mainVariationSide = getOppositePlacement(mainVariationSide);\n }\n\n var altVariationSide = getOppositePlacement(mainVariationSide);\n var checks = [];\n\n if (checkMainAxis) {\n checks.push(overflow[_basePlacement] <= 0);\n }\n\n if (checkAltAxis) {\n checks.push(overflow[mainVariationSide] <= 0, overflow[altVariationSide] <= 0);\n }\n\n if (checks.every(function (check) {\n return check;\n })) {\n firstFittingPlacement = placement;\n makeFallbackChecks = false;\n break;\n }\n\n checksMap.set(placement, checks);\n }\n\n if (makeFallbackChecks) {\n // `2` may be desired in some cases – research later\n var numberOfChecks = flipVariations ? 3 : 1;\n\n var _loop = function _loop(_i) {\n var fittingPlacement = placements.find(function (placement) {\n var checks = checksMap.get(placement);\n\n if (checks) {\n return checks.slice(0, _i).every(function (check) {\n return check;\n });\n }\n });\n\n if (fittingPlacement) {\n firstFittingPlacement = fittingPlacement;\n return \"break\";\n }\n };\n\n for (var _i = numberOfChecks; _i > 0; _i--) {\n var _ret = _loop(_i);\n\n if (_ret === \"break\") break;\n }\n }\n\n if (state.placement !== firstFittingPlacement) {\n state.modifiersData[name]._skip = true;\n state.placement = firstFittingPlacement;\n state.reset = true;\n }\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'flip',\n enabled: true,\n phase: 'main',\n fn: flip,\n requiresIfExists: ['offset'],\n data: {\n _skip: false\n }\n};","import { top, bottom, left, right } from \"../enums.js\";\nimport detectOverflow from \"../utils/detectOverflow.js\";\n\nfunction getSideOffsets(overflow, rect, preventedOffsets) {\n if (preventedOffsets === void 0) {\n preventedOffsets = {\n x: 0,\n y: 0\n };\n }\n\n return {\n top: overflow.top - rect.height - preventedOffsets.y,\n right: overflow.right - rect.width + preventedOffsets.x,\n bottom: overflow.bottom - rect.height + preventedOffsets.y,\n left: overflow.left - rect.width - preventedOffsets.x\n };\n}\n\nfunction isAnySideFullyClipped(overflow) {\n return [top, right, bottom, left].some(function (side) {\n return overflow[side] >= 0;\n });\n}\n\nfunction hide(_ref) {\n var state = _ref.state,\n name = _ref.name;\n var referenceRect = state.rects.reference;\n var popperRect = state.rects.popper;\n var preventedOffsets = state.modifiersData.preventOverflow;\n var referenceOverflow = detectOverflow(state, {\n elementContext: 'reference'\n });\n var popperAltOverflow = detectOverflow(state, {\n altBoundary: true\n });\n var referenceClippingOffsets = getSideOffsets(referenceOverflow, referenceRect);\n var popperEscapeOffsets = getSideOffsets(popperAltOverflow, popperRect, preventedOffsets);\n var isReferenceHidden = isAnySideFullyClipped(referenceClippingOffsets);\n var hasPopperEscaped = isAnySideFullyClipped(popperEscapeOffsets);\n state.modifiersData[name] = {\n referenceClippingOffsets: referenceClippingOffsets,\n popperEscapeOffsets: popperEscapeOffsets,\n isReferenceHidden: isReferenceHidden,\n hasPopperEscaped: hasPopperEscaped\n };\n state.attributes.popper = Object.assign({}, state.attributes.popper, {\n 'data-popper-reference-hidden': isReferenceHidden,\n 'data-popper-escaped': hasPopperEscaped\n });\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'hide',\n enabled: true,\n phase: 'main',\n requiresIfExists: ['preventOverflow'],\n fn: hide\n};","import getBasePlacement from \"../utils/getBasePlacement.js\";\nimport { top, left, right, placements } from \"../enums.js\"; // eslint-disable-next-line import/no-unused-modules\n\nexport function distanceAndSkiddingToXY(placement, rects, offset) {\n var basePlacement = getBasePlacement(placement);\n var invertDistance = [left, top].indexOf(basePlacement) >= 0 ? -1 : 1;\n\n var _ref = typeof offset === 'function' ? offset(Object.assign({}, rects, {\n placement: placement\n })) : offset,\n skidding = _ref[0],\n distance = _ref[1];\n\n skidding = skidding || 0;\n distance = (distance || 0) * invertDistance;\n return [left, right].indexOf(basePlacement) >= 0 ? {\n x: distance,\n y: skidding\n } : {\n x: skidding,\n y: distance\n };\n}\n\nfunction offset(_ref2) {\n var state = _ref2.state,\n options = _ref2.options,\n name = _ref2.name;\n var _options$offset = options.offset,\n offset = _options$offset === void 0 ? [0, 0] : _options$offset;\n var data = placements.reduce(function (acc, placement) {\n acc[placement] = distanceAndSkiddingToXY(placement, state.rects, offset);\n return acc;\n }, {});\n var _data$state$placement = data[state.placement],\n x = _data$state$placement.x,\n y = _data$state$placement.y;\n\n if (state.modifiersData.popperOffsets != null) {\n state.modifiersData.popperOffsets.x += x;\n state.modifiersData.popperOffsets.y += y;\n }\n\n state.modifiersData[name] = data;\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'offset',\n enabled: true,\n phase: 'main',\n requires: ['popperOffsets'],\n fn: offset\n};","import computeOffsets from \"../utils/computeOffsets.js\";\n\nfunction popperOffsets(_ref) {\n var state = _ref.state,\n name = _ref.name;\n // Offsets are the actual position the popper needs to have to be\n // properly positioned near its reference element\n // This is the most basic placement, and will be adjusted by\n // the modifiers in the next step\n state.modifiersData[name] = computeOffsets({\n reference: state.rects.reference,\n element: state.rects.popper,\n strategy: 'absolute',\n placement: state.placement\n });\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'popperOffsets',\n enabled: true,\n phase: 'read',\n fn: popperOffsets,\n data: {}\n};","export default function getAltAxis(axis) {\n return axis === 'x' ? 'y' : 'x';\n}","import { top, left, right, bottom, start } from \"../enums.js\";\nimport getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getMainAxisFromPlacement from \"../utils/getMainAxisFromPlacement.js\";\nimport getAltAxis from \"../utils/getAltAxis.js\";\nimport { within, withinMaxClamp } from \"../utils/within.js\";\nimport getLayoutRect from \"../dom-utils/getLayoutRect.js\";\nimport getOffsetParent from \"../dom-utils/getOffsetParent.js\";\nimport detectOverflow from \"../utils/detectOverflow.js\";\nimport getVariation from \"../utils/getVariation.js\";\nimport getFreshSideObject from \"../utils/getFreshSideObject.js\";\nimport { min as mathMin, max as mathMax } from \"../utils/math.js\";\n\nfunction preventOverflow(_ref) {\n var state = _ref.state,\n options = _ref.options,\n name = _ref.name;\n var _options$mainAxis = options.mainAxis,\n checkMainAxis = _options$mainAxis === void 0 ? true : _options$mainAxis,\n _options$altAxis = options.altAxis,\n checkAltAxis = _options$altAxis === void 0 ? false : _options$altAxis,\n boundary = options.boundary,\n rootBoundary = options.rootBoundary,\n altBoundary = options.altBoundary,\n padding = options.padding,\n _options$tether = options.tether,\n tether = _options$tether === void 0 ? true : _options$tether,\n _options$tetherOffset = options.tetherOffset,\n tetherOffset = _options$tetherOffset === void 0 ? 0 : _options$tetherOffset;\n var overflow = detectOverflow(state, {\n boundary: boundary,\n rootBoundary: rootBoundary,\n padding: padding,\n altBoundary: altBoundary\n });\n var basePlacement = getBasePlacement(state.placement);\n var variation = getVariation(state.placement);\n var isBasePlacement = !variation;\n var mainAxis = getMainAxisFromPlacement(basePlacement);\n var altAxis = getAltAxis(mainAxis);\n var popperOffsets = state.modifiersData.popperOffsets;\n var referenceRect = state.rects.reference;\n var popperRect = state.rects.popper;\n var tetherOffsetValue = typeof tetherOffset === 'function' ? tetherOffset(Object.assign({}, state.rects, {\n placement: state.placement\n })) : tetherOffset;\n var normalizedTetherOffsetValue = typeof tetherOffsetValue === 'number' ? {\n mainAxis: tetherOffsetValue,\n altAxis: tetherOffsetValue\n } : Object.assign({\n mainAxis: 0,\n altAxis: 0\n }, tetherOffsetValue);\n var offsetModifierState = state.modifiersData.offset ? state.modifiersData.offset[state.placement] : null;\n var data = {\n x: 0,\n y: 0\n };\n\n if (!popperOffsets) {\n return;\n }\n\n if (checkMainAxis) {\n var _offsetModifierState$;\n\n var mainSide = mainAxis === 'y' ? top : left;\n var altSide = mainAxis === 'y' ? bottom : right;\n var len = mainAxis === 'y' ? 'height' : 'width';\n var offset = popperOffsets[mainAxis];\n var min = offset + overflow[mainSide];\n var max = offset - overflow[altSide];\n var additive = tether ? -popperRect[len] / 2 : 0;\n var minLen = variation === start ? referenceRect[len] : popperRect[len];\n var maxLen = variation === start ? -popperRect[len] : -referenceRect[len]; // We need to include the arrow in the calculation so the arrow doesn't go\n // outside the reference bounds\n\n var arrowElement = state.elements.arrow;\n var arrowRect = tether && arrowElement ? getLayoutRect(arrowElement) : {\n width: 0,\n height: 0\n };\n var arrowPaddingObject = state.modifiersData['arrow#persistent'] ? state.modifiersData['arrow#persistent'].padding : getFreshSideObject();\n var arrowPaddingMin = arrowPaddingObject[mainSide];\n var arrowPaddingMax = arrowPaddingObject[altSide]; // If the reference length is smaller than the arrow length, we don't want\n // to include its full size in the calculation. If the reference is small\n // and near the edge of a boundary, the popper can overflow even if the\n // reference is not overflowing as well (e.g. virtual elements with no\n // width or height)\n\n var arrowLen = within(0, referenceRect[len], arrowRect[len]);\n var minOffset = isBasePlacement ? referenceRect[len] / 2 - additive - arrowLen - arrowPaddingMin - normalizedTetherOffsetValue.mainAxis : minLen - arrowLen - arrowPaddingMin - normalizedTetherOffsetValue.mainAxis;\n var maxOffset = isBasePlacement ? -referenceRect[len] / 2 + additive + arrowLen + arrowPaddingMax + normalizedTetherOffsetValue.mainAxis : maxLen + arrowLen + arrowPaddingMax + normalizedTetherOffsetValue.mainAxis;\n var arrowOffsetParent = state.elements.arrow && getOffsetParent(state.elements.arrow);\n var clientOffset = arrowOffsetParent ? mainAxis === 'y' ? arrowOffsetParent.clientTop || 0 : arrowOffsetParent.clientLeft || 0 : 0;\n var offsetModifierValue = (_offsetModifierState$ = offsetModifierState == null ? void 0 : offsetModifierState[mainAxis]) != null ? _offsetModifierState$ : 0;\n var tetherMin = offset + minOffset - offsetModifierValue - clientOffset;\n var tetherMax = offset + maxOffset - offsetModifierValue;\n var preventedOffset = within(tether ? mathMin(min, tetherMin) : min, offset, tether ? mathMax(max, tetherMax) : max);\n popperOffsets[mainAxis] = preventedOffset;\n data[mainAxis] = preventedOffset - offset;\n }\n\n if (checkAltAxis) {\n var _offsetModifierState$2;\n\n var _mainSide = mainAxis === 'x' ? top : left;\n\n var _altSide = mainAxis === 'x' ? bottom : right;\n\n var _offset = popperOffsets[altAxis];\n\n var _len = altAxis === 'y' ? 'height' : 'width';\n\n var _min = _offset + overflow[_mainSide];\n\n var _max = _offset - overflow[_altSide];\n\n var isOriginSide = [top, left].indexOf(basePlacement) !== -1;\n\n var _offsetModifierValue = (_offsetModifierState$2 = offsetModifierState == null ? void 0 : offsetModifierState[altAxis]) != null ? _offsetModifierState$2 : 0;\n\n var _tetherMin = isOriginSide ? _min : _offset - referenceRect[_len] - popperRect[_len] - _offsetModifierValue + normalizedTetherOffsetValue.altAxis;\n\n var _tetherMax = isOriginSide ? _offset + referenceRect[_len] + popperRect[_len] - _offsetModifierValue - normalizedTetherOffsetValue.altAxis : _max;\n\n var _preventedOffset = tether && isOriginSide ? withinMaxClamp(_tetherMin, _offset, _tetherMax) : within(tether ? _tetherMin : _min, _offset, tether ? _tetherMax : _max);\n\n popperOffsets[altAxis] = _preventedOffset;\n data[altAxis] = _preventedOffset - _offset;\n }\n\n state.modifiersData[name] = data;\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'preventOverflow',\n enabled: true,\n phase: 'main',\n fn: preventOverflow,\n requiresIfExists: ['offset']\n};","export default function getHTMLElementScroll(element) {\n return {\n scrollLeft: element.scrollLeft,\n scrollTop: element.scrollTop\n };\n}","import getWindowScroll from \"./getWindowScroll.js\";\nimport getWindow from \"./getWindow.js\";\nimport { isHTMLElement } from \"./instanceOf.js\";\nimport getHTMLElementScroll from \"./getHTMLElementScroll.js\";\nexport default function getNodeScroll(node) {\n if (node === getWindow(node) || !isHTMLElement(node)) {\n return getWindowScroll(node);\n } else {\n return getHTMLElementScroll(node);\n }\n}","import getBoundingClientRect from \"./getBoundingClientRect.js\";\nimport getNodeScroll from \"./getNodeScroll.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport { isHTMLElement } from \"./instanceOf.js\";\nimport getWindowScrollBarX from \"./getWindowScrollBarX.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport isScrollParent from \"./isScrollParent.js\";\nimport { round } from \"../utils/math.js\";\n\nfunction isElementScaled(element) {\n var rect = element.getBoundingClientRect();\n var scaleX = round(rect.width) / element.offsetWidth || 1;\n var scaleY = round(rect.height) / element.offsetHeight || 1;\n return scaleX !== 1 || scaleY !== 1;\n} // Returns the composite rect of an element relative to its offsetParent.\n// Composite means it takes into account transforms as well as layout.\n\n\nexport default function getCompositeRect(elementOrVirtualElement, offsetParent, isFixed) {\n if (isFixed === void 0) {\n isFixed = false;\n }\n\n var isOffsetParentAnElement = isHTMLElement(offsetParent);\n var offsetParentIsScaled = isHTMLElement(offsetParent) && isElementScaled(offsetParent);\n var documentElement = getDocumentElement(offsetParent);\n var rect = getBoundingClientRect(elementOrVirtualElement, offsetParentIsScaled, isFixed);\n var scroll = {\n scrollLeft: 0,\n scrollTop: 0\n };\n var offsets = {\n x: 0,\n y: 0\n };\n\n if (isOffsetParentAnElement || !isOffsetParentAnElement && !isFixed) {\n if (getNodeName(offsetParent) !== 'body' || // https://github.com/popperjs/popper-core/issues/1078\n isScrollParent(documentElement)) {\n scroll = getNodeScroll(offsetParent);\n }\n\n if (isHTMLElement(offsetParent)) {\n offsets = getBoundingClientRect(offsetParent, true);\n offsets.x += offsetParent.clientLeft;\n offsets.y += offsetParent.clientTop;\n } else if (documentElement) {\n offsets.x = getWindowScrollBarX(documentElement);\n }\n }\n\n return {\n x: rect.left + scroll.scrollLeft - offsets.x,\n y: rect.top + scroll.scrollTop - offsets.y,\n width: rect.width,\n height: rect.height\n };\n}","import { modifierPhases } from \"../enums.js\"; // source: https://stackoverflow.com/questions/49875255\n\nfunction order(modifiers) {\n var map = new Map();\n var visited = new Set();\n var result = [];\n modifiers.forEach(function (modifier) {\n map.set(modifier.name, modifier);\n }); // On visiting object, check for its dependencies and visit them recursively\n\n function sort(modifier) {\n visited.add(modifier.name);\n var requires = [].concat(modifier.requires || [], modifier.requiresIfExists || []);\n requires.forEach(function (dep) {\n if (!visited.has(dep)) {\n var depModifier = map.get(dep);\n\n if (depModifier) {\n sort(depModifier);\n }\n }\n });\n result.push(modifier);\n }\n\n modifiers.forEach(function (modifier) {\n if (!visited.has(modifier.name)) {\n // check for visited object\n sort(modifier);\n }\n });\n return result;\n}\n\nexport default function orderModifiers(modifiers) {\n // order based on dependencies\n var orderedModifiers = order(modifiers); // order based on phase\n\n return modifierPhases.reduce(function (acc, phase) {\n return acc.concat(orderedModifiers.filter(function (modifier) {\n return modifier.phase === phase;\n }));\n }, []);\n}","export default function debounce(fn) {\n var pending;\n return function () {\n if (!pending) {\n pending = new Promise(function (resolve) {\n Promise.resolve().then(function () {\n pending = undefined;\n resolve(fn());\n });\n });\n }\n\n return pending;\n };\n}","export default function mergeByName(modifiers) {\n var merged = modifiers.reduce(function (merged, current) {\n var existing = merged[current.name];\n merged[current.name] = existing ? Object.assign({}, existing, current, {\n options: Object.assign({}, existing.options, current.options),\n data: Object.assign({}, existing.data, current.data)\n }) : current;\n return merged;\n }, {}); // IE11 does not support Object.values\n\n return Object.keys(merged).map(function (key) {\n return merged[key];\n });\n}","import getCompositeRect from \"./dom-utils/getCompositeRect.js\";\nimport getLayoutRect from \"./dom-utils/getLayoutRect.js\";\nimport listScrollParents from \"./dom-utils/listScrollParents.js\";\nimport getOffsetParent from \"./dom-utils/getOffsetParent.js\";\nimport orderModifiers from \"./utils/orderModifiers.js\";\nimport debounce from \"./utils/debounce.js\";\nimport mergeByName from \"./utils/mergeByName.js\";\nimport detectOverflow from \"./utils/detectOverflow.js\";\nimport { isElement } from \"./dom-utils/instanceOf.js\";\nvar DEFAULT_OPTIONS = {\n placement: 'bottom',\n modifiers: [],\n strategy: 'absolute'\n};\n\nfunction areValidElements() {\n for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {\n args[_key] = arguments[_key];\n }\n\n return !args.some(function (element) {\n return !(element && typeof element.getBoundingClientRect === 'function');\n });\n}\n\nexport function popperGenerator(generatorOptions) {\n if (generatorOptions === void 0) {\n generatorOptions = {};\n }\n\n var _generatorOptions = generatorOptions,\n _generatorOptions$def = _generatorOptions.defaultModifiers,\n defaultModifiers = _generatorOptions$def === void 0 ? [] : _generatorOptions$def,\n _generatorOptions$def2 = _generatorOptions.defaultOptions,\n defaultOptions = _generatorOptions$def2 === void 0 ? DEFAULT_OPTIONS : _generatorOptions$def2;\n return function createPopper(reference, popper, options) {\n if (options === void 0) {\n options = defaultOptions;\n }\n\n var state = {\n placement: 'bottom',\n orderedModifiers: [],\n options: Object.assign({}, DEFAULT_OPTIONS, defaultOptions),\n modifiersData: {},\n elements: {\n reference: reference,\n popper: popper\n },\n attributes: {},\n styles: {}\n };\n var effectCleanupFns = [];\n var isDestroyed = false;\n var instance = {\n state: state,\n setOptions: function setOptions(setOptionsAction) {\n var options = typeof setOptionsAction === 'function' ? setOptionsAction(state.options) : setOptionsAction;\n cleanupModifierEffects();\n state.options = Object.assign({}, defaultOptions, state.options, options);\n state.scrollParents = {\n reference: isElement(reference) ? listScrollParents(reference) : reference.contextElement ? listScrollParents(reference.contextElement) : [],\n popper: listScrollParents(popper)\n }; // Orders the modifiers based on their dependencies and `phase`\n // properties\n\n var orderedModifiers = orderModifiers(mergeByName([].concat(defaultModifiers, state.options.modifiers))); // Strip out disabled modifiers\n\n state.orderedModifiers = orderedModifiers.filter(function (m) {\n return m.enabled;\n });\n runModifierEffects();\n return instance.update();\n },\n // Sync update – it will always be executed, even if not necessary. This\n // is useful for low frequency updates where sync behavior simplifies the\n // logic.\n // For high frequency updates (e.g. `resize` and `scroll` events), always\n // prefer the async Popper#update method\n forceUpdate: function forceUpdate() {\n if (isDestroyed) {\n return;\n }\n\n var _state$elements = state.elements,\n reference = _state$elements.reference,\n popper = _state$elements.popper; // Don't proceed if `reference` or `popper` are not valid elements\n // anymore\n\n if (!areValidElements(reference, popper)) {\n return;\n } // Store the reference and popper rects to be read by modifiers\n\n\n state.rects = {\n reference: getCompositeRect(reference, getOffsetParent(popper), state.options.strategy === 'fixed'),\n popper: getLayoutRect(popper)\n }; // Modifiers have the ability to reset the current update cycle. The\n // most common use case for this is the `flip` modifier changing the\n // placement, which then needs to re-run all the modifiers, because the\n // logic was previously ran for the previous placement and is therefore\n // stale/incorrect\n\n state.reset = false;\n state.placement = state.options.placement; // On each update cycle, the `modifiersData` property for each modifier\n // is filled with the initial data specified by the modifier. This means\n // it doesn't persist and is fresh on each update.\n // To ensure persistent data, use `${name}#persistent`\n\n state.orderedModifiers.forEach(function (modifier) {\n return state.modifiersData[modifier.name] = Object.assign({}, modifier.data);\n });\n\n for (var index = 0; index < state.orderedModifiers.length; index++) {\n if (state.reset === true) {\n state.reset = false;\n index = -1;\n continue;\n }\n\n var _state$orderedModifie = state.orderedModifiers[index],\n fn = _state$orderedModifie.fn,\n _state$orderedModifie2 = _state$orderedModifie.options,\n _options = _state$orderedModifie2 === void 0 ? {} : _state$orderedModifie2,\n name = _state$orderedModifie.name;\n\n if (typeof fn === 'function') {\n state = fn({\n state: state,\n options: _options,\n name: name,\n instance: instance\n }) || state;\n }\n }\n },\n // Async and optimistically optimized update – it will not be executed if\n // not necessary (debounced to run at most once-per-tick)\n update: debounce(function () {\n return new Promise(function (resolve) {\n instance.forceUpdate();\n resolve(state);\n });\n }),\n destroy: function destroy() {\n cleanupModifierEffects();\n isDestroyed = true;\n }\n };\n\n if (!areValidElements(reference, popper)) {\n return instance;\n }\n\n instance.setOptions(options).then(function (state) {\n if (!isDestroyed && options.onFirstUpdate) {\n options.onFirstUpdate(state);\n }\n }); // Modifiers have the ability to execute arbitrary code before the first\n // update cycle runs. They will be executed in the same order as the update\n // cycle. This is useful when a modifier adds some persistent data that\n // other modifiers need to use, but the modifier is run after the dependent\n // one.\n\n function runModifierEffects() {\n state.orderedModifiers.forEach(function (_ref) {\n var name = _ref.name,\n _ref$options = _ref.options,\n options = _ref$options === void 0 ? {} : _ref$options,\n effect = _ref.effect;\n\n if (typeof effect === 'function') {\n var cleanupFn = effect({\n state: state,\n name: name,\n instance: instance,\n options: options\n });\n\n var noopFn = function noopFn() {};\n\n effectCleanupFns.push(cleanupFn || noopFn);\n }\n });\n }\n\n function cleanupModifierEffects() {\n effectCleanupFns.forEach(function (fn) {\n return fn();\n });\n effectCleanupFns = [];\n }\n\n return instance;\n };\n}\nexport var createPopper = /*#__PURE__*/popperGenerator(); // eslint-disable-next-line import/no-unused-modules\n\nexport { detectOverflow };","import { popperGenerator, detectOverflow } from \"./createPopper.js\";\nimport eventListeners from \"./modifiers/eventListeners.js\";\nimport popperOffsets from \"./modifiers/popperOffsets.js\";\nimport computeStyles from \"./modifiers/computeStyles.js\";\nimport applyStyles from \"./modifiers/applyStyles.js\";\nimport offset from \"./modifiers/offset.js\";\nimport flip from \"./modifiers/flip.js\";\nimport preventOverflow from \"./modifiers/preventOverflow.js\";\nimport arrow from \"./modifiers/arrow.js\";\nimport hide from \"./modifiers/hide.js\";\nvar defaultModifiers = [eventListeners, popperOffsets, computeStyles, applyStyles, offset, flip, preventOverflow, arrow, hide];\nvar createPopper = /*#__PURE__*/popperGenerator({\n defaultModifiers: defaultModifiers\n}); // eslint-disable-next-line import/no-unused-modules\n\nexport { createPopper, popperGenerator, defaultModifiers, detectOverflow }; // eslint-disable-next-line import/no-unused-modules\n\nexport { createPopper as createPopperLite } from \"./popper-lite.js\"; // eslint-disable-next-line import/no-unused-modules\n\nexport * from \"./modifiers/index.js\";","import { generateUtilityClass } from '../generateUtilityClass';\nimport { generateUtilityClasses } from '../generateUtilityClasses';\nconst COMPONENT_NAME = 'Popper';\nexport function getPopperUtilityClass(slot) {\n return generateUtilityClass(COMPONENT_NAME, slot);\n}\nexport const popperClasses = generateUtilityClasses(COMPONENT_NAME, ['root']);","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"anchorEl\", \"children\", \"direction\", \"disablePortal\", \"modifiers\", \"open\", \"placement\", \"popperOptions\", \"popperRef\", \"slotProps\", \"slots\", \"TransitionProps\", \"ownerState\"],\n _excluded2 = [\"anchorEl\", \"children\", \"container\", \"direction\", \"disablePortal\", \"keepMounted\", \"modifiers\", \"open\", \"placement\", \"popperOptions\", \"popperRef\", \"style\", \"transition\", \"slotProps\", \"slots\"];\nimport * as React from 'react';\nimport { chainPropTypes, HTMLElementType, refType, unstable_ownerDocument as ownerDocument, unstable_useEnhancedEffect as useEnhancedEffect, unstable_useForkRef as useForkRef } from '@mui/utils';\nimport { createPopper } from '@popperjs/core';\nimport PropTypes from 'prop-types';\nimport { unstable_composeClasses as composeClasses } from '../composeClasses';\nimport { Portal } from '../Portal';\nimport { getPopperUtilityClass } from './popperClasses';\nimport { useSlotProps } from '../utils';\nimport { useClassNamesOverride } from '../utils/ClassNameConfigurator';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nfunction flipPlacement(placement, direction) {\n if (direction === 'ltr') {\n return placement;\n }\n switch (placement) {\n case 'bottom-end':\n return 'bottom-start';\n case 'bottom-start':\n return 'bottom-end';\n case 'top-end':\n return 'top-start';\n case 'top-start':\n return 'top-end';\n default:\n return placement;\n }\n}\nfunction resolveAnchorEl(anchorEl) {\n return typeof anchorEl === 'function' ? anchorEl() : anchorEl;\n}\nfunction isHTMLElement(element) {\n return element.nodeType !== undefined;\n}\nfunction isVirtualElement(element) {\n return !isHTMLElement(element);\n}\nconst useUtilityClasses = () => {\n const slots = {\n root: ['root']\n };\n return composeClasses(slots, useClassNamesOverride(getPopperUtilityClass));\n};\nconst defaultPopperOptions = {};\nconst PopperTooltip = /*#__PURE__*/React.forwardRef(function PopperTooltip(props, forwardedRef) {\n var _slots$root;\n const {\n anchorEl,\n children,\n direction,\n disablePortal,\n modifiers,\n open,\n placement: initialPlacement,\n popperOptions,\n popperRef: popperRefProp,\n slotProps = {},\n slots = {},\n TransitionProps\n // @ts-ignore internal logic\n // prevent from spreading to DOM, it can come from the parent component e.g. Select.\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const tooltipRef = React.useRef(null);\n const ownRef = useForkRef(tooltipRef, forwardedRef);\n const popperRef = React.useRef(null);\n const handlePopperRef = useForkRef(popperRef, popperRefProp);\n const handlePopperRefRef = React.useRef(handlePopperRef);\n useEnhancedEffect(() => {\n handlePopperRefRef.current = handlePopperRef;\n }, [handlePopperRef]);\n React.useImperativeHandle(popperRefProp, () => popperRef.current, []);\n const rtlPlacement = flipPlacement(initialPlacement, direction);\n /**\n * placement initialized from prop but can change during lifetime if modifiers.flip.\n * modifiers.flip is essentially a flip for controlled/uncontrolled behavior\n */\n const [placement, setPlacement] = React.useState(rtlPlacement);\n const [resolvedAnchorElement, setResolvedAnchorElement] = React.useState(resolveAnchorEl(anchorEl));\n React.useEffect(() => {\n if (popperRef.current) {\n popperRef.current.forceUpdate();\n }\n });\n React.useEffect(() => {\n if (anchorEl) {\n setResolvedAnchorElement(resolveAnchorEl(anchorEl));\n }\n }, [anchorEl]);\n useEnhancedEffect(() => {\n if (!resolvedAnchorElement || !open) {\n return undefined;\n }\n const handlePopperUpdate = data => {\n setPlacement(data.placement);\n };\n if (process.env.NODE_ENV !== 'production') {\n if (resolvedAnchorElement && isHTMLElement(resolvedAnchorElement) && resolvedAnchorElement.nodeType === 1) {\n const box = resolvedAnchorElement.getBoundingClientRect();\n if (process.env.NODE_ENV !== 'test' && box.top === 0 && box.left === 0 && box.right === 0 && box.bottom === 0) {\n console.warn(['MUI: The `anchorEl` prop provided to the component is invalid.', 'The anchor element should be part of the document layout.', \"Make sure the element is present in the document or that it's not display none.\"].join('\\n'));\n }\n }\n }\n let popperModifiers = [{\n name: 'preventOverflow',\n options: {\n altBoundary: disablePortal\n }\n }, {\n name: 'flip',\n options: {\n altBoundary: disablePortal\n }\n }, {\n name: 'onUpdate',\n enabled: true,\n phase: 'afterWrite',\n fn: ({\n state\n }) => {\n handlePopperUpdate(state);\n }\n }];\n if (modifiers != null) {\n popperModifiers = popperModifiers.concat(modifiers);\n }\n if (popperOptions && popperOptions.modifiers != null) {\n popperModifiers = popperModifiers.concat(popperOptions.modifiers);\n }\n const popper = createPopper(resolvedAnchorElement, tooltipRef.current, _extends({\n placement: rtlPlacement\n }, popperOptions, {\n modifiers: popperModifiers\n }));\n handlePopperRefRef.current(popper);\n return () => {\n popper.destroy();\n handlePopperRefRef.current(null);\n };\n }, [resolvedAnchorElement, disablePortal, modifiers, open, popperOptions, rtlPlacement]);\n const childProps = {\n placement: placement\n };\n if (TransitionProps !== null) {\n childProps.TransitionProps = TransitionProps;\n }\n const classes = useUtilityClasses();\n const Root = (_slots$root = slots.root) != null ? _slots$root : 'div';\n const rootProps = useSlotProps({\n elementType: Root,\n externalSlotProps: slotProps.root,\n externalForwardedProps: other,\n additionalProps: {\n role: 'tooltip',\n ref: ownRef\n },\n ownerState: props,\n className: classes.root\n });\n return /*#__PURE__*/_jsx(Root, _extends({}, rootProps, {\n children: typeof children === 'function' ? children(childProps) : children\n }));\n});\n\n/**\n * Poppers rely on the 3rd party library [Popper.js](https://popper.js.org/docs/v2/) for positioning.\n *\n * Demos:\n *\n * - [Popper](https://mui.com/base-ui/react-popper/)\n *\n * API:\n *\n * - [Popper API](https://mui.com/base-ui/react-popper/components-api/#popper)\n */\nconst Popper = /*#__PURE__*/React.forwardRef(function Popper(props, forwardedRef) {\n const {\n anchorEl,\n children,\n container: containerProp,\n direction = 'ltr',\n disablePortal = false,\n keepMounted = false,\n modifiers,\n open,\n placement = 'bottom',\n popperOptions = defaultPopperOptions,\n popperRef,\n style,\n transition = false,\n slotProps = {},\n slots = {}\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded2);\n const [exited, setExited] = React.useState(true);\n const handleEnter = () => {\n setExited(false);\n };\n const handleExited = () => {\n setExited(true);\n };\n if (!keepMounted && !open && (!transition || exited)) {\n return null;\n }\n\n // If the container prop is provided, use that\n // If the anchorEl prop is provided, use its parent body element as the container\n // If neither are provided let the Modal take care of choosing the container\n let container;\n if (containerProp) {\n container = containerProp;\n } else if (anchorEl) {\n const resolvedAnchorEl = resolveAnchorEl(anchorEl);\n container = resolvedAnchorEl && isHTMLElement(resolvedAnchorEl) ? ownerDocument(resolvedAnchorEl).body : ownerDocument(null).body;\n }\n const display = !open && keepMounted && (!transition || exited) ? 'none' : undefined;\n const transitionProps = transition ? {\n in: open,\n onEnter: handleEnter,\n onExited: handleExited\n } : undefined;\n return /*#__PURE__*/_jsx(Portal, {\n disablePortal: disablePortal,\n container: container,\n children: /*#__PURE__*/_jsx(PopperTooltip, _extends({\n anchorEl: anchorEl,\n direction: direction,\n disablePortal: disablePortal,\n modifiers: modifiers,\n ref: forwardedRef,\n open: transition ? !exited : open,\n placement: placement,\n popperOptions: popperOptions,\n popperRef: popperRef,\n slotProps: slotProps,\n slots: slots\n }, other, {\n style: _extends({\n // Prevents scroll issue, waiting for Popper.js to add this style once initiated.\n position: 'fixed',\n // Fix Popper.js display issue\n top: 0,\n left: 0,\n display\n }, style),\n TransitionProps: transitionProps,\n children: children\n }))\n });\n});\nprocess.env.NODE_ENV !== \"production\" ? Popper.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * An HTML element, [virtualElement](https://popper.js.org/docs/v2/virtual-elements/),\n * or a function that returns either.\n * It's used to set the position of the popper.\n * The return value will passed as the reference object of the Popper instance.\n */\n anchorEl: chainPropTypes(PropTypes.oneOfType([HTMLElementType, PropTypes.object, PropTypes.func]), props => {\n if (props.open) {\n const resolvedAnchorEl = resolveAnchorEl(props.anchorEl);\n if (resolvedAnchorEl && isHTMLElement(resolvedAnchorEl) && resolvedAnchorEl.nodeType === 1) {\n const box = resolvedAnchorEl.getBoundingClientRect();\n if (process.env.NODE_ENV !== 'test' && box.top === 0 && box.left === 0 && box.right === 0 && box.bottom === 0) {\n return new Error(['MUI: The `anchorEl` prop provided to the component is invalid.', 'The anchor element should be part of the document layout.', \"Make sure the element is present in the document or that it's not display none.\"].join('\\n'));\n }\n } else if (!resolvedAnchorEl || typeof resolvedAnchorEl.getBoundingClientRect !== 'function' || isVirtualElement(resolvedAnchorEl) && resolvedAnchorEl.contextElement != null && resolvedAnchorEl.contextElement.nodeType !== 1) {\n return new Error(['MUI: The `anchorEl` prop provided to the component is invalid.', 'It should be an HTML element instance or a virtualElement ', '(https://popper.js.org/docs/v2/virtual-elements/).'].join('\\n'));\n }\n }\n return null;\n }),\n /**\n * Popper render function or node.\n */\n children: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.node, PropTypes.func]),\n /**\n * An HTML element or function that returns one.\n * The `container` will have the portal children appended to it.\n *\n * You can also provide a callback, which is called in a React layout effect.\n * This lets you set the container from a ref, and also makes server-side rendering possible.\n *\n * By default, it uses the body of the top-level document object,\n * so it's simply `document.body` most of the time.\n */\n container: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.func]),\n /**\n * Direction of the text.\n * @default 'ltr'\n */\n direction: PropTypes.oneOf(['ltr', 'rtl']),\n /**\n * The `children` will be under the DOM hierarchy of the parent component.\n * @default false\n */\n disablePortal: PropTypes.bool,\n /**\n * Always keep the children in the DOM.\n * This prop can be useful in SEO situation or\n * when you want to maximize the responsiveness of the Popper.\n * @default false\n */\n keepMounted: PropTypes.bool,\n /**\n * Popper.js is based on a \"plugin-like\" architecture,\n * most of its features are fully encapsulated \"modifiers\".\n *\n * A modifier is a function that is called each time Popper.js needs to\n * compute the position of the popper.\n * For this reason, modifiers should be very performant to avoid bottlenecks.\n * To learn how to create a modifier, [read the modifiers documentation](https://popper.js.org/docs/v2/modifiers/).\n */\n modifiers: PropTypes.arrayOf(PropTypes.shape({\n data: PropTypes.object,\n effect: PropTypes.func,\n enabled: PropTypes.bool,\n fn: PropTypes.func,\n name: PropTypes.any,\n options: PropTypes.object,\n phase: PropTypes.oneOf(['afterMain', 'afterRead', 'afterWrite', 'beforeMain', 'beforeRead', 'beforeWrite', 'main', 'read', 'write']),\n requires: PropTypes.arrayOf(PropTypes.string),\n requiresIfExists: PropTypes.arrayOf(PropTypes.string)\n })),\n /**\n * If `true`, the component is shown.\n */\n open: PropTypes.bool.isRequired,\n /**\n * Popper placement.\n * @default 'bottom'\n */\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n /**\n * Options provided to the [`Popper.js`](https://popper.js.org/docs/v2/constructors/#options) instance.\n * @default {}\n */\n popperOptions: PropTypes.shape({\n modifiers: PropTypes.array,\n onFirstUpdate: PropTypes.func,\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n strategy: PropTypes.oneOf(['absolute', 'fixed'])\n }),\n /**\n * A ref that points to the used popper instance.\n */\n popperRef: refType,\n /**\n * The props used for each slot inside the Popper.\n * @default {}\n */\n slotProps: PropTypes.shape({\n root: PropTypes.oneOfType([PropTypes.func, PropTypes.object])\n }),\n /**\n * The components used for each slot inside the Popper.\n * Either a string to use a HTML element or a component.\n * @default {}\n */\n slots: PropTypes.shape({\n root: PropTypes.elementType\n }),\n /**\n * Help supporting a react-transition-group/Transition component.\n * @default false\n */\n transition: PropTypes.bool\n} : void 0;\nexport { Popper };","'use client';\n\nimport * as React from 'react';\nimport { useTheme as useThemeSystem } from '@mui/system';\nimport defaultTheme from './defaultTheme';\nimport THEME_ID from './identifier';\nexport default function useTheme() {\n const theme = useThemeSystem(defaultTheme);\n if (process.env.NODE_ENV !== 'production') {\n // eslint-disable-next-line react-hooks/rules-of-hooks\n React.useDebugValue(theme);\n }\n return theme[THEME_ID] || theme;\n}","export default function _setPrototypeOf(o, p) {\n _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function _setPrototypeOf(o, p) {\n o.__proto__ = p;\n return o;\n };\n return _setPrototypeOf(o, p);\n}","import setPrototypeOf from \"./setPrototypeOf.js\";\nexport default function _inheritsLoose(subClass, superClass) {\n subClass.prototype = Object.create(superClass.prototype);\n subClass.prototype.constructor = subClass;\n setPrototypeOf(subClass, superClass);\n}","export default {\n disabled: false\n};","import PropTypes from 'prop-types';\nexport var timeoutsShape = process.env.NODE_ENV !== 'production' ? PropTypes.oneOfType([PropTypes.number, PropTypes.shape({\n enter: PropTypes.number,\n exit: PropTypes.number,\n appear: PropTypes.number\n}).isRequired]) : null;\nexport var classNamesShape = process.env.NODE_ENV !== 'production' ? PropTypes.oneOfType([PropTypes.string, PropTypes.shape({\n enter: PropTypes.string,\n exit: PropTypes.string,\n active: PropTypes.string\n}), PropTypes.shape({\n enter: PropTypes.string,\n enterDone: PropTypes.string,\n enterActive: PropTypes.string,\n exit: PropTypes.string,\n exitDone: PropTypes.string,\n exitActive: PropTypes.string\n})]) : null;","import React from 'react';\nexport default React.createContext(null);","export var forceReflow = function forceReflow(node) {\n return node.scrollTop;\n};","import _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _inheritsLoose from \"@babel/runtime/helpers/esm/inheritsLoose\";\nimport PropTypes from 'prop-types';\nimport React from 'react';\nimport ReactDOM from 'react-dom';\nimport config from './config';\nimport { timeoutsShape } from './utils/PropTypes';\nimport TransitionGroupContext from './TransitionGroupContext';\nimport { forceReflow } from './utils/reflow';\nexport var UNMOUNTED = 'unmounted';\nexport var EXITED = 'exited';\nexport var ENTERING = 'entering';\nexport var ENTERED = 'entered';\nexport var EXITING = 'exiting';\n/**\n * The Transition component lets you describe a transition from one component\n * state to another _over time_ with a simple declarative API. Most commonly\n * it's used to animate the mounting and unmounting of a component, but can also\n * be used to describe in-place transition states as well.\n *\n * ---\n *\n * **Note**: `Transition` is a platform-agnostic base component. If you're using\n * transitions in CSS, you'll probably want to use\n * [`CSSTransition`](https://reactcommunity.org/react-transition-group/css-transition)\n * instead. It inherits all the features of `Transition`, but contains\n * additional features necessary to play nice with CSS transitions (hence the\n * name of the component).\n *\n * ---\n *\n * By default the `Transition` component does not alter the behavior of the\n * component it renders, it only tracks \"enter\" and \"exit\" states for the\n * components. It's up to you to give meaning and effect to those states. For\n * example we can add styles to a component when it enters or exits:\n *\n * ```jsx\n * import { Transition } from 'react-transition-group';\n *\n * const duration = 300;\n *\n * const defaultStyle = {\n * transition: `opacity ${duration}ms ease-in-out`,\n * opacity: 0,\n * }\n *\n * const transitionStyles = {\n * entering: { opacity: 1 },\n * entered: { opacity: 1 },\n * exiting: { opacity: 0 },\n * exited: { opacity: 0 },\n * };\n *\n * const Fade = ({ in: inProp }) => (\n * \n * {state => (\n *
    \n * I'm a fade Transition!\n *
    \n * )}\n *
    \n * );\n * ```\n *\n * There are 4 main states a Transition can be in:\n * - `'entering'`\n * - `'entered'`\n * - `'exiting'`\n * - `'exited'`\n *\n * Transition state is toggled via the `in` prop. When `true` the component\n * begins the \"Enter\" stage. During this stage, the component will shift from\n * its current transition state, to `'entering'` for the duration of the\n * transition and then to the `'entered'` stage once it's complete. Let's take\n * the following example (we'll use the\n * [useState](https://reactjs.org/docs/hooks-reference.html#usestate) hook):\n *\n * ```jsx\n * function App() {\n * const [inProp, setInProp] = useState(false);\n * return (\n *
    \n * \n * {state => (\n * // ...\n * )}\n * \n * \n *
    \n * );\n * }\n * ```\n *\n * When the button is clicked the component will shift to the `'entering'` state\n * and stay there for 500ms (the value of `timeout`) before it finally switches\n * to `'entered'`.\n *\n * When `in` is `false` the same thing happens except the state moves from\n * `'exiting'` to `'exited'`.\n */\n\nvar Transition = /*#__PURE__*/function (_React$Component) {\n _inheritsLoose(Transition, _React$Component);\n\n function Transition(props, context) {\n var _this;\n\n _this = _React$Component.call(this, props, context) || this;\n var parentGroup = context; // In the context of a TransitionGroup all enters are really appears\n\n var appear = parentGroup && !parentGroup.isMounting ? props.enter : props.appear;\n var initialStatus;\n _this.appearStatus = null;\n\n if (props.in) {\n if (appear) {\n initialStatus = EXITED;\n _this.appearStatus = ENTERING;\n } else {\n initialStatus = ENTERED;\n }\n } else {\n if (props.unmountOnExit || props.mountOnEnter) {\n initialStatus = UNMOUNTED;\n } else {\n initialStatus = EXITED;\n }\n }\n\n _this.state = {\n status: initialStatus\n };\n _this.nextCallback = null;\n return _this;\n }\n\n Transition.getDerivedStateFromProps = function getDerivedStateFromProps(_ref, prevState) {\n var nextIn = _ref.in;\n\n if (nextIn && prevState.status === UNMOUNTED) {\n return {\n status: EXITED\n };\n }\n\n return null;\n } // getSnapshotBeforeUpdate(prevProps) {\n // let nextStatus = null\n // if (prevProps !== this.props) {\n // const { status } = this.state\n // if (this.props.in) {\n // if (status !== ENTERING && status !== ENTERED) {\n // nextStatus = ENTERING\n // }\n // } else {\n // if (status === ENTERING || status === ENTERED) {\n // nextStatus = EXITING\n // }\n // }\n // }\n // return { nextStatus }\n // }\n ;\n\n var _proto = Transition.prototype;\n\n _proto.componentDidMount = function componentDidMount() {\n this.updateStatus(true, this.appearStatus);\n };\n\n _proto.componentDidUpdate = function componentDidUpdate(prevProps) {\n var nextStatus = null;\n\n if (prevProps !== this.props) {\n var status = this.state.status;\n\n if (this.props.in) {\n if (status !== ENTERING && status !== ENTERED) {\n nextStatus = ENTERING;\n }\n } else {\n if (status === ENTERING || status === ENTERED) {\n nextStatus = EXITING;\n }\n }\n }\n\n this.updateStatus(false, nextStatus);\n };\n\n _proto.componentWillUnmount = function componentWillUnmount() {\n this.cancelNextCallback();\n };\n\n _proto.getTimeouts = function getTimeouts() {\n var timeout = this.props.timeout;\n var exit, enter, appear;\n exit = enter = appear = timeout;\n\n if (timeout != null && typeof timeout !== 'number') {\n exit = timeout.exit;\n enter = timeout.enter; // TODO: remove fallback for next major\n\n appear = timeout.appear !== undefined ? timeout.appear : enter;\n }\n\n return {\n exit: exit,\n enter: enter,\n appear: appear\n };\n };\n\n _proto.updateStatus = function updateStatus(mounting, nextStatus) {\n if (mounting === void 0) {\n mounting = false;\n }\n\n if (nextStatus !== null) {\n // nextStatus will always be ENTERING or EXITING.\n this.cancelNextCallback();\n\n if (nextStatus === ENTERING) {\n if (this.props.unmountOnExit || this.props.mountOnEnter) {\n var node = this.props.nodeRef ? this.props.nodeRef.current : ReactDOM.findDOMNode(this); // https://github.com/reactjs/react-transition-group/pull/749\n // With unmountOnExit or mountOnEnter, the enter animation should happen at the transition between `exited` and `entering`.\n // To make the animation happen, we have to separate each rendering and avoid being processed as batched.\n\n if (node) forceReflow(node);\n }\n\n this.performEnter(mounting);\n } else {\n this.performExit();\n }\n } else if (this.props.unmountOnExit && this.state.status === EXITED) {\n this.setState({\n status: UNMOUNTED\n });\n }\n };\n\n _proto.performEnter = function performEnter(mounting) {\n var _this2 = this;\n\n var enter = this.props.enter;\n var appearing = this.context ? this.context.isMounting : mounting;\n\n var _ref2 = this.props.nodeRef ? [appearing] : [ReactDOM.findDOMNode(this), appearing],\n maybeNode = _ref2[0],\n maybeAppearing = _ref2[1];\n\n var timeouts = this.getTimeouts();\n var enterTimeout = appearing ? timeouts.appear : timeouts.enter; // no enter animation skip right to ENTERED\n // if we are mounting and running this it means appear _must_ be set\n\n if (!mounting && !enter || config.disabled) {\n this.safeSetState({\n status: ENTERED\n }, function () {\n _this2.props.onEntered(maybeNode);\n });\n return;\n }\n\n this.props.onEnter(maybeNode, maybeAppearing);\n this.safeSetState({\n status: ENTERING\n }, function () {\n _this2.props.onEntering(maybeNode, maybeAppearing);\n\n _this2.onTransitionEnd(enterTimeout, function () {\n _this2.safeSetState({\n status: ENTERED\n }, function () {\n _this2.props.onEntered(maybeNode, maybeAppearing);\n });\n });\n });\n };\n\n _proto.performExit = function performExit() {\n var _this3 = this;\n\n var exit = this.props.exit;\n var timeouts = this.getTimeouts();\n var maybeNode = this.props.nodeRef ? undefined : ReactDOM.findDOMNode(this); // no exit animation skip right to EXITED\n\n if (!exit || config.disabled) {\n this.safeSetState({\n status: EXITED\n }, function () {\n _this3.props.onExited(maybeNode);\n });\n return;\n }\n\n this.props.onExit(maybeNode);\n this.safeSetState({\n status: EXITING\n }, function () {\n _this3.props.onExiting(maybeNode);\n\n _this3.onTransitionEnd(timeouts.exit, function () {\n _this3.safeSetState({\n status: EXITED\n }, function () {\n _this3.props.onExited(maybeNode);\n });\n });\n });\n };\n\n _proto.cancelNextCallback = function cancelNextCallback() {\n if (this.nextCallback !== null) {\n this.nextCallback.cancel();\n this.nextCallback = null;\n }\n };\n\n _proto.safeSetState = function safeSetState(nextState, callback) {\n // This shouldn't be necessary, but there are weird race conditions with\n // setState callbacks and unmounting in testing, so always make sure that\n // we can cancel any pending setState callbacks after we unmount.\n callback = this.setNextCallback(callback);\n this.setState(nextState, callback);\n };\n\n _proto.setNextCallback = function setNextCallback(callback) {\n var _this4 = this;\n\n var active = true;\n\n this.nextCallback = function (event) {\n if (active) {\n active = false;\n _this4.nextCallback = null;\n callback(event);\n }\n };\n\n this.nextCallback.cancel = function () {\n active = false;\n };\n\n return this.nextCallback;\n };\n\n _proto.onTransitionEnd = function onTransitionEnd(timeout, handler) {\n this.setNextCallback(handler);\n var node = this.props.nodeRef ? this.props.nodeRef.current : ReactDOM.findDOMNode(this);\n var doesNotHaveTimeoutOrListener = timeout == null && !this.props.addEndListener;\n\n if (!node || doesNotHaveTimeoutOrListener) {\n setTimeout(this.nextCallback, 0);\n return;\n }\n\n if (this.props.addEndListener) {\n var _ref3 = this.props.nodeRef ? [this.nextCallback] : [node, this.nextCallback],\n maybeNode = _ref3[0],\n maybeNextCallback = _ref3[1];\n\n this.props.addEndListener(maybeNode, maybeNextCallback);\n }\n\n if (timeout != null) {\n setTimeout(this.nextCallback, timeout);\n }\n };\n\n _proto.render = function render() {\n var status = this.state.status;\n\n if (status === UNMOUNTED) {\n return null;\n }\n\n var _this$props = this.props,\n children = _this$props.children,\n _in = _this$props.in,\n _mountOnEnter = _this$props.mountOnEnter,\n _unmountOnExit = _this$props.unmountOnExit,\n _appear = _this$props.appear,\n _enter = _this$props.enter,\n _exit = _this$props.exit,\n _timeout = _this$props.timeout,\n _addEndListener = _this$props.addEndListener,\n _onEnter = _this$props.onEnter,\n _onEntering = _this$props.onEntering,\n _onEntered = _this$props.onEntered,\n _onExit = _this$props.onExit,\n _onExiting = _this$props.onExiting,\n _onExited = _this$props.onExited,\n _nodeRef = _this$props.nodeRef,\n childProps = _objectWithoutPropertiesLoose(_this$props, [\"children\", \"in\", \"mountOnEnter\", \"unmountOnExit\", \"appear\", \"enter\", \"exit\", \"timeout\", \"addEndListener\", \"onEnter\", \"onEntering\", \"onEntered\", \"onExit\", \"onExiting\", \"onExited\", \"nodeRef\"]);\n\n return (\n /*#__PURE__*/\n // allows for nested Transitions\n React.createElement(TransitionGroupContext.Provider, {\n value: null\n }, typeof children === 'function' ? children(status, childProps) : React.cloneElement(React.Children.only(children), childProps))\n );\n };\n\n return Transition;\n}(React.Component);\n\nTransition.contextType = TransitionGroupContext;\nTransition.propTypes = process.env.NODE_ENV !== \"production\" ? {\n /**\n * A React reference to DOM element that need to transition:\n * https://stackoverflow.com/a/51127130/4671932\n *\n * - When `nodeRef` prop is used, `node` is not passed to callback functions\n * (e.g. `onEnter`) because user already has direct access to the node.\n * - When changing `key` prop of `Transition` in a `TransitionGroup` a new\n * `nodeRef` need to be provided to `Transition` with changed `key` prop\n * (see\n * [test/CSSTransition-test.js](https://github.com/reactjs/react-transition-group/blob/13435f897b3ab71f6e19d724f145596f5910581c/test/CSSTransition-test.js#L362-L437)).\n */\n nodeRef: PropTypes.shape({\n current: typeof Element === 'undefined' ? PropTypes.any : function (propValue, key, componentName, location, propFullName, secret) {\n var value = propValue[key];\n return PropTypes.instanceOf(value && 'ownerDocument' in value ? value.ownerDocument.defaultView.Element : Element)(propValue, key, componentName, location, propFullName, secret);\n }\n }),\n\n /**\n * A `function` child can be used instead of a React element. This function is\n * called with the current transition status (`'entering'`, `'entered'`,\n * `'exiting'`, `'exited'`), which can be used to apply context\n * specific props to a component.\n *\n * ```jsx\n * \n * {state => (\n * \n * )}\n * \n * ```\n */\n children: PropTypes.oneOfType([PropTypes.func.isRequired, PropTypes.element.isRequired]).isRequired,\n\n /**\n * Show the component; triggers the enter or exit states\n */\n in: PropTypes.bool,\n\n /**\n * By default the child component is mounted immediately along with\n * the parent `Transition` component. If you want to \"lazy mount\" the component on the\n * first `in={true}` you can set `mountOnEnter`. After the first enter transition the component will stay\n * mounted, even on \"exited\", unless you also specify `unmountOnExit`.\n */\n mountOnEnter: PropTypes.bool,\n\n /**\n * By default the child component stays mounted after it reaches the `'exited'` state.\n * Set `unmountOnExit` if you'd prefer to unmount the component after it finishes exiting.\n */\n unmountOnExit: PropTypes.bool,\n\n /**\n * By default the child component does not perform the enter transition when\n * it first mounts, regardless of the value of `in`. If you want this\n * behavior, set both `appear` and `in` to `true`.\n *\n * > **Note**: there are no special appear states like `appearing`/`appeared`, this prop\n * > only adds an additional enter transition. However, in the\n * > `` component that first enter transition does result in\n * > additional `.appear-*` classes, that way you can choose to style it\n * > differently.\n */\n appear: PropTypes.bool,\n\n /**\n * Enable or disable enter transitions.\n */\n enter: PropTypes.bool,\n\n /**\n * Enable or disable exit transitions.\n */\n exit: PropTypes.bool,\n\n /**\n * The duration of the transition, in milliseconds.\n * Required unless `addEndListener` is provided.\n *\n * You may specify a single timeout for all transitions:\n *\n * ```jsx\n * timeout={500}\n * ```\n *\n * or individually:\n *\n * ```jsx\n * timeout={{\n * appear: 500,\n * enter: 300,\n * exit: 500,\n * }}\n * ```\n *\n * - `appear` defaults to the value of `enter`\n * - `enter` defaults to `0`\n * - `exit` defaults to `0`\n *\n * @type {number | { enter?: number, exit?: number, appear?: number }}\n */\n timeout: function timeout(props) {\n var pt = timeoutsShape;\n if (!props.addEndListener) pt = pt.isRequired;\n\n for (var _len = arguments.length, args = new Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) {\n args[_key - 1] = arguments[_key];\n }\n\n return pt.apply(void 0, [props].concat(args));\n },\n\n /**\n * Add a custom transition end trigger. Called with the transitioning\n * DOM node and a `done` callback. Allows for more fine grained transition end\n * logic. Timeouts are still used as a fallback if provided.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * ```jsx\n * addEndListener={(node, done) => {\n * // use the css transitionend event to mark the finish of a transition\n * node.addEventListener('transitionend', done, false);\n * }}\n * ```\n */\n addEndListener: PropTypes.func,\n\n /**\n * Callback fired before the \"entering\" status is applied. An extra parameter\n * `isAppearing` is supplied to indicate if the enter stage is occurring on the initial mount\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement, isAppearing: bool) -> void\n */\n onEnter: PropTypes.func,\n\n /**\n * Callback fired after the \"entering\" status is applied. An extra parameter\n * `isAppearing` is supplied to indicate if the enter stage is occurring on the initial mount\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement, isAppearing: bool)\n */\n onEntering: PropTypes.func,\n\n /**\n * Callback fired after the \"entered\" status is applied. An extra parameter\n * `isAppearing` is supplied to indicate if the enter stage is occurring on the initial mount\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement, isAppearing: bool) -> void\n */\n onEntered: PropTypes.func,\n\n /**\n * Callback fired before the \"exiting\" status is applied.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement) -> void\n */\n onExit: PropTypes.func,\n\n /**\n * Callback fired after the \"exiting\" status is applied.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement) -> void\n */\n onExiting: PropTypes.func,\n\n /**\n * Callback fired after the \"exited\" status is applied.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed\n *\n * @type Function(node: HtmlElement) -> void\n */\n onExited: PropTypes.func\n} : {}; // Name the function so it is clearer in the documentation\n\nfunction noop() {}\n\nTransition.defaultProps = {\n in: false,\n mountOnEnter: false,\n unmountOnExit: false,\n appear: false,\n enter: true,\n exit: true,\n onEnter: noop,\n onEntering: noop,\n onEntered: noop,\n onExit: noop,\n onExiting: noop,\n onExited: noop\n};\nTransition.UNMOUNTED = UNMOUNTED;\nTransition.EXITED = EXITED;\nTransition.ENTERING = ENTERING;\nTransition.ENTERED = ENTERED;\nTransition.EXITING = EXITING;\nexport default Transition;","export const reflow = node => node.scrollTop;\nexport function getTransitionProps(props, options) {\n var _style$transitionDura, _style$transitionTimi;\n const {\n timeout,\n easing,\n style = {}\n } = props;\n return {\n duration: (_style$transitionDura = style.transitionDuration) != null ? _style$transitionDura : typeof timeout === 'number' ? timeout : timeout[options.mode] || 0,\n easing: (_style$transitionTimi = style.transitionTimingFunction) != null ? _style$transitionTimi : typeof easing === 'object' ? easing[options.mode] : easing,\n delay: style.transitionDelay\n };\n}","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"addEndListener\", \"appear\", \"children\", \"easing\", \"in\", \"onEnter\", \"onEntered\", \"onEntering\", \"onExit\", \"onExited\", \"onExiting\", \"style\", \"timeout\", \"TransitionComponent\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport { elementAcceptingRef, unstable_useTimeout as useTimeout } from '@mui/utils';\nimport { Transition } from 'react-transition-group';\nimport useTheme from '../styles/useTheme';\nimport { getTransitionProps, reflow } from '../transitions/utils';\nimport useForkRef from '../utils/useForkRef';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nfunction getScale(value) {\n return `scale(${value}, ${value ** 2})`;\n}\nconst styles = {\n entering: {\n opacity: 1,\n transform: getScale(1)\n },\n entered: {\n opacity: 1,\n transform: 'none'\n }\n};\n\n/*\n TODO v6: remove\n Conditionally apply a workaround for the CSS transition bug in Safari 15.4 / WebKit browsers.\n */\nconst isWebKit154 = typeof navigator !== 'undefined' && /^((?!chrome|android).)*(safari|mobile)/i.test(navigator.userAgent) && /(os |version\\/)15(.|_)4/i.test(navigator.userAgent);\n\n/**\n * The Grow transition is used by the [Tooltip](/material-ui/react-tooltip/) and\n * [Popover](/material-ui/react-popover/) components.\n * It uses [react-transition-group](https://github.com/reactjs/react-transition-group) internally.\n */\nconst Grow = /*#__PURE__*/React.forwardRef(function Grow(props, ref) {\n const {\n addEndListener,\n appear = true,\n children,\n easing,\n in: inProp,\n onEnter,\n onEntered,\n onEntering,\n onExit,\n onExited,\n onExiting,\n style,\n timeout = 'auto',\n // eslint-disable-next-line react/prop-types\n TransitionComponent = Transition\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const timer = useTimeout();\n const autoTimeout = React.useRef();\n const theme = useTheme();\n const nodeRef = React.useRef(null);\n const handleRef = useForkRef(nodeRef, children.ref, ref);\n const normalizedTransitionCallback = callback => maybeIsAppearing => {\n if (callback) {\n const node = nodeRef.current;\n\n // onEnterXxx and onExitXxx callbacks have a different arguments.length value.\n if (maybeIsAppearing === undefined) {\n callback(node);\n } else {\n callback(node, maybeIsAppearing);\n }\n }\n };\n const handleEntering = normalizedTransitionCallback(onEntering);\n const handleEnter = normalizedTransitionCallback((node, isAppearing) => {\n reflow(node); // So the animation always start from the start.\n\n const {\n duration: transitionDuration,\n delay,\n easing: transitionTimingFunction\n } = getTransitionProps({\n style,\n timeout,\n easing\n }, {\n mode: 'enter'\n });\n let duration;\n if (timeout === 'auto') {\n duration = theme.transitions.getAutoHeightDuration(node.clientHeight);\n autoTimeout.current = duration;\n } else {\n duration = transitionDuration;\n }\n node.style.transition = [theme.transitions.create('opacity', {\n duration,\n delay\n }), theme.transitions.create('transform', {\n duration: isWebKit154 ? duration : duration * 0.666,\n delay,\n easing: transitionTimingFunction\n })].join(',');\n if (onEnter) {\n onEnter(node, isAppearing);\n }\n });\n const handleEntered = normalizedTransitionCallback(onEntered);\n const handleExiting = normalizedTransitionCallback(onExiting);\n const handleExit = normalizedTransitionCallback(node => {\n const {\n duration: transitionDuration,\n delay,\n easing: transitionTimingFunction\n } = getTransitionProps({\n style,\n timeout,\n easing\n }, {\n mode: 'exit'\n });\n let duration;\n if (timeout === 'auto') {\n duration = theme.transitions.getAutoHeightDuration(node.clientHeight);\n autoTimeout.current = duration;\n } else {\n duration = transitionDuration;\n }\n node.style.transition = [theme.transitions.create('opacity', {\n duration,\n delay\n }), theme.transitions.create('transform', {\n duration: isWebKit154 ? duration : duration * 0.666,\n delay: isWebKit154 ? delay : delay || duration * 0.333,\n easing: transitionTimingFunction\n })].join(',');\n node.style.opacity = 0;\n node.style.transform = getScale(0.75);\n if (onExit) {\n onExit(node);\n }\n });\n const handleExited = normalizedTransitionCallback(onExited);\n const handleAddEndListener = next => {\n if (timeout === 'auto') {\n timer.start(autoTimeout.current || 0, next);\n }\n if (addEndListener) {\n // Old call signature before `react-transition-group` implemented `nodeRef`\n addEndListener(nodeRef.current, next);\n }\n };\n return /*#__PURE__*/_jsx(TransitionComponent, _extends({\n appear: appear,\n in: inProp,\n nodeRef: nodeRef,\n onEnter: handleEnter,\n onEntered: handleEntered,\n onEntering: handleEntering,\n onExit: handleExit,\n onExited: handleExited,\n onExiting: handleExiting,\n addEndListener: handleAddEndListener,\n timeout: timeout === 'auto' ? null : timeout\n }, other, {\n children: (state, childProps) => {\n return /*#__PURE__*/React.cloneElement(children, _extends({\n style: _extends({\n opacity: 0,\n transform: getScale(0.75),\n visibility: state === 'exited' && !inProp ? 'hidden' : undefined\n }, styles[state], style, children.props.style),\n ref: handleRef\n }, childProps));\n }\n }));\n});\nprocess.env.NODE_ENV !== \"production\" ? Grow.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the d.ts file and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * Add a custom transition end trigger. Called with the transitioning DOM\n * node and a done callback. Allows for more fine grained transition end\n * logic. Note: Timeouts are still used as a fallback if provided.\n */\n addEndListener: PropTypes.func,\n /**\n * Perform the enter transition when it first mounts if `in` is also `true`.\n * Set this to `false` to disable this behavior.\n * @default true\n */\n appear: PropTypes.bool,\n /**\n * A single child content element.\n */\n children: elementAcceptingRef.isRequired,\n /**\n * The transition timing function.\n * You may specify a single easing or a object containing enter and exit values.\n */\n easing: PropTypes.oneOfType([PropTypes.shape({\n enter: PropTypes.string,\n exit: PropTypes.string\n }), PropTypes.string]),\n /**\n * If `true`, the component will transition in.\n */\n in: PropTypes.bool,\n /**\n * @ignore\n */\n onEnter: PropTypes.func,\n /**\n * @ignore\n */\n onEntered: PropTypes.func,\n /**\n * @ignore\n */\n onEntering: PropTypes.func,\n /**\n * @ignore\n */\n onExit: PropTypes.func,\n /**\n * @ignore\n */\n onExited: PropTypes.func,\n /**\n * @ignore\n */\n onExiting: PropTypes.func,\n /**\n * @ignore\n */\n style: PropTypes.object,\n /**\n * The duration for the transition, in milliseconds.\n * You may specify a single timeout for all transitions, or individually with an object.\n *\n * Set to 'auto' to automatically calculate transition time based on height.\n * @default 'auto'\n */\n timeout: PropTypes.oneOfType([PropTypes.oneOf(['auto']), PropTypes.number, PropTypes.shape({\n appear: PropTypes.number,\n enter: PropTypes.number,\n exit: PropTypes.number\n })])\n} : void 0;\nGrow.muiSupportAuto = true;\nexport default Grow;","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"anchorEl\", \"component\", \"components\", \"componentsProps\", \"container\", \"disablePortal\", \"keepMounted\", \"modifiers\", \"open\", \"placement\", \"popperOptions\", \"popperRef\", \"transition\", \"slots\", \"slotProps\"];\nimport { Popper as BasePopper } from '@mui/base/Popper';\nimport { useThemeWithoutDefault as useTheme } from '@mui/system';\nimport { HTMLElementType, refType } from '@mui/utils';\nimport PropTypes from 'prop-types';\nimport * as React from 'react';\nimport { styled, useThemeProps } from '../styles';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nconst PopperRoot = styled(BasePopper, {\n name: 'MuiPopper',\n slot: 'Root',\n overridesResolver: (props, styles) => styles.root\n})({});\n\n/**\n *\n * Demos:\n *\n * - [Autocomplete](https://mui.com/material-ui/react-autocomplete/)\n * - [Menu](https://mui.com/material-ui/react-menu/)\n * - [Popper](https://mui.com/material-ui/react-popper/)\n *\n * API:\n *\n * - [Popper API](https://mui.com/material-ui/api/popper/)\n */\nconst Popper = /*#__PURE__*/React.forwardRef(function Popper(inProps, ref) {\n var _slots$root;\n const theme = useTheme();\n const props = useThemeProps({\n props: inProps,\n name: 'MuiPopper'\n });\n const {\n anchorEl,\n component,\n components,\n componentsProps,\n container,\n disablePortal,\n keepMounted,\n modifiers,\n open,\n placement,\n popperOptions,\n popperRef,\n transition,\n slots,\n slotProps\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const RootComponent = (_slots$root = slots == null ? void 0 : slots.root) != null ? _slots$root : components == null ? void 0 : components.Root;\n const otherProps = _extends({\n anchorEl,\n container,\n disablePortal,\n keepMounted,\n modifiers,\n open,\n placement,\n popperOptions,\n popperRef,\n transition\n }, other);\n return /*#__PURE__*/_jsx(PopperRoot, _extends({\n as: component,\n direction: theme == null ? void 0 : theme.direction,\n slots: {\n root: RootComponent\n },\n slotProps: slotProps != null ? slotProps : componentsProps\n }, otherProps, {\n ref: ref\n }));\n});\nprocess.env.NODE_ENV !== \"production\" ? Popper.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * An HTML element, [virtualElement](https://popper.js.org/docs/v2/virtual-elements/),\n * or a function that returns either.\n * It's used to set the position of the popper.\n * The return value will passed as the reference object of the Popper instance.\n */\n anchorEl: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.object, PropTypes.func]),\n /**\n * Popper render function or node.\n */\n children: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.node, PropTypes.func]),\n /**\n * The component used for the root node.\n * Either a string to use a HTML element or a component.\n */\n component: PropTypes.elementType,\n /**\n * The components used for each slot inside the Popper.\n * Either a string to use a HTML element or a component.\n * @default {}\n */\n components: PropTypes.shape({\n Root: PropTypes.elementType\n }),\n /**\n * The props used for each slot inside the Popper.\n * @default {}\n */\n componentsProps: PropTypes.shape({\n root: PropTypes.oneOfType([PropTypes.func, PropTypes.object])\n }),\n /**\n * An HTML element or function that returns one.\n * The `container` will have the portal children appended to it.\n *\n * You can also provide a callback, which is called in a React layout effect.\n * This lets you set the container from a ref, and also makes server-side rendering possible.\n *\n * By default, it uses the body of the top-level document object,\n * so it's simply `document.body` most of the time.\n */\n container: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.func]),\n /**\n * The `children` will be under the DOM hierarchy of the parent component.\n * @default false\n */\n disablePortal: PropTypes.bool,\n /**\n * Always keep the children in the DOM.\n * This prop can be useful in SEO situation or\n * when you want to maximize the responsiveness of the Popper.\n * @default false\n */\n keepMounted: PropTypes.bool,\n /**\n * Popper.js is based on a \"plugin-like\" architecture,\n * most of its features are fully encapsulated \"modifiers\".\n *\n * A modifier is a function that is called each time Popper.js needs to\n * compute the position of the popper.\n * For this reason, modifiers should be very performant to avoid bottlenecks.\n * To learn how to create a modifier, [read the modifiers documentation](https://popper.js.org/docs/v2/modifiers/).\n */\n modifiers: PropTypes.arrayOf(PropTypes.shape({\n data: PropTypes.object,\n effect: PropTypes.func,\n enabled: PropTypes.bool,\n fn: PropTypes.func,\n name: PropTypes.any,\n options: PropTypes.object,\n phase: PropTypes.oneOf(['afterMain', 'afterRead', 'afterWrite', 'beforeMain', 'beforeRead', 'beforeWrite', 'main', 'read', 'write']),\n requires: PropTypes.arrayOf(PropTypes.string),\n requiresIfExists: PropTypes.arrayOf(PropTypes.string)\n })),\n /**\n * If `true`, the component is shown.\n */\n open: PropTypes.bool.isRequired,\n /**\n * Popper placement.\n * @default 'bottom'\n */\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n /**\n * Options provided to the [`Popper.js`](https://popper.js.org/docs/v2/constructors/#options) instance.\n * @default {}\n */\n popperOptions: PropTypes.shape({\n modifiers: PropTypes.array,\n onFirstUpdate: PropTypes.func,\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n strategy: PropTypes.oneOf(['absolute', 'fixed'])\n }),\n /**\n * A ref that points to the used popper instance.\n */\n popperRef: refType,\n /**\n * The props used for each slot inside the Popper.\n * @default {}\n */\n slotProps: PropTypes.shape({\n root: PropTypes.oneOfType([PropTypes.func, PropTypes.object])\n }),\n /**\n * The components used for each slot inside the Popper.\n * Either a string to use a HTML element or a component.\n * @default {}\n */\n slots: PropTypes.shape({\n root: PropTypes.elementType\n }),\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Help supporting a react-transition-group/Transition component.\n * @default false\n */\n transition: PropTypes.bool\n} : void 0;\nexport default Popper;","import generateUtilityClasses from '@mui/utils/generateUtilityClasses';\nimport generateUtilityClass from '@mui/utils/generateUtilityClass';\nexport function getTooltipUtilityClass(slot) {\n return generateUtilityClass('MuiTooltip', slot);\n}\nconst tooltipClasses = generateUtilityClasses('MuiTooltip', ['popper', 'popperInteractive', 'popperArrow', 'popperClose', 'tooltip', 'tooltipArrow', 'touch', 'tooltipPlacementLeft', 'tooltipPlacementRight', 'tooltipPlacementTop', 'tooltipPlacementBottom', 'arrow']);\nexport default tooltipClasses;","'use client';\n\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nconst _excluded = [\"arrow\", \"children\", \"classes\", \"components\", \"componentsProps\", \"describeChild\", \"disableFocusListener\", \"disableHoverListener\", \"disableInteractive\", \"disableTouchListener\", \"enterDelay\", \"enterNextDelay\", \"enterTouchDelay\", \"followCursor\", \"id\", \"leaveDelay\", \"leaveTouchDelay\", \"onClose\", \"onOpen\", \"open\", \"placement\", \"PopperComponent\", \"PopperProps\", \"slotProps\", \"slots\", \"title\", \"TransitionComponent\", \"TransitionProps\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport clsx from 'clsx';\nimport { elementAcceptingRef, unstable_useTimeout as useTimeout, unstable_Timeout as Timeout } from '@mui/utils';\nimport { unstable_composeClasses as composeClasses, appendOwnerState } from '@mui/base';\nimport { alpha } from '@mui/system';\nimport styled from '../styles/styled';\nimport useTheme from '../styles/useTheme';\nimport useThemeProps from '../styles/useThemeProps';\nimport capitalize from '../utils/capitalize';\nimport Grow from '../Grow';\nimport Popper from '../Popper';\nimport useEventCallback from '../utils/useEventCallback';\nimport useForkRef from '../utils/useForkRef';\nimport useId from '../utils/useId';\nimport useIsFocusVisible from '../utils/useIsFocusVisible';\nimport useControlled from '../utils/useControlled';\nimport tooltipClasses, { getTooltipUtilityClass } from './tooltipClasses';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nimport { jsxs as _jsxs } from \"react/jsx-runtime\";\nfunction round(value) {\n return Math.round(value * 1e5) / 1e5;\n}\nconst useUtilityClasses = ownerState => {\n const {\n classes,\n disableInteractive,\n arrow,\n touch,\n placement\n } = ownerState;\n const slots = {\n popper: ['popper', !disableInteractive && 'popperInteractive', arrow && 'popperArrow'],\n tooltip: ['tooltip', arrow && 'tooltipArrow', touch && 'touch', `tooltipPlacement${capitalize(placement.split('-')[0])}`],\n arrow: ['arrow']\n };\n return composeClasses(slots, getTooltipUtilityClass, classes);\n};\nconst TooltipPopper = styled(Popper, {\n name: 'MuiTooltip',\n slot: 'Popper',\n overridesResolver: (props, styles) => {\n const {\n ownerState\n } = props;\n return [styles.popper, !ownerState.disableInteractive && styles.popperInteractive, ownerState.arrow && styles.popperArrow, !ownerState.open && styles.popperClose];\n }\n})(({\n theme,\n ownerState,\n open\n}) => _extends({\n zIndex: (theme.vars || theme).zIndex.tooltip,\n pointerEvents: 'none'\n}, !ownerState.disableInteractive && {\n pointerEvents: 'auto'\n}, !open && {\n pointerEvents: 'none'\n}, ownerState.arrow && {\n [`&[data-popper-placement*=\"bottom\"] .${tooltipClasses.arrow}`]: {\n top: 0,\n marginTop: '-0.71em',\n '&::before': {\n transformOrigin: '0 100%'\n }\n },\n [`&[data-popper-placement*=\"top\"] .${tooltipClasses.arrow}`]: {\n bottom: 0,\n marginBottom: '-0.71em',\n '&::before': {\n transformOrigin: '100% 0'\n }\n },\n [`&[data-popper-placement*=\"right\"] .${tooltipClasses.arrow}`]: _extends({}, !ownerState.isRtl ? {\n left: 0,\n marginLeft: '-0.71em'\n } : {\n right: 0,\n marginRight: '-0.71em'\n }, {\n height: '1em',\n width: '0.71em',\n '&::before': {\n transformOrigin: '100% 100%'\n }\n }),\n [`&[data-popper-placement*=\"left\"] .${tooltipClasses.arrow}`]: _extends({}, !ownerState.isRtl ? {\n right: 0,\n marginRight: '-0.71em'\n } : {\n left: 0,\n marginLeft: '-0.71em'\n }, {\n height: '1em',\n width: '0.71em',\n '&::before': {\n transformOrigin: '0 0'\n }\n })\n}));\nconst TooltipTooltip = styled('div', {\n name: 'MuiTooltip',\n slot: 'Tooltip',\n overridesResolver: (props, styles) => {\n const {\n ownerState\n } = props;\n return [styles.tooltip, ownerState.touch && styles.touch, ownerState.arrow && styles.tooltipArrow, styles[`tooltipPlacement${capitalize(ownerState.placement.split('-')[0])}`]];\n }\n})(({\n theme,\n ownerState\n}) => _extends({\n backgroundColor: theme.vars ? theme.vars.palette.Tooltip.bg : alpha(theme.palette.grey[700], 0.92),\n borderRadius: (theme.vars || theme).shape.borderRadius,\n color: (theme.vars || theme).palette.common.white,\n fontFamily: theme.typography.fontFamily,\n padding: '4px 8px',\n fontSize: theme.typography.pxToRem(11),\n maxWidth: 300,\n margin: 2,\n wordWrap: 'break-word',\n fontWeight: theme.typography.fontWeightMedium\n}, ownerState.arrow && {\n position: 'relative',\n margin: 0\n}, ownerState.touch && {\n padding: '8px 16px',\n fontSize: theme.typography.pxToRem(14),\n lineHeight: `${round(16 / 14)}em`,\n fontWeight: theme.typography.fontWeightRegular\n}, {\n [`.${tooltipClasses.popper}[data-popper-placement*=\"left\"] &`]: _extends({\n transformOrigin: 'right center'\n }, !ownerState.isRtl ? _extends({\n marginRight: '14px'\n }, ownerState.touch && {\n marginRight: '24px'\n }) : _extends({\n marginLeft: '14px'\n }, ownerState.touch && {\n marginLeft: '24px'\n })),\n [`.${tooltipClasses.popper}[data-popper-placement*=\"right\"] &`]: _extends({\n transformOrigin: 'left center'\n }, !ownerState.isRtl ? _extends({\n marginLeft: '14px'\n }, ownerState.touch && {\n marginLeft: '24px'\n }) : _extends({\n marginRight: '14px'\n }, ownerState.touch && {\n marginRight: '24px'\n })),\n [`.${tooltipClasses.popper}[data-popper-placement*=\"top\"] &`]: _extends({\n transformOrigin: 'center bottom',\n marginBottom: '14px'\n }, ownerState.touch && {\n marginBottom: '24px'\n }),\n [`.${tooltipClasses.popper}[data-popper-placement*=\"bottom\"] &`]: _extends({\n transformOrigin: 'center top',\n marginTop: '14px'\n }, ownerState.touch && {\n marginTop: '24px'\n })\n}));\nconst TooltipArrow = styled('span', {\n name: 'MuiTooltip',\n slot: 'Arrow',\n overridesResolver: (props, styles) => styles.arrow\n})(({\n theme\n}) => ({\n overflow: 'hidden',\n position: 'absolute',\n width: '1em',\n height: '0.71em' /* = width / sqrt(2) = (length of the hypotenuse) */,\n boxSizing: 'border-box',\n color: theme.vars ? theme.vars.palette.Tooltip.bg : alpha(theme.palette.grey[700], 0.9),\n '&::before': {\n content: '\"\"',\n margin: 'auto',\n display: 'block',\n width: '100%',\n height: '100%',\n backgroundColor: 'currentColor',\n transform: 'rotate(45deg)'\n }\n}));\nlet hystersisOpen = false;\nconst hystersisTimer = new Timeout();\nlet cursorPosition = {\n x: 0,\n y: 0\n};\nexport function testReset() {\n hystersisOpen = false;\n hystersisTimer.clear();\n}\nfunction composeEventHandler(handler, eventHandler) {\n return event => {\n if (eventHandler) {\n eventHandler(event);\n }\n handler(event);\n };\n}\n\n// TODO v6: Remove PopperComponent, PopperProps, TransitionComponent and TransitionProps.\nconst Tooltip = /*#__PURE__*/React.forwardRef(function Tooltip(inProps, ref) {\n var _ref, _slots$popper, _ref2, _ref3, _slots$transition, _ref4, _slots$tooltip, _ref5, _slots$arrow, _slotProps$popper, _ref6, _slotProps$popper2, _slotProps$transition, _slotProps$tooltip, _ref7, _slotProps$tooltip2, _slotProps$arrow, _ref8, _slotProps$arrow2;\n const props = useThemeProps({\n props: inProps,\n name: 'MuiTooltip'\n });\n const {\n arrow = false,\n children: childrenProp,\n components = {},\n componentsProps = {},\n describeChild = false,\n disableFocusListener = false,\n disableHoverListener = false,\n disableInteractive: disableInteractiveProp = false,\n disableTouchListener = false,\n enterDelay = 100,\n enterNextDelay = 0,\n enterTouchDelay = 700,\n followCursor = false,\n id: idProp,\n leaveDelay = 0,\n leaveTouchDelay = 1500,\n onClose,\n onOpen,\n open: openProp,\n placement = 'bottom',\n PopperComponent: PopperComponentProp,\n PopperProps = {},\n slotProps = {},\n slots = {},\n title,\n TransitionComponent: TransitionComponentProp = Grow,\n TransitionProps\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n\n // to prevent runtime errors, developers will need to provide a child as a React element anyway.\n const children = /*#__PURE__*/React.isValidElement(childrenProp) ? childrenProp : /*#__PURE__*/_jsx(\"span\", {\n children: childrenProp\n });\n const theme = useTheme();\n const isRtl = theme.direction === 'rtl';\n const [childNode, setChildNode] = React.useState();\n const [arrowRef, setArrowRef] = React.useState(null);\n const ignoreNonTouchEvents = React.useRef(false);\n const disableInteractive = disableInteractiveProp || followCursor;\n const closeTimer = useTimeout();\n const enterTimer = useTimeout();\n const leaveTimer = useTimeout();\n const touchTimer = useTimeout();\n const [openState, setOpenState] = useControlled({\n controlled: openProp,\n default: false,\n name: 'Tooltip',\n state: 'open'\n });\n let open = openState;\n if (process.env.NODE_ENV !== 'production') {\n // eslint-disable-next-line react-hooks/rules-of-hooks\n const {\n current: isControlled\n } = React.useRef(openProp !== undefined);\n\n // eslint-disable-next-line react-hooks/rules-of-hooks\n React.useEffect(() => {\n if (childNode && childNode.disabled && !isControlled && title !== '' && childNode.tagName.toLowerCase() === 'button') {\n console.error(['MUI: You are providing a disabled `button` child to the Tooltip component.', 'A disabled element does not fire events.', \"Tooltip needs to listen to the child element's events to display the title.\", '', 'Add a simple wrapper element, such as a `span`.'].join('\\n'));\n }\n }, [title, childNode, isControlled]);\n }\n const id = useId(idProp);\n const prevUserSelect = React.useRef();\n const stopTouchInteraction = useEventCallback(() => {\n if (prevUserSelect.current !== undefined) {\n document.body.style.WebkitUserSelect = prevUserSelect.current;\n prevUserSelect.current = undefined;\n }\n touchTimer.clear();\n });\n React.useEffect(() => stopTouchInteraction, [stopTouchInteraction]);\n const handleOpen = event => {\n hystersisTimer.clear();\n hystersisOpen = true;\n\n // The mouseover event will trigger for every nested element in the tooltip.\n // We can skip rerendering when the tooltip is already open.\n // We are using the mouseover event instead of the mouseenter event to fix a hide/show issue.\n setOpenState(true);\n if (onOpen && !open) {\n onOpen(event);\n }\n };\n const handleClose = useEventCallback(\n /**\n * @param {React.SyntheticEvent | Event} event\n */\n event => {\n hystersisTimer.start(800 + leaveDelay, () => {\n hystersisOpen = false;\n });\n setOpenState(false);\n if (onClose && open) {\n onClose(event);\n }\n closeTimer.start(theme.transitions.duration.shortest, () => {\n ignoreNonTouchEvents.current = false;\n });\n });\n const handleEnter = event => {\n if (ignoreNonTouchEvents.current && event.type !== 'touchstart') {\n return;\n }\n\n // Remove the title ahead of time.\n // We don't want to wait for the next render commit.\n // We would risk displaying two tooltips at the same time (native + this one).\n if (childNode) {\n childNode.removeAttribute('title');\n }\n enterTimer.clear();\n leaveTimer.clear();\n if (enterDelay || hystersisOpen && enterNextDelay) {\n enterTimer.start(hystersisOpen ? enterNextDelay : enterDelay, () => {\n handleOpen(event);\n });\n } else {\n handleOpen(event);\n }\n };\n const handleLeave = event => {\n enterTimer.clear();\n leaveTimer.start(leaveDelay, () => {\n handleClose(event);\n });\n };\n const {\n isFocusVisibleRef,\n onBlur: handleBlurVisible,\n onFocus: handleFocusVisible,\n ref: focusVisibleRef\n } = useIsFocusVisible();\n // We don't necessarily care about the focusVisible state (which is safe to access via ref anyway).\n // We just need to re-render the Tooltip if the focus-visible state changes.\n const [, setChildIsFocusVisible] = React.useState(false);\n const handleBlur = event => {\n handleBlurVisible(event);\n if (isFocusVisibleRef.current === false) {\n setChildIsFocusVisible(false);\n handleLeave(event);\n }\n };\n const handleFocus = event => {\n // Workaround for https://github.com/facebook/react/issues/7769\n // The autoFocus of React might trigger the event before the componentDidMount.\n // We need to account for this eventuality.\n if (!childNode) {\n setChildNode(event.currentTarget);\n }\n handleFocusVisible(event);\n if (isFocusVisibleRef.current === true) {\n setChildIsFocusVisible(true);\n handleEnter(event);\n }\n };\n const detectTouchStart = event => {\n ignoreNonTouchEvents.current = true;\n const childrenProps = children.props;\n if (childrenProps.onTouchStart) {\n childrenProps.onTouchStart(event);\n }\n };\n const handleMouseOver = handleEnter;\n const handleMouseLeave = handleLeave;\n const handleTouchStart = event => {\n detectTouchStart(event);\n leaveTimer.clear();\n closeTimer.clear();\n stopTouchInteraction();\n prevUserSelect.current = document.body.style.WebkitUserSelect;\n // Prevent iOS text selection on long-tap.\n document.body.style.WebkitUserSelect = 'none';\n touchTimer.start(enterTouchDelay, () => {\n document.body.style.WebkitUserSelect = prevUserSelect.current;\n handleEnter(event);\n });\n };\n const handleTouchEnd = event => {\n if (children.props.onTouchEnd) {\n children.props.onTouchEnd(event);\n }\n stopTouchInteraction();\n leaveTimer.start(leaveTouchDelay, () => {\n handleClose(event);\n });\n };\n React.useEffect(() => {\n if (!open) {\n return undefined;\n }\n\n /**\n * @param {KeyboardEvent} nativeEvent\n */\n function handleKeyDown(nativeEvent) {\n // IE11, Edge (prior to using Bink?) use 'Esc'\n if (nativeEvent.key === 'Escape' || nativeEvent.key === 'Esc') {\n handleClose(nativeEvent);\n }\n }\n document.addEventListener('keydown', handleKeyDown);\n return () => {\n document.removeEventListener('keydown', handleKeyDown);\n };\n }, [handleClose, open]);\n const handleRef = useForkRef(children.ref, focusVisibleRef, setChildNode, ref);\n\n // There is no point in displaying an empty tooltip.\n // So we exclude all falsy values, except 0, which is valid.\n if (!title && title !== 0) {\n open = false;\n }\n const popperRef = React.useRef();\n const handleMouseMove = event => {\n const childrenProps = children.props;\n if (childrenProps.onMouseMove) {\n childrenProps.onMouseMove(event);\n }\n cursorPosition = {\n x: event.clientX,\n y: event.clientY\n };\n if (popperRef.current) {\n popperRef.current.update();\n }\n };\n const nameOrDescProps = {};\n const titleIsString = typeof title === 'string';\n if (describeChild) {\n nameOrDescProps.title = !open && titleIsString && !disableHoverListener ? title : null;\n nameOrDescProps['aria-describedby'] = open ? id : null;\n } else {\n nameOrDescProps['aria-label'] = titleIsString ? title : null;\n nameOrDescProps['aria-labelledby'] = open && !titleIsString ? id : null;\n }\n const childrenProps = _extends({}, nameOrDescProps, other, children.props, {\n className: clsx(other.className, children.props.className),\n onTouchStart: detectTouchStart,\n ref: handleRef\n }, followCursor ? {\n onMouseMove: handleMouseMove\n } : {});\n if (process.env.NODE_ENV !== 'production') {\n childrenProps['data-mui-internal-clone-element'] = true;\n\n // eslint-disable-next-line react-hooks/rules-of-hooks\n React.useEffect(() => {\n if (childNode && !childNode.getAttribute('data-mui-internal-clone-element')) {\n console.error(['MUI: The `children` component of the Tooltip is not forwarding its props correctly.', 'Please make sure that props are spread on the same element that the ref is applied to.'].join('\\n'));\n }\n }, [childNode]);\n }\n const interactiveWrapperListeners = {};\n if (!disableTouchListener) {\n childrenProps.onTouchStart = handleTouchStart;\n childrenProps.onTouchEnd = handleTouchEnd;\n }\n if (!disableHoverListener) {\n childrenProps.onMouseOver = composeEventHandler(handleMouseOver, childrenProps.onMouseOver);\n childrenProps.onMouseLeave = composeEventHandler(handleMouseLeave, childrenProps.onMouseLeave);\n if (!disableInteractive) {\n interactiveWrapperListeners.onMouseOver = handleMouseOver;\n interactiveWrapperListeners.onMouseLeave = handleMouseLeave;\n }\n }\n if (!disableFocusListener) {\n childrenProps.onFocus = composeEventHandler(handleFocus, childrenProps.onFocus);\n childrenProps.onBlur = composeEventHandler(handleBlur, childrenProps.onBlur);\n if (!disableInteractive) {\n interactiveWrapperListeners.onFocus = handleFocus;\n interactiveWrapperListeners.onBlur = handleBlur;\n }\n }\n if (process.env.NODE_ENV !== 'production') {\n if (children.props.title) {\n console.error(['MUI: You have provided a `title` prop to the child of .', `Remove this title prop \\`${children.props.title}\\` or the Tooltip component.`].join('\\n'));\n }\n }\n const popperOptions = React.useMemo(() => {\n var _PopperProps$popperOp;\n let tooltipModifiers = [{\n name: 'arrow',\n enabled: Boolean(arrowRef),\n options: {\n element: arrowRef,\n padding: 4\n }\n }];\n if ((_PopperProps$popperOp = PopperProps.popperOptions) != null && _PopperProps$popperOp.modifiers) {\n tooltipModifiers = tooltipModifiers.concat(PopperProps.popperOptions.modifiers);\n }\n return _extends({}, PopperProps.popperOptions, {\n modifiers: tooltipModifiers\n });\n }, [arrowRef, PopperProps]);\n const ownerState = _extends({}, props, {\n isRtl,\n arrow,\n disableInteractive,\n placement,\n PopperComponentProp,\n touch: ignoreNonTouchEvents.current\n });\n const classes = useUtilityClasses(ownerState);\n const PopperComponent = (_ref = (_slots$popper = slots.popper) != null ? _slots$popper : components.Popper) != null ? _ref : TooltipPopper;\n const TransitionComponent = (_ref2 = (_ref3 = (_slots$transition = slots.transition) != null ? _slots$transition : components.Transition) != null ? _ref3 : TransitionComponentProp) != null ? _ref2 : Grow;\n const TooltipComponent = (_ref4 = (_slots$tooltip = slots.tooltip) != null ? _slots$tooltip : components.Tooltip) != null ? _ref4 : TooltipTooltip;\n const ArrowComponent = (_ref5 = (_slots$arrow = slots.arrow) != null ? _slots$arrow : components.Arrow) != null ? _ref5 : TooltipArrow;\n const popperProps = appendOwnerState(PopperComponent, _extends({}, PopperProps, (_slotProps$popper = slotProps.popper) != null ? _slotProps$popper : componentsProps.popper, {\n className: clsx(classes.popper, PopperProps == null ? void 0 : PopperProps.className, (_ref6 = (_slotProps$popper2 = slotProps.popper) != null ? _slotProps$popper2 : componentsProps.popper) == null ? void 0 : _ref6.className)\n }), ownerState);\n const transitionProps = appendOwnerState(TransitionComponent, _extends({}, TransitionProps, (_slotProps$transition = slotProps.transition) != null ? _slotProps$transition : componentsProps.transition), ownerState);\n const tooltipProps = appendOwnerState(TooltipComponent, _extends({}, (_slotProps$tooltip = slotProps.tooltip) != null ? _slotProps$tooltip : componentsProps.tooltip, {\n className: clsx(classes.tooltip, (_ref7 = (_slotProps$tooltip2 = slotProps.tooltip) != null ? _slotProps$tooltip2 : componentsProps.tooltip) == null ? void 0 : _ref7.className)\n }), ownerState);\n const tooltipArrowProps = appendOwnerState(ArrowComponent, _extends({}, (_slotProps$arrow = slotProps.arrow) != null ? _slotProps$arrow : componentsProps.arrow, {\n className: clsx(classes.arrow, (_ref8 = (_slotProps$arrow2 = slotProps.arrow) != null ? _slotProps$arrow2 : componentsProps.arrow) == null ? void 0 : _ref8.className)\n }), ownerState);\n return /*#__PURE__*/_jsxs(React.Fragment, {\n children: [/*#__PURE__*/React.cloneElement(children, childrenProps), /*#__PURE__*/_jsx(PopperComponent, _extends({\n as: PopperComponentProp != null ? PopperComponentProp : Popper,\n placement: placement,\n anchorEl: followCursor ? {\n getBoundingClientRect: () => ({\n top: cursorPosition.y,\n left: cursorPosition.x,\n right: cursorPosition.x,\n bottom: cursorPosition.y,\n width: 0,\n height: 0\n })\n } : childNode,\n popperRef: popperRef,\n open: childNode ? open : false,\n id: id,\n transition: true\n }, interactiveWrapperListeners, popperProps, {\n popperOptions: popperOptions,\n children: ({\n TransitionProps: TransitionPropsInner\n }) => /*#__PURE__*/_jsx(TransitionComponent, _extends({\n timeout: theme.transitions.duration.shorter\n }, TransitionPropsInner, transitionProps, {\n children: /*#__PURE__*/_jsxs(TooltipComponent, _extends({}, tooltipProps, {\n children: [title, arrow ? /*#__PURE__*/_jsx(ArrowComponent, _extends({}, tooltipArrowProps, {\n ref: setArrowRef\n })) : null]\n }))\n }))\n }))]\n });\n});\nprocess.env.NODE_ENV !== \"production\" ? Tooltip.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the d.ts file and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * If `true`, adds an arrow to the tooltip.\n * @default false\n */\n arrow: PropTypes.bool,\n /**\n * Tooltip reference element.\n */\n children: elementAcceptingRef.isRequired,\n /**\n * Override or extend the styles applied to the component.\n */\n classes: PropTypes.object,\n /**\n * @ignore\n */\n className: PropTypes.string,\n /**\n * The components used for each slot inside.\n *\n * This prop is an alias for the `slots` prop.\n * It's recommended to use the `slots` prop instead.\n *\n * @default {}\n */\n components: PropTypes.shape({\n Arrow: PropTypes.elementType,\n Popper: PropTypes.elementType,\n Tooltip: PropTypes.elementType,\n Transition: PropTypes.elementType\n }),\n /**\n * The extra props for the slot components.\n * You can override the existing props or add new ones.\n *\n * This prop is an alias for the `slotProps` prop.\n * It's recommended to use the `slotProps` prop instead, as `componentsProps` will be deprecated in the future.\n *\n * @default {}\n */\n componentsProps: PropTypes.shape({\n arrow: PropTypes.object,\n popper: PropTypes.object,\n tooltip: PropTypes.object,\n transition: PropTypes.object\n }),\n /**\n * Set to `true` if the `title` acts as an accessible description.\n * By default the `title` acts as an accessible label for the child.\n * @default false\n */\n describeChild: PropTypes.bool,\n /**\n * Do not respond to focus-visible events.\n * @default false\n */\n disableFocusListener: PropTypes.bool,\n /**\n * Do not respond to hover events.\n * @default false\n */\n disableHoverListener: PropTypes.bool,\n /**\n * Makes a tooltip not interactive, i.e. it will close when the user\n * hovers over the tooltip before the `leaveDelay` is expired.\n * @default false\n */\n disableInteractive: PropTypes.bool,\n /**\n * Do not respond to long press touch events.\n * @default false\n */\n disableTouchListener: PropTypes.bool,\n /**\n * The number of milliseconds to wait before showing the tooltip.\n * This prop won't impact the enter touch delay (`enterTouchDelay`).\n * @default 100\n */\n enterDelay: PropTypes.number,\n /**\n * The number of milliseconds to wait before showing the tooltip when one was already recently opened.\n * @default 0\n */\n enterNextDelay: PropTypes.number,\n /**\n * The number of milliseconds a user must touch the element before showing the tooltip.\n * @default 700\n */\n enterTouchDelay: PropTypes.number,\n /**\n * If `true`, the tooltip follow the cursor over the wrapped element.\n * @default false\n */\n followCursor: PropTypes.bool,\n /**\n * This prop is used to help implement the accessibility logic.\n * If you don't provide this prop. It falls back to a randomly generated id.\n */\n id: PropTypes.string,\n /**\n * The number of milliseconds to wait before hiding the tooltip.\n * This prop won't impact the leave touch delay (`leaveTouchDelay`).\n * @default 0\n */\n leaveDelay: PropTypes.number,\n /**\n * The number of milliseconds after the user stops touching an element before hiding the tooltip.\n * @default 1500\n */\n leaveTouchDelay: PropTypes.number,\n /**\n * Callback fired when the component requests to be closed.\n *\n * @param {React.SyntheticEvent} event The event source of the callback.\n */\n onClose: PropTypes.func,\n /**\n * Callback fired when the component requests to be open.\n *\n * @param {React.SyntheticEvent} event The event source of the callback.\n */\n onOpen: PropTypes.func,\n /**\n * If `true`, the component is shown.\n */\n open: PropTypes.bool,\n /**\n * Tooltip placement.\n * @default 'bottom'\n */\n placement: PropTypes.oneOf(['bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n /**\n * The component used for the popper.\n * @default Popper\n */\n PopperComponent: PropTypes.elementType,\n /**\n * Props applied to the [`Popper`](/material-ui/api/popper/) element.\n * @default {}\n */\n PopperProps: PropTypes.object,\n /**\n * The extra props for the slot components.\n * You can override the existing props or add new ones.\n *\n * This prop is an alias for the `componentsProps` prop, which will be deprecated in the future.\n *\n * @default {}\n */\n slotProps: PropTypes.shape({\n arrow: PropTypes.object,\n popper: PropTypes.object,\n tooltip: PropTypes.object,\n transition: PropTypes.object\n }),\n /**\n * The components used for each slot inside.\n *\n * This prop is an alias for the `components` prop, which will be deprecated in the future.\n *\n * @default {}\n */\n slots: PropTypes.shape({\n arrow: PropTypes.elementType,\n popper: PropTypes.elementType,\n tooltip: PropTypes.elementType,\n transition: PropTypes.elementType\n }),\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Tooltip title. Zero-length titles string, undefined, null and false are never displayed.\n */\n title: PropTypes.node,\n /**\n * The component used for the transition.\n * [Follow this guide](/material-ui/transitions/#transitioncomponent-prop) to learn more about the requirements for this component.\n * @default Grow\n */\n TransitionComponent: PropTypes.elementType,\n /**\n * Props applied to the transition element.\n * By default, the element is based on this [`Transition`](http://reactcommunity.org/react-transition-group/transition/) component.\n */\n TransitionProps: PropTypes.object\n} : void 0;\nexport default Tooltip;","import '@/components/mui/menu-item.component.css';\nimport ArrowRightIcon from '@mui/icons-material/ArrowRight';\nimport {\n ListItemIcon as MuiListItemIcon,\n ListItemText as MuiListItemText,\n MenuItem as MuiMenuItem,\n} from '@mui/material';\nimport Tooltip from '@mui/material/Tooltip';\nimport { Localized, ReferencedItem, SingleColumnMenu } from 'platform-bible-utils';\nimport { MouseEvent, PropsWithChildren } from 'react';\n\ntype MenuItemInfoBase = {\n /** Text (displayable in the UI) as the name of the menu item */\n label: string;\n /** Text to display when the mouse hovers over the menu item */\n tooltip?: string;\n};\n\nexport type Command = MenuItemInfoBase & {\n /** Command to execute (string.string) */\n command: string;\n};\n\ntype SubMenu = MenuItemInfoBase & {\n /** Command to execute (string.string) */\n items: MenuItemInfo[];\n};\n\nexport interface CommandHandler {\n (command: Command): void;\n}\n\nexport type MenuPropsBase = {\n /*\n * The JSON defining the menu whose items are to be rendered. This will typically be one of the\n * menus in the \"defs\" in a Platform.Bible menu (see PlatformMenus). The schema for this is\n * menuDocumentSchema (at the end of menus.model.ts). Note that while this is a\n * \"SingleColumnMenu\", somewhat bizarrely, a MultiColumnMenu is a SingleColumnMenu, so it really\n * could be a MultiColumnMenu, in which case, column had better be defined so it can be used\n * to filter out the actual groups and items to display on the column.\n */\n menuDefinition: Localized;\n\n commandHandler: CommandHandler;\n\n /**\n * Additional action to perform when any menu item is clicked. Allows the caller to handle event\n * (e.g., to close the menu).\n */\n onClick?: (event: MouseEvent) => void;\n};\n\nexport type MenuItemListProps = MenuPropsBase & {\n /** Optional unique (column) identifier */\n columnId?: ReferencedItem;\n};\n\nexport type MenuItemProps = Omit &\n PropsWithChildren<{\n /** Optional unique identifier */\n id?: string;\n\n onClick: (event: MouseEvent) => void;\n }>;\n\ntype MenuItemInfo = (Command | SubMenu) & {\n /**\n * If specified, menu item will be inset if it does not have a leading icon.\n *\n * @default true\n */\n allowForLeadingIcons?: boolean;\n /**\n * If specified, the path to the icon image to display on the leading side of the menu text.\n *\n * @default undefined (no leading icon will be shown)\n */\n iconPathBefore?: string;\n /**\n * If specified, the path to the icon image to display on the trailing side of the menu text.\n *\n * @default undefined (no trailing icon will be shown)\n */\n iconPathAfter?: string;\n /**\n * If true, list item is focused during the first mount\n *\n * @default false\n */\n hasAutoFocus?: boolean;\n\n /** Additional css classes to help with unique styling of the menu item */\n className?: string;\n\n /**\n * If true, the menu item will appear disabled and it will not respond to clicks or mouse hovers.\n *\n * @default false\n */\n isDisabled?: boolean;\n\n /**\n * If true, compact vertical padding designed for keyboard and mouse input is used.\n *\n * @default true\n */\n isDense?: boolean;\n\n /**\n * If true, a right-arrow icon will be displayed (iconPathAfter, if specified, will be ignored).\n *\n * @default false\n */\n isSubMenuParent?: boolean;\n\n /**\n * If true, the left and right padding is removed\n *\n * @default false\n */\n hasDisabledGutters?: boolean;\n\n /**\n * If true, a 1px light border is added to bottom of menu item\n *\n * @default false\n */\n hasDivider?: boolean;\n\n /** Help identify which element has keyboard focus */\n focusVisibleClassName?: string;\n\n /** If it's a submenu, it should have the items property */\n items?: MenuItemInfo[];\n};\n\nfunction getIcon(icon: string | undefined, menuLabel: string, leading: boolean) {\n return icon ? (\n \n {`${leading\n \n ) : undefined;\n}\n\nexport default function MenuItem(props: MenuItemProps) {\n const {\n onClick,\n label,\n tooltip,\n allowForLeadingIcons = true,\n iconPathBefore = undefined,\n iconPathAfter = undefined,\n hasAutoFocus = false,\n className,\n isDisabled = false,\n isDense = true,\n isSubMenuParent = false,\n hasDisabledGutters = false,\n hasDivider = false,\n focusVisibleClassName,\n id,\n children,\n } = props;\n\n const menuItem = (\n \n {label ? (\n <>\n {getIcon(iconPathBefore, label, true)}\n \n {isSubMenuParent ? (\n \n \n \n ) : (\n getIcon(iconPathAfter, label, false)\n )}\n \n ) : (\n children\n )}\n \n );\n\n return tooltip ? (\n \n
    {menuItem}
    \n
    \n ) : (\n menuItem\n );\n}\n","import MenuItem, {\n MenuItemListProps,\n MenuItemProps,\n MenuPropsBase,\n} from '@/components/mui/menu-item.component';\nimport { Menu } from '@mui/material';\nimport {\n Localized,\n MenuGroupDetailsInSubMenu,\n MenuItemContainingCommand,\n MenuItemContainingSubmenu,\n OrderedExtensibleContainer,\n ReferencedItem,\n SingleColumnMenu,\n} from 'platform-bible-utils';\nimport { MouseEvent, useMemo, useState } from 'react';\n\n/**\n * All the exported types in this file should be regarded as \"internal\" (i.e., they should not be\n * exposed via index.ts).\n */\n\nexport type GroupedMenuPropsBase = MenuPropsBase & {\n /** Optional unique (column) identifier */\n columnId?: ReferencedItem;\n};\n\nexport type GroupedMenuItemListProps = MenuItemListProps & {\n /**\n * If the menuDefinition includes \"top-level\" groups (i.e., those that belong to a column as\n * opposed to those that belong to a submenu) that should not be included in the list, then this\n * array specifies which groups to include. Likewise, for a submenu, this list indicates which\n * groups are pertinent for that submenu. So then for a context menu this property need not be\n * specified since it is a top-level menu based on a \"true\" SingleColumnMenu (i.e., one that is\n * not a MultiColumnMenu).\n */\n includedGroups?: {\n id: string;\n group: Localized;\n }[];\n};\n\ninterface ItemInfo {\n item: Localized;\n isLastItemInGroup: boolean;\n}\n\ntype SubMenuProps = MenuPropsBase & {\n parentMenuItem: Localized;\n parentItemProps: Omit, 'iconPathAfter'>;\n};\n\nfunction getAllGroups(menuDefinition: Localized) {\n const groupEntries = Object.entries(menuDefinition.groups);\n // Convert array of entries to array of objects with id and group properties\n return groupEntries.map(([key, value]) => ({ id: key, group: value }));\n}\n\nfunction SubMenu(props: SubMenuProps) {\n const [anchorEl, setAnchorEl] = useState(undefined);\n\n const { parentMenuItem, parentItemProps, menuDefinition } = props;\n\n const handleParentMenuItemClick = (event: MouseEvent) => {\n setAnchorEl(event.currentTarget);\n };\n\n const handleClose = () => {\n setAnchorEl(undefined);\n };\n\n const renderSubMenuItems = () => {\n let includedGroups = getAllGroups(menuDefinition).filter((g) => 'menuItem' in g.group);\n\n // Ensure valid parent menu was provided. (If not, submenu will contain all groups!)\n if (!parentMenuItem?.id) throw new Error('A valid parent menu item is required for submenus.');\n\n // When laying out a submenu, only include groups associated with the provided parent menu.\n // Note: without the (annoying) redundant check that the included groups\n // have the menuItem field, TS doesn't think it exists.\n includedGroups = includedGroups.filter(\n (group) => 'menuItem' in group.group && group.group.menuItem === parentMenuItem.id,\n );\n\n return ;\n };\n\n return (\n <>\n \n \n {renderSubMenuItems()}\n \n \n );\n}\n\nconst getOrderedGroupItems = (\n groupId: string,\n allItems: Localized[],\n) => {\n // Filter items that belong to the specified group\n const itemsForGroup = allItems.filter((item) => item.group === groupId);\n // Sort items based on order\n const sortedItems = itemsForGroup.sort((a, b) => (a.order || 0) - (b.order || 0));\n return sortedItems;\n};\n\n/**\n * This component is internal; it does not need to be exposed to the outside world since it is not\n * useful on its own. It is used to generate and lay out the MenuItems that appear either on a\n * top-level menu (in a GridMenu or ContextMenu) or in a submenu.\n */\nexport default function GroupedMenuItemList(menuProps: GroupedMenuItemListProps) {\n const { menuDefinition, onClick, commandHandler, includedGroups } = menuProps;\n\n const { items, allowForLeadingIcons } = useMemo(() => {\n const groupsToInclude =\n includedGroups && includedGroups.length > 0\n ? includedGroups\n : // We're apparently laying out a single-column menu (presumably a context menu). In this\n // case, all groups should be included except ones that belong to a submenu.\n getAllGroups(menuDefinition).filter((g) => !('menuItem' in g.group));\n\n const sortedGroups = Object.values(groupsToInclude).sort(\n (a, b) => (a.group.order || 0) - (b.group.order || 0),\n );\n\n const itemArray: ItemInfo[] = [];\n\n sortedGroups.forEach((group) => {\n getOrderedGroupItems(group.id, menuDefinition.items).forEach((item) =>\n itemArray.push({ item, isLastItemInGroup: false }),\n );\n if (itemArray.length > 0) itemArray[itemArray.length - 1].isLastItemInGroup = true;\n });\n\n // No divider after last item in final group.\n if (itemArray.length > 0) itemArray[itemArray.length - 1].isLastItemInGroup = false;\n\n const allowSpaceForLeadingIcons = itemArray.some(\n (i) => 'iconPathBefore' in i.item && i.item.iconPathBefore,\n );\n\n return { items: itemArray, allowForLeadingIcons: allowSpaceForLeadingIcons };\n }, [includedGroups, menuDefinition]);\n\n // Create props for MenuItem component including setting hasDivider for the last item in a group\n const createMenuItemProps = ({ item, isLastItemInGroup }: ItemInfo) => {\n const menuItemProps = {\n className: 'papi-menu-item',\n label: item.label,\n tooltip: item.tooltip,\n iconPathBefore: 'iconPathBefore' in item ? item.iconPathBefore : undefined,\n iconPathAfter: 'iconPathAfter' in item ? item.iconPathAfter : undefined,\n hasDivider: isLastItemInGroup, // Set hasDivider to true for the last item in a group\n allowForLeadingIcons,\n };\n\n return menuItemProps;\n };\n\n const [firstItem] = items;\n\n if (!firstItem) return
    ;\n\n const divKey = firstItem.item.group;\n\n return (\n
    \n {items.map((itemInfo, index) => {\n const { item } = itemInfo;\n const menuItemProps = createMenuItemProps(itemInfo);\n if ('command' in item) {\n const key = item.group + index;\n return (\n ) => {\n onClick?.(event);\n commandHandler(item);\n }}\n {...menuItemProps}\n />\n );\n }\n return (\n \n );\n })}\n
    \n );\n}\n","import GroupedMenuItemList from '@/components/mui/grouped-menu-item-list.component';\nimport { MenuItemListProps } from '@/components/mui/menu-item.component';\nimport { MultiColumnMenu } from 'platform-bible-utils';\n\n/**\n * This component is internal; it does not need to be exposed to the outside world since it is not\n * useful on its own. Use either GridMenu or ContextMenu.\n */\nexport default function TopLevelMenu(props: MenuItemListProps) {\n const { menuDefinition, columnId } = props;\n\n const groupEntries = Object.entries(menuDefinition.groups);\n // Convert array of entries to array of objects with id and group properties\n const groups = groupEntries.map(([key, value]) => ({ id: key, group: value }));\n let includedGroups = groups.filter((g) => 'column' in g.group);\n\n // Check if column is provided and menuDefinition is a MultiColumnMenu\n if (\n columnId &&\n 'columns' in menuDefinition &&\n // Without this type assertion, TS doesn't know what columns is.\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n (menuDefinition as MultiColumnMenu).columns[columnId]\n ) {\n // When laying out a single column in a MultiColumnMenu, only include groups associated with\n // the provided column. Note: without the (annoying) redundant check that the included groups\n // have the colum field, TS doesn't think it exists.\n includedGroups = includedGroups.filter(\n (g) => 'column' in g.group && g.group.column === columnId,\n );\n }\n\n return ;\n}\n","import '@/components/mui/grid-menu.component.css';\nimport { GroupedMenuPropsBase } from '@/components/mui/grouped-menu-item-list.component';\nimport { CommandHandler } from '@/components/mui/menu-item.component';\nimport TopLevelMenu from '@/components/mui/top-level-menu.component';\nimport { Grid, List } from '@mui/material';\nimport {\n Localized,\n MenuColumnWithHeader,\n MultiColumnMenu,\n ReferencedItem,\n} from 'platform-bible-utils';\nimport { useMemo } from 'react';\n\ntype ColumnInfo = {\n /*\n * The ID (`${string}.${string}`) of a specific menu column.\n */\n id: ReferencedItem;\n\n /*\n * Metadata (label, order, etc.) for a specific menu column.\n */\n metadata: Localized;\n};\n\ntype MenuColumnProps = ColumnInfo &\n GroupedMenuPropsBase & {\n /** Additional css classes to help with unique styling of the menu column */\n className?: string;\n };\n\nexport type GridMenuInfo = {\n /** The menu object containing information about the columns, groups, and items to display. */\n multiColumnMenu: Localized;\n};\n\nexport type GridMenuProps = GridMenuInfo & {\n /** Optional unique identifier */\n id?: string;\n\n commandHandler: CommandHandler;\n\n /** Additional css classes to help with unique styling of the grid menu */\n className?: string;\n};\n\nfunction MenuColumn({\n commandHandler,\n menuDefinition,\n id,\n metadata,\n onClick,\n className,\n}: MenuColumnProps) {\n return (\n \n

    \n {metadata.label}\n

    \n {/* It would seem as though this List component were unnecessary, since it only contains one\n thing, but the \"dense\" property does affect the layout of the items (in a way I don't fully\n understand). There might be a better way. */}\n \n \n \n \n );\n}\n\nexport default function GridMenu({\n commandHandler,\n className,\n multiColumnMenu,\n id,\n}: GridMenuProps) {\n const { columns } = multiColumnMenu;\n\n const sortedColumns = useMemo(() => {\n const columnNumbers = new Map();\n Object.getOwnPropertyNames(columns).forEach((columnName: string) => {\n // We know for sure there is a (boolean) property 'isExtensible' that we are not interested in.\n if (columnName === 'isExtensible') return;\n // TS doesn't allow `columnName` above to be a ReferencedItem even though the type says it is\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const columnId = columnName as ReferencedItem;\n const column = columns[columnId];\n // As of right now (and hopefully forever after), all remaining properties of the\n // ColumnsWithHeaders object are columns whose property names are the IDs of the columns.\n // This is an additional (redundant) sanity check. Specifically we're interested in\n // MenuColumnWithHeader objects, which TypeScript now \"knows\" we have, but at runtime all we\n // can check for is that it's an object with a valid numeric order field. That's likely good\n // enough.\n if (\n typeof column === 'object' &&\n typeof column.order === 'number' &&\n !Number.isNaN(column.order)\n )\n columnNumbers.set(column.order, { id: columnId, metadata: column });\n else\n console.warn(\n `Property ${columnName} (${typeof column}) on menu ${id} is not a valid column and is being ignored. This might indicate data corruption`,\n );\n });\n\n // Extract values and sort them based on the 'order' property\n return Array.from(columnNumbers.values()).sort((a, b) => {\n return (a.metadata.order || 0) - (b.metadata.order || 0);\n });\n }, [columns, id]);\n\n // We might need something like this if we need to be able to prevent empty columns\n // sortedColumns.filter((c) => multiColumnMenu.groups.some((g) => 'column' in g && (g as .column)...\n\n return (\n \n {sortedColumns.map((col, index) => (\n \n ))}\n \n );\n}\n","import { useEffect, useRef, useState } from 'react';\n\nexport type UsePromiseOptions = {\n /**\n * Whether to leave the value as the most recent resolved promise value or set it back to\n * defaultValue while running the promise again. Defaults to true\n */\n preserveValue?: boolean;\n};\n\n/** Set up defaults for options for usePromise hook */\nfunction getUsePromiseOptionsDefaults(options: UsePromiseOptions): UsePromiseOptions {\n return {\n preserveValue: true,\n ...options,\n };\n}\n\n/**\n * Awaits a promise and returns a loading value while the promise is unresolved\n *\n * @param promiseFactoryCallback A function that returns the promise to await. If this callback is\n * undefined, the current value will be returned (defaultValue unless it was previously changed\n * and `options.preserveValue` is true), and there will be no loading.\n *\n * WARNING: MUST BE STABLE - const or wrapped in useCallback. The reference must not be updated\n * every render\n * @param defaultValue The initial value to return while first awaiting the promise. If\n * `options.preserveValue` is false, this value is also shown while awaiting the promise on\n * subsequent calls.\n *\n * Note: this parameter is internally assigned to a `ref`, so changing it will not cause any hooks\n * to re-run with its new value. This means that, if the `promiseFactoryCallback` changes and\n * `options.preserveValue` is `false`, the returned value will be set to the current\n * `defaultValue`. However, the returned value will not be updated if`defaultValue` changes.\n * @param options Various options for adjusting how this hook runs the `promiseFactoryCallback`\n *\n * Note: this parameter is internally assigned to a `ref`, so changing it will not cause any hooks\n * to re-run with its new value. However, the latest `options.preserveValue` will always be used\n * appropriately to determine whether to preserve the returned value when changing the\n * `promiseFactoryCallback`\n * @returns `[value, isLoading]`\n *\n * - `value`: the current value for the promise, either the defaultValue or the resolved promise value\n * - `isLoading`: whether the promise is waiting to be resolved\n */\nconst usePromise = (\n promiseFactoryCallback: (() => Promise) | undefined,\n defaultValue: T,\n options: UsePromiseOptions = {},\n): [value: T, isLoading: boolean] => {\n // Use defaultValue as a ref so it doesn't update dependency arrays\n const defaultValueRef = useRef(defaultValue);\n defaultValueRef.current = defaultValue;\n // Use options as a ref so it doesn't update dependency arrays\n const optionsDefaultedRef = useRef(options);\n optionsDefaultedRef.current = getUsePromiseOptionsDefaults(optionsDefaultedRef.current);\n\n const [value, setValue] = useState(() => defaultValueRef.current);\n const [isLoading, setIsLoading] = useState(true);\n useEffect(() => {\n let promiseIsCurrent = true;\n // If a promiseFactoryCallback was provided, we are loading. Otherwise, there is no loading to do\n setIsLoading(!!promiseFactoryCallback);\n (async () => {\n // If there is a callback to run, run it\n if (promiseFactoryCallback) {\n const result = await promiseFactoryCallback();\n // If the promise was not already replaced, update the value\n if (promiseIsCurrent) {\n setValue(() => result);\n setIsLoading(false);\n }\n }\n })();\n\n return () => {\n // Mark this promise as old and not to be used\n promiseIsCurrent = false;\n if (!optionsDefaultedRef.current.preserveValue) setValue(() => defaultValueRef.current);\n };\n }, [promiseFactoryCallback]);\n\n return [value, isLoading];\n};\nexport default usePromise;\n","\"use client\";\n\nimport createSvgIcon from './utils/createSvgIcon';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nexport default createSvgIcon( /*#__PURE__*/_jsx(\"path\", {\n d: \"M3 18h18v-2H3zm0-5h18v-2H3zm0-7v2h18V6z\"\n}), 'Menu');","import GridMenu from '@/components/mui/grid-menu.component';\nimport { Command, CommandHandler } from '@/components/mui/menu-item.component';\nimport usePromise from '@/hooks/use-promise.hook';\nimport { Menu as MenuIcon } from '@mui/icons-material';\nimport { Drawer, IconButton } from '@mui/material';\nimport { Localized, MultiColumnMenu } from 'platform-bible-utils';\nimport {\n MouseEvent,\n MutableRefObject,\n PropsWithChildren,\n useCallback,\n useEffect,\n useState,\n} from 'react';\n\nexport interface MultiColumnMenuProvider {\n (isSupportAndDevelopment: boolean): Promise>;\n}\n\nexport type HamburgerMenuButtonProps = PropsWithChildren & {\n /** The handler to use for menu commands (and eventually toolbar commands). */\n commandHandler: CommandHandler;\n\n /**\n * Optional reference to the \"div\" container that determines the where the menu should appear. If\n * not defined, then (1,1) used.\n */\n containerRef?: MutableRefObject;\n\n /**\n * The delegate to use to get the menu data. If not specified or if it returns undefined, the data\n * in normalMenu or fullMenu property will be used.\n */\n menuProvider?: MultiColumnMenuProvider;\n\n /**\n * The menu data to show when the menu is opened if the menuProvider property is not defined.\n * (This allows for a default or test-only static menu to be used.)\n */\n normalMenu?: Localized;\n\n /**\n * The menu data to show for \"full\" menu (when opened with the SHIFT key pressed) if the\n * menuProvider property is not defined. (This allows for a default or test-only static menu to be\n * used.)\n */\n fullMenu?: Localized;\n\n /** Additional css class(es) to help with unique styling of the sub-components */\n className?: string;\n\n /** Value to use as prefix for ARIA labels on interactive sub-components */\n ariaLabelPrefix?: string;\n};\n\nexport default function HamburgerMenuButton({\n menuProvider,\n normalMenu,\n fullMenu,\n commandHandler,\n containerRef,\n className,\n ariaLabelPrefix,\n children,\n}: HamburgerMenuButtonProps) {\n const [isMenuOpen, setMenuOpen] = useState(false);\n const [showFullMenu, setShowFullMenu] = useState(false);\n\n const handleMenuItemClick = useCallback(() => {\n if (isMenuOpen) setMenuOpen(false);\n setShowFullMenu(false);\n }, [isMenuOpen]);\n\n const handleMenuButtonClick = useCallback((e: MouseEvent) => {\n e.stopPropagation();\n setMenuOpen((prevIsOpen) => {\n const isOpening = !prevIsOpen;\n if (isOpening && e.shiftKey) setShowFullMenu(true);\n else if (!isOpening) setShowFullMenu(false);\n return isOpening;\n });\n }, []);\n\n const menuCommandHandler = useCallback(\n (command: Command) => {\n handleMenuItemClick();\n return commandHandler(command);\n },\n [commandHandler, handleMenuItemClick],\n );\n\n const [offset, setOffset] = useState({ top: 1, left: 1 });\n\n useEffect(() => {\n if (isMenuOpen) {\n const node = containerRef?.current;\n if (node) {\n const rect = node.getBoundingClientRect();\n const scrollTop = window.scrollY;\n const scrollLeft = window.scrollX;\n const top = rect.top + scrollTop + node.clientHeight;\n const left = rect.left + scrollLeft;\n setOffset({ top, left });\n }\n }\n }, [isMenuOpen, containerRef]);\n\n const [normalMenuData] = usePromise(\n useCallback(async () => {\n return menuProvider?.(false) ?? normalMenu;\n // isMenuOpen needs to be included for the menu contents to reevaluate when reopened\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [menuProvider, normalMenu, isMenuOpen]),\n normalMenu,\n );\n\n const [fullMenuData] = usePromise(\n useCallback(async () => {\n return menuProvider?.(true) ?? fullMenu ?? normalMenuData;\n // isMenuOpen needs to be included for the menu contents to reevaluate when reopened\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [menuProvider, fullMenu, normalMenuData, isMenuOpen]),\n fullMenu ?? normalMenuData,\n );\n\n const menu = showFullMenu && fullMenuData ? fullMenuData : normalMenuData;\n\n return (\n <>\n \n {children ?? }\n \n \n {menu ? (\n \n ) : undefined}\n \n \n );\n}\n","import '@/components/mui/icon-button.component.css';\nimport { IconButton as MuiIconButton } from '@mui/material';\nimport { MouseEventHandler, PropsWithChildren } from 'react';\n\nexport type IconButtonProps = PropsWithChildren<{\n /** Optional unique identifier */\n id?: string;\n /**\n * Required. Used as both the tooltip (aka, title) and the aria-label (used for accessibility,\n * testing, etc.), unless a distinct tooltip is supplied.\n */\n label: string;\n /**\n * Enabled status of button\n *\n * @default false\n */\n isDisabled?: boolean;\n /** Optional tooltip to display if different from the aria-label. */\n tooltip?: string;\n /** If true, no tooltip will be displayed. */\n isTooltipSuppressed?: boolean;\n /**\n * If given, uses a negative margin to counteract the padding on one side (this is often helpful\n * for aligning the left or right side of the icon with content above or below, without ruining\n * the border size and shape).\n *\n * @default false\n */\n adjustMarginToAlignToEdge?: 'end' | 'start' | false;\n /**\n * The size of the component. small is equivalent to the dense button styling.\n *\n * @default false\n */\n size: 'small' | 'medium' | 'large';\n /** Additional css classes to help with unique styling of the button */\n className?: string;\n /** Optional click handler */\n onClick?: MouseEventHandler;\n}>;\n\n/**\n * Iconic button a user can click to do something\n *\n * Thanks to MUI for heavy inspiration and documentation\n * https://mui.com/material-ui/getting-started/overview/\n */\nfunction IconButton({\n id,\n label,\n isDisabled = false,\n tooltip,\n isTooltipSuppressed = false,\n adjustMarginToAlignToEdge = false,\n size = 'medium',\n className,\n onClick,\n children,\n}: IconButtonProps) {\n return (\n \n {children /* the icon to display */}\n \n );\n}\n\nexport default IconButton;\n","import { cn } from '@/utils/shadcn-ui.util';\nimport { LoaderCircle, LucideProps } from 'lucide-react';\nimport { forwardRef } from 'react';\n\nexport type SpinnerProps = LucideProps;\n\nconst Spinner = forwardRef(({ className, ...props }, ref) => {\n return (\n \n );\n});\n\nSpinner.displayName = 'Spinner';\n\nexport default Spinner;\n","import { Input as ShadInput } from '@/components/shadcn-ui/input';\nimport { Label as ShadLabel } from '@/components/shadcn-ui/label';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { ChangeEventHandler, FocusEventHandler } from 'react';\n\nexport type TextFieldProps = {\n /** Optional unique identifier */\n id?: string;\n /**\n * If `true`, the component is disabled.\n *\n * @default false\n */\n isDisabled?: boolean;\n /**\n * If `true`, the label is displayed in an error state.\n *\n * @default false\n */\n hasError?: boolean;\n /**\n * If `true`, the input will take up the full width of its container.\n *\n * @default false\n */\n isFullWidth?: boolean;\n /** Text that gives the user instructions on what contents the TextField expects */\n helperText?: string;\n /** The title of the TextField */\n label?: string;\n /** The short hint displayed in the `input` before the user enters a value. */\n placeholder?: string;\n /**\n * If `true`, the label is displayed as required and the `input` element is required.\n *\n * @default false\n */\n isRequired?: boolean;\n /** Additional css classes to help with unique styling of the text field */\n className?: string;\n /** Starting value for the text field if it is not controlled */\n defaultValue?: string | number;\n /** Value of the text field if controlled */\n value?: string | number;\n /** Triggers when content of textfield is changed */\n onChange?: ChangeEventHandler;\n /** Triggers when textfield gets focus */\n onFocus?: FocusEventHandler;\n /** Triggers when textfield loses focus */\n onBlur?: FocusEventHandler;\n};\n\n/**\n * Text input field\n *\n * Thanks to Shadcn for heavy inspiration and documentation\n * https://ui.shadcn.com/docs/components/input#with-label\n */\nfunction TextField({\n id,\n isDisabled = false,\n hasError = false,\n isFullWidth = false,\n helperText,\n label,\n placeholder,\n isRequired = false,\n className,\n defaultValue,\n value,\n onChange,\n onFocus,\n onBlur,\n}: TextFieldProps) {\n return (\n
    \n {`${label}${isRequired ? '*' : ''}`}\n \n

    {helperText}

    \n
    \n );\n}\n\nexport default TextField;\n","import HamburgerMenuButton, {\n MultiColumnMenuProvider,\n} from '@/components/mui/hamburger-menu-button.component';\nimport { CommandHandler } from '@/components/mui/menu-item.component';\nimport '@/components/mui/toolbar.component.css';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { AppBar, Toolbar as MuiToolbar } from '@mui/material';\nimport { PropsWithChildren, useRef } from 'react';\n\nexport type ToolbarProps = PropsWithChildren<{\n /** The handler to use for menu commands (and eventually toolbar commands). */\n commandHandler: CommandHandler;\n\n /**\n * The optional delegate to use to get the menu data. If not specified, the \"hamburger\" menu will\n * not display.\n */\n menuProvider?: MultiColumnMenuProvider;\n\n /** Optional unique identifier */\n id?: string;\n\n /** Additional css classes to help with unique styling of the toolbar */\n className?: string;\n}>;\n\nexport default function Toolbar({\n menuProvider,\n commandHandler,\n className,\n id,\n children,\n}: ToolbarProps) {\n // This ref will always be defined\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const containerRef = useRef(undefined!);\n\n return (\n
    \n \n \n {menuProvider ? (\n \n ) : undefined}\n {children ?
    {children}
    : undefined}\n \n
    \n
    \n );\n}\n","import React from 'react';\nimport { cva, type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst alertVariants = cva(\n 'tw-relative tw-w-full tw-rounded-lg tw-border tw-p-4 [&>svg~*]:tw-pl-7 [&>svg+div]:tw-translate-y-[-3px] [&>svg]:tw-absolute [&>svg]:tw-left-4 [&>svg]:tw-top-4 [&>svg]:tw-text-foreground',\n {\n variants: {\n variant: {\n default: 'tw-bg-background tw-text-foreground',\n destructive:\n 'tw-border-destructive/50 tw-text-destructive dark:tw-border-destructive [&>svg]:tw-text-destructive',\n },\n },\n defaultVariants: {\n variant: 'default',\n },\n },\n);\n\nconst Alert = React.forwardRef<\n HTMLDivElement,\n React.HTMLAttributes & VariantProps\n>(({ className, variant, ...props }, ref) => (\n
    \n));\nAlert.displayName = 'Alert';\n\nconst AlertTitle = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n {/* added because of https://github.com/jsx-eslint/eslint-plugin-jsx-a11y/blob/main/docs/rules/heading-has-content.md */}\n {props.children}{' '}\n \n ),\n);\nAlertTitle.displayName = 'AlertTitle';\n\nconst AlertDescription = React.forwardRef<\n HTMLParagraphElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n
    \n));\nAlertDescription.displayName = 'AlertDescription';\n\nexport { Alert, AlertTitle, AlertDescription };\n","import { ComponentProps } from 'react';\nimport { toast as sonner, Toaster } from 'sonner';\n\ntype SonnerProps = ComponentProps;\n\nfunction Sonner({ ...props }: SonnerProps) {\n return (\n \n );\n}\n\n// The re-export of the sonner function was added manually\nexport { Sonner, sonner };\n","import React from 'react';\nimport * as SliderPrimitive from '@radix-ui/react-slider';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Slider = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n \n \n \n));\nSlider.displayName = SliderPrimitive.Root.displayName;\n\nexport { Slider };\n","import React from 'react';\nimport * as SwitchPrimitives from '@radix-ui/react-switch';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Switch = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n));\nSwitch.displayName = SwitchPrimitives.Root.displayName;\n\nexport { Switch };\n","import React from 'react';\nimport * as TabsPrimitive from '@radix-ui/react-tabs';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport const Tabs = TabsPrimitive.Root;\n\nexport type TabsListProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport type TabsTriggerProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport type TabsContentProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport const TabsList = React.forwardRef<\n React.ElementRef,\n TabsListProps\n>(({ className, ...props }, ref) => (\n \n));\nTabsList.displayName = TabsPrimitive.List.displayName;\n\nexport const TabsTrigger = React.forwardRef<\n React.ElementRef,\n TabsTriggerProps\n>(({ className, ...props }, ref) => (\n \n));\nTabsTrigger.displayName = TabsPrimitive.Trigger.displayName;\n\nexport const TabsContent = React.forwardRef<\n React.ElementRef,\n TabsContentProps\n>(({ className, ...props }, ref) => (\n \n));\nTabsContent.displayName = TabsPrimitive.Content.displayName;\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Download } from 'lucide-react';\n\ntype InstallButtonProps = {\n /** The installing boolean value determines the state of the button. */\n isInstalling: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n /** Optional text for the button. */\n buttonText?: string;\n} & ButtonProps;\n\n/**\n * The InstallButton component is a button designed for initiating installs. It includes visuals for\n * active installing and idle states.\n *\n * @param isInstalling The installing boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @param buttonText Optional text for the button.\n * @returns A install button.\n */\nexport default function InstallButton({\n isInstalling,\n handleClick,\n buttonText,\n className,\n ...props\n}: InstallButtonProps) {\n return (\n \n {isInstalling ? (\n \n ) : (\n <>\n \n {buttonText}\n \n )}\n \n );\n}\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\n\ntype EnableButtonProps = {\n /** The enabling boolean value determines the state of the button. */\n isEnabling: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n} & ButtonProps;\n\n/**\n * The EnableButton component is a button designed for initiating enabling of downloads. It includes\n * visuals for active enabling and idle states.\n *\n * @param isEnabling The enabling boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @returns A button that can be used to enable.\n */\nexport default function EnableButton({\n isEnabling,\n handleClick,\n className,\n ...props\n}: EnableButtonProps) {\n return (\n \n {isEnabling ? (\n <>\n \n Enabling...\n \n ) : (\n 'Enable'\n )}\n \n );\n}\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\n\ntype DisableButtonProps = {\n /** The disabling boolean value determines the state of the button. */\n isDisabling: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n} & ButtonProps;\n\n/**\n * The DisableButton component is a button designed for initiating disabling of downloads. It\n * includes visuals for active disabling and idle states.\n *\n * @param isDisabling The disabling boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @returns A button that can be used to disable.\n */\nexport default function DisableButton({\n isDisabling,\n handleClick,\n className,\n ...props\n}: DisableButtonProps) {\n return (\n \n {isDisabling ? (\n <>\n \n Disabling...\n \n ) : (\n 'Disable'\n )}\n \n );\n}\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\n\ntype UpdateButtonProps = {\n /** The updating boolean value determines the state of the button. */\n isUpdating: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n} & ButtonProps;\n\n/**\n * The UpdateButton component is a button designed for initiating updates for downloaded extensions.\n * It includes visuals for active updating and idle states.\n *\n * @param isUpdating The updating boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @returns A button that can be used to update.\n */\nexport default function UpdateButton({\n isUpdating,\n handleClick,\n className,\n ...props\n}: UpdateButtonProps) {\n return (\n \n {isUpdating ? (\n <>\n \n Updating...\n \n ) : (\n 'Update'\n )}\n \n );\n}\n","import { cn } from '@/utils/shadcn-ui.util';\nimport Markdown, { MarkdownToJSX } from 'markdown-to-jsx';\nimport { useMemo } from 'react';\n\ninterface MarkdownRendererProps {\n /** Optional unique identifier */\n id?: string;\n /** The markdown string to render */\n markdown: string;\n className?: string;\n /**\n * The [`target` attribute for `a` html\n * tags](https://developer.mozilla.org/en-US/docs/Web/HTML/Element/a#target). Defaults to not\n * adding a `target` to `a` tags\n */\n anchorTarget?: string;\n}\n\n/**\n * This component renders markdown content given a markdown string. It uses typography styles from\n * the platform.\n *\n * @param markdown The markdown string to render.\n * @param id Optional unique identifier\n * @returns A div containing the rendered markdown content.\n */\nexport default function MarkdownRenderer({\n id,\n markdown,\n className,\n anchorTarget,\n}: MarkdownRendererProps) {\n const options: MarkdownToJSX.Options = useMemo(\n () => ({\n overrides: {\n a: {\n props: {\n target: anchorTarget,\n },\n },\n },\n }),\n [anchorTarget],\n );\n return (\n
    \n {markdown}\n
    \n );\n}\n","import { Filter, ChevronDown } from 'lucide-react';\nimport { forwardRef } from 'react';\nimport { Button } from '@/components/shadcn-ui/button';\n\n/**\n * The FilterButton component is a button designed for initiating filtering of data. It is designed\n * to be used with the dropdown menu. It uses forwardRef to pass the button to the dropdown trigger\n * asChild.\n *\n * @returns A button that can be used to filter.\n */\nconst FilterButton = forwardRef((props, ref) => {\n return (\n \n \n Filter\n \n \n );\n});\n\nexport default FilterButton;\n","import {\n DropdownMenu,\n DropdownMenuTrigger,\n DropdownMenuContent,\n DropdownMenuLabel,\n DropdownMenuGroup,\n DropdownMenuCheckboxItem,\n DropdownMenuRadioItem,\n DropdownMenuSeparator,\n} from '@/components/shadcn-ui/dropdown-menu';\nimport FilterButton from './buttons/filter-button.component';\n\nexport enum DropdownMenuItemType {\n Check,\n Radio,\n}\n\nexport type DropdownItem = {\n /** The label is the text that will be displayed on the dropdown item. */\n label: string;\n /** The itemType determines the DropdownMenuItemType type as either Check or Radio. */\n itemType: DropdownMenuItemType;\n /** The onClick function is called when the item is clicked. */\n onClick: () => void;\n};\n\nexport type DropdownGroup = {\n /**\n * The label is the text that will be displayed on the dropdown group. It is used to categorize\n * the items in the group.\n */\n label: string;\n /** The items array contains the items that will be displayed in the dropdown group */\n items: DropdownItem[];\n};\n\nexport type FilterDropdownProps = {\n /** Object unique identifier */\n id?: string;\n /** The groups array contains the groups that will be displayed in the dropdown */\n groups: DropdownGroup[];\n}; // TODO: extend the props later\n\n/**\n * The FilterDropdown component is a dropdown designed for filtering content. It includes groups of\n * items that can be checkboxes or radio items.\n *\n * @param id Optional unique identifier\n * @param groups The groups array contains the groups that will be displayed in the dropdown\n * @returns A filter dropdown.\n */\nexport default function FilterDropdown({ id, groups }: FilterDropdownProps) {\n return (\n
    \n {/* TODO: remove this once the DropDown Menu shadcn has an id prop */}\n \n \n \n \n \n {groups.map((group) => (\n
    \n {group.label}\n \n {group.items.map((item) => (\n
    \n {item.itemType === DropdownMenuItemType.Check ? (\n \n {item.label}\n \n ) : (\n \n {item.label}\n \n )}\n
    \n ))}\n
    \n \n
    \n ))}\n
    \n
    \n
    \n );\n}\n","interface NoExtensionsFoundProps {\n /** Optional unique identifier */\n id?: string;\n /** The message to display */\n message: string;\n}\n/**\n * This component displays a message to the user when no extensions are found in the marketplace.\n *\n * @param id Optional unique identifier\n * @param message The message to display.\n * @returns {JSX.Element} - Returns the message component that displays the message to the user.\n */\nexport default function NoExtensionsFound({ id, message }: NoExtensionsFoundProps) {\n return (\n
    \n
    \n

    {message}

    \n
    \n
    \n );\n}\n","import { CircleHelp, Link as LucideLink, User } from 'lucide-react';\nimport { NumberFormat } from 'platform-bible-utils';\n\n/** Interface that stores the parameters passed to the More Info component */\ninterface MoreInfoProps {\n /** Optional unique identifier */\n id?: string;\n /** The category of the extension */\n category: string;\n /** The number of downloads for the extension */\n downloads: Record;\n /** The languages supported by the extension */\n languages: string[];\n /** The URL to the more info page of the extension */\n moreInfoUrl: string;\n}\n/**\n * This component displays the more info section of the extension which includes the category,\n * number of downloads, languages, and links to the website and support\n *\n * @param id Optional unique identifier\n * @param category The category of the extension\n * @param downloads The number of downloads for the extension\n * @param languages The languages supported by the extension\n * @param moreInfoUrl The URL to the more info page of the extension\n * @returns {JSX.Element} - Returns the more info component that displays the category, number of\n * downloads, languages, and links to the website and support\n */\nexport default function MoreInfo({\n id,\n category,\n downloads,\n languages,\n moreInfoUrl,\n}: MoreInfoProps) {\n /**\n * This constant formats the number of downloads into a more readable format.\n *\n * @example 1000 -> 1K\n *\n * @example 1000000 -> 1M\n *\n * @returns The formatted number of downloads\n */\n const numberFormatted = new NumberFormat('en', {\n notation: 'compact',\n compactDisplay: 'short',\n }).format(Object.values(downloads).reduce((a: number, b: number) => a + b, 0));\n\n /** This function scrolls the window to the bottom of the page. */\n const handleScrollToBottom = () => {\n window.scrollTo(0, document.body.scrollHeight);\n };\n\n return (\n \n
    \n
    \n {category}\n
    \n CATEGORY\n
    \n
    \n
    \n
    \n \n {numberFormatted}\n
    \n USERS\n
    \n
    \n
    \n
    \n {languages.slice(0, 3).map((locale) => (\n \n {locale.toUpperCase()}\n \n ))}\n
    \n {languages.length > 3 && (\n handleScrollToBottom()}\n className=\"tw-text-xs tw-text-gray-500 tw-underline\"\n >\n +{languages.length - 3} more languages\n \n )}\n
    \n
    \n
    \n \n Website\n \n \n \n Support\n \n \n
    \n
    \n );\n}\n","import { useState } from 'react';\n\nexport type VersionInformation = {\n /** Date the version was published */\n date: string;\n /** Description of the changes in the version */\n description: string;\n};\n\n/** Type to store the version history information */\nexport type VersionHistoryType = Record;\n\n/** Interface that stores the parameters passed to the Version History component */\ninterface VersionHistoryProps {\n /** Optional unique identifier */\n id?: string;\n /** Object containing the versions mapped with their information */\n versionHistory: VersionHistoryType;\n}\n\n/**\n * Component to render the version history information shown in the footer component. Lists the 5\n * most recent versions, with the options to show all versions by pressing a button.\n *\n * @param versionHistory Object containing the versions mapped with their information\n * @param id Optional unique identifier\n * @returns Rendered version history for the Footer component\n */\nexport default function VersionHistory({ id, versionHistory }: VersionHistoryProps) {\n const [showAllVersions, setShowAllVersions] = useState(false);\n const currentDate = new Date();\n\n /**\n * Function to format the time string for the version history in the form of 'X year(s) ago'.\n *\n * @param dateString ISO Date string to determine the time string from\n * @returns Formatted time string\n */\n function formatTimeString(dateString: string) {\n const date = new Date(dateString);\n const dateDiff = new Date(currentDate.getTime() - date.getTime());\n const yearDiff = dateDiff.getUTCFullYear() - 1970;\n const monthDiff = dateDiff.getUTCMonth();\n const dayDiff = dateDiff.getUTCDate() - 1;\n\n // Determines how long ago the version was published\n let timeString = '';\n if (yearDiff > 0) {\n timeString = `${yearDiff.toString()} year${yearDiff === 1 ? '' : 's'} ago`;\n } else if (monthDiff > 0) {\n timeString = `${monthDiff.toString()} month${monthDiff === 1 ? '' : 's'} ago`;\n } else if (dayDiff === 0) {\n timeString = 'today';\n } else {\n timeString = `${dayDiff.toString()} day${dayDiff === 1 ? '' : 's'} ago`;\n }\n\n return timeString;\n }\n\n // Sorts the version history by version number\n const sortedEntries = Object.entries(versionHistory).sort((a, b) => b[0].localeCompare(a[0]));\n\n return (\n
    \n

    What`s New

    \n
      \n {(showAllVersions ? sortedEntries : sortedEntries.slice(0, 5)).map((entry) => (\n
      \n
      \n
    • \n {entry[1].description}\n
    • \n
      \n
      \n
      Version {entry[0]}
      \n
      {formatTimeString(entry[1].date)}
      \n
      \n
      \n ))}\n
    \n {sortedEntries.length > 5 && (\n setShowAllVersions(!showAllVersions)}\n className=\"tw-text-xs tw-text-gray-500 tw-underline\"\n >\n {showAllVersions ? 'Show Less Version History' : 'Show All Version History'}\n \n )}\n
    \n );\n}\n","import { useMemo } from 'react';\nimport { formatBytes } from 'platform-bible-utils';\nimport VersionHistory, { VersionHistoryType } from './version-history.component';\n\n/** Interface to store the parameters passed to the Footer component */\ninterface FooterProps {\n /** Optional unique identifier */\n id?: string;\n /** Name of the publisher */\n publisherDisplayName: string;\n /** Size of the extension file in bytes */\n fileSize: number;\n /** List of language codes supported by the extension */\n locales: string[];\n /** Object containing the version history mapped with their information */\n versionHistory: VersionHistoryType;\n}\n\n/**\n * Component to render the footer for the extension details which contains information on the\n * publisher, version history, languages, and file size.\n *\n * @param id Optional unique identifier\n * @param publisherDisplayName Name of the publisher\n * @param fileSize Size of the extension file in bytes\n * @param locales List of language codes supported by the extension\n * @param versionHistory Object containing the version history mapped with their information\n * @returns The rendered Footer component\n */\nexport default function Footer({\n id,\n publisherDisplayName,\n fileSize,\n locales,\n versionHistory,\n}: FooterProps) {\n /** Formats the file size into a human-readable format */\n const formattedFileSize = useMemo(() => formatBytes(fileSize), [fileSize]);\n\n /**\n * This function gets the display names of the languages based on the language codes.\n *\n * @param codes The list of language codes\n * @returns The list of language names\n */\n const getLanguageNames = (codes: string[]) => {\n const displayNames = new Intl.DisplayNames(navigator.language, { type: 'language' });\n return codes.map((code) => displayNames.of(code));\n };\n\n const languageNames = getLanguageNames(locales);\n\n return (\n
    \n
    \n \n
    \n
    \n

    Information

    \n
    \n

    \n Publisher\n {publisherDisplayName}\n Size\n {formattedFileSize}\n

    \n
    \n

    \n Languages\n {languageNames.join(', ')}\n

    \n
    \n
    \n
    \n
    \n
    \n );\n}\n","import { PlatformEvent, PlatformEventHandler } from 'platform-bible-utils';\nimport { useEffect } from 'react';\n\n/**\n * Adds an event handler to an event so the event handler runs when the event is emitted. Use\n * `papi.network.getNetworkEvent` to use a networked event with this hook.\n *\n * @param event The event to subscribe to.\n *\n * - If event is a `PlatformEvent`, that event will be used\n * - If event is undefined, the callback will not be subscribed. Useful if the event is not yet\n * available for example\n *\n * @param eventHandler The callback to run when the event is emitted\n *\n * WARNING: MUST BE STABLE - const or wrapped in useCallback. The reference must not be updated\n * every render\n */\nconst useEvent = (\n event: PlatformEvent | undefined,\n eventHandler: PlatformEventHandler,\n) => {\n useEffect(() => {\n // Do nothing if the event is not provided (in case the event is not yet available, for example)\n if (!event) return () => {};\n\n const unsubscriber = event(eventHandler);\n return () => {\n unsubscriber();\n };\n }, [event, eventHandler]);\n};\nexport default useEvent;\n","import { useCallback, useEffect } from 'react';\nimport { PlatformEvent, PlatformEventAsync, PlatformEventHandler } from 'platform-bible-utils';\nimport usePromise from './use-promise.hook';\n\nconst noopUnsubscriber = () => false;\n\n/**\n * Adds an event handler to an asynchronously subscribing/unsubscribing event so the event handler\n * runs when the event is emitted. Use `papi.network.getNetworkEvent` to use a networked event with\n * this hook.\n *\n * @param event The asynchronously (un)subscribing event to subscribe to.\n *\n * - If event is a `PlatformEvent` or `PlatformEventAsync`, that event will be used\n * - If event is undefined, the callback will not be subscribed. Useful if the event is not yet\n * available for example\n *\n * @param eventHandler The callback to run when the event is emitted\n *\n * WARNING: MUST BE STABLE - const or wrapped in useCallback. The reference must not be updated\n * every render\n */\nconst useEventAsync = (\n event: PlatformEvent | PlatformEventAsync | undefined,\n eventHandler: PlatformEventHandler,\n) => {\n // Subscribe to the event asynchronously\n const [unsubscribe] = usePromise(\n useCallback(async () => {\n // Do nothing if the event is not provided (in case the event is not yet available, for example)\n if (!event) return noopUnsubscriber;\n\n // Wrap subscribe and unsubscribe in promises to allow normal events to be used as well\n const unsub = await Promise.resolve(event(eventHandler));\n return async () => unsub();\n }, [eventHandler, event]),\n noopUnsubscriber,\n // We want the unsubscriber to return to default value immediately upon changing subscription\n // So the useEffect below will unsubscribe asap\n { preserveValue: false },\n );\n\n // Unsubscribe from the event asynchronously (but we aren't awaiting the unsub)\n useEffect(() => {\n return () => {\n if (unsubscribe !== noopUnsubscriber) {\n unsubscribe();\n }\n };\n }, [unsubscribe]);\n};\n\nexport default useEventAsync;\n"],"names":["twMergeCustom","extendTailwindMerge","cn","inputs","clsx","Input","React","className","type","props","ref","jsx","BookChapterInput","forwardRef","handleSearch","handleKeyDown","handleOnClick","handleSubmit","jsxs","ShadInput","event","e","History","P","R","s","n","N","B","O","S","K","g","k","x","T","X","V","w","L","G","A","H","C","I","y","q","U","m","l","h","c","E","D","i","a","o","u","v","f","d","b","J","DropdownMenu","DropdownMenuPrimitive","DropdownMenuTrigger","DropdownMenuGroup","DropdownMenuPortal","DropdownMenuSub","DropdownMenuRadioGroup","DropdownMenuSubTrigger","inset","children","ChevronRight","DropdownMenuSubContent","DropdownMenuContent","sideOffset","DropdownMenuItem","DropdownMenuCheckboxItem","checked","Check","DropdownMenuRadioItem","Circle","DropdownMenuLabel","DropdownMenuSeparator","DropdownMenuShortcut","BookMenuItem","bookId","handleSelectBook","isSelected","handleHighlightBook","bookType","ShadDropdownMenuItem","Canon","ChapterSelect","handleSelectChapter","endChapter","activeChapter","highlightedChapter","handleHighlightedChapter","chapters","_","handleMouse","useCallback","chapterNumber","chapter","GoToMenuItem","handleSort","handleLocationHistory","handleBookmarks","ShadDropdownMenuLabel","ArrowDownWideNarrow","Clock","Bookmark","ALL_BOOK_IDS","BOOK_TYPE_LABELS","BOOK_TYPE_ARRAY","SCROLL_OFFSET","SEARCH_QUERY_FORMATS","fetchGroupedBooks","fetchEndChapter","getChaptersForBook","getAllEnglishNames","isValidBookEnglishName","bookName","getBookIdFromEnglishName","formattedBookName","BookChapterControl","scrRef","searchQuery","setSearchQuery","useState","selectedBookId","setSelectedBookId","setHighlightedChapter","highlightedBookId","setHighlightedBookId","isContentOpen","setIsContentOpen","isContentOpenDelayed","setIsContentOpenDelayed","inputRef","useRef","contentRef","menuItemRef","fetchFilteredBooks","englishNameLowerCase","normalizedQuery","handleSearchInput","searchString","shouldPreventAutoClosing","controlMenuState","open","updateReference","shouldClose","verse","handleInputSubmit","format","matches","book","englishName","handleKeyDownInput","handleKeyDownContent","key","handleKeyDownMenuItem","chapterOffSet","useEffect","useLayoutEffect","scrollTimeout","scrollPosition","ShadDropdownMenu","ShadDropdownMenuTrigger","ShadDropdownMenuContent","bookTypeIndex","element","ShadDropdownMenuSeparator","buttonVariants","cva","Button","variant","size","asChild","Slot","labelVariants","Label","LabelPrimitive","RadioGroup","RadioGroupPrimitive","RadioGroupItem","Popover","PopoverPrimitive","PopoverTrigger","PopoverContent","align","DialogPortal","DialogPrimitive","DialogOverlay","DialogContent","DialogTitle","DialogDescription","Command","CommandPrimitive","CommandInput","Search","CommandList","CommandEmpty","CommandGroup","CommandSeparator","CommandItem","getOptionLabelDefault","option","ComboBox","id","options","buttonClassName","popoverContentClassName","value","onChange","getOptionLabel","buttonPlaceholder","textPlaceholder","commandEmptyMessage","buttonVariant","dir","isDisabled","setOpen","ChevronsUpDown","ChapterRangeSelector","startChapter","handleSelectStartChapter","handleSelectEndChapter","chapterCount","chapterOptions","useMemo","index","Fragment","BookSelectionMode","BOOK_SELECTOR_STRING_KEYS","localizeString","strings","BookSelector","handleBookSelectionModeChange","currentBookName","onSelectBooks","selectedBookIds","localizedStrings","currentBookText","chooseText","chooseBooksText","bookSelectionMode","setBookSelectionMode","onSelectionModeChange","newMode","DataTableViewOptions","table","FilterIcon","column","Select","SelectPrimitive","SelectGroup","SelectValue","SelectTrigger","ChevronDown","SelectScrollUpButton","ChevronUp","SelectScrollDownButton","SelectContent","position","SelectLabel","SelectItem","SelectSeparator","DataTablePagination","pageSize","ArrowLeftIcon","ChevronLeftIcon","ChevronRightIcon","ArrowRightIcon","Table","stickyHeader","TableHeader","TableBody","TableFooter","TableRow","TableHead","TableCell","TableCaption","DataTable","columns","data","enablePagination","showPaginationControls","showColumnVisibilityControls","onRowClickHandler","sorting","setSorting","columnFilters","setColumnFilters","columnVisibility","setColumnVisibility","rowSelection","setRowSelection","useReactTable","getCoreRowModel","getPaginationRowModel","getSortedRowModel","getFilteredRowModel","headerGroup","header","flexRender","_a","row","cell","OccurrencesTable","occurrenceData","setScriptureReference","referenceHeaderText","occurrenceHeaderText","occurrences","uniqueOccurrences","occurrence","uniqueOccurrence","deepEqual","Checkbox","CheckboxPrimitive","getLinesFromUSFM","text","getNumberFromUSFM","regex","match","getBookNumFromId","getStatusForItem","item","approvedItems","unapprovedItems","toggleVariants","Toggle","TogglePrimitive","ToggleGroupContext","ToggleGroup","ToggleGroupPrimitive","ToggleGroupItem","context","getSortingIcon","sortDirection","ArrowUpIcon","ArrowDownIcon","ArrowUpDownIcon","inventoryItemColumn","itemLabel","inventoryAdditionalItemColumn","additionalItemLabel","additionalItemIndex","inventoryCountColumn","countLabel","statusChangeHandler","changedItems","newStatus","onApprovedItemsChange","onUnapprovedItemsChange","newApprovedItems","validItem","newUnapprovedItems","unapprovedItem","inventoryStatusColumn","statusLabel","status","CircleCheckIcon","CircleXIcon","CircleHelpIcon","INVENTORY_STRING_KEYS","filterItemData","itemData","statusFilter","textFilter","filteredItemData","createTableData","scriptureRef","itemRegex","tableData","currentBook","currentChapter","currentVerse","line","items","itemIndex","existingItem","tableEntry","newReference","substring","newItem","Inventory","scriptureReference","extractItems","additionalItemsLabels","scope","onScopeChange","allItemsText","approvedItemsText","unapprovedItemsText","unknownItemsText","scopeBookText","scopeChapterText","scopeVerseText","filterText","showAdditionalItemsText","showAdditionalItems","setShowAdditionalItems","setStatusFilter","setTextFilter","selectedItem","setSelectedItem","reducedTableData","newTableData","firstItem","existingEntry","newTableEntry","filteredTableData","allColumns","numberOfAdditionalItems","additionalColumns","_b","rowClickHandler","newSelection","handleScopeChange","handleStatusFilterChange","SearchBar","onSearch","placeholder","isFullWidth","handleInputChange","VerticalTabs","TabsPrimitive","VerticalTabsList","VerticalTabsTrigger","VerticalTabsContent","TabNavigationContentSearch","tabList","searchPlaceholder","headerTitle","isSearchBarFullWidth","direction","tab","Separator","orientation","decorative","SeparatorPrimitive","Sheet","SheetPrimitive","SheetPortal","SheetOverlay","sheetVariants","SheetContent","side","SheetTitle","SheetDescription","Skeleton","TooltipProvider","TooltipPrimitive","Tooltip","TooltipTrigger","TooltipContent","MOBILE_BREAKPOINT","useIsMobile","isMobile","setIsMobile","mql","SIDEBAR_COOKIE_NAME","SIDEBAR_COOKIE_MAX_AGE","SIDEBAR_WIDTH","SIDEBAR_WIDTH_MOBILE","SIDEBAR_WIDTH_ICON","SIDEBAR_KEYBOARD_SHORTCUT","SidebarContext","useSidebar","SidebarProvider","defaultOpen","openProp","setOpenProp","style","openMobile","setOpenMobile","_open","_setOpen","isOpen","openState","toggleSidebar","state","contextValue","Sidebar","collapsible","SidebarTrigger","onClick","PanelLeft","SidebarRail","SidebarInset","SidebarInput","SidebarHeader","SidebarFooter","SidebarSeparator","SidebarContent","SidebarGroup","SidebarGroupLabel","SidebarGroupAction","SidebarGroupContent","SidebarMenu","SidebarMenuItem","sidebarMenuButtonVariants","SidebarMenuButton","isActive","tooltip","Comp","button","SidebarMenuAction","showOnHover","SidebarMenuBadge","SidebarMenuSkeleton","showIcon","width","SidebarMenuSub","SidebarMenuSubItem","SidebarMenuSubButton","SettingsSidebar","extensionLabels","projectOptions","handleSelectSidebarItem","selectedSidebarItem","handleSelectItem","projectId","getProjectNameFromProjectId","project","label","selectedProjectName","SettingsSidebarContentSearch","scrBookColId","scrRefColId","typeColId","detailsColId","defaultScrRefColumnName","defaultScrBookGroupName","defaultTypeColumnName","defaultDetailsColumnName","getColumns","colInfo","showSourceColumn","showSrcCol","info","formatScrRef","compareScrRefs","toRefOrRange","scriptureSelection","offsetStart","offsetEnd","scrRefToBBBCCCVVV","getRowKey","ScriptureResultsViewer","sources","showColumnHeaders","scriptureReferenceColumnName","scriptureBookGroupName","typeColumnName","detailsColumnName","onRowSelected","grouping","setGrouping","scriptureResults","source","getExpandedRowModel","getGroupedRowModel","selectedRows","keys","selectedRow","scrBookGroupName","typeGroupName","groupingOptions","handleSelectChange","selectedGrouping","handleRowClick","getEvenOrOddBandingStyle","getIndent","groupingState","rowIndex","ChevronLeft","DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS","getLocalizeKeyForScrollGroupId","ScrollGroupSelector","availableScrollGroupIds","scrollGroupId","onChangeScrollGroupId","localizedStringsDefaulted","localizedStringKey","localizedStringValue","newScrollGroupString","scrollGroupOptionId","SettingsList","SettingsListItem","primary","secondary","isLoading","loadingMessage","SettingsListHeader","includeSeparator","Card","CardHeader","CardTitle","CardDescription","CardContent","CardFooter","SettingsCard","settingsGroupLabel","settingsGroupDescription","Checklist","listItems","selectedListItems","handleSelectListItem","createLabel","_interopRequireDefault","obj","module","chainPropTypes","propType1","propType2","args","_extends","target","isPlainObject","prototype","deepClone","output","deepmerge","p","r","t","z","reactIs_production_min","hasSymbol","REACT_ELEMENT_TYPE","REACT_PORTAL_TYPE","REACT_FRAGMENT_TYPE","REACT_STRICT_MODE_TYPE","REACT_PROFILER_TYPE","REACT_PROVIDER_TYPE","REACT_CONTEXT_TYPE","REACT_ASYNC_MODE_TYPE","REACT_CONCURRENT_MODE_TYPE","REACT_FORWARD_REF_TYPE","REACT_SUSPENSE_TYPE","REACT_SUSPENSE_LIST_TYPE","REACT_MEMO_TYPE","REACT_LAZY_TYPE","REACT_BLOCK_TYPE","REACT_FUNDAMENTAL_TYPE","REACT_RESPONDER_TYPE","REACT_SCOPE_TYPE","isValidElementType","typeOf","object","$$typeof","$$typeofType","AsyncMode","ConcurrentMode","ContextConsumer","ContextProvider","Element","ForwardRef","Lazy","Memo","Portal","Profiler","StrictMode","Suspense","hasWarnedAboutDeprecatedIsAsyncMode","isAsyncMode","isConcurrentMode","isContextConsumer","isContextProvider","isElement","isForwardRef","isFragment","isLazy","isMemo","isPortal","isProfiler","isStrictMode","isSuspense","reactIs_development","reactIsModule","require$$0","require$$1","getOwnPropertySymbols","hasOwnProperty","propIsEnumerable","toObject","val","shouldUseNative","test1","test2","order2","test3","letter","objectAssign","from","to","symbols","ReactPropTypesSecret","ReactPropTypesSecret_1","has","printWarning","loggedTypeFailures","message","checkPropTypes","typeSpecs","values","location","componentName","getStack","typeSpecName","error","err","ex","stack","checkPropTypes_1","ReactIs","assign","require$$2","require$$3","require$$4","emptyFunctionThatReturnsNull","factoryWithTypeCheckers","isValidElement","throwOnDirectAccess","ITERATOR_SYMBOL","FAUX_ITERATOR_SYMBOL","getIteratorFn","maybeIterable","iteratorFn","ANONYMOUS","ReactPropTypes","createPrimitiveTypeChecker","createAnyTypeChecker","createArrayOfTypeChecker","createElementTypeChecker","createElementTypeTypeChecker","createInstanceTypeChecker","createNodeChecker","createObjectOfTypeChecker","createEnumTypeChecker","createUnionTypeChecker","createShapeTypeChecker","createStrictShapeTypeChecker","is","PropTypeError","createChainableTypeChecker","validate","manualPropTypeCallCache","manualPropTypeWarningCount","checkType","isRequired","propName","propFullName","secret","cacheKey","chainedCheckType","expectedType","propValue","propType","getPropType","preciseType","getPreciseType","typeChecker","expectedClass","expectedClassName","actualClassName","getClassName","expectedValues","valuesString","arrayOfTypeCheckers","checker","getPostfixForTypeWarning","expectedTypes","checkerResult","expectedTypesMessage","isNode","invalidValidatorError","shapeTypes","allKeys","iterator","step","entry","isSymbol","emptyFunction","emptyFunctionWithReset","factoryWithThrowingShims","shim","getShim","propTypesModule","isClassComponent","elementType","acceptingRef","safePropName","warningHint","elementAcceptingRef","PropTypes","elementAcceptingRef$1","specialProperty","exactProp","propTypes","unsupportedProps","prop","formatMuiErrorMessage","code","url","REACT_SERVER_CONTEXT_TYPE","REACT_OFFSCREEN_TYPE","enableScopeAPI","enableCacheElement","enableTransitionTracing","enableLegacyHidden","enableDebugTracing","REACT_MODULE_REFERENCE","SuspenseList","hasWarnedAboutDeprecatedIsConcurrentMode","isSuspenseList","fnNameMatchRegex","getFunctionName","fn","getFunctionComponentName","Component","fallback","getWrappedName","outerType","innerType","wrapperName","functionName","getDisplayName","HTMLElementType","refType","refType$1","capitalize","string","_formatMuiErrorMessage","createChainedFunction","funcs","acc","func","debounce","wait","timeout","debounced","later","deprecatedPropType","validator","reason","componentNameSafe","propFullNameSafe","isMuiElement","muiNames","_muiName","_element$type","ownerDocument","node","ownerWindow","requirePropFactory","componentNameInError","prevPropTypes","requiredProp","defaultTypeChecker","typeCheckerResult","setRef","useEnhancedEffect","useEnhancedEffect$1","globalId","useGlobalId","idOverride","defaultId","setDefaultId","maybeReactUseId","useId","reactId","unsupportedProp","useControlled","controlled","defaultProp","name","isControlled","valueState","setValue","defaultValue","setValueIfUncontrolled","newValue","useEventCallback","useForkRef","refs","instance","UNINITIALIZED","useLazyRef","init","initArg","EMPTY","useOnMount","Timeout","delay","useTimeout","hadKeyboardEvent","hadFocusVisibleRecently","hadFocusVisibleRecentlyTimeout","inputTypesWhitelist","focusTriggersKeyboardModality","tagName","handlePointerDown","handleVisibilityChange","prepare","doc","isFocusVisible","useIsFocusVisible","isFocusVisibleRef","handleBlurVisible","handleFocusVisible","resolveProps","defaultProps","defaultSlotProps","slotProps","slotPropName","composeClasses","slots","getUtilityClass","classes","slot","utilityClass","defaultGenerator","createClassNameGenerator","generate","generator","ClassNameGenerator","ClassNameGenerator$1","globalStateClasses","generateUtilityClass","globalStatePrefix","globalStateClass","generateUtilityClasses","result","clamp","min","max","_objectWithoutPropertiesLoose","excluded","sourceKeys","_excluded","sortBreakpointsValues","breakpointsAsArray","breakpoint1","breakpoint2","createBreakpoints","breakpoints","unit","other","sortedValues","up","down","between","start","end","endIndex","only","not","keyIndex","shape","shape$1","responsivePropType","responsivePropType$1","merge","defaultBreakpoints","handleBreakpoints","styleFromPropValue","theme","themeBreakpoints","breakpoint","mediaKey","cssKey","createEmptyBreakpointObject","breakpointsInput","_breakpointsInput$key","breakpointStyleKey","removeUnusedBreakpoints","breakpointKeys","breakpointOutput","getPath","path","checkVars","getStyleValue","themeMapping","transform","propValueFinal","userValue","cssProperty","themeKey","memoize","cache","arg","properties","directions","aliases","getCssProperties","property","marginKeys","paddingKeys","spacingKeys","createUnaryUnit","_getPath","themeSpacing","abs","createUnarySpacing","getValue","transformer","transformed","getStyleFromPropValue","cssProperties","resolveCssProperty","margin","padding","createSpacing","spacingInput","spacing","argsInput","argument","compose","styles","handlers","borderTransform","createBorderStyle","border","borderTop","borderRight","borderBottom","borderLeft","borderColor","borderTopColor","borderRightColor","borderBottomColor","borderLeftColor","outline","outlineColor","borderRadius","gap","columnGap","rowGap","gridColumn","gridRow","gridAutoFlow","gridAutoColumns","gridAutoRows","gridTemplateColumns","gridTemplateRows","gridTemplateAreas","gridArea","paletteTransform","color","bgcolor","backgroundColor","sizingTransform","maxWidth","_props$theme","_props$theme2","breakpointsValues","minWidth","height","maxHeight","minHeight","boxSizing","defaultSxConfig","defaultSxConfig$1","objectsHaveSameKeys","objects","union","callIfFn","maybeFn","unstable_createStyleFunctionSx","getThemeValue","config","styleFunctionSx","_theme$unstable_sxCon","sx","traverse","sxInput","sxObject","emptyBreakpoints","breakpointsKeys","css","styleKey","styleFunctionSx$1","applyStyles","createTheme","paletteInput","shapeInput","muiTheme","isObjectEmpty","useTheme","defaultTheme","contextTheme","ThemeContext","systemDefaultTheme","useThemeWithoutDefault","_excluded2","_excluded3","isEmpty","isStringTag","tag","shouldForwardProp","lowercaseFirstLetter","resolveTheme","themeId","defaultOverridesResolver","processStyleArg","callableStyle","_ref","ownerState","resolvedStylesArg","resolvedStyle","variants","isMatch","createStyled","input","rootShouldForwardProp","slotShouldForwardProp","systemSx","inputOptions","processStyles","componentSlot","inputSkipVariantsResolver","inputSkipSx","overridesResolver","skipVariantsResolver","skipSx","shouldForwardPropOption","defaultStyledResolver","styledEngineStyled","transformStyleArg","stylesArg","muiStyledResolver","styleArg","expressions","transformedStyleArg","expressionsWithDefaultTheme","styleOverrides","resolvedStyleOverrides","slotKey","slotStyle","_theme$components","themeVariants","numOfCustomFnsApplied","placeholders","displayName","getThemeProps","params","useThemeProps","clampWrapper","hexToRgb","re","colors","decomposeColor","marker","colorSpace","recomposeColor","hslToRgb","rgb","getLuminance","getContrastRatio","foreground","background","lumA","lumB","alpha","darken","coefficient","lighten","createMixins","mixins","common","common$1","grey","grey$1","purple","purple$1","red","red$1","orange","orange$1","blue","blue$1","lightBlue","lightBlue$1","green","green$1","light","dark","addLightOrDark","intent","shade","tonalOffset","tonalOffsetLight","tonalOffsetDark","getDefaultPrimary","mode","getDefaultSecondary","getDefaultError","getDefaultInfo","getDefaultSuccess","getDefaultWarning","createPalette","palette","contrastThreshold","success","warning","getContrastText","contrastText","contrast","augmentColor","mainShade","lightShade","darkShade","modes","round","caseAllCaps","defaultFontFamily","createTypography","typography","fontFamily","fontSize","fontWeightLight","fontWeightRegular","fontWeightMedium","fontWeightBold","htmlFontSize","allVariants","pxToRem2","coef","pxToRem","buildVariant","fontWeight","lineHeight","letterSpacing","casing","shadowKeyUmbraOpacity","shadowKeyPenumbraOpacity","shadowAmbientShadowOpacity","createShadow","px","shadows","shadows$1","easing","duration","formatMs","milliseconds","getAutoHeightDuration","constant","createTransitions","inputTransitions","mergedEasing","mergedDuration","durationOption","easingOption","isString","isNumber","animatedProp","zIndex","zIndex$1","mixinsInput","transitionsInput","typographyInput","systemTheme","systemCreateTheme","stateClasses","component","child","stateClass","defaultTheme$1","THEME_ID","systemUseThemeProps","styled","styled$1","getSvgIconUtilityClass","useUtilityClasses","SvgIconRoot","_theme$transitions","_theme$transitions$cr","_theme$transitions2","_theme$typography","_theme$typography$pxT","_theme$typography2","_theme$typography2$px","_theme$typography3","_theme$typography3$px","_palette$ownerState$c","_palette","_palette2","_palette3","SvgIcon","inProps","htmlColor","inheritViewBox","titleAccess","viewBox","hasSvgAsChild","more","_jsxs","_jsx","SvgIcon$1","createSvgIcon","unstable_ClassNameGenerator","exports","_utils","ArrowRight","default_1","_createSvgIcon","_jsxRuntime","isHostComponent","appendOwnerState","otherProps","defaultContextValue","ClassNameConfiguratorContext","useClassNamesOverride","disableDefaultClasses","extractEventHandlers","excludeKeys","resolveComponentProps","componentProps","slotState","omitEventHandlers","mergeSlotProps","parameters","getSlotProps","additionalProps","externalSlotProps","externalForwardedProps","joinedClasses","mergedStyle","eventHandlers","componentsPropsWithoutEventHandlers","otherPropsWithoutEventHandlers","internalSlotProps","useSlotProps","_parameters$additiona","skipResolvingSlotProps","rest","resolvedComponentsProps","mergedProps","internalRef","GLOBAL_CLASS_PREFIX","buildStateClass","buildSlotClass","getContainer","container","forwardedRef","disablePortal","mountNode","setMountNode","handleRef","newProps","ReactDOM","top","bottom","right","left","auto","basePlacements","clippingParents","viewport","popper","reference","variationPlacements","placement","placements","beforeRead","read","afterRead","beforeMain","main","afterMain","beforeWrite","write","afterWrite","modifierPhases","getNodeName","getWindow","OwnElement","isHTMLElement","isShadowRoot","attributes","effect","_ref2","initialStyles","styleProperties","attribute","applyStyles$1","getBasePlacement","getUAString","uaData","isLayoutViewport","getBoundingClientRect","includeScale","isFixedStrategy","clientRect","scaleX","scaleY","visualViewport","addVisualOffsets","getLayoutRect","contains","parent","rootNode","next","getComputedStyle","isTableElement","getDocumentElement","getParentNode","getTrueOffsetParent","getContainingBlock","isFirefox","isIE","elementCss","currentNode","getOffsetParent","window","offsetParent","getMainAxisFromPlacement","within","mathMax","mathMin","withinMaxClamp","getFreshSideObject","mergePaddingObject","paddingObject","expandToHashMap","hashMap","toPaddingObject","arrow","_state$modifiersData$","arrowElement","popperOffsets","basePlacement","axis","isVertical","len","arrowRect","minProp","maxProp","endDiff","startDiff","arrowOffsetParent","clientSize","centerToReference","center","offset","axisProp","_options$element","arrow$1","getVariation","unsetSides","roundOffsetsByDPR","win","dpr","mapToStyles","_Object$assign2","popperRect","variation","offsets","gpuAcceleration","adaptive","roundOffsets","isFixed","_offsets$x","_offsets$y","_ref3","hasX","hasY","sideX","sideY","heightProp","widthProp","offsetY","offsetX","commonStyles","_ref4","_Object$assign","computeStyles","_ref5","_options$gpuAccelerat","_options$adaptive","_options$roundOffsets","computeStyles$1","passive","_options$scroll","scroll","_options$resize","resize","scrollParents","scrollParent","eventListeners","hash","getOppositePlacement","matched","getOppositeVariationPlacement","getWindowScroll","scrollLeft","scrollTop","getWindowScrollBarX","getViewportRect","strategy","html","layoutViewport","getDocumentRect","_element$ownerDocumen","winScroll","body","isScrollParent","_getComputedStyle","overflow","overflowX","overflowY","getScrollParent","listScrollParents","list","isBody","updatedList","rectToClientRect","rect","getInnerBoundingClientRect","getClientRectFromMixedType","clippingParent","getClippingParents","canEscapeClipping","clipperElement","getClippingRect","boundary","rootBoundary","mainClippingParents","firstClippingParent","clippingRect","accRect","computeOffsets","commonX","commonY","mainAxis","detectOverflow","_options","_options$placement","_options$strategy","_options$boundary","_options$rootBoundary","_options$elementConte","elementContext","_options$altBoundary","altBoundary","_options$padding","altContext","clippingClientRect","referenceClientRect","popperClientRect","elementClientRect","overflowOffsets","offsetData","multiply","computeAutoPlacement","flipVariations","_options$allowedAutoP","allowedAutoPlacements","allPlacements","allowedPlacements","overflows","getExpandedFallbackPlacements","oppositePlacement","flip","_options$mainAxis","checkMainAxis","_options$altAxis","checkAltAxis","specifiedFallbackPlacements","_options$flipVariatio","preferredPlacement","isBasePlacement","fallbackPlacements","referenceRect","checksMap","makeFallbackChecks","firstFittingPlacement","_basePlacement","isStartVariation","mainVariationSide","altVariationSide","checks","check","numberOfChecks","_loop","_i","fittingPlacement","_ret","flip$1","getSideOffsets","preventedOffsets","isAnySideFullyClipped","hide","referenceOverflow","popperAltOverflow","referenceClippingOffsets","popperEscapeOffsets","isReferenceHidden","hasPopperEscaped","hide$1","distanceAndSkiddingToXY","rects","invertDistance","skidding","distance","_options$offset","_data$state$placement","offset$1","popperOffsets$1","getAltAxis","preventOverflow","_options$tether","tether","_options$tetherOffset","tetherOffset","altAxis","tetherOffsetValue","normalizedTetherOffsetValue","offsetModifierState","_offsetModifierState$","mainSide","altSide","additive","minLen","maxLen","arrowPaddingObject","arrowPaddingMin","arrowPaddingMax","arrowLen","minOffset","maxOffset","clientOffset","offsetModifierValue","tetherMin","tetherMax","preventedOffset","_offsetModifierState$2","_mainSide","_altSide","_offset","_len","_min","_max","isOriginSide","_offsetModifierValue","_tetherMin","_tetherMax","_preventedOffset","preventOverflow$1","getHTMLElementScroll","getNodeScroll","isElementScaled","getCompositeRect","elementOrVirtualElement","isOffsetParentAnElement","offsetParentIsScaled","documentElement","order","modifiers","map","visited","modifier","sort","requires","dep","depModifier","orderModifiers","orderedModifiers","phase","pending","resolve","mergeByName","merged","current","existing","DEFAULT_OPTIONS","areValidElements","_key","popperGenerator","generatorOptions","_generatorOptions","_generatorOptions$def","defaultModifiers","_generatorOptions$def2","defaultOptions","effectCleanupFns","isDestroyed","setOptionsAction","cleanupModifierEffects","runModifierEffects","_state$elements","_state$orderedModifie","_state$orderedModifie2","_ref$options","cleanupFn","noopFn","createPopper","COMPONENT_NAME","getPopperUtilityClass","flipPlacement","resolveAnchorEl","anchorEl","isVirtualElement","defaultPopperOptions","PopperTooltip","_slots$root","initialPlacement","popperOptions","popperRefProp","TransitionProps","tooltipRef","ownRef","popperRef","handlePopperRef","handlePopperRefRef","rtlPlacement","setPlacement","resolvedAnchorElement","setResolvedAnchorElement","handlePopperUpdate","box","popperModifiers","childProps","Root","rootProps","Popper","containerProp","keepMounted","transition","exited","setExited","handleEnter","handleExited","resolvedAnchorEl","display","transitionProps","useThemeSystem","_setPrototypeOf","_inheritsLoose","subClass","superClass","setPrototypeOf","timeoutsShape","TransitionGroupContext","forceReflow","UNMOUNTED","EXITED","ENTERING","ENTERED","EXITING","Transition","_React$Component","_this","parentGroup","appear","initialStatus","prevState","nextIn","_proto","prevProps","nextStatus","exit","enter","mounting","_this2","appearing","maybeNode","maybeAppearing","timeouts","enterTimeout","_this3","nextState","callback","_this4","active","handler","doesNotHaveTimeoutOrListener","maybeNextCallback","_this$props","pt","noop","Transition$1","reflow","getTransitionProps","_style$transitionDura","_style$transitionTimi","getScale","isWebKit154","Grow","addEndListener","inProp","onEnter","onEntered","onEntering","onExit","onExited","onExiting","TransitionComponent","timer","autoTimeout","nodeRef","normalizedTransitionCallback","maybeIsAppearing","handleEntering","isAppearing","transitionDuration","transitionTimingFunction","handleEntered","handleExiting","handleExit","Grow$1","PopperRoot","BasePopper","components","componentsProps","RootComponent","Popper$1","getTooltipUtilityClass","tooltipClasses","tooltipClasses$1","disableInteractive","touch","TooltipPopper","TooltipTooltip","TooltipArrow","hystersisOpen","hystersisTimer","cursorPosition","composeEventHandler","eventHandler","_slots$popper","_slots$transition","_slots$tooltip","_slots$arrow","_slotProps$popper","_ref6","_slotProps$popper2","_slotProps$transition","_slotProps$tooltip","_ref7","_slotProps$tooltip2","_slotProps$arrow","_ref8","_slotProps$arrow2","childrenProp","describeChild","disableFocusListener","disableHoverListener","disableInteractiveProp","disableTouchListener","enterDelay","enterNextDelay","enterTouchDelay","followCursor","idProp","leaveDelay","leaveTouchDelay","onClose","onOpen","PopperComponentProp","PopperProps","title","TransitionComponentProp","isRtl","childNode","setChildNode","arrowRef","setArrowRef","ignoreNonTouchEvents","closeTimer","enterTimer","leaveTimer","touchTimer","setOpenState","prevUserSelect","stopTouchInteraction","handleOpen","handleClose","handleLeave","focusVisibleRef","setChildIsFocusVisible","handleBlur","handleFocus","detectTouchStart","childrenProps","handleMouseOver","handleMouseLeave","handleTouchStart","handleTouchEnd","nativeEvent","handleMouseMove","nameOrDescProps","titleIsString","interactiveWrapperListeners","_PopperProps$popperOp","tooltipModifiers","PopperComponent","TooltipComponent","ArrowComponent","popperProps","tooltipProps","tooltipArrowProps","TransitionPropsInner","Tooltip$1","getIcon","icon","menuLabel","leading","MuiListItemIcon","MenuItem","allowForLeadingIcons","iconPathBefore","iconPathAfter","hasAutoFocus","isDense","isSubMenuParent","hasDisabledGutters","hasDivider","focusVisibleClassName","menuItem","MuiMenuItem","MuiListItemText","getAllGroups","menuDefinition","SubMenu","setAnchorEl","parentMenuItem","parentItemProps","handleParentMenuItemClick","renderSubMenuItems","includedGroups","group","GroupedMenuItemList","Menu","getOrderedGroupItems","groupId","allItems","menuProps","commandHandler","groupsToInclude","sortedGroups","itemArray","allowSpaceForLeadingIcons","createMenuItemProps","isLastItemInGroup","divKey","itemInfo","menuItemProps","TopLevelMenu","columnId","MenuColumn","metadata","Grid","List","GridMenu","multiColumnMenu","sortedColumns","columnNumbers","columnName","col","getUsePromiseOptionsDefaults","usePromise","promiseFactoryCallback","defaultValueRef","optionsDefaultedRef","setIsLoading","promiseIsCurrent","MenuIcon","HamburgerMenuButton","menuProvider","normalMenu","fullMenu","containerRef","ariaLabelPrefix","isMenuOpen","setMenuOpen","showFullMenu","setShowFullMenu","handleMenuItemClick","handleMenuButtonClick","prevIsOpen","isOpening","menuCommandHandler","command","setOffset","normalMenuData","fullMenuData","menu","IconButton","Drawer","isTooltipSuppressed","adjustMarginToAlignToEdge","MuiIconButton","Spinner","LoaderCircle","TextField","hasError","helperText","onFocus","onBlur","ShadLabel","Toolbar","AppBar","MuiToolbar","alertVariants","Alert","AlertTitle","AlertDescription","Sonner","Toaster","Slider","SliderPrimitive","Switch","SwitchPrimitives","Tabs","TabsList","TabsTrigger","TabsContent","InstallButton","isInstalling","handleClick","buttonText","Download","EnableButton","isEnabling","DisableButton","isDisabling","UpdateButton","isUpdating","MarkdownRenderer","markdown","anchorTarget","Markdown","FilterButton","Filter","DropdownMenuItemType","DropdownMenuItemType2","FilterDropdown","groups","NoExtensionsFound","MoreInfo","category","downloads","languages","moreInfoUrl","numberFormatted","NumberFormat","handleScrollToBottom","User","locale","LucideLink","CircleHelp","VersionHistory","versionHistory","showAllVersions","setShowAllVersions","currentDate","formatTimeString","dateString","date","dateDiff","yearDiff","monthDiff","dayDiff","timeString","sortedEntries","Footer","publisherDisplayName","fileSize","locales","formattedFileSize","formatBytes","languageNames","codes","displayNames","useEvent","unsubscriber","noopUnsubscriber","useEventAsync","unsubscribe","unsub"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAGA,MAAMA,KAAgBC,GAAoB,EAAE,QAAQ,MAAO,CAAA;AAyDpD,SAASC,KAAMC,GAAsB;AACnC,SAAAH,GAAcI,GAAK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;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","x_google_ignoreList":[3,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,83,84,85,86,87,88,89,90,91,92,93,94,95,96,97,98,99,100,101,102,103,104,105,106,107,108,109,110,111,112,113,114,115,116,117,118,119,120,121,122,123,124,125,126,127,128,129,130,131,132,133,134,135,136,137,138,139,140,141,142,143,144,145,146,147,148,149,150,151,152,153,154,155,156,157,158,159,160,161,162,163,164,165,166,167,168,169,170,171,172,173,174,175,176,177,178,179,180,181,182,183,184,185,186,187,188,189,190,191,192,193,194,195,196,197,198,199,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,230]} \ No newline at end of file diff --git a/lib/platform-bible-react/src/components/advanced/settings-components/settings-card.component.tsx b/lib/platform-bible-react/src/components/advanced/settings-components/settings-card.component.tsx index ee92194ca8..9ce28a9ee1 100644 --- a/lib/platform-bible-react/src/components/advanced/settings-components/settings-card.component.tsx +++ b/lib/platform-bible-react/src/components/advanced/settings-components/settings-card.component.tsx @@ -3,20 +3,27 @@ import { CardContent } from '@mui/material'; import { PropsWithChildren } from 'react'; type SettingsCardProps = PropsWithChildren & { + /** Optional id for testing */ + id?: string; + + /** Label of the settings group */ settingsGroupLabel: string; - settingsGroupDescription: string; + + /** Optional description of the settings group */ + settingsGroupDescription?: string; }; export default function SettingsCard({ + id, settingsGroupLabel, settingsGroupDescription, children, }: SettingsCardProps) { return ( - + {settingsGroupLabel} - {settingsGroupDescription} + {settingsGroupDescription && {settingsGroupDescription}} {children} diff --git a/lib/platform-bible-react/src/components/advanced/settings-components/settings-sidebar-content-search.component.tsx b/lib/platform-bible-react/src/components/advanced/settings-components/settings-sidebar-content-search.component.tsx index 201c3ec4c2..868ac81b07 100644 --- a/lib/platform-bible-react/src/components/advanced/settings-components/settings-sidebar-content-search.component.tsx +++ b/lib/platform-bible-react/src/components/advanced/settings-components/settings-sidebar-content-search.component.tsx @@ -1,34 +1,32 @@ import { SidebarInset, SidebarProvider } from '@/components/shadcn-ui/sidebar'; -// import { ProjectSettingProperties, SettingProperties } from 'platform-bible-utils'; import { PropsWithChildren } from 'react'; -import SettingsSidebar from './settings-sidebar.component'; +import SettingsSidebar, { SettingsSidebarProps } from './settings-sidebar.component'; -export type SettingsSidebarContentSearchProps = { - /** Text direction ltr or rtl */ - direction?: 'ltr' | 'rtl'; +export type SettingsSidebarContentSearchProps = SettingsSidebarProps & + PropsWithChildren & { + /** Optional id for testing */ + id?: string; - extensionLabels: string[]; - // projectLabels: string[]; - handleSelectSidebarItem: (key: string, isProjectSetting: boolean) => void; - // renderSettingsProperties: (extension: string) => SettingProperties; - // renderProjectSettingsProperties: (project: string) => ProjectSettingProperties; -} & PropsWithChildren; + /** Text direction ltr or rtl */ + direction?: 'ltr' | 'rtl'; + }; export default function SettingsSidebarContentSearch({ + id, direction = 'ltr', extensionLabels, - // projectLabels, + projectOptions, children, handleSelectSidebarItem, - // renderSettingsProperties, - // renderProjectSettingsProperties. + selectedSidebarItem, }: SettingsSidebarContentSearchProps) { return ( - + {children} diff --git a/lib/platform-bible-react/src/components/advanced/settings-components/settings-sidebar.component.tsx b/lib/platform-bible-react/src/components/advanced/settings-components/settings-sidebar.component.tsx index 19140bcd82..f96ada612f 100644 --- a/lib/platform-bible-react/src/components/advanced/settings-components/settings-sidebar.component.tsx +++ b/lib/platform-bible-react/src/components/advanced/settings-components/settings-sidebar.component.tsx @@ -1,4 +1,4 @@ -import { useState } from 'react'; +import ComboBox, { ComboBoxOption } from '@/components/basics/combo-box.component'; import { Sidebar, SidebarContent, @@ -8,33 +8,54 @@ import { SidebarMenu, SidebarMenuItem, SidebarMenuButton, -} from '../../shadcn-ui/sidebar'; +} from '@/components/shadcn-ui/sidebar'; +import { useCallback } from 'react'; + +export type SelectedSettingsSidebarItem = { + label: string; + projectId?: string; +}; + +export type ProjectOptions = { projectId: string; projectName: string }; export type SettingsSidebarProps = { - /** Optional id */ + /** Optional id for testing */ id?: string; - /** Extension labels to list in sidebar */ + /** Extension labels from contribution */ extensionLabels: string[]; - /** Project labels to list in sidebar */ - // projectLabels: string[]; + /** Project names and ids */ + projectOptions: ProjectOptions[]; - handleSelectSidebarItem: (key: string, isProjectSetting: boolean) => void; + /** Handler for selecting a sidebar item */ + handleSelectSidebarItem: (key: string, projectId?: string) => void; + + /** The current selected value in the sidebar */ + selectedSidebarItem: SelectedSettingsSidebarItem | undefined; }; export default function SettingsSidebar({ id, extensionLabels, - // projectLabels, + projectOptions, handleSelectSidebarItem, + selectedSidebarItem, }: SettingsSidebarProps) { - const [selectedItem, setSelectedItem] = useState(); + const handleSelectItem = useCallback( + (item: string, projectId?: string) => { + handleSelectSidebarItem(item, projectId); + }, + [handleSelectSidebarItem], + ); - const handleSelectItem = (item: string, isProjectSetting: boolean) => { - setSelectedItem(item); - handleSelectSidebarItem(item, isProjectSetting); - }; + const getProjectNameFromProjectId = useCallback( + (projectId: string) => { + const project = projectOptions.find((option) => option.projectId === projectId); + return project ? project.projectName : projectId; + }, + [projectOptions], + ); return ( @@ -46,8 +67,10 @@ export default function SettingsSidebar({ {extensionLabels.map((label) => ( handleSelectItem(label, false)} - isActive={label === selectedItem} + onClick={() => handleSelectItem(label)} + isActive={ + !selectedSidebarItem?.projectId && label === selectedSidebarItem?.label + } > {label} @@ -56,24 +79,26 @@ export default function SettingsSidebar({ - - {/* + Projects - - {projectLabels.map((label) => ( - - handleSelectItem(label)} - isActive={label === selectedItem} - > - {label} - - - ))} - + option.projectId)} + getOptionLabel={(projectId: ComboBoxOption) => { + // This function expects a ComboBoxOption, but we know it is a string + // eslint-disable-next-line no-type-assertion/no-type-assertion + return getProjectNameFromProjectId(projectId as string); + }} + buttonPlaceholder="Type or select project" + onChange={(projectId: string) => { + const selectedProjectName = getProjectNameFromProjectId(projectId); + handleSelectItem(selectedProjectName, projectId); + }} + value={selectedSidebarItem?.projectId ?? undefined} + /> - */} + ); diff --git a/lib/platform-bible-react/src/components/basics/chapter-range-selector.component.tsx b/lib/platform-bible-react/src/components/basics/chapter-range-selector.component.tsx index c0298fe36f..2f21e8952f 100644 --- a/lib/platform-bible-react/src/components/basics/chapter-range-selector.component.tsx +++ b/lib/platform-bible-react/src/components/basics/chapter-range-selector.component.tsx @@ -44,7 +44,7 @@ export default function ChapterRangeSelector({ option.toString()} @@ -55,7 +55,7 @@ export default function ChapterRangeSelector({ option.toString()} diff --git a/lib/platform-bible-react/src/components/basics/combo-box.component.tsx b/lib/platform-bible-react/src/components/basics/combo-box.component.tsx index 7dd94e7db5..47e4cb7366 100644 --- a/lib/platform-bible-react/src/components/basics/combo-box.component.tsx +++ b/lib/platform-bible-react/src/components/basics/combo-box.component.tsx @@ -21,8 +21,10 @@ export type ComboBoxProps = { /** Text label title for combobox */ /** List of available options for the dropdown menu */ options?: readonly T[]; - /** Additional css classes to help with unique styling of the combo box */ - className?: string; + /** Additional css classes to help with unique styling of the combo box button */ + buttonClassName?: string; + /** Additional css classes to help with unique styling of the combo box popover */ + popoverContentClassName?: string; /** * The selected value that the combo box currently holds. Must be shallow equal to one of the * options entries. @@ -67,7 +69,8 @@ function getOptionLabelDefault(option: ComboBoxOption): string { function ComboBox({ id, options = [], - className, + buttonClassName, + popoverContentClassName, value, onChange = () => {}, getOptionLabel = getOptionLabelDefault, @@ -89,7 +92,7 @@ function ComboBox({ role="combobox" aria-expanded={open} id={id} - className={cn('tw-w-[200px] tw-justify-between', className)} + className={cn('tw-w-[200px] tw-justify-between', buttonClassName)} disabled={isDisabled} > @@ -98,7 +101,7 @@ function ComboBox({ - + {commandEmptyMessage} diff --git a/lib/platform-bible-react/src/index.ts b/lib/platform-bible-react/src/index.ts index deaba3e190..0e6a0d1acd 100644 --- a/lib/platform-bible-react/src/index.ts +++ b/lib/platform-bible-react/src/index.ts @@ -43,6 +43,8 @@ export { export { default as SettingsSidebar, type SettingsSidebarProps, + type ProjectOptions, + type SelectedSettingsSidebarItem, } from './components/advanced/settings-components/settings-sidebar.component'; export { default as SettingsSidebarContentSearch } from './components/advanced/settings-components/settings-sidebar-content-search.component'; export { default as ScriptureResultsViewer } from './components/advanced/scripture-results-viewer/scripture-results-viewer.component'; diff --git a/src/renderer/components/settings-tabs/settings-components/user-setting.component.tsx b/src/renderer/components/settings-tabs/settings-components/other-setting.component.tsx similarity index 62% rename from src/renderer/components/settings-tabs/settings-components/user-setting.component.tsx rename to src/renderer/components/settings-tabs/settings-components/other-setting.component.tsx index cb98c42fcb..50b684a963 100644 --- a/src/renderer/components/settings-tabs/settings-components/user-setting.component.tsx +++ b/src/renderer/components/settings-tabs/settings-components/other-setting.component.tsx @@ -1,27 +1,24 @@ import useSetting from '@renderer/hooks/papi-hooks/use-setting.hook'; import { SettingNames, SettingTypes } from 'papi-shared-types'; import settingsService from '@shared/services/settings.service'; -import Setting, { UserSettingProps, UserSettingValues } from './setting.component'; +import Setting, { OtherSettingProps, OtherSettingValues } from './setting.component'; -/** - * Provides a user-specific setting component by utilizing the `Setting` component with - * user-specific validation - */ -export default function UserSetting({ +/** Provides a non-project setting component by utilizing the `Setting` component validation */ +export default function OtherSetting({ settingKey, label, description, defaultSetting, -}: UserSettingProps) { +}: OtherSettingProps) { const [setting, setSetting, , isLoading] = useSetting( settingKey, defaultSetting, ); - const validateUserSetting = async ( + const validateOtherSetting = async ( currentSettingKey: SettingNames, - newValue: UserSettingValues, - currentValue: UserSettingValues, + newValue: OtherSettingValues, + currentValue: OtherSettingValues, ) => { return settingsService.validateSetting(currentSettingKey, newValue, currentValue); }; @@ -32,7 +29,7 @@ export default function UserSetting({ setting={setting} setSetting={setSetting} isLoading={isLoading} - validateUserSetting={validateUserSetting} + validateOtherSetting={validateOtherSetting} label={label} description={description} /> diff --git a/src/renderer/components/settings-tabs/settings-components/project-or-user-settings-list.component.tsx b/src/renderer/components/settings-tabs/settings-components/project-or-other-settings-list.component.tsx similarity index 81% rename from src/renderer/components/settings-tabs/settings-components/project-or-user-settings-list.component.tsx rename to src/renderer/components/settings-tabs/settings-components/project-or-other-settings-list.component.tsx index b5033d660a..d2d44f0390 100644 --- a/src/renderer/components/settings-tabs/settings-components/project-or-user-settings-list.component.tsx +++ b/src/renderer/components/settings-tabs/settings-components/project-or-other-settings-list.component.tsx @@ -2,12 +2,12 @@ import { Localized, ProjectSettingProperties, SettingProperties } from 'platform import { SettingsCard } from 'platform-bible-react'; import { useMemo } from 'react'; import { ProjectSettingNames, SettingNames } from 'papi-shared-types'; -import UserSetting from './user-setting.component'; +import OtherSetting from './other-setting.component'; import ProjectSetting from './project-setting.component'; -import { ProjectSettingValues, UserSettingValues } from './setting.component'; +import { ProjectSettingValues, OtherSettingValues } from './setting.component'; /** Properties for a settings list component that displays either project or user settings */ -type ProjectOrUserSettingsListProps = { +type ProjectOrOtherSettingsListProps = { /** Properties for either a project setting group or user setting group */ settingProperties: Localized | Localized; /** Optional projectId, supplied if the list is for project settings */ @@ -24,13 +24,13 @@ type ProjectOrUserSettingsListProps = { * Filters and displays a list of settings based on a search query and whether it's for project or * user settings, rendering either `ProjectSetting` or `UserSetting` components accordingly. */ -export default function ProjectOrUserSettingsList({ +export default function ProjectOrOtherSettingsList({ settingProperties, projectId, searchQuery, groupLabel, groupDescription, -}: ProjectOrUserSettingsListProps) { +}: ProjectOrOtherSettingsListProps) { const filteredSettingsProperties = useMemo((): | Localized | Localized => { @@ -47,13 +47,7 @@ export default function ProjectOrUserSettingsList({ }, [searchQuery, settingProperties]); return ( - - {/* // {Object.keys(filteredSettingsProperties).length > 0 ? ( */} - {/* // */} - {/* // ) : undefined} */} +
    {Object.entries(filteredSettingsProperties).map(([key, property]) => projectId ? ( @@ -70,7 +64,7 @@ export default function ProjectOrUserSettingsList({ defaultSetting={property.default as ProjectSettingValues} /> ) : ( - ), )} diff --git a/src/renderer/components/settings-tabs/settings-components/setting.component.tsx b/src/renderer/components/settings-tabs/settings-components/setting.component.tsx index 719dec214a..2708a140a3 100644 --- a/src/renderer/components/settings-tabs/settings-components/setting.component.tsx +++ b/src/renderer/components/settings-tabs/settings-components/setting.component.tsx @@ -1,16 +1,16 @@ -import { ChangeEvent, useCallback, useMemo, useState } from 'react'; +import { ChangeEvent, useCallback, useState } from 'react'; import { ProjectSettingNames, ProjectSettingTypes, SettingNames, SettingTypes, } from 'papi-shared-types'; -import { Input, SettingsListItem, Switch } from 'platform-bible-react'; +import { Input, Label, Switch } from 'platform-bible-react'; import { debounce, getErrorMessage } from 'platform-bible-utils'; import { DataProviderUpdateInstructions } from '@shared/models/data-provider.model'; import { SettingDataTypes } from '@shared/services/settings.service-model'; import logger from '@shared/services/logger.service'; -import { useLocalizedStrings } from '@renderer/hooks/papi-hooks'; +// import { useLocalizedStrings } from '@renderer/hooks/papi-hooks'; /** Props shared between the user and project setting components */ type BaseSettingProps = { @@ -28,10 +28,10 @@ type BaseSettingProps = { * Combines properties and controls with optional validation functions for both project and user * settings */ -type SettingProps = TProps & +type SettingProps = TProps & TControls & { validateProjectSetting?: TValidateProject; - validateUserSetting?: TValidateUser; + validateOtherSetting?: TValidateOther; }; /** Values of ProjectSettingTypes */ @@ -53,14 +53,14 @@ type ProjectSettingsControls = { }; /** Values of SettingTypes */ -export type UserSettingValues = SettingTypes[keyof SettingTypes]; +export type OtherSettingValues = SettingTypes[keyof SettingTypes]; /** Props for the UserSetting component */ -export type UserSettingProps = BaseSettingProps; +export type OtherSettingProps = BaseSettingProps; /** Values from the useSetting hook to manage the setting */ -type UserSettingsControls = { - setting: UserSettingValues; +type OtherSettingsControls = { + setting: OtherSettingValues; // Necessary for flexibility in handleChangeSetting, ProjectSettingValues and // UserSettingValues are not the same so it couldn't assign // eslint-disable-next-line @typescript-eslint/no-explicit-any @@ -83,8 +83,8 @@ type CombinedSettingProps = never > | SettingProps< - Omit, - UserSettingsControls, + Omit, + OtherSettingsControls, never, // Necessary for flexibility in handleChangeSetting, couldn't use unknown // and keep types in ProjectSetting component @@ -100,13 +100,13 @@ export default function Setting({ settingKey, setting, setSetting, - isLoading, - validateUserSetting, + // isLoading, + validateOtherSetting, validateProjectSetting, label, - description, + // description, }: CombinedSettingProps) { - const validateSetting = validateUserSetting || validateProjectSetting; + const validateSetting = validateOtherSetting || validateProjectSetting; const [errorMessage, setErrorMessage] = useState(undefined); @@ -193,18 +193,14 @@ export default function Setting({ ); }, [setting, settingKey, debouncedHandleChange, errorMessage]); - const loadingSettingKey = '%settings_defaultMessage_loadingSetting%'; - const [localizedStrings] = useLocalizedStrings(useMemo(() => [loadingSettingKey], [])); - const localizedLoadingSetting = localizedStrings[loadingSettingKey]; + // const loadingSettingKey = '%settings_defaultMessage_loadingSetting%'; + // const [localizedStrings] = useLocalizedStrings(useMemo(() => [loadingSettingKey], [])); + // const localizedLoadingSetting = localizedStrings[loadingSettingKey]; return ( - +
    + {generateComponent()} - +
    ); } diff --git a/src/renderer/components/settings-tabs/settings-tab.component.tsx b/src/renderer/components/settings-tabs/settings-tab.component.tsx index 1d762108f1..7bd52d8b62 100644 --- a/src/renderer/components/settings-tabs/settings-tab.component.tsx +++ b/src/renderer/components/settings-tabs/settings-tab.component.tsx @@ -1,35 +1,29 @@ import { useCallback, useMemo, useState } from 'react'; -import { SettingsSidebarContentSearch, usePromise } from 'platform-bible-react'; +import { + ProjectOptions, + SelectedSettingsSidebarItem, + SettingsSidebarContentSearch, + usePromise, +} from 'platform-bible-react'; import { SavedTabInfo, TabInfo } from '@shared/models/docking-framework.model'; -import projectSettingsService from '@shared/services/project-settings.service'; +import projectSettingsService, { + filterProjectSettingsContributionsByProjectInterfaces, +} from '@shared/services/project-settings.service'; import settingsService from '@shared/services/settings.service'; -// import { useLocalizedStrings } from '@renderer/hooks/papi-hooks'; -import ProjectOrUserSettingsList from './settings-components/project-or-user-settings-list.component'; import './settings-tab.component.scss'; +import projectLookupService from '@shared/services/project-lookup.service'; +import { projectDataProviders } from '@renderer/services/papi-frontend.service'; +import ProjectOrOtherSettingsList from './settings-components/project-or-other-settings-list.component'; export const TAB_TYPE_SETTINGS_TAB = 'settings-tab'; type SettingsTabProps = { /** Optional project Id, when passed in, will only show settings for that project */ projectId?: string; - /** Optional setting key, when passed in, will scroll to that selected setting in the dialog */ - // settingKey?: string; -}; - -type SelectedSidebarItem = { - label: string; - isProjectSetting: boolean; }; export default function SettingsTab({ projectId }: SettingsTabProps) { - // const searchProjectSettingsKey = '%settings_defaultSearchText_searchProject%'; - // const searchUserSettingsKey = '%settings_defaultSearchText_searchUserSettings%'; - // const [localizedStrings] = useLocalizedStrings( - // useMemo(() => [searchProjectSettingsKey, searchUserSettingsKey], []), - // ); - // const localizedSearchProjectSettings = localizedStrings[searchProjectSettingsKey]; - // const localizedSearchUserSettings = localizedStrings[searchUserSettingsKey]; - const [selectedSidebarItem, setSelectedSidebarItem] = useState(); + const [selectedSidebarItem, setSelectedSidebarItem] = useState(); const [settingsContributions, isLoadingSettingsContributions] = usePromise( useCallback(async () => { @@ -46,7 +40,6 @@ export default function SettingsTab({ projectId }: SettingsTabProps) { setSelectedSidebarItem({ label: Object.keys(filteredContributions)[0], - isProjectSetting: false, }); return filteredContributions; @@ -75,74 +68,88 @@ export default function SettingsTab({ projectId }: SettingsTabProps) { }, []), ); - // const getFilteredProjectSettingKeys = useMemo(() => { - // const objectKeys = Object.keys(projectSettingsContributions); + const [filteredProjectSettingsContributions] = usePromise( + useCallback(async () => { + if (!selectedSidebarItem || !selectedSidebarItem.projectId) return undefined; - // objectKeys.filter((key) => ); - // }, []); + const projectInterfacesFromProjectId = ( + await projectLookupService.getMetadataForProject(selectedSidebarItem.projectId) + ).projectInterfaces; - // const getProjectSettingLabels = () => { - // if (!projectSettingsContributions) return; + const filteredContributionsByInterface = + await filterProjectSettingsContributionsByProjectInterfaces( + projectSettingsContributions, + projectInterfacesFromProjectId, + ); - // const projectContributionKeysAndLabels: { [projectName: string]: string } = {}; + return filteredContributionsByInterface; + }, [projectSettingsContributions, selectedSidebarItem]), + useMemo(() => undefined, []), + ); - // Object.entries(projectSettingsContributions).map( - // ([projectName, settingsGroups]) => - // settingsGroups && - // Object.entries(settingsGroups).map( - // // eslint-disable-next-line no-return-assign - // ([, settingsGroup]) => - // (projectContributionKeysAndLabels[projectName] = settingsGroup.label), - // ), - // ); - // }; + const [allProjectIdsFromMetadata] = usePromise( + useCallback(async () => { + const allMetadata = await projectLookupService.getMetadataForAllProjects(); + return allMetadata.flatMap((metadata) => metadata.id); + }, []), + useMemo(() => [], []), + ); - // const getExtensionSettingLabels = () => { - // if (!settingsContributions) return; + const projectNameCache: { [projectId: string]: string } = useMemo(() => { + return {}; + }, []); - // const contributionKeysAndLabels: { [extensionName: string]: string } = {}; + const getProjectName = useCallback( + async (projectIdToGetName: string) => { + if (projectNameCache[projectIdToGetName]) { + return projectNameCache[projectIdToGetName]; + } - // Object.entries(settingsContributions).map( - // ([extensionName, settingsGroups]) => - // settingsGroups && - // Object.entries(settingsGroups).map( - // // eslint-disable-next-line no-return-assign - // ([, settingsGroup]) => (contributionKeysAndLabels[extensionName] = settingsGroup.label), - // ), - // ); - // }; + const pdp = await projectDataProviders.get('platform.base', projectIdToGetName); + const projectName = await pdp.getSetting('platform.name'); - const currentlySelectedSettingGroup = useMemo(() => { - if (!selectedSidebarItem) return undefined; + projectNameCache[projectIdToGetName] = projectName; - let selectedSettingGroup; - if (!selectedSidebarItem.isProjectSetting && settingsContributions) - selectedSettingGroup = settingsContributions[selectedSidebarItem.label]; - else if (selectedSidebarItem.isProjectSetting && projectSettingsContributions) - selectedSettingGroup = projectSettingsContributions[selectedSidebarItem.label]; + return projectName; + }, + [projectNameCache], + ); - return selectedSettingGroup; - }, [projectSettingsContributions, selectedSidebarItem, settingsContributions]); + const [allProjectOptions]: [ProjectOptions[], boolean] = usePromise( + useCallback(async () => { + const projectOptions = await Promise.all( + allProjectIdsFromMetadata.map(async (id) => ({ + projectId: id, + projectName: await getProjectName(id), + })), + ); + return projectOptions; + }, [allProjectIdsFromMetadata, getProjectName]), + useMemo(() => [], []), + ); if (!settingsContributions) return
    No Settings
    ; - if (!projectSettingsContributions) return
    No project settings
    ; if (isLoadingSettingsContributions || isLoadingProjectSettingsContributions) return
    Loading Settings
    ; // TODO: fix - if (projectId) { - const specificProjectContribution = projectSettingsContributions[projectId]; - + if (projectId && filteredProjectSettingsContributions) { return ( -
    - {specificProjectContribution?.forEach((group) => ( - - )) ||
    } +
    + {Object.entries(filteredProjectSettingsContributions).map( + ([, settingsGroups]) => + settingsGroups && + Object.entries(settingsGroups).map(([, settingsGroup]) => ( + + )), + )}
    ); } @@ -152,21 +159,39 @@ export default function SettingsTab({ projectId }: SettingsTabProps) {
    - setSelectedSidebarItem({ label: key, isProjectSetting }) + projectOptions={allProjectOptions} + handleSelectSidebarItem={(key: string, projId?: string) => + setSelectedSidebarItem({ label: key, projectId: projId }) } - // selectedSidebarItem={selectedSidebarItem} // TODO: Needed to set the active item + selectedSidebarItem={selectedSidebarItem} > - {currentlySelectedSettingGroup && Array.isArray(currentlySelectedSettingGroup) - ? currentlySelectedSettingGroup.map((group) => ( - - )) - : undefined} + {/* eslint-disable-next-line no-nested-ternary */} + {selectedSidebarItem?.projectId && filteredProjectSettingsContributions + ? Object.entries(filteredProjectSettingsContributions).map( + ([, settingsGroups]) => + settingsGroups && + Object.entries(settingsGroups).map(([, settingsGroup]) => ( + + )), + ) + : selectedSidebarItem?.label && settingsContributions + ? settingsContributions[selectedSidebarItem.label]?.map((group) => ( + + )) + : undefined}
    From e75ca7520de0c5afbb22e0dc94d9c586e5399292 Mon Sep 17 00:00:00 2001 From: Jolie Rabideau Date: Mon, 25 Nov 2024 16:00:17 -0500 Subject: [PATCH 03/18] Fix css to match v0, attempt to fix project list --- lib/platform-bible-react/dist/index.cjs | 149 +- lib/platform-bible-react/dist/index.cjs.map | 2 +- lib/platform-bible-react/dist/index.d.ts | 9 +- lib/platform-bible-react/dist/index.js | 2291 +++++++++-------- lib/platform-bible-react/dist/index.js.map | 2 +- .../settings-card.component.tsx | 11 +- ...tings-sidebar-content-search.component.tsx | 32 +- .../settings-sidebar.component.tsx | 33 +- .../basics/search-bar.component.tsx | 9 +- .../src/components/shadcn-ui/sidebar.tsx | 9 +- .../pages/components/basics.component.tsx | 4 +- ...oject-or-other-settings-list.component.tsx | 2 +- .../settings-components/setting.component.tsx | 14 +- .../settings-tabs/settings-tab.component.scss | 3 +- .../settings-tabs/settings-tab.component.tsx | 118 +- 15 files changed, 1435 insertions(+), 1253 deletions(-) diff --git a/lib/platform-bible-react/dist/index.cjs b/lib/platform-bible-react/dist/index.cjs index 49a92932a9..af2af2c6c9 100644 --- a/lib/platform-bible-react/dist/index.cjs +++ b/lib/platform-bible-react/dist/index.cjs @@ -1,23 +1,23 @@ -"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const a=require("react/jsx-runtime"),g=require("react"),Q=require("lucide-react"),ot=require("clsx"),ml=require("tailwind-merge"),ts=require("@radix-ui/react-dropdown-menu"),W=require("platform-bible-utils"),Ht=require("@radix-ui/react-slot"),Xt=require("class-variance-authority"),hl=require("@radix-ui/react-label"),gl=require("@radix-ui/react-radio-group"),bl=require("@radix-ui/react-popover"),Oe=require("cmdk"),vl=require("@radix-ui/react-dialog"),Se=require("@tanstack/react-table"),xl=require("@radix-ui/react-select"),yl=require("@radix-ui/react-checkbox"),Nl=require("@radix-ui/react-toggle-group"),kl=require("@radix-ui/react-toggle"),Sl=require("@radix-ui/react-tabs"),El=require("@radix-ui/react-separator"),jl=require("@radix-ui/react-tooltip"),Ce=require("@mui/material"),Gr=require("@mui/styled-engine"),ln=require("react-dom"),ns=require("sonner"),Cl=require("@radix-ui/react-slider"),Tl=require("@radix-ui/react-switch"),Rl=require("markdown-to-jsx");function ke(e){const t=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(e){for(const n in e)if(n!=="default"){const r=Object.getOwnPropertyDescriptor(e,n);Object.defineProperty(t,n,r.get?r:{enumerable:!0,get:()=>e[n]})}}return t.default=e,Object.freeze(t)}const M=ke(g),pe=ke(ts),rs=ke(hl),bn=ke(gl),vn=ke(bl),be=ke(vl),ge=ke(xl),Ur=ke(yl),rr=ke(Nl),os=ke(kl),_e=ke(Sl),as=ke(El),Sn=ke(jl),Ol=ke(ln),cn=ke(Cl),qr=ke(Tl);const _l=ml.extendTailwindMerge({prefix:"tw-"});function N(...e){return _l(ot.clsx(e))}const St=g.forwardRef(({className:e,type:t,...n},r)=>a.jsx("input",{type:t,className:N("pr-twp tw-flex tw-h-10 tw-rounded-md tw-border tw-border-input tw-bg-background tw-px-3 tw-py-2 tw-text-sm tw-ring-offset-background file:tw-border-0 file:tw-bg-transparent file:tw-text-sm file:tw-font-medium file:tw-text-foreground placeholder:tw-text-muted-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-cursor-not-allowed disabled:tw-opacity-50",e),ref:r,...n}));St.displayName="Input";const Pl=g.forwardRef(({handleSearch:e,handleKeyDown:t,handleOnClick:n,handleSubmit:r,...o},s)=>a.jsxs("div",{className:"tw-relative",children:[a.jsx(St,{...o,type:"text",className:"tw-box-border tw-gap-2.5 tw-rounded-lg tw-border tw-border-solid tw-bg-background tw-py-2 tw-pl-4 tw-pr-3 tw-font-medium tw-shadow-none tw-outline-none",onChange:i=>e(i.target.value),onKeyDown:i=>{i.key==="Enter"&&r(),t(i)},onClick:n,ref:s}),a.jsx(Q.History,{className:"tw-absolute tw-right-3 tw-top-1/2 tw-h-4 tw-w-4 tw--translate-y-1/2 tw-transform tw-cursor-pointer tw-text-muted-foreground",onClick:()=>{console.log("back in history")}})]}));var Il=Object.defineProperty,Ml=(e,t,n)=>t in e?Il(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,ne=(e,t,n)=>Ml(e,typeof t!="symbol"?t+"":t,n);const gt=["GEN","EXO","LEV","NUM","DEU","JOS","JDG","RUT","1SA","2SA","1KI","2KI","1CH","2CH","EZR","NEH","EST","JOB","PSA","PRO","ECC","SNG","ISA","JER","LAM","EZK","DAN","HOS","JOL","AMO","OBA","JON","MIC","NAM","HAB","ZEP","HAG","ZEC","MAL","MAT","MRK","LUK","JHN","ACT","ROM","1CO","2CO","GAL","EPH","PHP","COL","1TH","2TH","1TI","2TI","TIT","PHM","HEB","JAS","1PE","2PE","1JN","2JN","3JN","JUD","REV","TOB","JDT","ESG","WIS","SIR","BAR","LJE","S3Y","SUS","BEL","1MA","2MA","3MA","4MA","1ES","2ES","MAN","PS2","ODA","PSS","JSA","JDB","TBS","SST","DNT","BLT","XXA","XXB","XXC","XXD","XXE","XXF","XXG","FRT","BAK","OTH","3ES","EZA","5EZ","6EZ","INT","CNC","GLO","TDX","NDX","DAG","PS3","2BA","LBA","JUB","ENO","1MQ","2MQ","3MQ","REP","4BA","LAO"],ao=["XXA","XXB","XXC","XXD","XXE","XXF","XXG","FRT","BAK","OTH","INT","CNC","GLO","TDX","NDX"],ss=["Genesis","Exodus","Leviticus","Numbers","Deuteronomy","Joshua","Judges","Ruth","1 Samuel","2 Samuel","1 Kings","2 Kings","1 Chronicles","2 Chronicles","Ezra","Nehemiah","Esther (Hebrew)","Job","Psalms","Proverbs","Ecclesiastes","Song of Songs","Isaiah","Jeremiah","Lamentations","Ezekiel","Daniel (Hebrew)","Hosea","Joel","Amos","Obadiah","Jonah","Micah","Nahum","Habakkuk","Zephaniah","Haggai","Zechariah","Malachi","Matthew","Mark","Luke","John","Acts","Romans","1 Corinthians","2 Corinthians","Galatians","Ephesians","Philippians","Colossians","1 Thessalonians","2 Thessalonians","1 Timothy","2 Timothy","Titus","Philemon","Hebrews","James","1 Peter","2 Peter","1 John","2 John","3 John","Jude","Revelation","Tobit","Judith","Esther Greek","Wisdom of Solomon","Sirach (Ecclesiasticus)","Baruch","Letter of Jeremiah","Song of 3 Young Men","Susanna","Bel and the Dragon","1 Maccabees","2 Maccabees","3 Maccabees","4 Maccabees","1 Esdras (Greek)","2 Esdras (Latin)","Prayer of Manasseh","Psalm 151","Odes","Psalms of Solomon","Joshua A. *obsolete*","Judges B. *obsolete*","Tobit S. *obsolete*","Susanna Th. *obsolete*","Daniel Th. *obsolete*","Bel Th. *obsolete*","Extra A","Extra B","Extra C","Extra D","Extra E","Extra F","Extra G","Front Matter","Back Matter","Other Matter","3 Ezra *obsolete*","Apocalypse of Ezra","5 Ezra (Latin Prologue)","6 Ezra (Latin Epilogue)","Introduction","Concordance ","Glossary ","Topical Index","Names Index","Daniel Greek","Psalms 152-155","2 Baruch (Apocalypse)","Letter of Baruch","Jubilees","Enoch","1 Meqabyan","2 Meqabyan","3 Meqabyan","Reproof (Proverbs 25-31)","4 Baruch (Rest of Baruch)","Laodiceans"],sa=Ul();function Yt(e,t=!0){return t&&(e=e.toUpperCase()),e in sa?sa[e]:0}function so(e){return Yt(e)>0}function $l(e){const t=typeof e=="string"?Yt(e):e;return t>=40&&t<=66}function Dl(e){return(typeof e=="string"?Yt(e):e)<=39}function is(e){return e<=66}function Al(e){const t=typeof e=="string"?Yt(e):e;return ds(t)&&!is(t)}function*Bl(){for(let e=1;e<=gt.length;e++)yield e}const Vl=1,ls=gt.length;function zl(){return["XXA","XXB","XXC","XXD","XXE","XXF","XXG"]}function io(e,t="***"){const n=e-1;return n<0||n>=gt.length?t:gt[n]}function cs(e){return e<=0||e>ls?"******":ss[e-1]}function Ll(e){return cs(Yt(e))}function ds(e){const t=typeof e=="number"?io(e):e;return so(t)&&!ao.includes(t)}function Fl(e){const t=typeof e=="number"?io(e):e;return so(t)&&ao.includes(t)}function Gl(e){return ss[e-1].includes("*obsolete*")}function Ul(){const e={};for(let t=0;t(e[e.Unknown=0]="Unknown",e[e.Original=1]="Original",e[e.Septuagint=2]="Septuagint",e[e.Vulgate=3]="Vulgate",e[e.English=4]="English",e[e.RussianProtestant=5]="RussianProtestant",e[e.RussianOrthodox=6]="RussianOrthodox",e))(He||{});const Ie=class{constructor(t){if(ne(this,"name"),ne(this,"fullPath"),ne(this,"isPresent"),ne(this,"hasVerseSegments"),ne(this,"isCustomized"),ne(this,"baseVersification"),ne(this,"scriptureBooks"),ne(this,"_type"),t==null)throw new Error("Argument undefined");typeof t=="string"?(this.name=t,this._type=He[t]):(this._type=t,this.name=He[t])}get type(){return this._type}equals(t){return!t.type||!this.type?!1:t.type===this.type}};ne(Ie,"Original",new Ie(He.Original)),ne(Ie,"Septuagint",new Ie(He.Septuagint)),ne(Ie,"Vulgate",new Ie(He.Vulgate)),ne(Ie,"English",new Ie(He.English)),ne(Ie,"RussianProtestant",new Ie(He.RussianProtestant)),ne(Ie,"RussianOrthodox",new Ie(He.RussianOrthodox));let ut=Ie;function ia(e,t){const n=t[0];for(let r=1;r(e[e.Valid=0]="Valid",e[e.UnknownVersification=1]="UnknownVersification",e[e.OutOfRange=2]="OutOfRange",e[e.VerseOutOfOrder=3]="VerseOutOfOrder",e[e.VerseRepeated=4]="VerseRepeated",e))(us||{});const je=class re{constructor(t,n,r,o){if(ne(this,"firstChapter"),ne(this,"lastChapter"),ne(this,"lastVerse"),ne(this,"hasSegmentsDefined"),ne(this,"text"),ne(this,"BBBCCCVVVS"),ne(this,"longHashCode"),ne(this,"versification"),ne(this,"rtlMark","‏"),ne(this,"_bookNum",0),ne(this,"_chapterNum",0),ne(this,"_verseNum",0),ne(this,"_verse"),r==null&&o==null)if(t!=null&&typeof t=="string"){const s=t,i=n!=null&&n instanceof ut?n:void 0;this.setEmpty(i),this.parse(s)}else if(t!=null&&typeof t=="number"){const s=n!=null&&n instanceof ut?n:void 0;this.setEmpty(s),this._verseNum=t%re.chapterDigitShifter,this._chapterNum=Math.floor(t%re.bookDigitShifter/re.chapterDigitShifter),this._bookNum=Math.floor(t/re.bookDigitShifter)}else if(n==null)if(t!=null&&t instanceof re){const s=t;this._bookNum=s.bookNum,this._chapterNum=s.chapterNum,this._verseNum=s.verseNum,this._verse=s.verse,this.versification=s.versification}else{if(t==null)return;const s=t instanceof ut?t:re.defaultVersification;this.setEmpty(s)}else throw new Error("VerseRef constructor not supported.");else if(t!=null&&n!=null&&r!=null)if(typeof t=="string"&&typeof n=="string"&&typeof r=="string")this.setEmpty(o),this.updateInternal(t,n,r);else if(typeof t=="number"&&typeof n=="number"&&typeof r=="number")this._bookNum=t,this._chapterNum=n,this._verseNum=r,this.versification=o??re.defaultVersification;else throw new Error("VerseRef constructor not supported.");else throw new Error("VerseRef constructor not supported.")}static isVerseParseable(t){return t.length>0&&"0123456789".includes(t[0])&&!t.endsWith(this.verseRangeSeparator)&&!t.endsWith(this.verseSequenceIndicator)}static tryParse(t){let n;try{return n=new re(t),{success:!0,verseRef:n}}catch(r){if(r instanceof nn)return n=new re,{success:!1,verseRef:n};throw r}}static getBBBCCCVVV(t,n,r){return t%re.bcvMaxValue*re.bookDigitShifter+(n>=0?n%re.bcvMaxValue*re.chapterDigitShifter:0)+(r>=0?r%re.bcvMaxValue:0)}static fromJSON(t){const{book:n,chapterNum:r,verseNum:o,verse:s,versificationStr:i}=t,l=s||o.toString();let c;return i&&(c=new ut(i)),n?new re(n,r.toString(),l,c):new re}static tryGetVerseNum(t){let n;if(!t)return n=-1,{success:!0,vNum:n};n=0;let r;for(let o=0;o"9")return o===0&&(n=-1),{success:!1,vNum:n};if(n=n*10+ +r-0,n>re.bcvMaxValue)return n=-1,{success:!1,vNum:n}}return{success:!0,vNum:n}}get isDefault(){return this.bookNum===0&&this.chapterNum===0&&this.verseNum===0&&this.versification==null}get hasMultiple(){return this._verse!=null&&(this._verse.includes(re.verseRangeSeparator)||this._verse.includes(re.verseSequenceIndicator))}get book(){return ae.bookNumberToId(this.bookNum,"")}set book(t){this.bookNum=ae.bookIdToNumber(t)}get chapter(){return this.isDefault||this._chapterNum<0?"":this._chapterNum.toString()}set chapter(t){const n=+t;this._chapterNum=Number.isInteger(n)?n:-1}get verse(){return this._verse!=null?this._verse:this.isDefault||this._verseNum<0?"":this._verseNum.toString()}set verse(t){const{success:n,vNum:r}=re.tryGetVerseNum(t);this._verse=n?void 0:t.replace(this.rtlMark,""),this._verseNum=r,!(this._verseNum>=0)&&({vNum:this._verseNum}=re.tryGetVerseNum(this._verse))}get bookNum(){return this._bookNum}set bookNum(t){if(t<=0||t>ae.lastBook)throw new nn("BookNum must be greater than zero and less than or equal to last book");this._bookNum=t}get chapterNum(){return this._chapterNum}set chapterNum(t){this.chapterNum=t}get verseNum(){return this._verseNum}set verseNum(t){this._verseNum=t}get versificationStr(){var t;return(t=this.versification)==null?void 0:t.name}set versificationStr(t){this.versification=this.versification!=null?new ut(t):void 0}get valid(){return this.validStatus===0}get validStatus(){return this.validateVerse(re.verseRangeSeparators,re.verseSequenceIndicators)}get BBBCCC(){return re.getBBBCCCVVV(this._bookNum,this._chapterNum,0)}get BBBCCCVVV(){return re.getBBBCCCVVV(this._bookNum,this._chapterNum,this._verseNum)}get isExcluded(){return!1}parse(t){if(t=t.replace(this.rtlMark,""),t.includes("/")){const s=t.split("/");if(t=s[0],s.length>1)try{const i=+s[1].trim();this.versification=new ut(He[i])}catch{throw new nn("Invalid reference : "+t)}}const n=t.trim().split(" ");if(n.length!==2)throw new nn("Invalid reference : "+t);const r=n[1].split(":"),o=+r[0];if(r.length!==2||ae.bookIdToNumber(n[0])===0||!Number.isInteger(o)||o<0||!re.isVerseParseable(r[1]))throw new nn("Invalid reference : "+t);this.updateInternal(n[0],r[0],r[1])}simplify(){this._verse=void 0}clone(){return new re(this)}toString(){const t=this.book;return t===""?"":`${t} ${this.chapter}:${this.verse}`}toJSON(){let t=this.verse;(t===""||t===this.verseNum.toString())&&(t=void 0);const n={book:this.book,chapterNum:this.chapterNum,verseNum:this.verseNum,verse:t,versificationStr:this.versificationStr};return t||delete n.verse,n}equals(t){return t instanceof re?t._bookNum===this._bookNum&&t._chapterNum===this._chapterNum&&t._verseNum===this._verseNum&&t.verse===this.verse&&(t.versification==null&&this.versification==null||t.versification!=null&&this.versification!=null&&t.versification.equals(this.versification)):!1}allVerses(t=!1,n=re.verseRangeSeparators,r=re.verseSequenceIndicators){if(this._verse==null||this.chapterNum<=0)return[this.clone()];const o=[],s=ia(this._verse,r);for(const i of s.map(l=>ia(l,n))){const l=this.clone();l.verse=i[0];const c=l.verseNum;if(o.push(l),i.length>1){const d=this.clone();if(d.verse=i[1],!t)for(let u=c+1;ui)return 3;if(r===i)return 4;r=i}return 0}get internalValid(){return this.versification==null?1:this._bookNum<=0||this._bookNum>ae.lastBook?2:(ae.isCanonical(this._bookNum),0)}setEmpty(t=re.defaultVersification){this._bookNum=0,this._chapterNum=-1,this._verse=void 0,this.versification=t}updateInternal(t,n,r){this.bookNum=ae.bookIdToNumber(t),this.chapter=n,this.verse=r}};ne(je,"defaultVersification",ut.English),ne(je,"verseRangeSeparator","-"),ne(je,"verseSequenceIndicator",","),ne(je,"verseRangeSeparators",[je.verseRangeSeparator]),ne(je,"verseSequenceIndicators",[je.verseSequenceIndicator]),ne(je,"chapterDigitShifter",1e3),ne(je,"bookDigitShifter",je.chapterDigitShifter*je.chapterDigitShifter),ne(je,"bcvMaxValue",je.chapterDigitShifter-1),ne(je,"ValidStatusType",us);class nn extends Error{}const or=pe.Root,lo=pe.Trigger,ps=pe.Group,ql=pe.Portal,Hl=pe.Sub,Xl=pe.RadioGroup,ws=g.forwardRef(({className:e,inset:t,children:n,...r},o)=>a.jsxs(pe.SubTrigger,{ref:o,className:N("tw-flex tw-cursor-default tw-select-none tw-items-center tw-rounded-sm tw-px-2 tw-py-1.5 tw-text-sm tw-outline-none focus:tw-bg-accent data-[state=open]:tw-bg-accent",t&&"tw-pl-8",e),...r,children:[n,a.jsx(Q.ChevronRight,{className:"tw-ml-auto tw-h-4 tw-w-4"})]}));ws.displayName=pe.SubTrigger.displayName;const fs=g.forwardRef(({className:e,...t},n)=>a.jsx(pe.SubContent,{ref:n,className:N("tw-z-50 tw-min-w-[8rem] tw-overflow-hidden tw-rounded-md tw-border tw-bg-popover tw-p-1 tw-text-popover-foreground tw-shadow-lg data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0 data-[state=closed]:tw-zoom-out-95 data-[state=open]:tw-zoom-in-95 data-[side=bottom]:tw-slide-in-from-top-2 data-[side=left]:tw-slide-in-from-right-2 data-[side=right]:tw-slide-in-from-left-2 data-[side=top]:tw-slide-in-from-bottom-2",e),...t}));fs.displayName=pe.SubContent.displayName;const En=g.forwardRef(({className:e,sideOffset:t=4,...n},r)=>a.jsx(pe.Portal,{children:a.jsx(pe.Content,{ref:r,sideOffset:t,className:N("pr-twp tw-z-50 tw-min-w-[8rem] tw-overflow-hidden tw-rounded-md tw-border tw-bg-popover tw-p-1 tw-text-popover-foreground tw-shadow-md data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0 data-[state=closed]:tw-zoom-out-95 data-[state=open]:tw-zoom-in-95 data-[side=bottom]:tw-slide-in-from-top-2 data-[side=left]:tw-slide-in-from-right-2 data-[side=right]:tw-slide-in-from-left-2 data-[side=top]:tw-slide-in-from-bottom-2",e),...n})}));En.displayName=pe.Content.displayName;const co=g.forwardRef(({className:e,inset:t,...n},r)=>a.jsx(pe.Item,{ref:r,className:N("tw-cursor-default tw-select-none tw-items-center tw-rounded-sm tw-px-2 tw-py-1.5 tw-text-sm tw-outline-none tw-transition-colors focus:tw-bg-accent data-[disabled]:tw-pointer-events-none data-[disabled]:tw-opacity-50",t&&"tw-pl-8",e),...n}));co.displayName=pe.Item.displayName;const ar=g.forwardRef(({className:e,children:t,checked:n,...r},o)=>a.jsxs(pe.CheckboxItem,{ref:o,className:N("tw-relative tw-flex tw-cursor-default tw-select-none tw-items-center tw-rounded-sm tw-py-1.5 tw-pl-8 tw-pr-2 tw-text-sm tw-outline-none tw-transition-colors focus:tw-bg-accent focus:tw-text-accent-foreground data-[disabled]:tw-pointer-events-none data-[disabled]:tw-opacity-50",e),checked:n,...r,children:[a.jsx("span",{className:"tw-absolute tw-left-2 tw-flex tw-h-3.5 tw-w-3.5 tw-items-center tw-justify-center",children:a.jsx(pe.ItemIndicator,{children:a.jsx(Q.Check,{className:"tw-h-4 tw-w-4"})})}),t]}));ar.displayName=pe.CheckboxItem.displayName;const uo=g.forwardRef(({className:e,children:t,...n},r)=>a.jsxs(pe.RadioItem,{ref:r,className:N("tw-relative tw-flex tw-cursor-default tw-select-none tw-items-center tw-rounded-sm tw-py-1.5 tw-pl-8 tw-pr-2 tw-text-sm tw-outline-none tw-transition-colors focus:tw-bg-accent focus:tw-text-accent-foreground data-[disabled]:tw-pointer-events-none data-[disabled]:tw-opacity-50",e),...n,children:[a.jsx("span",{className:"tw-absolute tw-left-2 tw-flex tw-h-3.5 tw-w-3.5 tw-items-center tw-justify-center",children:a.jsx(pe.ItemIndicator,{children:a.jsx(Q.Circle,{className:"tw-h-2 tw-w-2 tw-fill-current"})})}),t]}));uo.displayName=pe.RadioItem.displayName;const Wt=g.forwardRef(({className:e,inset:t,...n},r)=>a.jsx(pe.Label,{ref:r,className:N("tw-px-2 tw-py-1.5 tw-text-sm tw-font-semibold",t&&"tw-pl-8",e),...n}));Wt.displayName=pe.Label.displayName;const jn=g.forwardRef(({className:e,...t},n)=>a.jsx(pe.Separator,{ref:n,className:N("tw--mx-1 tw-my-1 tw-h-px tw-bg-muted",e),...t}));jn.displayName=pe.Separator.displayName;function ms({className:e,...t}){return a.jsx("span",{className:N("tw-ml-auto tw-text-xs tw-tracking-widest tw-opacity-60",e),...t})}ms.displayName="DropdownMenuShortcut";const Yl=g.forwardRef(({bookId:e,handleSelectBook:t,isSelected:n,handleHighlightBook:r,handleKeyDown:o,bookType:s,children:i},l)=>a.jsxs(co,{ref:l,textValue:e,className:N("tw-mx-1 tw-px-1 tw-font-normal tw-text-foreground/80",{"tw-bg-amber-50 tw-text-yellow-900 data-[highlighted]:tw-bg-amber-100":n}),onSelect:c=>{c.preventDefault(),t()},onKeyDown:c=>{o(c)},onFocus:r,onMouseMove:r,children:[a.jsx("span",{className:N("tw-border-b-0 tw-border-l-2 tw-border-r-0 tw-border-t-0 tw-border-solid tw-px-2",{"tw-font-bold":n,"tw-border-l-red-200":s.toLowerCase()==="ot","tw-border-l-purple-200":s.toLowerCase()==="nt","tw-border-l-indigo-200":s.toLowerCase()==="dc"}),children:ae.bookIdToEnglishName(e)}),n&&a.jsx("div",{children:i})]},e));function Wl({handleSelectChapter:e,endChapter:t,activeChapter:n,highlightedChapter:r,handleHighlightedChapter:o}){const s=Array.from({length:t},(l,c)=>c+1),i=g.useCallback(l=>{o(l)},[o]);return a.jsx("div",{className:N("tw-flex tw-flex-wrap tw-items-start tw-justify-start tw-self-stretch"),children:s.map(l=>a.jsx("div",{className:N("tw-box-content tw-flex tw-h-4 tw-w-4 tw-cursor-pointer tw-items-center tw-justify-end tw-rounded-md tw-p-2 tw-text-amber-800",{"tw-font-semibold tw-text-amber-900":l===n,"tw-bg-amber-200":l===r}),onClick:c=>{c.preventDefault(),c.stopPropagation(),e(l)},role:"button",onKeyDown:c=>{c.key==="Enter"&&e(l)},tabIndex:0,onMouseMove:()=>i(l),children:l},l))})}function Kl({handleSort:e,handleLocationHistory:t,handleBookmarks:n}){return a.jsxs(Wt,{className:"tw-flex tw-justify-between",children:[a.jsx("p",{className:"tw-inline-block tw-align-middle",children:"Go To"}),a.jsxs("div",{className:"tw-flex tw-items-center",children:[a.jsx(Q.ArrowDownWideNarrow,{onClick:e,className:"tw-m-2 tw-h-4 tw-w-4 tw-cursor-pointer tw-gap-2"}),a.jsx(Q.Clock,{onClick:t,className:"tw-m-2 tw-h-4 tw-w-4 tw-cursor-pointer tw-gap-2"}),a.jsx(Q.Bookmark,{onClick:n,className:"tw-m-2 tw-h-4 tw-w-4 tw-cursor-pointer tw-gap-2"})]})]})}const wn=ae.allBookIds,Jl={OT:"Old Testament",NT:"New Testament",DC:"Deuterocanon"},la=["OT","NT","DC"],Zl=32+32+32,Ql=[/^(\w+)$/i,/^(\w+)(?:\s(\d+))$/i,/^(\w+)(?:\s(\d+):(\d+))$/i],ec=e=>({OT:wn.filter(n=>ae.isBookOT(n)),NT:wn.filter(n=>ae.isBookNT(n)),DC:wn.filter(n=>ae.isBookDC(n))})[e],rn=e=>W.getChaptersForBook(ae.bookIdToNumber(e));function tc(){return wn.map(t=>ae.bookIdToEnglishName(t))}function nc(e){return tc().includes(e)}function rc(e){const t=e.toLowerCase().replace(/^\w/,n=>n.toUpperCase());if(nc(t))return wn.find(r=>ae.bookIdToEnglishName(r)===t)}function oc({scrRef:e,handleSubmit:t}){const[n,r]=g.useState(""),[o,s]=g.useState(ae.bookNumberToId(e.bookNum)),[i,l]=g.useState(e.chapterNum??0),[c,d]=g.useState(ae.bookNumberToId(e.bookNum)),[u,h]=g.useState(!1),[w,b]=g.useState(u),x=g.useRef(void 0),f=g.useRef(void 0),m=g.useRef(void 0),S=g.useCallback(k=>ec(k).filter(D=>{const $=ae.bookIdToEnglishName(D).toLowerCase(),J=n.replace(/[^a-zA-Z]/g,"").toLowerCase();return $.includes(J)||D.toLowerCase().includes(J)}),[n]),R=k=>{r(k)},j=g.useRef(!1),E=g.useCallback(k=>{if(j.current){j.current=!1;return}h(k)},[]),v=g.useCallback((k,D,$,J)=>{if(l(ae.bookNumberToId(e.bookNum)!==k?1:e.chapterNum),D||rn(k)===-1){t({bookNum:ae.bookIdToNumber(k),chapterNum:$||1,verseNum:J||1}),h(!1),r("");return}s(o!==k?k:""),h(!D)},[t,e.bookNum,e.chapterNum,o]),P=k=>{k<=0||k>rn(o)||v(o,!0,k)},V=g.useCallback(()=>{Ql.forEach(k=>{const D=n.match(k);if(D){const[$,J=void 0,Y=void 0]=D.slice(1),F=rc($);(ae.isBookIdValid($)||F)&&v(F??$,!0,J?parseInt(J,10):1,Y?parseInt(Y,10):1)}})},[v,n]),U=g.useCallback(k=>{u?(k.key==="ArrowDown"||k.key==="ArrowUp")&&(typeof m<"u"&&m.current!==null?m.current.focus():typeof f<"u"&&f.current!==null&&f.current.focus(),k.preventDefault()):h(!0)},[u]),C=k=>{const{key:D}=k;D==="ArrowRight"||D==="ArrowLeft"||D==="ArrowDown"||D==="ArrowUp"||D==="Enter"||(x.current.dispatchEvent(new KeyboardEvent("keydown",{key:D})),x.current.focus())},_=k=>{const{key:D}=k;if(c===o){if(D==="Enter"){k.preventDefault(),v(o,!0,i);return}let $=0;if(D==="ArrowRight")if(i1)$=-1;else{k.preventDefault();return}else D==="ArrowDown"?$=6:D==="ArrowUp"&&($=-6);i+$<=0||i+$>rn(c)?l(0):$!==0&&(l(i+$),k.preventDefault())}};return g.useEffect(()=>{o===c?o===ae.bookNumberToId(e.bookNum)?l(e.chapterNum):l(1):l(0)},[c,e.bookNum,e.chapterNum,o]),g.useLayoutEffect(()=>{b(u)},[u]),g.useLayoutEffect(()=>{const k=setTimeout(()=>{if(w&&f.current&&m.current){const $=m.current.offsetTop-Zl;f.current.scrollTo({top:$,behavior:"instant"})}},10);return()=>{clearTimeout(k)}},[w]),a.jsx("div",{className:"pr-twp tw-flex",children:a.jsxs(or,{modal:!1,open:u,onOpenChange:E,children:[a.jsx(lo,{asChild:!0,children:a.jsx(Pl,{ref:x,value:n,handleSearch:R,handleKeyDown:U,handleOnClick:()=>{s(ae.bookNumberToId(e.bookNum)),d(ae.bookNumberToId(e.bookNum)),l(e.chapterNum>0?e.chapterNum:0),h(!0),x.current.focus()},onFocus:()=>{j.current=!0},handleSubmit:V,placeholder:`${ae.bookNumberToEnglishName(e.bookNum)} ${e.chapterNum}:${e.verseNum}`})}),a.jsxs(En,{className:"tw-m-1 tw-overflow-y-auto tw-p-0 tw-font-normal tw-text-foreground/80",style:{width:"233px",maxHeight:"500px",zIndex:"250"},onKeyDown:C,align:"start",ref:f,children:[a.jsx(Kl,{handleSort:()=>console.log("sorting"),handleLocationHistory:()=>console.log("location history"),handleBookmarks:()=>console.log("bookmarks")}),la.map((k,D)=>S(k).length>0&&a.jsxs("div",{children:[a.jsx(Wt,{className:"tw-font-semibold tw-text-foreground/80",children:Jl[k]}),S(k).map($=>a.jsx("div",{children:a.jsx(Yl,{bookId:$,handleSelectBook:()=>v($,!1),isSelected:o===$,handleHighlightBook:()=>d($),handleKeyDown:_,bookType:k,ref:J=>{o===$&&(m.current=J)},children:a.jsx(Wl,{handleSelectChapter:P,endChapter:rn($),activeChapter:e.bookNum===ae.bookIdToNumber($)?e.chapterNum:0,highlightedChapter:i,handleHighlightedChapter:J=>{l(J)}})})},$)),la.length-1!==D?a.jsx(jn,{}):void 0]},k))]})]})})}const hs=Xt.cva("pr-twp tw-inline-flex tw-items-center tw-justify-center tw-whitespace-nowrap tw-rounded-md tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-colors focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50",{variants:{variant:{default:"tw-bg-primary tw-text-primary-foreground hover:tw-bg-primary/90",destructive:"tw-bg-destructive tw-text-destructive-foreground hover:tw-bg-destructive/90",outline:"tw-border tw-border-input tw-bg-background hover:tw-bg-accent hover:tw-text-accent-foreground",secondary:"tw-bg-secondary tw-text-secondary-foreground hover:tw-bg-secondary/80",ghost:"hover:tw-bg-accent hover:tw-text-accent-foreground",link:"tw-text-primary tw-underline-offset-4 hover:tw-underline"},size:{default:"tw-h-10 tw-px-4 tw-py-2",sm:"tw-h-9 tw-rounded-md tw-px-3",lg:"tw-h-11 tw-rounded-md tw-px-8",icon:"tw-h-10 tw-w-10"}},defaultVariants:{variant:"default",size:"default"}}),fe=g.forwardRef(({className:e,variant:t,size:n,asChild:r=!1,...o},s)=>{const i=r?Ht.Slot:"button";return a.jsx(i,{className:N(hs({variant:t,size:n,className:e})),ref:s,...o})});fe.displayName="Button";const ac=Xt.cva("tw-text-sm tw-font-medium tw-leading-none peer-disabled:tw-cursor-not-allowed peer-disabled:tw-opacity-70"),qe=g.forwardRef(({className:e,...t},n)=>a.jsx(rs.Root,{ref:n,className:N("pr-twp",ac(),e),...t}));qe.displayName=rs.Root.displayName;const po=g.forwardRef(({className:e,...t},n)=>a.jsx(bn.Root,{className:N("pr-twp tw-grid tw-gap-2",e),...t,ref:n}));po.displayName=bn.Root.displayName;const Yn=g.forwardRef(({className:e,...t},n)=>a.jsx(bn.Item,{ref:n,className:N("pr-twp tw-aspect-square tw-h-4 tw-w-4 tw-rounded-full tw-border tw-border-primary tw-text-primary tw-ring-offset-background focus:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-cursor-not-allowed disabled:tw-opacity-50",e),...t,children:a.jsx(bn.Indicator,{className:"tw-flex tw-items-center tw-justify-center",children:a.jsx(Q.Circle,{className:"tw-h-2.5 tw-w-2.5 tw-fill-current tw-text-current"})})}));Yn.displayName=bn.Item.displayName;const sc=vn.Root,ic=vn.Trigger,gs=g.forwardRef(({className:e,align:t="center",sideOffset:n=4,...r},o)=>a.jsx(vn.Portal,{children:a.jsx(vn.Content,{ref:o,align:t,sideOffset:n,className:N("pr-twp tw-z-50 tw-w-72 tw-rounded-md tw-border tw-bg-popover tw-p-4 tw-text-popover-foreground tw-shadow-md tw-outline-none data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0 data-[state=closed]:tw-zoom-out-95 data-[state=open]:tw-zoom-in-95 data-[side=bottom]:tw-slide-in-from-top-2 data-[side=left]:tw-slide-in-from-right-2 data-[side=right]:tw-slide-in-from-left-2 data-[side=top]:tw-slide-in-from-bottom-2",e),...r})}));gs.displayName=vn.Content.displayName;const lc=be.Portal,bs=g.forwardRef(({className:e,...t},n)=>a.jsx(be.Overlay,{ref:n,className:N("tw-fixed tw-inset-0 tw-z-50 tw-bg-black/80 data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0",e),...t}));bs.displayName=be.Overlay.displayName;const cc=g.forwardRef(({className:e,children:t,...n},r)=>a.jsxs(lc,{children:[a.jsx(bs,{}),a.jsxs(be.Content,{ref:r,className:N("tw-fixed tw-left-[50%] tw-top-[50%] tw-z-50 tw-grid tw-w-full tw-max-w-lg tw-translate-x-[-50%] tw-translate-y-[-50%] tw-gap-4 tw-border tw-bg-background tw-p-6 tw-shadow-lg tw-duration-200 data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0 data-[state=closed]:tw-zoom-out-95 data-[state=open]:tw-zoom-in-95 data-[state=closed]:tw-slide-out-to-left-1/2 data-[state=closed]:tw-slide-out-to-top-[48%] data-[state=open]:tw-slide-in-from-left-1/2 data-[state=open]:tw-slide-in-from-top-[48%] sm:tw-rounded-lg",e),...n,children:[t,a.jsxs(be.Close,{className:"tw-absolute tw-right-4 tw-top-4 tw-rounded-sm tw-opacity-70 tw-ring-offset-background tw-transition-opacity hover:tw-opacity-100 focus:tw-outline-none focus:tw-ring-2 focus:tw-ring-ring focus:tw-ring-offset-2 disabled:tw-pointer-events-none data-[state=open]:tw-bg-accent data-[state=open]:tw-text-muted-foreground",children:[a.jsx(Q.X,{className:"tw-h-4 tw-w-4"}),a.jsx("span",{className:"tw-sr-only",children:"Close"})]})]})]}));cc.displayName=be.Content.displayName;const dc=g.forwardRef(({className:e,...t},n)=>a.jsx(be.Title,{ref:n,className:N("tw-text-lg tw-font-semibold tw-leading-none tw-tracking-tight",e),...t}));dc.displayName=be.Title.displayName;const uc=g.forwardRef(({className:e,...t},n)=>a.jsx(be.Description,{ref:n,className:N("tw-text-sm tw-text-muted-foreground",e),...t}));uc.displayName=be.Description.displayName;const vs=g.forwardRef(({className:e,...t},n)=>a.jsx(Oe.Command,{ref:n,className:N("tw-flex tw-h-full tw-w-full tw-flex-col tw-overflow-hidden tw-rounded-md tw-bg-popover tw-text-popover-foreground",e),...t}));vs.displayName=Oe.Command.displayName;const xs=g.forwardRef(({className:e,...t},n)=>a.jsxs("div",{className:"tw-flex tw-items-center tw-border-b tw-px-3",children:[a.jsx(Q.Search,{className:"tw-me-2 tw-h-4 tw-w-4 tw-shrink-0 tw-opacity-50"}),a.jsx(Oe.Command.Input,{ref:n,className:N("tw-flex tw-h-11 tw-w-full tw-rounded-md tw-bg-transparent tw-py-3 tw-text-sm tw-outline-none placeholder:tw-text-muted-foreground disabled:tw-cursor-not-allowed disabled:tw-opacity-50",e),...t})]}));xs.displayName=Oe.Command.Input.displayName;const ys=g.forwardRef(({className:e,...t},n)=>a.jsx(Oe.Command.List,{ref:n,className:N("tw-max-h-[300px] tw-overflow-y-auto tw-overflow-x-hidden",e),...t}));ys.displayName=Oe.Command.List.displayName;const Ns=g.forwardRef((e,t)=>a.jsx(Oe.Command.Empty,{ref:t,className:"tw-py-6 tw-text-center tw-text-sm",...e}));Ns.displayName=Oe.Command.Empty.displayName;const pc=g.forwardRef(({className:e,...t},n)=>a.jsx(Oe.Command.Group,{ref:n,className:N("tw-overflow-hidden tw-p-1 tw-text-foreground [&_[cmdk-group-heading]]:tw-px-2 [&_[cmdk-group-heading]]:tw-py-1.5 [&_[cmdk-group-heading]]:tw-text-xs [&_[cmdk-group-heading]]:tw-font-medium [&_[cmdk-group-heading]]:tw-text-muted-foreground",e),...t}));pc.displayName=Oe.Command.Group.displayName;const wc=g.forwardRef(({className:e,...t},n)=>a.jsx(Oe.Command.Separator,{ref:n,className:N("tw--mx-1 tw-h-px tw-bg-border",e),...t}));wc.displayName=Oe.Command.Separator.displayName;const ks=g.forwardRef(({className:e,...t},n)=>a.jsx(Oe.Command.Item,{ref:n,className:N("tw-relative tw-flex tw-cursor-default tw-select-none tw-items-center tw-rounded-sm tw-px-2 tw-py-1.5 tw-text-sm tw-outline-none data-[disabled=true]:tw-pointer-events-none data-[selected=true]:tw-bg-accent data-[selected=true]:tw-text-accent-foreground data-[disabled=true]:tw-opacity-50",e),...t}));ks.displayName=Oe.Command.Item.displayName;function fc(e){return typeof e=="string"?e:typeof e=="number"?e.toString():e.label}function Wn({id:e,options:t=[],buttonClassName:n,popoverContentClassName:r,value:o,onChange:s=()=>{},getOptionLabel:i=fc,buttonPlaceholder:l="",textPlaceholder:c="",commandEmptyMessage:d="No option found",buttonVariant:u="outline",dir:h="ltr",isDisabled:w=!1,...b}){const[x,f]=g.useState(!1);return a.jsxs(sc,{open:x,onOpenChange:f,...b,children:[a.jsx(ic,{asChild:!0,children:a.jsxs(fe,{variant:u,role:"combobox","aria-expanded":x,id:e,className:N("tw-w-[200px] tw-justify-between",n),disabled:w,children:[a.jsx("span",{className:"tw-overflow-hidden tw-text-ellipsis tw-whitespace-nowrap",children:o?i(o):l}),a.jsx(Q.ChevronsUpDown,{className:"tw-ms-2 tw-h-4 tw-w-4 tw-shrink-0 tw-opacity-50"})]})}),a.jsx(gs,{className:N("tw-w-[200px] tw-p-0",r),dir:h,children:a.jsxs(vs,{children:[a.jsx(xs,{dir:h,placeholder:c,className:"tw-text-inherit"}),a.jsx(Ns,{children:d}),a.jsx(ys,{children:t.map(m=>a.jsxs(ks,{value:i(m),onSelect:()=>{s(m),f(!1)},children:[a.jsx(Q.Check,{className:N("tw-me-2 tw-h-4 tw-w-4",{"tw-opacity-0":!o||i(o)!==i(m)})}),i(m)]},i(m)))})]})})]})}function Ss({startChapter:e,endChapter:t,handleSelectStartChapter:n,handleSelectEndChapter:r,isDisabled:o=!1,chapterCount:s}){const i=g.useMemo(()=>Array.from({length:s},(d,u)=>u+1),[s]),l=d=>{n(d),d>t&&r(d)},c=d=>{r(d),dd.toString(),value:e},"start chapter"),a.jsx(qe,{htmlFor:"end-chapters-combobox",children:"to"}),a.jsx(Wn,{isDisabled:o,onChange:c,buttonClassName:"tw-ml-2 tw-w-20",options:i,getOptionLabel:d=>d.toString(),value:t},"end chapter")]})}var Es=(e=>(e.CURRENT_BOOK="current book",e.CHOOSE_BOOKS="choose books",e))(Es||{});const mc=Object.freeze(["%webView_bookSelector_currentBook%","%webView_bookSelector_choose%","%webView_bookSelector_chooseBooks%"]),Tr=(e,t)=>e[t]??t;function hc({handleBookSelectionModeChange:e,currentBookName:t,onSelectBooks:n,selectedBookIds:r,chapterCount:o,endChapter:s,handleSelectEndChapter:i,startChapter:l,handleSelectStartChapter:c,localizedStrings:d}){const u=Tr(d,"%webView_bookSelector_currentBook%"),h=Tr(d,"%webView_bookSelector_choose%"),w=Tr(d,"%webView_bookSelector_chooseBooks%"),[b,x]=g.useState("current book"),f=m=>{x(m),e(m)};return a.jsx(po,{className:"pr-twp tw-flex",value:b,onValueChange:m=>f(m),children:a.jsxs("div",{className:"tw-flex tw-w-full tw-flex-col tw-gap-4",children:[a.jsxs("div",{className:"tw-grid tw-grid-cols-[25%,25%,50%]",children:[a.jsxs("div",{className:"tw-flex tw-items-center",children:[a.jsx(Yn,{value:"current book"}),a.jsx(qe,{className:"tw-ml-1",children:u})]}),a.jsx(qe,{className:"tw-flex tw-items-center",children:t}),a.jsx("div",{className:"tw-flex tw-items-center tw-justify-end",children:a.jsx(Ss,{isDisabled:b==="choose books",handleSelectStartChapter:c,handleSelectEndChapter:i,chapterCount:o,startChapter:l,endChapter:s})})]}),a.jsxs("div",{className:"tw-grid tw-grid-cols-[25%,50%,25%]",children:[a.jsxs("div",{className:"tw-flex tw-items-center",children:[a.jsx(Yn,{value:"choose books"}),a.jsx(qe,{className:"tw-ml-1",children:w})]}),a.jsx(qe,{className:"tw-flex tw-items-center",children:r.map(m=>ae.bookIdToEnglishName(m)).join(", ")}),a.jsx(fe,{disabled:b==="current book",onClick:()=>n(),children:h})]})]})})}function gc({table:e}){return a.jsxs(or,{children:[a.jsx(ts.DropdownMenuTrigger,{asChild:!0,children:a.jsxs(fe,{variant:"outline",size:"sm",className:"tw-ml-auto tw-hidden tw-h-8 lg:tw-flex",children:[a.jsx(Q.FilterIcon,{className:"tw-mr-2 tw-h-4 tw-w-4"}),"View"]})}),a.jsxs(En,{align:"end",className:"tw-w-[150px]",children:[a.jsx(Wt,{children:"Toggle columns"}),a.jsx(jn,{}),e.getAllColumns().filter(t=>t.getCanHide()).map(t=>a.jsx(ar,{className:"tw-capitalize",checked:t.getIsVisible(),onCheckedChange:n=>t.toggleVisibility(!!n),children:t.id},t.id))]})]})}const At=ge.Root,js=ge.Group,Bt=ge.Value,bt=g.forwardRef(({className:e,children:t,...n},r)=>a.jsxs(ge.Trigger,{ref:r,className:N("tw-flex tw-h-10 tw-w-full tw-items-center tw-justify-between tw-rounded-md tw-border tw-border-input tw-bg-background tw-px-3 tw-py-2 tw-text-sm tw-ring-offset-background placeholder:tw-text-muted-foreground focus:tw-outline-none focus:tw-ring-2 focus:tw-ring-ring focus:tw-ring-offset-2 disabled:tw-cursor-not-allowed disabled:tw-opacity-50 [&>span]:tw-line-clamp-1",e),...n,children:[t,a.jsx(ge.Icon,{asChild:!0,children:a.jsx(Q.ChevronDown,{className:"tw-h-4 tw-w-4 tw-opacity-50"})})]}));bt.displayName=ge.Trigger.displayName;const wo=g.forwardRef(({className:e,...t},n)=>a.jsx(ge.ScrollUpButton,{ref:n,className:N("tw-flex tw-cursor-default tw-items-center tw-justify-center tw-py-1",e),...t,children:a.jsx(Q.ChevronUp,{className:"tw-h-4 tw-w-4"})}));wo.displayName=ge.ScrollUpButton.displayName;const fo=g.forwardRef(({className:e,...t},n)=>a.jsx(ge.ScrollDownButton,{ref:n,className:N("tw-flex tw-cursor-default tw-items-center tw-justify-center tw-py-1",e),...t,children:a.jsx(Q.ChevronDown,{className:"tw-h-4 tw-w-4"})}));fo.displayName=ge.ScrollDownButton.displayName;const vt=g.forwardRef(({className:e,children:t,position:n="popper",...r},o)=>a.jsx(ge.Portal,{children:a.jsxs(ge.Content,{ref:o,className:N("pr-twp tw-relative tw-z-50 tw-max-h-96 tw-min-w-[8rem] tw-overflow-hidden tw-rounded-md tw-border tw-bg-popover tw-text-popover-foreground tw-shadow-md data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0 data-[state=closed]:tw-zoom-out-95 data-[state=open]:tw-zoom-in-95 data-[side=bottom]:tw-slide-in-from-top-2 data-[side=left]:tw-slide-in-from-right-2 data-[side=right]:tw-slide-in-from-left-2 data-[side=top]:tw-slide-in-from-bottom-2",n==="popper"&&"data-[side=bottom]:tw-translate-y-1 data-[side=left]:tw--translate-x-1 data-[side=right]:tw-translate-x-1 data-[side=top]:tw--translate-y-1",e),position:n,...r,children:[a.jsx(wo,{}),a.jsx(ge.Viewport,{className:N("tw-p-1",n==="popper"&&"tw-h-[var(--radix-select-trigger-height)] tw-w-full tw-min-w-[var(--radix-select-trigger-width)]"),children:t}),a.jsx(fo,{})]})}));vt.displayName=ge.Content.displayName;const Cs=g.forwardRef(({className:e,...t},n)=>a.jsx(ge.Label,{ref:n,className:N("tw-py-1.5 tw-pl-8 tw-pr-2 tw-text-sm tw-font-semibold",e),...t}));Cs.displayName=ge.Label.displayName;const Ae=g.forwardRef(({className:e,children:t,...n},r)=>a.jsxs(ge.Item,{ref:r,className:N("tw-relative tw-flex tw-w-full tw-cursor-default tw-select-none tw-items-center tw-rounded-sm tw-py-1.5 tw-pl-8 tw-pr-2 tw-text-sm tw-outline-none focus:tw-bg-accent focus:tw-text-accent-foreground data-[disabled]:tw-pointer-events-none data-[disabled]:tw-opacity-50",e),...n,children:[a.jsx("span",{className:"tw-absolute tw-left-2 tw-flex tw-h-3.5 tw-w-3.5 tw-items-center tw-justify-center",children:a.jsx(ge.ItemIndicator,{children:a.jsx(Q.Check,{className:"tw-h-4 tw-w-4"})})}),a.jsx(ge.ItemText,{children:t})]}));Ae.displayName=ge.Item.displayName;const Ts=g.forwardRef(({className:e,...t},n)=>a.jsx(ge.Separator,{ref:n,className:N("tw--mx-1 tw-my-1 tw-h-px tw-bg-muted",e),...t}));Ts.displayName=ge.Separator.displayName;function bc({table:e}){return a.jsx("div",{className:"tw-flex tw-items-center tw-justify-between tw-px-2 tw-pb-3 tw-pt-3",children:a.jsxs("div",{className:"tw-flex tw-items-center tw-space-x-6 lg:tw-space-x-8",children:[a.jsxs("div",{className:"tw-flex-1 tw-text-sm tw-text-muted-foreground",children:[e.getFilteredSelectedRowModel().rows.length," of"," ",e.getFilteredRowModel().rows.length," row(s) selected"]}),a.jsxs("div",{className:"tw-flex tw-items-center tw-space-x-2",children:[a.jsx("p",{className:"tw-text-nowrap tw-text-sm tw-font-medium",children:"Rows per page"}),a.jsxs(At,{value:`${e.getState().pagination.pageSize}`,onValueChange:t=>{e.setPageSize(Number(t))},children:[a.jsx(bt,{className:"tw-h-8 tw-w-[70px]",children:a.jsx(Bt,{placeholder:e.getState().pagination.pageSize})}),a.jsx(vt,{side:"top",children:[10,20,30,40,50].map(t=>a.jsx(Ae,{value:`${t}`,children:t},t))})]})]}),a.jsxs("div",{className:"tw-flex tw-w-[100px] tw-items-center tw-justify-center tw-text-sm tw-font-medium",children:["Page ",e.getState().pagination.pageIndex+1," of ",e.getPageCount()]}),a.jsxs("div",{className:"tw-flex tw-items-center tw-space-x-2",children:[a.jsxs(fe,{variant:"outline",size:"icon",className:"tw-hidden tw-h-8 tw-w-8 tw-p-0 lg:tw-flex",onClick:()=>e.setPageIndex(0),disabled:!e.getCanPreviousPage(),children:[a.jsx("span",{className:"tw-sr-only",children:"Go to first page"}),a.jsx(Q.ArrowLeftIcon,{className:"tw-h-4 tw-w-4"})]}),a.jsxs(fe,{variant:"outline",size:"icon",className:"tw-h-8 tw-w-8 tw-p-0",onClick:()=>e.previousPage(),disabled:!e.getCanPreviousPage(),children:[a.jsx("span",{className:"tw-sr-only",children:"Go to previous page"}),a.jsx(Q.ChevronLeftIcon,{className:"tw-h-4 tw-w-4"})]}),a.jsxs(fe,{variant:"outline",size:"icon",className:"tw-h-8 tw-w-8 tw-p-0",onClick:()=>e.nextPage(),disabled:!e.getCanNextPage(),children:[a.jsx("span",{className:"tw-sr-only",children:"Go to next page"}),a.jsx(Q.ChevronRightIcon,{className:"tw-h-4 tw-w-4"})]}),a.jsxs(fe,{variant:"outline",size:"icon",className:"tw-hidden tw-h-8 tw-w-8 tw-p-0 lg:tw-flex",onClick:()=>e.setPageIndex(e.getPageCount()-1),disabled:!e.getCanNextPage(),children:[a.jsx("span",{className:"tw-sr-only",children:"Go to last page"}),a.jsx(Q.ArrowRightIcon,{className:"tw-h-4 tw-w-4"})]})]})]})})}const Cn=g.forwardRef(({className:e,stickyHeader:t,...n},r)=>a.jsx("div",{className:N("pr-twp tw-relative tw-w-full",{"tw-overflow-auto":!t}),children:a.jsx("table",{ref:r,className:N("tw-w-full tw-caption-bottom tw-text-sm",e),...n})}));Cn.displayName="Table";const Tn=g.forwardRef(({className:e,stickyHeader:t,...n},r)=>a.jsx("thead",{ref:r,className:N({"tw-sticky tw-top-[-1px] tw-bg-background tw-drop-shadow-sm":t},"[&_tr]:tw-border-b",e),...n}));Tn.displayName="TableHeader";const Rn=g.forwardRef(({className:e,...t},n)=>a.jsx("tbody",{ref:n,className:N("[&_tr:last-child]:tw-border-0",e),...t}));Rn.displayName="TableBody";const Rs=g.forwardRef(({className:e,...t},n)=>a.jsx("tfoot",{ref:n,className:N("tw-border-t tw-bg-muted/50 tw-font-medium [&>tr]:last:tw-border-b-0",e),...t}));Rs.displayName="TableFooter";const Ze=g.forwardRef(({className:e,...t},n)=>a.jsx("tr",{ref:n,className:N("tw-border-b tw-transition-colors hover:tw-bg-muted/50 data-[state=selected]:tw-bg-muted",e),...t}));Ze.displayName="TableRow";const Vt=g.forwardRef(({className:e,...t},n)=>a.jsx("th",{ref:n,className:N("tw-h-12 tw-px-4 tw-text-start tw-align-middle tw-font-medium tw-text-muted-foreground [&:has([role=checkbox])]:tw-pe-0",e),...t}));Vt.displayName="TableHead";const xt=g.forwardRef(({className:e,...t},n)=>a.jsx("td",{ref:n,className:N("tw-p-4 tw-align-middle [&:has([role=checkbox])]:tw-pe-0",e),...t}));xt.displayName="TableCell";const Os=g.forwardRef(({className:e,...t},n)=>a.jsx("caption",{ref:n,className:N("tw-mt-4 tw-text-sm tw-text-muted-foreground",e),...t}));Os.displayName="TableCaption";function _s({columns:e,data:t,enablePagination:n=!1,showPaginationControls:r=!1,showColumnVisibilityControls:o=!1,stickyHeader:s=!1,onRowClickHandler:i=()=>{}}){var m;const[l,c]=g.useState([]),[d,u]=g.useState([]),[h,w]=g.useState({}),[b,x]=g.useState({}),f=Se.useReactTable({data:t,columns:e,getCoreRowModel:Se.getCoreRowModel(),...n&&{getPaginationRowModel:Se.getPaginationRowModel()},onSortingChange:c,getSortedRowModel:Se.getSortedRowModel(),onColumnFiltersChange:u,getFilteredRowModel:Se.getFilteredRowModel(),onColumnVisibilityChange:w,onRowSelectionChange:x,state:{sorting:l,columnFilters:d,columnVisibility:h,rowSelection:b}});return a.jsxs("div",{className:"pr-twp",children:[o&&a.jsx(gc,{table:f}),a.jsxs(Cn,{stickyHeader:s,children:[a.jsx(Tn,{stickyHeader:s,children:f.getHeaderGroups().map(S=>a.jsx(Ze,{children:S.headers.map(R=>a.jsx(Vt,{children:R.isPlaceholder?void 0:Se.flexRender(R.column.columnDef.header,R.getContext())},R.id))},S.id))}),a.jsx(Rn,{children:(m=f.getRowModel().rows)!=null&&m.length?f.getRowModel().rows.map(S=>a.jsx(Ze,{onClick:()=>i(S,f),"data-state":S.getIsSelected()&&"selected",children:S.getVisibleCells().map(R=>a.jsx(xt,{children:Se.flexRender(R.column.columnDef.cell,R.getContext())},R.id))},S.id)):a.jsx(Ze,{children:a.jsx(xt,{colSpan:e.length,className:"tw-h-24 tw-text-center",children:"No results."})})})]}),n&&a.jsxs("div",{className:"tw-flex tw-items-center tw-justify-end tw-space-x-2 tw-py-4",children:[a.jsx(fe,{variant:"outline",size:"sm",onClick:()=>f.previousPage(),disabled:!f.getCanPreviousPage(),children:"Previous"}),a.jsx(fe,{variant:"outline",size:"sm",onClick:()=>f.nextPage(),disabled:!f.getCanNextPage(),children:"Next"})]}),n&&r&&a.jsx(bc,{table:f})]})}function vc({occurrenceData:e,setScriptureReference:t,localizedStrings:n}){const r=n["%webView_inventory_occurrences_table_header_reference%"],o=n["%webView_inventory_occurrences_table_header_occurrence%"],s=g.useMemo(()=>{const i=[];return e.forEach(l=>{i.some(c=>W.deepEqual(c,l))||i.push(l)}),i},[e]);return a.jsxs(Cn,{stickyHeader:!0,children:[a.jsx(Tn,{stickyHeader:!0,children:a.jsxs(Ze,{children:[a.jsx(Vt,{children:r}),a.jsx(Vt,{children:o})]})}),a.jsx(Rn,{children:s.length>0&&s.map(i=>a.jsxs(Ze,{onClick:()=>{t(i.reference)},children:[a.jsx(xt,{children:`${ae.bookNumberToEnglishName(i.reference.bookNum)} ${i.reference.chapterNum}:${i.reference.verseNum}`}),a.jsx(xt,{children:i.text})]},`${i.reference.bookNum} ${i.reference.chapterNum}:${i.reference.verseNum}-${i.text}`))})]})}const sr=g.forwardRef(({className:e,...t},n)=>a.jsx(Ur.Root,{ref:n,className:N("tw-peer pr-twp tw-h-4 tw-w-4 tw-shrink-0 tw-rounded-sm tw-border tw-border-primary tw-ring-offset-background focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-cursor-not-allowed disabled:tw-opacity-50 data-[state=checked]:tw-bg-primary data-[state=checked]:tw-text-primary-foreground",e),...t,children:a.jsx(Ur.Indicator,{className:N("tw-flex tw-items-center tw-justify-center tw-text-current"),children:a.jsx(Q.Check,{className:"tw-h-4 tw-w-4"})})}));sr.displayName=Ur.Root.displayName;const Ps=e=>e.split(/(?:\r?\n|\r)|(?=(?:\\(?:v|c|id)))/g),Hr=e=>{const t=/^\\[vc]\s+(\d+)/,n=e.match(t);if(n)return+n[1]},Is=e=>{const t=e.match(/^\\id\s+([A-Za-z]+)/);return t?ae.bookIdToNumber(t[1]):0},Ms=(e,t,n)=>n.includes(e)?"unapproved":t.includes(e)?"approved":"unknown",$s=Xt.cva("pr-twp tw-inline-flex tw-items-center tw-justify-center tw-rounded-md tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-colors hover:tw-bg-muted hover:tw-text-muted-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50 data-[state=on]:tw-bg-accent data-[state=on]:tw-text-accent-foreground",{variants:{variant:{default:"tw-bg-transparent",outline:"tw-border tw-border-input tw-bg-transparent hover:tw-bg-accent hover:tw-text-accent-foreground"},size:{default:"tw-h-10 tw-px-3",sm:"tw-h-9 tw-px-2.5",lg:"tw-h-11 tw-px-5"}},defaultVariants:{variant:"default",size:"default"}}),xc=g.forwardRef(({className:e,variant:t,size:n,...r},o)=>a.jsx(os.Root,{ref:o,className:N($s({variant:t,size:n,className:e})),...r}));xc.displayName=os.Root.displayName;const Ds=g.createContext({size:"default",variant:"default"}),mo=g.forwardRef(({className:e,variant:t,size:n,children:r,...o},s)=>a.jsx(rr.Root,{ref:s,className:N("pr-twp tw-flex tw-items-center tw-justify-center tw-gap-1",e),...o,children:a.jsx(Ds.Provider,{value:{variant:t,size:n},children:r})}));mo.displayName=rr.Root.displayName;const fn=g.forwardRef(({className:e,children:t,variant:n,size:r,...o},s)=>{const i=g.useContext(Ds);return a.jsx(rr.Item,{ref:s,className:N($s({variant:i.variant||n,size:i.size||r}),e),...o,children:t})});fn.displayName=rr.Item.displayName;const ir=e=>e==="asc"?a.jsx(Q.ArrowUpIcon,{className:"tw-ms-2 tw-h-4 tw-w-4"}):e==="desc"?a.jsx(Q.ArrowDownIcon,{className:"tw-ms-2 tw-h-4 tw-w-4"}):a.jsx(Q.ArrowUpDownIcon,{className:"tw-ms-2 tw-h-4 tw-w-4"}),yc=e=>({accessorKey:"item",accessorFn:t=>t.items[0],header:({column:t})=>a.jsxs(fe,{variant:"ghost",onClick:()=>t.toggleSorting(void 0),children:[e,ir(t.getIsSorted())]})}),Nc=(e,t)=>({accessorKey:`item${t}`,accessorFn:n=>n.items[t],header:({column:n})=>a.jsxs(fe,{variant:"ghost",onClick:()=>n.toggleSorting(void 0),children:[e,ir(n.getIsSorted())]})}),kc=e=>({accessorKey:"count",header:({column:t})=>a.jsx("div",{className:"tw-flex tw-justify-end tw-tabular-nums",children:a.jsxs(fe,{variant:"ghost",onClick:()=>t.toggleSorting(void 0),children:[e,ir(t.getIsSorted())]})}),cell:({row:t})=>a.jsx("div",{className:"tw-flex tw-justify-end",children:t.getValue("count")})}),Rr=(e,t,n,r,o,s)=>{let i=[...n];e.forEach(c=>{t==="approved"?i.includes(c)||i.push(c):i=i.filter(d=>d!==c)}),r(i);let l=[...o];e.forEach(c=>{t==="unapproved"?l.includes(c)||l.push(c):l=l.filter(d=>d!==c)}),s(l)},Sc=(e,t,n,r,o)=>({accessorKey:"status",header:({column:s})=>a.jsx("div",{className:"tw-flex tw-justify-center",children:a.jsxs(fe,{variant:"ghost",onClick:()=>s.toggleSorting(void 0),children:[e,ir(s.getIsSorted())]})}),cell:({row:s})=>{const i=s.getValue("status"),l=s.getValue("item");return a.jsxs(mo,{value:i,variant:"outline",type:"single",children:[a.jsx(fn,{onClick:()=>Rr([l],"approved",t,n,r,o),value:"approved",children:a.jsx(Q.CircleCheckIcon,{})}),a.jsx(fn,{onClick:()=>Rr([l],"unapproved",t,n,r,o),value:"unapproved",children:a.jsx(Q.CircleXIcon,{})}),a.jsx(fn,{onClick:()=>Rr([l],"unknown",t,n,r,o),value:"unknown",children:a.jsx(Q.CircleHelpIcon,{})})]})}}),Ec=Object.freeze(["%webView_inventory_all%","%webView_inventory_approved%","%webView_inventory_unapproved%","%webView_inventory_unknown%","%webView_inventory_scope_currentBook%","%webView_inventory_scope_chapter%","%webView_inventory_scope_verse%","%webView_inventory_filter_text%","%webView_inventory_show_additional_items%","%webView_inventory_occurrences_table_header_reference%","%webView_inventory_occurrences_table_header_occurrence%"]),jc=(e,t,n)=>{let r=e;return t!=="all"&&(r=r.filter(o=>t==="approved"&&o.status==="approved"||t==="unapproved"&&o.status==="unapproved"||t==="unknown"&&o.status==="unknown")),n!==""&&(r=r.filter(o=>o.items[0].includes(n))),r},Cc=(e,t,n,r,o)=>{if(!e)return[];const s=[];let i=t.bookNum,l=t.chapterNum,c=t.verseNum;return Ps(e).forEach(u=>{u.startsWith("\\id")&&(i=Is(u),l=0,c=0),u.startsWith("\\c")&&(l=Hr(u),c=0),u.startsWith("\\v")&&(c=Hr(u),l===0&&(l=t.chapterNum));let h=o.exec(u)??void 0;for(;h;){const w=[];h.forEach(m=>w.push(m));const b=h.index,x=s.find(m=>W.deepEqual(m.items,w)),f={reference:{bookNum:i!==void 0?i:-1,chapterNum:l!==void 0?l:-1,verseNum:c!==void 0?c:-1},text:W.substring(u,Math.max(0,b-25),Math.min(b+25,u.length))};if(x)x.count+=1,x.occurrences.push(f);else{const m={items:w,count:1,status:Ms(w[0],n,r),occurrences:[f]};s.push(m)}h=o.exec(u)??void 0}}),s},Je=(e,t)=>e[t]??t;function Tc({scriptureReference:e,setScriptureReference:t,localizedStrings:n,extractItems:r,additionalItemsLabels:o,approvedItems:s,unapprovedItems:i,text:l,scope:c,onScopeChange:d,columns:u}){const h=Je(n,"%webView_inventory_all%"),w=Je(n,"%webView_inventory_approved%"),b=Je(n,"%webView_inventory_unapproved%"),x=Je(n,"%webView_inventory_unknown%"),f=Je(n,"%webView_inventory_scope_currentBook%"),m=Je(n,"%webView_inventory_scope_chapter%"),S=Je(n,"%webView_inventory_scope_verse%"),R=Je(n,"%webView_inventory_filter_text%"),j=Je(n,"%webView_inventory_show_additional_items%"),[E,v]=g.useState(!1),[P,V]=g.useState("all"),[U,C]=g.useState(""),[_,k]=g.useState([]),D=g.useMemo(()=>l?r instanceof RegExp?Cc(l,e,s,i,r):r(l,e,s,i):[],[l,r,e,s,i]),$=g.useMemo(()=>{if(E)return D;const y=[];return D.forEach(T=>{const z=T.items[0],L=y.find(B=>B.items[0]===z);L?(L.count+=T.count,L.occurrences=L.occurrences.concat(T.occurrences)):y.push({items:[z],count:T.count,occurrences:T.occurrences,status:T.status})}),y},[E,D]),J=g.useMemo(()=>jc($,P,U),[$,P,U]),Y=g.useMemo(()=>{var z,L;if(!E)return u;const y=(z=o==null?void 0:o.tableHeaders)==null?void 0:z.length;if(!y)return u;const T=[];for(let B=0;B{k([])},[J]);const F=(y,T)=>{T.setRowSelection(()=>{const z={};return z[y.index]=!0,z}),k(y.original.items)},te=y=>{if(y==="book"||y==="chapter"||y==="verse")d(y);else throw new Error(`Invalid scope value: ${y}`)},se=y=>{if(y==="all"||y==="approved"||y==="unapproved"||y==="unknown")V(y);else throw new Error(`Invalid status filter value: ${y}`)},oe=g.useMemo(()=>{if($.length===0||_.length===0)return[];const y=$.filter(T=>W.deepEqual(E?T.items:[T.items[0]],_));if(y.length>1)throw new Error("Selected item is not unique");return y[0].occurrences},[_,E,$]);return a.jsxs("div",{className:"pr-twp tw-flex tw-h-full tw-flex-col",children:[a.jsxs("div",{className:"tw-flex tw-items-stretch",children:[a.jsxs(At,{onValueChange:y=>se(y),defaultValue:P,children:[a.jsx(bt,{className:"tw-m-1",children:a.jsx(Bt,{placeholder:"Select filter"})}),a.jsxs(vt,{children:[a.jsx(Ae,{value:"all",children:h}),a.jsx(Ae,{value:"approved",children:w}),a.jsx(Ae,{value:"unapproved",children:b}),a.jsx(Ae,{value:"unknown",children:x})]})]}),a.jsxs(At,{onValueChange:y=>te(y),defaultValue:c,children:[a.jsx(bt,{className:"tw-m-1",children:a.jsx(Bt,{placeholder:"Select scope"})}),a.jsxs(vt,{children:[a.jsx(Ae,{value:"book",children:f}),a.jsx(Ae,{value:"chapter",children:m}),a.jsx(Ae,{value:"verse",children:S})]})]}),a.jsx(St,{className:"tw-m-1 tw-rounded-md tw-border",placeholder:R,value:U,onChange:y=>{C(y.target.value)}}),o&&a.jsxs("div",{className:"tw-m-1 tw-flex tw-items-center tw-rounded-md tw-border",children:[a.jsx(sr,{className:"tw-m-1",checked:E,onCheckedChange:y=>{k([]),v(y)}}),a.jsx(qe,{className:"tw-m-1 tw-flex-shrink-0 tw-whitespace-nowrap",children:(o==null?void 0:o.checkboxText)??j})]})]}),a.jsx("div",{className:"tw-m-1 tw-flex-1 tw-overflow-auto tw-rounded-md tw-border",children:a.jsx(_s,{columns:Y,data:J,onRowClickHandler:F,stickyHeader:!0})}),oe.length>0&&a.jsx("div",{className:"tw-m-1 tw-flex-1 tw-overflow-auto tw-rounded-md tw-border",children:a.jsx(vc,{occurrenceData:oe,setScriptureReference:t,localizedStrings:n})})]})}function As({onSearch:e,placeholder:t,isFullWidth:n}){const[r,o]=g.useState(""),s=i=>{o(i),e(i)};return a.jsx(St,{className:N("tw-flex tw-h-10 tw-rounded-md tw-border tw-border-input tw-bg-background tw-px-3 tw-py-2 tw-text-sm tw-ring-offset-background file:tw-border-0 file:tw-bg-transparent file:tw-text-sm file:tw-font-medium placeholder:tw-text-muted-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-[color:hsl(240,5%,64.9%)] focus-visible:tw-ring-offset-2 disabled:tw-cursor-not-allowed disabled:tw-opacity-50",{"tw-w-full":n}),placeholder:t,value:r,onChange:i=>s(i.target.value)})}const ho=g.forwardRef(({className:e,...t},n)=>a.jsx(_e.Root,{orientation:"vertical",ref:n,className:N("tw-flex tw-gap-1 tw-rounded-md tw-text-muted-foreground",e),...t}));ho.displayName=_e.List.displayName;const go=g.forwardRef(({className:e,...t},n)=>a.jsx(_e.List,{ref:n,className:N("tw-flex-fit tw-mlk-items-center tw-w-[124px] tw-justify-center tw-rounded-md tw-bg-muted tw-p-1 tw-text-muted-foreground",e),...t}));go.displayName=_e.List.displayName;const Bs=g.forwardRef(({className:e,...t},n)=>a.jsx(_e.Trigger,{ref:n,...t,className:N("overflow-clip tw-inline-flex tw-w-[116px] tw-cursor-pointer tw-items-center tw-justify-center tw-break-words tw-rounded-sm tw-border-0 tw-bg-muted tw-px-3 tw-py-1.5 tw-text-sm tw-font-medium tw-text-inherit tw-ring-offset-background tw-transition-all hover:tw-text-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50 data-[state=active]:tw-bg-background data-[state=active]:tw-text-foreground data-[state=active]:tw-shadow-sm",e)})),bo=g.forwardRef(({className:e,...t},n)=>a.jsx(_e.Content,{ref:n,className:N("tw-ms-5 tw-flex-grow tw-text-foreground tw-ring-offset-background focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2",e),...t}));bo.displayName=_e.Content.displayName;function Rc({tabList:e,onSearch:t,searchPlaceholder:n,headerTitle:r,isSearchBarFullWidth:o=!1,direction:s="ltr"}){return a.jsxs("div",{className:"pr-twp",children:[a.jsxs("div",{className:"tw-sticky tw-top-0 tw-space-y-2 tw-pb-2",children:[r?a.jsx("h1",{children:r}):"",a.jsx(As,{isFullWidth:o,onSearch:t,placeholder:n})]}),a.jsxs(ho,{dir:s,children:[a.jsx(go,{children:e.map(i=>a.jsx(Bs,{value:i.value,children:i.value},i.key))}),e.map(i=>a.jsx(bo,{value:i.value,children:i.content},i.key))]})]})}const lr=g.forwardRef(({className:e,orientation:t="horizontal",decorative:n=!0,...r},o)=>a.jsx(as.Root,{ref:o,decorative:n,orientation:t,className:N("pr-twp tw-shrink-0 tw-bg-border",t==="horizontal"?"tw-h-[1px] tw-w-full":"tw-h-full tw-w-[1px]",e),...r}));lr.displayName=as.Root.displayName;const Oc=be.Root,_c=be.Portal,Vs=M.forwardRef(({className:e,...t},n)=>a.jsx(be.Overlay,{className:N("tw-fixed tw-inset-0 tw-z-50 tw-bg-black/80 data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0",e),...t,ref:n}));Vs.displayName=be.Overlay.displayName;const Pc=Xt.cva("pr-twp tw-fixed tw-z-50 tw-gap-4 tw-bg-background tw-p-6 tw-shadow-lg tw-transition tw-ease-in-out data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-duration-300 data-[state=open]:tw-duration-500",{variants:{side:{top:"tw-inset-x-0 tw-top-0 tw-border-b data-[state=closed]:tw-slide-out-to-top data-[state=open]:tw-slide-in-from-top",bottom:"tw-inset-x-0 tw-bottom-0 tw-border-t data-[state=closed]:tw-slide-out-to-bottom data-[state=open]:tw-slide-in-from-bottom",left:"tw-inset-y-0 tw-left-0 tw-h-full tw-w-3/4 tw-border-r data-[state=closed]:tw-slide-out-to-left data-[state=open]:tw-slide-in-from-left sm:tw-max-w-sm",right:"tw-inset-y-0 tw-right-0 tw-h-full tw-w-3/4 tw- tw-border-l data-[state=closed]:tw-slide-out-to-right data-[state=open]:tw-slide-in-from-right sm:tw-max-w-sm"}},defaultVariants:{side:"right"}}),zs=M.forwardRef(({side:e="right",className:t,children:n,...r},o)=>a.jsxs(_c,{children:[a.jsx(Vs,{}),a.jsxs(be.Content,{ref:o,className:N(Pc({side:e}),t),...r,children:[n,a.jsxs(be.Close,{className:"tw-absolute tw-right-4 tw-top-4 tw-rounded-sm tw-opacity-70 tw-ring-offset-background tw-transition-opacity hover:tw-opacity-100 focus:tw-outline-none focus:tw-ring-2 focus:tw-ring-ring focus:tw-ring-offset-2 disabled:tw-pointer-events-none data-[state=open]:tw-bg-secondary",children:[a.jsx(Q.X,{className:"tw-h-4 tw-w-4"}),a.jsx("span",{className:"tw-sr-only",children:"Close"})]})]})]}));zs.displayName=be.Content.displayName;const Ic=M.forwardRef(({className:e,...t},n)=>a.jsx(be.Title,{ref:n,className:N("tw-text-lg tw-font-semibold tw-text-foreground",e),...t}));Ic.displayName=be.Title.displayName;const Mc=M.forwardRef(({className:e,...t},n)=>a.jsx(be.Description,{ref:n,className:N("tw-text-sm tw-text-muted-foreground",e),...t}));Mc.displayName=be.Description.displayName;function ca({className:e,...t}){return a.jsx("div",{className:N("pr-twp tw-animate-pulse tw-rounded-md tw-bg-muted",e),...t})}const $c=Sn.Provider,Dc=Sn.Root,Ac=Sn.Trigger,Ls=g.forwardRef(({className:e,sideOffset:t=4,...n},r)=>a.jsx(Sn.Content,{ref:r,sideOffset:t,className:N("pr-twp tw-z-50 tw-overflow-hidden tw-rounded-md tw-border tw-bg-popover tw-px-3 tw-py-1.5 tw-text-sm tw-text-popover-foreground tw-shadow-md tw-animate-in tw-fade-in-0 tw-zoom-in-95 data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=closed]:tw-zoom-out-95 data-[side=bottom]:tw-slide-in-from-top-2 data-[side=left]:tw-slide-in-from-right-2 data-[side=right]:tw-slide-in-from-left-2 data-[side=top]:tw-slide-in-from-bottom-2",e),...n}));Ls.displayName=Sn.Content.displayName;const Or=768;function Bc(){const[e,t]=M.useState(void 0);return M.useEffect(()=>{const n=window.matchMedia(`(max-width: ${Or-1}px)`),r=()=>{t(window.innerWidthn.removeEventListener("change",r)},[]),!!e}const Vc="sidebar:state",zc=60*60*24*7,Lc="16rem",Fc="18rem",Gc="3rem",Uc="b",Fs=g.createContext(void 0);function cr(){const e=g.useContext(Fs);if(!e)throw new Error("useSidebar must be used within a SidebarProvider.");return e}const Gs=g.forwardRef(({defaultOpen:e=!0,open:t,onOpenChange:n,className:r,style:o,children:s,...i},l)=>{const c=Bc(),[d,u]=g.useState(!1),[h,w]=g.useState(e),b=t??h,x=g.useCallback(R=>{const j=typeof R=="function"?R(b):R;n?n(j):w(j),document.cookie=`${Vc}=${j}; path=/; max-age=${zc}`},[n,b]),f=g.useCallback(()=>c?u(R=>!R):x(R=>!R),[c,x,u]);g.useEffect(()=>{const R=j=>{j.key===Uc&&(j.metaKey||j.ctrlKey)&&(j.preventDefault(),f())};return window.addEventListener("keydown",R),()=>window.removeEventListener("keydown",R)},[f]);const m=b?"expanded":"collapsed",S=g.useMemo(()=>({state:m,open:b,setOpen:x,isMobile:c,openMobile:d,setOpenMobile:u,toggleSidebar:f}),[m,b,x,c,d,u,f]);return a.jsx(Fs.Provider,{value:S,children:a.jsx($c,{delayDuration:0,children:a.jsx("div",{style:{"--sidebar-width":Lc,"--sidebar-width-icon":Gc,...o},className:N("tw-group/sidebar-wrapper pr-twp tw-flex tw-min-h-svh tw-w-full has-[[data-variant=inset]]:tw-bg-sidebar",r),ref:l,...i,children:s})})})});Gs.displayName="SidebarProvider";const Us=g.forwardRef(({side:e="left",variant:t="sidebar",collapsible:n="offcanvas",className:r,children:o,...s},i)=>{const{isMobile:l,state:c,openMobile:d,setOpenMobile:u}=cr();return n==="none"?a.jsx("div",{className:N("tw-flex tw-h-full tw-w-[--sidebar-width] tw-flex-col tw-bg-sidebar tw-text-sidebar-foreground",r),ref:i,...s,children:o}):l?a.jsx(Oc,{open:d,onOpenChange:u,...s,children:a.jsx(zs,{"data-sidebar":"sidebar","data-mobile":"true",className:"tw-w-[--sidebar-width] tw-bg-sidebar tw-p-0 tw-text-sidebar-foreground [&>button]:tw-hidden",style:{"--sidebar-width":Fc},side:e,children:a.jsx("div",{className:"tw-flex tw-h-full tw-w-full tw-flex-col",children:o})})}):a.jsxs("div",{ref:i,className:"tw-group tw-peer tw-hidden tw-text-sidebar-foreground md:tw-block","data-state":c,"data-collapsible":c==="collapsed"?n:"","data-variant":t,"data-side":e,children:[a.jsx("div",{className:N("tw-relative tw-h-svh tw-w-[--sidebar-width] tw-bg-transparent tw-transition-[width] tw-duration-200 tw-ease-linear","group-data-[collapsible=offcanvas]:tw-w-0","group-data-[side=right]:tw-rotate-180",t==="floating"||t==="inset"?"group-data-[collapsible=icon]:tw-w-[calc(var(--sidebar-width-icon)_+_theme(spacing.4))]":"group-data-[collapsible=icon]:tw-w-[--sidebar-width-icon]")}),a.jsx("div",{className:N("tw-absolute tw-inset-y-0 tw-z-10 tw-hidden tw-h-svh tw-w-[--sidebar-width] tw-transition-[left,right,width] tw-duration-200 tw-ease-linear md:tw-flex",e==="left"?"tw-left-0 group-data-[collapsible=offcanvas]:tw-left-[calc(var(--sidebar-width)*-1)]":"tw-right-0 group-data-[collapsible=offcanvas]:tw-right-[calc(var(--sidebar-width)*-1)]",t==="floating"||t==="inset"?"tw-p-2 group-data-[collapsible=icon]:tw-w-[calc(var(--sidebar-width-icon)_+_theme(spacing.4)_+2px)]":"group-data-[collapsible=icon]:tw-w-[--sidebar-width-icon] group-data-[side=left]:tw-border-r group-data-[side=right]:tw-border-l",r),...s,children:a.jsx("div",{"data-sidebar":"sidebar",className:"tw-flex tw-h-full tw-w-full tw-flex-col tw-bg-sidebar group-data-[variant=floating]:tw-rounded-lg group-data-[variant=floating]:tw-border group-data-[variant=floating]:tw-border-sidebar-border group-data-[variant=floating]:tw-shadow",children:o})})]})});Us.displayName="Sidebar";const qc=g.forwardRef(({className:e,onClick:t,...n},r)=>{const{toggleSidebar:o}=cr();return a.jsxs(fe,{ref:r,"data-sidebar":"trigger",variant:"ghost",size:"icon",className:N("tw-h-7 tw-w-7",e),onClick:s=>{t==null||t(s),o()},...n,children:[a.jsx(Q.PanelLeft,{}),a.jsx("span",{className:"tw-sr-only",children:"Toggle Sidebar"})]})});qc.displayName="SidebarTrigger";const Hc=g.forwardRef(({className:e,...t},n)=>{const{toggleSidebar:r}=cr();return a.jsx("button",{type:"button",ref:n,"data-sidebar":"rail","aria-label":"Toggle Sidebar",tabIndex:-1,onClick:r,title:"Toggle Sidebar",className:N("tw-absolute tw-inset-y-0 tw-z-20 tw-hidden tw-w-4 tw--translate-x-1/2 tw-transition-all tw-ease-linear after:tw-absolute after:tw-inset-y-0 after:tw-left-1/2 after:tw-w-[2px] hover:after:tw-bg-sidebar-border group-data-[side=left]:tw--right-4 group-data-[side=right]:tw-left-0 sm:tw-flex","[[data-side=left]_&]:tw-cursor-w-resize [[data-side=right]_&]:tw-cursor-e-resize","[[data-side=left][data-state=collapsed]_&]:tw-cursor-e-resize [[data-side=right][data-state=collapsed]_&]:tw-cursor-w-resize","group-data-[collapsible=offcanvas]:tw-translate-x-0 group-data-[collapsible=offcanvas]:after:tw-left-full group-data-[collapsible=offcanvas]:hover:tw-bg-sidebar","[[data-side=left][data-collapsible=offcanvas]_&]:tw--right-2","[[data-side=right][data-collapsible=offcanvas]_&]:tw--left-2",e),...t})});Hc.displayName="SidebarRail";const qs=g.forwardRef(({className:e,...t},n)=>a.jsx("main",{ref:n,className:N("tw-relative tw-flex tw-min-h-svh tw-flex-1 tw-flex-col tw-bg-background","peer-data-[variant=inset]:tw-min-h-[calc(100svh-theme(spacing.4))] md:peer-data-[variant=inset]:tw-m-2 md:peer-data-[state=collapsed]:peer-data-[variant=inset]:tw-ml-2 md:peer-data-[variant=inset]:tw-ml-0 md:peer-data-[variant=inset]:tw-rounded-xl md:peer-data-[variant=inset]:tw-shadow",e),...t}));qs.displayName="SidebarInset";const Xc=g.forwardRef(({className:e,...t},n)=>a.jsx(St,{ref:n,"data-sidebar":"input",className:N("tw-h-8 tw-w-full tw-bg-background tw-shadow-none focus-visible:tw-ring-2 focus-visible:tw-ring-sidebar-ring",e),...t}));Xc.displayName="SidebarInput";const Yc=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,"data-sidebar":"header",className:N("tw-flex tw-flex-col tw-gap-2 tw-p-2",e),...t}));Yc.displayName="SidebarHeader";const Wc=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,"data-sidebar":"footer",className:N("tw-flex tw-flex-col tw-gap-2 tw-p-2",e),...t}));Wc.displayName="SidebarFooter";const Kc=g.forwardRef(({className:e,...t},n)=>a.jsx(lr,{ref:n,"data-sidebar":"separator",className:N("tw-mx-2 tw-w-auto tw-bg-sidebar-border",e),...t}));Kc.displayName="SidebarSeparator";const Hs=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,"data-sidebar":"content",className:N("tw-flex tw-min-h-0 tw-flex-1 tw-flex-col tw-gap-2 tw-overflow-auto group-data-[collapsible=icon]:tw-overflow-hidden",e),...t}));Hs.displayName="SidebarContent";const Xr=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,"data-sidebar":"group",className:N("tw-relative tw-flex tw-w-full tw-min-w-0 tw-flex-col tw-p-2",e),...t}));Xr.displayName="SidebarGroup";const Yr=g.forwardRef(({className:e,asChild:t=!1,...n},r)=>{const o=t?Ht.Slot:"div";return a.jsx(o,{ref:r,"data-sidebar":"group-label",className:N("tw-flex tw-h-8 tw-shrink-0 tw-items-center tw-rounded-md tw-px-2 tw-text-xs tw-font-medium tw-text-sidebar-foreground/70 tw-outline-none tw-ring-sidebar-ring tw-transition-[margin,opa] tw-duration-200 tw-ease-linear focus-visible:tw-ring-2 [&>svg]:tw-size-4 [&>svg]:tw-shrink-0","group-data-[collapsible=icon]:tw--mt-8 group-data-[collapsible=icon]:tw-opacity-0",e),...n})});Yr.displayName="SidebarGroupLabel";const Jc=g.forwardRef(({className:e,asChild:t=!1,...n},r)=>{const o=t?Ht.Slot:"button";return a.jsx(o,{ref:r,"data-sidebar":"group-action",className:N("tw-absolute tw-right-3 tw-top-3.5 tw-flex tw-aspect-square tw-w-5 tw-items-center tw-justify-center tw-rounded-md tw-p-0 tw-text-sidebar-foreground tw-outline-none tw-ring-sidebar-ring tw-transition-transform hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground focus-visible:tw-ring-2 [&>svg]:tw-size-4 [&>svg]:tw-shrink-0","after:tw-absolute after:tw--inset-2 after:md:tw-hidden","group-data-[collapsible=icon]:tw-hidden",e),...n})});Jc.displayName="SidebarGroupAction";const Wr=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,"data-sidebar":"group-content",className:N("tw-w-full tw-text-sm",e),...t}));Wr.displayName="SidebarGroupContent";const Xs=g.forwardRef(({className:e,...t},n)=>a.jsx("ul",{ref:n,"data-sidebar":"menu",className:N("tw-flex tw-w-full tw-min-w-0 tw-flex-col tw-gap-1",e),...t}));Xs.displayName="SidebarMenu";const Ys=g.forwardRef(({className:e,...t},n)=>a.jsx("li",{ref:n,"data-sidebar":"menu-item",className:N("tw-group/menu-item tw-relative",e),...t}));Ys.displayName="SidebarMenuItem";const Zc=Xt.cva("tw-peer/menu-button tw-flex tw-w-full tw-items-center tw-gap-2 tw-overflow-hidden tw-rounded-md tw-p-2 tw-text-left tw-text-sm tw-outline-none tw-ring-sidebar-ring tw-transition-[width,height,padding] hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground focus-visible:tw-ring-2 active:tw-bg-sidebar-accent active:tw-text-sidebar-accent-foreground disabled:tw-pointer-events-none disabled:tw-opacity-50 tw-group-has-[[data-sidebar=menu-action]]/menu-item:pr-8 aria-disabled:tw-pointer-events-none aria-disabled:tw-opacity-50 data-[active=true]:tw-bg-sidebar-accent data-[active=true]:tw-font-medium data-[active=true]:tw-text-sidebar-accent-foreground data-[state=open]:hover:tw-bg-sidebar-accent data-[state=open]:hover:tw-text-sidebar-accent-foreground group-data-[collapsible=icon]:tw-!size-8 group-data-[collapsible=icon]:tw-!p-2 [&>span:last-child]:tw-truncate [&>svg]:tw-size-4 [&>svg]:tw-shrink-0",{variants:{variant:{default:"hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground",outline:"tw-bg-background tw-shadow-[0_0_0_1px_hsl(var(--sidebar-border))] hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground hover:tw-shadow-[0_0_0_1px_hsl(var(--sidebar-accent))]"},size:{default:"tw-h-8 tw-text-sm",sm:"tw-h-7 tw-text-xs",lg:"tw-h-12 tw-text-sm group-data-[collapsible=icon]:tw-!p-0"}},defaultVariants:{variant:"default",size:"default"}}),Ws=g.forwardRef(({asChild:e=!1,isActive:t=!1,variant:n="default",size:r="default",tooltip:o,className:s,...i},l)=>{const c=e?Ht.Slot:"button",{isMobile:d,state:u}=cr(),h=a.jsx(c,{ref:l,"data-sidebar":"menu-button","data-size":r,"data-active":t,className:N(Zc({variant:n,size:r}),s),...i});return o?(typeof o=="string"&&(o={children:o}),a.jsxs(Dc,{children:[a.jsx(Ac,{asChild:!0,children:h}),a.jsx(Ls,{side:"right",align:"center",hidden:u!=="collapsed"||d,...o})]})):h});Ws.displayName="SidebarMenuButton";const Qc=g.forwardRef(({className:e,asChild:t=!1,showOnHover:n=!1,...r},o)=>{const s=t?Ht.Slot:"button";return a.jsx(s,{ref:o,"data-sidebar":"menu-action",className:N("tw-peer-hover/menu-button:text-sidebar-accent-foreground tw-absolute tw-right-1 tw-top-1.5 tw-flex tw-aspect-square tw-w-5 tw-items-center tw-justify-center tw-rounded-md tw-p-0 tw-text-sidebar-foreground tw-outline-none tw-ring-sidebar-ring tw-transition-transform hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground focus-visible:tw-ring-2 [&>svg]:tw-size-4 [&>svg]:tw-shrink-0","after:tw-absolute after:tw--inset-2 after:md:tw-hidden","tw-peer-data-[size=sm]/menu-button:top-1","tw-peer-data-[size=default]/menu-button:top-1.5","tw-peer-data-[size=lg]/menu-button:top-2.5","group-data-[collapsible=icon]:tw-hidden",n&&"tw-group-focus-within/menu-item:opacity-100 tw-group-hover/menu-item:opacity-100 tw-peer-data-[active=true]/menu-button:text-sidebar-accent-foreground data-[state=open]:tw-opacity-100 md:tw-opacity-0",e),...r})});Qc.displayName="SidebarMenuAction";const ed=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,"data-sidebar":"menu-badge",className:N("tw-pointer-events-none tw-absolute tw-right-1 tw-flex tw-h-5 tw-min-w-5 tw-select-none tw-items-center tw-justify-center tw-rounded-md tw-px-1 tw-text-xs tw-font-medium tw-tabular-nums tw-text-sidebar-foreground","tw-peer-hover/menu-button:text-sidebar-accent-foreground tw-peer-data-[active=true]/menu-button:text-sidebar-accent-foreground","tw-peer-data-[size=sm]/menu-button:top-1","tw-peer-data-[size=default]/menu-button:top-1.5","tw-peer-data-[size=lg]/menu-button:top-2.5","group-data-[collapsible=icon]:tw-hidden",e),...t}));ed.displayName="SidebarMenuBadge";const td=g.forwardRef(({className:e,showIcon:t=!1,...n},r)=>{const o=g.useMemo(()=>`${Math.floor(Math.random()*40)+50}%`,[]);return a.jsxs("div",{ref:r,"data-sidebar":"menu-skeleton",className:N("tw-flex tw-h-8 tw-items-center tw-gap-2 tw-rounded-md tw-px-2",e),...n,children:[t&&a.jsx(ca,{className:"tw-size-4 tw-rounded-md","data-sidebar":"menu-skeleton-icon"}),a.jsx(ca,{className:"tw-h-4 tw-max-w-[--skeleton-width] tw-flex-1","data-sidebar":"menu-skeleton-text",style:{"--skeleton-width":o}})]})});td.displayName="SidebarMenuSkeleton";const nd=g.forwardRef(({className:e,...t},n)=>a.jsx("ul",{ref:n,"data-sidebar":"menu-sub",className:N("tw-mx-3.5 tw-flex tw-min-w-0 tw-translate-x-px tw-flex-col tw-gap-1 tw-border-l tw-border-sidebar-border tw-px-2.5 tw-py-0.5","group-data-[collapsible=icon]:tw-hidden",e),...t}));nd.displayName="SidebarMenuSub";const rd=g.forwardRef(({...e},t)=>a.jsx("li",{ref:t,...e}));rd.displayName="SidebarMenuSubItem";const od=g.forwardRef(({asChild:e=!1,size:t="md",isActive:n,className:r,...o},s)=>{const i=e?Ht.Slot:"a";return a.jsx(i,{ref:s,"data-sidebar":"menu-sub-button","data-size":t,"data-active":n,className:N("tw-flex tw-h-7 tw-min-w-0 tw--translate-x-px tw-items-center tw-gap-2 tw-overflow-hidden tw-rounded-md tw-px-2 tw-text-sidebar-foreground tw-outline-none tw-ring-sidebar-ring hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground focus-visible:tw-ring-2 active:tw-bg-sidebar-accent active:tw-text-sidebar-accent-foreground disabled:tw-pointer-events-none disabled:tw-opacity-50 aria-disabled:tw-pointer-events-none aria-disabled:tw-opacity-50 [&>span:last-child]:tw-truncate [&>svg]:tw-size-4 [&>svg]:tw-shrink-0 [&>svg]:tw-text-sidebar-accent-foreground","data-[active=true]:tw-bg-sidebar-accent data-[active=true]:tw-text-sidebar-accent-foreground",t==="sm"&&"tw-text-xs",t==="md"&&"tw-text-sm","group-data-[collapsible=icon]:tw-hidden",r),...o})});od.displayName="SidebarMenuSubButton";function Ks({id:e,extensionLabels:t,projectOptions:n,handleSelectSidebarItem:r,selectedSidebarItem:o}){const s=g.useCallback((l,c)=>{r(l,c)},[r]),i=g.useCallback(l=>{const c=n.find(d=>d.projectId===l);return c?c.projectName:l},[n]);return a.jsx(Us,{id:e,collapsible:"offcanvas",variant:"sidebar",children:a.jsxs(Hs,{children:[a.jsxs(Xr,{children:[a.jsx(Yr,{children:"Extensions"}),a.jsx(Wr,{children:a.jsx(Xs,{children:t.map(l=>a.jsx(Ys,{children:a.jsx(Ws,{onClick:()=>s(l),isActive:!(o!=null&&o.projectId)&&l===(o==null?void 0:o.label),children:l})},l))})})]}),a.jsxs(Xr,{children:[a.jsx(Yr,{children:"Projects"}),a.jsx(Wr,{children:a.jsx(Wn,{popoverContentClassName:"tw-z-[1000]",options:n.flatMap(l=>l.projectId),getOptionLabel:l=>i(l),buttonPlaceholder:"Type or select project",onChange:l=>{const c=i(l);s(c,l)},value:(o==null?void 0:o.projectId)??void 0})})]})]})})}function ad({id:e,direction:t="ltr",extensionLabels:n,projectOptions:r,children:o,handleSelectSidebarItem:s,selectedSidebarItem:i}){return a.jsxs(Gs,{dir:t,id:e,children:[a.jsx(Ks,{extensionLabels:n,projectOptions:r,handleSelectSidebarItem:s,selectedSidebarItem:i}),a.jsx(qs,{children:o})]})}const rt="scrBook",sd="scrRef",pt="source",id="details",ld="Scripture Reference",cd="Scripture Book",Js="Type",dd="Details";function ud(e,t){const n=t??!1;return[{accessorFn:r=>`${ae.bookNumberToId(r.start.bookNum)} ${r.start.chapterNum}:${r.start.verseNum}`,id:rt,header:(e==null?void 0:e.scriptureReferenceColumnName)??ld,cell:r=>{const o=r.row.original;return r.row.getIsGrouped()?ae.bookNumberToEnglishName(o.start.bookNum):r.row.groupingColumnId===rt?W.formatScrRef(o.start):void 0},getGroupingValue:r=>r.start.bookNum,sortingFn:(r,o)=>W.compareScrRefs(r.original.start,o.original.start),enableGrouping:!0},{accessorFn:r=>W.formatScrRef(r.start),id:sd,header:void 0,cell:r=>{const o=r.row.original;return r.row.getIsGrouped()?void 0:W.formatScrRef(o.start)},sortingFn:(r,o)=>W.compareScrRefs(r.original.start,o.original.start),enableGrouping:!1},{accessorFn:r=>r.source.displayName,id:pt,header:n?(e==null?void 0:e.typeColumnName)??Js:void 0,cell:r=>n||r.row.getIsGrouped()?r.getValue():void 0,getGroupingValue:r=>r.source.id,sortingFn:(r,o)=>r.original.source.displayName.localeCompare(o.original.source.displayName),enableGrouping:!0},{accessorFn:r=>r.detail,id,header:(e==null?void 0:e.detailsColumnName)??dd,cell:r=>r.getValue(),enableGrouping:!1}]}const pd=e=>{if(!("offset"in e.start))throw new Error("No offset available in range start");if(e.end&&!("offset"in e.end))throw new Error("No offset available in range end");const{offset:t}=e.start;let n=0;return e.end&&({offset:n}=e.end),!e.end||W.compareScrRefs(e.start,e.end)===0?`${W.scrRefToBBBCCCVVV(e.start)}+${t}`:`${W.scrRefToBBBCCCVVV(e.start)}+${t}-${W.scrRefToBBBCCCVVV(e.end)}+${n}`},da=e=>`${pd({start:e.start,end:e.end})} ${e.source.displayName} ${e.detail}`;function wd({sources:e,showColumnHeaders:t=!1,showSourceColumn:n=!1,scriptureReferenceColumnName:r,scriptureBookGroupName:o,typeColumnName:s,detailsColumnName:i,onRowSelected:l,direction:c="ltr"}){const[d,u]=g.useState([]),[h,w]=g.useState([{id:rt,desc:!1}]),[b,x]=g.useState({}),f=g.useMemo(()=>e.flatMap(C=>C.data.map(_=>({..._,source:C.source}))),[e]),m=g.useMemo(()=>ud({scriptureReferenceColumnName:r,typeColumnName:s,detailsColumnName:i},n),[r,s,i,n]);g.useEffect(()=>{d.includes(pt)?w([{id:pt,desc:!1},{id:rt,desc:!1}]):w([{id:rt,desc:!1}])},[d]);const S=Se.useReactTable({data:f,columns:m,state:{grouping:d,sorting:h,rowSelection:b},onGroupingChange:u,onSortingChange:w,onRowSelectionChange:x,getExpandedRowModel:Se.getExpandedRowModel(),getGroupedRowModel:Se.getGroupedRowModel(),getCoreRowModel:Se.getCoreRowModel(),getSortedRowModel:Se.getSortedRowModel(),getRowId:da,autoResetExpanded:!1,enableMultiRowSelection:!1,enableSubRowSelection:!1});g.useEffect(()=>{if(l){const C=S.getSelectedRowModel().rowsById,_=Object.keys(C);if(_.length===1){const k=f.find(D=>da(D)===_[0])||void 0;k&&l(k)}}},[b,f,l,S]);const R=o??cd,j=s??Js,E=[{label:"No Grouping",value:[]},{label:`Group by ${R}`,value:[rt]},{label:`Group by ${j}`,value:[pt]},{label:`Group by ${R} and ${j}`,value:[rt,pt]},{label:`Group by ${j} and ${R}`,value:[pt,rt]}],v=C=>{u(JSON.parse(C))},P=(C,_)=>{!C.getIsGrouped()&&!C.getIsSelected()&&C.getToggleSelectedHandler()(_)},V=(C,_)=>C.getIsGrouped()?"":N("banded-row",_%2===0?"even":"odd"),U=(C,_,k)=>{if(!((C==null?void 0:C.length)===0||_.depth{v(C)},children:[a.jsx(bt,{className:"tw-mb-1 tw-mt-2",children:a.jsx(Bt,{})}),a.jsx(vt,{position:"item-aligned",children:a.jsx(js,{children:E.map(C=>a.jsx(Ae,{value:JSON.stringify(C.value),children:C.label},C.label))})})]}),a.jsxs(Cn,{className:"tw-relative tw-flex tw-flex-col tw-overflow-y-auto tw-p-0",children:[t&&a.jsx(Tn,{children:S.getHeaderGroups().map(C=>a.jsx(Ze,{children:C.headers.filter(_=>_.column.columnDef.header).map(_=>a.jsx(Vt,{colSpan:_.colSpan,className:"top-0 tw-sticky",children:_.isPlaceholder?void 0:a.jsxs("div",{children:[_.column.getCanGroup()?a.jsx(fe,{variant:"ghost",title:`Toggle grouping by ${_.column.columnDef.header}`,onClick:_.column.getToggleGroupingHandler(),type:"button",children:_.column.getIsGrouped()?"🛑":"👊 "}):void 0," ",Se.flexRender(_.column.columnDef.header,_.getContext())]})},_.id))},C.id))}),a.jsx(Rn,{children:S.getRowModel().rows.map((C,_)=>a.jsx(Ze,{"data-state":C.getIsSelected()?"selected":"",className:N(V(C,_)),onClick:k=>P(C,k),children:C.getVisibleCells().map(k=>{if(!(k.getIsPlaceholder()||k.column.columnDef.enableGrouping&&!k.getIsGrouped()&&(k.column.columnDef.id!==pt||!n)))return a.jsx(xt,{className:N(k.column.columnDef.id,"tw-p-[1px]",U(d,C,k)),children:(()=>k.getIsGrouped()?a.jsxs(fe,{variant:"link",onClick:C.getToggleExpandedHandler(),type:"button",children:[C.getIsExpanded()&&a.jsx(Q.ChevronDown,{}),!C.getIsExpanded()&&(c==="ltr"?a.jsx(Q.ChevronRight,{}):a.jsx(Q.ChevronLeft,{}))," ",Se.flexRender(k.column.columnDef.cell,k.getContext())," (",C.subRows.length,")"]}):Se.flexRender(k.column.columnDef.cell,k.getContext()))()},k.id)})},C.id))})]})]})}const _r={[W.getLocalizeKeyForScrollGroupId("undefined")]:"Ø",[W.getLocalizeKeyForScrollGroupId(0)]:"A",[W.getLocalizeKeyForScrollGroupId(1)]:"B",[W.getLocalizeKeyForScrollGroupId(2)]:"C",[W.getLocalizeKeyForScrollGroupId(3)]:"D",[W.getLocalizeKeyForScrollGroupId(4)]:"E",[W.getLocalizeKeyForScrollGroupId(5)]:"F",[W.getLocalizeKeyForScrollGroupId(6)]:"G",[W.getLocalizeKeyForScrollGroupId(7)]:"H",[W.getLocalizeKeyForScrollGroupId(8)]:"I",[W.getLocalizeKeyForScrollGroupId(9)]:"J",[W.getLocalizeKeyForScrollGroupId(10)]:"K",[W.getLocalizeKeyForScrollGroupId(11)]:"L",[W.getLocalizeKeyForScrollGroupId(12)]:"M",[W.getLocalizeKeyForScrollGroupId(13)]:"N",[W.getLocalizeKeyForScrollGroupId(14)]:"O",[W.getLocalizeKeyForScrollGroupId(15)]:"P",[W.getLocalizeKeyForScrollGroupId(16)]:"Q",[W.getLocalizeKeyForScrollGroupId(17)]:"R",[W.getLocalizeKeyForScrollGroupId(18)]:"S",[W.getLocalizeKeyForScrollGroupId(19)]:"T",[W.getLocalizeKeyForScrollGroupId(20)]:"U",[W.getLocalizeKeyForScrollGroupId(21)]:"V",[W.getLocalizeKeyForScrollGroupId(22)]:"W",[W.getLocalizeKeyForScrollGroupId(23)]:"X",[W.getLocalizeKeyForScrollGroupId(24)]:"Y",[W.getLocalizeKeyForScrollGroupId(25)]:"Z"};function fd({availableScrollGroupIds:e,scrollGroupId:t,onChangeScrollGroupId:n,localizedStrings:r={}}){const o={..._r,...Object.fromEntries(Object.entries(r).map(([s,i])=>[s,s===i&&s in _r?_r[s]:i]))};return a.jsxs(At,{value:`${t}`,onValueChange:s=>n(s==="undefined"?void 0:parseInt(s,10)),children:[a.jsx(bt,{className:"pr-twp tw-w-auto",children:a.jsx(Bt,{placeholder:o[W.getLocalizeKeyForScrollGroupId(t)]??t})}),a.jsx(vt,{style:{zIndex:250},children:e.map(s=>a.jsx(Ae,{value:`${s}`,children:o[W.getLocalizeKeyForScrollGroupId(s)]},`${s}`))})]})}function md({children:e}){return a.jsx("div",{className:"pr-twp tw-grid",children:e})}function hd({primary:e,secondary:t,children:n,isLoading:r=!1,loadingMessage:o}){return a.jsxs("div",{className:"tw-flex tw-items-center tw-justify-between tw-space-x-4 tw-py-2",children:[a.jsxs("div",{children:[a.jsx("p",{className:"tw-text-sm tw-font-medium tw-leading-none",children:e}),a.jsx("p",{className:"tw-whitespace-normal tw-break-words tw-text-sm tw-text-muted-foreground",children:t})]}),r?a.jsx("p",{className:"tw-text-sm tw-text-muted-foreground",children:o}):a.jsx("div",{children:n})]})}function gd({primary:e,secondary:t,includeSeparator:n=!1}){return a.jsxs("div",{className:"tw-space-y-4 tw-py-2",children:[a.jsxs("div",{children:[a.jsx("h3",{className:"tw-text-lg tw-font-medium",children:e}),a.jsx("p",{className:"tw-text-sm tw-text-muted-foreground",children:t})]}),n?a.jsx(lr,{}):""]})}const vo=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,className:N("pr-twp tw-rounded-lg tw-border tw-bg-card tw-text-card-foreground tw-shadow-sm",e),...t}));vo.displayName="Card";const xo=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,className:N("pr-twp tw-flex tw-flex-col tw-space-y-1.5 tw-p-6",e),...t}));xo.displayName="CardHeader";const yo=g.forwardRef(({className:e,...t},n)=>a.jsx("h3",{ref:n,className:N("pr-twp tw-text-2xl tw-font-semibold tw-leading-none tw-tracking-tight",e),...t,children:t.children}));yo.displayName="CardTitle";const No=g.forwardRef(({className:e,...t},n)=>a.jsx("p",{ref:n,className:N("pr-twp tw-text-sm tw-text-muted-foreground",e),...t}));No.displayName="CardDescription";const Zs=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,className:N("pr-twp tw-p-6 tw-pt-0",e),...t}));Zs.displayName="CardContent";const Qs=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,className:N("pr-twp tw-flex tw-items-center tw-p-6 tw-pt-0",e),...t}));Qs.displayName="CardFooter";function bd({id:e,settingsGroupLabel:t,settingsGroupDescription:n,children:r}){return a.jsxs(vo,{id:e,children:[a.jsxs(xo,{children:[a.jsx(yo,{children:t}),n&&a.jsx(No,{children:n})]}),a.jsx(Ce.CardContent,{className:"tw-space-y-4",children:r})]})}function vd({id:e,className:t,listItems:n,selectedListItems:r,handleSelectListItem:o,createLabel:s}){return a.jsx("div",{id:e,className:t,children:n.map(i=>a.jsxs("div",{className:"tw-m-2 tw-flex tw-items-center",children:[a.jsx(sr,{className:"tw-mr-2 tw-align-middle",checked:r.includes(i),onCheckedChange:l=>o(i,l)}),a.jsx(qe,{children:s?s(i):i})]},i))})}function xd(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}function yd(e){if(e.__esModule)return e;var t=e.default;if(typeof t=="function"){var n=function r(){return this instanceof r?Reflect.construct(t,arguments,this.constructor):t.apply(this,arguments)};n.prototype=t.prototype}else n={};return Object.defineProperty(n,"__esModule",{value:!0}),Object.keys(e).forEach(function(r){var o=Object.getOwnPropertyDescriptor(e,r);Object.defineProperty(n,r,o.get?o:{enumerable:!0,get:function(){return e[r]}})}),n}var ko={},ei={exports:{}};(function(e){function t(n){return n&&n.__esModule?n:{default:n}}e.exports=t,e.exports.__esModule=!0,e.exports.default=e.exports})(ei);var Nd=ei.exports,Pr={};function So(e,t){return process.env.NODE_ENV==="production"?()=>null:function(...r){return e(...r)||t(...r)}}function O(){return O=Object.assign?Object.assign.bind():function(e){for(var t=1;t{t[n]=ti(e[n])}),t}function Qe(e,t,n={clone:!0}){const r=n.clone?O({},e):e;return mt(e)&&mt(t)&&Object.keys(t).forEach(o=>{o!=="__proto__"&&(mt(t[o])&&o in e&&mt(e[o])?r[o]=Qe(e[o],t[o],n):n.clone?r[o]=mt(t[o])?ti(t[o]):t[o]:r[o]=t[o])}),r}var Kr={exports:{}},zn={exports:{}},ie={};/** @license React v16.13.1 +"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const a=require("react/jsx-runtime"),g=require("react"),Q=require("lucide-react"),ot=require("clsx"),ml=require("tailwind-merge"),rs=require("@radix-ui/react-dropdown-menu"),W=require("platform-bible-utils"),Ht=require("@radix-ui/react-slot"),Xt=require("class-variance-authority"),hl=require("@radix-ui/react-label"),gl=require("@radix-ui/react-radio-group"),bl=require("@radix-ui/react-popover"),Re=require("cmdk"),vl=require("@radix-ui/react-dialog"),Se=require("@tanstack/react-table"),xl=require("@radix-ui/react-select"),yl=require("@radix-ui/react-checkbox"),Nl=require("@radix-ui/react-toggle-group"),kl=require("@radix-ui/react-toggle"),Sl=require("@radix-ui/react-tabs"),El=require("@radix-ui/react-separator"),jl=require("@radix-ui/react-tooltip"),Gr=require("@mui/styled-engine"),Me=require("@mui/material"),ln=require("react-dom"),os=require("sonner"),Cl=require("@radix-ui/react-slider"),Tl=require("@radix-ui/react-switch"),Rl=require("markdown-to-jsx");function ke(e){const t=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(e){for(const n in e)if(n!=="default"){const r=Object.getOwnPropertyDescriptor(e,n);Object.defineProperty(t,n,r.get?r:{enumerable:!0,get:()=>e[n]})}}return t.default=e,Object.freeze(t)}const M=ke(g),pe=ke(rs),as=ke(hl),bn=ke(gl),vn=ke(bl),be=ke(vl),ge=ke(xl),Ur=ke(yl),rr=ke(Nl),ss=ke(kl),Oe=ke(Sl),is=ke(El),Sn=ke(jl),Ol=ke(ln),cn=ke(Cl),qr=ke(Tl);const _l=ml.extendTailwindMerge({prefix:"tw-"});function N(...e){return _l(ot.clsx(e))}const St=g.forwardRef(({className:e,type:t,...n},r)=>a.jsx("input",{type:t,className:N("pr-twp tw-flex tw-h-10 tw-rounded-md tw-border tw-border-input tw-bg-background tw-px-3 tw-py-2 tw-text-sm tw-ring-offset-background file:tw-border-0 file:tw-bg-transparent file:tw-text-sm file:tw-font-medium file:tw-text-foreground placeholder:tw-text-muted-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-cursor-not-allowed disabled:tw-opacity-50",e),ref:r,...n}));St.displayName="Input";const Pl=g.forwardRef(({handleSearch:e,handleKeyDown:t,handleOnClick:n,handleSubmit:r,...o},s)=>a.jsxs("div",{className:"tw-relative",children:[a.jsx(St,{...o,type:"text",className:"tw-box-border tw-gap-2.5 tw-rounded-lg tw-border tw-border-solid tw-bg-background tw-py-2 tw-pl-4 tw-pr-3 tw-font-medium tw-shadow-none tw-outline-none",onChange:i=>e(i.target.value),onKeyDown:i=>{i.key==="Enter"&&r(),t(i)},onClick:n,ref:s}),a.jsx(Q.History,{className:"tw-absolute tw-right-3 tw-top-1/2 tw-h-4 tw-w-4 tw--translate-y-1/2 tw-transform tw-cursor-pointer tw-text-muted-foreground",onClick:()=>{console.log("back in history")}})]}));var Il=Object.defineProperty,Ml=(e,t,n)=>t in e?Il(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,ne=(e,t,n)=>Ml(e,typeof t!="symbol"?t+"":t,n);const gt=["GEN","EXO","LEV","NUM","DEU","JOS","JDG","RUT","1SA","2SA","1KI","2KI","1CH","2CH","EZR","NEH","EST","JOB","PSA","PRO","ECC","SNG","ISA","JER","LAM","EZK","DAN","HOS","JOL","AMO","OBA","JON","MIC","NAM","HAB","ZEP","HAG","ZEC","MAL","MAT","MRK","LUK","JHN","ACT","ROM","1CO","2CO","GAL","EPH","PHP","COL","1TH","2TH","1TI","2TI","TIT","PHM","HEB","JAS","1PE","2PE","1JN","2JN","3JN","JUD","REV","TOB","JDT","ESG","WIS","SIR","BAR","LJE","S3Y","SUS","BEL","1MA","2MA","3MA","4MA","1ES","2ES","MAN","PS2","ODA","PSS","JSA","JDB","TBS","SST","DNT","BLT","XXA","XXB","XXC","XXD","XXE","XXF","XXG","FRT","BAK","OTH","3ES","EZA","5EZ","6EZ","INT","CNC","GLO","TDX","NDX","DAG","PS3","2BA","LBA","JUB","ENO","1MQ","2MQ","3MQ","REP","4BA","LAO"],ao=["XXA","XXB","XXC","XXD","XXE","XXF","XXG","FRT","BAK","OTH","INT","CNC","GLO","TDX","NDX"],ls=["Genesis","Exodus","Leviticus","Numbers","Deuteronomy","Joshua","Judges","Ruth","1 Samuel","2 Samuel","1 Kings","2 Kings","1 Chronicles","2 Chronicles","Ezra","Nehemiah","Esther (Hebrew)","Job","Psalms","Proverbs","Ecclesiastes","Song of Songs","Isaiah","Jeremiah","Lamentations","Ezekiel","Daniel (Hebrew)","Hosea","Joel","Amos","Obadiah","Jonah","Micah","Nahum","Habakkuk","Zephaniah","Haggai","Zechariah","Malachi","Matthew","Mark","Luke","John","Acts","Romans","1 Corinthians","2 Corinthians","Galatians","Ephesians","Philippians","Colossians","1 Thessalonians","2 Thessalonians","1 Timothy","2 Timothy","Titus","Philemon","Hebrews","James","1 Peter","2 Peter","1 John","2 John","3 John","Jude","Revelation","Tobit","Judith","Esther Greek","Wisdom of Solomon","Sirach (Ecclesiasticus)","Baruch","Letter of Jeremiah","Song of 3 Young Men","Susanna","Bel and the Dragon","1 Maccabees","2 Maccabees","3 Maccabees","4 Maccabees","1 Esdras (Greek)","2 Esdras (Latin)","Prayer of Manasseh","Psalm 151","Odes","Psalms of Solomon","Joshua A. *obsolete*","Judges B. *obsolete*","Tobit S. *obsolete*","Susanna Th. *obsolete*","Daniel Th. *obsolete*","Bel Th. *obsolete*","Extra A","Extra B","Extra C","Extra D","Extra E","Extra F","Extra G","Front Matter","Back Matter","Other Matter","3 Ezra *obsolete*","Apocalypse of Ezra","5 Ezra (Latin Prologue)","6 Ezra (Latin Epilogue)","Introduction","Concordance ","Glossary ","Topical Index","Names Index","Daniel Greek","Psalms 152-155","2 Baruch (Apocalypse)","Letter of Baruch","Jubilees","Enoch","1 Meqabyan","2 Meqabyan","3 Meqabyan","Reproof (Proverbs 25-31)","4 Baruch (Rest of Baruch)","Laodiceans"],la=Ul();function Yt(e,t=!0){return t&&(e=e.toUpperCase()),e in la?la[e]:0}function so(e){return Yt(e)>0}function $l(e){const t=typeof e=="string"?Yt(e):e;return t>=40&&t<=66}function Al(e){return(typeof e=="string"?Yt(e):e)<=39}function cs(e){return e<=66}function Dl(e){const t=typeof e=="string"?Yt(e):e;return ps(t)&&!cs(t)}function*Bl(){for(let e=1;e<=gt.length;e++)yield e}const Vl=1,ds=gt.length;function zl(){return["XXA","XXB","XXC","XXD","XXE","XXF","XXG"]}function io(e,t="***"){const n=e-1;return n<0||n>=gt.length?t:gt[n]}function us(e){return e<=0||e>ds?"******":ls[e-1]}function Ll(e){return us(Yt(e))}function ps(e){const t=typeof e=="number"?io(e):e;return so(t)&&!ao.includes(t)}function Fl(e){const t=typeof e=="number"?io(e):e;return so(t)&&ao.includes(t)}function Gl(e){return ls[e-1].includes("*obsolete*")}function Ul(){const e={};for(let t=0;t(e[e.Unknown=0]="Unknown",e[e.Original=1]="Original",e[e.Septuagint=2]="Septuagint",e[e.Vulgate=3]="Vulgate",e[e.English=4]="English",e[e.RussianProtestant=5]="RussianProtestant",e[e.RussianOrthodox=6]="RussianOrthodox",e))(He||{});const Pe=class{constructor(t){if(ne(this,"name"),ne(this,"fullPath"),ne(this,"isPresent"),ne(this,"hasVerseSegments"),ne(this,"isCustomized"),ne(this,"baseVersification"),ne(this,"scriptureBooks"),ne(this,"_type"),t==null)throw new Error("Argument undefined");typeof t=="string"?(this.name=t,this._type=He[t]):(this._type=t,this.name=He[t])}get type(){return this._type}equals(t){return!t.type||!this.type?!1:t.type===this.type}};ne(Pe,"Original",new Pe(He.Original)),ne(Pe,"Septuagint",new Pe(He.Septuagint)),ne(Pe,"Vulgate",new Pe(He.Vulgate)),ne(Pe,"English",new Pe(He.English)),ne(Pe,"RussianProtestant",new Pe(He.RussianProtestant)),ne(Pe,"RussianOrthodox",new Pe(He.RussianOrthodox));let ut=Pe;function ca(e,t){const n=t[0];for(let r=1;r(e[e.Valid=0]="Valid",e[e.UnknownVersification=1]="UnknownVersification",e[e.OutOfRange=2]="OutOfRange",e[e.VerseOutOfOrder=3]="VerseOutOfOrder",e[e.VerseRepeated=4]="VerseRepeated",e))(ws||{});const je=class re{constructor(t,n,r,o){if(ne(this,"firstChapter"),ne(this,"lastChapter"),ne(this,"lastVerse"),ne(this,"hasSegmentsDefined"),ne(this,"text"),ne(this,"BBBCCCVVVS"),ne(this,"longHashCode"),ne(this,"versification"),ne(this,"rtlMark","‏"),ne(this,"_bookNum",0),ne(this,"_chapterNum",0),ne(this,"_verseNum",0),ne(this,"_verse"),r==null&&o==null)if(t!=null&&typeof t=="string"){const s=t,i=n!=null&&n instanceof ut?n:void 0;this.setEmpty(i),this.parse(s)}else if(t!=null&&typeof t=="number"){const s=n!=null&&n instanceof ut?n:void 0;this.setEmpty(s),this._verseNum=t%re.chapterDigitShifter,this._chapterNum=Math.floor(t%re.bookDigitShifter/re.chapterDigitShifter),this._bookNum=Math.floor(t/re.bookDigitShifter)}else if(n==null)if(t!=null&&t instanceof re){const s=t;this._bookNum=s.bookNum,this._chapterNum=s.chapterNum,this._verseNum=s.verseNum,this._verse=s.verse,this.versification=s.versification}else{if(t==null)return;const s=t instanceof ut?t:re.defaultVersification;this.setEmpty(s)}else throw new Error("VerseRef constructor not supported.");else if(t!=null&&n!=null&&r!=null)if(typeof t=="string"&&typeof n=="string"&&typeof r=="string")this.setEmpty(o),this.updateInternal(t,n,r);else if(typeof t=="number"&&typeof n=="number"&&typeof r=="number")this._bookNum=t,this._chapterNum=n,this._verseNum=r,this.versification=o??re.defaultVersification;else throw new Error("VerseRef constructor not supported.");else throw new Error("VerseRef constructor not supported.")}static isVerseParseable(t){return t.length>0&&"0123456789".includes(t[0])&&!t.endsWith(this.verseRangeSeparator)&&!t.endsWith(this.verseSequenceIndicator)}static tryParse(t){let n;try{return n=new re(t),{success:!0,verseRef:n}}catch(r){if(r instanceof nn)return n=new re,{success:!1,verseRef:n};throw r}}static getBBBCCCVVV(t,n,r){return t%re.bcvMaxValue*re.bookDigitShifter+(n>=0?n%re.bcvMaxValue*re.chapterDigitShifter:0)+(r>=0?r%re.bcvMaxValue:0)}static fromJSON(t){const{book:n,chapterNum:r,verseNum:o,verse:s,versificationStr:i}=t,l=s||o.toString();let c;return i&&(c=new ut(i)),n?new re(n,r.toString(),l,c):new re}static tryGetVerseNum(t){let n;if(!t)return n=-1,{success:!0,vNum:n};n=0;let r;for(let o=0;o"9")return o===0&&(n=-1),{success:!1,vNum:n};if(n=n*10+ +r-0,n>re.bcvMaxValue)return n=-1,{success:!1,vNum:n}}return{success:!0,vNum:n}}get isDefault(){return this.bookNum===0&&this.chapterNum===0&&this.verseNum===0&&this.versification==null}get hasMultiple(){return this._verse!=null&&(this._verse.includes(re.verseRangeSeparator)||this._verse.includes(re.verseSequenceIndicator))}get book(){return ae.bookNumberToId(this.bookNum,"")}set book(t){this.bookNum=ae.bookIdToNumber(t)}get chapter(){return this.isDefault||this._chapterNum<0?"":this._chapterNum.toString()}set chapter(t){const n=+t;this._chapterNum=Number.isInteger(n)?n:-1}get verse(){return this._verse!=null?this._verse:this.isDefault||this._verseNum<0?"":this._verseNum.toString()}set verse(t){const{success:n,vNum:r}=re.tryGetVerseNum(t);this._verse=n?void 0:t.replace(this.rtlMark,""),this._verseNum=r,!(this._verseNum>=0)&&({vNum:this._verseNum}=re.tryGetVerseNum(this._verse))}get bookNum(){return this._bookNum}set bookNum(t){if(t<=0||t>ae.lastBook)throw new nn("BookNum must be greater than zero and less than or equal to last book");this._bookNum=t}get chapterNum(){return this._chapterNum}set chapterNum(t){this.chapterNum=t}get verseNum(){return this._verseNum}set verseNum(t){this._verseNum=t}get versificationStr(){var t;return(t=this.versification)==null?void 0:t.name}set versificationStr(t){this.versification=this.versification!=null?new ut(t):void 0}get valid(){return this.validStatus===0}get validStatus(){return this.validateVerse(re.verseRangeSeparators,re.verseSequenceIndicators)}get BBBCCC(){return re.getBBBCCCVVV(this._bookNum,this._chapterNum,0)}get BBBCCCVVV(){return re.getBBBCCCVVV(this._bookNum,this._chapterNum,this._verseNum)}get isExcluded(){return!1}parse(t){if(t=t.replace(this.rtlMark,""),t.includes("/")){const s=t.split("/");if(t=s[0],s.length>1)try{const i=+s[1].trim();this.versification=new ut(He[i])}catch{throw new nn("Invalid reference : "+t)}}const n=t.trim().split(" ");if(n.length!==2)throw new nn("Invalid reference : "+t);const r=n[1].split(":"),o=+r[0];if(r.length!==2||ae.bookIdToNumber(n[0])===0||!Number.isInteger(o)||o<0||!re.isVerseParseable(r[1]))throw new nn("Invalid reference : "+t);this.updateInternal(n[0],r[0],r[1])}simplify(){this._verse=void 0}clone(){return new re(this)}toString(){const t=this.book;return t===""?"":`${t} ${this.chapter}:${this.verse}`}toJSON(){let t=this.verse;(t===""||t===this.verseNum.toString())&&(t=void 0);const n={book:this.book,chapterNum:this.chapterNum,verseNum:this.verseNum,verse:t,versificationStr:this.versificationStr};return t||delete n.verse,n}equals(t){return t instanceof re?t._bookNum===this._bookNum&&t._chapterNum===this._chapterNum&&t._verseNum===this._verseNum&&t.verse===this.verse&&(t.versification==null&&this.versification==null||t.versification!=null&&this.versification!=null&&t.versification.equals(this.versification)):!1}allVerses(t=!1,n=re.verseRangeSeparators,r=re.verseSequenceIndicators){if(this._verse==null||this.chapterNum<=0)return[this.clone()];const o=[],s=ca(this._verse,r);for(const i of s.map(l=>ca(l,n))){const l=this.clone();l.verse=i[0];const c=l.verseNum;if(o.push(l),i.length>1){const d=this.clone();if(d.verse=i[1],!t)for(let u=c+1;ui)return 3;if(r===i)return 4;r=i}return 0}get internalValid(){return this.versification==null?1:this._bookNum<=0||this._bookNum>ae.lastBook?2:(ae.isCanonical(this._bookNum),0)}setEmpty(t=re.defaultVersification){this._bookNum=0,this._chapterNum=-1,this._verse=void 0,this.versification=t}updateInternal(t,n,r){this.bookNum=ae.bookIdToNumber(t),this.chapter=n,this.verse=r}};ne(je,"defaultVersification",ut.English),ne(je,"verseRangeSeparator","-"),ne(je,"verseSequenceIndicator",","),ne(je,"verseRangeSeparators",[je.verseRangeSeparator]),ne(je,"verseSequenceIndicators",[je.verseSequenceIndicator]),ne(je,"chapterDigitShifter",1e3),ne(je,"bookDigitShifter",je.chapterDigitShifter*je.chapterDigitShifter),ne(je,"bcvMaxValue",je.chapterDigitShifter-1),ne(je,"ValidStatusType",ws);class nn extends Error{}const or=pe.Root,lo=pe.Trigger,fs=pe.Group,ql=pe.Portal,Hl=pe.Sub,Xl=pe.RadioGroup,ms=g.forwardRef(({className:e,inset:t,children:n,...r},o)=>a.jsxs(pe.SubTrigger,{ref:o,className:N("tw-flex tw-cursor-default tw-select-none tw-items-center tw-rounded-sm tw-px-2 tw-py-1.5 tw-text-sm tw-outline-none focus:tw-bg-accent data-[state=open]:tw-bg-accent",t&&"tw-pl-8",e),...r,children:[n,a.jsx(Q.ChevronRight,{className:"tw-ml-auto tw-h-4 tw-w-4"})]}));ms.displayName=pe.SubTrigger.displayName;const hs=g.forwardRef(({className:e,...t},n)=>a.jsx(pe.SubContent,{ref:n,className:N("tw-z-50 tw-min-w-[8rem] tw-overflow-hidden tw-rounded-md tw-border tw-bg-popover tw-p-1 tw-text-popover-foreground tw-shadow-lg data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0 data-[state=closed]:tw-zoom-out-95 data-[state=open]:tw-zoom-in-95 data-[side=bottom]:tw-slide-in-from-top-2 data-[side=left]:tw-slide-in-from-right-2 data-[side=right]:tw-slide-in-from-left-2 data-[side=top]:tw-slide-in-from-bottom-2",e),...t}));hs.displayName=pe.SubContent.displayName;const En=g.forwardRef(({className:e,sideOffset:t=4,...n},r)=>a.jsx(pe.Portal,{children:a.jsx(pe.Content,{ref:r,sideOffset:t,className:N("pr-twp tw-z-50 tw-min-w-[8rem] tw-overflow-hidden tw-rounded-md tw-border tw-bg-popover tw-p-1 tw-text-popover-foreground tw-shadow-md data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0 data-[state=closed]:tw-zoom-out-95 data-[state=open]:tw-zoom-in-95 data-[side=bottom]:tw-slide-in-from-top-2 data-[side=left]:tw-slide-in-from-right-2 data-[side=right]:tw-slide-in-from-left-2 data-[side=top]:tw-slide-in-from-bottom-2",e),...n})}));En.displayName=pe.Content.displayName;const co=g.forwardRef(({className:e,inset:t,...n},r)=>a.jsx(pe.Item,{ref:r,className:N("tw-cursor-default tw-select-none tw-items-center tw-rounded-sm tw-px-2 tw-py-1.5 tw-text-sm tw-outline-none tw-transition-colors focus:tw-bg-accent data-[disabled]:tw-pointer-events-none data-[disabled]:tw-opacity-50",t&&"tw-pl-8",e),...n}));co.displayName=pe.Item.displayName;const ar=g.forwardRef(({className:e,children:t,checked:n,...r},o)=>a.jsxs(pe.CheckboxItem,{ref:o,className:N("tw-relative tw-flex tw-cursor-default tw-select-none tw-items-center tw-rounded-sm tw-py-1.5 tw-pl-8 tw-pr-2 tw-text-sm tw-outline-none tw-transition-colors focus:tw-bg-accent focus:tw-text-accent-foreground data-[disabled]:tw-pointer-events-none data-[disabled]:tw-opacity-50",e),checked:n,...r,children:[a.jsx("span",{className:"tw-absolute tw-left-2 tw-flex tw-h-3.5 tw-w-3.5 tw-items-center tw-justify-center",children:a.jsx(pe.ItemIndicator,{children:a.jsx(Q.Check,{className:"tw-h-4 tw-w-4"})})}),t]}));ar.displayName=pe.CheckboxItem.displayName;const uo=g.forwardRef(({className:e,children:t,...n},r)=>a.jsxs(pe.RadioItem,{ref:r,className:N("tw-relative tw-flex tw-cursor-default tw-select-none tw-items-center tw-rounded-sm tw-py-1.5 tw-pl-8 tw-pr-2 tw-text-sm tw-outline-none tw-transition-colors focus:tw-bg-accent focus:tw-text-accent-foreground data-[disabled]:tw-pointer-events-none data-[disabled]:tw-opacity-50",e),...n,children:[a.jsx("span",{className:"tw-absolute tw-left-2 tw-flex tw-h-3.5 tw-w-3.5 tw-items-center tw-justify-center",children:a.jsx(pe.ItemIndicator,{children:a.jsx(Q.Circle,{className:"tw-h-2 tw-w-2 tw-fill-current"})})}),t]}));uo.displayName=pe.RadioItem.displayName;const Wt=g.forwardRef(({className:e,inset:t,...n},r)=>a.jsx(pe.Label,{ref:r,className:N("tw-px-2 tw-py-1.5 tw-text-sm tw-font-semibold",t&&"tw-pl-8",e),...n}));Wt.displayName=pe.Label.displayName;const jn=g.forwardRef(({className:e,...t},n)=>a.jsx(pe.Separator,{ref:n,className:N("tw--mx-1 tw-my-1 tw-h-px tw-bg-muted",e),...t}));jn.displayName=pe.Separator.displayName;function gs({className:e,...t}){return a.jsx("span",{className:N("tw-ml-auto tw-text-xs tw-tracking-widest tw-opacity-60",e),...t})}gs.displayName="DropdownMenuShortcut";const Yl=g.forwardRef(({bookId:e,handleSelectBook:t,isSelected:n,handleHighlightBook:r,handleKeyDown:o,bookType:s,children:i},l)=>a.jsxs(co,{ref:l,textValue:e,className:N("tw-mx-1 tw-px-1 tw-font-normal tw-text-foreground/80",{"tw-bg-amber-50 tw-text-yellow-900 data-[highlighted]:tw-bg-amber-100":n}),onSelect:c=>{c.preventDefault(),t()},onKeyDown:c=>{o(c)},onFocus:r,onMouseMove:r,children:[a.jsx("span",{className:N("tw-border-b-0 tw-border-l-2 tw-border-r-0 tw-border-t-0 tw-border-solid tw-px-2",{"tw-font-bold":n,"tw-border-l-red-200":s.toLowerCase()==="ot","tw-border-l-purple-200":s.toLowerCase()==="nt","tw-border-l-indigo-200":s.toLowerCase()==="dc"}),children:ae.bookIdToEnglishName(e)}),n&&a.jsx("div",{children:i})]},e));function Wl({handleSelectChapter:e,endChapter:t,activeChapter:n,highlightedChapter:r,handleHighlightedChapter:o}){const s=Array.from({length:t},(l,c)=>c+1),i=g.useCallback(l=>{o(l)},[o]);return a.jsx("div",{className:N("tw-flex tw-flex-wrap tw-items-start tw-justify-start tw-self-stretch"),children:s.map(l=>a.jsx("div",{className:N("tw-box-content tw-flex tw-h-4 tw-w-4 tw-cursor-pointer tw-items-center tw-justify-end tw-rounded-md tw-p-2 tw-text-amber-800",{"tw-font-semibold tw-text-amber-900":l===n,"tw-bg-amber-200":l===r}),onClick:c=>{c.preventDefault(),c.stopPropagation(),e(l)},role:"button",onKeyDown:c=>{c.key==="Enter"&&e(l)},tabIndex:0,onMouseMove:()=>i(l),children:l},l))})}function Kl({handleSort:e,handleLocationHistory:t,handleBookmarks:n}){return a.jsxs(Wt,{className:"tw-flex tw-justify-between",children:[a.jsx("p",{className:"tw-inline-block tw-align-middle",children:"Go To"}),a.jsxs("div",{className:"tw-flex tw-items-center",children:[a.jsx(Q.ArrowDownWideNarrow,{onClick:e,className:"tw-m-2 tw-h-4 tw-w-4 tw-cursor-pointer tw-gap-2"}),a.jsx(Q.Clock,{onClick:t,className:"tw-m-2 tw-h-4 tw-w-4 tw-cursor-pointer tw-gap-2"}),a.jsx(Q.Bookmark,{onClick:n,className:"tw-m-2 tw-h-4 tw-w-4 tw-cursor-pointer tw-gap-2"})]})]})}const wn=ae.allBookIds,Jl={OT:"Old Testament",NT:"New Testament",DC:"Deuterocanon"},da=["OT","NT","DC"],Zl=32+32+32,Ql=[/^(\w+)$/i,/^(\w+)(?:\s(\d+))$/i,/^(\w+)(?:\s(\d+):(\d+))$/i],ec=e=>({OT:wn.filter(n=>ae.isBookOT(n)),NT:wn.filter(n=>ae.isBookNT(n)),DC:wn.filter(n=>ae.isBookDC(n))})[e],rn=e=>W.getChaptersForBook(ae.bookIdToNumber(e));function tc(){return wn.map(t=>ae.bookIdToEnglishName(t))}function nc(e){return tc().includes(e)}function rc(e){const t=e.toLowerCase().replace(/^\w/,n=>n.toUpperCase());if(nc(t))return wn.find(r=>ae.bookIdToEnglishName(r)===t)}function oc({scrRef:e,handleSubmit:t}){const[n,r]=g.useState(""),[o,s]=g.useState(ae.bookNumberToId(e.bookNum)),[i,l]=g.useState(e.chapterNum??0),[c,d]=g.useState(ae.bookNumberToId(e.bookNum)),[u,h]=g.useState(!1),[w,b]=g.useState(u),x=g.useRef(void 0),f=g.useRef(void 0),m=g.useRef(void 0),S=g.useCallback(k=>ec(k).filter(A=>{const $=ae.bookIdToEnglishName(A).toLowerCase(),J=n.replace(/[^a-zA-Z]/g,"").toLowerCase();return $.includes(J)||A.toLowerCase().includes(J)}),[n]),R=k=>{r(k)},j=g.useRef(!1),E=g.useCallback(k=>{if(j.current){j.current=!1;return}h(k)},[]),v=g.useCallback((k,A,$,J)=>{if(l(ae.bookNumberToId(e.bookNum)!==k?1:e.chapterNum),A||rn(k)===-1){t({bookNum:ae.bookIdToNumber(k),chapterNum:$||1,verseNum:J||1}),h(!1),r("");return}s(o!==k?k:""),h(!A)},[t,e.bookNum,e.chapterNum,o]),P=k=>{k<=0||k>rn(o)||v(o,!0,k)},V=g.useCallback(()=>{Ql.forEach(k=>{const A=n.match(k);if(A){const[$,J=void 0,Y=void 0]=A.slice(1),F=rc($);(ae.isBookIdValid($)||F)&&v(F??$,!0,J?parseInt(J,10):1,Y?parseInt(Y,10):1)}})},[v,n]),U=g.useCallback(k=>{u?(k.key==="ArrowDown"||k.key==="ArrowUp")&&(typeof m<"u"&&m.current!==null?m.current.focus():typeof f<"u"&&f.current!==null&&f.current.focus(),k.preventDefault()):h(!0)},[u]),C=k=>{const{key:A}=k;A==="ArrowRight"||A==="ArrowLeft"||A==="ArrowDown"||A==="ArrowUp"||A==="Enter"||(x.current.dispatchEvent(new KeyboardEvent("keydown",{key:A})),x.current.focus())},_=k=>{const{key:A}=k;if(c===o){if(A==="Enter"){k.preventDefault(),v(o,!0,i);return}let $=0;if(A==="ArrowRight")if(i1)$=-1;else{k.preventDefault();return}else A==="ArrowDown"?$=6:A==="ArrowUp"&&($=-6);i+$<=0||i+$>rn(c)?l(0):$!==0&&(l(i+$),k.preventDefault())}};return g.useEffect(()=>{o===c?o===ae.bookNumberToId(e.bookNum)?l(e.chapterNum):l(1):l(0)},[c,e.bookNum,e.chapterNum,o]),g.useLayoutEffect(()=>{b(u)},[u]),g.useLayoutEffect(()=>{const k=setTimeout(()=>{if(w&&f.current&&m.current){const $=m.current.offsetTop-Zl;f.current.scrollTo({top:$,behavior:"instant"})}},10);return()=>{clearTimeout(k)}},[w]),a.jsx("div",{className:"pr-twp tw-flex",children:a.jsxs(or,{modal:!1,open:u,onOpenChange:E,children:[a.jsx(lo,{asChild:!0,children:a.jsx(Pl,{ref:x,value:n,handleSearch:R,handleKeyDown:U,handleOnClick:()=>{s(ae.bookNumberToId(e.bookNum)),d(ae.bookNumberToId(e.bookNum)),l(e.chapterNum>0?e.chapterNum:0),h(!0),x.current.focus()},onFocus:()=>{j.current=!0},handleSubmit:V,placeholder:`${ae.bookNumberToEnglishName(e.bookNum)} ${e.chapterNum}:${e.verseNum}`})}),a.jsxs(En,{className:"tw-m-1 tw-overflow-y-auto tw-p-0 tw-font-normal tw-text-foreground/80",style:{width:"233px",maxHeight:"500px",zIndex:"250"},onKeyDown:C,align:"start",ref:f,children:[a.jsx(Kl,{handleSort:()=>console.log("sorting"),handleLocationHistory:()=>console.log("location history"),handleBookmarks:()=>console.log("bookmarks")}),da.map((k,A)=>S(k).length>0&&a.jsxs("div",{children:[a.jsx(Wt,{className:"tw-font-semibold tw-text-foreground/80",children:Jl[k]}),S(k).map($=>a.jsx("div",{children:a.jsx(Yl,{bookId:$,handleSelectBook:()=>v($,!1),isSelected:o===$,handleHighlightBook:()=>d($),handleKeyDown:_,bookType:k,ref:J=>{o===$&&(m.current=J)},children:a.jsx(Wl,{handleSelectChapter:P,endChapter:rn($),activeChapter:e.bookNum===ae.bookIdToNumber($)?e.chapterNum:0,highlightedChapter:i,handleHighlightedChapter:J=>{l(J)}})})},$)),da.length-1!==A?a.jsx(jn,{}):void 0]},k))]})]})})}const bs=Xt.cva("pr-twp tw-inline-flex tw-items-center tw-justify-center tw-whitespace-nowrap tw-rounded-md tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-colors focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50",{variants:{variant:{default:"tw-bg-primary tw-text-primary-foreground hover:tw-bg-primary/90",destructive:"tw-bg-destructive tw-text-destructive-foreground hover:tw-bg-destructive/90",outline:"tw-border tw-border-input tw-bg-background hover:tw-bg-accent hover:tw-text-accent-foreground",secondary:"tw-bg-secondary tw-text-secondary-foreground hover:tw-bg-secondary/80",ghost:"hover:tw-bg-accent hover:tw-text-accent-foreground",link:"tw-text-primary tw-underline-offset-4 hover:tw-underline"},size:{default:"tw-h-10 tw-px-4 tw-py-2",sm:"tw-h-9 tw-rounded-md tw-px-3",lg:"tw-h-11 tw-rounded-md tw-px-8",icon:"tw-h-10 tw-w-10"}},defaultVariants:{variant:"default",size:"default"}}),fe=g.forwardRef(({className:e,variant:t,size:n,asChild:r=!1,...o},s)=>{const i=r?Ht.Slot:"button";return a.jsx(i,{className:N(bs({variant:t,size:n,className:e})),ref:s,...o})});fe.displayName="Button";const ac=Xt.cva("tw-text-sm tw-font-medium tw-leading-none peer-disabled:tw-cursor-not-allowed peer-disabled:tw-opacity-70"),qe=g.forwardRef(({className:e,...t},n)=>a.jsx(as.Root,{ref:n,className:N("pr-twp",ac(),e),...t}));qe.displayName=as.Root.displayName;const po=g.forwardRef(({className:e,...t},n)=>a.jsx(bn.Root,{className:N("pr-twp tw-grid tw-gap-2",e),...t,ref:n}));po.displayName=bn.Root.displayName;const Yn=g.forwardRef(({className:e,...t},n)=>a.jsx(bn.Item,{ref:n,className:N("pr-twp tw-aspect-square tw-h-4 tw-w-4 tw-rounded-full tw-border tw-border-primary tw-text-primary tw-ring-offset-background focus:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-cursor-not-allowed disabled:tw-opacity-50",e),...t,children:a.jsx(bn.Indicator,{className:"tw-flex tw-items-center tw-justify-center",children:a.jsx(Q.Circle,{className:"tw-h-2.5 tw-w-2.5 tw-fill-current tw-text-current"})})}));Yn.displayName=bn.Item.displayName;const sc=vn.Root,ic=vn.Trigger,vs=g.forwardRef(({className:e,align:t="center",sideOffset:n=4,...r},o)=>a.jsx(vn.Portal,{children:a.jsx(vn.Content,{ref:o,align:t,sideOffset:n,className:N("pr-twp tw-z-50 tw-w-72 tw-rounded-md tw-border tw-bg-popover tw-p-4 tw-text-popover-foreground tw-shadow-md tw-outline-none data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0 data-[state=closed]:tw-zoom-out-95 data-[state=open]:tw-zoom-in-95 data-[side=bottom]:tw-slide-in-from-top-2 data-[side=left]:tw-slide-in-from-right-2 data-[side=right]:tw-slide-in-from-left-2 data-[side=top]:tw-slide-in-from-bottom-2",e),...r})}));vs.displayName=vn.Content.displayName;const lc=be.Portal,xs=g.forwardRef(({className:e,...t},n)=>a.jsx(be.Overlay,{ref:n,className:N("tw-fixed tw-inset-0 tw-z-50 tw-bg-black/80 data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0",e),...t}));xs.displayName=be.Overlay.displayName;const cc=g.forwardRef(({className:e,children:t,...n},r)=>a.jsxs(lc,{children:[a.jsx(xs,{}),a.jsxs(be.Content,{ref:r,className:N("tw-fixed tw-left-[50%] tw-top-[50%] tw-z-50 tw-grid tw-w-full tw-max-w-lg tw-translate-x-[-50%] tw-translate-y-[-50%] tw-gap-4 tw-border tw-bg-background tw-p-6 tw-shadow-lg tw-duration-200 data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0 data-[state=closed]:tw-zoom-out-95 data-[state=open]:tw-zoom-in-95 data-[state=closed]:tw-slide-out-to-left-1/2 data-[state=closed]:tw-slide-out-to-top-[48%] data-[state=open]:tw-slide-in-from-left-1/2 data-[state=open]:tw-slide-in-from-top-[48%] sm:tw-rounded-lg",e),...n,children:[t,a.jsxs(be.Close,{className:"tw-absolute tw-right-4 tw-top-4 tw-rounded-sm tw-opacity-70 tw-ring-offset-background tw-transition-opacity hover:tw-opacity-100 focus:tw-outline-none focus:tw-ring-2 focus:tw-ring-ring focus:tw-ring-offset-2 disabled:tw-pointer-events-none data-[state=open]:tw-bg-accent data-[state=open]:tw-text-muted-foreground",children:[a.jsx(Q.X,{className:"tw-h-4 tw-w-4"}),a.jsx("span",{className:"tw-sr-only",children:"Close"})]})]})]}));cc.displayName=be.Content.displayName;const dc=g.forwardRef(({className:e,...t},n)=>a.jsx(be.Title,{ref:n,className:N("tw-text-lg tw-font-semibold tw-leading-none tw-tracking-tight",e),...t}));dc.displayName=be.Title.displayName;const uc=g.forwardRef(({className:e,...t},n)=>a.jsx(be.Description,{ref:n,className:N("tw-text-sm tw-text-muted-foreground",e),...t}));uc.displayName=be.Description.displayName;const ys=g.forwardRef(({className:e,...t},n)=>a.jsx(Re.Command,{ref:n,className:N("tw-flex tw-h-full tw-w-full tw-flex-col tw-overflow-hidden tw-rounded-md tw-bg-popover tw-text-popover-foreground",e),...t}));ys.displayName=Re.Command.displayName;const Ns=g.forwardRef(({className:e,...t},n)=>a.jsxs("div",{className:"tw-flex tw-items-center tw-border-b tw-px-3",children:[a.jsx(Q.Search,{className:"tw-me-2 tw-h-4 tw-w-4 tw-shrink-0 tw-opacity-50"}),a.jsx(Re.Command.Input,{ref:n,className:N("tw-flex tw-h-11 tw-w-full tw-rounded-md tw-bg-transparent tw-py-3 tw-text-sm tw-outline-none placeholder:tw-text-muted-foreground disabled:tw-cursor-not-allowed disabled:tw-opacity-50",e),...t})]}));Ns.displayName=Re.Command.Input.displayName;const ks=g.forwardRef(({className:e,...t},n)=>a.jsx(Re.Command.List,{ref:n,className:N("tw-max-h-[300px] tw-overflow-y-auto tw-overflow-x-hidden",e),...t}));ks.displayName=Re.Command.List.displayName;const Ss=g.forwardRef((e,t)=>a.jsx(Re.Command.Empty,{ref:t,className:"tw-py-6 tw-text-center tw-text-sm",...e}));Ss.displayName=Re.Command.Empty.displayName;const pc=g.forwardRef(({className:e,...t},n)=>a.jsx(Re.Command.Group,{ref:n,className:N("tw-overflow-hidden tw-p-1 tw-text-foreground [&_[cmdk-group-heading]]:tw-px-2 [&_[cmdk-group-heading]]:tw-py-1.5 [&_[cmdk-group-heading]]:tw-text-xs [&_[cmdk-group-heading]]:tw-font-medium [&_[cmdk-group-heading]]:tw-text-muted-foreground",e),...t}));pc.displayName=Re.Command.Group.displayName;const wc=g.forwardRef(({className:e,...t},n)=>a.jsx(Re.Command.Separator,{ref:n,className:N("tw--mx-1 tw-h-px tw-bg-border",e),...t}));wc.displayName=Re.Command.Separator.displayName;const Es=g.forwardRef(({className:e,...t},n)=>a.jsx(Re.Command.Item,{ref:n,className:N("tw-relative tw-flex tw-cursor-default tw-select-none tw-items-center tw-rounded-sm tw-px-2 tw-py-1.5 tw-text-sm tw-outline-none data-[disabled=true]:tw-pointer-events-none data-[selected=true]:tw-bg-accent data-[selected=true]:tw-text-accent-foreground data-[disabled=true]:tw-opacity-50",e),...t}));Es.displayName=Re.Command.Item.displayName;function fc(e){return typeof e=="string"?e:typeof e=="number"?e.toString():e.label}function Wn({id:e,options:t=[],buttonClassName:n,popoverContentClassName:r,value:o,onChange:s=()=>{},getOptionLabel:i=fc,buttonPlaceholder:l="",textPlaceholder:c="",commandEmptyMessage:d="No option found",buttonVariant:u="outline",dir:h="ltr",isDisabled:w=!1,...b}){const[x,f]=g.useState(!1);return a.jsxs(sc,{open:x,onOpenChange:f,...b,children:[a.jsx(ic,{asChild:!0,children:a.jsxs(fe,{variant:u,role:"combobox","aria-expanded":x,id:e,className:N("tw-w-[200px] tw-justify-between",n),disabled:w,children:[a.jsx("span",{className:"tw-overflow-hidden tw-text-ellipsis tw-whitespace-nowrap",children:o?i(o):l}),a.jsx(Q.ChevronsUpDown,{className:"tw-ms-2 tw-h-4 tw-w-4 tw-shrink-0 tw-opacity-50"})]})}),a.jsx(vs,{className:N("tw-w-[200px] tw-p-0",r),dir:h,children:a.jsxs(ys,{children:[a.jsx(Ns,{dir:h,placeholder:c,className:"tw-text-inherit"}),a.jsx(Ss,{children:d}),a.jsx(ks,{children:t.map(m=>a.jsxs(Es,{value:i(m),onSelect:()=>{s(m),f(!1)},children:[a.jsx(Q.Check,{className:N("tw-me-2 tw-h-4 tw-w-4",{"tw-opacity-0":!o||i(o)!==i(m)})}),i(m)]},i(m)))})]})})]})}function js({startChapter:e,endChapter:t,handleSelectStartChapter:n,handleSelectEndChapter:r,isDisabled:o=!1,chapterCount:s}){const i=g.useMemo(()=>Array.from({length:s},(d,u)=>u+1),[s]),l=d=>{n(d),d>t&&r(d)},c=d=>{r(d),dd.toString(),value:e},"start chapter"),a.jsx(qe,{htmlFor:"end-chapters-combobox",children:"to"}),a.jsx(Wn,{isDisabled:o,onChange:c,buttonClassName:"tw-ml-2 tw-w-20",options:i,getOptionLabel:d=>d.toString(),value:t},"end chapter")]})}var Cs=(e=>(e.CURRENT_BOOK="current book",e.CHOOSE_BOOKS="choose books",e))(Cs||{});const mc=Object.freeze(["%webView_bookSelector_currentBook%","%webView_bookSelector_choose%","%webView_bookSelector_chooseBooks%"]),Tr=(e,t)=>e[t]??t;function hc({handleBookSelectionModeChange:e,currentBookName:t,onSelectBooks:n,selectedBookIds:r,chapterCount:o,endChapter:s,handleSelectEndChapter:i,startChapter:l,handleSelectStartChapter:c,localizedStrings:d}){const u=Tr(d,"%webView_bookSelector_currentBook%"),h=Tr(d,"%webView_bookSelector_choose%"),w=Tr(d,"%webView_bookSelector_chooseBooks%"),[b,x]=g.useState("current book"),f=m=>{x(m),e(m)};return a.jsx(po,{className:"pr-twp tw-flex",value:b,onValueChange:m=>f(m),children:a.jsxs("div",{className:"tw-flex tw-w-full tw-flex-col tw-gap-4",children:[a.jsxs("div",{className:"tw-grid tw-grid-cols-[25%,25%,50%]",children:[a.jsxs("div",{className:"tw-flex tw-items-center",children:[a.jsx(Yn,{value:"current book"}),a.jsx(qe,{className:"tw-ml-1",children:u})]}),a.jsx(qe,{className:"tw-flex tw-items-center",children:t}),a.jsx("div",{className:"tw-flex tw-items-center tw-justify-end",children:a.jsx(js,{isDisabled:b==="choose books",handleSelectStartChapter:c,handleSelectEndChapter:i,chapterCount:o,startChapter:l,endChapter:s})})]}),a.jsxs("div",{className:"tw-grid tw-grid-cols-[25%,50%,25%]",children:[a.jsxs("div",{className:"tw-flex tw-items-center",children:[a.jsx(Yn,{value:"choose books"}),a.jsx(qe,{className:"tw-ml-1",children:w})]}),a.jsx(qe,{className:"tw-flex tw-items-center",children:r.map(m=>ae.bookIdToEnglishName(m)).join(", ")}),a.jsx(fe,{disabled:b==="current book",onClick:()=>n(),children:h})]})]})})}function gc({table:e}){return a.jsxs(or,{children:[a.jsx(rs.DropdownMenuTrigger,{asChild:!0,children:a.jsxs(fe,{variant:"outline",size:"sm",className:"tw-ml-auto tw-hidden tw-h-8 lg:tw-flex",children:[a.jsx(Q.FilterIcon,{className:"tw-mr-2 tw-h-4 tw-w-4"}),"View"]})}),a.jsxs(En,{align:"end",className:"tw-w-[150px]",children:[a.jsx(Wt,{children:"Toggle columns"}),a.jsx(jn,{}),e.getAllColumns().filter(t=>t.getCanHide()).map(t=>a.jsx(ar,{className:"tw-capitalize",checked:t.getIsVisible(),onCheckedChange:n=>t.toggleVisibility(!!n),children:t.id},t.id))]})]})}const Dt=ge.Root,Ts=ge.Group,Bt=ge.Value,bt=g.forwardRef(({className:e,children:t,...n},r)=>a.jsxs(ge.Trigger,{ref:r,className:N("tw-flex tw-h-10 tw-w-full tw-items-center tw-justify-between tw-rounded-md tw-border tw-border-input tw-bg-background tw-px-3 tw-py-2 tw-text-sm tw-ring-offset-background placeholder:tw-text-muted-foreground focus:tw-outline-none focus:tw-ring-2 focus:tw-ring-ring focus:tw-ring-offset-2 disabled:tw-cursor-not-allowed disabled:tw-opacity-50 [&>span]:tw-line-clamp-1",e),...n,children:[t,a.jsx(ge.Icon,{asChild:!0,children:a.jsx(Q.ChevronDown,{className:"tw-h-4 tw-w-4 tw-opacity-50"})})]}));bt.displayName=ge.Trigger.displayName;const wo=g.forwardRef(({className:e,...t},n)=>a.jsx(ge.ScrollUpButton,{ref:n,className:N("tw-flex tw-cursor-default tw-items-center tw-justify-center tw-py-1",e),...t,children:a.jsx(Q.ChevronUp,{className:"tw-h-4 tw-w-4"})}));wo.displayName=ge.ScrollUpButton.displayName;const fo=g.forwardRef(({className:e,...t},n)=>a.jsx(ge.ScrollDownButton,{ref:n,className:N("tw-flex tw-cursor-default tw-items-center tw-justify-center tw-py-1",e),...t,children:a.jsx(Q.ChevronDown,{className:"tw-h-4 tw-w-4"})}));fo.displayName=ge.ScrollDownButton.displayName;const vt=g.forwardRef(({className:e,children:t,position:n="popper",...r},o)=>a.jsx(ge.Portal,{children:a.jsxs(ge.Content,{ref:o,className:N("pr-twp tw-relative tw-z-50 tw-max-h-96 tw-min-w-[8rem] tw-overflow-hidden tw-rounded-md tw-border tw-bg-popover tw-text-popover-foreground tw-shadow-md data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0 data-[state=closed]:tw-zoom-out-95 data-[state=open]:tw-zoom-in-95 data-[side=bottom]:tw-slide-in-from-top-2 data-[side=left]:tw-slide-in-from-right-2 data-[side=right]:tw-slide-in-from-left-2 data-[side=top]:tw-slide-in-from-bottom-2",n==="popper"&&"data-[side=bottom]:tw-translate-y-1 data-[side=left]:tw--translate-x-1 data-[side=right]:tw-translate-x-1 data-[side=top]:tw--translate-y-1",e),position:n,...r,children:[a.jsx(wo,{}),a.jsx(ge.Viewport,{className:N("tw-p-1",n==="popper"&&"tw-h-[var(--radix-select-trigger-height)] tw-w-full tw-min-w-[var(--radix-select-trigger-width)]"),children:t}),a.jsx(fo,{})]})}));vt.displayName=ge.Content.displayName;const Rs=g.forwardRef(({className:e,...t},n)=>a.jsx(ge.Label,{ref:n,className:N("tw-py-1.5 tw-pl-8 tw-pr-2 tw-text-sm tw-font-semibold",e),...t}));Rs.displayName=ge.Label.displayName;const De=g.forwardRef(({className:e,children:t,...n},r)=>a.jsxs(ge.Item,{ref:r,className:N("tw-relative tw-flex tw-w-full tw-cursor-default tw-select-none tw-items-center tw-rounded-sm tw-py-1.5 tw-pl-8 tw-pr-2 tw-text-sm tw-outline-none focus:tw-bg-accent focus:tw-text-accent-foreground data-[disabled]:tw-pointer-events-none data-[disabled]:tw-opacity-50",e),...n,children:[a.jsx("span",{className:"tw-absolute tw-left-2 tw-flex tw-h-3.5 tw-w-3.5 tw-items-center tw-justify-center",children:a.jsx(ge.ItemIndicator,{children:a.jsx(Q.Check,{className:"tw-h-4 tw-w-4"})})}),a.jsx(ge.ItemText,{children:t})]}));De.displayName=ge.Item.displayName;const Os=g.forwardRef(({className:e,...t},n)=>a.jsx(ge.Separator,{ref:n,className:N("tw--mx-1 tw-my-1 tw-h-px tw-bg-muted",e),...t}));Os.displayName=ge.Separator.displayName;function bc({table:e}){return a.jsx("div",{className:"tw-flex tw-items-center tw-justify-between tw-px-2 tw-pb-3 tw-pt-3",children:a.jsxs("div",{className:"tw-flex tw-items-center tw-space-x-6 lg:tw-space-x-8",children:[a.jsxs("div",{className:"tw-flex-1 tw-text-sm tw-text-muted-foreground",children:[e.getFilteredSelectedRowModel().rows.length," of"," ",e.getFilteredRowModel().rows.length," row(s) selected"]}),a.jsxs("div",{className:"tw-flex tw-items-center tw-space-x-2",children:[a.jsx("p",{className:"tw-text-nowrap tw-text-sm tw-font-medium",children:"Rows per page"}),a.jsxs(Dt,{value:`${e.getState().pagination.pageSize}`,onValueChange:t=>{e.setPageSize(Number(t))},children:[a.jsx(bt,{className:"tw-h-8 tw-w-[70px]",children:a.jsx(Bt,{placeholder:e.getState().pagination.pageSize})}),a.jsx(vt,{side:"top",children:[10,20,30,40,50].map(t=>a.jsx(De,{value:`${t}`,children:t},t))})]})]}),a.jsxs("div",{className:"tw-flex tw-w-[100px] tw-items-center tw-justify-center tw-text-sm tw-font-medium",children:["Page ",e.getState().pagination.pageIndex+1," of ",e.getPageCount()]}),a.jsxs("div",{className:"tw-flex tw-items-center tw-space-x-2",children:[a.jsxs(fe,{variant:"outline",size:"icon",className:"tw-hidden tw-h-8 tw-w-8 tw-p-0 lg:tw-flex",onClick:()=>e.setPageIndex(0),disabled:!e.getCanPreviousPage(),children:[a.jsx("span",{className:"tw-sr-only",children:"Go to first page"}),a.jsx(Q.ArrowLeftIcon,{className:"tw-h-4 tw-w-4"})]}),a.jsxs(fe,{variant:"outline",size:"icon",className:"tw-h-8 tw-w-8 tw-p-0",onClick:()=>e.previousPage(),disabled:!e.getCanPreviousPage(),children:[a.jsx("span",{className:"tw-sr-only",children:"Go to previous page"}),a.jsx(Q.ChevronLeftIcon,{className:"tw-h-4 tw-w-4"})]}),a.jsxs(fe,{variant:"outline",size:"icon",className:"tw-h-8 tw-w-8 tw-p-0",onClick:()=>e.nextPage(),disabled:!e.getCanNextPage(),children:[a.jsx("span",{className:"tw-sr-only",children:"Go to next page"}),a.jsx(Q.ChevronRightIcon,{className:"tw-h-4 tw-w-4"})]}),a.jsxs(fe,{variant:"outline",size:"icon",className:"tw-hidden tw-h-8 tw-w-8 tw-p-0 lg:tw-flex",onClick:()=>e.setPageIndex(e.getPageCount()-1),disabled:!e.getCanNextPage(),children:[a.jsx("span",{className:"tw-sr-only",children:"Go to last page"}),a.jsx(Q.ArrowRightIcon,{className:"tw-h-4 tw-w-4"})]})]})]})})}const Cn=g.forwardRef(({className:e,stickyHeader:t,...n},r)=>a.jsx("div",{className:N("pr-twp tw-relative tw-w-full",{"tw-overflow-auto":!t}),children:a.jsx("table",{ref:r,className:N("tw-w-full tw-caption-bottom tw-text-sm",e),...n})}));Cn.displayName="Table";const Tn=g.forwardRef(({className:e,stickyHeader:t,...n},r)=>a.jsx("thead",{ref:r,className:N({"tw-sticky tw-top-[-1px] tw-bg-background tw-drop-shadow-sm":t},"[&_tr]:tw-border-b",e),...n}));Tn.displayName="TableHeader";const Rn=g.forwardRef(({className:e,...t},n)=>a.jsx("tbody",{ref:n,className:N("[&_tr:last-child]:tw-border-0",e),...t}));Rn.displayName="TableBody";const _s=g.forwardRef(({className:e,...t},n)=>a.jsx("tfoot",{ref:n,className:N("tw-border-t tw-bg-muted/50 tw-font-medium [&>tr]:last:tw-border-b-0",e),...t}));_s.displayName="TableFooter";const Ze=g.forwardRef(({className:e,...t},n)=>a.jsx("tr",{ref:n,className:N("tw-border-b tw-transition-colors hover:tw-bg-muted/50 data-[state=selected]:tw-bg-muted",e),...t}));Ze.displayName="TableRow";const Vt=g.forwardRef(({className:e,...t},n)=>a.jsx("th",{ref:n,className:N("tw-h-12 tw-px-4 tw-text-start tw-align-middle tw-font-medium tw-text-muted-foreground [&:has([role=checkbox])]:tw-pe-0",e),...t}));Vt.displayName="TableHead";const xt=g.forwardRef(({className:e,...t},n)=>a.jsx("td",{ref:n,className:N("tw-p-4 tw-align-middle [&:has([role=checkbox])]:tw-pe-0",e),...t}));xt.displayName="TableCell";const Ps=g.forwardRef(({className:e,...t},n)=>a.jsx("caption",{ref:n,className:N("tw-mt-4 tw-text-sm tw-text-muted-foreground",e),...t}));Ps.displayName="TableCaption";function Is({columns:e,data:t,enablePagination:n=!1,showPaginationControls:r=!1,showColumnVisibilityControls:o=!1,stickyHeader:s=!1,onRowClickHandler:i=()=>{}}){var m;const[l,c]=g.useState([]),[d,u]=g.useState([]),[h,w]=g.useState({}),[b,x]=g.useState({}),f=Se.useReactTable({data:t,columns:e,getCoreRowModel:Se.getCoreRowModel(),...n&&{getPaginationRowModel:Se.getPaginationRowModel()},onSortingChange:c,getSortedRowModel:Se.getSortedRowModel(),onColumnFiltersChange:u,getFilteredRowModel:Se.getFilteredRowModel(),onColumnVisibilityChange:w,onRowSelectionChange:x,state:{sorting:l,columnFilters:d,columnVisibility:h,rowSelection:b}});return a.jsxs("div",{className:"pr-twp",children:[o&&a.jsx(gc,{table:f}),a.jsxs(Cn,{stickyHeader:s,children:[a.jsx(Tn,{stickyHeader:s,children:f.getHeaderGroups().map(S=>a.jsx(Ze,{children:S.headers.map(R=>a.jsx(Vt,{children:R.isPlaceholder?void 0:Se.flexRender(R.column.columnDef.header,R.getContext())},R.id))},S.id))}),a.jsx(Rn,{children:(m=f.getRowModel().rows)!=null&&m.length?f.getRowModel().rows.map(S=>a.jsx(Ze,{onClick:()=>i(S,f),"data-state":S.getIsSelected()&&"selected",children:S.getVisibleCells().map(R=>a.jsx(xt,{children:Se.flexRender(R.column.columnDef.cell,R.getContext())},R.id))},S.id)):a.jsx(Ze,{children:a.jsx(xt,{colSpan:e.length,className:"tw-h-24 tw-text-center",children:"No results."})})})]}),n&&a.jsxs("div",{className:"tw-flex tw-items-center tw-justify-end tw-space-x-2 tw-py-4",children:[a.jsx(fe,{variant:"outline",size:"sm",onClick:()=>f.previousPage(),disabled:!f.getCanPreviousPage(),children:"Previous"}),a.jsx(fe,{variant:"outline",size:"sm",onClick:()=>f.nextPage(),disabled:!f.getCanNextPage(),children:"Next"})]}),n&&r&&a.jsx(bc,{table:f})]})}function vc({occurrenceData:e,setScriptureReference:t,localizedStrings:n}){const r=n["%webView_inventory_occurrences_table_header_reference%"],o=n["%webView_inventory_occurrences_table_header_occurrence%"],s=g.useMemo(()=>{const i=[];return e.forEach(l=>{i.some(c=>W.deepEqual(c,l))||i.push(l)}),i},[e]);return a.jsxs(Cn,{stickyHeader:!0,children:[a.jsx(Tn,{stickyHeader:!0,children:a.jsxs(Ze,{children:[a.jsx(Vt,{children:r}),a.jsx(Vt,{children:o})]})}),a.jsx(Rn,{children:s.length>0&&s.map(i=>a.jsxs(Ze,{onClick:()=>{t(i.reference)},children:[a.jsx(xt,{children:`${ae.bookNumberToEnglishName(i.reference.bookNum)} ${i.reference.chapterNum}:${i.reference.verseNum}`}),a.jsx(xt,{children:i.text})]},`${i.reference.bookNum} ${i.reference.chapterNum}:${i.reference.verseNum}-${i.text}`))})]})}const sr=g.forwardRef(({className:e,...t},n)=>a.jsx(Ur.Root,{ref:n,className:N("tw-peer pr-twp tw-h-4 tw-w-4 tw-shrink-0 tw-rounded-sm tw-border tw-border-primary tw-ring-offset-background focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-cursor-not-allowed disabled:tw-opacity-50 data-[state=checked]:tw-bg-primary data-[state=checked]:tw-text-primary-foreground",e),...t,children:a.jsx(Ur.Indicator,{className:N("tw-flex tw-items-center tw-justify-center tw-text-current"),children:a.jsx(Q.Check,{className:"tw-h-4 tw-w-4"})})}));sr.displayName=Ur.Root.displayName;const Ms=e=>e.split(/(?:\r?\n|\r)|(?=(?:\\(?:v|c|id)))/g),Hr=e=>{const t=/^\\[vc]\s+(\d+)/,n=e.match(t);if(n)return+n[1]},$s=e=>{const t=e.match(/^\\id\s+([A-Za-z]+)/);return t?ae.bookIdToNumber(t[1]):0},As=(e,t,n)=>n.includes(e)?"unapproved":t.includes(e)?"approved":"unknown",Ds=Xt.cva("pr-twp tw-inline-flex tw-items-center tw-justify-center tw-rounded-md tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-colors hover:tw-bg-muted hover:tw-text-muted-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50 data-[state=on]:tw-bg-accent data-[state=on]:tw-text-accent-foreground",{variants:{variant:{default:"tw-bg-transparent",outline:"tw-border tw-border-input tw-bg-transparent hover:tw-bg-accent hover:tw-text-accent-foreground"},size:{default:"tw-h-10 tw-px-3",sm:"tw-h-9 tw-px-2.5",lg:"tw-h-11 tw-px-5"}},defaultVariants:{variant:"default",size:"default"}}),xc=g.forwardRef(({className:e,variant:t,size:n,...r},o)=>a.jsx(ss.Root,{ref:o,className:N(Ds({variant:t,size:n,className:e})),...r}));xc.displayName=ss.Root.displayName;const Bs=g.createContext({size:"default",variant:"default"}),mo=g.forwardRef(({className:e,variant:t,size:n,children:r,...o},s)=>a.jsx(rr.Root,{ref:s,className:N("pr-twp tw-flex tw-items-center tw-justify-center tw-gap-1",e),...o,children:a.jsx(Bs.Provider,{value:{variant:t,size:n},children:r})}));mo.displayName=rr.Root.displayName;const fn=g.forwardRef(({className:e,children:t,variant:n,size:r,...o},s)=>{const i=g.useContext(Bs);return a.jsx(rr.Item,{ref:s,className:N(Ds({variant:i.variant||n,size:i.size||r}),e),...o,children:t})});fn.displayName=rr.Item.displayName;const ir=e=>e==="asc"?a.jsx(Q.ArrowUpIcon,{className:"tw-ms-2 tw-h-4 tw-w-4"}):e==="desc"?a.jsx(Q.ArrowDownIcon,{className:"tw-ms-2 tw-h-4 tw-w-4"}):a.jsx(Q.ArrowUpDownIcon,{className:"tw-ms-2 tw-h-4 tw-w-4"}),yc=e=>({accessorKey:"item",accessorFn:t=>t.items[0],header:({column:t})=>a.jsxs(fe,{variant:"ghost",onClick:()=>t.toggleSorting(void 0),children:[e,ir(t.getIsSorted())]})}),Nc=(e,t)=>({accessorKey:`item${t}`,accessorFn:n=>n.items[t],header:({column:n})=>a.jsxs(fe,{variant:"ghost",onClick:()=>n.toggleSorting(void 0),children:[e,ir(n.getIsSorted())]})}),kc=e=>({accessorKey:"count",header:({column:t})=>a.jsx("div",{className:"tw-flex tw-justify-end tw-tabular-nums",children:a.jsxs(fe,{variant:"ghost",onClick:()=>t.toggleSorting(void 0),children:[e,ir(t.getIsSorted())]})}),cell:({row:t})=>a.jsx("div",{className:"tw-flex tw-justify-end",children:t.getValue("count")})}),Rr=(e,t,n,r,o,s)=>{let i=[...n];e.forEach(c=>{t==="approved"?i.includes(c)||i.push(c):i=i.filter(d=>d!==c)}),r(i);let l=[...o];e.forEach(c=>{t==="unapproved"?l.includes(c)||l.push(c):l=l.filter(d=>d!==c)}),s(l)},Sc=(e,t,n,r,o)=>({accessorKey:"status",header:({column:s})=>a.jsx("div",{className:"tw-flex tw-justify-center",children:a.jsxs(fe,{variant:"ghost",onClick:()=>s.toggleSorting(void 0),children:[e,ir(s.getIsSorted())]})}),cell:({row:s})=>{const i=s.getValue("status"),l=s.getValue("item");return a.jsxs(mo,{value:i,variant:"outline",type:"single",children:[a.jsx(fn,{onClick:()=>Rr([l],"approved",t,n,r,o),value:"approved",children:a.jsx(Q.CircleCheckIcon,{})}),a.jsx(fn,{onClick:()=>Rr([l],"unapproved",t,n,r,o),value:"unapproved",children:a.jsx(Q.CircleXIcon,{})}),a.jsx(fn,{onClick:()=>Rr([l],"unknown",t,n,r,o),value:"unknown",children:a.jsx(Q.CircleHelpIcon,{})})]})}}),Ec=Object.freeze(["%webView_inventory_all%","%webView_inventory_approved%","%webView_inventory_unapproved%","%webView_inventory_unknown%","%webView_inventory_scope_currentBook%","%webView_inventory_scope_chapter%","%webView_inventory_scope_verse%","%webView_inventory_filter_text%","%webView_inventory_show_additional_items%","%webView_inventory_occurrences_table_header_reference%","%webView_inventory_occurrences_table_header_occurrence%"]),jc=(e,t,n)=>{let r=e;return t!=="all"&&(r=r.filter(o=>t==="approved"&&o.status==="approved"||t==="unapproved"&&o.status==="unapproved"||t==="unknown"&&o.status==="unknown")),n!==""&&(r=r.filter(o=>o.items[0].includes(n))),r},Cc=(e,t,n,r,o)=>{if(!e)return[];const s=[];let i=t.bookNum,l=t.chapterNum,c=t.verseNum;return Ms(e).forEach(u=>{u.startsWith("\\id")&&(i=$s(u),l=0,c=0),u.startsWith("\\c")&&(l=Hr(u),c=0),u.startsWith("\\v")&&(c=Hr(u),l===0&&(l=t.chapterNum));let h=o.exec(u)??void 0;for(;h;){const w=[];h.forEach(m=>w.push(m));const b=h.index,x=s.find(m=>W.deepEqual(m.items,w)),f={reference:{bookNum:i!==void 0?i:-1,chapterNum:l!==void 0?l:-1,verseNum:c!==void 0?c:-1},text:W.substring(u,Math.max(0,b-25),Math.min(b+25,u.length))};if(x)x.count+=1,x.occurrences.push(f);else{const m={items:w,count:1,status:As(w[0],n,r),occurrences:[f]};s.push(m)}h=o.exec(u)??void 0}}),s},Je=(e,t)=>e[t]??t;function Tc({scriptureReference:e,setScriptureReference:t,localizedStrings:n,extractItems:r,additionalItemsLabels:o,approvedItems:s,unapprovedItems:i,text:l,scope:c,onScopeChange:d,columns:u}){const h=Je(n,"%webView_inventory_all%"),w=Je(n,"%webView_inventory_approved%"),b=Je(n,"%webView_inventory_unapproved%"),x=Je(n,"%webView_inventory_unknown%"),f=Je(n,"%webView_inventory_scope_currentBook%"),m=Je(n,"%webView_inventory_scope_chapter%"),S=Je(n,"%webView_inventory_scope_verse%"),R=Je(n,"%webView_inventory_filter_text%"),j=Je(n,"%webView_inventory_show_additional_items%"),[E,v]=g.useState(!1),[P,V]=g.useState("all"),[U,C]=g.useState(""),[_,k]=g.useState([]),A=g.useMemo(()=>l?r instanceof RegExp?Cc(l,e,s,i,r):r(l,e,s,i):[],[l,r,e,s,i]),$=g.useMemo(()=>{if(E)return A;const y=[];return A.forEach(T=>{const z=T.items[0],L=y.find(B=>B.items[0]===z);L?(L.count+=T.count,L.occurrences=L.occurrences.concat(T.occurrences)):y.push({items:[z],count:T.count,occurrences:T.occurrences,status:T.status})}),y},[E,A]),J=g.useMemo(()=>jc($,P,U),[$,P,U]),Y=g.useMemo(()=>{var z,L;if(!E)return u;const y=(z=o==null?void 0:o.tableHeaders)==null?void 0:z.length;if(!y)return u;const T=[];for(let B=0;B{k([])},[J]);const F=(y,T)=>{T.setRowSelection(()=>{const z={};return z[y.index]=!0,z}),k(y.original.items)},te=y=>{if(y==="book"||y==="chapter"||y==="verse")d(y);else throw new Error(`Invalid scope value: ${y}`)},se=y=>{if(y==="all"||y==="approved"||y==="unapproved"||y==="unknown")V(y);else throw new Error(`Invalid status filter value: ${y}`)},oe=g.useMemo(()=>{if($.length===0||_.length===0)return[];const y=$.filter(T=>W.deepEqual(E?T.items:[T.items[0]],_));if(y.length>1)throw new Error("Selected item is not unique");return y[0].occurrences},[_,E,$]);return a.jsxs("div",{className:"pr-twp tw-flex tw-h-full tw-flex-col",children:[a.jsxs("div",{className:"tw-flex tw-items-stretch",children:[a.jsxs(Dt,{onValueChange:y=>se(y),defaultValue:P,children:[a.jsx(bt,{className:"tw-m-1",children:a.jsx(Bt,{placeholder:"Select filter"})}),a.jsxs(vt,{children:[a.jsx(De,{value:"all",children:h}),a.jsx(De,{value:"approved",children:w}),a.jsx(De,{value:"unapproved",children:b}),a.jsx(De,{value:"unknown",children:x})]})]}),a.jsxs(Dt,{onValueChange:y=>te(y),defaultValue:c,children:[a.jsx(bt,{className:"tw-m-1",children:a.jsx(Bt,{placeholder:"Select scope"})}),a.jsxs(vt,{children:[a.jsx(De,{value:"book",children:f}),a.jsx(De,{value:"chapter",children:m}),a.jsx(De,{value:"verse",children:S})]})]}),a.jsx(St,{className:"tw-m-1 tw-rounded-md tw-border",placeholder:R,value:U,onChange:y=>{C(y.target.value)}}),o&&a.jsxs("div",{className:"tw-m-1 tw-flex tw-items-center tw-rounded-md tw-border",children:[a.jsx(sr,{className:"tw-m-1",checked:E,onCheckedChange:y=>{k([]),v(y)}}),a.jsx(qe,{className:"tw-m-1 tw-flex-shrink-0 tw-whitespace-nowrap",children:(o==null?void 0:o.checkboxText)??j})]})]}),a.jsx("div",{className:"tw-m-1 tw-flex-1 tw-overflow-auto tw-rounded-md tw-border",children:a.jsx(Is,{columns:Y,data:J,onRowClickHandler:F,stickyHeader:!0})}),oe.length>0&&a.jsx("div",{className:"tw-m-1 tw-flex-1 tw-overflow-auto tw-rounded-md tw-border",children:a.jsx(vc,{occurrenceData:oe,setScriptureReference:t,localizedStrings:n})})]})}function ho({className:e,onSearch:t,placeholder:n,isFullWidth:r}){const[o,s]=g.useState(""),i=l=>{s(l),t(l)};return a.jsx(St,{className:N("tw-flex tw-h-10 tw-rounded-md tw-border tw-border-input tw-bg-background tw-px-3 tw-py-2 tw-text-sm tw-ring-offset-background file:tw-border-0 file:tw-bg-transparent file:tw-text-sm file:tw-font-medium placeholder:tw-text-muted-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-[color:hsl(240,5%,64.9%)] focus-visible:tw-ring-offset-2 disabled:tw-cursor-not-allowed disabled:tw-opacity-50",{"tw-w-full":r},e),placeholder:n,value:o,onChange:l=>i(l.target.value)})}const go=g.forwardRef(({className:e,...t},n)=>a.jsx(Oe.Root,{orientation:"vertical",ref:n,className:N("tw-flex tw-gap-1 tw-rounded-md tw-text-muted-foreground",e),...t}));go.displayName=Oe.List.displayName;const bo=g.forwardRef(({className:e,...t},n)=>a.jsx(Oe.List,{ref:n,className:N("tw-flex-fit tw-mlk-items-center tw-w-[124px] tw-justify-center tw-rounded-md tw-bg-muted tw-p-1 tw-text-muted-foreground",e),...t}));bo.displayName=Oe.List.displayName;const Vs=g.forwardRef(({className:e,...t},n)=>a.jsx(Oe.Trigger,{ref:n,...t,className:N("overflow-clip tw-inline-flex tw-w-[116px] tw-cursor-pointer tw-items-center tw-justify-center tw-break-words tw-rounded-sm tw-border-0 tw-bg-muted tw-px-3 tw-py-1.5 tw-text-sm tw-font-medium tw-text-inherit tw-ring-offset-background tw-transition-all hover:tw-text-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50 data-[state=active]:tw-bg-background data-[state=active]:tw-text-foreground data-[state=active]:tw-shadow-sm",e)})),vo=g.forwardRef(({className:e,...t},n)=>a.jsx(Oe.Content,{ref:n,className:N("tw-ms-5 tw-flex-grow tw-text-foreground tw-ring-offset-background focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2",e),...t}));vo.displayName=Oe.Content.displayName;function Rc({tabList:e,onSearch:t,searchPlaceholder:n,headerTitle:r,isSearchBarFullWidth:o=!1,direction:s="ltr"}){return a.jsxs("div",{className:"pr-twp",children:[a.jsxs("div",{className:"tw-sticky tw-top-0 tw-space-y-2 tw-pb-2",children:[r?a.jsx("h1",{children:r}):"",a.jsx(ho,{isFullWidth:o,onSearch:t,placeholder:n})]}),a.jsxs(go,{dir:s,children:[a.jsx(bo,{children:e.map(i=>a.jsx(Vs,{value:i.value,children:i.value},i.key))}),e.map(i=>a.jsx(vo,{value:i.value,children:i.content},i.key))]})]})}const lr=g.forwardRef(({className:e,orientation:t="horizontal",decorative:n=!0,...r},o)=>a.jsx(is.Root,{ref:o,decorative:n,orientation:t,className:N("pr-twp tw-shrink-0 tw-bg-border",t==="horizontal"?"tw-h-[1px] tw-w-full":"tw-h-full tw-w-[1px]",e),...r}));lr.displayName=is.Root.displayName;const Oc=be.Root,_c=be.Portal,zs=M.forwardRef(({className:e,...t},n)=>a.jsx(be.Overlay,{className:N("tw-fixed tw-inset-0 tw-z-50 tw-bg-black/80 data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0",e),...t,ref:n}));zs.displayName=be.Overlay.displayName;const Pc=Xt.cva("pr-twp tw-fixed tw-z-50 tw-gap-4 tw-bg-background tw-p-6 tw-shadow-lg tw-transition tw-ease-in-out data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-duration-300 data-[state=open]:tw-duration-500",{variants:{side:{top:"tw-inset-x-0 tw-top-0 tw-border-b data-[state=closed]:tw-slide-out-to-top data-[state=open]:tw-slide-in-from-top",bottom:"tw-inset-x-0 tw-bottom-0 tw-border-t data-[state=closed]:tw-slide-out-to-bottom data-[state=open]:tw-slide-in-from-bottom",left:"tw-inset-y-0 tw-left-0 tw-h-full tw-w-3/4 tw-border-r data-[state=closed]:tw-slide-out-to-left data-[state=open]:tw-slide-in-from-left sm:tw-max-w-sm",right:"tw-inset-y-0 tw-right-0 tw-h-full tw-w-3/4 tw- tw-border-l data-[state=closed]:tw-slide-out-to-right data-[state=open]:tw-slide-in-from-right sm:tw-max-w-sm"}},defaultVariants:{side:"right"}}),Ls=M.forwardRef(({side:e="right",className:t,children:n,...r},o)=>a.jsxs(_c,{children:[a.jsx(zs,{}),a.jsxs(be.Content,{ref:o,className:N(Pc({side:e}),t),...r,children:[n,a.jsxs(be.Close,{className:"tw-absolute tw-right-4 tw-top-4 tw-rounded-sm tw-opacity-70 tw-ring-offset-background tw-transition-opacity hover:tw-opacity-100 focus:tw-outline-none focus:tw-ring-2 focus:tw-ring-ring focus:tw-ring-offset-2 disabled:tw-pointer-events-none data-[state=open]:tw-bg-secondary",children:[a.jsx(Q.X,{className:"tw-h-4 tw-w-4"}),a.jsx("span",{className:"tw-sr-only",children:"Close"})]})]})]}));Ls.displayName=be.Content.displayName;const Ic=M.forwardRef(({className:e,...t},n)=>a.jsx(be.Title,{ref:n,className:N("tw-text-lg tw-font-semibold tw-text-foreground",e),...t}));Ic.displayName=be.Title.displayName;const Mc=M.forwardRef(({className:e,...t},n)=>a.jsx(be.Description,{ref:n,className:N("tw-text-sm tw-text-muted-foreground",e),...t}));Mc.displayName=be.Description.displayName;function ua({className:e,...t}){return a.jsx("div",{className:N("pr-twp tw-animate-pulse tw-rounded-md tw-bg-muted",e),...t})}const $c=Sn.Provider,Ac=Sn.Root,Dc=Sn.Trigger,Fs=g.forwardRef(({className:e,sideOffset:t=4,...n},r)=>a.jsx(Sn.Content,{ref:r,sideOffset:t,className:N("pr-twp tw-z-50 tw-overflow-hidden tw-rounded-md tw-border tw-bg-popover tw-px-3 tw-py-1.5 tw-text-sm tw-text-popover-foreground tw-shadow-md tw-animate-in tw-fade-in-0 tw-zoom-in-95 data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=closed]:tw-zoom-out-95 data-[side=bottom]:tw-slide-in-from-top-2 data-[side=left]:tw-slide-in-from-right-2 data-[side=right]:tw-slide-in-from-left-2 data-[side=top]:tw-slide-in-from-bottom-2",e),...n}));Fs.displayName=Sn.Content.displayName;const Or=768;function Bc(){const[e,t]=M.useState(void 0);return M.useEffect(()=>{const n=window.matchMedia(`(max-width: ${Or-1}px)`),r=()=>{t(window.innerWidthn.removeEventListener("change",r)},[]),!!e}const Vc="sidebar:state",zc=60*60*24*7,Lc="16rem",Fc="18rem",Gc="3rem",Uc="b",Gs=g.createContext(void 0);function cr(){const e=g.useContext(Gs);if(!e)throw new Error("useSidebar must be used within a SidebarProvider.");return e}const Us=g.forwardRef(({defaultOpen:e=!0,open:t,onOpenChange:n,className:r,style:o,children:s,...i},l)=>{const c=Bc(),[d,u]=g.useState(!1),[h,w]=g.useState(e),b=t??h,x=g.useCallback(R=>{const j=typeof R=="function"?R(b):R;n?n(j):w(j),document.cookie=`${Vc}=${j}; path=/; max-age=${zc}`},[n,b]),f=g.useCallback(()=>c?u(R=>!R):x(R=>!R),[c,x,u]);g.useEffect(()=>{const R=j=>{j.key===Uc&&(j.metaKey||j.ctrlKey)&&(j.preventDefault(),f())};return window.addEventListener("keydown",R),()=>window.removeEventListener("keydown",R)},[f]);const m=b?"expanded":"collapsed",S=g.useMemo(()=>({state:m,open:b,setOpen:x,isMobile:c,openMobile:d,setOpenMobile:u,toggleSidebar:f}),[m,b,x,c,d,u,f]);return a.jsx(Gs.Provider,{value:S,children:a.jsx($c,{delayDuration:0,children:a.jsx("div",{style:{"--sidebar-width":Lc,"--sidebar-width-icon":Gc,...o},className:N("tw-group/sidebar-wrapper pr-twp tw-flex tw-w-full has-[[data-variant=inset]]:tw-bg-sidebar",r),ref:l,...i,children:s})})})});Us.displayName="SidebarProvider";const qs=g.forwardRef(({side:e="left",variant:t="sidebar",collapsible:n="offcanvas",className:r,children:o,...s},i)=>{const{isMobile:l,state:c,openMobile:d,setOpenMobile:u}=cr();return n==="none"?a.jsx("div",{className:N("tw-flex tw-h-full tw-w-[--sidebar-width] tw-flex-col tw-bg-sidebar tw-text-sidebar-foreground",r),ref:i,...s,children:o}):l?a.jsx(Oc,{open:d,onOpenChange:u,...s,children:a.jsx(Ls,{"data-sidebar":"sidebar","data-mobile":"true",className:"tw-w-[--sidebar-width] tw-bg-sidebar tw-p-0 tw-text-sidebar-foreground [&>button]:tw-hidden",style:{"--sidebar-width":Fc},side:e,children:a.jsx("div",{className:"tw-flex tw-h-full tw-w-full tw-flex-col",children:o})})}):a.jsxs("div",{ref:i,className:"tw-group tw-peer tw-hidden tw-text-sidebar-foreground md:tw-block","data-state":c,"data-collapsible":c==="collapsed"?n:"","data-variant":t,"data-side":e,children:[a.jsx("div",{className:N("tw-relative tw-h-svh tw-w-[--sidebar-width] tw-bg-transparent tw-transition-[width] tw-duration-200 tw-ease-linear","group-data-[collapsible=offcanvas]:tw-w-0","group-data-[side=right]:tw-rotate-180",t==="floating"||t==="inset"?"group-data-[collapsible=icon]:tw-w-[calc(var(--sidebar-width-icon)_+_theme(spacing.4))]":"group-data-[collapsible=icon]:tw-w-[--sidebar-width-icon]")}),a.jsx("div",{className:N("tw-absolute tw-inset-y-0 tw-z-10 tw-hidden tw-h-svh tw-w-[--sidebar-width] tw-transition-[left,right,width] tw-duration-200 tw-ease-linear md:tw-flex",e==="left"?"tw-left-0 group-data-[collapsible=offcanvas]:tw-left-[calc(var(--sidebar-width)*-1)]":"tw-right-0 group-data-[collapsible=offcanvas]:tw-right-[calc(var(--sidebar-width)*-1)]",t==="floating"||t==="inset"?"tw-p-2 group-data-[collapsible=icon]:tw-w-[calc(var(--sidebar-width-icon)_+_theme(spacing.4)_+2px)]":"group-data-[collapsible=icon]:tw-w-[--sidebar-width-icon] group-data-[side=left]:tw-border-r group-data-[side=right]:tw-border-l",r),...s,children:a.jsx("div",{"data-sidebar":"sidebar",className:"tw-flex tw-h-full tw-w-full tw-flex-col tw-bg-sidebar group-data-[variant=floating]:tw-rounded-lg group-data-[variant=floating]:tw-border group-data-[variant=floating]:tw-border-sidebar-border group-data-[variant=floating]:tw-shadow",children:o})})]})});qs.displayName="Sidebar";const qc=g.forwardRef(({className:e,onClick:t,...n},r)=>{const{toggleSidebar:o}=cr();return a.jsxs(fe,{ref:r,"data-sidebar":"trigger",variant:"ghost",size:"icon",className:N("tw-h-7 tw-w-7",e),onClick:s=>{t==null||t(s),o()},...n,children:[a.jsx(Q.PanelLeft,{}),a.jsx("span",{className:"tw-sr-only",children:"Toggle Sidebar"})]})});qc.displayName="SidebarTrigger";const Hc=g.forwardRef(({className:e,...t},n)=>{const{toggleSidebar:r}=cr();return a.jsx("button",{type:"button",ref:n,"data-sidebar":"rail","aria-label":"Toggle Sidebar",tabIndex:-1,onClick:r,title:"Toggle Sidebar",className:N("tw-absolute tw-inset-y-0 tw-z-20 tw-hidden tw-w-4 tw--translate-x-1/2 tw-transition-all tw-ease-linear after:tw-absolute after:tw-inset-y-0 after:tw-left-1/2 after:tw-w-[2px] hover:after:tw-bg-sidebar-border group-data-[side=left]:tw--right-4 group-data-[side=right]:tw-left-0 sm:tw-flex","[[data-side=left]_&]:tw-cursor-w-resize [[data-side=right]_&]:tw-cursor-e-resize","[[data-side=left][data-state=collapsed]_&]:tw-cursor-e-resize [[data-side=right][data-state=collapsed]_&]:tw-cursor-w-resize","group-data-[collapsible=offcanvas]:tw-translate-x-0 group-data-[collapsible=offcanvas]:after:tw-left-full group-data-[collapsible=offcanvas]:hover:tw-bg-sidebar","[[data-side=left][data-collapsible=offcanvas]_&]:tw--right-2","[[data-side=right][data-collapsible=offcanvas]_&]:tw--left-2",e),...t})});Hc.displayName="SidebarRail";const Hs=g.forwardRef(({className:e,...t},n)=>a.jsx("main",{ref:n,className:N("tw-relative tw-flex tw-flex-1 tw-flex-col tw-bg-background","peer-data-[variant=inset]:tw-min-h-[calc(100svh-theme(spacing.4))] md:peer-data-[variant=inset]:tw-m-2 md:peer-data-[state=collapsed]:peer-data-[variant=inset]:tw-ml-2 md:peer-data-[variant=inset]:tw-ml-0 md:peer-data-[variant=inset]:tw-rounded-xl md:peer-data-[variant=inset]:tw-shadow",e),...t}));Hs.displayName="SidebarInset";const Xc=g.forwardRef(({className:e,...t},n)=>a.jsx(St,{ref:n,"data-sidebar":"input",className:N("tw-h-8 tw-w-full tw-bg-background tw-shadow-none focus-visible:tw-ring-2 focus-visible:tw-ring-sidebar-ring",e),...t}));Xc.displayName="SidebarInput";const Yc=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,"data-sidebar":"header",className:N("tw-flex tw-flex-col tw-gap-2 tw-p-2",e),...t}));Yc.displayName="SidebarHeader";const Wc=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,"data-sidebar":"footer",className:N("tw-flex tw-flex-col tw-gap-2 tw-p-2",e),...t}));Wc.displayName="SidebarFooter";const Kc=g.forwardRef(({className:e,...t},n)=>a.jsx(lr,{ref:n,"data-sidebar":"separator",className:N("tw-mx-2 tw-w-auto tw-bg-sidebar-border",e),...t}));Kc.displayName="SidebarSeparator";const Xs=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,"data-sidebar":"content",className:N("tw-flex tw-min-h-0 tw-flex-1 tw-flex-col tw-gap-2 tw-overflow-auto group-data-[collapsible=icon]:tw-overflow-hidden",e),...t}));Xs.displayName="SidebarContent";const Xr=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,"data-sidebar":"group",className:N("tw-relative tw-flex tw-w-full tw-min-w-0 tw-flex-col tw-p-2",e),...t}));Xr.displayName="SidebarGroup";const Yr=g.forwardRef(({className:e,asChild:t=!1,...n},r)=>{const o=t?Ht.Slot:"div";return a.jsx(o,{ref:r,"data-sidebar":"group-label",className:N("tw-flex tw-h-8 tw-shrink-0 tw-items-center tw-rounded-md tw-px-2 tw-text-xs tw-font-medium tw-text-sidebar-foreground/70 tw-outline-none tw-ring-sidebar-ring tw-transition-[margin,opa] tw-duration-200 tw-ease-linear focus-visible:tw-ring-2 [&>svg]:tw-size-4 [&>svg]:tw-shrink-0","group-data-[collapsible=icon]:tw--mt-8 group-data-[collapsible=icon]:tw-opacity-0",e),...n})});Yr.displayName="SidebarGroupLabel";const Jc=g.forwardRef(({className:e,asChild:t=!1,...n},r)=>{const o=t?Ht.Slot:"button";return a.jsx(o,{ref:r,"data-sidebar":"group-action",className:N("tw-absolute tw-right-3 tw-top-3.5 tw-flex tw-aspect-square tw-w-5 tw-items-center tw-justify-center tw-rounded-md tw-p-0 tw-text-sidebar-foreground tw-outline-none tw-ring-sidebar-ring tw-transition-transform hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground focus-visible:tw-ring-2 [&>svg]:tw-size-4 [&>svg]:tw-shrink-0","after:tw-absolute after:tw--inset-2 after:md:tw-hidden","group-data-[collapsible=icon]:tw-hidden",e),...n})});Jc.displayName="SidebarGroupAction";const Wr=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,"data-sidebar":"group-content",className:N("tw-w-full tw-text-sm",e),...t}));Wr.displayName="SidebarGroupContent";const Ys=g.forwardRef(({className:e,...t},n)=>a.jsx("ul",{ref:n,"data-sidebar":"menu",className:N("tw-flex tw-w-full tw-min-w-0 tw-flex-col tw-gap-1",e),...t}));Ys.displayName="SidebarMenu";const Ws=g.forwardRef(({className:e,...t},n)=>a.jsx("li",{ref:n,"data-sidebar":"menu-item",className:N("tw-group/menu-item tw-relative",e),...t}));Ws.displayName="SidebarMenuItem";const Zc=Xt.cva("tw-peer/menu-button tw-flex tw-w-full tw-items-center tw-gap-2 tw-overflow-hidden tw-rounded-md tw-p-2 tw-text-left tw-text-sm tw-outline-none tw-ring-sidebar-ring tw-transition-[width,height,padding] hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground focus-visible:tw-ring-2 active:tw-bg-sidebar-accent active:tw-text-sidebar-accent-foreground disabled:tw-pointer-events-none disabled:tw-opacity-50 tw-group-has-[[data-sidebar=menu-action]]/menu-item:pr-8 aria-disabled:tw-pointer-events-none aria-disabled:tw-opacity-50 data-[active=true]:tw-font-medium data-[active=true]:tw-text-sidebar-accent-foreground data-[state=open]:hover:tw-bg-sidebar-accent data-[state=open]:hover:tw-text-sidebar-accent-foreground group-data-[collapsible=icon]:tw-!size-8 group-data-[collapsible=icon]:tw-!p-2 [&>span:last-child]:tw-truncate [&>svg]:tw-size-4 [&>svg]:tw-shrink-0",{variants:{variant:{default:"hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground",outline:"tw-bg-background tw-shadow-[0_0_0_1px_hsl(var(--sidebar-border))] hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground hover:tw-shadow-[0_0_0_1px_hsl(var(--sidebar-accent))]"},size:{default:"tw-h-8 tw-text-sm",sm:"tw-h-7 tw-text-xs",lg:"tw-h-12 tw-text-sm group-data-[collapsible=icon]:tw-!p-0"}},defaultVariants:{variant:"default",size:"default"}}),Ks=g.forwardRef(({asChild:e=!1,isActive:t=!1,variant:n="default",size:r="default",tooltip:o,className:s,...i},l)=>{const c=e?Ht.Slot:"button",{isMobile:d,state:u}=cr(),h=a.jsx(c,{ref:l,"data-sidebar":"menu-button","data-size":r,"data-active":t,className:N(Zc({variant:n,size:r}),s),...i});return o?(typeof o=="string"&&(o={children:o}),a.jsxs(Ac,{children:[a.jsx(Dc,{asChild:!0,children:h}),a.jsx(Fs,{side:"right",align:"center",hidden:u!=="collapsed"||d,...o})]})):h});Ks.displayName="SidebarMenuButton";const Qc=g.forwardRef(({className:e,asChild:t=!1,showOnHover:n=!1,...r},o)=>{const s=t?Ht.Slot:"button";return a.jsx(s,{ref:o,"data-sidebar":"menu-action",className:N("tw-peer-hover/menu-button:text-sidebar-accent-foreground tw-absolute tw-right-1 tw-top-1.5 tw-flex tw-aspect-square tw-w-5 tw-items-center tw-justify-center tw-rounded-md tw-p-0 tw-text-sidebar-foreground tw-outline-none tw-ring-sidebar-ring tw-transition-transform hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground focus-visible:tw-ring-2 [&>svg]:tw-size-4 [&>svg]:tw-shrink-0","after:tw-absolute after:tw--inset-2 after:md:tw-hidden","tw-peer-data-[size=sm]/menu-button:top-1","tw-peer-data-[size=default]/menu-button:top-1.5","tw-peer-data-[size=lg]/menu-button:top-2.5","group-data-[collapsible=icon]:tw-hidden",n&&"tw-group-focus-within/menu-item:opacity-100 tw-group-hover/menu-item:opacity-100 tw-peer-data-[active=true]/menu-button:text-sidebar-accent-foreground data-[state=open]:tw-opacity-100 md:tw-opacity-0",e),...r})});Qc.displayName="SidebarMenuAction";const ed=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,"data-sidebar":"menu-badge",className:N("tw-pointer-events-none tw-absolute tw-right-1 tw-flex tw-h-5 tw-min-w-5 tw-select-none tw-items-center tw-justify-center tw-rounded-md tw-px-1 tw-text-xs tw-font-medium tw-tabular-nums tw-text-sidebar-foreground","tw-peer-hover/menu-button:text-sidebar-accent-foreground tw-peer-data-[active=true]/menu-button:text-sidebar-accent-foreground","tw-peer-data-[size=sm]/menu-button:top-1","tw-peer-data-[size=default]/menu-button:top-1.5","tw-peer-data-[size=lg]/menu-button:top-2.5","group-data-[collapsible=icon]:tw-hidden",e),...t}));ed.displayName="SidebarMenuBadge";const td=g.forwardRef(({className:e,showIcon:t=!1,...n},r)=>{const o=g.useMemo(()=>`${Math.floor(Math.random()*40)+50}%`,[]);return a.jsxs("div",{ref:r,"data-sidebar":"menu-skeleton",className:N("tw-flex tw-h-8 tw-items-center tw-gap-2 tw-rounded-md tw-px-2",e),...n,children:[t&&a.jsx(ua,{className:"tw-size-4 tw-rounded-md","data-sidebar":"menu-skeleton-icon"}),a.jsx(ua,{className:"tw-h-4 tw-max-w-[--skeleton-width] tw-flex-1","data-sidebar":"menu-skeleton-text",style:{"--skeleton-width":o}})]})});td.displayName="SidebarMenuSkeleton";const nd=g.forwardRef(({className:e,...t},n)=>a.jsx("ul",{ref:n,"data-sidebar":"menu-sub",className:N("tw-mx-3.5 tw-flex tw-min-w-0 tw-translate-x-px tw-flex-col tw-gap-1 tw-border-l tw-border-sidebar-border tw-px-2.5 tw-py-0.5","group-data-[collapsible=icon]:tw-hidden",e),...t}));nd.displayName="SidebarMenuSub";const rd=g.forwardRef(({...e},t)=>a.jsx("li",{ref:t,...e}));rd.displayName="SidebarMenuSubItem";const od=g.forwardRef(({asChild:e=!1,size:t="md",isActive:n,className:r,...o},s)=>{const i=e?Ht.Slot:"a";return a.jsx(i,{ref:s,"data-sidebar":"menu-sub-button","data-size":t,"data-active":n,className:N("tw-flex tw-h-7 tw-min-w-0 tw--translate-x-px tw-items-center tw-gap-2 tw-overflow-hidden tw-rounded-md tw-px-2 tw-text-sidebar-foreground tw-outline-none tw-ring-sidebar-ring hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground focus-visible:tw-ring-2 active:tw-bg-sidebar-accent active:tw-text-sidebar-accent-foreground disabled:tw-pointer-events-none disabled:tw-opacity-50 aria-disabled:tw-pointer-events-none aria-disabled:tw-opacity-50 [&>span:last-child]:tw-truncate [&>svg]:tw-size-4 [&>svg]:tw-shrink-0 [&>svg]:tw-text-sidebar-accent-foreground","data-[active=true]:tw-bg-sidebar-accent data-[active=true]:tw-text-sidebar-accent-foreground",t==="sm"&&"tw-text-xs",t==="md"&&"tw-text-sm","group-data-[collapsible=icon]:tw-hidden",r),...o})});od.displayName="SidebarMenuSubButton";function Js({id:e,extensionLabels:t,projectOptions:n,handleSelectSidebarItem:r,selectedSidebarItem:o}){const s=g.useCallback((c,d)=>{r(c,d)},[r]),i=g.useCallback(c=>{const d=n.find(u=>u.projectId===c);return d?d.projectName:c},[n]),l=g.useCallback(c=>!o.projectId&&c===o.label,[o]);return a.jsx(qs,{id:e,collapsible:"none",variant:"inset",className:"tw-w-96 tw-gap-2 tw-overflow-y-auto tw-rounded tw-bg-slate-100",children:a.jsxs(Xs,{children:[a.jsxs(Xr,{children:[a.jsx(Yr,{className:"tw-text-sm tw-text-gray-400",children:"Extensions"}),a.jsx(Wr,{children:a.jsx(Ys,{children:t.map(c=>a.jsx(Ws,{children:a.jsx(Ks,{className:N("tw-rounded tw-py-2 tw-text-sm tw-text-gray-500 hover:tw-bg-white hover:tw-text-gray-900 hover:tw-shadow-sm active:tw-bg-white",{"tw-bg-white tw-text-gray-900 tw-shadow-sm":l(c)}),onClick:()=>s(c,void 0),isActive:l(c),children:a.jsx("span",{className:"tw-pl-3",children:c})})},c))})})]}),a.jsxs(Xr,{children:[a.jsx(Yr,{className:"tw-text-sm tw-text-gray-400",children:"Projects"}),a.jsx(Wr,{className:"tw-pl-3",children:a.jsx(Wn,{popoverContentClassName:"tw-z-[1000]",options:n.flatMap(c=>c.projectId),getOptionLabel:c=>i(c),buttonPlaceholder:"Type or select project",onChange:c=>{const d=i(c);s(d,c)},value:(o==null?void 0:o.projectId)??void 0})})]})]})})}function ad({id:e,direction:t="ltr",extensionLabels:n,projectOptions:r,children:o,handleSelectSidebarItem:s,selectedSidebarItem:i,onSearch:l}){return a.jsxs("div",{className:"tw-h-full tw-p-3",children:[a.jsx("div",{className:"tw-flex tw-items-center tw-justify-center tw-py-4",children:a.jsx(ho,{className:"tw-w-9/12",onSearch:l,placeholder:"Search app settings, extension settings, and project settings"})}),a.jsxs(Us,{dir:t,id:e,className:"tw-gap-4",children:[a.jsx(Js,{extensionLabels:n,projectOptions:r,handleSelectSidebarItem:s,selectedSidebarItem:i}),a.jsx(Hs,{className:"tw-overflow-y-auto",children:o})]})]})}const rt="scrBook",sd="scrRef",pt="source",id="details",ld="Scripture Reference",cd="Scripture Book",Zs="Type",dd="Details";function ud(e,t){const n=t??!1;return[{accessorFn:r=>`${ae.bookNumberToId(r.start.bookNum)} ${r.start.chapterNum}:${r.start.verseNum}`,id:rt,header:(e==null?void 0:e.scriptureReferenceColumnName)??ld,cell:r=>{const o=r.row.original;return r.row.getIsGrouped()?ae.bookNumberToEnglishName(o.start.bookNum):r.row.groupingColumnId===rt?W.formatScrRef(o.start):void 0},getGroupingValue:r=>r.start.bookNum,sortingFn:(r,o)=>W.compareScrRefs(r.original.start,o.original.start),enableGrouping:!0},{accessorFn:r=>W.formatScrRef(r.start),id:sd,header:void 0,cell:r=>{const o=r.row.original;return r.row.getIsGrouped()?void 0:W.formatScrRef(o.start)},sortingFn:(r,o)=>W.compareScrRefs(r.original.start,o.original.start),enableGrouping:!1},{accessorFn:r=>r.source.displayName,id:pt,header:n?(e==null?void 0:e.typeColumnName)??Zs:void 0,cell:r=>n||r.row.getIsGrouped()?r.getValue():void 0,getGroupingValue:r=>r.source.id,sortingFn:(r,o)=>r.original.source.displayName.localeCompare(o.original.source.displayName),enableGrouping:!0},{accessorFn:r=>r.detail,id,header:(e==null?void 0:e.detailsColumnName)??dd,cell:r=>r.getValue(),enableGrouping:!1}]}const pd=e=>{if(!("offset"in e.start))throw new Error("No offset available in range start");if(e.end&&!("offset"in e.end))throw new Error("No offset available in range end");const{offset:t}=e.start;let n=0;return e.end&&({offset:n}=e.end),!e.end||W.compareScrRefs(e.start,e.end)===0?`${W.scrRefToBBBCCCVVV(e.start)}+${t}`:`${W.scrRefToBBBCCCVVV(e.start)}+${t}-${W.scrRefToBBBCCCVVV(e.end)}+${n}`},pa=e=>`${pd({start:e.start,end:e.end})} ${e.source.displayName} ${e.detail}`;function wd({sources:e,showColumnHeaders:t=!1,showSourceColumn:n=!1,scriptureReferenceColumnName:r,scriptureBookGroupName:o,typeColumnName:s,detailsColumnName:i,onRowSelected:l,direction:c="ltr"}){const[d,u]=g.useState([]),[h,w]=g.useState([{id:rt,desc:!1}]),[b,x]=g.useState({}),f=g.useMemo(()=>e.flatMap(C=>C.data.map(_=>({..._,source:C.source}))),[e]),m=g.useMemo(()=>ud({scriptureReferenceColumnName:r,typeColumnName:s,detailsColumnName:i},n),[r,s,i,n]);g.useEffect(()=>{d.includes(pt)?w([{id:pt,desc:!1},{id:rt,desc:!1}]):w([{id:rt,desc:!1}])},[d]);const S=Se.useReactTable({data:f,columns:m,state:{grouping:d,sorting:h,rowSelection:b},onGroupingChange:u,onSortingChange:w,onRowSelectionChange:x,getExpandedRowModel:Se.getExpandedRowModel(),getGroupedRowModel:Se.getGroupedRowModel(),getCoreRowModel:Se.getCoreRowModel(),getSortedRowModel:Se.getSortedRowModel(),getRowId:pa,autoResetExpanded:!1,enableMultiRowSelection:!1,enableSubRowSelection:!1});g.useEffect(()=>{if(l){const C=S.getSelectedRowModel().rowsById,_=Object.keys(C);if(_.length===1){const k=f.find(A=>pa(A)===_[0])||void 0;k&&l(k)}}},[b,f,l,S]);const R=o??cd,j=s??Zs,E=[{label:"No Grouping",value:[]},{label:`Group by ${R}`,value:[rt]},{label:`Group by ${j}`,value:[pt]},{label:`Group by ${R} and ${j}`,value:[rt,pt]},{label:`Group by ${j} and ${R}`,value:[pt,rt]}],v=C=>{u(JSON.parse(C))},P=(C,_)=>{!C.getIsGrouped()&&!C.getIsSelected()&&C.getToggleSelectedHandler()(_)},V=(C,_)=>C.getIsGrouped()?"":N("banded-row",_%2===0?"even":"odd"),U=(C,_,k)=>{if(!((C==null?void 0:C.length)===0||_.depth{v(C)},children:[a.jsx(bt,{className:"tw-mb-1 tw-mt-2",children:a.jsx(Bt,{})}),a.jsx(vt,{position:"item-aligned",children:a.jsx(Ts,{children:E.map(C=>a.jsx(De,{value:JSON.stringify(C.value),children:C.label},C.label))})})]}),a.jsxs(Cn,{className:"tw-relative tw-flex tw-flex-col tw-overflow-y-auto tw-p-0",children:[t&&a.jsx(Tn,{children:S.getHeaderGroups().map(C=>a.jsx(Ze,{children:C.headers.filter(_=>_.column.columnDef.header).map(_=>a.jsx(Vt,{colSpan:_.colSpan,className:"top-0 tw-sticky",children:_.isPlaceholder?void 0:a.jsxs("div",{children:[_.column.getCanGroup()?a.jsx(fe,{variant:"ghost",title:`Toggle grouping by ${_.column.columnDef.header}`,onClick:_.column.getToggleGroupingHandler(),type:"button",children:_.column.getIsGrouped()?"🛑":"👊 "}):void 0," ",Se.flexRender(_.column.columnDef.header,_.getContext())]})},_.id))},C.id))}),a.jsx(Rn,{children:S.getRowModel().rows.map((C,_)=>a.jsx(Ze,{"data-state":C.getIsSelected()?"selected":"",className:N(V(C,_)),onClick:k=>P(C,k),children:C.getVisibleCells().map(k=>{if(!(k.getIsPlaceholder()||k.column.columnDef.enableGrouping&&!k.getIsGrouped()&&(k.column.columnDef.id!==pt||!n)))return a.jsx(xt,{className:N(k.column.columnDef.id,"tw-p-[1px]",U(d,C,k)),children:(()=>k.getIsGrouped()?a.jsxs(fe,{variant:"link",onClick:C.getToggleExpandedHandler(),type:"button",children:[C.getIsExpanded()&&a.jsx(Q.ChevronDown,{}),!C.getIsExpanded()&&(c==="ltr"?a.jsx(Q.ChevronRight,{}):a.jsx(Q.ChevronLeft,{}))," ",Se.flexRender(k.column.columnDef.cell,k.getContext())," (",C.subRows.length,")"]}):Se.flexRender(k.column.columnDef.cell,k.getContext()))()},k.id)})},C.id))})]})]})}const _r={[W.getLocalizeKeyForScrollGroupId("undefined")]:"Ø",[W.getLocalizeKeyForScrollGroupId(0)]:"A",[W.getLocalizeKeyForScrollGroupId(1)]:"B",[W.getLocalizeKeyForScrollGroupId(2)]:"C",[W.getLocalizeKeyForScrollGroupId(3)]:"D",[W.getLocalizeKeyForScrollGroupId(4)]:"E",[W.getLocalizeKeyForScrollGroupId(5)]:"F",[W.getLocalizeKeyForScrollGroupId(6)]:"G",[W.getLocalizeKeyForScrollGroupId(7)]:"H",[W.getLocalizeKeyForScrollGroupId(8)]:"I",[W.getLocalizeKeyForScrollGroupId(9)]:"J",[W.getLocalizeKeyForScrollGroupId(10)]:"K",[W.getLocalizeKeyForScrollGroupId(11)]:"L",[W.getLocalizeKeyForScrollGroupId(12)]:"M",[W.getLocalizeKeyForScrollGroupId(13)]:"N",[W.getLocalizeKeyForScrollGroupId(14)]:"O",[W.getLocalizeKeyForScrollGroupId(15)]:"P",[W.getLocalizeKeyForScrollGroupId(16)]:"Q",[W.getLocalizeKeyForScrollGroupId(17)]:"R",[W.getLocalizeKeyForScrollGroupId(18)]:"S",[W.getLocalizeKeyForScrollGroupId(19)]:"T",[W.getLocalizeKeyForScrollGroupId(20)]:"U",[W.getLocalizeKeyForScrollGroupId(21)]:"V",[W.getLocalizeKeyForScrollGroupId(22)]:"W",[W.getLocalizeKeyForScrollGroupId(23)]:"X",[W.getLocalizeKeyForScrollGroupId(24)]:"Y",[W.getLocalizeKeyForScrollGroupId(25)]:"Z"};function fd({availableScrollGroupIds:e,scrollGroupId:t,onChangeScrollGroupId:n,localizedStrings:r={}}){const o={..._r,...Object.fromEntries(Object.entries(r).map(([s,i])=>[s,s===i&&s in _r?_r[s]:i]))};return a.jsxs(Dt,{value:`${t}`,onValueChange:s=>n(s==="undefined"?void 0:parseInt(s,10)),children:[a.jsx(bt,{className:"pr-twp tw-w-auto",children:a.jsx(Bt,{placeholder:o[W.getLocalizeKeyForScrollGroupId(t)]??t})}),a.jsx(vt,{style:{zIndex:250},children:e.map(s=>a.jsx(De,{value:`${s}`,children:o[W.getLocalizeKeyForScrollGroupId(s)]},`${s}`))})]})}function md({children:e}){return a.jsx("div",{className:"pr-twp tw-grid",children:e})}function hd({primary:e,secondary:t,children:n,isLoading:r=!1,loadingMessage:o}){return a.jsxs("div",{className:"tw-flex tw-items-center tw-justify-between tw-space-x-4 tw-py-2",children:[a.jsxs("div",{children:[a.jsx("p",{className:"tw-text-sm tw-font-medium tw-leading-none",children:e}),a.jsx("p",{className:"tw-whitespace-normal tw-break-words tw-text-sm tw-text-muted-foreground",children:t})]}),r?a.jsx("p",{className:"tw-text-sm tw-text-muted-foreground",children:o}):a.jsx("div",{children:n})]})}function gd({primary:e,secondary:t,includeSeparator:n=!1}){return a.jsxs("div",{className:"tw-space-y-4 tw-py-2",children:[a.jsxs("div",{children:[a.jsx("h3",{className:"tw-text-lg tw-font-medium",children:e}),a.jsx("p",{className:"tw-text-sm tw-text-muted-foreground",children:t})]}),n?a.jsx(lr,{}):""]})}const xo=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,className:N("pr-twp tw-rounded-lg tw-border tw-bg-card tw-text-card-foreground tw-shadow-sm",e),...t}));xo.displayName="Card";const yo=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,className:N("pr-twp tw-flex tw-flex-col tw-space-y-1.5 tw-p-6",e),...t}));yo.displayName="CardHeader";const No=g.forwardRef(({className:e,...t},n)=>a.jsx("h3",{ref:n,className:N("pr-twp tw-text-2xl tw-font-semibold tw-leading-none tw-tracking-tight",e),...t,children:t.children}));No.displayName="CardTitle";const ko=g.forwardRef(({className:e,...t},n)=>a.jsx("p",{ref:n,className:N("pr-twp tw-text-sm tw-text-muted-foreground",e),...t}));ko.displayName="CardDescription";const So=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,className:N("pr-twp tw-p-6 tw-pt-0",e),...t}));So.displayName="CardContent";const Qs=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,className:N("pr-twp tw-flex tw-items-center tw-p-6 tw-pt-0",e),...t}));Qs.displayName="CardFooter";function bd({id:e,settingsGroupLabel:t,settingsGroupDescription:n,children:r}){return a.jsxs(xo,{id:e,children:[a.jsxs(yo,{children:[a.jsx(No,{children:t}),n&&a.jsx(ko,{children:n})]}),a.jsx(So,{children:r})]})}function vd({id:e,className:t,listItems:n,selectedListItems:r,handleSelectListItem:o,createLabel:s}){return a.jsx("div",{id:e,className:t,children:n.map(i=>a.jsxs("div",{className:"tw-m-2 tw-flex tw-items-center",children:[a.jsx(sr,{className:"tw-mr-2 tw-align-middle",checked:r.includes(i),onCheckedChange:l=>o(i,l)}),a.jsx(qe,{children:s?s(i):i})]},i))})}function xd(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}function yd(e){if(e.__esModule)return e;var t=e.default;if(typeof t=="function"){var n=function r(){return this instanceof r?Reflect.construct(t,arguments,this.constructor):t.apply(this,arguments)};n.prototype=t.prototype}else n={};return Object.defineProperty(n,"__esModule",{value:!0}),Object.keys(e).forEach(function(r){var o=Object.getOwnPropertyDescriptor(e,r);Object.defineProperty(n,r,o.get?o:{enumerable:!0,get:function(){return e[r]}})}),n}var Eo={},ei={exports:{}};(function(e){function t(n){return n&&n.__esModule?n:{default:n}}e.exports=t,e.exports.__esModule=!0,e.exports.default=e.exports})(ei);var Nd=ei.exports,Pr={};function jo(e,t){return process.env.NODE_ENV==="production"?()=>null:function(...r){return e(...r)||t(...r)}}function O(){return O=Object.assign?Object.assign.bind():function(e){for(var t=1;t{t[n]=ti(e[n])}),t}function Qe(e,t,n={clone:!0}){const r=n.clone?O({},e):e;return mt(e)&&mt(t)&&Object.keys(t).forEach(o=>{o!=="__proto__"&&(mt(t[o])&&o in e&&mt(e[o])?r[o]=Qe(e[o],t[o],n):n.clone?r[o]=mt(t[o])?ti(t[o]):t[o]:r[o]=t[o])}),r}var Kr={exports:{}},zn={exports:{}},ie={};/** @license React v16.13.1 * react-is.production.min.js * * Copyright (c) Facebook, Inc. and its affiliates. * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. - */var ua;function kd(){if(ua)return ie;ua=1;var e=typeof Symbol=="function"&&Symbol.for,t=e?Symbol.for("react.element"):60103,n=e?Symbol.for("react.portal"):60106,r=e?Symbol.for("react.fragment"):60107,o=e?Symbol.for("react.strict_mode"):60108,s=e?Symbol.for("react.profiler"):60114,i=e?Symbol.for("react.provider"):60109,l=e?Symbol.for("react.context"):60110,c=e?Symbol.for("react.async_mode"):60111,d=e?Symbol.for("react.concurrent_mode"):60111,u=e?Symbol.for("react.forward_ref"):60112,h=e?Symbol.for("react.suspense"):60113,w=e?Symbol.for("react.suspense_list"):60120,b=e?Symbol.for("react.memo"):60115,x=e?Symbol.for("react.lazy"):60116,f=e?Symbol.for("react.block"):60121,m=e?Symbol.for("react.fundamental"):60117,S=e?Symbol.for("react.responder"):60118,R=e?Symbol.for("react.scope"):60119;function j(v){if(typeof v=="object"&&v!==null){var P=v.$$typeof;switch(P){case t:switch(v=v.type,v){case c:case d:case r:case s:case o:case h:return v;default:switch(v=v&&v.$$typeof,v){case l:case u:case x:case b:case i:return v;default:return P}}case n:return P}}}function E(v){return j(v)===d}return ie.AsyncMode=c,ie.ConcurrentMode=d,ie.ContextConsumer=l,ie.ContextProvider=i,ie.Element=t,ie.ForwardRef=u,ie.Fragment=r,ie.Lazy=x,ie.Memo=b,ie.Portal=n,ie.Profiler=s,ie.StrictMode=o,ie.Suspense=h,ie.isAsyncMode=function(v){return E(v)||j(v)===c},ie.isConcurrentMode=E,ie.isContextConsumer=function(v){return j(v)===l},ie.isContextProvider=function(v){return j(v)===i},ie.isElement=function(v){return typeof v=="object"&&v!==null&&v.$$typeof===t},ie.isForwardRef=function(v){return j(v)===u},ie.isFragment=function(v){return j(v)===r},ie.isLazy=function(v){return j(v)===x},ie.isMemo=function(v){return j(v)===b},ie.isPortal=function(v){return j(v)===n},ie.isProfiler=function(v){return j(v)===s},ie.isStrictMode=function(v){return j(v)===o},ie.isSuspense=function(v){return j(v)===h},ie.isValidElementType=function(v){return typeof v=="string"||typeof v=="function"||v===r||v===d||v===s||v===o||v===h||v===w||typeof v=="object"&&v!==null&&(v.$$typeof===x||v.$$typeof===b||v.$$typeof===i||v.$$typeof===l||v.$$typeof===u||v.$$typeof===m||v.$$typeof===S||v.$$typeof===R||v.$$typeof===f)},ie.typeOf=j,ie}var le={};/** @license React v16.13.1 + */var wa;function kd(){if(wa)return ie;wa=1;var e=typeof Symbol=="function"&&Symbol.for,t=e?Symbol.for("react.element"):60103,n=e?Symbol.for("react.portal"):60106,r=e?Symbol.for("react.fragment"):60107,o=e?Symbol.for("react.strict_mode"):60108,s=e?Symbol.for("react.profiler"):60114,i=e?Symbol.for("react.provider"):60109,l=e?Symbol.for("react.context"):60110,c=e?Symbol.for("react.async_mode"):60111,d=e?Symbol.for("react.concurrent_mode"):60111,u=e?Symbol.for("react.forward_ref"):60112,h=e?Symbol.for("react.suspense"):60113,w=e?Symbol.for("react.suspense_list"):60120,b=e?Symbol.for("react.memo"):60115,x=e?Symbol.for("react.lazy"):60116,f=e?Symbol.for("react.block"):60121,m=e?Symbol.for("react.fundamental"):60117,S=e?Symbol.for("react.responder"):60118,R=e?Symbol.for("react.scope"):60119;function j(v){if(typeof v=="object"&&v!==null){var P=v.$$typeof;switch(P){case t:switch(v=v.type,v){case c:case d:case r:case s:case o:case h:return v;default:switch(v=v&&v.$$typeof,v){case l:case u:case x:case b:case i:return v;default:return P}}case n:return P}}}function E(v){return j(v)===d}return ie.AsyncMode=c,ie.ConcurrentMode=d,ie.ContextConsumer=l,ie.ContextProvider=i,ie.Element=t,ie.ForwardRef=u,ie.Fragment=r,ie.Lazy=x,ie.Memo=b,ie.Portal=n,ie.Profiler=s,ie.StrictMode=o,ie.Suspense=h,ie.isAsyncMode=function(v){return E(v)||j(v)===c},ie.isConcurrentMode=E,ie.isContextConsumer=function(v){return j(v)===l},ie.isContextProvider=function(v){return j(v)===i},ie.isElement=function(v){return typeof v=="object"&&v!==null&&v.$$typeof===t},ie.isForwardRef=function(v){return j(v)===u},ie.isFragment=function(v){return j(v)===r},ie.isLazy=function(v){return j(v)===x},ie.isMemo=function(v){return j(v)===b},ie.isPortal=function(v){return j(v)===n},ie.isProfiler=function(v){return j(v)===s},ie.isStrictMode=function(v){return j(v)===o},ie.isSuspense=function(v){return j(v)===h},ie.isValidElementType=function(v){return typeof v=="string"||typeof v=="function"||v===r||v===d||v===s||v===o||v===h||v===w||typeof v=="object"&&v!==null&&(v.$$typeof===x||v.$$typeof===b||v.$$typeof===i||v.$$typeof===l||v.$$typeof===u||v.$$typeof===m||v.$$typeof===S||v.$$typeof===R||v.$$typeof===f)},ie.typeOf=j,ie}var le={};/** @license React v16.13.1 * react-is.development.js * * Copyright (c) Facebook, Inc. and its affiliates. * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. - */var pa;function Sd(){return pa||(pa=1,process.env.NODE_ENV!=="production"&&function(){var e=typeof Symbol=="function"&&Symbol.for,t=e?Symbol.for("react.element"):60103,n=e?Symbol.for("react.portal"):60106,r=e?Symbol.for("react.fragment"):60107,o=e?Symbol.for("react.strict_mode"):60108,s=e?Symbol.for("react.profiler"):60114,i=e?Symbol.for("react.provider"):60109,l=e?Symbol.for("react.context"):60110,c=e?Symbol.for("react.async_mode"):60111,d=e?Symbol.for("react.concurrent_mode"):60111,u=e?Symbol.for("react.forward_ref"):60112,h=e?Symbol.for("react.suspense"):60113,w=e?Symbol.for("react.suspense_list"):60120,b=e?Symbol.for("react.memo"):60115,x=e?Symbol.for("react.lazy"):60116,f=e?Symbol.for("react.block"):60121,m=e?Symbol.for("react.fundamental"):60117,S=e?Symbol.for("react.responder"):60118,R=e?Symbol.for("react.scope"):60119;function j(I){return typeof I=="string"||typeof I=="function"||I===r||I===d||I===s||I===o||I===h||I===w||typeof I=="object"&&I!==null&&(I.$$typeof===x||I.$$typeof===b||I.$$typeof===i||I.$$typeof===l||I.$$typeof===u||I.$$typeof===m||I.$$typeof===S||I.$$typeof===R||I.$$typeof===f)}function E(I){if(typeof I=="object"&&I!==null){var ye=I.$$typeof;switch(ye){case t:var A=I.type;switch(A){case c:case d:case r:case s:case o:case h:return A;default:var xe=A&&A.$$typeof;switch(xe){case l:case u:case x:case b:case i:return xe;default:return ye}}case n:return ye}}}var v=c,P=d,V=l,U=i,C=t,_=u,k=r,D=x,$=b,J=n,Y=s,F=o,te=h,se=!1;function oe(I){return se||(se=!0,console.warn("The ReactIs.isAsyncMode() alias has been deprecated, and will be removed in React 17+. Update your code to use ReactIs.isConcurrentMode() instead. It has the exact same API.")),y(I)||E(I)===c}function y(I){return E(I)===d}function T(I){return E(I)===l}function z(I){return E(I)===i}function L(I){return typeof I=="object"&&I!==null&&I.$$typeof===t}function B(I){return E(I)===u}function X(I){return E(I)===r}function q(I){return E(I)===x}function H(I){return E(I)===b}function G(I){return E(I)===n}function K(I){return E(I)===s}function Z(I){return E(I)===o}function ue(I){return E(I)===h}le.AsyncMode=v,le.ConcurrentMode=P,le.ContextConsumer=V,le.ContextProvider=U,le.Element=C,le.ForwardRef=_,le.Fragment=k,le.Lazy=D,le.Memo=$,le.Portal=J,le.Profiler=Y,le.StrictMode=F,le.Suspense=te,le.isAsyncMode=oe,le.isConcurrentMode=y,le.isContextConsumer=T,le.isContextProvider=z,le.isElement=L,le.isForwardRef=B,le.isFragment=X,le.isLazy=q,le.isMemo=H,le.isPortal=G,le.isProfiler=K,le.isStrictMode=Z,le.isSuspense=ue,le.isValidElementType=j,le.typeOf=E}()),le}var wa;function ni(){return wa||(wa=1,process.env.NODE_ENV==="production"?zn.exports=kd():zn.exports=Sd()),zn.exports}/* + */var fa;function Sd(){return fa||(fa=1,process.env.NODE_ENV!=="production"&&function(){var e=typeof Symbol=="function"&&Symbol.for,t=e?Symbol.for("react.element"):60103,n=e?Symbol.for("react.portal"):60106,r=e?Symbol.for("react.fragment"):60107,o=e?Symbol.for("react.strict_mode"):60108,s=e?Symbol.for("react.profiler"):60114,i=e?Symbol.for("react.provider"):60109,l=e?Symbol.for("react.context"):60110,c=e?Symbol.for("react.async_mode"):60111,d=e?Symbol.for("react.concurrent_mode"):60111,u=e?Symbol.for("react.forward_ref"):60112,h=e?Symbol.for("react.suspense"):60113,w=e?Symbol.for("react.suspense_list"):60120,b=e?Symbol.for("react.memo"):60115,x=e?Symbol.for("react.lazy"):60116,f=e?Symbol.for("react.block"):60121,m=e?Symbol.for("react.fundamental"):60117,S=e?Symbol.for("react.responder"):60118,R=e?Symbol.for("react.scope"):60119;function j(I){return typeof I=="string"||typeof I=="function"||I===r||I===d||I===s||I===o||I===h||I===w||typeof I=="object"&&I!==null&&(I.$$typeof===x||I.$$typeof===b||I.$$typeof===i||I.$$typeof===l||I.$$typeof===u||I.$$typeof===m||I.$$typeof===S||I.$$typeof===R||I.$$typeof===f)}function E(I){if(typeof I=="object"&&I!==null){var ye=I.$$typeof;switch(ye){case t:var D=I.type;switch(D){case c:case d:case r:case s:case o:case h:return D;default:var xe=D&&D.$$typeof;switch(xe){case l:case u:case x:case b:case i:return xe;default:return ye}}case n:return ye}}}var v=c,P=d,V=l,U=i,C=t,_=u,k=r,A=x,$=b,J=n,Y=s,F=o,te=h,se=!1;function oe(I){return se||(se=!0,console.warn("The ReactIs.isAsyncMode() alias has been deprecated, and will be removed in React 17+. Update your code to use ReactIs.isConcurrentMode() instead. It has the exact same API.")),y(I)||E(I)===c}function y(I){return E(I)===d}function T(I){return E(I)===l}function z(I){return E(I)===i}function L(I){return typeof I=="object"&&I!==null&&I.$$typeof===t}function B(I){return E(I)===u}function X(I){return E(I)===r}function q(I){return E(I)===x}function H(I){return E(I)===b}function G(I){return E(I)===n}function K(I){return E(I)===s}function Z(I){return E(I)===o}function ue(I){return E(I)===h}le.AsyncMode=v,le.ConcurrentMode=P,le.ContextConsumer=V,le.ContextProvider=U,le.Element=C,le.ForwardRef=_,le.Fragment=k,le.Lazy=A,le.Memo=$,le.Portal=J,le.Profiler=Y,le.StrictMode=F,le.Suspense=te,le.isAsyncMode=oe,le.isConcurrentMode=y,le.isContextConsumer=T,le.isContextProvider=z,le.isElement=L,le.isForwardRef=B,le.isFragment=X,le.isLazy=q,le.isMemo=H,le.isPortal=G,le.isProfiler=K,le.isStrictMode=Z,le.isSuspense=ue,le.isValidElementType=j,le.typeOf=E}()),le}var ma;function ni(){return ma||(ma=1,process.env.NODE_ENV==="production"?zn.exports=kd():zn.exports=Sd()),zn.exports}/* object-assign (c) Sindre Sorhus @license MIT -*/var Ir,fa;function Ed(){if(fa)return Ir;fa=1;var e=Object.getOwnPropertySymbols,t=Object.prototype.hasOwnProperty,n=Object.prototype.propertyIsEnumerable;function r(s){if(s==null)throw new TypeError("Object.assign cannot be called with null or undefined");return Object(s)}function o(){try{if(!Object.assign)return!1;var s=new String("abc");if(s[5]="de",Object.getOwnPropertyNames(s)[0]==="5")return!1;for(var i={},l=0;l<10;l++)i["_"+String.fromCharCode(l)]=l;var c=Object.getOwnPropertyNames(i).map(function(u){return i[u]});if(c.join("")!=="0123456789")return!1;var d={};return"abcdefghijklmnopqrst".split("").forEach(function(u){d[u]=u}),Object.keys(Object.assign({},d)).join("")==="abcdefghijklmnopqrst"}catch{return!1}}return Ir=o()?Object.assign:function(s,i){for(var l,c=r(s),d,u=1;u1?s("Invalid arguments supplied to oneOf, expected an array, got "+arguments.length+" arguments. A common mistake is to write oneOf(x, y, z) instead of oneOf([x, y, z])."):s("Invalid argument supplied to oneOf, expected an array.")),i;function T(z,L,B,X,q){for(var H=z[L],G=0;G0?", expected one of type ["+K.join(", ")+"]":"";return new f("Invalid "+H+" `"+G+"` supplied to "+("`"+q+"`"+ye+"."))}return m(L)}function _(){function y(T,z,L,B,X){return J(T[z])?null:new f("Invalid "+B+" `"+X+"` supplied to "+("`"+L+"`, expected a ReactNode."))}return m(y)}function k(y,T,z,L,B){return new f((y||"React class")+": "+T+" type `"+z+"."+L+"` is invalid; it must be a function, usually from the `prop-types` package, but received `"+B+"`.")}function D(y){function T(z,L,B,X,q){var H=z[L],G=F(H);if(G!=="object")return new f("Invalid "+X+" `"+q+"` of type `"+G+"` "+("supplied to `"+B+"`, expected `object`."));for(var K in y){var Z=y[K];if(typeof Z!="function")return k(B,X,q,K,te(Z));var ue=Z(H,K,B,X,q+"."+K,n);if(ue)return ue}return null}return m(T)}function $(y){function T(z,L,B,X,q){var H=z[L],G=F(H);if(G!=="object")return new f("Invalid "+X+" `"+q+"` of type `"+G+"` "+("supplied to `"+B+"`, expected `object`."));var K=t({},z[L],y);for(var Z in K){var ue=y[Z];if(r(y,Z)&&typeof ue!="function")return k(B,X,q,Z,te(ue));if(!ue)return new f("Invalid "+X+" `"+q+"` key `"+Z+"` supplied to `"+B+"`.\nBad object: "+JSON.stringify(z[L],null," ")+` -Valid keys: `+JSON.stringify(Object.keys(y),null," "));var I=ue(H,Z,B,X,q+"."+Z,n);if(I)return I}return null}return m(T)}function J(y){switch(typeof y){case"number":case"string":case"undefined":return!0;case"boolean":return!y;case"object":if(Array.isArray(y))return y.every(J);if(y===null||l(y))return!0;var T=h(y);if(T){var z=T.call(y),L;if(T!==y.entries){for(;!(L=z.next()).done;)if(!J(L.value))return!1}else for(;!(L=z.next()).done;){var B=L.value;if(B&&!J(B[1]))return!1}}else return!1;return!0;default:return!1}}function Y(y,T){return y==="symbol"?!0:T?T["@@toStringTag"]==="Symbol"||typeof Symbol=="function"&&T instanceof Symbol:!1}function F(y){var T=typeof y;return Array.isArray(y)?"array":y instanceof RegExp?"object":Y(T,y)?"symbol":T}function te(y){if(typeof y>"u"||y===null)return""+y;var T=F(y);if(T==="object"){if(y instanceof Date)return"date";if(y instanceof RegExp)return"regexp"}return T}function se(y){var T=te(y);switch(T){case"array":case"object":return"an "+T;case"boolean":case"date":case"regexp":return"a "+T;default:return T}}function oe(y){return!y.constructor||!y.constructor.name?w:y.constructor.name}return b.checkPropTypes=o,b.resetWarningCache=o.resetWarningCache,b.PropTypes=b,b},Ar}var Br,va;function Td(){if(va)return Br;va=1;var e=Eo();function t(){}function n(){}return n.resetWarningCache=t,Br=function(){function r(i,l,c,d,u,h){if(h!==e){var w=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types");throw w.name="Invariant Violation",w}}r.isRequired=r;function o(){return r}var s={array:r,bigint:r,bool:r,func:r,number:r,object:r,string:r,symbol:r,any:r,arrayOf:o,element:r,elementType:r,instanceOf:o,node:r,objectOf:o,oneOf:o,oneOfType:o,shape:o,exact:o,checkPropTypes:n,resetWarningCache:t};return s.PropTypes=s,s},Br}if(process.env.NODE_ENV!=="production"){var Rd=ni(),Od=!0;Kr.exports=Cd()(Rd.isElement,Od)}else Kr.exports=Td()();var _d=Kr.exports;const p=xd(_d);function Pd(e){const{prototype:t={}}=e;return!!t.isReactComponent}function oi(e,t,n,r,o){const s=e[t],i=o||t;if(s==null||typeof window>"u")return null;let l;const c=s.type;return typeof c=="function"&&!Pd(c)&&(l="Did you accidentally use a plain function component for an element instead?"),l!==void 0?new Error(`Invalid ${r} \`${i}\` supplied to \`${n}\`. Expected an element that can hold a ref. ${l} For more information see https://mui.com/r/caveat-with-refs-guide`):null}const ai=So(p.element,oi);ai.isRequired=So(p.element.isRequired,oi);const si=ai,Id="exact-prop: ​";function Md(e){return process.env.NODE_ENV==="production"?e:O({},e,{[Id]:t=>{const n=Object.keys(t).filter(r=>!e.hasOwnProperty(r));return n.length>0?new Error(`The following props are not supported: ${n.map(r=>`\`${r}\``).join(", ")}. Please remove them.`):null}})}function zt(e){let t="https://mui.com/production-error/?code="+e;for(let n=1;n1?s("Invalid arguments supplied to oneOf, expected an array, got "+arguments.length+" arguments. A common mistake is to write oneOf(x, y, z) instead of oneOf([x, y, z])."):s("Invalid argument supplied to oneOf, expected an array.")),i;function T(z,L,B,X,q){for(var H=z[L],G=0;G0?", expected one of type ["+K.join(", ")+"]":"";return new f("Invalid "+H+" `"+G+"` supplied to "+("`"+q+"`"+ye+"."))}return m(L)}function _(){function y(T,z,L,B,X){return J(T[z])?null:new f("Invalid "+B+" `"+X+"` supplied to "+("`"+L+"`, expected a ReactNode."))}return m(y)}function k(y,T,z,L,B){return new f((y||"React class")+": "+T+" type `"+z+"."+L+"` is invalid; it must be a function, usually from the `prop-types` package, but received `"+B+"`.")}function A(y){function T(z,L,B,X,q){var H=z[L],G=F(H);if(G!=="object")return new f("Invalid "+X+" `"+q+"` of type `"+G+"` "+("supplied to `"+B+"`, expected `object`."));for(var K in y){var Z=y[K];if(typeof Z!="function")return k(B,X,q,K,te(Z));var ue=Z(H,K,B,X,q+"."+K,n);if(ue)return ue}return null}return m(T)}function $(y){function T(z,L,B,X,q){var H=z[L],G=F(H);if(G!=="object")return new f("Invalid "+X+" `"+q+"` of type `"+G+"` "+("supplied to `"+B+"`, expected `object`."));var K=t({},z[L],y);for(var Z in K){var ue=y[Z];if(r(y,Z)&&typeof ue!="function")return k(B,X,q,Z,te(ue));if(!ue)return new f("Invalid "+X+" `"+q+"` key `"+Z+"` supplied to `"+B+"`.\nBad object: "+JSON.stringify(z[L],null," ")+` +Valid keys: `+JSON.stringify(Object.keys(y),null," "));var I=ue(H,Z,B,X,q+"."+Z,n);if(I)return I}return null}return m(T)}function J(y){switch(typeof y){case"number":case"string":case"undefined":return!0;case"boolean":return!y;case"object":if(Array.isArray(y))return y.every(J);if(y===null||l(y))return!0;var T=h(y);if(T){var z=T.call(y),L;if(T!==y.entries){for(;!(L=z.next()).done;)if(!J(L.value))return!1}else for(;!(L=z.next()).done;){var B=L.value;if(B&&!J(B[1]))return!1}}else return!1;return!0;default:return!1}}function Y(y,T){return y==="symbol"?!0:T?T["@@toStringTag"]==="Symbol"||typeof Symbol=="function"&&T instanceof Symbol:!1}function F(y){var T=typeof y;return Array.isArray(y)?"array":y instanceof RegExp?"object":Y(T,y)?"symbol":T}function te(y){if(typeof y>"u"||y===null)return""+y;var T=F(y);if(T==="object"){if(y instanceof Date)return"date";if(y instanceof RegExp)return"regexp"}return T}function se(y){var T=te(y);switch(T){case"array":case"object":return"an "+T;case"boolean":case"date":case"regexp":return"a "+T;default:return T}}function oe(y){return!y.constructor||!y.constructor.name?w:y.constructor.name}return b.checkPropTypes=o,b.resetWarningCache=o.resetWarningCache,b.PropTypes=b,b},Dr}var Br,ya;function Td(){if(ya)return Br;ya=1;var e=Co();function t(){}function n(){}return n.resetWarningCache=t,Br=function(){function r(i,l,c,d,u,h){if(h!==e){var w=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types");throw w.name="Invariant Violation",w}}r.isRequired=r;function o(){return r}var s={array:r,bigint:r,bool:r,func:r,number:r,object:r,string:r,symbol:r,any:r,arrayOf:o,element:r,elementType:r,instanceOf:o,node:r,objectOf:o,oneOf:o,oneOfType:o,shape:o,exact:o,checkPropTypes:n,resetWarningCache:t};return s.PropTypes=s,s},Br}if(process.env.NODE_ENV!=="production"){var Rd=ni(),Od=!0;Kr.exports=Cd()(Rd.isElement,Od)}else Kr.exports=Td()();var _d=Kr.exports;const p=xd(_d);function Pd(e){const{prototype:t={}}=e;return!!t.isReactComponent}function oi(e,t,n,r,o){const s=e[t],i=o||t;if(s==null||typeof window>"u")return null;let l;const c=s.type;return typeof c=="function"&&!Pd(c)&&(l="Did you accidentally use a plain function component for an element instead?"),l!==void 0?new Error(`Invalid ${r} \`${i}\` supplied to \`${n}\`. Expected an element that can hold a ref. ${l} For more information see https://mui.com/r/caveat-with-refs-guide`):null}const ai=jo(p.element,oi);ai.isRequired=jo(p.element.isRequired,oi);const si=ai,Id="exact-prop: ​";function Md(e){return process.env.NODE_ENV==="production"?e:O({},e,{[Id]:t=>{const n=Object.keys(t).filter(r=>!e.hasOwnProperty(r));return n.length>0?new Error(`The following props are not supported: ${n.map(r=>`\`${r}\``).join(", ")}. Please remove them.`):null}})}function zt(e){let t="https://mui.com/production-error/?code="+e;for(let n=1;nn==null?t:function(...o){t.apply(this,o),n.apply(this,o)},()=>{})}function Fd(e,t=166){let n;function r(...o){const s=()=>{e.apply(this,o)};clearTimeout(n),n=setTimeout(s,t)}return r.clear=()=>{clearTimeout(n)},r}function Gd(e,t){return process.env.NODE_ENV==="production"?()=>null:(n,r,o,s,i)=>{const l=o||"<>",c=i||r;return typeof n[r]<"u"?new Error(`The ${s} \`${c}\` of \`${l}\` is deprecated. ${t}`):null}}function Ud(e,t){var n,r;return M.isValidElement(e)&&t.indexOf((n=e.type.muiName)!=null?n:(r=e.type)==null||(r=r._payload)==null||(r=r.value)==null?void 0:r.muiName)!==-1}function Kn(e){return e&&e.ownerDocument||document}function qd(e){return Kn(e).defaultView||window}function Hd(e,t){if(process.env.NODE_ENV==="production")return()=>null;const n=t?O({},t.propTypes):null;return o=>(s,i,l,c,d,...u)=>{const h=d||i,w=n==null?void 0:n[h];if(w){const b=w(s,i,l,c,d,...u);if(b)return b}return typeof s[i]<"u"&&!s[o]?new Error(`The prop \`${h}\` of \`${e}\` can only be used together with the \`${o}\` prop.`):null}}function Jn(e,t){typeof e=="function"?e(t):e&&(e.current=t)}const Xd=typeof window<"u"?M.useLayoutEffect:M.useEffect,Lt=Xd;let Sa=0;function Yd(e){const[t,n]=M.useState(e),r=e||t;return M.useEffect(()=>{t==null&&(Sa+=1,n(`mui-${Sa}`))},[t]),r}const Ea=M["useId".toString()];function ci(e){if(Ea!==void 0){const t=Ea();return e??t}return Yd(e)}function Wd(e,t,n,r,o){if(process.env.NODE_ENV==="production")return null;const s=o||t;return typeof e[t]<"u"?new Error(`The prop \`${s}\` is not supported. Please remove it.`):null}function di({controlled:e,default:t,name:n,state:r="value"}){const{current:o}=M.useRef(e!==void 0),[s,i]=M.useState(t),l=o?e:s;if(process.env.NODE_ENV!=="production"){M.useEffect(()=>{o!==(e!==void 0)&&console.error([`MUI: A component is changing the ${o?"":"un"}controlled ${r} state of ${n} to be ${o?"un":""}controlled.`,"Elements should not switch from uncontrolled to controlled (or vice versa).",`Decide between using a controlled or uncontrolled ${n} element for the lifetime of the component.`,"The nature of the state is determined during the first render. It's considered controlled if the value is not `undefined`.","More info: https://fb.me/react-controlled-components"].join(` + */var ka;function Ad(){return ka||(ka=1,process.env.NODE_ENV!=="production"&&function(){var e=Symbol.for("react.element"),t=Symbol.for("react.portal"),n=Symbol.for("react.fragment"),r=Symbol.for("react.strict_mode"),o=Symbol.for("react.profiler"),s=Symbol.for("react.provider"),i=Symbol.for("react.context"),l=Symbol.for("react.server_context"),c=Symbol.for("react.forward_ref"),d=Symbol.for("react.suspense"),u=Symbol.for("react.suspense_list"),h=Symbol.for("react.memo"),w=Symbol.for("react.lazy"),b=Symbol.for("react.offscreen"),x=!1,f=!1,m=!1,S=!1,R=!1,j;j=Symbol.for("react.module.reference");function E(D){return!!(typeof D=="string"||typeof D=="function"||D===n||D===o||R||D===r||D===d||D===u||S||D===b||x||f||m||typeof D=="object"&&D!==null&&(D.$$typeof===w||D.$$typeof===h||D.$$typeof===s||D.$$typeof===i||D.$$typeof===c||D.$$typeof===j||D.getModuleId!==void 0))}function v(D){if(typeof D=="object"&&D!==null){var xe=D.$$typeof;switch(xe){case e:var Ge=D.type;switch(Ge){case n:case o:case r:case d:case u:return Ge;default:var lt=Ge&&Ge.$$typeof;switch(lt){case l:case i:case c:case w:case h:case s:return lt;default:return xe}}case t:return xe}}}var P=i,V=s,U=e,C=c,_=n,k=w,A=h,$=t,J=o,Y=r,F=d,te=u,se=!1,oe=!1;function y(D){return se||(se=!0,console.warn("The ReactIs.isAsyncMode() alias has been deprecated, and will be removed in React 18+.")),!1}function T(D){return oe||(oe=!0,console.warn("The ReactIs.isConcurrentMode() alias has been deprecated, and will be removed in React 18+.")),!1}function z(D){return v(D)===i}function L(D){return v(D)===s}function B(D){return typeof D=="object"&&D!==null&&D.$$typeof===e}function X(D){return v(D)===c}function q(D){return v(D)===n}function H(D){return v(D)===w}function G(D){return v(D)===h}function K(D){return v(D)===t}function Z(D){return v(D)===o}function ue(D){return v(D)===r}function I(D){return v(D)===d}function ye(D){return v(D)===u}de.ContextConsumer=P,de.ContextProvider=V,de.Element=U,de.ForwardRef=C,de.Fragment=_,de.Lazy=k,de.Memo=A,de.Portal=$,de.Profiler=J,de.StrictMode=Y,de.Suspense=F,de.SuspenseList=te,de.isAsyncMode=y,de.isConcurrentMode=T,de.isContextConsumer=z,de.isContextProvider=L,de.isElement=B,de.isForwardRef=X,de.isFragment=q,de.isLazy=H,de.isMemo=G,de.isPortal=K,de.isProfiler=Z,de.isStrictMode=ue,de.isSuspense=I,de.isSuspenseList=ye,de.isValidElementType=E,de.typeOf=v}()),de}process.env.NODE_ENV==="production"?Jr.exports=$d():Jr.exports=Ad();var Sa=Jr.exports;const Dd=/^\s*function(?:\s|\s*\/\*.*\*\/\s*)+([^(\s/]*)\s*/;function Bd(e){const t=`${e}`.match(Dd);return t&&t[1]||""}function ii(e,t=""){return e.displayName||e.name||Bd(e)||t}function Ea(e,t,n){const r=ii(t);return e.displayName||(r!==""?`${n}(${r})`:n)}function Vd(e){if(e!=null){if(typeof e=="string")return e;if(typeof e=="function")return ii(e,"Component");if(typeof e=="object")switch(e.$$typeof){case Sa.ForwardRef:return Ea(e,e.render,"ForwardRef");case Sa.Memo:return Ea(e,e.type,"memo");default:return}}}function xn(e,t,n,r,o){if(process.env.NODE_ENV==="production")return null;const s=e[t],i=o||t;return s==null?null:s&&s.nodeType!==1?new Error(`Invalid ${r} \`${i}\` supplied to \`${n}\`. Expected an HTMLElement.`):null}const zd=p.oneOfType([p.func,p.object]),li=zd;function Ye(e){if(typeof e!="string")throw new Error(process.env.NODE_ENV!=="production"?"MUI: `capitalize(string)` expects a string argument.":zt(7));return e.charAt(0).toUpperCase()+e.slice(1)}function Ld(...e){return e.reduce((t,n)=>n==null?t:function(...o){t.apply(this,o),n.apply(this,o)},()=>{})}function Fd(e,t=166){let n;function r(...o){const s=()=>{e.apply(this,o)};clearTimeout(n),n=setTimeout(s,t)}return r.clear=()=>{clearTimeout(n)},r}function Gd(e,t){return process.env.NODE_ENV==="production"?()=>null:(n,r,o,s,i)=>{const l=o||"<>",c=i||r;return typeof n[r]<"u"?new Error(`The ${s} \`${c}\` of \`${l}\` is deprecated. ${t}`):null}}function Ud(e,t){var n,r;return M.isValidElement(e)&&t.indexOf((n=e.type.muiName)!=null?n:(r=e.type)==null||(r=r._payload)==null||(r=r.value)==null?void 0:r.muiName)!==-1}function Kn(e){return e&&e.ownerDocument||document}function qd(e){return Kn(e).defaultView||window}function Hd(e,t){if(process.env.NODE_ENV==="production")return()=>null;const n=t?O({},t.propTypes):null;return o=>(s,i,l,c,d,...u)=>{const h=d||i,w=n==null?void 0:n[h];if(w){const b=w(s,i,l,c,d,...u);if(b)return b}return typeof s[i]<"u"&&!s[o]?new Error(`The prop \`${h}\` of \`${e}\` can only be used together with the \`${o}\` prop.`):null}}function Jn(e,t){typeof e=="function"?e(t):e&&(e.current=t)}const Xd=typeof window<"u"?M.useLayoutEffect:M.useEffect,Lt=Xd;let ja=0;function Yd(e){const[t,n]=M.useState(e),r=e||t;return M.useEffect(()=>{t==null&&(ja+=1,n(`mui-${ja}`))},[t]),r}const Ca=M["useId".toString()];function ci(e){if(Ca!==void 0){const t=Ca();return e??t}return Yd(e)}function Wd(e,t,n,r,o){if(process.env.NODE_ENV==="production")return null;const s=o||t;return typeof e[t]<"u"?new Error(`The prop \`${s}\` is not supported. Please remove it.`):null}function di({controlled:e,default:t,name:n,state:r="value"}){const{current:o}=M.useRef(e!==void 0),[s,i]=M.useState(t),l=o?e:s;if(process.env.NODE_ENV!=="production"){M.useEffect(()=>{o!==(e!==void 0)&&console.error([`MUI: A component is changing the ${o?"":"un"}controlled ${r} state of ${n} to be ${o?"un":""}controlled.`,"Elements should not switch from uncontrolled to controlled (or vice versa).",`Decide between using a controlled or uncontrolled ${n} element for the lifetime of the component.`,"The nature of the state is determined during the first render. It's considered controlled if the value is not `undefined`.","More info: https://fb.me/react-controlled-components"].join(` `))},[r,n,e]);const{current:d}=M.useRef(t);M.useEffect(()=>{!o&&d!==t&&console.error([`MUI: A component is changing the default ${r} state of an uncontrolled ${n} after being initialized. To suppress this warning opt to use a controlled ${n}.`].join(` -`))},[JSON.stringify(t)])}const c=M.useCallback(d=>{o||i(d)},[]);return[l,c]}function Zr(e){const t=M.useRef(e);return Lt(()=>{t.current=e}),M.useRef((...n)=>(0,t.current)(...n)).current}function yt(...e){return M.useMemo(()=>e.every(t=>t==null)?null:t=>{e.forEach(n=>{Jn(n,t)})},e)}const ja={};function Kd(e,t){const n=M.useRef(ja);return n.current===ja&&(n.current=e(t)),n}const Jd=[];function Zd(e){M.useEffect(e,Jd)}class On{constructor(){this.currentId=null,this.clear=()=>{this.currentId!==null&&(clearTimeout(this.currentId),this.currentId=null)},this.disposeEffect=()=>this.clear}static create(){return new On}start(t,n){this.clear(),this.currentId=setTimeout(()=>{this.currentId=null,n()},t)}}function dn(){const e=Kd(On.create).current;return Zd(e.disposeEffect),e}let dr=!0,Qr=!1;const Qd=new On,eu={text:!0,search:!0,url:!0,tel:!0,email:!0,password:!0,number:!0,date:!0,month:!0,week:!0,time:!0,datetime:!0,"datetime-local":!0};function tu(e){const{type:t,tagName:n}=e;return!!(n==="INPUT"&&eu[t]&&!e.readOnly||n==="TEXTAREA"&&!e.readOnly||e.isContentEditable)}function nu(e){e.metaKey||e.altKey||e.ctrlKey||(dr=!0)}function Vr(){dr=!1}function ru(){this.visibilityState==="hidden"&&Qr&&(dr=!0)}function ou(e){e.addEventListener("keydown",nu,!0),e.addEventListener("mousedown",Vr,!0),e.addEventListener("pointerdown",Vr,!0),e.addEventListener("touchstart",Vr,!0),e.addEventListener("visibilitychange",ru,!0)}function au(e){const{target:t}=e;try{return t.matches(":focus-visible")}catch{}return dr||tu(t)}function ui(){const e=M.useCallback(o=>{o!=null&&ou(o.ownerDocument)},[]),t=M.useRef(!1);function n(){return t.current?(Qr=!0,Qd.start(100,()=>{Qr=!1}),t.current=!1,!0):!1}function r(o){return au(o)?(t.current=!0,!0):!1}return{isFocusVisibleRef:t,onFocus:r,onBlur:n,ref:e}}function pi(e,t){const n=O({},t);return Object.keys(e).forEach(r=>{if(r.toString().match(/^(components|slots)$/))n[r]=O({},e[r],n[r]);else if(r.toString().match(/^(componentsProps|slotProps)$/)){const o=e[r]||{},s=t[r];n[r]={},!s||!Object.keys(s)?n[r]=o:!o||!Object.keys(o)?n[r]=s:(n[r]=O({},s),Object.keys(o).forEach(i=>{n[r][i]=pi(o[i],s[i])}))}else n[r]===void 0&&(n[r]=e[r])}),n}function jo(e,t,n=void 0){const r={};return Object.keys(e).forEach(o=>{r[o]=e[o].reduce((s,i)=>{if(i){const l=t(i);l!==""&&s.push(l),n&&n[i]&&s.push(n[i])}return s},[]).join(" ")}),r}const Ca=e=>e,su=()=>{let e=Ca;return{configure(t){e=t},generate(t){return e(t)},reset(){e=Ca}}},iu=su(),wi=iu,fi={active:"active",checked:"checked",completed:"completed",disabled:"disabled",error:"error",expanded:"expanded",focused:"focused",focusVisible:"focusVisible",open:"open",readOnly:"readOnly",required:"required",selected:"selected"};function ur(e,t,n="Mui"){const r=fi[t];return r?`${n}-${r}`:`${wi.generate(e)}-${t}`}function mi(e,t,n="Mui"){const r={};return t.forEach(o=>{r[o]=ur(e,o,n)}),r}function lu(e,t=Number.MIN_SAFE_INTEGER,n=Number.MAX_SAFE_INTEGER){return Math.max(t,Math.min(e,n))}function Ne(e,t){if(e==null)return{};var n={},r=Object.keys(e),o,s;for(s=0;s=0)&&(n[o]=e[o]);return n}const cu=["values","unit","step"],du=e=>{const t=Object.keys(e).map(n=>({key:n,val:e[n]}))||[];return t.sort((n,r)=>n.val-r.val),t.reduce((n,r)=>O({},n,{[r.key]:r.val}),{})};function uu(e){const{values:t={xs:0,sm:600,md:900,lg:1200,xl:1536},unit:n="px",step:r=5}=e,o=Ne(e,cu),s=du(t),i=Object.keys(s);function l(w){return`@media (min-width:${typeof t[w]=="number"?t[w]:w}${n})`}function c(w){return`@media (max-width:${(typeof t[w]=="number"?t[w]:w)-r/100}${n})`}function d(w,b){const x=i.indexOf(b);return`@media (min-width:${typeof t[w]=="number"?t[w]:w}${n}) and (max-width:${(x!==-1&&typeof t[i[x]]=="number"?t[i[x]]:b)-r/100}${n})`}function u(w){return i.indexOf(w)+1`@media (min-width:${Co[e]}px)`};function et(e,t,n){const r=e.theme||{};if(Array.isArray(t)){const s=r.breakpoints||Ta;return t.reduce((i,l,c)=>(i[s.up(s.keys[c])]=n(t[c]),i),{})}if(typeof t=="object"){const s=r.breakpoints||Ta;return Object.keys(t).reduce((i,l)=>{if(Object.keys(s.values||Co).indexOf(l)!==-1){const c=s.up(l);i[c]=n(t[l],l)}else{const c=l;i[c]=t[c]}return i},{})}return n(t)}function mu(e={}){var t;return((t=e.keys)==null?void 0:t.reduce((r,o)=>{const s=e.up(o);return r[s]={},r},{}))||{}}function hu(e,t){return e.reduce((n,r)=>{const o=n[r];return(!o||Object.keys(o).length===0)&&delete n[r],n},t)}function pr(e,t,n=!0){if(!t||typeof t!="string")return null;if(e&&e.vars&&n){const r=`vars.${t}`.split(".").reduce((o,s)=>o&&o[s]?o[s]:null,e);if(r!=null)return r}return t.split(".").reduce((r,o)=>r&&r[o]!=null?r[o]:null,e)}function Zn(e,t,n,r=n){let o;return typeof e=="function"?o=e(n):Array.isArray(e)?o=e[n]||r:o=pr(e,n)||r,t&&(o=t(o,r,e)),o}function ve(e){const{prop:t,cssProperty:n=e.prop,themeKey:r,transform:o}=e,s=i=>{if(i[t]==null)return null;const l=i[t],c=i.theme,d=pr(c,r)||{};return et(i,l,h=>{let w=Zn(d,o,h);return h===w&&typeof h=="string"&&(w=Zn(d,o,`${t}${h==="default"?"":Ye(h)}`,h)),n===!1?w:{[n]:w}})};return s.propTypes=process.env.NODE_ENV!=="production"?{[t]:st}:{},s.filterProps=[t],s}function gu(e){const t={};return n=>(t[n]===void 0&&(t[n]=e(n)),t[n])}const bu={m:"margin",p:"padding"},vu={t:"Top",r:"Right",b:"Bottom",l:"Left",x:["Left","Right"],y:["Top","Bottom"]},Ra={marginX:"mx",marginY:"my",paddingX:"px",paddingY:"py"},xu=gu(e=>{if(e.length>2)if(Ra[e])e=Ra[e];else return[e];const[t,n]=e.split(""),r=bu[t],o=vu[n]||"";return Array.isArray(o)?o.map(s=>r+s):[r+o]}),wr=["m","mt","mr","mb","ml","mx","my","margin","marginTop","marginRight","marginBottom","marginLeft","marginX","marginY","marginInline","marginInlineStart","marginInlineEnd","marginBlock","marginBlockStart","marginBlockEnd"],fr=["p","pt","pr","pb","pl","px","py","padding","paddingTop","paddingRight","paddingBottom","paddingLeft","paddingX","paddingY","paddingInline","paddingInlineStart","paddingInlineEnd","paddingBlock","paddingBlockStart","paddingBlockEnd"],yu=[...wr,...fr];function _n(e,t,n,r){var o;const s=(o=pr(e,t,!1))!=null?o:n;return typeof s=="number"?i=>typeof i=="string"?i:(process.env.NODE_ENV!=="production"&&typeof i!="number"&&console.error(`MUI: Expected ${r} argument to be a number or a string, got ${i}.`),s*i):Array.isArray(s)?i=>typeof i=="string"?i:(process.env.NODE_ENV!=="production"&&(Number.isInteger(i)?i>s.length-1&&console.error([`MUI: The value provided (${i}) overflows.`,`The supported values are: ${JSON.stringify(s)}.`,`${i} > ${s.length-1}, you need to add the missing values.`].join(` +`))},[JSON.stringify(t)])}const c=M.useCallback(d=>{o||i(d)},[]);return[l,c]}function Zr(e){const t=M.useRef(e);return Lt(()=>{t.current=e}),M.useRef((...n)=>(0,t.current)(...n)).current}function yt(...e){return M.useMemo(()=>e.every(t=>t==null)?null:t=>{e.forEach(n=>{Jn(n,t)})},e)}const Ta={};function Kd(e,t){const n=M.useRef(Ta);return n.current===Ta&&(n.current=e(t)),n}const Jd=[];function Zd(e){M.useEffect(e,Jd)}class On{constructor(){this.currentId=null,this.clear=()=>{this.currentId!==null&&(clearTimeout(this.currentId),this.currentId=null)},this.disposeEffect=()=>this.clear}static create(){return new On}start(t,n){this.clear(),this.currentId=setTimeout(()=>{this.currentId=null,n()},t)}}function dn(){const e=Kd(On.create).current;return Zd(e.disposeEffect),e}let dr=!0,Qr=!1;const Qd=new On,eu={text:!0,search:!0,url:!0,tel:!0,email:!0,password:!0,number:!0,date:!0,month:!0,week:!0,time:!0,datetime:!0,"datetime-local":!0};function tu(e){const{type:t,tagName:n}=e;return!!(n==="INPUT"&&eu[t]&&!e.readOnly||n==="TEXTAREA"&&!e.readOnly||e.isContentEditable)}function nu(e){e.metaKey||e.altKey||e.ctrlKey||(dr=!0)}function Vr(){dr=!1}function ru(){this.visibilityState==="hidden"&&Qr&&(dr=!0)}function ou(e){e.addEventListener("keydown",nu,!0),e.addEventListener("mousedown",Vr,!0),e.addEventListener("pointerdown",Vr,!0),e.addEventListener("touchstart",Vr,!0),e.addEventListener("visibilitychange",ru,!0)}function au(e){const{target:t}=e;try{return t.matches(":focus-visible")}catch{}return dr||tu(t)}function ui(){const e=M.useCallback(o=>{o!=null&&ou(o.ownerDocument)},[]),t=M.useRef(!1);function n(){return t.current?(Qr=!0,Qd.start(100,()=>{Qr=!1}),t.current=!1,!0):!1}function r(o){return au(o)?(t.current=!0,!0):!1}return{isFocusVisibleRef:t,onFocus:r,onBlur:n,ref:e}}function pi(e,t){const n=O({},t);return Object.keys(e).forEach(r=>{if(r.toString().match(/^(components|slots)$/))n[r]=O({},e[r],n[r]);else if(r.toString().match(/^(componentsProps|slotProps)$/)){const o=e[r]||{},s=t[r];n[r]={},!s||!Object.keys(s)?n[r]=o:!o||!Object.keys(o)?n[r]=s:(n[r]=O({},s),Object.keys(o).forEach(i=>{n[r][i]=pi(o[i],s[i])}))}else n[r]===void 0&&(n[r]=e[r])}),n}function To(e,t,n=void 0){const r={};return Object.keys(e).forEach(o=>{r[o]=e[o].reduce((s,i)=>{if(i){const l=t(i);l!==""&&s.push(l),n&&n[i]&&s.push(n[i])}return s},[]).join(" ")}),r}const Ra=e=>e,su=()=>{let e=Ra;return{configure(t){e=t},generate(t){return e(t)},reset(){e=Ra}}},iu=su(),wi=iu,fi={active:"active",checked:"checked",completed:"completed",disabled:"disabled",error:"error",expanded:"expanded",focused:"focused",focusVisible:"focusVisible",open:"open",readOnly:"readOnly",required:"required",selected:"selected"};function ur(e,t,n="Mui"){const r=fi[t];return r?`${n}-${r}`:`${wi.generate(e)}-${t}`}function mi(e,t,n="Mui"){const r={};return t.forEach(o=>{r[o]=ur(e,o,n)}),r}function lu(e,t=Number.MIN_SAFE_INTEGER,n=Number.MAX_SAFE_INTEGER){return Math.max(t,Math.min(e,n))}function Ne(e,t){if(e==null)return{};var n={},r=Object.keys(e),o,s;for(s=0;s=0)&&(n[o]=e[o]);return n}const cu=["values","unit","step"],du=e=>{const t=Object.keys(e).map(n=>({key:n,val:e[n]}))||[];return t.sort((n,r)=>n.val-r.val),t.reduce((n,r)=>O({},n,{[r.key]:r.val}),{})};function uu(e){const{values:t={xs:0,sm:600,md:900,lg:1200,xl:1536},unit:n="px",step:r=5}=e,o=Ne(e,cu),s=du(t),i=Object.keys(s);function l(w){return`@media (min-width:${typeof t[w]=="number"?t[w]:w}${n})`}function c(w){return`@media (max-width:${(typeof t[w]=="number"?t[w]:w)-r/100}${n})`}function d(w,b){const x=i.indexOf(b);return`@media (min-width:${typeof t[w]=="number"?t[w]:w}${n}) and (max-width:${(x!==-1&&typeof t[i[x]]=="number"?t[i[x]]:b)-r/100}${n})`}function u(w){return i.indexOf(w)+1`@media (min-width:${Ro[e]}px)`};function et(e,t,n){const r=e.theme||{};if(Array.isArray(t)){const s=r.breakpoints||Oa;return t.reduce((i,l,c)=>(i[s.up(s.keys[c])]=n(t[c]),i),{})}if(typeof t=="object"){const s=r.breakpoints||Oa;return Object.keys(t).reduce((i,l)=>{if(Object.keys(s.values||Ro).indexOf(l)!==-1){const c=s.up(l);i[c]=n(t[l],l)}else{const c=l;i[c]=t[c]}return i},{})}return n(t)}function mu(e={}){var t;return((t=e.keys)==null?void 0:t.reduce((r,o)=>{const s=e.up(o);return r[s]={},r},{}))||{}}function hu(e,t){return e.reduce((n,r)=>{const o=n[r];return(!o||Object.keys(o).length===0)&&delete n[r],n},t)}function pr(e,t,n=!0){if(!t||typeof t!="string")return null;if(e&&e.vars&&n){const r=`vars.${t}`.split(".").reduce((o,s)=>o&&o[s]?o[s]:null,e);if(r!=null)return r}return t.split(".").reduce((r,o)=>r&&r[o]!=null?r[o]:null,e)}function Zn(e,t,n,r=n){let o;return typeof e=="function"?o=e(n):Array.isArray(e)?o=e[n]||r:o=pr(e,n)||r,t&&(o=t(o,r,e)),o}function ve(e){const{prop:t,cssProperty:n=e.prop,themeKey:r,transform:o}=e,s=i=>{if(i[t]==null)return null;const l=i[t],c=i.theme,d=pr(c,r)||{};return et(i,l,h=>{let w=Zn(d,o,h);return h===w&&typeof h=="string"&&(w=Zn(d,o,`${t}${h==="default"?"":Ye(h)}`,h)),n===!1?w:{[n]:w}})};return s.propTypes=process.env.NODE_ENV!=="production"?{[t]:st}:{},s.filterProps=[t],s}function gu(e){const t={};return n=>(t[n]===void 0&&(t[n]=e(n)),t[n])}const bu={m:"margin",p:"padding"},vu={t:"Top",r:"Right",b:"Bottom",l:"Left",x:["Left","Right"],y:["Top","Bottom"]},_a={marginX:"mx",marginY:"my",paddingX:"px",paddingY:"py"},xu=gu(e=>{if(e.length>2)if(_a[e])e=_a[e];else return[e];const[t,n]=e.split(""),r=bu[t],o=vu[n]||"";return Array.isArray(o)?o.map(s=>r+s):[r+o]}),wr=["m","mt","mr","mb","ml","mx","my","margin","marginTop","marginRight","marginBottom","marginLeft","marginX","marginY","marginInline","marginInlineStart","marginInlineEnd","marginBlock","marginBlockStart","marginBlockEnd"],fr=["p","pt","pr","pb","pl","px","py","padding","paddingTop","paddingRight","paddingBottom","paddingLeft","paddingX","paddingY","paddingInline","paddingInlineStart","paddingInlineEnd","paddingBlock","paddingBlockStart","paddingBlockEnd"],yu=[...wr,...fr];function _n(e,t,n,r){var o;const s=(o=pr(e,t,!1))!=null?o:n;return typeof s=="number"?i=>typeof i=="string"?i:(process.env.NODE_ENV!=="production"&&typeof i!="number"&&console.error(`MUI: Expected ${r} argument to be a number or a string, got ${i}.`),s*i):Array.isArray(s)?i=>typeof i=="string"?i:(process.env.NODE_ENV!=="production"&&(Number.isInteger(i)?i>s.length-1&&console.error([`MUI: The value provided (${i}) overflows.`,`The supported values are: ${JSON.stringify(s)}.`,`${i} > ${s.length-1}, you need to add the missing values.`].join(` `)):console.error([`MUI: The \`theme.${t}\` array type cannot be combined with non integer values.You should either use an integer value that can be used as index, or define the \`theme.${t}\` as a number.`].join(` `))),s[i]):typeof s=="function"?s:(process.env.NODE_ENV!=="production"&&console.error([`MUI: The \`theme.${t}\` value (${s}) is invalid.`,"It should be a number, an array or a function."].join(` -`)),()=>{})}function hi(e){return _n(e,"spacing",8,"spacing")}function Pn(e,t){if(typeof t=="string"||t==null)return t;const n=Math.abs(t),r=e(n);return t>=0?r:typeof r=="number"?-r:`-${r}`}function Nu(e,t){return n=>e.reduce((r,o)=>(r[o]=Pn(t,n),r),{})}function ku(e,t,n,r){if(t.indexOf(n)===-1)return null;const o=xu(n),s=Nu(o,r),i=e[n];return et(e,i,s)}function gi(e,t){const n=hi(e.theme);return Object.keys(e).map(r=>ku(e,t,r,n)).reduce(mn,{})}function me(e){return gi(e,wr)}me.propTypes=process.env.NODE_ENV!=="production"?wr.reduce((e,t)=>(e[t]=st,e),{}):{};me.filterProps=wr;function he(e){return gi(e,fr)}he.propTypes=process.env.NODE_ENV!=="production"?fr.reduce((e,t)=>(e[t]=st,e),{}):{};he.filterProps=fr;process.env.NODE_ENV!=="production"&&yu.reduce((e,t)=>(e[t]=st,e),{});function Su(e=8){if(e.mui)return e;const t=hi({spacing:e}),n=(...r)=>(process.env.NODE_ENV!=="production"&&(r.length<=4||console.error(`MUI: Too many arguments provided, expected between 0 and 4, got ${r.length}`)),(r.length===0?[1]:r).map(s=>{const i=t(s);return typeof i=="number"?`${i}px`:i}).join(" "));return n.mui=!0,n}function mr(...e){const t=e.reduce((r,o)=>(o.filterProps.forEach(s=>{r[s]=o}),r),{}),n=r=>Object.keys(r).reduce((o,s)=>t[s]?mn(o,t[s](r)):o,{});return n.propTypes=process.env.NODE_ENV!=="production"?e.reduce((r,o)=>Object.assign(r,o.propTypes),{}):{},n.filterProps=e.reduce((r,o)=>r.concat(o.filterProps),[]),n}function Be(e){return typeof e!="number"?e:`${e}px solid`}function Fe(e,t){return ve({prop:e,themeKey:"borders",transform:t})}const Eu=Fe("border",Be),ju=Fe("borderTop",Be),Cu=Fe("borderRight",Be),Tu=Fe("borderBottom",Be),Ru=Fe("borderLeft",Be),Ou=Fe("borderColor"),_u=Fe("borderTopColor"),Pu=Fe("borderRightColor"),Iu=Fe("borderBottomColor"),Mu=Fe("borderLeftColor"),$u=Fe("outline",Be),Du=Fe("outlineColor"),hr=e=>{if(e.borderRadius!==void 0&&e.borderRadius!==null){const t=_n(e.theme,"shape.borderRadius",4,"borderRadius"),n=r=>({borderRadius:Pn(t,r)});return et(e,e.borderRadius,n)}return null};hr.propTypes=process.env.NODE_ENV!=="production"?{borderRadius:st}:{};hr.filterProps=["borderRadius"];mr(Eu,ju,Cu,Tu,Ru,Ou,_u,Pu,Iu,Mu,hr,$u,Du);const gr=e=>{if(e.gap!==void 0&&e.gap!==null){const t=_n(e.theme,"spacing",8,"gap"),n=r=>({gap:Pn(t,r)});return et(e,e.gap,n)}return null};gr.propTypes=process.env.NODE_ENV!=="production"?{gap:st}:{};gr.filterProps=["gap"];const br=e=>{if(e.columnGap!==void 0&&e.columnGap!==null){const t=_n(e.theme,"spacing",8,"columnGap"),n=r=>({columnGap:Pn(t,r)});return et(e,e.columnGap,n)}return null};br.propTypes=process.env.NODE_ENV!=="production"?{columnGap:st}:{};br.filterProps=["columnGap"];const vr=e=>{if(e.rowGap!==void 0&&e.rowGap!==null){const t=_n(e.theme,"spacing",8,"rowGap"),n=r=>({rowGap:Pn(t,r)});return et(e,e.rowGap,n)}return null};vr.propTypes=process.env.NODE_ENV!=="production"?{rowGap:st}:{};vr.filterProps=["rowGap"];const Au=ve({prop:"gridColumn"}),Bu=ve({prop:"gridRow"}),Vu=ve({prop:"gridAutoFlow"}),zu=ve({prop:"gridAutoColumns"}),Lu=ve({prop:"gridAutoRows"}),Fu=ve({prop:"gridTemplateColumns"}),Gu=ve({prop:"gridTemplateRows"}),Uu=ve({prop:"gridTemplateAreas"}),qu=ve({prop:"gridArea"});mr(gr,br,vr,Au,Bu,Vu,zu,Lu,Fu,Gu,Uu,qu);function Dt(e,t){return t==="grey"?t:e}const Hu=ve({prop:"color",themeKey:"palette",transform:Dt}),Xu=ve({prop:"bgcolor",cssProperty:"backgroundColor",themeKey:"palette",transform:Dt}),Yu=ve({prop:"backgroundColor",themeKey:"palette",transform:Dt});mr(Hu,Xu,Yu);function Me(e){return e<=1&&e!==0?`${e*100}%`:e}const Wu=ve({prop:"width",transform:Me}),To=e=>{if(e.maxWidth!==void 0&&e.maxWidth!==null){const t=n=>{var r,o;const s=((r=e.theme)==null||(r=r.breakpoints)==null||(r=r.values)==null?void 0:r[n])||Co[n];return s?((o=e.theme)==null||(o=o.breakpoints)==null?void 0:o.unit)!=="px"?{maxWidth:`${s}${e.theme.breakpoints.unit}`}:{maxWidth:s}:{maxWidth:Me(n)}};return et(e,e.maxWidth,t)}return null};To.filterProps=["maxWidth"];const Ku=ve({prop:"minWidth",transform:Me}),Ju=ve({prop:"height",transform:Me}),Zu=ve({prop:"maxHeight",transform:Me}),Qu=ve({prop:"minHeight",transform:Me});ve({prop:"size",cssProperty:"width",transform:Me});ve({prop:"size",cssProperty:"height",transform:Me});const ep=ve({prop:"boxSizing"});mr(Wu,To,Ku,Ju,Zu,Qu,ep);const tp={border:{themeKey:"borders",transform:Be},borderTop:{themeKey:"borders",transform:Be},borderRight:{themeKey:"borders",transform:Be},borderBottom:{themeKey:"borders",transform:Be},borderLeft:{themeKey:"borders",transform:Be},borderColor:{themeKey:"palette"},borderTopColor:{themeKey:"palette"},borderRightColor:{themeKey:"palette"},borderBottomColor:{themeKey:"palette"},borderLeftColor:{themeKey:"palette"},outline:{themeKey:"borders",transform:Be},outlineColor:{themeKey:"palette"},borderRadius:{themeKey:"shape.borderRadius",style:hr},color:{themeKey:"palette",transform:Dt},bgcolor:{themeKey:"palette",cssProperty:"backgroundColor",transform:Dt},backgroundColor:{themeKey:"palette",transform:Dt},p:{style:he},pt:{style:he},pr:{style:he},pb:{style:he},pl:{style:he},px:{style:he},py:{style:he},padding:{style:he},paddingTop:{style:he},paddingRight:{style:he},paddingBottom:{style:he},paddingLeft:{style:he},paddingX:{style:he},paddingY:{style:he},paddingInline:{style:he},paddingInlineStart:{style:he},paddingInlineEnd:{style:he},paddingBlock:{style:he},paddingBlockStart:{style:he},paddingBlockEnd:{style:he},m:{style:me},mt:{style:me},mr:{style:me},mb:{style:me},ml:{style:me},mx:{style:me},my:{style:me},margin:{style:me},marginTop:{style:me},marginRight:{style:me},marginBottom:{style:me},marginLeft:{style:me},marginX:{style:me},marginY:{style:me},marginInline:{style:me},marginInlineStart:{style:me},marginInlineEnd:{style:me},marginBlock:{style:me},marginBlockStart:{style:me},marginBlockEnd:{style:me},displayPrint:{cssProperty:!1,transform:e=>({"@media print":{display:e}})},display:{},overflow:{},textOverflow:{},visibility:{},whiteSpace:{},flexBasis:{},flexDirection:{},flexWrap:{},justifyContent:{},alignItems:{},alignContent:{},order:{},flex:{},flexGrow:{},flexShrink:{},alignSelf:{},justifyItems:{},justifySelf:{},gap:{style:gr},rowGap:{style:vr},columnGap:{style:br},gridColumn:{},gridRow:{},gridAutoFlow:{},gridAutoColumns:{},gridAutoRows:{},gridTemplateColumns:{},gridTemplateRows:{},gridTemplateAreas:{},gridArea:{},position:{},zIndex:{themeKey:"zIndex"},top:{},right:{},bottom:{},left:{},boxShadow:{themeKey:"shadows"},width:{transform:Me},maxWidth:{style:To},minWidth:{transform:Me},height:{transform:Me},maxHeight:{transform:Me},minHeight:{transform:Me},boxSizing:{},fontFamily:{themeKey:"typography"},fontSize:{themeKey:"typography"},fontStyle:{themeKey:"typography"},fontWeight:{themeKey:"typography"},letterSpacing:{},textTransform:{},lineHeight:{},textAlign:{},typography:{cssProperty:!1,themeKey:"typography"}},Ro=tp;function np(...e){const t=e.reduce((r,o)=>r.concat(Object.keys(o)),[]),n=new Set(t);return e.every(r=>n.size===Object.keys(r).length)}function rp(e,t){return typeof e=="function"?e(t):e}function op(){function e(n,r,o,s){const i={[n]:r,theme:o},l=s[n];if(!l)return{[n]:r};const{cssProperty:c=n,themeKey:d,transform:u,style:h}=l;if(r==null)return null;if(d==="typography"&&r==="inherit")return{[n]:r};const w=pr(o,d)||{};return h?h(i):et(i,r,x=>{let f=Zn(w,u,x);return x===f&&typeof x=="string"&&(f=Zn(w,u,`${n}${x==="default"?"":Ye(x)}`,x)),c===!1?f:{[c]:f}})}function t(n){var r;const{sx:o,theme:s={}}=n||{};if(!o)return null;const i=(r=s.unstable_sxConfig)!=null?r:Ro;function l(c){let d=c;if(typeof c=="function")d=c(s);else if(typeof c!="object")return c;if(!d)return null;const u=mu(s.breakpoints),h=Object.keys(u);let w=u;return Object.keys(d).forEach(b=>{const x=rp(d[b],s);if(x!=null)if(typeof x=="object")if(i[b])w=mn(w,e(b,x,s,i));else{const f=et({theme:s},x,m=>({[b]:m}));np(f,x)?w[b]=t({sx:x,theme:s}):w=mn(w,f)}else w=mn(w,e(b,x,s,i))}),hu(h,w)}return Array.isArray(o)?o.map(l):l(o)}return t}const bi=op();bi.filterProps=["sx"];const Oo=bi;function ap(e,t){const n=this;return n.vars&&typeof n.getColorSchemeSelector=="function"?{[n.getColorSchemeSelector(e).replace(/(\[[^\]]+\])/,"*:where($1)")]:t}:n.palette.mode===e?t:{}}const sp=["breakpoints","palette","spacing","shape"];function _o(e={},...t){const{breakpoints:n={},palette:r={},spacing:o,shape:s={}}=e,i=Ne(e,sp),l=uu(n),c=Su(o);let d=Qe({breakpoints:l,direction:"ltr",components:{},palette:O({mode:"light"},r),spacing:c,shape:O({},wu,s)},i);return d.applyStyles=ap,d=t.reduce((u,h)=>Qe(u,h),d),d.unstable_sxConfig=O({},Ro,i==null?void 0:i.unstable_sxConfig),d.unstable_sx=function(h){return Oo({sx:h,theme:this})},d}function ip(e){return Object.keys(e).length===0}function vi(e=null){const t=M.useContext(Gr.ThemeContext);return!t||ip(t)?e:t}const lp=_o();function xi(e=lp){return vi(e)}const cp=["ownerState"],dp=["variants"],up=["name","slot","skipVariantsResolver","skipSx","overridesResolver"];function pp(e){return Object.keys(e).length===0}function wp(e){return typeof e=="string"&&e.charCodeAt(0)>96}function qn(e){return e!=="ownerState"&&e!=="theme"&&e!=="sx"&&e!=="as"}const fp=_o(),Oa=e=>e&&e.charAt(0).toLowerCase()+e.slice(1);function Ln({defaultTheme:e,theme:t,themeId:n}){return pp(t)?e:t[n]||t}function mp(e){return e?(t,n)=>n[e]:null}function Hn(e,t){let{ownerState:n}=t,r=Ne(t,cp);const o=typeof e=="function"?e(O({ownerState:n},r)):e;if(Array.isArray(o))return o.flatMap(s=>Hn(s,O({ownerState:n},r)));if(o&&typeof o=="object"&&Array.isArray(o.variants)){const{variants:s=[]}=o;let l=Ne(o,dp);return s.forEach(c=>{let d=!0;typeof c.props=="function"?d=c.props(O({ownerState:n},r,n)):Object.keys(c.props).forEach(u=>{(n==null?void 0:n[u])!==c.props[u]&&r[u]!==c.props[u]&&(d=!1)}),d&&(Array.isArray(l)||(l=[l]),l.push(typeof c.style=="function"?c.style(O({ownerState:n},r,n)):c.style))}),l}return o}function hp(e={}){const{themeId:t,defaultTheme:n=fp,rootShouldForwardProp:r=qn,slotShouldForwardProp:o=qn}=e,s=i=>Oo(O({},i,{theme:Ln(O({},i,{defaultTheme:n,themeId:t}))}));return s.__mui_systemSx=!0,(i,l={})=>{Gr.internal_processStyles(i,v=>v.filter(P=>!(P!=null&&P.__mui_systemSx)));const{name:c,slot:d,skipVariantsResolver:u,skipSx:h,overridesResolver:w=mp(Oa(d))}=l,b=Ne(l,up),x=u!==void 0?u:d&&d!=="Root"&&d!=="root"||!1,f=h||!1;let m;process.env.NODE_ENV!=="production"&&c&&(m=`${c}-${Oa(d||"Root")}`);let S=qn;d==="Root"||d==="root"?S=r:d?S=o:wp(i)&&(S=void 0);const R=Gr(i,O({shouldForwardProp:S,label:m},b)),j=v=>typeof v=="function"&&v.__emotion_real!==v||mt(v)?P=>Hn(v,O({},P,{theme:Ln({theme:P.theme,defaultTheme:n,themeId:t})})):v,E=(v,...P)=>{let V=j(v);const U=P?P.map(j):[];c&&w&&U.push(k=>{const D=Ln(O({},k,{defaultTheme:n,themeId:t}));if(!D.components||!D.components[c]||!D.components[c].styleOverrides)return null;const $=D.components[c].styleOverrides,J={};return Object.entries($).forEach(([Y,F])=>{J[Y]=Hn(F,O({},k,{theme:D}))}),w(k,J)}),c&&!x&&U.push(k=>{var D;const $=Ln(O({},k,{defaultTheme:n,themeId:t})),J=$==null||(D=$.components)==null||(D=D[c])==null?void 0:D.variants;return Hn({variants:J},O({},k,{theme:$}))}),f||U.push(s);const C=U.length-P.length;if(Array.isArray(v)&&C>0){const k=new Array(C).fill("");V=[...v,...k],V.raw=[...v.raw,...k]}const _=R(V,...U);if(process.env.NODE_ENV!=="production"){let k;c&&(k=`${c}${Ye(d||"")}`),k===void 0&&(k=`Styled(${Vd(i)})`),_.displayName=k}return i.muiName&&(_.muiName=i.muiName),_};return R.withConfig&&(E.withConfig=R.withConfig),E}}function gp(e){const{theme:t,name:n,props:r}=e;return!t||!t.components||!t.components[n]||!t.components[n].defaultProps?r:pi(t.components[n].defaultProps,r)}function bp({props:e,name:t,defaultTheme:n,themeId:r}){let o=xi(n);return r&&(o=o[r]||o),gp({theme:o,name:t,props:e})}function Po(e,t=0,n=1){return process.env.NODE_ENV!=="production"&&(en)&&console.error(`MUI: The value provided ${e} is out of range [${t}, ${n}].`),lu(e,t,n)}function vp(e){e=e.slice(1);const t=new RegExp(`.{1,${e.length>=6?2:1}}`,"g");let n=e.match(t);return n&&n[0].length===1&&(n=n.map(r=>r+r)),n?`rgb${n.length===4?"a":""}(${n.map((r,o)=>o<3?parseInt(r,16):Math.round(parseInt(r,16)/255*1e3)/1e3).join(", ")})`:""}function Nt(e){if(e.type)return e;if(e.charAt(0)==="#")return Nt(vp(e));const t=e.indexOf("("),n=e.substring(0,t);if(["rgb","rgba","hsl","hsla","color"].indexOf(n)===-1)throw new Error(process.env.NODE_ENV!=="production"?`MUI: Unsupported \`${e}\` color. +`)),()=>{})}function hi(e){return _n(e,"spacing",8,"spacing")}function Pn(e,t){if(typeof t=="string"||t==null)return t;const n=Math.abs(t),r=e(n);return t>=0?r:typeof r=="number"?-r:`-${r}`}function Nu(e,t){return n=>e.reduce((r,o)=>(r[o]=Pn(t,n),r),{})}function ku(e,t,n,r){if(t.indexOf(n)===-1)return null;const o=xu(n),s=Nu(o,r),i=e[n];return et(e,i,s)}function gi(e,t){const n=hi(e.theme);return Object.keys(e).map(r=>ku(e,t,r,n)).reduce(mn,{})}function me(e){return gi(e,wr)}me.propTypes=process.env.NODE_ENV!=="production"?wr.reduce((e,t)=>(e[t]=st,e),{}):{};me.filterProps=wr;function he(e){return gi(e,fr)}he.propTypes=process.env.NODE_ENV!=="production"?fr.reduce((e,t)=>(e[t]=st,e),{}):{};he.filterProps=fr;process.env.NODE_ENV!=="production"&&yu.reduce((e,t)=>(e[t]=st,e),{});function Su(e=8){if(e.mui)return e;const t=hi({spacing:e}),n=(...r)=>(process.env.NODE_ENV!=="production"&&(r.length<=4||console.error(`MUI: Too many arguments provided, expected between 0 and 4, got ${r.length}`)),(r.length===0?[1]:r).map(s=>{const i=t(s);return typeof i=="number"?`${i}px`:i}).join(" "));return n.mui=!0,n}function mr(...e){const t=e.reduce((r,o)=>(o.filterProps.forEach(s=>{r[s]=o}),r),{}),n=r=>Object.keys(r).reduce((o,s)=>t[s]?mn(o,t[s](r)):o,{});return n.propTypes=process.env.NODE_ENV!=="production"?e.reduce((r,o)=>Object.assign(r,o.propTypes),{}):{},n.filterProps=e.reduce((r,o)=>r.concat(o.filterProps),[]),n}function Be(e){return typeof e!="number"?e:`${e}px solid`}function Fe(e,t){return ve({prop:e,themeKey:"borders",transform:t})}const Eu=Fe("border",Be),ju=Fe("borderTop",Be),Cu=Fe("borderRight",Be),Tu=Fe("borderBottom",Be),Ru=Fe("borderLeft",Be),Ou=Fe("borderColor"),_u=Fe("borderTopColor"),Pu=Fe("borderRightColor"),Iu=Fe("borderBottomColor"),Mu=Fe("borderLeftColor"),$u=Fe("outline",Be),Au=Fe("outlineColor"),hr=e=>{if(e.borderRadius!==void 0&&e.borderRadius!==null){const t=_n(e.theme,"shape.borderRadius",4,"borderRadius"),n=r=>({borderRadius:Pn(t,r)});return et(e,e.borderRadius,n)}return null};hr.propTypes=process.env.NODE_ENV!=="production"?{borderRadius:st}:{};hr.filterProps=["borderRadius"];mr(Eu,ju,Cu,Tu,Ru,Ou,_u,Pu,Iu,Mu,hr,$u,Au);const gr=e=>{if(e.gap!==void 0&&e.gap!==null){const t=_n(e.theme,"spacing",8,"gap"),n=r=>({gap:Pn(t,r)});return et(e,e.gap,n)}return null};gr.propTypes=process.env.NODE_ENV!=="production"?{gap:st}:{};gr.filterProps=["gap"];const br=e=>{if(e.columnGap!==void 0&&e.columnGap!==null){const t=_n(e.theme,"spacing",8,"columnGap"),n=r=>({columnGap:Pn(t,r)});return et(e,e.columnGap,n)}return null};br.propTypes=process.env.NODE_ENV!=="production"?{columnGap:st}:{};br.filterProps=["columnGap"];const vr=e=>{if(e.rowGap!==void 0&&e.rowGap!==null){const t=_n(e.theme,"spacing",8,"rowGap"),n=r=>({rowGap:Pn(t,r)});return et(e,e.rowGap,n)}return null};vr.propTypes=process.env.NODE_ENV!=="production"?{rowGap:st}:{};vr.filterProps=["rowGap"];const Du=ve({prop:"gridColumn"}),Bu=ve({prop:"gridRow"}),Vu=ve({prop:"gridAutoFlow"}),zu=ve({prop:"gridAutoColumns"}),Lu=ve({prop:"gridAutoRows"}),Fu=ve({prop:"gridTemplateColumns"}),Gu=ve({prop:"gridTemplateRows"}),Uu=ve({prop:"gridTemplateAreas"}),qu=ve({prop:"gridArea"});mr(gr,br,vr,Du,Bu,Vu,zu,Lu,Fu,Gu,Uu,qu);function At(e,t){return t==="grey"?t:e}const Hu=ve({prop:"color",themeKey:"palette",transform:At}),Xu=ve({prop:"bgcolor",cssProperty:"backgroundColor",themeKey:"palette",transform:At}),Yu=ve({prop:"backgroundColor",themeKey:"palette",transform:At});mr(Hu,Xu,Yu);function Ie(e){return e<=1&&e!==0?`${e*100}%`:e}const Wu=ve({prop:"width",transform:Ie}),Oo=e=>{if(e.maxWidth!==void 0&&e.maxWidth!==null){const t=n=>{var r,o;const s=((r=e.theme)==null||(r=r.breakpoints)==null||(r=r.values)==null?void 0:r[n])||Ro[n];return s?((o=e.theme)==null||(o=o.breakpoints)==null?void 0:o.unit)!=="px"?{maxWidth:`${s}${e.theme.breakpoints.unit}`}:{maxWidth:s}:{maxWidth:Ie(n)}};return et(e,e.maxWidth,t)}return null};Oo.filterProps=["maxWidth"];const Ku=ve({prop:"minWidth",transform:Ie}),Ju=ve({prop:"height",transform:Ie}),Zu=ve({prop:"maxHeight",transform:Ie}),Qu=ve({prop:"minHeight",transform:Ie});ve({prop:"size",cssProperty:"width",transform:Ie});ve({prop:"size",cssProperty:"height",transform:Ie});const ep=ve({prop:"boxSizing"});mr(Wu,Oo,Ku,Ju,Zu,Qu,ep);const tp={border:{themeKey:"borders",transform:Be},borderTop:{themeKey:"borders",transform:Be},borderRight:{themeKey:"borders",transform:Be},borderBottom:{themeKey:"borders",transform:Be},borderLeft:{themeKey:"borders",transform:Be},borderColor:{themeKey:"palette"},borderTopColor:{themeKey:"palette"},borderRightColor:{themeKey:"palette"},borderBottomColor:{themeKey:"palette"},borderLeftColor:{themeKey:"palette"},outline:{themeKey:"borders",transform:Be},outlineColor:{themeKey:"palette"},borderRadius:{themeKey:"shape.borderRadius",style:hr},color:{themeKey:"palette",transform:At},bgcolor:{themeKey:"palette",cssProperty:"backgroundColor",transform:At},backgroundColor:{themeKey:"palette",transform:At},p:{style:he},pt:{style:he},pr:{style:he},pb:{style:he},pl:{style:he},px:{style:he},py:{style:he},padding:{style:he},paddingTop:{style:he},paddingRight:{style:he},paddingBottom:{style:he},paddingLeft:{style:he},paddingX:{style:he},paddingY:{style:he},paddingInline:{style:he},paddingInlineStart:{style:he},paddingInlineEnd:{style:he},paddingBlock:{style:he},paddingBlockStart:{style:he},paddingBlockEnd:{style:he},m:{style:me},mt:{style:me},mr:{style:me},mb:{style:me},ml:{style:me},mx:{style:me},my:{style:me},margin:{style:me},marginTop:{style:me},marginRight:{style:me},marginBottom:{style:me},marginLeft:{style:me},marginX:{style:me},marginY:{style:me},marginInline:{style:me},marginInlineStart:{style:me},marginInlineEnd:{style:me},marginBlock:{style:me},marginBlockStart:{style:me},marginBlockEnd:{style:me},displayPrint:{cssProperty:!1,transform:e=>({"@media print":{display:e}})},display:{},overflow:{},textOverflow:{},visibility:{},whiteSpace:{},flexBasis:{},flexDirection:{},flexWrap:{},justifyContent:{},alignItems:{},alignContent:{},order:{},flex:{},flexGrow:{},flexShrink:{},alignSelf:{},justifyItems:{},justifySelf:{},gap:{style:gr},rowGap:{style:vr},columnGap:{style:br},gridColumn:{},gridRow:{},gridAutoFlow:{},gridAutoColumns:{},gridAutoRows:{},gridTemplateColumns:{},gridTemplateRows:{},gridTemplateAreas:{},gridArea:{},position:{},zIndex:{themeKey:"zIndex"},top:{},right:{},bottom:{},left:{},boxShadow:{themeKey:"shadows"},width:{transform:Ie},maxWidth:{style:Oo},minWidth:{transform:Ie},height:{transform:Ie},maxHeight:{transform:Ie},minHeight:{transform:Ie},boxSizing:{},fontFamily:{themeKey:"typography"},fontSize:{themeKey:"typography"},fontStyle:{themeKey:"typography"},fontWeight:{themeKey:"typography"},letterSpacing:{},textTransform:{},lineHeight:{},textAlign:{},typography:{cssProperty:!1,themeKey:"typography"}},_o=tp;function np(...e){const t=e.reduce((r,o)=>r.concat(Object.keys(o)),[]),n=new Set(t);return e.every(r=>n.size===Object.keys(r).length)}function rp(e,t){return typeof e=="function"?e(t):e}function op(){function e(n,r,o,s){const i={[n]:r,theme:o},l=s[n];if(!l)return{[n]:r};const{cssProperty:c=n,themeKey:d,transform:u,style:h}=l;if(r==null)return null;if(d==="typography"&&r==="inherit")return{[n]:r};const w=pr(o,d)||{};return h?h(i):et(i,r,x=>{let f=Zn(w,u,x);return x===f&&typeof x=="string"&&(f=Zn(w,u,`${n}${x==="default"?"":Ye(x)}`,x)),c===!1?f:{[c]:f}})}function t(n){var r;const{sx:o,theme:s={}}=n||{};if(!o)return null;const i=(r=s.unstable_sxConfig)!=null?r:_o;function l(c){let d=c;if(typeof c=="function")d=c(s);else if(typeof c!="object")return c;if(!d)return null;const u=mu(s.breakpoints),h=Object.keys(u);let w=u;return Object.keys(d).forEach(b=>{const x=rp(d[b],s);if(x!=null)if(typeof x=="object")if(i[b])w=mn(w,e(b,x,s,i));else{const f=et({theme:s},x,m=>({[b]:m}));np(f,x)?w[b]=t({sx:x,theme:s}):w=mn(w,f)}else w=mn(w,e(b,x,s,i))}),hu(h,w)}return Array.isArray(o)?o.map(l):l(o)}return t}const bi=op();bi.filterProps=["sx"];const Po=bi;function ap(e,t){const n=this;return n.vars&&typeof n.getColorSchemeSelector=="function"?{[n.getColorSchemeSelector(e).replace(/(\[[^\]]+\])/,"*:where($1)")]:t}:n.palette.mode===e?t:{}}const sp=["breakpoints","palette","spacing","shape"];function Io(e={},...t){const{breakpoints:n={},palette:r={},spacing:o,shape:s={}}=e,i=Ne(e,sp),l=uu(n),c=Su(o);let d=Qe({breakpoints:l,direction:"ltr",components:{},palette:O({mode:"light"},r),spacing:c,shape:O({},wu,s)},i);return d.applyStyles=ap,d=t.reduce((u,h)=>Qe(u,h),d),d.unstable_sxConfig=O({},_o,i==null?void 0:i.unstable_sxConfig),d.unstable_sx=function(h){return Po({sx:h,theme:this})},d}function ip(e){return Object.keys(e).length===0}function vi(e=null){const t=M.useContext(Gr.ThemeContext);return!t||ip(t)?e:t}const lp=Io();function xi(e=lp){return vi(e)}const cp=["ownerState"],dp=["variants"],up=["name","slot","skipVariantsResolver","skipSx","overridesResolver"];function pp(e){return Object.keys(e).length===0}function wp(e){return typeof e=="string"&&e.charCodeAt(0)>96}function qn(e){return e!=="ownerState"&&e!=="theme"&&e!=="sx"&&e!=="as"}const fp=Io(),Pa=e=>e&&e.charAt(0).toLowerCase()+e.slice(1);function Ln({defaultTheme:e,theme:t,themeId:n}){return pp(t)?e:t[n]||t}function mp(e){return e?(t,n)=>n[e]:null}function Hn(e,t){let{ownerState:n}=t,r=Ne(t,cp);const o=typeof e=="function"?e(O({ownerState:n},r)):e;if(Array.isArray(o))return o.flatMap(s=>Hn(s,O({ownerState:n},r)));if(o&&typeof o=="object"&&Array.isArray(o.variants)){const{variants:s=[]}=o;let l=Ne(o,dp);return s.forEach(c=>{let d=!0;typeof c.props=="function"?d=c.props(O({ownerState:n},r,n)):Object.keys(c.props).forEach(u=>{(n==null?void 0:n[u])!==c.props[u]&&r[u]!==c.props[u]&&(d=!1)}),d&&(Array.isArray(l)||(l=[l]),l.push(typeof c.style=="function"?c.style(O({ownerState:n},r,n)):c.style))}),l}return o}function hp(e={}){const{themeId:t,defaultTheme:n=fp,rootShouldForwardProp:r=qn,slotShouldForwardProp:o=qn}=e,s=i=>Po(O({},i,{theme:Ln(O({},i,{defaultTheme:n,themeId:t}))}));return s.__mui_systemSx=!0,(i,l={})=>{Gr.internal_processStyles(i,v=>v.filter(P=>!(P!=null&&P.__mui_systemSx)));const{name:c,slot:d,skipVariantsResolver:u,skipSx:h,overridesResolver:w=mp(Pa(d))}=l,b=Ne(l,up),x=u!==void 0?u:d&&d!=="Root"&&d!=="root"||!1,f=h||!1;let m;process.env.NODE_ENV!=="production"&&c&&(m=`${c}-${Pa(d||"Root")}`);let S=qn;d==="Root"||d==="root"?S=r:d?S=o:wp(i)&&(S=void 0);const R=Gr(i,O({shouldForwardProp:S,label:m},b)),j=v=>typeof v=="function"&&v.__emotion_real!==v||mt(v)?P=>Hn(v,O({},P,{theme:Ln({theme:P.theme,defaultTheme:n,themeId:t})})):v,E=(v,...P)=>{let V=j(v);const U=P?P.map(j):[];c&&w&&U.push(k=>{const A=Ln(O({},k,{defaultTheme:n,themeId:t}));if(!A.components||!A.components[c]||!A.components[c].styleOverrides)return null;const $=A.components[c].styleOverrides,J={};return Object.entries($).forEach(([Y,F])=>{J[Y]=Hn(F,O({},k,{theme:A}))}),w(k,J)}),c&&!x&&U.push(k=>{var A;const $=Ln(O({},k,{defaultTheme:n,themeId:t})),J=$==null||(A=$.components)==null||(A=A[c])==null?void 0:A.variants;return Hn({variants:J},O({},k,{theme:$}))}),f||U.push(s);const C=U.length-P.length;if(Array.isArray(v)&&C>0){const k=new Array(C).fill("");V=[...v,...k],V.raw=[...v.raw,...k]}const _=R(V,...U);if(process.env.NODE_ENV!=="production"){let k;c&&(k=`${c}${Ye(d||"")}`),k===void 0&&(k=`Styled(${Vd(i)})`),_.displayName=k}return i.muiName&&(_.muiName=i.muiName),_};return R.withConfig&&(E.withConfig=R.withConfig),E}}function gp(e){const{theme:t,name:n,props:r}=e;return!t||!t.components||!t.components[n]||!t.components[n].defaultProps?r:pi(t.components[n].defaultProps,r)}function bp({props:e,name:t,defaultTheme:n,themeId:r}){let o=xi(n);return r&&(o=o[r]||o),gp({theme:o,name:t,props:e})}function Mo(e,t=0,n=1){return process.env.NODE_ENV!=="production"&&(en)&&console.error(`MUI: The value provided ${e} is out of range [${t}, ${n}].`),lu(e,t,n)}function vp(e){e=e.slice(1);const t=new RegExp(`.{1,${e.length>=6?2:1}}`,"g");let n=e.match(t);return n&&n[0].length===1&&(n=n.map(r=>r+r)),n?`rgb${n.length===4?"a":""}(${n.map((r,o)=>o<3?parseInt(r,16):Math.round(parseInt(r,16)/255*1e3)/1e3).join(", ")})`:""}function Nt(e){if(e.type)return e;if(e.charAt(0)==="#")return Nt(vp(e));const t=e.indexOf("("),n=e.substring(0,t);if(["rgb","rgba","hsl","hsla","color"].indexOf(n)===-1)throw new Error(process.env.NODE_ENV!=="production"?`MUI: Unsupported \`${e}\` color. The following formats are supported: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color().`:zt(9,e));let r=e.substring(t+1,e.length-1),o;if(n==="color"){if(r=r.split(" "),o=r.shift(),r.length===4&&r[3].charAt(0)==="/"&&(r[3]=r[3].slice(1)),["srgb","display-p3","a98-rgb","prophoto-rgb","rec-2020"].indexOf(o)===-1)throw new Error(process.env.NODE_ENV!=="production"?`MUI: unsupported \`${o}\` color space. -The following color spaces are supported: srgb, display-p3, a98-rgb, prophoto-rgb, rec-2020.`:zt(10,o))}else r=r.split(",");return r=r.map(s=>parseFloat(s)),{type:n,values:r,colorSpace:o}}function xr(e){const{type:t,colorSpace:n}=e;let{values:r}=e;return t.indexOf("rgb")!==-1?r=r.map((o,s)=>s<3?parseInt(o,10):o):t.indexOf("hsl")!==-1&&(r[1]=`${r[1]}%`,r[2]=`${r[2]}%`),t.indexOf("color")!==-1?r=`${n} ${r.join(" ")}`:r=`${r.join(", ")}`,`${t}(${r})`}function xp(e){e=Nt(e);const{values:t}=e,n=t[0],r=t[1]/100,o=t[2]/100,s=r*Math.min(o,1-o),i=(d,u=(d+n/30)%12)=>o-s*Math.max(Math.min(u-3,9-u,1),-1);let l="rgb";const c=[Math.round(i(0)*255),Math.round(i(8)*255),Math.round(i(4)*255)];return e.type==="hsla"&&(l+="a",c.push(t[3])),xr({type:l,values:c})}function _a(e){e=Nt(e);let t=e.type==="hsl"||e.type==="hsla"?Nt(xp(e)).values:e.values;return t=t.map(n=>(e.type!=="color"&&(n/=255),n<=.03928?n/12.92:((n+.055)/1.055)**2.4)),Number((.2126*t[0]+.7152*t[1]+.0722*t[2]).toFixed(3))}function Pa(e,t){const n=_a(e),r=_a(t);return(Math.max(n,r)+.05)/(Math.min(n,r)+.05)}function yi(e,t){return e=Nt(e),t=Po(t),(e.type==="rgb"||e.type==="hsl")&&(e.type+="a"),e.type==="color"?e.values[3]=`/${t}`:e.values[3]=t,xr(e)}function yp(e,t){if(e=Nt(e),t=Po(t),e.type.indexOf("hsl")!==-1)e.values[2]*=1-t;else if(e.type.indexOf("rgb")!==-1||e.type.indexOf("color")!==-1)for(let n=0;n<3;n+=1)e.values[n]*=1-t;return xr(e)}function Np(e,t){if(e=Nt(e),t=Po(t),e.type.indexOf("hsl")!==-1)e.values[2]+=(100-e.values[2])*t;else if(e.type.indexOf("rgb")!==-1)for(let n=0;n<3;n+=1)e.values[n]+=(255-e.values[n])*t;else if(e.type.indexOf("color")!==-1)for(let n=0;n<3;n+=1)e.values[n]+=(1-e.values[n])*t;return xr(e)}function kp(e,t){return O({toolbar:{minHeight:56,[e.up("xs")]:{"@media (orientation: landscape)":{minHeight:48}},[e.up("sm")]:{minHeight:64}}},t)}const Sp={black:"#000",white:"#fff"},yn=Sp,Ep={50:"#fafafa",100:"#f5f5f5",200:"#eeeeee",300:"#e0e0e0",400:"#bdbdbd",500:"#9e9e9e",600:"#757575",700:"#616161",800:"#424242",900:"#212121",A100:"#f5f5f5",A200:"#eeeeee",A400:"#bdbdbd",A700:"#616161"},jp=Ep,Cp={50:"#f3e5f5",100:"#e1bee7",200:"#ce93d8",300:"#ba68c8",400:"#ab47bc",500:"#9c27b0",600:"#8e24aa",700:"#7b1fa2",800:"#6a1b9a",900:"#4a148c",A100:"#ea80fc",A200:"#e040fb",A400:"#d500f9",A700:"#aa00ff"},Rt=Cp,Tp={50:"#ffebee",100:"#ffcdd2",200:"#ef9a9a",300:"#e57373",400:"#ef5350",500:"#f44336",600:"#e53935",700:"#d32f2f",800:"#c62828",900:"#b71c1c",A100:"#ff8a80",A200:"#ff5252",A400:"#ff1744",A700:"#d50000"},Ot=Tp,Rp={50:"#fff3e0",100:"#ffe0b2",200:"#ffcc80",300:"#ffb74d",400:"#ffa726",500:"#ff9800",600:"#fb8c00",700:"#f57c00",800:"#ef6c00",900:"#e65100",A100:"#ffd180",A200:"#ffab40",A400:"#ff9100",A700:"#ff6d00"},on=Rp,Op={50:"#e3f2fd",100:"#bbdefb",200:"#90caf9",300:"#64b5f6",400:"#42a5f5",500:"#2196f3",600:"#1e88e5",700:"#1976d2",800:"#1565c0",900:"#0d47a1",A100:"#82b1ff",A200:"#448aff",A400:"#2979ff",A700:"#2962ff"},_t=Op,_p={50:"#e1f5fe",100:"#b3e5fc",200:"#81d4fa",300:"#4fc3f7",400:"#29b6f6",500:"#03a9f4",600:"#039be5",700:"#0288d1",800:"#0277bd",900:"#01579b",A100:"#80d8ff",A200:"#40c4ff",A400:"#00b0ff",A700:"#0091ea"},Pt=_p,Pp={50:"#e8f5e9",100:"#c8e6c9",200:"#a5d6a7",300:"#81c784",400:"#66bb6a",500:"#4caf50",600:"#43a047",700:"#388e3c",800:"#2e7d32",900:"#1b5e20",A100:"#b9f6ca",A200:"#69f0ae",A400:"#00e676",A700:"#00c853"},It=Pp,Ip=["mode","contrastThreshold","tonalOffset"],Ia={text:{primary:"rgba(0, 0, 0, 0.87)",secondary:"rgba(0, 0, 0, 0.6)",disabled:"rgba(0, 0, 0, 0.38)"},divider:"rgba(0, 0, 0, 0.12)",background:{paper:yn.white,default:yn.white},action:{active:"rgba(0, 0, 0, 0.54)",hover:"rgba(0, 0, 0, 0.04)",hoverOpacity:.04,selected:"rgba(0, 0, 0, 0.08)",selectedOpacity:.08,disabled:"rgba(0, 0, 0, 0.26)",disabledBackground:"rgba(0, 0, 0, 0.12)",disabledOpacity:.38,focus:"rgba(0, 0, 0, 0.12)",focusOpacity:.12,activatedOpacity:.12}},zr={text:{primary:yn.white,secondary:"rgba(255, 255, 255, 0.7)",disabled:"rgba(255, 255, 255, 0.5)",icon:"rgba(255, 255, 255, 0.5)"},divider:"rgba(255, 255, 255, 0.12)",background:{paper:"#121212",default:"#121212"},action:{active:yn.white,hover:"rgba(255, 255, 255, 0.08)",hoverOpacity:.08,selected:"rgba(255, 255, 255, 0.16)",selectedOpacity:.16,disabled:"rgba(255, 255, 255, 0.3)",disabledBackground:"rgba(255, 255, 255, 0.12)",disabledOpacity:.38,focus:"rgba(255, 255, 255, 0.12)",focusOpacity:.12,activatedOpacity:.24}};function Ma(e,t,n,r){const o=r.light||r,s=r.dark||r*1.5;e[t]||(e.hasOwnProperty(n)?e[t]=e[n]:t==="light"?e.light=Np(e.main,o):t==="dark"&&(e.dark=yp(e.main,s)))}function Mp(e="light"){return e==="dark"?{main:_t[200],light:_t[50],dark:_t[400]}:{main:_t[700],light:_t[400],dark:_t[800]}}function $p(e="light"){return e==="dark"?{main:Rt[200],light:Rt[50],dark:Rt[400]}:{main:Rt[500],light:Rt[300],dark:Rt[700]}}function Dp(e="light"){return e==="dark"?{main:Ot[500],light:Ot[300],dark:Ot[700]}:{main:Ot[700],light:Ot[400],dark:Ot[800]}}function Ap(e="light"){return e==="dark"?{main:Pt[400],light:Pt[300],dark:Pt[700]}:{main:Pt[700],light:Pt[500],dark:Pt[900]}}function Bp(e="light"){return e==="dark"?{main:It[400],light:It[300],dark:It[700]}:{main:It[800],light:It[500],dark:It[900]}}function Vp(e="light"){return e==="dark"?{main:on[400],light:on[300],dark:on[700]}:{main:"#ed6c02",light:on[500],dark:on[900]}}function zp(e){const{mode:t="light",contrastThreshold:n=3,tonalOffset:r=.2}=e,o=Ne(e,Ip),s=e.primary||Mp(t),i=e.secondary||$p(t),l=e.error||Dp(t),c=e.info||Ap(t),d=e.success||Bp(t),u=e.warning||Vp(t);function h(f){const m=Pa(f,zr.text.primary)>=n?zr.text.primary:Ia.text.primary;if(process.env.NODE_ENV!=="production"){const S=Pa(f,m);S<3&&console.error([`MUI: The contrast ratio of ${S}:1 for ${m} on ${f}`,"falls below the WCAG recommended absolute minimum contrast ratio of 3:1.","https://www.w3.org/TR/2008/REC-WCAG20-20081211/#visual-audio-contrast-contrast"].join(` +The following color spaces are supported: srgb, display-p3, a98-rgb, prophoto-rgb, rec-2020.`:zt(10,o))}else r=r.split(",");return r=r.map(s=>parseFloat(s)),{type:n,values:r,colorSpace:o}}function xr(e){const{type:t,colorSpace:n}=e;let{values:r}=e;return t.indexOf("rgb")!==-1?r=r.map((o,s)=>s<3?parseInt(o,10):o):t.indexOf("hsl")!==-1&&(r[1]=`${r[1]}%`,r[2]=`${r[2]}%`),t.indexOf("color")!==-1?r=`${n} ${r.join(" ")}`:r=`${r.join(", ")}`,`${t}(${r})`}function xp(e){e=Nt(e);const{values:t}=e,n=t[0],r=t[1]/100,o=t[2]/100,s=r*Math.min(o,1-o),i=(d,u=(d+n/30)%12)=>o-s*Math.max(Math.min(u-3,9-u,1),-1);let l="rgb";const c=[Math.round(i(0)*255),Math.round(i(8)*255),Math.round(i(4)*255)];return e.type==="hsla"&&(l+="a",c.push(t[3])),xr({type:l,values:c})}function Ia(e){e=Nt(e);let t=e.type==="hsl"||e.type==="hsla"?Nt(xp(e)).values:e.values;return t=t.map(n=>(e.type!=="color"&&(n/=255),n<=.03928?n/12.92:((n+.055)/1.055)**2.4)),Number((.2126*t[0]+.7152*t[1]+.0722*t[2]).toFixed(3))}function Ma(e,t){const n=Ia(e),r=Ia(t);return(Math.max(n,r)+.05)/(Math.min(n,r)+.05)}function yi(e,t){return e=Nt(e),t=Mo(t),(e.type==="rgb"||e.type==="hsl")&&(e.type+="a"),e.type==="color"?e.values[3]=`/${t}`:e.values[3]=t,xr(e)}function yp(e,t){if(e=Nt(e),t=Mo(t),e.type.indexOf("hsl")!==-1)e.values[2]*=1-t;else if(e.type.indexOf("rgb")!==-1||e.type.indexOf("color")!==-1)for(let n=0;n<3;n+=1)e.values[n]*=1-t;return xr(e)}function Np(e,t){if(e=Nt(e),t=Mo(t),e.type.indexOf("hsl")!==-1)e.values[2]+=(100-e.values[2])*t;else if(e.type.indexOf("rgb")!==-1)for(let n=0;n<3;n+=1)e.values[n]+=(255-e.values[n])*t;else if(e.type.indexOf("color")!==-1)for(let n=0;n<3;n+=1)e.values[n]+=(1-e.values[n])*t;return xr(e)}function kp(e,t){return O({toolbar:{minHeight:56,[e.up("xs")]:{"@media (orientation: landscape)":{minHeight:48}},[e.up("sm")]:{minHeight:64}}},t)}const Sp={black:"#000",white:"#fff"},yn=Sp,Ep={50:"#fafafa",100:"#f5f5f5",200:"#eeeeee",300:"#e0e0e0",400:"#bdbdbd",500:"#9e9e9e",600:"#757575",700:"#616161",800:"#424242",900:"#212121",A100:"#f5f5f5",A200:"#eeeeee",A400:"#bdbdbd",A700:"#616161"},jp=Ep,Cp={50:"#f3e5f5",100:"#e1bee7",200:"#ce93d8",300:"#ba68c8",400:"#ab47bc",500:"#9c27b0",600:"#8e24aa",700:"#7b1fa2",800:"#6a1b9a",900:"#4a148c",A100:"#ea80fc",A200:"#e040fb",A400:"#d500f9",A700:"#aa00ff"},Rt=Cp,Tp={50:"#ffebee",100:"#ffcdd2",200:"#ef9a9a",300:"#e57373",400:"#ef5350",500:"#f44336",600:"#e53935",700:"#d32f2f",800:"#c62828",900:"#b71c1c",A100:"#ff8a80",A200:"#ff5252",A400:"#ff1744",A700:"#d50000"},Ot=Tp,Rp={50:"#fff3e0",100:"#ffe0b2",200:"#ffcc80",300:"#ffb74d",400:"#ffa726",500:"#ff9800",600:"#fb8c00",700:"#f57c00",800:"#ef6c00",900:"#e65100",A100:"#ffd180",A200:"#ffab40",A400:"#ff9100",A700:"#ff6d00"},on=Rp,Op={50:"#e3f2fd",100:"#bbdefb",200:"#90caf9",300:"#64b5f6",400:"#42a5f5",500:"#2196f3",600:"#1e88e5",700:"#1976d2",800:"#1565c0",900:"#0d47a1",A100:"#82b1ff",A200:"#448aff",A400:"#2979ff",A700:"#2962ff"},_t=Op,_p={50:"#e1f5fe",100:"#b3e5fc",200:"#81d4fa",300:"#4fc3f7",400:"#29b6f6",500:"#03a9f4",600:"#039be5",700:"#0288d1",800:"#0277bd",900:"#01579b",A100:"#80d8ff",A200:"#40c4ff",A400:"#00b0ff",A700:"#0091ea"},Pt=_p,Pp={50:"#e8f5e9",100:"#c8e6c9",200:"#a5d6a7",300:"#81c784",400:"#66bb6a",500:"#4caf50",600:"#43a047",700:"#388e3c",800:"#2e7d32",900:"#1b5e20",A100:"#b9f6ca",A200:"#69f0ae",A400:"#00e676",A700:"#00c853"},It=Pp,Ip=["mode","contrastThreshold","tonalOffset"],$a={text:{primary:"rgba(0, 0, 0, 0.87)",secondary:"rgba(0, 0, 0, 0.6)",disabled:"rgba(0, 0, 0, 0.38)"},divider:"rgba(0, 0, 0, 0.12)",background:{paper:yn.white,default:yn.white},action:{active:"rgba(0, 0, 0, 0.54)",hover:"rgba(0, 0, 0, 0.04)",hoverOpacity:.04,selected:"rgba(0, 0, 0, 0.08)",selectedOpacity:.08,disabled:"rgba(0, 0, 0, 0.26)",disabledBackground:"rgba(0, 0, 0, 0.12)",disabledOpacity:.38,focus:"rgba(0, 0, 0, 0.12)",focusOpacity:.12,activatedOpacity:.12}},zr={text:{primary:yn.white,secondary:"rgba(255, 255, 255, 0.7)",disabled:"rgba(255, 255, 255, 0.5)",icon:"rgba(255, 255, 255, 0.5)"},divider:"rgba(255, 255, 255, 0.12)",background:{paper:"#121212",default:"#121212"},action:{active:yn.white,hover:"rgba(255, 255, 255, 0.08)",hoverOpacity:.08,selected:"rgba(255, 255, 255, 0.16)",selectedOpacity:.16,disabled:"rgba(255, 255, 255, 0.3)",disabledBackground:"rgba(255, 255, 255, 0.12)",disabledOpacity:.38,focus:"rgba(255, 255, 255, 0.12)",focusOpacity:.12,activatedOpacity:.24}};function Aa(e,t,n,r){const o=r.light||r,s=r.dark||r*1.5;e[t]||(e.hasOwnProperty(n)?e[t]=e[n]:t==="light"?e.light=Np(e.main,o):t==="dark"&&(e.dark=yp(e.main,s)))}function Mp(e="light"){return e==="dark"?{main:_t[200],light:_t[50],dark:_t[400]}:{main:_t[700],light:_t[400],dark:_t[800]}}function $p(e="light"){return e==="dark"?{main:Rt[200],light:Rt[50],dark:Rt[400]}:{main:Rt[500],light:Rt[300],dark:Rt[700]}}function Ap(e="light"){return e==="dark"?{main:Ot[500],light:Ot[300],dark:Ot[700]}:{main:Ot[700],light:Ot[400],dark:Ot[800]}}function Dp(e="light"){return e==="dark"?{main:Pt[400],light:Pt[300],dark:Pt[700]}:{main:Pt[700],light:Pt[500],dark:Pt[900]}}function Bp(e="light"){return e==="dark"?{main:It[400],light:It[300],dark:It[700]}:{main:It[800],light:It[500],dark:It[900]}}function Vp(e="light"){return e==="dark"?{main:on[400],light:on[300],dark:on[700]}:{main:"#ed6c02",light:on[500],dark:on[900]}}function zp(e){const{mode:t="light",contrastThreshold:n=3,tonalOffset:r=.2}=e,o=Ne(e,Ip),s=e.primary||Mp(t),i=e.secondary||$p(t),l=e.error||Ap(t),c=e.info||Dp(t),d=e.success||Bp(t),u=e.warning||Vp(t);function h(f){const m=Ma(f,zr.text.primary)>=n?zr.text.primary:$a.text.primary;if(process.env.NODE_ENV!=="production"){const S=Ma(f,m);S<3&&console.error([`MUI: The contrast ratio of ${S}:1 for ${m} on ${f}`,"falls below the WCAG recommended absolute minimum contrast ratio of 3:1.","https://www.w3.org/TR/2008/REC-WCAG20-20081211/#visual-audio-contrast-contrast"].join(` `))}return m}const w=({color:f,name:m,mainShade:S=500,lightShade:R=300,darkShade:j=700})=>{if(f=O({},f),!f.main&&f[S]&&(f.main=f[S]),!f.hasOwnProperty("main"))throw new Error(process.env.NODE_ENV!=="production"?`MUI: The color${m?` (${m})`:""} provided to augmentColor(color) is invalid. The color object needs to have a \`main\` property or a \`${S}\` property.`:zt(11,m?` (${m})`:"",S));if(typeof f.main!="string")throw new Error(process.env.NODE_ENV!=="production"?`MUI: The color${m?` (${m})`:""} provided to augmentColor(color) is invalid. \`color.main\` should be a string, but \`${JSON.stringify(f.main)}\` was provided instead. @@ -55,16 +55,16 @@ const theme1 = createTheme({ palette: { const theme2 = createTheme({ palette: { primary: { main: green[500] }, -} });`:zt(12,m?` (${m})`:"",JSON.stringify(f.main)));return Ma(f,"light",R,r),Ma(f,"dark",j,r),f.contrastText||(f.contrastText=h(f.main)),f},b={dark:zr,light:Ia};return process.env.NODE_ENV!=="production"&&(b[t]||console.error(`MUI: The palette mode \`${t}\` is not supported.`)),Qe(O({common:O({},yn),mode:t,primary:w({color:s,name:"primary"}),secondary:w({color:i,name:"secondary",mainShade:"A400",lightShade:"A200",darkShade:"A700"}),error:w({color:l,name:"error"}),warning:w({color:u,name:"warning"}),info:w({color:c,name:"info"}),success:w({color:d,name:"success"}),grey:jp,contrastThreshold:n,getContrastText:h,augmentColor:w,tonalOffset:r},b[t]),o)}const Lp=["fontFamily","fontSize","fontWeightLight","fontWeightRegular","fontWeightMedium","fontWeightBold","htmlFontSize","allVariants","pxToRem"];function Fp(e){return Math.round(e*1e5)/1e5}const $a={textTransform:"uppercase"},Da='"Roboto", "Helvetica", "Arial", sans-serif';function Gp(e,t){const n=typeof t=="function"?t(e):t,{fontFamily:r=Da,fontSize:o=14,fontWeightLight:s=300,fontWeightRegular:i=400,fontWeightMedium:l=500,fontWeightBold:c=700,htmlFontSize:d=16,allVariants:u,pxToRem:h}=n,w=Ne(n,Lp);process.env.NODE_ENV!=="production"&&(typeof o!="number"&&console.error("MUI: `fontSize` is required to be a number."),typeof d!="number"&&console.error("MUI: `htmlFontSize` is required to be a number."));const b=o/14,x=h||(S=>`${S/d*b}rem`),f=(S,R,j,E,v)=>O({fontFamily:r,fontWeight:S,fontSize:x(R),lineHeight:j},r===Da?{letterSpacing:`${Fp(E/R)}em`}:{},v,u),m={h1:f(s,96,1.167,-1.5),h2:f(s,60,1.2,-.5),h3:f(i,48,1.167,0),h4:f(i,34,1.235,.25),h5:f(i,24,1.334,0),h6:f(l,20,1.6,.15),subtitle1:f(i,16,1.75,.15),subtitle2:f(l,14,1.57,.1),body1:f(i,16,1.5,.15),body2:f(i,14,1.43,.15),button:f(l,14,1.75,.4,$a),caption:f(i,12,1.66,.4),overline:f(i,12,2.66,1,$a),inherit:{fontFamily:"inherit",fontWeight:"inherit",fontSize:"inherit",lineHeight:"inherit",letterSpacing:"inherit"}};return Qe(O({htmlFontSize:d,pxToRem:x,fontFamily:r,fontSize:o,fontWeightLight:s,fontWeightRegular:i,fontWeightMedium:l,fontWeightBold:c},m),w,{clone:!1})}const Up=.2,qp=.14,Hp=.12;function we(...e){return[`${e[0]}px ${e[1]}px ${e[2]}px ${e[3]}px rgba(0,0,0,${Up})`,`${e[4]}px ${e[5]}px ${e[6]}px ${e[7]}px rgba(0,0,0,${qp})`,`${e[8]}px ${e[9]}px ${e[10]}px ${e[11]}px rgba(0,0,0,${Hp})`].join(",")}const Xp=["none",we(0,2,1,-1,0,1,1,0,0,1,3,0),we(0,3,1,-2,0,2,2,0,0,1,5,0),we(0,3,3,-2,0,3,4,0,0,1,8,0),we(0,2,4,-1,0,4,5,0,0,1,10,0),we(0,3,5,-1,0,5,8,0,0,1,14,0),we(0,3,5,-1,0,6,10,0,0,1,18,0),we(0,4,5,-2,0,7,10,1,0,2,16,1),we(0,5,5,-3,0,8,10,1,0,3,14,2),we(0,5,6,-3,0,9,12,1,0,3,16,2),we(0,6,6,-3,0,10,14,1,0,4,18,3),we(0,6,7,-4,0,11,15,1,0,4,20,3),we(0,7,8,-4,0,12,17,2,0,5,22,4),we(0,7,8,-4,0,13,19,2,0,5,24,4),we(0,7,9,-4,0,14,21,2,0,5,26,4),we(0,8,9,-5,0,15,22,2,0,6,28,5),we(0,8,10,-5,0,16,24,2,0,6,30,5),we(0,8,11,-5,0,17,26,2,0,6,32,5),we(0,9,11,-5,0,18,28,2,0,7,34,6),we(0,9,12,-6,0,19,29,2,0,7,36,6),we(0,10,13,-6,0,20,31,3,0,8,38,7),we(0,10,13,-6,0,21,33,3,0,8,40,7),we(0,10,14,-6,0,22,35,3,0,8,42,7),we(0,11,14,-7,0,23,36,3,0,9,44,8),we(0,11,15,-7,0,24,38,3,0,9,46,8)],Yp=Xp,Wp=["duration","easing","delay"],Kp={easeInOut:"cubic-bezier(0.4, 0, 0.2, 1)",easeOut:"cubic-bezier(0.0, 0, 0.2, 1)",easeIn:"cubic-bezier(0.4, 0, 1, 1)",sharp:"cubic-bezier(0.4, 0, 0.6, 1)"},Jp={shortest:150,shorter:200,short:250,standard:300,complex:375,enteringScreen:225,leavingScreen:195};function Aa(e){return`${Math.round(e)}ms`}function Zp(e){if(!e)return 0;const t=e/36;return Math.round((4+15*t**.25+t/5)*10)}function Qp(e){const t=O({},Kp,e.easing),n=O({},Jp,e.duration);return O({getAutoHeightDuration:Zp,create:(o=["all"],s={})=>{const{duration:i=n.standard,easing:l=t.easeInOut,delay:c=0}=s,d=Ne(s,Wp);if(process.env.NODE_ENV!=="production"){const u=w=>typeof w=="string",h=w=>!isNaN(parseFloat(w));!u(o)&&!Array.isArray(o)&&console.error('MUI: Argument "props" must be a string or Array.'),!h(i)&&!u(i)&&console.error(`MUI: Argument "duration" must be a number or a string but found ${i}.`),u(l)||console.error('MUI: Argument "easing" must be a string.'),!h(c)&&!u(c)&&console.error('MUI: Argument "delay" must be a number or a string.'),typeof s!="object"&&console.error(["MUI: Secong argument of transition.create must be an object.","Arguments should be either `create('prop1', options)` or `create(['prop1', 'prop2'], options)`"].join(` -`)),Object.keys(d).length!==0&&console.error(`MUI: Unrecognized argument(s) [${Object.keys(d).join(",")}].`)}return(Array.isArray(o)?o:[o]).map(u=>`${u} ${typeof i=="string"?i:Aa(i)} ${l} ${typeof c=="string"?c:Aa(c)}`).join(",")}},e,{easing:t,duration:n})}const ew={mobileStepper:1e3,fab:1050,speedDial:1050,appBar:1100,drawer:1200,modal:1300,snackbar:1400,tooltip:1500},tw=ew,nw=["breakpoints","mixins","spacing","palette","transitions","typography","shape"];function rw(e={},...t){const{mixins:n={},palette:r={},transitions:o={},typography:s={}}=e,i=Ne(e,nw);if(e.vars)throw new Error(process.env.NODE_ENV!=="production"?"MUI: `vars` is a private field used for CSS variables support.\nPlease use another name.":zt(18));const l=zp(r),c=_o(e);let d=Qe(c,{mixins:kp(c.breakpoints,n),palette:l,shadows:Yp.slice(),typography:Gp(l,s),transitions:Qp(o),zIndex:O({},tw)});if(d=Qe(d,i),d=t.reduce((u,h)=>Qe(u,h),d),process.env.NODE_ENV!=="production"){const u=["active","checked","completed","disabled","error","expanded","focused","focusVisible","required","selected"],h=(w,b)=>{let x;for(x in w){const f=w[x];if(u.indexOf(x)!==-1&&Object.keys(f).length>0){if(process.env.NODE_ENV!=="production"){const m=ur("",x);console.error([`MUI: The \`${b}\` component increases the CSS specificity of the \`${x}\` internal state.`,"You can not override it like this: ",JSON.stringify(w,null,2),"",`Instead, you need to use the '&.${m}' syntax:`,JSON.stringify({root:{[`&.${m}`]:f}},null,2),"","https://mui.com/r/state-classes-guide"].join(` -`))}w[x]={}}}};Object.keys(d.components).forEach(w=>{const b=d.components[w].styleOverrides;b&&w.indexOf("Mui")===0&&h(b,w)})}return d.unstable_sxConfig=O({},Ro,i==null?void 0:i.unstable_sxConfig),d.unstable_sx=function(h){return Oo({sx:h,theme:this})},d}const ow=rw(),Io=ow,Mo="$$material";function $o({props:e,name:t}){return bp({props:e,name:t,defaultTheme:Io,themeId:Mo})}const aw=e=>qn(e)&&e!=="classes",sw=hp({themeId:Mo,defaultTheme:Io,rootShouldForwardProp:aw}),In=sw;function iw(e){return ur("MuiSvgIcon",e)}mi("MuiSvgIcon",["root","colorPrimary","colorSecondary","colorAction","colorError","colorDisabled","fontSizeInherit","fontSizeSmall","fontSizeMedium","fontSizeLarge"]);const lw=["children","className","color","component","fontSize","htmlColor","inheritViewBox","titleAccess","viewBox"],cw=e=>{const{color:t,fontSize:n,classes:r}=e,o={root:["root",t!=="inherit"&&`color${Ye(t)}`,`fontSize${Ye(n)}`]};return jo(o,iw,r)},dw=In("svg",{name:"MuiSvgIcon",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.root,n.color!=="inherit"&&t[`color${Ye(n.color)}`],t[`fontSize${Ye(n.fontSize)}`]]}})(({theme:e,ownerState:t})=>{var n,r,o,s,i,l,c,d,u,h,w,b,x;return{userSelect:"none",width:"1em",height:"1em",display:"inline-block",fill:t.hasSvgAsChild?void 0:"currentColor",flexShrink:0,transition:(n=e.transitions)==null||(r=n.create)==null?void 0:r.call(n,"fill",{duration:(o=e.transitions)==null||(o=o.duration)==null?void 0:o.shorter}),fontSize:{inherit:"inherit",small:((s=e.typography)==null||(i=s.pxToRem)==null?void 0:i.call(s,20))||"1.25rem",medium:((l=e.typography)==null||(c=l.pxToRem)==null?void 0:c.call(l,24))||"1.5rem",large:((d=e.typography)==null||(u=d.pxToRem)==null?void 0:u.call(d,35))||"2.1875rem"}[t.fontSize],color:(h=(w=(e.vars||e).palette)==null||(w=w[t.color])==null?void 0:w.main)!=null?h:{action:(b=(e.vars||e).palette)==null||(b=b.action)==null?void 0:b.active,disabled:(x=(e.vars||e).palette)==null||(x=x.action)==null?void 0:x.disabled,inherit:void 0}[t.color]}}),Do=M.forwardRef(function(t,n){const r=$o({props:t,name:"MuiSvgIcon"}),{children:o,className:s,color:i="inherit",component:l="svg",fontSize:c="medium",htmlColor:d,inheritViewBox:u=!1,titleAccess:h,viewBox:w="0 0 24 24"}=r,b=Ne(r,lw),x=M.isValidElement(o)&&o.type==="svg",f=O({},r,{color:i,component:l,fontSize:c,instanceFontSize:t.fontSize,inheritViewBox:u,viewBox:w,hasSvgAsChild:x}),m={};u||(m.viewBox=w);const S=cw(f);return a.jsxs(dw,O({as:l,className:ot(S.root,s),focusable:"false",color:d,"aria-hidden":h?void 0:!0,role:h?"img":void 0,ref:n},m,b,x&&o.props,{ownerState:f,children:[x?o.props.children:o,h?a.jsx("title",{children:h}):null]}))});process.env.NODE_ENV!=="production"&&(Do.propTypes={children:p.node,classes:p.object,className:p.string,color:p.oneOfType([p.oneOf(["inherit","action","disabled","primary","secondary","error","info","success","warning"]),p.string]),component:p.elementType,fontSize:p.oneOfType([p.oneOf(["inherit","large","medium","small"]),p.string]),htmlColor:p.string,inheritViewBox:p.bool,shapeRendering:p.string,sx:p.oneOfType([p.arrayOf(p.oneOfType([p.func,p.object,p.bool])),p.func,p.object]),titleAccess:p.string,viewBox:p.string});Do.muiName="SvgIcon";const Ba=Do;function Ni(e,t){function n(r,o){return a.jsx(Ba,O({"data-testid":`${t}Icon`,ref:o},r,{children:e}))}return process.env.NODE_ENV!=="production"&&(n.displayName=`${t}Icon`),n.muiName=Ba.muiName,M.memo(M.forwardRef(n))}const uw={configure:e=>{process.env.NODE_ENV!=="production"&&console.warn(["MUI: `ClassNameGenerator` import from `@mui/material/utils` is outdated and might cause unexpected issues.","","You should use `import { unstable_ClassNameGenerator } from '@mui/material/className'` instead","","The detail of the issue: https://github.com/mui/material-ui/issues/30011#issuecomment-1024993401","","The updated documentation: https://mui.com/guides/classname-generator/"].join(` -`)),wi.configure(e)}},pw=Object.freeze(Object.defineProperty({__proto__:null,capitalize:Ye,createChainedFunction:Ld,createSvgIcon:Ni,debounce:Fd,deprecatedPropType:Gd,isMuiElement:Ud,ownerDocument:Kn,ownerWindow:qd,requirePropFactory:Hd,setRef:Jn,unstable_ClassNameGenerator:uw,unstable_useEnhancedEffect:Lt,unstable_useId:ci,unsupportedProp:Wd,useControlled:di,useEventCallback:Zr,useForkRef:yt,useIsFocusVisible:ui},Symbol.toStringTag,{value:"Module"})),ww=yd(pw);var Va;function fw(){return Va||(Va=1,function(e){"use client";Object.defineProperty(e,"__esModule",{value:!0}),Object.defineProperty(e,"default",{enumerable:!0,get:function(){return t.createSvgIcon}});var t=ww}(Pr)),Pr}var mw=Nd;Object.defineProperty(ko,"__esModule",{value:!0});var ki=ko.default=void 0,hw=mw(fw()),gw=a;ki=ko.default=(0,hw.default)((0,gw.jsx)("path",{d:"m10 17 5-5-5-5z"}),"ArrowRight");function bw(e){return typeof e=="string"}function un(e,t,n){return e===void 0||bw(e)?t:O({},t,{ownerState:O({},t.ownerState,n)})}const vw={disableDefaultClasses:!1},xw=M.createContext(vw);function yw(e){const{disableDefaultClasses:t}=M.useContext(xw);return n=>t?"":e(n)}function Nw(e,t=[]){if(e===void 0)return{};const n={};return Object.keys(e).filter(r=>r.match(/^on[A-Z]/)&&typeof e[r]=="function"&&!t.includes(r)).forEach(r=>{n[r]=e[r]}),n}function kw(e,t,n){return typeof e=="function"?e(t,n):e}function za(e){if(e===void 0)return{};const t={};return Object.keys(e).filter(n=>!(n.match(/^on[A-Z]/)&&typeof e[n]=="function")).forEach(n=>{t[n]=e[n]}),t}function Sw(e){const{getSlotProps:t,additionalProps:n,externalSlotProps:r,externalForwardedProps:o,className:s}=e;if(!t){const b=ot(n==null?void 0:n.className,s,o==null?void 0:o.className,r==null?void 0:r.className),x=O({},n==null?void 0:n.style,o==null?void 0:o.style,r==null?void 0:r.style),f=O({},n,o,r);return b.length>0&&(f.className=b),Object.keys(x).length>0&&(f.style=x),{props:f,internalRef:void 0}}const i=Nw(O({},o,r)),l=za(r),c=za(o),d=t(i),u=ot(d==null?void 0:d.className,n==null?void 0:n.className,s,o==null?void 0:o.className,r==null?void 0:r.className),h=O({},d==null?void 0:d.style,n==null?void 0:n.style,o==null?void 0:o.style,r==null?void 0:r.style),w=O({},d,n,c,l);return u.length>0&&(w.className=u),Object.keys(h).length>0&&(w.style=h),{props:w,internalRef:d.ref}}const Ew=["elementType","externalSlotProps","ownerState","skipResolvingSlotProps"];function jw(e){var t;const{elementType:n,externalSlotProps:r,ownerState:o,skipResolvingSlotProps:s=!1}=e,i=Ne(e,Ew),l=s?{}:kw(r,o),{props:c,internalRef:d}=Sw(O({},i,{externalSlotProps:l})),u=yt(d,l==null?void 0:l.ref,(t=e.additionalProps)==null?void 0:t.ref);return un(n,O({},c,{ref:u}),o)}const Si="base";function Cw(e){return`${Si}--${e}`}function Tw(e,t){return`${Si}-${e}-${t}`}function Ei(e,t){const n=fi[t];return n?Cw(n):Tw(e,t)}function Rw(e,t){const n={};return t.forEach(r=>{n[r]=Ei(e,r)}),n}function Ow(e){return typeof e=="function"?e():e}const Qn=M.forwardRef(function(t,n){const{children:r,container:o,disablePortal:s=!1}=t,[i,l]=M.useState(null),c=yt(M.isValidElement(r)?r.ref:null,n);if(Lt(()=>{s||l(Ow(o)||document.body)},[o,s]),Lt(()=>{if(i&&!s)return Jn(n,i),()=>{Jn(n,null)}},[n,i,s]),s){if(M.isValidElement(r)){const d={ref:c};return M.cloneElement(r,d)}return a.jsx(M.Fragment,{children:r})}return a.jsx(M.Fragment,{children:i&&Ol.createPortal(r,i)})});process.env.NODE_ENV!=="production"&&(Qn.propTypes={children:p.node,container:p.oneOfType([xn,p.func]),disablePortal:p.bool});process.env.NODE_ENV!=="production"&&(Qn["propTypes"]=Md(Qn.propTypes));var Te="top",ze="bottom",Le="right",Re="left",Ao="auto",Mn=[Te,ze,Le,Re],Ft="start",Nn="end",_w="clippingParents",ji="viewport",an="popper",Pw="reference",La=Mn.reduce(function(e,t){return e.concat([t+"-"+Ft,t+"-"+Nn])},[]),Ci=[].concat(Mn,[Ao]).reduce(function(e,t){return e.concat([t,t+"-"+Ft,t+"-"+Nn])},[]),Iw="beforeRead",Mw="read",$w="afterRead",Dw="beforeMain",Aw="main",Bw="afterMain",Vw="beforeWrite",zw="write",Lw="afterWrite",Fw=[Iw,Mw,$w,Dw,Aw,Bw,Vw,zw,Lw];function We(e){return e?(e.nodeName||"").toLowerCase():null}function $e(e){if(e==null)return window;if(e.toString()!=="[object Window]"){var t=e.ownerDocument;return t&&t.defaultView||window}return e}function kt(e){var t=$e(e).Element;return e instanceof t||e instanceof Element}function Ve(e){var t=$e(e).HTMLElement;return e instanceof t||e instanceof HTMLElement}function Bo(e){if(typeof ShadowRoot>"u")return!1;var t=$e(e).ShadowRoot;return e instanceof t||e instanceof ShadowRoot}function Gw(e){var t=e.state;Object.keys(t.elements).forEach(function(n){var r=t.styles[n]||{},o=t.attributes[n]||{},s=t.elements[n];!Ve(s)||!We(s)||(Object.assign(s.style,r),Object.keys(o).forEach(function(i){var l=o[i];l===!1?s.removeAttribute(i):s.setAttribute(i,l===!0?"":l)}))})}function Uw(e){var t=e.state,n={popper:{position:t.options.strategy,left:"0",top:"0",margin:"0"},arrow:{position:"absolute"},reference:{}};return Object.assign(t.elements.popper.style,n.popper),t.styles=n,t.elements.arrow&&Object.assign(t.elements.arrow.style,n.arrow),function(){Object.keys(t.elements).forEach(function(r){var o=t.elements[r],s=t.attributes[r]||{},i=Object.keys(t.styles.hasOwnProperty(r)?t.styles[r]:n[r]),l=i.reduce(function(c,d){return c[d]="",c},{});!Ve(o)||!We(o)||(Object.assign(o.style,l),Object.keys(s).forEach(function(c){o.removeAttribute(c)}))})}}const qw={name:"applyStyles",enabled:!0,phase:"write",fn:Gw,effect:Uw,requires:["computeStyles"]};function Xe(e){return e.split("-")[0]}var ht=Math.max,er=Math.min,Gt=Math.round;function eo(){var e=navigator.userAgentData;return e!=null&&e.brands&&Array.isArray(e.brands)?e.brands.map(function(t){return t.brand+"/"+t.version}).join(" "):navigator.userAgent}function Ti(){return!/^((?!chrome|android).)*safari/i.test(eo())}function Ut(e,t,n){t===void 0&&(t=!1),n===void 0&&(n=!1);var r=e.getBoundingClientRect(),o=1,s=1;t&&Ve(e)&&(o=e.offsetWidth>0&&Gt(r.width)/e.offsetWidth||1,s=e.offsetHeight>0&&Gt(r.height)/e.offsetHeight||1);var i=kt(e)?$e(e):window,l=i.visualViewport,c=!Ti()&&n,d=(r.left+(c&&l?l.offsetLeft:0))/o,u=(r.top+(c&&l?l.offsetTop:0))/s,h=r.width/o,w=r.height/s;return{width:h,height:w,top:u,right:d+h,bottom:u+w,left:d,x:d,y:u}}function Vo(e){var t=Ut(e),n=e.offsetWidth,r=e.offsetHeight;return Math.abs(t.width-n)<=1&&(n=t.width),Math.abs(t.height-r)<=1&&(r=t.height),{x:e.offsetLeft,y:e.offsetTop,width:n,height:r}}function Ri(e,t){var n=t.getRootNode&&t.getRootNode();if(e.contains(t))return!0;if(n&&Bo(n)){var r=t;do{if(r&&e.isSameNode(r))return!0;r=r.parentNode||r.host}while(r)}return!1}function tt(e){return $e(e).getComputedStyle(e)}function Hw(e){return["table","td","th"].indexOf(We(e))>=0}function it(e){return((kt(e)?e.ownerDocument:e.document)||window.document).documentElement}function yr(e){return We(e)==="html"?e:e.assignedSlot||e.parentNode||(Bo(e)?e.host:null)||it(e)}function Fa(e){return!Ve(e)||tt(e).position==="fixed"?null:e.offsetParent}function Xw(e){var t=/firefox/i.test(eo()),n=/Trident/i.test(eo());if(n&&Ve(e)){var r=tt(e);if(r.position==="fixed")return null}var o=yr(e);for(Bo(o)&&(o=o.host);Ve(o)&&["html","body"].indexOf(We(o))<0;){var s=tt(o);if(s.transform!=="none"||s.perspective!=="none"||s.contain==="paint"||["transform","perspective"].indexOf(s.willChange)!==-1||t&&s.willChange==="filter"||t&&s.filter&&s.filter!=="none")return o;o=o.parentNode}return null}function $n(e){for(var t=$e(e),n=Fa(e);n&&Hw(n)&&tt(n).position==="static";)n=Fa(n);return n&&(We(n)==="html"||We(n)==="body"&&tt(n).position==="static")?t:n||Xw(e)||t}function zo(e){return["top","bottom"].indexOf(e)>=0?"x":"y"}function hn(e,t,n){return ht(e,er(t,n))}function Yw(e,t,n){var r=hn(e,t,n);return r>n?n:r}function Oi(){return{top:0,right:0,bottom:0,left:0}}function _i(e){return Object.assign({},Oi(),e)}function Pi(e,t){return t.reduce(function(n,r){return n[r]=e,n},{})}var Ww=function(t,n){return t=typeof t=="function"?t(Object.assign({},n.rects,{placement:n.placement})):t,_i(typeof t!="number"?t:Pi(t,Mn))};function Kw(e){var t,n=e.state,r=e.name,o=e.options,s=n.elements.arrow,i=n.modifiersData.popperOffsets,l=Xe(n.placement),c=zo(l),d=[Re,Le].indexOf(l)>=0,u=d?"height":"width";if(!(!s||!i)){var h=Ww(o.padding,n),w=Vo(s),b=c==="y"?Te:Re,x=c==="y"?ze:Le,f=n.rects.reference[u]+n.rects.reference[c]-i[c]-n.rects.popper[u],m=i[c]-n.rects.reference[c],S=$n(s),R=S?c==="y"?S.clientHeight||0:S.clientWidth||0:0,j=f/2-m/2,E=h[b],v=R-w[u]-h[x],P=R/2-w[u]/2+j,V=hn(E,P,v),U=c;n.modifiersData[r]=(t={},t[U]=V,t.centerOffset=V-P,t)}}function Jw(e){var t=e.state,n=e.options,r=n.element,o=r===void 0?"[data-popper-arrow]":r;o!=null&&(typeof o=="string"&&(o=t.elements.popper.querySelector(o),!o)||Ri(t.elements.popper,o)&&(t.elements.arrow=o))}const Zw={name:"arrow",enabled:!0,phase:"main",fn:Kw,effect:Jw,requires:["popperOffsets"],requiresIfExists:["preventOverflow"]};function qt(e){return e.split("-")[1]}var Qw={top:"auto",right:"auto",bottom:"auto",left:"auto"};function ef(e,t){var n=e.x,r=e.y,o=t.devicePixelRatio||1;return{x:Gt(n*o)/o||0,y:Gt(r*o)/o||0}}function Ga(e){var t,n=e.popper,r=e.popperRect,o=e.placement,s=e.variation,i=e.offsets,l=e.position,c=e.gpuAcceleration,d=e.adaptive,u=e.roundOffsets,h=e.isFixed,w=i.x,b=w===void 0?0:w,x=i.y,f=x===void 0?0:x,m=typeof u=="function"?u({x:b,y:f}):{x:b,y:f};b=m.x,f=m.y;var S=i.hasOwnProperty("x"),R=i.hasOwnProperty("y"),j=Re,E=Te,v=window;if(d){var P=$n(n),V="clientHeight",U="clientWidth";if(P===$e(n)&&(P=it(n),tt(P).position!=="static"&&l==="absolute"&&(V="scrollHeight",U="scrollWidth")),P=P,o===Te||(o===Re||o===Le)&&s===Nn){E=ze;var C=h&&P===v&&v.visualViewport?v.visualViewport.height:P[V];f-=C-r.height,f*=c?1:-1}if(o===Re||(o===Te||o===ze)&&s===Nn){j=Le;var _=h&&P===v&&v.visualViewport?v.visualViewport.width:P[U];b-=_-r.width,b*=c?1:-1}}var k=Object.assign({position:l},d&&Qw),D=u===!0?ef({x:b,y:f},$e(n)):{x:b,y:f};if(b=D.x,f=D.y,c){var $;return Object.assign({},k,($={},$[E]=R?"0":"",$[j]=S?"0":"",$.transform=(v.devicePixelRatio||1)<=1?"translate("+b+"px, "+f+"px)":"translate3d("+b+"px, "+f+"px, 0)",$))}return Object.assign({},k,(t={},t[E]=R?f+"px":"",t[j]=S?b+"px":"",t.transform="",t))}function tf(e){var t=e.state,n=e.options,r=n.gpuAcceleration,o=r===void 0?!0:r,s=n.adaptive,i=s===void 0?!0:s,l=n.roundOffsets,c=l===void 0?!0:l,d={placement:Xe(t.placement),variation:qt(t.placement),popper:t.elements.popper,popperRect:t.rects.popper,gpuAcceleration:o,isFixed:t.options.strategy==="fixed"};t.modifiersData.popperOffsets!=null&&(t.styles.popper=Object.assign({},t.styles.popper,Ga(Object.assign({},d,{offsets:t.modifiersData.popperOffsets,position:t.options.strategy,adaptive:i,roundOffsets:c})))),t.modifiersData.arrow!=null&&(t.styles.arrow=Object.assign({},t.styles.arrow,Ga(Object.assign({},d,{offsets:t.modifiersData.arrow,position:"absolute",adaptive:!1,roundOffsets:c})))),t.attributes.popper=Object.assign({},t.attributes.popper,{"data-popper-placement":t.placement})}const nf={name:"computeStyles",enabled:!0,phase:"beforeWrite",fn:tf,data:{}};var Fn={passive:!0};function rf(e){var t=e.state,n=e.instance,r=e.options,o=r.scroll,s=o===void 0?!0:o,i=r.resize,l=i===void 0?!0:i,c=$e(t.elements.popper),d=[].concat(t.scrollParents.reference,t.scrollParents.popper);return s&&d.forEach(function(u){u.addEventListener("scroll",n.update,Fn)}),l&&c.addEventListener("resize",n.update,Fn),function(){s&&d.forEach(function(u){u.removeEventListener("scroll",n.update,Fn)}),l&&c.removeEventListener("resize",n.update,Fn)}}const of={name:"eventListeners",enabled:!0,phase:"write",fn:function(){},effect:rf,data:{}};var af={left:"right",right:"left",bottom:"top",top:"bottom"};function Xn(e){return e.replace(/left|right|bottom|top/g,function(t){return af[t]})}var sf={start:"end",end:"start"};function Ua(e){return e.replace(/start|end/g,function(t){return sf[t]})}function Lo(e){var t=$e(e),n=t.pageXOffset,r=t.pageYOffset;return{scrollLeft:n,scrollTop:r}}function Fo(e){return Ut(it(e)).left+Lo(e).scrollLeft}function lf(e,t){var n=$e(e),r=it(e),o=n.visualViewport,s=r.clientWidth,i=r.clientHeight,l=0,c=0;if(o){s=o.width,i=o.height;var d=Ti();(d||!d&&t==="fixed")&&(l=o.offsetLeft,c=o.offsetTop)}return{width:s,height:i,x:l+Fo(e),y:c}}function cf(e){var t,n=it(e),r=Lo(e),o=(t=e.ownerDocument)==null?void 0:t.body,s=ht(n.scrollWidth,n.clientWidth,o?o.scrollWidth:0,o?o.clientWidth:0),i=ht(n.scrollHeight,n.clientHeight,o?o.scrollHeight:0,o?o.clientHeight:0),l=-r.scrollLeft+Fo(e),c=-r.scrollTop;return tt(o||n).direction==="rtl"&&(l+=ht(n.clientWidth,o?o.clientWidth:0)-s),{width:s,height:i,x:l,y:c}}function Go(e){var t=tt(e),n=t.overflow,r=t.overflowX,o=t.overflowY;return/auto|scroll|overlay|hidden/.test(n+o+r)}function Ii(e){return["html","body","#document"].indexOf(We(e))>=0?e.ownerDocument.body:Ve(e)&&Go(e)?e:Ii(yr(e))}function gn(e,t){var n;t===void 0&&(t=[]);var r=Ii(e),o=r===((n=e.ownerDocument)==null?void 0:n.body),s=$e(r),i=o?[s].concat(s.visualViewport||[],Go(r)?r:[]):r,l=t.concat(i);return o?l:l.concat(gn(yr(i)))}function to(e){return Object.assign({},e,{left:e.x,top:e.y,right:e.x+e.width,bottom:e.y+e.height})}function df(e,t){var n=Ut(e,!1,t==="fixed");return n.top=n.top+e.clientTop,n.left=n.left+e.clientLeft,n.bottom=n.top+e.clientHeight,n.right=n.left+e.clientWidth,n.width=e.clientWidth,n.height=e.clientHeight,n.x=n.left,n.y=n.top,n}function qa(e,t,n){return t===ji?to(lf(e,n)):kt(t)?df(t,n):to(cf(it(e)))}function uf(e){var t=gn(yr(e)),n=["absolute","fixed"].indexOf(tt(e).position)>=0,r=n&&Ve(e)?$n(e):e;return kt(r)?t.filter(function(o){return kt(o)&&Ri(o,r)&&We(o)!=="body"}):[]}function pf(e,t,n,r){var o=t==="clippingParents"?uf(e):[].concat(t),s=[].concat(o,[n]),i=s[0],l=s.reduce(function(c,d){var u=qa(e,d,r);return c.top=ht(u.top,c.top),c.right=er(u.right,c.right),c.bottom=er(u.bottom,c.bottom),c.left=ht(u.left,c.left),c},qa(e,i,r));return l.width=l.right-l.left,l.height=l.bottom-l.top,l.x=l.left,l.y=l.top,l}function Mi(e){var t=e.reference,n=e.element,r=e.placement,o=r?Xe(r):null,s=r?qt(r):null,i=t.x+t.width/2-n.width/2,l=t.y+t.height/2-n.height/2,c;switch(o){case Te:c={x:i,y:t.y-n.height};break;case ze:c={x:i,y:t.y+t.height};break;case Le:c={x:t.x+t.width,y:l};break;case Re:c={x:t.x-n.width,y:l};break;default:c={x:t.x,y:t.y}}var d=o?zo(o):null;if(d!=null){var u=d==="y"?"height":"width";switch(s){case Ft:c[d]=c[d]-(t[u]/2-n[u]/2);break;case Nn:c[d]=c[d]+(t[u]/2-n[u]/2);break}}return c}function kn(e,t){t===void 0&&(t={});var n=t,r=n.placement,o=r===void 0?e.placement:r,s=n.strategy,i=s===void 0?e.strategy:s,l=n.boundary,c=l===void 0?_w:l,d=n.rootBoundary,u=d===void 0?ji:d,h=n.elementContext,w=h===void 0?an:h,b=n.altBoundary,x=b===void 0?!1:b,f=n.padding,m=f===void 0?0:f,S=_i(typeof m!="number"?m:Pi(m,Mn)),R=w===an?Pw:an,j=e.rects.popper,E=e.elements[x?R:w],v=pf(kt(E)?E:E.contextElement||it(e.elements.popper),c,u,i),P=Ut(e.elements.reference),V=Mi({reference:P,element:j,strategy:"absolute",placement:o}),U=to(Object.assign({},j,V)),C=w===an?U:P,_={top:v.top-C.top+S.top,bottom:C.bottom-v.bottom+S.bottom,left:v.left-C.left+S.left,right:C.right-v.right+S.right},k=e.modifiersData.offset;if(w===an&&k){var D=k[o];Object.keys(_).forEach(function($){var J=[Le,ze].indexOf($)>=0?1:-1,Y=[Te,ze].indexOf($)>=0?"y":"x";_[$]+=D[Y]*J})}return _}function wf(e,t){t===void 0&&(t={});var n=t,r=n.placement,o=n.boundary,s=n.rootBoundary,i=n.padding,l=n.flipVariations,c=n.allowedAutoPlacements,d=c===void 0?Ci:c,u=qt(r),h=u?l?La:La.filter(function(x){return qt(x)===u}):Mn,w=h.filter(function(x){return d.indexOf(x)>=0});w.length===0&&(w=h);var b=w.reduce(function(x,f){return x[f]=kn(e,{placement:f,boundary:o,rootBoundary:s,padding:i})[Xe(f)],x},{});return Object.keys(b).sort(function(x,f){return b[x]-b[f]})}function ff(e){if(Xe(e)===Ao)return[];var t=Xn(e);return[Ua(e),t,Ua(t)]}function mf(e){var t=e.state,n=e.options,r=e.name;if(!t.modifiersData[r]._skip){for(var o=n.mainAxis,s=o===void 0?!0:o,i=n.altAxis,l=i===void 0?!0:i,c=n.fallbackPlacements,d=n.padding,u=n.boundary,h=n.rootBoundary,w=n.altBoundary,b=n.flipVariations,x=b===void 0?!0:b,f=n.allowedAutoPlacements,m=t.options.placement,S=Xe(m),R=S===m,j=c||(R||!x?[Xn(m)]:ff(m)),E=[m].concat(j).reduce(function(B,X){return B.concat(Xe(X)===Ao?wf(t,{placement:X,boundary:u,rootBoundary:h,padding:d,flipVariations:x,allowedAutoPlacements:f}):X)},[]),v=t.rects.reference,P=t.rects.popper,V=new Map,U=!0,C=E[0],_=0;_=0,Y=J?"width":"height",F=kn(t,{placement:k,boundary:u,rootBoundary:h,altBoundary:w,padding:d}),te=J?$?Le:Re:$?ze:Te;v[Y]>P[Y]&&(te=Xn(te));var se=Xn(te),oe=[];if(s&&oe.push(F[D]<=0),l&&oe.push(F[te]<=0,F[se]<=0),oe.every(function(B){return B})){C=k,U=!1;break}V.set(k,oe)}if(U)for(var y=x?3:1,T=function(X){var q=E.find(function(H){var G=V.get(H);if(G)return G.slice(0,X).every(function(K){return K})});if(q)return C=q,"break"},z=y;z>0;z--){var L=T(z);if(L==="break")break}t.placement!==C&&(t.modifiersData[r]._skip=!0,t.placement=C,t.reset=!0)}}const hf={name:"flip",enabled:!0,phase:"main",fn:mf,requiresIfExists:["offset"],data:{_skip:!1}};function Ha(e,t,n){return n===void 0&&(n={x:0,y:0}),{top:e.top-t.height-n.y,right:e.right-t.width+n.x,bottom:e.bottom-t.height+n.y,left:e.left-t.width-n.x}}function Xa(e){return[Te,Le,ze,Re].some(function(t){return e[t]>=0})}function gf(e){var t=e.state,n=e.name,r=t.rects.reference,o=t.rects.popper,s=t.modifiersData.preventOverflow,i=kn(t,{elementContext:"reference"}),l=kn(t,{altBoundary:!0}),c=Ha(i,r),d=Ha(l,o,s),u=Xa(c),h=Xa(d);t.modifiersData[n]={referenceClippingOffsets:c,popperEscapeOffsets:d,isReferenceHidden:u,hasPopperEscaped:h},t.attributes.popper=Object.assign({},t.attributes.popper,{"data-popper-reference-hidden":u,"data-popper-escaped":h})}const bf={name:"hide",enabled:!0,phase:"main",requiresIfExists:["preventOverflow"],fn:gf};function vf(e,t,n){var r=Xe(e),o=[Re,Te].indexOf(r)>=0?-1:1,s=typeof n=="function"?n(Object.assign({},t,{placement:e})):n,i=s[0],l=s[1];return i=i||0,l=(l||0)*o,[Re,Le].indexOf(r)>=0?{x:l,y:i}:{x:i,y:l}}function xf(e){var t=e.state,n=e.options,r=e.name,o=n.offset,s=o===void 0?[0,0]:o,i=Ci.reduce(function(u,h){return u[h]=vf(h,t.rects,s),u},{}),l=i[t.placement],c=l.x,d=l.y;t.modifiersData.popperOffsets!=null&&(t.modifiersData.popperOffsets.x+=c,t.modifiersData.popperOffsets.y+=d),t.modifiersData[r]=i}const yf={name:"offset",enabled:!0,phase:"main",requires:["popperOffsets"],fn:xf};function Nf(e){var t=e.state,n=e.name;t.modifiersData[n]=Mi({reference:t.rects.reference,element:t.rects.popper,strategy:"absolute",placement:t.placement})}const kf={name:"popperOffsets",enabled:!0,phase:"read",fn:Nf,data:{}};function Sf(e){return e==="x"?"y":"x"}function Ef(e){var t=e.state,n=e.options,r=e.name,o=n.mainAxis,s=o===void 0?!0:o,i=n.altAxis,l=i===void 0?!1:i,c=n.boundary,d=n.rootBoundary,u=n.altBoundary,h=n.padding,w=n.tether,b=w===void 0?!0:w,x=n.tetherOffset,f=x===void 0?0:x,m=kn(t,{boundary:c,rootBoundary:d,padding:h,altBoundary:u}),S=Xe(t.placement),R=qt(t.placement),j=!R,E=zo(S),v=Sf(E),P=t.modifiersData.popperOffsets,V=t.rects.reference,U=t.rects.popper,C=typeof f=="function"?f(Object.assign({},t.rects,{placement:t.placement})):f,_=typeof C=="number"?{mainAxis:C,altAxis:C}:Object.assign({mainAxis:0,altAxis:0},C),k=t.modifiersData.offset?t.modifiersData.offset[t.placement]:null,D={x:0,y:0};if(P){if(s){var $,J=E==="y"?Te:Re,Y=E==="y"?ze:Le,F=E==="y"?"height":"width",te=P[E],se=te+m[J],oe=te-m[Y],y=b?-U[F]/2:0,T=R===Ft?V[F]:U[F],z=R===Ft?-U[F]:-V[F],L=t.elements.arrow,B=b&&L?Vo(L):{width:0,height:0},X=t.modifiersData["arrow#persistent"]?t.modifiersData["arrow#persistent"].padding:Oi(),q=X[J],H=X[Y],G=hn(0,V[F],B[F]),K=j?V[F]/2-y-G-q-_.mainAxis:T-G-q-_.mainAxis,Z=j?-V[F]/2+y+G+H+_.mainAxis:z+G+H+_.mainAxis,ue=t.elements.arrow&&$n(t.elements.arrow),I=ue?E==="y"?ue.clientTop||0:ue.clientLeft||0:0,ye=($=k==null?void 0:k[E])!=null?$:0,A=te+K-ye-I,xe=te+Z-ye,Ge=hn(b?er(se,A):se,te,b?ht(oe,xe):oe);P[E]=Ge,D[E]=Ge-te}if(l){var lt,Ee=E==="x"?Te:Re,Dn=E==="x"?ze:Le,Ue=P[v],Et=v==="y"?"height":"width",ct=Ue+m[Ee],jt=Ue-m[Dn],Ct=[Te,Re].indexOf(S)!==-1,Tt=(lt=k==null?void 0:k[v])!=null?lt:0,dt=Ct?ct:Ue-V[Et]-U[Et]-Tt+_.altAxis,Jt=Ct?Ue+V[Et]+U[Et]-Tt-_.altAxis:jt,An=b&&Ct?Yw(dt,Ue,Jt):hn(b?dt:ct,Ue,b?Jt:jt);P[v]=An,D[v]=An-Ue}t.modifiersData[r]=D}}const jf={name:"preventOverflow",enabled:!0,phase:"main",fn:Ef,requiresIfExists:["offset"]};function Cf(e){return{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}}function Tf(e){return e===$e(e)||!Ve(e)?Lo(e):Cf(e)}function Rf(e){var t=e.getBoundingClientRect(),n=Gt(t.width)/e.offsetWidth||1,r=Gt(t.height)/e.offsetHeight||1;return n!==1||r!==1}function Of(e,t,n){n===void 0&&(n=!1);var r=Ve(t),o=Ve(t)&&Rf(t),s=it(t),i=Ut(e,o,n),l={scrollLeft:0,scrollTop:0},c={x:0,y:0};return(r||!r&&!n)&&((We(t)!=="body"||Go(s))&&(l=Tf(t)),Ve(t)?(c=Ut(t,!0),c.x+=t.clientLeft,c.y+=t.clientTop):s&&(c.x=Fo(s))),{x:i.left+l.scrollLeft-c.x,y:i.top+l.scrollTop-c.y,width:i.width,height:i.height}}function _f(e){var t=new Map,n=new Set,r=[];e.forEach(function(s){t.set(s.name,s)});function o(s){n.add(s.name);var i=[].concat(s.requires||[],s.requiresIfExists||[]);i.forEach(function(l){if(!n.has(l)){var c=t.get(l);c&&o(c)}}),r.push(s)}return e.forEach(function(s){n.has(s.name)||o(s)}),r}function Pf(e){var t=_f(e);return Fw.reduce(function(n,r){return n.concat(t.filter(function(o){return o.phase===r}))},[])}function If(e){var t;return function(){return t||(t=new Promise(function(n){Promise.resolve().then(function(){t=void 0,n(e())})})),t}}function Mf(e){var t=e.reduce(function(n,r){var o=n[r.name];return n[r.name]=o?Object.assign({},o,r,{options:Object.assign({},o.options,r.options),data:Object.assign({},o.data,r.data)}):r,n},{});return Object.keys(t).map(function(n){return t[n]})}var Ya={placement:"bottom",modifiers:[],strategy:"absolute"};function Wa(){for(var e=arguments.length,t=new Array(e),n=0;njo({root:["root"]},yw(Bf)),Uf={},qf=M.forwardRef(function(t,n){var r;const{anchorEl:o,children:s,direction:i,disablePortal:l,modifiers:c,open:d,placement:u,popperOptions:h,popperRef:w,slotProps:b={},slots:x={},TransitionProps:f}=t,m=Ne(t,Vf),S=M.useRef(null),R=yt(S,n),j=M.useRef(null),E=yt(j,w),v=M.useRef(E);Lt(()=>{v.current=E},[E]),M.useImperativeHandle(w,()=>j.current,[]);const P=Lf(u,i),[V,U]=M.useState(P),[C,_]=M.useState(tr(o));M.useEffect(()=>{j.current&&j.current.forceUpdate()}),M.useEffect(()=>{o&&_(tr(o))},[o]),Lt(()=>{if(!C||!d)return;const Y=se=>{U(se.placement)};if(process.env.NODE_ENV!=="production"&&C&&Nr(C)&&C.nodeType===1){const se=C.getBoundingClientRect();process.env.NODE_ENV!=="test"&&se.top===0&&se.left===0&&se.right===0&&se.bottom===0&&console.warn(["MUI: The `anchorEl` prop provided to the component is invalid.","The anchor element should be part of the document layout.","Make sure the element is present in the document or that it's not display none."].join(` -`))}let F=[{name:"preventOverflow",options:{altBoundary:l}},{name:"flip",options:{altBoundary:l}},{name:"onUpdate",enabled:!0,phase:"afterWrite",fn:({state:se})=>{Y(se)}}];c!=null&&(F=F.concat(c)),h&&h.modifiers!=null&&(F=F.concat(h.modifiers));const te=Af(C,S.current,O({placement:P},h,{modifiers:F}));return v.current(te),()=>{te.destroy(),v.current(null)}},[C,l,c,d,h,P]);const k={placement:V};f!==null&&(k.TransitionProps=f);const D=Gf(),$=(r=x.root)!=null?r:"div",J=jw({elementType:$,externalSlotProps:b.root,externalForwardedProps:m,additionalProps:{role:"tooltip",ref:R},ownerState:t,className:D.root});return a.jsx($,O({},J,{children:typeof s=="function"?s(k):s}))}),Di=M.forwardRef(function(t,n){const{anchorEl:r,children:o,container:s,direction:i="ltr",disablePortal:l=!1,keepMounted:c=!1,modifiers:d,open:u,placement:h="bottom",popperOptions:w=Uf,popperRef:b,style:x,transition:f=!1,slotProps:m={},slots:S={}}=t,R=Ne(t,zf),[j,E]=M.useState(!0),v=()=>{E(!1)},P=()=>{E(!0)};if(!c&&!u&&(!f||j))return null;let V;if(s)V=s;else if(r){const _=tr(r);V=_&&Nr(_)?Kn(_).body:Kn(null).body}const U=!u&&c&&(!f||j)?"none":void 0,C=f?{in:u,onEnter:v,onExited:P}:void 0;return a.jsx(Qn,{disablePortal:l,container:V,children:a.jsx(qf,O({anchorEl:r,direction:i,disablePortal:l,modifiers:d,ref:n,open:f?!j:u,placement:h,popperOptions:w,popperRef:b,slotProps:m,slots:S},R,{style:O({position:"fixed",top:0,left:0,display:U},x),TransitionProps:C,children:o}))})});process.env.NODE_ENV!=="production"&&(Di.propTypes={anchorEl:So(p.oneOfType([xn,p.object,p.func]),e=>{if(e.open){const t=tr(e.anchorEl);if(t&&Nr(t)&&t.nodeType===1){const n=t.getBoundingClientRect();if(process.env.NODE_ENV!=="test"&&n.top===0&&n.left===0&&n.right===0&&n.bottom===0)return new Error(["MUI: The `anchorEl` prop provided to the component is invalid.","The anchor element should be part of the document layout.","Make sure the element is present in the document or that it's not display none."].join(` +} });`:zt(12,m?` (${m})`:"",JSON.stringify(f.main)));return Aa(f,"light",R,r),Aa(f,"dark",j,r),f.contrastText||(f.contrastText=h(f.main)),f},b={dark:zr,light:$a};return process.env.NODE_ENV!=="production"&&(b[t]||console.error(`MUI: The palette mode \`${t}\` is not supported.`)),Qe(O({common:O({},yn),mode:t,primary:w({color:s,name:"primary"}),secondary:w({color:i,name:"secondary",mainShade:"A400",lightShade:"A200",darkShade:"A700"}),error:w({color:l,name:"error"}),warning:w({color:u,name:"warning"}),info:w({color:c,name:"info"}),success:w({color:d,name:"success"}),grey:jp,contrastThreshold:n,getContrastText:h,augmentColor:w,tonalOffset:r},b[t]),o)}const Lp=["fontFamily","fontSize","fontWeightLight","fontWeightRegular","fontWeightMedium","fontWeightBold","htmlFontSize","allVariants","pxToRem"];function Fp(e){return Math.round(e*1e5)/1e5}const Da={textTransform:"uppercase"},Ba='"Roboto", "Helvetica", "Arial", sans-serif';function Gp(e,t){const n=typeof t=="function"?t(e):t,{fontFamily:r=Ba,fontSize:o=14,fontWeightLight:s=300,fontWeightRegular:i=400,fontWeightMedium:l=500,fontWeightBold:c=700,htmlFontSize:d=16,allVariants:u,pxToRem:h}=n,w=Ne(n,Lp);process.env.NODE_ENV!=="production"&&(typeof o!="number"&&console.error("MUI: `fontSize` is required to be a number."),typeof d!="number"&&console.error("MUI: `htmlFontSize` is required to be a number."));const b=o/14,x=h||(S=>`${S/d*b}rem`),f=(S,R,j,E,v)=>O({fontFamily:r,fontWeight:S,fontSize:x(R),lineHeight:j},r===Ba?{letterSpacing:`${Fp(E/R)}em`}:{},v,u),m={h1:f(s,96,1.167,-1.5),h2:f(s,60,1.2,-.5),h3:f(i,48,1.167,0),h4:f(i,34,1.235,.25),h5:f(i,24,1.334,0),h6:f(l,20,1.6,.15),subtitle1:f(i,16,1.75,.15),subtitle2:f(l,14,1.57,.1),body1:f(i,16,1.5,.15),body2:f(i,14,1.43,.15),button:f(l,14,1.75,.4,Da),caption:f(i,12,1.66,.4),overline:f(i,12,2.66,1,Da),inherit:{fontFamily:"inherit",fontWeight:"inherit",fontSize:"inherit",lineHeight:"inherit",letterSpacing:"inherit"}};return Qe(O({htmlFontSize:d,pxToRem:x,fontFamily:r,fontSize:o,fontWeightLight:s,fontWeightRegular:i,fontWeightMedium:l,fontWeightBold:c},m),w,{clone:!1})}const Up=.2,qp=.14,Hp=.12;function we(...e){return[`${e[0]}px ${e[1]}px ${e[2]}px ${e[3]}px rgba(0,0,0,${Up})`,`${e[4]}px ${e[5]}px ${e[6]}px ${e[7]}px rgba(0,0,0,${qp})`,`${e[8]}px ${e[9]}px ${e[10]}px ${e[11]}px rgba(0,0,0,${Hp})`].join(",")}const Xp=["none",we(0,2,1,-1,0,1,1,0,0,1,3,0),we(0,3,1,-2,0,2,2,0,0,1,5,0),we(0,3,3,-2,0,3,4,0,0,1,8,0),we(0,2,4,-1,0,4,5,0,0,1,10,0),we(0,3,5,-1,0,5,8,0,0,1,14,0),we(0,3,5,-1,0,6,10,0,0,1,18,0),we(0,4,5,-2,0,7,10,1,0,2,16,1),we(0,5,5,-3,0,8,10,1,0,3,14,2),we(0,5,6,-3,0,9,12,1,0,3,16,2),we(0,6,6,-3,0,10,14,1,0,4,18,3),we(0,6,7,-4,0,11,15,1,0,4,20,3),we(0,7,8,-4,0,12,17,2,0,5,22,4),we(0,7,8,-4,0,13,19,2,0,5,24,4),we(0,7,9,-4,0,14,21,2,0,5,26,4),we(0,8,9,-5,0,15,22,2,0,6,28,5),we(0,8,10,-5,0,16,24,2,0,6,30,5),we(0,8,11,-5,0,17,26,2,0,6,32,5),we(0,9,11,-5,0,18,28,2,0,7,34,6),we(0,9,12,-6,0,19,29,2,0,7,36,6),we(0,10,13,-6,0,20,31,3,0,8,38,7),we(0,10,13,-6,0,21,33,3,0,8,40,7),we(0,10,14,-6,0,22,35,3,0,8,42,7),we(0,11,14,-7,0,23,36,3,0,9,44,8),we(0,11,15,-7,0,24,38,3,0,9,46,8)],Yp=Xp,Wp=["duration","easing","delay"],Kp={easeInOut:"cubic-bezier(0.4, 0, 0.2, 1)",easeOut:"cubic-bezier(0.0, 0, 0.2, 1)",easeIn:"cubic-bezier(0.4, 0, 1, 1)",sharp:"cubic-bezier(0.4, 0, 0.6, 1)"},Jp={shortest:150,shorter:200,short:250,standard:300,complex:375,enteringScreen:225,leavingScreen:195};function Va(e){return`${Math.round(e)}ms`}function Zp(e){if(!e)return 0;const t=e/36;return Math.round((4+15*t**.25+t/5)*10)}function Qp(e){const t=O({},Kp,e.easing),n=O({},Jp,e.duration);return O({getAutoHeightDuration:Zp,create:(o=["all"],s={})=>{const{duration:i=n.standard,easing:l=t.easeInOut,delay:c=0}=s,d=Ne(s,Wp);if(process.env.NODE_ENV!=="production"){const u=w=>typeof w=="string",h=w=>!isNaN(parseFloat(w));!u(o)&&!Array.isArray(o)&&console.error('MUI: Argument "props" must be a string or Array.'),!h(i)&&!u(i)&&console.error(`MUI: Argument "duration" must be a number or a string but found ${i}.`),u(l)||console.error('MUI: Argument "easing" must be a string.'),!h(c)&&!u(c)&&console.error('MUI: Argument "delay" must be a number or a string.'),typeof s!="object"&&console.error(["MUI: Secong argument of transition.create must be an object.","Arguments should be either `create('prop1', options)` or `create(['prop1', 'prop2'], options)`"].join(` +`)),Object.keys(d).length!==0&&console.error(`MUI: Unrecognized argument(s) [${Object.keys(d).join(",")}].`)}return(Array.isArray(o)?o:[o]).map(u=>`${u} ${typeof i=="string"?i:Va(i)} ${l} ${typeof c=="string"?c:Va(c)}`).join(",")}},e,{easing:t,duration:n})}const ew={mobileStepper:1e3,fab:1050,speedDial:1050,appBar:1100,drawer:1200,modal:1300,snackbar:1400,tooltip:1500},tw=ew,nw=["breakpoints","mixins","spacing","palette","transitions","typography","shape"];function rw(e={},...t){const{mixins:n={},palette:r={},transitions:o={},typography:s={}}=e,i=Ne(e,nw);if(e.vars)throw new Error(process.env.NODE_ENV!=="production"?"MUI: `vars` is a private field used for CSS variables support.\nPlease use another name.":zt(18));const l=zp(r),c=Io(e);let d=Qe(c,{mixins:kp(c.breakpoints,n),palette:l,shadows:Yp.slice(),typography:Gp(l,s),transitions:Qp(o),zIndex:O({},tw)});if(d=Qe(d,i),d=t.reduce((u,h)=>Qe(u,h),d),process.env.NODE_ENV!=="production"){const u=["active","checked","completed","disabled","error","expanded","focused","focusVisible","required","selected"],h=(w,b)=>{let x;for(x in w){const f=w[x];if(u.indexOf(x)!==-1&&Object.keys(f).length>0){if(process.env.NODE_ENV!=="production"){const m=ur("",x);console.error([`MUI: The \`${b}\` component increases the CSS specificity of the \`${x}\` internal state.`,"You can not override it like this: ",JSON.stringify(w,null,2),"",`Instead, you need to use the '&.${m}' syntax:`,JSON.stringify({root:{[`&.${m}`]:f}},null,2),"","https://mui.com/r/state-classes-guide"].join(` +`))}w[x]={}}}};Object.keys(d.components).forEach(w=>{const b=d.components[w].styleOverrides;b&&w.indexOf("Mui")===0&&h(b,w)})}return d.unstable_sxConfig=O({},_o,i==null?void 0:i.unstable_sxConfig),d.unstable_sx=function(h){return Po({sx:h,theme:this})},d}const ow=rw(),$o=ow,Ao="$$material";function Do({props:e,name:t}){return bp({props:e,name:t,defaultTheme:$o,themeId:Ao})}const aw=e=>qn(e)&&e!=="classes",sw=hp({themeId:Ao,defaultTheme:$o,rootShouldForwardProp:aw}),In=sw;function iw(e){return ur("MuiSvgIcon",e)}mi("MuiSvgIcon",["root","colorPrimary","colorSecondary","colorAction","colorError","colorDisabled","fontSizeInherit","fontSizeSmall","fontSizeMedium","fontSizeLarge"]);const lw=["children","className","color","component","fontSize","htmlColor","inheritViewBox","titleAccess","viewBox"],cw=e=>{const{color:t,fontSize:n,classes:r}=e,o={root:["root",t!=="inherit"&&`color${Ye(t)}`,`fontSize${Ye(n)}`]};return To(o,iw,r)},dw=In("svg",{name:"MuiSvgIcon",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.root,n.color!=="inherit"&&t[`color${Ye(n.color)}`],t[`fontSize${Ye(n.fontSize)}`]]}})(({theme:e,ownerState:t})=>{var n,r,o,s,i,l,c,d,u,h,w,b,x;return{userSelect:"none",width:"1em",height:"1em",display:"inline-block",fill:t.hasSvgAsChild?void 0:"currentColor",flexShrink:0,transition:(n=e.transitions)==null||(r=n.create)==null?void 0:r.call(n,"fill",{duration:(o=e.transitions)==null||(o=o.duration)==null?void 0:o.shorter}),fontSize:{inherit:"inherit",small:((s=e.typography)==null||(i=s.pxToRem)==null?void 0:i.call(s,20))||"1.25rem",medium:((l=e.typography)==null||(c=l.pxToRem)==null?void 0:c.call(l,24))||"1.5rem",large:((d=e.typography)==null||(u=d.pxToRem)==null?void 0:u.call(d,35))||"2.1875rem"}[t.fontSize],color:(h=(w=(e.vars||e).palette)==null||(w=w[t.color])==null?void 0:w.main)!=null?h:{action:(b=(e.vars||e).palette)==null||(b=b.action)==null?void 0:b.active,disabled:(x=(e.vars||e).palette)==null||(x=x.action)==null?void 0:x.disabled,inherit:void 0}[t.color]}}),Bo=M.forwardRef(function(t,n){const r=Do({props:t,name:"MuiSvgIcon"}),{children:o,className:s,color:i="inherit",component:l="svg",fontSize:c="medium",htmlColor:d,inheritViewBox:u=!1,titleAccess:h,viewBox:w="0 0 24 24"}=r,b=Ne(r,lw),x=M.isValidElement(o)&&o.type==="svg",f=O({},r,{color:i,component:l,fontSize:c,instanceFontSize:t.fontSize,inheritViewBox:u,viewBox:w,hasSvgAsChild:x}),m={};u||(m.viewBox=w);const S=cw(f);return a.jsxs(dw,O({as:l,className:ot(S.root,s),focusable:"false",color:d,"aria-hidden":h?void 0:!0,role:h?"img":void 0,ref:n},m,b,x&&o.props,{ownerState:f,children:[x?o.props.children:o,h?a.jsx("title",{children:h}):null]}))});process.env.NODE_ENV!=="production"&&(Bo.propTypes={children:p.node,classes:p.object,className:p.string,color:p.oneOfType([p.oneOf(["inherit","action","disabled","primary","secondary","error","info","success","warning"]),p.string]),component:p.elementType,fontSize:p.oneOfType([p.oneOf(["inherit","large","medium","small"]),p.string]),htmlColor:p.string,inheritViewBox:p.bool,shapeRendering:p.string,sx:p.oneOfType([p.arrayOf(p.oneOfType([p.func,p.object,p.bool])),p.func,p.object]),titleAccess:p.string,viewBox:p.string});Bo.muiName="SvgIcon";const za=Bo;function Ni(e,t){function n(r,o){return a.jsx(za,O({"data-testid":`${t}Icon`,ref:o},r,{children:e}))}return process.env.NODE_ENV!=="production"&&(n.displayName=`${t}Icon`),n.muiName=za.muiName,M.memo(M.forwardRef(n))}const uw={configure:e=>{process.env.NODE_ENV!=="production"&&console.warn(["MUI: `ClassNameGenerator` import from `@mui/material/utils` is outdated and might cause unexpected issues.","","You should use `import { unstable_ClassNameGenerator } from '@mui/material/className'` instead","","The detail of the issue: https://github.com/mui/material-ui/issues/30011#issuecomment-1024993401","","The updated documentation: https://mui.com/guides/classname-generator/"].join(` +`)),wi.configure(e)}},pw=Object.freeze(Object.defineProperty({__proto__:null,capitalize:Ye,createChainedFunction:Ld,createSvgIcon:Ni,debounce:Fd,deprecatedPropType:Gd,isMuiElement:Ud,ownerDocument:Kn,ownerWindow:qd,requirePropFactory:Hd,setRef:Jn,unstable_ClassNameGenerator:uw,unstable_useEnhancedEffect:Lt,unstable_useId:ci,unsupportedProp:Wd,useControlled:di,useEventCallback:Zr,useForkRef:yt,useIsFocusVisible:ui},Symbol.toStringTag,{value:"Module"})),ww=yd(pw);var La;function fw(){return La||(La=1,function(e){"use client";Object.defineProperty(e,"__esModule",{value:!0}),Object.defineProperty(e,"default",{enumerable:!0,get:function(){return t.createSvgIcon}});var t=ww}(Pr)),Pr}var mw=Nd;Object.defineProperty(Eo,"__esModule",{value:!0});var ki=Eo.default=void 0,hw=mw(fw()),gw=a;ki=Eo.default=(0,hw.default)((0,gw.jsx)("path",{d:"m10 17 5-5-5-5z"}),"ArrowRight");function bw(e){return typeof e=="string"}function un(e,t,n){return e===void 0||bw(e)?t:O({},t,{ownerState:O({},t.ownerState,n)})}const vw={disableDefaultClasses:!1},xw=M.createContext(vw);function yw(e){const{disableDefaultClasses:t}=M.useContext(xw);return n=>t?"":e(n)}function Nw(e,t=[]){if(e===void 0)return{};const n={};return Object.keys(e).filter(r=>r.match(/^on[A-Z]/)&&typeof e[r]=="function"&&!t.includes(r)).forEach(r=>{n[r]=e[r]}),n}function kw(e,t,n){return typeof e=="function"?e(t,n):e}function Fa(e){if(e===void 0)return{};const t={};return Object.keys(e).filter(n=>!(n.match(/^on[A-Z]/)&&typeof e[n]=="function")).forEach(n=>{t[n]=e[n]}),t}function Sw(e){const{getSlotProps:t,additionalProps:n,externalSlotProps:r,externalForwardedProps:o,className:s}=e;if(!t){const b=ot(n==null?void 0:n.className,s,o==null?void 0:o.className,r==null?void 0:r.className),x=O({},n==null?void 0:n.style,o==null?void 0:o.style,r==null?void 0:r.style),f=O({},n,o,r);return b.length>0&&(f.className=b),Object.keys(x).length>0&&(f.style=x),{props:f,internalRef:void 0}}const i=Nw(O({},o,r)),l=Fa(r),c=Fa(o),d=t(i),u=ot(d==null?void 0:d.className,n==null?void 0:n.className,s,o==null?void 0:o.className,r==null?void 0:r.className),h=O({},d==null?void 0:d.style,n==null?void 0:n.style,o==null?void 0:o.style,r==null?void 0:r.style),w=O({},d,n,c,l);return u.length>0&&(w.className=u),Object.keys(h).length>0&&(w.style=h),{props:w,internalRef:d.ref}}const Ew=["elementType","externalSlotProps","ownerState","skipResolvingSlotProps"];function jw(e){var t;const{elementType:n,externalSlotProps:r,ownerState:o,skipResolvingSlotProps:s=!1}=e,i=Ne(e,Ew),l=s?{}:kw(r,o),{props:c,internalRef:d}=Sw(O({},i,{externalSlotProps:l})),u=yt(d,l==null?void 0:l.ref,(t=e.additionalProps)==null?void 0:t.ref);return un(n,O({},c,{ref:u}),o)}const Si="base";function Cw(e){return`${Si}--${e}`}function Tw(e,t){return`${Si}-${e}-${t}`}function Ei(e,t){const n=fi[t];return n?Cw(n):Tw(e,t)}function Rw(e,t){const n={};return t.forEach(r=>{n[r]=Ei(e,r)}),n}function Ow(e){return typeof e=="function"?e():e}const Qn=M.forwardRef(function(t,n){const{children:r,container:o,disablePortal:s=!1}=t,[i,l]=M.useState(null),c=yt(M.isValidElement(r)?r.ref:null,n);if(Lt(()=>{s||l(Ow(o)||document.body)},[o,s]),Lt(()=>{if(i&&!s)return Jn(n,i),()=>{Jn(n,null)}},[n,i,s]),s){if(M.isValidElement(r)){const d={ref:c};return M.cloneElement(r,d)}return a.jsx(M.Fragment,{children:r})}return a.jsx(M.Fragment,{children:i&&Ol.createPortal(r,i)})});process.env.NODE_ENV!=="production"&&(Qn.propTypes={children:p.node,container:p.oneOfType([xn,p.func]),disablePortal:p.bool});process.env.NODE_ENV!=="production"&&(Qn["propTypes"]=Md(Qn.propTypes));var Ce="top",ze="bottom",Le="right",Te="left",Vo="auto",Mn=[Ce,ze,Le,Te],Ft="start",Nn="end",_w="clippingParents",ji="viewport",an="popper",Pw="reference",Ga=Mn.reduce(function(e,t){return e.concat([t+"-"+Ft,t+"-"+Nn])},[]),Ci=[].concat(Mn,[Vo]).reduce(function(e,t){return e.concat([t,t+"-"+Ft,t+"-"+Nn])},[]),Iw="beforeRead",Mw="read",$w="afterRead",Aw="beforeMain",Dw="main",Bw="afterMain",Vw="beforeWrite",zw="write",Lw="afterWrite",Fw=[Iw,Mw,$w,Aw,Dw,Bw,Vw,zw,Lw];function We(e){return e?(e.nodeName||"").toLowerCase():null}function $e(e){if(e==null)return window;if(e.toString()!=="[object Window]"){var t=e.ownerDocument;return t&&t.defaultView||window}return e}function kt(e){var t=$e(e).Element;return e instanceof t||e instanceof Element}function Ve(e){var t=$e(e).HTMLElement;return e instanceof t||e instanceof HTMLElement}function zo(e){if(typeof ShadowRoot>"u")return!1;var t=$e(e).ShadowRoot;return e instanceof t||e instanceof ShadowRoot}function Gw(e){var t=e.state;Object.keys(t.elements).forEach(function(n){var r=t.styles[n]||{},o=t.attributes[n]||{},s=t.elements[n];!Ve(s)||!We(s)||(Object.assign(s.style,r),Object.keys(o).forEach(function(i){var l=o[i];l===!1?s.removeAttribute(i):s.setAttribute(i,l===!0?"":l)}))})}function Uw(e){var t=e.state,n={popper:{position:t.options.strategy,left:"0",top:"0",margin:"0"},arrow:{position:"absolute"},reference:{}};return Object.assign(t.elements.popper.style,n.popper),t.styles=n,t.elements.arrow&&Object.assign(t.elements.arrow.style,n.arrow),function(){Object.keys(t.elements).forEach(function(r){var o=t.elements[r],s=t.attributes[r]||{},i=Object.keys(t.styles.hasOwnProperty(r)?t.styles[r]:n[r]),l=i.reduce(function(c,d){return c[d]="",c},{});!Ve(o)||!We(o)||(Object.assign(o.style,l),Object.keys(s).forEach(function(c){o.removeAttribute(c)}))})}}const qw={name:"applyStyles",enabled:!0,phase:"write",fn:Gw,effect:Uw,requires:["computeStyles"]};function Xe(e){return e.split("-")[0]}var ht=Math.max,er=Math.min,Gt=Math.round;function eo(){var e=navigator.userAgentData;return e!=null&&e.brands&&Array.isArray(e.brands)?e.brands.map(function(t){return t.brand+"/"+t.version}).join(" "):navigator.userAgent}function Ti(){return!/^((?!chrome|android).)*safari/i.test(eo())}function Ut(e,t,n){t===void 0&&(t=!1),n===void 0&&(n=!1);var r=e.getBoundingClientRect(),o=1,s=1;t&&Ve(e)&&(o=e.offsetWidth>0&&Gt(r.width)/e.offsetWidth||1,s=e.offsetHeight>0&&Gt(r.height)/e.offsetHeight||1);var i=kt(e)?$e(e):window,l=i.visualViewport,c=!Ti()&&n,d=(r.left+(c&&l?l.offsetLeft:0))/o,u=(r.top+(c&&l?l.offsetTop:0))/s,h=r.width/o,w=r.height/s;return{width:h,height:w,top:u,right:d+h,bottom:u+w,left:d,x:d,y:u}}function Lo(e){var t=Ut(e),n=e.offsetWidth,r=e.offsetHeight;return Math.abs(t.width-n)<=1&&(n=t.width),Math.abs(t.height-r)<=1&&(r=t.height),{x:e.offsetLeft,y:e.offsetTop,width:n,height:r}}function Ri(e,t){var n=t.getRootNode&&t.getRootNode();if(e.contains(t))return!0;if(n&&zo(n)){var r=t;do{if(r&&e.isSameNode(r))return!0;r=r.parentNode||r.host}while(r)}return!1}function tt(e){return $e(e).getComputedStyle(e)}function Hw(e){return["table","td","th"].indexOf(We(e))>=0}function it(e){return((kt(e)?e.ownerDocument:e.document)||window.document).documentElement}function yr(e){return We(e)==="html"?e:e.assignedSlot||e.parentNode||(zo(e)?e.host:null)||it(e)}function Ua(e){return!Ve(e)||tt(e).position==="fixed"?null:e.offsetParent}function Xw(e){var t=/firefox/i.test(eo()),n=/Trident/i.test(eo());if(n&&Ve(e)){var r=tt(e);if(r.position==="fixed")return null}var o=yr(e);for(zo(o)&&(o=o.host);Ve(o)&&["html","body"].indexOf(We(o))<0;){var s=tt(o);if(s.transform!=="none"||s.perspective!=="none"||s.contain==="paint"||["transform","perspective"].indexOf(s.willChange)!==-1||t&&s.willChange==="filter"||t&&s.filter&&s.filter!=="none")return o;o=o.parentNode}return null}function $n(e){for(var t=$e(e),n=Ua(e);n&&Hw(n)&&tt(n).position==="static";)n=Ua(n);return n&&(We(n)==="html"||We(n)==="body"&&tt(n).position==="static")?t:n||Xw(e)||t}function Fo(e){return["top","bottom"].indexOf(e)>=0?"x":"y"}function hn(e,t,n){return ht(e,er(t,n))}function Yw(e,t,n){var r=hn(e,t,n);return r>n?n:r}function Oi(){return{top:0,right:0,bottom:0,left:0}}function _i(e){return Object.assign({},Oi(),e)}function Pi(e,t){return t.reduce(function(n,r){return n[r]=e,n},{})}var Ww=function(t,n){return t=typeof t=="function"?t(Object.assign({},n.rects,{placement:n.placement})):t,_i(typeof t!="number"?t:Pi(t,Mn))};function Kw(e){var t,n=e.state,r=e.name,o=e.options,s=n.elements.arrow,i=n.modifiersData.popperOffsets,l=Xe(n.placement),c=Fo(l),d=[Te,Le].indexOf(l)>=0,u=d?"height":"width";if(!(!s||!i)){var h=Ww(o.padding,n),w=Lo(s),b=c==="y"?Ce:Te,x=c==="y"?ze:Le,f=n.rects.reference[u]+n.rects.reference[c]-i[c]-n.rects.popper[u],m=i[c]-n.rects.reference[c],S=$n(s),R=S?c==="y"?S.clientHeight||0:S.clientWidth||0:0,j=f/2-m/2,E=h[b],v=R-w[u]-h[x],P=R/2-w[u]/2+j,V=hn(E,P,v),U=c;n.modifiersData[r]=(t={},t[U]=V,t.centerOffset=V-P,t)}}function Jw(e){var t=e.state,n=e.options,r=n.element,o=r===void 0?"[data-popper-arrow]":r;o!=null&&(typeof o=="string"&&(o=t.elements.popper.querySelector(o),!o)||Ri(t.elements.popper,o)&&(t.elements.arrow=o))}const Zw={name:"arrow",enabled:!0,phase:"main",fn:Kw,effect:Jw,requires:["popperOffsets"],requiresIfExists:["preventOverflow"]};function qt(e){return e.split("-")[1]}var Qw={top:"auto",right:"auto",bottom:"auto",left:"auto"};function ef(e,t){var n=e.x,r=e.y,o=t.devicePixelRatio||1;return{x:Gt(n*o)/o||0,y:Gt(r*o)/o||0}}function qa(e){var t,n=e.popper,r=e.popperRect,o=e.placement,s=e.variation,i=e.offsets,l=e.position,c=e.gpuAcceleration,d=e.adaptive,u=e.roundOffsets,h=e.isFixed,w=i.x,b=w===void 0?0:w,x=i.y,f=x===void 0?0:x,m=typeof u=="function"?u({x:b,y:f}):{x:b,y:f};b=m.x,f=m.y;var S=i.hasOwnProperty("x"),R=i.hasOwnProperty("y"),j=Te,E=Ce,v=window;if(d){var P=$n(n),V="clientHeight",U="clientWidth";if(P===$e(n)&&(P=it(n),tt(P).position!=="static"&&l==="absolute"&&(V="scrollHeight",U="scrollWidth")),P=P,o===Ce||(o===Te||o===Le)&&s===Nn){E=ze;var C=h&&P===v&&v.visualViewport?v.visualViewport.height:P[V];f-=C-r.height,f*=c?1:-1}if(o===Te||(o===Ce||o===ze)&&s===Nn){j=Le;var _=h&&P===v&&v.visualViewport?v.visualViewport.width:P[U];b-=_-r.width,b*=c?1:-1}}var k=Object.assign({position:l},d&&Qw),A=u===!0?ef({x:b,y:f},$e(n)):{x:b,y:f};if(b=A.x,f=A.y,c){var $;return Object.assign({},k,($={},$[E]=R?"0":"",$[j]=S?"0":"",$.transform=(v.devicePixelRatio||1)<=1?"translate("+b+"px, "+f+"px)":"translate3d("+b+"px, "+f+"px, 0)",$))}return Object.assign({},k,(t={},t[E]=R?f+"px":"",t[j]=S?b+"px":"",t.transform="",t))}function tf(e){var t=e.state,n=e.options,r=n.gpuAcceleration,o=r===void 0?!0:r,s=n.adaptive,i=s===void 0?!0:s,l=n.roundOffsets,c=l===void 0?!0:l,d={placement:Xe(t.placement),variation:qt(t.placement),popper:t.elements.popper,popperRect:t.rects.popper,gpuAcceleration:o,isFixed:t.options.strategy==="fixed"};t.modifiersData.popperOffsets!=null&&(t.styles.popper=Object.assign({},t.styles.popper,qa(Object.assign({},d,{offsets:t.modifiersData.popperOffsets,position:t.options.strategy,adaptive:i,roundOffsets:c})))),t.modifiersData.arrow!=null&&(t.styles.arrow=Object.assign({},t.styles.arrow,qa(Object.assign({},d,{offsets:t.modifiersData.arrow,position:"absolute",adaptive:!1,roundOffsets:c})))),t.attributes.popper=Object.assign({},t.attributes.popper,{"data-popper-placement":t.placement})}const nf={name:"computeStyles",enabled:!0,phase:"beforeWrite",fn:tf,data:{}};var Fn={passive:!0};function rf(e){var t=e.state,n=e.instance,r=e.options,o=r.scroll,s=o===void 0?!0:o,i=r.resize,l=i===void 0?!0:i,c=$e(t.elements.popper),d=[].concat(t.scrollParents.reference,t.scrollParents.popper);return s&&d.forEach(function(u){u.addEventListener("scroll",n.update,Fn)}),l&&c.addEventListener("resize",n.update,Fn),function(){s&&d.forEach(function(u){u.removeEventListener("scroll",n.update,Fn)}),l&&c.removeEventListener("resize",n.update,Fn)}}const of={name:"eventListeners",enabled:!0,phase:"write",fn:function(){},effect:rf,data:{}};var af={left:"right",right:"left",bottom:"top",top:"bottom"};function Xn(e){return e.replace(/left|right|bottom|top/g,function(t){return af[t]})}var sf={start:"end",end:"start"};function Ha(e){return e.replace(/start|end/g,function(t){return sf[t]})}function Go(e){var t=$e(e),n=t.pageXOffset,r=t.pageYOffset;return{scrollLeft:n,scrollTop:r}}function Uo(e){return Ut(it(e)).left+Go(e).scrollLeft}function lf(e,t){var n=$e(e),r=it(e),o=n.visualViewport,s=r.clientWidth,i=r.clientHeight,l=0,c=0;if(o){s=o.width,i=o.height;var d=Ti();(d||!d&&t==="fixed")&&(l=o.offsetLeft,c=o.offsetTop)}return{width:s,height:i,x:l+Uo(e),y:c}}function cf(e){var t,n=it(e),r=Go(e),o=(t=e.ownerDocument)==null?void 0:t.body,s=ht(n.scrollWidth,n.clientWidth,o?o.scrollWidth:0,o?o.clientWidth:0),i=ht(n.scrollHeight,n.clientHeight,o?o.scrollHeight:0,o?o.clientHeight:0),l=-r.scrollLeft+Uo(e),c=-r.scrollTop;return tt(o||n).direction==="rtl"&&(l+=ht(n.clientWidth,o?o.clientWidth:0)-s),{width:s,height:i,x:l,y:c}}function qo(e){var t=tt(e),n=t.overflow,r=t.overflowX,o=t.overflowY;return/auto|scroll|overlay|hidden/.test(n+o+r)}function Ii(e){return["html","body","#document"].indexOf(We(e))>=0?e.ownerDocument.body:Ve(e)&&qo(e)?e:Ii(yr(e))}function gn(e,t){var n;t===void 0&&(t=[]);var r=Ii(e),o=r===((n=e.ownerDocument)==null?void 0:n.body),s=$e(r),i=o?[s].concat(s.visualViewport||[],qo(r)?r:[]):r,l=t.concat(i);return o?l:l.concat(gn(yr(i)))}function to(e){return Object.assign({},e,{left:e.x,top:e.y,right:e.x+e.width,bottom:e.y+e.height})}function df(e,t){var n=Ut(e,!1,t==="fixed");return n.top=n.top+e.clientTop,n.left=n.left+e.clientLeft,n.bottom=n.top+e.clientHeight,n.right=n.left+e.clientWidth,n.width=e.clientWidth,n.height=e.clientHeight,n.x=n.left,n.y=n.top,n}function Xa(e,t,n){return t===ji?to(lf(e,n)):kt(t)?df(t,n):to(cf(it(e)))}function uf(e){var t=gn(yr(e)),n=["absolute","fixed"].indexOf(tt(e).position)>=0,r=n&&Ve(e)?$n(e):e;return kt(r)?t.filter(function(o){return kt(o)&&Ri(o,r)&&We(o)!=="body"}):[]}function pf(e,t,n,r){var o=t==="clippingParents"?uf(e):[].concat(t),s=[].concat(o,[n]),i=s[0],l=s.reduce(function(c,d){var u=Xa(e,d,r);return c.top=ht(u.top,c.top),c.right=er(u.right,c.right),c.bottom=er(u.bottom,c.bottom),c.left=ht(u.left,c.left),c},Xa(e,i,r));return l.width=l.right-l.left,l.height=l.bottom-l.top,l.x=l.left,l.y=l.top,l}function Mi(e){var t=e.reference,n=e.element,r=e.placement,o=r?Xe(r):null,s=r?qt(r):null,i=t.x+t.width/2-n.width/2,l=t.y+t.height/2-n.height/2,c;switch(o){case Ce:c={x:i,y:t.y-n.height};break;case ze:c={x:i,y:t.y+t.height};break;case Le:c={x:t.x+t.width,y:l};break;case Te:c={x:t.x-n.width,y:l};break;default:c={x:t.x,y:t.y}}var d=o?Fo(o):null;if(d!=null){var u=d==="y"?"height":"width";switch(s){case Ft:c[d]=c[d]-(t[u]/2-n[u]/2);break;case Nn:c[d]=c[d]+(t[u]/2-n[u]/2);break}}return c}function kn(e,t){t===void 0&&(t={});var n=t,r=n.placement,o=r===void 0?e.placement:r,s=n.strategy,i=s===void 0?e.strategy:s,l=n.boundary,c=l===void 0?_w:l,d=n.rootBoundary,u=d===void 0?ji:d,h=n.elementContext,w=h===void 0?an:h,b=n.altBoundary,x=b===void 0?!1:b,f=n.padding,m=f===void 0?0:f,S=_i(typeof m!="number"?m:Pi(m,Mn)),R=w===an?Pw:an,j=e.rects.popper,E=e.elements[x?R:w],v=pf(kt(E)?E:E.contextElement||it(e.elements.popper),c,u,i),P=Ut(e.elements.reference),V=Mi({reference:P,element:j,strategy:"absolute",placement:o}),U=to(Object.assign({},j,V)),C=w===an?U:P,_={top:v.top-C.top+S.top,bottom:C.bottom-v.bottom+S.bottom,left:v.left-C.left+S.left,right:C.right-v.right+S.right},k=e.modifiersData.offset;if(w===an&&k){var A=k[o];Object.keys(_).forEach(function($){var J=[Le,ze].indexOf($)>=0?1:-1,Y=[Ce,ze].indexOf($)>=0?"y":"x";_[$]+=A[Y]*J})}return _}function wf(e,t){t===void 0&&(t={});var n=t,r=n.placement,o=n.boundary,s=n.rootBoundary,i=n.padding,l=n.flipVariations,c=n.allowedAutoPlacements,d=c===void 0?Ci:c,u=qt(r),h=u?l?Ga:Ga.filter(function(x){return qt(x)===u}):Mn,w=h.filter(function(x){return d.indexOf(x)>=0});w.length===0&&(w=h);var b=w.reduce(function(x,f){return x[f]=kn(e,{placement:f,boundary:o,rootBoundary:s,padding:i})[Xe(f)],x},{});return Object.keys(b).sort(function(x,f){return b[x]-b[f]})}function ff(e){if(Xe(e)===Vo)return[];var t=Xn(e);return[Ha(e),t,Ha(t)]}function mf(e){var t=e.state,n=e.options,r=e.name;if(!t.modifiersData[r]._skip){for(var o=n.mainAxis,s=o===void 0?!0:o,i=n.altAxis,l=i===void 0?!0:i,c=n.fallbackPlacements,d=n.padding,u=n.boundary,h=n.rootBoundary,w=n.altBoundary,b=n.flipVariations,x=b===void 0?!0:b,f=n.allowedAutoPlacements,m=t.options.placement,S=Xe(m),R=S===m,j=c||(R||!x?[Xn(m)]:ff(m)),E=[m].concat(j).reduce(function(B,X){return B.concat(Xe(X)===Vo?wf(t,{placement:X,boundary:u,rootBoundary:h,padding:d,flipVariations:x,allowedAutoPlacements:f}):X)},[]),v=t.rects.reference,P=t.rects.popper,V=new Map,U=!0,C=E[0],_=0;_=0,Y=J?"width":"height",F=kn(t,{placement:k,boundary:u,rootBoundary:h,altBoundary:w,padding:d}),te=J?$?Le:Te:$?ze:Ce;v[Y]>P[Y]&&(te=Xn(te));var se=Xn(te),oe=[];if(s&&oe.push(F[A]<=0),l&&oe.push(F[te]<=0,F[se]<=0),oe.every(function(B){return B})){C=k,U=!1;break}V.set(k,oe)}if(U)for(var y=x?3:1,T=function(X){var q=E.find(function(H){var G=V.get(H);if(G)return G.slice(0,X).every(function(K){return K})});if(q)return C=q,"break"},z=y;z>0;z--){var L=T(z);if(L==="break")break}t.placement!==C&&(t.modifiersData[r]._skip=!0,t.placement=C,t.reset=!0)}}const hf={name:"flip",enabled:!0,phase:"main",fn:mf,requiresIfExists:["offset"],data:{_skip:!1}};function Ya(e,t,n){return n===void 0&&(n={x:0,y:0}),{top:e.top-t.height-n.y,right:e.right-t.width+n.x,bottom:e.bottom-t.height+n.y,left:e.left-t.width-n.x}}function Wa(e){return[Ce,Le,ze,Te].some(function(t){return e[t]>=0})}function gf(e){var t=e.state,n=e.name,r=t.rects.reference,o=t.rects.popper,s=t.modifiersData.preventOverflow,i=kn(t,{elementContext:"reference"}),l=kn(t,{altBoundary:!0}),c=Ya(i,r),d=Ya(l,o,s),u=Wa(c),h=Wa(d);t.modifiersData[n]={referenceClippingOffsets:c,popperEscapeOffsets:d,isReferenceHidden:u,hasPopperEscaped:h},t.attributes.popper=Object.assign({},t.attributes.popper,{"data-popper-reference-hidden":u,"data-popper-escaped":h})}const bf={name:"hide",enabled:!0,phase:"main",requiresIfExists:["preventOverflow"],fn:gf};function vf(e,t,n){var r=Xe(e),o=[Te,Ce].indexOf(r)>=0?-1:1,s=typeof n=="function"?n(Object.assign({},t,{placement:e})):n,i=s[0],l=s[1];return i=i||0,l=(l||0)*o,[Te,Le].indexOf(r)>=0?{x:l,y:i}:{x:i,y:l}}function xf(e){var t=e.state,n=e.options,r=e.name,o=n.offset,s=o===void 0?[0,0]:o,i=Ci.reduce(function(u,h){return u[h]=vf(h,t.rects,s),u},{}),l=i[t.placement],c=l.x,d=l.y;t.modifiersData.popperOffsets!=null&&(t.modifiersData.popperOffsets.x+=c,t.modifiersData.popperOffsets.y+=d),t.modifiersData[r]=i}const yf={name:"offset",enabled:!0,phase:"main",requires:["popperOffsets"],fn:xf};function Nf(e){var t=e.state,n=e.name;t.modifiersData[n]=Mi({reference:t.rects.reference,element:t.rects.popper,strategy:"absolute",placement:t.placement})}const kf={name:"popperOffsets",enabled:!0,phase:"read",fn:Nf,data:{}};function Sf(e){return e==="x"?"y":"x"}function Ef(e){var t=e.state,n=e.options,r=e.name,o=n.mainAxis,s=o===void 0?!0:o,i=n.altAxis,l=i===void 0?!1:i,c=n.boundary,d=n.rootBoundary,u=n.altBoundary,h=n.padding,w=n.tether,b=w===void 0?!0:w,x=n.tetherOffset,f=x===void 0?0:x,m=kn(t,{boundary:c,rootBoundary:d,padding:h,altBoundary:u}),S=Xe(t.placement),R=qt(t.placement),j=!R,E=Fo(S),v=Sf(E),P=t.modifiersData.popperOffsets,V=t.rects.reference,U=t.rects.popper,C=typeof f=="function"?f(Object.assign({},t.rects,{placement:t.placement})):f,_=typeof C=="number"?{mainAxis:C,altAxis:C}:Object.assign({mainAxis:0,altAxis:0},C),k=t.modifiersData.offset?t.modifiersData.offset[t.placement]:null,A={x:0,y:0};if(P){if(s){var $,J=E==="y"?Ce:Te,Y=E==="y"?ze:Le,F=E==="y"?"height":"width",te=P[E],se=te+m[J],oe=te-m[Y],y=b?-U[F]/2:0,T=R===Ft?V[F]:U[F],z=R===Ft?-U[F]:-V[F],L=t.elements.arrow,B=b&&L?Lo(L):{width:0,height:0},X=t.modifiersData["arrow#persistent"]?t.modifiersData["arrow#persistent"].padding:Oi(),q=X[J],H=X[Y],G=hn(0,V[F],B[F]),K=j?V[F]/2-y-G-q-_.mainAxis:T-G-q-_.mainAxis,Z=j?-V[F]/2+y+G+H+_.mainAxis:z+G+H+_.mainAxis,ue=t.elements.arrow&&$n(t.elements.arrow),I=ue?E==="y"?ue.clientTop||0:ue.clientLeft||0:0,ye=($=k==null?void 0:k[E])!=null?$:0,D=te+K-ye-I,xe=te+Z-ye,Ge=hn(b?er(se,D):se,te,b?ht(oe,xe):oe);P[E]=Ge,A[E]=Ge-te}if(l){var lt,Ee=E==="x"?Ce:Te,An=E==="x"?ze:Le,Ue=P[v],Et=v==="y"?"height":"width",ct=Ue+m[Ee],jt=Ue-m[An],Ct=[Ce,Te].indexOf(S)!==-1,Tt=(lt=k==null?void 0:k[v])!=null?lt:0,dt=Ct?ct:Ue-V[Et]-U[Et]-Tt+_.altAxis,Jt=Ct?Ue+V[Et]+U[Et]-Tt-_.altAxis:jt,Dn=b&&Ct?Yw(dt,Ue,Jt):hn(b?dt:ct,Ue,b?Jt:jt);P[v]=Dn,A[v]=Dn-Ue}t.modifiersData[r]=A}}const jf={name:"preventOverflow",enabled:!0,phase:"main",fn:Ef,requiresIfExists:["offset"]};function Cf(e){return{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}}function Tf(e){return e===$e(e)||!Ve(e)?Go(e):Cf(e)}function Rf(e){var t=e.getBoundingClientRect(),n=Gt(t.width)/e.offsetWidth||1,r=Gt(t.height)/e.offsetHeight||1;return n!==1||r!==1}function Of(e,t,n){n===void 0&&(n=!1);var r=Ve(t),o=Ve(t)&&Rf(t),s=it(t),i=Ut(e,o,n),l={scrollLeft:0,scrollTop:0},c={x:0,y:0};return(r||!r&&!n)&&((We(t)!=="body"||qo(s))&&(l=Tf(t)),Ve(t)?(c=Ut(t,!0),c.x+=t.clientLeft,c.y+=t.clientTop):s&&(c.x=Uo(s))),{x:i.left+l.scrollLeft-c.x,y:i.top+l.scrollTop-c.y,width:i.width,height:i.height}}function _f(e){var t=new Map,n=new Set,r=[];e.forEach(function(s){t.set(s.name,s)});function o(s){n.add(s.name);var i=[].concat(s.requires||[],s.requiresIfExists||[]);i.forEach(function(l){if(!n.has(l)){var c=t.get(l);c&&o(c)}}),r.push(s)}return e.forEach(function(s){n.has(s.name)||o(s)}),r}function Pf(e){var t=_f(e);return Fw.reduce(function(n,r){return n.concat(t.filter(function(o){return o.phase===r}))},[])}function If(e){var t;return function(){return t||(t=new Promise(function(n){Promise.resolve().then(function(){t=void 0,n(e())})})),t}}function Mf(e){var t=e.reduce(function(n,r){var o=n[r.name];return n[r.name]=o?Object.assign({},o,r,{options:Object.assign({},o.options,r.options),data:Object.assign({},o.data,r.data)}):r,n},{});return Object.keys(t).map(function(n){return t[n]})}var Ka={placement:"bottom",modifiers:[],strategy:"absolute"};function Ja(){for(var e=arguments.length,t=new Array(e),n=0;nTo({root:["root"]},yw(Bf)),Uf={},qf=M.forwardRef(function(t,n){var r;const{anchorEl:o,children:s,direction:i,disablePortal:l,modifiers:c,open:d,placement:u,popperOptions:h,popperRef:w,slotProps:b={},slots:x={},TransitionProps:f}=t,m=Ne(t,Vf),S=M.useRef(null),R=yt(S,n),j=M.useRef(null),E=yt(j,w),v=M.useRef(E);Lt(()=>{v.current=E},[E]),M.useImperativeHandle(w,()=>j.current,[]);const P=Lf(u,i),[V,U]=M.useState(P),[C,_]=M.useState(tr(o));M.useEffect(()=>{j.current&&j.current.forceUpdate()}),M.useEffect(()=>{o&&_(tr(o))},[o]),Lt(()=>{if(!C||!d)return;const Y=se=>{U(se.placement)};if(process.env.NODE_ENV!=="production"&&C&&Nr(C)&&C.nodeType===1){const se=C.getBoundingClientRect();process.env.NODE_ENV!=="test"&&se.top===0&&se.left===0&&se.right===0&&se.bottom===0&&console.warn(["MUI: The `anchorEl` prop provided to the component is invalid.","The anchor element should be part of the document layout.","Make sure the element is present in the document or that it's not display none."].join(` +`))}let F=[{name:"preventOverflow",options:{altBoundary:l}},{name:"flip",options:{altBoundary:l}},{name:"onUpdate",enabled:!0,phase:"afterWrite",fn:({state:se})=>{Y(se)}}];c!=null&&(F=F.concat(c)),h&&h.modifiers!=null&&(F=F.concat(h.modifiers));const te=Df(C,S.current,O({placement:P},h,{modifiers:F}));return v.current(te),()=>{te.destroy(),v.current(null)}},[C,l,c,d,h,P]);const k={placement:V};f!==null&&(k.TransitionProps=f);const A=Gf(),$=(r=x.root)!=null?r:"div",J=jw({elementType:$,externalSlotProps:b.root,externalForwardedProps:m,additionalProps:{role:"tooltip",ref:R},ownerState:t,className:A.root});return a.jsx($,O({},J,{children:typeof s=="function"?s(k):s}))}),Ai=M.forwardRef(function(t,n){const{anchorEl:r,children:o,container:s,direction:i="ltr",disablePortal:l=!1,keepMounted:c=!1,modifiers:d,open:u,placement:h="bottom",popperOptions:w=Uf,popperRef:b,style:x,transition:f=!1,slotProps:m={},slots:S={}}=t,R=Ne(t,zf),[j,E]=M.useState(!0),v=()=>{E(!1)},P=()=>{E(!0)};if(!c&&!u&&(!f||j))return null;let V;if(s)V=s;else if(r){const _=tr(r);V=_&&Nr(_)?Kn(_).body:Kn(null).body}const U=!u&&c&&(!f||j)?"none":void 0,C=f?{in:u,onEnter:v,onExited:P}:void 0;return a.jsx(Qn,{disablePortal:l,container:V,children:a.jsx(qf,O({anchorEl:r,direction:i,disablePortal:l,modifiers:d,ref:n,open:f?!j:u,placement:h,popperOptions:w,popperRef:b,slotProps:m,slots:S},R,{style:O({position:"fixed",top:0,left:0,display:U},x),TransitionProps:C,children:o}))})});process.env.NODE_ENV!=="production"&&(Ai.propTypes={anchorEl:jo(p.oneOfType([xn,p.object,p.func]),e=>{if(e.open){const t=tr(e.anchorEl);if(t&&Nr(t)&&t.nodeType===1){const n=t.getBoundingClientRect();if(process.env.NODE_ENV!=="test"&&n.top===0&&n.left===0&&n.right===0&&n.bottom===0)return new Error(["MUI: The `anchorEl` prop provided to the component is invalid.","The anchor element should be part of the document layout.","Make sure the element is present in the document or that it's not display none."].join(` `))}else if(!t||typeof t.getBoundingClientRect!="function"||Ff(t)&&t.contextElement!=null&&t.contextElement.nodeType!==1)return new Error(["MUI: The `anchorEl` prop provided to the component is invalid.","It should be an HTML element instance or a virtualElement ","(https://popper.js.org/docs/v2/virtual-elements/)."].join(` -`))}return null}),children:p.oneOfType([p.node,p.func]),container:p.oneOfType([xn,p.func]),direction:p.oneOf(["ltr","rtl"]),disablePortal:p.bool,keepMounted:p.bool,modifiers:p.arrayOf(p.shape({data:p.object,effect:p.func,enabled:p.bool,fn:p.func,name:p.any,options:p.object,phase:p.oneOf(["afterMain","afterRead","afterWrite","beforeMain","beforeRead","beforeWrite","main","read","write"]),requires:p.arrayOf(p.string),requiresIfExists:p.arrayOf(p.string)})),open:p.bool.isRequired,placement:p.oneOf(["auto-end","auto-start","auto","bottom-end","bottom-start","bottom","left-end","left-start","left","right-end","right-start","right","top-end","top-start","top"]),popperOptions:p.shape({modifiers:p.array,onFirstUpdate:p.func,placement:p.oneOf(["auto-end","auto-start","auto","bottom-end","bottom-start","bottom","left-end","left-start","left","right-end","right-start","right","top-end","top-start","top"]),strategy:p.oneOf(["absolute","fixed"])}),popperRef:li,slotProps:p.shape({root:p.oneOfType([p.func,p.object])}),slots:p.shape({root:p.elementType}),transition:p.bool});function Ai(){const e=xi(Io);return process.env.NODE_ENV!=="production"&&M.useDebugValue(e),e[Mo]||e}function no(e,t){return no=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,o){return r.__proto__=o,r},no(e,t)}function Hf(e,t){e.prototype=Object.create(t.prototype),e.prototype.constructor=e,no(e,t)}const Ka={disabled:!1};var Xf=process.env.NODE_ENV!=="production"?p.oneOfType([p.number,p.shape({enter:p.number,exit:p.number,appear:p.number}).isRequired]):null;process.env.NODE_ENV!=="production"&&p.oneOfType([p.string,p.shape({enter:p.string,exit:p.string,active:p.string}),p.shape({enter:p.string,enterDone:p.string,enterActive:p.string,exit:p.string,exitDone:p.string,exitActive:p.string})]);const Bi=g.createContext(null);var Yf=function(t){return t.scrollTop},pn="unmounted",wt="exited",ft="entering",$t="entered",ro="exiting",nt=function(e){Hf(t,e);function t(r,o){var s;s=e.call(this,r,o)||this;var i=o,l=i&&!i.isMounting?r.enter:r.appear,c;return s.appearStatus=null,r.in?l?(c=wt,s.appearStatus=ft):c=$t:r.unmountOnExit||r.mountOnEnter?c=pn:c=wt,s.state={status:c},s.nextCallback=null,s}t.getDerivedStateFromProps=function(o,s){var i=o.in;return i&&s.status===pn?{status:wt}:null};var n=t.prototype;return n.componentDidMount=function(){this.updateStatus(!0,this.appearStatus)},n.componentDidUpdate=function(o){var s=null;if(o!==this.props){var i=this.state.status;this.props.in?i!==ft&&i!==$t&&(s=ft):(i===ft||i===$t)&&(s=ro)}this.updateStatus(!1,s)},n.componentWillUnmount=function(){this.cancelNextCallback()},n.getTimeouts=function(){var o=this.props.timeout,s,i,l;return s=i=l=o,o!=null&&typeof o!="number"&&(s=o.exit,i=o.enter,l=o.appear!==void 0?o.appear:i),{exit:s,enter:i,appear:l}},n.updateStatus=function(o,s){if(o===void 0&&(o=!1),s!==null)if(this.cancelNextCallback(),s===ft){if(this.props.unmountOnExit||this.props.mountOnEnter){var i=this.props.nodeRef?this.props.nodeRef.current:ln.findDOMNode(this);i&&Yf(i)}this.performEnter(o)}else this.performExit();else this.props.unmountOnExit&&this.state.status===wt&&this.setState({status:pn})},n.performEnter=function(o){var s=this,i=this.props.enter,l=this.context?this.context.isMounting:o,c=this.props.nodeRef?[l]:[ln.findDOMNode(this),l],d=c[0],u=c[1],h=this.getTimeouts(),w=l?h.appear:h.enter;if(!o&&!i||Ka.disabled){this.safeSetState({status:$t},function(){s.props.onEntered(d)});return}this.props.onEnter(d,u),this.safeSetState({status:ft},function(){s.props.onEntering(d,u),s.onTransitionEnd(w,function(){s.safeSetState({status:$t},function(){s.props.onEntered(d,u)})})})},n.performExit=function(){var o=this,s=this.props.exit,i=this.getTimeouts(),l=this.props.nodeRef?void 0:ln.findDOMNode(this);if(!s||Ka.disabled){this.safeSetState({status:wt},function(){o.props.onExited(l)});return}this.props.onExit(l),this.safeSetState({status:ro},function(){o.props.onExiting(l),o.onTransitionEnd(i.exit,function(){o.safeSetState({status:wt},function(){o.props.onExited(l)})})})},n.cancelNextCallback=function(){this.nextCallback!==null&&(this.nextCallback.cancel(),this.nextCallback=null)},n.safeSetState=function(o,s){s=this.setNextCallback(s),this.setState(o,s)},n.setNextCallback=function(o){var s=this,i=!0;return this.nextCallback=function(l){i&&(i=!1,s.nextCallback=null,o(l))},this.nextCallback.cancel=function(){i=!1},this.nextCallback},n.onTransitionEnd=function(o,s){this.setNextCallback(s);var i=this.props.nodeRef?this.props.nodeRef.current:ln.findDOMNode(this),l=o==null&&!this.props.addEndListener;if(!i||l){setTimeout(this.nextCallback,0);return}if(this.props.addEndListener){var c=this.props.nodeRef?[this.nextCallback]:[i,this.nextCallback],d=c[0],u=c[1];this.props.addEndListener(d,u)}o!=null&&setTimeout(this.nextCallback,o)},n.render=function(){var o=this.state.status;if(o===pn)return null;var s=this.props,i=s.children;s.in,s.mountOnEnter,s.unmountOnExit,s.appear,s.enter,s.exit,s.timeout,s.addEndListener,s.onEnter,s.onEntering,s.onEntered,s.onExit,s.onExiting,s.onExited,s.nodeRef;var l=Ne(s,["children","in","mountOnEnter","unmountOnExit","appear","enter","exit","timeout","addEndListener","onEnter","onEntering","onEntered","onExit","onExiting","onExited","nodeRef"]);return g.createElement(Bi.Provider,{value:null},typeof i=="function"?i(o,l):g.cloneElement(g.Children.only(i),l))},t}(g.Component);nt.contextType=Bi;nt.propTypes=process.env.NODE_ENV!=="production"?{nodeRef:p.shape({current:typeof Element>"u"?p.any:function(e,t,n,r,o,s){var i=e[t];return p.instanceOf(i&&"ownerDocument"in i?i.ownerDocument.defaultView.Element:Element)(e,t,n,r,o,s)}}),children:p.oneOfType([p.func.isRequired,p.element.isRequired]).isRequired,in:p.bool,mountOnEnter:p.bool,unmountOnExit:p.bool,appear:p.bool,enter:p.bool,exit:p.bool,timeout:function(t){var n=Xf;t.addEndListener||(n=n.isRequired);for(var r=arguments.length,o=new Array(r>1?r-1:0),s=1;se.scrollTop;function Ja(e,t){var n,r;const{timeout:o,easing:s,style:i={}}=e;return{duration:(n=i.transitionDuration)!=null?n:typeof o=="number"?o:o[t.mode]||0,easing:(r=i.transitionTimingFunction)!=null?r:typeof s=="object"?s[t.mode]:s,delay:i.transitionDelay}}const Jf=["addEndListener","appear","children","easing","in","onEnter","onEntered","onEntering","onExit","onExited","onExiting","style","timeout","TransitionComponent"];function oo(e){return`scale(${e}, ${e**2})`}const Zf={entering:{opacity:1,transform:oo(1)},entered:{opacity:1,transform:"none"}},Lr=typeof navigator<"u"&&/^((?!chrome|android).)*(safari|mobile)/i.test(navigator.userAgent)&&/(os |version\/)15(.|_)4/i.test(navigator.userAgent),Uo=M.forwardRef(function(t,n){const{addEndListener:r,appear:o=!0,children:s,easing:i,in:l,onEnter:c,onEntered:d,onEntering:u,onExit:h,onExited:w,onExiting:b,style:x,timeout:f="auto",TransitionComponent:m=Wf}=t,S=Ne(t,Jf),R=dn(),j=M.useRef(),E=Ai(),v=M.useRef(null),P=yt(v,s.ref,n),V=Y=>F=>{if(Y){const te=v.current;F===void 0?Y(te):Y(te,F)}},U=V(u),C=V((Y,F)=>{Kf(Y);const{duration:te,delay:se,easing:oe}=Ja({style:x,timeout:f,easing:i},{mode:"enter"});let y;f==="auto"?(y=E.transitions.getAutoHeightDuration(Y.clientHeight),j.current=y):y=te,Y.style.transition=[E.transitions.create("opacity",{duration:y,delay:se}),E.transitions.create("transform",{duration:Lr?y:y*.666,delay:se,easing:oe})].join(","),c&&c(Y,F)}),_=V(d),k=V(b),D=V(Y=>{const{duration:F,delay:te,easing:se}=Ja({style:x,timeout:f,easing:i},{mode:"exit"});let oe;f==="auto"?(oe=E.transitions.getAutoHeightDuration(Y.clientHeight),j.current=oe):oe=F,Y.style.transition=[E.transitions.create("opacity",{duration:oe,delay:te}),E.transitions.create("transform",{duration:Lr?oe:oe*.666,delay:Lr?te:te||oe*.333,easing:se})].join(","),Y.style.opacity=0,Y.style.transform=oo(.75),h&&h(Y)}),$=V(w),J=Y=>{f==="auto"&&R.start(j.current||0,Y),r&&r(v.current,Y)};return a.jsx(m,O({appear:o,in:l,nodeRef:v,onEnter:C,onEntered:_,onEntering:U,onExit:D,onExited:$,onExiting:k,addEndListener:J,timeout:f==="auto"?null:f},S,{children:(Y,F)=>M.cloneElement(s,O({style:O({opacity:0,transform:oo(.75),visibility:Y==="exited"&&!l?"hidden":void 0},Zf[Y],x,s.props.style),ref:P},F))}))});process.env.NODE_ENV!=="production"&&(Uo.propTypes={addEndListener:p.func,appear:p.bool,children:si.isRequired,easing:p.oneOfType([p.shape({enter:p.string,exit:p.string}),p.string]),in:p.bool,onEnter:p.func,onEntered:p.func,onEntering:p.func,onExit:p.func,onExited:p.func,onExiting:p.func,style:p.object,timeout:p.oneOfType([p.oneOf(["auto"]),p.number,p.shape({appear:p.number,enter:p.number,exit:p.number})])});Uo.muiSupportAuto=!0;const Za=Uo,Qf=["anchorEl","component","components","componentsProps","container","disablePortal","keepMounted","modifiers","open","placement","popperOptions","popperRef","transition","slots","slotProps"],em=In(Di,{name:"MuiPopper",slot:"Root",overridesResolver:(e,t)=>t.root})({}),Vi=M.forwardRef(function(t,n){var r;const o=vi(),s=$o({props:t,name:"MuiPopper"}),{anchorEl:i,component:l,components:c,componentsProps:d,container:u,disablePortal:h,keepMounted:w,modifiers:b,open:x,placement:f,popperOptions:m,popperRef:S,transition:R,slots:j,slotProps:E}=s,v=Ne(s,Qf),P=(r=j==null?void 0:j.root)!=null?r:c==null?void 0:c.Root,V=O({anchorEl:i,container:u,disablePortal:h,keepMounted:w,modifiers:b,open:x,placement:f,popperOptions:m,popperRef:S,transition:R},v);return a.jsx(em,O({as:l,direction:o==null?void 0:o.direction,slots:{root:P},slotProps:E??d},V,{ref:n}))});process.env.NODE_ENV!=="production"&&(Vi.propTypes={anchorEl:p.oneOfType([xn,p.object,p.func]),children:p.oneOfType([p.node,p.func]),component:p.elementType,components:p.shape({Root:p.elementType}),componentsProps:p.shape({root:p.oneOfType([p.func,p.object])}),container:p.oneOfType([xn,p.func]),disablePortal:p.bool,keepMounted:p.bool,modifiers:p.arrayOf(p.shape({data:p.object,effect:p.func,enabled:p.bool,fn:p.func,name:p.any,options:p.object,phase:p.oneOf(["afterMain","afterRead","afterWrite","beforeMain","beforeRead","beforeWrite","main","read","write"]),requires:p.arrayOf(p.string),requiresIfExists:p.arrayOf(p.string)})),open:p.bool.isRequired,placement:p.oneOf(["auto-end","auto-start","auto","bottom-end","bottom-start","bottom","left-end","left-start","left","right-end","right-start","right","top-end","top-start","top"]),popperOptions:p.shape({modifiers:p.array,onFirstUpdate:p.func,placement:p.oneOf(["auto-end","auto-start","auto","bottom-end","bottom-start","bottom","left-end","left-start","left","right-end","right-start","right","top-end","top-start","top"]),strategy:p.oneOf(["absolute","fixed"])}),popperRef:li,slotProps:p.shape({root:p.oneOfType([p.func,p.object])}),slots:p.shape({root:p.elementType}),sx:p.oneOfType([p.arrayOf(p.oneOfType([p.func,p.object,p.bool])),p.func,p.object]),transition:p.bool});const zi=Vi;function tm(e){return ur("MuiTooltip",e)}const nm=mi("MuiTooltip",["popper","popperInteractive","popperArrow","popperClose","tooltip","tooltipArrow","touch","tooltipPlacementLeft","tooltipPlacementRight","tooltipPlacementTop","tooltipPlacementBottom","arrow"]),at=nm,rm=["arrow","children","classes","components","componentsProps","describeChild","disableFocusListener","disableHoverListener","disableInteractive","disableTouchListener","enterDelay","enterNextDelay","enterTouchDelay","followCursor","id","leaveDelay","leaveTouchDelay","onClose","onOpen","open","placement","PopperComponent","PopperProps","slotProps","slots","title","TransitionComponent","TransitionProps"];function om(e){return Math.round(e*1e5)/1e5}const am=e=>{const{classes:t,disableInteractive:n,arrow:r,touch:o,placement:s}=e,i={popper:["popper",!n&&"popperInteractive",r&&"popperArrow"],tooltip:["tooltip",r&&"tooltipArrow",o&&"touch",`tooltipPlacement${Ye(s.split("-")[0])}`],arrow:["arrow"]};return jo(i,tm,t)},sm=In(zi,{name:"MuiTooltip",slot:"Popper",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.popper,!n.disableInteractive&&t.popperInteractive,n.arrow&&t.popperArrow,!n.open&&t.popperClose]}})(({theme:e,ownerState:t,open:n})=>O({zIndex:(e.vars||e).zIndex.tooltip,pointerEvents:"none"},!t.disableInteractive&&{pointerEvents:"auto"},!n&&{pointerEvents:"none"},t.arrow&&{[`&[data-popper-placement*="bottom"] .${at.arrow}`]:{top:0,marginTop:"-0.71em","&::before":{transformOrigin:"0 100%"}},[`&[data-popper-placement*="top"] .${at.arrow}`]:{bottom:0,marginBottom:"-0.71em","&::before":{transformOrigin:"100% 0"}},[`&[data-popper-placement*="right"] .${at.arrow}`]:O({},t.isRtl?{right:0,marginRight:"-0.71em"}:{left:0,marginLeft:"-0.71em"},{height:"1em",width:"0.71em","&::before":{transformOrigin:"100% 100%"}}),[`&[data-popper-placement*="left"] .${at.arrow}`]:O({},t.isRtl?{left:0,marginLeft:"-0.71em"}:{right:0,marginRight:"-0.71em"},{height:"1em",width:"0.71em","&::before":{transformOrigin:"0 0"}})})),im=In("div",{name:"MuiTooltip",slot:"Tooltip",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.tooltip,n.touch&&t.touch,n.arrow&&t.tooltipArrow,t[`tooltipPlacement${Ye(n.placement.split("-")[0])}`]]}})(({theme:e,ownerState:t})=>O({backgroundColor:e.vars?e.vars.palette.Tooltip.bg:yi(e.palette.grey[700],.92),borderRadius:(e.vars||e).shape.borderRadius,color:(e.vars||e).palette.common.white,fontFamily:e.typography.fontFamily,padding:"4px 8px",fontSize:e.typography.pxToRem(11),maxWidth:300,margin:2,wordWrap:"break-word",fontWeight:e.typography.fontWeightMedium},t.arrow&&{position:"relative",margin:0},t.touch&&{padding:"8px 16px",fontSize:e.typography.pxToRem(14),lineHeight:`${om(16/14)}em`,fontWeight:e.typography.fontWeightRegular},{[`.${at.popper}[data-popper-placement*="left"] &`]:O({transformOrigin:"right center"},t.isRtl?O({marginLeft:"14px"},t.touch&&{marginLeft:"24px"}):O({marginRight:"14px"},t.touch&&{marginRight:"24px"})),[`.${at.popper}[data-popper-placement*="right"] &`]:O({transformOrigin:"left center"},t.isRtl?O({marginRight:"14px"},t.touch&&{marginRight:"24px"}):O({marginLeft:"14px"},t.touch&&{marginLeft:"24px"})),[`.${at.popper}[data-popper-placement*="top"] &`]:O({transformOrigin:"center bottom",marginBottom:"14px"},t.touch&&{marginBottom:"24px"}),[`.${at.popper}[data-popper-placement*="bottom"] &`]:O({transformOrigin:"center top",marginTop:"14px"},t.touch&&{marginTop:"24px"})})),lm=In("span",{name:"MuiTooltip",slot:"Arrow",overridesResolver:(e,t)=>t.arrow})(({theme:e})=>({overflow:"hidden",position:"absolute",width:"1em",height:"0.71em",boxSizing:"border-box",color:e.vars?e.vars.palette.Tooltip.bg:yi(e.palette.grey[700],.9),"&::before":{content:'""',margin:"auto",display:"block",width:"100%",height:"100%",backgroundColor:"currentColor",transform:"rotate(45deg)"}}));let Gn=!1;const Qa=new On;let sn={x:0,y:0};function Un(e,t){return n=>{t&&t(n),e(n)}}const Li=M.forwardRef(function(t,n){var r,o,s,i,l,c,d,u,h,w,b,x,f,m,S,R,j,E,v;const P=$o({props:t,name:"MuiTooltip"}),{arrow:V=!1,children:U,components:C={},componentsProps:_={},describeChild:k=!1,disableFocusListener:D=!1,disableHoverListener:$=!1,disableInteractive:J=!1,disableTouchListener:Y=!1,enterDelay:F=100,enterNextDelay:te=0,enterTouchDelay:se=700,followCursor:oe=!1,id:y,leaveDelay:T=0,leaveTouchDelay:z=1500,onClose:L,onOpen:B,open:X,placement:q="bottom",PopperComponent:H,PopperProps:G={},slotProps:K={},slots:Z={},title:ue,TransitionComponent:I=Za,TransitionProps:ye}=P,A=Ne(P,rm),xe=M.isValidElement(U)?U:a.jsx("span",{children:U}),Ge=Ai(),lt=Ge.direction==="rtl",[Ee,Dn]=M.useState(),[Ue,Et]=M.useState(null),ct=M.useRef(!1),jt=J||oe,Ct=dn(),Tt=dn(),dt=dn(),Jt=dn(),[An,Ho]=di({controlled:X,default:!1,name:"Tooltip",state:"open"});let Ke=An;if(process.env.NODE_ENV!=="production"){const{current:ee}=M.useRef(X!==void 0);M.useEffect(()=>{Ee&&Ee.disabled&&!ee&&ue!==""&&Ee.tagName.toLowerCase()==="button"&&console.error(["MUI: You are providing a disabled `button` child to the Tooltip component.","A disabled element does not fire events.","Tooltip needs to listen to the child element's events to display the title.","","Add a simple wrapper element, such as a `span`."].join(` -`))},[ue,Ee,ee])}const kr=ci(y),Zt=M.useRef(),Bn=Zr(()=>{Zt.current!==void 0&&(document.body.style.WebkitUserSelect=Zt.current,Zt.current=void 0),Jt.clear()});M.useEffect(()=>Bn,[Bn]);const Xo=ee=>{Qa.clear(),Gn=!0,Ho(!0),B&&!Ke&&B(ee)},Vn=Zr(ee=>{Qa.start(800+T,()=>{Gn=!1}),Ho(!1),L&&Ke&&L(ee),Ct.start(Ge.transitions.duration.shortest,()=>{ct.current=!1})}),Sr=ee=>{ct.current&&ee.type!=="touchstart"||(Ee&&Ee.removeAttribute("title"),Tt.clear(),dt.clear(),F||Gn&&te?Tt.start(Gn?te:F,()=>{Xo(ee)}):Xo(ee))},Yo=ee=>{Tt.clear(),dt.start(T,()=>{Vn(ee)})},{isFocusVisibleRef:Wo,onBlur:rl,onFocus:ol,ref:al}=ui(),[,Ko]=M.useState(!1),Jo=ee=>{rl(ee),Wo.current===!1&&(Ko(!1),Yo(ee))},Zo=ee=>{Ee||Dn(ee.currentTarget),ol(ee),Wo.current===!0&&(Ko(!0),Sr(ee))},Qo=ee=>{ct.current=!0;const Pe=xe.props;Pe.onTouchStart&&Pe.onTouchStart(ee)},ea=Sr,ta=Yo,sl=ee=>{Qo(ee),dt.clear(),Ct.clear(),Bn(),Zt.current=document.body.style.WebkitUserSelect,document.body.style.WebkitUserSelect="none",Jt.start(se,()=>{document.body.style.WebkitUserSelect=Zt.current,Sr(ee)})},il=ee=>{xe.props.onTouchEnd&&xe.props.onTouchEnd(ee),Bn(),dt.start(z,()=>{Vn(ee)})};M.useEffect(()=>{if(!Ke)return;function ee(Pe){(Pe.key==="Escape"||Pe.key==="Esc")&&Vn(Pe)}return document.addEventListener("keydown",ee),()=>{document.removeEventListener("keydown",ee)}},[Vn,Ke]);const ll=yt(xe.ref,al,Dn,n);!ue&&ue!==0&&(Ke=!1);const Er=M.useRef(),cl=ee=>{const Pe=xe.props;Pe.onMouseMove&&Pe.onMouseMove(ee),sn={x:ee.clientX,y:ee.clientY},Er.current&&Er.current.update()},Qt={},jr=typeof ue=="string";k?(Qt.title=!Ke&&jr&&!$?ue:null,Qt["aria-describedby"]=Ke?kr:null):(Qt["aria-label"]=jr?ue:null,Qt["aria-labelledby"]=Ke&&!jr?kr:null);const De=O({},Qt,A,xe.props,{className:ot(A.className,xe.props.className),onTouchStart:Qo,ref:ll},oe?{onMouseMove:cl}:{});process.env.NODE_ENV!=="production"&&(De["data-mui-internal-clone-element"]=!0,M.useEffect(()=>{Ee&&!Ee.getAttribute("data-mui-internal-clone-element")&&console.error(["MUI: The `children` component of the Tooltip is not forwarding its props correctly.","Please make sure that props are spread on the same element that the ref is applied to."].join(` -`))},[Ee]));const en={};Y||(De.onTouchStart=sl,De.onTouchEnd=il),$||(De.onMouseOver=Un(ea,De.onMouseOver),De.onMouseLeave=Un(ta,De.onMouseLeave),jt||(en.onMouseOver=ea,en.onMouseLeave=ta)),D||(De.onFocus=Un(Zo,De.onFocus),De.onBlur=Un(Jo,De.onBlur),jt||(en.onFocus=Zo,en.onBlur=Jo)),process.env.NODE_ENV!=="production"&&xe.props.title&&console.error(["MUI: You have provided a `title` prop to the child of .",`Remove this title prop \`${xe.props.title}\` or the Tooltip component.`].join(` -`));const dl=M.useMemo(()=>{var ee;let Pe=[{name:"arrow",enabled:!!Ue,options:{element:Ue,padding:4}}];return(ee=G.popperOptions)!=null&&ee.modifiers&&(Pe=Pe.concat(G.popperOptions.modifiers)),O({},G.popperOptions,{modifiers:Pe})},[Ue,G]),tn=O({},P,{isRtl:lt,arrow:V,disableInteractive:jt,placement:q,PopperComponentProp:H,touch:ct.current}),Cr=am(tn),na=(r=(o=Z.popper)!=null?o:C.Popper)!=null?r:sm,ra=(s=(i=(l=Z.transition)!=null?l:C.Transition)!=null?i:I)!=null?s:Za,oa=(c=(d=Z.tooltip)!=null?d:C.Tooltip)!=null?c:im,aa=(u=(h=Z.arrow)!=null?h:C.Arrow)!=null?u:lm,ul=un(na,O({},G,(w=K.popper)!=null?w:_.popper,{className:ot(Cr.popper,G==null?void 0:G.className,(b=(x=K.popper)!=null?x:_.popper)==null?void 0:b.className)}),tn),pl=un(ra,O({},ye,(f=K.transition)!=null?f:_.transition),tn),wl=un(oa,O({},(m=K.tooltip)!=null?m:_.tooltip,{className:ot(Cr.tooltip,(S=(R=K.tooltip)!=null?R:_.tooltip)==null?void 0:S.className)}),tn),fl=un(aa,O({},(j=K.arrow)!=null?j:_.arrow,{className:ot(Cr.arrow,(E=(v=K.arrow)!=null?v:_.arrow)==null?void 0:E.className)}),tn);return a.jsxs(M.Fragment,{children:[M.cloneElement(xe,De),a.jsx(na,O({as:H??zi,placement:q,anchorEl:oe?{getBoundingClientRect:()=>({top:sn.y,left:sn.x,right:sn.x,bottom:sn.y,width:0,height:0})}:Ee,popperRef:Er,open:Ee?Ke:!1,id:kr,transition:!0},en,ul,{popperOptions:dl,children:({TransitionProps:ee})=>a.jsx(ra,O({timeout:Ge.transitions.duration.shorter},ee,pl,{children:a.jsxs(oa,O({},wl,{children:[ue,V?a.jsx(aa,O({},fl,{ref:Et})):null]}))}))}))]})});process.env.NODE_ENV!=="production"&&(Li.propTypes={arrow:p.bool,children:si.isRequired,classes:p.object,className:p.string,components:p.shape({Arrow:p.elementType,Popper:p.elementType,Tooltip:p.elementType,Transition:p.elementType}),componentsProps:p.shape({arrow:p.object,popper:p.object,tooltip:p.object,transition:p.object}),describeChild:p.bool,disableFocusListener:p.bool,disableHoverListener:p.bool,disableInteractive:p.bool,disableTouchListener:p.bool,enterDelay:p.number,enterNextDelay:p.number,enterTouchDelay:p.number,followCursor:p.bool,id:p.string,leaveDelay:p.number,leaveTouchDelay:p.number,onClose:p.func,onOpen:p.func,open:p.bool,placement:p.oneOf(["bottom-end","bottom-start","bottom","left-end","left-start","left","right-end","right-start","right","top-end","top-start","top"]),PopperComponent:p.elementType,PopperProps:p.object,slotProps:p.shape({arrow:p.object,popper:p.object,tooltip:p.object,transition:p.object}),slots:p.shape({arrow:p.elementType,popper:p.elementType,tooltip:p.elementType,transition:p.elementType}),sx:p.oneOfType([p.arrayOf(p.oneOfType([p.func,p.object,p.bool])),p.func,p.object]),title:p.node,TransitionComponent:p.elementType,TransitionProps:p.object});const cm=Li;function es(e,t,n){return e?a.jsx(Ce.ListItemIcon,{className:`papi-menu-icon-${n?"leading":"trailing"}`,children:a.jsx("img",{src:e,alt:`${n?"Leading":"Trailing"} icon for ${t}`})}):void 0}function qo(e){const{onClick:t,label:n,tooltip:r,allowForLeadingIcons:o=!0,iconPathBefore:s=void 0,iconPathAfter:i=void 0,hasAutoFocus:l=!1,className:c,isDisabled:d=!1,isDense:u=!0,isSubMenuParent:h=!1,hasDisabledGutters:w=!1,hasDivider:b=!1,focusVisibleClassName:x,id:f,children:m}=e,S=a.jsx(Ce.MenuItem,{sx:{lineHeight:.8},autoFocus:l,className:c,disabled:d,dense:u,disableGutters:w,divider:b,focusVisibleClassName:x,onClick:t,id:f,children:n?a.jsxs(a.Fragment,{children:[es(s,n,!0),a.jsx(Ce.ListItemText,{primary:n,inset:!s&&o}),h?a.jsx(Ce.ListItemIcon,{className:"papi-menu-icon-trailing",children:a.jsx(ki,{})}):es(i,n,!1)]}):m});return r?a.jsx(cm,{title:r,placement:"right",children:a.jsx("div",{children:S})}):S}function Fi(e){return Object.entries(e.groups).map(([n,r])=>({id:n,group:r}))}function dm(e){const[t,n]=g.useState(void 0),{parentMenuItem:r,parentItemProps:o,menuDefinition:s}=e,i=d=>{n(d.currentTarget)},l=()=>{n(void 0)},c=()=>{let d=Fi(s).filter(u=>"menuItem"in u.group);if(!(r!=null&&r.id))throw new Error("A valid parent menu item is required for submenus.");return d=d.filter(u=>"menuItem"in u.group&&u.group.menuItem===r.id),a.jsx(Gi,{...e,includedGroups:d})};return a.jsxs(a.Fragment,{children:[a.jsx(qo,{onClick:i,...o,isSubMenuParent:!0}),a.jsx(Ce.Menu,{anchorEl:t,open:!!t,onClose:l,anchorOrigin:{vertical:"top",horizontal:"right"},transformOrigin:{vertical:"top",horizontal:"left"},children:c()},r.id)]})}const um=(e,t)=>t.filter(o=>o.group===e).sort((o,s)=>(o.order||0)-(s.order||0));function Gi(e){const{menuDefinition:t,onClick:n,commandHandler:r,includedGroups:o}=e,{items:s,allowForLeadingIcons:i}=g.useMemo(()=>{const u=o&&o.length>0?o:Fi(t).filter(x=>!("menuItem"in x.group)),h=Object.values(u).sort((x,f)=>(x.group.order||0)-(f.group.order||0)),w=[];h.forEach(x=>{um(x.id,t.items).forEach(f=>w.push({item:f,isLastItemInGroup:!1})),w.length>0&&(w[w.length-1].isLastItemInGroup=!0)}),w.length>0&&(w[w.length-1].isLastItemInGroup=!1);const b=w.some(x=>"iconPathBefore"in x.item&&x.item.iconPathBefore);return{items:w,allowForLeadingIcons:b}},[o,t]),l=({item:u,isLastItemInGroup:h})=>({className:"papi-menu-item",label:u.label,tooltip:u.tooltip,iconPathBefore:"iconPathBefore"in u?u.iconPathBefore:void 0,iconPathAfter:"iconPathAfter"in u?u.iconPathAfter:void 0,hasDivider:h,allowForLeadingIcons:i}),[c]=s;if(!c)return a.jsx("div",{});const d=c.item.group;return a.jsx("div",{role:"menu","aria-label":d,children:s.map((u,h)=>{const{item:w}=u,b=l(u);if("command"in w){const x=w.group+h;return a.jsx(qo,{onClick:f=>{n==null||n(f),r(w)},...b},x)}return a.jsx(dm,{parentMenuItem:w,parentItemProps:b,...e},d+w.id)})},d)}function pm(e){const{menuDefinition:t,columnId:n}=e;let s=Object.entries(t.groups).map(([i,l])=>({id:i,group:l})).filter(i=>"column"in i.group);return n&&"columns"in t&&t.columns[n]&&(s=s.filter(i=>"column"in i.group&&i.group.column===n)),a.jsx(Gi,{...e,includedGroups:s})}function wm({commandHandler:e,menuDefinition:t,id:n,metadata:r,onClick:o,className:s}){return a.jsxs(Ce.Grid,{id:n,item:!0,xs:"auto",role:"menu","aria-label":n,className:`papi-menu-column ${s??""}`,children:[a.jsx("h3",{"aria-label":r.label,className:`papi-menu-column-header ${s??""}`,children:r.label}),a.jsx(Ce.List,{id:n,dense:!0,className:s??"",children:a.jsx(pm,{commandHandler:e,menuDefinition:t,columnId:n,onClick:o})})]})}function Ui({commandHandler:e,className:t,multiColumnMenu:n,id:r}){const{columns:o}=n,s=g.useMemo(()=>{const i=new Map;return Object.getOwnPropertyNames(o).forEach(l=>{if(l==="isExtensible")return;const c=l,d=o[c];typeof d=="object"&&typeof d.order=="number"&&!Number.isNaN(d.order)?i.set(d.order,{id:c,metadata:d}):console.warn(`Property ${l} (${typeof d}) on menu ${r} is not a valid column and is being ignored. This might indicate data corruption`)}),Array.from(i.values()).sort((l,c)=>(l.metadata.order||0)-(c.metadata.order||0))},[o,r]);return a.jsx(Ce.Grid,{container:!0,spacing:0,className:`papi-multi-column-menu ${t??""}`,columns:s.length,role:"menu","aria-label":"GridMenu",id:r,children:s.map((i,l)=>a.jsx(wm,{commandHandler:e,menuDefinition:n,...i,className:t},l))})}function fm(e){return{preserveValue:!0,...e}}const nr=(e,t,n={})=>{const r=g.useRef(t);r.current=t;const o=g.useRef(n);o.current=fm(o.current);const[s,i]=g.useState(()=>r.current),[l,c]=g.useState(!0);return g.useEffect(()=>{let d=!0;return c(!!e),(async()=>{if(e){const u=await e();d&&(i(()=>u),c(!1))}})(),()=>{d=!1,o.current.preserveValue||i(()=>r.current)}},[e]),[s,l]},mm=Ni(a.jsx("path",{d:"M3 18h18v-2H3zm0-5h18v-2H3zm0-7v2h18V6z"}),"Menu");function qi({menuProvider:e,normalMenu:t,fullMenu:n,commandHandler:r,containerRef:o,className:s,ariaLabelPrefix:i,children:l}){const[c,d]=g.useState(!1),[u,h]=g.useState(!1),w=g.useCallback(()=>{c&&d(!1),h(!1)},[c]),b=g.useCallback(E=>{E.stopPropagation(),d(v=>{const P=!v;return P&&E.shiftKey?h(!0):P||h(!1),P})},[]),x=g.useCallback(E=>(w(),r(E)),[r,w]),[f,m]=g.useState({top:1,left:1});g.useEffect(()=>{if(c){const E=o==null?void 0:o.current;if(E){const v=E.getBoundingClientRect(),P=window.scrollY,V=window.scrollX,U=v.top+P+E.clientHeight,C=v.left+V;m({top:U,left:C})}}},[c,o]);const[S]=nr(g.useCallback(async()=>(e==null?void 0:e(!1))??t,[e,t,c]),t),[R]=nr(g.useCallback(async()=>(e==null?void 0:e(!0))??n??S,[e,n,S,c]),n??S),j=u&&R?R:S;return a.jsxs(a.Fragment,{children:[a.jsx(Ce.IconButton,{sx:{paddingTop:0,paddingBottom:0},edge:"start",className:`papi-menuButton ${s??""}`,color:"inherit","aria-label":`${i??""} menu button`,onClick:b,children:l??a.jsx(mm,{})}),a.jsx(Ce.Drawer,{className:`papi-menu-drawer ${s??""}`,anchor:"left",variant:"temporary",open:c,onClose:w,PaperProps:{className:"papi-menu-drawer-paper",style:{top:f.top,left:f.left}},children:j?a.jsx(Ui,{className:s,id:`${i??""} main menu`,commandHandler:x,multiColumnMenu:j}):void 0})]})}function hm({id:e,label:t,isDisabled:n=!1,tooltip:r,isTooltipSuppressed:o=!1,adjustMarginToAlignToEdge:s=!1,size:i="medium",className:l,onClick:c,children:d}){return a.jsx(Ce.IconButton,{id:e,disabled:n,edge:s,size:i,"aria-label":t,title:o?void 0:r??t,className:`papi-icon-button ${l??""}`,onClick:c,children:d})}const Kt=g.forwardRef(({className:e,...t},n)=>a.jsx(Q.LoaderCircle,{size:35,className:N("tw-animate-spin",e),...t,ref:n}));Kt.displayName="Spinner";function gm({id:e,isDisabled:t=!1,hasError:n=!1,isFullWidth:r=!1,helperText:o,label:s,placeholder:i,isRequired:l=!1,className:c,defaultValue:d,value:u,onChange:h,onFocus:w,onBlur:b}){return a.jsxs("div",{className:N("tw-inline-grid tw-items-center tw-gap-1.5",{"tw-w-full":r}),children:[a.jsx(qe,{htmlFor:e,className:N({"tw-text-red-600":n,"tw-hidden":!s}),children:`${s}${l?"*":""}`}),a.jsx(St,{id:e,disabled:t,placeholder:i,required:l,className:N(c,{"tw-border-red-600":n}),defaultValue:d,value:u,onChange:h,onFocus:w,onBlur:b}),a.jsx("p",{className:N({"tw-hidden":!o}),children:o})]})}function bm({menuProvider:e,commandHandler:t,className:n,id:r,children:o}){const s=g.useRef(void 0);return a.jsx("div",{ref:s,style:{position:"relative"},children:a.jsx(Ce.AppBar,{position:"static",id:r,children:a.jsxs(Ce.Toolbar,{className:N("tw-bg-muted tw-text-muted-foreground",n),variant:"dense",children:[e?a.jsx(qi,{commandHandler:t,containerRef:s,menuProvider:e}):void 0,o?a.jsx("div",{className:"papi-toolbar-children",children:o}):void 0]})})})}const vm=Xt.cva("tw-relative tw-w-full tw-rounded-lg tw-border tw-p-4 [&>svg~*]:tw-pl-7 [&>svg+div]:tw-translate-y-[-3px] [&>svg]:tw-absolute [&>svg]:tw-left-4 [&>svg]:tw-top-4 [&>svg]:tw-text-foreground",{variants:{variant:{default:"tw-bg-background tw-text-foreground",destructive:"tw-border-destructive/50 tw-text-destructive dark:tw-border-destructive [&>svg]:tw-text-destructive"}},defaultVariants:{variant:"default"}}),Hi=g.forwardRef(({className:e,variant:t,...n},r)=>a.jsx("div",{ref:r,role:"alert",className:N(vm({variant:t}),e),...n}));Hi.displayName="Alert";const Xi=g.forwardRef(({className:e,...t},n)=>a.jsxs("h5",{ref:n,className:N("tw-mb-1 tw-font-medium tw-leading-none tw-tracking-tight",e),...t,children:[t.children," "]}));Xi.displayName="AlertTitle";const Yi=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,className:N("tw-text-sm [&_p]:tw-leading-relaxed",e),...t}));Yi.displayName="AlertDescription";function xm({...e}){return a.jsx(ns.Toaster,{className:"tw-toaster tw-group",toastOptions:{classNames:{toast:"group toast group-[.toaster]:bg-background group-[.toaster]:text-foreground group-[.toaster]:border-border group-[.toaster]:shadow-lg",description:"group-[.toast]:text-muted-foreground",actionButton:"group-[.toast]:bg-primary group-[.toast]:text-primary-foreground",cancelButton:"group-[.toast]:bg-muted group-[.toast]:text-muted-foreground"}},...e})}const Wi=g.forwardRef(({className:e,...t},n)=>a.jsxs(cn.Root,{ref:n,className:N("pr-twp tw-relative tw-flex tw-w-full tw-touch-none tw-select-none tw-items-center",e),...t,children:[a.jsx(cn.Track,{className:"tw-relative tw-h-2 tw-w-full tw-grow tw-overflow-hidden tw-rounded-full tw-bg-secondary",children:a.jsx(cn.Range,{className:"tw-absolute tw-h-full tw-bg-primary"})}),a.jsx(cn.Thumb,{className:"tw-block tw-h-5 tw-w-5 tw-rounded-full tw-border-2 tw-border-primary tw-bg-background tw-ring-offset-background tw-transition-colors focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50"})]}));Wi.displayName=cn.Root.displayName;const Ki=g.forwardRef(({className:e,...t},n)=>a.jsx(qr.Root,{className:N("tw-peer pr-twp tw-inline-flex tw-h-6 tw-w-11 tw-shrink-0 tw-cursor-pointer tw-items-center tw-rounded-full tw-border-2 tw-border-transparent tw-transition-colors focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 focus-visible:tw-ring-offset-background disabled:tw-cursor-not-allowed disabled:tw-opacity-50 data-[state=checked]:tw-bg-primary data-[state=unchecked]:tw-bg-input",e),...t,ref:n,children:a.jsx(qr.Thumb,{className:N("pr-twp tw-pointer-events-none tw-block tw-h-5 tw-w-5 tw-rounded-full tw-bg-background tw-shadow-lg tw-ring-0 tw-transition-transform data-[state=checked]:tw-translate-x-5 data-[state=unchecked]:tw-translate-x-0")})}));Ki.displayName=qr.Root.displayName;const ym=_e.Root,Ji=g.forwardRef(({className:e,...t},n)=>a.jsx(_e.List,{ref:n,className:N("tw-inline-flex tw-h-10 tw-items-center tw-justify-center tw-rounded-md tw-bg-muted tw-p-1 tw-text-muted-foreground",e),...t}));Ji.displayName=_e.List.displayName;const Zi=g.forwardRef(({className:e,...t},n)=>a.jsx(_e.Trigger,{ref:n,className:N("tw-inline-flex tw-items-center tw-justify-center tw-whitespace-nowrap tw-rounded-sm tw-px-3 tw-py-1.5 tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-all hover:tw-text-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50 data-[state=active]:tw-bg-background data-[state=active]:tw-text-foreground data-[state=active]:tw-shadow-sm",e),...t}));Zi.displayName=_e.Trigger.displayName;const Qi=g.forwardRef(({className:e,...t},n)=>a.jsx(_e.Content,{ref:n,className:N("tw-mt-2 tw-ring-offset-background focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2",e),...t}));Qi.displayName=_e.Content.displayName;function Nm({isInstalling:e,handleClick:t,buttonText:n,className:r,...o}){return a.jsx(fe,{className:N("tw-h-8 tw-rounded-md tw-text-white tw-transition tw-duration-300 tw-ease-in-out hover:tw-bg-blue-700",{"tw-cursor-not-allowed tw-bg-blue-700":e,"tw-bg-blue-600":!e,"tw-bg-white tw-text-blue-600 hover:tw-text-white":!n,"tw-w-20":n},r),onClick:t,...o,children:e?a.jsx(Kt,{size:15}):a.jsxs(a.Fragment,{children:[a.jsx(Q.Download,{size:25,className:N("tw-h-4 tw-w-4",{"tw-mr-1":n})}),n]})})}function km({isEnabling:e,handleClick:t,className:n,...r}){return a.jsx(fe,{className:N("tw-h-8 tw-rounded-md tw-bg-blue-600 tw-px-4 tw-text-white tw-transition tw-duration-300 tw-ease-in-out hover:tw-bg-blue-700",{"tw-cursor-not-allowed tw-bg-blue-700":e},n),onClick:t,...r,children:e?a.jsxs(a.Fragment,{children:[a.jsx(Kt,{size:15,className:"tw-mr-1 tw-text-white"}),"Enabling..."]}):"Enable"})}function Sm({isDisabling:e,handleClick:t,className:n,...r}){return a.jsx(fe,{className:N("tw-h-8 tw-rounded-md tw-bg-gray-300 tw-text-black tw-transition tw-duration-300 tw-ease-in-out hover:tw-bg-gray-400",{"tw-cursor-not-allowed tw-bg-gray-400":e},n),onClick:t,...r,children:e?a.jsxs(a.Fragment,{children:[a.jsx(Kt,{size:15,className:"tw-mr-1 tw-text-black"}),"Disabling..."]}):"Disable"})}function Em({isUpdating:e,handleClick:t,className:n,...r}){return a.jsx(fe,{className:N("tw-h-8 tw-rounded-md tw-bg-blue-600 tw-px-4 tw-text-white tw-transition tw-duration-300 tw-ease-in-out hover:tw-bg-blue-700 hover:tw-text-white",{"tw-cursor-not-allowed tw-bg-blue-700":e},n),onClick:t,...r,children:e?a.jsxs(a.Fragment,{children:[a.jsx(Kt,{size:15,className:"tw-mr-1 tw-text-white"}),"Updating..."]}):"Update"})}function jm({id:e,markdown:t,className:n,anchorTarget:r}){const o=g.useMemo(()=>({overrides:{a:{props:{target:r}}}}),[r]);return a.jsx("div",{id:e,className:N("pr-twp tw-prose",n),children:a.jsx(Rl,{options:o,children:t})})}const el=g.forwardRef((e,t)=>a.jsxs(fe,{ref:t,className:"tw-rounded-md tw-border tw-border-dashed tw-border-gray-400 tw-bg-white tw-px-4 tw-py-2 tw-text-black tw-transition tw-duration-300 tw-ease-in-out hover:tw-border-blue-600 hover:tw-bg-white hover:tw-text-blue-600",...e,children:[a.jsx(Q.Filter,{size:16,className:"tw-mr-2 tw-h-4 tw-w-4 tw-text-gray-700 hover:tw-text-blue-600"}),"Filter",a.jsx(Q.ChevronDown,{size:16,className:"tw-ml-2 tw-h-4 tw-w-4 tw-text-gray-700 hover:tw-text-blue-600"})]}));var tl=(e=>(e[e.Check=0]="Check",e[e.Radio=1]="Radio",e))(tl||{});function Cm({id:e,groups:t}){return a.jsx("div",{id:e,children:a.jsxs(or,{children:[a.jsx(lo,{asChild:!0,children:a.jsx(el,{})}),a.jsx(En,{children:t.map(n=>a.jsxs("div",{children:[a.jsx(Wt,{children:n.label}),a.jsx(ps,{children:n.items.map(r=>a.jsx("div",{children:r.itemType===0?a.jsx(ar,{onClick:r.onClick,children:r.label}):a.jsx(uo,{onClick:r.onClick,value:r.label,children:r.label})},r.label))}),a.jsx(jn,{})]},n.label))})]})})}function Tm({id:e,message:t}){return a.jsx("div",{id:e,className:"tw-mb-20 tw-mt-20 tw-flex tw-items-center tw-justify-center",children:a.jsx("div",{className:"tw-w-3/4 tw-rounded-lg tw-bg-gray-100 tw-p-8 tw-text-center",children:a.jsx("p",{className:"tw-text-lg tw-text-gray-800",children:t})})})}function Rm({id:e,category:t,downloads:n,languages:r,moreInfoUrl:o}){const s=new W.NumberFormat("en",{notation:"compact",compactDisplay:"short"}).format(Object.values(n).reduce((l,c)=>l+c,0)),i=()=>{window.scrollTo(0,document.body.scrollHeight)};return a.jsxs("div",{id:e,className:"tw-flex tw-flex-wrap tw-items-start tw-space-x-4 tw-border-b tw-border-t tw-bg-white tw-pb-4 tw-pt-4",children:[a.jsxs("div",{className:"tw-flex tw-flex-col tw-items-center",children:[a.jsx("div",{className:"tw-flex tw-items-center tw-rounded-md tw-bg-gray-100 tw-px-2 tw-py-1",children:a.jsx("span",{className:"tw-text-xs tw-font-semibold tw-text-gray-700",children:t})}),a.jsx("span",{className:"tw-text-xs tw-text-gray-500",children:"CATEGORY"})]}),a.jsx("div",{className:"tw-mx-2 tw-h-10 tw-border-l tw-border-gray-300"}),a.jsxs("div",{className:"tw-flex tw-flex-col tw-items-center",children:[a.jsxs("div",{className:"tw-flex tw-items-center tw-rounded-md tw-bg-gray-100 tw-px-2 tw-py-1",children:[a.jsx(Q.User,{className:"tw-mr-1 tw-h-4 tw-w-4"}),a.jsx("span",{className:"tw-text-xs tw-font-semibold tw-text-gray-700",children:s})]}),a.jsx("span",{className:"tw-text-xs tw-text-gray-500",children:"USERS"})]}),a.jsx("div",{className:"tw-mx-2 tw-h-10 tw-border-l tw-border-gray-300"}),a.jsxs("div",{className:"tw-flex tw-flex-col tw-items-center",children:[a.jsx("div",{className:"tw-flex tw-items-center",children:r.slice(0,3).map(l=>a.jsx("span",{className:"tw-ml-1 tw-rounded-md tw-bg-gray-100 tw-px-2 tw-py-1 tw-text-xs tw-font-semibold tw-text-gray-700",children:l.toUpperCase()},l))}),r.length>3&&a.jsxs("button",{type:"button",onClick:()=>i(),className:"tw-text-xs tw-text-gray-500 tw-underline",children:["+",r.length-3," more languages"]})]}),a.jsx("div",{className:"tw-mx-2 tw-h-10 tw-border-l tw-border-gray-300"}),a.jsxs("div",{className:"tw-ml-auto tw-flex tw-flex-col tw-space-y-2",children:[a.jsxs("a",{href:o,target:"_blank",rel:"noreferrer",className:"tw-flex tw-items-center tw-text-xs tw-font-semibold tw-text-gray-500 tw-underline",children:["Website",a.jsx(Q.Link,{className:"tw-ml-1 tw-inline tw-h-4 tw-w-4"})]}),a.jsxs("a",{href:"https://example.com",target:"_blank",rel:"noreferrer",className:"tw-flex tw-items-center tw-text-xs tw-font-semibold tw-text-gray-500 tw-underline",children:["Support",a.jsx(Q.CircleHelp,{className:"tw-ml-1 tw-inline tw-h-4 tw-w-4"})]})]})]})}function nl({id:e,versionHistory:t}){const[n,r]=g.useState(!1),o=new Date;function s(l){const c=new Date(l),d=new Date(o.getTime()-c.getTime()),u=d.getUTCFullYear()-1970,h=d.getUTCMonth(),w=d.getUTCDate()-1;let b="";return u>0?b=`${u.toString()} year${u===1?"":"s"} ago`:h>0?b=`${h.toString()} month${h===1?"":"s"} ago`:w===0?b="today":b=`${w.toString()} day${w===1?"":"s"} ago`,b}const i=Object.entries(t).sort((l,c)=>c[0].localeCompare(l[0]));return a.jsxs("div",{id:e,children:[a.jsx("h3",{className:"tw-text-md tw-font-semibold",children:"What`s New"}),a.jsx("ul",{className:"tw-list-disc tw-pl-5 tw-pr-4 tw-text-xs tw-text-gray-600",children:(n?i:i.slice(0,5)).map(l=>a.jsxs("div",{className:"tw-mt-3 tw-flex tw-justify-between",children:[a.jsx("div",{className:"tw-text-gray-600",children:a.jsx("li",{className:"tw-prose tw-text-xs",children:a.jsx("span",{children:l[1].description})})}),a.jsxs("div",{className:"tw-justify-end tw-text-right",children:[a.jsxs("div",{children:["Version ",l[0]]}),a.jsx("div",{children:s(l[1].date)})]})]},l[0]))}),i.length>5&&a.jsx("button",{type:"button",onClick:()=>r(!n),className:"tw-text-xs tw-text-gray-500 tw-underline",children:n?"Show Less Version History":"Show All Version History"})]})}function Om({id:e,publisherDisplayName:t,fileSize:n,locales:r,versionHistory:o}){const s=g.useMemo(()=>W.formatBytes(n),[n]),l=(c=>{const d=new Intl.DisplayNames(navigator.language,{type:"language"});return c.map(u=>d.of(u))})(r);return a.jsx("div",{id:e,className:"tw-border-t tw-pb-4 tw-pt-4",children:a.jsxs("div",{className:"tw-md:flex-row tw-md:space-x-8 tw-flex tw-flex-col tw-space-x-0",children:[a.jsx(nl,{versionHistory:o}),a.jsx("div",{className:"tw-md:border-t-0 tw-md:border-l tw-md-h-auto tw-md-ml-8 tw-mt-4 tw-border-t tw-border-gray-300"}),a.jsxs("div",{className:"tw-md:mt-0 tw-mt-4 tw-flex-1 tw-space-y-3",children:[a.jsx("h2",{className:"tw-text-md tw-font-semibold",children:"Information"}),a.jsxs("div",{className:"tw-flex tw-items-start tw-justify-between tw-pr-4 tw-text-xs tw-text-gray-600",children:[a.jsxs("p",{className:"tw-flex tw-flex-col tw-justify-start",children:[a.jsx("span",{className:"tw-mb-2",children:"Publisher"}),a.jsx("span",{className:"tw-font-semibold",children:t}),a.jsx("span",{className:"tw-mb-2 tw-mt-4",children:"Size"}),a.jsx("span",{className:"tw-font-semibold",children:s})]}),a.jsx("div",{className:"tw-flex tw-w-3/4 tw-items-center tw-justify-between tw-text-xs tw-text-gray-600",children:a.jsxs("p",{className:"tw-flex tw-flex-col tw-justify-start",children:[a.jsx("span",{className:"tw-mb-2",children:"Languages"}),a.jsx("span",{className:"tw-font-semibold",children:l.join(", ")})]})})]})]})]})})}const _m=(e,t)=>{g.useEffect(()=>{if(!e)return()=>{};const n=e(t);return()=>{n()}},[e,t])},Fr=()=>!1,Pm=(e,t)=>{const[n]=nr(g.useCallback(async()=>{if(!e)return Fr;const r=await Promise.resolve(e(t));return async()=>r()},[t,e]),Fr,{preserveValue:!1});g.useEffect(()=>()=>{n!==Fr&&n()},[n])};Object.defineProperty(exports,"sonner",{enumerable:!0,get:()=>ns.toast});exports.Alert=Hi;exports.AlertDescription=Yi;exports.AlertTitle=Xi;exports.BOOK_SELECTOR_STRING_KEYS=mc;exports.BookChapterControl=oc;exports.BookSelectionMode=Es;exports.BookSelector=hc;exports.Button=fe;exports.Card=vo;exports.CardContent=Zs;exports.CardDescription=No;exports.CardFooter=Qs;exports.CardHeader=xo;exports.CardTitle=yo;exports.ChapterRangeSelector=Ss;exports.Checkbox=sr;exports.Checklist=vd;exports.ComboBox=Wn;exports.DataTable=_s;exports.DisableButton=Sm;exports.DropdownMenu=or;exports.DropdownMenuCheckboxItem=ar;exports.DropdownMenuContent=En;exports.DropdownMenuGroup=ps;exports.DropdownMenuItem=co;exports.DropdownMenuItemType=tl;exports.DropdownMenuLabel=Wt;exports.DropdownMenuPortal=ql;exports.DropdownMenuRadioGroup=Xl;exports.DropdownMenuRadioItem=uo;exports.DropdownMenuSeparator=jn;exports.DropdownMenuShortcut=ms;exports.DropdownMenuSub=Hl;exports.DropdownMenuSubContent=fs;exports.DropdownMenuSubTrigger=ws;exports.DropdownMenuTrigger=lo;exports.EnableButton=km;exports.FilterButton=el;exports.FilterDropdown=Cm;exports.Footer=Om;exports.GridMenu=Ui;exports.HamburgerMenuButton=qi;exports.INVENTORY_STRING_KEYS=Ec;exports.IconButton=hm;exports.Input=St;exports.InstallButton=Nm;exports.Inventory=Tc;exports.Label=qe;exports.MarkdownRenderer=jm;exports.MenuItem=qo;exports.MoreInfo=Rm;exports.NavigationContentSearch=Rc;exports.NoExtensionsFound=Tm;exports.RadioGroup=po;exports.RadioGroupItem=Yn;exports.ScriptureResultsViewer=wd;exports.ScrollGroupSelector=fd;exports.SearchBar=As;exports.Select=At;exports.SelectContent=vt;exports.SelectGroup=js;exports.SelectItem=Ae;exports.SelectLabel=Cs;exports.SelectScrollDownButton=fo;exports.SelectScrollUpButton=wo;exports.SelectSeparator=Ts;exports.SelectTrigger=bt;exports.SelectValue=Bt;exports.Separator=lr;exports.SettingsCard=bd;exports.SettingsList=md;exports.SettingsListHeader=gd;exports.SettingsListItem=hd;exports.SettingsSidebar=Ks;exports.SettingsSidebarContentSearch=ad;exports.Slider=Wi;exports.Sonner=xm;exports.Spinner=Kt;exports.Switch=Ki;exports.Table=Cn;exports.TableBody=Rn;exports.TableCaption=Os;exports.TableCell=xt;exports.TableFooter=Rs;exports.TableHead=Vt;exports.TableHeader=Tn;exports.TableRow=Ze;exports.Tabs=ym;exports.TabsContent=Qi;exports.TabsList=Ji;exports.TabsTrigger=Zi;exports.TextField=gm;exports.ToggleGroup=mo;exports.ToggleGroupItem=fn;exports.Toolbar=bm;exports.UpdateButton=Em;exports.VersionHistory=nl;exports.VerticalTabs=ho;exports.VerticalTabsContent=bo;exports.VerticalTabsList=go;exports.VerticalTabsTrigger=Bs;exports.buttonVariants=hs;exports.cn=N;exports.getBookNumFromId=Is;exports.getLinesFromUSFM=Ps;exports.getNumberFromUSFM=Hr;exports.getStatusForItem=Ms;exports.inventoryCountColumn=kc;exports.inventoryItemColumn=yc;exports.inventoryStatusColumn=Sc;exports.useEvent=_m;exports.useEventAsync=Pm;exports.usePromise=nr;function Im(e,t="top"){if(!e||typeof document>"u")return;const n=document.head||document.querySelector("head"),r=n.querySelector(":first-child"),o=document.createElement("style");o.appendChild(document.createTextNode(e)),t==="top"&&r?n.insertBefore(o,r):n.appendChild(o)}Im(`*, ::before, ::after { +`))}return null}),children:p.oneOfType([p.node,p.func]),container:p.oneOfType([xn,p.func]),direction:p.oneOf(["ltr","rtl"]),disablePortal:p.bool,keepMounted:p.bool,modifiers:p.arrayOf(p.shape({data:p.object,effect:p.func,enabled:p.bool,fn:p.func,name:p.any,options:p.object,phase:p.oneOf(["afterMain","afterRead","afterWrite","beforeMain","beforeRead","beforeWrite","main","read","write"]),requires:p.arrayOf(p.string),requiresIfExists:p.arrayOf(p.string)})),open:p.bool.isRequired,placement:p.oneOf(["auto-end","auto-start","auto","bottom-end","bottom-start","bottom","left-end","left-start","left","right-end","right-start","right","top-end","top-start","top"]),popperOptions:p.shape({modifiers:p.array,onFirstUpdate:p.func,placement:p.oneOf(["auto-end","auto-start","auto","bottom-end","bottom-start","bottom","left-end","left-start","left","right-end","right-start","right","top-end","top-start","top"]),strategy:p.oneOf(["absolute","fixed"])}),popperRef:li,slotProps:p.shape({root:p.oneOfType([p.func,p.object])}),slots:p.shape({root:p.elementType}),transition:p.bool});function Di(){const e=xi($o);return process.env.NODE_ENV!=="production"&&M.useDebugValue(e),e[Ao]||e}function no(e,t){return no=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,o){return r.__proto__=o,r},no(e,t)}function Hf(e,t){e.prototype=Object.create(t.prototype),e.prototype.constructor=e,no(e,t)}const Za={disabled:!1};var Xf=process.env.NODE_ENV!=="production"?p.oneOfType([p.number,p.shape({enter:p.number,exit:p.number,appear:p.number}).isRequired]):null;process.env.NODE_ENV!=="production"&&p.oneOfType([p.string,p.shape({enter:p.string,exit:p.string,active:p.string}),p.shape({enter:p.string,enterDone:p.string,enterActive:p.string,exit:p.string,exitDone:p.string,exitActive:p.string})]);const Bi=g.createContext(null);var Yf=function(t){return t.scrollTop},pn="unmounted",wt="exited",ft="entering",$t="entered",ro="exiting",nt=function(e){Hf(t,e);function t(r,o){var s;s=e.call(this,r,o)||this;var i=o,l=i&&!i.isMounting?r.enter:r.appear,c;return s.appearStatus=null,r.in?l?(c=wt,s.appearStatus=ft):c=$t:r.unmountOnExit||r.mountOnEnter?c=pn:c=wt,s.state={status:c},s.nextCallback=null,s}t.getDerivedStateFromProps=function(o,s){var i=o.in;return i&&s.status===pn?{status:wt}:null};var n=t.prototype;return n.componentDidMount=function(){this.updateStatus(!0,this.appearStatus)},n.componentDidUpdate=function(o){var s=null;if(o!==this.props){var i=this.state.status;this.props.in?i!==ft&&i!==$t&&(s=ft):(i===ft||i===$t)&&(s=ro)}this.updateStatus(!1,s)},n.componentWillUnmount=function(){this.cancelNextCallback()},n.getTimeouts=function(){var o=this.props.timeout,s,i,l;return s=i=l=o,o!=null&&typeof o!="number"&&(s=o.exit,i=o.enter,l=o.appear!==void 0?o.appear:i),{exit:s,enter:i,appear:l}},n.updateStatus=function(o,s){if(o===void 0&&(o=!1),s!==null)if(this.cancelNextCallback(),s===ft){if(this.props.unmountOnExit||this.props.mountOnEnter){var i=this.props.nodeRef?this.props.nodeRef.current:ln.findDOMNode(this);i&&Yf(i)}this.performEnter(o)}else this.performExit();else this.props.unmountOnExit&&this.state.status===wt&&this.setState({status:pn})},n.performEnter=function(o){var s=this,i=this.props.enter,l=this.context?this.context.isMounting:o,c=this.props.nodeRef?[l]:[ln.findDOMNode(this),l],d=c[0],u=c[1],h=this.getTimeouts(),w=l?h.appear:h.enter;if(!o&&!i||Za.disabled){this.safeSetState({status:$t},function(){s.props.onEntered(d)});return}this.props.onEnter(d,u),this.safeSetState({status:ft},function(){s.props.onEntering(d,u),s.onTransitionEnd(w,function(){s.safeSetState({status:$t},function(){s.props.onEntered(d,u)})})})},n.performExit=function(){var o=this,s=this.props.exit,i=this.getTimeouts(),l=this.props.nodeRef?void 0:ln.findDOMNode(this);if(!s||Za.disabled){this.safeSetState({status:wt},function(){o.props.onExited(l)});return}this.props.onExit(l),this.safeSetState({status:ro},function(){o.props.onExiting(l),o.onTransitionEnd(i.exit,function(){o.safeSetState({status:wt},function(){o.props.onExited(l)})})})},n.cancelNextCallback=function(){this.nextCallback!==null&&(this.nextCallback.cancel(),this.nextCallback=null)},n.safeSetState=function(o,s){s=this.setNextCallback(s),this.setState(o,s)},n.setNextCallback=function(o){var s=this,i=!0;return this.nextCallback=function(l){i&&(i=!1,s.nextCallback=null,o(l))},this.nextCallback.cancel=function(){i=!1},this.nextCallback},n.onTransitionEnd=function(o,s){this.setNextCallback(s);var i=this.props.nodeRef?this.props.nodeRef.current:ln.findDOMNode(this),l=o==null&&!this.props.addEndListener;if(!i||l){setTimeout(this.nextCallback,0);return}if(this.props.addEndListener){var c=this.props.nodeRef?[this.nextCallback]:[i,this.nextCallback],d=c[0],u=c[1];this.props.addEndListener(d,u)}o!=null&&setTimeout(this.nextCallback,o)},n.render=function(){var o=this.state.status;if(o===pn)return null;var s=this.props,i=s.children;s.in,s.mountOnEnter,s.unmountOnExit,s.appear,s.enter,s.exit,s.timeout,s.addEndListener,s.onEnter,s.onEntering,s.onEntered,s.onExit,s.onExiting,s.onExited,s.nodeRef;var l=Ne(s,["children","in","mountOnEnter","unmountOnExit","appear","enter","exit","timeout","addEndListener","onEnter","onEntering","onEntered","onExit","onExiting","onExited","nodeRef"]);return g.createElement(Bi.Provider,{value:null},typeof i=="function"?i(o,l):g.cloneElement(g.Children.only(i),l))},t}(g.Component);nt.contextType=Bi;nt.propTypes=process.env.NODE_ENV!=="production"?{nodeRef:p.shape({current:typeof Element>"u"?p.any:function(e,t,n,r,o,s){var i=e[t];return p.instanceOf(i&&"ownerDocument"in i?i.ownerDocument.defaultView.Element:Element)(e,t,n,r,o,s)}}),children:p.oneOfType([p.func.isRequired,p.element.isRequired]).isRequired,in:p.bool,mountOnEnter:p.bool,unmountOnExit:p.bool,appear:p.bool,enter:p.bool,exit:p.bool,timeout:function(t){var n=Xf;t.addEndListener||(n=n.isRequired);for(var r=arguments.length,o=new Array(r>1?r-1:0),s=1;se.scrollTop;function Qa(e,t){var n,r;const{timeout:o,easing:s,style:i={}}=e;return{duration:(n=i.transitionDuration)!=null?n:typeof o=="number"?o:o[t.mode]||0,easing:(r=i.transitionTimingFunction)!=null?r:typeof s=="object"?s[t.mode]:s,delay:i.transitionDelay}}const Jf=["addEndListener","appear","children","easing","in","onEnter","onEntered","onEntering","onExit","onExited","onExiting","style","timeout","TransitionComponent"];function oo(e){return`scale(${e}, ${e**2})`}const Zf={entering:{opacity:1,transform:oo(1)},entered:{opacity:1,transform:"none"}},Lr=typeof navigator<"u"&&/^((?!chrome|android).)*(safari|mobile)/i.test(navigator.userAgent)&&/(os |version\/)15(.|_)4/i.test(navigator.userAgent),Ho=M.forwardRef(function(t,n){const{addEndListener:r,appear:o=!0,children:s,easing:i,in:l,onEnter:c,onEntered:d,onEntering:u,onExit:h,onExited:w,onExiting:b,style:x,timeout:f="auto",TransitionComponent:m=Wf}=t,S=Ne(t,Jf),R=dn(),j=M.useRef(),E=Di(),v=M.useRef(null),P=yt(v,s.ref,n),V=Y=>F=>{if(Y){const te=v.current;F===void 0?Y(te):Y(te,F)}},U=V(u),C=V((Y,F)=>{Kf(Y);const{duration:te,delay:se,easing:oe}=Qa({style:x,timeout:f,easing:i},{mode:"enter"});let y;f==="auto"?(y=E.transitions.getAutoHeightDuration(Y.clientHeight),j.current=y):y=te,Y.style.transition=[E.transitions.create("opacity",{duration:y,delay:se}),E.transitions.create("transform",{duration:Lr?y:y*.666,delay:se,easing:oe})].join(","),c&&c(Y,F)}),_=V(d),k=V(b),A=V(Y=>{const{duration:F,delay:te,easing:se}=Qa({style:x,timeout:f,easing:i},{mode:"exit"});let oe;f==="auto"?(oe=E.transitions.getAutoHeightDuration(Y.clientHeight),j.current=oe):oe=F,Y.style.transition=[E.transitions.create("opacity",{duration:oe,delay:te}),E.transitions.create("transform",{duration:Lr?oe:oe*.666,delay:Lr?te:te||oe*.333,easing:se})].join(","),Y.style.opacity=0,Y.style.transform=oo(.75),h&&h(Y)}),$=V(w),J=Y=>{f==="auto"&&R.start(j.current||0,Y),r&&r(v.current,Y)};return a.jsx(m,O({appear:o,in:l,nodeRef:v,onEnter:C,onEntered:_,onEntering:U,onExit:A,onExited:$,onExiting:k,addEndListener:J,timeout:f==="auto"?null:f},S,{children:(Y,F)=>M.cloneElement(s,O({style:O({opacity:0,transform:oo(.75),visibility:Y==="exited"&&!l?"hidden":void 0},Zf[Y],x,s.props.style),ref:P},F))}))});process.env.NODE_ENV!=="production"&&(Ho.propTypes={addEndListener:p.func,appear:p.bool,children:si.isRequired,easing:p.oneOfType([p.shape({enter:p.string,exit:p.string}),p.string]),in:p.bool,onEnter:p.func,onEntered:p.func,onEntering:p.func,onExit:p.func,onExited:p.func,onExiting:p.func,style:p.object,timeout:p.oneOfType([p.oneOf(["auto"]),p.number,p.shape({appear:p.number,enter:p.number,exit:p.number})])});Ho.muiSupportAuto=!0;const es=Ho,Qf=["anchorEl","component","components","componentsProps","container","disablePortal","keepMounted","modifiers","open","placement","popperOptions","popperRef","transition","slots","slotProps"],em=In(Ai,{name:"MuiPopper",slot:"Root",overridesResolver:(e,t)=>t.root})({}),Vi=M.forwardRef(function(t,n){var r;const o=vi(),s=Do({props:t,name:"MuiPopper"}),{anchorEl:i,component:l,components:c,componentsProps:d,container:u,disablePortal:h,keepMounted:w,modifiers:b,open:x,placement:f,popperOptions:m,popperRef:S,transition:R,slots:j,slotProps:E}=s,v=Ne(s,Qf),P=(r=j==null?void 0:j.root)!=null?r:c==null?void 0:c.Root,V=O({anchorEl:i,container:u,disablePortal:h,keepMounted:w,modifiers:b,open:x,placement:f,popperOptions:m,popperRef:S,transition:R},v);return a.jsx(em,O({as:l,direction:o==null?void 0:o.direction,slots:{root:P},slotProps:E??d},V,{ref:n}))});process.env.NODE_ENV!=="production"&&(Vi.propTypes={anchorEl:p.oneOfType([xn,p.object,p.func]),children:p.oneOfType([p.node,p.func]),component:p.elementType,components:p.shape({Root:p.elementType}),componentsProps:p.shape({root:p.oneOfType([p.func,p.object])}),container:p.oneOfType([xn,p.func]),disablePortal:p.bool,keepMounted:p.bool,modifiers:p.arrayOf(p.shape({data:p.object,effect:p.func,enabled:p.bool,fn:p.func,name:p.any,options:p.object,phase:p.oneOf(["afterMain","afterRead","afterWrite","beforeMain","beforeRead","beforeWrite","main","read","write"]),requires:p.arrayOf(p.string),requiresIfExists:p.arrayOf(p.string)})),open:p.bool.isRequired,placement:p.oneOf(["auto-end","auto-start","auto","bottom-end","bottom-start","bottom","left-end","left-start","left","right-end","right-start","right","top-end","top-start","top"]),popperOptions:p.shape({modifiers:p.array,onFirstUpdate:p.func,placement:p.oneOf(["auto-end","auto-start","auto","bottom-end","bottom-start","bottom","left-end","left-start","left","right-end","right-start","right","top-end","top-start","top"]),strategy:p.oneOf(["absolute","fixed"])}),popperRef:li,slotProps:p.shape({root:p.oneOfType([p.func,p.object])}),slots:p.shape({root:p.elementType}),sx:p.oneOfType([p.arrayOf(p.oneOfType([p.func,p.object,p.bool])),p.func,p.object]),transition:p.bool});const zi=Vi;function tm(e){return ur("MuiTooltip",e)}const nm=mi("MuiTooltip",["popper","popperInteractive","popperArrow","popperClose","tooltip","tooltipArrow","touch","tooltipPlacementLeft","tooltipPlacementRight","tooltipPlacementTop","tooltipPlacementBottom","arrow"]),at=nm,rm=["arrow","children","classes","components","componentsProps","describeChild","disableFocusListener","disableHoverListener","disableInteractive","disableTouchListener","enterDelay","enterNextDelay","enterTouchDelay","followCursor","id","leaveDelay","leaveTouchDelay","onClose","onOpen","open","placement","PopperComponent","PopperProps","slotProps","slots","title","TransitionComponent","TransitionProps"];function om(e){return Math.round(e*1e5)/1e5}const am=e=>{const{classes:t,disableInteractive:n,arrow:r,touch:o,placement:s}=e,i={popper:["popper",!n&&"popperInteractive",r&&"popperArrow"],tooltip:["tooltip",r&&"tooltipArrow",o&&"touch",`tooltipPlacement${Ye(s.split("-")[0])}`],arrow:["arrow"]};return To(i,tm,t)},sm=In(zi,{name:"MuiTooltip",slot:"Popper",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.popper,!n.disableInteractive&&t.popperInteractive,n.arrow&&t.popperArrow,!n.open&&t.popperClose]}})(({theme:e,ownerState:t,open:n})=>O({zIndex:(e.vars||e).zIndex.tooltip,pointerEvents:"none"},!t.disableInteractive&&{pointerEvents:"auto"},!n&&{pointerEvents:"none"},t.arrow&&{[`&[data-popper-placement*="bottom"] .${at.arrow}`]:{top:0,marginTop:"-0.71em","&::before":{transformOrigin:"0 100%"}},[`&[data-popper-placement*="top"] .${at.arrow}`]:{bottom:0,marginBottom:"-0.71em","&::before":{transformOrigin:"100% 0"}},[`&[data-popper-placement*="right"] .${at.arrow}`]:O({},t.isRtl?{right:0,marginRight:"-0.71em"}:{left:0,marginLeft:"-0.71em"},{height:"1em",width:"0.71em","&::before":{transformOrigin:"100% 100%"}}),[`&[data-popper-placement*="left"] .${at.arrow}`]:O({},t.isRtl?{left:0,marginLeft:"-0.71em"}:{right:0,marginRight:"-0.71em"},{height:"1em",width:"0.71em","&::before":{transformOrigin:"0 0"}})})),im=In("div",{name:"MuiTooltip",slot:"Tooltip",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.tooltip,n.touch&&t.touch,n.arrow&&t.tooltipArrow,t[`tooltipPlacement${Ye(n.placement.split("-")[0])}`]]}})(({theme:e,ownerState:t})=>O({backgroundColor:e.vars?e.vars.palette.Tooltip.bg:yi(e.palette.grey[700],.92),borderRadius:(e.vars||e).shape.borderRadius,color:(e.vars||e).palette.common.white,fontFamily:e.typography.fontFamily,padding:"4px 8px",fontSize:e.typography.pxToRem(11),maxWidth:300,margin:2,wordWrap:"break-word",fontWeight:e.typography.fontWeightMedium},t.arrow&&{position:"relative",margin:0},t.touch&&{padding:"8px 16px",fontSize:e.typography.pxToRem(14),lineHeight:`${om(16/14)}em`,fontWeight:e.typography.fontWeightRegular},{[`.${at.popper}[data-popper-placement*="left"] &`]:O({transformOrigin:"right center"},t.isRtl?O({marginLeft:"14px"},t.touch&&{marginLeft:"24px"}):O({marginRight:"14px"},t.touch&&{marginRight:"24px"})),[`.${at.popper}[data-popper-placement*="right"] &`]:O({transformOrigin:"left center"},t.isRtl?O({marginRight:"14px"},t.touch&&{marginRight:"24px"}):O({marginLeft:"14px"},t.touch&&{marginLeft:"24px"})),[`.${at.popper}[data-popper-placement*="top"] &`]:O({transformOrigin:"center bottom",marginBottom:"14px"},t.touch&&{marginBottom:"24px"}),[`.${at.popper}[data-popper-placement*="bottom"] &`]:O({transformOrigin:"center top",marginTop:"14px"},t.touch&&{marginTop:"24px"})})),lm=In("span",{name:"MuiTooltip",slot:"Arrow",overridesResolver:(e,t)=>t.arrow})(({theme:e})=>({overflow:"hidden",position:"absolute",width:"1em",height:"0.71em",boxSizing:"border-box",color:e.vars?e.vars.palette.Tooltip.bg:yi(e.palette.grey[700],.9),"&::before":{content:'""',margin:"auto",display:"block",width:"100%",height:"100%",backgroundColor:"currentColor",transform:"rotate(45deg)"}}));let Gn=!1;const ts=new On;let sn={x:0,y:0};function Un(e,t){return n=>{t&&t(n),e(n)}}const Li=M.forwardRef(function(t,n){var r,o,s,i,l,c,d,u,h,w,b,x,f,m,S,R,j,E,v;const P=Do({props:t,name:"MuiTooltip"}),{arrow:V=!1,children:U,components:C={},componentsProps:_={},describeChild:k=!1,disableFocusListener:A=!1,disableHoverListener:$=!1,disableInteractive:J=!1,disableTouchListener:Y=!1,enterDelay:F=100,enterNextDelay:te=0,enterTouchDelay:se=700,followCursor:oe=!1,id:y,leaveDelay:T=0,leaveTouchDelay:z=1500,onClose:L,onOpen:B,open:X,placement:q="bottom",PopperComponent:H,PopperProps:G={},slotProps:K={},slots:Z={},title:ue,TransitionComponent:I=es,TransitionProps:ye}=P,D=Ne(P,rm),xe=M.isValidElement(U)?U:a.jsx("span",{children:U}),Ge=Di(),lt=Ge.direction==="rtl",[Ee,An]=M.useState(),[Ue,Et]=M.useState(null),ct=M.useRef(!1),jt=J||oe,Ct=dn(),Tt=dn(),dt=dn(),Jt=dn(),[Dn,Yo]=di({controlled:X,default:!1,name:"Tooltip",state:"open"});let Ke=Dn;if(process.env.NODE_ENV!=="production"){const{current:ee}=M.useRef(X!==void 0);M.useEffect(()=>{Ee&&Ee.disabled&&!ee&&ue!==""&&Ee.tagName.toLowerCase()==="button"&&console.error(["MUI: You are providing a disabled `button` child to the Tooltip component.","A disabled element does not fire events.","Tooltip needs to listen to the child element's events to display the title.","","Add a simple wrapper element, such as a `span`."].join(` +`))},[ue,Ee,ee])}const kr=ci(y),Zt=M.useRef(),Bn=Zr(()=>{Zt.current!==void 0&&(document.body.style.WebkitUserSelect=Zt.current,Zt.current=void 0),Jt.clear()});M.useEffect(()=>Bn,[Bn]);const Wo=ee=>{ts.clear(),Gn=!0,Yo(!0),B&&!Ke&&B(ee)},Vn=Zr(ee=>{ts.start(800+T,()=>{Gn=!1}),Yo(!1),L&&Ke&&L(ee),Ct.start(Ge.transitions.duration.shortest,()=>{ct.current=!1})}),Sr=ee=>{ct.current&&ee.type!=="touchstart"||(Ee&&Ee.removeAttribute("title"),Tt.clear(),dt.clear(),F||Gn&&te?Tt.start(Gn?te:F,()=>{Wo(ee)}):Wo(ee))},Ko=ee=>{Tt.clear(),dt.start(T,()=>{Vn(ee)})},{isFocusVisibleRef:Jo,onBlur:rl,onFocus:ol,ref:al}=ui(),[,Zo]=M.useState(!1),Qo=ee=>{rl(ee),Jo.current===!1&&(Zo(!1),Ko(ee))},ea=ee=>{Ee||An(ee.currentTarget),ol(ee),Jo.current===!0&&(Zo(!0),Sr(ee))},ta=ee=>{ct.current=!0;const _e=xe.props;_e.onTouchStart&&_e.onTouchStart(ee)},na=Sr,ra=Ko,sl=ee=>{ta(ee),dt.clear(),Ct.clear(),Bn(),Zt.current=document.body.style.WebkitUserSelect,document.body.style.WebkitUserSelect="none",Jt.start(se,()=>{document.body.style.WebkitUserSelect=Zt.current,Sr(ee)})},il=ee=>{xe.props.onTouchEnd&&xe.props.onTouchEnd(ee),Bn(),dt.start(z,()=>{Vn(ee)})};M.useEffect(()=>{if(!Ke)return;function ee(_e){(_e.key==="Escape"||_e.key==="Esc")&&Vn(_e)}return document.addEventListener("keydown",ee),()=>{document.removeEventListener("keydown",ee)}},[Vn,Ke]);const ll=yt(xe.ref,al,An,n);!ue&&ue!==0&&(Ke=!1);const Er=M.useRef(),cl=ee=>{const _e=xe.props;_e.onMouseMove&&_e.onMouseMove(ee),sn={x:ee.clientX,y:ee.clientY},Er.current&&Er.current.update()},Qt={},jr=typeof ue=="string";k?(Qt.title=!Ke&&jr&&!$?ue:null,Qt["aria-describedby"]=Ke?kr:null):(Qt["aria-label"]=jr?ue:null,Qt["aria-labelledby"]=Ke&&!jr?kr:null);const Ae=O({},Qt,D,xe.props,{className:ot(D.className,xe.props.className),onTouchStart:ta,ref:ll},oe?{onMouseMove:cl}:{});process.env.NODE_ENV!=="production"&&(Ae["data-mui-internal-clone-element"]=!0,M.useEffect(()=>{Ee&&!Ee.getAttribute("data-mui-internal-clone-element")&&console.error(["MUI: The `children` component of the Tooltip is not forwarding its props correctly.","Please make sure that props are spread on the same element that the ref is applied to."].join(` +`))},[Ee]));const en={};Y||(Ae.onTouchStart=sl,Ae.onTouchEnd=il),$||(Ae.onMouseOver=Un(na,Ae.onMouseOver),Ae.onMouseLeave=Un(ra,Ae.onMouseLeave),jt||(en.onMouseOver=na,en.onMouseLeave=ra)),A||(Ae.onFocus=Un(ea,Ae.onFocus),Ae.onBlur=Un(Qo,Ae.onBlur),jt||(en.onFocus=ea,en.onBlur=Qo)),process.env.NODE_ENV!=="production"&&xe.props.title&&console.error(["MUI: You have provided a `title` prop to the child of .",`Remove this title prop \`${xe.props.title}\` or the Tooltip component.`].join(` +`));const dl=M.useMemo(()=>{var ee;let _e=[{name:"arrow",enabled:!!Ue,options:{element:Ue,padding:4}}];return(ee=G.popperOptions)!=null&&ee.modifiers&&(_e=_e.concat(G.popperOptions.modifiers)),O({},G.popperOptions,{modifiers:_e})},[Ue,G]),tn=O({},P,{isRtl:lt,arrow:V,disableInteractive:jt,placement:q,PopperComponentProp:H,touch:ct.current}),Cr=am(tn),oa=(r=(o=Z.popper)!=null?o:C.Popper)!=null?r:sm,aa=(s=(i=(l=Z.transition)!=null?l:C.Transition)!=null?i:I)!=null?s:es,sa=(c=(d=Z.tooltip)!=null?d:C.Tooltip)!=null?c:im,ia=(u=(h=Z.arrow)!=null?h:C.Arrow)!=null?u:lm,ul=un(oa,O({},G,(w=K.popper)!=null?w:_.popper,{className:ot(Cr.popper,G==null?void 0:G.className,(b=(x=K.popper)!=null?x:_.popper)==null?void 0:b.className)}),tn),pl=un(aa,O({},ye,(f=K.transition)!=null?f:_.transition),tn),wl=un(sa,O({},(m=K.tooltip)!=null?m:_.tooltip,{className:ot(Cr.tooltip,(S=(R=K.tooltip)!=null?R:_.tooltip)==null?void 0:S.className)}),tn),fl=un(ia,O({},(j=K.arrow)!=null?j:_.arrow,{className:ot(Cr.arrow,(E=(v=K.arrow)!=null?v:_.arrow)==null?void 0:E.className)}),tn);return a.jsxs(M.Fragment,{children:[M.cloneElement(xe,Ae),a.jsx(oa,O({as:H??zi,placement:q,anchorEl:oe?{getBoundingClientRect:()=>({top:sn.y,left:sn.x,right:sn.x,bottom:sn.y,width:0,height:0})}:Ee,popperRef:Er,open:Ee?Ke:!1,id:kr,transition:!0},en,ul,{popperOptions:dl,children:({TransitionProps:ee})=>a.jsx(aa,O({timeout:Ge.transitions.duration.shorter},ee,pl,{children:a.jsxs(sa,O({},wl,{children:[ue,V?a.jsx(ia,O({},fl,{ref:Et})):null]}))}))}))]})});process.env.NODE_ENV!=="production"&&(Li.propTypes={arrow:p.bool,children:si.isRequired,classes:p.object,className:p.string,components:p.shape({Arrow:p.elementType,Popper:p.elementType,Tooltip:p.elementType,Transition:p.elementType}),componentsProps:p.shape({arrow:p.object,popper:p.object,tooltip:p.object,transition:p.object}),describeChild:p.bool,disableFocusListener:p.bool,disableHoverListener:p.bool,disableInteractive:p.bool,disableTouchListener:p.bool,enterDelay:p.number,enterNextDelay:p.number,enterTouchDelay:p.number,followCursor:p.bool,id:p.string,leaveDelay:p.number,leaveTouchDelay:p.number,onClose:p.func,onOpen:p.func,open:p.bool,placement:p.oneOf(["bottom-end","bottom-start","bottom","left-end","left-start","left","right-end","right-start","right","top-end","top-start","top"]),PopperComponent:p.elementType,PopperProps:p.object,slotProps:p.shape({arrow:p.object,popper:p.object,tooltip:p.object,transition:p.object}),slots:p.shape({arrow:p.elementType,popper:p.elementType,tooltip:p.elementType,transition:p.elementType}),sx:p.oneOfType([p.arrayOf(p.oneOfType([p.func,p.object,p.bool])),p.func,p.object]),title:p.node,TransitionComponent:p.elementType,TransitionProps:p.object});const cm=Li;function ns(e,t,n){return e?a.jsx(Me.ListItemIcon,{className:`papi-menu-icon-${n?"leading":"trailing"}`,children:a.jsx("img",{src:e,alt:`${n?"Leading":"Trailing"} icon for ${t}`})}):void 0}function Xo(e){const{onClick:t,label:n,tooltip:r,allowForLeadingIcons:o=!0,iconPathBefore:s=void 0,iconPathAfter:i=void 0,hasAutoFocus:l=!1,className:c,isDisabled:d=!1,isDense:u=!0,isSubMenuParent:h=!1,hasDisabledGutters:w=!1,hasDivider:b=!1,focusVisibleClassName:x,id:f,children:m}=e,S=a.jsx(Me.MenuItem,{sx:{lineHeight:.8},autoFocus:l,className:c,disabled:d,dense:u,disableGutters:w,divider:b,focusVisibleClassName:x,onClick:t,id:f,children:n?a.jsxs(a.Fragment,{children:[ns(s,n,!0),a.jsx(Me.ListItemText,{primary:n,inset:!s&&o}),h?a.jsx(Me.ListItemIcon,{className:"papi-menu-icon-trailing",children:a.jsx(ki,{})}):ns(i,n,!1)]}):m});return r?a.jsx(cm,{title:r,placement:"right",children:a.jsx("div",{children:S})}):S}function Fi(e){return Object.entries(e.groups).map(([n,r])=>({id:n,group:r}))}function dm(e){const[t,n]=g.useState(void 0),{parentMenuItem:r,parentItemProps:o,menuDefinition:s}=e,i=d=>{n(d.currentTarget)},l=()=>{n(void 0)},c=()=>{let d=Fi(s).filter(u=>"menuItem"in u.group);if(!(r!=null&&r.id))throw new Error("A valid parent menu item is required for submenus.");return d=d.filter(u=>"menuItem"in u.group&&u.group.menuItem===r.id),a.jsx(Gi,{...e,includedGroups:d})};return a.jsxs(a.Fragment,{children:[a.jsx(Xo,{onClick:i,...o,isSubMenuParent:!0}),a.jsx(Me.Menu,{anchorEl:t,open:!!t,onClose:l,anchorOrigin:{vertical:"top",horizontal:"right"},transformOrigin:{vertical:"top",horizontal:"left"},children:c()},r.id)]})}const um=(e,t)=>t.filter(o=>o.group===e).sort((o,s)=>(o.order||0)-(s.order||0));function Gi(e){const{menuDefinition:t,onClick:n,commandHandler:r,includedGroups:o}=e,{items:s,allowForLeadingIcons:i}=g.useMemo(()=>{const u=o&&o.length>0?o:Fi(t).filter(x=>!("menuItem"in x.group)),h=Object.values(u).sort((x,f)=>(x.group.order||0)-(f.group.order||0)),w=[];h.forEach(x=>{um(x.id,t.items).forEach(f=>w.push({item:f,isLastItemInGroup:!1})),w.length>0&&(w[w.length-1].isLastItemInGroup=!0)}),w.length>0&&(w[w.length-1].isLastItemInGroup=!1);const b=w.some(x=>"iconPathBefore"in x.item&&x.item.iconPathBefore);return{items:w,allowForLeadingIcons:b}},[o,t]),l=({item:u,isLastItemInGroup:h})=>({className:"papi-menu-item",label:u.label,tooltip:u.tooltip,iconPathBefore:"iconPathBefore"in u?u.iconPathBefore:void 0,iconPathAfter:"iconPathAfter"in u?u.iconPathAfter:void 0,hasDivider:h,allowForLeadingIcons:i}),[c]=s;if(!c)return a.jsx("div",{});const d=c.item.group;return a.jsx("div",{role:"menu","aria-label":d,children:s.map((u,h)=>{const{item:w}=u,b=l(u);if("command"in w){const x=w.group+h;return a.jsx(Xo,{onClick:f=>{n==null||n(f),r(w)},...b},x)}return a.jsx(dm,{parentMenuItem:w,parentItemProps:b,...e},d+w.id)})},d)}function pm(e){const{menuDefinition:t,columnId:n}=e;let s=Object.entries(t.groups).map(([i,l])=>({id:i,group:l})).filter(i=>"column"in i.group);return n&&"columns"in t&&t.columns[n]&&(s=s.filter(i=>"column"in i.group&&i.group.column===n)),a.jsx(Gi,{...e,includedGroups:s})}function wm({commandHandler:e,menuDefinition:t,id:n,metadata:r,onClick:o,className:s}){return a.jsxs(Me.Grid,{id:n,item:!0,xs:"auto",role:"menu","aria-label":n,className:`papi-menu-column ${s??""}`,children:[a.jsx("h3",{"aria-label":r.label,className:`papi-menu-column-header ${s??""}`,children:r.label}),a.jsx(Me.List,{id:n,dense:!0,className:s??"",children:a.jsx(pm,{commandHandler:e,menuDefinition:t,columnId:n,onClick:o})})]})}function Ui({commandHandler:e,className:t,multiColumnMenu:n,id:r}){const{columns:o}=n,s=g.useMemo(()=>{const i=new Map;return Object.getOwnPropertyNames(o).forEach(l=>{if(l==="isExtensible")return;const c=l,d=o[c];typeof d=="object"&&typeof d.order=="number"&&!Number.isNaN(d.order)?i.set(d.order,{id:c,metadata:d}):console.warn(`Property ${l} (${typeof d}) on menu ${r} is not a valid column and is being ignored. This might indicate data corruption`)}),Array.from(i.values()).sort((l,c)=>(l.metadata.order||0)-(c.metadata.order||0))},[o,r]);return a.jsx(Me.Grid,{container:!0,spacing:0,className:`papi-multi-column-menu ${t??""}`,columns:s.length,role:"menu","aria-label":"GridMenu",id:r,children:s.map((i,l)=>a.jsx(wm,{commandHandler:e,menuDefinition:n,...i,className:t},l))})}function fm(e){return{preserveValue:!0,...e}}const nr=(e,t,n={})=>{const r=g.useRef(t);r.current=t;const o=g.useRef(n);o.current=fm(o.current);const[s,i]=g.useState(()=>r.current),[l,c]=g.useState(!0);return g.useEffect(()=>{let d=!0;return c(!!e),(async()=>{if(e){const u=await e();d&&(i(()=>u),c(!1))}})(),()=>{d=!1,o.current.preserveValue||i(()=>r.current)}},[e]),[s,l]},mm=Ni(a.jsx("path",{d:"M3 18h18v-2H3zm0-5h18v-2H3zm0-7v2h18V6z"}),"Menu");function qi({menuProvider:e,normalMenu:t,fullMenu:n,commandHandler:r,containerRef:o,className:s,ariaLabelPrefix:i,children:l}){const[c,d]=g.useState(!1),[u,h]=g.useState(!1),w=g.useCallback(()=>{c&&d(!1),h(!1)},[c]),b=g.useCallback(E=>{E.stopPropagation(),d(v=>{const P=!v;return P&&E.shiftKey?h(!0):P||h(!1),P})},[]),x=g.useCallback(E=>(w(),r(E)),[r,w]),[f,m]=g.useState({top:1,left:1});g.useEffect(()=>{if(c){const E=o==null?void 0:o.current;if(E){const v=E.getBoundingClientRect(),P=window.scrollY,V=window.scrollX,U=v.top+P+E.clientHeight,C=v.left+V;m({top:U,left:C})}}},[c,o]);const[S]=nr(g.useCallback(async()=>(e==null?void 0:e(!1))??t,[e,t,c]),t),[R]=nr(g.useCallback(async()=>(e==null?void 0:e(!0))??n??S,[e,n,S,c]),n??S),j=u&&R?R:S;return a.jsxs(a.Fragment,{children:[a.jsx(Me.IconButton,{sx:{paddingTop:0,paddingBottom:0},edge:"start",className:`papi-menuButton ${s??""}`,color:"inherit","aria-label":`${i??""} menu button`,onClick:b,children:l??a.jsx(mm,{})}),a.jsx(Me.Drawer,{className:`papi-menu-drawer ${s??""}`,anchor:"left",variant:"temporary",open:c,onClose:w,PaperProps:{className:"papi-menu-drawer-paper",style:{top:f.top,left:f.left}},children:j?a.jsx(Ui,{className:s,id:`${i??""} main menu`,commandHandler:x,multiColumnMenu:j}):void 0})]})}function hm({id:e,label:t,isDisabled:n=!1,tooltip:r,isTooltipSuppressed:o=!1,adjustMarginToAlignToEdge:s=!1,size:i="medium",className:l,onClick:c,children:d}){return a.jsx(Me.IconButton,{id:e,disabled:n,edge:s,size:i,"aria-label":t,title:o?void 0:r??t,className:`papi-icon-button ${l??""}`,onClick:c,children:d})}const Kt=g.forwardRef(({className:e,...t},n)=>a.jsx(Q.LoaderCircle,{size:35,className:N("tw-animate-spin",e),...t,ref:n}));Kt.displayName="Spinner";function gm({id:e,isDisabled:t=!1,hasError:n=!1,isFullWidth:r=!1,helperText:o,label:s,placeholder:i,isRequired:l=!1,className:c,defaultValue:d,value:u,onChange:h,onFocus:w,onBlur:b}){return a.jsxs("div",{className:N("tw-inline-grid tw-items-center tw-gap-1.5",{"tw-w-full":r}),children:[a.jsx(qe,{htmlFor:e,className:N({"tw-text-red-600":n,"tw-hidden":!s}),children:`${s}${l?"*":""}`}),a.jsx(St,{id:e,disabled:t,placeholder:i,required:l,className:N(c,{"tw-border-red-600":n}),defaultValue:d,value:u,onChange:h,onFocus:w,onBlur:b}),a.jsx("p",{className:N({"tw-hidden":!o}),children:o})]})}function bm({menuProvider:e,commandHandler:t,className:n,id:r,children:o}){const s=g.useRef(void 0);return a.jsx("div",{ref:s,style:{position:"relative"},children:a.jsx(Me.AppBar,{position:"static",id:r,children:a.jsxs(Me.Toolbar,{className:N("tw-bg-muted tw-text-muted-foreground",n),variant:"dense",children:[e?a.jsx(qi,{commandHandler:t,containerRef:s,menuProvider:e}):void 0,o?a.jsx("div",{className:"papi-toolbar-children",children:o}):void 0]})})})}const vm=Xt.cva("tw-relative tw-w-full tw-rounded-lg tw-border tw-p-4 [&>svg~*]:tw-pl-7 [&>svg+div]:tw-translate-y-[-3px] [&>svg]:tw-absolute [&>svg]:tw-left-4 [&>svg]:tw-top-4 [&>svg]:tw-text-foreground",{variants:{variant:{default:"tw-bg-background tw-text-foreground",destructive:"tw-border-destructive/50 tw-text-destructive dark:tw-border-destructive [&>svg]:tw-text-destructive"}},defaultVariants:{variant:"default"}}),Hi=g.forwardRef(({className:e,variant:t,...n},r)=>a.jsx("div",{ref:r,role:"alert",className:N(vm({variant:t}),e),...n}));Hi.displayName="Alert";const Xi=g.forwardRef(({className:e,...t},n)=>a.jsxs("h5",{ref:n,className:N("tw-mb-1 tw-font-medium tw-leading-none tw-tracking-tight",e),...t,children:[t.children," "]}));Xi.displayName="AlertTitle";const Yi=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,className:N("tw-text-sm [&_p]:tw-leading-relaxed",e),...t}));Yi.displayName="AlertDescription";function xm({...e}){return a.jsx(os.Toaster,{className:"tw-toaster tw-group",toastOptions:{classNames:{toast:"group toast group-[.toaster]:bg-background group-[.toaster]:text-foreground group-[.toaster]:border-border group-[.toaster]:shadow-lg",description:"group-[.toast]:text-muted-foreground",actionButton:"group-[.toast]:bg-primary group-[.toast]:text-primary-foreground",cancelButton:"group-[.toast]:bg-muted group-[.toast]:text-muted-foreground"}},...e})}const Wi=g.forwardRef(({className:e,...t},n)=>a.jsxs(cn.Root,{ref:n,className:N("pr-twp tw-relative tw-flex tw-w-full tw-touch-none tw-select-none tw-items-center",e),...t,children:[a.jsx(cn.Track,{className:"tw-relative tw-h-2 tw-w-full tw-grow tw-overflow-hidden tw-rounded-full tw-bg-secondary",children:a.jsx(cn.Range,{className:"tw-absolute tw-h-full tw-bg-primary"})}),a.jsx(cn.Thumb,{className:"tw-block tw-h-5 tw-w-5 tw-rounded-full tw-border-2 tw-border-primary tw-bg-background tw-ring-offset-background tw-transition-colors focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50"})]}));Wi.displayName=cn.Root.displayName;const Ki=g.forwardRef(({className:e,...t},n)=>a.jsx(qr.Root,{className:N("tw-peer pr-twp tw-inline-flex tw-h-6 tw-w-11 tw-shrink-0 tw-cursor-pointer tw-items-center tw-rounded-full tw-border-2 tw-border-transparent tw-transition-colors focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 focus-visible:tw-ring-offset-background disabled:tw-cursor-not-allowed disabled:tw-opacity-50 data-[state=checked]:tw-bg-primary data-[state=unchecked]:tw-bg-input",e),...t,ref:n,children:a.jsx(qr.Thumb,{className:N("pr-twp tw-pointer-events-none tw-block tw-h-5 tw-w-5 tw-rounded-full tw-bg-background tw-shadow-lg tw-ring-0 tw-transition-transform data-[state=checked]:tw-translate-x-5 data-[state=unchecked]:tw-translate-x-0")})}));Ki.displayName=qr.Root.displayName;const ym=Oe.Root,Ji=g.forwardRef(({className:e,...t},n)=>a.jsx(Oe.List,{ref:n,className:N("tw-inline-flex tw-h-10 tw-items-center tw-justify-center tw-rounded-md tw-bg-muted tw-p-1 tw-text-muted-foreground",e),...t}));Ji.displayName=Oe.List.displayName;const Zi=g.forwardRef(({className:e,...t},n)=>a.jsx(Oe.Trigger,{ref:n,className:N("tw-inline-flex tw-items-center tw-justify-center tw-whitespace-nowrap tw-rounded-sm tw-px-3 tw-py-1.5 tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-all hover:tw-text-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50 data-[state=active]:tw-bg-background data-[state=active]:tw-text-foreground data-[state=active]:tw-shadow-sm",e),...t}));Zi.displayName=Oe.Trigger.displayName;const Qi=g.forwardRef(({className:e,...t},n)=>a.jsx(Oe.Content,{ref:n,className:N("tw-mt-2 tw-ring-offset-background focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2",e),...t}));Qi.displayName=Oe.Content.displayName;function Nm({isInstalling:e,handleClick:t,buttonText:n,className:r,...o}){return a.jsx(fe,{className:N("tw-h-8 tw-rounded-md tw-text-white tw-transition tw-duration-300 tw-ease-in-out hover:tw-bg-blue-700",{"tw-cursor-not-allowed tw-bg-blue-700":e,"tw-bg-blue-600":!e,"tw-bg-white tw-text-blue-600 hover:tw-text-white":!n,"tw-w-20":n},r),onClick:t,...o,children:e?a.jsx(Kt,{size:15}):a.jsxs(a.Fragment,{children:[a.jsx(Q.Download,{size:25,className:N("tw-h-4 tw-w-4",{"tw-mr-1":n})}),n]})})}function km({isEnabling:e,handleClick:t,className:n,...r}){return a.jsx(fe,{className:N("tw-h-8 tw-rounded-md tw-bg-blue-600 tw-px-4 tw-text-white tw-transition tw-duration-300 tw-ease-in-out hover:tw-bg-blue-700",{"tw-cursor-not-allowed tw-bg-blue-700":e},n),onClick:t,...r,children:e?a.jsxs(a.Fragment,{children:[a.jsx(Kt,{size:15,className:"tw-mr-1 tw-text-white"}),"Enabling..."]}):"Enable"})}function Sm({isDisabling:e,handleClick:t,className:n,...r}){return a.jsx(fe,{className:N("tw-h-8 tw-rounded-md tw-bg-gray-300 tw-text-black tw-transition tw-duration-300 tw-ease-in-out hover:tw-bg-gray-400",{"tw-cursor-not-allowed tw-bg-gray-400":e},n),onClick:t,...r,children:e?a.jsxs(a.Fragment,{children:[a.jsx(Kt,{size:15,className:"tw-mr-1 tw-text-black"}),"Disabling..."]}):"Disable"})}function Em({isUpdating:e,handleClick:t,className:n,...r}){return a.jsx(fe,{className:N("tw-h-8 tw-rounded-md tw-bg-blue-600 tw-px-4 tw-text-white tw-transition tw-duration-300 tw-ease-in-out hover:tw-bg-blue-700 hover:tw-text-white",{"tw-cursor-not-allowed tw-bg-blue-700":e},n),onClick:t,...r,children:e?a.jsxs(a.Fragment,{children:[a.jsx(Kt,{size:15,className:"tw-mr-1 tw-text-white"}),"Updating..."]}):"Update"})}function jm({id:e,markdown:t,className:n,anchorTarget:r}){const o=g.useMemo(()=>({overrides:{a:{props:{target:r}}}}),[r]);return a.jsx("div",{id:e,className:N("pr-twp tw-prose",n),children:a.jsx(Rl,{options:o,children:t})})}const el=g.forwardRef((e,t)=>a.jsxs(fe,{ref:t,className:"tw-rounded-md tw-border tw-border-dashed tw-border-gray-400 tw-bg-white tw-px-4 tw-py-2 tw-text-black tw-transition tw-duration-300 tw-ease-in-out hover:tw-border-blue-600 hover:tw-bg-white hover:tw-text-blue-600",...e,children:[a.jsx(Q.Filter,{size:16,className:"tw-mr-2 tw-h-4 tw-w-4 tw-text-gray-700 hover:tw-text-blue-600"}),"Filter",a.jsx(Q.ChevronDown,{size:16,className:"tw-ml-2 tw-h-4 tw-w-4 tw-text-gray-700 hover:tw-text-blue-600"})]}));var tl=(e=>(e[e.Check=0]="Check",e[e.Radio=1]="Radio",e))(tl||{});function Cm({id:e,groups:t}){return a.jsx("div",{id:e,children:a.jsxs(or,{children:[a.jsx(lo,{asChild:!0,children:a.jsx(el,{})}),a.jsx(En,{children:t.map(n=>a.jsxs("div",{children:[a.jsx(Wt,{children:n.label}),a.jsx(fs,{children:n.items.map(r=>a.jsx("div",{children:r.itemType===0?a.jsx(ar,{onClick:r.onClick,children:r.label}):a.jsx(uo,{onClick:r.onClick,value:r.label,children:r.label})},r.label))}),a.jsx(jn,{})]},n.label))})]})})}function Tm({id:e,message:t}){return a.jsx("div",{id:e,className:"tw-mb-20 tw-mt-20 tw-flex tw-items-center tw-justify-center",children:a.jsx("div",{className:"tw-w-3/4 tw-rounded-lg tw-bg-gray-100 tw-p-8 tw-text-center",children:a.jsx("p",{className:"tw-text-lg tw-text-gray-800",children:t})})})}function Rm({id:e,category:t,downloads:n,languages:r,moreInfoUrl:o}){const s=new W.NumberFormat("en",{notation:"compact",compactDisplay:"short"}).format(Object.values(n).reduce((l,c)=>l+c,0)),i=()=>{window.scrollTo(0,document.body.scrollHeight)};return a.jsxs("div",{id:e,className:"tw-flex tw-flex-wrap tw-items-start tw-space-x-4 tw-border-b tw-border-t tw-bg-white tw-pb-4 tw-pt-4",children:[a.jsxs("div",{className:"tw-flex tw-flex-col tw-items-center",children:[a.jsx("div",{className:"tw-flex tw-items-center tw-rounded-md tw-bg-gray-100 tw-px-2 tw-py-1",children:a.jsx("span",{className:"tw-text-xs tw-font-semibold tw-text-gray-700",children:t})}),a.jsx("span",{className:"tw-text-xs tw-text-gray-500",children:"CATEGORY"})]}),a.jsx("div",{className:"tw-mx-2 tw-h-10 tw-border-l tw-border-gray-300"}),a.jsxs("div",{className:"tw-flex tw-flex-col tw-items-center",children:[a.jsxs("div",{className:"tw-flex tw-items-center tw-rounded-md tw-bg-gray-100 tw-px-2 tw-py-1",children:[a.jsx(Q.User,{className:"tw-mr-1 tw-h-4 tw-w-4"}),a.jsx("span",{className:"tw-text-xs tw-font-semibold tw-text-gray-700",children:s})]}),a.jsx("span",{className:"tw-text-xs tw-text-gray-500",children:"USERS"})]}),a.jsx("div",{className:"tw-mx-2 tw-h-10 tw-border-l tw-border-gray-300"}),a.jsxs("div",{className:"tw-flex tw-flex-col tw-items-center",children:[a.jsx("div",{className:"tw-flex tw-items-center",children:r.slice(0,3).map(l=>a.jsx("span",{className:"tw-ml-1 tw-rounded-md tw-bg-gray-100 tw-px-2 tw-py-1 tw-text-xs tw-font-semibold tw-text-gray-700",children:l.toUpperCase()},l))}),r.length>3&&a.jsxs("button",{type:"button",onClick:()=>i(),className:"tw-text-xs tw-text-gray-500 tw-underline",children:["+",r.length-3," more languages"]})]}),a.jsx("div",{className:"tw-mx-2 tw-h-10 tw-border-l tw-border-gray-300"}),a.jsxs("div",{className:"tw-ml-auto tw-flex tw-flex-col tw-space-y-2",children:[a.jsxs("a",{href:o,target:"_blank",rel:"noreferrer",className:"tw-flex tw-items-center tw-text-xs tw-font-semibold tw-text-gray-500 tw-underline",children:["Website",a.jsx(Q.Link,{className:"tw-ml-1 tw-inline tw-h-4 tw-w-4"})]}),a.jsxs("a",{href:"https://example.com",target:"_blank",rel:"noreferrer",className:"tw-flex tw-items-center tw-text-xs tw-font-semibold tw-text-gray-500 tw-underline",children:["Support",a.jsx(Q.CircleHelp,{className:"tw-ml-1 tw-inline tw-h-4 tw-w-4"})]})]})]})}function nl({id:e,versionHistory:t}){const[n,r]=g.useState(!1),o=new Date;function s(l){const c=new Date(l),d=new Date(o.getTime()-c.getTime()),u=d.getUTCFullYear()-1970,h=d.getUTCMonth(),w=d.getUTCDate()-1;let b="";return u>0?b=`${u.toString()} year${u===1?"":"s"} ago`:h>0?b=`${h.toString()} month${h===1?"":"s"} ago`:w===0?b="today":b=`${w.toString()} day${w===1?"":"s"} ago`,b}const i=Object.entries(t).sort((l,c)=>c[0].localeCompare(l[0]));return a.jsxs("div",{id:e,children:[a.jsx("h3",{className:"tw-text-md tw-font-semibold",children:"What`s New"}),a.jsx("ul",{className:"tw-list-disc tw-pl-5 tw-pr-4 tw-text-xs tw-text-gray-600",children:(n?i:i.slice(0,5)).map(l=>a.jsxs("div",{className:"tw-mt-3 tw-flex tw-justify-between",children:[a.jsx("div",{className:"tw-text-gray-600",children:a.jsx("li",{className:"tw-prose tw-text-xs",children:a.jsx("span",{children:l[1].description})})}),a.jsxs("div",{className:"tw-justify-end tw-text-right",children:[a.jsxs("div",{children:["Version ",l[0]]}),a.jsx("div",{children:s(l[1].date)})]})]},l[0]))}),i.length>5&&a.jsx("button",{type:"button",onClick:()=>r(!n),className:"tw-text-xs tw-text-gray-500 tw-underline",children:n?"Show Less Version History":"Show All Version History"})]})}function Om({id:e,publisherDisplayName:t,fileSize:n,locales:r,versionHistory:o}){const s=g.useMemo(()=>W.formatBytes(n),[n]),l=(c=>{const d=new Intl.DisplayNames(navigator.language,{type:"language"});return c.map(u=>d.of(u))})(r);return a.jsx("div",{id:e,className:"tw-border-t tw-pb-4 tw-pt-4",children:a.jsxs("div",{className:"tw-md:flex-row tw-md:space-x-8 tw-flex tw-flex-col tw-space-x-0",children:[a.jsx(nl,{versionHistory:o}),a.jsx("div",{className:"tw-md:border-t-0 tw-md:border-l tw-md-h-auto tw-md-ml-8 tw-mt-4 tw-border-t tw-border-gray-300"}),a.jsxs("div",{className:"tw-md:mt-0 tw-mt-4 tw-flex-1 tw-space-y-3",children:[a.jsx("h2",{className:"tw-text-md tw-font-semibold",children:"Information"}),a.jsxs("div",{className:"tw-flex tw-items-start tw-justify-between tw-pr-4 tw-text-xs tw-text-gray-600",children:[a.jsxs("p",{className:"tw-flex tw-flex-col tw-justify-start",children:[a.jsx("span",{className:"tw-mb-2",children:"Publisher"}),a.jsx("span",{className:"tw-font-semibold",children:t}),a.jsx("span",{className:"tw-mb-2 tw-mt-4",children:"Size"}),a.jsx("span",{className:"tw-font-semibold",children:s})]}),a.jsx("div",{className:"tw-flex tw-w-3/4 tw-items-center tw-justify-between tw-text-xs tw-text-gray-600",children:a.jsxs("p",{className:"tw-flex tw-flex-col tw-justify-start",children:[a.jsx("span",{className:"tw-mb-2",children:"Languages"}),a.jsx("span",{className:"tw-font-semibold",children:l.join(", ")})]})})]})]})]})})}const _m=(e,t)=>{g.useEffect(()=>{if(!e)return()=>{};const n=e(t);return()=>{n()}},[e,t])},Fr=()=>!1,Pm=(e,t)=>{const[n]=nr(g.useCallback(async()=>{if(!e)return Fr;const r=await Promise.resolve(e(t));return async()=>r()},[t,e]),Fr,{preserveValue:!1});g.useEffect(()=>()=>{n!==Fr&&n()},[n])};Object.defineProperty(exports,"sonner",{enumerable:!0,get:()=>os.toast});exports.Alert=Hi;exports.AlertDescription=Yi;exports.AlertTitle=Xi;exports.BOOK_SELECTOR_STRING_KEYS=mc;exports.BookChapterControl=oc;exports.BookSelectionMode=Cs;exports.BookSelector=hc;exports.Button=fe;exports.Card=xo;exports.CardContent=So;exports.CardDescription=ko;exports.CardFooter=Qs;exports.CardHeader=yo;exports.CardTitle=No;exports.ChapterRangeSelector=js;exports.Checkbox=sr;exports.Checklist=vd;exports.ComboBox=Wn;exports.DataTable=Is;exports.DisableButton=Sm;exports.DropdownMenu=or;exports.DropdownMenuCheckboxItem=ar;exports.DropdownMenuContent=En;exports.DropdownMenuGroup=fs;exports.DropdownMenuItem=co;exports.DropdownMenuItemType=tl;exports.DropdownMenuLabel=Wt;exports.DropdownMenuPortal=ql;exports.DropdownMenuRadioGroup=Xl;exports.DropdownMenuRadioItem=uo;exports.DropdownMenuSeparator=jn;exports.DropdownMenuShortcut=gs;exports.DropdownMenuSub=Hl;exports.DropdownMenuSubContent=hs;exports.DropdownMenuSubTrigger=ms;exports.DropdownMenuTrigger=lo;exports.EnableButton=km;exports.FilterButton=el;exports.FilterDropdown=Cm;exports.Footer=Om;exports.GridMenu=Ui;exports.HamburgerMenuButton=qi;exports.INVENTORY_STRING_KEYS=Ec;exports.IconButton=hm;exports.Input=St;exports.InstallButton=Nm;exports.Inventory=Tc;exports.Label=qe;exports.MarkdownRenderer=jm;exports.MenuItem=Xo;exports.MoreInfo=Rm;exports.NavigationContentSearch=Rc;exports.NoExtensionsFound=Tm;exports.RadioGroup=po;exports.RadioGroupItem=Yn;exports.ScriptureResultsViewer=wd;exports.ScrollGroupSelector=fd;exports.SearchBar=ho;exports.Select=Dt;exports.SelectContent=vt;exports.SelectGroup=Ts;exports.SelectItem=De;exports.SelectLabel=Rs;exports.SelectScrollDownButton=fo;exports.SelectScrollUpButton=wo;exports.SelectSeparator=Os;exports.SelectTrigger=bt;exports.SelectValue=Bt;exports.Separator=lr;exports.SettingsCard=bd;exports.SettingsList=md;exports.SettingsListHeader=gd;exports.SettingsListItem=hd;exports.SettingsSidebar=Js;exports.SettingsSidebarContentSearch=ad;exports.Slider=Wi;exports.Sonner=xm;exports.Spinner=Kt;exports.Switch=Ki;exports.Table=Cn;exports.TableBody=Rn;exports.TableCaption=Ps;exports.TableCell=xt;exports.TableFooter=_s;exports.TableHead=Vt;exports.TableHeader=Tn;exports.TableRow=Ze;exports.Tabs=ym;exports.TabsContent=Qi;exports.TabsList=Ji;exports.TabsTrigger=Zi;exports.TextField=gm;exports.ToggleGroup=mo;exports.ToggleGroupItem=fn;exports.Toolbar=bm;exports.UpdateButton=Em;exports.VersionHistory=nl;exports.VerticalTabs=go;exports.VerticalTabsContent=vo;exports.VerticalTabsList=bo;exports.VerticalTabsTrigger=Vs;exports.buttonVariants=bs;exports.cn=N;exports.getBookNumFromId=$s;exports.getLinesFromUSFM=Ms;exports.getNumberFromUSFM=Hr;exports.getStatusForItem=As;exports.inventoryCountColumn=kc;exports.inventoryItemColumn=yc;exports.inventoryStatusColumn=Sc;exports.useEvent=_m;exports.useEventAsync=Pm;exports.usePromise=nr;function Im(e,t="top"){if(!e||typeof document>"u")return;const n=document.head||document.querySelector("head"),r=n.querySelector(":first-child"),o=document.createElement("style");o.appendChild(document.createTextNode(e)),t==="top"&&r?n.insertBefore(o,r):n.appendChild(o)}Im(`*, ::before, ::after { --tw-border-spacing-x: 0; --tw-border-spacing-y: 0; --tw-translate-x: 0; @@ -1483,6 +1483,12 @@ video:where(.pr-twp,.pr-twp *) { .tw-w-9 { width: 2.25rem; } +.tw-w-9\\/12 { + width: 75%; +} +.tw-w-96 { + width: 24rem; +} .tw-w-\\[--sidebar-width\\] { width: var(--sidebar-width); } @@ -1798,6 +1804,9 @@ video:where(.pr-twp,.pr-twp *) { .tw-break-words { overflow-wrap: break-word; } +.tw-rounded { + border-radius: 0.25rem; +} .tw-rounded-full { border-radius: 9999px; } @@ -2020,6 +2029,10 @@ video:where(.pr-twp,.pr-twp *) { .tw-bg-sidebar-border { background-color: hsl(var(--sidebar-border)); } +.tw-bg-slate-100 { + --tw-bg-opacity: 1; + background-color: rgb(241 245 249 / var(--tw-bg-opacity)); +} .tw-bg-transparent { background-color: transparent; } @@ -2039,6 +2052,9 @@ video:where(.pr-twp,.pr-twp *) { .tw-p-2 { padding: 0.5rem; } +.tw-p-3 { + padding: 0.75rem; +} .tw-p-4 { padding: 1rem; } @@ -2127,6 +2143,9 @@ video:where(.pr-twp,.pr-twp *) { .tw-pe-2 { padding-inline-end: 0.5rem; } +.tw-pl-3 { + padding-left: 0.75rem; +} .tw-pl-4 { padding-left: 1rem; } @@ -2282,6 +2301,10 @@ video:where(.pr-twp,.pr-twp *) { .tw-text-foreground\\/80 { color: hsl(var(--foreground) / 0.8); } +.tw-text-gray-400 { + --tw-text-opacity: 1; + color: rgb(156 163 175 / var(--tw-text-opacity)); +} .tw-text-gray-500 { --tw-text-opacity: 1; color: rgb(107 114 128 / var(--tw-text-opacity)); @@ -2298,6 +2321,10 @@ video:where(.pr-twp,.pr-twp *) { --tw-text-opacity: 1; color: rgb(31 41 55 / var(--tw-text-opacity)); } +.tw-text-gray-900 { + --tw-text-opacity: 1; + color: rgb(17 24 39 / var(--tw-text-opacity)); +} .tw-text-inherit { color: inherit; } @@ -2623,6 +2650,11 @@ video:where(.pr-twp,.pr-twp *) { color: hsl(var(--foreground)); } +.hover\\:tw-text-gray-900:hover { + --tw-text-opacity: 1; + color: rgb(17 24 39 / var(--tw-text-opacity)); +} + .hover\\:tw-text-muted-foreground:hover { color: hsl(var(--muted-foreground)); } @@ -2650,6 +2682,12 @@ video:where(.pr-twp,.pr-twp *) { box-shadow: var(--tw-ring-offset-shadow, 0 0 #0000), var(--tw-ring-shadow, 0 0 #0000), var(--tw-shadow); } +.hover\\:tw-shadow-sm:hover { + --tw-shadow: 0 1px 2px 0 rgb(0 0 0 / 0.05); + --tw-shadow-colored: 0 1px 2px 0 var(--tw-shadow-color); + box-shadow: var(--tw-ring-offset-shadow, 0 0 #0000), var(--tw-ring-shadow, 0 0 #0000), var(--tw-shadow); +} + .hover\\:after\\:tw-bg-sidebar-border:hover::after { content: var(--tw-content); background-color: hsl(var(--sidebar-border)); @@ -2718,6 +2756,11 @@ video:where(.pr-twp,.pr-twp *) { background-color: hsl(var(--sidebar-accent)); } +.active\\:tw-bg-white:active { + --tw-bg-opacity: 1; + background-color: rgb(255 255 255 / var(--tw-bg-opacity)); +} + .active\\:tw-text-sidebar-accent-foreground:active { color: hsl(var(--sidebar-accent-foreground)); } @@ -3543,31 +3586,12 @@ video:where(.pr-twp,.pr-twp *) { [data-side=right] .\\[\\[data-side\\=right\\]_\\&\\]\\:tw-cursor-e-resize { cursor: e-resize; } -.papi-icon-button { - border: 0; - border-radius: 3em; +.banded-row:hover { cursor: pointer; - display: inline-block; } -.papi-icon-button.primary { - background-color: #1ea7fd; - color: white; -} - -.papi-icon-button.secondary { - background-color: transparent; - color: #333; -} - -.papi-icon-button.paratext { - background-color: darkgreen; - color: greenyellow; -} - -.papi-icon-button.paratext.bright { - background-color: greenyellow; - color: darkgreen; +.banded-row[data-state='selected']:hover { + cursor: default; } .papi-multi-column-menu { background-color: rgb(222, 222, 222); @@ -3603,25 +3627,31 @@ video:where(.pr-twp,.pr-twp *) { color: rgb(76, 106, 76); background-color: rgb(214, 255, 152); } -.papi-menu-item { - background-color: transparent; +.papi-icon-button { + border: 0; + border-radius: 3em; + cursor: pointer; + display: inline-block; } -.papi-menu-icon-trailing { - margin-left: 10px; - place-content: flex-end; +.papi-icon-button.primary { + background-color: #1ea7fd; + color: white; } -.papi-menu-item img { - max-width: 24px; - max-height: 24px; +.papi-icon-button.secondary { + background-color: transparent; + color: #333; } -.banded-row:hover { - cursor: pointer; + +.papi-icon-button.paratext { + background-color: darkgreen; + color: greenyellow; } -.banded-row[data-state='selected']:hover { - cursor: default; +.papi-icon-button.paratext.bright { + background-color: greenyellow; + color: darkgreen; } .papi-menu-drawer-paper { height: fit-content !important; @@ -3633,5 +3663,18 @@ video:where(.pr-twp,.pr-twp *) { display: flex; gap: 8px; } +.papi-menu-item { + background-color: transparent; +} + +.papi-menu-icon-trailing { + margin-left: 10px; + place-content: flex-end; +} + +.papi-menu-item img { + max-width: 24px; + max-height: 24px; +} `,"top"); //# sourceMappingURL=index.cjs.map diff --git a/lib/platform-bible-react/dist/index.cjs.map b/lib/platform-bible-react/dist/index.cjs.map index 271c73b6fd..8ce8531647 100644 --- a/lib/platform-bible-react/dist/index.cjs.map +++ b/lib/platform-bible-react/dist/index.cjs.map @@ -1 +1 @@ -{"version":3,"file":"index.cjs","sources":["../src/utils/shadcn-ui.util.ts","../src/components/shadcn-ui/input.tsx","../src/components/advanced/book-chapter-control/book-chapter-input.component.tsx","../../../node_modules/@sillsdev/scripture/dist/index.es.js","../src/components/shadcn-ui/dropdown-menu.tsx","../src/components/advanced/book-chapter-control/book-menu-item.component.tsx","../src/components/advanced/book-chapter-control/chapter-select.component.tsx","../src/components/advanced/book-chapter-control/go-to-menu-item.component.tsx","../src/components/advanced/book-chapter-control/book-chapter-control.component.tsx","../src/components/shadcn-ui/button.tsx","../src/components/shadcn-ui/label.tsx","../src/components/shadcn-ui/radio-group.tsx","../src/components/shadcn-ui/popover.tsx","../src/components/shadcn-ui/dialog.tsx","../src/components/shadcn-ui/command.tsx","../src/components/basics/combo-box.component.tsx","../src/components/basics/chapter-range-selector.component.tsx","../src/components/advanced/book-selector.component.tsx","../src/components/advanced/data-table/data-table-column-toggle.component.tsx","../src/components/shadcn-ui/select.tsx","../src/components/advanced/data-table/data-table-pagination.component.tsx","../src/components/shadcn-ui/table.tsx","../src/components/advanced/data-table/data-table.component.tsx","../src/components/advanced/inventory/occurrences-table.component.tsx","../src/components/shadcn-ui/checkbox.tsx","../src/components/advanced/inventory/inventory-utils.ts","../src/components/shadcn-ui/toggle.tsx","../src/components/shadcn-ui/toggle-group.tsx","../src/components/advanced/inventory/inventory-columns.tsx","../src/components/advanced/inventory/inventory.component.tsx","../src/components/basics/search-bar.component.tsx","../src/components/basics/tabs-vertical.tsx","../src/components/advanced/tab-navigation-content-search.component.tsx","../src/components/shadcn-ui/separator.tsx","../src/components/shadcn-ui/sheet.tsx","../src/components/shadcn-ui/skeleton.tsx","../src/components/shadcn-ui/tooltip.tsx","../src/components/hooks/use-mobile.tsx","../src/components/shadcn-ui/sidebar.tsx","../src/components/advanced/settings-components/settings-sidebar.component.tsx","../src/components/advanced/settings-components/settings-sidebar-content-search.component.tsx","../src/components/advanced/scripture-results-viewer/scripture-results-viewer.component.tsx","../src/components/advanced/scroll-group-selector.component.tsx","../src/components/advanced/settings-components/settings-list.component.tsx","../src/components/shadcn-ui/card.tsx","../src/components/advanced/settings-components/settings-card.component.tsx","../src/components/basics/checklist.component.tsx","../../../node_modules/@babel/runtime/helpers/interopRequireDefault.js","../../../node_modules/@mui/utils/chainPropTypes/chainPropTypes.js","../../../node_modules/@babel/runtime/helpers/esm/extends.js","../../../node_modules/@mui/utils/deepmerge/deepmerge.js","../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.production.min.js","../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.development.js","../../../node_modules/prop-types/node_modules/react-is/index.js","../../../node_modules/object-assign/index.js","../../../node_modules/prop-types/lib/ReactPropTypesSecret.js","../../../node_modules/prop-types/lib/has.js","../../../node_modules/prop-types/checkPropTypes.js","../../../node_modules/prop-types/factoryWithTypeCheckers.js","../../../node_modules/prop-types/factoryWithThrowingShims.js","../../../node_modules/prop-types/index.js","../../../node_modules/@mui/utils/elementAcceptingRef/elementAcceptingRef.js","../../../node_modules/@mui/utils/exactProp/exactProp.js","../../../node_modules/@mui/utils/formatMuiErrorMessage/formatMuiErrorMessage.js","../../../node_modules/react-is/cjs/react-is.production.min.js","../../../node_modules/react-is/cjs/react-is.development.js","../../../node_modules/react-is/index.js","../../../node_modules/@mui/utils/getDisplayName/getDisplayName.js","../../../node_modules/@mui/utils/HTMLElementType/HTMLElementType.js","../../../node_modules/@mui/utils/refType/refType.js","../../../node_modules/@mui/utils/capitalize/capitalize.js","../../../node_modules/@mui/utils/createChainedFunction/createChainedFunction.js","../../../node_modules/@mui/utils/debounce/debounce.js","../../../node_modules/@mui/utils/deprecatedPropType/deprecatedPropType.js","../../../node_modules/@mui/utils/isMuiElement/isMuiElement.js","../../../node_modules/@mui/utils/ownerDocument/ownerDocument.js","../../../node_modules/@mui/utils/ownerWindow/ownerWindow.js","../../../node_modules/@mui/utils/requirePropFactory/requirePropFactory.js","../../../node_modules/@mui/utils/setRef/setRef.js","../../../node_modules/@mui/utils/useEnhancedEffect/useEnhancedEffect.js","../../../node_modules/@mui/utils/useId/useId.js","../../../node_modules/@mui/utils/unsupportedProp/unsupportedProp.js","../../../node_modules/@mui/utils/useControlled/useControlled.js","../../../node_modules/@mui/utils/useEventCallback/useEventCallback.js","../../../node_modules/@mui/utils/useForkRef/useForkRef.js","../../../node_modules/@mui/utils/useLazyRef/useLazyRef.js","../../../node_modules/@mui/utils/useOnMount/useOnMount.js","../../../node_modules/@mui/utils/useTimeout/useTimeout.js","../../../node_modules/@mui/utils/useIsFocusVisible/useIsFocusVisible.js","../../../node_modules/@mui/utils/resolveProps/resolveProps.js","../../../node_modules/@mui/utils/composeClasses/composeClasses.js","../../../node_modules/@mui/utils/ClassNameGenerator/ClassNameGenerator.js","../../../node_modules/@mui/utils/generateUtilityClass/generateUtilityClass.js","../../../node_modules/@mui/utils/generateUtilityClasses/generateUtilityClasses.js","../../../node_modules/@mui/utils/clamp/clamp.js","../../../node_modules/@babel/runtime/helpers/esm/objectWithoutPropertiesLoose.js","../../../node_modules/@mui/system/esm/createTheme/createBreakpoints.js","../../../node_modules/@mui/system/esm/createTheme/shape.js","../../../node_modules/@mui/system/esm/responsivePropType.js","../../../node_modules/@mui/system/esm/merge.js","../../../node_modules/@mui/system/esm/breakpoints.js","../../../node_modules/@mui/system/esm/style.js","../../../node_modules/@mui/system/esm/memoize.js","../../../node_modules/@mui/system/esm/spacing.js","../../../node_modules/@mui/system/esm/createTheme/createSpacing.js","../../../node_modules/@mui/system/esm/compose.js","../../../node_modules/@mui/system/esm/borders.js","../../../node_modules/@mui/system/esm/cssGrid.js","../../../node_modules/@mui/system/esm/palette.js","../../../node_modules/@mui/system/esm/sizing.js","../../../node_modules/@mui/system/esm/styleFunctionSx/defaultSxConfig.js","../../../node_modules/@mui/system/esm/styleFunctionSx/styleFunctionSx.js","../../../node_modules/@mui/system/esm/createTheme/applyStyles.js","../../../node_modules/@mui/system/esm/createTheme/createTheme.js","../../../node_modules/@mui/system/esm/useThemeWithoutDefault.js","../../../node_modules/@mui/system/esm/useTheme.js","../../../node_modules/@mui/system/esm/createStyled.js","../../../node_modules/@mui/system/esm/useThemeProps/getThemeProps.js","../../../node_modules/@mui/system/esm/useThemeProps/useThemeProps.js","../../../node_modules/@mui/system/esm/colorManipulator.js","../../../node_modules/@mui/material/styles/createMixins.js","../../../node_modules/@mui/material/colors/common.js","../../../node_modules/@mui/material/colors/grey.js","../../../node_modules/@mui/material/colors/purple.js","../../../node_modules/@mui/material/colors/red.js","../../../node_modules/@mui/material/colors/orange.js","../../../node_modules/@mui/material/colors/blue.js","../../../node_modules/@mui/material/colors/lightBlue.js","../../../node_modules/@mui/material/colors/green.js","../../../node_modules/@mui/material/styles/createPalette.js","../../../node_modules/@mui/material/styles/createTypography.js","../../../node_modules/@mui/material/styles/shadows.js","../../../node_modules/@mui/material/styles/createTransitions.js","../../../node_modules/@mui/material/styles/zIndex.js","../../../node_modules/@mui/material/styles/createTheme.js","../../../node_modules/@mui/material/styles/defaultTheme.js","../../../node_modules/@mui/material/styles/identifier.js","../../../node_modules/@mui/material/styles/useThemeProps.js","../../../node_modules/@mui/material/styles/styled.js","../../../node_modules/@mui/material/SvgIcon/svgIconClasses.js","../../../node_modules/@mui/material/SvgIcon/SvgIcon.js","../../../node_modules/@mui/material/utils/createSvgIcon.js","../../../node_modules/@mui/material/utils/index.js","../../../node_modules/@mui/icons-material/utils/createSvgIcon.js","../../../node_modules/@mui/icons-material/ArrowRight.js","../../../node_modules/@mui/base/utils/isHostComponent.js","../../../node_modules/@mui/base/utils/appendOwnerState.js","../../../node_modules/@mui/base/utils/ClassNameConfigurator.js","../../../node_modules/@mui/base/utils/extractEventHandlers.js","../../../node_modules/@mui/base/utils/resolveComponentProps.js","../../../node_modules/@mui/base/utils/omitEventHandlers.js","../../../node_modules/@mui/base/utils/mergeSlotProps.js","../../../node_modules/@mui/base/utils/useSlotProps.js","../../../node_modules/@mui/base/generateUtilityClass/index.js","../../../node_modules/@mui/base/generateUtilityClasses/index.js","../../../node_modules/@mui/base/Portal/Portal.js","../../../node_modules/@popperjs/core/lib/enums.js","../../../node_modules/@popperjs/core/lib/dom-utils/getNodeName.js","../../../node_modules/@popperjs/core/lib/dom-utils/getWindow.js","../../../node_modules/@popperjs/core/lib/dom-utils/instanceOf.js","../../../node_modules/@popperjs/core/lib/modifiers/applyStyles.js","../../../node_modules/@popperjs/core/lib/utils/getBasePlacement.js","../../../node_modules/@popperjs/core/lib/utils/math.js","../../../node_modules/@popperjs/core/lib/utils/userAgent.js","../../../node_modules/@popperjs/core/lib/dom-utils/isLayoutViewport.js","../../../node_modules/@popperjs/core/lib/dom-utils/getBoundingClientRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/getLayoutRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/contains.js","../../../node_modules/@popperjs/core/lib/dom-utils/getComputedStyle.js","../../../node_modules/@popperjs/core/lib/dom-utils/isTableElement.js","../../../node_modules/@popperjs/core/lib/dom-utils/getDocumentElement.js","../../../node_modules/@popperjs/core/lib/dom-utils/getParentNode.js","../../../node_modules/@popperjs/core/lib/dom-utils/getOffsetParent.js","../../../node_modules/@popperjs/core/lib/utils/getMainAxisFromPlacement.js","../../../node_modules/@popperjs/core/lib/utils/within.js","../../../node_modules/@popperjs/core/lib/utils/getFreshSideObject.js","../../../node_modules/@popperjs/core/lib/utils/mergePaddingObject.js","../../../node_modules/@popperjs/core/lib/utils/expandToHashMap.js","../../../node_modules/@popperjs/core/lib/modifiers/arrow.js","../../../node_modules/@popperjs/core/lib/utils/getVariation.js","../../../node_modules/@popperjs/core/lib/modifiers/computeStyles.js","../../../node_modules/@popperjs/core/lib/modifiers/eventListeners.js","../../../node_modules/@popperjs/core/lib/utils/getOppositePlacement.js","../../../node_modules/@popperjs/core/lib/utils/getOppositeVariationPlacement.js","../../../node_modules/@popperjs/core/lib/dom-utils/getWindowScroll.js","../../../node_modules/@popperjs/core/lib/dom-utils/getWindowScrollBarX.js","../../../node_modules/@popperjs/core/lib/dom-utils/getViewportRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/getDocumentRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/isScrollParent.js","../../../node_modules/@popperjs/core/lib/dom-utils/getScrollParent.js","../../../node_modules/@popperjs/core/lib/dom-utils/listScrollParents.js","../../../node_modules/@popperjs/core/lib/utils/rectToClientRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/getClippingRect.js","../../../node_modules/@popperjs/core/lib/utils/computeOffsets.js","../../../node_modules/@popperjs/core/lib/utils/detectOverflow.js","../../../node_modules/@popperjs/core/lib/utils/computeAutoPlacement.js","../../../node_modules/@popperjs/core/lib/modifiers/flip.js","../../../node_modules/@popperjs/core/lib/modifiers/hide.js","../../../node_modules/@popperjs/core/lib/modifiers/offset.js","../../../node_modules/@popperjs/core/lib/modifiers/popperOffsets.js","../../../node_modules/@popperjs/core/lib/utils/getAltAxis.js","../../../node_modules/@popperjs/core/lib/modifiers/preventOverflow.js","../../../node_modules/@popperjs/core/lib/dom-utils/getHTMLElementScroll.js","../../../node_modules/@popperjs/core/lib/dom-utils/getNodeScroll.js","../../../node_modules/@popperjs/core/lib/dom-utils/getCompositeRect.js","../../../node_modules/@popperjs/core/lib/utils/orderModifiers.js","../../../node_modules/@popperjs/core/lib/utils/debounce.js","../../../node_modules/@popperjs/core/lib/utils/mergeByName.js","../../../node_modules/@popperjs/core/lib/createPopper.js","../../../node_modules/@popperjs/core/lib/popper.js","../../../node_modules/@mui/base/Popper/popperClasses.js","../../../node_modules/@mui/base/Popper/Popper.js","../../../node_modules/@mui/material/styles/useTheme.js","../../../node_modules/@babel/runtime/helpers/esm/setPrototypeOf.js","../../../node_modules/@babel/runtime/helpers/esm/inheritsLoose.js","../../../node_modules/react-transition-group/esm/config.js","../../../node_modules/react-transition-group/esm/utils/PropTypes.js","../../../node_modules/react-transition-group/esm/TransitionGroupContext.js","../../../node_modules/react-transition-group/esm/utils/reflow.js","../../../node_modules/react-transition-group/esm/Transition.js","../../../node_modules/@mui/material/transitions/utils.js","../../../node_modules/@mui/material/Grow/Grow.js","../../../node_modules/@mui/material/Popper/Popper.js","../../../node_modules/@mui/material/Tooltip/tooltipClasses.js","../../../node_modules/@mui/material/Tooltip/Tooltip.js","../src/components/mui/menu-item.component.tsx","../src/components/mui/grouped-menu-item-list.component.tsx","../src/components/mui/top-level-menu.component.tsx","../src/components/mui/grid-menu.component.tsx","../src/hooks/use-promise.hook.ts","../../../node_modules/@mui/icons-material/esm/Menu.js","../src/components/mui/hamburger-menu-button.component.tsx","../src/components/mui/icon-button.component.tsx","../src/components/basics/spinner.component.tsx","../src/components/basics/text-field.component.tsx","../src/components/mui/toolbar.component.tsx","../src/components/shadcn-ui/alert.tsx","../src/components/shadcn-ui/sonner.tsx","../src/components/shadcn-ui/slider.tsx","../src/components/shadcn-ui/switch.tsx","../src/components/shadcn-ui/tabs.tsx","../src/components/advanced/extension-marketplace/buttons/install-button.component.tsx","../src/components/advanced/extension-marketplace/buttons/enable-button.component.tsx","../src/components/advanced/extension-marketplace/buttons/disable-button.component.tsx","../src/components/advanced/extension-marketplace/buttons/update-button.component.tsx","../src/components/advanced/extension-marketplace/markdown-renderer.component.tsx","../src/components/advanced/extension-marketplace/buttons/filter-button.component.tsx","../src/components/advanced/extension-marketplace/filter-dropdown.component.tsx","../src/components/advanced/extension-marketplace/no-extensions-found.component.tsx","../src/components/advanced/extension-marketplace/more-info.component.tsx","../src/components/advanced/extension-marketplace/version-history.component.tsx","../src/components/advanced/extension-marketplace/footer.component.tsx","../src/hooks/use-event.hook.ts","../src/hooks/use-event-async.hook.ts"],"sourcesContent":["import { type ClassValue, clsx } from 'clsx';\nimport { extendTailwindMerge } from 'tailwind-merge';\n\nconst twMergeCustom = extendTailwindMerge({ prefix: 'tw-' });\n\n/**\n * Tailwind and CSS class application helper function. Uses\n * [`clsx`](https://www.npmjs.com/package/clsx) to make it easy to apply classes conditionally using\n * object syntax, and uses [`tailwind-merge`](https://www.npmjs.com/package/tailwind-merge) to make\n * it easy to merge/overwrite Tailwind classes in a programmer-logic-friendly way.\n *\n * Note: `tailwind-merge` is configured to use the prefix `tw-`, so you must use the same prefix\n * with any Tailwind classes you use with this function to successfully overwrite other Tailwind\n * classes. `platform-bible-react` is configured to use `tw-` as its Tailwind prefix, so any\n * Tailwind classes you pass into `platform-bible-react` components will be compared using the `tw-`\n * prefix.\n *\n * This function was popularized by\n * [shadcn/ui](https://ui.shadcn.com/docs/installation/manual#add-a-cn-helper). See [ByteGrad's\n * explanation video](https://www.youtube.com/watch?v=re2JFITR7TI) for more information.\n *\n * @example\n *\n * ```typescript\n * const borderShouldBeBlue = true;\n * const textShouldBeRed = true;\n * const heightShouldBe20 = false;\n * const classString = cn(\n * 'tw-bg-primary tw-h-10 tw-text-primary-foreground',\n * 'tw-bg-secondary',\n * {\n * 'tw-border-blue-500': borderShouldBeBlue,\n * 'tw-text-red-500': textShouldBeRed,\n * 'tw-h-20': heightShouldBe20,\n * },\n * 'some-class',\n * );\n * ```\n *\n * The resulting `classString` is `'tw-h-10 tw-bg-secondary tw-border-blue-500 tw-text-red-500\n * some-class'`\n *\n * - Notice that `'tw-bg-secondary'`, specified later, overwrote `'tw-bg-primary'`, specified earlier,\n * because they are Tailwind classes that affect the same css property\n * - Notice that `'tw-text-red-500'`, specified later, overwrote `'tw-text-primary-foreground'`,\n * specified earlier, because they are Tailwind classes that affect the same css property\n * - Notice that `'tw-h-20'`, specified later, did not overwrite `'tw-h-10'`, specified earlier,\n * because `'tw-h-20'` is part of a conditional class object and its value evaluated to `false`;\n * therefore it was not applied\n * - Notice that `'some-class'` was applied. This function is not limited only to Tailwind classes.\n *\n *\n * @param inputs Class strings or `clsx` conditional class objects to merge. Tailwind classes\n * specified later in the arguments overwrite similar Tailwind classes specified earlier in the\n * arguments\n * @returns Class string containing all applicable classes from the arguments based on the rules\n * described above\n */\n// shadcn/ui uses this export in its boilerplate code\n// eslint-disable-next-line import/prefer-default-export\nexport function cn(...inputs: ClassValue[]) {\n return twMergeCustom(clsx(inputs));\n}\n","import React from 'react';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport interface InputProps extends React.InputHTMLAttributes {}\n\nexport const Input = React.forwardRef(\n ({ className, type, ...props }, ref) => {\n return (\n \n );\n },\n);\nInput.displayName = 'Input';\n","import { FocusEventHandler, forwardRef, KeyboardEvent, MouseEventHandler } from 'react';\nimport { History } from 'lucide-react';\nimport { Input as ShadInput } from '@/components/shadcn-ui/input';\n\nexport type BookChapterInputProps = {\n handleSearch: (searchString: string) => void;\n handleKeyDown: (event: KeyboardEvent) => void;\n handleOnClick: MouseEventHandler;\n handleSubmit: () => void;\n onFocus?: FocusEventHandler;\n value: string;\n placeholder: string;\n};\n\n// Shadcn Input sets type to \"button\"- HAVE to prop spread before setting type\nconst BookChapterInput = forwardRef(\n (\n { handleSearch, handleKeyDown, handleOnClick, handleSubmit, ...props }: BookChapterInputProps,\n ref,\n ) => {\n return (\n
    \n handleSearch(event.target.value)}\n onKeyDown={(e) => {\n if (e.key === 'Enter') {\n handleSubmit();\n }\n handleKeyDown(e);\n }}\n onClick={handleOnClick}\n ref={ref}\n />\n {\n // eslint-disable-next-line no-console\n console.log('back in history');\n }}\n />\n
    \n );\n },\n);\n\nexport default BookChapterInput;\n","var P = Object.defineProperty;\nvar R = (t, e, s) => e in t ? P(t, e, { enumerable: !0, configurable: !0, writable: !0, value: s }) : t[e] = s;\nvar n = (t, e, s) => R(t, typeof e != \"symbol\" ? e + \"\" : e, s);\nclass _ {\n constructor() {\n n(this, \"books\");\n n(this, \"firstSelectedBookNum\");\n n(this, \"lastSelectedBookNum\");\n n(this, \"count\");\n n(this, \"selectedBookNumbers\");\n n(this, \"selectedBookIds\");\n }\n}\nconst N = [\n \"GEN\",\n \"EXO\",\n \"LEV\",\n \"NUM\",\n \"DEU\",\n \"JOS\",\n \"JDG\",\n \"RUT\",\n \"1SA\",\n \"2SA\",\n // 10\n \"1KI\",\n \"2KI\",\n \"1CH\",\n \"2CH\",\n \"EZR\",\n \"NEH\",\n \"EST\",\n \"JOB\",\n \"PSA\",\n \"PRO\",\n // 20\n \"ECC\",\n \"SNG\",\n \"ISA\",\n \"JER\",\n \"LAM\",\n \"EZK\",\n \"DAN\",\n \"HOS\",\n \"JOL\",\n \"AMO\",\n // 30\n \"OBA\",\n \"JON\",\n \"MIC\",\n \"NAM\",\n \"HAB\",\n \"ZEP\",\n \"HAG\",\n \"ZEC\",\n \"MAL\",\n \"MAT\",\n // 40\n \"MRK\",\n \"LUK\",\n \"JHN\",\n \"ACT\",\n \"ROM\",\n \"1CO\",\n \"2CO\",\n \"GAL\",\n \"EPH\",\n \"PHP\",\n // 50\n \"COL\",\n \"1TH\",\n \"2TH\",\n \"1TI\",\n \"2TI\",\n \"TIT\",\n \"PHM\",\n \"HEB\",\n \"JAS\",\n \"1PE\",\n // 60\n \"2PE\",\n \"1JN\",\n \"2JN\",\n \"3JN\",\n \"JUD\",\n \"REV\",\n \"TOB\",\n \"JDT\",\n \"ESG\",\n \"WIS\",\n // 70\n \"SIR\",\n \"BAR\",\n \"LJE\",\n \"S3Y\",\n \"SUS\",\n \"BEL\",\n \"1MA\",\n \"2MA\",\n \"3MA\",\n \"4MA\",\n // 80\n \"1ES\",\n \"2ES\",\n \"MAN\",\n \"PS2\",\n \"ODA\",\n \"PSS\",\n \"JSA\",\n // actual variant text for JOS, now in LXA text\n \"JDB\",\n // actual variant text for JDG, now in LXA text\n \"TBS\",\n // actual variant text for TOB, now in LXA text\n \"SST\",\n // actual variant text for SUS, now in LXA text // 90\n \"DNT\",\n // actual variant text for DAN, now in LXA text\n \"BLT\",\n // actual variant text for BEL, now in LXA text\n \"XXA\",\n \"XXB\",\n \"XXC\",\n \"XXD\",\n \"XXE\",\n \"XXF\",\n \"XXG\",\n \"FRT\",\n // 100\n \"BAK\",\n \"OTH\",\n \"3ES\",\n // Used previously but really should be 2ES\n \"EZA\",\n // Used to be called 4ES, but not actually in any known project\n \"5EZ\",\n // Used to be called 5ES, but not actually in any known project\n \"6EZ\",\n // Used to be called 6ES, but not actually in any known project\n \"INT\",\n \"CNC\",\n \"GLO\",\n \"TDX\",\n // 110\n \"NDX\",\n \"DAG\",\n \"PS3\",\n \"2BA\",\n \"LBA\",\n \"JUB\",\n \"ENO\",\n \"1MQ\",\n \"2MQ\",\n \"3MQ\",\n // 120\n \"REP\",\n \"4BA\",\n \"LAO\"\n], B = [\n \"XXA\",\n \"XXB\",\n \"XXC\",\n \"XXD\",\n \"XXE\",\n \"XXF\",\n \"XXG\",\n \"FRT\",\n \"BAK\",\n \"OTH\",\n \"INT\",\n \"CNC\",\n \"GLO\",\n \"TDX\",\n \"NDX\"\n], O = [\n \"Genesis\",\n \"Exodus\",\n \"Leviticus\",\n \"Numbers\",\n \"Deuteronomy\",\n \"Joshua\",\n \"Judges\",\n \"Ruth\",\n \"1 Samuel\",\n \"2 Samuel\",\n \"1 Kings\",\n \"2 Kings\",\n \"1 Chronicles\",\n \"2 Chronicles\",\n \"Ezra\",\n \"Nehemiah\",\n \"Esther (Hebrew)\",\n \"Job\",\n \"Psalms\",\n \"Proverbs\",\n \"Ecclesiastes\",\n \"Song of Songs\",\n \"Isaiah\",\n \"Jeremiah\",\n \"Lamentations\",\n \"Ezekiel\",\n \"Daniel (Hebrew)\",\n \"Hosea\",\n \"Joel\",\n \"Amos\",\n \"Obadiah\",\n \"Jonah\",\n \"Micah\",\n \"Nahum\",\n \"Habakkuk\",\n \"Zephaniah\",\n \"Haggai\",\n \"Zechariah\",\n \"Malachi\",\n \"Matthew\",\n \"Mark\",\n \"Luke\",\n \"John\",\n \"Acts\",\n \"Romans\",\n \"1 Corinthians\",\n \"2 Corinthians\",\n \"Galatians\",\n \"Ephesians\",\n \"Philippians\",\n \"Colossians\",\n \"1 Thessalonians\",\n \"2 Thessalonians\",\n \"1 Timothy\",\n \"2 Timothy\",\n \"Titus\",\n \"Philemon\",\n \"Hebrews\",\n \"James\",\n \"1 Peter\",\n \"2 Peter\",\n \"1 John\",\n \"2 John\",\n \"3 John\",\n \"Jude\",\n \"Revelation\",\n \"Tobit\",\n \"Judith\",\n \"Esther Greek\",\n \"Wisdom of Solomon\",\n \"Sirach (Ecclesiasticus)\",\n \"Baruch\",\n \"Letter of Jeremiah\",\n \"Song of 3 Young Men\",\n \"Susanna\",\n \"Bel and the Dragon\",\n \"1 Maccabees\",\n \"2 Maccabees\",\n \"3 Maccabees\",\n \"4 Maccabees\",\n \"1 Esdras (Greek)\",\n \"2 Esdras (Latin)\",\n \"Prayer of Manasseh\",\n \"Psalm 151\",\n \"Odes\",\n \"Psalms of Solomon\",\n // WARNING, if you change the spelling of the *obsolete* tag be sure to update\n // IsObsolete routine\n \"Joshua A. *obsolete*\",\n \"Judges B. *obsolete*\",\n \"Tobit S. *obsolete*\",\n \"Susanna Th. *obsolete*\",\n \"Daniel Th. *obsolete*\",\n \"Bel Th. *obsolete*\",\n \"Extra A\",\n \"Extra B\",\n \"Extra C\",\n \"Extra D\",\n \"Extra E\",\n \"Extra F\",\n \"Extra G\",\n \"Front Matter\",\n \"Back Matter\",\n \"Other Matter\",\n \"3 Ezra *obsolete*\",\n \"Apocalypse of Ezra\",\n \"5 Ezra (Latin Prologue)\",\n \"6 Ezra (Latin Epilogue)\",\n \"Introduction\",\n \"Concordance \",\n \"Glossary \",\n \"Topical Index\",\n \"Names Index\",\n \"Daniel Greek\",\n \"Psalms 152-155\",\n \"2 Baruch (Apocalypse)\",\n \"Letter of Baruch\",\n \"Jubilees\",\n \"Enoch\",\n \"1 Meqabyan\",\n \"2 Meqabyan\",\n \"3 Meqabyan\",\n \"Reproof (Proverbs 25-31)\",\n \"4 Baruch (Rest of Baruch)\",\n \"Laodiceans\"\n], S = K();\nfunction g(t, e = !0) {\n return e && (t = t.toUpperCase()), t in S ? S[t] : 0;\n}\nfunction k(t) {\n return g(t) > 0;\n}\nfunction x(t) {\n const e = typeof t == \"string\" ? g(t) : t;\n return e >= 40 && e <= 66;\n}\nfunction T(t) {\n return (typeof t == \"string\" ? g(t) : t) <= 39;\n}\nfunction X(t) {\n return t <= 66;\n}\nfunction V(t) {\n const e = typeof t == \"string\" ? g(t) : t;\n return w(e) && !X(e);\n}\nfunction* L() {\n for (let t = 1; t <= N.length; t++) yield t;\n}\nconst G = 1, A = N.length;\nfunction H() {\n return [\"XXA\", \"XXB\", \"XXC\", \"XXD\", \"XXE\", \"XXF\", \"XXG\"];\n}\nfunction C(t, e = \"***\") {\n const s = t - 1;\n return s < 0 || s >= N.length ? e : N[s];\n}\nfunction I(t) {\n return t <= 0 || t > A ? \"******\" : O[t - 1];\n}\nfunction y(t) {\n return I(g(t));\n}\nfunction w(t) {\n const e = typeof t == \"number\" ? C(t) : t;\n return k(e) && !B.includes(e);\n}\nfunction q(t) {\n const e = typeof t == \"number\" ? C(t) : t;\n return k(e) && B.includes(e);\n}\nfunction U(t) {\n return O[t - 1].includes(\"*obsolete*\");\n}\nfunction K() {\n const t = {};\n for (let e = 0; e < N.length; e++)\n t[N[e]] = e + 1;\n return t;\n}\nconst m = {\n allBookIds: N,\n nonCanonicalIds: B,\n bookIdToNumber: g,\n isBookIdValid: k,\n isBookNT: x,\n isBookOT: T,\n isBookOTNT: X,\n isBookDC: V,\n allBookNumbers: L,\n firstBook: G,\n lastBook: A,\n extraBooks: H,\n bookNumberToId: C,\n bookNumberToEnglishName: I,\n bookIdToEnglishName: y,\n isCanonical: w,\n isExtraMaterial: q,\n isObsolete: U\n};\nvar l = /* @__PURE__ */ ((t) => (t[t.Unknown = 0] = \"Unknown\", t[t.Original = 1] = \"Original\", t[t.Septuagint = 2] = \"Septuagint\", t[t.Vulgate = 3] = \"Vulgate\", t[t.English = 4] = \"English\", t[t.RussianProtestant = 5] = \"RussianProtestant\", t[t.RussianOrthodox = 6] = \"RussianOrthodox\", t))(l || {});\nconst h = class h {\n // private versInfo: Versification;\n constructor(e) {\n n(this, \"name\");\n n(this, \"fullPath\");\n n(this, \"isPresent\");\n n(this, \"hasVerseSegments\");\n n(this, \"isCustomized\");\n n(this, \"baseVersification\");\n n(this, \"scriptureBooks\");\n n(this, \"_type\");\n if (e == null)\n throw new Error(\"Argument undefined\");\n typeof e == \"string\" ? (this.name = e, this._type = l[e]) : (this._type = e, this.name = l[e]);\n }\n get type() {\n return this._type;\n }\n equals(e) {\n return !e.type || !this.type ? !1 : e.type === this.type;\n }\n};\nn(h, \"Original\", new h(l.Original)), n(h, \"Septuagint\", new h(l.Septuagint)), n(h, \"Vulgate\", new h(l.Vulgate)), n(h, \"English\", new h(l.English)), n(h, \"RussianProtestant\", new h(l.RussianProtestant)), n(h, \"RussianOrthodox\", new h(l.RussianOrthodox));\nlet c = h;\nfunction E(t, e) {\n const s = e[0];\n for (let r = 1; r < e.length; r++)\n t = t.split(e[r]).join(s);\n return t.split(s);\n}\nvar D = /* @__PURE__ */ ((t) => (t[t.Valid = 0] = \"Valid\", t[t.UnknownVersification = 1] = \"UnknownVersification\", t[t.OutOfRange = 2] = \"OutOfRange\", t[t.VerseOutOfOrder = 3] = \"VerseOutOfOrder\", t[t.VerseRepeated = 4] = \"VerseRepeated\", t))(D || {});\nconst i = class i {\n constructor(e, s, r, a) {\n /** Not yet implemented. */\n n(this, \"firstChapter\");\n /** Not yet implemented. */\n n(this, \"lastChapter\");\n /** Not yet implemented. */\n n(this, \"lastVerse\");\n /** Not yet implemented. */\n n(this, \"hasSegmentsDefined\");\n /** Not yet implemented. */\n n(this, \"text\");\n /** Not yet implemented. */\n n(this, \"BBBCCCVVVS\");\n /** Not yet implemented. */\n n(this, \"longHashCode\");\n /** The versification of the reference. */\n n(this, \"versification\");\n n(this, \"rtlMark\", \"‏\");\n n(this, \"_bookNum\", 0);\n n(this, \"_chapterNum\", 0);\n n(this, \"_verseNum\", 0);\n n(this, \"_verse\");\n if (r == null && a == null)\n if (e != null && typeof e == \"string\") {\n const o = e, u = s != null && s instanceof c ? s : void 0;\n this.setEmpty(u), this.parse(o);\n } else if (e != null && typeof e == \"number\") {\n const o = s != null && s instanceof c ? s : void 0;\n this.setEmpty(o), this._verseNum = e % i.chapterDigitShifter, this._chapterNum = Math.floor(\n e % i.bookDigitShifter / i.chapterDigitShifter\n ), this._bookNum = Math.floor(e / i.bookDigitShifter);\n } else if (s == null)\n if (e != null && e instanceof i) {\n const o = e;\n this._bookNum = o.bookNum, this._chapterNum = o.chapterNum, this._verseNum = o.verseNum, this._verse = o.verse, this.versification = o.versification;\n } else {\n if (e == null) return;\n const o = e instanceof c ? e : i.defaultVersification;\n this.setEmpty(o);\n }\n else\n throw new Error(\"VerseRef constructor not supported.\");\n else if (e != null && s != null && r != null)\n if (typeof e == \"string\" && typeof s == \"string\" && typeof r == \"string\")\n this.setEmpty(a), this.updateInternal(e, s, r);\n else if (typeof e == \"number\" && typeof s == \"number\" && typeof r == \"number\")\n this._bookNum = e, this._chapterNum = s, this._verseNum = r, this.versification = a ?? i.defaultVersification;\n else\n throw new Error(\"VerseRef constructor not supported.\");\n else\n throw new Error(\"VerseRef constructor not supported.\");\n }\n /**\n * Determines if the verse string is in a valid format (does not consider versification).\n */\n static isVerseParseable(e) {\n return e.length > 0 && \"0123456789\".includes(e[0]) && !e.endsWith(this.verseRangeSeparator) && !e.endsWith(this.verseSequenceIndicator);\n }\n /**\n * Tries to parse the specified string into a verse reference.\n * @param str - The string to attempt to parse.\n * @returns success: `true` if the specified string was successfully parsed, `false` otherwise.\n * @returns verseRef: The result of the parse if successful, or empty VerseRef if it failed\n */\n static tryParse(e) {\n let s;\n try {\n return s = new i(e), { success: !0, verseRef: s };\n } catch (r) {\n if (r instanceof v)\n return s = new i(), { success: !1, verseRef: s };\n throw r;\n }\n }\n /**\n * Gets the reference as a comparable integer where the book, chapter, and verse each occupy 3\n * digits.\n * @param bookNum - Book number (this is 1-based, not an index).\n * @param chapterNum - Chapter number.\n * @param verseNum - Verse number.\n * @returns The reference as a comparable integer where the book, chapter, and verse each occupy 3\n * digits.\n */\n static getBBBCCCVVV(e, s, r) {\n return e % i.bcvMaxValue * i.bookDigitShifter + (s >= 0 ? s % i.bcvMaxValue * i.chapterDigitShifter : 0) + (r >= 0 ? r % i.bcvMaxValue : 0);\n }\n /**\n * Deserializes a serialized VerseRef.\n * @param serializedVerseRef - Serialized VerseRef to create from.\n * @returns the deserialized VerseRef.\n */\n static fromJSON(e) {\n const { book: s, chapterNum: r, verseNum: a, verse: o, versificationStr: u } = e, f = o || a.toString();\n let d;\n return u && (d = new c(u)), s ? new i(s, r.toString(), f, d) : new i();\n }\n /**\n * Parses a verse string and gets the leading numeric portion as a number.\n * @param verseStr - verse string to parse\n * @returns true if the entire string could be parsed as a single, simple verse number (1-999);\n * false if the verse string represented a verse bridge, contained segment letters, or was invalid\n */\n static tryGetVerseNum(e) {\n let s;\n if (!e)\n return s = -1, { success: !0, vNum: s };\n s = 0;\n let r;\n for (let a = 0; a < e.length; a++) {\n if (r = e[a], r < \"0\" || r > \"9\")\n return a === 0 && (s = -1), { success: !1, vNum: s };\n if (s = s * 10 + +r - 0, s > i.bcvMaxValue)\n return s = -1, { success: !1, vNum: s };\n }\n return { success: !0, vNum: s };\n }\n /**\n * Checks to see if a VerseRef hasn't been set - all values are the default.\n */\n get isDefault() {\n return this.bookNum === 0 && this.chapterNum === 0 && this.verseNum === 0 && this.versification == null;\n }\n /**\n * Gets whether the verse contains multiple verses.\n */\n get hasMultiple() {\n return this._verse != null && (this._verse.includes(i.verseRangeSeparator) || this._verse.includes(i.verseSequenceIndicator));\n }\n /**\n * Gets or sets the book of the reference. Book is the 3-letter abbreviation in capital letters,\n * e.g. `'MAT'`.\n */\n get book() {\n return m.bookNumberToId(this.bookNum, \"\");\n }\n set book(e) {\n this.bookNum = m.bookIdToNumber(e);\n }\n /**\n * Gets or sets the chapter of the reference,. e.g. `'3'`.\n */\n get chapter() {\n return this.isDefault || this._chapterNum < 0 ? \"\" : this._chapterNum.toString();\n }\n set chapter(e) {\n const s = +e;\n this._chapterNum = Number.isInteger(s) ? s : -1;\n }\n /**\n * Gets or sets the verse of the reference, including range, segments, and sequences, e.g. `'4'`,\n * or `'4b-5a, 7'`.\n */\n get verse() {\n return this._verse != null ? this._verse : this.isDefault || this._verseNum < 0 ? \"\" : this._verseNum.toString();\n }\n set verse(e) {\n const { success: s, vNum: r } = i.tryGetVerseNum(e);\n this._verse = s ? void 0 : e.replace(this.rtlMark, \"\"), this._verseNum = r, !(this._verseNum >= 0) && ({ vNum: this._verseNum } = i.tryGetVerseNum(this._verse));\n }\n /**\n * Get or set Book based on book number, e.g. `42`.\n */\n get bookNum() {\n return this._bookNum;\n }\n set bookNum(e) {\n if (e <= 0 || e > m.lastBook)\n throw new v(\n \"BookNum must be greater than zero and less than or equal to last book\"\n );\n this._bookNum = e;\n }\n /**\n * Gets or sets the chapter number, e.g. `3`. `-1` if not valid.\n */\n get chapterNum() {\n return this._chapterNum;\n }\n set chapterNum(e) {\n this.chapterNum = e;\n }\n /**\n * Gets or sets verse start number, e.g. `4`. `-1` if not valid.\n */\n get verseNum() {\n return this._verseNum;\n }\n set verseNum(e) {\n this._verseNum = e;\n }\n /**\n * String representing the versification (should ONLY be used for serialization/deserialization).\n *\n * @remarks This is for backwards compatibility when ScrVers was an enumeration.\n */\n get versificationStr() {\n var e;\n return (e = this.versification) == null ? void 0 : e.name;\n }\n set versificationStr(e) {\n this.versification = this.versification != null ? new c(e) : void 0;\n }\n /**\n * Determines if the reference is valid.\n */\n get valid() {\n return this.validStatus === 0;\n }\n /**\n * Get the valid status for this reference.\n */\n get validStatus() {\n return this.validateVerse(i.verseRangeSeparators, i.verseSequenceIndicators);\n }\n /**\n * Gets the reference as a comparable integer where the book,\n * chapter, and verse each occupy three digits and the verse is 0.\n */\n get BBBCCC() {\n return i.getBBBCCCVVV(this._bookNum, this._chapterNum, 0);\n }\n /**\n * Gets the reference as a comparable integer where the book,\n * chapter, and verse each occupy three digits. If verse is not null\n * (i.e., this reference represents a complex reference with verse\n * segments or bridge) this cannot be used for an exact comparison.\n */\n get BBBCCCVVV() {\n return i.getBBBCCCVVV(this._bookNum, this._chapterNum, this._verseNum);\n }\n /**\n * Gets whether the verse is defined as an excluded verse in the versification.\n * Does not handle verse ranges.\n */\n // eslint-disable-next-line @typescript-eslint/class-literal-property-style\n get isExcluded() {\n return !1;\n }\n /**\n * Parses the reference in the specified string.\n * Optionally versification can follow reference as in GEN 3:11/4\n * Throw an exception if\n * - invalid book name\n * - chapter number is missing or not a number\n * - verse number is missing or does not start with a number\n * - versification is invalid\n * @param verseStr - string to parse e.g. 'MAT 3:11'\n */\n parse(e) {\n if (e = e.replace(this.rtlMark, \"\"), e.includes(\"/\")) {\n const o = e.split(\"/\");\n if (e = o[0], o.length > 1)\n try {\n const u = +o[1].trim();\n this.versification = new c(l[u]);\n } catch {\n throw new v(\"Invalid reference : \" + e);\n }\n }\n const s = e.trim().split(\" \");\n if (s.length !== 2)\n throw new v(\"Invalid reference : \" + e);\n const r = s[1].split(\":\"), a = +r[0];\n if (r.length !== 2 || m.bookIdToNumber(s[0]) === 0 || !Number.isInteger(a) || a < 0 || !i.isVerseParseable(r[1]))\n throw new v(\"Invalid reference : \" + e);\n this.updateInternal(s[0], r[0], r[1]);\n }\n /**\n * Simplifies this verse ref so that it has no bridging of verses or\n * verse segments like `'1a'`.\n */\n simplify() {\n this._verse = void 0;\n }\n /**\n * Makes a clone of the reference.\n *\n * @returns The cloned VerseRef.\n */\n clone() {\n return new i(this);\n }\n toString() {\n const e = this.book;\n return e === \"\" ? \"\" : `${e} ${this.chapter}:${this.verse}`;\n }\n toJSON() {\n let e = this.verse;\n (e === \"\" || e === this.verseNum.toString()) && (e = void 0);\n const s = {\n book: this.book,\n chapterNum: this.chapterNum,\n verseNum: this.verseNum,\n verse: e,\n versificationStr: this.versificationStr\n };\n return e || delete s.verse, s;\n }\n /**\n * Compares this `VerseRef` with supplied one.\n * @param verseRef - object to compare this one to.\n * @returns `true` if this `VerseRef` is equal to the supplied one, `false` otherwise.\n */\n equals(e) {\n return e instanceof i ? e._bookNum === this._bookNum && e._chapterNum === this._chapterNum && e._verseNum === this._verseNum && e.verse === this.verse && (e.versification == null && this.versification == null || e.versification != null && this.versification != null && e.versification.equals(this.versification)) : !1;\n }\n /**\n * Enumerate all individual verses contained in a VerseRef.\n * Verse ranges are indicated by \"-\" and consecutive verses by \",\"s.\n * Examples:\n * GEN 1:2 returns GEN 1:2\n * GEN 1:1a-3b,5 returns GEN 1:1a, GEN 1:2, GEN 1:3b, GEN 1:5\n * GEN 1:2a-2c returns //! ??????\n *\n * @param specifiedVersesOnly - if set to true return only verses that are\n * explicitly specified only, not verses within a range. Defaults to `false`.\n * @param verseRangeSeparators - Verse range separators.\n * Defaults to `VerseRef.verseRangeSeparators`.\n * @param verseSequenceSeparators - Verse sequence separators.\n * Defaults to `VerseRef.verseSequenceIndicators`.\n * @returns An array of all single verse references in this VerseRef.\n */\n allVerses(e = !1, s = i.verseRangeSeparators, r = i.verseSequenceIndicators) {\n if (this._verse == null || this.chapterNum <= 0)\n return [this.clone()];\n const a = [], o = E(this._verse, r);\n for (const u of o.map((f) => E(f, s))) {\n const f = this.clone();\n f.verse = u[0];\n const d = f.verseNum;\n if (a.push(f), u.length > 1) {\n const b = this.clone();\n if (b.verse = u[1], !e)\n for (let p = d + 1; p < b.verseNum; p++) {\n const J = new i(\n this._bookNum,\n this._chapterNum,\n p,\n this.versification\n );\n this.isExcluded || a.push(J);\n }\n a.push(b);\n }\n }\n return a;\n }\n /**\n * Validates a verse number using the supplied separators rather than the defaults.\n */\n validateVerse(e, s) {\n if (!this.verse)\n return this.internalValid;\n let r = 0;\n for (const a of this.allVerses(!0, e, s)) {\n const o = a.internalValid;\n if (o !== 0)\n return o;\n const u = a.BBBCCCVVV;\n if (r > u)\n return 3;\n if (r === u)\n return 4;\n r = u;\n }\n return 0;\n }\n /**\n * Gets whether a single verse reference is valid.\n */\n get internalValid() {\n return this.versification == null ? 1 : this._bookNum <= 0 || this._bookNum > m.lastBook ? 2 : (m.isCanonical(this._bookNum), 0);\n }\n setEmpty(e = i.defaultVersification) {\n this._bookNum = 0, this._chapterNum = -1, this._verse = void 0, this.versification = e;\n }\n updateInternal(e, s, r) {\n this.bookNum = m.bookIdToNumber(e), this.chapter = s, this.verse = r;\n }\n};\nn(i, \"defaultVersification\", c.English), n(i, \"verseRangeSeparator\", \"-\"), n(i, \"verseSequenceIndicator\", \",\"), n(i, \"verseRangeSeparators\", [i.verseRangeSeparator]), n(i, \"verseSequenceIndicators\", [i.verseSequenceIndicator]), n(i, \"chapterDigitShifter\", 1e3), n(i, \"bookDigitShifter\", i.chapterDigitShifter * i.chapterDigitShifter), n(i, \"bcvMaxValue\", i.chapterDigitShifter - 1), /**\n * The valid status of the VerseRef.\n */\nn(i, \"ValidStatusType\", D);\nlet M = i;\nclass v extends Error {\n}\nexport {\n _ as BookSet,\n m as Canon,\n c as ScrVers,\n l as ScrVersType,\n M as VerseRef,\n v as VerseRefException\n};\n//# sourceMappingURL=index.es.js.map\n","import React from 'react';\nimport * as DropdownMenuPrimitive from '@radix-ui/react-dropdown-menu';\nimport { Check, ChevronRight, Circle } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport const DropdownMenu = DropdownMenuPrimitive.Root;\n\nexport const DropdownMenuTrigger = DropdownMenuPrimitive.Trigger;\n\nexport const DropdownMenuGroup = DropdownMenuPrimitive.Group;\n\nexport const DropdownMenuPortal = DropdownMenuPrimitive.Portal;\n\nexport const DropdownMenuSub = DropdownMenuPrimitive.Sub;\n\nexport const DropdownMenuRadioGroup = DropdownMenuPrimitive.RadioGroup;\n\nexport type DropdownMenuSubTriggerProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.SubTrigger\n> & {\n className?: string;\n inset?: boolean;\n};\n\nexport type DropdownMenuSubContentProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.SubContent\n> & {\n className?: string;\n};\n\nexport type DropdownMenuContentProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Content\n> & {\n className?: string;\n sideOffset?: number;\n};\n\nexport type DropdownMenuItemProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Item\n> & {\n className?: string;\n inset?: boolean;\n};\n\nexport type DropdownMenuCheckboxItemProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.CheckboxItem\n> & {\n className?: string;\n checked?: boolean;\n};\n\nexport type DropdownMenuRadioItemProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.RadioItem\n> & {\n className?: string;\n};\n\nexport type DropdownMenuLabelProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Label\n> & {\n className?: string;\n inset?: boolean;\n};\n\nexport type DropdownMenuSeparatorProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Separator\n> & {\n className?: string;\n};\n\nexport type DropdownMenuShortcutProps = React.HTMLAttributes & {\n className?: string;\n};\n\nexport const DropdownMenuSubTrigger = React.forwardRef<\n React.ElementRef,\n DropdownMenuSubTriggerProps\n>(({ className, inset, children, ...props }, ref) => (\n \n {children}\n \n \n));\nDropdownMenuSubTrigger.displayName = DropdownMenuPrimitive.SubTrigger.displayName;\n\nexport const DropdownMenuSubContent = React.forwardRef<\n React.ElementRef,\n DropdownMenuSubContentProps\n>(({ className, ...props }, ref) => (\n \n));\nDropdownMenuSubContent.displayName = DropdownMenuPrimitive.SubContent.displayName;\n\nexport const DropdownMenuContent = React.forwardRef<\n React.ElementRef,\n DropdownMenuContentProps\n>(({ className, sideOffset = 4, ...props }, ref) => (\n \n \n \n));\nDropdownMenuContent.displayName = DropdownMenuPrimitive.Content.displayName;\n\n/**\n * TODO: fix: direction is not automatically handled by this component, so that shortcuts are\n * display always to the right\n */\nexport const DropdownMenuItem = React.forwardRef<\n React.ElementRef,\n DropdownMenuItemProps\n>(({ className, inset, ...props }, ref) => (\n \n));\nDropdownMenuItem.displayName = DropdownMenuPrimitive.Item.displayName;\n\nexport const DropdownMenuCheckboxItem = React.forwardRef<\n React.ElementRef,\n DropdownMenuCheckboxItemProps\n>(({ className, children, checked, ...props }, ref) => (\n \n \n \n \n \n \n {children}\n \n));\nDropdownMenuCheckboxItem.displayName = DropdownMenuPrimitive.CheckboxItem.displayName;\n\nexport const DropdownMenuRadioItem = React.forwardRef<\n React.ElementRef,\n DropdownMenuRadioItemProps\n>(({ className, children, ...props }, ref) => (\n \n \n \n \n \n \n {children}\n \n));\nDropdownMenuRadioItem.displayName = DropdownMenuPrimitive.RadioItem.displayName;\n\nexport const DropdownMenuLabel = React.forwardRef<\n React.ElementRef,\n DropdownMenuLabelProps\n>(({ className, inset, ...props }, ref) => (\n \n));\nDropdownMenuLabel.displayName = DropdownMenuPrimitive.Label.displayName;\n\nexport const DropdownMenuSeparator = React.forwardRef<\n React.ElementRef,\n DropdownMenuSeparatorProps\n>(({ className, ...props }, ref) => (\n \n));\nDropdownMenuSeparator.displayName = DropdownMenuPrimitive.Separator.displayName;\n\nexport function DropdownMenuShortcut({ className, ...props }: DropdownMenuShortcutProps) {\n return (\n \n );\n}\nDropdownMenuShortcut.displayName = 'DropdownMenuShortcut';\n","import { Canon } from '@sillsdev/scripture';\nimport { PropsWithChildren, KeyboardEvent, forwardRef } from 'react';\nimport { DropdownMenuItem as ShadDropdownMenuItem } from '@/components/shadcn-ui/dropdown-menu';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport type BookType = 'OT' | 'NT' | 'DC';\n\ntype BookMenuItemProps = PropsWithChildren<{\n /** String id of book */\n bookId: string;\n /** Callback to run when a book menu item is selected */\n handleSelectBook: () => void;\n /** Indicates if this menu item is currently selected */\n isSelected: boolean;\n /** Function that is called upon highlighting a book in the dropdown menu */\n handleHighlightBook: () => void;\n /**\n * Function that is called on pressing a key\n *\n * @param event Event that contains information about the key stroke\n */\n handleKeyDown: (event: KeyboardEvent) => void;\n /**\n * Type of book associated with this menu item, coordinates color labels ? Mock up has the labels\n * coordinated to genre\n */\n bookType: BookType;\n}>;\n\nconst BookMenuItem = forwardRef(\n (\n {\n bookId,\n handleSelectBook,\n isSelected,\n handleHighlightBook,\n handleKeyDown,\n bookType,\n children,\n }: BookMenuItemProps,\n ref,\n ) => {\n return (\n {\n // preventDefault() here prevents the entire dropdown menu from closing when selecting this item\n event.preventDefault();\n handleSelectBook();\n }}\n onKeyDown={(event: KeyboardEvent) => {\n handleKeyDown(event);\n }}\n onFocus={handleHighlightBook}\n onMouseMove={handleHighlightBook}\n >\n \n {Canon.bookIdToEnglishName(bookId)}\n \n {isSelected &&
    {children}
    }\n \n );\n },\n);\n\nexport default BookMenuItem;\n","import { cn } from '@/utils/shadcn-ui.util';\nimport { useCallback } from 'react';\n\nexport type ChapterSelectProps = {\n /**\n * Callback to run when a chapter div is selected\n *\n * @param chapterNumber Number of the chapter that has been selected\n */\n handleSelectChapter: (chapterNumber: number) => void;\n /** The highest chapter number in the book (of course equal to number of chapters in the book) */\n endChapter: number;\n /** The chapter number that is currently selected */\n activeChapter: number;\n /** The chapter number that is currently highlighted using keyboard or mouse navigation */\n highlightedChapter: number;\n /**\n * Callback to run when a chapter is highlighted by the user\n *\n * @param chapterNumber The chapter that is highlighted\n */\n handleHighlightedChapter: (chapterNumber: number) => void;\n};\n\nfunction ChapterSelect({\n handleSelectChapter,\n endChapter,\n activeChapter,\n highlightedChapter,\n handleHighlightedChapter,\n}: ChapterSelectProps) {\n const chapters = Array.from({ length: endChapter }, (_, i) => i + 1);\n\n const handleMouse = useCallback(\n (chapterNumber: number) => {\n handleHighlightedChapter(chapterNumber);\n },\n [handleHighlightedChapter],\n );\n\n return (\n
    \n {chapters.map((chapter) => (\n {\n event.preventDefault();\n event.stopPropagation();\n handleSelectChapter(chapter);\n }}\n role=\"button\"\n onKeyDown={(event) => {\n if (event.key === 'Enter') {\n handleSelectChapter(chapter);\n }\n }}\n tabIndex={0}\n onMouseMove={() => handleMouse(chapter)}\n >\n {chapter}\n
    \n ))}\n
    \n );\n}\n\nexport default ChapterSelect;\n","import { DropdownMenuLabel as ShadDropdownMenuLabel } from '@/components/shadcn-ui/dropdown-menu';\nimport { Bookmark, Clock, ArrowDownWideNarrow } from 'lucide-react';\n\nexport type GoToMenuItemProps = {\n handleSort: () => void;\n handleLocationHistory: () => void;\n handleBookmarks: () => void;\n};\n\nfunction GoToMenuItem({ handleSort, handleLocationHistory, handleBookmarks }: GoToMenuItemProps) {\n return (\n \n

    Go To

    \n
    \n \n \n \n
    \n
    \n );\n}\n\nexport default GoToMenuItem;\n","import BookChapterInput from '@/components/advanced/book-chapter-control/book-chapter-input.component';\nimport BookMenuItem, {\n BookType,\n} from '@/components/advanced/book-chapter-control/book-menu-item.component';\nimport ChapterSelect from '@/components/advanced/book-chapter-control/chapter-select.component';\nimport GoToMenuItem from '@/components/advanced/book-chapter-control/go-to-menu-item.component';\nimport {\n DropdownMenu as ShadDropdownMenu,\n DropdownMenuContent as ShadDropdownMenuContent,\n DropdownMenuLabel as ShadDropdownMenuLabel,\n DropdownMenuSeparator as ShadDropdownMenuSeparator,\n DropdownMenuTrigger as ShadDropdownMenuTrigger,\n} from '@/components/shadcn-ui/dropdown-menu';\nimport { Canon } from '@sillsdev/scripture';\nimport { ScriptureReference, getChaptersForBook } from 'platform-bible-utils';\nimport {\n KeyboardEvent as ReactKeyboardEvent,\n useCallback,\n useEffect,\n useLayoutEffect,\n useRef,\n useState,\n} from 'react';\n\ntype BookTypeLabels = {\n [bookType in BookType]: string;\n};\ntype BookChapterControlProps = {\n scrRef: ScriptureReference;\n handleSubmit: (scrRef: ScriptureReference) => void;\n};\n\nconst ALL_BOOK_IDS = Canon.allBookIds;\nconst BOOK_TYPE_LABELS: BookTypeLabels = {\n OT: 'Old Testament',\n NT: 'New Testament',\n DC: 'Deuterocanon',\n};\nconst BOOK_TYPE_ARRAY: BookType[] = ['OT', 'NT', 'DC'];\n// This is the height of three menu items to offset scrolling to the selected menu item\n// If you use menuItemRef.clientHeight- includes height of chapter div which is too big\nconst SCROLL_OFFSET = 32 + 32 + 32;\nconst SEARCH_QUERY_FORMATS = [\n /^(\\w+)$/i, // Matches a single word (book name or id)\n /^(\\w+)(?:\\s(\\d+))$/i, // Matches a word followed by a chapter number\n /^(\\w+)(?:\\s(\\d+):(\\d+))$/i, // Matches a word followed by a chapter and verse number\n];\nconst fetchGroupedBooks = (bookType: BookType) => {\n const groupedBooks = {\n OT: ALL_BOOK_IDS.filter((bookId) => Canon.isBookOT(bookId)),\n NT: ALL_BOOK_IDS.filter((bookId) => Canon.isBookNT(bookId)),\n DC: ALL_BOOK_IDS.filter((bookId) => Canon.isBookDC(bookId)),\n };\n return groupedBooks[bookType];\n};\nconst fetchEndChapter = (bookId: string) => {\n // getChaptersForBook returns -1 if not found in scrBookData\n // scrBookData only includes OT and NT, so all DC will return -1\n return getChaptersForBook(Canon.bookIdToNumber(bookId));\n};\n\n/**\n * Gets all of the English names from book ids\n *\n * @returns String[]\n */\nfunction getAllEnglishNames(): string[] {\n const allEnglishNames = ALL_BOOK_IDS.map((bookId) => {\n return Canon.bookIdToEnglishName(bookId);\n });\n return allEnglishNames;\n}\n\n/**\n * Determines if bookName is in allEnglishNames\n *\n * @param bookName Book English name\n * @returns True if bookName is included, false otherwise\n */\nfunction isValidBookEnglishName(bookName: string): boolean {\n return getAllEnglishNames().includes(bookName);\n}\n\n/**\n * Gets a bookId from given English name\n *\n * @param bookName Book English name\n * @returns BookId of provided bookName, undefined otherwise\n */\nfunction getBookIdFromEnglishName(bookName: string): string | undefined {\n // Convert bookName to lowercase and then capitalize the first letter\n const formattedBookName = bookName.toLowerCase().replace(/^\\w/, (c) => c.toUpperCase());\n\n if (isValidBookEnglishName(formattedBookName)) {\n const matchingBookId = ALL_BOOK_IDS.find((bookId) => {\n return Canon.bookIdToEnglishName(bookId) === formattedBookName;\n });\n return matchingBookId;\n }\n\n return undefined;\n}\n\nfunction BookChapterControl({ scrRef, handleSubmit }: BookChapterControlProps) {\n const [searchQuery, setSearchQuery] = useState('');\n const [selectedBookId, setSelectedBookId] = useState(\n Canon.bookNumberToId(scrRef.bookNum),\n );\n const [highlightedChapter, setHighlightedChapter] = useState(scrRef.chapterNum ?? 0);\n const [highlightedBookId, setHighlightedBookId] = useState(\n Canon.bookNumberToId(scrRef.bookNum),\n );\n const [isContentOpen, setIsContentOpen] = useState(false);\n const [isContentOpenDelayed, setIsContentOpenDelayed] = useState(isContentOpen);\n\n // This ref will always be defined\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const inputRef = useRef(undefined!);\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const contentRef = useRef(undefined!);\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const menuItemRef = useRef(undefined!);\n\n const fetchFilteredBooks = useCallback(\n (bookType: BookType) => {\n return fetchGroupedBooks(bookType).filter((bookId: string) => {\n const englishNameLowerCase = Canon.bookIdToEnglishName(bookId).toLowerCase();\n const normalizedQuery = searchQuery.replace(/[^a-zA-Z]/g, '').toLowerCase();\n return (\n englishNameLowerCase.includes(normalizedQuery) || // Match book name\n bookId.toLowerCase().includes(normalizedQuery) // Match book ID\n );\n });\n },\n [searchQuery],\n );\n\n const handleSearchInput = (searchString: string) => {\n setSearchQuery(searchString);\n };\n\n /**\n * Whether to prevent radix's logic from closing the dropdown. This is important because radix\n * tries to close the dropdown when the input first focuses, and we don't want it to do that. But\n * we don't want to prevent the dropdown from closing when we click away from the input, so we\n * don't want to just keep it open if the input is focused\n */\n const shouldPreventAutoClosing = useRef(false);\n\n const controlMenuState = useCallback((open: boolean) => {\n if (shouldPreventAutoClosing.current) {\n shouldPreventAutoClosing.current = false;\n return;\n }\n setIsContentOpen(open);\n }, []);\n\n const updateReference = useCallback(\n (bookId: string, shouldClose: boolean, chapter?: number, verse?: number) => {\n setHighlightedChapter(\n Canon.bookNumberToId(scrRef.bookNum) !== bookId ? 1 : scrRef.chapterNum,\n );\n\n if (shouldClose || fetchEndChapter(bookId) === -1) {\n handleSubmit({\n bookNum: Canon.bookIdToNumber(bookId),\n chapterNum: chapter || 1,\n verseNum: verse || 1,\n });\n\n setIsContentOpen(false);\n setSearchQuery('');\n return;\n }\n\n setSelectedBookId(selectedBookId !== bookId ? bookId : '');\n setIsContentOpen(!shouldClose);\n },\n [handleSubmit, scrRef.bookNum, scrRef.chapterNum, selectedBookId],\n );\n\n const handleSelectChapter = (chapterNumber: number) => {\n if (chapterNumber <= 0 || chapterNumber > fetchEndChapter(selectedBookId)) {\n return;\n }\n updateReference(selectedBookId, true, chapterNumber);\n };\n\n const handleInputSubmit = useCallback(() => {\n SEARCH_QUERY_FORMATS.forEach((format) => {\n const matches = searchQuery.match(format);\n if (matches) {\n // Book should be a bookId or an english name\n const [book, chapter = undefined, verse = undefined] = matches.slice(1);\n const englishName = getBookIdFromEnglishName(book);\n\n if (Canon.isBookIdValid(book) || englishName) {\n updateReference(\n englishName ?? book,\n true,\n chapter ? parseInt(chapter, 10) : 1,\n verse ? parseInt(verse, 10) : 1,\n );\n }\n }\n });\n }, [updateReference, searchQuery]);\n\n const handleKeyDownInput = useCallback(\n (event: ReactKeyboardEvent) => {\n if (!isContentOpen) {\n setIsContentOpen(true);\n } else if (event.key === 'ArrowDown' || event.key === 'ArrowUp') {\n if (\n typeof menuItemRef !== 'undefined' &&\n // Ref uses null\n // eslint-disable-next-line no-null/no-null\n menuItemRef.current !== null\n ) {\n menuItemRef.current.focus();\n } else if (\n typeof contentRef !== 'undefined' &&\n // Ref uses null\n // eslint-disable-next-line no-null/no-null\n contentRef.current !== null\n ) {\n contentRef.current.focus();\n }\n event.preventDefault();\n }\n },\n [isContentOpen],\n );\n\n const handleKeyDownContent = (event: ReactKeyboardEvent) => {\n // When the dropdown menu has focus, key strokes should give focus to the input component,\n // unless they're navigation keys (arrows and enter)\n const { key } = event;\n if (\n key === 'ArrowRight' ||\n key === 'ArrowLeft' ||\n key === 'ArrowDown' ||\n key === 'ArrowUp' ||\n key === 'Enter'\n ) {\n return;\n }\n\n inputRef.current.dispatchEvent(new KeyboardEvent('keydown', { key }));\n inputRef.current.focus();\n };\n\n const handleKeyDownMenuItem = (event: ReactKeyboardEvent) => {\n const { key } = event;\n if (highlightedBookId === selectedBookId) {\n if (key === 'Enter') {\n event.preventDefault();\n updateReference(selectedBookId, true, highlightedChapter);\n return;\n }\n\n let chapterOffSet = 0;\n if (key === 'ArrowRight') {\n if (highlightedChapter < fetchEndChapter(highlightedBookId)) {\n chapterOffSet = 1;\n } else {\n event.preventDefault();\n return;\n }\n } else if (key === 'ArrowLeft') {\n if (highlightedChapter > 1) {\n chapterOffSet = -1;\n } else {\n event.preventDefault();\n return;\n }\n } else if (key === 'ArrowDown') {\n chapterOffSet = 6;\n } else if (key === 'ArrowUp') {\n chapterOffSet = -6;\n }\n if (\n highlightedChapter + chapterOffSet <= 0 ||\n highlightedChapter + chapterOffSet > fetchEndChapter(highlightedBookId)\n ) {\n setHighlightedChapter(0);\n } else if (chapterOffSet !== 0) {\n setHighlightedChapter(highlightedChapter + chapterOffSet);\n event.preventDefault();\n }\n }\n };\n\n useEffect(() => {\n if (selectedBookId === highlightedBookId) {\n if (selectedBookId === Canon.bookNumberToId(scrRef.bookNum)) {\n setHighlightedChapter(scrRef.chapterNum);\n } else {\n setHighlightedChapter(1);\n }\n } else {\n setHighlightedChapter(0);\n }\n }, [highlightedBookId, scrRef.bookNum, scrRef.chapterNum, selectedBookId]);\n\n // The purpose of these useLayoutEffects and timeout is to delay the scroll just\n // enough so that the refs are defined and available when they are used after the timeout\n useLayoutEffect(() => {\n setIsContentOpenDelayed(isContentOpen);\n }, [isContentOpen]);\n\n useLayoutEffect(() => {\n const scrollTimeout = setTimeout(() => {\n if (isContentOpenDelayed && contentRef.current && menuItemRef.current) {\n const menuItemOffsetTop = menuItemRef.current.offsetTop;\n const scrollPosition = menuItemOffsetTop - SCROLL_OFFSET;\n contentRef.current.scrollTo({ top: scrollPosition, behavior: 'instant' });\n }\n }, 10);\n return () => {\n clearTimeout(scrollTimeout);\n };\n }, [isContentOpenDelayed]);\n\n return (\n
    \n \n \n {\n setSelectedBookId(Canon.bookNumberToId(scrRef.bookNum));\n setHighlightedBookId(Canon.bookNumberToId(scrRef.bookNum));\n setHighlightedChapter(scrRef.chapterNum > 0 ? scrRef.chapterNum : 0);\n setIsContentOpen(true);\n inputRef.current.focus();\n }}\n onFocus={() => {\n // Radix thinks we want to close because the input is being focused. Prevent that\n shouldPreventAutoClosing.current = true;\n }}\n handleSubmit={handleInputSubmit}\n placeholder={`${Canon.bookNumberToEnglishName(scrRef.bookNum)} ${scrRef.chapterNum}:${scrRef.verseNum}`}\n />\n \n \n console.log('sorting')}\n handleLocationHistory={() => console.log('location history')}\n handleBookmarks={() => console.log('bookmarks')}\n />\n {BOOK_TYPE_ARRAY.map(\n (bookType, bookTypeIndex) =>\n fetchFilteredBooks(bookType).length > 0 && (\n
    \n \n {BOOK_TYPE_LABELS[bookType]}\n \n\n {fetchFilteredBooks(bookType).map((bookId) => (\n
    \n updateReference(bookId, false)}\n isSelected={selectedBookId === bookId}\n handleHighlightBook={() => setHighlightedBookId(bookId)}\n handleKeyDown={handleKeyDownMenuItem}\n bookType={bookType}\n ref={(element: HTMLDivElement) => {\n if (selectedBookId === bookId) menuItemRef.current = element;\n }}\n >\n {\n setHighlightedChapter(chapterNumber);\n }}\n />\n \n
    \n ))}\n {BOOK_TYPE_ARRAY.length - 1 !== bookTypeIndex ? (\n \n ) : undefined}\n
    \n ),\n )}\n \n
    \n
    \n );\n}\n\nexport default BookChapterControl;\n","import React from 'react';\nimport { Slot } from '@radix-ui/react-slot';\nimport { cva, type VariantProps } from 'class-variance-authority';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport const buttonVariants = cva(\n 'pr-twp tw-inline-flex tw-items-center tw-justify-center tw-whitespace-nowrap tw-rounded-md tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-colors focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50',\n {\n variants: {\n variant: {\n default: 'tw-bg-primary tw-text-primary-foreground hover:tw-bg-primary/90',\n destructive: 'tw-bg-destructive tw-text-destructive-foreground hover:tw-bg-destructive/90',\n outline:\n 'tw-border tw-border-input tw-bg-background hover:tw-bg-accent hover:tw-text-accent-foreground',\n secondary: 'tw-bg-secondary tw-text-secondary-foreground hover:tw-bg-secondary/80',\n ghost: 'hover:tw-bg-accent hover:tw-text-accent-foreground',\n link: 'tw-text-primary tw-underline-offset-4 hover:tw-underline',\n },\n size: {\n default: 'tw-h-10 tw-px-4 tw-py-2',\n sm: 'tw-h-9 tw-rounded-md tw-px-3',\n lg: 'tw-h-11 tw-rounded-md tw-px-8',\n icon: 'tw-h-10 tw-w-10',\n },\n },\n defaultVariants: {\n variant: 'default',\n size: 'default',\n },\n },\n);\n\nexport interface ButtonProps\n extends React.ButtonHTMLAttributes,\n VariantProps {\n asChild?: boolean;\n}\n\nexport const Button = React.forwardRef(\n ({ className, variant, size, asChild = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'button';\n return (\n \n );\n },\n);\nButton.displayName = 'Button';\n","import React from 'react';\nimport * as LabelPrimitive from '@radix-ui/react-label';\nimport { cva, type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst labelVariants = cva(\n 'tw-text-sm tw-font-medium tw-leading-none peer-disabled:tw-cursor-not-allowed peer-disabled:tw-opacity-70',\n);\n\nexport const Label = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef & VariantProps\n>(({ className, ...props }, ref) => (\n \n));\nLabel.displayName = LabelPrimitive.Root.displayName;\n","import React from 'react';\nimport * as RadioGroupPrimitive from '@radix-ui/react-radio-group';\nimport { Circle } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst RadioGroup = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => {\n return (\n \n );\n});\nRadioGroup.displayName = RadioGroupPrimitive.Root.displayName;\n\nconst RadioGroupItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => {\n return (\n \n \n \n \n \n );\n});\nRadioGroupItem.displayName = RadioGroupPrimitive.Item.displayName;\n\nexport { RadioGroup, RadioGroupItem };\n","import React from 'react';\nimport * as PopoverPrimitive from '@radix-ui/react-popover';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Popover = PopoverPrimitive.Root;\n\nconst PopoverTrigger = PopoverPrimitive.Trigger;\n\nconst PopoverContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, align = 'center', sideOffset = 4, ...props }, ref) => (\n \n \n \n));\nPopoverContent.displayName = PopoverPrimitive.Content.displayName;\n\nexport { Popover, PopoverTrigger, PopoverContent };\n","import React from 'react';\nimport * as DialogPrimitive from '@radix-ui/react-dialog';\nimport { X } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Dialog = DialogPrimitive.Root;\n\nconst DialogTrigger = DialogPrimitive.Trigger;\n\nconst DialogPortal = DialogPrimitive.Portal;\n\nconst DialogClose = DialogPrimitive.Close;\n\nconst DialogOverlay = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nDialogOverlay.displayName = DialogPrimitive.Overlay.displayName;\n\nconst DialogContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, ...props }, ref) => (\n \n \n \n {children}\n \n \n Close\n \n \n \n));\nDialogContent.displayName = DialogPrimitive.Content.displayName;\n\nfunction DialogHeader({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nDialogHeader.displayName = 'DialogHeader';\n\nfunction DialogFooter({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nDialogFooter.displayName = 'DialogFooter';\n\nconst DialogTitle = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nDialogTitle.displayName = DialogPrimitive.Title.displayName;\n\nconst DialogDescription = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nDialogDescription.displayName = DialogPrimitive.Description.displayName;\n\nexport {\n Dialog,\n DialogPortal,\n DialogOverlay,\n DialogClose,\n DialogTrigger,\n DialogContent,\n DialogHeader,\n DialogFooter,\n DialogTitle,\n DialogDescription,\n};\n","import React from 'react';\nimport { type DialogProps } from '@radix-ui/react-dialog';\nimport { Command as CommandPrimitive } from 'cmdk';\nimport { Search } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Dialog, DialogContent } from '@/components/shadcn-ui/dialog';\n\nconst Command = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nCommand.displayName = CommandPrimitive.displayName;\n\ninterface CommandDialogProps extends DialogProps {}\n\nfunction CommandDialog({ children, ...props }: CommandDialogProps) {\n return (\n \n \n \n {children}\n \n \n \n );\n}\n\nconst CommandInput = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n
    \n \n \n
    \n));\n\nCommandInput.displayName = CommandPrimitive.Input.displayName;\n\nconst CommandList = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\n\nCommandList.displayName = CommandPrimitive.List.displayName;\n\nconst CommandEmpty = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>((props, ref) => (\n \n));\n\nCommandEmpty.displayName = CommandPrimitive.Empty.displayName;\n\nconst CommandGroup = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\n\nCommandGroup.displayName = CommandPrimitive.Group.displayName;\n\nconst CommandSeparator = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nCommandSeparator.displayName = CommandPrimitive.Separator.displayName;\n\nconst CommandItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\n\nCommandItem.displayName = CommandPrimitive.Item.displayName;\n\nfunction CommandShortcut({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nCommandShortcut.displayName = 'CommandShortcut';\n\nexport {\n Command,\n CommandDialog,\n CommandInput,\n CommandList,\n CommandEmpty,\n CommandGroup,\n CommandItem,\n CommandShortcut,\n CommandSeparator,\n};\n","import { useState } from 'react';\nimport { Check, ChevronsUpDown } from 'lucide-react';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport { Popover, PopoverContent, PopoverTrigger } from '@/components/shadcn-ui/popover';\nimport {\n Command,\n CommandEmpty,\n CommandInput,\n CommandItem,\n CommandList,\n} from '@/components/shadcn-ui/command';\nimport { PopoverProps } from '@radix-ui/react-popover';\n\nexport type ComboBoxLabelOption = { label: string };\nexport type ComboBoxOption = string | number | ComboBoxLabelOption;\n\nexport type ComboBoxProps = {\n /** Optional unique identifier */\n id?: string;\n /** Text label title for combobox */\n /** List of available options for the dropdown menu */\n options?: readonly T[];\n /** Additional css classes to help with unique styling of the combo box button */\n buttonClassName?: string;\n /** Additional css classes to help with unique styling of the combo box popover */\n popoverContentClassName?: string;\n /**\n * The selected value that the combo box currently holds. Must be shallow equal to one of the\n * options entries.\n */\n value?: T;\n /** Triggers when content of textfield is changed */\n onChange?: (newValue: T) => void;\n /** Used to determine the string value for a given option. */\n getOptionLabel?: (option: ComboBoxOption) => string;\n /** Text displayed on button if `value` is undefined */\n buttonPlaceholder?: string;\n /** Placeholder text for text field */\n textPlaceholder?: string;\n /** Text to display when no options match input */\n commandEmptyMessage?: string;\n /** Variant of button */\n buttonVariant?: ButtonProps['variant'];\n /** Text direction ltr or rtl */\n dir?: Direction;\n /** Optional boolean to set if trigger should be disabled */\n isDisabled?: boolean;\n} & PopoverProps;\n\ntype Direction = 'ltr' | 'rtl';\n\nfunction getOptionLabelDefault(option: ComboBoxOption): string {\n if (typeof option === 'string') {\n return option;\n }\n if (typeof option === 'number') {\n return option.toString();\n }\n return option.label;\n}\n\n/**\n * Autocomplete input and command palette with a list of suggestions.\n *\n * Thanks to Shadcn for heavy inspiration and documentation\n * https://ui.shadcn.com/docs/components/combobox\n */\nfunction ComboBox({\n id,\n options = [],\n buttonClassName,\n popoverContentClassName,\n value,\n onChange = () => {},\n getOptionLabel = getOptionLabelDefault,\n buttonPlaceholder = '',\n textPlaceholder = '',\n commandEmptyMessage = 'No option found',\n buttonVariant = 'outline',\n dir = 'ltr',\n isDisabled = false,\n ...props\n}: ComboBoxProps) {\n const [open, setOpen] = useState(false);\n\n return (\n \n \n \n \n {value ? getOptionLabel(value) : buttonPlaceholder}\n \n \n \n \n \n \n \n {commandEmptyMessage}\n \n {options.map((option) => (\n {\n onChange(option);\n setOpen(false);\n }}\n >\n \n {getOptionLabel(option)}\n \n ))}\n \n \n \n \n );\n}\n\nexport default ComboBox;\n","import { useMemo } from 'react';\nimport ComboBox from '@/components/basics/combo-box.component';\nimport { Label } from '@/components/shadcn-ui/label';\n\nexport type ChapterRangeSelectorProps = {\n startChapter: number;\n endChapter: number;\n handleSelectStartChapter: (chapter: number) => void;\n handleSelectEndChapter: (chapter: number) => void;\n isDisabled?: boolean;\n chapterCount: number;\n};\n\nexport default function ChapterRangeSelector({\n startChapter,\n endChapter,\n handleSelectStartChapter,\n handleSelectEndChapter,\n isDisabled = false,\n chapterCount,\n}: ChapterRangeSelectorProps) {\n const chapterOptions = useMemo(\n () => Array.from({ length: chapterCount }, (_, index) => index + 1),\n [chapterCount],\n );\n\n const onChangeStartChapter = (value: number) => {\n handleSelectStartChapter(value);\n if (value > endChapter) {\n handleSelectEndChapter(value);\n }\n };\n\n const onChangeEndChapter = (value: number) => {\n handleSelectEndChapter(value);\n if (value < startChapter) {\n handleSelectStartChapter(value);\n }\n };\n\n return (\n <>\n \n option.toString()}\n value={startChapter}\n />\n\n \n option.toString()}\n value={endChapter}\n />\n \n );\n}\n","import { Button } from '@/components/shadcn-ui/button';\nimport { Label } from '@/components/shadcn-ui/label';\nimport { RadioGroup, RadioGroupItem } from '@/components/shadcn-ui/radio-group';\nimport { Canon } from '@sillsdev/scripture';\nimport { LocalizedStringValue } from 'platform-bible-utils';\nimport { useState } from 'react';\nimport ChapterRangeSelector, {\n ChapterRangeSelectorProps,\n} from '../basics/chapter-range-selector.component';\n\nexport enum BookSelectionMode {\n CURRENT_BOOK = 'current book',\n CHOOSE_BOOKS = 'choose books',\n}\n\n/**\n * Object containing all keys used for localization in this component. If you're using this\n * component in an extension, you can pass it into the useLocalizedStrings hook to easily obtain the\n * localized strings and pass them into the localizedStrings prop of this component\n */\nexport const BOOK_SELECTOR_STRING_KEYS = Object.freeze([\n '%webView_bookSelector_currentBook%',\n '%webView_bookSelector_choose%',\n '%webView_bookSelector_chooseBooks%',\n] as const);\n\nexport type BookSelectorLocalizedStrings = {\n [localizedInventoryKey in (typeof BOOK_SELECTOR_STRING_KEYS)[number]]?: LocalizedStringValue;\n};\n\n/**\n * Gets the localized value for the provided key\n *\n * @param strings Object containing localized string\n * @param key Key for a localized string\n * @returns The localized value for the provided key, if available. Returns the key if no localized\n * value is available\n */\nconst localizeString = (\n strings: BookSelectorLocalizedStrings,\n key: keyof BookSelectorLocalizedStrings,\n) => {\n return strings[key] ?? key;\n};\n\ntype BookSelectorProps = ChapterRangeSelectorProps & {\n handleBookSelectionModeChange: (newMode: BookSelectionMode) => void;\n currentBookName: string;\n onSelectBooks: () => void;\n selectedBookIds: string[];\n localizedStrings: BookSelectorLocalizedStrings;\n};\n\nexport default function BookSelector({\n handleBookSelectionModeChange,\n currentBookName,\n onSelectBooks,\n selectedBookIds,\n chapterCount,\n endChapter,\n handleSelectEndChapter,\n startChapter,\n handleSelectStartChapter,\n localizedStrings,\n}: BookSelectorProps) {\n const currentBookText = localizeString(localizedStrings, '%webView_bookSelector_currentBook%');\n const chooseText = localizeString(localizedStrings, '%webView_bookSelector_choose%');\n const chooseBooksText = localizeString(localizedStrings, '%webView_bookSelector_chooseBooks%');\n\n const [bookSelectionMode, setBookSelectionMode] = useState(\n BookSelectionMode.CURRENT_BOOK,\n );\n\n const onSelectionModeChange = (newMode: BookSelectionMode) => {\n setBookSelectionMode(newMode);\n handleBookSelectionModeChange(newMode);\n };\n\n return (\n onSelectionModeChange(value as BookSelectionMode)}\n >\n
    \n
    \n
    \n \n \n
    \n \n
    \n \n
    \n
    \n
    \n
    \n \n \n
    \n \n onSelectBooks()}\n >\n {chooseText}\n \n
    \n
    \n \n );\n}\n","import { DropdownMenuTrigger } from '@radix-ui/react-dropdown-menu';\nimport { FilterIcon } from 'lucide-react';\nimport { Table } from '@tanstack/react-table';\n\nimport { Button } from '@/components/shadcn-ui/button';\nimport {\n DropdownMenu,\n DropdownMenuCheckboxItem,\n DropdownMenuContent,\n DropdownMenuLabel,\n DropdownMenuSeparator,\n} from '@/components/shadcn-ui/dropdown-menu';\n\ninterface DataTableViewOptionsProps {\n table: Table;\n}\n\nfunction DataTableViewOptions({ table }: DataTableViewOptionsProps) {\n return (\n \n \n \n \n \n Toggle columns\n \n {table\n .getAllColumns()\n .filter((column) => column.getCanHide())\n .map((column) => {\n return (\n column.toggleVisibility(!!value)}\n >\n {column.id}\n \n );\n })}\n \n \n );\n}\n\nexport default DataTableViewOptions;\n","import React from 'react';\nimport * as SelectPrimitive from '@radix-ui/react-select';\nimport { Check, ChevronDown, ChevronUp } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Select = SelectPrimitive.Root;\n\nconst SelectGroup = SelectPrimitive.Group;\n\nconst SelectValue = SelectPrimitive.Value;\n\nconst SelectTrigger = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, ...props }, ref) => (\n span]:tw-line-clamp-1',\n className,\n )}\n {...props}\n >\n {children}\n \n \n \n \n));\nSelectTrigger.displayName = SelectPrimitive.Trigger.displayName;\n\nconst SelectScrollUpButton = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n));\nSelectScrollUpButton.displayName = SelectPrimitive.ScrollUpButton.displayName;\n\nconst SelectScrollDownButton = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n));\nSelectScrollDownButton.displayName = SelectPrimitive.ScrollDownButton.displayName;\n\nconst SelectContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, position = 'popper', ...props }, ref) => (\n \n \n \n \n {children}\n \n \n \n \n));\nSelectContent.displayName = SelectPrimitive.Content.displayName;\n\nconst SelectLabel = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSelectLabel.displayName = SelectPrimitive.Label.displayName;\n\nconst SelectItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, ...props }, ref) => (\n \n \n \n \n \n \n\n {children}\n \n));\nSelectItem.displayName = SelectPrimitive.Item.displayName;\n\nconst SelectSeparator = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSelectSeparator.displayName = SelectPrimitive.Separator.displayName;\n\nexport {\n Select,\n SelectGroup,\n SelectValue,\n SelectTrigger,\n SelectContent,\n SelectLabel,\n SelectItem,\n SelectSeparator,\n SelectScrollUpButton,\n SelectScrollDownButton,\n};\n","import { ChevronLeftIcon, ChevronRightIcon, ArrowLeftIcon, ArrowRightIcon } from 'lucide-react';\nimport { Table } from '@tanstack/react-table';\n\nimport { Button } from '@/components/shadcn-ui/button';\nimport {\n Select,\n SelectContent,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\n\ninterface DataTablePaginationProps {\n table: Table;\n}\n\nfunction DataTablePagination({ table }: DataTablePaginationProps) {\n return (\n
    \n
    \n
    \n {table.getFilteredSelectedRowModel().rows.length} of{' '}\n {table.getFilteredRowModel().rows.length} row(s) selected\n
    \n
    \n

    Rows per page

    \n {\n table.setPageSize(Number(value));\n }}\n >\n \n \n \n \n {[10, 20, 30, 40, 50].map((pageSize) => (\n \n {pageSize}\n \n ))}\n \n \n
    \n
    \n Page {table.getState().pagination.pageIndex + 1} of {table.getPageCount()}\n
    \n
    \n table.setPageIndex(0)}\n disabled={!table.getCanPreviousPage()}\n >\n Go to first page\n \n \n table.previousPage()}\n disabled={!table.getCanPreviousPage()}\n >\n Go to previous page\n \n \n table.nextPage()}\n disabled={!table.getCanNextPage()}\n >\n Go to next page\n \n \n table.setPageIndex(table.getPageCount() - 1)}\n disabled={!table.getCanNextPage()}\n >\n Go to last page\n \n \n
    \n
    \n
    \n );\n}\n\nexport default DataTablePagination;\n","import React from 'react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Table = React.forwardRef<\n HTMLTableElement,\n React.HTMLAttributes & { stickyHeader?: boolean }\n>(({ className, stickyHeader, ...props }, ref) => (\n
    \n \n
    \n));\nTable.displayName = 'Table';\n\nconst TableHeader = React.forwardRef<\n HTMLTableSectionElement,\n React.HTMLAttributes & { stickyHeader?: boolean }\n>(({ className, stickyHeader, ...props }, ref) => (\n \n));\nTableHeader.displayName = 'TableHeader';\n\nconst TableBody = React.forwardRef<\n HTMLTableSectionElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableBody.displayName = 'TableBody';\n\nconst TableFooter = React.forwardRef<\n HTMLTableSectionElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n tr]:last:tw-border-b-0', className)}\n {...props}\n />\n));\nTableFooter.displayName = 'TableFooter';\n\nconst TableRow = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nTableRow.displayName = 'TableRow';\n\nconst TableHead = React.forwardRef<\n HTMLTableCellElement,\n React.ThHTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableHead.displayName = 'TableHead';\n\nconst TableCell = React.forwardRef<\n HTMLTableCellElement,\n React.TdHTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableCell.displayName = 'TableCell';\n\nconst TableCaption = React.forwardRef<\n HTMLTableCaptionElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableCaption.displayName = 'TableCaption';\n\nexport { Table, TableHeader, TableBody, TableFooter, TableHead, TableRow, TableCell, TableCaption };\n","import { useState } from 'react';\n\nimport {\n ColumnFiltersState,\n flexRender,\n getCoreRowModel,\n getFilteredRowModel,\n getPaginationRowModel,\n getSortedRowModel,\n SortingState,\n ColumnDef as TSColumnDef,\n Row as TSRow,\n RowSelectionState as TSRowSelectionState,\n SortDirection as TSSortDirection,\n Table as TSTable,\n useReactTable,\n VisibilityState,\n} from '@tanstack/react-table';\n\nimport DataTableViewOptions from '@/components/advanced/data-table/data-table-column-toggle.component';\nimport DataTablePagination from '@/components/advanced/data-table/data-table-pagination.component';\nimport { Button } from '@/components/shadcn-ui/button';\nimport {\n Table,\n TableBody,\n TableCell,\n TableHead,\n TableHeader,\n TableRow,\n} from '@/components/shadcn-ui/table';\n\nexport type ColumnDef = TSColumnDef;\nexport type RowContents = TSRow;\nexport type TableContents = TSTable;\nexport type SortDirection = TSSortDirection;\nexport type RowSelectionState = TSRowSelectionState;\n\ninterface DataTableProps {\n columns: ColumnDef[];\n data: TData[];\n enablePagination?: boolean;\n showPaginationControls?: boolean;\n showColumnVisibilityControls?: boolean;\n stickyHeader?: boolean;\n onRowClickHandler?: (row: RowContents, table: TableContents) => void;\n}\n\n/**\n * Feature-rich table component that infuses our basic shadcn-based Table component with features\n * from TanStack's React Table library\n */\nfunction DataTable({\n columns,\n data,\n enablePagination = false,\n showPaginationControls = false,\n showColumnVisibilityControls = false,\n stickyHeader = false,\n onRowClickHandler = () => {},\n}: DataTableProps) {\n const [sorting, setSorting] = useState([]);\n const [columnFilters, setColumnFilters] = useState([]);\n const [columnVisibility, setColumnVisibility] = useState({});\n const [rowSelection, setRowSelection] = useState({});\n\n const table = useReactTable({\n data,\n columns,\n getCoreRowModel: getCoreRowModel(),\n ...(enablePagination && { getPaginationRowModel: getPaginationRowModel() }),\n onSortingChange: setSorting,\n getSortedRowModel: getSortedRowModel(),\n onColumnFiltersChange: setColumnFilters,\n getFilteredRowModel: getFilteredRowModel(),\n onColumnVisibilityChange: setColumnVisibility,\n onRowSelectionChange: setRowSelection,\n state: {\n sorting,\n columnFilters,\n columnVisibility,\n rowSelection,\n },\n });\n\n return (\n
    \n {showColumnVisibilityControls && }\n \n \n {table.getHeaderGroups().map((headerGroup) => (\n \n {headerGroup.headers.map((header) => {\n return (\n \n {header.isPlaceholder\n ? undefined\n : flexRender(header.column.columnDef.header, header.getContext())}\n \n );\n })}\n \n ))}\n \n \n {table.getRowModel().rows?.length ? (\n table.getRowModel().rows.map((row) => (\n onRowClickHandler(row, table)}\n key={row.id}\n data-state={row.getIsSelected() && 'selected'}\n >\n {row.getVisibleCells().map((cell) => (\n \n {flexRender(cell.column.columnDef.cell, cell.getContext())}\n \n ))}\n \n ))\n ) : (\n \n \n No results.\n \n \n )}\n \n
    \n {enablePagination && (\n
    \n table.previousPage()}\n disabled={!table.getCanPreviousPage()}\n >\n Previous\n \n table.nextPage()}\n disabled={!table.getCanNextPage()}\n >\n Next\n \n
    \n )}\n {enablePagination && showPaginationControls && }\n
    \n );\n}\n\nexport default DataTable;\n","import {\n Table,\n TableBody,\n TableCell,\n TableHead,\n TableHeader,\n TableRow,\n} from '@/components/shadcn-ui/table';\nimport { Canon } from '@sillsdev/scripture';\nimport { deepEqual, LanguageStrings, ScriptureReference } from 'platform-bible-utils';\nimport { useMemo } from 'react';\nimport { InventoryItemOccurrence } from './inventory-utils';\n\n/** Props for the OccurrencesTable component */\ntype OccurrencesTableProps = {\n /** Data that contains scriptures references and snippets of scripture */\n occurrenceData: InventoryItemOccurrence[];\n /** Callback function that is executed when the scripture reference is changed */\n setScriptureReference: (scriptureReference: ScriptureReference) => void;\n /**\n * Object with all localized strings that the OccurrencesTable needs to work well across multiple\n * languages\n */\n localizedStrings: LanguageStrings;\n};\n\n/**\n * Table that shows occurrences of specified inventory item(s). The first column shows the related\n * scripture reference. The second column shows the snippet of scripture that contains the specified\n * inventory item\n */\nfunction OccurrencesTable({\n occurrenceData,\n setScriptureReference,\n localizedStrings,\n}: OccurrencesTableProps) {\n const referenceHeaderText =\n localizedStrings['%webView_inventory_occurrences_table_header_reference%'];\n const occurrenceHeaderText =\n localizedStrings['%webView_inventory_occurrences_table_header_occurrence%'];\n\n const occurrences: InventoryItemOccurrence[] = useMemo(() => {\n const uniqueOccurrences: InventoryItemOccurrence[] = [];\n\n occurrenceData.forEach((occurrence) => {\n if (!uniqueOccurrences.some((uniqueOccurrence) => deepEqual(uniqueOccurrence, occurrence))) {\n uniqueOccurrences.push(occurrence);\n }\n });\n\n return uniqueOccurrences;\n }, [occurrenceData]);\n\n return (\n \n \n \n {referenceHeaderText}\n {occurrenceHeaderText}\n \n \n \n {occurrences.length > 0 &&\n occurrences.map((occurrence) => (\n {\n setScriptureReference(occurrence.reference);\n }}\n >\n {`${Canon.bookNumberToEnglishName(occurrence.reference.bookNum)} ${occurrence.reference.chapterNum}:${occurrence.reference.verseNum}`}\n {occurrence.text}\n \n ))}\n \n
    \n );\n}\n\nexport default OccurrencesTable;\n","import React from 'react';\nimport * as CheckboxPrimitive from '@radix-ui/react-checkbox';\nimport { Check } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Checkbox = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n \n \n));\nCheckbox.displayName = CheckboxPrimitive.Root.displayName;\n\nexport default Checkbox;\n","import { Canon } from '@sillsdev/scripture';\nimport { ScriptureReference } from 'platform-bible-utils';\n\n/* #region Types */\n\n/**\n * Status of items that appear in inventories. 'approved' and 'unapproved' items are defined in the\n * project's `Settings.xml`. All other items are defined as 'unknown'\n */\nexport type Status = 'approved' | 'unapproved' | 'unknown';\n\n/** Occurrence of item in inventory. Primarily used by table that shows occurrences */\nexport type InventoryItemOccurrence = {\n /** Reference to scripture where the item appears */\n reference: ScriptureReference;\n /** Snippet of scripture that contains the occurrence */\n text: string;\n};\n\n/** Data structure that contains all information on an item that is shown in an inventory */\nexport type InventoryTableData = {\n /**\n * The item (e.g. a character in the characters inventory, a marker in the marker inventory) In\n * most cases the array will only have one element. In case of additional items (e.g. the\n * preceding marker in the markers check), the primary item should be stored in the first index.\n * To show additional items in the inventory, make sure to configure the `additionalItemsLabels`\n * prop for the Inventory component\n */\n items: string[];\n /** The number of times this item occurs in the selected scope */\n count: number;\n /** The status of this item (see documentation for `Status` type for more information) */\n status: Status;\n /** Occurrences of this item in the scripture text for the selected scope */\n occurrences: InventoryItemOccurrence[];\n};\n\n/* #endregion */\n\n/* #region Functions */\n\n/**\n * Splits USFM string into shorter line-like segments\n *\n * @param text A single (likely very large) USFM string\n * @returns An array containing the input text, split into shorter segments\n */\nexport const getLinesFromUSFM = (text: string) => {\n // Splits on (CR)LF, CR, \\v, \\c and \\id\n return text.split(/(?:\\r?\\n|\\r)|(?=(?:\\\\(?:v|c|id)))/g);\n};\n\n/**\n * Extracts chapter or verse number from USFM strings that start with a \\c or \\v marker\n *\n * @param text USFM string that is expected to start with \\c or \\v marker\n * @returns Chapter or verse number if one is found. Else returns 0.\n */\nexport const getNumberFromUSFM = (text: string): number | undefined => {\n // Captures all digits that follow \\v or \\c markers followed by whitespace located at the start of a string\n const regex = /^\\\\[vc]\\s+(\\d+)/;\n const match = text.match(regex);\n\n if (match) {\n return +match[1];\n }\n return undefined;\n};\n\n/**\n * Gets book ID from USFM string that starts with the \\id marker, and returns book number for it\n *\n * @param text USFM string that is expected to start with \\id marker\n * @returns Book number corresponding to the \\id marker in the input text. Returns 0 if no marker is\n * found or the marker is not valid\n */\nexport const getBookNumFromId = (text: string): number => {\n // Captures all digits that follow an \\id marker followed by whitespace located at the start of a string\n const match = text.match(/^\\\\id\\s+([A-Za-z]+)/);\n if (match) {\n return Canon.bookIdToNumber(match[1]);\n }\n return 0;\n};\n\n/**\n * Gets the status for an item, typically used in the Inventory component\n *\n * @param item The item for which the status is being requested\n * @param approvedItems Array of approved items, typically as defined in `Settings.xml`\n * @param unapprovedItems Array of unapproved items, typically as defined in `Settings.xml`\n * @returns The status for the specified item\n */\nexport const getStatusForItem = (\n item: string,\n approvedItems: string[],\n unapprovedItems: string[],\n): Status => {\n if (unapprovedItems.includes(item)) return 'unapproved';\n if (approvedItems.includes(item)) return 'approved';\n return 'unknown';\n};\n\n/* #endregion */\n","import React from 'react';\nimport * as TogglePrimitive from '@radix-ui/react-toggle';\nimport { cva, type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst toggleVariants = cva(\n 'pr-twp tw-inline-flex tw-items-center tw-justify-center tw-rounded-md tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-colors hover:tw-bg-muted hover:tw-text-muted-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50 data-[state=on]:tw-bg-accent data-[state=on]:tw-text-accent-foreground',\n {\n variants: {\n variant: {\n default: 'tw-bg-transparent',\n outline:\n 'tw-border tw-border-input tw-bg-transparent hover:tw-bg-accent hover:tw-text-accent-foreground',\n },\n size: {\n default: 'tw-h-10 tw-px-3',\n sm: 'tw-h-9 tw-px-2.5',\n lg: 'tw-h-11 tw-px-5',\n },\n },\n defaultVariants: {\n variant: 'default',\n size: 'default',\n },\n },\n);\n\nconst Toggle = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef & VariantProps\n>(({ className, variant, size, ...props }, ref) => (\n \n));\n\nToggle.displayName = TogglePrimitive.Root.displayName;\n\nexport { Toggle, toggleVariants };\n","import React from 'react';\nimport * as ToggleGroupPrimitive from '@radix-ui/react-toggle-group';\nimport { type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { toggleVariants } from '@/components/shadcn-ui/toggle';\n\nconst ToggleGroupContext = React.createContext>({\n size: 'default',\n variant: 'default',\n});\n\nconst ToggleGroup = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef &\n VariantProps\n>(({ className, variant, size, children, ...props }, ref) => (\n \n \n {children}\n \n \n));\n\nToggleGroup.displayName = ToggleGroupPrimitive.Root.displayName;\n\nconst ToggleGroupItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef &\n VariantProps\n>(({ className, children, variant, size, ...props }, ref) => {\n const context = React.useContext(ToggleGroupContext);\n\n return (\n \n {children}\n \n );\n});\n\nToggleGroupItem.displayName = ToggleGroupPrimitive.Item.displayName;\n\nexport { ToggleGroup, ToggleGroupItem };\n","import { ColumnDef, SortDirection } from '@/components/advanced/data-table/data-table.component';\nimport { Button } from '@/components/shadcn-ui/button';\nimport { ToggleGroup, ToggleGroupItem } from '@/components/shadcn-ui/toggle-group';\nimport {\n ArrowDownIcon,\n ArrowUpDownIcon,\n ArrowUpIcon,\n CircleCheckIcon,\n CircleHelpIcon,\n CircleXIcon,\n} from 'lucide-react';\nimport { ReactNode } from 'react';\nimport { InventoryTableData, Status } from './inventory-utils';\n\n/**\n * Gets an icon that indicates the current sorting direction based on the provided input\n *\n * @param sortDirection Sorting direction. Can be ascending ('asc'), descending ('desc') or false (\n * i.e. not sorted)\n * @returns The appropriate sorting icon for the provided sorting direction\n */\nconst getSortingIcon = (sortDirection: false | SortDirection): ReactNode => {\n if (sortDirection === 'asc') {\n return ;\n }\n if (sortDirection === 'desc') {\n return ;\n }\n return ;\n};\n\n/**\n * Function that creates the item column for inventories\n *\n * @param itemLabel Localized label for the item column (e.g. 'Character', 'Repeated Word', etc.)\n * @returns Column that shows the inventory items. Should be used with the DataTable component\n */\nexport const inventoryItemColumn = (itemLabel: string): ColumnDef => {\n return {\n accessorKey: 'item',\n accessorFn: (row: InventoryTableData) => row.items[0],\n header: ({ column }) => (\n \n ),\n };\n};\n\n/**\n * Function that creates the additional item columns for inventories\n *\n * @param additionalItemLabel Localized label for the additional item column (e.g. 'Preceding\n * Marker')\n * @param additionalItemIndex Index that locates the desired item in the items array of the\n * inventory\n * @returns Column that shows additional inventory items. Should be used with the DataTable\n * component\n */\nexport const inventoryAdditionalItemColumn = (\n additionalItemLabel: string,\n additionalItemIndex: number,\n): ColumnDef => {\n return {\n accessorKey: `item${additionalItemIndex}`,\n accessorFn: (row: InventoryTableData) => row.items[additionalItemIndex],\n header: ({ column }) => (\n \n ),\n };\n};\n\n/**\n * Function that creates the count column for inventories. Should be used with the DataTable\n * component.\n *\n * @param itemLabel Localized label for the count column\n * @returns Column that shows the number of occurrences of the related inventory items\n */\nexport const inventoryCountColumn = (countLabel: string): ColumnDef => {\n return {\n accessorKey: 'count',\n header: ({ column }) => (\n
    \n \n
    \n ),\n cell: ({ row }) =>
    {row.getValue('count')}
    ,\n };\n};\n\n/**\n * Function that updates project settings when status for item(s) changes\n *\n * @param changedItems Array of items for which the status is being updated\n * @param newStatus The status that the items are being given\n * @param approvedItems Array of currently approved items\n * @param onApprovedItemsChange Callback function that stores the updated list of approved items\n * @param unapprovedItems Array of currently unapproved items\n * @param onUnapprovedItemsChange Callback function that stores the updated list of unapproved items\n */\nconst statusChangeHandler = (\n changedItems: string[],\n newStatus: Status,\n approvedItems: string[],\n onApprovedItemsChange: (items: string[]) => void,\n unapprovedItems: string[],\n onUnapprovedItemsChange: (items: string[]) => void,\n) => {\n let newApprovedItems: string[] = [...approvedItems];\n changedItems.forEach((item) => {\n if (newStatus === 'approved') {\n if (!newApprovedItems.includes(item)) {\n newApprovedItems.push(item);\n }\n } else {\n newApprovedItems = newApprovedItems.filter((validItem) => validItem !== item);\n }\n });\n onApprovedItemsChange(newApprovedItems);\n\n let newUnapprovedItems: string[] = [...unapprovedItems];\n changedItems.forEach((item) => {\n if (newStatus === 'unapproved') {\n if (!newUnapprovedItems.includes(item)) {\n newUnapprovedItems.push(item);\n }\n } else {\n newUnapprovedItems = newUnapprovedItems.filter((unapprovedItem) => unapprovedItem !== item);\n }\n });\n onUnapprovedItemsChange(newUnapprovedItems);\n};\n\n/**\n * Function that creates the status column for inventories. Should be used with the DataTable\n * component.\n *\n * @param statusLabel Localized label for the status column\n * @param approvedItems Array of approved items, typically as defined in `Settings.xml`\n * @param onApprovedItemsChange Callback function that stores the updated list of approved items\n * @param unapprovedItems Array of unapproved items, typically as defined in `Settings.xml`\n * @param onUnapprovedItemsChange Callback function that stores the updated list of unapproved items\n * @returns Column that shows the status buttons for the related inventory item. The button for the\n * current status of the item is selected\n */\nexport const inventoryStatusColumn = (\n statusLabel: string,\n approvedItems: string[],\n onApprovedItemsChange: (items: string[]) => void,\n unapprovedItems: string[],\n onUnapprovedItemsChange: (items: string[]) => void,\n): ColumnDef => {\n return {\n accessorKey: 'status',\n header: ({ column }) => {\n return (\n
    \n \n
    \n );\n },\n cell: ({ row }) => {\n const status: Status = row.getValue('status');\n const item: string = row.getValue('item');\n return (\n \n \n statusChangeHandler(\n [item],\n 'approved',\n approvedItems,\n onApprovedItemsChange,\n unapprovedItems,\n onUnapprovedItemsChange,\n )\n }\n value=\"approved\"\n >\n \n \n \n statusChangeHandler(\n [item],\n 'unapproved',\n approvedItems,\n onApprovedItemsChange,\n unapprovedItems,\n onUnapprovedItemsChange,\n )\n }\n value=\"unapproved\"\n >\n \n \n \n statusChangeHandler(\n [item],\n 'unknown',\n approvedItems,\n onApprovedItemsChange,\n unapprovedItems,\n onUnapprovedItemsChange,\n )\n }\n value=\"unknown\"\n >\n \n \n \n );\n },\n };\n};\n","import DataTable, {\n ColumnDef,\n RowContents,\n RowSelectionState,\n TableContents,\n} from '@/components/advanced/data-table/data-table.component';\nimport OccurrencesTable from '@/components/advanced/inventory/occurrences-table.component';\nimport Checkbox from '@/components/shadcn-ui/checkbox';\nimport { Input } from '@/components/shadcn-ui/input';\nimport { Label } from '@/components/shadcn-ui/label';\nimport {\n Select,\n SelectContent,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\nimport {\n deepEqual,\n LocalizedStringValue,\n ScriptureReference,\n substring,\n} from 'platform-bible-utils';\nimport { useEffect, useMemo, useState } from 'react';\nimport {\n getBookNumFromId,\n getLinesFromUSFM,\n getNumberFromUSFM,\n getStatusForItem,\n InventoryItemOccurrence,\n InventoryTableData,\n Status,\n} from './inventory-utils';\nimport { inventoryAdditionalItemColumn } from './inventory-columns';\n\n/**\n * Object containing all keys used for localization in this component. If you're using this\n * component in an extension, you can pass it into the useLocalizedStrings hook to easily obtain the\n * localized strings and pass them into the localizedStrings prop of this component\n */\nexport const INVENTORY_STRING_KEYS = Object.freeze([\n '%webView_inventory_all%',\n '%webView_inventory_approved%',\n '%webView_inventory_unapproved%',\n '%webView_inventory_unknown%',\n '%webView_inventory_scope_currentBook%',\n '%webView_inventory_scope_chapter%',\n '%webView_inventory_scope_verse%',\n '%webView_inventory_filter_text%',\n '%webView_inventory_show_additional_items%',\n '%webView_inventory_occurrences_table_header_reference%',\n '%webView_inventory_occurrences_table_header_occurrence%',\n] as const);\n\nexport type InventoryLocalizedStrings = {\n [localizedInventoryKey in (typeof INVENTORY_STRING_KEYS)[number]]?: LocalizedStringValue;\n};\n\n/** Scope of scripture that the inventory can operate on */\nexport type Scope = 'book' | 'chapter' | 'verse';\n\n/** Status values that the status filter can select from */\ntype StatusFilter = Status | 'all';\n\n/** Text labels for the inventory columns and the control components of additional inventory items */\ntype AdditionalItemsLabels = {\n checkboxText?: string;\n tableHeaders?: string[];\n};\n\n/**\n * Filters data that is shown in the DataTable section of the Inventory\n *\n * @param itemData All inventory items and their related information\n * @param statusFilter Allows filtering by status (i.e. show all items, or only items that are\n * 'approved', 'unapproved' or 'unknown')\n * @param textFilter Allows filtering by text. All items that include the filter text will be\n * selected.\n * @returns Array of items and their related information that are matched by the specified filters\n */\nconst filterItemData = (\n itemData: InventoryTableData[],\n statusFilter: StatusFilter,\n textFilter: string,\n): InventoryTableData[] => {\n let filteredItemData: InventoryTableData[] = itemData;\n\n if (statusFilter !== 'all') {\n filteredItemData = filteredItemData.filter(\n (item) =>\n (statusFilter === 'approved' && item.status === 'approved') ||\n (statusFilter === 'unapproved' && item.status === 'unapproved') ||\n (statusFilter === 'unknown' && item.status === 'unknown'),\n );\n }\n\n if (textFilter !== '')\n filteredItemData = filteredItemData.filter((item) => item.items[0].includes(textFilter));\n\n return filteredItemData;\n};\n\n/**\n * Turns array of strings into array of inventory items, along with their count and status\n *\n * @param text The source scripture text that is searched for inventory items\n * @param scriptureRef The scripture reference that the application is currently set to\n * @param approvedItems Array of approved items, typically as defined in `Settings.xml`\n * @param unapprovedItems Array of unapproved items, typically as defined in `Settings.xml`\n * @param itemRegex Regular expression that describes what items this Inventory should extract from\n * the provided scripture text\n * @returns Array of inventory items, along with their count and status\n */\nconst createTableData = (\n text: string | undefined,\n scriptureRef: ScriptureReference,\n approvedItems: string[],\n unapprovedItems: string[],\n itemRegex: RegExp,\n): InventoryTableData[] => {\n if (!text) return [];\n\n const tableData: InventoryTableData[] = [];\n\n let currentBook: number | undefined = scriptureRef.bookNum;\n let currentChapter: number | undefined = scriptureRef.chapterNum;\n let currentVerse: number | undefined = scriptureRef.verseNum;\n\n const lines = getLinesFromUSFM(text);\n\n lines.forEach((line: string) => {\n if (line.startsWith('\\\\id')) {\n currentBook = getBookNumFromId(line);\n currentChapter = 0;\n currentVerse = 0;\n }\n if (line.startsWith('\\\\c')) {\n currentChapter = getNumberFromUSFM(line);\n currentVerse = 0;\n }\n if (line.startsWith('\\\\v')) {\n currentVerse = getNumberFromUSFM(line);\n if (currentChapter === 0) {\n currentChapter = scriptureRef.chapterNum;\n }\n }\n\n let match: RegExpExecArray | undefined = itemRegex.exec(line) ?? undefined;\n while (match) {\n const items: string[] = [];\n match.forEach((item) => items.push(item));\n const itemIndex = match.index;\n const existingItem = tableData.find((tableEntry) => deepEqual(tableEntry.items, items));\n const newReference: InventoryItemOccurrence = {\n reference: {\n bookNum: currentBook !== undefined ? currentBook : -1,\n chapterNum: currentChapter !== undefined ? currentChapter : -1,\n verseNum: currentVerse !== undefined ? currentVerse : -1,\n },\n text: substring(line, Math.max(0, itemIndex - 25), Math.min(itemIndex + 25, line.length)),\n };\n if (existingItem) {\n existingItem.count += 1;\n existingItem.occurrences.push(newReference);\n } else {\n const newItem: InventoryTableData = {\n items,\n count: 1,\n status: getStatusForItem(items[0], approvedItems, unapprovedItems),\n occurrences: [newReference],\n };\n tableData.push(newItem);\n }\n\n match = itemRegex.exec(line) ?? undefined;\n }\n });\n\n return tableData;\n};\n\n/**\n * Gets the localized value for the provided key\n *\n * @param strings Object containing localized string\n * @param key Key for a localized string\n * @returns The localized value for the provided key, if available. Returns the key if no localized\n * value is available\n */\nconst localizeString = (\n strings: InventoryLocalizedStrings,\n key: keyof InventoryLocalizedStrings,\n) => {\n return strings[key] ?? key;\n};\n\n/** Props for the Inventory component */\ntype InventoryProps = {\n /** The scripture reference that the application is currently set to */\n scriptureReference: ScriptureReference;\n /** Callback function that is executed when the scripture reference is changed */\n setScriptureReference: (scriptureReference: ScriptureReference) => void;\n /**\n * Object with all localized strings that the Inventory needs to work well across multiple\n * languages. When using this component with Platform.Bible, you can import\n * `INVENTORY_STRING_KEYS` from this library, pass it in to the Platform's localization hook, and\n * pass the localized keys that are returned by the hook into this prop.\n */\n localizedStrings: InventoryLocalizedStrings;\n /**\n * The logic that finds the desired items in the source text. This can either be a Regular\n * expression that captures one or multiple items (preferred), or a custom function that builds\n * and return an InventoryDataTable[] manually. Note: In case the logic captures more than one\n * item (i.e. InventoryTableData.items has a length greater than 1), you must provide text labels\n * for the related columns and control elements to show by setting the `additionalItemsLabels`\n * prop\n */\n extractItems:\n | RegExp\n | ((\n text: string | undefined,\n scriptureRef: ScriptureReference,\n approvedItems: string[],\n unapprovedItems: string[],\n ) => InventoryTableData[]);\n /**\n * Text labels for control elements and additional column headers in case your Inventory has more\n * than one item to show (e.g. The 'Preceding Marker' in the Markers Inventory)\n */\n additionalItemsLabels?: AdditionalItemsLabels;\n /** Array of approved items, typically as defined in `Settings.xml` */\n approvedItems: string[];\n /** Array of unapproved items, typically as defined in `Settings.xml` */\n unapprovedItems: string[];\n /** The source scripture text that is searched for in inventory items */\n text: string | undefined;\n /** Scope of scripture that the inventory will operate on */\n scope: Scope;\n /** Callback function that is executed when the scope is changed from the Inventory */\n onScopeChange: (scope: Scope) => void;\n /**\n * Column definitions for the Inventory data table. The most commonly used column definitions are\n * pre-configured for your convenience and can be imported (e.g. inventoryItemColumn,\n * inventoryAdditionalItemColumn inventoryCountColumn, and inventoryStatusColumn). If you need any\n * other columns you can add these yourself\n */\n columns: ColumnDef[];\n};\n\n/** Inventory component that is used to view and control the status of provided project settings */\nexport default function Inventory({\n scriptureReference,\n setScriptureReference,\n localizedStrings,\n extractItems,\n additionalItemsLabels,\n approvedItems,\n unapprovedItems,\n text,\n scope,\n onScopeChange,\n columns,\n}: InventoryProps) {\n const allItemsText = localizeString(localizedStrings, '%webView_inventory_all%');\n const approvedItemsText = localizeString(localizedStrings, '%webView_inventory_approved%');\n const unapprovedItemsText = localizeString(localizedStrings, '%webView_inventory_unapproved%');\n const unknownItemsText = localizeString(localizedStrings, '%webView_inventory_unknown%');\n const scopeBookText = localizeString(localizedStrings, '%webView_inventory_scope_currentBook%');\n const scopeChapterText = localizeString(localizedStrings, '%webView_inventory_scope_chapter%');\n const scopeVerseText = localizeString(localizedStrings, '%webView_inventory_scope_verse%');\n const filterText = localizeString(localizedStrings, '%webView_inventory_filter_text%');\n const showAdditionalItemsText = localizeString(\n localizedStrings,\n '%webView_inventory_show_additional_items%',\n );\n\n const [showAdditionalItems, setShowAdditionalItems] = useState(false);\n const [statusFilter, setStatusFilter] = useState('all');\n const [textFilter, setTextFilter] = useState('');\n const [selectedItem, setSelectedItem] = useState([]);\n\n const tableData: InventoryTableData[] = useMemo(() => {\n if (!text) return [];\n if (extractItems instanceof RegExp)\n return createTableData(\n text,\n scriptureReference,\n approvedItems,\n unapprovedItems,\n extractItems,\n );\n return extractItems(text, scriptureReference, approvedItems, unapprovedItems);\n }, [text, extractItems, scriptureReference, approvedItems, unapprovedItems]);\n\n const reducedTableData: InventoryTableData[] = useMemo(() => {\n if (showAdditionalItems) return tableData;\n\n const newTableData: InventoryTableData[] = [];\n\n tableData.forEach((tableEntry) => {\n const firstItem = tableEntry.items[0];\n\n const existingEntry = newTableData.find(\n (newTableEntry) => newTableEntry.items[0] === firstItem,\n );\n\n if (existingEntry) {\n existingEntry.count += tableEntry.count;\n existingEntry.occurrences = existingEntry.occurrences.concat(tableEntry.occurrences);\n } else {\n newTableData.push({\n items: [firstItem],\n count: tableEntry.count,\n occurrences: tableEntry.occurrences,\n status: tableEntry.status,\n });\n }\n });\n\n return newTableData;\n }, [showAdditionalItems, tableData]);\n\n const filteredTableData: InventoryTableData[] = useMemo(() => {\n return filterItemData(reducedTableData, statusFilter, textFilter);\n }, [reducedTableData, statusFilter, textFilter]);\n\n const allColumns: ColumnDef[] = useMemo(() => {\n if (!showAdditionalItems) return columns;\n\n const numberOfAdditionalItems = additionalItemsLabels?.tableHeaders?.length;\n if (!numberOfAdditionalItems) return columns;\n\n const additionalColumns: ColumnDef[] = [];\n\n for (let index = 0; index < numberOfAdditionalItems; index++) {\n additionalColumns.push(\n inventoryAdditionalItemColumn(\n additionalItemsLabels?.tableHeaders?.[index] || 'Additional Item',\n index + 1,\n ),\n );\n }\n\n return [...additionalColumns, ...columns];\n }, [additionalItemsLabels?.tableHeaders, columns, showAdditionalItems]);\n\n useEffect(() => {\n setSelectedItem([]);\n }, [filteredTableData]);\n\n const rowClickHandler = (\n row: RowContents,\n table: TableContents,\n ) => {\n table.setRowSelection(() => {\n const newSelection: RowSelectionState = {};\n newSelection[row.index] = true;\n return newSelection;\n });\n\n setSelectedItem(row.original.items);\n };\n\n const handleScopeChange = (value: string) => {\n if (value === 'book' || value === 'chapter' || value === 'verse') {\n onScopeChange(value);\n } else {\n throw new Error(`Invalid scope value: ${value}`);\n }\n };\n\n const handleStatusFilterChange = (value: string) => {\n if (value === 'all' || value === 'approved' || value === 'unapproved' || value === 'unknown') {\n setStatusFilter(value);\n } else {\n throw new Error(`Invalid status filter value: ${value}`);\n }\n };\n\n const occurrenceData: InventoryItemOccurrence[] = useMemo(() => {\n if (reducedTableData.length === 0 || selectedItem.length === 0) return [];\n const occurrence = reducedTableData.filter((tableEntry: InventoryTableData) => {\n return deepEqual(\n showAdditionalItems ? tableEntry.items : [tableEntry.items[0]],\n selectedItem,\n );\n });\n if (occurrence.length > 1) throw new Error('Selected item is not unique');\n return occurrence[0].occurrences;\n }, [selectedItem, showAdditionalItems, reducedTableData]);\n\n return (\n
    \n
    \n handleStatusFilterChange(value)}\n defaultValue={statusFilter}\n >\n \n \n \n \n {allItemsText}\n {approvedItemsText}\n {unapprovedItemsText}\n {unknownItemsText}\n \n \n \n {\n setTextFilter(event.target.value);\n }}\n />\n {additionalItemsLabels && (\n
    \n {\n setSelectedItem([]);\n setShowAdditionalItems(checked);\n }}\n />\n \n
    \n )}\n
    \n
    \n \n
    \n {occurrenceData.length > 0 && (\n
    \n \n
    \n )}\n
    \n );\n}\n","import { Input } from '@/components/shadcn-ui/input';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { useState } from 'react';\n\nexport type SearchBarProps = {\n /**\n * Callback fired to handle the search query when button pressed\n *\n * @param searchQuery\n */\n onSearch: (searchQuery: string) => void;\n\n /** Optional string that appears in the search bar without a search string */\n placeholder?: string;\n\n /** Optional boolean to set the input base to full width */\n isFullWidth?: boolean;\n};\n\nexport default function SearchBar({ onSearch, placeholder, isFullWidth }: SearchBarProps) {\n const [searchQuery, setSearchQuery] = useState('');\n\n const handleInputChange = (searchString: string) => {\n setSearchQuery(searchString);\n onSearch(searchString);\n };\n\n return (\n handleInputChange(e.target.value)}\n />\n );\n}\n","// adapted from: https://github.com/shadcn-ui/ui/discussions/752\n\n'use client';\n\nimport { TabsContentProps, TabsListProps, TabsTriggerProps } from '@/components/shadcn-ui/tabs';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport * as TabsPrimitive from '@radix-ui/react-tabs';\nimport React from 'react';\n\nexport type VerticalTabsProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport type LeftTabsTriggerProps = TabsTriggerProps & {\n value: string;\n ref?: React.Ref;\n};\n\nexport const VerticalTabs = React.forwardRef<\n React.ElementRef,\n VerticalTabsProps\n>(({ className, ...props }, ref) => (\n \n));\n\nVerticalTabs.displayName = TabsPrimitive.List.displayName;\n\nexport const VerticalTabsList = React.forwardRef<\n React.ElementRef,\n TabsListProps\n>(({ className, ...props }, ref) => (\n \n));\nVerticalTabsList.displayName = TabsPrimitive.List.displayName;\n\nexport const VerticalTabsTrigger = React.forwardRef<\n React.ElementRef,\n LeftTabsTriggerProps\n>(({ className, ...props }, ref) => (\n \n));\n\nexport const VerticalTabsContent = React.forwardRef<\n React.ElementRef,\n TabsContentProps\n>(({ className, ...props }, ref) => (\n \n));\nVerticalTabsContent.displayName = TabsPrimitive.Content.displayName;\n","import SearchBar from '@/components/basics/search-bar.component';\nimport {\n VerticalTabs,\n VerticalTabsContent,\n VerticalTabsList,\n VerticalTabsTrigger,\n} from '@/components/basics/tabs-vertical';\nimport { ReactNode } from 'react';\n\nexport type TabKeyValueContent = {\n key: string;\n value: string;\n content: ReactNode;\n};\n\nexport type TabNavigationContentSearchProps = {\n /** List of values and keys for each tab this component should provide */\n tabList: TabKeyValueContent[];\n\n /** Handler to run when the value of the search bar changes */\n onSearch: (searchQuery: string) => void;\n\n /** Optional placeholder for the search bar */\n searchPlaceholder?: string;\n\n /** Optional title to include in the header */\n headerTitle?: string;\n\n /** Optional flag to make the search bar appear full width */\n isSearchBarFullWidth?: boolean;\n\n /** Text direction ltr or rtl */\n direction?: 'ltr' | 'rtl';\n};\n\nexport default function TabNavigationContentSearch({\n tabList,\n onSearch,\n searchPlaceholder,\n headerTitle,\n isSearchBarFullWidth = false,\n direction = 'ltr',\n}: TabNavigationContentSearchProps) {\n return (\n
    \n
    \n {headerTitle ?

    {headerTitle}

    : ''}\n \n
    \n \n \n {tabList.map((tab) => (\n \n {tab.value}\n \n ))}\n \n {tabList.map((tab) => (\n \n {tab.content}\n \n ))}\n \n
    \n );\n}\n","import React from 'react';\nimport * as SeparatorPrimitive from '@radix-ui/react-separator';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Separator = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, orientation = 'horizontal', decorative = true, ...props }, ref) => (\n \n));\nSeparator.displayName = SeparatorPrimitive.Root.displayName;\n\nexport { Separator };\n","'use client';\n\nimport * as React from 'react';\nimport * as SheetPrimitive from '@radix-ui/react-dialog';\nimport { cva, type VariantProps } from 'class-variance-authority';\nimport { X } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Sheet = SheetPrimitive.Root;\n\nconst SheetTrigger = SheetPrimitive.Trigger;\n\nconst SheetClose = SheetPrimitive.Close;\n\nconst SheetPortal = SheetPrimitive.Portal;\n\nconst SheetOverlay = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSheetOverlay.displayName = SheetPrimitive.Overlay.displayName;\n\nconst sheetVariants = cva(\n 'pr-twp tw-fixed tw-z-50 tw-gap-4 tw-bg-background tw-p-6 tw-shadow-lg tw-transition tw-ease-in-out data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-duration-300 data-[state=open]:tw-duration-500',\n {\n variants: {\n side: {\n top: 'tw-inset-x-0 tw-top-0 tw-border-b data-[state=closed]:tw-slide-out-to-top data-[state=open]:tw-slide-in-from-top',\n bottom:\n 'tw-inset-x-0 tw-bottom-0 tw-border-t data-[state=closed]:tw-slide-out-to-bottom data-[state=open]:tw-slide-in-from-bottom',\n left: 'tw-inset-y-0 tw-left-0 tw-h-full tw-w-3/4 tw-border-r data-[state=closed]:tw-slide-out-to-left data-[state=open]:tw-slide-in-from-left sm:tw-max-w-sm',\n right:\n 'tw-inset-y-0 tw-right-0 tw-h-full tw-w-3/4 tw- tw-border-l data-[state=closed]:tw-slide-out-to-right data-[state=open]:tw-slide-in-from-right sm:tw-max-w-sm',\n },\n },\n defaultVariants: {\n side: 'right',\n },\n },\n);\n\ninterface SheetContentProps\n extends React.ComponentPropsWithoutRef,\n VariantProps {}\n\nconst SheetContent = React.forwardRef<\n React.ElementRef,\n SheetContentProps\n>(({ side = 'right', className, children, ...props }, ref) => (\n \n \n \n {children}\n \n \n Close\n \n \n \n));\nSheetContent.displayName = SheetPrimitive.Content.displayName;\n\nfunction SheetHeader({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nSheetHeader.displayName = 'SheetHeader';\n\nfunction SheetFooter({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nSheetFooter.displayName = 'SheetFooter';\n\nconst SheetTitle = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSheetTitle.displayName = SheetPrimitive.Title.displayName;\n\nconst SheetDescription = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSheetDescription.displayName = SheetPrimitive.Description.displayName;\n\nexport {\n Sheet,\n SheetPortal,\n SheetOverlay,\n SheetTrigger,\n SheetClose,\n SheetContent,\n SheetHeader,\n SheetFooter,\n SheetTitle,\n SheetDescription,\n};\n","import React from 'react';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nfunction Skeleton({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\n\nexport { Skeleton };\n","import React from 'react';\nimport * as TooltipPrimitive from '@radix-ui/react-tooltip';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst TooltipProvider = TooltipPrimitive.Provider;\n\nconst Tooltip = TooltipPrimitive.Root;\n\nconst TooltipTrigger = TooltipPrimitive.Trigger;\n\nconst TooltipContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, sideOffset = 4, ...props }, ref) => (\n \n));\nTooltipContent.displayName = TooltipPrimitive.Content.displayName;\n\nexport { Tooltip, TooltipTrigger, TooltipContent, TooltipProvider };\n","import * as React from 'react';\n\nconst MOBILE_BREAKPOINT = 768;\n\nexport default function useIsMobile() {\n const [isMobile, setIsMobile] = React.useState(undefined);\n\n React.useEffect(() => {\n const mql = window.matchMedia(`(max-width: ${MOBILE_BREAKPOINT - 1}px)`);\n const onChange = () => {\n setIsMobile(window.innerWidth < MOBILE_BREAKPOINT);\n };\n mql.addEventListener('change', onChange);\n setIsMobile(window.innerWidth < MOBILE_BREAKPOINT);\n return () => mql.removeEventListener('change', onChange);\n }, []);\n\n return !!isMobile;\n}\n","import React from 'react';\nimport { Slot } from '@radix-ui/react-slot';\nimport { VariantProps, cva } from 'class-variance-authority';\nimport { PanelLeft } from 'lucide-react';\n\nimport { Button } from '@/components/shadcn-ui/button';\nimport { Input } from '@/components/shadcn-ui/input';\nimport { Separator } from '@/components/shadcn-ui/separator';\nimport { Sheet, SheetContent } from '@/components/shadcn-ui/sheet';\nimport { Skeleton } from '@/components/shadcn-ui/skeleton';\nimport {\n Tooltip,\n TooltipContent,\n TooltipProvider,\n TooltipTrigger,\n} from '@/components/shadcn-ui/tooltip';\nimport useIsMobile from '@/components/hooks/use-mobile';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst SIDEBAR_COOKIE_NAME = 'sidebar:state';\nconst SIDEBAR_COOKIE_MAX_AGE = 60 * 60 * 24 * 7;\nconst SIDEBAR_WIDTH = '16rem';\nconst SIDEBAR_WIDTH_MOBILE = '18rem';\nconst SIDEBAR_WIDTH_ICON = '3rem';\nconst SIDEBAR_KEYBOARD_SHORTCUT = 'b';\n\ntype SidebarContextProps = {\n state: 'expanded' | 'collapsed';\n open: boolean;\n setOpen: (open: boolean) => void;\n openMobile: boolean;\n setOpenMobile: (open: boolean) => void;\n isMobile: boolean;\n toggleSidebar: () => void;\n};\n\nconst SidebarContext = React.createContext(undefined);\n\nfunction useSidebar() {\n const context = React.useContext(SidebarContext);\n if (!context) {\n throw new Error('useSidebar must be used within a SidebarProvider.');\n }\n\n return context;\n}\n\nconst SidebarProvider = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & {\n defaultOpen?: boolean;\n open?: boolean;\n onOpenChange?: (open: boolean) => void;\n }\n>(\n (\n {\n defaultOpen = true,\n open: openProp,\n onOpenChange: setOpenProp,\n className,\n style,\n children,\n ...props\n },\n ref,\n ) => {\n const isMobile = useIsMobile();\n const [openMobile, setOpenMobile] = React.useState(false);\n\n // This is the internal state of the sidebar.\n // We use openProp and setOpenProp for control from outside the component.\n const [_open, _setOpen] = React.useState(defaultOpen);\n const isOpen = openProp ?? _open;\n const setOpen = React.useCallback(\n (value: boolean | ((value: boolean) => boolean)) => {\n const openState = typeof value === 'function' ? value(isOpen) : value;\n if (setOpenProp) {\n setOpenProp(openState);\n } else {\n _setOpen(openState);\n }\n\n // This sets the cookie to keep the sidebar state.\n document.cookie = `${SIDEBAR_COOKIE_NAME}=${openState}; path=/; max-age=${SIDEBAR_COOKIE_MAX_AGE}`;\n },\n [setOpenProp, isOpen],\n );\n\n // Helper to toggle the sidebar.\n const toggleSidebar = React.useCallback(() => {\n return isMobile ? setOpenMobile((open) => !open) : setOpen((open) => !open);\n }, [isMobile, setOpen, setOpenMobile]);\n\n // Adds a keyboard shortcut to toggle the sidebar.\n React.useEffect(() => {\n const handleKeyDown = (event: KeyboardEvent) => {\n if (event.key === SIDEBAR_KEYBOARD_SHORTCUT && (event.metaKey || event.ctrlKey)) {\n event.preventDefault();\n toggleSidebar();\n }\n };\n\n window.addEventListener('keydown', handleKeyDown);\n return () => window.removeEventListener('keydown', handleKeyDown);\n }, [toggleSidebar]);\n\n // We add a state so that we can do data-state=\"expanded\" or \"collapsed\".\n // This makes it easier to style the sidebar with Tailwind classes.\n const state = isOpen ? 'expanded' : 'collapsed';\n\n const contextValue = React.useMemo(\n () => ({\n state,\n open: isOpen,\n setOpen,\n isMobile,\n openMobile,\n setOpenMobile,\n toggleSidebar,\n }),\n [state, isOpen, setOpen, isMobile, openMobile, setOpenMobile, toggleSidebar],\n );\n\n return (\n \n \n \n {children}\n
    \n \n \n );\n },\n);\nSidebarProvider.displayName = 'SidebarProvider';\n\nconst Sidebar = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & {\n side?: 'left' | 'right';\n variant?: 'sidebar' | 'floating' | 'inset';\n collapsible?: 'offcanvas' | 'icon' | 'none';\n }\n>(\n (\n {\n side = 'left',\n variant = 'sidebar',\n collapsible = 'offcanvas',\n className,\n children,\n ...props\n },\n ref,\n ) => {\n const { isMobile, state, openMobile, setOpenMobile } = useSidebar();\n\n if (collapsible === 'none') {\n return (\n \n {children}\n
    \n );\n }\n\n if (isMobile) {\n return (\n \n button]:tw-hidden\"\n style={\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n {\n '--sidebar-width': SIDEBAR_WIDTH_MOBILE,\n } as React.CSSProperties\n }\n side={side}\n >\n
    {children}
    \n \n
    \n );\n }\n\n return (\n \n {/* This is what handles the sidebar gap on desktop */}\n \n \n \n {children}\n
    \n
    \n
    \n );\n },\n);\nSidebar.displayName = 'Sidebar';\n\nconst SidebarTrigger = React.forwardRef<\n React.ElementRef,\n React.ComponentProps\n>(({ className, onClick, ...props }, ref) => {\n const { toggleSidebar } = useSidebar();\n\n return (\n {\n onClick?.(event);\n toggleSidebar();\n }}\n {...props}\n >\n \n Toggle Sidebar\n \n );\n});\nSidebarTrigger.displayName = 'SidebarTrigger';\n\nconst SidebarRail = React.forwardRef>(\n ({ className, ...props }, ref) => {\n const { toggleSidebar } = useSidebar();\n\n return (\n \n );\n },\n);\nSidebarRail.displayName = 'SidebarRail';\n\nconst SidebarInset = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarInset.displayName = 'SidebarInset';\n\nconst SidebarInput = React.forwardRef<\n React.ElementRef,\n React.ComponentProps\n>(({ className, ...props }, ref) => {\n return (\n \n );\n});\nSidebarInput.displayName = 'SidebarInput';\n\nconst SidebarHeader = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarHeader.displayName = 'SidebarHeader';\n\nconst SidebarFooter = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarFooter.displayName = 'SidebarFooter';\n\nconst SidebarSeparator = React.forwardRef<\n React.ElementRef,\n React.ComponentProps\n>(({ className, ...props }, ref) => {\n return (\n \n );\n});\nSidebarSeparator.displayName = 'SidebarSeparator';\n\nconst SidebarContent = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarContent.displayName = 'SidebarContent';\n\nconst SidebarGroup = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarGroup.displayName = 'SidebarGroup';\n\nconst SidebarGroupLabel = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & { asChild?: boolean }\n>(({ className, asChild = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'div';\n\n return (\n svg]:tw-size-4 [&>svg]:tw-shrink-0',\n 'group-data-[collapsible=icon]:tw--mt-8 group-data-[collapsible=icon]:tw-opacity-0',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarGroupLabel.displayName = 'SidebarGroupLabel';\n\nconst SidebarGroupAction = React.forwardRef<\n HTMLButtonElement,\n React.ComponentProps<'button'> & { asChild?: boolean }\n>(({ className, asChild = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'button';\n\n return (\n svg]:tw-size-4 [&>svg]:tw-shrink-0',\n // Increases the hit area of the button on mobile.\n 'after:tw-absolute after:tw--inset-2 after:md:tw-hidden',\n 'group-data-[collapsible=icon]:tw-hidden',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarGroupAction.displayName = 'SidebarGroupAction';\n\nconst SidebarGroupContent = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarGroupContent.displayName = 'SidebarGroupContent';\n\nconst SidebarMenu = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenu.displayName = 'SidebarMenu';\n\nconst SidebarMenuItem = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenuItem.displayName = 'SidebarMenuItem';\n\nconst sidebarMenuButtonVariants = cva(\n 'tw-peer/menu-button tw-flex tw-w-full tw-items-center tw-gap-2 tw-overflow-hidden tw-rounded-md tw-p-2 tw-text-left tw-text-sm tw-outline-none tw-ring-sidebar-ring tw-transition-[width,height,padding] hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground focus-visible:tw-ring-2 active:tw-bg-sidebar-accent active:tw-text-sidebar-accent-foreground disabled:tw-pointer-events-none disabled:tw-opacity-50 tw-group-has-[[data-sidebar=menu-action]]/menu-item:pr-8 aria-disabled:tw-pointer-events-none aria-disabled:tw-opacity-50 data-[active=true]:tw-bg-sidebar-accent data-[active=true]:tw-font-medium data-[active=true]:tw-text-sidebar-accent-foreground data-[state=open]:hover:tw-bg-sidebar-accent data-[state=open]:hover:tw-text-sidebar-accent-foreground group-data-[collapsible=icon]:tw-!size-8 group-data-[collapsible=icon]:tw-!p-2 [&>span:last-child]:tw-truncate [&>svg]:tw-size-4 [&>svg]:tw-shrink-0',\n {\n variants: {\n variant: {\n default: 'hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground',\n outline:\n 'tw-bg-background tw-shadow-[0_0_0_1px_hsl(var(--sidebar-border))] hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground hover:tw-shadow-[0_0_0_1px_hsl(var(--sidebar-accent))]',\n },\n size: {\n default: 'tw-h-8 tw-text-sm',\n sm: 'tw-h-7 tw-text-xs',\n lg: 'tw-h-12 tw-text-sm group-data-[collapsible=icon]:tw-!p-0',\n },\n },\n defaultVariants: {\n variant: 'default',\n size: 'default',\n },\n },\n);\n\nconst SidebarMenuButton = React.forwardRef<\n HTMLButtonElement,\n React.ComponentProps<'button'> & {\n asChild?: boolean;\n isActive?: boolean;\n tooltip?: string | React.ComponentProps;\n } & VariantProps\n>(\n (\n {\n asChild = false,\n isActive = false,\n variant = 'default',\n size = 'default',\n tooltip,\n className,\n ...props\n },\n ref,\n ) => {\n const Comp = asChild ? Slot : 'button';\n const { isMobile, state } = useSidebar();\n\n const button = (\n \n );\n\n if (!tooltip) {\n return button;\n }\n\n if (typeof tooltip === 'string') {\n // eslint-disable-next-line no-param-reassign\n tooltip = {\n children: tooltip,\n };\n }\n\n return (\n \n {button}\n \n );\n },\n);\nSidebarMenuButton.displayName = 'SidebarMenuButton';\n\nconst SidebarMenuAction = React.forwardRef<\n HTMLButtonElement,\n React.ComponentProps<'button'> & {\n asChild?: boolean;\n showOnHover?: boolean;\n }\n>(({ className, asChild = false, showOnHover = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'button';\n\n return (\n svg]:tw-size-4 [&>svg]:tw-shrink-0',\n // Increases the hit area of the button on mobile.\n 'after:tw-absolute after:tw--inset-2 after:md:tw-hidden',\n 'tw-peer-data-[size=sm]/menu-button:top-1',\n 'tw-peer-data-[size=default]/menu-button:top-1.5',\n 'tw-peer-data-[size=lg]/menu-button:top-2.5',\n 'group-data-[collapsible=icon]:tw-hidden',\n showOnHover &&\n 'tw-group-focus-within/menu-item:opacity-100 tw-group-hover/menu-item:opacity-100 tw-peer-data-[active=true]/menu-button:text-sidebar-accent-foreground data-[state=open]:tw-opacity-100 md:tw-opacity-0',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarMenuAction.displayName = 'SidebarMenuAction';\n\nconst SidebarMenuBadge = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenuBadge.displayName = 'SidebarMenuBadge';\n\nconst SidebarMenuSkeleton = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & {\n showIcon?: boolean;\n }\n>(({ className, showIcon = false, ...props }, ref) => {\n // Random width between 50 to 90%.\n const width = React.useMemo(() => {\n return `${Math.floor(Math.random() * 40) + 50}%`;\n }, []);\n\n return (\n \n {showIcon && (\n \n )}\n \n
    \n );\n});\nSidebarMenuSkeleton.displayName = 'SidebarMenuSkeleton';\n\nconst SidebarMenuSub = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenuSub.displayName = 'SidebarMenuSub';\n\nconst SidebarMenuSubItem = React.forwardRef>(\n ({ ...props }, ref) =>
  • ,\n);\nSidebarMenuSubItem.displayName = 'SidebarMenuSubItem';\n\nconst SidebarMenuSubButton = React.forwardRef<\n HTMLAnchorElement,\n React.ComponentProps<'a'> & {\n asChild?: boolean;\n size?: 'sm' | 'md';\n isActive?: boolean;\n }\n>(({ asChild = false, size = 'md', isActive, className, ...props }, ref) => {\n const Comp = asChild ? Slot : 'a';\n\n return (\n span:last-child]:tw-truncate [&>svg]:tw-size-4 [&>svg]:tw-shrink-0 [&>svg]:tw-text-sidebar-accent-foreground',\n 'data-[active=true]:tw-bg-sidebar-accent data-[active=true]:tw-text-sidebar-accent-foreground',\n size === 'sm' && 'tw-text-xs',\n size === 'md' && 'tw-text-sm',\n 'group-data-[collapsible=icon]:tw-hidden',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarMenuSubButton.displayName = 'SidebarMenuSubButton';\n\nexport {\n Sidebar,\n SidebarContent,\n SidebarFooter,\n SidebarGroup,\n SidebarGroupAction,\n SidebarGroupContent,\n SidebarGroupLabel,\n SidebarHeader,\n SidebarInput,\n SidebarInset,\n SidebarMenu,\n SidebarMenuAction,\n SidebarMenuBadge,\n SidebarMenuButton,\n SidebarMenuItem,\n SidebarMenuSkeleton,\n SidebarMenuSub,\n SidebarMenuSubButton,\n SidebarMenuSubItem,\n SidebarProvider,\n SidebarRail,\n SidebarSeparator,\n SidebarTrigger,\n useSidebar,\n};\n","import ComboBox, { ComboBoxOption } from '@/components/basics/combo-box.component';\nimport {\n Sidebar,\n SidebarContent,\n SidebarGroup,\n SidebarGroupLabel,\n SidebarGroupContent,\n SidebarMenu,\n SidebarMenuItem,\n SidebarMenuButton,\n} from '@/components/shadcn-ui/sidebar';\nimport { useCallback } from 'react';\n\nexport type SelectedSettingsSidebarItem = {\n label: string;\n projectId?: string;\n};\n\nexport type ProjectOptions = { projectId: string; projectName: string };\n\nexport type SettingsSidebarProps = {\n /** Optional id for testing */\n id?: string;\n\n /** Extension labels from contribution */\n extensionLabels: string[];\n\n /** Project names and ids */\n projectOptions: ProjectOptions[];\n\n /** Handler for selecting a sidebar item */\n handleSelectSidebarItem: (key: string, projectId?: string) => void;\n\n /** The current selected value in the sidebar */\n selectedSidebarItem: SelectedSettingsSidebarItem | undefined;\n};\n\nexport default function SettingsSidebar({\n id,\n extensionLabels,\n projectOptions,\n handleSelectSidebarItem,\n selectedSidebarItem,\n}: SettingsSidebarProps) {\n const handleSelectItem = useCallback(\n (item: string, projectId?: string) => {\n handleSelectSidebarItem(item, projectId);\n },\n [handleSelectSidebarItem],\n );\n\n const getProjectNameFromProjectId = useCallback(\n (projectId: string) => {\n const project = projectOptions.find((option) => option.projectId === projectId);\n return project ? project.projectName : projectId;\n },\n [projectOptions],\n );\n\n return (\n \n \n \n Extensions\n \n \n {extensionLabels.map((label) => (\n \n handleSelectItem(label)}\n isActive={\n !selectedSidebarItem?.projectId && label === selectedSidebarItem?.label\n }\n >\n {label}\n \n \n ))}\n \n \n \n \n Projects\n \n option.projectId)}\n getOptionLabel={(projectId: ComboBoxOption) => {\n // This function expects a ComboBoxOption, but we know it is a string\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n return getProjectNameFromProjectId(projectId as string);\n }}\n buttonPlaceholder=\"Type or select project\"\n onChange={(projectId: string) => {\n const selectedProjectName = getProjectNameFromProjectId(projectId);\n handleSelectItem(selectedProjectName, projectId);\n }}\n value={selectedSidebarItem?.projectId ?? undefined}\n />\n \n \n \n \n );\n}\n","import { SidebarInset, SidebarProvider } from '@/components/shadcn-ui/sidebar';\nimport { PropsWithChildren } from 'react';\nimport SettingsSidebar, { SettingsSidebarProps } from './settings-sidebar.component';\n\nexport type SettingsSidebarContentSearchProps = SettingsSidebarProps &\n PropsWithChildren & {\n /** Optional id for testing */\n id?: string;\n\n /** Text direction ltr or rtl */\n direction?: 'ltr' | 'rtl';\n };\n\nexport default function SettingsSidebarContentSearch({\n id,\n direction = 'ltr',\n extensionLabels,\n projectOptions,\n children,\n handleSelectSidebarItem,\n selectedSidebarItem,\n}: SettingsSidebarContentSearchProps) {\n return (\n \n \n {children}\n \n );\n}\n","import { Button } from '@/components/shadcn-ui/button';\nimport {\n Select,\n SelectContent,\n SelectGroup,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\nimport {\n Table,\n TableBody,\n TableCell,\n TableHead,\n TableHeader,\n TableRow,\n} from '@/components/shadcn-ui/table';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Canon } from '@sillsdev/scripture';\nimport {\n Cell,\n ColumnDef,\n flexRender,\n getCoreRowModel,\n getExpandedRowModel,\n getGroupedRowModel,\n getSortedRowModel,\n GroupingState,\n Row,\n RowSelectionState,\n SortingState,\n useReactTable,\n} from '@tanstack/react-table';\nimport '@/components/advanced/scripture-results-viewer/scripture-results-viewer.component.css';\nimport {\n compareScrRefs,\n formatScrRef,\n ScriptureSelection,\n scrRefToBBBCCCVVV,\n} from 'platform-bible-utils';\nimport { MouseEvent, useEffect, useMemo, useState } from 'react';\nimport { ChevronDown, ChevronLeft, ChevronRight } from 'lucide-react';\n\n/**\n * Information (e.g., a checking error or some other type of \"transient\" annotation) about something\n * noteworthy at a specific place in an instance of the Scriptures.\n */\nexport type ScriptureItemDetail = ScriptureSelection & {\n /**\n * Text of the error, note, etc. In the future, we might want to support something more than just\n * text so that a JSX element could be provided with a link or some other controls related to the\n * issue being reported.\n */\n detail: string;\n};\n\n/**\n * A uniquely identifiable source of results that can be displayed in the ScriptureResultsViewer.\n * Generally, the source will be a particular Scripture check, but there may be other types of\n * sources.\n */\nexport type ResultsSource = {\n /**\n * Uniquely identifies the source.\n *\n * @type {string}\n */\n id: string;\n\n /**\n * Name (potentially localized) of the source, suitable for display in the UI.\n *\n * @type {string}\n */\n displayName: string;\n};\n\nexport type ScriptureSrcItemDetail = ScriptureItemDetail & {\n /** Source/type of detail. Can be used for grouping. */\n source: ResultsSource;\n};\n\n/**\n * Represents a set of results keyed by Scripture reference. Generally, the source will be a\n * particular Scripture check, but this type also allows for other types of uniquely identifiable\n * sources.\n */\nexport type ResultsSet = {\n /**\n * The backing source associated with this set of results.\n *\n * @type {ResultsSource}\n */\n source: ResultsSource;\n\n /**\n * Array of Scripture item details (messages keyed by Scripture reference).\n *\n * @type {ScriptureItemDetail[]}\n */\n data: ScriptureItemDetail[];\n};\n\nconst scrBookColId = 'scrBook';\nconst scrRefColId = 'scrRef';\nconst typeColId = 'source';\nconst detailsColId = 'details';\n\nconst defaultScrRefColumnName = 'Scripture Reference';\nconst defaultScrBookGroupName = 'Scripture Book';\nconst defaultTypeColumnName = 'Type';\nconst defaultDetailsColumnName = 'Details';\n\nexport type ScriptureResultsViewerColumnInfo = {\n /** Optional header to display for the Reference column. Default value: 'Scripture Reference'. */\n scriptureReferenceColumnName?: string;\n\n /** Optional text to display to refer to the Scripture book group. Default value: 'Scripture Book'. */\n scriptureBookGroupName?: string;\n\n /** Optional header to display for the Type column. Default value: 'Type'. */\n typeColumnName?: string;\n\n /** Optional header to display for the Details column. Default value: 'Details' */\n detailsColumnName?: string;\n};\n\nexport type ScriptureResultsViewerProps = ScriptureResultsViewerColumnInfo & {\n /** Groups of ScriptureItemDetail objects from particular sources (e.g., Scripture checks) */\n sources: ResultsSet[];\n\n /** Flag indicating whether to display column headers. Default is false. */\n showColumnHeaders?: boolean;\n\n /** Flag indicating whether to display source column. Default is false. */\n showSourceColumn?: boolean;\n\n /** Callback function to notify when a row is selected */\n onRowSelected?: (selectedRow: ScriptureSrcItemDetail | undefined) => void;\n\n /** Text direction ltr or rtl */\n direction?: 'ltr' | 'rtl';\n};\n\nfunction getColumns(\n colInfo?: ScriptureResultsViewerColumnInfo,\n showSourceColumn?: boolean,\n): ColumnDef[] {\n const showSrcCol = showSourceColumn ?? false;\n return [\n {\n accessorFn: (row) =>\n `${Canon.bookNumberToId(row.start.bookNum)} ${row.start.chapterNum}:${row.start.verseNum}`,\n id: scrBookColId,\n header: colInfo?.scriptureReferenceColumnName ?? defaultScrRefColumnName,\n cell: (info) => {\n const row = info.row.original;\n if (info.row.getIsGrouped()) {\n return Canon.bookNumberToEnglishName(row.start.bookNum);\n }\n return info.row.groupingColumnId === scrBookColId ? formatScrRef(row.start) : undefined;\n },\n getGroupingValue: (row) => row.start.bookNum,\n sortingFn: (a, b) => {\n return compareScrRefs(a.original.start, b.original.start);\n },\n enableGrouping: true,\n },\n {\n accessorFn: (row) => formatScrRef(row.start),\n id: scrRefColId,\n header: undefined,\n cell: (info) => {\n const row = info.row.original;\n return info.row.getIsGrouped() ? undefined : formatScrRef(row.start);\n },\n sortingFn: (a, b) => {\n return compareScrRefs(a.original.start, b.original.start);\n },\n enableGrouping: false,\n },\n {\n accessorFn: (row) => row.source.displayName,\n id: typeColId,\n header: showSrcCol ? (colInfo?.typeColumnName ?? defaultTypeColumnName) : undefined,\n cell: (info) => (showSrcCol || info.row.getIsGrouped() ? info.getValue() : undefined),\n getGroupingValue: (row) => row.source.id,\n sortingFn: (a, b) =>\n a.original.source.displayName.localeCompare(b.original.source.displayName),\n enableGrouping: true,\n },\n {\n accessorFn: (row) => row.detail,\n id: detailsColId,\n header: colInfo?.detailsColumnName ?? defaultDetailsColumnName,\n cell: (info) => info.getValue(),\n enableGrouping: false,\n },\n ];\n}\n\nconst toRefOrRange = (scriptureSelection: ScriptureSelection) => {\n if (!('offset' in scriptureSelection.start))\n throw new Error('No offset available in range start');\n if (scriptureSelection.end && !('offset' in scriptureSelection.end))\n throw new Error('No offset available in range end');\n const { offset: offsetStart } = scriptureSelection.start;\n let offsetEnd: number = 0;\n if (scriptureSelection.end) ({ offset: offsetEnd } = scriptureSelection.end);\n if (\n !scriptureSelection.end ||\n compareScrRefs(scriptureSelection.start, scriptureSelection.end) === 0\n )\n return `${scrRefToBBBCCCVVV(scriptureSelection.start)}+${offsetStart}`;\n return `${scrRefToBBBCCCVVV(scriptureSelection.start)}+${offsetStart}-${scrRefToBBBCCCVVV(scriptureSelection.end)}+${offsetEnd}`;\n};\n\nconst getRowKey = (row: ScriptureSrcItemDetail) =>\n `${toRefOrRange({ start: row.start, end: row.end })} ${row.source.displayName} ${row.detail}`;\n\n/**\n * Component to display a combined list of detailed items from one or more sources, where the items\n * are keyed primarily by Scripture reference. This is particularly useful for displaying a list of\n * results from Scripture checks, but more generally could be used to display any \"results\" from any\n * source(s). The component allows for grouping by Scripture book, source, or both. By default, it\n * displays somewhat \"tree-like\" which allows it to be more horizontally compact and intuitive. But\n * it also has the option of displaying as a traditional table with column headings (with or without\n * the source column showing).\n */\nexport default function ScriptureResultsViewer({\n sources,\n showColumnHeaders = false,\n showSourceColumn = false,\n scriptureReferenceColumnName,\n scriptureBookGroupName,\n typeColumnName,\n detailsColumnName,\n onRowSelected,\n direction = 'ltr',\n}: ScriptureResultsViewerProps) {\n const [grouping, setGrouping] = useState([]);\n const [sorting, setSorting] = useState([{ id: scrBookColId, desc: false }]);\n const [rowSelection, setRowSelection] = useState({});\n\n const scriptureResults = useMemo(\n () =>\n sources.flatMap((source) => {\n return source.data.map((item) => ({\n ...item,\n source: source.source,\n }));\n }),\n [sources],\n );\n\n const columns = useMemo(\n () =>\n getColumns(\n {\n scriptureReferenceColumnName,\n typeColumnName,\n detailsColumnName,\n },\n showSourceColumn,\n ),\n [scriptureReferenceColumnName, typeColumnName, detailsColumnName, showSourceColumn],\n );\n\n useEffect(() => {\n // Ensure sorting is applied correctly when grouped by type\n if (grouping.includes(typeColId)) {\n setSorting([\n { id: typeColId, desc: false },\n { id: scrBookColId, desc: false },\n ]);\n } else {\n setSorting([{ id: scrBookColId, desc: false }]);\n }\n }, [grouping]);\n\n const table = useReactTable({\n data: scriptureResults,\n columns,\n state: {\n grouping,\n sorting,\n rowSelection,\n },\n onGroupingChange: setGrouping,\n onSortingChange: setSorting,\n onRowSelectionChange: setRowSelection,\n getExpandedRowModel: getExpandedRowModel(),\n getGroupedRowModel: getGroupedRowModel(),\n getCoreRowModel: getCoreRowModel(),\n getSortedRowModel: getSortedRowModel(),\n getRowId: getRowKey,\n autoResetExpanded: false,\n enableMultiRowSelection: false,\n enableSubRowSelection: false,\n });\n\n useEffect(() => {\n if (onRowSelected) {\n const selectedRows = table.getSelectedRowModel().rowsById;\n const keys = Object.keys(selectedRows);\n if (keys.length === 1) {\n const selectedRow = scriptureResults.find((row) => getRowKey(row) === keys[0]) || undefined;\n if (selectedRow) onRowSelected(selectedRow);\n }\n }\n }, [rowSelection, scriptureResults, onRowSelected, table]);\n\n // Define possible grouping options\n const scrBookGroupName = scriptureBookGroupName ?? defaultScrBookGroupName;\n const typeGroupName = typeColumnName ?? defaultTypeColumnName;\n\n const groupingOptions = [\n { label: 'No Grouping', value: [] },\n { label: `Group by ${scrBookGroupName}`, value: [scrBookColId] },\n { label: `Group by ${typeGroupName}`, value: [typeColId] },\n {\n label: `Group by ${scrBookGroupName} and ${typeGroupName}`,\n value: [scrBookColId, typeColId],\n },\n {\n label: `Group by ${typeGroupName} and ${scrBookGroupName}`,\n value: [typeColId, scrBookColId],\n },\n ];\n\n const handleSelectChange = (selectedGrouping: string) => {\n setGrouping(JSON.parse(selectedGrouping));\n };\n\n const handleRowClick = (row: Row, event: MouseEvent) => {\n if (!row.getIsGrouped() && !row.getIsSelected()) {\n row.getToggleSelectedHandler()(event);\n }\n };\n\n const getEvenOrOddBandingStyle = (row: Row, index: number) => {\n if (row.getIsGrouped()) return '';\n // UX has now said they don't think they want banding. I'm leaving in the code to\n // set even and odd styles, but there's nothing in the CSS to style them differently.\n // The \"even\" style used to also have tw-bg-neutral-300 (along with even) to create\n // a visual banding effect. That could be added back in if UX changes the decision.\n return cn('banded-row', index % 2 === 0 ? 'even' : 'odd');\n };\n\n const getIndent = (\n groupingState: GroupingState,\n row: Row,\n cell: Cell,\n ) => {\n if (groupingState?.length === 0 || row.depth < cell.column.getGroupedIndex()) return undefined;\n if (row.getIsGrouped()) {\n switch (row.depth) {\n case 1:\n return 'tw-ps-4';\n default:\n return undefined;\n }\n }\n switch (row.depth) {\n case 1:\n return 'tw-ps-8';\n case 2:\n return 'tw-ps-12';\n default:\n return undefined;\n }\n };\n\n return (\n
    \n {!showColumnHeaders && (\n {\n handleSelectChange(value);\n }}\n >\n \n \n \n \n \n {groupingOptions.map((option) => (\n \n {option.label}\n \n ))}\n \n \n \n )}\n \n {showColumnHeaders && (\n \n {table.getHeaderGroups().map((headerGroup) => (\n \n {headerGroup.headers\n .filter((h) => h.column.columnDef.header)\n .map((header) => (\n /* For sticky column headers to work, we probably need to change the default definition of the shadcn Table component. See https://github.com/shadcn-ui/ui/issues/1151 */\n \n {header.isPlaceholder ? undefined : (\n
    \n {header.column.getCanGroup() ? (\n \n {header.column.getIsGrouped() ? `🛑` : `👊 `}\n \n ) : undefined}{' '}\n {flexRender(header.column.columnDef.header, header.getContext())}\n
    \n )}\n
    \n ))}\n
    \n ))}\n
    \n )}\n \n {table.getRowModel().rows.map((row, rowIndex) => {\n return (\n handleRowClick(row, event)}\n >\n {row.getVisibleCells().map((cell) => {\n if (\n cell.getIsPlaceholder() ||\n (cell.column.columnDef.enableGrouping &&\n !cell.getIsGrouped() &&\n (cell.column.columnDef.id !== typeColId || !showSourceColumn))\n )\n return undefined;\n return (\n \n {(() => {\n if (cell.getIsGrouped()) {\n return (\n \n {row.getIsExpanded() && }\n {!row.getIsExpanded() &&\n (direction === 'ltr' ? : )}{' '}\n {flexRender(cell.column.columnDef.cell, cell.getContext())} (\n {row.subRows.length})\n \n );\n }\n\n // if (cell.getIsAggregated()) {\n // flexRender(\n // cell.column.columnDef.aggregatedCell ?? cell.column.columnDef.cell,\n // cell.getContext(),\n // );\n // }\n\n return flexRender(cell.column.columnDef.cell, cell.getContext());\n })()}\n \n );\n })}\n \n );\n })}\n \n
    \n
    \n );\n}\n","import {\n getLocalizeKeyForScrollGroupId,\n LanguageStrings,\n ScrollGroupId,\n} from 'platform-bible-utils';\nimport {\n Select,\n SelectContent,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\n\nconst DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS = {\n [getLocalizeKeyForScrollGroupId('undefined')]: 'Ø',\n [getLocalizeKeyForScrollGroupId(0)]: 'A',\n [getLocalizeKeyForScrollGroupId(1)]: 'B',\n [getLocalizeKeyForScrollGroupId(2)]: 'C',\n [getLocalizeKeyForScrollGroupId(3)]: 'D',\n [getLocalizeKeyForScrollGroupId(4)]: 'E',\n [getLocalizeKeyForScrollGroupId(5)]: 'F',\n [getLocalizeKeyForScrollGroupId(6)]: 'G',\n [getLocalizeKeyForScrollGroupId(7)]: 'H',\n [getLocalizeKeyForScrollGroupId(8)]: 'I',\n [getLocalizeKeyForScrollGroupId(9)]: 'J',\n [getLocalizeKeyForScrollGroupId(10)]: 'K',\n [getLocalizeKeyForScrollGroupId(11)]: 'L',\n [getLocalizeKeyForScrollGroupId(12)]: 'M',\n [getLocalizeKeyForScrollGroupId(13)]: 'N',\n [getLocalizeKeyForScrollGroupId(14)]: 'O',\n [getLocalizeKeyForScrollGroupId(15)]: 'P',\n [getLocalizeKeyForScrollGroupId(16)]: 'Q',\n [getLocalizeKeyForScrollGroupId(17)]: 'R',\n [getLocalizeKeyForScrollGroupId(18)]: 'S',\n [getLocalizeKeyForScrollGroupId(19)]: 'T',\n [getLocalizeKeyForScrollGroupId(20)]: 'U',\n [getLocalizeKeyForScrollGroupId(21)]: 'V',\n [getLocalizeKeyForScrollGroupId(22)]: 'W',\n [getLocalizeKeyForScrollGroupId(23)]: 'X',\n [getLocalizeKeyForScrollGroupId(24)]: 'Y',\n [getLocalizeKeyForScrollGroupId(25)]: 'Z',\n};\n\nexport type ScrollGroupSelectorProps = {\n /**\n * List of scroll group ids to show to the user. Either a {@link ScrollGroupId} or `undefined` for\n * no scroll group\n */\n availableScrollGroupIds: (ScrollGroupId | undefined)[];\n /** Currently selected scroll group id. `undefined` for no scroll group */\n scrollGroupId: ScrollGroupId | undefined;\n /** Callback function run when the user tries to change the scroll group id */\n onChangeScrollGroupId: (newScrollGroupId: ScrollGroupId | undefined) => void;\n /**\n * Localized strings to use for displaying scroll group ids. Must be an object whose keys are\n * `getLocalizeKeyForScrollGroupId(scrollGroupId)` for all scroll group ids (and `undefined` if\n * included) in {@link ScrollGroupSelectorProps.availableScrollGroupIds} and whose values are the\n * localized strings to use for those scroll group ids.\n *\n * Defaults to English localizations of English alphabet for scroll groups 0-25 (e.g. 0 is A) and\n * Ø for `undefined`. Will fill in any that are not provided with these English localizations.\n * Also, if any values match the keys, the English localization will be used. This is useful in\n * case you want to pass in a temporary version of the localized strings while your localized\n * strings load.\n *\n * @example\n *\n * ```typescript\n * const myScrollGroupIdLocalizedStrings = {\n * [getLocalizeKeyForScrollGroupId('undefined')]: 'Ø',\n * [getLocalizeKeyForScrollGroupId(0)]: 'A',\n * [getLocalizeKeyForScrollGroupId(1)]: 'B',\n * [getLocalizeKeyForScrollGroupId(2)]: 'C',\n * [getLocalizeKeyForScrollGroupId(3)]: 'D',\n * [getLocalizeKeyForScrollGroupId(4)]: 'E',\n * };\n * ```\n *\n * @example\n *\n * ```tsx\n * const availableScrollGroupIds = [undefined, 0, 1, 2, 3, 4];\n *\n * const localizeKeys = getLocalizeKeysForScrollGroupIds();\n *\n * const [localizedStrings] = useLocalizedStrings(localizeKeys);\n *\n * ...\n *\n * \n * ```\n */\n localizedStrings?: LanguageStrings;\n};\n\n/** Selector component for choosing a scroll group */\nexport default function ScrollGroupSelector({\n availableScrollGroupIds,\n scrollGroupId,\n onChangeScrollGroupId,\n localizedStrings = {},\n}: ScrollGroupSelectorProps) {\n const localizedStringsDefaulted = {\n ...DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS,\n ...Object.fromEntries(\n Object.entries(localizedStrings).map(\n ([localizedStringKey, localizedStringValue]: [string, string]) => [\n localizedStringKey,\n localizedStringKey === localizedStringValue &&\n localizedStringKey in DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS\n ? DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS[localizedStringKey]\n : localizedStringValue,\n ],\n ),\n ),\n };\n return (\n \n onChangeScrollGroupId(\n newScrollGroupString === 'undefined' ? undefined : parseInt(newScrollGroupString, 10),\n )\n }\n >\n \n \n \n \n {availableScrollGroupIds.map((scrollGroupOptionId) => (\n \n {localizedStringsDefaulted[getLocalizeKeyForScrollGroupId(scrollGroupOptionId)]}\n \n ))}\n \n \n );\n}\n","import { PropsWithChildren } from 'react';\nimport { Separator } from '@/components/shadcn-ui/separator';\n\n/** Props for the SettingsList component, currently just children */\ntype SettingsListProps = PropsWithChildren;\n\n/**\n * SettingsList component is a wrapper for list items. Rendered with a formatted div\n *\n * @param children To populate the list with\n * @returns Formatted div encompassing the children\n */\nexport function SettingsList({ children }: SettingsListProps) {\n return
    {children}
    ;\n}\n\n/** Props for SettingsListItem component */\ntype SettingsListItemProps = PropsWithChildren & {\n /** Primary text of the list item */\n primary: string;\n\n /** Optional text of the list item */\n secondary?: string | undefined;\n\n /** Optional boolean to display a message if the children aren't loaded yet. Defaults to false */\n isLoading?: boolean;\n\n /** Optional message to display if isLoading */\n loadingMessage?: string;\n};\n\n/**\n * SettingsListItem component is a common list item. Rendered with a formatted div\n *\n * @param primary Primary text of the list item\n * @param secondary Optional secondary text of the list item\n * @param isLoading Optional, to display a message if the action component isn't generated yet,\n * defaults to false\n * @param children The action component(s) to provide for this item\n * @param loadingMessage Optional, message to display if isLoading\n * @returns Formatted div encompassing the list item content\n */\nexport function SettingsListItem({\n primary,\n secondary,\n children,\n isLoading = false,\n loadingMessage,\n}: SettingsListItemProps) {\n return (\n
    \n
    \n

    {primary}

    \n

    \n {secondary}\n

    \n
    \n\n {isLoading ? (\n

    {loadingMessage}

    \n ) : (\n
    {children}
    \n )}\n
    \n );\n}\n\n/** Props for SettingsListHeader component */\ntype SettingsListHeaderProps = {\n /** The primary text of the list header */\n primary: string;\n\n /** Optional secondary text of the list header */\n secondary?: string | undefined;\n\n /** Optional boolean to include a separator underneath the secondary text. Defaults to false */\n includeSeparator?: boolean;\n};\n\n/**\n * SettingsListHeader component displays text above the list\n *\n * @param primary The primary text of the list header\n * @param secondary Optional secondary text of the list header\n * @param includeSeparator Optional boolean to include a separator underneath the secondary text.\n * Defaults to false\n * @returns Formatted div with list header content\n */\nexport function SettingsListHeader({\n primary,\n secondary,\n includeSeparator = false,\n}: SettingsListHeaderProps) {\n return (\n
    \n
    \n

    {primary}

    \n

    {secondary}

    \n
    \n {includeSeparator ? : ''}\n
    \n );\n}\n","import React from 'react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Card = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nCard.displayName = 'Card';\n\nconst CardHeader = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nCardHeader.displayName = 'CardHeader';\n\nconst CardTitle = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n {/* added because of https://github.com/jsx-eslint/eslint-plugin-jsx-a11y/blob/main/docs/rules/heading-has-content.md */}\n {props.children}\n \n ),\n);\nCardTitle.displayName = 'CardTitle';\n\nconst CardDescription = React.forwardRef<\n HTMLParagraphElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n

    \n));\nCardDescription.displayName = 'CardDescription';\n\nconst CardContent = React.forwardRef>(\n ({ className, ...props }, ref) => (\n

    \n ),\n);\nCardContent.displayName = 'CardContent';\n\nconst CardFooter = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nCardFooter.displayName = 'CardFooter';\n\nexport { Card, CardHeader, CardFooter, CardTitle, CardDescription, CardContent };\n","import { Card, CardDescription, CardHeader, CardTitle } from '@/components/shadcn-ui/card';\nimport { CardContent } from '@mui/material';\nimport { PropsWithChildren } from 'react';\n\ntype SettingsCardProps = PropsWithChildren & {\n /** Optional id for testing */\n id?: string;\n\n /** Label of the settings group */\n settingsGroupLabel: string;\n\n /** Optional description of the settings group */\n settingsGroupDescription?: string;\n};\n\nexport default function SettingsCard({\n id,\n settingsGroupLabel,\n settingsGroupDescription,\n children,\n}: SettingsCardProps) {\n return (\n \n \n {settingsGroupLabel}\n {settingsGroupDescription && {settingsGroupDescription}}\n \n {children}\n \n );\n}\n","import Checkbox from '@/components/shadcn-ui/checkbox';\nimport { Label } from '@/components/shadcn-ui/label';\n\nexport type ChecklistProps = {\n /** Optional string representing the id attribute of the Checklist */\n id?: string;\n /** Optional string representing CSS class name(s) for styling */\n className?: string;\n /** Array of strings representing the checkable items */\n listItems: string[];\n /** Array of strings representing the checked items */\n selectedListItems: string[];\n /**\n * Function that is called when a checkbox item is selected or deselected\n *\n * @param item The string description for this item\n * @param selected True if selected, false if not selected\n */\n handleSelectListItem: (item: string, selected: boolean) => void;\n\n /**\n * Optional function creates a label for a provided checkable item\n *\n * @param item The item for which a label is to be created\n * @returns A string representing the label text for the checkbox associated with that item\n */\n createLabel?: (item: string) => string;\n};\n\n/** Renders a list of checkboxes. Each checkbox corresponds to an item from the `listItems` array. */\nexport default function Checklist({\n id,\n className,\n listItems,\n selectedListItems,\n handleSelectListItem,\n createLabel,\n}: ChecklistProps) {\n return (\n
    \n {listItems.map((item) => (\n
    \n handleSelectListItem(item, value)}\n />\n \n
    \n ))}\n
    \n );\n}\n","function _interopRequireDefault(obj) {\n return obj && obj.__esModule ? obj : {\n \"default\": obj\n };\n}\nmodule.exports = _interopRequireDefault, module.exports.__esModule = true, module.exports[\"default\"] = module.exports;","export default function chainPropTypes(propType1, propType2) {\n if (process.env.NODE_ENV === 'production') {\n return () => null;\n }\n return function validate(...args) {\n return propType1(...args) || propType2(...args);\n };\n}","export default function _extends() {\n _extends = Object.assign ? Object.assign.bind() : function (target) {\n for (var i = 1; i < arguments.length; i++) {\n var source = arguments[i];\n for (var key in source) {\n if (Object.prototype.hasOwnProperty.call(source, key)) {\n target[key] = source[key];\n }\n }\n }\n return target;\n };\n return _extends.apply(this, arguments);\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\n// https://github.com/sindresorhus/is-plain-obj/blob/main/index.js\nexport function isPlainObject(item) {\n if (typeof item !== 'object' || item === null) {\n return false;\n }\n const prototype = Object.getPrototypeOf(item);\n return (prototype === null || prototype === Object.prototype || Object.getPrototypeOf(prototype) === null) && !(Symbol.toStringTag in item) && !(Symbol.iterator in item);\n}\nfunction deepClone(source) {\n if (!isPlainObject(source)) {\n return source;\n }\n const output = {};\n Object.keys(source).forEach(key => {\n output[key] = deepClone(source[key]);\n });\n return output;\n}\nexport default function deepmerge(target, source, options = {\n clone: true\n}) {\n const output = options.clone ? _extends({}, target) : target;\n if (isPlainObject(target) && isPlainObject(source)) {\n Object.keys(source).forEach(key => {\n // Avoid prototype pollution\n if (key === '__proto__') {\n return;\n }\n if (isPlainObject(source[key]) && key in target && isPlainObject(target[key])) {\n // Since `output` is a clone of `target` and we have narrowed `target` in this block we can cast to the same type.\n output[key] = deepmerge(target[key], source[key], options);\n } else if (options.clone) {\n output[key] = isPlainObject(source[key]) ? deepClone(source[key]) : source[key];\n } else {\n output[key] = source[key];\n }\n });\n }\n return output;\n}","/** @license React v16.13.1\n * react-is.production.min.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';var b=\"function\"===typeof Symbol&&Symbol.for,c=b?Symbol.for(\"react.element\"):60103,d=b?Symbol.for(\"react.portal\"):60106,e=b?Symbol.for(\"react.fragment\"):60107,f=b?Symbol.for(\"react.strict_mode\"):60108,g=b?Symbol.for(\"react.profiler\"):60114,h=b?Symbol.for(\"react.provider\"):60109,k=b?Symbol.for(\"react.context\"):60110,l=b?Symbol.for(\"react.async_mode\"):60111,m=b?Symbol.for(\"react.concurrent_mode\"):60111,n=b?Symbol.for(\"react.forward_ref\"):60112,p=b?Symbol.for(\"react.suspense\"):60113,q=b?\nSymbol.for(\"react.suspense_list\"):60120,r=b?Symbol.for(\"react.memo\"):60115,t=b?Symbol.for(\"react.lazy\"):60116,v=b?Symbol.for(\"react.block\"):60121,w=b?Symbol.for(\"react.fundamental\"):60117,x=b?Symbol.for(\"react.responder\"):60118,y=b?Symbol.for(\"react.scope\"):60119;\nfunction z(a){if(\"object\"===typeof a&&null!==a){var u=a.$$typeof;switch(u){case c:switch(a=a.type,a){case l:case m:case e:case g:case f:case p:return a;default:switch(a=a&&a.$$typeof,a){case k:case n:case t:case r:case h:return a;default:return u}}case d:return u}}}function A(a){return z(a)===m}exports.AsyncMode=l;exports.ConcurrentMode=m;exports.ContextConsumer=k;exports.ContextProvider=h;exports.Element=c;exports.ForwardRef=n;exports.Fragment=e;exports.Lazy=t;exports.Memo=r;exports.Portal=d;\nexports.Profiler=g;exports.StrictMode=f;exports.Suspense=p;exports.isAsyncMode=function(a){return A(a)||z(a)===l};exports.isConcurrentMode=A;exports.isContextConsumer=function(a){return z(a)===k};exports.isContextProvider=function(a){return z(a)===h};exports.isElement=function(a){return\"object\"===typeof a&&null!==a&&a.$$typeof===c};exports.isForwardRef=function(a){return z(a)===n};exports.isFragment=function(a){return z(a)===e};exports.isLazy=function(a){return z(a)===t};\nexports.isMemo=function(a){return z(a)===r};exports.isPortal=function(a){return z(a)===d};exports.isProfiler=function(a){return z(a)===g};exports.isStrictMode=function(a){return z(a)===f};exports.isSuspense=function(a){return z(a)===p};\nexports.isValidElementType=function(a){return\"string\"===typeof a||\"function\"===typeof a||a===e||a===m||a===g||a===f||a===p||a===q||\"object\"===typeof a&&null!==a&&(a.$$typeof===t||a.$$typeof===r||a.$$typeof===h||a.$$typeof===k||a.$$typeof===n||a.$$typeof===w||a.$$typeof===x||a.$$typeof===y||a.$$typeof===v)};exports.typeOf=z;\n","/** @license React v16.13.1\n * react-is.development.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\n\n\nif (process.env.NODE_ENV !== \"production\") {\n (function() {\n'use strict';\n\n// The Symbol used to tag the ReactElement-like types. If there is no native Symbol\n// nor polyfill, then a plain number is used for performance.\nvar hasSymbol = typeof Symbol === 'function' && Symbol.for;\nvar REACT_ELEMENT_TYPE = hasSymbol ? Symbol.for('react.element') : 0xeac7;\nvar REACT_PORTAL_TYPE = hasSymbol ? Symbol.for('react.portal') : 0xeaca;\nvar REACT_FRAGMENT_TYPE = hasSymbol ? Symbol.for('react.fragment') : 0xeacb;\nvar REACT_STRICT_MODE_TYPE = hasSymbol ? Symbol.for('react.strict_mode') : 0xeacc;\nvar REACT_PROFILER_TYPE = hasSymbol ? Symbol.for('react.profiler') : 0xead2;\nvar REACT_PROVIDER_TYPE = hasSymbol ? Symbol.for('react.provider') : 0xeacd;\nvar REACT_CONTEXT_TYPE = hasSymbol ? Symbol.for('react.context') : 0xeace; // TODO: We don't use AsyncMode or ConcurrentMode anymore. They were temporary\n// (unstable) APIs that have been removed. Can we remove the symbols?\n\nvar REACT_ASYNC_MODE_TYPE = hasSymbol ? Symbol.for('react.async_mode') : 0xeacf;\nvar REACT_CONCURRENT_MODE_TYPE = hasSymbol ? Symbol.for('react.concurrent_mode') : 0xeacf;\nvar REACT_FORWARD_REF_TYPE = hasSymbol ? Symbol.for('react.forward_ref') : 0xead0;\nvar REACT_SUSPENSE_TYPE = hasSymbol ? Symbol.for('react.suspense') : 0xead1;\nvar REACT_SUSPENSE_LIST_TYPE = hasSymbol ? Symbol.for('react.suspense_list') : 0xead8;\nvar REACT_MEMO_TYPE = hasSymbol ? Symbol.for('react.memo') : 0xead3;\nvar REACT_LAZY_TYPE = hasSymbol ? Symbol.for('react.lazy') : 0xead4;\nvar REACT_BLOCK_TYPE = hasSymbol ? Symbol.for('react.block') : 0xead9;\nvar REACT_FUNDAMENTAL_TYPE = hasSymbol ? Symbol.for('react.fundamental') : 0xead5;\nvar REACT_RESPONDER_TYPE = hasSymbol ? Symbol.for('react.responder') : 0xead6;\nvar REACT_SCOPE_TYPE = hasSymbol ? Symbol.for('react.scope') : 0xead7;\n\nfunction isValidElementType(type) {\n return typeof type === 'string' || typeof type === 'function' || // Note: its typeof might be other than 'symbol' or 'number' if it's a polyfill.\n type === REACT_FRAGMENT_TYPE || type === REACT_CONCURRENT_MODE_TYPE || type === REACT_PROFILER_TYPE || type === REACT_STRICT_MODE_TYPE || type === REACT_SUSPENSE_TYPE || type === REACT_SUSPENSE_LIST_TYPE || typeof type === 'object' && type !== null && (type.$$typeof === REACT_LAZY_TYPE || type.$$typeof === REACT_MEMO_TYPE || type.$$typeof === REACT_PROVIDER_TYPE || type.$$typeof === REACT_CONTEXT_TYPE || type.$$typeof === REACT_FORWARD_REF_TYPE || type.$$typeof === REACT_FUNDAMENTAL_TYPE || type.$$typeof === REACT_RESPONDER_TYPE || type.$$typeof === REACT_SCOPE_TYPE || type.$$typeof === REACT_BLOCK_TYPE);\n}\n\nfunction typeOf(object) {\n if (typeof object === 'object' && object !== null) {\n var $$typeof = object.$$typeof;\n\n switch ($$typeof) {\n case REACT_ELEMENT_TYPE:\n var type = object.type;\n\n switch (type) {\n case REACT_ASYNC_MODE_TYPE:\n case REACT_CONCURRENT_MODE_TYPE:\n case REACT_FRAGMENT_TYPE:\n case REACT_PROFILER_TYPE:\n case REACT_STRICT_MODE_TYPE:\n case REACT_SUSPENSE_TYPE:\n return type;\n\n default:\n var $$typeofType = type && type.$$typeof;\n\n switch ($$typeofType) {\n case REACT_CONTEXT_TYPE:\n case REACT_FORWARD_REF_TYPE:\n case REACT_LAZY_TYPE:\n case REACT_MEMO_TYPE:\n case REACT_PROVIDER_TYPE:\n return $$typeofType;\n\n default:\n return $$typeof;\n }\n\n }\n\n case REACT_PORTAL_TYPE:\n return $$typeof;\n }\n }\n\n return undefined;\n} // AsyncMode is deprecated along with isAsyncMode\n\nvar AsyncMode = REACT_ASYNC_MODE_TYPE;\nvar ConcurrentMode = REACT_CONCURRENT_MODE_TYPE;\nvar ContextConsumer = REACT_CONTEXT_TYPE;\nvar ContextProvider = REACT_PROVIDER_TYPE;\nvar Element = REACT_ELEMENT_TYPE;\nvar ForwardRef = REACT_FORWARD_REF_TYPE;\nvar Fragment = REACT_FRAGMENT_TYPE;\nvar Lazy = REACT_LAZY_TYPE;\nvar Memo = REACT_MEMO_TYPE;\nvar Portal = REACT_PORTAL_TYPE;\nvar Profiler = REACT_PROFILER_TYPE;\nvar StrictMode = REACT_STRICT_MODE_TYPE;\nvar Suspense = REACT_SUSPENSE_TYPE;\nvar hasWarnedAboutDeprecatedIsAsyncMode = false; // AsyncMode should be deprecated\n\nfunction isAsyncMode(object) {\n {\n if (!hasWarnedAboutDeprecatedIsAsyncMode) {\n hasWarnedAboutDeprecatedIsAsyncMode = true; // Using console['warn'] to evade Babel and ESLint\n\n console['warn']('The ReactIs.isAsyncMode() alias has been deprecated, ' + 'and will be removed in React 17+. Update your code to use ' + 'ReactIs.isConcurrentMode() instead. It has the exact same API.');\n }\n }\n\n return isConcurrentMode(object) || typeOf(object) === REACT_ASYNC_MODE_TYPE;\n}\nfunction isConcurrentMode(object) {\n return typeOf(object) === REACT_CONCURRENT_MODE_TYPE;\n}\nfunction isContextConsumer(object) {\n return typeOf(object) === REACT_CONTEXT_TYPE;\n}\nfunction isContextProvider(object) {\n return typeOf(object) === REACT_PROVIDER_TYPE;\n}\nfunction isElement(object) {\n return typeof object === 'object' && object !== null && object.$$typeof === REACT_ELEMENT_TYPE;\n}\nfunction isForwardRef(object) {\n return typeOf(object) === REACT_FORWARD_REF_TYPE;\n}\nfunction isFragment(object) {\n return typeOf(object) === REACT_FRAGMENT_TYPE;\n}\nfunction isLazy(object) {\n return typeOf(object) === REACT_LAZY_TYPE;\n}\nfunction isMemo(object) {\n return typeOf(object) === REACT_MEMO_TYPE;\n}\nfunction isPortal(object) {\n return typeOf(object) === REACT_PORTAL_TYPE;\n}\nfunction isProfiler(object) {\n return typeOf(object) === REACT_PROFILER_TYPE;\n}\nfunction isStrictMode(object) {\n return typeOf(object) === REACT_STRICT_MODE_TYPE;\n}\nfunction isSuspense(object) {\n return typeOf(object) === REACT_SUSPENSE_TYPE;\n}\n\nexports.AsyncMode = AsyncMode;\nexports.ConcurrentMode = ConcurrentMode;\nexports.ContextConsumer = ContextConsumer;\nexports.ContextProvider = ContextProvider;\nexports.Element = Element;\nexports.ForwardRef = ForwardRef;\nexports.Fragment = Fragment;\nexports.Lazy = Lazy;\nexports.Memo = Memo;\nexports.Portal = Portal;\nexports.Profiler = Profiler;\nexports.StrictMode = StrictMode;\nexports.Suspense = Suspense;\nexports.isAsyncMode = isAsyncMode;\nexports.isConcurrentMode = isConcurrentMode;\nexports.isContextConsumer = isContextConsumer;\nexports.isContextProvider = isContextProvider;\nexports.isElement = isElement;\nexports.isForwardRef = isForwardRef;\nexports.isFragment = isFragment;\nexports.isLazy = isLazy;\nexports.isMemo = isMemo;\nexports.isPortal = isPortal;\nexports.isProfiler = isProfiler;\nexports.isStrictMode = isStrictMode;\nexports.isSuspense = isSuspense;\nexports.isValidElementType = isValidElementType;\nexports.typeOf = typeOf;\n })();\n}\n","'use strict';\n\nif (process.env.NODE_ENV === 'production') {\n module.exports = require('./cjs/react-is.production.min.js');\n} else {\n module.exports = require('./cjs/react-is.development.js');\n}\n","/*\nobject-assign\n(c) Sindre Sorhus\n@license MIT\n*/\n\n'use strict';\n/* eslint-disable no-unused-vars */\nvar getOwnPropertySymbols = Object.getOwnPropertySymbols;\nvar hasOwnProperty = Object.prototype.hasOwnProperty;\nvar propIsEnumerable = Object.prototype.propertyIsEnumerable;\n\nfunction toObject(val) {\n\tif (val === null || val === undefined) {\n\t\tthrow new TypeError('Object.assign cannot be called with null or undefined');\n\t}\n\n\treturn Object(val);\n}\n\nfunction shouldUseNative() {\n\ttry {\n\t\tif (!Object.assign) {\n\t\t\treturn false;\n\t\t}\n\n\t\t// Detect buggy property enumeration order in older V8 versions.\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=4118\n\t\tvar test1 = new String('abc'); // eslint-disable-line no-new-wrappers\n\t\ttest1[5] = 'de';\n\t\tif (Object.getOwnPropertyNames(test1)[0] === '5') {\n\t\t\treturn false;\n\t\t}\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=3056\n\t\tvar test2 = {};\n\t\tfor (var i = 0; i < 10; i++) {\n\t\t\ttest2['_' + String.fromCharCode(i)] = i;\n\t\t}\n\t\tvar order2 = Object.getOwnPropertyNames(test2).map(function (n) {\n\t\t\treturn test2[n];\n\t\t});\n\t\tif (order2.join('') !== '0123456789') {\n\t\t\treturn false;\n\t\t}\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=3056\n\t\tvar test3 = {};\n\t\t'abcdefghijklmnopqrst'.split('').forEach(function (letter) {\n\t\t\ttest3[letter] = letter;\n\t\t});\n\t\tif (Object.keys(Object.assign({}, test3)).join('') !==\n\t\t\t\t'abcdefghijklmnopqrst') {\n\t\t\treturn false;\n\t\t}\n\n\t\treturn true;\n\t} catch (err) {\n\t\t// We don't expect any of the above to throw, but better to be safe.\n\t\treturn false;\n\t}\n}\n\nmodule.exports = shouldUseNative() ? Object.assign : function (target, source) {\n\tvar from;\n\tvar to = toObject(target);\n\tvar symbols;\n\n\tfor (var s = 1; s < arguments.length; s++) {\n\t\tfrom = Object(arguments[s]);\n\n\t\tfor (var key in from) {\n\t\t\tif (hasOwnProperty.call(from, key)) {\n\t\t\t\tto[key] = from[key];\n\t\t\t}\n\t\t}\n\n\t\tif (getOwnPropertySymbols) {\n\t\t\tsymbols = getOwnPropertySymbols(from);\n\t\t\tfor (var i = 0; i < symbols.length; i++) {\n\t\t\t\tif (propIsEnumerable.call(from, symbols[i])) {\n\t\t\t\t\tto[symbols[i]] = from[symbols[i]];\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\n\treturn to;\n};\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar ReactPropTypesSecret = 'SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED';\n\nmodule.exports = ReactPropTypesSecret;\n","module.exports = Function.call.bind(Object.prototype.hasOwnProperty);\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar printWarning = function() {};\n\nif (process.env.NODE_ENV !== 'production') {\n var ReactPropTypesSecret = require('./lib/ReactPropTypesSecret');\n var loggedTypeFailures = {};\n var has = require('./lib/has');\n\n printWarning = function(text) {\n var message = 'Warning: ' + text;\n if (typeof console !== 'undefined') {\n console.error(message);\n }\n try {\n // --- Welcome to debugging React ---\n // This error was thrown as a convenience so that you can use this stack\n // to find the callsite that caused this warning to fire.\n throw new Error(message);\n } catch (x) { /**/ }\n };\n}\n\n/**\n * Assert that the values match with the type specs.\n * Error messages are memorized and will only be shown once.\n *\n * @param {object} typeSpecs Map of name to a ReactPropType\n * @param {object} values Runtime values that need to be type-checked\n * @param {string} location e.g. \"prop\", \"context\", \"child context\"\n * @param {string} componentName Name of the component for error messages.\n * @param {?Function} getStack Returns the component stack.\n * @private\n */\nfunction checkPropTypes(typeSpecs, values, location, componentName, getStack) {\n if (process.env.NODE_ENV !== 'production') {\n for (var typeSpecName in typeSpecs) {\n if (has(typeSpecs, typeSpecName)) {\n var error;\n // Prop type validation may throw. In case they do, we don't want to\n // fail the render phase where it didn't fail before. So we log it.\n // After these have been cleaned up, we'll let them throw.\n try {\n // This is intentionally an invariant that gets caught. It's the same\n // behavior as without this statement except with a better message.\n if (typeof typeSpecs[typeSpecName] !== 'function') {\n var err = Error(\n (componentName || 'React class') + ': ' + location + ' type `' + typeSpecName + '` is invalid; ' +\n 'it must be a function, usually from the `prop-types` package, but received `' + typeof typeSpecs[typeSpecName] + '`.' +\n 'This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.'\n );\n err.name = 'Invariant Violation';\n throw err;\n }\n error = typeSpecs[typeSpecName](values, typeSpecName, componentName, location, null, ReactPropTypesSecret);\n } catch (ex) {\n error = ex;\n }\n if (error && !(error instanceof Error)) {\n printWarning(\n (componentName || 'React class') + ': type specification of ' +\n location + ' `' + typeSpecName + '` is invalid; the type checker ' +\n 'function must return `null` or an `Error` but returned a ' + typeof error + '. ' +\n 'You may have forgotten to pass an argument to the type checker ' +\n 'creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and ' +\n 'shape all require an argument).'\n );\n }\n if (error instanceof Error && !(error.message in loggedTypeFailures)) {\n // Only monitor this failure once because there tends to be a lot of the\n // same error.\n loggedTypeFailures[error.message] = true;\n\n var stack = getStack ? getStack() : '';\n\n printWarning(\n 'Failed ' + location + ' type: ' + error.message + (stack != null ? stack : '')\n );\n }\n }\n }\n }\n}\n\n/**\n * Resets warning cache when testing.\n *\n * @private\n */\ncheckPropTypes.resetWarningCache = function() {\n if (process.env.NODE_ENV !== 'production') {\n loggedTypeFailures = {};\n }\n}\n\nmodule.exports = checkPropTypes;\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar ReactIs = require('react-is');\nvar assign = require('object-assign');\n\nvar ReactPropTypesSecret = require('./lib/ReactPropTypesSecret');\nvar has = require('./lib/has');\nvar checkPropTypes = require('./checkPropTypes');\n\nvar printWarning = function() {};\n\nif (process.env.NODE_ENV !== 'production') {\n printWarning = function(text) {\n var message = 'Warning: ' + text;\n if (typeof console !== 'undefined') {\n console.error(message);\n }\n try {\n // --- Welcome to debugging React ---\n // This error was thrown as a convenience so that you can use this stack\n // to find the callsite that caused this warning to fire.\n throw new Error(message);\n } catch (x) {}\n };\n}\n\nfunction emptyFunctionThatReturnsNull() {\n return null;\n}\n\nmodule.exports = function(isValidElement, throwOnDirectAccess) {\n /* global Symbol */\n var ITERATOR_SYMBOL = typeof Symbol === 'function' && Symbol.iterator;\n var FAUX_ITERATOR_SYMBOL = '@@iterator'; // Before Symbol spec.\n\n /**\n * Returns the iterator method function contained on the iterable object.\n *\n * Be sure to invoke the function with the iterable as context:\n *\n * var iteratorFn = getIteratorFn(myIterable);\n * if (iteratorFn) {\n * var iterator = iteratorFn.call(myIterable);\n * ...\n * }\n *\n * @param {?object} maybeIterable\n * @return {?function}\n */\n function getIteratorFn(maybeIterable) {\n var iteratorFn = maybeIterable && (ITERATOR_SYMBOL && maybeIterable[ITERATOR_SYMBOL] || maybeIterable[FAUX_ITERATOR_SYMBOL]);\n if (typeof iteratorFn === 'function') {\n return iteratorFn;\n }\n }\n\n /**\n * Collection of methods that allow declaration and validation of props that are\n * supplied to React components. Example usage:\n *\n * var Props = require('ReactPropTypes');\n * var MyArticle = React.createClass({\n * propTypes: {\n * // An optional string prop named \"description\".\n * description: Props.string,\n *\n * // A required enum prop named \"category\".\n * category: Props.oneOf(['News','Photos']).isRequired,\n *\n * // A prop named \"dialog\" that requires an instance of Dialog.\n * dialog: Props.instanceOf(Dialog).isRequired\n * },\n * render: function() { ... }\n * });\n *\n * A more formal specification of how these methods are used:\n *\n * type := array|bool|func|object|number|string|oneOf([...])|instanceOf(...)\n * decl := ReactPropTypes.{type}(.isRequired)?\n *\n * Each and every declaration produces a function with the same signature. This\n * allows the creation of custom validation functions. For example:\n *\n * var MyLink = React.createClass({\n * propTypes: {\n * // An optional string or URI prop named \"href\".\n * href: function(props, propName, componentName) {\n * var propValue = props[propName];\n * if (propValue != null && typeof propValue !== 'string' &&\n * !(propValue instanceof URI)) {\n * return new Error(\n * 'Expected a string or an URI for ' + propName + ' in ' +\n * componentName\n * );\n * }\n * }\n * },\n * render: function() {...}\n * });\n *\n * @internal\n */\n\n var ANONYMOUS = '<>';\n\n // Important!\n // Keep this list in sync with production version in `./factoryWithThrowingShims.js`.\n var ReactPropTypes = {\n array: createPrimitiveTypeChecker('array'),\n bigint: createPrimitiveTypeChecker('bigint'),\n bool: createPrimitiveTypeChecker('boolean'),\n func: createPrimitiveTypeChecker('function'),\n number: createPrimitiveTypeChecker('number'),\n object: createPrimitiveTypeChecker('object'),\n string: createPrimitiveTypeChecker('string'),\n symbol: createPrimitiveTypeChecker('symbol'),\n\n any: createAnyTypeChecker(),\n arrayOf: createArrayOfTypeChecker,\n element: createElementTypeChecker(),\n elementType: createElementTypeTypeChecker(),\n instanceOf: createInstanceTypeChecker,\n node: createNodeChecker(),\n objectOf: createObjectOfTypeChecker,\n oneOf: createEnumTypeChecker,\n oneOfType: createUnionTypeChecker,\n shape: createShapeTypeChecker,\n exact: createStrictShapeTypeChecker,\n };\n\n /**\n * inlined Object.is polyfill to avoid requiring consumers ship their own\n * https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object/is\n */\n /*eslint-disable no-self-compare*/\n function is(x, y) {\n // SameValue algorithm\n if (x === y) {\n // Steps 1-5, 7-10\n // Steps 6.b-6.e: +0 != -0\n return x !== 0 || 1 / x === 1 / y;\n } else {\n // Step 6.a: NaN == NaN\n return x !== x && y !== y;\n }\n }\n /*eslint-enable no-self-compare*/\n\n /**\n * We use an Error-like object for backward compatibility as people may call\n * PropTypes directly and inspect their output. However, we don't use real\n * Errors anymore. We don't inspect their stack anyway, and creating them\n * is prohibitively expensive if they are created too often, such as what\n * happens in oneOfType() for any type before the one that matched.\n */\n function PropTypeError(message, data) {\n this.message = message;\n this.data = data && typeof data === 'object' ? data: {};\n this.stack = '';\n }\n // Make `instanceof Error` still work for returned errors.\n PropTypeError.prototype = Error.prototype;\n\n function createChainableTypeChecker(validate) {\n if (process.env.NODE_ENV !== 'production') {\n var manualPropTypeCallCache = {};\n var manualPropTypeWarningCount = 0;\n }\n function checkType(isRequired, props, propName, componentName, location, propFullName, secret) {\n componentName = componentName || ANONYMOUS;\n propFullName = propFullName || propName;\n\n if (secret !== ReactPropTypesSecret) {\n if (throwOnDirectAccess) {\n // New behavior only for users of `prop-types` package\n var err = new Error(\n 'Calling PropTypes validators directly is not supported by the `prop-types` package. ' +\n 'Use `PropTypes.checkPropTypes()` to call them. ' +\n 'Read more at http://fb.me/use-check-prop-types'\n );\n err.name = 'Invariant Violation';\n throw err;\n } else if (process.env.NODE_ENV !== 'production' && typeof console !== 'undefined') {\n // Old behavior for people using React.PropTypes\n var cacheKey = componentName + ':' + propName;\n if (\n !manualPropTypeCallCache[cacheKey] &&\n // Avoid spamming the console because they are often not actionable except for lib authors\n manualPropTypeWarningCount < 3\n ) {\n printWarning(\n 'You are manually calling a React.PropTypes validation ' +\n 'function for the `' + propFullName + '` prop on `' + componentName + '`. This is deprecated ' +\n 'and will throw in the standalone `prop-types` package. ' +\n 'You may be seeing this warning due to a third-party PropTypes ' +\n 'library. See https://fb.me/react-warning-dont-call-proptypes ' + 'for details.'\n );\n manualPropTypeCallCache[cacheKey] = true;\n manualPropTypeWarningCount++;\n }\n }\n }\n if (props[propName] == null) {\n if (isRequired) {\n if (props[propName] === null) {\n return new PropTypeError('The ' + location + ' `' + propFullName + '` is marked as required ' + ('in `' + componentName + '`, but its value is `null`.'));\n }\n return new PropTypeError('The ' + location + ' `' + propFullName + '` is marked as required in ' + ('`' + componentName + '`, but its value is `undefined`.'));\n }\n return null;\n } else {\n return validate(props, propName, componentName, location, propFullName);\n }\n }\n\n var chainedCheckType = checkType.bind(null, false);\n chainedCheckType.isRequired = checkType.bind(null, true);\n\n return chainedCheckType;\n }\n\n function createPrimitiveTypeChecker(expectedType) {\n function validate(props, propName, componentName, location, propFullName, secret) {\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== expectedType) {\n // `propValue` being instance of, say, date/regexp, pass the 'object'\n // check, but we can offer a more precise error message here rather than\n // 'of type `object`'.\n var preciseType = getPreciseType(propValue);\n\n return new PropTypeError(\n 'Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + preciseType + '` supplied to `' + componentName + '`, expected ') + ('`' + expectedType + '`.'),\n {expectedType: expectedType}\n );\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createAnyTypeChecker() {\n return createChainableTypeChecker(emptyFunctionThatReturnsNull);\n }\n\n function createArrayOfTypeChecker(typeChecker) {\n function validate(props, propName, componentName, location, propFullName) {\n if (typeof typeChecker !== 'function') {\n return new PropTypeError('Property `' + propFullName + '` of component `' + componentName + '` has invalid PropType notation inside arrayOf.');\n }\n var propValue = props[propName];\n if (!Array.isArray(propValue)) {\n var propType = getPropType(propValue);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected an array.'));\n }\n for (var i = 0; i < propValue.length; i++) {\n var error = typeChecker(propValue, i, componentName, location, propFullName + '[' + i + ']', ReactPropTypesSecret);\n if (error instanceof Error) {\n return error;\n }\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createElementTypeChecker() {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n if (!isValidElement(propValue)) {\n var propType = getPropType(propValue);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected a single ReactElement.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createElementTypeTypeChecker() {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n if (!ReactIs.isValidElementType(propValue)) {\n var propType = getPropType(propValue);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected a single ReactElement type.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createInstanceTypeChecker(expectedClass) {\n function validate(props, propName, componentName, location, propFullName) {\n if (!(props[propName] instanceof expectedClass)) {\n var expectedClassName = expectedClass.name || ANONYMOUS;\n var actualClassName = getClassName(props[propName]);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + actualClassName + '` supplied to `' + componentName + '`, expected ') + ('instance of `' + expectedClassName + '`.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createEnumTypeChecker(expectedValues) {\n if (!Array.isArray(expectedValues)) {\n if (process.env.NODE_ENV !== 'production') {\n if (arguments.length > 1) {\n printWarning(\n 'Invalid arguments supplied to oneOf, expected an array, got ' + arguments.length + ' arguments. ' +\n 'A common mistake is to write oneOf(x, y, z) instead of oneOf([x, y, z]).'\n );\n } else {\n printWarning('Invalid argument supplied to oneOf, expected an array.');\n }\n }\n return emptyFunctionThatReturnsNull;\n }\n\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n for (var i = 0; i < expectedValues.length; i++) {\n if (is(propValue, expectedValues[i])) {\n return null;\n }\n }\n\n var valuesString = JSON.stringify(expectedValues, function replacer(key, value) {\n var type = getPreciseType(value);\n if (type === 'symbol') {\n return String(value);\n }\n return value;\n });\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of value `' + String(propValue) + '` ' + ('supplied to `' + componentName + '`, expected one of ' + valuesString + '.'));\n }\n return createChainableTypeChecker(validate);\n }\n\n function createObjectOfTypeChecker(typeChecker) {\n function validate(props, propName, componentName, location, propFullName) {\n if (typeof typeChecker !== 'function') {\n return new PropTypeError('Property `' + propFullName + '` of component `' + componentName + '` has invalid PropType notation inside objectOf.');\n }\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== 'object') {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected an object.'));\n }\n for (var key in propValue) {\n if (has(propValue, key)) {\n var error = typeChecker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret);\n if (error instanceof Error) {\n return error;\n }\n }\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createUnionTypeChecker(arrayOfTypeCheckers) {\n if (!Array.isArray(arrayOfTypeCheckers)) {\n process.env.NODE_ENV !== 'production' ? printWarning('Invalid argument supplied to oneOfType, expected an instance of array.') : void 0;\n return emptyFunctionThatReturnsNull;\n }\n\n for (var i = 0; i < arrayOfTypeCheckers.length; i++) {\n var checker = arrayOfTypeCheckers[i];\n if (typeof checker !== 'function') {\n printWarning(\n 'Invalid argument supplied to oneOfType. Expected an array of check functions, but ' +\n 'received ' + getPostfixForTypeWarning(checker) + ' at index ' + i + '.'\n );\n return emptyFunctionThatReturnsNull;\n }\n }\n\n function validate(props, propName, componentName, location, propFullName) {\n var expectedTypes = [];\n for (var i = 0; i < arrayOfTypeCheckers.length; i++) {\n var checker = arrayOfTypeCheckers[i];\n var checkerResult = checker(props, propName, componentName, location, propFullName, ReactPropTypesSecret);\n if (checkerResult == null) {\n return null;\n }\n if (checkerResult.data && has(checkerResult.data, 'expectedType')) {\n expectedTypes.push(checkerResult.data.expectedType);\n }\n }\n var expectedTypesMessage = (expectedTypes.length > 0) ? ', expected one of type [' + expectedTypes.join(', ') + ']': '';\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` supplied to ' + ('`' + componentName + '`' + expectedTypesMessage + '.'));\n }\n return createChainableTypeChecker(validate);\n }\n\n function createNodeChecker() {\n function validate(props, propName, componentName, location, propFullName) {\n if (!isNode(props[propName])) {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` supplied to ' + ('`' + componentName + '`, expected a ReactNode.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function invalidValidatorError(componentName, location, propFullName, key, type) {\n return new PropTypeError(\n (componentName || 'React class') + ': ' + location + ' type `' + propFullName + '.' + key + '` is invalid; ' +\n 'it must be a function, usually from the `prop-types` package, but received `' + type + '`.'\n );\n }\n\n function createShapeTypeChecker(shapeTypes) {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== 'object') {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type `' + propType + '` ' + ('supplied to `' + componentName + '`, expected `object`.'));\n }\n for (var key in shapeTypes) {\n var checker = shapeTypes[key];\n if (typeof checker !== 'function') {\n return invalidValidatorError(componentName, location, propFullName, key, getPreciseType(checker));\n }\n var error = checker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret);\n if (error) {\n return error;\n }\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createStrictShapeTypeChecker(shapeTypes) {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== 'object') {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type `' + propType + '` ' + ('supplied to `' + componentName + '`, expected `object`.'));\n }\n // We need to check all keys in case some are required but missing from props.\n var allKeys = assign({}, props[propName], shapeTypes);\n for (var key in allKeys) {\n var checker = shapeTypes[key];\n if (has(shapeTypes, key) && typeof checker !== 'function') {\n return invalidValidatorError(componentName, location, propFullName, key, getPreciseType(checker));\n }\n if (!checker) {\n return new PropTypeError(\n 'Invalid ' + location + ' `' + propFullName + '` key `' + key + '` supplied to `' + componentName + '`.' +\n '\\nBad object: ' + JSON.stringify(props[propName], null, ' ') +\n '\\nValid keys: ' + JSON.stringify(Object.keys(shapeTypes), null, ' ')\n );\n }\n var error = checker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret);\n if (error) {\n return error;\n }\n }\n return null;\n }\n\n return createChainableTypeChecker(validate);\n }\n\n function isNode(propValue) {\n switch (typeof propValue) {\n case 'number':\n case 'string':\n case 'undefined':\n return true;\n case 'boolean':\n return !propValue;\n case 'object':\n if (Array.isArray(propValue)) {\n return propValue.every(isNode);\n }\n if (propValue === null || isValidElement(propValue)) {\n return true;\n }\n\n var iteratorFn = getIteratorFn(propValue);\n if (iteratorFn) {\n var iterator = iteratorFn.call(propValue);\n var step;\n if (iteratorFn !== propValue.entries) {\n while (!(step = iterator.next()).done) {\n if (!isNode(step.value)) {\n return false;\n }\n }\n } else {\n // Iterator will provide entry [k,v] tuples rather than values.\n while (!(step = iterator.next()).done) {\n var entry = step.value;\n if (entry) {\n if (!isNode(entry[1])) {\n return false;\n }\n }\n }\n }\n } else {\n return false;\n }\n\n return true;\n default:\n return false;\n }\n }\n\n function isSymbol(propType, propValue) {\n // Native Symbol.\n if (propType === 'symbol') {\n return true;\n }\n\n // falsy value can't be a Symbol\n if (!propValue) {\n return false;\n }\n\n // 19.4.3.5 Symbol.prototype[@@toStringTag] === 'Symbol'\n if (propValue['@@toStringTag'] === 'Symbol') {\n return true;\n }\n\n // Fallback for non-spec compliant Symbols which are polyfilled.\n if (typeof Symbol === 'function' && propValue instanceof Symbol) {\n return true;\n }\n\n return false;\n }\n\n // Equivalent of `typeof` but with special handling for array and regexp.\n function getPropType(propValue) {\n var propType = typeof propValue;\n if (Array.isArray(propValue)) {\n return 'array';\n }\n if (propValue instanceof RegExp) {\n // Old webkits (at least until Android 4.0) return 'function' rather than\n // 'object' for typeof a RegExp. We'll normalize this here so that /bla/\n // passes PropTypes.object.\n return 'object';\n }\n if (isSymbol(propType, propValue)) {\n return 'symbol';\n }\n return propType;\n }\n\n // This handles more types than `getPropType`. Only used for error messages.\n // See `createPrimitiveTypeChecker`.\n function getPreciseType(propValue) {\n if (typeof propValue === 'undefined' || propValue === null) {\n return '' + propValue;\n }\n var propType = getPropType(propValue);\n if (propType === 'object') {\n if (propValue instanceof Date) {\n return 'date';\n } else if (propValue instanceof RegExp) {\n return 'regexp';\n }\n }\n return propType;\n }\n\n // Returns a string that is postfixed to a warning about an invalid type.\n // For example, \"undefined\" or \"of type array\"\n function getPostfixForTypeWarning(value) {\n var type = getPreciseType(value);\n switch (type) {\n case 'array':\n case 'object':\n return 'an ' + type;\n case 'boolean':\n case 'date':\n case 'regexp':\n return 'a ' + type;\n default:\n return type;\n }\n }\n\n // Returns class name of the object, if any.\n function getClassName(propValue) {\n if (!propValue.constructor || !propValue.constructor.name) {\n return ANONYMOUS;\n }\n return propValue.constructor.name;\n }\n\n ReactPropTypes.checkPropTypes = checkPropTypes;\n ReactPropTypes.resetWarningCache = checkPropTypes.resetWarningCache;\n ReactPropTypes.PropTypes = ReactPropTypes;\n\n return ReactPropTypes;\n};\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar ReactPropTypesSecret = require('./lib/ReactPropTypesSecret');\n\nfunction emptyFunction() {}\nfunction emptyFunctionWithReset() {}\nemptyFunctionWithReset.resetWarningCache = emptyFunction;\n\nmodule.exports = function() {\n function shim(props, propName, componentName, location, propFullName, secret) {\n if (secret === ReactPropTypesSecret) {\n // It is still safe when called from React.\n return;\n }\n var err = new Error(\n 'Calling PropTypes validators directly is not supported by the `prop-types` package. ' +\n 'Use PropTypes.checkPropTypes() to call them. ' +\n 'Read more at http://fb.me/use-check-prop-types'\n );\n err.name = 'Invariant Violation';\n throw err;\n };\n shim.isRequired = shim;\n function getShim() {\n return shim;\n };\n // Important!\n // Keep this list in sync with production version in `./factoryWithTypeCheckers.js`.\n var ReactPropTypes = {\n array: shim,\n bigint: shim,\n bool: shim,\n func: shim,\n number: shim,\n object: shim,\n string: shim,\n symbol: shim,\n\n any: shim,\n arrayOf: getShim,\n element: shim,\n elementType: shim,\n instanceOf: getShim,\n node: shim,\n objectOf: getShim,\n oneOf: getShim,\n oneOfType: getShim,\n shape: getShim,\n exact: getShim,\n\n checkPropTypes: emptyFunctionWithReset,\n resetWarningCache: emptyFunction\n };\n\n ReactPropTypes.PropTypes = ReactPropTypes;\n\n return ReactPropTypes;\n};\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\nif (process.env.NODE_ENV !== 'production') {\n var ReactIs = require('react-is');\n\n // By explicitly using `prop-types` you are opting into new development behavior.\n // http://fb.me/prop-types-in-prod\n var throwOnDirectAccess = true;\n module.exports = require('./factoryWithTypeCheckers')(ReactIs.isElement, throwOnDirectAccess);\n} else {\n // By explicitly using `prop-types` you are opting into new production behavior.\n // http://fb.me/prop-types-in-prod\n module.exports = require('./factoryWithThrowingShims')();\n}\n","import PropTypes from 'prop-types';\nimport chainPropTypes from '../chainPropTypes';\nfunction isClassComponent(elementType) {\n // elementType.prototype?.isReactComponent\n const {\n prototype = {}\n } = elementType;\n return Boolean(prototype.isReactComponent);\n}\nfunction acceptingRef(props, propName, componentName, location, propFullName) {\n const element = props[propName];\n const safePropName = propFullName || propName;\n if (element == null ||\n // When server-side rendering React doesn't warn either.\n // This is not an accurate check for SSR.\n // This is only in place for Emotion compat.\n // TODO: Revisit once https://github.com/facebook/react/issues/20047 is resolved.\n typeof window === 'undefined') {\n return null;\n }\n let warningHint;\n const elementType = element.type;\n /**\n * Blacklisting instead of whitelisting\n *\n * Blacklisting will miss some components, such as React.Fragment. Those will at least\n * trigger a warning in React.\n * We can't whitelist because there is no safe way to detect React.forwardRef\n * or class components. \"Safe\" means there's no public API.\n *\n */\n if (typeof elementType === 'function' && !isClassComponent(elementType)) {\n warningHint = 'Did you accidentally use a plain function component for an element instead?';\n }\n if (warningHint !== undefined) {\n return new Error(`Invalid ${location} \\`${safePropName}\\` supplied to \\`${componentName}\\`. ` + `Expected an element that can hold a ref. ${warningHint} ` + 'For more information see https://mui.com/r/caveat-with-refs-guide');\n }\n return null;\n}\nconst elementAcceptingRef = chainPropTypes(PropTypes.element, acceptingRef);\nelementAcceptingRef.isRequired = chainPropTypes(PropTypes.element.isRequired, acceptingRef);\nexport default elementAcceptingRef;","import _extends from \"@babel/runtime/helpers/esm/extends\";\n// This module is based on https://github.com/airbnb/prop-types-exact repository.\n// However, in order to reduce the number of dependencies and to remove some extra safe checks\n// the module was forked.\n\nconst specialProperty = 'exact-prop: \\u200b';\nexport default function exactProp(propTypes) {\n if (process.env.NODE_ENV === 'production') {\n return propTypes;\n }\n return _extends({}, propTypes, {\n [specialProperty]: props => {\n const unsupportedProps = Object.keys(props).filter(prop => !propTypes.hasOwnProperty(prop));\n if (unsupportedProps.length > 0) {\n return new Error(`The following props are not supported: ${unsupportedProps.map(prop => `\\`${prop}\\``).join(', ')}. Please remove them.`);\n }\n return null;\n }\n });\n}","/**\n * WARNING: Don't import this directly.\n * Use `MuiError` from `@mui/internal-babel-macros/MuiError.macro` instead.\n * @param {number} code\n */\nexport default function formatMuiErrorMessage(code) {\n // Apply babel-plugin-transform-template-literals in loose mode\n // loose mode is safe if we're concatenating primitives\n // see https://babeljs.io/docs/en/babel-plugin-transform-template-literals#loose\n /* eslint-disable prefer-template */\n let url = 'https://mui.com/production-error/?code=' + code;\n for (let i = 1; i < arguments.length; i += 1) {\n // rest params over-transpile for this case\n // eslint-disable-next-line prefer-rest-params\n url += '&args[]=' + encodeURIComponent(arguments[i]);\n }\n return 'Minified MUI error #' + code + '; visit ' + url + ' for the full message.';\n /* eslint-enable prefer-template */\n}","/**\n * @license React\n * react-is.production.min.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n'use strict';var b=Symbol.for(\"react.element\"),c=Symbol.for(\"react.portal\"),d=Symbol.for(\"react.fragment\"),e=Symbol.for(\"react.strict_mode\"),f=Symbol.for(\"react.profiler\"),g=Symbol.for(\"react.provider\"),h=Symbol.for(\"react.context\"),k=Symbol.for(\"react.server_context\"),l=Symbol.for(\"react.forward_ref\"),m=Symbol.for(\"react.suspense\"),n=Symbol.for(\"react.suspense_list\"),p=Symbol.for(\"react.memo\"),q=Symbol.for(\"react.lazy\"),t=Symbol.for(\"react.offscreen\"),u;u=Symbol.for(\"react.module.reference\");\nfunction v(a){if(\"object\"===typeof a&&null!==a){var r=a.$$typeof;switch(r){case b:switch(a=a.type,a){case d:case f:case e:case m:case n:return a;default:switch(a=a&&a.$$typeof,a){case k:case h:case l:case q:case p:case g:return a;default:return r}}case c:return r}}}exports.ContextConsumer=h;exports.ContextProvider=g;exports.Element=b;exports.ForwardRef=l;exports.Fragment=d;exports.Lazy=q;exports.Memo=p;exports.Portal=c;exports.Profiler=f;exports.StrictMode=e;exports.Suspense=m;\nexports.SuspenseList=n;exports.isAsyncMode=function(){return!1};exports.isConcurrentMode=function(){return!1};exports.isContextConsumer=function(a){return v(a)===h};exports.isContextProvider=function(a){return v(a)===g};exports.isElement=function(a){return\"object\"===typeof a&&null!==a&&a.$$typeof===b};exports.isForwardRef=function(a){return v(a)===l};exports.isFragment=function(a){return v(a)===d};exports.isLazy=function(a){return v(a)===q};exports.isMemo=function(a){return v(a)===p};\nexports.isPortal=function(a){return v(a)===c};exports.isProfiler=function(a){return v(a)===f};exports.isStrictMode=function(a){return v(a)===e};exports.isSuspense=function(a){return v(a)===m};exports.isSuspenseList=function(a){return v(a)===n};\nexports.isValidElementType=function(a){return\"string\"===typeof a||\"function\"===typeof a||a===d||a===f||a===e||a===m||a===n||a===t||\"object\"===typeof a&&null!==a&&(a.$$typeof===q||a.$$typeof===p||a.$$typeof===g||a.$$typeof===h||a.$$typeof===l||a.$$typeof===u||void 0!==a.getModuleId)?!0:!1};exports.typeOf=v;\n","/**\n * @license React\n * react-is.development.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nif (process.env.NODE_ENV !== \"production\") {\n (function() {\n'use strict';\n\n// ATTENTION\n// When adding new symbols to this file,\n// Please consider also adding to 'react-devtools-shared/src/backend/ReactSymbols'\n// The Symbol used to tag the ReactElement-like types.\nvar REACT_ELEMENT_TYPE = Symbol.for('react.element');\nvar REACT_PORTAL_TYPE = Symbol.for('react.portal');\nvar REACT_FRAGMENT_TYPE = Symbol.for('react.fragment');\nvar REACT_STRICT_MODE_TYPE = Symbol.for('react.strict_mode');\nvar REACT_PROFILER_TYPE = Symbol.for('react.profiler');\nvar REACT_PROVIDER_TYPE = Symbol.for('react.provider');\nvar REACT_CONTEXT_TYPE = Symbol.for('react.context');\nvar REACT_SERVER_CONTEXT_TYPE = Symbol.for('react.server_context');\nvar REACT_FORWARD_REF_TYPE = Symbol.for('react.forward_ref');\nvar REACT_SUSPENSE_TYPE = Symbol.for('react.suspense');\nvar REACT_SUSPENSE_LIST_TYPE = Symbol.for('react.suspense_list');\nvar REACT_MEMO_TYPE = Symbol.for('react.memo');\nvar REACT_LAZY_TYPE = Symbol.for('react.lazy');\nvar REACT_OFFSCREEN_TYPE = Symbol.for('react.offscreen');\n\n// -----------------------------------------------------------------------------\n\nvar enableScopeAPI = false; // Experimental Create Event Handle API.\nvar enableCacheElement = false;\nvar enableTransitionTracing = false; // No known bugs, but needs performance testing\n\nvar enableLegacyHidden = false; // Enables unstable_avoidThisFallback feature in Fiber\n// stuff. Intended to enable React core members to more easily debug scheduling\n// issues in DEV builds.\n\nvar enableDebugTracing = false; // Track which Fiber(s) schedule render work.\n\nvar REACT_MODULE_REFERENCE;\n\n{\n REACT_MODULE_REFERENCE = Symbol.for('react.module.reference');\n}\n\nfunction isValidElementType(type) {\n if (typeof type === 'string' || typeof type === 'function') {\n return true;\n } // Note: typeof might be other than 'symbol' or 'number' (e.g. if it's a polyfill).\n\n\n if (type === REACT_FRAGMENT_TYPE || type === REACT_PROFILER_TYPE || enableDebugTracing || type === REACT_STRICT_MODE_TYPE || type === REACT_SUSPENSE_TYPE || type === REACT_SUSPENSE_LIST_TYPE || enableLegacyHidden || type === REACT_OFFSCREEN_TYPE || enableScopeAPI || enableCacheElement || enableTransitionTracing ) {\n return true;\n }\n\n if (typeof type === 'object' && type !== null) {\n if (type.$$typeof === REACT_LAZY_TYPE || type.$$typeof === REACT_MEMO_TYPE || type.$$typeof === REACT_PROVIDER_TYPE || type.$$typeof === REACT_CONTEXT_TYPE || type.$$typeof === REACT_FORWARD_REF_TYPE || // This needs to include all possible module reference object\n // types supported by any Flight configuration anywhere since\n // we don't know which Flight build this will end up being used\n // with.\n type.$$typeof === REACT_MODULE_REFERENCE || type.getModuleId !== undefined) {\n return true;\n }\n }\n\n return false;\n}\n\nfunction typeOf(object) {\n if (typeof object === 'object' && object !== null) {\n var $$typeof = object.$$typeof;\n\n switch ($$typeof) {\n case REACT_ELEMENT_TYPE:\n var type = object.type;\n\n switch (type) {\n case REACT_FRAGMENT_TYPE:\n case REACT_PROFILER_TYPE:\n case REACT_STRICT_MODE_TYPE:\n case REACT_SUSPENSE_TYPE:\n case REACT_SUSPENSE_LIST_TYPE:\n return type;\n\n default:\n var $$typeofType = type && type.$$typeof;\n\n switch ($$typeofType) {\n case REACT_SERVER_CONTEXT_TYPE:\n case REACT_CONTEXT_TYPE:\n case REACT_FORWARD_REF_TYPE:\n case REACT_LAZY_TYPE:\n case REACT_MEMO_TYPE:\n case REACT_PROVIDER_TYPE:\n return $$typeofType;\n\n default:\n return $$typeof;\n }\n\n }\n\n case REACT_PORTAL_TYPE:\n return $$typeof;\n }\n }\n\n return undefined;\n}\nvar ContextConsumer = REACT_CONTEXT_TYPE;\nvar ContextProvider = REACT_PROVIDER_TYPE;\nvar Element = REACT_ELEMENT_TYPE;\nvar ForwardRef = REACT_FORWARD_REF_TYPE;\nvar Fragment = REACT_FRAGMENT_TYPE;\nvar Lazy = REACT_LAZY_TYPE;\nvar Memo = REACT_MEMO_TYPE;\nvar Portal = REACT_PORTAL_TYPE;\nvar Profiler = REACT_PROFILER_TYPE;\nvar StrictMode = REACT_STRICT_MODE_TYPE;\nvar Suspense = REACT_SUSPENSE_TYPE;\nvar SuspenseList = REACT_SUSPENSE_LIST_TYPE;\nvar hasWarnedAboutDeprecatedIsAsyncMode = false;\nvar hasWarnedAboutDeprecatedIsConcurrentMode = false; // AsyncMode should be deprecated\n\nfunction isAsyncMode(object) {\n {\n if (!hasWarnedAboutDeprecatedIsAsyncMode) {\n hasWarnedAboutDeprecatedIsAsyncMode = true; // Using console['warn'] to evade Babel and ESLint\n\n console['warn']('The ReactIs.isAsyncMode() alias has been deprecated, ' + 'and will be removed in React 18+.');\n }\n }\n\n return false;\n}\nfunction isConcurrentMode(object) {\n {\n if (!hasWarnedAboutDeprecatedIsConcurrentMode) {\n hasWarnedAboutDeprecatedIsConcurrentMode = true; // Using console['warn'] to evade Babel and ESLint\n\n console['warn']('The ReactIs.isConcurrentMode() alias has been deprecated, ' + 'and will be removed in React 18+.');\n }\n }\n\n return false;\n}\nfunction isContextConsumer(object) {\n return typeOf(object) === REACT_CONTEXT_TYPE;\n}\nfunction isContextProvider(object) {\n return typeOf(object) === REACT_PROVIDER_TYPE;\n}\nfunction isElement(object) {\n return typeof object === 'object' && object !== null && object.$$typeof === REACT_ELEMENT_TYPE;\n}\nfunction isForwardRef(object) {\n return typeOf(object) === REACT_FORWARD_REF_TYPE;\n}\nfunction isFragment(object) {\n return typeOf(object) === REACT_FRAGMENT_TYPE;\n}\nfunction isLazy(object) {\n return typeOf(object) === REACT_LAZY_TYPE;\n}\nfunction isMemo(object) {\n return typeOf(object) === REACT_MEMO_TYPE;\n}\nfunction isPortal(object) {\n return typeOf(object) === REACT_PORTAL_TYPE;\n}\nfunction isProfiler(object) {\n return typeOf(object) === REACT_PROFILER_TYPE;\n}\nfunction isStrictMode(object) {\n return typeOf(object) === REACT_STRICT_MODE_TYPE;\n}\nfunction isSuspense(object) {\n return typeOf(object) === REACT_SUSPENSE_TYPE;\n}\nfunction isSuspenseList(object) {\n return typeOf(object) === REACT_SUSPENSE_LIST_TYPE;\n}\n\nexports.ContextConsumer = ContextConsumer;\nexports.ContextProvider = ContextProvider;\nexports.Element = Element;\nexports.ForwardRef = ForwardRef;\nexports.Fragment = Fragment;\nexports.Lazy = Lazy;\nexports.Memo = Memo;\nexports.Portal = Portal;\nexports.Profiler = Profiler;\nexports.StrictMode = StrictMode;\nexports.Suspense = Suspense;\nexports.SuspenseList = SuspenseList;\nexports.isAsyncMode = isAsyncMode;\nexports.isConcurrentMode = isConcurrentMode;\nexports.isContextConsumer = isContextConsumer;\nexports.isContextProvider = isContextProvider;\nexports.isElement = isElement;\nexports.isForwardRef = isForwardRef;\nexports.isFragment = isFragment;\nexports.isLazy = isLazy;\nexports.isMemo = isMemo;\nexports.isPortal = isPortal;\nexports.isProfiler = isProfiler;\nexports.isStrictMode = isStrictMode;\nexports.isSuspense = isSuspense;\nexports.isSuspenseList = isSuspenseList;\nexports.isValidElementType = isValidElementType;\nexports.typeOf = typeOf;\n })();\n}\n","'use strict';\n\nif (process.env.NODE_ENV === 'production') {\n module.exports = require('./cjs/react-is.production.min.js');\n} else {\n module.exports = require('./cjs/react-is.development.js');\n}\n","import { ForwardRef, Memo } from 'react-is';\n\n// Simplified polyfill for IE11 support\n// https://github.com/JamesMGreene/Function.name/blob/58b314d4a983110c3682f1228f845d39ccca1817/Function.name.js#L3\nconst fnNameMatchRegex = /^\\s*function(?:\\s|\\s*\\/\\*.*\\*\\/\\s*)+([^(\\s/]*)\\s*/;\nexport function getFunctionName(fn) {\n const match = `${fn}`.match(fnNameMatchRegex);\n const name = match && match[1];\n return name || '';\n}\nfunction getFunctionComponentName(Component, fallback = '') {\n return Component.displayName || Component.name || getFunctionName(Component) || fallback;\n}\nfunction getWrappedName(outerType, innerType, wrapperName) {\n const functionName = getFunctionComponentName(innerType);\n return outerType.displayName || (functionName !== '' ? `${wrapperName}(${functionName})` : wrapperName);\n}\n\n/**\n * cherry-pick from\n * https://github.com/facebook/react/blob/769b1f270e1251d9dbdce0fcbd9e92e502d059b8/packages/shared/getComponentName.js\n * originally forked from recompose/getDisplayName with added IE11 support\n */\nexport default function getDisplayName(Component) {\n if (Component == null) {\n return undefined;\n }\n if (typeof Component === 'string') {\n return Component;\n }\n if (typeof Component === 'function') {\n return getFunctionComponentName(Component, 'Component');\n }\n\n // TypeScript can't have components as objects but they exist in the form of `memo` or `Suspense`\n if (typeof Component === 'object') {\n switch (Component.$$typeof) {\n case ForwardRef:\n return getWrappedName(Component, Component.render, 'ForwardRef');\n case Memo:\n return getWrappedName(Component, Component.type, 'memo');\n default:\n return undefined;\n }\n }\n return undefined;\n}","export default function HTMLElementType(props, propName, componentName, location, propFullName) {\n if (process.env.NODE_ENV === 'production') {\n return null;\n }\n const propValue = props[propName];\n const safePropName = propFullName || propName;\n if (propValue == null) {\n return null;\n }\n if (propValue && propValue.nodeType !== 1) {\n return new Error(`Invalid ${location} \\`${safePropName}\\` supplied to \\`${componentName}\\`. ` + `Expected an HTMLElement.`);\n }\n return null;\n}","import PropTypes from 'prop-types';\nconst refType = PropTypes.oneOfType([PropTypes.func, PropTypes.object]);\nexport default refType;","import _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\n// It should to be noted that this function isn't equivalent to `text-transform: capitalize`.\n//\n// A strict capitalization should uppercase the first letter of each word in the sentence.\n// We only handle the first word.\nexport default function capitalize(string) {\n if (typeof string !== 'string') {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: \\`capitalize(string)\\` expects a string argument.` : _formatMuiErrorMessage(7));\n }\n return string.charAt(0).toUpperCase() + string.slice(1);\n}","/**\n * Safe chained function.\n *\n * Will only create a new function if needed,\n * otherwise will pass back existing functions or null.\n */\nexport default function createChainedFunction(...funcs) {\n return funcs.reduce((acc, func) => {\n if (func == null) {\n return acc;\n }\n return function chainedFunction(...args) {\n acc.apply(this, args);\n func.apply(this, args);\n };\n }, () => {});\n}","// Corresponds to 10 frames at 60 Hz.\n// A few bytes payload overhead when lodash/debounce is ~3 kB and debounce ~300 B.\nexport default function debounce(func, wait = 166) {\n let timeout;\n function debounced(...args) {\n const later = () => {\n // @ts-ignore\n func.apply(this, args);\n };\n clearTimeout(timeout);\n timeout = setTimeout(later, wait);\n }\n debounced.clear = () => {\n clearTimeout(timeout);\n };\n return debounced;\n}","export default function deprecatedPropType(validator, reason) {\n if (process.env.NODE_ENV === 'production') {\n return () => null;\n }\n return (props, propName, componentName, location, propFullName) => {\n const componentNameSafe = componentName || '<>';\n const propFullNameSafe = propFullName || propName;\n if (typeof props[propName] !== 'undefined') {\n return new Error(`The ${location} \\`${propFullNameSafe}\\` of ` + `\\`${componentNameSafe}\\` is deprecated. ${reason}`);\n }\n return null;\n };\n}","import * as React from 'react';\nexport default function isMuiElement(element, muiNames) {\n var _muiName, _element$type;\n return /*#__PURE__*/React.isValidElement(element) && muiNames.indexOf( // For server components `muiName` is avaialble in element.type._payload.value.muiName\n // relevant info - https://github.com/facebook/react/blob/2807d781a08db8e9873687fccc25c0f12b4fb3d4/packages/react/src/ReactLazy.js#L45\n // eslint-disable-next-line no-underscore-dangle\n (_muiName = element.type.muiName) != null ? _muiName : (_element$type = element.type) == null || (_element$type = _element$type._payload) == null || (_element$type = _element$type.value) == null ? void 0 : _element$type.muiName) !== -1;\n}","export default function ownerDocument(node) {\n return node && node.ownerDocument || document;\n}","import ownerDocument from '../ownerDocument';\nexport default function ownerWindow(node) {\n const doc = ownerDocument(node);\n return doc.defaultView || window;\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nexport default function requirePropFactory(componentNameInError, Component) {\n if (process.env.NODE_ENV === 'production') {\n return () => null;\n }\n\n // eslint-disable-next-line react/forbid-foreign-prop-types\n const prevPropTypes = Component ? _extends({}, Component.propTypes) : null;\n const requireProp = requiredProp => (props, propName, componentName, location, propFullName, ...args) => {\n const propFullNameSafe = propFullName || propName;\n const defaultTypeChecker = prevPropTypes == null ? void 0 : prevPropTypes[propFullNameSafe];\n if (defaultTypeChecker) {\n const typeCheckerResult = defaultTypeChecker(props, propName, componentName, location, propFullName, ...args);\n if (typeCheckerResult) {\n return typeCheckerResult;\n }\n }\n if (typeof props[propName] !== 'undefined' && !props[requiredProp]) {\n return new Error(`The prop \\`${propFullNameSafe}\\` of ` + `\\`${componentNameInError}\\` can only be used together with the \\`${requiredProp}\\` prop.`);\n }\n return null;\n };\n return requireProp;\n}","/**\n * TODO v5: consider making it private\n *\n * passes {value} to {ref}\n *\n * WARNING: Be sure to only call this inside a callback that is passed as a ref.\n * Otherwise, make sure to cleanup the previous {ref} if it changes. See\n * https://github.com/mui/material-ui/issues/13539\n *\n * Useful if you want to expose the ref of an inner component to the public API\n * while still using it inside the component.\n * @param ref A ref callback or ref object. If anything falsy, this is a no-op.\n */\nexport default function setRef(ref, value) {\n if (typeof ref === 'function') {\n ref(value);\n } else if (ref) {\n ref.current = value;\n }\n}","'use client';\n\nimport * as React from 'react';\n\n/**\n * A version of `React.useLayoutEffect` that does not show a warning when server-side rendering.\n * This is useful for effects that are only needed for client-side rendering but not for SSR.\n *\n * Before you use this hook, make sure to read https://gist.github.com/gaearon/e7d97cdf38a2907924ea12e4ebdf3c85\n * and confirm it doesn't apply to your use-case.\n */\nconst useEnhancedEffect = typeof window !== 'undefined' ? React.useLayoutEffect : React.useEffect;\nexport default useEnhancedEffect;","'use client';\n\nimport * as React from 'react';\nlet globalId = 0;\nfunction useGlobalId(idOverride) {\n const [defaultId, setDefaultId] = React.useState(idOverride);\n const id = idOverride || defaultId;\n React.useEffect(() => {\n if (defaultId == null) {\n // Fallback to this default id when possible.\n // Use the incrementing value for client-side rendering only.\n // We can't use it server-side.\n // If you want to use random values please consider the Birthday Problem: https://en.wikipedia.org/wiki/Birthday_problem\n globalId += 1;\n setDefaultId(`mui-${globalId}`);\n }\n }, [defaultId]);\n return id;\n}\n\n// downstream bundlers may remove unnecessary concatenation, but won't remove toString call -- Workaround for https://github.com/webpack/webpack/issues/14814\nconst maybeReactUseId = React['useId'.toString()];\n/**\n *\n * @example
    \n * @param idOverride\n * @returns {string}\n */\nexport default function useId(idOverride) {\n if (maybeReactUseId !== undefined) {\n const reactId = maybeReactUseId();\n return idOverride != null ? idOverride : reactId;\n }\n // eslint-disable-next-line react-hooks/rules-of-hooks -- `React.useId` is invariant at runtime.\n return useGlobalId(idOverride);\n}","export default function unsupportedProp(props, propName, componentName, location, propFullName) {\n if (process.env.NODE_ENV === 'production') {\n return null;\n }\n const propFullNameSafe = propFullName || propName;\n if (typeof props[propName] !== 'undefined') {\n return new Error(`The prop \\`${propFullNameSafe}\\` is not supported. Please remove it.`);\n }\n return null;\n}","'use client';\n\n/* eslint-disable react-hooks/rules-of-hooks, react-hooks/exhaustive-deps */\nimport * as React from 'react';\nexport default function useControlled({\n controlled,\n default: defaultProp,\n name,\n state = 'value'\n}) {\n // isControlled is ignored in the hook dependency lists as it should never change.\n const {\n current: isControlled\n } = React.useRef(controlled !== undefined);\n const [valueState, setValue] = React.useState(defaultProp);\n const value = isControlled ? controlled : valueState;\n if (process.env.NODE_ENV !== 'production') {\n React.useEffect(() => {\n if (isControlled !== (controlled !== undefined)) {\n console.error([`MUI: A component is changing the ${isControlled ? '' : 'un'}controlled ${state} state of ${name} to be ${isControlled ? 'un' : ''}controlled.`, 'Elements should not switch from uncontrolled to controlled (or vice versa).', `Decide between using a controlled or uncontrolled ${name} ` + 'element for the lifetime of the component.', \"The nature of the state is determined during the first render. It's considered controlled if the value is not `undefined`.\", 'More info: https://fb.me/react-controlled-components'].join('\\n'));\n }\n }, [state, name, controlled]);\n const {\n current: defaultValue\n } = React.useRef(defaultProp);\n React.useEffect(() => {\n if (!isControlled && defaultValue !== defaultProp) {\n console.error([`MUI: A component is changing the default ${state} state of an uncontrolled ${name} after being initialized. ` + `To suppress this warning opt to use a controlled ${name}.`].join('\\n'));\n }\n }, [JSON.stringify(defaultProp)]);\n }\n const setValueIfUncontrolled = React.useCallback(newValue => {\n if (!isControlled) {\n setValue(newValue);\n }\n }, []);\n return [value, setValueIfUncontrolled];\n}","'use client';\n\nimport * as React from 'react';\nimport useEnhancedEffect from '../useEnhancedEffect';\n\n/**\n * Inspired by https://github.com/facebook/react/issues/14099#issuecomment-440013892\n * See RFC in https://github.com/reactjs/rfcs/pull/220\n */\n\nfunction useEventCallback(fn) {\n const ref = React.useRef(fn);\n useEnhancedEffect(() => {\n ref.current = fn;\n });\n return React.useRef((...args) =>\n // @ts-expect-error hide `this`\n (0, ref.current)(...args)).current;\n}\nexport default useEventCallback;","'use client';\n\nimport * as React from 'react';\nimport setRef from '../setRef';\nexport default function useForkRef(...refs) {\n /**\n * This will create a new function if the refs passed to this hook change and are all defined.\n * This means react will call the old forkRef with `null` and the new forkRef\n * with the ref. Cleanup naturally emerges from this behavior.\n */\n return React.useMemo(() => {\n if (refs.every(ref => ref == null)) {\n return null;\n }\n return instance => {\n refs.forEach(ref => {\n setRef(ref, instance);\n });\n };\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, refs);\n}","'use client';\n\nimport * as React from 'react';\nconst UNINITIALIZED = {};\n\n/**\n * A React.useRef() that is initialized lazily with a function. Note that it accepts an optional\n * initialization argument, so the initialization function doesn't need to be an inline closure.\n *\n * @usage\n * const ref = useLazyRef(sortColumns, columns)\n */\nexport default function useLazyRef(init, initArg) {\n const ref = React.useRef(UNINITIALIZED);\n if (ref.current === UNINITIALIZED) {\n ref.current = init(initArg);\n }\n return ref;\n}","'use client';\n\nimport * as React from 'react';\nconst EMPTY = [];\n\n/**\n * A React.useEffect equivalent that runs once, when the component is mounted.\n */\nexport default function useOnMount(fn) {\n /* eslint-disable react-hooks/exhaustive-deps */\n React.useEffect(fn, EMPTY);\n /* eslint-enable react-hooks/exhaustive-deps */\n}","'use client';\n\nimport useLazyRef from '../useLazyRef/useLazyRef';\nimport useOnMount from '../useOnMount/useOnMount';\nexport class Timeout {\n constructor() {\n this.currentId = null;\n this.clear = () => {\n if (this.currentId !== null) {\n clearTimeout(this.currentId);\n this.currentId = null;\n }\n };\n this.disposeEffect = () => {\n return this.clear;\n };\n }\n static create() {\n return new Timeout();\n }\n /**\n * Executes `fn` after `delay`, clearing any previously scheduled call.\n */\n start(delay, fn) {\n this.clear();\n this.currentId = setTimeout(() => {\n this.currentId = null;\n fn();\n }, delay);\n }\n}\nexport default function useTimeout() {\n const timeout = useLazyRef(Timeout.create).current;\n useOnMount(timeout.disposeEffect);\n return timeout;\n}","'use client';\n\n// based on https://github.com/WICG/focus-visible/blob/v4.1.5/src/focus-visible.js\nimport * as React from 'react';\nimport { Timeout } from '../useTimeout/useTimeout';\nlet hadKeyboardEvent = true;\nlet hadFocusVisibleRecently = false;\nconst hadFocusVisibleRecentlyTimeout = new Timeout();\nconst inputTypesWhitelist = {\n text: true,\n search: true,\n url: true,\n tel: true,\n email: true,\n password: true,\n number: true,\n date: true,\n month: true,\n week: true,\n time: true,\n datetime: true,\n 'datetime-local': true\n};\n\n/**\n * Computes whether the given element should automatically trigger the\n * `focus-visible` class being added, i.e. whether it should always match\n * `:focus-visible` when focused.\n * @param {Element} node\n * @returns {boolean}\n */\nfunction focusTriggersKeyboardModality(node) {\n const {\n type,\n tagName\n } = node;\n if (tagName === 'INPUT' && inputTypesWhitelist[type] && !node.readOnly) {\n return true;\n }\n if (tagName === 'TEXTAREA' && !node.readOnly) {\n return true;\n }\n if (node.isContentEditable) {\n return true;\n }\n return false;\n}\n\n/**\n * Keep track of our keyboard modality state with `hadKeyboardEvent`.\n * If the most recent user interaction was via the keyboard;\n * and the key press did not include a meta, alt/option, or control key;\n * then the modality is keyboard. Otherwise, the modality is not keyboard.\n * @param {KeyboardEvent} event\n */\nfunction handleKeyDown(event) {\n if (event.metaKey || event.altKey || event.ctrlKey) {\n return;\n }\n hadKeyboardEvent = true;\n}\n\n/**\n * If at any point a user clicks with a pointing device, ensure that we change\n * the modality away from keyboard.\n * This avoids the situation where a user presses a key on an already focused\n * element, and then clicks on a different element, focusing it with a\n * pointing device, while we still think we're in keyboard modality.\n */\nfunction handlePointerDown() {\n hadKeyboardEvent = false;\n}\nfunction handleVisibilityChange() {\n if (this.visibilityState === 'hidden') {\n // If the tab becomes active again, the browser will handle calling focus\n // on the element (Safari actually calls it twice).\n // If this tab change caused a blur on an element with focus-visible,\n // re-apply the class when the user switches back to the tab.\n if (hadFocusVisibleRecently) {\n hadKeyboardEvent = true;\n }\n }\n}\nfunction prepare(doc) {\n doc.addEventListener('keydown', handleKeyDown, true);\n doc.addEventListener('mousedown', handlePointerDown, true);\n doc.addEventListener('pointerdown', handlePointerDown, true);\n doc.addEventListener('touchstart', handlePointerDown, true);\n doc.addEventListener('visibilitychange', handleVisibilityChange, true);\n}\nexport function teardown(doc) {\n doc.removeEventListener('keydown', handleKeyDown, true);\n doc.removeEventListener('mousedown', handlePointerDown, true);\n doc.removeEventListener('pointerdown', handlePointerDown, true);\n doc.removeEventListener('touchstart', handlePointerDown, true);\n doc.removeEventListener('visibilitychange', handleVisibilityChange, true);\n}\nfunction isFocusVisible(event) {\n const {\n target\n } = event;\n try {\n return target.matches(':focus-visible');\n } catch (error) {\n // Browsers not implementing :focus-visible will throw a SyntaxError.\n // We use our own heuristic for those browsers.\n // Rethrow might be better if it's not the expected error but do we really\n // want to crash if focus-visible malfunctioned?\n }\n\n // No need for validFocusTarget check. The user does that by attaching it to\n // focusable events only.\n return hadKeyboardEvent || focusTriggersKeyboardModality(target);\n}\nexport default function useIsFocusVisible() {\n const ref = React.useCallback(node => {\n if (node != null) {\n prepare(node.ownerDocument);\n }\n }, []);\n const isFocusVisibleRef = React.useRef(false);\n\n /**\n * Should be called if a blur event is fired\n */\n function handleBlurVisible() {\n // checking against potential state variable does not suffice if we focus and blur synchronously.\n // React wouldn't have time to trigger a re-render so `focusVisible` would be stale.\n // Ideally we would adjust `isFocusVisible(event)` to look at `relatedTarget` for blur events.\n // This doesn't work in IE11 due to https://github.com/facebook/react/issues/3751\n // TODO: check again if React releases their internal changes to focus event handling (https://github.com/facebook/react/pull/19186).\n if (isFocusVisibleRef.current) {\n // To detect a tab/window switch, we look for a blur event followed\n // rapidly by a visibility change.\n // If we don't see a visibility change within 100ms, it's probably a\n // regular focus change.\n hadFocusVisibleRecently = true;\n hadFocusVisibleRecentlyTimeout.start(100, () => {\n hadFocusVisibleRecently = false;\n });\n isFocusVisibleRef.current = false;\n return true;\n }\n return false;\n }\n\n /**\n * Should be called if a blur event is fired\n */\n function handleFocusVisible(event) {\n if (isFocusVisible(event)) {\n isFocusVisibleRef.current = true;\n return true;\n }\n return false;\n }\n return {\n isFocusVisibleRef,\n onFocus: handleFocusVisible,\n onBlur: handleBlurVisible,\n ref\n };\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\n/**\n * Add keys, values of `defaultProps` that does not exist in `props`\n * @param {object} defaultProps\n * @param {object} props\n * @returns {object} resolved props\n */\nexport default function resolveProps(defaultProps, props) {\n const output = _extends({}, props);\n Object.keys(defaultProps).forEach(propName => {\n if (propName.toString().match(/^(components|slots)$/)) {\n output[propName] = _extends({}, defaultProps[propName], output[propName]);\n } else if (propName.toString().match(/^(componentsProps|slotProps)$/)) {\n const defaultSlotProps = defaultProps[propName] || {};\n const slotProps = props[propName];\n output[propName] = {};\n if (!slotProps || !Object.keys(slotProps)) {\n // Reduce the iteration if the slot props is empty\n output[propName] = defaultSlotProps;\n } else if (!defaultSlotProps || !Object.keys(defaultSlotProps)) {\n // Reduce the iteration if the default slot props is empty\n output[propName] = slotProps;\n } else {\n output[propName] = _extends({}, slotProps);\n Object.keys(defaultSlotProps).forEach(slotPropName => {\n output[propName][slotPropName] = resolveProps(defaultSlotProps[slotPropName], slotProps[slotPropName]);\n });\n }\n } else if (output[propName] === undefined) {\n output[propName] = defaultProps[propName];\n }\n });\n return output;\n}","export default function composeClasses(slots, getUtilityClass, classes = undefined) {\n const output = {};\n Object.keys(slots).forEach(\n // `Object.keys(slots)` can't be wider than `T` because we infer `T` from `slots`.\n // @ts-expect-error https://github.com/microsoft/TypeScript/pull/12253#issuecomment-263132208\n slot => {\n output[slot] = slots[slot].reduce((acc, key) => {\n if (key) {\n const utilityClass = getUtilityClass(key);\n if (utilityClass !== '') {\n acc.push(utilityClass);\n }\n if (classes && classes[key]) {\n acc.push(classes[key]);\n }\n }\n return acc;\n }, []).join(' ');\n });\n return output;\n}","const defaultGenerator = componentName => componentName;\nconst createClassNameGenerator = () => {\n let generate = defaultGenerator;\n return {\n configure(generator) {\n generate = generator;\n },\n generate(componentName) {\n return generate(componentName);\n },\n reset() {\n generate = defaultGenerator;\n }\n };\n};\nconst ClassNameGenerator = createClassNameGenerator();\nexport default ClassNameGenerator;","import ClassNameGenerator from '../ClassNameGenerator';\nexport const globalStateClasses = {\n active: 'active',\n checked: 'checked',\n completed: 'completed',\n disabled: 'disabled',\n error: 'error',\n expanded: 'expanded',\n focused: 'focused',\n focusVisible: 'focusVisible',\n open: 'open',\n readOnly: 'readOnly',\n required: 'required',\n selected: 'selected'\n};\nexport default function generateUtilityClass(componentName, slot, globalStatePrefix = 'Mui') {\n const globalStateClass = globalStateClasses[slot];\n return globalStateClass ? `${globalStatePrefix}-${globalStateClass}` : `${ClassNameGenerator.generate(componentName)}-${slot}`;\n}\nexport function isGlobalState(slot) {\n return globalStateClasses[slot] !== undefined;\n}","import generateUtilityClass from '../generateUtilityClass';\nexport default function generateUtilityClasses(componentName, slots, globalStatePrefix = 'Mui') {\n const result = {};\n slots.forEach(slot => {\n result[slot] = generateUtilityClass(componentName, slot, globalStatePrefix);\n });\n return result;\n}","function clamp(val, min = Number.MIN_SAFE_INTEGER, max = Number.MAX_SAFE_INTEGER) {\n return Math.max(min, Math.min(val, max));\n}\nexport default clamp;","export default function _objectWithoutPropertiesLoose(source, excluded) {\n if (source == null) return {};\n var target = {};\n var sourceKeys = Object.keys(source);\n var key, i;\n for (i = 0; i < sourceKeys.length; i++) {\n key = sourceKeys[i];\n if (excluded.indexOf(key) >= 0) continue;\n target[key] = source[key];\n }\n return target;\n}","import _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nconst _excluded = [\"values\", \"unit\", \"step\"];\n// Sorted ASC by size. That's important.\n// It can't be configured as it's used statically for propTypes.\nexport const breakpointKeys = ['xs', 'sm', 'md', 'lg', 'xl'];\nconst sortBreakpointsValues = values => {\n const breakpointsAsArray = Object.keys(values).map(key => ({\n key,\n val: values[key]\n })) || [];\n // Sort in ascending order\n breakpointsAsArray.sort((breakpoint1, breakpoint2) => breakpoint1.val - breakpoint2.val);\n return breakpointsAsArray.reduce((acc, obj) => {\n return _extends({}, acc, {\n [obj.key]: obj.val\n });\n }, {});\n};\n\n// Keep in mind that @media is inclusive by the CSS specification.\nexport default function createBreakpoints(breakpoints) {\n const {\n // The breakpoint **start** at this value.\n // For instance with the first breakpoint xs: [xs, sm).\n values = {\n xs: 0,\n // phone\n sm: 600,\n // tablet\n md: 900,\n // small laptop\n lg: 1200,\n // desktop\n xl: 1536 // large screen\n },\n unit = 'px',\n step = 5\n } = breakpoints,\n other = _objectWithoutPropertiesLoose(breakpoints, _excluded);\n const sortedValues = sortBreakpointsValues(values);\n const keys = Object.keys(sortedValues);\n function up(key) {\n const value = typeof values[key] === 'number' ? values[key] : key;\n return `@media (min-width:${value}${unit})`;\n }\n function down(key) {\n const value = typeof values[key] === 'number' ? values[key] : key;\n return `@media (max-width:${value - step / 100}${unit})`;\n }\n function between(start, end) {\n const endIndex = keys.indexOf(end);\n return `@media (min-width:${typeof values[start] === 'number' ? values[start] : start}${unit}) and ` + `(max-width:${(endIndex !== -1 && typeof values[keys[endIndex]] === 'number' ? values[keys[endIndex]] : end) - step / 100}${unit})`;\n }\n function only(key) {\n if (keys.indexOf(key) + 1 < keys.length) {\n return between(key, keys[keys.indexOf(key) + 1]);\n }\n return up(key);\n }\n function not(key) {\n // handle first and last key separately, for better readability\n const keyIndex = keys.indexOf(key);\n if (keyIndex === 0) {\n return up(keys[1]);\n }\n if (keyIndex === keys.length - 1) {\n return down(keys[keyIndex]);\n }\n return between(key, keys[keys.indexOf(key) + 1]).replace('@media', '@media not all and');\n }\n return _extends({\n keys,\n values: sortedValues,\n up,\n down,\n between,\n only,\n not,\n unit\n }, other);\n}","const shape = {\n borderRadius: 4\n};\nexport default shape;","import PropTypes from 'prop-types';\nconst responsivePropType = process.env.NODE_ENV !== 'production' ? PropTypes.oneOfType([PropTypes.number, PropTypes.string, PropTypes.object, PropTypes.array]) : {};\nexport default responsivePropType;","import deepmerge from '@mui/utils/deepmerge';\nfunction merge(acc, item) {\n if (!item) {\n return acc;\n }\n return deepmerge(acc, item, {\n clone: false // No need to clone deep, it's way faster.\n });\n}\nexport default merge;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport PropTypes from 'prop-types';\nimport deepmerge from '@mui/utils/deepmerge';\nimport merge from './merge';\n\n// The breakpoint **start** at this value.\n// For instance with the first breakpoint xs: [xs, sm[.\nexport const values = {\n xs: 0,\n // phone\n sm: 600,\n // tablet\n md: 900,\n // small laptop\n lg: 1200,\n // desktop\n xl: 1536 // large screen\n};\nconst defaultBreakpoints = {\n // Sorted ASC by size. That's important.\n // It can't be configured as it's used statically for propTypes.\n keys: ['xs', 'sm', 'md', 'lg', 'xl'],\n up: key => `@media (min-width:${values[key]}px)`\n};\nexport function handleBreakpoints(props, propValue, styleFromPropValue) {\n const theme = props.theme || {};\n if (Array.isArray(propValue)) {\n const themeBreakpoints = theme.breakpoints || defaultBreakpoints;\n return propValue.reduce((acc, item, index) => {\n acc[themeBreakpoints.up(themeBreakpoints.keys[index])] = styleFromPropValue(propValue[index]);\n return acc;\n }, {});\n }\n if (typeof propValue === 'object') {\n const themeBreakpoints = theme.breakpoints || defaultBreakpoints;\n return Object.keys(propValue).reduce((acc, breakpoint) => {\n // key is breakpoint\n if (Object.keys(themeBreakpoints.values || values).indexOf(breakpoint) !== -1) {\n const mediaKey = themeBreakpoints.up(breakpoint);\n acc[mediaKey] = styleFromPropValue(propValue[breakpoint], breakpoint);\n } else {\n const cssKey = breakpoint;\n acc[cssKey] = propValue[cssKey];\n }\n return acc;\n }, {});\n }\n const output = styleFromPropValue(propValue);\n return output;\n}\nfunction breakpoints(styleFunction) {\n // false positive\n // eslint-disable-next-line react/function-component-definition\n const newStyleFunction = props => {\n const theme = props.theme || {};\n const base = styleFunction(props);\n const themeBreakpoints = theme.breakpoints || defaultBreakpoints;\n const extended = themeBreakpoints.keys.reduce((acc, key) => {\n if (props[key]) {\n acc = acc || {};\n acc[themeBreakpoints.up(key)] = styleFunction(_extends({\n theme\n }, props[key]));\n }\n return acc;\n }, null);\n return merge(base, extended);\n };\n newStyleFunction.propTypes = process.env.NODE_ENV !== 'production' ? _extends({}, styleFunction.propTypes, {\n xs: PropTypes.object,\n sm: PropTypes.object,\n md: PropTypes.object,\n lg: PropTypes.object,\n xl: PropTypes.object\n }) : {};\n newStyleFunction.filterProps = ['xs', 'sm', 'md', 'lg', 'xl', ...styleFunction.filterProps];\n return newStyleFunction;\n}\nexport function createEmptyBreakpointObject(breakpointsInput = {}) {\n var _breakpointsInput$key;\n const breakpointsInOrder = (_breakpointsInput$key = breakpointsInput.keys) == null ? void 0 : _breakpointsInput$key.reduce((acc, key) => {\n const breakpointStyleKey = breakpointsInput.up(key);\n acc[breakpointStyleKey] = {};\n return acc;\n }, {});\n return breakpointsInOrder || {};\n}\nexport function removeUnusedBreakpoints(breakpointKeys, style) {\n return breakpointKeys.reduce((acc, key) => {\n const breakpointOutput = acc[key];\n const isBreakpointUnused = !breakpointOutput || Object.keys(breakpointOutput).length === 0;\n if (isBreakpointUnused) {\n delete acc[key];\n }\n return acc;\n }, style);\n}\nexport function mergeBreakpointsInOrder(breakpointsInput, ...styles) {\n const emptyBreakpoints = createEmptyBreakpointObject(breakpointsInput);\n const mergedOutput = [emptyBreakpoints, ...styles].reduce((prev, next) => deepmerge(prev, next), {});\n return removeUnusedBreakpoints(Object.keys(emptyBreakpoints), mergedOutput);\n}\n\n// compute base for responsive values; e.g.,\n// [1,2,3] => {xs: true, sm: true, md: true}\n// {xs: 1, sm: 2, md: 3} => {xs: true, sm: true, md: true}\nexport function computeBreakpointsBase(breakpointValues, themeBreakpoints) {\n // fixed value\n if (typeof breakpointValues !== 'object') {\n return {};\n }\n const base = {};\n const breakpointsKeys = Object.keys(themeBreakpoints);\n if (Array.isArray(breakpointValues)) {\n breakpointsKeys.forEach((breakpoint, i) => {\n if (i < breakpointValues.length) {\n base[breakpoint] = true;\n }\n });\n } else {\n breakpointsKeys.forEach(breakpoint => {\n if (breakpointValues[breakpoint] != null) {\n base[breakpoint] = true;\n }\n });\n }\n return base;\n}\nexport function resolveBreakpointValues({\n values: breakpointValues,\n breakpoints: themeBreakpoints,\n base: customBase\n}) {\n const base = customBase || computeBreakpointsBase(breakpointValues, themeBreakpoints);\n const keys = Object.keys(base);\n if (keys.length === 0) {\n return breakpointValues;\n }\n let previous;\n return keys.reduce((acc, breakpoint, i) => {\n if (Array.isArray(breakpointValues)) {\n acc[breakpoint] = breakpointValues[i] != null ? breakpointValues[i] : breakpointValues[previous];\n previous = i;\n } else if (typeof breakpointValues === 'object') {\n acc[breakpoint] = breakpointValues[breakpoint] != null ? breakpointValues[breakpoint] : breakpointValues[previous];\n previous = breakpoint;\n } else {\n acc[breakpoint] = breakpointValues;\n }\n return acc;\n }, {});\n}\nexport default breakpoints;","import capitalize from '@mui/utils/capitalize';\nimport responsivePropType from './responsivePropType';\nimport { handleBreakpoints } from './breakpoints';\nexport function getPath(obj, path, checkVars = true) {\n if (!path || typeof path !== 'string') {\n return null;\n }\n\n // Check if CSS variables are used\n if (obj && obj.vars && checkVars) {\n const val = `vars.${path}`.split('.').reduce((acc, item) => acc && acc[item] ? acc[item] : null, obj);\n if (val != null) {\n return val;\n }\n }\n return path.split('.').reduce((acc, item) => {\n if (acc && acc[item] != null) {\n return acc[item];\n }\n return null;\n }, obj);\n}\nexport function getStyleValue(themeMapping, transform, propValueFinal, userValue = propValueFinal) {\n let value;\n if (typeof themeMapping === 'function') {\n value = themeMapping(propValueFinal);\n } else if (Array.isArray(themeMapping)) {\n value = themeMapping[propValueFinal] || userValue;\n } else {\n value = getPath(themeMapping, propValueFinal) || userValue;\n }\n if (transform) {\n value = transform(value, userValue, themeMapping);\n }\n return value;\n}\nfunction style(options) {\n const {\n prop,\n cssProperty = options.prop,\n themeKey,\n transform\n } = options;\n\n // false positive\n // eslint-disable-next-line react/function-component-definition\n const fn = props => {\n if (props[prop] == null) {\n return null;\n }\n const propValue = props[prop];\n const theme = props.theme;\n const themeMapping = getPath(theme, themeKey) || {};\n const styleFromPropValue = propValueFinal => {\n let value = getStyleValue(themeMapping, transform, propValueFinal);\n if (propValueFinal === value && typeof propValueFinal === 'string') {\n // Haven't found value\n value = getStyleValue(themeMapping, transform, `${prop}${propValueFinal === 'default' ? '' : capitalize(propValueFinal)}`, propValueFinal);\n }\n if (cssProperty === false) {\n return value;\n }\n return {\n [cssProperty]: value\n };\n };\n return handleBreakpoints(props, propValue, styleFromPropValue);\n };\n fn.propTypes = process.env.NODE_ENV !== 'production' ? {\n [prop]: responsivePropType\n } : {};\n fn.filterProps = [prop];\n return fn;\n}\nexport default style;","export default function memoize(fn) {\n const cache = {};\n return arg => {\n if (cache[arg] === undefined) {\n cache[arg] = fn(arg);\n }\n return cache[arg];\n };\n}","import responsivePropType from './responsivePropType';\nimport { handleBreakpoints } from './breakpoints';\nimport { getPath } from './style';\nimport merge from './merge';\nimport memoize from './memoize';\nconst properties = {\n m: 'margin',\n p: 'padding'\n};\nconst directions = {\n t: 'Top',\n r: 'Right',\n b: 'Bottom',\n l: 'Left',\n x: ['Left', 'Right'],\n y: ['Top', 'Bottom']\n};\nconst aliases = {\n marginX: 'mx',\n marginY: 'my',\n paddingX: 'px',\n paddingY: 'py'\n};\n\n// memoize() impact:\n// From 300,000 ops/sec\n// To 350,000 ops/sec\nconst getCssProperties = memoize(prop => {\n // It's not a shorthand notation.\n if (prop.length > 2) {\n if (aliases[prop]) {\n prop = aliases[prop];\n } else {\n return [prop];\n }\n }\n const [a, b] = prop.split('');\n const property = properties[a];\n const direction = directions[b] || '';\n return Array.isArray(direction) ? direction.map(dir => property + dir) : [property + direction];\n});\nexport const marginKeys = ['m', 'mt', 'mr', 'mb', 'ml', 'mx', 'my', 'margin', 'marginTop', 'marginRight', 'marginBottom', 'marginLeft', 'marginX', 'marginY', 'marginInline', 'marginInlineStart', 'marginInlineEnd', 'marginBlock', 'marginBlockStart', 'marginBlockEnd'];\nexport const paddingKeys = ['p', 'pt', 'pr', 'pb', 'pl', 'px', 'py', 'padding', 'paddingTop', 'paddingRight', 'paddingBottom', 'paddingLeft', 'paddingX', 'paddingY', 'paddingInline', 'paddingInlineStart', 'paddingInlineEnd', 'paddingBlock', 'paddingBlockStart', 'paddingBlockEnd'];\nconst spacingKeys = [...marginKeys, ...paddingKeys];\nexport function createUnaryUnit(theme, themeKey, defaultValue, propName) {\n var _getPath;\n const themeSpacing = (_getPath = getPath(theme, themeKey, false)) != null ? _getPath : defaultValue;\n if (typeof themeSpacing === 'number') {\n return abs => {\n if (typeof abs === 'string') {\n return abs;\n }\n if (process.env.NODE_ENV !== 'production') {\n if (typeof abs !== 'number') {\n console.error(`MUI: Expected ${propName} argument to be a number or a string, got ${abs}.`);\n }\n }\n return themeSpacing * abs;\n };\n }\n if (Array.isArray(themeSpacing)) {\n return abs => {\n if (typeof abs === 'string') {\n return abs;\n }\n if (process.env.NODE_ENV !== 'production') {\n if (!Number.isInteger(abs)) {\n console.error([`MUI: The \\`theme.${themeKey}\\` array type cannot be combined with non integer values.` + `You should either use an integer value that can be used as index, or define the \\`theme.${themeKey}\\` as a number.`].join('\\n'));\n } else if (abs > themeSpacing.length - 1) {\n console.error([`MUI: The value provided (${abs}) overflows.`, `The supported values are: ${JSON.stringify(themeSpacing)}.`, `${abs} > ${themeSpacing.length - 1}, you need to add the missing values.`].join('\\n'));\n }\n }\n return themeSpacing[abs];\n };\n }\n if (typeof themeSpacing === 'function') {\n return themeSpacing;\n }\n if (process.env.NODE_ENV !== 'production') {\n console.error([`MUI: The \\`theme.${themeKey}\\` value (${themeSpacing}) is invalid.`, 'It should be a number, an array or a function.'].join('\\n'));\n }\n return () => undefined;\n}\nexport function createUnarySpacing(theme) {\n return createUnaryUnit(theme, 'spacing', 8, 'spacing');\n}\nexport function getValue(transformer, propValue) {\n if (typeof propValue === 'string' || propValue == null) {\n return propValue;\n }\n const abs = Math.abs(propValue);\n const transformed = transformer(abs);\n if (propValue >= 0) {\n return transformed;\n }\n if (typeof transformed === 'number') {\n return -transformed;\n }\n return `-${transformed}`;\n}\nexport function getStyleFromPropValue(cssProperties, transformer) {\n return propValue => cssProperties.reduce((acc, cssProperty) => {\n acc[cssProperty] = getValue(transformer, propValue);\n return acc;\n }, {});\n}\nfunction resolveCssProperty(props, keys, prop, transformer) {\n // Using a hash computation over an array iteration could be faster, but with only 28 items,\n // it's doesn't worth the bundle size.\n if (keys.indexOf(prop) === -1) {\n return null;\n }\n const cssProperties = getCssProperties(prop);\n const styleFromPropValue = getStyleFromPropValue(cssProperties, transformer);\n const propValue = props[prop];\n return handleBreakpoints(props, propValue, styleFromPropValue);\n}\nfunction style(props, keys) {\n const transformer = createUnarySpacing(props.theme);\n return Object.keys(props).map(prop => resolveCssProperty(props, keys, prop, transformer)).reduce(merge, {});\n}\nexport function margin(props) {\n return style(props, marginKeys);\n}\nmargin.propTypes = process.env.NODE_ENV !== 'production' ? marginKeys.reduce((obj, key) => {\n obj[key] = responsivePropType;\n return obj;\n}, {}) : {};\nmargin.filterProps = marginKeys;\nexport function padding(props) {\n return style(props, paddingKeys);\n}\npadding.propTypes = process.env.NODE_ENV !== 'production' ? paddingKeys.reduce((obj, key) => {\n obj[key] = responsivePropType;\n return obj;\n}, {}) : {};\npadding.filterProps = paddingKeys;\nfunction spacing(props) {\n return style(props, spacingKeys);\n}\nspacing.propTypes = process.env.NODE_ENV !== 'production' ? spacingKeys.reduce((obj, key) => {\n obj[key] = responsivePropType;\n return obj;\n}, {}) : {};\nspacing.filterProps = spacingKeys;\nexport default spacing;","import { createUnarySpacing } from '../spacing';\n\n// The different signatures imply different meaning for their arguments that can't be expressed structurally.\n// We express the difference with variable names.\n\nexport default function createSpacing(spacingInput = 8) {\n // Already transformed.\n if (spacingInput.mui) {\n return spacingInput;\n }\n\n // Material Design layouts are visually balanced. Most measurements align to an 8dp grid, which aligns both spacing and the overall layout.\n // Smaller components, such as icons, can align to a 4dp grid.\n // https://m2.material.io/design/layout/understanding-layout.html\n const transform = createUnarySpacing({\n spacing: spacingInput\n });\n const spacing = (...argsInput) => {\n if (process.env.NODE_ENV !== 'production') {\n if (!(argsInput.length <= 4)) {\n console.error(`MUI: Too many arguments provided, expected between 0 and 4, got ${argsInput.length}`);\n }\n }\n const args = argsInput.length === 0 ? [1] : argsInput;\n return args.map(argument => {\n const output = transform(argument);\n return typeof output === 'number' ? `${output}px` : output;\n }).join(' ');\n };\n spacing.mui = true;\n return spacing;\n}","import merge from './merge';\nfunction compose(...styles) {\n const handlers = styles.reduce((acc, style) => {\n style.filterProps.forEach(prop => {\n acc[prop] = style;\n });\n return acc;\n }, {});\n\n // false positive\n // eslint-disable-next-line react/function-component-definition\n const fn = props => {\n return Object.keys(props).reduce((acc, prop) => {\n if (handlers[prop]) {\n return merge(acc, handlers[prop](props));\n }\n return acc;\n }, {});\n };\n fn.propTypes = process.env.NODE_ENV !== 'production' ? styles.reduce((acc, style) => Object.assign(acc, style.propTypes), {}) : {};\n fn.filterProps = styles.reduce((acc, style) => acc.concat(style.filterProps), []);\n return fn;\n}\nexport default compose;","import responsivePropType from './responsivePropType';\nimport style from './style';\nimport compose from './compose';\nimport { createUnaryUnit, getValue } from './spacing';\nimport { handleBreakpoints } from './breakpoints';\nexport function borderTransform(value) {\n if (typeof value !== 'number') {\n return value;\n }\n return `${value}px solid`;\n}\nfunction createBorderStyle(prop, transform) {\n return style({\n prop,\n themeKey: 'borders',\n transform\n });\n}\nexport const border = createBorderStyle('border', borderTransform);\nexport const borderTop = createBorderStyle('borderTop', borderTransform);\nexport const borderRight = createBorderStyle('borderRight', borderTransform);\nexport const borderBottom = createBorderStyle('borderBottom', borderTransform);\nexport const borderLeft = createBorderStyle('borderLeft', borderTransform);\nexport const borderColor = createBorderStyle('borderColor');\nexport const borderTopColor = createBorderStyle('borderTopColor');\nexport const borderRightColor = createBorderStyle('borderRightColor');\nexport const borderBottomColor = createBorderStyle('borderBottomColor');\nexport const borderLeftColor = createBorderStyle('borderLeftColor');\nexport const outline = createBorderStyle('outline', borderTransform);\nexport const outlineColor = createBorderStyle('outlineColor');\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const borderRadius = props => {\n if (props.borderRadius !== undefined && props.borderRadius !== null) {\n const transformer = createUnaryUnit(props.theme, 'shape.borderRadius', 4, 'borderRadius');\n const styleFromPropValue = propValue => ({\n borderRadius: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.borderRadius, styleFromPropValue);\n }\n return null;\n};\nborderRadius.propTypes = process.env.NODE_ENV !== 'production' ? {\n borderRadius: responsivePropType\n} : {};\nborderRadius.filterProps = ['borderRadius'];\nconst borders = compose(border, borderTop, borderRight, borderBottom, borderLeft, borderColor, borderTopColor, borderRightColor, borderBottomColor, borderLeftColor, borderRadius, outline, outlineColor);\nexport default borders;","import style from './style';\nimport compose from './compose';\nimport { createUnaryUnit, getValue } from './spacing';\nimport { handleBreakpoints } from './breakpoints';\nimport responsivePropType from './responsivePropType';\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const gap = props => {\n if (props.gap !== undefined && props.gap !== null) {\n const transformer = createUnaryUnit(props.theme, 'spacing', 8, 'gap');\n const styleFromPropValue = propValue => ({\n gap: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.gap, styleFromPropValue);\n }\n return null;\n};\ngap.propTypes = process.env.NODE_ENV !== 'production' ? {\n gap: responsivePropType\n} : {};\ngap.filterProps = ['gap'];\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const columnGap = props => {\n if (props.columnGap !== undefined && props.columnGap !== null) {\n const transformer = createUnaryUnit(props.theme, 'spacing', 8, 'columnGap');\n const styleFromPropValue = propValue => ({\n columnGap: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.columnGap, styleFromPropValue);\n }\n return null;\n};\ncolumnGap.propTypes = process.env.NODE_ENV !== 'production' ? {\n columnGap: responsivePropType\n} : {};\ncolumnGap.filterProps = ['columnGap'];\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const rowGap = props => {\n if (props.rowGap !== undefined && props.rowGap !== null) {\n const transformer = createUnaryUnit(props.theme, 'spacing', 8, 'rowGap');\n const styleFromPropValue = propValue => ({\n rowGap: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.rowGap, styleFromPropValue);\n }\n return null;\n};\nrowGap.propTypes = process.env.NODE_ENV !== 'production' ? {\n rowGap: responsivePropType\n} : {};\nrowGap.filterProps = ['rowGap'];\nexport const gridColumn = style({\n prop: 'gridColumn'\n});\nexport const gridRow = style({\n prop: 'gridRow'\n});\nexport const gridAutoFlow = style({\n prop: 'gridAutoFlow'\n});\nexport const gridAutoColumns = style({\n prop: 'gridAutoColumns'\n});\nexport const gridAutoRows = style({\n prop: 'gridAutoRows'\n});\nexport const gridTemplateColumns = style({\n prop: 'gridTemplateColumns'\n});\nexport const gridTemplateRows = style({\n prop: 'gridTemplateRows'\n});\nexport const gridTemplateAreas = style({\n prop: 'gridTemplateAreas'\n});\nexport const gridArea = style({\n prop: 'gridArea'\n});\nconst grid = compose(gap, columnGap, rowGap, gridColumn, gridRow, gridAutoFlow, gridAutoColumns, gridAutoRows, gridTemplateColumns, gridTemplateRows, gridTemplateAreas, gridArea);\nexport default grid;","import style from './style';\nimport compose from './compose';\nexport function paletteTransform(value, userValue) {\n if (userValue === 'grey') {\n return userValue;\n }\n return value;\n}\nexport const color = style({\n prop: 'color',\n themeKey: 'palette',\n transform: paletteTransform\n});\nexport const bgcolor = style({\n prop: 'bgcolor',\n cssProperty: 'backgroundColor',\n themeKey: 'palette',\n transform: paletteTransform\n});\nexport const backgroundColor = style({\n prop: 'backgroundColor',\n themeKey: 'palette',\n transform: paletteTransform\n});\nconst palette = compose(color, bgcolor, backgroundColor);\nexport default palette;","import style from './style';\nimport compose from './compose';\nimport { handleBreakpoints, values as breakpointsValues } from './breakpoints';\nexport function sizingTransform(value) {\n return value <= 1 && value !== 0 ? `${value * 100}%` : value;\n}\nexport const width = style({\n prop: 'width',\n transform: sizingTransform\n});\nexport const maxWidth = props => {\n if (props.maxWidth !== undefined && props.maxWidth !== null) {\n const styleFromPropValue = propValue => {\n var _props$theme, _props$theme2;\n const breakpoint = ((_props$theme = props.theme) == null || (_props$theme = _props$theme.breakpoints) == null || (_props$theme = _props$theme.values) == null ? void 0 : _props$theme[propValue]) || breakpointsValues[propValue];\n if (!breakpoint) {\n return {\n maxWidth: sizingTransform(propValue)\n };\n }\n if (((_props$theme2 = props.theme) == null || (_props$theme2 = _props$theme2.breakpoints) == null ? void 0 : _props$theme2.unit) !== 'px') {\n return {\n maxWidth: `${breakpoint}${props.theme.breakpoints.unit}`\n };\n }\n return {\n maxWidth: breakpoint\n };\n };\n return handleBreakpoints(props, props.maxWidth, styleFromPropValue);\n }\n return null;\n};\nmaxWidth.filterProps = ['maxWidth'];\nexport const minWidth = style({\n prop: 'minWidth',\n transform: sizingTransform\n});\nexport const height = style({\n prop: 'height',\n transform: sizingTransform\n});\nexport const maxHeight = style({\n prop: 'maxHeight',\n transform: sizingTransform\n});\nexport const minHeight = style({\n prop: 'minHeight',\n transform: sizingTransform\n});\nexport const sizeWidth = style({\n prop: 'size',\n cssProperty: 'width',\n transform: sizingTransform\n});\nexport const sizeHeight = style({\n prop: 'size',\n cssProperty: 'height',\n transform: sizingTransform\n});\nexport const boxSizing = style({\n prop: 'boxSizing'\n});\nconst sizing = compose(width, maxWidth, minWidth, height, maxHeight, minHeight, boxSizing);\nexport default sizing;","import { padding, margin } from '../spacing';\nimport { borderRadius, borderTransform } from '../borders';\nimport { gap, rowGap, columnGap } from '../cssGrid';\nimport { paletteTransform } from '../palette';\nimport { maxWidth, sizingTransform } from '../sizing';\nconst defaultSxConfig = {\n // borders\n border: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderTop: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderRight: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderBottom: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderLeft: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderColor: {\n themeKey: 'palette'\n },\n borderTopColor: {\n themeKey: 'palette'\n },\n borderRightColor: {\n themeKey: 'palette'\n },\n borderBottomColor: {\n themeKey: 'palette'\n },\n borderLeftColor: {\n themeKey: 'palette'\n },\n outline: {\n themeKey: 'borders',\n transform: borderTransform\n },\n outlineColor: {\n themeKey: 'palette'\n },\n borderRadius: {\n themeKey: 'shape.borderRadius',\n style: borderRadius\n },\n // palette\n color: {\n themeKey: 'palette',\n transform: paletteTransform\n },\n bgcolor: {\n themeKey: 'palette',\n cssProperty: 'backgroundColor',\n transform: paletteTransform\n },\n backgroundColor: {\n themeKey: 'palette',\n transform: paletteTransform\n },\n // spacing\n p: {\n style: padding\n },\n pt: {\n style: padding\n },\n pr: {\n style: padding\n },\n pb: {\n style: padding\n },\n pl: {\n style: padding\n },\n px: {\n style: padding\n },\n py: {\n style: padding\n },\n padding: {\n style: padding\n },\n paddingTop: {\n style: padding\n },\n paddingRight: {\n style: padding\n },\n paddingBottom: {\n style: padding\n },\n paddingLeft: {\n style: padding\n },\n paddingX: {\n style: padding\n },\n paddingY: {\n style: padding\n },\n paddingInline: {\n style: padding\n },\n paddingInlineStart: {\n style: padding\n },\n paddingInlineEnd: {\n style: padding\n },\n paddingBlock: {\n style: padding\n },\n paddingBlockStart: {\n style: padding\n },\n paddingBlockEnd: {\n style: padding\n },\n m: {\n style: margin\n },\n mt: {\n style: margin\n },\n mr: {\n style: margin\n },\n mb: {\n style: margin\n },\n ml: {\n style: margin\n },\n mx: {\n style: margin\n },\n my: {\n style: margin\n },\n margin: {\n style: margin\n },\n marginTop: {\n style: margin\n },\n marginRight: {\n style: margin\n },\n marginBottom: {\n style: margin\n },\n marginLeft: {\n style: margin\n },\n marginX: {\n style: margin\n },\n marginY: {\n style: margin\n },\n marginInline: {\n style: margin\n },\n marginInlineStart: {\n style: margin\n },\n marginInlineEnd: {\n style: margin\n },\n marginBlock: {\n style: margin\n },\n marginBlockStart: {\n style: margin\n },\n marginBlockEnd: {\n style: margin\n },\n // display\n displayPrint: {\n cssProperty: false,\n transform: value => ({\n '@media print': {\n display: value\n }\n })\n },\n display: {},\n overflow: {},\n textOverflow: {},\n visibility: {},\n whiteSpace: {},\n // flexbox\n flexBasis: {},\n flexDirection: {},\n flexWrap: {},\n justifyContent: {},\n alignItems: {},\n alignContent: {},\n order: {},\n flex: {},\n flexGrow: {},\n flexShrink: {},\n alignSelf: {},\n justifyItems: {},\n justifySelf: {},\n // grid\n gap: {\n style: gap\n },\n rowGap: {\n style: rowGap\n },\n columnGap: {\n style: columnGap\n },\n gridColumn: {},\n gridRow: {},\n gridAutoFlow: {},\n gridAutoColumns: {},\n gridAutoRows: {},\n gridTemplateColumns: {},\n gridTemplateRows: {},\n gridTemplateAreas: {},\n gridArea: {},\n // positions\n position: {},\n zIndex: {\n themeKey: 'zIndex'\n },\n top: {},\n right: {},\n bottom: {},\n left: {},\n // shadows\n boxShadow: {\n themeKey: 'shadows'\n },\n // sizing\n width: {\n transform: sizingTransform\n },\n maxWidth: {\n style: maxWidth\n },\n minWidth: {\n transform: sizingTransform\n },\n height: {\n transform: sizingTransform\n },\n maxHeight: {\n transform: sizingTransform\n },\n minHeight: {\n transform: sizingTransform\n },\n boxSizing: {},\n // typography\n fontFamily: {\n themeKey: 'typography'\n },\n fontSize: {\n themeKey: 'typography'\n },\n fontStyle: {\n themeKey: 'typography'\n },\n fontWeight: {\n themeKey: 'typography'\n },\n letterSpacing: {},\n textTransform: {},\n lineHeight: {},\n textAlign: {},\n typography: {\n cssProperty: false,\n themeKey: 'typography'\n }\n};\nexport default defaultSxConfig;","import capitalize from '@mui/utils/capitalize';\nimport merge from '../merge';\nimport { getPath, getStyleValue as getValue } from '../style';\nimport { handleBreakpoints, createEmptyBreakpointObject, removeUnusedBreakpoints } from '../breakpoints';\nimport defaultSxConfig from './defaultSxConfig';\nfunction objectsHaveSameKeys(...objects) {\n const allKeys = objects.reduce((keys, object) => keys.concat(Object.keys(object)), []);\n const union = new Set(allKeys);\n return objects.every(object => union.size === Object.keys(object).length);\n}\nfunction callIfFn(maybeFn, arg) {\n return typeof maybeFn === 'function' ? maybeFn(arg) : maybeFn;\n}\n\n// eslint-disable-next-line @typescript-eslint/naming-convention\nexport function unstable_createStyleFunctionSx() {\n function getThemeValue(prop, val, theme, config) {\n const props = {\n [prop]: val,\n theme\n };\n const options = config[prop];\n if (!options) {\n return {\n [prop]: val\n };\n }\n const {\n cssProperty = prop,\n themeKey,\n transform,\n style\n } = options;\n if (val == null) {\n return null;\n }\n\n // TODO v6: remove, see https://github.com/mui/material-ui/pull/38123\n if (themeKey === 'typography' && val === 'inherit') {\n return {\n [prop]: val\n };\n }\n const themeMapping = getPath(theme, themeKey) || {};\n if (style) {\n return style(props);\n }\n const styleFromPropValue = propValueFinal => {\n let value = getValue(themeMapping, transform, propValueFinal);\n if (propValueFinal === value && typeof propValueFinal === 'string') {\n // Haven't found value\n value = getValue(themeMapping, transform, `${prop}${propValueFinal === 'default' ? '' : capitalize(propValueFinal)}`, propValueFinal);\n }\n if (cssProperty === false) {\n return value;\n }\n return {\n [cssProperty]: value\n };\n };\n return handleBreakpoints(props, val, styleFromPropValue);\n }\n function styleFunctionSx(props) {\n var _theme$unstable_sxCon;\n const {\n sx,\n theme = {}\n } = props || {};\n if (!sx) {\n return null; // Emotion & styled-components will neglect null\n }\n const config = (_theme$unstable_sxCon = theme.unstable_sxConfig) != null ? _theme$unstable_sxCon : defaultSxConfig;\n\n /*\n * Receive `sxInput` as object or callback\n * and then recursively check keys & values to create media query object styles.\n * (the result will be used in `styled`)\n */\n function traverse(sxInput) {\n let sxObject = sxInput;\n if (typeof sxInput === 'function') {\n sxObject = sxInput(theme);\n } else if (typeof sxInput !== 'object') {\n // value\n return sxInput;\n }\n if (!sxObject) {\n return null;\n }\n const emptyBreakpoints = createEmptyBreakpointObject(theme.breakpoints);\n const breakpointsKeys = Object.keys(emptyBreakpoints);\n let css = emptyBreakpoints;\n Object.keys(sxObject).forEach(styleKey => {\n const value = callIfFn(sxObject[styleKey], theme);\n if (value !== null && value !== undefined) {\n if (typeof value === 'object') {\n if (config[styleKey]) {\n css = merge(css, getThemeValue(styleKey, value, theme, config));\n } else {\n const breakpointsValues = handleBreakpoints({\n theme\n }, value, x => ({\n [styleKey]: x\n }));\n if (objectsHaveSameKeys(breakpointsValues, value)) {\n css[styleKey] = styleFunctionSx({\n sx: value,\n theme\n });\n } else {\n css = merge(css, breakpointsValues);\n }\n }\n } else {\n css = merge(css, getThemeValue(styleKey, value, theme, config));\n }\n }\n });\n return removeUnusedBreakpoints(breakpointsKeys, css);\n }\n return Array.isArray(sx) ? sx.map(traverse) : traverse(sx);\n }\n return styleFunctionSx;\n}\nconst styleFunctionSx = unstable_createStyleFunctionSx();\nstyleFunctionSx.filterProps = ['sx'];\nexport default styleFunctionSx;","/**\n * A universal utility to style components with multiple color modes. Always use it from the theme object.\n * It works with:\n * - [Basic theme](https://mui.com/material-ui/customization/dark-mode/)\n * - [CSS theme variables](https://mui.com/material-ui/experimental-api/css-theme-variables/overview/)\n * - Zero-runtime engine\n *\n * Tips: Use an array over object spread and place `theme.applyStyles()` last.\n *\n * ✅ [{ background: '#e5e5e5' }, theme.applyStyles('dark', { background: '#1c1c1c' })]\n *\n * 🚫 { background: '#e5e5e5', ...theme.applyStyles('dark', { background: '#1c1c1c' })}\n *\n * @example\n * 1. using with `styled`:\n * ```jsx\n * const Component = styled('div')(({ theme }) => [\n * { background: '#e5e5e5' },\n * theme.applyStyles('dark', {\n * background: '#1c1c1c',\n * color: '#fff',\n * }),\n * ]);\n * ```\n *\n * @example\n * 2. using with `sx` prop:\n * ```jsx\n * [\n * { background: '#e5e5e5' },\n * theme.applyStyles('dark', {\n * background: '#1c1c1c',\n * color: '#fff',\n * }),\n * ]}\n * />\n * ```\n *\n * @example\n * 3. theming a component:\n * ```jsx\n * extendTheme({\n * components: {\n * MuiButton: {\n * styleOverrides: {\n * root: ({ theme }) => [\n * { background: '#e5e5e5' },\n * theme.applyStyles('dark', {\n * background: '#1c1c1c',\n * color: '#fff',\n * }),\n * ],\n * },\n * }\n * }\n * })\n *```\n */\nexport default function applyStyles(key, styles) {\n // @ts-expect-error this is 'any' type\n const theme = this;\n if (theme.vars && typeof theme.getColorSchemeSelector === 'function') {\n // If CssVarsProvider is used as a provider,\n // returns '* :where([data-mui-color-scheme=\"light|dark\"]) &'\n const selector = theme.getColorSchemeSelector(key).replace(/(\\[[^\\]]+\\])/, '*:where($1)');\n return {\n [selector]: styles\n };\n }\n if (theme.palette.mode === key) {\n return styles;\n }\n return {};\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"breakpoints\", \"palette\", \"spacing\", \"shape\"];\nimport deepmerge from '@mui/utils/deepmerge';\nimport createBreakpoints from './createBreakpoints';\nimport shape from './shape';\nimport createSpacing from './createSpacing';\nimport styleFunctionSx from '../styleFunctionSx/styleFunctionSx';\nimport defaultSxConfig from '../styleFunctionSx/defaultSxConfig';\nimport applyStyles from './applyStyles';\nfunction createTheme(options = {}, ...args) {\n const {\n breakpoints: breakpointsInput = {},\n palette: paletteInput = {},\n spacing: spacingInput,\n shape: shapeInput = {}\n } = options,\n other = _objectWithoutPropertiesLoose(options, _excluded);\n const breakpoints = createBreakpoints(breakpointsInput);\n const spacing = createSpacing(spacingInput);\n let muiTheme = deepmerge({\n breakpoints,\n direction: 'ltr',\n components: {},\n // Inject component definitions.\n palette: _extends({\n mode: 'light'\n }, paletteInput),\n spacing,\n shape: _extends({}, shape, shapeInput)\n }, other);\n muiTheme.applyStyles = applyStyles;\n muiTheme = args.reduce((acc, argument) => deepmerge(acc, argument), muiTheme);\n muiTheme.unstable_sxConfig = _extends({}, defaultSxConfig, other == null ? void 0 : other.unstable_sxConfig);\n muiTheme.unstable_sx = function sx(props) {\n return styleFunctionSx({\n sx: props,\n theme: this\n });\n };\n return muiTheme;\n}\nexport default createTheme;","'use client';\n\nimport * as React from 'react';\nimport { ThemeContext } from '@mui/styled-engine';\nfunction isObjectEmpty(obj) {\n return Object.keys(obj).length === 0;\n}\nfunction useTheme(defaultTheme = null) {\n const contextTheme = React.useContext(ThemeContext);\n return !contextTheme || isObjectEmpty(contextTheme) ? defaultTheme : contextTheme;\n}\nexport default useTheme;","'use client';\n\nimport createTheme from './createTheme';\nimport useThemeWithoutDefault from './useThemeWithoutDefault';\nexport const systemDefaultTheme = createTheme();\nfunction useTheme(defaultTheme = systemDefaultTheme) {\n return useThemeWithoutDefault(defaultTheme);\n}\nexport default useTheme;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"ownerState\"],\n _excluded2 = [\"variants\"],\n _excluded3 = [\"name\", \"slot\", \"skipVariantsResolver\", \"skipSx\", \"overridesResolver\"];\n/* eslint-disable no-underscore-dangle */\nimport styledEngineStyled, { internal_processStyles as processStyles } from '@mui/styled-engine';\nimport { isPlainObject } from '@mui/utils/deepmerge';\nimport capitalize from '@mui/utils/capitalize';\nimport getDisplayName from '@mui/utils/getDisplayName';\nimport createTheme from './createTheme';\nimport styleFunctionSx from './styleFunctionSx';\nfunction isEmpty(obj) {\n return Object.keys(obj).length === 0;\n}\n\n// https://github.com/emotion-js/emotion/blob/26ded6109fcd8ca9875cc2ce4564fee678a3f3c5/packages/styled/src/utils.js#L40\nfunction isStringTag(tag) {\n return typeof tag === 'string' &&\n // 96 is one less than the char code\n // for \"a\" so this is checking that\n // it's a lowercase character\n tag.charCodeAt(0) > 96;\n}\n\n// Update /system/styled/#api in case if this changes\nexport function shouldForwardProp(prop) {\n return prop !== 'ownerState' && prop !== 'theme' && prop !== 'sx' && prop !== 'as';\n}\nexport const systemDefaultTheme = createTheme();\nconst lowercaseFirstLetter = string => {\n if (!string) {\n return string;\n }\n return string.charAt(0).toLowerCase() + string.slice(1);\n};\nfunction resolveTheme({\n defaultTheme,\n theme,\n themeId\n}) {\n return isEmpty(theme) ? defaultTheme : theme[themeId] || theme;\n}\nfunction defaultOverridesResolver(slot) {\n if (!slot) {\n return null;\n }\n return (props, styles) => styles[slot];\n}\nfunction processStyleArg(callableStyle, _ref) {\n let {\n ownerState\n } = _ref,\n props = _objectWithoutPropertiesLoose(_ref, _excluded);\n const resolvedStylesArg = typeof callableStyle === 'function' ? callableStyle(_extends({\n ownerState\n }, props)) : callableStyle;\n if (Array.isArray(resolvedStylesArg)) {\n return resolvedStylesArg.flatMap(resolvedStyle => processStyleArg(resolvedStyle, _extends({\n ownerState\n }, props)));\n }\n if (!!resolvedStylesArg && typeof resolvedStylesArg === 'object' && Array.isArray(resolvedStylesArg.variants)) {\n const {\n variants = []\n } = resolvedStylesArg,\n otherStyles = _objectWithoutPropertiesLoose(resolvedStylesArg, _excluded2);\n let result = otherStyles;\n variants.forEach(variant => {\n let isMatch = true;\n if (typeof variant.props === 'function') {\n isMatch = variant.props(_extends({\n ownerState\n }, props, ownerState));\n } else {\n Object.keys(variant.props).forEach(key => {\n if ((ownerState == null ? void 0 : ownerState[key]) !== variant.props[key] && props[key] !== variant.props[key]) {\n isMatch = false;\n }\n });\n }\n if (isMatch) {\n if (!Array.isArray(result)) {\n result = [result];\n }\n result.push(typeof variant.style === 'function' ? variant.style(_extends({\n ownerState\n }, props, ownerState)) : variant.style);\n }\n });\n return result;\n }\n return resolvedStylesArg;\n}\nexport default function createStyled(input = {}) {\n const {\n themeId,\n defaultTheme = systemDefaultTheme,\n rootShouldForwardProp = shouldForwardProp,\n slotShouldForwardProp = shouldForwardProp\n } = input;\n const systemSx = props => {\n return styleFunctionSx(_extends({}, props, {\n theme: resolveTheme(_extends({}, props, {\n defaultTheme,\n themeId\n }))\n }));\n };\n systemSx.__mui_systemSx = true;\n return (tag, inputOptions = {}) => {\n // Filter out the `sx` style function from the previous styled component to prevent unnecessary styles generated by the composite components.\n processStyles(tag, styles => styles.filter(style => !(style != null && style.__mui_systemSx)));\n const {\n name: componentName,\n slot: componentSlot,\n skipVariantsResolver: inputSkipVariantsResolver,\n skipSx: inputSkipSx,\n // TODO v6: remove `lowercaseFirstLetter()` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n overridesResolver = defaultOverridesResolver(lowercaseFirstLetter(componentSlot))\n } = inputOptions,\n options = _objectWithoutPropertiesLoose(inputOptions, _excluded3);\n\n // if skipVariantsResolver option is defined, take the value, otherwise, true for root and false for other slots.\n const skipVariantsResolver = inputSkipVariantsResolver !== undefined ? inputSkipVariantsResolver :\n // TODO v6: remove `Root` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n componentSlot && componentSlot !== 'Root' && componentSlot !== 'root' || false;\n const skipSx = inputSkipSx || false;\n let label;\n if (process.env.NODE_ENV !== 'production') {\n if (componentName) {\n // TODO v6: remove `lowercaseFirstLetter()` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n label = `${componentName}-${lowercaseFirstLetter(componentSlot || 'Root')}`;\n }\n }\n let shouldForwardPropOption = shouldForwardProp;\n\n // TODO v6: remove `Root` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n if (componentSlot === 'Root' || componentSlot === 'root') {\n shouldForwardPropOption = rootShouldForwardProp;\n } else if (componentSlot) {\n // any other slot specified\n shouldForwardPropOption = slotShouldForwardProp;\n } else if (isStringTag(tag)) {\n // for string (html) tag, preserve the behavior in emotion & styled-components.\n shouldForwardPropOption = undefined;\n }\n const defaultStyledResolver = styledEngineStyled(tag, _extends({\n shouldForwardProp: shouldForwardPropOption,\n label\n }, options));\n const transformStyleArg = stylesArg => {\n // On the server Emotion doesn't use React.forwardRef for creating components, so the created\n // component stays as a function. This condition makes sure that we do not interpolate functions\n // which are basically components used as a selectors.\n if (typeof stylesArg === 'function' && stylesArg.__emotion_real !== stylesArg || isPlainObject(stylesArg)) {\n return props => processStyleArg(stylesArg, _extends({}, props, {\n theme: resolveTheme({\n theme: props.theme,\n defaultTheme,\n themeId\n })\n }));\n }\n return stylesArg;\n };\n const muiStyledResolver = (styleArg, ...expressions) => {\n let transformedStyleArg = transformStyleArg(styleArg);\n const expressionsWithDefaultTheme = expressions ? expressions.map(transformStyleArg) : [];\n if (componentName && overridesResolver) {\n expressionsWithDefaultTheme.push(props => {\n const theme = resolveTheme(_extends({}, props, {\n defaultTheme,\n themeId\n }));\n if (!theme.components || !theme.components[componentName] || !theme.components[componentName].styleOverrides) {\n return null;\n }\n const styleOverrides = theme.components[componentName].styleOverrides;\n const resolvedStyleOverrides = {};\n // TODO: v7 remove iteration and use `resolveStyleArg(styleOverrides[slot])` directly\n Object.entries(styleOverrides).forEach(([slotKey, slotStyle]) => {\n resolvedStyleOverrides[slotKey] = processStyleArg(slotStyle, _extends({}, props, {\n theme\n }));\n });\n return overridesResolver(props, resolvedStyleOverrides);\n });\n }\n if (componentName && !skipVariantsResolver) {\n expressionsWithDefaultTheme.push(props => {\n var _theme$components;\n const theme = resolveTheme(_extends({}, props, {\n defaultTheme,\n themeId\n }));\n const themeVariants = theme == null || (_theme$components = theme.components) == null || (_theme$components = _theme$components[componentName]) == null ? void 0 : _theme$components.variants;\n return processStyleArg({\n variants: themeVariants\n }, _extends({}, props, {\n theme\n }));\n });\n }\n if (!skipSx) {\n expressionsWithDefaultTheme.push(systemSx);\n }\n const numOfCustomFnsApplied = expressionsWithDefaultTheme.length - expressions.length;\n if (Array.isArray(styleArg) && numOfCustomFnsApplied > 0) {\n const placeholders = new Array(numOfCustomFnsApplied).fill('');\n // If the type is array, than we need to add placeholders in the template for the overrides, variants and the sx styles.\n transformedStyleArg = [...styleArg, ...placeholders];\n transformedStyleArg.raw = [...styleArg.raw, ...placeholders];\n }\n const Component = defaultStyledResolver(transformedStyleArg, ...expressionsWithDefaultTheme);\n if (process.env.NODE_ENV !== 'production') {\n let displayName;\n if (componentName) {\n displayName = `${componentName}${capitalize(componentSlot || '')}`;\n }\n if (displayName === undefined) {\n displayName = `Styled(${getDisplayName(tag)})`;\n }\n Component.displayName = displayName;\n }\n if (tag.muiName) {\n Component.muiName = tag.muiName;\n }\n return Component;\n };\n if (defaultStyledResolver.withConfig) {\n muiStyledResolver.withConfig = defaultStyledResolver.withConfig;\n }\n return muiStyledResolver;\n };\n}","import resolveProps from '@mui/utils/resolveProps';\nexport default function getThemeProps(params) {\n const {\n theme,\n name,\n props\n } = params;\n if (!theme || !theme.components || !theme.components[name] || !theme.components[name].defaultProps) {\n return props;\n }\n return resolveProps(theme.components[name].defaultProps, props);\n}","'use client';\n\nimport getThemeProps from './getThemeProps';\nimport useTheme from '../useTheme';\nexport default function useThemeProps({\n props,\n name,\n defaultTheme,\n themeId\n}) {\n let theme = useTheme(defaultTheme);\n if (themeId) {\n theme = theme[themeId] || theme;\n }\n const mergedProps = getThemeProps({\n theme,\n name,\n props\n });\n return mergedProps;\n}","import _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\n/* eslint-disable @typescript-eslint/naming-convention */\nimport clamp from '@mui/utils/clamp';\n/**\n * Returns a number whose value is limited to the given range.\n * @param {number} value The value to be clamped\n * @param {number} min The lower boundary of the output range\n * @param {number} max The upper boundary of the output range\n * @returns {number} A number in the range [min, max]\n */\nfunction clampWrapper(value, min = 0, max = 1) {\n if (process.env.NODE_ENV !== 'production') {\n if (value < min || value > max) {\n console.error(`MUI: The value provided ${value} is out of range [${min}, ${max}].`);\n }\n }\n return clamp(value, min, max);\n}\n\n/**\n * Converts a color from CSS hex format to CSS rgb format.\n * @param {string} color - Hex color, i.e. #nnn or #nnnnnn\n * @returns {string} A CSS rgb color string\n */\nexport function hexToRgb(color) {\n color = color.slice(1);\n const re = new RegExp(`.{1,${color.length >= 6 ? 2 : 1}}`, 'g');\n let colors = color.match(re);\n if (colors && colors[0].length === 1) {\n colors = colors.map(n => n + n);\n }\n return colors ? `rgb${colors.length === 4 ? 'a' : ''}(${colors.map((n, index) => {\n return index < 3 ? parseInt(n, 16) : Math.round(parseInt(n, 16) / 255 * 1000) / 1000;\n }).join(', ')})` : '';\n}\nfunction intToHex(int) {\n const hex = int.toString(16);\n return hex.length === 1 ? `0${hex}` : hex;\n}\n\n/**\n * Returns an object with the type and values of a color.\n *\n * Note: Does not support rgb % values.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @returns {object} - A MUI color object: {type: string, values: number[]}\n */\nexport function decomposeColor(color) {\n // Idempotent\n if (color.type) {\n return color;\n }\n if (color.charAt(0) === '#') {\n return decomposeColor(hexToRgb(color));\n }\n const marker = color.indexOf('(');\n const type = color.substring(0, marker);\n if (['rgb', 'rgba', 'hsl', 'hsla', 'color'].indexOf(type) === -1) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: Unsupported \\`${color}\\` color.\nThe following formats are supported: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color().` : _formatMuiErrorMessage(9, color));\n }\n let values = color.substring(marker + 1, color.length - 1);\n let colorSpace;\n if (type === 'color') {\n values = values.split(' ');\n colorSpace = values.shift();\n if (values.length === 4 && values[3].charAt(0) === '/') {\n values[3] = values[3].slice(1);\n }\n if (['srgb', 'display-p3', 'a98-rgb', 'prophoto-rgb', 'rec-2020'].indexOf(colorSpace) === -1) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: unsupported \\`${colorSpace}\\` color space.\nThe following color spaces are supported: srgb, display-p3, a98-rgb, prophoto-rgb, rec-2020.` : _formatMuiErrorMessage(10, colorSpace));\n }\n } else {\n values = values.split(',');\n }\n values = values.map(value => parseFloat(value));\n return {\n type,\n values,\n colorSpace\n };\n}\n\n/**\n * Returns a channel created from the input color.\n *\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @returns {string} - The channel for the color, that can be used in rgba or hsla colors\n */\nexport const colorChannel = color => {\n const decomposedColor = decomposeColor(color);\n return decomposedColor.values.slice(0, 3).map((val, idx) => decomposedColor.type.indexOf('hsl') !== -1 && idx !== 0 ? `${val}%` : val).join(' ');\n};\nexport const private_safeColorChannel = (color, warning) => {\n try {\n return colorChannel(color);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n};\n\n/**\n * Converts a color object with type and values to a string.\n * @param {object} color - Decomposed color\n * @param {string} color.type - One of: 'rgb', 'rgba', 'hsl', 'hsla', 'color'\n * @param {array} color.values - [n,n,n] or [n,n,n,n]\n * @returns {string} A CSS color string\n */\nexport function recomposeColor(color) {\n const {\n type,\n colorSpace\n } = color;\n let {\n values\n } = color;\n if (type.indexOf('rgb') !== -1) {\n // Only convert the first 3 values to int (i.e. not alpha)\n values = values.map((n, i) => i < 3 ? parseInt(n, 10) : n);\n } else if (type.indexOf('hsl') !== -1) {\n values[1] = `${values[1]}%`;\n values[2] = `${values[2]}%`;\n }\n if (type.indexOf('color') !== -1) {\n values = `${colorSpace} ${values.join(' ')}`;\n } else {\n values = `${values.join(', ')}`;\n }\n return `${type}(${values})`;\n}\n\n/**\n * Converts a color from CSS rgb format to CSS hex format.\n * @param {string} color - RGB color, i.e. rgb(n, n, n)\n * @returns {string} A CSS rgb color string, i.e. #nnnnnn\n */\nexport function rgbToHex(color) {\n // Idempotent\n if (color.indexOf('#') === 0) {\n return color;\n }\n const {\n values\n } = decomposeColor(color);\n return `#${values.map((n, i) => intToHex(i === 3 ? Math.round(255 * n) : n)).join('')}`;\n}\n\n/**\n * Converts a color from hsl format to rgb format.\n * @param {string} color - HSL color values\n * @returns {string} rgb color values\n */\nexport function hslToRgb(color) {\n color = decomposeColor(color);\n const {\n values\n } = color;\n const h = values[0];\n const s = values[1] / 100;\n const l = values[2] / 100;\n const a = s * Math.min(l, 1 - l);\n const f = (n, k = (n + h / 30) % 12) => l - a * Math.max(Math.min(k - 3, 9 - k, 1), -1);\n let type = 'rgb';\n const rgb = [Math.round(f(0) * 255), Math.round(f(8) * 255), Math.round(f(4) * 255)];\n if (color.type === 'hsla') {\n type += 'a';\n rgb.push(values[3]);\n }\n return recomposeColor({\n type,\n values: rgb\n });\n}\n/**\n * The relative brightness of any point in a color space,\n * normalized to 0 for darkest black and 1 for lightest white.\n *\n * Formula: https://www.w3.org/TR/WCAG20-TECHS/G17.html#G17-tests\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @returns {number} The relative brightness of the color in the range 0 - 1\n */\nexport function getLuminance(color) {\n color = decomposeColor(color);\n let rgb = color.type === 'hsl' || color.type === 'hsla' ? decomposeColor(hslToRgb(color)).values : color.values;\n rgb = rgb.map(val => {\n if (color.type !== 'color') {\n val /= 255; // normalized\n }\n return val <= 0.03928 ? val / 12.92 : ((val + 0.055) / 1.055) ** 2.4;\n });\n\n // Truncate at 3 digits\n return Number((0.2126 * rgb[0] + 0.7152 * rgb[1] + 0.0722 * rgb[2]).toFixed(3));\n}\n\n/**\n * Calculates the contrast ratio between two colors.\n *\n * Formula: https://www.w3.org/TR/WCAG20-TECHS/G17.html#G17-tests\n * @param {string} foreground - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla()\n * @param {string} background - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla()\n * @returns {number} A contrast ratio value in the range 0 - 21.\n */\nexport function getContrastRatio(foreground, background) {\n const lumA = getLuminance(foreground);\n const lumB = getLuminance(background);\n return (Math.max(lumA, lumB) + 0.05) / (Math.min(lumA, lumB) + 0.05);\n}\n\n/**\n * Sets the absolute transparency of a color.\n * Any existing alpha values are overwritten.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} value - value to set the alpha channel to in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function alpha(color, value) {\n color = decomposeColor(color);\n value = clampWrapper(value);\n if (color.type === 'rgb' || color.type === 'hsl') {\n color.type += 'a';\n }\n if (color.type === 'color') {\n color.values[3] = `/${value}`;\n } else {\n color.values[3] = value;\n }\n return recomposeColor(color);\n}\nexport function private_safeAlpha(color, value, warning) {\n try {\n return alpha(color, value);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Darkens a color.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} coefficient - multiplier in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function darken(color, coefficient) {\n color = decomposeColor(color);\n coefficient = clampWrapper(coefficient);\n if (color.type.indexOf('hsl') !== -1) {\n color.values[2] *= 1 - coefficient;\n } else if (color.type.indexOf('rgb') !== -1 || color.type.indexOf('color') !== -1) {\n for (let i = 0; i < 3; i += 1) {\n color.values[i] *= 1 - coefficient;\n }\n }\n return recomposeColor(color);\n}\nexport function private_safeDarken(color, coefficient, warning) {\n try {\n return darken(color, coefficient);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Lightens a color.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} coefficient - multiplier in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function lighten(color, coefficient) {\n color = decomposeColor(color);\n coefficient = clampWrapper(coefficient);\n if (color.type.indexOf('hsl') !== -1) {\n color.values[2] += (100 - color.values[2]) * coefficient;\n } else if (color.type.indexOf('rgb') !== -1) {\n for (let i = 0; i < 3; i += 1) {\n color.values[i] += (255 - color.values[i]) * coefficient;\n }\n } else if (color.type.indexOf('color') !== -1) {\n for (let i = 0; i < 3; i += 1) {\n color.values[i] += (1 - color.values[i]) * coefficient;\n }\n }\n return recomposeColor(color);\n}\nexport function private_safeLighten(color, coefficient, warning) {\n try {\n return lighten(color, coefficient);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Darken or lighten a color, depending on its luminance.\n * Light colors are darkened, dark colors are lightened.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} coefficient=0.15 - multiplier in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function emphasize(color, coefficient = 0.15) {\n return getLuminance(color) > 0.5 ? darken(color, coefficient) : lighten(color, coefficient);\n}\nexport function private_safeEmphasize(color, coefficient, warning) {\n try {\n return emphasize(color, coefficient);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Blend a transparent overlay color with a background color, resulting in a single\n * RGB color.\n * @param {string} background - CSS color\n * @param {string} overlay - CSS color\n * @param {number} opacity - Opacity multiplier in the range 0 - 1\n * @param {number} [gamma=1.0] - Gamma correction factor. For gamma-correct blending, 2.2 is usual.\n */\nexport function blend(background, overlay, opacity, gamma = 1.0) {\n const blendChannel = (b, o) => Math.round((b ** (1 / gamma) * (1 - opacity) + o ** (1 / gamma) * opacity) ** gamma);\n const backgroundColor = decomposeColor(background);\n const overlayColor = decomposeColor(overlay);\n const rgb = [blendChannel(backgroundColor.values[0], overlayColor.values[0]), blendChannel(backgroundColor.values[1], overlayColor.values[1]), blendChannel(backgroundColor.values[2], overlayColor.values[2])];\n return recomposeColor({\n type: 'rgb',\n values: rgb\n });\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nexport default function createMixins(breakpoints, mixins) {\n return _extends({\n toolbar: {\n minHeight: 56,\n [breakpoints.up('xs')]: {\n '@media (orientation: landscape)': {\n minHeight: 48\n }\n },\n [breakpoints.up('sm')]: {\n minHeight: 64\n }\n }\n }, mixins);\n}","const common = {\n black: '#000',\n white: '#fff'\n};\nexport default common;","const grey = {\n 50: '#fafafa',\n 100: '#f5f5f5',\n 200: '#eeeeee',\n 300: '#e0e0e0',\n 400: '#bdbdbd',\n 500: '#9e9e9e',\n 600: '#757575',\n 700: '#616161',\n 800: '#424242',\n 900: '#212121',\n A100: '#f5f5f5',\n A200: '#eeeeee',\n A400: '#bdbdbd',\n A700: '#616161'\n};\nexport default grey;","const purple = {\n 50: '#f3e5f5',\n 100: '#e1bee7',\n 200: '#ce93d8',\n 300: '#ba68c8',\n 400: '#ab47bc',\n 500: '#9c27b0',\n 600: '#8e24aa',\n 700: '#7b1fa2',\n 800: '#6a1b9a',\n 900: '#4a148c',\n A100: '#ea80fc',\n A200: '#e040fb',\n A400: '#d500f9',\n A700: '#aa00ff'\n};\nexport default purple;","const red = {\n 50: '#ffebee',\n 100: '#ffcdd2',\n 200: '#ef9a9a',\n 300: '#e57373',\n 400: '#ef5350',\n 500: '#f44336',\n 600: '#e53935',\n 700: '#d32f2f',\n 800: '#c62828',\n 900: '#b71c1c',\n A100: '#ff8a80',\n A200: '#ff5252',\n A400: '#ff1744',\n A700: '#d50000'\n};\nexport default red;","const orange = {\n 50: '#fff3e0',\n 100: '#ffe0b2',\n 200: '#ffcc80',\n 300: '#ffb74d',\n 400: '#ffa726',\n 500: '#ff9800',\n 600: '#fb8c00',\n 700: '#f57c00',\n 800: '#ef6c00',\n 900: '#e65100',\n A100: '#ffd180',\n A200: '#ffab40',\n A400: '#ff9100',\n A700: '#ff6d00'\n};\nexport default orange;","const blue = {\n 50: '#e3f2fd',\n 100: '#bbdefb',\n 200: '#90caf9',\n 300: '#64b5f6',\n 400: '#42a5f5',\n 500: '#2196f3',\n 600: '#1e88e5',\n 700: '#1976d2',\n 800: '#1565c0',\n 900: '#0d47a1',\n A100: '#82b1ff',\n A200: '#448aff',\n A400: '#2979ff',\n A700: '#2962ff'\n};\nexport default blue;","const lightBlue = {\n 50: '#e1f5fe',\n 100: '#b3e5fc',\n 200: '#81d4fa',\n 300: '#4fc3f7',\n 400: '#29b6f6',\n 500: '#03a9f4',\n 600: '#039be5',\n 700: '#0288d1',\n 800: '#0277bd',\n 900: '#01579b',\n A100: '#80d8ff',\n A200: '#40c4ff',\n A400: '#00b0ff',\n A700: '#0091ea'\n};\nexport default lightBlue;","const green = {\n 50: '#e8f5e9',\n 100: '#c8e6c9',\n 200: '#a5d6a7',\n 300: '#81c784',\n 400: '#66bb6a',\n 500: '#4caf50',\n 600: '#43a047',\n 700: '#388e3c',\n 800: '#2e7d32',\n 900: '#1b5e20',\n A100: '#b9f6ca',\n A200: '#69f0ae',\n A400: '#00e676',\n A700: '#00c853'\n};\nexport default green;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\nconst _excluded = [\"mode\", \"contrastThreshold\", \"tonalOffset\"];\nimport { deepmerge } from '@mui/utils';\nimport { darken, getContrastRatio, lighten } from '@mui/system';\nimport common from '../colors/common';\nimport grey from '../colors/grey';\nimport purple from '../colors/purple';\nimport red from '../colors/red';\nimport orange from '../colors/orange';\nimport blue from '../colors/blue';\nimport lightBlue from '../colors/lightBlue';\nimport green from '../colors/green';\nexport const light = {\n // The colors used to style the text.\n text: {\n // The most important text.\n primary: 'rgba(0, 0, 0, 0.87)',\n // Secondary text.\n secondary: 'rgba(0, 0, 0, 0.6)',\n // Disabled text have even lower visual prominence.\n disabled: 'rgba(0, 0, 0, 0.38)'\n },\n // The color used to divide different elements.\n divider: 'rgba(0, 0, 0, 0.12)',\n // The background colors used to style the surfaces.\n // Consistency between these values is important.\n background: {\n paper: common.white,\n default: common.white\n },\n // The colors used to style the action elements.\n action: {\n // The color of an active action like an icon button.\n active: 'rgba(0, 0, 0, 0.54)',\n // The color of an hovered action.\n hover: 'rgba(0, 0, 0, 0.04)',\n hoverOpacity: 0.04,\n // The color of a selected action.\n selected: 'rgba(0, 0, 0, 0.08)',\n selectedOpacity: 0.08,\n // The color of a disabled action.\n disabled: 'rgba(0, 0, 0, 0.26)',\n // The background color of a disabled action.\n disabledBackground: 'rgba(0, 0, 0, 0.12)',\n disabledOpacity: 0.38,\n focus: 'rgba(0, 0, 0, 0.12)',\n focusOpacity: 0.12,\n activatedOpacity: 0.12\n }\n};\nexport const dark = {\n text: {\n primary: common.white,\n secondary: 'rgba(255, 255, 255, 0.7)',\n disabled: 'rgba(255, 255, 255, 0.5)',\n icon: 'rgba(255, 255, 255, 0.5)'\n },\n divider: 'rgba(255, 255, 255, 0.12)',\n background: {\n paper: '#121212',\n default: '#121212'\n },\n action: {\n active: common.white,\n hover: 'rgba(255, 255, 255, 0.08)',\n hoverOpacity: 0.08,\n selected: 'rgba(255, 255, 255, 0.16)',\n selectedOpacity: 0.16,\n disabled: 'rgba(255, 255, 255, 0.3)',\n disabledBackground: 'rgba(255, 255, 255, 0.12)',\n disabledOpacity: 0.38,\n focus: 'rgba(255, 255, 255, 0.12)',\n focusOpacity: 0.12,\n activatedOpacity: 0.24\n }\n};\nfunction addLightOrDark(intent, direction, shade, tonalOffset) {\n const tonalOffsetLight = tonalOffset.light || tonalOffset;\n const tonalOffsetDark = tonalOffset.dark || tonalOffset * 1.5;\n if (!intent[direction]) {\n if (intent.hasOwnProperty(shade)) {\n intent[direction] = intent[shade];\n } else if (direction === 'light') {\n intent.light = lighten(intent.main, tonalOffsetLight);\n } else if (direction === 'dark') {\n intent.dark = darken(intent.main, tonalOffsetDark);\n }\n }\n}\nfunction getDefaultPrimary(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: blue[200],\n light: blue[50],\n dark: blue[400]\n };\n }\n return {\n main: blue[700],\n light: blue[400],\n dark: blue[800]\n };\n}\nfunction getDefaultSecondary(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: purple[200],\n light: purple[50],\n dark: purple[400]\n };\n }\n return {\n main: purple[500],\n light: purple[300],\n dark: purple[700]\n };\n}\nfunction getDefaultError(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: red[500],\n light: red[300],\n dark: red[700]\n };\n }\n return {\n main: red[700],\n light: red[400],\n dark: red[800]\n };\n}\nfunction getDefaultInfo(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: lightBlue[400],\n light: lightBlue[300],\n dark: lightBlue[700]\n };\n }\n return {\n main: lightBlue[700],\n light: lightBlue[500],\n dark: lightBlue[900]\n };\n}\nfunction getDefaultSuccess(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: green[400],\n light: green[300],\n dark: green[700]\n };\n }\n return {\n main: green[800],\n light: green[500],\n dark: green[900]\n };\n}\nfunction getDefaultWarning(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: orange[400],\n light: orange[300],\n dark: orange[700]\n };\n }\n return {\n main: '#ed6c02',\n // closest to orange[800] that pass 3:1.\n light: orange[500],\n dark: orange[900]\n };\n}\nexport default function createPalette(palette) {\n const {\n mode = 'light',\n contrastThreshold = 3,\n tonalOffset = 0.2\n } = palette,\n other = _objectWithoutPropertiesLoose(palette, _excluded);\n const primary = palette.primary || getDefaultPrimary(mode);\n const secondary = palette.secondary || getDefaultSecondary(mode);\n const error = palette.error || getDefaultError(mode);\n const info = palette.info || getDefaultInfo(mode);\n const success = palette.success || getDefaultSuccess(mode);\n const warning = palette.warning || getDefaultWarning(mode);\n\n // Use the same logic as\n // Bootstrap: https://github.com/twbs/bootstrap/blob/1d6e3710dd447de1a200f29e8fa521f8a0908f70/scss/_functions.scss#L59\n // and material-components-web https://github.com/material-components/material-components-web/blob/ac46b8863c4dab9fc22c4c662dc6bd1b65dd652f/packages/mdc-theme/_functions.scss#L54\n function getContrastText(background) {\n const contrastText = getContrastRatio(background, dark.text.primary) >= contrastThreshold ? dark.text.primary : light.text.primary;\n if (process.env.NODE_ENV !== 'production') {\n const contrast = getContrastRatio(background, contrastText);\n if (contrast < 3) {\n console.error([`MUI: The contrast ratio of ${contrast}:1 for ${contrastText} on ${background}`, 'falls below the WCAG recommended absolute minimum contrast ratio of 3:1.', 'https://www.w3.org/TR/2008/REC-WCAG20-20081211/#visual-audio-contrast-contrast'].join('\\n'));\n }\n }\n return contrastText;\n }\n const augmentColor = ({\n color,\n name,\n mainShade = 500,\n lightShade = 300,\n darkShade = 700\n }) => {\n color = _extends({}, color);\n if (!color.main && color[mainShade]) {\n color.main = color[mainShade];\n }\n if (!color.hasOwnProperty('main')) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: The color${name ? ` (${name})` : ''} provided to augmentColor(color) is invalid.\nThe color object needs to have a \\`main\\` property or a \\`${mainShade}\\` property.` : _formatMuiErrorMessage(11, name ? ` (${name})` : '', mainShade));\n }\n if (typeof color.main !== 'string') {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: The color${name ? ` (${name})` : ''} provided to augmentColor(color) is invalid.\n\\`color.main\\` should be a string, but \\`${JSON.stringify(color.main)}\\` was provided instead.\n\nDid you intend to use one of the following approaches?\n\nimport { green } from \"@mui/material/colors\";\n\nconst theme1 = createTheme({ palette: {\n primary: green,\n} });\n\nconst theme2 = createTheme({ palette: {\n primary: { main: green[500] },\n} });` : _formatMuiErrorMessage(12, name ? ` (${name})` : '', JSON.stringify(color.main)));\n }\n addLightOrDark(color, 'light', lightShade, tonalOffset);\n addLightOrDark(color, 'dark', darkShade, tonalOffset);\n if (!color.contrastText) {\n color.contrastText = getContrastText(color.main);\n }\n return color;\n };\n const modes = {\n dark,\n light\n };\n if (process.env.NODE_ENV !== 'production') {\n if (!modes[mode]) {\n console.error(`MUI: The palette mode \\`${mode}\\` is not supported.`);\n }\n }\n const paletteOutput = deepmerge(_extends({\n // A collection of common colors.\n common: _extends({}, common),\n // prevent mutable object.\n // The palette mode, can be light or dark.\n mode,\n // The colors used to represent primary interface elements for a user.\n primary: augmentColor({\n color: primary,\n name: 'primary'\n }),\n // The colors used to represent secondary interface elements for a user.\n secondary: augmentColor({\n color: secondary,\n name: 'secondary',\n mainShade: 'A400',\n lightShade: 'A200',\n darkShade: 'A700'\n }),\n // The colors used to represent interface elements that the user should be made aware of.\n error: augmentColor({\n color: error,\n name: 'error'\n }),\n // The colors used to represent potentially dangerous actions or important messages.\n warning: augmentColor({\n color: warning,\n name: 'warning'\n }),\n // The colors used to present information to the user that is neutral and not necessarily important.\n info: augmentColor({\n color: info,\n name: 'info'\n }),\n // The colors used to indicate the successful completion of an action that user triggered.\n success: augmentColor({\n color: success,\n name: 'success'\n }),\n // The grey colors.\n grey,\n // Used by `getContrastText()` to maximize the contrast between\n // the background and the text.\n contrastThreshold,\n // Takes a background color and returns the text color that maximizes the contrast.\n getContrastText,\n // Generate a rich color object.\n augmentColor,\n // Used by the functions below to shift a color's luminance by approximately\n // two indexes within its tonal palette.\n // E.g., shift from Red 500 to Red 300 or Red 700.\n tonalOffset\n }, modes[mode]), other);\n return paletteOutput;\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"fontFamily\", \"fontSize\", \"fontWeightLight\", \"fontWeightRegular\", \"fontWeightMedium\", \"fontWeightBold\", \"htmlFontSize\", \"allVariants\", \"pxToRem\"];\nimport { deepmerge } from '@mui/utils';\nfunction round(value) {\n return Math.round(value * 1e5) / 1e5;\n}\nconst caseAllCaps = {\n textTransform: 'uppercase'\n};\nconst defaultFontFamily = '\"Roboto\", \"Helvetica\", \"Arial\", sans-serif';\n\n/**\n * @see @link{https://m2.material.io/design/typography/the-type-system.html}\n * @see @link{https://m2.material.io/design/typography/understanding-typography.html}\n */\nexport default function createTypography(palette, typography) {\n const _ref = typeof typography === 'function' ? typography(palette) : typography,\n {\n fontFamily = defaultFontFamily,\n // The default font size of the Material Specification.\n fontSize = 14,\n // px\n fontWeightLight = 300,\n fontWeightRegular = 400,\n fontWeightMedium = 500,\n fontWeightBold = 700,\n // Tell MUI what's the font-size on the html element.\n // 16px is the default font-size used by browsers.\n htmlFontSize = 16,\n // Apply the CSS properties to all the variants.\n allVariants,\n pxToRem: pxToRem2\n } = _ref,\n other = _objectWithoutPropertiesLoose(_ref, _excluded);\n if (process.env.NODE_ENV !== 'production') {\n if (typeof fontSize !== 'number') {\n console.error('MUI: `fontSize` is required to be a number.');\n }\n if (typeof htmlFontSize !== 'number') {\n console.error('MUI: `htmlFontSize` is required to be a number.');\n }\n }\n const coef = fontSize / 14;\n const pxToRem = pxToRem2 || (size => `${size / htmlFontSize * coef}rem`);\n const buildVariant = (fontWeight, size, lineHeight, letterSpacing, casing) => _extends({\n fontFamily,\n fontWeight,\n fontSize: pxToRem(size),\n // Unitless following https://meyerweb.com/eric/thoughts/2006/02/08/unitless-line-heights/\n lineHeight\n }, fontFamily === defaultFontFamily ? {\n letterSpacing: `${round(letterSpacing / size)}em`\n } : {}, casing, allVariants);\n const variants = {\n h1: buildVariant(fontWeightLight, 96, 1.167, -1.5),\n h2: buildVariant(fontWeightLight, 60, 1.2, -0.5),\n h3: buildVariant(fontWeightRegular, 48, 1.167, 0),\n h4: buildVariant(fontWeightRegular, 34, 1.235, 0.25),\n h5: buildVariant(fontWeightRegular, 24, 1.334, 0),\n h6: buildVariant(fontWeightMedium, 20, 1.6, 0.15),\n subtitle1: buildVariant(fontWeightRegular, 16, 1.75, 0.15),\n subtitle2: buildVariant(fontWeightMedium, 14, 1.57, 0.1),\n body1: buildVariant(fontWeightRegular, 16, 1.5, 0.15),\n body2: buildVariant(fontWeightRegular, 14, 1.43, 0.15),\n button: buildVariant(fontWeightMedium, 14, 1.75, 0.4, caseAllCaps),\n caption: buildVariant(fontWeightRegular, 12, 1.66, 0.4),\n overline: buildVariant(fontWeightRegular, 12, 2.66, 1, caseAllCaps),\n // TODO v6: Remove handling of 'inherit' variant from the theme as it is already handled in Material UI's Typography component. Also, remember to remove the associated types.\n inherit: {\n fontFamily: 'inherit',\n fontWeight: 'inherit',\n fontSize: 'inherit',\n lineHeight: 'inherit',\n letterSpacing: 'inherit'\n }\n };\n return deepmerge(_extends({\n htmlFontSize,\n pxToRem,\n fontFamily,\n fontSize,\n fontWeightLight,\n fontWeightRegular,\n fontWeightMedium,\n fontWeightBold\n }, variants), other, {\n clone: false // No need to clone deep\n });\n}","const shadowKeyUmbraOpacity = 0.2;\nconst shadowKeyPenumbraOpacity = 0.14;\nconst shadowAmbientShadowOpacity = 0.12;\nfunction createShadow(...px) {\n return [`${px[0]}px ${px[1]}px ${px[2]}px ${px[3]}px rgba(0,0,0,${shadowKeyUmbraOpacity})`, `${px[4]}px ${px[5]}px ${px[6]}px ${px[7]}px rgba(0,0,0,${shadowKeyPenumbraOpacity})`, `${px[8]}px ${px[9]}px ${px[10]}px ${px[11]}px rgba(0,0,0,${shadowAmbientShadowOpacity})`].join(',');\n}\n\n// Values from https://github.com/material-components/material-components-web/blob/be8747f94574669cb5e7add1a7c54fa41a89cec7/packages/mdc-elevation/_variables.scss\nconst shadows = ['none', createShadow(0, 2, 1, -1, 0, 1, 1, 0, 0, 1, 3, 0), createShadow(0, 3, 1, -2, 0, 2, 2, 0, 0, 1, 5, 0), createShadow(0, 3, 3, -2, 0, 3, 4, 0, 0, 1, 8, 0), createShadow(0, 2, 4, -1, 0, 4, 5, 0, 0, 1, 10, 0), createShadow(0, 3, 5, -1, 0, 5, 8, 0, 0, 1, 14, 0), createShadow(0, 3, 5, -1, 0, 6, 10, 0, 0, 1, 18, 0), createShadow(0, 4, 5, -2, 0, 7, 10, 1, 0, 2, 16, 1), createShadow(0, 5, 5, -3, 0, 8, 10, 1, 0, 3, 14, 2), createShadow(0, 5, 6, -3, 0, 9, 12, 1, 0, 3, 16, 2), createShadow(0, 6, 6, -3, 0, 10, 14, 1, 0, 4, 18, 3), createShadow(0, 6, 7, -4, 0, 11, 15, 1, 0, 4, 20, 3), createShadow(0, 7, 8, -4, 0, 12, 17, 2, 0, 5, 22, 4), createShadow(0, 7, 8, -4, 0, 13, 19, 2, 0, 5, 24, 4), createShadow(0, 7, 9, -4, 0, 14, 21, 2, 0, 5, 26, 4), createShadow(0, 8, 9, -5, 0, 15, 22, 2, 0, 6, 28, 5), createShadow(0, 8, 10, -5, 0, 16, 24, 2, 0, 6, 30, 5), createShadow(0, 8, 11, -5, 0, 17, 26, 2, 0, 6, 32, 5), createShadow(0, 9, 11, -5, 0, 18, 28, 2, 0, 7, 34, 6), createShadow(0, 9, 12, -6, 0, 19, 29, 2, 0, 7, 36, 6), createShadow(0, 10, 13, -6, 0, 20, 31, 3, 0, 8, 38, 7), createShadow(0, 10, 13, -6, 0, 21, 33, 3, 0, 8, 40, 7), createShadow(0, 10, 14, -6, 0, 22, 35, 3, 0, 8, 42, 7), createShadow(0, 11, 14, -7, 0, 23, 36, 3, 0, 9, 44, 8), createShadow(0, 11, 15, -7, 0, 24, 38, 3, 0, 9, 46, 8)];\nexport default shadows;","import _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nconst _excluded = [\"duration\", \"easing\", \"delay\"];\n// Follow https://material.google.com/motion/duration-easing.html#duration-easing-natural-easing-curves\n// to learn the context in which each easing should be used.\nexport const easing = {\n // This is the most common easing curve.\n easeInOut: 'cubic-bezier(0.4, 0, 0.2, 1)',\n // Objects enter the screen at full velocity from off-screen and\n // slowly decelerate to a resting point.\n easeOut: 'cubic-bezier(0.0, 0, 0.2, 1)',\n // Objects leave the screen at full velocity. They do not decelerate when off-screen.\n easeIn: 'cubic-bezier(0.4, 0, 1, 1)',\n // The sharp curve is used by objects that may return to the screen at any time.\n sharp: 'cubic-bezier(0.4, 0, 0.6, 1)'\n};\n\n// Follow https://m2.material.io/guidelines/motion/duration-easing.html#duration-easing-common-durations\n// to learn when use what timing\nexport const duration = {\n shortest: 150,\n shorter: 200,\n short: 250,\n // most basic recommended timing\n standard: 300,\n // this is to be used in complex animations\n complex: 375,\n // recommended when something is entering screen\n enteringScreen: 225,\n // recommended when something is leaving screen\n leavingScreen: 195\n};\nfunction formatMs(milliseconds) {\n return `${Math.round(milliseconds)}ms`;\n}\nfunction getAutoHeightDuration(height) {\n if (!height) {\n return 0;\n }\n const constant = height / 36;\n\n // https://www.wolframalpha.com/input/?i=(4+%2B+15+*+(x+%2F+36+)+**+0.25+%2B+(x+%2F+36)+%2F+5)+*+10\n return Math.round((4 + 15 * constant ** 0.25 + constant / 5) * 10);\n}\nexport default function createTransitions(inputTransitions) {\n const mergedEasing = _extends({}, easing, inputTransitions.easing);\n const mergedDuration = _extends({}, duration, inputTransitions.duration);\n const create = (props = ['all'], options = {}) => {\n const {\n duration: durationOption = mergedDuration.standard,\n easing: easingOption = mergedEasing.easeInOut,\n delay = 0\n } = options,\n other = _objectWithoutPropertiesLoose(options, _excluded);\n if (process.env.NODE_ENV !== 'production') {\n const isString = value => typeof value === 'string';\n // IE11 support, replace with Number.isNaN\n // eslint-disable-next-line no-restricted-globals\n const isNumber = value => !isNaN(parseFloat(value));\n if (!isString(props) && !Array.isArray(props)) {\n console.error('MUI: Argument \"props\" must be a string or Array.');\n }\n if (!isNumber(durationOption) && !isString(durationOption)) {\n console.error(`MUI: Argument \"duration\" must be a number or a string but found ${durationOption}.`);\n }\n if (!isString(easingOption)) {\n console.error('MUI: Argument \"easing\" must be a string.');\n }\n if (!isNumber(delay) && !isString(delay)) {\n console.error('MUI: Argument \"delay\" must be a number or a string.');\n }\n if (typeof options !== 'object') {\n console.error(['MUI: Secong argument of transition.create must be an object.', \"Arguments should be either `create('prop1', options)` or `create(['prop1', 'prop2'], options)`\"].join('\\n'));\n }\n if (Object.keys(other).length !== 0) {\n console.error(`MUI: Unrecognized argument(s) [${Object.keys(other).join(',')}].`);\n }\n }\n return (Array.isArray(props) ? props : [props]).map(animatedProp => `${animatedProp} ${typeof durationOption === 'string' ? durationOption : formatMs(durationOption)} ${easingOption} ${typeof delay === 'string' ? delay : formatMs(delay)}`).join(',');\n };\n return _extends({\n getAutoHeightDuration,\n create\n }, inputTransitions, {\n easing: mergedEasing,\n duration: mergedDuration\n });\n}","// We need to centralize the zIndex definitions as they work\n// like global values in the browser.\nconst zIndex = {\n mobileStepper: 1000,\n fab: 1050,\n speedDial: 1050,\n appBar: 1100,\n drawer: 1200,\n modal: 1300,\n snackbar: 1400,\n tooltip: 1500\n};\nexport default zIndex;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\nconst _excluded = [\"breakpoints\", \"mixins\", \"spacing\", \"palette\", \"transitions\", \"typography\", \"shape\"];\nimport { deepmerge } from '@mui/utils';\nimport { createTheme as systemCreateTheme, unstable_defaultSxConfig as defaultSxConfig, unstable_styleFunctionSx as styleFunctionSx } from '@mui/system';\nimport generateUtilityClass from '@mui/utils/generateUtilityClass';\nimport createMixins from './createMixins';\nimport createPalette from './createPalette';\nimport createTypography from './createTypography';\nimport shadows from './shadows';\nimport createTransitions from './createTransitions';\nimport zIndex from './zIndex';\nfunction createTheme(options = {}, ...args) {\n const {\n mixins: mixinsInput = {},\n palette: paletteInput = {},\n transitions: transitionsInput = {},\n typography: typographyInput = {}\n } = options,\n other = _objectWithoutPropertiesLoose(options, _excluded);\n if (options.vars) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: \\`vars\\` is a private field used for CSS variables support.\nPlease use another name.` : _formatMuiErrorMessage(18));\n }\n const palette = createPalette(paletteInput);\n const systemTheme = systemCreateTheme(options);\n let muiTheme = deepmerge(systemTheme, {\n mixins: createMixins(systemTheme.breakpoints, mixinsInput),\n palette,\n // Don't use [...shadows] until you've verified its transpiled code is not invoking the iterator protocol.\n shadows: shadows.slice(),\n typography: createTypography(palette, typographyInput),\n transitions: createTransitions(transitionsInput),\n zIndex: _extends({}, zIndex)\n });\n muiTheme = deepmerge(muiTheme, other);\n muiTheme = args.reduce((acc, argument) => deepmerge(acc, argument), muiTheme);\n if (process.env.NODE_ENV !== 'production') {\n // TODO v6: Refactor to use globalStateClassesMapping from @mui/utils once `readOnly` state class is used in Rating component.\n const stateClasses = ['active', 'checked', 'completed', 'disabled', 'error', 'expanded', 'focused', 'focusVisible', 'required', 'selected'];\n const traverse = (node, component) => {\n let key;\n\n // eslint-disable-next-line guard-for-in, no-restricted-syntax\n for (key in node) {\n const child = node[key];\n if (stateClasses.indexOf(key) !== -1 && Object.keys(child).length > 0) {\n if (process.env.NODE_ENV !== 'production') {\n const stateClass = generateUtilityClass('', key);\n console.error([`MUI: The \\`${component}\\` component increases ` + `the CSS specificity of the \\`${key}\\` internal state.`, 'You can not override it like this: ', JSON.stringify(node, null, 2), '', `Instead, you need to use the '&.${stateClass}' syntax:`, JSON.stringify({\n root: {\n [`&.${stateClass}`]: child\n }\n }, null, 2), '', 'https://mui.com/r/state-classes-guide'].join('\\n'));\n }\n // Remove the style to prevent global conflicts.\n node[key] = {};\n }\n }\n };\n Object.keys(muiTheme.components).forEach(component => {\n const styleOverrides = muiTheme.components[component].styleOverrides;\n if (styleOverrides && component.indexOf('Mui') === 0) {\n traverse(styleOverrides, component);\n }\n });\n }\n muiTheme.unstable_sxConfig = _extends({}, defaultSxConfig, other == null ? void 0 : other.unstable_sxConfig);\n muiTheme.unstable_sx = function sx(props) {\n return styleFunctionSx({\n sx: props,\n theme: this\n });\n };\n return muiTheme;\n}\nlet warnedOnce = false;\nexport function createMuiTheme(...args) {\n if (process.env.NODE_ENV !== 'production') {\n if (!warnedOnce) {\n warnedOnce = true;\n console.error(['MUI: the createMuiTheme function was renamed to createTheme.', '', \"You should use `import { createTheme } from '@mui/material/styles'`\"].join('\\n'));\n }\n }\n return createTheme(...args);\n}\nexport default createTheme;","'use client';\n\nimport createTheme from './createTheme';\nconst defaultTheme = createTheme();\nexport default defaultTheme;","export default '$$material';","'use client';\n\nimport { useThemeProps as systemUseThemeProps } from '@mui/system';\nimport defaultTheme from './defaultTheme';\nimport THEME_ID from './identifier';\nexport default function useThemeProps({\n props,\n name\n}) {\n return systemUseThemeProps({\n props,\n name,\n defaultTheme,\n themeId: THEME_ID\n });\n}","'use client';\n\nimport { createStyled, shouldForwardProp } from '@mui/system';\nimport defaultTheme from './defaultTheme';\nimport THEME_ID from './identifier';\nexport const rootShouldForwardProp = prop => shouldForwardProp(prop) && prop !== 'classes';\nexport const slotShouldForwardProp = shouldForwardProp;\nconst styled = createStyled({\n themeId: THEME_ID,\n defaultTheme,\n rootShouldForwardProp\n});\nexport default styled;","import generateUtilityClasses from '@mui/utils/generateUtilityClasses';\nimport generateUtilityClass from '@mui/utils/generateUtilityClass';\nexport function getSvgIconUtilityClass(slot) {\n return generateUtilityClass('MuiSvgIcon', slot);\n}\nconst svgIconClasses = generateUtilityClasses('MuiSvgIcon', ['root', 'colorPrimary', 'colorSecondary', 'colorAction', 'colorError', 'colorDisabled', 'fontSizeInherit', 'fontSizeSmall', 'fontSizeMedium', 'fontSizeLarge']);\nexport default svgIconClasses;","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"children\", \"className\", \"color\", \"component\", \"fontSize\", \"htmlColor\", \"inheritViewBox\", \"titleAccess\", \"viewBox\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport clsx from 'clsx';\nimport { unstable_composeClasses as composeClasses } from '@mui/base/composeClasses';\nimport capitalize from '../utils/capitalize';\nimport useThemeProps from '../styles/useThemeProps';\nimport styled from '../styles/styled';\nimport { getSvgIconUtilityClass } from './svgIconClasses';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nimport { jsxs as _jsxs } from \"react/jsx-runtime\";\nconst useUtilityClasses = ownerState => {\n const {\n color,\n fontSize,\n classes\n } = ownerState;\n const slots = {\n root: ['root', color !== 'inherit' && `color${capitalize(color)}`, `fontSize${capitalize(fontSize)}`]\n };\n return composeClasses(slots, getSvgIconUtilityClass, classes);\n};\nconst SvgIconRoot = styled('svg', {\n name: 'MuiSvgIcon',\n slot: 'Root',\n overridesResolver: (props, styles) => {\n const {\n ownerState\n } = props;\n return [styles.root, ownerState.color !== 'inherit' && styles[`color${capitalize(ownerState.color)}`], styles[`fontSize${capitalize(ownerState.fontSize)}`]];\n }\n})(({\n theme,\n ownerState\n}) => {\n var _theme$transitions, _theme$transitions$cr, _theme$transitions2, _theme$typography, _theme$typography$pxT, _theme$typography2, _theme$typography2$px, _theme$typography3, _theme$typography3$px, _palette$ownerState$c, _palette, _palette2, _palette3;\n return {\n userSelect: 'none',\n width: '1em',\n height: '1em',\n display: 'inline-block',\n // the will define the property that has `currentColor`\n // e.g. heroicons uses fill=\"none\" and stroke=\"currentColor\"\n fill: ownerState.hasSvgAsChild ? undefined : 'currentColor',\n flexShrink: 0,\n transition: (_theme$transitions = theme.transitions) == null || (_theme$transitions$cr = _theme$transitions.create) == null ? void 0 : _theme$transitions$cr.call(_theme$transitions, 'fill', {\n duration: (_theme$transitions2 = theme.transitions) == null || (_theme$transitions2 = _theme$transitions2.duration) == null ? void 0 : _theme$transitions2.shorter\n }),\n fontSize: {\n inherit: 'inherit',\n small: ((_theme$typography = theme.typography) == null || (_theme$typography$pxT = _theme$typography.pxToRem) == null ? void 0 : _theme$typography$pxT.call(_theme$typography, 20)) || '1.25rem',\n medium: ((_theme$typography2 = theme.typography) == null || (_theme$typography2$px = _theme$typography2.pxToRem) == null ? void 0 : _theme$typography2$px.call(_theme$typography2, 24)) || '1.5rem',\n large: ((_theme$typography3 = theme.typography) == null || (_theme$typography3$px = _theme$typography3.pxToRem) == null ? void 0 : _theme$typography3$px.call(_theme$typography3, 35)) || '2.1875rem'\n }[ownerState.fontSize],\n // TODO v5 deprecate, v6 remove for sx\n color: (_palette$ownerState$c = (_palette = (theme.vars || theme).palette) == null || (_palette = _palette[ownerState.color]) == null ? void 0 : _palette.main) != null ? _palette$ownerState$c : {\n action: (_palette2 = (theme.vars || theme).palette) == null || (_palette2 = _palette2.action) == null ? void 0 : _palette2.active,\n disabled: (_palette3 = (theme.vars || theme).palette) == null || (_palette3 = _palette3.action) == null ? void 0 : _palette3.disabled,\n inherit: undefined\n }[ownerState.color]\n };\n});\nconst SvgIcon = /*#__PURE__*/React.forwardRef(function SvgIcon(inProps, ref) {\n const props = useThemeProps({\n props: inProps,\n name: 'MuiSvgIcon'\n });\n const {\n children,\n className,\n color = 'inherit',\n component = 'svg',\n fontSize = 'medium',\n htmlColor,\n inheritViewBox = false,\n titleAccess,\n viewBox = '0 0 24 24'\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const hasSvgAsChild = /*#__PURE__*/React.isValidElement(children) && children.type === 'svg';\n const ownerState = _extends({}, props, {\n color,\n component,\n fontSize,\n instanceFontSize: inProps.fontSize,\n inheritViewBox,\n viewBox,\n hasSvgAsChild\n });\n const more = {};\n if (!inheritViewBox) {\n more.viewBox = viewBox;\n }\n const classes = useUtilityClasses(ownerState);\n return /*#__PURE__*/_jsxs(SvgIconRoot, _extends({\n as: component,\n className: clsx(classes.root, className),\n focusable: \"false\",\n color: htmlColor,\n \"aria-hidden\": titleAccess ? undefined : true,\n role: titleAccess ? 'img' : undefined,\n ref: ref\n }, more, other, hasSvgAsChild && children.props, {\n ownerState: ownerState,\n children: [hasSvgAsChild ? children.props.children : children, titleAccess ? /*#__PURE__*/_jsx(\"title\", {\n children: titleAccess\n }) : null]\n }));\n});\nprocess.env.NODE_ENV !== \"production\" ? SvgIcon.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the d.ts file and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * Node passed into the SVG element.\n */\n children: PropTypes.node,\n /**\n * Override or extend the styles applied to the component.\n */\n classes: PropTypes.object,\n /**\n * @ignore\n */\n className: PropTypes.string,\n /**\n * The color of the component.\n * It supports both default and custom theme colors, which can be added as shown in the\n * [palette customization guide](https://mui.com/material-ui/customization/palette/#custom-colors).\n * You can use the `htmlColor` prop to apply a color attribute to the SVG element.\n * @default 'inherit'\n */\n color: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.oneOf(['inherit', 'action', 'disabled', 'primary', 'secondary', 'error', 'info', 'success', 'warning']), PropTypes.string]),\n /**\n * The component used for the root node.\n * Either a string to use a HTML element or a component.\n */\n component: PropTypes.elementType,\n /**\n * The fontSize applied to the icon. Defaults to 24px, but can be configure to inherit font size.\n * @default 'medium'\n */\n fontSize: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.oneOf(['inherit', 'large', 'medium', 'small']), PropTypes.string]),\n /**\n * Applies a color attribute to the SVG element.\n */\n htmlColor: PropTypes.string,\n /**\n * If `true`, the root node will inherit the custom `component`'s viewBox and the `viewBox`\n * prop will be ignored.\n * Useful when you want to reference a custom `component` and have `SvgIcon` pass that\n * `component`'s viewBox to the root node.\n * @default false\n */\n inheritViewBox: PropTypes.bool,\n /**\n * The shape-rendering attribute. The behavior of the different options is described on the\n * [MDN Web Docs](https://developer.mozilla.org/en-US/docs/Web/SVG/Attribute/shape-rendering).\n * If you are having issues with blurry icons you should investigate this prop.\n */\n shapeRendering: PropTypes.string,\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Provides a human-readable title for the element that contains it.\n * https://www.w3.org/TR/SVG-access/#Equivalent\n */\n titleAccess: PropTypes.string,\n /**\n * Allows you to redefine what the coordinates without units mean inside an SVG element.\n * For example, if the SVG element is 500 (width) by 200 (height),\n * and you pass viewBox=\"0 0 50 20\",\n * this means that the coordinates inside the SVG will go from the top left corner (0,0)\n * to bottom right (50,20) and each unit will be worth 10px.\n * @default '0 0 24 24'\n */\n viewBox: PropTypes.string\n} : void 0;\nSvgIcon.muiName = 'SvgIcon';\nexport default SvgIcon;","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport * as React from 'react';\nimport SvgIcon from '../SvgIcon';\n\n/**\n * Private module reserved for @mui packages.\n */\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nexport default function createSvgIcon(path, displayName) {\n function Component(props, ref) {\n return /*#__PURE__*/_jsx(SvgIcon, _extends({\n \"data-testid\": `${displayName}Icon`,\n ref: ref\n }, props, {\n children: path\n }));\n }\n if (process.env.NODE_ENV !== 'production') {\n // Need to set `displayName` on the inner component for React.memo.\n // React prior to 16.14 ignores `displayName` on the wrapper.\n Component.displayName = `${displayName}Icon`;\n }\n Component.muiName = SvgIcon.muiName;\n return /*#__PURE__*/React.memo( /*#__PURE__*/React.forwardRef(Component));\n}","'use client';\n\nimport { unstable_ClassNameGenerator as ClassNameGenerator } from '@mui/base/ClassNameGenerator';\nexport { default as capitalize } from './capitalize';\nexport { default as createChainedFunction } from './createChainedFunction';\nexport { default as createSvgIcon } from './createSvgIcon';\nexport { default as debounce } from './debounce';\nexport { default as deprecatedPropType } from './deprecatedPropType';\nexport { default as isMuiElement } from './isMuiElement';\nexport { default as ownerDocument } from './ownerDocument';\nexport { default as ownerWindow } from './ownerWindow';\nexport { default as requirePropFactory } from './requirePropFactory';\nexport { default as setRef } from './setRef';\nexport { default as unstable_useEnhancedEffect } from './useEnhancedEffect';\nexport { default as unstable_useId } from './useId';\nexport { default as unsupportedProp } from './unsupportedProp';\nexport { default as useControlled } from './useControlled';\nexport { default as useEventCallback } from './useEventCallback';\nexport { default as useForkRef } from './useForkRef';\nexport { default as useIsFocusVisible } from './useIsFocusVisible';\n// TODO: remove this export once ClassNameGenerator is stable\n// eslint-disable-next-line @typescript-eslint/naming-convention\nexport const unstable_ClassNameGenerator = {\n configure: generator => {\n if (process.env.NODE_ENV !== 'production') {\n console.warn(['MUI: `ClassNameGenerator` import from `@mui/material/utils` is outdated and might cause unexpected issues.', '', \"You should use `import { unstable_ClassNameGenerator } from '@mui/material/className'` instead\", '', 'The detail of the issue: https://github.com/mui/material-ui/issues/30011#issuecomment-1024993401', '', 'The updated documentation: https://mui.com/guides/classname-generator/'].join('\\n'));\n }\n ClassNameGenerator.configure(generator);\n }\n};","\"use strict\";\n'use client';\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nObject.defineProperty(exports, \"default\", {\n enumerable: true,\n get: function () {\n return _utils.createSvgIcon;\n }\n});\nvar _utils = require(\"@mui/material/utils\");","\"use strict\";\n\"use client\";\n\nvar _interopRequireDefault = require(\"@babel/runtime/helpers/interopRequireDefault\");\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = void 0;\nvar _createSvgIcon = _interopRequireDefault(require(\"./utils/createSvgIcon\"));\nvar _jsxRuntime = require(\"react/jsx-runtime\");\nvar _default = exports.default = (0, _createSvgIcon.default)( /*#__PURE__*/(0, _jsxRuntime.jsx)(\"path\", {\n d: \"m10 17 5-5-5-5z\"\n}), 'ArrowRight');","/**\n * Determines if a given element is a DOM element name (i.e. not a React component).\n */\nexport function isHostComponent(element) {\n return typeof element === 'string';\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport { isHostComponent } from './isHostComponent';\n\n/**\n * Type of the ownerState based on the type of an element it applies to.\n * This resolves to the provided OwnerState for React components and `undefined` for host components.\n * Falls back to `OwnerState | undefined` when the exact type can't be determined in development time.\n */\n\n/**\n * Appends the ownerState object to the props, merging with the existing one if necessary.\n *\n * @param elementType Type of the element that owns the `existingProps`. If the element is a DOM node or undefined, `ownerState` is not applied.\n * @param otherProps Props of the element.\n * @param ownerState\n */\nexport function appendOwnerState(elementType, otherProps, ownerState) {\n if (elementType === undefined || isHostComponent(elementType)) {\n return otherProps;\n }\n return _extends({}, otherProps, {\n ownerState: _extends({}, otherProps.ownerState, ownerState)\n });\n}","'use client';\n\nimport * as React from 'react';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nconst defaultContextValue = {\n disableDefaultClasses: false\n};\nconst ClassNameConfiguratorContext = /*#__PURE__*/React.createContext(defaultContextValue);\n/**\n * @ignore - internal hook.\n *\n * Wraps the `generateUtilityClass` function and controls how the classes are generated.\n * Currently it only affects whether the classes are applied or not.\n *\n * @returns Function to be called with the `generateUtilityClass` function specific to a component to generate the classes.\n */\nexport function useClassNamesOverride(generateUtilityClass) {\n const {\n disableDefaultClasses\n } = React.useContext(ClassNameConfiguratorContext);\n return slot => {\n if (disableDefaultClasses) {\n return '';\n }\n return generateUtilityClass(slot);\n };\n}\n\n/**\n * Allows to configure the components within to not apply any built-in classes.\n */\nexport function ClassNameConfigurator(props) {\n const {\n disableDefaultClasses,\n children\n } = props;\n const contextValue = React.useMemo(() => ({\n disableDefaultClasses: disableDefaultClasses != null ? disableDefaultClasses : false\n }), [disableDefaultClasses]);\n return /*#__PURE__*/_jsx(ClassNameConfiguratorContext.Provider, {\n value: contextValue,\n children: children\n });\n}","/**\n * Extracts event handlers from a given object.\n * A prop is considered an event handler if it is a function and its name starts with `on`.\n *\n * @param object An object to extract event handlers from.\n * @param excludeKeys An array of keys to exclude from the returned object.\n */\nexport function extractEventHandlers(object, excludeKeys = []) {\n if (object === undefined) {\n return {};\n }\n const result = {};\n Object.keys(object).filter(prop => prop.match(/^on[A-Z]/) && typeof object[prop] === 'function' && !excludeKeys.includes(prop)).forEach(prop => {\n result[prop] = object[prop];\n });\n return result;\n}","/**\n * If `componentProps` is a function, calls it with the provided `ownerState`.\n * Otherwise, just returns `componentProps`.\n */\nexport function resolveComponentProps(componentProps, ownerState, slotState) {\n if (typeof componentProps === 'function') {\n return componentProps(ownerState, slotState);\n }\n return componentProps;\n}","/**\n * Removes event handlers from the given object.\n * A field is considered an event handler if it is a function with a name beginning with `on`.\n *\n * @param object Object to remove event handlers from.\n * @returns Object with event handlers removed.\n */\nexport function omitEventHandlers(object) {\n if (object === undefined) {\n return {};\n }\n const result = {};\n Object.keys(object).filter(prop => !(prop.match(/^on[A-Z]/) && typeof object[prop] === 'function')).forEach(prop => {\n result[prop] = object[prop];\n });\n return result;\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport clsx from 'clsx';\nimport { extractEventHandlers } from './extractEventHandlers';\nimport { omitEventHandlers } from './omitEventHandlers';\n/**\n * Merges the slot component internal props (usually coming from a hook)\n * with the externally provided ones.\n *\n * The merge order is (the latter overrides the former):\n * 1. The internal props (specified as a getter function to work with get*Props hook result)\n * 2. Additional props (specified internally on a Base UI component)\n * 3. External props specified on the owner component. These should only be used on a root slot.\n * 4. External props specified in the `slotProps.*` prop.\n * 5. The `className` prop - combined from all the above.\n * @param parameters\n * @returns\n */\nexport function mergeSlotProps(parameters) {\n const {\n getSlotProps,\n additionalProps,\n externalSlotProps,\n externalForwardedProps,\n className\n } = parameters;\n if (!getSlotProps) {\n // The simpler case - getSlotProps is not defined, so no internal event handlers are defined,\n // so we can simply merge all the props without having to worry about extracting event handlers.\n const joinedClasses = clsx(additionalProps == null ? void 0 : additionalProps.className, className, externalForwardedProps == null ? void 0 : externalForwardedProps.className, externalSlotProps == null ? void 0 : externalSlotProps.className);\n const mergedStyle = _extends({}, additionalProps == null ? void 0 : additionalProps.style, externalForwardedProps == null ? void 0 : externalForwardedProps.style, externalSlotProps == null ? void 0 : externalSlotProps.style);\n const props = _extends({}, additionalProps, externalForwardedProps, externalSlotProps);\n if (joinedClasses.length > 0) {\n props.className = joinedClasses;\n }\n if (Object.keys(mergedStyle).length > 0) {\n props.style = mergedStyle;\n }\n return {\n props,\n internalRef: undefined\n };\n }\n\n // In this case, getSlotProps is responsible for calling the external event handlers.\n // We don't need to include them in the merged props because of this.\n\n const eventHandlers = extractEventHandlers(_extends({}, externalForwardedProps, externalSlotProps));\n const componentsPropsWithoutEventHandlers = omitEventHandlers(externalSlotProps);\n const otherPropsWithoutEventHandlers = omitEventHandlers(externalForwardedProps);\n const internalSlotProps = getSlotProps(eventHandlers);\n\n // The order of classes is important here.\n // Emotion (that we use in libraries consuming Base UI) depends on this order\n // to properly override style. It requires the most important classes to be last\n // (see https://github.com/mui/material-ui/pull/33205) for the related discussion.\n const joinedClasses = clsx(internalSlotProps == null ? void 0 : internalSlotProps.className, additionalProps == null ? void 0 : additionalProps.className, className, externalForwardedProps == null ? void 0 : externalForwardedProps.className, externalSlotProps == null ? void 0 : externalSlotProps.className);\n const mergedStyle = _extends({}, internalSlotProps == null ? void 0 : internalSlotProps.style, additionalProps == null ? void 0 : additionalProps.style, externalForwardedProps == null ? void 0 : externalForwardedProps.style, externalSlotProps == null ? void 0 : externalSlotProps.style);\n const props = _extends({}, internalSlotProps, additionalProps, otherPropsWithoutEventHandlers, componentsPropsWithoutEventHandlers);\n if (joinedClasses.length > 0) {\n props.className = joinedClasses;\n }\n if (Object.keys(mergedStyle).length > 0) {\n props.style = mergedStyle;\n }\n return {\n props,\n internalRef: internalSlotProps.ref\n };\n}","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"elementType\", \"externalSlotProps\", \"ownerState\", \"skipResolvingSlotProps\"];\nimport { unstable_useForkRef as useForkRef } from '@mui/utils';\nimport { appendOwnerState } from './appendOwnerState';\nimport { mergeSlotProps } from './mergeSlotProps';\nimport { resolveComponentProps } from './resolveComponentProps';\n/**\n * @ignore - do not document.\n * Builds the props to be passed into the slot of an unstyled component.\n * It merges the internal props of the component with the ones supplied by the user, allowing to customize the behavior.\n * If the slot component is not a host component, it also merges in the `ownerState`.\n *\n * @param parameters.getSlotProps - A function that returns the props to be passed to the slot component.\n */\nexport function useSlotProps(parameters) {\n var _parameters$additiona;\n const {\n elementType,\n externalSlotProps,\n ownerState,\n skipResolvingSlotProps = false\n } = parameters,\n rest = _objectWithoutPropertiesLoose(parameters, _excluded);\n const resolvedComponentsProps = skipResolvingSlotProps ? {} : resolveComponentProps(externalSlotProps, ownerState);\n const {\n props: mergedProps,\n internalRef\n } = mergeSlotProps(_extends({}, rest, {\n externalSlotProps: resolvedComponentsProps\n }));\n const ref = useForkRef(internalRef, resolvedComponentsProps == null ? void 0 : resolvedComponentsProps.ref, (_parameters$additiona = parameters.additionalProps) == null ? void 0 : _parameters$additiona.ref);\n const props = appendOwnerState(elementType, _extends({}, mergedProps, {\n ref\n }), ownerState);\n return props;\n}","import { globalStateClasses } from '@mui/utils/generateUtilityClass';\nconst GLOBAL_CLASS_PREFIX = 'base';\nfunction buildStateClass(state) {\n return `${GLOBAL_CLASS_PREFIX}--${state}`;\n}\nfunction buildSlotClass(componentName, slot) {\n return `${GLOBAL_CLASS_PREFIX}-${componentName}-${slot}`;\n}\nexport function generateUtilityClass(componentName, slot) {\n const globalStateClass = globalStateClasses[slot];\n return globalStateClass ? buildStateClass(globalStateClass) : buildSlotClass(componentName, slot);\n}\nexport function isGlobalState(slot) {\n return globalStateClasses[slot] !== undefined;\n}","import { generateUtilityClass } from '../generateUtilityClass';\nexport function generateUtilityClasses(componentName, slots) {\n const result = {};\n slots.forEach(slot => {\n result[slot] = generateUtilityClass(componentName, slot);\n });\n return result;\n}","'use client';\n\nimport * as React from 'react';\nimport * as ReactDOM from 'react-dom';\nimport PropTypes from 'prop-types';\nimport { exactProp, HTMLElementType, unstable_useEnhancedEffect as useEnhancedEffect, unstable_useForkRef as useForkRef, unstable_setRef as setRef } from '@mui/utils';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nfunction getContainer(container) {\n return typeof container === 'function' ? container() : container;\n}\n\n/**\n * Portals provide a first-class way to render children into a DOM node\n * that exists outside the DOM hierarchy of the parent component.\n *\n * Demos:\n *\n * - [Portal](https://mui.com/base-ui/react-portal/)\n *\n * API:\n *\n * - [Portal API](https://mui.com/base-ui/react-portal/components-api/#portal)\n */\nconst Portal = /*#__PURE__*/React.forwardRef(function Portal(props, forwardedRef) {\n const {\n children,\n container,\n disablePortal = false\n } = props;\n const [mountNode, setMountNode] = React.useState(null);\n // @ts-expect-error TODO upstream fix\n const handleRef = useForkRef( /*#__PURE__*/React.isValidElement(children) ? children.ref : null, forwardedRef);\n useEnhancedEffect(() => {\n if (!disablePortal) {\n setMountNode(getContainer(container) || document.body);\n }\n }, [container, disablePortal]);\n useEnhancedEffect(() => {\n if (mountNode && !disablePortal) {\n setRef(forwardedRef, mountNode);\n return () => {\n setRef(forwardedRef, null);\n };\n }\n return undefined;\n }, [forwardedRef, mountNode, disablePortal]);\n if (disablePortal) {\n if ( /*#__PURE__*/React.isValidElement(children)) {\n const newProps = {\n ref: handleRef\n };\n return /*#__PURE__*/React.cloneElement(children, newProps);\n }\n return /*#__PURE__*/_jsx(React.Fragment, {\n children: children\n });\n }\n return /*#__PURE__*/_jsx(React.Fragment, {\n children: mountNode ? /*#__PURE__*/ReactDOM.createPortal(children, mountNode) : mountNode\n });\n});\nprocess.env.NODE_ENV !== \"production\" ? Portal.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * The children to render into the `container`.\n */\n children: PropTypes.node,\n /**\n * An HTML element or function that returns one.\n * The `container` will have the portal children appended to it.\n *\n * You can also provide a callback, which is called in a React layout effect.\n * This lets you set the container from a ref, and also makes server-side rendering possible.\n *\n * By default, it uses the body of the top-level document object,\n * so it's simply `document.body` most of the time.\n */\n container: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.func]),\n /**\n * The `children` will be under the DOM hierarchy of the parent component.\n * @default false\n */\n disablePortal: PropTypes.bool\n} : void 0;\nif (process.env.NODE_ENV !== 'production') {\n // eslint-disable-next-line\n Portal['propTypes' + ''] = exactProp(Portal.propTypes);\n}\nexport { Portal };","export var top = 'top';\nexport var bottom = 'bottom';\nexport var right = 'right';\nexport var left = 'left';\nexport var auto = 'auto';\nexport var basePlacements = [top, bottom, right, left];\nexport var start = 'start';\nexport var end = 'end';\nexport var clippingParents = 'clippingParents';\nexport var viewport = 'viewport';\nexport var popper = 'popper';\nexport var reference = 'reference';\nexport var variationPlacements = /*#__PURE__*/basePlacements.reduce(function (acc, placement) {\n return acc.concat([placement + \"-\" + start, placement + \"-\" + end]);\n}, []);\nexport var placements = /*#__PURE__*/[].concat(basePlacements, [auto]).reduce(function (acc, placement) {\n return acc.concat([placement, placement + \"-\" + start, placement + \"-\" + end]);\n}, []); // modifiers that need to read the DOM\n\nexport var beforeRead = 'beforeRead';\nexport var read = 'read';\nexport var afterRead = 'afterRead'; // pure-logic modifiers\n\nexport var beforeMain = 'beforeMain';\nexport var main = 'main';\nexport var afterMain = 'afterMain'; // modifier with the purpose to write to the DOM (or write into a framework state)\n\nexport var beforeWrite = 'beforeWrite';\nexport var write = 'write';\nexport var afterWrite = 'afterWrite';\nexport var modifierPhases = [beforeRead, read, afterRead, beforeMain, main, afterMain, beforeWrite, write, afterWrite];","export default function getNodeName(element) {\n return element ? (element.nodeName || '').toLowerCase() : null;\n}","export default function getWindow(node) {\n if (node == null) {\n return window;\n }\n\n if (node.toString() !== '[object Window]') {\n var ownerDocument = node.ownerDocument;\n return ownerDocument ? ownerDocument.defaultView || window : window;\n }\n\n return node;\n}","import getWindow from \"./getWindow.js\";\n\nfunction isElement(node) {\n var OwnElement = getWindow(node).Element;\n return node instanceof OwnElement || node instanceof Element;\n}\n\nfunction isHTMLElement(node) {\n var OwnElement = getWindow(node).HTMLElement;\n return node instanceof OwnElement || node instanceof HTMLElement;\n}\n\nfunction isShadowRoot(node) {\n // IE 11 has no ShadowRoot\n if (typeof ShadowRoot === 'undefined') {\n return false;\n }\n\n var OwnElement = getWindow(node).ShadowRoot;\n return node instanceof OwnElement || node instanceof ShadowRoot;\n}\n\nexport { isElement, isHTMLElement, isShadowRoot };","import getNodeName from \"../dom-utils/getNodeName.js\";\nimport { isHTMLElement } from \"../dom-utils/instanceOf.js\"; // This modifier takes the styles prepared by the `computeStyles` modifier\n// and applies them to the HTMLElements such as popper and arrow\n\nfunction applyStyles(_ref) {\n var state = _ref.state;\n Object.keys(state.elements).forEach(function (name) {\n var style = state.styles[name] || {};\n var attributes = state.attributes[name] || {};\n var element = state.elements[name]; // arrow is optional + virtual elements\n\n if (!isHTMLElement(element) || !getNodeName(element)) {\n return;\n } // Flow doesn't support to extend this property, but it's the most\n // effective way to apply styles to an HTMLElement\n // $FlowFixMe[cannot-write]\n\n\n Object.assign(element.style, style);\n Object.keys(attributes).forEach(function (name) {\n var value = attributes[name];\n\n if (value === false) {\n element.removeAttribute(name);\n } else {\n element.setAttribute(name, value === true ? '' : value);\n }\n });\n });\n}\n\nfunction effect(_ref2) {\n var state = _ref2.state;\n var initialStyles = {\n popper: {\n position: state.options.strategy,\n left: '0',\n top: '0',\n margin: '0'\n },\n arrow: {\n position: 'absolute'\n },\n reference: {}\n };\n Object.assign(state.elements.popper.style, initialStyles.popper);\n state.styles = initialStyles;\n\n if (state.elements.arrow) {\n Object.assign(state.elements.arrow.style, initialStyles.arrow);\n }\n\n return function () {\n Object.keys(state.elements).forEach(function (name) {\n var element = state.elements[name];\n var attributes = state.attributes[name] || {};\n var styleProperties = Object.keys(state.styles.hasOwnProperty(name) ? state.styles[name] : initialStyles[name]); // Set all values to an empty string to unset them\n\n var style = styleProperties.reduce(function (style, property) {\n style[property] = '';\n return style;\n }, {}); // arrow is optional + virtual elements\n\n if (!isHTMLElement(element) || !getNodeName(element)) {\n return;\n }\n\n Object.assign(element.style, style);\n Object.keys(attributes).forEach(function (attribute) {\n element.removeAttribute(attribute);\n });\n });\n };\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'applyStyles',\n enabled: true,\n phase: 'write',\n fn: applyStyles,\n effect: effect,\n requires: ['computeStyles']\n};","import { auto } from \"../enums.js\";\nexport default function getBasePlacement(placement) {\n return placement.split('-')[0];\n}","export var max = Math.max;\nexport var min = Math.min;\nexport var round = Math.round;","export default function getUAString() {\n var uaData = navigator.userAgentData;\n\n if (uaData != null && uaData.brands && Array.isArray(uaData.brands)) {\n return uaData.brands.map(function (item) {\n return item.brand + \"/\" + item.version;\n }).join(' ');\n }\n\n return navigator.userAgent;\n}","import getUAString from \"../utils/userAgent.js\";\nexport default function isLayoutViewport() {\n return !/^((?!chrome|android).)*safari/i.test(getUAString());\n}","import { isElement, isHTMLElement } from \"./instanceOf.js\";\nimport { round } from \"../utils/math.js\";\nimport getWindow from \"./getWindow.js\";\nimport isLayoutViewport from \"./isLayoutViewport.js\";\nexport default function getBoundingClientRect(element, includeScale, isFixedStrategy) {\n if (includeScale === void 0) {\n includeScale = false;\n }\n\n if (isFixedStrategy === void 0) {\n isFixedStrategy = false;\n }\n\n var clientRect = element.getBoundingClientRect();\n var scaleX = 1;\n var scaleY = 1;\n\n if (includeScale && isHTMLElement(element)) {\n scaleX = element.offsetWidth > 0 ? round(clientRect.width) / element.offsetWidth || 1 : 1;\n scaleY = element.offsetHeight > 0 ? round(clientRect.height) / element.offsetHeight || 1 : 1;\n }\n\n var _ref = isElement(element) ? getWindow(element) : window,\n visualViewport = _ref.visualViewport;\n\n var addVisualOffsets = !isLayoutViewport() && isFixedStrategy;\n var x = (clientRect.left + (addVisualOffsets && visualViewport ? visualViewport.offsetLeft : 0)) / scaleX;\n var y = (clientRect.top + (addVisualOffsets && visualViewport ? visualViewport.offsetTop : 0)) / scaleY;\n var width = clientRect.width / scaleX;\n var height = clientRect.height / scaleY;\n return {\n width: width,\n height: height,\n top: y,\n right: x + width,\n bottom: y + height,\n left: x,\n x: x,\n y: y\n };\n}","import getBoundingClientRect from \"./getBoundingClientRect.js\"; // Returns the layout rect of an element relative to its offsetParent. Layout\n// means it doesn't take into account transforms.\n\nexport default function getLayoutRect(element) {\n var clientRect = getBoundingClientRect(element); // Use the clientRect sizes if it's not been transformed.\n // Fixes https://github.com/popperjs/popper-core/issues/1223\n\n var width = element.offsetWidth;\n var height = element.offsetHeight;\n\n if (Math.abs(clientRect.width - width) <= 1) {\n width = clientRect.width;\n }\n\n if (Math.abs(clientRect.height - height) <= 1) {\n height = clientRect.height;\n }\n\n return {\n x: element.offsetLeft,\n y: element.offsetTop,\n width: width,\n height: height\n };\n}","import { isShadowRoot } from \"./instanceOf.js\";\nexport default function contains(parent, child) {\n var rootNode = child.getRootNode && child.getRootNode(); // First, attempt with faster native method\n\n if (parent.contains(child)) {\n return true;\n } // then fallback to custom implementation with Shadow DOM support\n else if (rootNode && isShadowRoot(rootNode)) {\n var next = child;\n\n do {\n if (next && parent.isSameNode(next)) {\n return true;\n } // $FlowFixMe[prop-missing]: need a better way to handle this...\n\n\n next = next.parentNode || next.host;\n } while (next);\n } // Give up, the result is false\n\n\n return false;\n}","import getWindow from \"./getWindow.js\";\nexport default function getComputedStyle(element) {\n return getWindow(element).getComputedStyle(element);\n}","import getNodeName from \"./getNodeName.js\";\nexport default function isTableElement(element) {\n return ['table', 'td', 'th'].indexOf(getNodeName(element)) >= 0;\n}","import { isElement } from \"./instanceOf.js\";\nexport default function getDocumentElement(element) {\n // $FlowFixMe[incompatible-return]: assume body is always available\n return ((isElement(element) ? element.ownerDocument : // $FlowFixMe[prop-missing]\n element.document) || window.document).documentElement;\n}","import getNodeName from \"./getNodeName.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport { isShadowRoot } from \"./instanceOf.js\";\nexport default function getParentNode(element) {\n if (getNodeName(element) === 'html') {\n return element;\n }\n\n return (// this is a quicker (but less type safe) way to save quite some bytes from the bundle\n // $FlowFixMe[incompatible-return]\n // $FlowFixMe[prop-missing]\n element.assignedSlot || // step into the shadow DOM of the parent of a slotted node\n element.parentNode || ( // DOM Element detected\n isShadowRoot(element) ? element.host : null) || // ShadowRoot detected\n // $FlowFixMe[incompatible-call]: HTMLElement is a Node\n getDocumentElement(element) // fallback\n\n );\n}","import getWindow from \"./getWindow.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport getComputedStyle from \"./getComputedStyle.js\";\nimport { isHTMLElement, isShadowRoot } from \"./instanceOf.js\";\nimport isTableElement from \"./isTableElement.js\";\nimport getParentNode from \"./getParentNode.js\";\nimport getUAString from \"../utils/userAgent.js\";\n\nfunction getTrueOffsetParent(element) {\n if (!isHTMLElement(element) || // https://github.com/popperjs/popper-core/issues/837\n getComputedStyle(element).position === 'fixed') {\n return null;\n }\n\n return element.offsetParent;\n} // `.offsetParent` reports `null` for fixed elements, while absolute elements\n// return the containing block\n\n\nfunction getContainingBlock(element) {\n var isFirefox = /firefox/i.test(getUAString());\n var isIE = /Trident/i.test(getUAString());\n\n if (isIE && isHTMLElement(element)) {\n // In IE 9, 10 and 11 fixed elements containing block is always established by the viewport\n var elementCss = getComputedStyle(element);\n\n if (elementCss.position === 'fixed') {\n return null;\n }\n }\n\n var currentNode = getParentNode(element);\n\n if (isShadowRoot(currentNode)) {\n currentNode = currentNode.host;\n }\n\n while (isHTMLElement(currentNode) && ['html', 'body'].indexOf(getNodeName(currentNode)) < 0) {\n var css = getComputedStyle(currentNode); // This is non-exhaustive but covers the most common CSS properties that\n // create a containing block.\n // https://developer.mozilla.org/en-US/docs/Web/CSS/Containing_block#identifying_the_containing_block\n\n if (css.transform !== 'none' || css.perspective !== 'none' || css.contain === 'paint' || ['transform', 'perspective'].indexOf(css.willChange) !== -1 || isFirefox && css.willChange === 'filter' || isFirefox && css.filter && css.filter !== 'none') {\n return currentNode;\n } else {\n currentNode = currentNode.parentNode;\n }\n }\n\n return null;\n} // Gets the closest ancestor positioned element. Handles some edge cases,\n// such as table ancestors and cross browser bugs.\n\n\nexport default function getOffsetParent(element) {\n var window = getWindow(element);\n var offsetParent = getTrueOffsetParent(element);\n\n while (offsetParent && isTableElement(offsetParent) && getComputedStyle(offsetParent).position === 'static') {\n offsetParent = getTrueOffsetParent(offsetParent);\n }\n\n if (offsetParent && (getNodeName(offsetParent) === 'html' || getNodeName(offsetParent) === 'body' && getComputedStyle(offsetParent).position === 'static')) {\n return window;\n }\n\n return offsetParent || getContainingBlock(element) || window;\n}","export default function getMainAxisFromPlacement(placement) {\n return ['top', 'bottom'].indexOf(placement) >= 0 ? 'x' : 'y';\n}","import { max as mathMax, min as mathMin } from \"./math.js\";\nexport function within(min, value, max) {\n return mathMax(min, mathMin(value, max));\n}\nexport function withinMaxClamp(min, value, max) {\n var v = within(min, value, max);\n return v > max ? max : v;\n}","export default function getFreshSideObject() {\n return {\n top: 0,\n right: 0,\n bottom: 0,\n left: 0\n };\n}","import getFreshSideObject from \"./getFreshSideObject.js\";\nexport default function mergePaddingObject(paddingObject) {\n return Object.assign({}, getFreshSideObject(), paddingObject);\n}","export default function expandToHashMap(value, keys) {\n return keys.reduce(function (hashMap, key) {\n hashMap[key] = value;\n return hashMap;\n }, {});\n}","import getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getLayoutRect from \"../dom-utils/getLayoutRect.js\";\nimport contains from \"../dom-utils/contains.js\";\nimport getOffsetParent from \"../dom-utils/getOffsetParent.js\";\nimport getMainAxisFromPlacement from \"../utils/getMainAxisFromPlacement.js\";\nimport { within } from \"../utils/within.js\";\nimport mergePaddingObject from \"../utils/mergePaddingObject.js\";\nimport expandToHashMap from \"../utils/expandToHashMap.js\";\nimport { left, right, basePlacements, top, bottom } from \"../enums.js\"; // eslint-disable-next-line import/no-unused-modules\n\nvar toPaddingObject = function toPaddingObject(padding, state) {\n padding = typeof padding === 'function' ? padding(Object.assign({}, state.rects, {\n placement: state.placement\n })) : padding;\n return mergePaddingObject(typeof padding !== 'number' ? padding : expandToHashMap(padding, basePlacements));\n};\n\nfunction arrow(_ref) {\n var _state$modifiersData$;\n\n var state = _ref.state,\n name = _ref.name,\n options = _ref.options;\n var arrowElement = state.elements.arrow;\n var popperOffsets = state.modifiersData.popperOffsets;\n var basePlacement = getBasePlacement(state.placement);\n var axis = getMainAxisFromPlacement(basePlacement);\n var isVertical = [left, right].indexOf(basePlacement) >= 0;\n var len = isVertical ? 'height' : 'width';\n\n if (!arrowElement || !popperOffsets) {\n return;\n }\n\n var paddingObject = toPaddingObject(options.padding, state);\n var arrowRect = getLayoutRect(arrowElement);\n var minProp = axis === 'y' ? top : left;\n var maxProp = axis === 'y' ? bottom : right;\n var endDiff = state.rects.reference[len] + state.rects.reference[axis] - popperOffsets[axis] - state.rects.popper[len];\n var startDiff = popperOffsets[axis] - state.rects.reference[axis];\n var arrowOffsetParent = getOffsetParent(arrowElement);\n var clientSize = arrowOffsetParent ? axis === 'y' ? arrowOffsetParent.clientHeight || 0 : arrowOffsetParent.clientWidth || 0 : 0;\n var centerToReference = endDiff / 2 - startDiff / 2; // Make sure the arrow doesn't overflow the popper if the center point is\n // outside of the popper bounds\n\n var min = paddingObject[minProp];\n var max = clientSize - arrowRect[len] - paddingObject[maxProp];\n var center = clientSize / 2 - arrowRect[len] / 2 + centerToReference;\n var offset = within(min, center, max); // Prevents breaking syntax highlighting...\n\n var axisProp = axis;\n state.modifiersData[name] = (_state$modifiersData$ = {}, _state$modifiersData$[axisProp] = offset, _state$modifiersData$.centerOffset = offset - center, _state$modifiersData$);\n}\n\nfunction effect(_ref2) {\n var state = _ref2.state,\n options = _ref2.options;\n var _options$element = options.element,\n arrowElement = _options$element === void 0 ? '[data-popper-arrow]' : _options$element;\n\n if (arrowElement == null) {\n return;\n } // CSS selector\n\n\n if (typeof arrowElement === 'string') {\n arrowElement = state.elements.popper.querySelector(arrowElement);\n\n if (!arrowElement) {\n return;\n }\n }\n\n if (!contains(state.elements.popper, arrowElement)) {\n return;\n }\n\n state.elements.arrow = arrowElement;\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'arrow',\n enabled: true,\n phase: 'main',\n fn: arrow,\n effect: effect,\n requires: ['popperOffsets'],\n requiresIfExists: ['preventOverflow']\n};","export default function getVariation(placement) {\n return placement.split('-')[1];\n}","import { top, left, right, bottom, end } from \"../enums.js\";\nimport getOffsetParent from \"../dom-utils/getOffsetParent.js\";\nimport getWindow from \"../dom-utils/getWindow.js\";\nimport getDocumentElement from \"../dom-utils/getDocumentElement.js\";\nimport getComputedStyle from \"../dom-utils/getComputedStyle.js\";\nimport getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getVariation from \"../utils/getVariation.js\";\nimport { round } from \"../utils/math.js\"; // eslint-disable-next-line import/no-unused-modules\n\nvar unsetSides = {\n top: 'auto',\n right: 'auto',\n bottom: 'auto',\n left: 'auto'\n}; // Round the offsets to the nearest suitable subpixel based on the DPR.\n// Zooming can change the DPR, but it seems to report a value that will\n// cleanly divide the values into the appropriate subpixels.\n\nfunction roundOffsetsByDPR(_ref, win) {\n var x = _ref.x,\n y = _ref.y;\n var dpr = win.devicePixelRatio || 1;\n return {\n x: round(x * dpr) / dpr || 0,\n y: round(y * dpr) / dpr || 0\n };\n}\n\nexport function mapToStyles(_ref2) {\n var _Object$assign2;\n\n var popper = _ref2.popper,\n popperRect = _ref2.popperRect,\n placement = _ref2.placement,\n variation = _ref2.variation,\n offsets = _ref2.offsets,\n position = _ref2.position,\n gpuAcceleration = _ref2.gpuAcceleration,\n adaptive = _ref2.adaptive,\n roundOffsets = _ref2.roundOffsets,\n isFixed = _ref2.isFixed;\n var _offsets$x = offsets.x,\n x = _offsets$x === void 0 ? 0 : _offsets$x,\n _offsets$y = offsets.y,\n y = _offsets$y === void 0 ? 0 : _offsets$y;\n\n var _ref3 = typeof roundOffsets === 'function' ? roundOffsets({\n x: x,\n y: y\n }) : {\n x: x,\n y: y\n };\n\n x = _ref3.x;\n y = _ref3.y;\n var hasX = offsets.hasOwnProperty('x');\n var hasY = offsets.hasOwnProperty('y');\n var sideX = left;\n var sideY = top;\n var win = window;\n\n if (adaptive) {\n var offsetParent = getOffsetParent(popper);\n var heightProp = 'clientHeight';\n var widthProp = 'clientWidth';\n\n if (offsetParent === getWindow(popper)) {\n offsetParent = getDocumentElement(popper);\n\n if (getComputedStyle(offsetParent).position !== 'static' && position === 'absolute') {\n heightProp = 'scrollHeight';\n widthProp = 'scrollWidth';\n }\n } // $FlowFixMe[incompatible-cast]: force type refinement, we compare offsetParent with window above, but Flow doesn't detect it\n\n\n offsetParent = offsetParent;\n\n if (placement === top || (placement === left || placement === right) && variation === end) {\n sideY = bottom;\n var offsetY = isFixed && offsetParent === win && win.visualViewport ? win.visualViewport.height : // $FlowFixMe[prop-missing]\n offsetParent[heightProp];\n y -= offsetY - popperRect.height;\n y *= gpuAcceleration ? 1 : -1;\n }\n\n if (placement === left || (placement === top || placement === bottom) && variation === end) {\n sideX = right;\n var offsetX = isFixed && offsetParent === win && win.visualViewport ? win.visualViewport.width : // $FlowFixMe[prop-missing]\n offsetParent[widthProp];\n x -= offsetX - popperRect.width;\n x *= gpuAcceleration ? 1 : -1;\n }\n }\n\n var commonStyles = Object.assign({\n position: position\n }, adaptive && unsetSides);\n\n var _ref4 = roundOffsets === true ? roundOffsetsByDPR({\n x: x,\n y: y\n }, getWindow(popper)) : {\n x: x,\n y: y\n };\n\n x = _ref4.x;\n y = _ref4.y;\n\n if (gpuAcceleration) {\n var _Object$assign;\n\n return Object.assign({}, commonStyles, (_Object$assign = {}, _Object$assign[sideY] = hasY ? '0' : '', _Object$assign[sideX] = hasX ? '0' : '', _Object$assign.transform = (win.devicePixelRatio || 1) <= 1 ? \"translate(\" + x + \"px, \" + y + \"px)\" : \"translate3d(\" + x + \"px, \" + y + \"px, 0)\", _Object$assign));\n }\n\n return Object.assign({}, commonStyles, (_Object$assign2 = {}, _Object$assign2[sideY] = hasY ? y + \"px\" : '', _Object$assign2[sideX] = hasX ? x + \"px\" : '', _Object$assign2.transform = '', _Object$assign2));\n}\n\nfunction computeStyles(_ref5) {\n var state = _ref5.state,\n options = _ref5.options;\n var _options$gpuAccelerat = options.gpuAcceleration,\n gpuAcceleration = _options$gpuAccelerat === void 0 ? true : _options$gpuAccelerat,\n _options$adaptive = options.adaptive,\n adaptive = _options$adaptive === void 0 ? true : _options$adaptive,\n _options$roundOffsets = options.roundOffsets,\n roundOffsets = _options$roundOffsets === void 0 ? true : _options$roundOffsets;\n var commonStyles = {\n placement: getBasePlacement(state.placement),\n variation: getVariation(state.placement),\n popper: state.elements.popper,\n popperRect: state.rects.popper,\n gpuAcceleration: gpuAcceleration,\n isFixed: state.options.strategy === 'fixed'\n };\n\n if (state.modifiersData.popperOffsets != null) {\n state.styles.popper = Object.assign({}, state.styles.popper, mapToStyles(Object.assign({}, commonStyles, {\n offsets: state.modifiersData.popperOffsets,\n position: state.options.strategy,\n adaptive: adaptive,\n roundOffsets: roundOffsets\n })));\n }\n\n if (state.modifiersData.arrow != null) {\n state.styles.arrow = Object.assign({}, state.styles.arrow, mapToStyles(Object.assign({}, commonStyles, {\n offsets: state.modifiersData.arrow,\n position: 'absolute',\n adaptive: false,\n roundOffsets: roundOffsets\n })));\n }\n\n state.attributes.popper = Object.assign({}, state.attributes.popper, {\n 'data-popper-placement': state.placement\n });\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'computeStyles',\n enabled: true,\n phase: 'beforeWrite',\n fn: computeStyles,\n data: {}\n};","import getWindow from \"../dom-utils/getWindow.js\"; // eslint-disable-next-line import/no-unused-modules\n\nvar passive = {\n passive: true\n};\n\nfunction effect(_ref) {\n var state = _ref.state,\n instance = _ref.instance,\n options = _ref.options;\n var _options$scroll = options.scroll,\n scroll = _options$scroll === void 0 ? true : _options$scroll,\n _options$resize = options.resize,\n resize = _options$resize === void 0 ? true : _options$resize;\n var window = getWindow(state.elements.popper);\n var scrollParents = [].concat(state.scrollParents.reference, state.scrollParents.popper);\n\n if (scroll) {\n scrollParents.forEach(function (scrollParent) {\n scrollParent.addEventListener('scroll', instance.update, passive);\n });\n }\n\n if (resize) {\n window.addEventListener('resize', instance.update, passive);\n }\n\n return function () {\n if (scroll) {\n scrollParents.forEach(function (scrollParent) {\n scrollParent.removeEventListener('scroll', instance.update, passive);\n });\n }\n\n if (resize) {\n window.removeEventListener('resize', instance.update, passive);\n }\n };\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'eventListeners',\n enabled: true,\n phase: 'write',\n fn: function fn() {},\n effect: effect,\n data: {}\n};","var hash = {\n left: 'right',\n right: 'left',\n bottom: 'top',\n top: 'bottom'\n};\nexport default function getOppositePlacement(placement) {\n return placement.replace(/left|right|bottom|top/g, function (matched) {\n return hash[matched];\n });\n}","var hash = {\n start: 'end',\n end: 'start'\n};\nexport default function getOppositeVariationPlacement(placement) {\n return placement.replace(/start|end/g, function (matched) {\n return hash[matched];\n });\n}","import getWindow from \"./getWindow.js\";\nexport default function getWindowScroll(node) {\n var win = getWindow(node);\n var scrollLeft = win.pageXOffset;\n var scrollTop = win.pageYOffset;\n return {\n scrollLeft: scrollLeft,\n scrollTop: scrollTop\n };\n}","import getBoundingClientRect from \"./getBoundingClientRect.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport getWindowScroll from \"./getWindowScroll.js\";\nexport default function getWindowScrollBarX(element) {\n // If has a CSS width greater than the viewport, then this will be\n // incorrect for RTL.\n // Popper 1 is broken in this case and never had a bug report so let's assume\n // it's not an issue. I don't think anyone ever specifies width on \n // anyway.\n // Browsers where the left scrollbar doesn't cause an issue report `0` for\n // this (e.g. Edge 2019, IE11, Safari)\n return getBoundingClientRect(getDocumentElement(element)).left + getWindowScroll(element).scrollLeft;\n}","import getWindow from \"./getWindow.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport getWindowScrollBarX from \"./getWindowScrollBarX.js\";\nimport isLayoutViewport from \"./isLayoutViewport.js\";\nexport default function getViewportRect(element, strategy) {\n var win = getWindow(element);\n var html = getDocumentElement(element);\n var visualViewport = win.visualViewport;\n var width = html.clientWidth;\n var height = html.clientHeight;\n var x = 0;\n var y = 0;\n\n if (visualViewport) {\n width = visualViewport.width;\n height = visualViewport.height;\n var layoutViewport = isLayoutViewport();\n\n if (layoutViewport || !layoutViewport && strategy === 'fixed') {\n x = visualViewport.offsetLeft;\n y = visualViewport.offsetTop;\n }\n }\n\n return {\n width: width,\n height: height,\n x: x + getWindowScrollBarX(element),\n y: y\n };\n}","import getDocumentElement from \"./getDocumentElement.js\";\nimport getComputedStyle from \"./getComputedStyle.js\";\nimport getWindowScrollBarX from \"./getWindowScrollBarX.js\";\nimport getWindowScroll from \"./getWindowScroll.js\";\nimport { max } from \"../utils/math.js\"; // Gets the entire size of the scrollable document area, even extending outside\n// of the `` and `` rect bounds if horizontally scrollable\n\nexport default function getDocumentRect(element) {\n var _element$ownerDocumen;\n\n var html = getDocumentElement(element);\n var winScroll = getWindowScroll(element);\n var body = (_element$ownerDocumen = element.ownerDocument) == null ? void 0 : _element$ownerDocumen.body;\n var width = max(html.scrollWidth, html.clientWidth, body ? body.scrollWidth : 0, body ? body.clientWidth : 0);\n var height = max(html.scrollHeight, html.clientHeight, body ? body.scrollHeight : 0, body ? body.clientHeight : 0);\n var x = -winScroll.scrollLeft + getWindowScrollBarX(element);\n var y = -winScroll.scrollTop;\n\n if (getComputedStyle(body || html).direction === 'rtl') {\n x += max(html.clientWidth, body ? body.clientWidth : 0) - width;\n }\n\n return {\n width: width,\n height: height,\n x: x,\n y: y\n };\n}","import getComputedStyle from \"./getComputedStyle.js\";\nexport default function isScrollParent(element) {\n // Firefox wants us to check `-x` and `-y` variations as well\n var _getComputedStyle = getComputedStyle(element),\n overflow = _getComputedStyle.overflow,\n overflowX = _getComputedStyle.overflowX,\n overflowY = _getComputedStyle.overflowY;\n\n return /auto|scroll|overlay|hidden/.test(overflow + overflowY + overflowX);\n}","import getParentNode from \"./getParentNode.js\";\nimport isScrollParent from \"./isScrollParent.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport { isHTMLElement } from \"./instanceOf.js\";\nexport default function getScrollParent(node) {\n if (['html', 'body', '#document'].indexOf(getNodeName(node)) >= 0) {\n // $FlowFixMe[incompatible-return]: assume body is always available\n return node.ownerDocument.body;\n }\n\n if (isHTMLElement(node) && isScrollParent(node)) {\n return node;\n }\n\n return getScrollParent(getParentNode(node));\n}","import getScrollParent from \"./getScrollParent.js\";\nimport getParentNode from \"./getParentNode.js\";\nimport getWindow from \"./getWindow.js\";\nimport isScrollParent from \"./isScrollParent.js\";\n/*\ngiven a DOM element, return the list of all scroll parents, up the list of ancesors\nuntil we get to the top window object. This list is what we attach scroll listeners\nto, because if any of these parent elements scroll, we'll need to re-calculate the\nreference element's position.\n*/\n\nexport default function listScrollParents(element, list) {\n var _element$ownerDocumen;\n\n if (list === void 0) {\n list = [];\n }\n\n var scrollParent = getScrollParent(element);\n var isBody = scrollParent === ((_element$ownerDocumen = element.ownerDocument) == null ? void 0 : _element$ownerDocumen.body);\n var win = getWindow(scrollParent);\n var target = isBody ? [win].concat(win.visualViewport || [], isScrollParent(scrollParent) ? scrollParent : []) : scrollParent;\n var updatedList = list.concat(target);\n return isBody ? updatedList : // $FlowFixMe[incompatible-call]: isBody tells us target will be an HTMLElement here\n updatedList.concat(listScrollParents(getParentNode(target)));\n}","export default function rectToClientRect(rect) {\n return Object.assign({}, rect, {\n left: rect.x,\n top: rect.y,\n right: rect.x + rect.width,\n bottom: rect.y + rect.height\n });\n}","import { viewport } from \"../enums.js\";\nimport getViewportRect from \"./getViewportRect.js\";\nimport getDocumentRect from \"./getDocumentRect.js\";\nimport listScrollParents from \"./listScrollParents.js\";\nimport getOffsetParent from \"./getOffsetParent.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport getComputedStyle from \"./getComputedStyle.js\";\nimport { isElement, isHTMLElement } from \"./instanceOf.js\";\nimport getBoundingClientRect from \"./getBoundingClientRect.js\";\nimport getParentNode from \"./getParentNode.js\";\nimport contains from \"./contains.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport rectToClientRect from \"../utils/rectToClientRect.js\";\nimport { max, min } from \"../utils/math.js\";\n\nfunction getInnerBoundingClientRect(element, strategy) {\n var rect = getBoundingClientRect(element, false, strategy === 'fixed');\n rect.top = rect.top + element.clientTop;\n rect.left = rect.left + element.clientLeft;\n rect.bottom = rect.top + element.clientHeight;\n rect.right = rect.left + element.clientWidth;\n rect.width = element.clientWidth;\n rect.height = element.clientHeight;\n rect.x = rect.left;\n rect.y = rect.top;\n return rect;\n}\n\nfunction getClientRectFromMixedType(element, clippingParent, strategy) {\n return clippingParent === viewport ? rectToClientRect(getViewportRect(element, strategy)) : isElement(clippingParent) ? getInnerBoundingClientRect(clippingParent, strategy) : rectToClientRect(getDocumentRect(getDocumentElement(element)));\n} // A \"clipping parent\" is an overflowable container with the characteristic of\n// clipping (or hiding) overflowing elements with a position different from\n// `initial`\n\n\nfunction getClippingParents(element) {\n var clippingParents = listScrollParents(getParentNode(element));\n var canEscapeClipping = ['absolute', 'fixed'].indexOf(getComputedStyle(element).position) >= 0;\n var clipperElement = canEscapeClipping && isHTMLElement(element) ? getOffsetParent(element) : element;\n\n if (!isElement(clipperElement)) {\n return [];\n } // $FlowFixMe[incompatible-return]: https://github.com/facebook/flow/issues/1414\n\n\n return clippingParents.filter(function (clippingParent) {\n return isElement(clippingParent) && contains(clippingParent, clipperElement) && getNodeName(clippingParent) !== 'body';\n });\n} // Gets the maximum area that the element is visible in due to any number of\n// clipping parents\n\n\nexport default function getClippingRect(element, boundary, rootBoundary, strategy) {\n var mainClippingParents = boundary === 'clippingParents' ? getClippingParents(element) : [].concat(boundary);\n var clippingParents = [].concat(mainClippingParents, [rootBoundary]);\n var firstClippingParent = clippingParents[0];\n var clippingRect = clippingParents.reduce(function (accRect, clippingParent) {\n var rect = getClientRectFromMixedType(element, clippingParent, strategy);\n accRect.top = max(rect.top, accRect.top);\n accRect.right = min(rect.right, accRect.right);\n accRect.bottom = min(rect.bottom, accRect.bottom);\n accRect.left = max(rect.left, accRect.left);\n return accRect;\n }, getClientRectFromMixedType(element, firstClippingParent, strategy));\n clippingRect.width = clippingRect.right - clippingRect.left;\n clippingRect.height = clippingRect.bottom - clippingRect.top;\n clippingRect.x = clippingRect.left;\n clippingRect.y = clippingRect.top;\n return clippingRect;\n}","import getBasePlacement from \"./getBasePlacement.js\";\nimport getVariation from \"./getVariation.js\";\nimport getMainAxisFromPlacement from \"./getMainAxisFromPlacement.js\";\nimport { top, right, bottom, left, start, end } from \"../enums.js\";\nexport default function computeOffsets(_ref) {\n var reference = _ref.reference,\n element = _ref.element,\n placement = _ref.placement;\n var basePlacement = placement ? getBasePlacement(placement) : null;\n var variation = placement ? getVariation(placement) : null;\n var commonX = reference.x + reference.width / 2 - element.width / 2;\n var commonY = reference.y + reference.height / 2 - element.height / 2;\n var offsets;\n\n switch (basePlacement) {\n case top:\n offsets = {\n x: commonX,\n y: reference.y - element.height\n };\n break;\n\n case bottom:\n offsets = {\n x: commonX,\n y: reference.y + reference.height\n };\n break;\n\n case right:\n offsets = {\n x: reference.x + reference.width,\n y: commonY\n };\n break;\n\n case left:\n offsets = {\n x: reference.x - element.width,\n y: commonY\n };\n break;\n\n default:\n offsets = {\n x: reference.x,\n y: reference.y\n };\n }\n\n var mainAxis = basePlacement ? getMainAxisFromPlacement(basePlacement) : null;\n\n if (mainAxis != null) {\n var len = mainAxis === 'y' ? 'height' : 'width';\n\n switch (variation) {\n case start:\n offsets[mainAxis] = offsets[mainAxis] - (reference[len] / 2 - element[len] / 2);\n break;\n\n case end:\n offsets[mainAxis] = offsets[mainAxis] + (reference[len] / 2 - element[len] / 2);\n break;\n\n default:\n }\n }\n\n return offsets;\n}","import getClippingRect from \"../dom-utils/getClippingRect.js\";\nimport getDocumentElement from \"../dom-utils/getDocumentElement.js\";\nimport getBoundingClientRect from \"../dom-utils/getBoundingClientRect.js\";\nimport computeOffsets from \"./computeOffsets.js\";\nimport rectToClientRect from \"./rectToClientRect.js\";\nimport { clippingParents, reference, popper, bottom, top, right, basePlacements, viewport } from \"../enums.js\";\nimport { isElement } from \"../dom-utils/instanceOf.js\";\nimport mergePaddingObject from \"./mergePaddingObject.js\";\nimport expandToHashMap from \"./expandToHashMap.js\"; // eslint-disable-next-line import/no-unused-modules\n\nexport default function detectOverflow(state, options) {\n if (options === void 0) {\n options = {};\n }\n\n var _options = options,\n _options$placement = _options.placement,\n placement = _options$placement === void 0 ? state.placement : _options$placement,\n _options$strategy = _options.strategy,\n strategy = _options$strategy === void 0 ? state.strategy : _options$strategy,\n _options$boundary = _options.boundary,\n boundary = _options$boundary === void 0 ? clippingParents : _options$boundary,\n _options$rootBoundary = _options.rootBoundary,\n rootBoundary = _options$rootBoundary === void 0 ? viewport : _options$rootBoundary,\n _options$elementConte = _options.elementContext,\n elementContext = _options$elementConte === void 0 ? popper : _options$elementConte,\n _options$altBoundary = _options.altBoundary,\n altBoundary = _options$altBoundary === void 0 ? false : _options$altBoundary,\n _options$padding = _options.padding,\n padding = _options$padding === void 0 ? 0 : _options$padding;\n var paddingObject = mergePaddingObject(typeof padding !== 'number' ? padding : expandToHashMap(padding, basePlacements));\n var altContext = elementContext === popper ? reference : popper;\n var popperRect = state.rects.popper;\n var element = state.elements[altBoundary ? altContext : elementContext];\n var clippingClientRect = getClippingRect(isElement(element) ? element : element.contextElement || getDocumentElement(state.elements.popper), boundary, rootBoundary, strategy);\n var referenceClientRect = getBoundingClientRect(state.elements.reference);\n var popperOffsets = computeOffsets({\n reference: referenceClientRect,\n element: popperRect,\n strategy: 'absolute',\n placement: placement\n });\n var popperClientRect = rectToClientRect(Object.assign({}, popperRect, popperOffsets));\n var elementClientRect = elementContext === popper ? popperClientRect : referenceClientRect; // positive = overflowing the clipping rect\n // 0 or negative = within the clipping rect\n\n var overflowOffsets = {\n top: clippingClientRect.top - elementClientRect.top + paddingObject.top,\n bottom: elementClientRect.bottom - clippingClientRect.bottom + paddingObject.bottom,\n left: clippingClientRect.left - elementClientRect.left + paddingObject.left,\n right: elementClientRect.right - clippingClientRect.right + paddingObject.right\n };\n var offsetData = state.modifiersData.offset; // Offsets can be applied only to the popper element\n\n if (elementContext === popper && offsetData) {\n var offset = offsetData[placement];\n Object.keys(overflowOffsets).forEach(function (key) {\n var multiply = [right, bottom].indexOf(key) >= 0 ? 1 : -1;\n var axis = [top, bottom].indexOf(key) >= 0 ? 'y' : 'x';\n overflowOffsets[key] += offset[axis] * multiply;\n });\n }\n\n return overflowOffsets;\n}","import getVariation from \"./getVariation.js\";\nimport { variationPlacements, basePlacements, placements as allPlacements } from \"../enums.js\";\nimport detectOverflow from \"./detectOverflow.js\";\nimport getBasePlacement from \"./getBasePlacement.js\";\nexport default function computeAutoPlacement(state, options) {\n if (options === void 0) {\n options = {};\n }\n\n var _options = options,\n placement = _options.placement,\n boundary = _options.boundary,\n rootBoundary = _options.rootBoundary,\n padding = _options.padding,\n flipVariations = _options.flipVariations,\n _options$allowedAutoP = _options.allowedAutoPlacements,\n allowedAutoPlacements = _options$allowedAutoP === void 0 ? allPlacements : _options$allowedAutoP;\n var variation = getVariation(placement);\n var placements = variation ? flipVariations ? variationPlacements : variationPlacements.filter(function (placement) {\n return getVariation(placement) === variation;\n }) : basePlacements;\n var allowedPlacements = placements.filter(function (placement) {\n return allowedAutoPlacements.indexOf(placement) >= 0;\n });\n\n if (allowedPlacements.length === 0) {\n allowedPlacements = placements;\n } // $FlowFixMe[incompatible-type]: Flow seems to have problems with two array unions...\n\n\n var overflows = allowedPlacements.reduce(function (acc, placement) {\n acc[placement] = detectOverflow(state, {\n placement: placement,\n boundary: boundary,\n rootBoundary: rootBoundary,\n padding: padding\n })[getBasePlacement(placement)];\n return acc;\n }, {});\n return Object.keys(overflows).sort(function (a, b) {\n return overflows[a] - overflows[b];\n });\n}","import getOppositePlacement from \"../utils/getOppositePlacement.js\";\nimport getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getOppositeVariationPlacement from \"../utils/getOppositeVariationPlacement.js\";\nimport detectOverflow from \"../utils/detectOverflow.js\";\nimport computeAutoPlacement from \"../utils/computeAutoPlacement.js\";\nimport { bottom, top, start, right, left, auto } from \"../enums.js\";\nimport getVariation from \"../utils/getVariation.js\"; // eslint-disable-next-line import/no-unused-modules\n\nfunction getExpandedFallbackPlacements(placement) {\n if (getBasePlacement(placement) === auto) {\n return [];\n }\n\n var oppositePlacement = getOppositePlacement(placement);\n return [getOppositeVariationPlacement(placement), oppositePlacement, getOppositeVariationPlacement(oppositePlacement)];\n}\n\nfunction flip(_ref) {\n var state = _ref.state,\n options = _ref.options,\n name = _ref.name;\n\n if (state.modifiersData[name]._skip) {\n return;\n }\n\n var _options$mainAxis = options.mainAxis,\n checkMainAxis = _options$mainAxis === void 0 ? true : _options$mainAxis,\n _options$altAxis = options.altAxis,\n checkAltAxis = _options$altAxis === void 0 ? true : _options$altAxis,\n specifiedFallbackPlacements = options.fallbackPlacements,\n padding = options.padding,\n boundary = options.boundary,\n rootBoundary = options.rootBoundary,\n altBoundary = options.altBoundary,\n _options$flipVariatio = options.flipVariations,\n flipVariations = _options$flipVariatio === void 0 ? true : _options$flipVariatio,\n allowedAutoPlacements = options.allowedAutoPlacements;\n var preferredPlacement = state.options.placement;\n var basePlacement = getBasePlacement(preferredPlacement);\n var isBasePlacement = basePlacement === preferredPlacement;\n var fallbackPlacements = specifiedFallbackPlacements || (isBasePlacement || !flipVariations ? [getOppositePlacement(preferredPlacement)] : getExpandedFallbackPlacements(preferredPlacement));\n var placements = [preferredPlacement].concat(fallbackPlacements).reduce(function (acc, placement) {\n return acc.concat(getBasePlacement(placement) === auto ? computeAutoPlacement(state, {\n placement: placement,\n boundary: boundary,\n rootBoundary: rootBoundary,\n padding: padding,\n flipVariations: flipVariations,\n allowedAutoPlacements: allowedAutoPlacements\n }) : placement);\n }, []);\n var referenceRect = state.rects.reference;\n var popperRect = state.rects.popper;\n var checksMap = new Map();\n var makeFallbackChecks = true;\n var firstFittingPlacement = placements[0];\n\n for (var i = 0; i < placements.length; i++) {\n var placement = placements[i];\n\n var _basePlacement = getBasePlacement(placement);\n\n var isStartVariation = getVariation(placement) === start;\n var isVertical = [top, bottom].indexOf(_basePlacement) >= 0;\n var len = isVertical ? 'width' : 'height';\n var overflow = detectOverflow(state, {\n placement: placement,\n boundary: boundary,\n rootBoundary: rootBoundary,\n altBoundary: altBoundary,\n padding: padding\n });\n var mainVariationSide = isVertical ? isStartVariation ? right : left : isStartVariation ? bottom : top;\n\n if (referenceRect[len] > popperRect[len]) {\n mainVariationSide = getOppositePlacement(mainVariationSide);\n }\n\n var altVariationSide = getOppositePlacement(mainVariationSide);\n var checks = [];\n\n if (checkMainAxis) {\n checks.push(overflow[_basePlacement] <= 0);\n }\n\n if (checkAltAxis) {\n checks.push(overflow[mainVariationSide] <= 0, overflow[altVariationSide] <= 0);\n }\n\n if (checks.every(function (check) {\n return check;\n })) {\n firstFittingPlacement = placement;\n makeFallbackChecks = false;\n break;\n }\n\n checksMap.set(placement, checks);\n }\n\n if (makeFallbackChecks) {\n // `2` may be desired in some cases – research later\n var numberOfChecks = flipVariations ? 3 : 1;\n\n var _loop = function _loop(_i) {\n var fittingPlacement = placements.find(function (placement) {\n var checks = checksMap.get(placement);\n\n if (checks) {\n return checks.slice(0, _i).every(function (check) {\n return check;\n });\n }\n });\n\n if (fittingPlacement) {\n firstFittingPlacement = fittingPlacement;\n return \"break\";\n }\n };\n\n for (var _i = numberOfChecks; _i > 0; _i--) {\n var _ret = _loop(_i);\n\n if (_ret === \"break\") break;\n }\n }\n\n if (state.placement !== firstFittingPlacement) {\n state.modifiersData[name]._skip = true;\n state.placement = firstFittingPlacement;\n state.reset = true;\n }\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'flip',\n enabled: true,\n phase: 'main',\n fn: flip,\n requiresIfExists: ['offset'],\n data: {\n _skip: false\n }\n};","import { top, bottom, left, right } from \"../enums.js\";\nimport detectOverflow from \"../utils/detectOverflow.js\";\n\nfunction getSideOffsets(overflow, rect, preventedOffsets) {\n if (preventedOffsets === void 0) {\n preventedOffsets = {\n x: 0,\n y: 0\n };\n }\n\n return {\n top: overflow.top - rect.height - preventedOffsets.y,\n right: overflow.right - rect.width + preventedOffsets.x,\n bottom: overflow.bottom - rect.height + preventedOffsets.y,\n left: overflow.left - rect.width - preventedOffsets.x\n };\n}\n\nfunction isAnySideFullyClipped(overflow) {\n return [top, right, bottom, left].some(function (side) {\n return overflow[side] >= 0;\n });\n}\n\nfunction hide(_ref) {\n var state = _ref.state,\n name = _ref.name;\n var referenceRect = state.rects.reference;\n var popperRect = state.rects.popper;\n var preventedOffsets = state.modifiersData.preventOverflow;\n var referenceOverflow = detectOverflow(state, {\n elementContext: 'reference'\n });\n var popperAltOverflow = detectOverflow(state, {\n altBoundary: true\n });\n var referenceClippingOffsets = getSideOffsets(referenceOverflow, referenceRect);\n var popperEscapeOffsets = getSideOffsets(popperAltOverflow, popperRect, preventedOffsets);\n var isReferenceHidden = isAnySideFullyClipped(referenceClippingOffsets);\n var hasPopperEscaped = isAnySideFullyClipped(popperEscapeOffsets);\n state.modifiersData[name] = {\n referenceClippingOffsets: referenceClippingOffsets,\n popperEscapeOffsets: popperEscapeOffsets,\n isReferenceHidden: isReferenceHidden,\n hasPopperEscaped: hasPopperEscaped\n };\n state.attributes.popper = Object.assign({}, state.attributes.popper, {\n 'data-popper-reference-hidden': isReferenceHidden,\n 'data-popper-escaped': hasPopperEscaped\n });\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'hide',\n enabled: true,\n phase: 'main',\n requiresIfExists: ['preventOverflow'],\n fn: hide\n};","import getBasePlacement from \"../utils/getBasePlacement.js\";\nimport { top, left, right, placements } from \"../enums.js\"; // eslint-disable-next-line import/no-unused-modules\n\nexport function distanceAndSkiddingToXY(placement, rects, offset) {\n var basePlacement = getBasePlacement(placement);\n var invertDistance = [left, top].indexOf(basePlacement) >= 0 ? -1 : 1;\n\n var _ref = typeof offset === 'function' ? offset(Object.assign({}, rects, {\n placement: placement\n })) : offset,\n skidding = _ref[0],\n distance = _ref[1];\n\n skidding = skidding || 0;\n distance = (distance || 0) * invertDistance;\n return [left, right].indexOf(basePlacement) >= 0 ? {\n x: distance,\n y: skidding\n } : {\n x: skidding,\n y: distance\n };\n}\n\nfunction offset(_ref2) {\n var state = _ref2.state,\n options = _ref2.options,\n name = _ref2.name;\n var _options$offset = options.offset,\n offset = _options$offset === void 0 ? [0, 0] : _options$offset;\n var data = placements.reduce(function (acc, placement) {\n acc[placement] = distanceAndSkiddingToXY(placement, state.rects, offset);\n return acc;\n }, {});\n var _data$state$placement = data[state.placement],\n x = _data$state$placement.x,\n y = _data$state$placement.y;\n\n if (state.modifiersData.popperOffsets != null) {\n state.modifiersData.popperOffsets.x += x;\n state.modifiersData.popperOffsets.y += y;\n }\n\n state.modifiersData[name] = data;\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'offset',\n enabled: true,\n phase: 'main',\n requires: ['popperOffsets'],\n fn: offset\n};","import computeOffsets from \"../utils/computeOffsets.js\";\n\nfunction popperOffsets(_ref) {\n var state = _ref.state,\n name = _ref.name;\n // Offsets are the actual position the popper needs to have to be\n // properly positioned near its reference element\n // This is the most basic placement, and will be adjusted by\n // the modifiers in the next step\n state.modifiersData[name] = computeOffsets({\n reference: state.rects.reference,\n element: state.rects.popper,\n strategy: 'absolute',\n placement: state.placement\n });\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'popperOffsets',\n enabled: true,\n phase: 'read',\n fn: popperOffsets,\n data: {}\n};","export default function getAltAxis(axis) {\n return axis === 'x' ? 'y' : 'x';\n}","import { top, left, right, bottom, start } from \"../enums.js\";\nimport getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getMainAxisFromPlacement from \"../utils/getMainAxisFromPlacement.js\";\nimport getAltAxis from \"../utils/getAltAxis.js\";\nimport { within, withinMaxClamp } from \"../utils/within.js\";\nimport getLayoutRect from \"../dom-utils/getLayoutRect.js\";\nimport getOffsetParent from \"../dom-utils/getOffsetParent.js\";\nimport detectOverflow from \"../utils/detectOverflow.js\";\nimport getVariation from \"../utils/getVariation.js\";\nimport getFreshSideObject from \"../utils/getFreshSideObject.js\";\nimport { min as mathMin, max as mathMax } from \"../utils/math.js\";\n\nfunction preventOverflow(_ref) {\n var state = _ref.state,\n options = _ref.options,\n name = _ref.name;\n var _options$mainAxis = options.mainAxis,\n checkMainAxis = _options$mainAxis === void 0 ? true : _options$mainAxis,\n _options$altAxis = options.altAxis,\n checkAltAxis = _options$altAxis === void 0 ? false : _options$altAxis,\n boundary = options.boundary,\n rootBoundary = options.rootBoundary,\n altBoundary = options.altBoundary,\n padding = options.padding,\n _options$tether = options.tether,\n tether = _options$tether === void 0 ? true : _options$tether,\n _options$tetherOffset = options.tetherOffset,\n tetherOffset = _options$tetherOffset === void 0 ? 0 : _options$tetherOffset;\n var overflow = detectOverflow(state, {\n boundary: boundary,\n rootBoundary: rootBoundary,\n padding: padding,\n altBoundary: altBoundary\n });\n var basePlacement = getBasePlacement(state.placement);\n var variation = getVariation(state.placement);\n var isBasePlacement = !variation;\n var mainAxis = getMainAxisFromPlacement(basePlacement);\n var altAxis = getAltAxis(mainAxis);\n var popperOffsets = state.modifiersData.popperOffsets;\n var referenceRect = state.rects.reference;\n var popperRect = state.rects.popper;\n var tetherOffsetValue = typeof tetherOffset === 'function' ? tetherOffset(Object.assign({}, state.rects, {\n placement: state.placement\n })) : tetherOffset;\n var normalizedTetherOffsetValue = typeof tetherOffsetValue === 'number' ? {\n mainAxis: tetherOffsetValue,\n altAxis: tetherOffsetValue\n } : Object.assign({\n mainAxis: 0,\n altAxis: 0\n }, tetherOffsetValue);\n var offsetModifierState = state.modifiersData.offset ? state.modifiersData.offset[state.placement] : null;\n var data = {\n x: 0,\n y: 0\n };\n\n if (!popperOffsets) {\n return;\n }\n\n if (checkMainAxis) {\n var _offsetModifierState$;\n\n var mainSide = mainAxis === 'y' ? top : left;\n var altSide = mainAxis === 'y' ? bottom : right;\n var len = mainAxis === 'y' ? 'height' : 'width';\n var offset = popperOffsets[mainAxis];\n var min = offset + overflow[mainSide];\n var max = offset - overflow[altSide];\n var additive = tether ? -popperRect[len] / 2 : 0;\n var minLen = variation === start ? referenceRect[len] : popperRect[len];\n var maxLen = variation === start ? -popperRect[len] : -referenceRect[len]; // We need to include the arrow in the calculation so the arrow doesn't go\n // outside the reference bounds\n\n var arrowElement = state.elements.arrow;\n var arrowRect = tether && arrowElement ? getLayoutRect(arrowElement) : {\n width: 0,\n height: 0\n };\n var arrowPaddingObject = state.modifiersData['arrow#persistent'] ? state.modifiersData['arrow#persistent'].padding : getFreshSideObject();\n var arrowPaddingMin = arrowPaddingObject[mainSide];\n var arrowPaddingMax = arrowPaddingObject[altSide]; // If the reference length is smaller than the arrow length, we don't want\n // to include its full size in the calculation. If the reference is small\n // and near the edge of a boundary, the popper can overflow even if the\n // reference is not overflowing as well (e.g. virtual elements with no\n // width or height)\n\n var arrowLen = within(0, referenceRect[len], arrowRect[len]);\n var minOffset = isBasePlacement ? referenceRect[len] / 2 - additive - arrowLen - arrowPaddingMin - normalizedTetherOffsetValue.mainAxis : minLen - arrowLen - arrowPaddingMin - normalizedTetherOffsetValue.mainAxis;\n var maxOffset = isBasePlacement ? -referenceRect[len] / 2 + additive + arrowLen + arrowPaddingMax + normalizedTetherOffsetValue.mainAxis : maxLen + arrowLen + arrowPaddingMax + normalizedTetherOffsetValue.mainAxis;\n var arrowOffsetParent = state.elements.arrow && getOffsetParent(state.elements.arrow);\n var clientOffset = arrowOffsetParent ? mainAxis === 'y' ? arrowOffsetParent.clientTop || 0 : arrowOffsetParent.clientLeft || 0 : 0;\n var offsetModifierValue = (_offsetModifierState$ = offsetModifierState == null ? void 0 : offsetModifierState[mainAxis]) != null ? _offsetModifierState$ : 0;\n var tetherMin = offset + minOffset - offsetModifierValue - clientOffset;\n var tetherMax = offset + maxOffset - offsetModifierValue;\n var preventedOffset = within(tether ? mathMin(min, tetherMin) : min, offset, tether ? mathMax(max, tetherMax) : max);\n popperOffsets[mainAxis] = preventedOffset;\n data[mainAxis] = preventedOffset - offset;\n }\n\n if (checkAltAxis) {\n var _offsetModifierState$2;\n\n var _mainSide = mainAxis === 'x' ? top : left;\n\n var _altSide = mainAxis === 'x' ? bottom : right;\n\n var _offset = popperOffsets[altAxis];\n\n var _len = altAxis === 'y' ? 'height' : 'width';\n\n var _min = _offset + overflow[_mainSide];\n\n var _max = _offset - overflow[_altSide];\n\n var isOriginSide = [top, left].indexOf(basePlacement) !== -1;\n\n var _offsetModifierValue = (_offsetModifierState$2 = offsetModifierState == null ? void 0 : offsetModifierState[altAxis]) != null ? _offsetModifierState$2 : 0;\n\n var _tetherMin = isOriginSide ? _min : _offset - referenceRect[_len] - popperRect[_len] - _offsetModifierValue + normalizedTetherOffsetValue.altAxis;\n\n var _tetherMax = isOriginSide ? _offset + referenceRect[_len] + popperRect[_len] - _offsetModifierValue - normalizedTetherOffsetValue.altAxis : _max;\n\n var _preventedOffset = tether && isOriginSide ? withinMaxClamp(_tetherMin, _offset, _tetherMax) : within(tether ? _tetherMin : _min, _offset, tether ? _tetherMax : _max);\n\n popperOffsets[altAxis] = _preventedOffset;\n data[altAxis] = _preventedOffset - _offset;\n }\n\n state.modifiersData[name] = data;\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'preventOverflow',\n enabled: true,\n phase: 'main',\n fn: preventOverflow,\n requiresIfExists: ['offset']\n};","export default function getHTMLElementScroll(element) {\n return {\n scrollLeft: element.scrollLeft,\n scrollTop: element.scrollTop\n };\n}","import getWindowScroll from \"./getWindowScroll.js\";\nimport getWindow from \"./getWindow.js\";\nimport { isHTMLElement } from \"./instanceOf.js\";\nimport getHTMLElementScroll from \"./getHTMLElementScroll.js\";\nexport default function getNodeScroll(node) {\n if (node === getWindow(node) || !isHTMLElement(node)) {\n return getWindowScroll(node);\n } else {\n return getHTMLElementScroll(node);\n }\n}","import getBoundingClientRect from \"./getBoundingClientRect.js\";\nimport getNodeScroll from \"./getNodeScroll.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport { isHTMLElement } from \"./instanceOf.js\";\nimport getWindowScrollBarX from \"./getWindowScrollBarX.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport isScrollParent from \"./isScrollParent.js\";\nimport { round } from \"../utils/math.js\";\n\nfunction isElementScaled(element) {\n var rect = element.getBoundingClientRect();\n var scaleX = round(rect.width) / element.offsetWidth || 1;\n var scaleY = round(rect.height) / element.offsetHeight || 1;\n return scaleX !== 1 || scaleY !== 1;\n} // Returns the composite rect of an element relative to its offsetParent.\n// Composite means it takes into account transforms as well as layout.\n\n\nexport default function getCompositeRect(elementOrVirtualElement, offsetParent, isFixed) {\n if (isFixed === void 0) {\n isFixed = false;\n }\n\n var isOffsetParentAnElement = isHTMLElement(offsetParent);\n var offsetParentIsScaled = isHTMLElement(offsetParent) && isElementScaled(offsetParent);\n var documentElement = getDocumentElement(offsetParent);\n var rect = getBoundingClientRect(elementOrVirtualElement, offsetParentIsScaled, isFixed);\n var scroll = {\n scrollLeft: 0,\n scrollTop: 0\n };\n var offsets = {\n x: 0,\n y: 0\n };\n\n if (isOffsetParentAnElement || !isOffsetParentAnElement && !isFixed) {\n if (getNodeName(offsetParent) !== 'body' || // https://github.com/popperjs/popper-core/issues/1078\n isScrollParent(documentElement)) {\n scroll = getNodeScroll(offsetParent);\n }\n\n if (isHTMLElement(offsetParent)) {\n offsets = getBoundingClientRect(offsetParent, true);\n offsets.x += offsetParent.clientLeft;\n offsets.y += offsetParent.clientTop;\n } else if (documentElement) {\n offsets.x = getWindowScrollBarX(documentElement);\n }\n }\n\n return {\n x: rect.left + scroll.scrollLeft - offsets.x,\n y: rect.top + scroll.scrollTop - offsets.y,\n width: rect.width,\n height: rect.height\n };\n}","import { modifierPhases } from \"../enums.js\"; // source: https://stackoverflow.com/questions/49875255\n\nfunction order(modifiers) {\n var map = new Map();\n var visited = new Set();\n var result = [];\n modifiers.forEach(function (modifier) {\n map.set(modifier.name, modifier);\n }); // On visiting object, check for its dependencies and visit them recursively\n\n function sort(modifier) {\n visited.add(modifier.name);\n var requires = [].concat(modifier.requires || [], modifier.requiresIfExists || []);\n requires.forEach(function (dep) {\n if (!visited.has(dep)) {\n var depModifier = map.get(dep);\n\n if (depModifier) {\n sort(depModifier);\n }\n }\n });\n result.push(modifier);\n }\n\n modifiers.forEach(function (modifier) {\n if (!visited.has(modifier.name)) {\n // check for visited object\n sort(modifier);\n }\n });\n return result;\n}\n\nexport default function orderModifiers(modifiers) {\n // order based on dependencies\n var orderedModifiers = order(modifiers); // order based on phase\n\n return modifierPhases.reduce(function (acc, phase) {\n return acc.concat(orderedModifiers.filter(function (modifier) {\n return modifier.phase === phase;\n }));\n }, []);\n}","export default function debounce(fn) {\n var pending;\n return function () {\n if (!pending) {\n pending = new Promise(function (resolve) {\n Promise.resolve().then(function () {\n pending = undefined;\n resolve(fn());\n });\n });\n }\n\n return pending;\n };\n}","export default function mergeByName(modifiers) {\n var merged = modifiers.reduce(function (merged, current) {\n var existing = merged[current.name];\n merged[current.name] = existing ? Object.assign({}, existing, current, {\n options: Object.assign({}, existing.options, current.options),\n data: Object.assign({}, existing.data, current.data)\n }) : current;\n return merged;\n }, {}); // IE11 does not support Object.values\n\n return Object.keys(merged).map(function (key) {\n return merged[key];\n });\n}","import getCompositeRect from \"./dom-utils/getCompositeRect.js\";\nimport getLayoutRect from \"./dom-utils/getLayoutRect.js\";\nimport listScrollParents from \"./dom-utils/listScrollParents.js\";\nimport getOffsetParent from \"./dom-utils/getOffsetParent.js\";\nimport orderModifiers from \"./utils/orderModifiers.js\";\nimport debounce from \"./utils/debounce.js\";\nimport mergeByName from \"./utils/mergeByName.js\";\nimport detectOverflow from \"./utils/detectOverflow.js\";\nimport { isElement } from \"./dom-utils/instanceOf.js\";\nvar DEFAULT_OPTIONS = {\n placement: 'bottom',\n modifiers: [],\n strategy: 'absolute'\n};\n\nfunction areValidElements() {\n for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {\n args[_key] = arguments[_key];\n }\n\n return !args.some(function (element) {\n return !(element && typeof element.getBoundingClientRect === 'function');\n });\n}\n\nexport function popperGenerator(generatorOptions) {\n if (generatorOptions === void 0) {\n generatorOptions = {};\n }\n\n var _generatorOptions = generatorOptions,\n _generatorOptions$def = _generatorOptions.defaultModifiers,\n defaultModifiers = _generatorOptions$def === void 0 ? [] : _generatorOptions$def,\n _generatorOptions$def2 = _generatorOptions.defaultOptions,\n defaultOptions = _generatorOptions$def2 === void 0 ? DEFAULT_OPTIONS : _generatorOptions$def2;\n return function createPopper(reference, popper, options) {\n if (options === void 0) {\n options = defaultOptions;\n }\n\n var state = {\n placement: 'bottom',\n orderedModifiers: [],\n options: Object.assign({}, DEFAULT_OPTIONS, defaultOptions),\n modifiersData: {},\n elements: {\n reference: reference,\n popper: popper\n },\n attributes: {},\n styles: {}\n };\n var effectCleanupFns = [];\n var isDestroyed = false;\n var instance = {\n state: state,\n setOptions: function setOptions(setOptionsAction) {\n var options = typeof setOptionsAction === 'function' ? setOptionsAction(state.options) : setOptionsAction;\n cleanupModifierEffects();\n state.options = Object.assign({}, defaultOptions, state.options, options);\n state.scrollParents = {\n reference: isElement(reference) ? listScrollParents(reference) : reference.contextElement ? listScrollParents(reference.contextElement) : [],\n popper: listScrollParents(popper)\n }; // Orders the modifiers based on their dependencies and `phase`\n // properties\n\n var orderedModifiers = orderModifiers(mergeByName([].concat(defaultModifiers, state.options.modifiers))); // Strip out disabled modifiers\n\n state.orderedModifiers = orderedModifiers.filter(function (m) {\n return m.enabled;\n });\n runModifierEffects();\n return instance.update();\n },\n // Sync update – it will always be executed, even if not necessary. This\n // is useful for low frequency updates where sync behavior simplifies the\n // logic.\n // For high frequency updates (e.g. `resize` and `scroll` events), always\n // prefer the async Popper#update method\n forceUpdate: function forceUpdate() {\n if (isDestroyed) {\n return;\n }\n\n var _state$elements = state.elements,\n reference = _state$elements.reference,\n popper = _state$elements.popper; // Don't proceed if `reference` or `popper` are not valid elements\n // anymore\n\n if (!areValidElements(reference, popper)) {\n return;\n } // Store the reference and popper rects to be read by modifiers\n\n\n state.rects = {\n reference: getCompositeRect(reference, getOffsetParent(popper), state.options.strategy === 'fixed'),\n popper: getLayoutRect(popper)\n }; // Modifiers have the ability to reset the current update cycle. The\n // most common use case for this is the `flip` modifier changing the\n // placement, which then needs to re-run all the modifiers, because the\n // logic was previously ran for the previous placement and is therefore\n // stale/incorrect\n\n state.reset = false;\n state.placement = state.options.placement; // On each update cycle, the `modifiersData` property for each modifier\n // is filled with the initial data specified by the modifier. This means\n // it doesn't persist and is fresh on each update.\n // To ensure persistent data, use `${name}#persistent`\n\n state.orderedModifiers.forEach(function (modifier) {\n return state.modifiersData[modifier.name] = Object.assign({}, modifier.data);\n });\n\n for (var index = 0; index < state.orderedModifiers.length; index++) {\n if (state.reset === true) {\n state.reset = false;\n index = -1;\n continue;\n }\n\n var _state$orderedModifie = state.orderedModifiers[index],\n fn = _state$orderedModifie.fn,\n _state$orderedModifie2 = _state$orderedModifie.options,\n _options = _state$orderedModifie2 === void 0 ? {} : _state$orderedModifie2,\n name = _state$orderedModifie.name;\n\n if (typeof fn === 'function') {\n state = fn({\n state: state,\n options: _options,\n name: name,\n instance: instance\n }) || state;\n }\n }\n },\n // Async and optimistically optimized update – it will not be executed if\n // not necessary (debounced to run at most once-per-tick)\n update: debounce(function () {\n return new Promise(function (resolve) {\n instance.forceUpdate();\n resolve(state);\n });\n }),\n destroy: function destroy() {\n cleanupModifierEffects();\n isDestroyed = true;\n }\n };\n\n if (!areValidElements(reference, popper)) {\n return instance;\n }\n\n instance.setOptions(options).then(function (state) {\n if (!isDestroyed && options.onFirstUpdate) {\n options.onFirstUpdate(state);\n }\n }); // Modifiers have the ability to execute arbitrary code before the first\n // update cycle runs. They will be executed in the same order as the update\n // cycle. This is useful when a modifier adds some persistent data that\n // other modifiers need to use, but the modifier is run after the dependent\n // one.\n\n function runModifierEffects() {\n state.orderedModifiers.forEach(function (_ref) {\n var name = _ref.name,\n _ref$options = _ref.options,\n options = _ref$options === void 0 ? {} : _ref$options,\n effect = _ref.effect;\n\n if (typeof effect === 'function') {\n var cleanupFn = effect({\n state: state,\n name: name,\n instance: instance,\n options: options\n });\n\n var noopFn = function noopFn() {};\n\n effectCleanupFns.push(cleanupFn || noopFn);\n }\n });\n }\n\n function cleanupModifierEffects() {\n effectCleanupFns.forEach(function (fn) {\n return fn();\n });\n effectCleanupFns = [];\n }\n\n return instance;\n };\n}\nexport var createPopper = /*#__PURE__*/popperGenerator(); // eslint-disable-next-line import/no-unused-modules\n\nexport { detectOverflow };","import { popperGenerator, detectOverflow } from \"./createPopper.js\";\nimport eventListeners from \"./modifiers/eventListeners.js\";\nimport popperOffsets from \"./modifiers/popperOffsets.js\";\nimport computeStyles from \"./modifiers/computeStyles.js\";\nimport applyStyles from \"./modifiers/applyStyles.js\";\nimport offset from \"./modifiers/offset.js\";\nimport flip from \"./modifiers/flip.js\";\nimport preventOverflow from \"./modifiers/preventOverflow.js\";\nimport arrow from \"./modifiers/arrow.js\";\nimport hide from \"./modifiers/hide.js\";\nvar defaultModifiers = [eventListeners, popperOffsets, computeStyles, applyStyles, offset, flip, preventOverflow, arrow, hide];\nvar createPopper = /*#__PURE__*/popperGenerator({\n defaultModifiers: defaultModifiers\n}); // eslint-disable-next-line import/no-unused-modules\n\nexport { createPopper, popperGenerator, defaultModifiers, detectOverflow }; // eslint-disable-next-line import/no-unused-modules\n\nexport { createPopper as createPopperLite } from \"./popper-lite.js\"; // eslint-disable-next-line import/no-unused-modules\n\nexport * from \"./modifiers/index.js\";","import { generateUtilityClass } from '../generateUtilityClass';\nimport { generateUtilityClasses } from '../generateUtilityClasses';\nconst COMPONENT_NAME = 'Popper';\nexport function getPopperUtilityClass(slot) {\n return generateUtilityClass(COMPONENT_NAME, slot);\n}\nexport const popperClasses = generateUtilityClasses(COMPONENT_NAME, ['root']);","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"anchorEl\", \"children\", \"direction\", \"disablePortal\", \"modifiers\", \"open\", \"placement\", \"popperOptions\", \"popperRef\", \"slotProps\", \"slots\", \"TransitionProps\", \"ownerState\"],\n _excluded2 = [\"anchorEl\", \"children\", \"container\", \"direction\", \"disablePortal\", \"keepMounted\", \"modifiers\", \"open\", \"placement\", \"popperOptions\", \"popperRef\", \"style\", \"transition\", \"slotProps\", \"slots\"];\nimport * as React from 'react';\nimport { chainPropTypes, HTMLElementType, refType, unstable_ownerDocument as ownerDocument, unstable_useEnhancedEffect as useEnhancedEffect, unstable_useForkRef as useForkRef } from '@mui/utils';\nimport { createPopper } from '@popperjs/core';\nimport PropTypes from 'prop-types';\nimport { unstable_composeClasses as composeClasses } from '../composeClasses';\nimport { Portal } from '../Portal';\nimport { getPopperUtilityClass } from './popperClasses';\nimport { useSlotProps } from '../utils';\nimport { useClassNamesOverride } from '../utils/ClassNameConfigurator';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nfunction flipPlacement(placement, direction) {\n if (direction === 'ltr') {\n return placement;\n }\n switch (placement) {\n case 'bottom-end':\n return 'bottom-start';\n case 'bottom-start':\n return 'bottom-end';\n case 'top-end':\n return 'top-start';\n case 'top-start':\n return 'top-end';\n default:\n return placement;\n }\n}\nfunction resolveAnchorEl(anchorEl) {\n return typeof anchorEl === 'function' ? anchorEl() : anchorEl;\n}\nfunction isHTMLElement(element) {\n return element.nodeType !== undefined;\n}\nfunction isVirtualElement(element) {\n return !isHTMLElement(element);\n}\nconst useUtilityClasses = () => {\n const slots = {\n root: ['root']\n };\n return composeClasses(slots, useClassNamesOverride(getPopperUtilityClass));\n};\nconst defaultPopperOptions = {};\nconst PopperTooltip = /*#__PURE__*/React.forwardRef(function PopperTooltip(props, forwardedRef) {\n var _slots$root;\n const {\n anchorEl,\n children,\n direction,\n disablePortal,\n modifiers,\n open,\n placement: initialPlacement,\n popperOptions,\n popperRef: popperRefProp,\n slotProps = {},\n slots = {},\n TransitionProps\n // @ts-ignore internal logic\n // prevent from spreading to DOM, it can come from the parent component e.g. Select.\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const tooltipRef = React.useRef(null);\n const ownRef = useForkRef(tooltipRef, forwardedRef);\n const popperRef = React.useRef(null);\n const handlePopperRef = useForkRef(popperRef, popperRefProp);\n const handlePopperRefRef = React.useRef(handlePopperRef);\n useEnhancedEffect(() => {\n handlePopperRefRef.current = handlePopperRef;\n }, [handlePopperRef]);\n React.useImperativeHandle(popperRefProp, () => popperRef.current, []);\n const rtlPlacement = flipPlacement(initialPlacement, direction);\n /**\n * placement initialized from prop but can change during lifetime if modifiers.flip.\n * modifiers.flip is essentially a flip for controlled/uncontrolled behavior\n */\n const [placement, setPlacement] = React.useState(rtlPlacement);\n const [resolvedAnchorElement, setResolvedAnchorElement] = React.useState(resolveAnchorEl(anchorEl));\n React.useEffect(() => {\n if (popperRef.current) {\n popperRef.current.forceUpdate();\n }\n });\n React.useEffect(() => {\n if (anchorEl) {\n setResolvedAnchorElement(resolveAnchorEl(anchorEl));\n }\n }, [anchorEl]);\n useEnhancedEffect(() => {\n if (!resolvedAnchorElement || !open) {\n return undefined;\n }\n const handlePopperUpdate = data => {\n setPlacement(data.placement);\n };\n if (process.env.NODE_ENV !== 'production') {\n if (resolvedAnchorElement && isHTMLElement(resolvedAnchorElement) && resolvedAnchorElement.nodeType === 1) {\n const box = resolvedAnchorElement.getBoundingClientRect();\n if (process.env.NODE_ENV !== 'test' && box.top === 0 && box.left === 0 && box.right === 0 && box.bottom === 0) {\n console.warn(['MUI: The `anchorEl` prop provided to the component is invalid.', 'The anchor element should be part of the document layout.', \"Make sure the element is present in the document or that it's not display none.\"].join('\\n'));\n }\n }\n }\n let popperModifiers = [{\n name: 'preventOverflow',\n options: {\n altBoundary: disablePortal\n }\n }, {\n name: 'flip',\n options: {\n altBoundary: disablePortal\n }\n }, {\n name: 'onUpdate',\n enabled: true,\n phase: 'afterWrite',\n fn: ({\n state\n }) => {\n handlePopperUpdate(state);\n }\n }];\n if (modifiers != null) {\n popperModifiers = popperModifiers.concat(modifiers);\n }\n if (popperOptions && popperOptions.modifiers != null) {\n popperModifiers = popperModifiers.concat(popperOptions.modifiers);\n }\n const popper = createPopper(resolvedAnchorElement, tooltipRef.current, _extends({\n placement: rtlPlacement\n }, popperOptions, {\n modifiers: popperModifiers\n }));\n handlePopperRefRef.current(popper);\n return () => {\n popper.destroy();\n handlePopperRefRef.current(null);\n };\n }, [resolvedAnchorElement, disablePortal, modifiers, open, popperOptions, rtlPlacement]);\n const childProps = {\n placement: placement\n };\n if (TransitionProps !== null) {\n childProps.TransitionProps = TransitionProps;\n }\n const classes = useUtilityClasses();\n const Root = (_slots$root = slots.root) != null ? _slots$root : 'div';\n const rootProps = useSlotProps({\n elementType: Root,\n externalSlotProps: slotProps.root,\n externalForwardedProps: other,\n additionalProps: {\n role: 'tooltip',\n ref: ownRef\n },\n ownerState: props,\n className: classes.root\n });\n return /*#__PURE__*/_jsx(Root, _extends({}, rootProps, {\n children: typeof children === 'function' ? children(childProps) : children\n }));\n});\n\n/**\n * Poppers rely on the 3rd party library [Popper.js](https://popper.js.org/docs/v2/) for positioning.\n *\n * Demos:\n *\n * - [Popper](https://mui.com/base-ui/react-popper/)\n *\n * API:\n *\n * - [Popper API](https://mui.com/base-ui/react-popper/components-api/#popper)\n */\nconst Popper = /*#__PURE__*/React.forwardRef(function Popper(props, forwardedRef) {\n const {\n anchorEl,\n children,\n container: containerProp,\n direction = 'ltr',\n disablePortal = false,\n keepMounted = false,\n modifiers,\n open,\n placement = 'bottom',\n popperOptions = defaultPopperOptions,\n popperRef,\n style,\n transition = false,\n slotProps = {},\n slots = {}\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded2);\n const [exited, setExited] = React.useState(true);\n const handleEnter = () => {\n setExited(false);\n };\n const handleExited = () => {\n setExited(true);\n };\n if (!keepMounted && !open && (!transition || exited)) {\n return null;\n }\n\n // If the container prop is provided, use that\n // If the anchorEl prop is provided, use its parent body element as the container\n // If neither are provided let the Modal take care of choosing the container\n let container;\n if (containerProp) {\n container = containerProp;\n } else if (anchorEl) {\n const resolvedAnchorEl = resolveAnchorEl(anchorEl);\n container = resolvedAnchorEl && isHTMLElement(resolvedAnchorEl) ? ownerDocument(resolvedAnchorEl).body : ownerDocument(null).body;\n }\n const display = !open && keepMounted && (!transition || exited) ? 'none' : undefined;\n const transitionProps = transition ? {\n in: open,\n onEnter: handleEnter,\n onExited: handleExited\n } : undefined;\n return /*#__PURE__*/_jsx(Portal, {\n disablePortal: disablePortal,\n container: container,\n children: /*#__PURE__*/_jsx(PopperTooltip, _extends({\n anchorEl: anchorEl,\n direction: direction,\n disablePortal: disablePortal,\n modifiers: modifiers,\n ref: forwardedRef,\n open: transition ? !exited : open,\n placement: placement,\n popperOptions: popperOptions,\n popperRef: popperRef,\n slotProps: slotProps,\n slots: slots\n }, other, {\n style: _extends({\n // Prevents scroll issue, waiting for Popper.js to add this style once initiated.\n position: 'fixed',\n // Fix Popper.js display issue\n top: 0,\n left: 0,\n display\n }, style),\n TransitionProps: transitionProps,\n children: children\n }))\n });\n});\nprocess.env.NODE_ENV !== \"production\" ? Popper.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * An HTML element, [virtualElement](https://popper.js.org/docs/v2/virtual-elements/),\n * or a function that returns either.\n * It's used to set the position of the popper.\n * The return value will passed as the reference object of the Popper instance.\n */\n anchorEl: chainPropTypes(PropTypes.oneOfType([HTMLElementType, PropTypes.object, PropTypes.func]), props => {\n if (props.open) {\n const resolvedAnchorEl = resolveAnchorEl(props.anchorEl);\n if (resolvedAnchorEl && isHTMLElement(resolvedAnchorEl) && resolvedAnchorEl.nodeType === 1) {\n const box = resolvedAnchorEl.getBoundingClientRect();\n if (process.env.NODE_ENV !== 'test' && box.top === 0 && box.left === 0 && box.right === 0 && box.bottom === 0) {\n return new Error(['MUI: The `anchorEl` prop provided to the component is invalid.', 'The anchor element should be part of the document layout.', \"Make sure the element is present in the document or that it's not display none.\"].join('\\n'));\n }\n } else if (!resolvedAnchorEl || typeof resolvedAnchorEl.getBoundingClientRect !== 'function' || isVirtualElement(resolvedAnchorEl) && resolvedAnchorEl.contextElement != null && resolvedAnchorEl.contextElement.nodeType !== 1) {\n return new Error(['MUI: The `anchorEl` prop provided to the component is invalid.', 'It should be an HTML element instance or a virtualElement ', '(https://popper.js.org/docs/v2/virtual-elements/).'].join('\\n'));\n }\n }\n return null;\n }),\n /**\n * Popper render function or node.\n */\n children: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.node, PropTypes.func]),\n /**\n * An HTML element or function that returns one.\n * The `container` will have the portal children appended to it.\n *\n * You can also provide a callback, which is called in a React layout effect.\n * This lets you set the container from a ref, and also makes server-side rendering possible.\n *\n * By default, it uses the body of the top-level document object,\n * so it's simply `document.body` most of the time.\n */\n container: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.func]),\n /**\n * Direction of the text.\n * @default 'ltr'\n */\n direction: PropTypes.oneOf(['ltr', 'rtl']),\n /**\n * The `children` will be under the DOM hierarchy of the parent component.\n * @default false\n */\n disablePortal: PropTypes.bool,\n /**\n * Always keep the children in the DOM.\n * This prop can be useful in SEO situation or\n * when you want to maximize the responsiveness of the Popper.\n * @default false\n */\n keepMounted: PropTypes.bool,\n /**\n * Popper.js is based on a \"plugin-like\" architecture,\n * most of its features are fully encapsulated \"modifiers\".\n *\n * A modifier is a function that is called each time Popper.js needs to\n * compute the position of the popper.\n * For this reason, modifiers should be very performant to avoid bottlenecks.\n * To learn how to create a modifier, [read the modifiers documentation](https://popper.js.org/docs/v2/modifiers/).\n */\n modifiers: PropTypes.arrayOf(PropTypes.shape({\n data: PropTypes.object,\n effect: PropTypes.func,\n enabled: PropTypes.bool,\n fn: PropTypes.func,\n name: PropTypes.any,\n options: PropTypes.object,\n phase: PropTypes.oneOf(['afterMain', 'afterRead', 'afterWrite', 'beforeMain', 'beforeRead', 'beforeWrite', 'main', 'read', 'write']),\n requires: PropTypes.arrayOf(PropTypes.string),\n requiresIfExists: PropTypes.arrayOf(PropTypes.string)\n })),\n /**\n * If `true`, the component is shown.\n */\n open: PropTypes.bool.isRequired,\n /**\n * Popper placement.\n * @default 'bottom'\n */\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n /**\n * Options provided to the [`Popper.js`](https://popper.js.org/docs/v2/constructors/#options) instance.\n * @default {}\n */\n popperOptions: PropTypes.shape({\n modifiers: PropTypes.array,\n onFirstUpdate: PropTypes.func,\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n strategy: PropTypes.oneOf(['absolute', 'fixed'])\n }),\n /**\n * A ref that points to the used popper instance.\n */\n popperRef: refType,\n /**\n * The props used for each slot inside the Popper.\n * @default {}\n */\n slotProps: PropTypes.shape({\n root: PropTypes.oneOfType([PropTypes.func, PropTypes.object])\n }),\n /**\n * The components used for each slot inside the Popper.\n * Either a string to use a HTML element or a component.\n * @default {}\n */\n slots: PropTypes.shape({\n root: PropTypes.elementType\n }),\n /**\n * Help supporting a react-transition-group/Transition component.\n * @default false\n */\n transition: PropTypes.bool\n} : void 0;\nexport { Popper };","'use client';\n\nimport * as React from 'react';\nimport { useTheme as useThemeSystem } from '@mui/system';\nimport defaultTheme from './defaultTheme';\nimport THEME_ID from './identifier';\nexport default function useTheme() {\n const theme = useThemeSystem(defaultTheme);\n if (process.env.NODE_ENV !== 'production') {\n // eslint-disable-next-line react-hooks/rules-of-hooks\n React.useDebugValue(theme);\n }\n return theme[THEME_ID] || theme;\n}","export default function _setPrototypeOf(o, p) {\n _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function _setPrototypeOf(o, p) {\n o.__proto__ = p;\n return o;\n };\n return _setPrototypeOf(o, p);\n}","import setPrototypeOf from \"./setPrototypeOf.js\";\nexport default function _inheritsLoose(subClass, superClass) {\n subClass.prototype = Object.create(superClass.prototype);\n subClass.prototype.constructor = subClass;\n setPrototypeOf(subClass, superClass);\n}","export default {\n disabled: false\n};","import PropTypes from 'prop-types';\nexport var timeoutsShape = process.env.NODE_ENV !== 'production' ? PropTypes.oneOfType([PropTypes.number, PropTypes.shape({\n enter: PropTypes.number,\n exit: PropTypes.number,\n appear: PropTypes.number\n}).isRequired]) : null;\nexport var classNamesShape = process.env.NODE_ENV !== 'production' ? PropTypes.oneOfType([PropTypes.string, PropTypes.shape({\n enter: PropTypes.string,\n exit: PropTypes.string,\n active: PropTypes.string\n}), PropTypes.shape({\n enter: PropTypes.string,\n enterDone: PropTypes.string,\n enterActive: PropTypes.string,\n exit: PropTypes.string,\n exitDone: PropTypes.string,\n exitActive: PropTypes.string\n})]) : null;","import React from 'react';\nexport default React.createContext(null);","export var forceReflow = function forceReflow(node) {\n return node.scrollTop;\n};","import _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _inheritsLoose from \"@babel/runtime/helpers/esm/inheritsLoose\";\nimport PropTypes from 'prop-types';\nimport React from 'react';\nimport ReactDOM from 'react-dom';\nimport config from './config';\nimport { timeoutsShape } from './utils/PropTypes';\nimport TransitionGroupContext from './TransitionGroupContext';\nimport { forceReflow } from './utils/reflow';\nexport var UNMOUNTED = 'unmounted';\nexport var EXITED = 'exited';\nexport var ENTERING = 'entering';\nexport var ENTERED = 'entered';\nexport var EXITING = 'exiting';\n/**\n * The Transition component lets you describe a transition from one component\n * state to another _over time_ with a simple declarative API. Most commonly\n * it's used to animate the mounting and unmounting of a component, but can also\n * be used to describe in-place transition states as well.\n *\n * ---\n *\n * **Note**: `Transition` is a platform-agnostic base component. If you're using\n * transitions in CSS, you'll probably want to use\n * [`CSSTransition`](https://reactcommunity.org/react-transition-group/css-transition)\n * instead. It inherits all the features of `Transition`, but contains\n * additional features necessary to play nice with CSS transitions (hence the\n * name of the component).\n *\n * ---\n *\n * By default the `Transition` component does not alter the behavior of the\n * component it renders, it only tracks \"enter\" and \"exit\" states for the\n * components. It's up to you to give meaning and effect to those states. For\n * example we can add styles to a component when it enters or exits:\n *\n * ```jsx\n * import { Transition } from 'react-transition-group';\n *\n * const duration = 300;\n *\n * const defaultStyle = {\n * transition: `opacity ${duration}ms ease-in-out`,\n * opacity: 0,\n * }\n *\n * const transitionStyles = {\n * entering: { opacity: 1 },\n * entered: { opacity: 1 },\n * exiting: { opacity: 0 },\n * exited: { opacity: 0 },\n * };\n *\n * const Fade = ({ in: inProp }) => (\n * \n * {state => (\n *
    \n * I'm a fade Transition!\n *
    \n * )}\n *
    \n * );\n * ```\n *\n * There are 4 main states a Transition can be in:\n * - `'entering'`\n * - `'entered'`\n * - `'exiting'`\n * - `'exited'`\n *\n * Transition state is toggled via the `in` prop. When `true` the component\n * begins the \"Enter\" stage. During this stage, the component will shift from\n * its current transition state, to `'entering'` for the duration of the\n * transition and then to the `'entered'` stage once it's complete. Let's take\n * the following example (we'll use the\n * [useState](https://reactjs.org/docs/hooks-reference.html#usestate) hook):\n *\n * ```jsx\n * function App() {\n * const [inProp, setInProp] = useState(false);\n * return (\n *
    \n * \n * {state => (\n * // ...\n * )}\n * \n * \n *
    \n * );\n * }\n * ```\n *\n * When the button is clicked the component will shift to the `'entering'` state\n * and stay there for 500ms (the value of `timeout`) before it finally switches\n * to `'entered'`.\n *\n * When `in` is `false` the same thing happens except the state moves from\n * `'exiting'` to `'exited'`.\n */\n\nvar Transition = /*#__PURE__*/function (_React$Component) {\n _inheritsLoose(Transition, _React$Component);\n\n function Transition(props, context) {\n var _this;\n\n _this = _React$Component.call(this, props, context) || this;\n var parentGroup = context; // In the context of a TransitionGroup all enters are really appears\n\n var appear = parentGroup && !parentGroup.isMounting ? props.enter : props.appear;\n var initialStatus;\n _this.appearStatus = null;\n\n if (props.in) {\n if (appear) {\n initialStatus = EXITED;\n _this.appearStatus = ENTERING;\n } else {\n initialStatus = ENTERED;\n }\n } else {\n if (props.unmountOnExit || props.mountOnEnter) {\n initialStatus = UNMOUNTED;\n } else {\n initialStatus = EXITED;\n }\n }\n\n _this.state = {\n status: initialStatus\n };\n _this.nextCallback = null;\n return _this;\n }\n\n Transition.getDerivedStateFromProps = function getDerivedStateFromProps(_ref, prevState) {\n var nextIn = _ref.in;\n\n if (nextIn && prevState.status === UNMOUNTED) {\n return {\n status: EXITED\n };\n }\n\n return null;\n } // getSnapshotBeforeUpdate(prevProps) {\n // let nextStatus = null\n // if (prevProps !== this.props) {\n // const { status } = this.state\n // if (this.props.in) {\n // if (status !== ENTERING && status !== ENTERED) {\n // nextStatus = ENTERING\n // }\n // } else {\n // if (status === ENTERING || status === ENTERED) {\n // nextStatus = EXITING\n // }\n // }\n // }\n // return { nextStatus }\n // }\n ;\n\n var _proto = Transition.prototype;\n\n _proto.componentDidMount = function componentDidMount() {\n this.updateStatus(true, this.appearStatus);\n };\n\n _proto.componentDidUpdate = function componentDidUpdate(prevProps) {\n var nextStatus = null;\n\n if (prevProps !== this.props) {\n var status = this.state.status;\n\n if (this.props.in) {\n if (status !== ENTERING && status !== ENTERED) {\n nextStatus = ENTERING;\n }\n } else {\n if (status === ENTERING || status === ENTERED) {\n nextStatus = EXITING;\n }\n }\n }\n\n this.updateStatus(false, nextStatus);\n };\n\n _proto.componentWillUnmount = function componentWillUnmount() {\n this.cancelNextCallback();\n };\n\n _proto.getTimeouts = function getTimeouts() {\n var timeout = this.props.timeout;\n var exit, enter, appear;\n exit = enter = appear = timeout;\n\n if (timeout != null && typeof timeout !== 'number') {\n exit = timeout.exit;\n enter = timeout.enter; // TODO: remove fallback for next major\n\n appear = timeout.appear !== undefined ? timeout.appear : enter;\n }\n\n return {\n exit: exit,\n enter: enter,\n appear: appear\n };\n };\n\n _proto.updateStatus = function updateStatus(mounting, nextStatus) {\n if (mounting === void 0) {\n mounting = false;\n }\n\n if (nextStatus !== null) {\n // nextStatus will always be ENTERING or EXITING.\n this.cancelNextCallback();\n\n if (nextStatus === ENTERING) {\n if (this.props.unmountOnExit || this.props.mountOnEnter) {\n var node = this.props.nodeRef ? this.props.nodeRef.current : ReactDOM.findDOMNode(this); // https://github.com/reactjs/react-transition-group/pull/749\n // With unmountOnExit or mountOnEnter, the enter animation should happen at the transition between `exited` and `entering`.\n // To make the animation happen, we have to separate each rendering and avoid being processed as batched.\n\n if (node) forceReflow(node);\n }\n\n this.performEnter(mounting);\n } else {\n this.performExit();\n }\n } else if (this.props.unmountOnExit && this.state.status === EXITED) {\n this.setState({\n status: UNMOUNTED\n });\n }\n };\n\n _proto.performEnter = function performEnter(mounting) {\n var _this2 = this;\n\n var enter = this.props.enter;\n var appearing = this.context ? this.context.isMounting : mounting;\n\n var _ref2 = this.props.nodeRef ? [appearing] : [ReactDOM.findDOMNode(this), appearing],\n maybeNode = _ref2[0],\n maybeAppearing = _ref2[1];\n\n var timeouts = this.getTimeouts();\n var enterTimeout = appearing ? timeouts.appear : timeouts.enter; // no enter animation skip right to ENTERED\n // if we are mounting and running this it means appear _must_ be set\n\n if (!mounting && !enter || config.disabled) {\n this.safeSetState({\n status: ENTERED\n }, function () {\n _this2.props.onEntered(maybeNode);\n });\n return;\n }\n\n this.props.onEnter(maybeNode, maybeAppearing);\n this.safeSetState({\n status: ENTERING\n }, function () {\n _this2.props.onEntering(maybeNode, maybeAppearing);\n\n _this2.onTransitionEnd(enterTimeout, function () {\n _this2.safeSetState({\n status: ENTERED\n }, function () {\n _this2.props.onEntered(maybeNode, maybeAppearing);\n });\n });\n });\n };\n\n _proto.performExit = function performExit() {\n var _this3 = this;\n\n var exit = this.props.exit;\n var timeouts = this.getTimeouts();\n var maybeNode = this.props.nodeRef ? undefined : ReactDOM.findDOMNode(this); // no exit animation skip right to EXITED\n\n if (!exit || config.disabled) {\n this.safeSetState({\n status: EXITED\n }, function () {\n _this3.props.onExited(maybeNode);\n });\n return;\n }\n\n this.props.onExit(maybeNode);\n this.safeSetState({\n status: EXITING\n }, function () {\n _this3.props.onExiting(maybeNode);\n\n _this3.onTransitionEnd(timeouts.exit, function () {\n _this3.safeSetState({\n status: EXITED\n }, function () {\n _this3.props.onExited(maybeNode);\n });\n });\n });\n };\n\n _proto.cancelNextCallback = function cancelNextCallback() {\n if (this.nextCallback !== null) {\n this.nextCallback.cancel();\n this.nextCallback = null;\n }\n };\n\n _proto.safeSetState = function safeSetState(nextState, callback) {\n // This shouldn't be necessary, but there are weird race conditions with\n // setState callbacks and unmounting in testing, so always make sure that\n // we can cancel any pending setState callbacks after we unmount.\n callback = this.setNextCallback(callback);\n this.setState(nextState, callback);\n };\n\n _proto.setNextCallback = function setNextCallback(callback) {\n var _this4 = this;\n\n var active = true;\n\n this.nextCallback = function (event) {\n if (active) {\n active = false;\n _this4.nextCallback = null;\n callback(event);\n }\n };\n\n this.nextCallback.cancel = function () {\n active = false;\n };\n\n return this.nextCallback;\n };\n\n _proto.onTransitionEnd = function onTransitionEnd(timeout, handler) {\n this.setNextCallback(handler);\n var node = this.props.nodeRef ? this.props.nodeRef.current : ReactDOM.findDOMNode(this);\n var doesNotHaveTimeoutOrListener = timeout == null && !this.props.addEndListener;\n\n if (!node || doesNotHaveTimeoutOrListener) {\n setTimeout(this.nextCallback, 0);\n return;\n }\n\n if (this.props.addEndListener) {\n var _ref3 = this.props.nodeRef ? [this.nextCallback] : [node, this.nextCallback],\n maybeNode = _ref3[0],\n maybeNextCallback = _ref3[1];\n\n this.props.addEndListener(maybeNode, maybeNextCallback);\n }\n\n if (timeout != null) {\n setTimeout(this.nextCallback, timeout);\n }\n };\n\n _proto.render = function render() {\n var status = this.state.status;\n\n if (status === UNMOUNTED) {\n return null;\n }\n\n var _this$props = this.props,\n children = _this$props.children,\n _in = _this$props.in,\n _mountOnEnter = _this$props.mountOnEnter,\n _unmountOnExit = _this$props.unmountOnExit,\n _appear = _this$props.appear,\n _enter = _this$props.enter,\n _exit = _this$props.exit,\n _timeout = _this$props.timeout,\n _addEndListener = _this$props.addEndListener,\n _onEnter = _this$props.onEnter,\n _onEntering = _this$props.onEntering,\n _onEntered = _this$props.onEntered,\n _onExit = _this$props.onExit,\n _onExiting = _this$props.onExiting,\n _onExited = _this$props.onExited,\n _nodeRef = _this$props.nodeRef,\n childProps = _objectWithoutPropertiesLoose(_this$props, [\"children\", \"in\", \"mountOnEnter\", \"unmountOnExit\", \"appear\", \"enter\", \"exit\", \"timeout\", \"addEndListener\", \"onEnter\", \"onEntering\", \"onEntered\", \"onExit\", \"onExiting\", \"onExited\", \"nodeRef\"]);\n\n return (\n /*#__PURE__*/\n // allows for nested Transitions\n React.createElement(TransitionGroupContext.Provider, {\n value: null\n }, typeof children === 'function' ? children(status, childProps) : React.cloneElement(React.Children.only(children), childProps))\n );\n };\n\n return Transition;\n}(React.Component);\n\nTransition.contextType = TransitionGroupContext;\nTransition.propTypes = process.env.NODE_ENV !== \"production\" ? {\n /**\n * A React reference to DOM element that need to transition:\n * https://stackoverflow.com/a/51127130/4671932\n *\n * - When `nodeRef` prop is used, `node` is not passed to callback functions\n * (e.g. `onEnter`) because user already has direct access to the node.\n * - When changing `key` prop of `Transition` in a `TransitionGroup` a new\n * `nodeRef` need to be provided to `Transition` with changed `key` prop\n * (see\n * [test/CSSTransition-test.js](https://github.com/reactjs/react-transition-group/blob/13435f897b3ab71f6e19d724f145596f5910581c/test/CSSTransition-test.js#L362-L437)).\n */\n nodeRef: PropTypes.shape({\n current: typeof Element === 'undefined' ? PropTypes.any : function (propValue, key, componentName, location, propFullName, secret) {\n var value = propValue[key];\n return PropTypes.instanceOf(value && 'ownerDocument' in value ? value.ownerDocument.defaultView.Element : Element)(propValue, key, componentName, location, propFullName, secret);\n }\n }),\n\n /**\n * A `function` child can be used instead of a React element. This function is\n * called with the current transition status (`'entering'`, `'entered'`,\n * `'exiting'`, `'exited'`), which can be used to apply context\n * specific props to a component.\n *\n * ```jsx\n * \n * {state => (\n * \n * )}\n * \n * ```\n */\n children: PropTypes.oneOfType([PropTypes.func.isRequired, PropTypes.element.isRequired]).isRequired,\n\n /**\n * Show the component; triggers the enter or exit states\n */\n in: PropTypes.bool,\n\n /**\n * By default the child component is mounted immediately along with\n * the parent `Transition` component. If you want to \"lazy mount\" the component on the\n * first `in={true}` you can set `mountOnEnter`. After the first enter transition the component will stay\n * mounted, even on \"exited\", unless you also specify `unmountOnExit`.\n */\n mountOnEnter: PropTypes.bool,\n\n /**\n * By default the child component stays mounted after it reaches the `'exited'` state.\n * Set `unmountOnExit` if you'd prefer to unmount the component after it finishes exiting.\n */\n unmountOnExit: PropTypes.bool,\n\n /**\n * By default the child component does not perform the enter transition when\n * it first mounts, regardless of the value of `in`. If you want this\n * behavior, set both `appear` and `in` to `true`.\n *\n * > **Note**: there are no special appear states like `appearing`/`appeared`, this prop\n * > only adds an additional enter transition. However, in the\n * > `` component that first enter transition does result in\n * > additional `.appear-*` classes, that way you can choose to style it\n * > differently.\n */\n appear: PropTypes.bool,\n\n /**\n * Enable or disable enter transitions.\n */\n enter: PropTypes.bool,\n\n /**\n * Enable or disable exit transitions.\n */\n exit: PropTypes.bool,\n\n /**\n * The duration of the transition, in milliseconds.\n * Required unless `addEndListener` is provided.\n *\n * You may specify a single timeout for all transitions:\n *\n * ```jsx\n * timeout={500}\n * ```\n *\n * or individually:\n *\n * ```jsx\n * timeout={{\n * appear: 500,\n * enter: 300,\n * exit: 500,\n * }}\n * ```\n *\n * - `appear` defaults to the value of `enter`\n * - `enter` defaults to `0`\n * - `exit` defaults to `0`\n *\n * @type {number | { enter?: number, exit?: number, appear?: number }}\n */\n timeout: function timeout(props) {\n var pt = timeoutsShape;\n if (!props.addEndListener) pt = pt.isRequired;\n\n for (var _len = arguments.length, args = new Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) {\n args[_key - 1] = arguments[_key];\n }\n\n return pt.apply(void 0, [props].concat(args));\n },\n\n /**\n * Add a custom transition end trigger. Called with the transitioning\n * DOM node and a `done` callback. Allows for more fine grained transition end\n * logic. Timeouts are still used as a fallback if provided.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * ```jsx\n * addEndListener={(node, done) => {\n * // use the css transitionend event to mark the finish of a transition\n * node.addEventListener('transitionend', done, false);\n * }}\n * ```\n */\n addEndListener: PropTypes.func,\n\n /**\n * Callback fired before the \"entering\" status is applied. An extra parameter\n * `isAppearing` is supplied to indicate if the enter stage is occurring on the initial mount\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement, isAppearing: bool) -> void\n */\n onEnter: PropTypes.func,\n\n /**\n * Callback fired after the \"entering\" status is applied. An extra parameter\n * `isAppearing` is supplied to indicate if the enter stage is occurring on the initial mount\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement, isAppearing: bool)\n */\n onEntering: PropTypes.func,\n\n /**\n * Callback fired after the \"entered\" status is applied. An extra parameter\n * `isAppearing` is supplied to indicate if the enter stage is occurring on the initial mount\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement, isAppearing: bool) -> void\n */\n onEntered: PropTypes.func,\n\n /**\n * Callback fired before the \"exiting\" status is applied.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement) -> void\n */\n onExit: PropTypes.func,\n\n /**\n * Callback fired after the \"exiting\" status is applied.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement) -> void\n */\n onExiting: PropTypes.func,\n\n /**\n * Callback fired after the \"exited\" status is applied.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed\n *\n * @type Function(node: HtmlElement) -> void\n */\n onExited: PropTypes.func\n} : {}; // Name the function so it is clearer in the documentation\n\nfunction noop() {}\n\nTransition.defaultProps = {\n in: false,\n mountOnEnter: false,\n unmountOnExit: false,\n appear: false,\n enter: true,\n exit: true,\n onEnter: noop,\n onEntering: noop,\n onEntered: noop,\n onExit: noop,\n onExiting: noop,\n onExited: noop\n};\nTransition.UNMOUNTED = UNMOUNTED;\nTransition.EXITED = EXITED;\nTransition.ENTERING = ENTERING;\nTransition.ENTERED = ENTERED;\nTransition.EXITING = EXITING;\nexport default Transition;","export const reflow = node => node.scrollTop;\nexport function getTransitionProps(props, options) {\n var _style$transitionDura, _style$transitionTimi;\n const {\n timeout,\n easing,\n style = {}\n } = props;\n return {\n duration: (_style$transitionDura = style.transitionDuration) != null ? _style$transitionDura : typeof timeout === 'number' ? timeout : timeout[options.mode] || 0,\n easing: (_style$transitionTimi = style.transitionTimingFunction) != null ? _style$transitionTimi : typeof easing === 'object' ? easing[options.mode] : easing,\n delay: style.transitionDelay\n };\n}","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"addEndListener\", \"appear\", \"children\", \"easing\", \"in\", \"onEnter\", \"onEntered\", \"onEntering\", \"onExit\", \"onExited\", \"onExiting\", \"style\", \"timeout\", \"TransitionComponent\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport { elementAcceptingRef, unstable_useTimeout as useTimeout } from '@mui/utils';\nimport { Transition } from 'react-transition-group';\nimport useTheme from '../styles/useTheme';\nimport { getTransitionProps, reflow } from '../transitions/utils';\nimport useForkRef from '../utils/useForkRef';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nfunction getScale(value) {\n return `scale(${value}, ${value ** 2})`;\n}\nconst styles = {\n entering: {\n opacity: 1,\n transform: getScale(1)\n },\n entered: {\n opacity: 1,\n transform: 'none'\n }\n};\n\n/*\n TODO v6: remove\n Conditionally apply a workaround for the CSS transition bug in Safari 15.4 / WebKit browsers.\n */\nconst isWebKit154 = typeof navigator !== 'undefined' && /^((?!chrome|android).)*(safari|mobile)/i.test(navigator.userAgent) && /(os |version\\/)15(.|_)4/i.test(navigator.userAgent);\n\n/**\n * The Grow transition is used by the [Tooltip](/material-ui/react-tooltip/) and\n * [Popover](/material-ui/react-popover/) components.\n * It uses [react-transition-group](https://github.com/reactjs/react-transition-group) internally.\n */\nconst Grow = /*#__PURE__*/React.forwardRef(function Grow(props, ref) {\n const {\n addEndListener,\n appear = true,\n children,\n easing,\n in: inProp,\n onEnter,\n onEntered,\n onEntering,\n onExit,\n onExited,\n onExiting,\n style,\n timeout = 'auto',\n // eslint-disable-next-line react/prop-types\n TransitionComponent = Transition\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const timer = useTimeout();\n const autoTimeout = React.useRef();\n const theme = useTheme();\n const nodeRef = React.useRef(null);\n const handleRef = useForkRef(nodeRef, children.ref, ref);\n const normalizedTransitionCallback = callback => maybeIsAppearing => {\n if (callback) {\n const node = nodeRef.current;\n\n // onEnterXxx and onExitXxx callbacks have a different arguments.length value.\n if (maybeIsAppearing === undefined) {\n callback(node);\n } else {\n callback(node, maybeIsAppearing);\n }\n }\n };\n const handleEntering = normalizedTransitionCallback(onEntering);\n const handleEnter = normalizedTransitionCallback((node, isAppearing) => {\n reflow(node); // So the animation always start from the start.\n\n const {\n duration: transitionDuration,\n delay,\n easing: transitionTimingFunction\n } = getTransitionProps({\n style,\n timeout,\n easing\n }, {\n mode: 'enter'\n });\n let duration;\n if (timeout === 'auto') {\n duration = theme.transitions.getAutoHeightDuration(node.clientHeight);\n autoTimeout.current = duration;\n } else {\n duration = transitionDuration;\n }\n node.style.transition = [theme.transitions.create('opacity', {\n duration,\n delay\n }), theme.transitions.create('transform', {\n duration: isWebKit154 ? duration : duration * 0.666,\n delay,\n easing: transitionTimingFunction\n })].join(',');\n if (onEnter) {\n onEnter(node, isAppearing);\n }\n });\n const handleEntered = normalizedTransitionCallback(onEntered);\n const handleExiting = normalizedTransitionCallback(onExiting);\n const handleExit = normalizedTransitionCallback(node => {\n const {\n duration: transitionDuration,\n delay,\n easing: transitionTimingFunction\n } = getTransitionProps({\n style,\n timeout,\n easing\n }, {\n mode: 'exit'\n });\n let duration;\n if (timeout === 'auto') {\n duration = theme.transitions.getAutoHeightDuration(node.clientHeight);\n autoTimeout.current = duration;\n } else {\n duration = transitionDuration;\n }\n node.style.transition = [theme.transitions.create('opacity', {\n duration,\n delay\n }), theme.transitions.create('transform', {\n duration: isWebKit154 ? duration : duration * 0.666,\n delay: isWebKit154 ? delay : delay || duration * 0.333,\n easing: transitionTimingFunction\n })].join(',');\n node.style.opacity = 0;\n node.style.transform = getScale(0.75);\n if (onExit) {\n onExit(node);\n }\n });\n const handleExited = normalizedTransitionCallback(onExited);\n const handleAddEndListener = next => {\n if (timeout === 'auto') {\n timer.start(autoTimeout.current || 0, next);\n }\n if (addEndListener) {\n // Old call signature before `react-transition-group` implemented `nodeRef`\n addEndListener(nodeRef.current, next);\n }\n };\n return /*#__PURE__*/_jsx(TransitionComponent, _extends({\n appear: appear,\n in: inProp,\n nodeRef: nodeRef,\n onEnter: handleEnter,\n onEntered: handleEntered,\n onEntering: handleEntering,\n onExit: handleExit,\n onExited: handleExited,\n onExiting: handleExiting,\n addEndListener: handleAddEndListener,\n timeout: timeout === 'auto' ? null : timeout\n }, other, {\n children: (state, childProps) => {\n return /*#__PURE__*/React.cloneElement(children, _extends({\n style: _extends({\n opacity: 0,\n transform: getScale(0.75),\n visibility: state === 'exited' && !inProp ? 'hidden' : undefined\n }, styles[state], style, children.props.style),\n ref: handleRef\n }, childProps));\n }\n }));\n});\nprocess.env.NODE_ENV !== \"production\" ? Grow.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the d.ts file and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * Add a custom transition end trigger. Called with the transitioning DOM\n * node and a done callback. Allows for more fine grained transition end\n * logic. Note: Timeouts are still used as a fallback if provided.\n */\n addEndListener: PropTypes.func,\n /**\n * Perform the enter transition when it first mounts if `in` is also `true`.\n * Set this to `false` to disable this behavior.\n * @default true\n */\n appear: PropTypes.bool,\n /**\n * A single child content element.\n */\n children: elementAcceptingRef.isRequired,\n /**\n * The transition timing function.\n * You may specify a single easing or a object containing enter and exit values.\n */\n easing: PropTypes.oneOfType([PropTypes.shape({\n enter: PropTypes.string,\n exit: PropTypes.string\n }), PropTypes.string]),\n /**\n * If `true`, the component will transition in.\n */\n in: PropTypes.bool,\n /**\n * @ignore\n */\n onEnter: PropTypes.func,\n /**\n * @ignore\n */\n onEntered: PropTypes.func,\n /**\n * @ignore\n */\n onEntering: PropTypes.func,\n /**\n * @ignore\n */\n onExit: PropTypes.func,\n /**\n * @ignore\n */\n onExited: PropTypes.func,\n /**\n * @ignore\n */\n onExiting: PropTypes.func,\n /**\n * @ignore\n */\n style: PropTypes.object,\n /**\n * The duration for the transition, in milliseconds.\n * You may specify a single timeout for all transitions, or individually with an object.\n *\n * Set to 'auto' to automatically calculate transition time based on height.\n * @default 'auto'\n */\n timeout: PropTypes.oneOfType([PropTypes.oneOf(['auto']), PropTypes.number, PropTypes.shape({\n appear: PropTypes.number,\n enter: PropTypes.number,\n exit: PropTypes.number\n })])\n} : void 0;\nGrow.muiSupportAuto = true;\nexport default Grow;","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"anchorEl\", \"component\", \"components\", \"componentsProps\", \"container\", \"disablePortal\", \"keepMounted\", \"modifiers\", \"open\", \"placement\", \"popperOptions\", \"popperRef\", \"transition\", \"slots\", \"slotProps\"];\nimport { Popper as BasePopper } from '@mui/base/Popper';\nimport { useThemeWithoutDefault as useTheme } from '@mui/system';\nimport { HTMLElementType, refType } from '@mui/utils';\nimport PropTypes from 'prop-types';\nimport * as React from 'react';\nimport { styled, useThemeProps } from '../styles';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nconst PopperRoot = styled(BasePopper, {\n name: 'MuiPopper',\n slot: 'Root',\n overridesResolver: (props, styles) => styles.root\n})({});\n\n/**\n *\n * Demos:\n *\n * - [Autocomplete](https://mui.com/material-ui/react-autocomplete/)\n * - [Menu](https://mui.com/material-ui/react-menu/)\n * - [Popper](https://mui.com/material-ui/react-popper/)\n *\n * API:\n *\n * - [Popper API](https://mui.com/material-ui/api/popper/)\n */\nconst Popper = /*#__PURE__*/React.forwardRef(function Popper(inProps, ref) {\n var _slots$root;\n const theme = useTheme();\n const props = useThemeProps({\n props: inProps,\n name: 'MuiPopper'\n });\n const {\n anchorEl,\n component,\n components,\n componentsProps,\n container,\n disablePortal,\n keepMounted,\n modifiers,\n open,\n placement,\n popperOptions,\n popperRef,\n transition,\n slots,\n slotProps\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const RootComponent = (_slots$root = slots == null ? void 0 : slots.root) != null ? _slots$root : components == null ? void 0 : components.Root;\n const otherProps = _extends({\n anchorEl,\n container,\n disablePortal,\n keepMounted,\n modifiers,\n open,\n placement,\n popperOptions,\n popperRef,\n transition\n }, other);\n return /*#__PURE__*/_jsx(PopperRoot, _extends({\n as: component,\n direction: theme == null ? void 0 : theme.direction,\n slots: {\n root: RootComponent\n },\n slotProps: slotProps != null ? slotProps : componentsProps\n }, otherProps, {\n ref: ref\n }));\n});\nprocess.env.NODE_ENV !== \"production\" ? Popper.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * An HTML element, [virtualElement](https://popper.js.org/docs/v2/virtual-elements/),\n * or a function that returns either.\n * It's used to set the position of the popper.\n * The return value will passed as the reference object of the Popper instance.\n */\n anchorEl: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.object, PropTypes.func]),\n /**\n * Popper render function or node.\n */\n children: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.node, PropTypes.func]),\n /**\n * The component used for the root node.\n * Either a string to use a HTML element or a component.\n */\n component: PropTypes.elementType,\n /**\n * The components used for each slot inside the Popper.\n * Either a string to use a HTML element or a component.\n * @default {}\n */\n components: PropTypes.shape({\n Root: PropTypes.elementType\n }),\n /**\n * The props used for each slot inside the Popper.\n * @default {}\n */\n componentsProps: PropTypes.shape({\n root: PropTypes.oneOfType([PropTypes.func, PropTypes.object])\n }),\n /**\n * An HTML element or function that returns one.\n * The `container` will have the portal children appended to it.\n *\n * You can also provide a callback, which is called in a React layout effect.\n * This lets you set the container from a ref, and also makes server-side rendering possible.\n *\n * By default, it uses the body of the top-level document object,\n * so it's simply `document.body` most of the time.\n */\n container: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.func]),\n /**\n * The `children` will be under the DOM hierarchy of the parent component.\n * @default false\n */\n disablePortal: PropTypes.bool,\n /**\n * Always keep the children in the DOM.\n * This prop can be useful in SEO situation or\n * when you want to maximize the responsiveness of the Popper.\n * @default false\n */\n keepMounted: PropTypes.bool,\n /**\n * Popper.js is based on a \"plugin-like\" architecture,\n * most of its features are fully encapsulated \"modifiers\".\n *\n * A modifier is a function that is called each time Popper.js needs to\n * compute the position of the popper.\n * For this reason, modifiers should be very performant to avoid bottlenecks.\n * To learn how to create a modifier, [read the modifiers documentation](https://popper.js.org/docs/v2/modifiers/).\n */\n modifiers: PropTypes.arrayOf(PropTypes.shape({\n data: PropTypes.object,\n effect: PropTypes.func,\n enabled: PropTypes.bool,\n fn: PropTypes.func,\n name: PropTypes.any,\n options: PropTypes.object,\n phase: PropTypes.oneOf(['afterMain', 'afterRead', 'afterWrite', 'beforeMain', 'beforeRead', 'beforeWrite', 'main', 'read', 'write']),\n requires: PropTypes.arrayOf(PropTypes.string),\n requiresIfExists: PropTypes.arrayOf(PropTypes.string)\n })),\n /**\n * If `true`, the component is shown.\n */\n open: PropTypes.bool.isRequired,\n /**\n * Popper placement.\n * @default 'bottom'\n */\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n /**\n * Options provided to the [`Popper.js`](https://popper.js.org/docs/v2/constructors/#options) instance.\n * @default {}\n */\n popperOptions: PropTypes.shape({\n modifiers: PropTypes.array,\n onFirstUpdate: PropTypes.func,\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n strategy: PropTypes.oneOf(['absolute', 'fixed'])\n }),\n /**\n * A ref that points to the used popper instance.\n */\n popperRef: refType,\n /**\n * The props used for each slot inside the Popper.\n * @default {}\n */\n slotProps: PropTypes.shape({\n root: PropTypes.oneOfType([PropTypes.func, PropTypes.object])\n }),\n /**\n * The components used for each slot inside the Popper.\n * Either a string to use a HTML element or a component.\n * @default {}\n */\n slots: PropTypes.shape({\n root: PropTypes.elementType\n }),\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Help supporting a react-transition-group/Transition component.\n * @default false\n */\n transition: PropTypes.bool\n} : void 0;\nexport default Popper;","import generateUtilityClasses from '@mui/utils/generateUtilityClasses';\nimport generateUtilityClass from '@mui/utils/generateUtilityClass';\nexport function getTooltipUtilityClass(slot) {\n return generateUtilityClass('MuiTooltip', slot);\n}\nconst tooltipClasses = generateUtilityClasses('MuiTooltip', ['popper', 'popperInteractive', 'popperArrow', 'popperClose', 'tooltip', 'tooltipArrow', 'touch', 'tooltipPlacementLeft', 'tooltipPlacementRight', 'tooltipPlacementTop', 'tooltipPlacementBottom', 'arrow']);\nexport default tooltipClasses;","'use client';\n\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nconst _excluded = [\"arrow\", \"children\", \"classes\", \"components\", \"componentsProps\", \"describeChild\", \"disableFocusListener\", \"disableHoverListener\", \"disableInteractive\", \"disableTouchListener\", \"enterDelay\", \"enterNextDelay\", \"enterTouchDelay\", \"followCursor\", \"id\", \"leaveDelay\", \"leaveTouchDelay\", \"onClose\", \"onOpen\", \"open\", \"placement\", \"PopperComponent\", \"PopperProps\", \"slotProps\", \"slots\", \"title\", \"TransitionComponent\", \"TransitionProps\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport clsx from 'clsx';\nimport { elementAcceptingRef, unstable_useTimeout as useTimeout, unstable_Timeout as Timeout } from '@mui/utils';\nimport { unstable_composeClasses as composeClasses, appendOwnerState } from '@mui/base';\nimport { alpha } from '@mui/system';\nimport styled from '../styles/styled';\nimport useTheme from '../styles/useTheme';\nimport useThemeProps from '../styles/useThemeProps';\nimport capitalize from '../utils/capitalize';\nimport Grow from '../Grow';\nimport Popper from '../Popper';\nimport useEventCallback from '../utils/useEventCallback';\nimport useForkRef from '../utils/useForkRef';\nimport useId from '../utils/useId';\nimport useIsFocusVisible from '../utils/useIsFocusVisible';\nimport useControlled from '../utils/useControlled';\nimport tooltipClasses, { getTooltipUtilityClass } from './tooltipClasses';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nimport { jsxs as _jsxs } from \"react/jsx-runtime\";\nfunction round(value) {\n return Math.round(value * 1e5) / 1e5;\n}\nconst useUtilityClasses = ownerState => {\n const {\n classes,\n disableInteractive,\n arrow,\n touch,\n placement\n } = ownerState;\n const slots = {\n popper: ['popper', !disableInteractive && 'popperInteractive', arrow && 'popperArrow'],\n tooltip: ['tooltip', arrow && 'tooltipArrow', touch && 'touch', `tooltipPlacement${capitalize(placement.split('-')[0])}`],\n arrow: ['arrow']\n };\n return composeClasses(slots, getTooltipUtilityClass, classes);\n};\nconst TooltipPopper = styled(Popper, {\n name: 'MuiTooltip',\n slot: 'Popper',\n overridesResolver: (props, styles) => {\n const {\n ownerState\n } = props;\n return [styles.popper, !ownerState.disableInteractive && styles.popperInteractive, ownerState.arrow && styles.popperArrow, !ownerState.open && styles.popperClose];\n }\n})(({\n theme,\n ownerState,\n open\n}) => _extends({\n zIndex: (theme.vars || theme).zIndex.tooltip,\n pointerEvents: 'none'\n}, !ownerState.disableInteractive && {\n pointerEvents: 'auto'\n}, !open && {\n pointerEvents: 'none'\n}, ownerState.arrow && {\n [`&[data-popper-placement*=\"bottom\"] .${tooltipClasses.arrow}`]: {\n top: 0,\n marginTop: '-0.71em',\n '&::before': {\n transformOrigin: '0 100%'\n }\n },\n [`&[data-popper-placement*=\"top\"] .${tooltipClasses.arrow}`]: {\n bottom: 0,\n marginBottom: '-0.71em',\n '&::before': {\n transformOrigin: '100% 0'\n }\n },\n [`&[data-popper-placement*=\"right\"] .${tooltipClasses.arrow}`]: _extends({}, !ownerState.isRtl ? {\n left: 0,\n marginLeft: '-0.71em'\n } : {\n right: 0,\n marginRight: '-0.71em'\n }, {\n height: '1em',\n width: '0.71em',\n '&::before': {\n transformOrigin: '100% 100%'\n }\n }),\n [`&[data-popper-placement*=\"left\"] .${tooltipClasses.arrow}`]: _extends({}, !ownerState.isRtl ? {\n right: 0,\n marginRight: '-0.71em'\n } : {\n left: 0,\n marginLeft: '-0.71em'\n }, {\n height: '1em',\n width: '0.71em',\n '&::before': {\n transformOrigin: '0 0'\n }\n })\n}));\nconst TooltipTooltip = styled('div', {\n name: 'MuiTooltip',\n slot: 'Tooltip',\n overridesResolver: (props, styles) => {\n const {\n ownerState\n } = props;\n return [styles.tooltip, ownerState.touch && styles.touch, ownerState.arrow && styles.tooltipArrow, styles[`tooltipPlacement${capitalize(ownerState.placement.split('-')[0])}`]];\n }\n})(({\n theme,\n ownerState\n}) => _extends({\n backgroundColor: theme.vars ? theme.vars.palette.Tooltip.bg : alpha(theme.palette.grey[700], 0.92),\n borderRadius: (theme.vars || theme).shape.borderRadius,\n color: (theme.vars || theme).palette.common.white,\n fontFamily: theme.typography.fontFamily,\n padding: '4px 8px',\n fontSize: theme.typography.pxToRem(11),\n maxWidth: 300,\n margin: 2,\n wordWrap: 'break-word',\n fontWeight: theme.typography.fontWeightMedium\n}, ownerState.arrow && {\n position: 'relative',\n margin: 0\n}, ownerState.touch && {\n padding: '8px 16px',\n fontSize: theme.typography.pxToRem(14),\n lineHeight: `${round(16 / 14)}em`,\n fontWeight: theme.typography.fontWeightRegular\n}, {\n [`.${tooltipClasses.popper}[data-popper-placement*=\"left\"] &`]: _extends({\n transformOrigin: 'right center'\n }, !ownerState.isRtl ? _extends({\n marginRight: '14px'\n }, ownerState.touch && {\n marginRight: '24px'\n }) : _extends({\n marginLeft: '14px'\n }, ownerState.touch && {\n marginLeft: '24px'\n })),\n [`.${tooltipClasses.popper}[data-popper-placement*=\"right\"] &`]: _extends({\n transformOrigin: 'left center'\n }, !ownerState.isRtl ? _extends({\n marginLeft: '14px'\n }, ownerState.touch && {\n marginLeft: '24px'\n }) : _extends({\n marginRight: '14px'\n }, ownerState.touch && {\n marginRight: '24px'\n })),\n [`.${tooltipClasses.popper}[data-popper-placement*=\"top\"] &`]: _extends({\n transformOrigin: 'center bottom',\n marginBottom: '14px'\n }, ownerState.touch && {\n marginBottom: '24px'\n }),\n [`.${tooltipClasses.popper}[data-popper-placement*=\"bottom\"] &`]: _extends({\n transformOrigin: 'center top',\n marginTop: '14px'\n }, ownerState.touch && {\n marginTop: '24px'\n })\n}));\nconst TooltipArrow = styled('span', {\n name: 'MuiTooltip',\n slot: 'Arrow',\n overridesResolver: (props, styles) => styles.arrow\n})(({\n theme\n}) => ({\n overflow: 'hidden',\n position: 'absolute',\n width: '1em',\n height: '0.71em' /* = width / sqrt(2) = (length of the hypotenuse) */,\n boxSizing: 'border-box',\n color: theme.vars ? theme.vars.palette.Tooltip.bg : alpha(theme.palette.grey[700], 0.9),\n '&::before': {\n content: '\"\"',\n margin: 'auto',\n display: 'block',\n width: '100%',\n height: '100%',\n backgroundColor: 'currentColor',\n transform: 'rotate(45deg)'\n }\n}));\nlet hystersisOpen = false;\nconst hystersisTimer = new Timeout();\nlet cursorPosition = {\n x: 0,\n y: 0\n};\nexport function testReset() {\n hystersisOpen = false;\n hystersisTimer.clear();\n}\nfunction composeEventHandler(handler, eventHandler) {\n return event => {\n if (eventHandler) {\n eventHandler(event);\n }\n handler(event);\n };\n}\n\n// TODO v6: Remove PopperComponent, PopperProps, TransitionComponent and TransitionProps.\nconst Tooltip = /*#__PURE__*/React.forwardRef(function Tooltip(inProps, ref) {\n var _ref, _slots$popper, _ref2, _ref3, _slots$transition, _ref4, _slots$tooltip, _ref5, _slots$arrow, _slotProps$popper, _ref6, _slotProps$popper2, _slotProps$transition, _slotProps$tooltip, _ref7, _slotProps$tooltip2, _slotProps$arrow, _ref8, _slotProps$arrow2;\n const props = useThemeProps({\n props: inProps,\n name: 'MuiTooltip'\n });\n const {\n arrow = false,\n children: childrenProp,\n components = {},\n componentsProps = {},\n describeChild = false,\n disableFocusListener = false,\n disableHoverListener = false,\n disableInteractive: disableInteractiveProp = false,\n disableTouchListener = false,\n enterDelay = 100,\n enterNextDelay = 0,\n enterTouchDelay = 700,\n followCursor = false,\n id: idProp,\n leaveDelay = 0,\n leaveTouchDelay = 1500,\n onClose,\n onOpen,\n open: openProp,\n placement = 'bottom',\n PopperComponent: PopperComponentProp,\n PopperProps = {},\n slotProps = {},\n slots = {},\n title,\n TransitionComponent: TransitionComponentProp = Grow,\n TransitionProps\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n\n // to prevent runtime errors, developers will need to provide a child as a React element anyway.\n const children = /*#__PURE__*/React.isValidElement(childrenProp) ? childrenProp : /*#__PURE__*/_jsx(\"span\", {\n children: childrenProp\n });\n const theme = useTheme();\n const isRtl = theme.direction === 'rtl';\n const [childNode, setChildNode] = React.useState();\n const [arrowRef, setArrowRef] = React.useState(null);\n const ignoreNonTouchEvents = React.useRef(false);\n const disableInteractive = disableInteractiveProp || followCursor;\n const closeTimer = useTimeout();\n const enterTimer = useTimeout();\n const leaveTimer = useTimeout();\n const touchTimer = useTimeout();\n const [openState, setOpenState] = useControlled({\n controlled: openProp,\n default: false,\n name: 'Tooltip',\n state: 'open'\n });\n let open = openState;\n if (process.env.NODE_ENV !== 'production') {\n // eslint-disable-next-line react-hooks/rules-of-hooks\n const {\n current: isControlled\n } = React.useRef(openProp !== undefined);\n\n // eslint-disable-next-line react-hooks/rules-of-hooks\n React.useEffect(() => {\n if (childNode && childNode.disabled && !isControlled && title !== '' && childNode.tagName.toLowerCase() === 'button') {\n console.error(['MUI: You are providing a disabled `button` child to the Tooltip component.', 'A disabled element does not fire events.', \"Tooltip needs to listen to the child element's events to display the title.\", '', 'Add a simple wrapper element, such as a `span`.'].join('\\n'));\n }\n }, [title, childNode, isControlled]);\n }\n const id = useId(idProp);\n const prevUserSelect = React.useRef();\n const stopTouchInteraction = useEventCallback(() => {\n if (prevUserSelect.current !== undefined) {\n document.body.style.WebkitUserSelect = prevUserSelect.current;\n prevUserSelect.current = undefined;\n }\n touchTimer.clear();\n });\n React.useEffect(() => stopTouchInteraction, [stopTouchInteraction]);\n const handleOpen = event => {\n hystersisTimer.clear();\n hystersisOpen = true;\n\n // The mouseover event will trigger for every nested element in the tooltip.\n // We can skip rerendering when the tooltip is already open.\n // We are using the mouseover event instead of the mouseenter event to fix a hide/show issue.\n setOpenState(true);\n if (onOpen && !open) {\n onOpen(event);\n }\n };\n const handleClose = useEventCallback(\n /**\n * @param {React.SyntheticEvent | Event} event\n */\n event => {\n hystersisTimer.start(800 + leaveDelay, () => {\n hystersisOpen = false;\n });\n setOpenState(false);\n if (onClose && open) {\n onClose(event);\n }\n closeTimer.start(theme.transitions.duration.shortest, () => {\n ignoreNonTouchEvents.current = false;\n });\n });\n const handleEnter = event => {\n if (ignoreNonTouchEvents.current && event.type !== 'touchstart') {\n return;\n }\n\n // Remove the title ahead of time.\n // We don't want to wait for the next render commit.\n // We would risk displaying two tooltips at the same time (native + this one).\n if (childNode) {\n childNode.removeAttribute('title');\n }\n enterTimer.clear();\n leaveTimer.clear();\n if (enterDelay || hystersisOpen && enterNextDelay) {\n enterTimer.start(hystersisOpen ? enterNextDelay : enterDelay, () => {\n handleOpen(event);\n });\n } else {\n handleOpen(event);\n }\n };\n const handleLeave = event => {\n enterTimer.clear();\n leaveTimer.start(leaveDelay, () => {\n handleClose(event);\n });\n };\n const {\n isFocusVisibleRef,\n onBlur: handleBlurVisible,\n onFocus: handleFocusVisible,\n ref: focusVisibleRef\n } = useIsFocusVisible();\n // We don't necessarily care about the focusVisible state (which is safe to access via ref anyway).\n // We just need to re-render the Tooltip if the focus-visible state changes.\n const [, setChildIsFocusVisible] = React.useState(false);\n const handleBlur = event => {\n handleBlurVisible(event);\n if (isFocusVisibleRef.current === false) {\n setChildIsFocusVisible(false);\n handleLeave(event);\n }\n };\n const handleFocus = event => {\n // Workaround for https://github.com/facebook/react/issues/7769\n // The autoFocus of React might trigger the event before the componentDidMount.\n // We need to account for this eventuality.\n if (!childNode) {\n setChildNode(event.currentTarget);\n }\n handleFocusVisible(event);\n if (isFocusVisibleRef.current === true) {\n setChildIsFocusVisible(true);\n handleEnter(event);\n }\n };\n const detectTouchStart = event => {\n ignoreNonTouchEvents.current = true;\n const childrenProps = children.props;\n if (childrenProps.onTouchStart) {\n childrenProps.onTouchStart(event);\n }\n };\n const handleMouseOver = handleEnter;\n const handleMouseLeave = handleLeave;\n const handleTouchStart = event => {\n detectTouchStart(event);\n leaveTimer.clear();\n closeTimer.clear();\n stopTouchInteraction();\n prevUserSelect.current = document.body.style.WebkitUserSelect;\n // Prevent iOS text selection on long-tap.\n document.body.style.WebkitUserSelect = 'none';\n touchTimer.start(enterTouchDelay, () => {\n document.body.style.WebkitUserSelect = prevUserSelect.current;\n handleEnter(event);\n });\n };\n const handleTouchEnd = event => {\n if (children.props.onTouchEnd) {\n children.props.onTouchEnd(event);\n }\n stopTouchInteraction();\n leaveTimer.start(leaveTouchDelay, () => {\n handleClose(event);\n });\n };\n React.useEffect(() => {\n if (!open) {\n return undefined;\n }\n\n /**\n * @param {KeyboardEvent} nativeEvent\n */\n function handleKeyDown(nativeEvent) {\n // IE11, Edge (prior to using Bink?) use 'Esc'\n if (nativeEvent.key === 'Escape' || nativeEvent.key === 'Esc') {\n handleClose(nativeEvent);\n }\n }\n document.addEventListener('keydown', handleKeyDown);\n return () => {\n document.removeEventListener('keydown', handleKeyDown);\n };\n }, [handleClose, open]);\n const handleRef = useForkRef(children.ref, focusVisibleRef, setChildNode, ref);\n\n // There is no point in displaying an empty tooltip.\n // So we exclude all falsy values, except 0, which is valid.\n if (!title && title !== 0) {\n open = false;\n }\n const popperRef = React.useRef();\n const handleMouseMove = event => {\n const childrenProps = children.props;\n if (childrenProps.onMouseMove) {\n childrenProps.onMouseMove(event);\n }\n cursorPosition = {\n x: event.clientX,\n y: event.clientY\n };\n if (popperRef.current) {\n popperRef.current.update();\n }\n };\n const nameOrDescProps = {};\n const titleIsString = typeof title === 'string';\n if (describeChild) {\n nameOrDescProps.title = !open && titleIsString && !disableHoverListener ? title : null;\n nameOrDescProps['aria-describedby'] = open ? id : null;\n } else {\n nameOrDescProps['aria-label'] = titleIsString ? title : null;\n nameOrDescProps['aria-labelledby'] = open && !titleIsString ? id : null;\n }\n const childrenProps = _extends({}, nameOrDescProps, other, children.props, {\n className: clsx(other.className, children.props.className),\n onTouchStart: detectTouchStart,\n ref: handleRef\n }, followCursor ? {\n onMouseMove: handleMouseMove\n } : {});\n if (process.env.NODE_ENV !== 'production') {\n childrenProps['data-mui-internal-clone-element'] = true;\n\n // eslint-disable-next-line react-hooks/rules-of-hooks\n React.useEffect(() => {\n if (childNode && !childNode.getAttribute('data-mui-internal-clone-element')) {\n console.error(['MUI: The `children` component of the Tooltip is not forwarding its props correctly.', 'Please make sure that props are spread on the same element that the ref is applied to.'].join('\\n'));\n }\n }, [childNode]);\n }\n const interactiveWrapperListeners = {};\n if (!disableTouchListener) {\n childrenProps.onTouchStart = handleTouchStart;\n childrenProps.onTouchEnd = handleTouchEnd;\n }\n if (!disableHoverListener) {\n childrenProps.onMouseOver = composeEventHandler(handleMouseOver, childrenProps.onMouseOver);\n childrenProps.onMouseLeave = composeEventHandler(handleMouseLeave, childrenProps.onMouseLeave);\n if (!disableInteractive) {\n interactiveWrapperListeners.onMouseOver = handleMouseOver;\n interactiveWrapperListeners.onMouseLeave = handleMouseLeave;\n }\n }\n if (!disableFocusListener) {\n childrenProps.onFocus = composeEventHandler(handleFocus, childrenProps.onFocus);\n childrenProps.onBlur = composeEventHandler(handleBlur, childrenProps.onBlur);\n if (!disableInteractive) {\n interactiveWrapperListeners.onFocus = handleFocus;\n interactiveWrapperListeners.onBlur = handleBlur;\n }\n }\n if (process.env.NODE_ENV !== 'production') {\n if (children.props.title) {\n console.error(['MUI: You have provided a `title` prop to the child of .', `Remove this title prop \\`${children.props.title}\\` or the Tooltip component.`].join('\\n'));\n }\n }\n const popperOptions = React.useMemo(() => {\n var _PopperProps$popperOp;\n let tooltipModifiers = [{\n name: 'arrow',\n enabled: Boolean(arrowRef),\n options: {\n element: arrowRef,\n padding: 4\n }\n }];\n if ((_PopperProps$popperOp = PopperProps.popperOptions) != null && _PopperProps$popperOp.modifiers) {\n tooltipModifiers = tooltipModifiers.concat(PopperProps.popperOptions.modifiers);\n }\n return _extends({}, PopperProps.popperOptions, {\n modifiers: tooltipModifiers\n });\n }, [arrowRef, PopperProps]);\n const ownerState = _extends({}, props, {\n isRtl,\n arrow,\n disableInteractive,\n placement,\n PopperComponentProp,\n touch: ignoreNonTouchEvents.current\n });\n const classes = useUtilityClasses(ownerState);\n const PopperComponent = (_ref = (_slots$popper = slots.popper) != null ? _slots$popper : components.Popper) != null ? _ref : TooltipPopper;\n const TransitionComponent = (_ref2 = (_ref3 = (_slots$transition = slots.transition) != null ? _slots$transition : components.Transition) != null ? _ref3 : TransitionComponentProp) != null ? _ref2 : Grow;\n const TooltipComponent = (_ref4 = (_slots$tooltip = slots.tooltip) != null ? _slots$tooltip : components.Tooltip) != null ? _ref4 : TooltipTooltip;\n const ArrowComponent = (_ref5 = (_slots$arrow = slots.arrow) != null ? _slots$arrow : components.Arrow) != null ? _ref5 : TooltipArrow;\n const popperProps = appendOwnerState(PopperComponent, _extends({}, PopperProps, (_slotProps$popper = slotProps.popper) != null ? _slotProps$popper : componentsProps.popper, {\n className: clsx(classes.popper, PopperProps == null ? void 0 : PopperProps.className, (_ref6 = (_slotProps$popper2 = slotProps.popper) != null ? _slotProps$popper2 : componentsProps.popper) == null ? void 0 : _ref6.className)\n }), ownerState);\n const transitionProps = appendOwnerState(TransitionComponent, _extends({}, TransitionProps, (_slotProps$transition = slotProps.transition) != null ? _slotProps$transition : componentsProps.transition), ownerState);\n const tooltipProps = appendOwnerState(TooltipComponent, _extends({}, (_slotProps$tooltip = slotProps.tooltip) != null ? _slotProps$tooltip : componentsProps.tooltip, {\n className: clsx(classes.tooltip, (_ref7 = (_slotProps$tooltip2 = slotProps.tooltip) != null ? _slotProps$tooltip2 : componentsProps.tooltip) == null ? void 0 : _ref7.className)\n }), ownerState);\n const tooltipArrowProps = appendOwnerState(ArrowComponent, _extends({}, (_slotProps$arrow = slotProps.arrow) != null ? _slotProps$arrow : componentsProps.arrow, {\n className: clsx(classes.arrow, (_ref8 = (_slotProps$arrow2 = slotProps.arrow) != null ? _slotProps$arrow2 : componentsProps.arrow) == null ? void 0 : _ref8.className)\n }), ownerState);\n return /*#__PURE__*/_jsxs(React.Fragment, {\n children: [/*#__PURE__*/React.cloneElement(children, childrenProps), /*#__PURE__*/_jsx(PopperComponent, _extends({\n as: PopperComponentProp != null ? PopperComponentProp : Popper,\n placement: placement,\n anchorEl: followCursor ? {\n getBoundingClientRect: () => ({\n top: cursorPosition.y,\n left: cursorPosition.x,\n right: cursorPosition.x,\n bottom: cursorPosition.y,\n width: 0,\n height: 0\n })\n } : childNode,\n popperRef: popperRef,\n open: childNode ? open : false,\n id: id,\n transition: true\n }, interactiveWrapperListeners, popperProps, {\n popperOptions: popperOptions,\n children: ({\n TransitionProps: TransitionPropsInner\n }) => /*#__PURE__*/_jsx(TransitionComponent, _extends({\n timeout: theme.transitions.duration.shorter\n }, TransitionPropsInner, transitionProps, {\n children: /*#__PURE__*/_jsxs(TooltipComponent, _extends({}, tooltipProps, {\n children: [title, arrow ? /*#__PURE__*/_jsx(ArrowComponent, _extends({}, tooltipArrowProps, {\n ref: setArrowRef\n })) : null]\n }))\n }))\n }))]\n });\n});\nprocess.env.NODE_ENV !== \"production\" ? Tooltip.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the d.ts file and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * If `true`, adds an arrow to the tooltip.\n * @default false\n */\n arrow: PropTypes.bool,\n /**\n * Tooltip reference element.\n */\n children: elementAcceptingRef.isRequired,\n /**\n * Override or extend the styles applied to the component.\n */\n classes: PropTypes.object,\n /**\n * @ignore\n */\n className: PropTypes.string,\n /**\n * The components used for each slot inside.\n *\n * This prop is an alias for the `slots` prop.\n * It's recommended to use the `slots` prop instead.\n *\n * @default {}\n */\n components: PropTypes.shape({\n Arrow: PropTypes.elementType,\n Popper: PropTypes.elementType,\n Tooltip: PropTypes.elementType,\n Transition: PropTypes.elementType\n }),\n /**\n * The extra props for the slot components.\n * You can override the existing props or add new ones.\n *\n * This prop is an alias for the `slotProps` prop.\n * It's recommended to use the `slotProps` prop instead, as `componentsProps` will be deprecated in the future.\n *\n * @default {}\n */\n componentsProps: PropTypes.shape({\n arrow: PropTypes.object,\n popper: PropTypes.object,\n tooltip: PropTypes.object,\n transition: PropTypes.object\n }),\n /**\n * Set to `true` if the `title` acts as an accessible description.\n * By default the `title` acts as an accessible label for the child.\n * @default false\n */\n describeChild: PropTypes.bool,\n /**\n * Do not respond to focus-visible events.\n * @default false\n */\n disableFocusListener: PropTypes.bool,\n /**\n * Do not respond to hover events.\n * @default false\n */\n disableHoverListener: PropTypes.bool,\n /**\n * Makes a tooltip not interactive, i.e. it will close when the user\n * hovers over the tooltip before the `leaveDelay` is expired.\n * @default false\n */\n disableInteractive: PropTypes.bool,\n /**\n * Do not respond to long press touch events.\n * @default false\n */\n disableTouchListener: PropTypes.bool,\n /**\n * The number of milliseconds to wait before showing the tooltip.\n * This prop won't impact the enter touch delay (`enterTouchDelay`).\n * @default 100\n */\n enterDelay: PropTypes.number,\n /**\n * The number of milliseconds to wait before showing the tooltip when one was already recently opened.\n * @default 0\n */\n enterNextDelay: PropTypes.number,\n /**\n * The number of milliseconds a user must touch the element before showing the tooltip.\n * @default 700\n */\n enterTouchDelay: PropTypes.number,\n /**\n * If `true`, the tooltip follow the cursor over the wrapped element.\n * @default false\n */\n followCursor: PropTypes.bool,\n /**\n * This prop is used to help implement the accessibility logic.\n * If you don't provide this prop. It falls back to a randomly generated id.\n */\n id: PropTypes.string,\n /**\n * The number of milliseconds to wait before hiding the tooltip.\n * This prop won't impact the leave touch delay (`leaveTouchDelay`).\n * @default 0\n */\n leaveDelay: PropTypes.number,\n /**\n * The number of milliseconds after the user stops touching an element before hiding the tooltip.\n * @default 1500\n */\n leaveTouchDelay: PropTypes.number,\n /**\n * Callback fired when the component requests to be closed.\n *\n * @param {React.SyntheticEvent} event The event source of the callback.\n */\n onClose: PropTypes.func,\n /**\n * Callback fired when the component requests to be open.\n *\n * @param {React.SyntheticEvent} event The event source of the callback.\n */\n onOpen: PropTypes.func,\n /**\n * If `true`, the component is shown.\n */\n open: PropTypes.bool,\n /**\n * Tooltip placement.\n * @default 'bottom'\n */\n placement: PropTypes.oneOf(['bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n /**\n * The component used for the popper.\n * @default Popper\n */\n PopperComponent: PropTypes.elementType,\n /**\n * Props applied to the [`Popper`](/material-ui/api/popper/) element.\n * @default {}\n */\n PopperProps: PropTypes.object,\n /**\n * The extra props for the slot components.\n * You can override the existing props or add new ones.\n *\n * This prop is an alias for the `componentsProps` prop, which will be deprecated in the future.\n *\n * @default {}\n */\n slotProps: PropTypes.shape({\n arrow: PropTypes.object,\n popper: PropTypes.object,\n tooltip: PropTypes.object,\n transition: PropTypes.object\n }),\n /**\n * The components used for each slot inside.\n *\n * This prop is an alias for the `components` prop, which will be deprecated in the future.\n *\n * @default {}\n */\n slots: PropTypes.shape({\n arrow: PropTypes.elementType,\n popper: PropTypes.elementType,\n tooltip: PropTypes.elementType,\n transition: PropTypes.elementType\n }),\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Tooltip title. Zero-length titles string, undefined, null and false are never displayed.\n */\n title: PropTypes.node,\n /**\n * The component used for the transition.\n * [Follow this guide](/material-ui/transitions/#transitioncomponent-prop) to learn more about the requirements for this component.\n * @default Grow\n */\n TransitionComponent: PropTypes.elementType,\n /**\n * Props applied to the transition element.\n * By default, the element is based on this [`Transition`](http://reactcommunity.org/react-transition-group/transition/) component.\n */\n TransitionProps: PropTypes.object\n} : void 0;\nexport default Tooltip;","import '@/components/mui/menu-item.component.css';\nimport ArrowRightIcon from '@mui/icons-material/ArrowRight';\nimport {\n ListItemIcon as MuiListItemIcon,\n ListItemText as MuiListItemText,\n MenuItem as MuiMenuItem,\n} from '@mui/material';\nimport Tooltip from '@mui/material/Tooltip';\nimport { Localized, ReferencedItem, SingleColumnMenu } from 'platform-bible-utils';\nimport { MouseEvent, PropsWithChildren } from 'react';\n\ntype MenuItemInfoBase = {\n /** Text (displayable in the UI) as the name of the menu item */\n label: string;\n /** Text to display when the mouse hovers over the menu item */\n tooltip?: string;\n};\n\nexport type Command = MenuItemInfoBase & {\n /** Command to execute (string.string) */\n command: string;\n};\n\ntype SubMenu = MenuItemInfoBase & {\n /** Command to execute (string.string) */\n items: MenuItemInfo[];\n};\n\nexport interface CommandHandler {\n (command: Command): void;\n}\n\nexport type MenuPropsBase = {\n /*\n * The JSON defining the menu whose items are to be rendered. This will typically be one of the\n * menus in the \"defs\" in a Platform.Bible menu (see PlatformMenus). The schema for this is\n * menuDocumentSchema (at the end of menus.model.ts). Note that while this is a\n * \"SingleColumnMenu\", somewhat bizarrely, a MultiColumnMenu is a SingleColumnMenu, so it really\n * could be a MultiColumnMenu, in which case, column had better be defined so it can be used\n * to filter out the actual groups and items to display on the column.\n */\n menuDefinition: Localized;\n\n commandHandler: CommandHandler;\n\n /**\n * Additional action to perform when any menu item is clicked. Allows the caller to handle event\n * (e.g., to close the menu).\n */\n onClick?: (event: MouseEvent) => void;\n};\n\nexport type MenuItemListProps = MenuPropsBase & {\n /** Optional unique (column) identifier */\n columnId?: ReferencedItem;\n};\n\nexport type MenuItemProps = Omit &\n PropsWithChildren<{\n /** Optional unique identifier */\n id?: string;\n\n onClick: (event: MouseEvent) => void;\n }>;\n\ntype MenuItemInfo = (Command | SubMenu) & {\n /**\n * If specified, menu item will be inset if it does not have a leading icon.\n *\n * @default true\n */\n allowForLeadingIcons?: boolean;\n /**\n * If specified, the path to the icon image to display on the leading side of the menu text.\n *\n * @default undefined (no leading icon will be shown)\n */\n iconPathBefore?: string;\n /**\n * If specified, the path to the icon image to display on the trailing side of the menu text.\n *\n * @default undefined (no trailing icon will be shown)\n */\n iconPathAfter?: string;\n /**\n * If true, list item is focused during the first mount\n *\n * @default false\n */\n hasAutoFocus?: boolean;\n\n /** Additional css classes to help with unique styling of the menu item */\n className?: string;\n\n /**\n * If true, the menu item will appear disabled and it will not respond to clicks or mouse hovers.\n *\n * @default false\n */\n isDisabled?: boolean;\n\n /**\n * If true, compact vertical padding designed for keyboard and mouse input is used.\n *\n * @default true\n */\n isDense?: boolean;\n\n /**\n * If true, a right-arrow icon will be displayed (iconPathAfter, if specified, will be ignored).\n *\n * @default false\n */\n isSubMenuParent?: boolean;\n\n /**\n * If true, the left and right padding is removed\n *\n * @default false\n */\n hasDisabledGutters?: boolean;\n\n /**\n * If true, a 1px light border is added to bottom of menu item\n *\n * @default false\n */\n hasDivider?: boolean;\n\n /** Help identify which element has keyboard focus */\n focusVisibleClassName?: string;\n\n /** If it's a submenu, it should have the items property */\n items?: MenuItemInfo[];\n};\n\nfunction getIcon(icon: string | undefined, menuLabel: string, leading: boolean) {\n return icon ? (\n \n {`${leading\n \n ) : undefined;\n}\n\nexport default function MenuItem(props: MenuItemProps) {\n const {\n onClick,\n label,\n tooltip,\n allowForLeadingIcons = true,\n iconPathBefore = undefined,\n iconPathAfter = undefined,\n hasAutoFocus = false,\n className,\n isDisabled = false,\n isDense = true,\n isSubMenuParent = false,\n hasDisabledGutters = false,\n hasDivider = false,\n focusVisibleClassName,\n id,\n children,\n } = props;\n\n const menuItem = (\n \n {label ? (\n <>\n {getIcon(iconPathBefore, label, true)}\n \n {isSubMenuParent ? (\n \n \n \n ) : (\n getIcon(iconPathAfter, label, false)\n )}\n \n ) : (\n children\n )}\n \n );\n\n return tooltip ? (\n \n
    {menuItem}
    \n
    \n ) : (\n menuItem\n );\n}\n","import MenuItem, {\n MenuItemListProps,\n MenuItemProps,\n MenuPropsBase,\n} from '@/components/mui/menu-item.component';\nimport { Menu } from '@mui/material';\nimport {\n Localized,\n MenuGroupDetailsInSubMenu,\n MenuItemContainingCommand,\n MenuItemContainingSubmenu,\n OrderedExtensibleContainer,\n ReferencedItem,\n SingleColumnMenu,\n} from 'platform-bible-utils';\nimport { MouseEvent, useMemo, useState } from 'react';\n\n/**\n * All the exported types in this file should be regarded as \"internal\" (i.e., they should not be\n * exposed via index.ts).\n */\n\nexport type GroupedMenuPropsBase = MenuPropsBase & {\n /** Optional unique (column) identifier */\n columnId?: ReferencedItem;\n};\n\nexport type GroupedMenuItemListProps = MenuItemListProps & {\n /**\n * If the menuDefinition includes \"top-level\" groups (i.e., those that belong to a column as\n * opposed to those that belong to a submenu) that should not be included in the list, then this\n * array specifies which groups to include. Likewise, for a submenu, this list indicates which\n * groups are pertinent for that submenu. So then for a context menu this property need not be\n * specified since it is a top-level menu based on a \"true\" SingleColumnMenu (i.e., one that is\n * not a MultiColumnMenu).\n */\n includedGroups?: {\n id: string;\n group: Localized;\n }[];\n};\n\ninterface ItemInfo {\n item: Localized;\n isLastItemInGroup: boolean;\n}\n\ntype SubMenuProps = MenuPropsBase & {\n parentMenuItem: Localized;\n parentItemProps: Omit, 'iconPathAfter'>;\n};\n\nfunction getAllGroups(menuDefinition: Localized) {\n const groupEntries = Object.entries(menuDefinition.groups);\n // Convert array of entries to array of objects with id and group properties\n return groupEntries.map(([key, value]) => ({ id: key, group: value }));\n}\n\nfunction SubMenu(props: SubMenuProps) {\n const [anchorEl, setAnchorEl] = useState(undefined);\n\n const { parentMenuItem, parentItemProps, menuDefinition } = props;\n\n const handleParentMenuItemClick = (event: MouseEvent) => {\n setAnchorEl(event.currentTarget);\n };\n\n const handleClose = () => {\n setAnchorEl(undefined);\n };\n\n const renderSubMenuItems = () => {\n let includedGroups = getAllGroups(menuDefinition).filter((g) => 'menuItem' in g.group);\n\n // Ensure valid parent menu was provided. (If not, submenu will contain all groups!)\n if (!parentMenuItem?.id) throw new Error('A valid parent menu item is required for submenus.');\n\n // When laying out a submenu, only include groups associated with the provided parent menu.\n // Note: without the (annoying) redundant check that the included groups\n // have the menuItem field, TS doesn't think it exists.\n includedGroups = includedGroups.filter(\n (group) => 'menuItem' in group.group && group.group.menuItem === parentMenuItem.id,\n );\n\n return ;\n };\n\n return (\n <>\n \n \n {renderSubMenuItems()}\n \n \n );\n}\n\nconst getOrderedGroupItems = (\n groupId: string,\n allItems: Localized[],\n) => {\n // Filter items that belong to the specified group\n const itemsForGroup = allItems.filter((item) => item.group === groupId);\n // Sort items based on order\n const sortedItems = itemsForGroup.sort((a, b) => (a.order || 0) - (b.order || 0));\n return sortedItems;\n};\n\n/**\n * This component is internal; it does not need to be exposed to the outside world since it is not\n * useful on its own. It is used to generate and lay out the MenuItems that appear either on a\n * top-level menu (in a GridMenu or ContextMenu) or in a submenu.\n */\nexport default function GroupedMenuItemList(menuProps: GroupedMenuItemListProps) {\n const { menuDefinition, onClick, commandHandler, includedGroups } = menuProps;\n\n const { items, allowForLeadingIcons } = useMemo(() => {\n const groupsToInclude =\n includedGroups && includedGroups.length > 0\n ? includedGroups\n : // We're apparently laying out a single-column menu (presumably a context menu). In this\n // case, all groups should be included except ones that belong to a submenu.\n getAllGroups(menuDefinition).filter((g) => !('menuItem' in g.group));\n\n const sortedGroups = Object.values(groupsToInclude).sort(\n (a, b) => (a.group.order || 0) - (b.group.order || 0),\n );\n\n const itemArray: ItemInfo[] = [];\n\n sortedGroups.forEach((group) => {\n getOrderedGroupItems(group.id, menuDefinition.items).forEach((item) =>\n itemArray.push({ item, isLastItemInGroup: false }),\n );\n if (itemArray.length > 0) itemArray[itemArray.length - 1].isLastItemInGroup = true;\n });\n\n // No divider after last item in final group.\n if (itemArray.length > 0) itemArray[itemArray.length - 1].isLastItemInGroup = false;\n\n const allowSpaceForLeadingIcons = itemArray.some(\n (i) => 'iconPathBefore' in i.item && i.item.iconPathBefore,\n );\n\n return { items: itemArray, allowForLeadingIcons: allowSpaceForLeadingIcons };\n }, [includedGroups, menuDefinition]);\n\n // Create props for MenuItem component including setting hasDivider for the last item in a group\n const createMenuItemProps = ({ item, isLastItemInGroup }: ItemInfo) => {\n const menuItemProps = {\n className: 'papi-menu-item',\n label: item.label,\n tooltip: item.tooltip,\n iconPathBefore: 'iconPathBefore' in item ? item.iconPathBefore : undefined,\n iconPathAfter: 'iconPathAfter' in item ? item.iconPathAfter : undefined,\n hasDivider: isLastItemInGroup, // Set hasDivider to true for the last item in a group\n allowForLeadingIcons,\n };\n\n return menuItemProps;\n };\n\n const [firstItem] = items;\n\n if (!firstItem) return
    ;\n\n const divKey = firstItem.item.group;\n\n return (\n
    \n {items.map((itemInfo, index) => {\n const { item } = itemInfo;\n const menuItemProps = createMenuItemProps(itemInfo);\n if ('command' in item) {\n const key = item.group + index;\n return (\n ) => {\n onClick?.(event);\n commandHandler(item);\n }}\n {...menuItemProps}\n />\n );\n }\n return (\n \n );\n })}\n
    \n );\n}\n","import GroupedMenuItemList from '@/components/mui/grouped-menu-item-list.component';\nimport { MenuItemListProps } from '@/components/mui/menu-item.component';\nimport { MultiColumnMenu } from 'platform-bible-utils';\n\n/**\n * This component is internal; it does not need to be exposed to the outside world since it is not\n * useful on its own. Use either GridMenu or ContextMenu.\n */\nexport default function TopLevelMenu(props: MenuItemListProps) {\n const { menuDefinition, columnId } = props;\n\n const groupEntries = Object.entries(menuDefinition.groups);\n // Convert array of entries to array of objects with id and group properties\n const groups = groupEntries.map(([key, value]) => ({ id: key, group: value }));\n let includedGroups = groups.filter((g) => 'column' in g.group);\n\n // Check if column is provided and menuDefinition is a MultiColumnMenu\n if (\n columnId &&\n 'columns' in menuDefinition &&\n // Without this type assertion, TS doesn't know what columns is.\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n (menuDefinition as MultiColumnMenu).columns[columnId]\n ) {\n // When laying out a single column in a MultiColumnMenu, only include groups associated with\n // the provided column. Note: without the (annoying) redundant check that the included groups\n // have the colum field, TS doesn't think it exists.\n includedGroups = includedGroups.filter(\n (g) => 'column' in g.group && g.group.column === columnId,\n );\n }\n\n return ;\n}\n","import '@/components/mui/grid-menu.component.css';\nimport { GroupedMenuPropsBase } from '@/components/mui/grouped-menu-item-list.component';\nimport { CommandHandler } from '@/components/mui/menu-item.component';\nimport TopLevelMenu from '@/components/mui/top-level-menu.component';\nimport { Grid, List } from '@mui/material';\nimport {\n Localized,\n MenuColumnWithHeader,\n MultiColumnMenu,\n ReferencedItem,\n} from 'platform-bible-utils';\nimport { useMemo } from 'react';\n\ntype ColumnInfo = {\n /*\n * The ID (`${string}.${string}`) of a specific menu column.\n */\n id: ReferencedItem;\n\n /*\n * Metadata (label, order, etc.) for a specific menu column.\n */\n metadata: Localized;\n};\n\ntype MenuColumnProps = ColumnInfo &\n GroupedMenuPropsBase & {\n /** Additional css classes to help with unique styling of the menu column */\n className?: string;\n };\n\nexport type GridMenuInfo = {\n /** The menu object containing information about the columns, groups, and items to display. */\n multiColumnMenu: Localized;\n};\n\nexport type GridMenuProps = GridMenuInfo & {\n /** Optional unique identifier */\n id?: string;\n\n commandHandler: CommandHandler;\n\n /** Additional css classes to help with unique styling of the grid menu */\n className?: string;\n};\n\nfunction MenuColumn({\n commandHandler,\n menuDefinition,\n id,\n metadata,\n onClick,\n className,\n}: MenuColumnProps) {\n return (\n \n

    \n {metadata.label}\n

    \n {/* It would seem as though this List component were unnecessary, since it only contains one\n thing, but the \"dense\" property does affect the layout of the items (in a way I don't fully\n understand). There might be a better way. */}\n \n \n \n \n );\n}\n\nexport default function GridMenu({\n commandHandler,\n className,\n multiColumnMenu,\n id,\n}: GridMenuProps) {\n const { columns } = multiColumnMenu;\n\n const sortedColumns = useMemo(() => {\n const columnNumbers = new Map();\n Object.getOwnPropertyNames(columns).forEach((columnName: string) => {\n // We know for sure there is a (boolean) property 'isExtensible' that we are not interested in.\n if (columnName === 'isExtensible') return;\n // TS doesn't allow `columnName` above to be a ReferencedItem even though the type says it is\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const columnId = columnName as ReferencedItem;\n const column = columns[columnId];\n // As of right now (and hopefully forever after), all remaining properties of the\n // ColumnsWithHeaders object are columns whose property names are the IDs of the columns.\n // This is an additional (redundant) sanity check. Specifically we're interested in\n // MenuColumnWithHeader objects, which TypeScript now \"knows\" we have, but at runtime all we\n // can check for is that it's an object with a valid numeric order field. That's likely good\n // enough.\n if (\n typeof column === 'object' &&\n typeof column.order === 'number' &&\n !Number.isNaN(column.order)\n )\n columnNumbers.set(column.order, { id: columnId, metadata: column });\n else\n console.warn(\n `Property ${columnName} (${typeof column}) on menu ${id} is not a valid column and is being ignored. This might indicate data corruption`,\n );\n });\n\n // Extract values and sort them based on the 'order' property\n return Array.from(columnNumbers.values()).sort((a, b) => {\n return (a.metadata.order || 0) - (b.metadata.order || 0);\n });\n }, [columns, id]);\n\n // We might need something like this if we need to be able to prevent empty columns\n // sortedColumns.filter((c) => multiColumnMenu.groups.some((g) => 'column' in g && (g as .column)...\n\n return (\n \n {sortedColumns.map((col, index) => (\n \n ))}\n \n );\n}\n","import { useEffect, useRef, useState } from 'react';\n\nexport type UsePromiseOptions = {\n /**\n * Whether to leave the value as the most recent resolved promise value or set it back to\n * defaultValue while running the promise again. Defaults to true\n */\n preserveValue?: boolean;\n};\n\n/** Set up defaults for options for usePromise hook */\nfunction getUsePromiseOptionsDefaults(options: UsePromiseOptions): UsePromiseOptions {\n return {\n preserveValue: true,\n ...options,\n };\n}\n\n/**\n * Awaits a promise and returns a loading value while the promise is unresolved\n *\n * @param promiseFactoryCallback A function that returns the promise to await. If this callback is\n * undefined, the current value will be returned (defaultValue unless it was previously changed\n * and `options.preserveValue` is true), and there will be no loading.\n *\n * WARNING: MUST BE STABLE - const or wrapped in useCallback. The reference must not be updated\n * every render\n * @param defaultValue The initial value to return while first awaiting the promise. If\n * `options.preserveValue` is false, this value is also shown while awaiting the promise on\n * subsequent calls.\n *\n * Note: this parameter is internally assigned to a `ref`, so changing it will not cause any hooks\n * to re-run with its new value. This means that, if the `promiseFactoryCallback` changes and\n * `options.preserveValue` is `false`, the returned value will be set to the current\n * `defaultValue`. However, the returned value will not be updated if`defaultValue` changes.\n * @param options Various options for adjusting how this hook runs the `promiseFactoryCallback`\n *\n * Note: this parameter is internally assigned to a `ref`, so changing it will not cause any hooks\n * to re-run with its new value. However, the latest `options.preserveValue` will always be used\n * appropriately to determine whether to preserve the returned value when changing the\n * `promiseFactoryCallback`\n * @returns `[value, isLoading]`\n *\n * - `value`: the current value for the promise, either the defaultValue or the resolved promise value\n * - `isLoading`: whether the promise is waiting to be resolved\n */\nconst usePromise = (\n promiseFactoryCallback: (() => Promise) | undefined,\n defaultValue: T,\n options: UsePromiseOptions = {},\n): [value: T, isLoading: boolean] => {\n // Use defaultValue as a ref so it doesn't update dependency arrays\n const defaultValueRef = useRef(defaultValue);\n defaultValueRef.current = defaultValue;\n // Use options as a ref so it doesn't update dependency arrays\n const optionsDefaultedRef = useRef(options);\n optionsDefaultedRef.current = getUsePromiseOptionsDefaults(optionsDefaultedRef.current);\n\n const [value, setValue] = useState(() => defaultValueRef.current);\n const [isLoading, setIsLoading] = useState(true);\n useEffect(() => {\n let promiseIsCurrent = true;\n // If a promiseFactoryCallback was provided, we are loading. Otherwise, there is no loading to do\n setIsLoading(!!promiseFactoryCallback);\n (async () => {\n // If there is a callback to run, run it\n if (promiseFactoryCallback) {\n const result = await promiseFactoryCallback();\n // If the promise was not already replaced, update the value\n if (promiseIsCurrent) {\n setValue(() => result);\n setIsLoading(false);\n }\n }\n })();\n\n return () => {\n // Mark this promise as old and not to be used\n promiseIsCurrent = false;\n if (!optionsDefaultedRef.current.preserveValue) setValue(() => defaultValueRef.current);\n };\n }, [promiseFactoryCallback]);\n\n return [value, isLoading];\n};\nexport default usePromise;\n","\"use client\";\n\nimport createSvgIcon from './utils/createSvgIcon';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nexport default createSvgIcon( /*#__PURE__*/_jsx(\"path\", {\n d: \"M3 18h18v-2H3zm0-5h18v-2H3zm0-7v2h18V6z\"\n}), 'Menu');","import GridMenu from '@/components/mui/grid-menu.component';\nimport { Command, CommandHandler } from '@/components/mui/menu-item.component';\nimport usePromise from '@/hooks/use-promise.hook';\nimport { Menu as MenuIcon } from '@mui/icons-material';\nimport { Drawer, IconButton } from '@mui/material';\nimport { Localized, MultiColumnMenu } from 'platform-bible-utils';\nimport {\n MouseEvent,\n MutableRefObject,\n PropsWithChildren,\n useCallback,\n useEffect,\n useState,\n} from 'react';\n\nexport interface MultiColumnMenuProvider {\n (isSupportAndDevelopment: boolean): Promise>;\n}\n\nexport type HamburgerMenuButtonProps = PropsWithChildren & {\n /** The handler to use for menu commands (and eventually toolbar commands). */\n commandHandler: CommandHandler;\n\n /**\n * Optional reference to the \"div\" container that determines the where the menu should appear. If\n * not defined, then (1,1) used.\n */\n containerRef?: MutableRefObject;\n\n /**\n * The delegate to use to get the menu data. If not specified or if it returns undefined, the data\n * in normalMenu or fullMenu property will be used.\n */\n menuProvider?: MultiColumnMenuProvider;\n\n /**\n * The menu data to show when the menu is opened if the menuProvider property is not defined.\n * (This allows for a default or test-only static menu to be used.)\n */\n normalMenu?: Localized;\n\n /**\n * The menu data to show for \"full\" menu (when opened with the SHIFT key pressed) if the\n * menuProvider property is not defined. (This allows for a default or test-only static menu to be\n * used.)\n */\n fullMenu?: Localized;\n\n /** Additional css class(es) to help with unique styling of the sub-components */\n className?: string;\n\n /** Value to use as prefix for ARIA labels on interactive sub-components */\n ariaLabelPrefix?: string;\n};\n\nexport default function HamburgerMenuButton({\n menuProvider,\n normalMenu,\n fullMenu,\n commandHandler,\n containerRef,\n className,\n ariaLabelPrefix,\n children,\n}: HamburgerMenuButtonProps) {\n const [isMenuOpen, setMenuOpen] = useState(false);\n const [showFullMenu, setShowFullMenu] = useState(false);\n\n const handleMenuItemClick = useCallback(() => {\n if (isMenuOpen) setMenuOpen(false);\n setShowFullMenu(false);\n }, [isMenuOpen]);\n\n const handleMenuButtonClick = useCallback((e: MouseEvent) => {\n e.stopPropagation();\n setMenuOpen((prevIsOpen) => {\n const isOpening = !prevIsOpen;\n if (isOpening && e.shiftKey) setShowFullMenu(true);\n else if (!isOpening) setShowFullMenu(false);\n return isOpening;\n });\n }, []);\n\n const menuCommandHandler = useCallback(\n (command: Command) => {\n handleMenuItemClick();\n return commandHandler(command);\n },\n [commandHandler, handleMenuItemClick],\n );\n\n const [offset, setOffset] = useState({ top: 1, left: 1 });\n\n useEffect(() => {\n if (isMenuOpen) {\n const node = containerRef?.current;\n if (node) {\n const rect = node.getBoundingClientRect();\n const scrollTop = window.scrollY;\n const scrollLeft = window.scrollX;\n const top = rect.top + scrollTop + node.clientHeight;\n const left = rect.left + scrollLeft;\n setOffset({ top, left });\n }\n }\n }, [isMenuOpen, containerRef]);\n\n const [normalMenuData] = usePromise(\n useCallback(async () => {\n return menuProvider?.(false) ?? normalMenu;\n // isMenuOpen needs to be included for the menu contents to reevaluate when reopened\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [menuProvider, normalMenu, isMenuOpen]),\n normalMenu,\n );\n\n const [fullMenuData] = usePromise(\n useCallback(async () => {\n return menuProvider?.(true) ?? fullMenu ?? normalMenuData;\n // isMenuOpen needs to be included for the menu contents to reevaluate when reopened\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [menuProvider, fullMenu, normalMenuData, isMenuOpen]),\n fullMenu ?? normalMenuData,\n );\n\n const menu = showFullMenu && fullMenuData ? fullMenuData : normalMenuData;\n\n return (\n <>\n \n {children ?? }\n \n \n {menu ? (\n \n ) : undefined}\n \n \n );\n}\n","import '@/components/mui/icon-button.component.css';\nimport { IconButton as MuiIconButton } from '@mui/material';\nimport { MouseEventHandler, PropsWithChildren } from 'react';\n\nexport type IconButtonProps = PropsWithChildren<{\n /** Optional unique identifier */\n id?: string;\n /**\n * Required. Used as both the tooltip (aka, title) and the aria-label (used for accessibility,\n * testing, etc.), unless a distinct tooltip is supplied.\n */\n label: string;\n /**\n * Enabled status of button\n *\n * @default false\n */\n isDisabled?: boolean;\n /** Optional tooltip to display if different from the aria-label. */\n tooltip?: string;\n /** If true, no tooltip will be displayed. */\n isTooltipSuppressed?: boolean;\n /**\n * If given, uses a negative margin to counteract the padding on one side (this is often helpful\n * for aligning the left or right side of the icon with content above or below, without ruining\n * the border size and shape).\n *\n * @default false\n */\n adjustMarginToAlignToEdge?: 'end' | 'start' | false;\n /**\n * The size of the component. small is equivalent to the dense button styling.\n *\n * @default false\n */\n size: 'small' | 'medium' | 'large';\n /** Additional css classes to help with unique styling of the button */\n className?: string;\n /** Optional click handler */\n onClick?: MouseEventHandler;\n}>;\n\n/**\n * Iconic button a user can click to do something\n *\n * Thanks to MUI for heavy inspiration and documentation\n * https://mui.com/material-ui/getting-started/overview/\n */\nfunction IconButton({\n id,\n label,\n isDisabled = false,\n tooltip,\n isTooltipSuppressed = false,\n adjustMarginToAlignToEdge = false,\n size = 'medium',\n className,\n onClick,\n children,\n}: IconButtonProps) {\n return (\n \n {children /* the icon to display */}\n \n );\n}\n\nexport default IconButton;\n","import { cn } from '@/utils/shadcn-ui.util';\nimport { LoaderCircle, LucideProps } from 'lucide-react';\nimport { forwardRef } from 'react';\n\nexport type SpinnerProps = LucideProps;\n\nconst Spinner = forwardRef(({ className, ...props }, ref) => {\n return (\n \n );\n});\n\nSpinner.displayName = 'Spinner';\n\nexport default Spinner;\n","import { Input as ShadInput } from '@/components/shadcn-ui/input';\nimport { Label as ShadLabel } from '@/components/shadcn-ui/label';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { ChangeEventHandler, FocusEventHandler } from 'react';\n\nexport type TextFieldProps = {\n /** Optional unique identifier */\n id?: string;\n /**\n * If `true`, the component is disabled.\n *\n * @default false\n */\n isDisabled?: boolean;\n /**\n * If `true`, the label is displayed in an error state.\n *\n * @default false\n */\n hasError?: boolean;\n /**\n * If `true`, the input will take up the full width of its container.\n *\n * @default false\n */\n isFullWidth?: boolean;\n /** Text that gives the user instructions on what contents the TextField expects */\n helperText?: string;\n /** The title of the TextField */\n label?: string;\n /** The short hint displayed in the `input` before the user enters a value. */\n placeholder?: string;\n /**\n * If `true`, the label is displayed as required and the `input` element is required.\n *\n * @default false\n */\n isRequired?: boolean;\n /** Additional css classes to help with unique styling of the text field */\n className?: string;\n /** Starting value for the text field if it is not controlled */\n defaultValue?: string | number;\n /** Value of the text field if controlled */\n value?: string | number;\n /** Triggers when content of textfield is changed */\n onChange?: ChangeEventHandler;\n /** Triggers when textfield gets focus */\n onFocus?: FocusEventHandler;\n /** Triggers when textfield loses focus */\n onBlur?: FocusEventHandler;\n};\n\n/**\n * Text input field\n *\n * Thanks to Shadcn for heavy inspiration and documentation\n * https://ui.shadcn.com/docs/components/input#with-label\n */\nfunction TextField({\n id,\n isDisabled = false,\n hasError = false,\n isFullWidth = false,\n helperText,\n label,\n placeholder,\n isRequired = false,\n className,\n defaultValue,\n value,\n onChange,\n onFocus,\n onBlur,\n}: TextFieldProps) {\n return (\n
    \n {`${label}${isRequired ? '*' : ''}`}\n \n

    {helperText}

    \n
    \n );\n}\n\nexport default TextField;\n","import HamburgerMenuButton, {\n MultiColumnMenuProvider,\n} from '@/components/mui/hamburger-menu-button.component';\nimport { CommandHandler } from '@/components/mui/menu-item.component';\nimport '@/components/mui/toolbar.component.css';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { AppBar, Toolbar as MuiToolbar } from '@mui/material';\nimport { PropsWithChildren, useRef } from 'react';\n\nexport type ToolbarProps = PropsWithChildren<{\n /** The handler to use for menu commands (and eventually toolbar commands). */\n commandHandler: CommandHandler;\n\n /**\n * The optional delegate to use to get the menu data. If not specified, the \"hamburger\" menu will\n * not display.\n */\n menuProvider?: MultiColumnMenuProvider;\n\n /** Optional unique identifier */\n id?: string;\n\n /** Additional css classes to help with unique styling of the toolbar */\n className?: string;\n}>;\n\nexport default function Toolbar({\n menuProvider,\n commandHandler,\n className,\n id,\n children,\n}: ToolbarProps) {\n // This ref will always be defined\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const containerRef = useRef(undefined!);\n\n return (\n
    \n \n \n {menuProvider ? (\n \n ) : undefined}\n {children ?
    {children}
    : undefined}\n \n
    \n
    \n );\n}\n","import React from 'react';\nimport { cva, type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst alertVariants = cva(\n 'tw-relative tw-w-full tw-rounded-lg tw-border tw-p-4 [&>svg~*]:tw-pl-7 [&>svg+div]:tw-translate-y-[-3px] [&>svg]:tw-absolute [&>svg]:tw-left-4 [&>svg]:tw-top-4 [&>svg]:tw-text-foreground',\n {\n variants: {\n variant: {\n default: 'tw-bg-background tw-text-foreground',\n destructive:\n 'tw-border-destructive/50 tw-text-destructive dark:tw-border-destructive [&>svg]:tw-text-destructive',\n },\n },\n defaultVariants: {\n variant: 'default',\n },\n },\n);\n\nconst Alert = React.forwardRef<\n HTMLDivElement,\n React.HTMLAttributes & VariantProps\n>(({ className, variant, ...props }, ref) => (\n
    \n));\nAlert.displayName = 'Alert';\n\nconst AlertTitle = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n {/* added because of https://github.com/jsx-eslint/eslint-plugin-jsx-a11y/blob/main/docs/rules/heading-has-content.md */}\n {props.children}{' '}\n \n ),\n);\nAlertTitle.displayName = 'AlertTitle';\n\nconst AlertDescription = React.forwardRef<\n HTMLParagraphElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n
    \n));\nAlertDescription.displayName = 'AlertDescription';\n\nexport { Alert, AlertTitle, AlertDescription };\n","import { ComponentProps } from 'react';\nimport { toast as sonner, Toaster } from 'sonner';\n\ntype SonnerProps = ComponentProps;\n\nfunction Sonner({ ...props }: SonnerProps) {\n return (\n \n );\n}\n\n// The re-export of the sonner function was added manually\nexport { Sonner, sonner };\n","import React from 'react';\nimport * as SliderPrimitive from '@radix-ui/react-slider';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Slider = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n \n \n \n));\nSlider.displayName = SliderPrimitive.Root.displayName;\n\nexport { Slider };\n","import React from 'react';\nimport * as SwitchPrimitives from '@radix-ui/react-switch';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Switch = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n));\nSwitch.displayName = SwitchPrimitives.Root.displayName;\n\nexport { Switch };\n","import React from 'react';\nimport * as TabsPrimitive from '@radix-ui/react-tabs';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport const Tabs = TabsPrimitive.Root;\n\nexport type TabsListProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport type TabsTriggerProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport type TabsContentProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport const TabsList = React.forwardRef<\n React.ElementRef,\n TabsListProps\n>(({ className, ...props }, ref) => (\n \n));\nTabsList.displayName = TabsPrimitive.List.displayName;\n\nexport const TabsTrigger = React.forwardRef<\n React.ElementRef,\n TabsTriggerProps\n>(({ className, ...props }, ref) => (\n \n));\nTabsTrigger.displayName = TabsPrimitive.Trigger.displayName;\n\nexport const TabsContent = React.forwardRef<\n React.ElementRef,\n TabsContentProps\n>(({ className, ...props }, ref) => (\n \n));\nTabsContent.displayName = TabsPrimitive.Content.displayName;\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Download } from 'lucide-react';\n\ntype InstallButtonProps = {\n /** The installing boolean value determines the state of the button. */\n isInstalling: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n /** Optional text for the button. */\n buttonText?: string;\n} & ButtonProps;\n\n/**\n * The InstallButton component is a button designed for initiating installs. It includes visuals for\n * active installing and idle states.\n *\n * @param isInstalling The installing boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @param buttonText Optional text for the button.\n * @returns A install button.\n */\nexport default function InstallButton({\n isInstalling,\n handleClick,\n buttonText,\n className,\n ...props\n}: InstallButtonProps) {\n return (\n \n {isInstalling ? (\n \n ) : (\n <>\n \n {buttonText}\n \n )}\n \n );\n}\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\n\ntype EnableButtonProps = {\n /** The enabling boolean value determines the state of the button. */\n isEnabling: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n} & ButtonProps;\n\n/**\n * The EnableButton component is a button designed for initiating enabling of downloads. It includes\n * visuals for active enabling and idle states.\n *\n * @param isEnabling The enabling boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @returns A button that can be used to enable.\n */\nexport default function EnableButton({\n isEnabling,\n handleClick,\n className,\n ...props\n}: EnableButtonProps) {\n return (\n \n {isEnabling ? (\n <>\n \n Enabling...\n \n ) : (\n 'Enable'\n )}\n \n );\n}\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\n\ntype DisableButtonProps = {\n /** The disabling boolean value determines the state of the button. */\n isDisabling: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n} & ButtonProps;\n\n/**\n * The DisableButton component is a button designed for initiating disabling of downloads. It\n * includes visuals for active disabling and idle states.\n *\n * @param isDisabling The disabling boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @returns A button that can be used to disable.\n */\nexport default function DisableButton({\n isDisabling,\n handleClick,\n className,\n ...props\n}: DisableButtonProps) {\n return (\n \n {isDisabling ? (\n <>\n \n Disabling...\n \n ) : (\n 'Disable'\n )}\n \n );\n}\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\n\ntype UpdateButtonProps = {\n /** The updating boolean value determines the state of the button. */\n isUpdating: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n} & ButtonProps;\n\n/**\n * The UpdateButton component is a button designed for initiating updates for downloaded extensions.\n * It includes visuals for active updating and idle states.\n *\n * @param isUpdating The updating boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @returns A button that can be used to update.\n */\nexport default function UpdateButton({\n isUpdating,\n handleClick,\n className,\n ...props\n}: UpdateButtonProps) {\n return (\n \n {isUpdating ? (\n <>\n \n Updating...\n \n ) : (\n 'Update'\n )}\n \n );\n}\n","import { cn } from '@/utils/shadcn-ui.util';\nimport Markdown, { MarkdownToJSX } from 'markdown-to-jsx';\nimport { useMemo } from 'react';\n\ninterface MarkdownRendererProps {\n /** Optional unique identifier */\n id?: string;\n /** The markdown string to render */\n markdown: string;\n className?: string;\n /**\n * The [`target` attribute for `a` html\n * tags](https://developer.mozilla.org/en-US/docs/Web/HTML/Element/a#target). Defaults to not\n * adding a `target` to `a` tags\n */\n anchorTarget?: string;\n}\n\n/**\n * This component renders markdown content given a markdown string. It uses typography styles from\n * the platform.\n *\n * @param markdown The markdown string to render.\n * @param id Optional unique identifier\n * @returns A div containing the rendered markdown content.\n */\nexport default function MarkdownRenderer({\n id,\n markdown,\n className,\n anchorTarget,\n}: MarkdownRendererProps) {\n const options: MarkdownToJSX.Options = useMemo(\n () => ({\n overrides: {\n a: {\n props: {\n target: anchorTarget,\n },\n },\n },\n }),\n [anchorTarget],\n );\n return (\n
    \n {markdown}\n
    \n );\n}\n","import { Filter, ChevronDown } from 'lucide-react';\nimport { forwardRef } from 'react';\nimport { Button } from '@/components/shadcn-ui/button';\n\n/**\n * The FilterButton component is a button designed for initiating filtering of data. It is designed\n * to be used with the dropdown menu. It uses forwardRef to pass the button to the dropdown trigger\n * asChild.\n *\n * @returns A button that can be used to filter.\n */\nconst FilterButton = forwardRef((props, ref) => {\n return (\n \n \n Filter\n \n \n );\n});\n\nexport default FilterButton;\n","import {\n DropdownMenu,\n DropdownMenuTrigger,\n DropdownMenuContent,\n DropdownMenuLabel,\n DropdownMenuGroup,\n DropdownMenuCheckboxItem,\n DropdownMenuRadioItem,\n DropdownMenuSeparator,\n} from '@/components/shadcn-ui/dropdown-menu';\nimport FilterButton from './buttons/filter-button.component';\n\nexport enum DropdownMenuItemType {\n Check,\n Radio,\n}\n\nexport type DropdownItem = {\n /** The label is the text that will be displayed on the dropdown item. */\n label: string;\n /** The itemType determines the DropdownMenuItemType type as either Check or Radio. */\n itemType: DropdownMenuItemType;\n /** The onClick function is called when the item is clicked. */\n onClick: () => void;\n};\n\nexport type DropdownGroup = {\n /**\n * The label is the text that will be displayed on the dropdown group. It is used to categorize\n * the items in the group.\n */\n label: string;\n /** The items array contains the items that will be displayed in the dropdown group */\n items: DropdownItem[];\n};\n\nexport type FilterDropdownProps = {\n /** Object unique identifier */\n id?: string;\n /** The groups array contains the groups that will be displayed in the dropdown */\n groups: DropdownGroup[];\n}; // TODO: extend the props later\n\n/**\n * The FilterDropdown component is a dropdown designed for filtering content. It includes groups of\n * items that can be checkboxes or radio items.\n *\n * @param id Optional unique identifier\n * @param groups The groups array contains the groups that will be displayed in the dropdown\n * @returns A filter dropdown.\n */\nexport default function FilterDropdown({ id, groups }: FilterDropdownProps) {\n return (\n
    \n {/* TODO: remove this once the DropDown Menu shadcn has an id prop */}\n \n \n \n \n \n {groups.map((group) => (\n
    \n {group.label}\n \n {group.items.map((item) => (\n
    \n {item.itemType === DropdownMenuItemType.Check ? (\n \n {item.label}\n \n ) : (\n \n {item.label}\n \n )}\n
    \n ))}\n
    \n \n
    \n ))}\n
    \n
    \n
    \n );\n}\n","interface NoExtensionsFoundProps {\n /** Optional unique identifier */\n id?: string;\n /** The message to display */\n message: string;\n}\n/**\n * This component displays a message to the user when no extensions are found in the marketplace.\n *\n * @param id Optional unique identifier\n * @param message The message to display.\n * @returns {JSX.Element} - Returns the message component that displays the message to the user.\n */\nexport default function NoExtensionsFound({ id, message }: NoExtensionsFoundProps) {\n return (\n
    \n
    \n

    {message}

    \n
    \n
    \n );\n}\n","import { CircleHelp, Link as LucideLink, User } from 'lucide-react';\nimport { NumberFormat } from 'platform-bible-utils';\n\n/** Interface that stores the parameters passed to the More Info component */\ninterface MoreInfoProps {\n /** Optional unique identifier */\n id?: string;\n /** The category of the extension */\n category: string;\n /** The number of downloads for the extension */\n downloads: Record;\n /** The languages supported by the extension */\n languages: string[];\n /** The URL to the more info page of the extension */\n moreInfoUrl: string;\n}\n/**\n * This component displays the more info section of the extension which includes the category,\n * number of downloads, languages, and links to the website and support\n *\n * @param id Optional unique identifier\n * @param category The category of the extension\n * @param downloads The number of downloads for the extension\n * @param languages The languages supported by the extension\n * @param moreInfoUrl The URL to the more info page of the extension\n * @returns {JSX.Element} - Returns the more info component that displays the category, number of\n * downloads, languages, and links to the website and support\n */\nexport default function MoreInfo({\n id,\n category,\n downloads,\n languages,\n moreInfoUrl,\n}: MoreInfoProps) {\n /**\n * This constant formats the number of downloads into a more readable format.\n *\n * @example 1000 -> 1K\n *\n * @example 1000000 -> 1M\n *\n * @returns The formatted number of downloads\n */\n const numberFormatted = new NumberFormat('en', {\n notation: 'compact',\n compactDisplay: 'short',\n }).format(Object.values(downloads).reduce((a: number, b: number) => a + b, 0));\n\n /** This function scrolls the window to the bottom of the page. */\n const handleScrollToBottom = () => {\n window.scrollTo(0, document.body.scrollHeight);\n };\n\n return (\n \n
    \n
    \n {category}\n
    \n CATEGORY\n
    \n
    \n
    \n
    \n \n {numberFormatted}\n
    \n USERS\n
    \n
    \n
    \n
    \n {languages.slice(0, 3).map((locale) => (\n \n {locale.toUpperCase()}\n \n ))}\n
    \n {languages.length > 3 && (\n handleScrollToBottom()}\n className=\"tw-text-xs tw-text-gray-500 tw-underline\"\n >\n +{languages.length - 3} more languages\n \n )}\n
    \n
    \n
    \n \n Website\n \n \n \n Support\n \n \n
    \n
    \n );\n}\n","import { useState } from 'react';\n\nexport type VersionInformation = {\n /** Date the version was published */\n date: string;\n /** Description of the changes in the version */\n description: string;\n};\n\n/** Type to store the version history information */\nexport type VersionHistoryType = Record;\n\n/** Interface that stores the parameters passed to the Version History component */\ninterface VersionHistoryProps {\n /** Optional unique identifier */\n id?: string;\n /** Object containing the versions mapped with their information */\n versionHistory: VersionHistoryType;\n}\n\n/**\n * Component to render the version history information shown in the footer component. Lists the 5\n * most recent versions, with the options to show all versions by pressing a button.\n *\n * @param versionHistory Object containing the versions mapped with their information\n * @param id Optional unique identifier\n * @returns Rendered version history for the Footer component\n */\nexport default function VersionHistory({ id, versionHistory }: VersionHistoryProps) {\n const [showAllVersions, setShowAllVersions] = useState(false);\n const currentDate = new Date();\n\n /**\n * Function to format the time string for the version history in the form of 'X year(s) ago'.\n *\n * @param dateString ISO Date string to determine the time string from\n * @returns Formatted time string\n */\n function formatTimeString(dateString: string) {\n const date = new Date(dateString);\n const dateDiff = new Date(currentDate.getTime() - date.getTime());\n const yearDiff = dateDiff.getUTCFullYear() - 1970;\n const monthDiff = dateDiff.getUTCMonth();\n const dayDiff = dateDiff.getUTCDate() - 1;\n\n // Determines how long ago the version was published\n let timeString = '';\n if (yearDiff > 0) {\n timeString = `${yearDiff.toString()} year${yearDiff === 1 ? '' : 's'} ago`;\n } else if (monthDiff > 0) {\n timeString = `${monthDiff.toString()} month${monthDiff === 1 ? '' : 's'} ago`;\n } else if (dayDiff === 0) {\n timeString = 'today';\n } else {\n timeString = `${dayDiff.toString()} day${dayDiff === 1 ? '' : 's'} ago`;\n }\n\n return timeString;\n }\n\n // Sorts the version history by version number\n const sortedEntries = Object.entries(versionHistory).sort((a, b) => b[0].localeCompare(a[0]));\n\n return (\n
    \n

    What`s New

    \n
      \n {(showAllVersions ? sortedEntries : sortedEntries.slice(0, 5)).map((entry) => (\n
      \n
      \n
    • \n {entry[1].description}\n
    • \n
      \n
      \n
      Version {entry[0]}
      \n
      {formatTimeString(entry[1].date)}
      \n
      \n
      \n ))}\n
    \n {sortedEntries.length > 5 && (\n setShowAllVersions(!showAllVersions)}\n className=\"tw-text-xs tw-text-gray-500 tw-underline\"\n >\n {showAllVersions ? 'Show Less Version History' : 'Show All Version History'}\n \n )}\n
    \n );\n}\n","import { useMemo } from 'react';\nimport { formatBytes } from 'platform-bible-utils';\nimport VersionHistory, { VersionHistoryType } from './version-history.component';\n\n/** Interface to store the parameters passed to the Footer component */\ninterface FooterProps {\n /** Optional unique identifier */\n id?: string;\n /** Name of the publisher */\n publisherDisplayName: string;\n /** Size of the extension file in bytes */\n fileSize: number;\n /** List of language codes supported by the extension */\n locales: string[];\n /** Object containing the version history mapped with their information */\n versionHistory: VersionHistoryType;\n}\n\n/**\n * Component to render the footer for the extension details which contains information on the\n * publisher, version history, languages, and file size.\n *\n * @param id Optional unique identifier\n * @param publisherDisplayName Name of the publisher\n * @param fileSize Size of the extension file in bytes\n * @param locales List of language codes supported by the extension\n * @param versionHistory Object containing the version history mapped with their information\n * @returns The rendered Footer component\n */\nexport default function Footer({\n id,\n publisherDisplayName,\n fileSize,\n locales,\n versionHistory,\n}: FooterProps) {\n /** Formats the file size into a human-readable format */\n const formattedFileSize = useMemo(() => formatBytes(fileSize), [fileSize]);\n\n /**\n * This function gets the display names of the languages based on the language codes.\n *\n * @param codes The list of language codes\n * @returns The list of language names\n */\n const getLanguageNames = (codes: string[]) => {\n const displayNames = new Intl.DisplayNames(navigator.language, { type: 'language' });\n return codes.map((code) => displayNames.of(code));\n };\n\n const languageNames = getLanguageNames(locales);\n\n return (\n
    \n
    \n \n
    \n
    \n

    Information

    \n
    \n

    \n Publisher\n {publisherDisplayName}\n Size\n {formattedFileSize}\n

    \n
    \n

    \n Languages\n {languageNames.join(', ')}\n

    \n
    \n
    \n
    \n
    \n
    \n );\n}\n","import { PlatformEvent, PlatformEventHandler } from 'platform-bible-utils';\nimport { useEffect } from 'react';\n\n/**\n * Adds an event handler to an event so the event handler runs when the event is emitted. Use\n * `papi.network.getNetworkEvent` to use a networked event with this hook.\n *\n * @param event The event to subscribe to.\n *\n * - If event is a `PlatformEvent`, that event will be used\n * - If event is undefined, the callback will not be subscribed. Useful if the event is not yet\n * available for example\n *\n * @param eventHandler The callback to run when the event is emitted\n *\n * WARNING: MUST BE STABLE - const or wrapped in useCallback. The reference must not be updated\n * every render\n */\nconst useEvent = (\n event: PlatformEvent | undefined,\n eventHandler: PlatformEventHandler,\n) => {\n useEffect(() => {\n // Do nothing if the event is not provided (in case the event is not yet available, for example)\n if (!event) return () => {};\n\n const unsubscriber = event(eventHandler);\n return () => {\n unsubscriber();\n };\n }, [event, eventHandler]);\n};\nexport default useEvent;\n","import { useCallback, useEffect } from 'react';\nimport { PlatformEvent, PlatformEventAsync, PlatformEventHandler } from 'platform-bible-utils';\nimport usePromise from './use-promise.hook';\n\nconst noopUnsubscriber = () => false;\n\n/**\n * Adds an event handler to an asynchronously subscribing/unsubscribing event so the event handler\n * runs when the event is emitted. Use `papi.network.getNetworkEvent` to use a networked event with\n * this hook.\n *\n * @param event The asynchronously (un)subscribing event to subscribe to.\n *\n * - If event is a `PlatformEvent` or `PlatformEventAsync`, that event will be used\n * - If event is undefined, the callback will not be subscribed. Useful if the event is not yet\n * available for example\n *\n * @param eventHandler The callback to run when the event is emitted\n *\n * WARNING: MUST BE STABLE - const or wrapped in useCallback. The reference must not be updated\n * every render\n */\nconst useEventAsync = (\n event: PlatformEvent | PlatformEventAsync | undefined,\n eventHandler: PlatformEventHandler,\n) => {\n // Subscribe to the event asynchronously\n const [unsubscribe] = usePromise(\n useCallback(async () => {\n // Do nothing if the event is not provided (in case the event is not yet available, for example)\n if (!event) return noopUnsubscriber;\n\n // Wrap subscribe and unsubscribe in promises to allow normal events to be used as well\n const unsub = await Promise.resolve(event(eventHandler));\n return async () => unsub();\n }, [eventHandler, event]),\n noopUnsubscriber,\n // We want the unsubscriber to return to default value immediately upon changing subscription\n // So the useEffect below will unsubscribe asap\n { preserveValue: false },\n );\n\n // Unsubscribe from the event asynchronously (but we aren't awaiting the unsub)\n useEffect(() => {\n return () => {\n if (unsubscribe !== noopUnsubscriber) {\n unsubscribe();\n }\n };\n }, [unsubscribe]);\n};\n\nexport default useEventAsync;\n"],"names":["twMergeCustom","extendTailwindMerge","cn","inputs","clsx","Input","React","className","type","props","ref","jsx","BookChapterInput","forwardRef","handleSearch","handleKeyDown","handleOnClick","handleSubmit","jsxs","ShadInput","event","e","History","P","R","t","s","n","N","B","O","S","K","g","k","x","T","X","V","w","L","G","A","H","C","I","y","q","U","m","l","h","c","E","D","i","a","o","u","v","f","d","b","p","J","DropdownMenu","DropdownMenuPrimitive","DropdownMenuTrigger","DropdownMenuGroup","DropdownMenuPortal","DropdownMenuSub","DropdownMenuRadioGroup","DropdownMenuSubTrigger","inset","children","ChevronRight","DropdownMenuSubContent","DropdownMenuContent","sideOffset","DropdownMenuItem","DropdownMenuCheckboxItem","checked","Check","DropdownMenuRadioItem","Circle","DropdownMenuLabel","DropdownMenuSeparator","DropdownMenuShortcut","BookMenuItem","bookId","handleSelectBook","isSelected","handleHighlightBook","bookType","ShadDropdownMenuItem","Canon","ChapterSelect","handleSelectChapter","endChapter","activeChapter","highlightedChapter","handleHighlightedChapter","chapters","_","handleMouse","useCallback","chapterNumber","chapter","GoToMenuItem","handleSort","handleLocationHistory","handleBookmarks","ShadDropdownMenuLabel","ArrowDownWideNarrow","Clock","Bookmark","ALL_BOOK_IDS","BOOK_TYPE_LABELS","BOOK_TYPE_ARRAY","SCROLL_OFFSET","SEARCH_QUERY_FORMATS","fetchGroupedBooks","fetchEndChapter","getChaptersForBook","getAllEnglishNames","isValidBookEnglishName","bookName","getBookIdFromEnglishName","formattedBookName","BookChapterControl","scrRef","searchQuery","setSearchQuery","useState","selectedBookId","setSelectedBookId","setHighlightedChapter","highlightedBookId","setHighlightedBookId","isContentOpen","setIsContentOpen","isContentOpenDelayed","setIsContentOpenDelayed","inputRef","useRef","contentRef","menuItemRef","fetchFilteredBooks","englishNameLowerCase","normalizedQuery","handleSearchInput","searchString","shouldPreventAutoClosing","controlMenuState","open","updateReference","shouldClose","verse","handleInputSubmit","format","matches","book","englishName","handleKeyDownInput","handleKeyDownContent","key","handleKeyDownMenuItem","chapterOffSet","useEffect","useLayoutEffect","scrollTimeout","scrollPosition","ShadDropdownMenu","ShadDropdownMenuTrigger","ShadDropdownMenuContent","bookTypeIndex","element","ShadDropdownMenuSeparator","buttonVariants","cva","Button","variant","size","asChild","Comp","Slot","labelVariants","Label","LabelPrimitive","RadioGroup","RadioGroupPrimitive","RadioGroupItem","Popover","PopoverPrimitive","PopoverTrigger","PopoverContent","align","DialogPortal","DialogPrimitive","DialogOverlay","DialogContent","DialogTitle","DialogDescription","Command","CommandPrimitive","CommandInput","Search","CommandList","CommandEmpty","CommandGroup","CommandSeparator","CommandItem","getOptionLabelDefault","option","ComboBox","id","options","buttonClassName","popoverContentClassName","value","onChange","getOptionLabel","buttonPlaceholder","textPlaceholder","commandEmptyMessage","buttonVariant","dir","isDisabled","setOpen","ChevronsUpDown","ChapterRangeSelector","startChapter","handleSelectStartChapter","handleSelectEndChapter","chapterCount","chapterOptions","useMemo","index","onChangeStartChapter","onChangeEndChapter","Fragment","BookSelectionMode","BOOK_SELECTOR_STRING_KEYS","localizeString","strings","BookSelector","handleBookSelectionModeChange","currentBookName","onSelectBooks","selectedBookIds","localizedStrings","currentBookText","chooseText","chooseBooksText","bookSelectionMode","setBookSelectionMode","onSelectionModeChange","newMode","DataTableViewOptions","table","FilterIcon","column","Select","SelectPrimitive","SelectGroup","SelectValue","SelectTrigger","ChevronDown","SelectScrollUpButton","ChevronUp","SelectScrollDownButton","SelectContent","position","SelectLabel","SelectItem","SelectSeparator","DataTablePagination","pageSize","ArrowLeftIcon","ChevronLeftIcon","ChevronRightIcon","ArrowRightIcon","Table","stickyHeader","TableHeader","TableBody","TableFooter","TableRow","TableHead","TableCell","TableCaption","DataTable","columns","data","enablePagination","showPaginationControls","showColumnVisibilityControls","onRowClickHandler","sorting","setSorting","columnFilters","setColumnFilters","columnVisibility","setColumnVisibility","rowSelection","setRowSelection","useReactTable","getCoreRowModel","getPaginationRowModel","getSortedRowModel","getFilteredRowModel","headerGroup","header","flexRender","_a","row","cell","OccurrencesTable","occurrenceData","setScriptureReference","referenceHeaderText","occurrenceHeaderText","occurrences","uniqueOccurrences","occurrence","uniqueOccurrence","deepEqual","Checkbox","CheckboxPrimitive","getLinesFromUSFM","text","getNumberFromUSFM","regex","match","getBookNumFromId","getStatusForItem","item","approvedItems","unapprovedItems","toggleVariants","Toggle","TogglePrimitive","ToggleGroupContext","ToggleGroup","ToggleGroupPrimitive","ToggleGroupItem","context","getSortingIcon","sortDirection","ArrowUpIcon","ArrowDownIcon","ArrowUpDownIcon","inventoryItemColumn","itemLabel","inventoryAdditionalItemColumn","additionalItemLabel","additionalItemIndex","inventoryCountColumn","countLabel","statusChangeHandler","changedItems","newStatus","onApprovedItemsChange","onUnapprovedItemsChange","newApprovedItems","validItem","newUnapprovedItems","unapprovedItem","inventoryStatusColumn","statusLabel","status","CircleCheckIcon","CircleXIcon","CircleHelpIcon","INVENTORY_STRING_KEYS","filterItemData","itemData","statusFilter","textFilter","filteredItemData","createTableData","scriptureRef","itemRegex","tableData","currentBook","currentChapter","currentVerse","line","items","itemIndex","existingItem","tableEntry","newReference","substring","newItem","Inventory","scriptureReference","extractItems","additionalItemsLabels","scope","onScopeChange","allItemsText","approvedItemsText","unapprovedItemsText","unknownItemsText","scopeBookText","scopeChapterText","scopeVerseText","filterText","showAdditionalItemsText","showAdditionalItems","setShowAdditionalItems","setStatusFilter","setTextFilter","selectedItem","setSelectedItem","reducedTableData","newTableData","firstItem","existingEntry","newTableEntry","filteredTableData","allColumns","numberOfAdditionalItems","additionalColumns","_b","rowClickHandler","newSelection","handleScopeChange","handleStatusFilterChange","SearchBar","onSearch","placeholder","isFullWidth","handleInputChange","VerticalTabs","TabsPrimitive","VerticalTabsList","VerticalTabsTrigger","VerticalTabsContent","TabNavigationContentSearch","tabList","searchPlaceholder","headerTitle","isSearchBarFullWidth","direction","tab","Separator","orientation","decorative","SeparatorPrimitive","Sheet","SheetPrimitive","SheetPortal","SheetOverlay","sheetVariants","SheetContent","side","SheetTitle","SheetDescription","Skeleton","TooltipProvider","TooltipPrimitive","Tooltip","TooltipTrigger","TooltipContent","MOBILE_BREAKPOINT","useIsMobile","isMobile","setIsMobile","mql","SIDEBAR_COOKIE_NAME","SIDEBAR_COOKIE_MAX_AGE","SIDEBAR_WIDTH","SIDEBAR_WIDTH_MOBILE","SIDEBAR_WIDTH_ICON","SIDEBAR_KEYBOARD_SHORTCUT","SidebarContext","useSidebar","SidebarProvider","defaultOpen","openProp","setOpenProp","style","openMobile","setOpenMobile","_open","_setOpen","isOpen","openState","toggleSidebar","state","contextValue","Sidebar","collapsible","SidebarTrigger","onClick","PanelLeft","SidebarRail","SidebarInset","SidebarInput","SidebarHeader","SidebarFooter","SidebarSeparator","SidebarContent","SidebarGroup","SidebarGroupLabel","SidebarGroupAction","SidebarGroupContent","SidebarMenu","SidebarMenuItem","sidebarMenuButtonVariants","SidebarMenuButton","isActive","tooltip","button","SidebarMenuAction","showOnHover","SidebarMenuBadge","SidebarMenuSkeleton","showIcon","width","SidebarMenuSub","SidebarMenuSubItem","SidebarMenuSubButton","SettingsSidebar","extensionLabels","projectOptions","handleSelectSidebarItem","selectedSidebarItem","handleSelectItem","projectId","getProjectNameFromProjectId","project","label","selectedProjectName","SettingsSidebarContentSearch","scrBookColId","scrRefColId","typeColId","detailsColId","defaultScrRefColumnName","defaultScrBookGroupName","defaultTypeColumnName","defaultDetailsColumnName","getColumns","colInfo","showSourceColumn","showSrcCol","info","formatScrRef","compareScrRefs","toRefOrRange","scriptureSelection","offsetStart","offsetEnd","scrRefToBBBCCCVVV","getRowKey","ScriptureResultsViewer","sources","showColumnHeaders","scriptureReferenceColumnName","scriptureBookGroupName","typeColumnName","detailsColumnName","onRowSelected","grouping","setGrouping","scriptureResults","source","getExpandedRowModel","getGroupedRowModel","selectedRows","keys","selectedRow","scrBookGroupName","typeGroupName","groupingOptions","handleSelectChange","selectedGrouping","handleRowClick","getEvenOrOddBandingStyle","getIndent","groupingState","rowIndex","ChevronLeft","DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS","getLocalizeKeyForScrollGroupId","ScrollGroupSelector","availableScrollGroupIds","scrollGroupId","onChangeScrollGroupId","localizedStringsDefaulted","localizedStringKey","localizedStringValue","newScrollGroupString","scrollGroupOptionId","SettingsList","SettingsListItem","primary","secondary","isLoading","loadingMessage","SettingsListHeader","includeSeparator","Card","CardHeader","CardTitle","CardDescription","CardContent","CardFooter","SettingsCard","settingsGroupLabel","settingsGroupDescription","Checklist","listItems","selectedListItems","handleSelectListItem","createLabel","_interopRequireDefault","obj","module","chainPropTypes","propType1","propType2","args","_extends","target","isPlainObject","prototype","deepClone","output","deepmerge","r","z","reactIs_production_min","hasSymbol","REACT_ELEMENT_TYPE","REACT_PORTAL_TYPE","REACT_FRAGMENT_TYPE","REACT_STRICT_MODE_TYPE","REACT_PROFILER_TYPE","REACT_PROVIDER_TYPE","REACT_CONTEXT_TYPE","REACT_ASYNC_MODE_TYPE","REACT_CONCURRENT_MODE_TYPE","REACT_FORWARD_REF_TYPE","REACT_SUSPENSE_TYPE","REACT_SUSPENSE_LIST_TYPE","REACT_MEMO_TYPE","REACT_LAZY_TYPE","REACT_BLOCK_TYPE","REACT_FUNDAMENTAL_TYPE","REACT_RESPONDER_TYPE","REACT_SCOPE_TYPE","isValidElementType","typeOf","object","$$typeof","$$typeofType","AsyncMode","ConcurrentMode","ContextConsumer","ContextProvider","Element","ForwardRef","Lazy","Memo","Portal","Profiler","StrictMode","Suspense","hasWarnedAboutDeprecatedIsAsyncMode","isAsyncMode","isConcurrentMode","isContextConsumer","isContextProvider","isElement","isForwardRef","isFragment","isLazy","isMemo","isPortal","isProfiler","isStrictMode","isSuspense","reactIs_development","reactIsModule","require$$0","require$$1","getOwnPropertySymbols","hasOwnProperty","propIsEnumerable","toObject","val","shouldUseNative","test1","test2","order2","test3","letter","objectAssign","from","to","symbols","ReactPropTypesSecret","ReactPropTypesSecret_1","has","printWarning","loggedTypeFailures","message","checkPropTypes","typeSpecs","values","location","componentName","getStack","typeSpecName","error","err","ex","stack","checkPropTypes_1","ReactIs","assign","require$$2","require$$3","require$$4","emptyFunctionThatReturnsNull","factoryWithTypeCheckers","isValidElement","throwOnDirectAccess","ITERATOR_SYMBOL","FAUX_ITERATOR_SYMBOL","getIteratorFn","maybeIterable","iteratorFn","ANONYMOUS","ReactPropTypes","createPrimitiveTypeChecker","createAnyTypeChecker","createArrayOfTypeChecker","createElementTypeChecker","createElementTypeTypeChecker","createInstanceTypeChecker","createNodeChecker","createObjectOfTypeChecker","createEnumTypeChecker","createUnionTypeChecker","createShapeTypeChecker","createStrictShapeTypeChecker","is","PropTypeError","createChainableTypeChecker","validate","manualPropTypeCallCache","manualPropTypeWarningCount","checkType","isRequired","propName","propFullName","secret","cacheKey","chainedCheckType","expectedType","propValue","propType","getPropType","preciseType","getPreciseType","typeChecker","expectedClass","expectedClassName","actualClassName","getClassName","expectedValues","valuesString","arrayOfTypeCheckers","checker","getPostfixForTypeWarning","expectedTypes","checkerResult","expectedTypesMessage","isNode","invalidValidatorError","shapeTypes","allKeys","iterator","step","entry","isSymbol","emptyFunction","emptyFunctionWithReset","factoryWithThrowingShims","shim","getShim","propTypesModule","isClassComponent","elementType","acceptingRef","safePropName","warningHint","elementAcceptingRef","PropTypes","elementAcceptingRef$1","specialProperty","exactProp","propTypes","unsupportedProps","prop","formatMuiErrorMessage","code","url","REACT_SERVER_CONTEXT_TYPE","REACT_OFFSCREEN_TYPE","enableScopeAPI","enableCacheElement","enableTransitionTracing","enableLegacyHidden","enableDebugTracing","REACT_MODULE_REFERENCE","SuspenseList","hasWarnedAboutDeprecatedIsConcurrentMode","isSuspenseList","fnNameMatchRegex","getFunctionName","fn","getFunctionComponentName","Component","fallback","getWrappedName","outerType","innerType","wrapperName","functionName","getDisplayName","HTMLElementType","refType","refType$1","capitalize","string","_formatMuiErrorMessage","createChainedFunction","funcs","acc","func","debounce","wait","timeout","debounced","later","deprecatedPropType","validator","reason","componentNameSafe","propFullNameSafe","isMuiElement","muiNames","_muiName","_element$type","ownerDocument","node","ownerWindow","requirePropFactory","componentNameInError","prevPropTypes","requiredProp","defaultTypeChecker","typeCheckerResult","setRef","useEnhancedEffect","useEnhancedEffect$1","globalId","useGlobalId","idOverride","defaultId","setDefaultId","maybeReactUseId","useId","reactId","unsupportedProp","useControlled","controlled","defaultProp","name","isControlled","valueState","setValue","defaultValue","setValueIfUncontrolled","newValue","useEventCallback","useForkRef","refs","instance","UNINITIALIZED","useLazyRef","init","initArg","EMPTY","useOnMount","Timeout","delay","useTimeout","hadKeyboardEvent","hadFocusVisibleRecently","hadFocusVisibleRecentlyTimeout","inputTypesWhitelist","focusTriggersKeyboardModality","tagName","handlePointerDown","handleVisibilityChange","prepare","doc","isFocusVisible","useIsFocusVisible","isFocusVisibleRef","handleBlurVisible","handleFocusVisible","resolveProps","defaultProps","defaultSlotProps","slotProps","slotPropName","composeClasses","slots","getUtilityClass","classes","slot","utilityClass","defaultGenerator","createClassNameGenerator","generate","generator","ClassNameGenerator","ClassNameGenerator$1","globalStateClasses","generateUtilityClass","globalStatePrefix","globalStateClass","generateUtilityClasses","result","clamp","min","max","_objectWithoutPropertiesLoose","excluded","sourceKeys","_excluded","sortBreakpointsValues","breakpointsAsArray","breakpoint1","breakpoint2","createBreakpoints","breakpoints","unit","other","sortedValues","up","down","between","start","end","endIndex","only","not","keyIndex","shape","shape$1","responsivePropType","responsivePropType$1","merge","defaultBreakpoints","handleBreakpoints","styleFromPropValue","theme","themeBreakpoints","breakpoint","mediaKey","cssKey","createEmptyBreakpointObject","breakpointsInput","_breakpointsInput$key","breakpointStyleKey","removeUnusedBreakpoints","breakpointKeys","breakpointOutput","getPath","path","checkVars","getStyleValue","themeMapping","transform","propValueFinal","userValue","cssProperty","themeKey","memoize","cache","arg","properties","directions","aliases","getCssProperties","property","marginKeys","paddingKeys","spacingKeys","createUnaryUnit","_getPath","themeSpacing","abs","createUnarySpacing","getValue","transformer","transformed","getStyleFromPropValue","cssProperties","resolveCssProperty","margin","padding","createSpacing","spacingInput","spacing","argsInput","argument","compose","styles","handlers","borderTransform","createBorderStyle","border","borderTop","borderRight","borderBottom","borderLeft","borderColor","borderTopColor","borderRightColor","borderBottomColor","borderLeftColor","outline","outlineColor","borderRadius","gap","columnGap","rowGap","gridColumn","gridRow","gridAutoFlow","gridAutoColumns","gridAutoRows","gridTemplateColumns","gridTemplateRows","gridTemplateAreas","gridArea","paletteTransform","color","bgcolor","backgroundColor","sizingTransform","maxWidth","_props$theme","_props$theme2","breakpointsValues","minWidth","height","maxHeight","minHeight","boxSizing","defaultSxConfig","defaultSxConfig$1","objectsHaveSameKeys","objects","union","callIfFn","maybeFn","unstable_createStyleFunctionSx","getThemeValue","config","styleFunctionSx","_theme$unstable_sxCon","sx","traverse","sxInput","sxObject","emptyBreakpoints","breakpointsKeys","css","styleKey","styleFunctionSx$1","applyStyles","createTheme","paletteInput","shapeInput","muiTheme","isObjectEmpty","useTheme","defaultTheme","contextTheme","ThemeContext","systemDefaultTheme","useThemeWithoutDefault","_excluded2","_excluded3","isEmpty","isStringTag","tag","shouldForwardProp","lowercaseFirstLetter","resolveTheme","themeId","defaultOverridesResolver","processStyleArg","callableStyle","_ref","ownerState","resolvedStylesArg","resolvedStyle","variants","isMatch","createStyled","input","rootShouldForwardProp","slotShouldForwardProp","systemSx","inputOptions","processStyles","componentSlot","inputSkipVariantsResolver","inputSkipSx","overridesResolver","skipVariantsResolver","skipSx","shouldForwardPropOption","defaultStyledResolver","styledEngineStyled","transformStyleArg","stylesArg","muiStyledResolver","styleArg","expressions","transformedStyleArg","expressionsWithDefaultTheme","styleOverrides","resolvedStyleOverrides","slotKey","slotStyle","_theme$components","themeVariants","numOfCustomFnsApplied","placeholders","displayName","getThemeProps","params","useThemeProps","clampWrapper","hexToRgb","re","colors","decomposeColor","marker","colorSpace","recomposeColor","hslToRgb","rgb","getLuminance","getContrastRatio","foreground","background","lumA","lumB","alpha","darken","coefficient","lighten","createMixins","mixins","common","common$1","grey","grey$1","purple","purple$1","red","red$1","orange","orange$1","blue","blue$1","lightBlue","lightBlue$1","green","green$1","light","dark","addLightOrDark","intent","shade","tonalOffset","tonalOffsetLight","tonalOffsetDark","getDefaultPrimary","mode","getDefaultSecondary","getDefaultError","getDefaultInfo","getDefaultSuccess","getDefaultWarning","createPalette","palette","contrastThreshold","success","warning","getContrastText","contrastText","contrast","augmentColor","mainShade","lightShade","darkShade","modes","round","caseAllCaps","defaultFontFamily","createTypography","typography","fontFamily","fontSize","fontWeightLight","fontWeightRegular","fontWeightMedium","fontWeightBold","htmlFontSize","allVariants","pxToRem2","coef","pxToRem","buildVariant","fontWeight","lineHeight","letterSpacing","casing","shadowKeyUmbraOpacity","shadowKeyPenumbraOpacity","shadowAmbientShadowOpacity","createShadow","px","shadows","shadows$1","easing","duration","formatMs","milliseconds","getAutoHeightDuration","constant","createTransitions","inputTransitions","mergedEasing","mergedDuration","durationOption","easingOption","isString","isNumber","animatedProp","zIndex","zIndex$1","mixinsInput","transitionsInput","typographyInput","systemTheme","systemCreateTheme","stateClasses","component","child","stateClass","defaultTheme$1","THEME_ID","systemUseThemeProps","styled","styled$1","getSvgIconUtilityClass","useUtilityClasses","SvgIconRoot","_theme$transitions","_theme$transitions$cr","_theme$transitions2","_theme$typography","_theme$typography$pxT","_theme$typography2","_theme$typography2$px","_theme$typography3","_theme$typography3$px","_palette$ownerState$c","_palette","_palette2","_palette3","SvgIcon","inProps","htmlColor","inheritViewBox","titleAccess","viewBox","hasSvgAsChild","more","_jsxs","_jsx","SvgIcon$1","createSvgIcon","unstable_ClassNameGenerator","exports","_utils","ArrowRight","default_1","_createSvgIcon","_jsxRuntime","isHostComponent","appendOwnerState","otherProps","defaultContextValue","ClassNameConfiguratorContext","useClassNamesOverride","disableDefaultClasses","extractEventHandlers","excludeKeys","resolveComponentProps","componentProps","slotState","omitEventHandlers","mergeSlotProps","parameters","getSlotProps","additionalProps","externalSlotProps","externalForwardedProps","joinedClasses","mergedStyle","eventHandlers","componentsPropsWithoutEventHandlers","otherPropsWithoutEventHandlers","internalSlotProps","useSlotProps","_parameters$additiona","skipResolvingSlotProps","rest","resolvedComponentsProps","mergedProps","internalRef","GLOBAL_CLASS_PREFIX","buildStateClass","buildSlotClass","getContainer","container","forwardedRef","disablePortal","mountNode","setMountNode","handleRef","newProps","ReactDOM","top","bottom","right","left","auto","basePlacements","clippingParents","viewport","popper","reference","variationPlacements","placement","placements","beforeRead","read","afterRead","beforeMain","main","afterMain","beforeWrite","write","afterWrite","modifierPhases","getNodeName","getWindow","OwnElement","isHTMLElement","isShadowRoot","attributes","effect","_ref2","initialStyles","styleProperties","attribute","applyStyles$1","getBasePlacement","getUAString","uaData","isLayoutViewport","getBoundingClientRect","includeScale","isFixedStrategy","clientRect","scaleX","scaleY","visualViewport","addVisualOffsets","getLayoutRect","contains","parent","rootNode","next","getComputedStyle","isTableElement","getDocumentElement","getParentNode","getTrueOffsetParent","getContainingBlock","isFirefox","isIE","elementCss","currentNode","getOffsetParent","window","offsetParent","getMainAxisFromPlacement","within","mathMax","mathMin","withinMaxClamp","getFreshSideObject","mergePaddingObject","paddingObject","expandToHashMap","hashMap","toPaddingObject","arrow","_state$modifiersData$","arrowElement","popperOffsets","basePlacement","axis","isVertical","len","arrowRect","minProp","maxProp","endDiff","startDiff","arrowOffsetParent","clientSize","centerToReference","center","offset","axisProp","_options$element","arrow$1","getVariation","unsetSides","roundOffsetsByDPR","win","dpr","mapToStyles","_Object$assign2","popperRect","variation","offsets","gpuAcceleration","adaptive","roundOffsets","isFixed","_offsets$x","_offsets$y","_ref3","hasX","hasY","sideX","sideY","heightProp","widthProp","offsetY","offsetX","commonStyles","_ref4","_Object$assign","computeStyles","_ref5","_options$gpuAccelerat","_options$adaptive","_options$roundOffsets","computeStyles$1","passive","_options$scroll","scroll","_options$resize","resize","scrollParents","scrollParent","eventListeners","hash","getOppositePlacement","matched","getOppositeVariationPlacement","getWindowScroll","scrollLeft","scrollTop","getWindowScrollBarX","getViewportRect","strategy","html","layoutViewport","getDocumentRect","_element$ownerDocumen","winScroll","body","isScrollParent","_getComputedStyle","overflow","overflowX","overflowY","getScrollParent","listScrollParents","list","isBody","updatedList","rectToClientRect","rect","getInnerBoundingClientRect","getClientRectFromMixedType","clippingParent","getClippingParents","canEscapeClipping","clipperElement","getClippingRect","boundary","rootBoundary","mainClippingParents","firstClippingParent","clippingRect","accRect","computeOffsets","commonX","commonY","mainAxis","detectOverflow","_options","_options$placement","_options$strategy","_options$boundary","_options$rootBoundary","_options$elementConte","elementContext","_options$altBoundary","altBoundary","_options$padding","altContext","clippingClientRect","referenceClientRect","popperClientRect","elementClientRect","overflowOffsets","offsetData","multiply","computeAutoPlacement","flipVariations","_options$allowedAutoP","allowedAutoPlacements","allPlacements","allowedPlacements","overflows","getExpandedFallbackPlacements","oppositePlacement","flip","_options$mainAxis","checkMainAxis","_options$altAxis","checkAltAxis","specifiedFallbackPlacements","_options$flipVariatio","preferredPlacement","isBasePlacement","fallbackPlacements","referenceRect","checksMap","makeFallbackChecks","firstFittingPlacement","_basePlacement","isStartVariation","mainVariationSide","altVariationSide","checks","check","numberOfChecks","_loop","_i","fittingPlacement","_ret","flip$1","getSideOffsets","preventedOffsets","isAnySideFullyClipped","hide","referenceOverflow","popperAltOverflow","referenceClippingOffsets","popperEscapeOffsets","isReferenceHidden","hasPopperEscaped","hide$1","distanceAndSkiddingToXY","rects","invertDistance","skidding","distance","_options$offset","_data$state$placement","offset$1","popperOffsets$1","getAltAxis","preventOverflow","_options$tether","tether","_options$tetherOffset","tetherOffset","altAxis","tetherOffsetValue","normalizedTetherOffsetValue","offsetModifierState","_offsetModifierState$","mainSide","altSide","additive","minLen","maxLen","arrowPaddingObject","arrowPaddingMin","arrowPaddingMax","arrowLen","minOffset","maxOffset","clientOffset","offsetModifierValue","tetherMin","tetherMax","preventedOffset","_offsetModifierState$2","_mainSide","_altSide","_offset","_len","_min","_max","isOriginSide","_offsetModifierValue","_tetherMin","_tetherMax","_preventedOffset","preventOverflow$1","getHTMLElementScroll","getNodeScroll","isElementScaled","getCompositeRect","elementOrVirtualElement","isOffsetParentAnElement","offsetParentIsScaled","documentElement","order","modifiers","map","visited","modifier","sort","requires","dep","depModifier","orderModifiers","orderedModifiers","phase","pending","resolve","mergeByName","merged","current","existing","DEFAULT_OPTIONS","areValidElements","_key","popperGenerator","generatorOptions","_generatorOptions","_generatorOptions$def","defaultModifiers","_generatorOptions$def2","defaultOptions","effectCleanupFns","isDestroyed","setOptionsAction","cleanupModifierEffects","runModifierEffects","_state$elements","_state$orderedModifie","_state$orderedModifie2","_ref$options","cleanupFn","noopFn","createPopper","COMPONENT_NAME","getPopperUtilityClass","flipPlacement","resolveAnchorEl","anchorEl","isVirtualElement","defaultPopperOptions","PopperTooltip","_slots$root","initialPlacement","popperOptions","popperRefProp","TransitionProps","tooltipRef","ownRef","popperRef","handlePopperRef","handlePopperRefRef","rtlPlacement","setPlacement","resolvedAnchorElement","setResolvedAnchorElement","handlePopperUpdate","box","popperModifiers","childProps","Root","rootProps","Popper","containerProp","keepMounted","transition","exited","setExited","handleEnter","handleExited","resolvedAnchorEl","display","transitionProps","useThemeSystem","_setPrototypeOf","_inheritsLoose","subClass","superClass","setPrototypeOf","timeoutsShape","TransitionGroupContext","forceReflow","UNMOUNTED","EXITED","ENTERING","ENTERED","EXITING","Transition","_React$Component","_this","parentGroup","appear","initialStatus","prevState","nextIn","_proto","prevProps","nextStatus","exit","enter","mounting","_this2","appearing","maybeNode","maybeAppearing","timeouts","enterTimeout","_this3","nextState","callback","_this4","active","handler","doesNotHaveTimeoutOrListener","maybeNextCallback","_this$props","pt","noop","Transition$1","reflow","getTransitionProps","_style$transitionDura","_style$transitionTimi","getScale","isWebKit154","Grow","addEndListener","inProp","onEnter","onEntered","onEntering","onExit","onExited","onExiting","TransitionComponent","timer","autoTimeout","nodeRef","normalizedTransitionCallback","maybeIsAppearing","handleEntering","isAppearing","transitionDuration","transitionTimingFunction","handleEntered","handleExiting","handleExit","handleAddEndListener","Grow$1","PopperRoot","BasePopper","components","componentsProps","RootComponent","Popper$1","getTooltipUtilityClass","tooltipClasses","tooltipClasses$1","disableInteractive","touch","TooltipPopper","TooltipTooltip","TooltipArrow","hystersisOpen","hystersisTimer","cursorPosition","composeEventHandler","eventHandler","_slots$popper","_slots$transition","_slots$tooltip","_slots$arrow","_slotProps$popper","_ref6","_slotProps$popper2","_slotProps$transition","_slotProps$tooltip","_ref7","_slotProps$tooltip2","_slotProps$arrow","_ref8","_slotProps$arrow2","childrenProp","describeChild","disableFocusListener","disableHoverListener","disableInteractiveProp","disableTouchListener","enterDelay","enterNextDelay","enterTouchDelay","followCursor","idProp","leaveDelay","leaveTouchDelay","onClose","onOpen","PopperComponentProp","PopperProps","title","TransitionComponentProp","isRtl","childNode","setChildNode","arrowRef","setArrowRef","ignoreNonTouchEvents","closeTimer","enterTimer","leaveTimer","touchTimer","setOpenState","prevUserSelect","stopTouchInteraction","handleOpen","handleClose","handleLeave","focusVisibleRef","setChildIsFocusVisible","handleBlur","handleFocus","detectTouchStart","childrenProps","handleMouseOver","handleMouseLeave","handleTouchStart","handleTouchEnd","nativeEvent","handleMouseMove","nameOrDescProps","titleIsString","interactiveWrapperListeners","_PopperProps$popperOp","tooltipModifiers","PopperComponent","TooltipComponent","ArrowComponent","popperProps","tooltipProps","tooltipArrowProps","TransitionPropsInner","Tooltip$1","getIcon","icon","menuLabel","leading","MuiListItemIcon","MenuItem","allowForLeadingIcons","iconPathBefore","iconPathAfter","hasAutoFocus","isDense","isSubMenuParent","hasDisabledGutters","hasDivider","focusVisibleClassName","menuItem","MuiMenuItem","MuiListItemText","getAllGroups","menuDefinition","SubMenu","setAnchorEl","parentMenuItem","parentItemProps","handleParentMenuItemClick","renderSubMenuItems","includedGroups","group","GroupedMenuItemList","Menu","getOrderedGroupItems","groupId","allItems","menuProps","commandHandler","groupsToInclude","sortedGroups","itemArray","allowSpaceForLeadingIcons","createMenuItemProps","isLastItemInGroup","divKey","itemInfo","menuItemProps","TopLevelMenu","columnId","MenuColumn","metadata","Grid","List","GridMenu","multiColumnMenu","sortedColumns","columnNumbers","columnName","col","getUsePromiseOptionsDefaults","usePromise","promiseFactoryCallback","defaultValueRef","optionsDefaultedRef","setIsLoading","promiseIsCurrent","MenuIcon","HamburgerMenuButton","menuProvider","normalMenu","fullMenu","containerRef","ariaLabelPrefix","isMenuOpen","setMenuOpen","showFullMenu","setShowFullMenu","handleMenuItemClick","handleMenuButtonClick","prevIsOpen","isOpening","menuCommandHandler","command","setOffset","normalMenuData","fullMenuData","menu","IconButton","Drawer","isTooltipSuppressed","adjustMarginToAlignToEdge","MuiIconButton","Spinner","LoaderCircle","TextField","hasError","helperText","onFocus","onBlur","ShadLabel","Toolbar","AppBar","MuiToolbar","alertVariants","Alert","AlertTitle","AlertDescription","Sonner","Toaster","Slider","SliderPrimitive","Switch","SwitchPrimitives","Tabs","TabsList","TabsTrigger","TabsContent","InstallButton","isInstalling","handleClick","buttonText","Download","EnableButton","isEnabling","DisableButton","isDisabling","UpdateButton","isUpdating","MarkdownRenderer","markdown","anchorTarget","Markdown","FilterButton","Filter","DropdownMenuItemType","DropdownMenuItemType2","FilterDropdown","groups","NoExtensionsFound","MoreInfo","category","downloads","languages","moreInfoUrl","numberFormatted","NumberFormat","handleScrollToBottom","User","locale","LucideLink","CircleHelp","VersionHistory","versionHistory","showAllVersions","setShowAllVersions","currentDate","formatTimeString","dateString","date","dateDiff","yearDiff","monthDiff","dayDiff","timeString","sortedEntries","Footer","publisherDisplayName","fileSize","locales","formattedFileSize","formatBytes","languageNames","codes","displayNames","useEvent","unsubscriber","noopUnsubscriber","useEventAsync","unsubscribe","unsub"],"mappings":"28CAGA,MAAMA,GAAgBC,GAAAA,oBAAoB,CAAE,OAAQ,KAAO,CAAA,EAyDpD,SAASC,KAAMC,EAAsB,CACnC,OAAAH,GAAcI,GAAAA,KAAKD,CAAM,CAAC,CACnC,CCzDO,MAAME,GAAQC,EAAM,WACzB,CAAC,CAAE,UAAAC,EAAW,KAAAC,EAAM,GAAGC,CAAA,EAASC,IAE5BC,EAAA,IAAC,QAAA,CACC,KAAAH,EACA,UAAWN,EACT,sbACAK,CACF,EACA,IAAAG,EAEC,GAAGD,CAAA,CAAA,CAIZ,EACAJ,GAAM,YAAc,QCNpB,MAAMO,GAAmBC,EAAA,WACvB,CACE,CAAE,aAAAC,EAAc,cAAAC,EAAe,cAAAC,EAAe,aAAAC,EAAc,GAAGR,CAAM,EACrEC,IAGEQ,EAAA,KAAC,MAAI,CAAA,UAAU,cACb,SAAA,CAAAP,EAAA,IAACQ,GAAA,CACE,GAAGV,EACJ,KAAK,OACL,UAAU,0JACV,SAAWW,GAAUN,EAAaM,EAAM,OAAO,KAAK,EACpD,UAAYC,GAAM,CACZA,EAAE,MAAQ,SACCJ,IAEfF,EAAcM,CAAC,CACjB,EACA,QAASL,EACT,IAAAN,CAAA,CACF,EACAC,EAAA,IAACW,EAAA,QAAA,CACC,UAAU,8HACV,QAAS,IAAM,CAEb,QAAQ,IAAI,iBAAiB,CAC/B,CAAA,CACF,CACF,CAAA,CAAA,CAGN,EC9CA,IAAIC,GAAI,OAAO,eACXC,GAAI,CAACC,EAAGJ,EAAGK,IAAML,KAAKI,EAAIF,GAAEE,EAAGJ,EAAG,CAAE,WAAY,GAAI,aAAc,GAAI,SAAU,GAAI,MAAOK,CAAC,CAAE,EAAID,EAAEJ,CAAC,EAAIK,EACzGC,GAAI,CAACF,EAAGJ,EAAGK,IAAMF,GAAEC,EAAG,OAAOJ,GAAK,SAAWA,EAAI,GAAKA,EAAGK,CAAC,EAW9D,MAAME,GAAI,CACR,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MAEA,MAEA,MAEA,MAEA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,MAEA,MAEA,MAEA,MAEA,MACA,MACA,MACA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,KACF,EAAGC,GAAI,CACL,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,KACF,EAAGC,GAAI,CACL,UACA,SACA,YACA,UACA,cACA,SACA,SACA,OACA,WACA,WACA,UACA,UACA,eACA,eACA,OACA,WACA,kBACA,MACA,SACA,WACA,eACA,gBACA,SACA,WACA,eACA,UACA,kBACA,QACA,OACA,OACA,UACA,QACA,QACA,QACA,WACA,YACA,SACA,YACA,UACA,UACA,OACA,OACA,OACA,OACA,SACA,gBACA,gBACA,YACA,YACA,cACA,aACA,kBACA,kBACA,YACA,YACA,QACA,WACA,UACA,QACA,UACA,UACA,SACA,SACA,SACA,OACA,aACA,QACA,SACA,eACA,oBACA,0BACA,SACA,qBACA,sBACA,UACA,qBACA,cACA,cACA,cACA,cACA,mBACA,mBACA,qBACA,YACA,OACA,oBAGA,uBACA,uBACA,sBACA,yBACA,wBACA,qBACA,UACA,UACA,UACA,UACA,UACA,UACA,UACA,eACA,cACA,eACA,oBACA,qBACA,0BACA,0BACA,eACA,eACA,YACA,gBACA,cACA,eACA,iBACA,wBACA,mBACA,WACA,QACA,aACA,aACA,aACA,2BACA,4BACA,YACF,EAAGC,GAAIC,KACP,SAASC,GAAER,EAAGJ,EAAI,GAAI,CACpB,OAAOA,IAAMI,EAAIA,EAAE,YAAa,GAAGA,KAAKM,GAAIA,GAAEN,CAAC,EAAI,CACrD,CACA,SAASS,GAAET,EAAG,CACZ,OAAOQ,GAAER,CAAC,EAAI,CAChB,CACA,SAASU,GAAEV,EAAG,CACZ,MAAMJ,EAAI,OAAOI,GAAK,SAAWQ,GAAER,CAAC,EAAIA,EACxC,OAAOJ,GAAK,IAAMA,GAAK,EACzB,CACA,SAASe,GAAEX,EAAG,CACZ,OAAQ,OAAOA,GAAK,SAAWQ,GAAER,CAAC,EAAIA,IAAM,EAC9C,CACA,SAASY,GAAEZ,EAAG,CACZ,OAAOA,GAAK,EACd,CACA,SAASa,GAAEb,EAAG,CACZ,MAAMJ,EAAI,OAAOI,GAAK,SAAWQ,GAAER,CAAC,EAAIA,EACxC,OAAOc,GAAElB,CAAC,GAAK,CAACgB,GAAEhB,CAAC,CACrB,CACA,SAAUmB,IAAI,CACZ,QAASf,EAAI,EAAGA,GAAKG,GAAE,OAAQH,IAAK,MAAMA,CAC5C,CACA,MAA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;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","x_google_ignoreList":[3,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,83,84,85,86,87,88,89,90,91,92,93,94,95,96,97,98,99,100,101,102,103,104,105,106,107,108,109,110,111,112,113,114,115,116,117,118,119,120,121,122,123,124,125,126,127,128,129,130,131,132,133,134,135,136,137,138,139,140,141,142,143,144,145,146,147,148,149,150,151,152,153,154,155,156,157,158,159,160,161,162,163,164,165,166,167,168,169,170,171,172,173,174,175,176,177,178,179,180,181,182,183,184,185,186,187,188,189,190,191,192,193,194,195,196,197,198,199,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,230]} \ No newline at end of file +{"version":3,"file":"index.cjs","sources":["../src/utils/shadcn-ui.util.ts","../src/components/shadcn-ui/input.tsx","../src/components/advanced/book-chapter-control/book-chapter-input.component.tsx","../../../node_modules/@sillsdev/scripture/dist/index.es.js","../src/components/shadcn-ui/dropdown-menu.tsx","../src/components/advanced/book-chapter-control/book-menu-item.component.tsx","../src/components/advanced/book-chapter-control/chapter-select.component.tsx","../src/components/advanced/book-chapter-control/go-to-menu-item.component.tsx","../src/components/advanced/book-chapter-control/book-chapter-control.component.tsx","../src/components/shadcn-ui/button.tsx","../src/components/shadcn-ui/label.tsx","../src/components/shadcn-ui/radio-group.tsx","../src/components/shadcn-ui/popover.tsx","../src/components/shadcn-ui/dialog.tsx","../src/components/shadcn-ui/command.tsx","../src/components/basics/combo-box.component.tsx","../src/components/basics/chapter-range-selector.component.tsx","../src/components/advanced/book-selector.component.tsx","../src/components/advanced/data-table/data-table-column-toggle.component.tsx","../src/components/shadcn-ui/select.tsx","../src/components/advanced/data-table/data-table-pagination.component.tsx","../src/components/shadcn-ui/table.tsx","../src/components/advanced/data-table/data-table.component.tsx","../src/components/advanced/inventory/occurrences-table.component.tsx","../src/components/shadcn-ui/checkbox.tsx","../src/components/advanced/inventory/inventory-utils.ts","../src/components/shadcn-ui/toggle.tsx","../src/components/shadcn-ui/toggle-group.tsx","../src/components/advanced/inventory/inventory-columns.tsx","../src/components/advanced/inventory/inventory.component.tsx","../src/components/basics/search-bar.component.tsx","../src/components/basics/tabs-vertical.tsx","../src/components/advanced/tab-navigation-content-search.component.tsx","../src/components/shadcn-ui/separator.tsx","../src/components/shadcn-ui/sheet.tsx","../src/components/shadcn-ui/skeleton.tsx","../src/components/shadcn-ui/tooltip.tsx","../src/components/hooks/use-mobile.tsx","../src/components/shadcn-ui/sidebar.tsx","../src/components/advanced/settings-components/settings-sidebar.component.tsx","../src/components/advanced/settings-components/settings-sidebar-content-search.component.tsx","../src/components/advanced/scripture-results-viewer/scripture-results-viewer.component.tsx","../src/components/advanced/scroll-group-selector.component.tsx","../src/components/advanced/settings-components/settings-list.component.tsx","../src/components/shadcn-ui/card.tsx","../src/components/advanced/settings-components/settings-card.component.tsx","../src/components/basics/checklist.component.tsx","../../../node_modules/@babel/runtime/helpers/interopRequireDefault.js","../../../node_modules/@mui/utils/chainPropTypes/chainPropTypes.js","../../../node_modules/@babel/runtime/helpers/esm/extends.js","../../../node_modules/@mui/utils/deepmerge/deepmerge.js","../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.production.min.js","../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.development.js","../../../node_modules/prop-types/node_modules/react-is/index.js","../../../node_modules/object-assign/index.js","../../../node_modules/prop-types/lib/ReactPropTypesSecret.js","../../../node_modules/prop-types/lib/has.js","../../../node_modules/prop-types/checkPropTypes.js","../../../node_modules/prop-types/factoryWithTypeCheckers.js","../../../node_modules/prop-types/factoryWithThrowingShims.js","../../../node_modules/prop-types/index.js","../../../node_modules/@mui/utils/elementAcceptingRef/elementAcceptingRef.js","../../../node_modules/@mui/utils/exactProp/exactProp.js","../../../node_modules/@mui/utils/formatMuiErrorMessage/formatMuiErrorMessage.js","../../../node_modules/react-is/cjs/react-is.production.min.js","../../../node_modules/react-is/cjs/react-is.development.js","../../../node_modules/react-is/index.js","../../../node_modules/@mui/utils/getDisplayName/getDisplayName.js","../../../node_modules/@mui/utils/HTMLElementType/HTMLElementType.js","../../../node_modules/@mui/utils/refType/refType.js","../../../node_modules/@mui/utils/capitalize/capitalize.js","../../../node_modules/@mui/utils/createChainedFunction/createChainedFunction.js","../../../node_modules/@mui/utils/debounce/debounce.js","../../../node_modules/@mui/utils/deprecatedPropType/deprecatedPropType.js","../../../node_modules/@mui/utils/isMuiElement/isMuiElement.js","../../../node_modules/@mui/utils/ownerDocument/ownerDocument.js","../../../node_modules/@mui/utils/ownerWindow/ownerWindow.js","../../../node_modules/@mui/utils/requirePropFactory/requirePropFactory.js","../../../node_modules/@mui/utils/setRef/setRef.js","../../../node_modules/@mui/utils/useEnhancedEffect/useEnhancedEffect.js","../../../node_modules/@mui/utils/useId/useId.js","../../../node_modules/@mui/utils/unsupportedProp/unsupportedProp.js","../../../node_modules/@mui/utils/useControlled/useControlled.js","../../../node_modules/@mui/utils/useEventCallback/useEventCallback.js","../../../node_modules/@mui/utils/useForkRef/useForkRef.js","../../../node_modules/@mui/utils/useLazyRef/useLazyRef.js","../../../node_modules/@mui/utils/useOnMount/useOnMount.js","../../../node_modules/@mui/utils/useTimeout/useTimeout.js","../../../node_modules/@mui/utils/useIsFocusVisible/useIsFocusVisible.js","../../../node_modules/@mui/utils/resolveProps/resolveProps.js","../../../node_modules/@mui/utils/composeClasses/composeClasses.js","../../../node_modules/@mui/utils/ClassNameGenerator/ClassNameGenerator.js","../../../node_modules/@mui/utils/generateUtilityClass/generateUtilityClass.js","../../../node_modules/@mui/utils/generateUtilityClasses/generateUtilityClasses.js","../../../node_modules/@mui/utils/clamp/clamp.js","../../../node_modules/@babel/runtime/helpers/esm/objectWithoutPropertiesLoose.js","../../../node_modules/@mui/system/esm/createTheme/createBreakpoints.js","../../../node_modules/@mui/system/esm/createTheme/shape.js","../../../node_modules/@mui/system/esm/responsivePropType.js","../../../node_modules/@mui/system/esm/merge.js","../../../node_modules/@mui/system/esm/breakpoints.js","../../../node_modules/@mui/system/esm/style.js","../../../node_modules/@mui/system/esm/memoize.js","../../../node_modules/@mui/system/esm/spacing.js","../../../node_modules/@mui/system/esm/createTheme/createSpacing.js","../../../node_modules/@mui/system/esm/compose.js","../../../node_modules/@mui/system/esm/borders.js","../../../node_modules/@mui/system/esm/cssGrid.js","../../../node_modules/@mui/system/esm/palette.js","../../../node_modules/@mui/system/esm/sizing.js","../../../node_modules/@mui/system/esm/styleFunctionSx/defaultSxConfig.js","../../../node_modules/@mui/system/esm/styleFunctionSx/styleFunctionSx.js","../../../node_modules/@mui/system/esm/createTheme/applyStyles.js","../../../node_modules/@mui/system/esm/createTheme/createTheme.js","../../../node_modules/@mui/system/esm/useThemeWithoutDefault.js","../../../node_modules/@mui/system/esm/useTheme.js","../../../node_modules/@mui/system/esm/createStyled.js","../../../node_modules/@mui/system/esm/useThemeProps/getThemeProps.js","../../../node_modules/@mui/system/esm/useThemeProps/useThemeProps.js","../../../node_modules/@mui/system/esm/colorManipulator.js","../../../node_modules/@mui/material/styles/createMixins.js","../../../node_modules/@mui/material/colors/common.js","../../../node_modules/@mui/material/colors/grey.js","../../../node_modules/@mui/material/colors/purple.js","../../../node_modules/@mui/material/colors/red.js","../../../node_modules/@mui/material/colors/orange.js","../../../node_modules/@mui/material/colors/blue.js","../../../node_modules/@mui/material/colors/lightBlue.js","../../../node_modules/@mui/material/colors/green.js","../../../node_modules/@mui/material/styles/createPalette.js","../../../node_modules/@mui/material/styles/createTypography.js","../../../node_modules/@mui/material/styles/shadows.js","../../../node_modules/@mui/material/styles/createTransitions.js","../../../node_modules/@mui/material/styles/zIndex.js","../../../node_modules/@mui/material/styles/createTheme.js","../../../node_modules/@mui/material/styles/defaultTheme.js","../../../node_modules/@mui/material/styles/identifier.js","../../../node_modules/@mui/material/styles/useThemeProps.js","../../../node_modules/@mui/material/styles/styled.js","../../../node_modules/@mui/material/SvgIcon/svgIconClasses.js","../../../node_modules/@mui/material/SvgIcon/SvgIcon.js","../../../node_modules/@mui/material/utils/createSvgIcon.js","../../../node_modules/@mui/material/utils/index.js","../../../node_modules/@mui/icons-material/utils/createSvgIcon.js","../../../node_modules/@mui/icons-material/ArrowRight.js","../../../node_modules/@mui/base/utils/isHostComponent.js","../../../node_modules/@mui/base/utils/appendOwnerState.js","../../../node_modules/@mui/base/utils/ClassNameConfigurator.js","../../../node_modules/@mui/base/utils/extractEventHandlers.js","../../../node_modules/@mui/base/utils/resolveComponentProps.js","../../../node_modules/@mui/base/utils/omitEventHandlers.js","../../../node_modules/@mui/base/utils/mergeSlotProps.js","../../../node_modules/@mui/base/utils/useSlotProps.js","../../../node_modules/@mui/base/generateUtilityClass/index.js","../../../node_modules/@mui/base/generateUtilityClasses/index.js","../../../node_modules/@mui/base/Portal/Portal.js","../../../node_modules/@popperjs/core/lib/enums.js","../../../node_modules/@popperjs/core/lib/dom-utils/getNodeName.js","../../../node_modules/@popperjs/core/lib/dom-utils/getWindow.js","../../../node_modules/@popperjs/core/lib/dom-utils/instanceOf.js","../../../node_modules/@popperjs/core/lib/modifiers/applyStyles.js","../../../node_modules/@popperjs/core/lib/utils/getBasePlacement.js","../../../node_modules/@popperjs/core/lib/utils/math.js","../../../node_modules/@popperjs/core/lib/utils/userAgent.js","../../../node_modules/@popperjs/core/lib/dom-utils/isLayoutViewport.js","../../../node_modules/@popperjs/core/lib/dom-utils/getBoundingClientRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/getLayoutRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/contains.js","../../../node_modules/@popperjs/core/lib/dom-utils/getComputedStyle.js","../../../node_modules/@popperjs/core/lib/dom-utils/isTableElement.js","../../../node_modules/@popperjs/core/lib/dom-utils/getDocumentElement.js","../../../node_modules/@popperjs/core/lib/dom-utils/getParentNode.js","../../../node_modules/@popperjs/core/lib/dom-utils/getOffsetParent.js","../../../node_modules/@popperjs/core/lib/utils/getMainAxisFromPlacement.js","../../../node_modules/@popperjs/core/lib/utils/within.js","../../../node_modules/@popperjs/core/lib/utils/getFreshSideObject.js","../../../node_modules/@popperjs/core/lib/utils/mergePaddingObject.js","../../../node_modules/@popperjs/core/lib/utils/expandToHashMap.js","../../../node_modules/@popperjs/core/lib/modifiers/arrow.js","../../../node_modules/@popperjs/core/lib/utils/getVariation.js","../../../node_modules/@popperjs/core/lib/modifiers/computeStyles.js","../../../node_modules/@popperjs/core/lib/modifiers/eventListeners.js","../../../node_modules/@popperjs/core/lib/utils/getOppositePlacement.js","../../../node_modules/@popperjs/core/lib/utils/getOppositeVariationPlacement.js","../../../node_modules/@popperjs/core/lib/dom-utils/getWindowScroll.js","../../../node_modules/@popperjs/core/lib/dom-utils/getWindowScrollBarX.js","../../../node_modules/@popperjs/core/lib/dom-utils/getViewportRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/getDocumentRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/isScrollParent.js","../../../node_modules/@popperjs/core/lib/dom-utils/getScrollParent.js","../../../node_modules/@popperjs/core/lib/dom-utils/listScrollParents.js","../../../node_modules/@popperjs/core/lib/utils/rectToClientRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/getClippingRect.js","../../../node_modules/@popperjs/core/lib/utils/computeOffsets.js","../../../node_modules/@popperjs/core/lib/utils/detectOverflow.js","../../../node_modules/@popperjs/core/lib/utils/computeAutoPlacement.js","../../../node_modules/@popperjs/core/lib/modifiers/flip.js","../../../node_modules/@popperjs/core/lib/modifiers/hide.js","../../../node_modules/@popperjs/core/lib/modifiers/offset.js","../../../node_modules/@popperjs/core/lib/modifiers/popperOffsets.js","../../../node_modules/@popperjs/core/lib/utils/getAltAxis.js","../../../node_modules/@popperjs/core/lib/modifiers/preventOverflow.js","../../../node_modules/@popperjs/core/lib/dom-utils/getHTMLElementScroll.js","../../../node_modules/@popperjs/core/lib/dom-utils/getNodeScroll.js","../../../node_modules/@popperjs/core/lib/dom-utils/getCompositeRect.js","../../../node_modules/@popperjs/core/lib/utils/orderModifiers.js","../../../node_modules/@popperjs/core/lib/utils/debounce.js","../../../node_modules/@popperjs/core/lib/utils/mergeByName.js","../../../node_modules/@popperjs/core/lib/createPopper.js","../../../node_modules/@popperjs/core/lib/popper.js","../../../node_modules/@mui/base/Popper/popperClasses.js","../../../node_modules/@mui/base/Popper/Popper.js","../../../node_modules/@mui/material/styles/useTheme.js","../../../node_modules/@babel/runtime/helpers/esm/setPrototypeOf.js","../../../node_modules/@babel/runtime/helpers/esm/inheritsLoose.js","../../../node_modules/react-transition-group/esm/config.js","../../../node_modules/react-transition-group/esm/utils/PropTypes.js","../../../node_modules/react-transition-group/esm/TransitionGroupContext.js","../../../node_modules/react-transition-group/esm/utils/reflow.js","../../../node_modules/react-transition-group/esm/Transition.js","../../../node_modules/@mui/material/transitions/utils.js","../../../node_modules/@mui/material/Grow/Grow.js","../../../node_modules/@mui/material/Popper/Popper.js","../../../node_modules/@mui/material/Tooltip/tooltipClasses.js","../../../node_modules/@mui/material/Tooltip/Tooltip.js","../src/components/mui/menu-item.component.tsx","../src/components/mui/grouped-menu-item-list.component.tsx","../src/components/mui/top-level-menu.component.tsx","../src/components/mui/grid-menu.component.tsx","../src/hooks/use-promise.hook.ts","../../../node_modules/@mui/icons-material/esm/Menu.js","../src/components/mui/hamburger-menu-button.component.tsx","../src/components/mui/icon-button.component.tsx","../src/components/basics/spinner.component.tsx","../src/components/basics/text-field.component.tsx","../src/components/mui/toolbar.component.tsx","../src/components/shadcn-ui/alert.tsx","../src/components/shadcn-ui/sonner.tsx","../src/components/shadcn-ui/slider.tsx","../src/components/shadcn-ui/switch.tsx","../src/components/shadcn-ui/tabs.tsx","../src/components/advanced/extension-marketplace/buttons/install-button.component.tsx","../src/components/advanced/extension-marketplace/buttons/enable-button.component.tsx","../src/components/advanced/extension-marketplace/buttons/disable-button.component.tsx","../src/components/advanced/extension-marketplace/buttons/update-button.component.tsx","../src/components/advanced/extension-marketplace/markdown-renderer.component.tsx","../src/components/advanced/extension-marketplace/buttons/filter-button.component.tsx","../src/components/advanced/extension-marketplace/filter-dropdown.component.tsx","../src/components/advanced/extension-marketplace/no-extensions-found.component.tsx","../src/components/advanced/extension-marketplace/more-info.component.tsx","../src/components/advanced/extension-marketplace/version-history.component.tsx","../src/components/advanced/extension-marketplace/footer.component.tsx","../src/hooks/use-event.hook.ts","../src/hooks/use-event-async.hook.ts"],"sourcesContent":["import { type ClassValue, clsx } from 'clsx';\nimport { extendTailwindMerge } from 'tailwind-merge';\n\nconst twMergeCustom = extendTailwindMerge({ prefix: 'tw-' });\n\n/**\n * Tailwind and CSS class application helper function. Uses\n * [`clsx`](https://www.npmjs.com/package/clsx) to make it easy to apply classes conditionally using\n * object syntax, and uses [`tailwind-merge`](https://www.npmjs.com/package/tailwind-merge) to make\n * it easy to merge/overwrite Tailwind classes in a programmer-logic-friendly way.\n *\n * Note: `tailwind-merge` is configured to use the prefix `tw-`, so you must use the same prefix\n * with any Tailwind classes you use with this function to successfully overwrite other Tailwind\n * classes. `platform-bible-react` is configured to use `tw-` as its Tailwind prefix, so any\n * Tailwind classes you pass into `platform-bible-react` components will be compared using the `tw-`\n * prefix.\n *\n * This function was popularized by\n * [shadcn/ui](https://ui.shadcn.com/docs/installation/manual#add-a-cn-helper). See [ByteGrad's\n * explanation video](https://www.youtube.com/watch?v=re2JFITR7TI) for more information.\n *\n * @example\n *\n * ```typescript\n * const borderShouldBeBlue = true;\n * const textShouldBeRed = true;\n * const heightShouldBe20 = false;\n * const classString = cn(\n * 'tw-bg-primary tw-h-10 tw-text-primary-foreground',\n * 'tw-bg-secondary',\n * {\n * 'tw-border-blue-500': borderShouldBeBlue,\n * 'tw-text-red-500': textShouldBeRed,\n * 'tw-h-20': heightShouldBe20,\n * },\n * 'some-class',\n * );\n * ```\n *\n * The resulting `classString` is `'tw-h-10 tw-bg-secondary tw-border-blue-500 tw-text-red-500\n * some-class'`\n *\n * - Notice that `'tw-bg-secondary'`, specified later, overwrote `'tw-bg-primary'`, specified earlier,\n * because they are Tailwind classes that affect the same css property\n * - Notice that `'tw-text-red-500'`, specified later, overwrote `'tw-text-primary-foreground'`,\n * specified earlier, because they are Tailwind classes that affect the same css property\n * - Notice that `'tw-h-20'`, specified later, did not overwrite `'tw-h-10'`, specified earlier,\n * because `'tw-h-20'` is part of a conditional class object and its value evaluated to `false`;\n * therefore it was not applied\n * - Notice that `'some-class'` was applied. This function is not limited only to Tailwind classes.\n *\n *\n * @param inputs Class strings or `clsx` conditional class objects to merge. Tailwind classes\n * specified later in the arguments overwrite similar Tailwind classes specified earlier in the\n * arguments\n * @returns Class string containing all applicable classes from the arguments based on the rules\n * described above\n */\n// shadcn/ui uses this export in its boilerplate code\n// eslint-disable-next-line import/prefer-default-export\nexport function cn(...inputs: ClassValue[]) {\n return twMergeCustom(clsx(inputs));\n}\n","import React from 'react';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport interface InputProps extends React.InputHTMLAttributes {}\n\nexport const Input = React.forwardRef(\n ({ className, type, ...props }, ref) => {\n return (\n \n );\n },\n);\nInput.displayName = 'Input';\n","import { FocusEventHandler, forwardRef, KeyboardEvent, MouseEventHandler } from 'react';\nimport { History } from 'lucide-react';\nimport { Input as ShadInput } from '@/components/shadcn-ui/input';\n\nexport type BookChapterInputProps = {\n handleSearch: (searchString: string) => void;\n handleKeyDown: (event: KeyboardEvent) => void;\n handleOnClick: MouseEventHandler;\n handleSubmit: () => void;\n onFocus?: FocusEventHandler;\n value: string;\n placeholder: string;\n};\n\n// Shadcn Input sets type to \"button\"- HAVE to prop spread before setting type\nconst BookChapterInput = forwardRef(\n (\n { handleSearch, handleKeyDown, handleOnClick, handleSubmit, ...props }: BookChapterInputProps,\n ref,\n ) => {\n return (\n
    \n handleSearch(event.target.value)}\n onKeyDown={(e) => {\n if (e.key === 'Enter') {\n handleSubmit();\n }\n handleKeyDown(e);\n }}\n onClick={handleOnClick}\n ref={ref}\n />\n {\n // eslint-disable-next-line no-console\n console.log('back in history');\n }}\n />\n
    \n );\n },\n);\n\nexport default BookChapterInput;\n","var P = Object.defineProperty;\nvar R = (t, e, s) => e in t ? P(t, e, { enumerable: !0, configurable: !0, writable: !0, value: s }) : t[e] = s;\nvar n = (t, e, s) => R(t, typeof e != \"symbol\" ? e + \"\" : e, s);\nclass _ {\n constructor() {\n n(this, \"books\");\n n(this, \"firstSelectedBookNum\");\n n(this, \"lastSelectedBookNum\");\n n(this, \"count\");\n n(this, \"selectedBookNumbers\");\n n(this, \"selectedBookIds\");\n }\n}\nconst N = [\n \"GEN\",\n \"EXO\",\n \"LEV\",\n \"NUM\",\n \"DEU\",\n \"JOS\",\n \"JDG\",\n \"RUT\",\n \"1SA\",\n \"2SA\",\n // 10\n \"1KI\",\n \"2KI\",\n \"1CH\",\n \"2CH\",\n \"EZR\",\n \"NEH\",\n \"EST\",\n \"JOB\",\n \"PSA\",\n \"PRO\",\n // 20\n \"ECC\",\n \"SNG\",\n \"ISA\",\n \"JER\",\n \"LAM\",\n \"EZK\",\n \"DAN\",\n \"HOS\",\n \"JOL\",\n \"AMO\",\n // 30\n \"OBA\",\n \"JON\",\n \"MIC\",\n \"NAM\",\n \"HAB\",\n \"ZEP\",\n \"HAG\",\n \"ZEC\",\n \"MAL\",\n \"MAT\",\n // 40\n \"MRK\",\n \"LUK\",\n \"JHN\",\n \"ACT\",\n \"ROM\",\n \"1CO\",\n \"2CO\",\n \"GAL\",\n \"EPH\",\n \"PHP\",\n // 50\n \"COL\",\n \"1TH\",\n \"2TH\",\n \"1TI\",\n \"2TI\",\n \"TIT\",\n \"PHM\",\n \"HEB\",\n \"JAS\",\n \"1PE\",\n // 60\n \"2PE\",\n \"1JN\",\n \"2JN\",\n \"3JN\",\n \"JUD\",\n \"REV\",\n \"TOB\",\n \"JDT\",\n \"ESG\",\n \"WIS\",\n // 70\n \"SIR\",\n \"BAR\",\n \"LJE\",\n \"S3Y\",\n \"SUS\",\n \"BEL\",\n \"1MA\",\n \"2MA\",\n \"3MA\",\n \"4MA\",\n // 80\n \"1ES\",\n \"2ES\",\n \"MAN\",\n \"PS2\",\n \"ODA\",\n \"PSS\",\n \"JSA\",\n // actual variant text for JOS, now in LXA text\n \"JDB\",\n // actual variant text for JDG, now in LXA text\n \"TBS\",\n // actual variant text for TOB, now in LXA text\n \"SST\",\n // actual variant text for SUS, now in LXA text // 90\n \"DNT\",\n // actual variant text for DAN, now in LXA text\n \"BLT\",\n // actual variant text for BEL, now in LXA text\n \"XXA\",\n \"XXB\",\n \"XXC\",\n \"XXD\",\n \"XXE\",\n \"XXF\",\n \"XXG\",\n \"FRT\",\n // 100\n \"BAK\",\n \"OTH\",\n \"3ES\",\n // Used previously but really should be 2ES\n \"EZA\",\n // Used to be called 4ES, but not actually in any known project\n \"5EZ\",\n // Used to be called 5ES, but not actually in any known project\n \"6EZ\",\n // Used to be called 6ES, but not actually in any known project\n \"INT\",\n \"CNC\",\n \"GLO\",\n \"TDX\",\n // 110\n \"NDX\",\n \"DAG\",\n \"PS3\",\n \"2BA\",\n \"LBA\",\n \"JUB\",\n \"ENO\",\n \"1MQ\",\n \"2MQ\",\n \"3MQ\",\n // 120\n \"REP\",\n \"4BA\",\n \"LAO\"\n], B = [\n \"XXA\",\n \"XXB\",\n \"XXC\",\n \"XXD\",\n \"XXE\",\n \"XXF\",\n \"XXG\",\n \"FRT\",\n \"BAK\",\n \"OTH\",\n \"INT\",\n \"CNC\",\n \"GLO\",\n \"TDX\",\n \"NDX\"\n], O = [\n \"Genesis\",\n \"Exodus\",\n \"Leviticus\",\n \"Numbers\",\n \"Deuteronomy\",\n \"Joshua\",\n \"Judges\",\n \"Ruth\",\n \"1 Samuel\",\n \"2 Samuel\",\n \"1 Kings\",\n \"2 Kings\",\n \"1 Chronicles\",\n \"2 Chronicles\",\n \"Ezra\",\n \"Nehemiah\",\n \"Esther (Hebrew)\",\n \"Job\",\n \"Psalms\",\n \"Proverbs\",\n \"Ecclesiastes\",\n \"Song of Songs\",\n \"Isaiah\",\n \"Jeremiah\",\n \"Lamentations\",\n \"Ezekiel\",\n \"Daniel (Hebrew)\",\n \"Hosea\",\n \"Joel\",\n \"Amos\",\n \"Obadiah\",\n \"Jonah\",\n \"Micah\",\n \"Nahum\",\n \"Habakkuk\",\n \"Zephaniah\",\n \"Haggai\",\n \"Zechariah\",\n \"Malachi\",\n \"Matthew\",\n \"Mark\",\n \"Luke\",\n \"John\",\n \"Acts\",\n \"Romans\",\n \"1 Corinthians\",\n \"2 Corinthians\",\n \"Galatians\",\n \"Ephesians\",\n \"Philippians\",\n \"Colossians\",\n \"1 Thessalonians\",\n \"2 Thessalonians\",\n \"1 Timothy\",\n \"2 Timothy\",\n \"Titus\",\n \"Philemon\",\n \"Hebrews\",\n \"James\",\n \"1 Peter\",\n \"2 Peter\",\n \"1 John\",\n \"2 John\",\n \"3 John\",\n \"Jude\",\n \"Revelation\",\n \"Tobit\",\n \"Judith\",\n \"Esther Greek\",\n \"Wisdom of Solomon\",\n \"Sirach (Ecclesiasticus)\",\n \"Baruch\",\n \"Letter of Jeremiah\",\n \"Song of 3 Young Men\",\n \"Susanna\",\n \"Bel and the Dragon\",\n \"1 Maccabees\",\n \"2 Maccabees\",\n \"3 Maccabees\",\n \"4 Maccabees\",\n \"1 Esdras (Greek)\",\n \"2 Esdras (Latin)\",\n \"Prayer of Manasseh\",\n \"Psalm 151\",\n \"Odes\",\n \"Psalms of Solomon\",\n // WARNING, if you change the spelling of the *obsolete* tag be sure to update\n // IsObsolete routine\n \"Joshua A. *obsolete*\",\n \"Judges B. *obsolete*\",\n \"Tobit S. *obsolete*\",\n \"Susanna Th. *obsolete*\",\n \"Daniel Th. *obsolete*\",\n \"Bel Th. *obsolete*\",\n \"Extra A\",\n \"Extra B\",\n \"Extra C\",\n \"Extra D\",\n \"Extra E\",\n \"Extra F\",\n \"Extra G\",\n \"Front Matter\",\n \"Back Matter\",\n \"Other Matter\",\n \"3 Ezra *obsolete*\",\n \"Apocalypse of Ezra\",\n \"5 Ezra (Latin Prologue)\",\n \"6 Ezra (Latin Epilogue)\",\n \"Introduction\",\n \"Concordance \",\n \"Glossary \",\n \"Topical Index\",\n \"Names Index\",\n \"Daniel Greek\",\n \"Psalms 152-155\",\n \"2 Baruch (Apocalypse)\",\n \"Letter of Baruch\",\n \"Jubilees\",\n \"Enoch\",\n \"1 Meqabyan\",\n \"2 Meqabyan\",\n \"3 Meqabyan\",\n \"Reproof (Proverbs 25-31)\",\n \"4 Baruch (Rest of Baruch)\",\n \"Laodiceans\"\n], S = K();\nfunction g(t, e = !0) {\n return e && (t = t.toUpperCase()), t in S ? S[t] : 0;\n}\nfunction k(t) {\n return g(t) > 0;\n}\nfunction x(t) {\n const e = typeof t == \"string\" ? g(t) : t;\n return e >= 40 && e <= 66;\n}\nfunction T(t) {\n return (typeof t == \"string\" ? g(t) : t) <= 39;\n}\nfunction X(t) {\n return t <= 66;\n}\nfunction V(t) {\n const e = typeof t == \"string\" ? g(t) : t;\n return w(e) && !X(e);\n}\nfunction* L() {\n for (let t = 1; t <= N.length; t++) yield t;\n}\nconst G = 1, A = N.length;\nfunction H() {\n return [\"XXA\", \"XXB\", \"XXC\", \"XXD\", \"XXE\", \"XXF\", \"XXG\"];\n}\nfunction C(t, e = \"***\") {\n const s = t - 1;\n return s < 0 || s >= N.length ? e : N[s];\n}\nfunction I(t) {\n return t <= 0 || t > A ? \"******\" : O[t - 1];\n}\nfunction y(t) {\n return I(g(t));\n}\nfunction w(t) {\n const e = typeof t == \"number\" ? C(t) : t;\n return k(e) && !B.includes(e);\n}\nfunction q(t) {\n const e = typeof t == \"number\" ? C(t) : t;\n return k(e) && B.includes(e);\n}\nfunction U(t) {\n return O[t - 1].includes(\"*obsolete*\");\n}\nfunction K() {\n const t = {};\n for (let e = 0; e < N.length; e++)\n t[N[e]] = e + 1;\n return t;\n}\nconst m = {\n allBookIds: N,\n nonCanonicalIds: B,\n bookIdToNumber: g,\n isBookIdValid: k,\n isBookNT: x,\n isBookOT: T,\n isBookOTNT: X,\n isBookDC: V,\n allBookNumbers: L,\n firstBook: G,\n lastBook: A,\n extraBooks: H,\n bookNumberToId: C,\n bookNumberToEnglishName: I,\n bookIdToEnglishName: y,\n isCanonical: w,\n isExtraMaterial: q,\n isObsolete: U\n};\nvar l = /* @__PURE__ */ ((t) => (t[t.Unknown = 0] = \"Unknown\", t[t.Original = 1] = \"Original\", t[t.Septuagint = 2] = \"Septuagint\", t[t.Vulgate = 3] = \"Vulgate\", t[t.English = 4] = \"English\", t[t.RussianProtestant = 5] = \"RussianProtestant\", t[t.RussianOrthodox = 6] = \"RussianOrthodox\", t))(l || {});\nconst h = class h {\n // private versInfo: Versification;\n constructor(e) {\n n(this, \"name\");\n n(this, \"fullPath\");\n n(this, \"isPresent\");\n n(this, \"hasVerseSegments\");\n n(this, \"isCustomized\");\n n(this, \"baseVersification\");\n n(this, \"scriptureBooks\");\n n(this, \"_type\");\n if (e == null)\n throw new Error(\"Argument undefined\");\n typeof e == \"string\" ? (this.name = e, this._type = l[e]) : (this._type = e, this.name = l[e]);\n }\n get type() {\n return this._type;\n }\n equals(e) {\n return !e.type || !this.type ? !1 : e.type === this.type;\n }\n};\nn(h, \"Original\", new h(l.Original)), n(h, \"Septuagint\", new h(l.Septuagint)), n(h, \"Vulgate\", new h(l.Vulgate)), n(h, \"English\", new h(l.English)), n(h, \"RussianProtestant\", new h(l.RussianProtestant)), n(h, \"RussianOrthodox\", new h(l.RussianOrthodox));\nlet c = h;\nfunction E(t, e) {\n const s = e[0];\n for (let r = 1; r < e.length; r++)\n t = t.split(e[r]).join(s);\n return t.split(s);\n}\nvar D = /* @__PURE__ */ ((t) => (t[t.Valid = 0] = \"Valid\", t[t.UnknownVersification = 1] = \"UnknownVersification\", t[t.OutOfRange = 2] = \"OutOfRange\", t[t.VerseOutOfOrder = 3] = \"VerseOutOfOrder\", t[t.VerseRepeated = 4] = \"VerseRepeated\", t))(D || {});\nconst i = class i {\n constructor(e, s, r, a) {\n /** Not yet implemented. */\n n(this, \"firstChapter\");\n /** Not yet implemented. */\n n(this, \"lastChapter\");\n /** Not yet implemented. */\n n(this, \"lastVerse\");\n /** Not yet implemented. */\n n(this, \"hasSegmentsDefined\");\n /** Not yet implemented. */\n n(this, \"text\");\n /** Not yet implemented. */\n n(this, \"BBBCCCVVVS\");\n /** Not yet implemented. */\n n(this, \"longHashCode\");\n /** The versification of the reference. */\n n(this, \"versification\");\n n(this, \"rtlMark\", \"‏\");\n n(this, \"_bookNum\", 0);\n n(this, \"_chapterNum\", 0);\n n(this, \"_verseNum\", 0);\n n(this, \"_verse\");\n if (r == null && a == null)\n if (e != null && typeof e == \"string\") {\n const o = e, u = s != null && s instanceof c ? s : void 0;\n this.setEmpty(u), this.parse(o);\n } else if (e != null && typeof e == \"number\") {\n const o = s != null && s instanceof c ? s : void 0;\n this.setEmpty(o), this._verseNum = e % i.chapterDigitShifter, this._chapterNum = Math.floor(\n e % i.bookDigitShifter / i.chapterDigitShifter\n ), this._bookNum = Math.floor(e / i.bookDigitShifter);\n } else if (s == null)\n if (e != null && e instanceof i) {\n const o = e;\n this._bookNum = o.bookNum, this._chapterNum = o.chapterNum, this._verseNum = o.verseNum, this._verse = o.verse, this.versification = o.versification;\n } else {\n if (e == null) return;\n const o = e instanceof c ? e : i.defaultVersification;\n this.setEmpty(o);\n }\n else\n throw new Error(\"VerseRef constructor not supported.\");\n else if (e != null && s != null && r != null)\n if (typeof e == \"string\" && typeof s == \"string\" && typeof r == \"string\")\n this.setEmpty(a), this.updateInternal(e, s, r);\n else if (typeof e == \"number\" && typeof s == \"number\" && typeof r == \"number\")\n this._bookNum = e, this._chapterNum = s, this._verseNum = r, this.versification = a ?? i.defaultVersification;\n else\n throw new Error(\"VerseRef constructor not supported.\");\n else\n throw new Error(\"VerseRef constructor not supported.\");\n }\n /**\n * Determines if the verse string is in a valid format (does not consider versification).\n */\n static isVerseParseable(e) {\n return e.length > 0 && \"0123456789\".includes(e[0]) && !e.endsWith(this.verseRangeSeparator) && !e.endsWith(this.verseSequenceIndicator);\n }\n /**\n * Tries to parse the specified string into a verse reference.\n * @param str - The string to attempt to parse.\n * @returns success: `true` if the specified string was successfully parsed, `false` otherwise.\n * @returns verseRef: The result of the parse if successful, or empty VerseRef if it failed\n */\n static tryParse(e) {\n let s;\n try {\n return s = new i(e), { success: !0, verseRef: s };\n } catch (r) {\n if (r instanceof v)\n return s = new i(), { success: !1, verseRef: s };\n throw r;\n }\n }\n /**\n * Gets the reference as a comparable integer where the book, chapter, and verse each occupy 3\n * digits.\n * @param bookNum - Book number (this is 1-based, not an index).\n * @param chapterNum - Chapter number.\n * @param verseNum - Verse number.\n * @returns The reference as a comparable integer where the book, chapter, and verse each occupy 3\n * digits.\n */\n static getBBBCCCVVV(e, s, r) {\n return e % i.bcvMaxValue * i.bookDigitShifter + (s >= 0 ? s % i.bcvMaxValue * i.chapterDigitShifter : 0) + (r >= 0 ? r % i.bcvMaxValue : 0);\n }\n /**\n * Deserializes a serialized VerseRef.\n * @param serializedVerseRef - Serialized VerseRef to create from.\n * @returns the deserialized VerseRef.\n */\n static fromJSON(e) {\n const { book: s, chapterNum: r, verseNum: a, verse: o, versificationStr: u } = e, f = o || a.toString();\n let d;\n return u && (d = new c(u)), s ? new i(s, r.toString(), f, d) : new i();\n }\n /**\n * Parses a verse string and gets the leading numeric portion as a number.\n * @param verseStr - verse string to parse\n * @returns true if the entire string could be parsed as a single, simple verse number (1-999);\n * false if the verse string represented a verse bridge, contained segment letters, or was invalid\n */\n static tryGetVerseNum(e) {\n let s;\n if (!e)\n return s = -1, { success: !0, vNum: s };\n s = 0;\n let r;\n for (let a = 0; a < e.length; a++) {\n if (r = e[a], r < \"0\" || r > \"9\")\n return a === 0 && (s = -1), { success: !1, vNum: s };\n if (s = s * 10 + +r - 0, s > i.bcvMaxValue)\n return s = -1, { success: !1, vNum: s };\n }\n return { success: !0, vNum: s };\n }\n /**\n * Checks to see if a VerseRef hasn't been set - all values are the default.\n */\n get isDefault() {\n return this.bookNum === 0 && this.chapterNum === 0 && this.verseNum === 0 && this.versification == null;\n }\n /**\n * Gets whether the verse contains multiple verses.\n */\n get hasMultiple() {\n return this._verse != null && (this._verse.includes(i.verseRangeSeparator) || this._verse.includes(i.verseSequenceIndicator));\n }\n /**\n * Gets or sets the book of the reference. Book is the 3-letter abbreviation in capital letters,\n * e.g. `'MAT'`.\n */\n get book() {\n return m.bookNumberToId(this.bookNum, \"\");\n }\n set book(e) {\n this.bookNum = m.bookIdToNumber(e);\n }\n /**\n * Gets or sets the chapter of the reference,. e.g. `'3'`.\n */\n get chapter() {\n return this.isDefault || this._chapterNum < 0 ? \"\" : this._chapterNum.toString();\n }\n set chapter(e) {\n const s = +e;\n this._chapterNum = Number.isInteger(s) ? s : -1;\n }\n /**\n * Gets or sets the verse of the reference, including range, segments, and sequences, e.g. `'4'`,\n * or `'4b-5a, 7'`.\n */\n get verse() {\n return this._verse != null ? this._verse : this.isDefault || this._verseNum < 0 ? \"\" : this._verseNum.toString();\n }\n set verse(e) {\n const { success: s, vNum: r } = i.tryGetVerseNum(e);\n this._verse = s ? void 0 : e.replace(this.rtlMark, \"\"), this._verseNum = r, !(this._verseNum >= 0) && ({ vNum: this._verseNum } = i.tryGetVerseNum(this._verse));\n }\n /**\n * Get or set Book based on book number, e.g. `42`.\n */\n get bookNum() {\n return this._bookNum;\n }\n set bookNum(e) {\n if (e <= 0 || e > m.lastBook)\n throw new v(\n \"BookNum must be greater than zero and less than or equal to last book\"\n );\n this._bookNum = e;\n }\n /**\n * Gets or sets the chapter number, e.g. `3`. `-1` if not valid.\n */\n get chapterNum() {\n return this._chapterNum;\n }\n set chapterNum(e) {\n this.chapterNum = e;\n }\n /**\n * Gets or sets verse start number, e.g. `4`. `-1` if not valid.\n */\n get verseNum() {\n return this._verseNum;\n }\n set verseNum(e) {\n this._verseNum = e;\n }\n /**\n * String representing the versification (should ONLY be used for serialization/deserialization).\n *\n * @remarks This is for backwards compatibility when ScrVers was an enumeration.\n */\n get versificationStr() {\n var e;\n return (e = this.versification) == null ? void 0 : e.name;\n }\n set versificationStr(e) {\n this.versification = this.versification != null ? new c(e) : void 0;\n }\n /**\n * Determines if the reference is valid.\n */\n get valid() {\n return this.validStatus === 0;\n }\n /**\n * Get the valid status for this reference.\n */\n get validStatus() {\n return this.validateVerse(i.verseRangeSeparators, i.verseSequenceIndicators);\n }\n /**\n * Gets the reference as a comparable integer where the book,\n * chapter, and verse each occupy three digits and the verse is 0.\n */\n get BBBCCC() {\n return i.getBBBCCCVVV(this._bookNum, this._chapterNum, 0);\n }\n /**\n * Gets the reference as a comparable integer where the book,\n * chapter, and verse each occupy three digits. If verse is not null\n * (i.e., this reference represents a complex reference with verse\n * segments or bridge) this cannot be used for an exact comparison.\n */\n get BBBCCCVVV() {\n return i.getBBBCCCVVV(this._bookNum, this._chapterNum, this._verseNum);\n }\n /**\n * Gets whether the verse is defined as an excluded verse in the versification.\n * Does not handle verse ranges.\n */\n // eslint-disable-next-line @typescript-eslint/class-literal-property-style\n get isExcluded() {\n return !1;\n }\n /**\n * Parses the reference in the specified string.\n * Optionally versification can follow reference as in GEN 3:11/4\n * Throw an exception if\n * - invalid book name\n * - chapter number is missing or not a number\n * - verse number is missing or does not start with a number\n * - versification is invalid\n * @param verseStr - string to parse e.g. 'MAT 3:11'\n */\n parse(e) {\n if (e = e.replace(this.rtlMark, \"\"), e.includes(\"/\")) {\n const o = e.split(\"/\");\n if (e = o[0], o.length > 1)\n try {\n const u = +o[1].trim();\n this.versification = new c(l[u]);\n } catch {\n throw new v(\"Invalid reference : \" + e);\n }\n }\n const s = e.trim().split(\" \");\n if (s.length !== 2)\n throw new v(\"Invalid reference : \" + e);\n const r = s[1].split(\":\"), a = +r[0];\n if (r.length !== 2 || m.bookIdToNumber(s[0]) === 0 || !Number.isInteger(a) || a < 0 || !i.isVerseParseable(r[1]))\n throw new v(\"Invalid reference : \" + e);\n this.updateInternal(s[0], r[0], r[1]);\n }\n /**\n * Simplifies this verse ref so that it has no bridging of verses or\n * verse segments like `'1a'`.\n */\n simplify() {\n this._verse = void 0;\n }\n /**\n * Makes a clone of the reference.\n *\n * @returns The cloned VerseRef.\n */\n clone() {\n return new i(this);\n }\n toString() {\n const e = this.book;\n return e === \"\" ? \"\" : `${e} ${this.chapter}:${this.verse}`;\n }\n toJSON() {\n let e = this.verse;\n (e === \"\" || e === this.verseNum.toString()) && (e = void 0);\n const s = {\n book: this.book,\n chapterNum: this.chapterNum,\n verseNum: this.verseNum,\n verse: e,\n versificationStr: this.versificationStr\n };\n return e || delete s.verse, s;\n }\n /**\n * Compares this `VerseRef` with supplied one.\n * @param verseRef - object to compare this one to.\n * @returns `true` if this `VerseRef` is equal to the supplied one, `false` otherwise.\n */\n equals(e) {\n return e instanceof i ? e._bookNum === this._bookNum && e._chapterNum === this._chapterNum && e._verseNum === this._verseNum && e.verse === this.verse && (e.versification == null && this.versification == null || e.versification != null && this.versification != null && e.versification.equals(this.versification)) : !1;\n }\n /**\n * Enumerate all individual verses contained in a VerseRef.\n * Verse ranges are indicated by \"-\" and consecutive verses by \",\"s.\n * Examples:\n * GEN 1:2 returns GEN 1:2\n * GEN 1:1a-3b,5 returns GEN 1:1a, GEN 1:2, GEN 1:3b, GEN 1:5\n * GEN 1:2a-2c returns //! ??????\n *\n * @param specifiedVersesOnly - if set to true return only verses that are\n * explicitly specified only, not verses within a range. Defaults to `false`.\n * @param verseRangeSeparators - Verse range separators.\n * Defaults to `VerseRef.verseRangeSeparators`.\n * @param verseSequenceSeparators - Verse sequence separators.\n * Defaults to `VerseRef.verseSequenceIndicators`.\n * @returns An array of all single verse references in this VerseRef.\n */\n allVerses(e = !1, s = i.verseRangeSeparators, r = i.verseSequenceIndicators) {\n if (this._verse == null || this.chapterNum <= 0)\n return [this.clone()];\n const a = [], o = E(this._verse, r);\n for (const u of o.map((f) => E(f, s))) {\n const f = this.clone();\n f.verse = u[0];\n const d = f.verseNum;\n if (a.push(f), u.length > 1) {\n const b = this.clone();\n if (b.verse = u[1], !e)\n for (let p = d + 1; p < b.verseNum; p++) {\n const J = new i(\n this._bookNum,\n this._chapterNum,\n p,\n this.versification\n );\n this.isExcluded || a.push(J);\n }\n a.push(b);\n }\n }\n return a;\n }\n /**\n * Validates a verse number using the supplied separators rather than the defaults.\n */\n validateVerse(e, s) {\n if (!this.verse)\n return this.internalValid;\n let r = 0;\n for (const a of this.allVerses(!0, e, s)) {\n const o = a.internalValid;\n if (o !== 0)\n return o;\n const u = a.BBBCCCVVV;\n if (r > u)\n return 3;\n if (r === u)\n return 4;\n r = u;\n }\n return 0;\n }\n /**\n * Gets whether a single verse reference is valid.\n */\n get internalValid() {\n return this.versification == null ? 1 : this._bookNum <= 0 || this._bookNum > m.lastBook ? 2 : (m.isCanonical(this._bookNum), 0);\n }\n setEmpty(e = i.defaultVersification) {\n this._bookNum = 0, this._chapterNum = -1, this._verse = void 0, this.versification = e;\n }\n updateInternal(e, s, r) {\n this.bookNum = m.bookIdToNumber(e), this.chapter = s, this.verse = r;\n }\n};\nn(i, \"defaultVersification\", c.English), n(i, \"verseRangeSeparator\", \"-\"), n(i, \"verseSequenceIndicator\", \",\"), n(i, \"verseRangeSeparators\", [i.verseRangeSeparator]), n(i, \"verseSequenceIndicators\", [i.verseSequenceIndicator]), n(i, \"chapterDigitShifter\", 1e3), n(i, \"bookDigitShifter\", i.chapterDigitShifter * i.chapterDigitShifter), n(i, \"bcvMaxValue\", i.chapterDigitShifter - 1), /**\n * The valid status of the VerseRef.\n */\nn(i, \"ValidStatusType\", D);\nlet M = i;\nclass v extends Error {\n}\nexport {\n _ as BookSet,\n m as Canon,\n c as ScrVers,\n l as ScrVersType,\n M as VerseRef,\n v as VerseRefException\n};\n//# sourceMappingURL=index.es.js.map\n","import React from 'react';\nimport * as DropdownMenuPrimitive from '@radix-ui/react-dropdown-menu';\nimport { Check, ChevronRight, Circle } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport const DropdownMenu = DropdownMenuPrimitive.Root;\n\nexport const DropdownMenuTrigger = DropdownMenuPrimitive.Trigger;\n\nexport const DropdownMenuGroup = DropdownMenuPrimitive.Group;\n\nexport const DropdownMenuPortal = DropdownMenuPrimitive.Portal;\n\nexport const DropdownMenuSub = DropdownMenuPrimitive.Sub;\n\nexport const DropdownMenuRadioGroup = DropdownMenuPrimitive.RadioGroup;\n\nexport type DropdownMenuSubTriggerProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.SubTrigger\n> & {\n className?: string;\n inset?: boolean;\n};\n\nexport type DropdownMenuSubContentProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.SubContent\n> & {\n className?: string;\n};\n\nexport type DropdownMenuContentProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Content\n> & {\n className?: string;\n sideOffset?: number;\n};\n\nexport type DropdownMenuItemProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Item\n> & {\n className?: string;\n inset?: boolean;\n};\n\nexport type DropdownMenuCheckboxItemProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.CheckboxItem\n> & {\n className?: string;\n checked?: boolean;\n};\n\nexport type DropdownMenuRadioItemProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.RadioItem\n> & {\n className?: string;\n};\n\nexport type DropdownMenuLabelProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Label\n> & {\n className?: string;\n inset?: boolean;\n};\n\nexport type DropdownMenuSeparatorProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Separator\n> & {\n className?: string;\n};\n\nexport type DropdownMenuShortcutProps = React.HTMLAttributes & {\n className?: string;\n};\n\nexport const DropdownMenuSubTrigger = React.forwardRef<\n React.ElementRef,\n DropdownMenuSubTriggerProps\n>(({ className, inset, children, ...props }, ref) => (\n \n {children}\n \n \n));\nDropdownMenuSubTrigger.displayName = DropdownMenuPrimitive.SubTrigger.displayName;\n\nexport const DropdownMenuSubContent = React.forwardRef<\n React.ElementRef,\n DropdownMenuSubContentProps\n>(({ className, ...props }, ref) => (\n \n));\nDropdownMenuSubContent.displayName = DropdownMenuPrimitive.SubContent.displayName;\n\nexport const DropdownMenuContent = React.forwardRef<\n React.ElementRef,\n DropdownMenuContentProps\n>(({ className, sideOffset = 4, ...props }, ref) => (\n \n \n \n));\nDropdownMenuContent.displayName = DropdownMenuPrimitive.Content.displayName;\n\n/**\n * TODO: fix: direction is not automatically handled by this component, so that shortcuts are\n * display always to the right\n */\nexport const DropdownMenuItem = React.forwardRef<\n React.ElementRef,\n DropdownMenuItemProps\n>(({ className, inset, ...props }, ref) => (\n \n));\nDropdownMenuItem.displayName = DropdownMenuPrimitive.Item.displayName;\n\nexport const DropdownMenuCheckboxItem = React.forwardRef<\n React.ElementRef,\n DropdownMenuCheckboxItemProps\n>(({ className, children, checked, ...props }, ref) => (\n \n \n \n \n \n \n {children}\n \n));\nDropdownMenuCheckboxItem.displayName = DropdownMenuPrimitive.CheckboxItem.displayName;\n\nexport const DropdownMenuRadioItem = React.forwardRef<\n React.ElementRef,\n DropdownMenuRadioItemProps\n>(({ className, children, ...props }, ref) => (\n \n \n \n \n \n \n {children}\n \n));\nDropdownMenuRadioItem.displayName = DropdownMenuPrimitive.RadioItem.displayName;\n\nexport const DropdownMenuLabel = React.forwardRef<\n React.ElementRef,\n DropdownMenuLabelProps\n>(({ className, inset, ...props }, ref) => (\n \n));\nDropdownMenuLabel.displayName = DropdownMenuPrimitive.Label.displayName;\n\nexport const DropdownMenuSeparator = React.forwardRef<\n React.ElementRef,\n DropdownMenuSeparatorProps\n>(({ className, ...props }, ref) => (\n \n));\nDropdownMenuSeparator.displayName = DropdownMenuPrimitive.Separator.displayName;\n\nexport function DropdownMenuShortcut({ className, ...props }: DropdownMenuShortcutProps) {\n return (\n \n );\n}\nDropdownMenuShortcut.displayName = 'DropdownMenuShortcut';\n","import { Canon } from '@sillsdev/scripture';\nimport { PropsWithChildren, KeyboardEvent, forwardRef } from 'react';\nimport { DropdownMenuItem as ShadDropdownMenuItem } from '@/components/shadcn-ui/dropdown-menu';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport type BookType = 'OT' | 'NT' | 'DC';\n\ntype BookMenuItemProps = PropsWithChildren<{\n /** String id of book */\n bookId: string;\n /** Callback to run when a book menu item is selected */\n handleSelectBook: () => void;\n /** Indicates if this menu item is currently selected */\n isSelected: boolean;\n /** Function that is called upon highlighting a book in the dropdown menu */\n handleHighlightBook: () => void;\n /**\n * Function that is called on pressing a key\n *\n * @param event Event that contains information about the key stroke\n */\n handleKeyDown: (event: KeyboardEvent) => void;\n /**\n * Type of book associated with this menu item, coordinates color labels ? Mock up has the labels\n * coordinated to genre\n */\n bookType: BookType;\n}>;\n\nconst BookMenuItem = forwardRef(\n (\n {\n bookId,\n handleSelectBook,\n isSelected,\n handleHighlightBook,\n handleKeyDown,\n bookType,\n children,\n }: BookMenuItemProps,\n ref,\n ) => {\n return (\n {\n // preventDefault() here prevents the entire dropdown menu from closing when selecting this item\n event.preventDefault();\n handleSelectBook();\n }}\n onKeyDown={(event: KeyboardEvent) => {\n handleKeyDown(event);\n }}\n onFocus={handleHighlightBook}\n onMouseMove={handleHighlightBook}\n >\n \n {Canon.bookIdToEnglishName(bookId)}\n \n {isSelected &&
    {children}
    }\n \n );\n },\n);\n\nexport default BookMenuItem;\n","import { cn } from '@/utils/shadcn-ui.util';\nimport { useCallback } from 'react';\n\nexport type ChapterSelectProps = {\n /**\n * Callback to run when a chapter div is selected\n *\n * @param chapterNumber Number of the chapter that has been selected\n */\n handleSelectChapter: (chapterNumber: number) => void;\n /** The highest chapter number in the book (of course equal to number of chapters in the book) */\n endChapter: number;\n /** The chapter number that is currently selected */\n activeChapter: number;\n /** The chapter number that is currently highlighted using keyboard or mouse navigation */\n highlightedChapter: number;\n /**\n * Callback to run when a chapter is highlighted by the user\n *\n * @param chapterNumber The chapter that is highlighted\n */\n handleHighlightedChapter: (chapterNumber: number) => void;\n};\n\nfunction ChapterSelect({\n handleSelectChapter,\n endChapter,\n activeChapter,\n highlightedChapter,\n handleHighlightedChapter,\n}: ChapterSelectProps) {\n const chapters = Array.from({ length: endChapter }, (_, i) => i + 1);\n\n const handleMouse = useCallback(\n (chapterNumber: number) => {\n handleHighlightedChapter(chapterNumber);\n },\n [handleHighlightedChapter],\n );\n\n return (\n
    \n {chapters.map((chapter) => (\n {\n event.preventDefault();\n event.stopPropagation();\n handleSelectChapter(chapter);\n }}\n role=\"button\"\n onKeyDown={(event) => {\n if (event.key === 'Enter') {\n handleSelectChapter(chapter);\n }\n }}\n tabIndex={0}\n onMouseMove={() => handleMouse(chapter)}\n >\n {chapter}\n
    \n ))}\n
    \n );\n}\n\nexport default ChapterSelect;\n","import { DropdownMenuLabel as ShadDropdownMenuLabel } from '@/components/shadcn-ui/dropdown-menu';\nimport { Bookmark, Clock, ArrowDownWideNarrow } from 'lucide-react';\n\nexport type GoToMenuItemProps = {\n handleSort: () => void;\n handleLocationHistory: () => void;\n handleBookmarks: () => void;\n};\n\nfunction GoToMenuItem({ handleSort, handleLocationHistory, handleBookmarks }: GoToMenuItemProps) {\n return (\n \n

    Go To

    \n
    \n \n \n \n
    \n
    \n );\n}\n\nexport default GoToMenuItem;\n","import BookChapterInput from '@/components/advanced/book-chapter-control/book-chapter-input.component';\nimport BookMenuItem, {\n BookType,\n} from '@/components/advanced/book-chapter-control/book-menu-item.component';\nimport ChapterSelect from '@/components/advanced/book-chapter-control/chapter-select.component';\nimport GoToMenuItem from '@/components/advanced/book-chapter-control/go-to-menu-item.component';\nimport {\n DropdownMenu as ShadDropdownMenu,\n DropdownMenuContent as ShadDropdownMenuContent,\n DropdownMenuLabel as ShadDropdownMenuLabel,\n DropdownMenuSeparator as ShadDropdownMenuSeparator,\n DropdownMenuTrigger as ShadDropdownMenuTrigger,\n} from '@/components/shadcn-ui/dropdown-menu';\nimport { Canon } from '@sillsdev/scripture';\nimport { ScriptureReference, getChaptersForBook } from 'platform-bible-utils';\nimport {\n KeyboardEvent as ReactKeyboardEvent,\n useCallback,\n useEffect,\n useLayoutEffect,\n useRef,\n useState,\n} from 'react';\n\ntype BookTypeLabels = {\n [bookType in BookType]: string;\n};\ntype BookChapterControlProps = {\n scrRef: ScriptureReference;\n handleSubmit: (scrRef: ScriptureReference) => void;\n};\n\nconst ALL_BOOK_IDS = Canon.allBookIds;\nconst BOOK_TYPE_LABELS: BookTypeLabels = {\n OT: 'Old Testament',\n NT: 'New Testament',\n DC: 'Deuterocanon',\n};\nconst BOOK_TYPE_ARRAY: BookType[] = ['OT', 'NT', 'DC'];\n// This is the height of three menu items to offset scrolling to the selected menu item\n// If you use menuItemRef.clientHeight- includes height of chapter div which is too big\nconst SCROLL_OFFSET = 32 + 32 + 32;\nconst SEARCH_QUERY_FORMATS = [\n /^(\\w+)$/i, // Matches a single word (book name or id)\n /^(\\w+)(?:\\s(\\d+))$/i, // Matches a word followed by a chapter number\n /^(\\w+)(?:\\s(\\d+):(\\d+))$/i, // Matches a word followed by a chapter and verse number\n];\nconst fetchGroupedBooks = (bookType: BookType) => {\n const groupedBooks = {\n OT: ALL_BOOK_IDS.filter((bookId) => Canon.isBookOT(bookId)),\n NT: ALL_BOOK_IDS.filter((bookId) => Canon.isBookNT(bookId)),\n DC: ALL_BOOK_IDS.filter((bookId) => Canon.isBookDC(bookId)),\n };\n return groupedBooks[bookType];\n};\nconst fetchEndChapter = (bookId: string) => {\n // getChaptersForBook returns -1 if not found in scrBookData\n // scrBookData only includes OT and NT, so all DC will return -1\n return getChaptersForBook(Canon.bookIdToNumber(bookId));\n};\n\n/**\n * Gets all of the English names from book ids\n *\n * @returns String[]\n */\nfunction getAllEnglishNames(): string[] {\n const allEnglishNames = ALL_BOOK_IDS.map((bookId) => {\n return Canon.bookIdToEnglishName(bookId);\n });\n return allEnglishNames;\n}\n\n/**\n * Determines if bookName is in allEnglishNames\n *\n * @param bookName Book English name\n * @returns True if bookName is included, false otherwise\n */\nfunction isValidBookEnglishName(bookName: string): boolean {\n return getAllEnglishNames().includes(bookName);\n}\n\n/**\n * Gets a bookId from given English name\n *\n * @param bookName Book English name\n * @returns BookId of provided bookName, undefined otherwise\n */\nfunction getBookIdFromEnglishName(bookName: string): string | undefined {\n // Convert bookName to lowercase and then capitalize the first letter\n const formattedBookName = bookName.toLowerCase().replace(/^\\w/, (c) => c.toUpperCase());\n\n if (isValidBookEnglishName(formattedBookName)) {\n const matchingBookId = ALL_BOOK_IDS.find((bookId) => {\n return Canon.bookIdToEnglishName(bookId) === formattedBookName;\n });\n return matchingBookId;\n }\n\n return undefined;\n}\n\nfunction BookChapterControl({ scrRef, handleSubmit }: BookChapterControlProps) {\n const [searchQuery, setSearchQuery] = useState('');\n const [selectedBookId, setSelectedBookId] = useState(\n Canon.bookNumberToId(scrRef.bookNum),\n );\n const [highlightedChapter, setHighlightedChapter] = useState(scrRef.chapterNum ?? 0);\n const [highlightedBookId, setHighlightedBookId] = useState(\n Canon.bookNumberToId(scrRef.bookNum),\n );\n const [isContentOpen, setIsContentOpen] = useState(false);\n const [isContentOpenDelayed, setIsContentOpenDelayed] = useState(isContentOpen);\n\n // This ref will always be defined\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const inputRef = useRef(undefined!);\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const contentRef = useRef(undefined!);\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const menuItemRef = useRef(undefined!);\n\n const fetchFilteredBooks = useCallback(\n (bookType: BookType) => {\n return fetchGroupedBooks(bookType).filter((bookId: string) => {\n const englishNameLowerCase = Canon.bookIdToEnglishName(bookId).toLowerCase();\n const normalizedQuery = searchQuery.replace(/[^a-zA-Z]/g, '').toLowerCase();\n return (\n englishNameLowerCase.includes(normalizedQuery) || // Match book name\n bookId.toLowerCase().includes(normalizedQuery) // Match book ID\n );\n });\n },\n [searchQuery],\n );\n\n const handleSearchInput = (searchString: string) => {\n setSearchQuery(searchString);\n };\n\n /**\n * Whether to prevent radix's logic from closing the dropdown. This is important because radix\n * tries to close the dropdown when the input first focuses, and we don't want it to do that. But\n * we don't want to prevent the dropdown from closing when we click away from the input, so we\n * don't want to just keep it open if the input is focused\n */\n const shouldPreventAutoClosing = useRef(false);\n\n const controlMenuState = useCallback((open: boolean) => {\n if (shouldPreventAutoClosing.current) {\n shouldPreventAutoClosing.current = false;\n return;\n }\n setIsContentOpen(open);\n }, []);\n\n const updateReference = useCallback(\n (bookId: string, shouldClose: boolean, chapter?: number, verse?: number) => {\n setHighlightedChapter(\n Canon.bookNumberToId(scrRef.bookNum) !== bookId ? 1 : scrRef.chapterNum,\n );\n\n if (shouldClose || fetchEndChapter(bookId) === -1) {\n handleSubmit({\n bookNum: Canon.bookIdToNumber(bookId),\n chapterNum: chapter || 1,\n verseNum: verse || 1,\n });\n\n setIsContentOpen(false);\n setSearchQuery('');\n return;\n }\n\n setSelectedBookId(selectedBookId !== bookId ? bookId : '');\n setIsContentOpen(!shouldClose);\n },\n [handleSubmit, scrRef.bookNum, scrRef.chapterNum, selectedBookId],\n );\n\n const handleSelectChapter = (chapterNumber: number) => {\n if (chapterNumber <= 0 || chapterNumber > fetchEndChapter(selectedBookId)) {\n return;\n }\n updateReference(selectedBookId, true, chapterNumber);\n };\n\n const handleInputSubmit = useCallback(() => {\n SEARCH_QUERY_FORMATS.forEach((format) => {\n const matches = searchQuery.match(format);\n if (matches) {\n // Book should be a bookId or an english name\n const [book, chapter = undefined, verse = undefined] = matches.slice(1);\n const englishName = getBookIdFromEnglishName(book);\n\n if (Canon.isBookIdValid(book) || englishName) {\n updateReference(\n englishName ?? book,\n true,\n chapter ? parseInt(chapter, 10) : 1,\n verse ? parseInt(verse, 10) : 1,\n );\n }\n }\n });\n }, [updateReference, searchQuery]);\n\n const handleKeyDownInput = useCallback(\n (event: ReactKeyboardEvent) => {\n if (!isContentOpen) {\n setIsContentOpen(true);\n } else if (event.key === 'ArrowDown' || event.key === 'ArrowUp') {\n if (\n typeof menuItemRef !== 'undefined' &&\n // Ref uses null\n // eslint-disable-next-line no-null/no-null\n menuItemRef.current !== null\n ) {\n menuItemRef.current.focus();\n } else if (\n typeof contentRef !== 'undefined' &&\n // Ref uses null\n // eslint-disable-next-line no-null/no-null\n contentRef.current !== null\n ) {\n contentRef.current.focus();\n }\n event.preventDefault();\n }\n },\n [isContentOpen],\n );\n\n const handleKeyDownContent = (event: ReactKeyboardEvent) => {\n // When the dropdown menu has focus, key strokes should give focus to the input component,\n // unless they're navigation keys (arrows and enter)\n const { key } = event;\n if (\n key === 'ArrowRight' ||\n key === 'ArrowLeft' ||\n key === 'ArrowDown' ||\n key === 'ArrowUp' ||\n key === 'Enter'\n ) {\n return;\n }\n\n inputRef.current.dispatchEvent(new KeyboardEvent('keydown', { key }));\n inputRef.current.focus();\n };\n\n const handleKeyDownMenuItem = (event: ReactKeyboardEvent) => {\n const { key } = event;\n if (highlightedBookId === selectedBookId) {\n if (key === 'Enter') {\n event.preventDefault();\n updateReference(selectedBookId, true, highlightedChapter);\n return;\n }\n\n let chapterOffSet = 0;\n if (key === 'ArrowRight') {\n if (highlightedChapter < fetchEndChapter(highlightedBookId)) {\n chapterOffSet = 1;\n } else {\n event.preventDefault();\n return;\n }\n } else if (key === 'ArrowLeft') {\n if (highlightedChapter > 1) {\n chapterOffSet = -1;\n } else {\n event.preventDefault();\n return;\n }\n } else if (key === 'ArrowDown') {\n chapterOffSet = 6;\n } else if (key === 'ArrowUp') {\n chapterOffSet = -6;\n }\n if (\n highlightedChapter + chapterOffSet <= 0 ||\n highlightedChapter + chapterOffSet > fetchEndChapter(highlightedBookId)\n ) {\n setHighlightedChapter(0);\n } else if (chapterOffSet !== 0) {\n setHighlightedChapter(highlightedChapter + chapterOffSet);\n event.preventDefault();\n }\n }\n };\n\n useEffect(() => {\n if (selectedBookId === highlightedBookId) {\n if (selectedBookId === Canon.bookNumberToId(scrRef.bookNum)) {\n setHighlightedChapter(scrRef.chapterNum);\n } else {\n setHighlightedChapter(1);\n }\n } else {\n setHighlightedChapter(0);\n }\n }, [highlightedBookId, scrRef.bookNum, scrRef.chapterNum, selectedBookId]);\n\n // The purpose of these useLayoutEffects and timeout is to delay the scroll just\n // enough so that the refs are defined and available when they are used after the timeout\n useLayoutEffect(() => {\n setIsContentOpenDelayed(isContentOpen);\n }, [isContentOpen]);\n\n useLayoutEffect(() => {\n const scrollTimeout = setTimeout(() => {\n if (isContentOpenDelayed && contentRef.current && menuItemRef.current) {\n const menuItemOffsetTop = menuItemRef.current.offsetTop;\n const scrollPosition = menuItemOffsetTop - SCROLL_OFFSET;\n contentRef.current.scrollTo({ top: scrollPosition, behavior: 'instant' });\n }\n }, 10);\n return () => {\n clearTimeout(scrollTimeout);\n };\n }, [isContentOpenDelayed]);\n\n return (\n
    \n \n \n {\n setSelectedBookId(Canon.bookNumberToId(scrRef.bookNum));\n setHighlightedBookId(Canon.bookNumberToId(scrRef.bookNum));\n setHighlightedChapter(scrRef.chapterNum > 0 ? scrRef.chapterNum : 0);\n setIsContentOpen(true);\n inputRef.current.focus();\n }}\n onFocus={() => {\n // Radix thinks we want to close because the input is being focused. Prevent that\n shouldPreventAutoClosing.current = true;\n }}\n handleSubmit={handleInputSubmit}\n placeholder={`${Canon.bookNumberToEnglishName(scrRef.bookNum)} ${scrRef.chapterNum}:${scrRef.verseNum}`}\n />\n \n \n console.log('sorting')}\n handleLocationHistory={() => console.log('location history')}\n handleBookmarks={() => console.log('bookmarks')}\n />\n {BOOK_TYPE_ARRAY.map(\n (bookType, bookTypeIndex) =>\n fetchFilteredBooks(bookType).length > 0 && (\n
    \n \n {BOOK_TYPE_LABELS[bookType]}\n \n\n {fetchFilteredBooks(bookType).map((bookId) => (\n
    \n updateReference(bookId, false)}\n isSelected={selectedBookId === bookId}\n handleHighlightBook={() => setHighlightedBookId(bookId)}\n handleKeyDown={handleKeyDownMenuItem}\n bookType={bookType}\n ref={(element: HTMLDivElement) => {\n if (selectedBookId === bookId) menuItemRef.current = element;\n }}\n >\n {\n setHighlightedChapter(chapterNumber);\n }}\n />\n \n
    \n ))}\n {BOOK_TYPE_ARRAY.length - 1 !== bookTypeIndex ? (\n \n ) : undefined}\n
    \n ),\n )}\n \n
    \n
    \n );\n}\n\nexport default BookChapterControl;\n","import React from 'react';\nimport { Slot } from '@radix-ui/react-slot';\nimport { cva, type VariantProps } from 'class-variance-authority';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport const buttonVariants = cva(\n 'pr-twp tw-inline-flex tw-items-center tw-justify-center tw-whitespace-nowrap tw-rounded-md tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-colors focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50',\n {\n variants: {\n variant: {\n default: 'tw-bg-primary tw-text-primary-foreground hover:tw-bg-primary/90',\n destructive: 'tw-bg-destructive tw-text-destructive-foreground hover:tw-bg-destructive/90',\n outline:\n 'tw-border tw-border-input tw-bg-background hover:tw-bg-accent hover:tw-text-accent-foreground',\n secondary: 'tw-bg-secondary tw-text-secondary-foreground hover:tw-bg-secondary/80',\n ghost: 'hover:tw-bg-accent hover:tw-text-accent-foreground',\n link: 'tw-text-primary tw-underline-offset-4 hover:tw-underline',\n },\n size: {\n default: 'tw-h-10 tw-px-4 tw-py-2',\n sm: 'tw-h-9 tw-rounded-md tw-px-3',\n lg: 'tw-h-11 tw-rounded-md tw-px-8',\n icon: 'tw-h-10 tw-w-10',\n },\n },\n defaultVariants: {\n variant: 'default',\n size: 'default',\n },\n },\n);\n\nexport interface ButtonProps\n extends React.ButtonHTMLAttributes,\n VariantProps {\n asChild?: boolean;\n}\n\nexport const Button = React.forwardRef(\n ({ className, variant, size, asChild = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'button';\n return (\n \n );\n },\n);\nButton.displayName = 'Button';\n","import React from 'react';\nimport * as LabelPrimitive from '@radix-ui/react-label';\nimport { cva, type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst labelVariants = cva(\n 'tw-text-sm tw-font-medium tw-leading-none peer-disabled:tw-cursor-not-allowed peer-disabled:tw-opacity-70',\n);\n\nexport const Label = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef & VariantProps\n>(({ className, ...props }, ref) => (\n \n));\nLabel.displayName = LabelPrimitive.Root.displayName;\n","import React from 'react';\nimport * as RadioGroupPrimitive from '@radix-ui/react-radio-group';\nimport { Circle } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst RadioGroup = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => {\n return (\n \n );\n});\nRadioGroup.displayName = RadioGroupPrimitive.Root.displayName;\n\nconst RadioGroupItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => {\n return (\n \n \n \n \n \n );\n});\nRadioGroupItem.displayName = RadioGroupPrimitive.Item.displayName;\n\nexport { RadioGroup, RadioGroupItem };\n","import React from 'react';\nimport * as PopoverPrimitive from '@radix-ui/react-popover';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Popover = PopoverPrimitive.Root;\n\nconst PopoverTrigger = PopoverPrimitive.Trigger;\n\nconst PopoverContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, align = 'center', sideOffset = 4, ...props }, ref) => (\n \n \n \n));\nPopoverContent.displayName = PopoverPrimitive.Content.displayName;\n\nexport { Popover, PopoverTrigger, PopoverContent };\n","import React from 'react';\nimport * as DialogPrimitive from '@radix-ui/react-dialog';\nimport { X } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Dialog = DialogPrimitive.Root;\n\nconst DialogTrigger = DialogPrimitive.Trigger;\n\nconst DialogPortal = DialogPrimitive.Portal;\n\nconst DialogClose = DialogPrimitive.Close;\n\nconst DialogOverlay = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nDialogOverlay.displayName = DialogPrimitive.Overlay.displayName;\n\nconst DialogContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, ...props }, ref) => (\n \n \n \n {children}\n \n \n Close\n \n \n \n));\nDialogContent.displayName = DialogPrimitive.Content.displayName;\n\nfunction DialogHeader({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nDialogHeader.displayName = 'DialogHeader';\n\nfunction DialogFooter({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nDialogFooter.displayName = 'DialogFooter';\n\nconst DialogTitle = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nDialogTitle.displayName = DialogPrimitive.Title.displayName;\n\nconst DialogDescription = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nDialogDescription.displayName = DialogPrimitive.Description.displayName;\n\nexport {\n Dialog,\n DialogPortal,\n DialogOverlay,\n DialogClose,\n DialogTrigger,\n DialogContent,\n DialogHeader,\n DialogFooter,\n DialogTitle,\n DialogDescription,\n};\n","import React from 'react';\nimport { type DialogProps } from '@radix-ui/react-dialog';\nimport { Command as CommandPrimitive } from 'cmdk';\nimport { Search } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Dialog, DialogContent } from '@/components/shadcn-ui/dialog';\n\nconst Command = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nCommand.displayName = CommandPrimitive.displayName;\n\ninterface CommandDialogProps extends DialogProps {}\n\nfunction CommandDialog({ children, ...props }: CommandDialogProps) {\n return (\n \n \n \n {children}\n \n \n \n );\n}\n\nconst CommandInput = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n
    \n \n \n
    \n));\n\nCommandInput.displayName = CommandPrimitive.Input.displayName;\n\nconst CommandList = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\n\nCommandList.displayName = CommandPrimitive.List.displayName;\n\nconst CommandEmpty = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>((props, ref) => (\n \n));\n\nCommandEmpty.displayName = CommandPrimitive.Empty.displayName;\n\nconst CommandGroup = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\n\nCommandGroup.displayName = CommandPrimitive.Group.displayName;\n\nconst CommandSeparator = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nCommandSeparator.displayName = CommandPrimitive.Separator.displayName;\n\nconst CommandItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\n\nCommandItem.displayName = CommandPrimitive.Item.displayName;\n\nfunction CommandShortcut({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nCommandShortcut.displayName = 'CommandShortcut';\n\nexport {\n Command,\n CommandDialog,\n CommandInput,\n CommandList,\n CommandEmpty,\n CommandGroup,\n CommandItem,\n CommandShortcut,\n CommandSeparator,\n};\n","import { useState } from 'react';\nimport { Check, ChevronsUpDown } from 'lucide-react';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport { Popover, PopoverContent, PopoverTrigger } from '@/components/shadcn-ui/popover';\nimport {\n Command,\n CommandEmpty,\n CommandInput,\n CommandItem,\n CommandList,\n} from '@/components/shadcn-ui/command';\nimport { PopoverProps } from '@radix-ui/react-popover';\n\nexport type ComboBoxLabelOption = { label: string };\nexport type ComboBoxOption = string | number | ComboBoxLabelOption;\n\nexport type ComboBoxProps = {\n /** Optional unique identifier */\n id?: string;\n /** Text label title for combobox */\n /** List of available options for the dropdown menu */\n options?: readonly T[];\n /** Additional css classes to help with unique styling of the combo box button */\n buttonClassName?: string;\n /** Additional css classes to help with unique styling of the combo box popover */\n popoverContentClassName?: string;\n /**\n * The selected value that the combo box currently holds. Must be shallow equal to one of the\n * options entries.\n */\n value?: T;\n /** Triggers when content of textfield is changed */\n onChange?: (newValue: T) => void;\n /** Used to determine the string value for a given option. */\n getOptionLabel?: (option: ComboBoxOption) => string;\n /** Text displayed on button if `value` is undefined */\n buttonPlaceholder?: string;\n /** Placeholder text for text field */\n textPlaceholder?: string;\n /** Text to display when no options match input */\n commandEmptyMessage?: string;\n /** Variant of button */\n buttonVariant?: ButtonProps['variant'];\n /** Text direction ltr or rtl */\n dir?: Direction;\n /** Optional boolean to set if trigger should be disabled */\n isDisabled?: boolean;\n} & PopoverProps;\n\ntype Direction = 'ltr' | 'rtl';\n\nfunction getOptionLabelDefault(option: ComboBoxOption): string {\n if (typeof option === 'string') {\n return option;\n }\n if (typeof option === 'number') {\n return option.toString();\n }\n return option.label;\n}\n\n/**\n * Autocomplete input and command palette with a list of suggestions.\n *\n * Thanks to Shadcn for heavy inspiration and documentation\n * https://ui.shadcn.com/docs/components/combobox\n */\nfunction ComboBox({\n id,\n options = [],\n buttonClassName,\n popoverContentClassName,\n value,\n onChange = () => {},\n getOptionLabel = getOptionLabelDefault,\n buttonPlaceholder = '',\n textPlaceholder = '',\n commandEmptyMessage = 'No option found',\n buttonVariant = 'outline',\n dir = 'ltr',\n isDisabled = false,\n ...props\n}: ComboBoxProps) {\n const [open, setOpen] = useState(false);\n\n return (\n \n \n \n \n {value ? getOptionLabel(value) : buttonPlaceholder}\n \n \n \n \n \n \n \n {commandEmptyMessage}\n \n {options.map((option) => (\n {\n onChange(option);\n setOpen(false);\n }}\n >\n \n {getOptionLabel(option)}\n \n ))}\n \n \n \n \n );\n}\n\nexport default ComboBox;\n","import { useMemo } from 'react';\nimport ComboBox from '@/components/basics/combo-box.component';\nimport { Label } from '@/components/shadcn-ui/label';\n\nexport type ChapterRangeSelectorProps = {\n startChapter: number;\n endChapter: number;\n handleSelectStartChapter: (chapter: number) => void;\n handleSelectEndChapter: (chapter: number) => void;\n isDisabled?: boolean;\n chapterCount: number;\n};\n\nexport default function ChapterRangeSelector({\n startChapter,\n endChapter,\n handleSelectStartChapter,\n handleSelectEndChapter,\n isDisabled = false,\n chapterCount,\n}: ChapterRangeSelectorProps) {\n const chapterOptions = useMemo(\n () => Array.from({ length: chapterCount }, (_, index) => index + 1),\n [chapterCount],\n );\n\n const onChangeStartChapter = (value: number) => {\n handleSelectStartChapter(value);\n if (value > endChapter) {\n handleSelectEndChapter(value);\n }\n };\n\n const onChangeEndChapter = (value: number) => {\n handleSelectEndChapter(value);\n if (value < startChapter) {\n handleSelectStartChapter(value);\n }\n };\n\n return (\n <>\n \n option.toString()}\n value={startChapter}\n />\n\n \n option.toString()}\n value={endChapter}\n />\n \n );\n}\n","import { Button } from '@/components/shadcn-ui/button';\nimport { Label } from '@/components/shadcn-ui/label';\nimport { RadioGroup, RadioGroupItem } from '@/components/shadcn-ui/radio-group';\nimport { Canon } from '@sillsdev/scripture';\nimport { LocalizedStringValue } from 'platform-bible-utils';\nimport { useState } from 'react';\nimport ChapterRangeSelector, {\n ChapterRangeSelectorProps,\n} from '../basics/chapter-range-selector.component';\n\nexport enum BookSelectionMode {\n CURRENT_BOOK = 'current book',\n CHOOSE_BOOKS = 'choose books',\n}\n\n/**\n * Object containing all keys used for localization in this component. If you're using this\n * component in an extension, you can pass it into the useLocalizedStrings hook to easily obtain the\n * localized strings and pass them into the localizedStrings prop of this component\n */\nexport const BOOK_SELECTOR_STRING_KEYS = Object.freeze([\n '%webView_bookSelector_currentBook%',\n '%webView_bookSelector_choose%',\n '%webView_bookSelector_chooseBooks%',\n] as const);\n\nexport type BookSelectorLocalizedStrings = {\n [localizedInventoryKey in (typeof BOOK_SELECTOR_STRING_KEYS)[number]]?: LocalizedStringValue;\n};\n\n/**\n * Gets the localized value for the provided key\n *\n * @param strings Object containing localized string\n * @param key Key for a localized string\n * @returns The localized value for the provided key, if available. Returns the key if no localized\n * value is available\n */\nconst localizeString = (\n strings: BookSelectorLocalizedStrings,\n key: keyof BookSelectorLocalizedStrings,\n) => {\n return strings[key] ?? key;\n};\n\ntype BookSelectorProps = ChapterRangeSelectorProps & {\n handleBookSelectionModeChange: (newMode: BookSelectionMode) => void;\n currentBookName: string;\n onSelectBooks: () => void;\n selectedBookIds: string[];\n localizedStrings: BookSelectorLocalizedStrings;\n};\n\nexport default function BookSelector({\n handleBookSelectionModeChange,\n currentBookName,\n onSelectBooks,\n selectedBookIds,\n chapterCount,\n endChapter,\n handleSelectEndChapter,\n startChapter,\n handleSelectStartChapter,\n localizedStrings,\n}: BookSelectorProps) {\n const currentBookText = localizeString(localizedStrings, '%webView_bookSelector_currentBook%');\n const chooseText = localizeString(localizedStrings, '%webView_bookSelector_choose%');\n const chooseBooksText = localizeString(localizedStrings, '%webView_bookSelector_chooseBooks%');\n\n const [bookSelectionMode, setBookSelectionMode] = useState(\n BookSelectionMode.CURRENT_BOOK,\n );\n\n const onSelectionModeChange = (newMode: BookSelectionMode) => {\n setBookSelectionMode(newMode);\n handleBookSelectionModeChange(newMode);\n };\n\n return (\n onSelectionModeChange(value as BookSelectionMode)}\n >\n
    \n
    \n
    \n \n \n
    \n \n
    \n \n
    \n
    \n
    \n
    \n \n \n
    \n \n onSelectBooks()}\n >\n {chooseText}\n \n
    \n
    \n \n );\n}\n","import { DropdownMenuTrigger } from '@radix-ui/react-dropdown-menu';\nimport { FilterIcon } from 'lucide-react';\nimport { Table } from '@tanstack/react-table';\n\nimport { Button } from '@/components/shadcn-ui/button';\nimport {\n DropdownMenu,\n DropdownMenuCheckboxItem,\n DropdownMenuContent,\n DropdownMenuLabel,\n DropdownMenuSeparator,\n} from '@/components/shadcn-ui/dropdown-menu';\n\ninterface DataTableViewOptionsProps {\n table: Table;\n}\n\nfunction DataTableViewOptions({ table }: DataTableViewOptionsProps) {\n return (\n \n \n \n \n \n Toggle columns\n \n {table\n .getAllColumns()\n .filter((column) => column.getCanHide())\n .map((column) => {\n return (\n column.toggleVisibility(!!value)}\n >\n {column.id}\n \n );\n })}\n \n \n );\n}\n\nexport default DataTableViewOptions;\n","import React from 'react';\nimport * as SelectPrimitive from '@radix-ui/react-select';\nimport { Check, ChevronDown, ChevronUp } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Select = SelectPrimitive.Root;\n\nconst SelectGroup = SelectPrimitive.Group;\n\nconst SelectValue = SelectPrimitive.Value;\n\nconst SelectTrigger = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, ...props }, ref) => (\n span]:tw-line-clamp-1',\n className,\n )}\n {...props}\n >\n {children}\n \n \n \n \n));\nSelectTrigger.displayName = SelectPrimitive.Trigger.displayName;\n\nconst SelectScrollUpButton = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n));\nSelectScrollUpButton.displayName = SelectPrimitive.ScrollUpButton.displayName;\n\nconst SelectScrollDownButton = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n));\nSelectScrollDownButton.displayName = SelectPrimitive.ScrollDownButton.displayName;\n\nconst SelectContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, position = 'popper', ...props }, ref) => (\n \n \n \n \n {children}\n \n \n \n \n));\nSelectContent.displayName = SelectPrimitive.Content.displayName;\n\nconst SelectLabel = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSelectLabel.displayName = SelectPrimitive.Label.displayName;\n\nconst SelectItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, ...props }, ref) => (\n \n \n \n \n \n \n\n {children}\n \n));\nSelectItem.displayName = SelectPrimitive.Item.displayName;\n\nconst SelectSeparator = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSelectSeparator.displayName = SelectPrimitive.Separator.displayName;\n\nexport {\n Select,\n SelectGroup,\n SelectValue,\n SelectTrigger,\n SelectContent,\n SelectLabel,\n SelectItem,\n SelectSeparator,\n SelectScrollUpButton,\n SelectScrollDownButton,\n};\n","import { ChevronLeftIcon, ChevronRightIcon, ArrowLeftIcon, ArrowRightIcon } from 'lucide-react';\nimport { Table } from '@tanstack/react-table';\n\nimport { Button } from '@/components/shadcn-ui/button';\nimport {\n Select,\n SelectContent,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\n\ninterface DataTablePaginationProps {\n table: Table;\n}\n\nfunction DataTablePagination({ table }: DataTablePaginationProps) {\n return (\n
    \n
    \n
    \n {table.getFilteredSelectedRowModel().rows.length} of{' '}\n {table.getFilteredRowModel().rows.length} row(s) selected\n
    \n
    \n

    Rows per page

    \n {\n table.setPageSize(Number(value));\n }}\n >\n \n \n \n \n {[10, 20, 30, 40, 50].map((pageSize) => (\n \n {pageSize}\n \n ))}\n \n \n
    \n
    \n Page {table.getState().pagination.pageIndex + 1} of {table.getPageCount()}\n
    \n
    \n table.setPageIndex(0)}\n disabled={!table.getCanPreviousPage()}\n >\n Go to first page\n \n \n table.previousPage()}\n disabled={!table.getCanPreviousPage()}\n >\n Go to previous page\n \n \n table.nextPage()}\n disabled={!table.getCanNextPage()}\n >\n Go to next page\n \n \n table.setPageIndex(table.getPageCount() - 1)}\n disabled={!table.getCanNextPage()}\n >\n Go to last page\n \n \n
    \n
    \n
    \n );\n}\n\nexport default DataTablePagination;\n","import React from 'react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Table = React.forwardRef<\n HTMLTableElement,\n React.HTMLAttributes & { stickyHeader?: boolean }\n>(({ className, stickyHeader, ...props }, ref) => (\n
    \n \n
    \n));\nTable.displayName = 'Table';\n\nconst TableHeader = React.forwardRef<\n HTMLTableSectionElement,\n React.HTMLAttributes & { stickyHeader?: boolean }\n>(({ className, stickyHeader, ...props }, ref) => (\n \n));\nTableHeader.displayName = 'TableHeader';\n\nconst TableBody = React.forwardRef<\n HTMLTableSectionElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableBody.displayName = 'TableBody';\n\nconst TableFooter = React.forwardRef<\n HTMLTableSectionElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n tr]:last:tw-border-b-0', className)}\n {...props}\n />\n));\nTableFooter.displayName = 'TableFooter';\n\nconst TableRow = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nTableRow.displayName = 'TableRow';\n\nconst TableHead = React.forwardRef<\n HTMLTableCellElement,\n React.ThHTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableHead.displayName = 'TableHead';\n\nconst TableCell = React.forwardRef<\n HTMLTableCellElement,\n React.TdHTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableCell.displayName = 'TableCell';\n\nconst TableCaption = React.forwardRef<\n HTMLTableCaptionElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableCaption.displayName = 'TableCaption';\n\nexport { Table, TableHeader, TableBody, TableFooter, TableHead, TableRow, TableCell, TableCaption };\n","import { useState } from 'react';\n\nimport {\n ColumnFiltersState,\n flexRender,\n getCoreRowModel,\n getFilteredRowModel,\n getPaginationRowModel,\n getSortedRowModel,\n SortingState,\n ColumnDef as TSColumnDef,\n Row as TSRow,\n RowSelectionState as TSRowSelectionState,\n SortDirection as TSSortDirection,\n Table as TSTable,\n useReactTable,\n VisibilityState,\n} from '@tanstack/react-table';\n\nimport DataTableViewOptions from '@/components/advanced/data-table/data-table-column-toggle.component';\nimport DataTablePagination from '@/components/advanced/data-table/data-table-pagination.component';\nimport { Button } from '@/components/shadcn-ui/button';\nimport {\n Table,\n TableBody,\n TableCell,\n TableHead,\n TableHeader,\n TableRow,\n} from '@/components/shadcn-ui/table';\n\nexport type ColumnDef = TSColumnDef;\nexport type RowContents = TSRow;\nexport type TableContents = TSTable;\nexport type SortDirection = TSSortDirection;\nexport type RowSelectionState = TSRowSelectionState;\n\ninterface DataTableProps {\n columns: ColumnDef[];\n data: TData[];\n enablePagination?: boolean;\n showPaginationControls?: boolean;\n showColumnVisibilityControls?: boolean;\n stickyHeader?: boolean;\n onRowClickHandler?: (row: RowContents, table: TableContents) => void;\n}\n\n/**\n * Feature-rich table component that infuses our basic shadcn-based Table component with features\n * from TanStack's React Table library\n */\nfunction DataTable({\n columns,\n data,\n enablePagination = false,\n showPaginationControls = false,\n showColumnVisibilityControls = false,\n stickyHeader = false,\n onRowClickHandler = () => {},\n}: DataTableProps) {\n const [sorting, setSorting] = useState([]);\n const [columnFilters, setColumnFilters] = useState([]);\n const [columnVisibility, setColumnVisibility] = useState({});\n const [rowSelection, setRowSelection] = useState({});\n\n const table = useReactTable({\n data,\n columns,\n getCoreRowModel: getCoreRowModel(),\n ...(enablePagination && { getPaginationRowModel: getPaginationRowModel() }),\n onSortingChange: setSorting,\n getSortedRowModel: getSortedRowModel(),\n onColumnFiltersChange: setColumnFilters,\n getFilteredRowModel: getFilteredRowModel(),\n onColumnVisibilityChange: setColumnVisibility,\n onRowSelectionChange: setRowSelection,\n state: {\n sorting,\n columnFilters,\n columnVisibility,\n rowSelection,\n },\n });\n\n return (\n
    \n {showColumnVisibilityControls && }\n \n \n {table.getHeaderGroups().map((headerGroup) => (\n \n {headerGroup.headers.map((header) => {\n return (\n \n {header.isPlaceholder\n ? undefined\n : flexRender(header.column.columnDef.header, header.getContext())}\n \n );\n })}\n \n ))}\n \n \n {table.getRowModel().rows?.length ? (\n table.getRowModel().rows.map((row) => (\n onRowClickHandler(row, table)}\n key={row.id}\n data-state={row.getIsSelected() && 'selected'}\n >\n {row.getVisibleCells().map((cell) => (\n \n {flexRender(cell.column.columnDef.cell, cell.getContext())}\n \n ))}\n \n ))\n ) : (\n \n \n No results.\n \n \n )}\n \n
    \n {enablePagination && (\n
    \n table.previousPage()}\n disabled={!table.getCanPreviousPage()}\n >\n Previous\n \n table.nextPage()}\n disabled={!table.getCanNextPage()}\n >\n Next\n \n
    \n )}\n {enablePagination && showPaginationControls && }\n
    \n );\n}\n\nexport default DataTable;\n","import {\n Table,\n TableBody,\n TableCell,\n TableHead,\n TableHeader,\n TableRow,\n} from '@/components/shadcn-ui/table';\nimport { Canon } from '@sillsdev/scripture';\nimport { deepEqual, LanguageStrings, ScriptureReference } from 'platform-bible-utils';\nimport { useMemo } from 'react';\nimport { InventoryItemOccurrence } from './inventory-utils';\n\n/** Props for the OccurrencesTable component */\ntype OccurrencesTableProps = {\n /** Data that contains scriptures references and snippets of scripture */\n occurrenceData: InventoryItemOccurrence[];\n /** Callback function that is executed when the scripture reference is changed */\n setScriptureReference: (scriptureReference: ScriptureReference) => void;\n /**\n * Object with all localized strings that the OccurrencesTable needs to work well across multiple\n * languages\n */\n localizedStrings: LanguageStrings;\n};\n\n/**\n * Table that shows occurrences of specified inventory item(s). The first column shows the related\n * scripture reference. The second column shows the snippet of scripture that contains the specified\n * inventory item\n */\nfunction OccurrencesTable({\n occurrenceData,\n setScriptureReference,\n localizedStrings,\n}: OccurrencesTableProps) {\n const referenceHeaderText =\n localizedStrings['%webView_inventory_occurrences_table_header_reference%'];\n const occurrenceHeaderText =\n localizedStrings['%webView_inventory_occurrences_table_header_occurrence%'];\n\n const occurrences: InventoryItemOccurrence[] = useMemo(() => {\n const uniqueOccurrences: InventoryItemOccurrence[] = [];\n\n occurrenceData.forEach((occurrence) => {\n if (!uniqueOccurrences.some((uniqueOccurrence) => deepEqual(uniqueOccurrence, occurrence))) {\n uniqueOccurrences.push(occurrence);\n }\n });\n\n return uniqueOccurrences;\n }, [occurrenceData]);\n\n return (\n \n \n \n {referenceHeaderText}\n {occurrenceHeaderText}\n \n \n \n {occurrences.length > 0 &&\n occurrences.map((occurrence) => (\n {\n setScriptureReference(occurrence.reference);\n }}\n >\n {`${Canon.bookNumberToEnglishName(occurrence.reference.bookNum)} ${occurrence.reference.chapterNum}:${occurrence.reference.verseNum}`}\n {occurrence.text}\n \n ))}\n \n
    \n );\n}\n\nexport default OccurrencesTable;\n","import React from 'react';\nimport * as CheckboxPrimitive from '@radix-ui/react-checkbox';\nimport { Check } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Checkbox = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n \n \n));\nCheckbox.displayName = CheckboxPrimitive.Root.displayName;\n\nexport default Checkbox;\n","import { Canon } from '@sillsdev/scripture';\nimport { ScriptureReference } from 'platform-bible-utils';\n\n/* #region Types */\n\n/**\n * Status of items that appear in inventories. 'approved' and 'unapproved' items are defined in the\n * project's `Settings.xml`. All other items are defined as 'unknown'\n */\nexport type Status = 'approved' | 'unapproved' | 'unknown';\n\n/** Occurrence of item in inventory. Primarily used by table that shows occurrences */\nexport type InventoryItemOccurrence = {\n /** Reference to scripture where the item appears */\n reference: ScriptureReference;\n /** Snippet of scripture that contains the occurrence */\n text: string;\n};\n\n/** Data structure that contains all information on an item that is shown in an inventory */\nexport type InventoryTableData = {\n /**\n * The item (e.g. a character in the characters inventory, a marker in the marker inventory) In\n * most cases the array will only have one element. In case of additional items (e.g. the\n * preceding marker in the markers check), the primary item should be stored in the first index.\n * To show additional items in the inventory, make sure to configure the `additionalItemsLabels`\n * prop for the Inventory component\n */\n items: string[];\n /** The number of times this item occurs in the selected scope */\n count: number;\n /** The status of this item (see documentation for `Status` type for more information) */\n status: Status;\n /** Occurrences of this item in the scripture text for the selected scope */\n occurrences: InventoryItemOccurrence[];\n};\n\n/* #endregion */\n\n/* #region Functions */\n\n/**\n * Splits USFM string into shorter line-like segments\n *\n * @param text A single (likely very large) USFM string\n * @returns An array containing the input text, split into shorter segments\n */\nexport const getLinesFromUSFM = (text: string) => {\n // Splits on (CR)LF, CR, \\v, \\c and \\id\n return text.split(/(?:\\r?\\n|\\r)|(?=(?:\\\\(?:v|c|id)))/g);\n};\n\n/**\n * Extracts chapter or verse number from USFM strings that start with a \\c or \\v marker\n *\n * @param text USFM string that is expected to start with \\c or \\v marker\n * @returns Chapter or verse number if one is found. Else returns 0.\n */\nexport const getNumberFromUSFM = (text: string): number | undefined => {\n // Captures all digits that follow \\v or \\c markers followed by whitespace located at the start of a string\n const regex = /^\\\\[vc]\\s+(\\d+)/;\n const match = text.match(regex);\n\n if (match) {\n return +match[1];\n }\n return undefined;\n};\n\n/**\n * Gets book ID from USFM string that starts with the \\id marker, and returns book number for it\n *\n * @param text USFM string that is expected to start with \\id marker\n * @returns Book number corresponding to the \\id marker in the input text. Returns 0 if no marker is\n * found or the marker is not valid\n */\nexport const getBookNumFromId = (text: string): number => {\n // Captures all digits that follow an \\id marker followed by whitespace located at the start of a string\n const match = text.match(/^\\\\id\\s+([A-Za-z]+)/);\n if (match) {\n return Canon.bookIdToNumber(match[1]);\n }\n return 0;\n};\n\n/**\n * Gets the status for an item, typically used in the Inventory component\n *\n * @param item The item for which the status is being requested\n * @param approvedItems Array of approved items, typically as defined in `Settings.xml`\n * @param unapprovedItems Array of unapproved items, typically as defined in `Settings.xml`\n * @returns The status for the specified item\n */\nexport const getStatusForItem = (\n item: string,\n approvedItems: string[],\n unapprovedItems: string[],\n): Status => {\n if (unapprovedItems.includes(item)) return 'unapproved';\n if (approvedItems.includes(item)) return 'approved';\n return 'unknown';\n};\n\n/* #endregion */\n","import React from 'react';\nimport * as TogglePrimitive from '@radix-ui/react-toggle';\nimport { cva, type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst toggleVariants = cva(\n 'pr-twp tw-inline-flex tw-items-center tw-justify-center tw-rounded-md tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-colors hover:tw-bg-muted hover:tw-text-muted-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50 data-[state=on]:tw-bg-accent data-[state=on]:tw-text-accent-foreground',\n {\n variants: {\n variant: {\n default: 'tw-bg-transparent',\n outline:\n 'tw-border tw-border-input tw-bg-transparent hover:tw-bg-accent hover:tw-text-accent-foreground',\n },\n size: {\n default: 'tw-h-10 tw-px-3',\n sm: 'tw-h-9 tw-px-2.5',\n lg: 'tw-h-11 tw-px-5',\n },\n },\n defaultVariants: {\n variant: 'default',\n size: 'default',\n },\n },\n);\n\nconst Toggle = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef & VariantProps\n>(({ className, variant, size, ...props }, ref) => (\n \n));\n\nToggle.displayName = TogglePrimitive.Root.displayName;\n\nexport { Toggle, toggleVariants };\n","import React from 'react';\nimport * as ToggleGroupPrimitive from '@radix-ui/react-toggle-group';\nimport { type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { toggleVariants } from '@/components/shadcn-ui/toggle';\n\nconst ToggleGroupContext = React.createContext>({\n size: 'default',\n variant: 'default',\n});\n\nconst ToggleGroup = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef &\n VariantProps\n>(({ className, variant, size, children, ...props }, ref) => (\n \n \n {children}\n \n \n));\n\nToggleGroup.displayName = ToggleGroupPrimitive.Root.displayName;\n\nconst ToggleGroupItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef &\n VariantProps\n>(({ className, children, variant, size, ...props }, ref) => {\n const context = React.useContext(ToggleGroupContext);\n\n return (\n \n {children}\n \n );\n});\n\nToggleGroupItem.displayName = ToggleGroupPrimitive.Item.displayName;\n\nexport { ToggleGroup, ToggleGroupItem };\n","import { ColumnDef, SortDirection } from '@/components/advanced/data-table/data-table.component';\nimport { Button } from '@/components/shadcn-ui/button';\nimport { ToggleGroup, ToggleGroupItem } from '@/components/shadcn-ui/toggle-group';\nimport {\n ArrowDownIcon,\n ArrowUpDownIcon,\n ArrowUpIcon,\n CircleCheckIcon,\n CircleHelpIcon,\n CircleXIcon,\n} from 'lucide-react';\nimport { ReactNode } from 'react';\nimport { InventoryTableData, Status } from './inventory-utils';\n\n/**\n * Gets an icon that indicates the current sorting direction based on the provided input\n *\n * @param sortDirection Sorting direction. Can be ascending ('asc'), descending ('desc') or false (\n * i.e. not sorted)\n * @returns The appropriate sorting icon for the provided sorting direction\n */\nconst getSortingIcon = (sortDirection: false | SortDirection): ReactNode => {\n if (sortDirection === 'asc') {\n return ;\n }\n if (sortDirection === 'desc') {\n return ;\n }\n return ;\n};\n\n/**\n * Function that creates the item column for inventories\n *\n * @param itemLabel Localized label for the item column (e.g. 'Character', 'Repeated Word', etc.)\n * @returns Column that shows the inventory items. Should be used with the DataTable component\n */\nexport const inventoryItemColumn = (itemLabel: string): ColumnDef => {\n return {\n accessorKey: 'item',\n accessorFn: (row: InventoryTableData) => row.items[0],\n header: ({ column }) => (\n \n ),\n };\n};\n\n/**\n * Function that creates the additional item columns for inventories\n *\n * @param additionalItemLabel Localized label for the additional item column (e.g. 'Preceding\n * Marker')\n * @param additionalItemIndex Index that locates the desired item in the items array of the\n * inventory\n * @returns Column that shows additional inventory items. Should be used with the DataTable\n * component\n */\nexport const inventoryAdditionalItemColumn = (\n additionalItemLabel: string,\n additionalItemIndex: number,\n): ColumnDef => {\n return {\n accessorKey: `item${additionalItemIndex}`,\n accessorFn: (row: InventoryTableData) => row.items[additionalItemIndex],\n header: ({ column }) => (\n \n ),\n };\n};\n\n/**\n * Function that creates the count column for inventories. Should be used with the DataTable\n * component.\n *\n * @param itemLabel Localized label for the count column\n * @returns Column that shows the number of occurrences of the related inventory items\n */\nexport const inventoryCountColumn = (countLabel: string): ColumnDef => {\n return {\n accessorKey: 'count',\n header: ({ column }) => (\n
    \n \n
    \n ),\n cell: ({ row }) =>
    {row.getValue('count')}
    ,\n };\n};\n\n/**\n * Function that updates project settings when status for item(s) changes\n *\n * @param changedItems Array of items for which the status is being updated\n * @param newStatus The status that the items are being given\n * @param approvedItems Array of currently approved items\n * @param onApprovedItemsChange Callback function that stores the updated list of approved items\n * @param unapprovedItems Array of currently unapproved items\n * @param onUnapprovedItemsChange Callback function that stores the updated list of unapproved items\n */\nconst statusChangeHandler = (\n changedItems: string[],\n newStatus: Status,\n approvedItems: string[],\n onApprovedItemsChange: (items: string[]) => void,\n unapprovedItems: string[],\n onUnapprovedItemsChange: (items: string[]) => void,\n) => {\n let newApprovedItems: string[] = [...approvedItems];\n changedItems.forEach((item) => {\n if (newStatus === 'approved') {\n if (!newApprovedItems.includes(item)) {\n newApprovedItems.push(item);\n }\n } else {\n newApprovedItems = newApprovedItems.filter((validItem) => validItem !== item);\n }\n });\n onApprovedItemsChange(newApprovedItems);\n\n let newUnapprovedItems: string[] = [...unapprovedItems];\n changedItems.forEach((item) => {\n if (newStatus === 'unapproved') {\n if (!newUnapprovedItems.includes(item)) {\n newUnapprovedItems.push(item);\n }\n } else {\n newUnapprovedItems = newUnapprovedItems.filter((unapprovedItem) => unapprovedItem !== item);\n }\n });\n onUnapprovedItemsChange(newUnapprovedItems);\n};\n\n/**\n * Function that creates the status column for inventories. Should be used with the DataTable\n * component.\n *\n * @param statusLabel Localized label for the status column\n * @param approvedItems Array of approved items, typically as defined in `Settings.xml`\n * @param onApprovedItemsChange Callback function that stores the updated list of approved items\n * @param unapprovedItems Array of unapproved items, typically as defined in `Settings.xml`\n * @param onUnapprovedItemsChange Callback function that stores the updated list of unapproved items\n * @returns Column that shows the status buttons for the related inventory item. The button for the\n * current status of the item is selected\n */\nexport const inventoryStatusColumn = (\n statusLabel: string,\n approvedItems: string[],\n onApprovedItemsChange: (items: string[]) => void,\n unapprovedItems: string[],\n onUnapprovedItemsChange: (items: string[]) => void,\n): ColumnDef => {\n return {\n accessorKey: 'status',\n header: ({ column }) => {\n return (\n
    \n \n
    \n );\n },\n cell: ({ row }) => {\n const status: Status = row.getValue('status');\n const item: string = row.getValue('item');\n return (\n \n \n statusChangeHandler(\n [item],\n 'approved',\n approvedItems,\n onApprovedItemsChange,\n unapprovedItems,\n onUnapprovedItemsChange,\n )\n }\n value=\"approved\"\n >\n \n \n \n statusChangeHandler(\n [item],\n 'unapproved',\n approvedItems,\n onApprovedItemsChange,\n unapprovedItems,\n onUnapprovedItemsChange,\n )\n }\n value=\"unapproved\"\n >\n \n \n \n statusChangeHandler(\n [item],\n 'unknown',\n approvedItems,\n onApprovedItemsChange,\n unapprovedItems,\n onUnapprovedItemsChange,\n )\n }\n value=\"unknown\"\n >\n \n \n \n );\n },\n };\n};\n","import DataTable, {\n ColumnDef,\n RowContents,\n RowSelectionState,\n TableContents,\n} from '@/components/advanced/data-table/data-table.component';\nimport OccurrencesTable from '@/components/advanced/inventory/occurrences-table.component';\nimport Checkbox from '@/components/shadcn-ui/checkbox';\nimport { Input } from '@/components/shadcn-ui/input';\nimport { Label } from '@/components/shadcn-ui/label';\nimport {\n Select,\n SelectContent,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\nimport {\n deepEqual,\n LocalizedStringValue,\n ScriptureReference,\n substring,\n} from 'platform-bible-utils';\nimport { useEffect, useMemo, useState } from 'react';\nimport {\n getBookNumFromId,\n getLinesFromUSFM,\n getNumberFromUSFM,\n getStatusForItem,\n InventoryItemOccurrence,\n InventoryTableData,\n Status,\n} from './inventory-utils';\nimport { inventoryAdditionalItemColumn } from './inventory-columns';\n\n/**\n * Object containing all keys used for localization in this component. If you're using this\n * component in an extension, you can pass it into the useLocalizedStrings hook to easily obtain the\n * localized strings and pass them into the localizedStrings prop of this component\n */\nexport const INVENTORY_STRING_KEYS = Object.freeze([\n '%webView_inventory_all%',\n '%webView_inventory_approved%',\n '%webView_inventory_unapproved%',\n '%webView_inventory_unknown%',\n '%webView_inventory_scope_currentBook%',\n '%webView_inventory_scope_chapter%',\n '%webView_inventory_scope_verse%',\n '%webView_inventory_filter_text%',\n '%webView_inventory_show_additional_items%',\n '%webView_inventory_occurrences_table_header_reference%',\n '%webView_inventory_occurrences_table_header_occurrence%',\n] as const);\n\nexport type InventoryLocalizedStrings = {\n [localizedInventoryKey in (typeof INVENTORY_STRING_KEYS)[number]]?: LocalizedStringValue;\n};\n\n/** Scope of scripture that the inventory can operate on */\nexport type Scope = 'book' | 'chapter' | 'verse';\n\n/** Status values that the status filter can select from */\ntype StatusFilter = Status | 'all';\n\n/** Text labels for the inventory columns and the control components of additional inventory items */\ntype AdditionalItemsLabels = {\n checkboxText?: string;\n tableHeaders?: string[];\n};\n\n/**\n * Filters data that is shown in the DataTable section of the Inventory\n *\n * @param itemData All inventory items and their related information\n * @param statusFilter Allows filtering by status (i.e. show all items, or only items that are\n * 'approved', 'unapproved' or 'unknown')\n * @param textFilter Allows filtering by text. All items that include the filter text will be\n * selected.\n * @returns Array of items and their related information that are matched by the specified filters\n */\nconst filterItemData = (\n itemData: InventoryTableData[],\n statusFilter: StatusFilter,\n textFilter: string,\n): InventoryTableData[] => {\n let filteredItemData: InventoryTableData[] = itemData;\n\n if (statusFilter !== 'all') {\n filteredItemData = filteredItemData.filter(\n (item) =>\n (statusFilter === 'approved' && item.status === 'approved') ||\n (statusFilter === 'unapproved' && item.status === 'unapproved') ||\n (statusFilter === 'unknown' && item.status === 'unknown'),\n );\n }\n\n if (textFilter !== '')\n filteredItemData = filteredItemData.filter((item) => item.items[0].includes(textFilter));\n\n return filteredItemData;\n};\n\n/**\n * Turns array of strings into array of inventory items, along with their count and status\n *\n * @param text The source scripture text that is searched for inventory items\n * @param scriptureRef The scripture reference that the application is currently set to\n * @param approvedItems Array of approved items, typically as defined in `Settings.xml`\n * @param unapprovedItems Array of unapproved items, typically as defined in `Settings.xml`\n * @param itemRegex Regular expression that describes what items this Inventory should extract from\n * the provided scripture text\n * @returns Array of inventory items, along with their count and status\n */\nconst createTableData = (\n text: string | undefined,\n scriptureRef: ScriptureReference,\n approvedItems: string[],\n unapprovedItems: string[],\n itemRegex: RegExp,\n): InventoryTableData[] => {\n if (!text) return [];\n\n const tableData: InventoryTableData[] = [];\n\n let currentBook: number | undefined = scriptureRef.bookNum;\n let currentChapter: number | undefined = scriptureRef.chapterNum;\n let currentVerse: number | undefined = scriptureRef.verseNum;\n\n const lines = getLinesFromUSFM(text);\n\n lines.forEach((line: string) => {\n if (line.startsWith('\\\\id')) {\n currentBook = getBookNumFromId(line);\n currentChapter = 0;\n currentVerse = 0;\n }\n if (line.startsWith('\\\\c')) {\n currentChapter = getNumberFromUSFM(line);\n currentVerse = 0;\n }\n if (line.startsWith('\\\\v')) {\n currentVerse = getNumberFromUSFM(line);\n if (currentChapter === 0) {\n currentChapter = scriptureRef.chapterNum;\n }\n }\n\n let match: RegExpExecArray | undefined = itemRegex.exec(line) ?? undefined;\n while (match) {\n const items: string[] = [];\n match.forEach((item) => items.push(item));\n const itemIndex = match.index;\n const existingItem = tableData.find((tableEntry) => deepEqual(tableEntry.items, items));\n const newReference: InventoryItemOccurrence = {\n reference: {\n bookNum: currentBook !== undefined ? currentBook : -1,\n chapterNum: currentChapter !== undefined ? currentChapter : -1,\n verseNum: currentVerse !== undefined ? currentVerse : -1,\n },\n text: substring(line, Math.max(0, itemIndex - 25), Math.min(itemIndex + 25, line.length)),\n };\n if (existingItem) {\n existingItem.count += 1;\n existingItem.occurrences.push(newReference);\n } else {\n const newItem: InventoryTableData = {\n items,\n count: 1,\n status: getStatusForItem(items[0], approvedItems, unapprovedItems),\n occurrences: [newReference],\n };\n tableData.push(newItem);\n }\n\n match = itemRegex.exec(line) ?? undefined;\n }\n });\n\n return tableData;\n};\n\n/**\n * Gets the localized value for the provided key\n *\n * @param strings Object containing localized string\n * @param key Key for a localized string\n * @returns The localized value for the provided key, if available. Returns the key if no localized\n * value is available\n */\nconst localizeString = (\n strings: InventoryLocalizedStrings,\n key: keyof InventoryLocalizedStrings,\n) => {\n return strings[key] ?? key;\n};\n\n/** Props for the Inventory component */\ntype InventoryProps = {\n /** The scripture reference that the application is currently set to */\n scriptureReference: ScriptureReference;\n /** Callback function that is executed when the scripture reference is changed */\n setScriptureReference: (scriptureReference: ScriptureReference) => void;\n /**\n * Object with all localized strings that the Inventory needs to work well across multiple\n * languages. When using this component with Platform.Bible, you can import\n * `INVENTORY_STRING_KEYS` from this library, pass it in to the Platform's localization hook, and\n * pass the localized keys that are returned by the hook into this prop.\n */\n localizedStrings: InventoryLocalizedStrings;\n /**\n * The logic that finds the desired items in the source text. This can either be a Regular\n * expression that captures one or multiple items (preferred), or a custom function that builds\n * and return an InventoryDataTable[] manually. Note: In case the logic captures more than one\n * item (i.e. InventoryTableData.items has a length greater than 1), you must provide text labels\n * for the related columns and control elements to show by setting the `additionalItemsLabels`\n * prop\n */\n extractItems:\n | RegExp\n | ((\n text: string | undefined,\n scriptureRef: ScriptureReference,\n approvedItems: string[],\n unapprovedItems: string[],\n ) => InventoryTableData[]);\n /**\n * Text labels for control elements and additional column headers in case your Inventory has more\n * than one item to show (e.g. The 'Preceding Marker' in the Markers Inventory)\n */\n additionalItemsLabels?: AdditionalItemsLabels;\n /** Array of approved items, typically as defined in `Settings.xml` */\n approvedItems: string[];\n /** Array of unapproved items, typically as defined in `Settings.xml` */\n unapprovedItems: string[];\n /** The source scripture text that is searched for in inventory items */\n text: string | undefined;\n /** Scope of scripture that the inventory will operate on */\n scope: Scope;\n /** Callback function that is executed when the scope is changed from the Inventory */\n onScopeChange: (scope: Scope) => void;\n /**\n * Column definitions for the Inventory data table. The most commonly used column definitions are\n * pre-configured for your convenience and can be imported (e.g. inventoryItemColumn,\n * inventoryAdditionalItemColumn inventoryCountColumn, and inventoryStatusColumn). If you need any\n * other columns you can add these yourself\n */\n columns: ColumnDef[];\n};\n\n/** Inventory component that is used to view and control the status of provided project settings */\nexport default function Inventory({\n scriptureReference,\n setScriptureReference,\n localizedStrings,\n extractItems,\n additionalItemsLabels,\n approvedItems,\n unapprovedItems,\n text,\n scope,\n onScopeChange,\n columns,\n}: InventoryProps) {\n const allItemsText = localizeString(localizedStrings, '%webView_inventory_all%');\n const approvedItemsText = localizeString(localizedStrings, '%webView_inventory_approved%');\n const unapprovedItemsText = localizeString(localizedStrings, '%webView_inventory_unapproved%');\n const unknownItemsText = localizeString(localizedStrings, '%webView_inventory_unknown%');\n const scopeBookText = localizeString(localizedStrings, '%webView_inventory_scope_currentBook%');\n const scopeChapterText = localizeString(localizedStrings, '%webView_inventory_scope_chapter%');\n const scopeVerseText = localizeString(localizedStrings, '%webView_inventory_scope_verse%');\n const filterText = localizeString(localizedStrings, '%webView_inventory_filter_text%');\n const showAdditionalItemsText = localizeString(\n localizedStrings,\n '%webView_inventory_show_additional_items%',\n );\n\n const [showAdditionalItems, setShowAdditionalItems] = useState(false);\n const [statusFilter, setStatusFilter] = useState('all');\n const [textFilter, setTextFilter] = useState('');\n const [selectedItem, setSelectedItem] = useState([]);\n\n const tableData: InventoryTableData[] = useMemo(() => {\n if (!text) return [];\n if (extractItems instanceof RegExp)\n return createTableData(\n text,\n scriptureReference,\n approvedItems,\n unapprovedItems,\n extractItems,\n );\n return extractItems(text, scriptureReference, approvedItems, unapprovedItems);\n }, [text, extractItems, scriptureReference, approvedItems, unapprovedItems]);\n\n const reducedTableData: InventoryTableData[] = useMemo(() => {\n if (showAdditionalItems) return tableData;\n\n const newTableData: InventoryTableData[] = [];\n\n tableData.forEach((tableEntry) => {\n const firstItem = tableEntry.items[0];\n\n const existingEntry = newTableData.find(\n (newTableEntry) => newTableEntry.items[0] === firstItem,\n );\n\n if (existingEntry) {\n existingEntry.count += tableEntry.count;\n existingEntry.occurrences = existingEntry.occurrences.concat(tableEntry.occurrences);\n } else {\n newTableData.push({\n items: [firstItem],\n count: tableEntry.count,\n occurrences: tableEntry.occurrences,\n status: tableEntry.status,\n });\n }\n });\n\n return newTableData;\n }, [showAdditionalItems, tableData]);\n\n const filteredTableData: InventoryTableData[] = useMemo(() => {\n return filterItemData(reducedTableData, statusFilter, textFilter);\n }, [reducedTableData, statusFilter, textFilter]);\n\n const allColumns: ColumnDef[] = useMemo(() => {\n if (!showAdditionalItems) return columns;\n\n const numberOfAdditionalItems = additionalItemsLabels?.tableHeaders?.length;\n if (!numberOfAdditionalItems) return columns;\n\n const additionalColumns: ColumnDef[] = [];\n\n for (let index = 0; index < numberOfAdditionalItems; index++) {\n additionalColumns.push(\n inventoryAdditionalItemColumn(\n additionalItemsLabels?.tableHeaders?.[index] || 'Additional Item',\n index + 1,\n ),\n );\n }\n\n return [...additionalColumns, ...columns];\n }, [additionalItemsLabels?.tableHeaders, columns, showAdditionalItems]);\n\n useEffect(() => {\n setSelectedItem([]);\n }, [filteredTableData]);\n\n const rowClickHandler = (\n row: RowContents,\n table: TableContents,\n ) => {\n table.setRowSelection(() => {\n const newSelection: RowSelectionState = {};\n newSelection[row.index] = true;\n return newSelection;\n });\n\n setSelectedItem(row.original.items);\n };\n\n const handleScopeChange = (value: string) => {\n if (value === 'book' || value === 'chapter' || value === 'verse') {\n onScopeChange(value);\n } else {\n throw new Error(`Invalid scope value: ${value}`);\n }\n };\n\n const handleStatusFilterChange = (value: string) => {\n if (value === 'all' || value === 'approved' || value === 'unapproved' || value === 'unknown') {\n setStatusFilter(value);\n } else {\n throw new Error(`Invalid status filter value: ${value}`);\n }\n };\n\n const occurrenceData: InventoryItemOccurrence[] = useMemo(() => {\n if (reducedTableData.length === 0 || selectedItem.length === 0) return [];\n const occurrence = reducedTableData.filter((tableEntry: InventoryTableData) => {\n return deepEqual(\n showAdditionalItems ? tableEntry.items : [tableEntry.items[0]],\n selectedItem,\n );\n });\n if (occurrence.length > 1) throw new Error('Selected item is not unique');\n return occurrence[0].occurrences;\n }, [selectedItem, showAdditionalItems, reducedTableData]);\n\n return (\n
    \n
    \n handleStatusFilterChange(value)}\n defaultValue={statusFilter}\n >\n \n \n \n \n {allItemsText}\n {approvedItemsText}\n {unapprovedItemsText}\n {unknownItemsText}\n \n \n \n {\n setTextFilter(event.target.value);\n }}\n />\n {additionalItemsLabels && (\n
    \n {\n setSelectedItem([]);\n setShowAdditionalItems(checked);\n }}\n />\n \n
    \n )}\n
    \n
    \n \n
    \n {occurrenceData.length > 0 && (\n
    \n \n
    \n )}\n
    \n );\n}\n","import { Input } from '@/components/shadcn-ui/input';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { useState } from 'react';\n\nexport type SearchBarProps = {\n className?: string;\n /**\n * Callback fired to handle the search query when button pressed\n *\n * @param searchQuery\n */\n onSearch: (searchQuery: string) => void;\n\n /** Optional string that appears in the search bar without a search string */\n placeholder?: string;\n\n /** Optional boolean to set the input base to full width */\n isFullWidth?: boolean;\n};\n\nexport default function SearchBar({\n className,\n onSearch,\n placeholder,\n isFullWidth,\n}: SearchBarProps) {\n const [searchQuery, setSearchQuery] = useState('');\n\n const handleInputChange = (searchString: string) => {\n setSearchQuery(searchString);\n onSearch(searchString);\n };\n\n return (\n handleInputChange(e.target.value)}\n />\n );\n}\n","// adapted from: https://github.com/shadcn-ui/ui/discussions/752\n\n'use client';\n\nimport { TabsContentProps, TabsListProps, TabsTriggerProps } from '@/components/shadcn-ui/tabs';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport * as TabsPrimitive from '@radix-ui/react-tabs';\nimport React from 'react';\n\nexport type VerticalTabsProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport type LeftTabsTriggerProps = TabsTriggerProps & {\n value: string;\n ref?: React.Ref;\n};\n\nexport const VerticalTabs = React.forwardRef<\n React.ElementRef,\n VerticalTabsProps\n>(({ className, ...props }, ref) => (\n \n));\n\nVerticalTabs.displayName = TabsPrimitive.List.displayName;\n\nexport const VerticalTabsList = React.forwardRef<\n React.ElementRef,\n TabsListProps\n>(({ className, ...props }, ref) => (\n \n));\nVerticalTabsList.displayName = TabsPrimitive.List.displayName;\n\nexport const VerticalTabsTrigger = React.forwardRef<\n React.ElementRef,\n LeftTabsTriggerProps\n>(({ className, ...props }, ref) => (\n \n));\n\nexport const VerticalTabsContent = React.forwardRef<\n React.ElementRef,\n TabsContentProps\n>(({ className, ...props }, ref) => (\n \n));\nVerticalTabsContent.displayName = TabsPrimitive.Content.displayName;\n","import SearchBar from '@/components/basics/search-bar.component';\nimport {\n VerticalTabs,\n VerticalTabsContent,\n VerticalTabsList,\n VerticalTabsTrigger,\n} from '@/components/basics/tabs-vertical';\nimport { ReactNode } from 'react';\n\nexport type TabKeyValueContent = {\n key: string;\n value: string;\n content: ReactNode;\n};\n\nexport type TabNavigationContentSearchProps = {\n /** List of values and keys for each tab this component should provide */\n tabList: TabKeyValueContent[];\n\n /** Handler to run when the value of the search bar changes */\n onSearch: (searchQuery: string) => void;\n\n /** Optional placeholder for the search bar */\n searchPlaceholder?: string;\n\n /** Optional title to include in the header */\n headerTitle?: string;\n\n /** Optional flag to make the search bar appear full width */\n isSearchBarFullWidth?: boolean;\n\n /** Text direction ltr or rtl */\n direction?: 'ltr' | 'rtl';\n};\n\nexport default function TabNavigationContentSearch({\n tabList,\n onSearch,\n searchPlaceholder,\n headerTitle,\n isSearchBarFullWidth = false,\n direction = 'ltr',\n}: TabNavigationContentSearchProps) {\n return (\n
    \n
    \n {headerTitle ?

    {headerTitle}

    : ''}\n \n
    \n \n \n {tabList.map((tab) => (\n \n {tab.value}\n \n ))}\n \n {tabList.map((tab) => (\n \n {tab.content}\n \n ))}\n \n
    \n );\n}\n","import React from 'react';\nimport * as SeparatorPrimitive from '@radix-ui/react-separator';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Separator = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, orientation = 'horizontal', decorative = true, ...props }, ref) => (\n \n));\nSeparator.displayName = SeparatorPrimitive.Root.displayName;\n\nexport { Separator };\n","'use client';\n\nimport * as React from 'react';\nimport * as SheetPrimitive from '@radix-ui/react-dialog';\nimport { cva, type VariantProps } from 'class-variance-authority';\nimport { X } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Sheet = SheetPrimitive.Root;\n\nconst SheetTrigger = SheetPrimitive.Trigger;\n\nconst SheetClose = SheetPrimitive.Close;\n\nconst SheetPortal = SheetPrimitive.Portal;\n\nconst SheetOverlay = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSheetOverlay.displayName = SheetPrimitive.Overlay.displayName;\n\nconst sheetVariants = cva(\n 'pr-twp tw-fixed tw-z-50 tw-gap-4 tw-bg-background tw-p-6 tw-shadow-lg tw-transition tw-ease-in-out data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-duration-300 data-[state=open]:tw-duration-500',\n {\n variants: {\n side: {\n top: 'tw-inset-x-0 tw-top-0 tw-border-b data-[state=closed]:tw-slide-out-to-top data-[state=open]:tw-slide-in-from-top',\n bottom:\n 'tw-inset-x-0 tw-bottom-0 tw-border-t data-[state=closed]:tw-slide-out-to-bottom data-[state=open]:tw-slide-in-from-bottom',\n left: 'tw-inset-y-0 tw-left-0 tw-h-full tw-w-3/4 tw-border-r data-[state=closed]:tw-slide-out-to-left data-[state=open]:tw-slide-in-from-left sm:tw-max-w-sm',\n right:\n 'tw-inset-y-0 tw-right-0 tw-h-full tw-w-3/4 tw- tw-border-l data-[state=closed]:tw-slide-out-to-right data-[state=open]:tw-slide-in-from-right sm:tw-max-w-sm',\n },\n },\n defaultVariants: {\n side: 'right',\n },\n },\n);\n\ninterface SheetContentProps\n extends React.ComponentPropsWithoutRef,\n VariantProps {}\n\nconst SheetContent = React.forwardRef<\n React.ElementRef,\n SheetContentProps\n>(({ side = 'right', className, children, ...props }, ref) => (\n \n \n \n {children}\n \n \n Close\n \n \n \n));\nSheetContent.displayName = SheetPrimitive.Content.displayName;\n\nfunction SheetHeader({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nSheetHeader.displayName = 'SheetHeader';\n\nfunction SheetFooter({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nSheetFooter.displayName = 'SheetFooter';\n\nconst SheetTitle = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSheetTitle.displayName = SheetPrimitive.Title.displayName;\n\nconst SheetDescription = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSheetDescription.displayName = SheetPrimitive.Description.displayName;\n\nexport {\n Sheet,\n SheetPortal,\n SheetOverlay,\n SheetTrigger,\n SheetClose,\n SheetContent,\n SheetHeader,\n SheetFooter,\n SheetTitle,\n SheetDescription,\n};\n","import React from 'react';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nfunction Skeleton({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\n\nexport { Skeleton };\n","import React from 'react';\nimport * as TooltipPrimitive from '@radix-ui/react-tooltip';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst TooltipProvider = TooltipPrimitive.Provider;\n\nconst Tooltip = TooltipPrimitive.Root;\n\nconst TooltipTrigger = TooltipPrimitive.Trigger;\n\nconst TooltipContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, sideOffset = 4, ...props }, ref) => (\n \n));\nTooltipContent.displayName = TooltipPrimitive.Content.displayName;\n\nexport { Tooltip, TooltipTrigger, TooltipContent, TooltipProvider };\n","import * as React from 'react';\n\nconst MOBILE_BREAKPOINT = 768;\n\nexport default function useIsMobile() {\n const [isMobile, setIsMobile] = React.useState(undefined);\n\n React.useEffect(() => {\n const mql = window.matchMedia(`(max-width: ${MOBILE_BREAKPOINT - 1}px)`);\n const onChange = () => {\n setIsMobile(window.innerWidth < MOBILE_BREAKPOINT);\n };\n mql.addEventListener('change', onChange);\n setIsMobile(window.innerWidth < MOBILE_BREAKPOINT);\n return () => mql.removeEventListener('change', onChange);\n }, []);\n\n return !!isMobile;\n}\n","import React from 'react';\nimport { Slot } from '@radix-ui/react-slot';\nimport { VariantProps, cva } from 'class-variance-authority';\nimport { PanelLeft } from 'lucide-react';\n\nimport { Button } from '@/components/shadcn-ui/button';\nimport { Input } from '@/components/shadcn-ui/input';\nimport { Separator } from '@/components/shadcn-ui/separator';\nimport { Sheet, SheetContent } from '@/components/shadcn-ui/sheet';\nimport { Skeleton } from '@/components/shadcn-ui/skeleton';\nimport {\n Tooltip,\n TooltipContent,\n TooltipProvider,\n TooltipTrigger,\n} from '@/components/shadcn-ui/tooltip';\nimport useIsMobile from '@/components/hooks/use-mobile';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst SIDEBAR_COOKIE_NAME = 'sidebar:state';\nconst SIDEBAR_COOKIE_MAX_AGE = 60 * 60 * 24 * 7;\nconst SIDEBAR_WIDTH = '16rem';\nconst SIDEBAR_WIDTH_MOBILE = '18rem';\nconst SIDEBAR_WIDTH_ICON = '3rem';\nconst SIDEBAR_KEYBOARD_SHORTCUT = 'b';\n\ntype SidebarContextProps = {\n state: 'expanded' | 'collapsed';\n open: boolean;\n setOpen: (open: boolean) => void;\n openMobile: boolean;\n setOpenMobile: (open: boolean) => void;\n isMobile: boolean;\n toggleSidebar: () => void;\n};\n\nconst SidebarContext = React.createContext(undefined);\n\nfunction useSidebar() {\n const context = React.useContext(SidebarContext);\n if (!context) {\n throw new Error('useSidebar must be used within a SidebarProvider.');\n }\n\n return context;\n}\n\nconst SidebarProvider = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & {\n defaultOpen?: boolean;\n open?: boolean;\n onOpenChange?: (open: boolean) => void;\n }\n>(\n (\n {\n defaultOpen = true,\n open: openProp,\n onOpenChange: setOpenProp,\n className,\n style,\n children,\n ...props\n },\n ref,\n ) => {\n const isMobile = useIsMobile();\n const [openMobile, setOpenMobile] = React.useState(false);\n\n // This is the internal state of the sidebar.\n // We use openProp and setOpenProp for control from outside the component.\n const [_open, _setOpen] = React.useState(defaultOpen);\n const isOpen = openProp ?? _open;\n const setOpen = React.useCallback(\n (value: boolean | ((value: boolean) => boolean)) => {\n const openState = typeof value === 'function' ? value(isOpen) : value;\n if (setOpenProp) {\n setOpenProp(openState);\n } else {\n _setOpen(openState);\n }\n\n // This sets the cookie to keep the sidebar state.\n document.cookie = `${SIDEBAR_COOKIE_NAME}=${openState}; path=/; max-age=${SIDEBAR_COOKIE_MAX_AGE}`;\n },\n [setOpenProp, isOpen],\n );\n\n // Helper to toggle the sidebar.\n const toggleSidebar = React.useCallback(() => {\n return isMobile ? setOpenMobile((open) => !open) : setOpen((open) => !open);\n }, [isMobile, setOpen, setOpenMobile]);\n\n // Adds a keyboard shortcut to toggle the sidebar.\n React.useEffect(() => {\n const handleKeyDown = (event: KeyboardEvent) => {\n if (event.key === SIDEBAR_KEYBOARD_SHORTCUT && (event.metaKey || event.ctrlKey)) {\n event.preventDefault();\n toggleSidebar();\n }\n };\n\n window.addEventListener('keydown', handleKeyDown);\n return () => window.removeEventListener('keydown', handleKeyDown);\n }, [toggleSidebar]);\n\n // We add a state so that we can do data-state=\"expanded\" or \"collapsed\".\n // This makes it easier to style the sidebar with Tailwind classes.\n const state = isOpen ? 'expanded' : 'collapsed';\n\n const contextValue = React.useMemo(\n () => ({\n state,\n open: isOpen,\n setOpen,\n isMobile,\n openMobile,\n setOpenMobile,\n toggleSidebar,\n }),\n [state, isOpen, setOpen, isMobile, openMobile, setOpenMobile, toggleSidebar],\n );\n\n return (\n \n \n \n {children}\n
    \n \n \n );\n },\n);\nSidebarProvider.displayName = 'SidebarProvider';\n\nconst Sidebar = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & {\n side?: 'left' | 'right';\n variant?: 'sidebar' | 'floating' | 'inset';\n collapsible?: 'offcanvas' | 'icon' | 'none';\n }\n>(\n (\n {\n side = 'left',\n variant = 'sidebar',\n collapsible = 'offcanvas',\n className,\n children,\n ...props\n },\n ref,\n ) => {\n const { isMobile, state, openMobile, setOpenMobile } = useSidebar();\n\n if (collapsible === 'none') {\n return (\n \n {children}\n
    \n );\n }\n\n if (isMobile) {\n return (\n \n button]:tw-hidden\"\n style={\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n {\n '--sidebar-width': SIDEBAR_WIDTH_MOBILE,\n } as React.CSSProperties\n }\n side={side}\n >\n
    {children}
    \n \n
    \n );\n }\n\n return (\n \n {/* This is what handles the sidebar gap on desktop */}\n \n \n \n {children}\n
    \n
    \n
    \n );\n },\n);\nSidebar.displayName = 'Sidebar';\n\nconst SidebarTrigger = React.forwardRef<\n React.ElementRef,\n React.ComponentProps\n>(({ className, onClick, ...props }, ref) => {\n const { toggleSidebar } = useSidebar();\n\n return (\n {\n onClick?.(event);\n toggleSidebar();\n }}\n {...props}\n >\n \n Toggle Sidebar\n \n );\n});\nSidebarTrigger.displayName = 'SidebarTrigger';\n\nconst SidebarRail = React.forwardRef>(\n ({ className, ...props }, ref) => {\n const { toggleSidebar } = useSidebar();\n\n return (\n \n );\n },\n);\nSidebarRail.displayName = 'SidebarRail';\n\nconst SidebarInset = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarInset.displayName = 'SidebarInset';\n\nconst SidebarInput = React.forwardRef<\n React.ElementRef,\n React.ComponentProps\n>(({ className, ...props }, ref) => {\n return (\n \n );\n});\nSidebarInput.displayName = 'SidebarInput';\n\nconst SidebarHeader = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarHeader.displayName = 'SidebarHeader';\n\nconst SidebarFooter = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarFooter.displayName = 'SidebarFooter';\n\nconst SidebarSeparator = React.forwardRef<\n React.ElementRef,\n React.ComponentProps\n>(({ className, ...props }, ref) => {\n return (\n \n );\n});\nSidebarSeparator.displayName = 'SidebarSeparator';\n\nconst SidebarContent = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarContent.displayName = 'SidebarContent';\n\nconst SidebarGroup = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarGroup.displayName = 'SidebarGroup';\n\nconst SidebarGroupLabel = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & { asChild?: boolean }\n>(({ className, asChild = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'div';\n\n return (\n svg]:tw-size-4 [&>svg]:tw-shrink-0',\n 'group-data-[collapsible=icon]:tw--mt-8 group-data-[collapsible=icon]:tw-opacity-0',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarGroupLabel.displayName = 'SidebarGroupLabel';\n\nconst SidebarGroupAction = React.forwardRef<\n HTMLButtonElement,\n React.ComponentProps<'button'> & { asChild?: boolean }\n>(({ className, asChild = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'button';\n\n return (\n svg]:tw-size-4 [&>svg]:tw-shrink-0',\n // Increases the hit area of the button on mobile.\n 'after:tw-absolute after:tw--inset-2 after:md:tw-hidden',\n 'group-data-[collapsible=icon]:tw-hidden',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarGroupAction.displayName = 'SidebarGroupAction';\n\nconst SidebarGroupContent = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarGroupContent.displayName = 'SidebarGroupContent';\n\nconst SidebarMenu = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenu.displayName = 'SidebarMenu';\n\nconst SidebarMenuItem = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenuItem.displayName = 'SidebarMenuItem';\n\nconst sidebarMenuButtonVariants = cva(\n // Removed data-[active=true]:tw-bg-sidebar-accent\n 'tw-peer/menu-button tw-flex tw-w-full tw-items-center tw-gap-2 tw-overflow-hidden tw-rounded-md tw-p-2 tw-text-left tw-text-sm tw-outline-none tw-ring-sidebar-ring tw-transition-[width,height,padding] hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground focus-visible:tw-ring-2 active:tw-bg-sidebar-accent active:tw-text-sidebar-accent-foreground disabled:tw-pointer-events-none disabled:tw-opacity-50 tw-group-has-[[data-sidebar=menu-action]]/menu-item:pr-8 aria-disabled:tw-pointer-events-none aria-disabled:tw-opacity-50 data-[active=true]:tw-font-medium data-[active=true]:tw-text-sidebar-accent-foreground data-[state=open]:hover:tw-bg-sidebar-accent data-[state=open]:hover:tw-text-sidebar-accent-foreground group-data-[collapsible=icon]:tw-!size-8 group-data-[collapsible=icon]:tw-!p-2 [&>span:last-child]:tw-truncate [&>svg]:tw-size-4 [&>svg]:tw-shrink-0',\n {\n variants: {\n variant: {\n default: 'hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground',\n outline:\n 'tw-bg-background tw-shadow-[0_0_0_1px_hsl(var(--sidebar-border))] hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground hover:tw-shadow-[0_0_0_1px_hsl(var(--sidebar-accent))]',\n },\n size: {\n default: 'tw-h-8 tw-text-sm',\n sm: 'tw-h-7 tw-text-xs',\n lg: 'tw-h-12 tw-text-sm group-data-[collapsible=icon]:tw-!p-0',\n },\n },\n defaultVariants: {\n variant: 'default',\n size: 'default',\n },\n },\n);\n\nconst SidebarMenuButton = React.forwardRef<\n HTMLButtonElement,\n React.ComponentProps<'button'> & {\n asChild?: boolean;\n isActive?: boolean;\n tooltip?: string | React.ComponentProps;\n } & VariantProps\n>(\n (\n {\n asChild = false,\n isActive = false,\n variant = 'default',\n size = 'default',\n tooltip,\n className,\n ...props\n },\n ref,\n ) => {\n const Comp = asChild ? Slot : 'button';\n const { isMobile, state } = useSidebar();\n\n const button = (\n \n );\n\n if (!tooltip) {\n return button;\n }\n\n if (typeof tooltip === 'string') {\n // eslint-disable-next-line no-param-reassign\n tooltip = {\n children: tooltip,\n };\n }\n\n return (\n \n {button}\n \n );\n },\n);\nSidebarMenuButton.displayName = 'SidebarMenuButton';\n\nconst SidebarMenuAction = React.forwardRef<\n HTMLButtonElement,\n React.ComponentProps<'button'> & {\n asChild?: boolean;\n showOnHover?: boolean;\n }\n>(({ className, asChild = false, showOnHover = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'button';\n\n return (\n svg]:tw-size-4 [&>svg]:tw-shrink-0',\n // Increases the hit area of the button on mobile.\n 'after:tw-absolute after:tw--inset-2 after:md:tw-hidden',\n 'tw-peer-data-[size=sm]/menu-button:top-1',\n 'tw-peer-data-[size=default]/menu-button:top-1.5',\n 'tw-peer-data-[size=lg]/menu-button:top-2.5',\n 'group-data-[collapsible=icon]:tw-hidden',\n showOnHover &&\n 'tw-group-focus-within/menu-item:opacity-100 tw-group-hover/menu-item:opacity-100 tw-peer-data-[active=true]/menu-button:text-sidebar-accent-foreground data-[state=open]:tw-opacity-100 md:tw-opacity-0',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarMenuAction.displayName = 'SidebarMenuAction';\n\nconst SidebarMenuBadge = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenuBadge.displayName = 'SidebarMenuBadge';\n\nconst SidebarMenuSkeleton = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & {\n showIcon?: boolean;\n }\n>(({ className, showIcon = false, ...props }, ref) => {\n // Random width between 50 to 90%.\n const width = React.useMemo(() => {\n return `${Math.floor(Math.random() * 40) + 50}%`;\n }, []);\n\n return (\n \n {showIcon && (\n \n )}\n \n
    \n );\n});\nSidebarMenuSkeleton.displayName = 'SidebarMenuSkeleton';\n\nconst SidebarMenuSub = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenuSub.displayName = 'SidebarMenuSub';\n\nconst SidebarMenuSubItem = React.forwardRef>(\n ({ ...props }, ref) =>
  • ,\n);\nSidebarMenuSubItem.displayName = 'SidebarMenuSubItem';\n\nconst SidebarMenuSubButton = React.forwardRef<\n HTMLAnchorElement,\n React.ComponentProps<'a'> & {\n asChild?: boolean;\n size?: 'sm' | 'md';\n isActive?: boolean;\n }\n>(({ asChild = false, size = 'md', isActive, className, ...props }, ref) => {\n const Comp = asChild ? Slot : 'a';\n\n return (\n span:last-child]:tw-truncate [&>svg]:tw-size-4 [&>svg]:tw-shrink-0 [&>svg]:tw-text-sidebar-accent-foreground',\n 'data-[active=true]:tw-bg-sidebar-accent data-[active=true]:tw-text-sidebar-accent-foreground',\n size === 'sm' && 'tw-text-xs',\n size === 'md' && 'tw-text-sm',\n 'group-data-[collapsible=icon]:tw-hidden',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarMenuSubButton.displayName = 'SidebarMenuSubButton';\n\nexport {\n Sidebar,\n SidebarContent,\n SidebarFooter,\n SidebarGroup,\n SidebarGroupAction,\n SidebarGroupContent,\n SidebarGroupLabel,\n SidebarHeader,\n SidebarInput,\n SidebarInset,\n SidebarMenu,\n SidebarMenuAction,\n SidebarMenuBadge,\n SidebarMenuButton,\n SidebarMenuItem,\n SidebarMenuSkeleton,\n SidebarMenuSub,\n SidebarMenuSubButton,\n SidebarMenuSubItem,\n SidebarProvider,\n SidebarRail,\n SidebarSeparator,\n SidebarTrigger,\n useSidebar,\n};\n","import ComboBox, { ComboBoxOption } from '@/components/basics/combo-box.component';\nimport {\n Sidebar,\n SidebarContent,\n SidebarGroup,\n SidebarGroupLabel,\n SidebarGroupContent,\n SidebarMenu,\n SidebarMenuItem,\n SidebarMenuButton,\n} from '@/components/shadcn-ui/sidebar';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { useCallback } from 'react';\n\nexport type SelectedSettingsSidebarItem = {\n label: string;\n projectId?: string;\n};\n\nexport type ProjectOptions = { projectId: string; projectName: string };\n\nexport type SettingsSidebarProps = {\n /** Optional id for testing */\n id?: string;\n\n /** Extension labels from contribution */\n extensionLabels: string[];\n\n /** Project names and ids */\n projectOptions: ProjectOptions[];\n\n /** Handler for selecting a sidebar item */\n handleSelectSidebarItem: (key: string, projectId?: string) => void;\n\n /** The current selected value in the sidebar */\n selectedSidebarItem: SelectedSettingsSidebarItem;\n};\n\nexport default function SettingsSidebar({\n id,\n extensionLabels,\n projectOptions,\n handleSelectSidebarItem,\n selectedSidebarItem,\n}: SettingsSidebarProps) {\n const handleSelectItem = useCallback(\n (item: string, projectId?: string) => {\n handleSelectSidebarItem(item, projectId);\n },\n [handleSelectSidebarItem],\n );\n\n const getProjectNameFromProjectId = useCallback(\n (projectId: string) => {\n const project = projectOptions.find((option) => option.projectId === projectId);\n return project ? project.projectName : projectId;\n },\n [projectOptions],\n );\n\n const getIsActive: (label: string) => boolean = useCallback(\n (label: string) => !selectedSidebarItem.projectId && label === selectedSidebarItem.label,\n [selectedSidebarItem],\n );\n\n return (\n \n \n \n Extensions\n \n \n {extensionLabels.map((label) => (\n \n handleSelectItem(label, undefined)}\n isActive={getIsActive(label)}\n >\n {label}\n \n \n ))}\n \n \n \n \n Projects\n \n option.projectId)}\n getOptionLabel={(projectId: ComboBoxOption) => {\n // This function expects a ComboBoxOption, but we know it is a string\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n return getProjectNameFromProjectId(projectId as string);\n }}\n buttonPlaceholder=\"Type or select project\"\n onChange={(projectId: string) => {\n const selectedProjectName = getProjectNameFromProjectId(projectId);\n handleSelectItem(selectedProjectName, projectId);\n }}\n value={selectedSidebarItem?.projectId ?? undefined}\n />\n \n \n \n \n );\n}\n","import { SidebarInset, SidebarProvider } from '@/components/shadcn-ui/sidebar';\nimport { PropsWithChildren } from 'react';\nimport SearchBar from '@/components/basics/search-bar.component';\nimport SettingsSidebar, { SettingsSidebarProps } from './settings-sidebar.component';\n\nexport type SettingsSidebarContentSearchProps = SettingsSidebarProps &\n PropsWithChildren & {\n /** Optional id for testing */\n id?: string;\n\n /** Text direction ltr or rtl */\n direction?: 'ltr' | 'rtl';\n\n /** Handler to run when the value of the search bar changes */\n onSearch: (searchQuery: string) => void;\n };\n\nexport default function SettingsSidebarContentSearch({\n id,\n direction = 'ltr',\n extensionLabels,\n projectOptions,\n children,\n handleSelectSidebarItem,\n selectedSidebarItem,\n onSearch,\n}: SettingsSidebarContentSearchProps) {\n return (\n
    \n
    \n \n
    \n \n \n {children}\n \n
    \n );\n}\n","import { Button } from '@/components/shadcn-ui/button';\nimport {\n Select,\n SelectContent,\n SelectGroup,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\nimport {\n Table,\n TableBody,\n TableCell,\n TableHead,\n TableHeader,\n TableRow,\n} from '@/components/shadcn-ui/table';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Canon } from '@sillsdev/scripture';\nimport {\n Cell,\n ColumnDef,\n flexRender,\n getCoreRowModel,\n getExpandedRowModel,\n getGroupedRowModel,\n getSortedRowModel,\n GroupingState,\n Row,\n RowSelectionState,\n SortingState,\n useReactTable,\n} from '@tanstack/react-table';\nimport '@/components/advanced/scripture-results-viewer/scripture-results-viewer.component.css';\nimport {\n compareScrRefs,\n formatScrRef,\n ScriptureSelection,\n scrRefToBBBCCCVVV,\n} from 'platform-bible-utils';\nimport { MouseEvent, useEffect, useMemo, useState } from 'react';\nimport { ChevronDown, ChevronLeft, ChevronRight } from 'lucide-react';\n\n/**\n * Information (e.g., a checking error or some other type of \"transient\" annotation) about something\n * noteworthy at a specific place in an instance of the Scriptures.\n */\nexport type ScriptureItemDetail = ScriptureSelection & {\n /**\n * Text of the error, note, etc. In the future, we might want to support something more than just\n * text so that a JSX element could be provided with a link or some other controls related to the\n * issue being reported.\n */\n detail: string;\n};\n\n/**\n * A uniquely identifiable source of results that can be displayed in the ScriptureResultsViewer.\n * Generally, the source will be a particular Scripture check, but there may be other types of\n * sources.\n */\nexport type ResultsSource = {\n /**\n * Uniquely identifies the source.\n *\n * @type {string}\n */\n id: string;\n\n /**\n * Name (potentially localized) of the source, suitable for display in the UI.\n *\n * @type {string}\n */\n displayName: string;\n};\n\nexport type ScriptureSrcItemDetail = ScriptureItemDetail & {\n /** Source/type of detail. Can be used for grouping. */\n source: ResultsSource;\n};\n\n/**\n * Represents a set of results keyed by Scripture reference. Generally, the source will be a\n * particular Scripture check, but this type also allows for other types of uniquely identifiable\n * sources.\n */\nexport type ResultsSet = {\n /**\n * The backing source associated with this set of results.\n *\n * @type {ResultsSource}\n */\n source: ResultsSource;\n\n /**\n * Array of Scripture item details (messages keyed by Scripture reference).\n *\n * @type {ScriptureItemDetail[]}\n */\n data: ScriptureItemDetail[];\n};\n\nconst scrBookColId = 'scrBook';\nconst scrRefColId = 'scrRef';\nconst typeColId = 'source';\nconst detailsColId = 'details';\n\nconst defaultScrRefColumnName = 'Scripture Reference';\nconst defaultScrBookGroupName = 'Scripture Book';\nconst defaultTypeColumnName = 'Type';\nconst defaultDetailsColumnName = 'Details';\n\nexport type ScriptureResultsViewerColumnInfo = {\n /** Optional header to display for the Reference column. Default value: 'Scripture Reference'. */\n scriptureReferenceColumnName?: string;\n\n /** Optional text to display to refer to the Scripture book group. Default value: 'Scripture Book'. */\n scriptureBookGroupName?: string;\n\n /** Optional header to display for the Type column. Default value: 'Type'. */\n typeColumnName?: string;\n\n /** Optional header to display for the Details column. Default value: 'Details' */\n detailsColumnName?: string;\n};\n\nexport type ScriptureResultsViewerProps = ScriptureResultsViewerColumnInfo & {\n /** Groups of ScriptureItemDetail objects from particular sources (e.g., Scripture checks) */\n sources: ResultsSet[];\n\n /** Flag indicating whether to display column headers. Default is false. */\n showColumnHeaders?: boolean;\n\n /** Flag indicating whether to display source column. Default is false. */\n showSourceColumn?: boolean;\n\n /** Callback function to notify when a row is selected */\n onRowSelected?: (selectedRow: ScriptureSrcItemDetail | undefined) => void;\n\n /** Text direction ltr or rtl */\n direction?: 'ltr' | 'rtl';\n};\n\nfunction getColumns(\n colInfo?: ScriptureResultsViewerColumnInfo,\n showSourceColumn?: boolean,\n): ColumnDef[] {\n const showSrcCol = showSourceColumn ?? false;\n return [\n {\n accessorFn: (row) =>\n `${Canon.bookNumberToId(row.start.bookNum)} ${row.start.chapterNum}:${row.start.verseNum}`,\n id: scrBookColId,\n header: colInfo?.scriptureReferenceColumnName ?? defaultScrRefColumnName,\n cell: (info) => {\n const row = info.row.original;\n if (info.row.getIsGrouped()) {\n return Canon.bookNumberToEnglishName(row.start.bookNum);\n }\n return info.row.groupingColumnId === scrBookColId ? formatScrRef(row.start) : undefined;\n },\n getGroupingValue: (row) => row.start.bookNum,\n sortingFn: (a, b) => {\n return compareScrRefs(a.original.start, b.original.start);\n },\n enableGrouping: true,\n },\n {\n accessorFn: (row) => formatScrRef(row.start),\n id: scrRefColId,\n header: undefined,\n cell: (info) => {\n const row = info.row.original;\n return info.row.getIsGrouped() ? undefined : formatScrRef(row.start);\n },\n sortingFn: (a, b) => {\n return compareScrRefs(a.original.start, b.original.start);\n },\n enableGrouping: false,\n },\n {\n accessorFn: (row) => row.source.displayName,\n id: typeColId,\n header: showSrcCol ? (colInfo?.typeColumnName ?? defaultTypeColumnName) : undefined,\n cell: (info) => (showSrcCol || info.row.getIsGrouped() ? info.getValue() : undefined),\n getGroupingValue: (row) => row.source.id,\n sortingFn: (a, b) =>\n a.original.source.displayName.localeCompare(b.original.source.displayName),\n enableGrouping: true,\n },\n {\n accessorFn: (row) => row.detail,\n id: detailsColId,\n header: colInfo?.detailsColumnName ?? defaultDetailsColumnName,\n cell: (info) => info.getValue(),\n enableGrouping: false,\n },\n ];\n}\n\nconst toRefOrRange = (scriptureSelection: ScriptureSelection) => {\n if (!('offset' in scriptureSelection.start))\n throw new Error('No offset available in range start');\n if (scriptureSelection.end && !('offset' in scriptureSelection.end))\n throw new Error('No offset available in range end');\n const { offset: offsetStart } = scriptureSelection.start;\n let offsetEnd: number = 0;\n if (scriptureSelection.end) ({ offset: offsetEnd } = scriptureSelection.end);\n if (\n !scriptureSelection.end ||\n compareScrRefs(scriptureSelection.start, scriptureSelection.end) === 0\n )\n return `${scrRefToBBBCCCVVV(scriptureSelection.start)}+${offsetStart}`;\n return `${scrRefToBBBCCCVVV(scriptureSelection.start)}+${offsetStart}-${scrRefToBBBCCCVVV(scriptureSelection.end)}+${offsetEnd}`;\n};\n\nconst getRowKey = (row: ScriptureSrcItemDetail) =>\n `${toRefOrRange({ start: row.start, end: row.end })} ${row.source.displayName} ${row.detail}`;\n\n/**\n * Component to display a combined list of detailed items from one or more sources, where the items\n * are keyed primarily by Scripture reference. This is particularly useful for displaying a list of\n * results from Scripture checks, but more generally could be used to display any \"results\" from any\n * source(s). The component allows for grouping by Scripture book, source, or both. By default, it\n * displays somewhat \"tree-like\" which allows it to be more horizontally compact and intuitive. But\n * it also has the option of displaying as a traditional table with column headings (with or without\n * the source column showing).\n */\nexport default function ScriptureResultsViewer({\n sources,\n showColumnHeaders = false,\n showSourceColumn = false,\n scriptureReferenceColumnName,\n scriptureBookGroupName,\n typeColumnName,\n detailsColumnName,\n onRowSelected,\n direction = 'ltr',\n}: ScriptureResultsViewerProps) {\n const [grouping, setGrouping] = useState([]);\n const [sorting, setSorting] = useState([{ id: scrBookColId, desc: false }]);\n const [rowSelection, setRowSelection] = useState({});\n\n const scriptureResults = useMemo(\n () =>\n sources.flatMap((source) => {\n return source.data.map((item) => ({\n ...item,\n source: source.source,\n }));\n }),\n [sources],\n );\n\n const columns = useMemo(\n () =>\n getColumns(\n {\n scriptureReferenceColumnName,\n typeColumnName,\n detailsColumnName,\n },\n showSourceColumn,\n ),\n [scriptureReferenceColumnName, typeColumnName, detailsColumnName, showSourceColumn],\n );\n\n useEffect(() => {\n // Ensure sorting is applied correctly when grouped by type\n if (grouping.includes(typeColId)) {\n setSorting([\n { id: typeColId, desc: false },\n { id: scrBookColId, desc: false },\n ]);\n } else {\n setSorting([{ id: scrBookColId, desc: false }]);\n }\n }, [grouping]);\n\n const table = useReactTable({\n data: scriptureResults,\n columns,\n state: {\n grouping,\n sorting,\n rowSelection,\n },\n onGroupingChange: setGrouping,\n onSortingChange: setSorting,\n onRowSelectionChange: setRowSelection,\n getExpandedRowModel: getExpandedRowModel(),\n getGroupedRowModel: getGroupedRowModel(),\n getCoreRowModel: getCoreRowModel(),\n getSortedRowModel: getSortedRowModel(),\n getRowId: getRowKey,\n autoResetExpanded: false,\n enableMultiRowSelection: false,\n enableSubRowSelection: false,\n });\n\n useEffect(() => {\n if (onRowSelected) {\n const selectedRows = table.getSelectedRowModel().rowsById;\n const keys = Object.keys(selectedRows);\n if (keys.length === 1) {\n const selectedRow = scriptureResults.find((row) => getRowKey(row) === keys[0]) || undefined;\n if (selectedRow) onRowSelected(selectedRow);\n }\n }\n }, [rowSelection, scriptureResults, onRowSelected, table]);\n\n // Define possible grouping options\n const scrBookGroupName = scriptureBookGroupName ?? defaultScrBookGroupName;\n const typeGroupName = typeColumnName ?? defaultTypeColumnName;\n\n const groupingOptions = [\n { label: 'No Grouping', value: [] },\n { label: `Group by ${scrBookGroupName}`, value: [scrBookColId] },\n { label: `Group by ${typeGroupName}`, value: [typeColId] },\n {\n label: `Group by ${scrBookGroupName} and ${typeGroupName}`,\n value: [scrBookColId, typeColId],\n },\n {\n label: `Group by ${typeGroupName} and ${scrBookGroupName}`,\n value: [typeColId, scrBookColId],\n },\n ];\n\n const handleSelectChange = (selectedGrouping: string) => {\n setGrouping(JSON.parse(selectedGrouping));\n };\n\n const handleRowClick = (row: Row, event: MouseEvent) => {\n if (!row.getIsGrouped() && !row.getIsSelected()) {\n row.getToggleSelectedHandler()(event);\n }\n };\n\n const getEvenOrOddBandingStyle = (row: Row, index: number) => {\n if (row.getIsGrouped()) return '';\n // UX has now said they don't think they want banding. I'm leaving in the code to\n // set even and odd styles, but there's nothing in the CSS to style them differently.\n // The \"even\" style used to also have tw-bg-neutral-300 (along with even) to create\n // a visual banding effect. That could be added back in if UX changes the decision.\n return cn('banded-row', index % 2 === 0 ? 'even' : 'odd');\n };\n\n const getIndent = (\n groupingState: GroupingState,\n row: Row,\n cell: Cell,\n ) => {\n if (groupingState?.length === 0 || row.depth < cell.column.getGroupedIndex()) return undefined;\n if (row.getIsGrouped()) {\n switch (row.depth) {\n case 1:\n return 'tw-ps-4';\n default:\n return undefined;\n }\n }\n switch (row.depth) {\n case 1:\n return 'tw-ps-8';\n case 2:\n return 'tw-ps-12';\n default:\n return undefined;\n }\n };\n\n return (\n
    \n {!showColumnHeaders && (\n {\n handleSelectChange(value);\n }}\n >\n \n \n \n \n \n {groupingOptions.map((option) => (\n \n {option.label}\n \n ))}\n \n \n \n )}\n \n {showColumnHeaders && (\n \n {table.getHeaderGroups().map((headerGroup) => (\n \n {headerGroup.headers\n .filter((h) => h.column.columnDef.header)\n .map((header) => (\n /* For sticky column headers to work, we probably need to change the default definition of the shadcn Table component. See https://github.com/shadcn-ui/ui/issues/1151 */\n \n {header.isPlaceholder ? undefined : (\n
    \n {header.column.getCanGroup() ? (\n \n {header.column.getIsGrouped() ? `🛑` : `👊 `}\n \n ) : undefined}{' '}\n {flexRender(header.column.columnDef.header, header.getContext())}\n
    \n )}\n
    \n ))}\n
    \n ))}\n
    \n )}\n \n {table.getRowModel().rows.map((row, rowIndex) => {\n return (\n handleRowClick(row, event)}\n >\n {row.getVisibleCells().map((cell) => {\n if (\n cell.getIsPlaceholder() ||\n (cell.column.columnDef.enableGrouping &&\n !cell.getIsGrouped() &&\n (cell.column.columnDef.id !== typeColId || !showSourceColumn))\n )\n return undefined;\n return (\n \n {(() => {\n if (cell.getIsGrouped()) {\n return (\n \n {row.getIsExpanded() && }\n {!row.getIsExpanded() &&\n (direction === 'ltr' ? : )}{' '}\n {flexRender(cell.column.columnDef.cell, cell.getContext())} (\n {row.subRows.length})\n \n );\n }\n\n // if (cell.getIsAggregated()) {\n // flexRender(\n // cell.column.columnDef.aggregatedCell ?? cell.column.columnDef.cell,\n // cell.getContext(),\n // );\n // }\n\n return flexRender(cell.column.columnDef.cell, cell.getContext());\n })()}\n \n );\n })}\n \n );\n })}\n \n
    \n
    \n );\n}\n","import {\n getLocalizeKeyForScrollGroupId,\n LanguageStrings,\n ScrollGroupId,\n} from 'platform-bible-utils';\nimport {\n Select,\n SelectContent,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\n\nconst DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS = {\n [getLocalizeKeyForScrollGroupId('undefined')]: 'Ø',\n [getLocalizeKeyForScrollGroupId(0)]: 'A',\n [getLocalizeKeyForScrollGroupId(1)]: 'B',\n [getLocalizeKeyForScrollGroupId(2)]: 'C',\n [getLocalizeKeyForScrollGroupId(3)]: 'D',\n [getLocalizeKeyForScrollGroupId(4)]: 'E',\n [getLocalizeKeyForScrollGroupId(5)]: 'F',\n [getLocalizeKeyForScrollGroupId(6)]: 'G',\n [getLocalizeKeyForScrollGroupId(7)]: 'H',\n [getLocalizeKeyForScrollGroupId(8)]: 'I',\n [getLocalizeKeyForScrollGroupId(9)]: 'J',\n [getLocalizeKeyForScrollGroupId(10)]: 'K',\n [getLocalizeKeyForScrollGroupId(11)]: 'L',\n [getLocalizeKeyForScrollGroupId(12)]: 'M',\n [getLocalizeKeyForScrollGroupId(13)]: 'N',\n [getLocalizeKeyForScrollGroupId(14)]: 'O',\n [getLocalizeKeyForScrollGroupId(15)]: 'P',\n [getLocalizeKeyForScrollGroupId(16)]: 'Q',\n [getLocalizeKeyForScrollGroupId(17)]: 'R',\n [getLocalizeKeyForScrollGroupId(18)]: 'S',\n [getLocalizeKeyForScrollGroupId(19)]: 'T',\n [getLocalizeKeyForScrollGroupId(20)]: 'U',\n [getLocalizeKeyForScrollGroupId(21)]: 'V',\n [getLocalizeKeyForScrollGroupId(22)]: 'W',\n [getLocalizeKeyForScrollGroupId(23)]: 'X',\n [getLocalizeKeyForScrollGroupId(24)]: 'Y',\n [getLocalizeKeyForScrollGroupId(25)]: 'Z',\n};\n\nexport type ScrollGroupSelectorProps = {\n /**\n * List of scroll group ids to show to the user. Either a {@link ScrollGroupId} or `undefined` for\n * no scroll group\n */\n availableScrollGroupIds: (ScrollGroupId | undefined)[];\n /** Currently selected scroll group id. `undefined` for no scroll group */\n scrollGroupId: ScrollGroupId | undefined;\n /** Callback function run when the user tries to change the scroll group id */\n onChangeScrollGroupId: (newScrollGroupId: ScrollGroupId | undefined) => void;\n /**\n * Localized strings to use for displaying scroll group ids. Must be an object whose keys are\n * `getLocalizeKeyForScrollGroupId(scrollGroupId)` for all scroll group ids (and `undefined` if\n * included) in {@link ScrollGroupSelectorProps.availableScrollGroupIds} and whose values are the\n * localized strings to use for those scroll group ids.\n *\n * Defaults to English localizations of English alphabet for scroll groups 0-25 (e.g. 0 is A) and\n * Ø for `undefined`. Will fill in any that are not provided with these English localizations.\n * Also, if any values match the keys, the English localization will be used. This is useful in\n * case you want to pass in a temporary version of the localized strings while your localized\n * strings load.\n *\n * @example\n *\n * ```typescript\n * const myScrollGroupIdLocalizedStrings = {\n * [getLocalizeKeyForScrollGroupId('undefined')]: 'Ø',\n * [getLocalizeKeyForScrollGroupId(0)]: 'A',\n * [getLocalizeKeyForScrollGroupId(1)]: 'B',\n * [getLocalizeKeyForScrollGroupId(2)]: 'C',\n * [getLocalizeKeyForScrollGroupId(3)]: 'D',\n * [getLocalizeKeyForScrollGroupId(4)]: 'E',\n * };\n * ```\n *\n * @example\n *\n * ```tsx\n * const availableScrollGroupIds = [undefined, 0, 1, 2, 3, 4];\n *\n * const localizeKeys = getLocalizeKeysForScrollGroupIds();\n *\n * const [localizedStrings] = useLocalizedStrings(localizeKeys);\n *\n * ...\n *\n * \n * ```\n */\n localizedStrings?: LanguageStrings;\n};\n\n/** Selector component for choosing a scroll group */\nexport default function ScrollGroupSelector({\n availableScrollGroupIds,\n scrollGroupId,\n onChangeScrollGroupId,\n localizedStrings = {},\n}: ScrollGroupSelectorProps) {\n const localizedStringsDefaulted = {\n ...DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS,\n ...Object.fromEntries(\n Object.entries(localizedStrings).map(\n ([localizedStringKey, localizedStringValue]: [string, string]) => [\n localizedStringKey,\n localizedStringKey === localizedStringValue &&\n localizedStringKey in DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS\n ? DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS[localizedStringKey]\n : localizedStringValue,\n ],\n ),\n ),\n };\n return (\n \n onChangeScrollGroupId(\n newScrollGroupString === 'undefined' ? undefined : parseInt(newScrollGroupString, 10),\n )\n }\n >\n \n \n \n \n {availableScrollGroupIds.map((scrollGroupOptionId) => (\n \n {localizedStringsDefaulted[getLocalizeKeyForScrollGroupId(scrollGroupOptionId)]}\n \n ))}\n \n \n );\n}\n","import { PropsWithChildren } from 'react';\nimport { Separator } from '@/components/shadcn-ui/separator';\n\n/** Props for the SettingsList component, currently just children */\ntype SettingsListProps = PropsWithChildren;\n\n/**\n * SettingsList component is a wrapper for list items. Rendered with a formatted div\n *\n * @param children To populate the list with\n * @returns Formatted div encompassing the children\n */\nexport function SettingsList({ children }: SettingsListProps) {\n return
    {children}
    ;\n}\n\n/** Props for SettingsListItem component */\ntype SettingsListItemProps = PropsWithChildren & {\n /** Primary text of the list item */\n primary: string;\n\n /** Optional text of the list item */\n secondary?: string | undefined;\n\n /** Optional boolean to display a message if the children aren't loaded yet. Defaults to false */\n isLoading?: boolean;\n\n /** Optional message to display if isLoading */\n loadingMessage?: string;\n};\n\n/**\n * SettingsListItem component is a common list item. Rendered with a formatted div\n *\n * @param primary Primary text of the list item\n * @param secondary Optional secondary text of the list item\n * @param isLoading Optional, to display a message if the action component isn't generated yet,\n * defaults to false\n * @param children The action component(s) to provide for this item\n * @param loadingMessage Optional, message to display if isLoading\n * @returns Formatted div encompassing the list item content\n */\nexport function SettingsListItem({\n primary,\n secondary,\n children,\n isLoading = false,\n loadingMessage,\n}: SettingsListItemProps) {\n return (\n
    \n
    \n

    {primary}

    \n

    \n {secondary}\n

    \n
    \n\n {isLoading ? (\n

    {loadingMessage}

    \n ) : (\n
    {children}
    \n )}\n
    \n );\n}\n\n/** Props for SettingsListHeader component */\ntype SettingsListHeaderProps = {\n /** The primary text of the list header */\n primary: string;\n\n /** Optional secondary text of the list header */\n secondary?: string | undefined;\n\n /** Optional boolean to include a separator underneath the secondary text. Defaults to false */\n includeSeparator?: boolean;\n};\n\n/**\n * SettingsListHeader component displays text above the list\n *\n * @param primary The primary text of the list header\n * @param secondary Optional secondary text of the list header\n * @param includeSeparator Optional boolean to include a separator underneath the secondary text.\n * Defaults to false\n * @returns Formatted div with list header content\n */\nexport function SettingsListHeader({\n primary,\n secondary,\n includeSeparator = false,\n}: SettingsListHeaderProps) {\n return (\n
    \n
    \n

    {primary}

    \n

    {secondary}

    \n
    \n {includeSeparator ? : ''}\n
    \n );\n}\n","import React from 'react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Card = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nCard.displayName = 'Card';\n\nconst CardHeader = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nCardHeader.displayName = 'CardHeader';\n\nconst CardTitle = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n {/* added because of https://github.com/jsx-eslint/eslint-plugin-jsx-a11y/blob/main/docs/rules/heading-has-content.md */}\n {props.children}\n \n ),\n);\nCardTitle.displayName = 'CardTitle';\n\nconst CardDescription = React.forwardRef<\n HTMLParagraphElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n

    \n));\nCardDescription.displayName = 'CardDescription';\n\nconst CardContent = React.forwardRef>(\n ({ className, ...props }, ref) => (\n

    \n ),\n);\nCardContent.displayName = 'CardContent';\n\nconst CardFooter = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nCardFooter.displayName = 'CardFooter';\n\nexport { Card, CardHeader, CardFooter, CardTitle, CardDescription, CardContent };\n","import {\n Card,\n CardDescription,\n CardHeader,\n CardTitle,\n CardContent,\n} from '@/components/shadcn-ui/card';\nimport { PropsWithChildren } from 'react';\n\ntype SettingsCardProps = PropsWithChildren & {\n /** Optional id for testing */\n id?: string;\n\n /** Label of the settings group */\n settingsGroupLabel: string;\n\n /** Optional description of the settings group */\n settingsGroupDescription?: string;\n};\n\nexport default function SettingsCard({\n id,\n settingsGroupLabel,\n settingsGroupDescription,\n children,\n}: SettingsCardProps) {\n return (\n \n \n {settingsGroupLabel}\n {settingsGroupDescription && {settingsGroupDescription}}\n \n {children}\n \n );\n}\n","import Checkbox from '@/components/shadcn-ui/checkbox';\nimport { Label } from '@/components/shadcn-ui/label';\n\nexport type ChecklistProps = {\n /** Optional string representing the id attribute of the Checklist */\n id?: string;\n /** Optional string representing CSS class name(s) for styling */\n className?: string;\n /** Array of strings representing the checkable items */\n listItems: string[];\n /** Array of strings representing the checked items */\n selectedListItems: string[];\n /**\n * Function that is called when a checkbox item is selected or deselected\n *\n * @param item The string description for this item\n * @param selected True if selected, false if not selected\n */\n handleSelectListItem: (item: string, selected: boolean) => void;\n\n /**\n * Optional function creates a label for a provided checkable item\n *\n * @param item The item for which a label is to be created\n * @returns A string representing the label text for the checkbox associated with that item\n */\n createLabel?: (item: string) => string;\n};\n\n/** Renders a list of checkboxes. Each checkbox corresponds to an item from the `listItems` array. */\nexport default function Checklist({\n id,\n className,\n listItems,\n selectedListItems,\n handleSelectListItem,\n createLabel,\n}: ChecklistProps) {\n return (\n
    \n {listItems.map((item) => (\n
    \n handleSelectListItem(item, value)}\n />\n \n
    \n ))}\n
    \n );\n}\n","function _interopRequireDefault(obj) {\n return obj && obj.__esModule ? obj : {\n \"default\": obj\n };\n}\nmodule.exports = _interopRequireDefault, module.exports.__esModule = true, module.exports[\"default\"] = module.exports;","export default function chainPropTypes(propType1, propType2) {\n if (process.env.NODE_ENV === 'production') {\n return () => null;\n }\n return function validate(...args) {\n return propType1(...args) || propType2(...args);\n };\n}","export default function _extends() {\n _extends = Object.assign ? Object.assign.bind() : function (target) {\n for (var i = 1; i < arguments.length; i++) {\n var source = arguments[i];\n for (var key in source) {\n if (Object.prototype.hasOwnProperty.call(source, key)) {\n target[key] = source[key];\n }\n }\n }\n return target;\n };\n return _extends.apply(this, arguments);\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\n// https://github.com/sindresorhus/is-plain-obj/blob/main/index.js\nexport function isPlainObject(item) {\n if (typeof item !== 'object' || item === null) {\n return false;\n }\n const prototype = Object.getPrototypeOf(item);\n return (prototype === null || prototype === Object.prototype || Object.getPrototypeOf(prototype) === null) && !(Symbol.toStringTag in item) && !(Symbol.iterator in item);\n}\nfunction deepClone(source) {\n if (!isPlainObject(source)) {\n return source;\n }\n const output = {};\n Object.keys(source).forEach(key => {\n output[key] = deepClone(source[key]);\n });\n return output;\n}\nexport default function deepmerge(target, source, options = {\n clone: true\n}) {\n const output = options.clone ? _extends({}, target) : target;\n if (isPlainObject(target) && isPlainObject(source)) {\n Object.keys(source).forEach(key => {\n // Avoid prototype pollution\n if (key === '__proto__') {\n return;\n }\n if (isPlainObject(source[key]) && key in target && isPlainObject(target[key])) {\n // Since `output` is a clone of `target` and we have narrowed `target` in this block we can cast to the same type.\n output[key] = deepmerge(target[key], source[key], options);\n } else if (options.clone) {\n output[key] = isPlainObject(source[key]) ? deepClone(source[key]) : source[key];\n } else {\n output[key] = source[key];\n }\n });\n }\n return output;\n}","/** @license React v16.13.1\n * react-is.production.min.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';var b=\"function\"===typeof Symbol&&Symbol.for,c=b?Symbol.for(\"react.element\"):60103,d=b?Symbol.for(\"react.portal\"):60106,e=b?Symbol.for(\"react.fragment\"):60107,f=b?Symbol.for(\"react.strict_mode\"):60108,g=b?Symbol.for(\"react.profiler\"):60114,h=b?Symbol.for(\"react.provider\"):60109,k=b?Symbol.for(\"react.context\"):60110,l=b?Symbol.for(\"react.async_mode\"):60111,m=b?Symbol.for(\"react.concurrent_mode\"):60111,n=b?Symbol.for(\"react.forward_ref\"):60112,p=b?Symbol.for(\"react.suspense\"):60113,q=b?\nSymbol.for(\"react.suspense_list\"):60120,r=b?Symbol.for(\"react.memo\"):60115,t=b?Symbol.for(\"react.lazy\"):60116,v=b?Symbol.for(\"react.block\"):60121,w=b?Symbol.for(\"react.fundamental\"):60117,x=b?Symbol.for(\"react.responder\"):60118,y=b?Symbol.for(\"react.scope\"):60119;\nfunction z(a){if(\"object\"===typeof a&&null!==a){var u=a.$$typeof;switch(u){case c:switch(a=a.type,a){case l:case m:case e:case g:case f:case p:return a;default:switch(a=a&&a.$$typeof,a){case k:case n:case t:case r:case h:return a;default:return u}}case d:return u}}}function A(a){return z(a)===m}exports.AsyncMode=l;exports.ConcurrentMode=m;exports.ContextConsumer=k;exports.ContextProvider=h;exports.Element=c;exports.ForwardRef=n;exports.Fragment=e;exports.Lazy=t;exports.Memo=r;exports.Portal=d;\nexports.Profiler=g;exports.StrictMode=f;exports.Suspense=p;exports.isAsyncMode=function(a){return A(a)||z(a)===l};exports.isConcurrentMode=A;exports.isContextConsumer=function(a){return z(a)===k};exports.isContextProvider=function(a){return z(a)===h};exports.isElement=function(a){return\"object\"===typeof a&&null!==a&&a.$$typeof===c};exports.isForwardRef=function(a){return z(a)===n};exports.isFragment=function(a){return z(a)===e};exports.isLazy=function(a){return z(a)===t};\nexports.isMemo=function(a){return z(a)===r};exports.isPortal=function(a){return z(a)===d};exports.isProfiler=function(a){return z(a)===g};exports.isStrictMode=function(a){return z(a)===f};exports.isSuspense=function(a){return z(a)===p};\nexports.isValidElementType=function(a){return\"string\"===typeof a||\"function\"===typeof a||a===e||a===m||a===g||a===f||a===p||a===q||\"object\"===typeof a&&null!==a&&(a.$$typeof===t||a.$$typeof===r||a.$$typeof===h||a.$$typeof===k||a.$$typeof===n||a.$$typeof===w||a.$$typeof===x||a.$$typeof===y||a.$$typeof===v)};exports.typeOf=z;\n","/** @license React v16.13.1\n * react-is.development.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\n\n\nif (process.env.NODE_ENV !== \"production\") {\n (function() {\n'use strict';\n\n// The Symbol used to tag the ReactElement-like types. If there is no native Symbol\n// nor polyfill, then a plain number is used for performance.\nvar hasSymbol = typeof Symbol === 'function' && Symbol.for;\nvar REACT_ELEMENT_TYPE = hasSymbol ? Symbol.for('react.element') : 0xeac7;\nvar REACT_PORTAL_TYPE = hasSymbol ? Symbol.for('react.portal') : 0xeaca;\nvar REACT_FRAGMENT_TYPE = hasSymbol ? Symbol.for('react.fragment') : 0xeacb;\nvar REACT_STRICT_MODE_TYPE = hasSymbol ? Symbol.for('react.strict_mode') : 0xeacc;\nvar REACT_PROFILER_TYPE = hasSymbol ? Symbol.for('react.profiler') : 0xead2;\nvar REACT_PROVIDER_TYPE = hasSymbol ? Symbol.for('react.provider') : 0xeacd;\nvar REACT_CONTEXT_TYPE = hasSymbol ? Symbol.for('react.context') : 0xeace; // TODO: We don't use AsyncMode or ConcurrentMode anymore. They were temporary\n// (unstable) APIs that have been removed. Can we remove the symbols?\n\nvar REACT_ASYNC_MODE_TYPE = hasSymbol ? Symbol.for('react.async_mode') : 0xeacf;\nvar REACT_CONCURRENT_MODE_TYPE = hasSymbol ? Symbol.for('react.concurrent_mode') : 0xeacf;\nvar REACT_FORWARD_REF_TYPE = hasSymbol ? Symbol.for('react.forward_ref') : 0xead0;\nvar REACT_SUSPENSE_TYPE = hasSymbol ? Symbol.for('react.suspense') : 0xead1;\nvar REACT_SUSPENSE_LIST_TYPE = hasSymbol ? Symbol.for('react.suspense_list') : 0xead8;\nvar REACT_MEMO_TYPE = hasSymbol ? Symbol.for('react.memo') : 0xead3;\nvar REACT_LAZY_TYPE = hasSymbol ? Symbol.for('react.lazy') : 0xead4;\nvar REACT_BLOCK_TYPE = hasSymbol ? Symbol.for('react.block') : 0xead9;\nvar REACT_FUNDAMENTAL_TYPE = hasSymbol ? Symbol.for('react.fundamental') : 0xead5;\nvar REACT_RESPONDER_TYPE = hasSymbol ? Symbol.for('react.responder') : 0xead6;\nvar REACT_SCOPE_TYPE = hasSymbol ? Symbol.for('react.scope') : 0xead7;\n\nfunction isValidElementType(type) {\n return typeof type === 'string' || typeof type === 'function' || // Note: its typeof might be other than 'symbol' or 'number' if it's a polyfill.\n type === REACT_FRAGMENT_TYPE || type === REACT_CONCURRENT_MODE_TYPE || type === REACT_PROFILER_TYPE || type === REACT_STRICT_MODE_TYPE || type === REACT_SUSPENSE_TYPE || type === REACT_SUSPENSE_LIST_TYPE || typeof type === 'object' && type !== null && (type.$$typeof === REACT_LAZY_TYPE || type.$$typeof === REACT_MEMO_TYPE || type.$$typeof === REACT_PROVIDER_TYPE || type.$$typeof === REACT_CONTEXT_TYPE || type.$$typeof === REACT_FORWARD_REF_TYPE || type.$$typeof === REACT_FUNDAMENTAL_TYPE || type.$$typeof === REACT_RESPONDER_TYPE || type.$$typeof === REACT_SCOPE_TYPE || type.$$typeof === REACT_BLOCK_TYPE);\n}\n\nfunction typeOf(object) {\n if (typeof object === 'object' && object !== null) {\n var $$typeof = object.$$typeof;\n\n switch ($$typeof) {\n case REACT_ELEMENT_TYPE:\n var type = object.type;\n\n switch (type) {\n case REACT_ASYNC_MODE_TYPE:\n case REACT_CONCURRENT_MODE_TYPE:\n case REACT_FRAGMENT_TYPE:\n case REACT_PROFILER_TYPE:\n case REACT_STRICT_MODE_TYPE:\n case REACT_SUSPENSE_TYPE:\n return type;\n\n default:\n var $$typeofType = type && type.$$typeof;\n\n switch ($$typeofType) {\n case REACT_CONTEXT_TYPE:\n case REACT_FORWARD_REF_TYPE:\n case REACT_LAZY_TYPE:\n case REACT_MEMO_TYPE:\n case REACT_PROVIDER_TYPE:\n return $$typeofType;\n\n default:\n return $$typeof;\n }\n\n }\n\n case REACT_PORTAL_TYPE:\n return $$typeof;\n }\n }\n\n return undefined;\n} // AsyncMode is deprecated along with isAsyncMode\n\nvar AsyncMode = REACT_ASYNC_MODE_TYPE;\nvar ConcurrentMode = REACT_CONCURRENT_MODE_TYPE;\nvar ContextConsumer = REACT_CONTEXT_TYPE;\nvar ContextProvider = REACT_PROVIDER_TYPE;\nvar Element = REACT_ELEMENT_TYPE;\nvar ForwardRef = REACT_FORWARD_REF_TYPE;\nvar Fragment = REACT_FRAGMENT_TYPE;\nvar Lazy = REACT_LAZY_TYPE;\nvar Memo = REACT_MEMO_TYPE;\nvar Portal = REACT_PORTAL_TYPE;\nvar Profiler = REACT_PROFILER_TYPE;\nvar StrictMode = REACT_STRICT_MODE_TYPE;\nvar Suspense = REACT_SUSPENSE_TYPE;\nvar hasWarnedAboutDeprecatedIsAsyncMode = false; // AsyncMode should be deprecated\n\nfunction isAsyncMode(object) {\n {\n if (!hasWarnedAboutDeprecatedIsAsyncMode) {\n hasWarnedAboutDeprecatedIsAsyncMode = true; // Using console['warn'] to evade Babel and ESLint\n\n console['warn']('The ReactIs.isAsyncMode() alias has been deprecated, ' + 'and will be removed in React 17+. Update your code to use ' + 'ReactIs.isConcurrentMode() instead. It has the exact same API.');\n }\n }\n\n return isConcurrentMode(object) || typeOf(object) === REACT_ASYNC_MODE_TYPE;\n}\nfunction isConcurrentMode(object) {\n return typeOf(object) === REACT_CONCURRENT_MODE_TYPE;\n}\nfunction isContextConsumer(object) {\n return typeOf(object) === REACT_CONTEXT_TYPE;\n}\nfunction isContextProvider(object) {\n return typeOf(object) === REACT_PROVIDER_TYPE;\n}\nfunction isElement(object) {\n return typeof object === 'object' && object !== null && object.$$typeof === REACT_ELEMENT_TYPE;\n}\nfunction isForwardRef(object) {\n return typeOf(object) === REACT_FORWARD_REF_TYPE;\n}\nfunction isFragment(object) {\n return typeOf(object) === REACT_FRAGMENT_TYPE;\n}\nfunction isLazy(object) {\n return typeOf(object) === REACT_LAZY_TYPE;\n}\nfunction isMemo(object) {\n return typeOf(object) === REACT_MEMO_TYPE;\n}\nfunction isPortal(object) {\n return typeOf(object) === REACT_PORTAL_TYPE;\n}\nfunction isProfiler(object) {\n return typeOf(object) === REACT_PROFILER_TYPE;\n}\nfunction isStrictMode(object) {\n return typeOf(object) === REACT_STRICT_MODE_TYPE;\n}\nfunction isSuspense(object) {\n return typeOf(object) === REACT_SUSPENSE_TYPE;\n}\n\nexports.AsyncMode = AsyncMode;\nexports.ConcurrentMode = ConcurrentMode;\nexports.ContextConsumer = ContextConsumer;\nexports.ContextProvider = ContextProvider;\nexports.Element = Element;\nexports.ForwardRef = ForwardRef;\nexports.Fragment = Fragment;\nexports.Lazy = Lazy;\nexports.Memo = Memo;\nexports.Portal = Portal;\nexports.Profiler = Profiler;\nexports.StrictMode = StrictMode;\nexports.Suspense = Suspense;\nexports.isAsyncMode = isAsyncMode;\nexports.isConcurrentMode = isConcurrentMode;\nexports.isContextConsumer = isContextConsumer;\nexports.isContextProvider = isContextProvider;\nexports.isElement = isElement;\nexports.isForwardRef = isForwardRef;\nexports.isFragment = isFragment;\nexports.isLazy = isLazy;\nexports.isMemo = isMemo;\nexports.isPortal = isPortal;\nexports.isProfiler = isProfiler;\nexports.isStrictMode = isStrictMode;\nexports.isSuspense = isSuspense;\nexports.isValidElementType = isValidElementType;\nexports.typeOf = typeOf;\n })();\n}\n","'use strict';\n\nif (process.env.NODE_ENV === 'production') {\n module.exports = require('./cjs/react-is.production.min.js');\n} else {\n module.exports = require('./cjs/react-is.development.js');\n}\n","/*\nobject-assign\n(c) Sindre Sorhus\n@license MIT\n*/\n\n'use strict';\n/* eslint-disable no-unused-vars */\nvar getOwnPropertySymbols = Object.getOwnPropertySymbols;\nvar hasOwnProperty = Object.prototype.hasOwnProperty;\nvar propIsEnumerable = Object.prototype.propertyIsEnumerable;\n\nfunction toObject(val) {\n\tif (val === null || val === undefined) {\n\t\tthrow new TypeError('Object.assign cannot be called with null or undefined');\n\t}\n\n\treturn Object(val);\n}\n\nfunction shouldUseNative() {\n\ttry {\n\t\tif (!Object.assign) {\n\t\t\treturn false;\n\t\t}\n\n\t\t// Detect buggy property enumeration order in older V8 versions.\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=4118\n\t\tvar test1 = new String('abc'); // eslint-disable-line no-new-wrappers\n\t\ttest1[5] = 'de';\n\t\tif (Object.getOwnPropertyNames(test1)[0] === '5') {\n\t\t\treturn false;\n\t\t}\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=3056\n\t\tvar test2 = {};\n\t\tfor (var i = 0; i < 10; i++) {\n\t\t\ttest2['_' + String.fromCharCode(i)] = i;\n\t\t}\n\t\tvar order2 = Object.getOwnPropertyNames(test2).map(function (n) {\n\t\t\treturn test2[n];\n\t\t});\n\t\tif (order2.join('') !== '0123456789') {\n\t\t\treturn false;\n\t\t}\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=3056\n\t\tvar test3 = {};\n\t\t'abcdefghijklmnopqrst'.split('').forEach(function (letter) {\n\t\t\ttest3[letter] = letter;\n\t\t});\n\t\tif (Object.keys(Object.assign({}, test3)).join('') !==\n\t\t\t\t'abcdefghijklmnopqrst') {\n\t\t\treturn false;\n\t\t}\n\n\t\treturn true;\n\t} catch (err) {\n\t\t// We don't expect any of the above to throw, but better to be safe.\n\t\treturn false;\n\t}\n}\n\nmodule.exports = shouldUseNative() ? Object.assign : function (target, source) {\n\tvar from;\n\tvar to = toObject(target);\n\tvar symbols;\n\n\tfor (var s = 1; s < arguments.length; s++) {\n\t\tfrom = Object(arguments[s]);\n\n\t\tfor (var key in from) {\n\t\t\tif (hasOwnProperty.call(from, key)) {\n\t\t\t\tto[key] = from[key];\n\t\t\t}\n\t\t}\n\n\t\tif (getOwnPropertySymbols) {\n\t\t\tsymbols = getOwnPropertySymbols(from);\n\t\t\tfor (var i = 0; i < symbols.length; i++) {\n\t\t\t\tif (propIsEnumerable.call(from, symbols[i])) {\n\t\t\t\t\tto[symbols[i]] = from[symbols[i]];\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\n\treturn to;\n};\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar ReactPropTypesSecret = 'SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED';\n\nmodule.exports = ReactPropTypesSecret;\n","module.exports = Function.call.bind(Object.prototype.hasOwnProperty);\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar printWarning = function() {};\n\nif (process.env.NODE_ENV !== 'production') {\n var ReactPropTypesSecret = require('./lib/ReactPropTypesSecret');\n var loggedTypeFailures = {};\n var has = require('./lib/has');\n\n printWarning = function(text) {\n var message = 'Warning: ' + text;\n if (typeof console !== 'undefined') {\n console.error(message);\n }\n try {\n // --- Welcome to debugging React ---\n // This error was thrown as a convenience so that you can use this stack\n // to find the callsite that caused this warning to fire.\n throw new Error(message);\n } catch (x) { /**/ }\n };\n}\n\n/**\n * Assert that the values match with the type specs.\n * Error messages are memorized and will only be shown once.\n *\n * @param {object} typeSpecs Map of name to a ReactPropType\n * @param {object} values Runtime values that need to be type-checked\n * @param {string} location e.g. \"prop\", \"context\", \"child context\"\n * @param {string} componentName Name of the component for error messages.\n * @param {?Function} getStack Returns the component stack.\n * @private\n */\nfunction checkPropTypes(typeSpecs, values, location, componentName, getStack) {\n if (process.env.NODE_ENV !== 'production') {\n for (var typeSpecName in typeSpecs) {\n if (has(typeSpecs, typeSpecName)) {\n var error;\n // Prop type validation may throw. In case they do, we don't want to\n // fail the render phase where it didn't fail before. So we log it.\n // After these have been cleaned up, we'll let them throw.\n try {\n // This is intentionally an invariant that gets caught. It's the same\n // behavior as without this statement except with a better message.\n if (typeof typeSpecs[typeSpecName] !== 'function') {\n var err = Error(\n (componentName || 'React class') + ': ' + location + ' type `' + typeSpecName + '` is invalid; ' +\n 'it must be a function, usually from the `prop-types` package, but received `' + typeof typeSpecs[typeSpecName] + '`.' +\n 'This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.'\n );\n err.name = 'Invariant Violation';\n throw err;\n }\n error = typeSpecs[typeSpecName](values, typeSpecName, componentName, location, null, ReactPropTypesSecret);\n } catch (ex) {\n error = ex;\n }\n if (error && !(error instanceof Error)) {\n printWarning(\n (componentName || 'React class') + ': type specification of ' +\n location + ' `' + typeSpecName + '` is invalid; the type checker ' +\n 'function must return `null` or an `Error` but returned a ' + typeof error + '. ' +\n 'You may have forgotten to pass an argument to the type checker ' +\n 'creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and ' +\n 'shape all require an argument).'\n );\n }\n if (error instanceof Error && !(error.message in loggedTypeFailures)) {\n // Only monitor this failure once because there tends to be a lot of the\n // same error.\n loggedTypeFailures[error.message] = true;\n\n var stack = getStack ? getStack() : '';\n\n printWarning(\n 'Failed ' + location + ' type: ' + error.message + (stack != null ? stack : '')\n );\n }\n }\n }\n }\n}\n\n/**\n * Resets warning cache when testing.\n *\n * @private\n */\ncheckPropTypes.resetWarningCache = function() {\n if (process.env.NODE_ENV !== 'production') {\n loggedTypeFailures = {};\n }\n}\n\nmodule.exports = checkPropTypes;\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar ReactIs = require('react-is');\nvar assign = require('object-assign');\n\nvar ReactPropTypesSecret = require('./lib/ReactPropTypesSecret');\nvar has = require('./lib/has');\nvar checkPropTypes = require('./checkPropTypes');\n\nvar printWarning = function() {};\n\nif (process.env.NODE_ENV !== 'production') {\n printWarning = function(text) {\n var message = 'Warning: ' + text;\n if (typeof console !== 'undefined') {\n console.error(message);\n }\n try {\n // --- Welcome to debugging React ---\n // This error was thrown as a convenience so that you can use this stack\n // to find the callsite that caused this warning to fire.\n throw new Error(message);\n } catch (x) {}\n };\n}\n\nfunction emptyFunctionThatReturnsNull() {\n return null;\n}\n\nmodule.exports = function(isValidElement, throwOnDirectAccess) {\n /* global Symbol */\n var ITERATOR_SYMBOL = typeof Symbol === 'function' && Symbol.iterator;\n var FAUX_ITERATOR_SYMBOL = '@@iterator'; // Before Symbol spec.\n\n /**\n * Returns the iterator method function contained on the iterable object.\n *\n * Be sure to invoke the function with the iterable as context:\n *\n * var iteratorFn = getIteratorFn(myIterable);\n * if (iteratorFn) {\n * var iterator = iteratorFn.call(myIterable);\n * ...\n * }\n *\n * @param {?object} maybeIterable\n * @return {?function}\n */\n function getIteratorFn(maybeIterable) {\n var iteratorFn = maybeIterable && (ITERATOR_SYMBOL && maybeIterable[ITERATOR_SYMBOL] || maybeIterable[FAUX_ITERATOR_SYMBOL]);\n if (typeof iteratorFn === 'function') {\n return iteratorFn;\n }\n }\n\n /**\n * Collection of methods that allow declaration and validation of props that are\n * supplied to React components. Example usage:\n *\n * var Props = require('ReactPropTypes');\n * var MyArticle = React.createClass({\n * propTypes: {\n * // An optional string prop named \"description\".\n * description: Props.string,\n *\n * // A required enum prop named \"category\".\n * category: Props.oneOf(['News','Photos']).isRequired,\n *\n * // A prop named \"dialog\" that requires an instance of Dialog.\n * dialog: Props.instanceOf(Dialog).isRequired\n * },\n * render: function() { ... }\n * });\n *\n * A more formal specification of how these methods are used:\n *\n * type := array|bool|func|object|number|string|oneOf([...])|instanceOf(...)\n * decl := ReactPropTypes.{type}(.isRequired)?\n *\n * Each and every declaration produces a function with the same signature. This\n * allows the creation of custom validation functions. For example:\n *\n * var MyLink = React.createClass({\n * propTypes: {\n * // An optional string or URI prop named \"href\".\n * href: function(props, propName, componentName) {\n * var propValue = props[propName];\n * if (propValue != null && typeof propValue !== 'string' &&\n * !(propValue instanceof URI)) {\n * return new Error(\n * 'Expected a string or an URI for ' + propName + ' in ' +\n * componentName\n * );\n * }\n * }\n * },\n * render: function() {...}\n * });\n *\n * @internal\n */\n\n var ANONYMOUS = '<>';\n\n // Important!\n // Keep this list in sync with production version in `./factoryWithThrowingShims.js`.\n var ReactPropTypes = {\n array: createPrimitiveTypeChecker('array'),\n bigint: createPrimitiveTypeChecker('bigint'),\n bool: createPrimitiveTypeChecker('boolean'),\n func: createPrimitiveTypeChecker('function'),\n number: createPrimitiveTypeChecker('number'),\n object: createPrimitiveTypeChecker('object'),\n string: createPrimitiveTypeChecker('string'),\n symbol: createPrimitiveTypeChecker('symbol'),\n\n any: createAnyTypeChecker(),\n arrayOf: createArrayOfTypeChecker,\n element: createElementTypeChecker(),\n elementType: createElementTypeTypeChecker(),\n instanceOf: createInstanceTypeChecker,\n node: createNodeChecker(),\n objectOf: createObjectOfTypeChecker,\n oneOf: createEnumTypeChecker,\n oneOfType: createUnionTypeChecker,\n shape: createShapeTypeChecker,\n exact: createStrictShapeTypeChecker,\n };\n\n /**\n * inlined Object.is polyfill to avoid requiring consumers ship their own\n * https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object/is\n */\n /*eslint-disable no-self-compare*/\n function is(x, y) {\n // SameValue algorithm\n if (x === y) {\n // Steps 1-5, 7-10\n // Steps 6.b-6.e: +0 != -0\n return x !== 0 || 1 / x === 1 / y;\n } else {\n // Step 6.a: NaN == NaN\n return x !== x && y !== y;\n }\n }\n /*eslint-enable no-self-compare*/\n\n /**\n * We use an Error-like object for backward compatibility as people may call\n * PropTypes directly and inspect their output. However, we don't use real\n * Errors anymore. We don't inspect their stack anyway, and creating them\n * is prohibitively expensive if they are created too often, such as what\n * happens in oneOfType() for any type before the one that matched.\n */\n function PropTypeError(message, data) {\n this.message = message;\n this.data = data && typeof data === 'object' ? data: {};\n this.stack = '';\n }\n // Make `instanceof Error` still work for returned errors.\n PropTypeError.prototype = Error.prototype;\n\n function createChainableTypeChecker(validate) {\n if (process.env.NODE_ENV !== 'production') {\n var manualPropTypeCallCache = {};\n var manualPropTypeWarningCount = 0;\n }\n function checkType(isRequired, props, propName, componentName, location, propFullName, secret) {\n componentName = componentName || ANONYMOUS;\n propFullName = propFullName || propName;\n\n if (secret !== ReactPropTypesSecret) {\n if (throwOnDirectAccess) {\n // New behavior only for users of `prop-types` package\n var err = new Error(\n 'Calling PropTypes validators directly is not supported by the `prop-types` package. ' +\n 'Use `PropTypes.checkPropTypes()` to call them. ' +\n 'Read more at http://fb.me/use-check-prop-types'\n );\n err.name = 'Invariant Violation';\n throw err;\n } else if (process.env.NODE_ENV !== 'production' && typeof console !== 'undefined') {\n // Old behavior for people using React.PropTypes\n var cacheKey = componentName + ':' + propName;\n if (\n !manualPropTypeCallCache[cacheKey] &&\n // Avoid spamming the console because they are often not actionable except for lib authors\n manualPropTypeWarningCount < 3\n ) {\n printWarning(\n 'You are manually calling a React.PropTypes validation ' +\n 'function for the `' + propFullName + '` prop on `' + componentName + '`. This is deprecated ' +\n 'and will throw in the standalone `prop-types` package. ' +\n 'You may be seeing this warning due to a third-party PropTypes ' +\n 'library. See https://fb.me/react-warning-dont-call-proptypes ' + 'for details.'\n );\n manualPropTypeCallCache[cacheKey] = true;\n manualPropTypeWarningCount++;\n }\n }\n }\n if (props[propName] == null) {\n if (isRequired) {\n if (props[propName] === null) {\n return new PropTypeError('The ' + location + ' `' + propFullName + '` is marked as required ' + ('in `' + componentName + '`, but its value is `null`.'));\n }\n return new PropTypeError('The ' + location + ' `' + propFullName + '` is marked as required in ' + ('`' + componentName + '`, but its value is `undefined`.'));\n }\n return null;\n } else {\n return validate(props, propName, componentName, location, propFullName);\n }\n }\n\n var chainedCheckType = checkType.bind(null, false);\n chainedCheckType.isRequired = checkType.bind(null, true);\n\n return chainedCheckType;\n }\n\n function createPrimitiveTypeChecker(expectedType) {\n function validate(props, propName, componentName, location, propFullName, secret) {\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== expectedType) {\n // `propValue` being instance of, say, date/regexp, pass the 'object'\n // check, but we can offer a more precise error message here rather than\n // 'of type `object`'.\n var preciseType = getPreciseType(propValue);\n\n return new PropTypeError(\n 'Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + preciseType + '` supplied to `' + componentName + '`, expected ') + ('`' + expectedType + '`.'),\n {expectedType: expectedType}\n );\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createAnyTypeChecker() {\n return createChainableTypeChecker(emptyFunctionThatReturnsNull);\n }\n\n function createArrayOfTypeChecker(typeChecker) {\n function validate(props, propName, componentName, location, propFullName) {\n if (typeof typeChecker !== 'function') {\n return new PropTypeError('Property `' + propFullName + '` of component `' + componentName + '` has invalid PropType notation inside arrayOf.');\n }\n var propValue = props[propName];\n if (!Array.isArray(propValue)) {\n var propType = getPropType(propValue);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected an array.'));\n }\n for (var i = 0; i < propValue.length; i++) {\n var error = typeChecker(propValue, i, componentName, location, propFullName + '[' + i + ']', ReactPropTypesSecret);\n if (error instanceof Error) {\n return error;\n }\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createElementTypeChecker() {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n if (!isValidElement(propValue)) {\n var propType = getPropType(propValue);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected a single ReactElement.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createElementTypeTypeChecker() {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n if (!ReactIs.isValidElementType(propValue)) {\n var propType = getPropType(propValue);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected a single ReactElement type.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createInstanceTypeChecker(expectedClass) {\n function validate(props, propName, componentName, location, propFullName) {\n if (!(props[propName] instanceof expectedClass)) {\n var expectedClassName = expectedClass.name || ANONYMOUS;\n var actualClassName = getClassName(props[propName]);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + actualClassName + '` supplied to `' + componentName + '`, expected ') + ('instance of `' + expectedClassName + '`.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createEnumTypeChecker(expectedValues) {\n if (!Array.isArray(expectedValues)) {\n if (process.env.NODE_ENV !== 'production') {\n if (arguments.length > 1) {\n printWarning(\n 'Invalid arguments supplied to oneOf, expected an array, got ' + arguments.length + ' arguments. ' +\n 'A common mistake is to write oneOf(x, y, z) instead of oneOf([x, y, z]).'\n );\n } else {\n printWarning('Invalid argument supplied to oneOf, expected an array.');\n }\n }\n return emptyFunctionThatReturnsNull;\n }\n\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n for (var i = 0; i < expectedValues.length; i++) {\n if (is(propValue, expectedValues[i])) {\n return null;\n }\n }\n\n var valuesString = JSON.stringify(expectedValues, function replacer(key, value) {\n var type = getPreciseType(value);\n if (type === 'symbol') {\n return String(value);\n }\n return value;\n });\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of value `' + String(propValue) + '` ' + ('supplied to `' + componentName + '`, expected one of ' + valuesString + '.'));\n }\n return createChainableTypeChecker(validate);\n }\n\n function createObjectOfTypeChecker(typeChecker) {\n function validate(props, propName, componentName, location, propFullName) {\n if (typeof typeChecker !== 'function') {\n return new PropTypeError('Property `' + propFullName + '` of component `' + componentName + '` has invalid PropType notation inside objectOf.');\n }\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== 'object') {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected an object.'));\n }\n for (var key in propValue) {\n if (has(propValue, key)) {\n var error = typeChecker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret);\n if (error instanceof Error) {\n return error;\n }\n }\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createUnionTypeChecker(arrayOfTypeCheckers) {\n if (!Array.isArray(arrayOfTypeCheckers)) {\n process.env.NODE_ENV !== 'production' ? printWarning('Invalid argument supplied to oneOfType, expected an instance of array.') : void 0;\n return emptyFunctionThatReturnsNull;\n }\n\n for (var i = 0; i < arrayOfTypeCheckers.length; i++) {\n var checker = arrayOfTypeCheckers[i];\n if (typeof checker !== 'function') {\n printWarning(\n 'Invalid argument supplied to oneOfType. Expected an array of check functions, but ' +\n 'received ' + getPostfixForTypeWarning(checker) + ' at index ' + i + '.'\n );\n return emptyFunctionThatReturnsNull;\n }\n }\n\n function validate(props, propName, componentName, location, propFullName) {\n var expectedTypes = [];\n for (var i = 0; i < arrayOfTypeCheckers.length; i++) {\n var checker = arrayOfTypeCheckers[i];\n var checkerResult = checker(props, propName, componentName, location, propFullName, ReactPropTypesSecret);\n if (checkerResult == null) {\n return null;\n }\n if (checkerResult.data && has(checkerResult.data, 'expectedType')) {\n expectedTypes.push(checkerResult.data.expectedType);\n }\n }\n var expectedTypesMessage = (expectedTypes.length > 0) ? ', expected one of type [' + expectedTypes.join(', ') + ']': '';\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` supplied to ' + ('`' + componentName + '`' + expectedTypesMessage + '.'));\n }\n return createChainableTypeChecker(validate);\n }\n\n function createNodeChecker() {\n function validate(props, propName, componentName, location, propFullName) {\n if (!isNode(props[propName])) {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` supplied to ' + ('`' + componentName + '`, expected a ReactNode.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function invalidValidatorError(componentName, location, propFullName, key, type) {\n return new PropTypeError(\n (componentName || 'React class') + ': ' + location + ' type `' + propFullName + '.' + key + '` is invalid; ' +\n 'it must be a function, usually from the `prop-types` package, but received `' + type + '`.'\n );\n }\n\n function createShapeTypeChecker(shapeTypes) {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== 'object') {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type `' + propType + '` ' + ('supplied to `' + componentName + '`, expected `object`.'));\n }\n for (var key in shapeTypes) {\n var checker = shapeTypes[key];\n if (typeof checker !== 'function') {\n return invalidValidatorError(componentName, location, propFullName, key, getPreciseType(checker));\n }\n var error = checker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret);\n if (error) {\n return error;\n }\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createStrictShapeTypeChecker(shapeTypes) {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== 'object') {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type `' + propType + '` ' + ('supplied to `' + componentName + '`, expected `object`.'));\n }\n // We need to check all keys in case some are required but missing from props.\n var allKeys = assign({}, props[propName], shapeTypes);\n for (var key in allKeys) {\n var checker = shapeTypes[key];\n if (has(shapeTypes, key) && typeof checker !== 'function') {\n return invalidValidatorError(componentName, location, propFullName, key, getPreciseType(checker));\n }\n if (!checker) {\n return new PropTypeError(\n 'Invalid ' + location + ' `' + propFullName + '` key `' + key + '` supplied to `' + componentName + '`.' +\n '\\nBad object: ' + JSON.stringify(props[propName], null, ' ') +\n '\\nValid keys: ' + JSON.stringify(Object.keys(shapeTypes), null, ' ')\n );\n }\n var error = checker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret);\n if (error) {\n return error;\n }\n }\n return null;\n }\n\n return createChainableTypeChecker(validate);\n }\n\n function isNode(propValue) {\n switch (typeof propValue) {\n case 'number':\n case 'string':\n case 'undefined':\n return true;\n case 'boolean':\n return !propValue;\n case 'object':\n if (Array.isArray(propValue)) {\n return propValue.every(isNode);\n }\n if (propValue === null || isValidElement(propValue)) {\n return true;\n }\n\n var iteratorFn = getIteratorFn(propValue);\n if (iteratorFn) {\n var iterator = iteratorFn.call(propValue);\n var step;\n if (iteratorFn !== propValue.entries) {\n while (!(step = iterator.next()).done) {\n if (!isNode(step.value)) {\n return false;\n }\n }\n } else {\n // Iterator will provide entry [k,v] tuples rather than values.\n while (!(step = iterator.next()).done) {\n var entry = step.value;\n if (entry) {\n if (!isNode(entry[1])) {\n return false;\n }\n }\n }\n }\n } else {\n return false;\n }\n\n return true;\n default:\n return false;\n }\n }\n\n function isSymbol(propType, propValue) {\n // Native Symbol.\n if (propType === 'symbol') {\n return true;\n }\n\n // falsy value can't be a Symbol\n if (!propValue) {\n return false;\n }\n\n // 19.4.3.5 Symbol.prototype[@@toStringTag] === 'Symbol'\n if (propValue['@@toStringTag'] === 'Symbol') {\n return true;\n }\n\n // Fallback for non-spec compliant Symbols which are polyfilled.\n if (typeof Symbol === 'function' && propValue instanceof Symbol) {\n return true;\n }\n\n return false;\n }\n\n // Equivalent of `typeof` but with special handling for array and regexp.\n function getPropType(propValue) {\n var propType = typeof propValue;\n if (Array.isArray(propValue)) {\n return 'array';\n }\n if (propValue instanceof RegExp) {\n // Old webkits (at least until Android 4.0) return 'function' rather than\n // 'object' for typeof a RegExp. We'll normalize this here so that /bla/\n // passes PropTypes.object.\n return 'object';\n }\n if (isSymbol(propType, propValue)) {\n return 'symbol';\n }\n return propType;\n }\n\n // This handles more types than `getPropType`. Only used for error messages.\n // See `createPrimitiveTypeChecker`.\n function getPreciseType(propValue) {\n if (typeof propValue === 'undefined' || propValue === null) {\n return '' + propValue;\n }\n var propType = getPropType(propValue);\n if (propType === 'object') {\n if (propValue instanceof Date) {\n return 'date';\n } else if (propValue instanceof RegExp) {\n return 'regexp';\n }\n }\n return propType;\n }\n\n // Returns a string that is postfixed to a warning about an invalid type.\n // For example, \"undefined\" or \"of type array\"\n function getPostfixForTypeWarning(value) {\n var type = getPreciseType(value);\n switch (type) {\n case 'array':\n case 'object':\n return 'an ' + type;\n case 'boolean':\n case 'date':\n case 'regexp':\n return 'a ' + type;\n default:\n return type;\n }\n }\n\n // Returns class name of the object, if any.\n function getClassName(propValue) {\n if (!propValue.constructor || !propValue.constructor.name) {\n return ANONYMOUS;\n }\n return propValue.constructor.name;\n }\n\n ReactPropTypes.checkPropTypes = checkPropTypes;\n ReactPropTypes.resetWarningCache = checkPropTypes.resetWarningCache;\n ReactPropTypes.PropTypes = ReactPropTypes;\n\n return ReactPropTypes;\n};\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar ReactPropTypesSecret = require('./lib/ReactPropTypesSecret');\n\nfunction emptyFunction() {}\nfunction emptyFunctionWithReset() {}\nemptyFunctionWithReset.resetWarningCache = emptyFunction;\n\nmodule.exports = function() {\n function shim(props, propName, componentName, location, propFullName, secret) {\n if (secret === ReactPropTypesSecret) {\n // It is still safe when called from React.\n return;\n }\n var err = new Error(\n 'Calling PropTypes validators directly is not supported by the `prop-types` package. ' +\n 'Use PropTypes.checkPropTypes() to call them. ' +\n 'Read more at http://fb.me/use-check-prop-types'\n );\n err.name = 'Invariant Violation';\n throw err;\n };\n shim.isRequired = shim;\n function getShim() {\n return shim;\n };\n // Important!\n // Keep this list in sync with production version in `./factoryWithTypeCheckers.js`.\n var ReactPropTypes = {\n array: shim,\n bigint: shim,\n bool: shim,\n func: shim,\n number: shim,\n object: shim,\n string: shim,\n symbol: shim,\n\n any: shim,\n arrayOf: getShim,\n element: shim,\n elementType: shim,\n instanceOf: getShim,\n node: shim,\n objectOf: getShim,\n oneOf: getShim,\n oneOfType: getShim,\n shape: getShim,\n exact: getShim,\n\n checkPropTypes: emptyFunctionWithReset,\n resetWarningCache: emptyFunction\n };\n\n ReactPropTypes.PropTypes = ReactPropTypes;\n\n return ReactPropTypes;\n};\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\nif (process.env.NODE_ENV !== 'production') {\n var ReactIs = require('react-is');\n\n // By explicitly using `prop-types` you are opting into new development behavior.\n // http://fb.me/prop-types-in-prod\n var throwOnDirectAccess = true;\n module.exports = require('./factoryWithTypeCheckers')(ReactIs.isElement, throwOnDirectAccess);\n} else {\n // By explicitly using `prop-types` you are opting into new production behavior.\n // http://fb.me/prop-types-in-prod\n module.exports = require('./factoryWithThrowingShims')();\n}\n","import PropTypes from 'prop-types';\nimport chainPropTypes from '../chainPropTypes';\nfunction isClassComponent(elementType) {\n // elementType.prototype?.isReactComponent\n const {\n prototype = {}\n } = elementType;\n return Boolean(prototype.isReactComponent);\n}\nfunction acceptingRef(props, propName, componentName, location, propFullName) {\n const element = props[propName];\n const safePropName = propFullName || propName;\n if (element == null ||\n // When server-side rendering React doesn't warn either.\n // This is not an accurate check for SSR.\n // This is only in place for Emotion compat.\n // TODO: Revisit once https://github.com/facebook/react/issues/20047 is resolved.\n typeof window === 'undefined') {\n return null;\n }\n let warningHint;\n const elementType = element.type;\n /**\n * Blacklisting instead of whitelisting\n *\n * Blacklisting will miss some components, such as React.Fragment. Those will at least\n * trigger a warning in React.\n * We can't whitelist because there is no safe way to detect React.forwardRef\n * or class components. \"Safe\" means there's no public API.\n *\n */\n if (typeof elementType === 'function' && !isClassComponent(elementType)) {\n warningHint = 'Did you accidentally use a plain function component for an element instead?';\n }\n if (warningHint !== undefined) {\n return new Error(`Invalid ${location} \\`${safePropName}\\` supplied to \\`${componentName}\\`. ` + `Expected an element that can hold a ref. ${warningHint} ` + 'For more information see https://mui.com/r/caveat-with-refs-guide');\n }\n return null;\n}\nconst elementAcceptingRef = chainPropTypes(PropTypes.element, acceptingRef);\nelementAcceptingRef.isRequired = chainPropTypes(PropTypes.element.isRequired, acceptingRef);\nexport default elementAcceptingRef;","import _extends from \"@babel/runtime/helpers/esm/extends\";\n// This module is based on https://github.com/airbnb/prop-types-exact repository.\n// However, in order to reduce the number of dependencies and to remove some extra safe checks\n// the module was forked.\n\nconst specialProperty = 'exact-prop: \\u200b';\nexport default function exactProp(propTypes) {\n if (process.env.NODE_ENV === 'production') {\n return propTypes;\n }\n return _extends({}, propTypes, {\n [specialProperty]: props => {\n const unsupportedProps = Object.keys(props).filter(prop => !propTypes.hasOwnProperty(prop));\n if (unsupportedProps.length > 0) {\n return new Error(`The following props are not supported: ${unsupportedProps.map(prop => `\\`${prop}\\``).join(', ')}. Please remove them.`);\n }\n return null;\n }\n });\n}","/**\n * WARNING: Don't import this directly.\n * Use `MuiError` from `@mui/internal-babel-macros/MuiError.macro` instead.\n * @param {number} code\n */\nexport default function formatMuiErrorMessage(code) {\n // Apply babel-plugin-transform-template-literals in loose mode\n // loose mode is safe if we're concatenating primitives\n // see https://babeljs.io/docs/en/babel-plugin-transform-template-literals#loose\n /* eslint-disable prefer-template */\n let url = 'https://mui.com/production-error/?code=' + code;\n for (let i = 1; i < arguments.length; i += 1) {\n // rest params over-transpile for this case\n // eslint-disable-next-line prefer-rest-params\n url += '&args[]=' + encodeURIComponent(arguments[i]);\n }\n return 'Minified MUI error #' + code + '; visit ' + url + ' for the full message.';\n /* eslint-enable prefer-template */\n}","/**\n * @license React\n * react-is.production.min.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n'use strict';var b=Symbol.for(\"react.element\"),c=Symbol.for(\"react.portal\"),d=Symbol.for(\"react.fragment\"),e=Symbol.for(\"react.strict_mode\"),f=Symbol.for(\"react.profiler\"),g=Symbol.for(\"react.provider\"),h=Symbol.for(\"react.context\"),k=Symbol.for(\"react.server_context\"),l=Symbol.for(\"react.forward_ref\"),m=Symbol.for(\"react.suspense\"),n=Symbol.for(\"react.suspense_list\"),p=Symbol.for(\"react.memo\"),q=Symbol.for(\"react.lazy\"),t=Symbol.for(\"react.offscreen\"),u;u=Symbol.for(\"react.module.reference\");\nfunction v(a){if(\"object\"===typeof a&&null!==a){var r=a.$$typeof;switch(r){case b:switch(a=a.type,a){case d:case f:case e:case m:case n:return a;default:switch(a=a&&a.$$typeof,a){case k:case h:case l:case q:case p:case g:return a;default:return r}}case c:return r}}}exports.ContextConsumer=h;exports.ContextProvider=g;exports.Element=b;exports.ForwardRef=l;exports.Fragment=d;exports.Lazy=q;exports.Memo=p;exports.Portal=c;exports.Profiler=f;exports.StrictMode=e;exports.Suspense=m;\nexports.SuspenseList=n;exports.isAsyncMode=function(){return!1};exports.isConcurrentMode=function(){return!1};exports.isContextConsumer=function(a){return v(a)===h};exports.isContextProvider=function(a){return v(a)===g};exports.isElement=function(a){return\"object\"===typeof a&&null!==a&&a.$$typeof===b};exports.isForwardRef=function(a){return v(a)===l};exports.isFragment=function(a){return v(a)===d};exports.isLazy=function(a){return v(a)===q};exports.isMemo=function(a){return v(a)===p};\nexports.isPortal=function(a){return v(a)===c};exports.isProfiler=function(a){return v(a)===f};exports.isStrictMode=function(a){return v(a)===e};exports.isSuspense=function(a){return v(a)===m};exports.isSuspenseList=function(a){return v(a)===n};\nexports.isValidElementType=function(a){return\"string\"===typeof a||\"function\"===typeof a||a===d||a===f||a===e||a===m||a===n||a===t||\"object\"===typeof a&&null!==a&&(a.$$typeof===q||a.$$typeof===p||a.$$typeof===g||a.$$typeof===h||a.$$typeof===l||a.$$typeof===u||void 0!==a.getModuleId)?!0:!1};exports.typeOf=v;\n","/**\n * @license React\n * react-is.development.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nif (process.env.NODE_ENV !== \"production\") {\n (function() {\n'use strict';\n\n// ATTENTION\n// When adding new symbols to this file,\n// Please consider also adding to 'react-devtools-shared/src/backend/ReactSymbols'\n// The Symbol used to tag the ReactElement-like types.\nvar REACT_ELEMENT_TYPE = Symbol.for('react.element');\nvar REACT_PORTAL_TYPE = Symbol.for('react.portal');\nvar REACT_FRAGMENT_TYPE = Symbol.for('react.fragment');\nvar REACT_STRICT_MODE_TYPE = Symbol.for('react.strict_mode');\nvar REACT_PROFILER_TYPE = Symbol.for('react.profiler');\nvar REACT_PROVIDER_TYPE = Symbol.for('react.provider');\nvar REACT_CONTEXT_TYPE = Symbol.for('react.context');\nvar REACT_SERVER_CONTEXT_TYPE = Symbol.for('react.server_context');\nvar REACT_FORWARD_REF_TYPE = Symbol.for('react.forward_ref');\nvar REACT_SUSPENSE_TYPE = Symbol.for('react.suspense');\nvar REACT_SUSPENSE_LIST_TYPE = Symbol.for('react.suspense_list');\nvar REACT_MEMO_TYPE = Symbol.for('react.memo');\nvar REACT_LAZY_TYPE = Symbol.for('react.lazy');\nvar REACT_OFFSCREEN_TYPE = Symbol.for('react.offscreen');\n\n// -----------------------------------------------------------------------------\n\nvar enableScopeAPI = false; // Experimental Create Event Handle API.\nvar enableCacheElement = false;\nvar enableTransitionTracing = false; // No known bugs, but needs performance testing\n\nvar enableLegacyHidden = false; // Enables unstable_avoidThisFallback feature in Fiber\n// stuff. Intended to enable React core members to more easily debug scheduling\n// issues in DEV builds.\n\nvar enableDebugTracing = false; // Track which Fiber(s) schedule render work.\n\nvar REACT_MODULE_REFERENCE;\n\n{\n REACT_MODULE_REFERENCE = Symbol.for('react.module.reference');\n}\n\nfunction isValidElementType(type) {\n if (typeof type === 'string' || typeof type === 'function') {\n return true;\n } // Note: typeof might be other than 'symbol' or 'number' (e.g. if it's a polyfill).\n\n\n if (type === REACT_FRAGMENT_TYPE || type === REACT_PROFILER_TYPE || enableDebugTracing || type === REACT_STRICT_MODE_TYPE || type === REACT_SUSPENSE_TYPE || type === REACT_SUSPENSE_LIST_TYPE || enableLegacyHidden || type === REACT_OFFSCREEN_TYPE || enableScopeAPI || enableCacheElement || enableTransitionTracing ) {\n return true;\n }\n\n if (typeof type === 'object' && type !== null) {\n if (type.$$typeof === REACT_LAZY_TYPE || type.$$typeof === REACT_MEMO_TYPE || type.$$typeof === REACT_PROVIDER_TYPE || type.$$typeof === REACT_CONTEXT_TYPE || type.$$typeof === REACT_FORWARD_REF_TYPE || // This needs to include all possible module reference object\n // types supported by any Flight configuration anywhere since\n // we don't know which Flight build this will end up being used\n // with.\n type.$$typeof === REACT_MODULE_REFERENCE || type.getModuleId !== undefined) {\n return true;\n }\n }\n\n return false;\n}\n\nfunction typeOf(object) {\n if (typeof object === 'object' && object !== null) {\n var $$typeof = object.$$typeof;\n\n switch ($$typeof) {\n case REACT_ELEMENT_TYPE:\n var type = object.type;\n\n switch (type) {\n case REACT_FRAGMENT_TYPE:\n case REACT_PROFILER_TYPE:\n case REACT_STRICT_MODE_TYPE:\n case REACT_SUSPENSE_TYPE:\n case REACT_SUSPENSE_LIST_TYPE:\n return type;\n\n default:\n var $$typeofType = type && type.$$typeof;\n\n switch ($$typeofType) {\n case REACT_SERVER_CONTEXT_TYPE:\n case REACT_CONTEXT_TYPE:\n case REACT_FORWARD_REF_TYPE:\n case REACT_LAZY_TYPE:\n case REACT_MEMO_TYPE:\n case REACT_PROVIDER_TYPE:\n return $$typeofType;\n\n default:\n return $$typeof;\n }\n\n }\n\n case REACT_PORTAL_TYPE:\n return $$typeof;\n }\n }\n\n return undefined;\n}\nvar ContextConsumer = REACT_CONTEXT_TYPE;\nvar ContextProvider = REACT_PROVIDER_TYPE;\nvar Element = REACT_ELEMENT_TYPE;\nvar ForwardRef = REACT_FORWARD_REF_TYPE;\nvar Fragment = REACT_FRAGMENT_TYPE;\nvar Lazy = REACT_LAZY_TYPE;\nvar Memo = REACT_MEMO_TYPE;\nvar Portal = REACT_PORTAL_TYPE;\nvar Profiler = REACT_PROFILER_TYPE;\nvar StrictMode = REACT_STRICT_MODE_TYPE;\nvar Suspense = REACT_SUSPENSE_TYPE;\nvar SuspenseList = REACT_SUSPENSE_LIST_TYPE;\nvar hasWarnedAboutDeprecatedIsAsyncMode = false;\nvar hasWarnedAboutDeprecatedIsConcurrentMode = false; // AsyncMode should be deprecated\n\nfunction isAsyncMode(object) {\n {\n if (!hasWarnedAboutDeprecatedIsAsyncMode) {\n hasWarnedAboutDeprecatedIsAsyncMode = true; // Using console['warn'] to evade Babel and ESLint\n\n console['warn']('The ReactIs.isAsyncMode() alias has been deprecated, ' + 'and will be removed in React 18+.');\n }\n }\n\n return false;\n}\nfunction isConcurrentMode(object) {\n {\n if (!hasWarnedAboutDeprecatedIsConcurrentMode) {\n hasWarnedAboutDeprecatedIsConcurrentMode = true; // Using console['warn'] to evade Babel and ESLint\n\n console['warn']('The ReactIs.isConcurrentMode() alias has been deprecated, ' + 'and will be removed in React 18+.');\n }\n }\n\n return false;\n}\nfunction isContextConsumer(object) {\n return typeOf(object) === REACT_CONTEXT_TYPE;\n}\nfunction isContextProvider(object) {\n return typeOf(object) === REACT_PROVIDER_TYPE;\n}\nfunction isElement(object) {\n return typeof object === 'object' && object !== null && object.$$typeof === REACT_ELEMENT_TYPE;\n}\nfunction isForwardRef(object) {\n return typeOf(object) === REACT_FORWARD_REF_TYPE;\n}\nfunction isFragment(object) {\n return typeOf(object) === REACT_FRAGMENT_TYPE;\n}\nfunction isLazy(object) {\n return typeOf(object) === REACT_LAZY_TYPE;\n}\nfunction isMemo(object) {\n return typeOf(object) === REACT_MEMO_TYPE;\n}\nfunction isPortal(object) {\n return typeOf(object) === REACT_PORTAL_TYPE;\n}\nfunction isProfiler(object) {\n return typeOf(object) === REACT_PROFILER_TYPE;\n}\nfunction isStrictMode(object) {\n return typeOf(object) === REACT_STRICT_MODE_TYPE;\n}\nfunction isSuspense(object) {\n return typeOf(object) === REACT_SUSPENSE_TYPE;\n}\nfunction isSuspenseList(object) {\n return typeOf(object) === REACT_SUSPENSE_LIST_TYPE;\n}\n\nexports.ContextConsumer = ContextConsumer;\nexports.ContextProvider = ContextProvider;\nexports.Element = Element;\nexports.ForwardRef = ForwardRef;\nexports.Fragment = Fragment;\nexports.Lazy = Lazy;\nexports.Memo = Memo;\nexports.Portal = Portal;\nexports.Profiler = Profiler;\nexports.StrictMode = StrictMode;\nexports.Suspense = Suspense;\nexports.SuspenseList = SuspenseList;\nexports.isAsyncMode = isAsyncMode;\nexports.isConcurrentMode = isConcurrentMode;\nexports.isContextConsumer = isContextConsumer;\nexports.isContextProvider = isContextProvider;\nexports.isElement = isElement;\nexports.isForwardRef = isForwardRef;\nexports.isFragment = isFragment;\nexports.isLazy = isLazy;\nexports.isMemo = isMemo;\nexports.isPortal = isPortal;\nexports.isProfiler = isProfiler;\nexports.isStrictMode = isStrictMode;\nexports.isSuspense = isSuspense;\nexports.isSuspenseList = isSuspenseList;\nexports.isValidElementType = isValidElementType;\nexports.typeOf = typeOf;\n })();\n}\n","'use strict';\n\nif (process.env.NODE_ENV === 'production') {\n module.exports = require('./cjs/react-is.production.min.js');\n} else {\n module.exports = require('./cjs/react-is.development.js');\n}\n","import { ForwardRef, Memo } from 'react-is';\n\n// Simplified polyfill for IE11 support\n// https://github.com/JamesMGreene/Function.name/blob/58b314d4a983110c3682f1228f845d39ccca1817/Function.name.js#L3\nconst fnNameMatchRegex = /^\\s*function(?:\\s|\\s*\\/\\*.*\\*\\/\\s*)+([^(\\s/]*)\\s*/;\nexport function getFunctionName(fn) {\n const match = `${fn}`.match(fnNameMatchRegex);\n const name = match && match[1];\n return name || '';\n}\nfunction getFunctionComponentName(Component, fallback = '') {\n return Component.displayName || Component.name || getFunctionName(Component) || fallback;\n}\nfunction getWrappedName(outerType, innerType, wrapperName) {\n const functionName = getFunctionComponentName(innerType);\n return outerType.displayName || (functionName !== '' ? `${wrapperName}(${functionName})` : wrapperName);\n}\n\n/**\n * cherry-pick from\n * https://github.com/facebook/react/blob/769b1f270e1251d9dbdce0fcbd9e92e502d059b8/packages/shared/getComponentName.js\n * originally forked from recompose/getDisplayName with added IE11 support\n */\nexport default function getDisplayName(Component) {\n if (Component == null) {\n return undefined;\n }\n if (typeof Component === 'string') {\n return Component;\n }\n if (typeof Component === 'function') {\n return getFunctionComponentName(Component, 'Component');\n }\n\n // TypeScript can't have components as objects but they exist in the form of `memo` or `Suspense`\n if (typeof Component === 'object') {\n switch (Component.$$typeof) {\n case ForwardRef:\n return getWrappedName(Component, Component.render, 'ForwardRef');\n case Memo:\n return getWrappedName(Component, Component.type, 'memo');\n default:\n return undefined;\n }\n }\n return undefined;\n}","export default function HTMLElementType(props, propName, componentName, location, propFullName) {\n if (process.env.NODE_ENV === 'production') {\n return null;\n }\n const propValue = props[propName];\n const safePropName = propFullName || propName;\n if (propValue == null) {\n return null;\n }\n if (propValue && propValue.nodeType !== 1) {\n return new Error(`Invalid ${location} \\`${safePropName}\\` supplied to \\`${componentName}\\`. ` + `Expected an HTMLElement.`);\n }\n return null;\n}","import PropTypes from 'prop-types';\nconst refType = PropTypes.oneOfType([PropTypes.func, PropTypes.object]);\nexport default refType;","import _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\n// It should to be noted that this function isn't equivalent to `text-transform: capitalize`.\n//\n// A strict capitalization should uppercase the first letter of each word in the sentence.\n// We only handle the first word.\nexport default function capitalize(string) {\n if (typeof string !== 'string') {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: \\`capitalize(string)\\` expects a string argument.` : _formatMuiErrorMessage(7));\n }\n return string.charAt(0).toUpperCase() + string.slice(1);\n}","/**\n * Safe chained function.\n *\n * Will only create a new function if needed,\n * otherwise will pass back existing functions or null.\n */\nexport default function createChainedFunction(...funcs) {\n return funcs.reduce((acc, func) => {\n if (func == null) {\n return acc;\n }\n return function chainedFunction(...args) {\n acc.apply(this, args);\n func.apply(this, args);\n };\n }, () => {});\n}","// Corresponds to 10 frames at 60 Hz.\n// A few bytes payload overhead when lodash/debounce is ~3 kB and debounce ~300 B.\nexport default function debounce(func, wait = 166) {\n let timeout;\n function debounced(...args) {\n const later = () => {\n // @ts-ignore\n func.apply(this, args);\n };\n clearTimeout(timeout);\n timeout = setTimeout(later, wait);\n }\n debounced.clear = () => {\n clearTimeout(timeout);\n };\n return debounced;\n}","export default function deprecatedPropType(validator, reason) {\n if (process.env.NODE_ENV === 'production') {\n return () => null;\n }\n return (props, propName, componentName, location, propFullName) => {\n const componentNameSafe = componentName || '<>';\n const propFullNameSafe = propFullName || propName;\n if (typeof props[propName] !== 'undefined') {\n return new Error(`The ${location} \\`${propFullNameSafe}\\` of ` + `\\`${componentNameSafe}\\` is deprecated. ${reason}`);\n }\n return null;\n };\n}","import * as React from 'react';\nexport default function isMuiElement(element, muiNames) {\n var _muiName, _element$type;\n return /*#__PURE__*/React.isValidElement(element) && muiNames.indexOf( // For server components `muiName` is avaialble in element.type._payload.value.muiName\n // relevant info - https://github.com/facebook/react/blob/2807d781a08db8e9873687fccc25c0f12b4fb3d4/packages/react/src/ReactLazy.js#L45\n // eslint-disable-next-line no-underscore-dangle\n (_muiName = element.type.muiName) != null ? _muiName : (_element$type = element.type) == null || (_element$type = _element$type._payload) == null || (_element$type = _element$type.value) == null ? void 0 : _element$type.muiName) !== -1;\n}","export default function ownerDocument(node) {\n return node && node.ownerDocument || document;\n}","import ownerDocument from '../ownerDocument';\nexport default function ownerWindow(node) {\n const doc = ownerDocument(node);\n return doc.defaultView || window;\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nexport default function requirePropFactory(componentNameInError, Component) {\n if (process.env.NODE_ENV === 'production') {\n return () => null;\n }\n\n // eslint-disable-next-line react/forbid-foreign-prop-types\n const prevPropTypes = Component ? _extends({}, Component.propTypes) : null;\n const requireProp = requiredProp => (props, propName, componentName, location, propFullName, ...args) => {\n const propFullNameSafe = propFullName || propName;\n const defaultTypeChecker = prevPropTypes == null ? void 0 : prevPropTypes[propFullNameSafe];\n if (defaultTypeChecker) {\n const typeCheckerResult = defaultTypeChecker(props, propName, componentName, location, propFullName, ...args);\n if (typeCheckerResult) {\n return typeCheckerResult;\n }\n }\n if (typeof props[propName] !== 'undefined' && !props[requiredProp]) {\n return new Error(`The prop \\`${propFullNameSafe}\\` of ` + `\\`${componentNameInError}\\` can only be used together with the \\`${requiredProp}\\` prop.`);\n }\n return null;\n };\n return requireProp;\n}","/**\n * TODO v5: consider making it private\n *\n * passes {value} to {ref}\n *\n * WARNING: Be sure to only call this inside a callback that is passed as a ref.\n * Otherwise, make sure to cleanup the previous {ref} if it changes. See\n * https://github.com/mui/material-ui/issues/13539\n *\n * Useful if you want to expose the ref of an inner component to the public API\n * while still using it inside the component.\n * @param ref A ref callback or ref object. If anything falsy, this is a no-op.\n */\nexport default function setRef(ref, value) {\n if (typeof ref === 'function') {\n ref(value);\n } else if (ref) {\n ref.current = value;\n }\n}","'use client';\n\nimport * as React from 'react';\n\n/**\n * A version of `React.useLayoutEffect` that does not show a warning when server-side rendering.\n * This is useful for effects that are only needed for client-side rendering but not for SSR.\n *\n * Before you use this hook, make sure to read https://gist.github.com/gaearon/e7d97cdf38a2907924ea12e4ebdf3c85\n * and confirm it doesn't apply to your use-case.\n */\nconst useEnhancedEffect = typeof window !== 'undefined' ? React.useLayoutEffect : React.useEffect;\nexport default useEnhancedEffect;","'use client';\n\nimport * as React from 'react';\nlet globalId = 0;\nfunction useGlobalId(idOverride) {\n const [defaultId, setDefaultId] = React.useState(idOverride);\n const id = idOverride || defaultId;\n React.useEffect(() => {\n if (defaultId == null) {\n // Fallback to this default id when possible.\n // Use the incrementing value for client-side rendering only.\n // We can't use it server-side.\n // If you want to use random values please consider the Birthday Problem: https://en.wikipedia.org/wiki/Birthday_problem\n globalId += 1;\n setDefaultId(`mui-${globalId}`);\n }\n }, [defaultId]);\n return id;\n}\n\n// downstream bundlers may remove unnecessary concatenation, but won't remove toString call -- Workaround for https://github.com/webpack/webpack/issues/14814\nconst maybeReactUseId = React['useId'.toString()];\n/**\n *\n * @example
    \n * @param idOverride\n * @returns {string}\n */\nexport default function useId(idOverride) {\n if (maybeReactUseId !== undefined) {\n const reactId = maybeReactUseId();\n return idOverride != null ? idOverride : reactId;\n }\n // eslint-disable-next-line react-hooks/rules-of-hooks -- `React.useId` is invariant at runtime.\n return useGlobalId(idOverride);\n}","export default function unsupportedProp(props, propName, componentName, location, propFullName) {\n if (process.env.NODE_ENV === 'production') {\n return null;\n }\n const propFullNameSafe = propFullName || propName;\n if (typeof props[propName] !== 'undefined') {\n return new Error(`The prop \\`${propFullNameSafe}\\` is not supported. Please remove it.`);\n }\n return null;\n}","'use client';\n\n/* eslint-disable react-hooks/rules-of-hooks, react-hooks/exhaustive-deps */\nimport * as React from 'react';\nexport default function useControlled({\n controlled,\n default: defaultProp,\n name,\n state = 'value'\n}) {\n // isControlled is ignored in the hook dependency lists as it should never change.\n const {\n current: isControlled\n } = React.useRef(controlled !== undefined);\n const [valueState, setValue] = React.useState(defaultProp);\n const value = isControlled ? controlled : valueState;\n if (process.env.NODE_ENV !== 'production') {\n React.useEffect(() => {\n if (isControlled !== (controlled !== undefined)) {\n console.error([`MUI: A component is changing the ${isControlled ? '' : 'un'}controlled ${state} state of ${name} to be ${isControlled ? 'un' : ''}controlled.`, 'Elements should not switch from uncontrolled to controlled (or vice versa).', `Decide between using a controlled or uncontrolled ${name} ` + 'element for the lifetime of the component.', \"The nature of the state is determined during the first render. It's considered controlled if the value is not `undefined`.\", 'More info: https://fb.me/react-controlled-components'].join('\\n'));\n }\n }, [state, name, controlled]);\n const {\n current: defaultValue\n } = React.useRef(defaultProp);\n React.useEffect(() => {\n if (!isControlled && defaultValue !== defaultProp) {\n console.error([`MUI: A component is changing the default ${state} state of an uncontrolled ${name} after being initialized. ` + `To suppress this warning opt to use a controlled ${name}.`].join('\\n'));\n }\n }, [JSON.stringify(defaultProp)]);\n }\n const setValueIfUncontrolled = React.useCallback(newValue => {\n if (!isControlled) {\n setValue(newValue);\n }\n }, []);\n return [value, setValueIfUncontrolled];\n}","'use client';\n\nimport * as React from 'react';\nimport useEnhancedEffect from '../useEnhancedEffect';\n\n/**\n * Inspired by https://github.com/facebook/react/issues/14099#issuecomment-440013892\n * See RFC in https://github.com/reactjs/rfcs/pull/220\n */\n\nfunction useEventCallback(fn) {\n const ref = React.useRef(fn);\n useEnhancedEffect(() => {\n ref.current = fn;\n });\n return React.useRef((...args) =>\n // @ts-expect-error hide `this`\n (0, ref.current)(...args)).current;\n}\nexport default useEventCallback;","'use client';\n\nimport * as React from 'react';\nimport setRef from '../setRef';\nexport default function useForkRef(...refs) {\n /**\n * This will create a new function if the refs passed to this hook change and are all defined.\n * This means react will call the old forkRef with `null` and the new forkRef\n * with the ref. Cleanup naturally emerges from this behavior.\n */\n return React.useMemo(() => {\n if (refs.every(ref => ref == null)) {\n return null;\n }\n return instance => {\n refs.forEach(ref => {\n setRef(ref, instance);\n });\n };\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, refs);\n}","'use client';\n\nimport * as React from 'react';\nconst UNINITIALIZED = {};\n\n/**\n * A React.useRef() that is initialized lazily with a function. Note that it accepts an optional\n * initialization argument, so the initialization function doesn't need to be an inline closure.\n *\n * @usage\n * const ref = useLazyRef(sortColumns, columns)\n */\nexport default function useLazyRef(init, initArg) {\n const ref = React.useRef(UNINITIALIZED);\n if (ref.current === UNINITIALIZED) {\n ref.current = init(initArg);\n }\n return ref;\n}","'use client';\n\nimport * as React from 'react';\nconst EMPTY = [];\n\n/**\n * A React.useEffect equivalent that runs once, when the component is mounted.\n */\nexport default function useOnMount(fn) {\n /* eslint-disable react-hooks/exhaustive-deps */\n React.useEffect(fn, EMPTY);\n /* eslint-enable react-hooks/exhaustive-deps */\n}","'use client';\n\nimport useLazyRef from '../useLazyRef/useLazyRef';\nimport useOnMount from '../useOnMount/useOnMount';\nexport class Timeout {\n constructor() {\n this.currentId = null;\n this.clear = () => {\n if (this.currentId !== null) {\n clearTimeout(this.currentId);\n this.currentId = null;\n }\n };\n this.disposeEffect = () => {\n return this.clear;\n };\n }\n static create() {\n return new Timeout();\n }\n /**\n * Executes `fn` after `delay`, clearing any previously scheduled call.\n */\n start(delay, fn) {\n this.clear();\n this.currentId = setTimeout(() => {\n this.currentId = null;\n fn();\n }, delay);\n }\n}\nexport default function useTimeout() {\n const timeout = useLazyRef(Timeout.create).current;\n useOnMount(timeout.disposeEffect);\n return timeout;\n}","'use client';\n\n// based on https://github.com/WICG/focus-visible/blob/v4.1.5/src/focus-visible.js\nimport * as React from 'react';\nimport { Timeout } from '../useTimeout/useTimeout';\nlet hadKeyboardEvent = true;\nlet hadFocusVisibleRecently = false;\nconst hadFocusVisibleRecentlyTimeout = new Timeout();\nconst inputTypesWhitelist = {\n text: true,\n search: true,\n url: true,\n tel: true,\n email: true,\n password: true,\n number: true,\n date: true,\n month: true,\n week: true,\n time: true,\n datetime: true,\n 'datetime-local': true\n};\n\n/**\n * Computes whether the given element should automatically trigger the\n * `focus-visible` class being added, i.e. whether it should always match\n * `:focus-visible` when focused.\n * @param {Element} node\n * @returns {boolean}\n */\nfunction focusTriggersKeyboardModality(node) {\n const {\n type,\n tagName\n } = node;\n if (tagName === 'INPUT' && inputTypesWhitelist[type] && !node.readOnly) {\n return true;\n }\n if (tagName === 'TEXTAREA' && !node.readOnly) {\n return true;\n }\n if (node.isContentEditable) {\n return true;\n }\n return false;\n}\n\n/**\n * Keep track of our keyboard modality state with `hadKeyboardEvent`.\n * If the most recent user interaction was via the keyboard;\n * and the key press did not include a meta, alt/option, or control key;\n * then the modality is keyboard. Otherwise, the modality is not keyboard.\n * @param {KeyboardEvent} event\n */\nfunction handleKeyDown(event) {\n if (event.metaKey || event.altKey || event.ctrlKey) {\n return;\n }\n hadKeyboardEvent = true;\n}\n\n/**\n * If at any point a user clicks with a pointing device, ensure that we change\n * the modality away from keyboard.\n * This avoids the situation where a user presses a key on an already focused\n * element, and then clicks on a different element, focusing it with a\n * pointing device, while we still think we're in keyboard modality.\n */\nfunction handlePointerDown() {\n hadKeyboardEvent = false;\n}\nfunction handleVisibilityChange() {\n if (this.visibilityState === 'hidden') {\n // If the tab becomes active again, the browser will handle calling focus\n // on the element (Safari actually calls it twice).\n // If this tab change caused a blur on an element with focus-visible,\n // re-apply the class when the user switches back to the tab.\n if (hadFocusVisibleRecently) {\n hadKeyboardEvent = true;\n }\n }\n}\nfunction prepare(doc) {\n doc.addEventListener('keydown', handleKeyDown, true);\n doc.addEventListener('mousedown', handlePointerDown, true);\n doc.addEventListener('pointerdown', handlePointerDown, true);\n doc.addEventListener('touchstart', handlePointerDown, true);\n doc.addEventListener('visibilitychange', handleVisibilityChange, true);\n}\nexport function teardown(doc) {\n doc.removeEventListener('keydown', handleKeyDown, true);\n doc.removeEventListener('mousedown', handlePointerDown, true);\n doc.removeEventListener('pointerdown', handlePointerDown, true);\n doc.removeEventListener('touchstart', handlePointerDown, true);\n doc.removeEventListener('visibilitychange', handleVisibilityChange, true);\n}\nfunction isFocusVisible(event) {\n const {\n target\n } = event;\n try {\n return target.matches(':focus-visible');\n } catch (error) {\n // Browsers not implementing :focus-visible will throw a SyntaxError.\n // We use our own heuristic for those browsers.\n // Rethrow might be better if it's not the expected error but do we really\n // want to crash if focus-visible malfunctioned?\n }\n\n // No need for validFocusTarget check. The user does that by attaching it to\n // focusable events only.\n return hadKeyboardEvent || focusTriggersKeyboardModality(target);\n}\nexport default function useIsFocusVisible() {\n const ref = React.useCallback(node => {\n if (node != null) {\n prepare(node.ownerDocument);\n }\n }, []);\n const isFocusVisibleRef = React.useRef(false);\n\n /**\n * Should be called if a blur event is fired\n */\n function handleBlurVisible() {\n // checking against potential state variable does not suffice if we focus and blur synchronously.\n // React wouldn't have time to trigger a re-render so `focusVisible` would be stale.\n // Ideally we would adjust `isFocusVisible(event)` to look at `relatedTarget` for blur events.\n // This doesn't work in IE11 due to https://github.com/facebook/react/issues/3751\n // TODO: check again if React releases their internal changes to focus event handling (https://github.com/facebook/react/pull/19186).\n if (isFocusVisibleRef.current) {\n // To detect a tab/window switch, we look for a blur event followed\n // rapidly by a visibility change.\n // If we don't see a visibility change within 100ms, it's probably a\n // regular focus change.\n hadFocusVisibleRecently = true;\n hadFocusVisibleRecentlyTimeout.start(100, () => {\n hadFocusVisibleRecently = false;\n });\n isFocusVisibleRef.current = false;\n return true;\n }\n return false;\n }\n\n /**\n * Should be called if a blur event is fired\n */\n function handleFocusVisible(event) {\n if (isFocusVisible(event)) {\n isFocusVisibleRef.current = true;\n return true;\n }\n return false;\n }\n return {\n isFocusVisibleRef,\n onFocus: handleFocusVisible,\n onBlur: handleBlurVisible,\n ref\n };\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\n/**\n * Add keys, values of `defaultProps` that does not exist in `props`\n * @param {object} defaultProps\n * @param {object} props\n * @returns {object} resolved props\n */\nexport default function resolveProps(defaultProps, props) {\n const output = _extends({}, props);\n Object.keys(defaultProps).forEach(propName => {\n if (propName.toString().match(/^(components|slots)$/)) {\n output[propName] = _extends({}, defaultProps[propName], output[propName]);\n } else if (propName.toString().match(/^(componentsProps|slotProps)$/)) {\n const defaultSlotProps = defaultProps[propName] || {};\n const slotProps = props[propName];\n output[propName] = {};\n if (!slotProps || !Object.keys(slotProps)) {\n // Reduce the iteration if the slot props is empty\n output[propName] = defaultSlotProps;\n } else if (!defaultSlotProps || !Object.keys(defaultSlotProps)) {\n // Reduce the iteration if the default slot props is empty\n output[propName] = slotProps;\n } else {\n output[propName] = _extends({}, slotProps);\n Object.keys(defaultSlotProps).forEach(slotPropName => {\n output[propName][slotPropName] = resolveProps(defaultSlotProps[slotPropName], slotProps[slotPropName]);\n });\n }\n } else if (output[propName] === undefined) {\n output[propName] = defaultProps[propName];\n }\n });\n return output;\n}","export default function composeClasses(slots, getUtilityClass, classes = undefined) {\n const output = {};\n Object.keys(slots).forEach(\n // `Object.keys(slots)` can't be wider than `T` because we infer `T` from `slots`.\n // @ts-expect-error https://github.com/microsoft/TypeScript/pull/12253#issuecomment-263132208\n slot => {\n output[slot] = slots[slot].reduce((acc, key) => {\n if (key) {\n const utilityClass = getUtilityClass(key);\n if (utilityClass !== '') {\n acc.push(utilityClass);\n }\n if (classes && classes[key]) {\n acc.push(classes[key]);\n }\n }\n return acc;\n }, []).join(' ');\n });\n return output;\n}","const defaultGenerator = componentName => componentName;\nconst createClassNameGenerator = () => {\n let generate = defaultGenerator;\n return {\n configure(generator) {\n generate = generator;\n },\n generate(componentName) {\n return generate(componentName);\n },\n reset() {\n generate = defaultGenerator;\n }\n };\n};\nconst ClassNameGenerator = createClassNameGenerator();\nexport default ClassNameGenerator;","import ClassNameGenerator from '../ClassNameGenerator';\nexport const globalStateClasses = {\n active: 'active',\n checked: 'checked',\n completed: 'completed',\n disabled: 'disabled',\n error: 'error',\n expanded: 'expanded',\n focused: 'focused',\n focusVisible: 'focusVisible',\n open: 'open',\n readOnly: 'readOnly',\n required: 'required',\n selected: 'selected'\n};\nexport default function generateUtilityClass(componentName, slot, globalStatePrefix = 'Mui') {\n const globalStateClass = globalStateClasses[slot];\n return globalStateClass ? `${globalStatePrefix}-${globalStateClass}` : `${ClassNameGenerator.generate(componentName)}-${slot}`;\n}\nexport function isGlobalState(slot) {\n return globalStateClasses[slot] !== undefined;\n}","import generateUtilityClass from '../generateUtilityClass';\nexport default function generateUtilityClasses(componentName, slots, globalStatePrefix = 'Mui') {\n const result = {};\n slots.forEach(slot => {\n result[slot] = generateUtilityClass(componentName, slot, globalStatePrefix);\n });\n return result;\n}","function clamp(val, min = Number.MIN_SAFE_INTEGER, max = Number.MAX_SAFE_INTEGER) {\n return Math.max(min, Math.min(val, max));\n}\nexport default clamp;","export default function _objectWithoutPropertiesLoose(source, excluded) {\n if (source == null) return {};\n var target = {};\n var sourceKeys = Object.keys(source);\n var key, i;\n for (i = 0; i < sourceKeys.length; i++) {\n key = sourceKeys[i];\n if (excluded.indexOf(key) >= 0) continue;\n target[key] = source[key];\n }\n return target;\n}","import _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nconst _excluded = [\"values\", \"unit\", \"step\"];\n// Sorted ASC by size. That's important.\n// It can't be configured as it's used statically for propTypes.\nexport const breakpointKeys = ['xs', 'sm', 'md', 'lg', 'xl'];\nconst sortBreakpointsValues = values => {\n const breakpointsAsArray = Object.keys(values).map(key => ({\n key,\n val: values[key]\n })) || [];\n // Sort in ascending order\n breakpointsAsArray.sort((breakpoint1, breakpoint2) => breakpoint1.val - breakpoint2.val);\n return breakpointsAsArray.reduce((acc, obj) => {\n return _extends({}, acc, {\n [obj.key]: obj.val\n });\n }, {});\n};\n\n// Keep in mind that @media is inclusive by the CSS specification.\nexport default function createBreakpoints(breakpoints) {\n const {\n // The breakpoint **start** at this value.\n // For instance with the first breakpoint xs: [xs, sm).\n values = {\n xs: 0,\n // phone\n sm: 600,\n // tablet\n md: 900,\n // small laptop\n lg: 1200,\n // desktop\n xl: 1536 // large screen\n },\n unit = 'px',\n step = 5\n } = breakpoints,\n other = _objectWithoutPropertiesLoose(breakpoints, _excluded);\n const sortedValues = sortBreakpointsValues(values);\n const keys = Object.keys(sortedValues);\n function up(key) {\n const value = typeof values[key] === 'number' ? values[key] : key;\n return `@media (min-width:${value}${unit})`;\n }\n function down(key) {\n const value = typeof values[key] === 'number' ? values[key] : key;\n return `@media (max-width:${value - step / 100}${unit})`;\n }\n function between(start, end) {\n const endIndex = keys.indexOf(end);\n return `@media (min-width:${typeof values[start] === 'number' ? values[start] : start}${unit}) and ` + `(max-width:${(endIndex !== -1 && typeof values[keys[endIndex]] === 'number' ? values[keys[endIndex]] : end) - step / 100}${unit})`;\n }\n function only(key) {\n if (keys.indexOf(key) + 1 < keys.length) {\n return between(key, keys[keys.indexOf(key) + 1]);\n }\n return up(key);\n }\n function not(key) {\n // handle first and last key separately, for better readability\n const keyIndex = keys.indexOf(key);\n if (keyIndex === 0) {\n return up(keys[1]);\n }\n if (keyIndex === keys.length - 1) {\n return down(keys[keyIndex]);\n }\n return between(key, keys[keys.indexOf(key) + 1]).replace('@media', '@media not all and');\n }\n return _extends({\n keys,\n values: sortedValues,\n up,\n down,\n between,\n only,\n not,\n unit\n }, other);\n}","const shape = {\n borderRadius: 4\n};\nexport default shape;","import PropTypes from 'prop-types';\nconst responsivePropType = process.env.NODE_ENV !== 'production' ? PropTypes.oneOfType([PropTypes.number, PropTypes.string, PropTypes.object, PropTypes.array]) : {};\nexport default responsivePropType;","import deepmerge from '@mui/utils/deepmerge';\nfunction merge(acc, item) {\n if (!item) {\n return acc;\n }\n return deepmerge(acc, item, {\n clone: false // No need to clone deep, it's way faster.\n });\n}\nexport default merge;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport PropTypes from 'prop-types';\nimport deepmerge from '@mui/utils/deepmerge';\nimport merge from './merge';\n\n// The breakpoint **start** at this value.\n// For instance with the first breakpoint xs: [xs, sm[.\nexport const values = {\n xs: 0,\n // phone\n sm: 600,\n // tablet\n md: 900,\n // small laptop\n lg: 1200,\n // desktop\n xl: 1536 // large screen\n};\nconst defaultBreakpoints = {\n // Sorted ASC by size. That's important.\n // It can't be configured as it's used statically for propTypes.\n keys: ['xs', 'sm', 'md', 'lg', 'xl'],\n up: key => `@media (min-width:${values[key]}px)`\n};\nexport function handleBreakpoints(props, propValue, styleFromPropValue) {\n const theme = props.theme || {};\n if (Array.isArray(propValue)) {\n const themeBreakpoints = theme.breakpoints || defaultBreakpoints;\n return propValue.reduce((acc, item, index) => {\n acc[themeBreakpoints.up(themeBreakpoints.keys[index])] = styleFromPropValue(propValue[index]);\n return acc;\n }, {});\n }\n if (typeof propValue === 'object') {\n const themeBreakpoints = theme.breakpoints || defaultBreakpoints;\n return Object.keys(propValue).reduce((acc, breakpoint) => {\n // key is breakpoint\n if (Object.keys(themeBreakpoints.values || values).indexOf(breakpoint) !== -1) {\n const mediaKey = themeBreakpoints.up(breakpoint);\n acc[mediaKey] = styleFromPropValue(propValue[breakpoint], breakpoint);\n } else {\n const cssKey = breakpoint;\n acc[cssKey] = propValue[cssKey];\n }\n return acc;\n }, {});\n }\n const output = styleFromPropValue(propValue);\n return output;\n}\nfunction breakpoints(styleFunction) {\n // false positive\n // eslint-disable-next-line react/function-component-definition\n const newStyleFunction = props => {\n const theme = props.theme || {};\n const base = styleFunction(props);\n const themeBreakpoints = theme.breakpoints || defaultBreakpoints;\n const extended = themeBreakpoints.keys.reduce((acc, key) => {\n if (props[key]) {\n acc = acc || {};\n acc[themeBreakpoints.up(key)] = styleFunction(_extends({\n theme\n }, props[key]));\n }\n return acc;\n }, null);\n return merge(base, extended);\n };\n newStyleFunction.propTypes = process.env.NODE_ENV !== 'production' ? _extends({}, styleFunction.propTypes, {\n xs: PropTypes.object,\n sm: PropTypes.object,\n md: PropTypes.object,\n lg: PropTypes.object,\n xl: PropTypes.object\n }) : {};\n newStyleFunction.filterProps = ['xs', 'sm', 'md', 'lg', 'xl', ...styleFunction.filterProps];\n return newStyleFunction;\n}\nexport function createEmptyBreakpointObject(breakpointsInput = {}) {\n var _breakpointsInput$key;\n const breakpointsInOrder = (_breakpointsInput$key = breakpointsInput.keys) == null ? void 0 : _breakpointsInput$key.reduce((acc, key) => {\n const breakpointStyleKey = breakpointsInput.up(key);\n acc[breakpointStyleKey] = {};\n return acc;\n }, {});\n return breakpointsInOrder || {};\n}\nexport function removeUnusedBreakpoints(breakpointKeys, style) {\n return breakpointKeys.reduce((acc, key) => {\n const breakpointOutput = acc[key];\n const isBreakpointUnused = !breakpointOutput || Object.keys(breakpointOutput).length === 0;\n if (isBreakpointUnused) {\n delete acc[key];\n }\n return acc;\n }, style);\n}\nexport function mergeBreakpointsInOrder(breakpointsInput, ...styles) {\n const emptyBreakpoints = createEmptyBreakpointObject(breakpointsInput);\n const mergedOutput = [emptyBreakpoints, ...styles].reduce((prev, next) => deepmerge(prev, next), {});\n return removeUnusedBreakpoints(Object.keys(emptyBreakpoints), mergedOutput);\n}\n\n// compute base for responsive values; e.g.,\n// [1,2,3] => {xs: true, sm: true, md: true}\n// {xs: 1, sm: 2, md: 3} => {xs: true, sm: true, md: true}\nexport function computeBreakpointsBase(breakpointValues, themeBreakpoints) {\n // fixed value\n if (typeof breakpointValues !== 'object') {\n return {};\n }\n const base = {};\n const breakpointsKeys = Object.keys(themeBreakpoints);\n if (Array.isArray(breakpointValues)) {\n breakpointsKeys.forEach((breakpoint, i) => {\n if (i < breakpointValues.length) {\n base[breakpoint] = true;\n }\n });\n } else {\n breakpointsKeys.forEach(breakpoint => {\n if (breakpointValues[breakpoint] != null) {\n base[breakpoint] = true;\n }\n });\n }\n return base;\n}\nexport function resolveBreakpointValues({\n values: breakpointValues,\n breakpoints: themeBreakpoints,\n base: customBase\n}) {\n const base = customBase || computeBreakpointsBase(breakpointValues, themeBreakpoints);\n const keys = Object.keys(base);\n if (keys.length === 0) {\n return breakpointValues;\n }\n let previous;\n return keys.reduce((acc, breakpoint, i) => {\n if (Array.isArray(breakpointValues)) {\n acc[breakpoint] = breakpointValues[i] != null ? breakpointValues[i] : breakpointValues[previous];\n previous = i;\n } else if (typeof breakpointValues === 'object') {\n acc[breakpoint] = breakpointValues[breakpoint] != null ? breakpointValues[breakpoint] : breakpointValues[previous];\n previous = breakpoint;\n } else {\n acc[breakpoint] = breakpointValues;\n }\n return acc;\n }, {});\n}\nexport default breakpoints;","import capitalize from '@mui/utils/capitalize';\nimport responsivePropType from './responsivePropType';\nimport { handleBreakpoints } from './breakpoints';\nexport function getPath(obj, path, checkVars = true) {\n if (!path || typeof path !== 'string') {\n return null;\n }\n\n // Check if CSS variables are used\n if (obj && obj.vars && checkVars) {\n const val = `vars.${path}`.split('.').reduce((acc, item) => acc && acc[item] ? acc[item] : null, obj);\n if (val != null) {\n return val;\n }\n }\n return path.split('.').reduce((acc, item) => {\n if (acc && acc[item] != null) {\n return acc[item];\n }\n return null;\n }, obj);\n}\nexport function getStyleValue(themeMapping, transform, propValueFinal, userValue = propValueFinal) {\n let value;\n if (typeof themeMapping === 'function') {\n value = themeMapping(propValueFinal);\n } else if (Array.isArray(themeMapping)) {\n value = themeMapping[propValueFinal] || userValue;\n } else {\n value = getPath(themeMapping, propValueFinal) || userValue;\n }\n if (transform) {\n value = transform(value, userValue, themeMapping);\n }\n return value;\n}\nfunction style(options) {\n const {\n prop,\n cssProperty = options.prop,\n themeKey,\n transform\n } = options;\n\n // false positive\n // eslint-disable-next-line react/function-component-definition\n const fn = props => {\n if (props[prop] == null) {\n return null;\n }\n const propValue = props[prop];\n const theme = props.theme;\n const themeMapping = getPath(theme, themeKey) || {};\n const styleFromPropValue = propValueFinal => {\n let value = getStyleValue(themeMapping, transform, propValueFinal);\n if (propValueFinal === value && typeof propValueFinal === 'string') {\n // Haven't found value\n value = getStyleValue(themeMapping, transform, `${prop}${propValueFinal === 'default' ? '' : capitalize(propValueFinal)}`, propValueFinal);\n }\n if (cssProperty === false) {\n return value;\n }\n return {\n [cssProperty]: value\n };\n };\n return handleBreakpoints(props, propValue, styleFromPropValue);\n };\n fn.propTypes = process.env.NODE_ENV !== 'production' ? {\n [prop]: responsivePropType\n } : {};\n fn.filterProps = [prop];\n return fn;\n}\nexport default style;","export default function memoize(fn) {\n const cache = {};\n return arg => {\n if (cache[arg] === undefined) {\n cache[arg] = fn(arg);\n }\n return cache[arg];\n };\n}","import responsivePropType from './responsivePropType';\nimport { handleBreakpoints } from './breakpoints';\nimport { getPath } from './style';\nimport merge from './merge';\nimport memoize from './memoize';\nconst properties = {\n m: 'margin',\n p: 'padding'\n};\nconst directions = {\n t: 'Top',\n r: 'Right',\n b: 'Bottom',\n l: 'Left',\n x: ['Left', 'Right'],\n y: ['Top', 'Bottom']\n};\nconst aliases = {\n marginX: 'mx',\n marginY: 'my',\n paddingX: 'px',\n paddingY: 'py'\n};\n\n// memoize() impact:\n// From 300,000 ops/sec\n// To 350,000 ops/sec\nconst getCssProperties = memoize(prop => {\n // It's not a shorthand notation.\n if (prop.length > 2) {\n if (aliases[prop]) {\n prop = aliases[prop];\n } else {\n return [prop];\n }\n }\n const [a, b] = prop.split('');\n const property = properties[a];\n const direction = directions[b] || '';\n return Array.isArray(direction) ? direction.map(dir => property + dir) : [property + direction];\n});\nexport const marginKeys = ['m', 'mt', 'mr', 'mb', 'ml', 'mx', 'my', 'margin', 'marginTop', 'marginRight', 'marginBottom', 'marginLeft', 'marginX', 'marginY', 'marginInline', 'marginInlineStart', 'marginInlineEnd', 'marginBlock', 'marginBlockStart', 'marginBlockEnd'];\nexport const paddingKeys = ['p', 'pt', 'pr', 'pb', 'pl', 'px', 'py', 'padding', 'paddingTop', 'paddingRight', 'paddingBottom', 'paddingLeft', 'paddingX', 'paddingY', 'paddingInline', 'paddingInlineStart', 'paddingInlineEnd', 'paddingBlock', 'paddingBlockStart', 'paddingBlockEnd'];\nconst spacingKeys = [...marginKeys, ...paddingKeys];\nexport function createUnaryUnit(theme, themeKey, defaultValue, propName) {\n var _getPath;\n const themeSpacing = (_getPath = getPath(theme, themeKey, false)) != null ? _getPath : defaultValue;\n if (typeof themeSpacing === 'number') {\n return abs => {\n if (typeof abs === 'string') {\n return abs;\n }\n if (process.env.NODE_ENV !== 'production') {\n if (typeof abs !== 'number') {\n console.error(`MUI: Expected ${propName} argument to be a number or a string, got ${abs}.`);\n }\n }\n return themeSpacing * abs;\n };\n }\n if (Array.isArray(themeSpacing)) {\n return abs => {\n if (typeof abs === 'string') {\n return abs;\n }\n if (process.env.NODE_ENV !== 'production') {\n if (!Number.isInteger(abs)) {\n console.error([`MUI: The \\`theme.${themeKey}\\` array type cannot be combined with non integer values.` + `You should either use an integer value that can be used as index, or define the \\`theme.${themeKey}\\` as a number.`].join('\\n'));\n } else if (abs > themeSpacing.length - 1) {\n console.error([`MUI: The value provided (${abs}) overflows.`, `The supported values are: ${JSON.stringify(themeSpacing)}.`, `${abs} > ${themeSpacing.length - 1}, you need to add the missing values.`].join('\\n'));\n }\n }\n return themeSpacing[abs];\n };\n }\n if (typeof themeSpacing === 'function') {\n return themeSpacing;\n }\n if (process.env.NODE_ENV !== 'production') {\n console.error([`MUI: The \\`theme.${themeKey}\\` value (${themeSpacing}) is invalid.`, 'It should be a number, an array or a function.'].join('\\n'));\n }\n return () => undefined;\n}\nexport function createUnarySpacing(theme) {\n return createUnaryUnit(theme, 'spacing', 8, 'spacing');\n}\nexport function getValue(transformer, propValue) {\n if (typeof propValue === 'string' || propValue == null) {\n return propValue;\n }\n const abs = Math.abs(propValue);\n const transformed = transformer(abs);\n if (propValue >= 0) {\n return transformed;\n }\n if (typeof transformed === 'number') {\n return -transformed;\n }\n return `-${transformed}`;\n}\nexport function getStyleFromPropValue(cssProperties, transformer) {\n return propValue => cssProperties.reduce((acc, cssProperty) => {\n acc[cssProperty] = getValue(transformer, propValue);\n return acc;\n }, {});\n}\nfunction resolveCssProperty(props, keys, prop, transformer) {\n // Using a hash computation over an array iteration could be faster, but with only 28 items,\n // it's doesn't worth the bundle size.\n if (keys.indexOf(prop) === -1) {\n return null;\n }\n const cssProperties = getCssProperties(prop);\n const styleFromPropValue = getStyleFromPropValue(cssProperties, transformer);\n const propValue = props[prop];\n return handleBreakpoints(props, propValue, styleFromPropValue);\n}\nfunction style(props, keys) {\n const transformer = createUnarySpacing(props.theme);\n return Object.keys(props).map(prop => resolveCssProperty(props, keys, prop, transformer)).reduce(merge, {});\n}\nexport function margin(props) {\n return style(props, marginKeys);\n}\nmargin.propTypes = process.env.NODE_ENV !== 'production' ? marginKeys.reduce((obj, key) => {\n obj[key] = responsivePropType;\n return obj;\n}, {}) : {};\nmargin.filterProps = marginKeys;\nexport function padding(props) {\n return style(props, paddingKeys);\n}\npadding.propTypes = process.env.NODE_ENV !== 'production' ? paddingKeys.reduce((obj, key) => {\n obj[key] = responsivePropType;\n return obj;\n}, {}) : {};\npadding.filterProps = paddingKeys;\nfunction spacing(props) {\n return style(props, spacingKeys);\n}\nspacing.propTypes = process.env.NODE_ENV !== 'production' ? spacingKeys.reduce((obj, key) => {\n obj[key] = responsivePropType;\n return obj;\n}, {}) : {};\nspacing.filterProps = spacingKeys;\nexport default spacing;","import { createUnarySpacing } from '../spacing';\n\n// The different signatures imply different meaning for their arguments that can't be expressed structurally.\n// We express the difference with variable names.\n\nexport default function createSpacing(spacingInput = 8) {\n // Already transformed.\n if (spacingInput.mui) {\n return spacingInput;\n }\n\n // Material Design layouts are visually balanced. Most measurements align to an 8dp grid, which aligns both spacing and the overall layout.\n // Smaller components, such as icons, can align to a 4dp grid.\n // https://m2.material.io/design/layout/understanding-layout.html\n const transform = createUnarySpacing({\n spacing: spacingInput\n });\n const spacing = (...argsInput) => {\n if (process.env.NODE_ENV !== 'production') {\n if (!(argsInput.length <= 4)) {\n console.error(`MUI: Too many arguments provided, expected between 0 and 4, got ${argsInput.length}`);\n }\n }\n const args = argsInput.length === 0 ? [1] : argsInput;\n return args.map(argument => {\n const output = transform(argument);\n return typeof output === 'number' ? `${output}px` : output;\n }).join(' ');\n };\n spacing.mui = true;\n return spacing;\n}","import merge from './merge';\nfunction compose(...styles) {\n const handlers = styles.reduce((acc, style) => {\n style.filterProps.forEach(prop => {\n acc[prop] = style;\n });\n return acc;\n }, {});\n\n // false positive\n // eslint-disable-next-line react/function-component-definition\n const fn = props => {\n return Object.keys(props).reduce((acc, prop) => {\n if (handlers[prop]) {\n return merge(acc, handlers[prop](props));\n }\n return acc;\n }, {});\n };\n fn.propTypes = process.env.NODE_ENV !== 'production' ? styles.reduce((acc, style) => Object.assign(acc, style.propTypes), {}) : {};\n fn.filterProps = styles.reduce((acc, style) => acc.concat(style.filterProps), []);\n return fn;\n}\nexport default compose;","import responsivePropType from './responsivePropType';\nimport style from './style';\nimport compose from './compose';\nimport { createUnaryUnit, getValue } from './spacing';\nimport { handleBreakpoints } from './breakpoints';\nexport function borderTransform(value) {\n if (typeof value !== 'number') {\n return value;\n }\n return `${value}px solid`;\n}\nfunction createBorderStyle(prop, transform) {\n return style({\n prop,\n themeKey: 'borders',\n transform\n });\n}\nexport const border = createBorderStyle('border', borderTransform);\nexport const borderTop = createBorderStyle('borderTop', borderTransform);\nexport const borderRight = createBorderStyle('borderRight', borderTransform);\nexport const borderBottom = createBorderStyle('borderBottom', borderTransform);\nexport const borderLeft = createBorderStyle('borderLeft', borderTransform);\nexport const borderColor = createBorderStyle('borderColor');\nexport const borderTopColor = createBorderStyle('borderTopColor');\nexport const borderRightColor = createBorderStyle('borderRightColor');\nexport const borderBottomColor = createBorderStyle('borderBottomColor');\nexport const borderLeftColor = createBorderStyle('borderLeftColor');\nexport const outline = createBorderStyle('outline', borderTransform);\nexport const outlineColor = createBorderStyle('outlineColor');\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const borderRadius = props => {\n if (props.borderRadius !== undefined && props.borderRadius !== null) {\n const transformer = createUnaryUnit(props.theme, 'shape.borderRadius', 4, 'borderRadius');\n const styleFromPropValue = propValue => ({\n borderRadius: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.borderRadius, styleFromPropValue);\n }\n return null;\n};\nborderRadius.propTypes = process.env.NODE_ENV !== 'production' ? {\n borderRadius: responsivePropType\n} : {};\nborderRadius.filterProps = ['borderRadius'];\nconst borders = compose(border, borderTop, borderRight, borderBottom, borderLeft, borderColor, borderTopColor, borderRightColor, borderBottomColor, borderLeftColor, borderRadius, outline, outlineColor);\nexport default borders;","import style from './style';\nimport compose from './compose';\nimport { createUnaryUnit, getValue } from './spacing';\nimport { handleBreakpoints } from './breakpoints';\nimport responsivePropType from './responsivePropType';\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const gap = props => {\n if (props.gap !== undefined && props.gap !== null) {\n const transformer = createUnaryUnit(props.theme, 'spacing', 8, 'gap');\n const styleFromPropValue = propValue => ({\n gap: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.gap, styleFromPropValue);\n }\n return null;\n};\ngap.propTypes = process.env.NODE_ENV !== 'production' ? {\n gap: responsivePropType\n} : {};\ngap.filterProps = ['gap'];\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const columnGap = props => {\n if (props.columnGap !== undefined && props.columnGap !== null) {\n const transformer = createUnaryUnit(props.theme, 'spacing', 8, 'columnGap');\n const styleFromPropValue = propValue => ({\n columnGap: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.columnGap, styleFromPropValue);\n }\n return null;\n};\ncolumnGap.propTypes = process.env.NODE_ENV !== 'production' ? {\n columnGap: responsivePropType\n} : {};\ncolumnGap.filterProps = ['columnGap'];\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const rowGap = props => {\n if (props.rowGap !== undefined && props.rowGap !== null) {\n const transformer = createUnaryUnit(props.theme, 'spacing', 8, 'rowGap');\n const styleFromPropValue = propValue => ({\n rowGap: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.rowGap, styleFromPropValue);\n }\n return null;\n};\nrowGap.propTypes = process.env.NODE_ENV !== 'production' ? {\n rowGap: responsivePropType\n} : {};\nrowGap.filterProps = ['rowGap'];\nexport const gridColumn = style({\n prop: 'gridColumn'\n});\nexport const gridRow = style({\n prop: 'gridRow'\n});\nexport const gridAutoFlow = style({\n prop: 'gridAutoFlow'\n});\nexport const gridAutoColumns = style({\n prop: 'gridAutoColumns'\n});\nexport const gridAutoRows = style({\n prop: 'gridAutoRows'\n});\nexport const gridTemplateColumns = style({\n prop: 'gridTemplateColumns'\n});\nexport const gridTemplateRows = style({\n prop: 'gridTemplateRows'\n});\nexport const gridTemplateAreas = style({\n prop: 'gridTemplateAreas'\n});\nexport const gridArea = style({\n prop: 'gridArea'\n});\nconst grid = compose(gap, columnGap, rowGap, gridColumn, gridRow, gridAutoFlow, gridAutoColumns, gridAutoRows, gridTemplateColumns, gridTemplateRows, gridTemplateAreas, gridArea);\nexport default grid;","import style from './style';\nimport compose from './compose';\nexport function paletteTransform(value, userValue) {\n if (userValue === 'grey') {\n return userValue;\n }\n return value;\n}\nexport const color = style({\n prop: 'color',\n themeKey: 'palette',\n transform: paletteTransform\n});\nexport const bgcolor = style({\n prop: 'bgcolor',\n cssProperty: 'backgroundColor',\n themeKey: 'palette',\n transform: paletteTransform\n});\nexport const backgroundColor = style({\n prop: 'backgroundColor',\n themeKey: 'palette',\n transform: paletteTransform\n});\nconst palette = compose(color, bgcolor, backgroundColor);\nexport default palette;","import style from './style';\nimport compose from './compose';\nimport { handleBreakpoints, values as breakpointsValues } from './breakpoints';\nexport function sizingTransform(value) {\n return value <= 1 && value !== 0 ? `${value * 100}%` : value;\n}\nexport const width = style({\n prop: 'width',\n transform: sizingTransform\n});\nexport const maxWidth = props => {\n if (props.maxWidth !== undefined && props.maxWidth !== null) {\n const styleFromPropValue = propValue => {\n var _props$theme, _props$theme2;\n const breakpoint = ((_props$theme = props.theme) == null || (_props$theme = _props$theme.breakpoints) == null || (_props$theme = _props$theme.values) == null ? void 0 : _props$theme[propValue]) || breakpointsValues[propValue];\n if (!breakpoint) {\n return {\n maxWidth: sizingTransform(propValue)\n };\n }\n if (((_props$theme2 = props.theme) == null || (_props$theme2 = _props$theme2.breakpoints) == null ? void 0 : _props$theme2.unit) !== 'px') {\n return {\n maxWidth: `${breakpoint}${props.theme.breakpoints.unit}`\n };\n }\n return {\n maxWidth: breakpoint\n };\n };\n return handleBreakpoints(props, props.maxWidth, styleFromPropValue);\n }\n return null;\n};\nmaxWidth.filterProps = ['maxWidth'];\nexport const minWidth = style({\n prop: 'minWidth',\n transform: sizingTransform\n});\nexport const height = style({\n prop: 'height',\n transform: sizingTransform\n});\nexport const maxHeight = style({\n prop: 'maxHeight',\n transform: sizingTransform\n});\nexport const minHeight = style({\n prop: 'minHeight',\n transform: sizingTransform\n});\nexport const sizeWidth = style({\n prop: 'size',\n cssProperty: 'width',\n transform: sizingTransform\n});\nexport const sizeHeight = style({\n prop: 'size',\n cssProperty: 'height',\n transform: sizingTransform\n});\nexport const boxSizing = style({\n prop: 'boxSizing'\n});\nconst sizing = compose(width, maxWidth, minWidth, height, maxHeight, minHeight, boxSizing);\nexport default sizing;","import { padding, margin } from '../spacing';\nimport { borderRadius, borderTransform } from '../borders';\nimport { gap, rowGap, columnGap } from '../cssGrid';\nimport { paletteTransform } from '../palette';\nimport { maxWidth, sizingTransform } from '../sizing';\nconst defaultSxConfig = {\n // borders\n border: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderTop: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderRight: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderBottom: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderLeft: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderColor: {\n themeKey: 'palette'\n },\n borderTopColor: {\n themeKey: 'palette'\n },\n borderRightColor: {\n themeKey: 'palette'\n },\n borderBottomColor: {\n themeKey: 'palette'\n },\n borderLeftColor: {\n themeKey: 'palette'\n },\n outline: {\n themeKey: 'borders',\n transform: borderTransform\n },\n outlineColor: {\n themeKey: 'palette'\n },\n borderRadius: {\n themeKey: 'shape.borderRadius',\n style: borderRadius\n },\n // palette\n color: {\n themeKey: 'palette',\n transform: paletteTransform\n },\n bgcolor: {\n themeKey: 'palette',\n cssProperty: 'backgroundColor',\n transform: paletteTransform\n },\n backgroundColor: {\n themeKey: 'palette',\n transform: paletteTransform\n },\n // spacing\n p: {\n style: padding\n },\n pt: {\n style: padding\n },\n pr: {\n style: padding\n },\n pb: {\n style: padding\n },\n pl: {\n style: padding\n },\n px: {\n style: padding\n },\n py: {\n style: padding\n },\n padding: {\n style: padding\n },\n paddingTop: {\n style: padding\n },\n paddingRight: {\n style: padding\n },\n paddingBottom: {\n style: padding\n },\n paddingLeft: {\n style: padding\n },\n paddingX: {\n style: padding\n },\n paddingY: {\n style: padding\n },\n paddingInline: {\n style: padding\n },\n paddingInlineStart: {\n style: padding\n },\n paddingInlineEnd: {\n style: padding\n },\n paddingBlock: {\n style: padding\n },\n paddingBlockStart: {\n style: padding\n },\n paddingBlockEnd: {\n style: padding\n },\n m: {\n style: margin\n },\n mt: {\n style: margin\n },\n mr: {\n style: margin\n },\n mb: {\n style: margin\n },\n ml: {\n style: margin\n },\n mx: {\n style: margin\n },\n my: {\n style: margin\n },\n margin: {\n style: margin\n },\n marginTop: {\n style: margin\n },\n marginRight: {\n style: margin\n },\n marginBottom: {\n style: margin\n },\n marginLeft: {\n style: margin\n },\n marginX: {\n style: margin\n },\n marginY: {\n style: margin\n },\n marginInline: {\n style: margin\n },\n marginInlineStart: {\n style: margin\n },\n marginInlineEnd: {\n style: margin\n },\n marginBlock: {\n style: margin\n },\n marginBlockStart: {\n style: margin\n },\n marginBlockEnd: {\n style: margin\n },\n // display\n displayPrint: {\n cssProperty: false,\n transform: value => ({\n '@media print': {\n display: value\n }\n })\n },\n display: {},\n overflow: {},\n textOverflow: {},\n visibility: {},\n whiteSpace: {},\n // flexbox\n flexBasis: {},\n flexDirection: {},\n flexWrap: {},\n justifyContent: {},\n alignItems: {},\n alignContent: {},\n order: {},\n flex: {},\n flexGrow: {},\n flexShrink: {},\n alignSelf: {},\n justifyItems: {},\n justifySelf: {},\n // grid\n gap: {\n style: gap\n },\n rowGap: {\n style: rowGap\n },\n columnGap: {\n style: columnGap\n },\n gridColumn: {},\n gridRow: {},\n gridAutoFlow: {},\n gridAutoColumns: {},\n gridAutoRows: {},\n gridTemplateColumns: {},\n gridTemplateRows: {},\n gridTemplateAreas: {},\n gridArea: {},\n // positions\n position: {},\n zIndex: {\n themeKey: 'zIndex'\n },\n top: {},\n right: {},\n bottom: {},\n left: {},\n // shadows\n boxShadow: {\n themeKey: 'shadows'\n },\n // sizing\n width: {\n transform: sizingTransform\n },\n maxWidth: {\n style: maxWidth\n },\n minWidth: {\n transform: sizingTransform\n },\n height: {\n transform: sizingTransform\n },\n maxHeight: {\n transform: sizingTransform\n },\n minHeight: {\n transform: sizingTransform\n },\n boxSizing: {},\n // typography\n fontFamily: {\n themeKey: 'typography'\n },\n fontSize: {\n themeKey: 'typography'\n },\n fontStyle: {\n themeKey: 'typography'\n },\n fontWeight: {\n themeKey: 'typography'\n },\n letterSpacing: {},\n textTransform: {},\n lineHeight: {},\n textAlign: {},\n typography: {\n cssProperty: false,\n themeKey: 'typography'\n }\n};\nexport default defaultSxConfig;","import capitalize from '@mui/utils/capitalize';\nimport merge from '../merge';\nimport { getPath, getStyleValue as getValue } from '../style';\nimport { handleBreakpoints, createEmptyBreakpointObject, removeUnusedBreakpoints } from '../breakpoints';\nimport defaultSxConfig from './defaultSxConfig';\nfunction objectsHaveSameKeys(...objects) {\n const allKeys = objects.reduce((keys, object) => keys.concat(Object.keys(object)), []);\n const union = new Set(allKeys);\n return objects.every(object => union.size === Object.keys(object).length);\n}\nfunction callIfFn(maybeFn, arg) {\n return typeof maybeFn === 'function' ? maybeFn(arg) : maybeFn;\n}\n\n// eslint-disable-next-line @typescript-eslint/naming-convention\nexport function unstable_createStyleFunctionSx() {\n function getThemeValue(prop, val, theme, config) {\n const props = {\n [prop]: val,\n theme\n };\n const options = config[prop];\n if (!options) {\n return {\n [prop]: val\n };\n }\n const {\n cssProperty = prop,\n themeKey,\n transform,\n style\n } = options;\n if (val == null) {\n return null;\n }\n\n // TODO v6: remove, see https://github.com/mui/material-ui/pull/38123\n if (themeKey === 'typography' && val === 'inherit') {\n return {\n [prop]: val\n };\n }\n const themeMapping = getPath(theme, themeKey) || {};\n if (style) {\n return style(props);\n }\n const styleFromPropValue = propValueFinal => {\n let value = getValue(themeMapping, transform, propValueFinal);\n if (propValueFinal === value && typeof propValueFinal === 'string') {\n // Haven't found value\n value = getValue(themeMapping, transform, `${prop}${propValueFinal === 'default' ? '' : capitalize(propValueFinal)}`, propValueFinal);\n }\n if (cssProperty === false) {\n return value;\n }\n return {\n [cssProperty]: value\n };\n };\n return handleBreakpoints(props, val, styleFromPropValue);\n }\n function styleFunctionSx(props) {\n var _theme$unstable_sxCon;\n const {\n sx,\n theme = {}\n } = props || {};\n if (!sx) {\n return null; // Emotion & styled-components will neglect null\n }\n const config = (_theme$unstable_sxCon = theme.unstable_sxConfig) != null ? _theme$unstable_sxCon : defaultSxConfig;\n\n /*\n * Receive `sxInput` as object or callback\n * and then recursively check keys & values to create media query object styles.\n * (the result will be used in `styled`)\n */\n function traverse(sxInput) {\n let sxObject = sxInput;\n if (typeof sxInput === 'function') {\n sxObject = sxInput(theme);\n } else if (typeof sxInput !== 'object') {\n // value\n return sxInput;\n }\n if (!sxObject) {\n return null;\n }\n const emptyBreakpoints = createEmptyBreakpointObject(theme.breakpoints);\n const breakpointsKeys = Object.keys(emptyBreakpoints);\n let css = emptyBreakpoints;\n Object.keys(sxObject).forEach(styleKey => {\n const value = callIfFn(sxObject[styleKey], theme);\n if (value !== null && value !== undefined) {\n if (typeof value === 'object') {\n if (config[styleKey]) {\n css = merge(css, getThemeValue(styleKey, value, theme, config));\n } else {\n const breakpointsValues = handleBreakpoints({\n theme\n }, value, x => ({\n [styleKey]: x\n }));\n if (objectsHaveSameKeys(breakpointsValues, value)) {\n css[styleKey] = styleFunctionSx({\n sx: value,\n theme\n });\n } else {\n css = merge(css, breakpointsValues);\n }\n }\n } else {\n css = merge(css, getThemeValue(styleKey, value, theme, config));\n }\n }\n });\n return removeUnusedBreakpoints(breakpointsKeys, css);\n }\n return Array.isArray(sx) ? sx.map(traverse) : traverse(sx);\n }\n return styleFunctionSx;\n}\nconst styleFunctionSx = unstable_createStyleFunctionSx();\nstyleFunctionSx.filterProps = ['sx'];\nexport default styleFunctionSx;","/**\n * A universal utility to style components with multiple color modes. Always use it from the theme object.\n * It works with:\n * - [Basic theme](https://mui.com/material-ui/customization/dark-mode/)\n * - [CSS theme variables](https://mui.com/material-ui/experimental-api/css-theme-variables/overview/)\n * - Zero-runtime engine\n *\n * Tips: Use an array over object spread and place `theme.applyStyles()` last.\n *\n * ✅ [{ background: '#e5e5e5' }, theme.applyStyles('dark', { background: '#1c1c1c' })]\n *\n * 🚫 { background: '#e5e5e5', ...theme.applyStyles('dark', { background: '#1c1c1c' })}\n *\n * @example\n * 1. using with `styled`:\n * ```jsx\n * const Component = styled('div')(({ theme }) => [\n * { background: '#e5e5e5' },\n * theme.applyStyles('dark', {\n * background: '#1c1c1c',\n * color: '#fff',\n * }),\n * ]);\n * ```\n *\n * @example\n * 2. using with `sx` prop:\n * ```jsx\n * [\n * { background: '#e5e5e5' },\n * theme.applyStyles('dark', {\n * background: '#1c1c1c',\n * color: '#fff',\n * }),\n * ]}\n * />\n * ```\n *\n * @example\n * 3. theming a component:\n * ```jsx\n * extendTheme({\n * components: {\n * MuiButton: {\n * styleOverrides: {\n * root: ({ theme }) => [\n * { background: '#e5e5e5' },\n * theme.applyStyles('dark', {\n * background: '#1c1c1c',\n * color: '#fff',\n * }),\n * ],\n * },\n * }\n * }\n * })\n *```\n */\nexport default function applyStyles(key, styles) {\n // @ts-expect-error this is 'any' type\n const theme = this;\n if (theme.vars && typeof theme.getColorSchemeSelector === 'function') {\n // If CssVarsProvider is used as a provider,\n // returns '* :where([data-mui-color-scheme=\"light|dark\"]) &'\n const selector = theme.getColorSchemeSelector(key).replace(/(\\[[^\\]]+\\])/, '*:where($1)');\n return {\n [selector]: styles\n };\n }\n if (theme.palette.mode === key) {\n return styles;\n }\n return {};\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"breakpoints\", \"palette\", \"spacing\", \"shape\"];\nimport deepmerge from '@mui/utils/deepmerge';\nimport createBreakpoints from './createBreakpoints';\nimport shape from './shape';\nimport createSpacing from './createSpacing';\nimport styleFunctionSx from '../styleFunctionSx/styleFunctionSx';\nimport defaultSxConfig from '../styleFunctionSx/defaultSxConfig';\nimport applyStyles from './applyStyles';\nfunction createTheme(options = {}, ...args) {\n const {\n breakpoints: breakpointsInput = {},\n palette: paletteInput = {},\n spacing: spacingInput,\n shape: shapeInput = {}\n } = options,\n other = _objectWithoutPropertiesLoose(options, _excluded);\n const breakpoints = createBreakpoints(breakpointsInput);\n const spacing = createSpacing(spacingInput);\n let muiTheme = deepmerge({\n breakpoints,\n direction: 'ltr',\n components: {},\n // Inject component definitions.\n palette: _extends({\n mode: 'light'\n }, paletteInput),\n spacing,\n shape: _extends({}, shape, shapeInput)\n }, other);\n muiTheme.applyStyles = applyStyles;\n muiTheme = args.reduce((acc, argument) => deepmerge(acc, argument), muiTheme);\n muiTheme.unstable_sxConfig = _extends({}, defaultSxConfig, other == null ? void 0 : other.unstable_sxConfig);\n muiTheme.unstable_sx = function sx(props) {\n return styleFunctionSx({\n sx: props,\n theme: this\n });\n };\n return muiTheme;\n}\nexport default createTheme;","'use client';\n\nimport * as React from 'react';\nimport { ThemeContext } from '@mui/styled-engine';\nfunction isObjectEmpty(obj) {\n return Object.keys(obj).length === 0;\n}\nfunction useTheme(defaultTheme = null) {\n const contextTheme = React.useContext(ThemeContext);\n return !contextTheme || isObjectEmpty(contextTheme) ? defaultTheme : contextTheme;\n}\nexport default useTheme;","'use client';\n\nimport createTheme from './createTheme';\nimport useThemeWithoutDefault from './useThemeWithoutDefault';\nexport const systemDefaultTheme = createTheme();\nfunction useTheme(defaultTheme = systemDefaultTheme) {\n return useThemeWithoutDefault(defaultTheme);\n}\nexport default useTheme;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"ownerState\"],\n _excluded2 = [\"variants\"],\n _excluded3 = [\"name\", \"slot\", \"skipVariantsResolver\", \"skipSx\", \"overridesResolver\"];\n/* eslint-disable no-underscore-dangle */\nimport styledEngineStyled, { internal_processStyles as processStyles } from '@mui/styled-engine';\nimport { isPlainObject } from '@mui/utils/deepmerge';\nimport capitalize from '@mui/utils/capitalize';\nimport getDisplayName from '@mui/utils/getDisplayName';\nimport createTheme from './createTheme';\nimport styleFunctionSx from './styleFunctionSx';\nfunction isEmpty(obj) {\n return Object.keys(obj).length === 0;\n}\n\n// https://github.com/emotion-js/emotion/blob/26ded6109fcd8ca9875cc2ce4564fee678a3f3c5/packages/styled/src/utils.js#L40\nfunction isStringTag(tag) {\n return typeof tag === 'string' &&\n // 96 is one less than the char code\n // for \"a\" so this is checking that\n // it's a lowercase character\n tag.charCodeAt(0) > 96;\n}\n\n// Update /system/styled/#api in case if this changes\nexport function shouldForwardProp(prop) {\n return prop !== 'ownerState' && prop !== 'theme' && prop !== 'sx' && prop !== 'as';\n}\nexport const systemDefaultTheme = createTheme();\nconst lowercaseFirstLetter = string => {\n if (!string) {\n return string;\n }\n return string.charAt(0).toLowerCase() + string.slice(1);\n};\nfunction resolveTheme({\n defaultTheme,\n theme,\n themeId\n}) {\n return isEmpty(theme) ? defaultTheme : theme[themeId] || theme;\n}\nfunction defaultOverridesResolver(slot) {\n if (!slot) {\n return null;\n }\n return (props, styles) => styles[slot];\n}\nfunction processStyleArg(callableStyle, _ref) {\n let {\n ownerState\n } = _ref,\n props = _objectWithoutPropertiesLoose(_ref, _excluded);\n const resolvedStylesArg = typeof callableStyle === 'function' ? callableStyle(_extends({\n ownerState\n }, props)) : callableStyle;\n if (Array.isArray(resolvedStylesArg)) {\n return resolvedStylesArg.flatMap(resolvedStyle => processStyleArg(resolvedStyle, _extends({\n ownerState\n }, props)));\n }\n if (!!resolvedStylesArg && typeof resolvedStylesArg === 'object' && Array.isArray(resolvedStylesArg.variants)) {\n const {\n variants = []\n } = resolvedStylesArg,\n otherStyles = _objectWithoutPropertiesLoose(resolvedStylesArg, _excluded2);\n let result = otherStyles;\n variants.forEach(variant => {\n let isMatch = true;\n if (typeof variant.props === 'function') {\n isMatch = variant.props(_extends({\n ownerState\n }, props, ownerState));\n } else {\n Object.keys(variant.props).forEach(key => {\n if ((ownerState == null ? void 0 : ownerState[key]) !== variant.props[key] && props[key] !== variant.props[key]) {\n isMatch = false;\n }\n });\n }\n if (isMatch) {\n if (!Array.isArray(result)) {\n result = [result];\n }\n result.push(typeof variant.style === 'function' ? variant.style(_extends({\n ownerState\n }, props, ownerState)) : variant.style);\n }\n });\n return result;\n }\n return resolvedStylesArg;\n}\nexport default function createStyled(input = {}) {\n const {\n themeId,\n defaultTheme = systemDefaultTheme,\n rootShouldForwardProp = shouldForwardProp,\n slotShouldForwardProp = shouldForwardProp\n } = input;\n const systemSx = props => {\n return styleFunctionSx(_extends({}, props, {\n theme: resolveTheme(_extends({}, props, {\n defaultTheme,\n themeId\n }))\n }));\n };\n systemSx.__mui_systemSx = true;\n return (tag, inputOptions = {}) => {\n // Filter out the `sx` style function from the previous styled component to prevent unnecessary styles generated by the composite components.\n processStyles(tag, styles => styles.filter(style => !(style != null && style.__mui_systemSx)));\n const {\n name: componentName,\n slot: componentSlot,\n skipVariantsResolver: inputSkipVariantsResolver,\n skipSx: inputSkipSx,\n // TODO v6: remove `lowercaseFirstLetter()` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n overridesResolver = defaultOverridesResolver(lowercaseFirstLetter(componentSlot))\n } = inputOptions,\n options = _objectWithoutPropertiesLoose(inputOptions, _excluded3);\n\n // if skipVariantsResolver option is defined, take the value, otherwise, true for root and false for other slots.\n const skipVariantsResolver = inputSkipVariantsResolver !== undefined ? inputSkipVariantsResolver :\n // TODO v6: remove `Root` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n componentSlot && componentSlot !== 'Root' && componentSlot !== 'root' || false;\n const skipSx = inputSkipSx || false;\n let label;\n if (process.env.NODE_ENV !== 'production') {\n if (componentName) {\n // TODO v6: remove `lowercaseFirstLetter()` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n label = `${componentName}-${lowercaseFirstLetter(componentSlot || 'Root')}`;\n }\n }\n let shouldForwardPropOption = shouldForwardProp;\n\n // TODO v6: remove `Root` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n if (componentSlot === 'Root' || componentSlot === 'root') {\n shouldForwardPropOption = rootShouldForwardProp;\n } else if (componentSlot) {\n // any other slot specified\n shouldForwardPropOption = slotShouldForwardProp;\n } else if (isStringTag(tag)) {\n // for string (html) tag, preserve the behavior in emotion & styled-components.\n shouldForwardPropOption = undefined;\n }\n const defaultStyledResolver = styledEngineStyled(tag, _extends({\n shouldForwardProp: shouldForwardPropOption,\n label\n }, options));\n const transformStyleArg = stylesArg => {\n // On the server Emotion doesn't use React.forwardRef for creating components, so the created\n // component stays as a function. This condition makes sure that we do not interpolate functions\n // which are basically components used as a selectors.\n if (typeof stylesArg === 'function' && stylesArg.__emotion_real !== stylesArg || isPlainObject(stylesArg)) {\n return props => processStyleArg(stylesArg, _extends({}, props, {\n theme: resolveTheme({\n theme: props.theme,\n defaultTheme,\n themeId\n })\n }));\n }\n return stylesArg;\n };\n const muiStyledResolver = (styleArg, ...expressions) => {\n let transformedStyleArg = transformStyleArg(styleArg);\n const expressionsWithDefaultTheme = expressions ? expressions.map(transformStyleArg) : [];\n if (componentName && overridesResolver) {\n expressionsWithDefaultTheme.push(props => {\n const theme = resolveTheme(_extends({}, props, {\n defaultTheme,\n themeId\n }));\n if (!theme.components || !theme.components[componentName] || !theme.components[componentName].styleOverrides) {\n return null;\n }\n const styleOverrides = theme.components[componentName].styleOverrides;\n const resolvedStyleOverrides = {};\n // TODO: v7 remove iteration and use `resolveStyleArg(styleOverrides[slot])` directly\n Object.entries(styleOverrides).forEach(([slotKey, slotStyle]) => {\n resolvedStyleOverrides[slotKey] = processStyleArg(slotStyle, _extends({}, props, {\n theme\n }));\n });\n return overridesResolver(props, resolvedStyleOverrides);\n });\n }\n if (componentName && !skipVariantsResolver) {\n expressionsWithDefaultTheme.push(props => {\n var _theme$components;\n const theme = resolveTheme(_extends({}, props, {\n defaultTheme,\n themeId\n }));\n const themeVariants = theme == null || (_theme$components = theme.components) == null || (_theme$components = _theme$components[componentName]) == null ? void 0 : _theme$components.variants;\n return processStyleArg({\n variants: themeVariants\n }, _extends({}, props, {\n theme\n }));\n });\n }\n if (!skipSx) {\n expressionsWithDefaultTheme.push(systemSx);\n }\n const numOfCustomFnsApplied = expressionsWithDefaultTheme.length - expressions.length;\n if (Array.isArray(styleArg) && numOfCustomFnsApplied > 0) {\n const placeholders = new Array(numOfCustomFnsApplied).fill('');\n // If the type is array, than we need to add placeholders in the template for the overrides, variants and the sx styles.\n transformedStyleArg = [...styleArg, ...placeholders];\n transformedStyleArg.raw = [...styleArg.raw, ...placeholders];\n }\n const Component = defaultStyledResolver(transformedStyleArg, ...expressionsWithDefaultTheme);\n if (process.env.NODE_ENV !== 'production') {\n let displayName;\n if (componentName) {\n displayName = `${componentName}${capitalize(componentSlot || '')}`;\n }\n if (displayName === undefined) {\n displayName = `Styled(${getDisplayName(tag)})`;\n }\n Component.displayName = displayName;\n }\n if (tag.muiName) {\n Component.muiName = tag.muiName;\n }\n return Component;\n };\n if (defaultStyledResolver.withConfig) {\n muiStyledResolver.withConfig = defaultStyledResolver.withConfig;\n }\n return muiStyledResolver;\n };\n}","import resolveProps from '@mui/utils/resolveProps';\nexport default function getThemeProps(params) {\n const {\n theme,\n name,\n props\n } = params;\n if (!theme || !theme.components || !theme.components[name] || !theme.components[name].defaultProps) {\n return props;\n }\n return resolveProps(theme.components[name].defaultProps, props);\n}","'use client';\n\nimport getThemeProps from './getThemeProps';\nimport useTheme from '../useTheme';\nexport default function useThemeProps({\n props,\n name,\n defaultTheme,\n themeId\n}) {\n let theme = useTheme(defaultTheme);\n if (themeId) {\n theme = theme[themeId] || theme;\n }\n const mergedProps = getThemeProps({\n theme,\n name,\n props\n });\n return mergedProps;\n}","import _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\n/* eslint-disable @typescript-eslint/naming-convention */\nimport clamp from '@mui/utils/clamp';\n/**\n * Returns a number whose value is limited to the given range.\n * @param {number} value The value to be clamped\n * @param {number} min The lower boundary of the output range\n * @param {number} max The upper boundary of the output range\n * @returns {number} A number in the range [min, max]\n */\nfunction clampWrapper(value, min = 0, max = 1) {\n if (process.env.NODE_ENV !== 'production') {\n if (value < min || value > max) {\n console.error(`MUI: The value provided ${value} is out of range [${min}, ${max}].`);\n }\n }\n return clamp(value, min, max);\n}\n\n/**\n * Converts a color from CSS hex format to CSS rgb format.\n * @param {string} color - Hex color, i.e. #nnn or #nnnnnn\n * @returns {string} A CSS rgb color string\n */\nexport function hexToRgb(color) {\n color = color.slice(1);\n const re = new RegExp(`.{1,${color.length >= 6 ? 2 : 1}}`, 'g');\n let colors = color.match(re);\n if (colors && colors[0].length === 1) {\n colors = colors.map(n => n + n);\n }\n return colors ? `rgb${colors.length === 4 ? 'a' : ''}(${colors.map((n, index) => {\n return index < 3 ? parseInt(n, 16) : Math.round(parseInt(n, 16) / 255 * 1000) / 1000;\n }).join(', ')})` : '';\n}\nfunction intToHex(int) {\n const hex = int.toString(16);\n return hex.length === 1 ? `0${hex}` : hex;\n}\n\n/**\n * Returns an object with the type and values of a color.\n *\n * Note: Does not support rgb % values.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @returns {object} - A MUI color object: {type: string, values: number[]}\n */\nexport function decomposeColor(color) {\n // Idempotent\n if (color.type) {\n return color;\n }\n if (color.charAt(0) === '#') {\n return decomposeColor(hexToRgb(color));\n }\n const marker = color.indexOf('(');\n const type = color.substring(0, marker);\n if (['rgb', 'rgba', 'hsl', 'hsla', 'color'].indexOf(type) === -1) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: Unsupported \\`${color}\\` color.\nThe following formats are supported: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color().` : _formatMuiErrorMessage(9, color));\n }\n let values = color.substring(marker + 1, color.length - 1);\n let colorSpace;\n if (type === 'color') {\n values = values.split(' ');\n colorSpace = values.shift();\n if (values.length === 4 && values[3].charAt(0) === '/') {\n values[3] = values[3].slice(1);\n }\n if (['srgb', 'display-p3', 'a98-rgb', 'prophoto-rgb', 'rec-2020'].indexOf(colorSpace) === -1) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: unsupported \\`${colorSpace}\\` color space.\nThe following color spaces are supported: srgb, display-p3, a98-rgb, prophoto-rgb, rec-2020.` : _formatMuiErrorMessage(10, colorSpace));\n }\n } else {\n values = values.split(',');\n }\n values = values.map(value => parseFloat(value));\n return {\n type,\n values,\n colorSpace\n };\n}\n\n/**\n * Returns a channel created from the input color.\n *\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @returns {string} - The channel for the color, that can be used in rgba or hsla colors\n */\nexport const colorChannel = color => {\n const decomposedColor = decomposeColor(color);\n return decomposedColor.values.slice(0, 3).map((val, idx) => decomposedColor.type.indexOf('hsl') !== -1 && idx !== 0 ? `${val}%` : val).join(' ');\n};\nexport const private_safeColorChannel = (color, warning) => {\n try {\n return colorChannel(color);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n};\n\n/**\n * Converts a color object with type and values to a string.\n * @param {object} color - Decomposed color\n * @param {string} color.type - One of: 'rgb', 'rgba', 'hsl', 'hsla', 'color'\n * @param {array} color.values - [n,n,n] or [n,n,n,n]\n * @returns {string} A CSS color string\n */\nexport function recomposeColor(color) {\n const {\n type,\n colorSpace\n } = color;\n let {\n values\n } = color;\n if (type.indexOf('rgb') !== -1) {\n // Only convert the first 3 values to int (i.e. not alpha)\n values = values.map((n, i) => i < 3 ? parseInt(n, 10) : n);\n } else if (type.indexOf('hsl') !== -1) {\n values[1] = `${values[1]}%`;\n values[2] = `${values[2]}%`;\n }\n if (type.indexOf('color') !== -1) {\n values = `${colorSpace} ${values.join(' ')}`;\n } else {\n values = `${values.join(', ')}`;\n }\n return `${type}(${values})`;\n}\n\n/**\n * Converts a color from CSS rgb format to CSS hex format.\n * @param {string} color - RGB color, i.e. rgb(n, n, n)\n * @returns {string} A CSS rgb color string, i.e. #nnnnnn\n */\nexport function rgbToHex(color) {\n // Idempotent\n if (color.indexOf('#') === 0) {\n return color;\n }\n const {\n values\n } = decomposeColor(color);\n return `#${values.map((n, i) => intToHex(i === 3 ? Math.round(255 * n) : n)).join('')}`;\n}\n\n/**\n * Converts a color from hsl format to rgb format.\n * @param {string} color - HSL color values\n * @returns {string} rgb color values\n */\nexport function hslToRgb(color) {\n color = decomposeColor(color);\n const {\n values\n } = color;\n const h = values[0];\n const s = values[1] / 100;\n const l = values[2] / 100;\n const a = s * Math.min(l, 1 - l);\n const f = (n, k = (n + h / 30) % 12) => l - a * Math.max(Math.min(k - 3, 9 - k, 1), -1);\n let type = 'rgb';\n const rgb = [Math.round(f(0) * 255), Math.round(f(8) * 255), Math.round(f(4) * 255)];\n if (color.type === 'hsla') {\n type += 'a';\n rgb.push(values[3]);\n }\n return recomposeColor({\n type,\n values: rgb\n });\n}\n/**\n * The relative brightness of any point in a color space,\n * normalized to 0 for darkest black and 1 for lightest white.\n *\n * Formula: https://www.w3.org/TR/WCAG20-TECHS/G17.html#G17-tests\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @returns {number} The relative brightness of the color in the range 0 - 1\n */\nexport function getLuminance(color) {\n color = decomposeColor(color);\n let rgb = color.type === 'hsl' || color.type === 'hsla' ? decomposeColor(hslToRgb(color)).values : color.values;\n rgb = rgb.map(val => {\n if (color.type !== 'color') {\n val /= 255; // normalized\n }\n return val <= 0.03928 ? val / 12.92 : ((val + 0.055) / 1.055) ** 2.4;\n });\n\n // Truncate at 3 digits\n return Number((0.2126 * rgb[0] + 0.7152 * rgb[1] + 0.0722 * rgb[2]).toFixed(3));\n}\n\n/**\n * Calculates the contrast ratio between two colors.\n *\n * Formula: https://www.w3.org/TR/WCAG20-TECHS/G17.html#G17-tests\n * @param {string} foreground - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla()\n * @param {string} background - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla()\n * @returns {number} A contrast ratio value in the range 0 - 21.\n */\nexport function getContrastRatio(foreground, background) {\n const lumA = getLuminance(foreground);\n const lumB = getLuminance(background);\n return (Math.max(lumA, lumB) + 0.05) / (Math.min(lumA, lumB) + 0.05);\n}\n\n/**\n * Sets the absolute transparency of a color.\n * Any existing alpha values are overwritten.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} value - value to set the alpha channel to in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function alpha(color, value) {\n color = decomposeColor(color);\n value = clampWrapper(value);\n if (color.type === 'rgb' || color.type === 'hsl') {\n color.type += 'a';\n }\n if (color.type === 'color') {\n color.values[3] = `/${value}`;\n } else {\n color.values[3] = value;\n }\n return recomposeColor(color);\n}\nexport function private_safeAlpha(color, value, warning) {\n try {\n return alpha(color, value);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Darkens a color.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} coefficient - multiplier in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function darken(color, coefficient) {\n color = decomposeColor(color);\n coefficient = clampWrapper(coefficient);\n if (color.type.indexOf('hsl') !== -1) {\n color.values[2] *= 1 - coefficient;\n } else if (color.type.indexOf('rgb') !== -1 || color.type.indexOf('color') !== -1) {\n for (let i = 0; i < 3; i += 1) {\n color.values[i] *= 1 - coefficient;\n }\n }\n return recomposeColor(color);\n}\nexport function private_safeDarken(color, coefficient, warning) {\n try {\n return darken(color, coefficient);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Lightens a color.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} coefficient - multiplier in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function lighten(color, coefficient) {\n color = decomposeColor(color);\n coefficient = clampWrapper(coefficient);\n if (color.type.indexOf('hsl') !== -1) {\n color.values[2] += (100 - color.values[2]) * coefficient;\n } else if (color.type.indexOf('rgb') !== -1) {\n for (let i = 0; i < 3; i += 1) {\n color.values[i] += (255 - color.values[i]) * coefficient;\n }\n } else if (color.type.indexOf('color') !== -1) {\n for (let i = 0; i < 3; i += 1) {\n color.values[i] += (1 - color.values[i]) * coefficient;\n }\n }\n return recomposeColor(color);\n}\nexport function private_safeLighten(color, coefficient, warning) {\n try {\n return lighten(color, coefficient);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Darken or lighten a color, depending on its luminance.\n * Light colors are darkened, dark colors are lightened.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} coefficient=0.15 - multiplier in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function emphasize(color, coefficient = 0.15) {\n return getLuminance(color) > 0.5 ? darken(color, coefficient) : lighten(color, coefficient);\n}\nexport function private_safeEmphasize(color, coefficient, warning) {\n try {\n return emphasize(color, coefficient);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Blend a transparent overlay color with a background color, resulting in a single\n * RGB color.\n * @param {string} background - CSS color\n * @param {string} overlay - CSS color\n * @param {number} opacity - Opacity multiplier in the range 0 - 1\n * @param {number} [gamma=1.0] - Gamma correction factor. For gamma-correct blending, 2.2 is usual.\n */\nexport function blend(background, overlay, opacity, gamma = 1.0) {\n const blendChannel = (b, o) => Math.round((b ** (1 / gamma) * (1 - opacity) + o ** (1 / gamma) * opacity) ** gamma);\n const backgroundColor = decomposeColor(background);\n const overlayColor = decomposeColor(overlay);\n const rgb = [blendChannel(backgroundColor.values[0], overlayColor.values[0]), blendChannel(backgroundColor.values[1], overlayColor.values[1]), blendChannel(backgroundColor.values[2], overlayColor.values[2])];\n return recomposeColor({\n type: 'rgb',\n values: rgb\n });\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nexport default function createMixins(breakpoints, mixins) {\n return _extends({\n toolbar: {\n minHeight: 56,\n [breakpoints.up('xs')]: {\n '@media (orientation: landscape)': {\n minHeight: 48\n }\n },\n [breakpoints.up('sm')]: {\n minHeight: 64\n }\n }\n }, mixins);\n}","const common = {\n black: '#000',\n white: '#fff'\n};\nexport default common;","const grey = {\n 50: '#fafafa',\n 100: '#f5f5f5',\n 200: '#eeeeee',\n 300: '#e0e0e0',\n 400: '#bdbdbd',\n 500: '#9e9e9e',\n 600: '#757575',\n 700: '#616161',\n 800: '#424242',\n 900: '#212121',\n A100: '#f5f5f5',\n A200: '#eeeeee',\n A400: '#bdbdbd',\n A700: '#616161'\n};\nexport default grey;","const purple = {\n 50: '#f3e5f5',\n 100: '#e1bee7',\n 200: '#ce93d8',\n 300: '#ba68c8',\n 400: '#ab47bc',\n 500: '#9c27b0',\n 600: '#8e24aa',\n 700: '#7b1fa2',\n 800: '#6a1b9a',\n 900: '#4a148c',\n A100: '#ea80fc',\n A200: '#e040fb',\n A400: '#d500f9',\n A700: '#aa00ff'\n};\nexport default purple;","const red = {\n 50: '#ffebee',\n 100: '#ffcdd2',\n 200: '#ef9a9a',\n 300: '#e57373',\n 400: '#ef5350',\n 500: '#f44336',\n 600: '#e53935',\n 700: '#d32f2f',\n 800: '#c62828',\n 900: '#b71c1c',\n A100: '#ff8a80',\n A200: '#ff5252',\n A400: '#ff1744',\n A700: '#d50000'\n};\nexport default red;","const orange = {\n 50: '#fff3e0',\n 100: '#ffe0b2',\n 200: '#ffcc80',\n 300: '#ffb74d',\n 400: '#ffa726',\n 500: '#ff9800',\n 600: '#fb8c00',\n 700: '#f57c00',\n 800: '#ef6c00',\n 900: '#e65100',\n A100: '#ffd180',\n A200: '#ffab40',\n A400: '#ff9100',\n A700: '#ff6d00'\n};\nexport default orange;","const blue = {\n 50: '#e3f2fd',\n 100: '#bbdefb',\n 200: '#90caf9',\n 300: '#64b5f6',\n 400: '#42a5f5',\n 500: '#2196f3',\n 600: '#1e88e5',\n 700: '#1976d2',\n 800: '#1565c0',\n 900: '#0d47a1',\n A100: '#82b1ff',\n A200: '#448aff',\n A400: '#2979ff',\n A700: '#2962ff'\n};\nexport default blue;","const lightBlue = {\n 50: '#e1f5fe',\n 100: '#b3e5fc',\n 200: '#81d4fa',\n 300: '#4fc3f7',\n 400: '#29b6f6',\n 500: '#03a9f4',\n 600: '#039be5',\n 700: '#0288d1',\n 800: '#0277bd',\n 900: '#01579b',\n A100: '#80d8ff',\n A200: '#40c4ff',\n A400: '#00b0ff',\n A700: '#0091ea'\n};\nexport default lightBlue;","const green = {\n 50: '#e8f5e9',\n 100: '#c8e6c9',\n 200: '#a5d6a7',\n 300: '#81c784',\n 400: '#66bb6a',\n 500: '#4caf50',\n 600: '#43a047',\n 700: '#388e3c',\n 800: '#2e7d32',\n 900: '#1b5e20',\n A100: '#b9f6ca',\n A200: '#69f0ae',\n A400: '#00e676',\n A700: '#00c853'\n};\nexport default green;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\nconst _excluded = [\"mode\", \"contrastThreshold\", \"tonalOffset\"];\nimport { deepmerge } from '@mui/utils';\nimport { darken, getContrastRatio, lighten } from '@mui/system';\nimport common from '../colors/common';\nimport grey from '../colors/grey';\nimport purple from '../colors/purple';\nimport red from '../colors/red';\nimport orange from '../colors/orange';\nimport blue from '../colors/blue';\nimport lightBlue from '../colors/lightBlue';\nimport green from '../colors/green';\nexport const light = {\n // The colors used to style the text.\n text: {\n // The most important text.\n primary: 'rgba(0, 0, 0, 0.87)',\n // Secondary text.\n secondary: 'rgba(0, 0, 0, 0.6)',\n // Disabled text have even lower visual prominence.\n disabled: 'rgba(0, 0, 0, 0.38)'\n },\n // The color used to divide different elements.\n divider: 'rgba(0, 0, 0, 0.12)',\n // The background colors used to style the surfaces.\n // Consistency between these values is important.\n background: {\n paper: common.white,\n default: common.white\n },\n // The colors used to style the action elements.\n action: {\n // The color of an active action like an icon button.\n active: 'rgba(0, 0, 0, 0.54)',\n // The color of an hovered action.\n hover: 'rgba(0, 0, 0, 0.04)',\n hoverOpacity: 0.04,\n // The color of a selected action.\n selected: 'rgba(0, 0, 0, 0.08)',\n selectedOpacity: 0.08,\n // The color of a disabled action.\n disabled: 'rgba(0, 0, 0, 0.26)',\n // The background color of a disabled action.\n disabledBackground: 'rgba(0, 0, 0, 0.12)',\n disabledOpacity: 0.38,\n focus: 'rgba(0, 0, 0, 0.12)',\n focusOpacity: 0.12,\n activatedOpacity: 0.12\n }\n};\nexport const dark = {\n text: {\n primary: common.white,\n secondary: 'rgba(255, 255, 255, 0.7)',\n disabled: 'rgba(255, 255, 255, 0.5)',\n icon: 'rgba(255, 255, 255, 0.5)'\n },\n divider: 'rgba(255, 255, 255, 0.12)',\n background: {\n paper: '#121212',\n default: '#121212'\n },\n action: {\n active: common.white,\n hover: 'rgba(255, 255, 255, 0.08)',\n hoverOpacity: 0.08,\n selected: 'rgba(255, 255, 255, 0.16)',\n selectedOpacity: 0.16,\n disabled: 'rgba(255, 255, 255, 0.3)',\n disabledBackground: 'rgba(255, 255, 255, 0.12)',\n disabledOpacity: 0.38,\n focus: 'rgba(255, 255, 255, 0.12)',\n focusOpacity: 0.12,\n activatedOpacity: 0.24\n }\n};\nfunction addLightOrDark(intent, direction, shade, tonalOffset) {\n const tonalOffsetLight = tonalOffset.light || tonalOffset;\n const tonalOffsetDark = tonalOffset.dark || tonalOffset * 1.5;\n if (!intent[direction]) {\n if (intent.hasOwnProperty(shade)) {\n intent[direction] = intent[shade];\n } else if (direction === 'light') {\n intent.light = lighten(intent.main, tonalOffsetLight);\n } else if (direction === 'dark') {\n intent.dark = darken(intent.main, tonalOffsetDark);\n }\n }\n}\nfunction getDefaultPrimary(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: blue[200],\n light: blue[50],\n dark: blue[400]\n };\n }\n return {\n main: blue[700],\n light: blue[400],\n dark: blue[800]\n };\n}\nfunction getDefaultSecondary(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: purple[200],\n light: purple[50],\n dark: purple[400]\n };\n }\n return {\n main: purple[500],\n light: purple[300],\n dark: purple[700]\n };\n}\nfunction getDefaultError(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: red[500],\n light: red[300],\n dark: red[700]\n };\n }\n return {\n main: red[700],\n light: red[400],\n dark: red[800]\n };\n}\nfunction getDefaultInfo(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: lightBlue[400],\n light: lightBlue[300],\n dark: lightBlue[700]\n };\n }\n return {\n main: lightBlue[700],\n light: lightBlue[500],\n dark: lightBlue[900]\n };\n}\nfunction getDefaultSuccess(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: green[400],\n light: green[300],\n dark: green[700]\n };\n }\n return {\n main: green[800],\n light: green[500],\n dark: green[900]\n };\n}\nfunction getDefaultWarning(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: orange[400],\n light: orange[300],\n dark: orange[700]\n };\n }\n return {\n main: '#ed6c02',\n // closest to orange[800] that pass 3:1.\n light: orange[500],\n dark: orange[900]\n };\n}\nexport default function createPalette(palette) {\n const {\n mode = 'light',\n contrastThreshold = 3,\n tonalOffset = 0.2\n } = palette,\n other = _objectWithoutPropertiesLoose(palette, _excluded);\n const primary = palette.primary || getDefaultPrimary(mode);\n const secondary = palette.secondary || getDefaultSecondary(mode);\n const error = palette.error || getDefaultError(mode);\n const info = palette.info || getDefaultInfo(mode);\n const success = palette.success || getDefaultSuccess(mode);\n const warning = palette.warning || getDefaultWarning(mode);\n\n // Use the same logic as\n // Bootstrap: https://github.com/twbs/bootstrap/blob/1d6e3710dd447de1a200f29e8fa521f8a0908f70/scss/_functions.scss#L59\n // and material-components-web https://github.com/material-components/material-components-web/blob/ac46b8863c4dab9fc22c4c662dc6bd1b65dd652f/packages/mdc-theme/_functions.scss#L54\n function getContrastText(background) {\n const contrastText = getContrastRatio(background, dark.text.primary) >= contrastThreshold ? dark.text.primary : light.text.primary;\n if (process.env.NODE_ENV !== 'production') {\n const contrast = getContrastRatio(background, contrastText);\n if (contrast < 3) {\n console.error([`MUI: The contrast ratio of ${contrast}:1 for ${contrastText} on ${background}`, 'falls below the WCAG recommended absolute minimum contrast ratio of 3:1.', 'https://www.w3.org/TR/2008/REC-WCAG20-20081211/#visual-audio-contrast-contrast'].join('\\n'));\n }\n }\n return contrastText;\n }\n const augmentColor = ({\n color,\n name,\n mainShade = 500,\n lightShade = 300,\n darkShade = 700\n }) => {\n color = _extends({}, color);\n if (!color.main && color[mainShade]) {\n color.main = color[mainShade];\n }\n if (!color.hasOwnProperty('main')) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: The color${name ? ` (${name})` : ''} provided to augmentColor(color) is invalid.\nThe color object needs to have a \\`main\\` property or a \\`${mainShade}\\` property.` : _formatMuiErrorMessage(11, name ? ` (${name})` : '', mainShade));\n }\n if (typeof color.main !== 'string') {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: The color${name ? ` (${name})` : ''} provided to augmentColor(color) is invalid.\n\\`color.main\\` should be a string, but \\`${JSON.stringify(color.main)}\\` was provided instead.\n\nDid you intend to use one of the following approaches?\n\nimport { green } from \"@mui/material/colors\";\n\nconst theme1 = createTheme({ palette: {\n primary: green,\n} });\n\nconst theme2 = createTheme({ palette: {\n primary: { main: green[500] },\n} });` : _formatMuiErrorMessage(12, name ? ` (${name})` : '', JSON.stringify(color.main)));\n }\n addLightOrDark(color, 'light', lightShade, tonalOffset);\n addLightOrDark(color, 'dark', darkShade, tonalOffset);\n if (!color.contrastText) {\n color.contrastText = getContrastText(color.main);\n }\n return color;\n };\n const modes = {\n dark,\n light\n };\n if (process.env.NODE_ENV !== 'production') {\n if (!modes[mode]) {\n console.error(`MUI: The palette mode \\`${mode}\\` is not supported.`);\n }\n }\n const paletteOutput = deepmerge(_extends({\n // A collection of common colors.\n common: _extends({}, common),\n // prevent mutable object.\n // The palette mode, can be light or dark.\n mode,\n // The colors used to represent primary interface elements for a user.\n primary: augmentColor({\n color: primary,\n name: 'primary'\n }),\n // The colors used to represent secondary interface elements for a user.\n secondary: augmentColor({\n color: secondary,\n name: 'secondary',\n mainShade: 'A400',\n lightShade: 'A200',\n darkShade: 'A700'\n }),\n // The colors used to represent interface elements that the user should be made aware of.\n error: augmentColor({\n color: error,\n name: 'error'\n }),\n // The colors used to represent potentially dangerous actions or important messages.\n warning: augmentColor({\n color: warning,\n name: 'warning'\n }),\n // The colors used to present information to the user that is neutral and not necessarily important.\n info: augmentColor({\n color: info,\n name: 'info'\n }),\n // The colors used to indicate the successful completion of an action that user triggered.\n success: augmentColor({\n color: success,\n name: 'success'\n }),\n // The grey colors.\n grey,\n // Used by `getContrastText()` to maximize the contrast between\n // the background and the text.\n contrastThreshold,\n // Takes a background color and returns the text color that maximizes the contrast.\n getContrastText,\n // Generate a rich color object.\n augmentColor,\n // Used by the functions below to shift a color's luminance by approximately\n // two indexes within its tonal palette.\n // E.g., shift from Red 500 to Red 300 or Red 700.\n tonalOffset\n }, modes[mode]), other);\n return paletteOutput;\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"fontFamily\", \"fontSize\", \"fontWeightLight\", \"fontWeightRegular\", \"fontWeightMedium\", \"fontWeightBold\", \"htmlFontSize\", \"allVariants\", \"pxToRem\"];\nimport { deepmerge } from '@mui/utils';\nfunction round(value) {\n return Math.round(value * 1e5) / 1e5;\n}\nconst caseAllCaps = {\n textTransform: 'uppercase'\n};\nconst defaultFontFamily = '\"Roboto\", \"Helvetica\", \"Arial\", sans-serif';\n\n/**\n * @see @link{https://m2.material.io/design/typography/the-type-system.html}\n * @see @link{https://m2.material.io/design/typography/understanding-typography.html}\n */\nexport default function createTypography(palette, typography) {\n const _ref = typeof typography === 'function' ? typography(palette) : typography,\n {\n fontFamily = defaultFontFamily,\n // The default font size of the Material Specification.\n fontSize = 14,\n // px\n fontWeightLight = 300,\n fontWeightRegular = 400,\n fontWeightMedium = 500,\n fontWeightBold = 700,\n // Tell MUI what's the font-size on the html element.\n // 16px is the default font-size used by browsers.\n htmlFontSize = 16,\n // Apply the CSS properties to all the variants.\n allVariants,\n pxToRem: pxToRem2\n } = _ref,\n other = _objectWithoutPropertiesLoose(_ref, _excluded);\n if (process.env.NODE_ENV !== 'production') {\n if (typeof fontSize !== 'number') {\n console.error('MUI: `fontSize` is required to be a number.');\n }\n if (typeof htmlFontSize !== 'number') {\n console.error('MUI: `htmlFontSize` is required to be a number.');\n }\n }\n const coef = fontSize / 14;\n const pxToRem = pxToRem2 || (size => `${size / htmlFontSize * coef}rem`);\n const buildVariant = (fontWeight, size, lineHeight, letterSpacing, casing) => _extends({\n fontFamily,\n fontWeight,\n fontSize: pxToRem(size),\n // Unitless following https://meyerweb.com/eric/thoughts/2006/02/08/unitless-line-heights/\n lineHeight\n }, fontFamily === defaultFontFamily ? {\n letterSpacing: `${round(letterSpacing / size)}em`\n } : {}, casing, allVariants);\n const variants = {\n h1: buildVariant(fontWeightLight, 96, 1.167, -1.5),\n h2: buildVariant(fontWeightLight, 60, 1.2, -0.5),\n h3: buildVariant(fontWeightRegular, 48, 1.167, 0),\n h4: buildVariant(fontWeightRegular, 34, 1.235, 0.25),\n h5: buildVariant(fontWeightRegular, 24, 1.334, 0),\n h6: buildVariant(fontWeightMedium, 20, 1.6, 0.15),\n subtitle1: buildVariant(fontWeightRegular, 16, 1.75, 0.15),\n subtitle2: buildVariant(fontWeightMedium, 14, 1.57, 0.1),\n body1: buildVariant(fontWeightRegular, 16, 1.5, 0.15),\n body2: buildVariant(fontWeightRegular, 14, 1.43, 0.15),\n button: buildVariant(fontWeightMedium, 14, 1.75, 0.4, caseAllCaps),\n caption: buildVariant(fontWeightRegular, 12, 1.66, 0.4),\n overline: buildVariant(fontWeightRegular, 12, 2.66, 1, caseAllCaps),\n // TODO v6: Remove handling of 'inherit' variant from the theme as it is already handled in Material UI's Typography component. Also, remember to remove the associated types.\n inherit: {\n fontFamily: 'inherit',\n fontWeight: 'inherit',\n fontSize: 'inherit',\n lineHeight: 'inherit',\n letterSpacing: 'inherit'\n }\n };\n return deepmerge(_extends({\n htmlFontSize,\n pxToRem,\n fontFamily,\n fontSize,\n fontWeightLight,\n fontWeightRegular,\n fontWeightMedium,\n fontWeightBold\n }, variants), other, {\n clone: false // No need to clone deep\n });\n}","const shadowKeyUmbraOpacity = 0.2;\nconst shadowKeyPenumbraOpacity = 0.14;\nconst shadowAmbientShadowOpacity = 0.12;\nfunction createShadow(...px) {\n return [`${px[0]}px ${px[1]}px ${px[2]}px ${px[3]}px rgba(0,0,0,${shadowKeyUmbraOpacity})`, `${px[4]}px ${px[5]}px ${px[6]}px ${px[7]}px rgba(0,0,0,${shadowKeyPenumbraOpacity})`, `${px[8]}px ${px[9]}px ${px[10]}px ${px[11]}px rgba(0,0,0,${shadowAmbientShadowOpacity})`].join(',');\n}\n\n// Values from https://github.com/material-components/material-components-web/blob/be8747f94574669cb5e7add1a7c54fa41a89cec7/packages/mdc-elevation/_variables.scss\nconst shadows = ['none', createShadow(0, 2, 1, -1, 0, 1, 1, 0, 0, 1, 3, 0), createShadow(0, 3, 1, -2, 0, 2, 2, 0, 0, 1, 5, 0), createShadow(0, 3, 3, -2, 0, 3, 4, 0, 0, 1, 8, 0), createShadow(0, 2, 4, -1, 0, 4, 5, 0, 0, 1, 10, 0), createShadow(0, 3, 5, -1, 0, 5, 8, 0, 0, 1, 14, 0), createShadow(0, 3, 5, -1, 0, 6, 10, 0, 0, 1, 18, 0), createShadow(0, 4, 5, -2, 0, 7, 10, 1, 0, 2, 16, 1), createShadow(0, 5, 5, -3, 0, 8, 10, 1, 0, 3, 14, 2), createShadow(0, 5, 6, -3, 0, 9, 12, 1, 0, 3, 16, 2), createShadow(0, 6, 6, -3, 0, 10, 14, 1, 0, 4, 18, 3), createShadow(0, 6, 7, -4, 0, 11, 15, 1, 0, 4, 20, 3), createShadow(0, 7, 8, -4, 0, 12, 17, 2, 0, 5, 22, 4), createShadow(0, 7, 8, -4, 0, 13, 19, 2, 0, 5, 24, 4), createShadow(0, 7, 9, -4, 0, 14, 21, 2, 0, 5, 26, 4), createShadow(0, 8, 9, -5, 0, 15, 22, 2, 0, 6, 28, 5), createShadow(0, 8, 10, -5, 0, 16, 24, 2, 0, 6, 30, 5), createShadow(0, 8, 11, -5, 0, 17, 26, 2, 0, 6, 32, 5), createShadow(0, 9, 11, -5, 0, 18, 28, 2, 0, 7, 34, 6), createShadow(0, 9, 12, -6, 0, 19, 29, 2, 0, 7, 36, 6), createShadow(0, 10, 13, -6, 0, 20, 31, 3, 0, 8, 38, 7), createShadow(0, 10, 13, -6, 0, 21, 33, 3, 0, 8, 40, 7), createShadow(0, 10, 14, -6, 0, 22, 35, 3, 0, 8, 42, 7), createShadow(0, 11, 14, -7, 0, 23, 36, 3, 0, 9, 44, 8), createShadow(0, 11, 15, -7, 0, 24, 38, 3, 0, 9, 46, 8)];\nexport default shadows;","import _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nconst _excluded = [\"duration\", \"easing\", \"delay\"];\n// Follow https://material.google.com/motion/duration-easing.html#duration-easing-natural-easing-curves\n// to learn the context in which each easing should be used.\nexport const easing = {\n // This is the most common easing curve.\n easeInOut: 'cubic-bezier(0.4, 0, 0.2, 1)',\n // Objects enter the screen at full velocity from off-screen and\n // slowly decelerate to a resting point.\n easeOut: 'cubic-bezier(0.0, 0, 0.2, 1)',\n // Objects leave the screen at full velocity. They do not decelerate when off-screen.\n easeIn: 'cubic-bezier(0.4, 0, 1, 1)',\n // The sharp curve is used by objects that may return to the screen at any time.\n sharp: 'cubic-bezier(0.4, 0, 0.6, 1)'\n};\n\n// Follow https://m2.material.io/guidelines/motion/duration-easing.html#duration-easing-common-durations\n// to learn when use what timing\nexport const duration = {\n shortest: 150,\n shorter: 200,\n short: 250,\n // most basic recommended timing\n standard: 300,\n // this is to be used in complex animations\n complex: 375,\n // recommended when something is entering screen\n enteringScreen: 225,\n // recommended when something is leaving screen\n leavingScreen: 195\n};\nfunction formatMs(milliseconds) {\n return `${Math.round(milliseconds)}ms`;\n}\nfunction getAutoHeightDuration(height) {\n if (!height) {\n return 0;\n }\n const constant = height / 36;\n\n // https://www.wolframalpha.com/input/?i=(4+%2B+15+*+(x+%2F+36+)+**+0.25+%2B+(x+%2F+36)+%2F+5)+*+10\n return Math.round((4 + 15 * constant ** 0.25 + constant / 5) * 10);\n}\nexport default function createTransitions(inputTransitions) {\n const mergedEasing = _extends({}, easing, inputTransitions.easing);\n const mergedDuration = _extends({}, duration, inputTransitions.duration);\n const create = (props = ['all'], options = {}) => {\n const {\n duration: durationOption = mergedDuration.standard,\n easing: easingOption = mergedEasing.easeInOut,\n delay = 0\n } = options,\n other = _objectWithoutPropertiesLoose(options, _excluded);\n if (process.env.NODE_ENV !== 'production') {\n const isString = value => typeof value === 'string';\n // IE11 support, replace with Number.isNaN\n // eslint-disable-next-line no-restricted-globals\n const isNumber = value => !isNaN(parseFloat(value));\n if (!isString(props) && !Array.isArray(props)) {\n console.error('MUI: Argument \"props\" must be a string or Array.');\n }\n if (!isNumber(durationOption) && !isString(durationOption)) {\n console.error(`MUI: Argument \"duration\" must be a number or a string but found ${durationOption}.`);\n }\n if (!isString(easingOption)) {\n console.error('MUI: Argument \"easing\" must be a string.');\n }\n if (!isNumber(delay) && !isString(delay)) {\n console.error('MUI: Argument \"delay\" must be a number or a string.');\n }\n if (typeof options !== 'object') {\n console.error(['MUI: Secong argument of transition.create must be an object.', \"Arguments should be either `create('prop1', options)` or `create(['prop1', 'prop2'], options)`\"].join('\\n'));\n }\n if (Object.keys(other).length !== 0) {\n console.error(`MUI: Unrecognized argument(s) [${Object.keys(other).join(',')}].`);\n }\n }\n return (Array.isArray(props) ? props : [props]).map(animatedProp => `${animatedProp} ${typeof durationOption === 'string' ? durationOption : formatMs(durationOption)} ${easingOption} ${typeof delay === 'string' ? delay : formatMs(delay)}`).join(',');\n };\n return _extends({\n getAutoHeightDuration,\n create\n }, inputTransitions, {\n easing: mergedEasing,\n duration: mergedDuration\n });\n}","// We need to centralize the zIndex definitions as they work\n// like global values in the browser.\nconst zIndex = {\n mobileStepper: 1000,\n fab: 1050,\n speedDial: 1050,\n appBar: 1100,\n drawer: 1200,\n modal: 1300,\n snackbar: 1400,\n tooltip: 1500\n};\nexport default zIndex;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\nconst _excluded = [\"breakpoints\", \"mixins\", \"spacing\", \"palette\", \"transitions\", \"typography\", \"shape\"];\nimport { deepmerge } from '@mui/utils';\nimport { createTheme as systemCreateTheme, unstable_defaultSxConfig as defaultSxConfig, unstable_styleFunctionSx as styleFunctionSx } from '@mui/system';\nimport generateUtilityClass from '@mui/utils/generateUtilityClass';\nimport createMixins from './createMixins';\nimport createPalette from './createPalette';\nimport createTypography from './createTypography';\nimport shadows from './shadows';\nimport createTransitions from './createTransitions';\nimport zIndex from './zIndex';\nfunction createTheme(options = {}, ...args) {\n const {\n mixins: mixinsInput = {},\n palette: paletteInput = {},\n transitions: transitionsInput = {},\n typography: typographyInput = {}\n } = options,\n other = _objectWithoutPropertiesLoose(options, _excluded);\n if (options.vars) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: \\`vars\\` is a private field used for CSS variables support.\nPlease use another name.` : _formatMuiErrorMessage(18));\n }\n const palette = createPalette(paletteInput);\n const systemTheme = systemCreateTheme(options);\n let muiTheme = deepmerge(systemTheme, {\n mixins: createMixins(systemTheme.breakpoints, mixinsInput),\n palette,\n // Don't use [...shadows] until you've verified its transpiled code is not invoking the iterator protocol.\n shadows: shadows.slice(),\n typography: createTypography(palette, typographyInput),\n transitions: createTransitions(transitionsInput),\n zIndex: _extends({}, zIndex)\n });\n muiTheme = deepmerge(muiTheme, other);\n muiTheme = args.reduce((acc, argument) => deepmerge(acc, argument), muiTheme);\n if (process.env.NODE_ENV !== 'production') {\n // TODO v6: Refactor to use globalStateClassesMapping from @mui/utils once `readOnly` state class is used in Rating component.\n const stateClasses = ['active', 'checked', 'completed', 'disabled', 'error', 'expanded', 'focused', 'focusVisible', 'required', 'selected'];\n const traverse = (node, component) => {\n let key;\n\n // eslint-disable-next-line guard-for-in, no-restricted-syntax\n for (key in node) {\n const child = node[key];\n if (stateClasses.indexOf(key) !== -1 && Object.keys(child).length > 0) {\n if (process.env.NODE_ENV !== 'production') {\n const stateClass = generateUtilityClass('', key);\n console.error([`MUI: The \\`${component}\\` component increases ` + `the CSS specificity of the \\`${key}\\` internal state.`, 'You can not override it like this: ', JSON.stringify(node, null, 2), '', `Instead, you need to use the '&.${stateClass}' syntax:`, JSON.stringify({\n root: {\n [`&.${stateClass}`]: child\n }\n }, null, 2), '', 'https://mui.com/r/state-classes-guide'].join('\\n'));\n }\n // Remove the style to prevent global conflicts.\n node[key] = {};\n }\n }\n };\n Object.keys(muiTheme.components).forEach(component => {\n const styleOverrides = muiTheme.components[component].styleOverrides;\n if (styleOverrides && component.indexOf('Mui') === 0) {\n traverse(styleOverrides, component);\n }\n });\n }\n muiTheme.unstable_sxConfig = _extends({}, defaultSxConfig, other == null ? void 0 : other.unstable_sxConfig);\n muiTheme.unstable_sx = function sx(props) {\n return styleFunctionSx({\n sx: props,\n theme: this\n });\n };\n return muiTheme;\n}\nlet warnedOnce = false;\nexport function createMuiTheme(...args) {\n if (process.env.NODE_ENV !== 'production') {\n if (!warnedOnce) {\n warnedOnce = true;\n console.error(['MUI: the createMuiTheme function was renamed to createTheme.', '', \"You should use `import { createTheme } from '@mui/material/styles'`\"].join('\\n'));\n }\n }\n return createTheme(...args);\n}\nexport default createTheme;","'use client';\n\nimport createTheme from './createTheme';\nconst defaultTheme = createTheme();\nexport default defaultTheme;","export default '$$material';","'use client';\n\nimport { useThemeProps as systemUseThemeProps } from '@mui/system';\nimport defaultTheme from './defaultTheme';\nimport THEME_ID from './identifier';\nexport default function useThemeProps({\n props,\n name\n}) {\n return systemUseThemeProps({\n props,\n name,\n defaultTheme,\n themeId: THEME_ID\n });\n}","'use client';\n\nimport { createStyled, shouldForwardProp } from '@mui/system';\nimport defaultTheme from './defaultTheme';\nimport THEME_ID from './identifier';\nexport const rootShouldForwardProp = prop => shouldForwardProp(prop) && prop !== 'classes';\nexport const slotShouldForwardProp = shouldForwardProp;\nconst styled = createStyled({\n themeId: THEME_ID,\n defaultTheme,\n rootShouldForwardProp\n});\nexport default styled;","import generateUtilityClasses from '@mui/utils/generateUtilityClasses';\nimport generateUtilityClass from '@mui/utils/generateUtilityClass';\nexport function getSvgIconUtilityClass(slot) {\n return generateUtilityClass('MuiSvgIcon', slot);\n}\nconst svgIconClasses = generateUtilityClasses('MuiSvgIcon', ['root', 'colorPrimary', 'colorSecondary', 'colorAction', 'colorError', 'colorDisabled', 'fontSizeInherit', 'fontSizeSmall', 'fontSizeMedium', 'fontSizeLarge']);\nexport default svgIconClasses;","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"children\", \"className\", \"color\", \"component\", \"fontSize\", \"htmlColor\", \"inheritViewBox\", \"titleAccess\", \"viewBox\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport clsx from 'clsx';\nimport { unstable_composeClasses as composeClasses } from '@mui/base/composeClasses';\nimport capitalize from '../utils/capitalize';\nimport useThemeProps from '../styles/useThemeProps';\nimport styled from '../styles/styled';\nimport { getSvgIconUtilityClass } from './svgIconClasses';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nimport { jsxs as _jsxs } from \"react/jsx-runtime\";\nconst useUtilityClasses = ownerState => {\n const {\n color,\n fontSize,\n classes\n } = ownerState;\n const slots = {\n root: ['root', color !== 'inherit' && `color${capitalize(color)}`, `fontSize${capitalize(fontSize)}`]\n };\n return composeClasses(slots, getSvgIconUtilityClass, classes);\n};\nconst SvgIconRoot = styled('svg', {\n name: 'MuiSvgIcon',\n slot: 'Root',\n overridesResolver: (props, styles) => {\n const {\n ownerState\n } = props;\n return [styles.root, ownerState.color !== 'inherit' && styles[`color${capitalize(ownerState.color)}`], styles[`fontSize${capitalize(ownerState.fontSize)}`]];\n }\n})(({\n theme,\n ownerState\n}) => {\n var _theme$transitions, _theme$transitions$cr, _theme$transitions2, _theme$typography, _theme$typography$pxT, _theme$typography2, _theme$typography2$px, _theme$typography3, _theme$typography3$px, _palette$ownerState$c, _palette, _palette2, _palette3;\n return {\n userSelect: 'none',\n width: '1em',\n height: '1em',\n display: 'inline-block',\n // the will define the property that has `currentColor`\n // e.g. heroicons uses fill=\"none\" and stroke=\"currentColor\"\n fill: ownerState.hasSvgAsChild ? undefined : 'currentColor',\n flexShrink: 0,\n transition: (_theme$transitions = theme.transitions) == null || (_theme$transitions$cr = _theme$transitions.create) == null ? void 0 : _theme$transitions$cr.call(_theme$transitions, 'fill', {\n duration: (_theme$transitions2 = theme.transitions) == null || (_theme$transitions2 = _theme$transitions2.duration) == null ? void 0 : _theme$transitions2.shorter\n }),\n fontSize: {\n inherit: 'inherit',\n small: ((_theme$typography = theme.typography) == null || (_theme$typography$pxT = _theme$typography.pxToRem) == null ? void 0 : _theme$typography$pxT.call(_theme$typography, 20)) || '1.25rem',\n medium: ((_theme$typography2 = theme.typography) == null || (_theme$typography2$px = _theme$typography2.pxToRem) == null ? void 0 : _theme$typography2$px.call(_theme$typography2, 24)) || '1.5rem',\n large: ((_theme$typography3 = theme.typography) == null || (_theme$typography3$px = _theme$typography3.pxToRem) == null ? void 0 : _theme$typography3$px.call(_theme$typography3, 35)) || '2.1875rem'\n }[ownerState.fontSize],\n // TODO v5 deprecate, v6 remove for sx\n color: (_palette$ownerState$c = (_palette = (theme.vars || theme).palette) == null || (_palette = _palette[ownerState.color]) == null ? void 0 : _palette.main) != null ? _palette$ownerState$c : {\n action: (_palette2 = (theme.vars || theme).palette) == null || (_palette2 = _palette2.action) == null ? void 0 : _palette2.active,\n disabled: (_palette3 = (theme.vars || theme).palette) == null || (_palette3 = _palette3.action) == null ? void 0 : _palette3.disabled,\n inherit: undefined\n }[ownerState.color]\n };\n});\nconst SvgIcon = /*#__PURE__*/React.forwardRef(function SvgIcon(inProps, ref) {\n const props = useThemeProps({\n props: inProps,\n name: 'MuiSvgIcon'\n });\n const {\n children,\n className,\n color = 'inherit',\n component = 'svg',\n fontSize = 'medium',\n htmlColor,\n inheritViewBox = false,\n titleAccess,\n viewBox = '0 0 24 24'\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const hasSvgAsChild = /*#__PURE__*/React.isValidElement(children) && children.type === 'svg';\n const ownerState = _extends({}, props, {\n color,\n component,\n fontSize,\n instanceFontSize: inProps.fontSize,\n inheritViewBox,\n viewBox,\n hasSvgAsChild\n });\n const more = {};\n if (!inheritViewBox) {\n more.viewBox = viewBox;\n }\n const classes = useUtilityClasses(ownerState);\n return /*#__PURE__*/_jsxs(SvgIconRoot, _extends({\n as: component,\n className: clsx(classes.root, className),\n focusable: \"false\",\n color: htmlColor,\n \"aria-hidden\": titleAccess ? undefined : true,\n role: titleAccess ? 'img' : undefined,\n ref: ref\n }, more, other, hasSvgAsChild && children.props, {\n ownerState: ownerState,\n children: [hasSvgAsChild ? children.props.children : children, titleAccess ? /*#__PURE__*/_jsx(\"title\", {\n children: titleAccess\n }) : null]\n }));\n});\nprocess.env.NODE_ENV !== \"production\" ? SvgIcon.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the d.ts file and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * Node passed into the SVG element.\n */\n children: PropTypes.node,\n /**\n * Override or extend the styles applied to the component.\n */\n classes: PropTypes.object,\n /**\n * @ignore\n */\n className: PropTypes.string,\n /**\n * The color of the component.\n * It supports both default and custom theme colors, which can be added as shown in the\n * [palette customization guide](https://mui.com/material-ui/customization/palette/#custom-colors).\n * You can use the `htmlColor` prop to apply a color attribute to the SVG element.\n * @default 'inherit'\n */\n color: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.oneOf(['inherit', 'action', 'disabled', 'primary', 'secondary', 'error', 'info', 'success', 'warning']), PropTypes.string]),\n /**\n * The component used for the root node.\n * Either a string to use a HTML element or a component.\n */\n component: PropTypes.elementType,\n /**\n * The fontSize applied to the icon. Defaults to 24px, but can be configure to inherit font size.\n * @default 'medium'\n */\n fontSize: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.oneOf(['inherit', 'large', 'medium', 'small']), PropTypes.string]),\n /**\n * Applies a color attribute to the SVG element.\n */\n htmlColor: PropTypes.string,\n /**\n * If `true`, the root node will inherit the custom `component`'s viewBox and the `viewBox`\n * prop will be ignored.\n * Useful when you want to reference a custom `component` and have `SvgIcon` pass that\n * `component`'s viewBox to the root node.\n * @default false\n */\n inheritViewBox: PropTypes.bool,\n /**\n * The shape-rendering attribute. The behavior of the different options is described on the\n * [MDN Web Docs](https://developer.mozilla.org/en-US/docs/Web/SVG/Attribute/shape-rendering).\n * If you are having issues with blurry icons you should investigate this prop.\n */\n shapeRendering: PropTypes.string,\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Provides a human-readable title for the element that contains it.\n * https://www.w3.org/TR/SVG-access/#Equivalent\n */\n titleAccess: PropTypes.string,\n /**\n * Allows you to redefine what the coordinates without units mean inside an SVG element.\n * For example, if the SVG element is 500 (width) by 200 (height),\n * and you pass viewBox=\"0 0 50 20\",\n * this means that the coordinates inside the SVG will go from the top left corner (0,0)\n * to bottom right (50,20) and each unit will be worth 10px.\n * @default '0 0 24 24'\n */\n viewBox: PropTypes.string\n} : void 0;\nSvgIcon.muiName = 'SvgIcon';\nexport default SvgIcon;","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport * as React from 'react';\nimport SvgIcon from '../SvgIcon';\n\n/**\n * Private module reserved for @mui packages.\n */\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nexport default function createSvgIcon(path, displayName) {\n function Component(props, ref) {\n return /*#__PURE__*/_jsx(SvgIcon, _extends({\n \"data-testid\": `${displayName}Icon`,\n ref: ref\n }, props, {\n children: path\n }));\n }\n if (process.env.NODE_ENV !== 'production') {\n // Need to set `displayName` on the inner component for React.memo.\n // React prior to 16.14 ignores `displayName` on the wrapper.\n Component.displayName = `${displayName}Icon`;\n }\n Component.muiName = SvgIcon.muiName;\n return /*#__PURE__*/React.memo( /*#__PURE__*/React.forwardRef(Component));\n}","'use client';\n\nimport { unstable_ClassNameGenerator as ClassNameGenerator } from '@mui/base/ClassNameGenerator';\nexport { default as capitalize } from './capitalize';\nexport { default as createChainedFunction } from './createChainedFunction';\nexport { default as createSvgIcon } from './createSvgIcon';\nexport { default as debounce } from './debounce';\nexport { default as deprecatedPropType } from './deprecatedPropType';\nexport { default as isMuiElement } from './isMuiElement';\nexport { default as ownerDocument } from './ownerDocument';\nexport { default as ownerWindow } from './ownerWindow';\nexport { default as requirePropFactory } from './requirePropFactory';\nexport { default as setRef } from './setRef';\nexport { default as unstable_useEnhancedEffect } from './useEnhancedEffect';\nexport { default as unstable_useId } from './useId';\nexport { default as unsupportedProp } from './unsupportedProp';\nexport { default as useControlled } from './useControlled';\nexport { default as useEventCallback } from './useEventCallback';\nexport { default as useForkRef } from './useForkRef';\nexport { default as useIsFocusVisible } from './useIsFocusVisible';\n// TODO: remove this export once ClassNameGenerator is stable\n// eslint-disable-next-line @typescript-eslint/naming-convention\nexport const unstable_ClassNameGenerator = {\n configure: generator => {\n if (process.env.NODE_ENV !== 'production') {\n console.warn(['MUI: `ClassNameGenerator` import from `@mui/material/utils` is outdated and might cause unexpected issues.', '', \"You should use `import { unstable_ClassNameGenerator } from '@mui/material/className'` instead\", '', 'The detail of the issue: https://github.com/mui/material-ui/issues/30011#issuecomment-1024993401', '', 'The updated documentation: https://mui.com/guides/classname-generator/'].join('\\n'));\n }\n ClassNameGenerator.configure(generator);\n }\n};","\"use strict\";\n'use client';\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nObject.defineProperty(exports, \"default\", {\n enumerable: true,\n get: function () {\n return _utils.createSvgIcon;\n }\n});\nvar _utils = require(\"@mui/material/utils\");","\"use strict\";\n\"use client\";\n\nvar _interopRequireDefault = require(\"@babel/runtime/helpers/interopRequireDefault\");\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = void 0;\nvar _createSvgIcon = _interopRequireDefault(require(\"./utils/createSvgIcon\"));\nvar _jsxRuntime = require(\"react/jsx-runtime\");\nvar _default = exports.default = (0, _createSvgIcon.default)( /*#__PURE__*/(0, _jsxRuntime.jsx)(\"path\", {\n d: \"m10 17 5-5-5-5z\"\n}), 'ArrowRight');","/**\n * Determines if a given element is a DOM element name (i.e. not a React component).\n */\nexport function isHostComponent(element) {\n return typeof element === 'string';\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport { isHostComponent } from './isHostComponent';\n\n/**\n * Type of the ownerState based on the type of an element it applies to.\n * This resolves to the provided OwnerState for React components and `undefined` for host components.\n * Falls back to `OwnerState | undefined` when the exact type can't be determined in development time.\n */\n\n/**\n * Appends the ownerState object to the props, merging with the existing one if necessary.\n *\n * @param elementType Type of the element that owns the `existingProps`. If the element is a DOM node or undefined, `ownerState` is not applied.\n * @param otherProps Props of the element.\n * @param ownerState\n */\nexport function appendOwnerState(elementType, otherProps, ownerState) {\n if (elementType === undefined || isHostComponent(elementType)) {\n return otherProps;\n }\n return _extends({}, otherProps, {\n ownerState: _extends({}, otherProps.ownerState, ownerState)\n });\n}","'use client';\n\nimport * as React from 'react';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nconst defaultContextValue = {\n disableDefaultClasses: false\n};\nconst ClassNameConfiguratorContext = /*#__PURE__*/React.createContext(defaultContextValue);\n/**\n * @ignore - internal hook.\n *\n * Wraps the `generateUtilityClass` function and controls how the classes are generated.\n * Currently it only affects whether the classes are applied or not.\n *\n * @returns Function to be called with the `generateUtilityClass` function specific to a component to generate the classes.\n */\nexport function useClassNamesOverride(generateUtilityClass) {\n const {\n disableDefaultClasses\n } = React.useContext(ClassNameConfiguratorContext);\n return slot => {\n if (disableDefaultClasses) {\n return '';\n }\n return generateUtilityClass(slot);\n };\n}\n\n/**\n * Allows to configure the components within to not apply any built-in classes.\n */\nexport function ClassNameConfigurator(props) {\n const {\n disableDefaultClasses,\n children\n } = props;\n const contextValue = React.useMemo(() => ({\n disableDefaultClasses: disableDefaultClasses != null ? disableDefaultClasses : false\n }), [disableDefaultClasses]);\n return /*#__PURE__*/_jsx(ClassNameConfiguratorContext.Provider, {\n value: contextValue,\n children: children\n });\n}","/**\n * Extracts event handlers from a given object.\n * A prop is considered an event handler if it is a function and its name starts with `on`.\n *\n * @param object An object to extract event handlers from.\n * @param excludeKeys An array of keys to exclude from the returned object.\n */\nexport function extractEventHandlers(object, excludeKeys = []) {\n if (object === undefined) {\n return {};\n }\n const result = {};\n Object.keys(object).filter(prop => prop.match(/^on[A-Z]/) && typeof object[prop] === 'function' && !excludeKeys.includes(prop)).forEach(prop => {\n result[prop] = object[prop];\n });\n return result;\n}","/**\n * If `componentProps` is a function, calls it with the provided `ownerState`.\n * Otherwise, just returns `componentProps`.\n */\nexport function resolveComponentProps(componentProps, ownerState, slotState) {\n if (typeof componentProps === 'function') {\n return componentProps(ownerState, slotState);\n }\n return componentProps;\n}","/**\n * Removes event handlers from the given object.\n * A field is considered an event handler if it is a function with a name beginning with `on`.\n *\n * @param object Object to remove event handlers from.\n * @returns Object with event handlers removed.\n */\nexport function omitEventHandlers(object) {\n if (object === undefined) {\n return {};\n }\n const result = {};\n Object.keys(object).filter(prop => !(prop.match(/^on[A-Z]/) && typeof object[prop] === 'function')).forEach(prop => {\n result[prop] = object[prop];\n });\n return result;\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport clsx from 'clsx';\nimport { extractEventHandlers } from './extractEventHandlers';\nimport { omitEventHandlers } from './omitEventHandlers';\n/**\n * Merges the slot component internal props (usually coming from a hook)\n * with the externally provided ones.\n *\n * The merge order is (the latter overrides the former):\n * 1. The internal props (specified as a getter function to work with get*Props hook result)\n * 2. Additional props (specified internally on a Base UI component)\n * 3. External props specified on the owner component. These should only be used on a root slot.\n * 4. External props specified in the `slotProps.*` prop.\n * 5. The `className` prop - combined from all the above.\n * @param parameters\n * @returns\n */\nexport function mergeSlotProps(parameters) {\n const {\n getSlotProps,\n additionalProps,\n externalSlotProps,\n externalForwardedProps,\n className\n } = parameters;\n if (!getSlotProps) {\n // The simpler case - getSlotProps is not defined, so no internal event handlers are defined,\n // so we can simply merge all the props without having to worry about extracting event handlers.\n const joinedClasses = clsx(additionalProps == null ? void 0 : additionalProps.className, className, externalForwardedProps == null ? void 0 : externalForwardedProps.className, externalSlotProps == null ? void 0 : externalSlotProps.className);\n const mergedStyle = _extends({}, additionalProps == null ? void 0 : additionalProps.style, externalForwardedProps == null ? void 0 : externalForwardedProps.style, externalSlotProps == null ? void 0 : externalSlotProps.style);\n const props = _extends({}, additionalProps, externalForwardedProps, externalSlotProps);\n if (joinedClasses.length > 0) {\n props.className = joinedClasses;\n }\n if (Object.keys(mergedStyle).length > 0) {\n props.style = mergedStyle;\n }\n return {\n props,\n internalRef: undefined\n };\n }\n\n // In this case, getSlotProps is responsible for calling the external event handlers.\n // We don't need to include them in the merged props because of this.\n\n const eventHandlers = extractEventHandlers(_extends({}, externalForwardedProps, externalSlotProps));\n const componentsPropsWithoutEventHandlers = omitEventHandlers(externalSlotProps);\n const otherPropsWithoutEventHandlers = omitEventHandlers(externalForwardedProps);\n const internalSlotProps = getSlotProps(eventHandlers);\n\n // The order of classes is important here.\n // Emotion (that we use in libraries consuming Base UI) depends on this order\n // to properly override style. It requires the most important classes to be last\n // (see https://github.com/mui/material-ui/pull/33205) for the related discussion.\n const joinedClasses = clsx(internalSlotProps == null ? void 0 : internalSlotProps.className, additionalProps == null ? void 0 : additionalProps.className, className, externalForwardedProps == null ? void 0 : externalForwardedProps.className, externalSlotProps == null ? void 0 : externalSlotProps.className);\n const mergedStyle = _extends({}, internalSlotProps == null ? void 0 : internalSlotProps.style, additionalProps == null ? void 0 : additionalProps.style, externalForwardedProps == null ? void 0 : externalForwardedProps.style, externalSlotProps == null ? void 0 : externalSlotProps.style);\n const props = _extends({}, internalSlotProps, additionalProps, otherPropsWithoutEventHandlers, componentsPropsWithoutEventHandlers);\n if (joinedClasses.length > 0) {\n props.className = joinedClasses;\n }\n if (Object.keys(mergedStyle).length > 0) {\n props.style = mergedStyle;\n }\n return {\n props,\n internalRef: internalSlotProps.ref\n };\n}","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"elementType\", \"externalSlotProps\", \"ownerState\", \"skipResolvingSlotProps\"];\nimport { unstable_useForkRef as useForkRef } from '@mui/utils';\nimport { appendOwnerState } from './appendOwnerState';\nimport { mergeSlotProps } from './mergeSlotProps';\nimport { resolveComponentProps } from './resolveComponentProps';\n/**\n * @ignore - do not document.\n * Builds the props to be passed into the slot of an unstyled component.\n * It merges the internal props of the component with the ones supplied by the user, allowing to customize the behavior.\n * If the slot component is not a host component, it also merges in the `ownerState`.\n *\n * @param parameters.getSlotProps - A function that returns the props to be passed to the slot component.\n */\nexport function useSlotProps(parameters) {\n var _parameters$additiona;\n const {\n elementType,\n externalSlotProps,\n ownerState,\n skipResolvingSlotProps = false\n } = parameters,\n rest = _objectWithoutPropertiesLoose(parameters, _excluded);\n const resolvedComponentsProps = skipResolvingSlotProps ? {} : resolveComponentProps(externalSlotProps, ownerState);\n const {\n props: mergedProps,\n internalRef\n } = mergeSlotProps(_extends({}, rest, {\n externalSlotProps: resolvedComponentsProps\n }));\n const ref = useForkRef(internalRef, resolvedComponentsProps == null ? void 0 : resolvedComponentsProps.ref, (_parameters$additiona = parameters.additionalProps) == null ? void 0 : _parameters$additiona.ref);\n const props = appendOwnerState(elementType, _extends({}, mergedProps, {\n ref\n }), ownerState);\n return props;\n}","import { globalStateClasses } from '@mui/utils/generateUtilityClass';\nconst GLOBAL_CLASS_PREFIX = 'base';\nfunction buildStateClass(state) {\n return `${GLOBAL_CLASS_PREFIX}--${state}`;\n}\nfunction buildSlotClass(componentName, slot) {\n return `${GLOBAL_CLASS_PREFIX}-${componentName}-${slot}`;\n}\nexport function generateUtilityClass(componentName, slot) {\n const globalStateClass = globalStateClasses[slot];\n return globalStateClass ? buildStateClass(globalStateClass) : buildSlotClass(componentName, slot);\n}\nexport function isGlobalState(slot) {\n return globalStateClasses[slot] !== undefined;\n}","import { generateUtilityClass } from '../generateUtilityClass';\nexport function generateUtilityClasses(componentName, slots) {\n const result = {};\n slots.forEach(slot => {\n result[slot] = generateUtilityClass(componentName, slot);\n });\n return result;\n}","'use client';\n\nimport * as React from 'react';\nimport * as ReactDOM from 'react-dom';\nimport PropTypes from 'prop-types';\nimport { exactProp, HTMLElementType, unstable_useEnhancedEffect as useEnhancedEffect, unstable_useForkRef as useForkRef, unstable_setRef as setRef } from '@mui/utils';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nfunction getContainer(container) {\n return typeof container === 'function' ? container() : container;\n}\n\n/**\n * Portals provide a first-class way to render children into a DOM node\n * that exists outside the DOM hierarchy of the parent component.\n *\n * Demos:\n *\n * - [Portal](https://mui.com/base-ui/react-portal/)\n *\n * API:\n *\n * - [Portal API](https://mui.com/base-ui/react-portal/components-api/#portal)\n */\nconst Portal = /*#__PURE__*/React.forwardRef(function Portal(props, forwardedRef) {\n const {\n children,\n container,\n disablePortal = false\n } = props;\n const [mountNode, setMountNode] = React.useState(null);\n // @ts-expect-error TODO upstream fix\n const handleRef = useForkRef( /*#__PURE__*/React.isValidElement(children) ? children.ref : null, forwardedRef);\n useEnhancedEffect(() => {\n if (!disablePortal) {\n setMountNode(getContainer(container) || document.body);\n }\n }, [container, disablePortal]);\n useEnhancedEffect(() => {\n if (mountNode && !disablePortal) {\n setRef(forwardedRef, mountNode);\n return () => {\n setRef(forwardedRef, null);\n };\n }\n return undefined;\n }, [forwardedRef, mountNode, disablePortal]);\n if (disablePortal) {\n if ( /*#__PURE__*/React.isValidElement(children)) {\n const newProps = {\n ref: handleRef\n };\n return /*#__PURE__*/React.cloneElement(children, newProps);\n }\n return /*#__PURE__*/_jsx(React.Fragment, {\n children: children\n });\n }\n return /*#__PURE__*/_jsx(React.Fragment, {\n children: mountNode ? /*#__PURE__*/ReactDOM.createPortal(children, mountNode) : mountNode\n });\n});\nprocess.env.NODE_ENV !== \"production\" ? Portal.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * The children to render into the `container`.\n */\n children: PropTypes.node,\n /**\n * An HTML element or function that returns one.\n * The `container` will have the portal children appended to it.\n *\n * You can also provide a callback, which is called in a React layout effect.\n * This lets you set the container from a ref, and also makes server-side rendering possible.\n *\n * By default, it uses the body of the top-level document object,\n * so it's simply `document.body` most of the time.\n */\n container: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.func]),\n /**\n * The `children` will be under the DOM hierarchy of the parent component.\n * @default false\n */\n disablePortal: PropTypes.bool\n} : void 0;\nif (process.env.NODE_ENV !== 'production') {\n // eslint-disable-next-line\n Portal['propTypes' + ''] = exactProp(Portal.propTypes);\n}\nexport { Portal };","export var top = 'top';\nexport var bottom = 'bottom';\nexport var right = 'right';\nexport var left = 'left';\nexport var auto = 'auto';\nexport var basePlacements = [top, bottom, right, left];\nexport var start = 'start';\nexport var end = 'end';\nexport var clippingParents = 'clippingParents';\nexport var viewport = 'viewport';\nexport var popper = 'popper';\nexport var reference = 'reference';\nexport var variationPlacements = /*#__PURE__*/basePlacements.reduce(function (acc, placement) {\n return acc.concat([placement + \"-\" + start, placement + \"-\" + end]);\n}, []);\nexport var placements = /*#__PURE__*/[].concat(basePlacements, [auto]).reduce(function (acc, placement) {\n return acc.concat([placement, placement + \"-\" + start, placement + \"-\" + end]);\n}, []); // modifiers that need to read the DOM\n\nexport var beforeRead = 'beforeRead';\nexport var read = 'read';\nexport var afterRead = 'afterRead'; // pure-logic modifiers\n\nexport var beforeMain = 'beforeMain';\nexport var main = 'main';\nexport var afterMain = 'afterMain'; // modifier with the purpose to write to the DOM (or write into a framework state)\n\nexport var beforeWrite = 'beforeWrite';\nexport var write = 'write';\nexport var afterWrite = 'afterWrite';\nexport var modifierPhases = [beforeRead, read, afterRead, beforeMain, main, afterMain, beforeWrite, write, afterWrite];","export default function getNodeName(element) {\n return element ? (element.nodeName || '').toLowerCase() : null;\n}","export default function getWindow(node) {\n if (node == null) {\n return window;\n }\n\n if (node.toString() !== '[object Window]') {\n var ownerDocument = node.ownerDocument;\n return ownerDocument ? ownerDocument.defaultView || window : window;\n }\n\n return node;\n}","import getWindow from \"./getWindow.js\";\n\nfunction isElement(node) {\n var OwnElement = getWindow(node).Element;\n return node instanceof OwnElement || node instanceof Element;\n}\n\nfunction isHTMLElement(node) {\n var OwnElement = getWindow(node).HTMLElement;\n return node instanceof OwnElement || node instanceof HTMLElement;\n}\n\nfunction isShadowRoot(node) {\n // IE 11 has no ShadowRoot\n if (typeof ShadowRoot === 'undefined') {\n return false;\n }\n\n var OwnElement = getWindow(node).ShadowRoot;\n return node instanceof OwnElement || node instanceof ShadowRoot;\n}\n\nexport { isElement, isHTMLElement, isShadowRoot };","import getNodeName from \"../dom-utils/getNodeName.js\";\nimport { isHTMLElement } from \"../dom-utils/instanceOf.js\"; // This modifier takes the styles prepared by the `computeStyles` modifier\n// and applies them to the HTMLElements such as popper and arrow\n\nfunction applyStyles(_ref) {\n var state = _ref.state;\n Object.keys(state.elements).forEach(function (name) {\n var style = state.styles[name] || {};\n var attributes = state.attributes[name] || {};\n var element = state.elements[name]; // arrow is optional + virtual elements\n\n if (!isHTMLElement(element) || !getNodeName(element)) {\n return;\n } // Flow doesn't support to extend this property, but it's the most\n // effective way to apply styles to an HTMLElement\n // $FlowFixMe[cannot-write]\n\n\n Object.assign(element.style, style);\n Object.keys(attributes).forEach(function (name) {\n var value = attributes[name];\n\n if (value === false) {\n element.removeAttribute(name);\n } else {\n element.setAttribute(name, value === true ? '' : value);\n }\n });\n });\n}\n\nfunction effect(_ref2) {\n var state = _ref2.state;\n var initialStyles = {\n popper: {\n position: state.options.strategy,\n left: '0',\n top: '0',\n margin: '0'\n },\n arrow: {\n position: 'absolute'\n },\n reference: {}\n };\n Object.assign(state.elements.popper.style, initialStyles.popper);\n state.styles = initialStyles;\n\n if (state.elements.arrow) {\n Object.assign(state.elements.arrow.style, initialStyles.arrow);\n }\n\n return function () {\n Object.keys(state.elements).forEach(function (name) {\n var element = state.elements[name];\n var attributes = state.attributes[name] || {};\n var styleProperties = Object.keys(state.styles.hasOwnProperty(name) ? state.styles[name] : initialStyles[name]); // Set all values to an empty string to unset them\n\n var style = styleProperties.reduce(function (style, property) {\n style[property] = '';\n return style;\n }, {}); // arrow is optional + virtual elements\n\n if (!isHTMLElement(element) || !getNodeName(element)) {\n return;\n }\n\n Object.assign(element.style, style);\n Object.keys(attributes).forEach(function (attribute) {\n element.removeAttribute(attribute);\n });\n });\n };\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'applyStyles',\n enabled: true,\n phase: 'write',\n fn: applyStyles,\n effect: effect,\n requires: ['computeStyles']\n};","import { auto } from \"../enums.js\";\nexport default function getBasePlacement(placement) {\n return placement.split('-')[0];\n}","export var max = Math.max;\nexport var min = Math.min;\nexport var round = Math.round;","export default function getUAString() {\n var uaData = navigator.userAgentData;\n\n if (uaData != null && uaData.brands && Array.isArray(uaData.brands)) {\n return uaData.brands.map(function (item) {\n return item.brand + \"/\" + item.version;\n }).join(' ');\n }\n\n return navigator.userAgent;\n}","import getUAString from \"../utils/userAgent.js\";\nexport default function isLayoutViewport() {\n return !/^((?!chrome|android).)*safari/i.test(getUAString());\n}","import { isElement, isHTMLElement } from \"./instanceOf.js\";\nimport { round } from \"../utils/math.js\";\nimport getWindow from \"./getWindow.js\";\nimport isLayoutViewport from \"./isLayoutViewport.js\";\nexport default function getBoundingClientRect(element, includeScale, isFixedStrategy) {\n if (includeScale === void 0) {\n includeScale = false;\n }\n\n if (isFixedStrategy === void 0) {\n isFixedStrategy = false;\n }\n\n var clientRect = element.getBoundingClientRect();\n var scaleX = 1;\n var scaleY = 1;\n\n if (includeScale && isHTMLElement(element)) {\n scaleX = element.offsetWidth > 0 ? round(clientRect.width) / element.offsetWidth || 1 : 1;\n scaleY = element.offsetHeight > 0 ? round(clientRect.height) / element.offsetHeight || 1 : 1;\n }\n\n var _ref = isElement(element) ? getWindow(element) : window,\n visualViewport = _ref.visualViewport;\n\n var addVisualOffsets = !isLayoutViewport() && isFixedStrategy;\n var x = (clientRect.left + (addVisualOffsets && visualViewport ? visualViewport.offsetLeft : 0)) / scaleX;\n var y = (clientRect.top + (addVisualOffsets && visualViewport ? visualViewport.offsetTop : 0)) / scaleY;\n var width = clientRect.width / scaleX;\n var height = clientRect.height / scaleY;\n return {\n width: width,\n height: height,\n top: y,\n right: x + width,\n bottom: y + height,\n left: x,\n x: x,\n y: y\n };\n}","import getBoundingClientRect from \"./getBoundingClientRect.js\"; // Returns the layout rect of an element relative to its offsetParent. Layout\n// means it doesn't take into account transforms.\n\nexport default function getLayoutRect(element) {\n var clientRect = getBoundingClientRect(element); // Use the clientRect sizes if it's not been transformed.\n // Fixes https://github.com/popperjs/popper-core/issues/1223\n\n var width = element.offsetWidth;\n var height = element.offsetHeight;\n\n if (Math.abs(clientRect.width - width) <= 1) {\n width = clientRect.width;\n }\n\n if (Math.abs(clientRect.height - height) <= 1) {\n height = clientRect.height;\n }\n\n return {\n x: element.offsetLeft,\n y: element.offsetTop,\n width: width,\n height: height\n };\n}","import { isShadowRoot } from \"./instanceOf.js\";\nexport default function contains(parent, child) {\n var rootNode = child.getRootNode && child.getRootNode(); // First, attempt with faster native method\n\n if (parent.contains(child)) {\n return true;\n } // then fallback to custom implementation with Shadow DOM support\n else if (rootNode && isShadowRoot(rootNode)) {\n var next = child;\n\n do {\n if (next && parent.isSameNode(next)) {\n return true;\n } // $FlowFixMe[prop-missing]: need a better way to handle this...\n\n\n next = next.parentNode || next.host;\n } while (next);\n } // Give up, the result is false\n\n\n return false;\n}","import getWindow from \"./getWindow.js\";\nexport default function getComputedStyle(element) {\n return getWindow(element).getComputedStyle(element);\n}","import getNodeName from \"./getNodeName.js\";\nexport default function isTableElement(element) {\n return ['table', 'td', 'th'].indexOf(getNodeName(element)) >= 0;\n}","import { isElement } from \"./instanceOf.js\";\nexport default function getDocumentElement(element) {\n // $FlowFixMe[incompatible-return]: assume body is always available\n return ((isElement(element) ? element.ownerDocument : // $FlowFixMe[prop-missing]\n element.document) || window.document).documentElement;\n}","import getNodeName from \"./getNodeName.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport { isShadowRoot } from \"./instanceOf.js\";\nexport default function getParentNode(element) {\n if (getNodeName(element) === 'html') {\n return element;\n }\n\n return (// this is a quicker (but less type safe) way to save quite some bytes from the bundle\n // $FlowFixMe[incompatible-return]\n // $FlowFixMe[prop-missing]\n element.assignedSlot || // step into the shadow DOM of the parent of a slotted node\n element.parentNode || ( // DOM Element detected\n isShadowRoot(element) ? element.host : null) || // ShadowRoot detected\n // $FlowFixMe[incompatible-call]: HTMLElement is a Node\n getDocumentElement(element) // fallback\n\n );\n}","import getWindow from \"./getWindow.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport getComputedStyle from \"./getComputedStyle.js\";\nimport { isHTMLElement, isShadowRoot } from \"./instanceOf.js\";\nimport isTableElement from \"./isTableElement.js\";\nimport getParentNode from \"./getParentNode.js\";\nimport getUAString from \"../utils/userAgent.js\";\n\nfunction getTrueOffsetParent(element) {\n if (!isHTMLElement(element) || // https://github.com/popperjs/popper-core/issues/837\n getComputedStyle(element).position === 'fixed') {\n return null;\n }\n\n return element.offsetParent;\n} // `.offsetParent` reports `null` for fixed elements, while absolute elements\n// return the containing block\n\n\nfunction getContainingBlock(element) {\n var isFirefox = /firefox/i.test(getUAString());\n var isIE = /Trident/i.test(getUAString());\n\n if (isIE && isHTMLElement(element)) {\n // In IE 9, 10 and 11 fixed elements containing block is always established by the viewport\n var elementCss = getComputedStyle(element);\n\n if (elementCss.position === 'fixed') {\n return null;\n }\n }\n\n var currentNode = getParentNode(element);\n\n if (isShadowRoot(currentNode)) {\n currentNode = currentNode.host;\n }\n\n while (isHTMLElement(currentNode) && ['html', 'body'].indexOf(getNodeName(currentNode)) < 0) {\n var css = getComputedStyle(currentNode); // This is non-exhaustive but covers the most common CSS properties that\n // create a containing block.\n // https://developer.mozilla.org/en-US/docs/Web/CSS/Containing_block#identifying_the_containing_block\n\n if (css.transform !== 'none' || css.perspective !== 'none' || css.contain === 'paint' || ['transform', 'perspective'].indexOf(css.willChange) !== -1 || isFirefox && css.willChange === 'filter' || isFirefox && css.filter && css.filter !== 'none') {\n return currentNode;\n } else {\n currentNode = currentNode.parentNode;\n }\n }\n\n return null;\n} // Gets the closest ancestor positioned element. Handles some edge cases,\n// such as table ancestors and cross browser bugs.\n\n\nexport default function getOffsetParent(element) {\n var window = getWindow(element);\n var offsetParent = getTrueOffsetParent(element);\n\n while (offsetParent && isTableElement(offsetParent) && getComputedStyle(offsetParent).position === 'static') {\n offsetParent = getTrueOffsetParent(offsetParent);\n }\n\n if (offsetParent && (getNodeName(offsetParent) === 'html' || getNodeName(offsetParent) === 'body' && getComputedStyle(offsetParent).position === 'static')) {\n return window;\n }\n\n return offsetParent || getContainingBlock(element) || window;\n}","export default function getMainAxisFromPlacement(placement) {\n return ['top', 'bottom'].indexOf(placement) >= 0 ? 'x' : 'y';\n}","import { max as mathMax, min as mathMin } from \"./math.js\";\nexport function within(min, value, max) {\n return mathMax(min, mathMin(value, max));\n}\nexport function withinMaxClamp(min, value, max) {\n var v = within(min, value, max);\n return v > max ? max : v;\n}","export default function getFreshSideObject() {\n return {\n top: 0,\n right: 0,\n bottom: 0,\n left: 0\n };\n}","import getFreshSideObject from \"./getFreshSideObject.js\";\nexport default function mergePaddingObject(paddingObject) {\n return Object.assign({}, getFreshSideObject(), paddingObject);\n}","export default function expandToHashMap(value, keys) {\n return keys.reduce(function (hashMap, key) {\n hashMap[key] = value;\n return hashMap;\n }, {});\n}","import getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getLayoutRect from \"../dom-utils/getLayoutRect.js\";\nimport contains from \"../dom-utils/contains.js\";\nimport getOffsetParent from \"../dom-utils/getOffsetParent.js\";\nimport getMainAxisFromPlacement from \"../utils/getMainAxisFromPlacement.js\";\nimport { within } from \"../utils/within.js\";\nimport mergePaddingObject from \"../utils/mergePaddingObject.js\";\nimport expandToHashMap from \"../utils/expandToHashMap.js\";\nimport { left, right, basePlacements, top, bottom } from \"../enums.js\"; // eslint-disable-next-line import/no-unused-modules\n\nvar toPaddingObject = function toPaddingObject(padding, state) {\n padding = typeof padding === 'function' ? padding(Object.assign({}, state.rects, {\n placement: state.placement\n })) : padding;\n return mergePaddingObject(typeof padding !== 'number' ? padding : expandToHashMap(padding, basePlacements));\n};\n\nfunction arrow(_ref) {\n var _state$modifiersData$;\n\n var state = _ref.state,\n name = _ref.name,\n options = _ref.options;\n var arrowElement = state.elements.arrow;\n var popperOffsets = state.modifiersData.popperOffsets;\n var basePlacement = getBasePlacement(state.placement);\n var axis = getMainAxisFromPlacement(basePlacement);\n var isVertical = [left, right].indexOf(basePlacement) >= 0;\n var len = isVertical ? 'height' : 'width';\n\n if (!arrowElement || !popperOffsets) {\n return;\n }\n\n var paddingObject = toPaddingObject(options.padding, state);\n var arrowRect = getLayoutRect(arrowElement);\n var minProp = axis === 'y' ? top : left;\n var maxProp = axis === 'y' ? bottom : right;\n var endDiff = state.rects.reference[len] + state.rects.reference[axis] - popperOffsets[axis] - state.rects.popper[len];\n var startDiff = popperOffsets[axis] - state.rects.reference[axis];\n var arrowOffsetParent = getOffsetParent(arrowElement);\n var clientSize = arrowOffsetParent ? axis === 'y' ? arrowOffsetParent.clientHeight || 0 : arrowOffsetParent.clientWidth || 0 : 0;\n var centerToReference = endDiff / 2 - startDiff / 2; // Make sure the arrow doesn't overflow the popper if the center point is\n // outside of the popper bounds\n\n var min = paddingObject[minProp];\n var max = clientSize - arrowRect[len] - paddingObject[maxProp];\n var center = clientSize / 2 - arrowRect[len] / 2 + centerToReference;\n var offset = within(min, center, max); // Prevents breaking syntax highlighting...\n\n var axisProp = axis;\n state.modifiersData[name] = (_state$modifiersData$ = {}, _state$modifiersData$[axisProp] = offset, _state$modifiersData$.centerOffset = offset - center, _state$modifiersData$);\n}\n\nfunction effect(_ref2) {\n var state = _ref2.state,\n options = _ref2.options;\n var _options$element = options.element,\n arrowElement = _options$element === void 0 ? '[data-popper-arrow]' : _options$element;\n\n if (arrowElement == null) {\n return;\n } // CSS selector\n\n\n if (typeof arrowElement === 'string') {\n arrowElement = state.elements.popper.querySelector(arrowElement);\n\n if (!arrowElement) {\n return;\n }\n }\n\n if (!contains(state.elements.popper, arrowElement)) {\n return;\n }\n\n state.elements.arrow = arrowElement;\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'arrow',\n enabled: true,\n phase: 'main',\n fn: arrow,\n effect: effect,\n requires: ['popperOffsets'],\n requiresIfExists: ['preventOverflow']\n};","export default function getVariation(placement) {\n return placement.split('-')[1];\n}","import { top, left, right, bottom, end } from \"../enums.js\";\nimport getOffsetParent from \"../dom-utils/getOffsetParent.js\";\nimport getWindow from \"../dom-utils/getWindow.js\";\nimport getDocumentElement from \"../dom-utils/getDocumentElement.js\";\nimport getComputedStyle from \"../dom-utils/getComputedStyle.js\";\nimport getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getVariation from \"../utils/getVariation.js\";\nimport { round } from \"../utils/math.js\"; // eslint-disable-next-line import/no-unused-modules\n\nvar unsetSides = {\n top: 'auto',\n right: 'auto',\n bottom: 'auto',\n left: 'auto'\n}; // Round the offsets to the nearest suitable subpixel based on the DPR.\n// Zooming can change the DPR, but it seems to report a value that will\n// cleanly divide the values into the appropriate subpixels.\n\nfunction roundOffsetsByDPR(_ref, win) {\n var x = _ref.x,\n y = _ref.y;\n var dpr = win.devicePixelRatio || 1;\n return {\n x: round(x * dpr) / dpr || 0,\n y: round(y * dpr) / dpr || 0\n };\n}\n\nexport function mapToStyles(_ref2) {\n var _Object$assign2;\n\n var popper = _ref2.popper,\n popperRect = _ref2.popperRect,\n placement = _ref2.placement,\n variation = _ref2.variation,\n offsets = _ref2.offsets,\n position = _ref2.position,\n gpuAcceleration = _ref2.gpuAcceleration,\n adaptive = _ref2.adaptive,\n roundOffsets = _ref2.roundOffsets,\n isFixed = _ref2.isFixed;\n var _offsets$x = offsets.x,\n x = _offsets$x === void 0 ? 0 : _offsets$x,\n _offsets$y = offsets.y,\n y = _offsets$y === void 0 ? 0 : _offsets$y;\n\n var _ref3 = typeof roundOffsets === 'function' ? roundOffsets({\n x: x,\n y: y\n }) : {\n x: x,\n y: y\n };\n\n x = _ref3.x;\n y = _ref3.y;\n var hasX = offsets.hasOwnProperty('x');\n var hasY = offsets.hasOwnProperty('y');\n var sideX = left;\n var sideY = top;\n var win = window;\n\n if (adaptive) {\n var offsetParent = getOffsetParent(popper);\n var heightProp = 'clientHeight';\n var widthProp = 'clientWidth';\n\n if (offsetParent === getWindow(popper)) {\n offsetParent = getDocumentElement(popper);\n\n if (getComputedStyle(offsetParent).position !== 'static' && position === 'absolute') {\n heightProp = 'scrollHeight';\n widthProp = 'scrollWidth';\n }\n } // $FlowFixMe[incompatible-cast]: force type refinement, we compare offsetParent with window above, but Flow doesn't detect it\n\n\n offsetParent = offsetParent;\n\n if (placement === top || (placement === left || placement === right) && variation === end) {\n sideY = bottom;\n var offsetY = isFixed && offsetParent === win && win.visualViewport ? win.visualViewport.height : // $FlowFixMe[prop-missing]\n offsetParent[heightProp];\n y -= offsetY - popperRect.height;\n y *= gpuAcceleration ? 1 : -1;\n }\n\n if (placement === left || (placement === top || placement === bottom) && variation === end) {\n sideX = right;\n var offsetX = isFixed && offsetParent === win && win.visualViewport ? win.visualViewport.width : // $FlowFixMe[prop-missing]\n offsetParent[widthProp];\n x -= offsetX - popperRect.width;\n x *= gpuAcceleration ? 1 : -1;\n }\n }\n\n var commonStyles = Object.assign({\n position: position\n }, adaptive && unsetSides);\n\n var _ref4 = roundOffsets === true ? roundOffsetsByDPR({\n x: x,\n y: y\n }, getWindow(popper)) : {\n x: x,\n y: y\n };\n\n x = _ref4.x;\n y = _ref4.y;\n\n if (gpuAcceleration) {\n var _Object$assign;\n\n return Object.assign({}, commonStyles, (_Object$assign = {}, _Object$assign[sideY] = hasY ? '0' : '', _Object$assign[sideX] = hasX ? '0' : '', _Object$assign.transform = (win.devicePixelRatio || 1) <= 1 ? \"translate(\" + x + \"px, \" + y + \"px)\" : \"translate3d(\" + x + \"px, \" + y + \"px, 0)\", _Object$assign));\n }\n\n return Object.assign({}, commonStyles, (_Object$assign2 = {}, _Object$assign2[sideY] = hasY ? y + \"px\" : '', _Object$assign2[sideX] = hasX ? x + \"px\" : '', _Object$assign2.transform = '', _Object$assign2));\n}\n\nfunction computeStyles(_ref5) {\n var state = _ref5.state,\n options = _ref5.options;\n var _options$gpuAccelerat = options.gpuAcceleration,\n gpuAcceleration = _options$gpuAccelerat === void 0 ? true : _options$gpuAccelerat,\n _options$adaptive = options.adaptive,\n adaptive = _options$adaptive === void 0 ? true : _options$adaptive,\n _options$roundOffsets = options.roundOffsets,\n roundOffsets = _options$roundOffsets === void 0 ? true : _options$roundOffsets;\n var commonStyles = {\n placement: getBasePlacement(state.placement),\n variation: getVariation(state.placement),\n popper: state.elements.popper,\n popperRect: state.rects.popper,\n gpuAcceleration: gpuAcceleration,\n isFixed: state.options.strategy === 'fixed'\n };\n\n if (state.modifiersData.popperOffsets != null) {\n state.styles.popper = Object.assign({}, state.styles.popper, mapToStyles(Object.assign({}, commonStyles, {\n offsets: state.modifiersData.popperOffsets,\n position: state.options.strategy,\n adaptive: adaptive,\n roundOffsets: roundOffsets\n })));\n }\n\n if (state.modifiersData.arrow != null) {\n state.styles.arrow = Object.assign({}, state.styles.arrow, mapToStyles(Object.assign({}, commonStyles, {\n offsets: state.modifiersData.arrow,\n position: 'absolute',\n adaptive: false,\n roundOffsets: roundOffsets\n })));\n }\n\n state.attributes.popper = Object.assign({}, state.attributes.popper, {\n 'data-popper-placement': state.placement\n });\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'computeStyles',\n enabled: true,\n phase: 'beforeWrite',\n fn: computeStyles,\n data: {}\n};","import getWindow from \"../dom-utils/getWindow.js\"; // eslint-disable-next-line import/no-unused-modules\n\nvar passive = {\n passive: true\n};\n\nfunction effect(_ref) {\n var state = _ref.state,\n instance = _ref.instance,\n options = _ref.options;\n var _options$scroll = options.scroll,\n scroll = _options$scroll === void 0 ? true : _options$scroll,\n _options$resize = options.resize,\n resize = _options$resize === void 0 ? true : _options$resize;\n var window = getWindow(state.elements.popper);\n var scrollParents = [].concat(state.scrollParents.reference, state.scrollParents.popper);\n\n if (scroll) {\n scrollParents.forEach(function (scrollParent) {\n scrollParent.addEventListener('scroll', instance.update, passive);\n });\n }\n\n if (resize) {\n window.addEventListener('resize', instance.update, passive);\n }\n\n return function () {\n if (scroll) {\n scrollParents.forEach(function (scrollParent) {\n scrollParent.removeEventListener('scroll', instance.update, passive);\n });\n }\n\n if (resize) {\n window.removeEventListener('resize', instance.update, passive);\n }\n };\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'eventListeners',\n enabled: true,\n phase: 'write',\n fn: function fn() {},\n effect: effect,\n data: {}\n};","var hash = {\n left: 'right',\n right: 'left',\n bottom: 'top',\n top: 'bottom'\n};\nexport default function getOppositePlacement(placement) {\n return placement.replace(/left|right|bottom|top/g, function (matched) {\n return hash[matched];\n });\n}","var hash = {\n start: 'end',\n end: 'start'\n};\nexport default function getOppositeVariationPlacement(placement) {\n return placement.replace(/start|end/g, function (matched) {\n return hash[matched];\n });\n}","import getWindow from \"./getWindow.js\";\nexport default function getWindowScroll(node) {\n var win = getWindow(node);\n var scrollLeft = win.pageXOffset;\n var scrollTop = win.pageYOffset;\n return {\n scrollLeft: scrollLeft,\n scrollTop: scrollTop\n };\n}","import getBoundingClientRect from \"./getBoundingClientRect.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport getWindowScroll from \"./getWindowScroll.js\";\nexport default function getWindowScrollBarX(element) {\n // If has a CSS width greater than the viewport, then this will be\n // incorrect for RTL.\n // Popper 1 is broken in this case and never had a bug report so let's assume\n // it's not an issue. I don't think anyone ever specifies width on \n // anyway.\n // Browsers where the left scrollbar doesn't cause an issue report `0` for\n // this (e.g. Edge 2019, IE11, Safari)\n return getBoundingClientRect(getDocumentElement(element)).left + getWindowScroll(element).scrollLeft;\n}","import getWindow from \"./getWindow.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport getWindowScrollBarX from \"./getWindowScrollBarX.js\";\nimport isLayoutViewport from \"./isLayoutViewport.js\";\nexport default function getViewportRect(element, strategy) {\n var win = getWindow(element);\n var html = getDocumentElement(element);\n var visualViewport = win.visualViewport;\n var width = html.clientWidth;\n var height = html.clientHeight;\n var x = 0;\n var y = 0;\n\n if (visualViewport) {\n width = visualViewport.width;\n height = visualViewport.height;\n var layoutViewport = isLayoutViewport();\n\n if (layoutViewport || !layoutViewport && strategy === 'fixed') {\n x = visualViewport.offsetLeft;\n y = visualViewport.offsetTop;\n }\n }\n\n return {\n width: width,\n height: height,\n x: x + getWindowScrollBarX(element),\n y: y\n };\n}","import getDocumentElement from \"./getDocumentElement.js\";\nimport getComputedStyle from \"./getComputedStyle.js\";\nimport getWindowScrollBarX from \"./getWindowScrollBarX.js\";\nimport getWindowScroll from \"./getWindowScroll.js\";\nimport { max } from \"../utils/math.js\"; // Gets the entire size of the scrollable document area, even extending outside\n// of the `` and `` rect bounds if horizontally scrollable\n\nexport default function getDocumentRect(element) {\n var _element$ownerDocumen;\n\n var html = getDocumentElement(element);\n var winScroll = getWindowScroll(element);\n var body = (_element$ownerDocumen = element.ownerDocument) == null ? void 0 : _element$ownerDocumen.body;\n var width = max(html.scrollWidth, html.clientWidth, body ? body.scrollWidth : 0, body ? body.clientWidth : 0);\n var height = max(html.scrollHeight, html.clientHeight, body ? body.scrollHeight : 0, body ? body.clientHeight : 0);\n var x = -winScroll.scrollLeft + getWindowScrollBarX(element);\n var y = -winScroll.scrollTop;\n\n if (getComputedStyle(body || html).direction === 'rtl') {\n x += max(html.clientWidth, body ? body.clientWidth : 0) - width;\n }\n\n return {\n width: width,\n height: height,\n x: x,\n y: y\n };\n}","import getComputedStyle from \"./getComputedStyle.js\";\nexport default function isScrollParent(element) {\n // Firefox wants us to check `-x` and `-y` variations as well\n var _getComputedStyle = getComputedStyle(element),\n overflow = _getComputedStyle.overflow,\n overflowX = _getComputedStyle.overflowX,\n overflowY = _getComputedStyle.overflowY;\n\n return /auto|scroll|overlay|hidden/.test(overflow + overflowY + overflowX);\n}","import getParentNode from \"./getParentNode.js\";\nimport isScrollParent from \"./isScrollParent.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport { isHTMLElement } from \"./instanceOf.js\";\nexport default function getScrollParent(node) {\n if (['html', 'body', '#document'].indexOf(getNodeName(node)) >= 0) {\n // $FlowFixMe[incompatible-return]: assume body is always available\n return node.ownerDocument.body;\n }\n\n if (isHTMLElement(node) && isScrollParent(node)) {\n return node;\n }\n\n return getScrollParent(getParentNode(node));\n}","import getScrollParent from \"./getScrollParent.js\";\nimport getParentNode from \"./getParentNode.js\";\nimport getWindow from \"./getWindow.js\";\nimport isScrollParent from \"./isScrollParent.js\";\n/*\ngiven a DOM element, return the list of all scroll parents, up the list of ancesors\nuntil we get to the top window object. This list is what we attach scroll listeners\nto, because if any of these parent elements scroll, we'll need to re-calculate the\nreference element's position.\n*/\n\nexport default function listScrollParents(element, list) {\n var _element$ownerDocumen;\n\n if (list === void 0) {\n list = [];\n }\n\n var scrollParent = getScrollParent(element);\n var isBody = scrollParent === ((_element$ownerDocumen = element.ownerDocument) == null ? void 0 : _element$ownerDocumen.body);\n var win = getWindow(scrollParent);\n var target = isBody ? [win].concat(win.visualViewport || [], isScrollParent(scrollParent) ? scrollParent : []) : scrollParent;\n var updatedList = list.concat(target);\n return isBody ? updatedList : // $FlowFixMe[incompatible-call]: isBody tells us target will be an HTMLElement here\n updatedList.concat(listScrollParents(getParentNode(target)));\n}","export default function rectToClientRect(rect) {\n return Object.assign({}, rect, {\n left: rect.x,\n top: rect.y,\n right: rect.x + rect.width,\n bottom: rect.y + rect.height\n });\n}","import { viewport } from \"../enums.js\";\nimport getViewportRect from \"./getViewportRect.js\";\nimport getDocumentRect from \"./getDocumentRect.js\";\nimport listScrollParents from \"./listScrollParents.js\";\nimport getOffsetParent from \"./getOffsetParent.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport getComputedStyle from \"./getComputedStyle.js\";\nimport { isElement, isHTMLElement } from \"./instanceOf.js\";\nimport getBoundingClientRect from \"./getBoundingClientRect.js\";\nimport getParentNode from \"./getParentNode.js\";\nimport contains from \"./contains.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport rectToClientRect from \"../utils/rectToClientRect.js\";\nimport { max, min } from \"../utils/math.js\";\n\nfunction getInnerBoundingClientRect(element, strategy) {\n var rect = getBoundingClientRect(element, false, strategy === 'fixed');\n rect.top = rect.top + element.clientTop;\n rect.left = rect.left + element.clientLeft;\n rect.bottom = rect.top + element.clientHeight;\n rect.right = rect.left + element.clientWidth;\n rect.width = element.clientWidth;\n rect.height = element.clientHeight;\n rect.x = rect.left;\n rect.y = rect.top;\n return rect;\n}\n\nfunction getClientRectFromMixedType(element, clippingParent, strategy) {\n return clippingParent === viewport ? rectToClientRect(getViewportRect(element, strategy)) : isElement(clippingParent) ? getInnerBoundingClientRect(clippingParent, strategy) : rectToClientRect(getDocumentRect(getDocumentElement(element)));\n} // A \"clipping parent\" is an overflowable container with the characteristic of\n// clipping (or hiding) overflowing elements with a position different from\n// `initial`\n\n\nfunction getClippingParents(element) {\n var clippingParents = listScrollParents(getParentNode(element));\n var canEscapeClipping = ['absolute', 'fixed'].indexOf(getComputedStyle(element).position) >= 0;\n var clipperElement = canEscapeClipping && isHTMLElement(element) ? getOffsetParent(element) : element;\n\n if (!isElement(clipperElement)) {\n return [];\n } // $FlowFixMe[incompatible-return]: https://github.com/facebook/flow/issues/1414\n\n\n return clippingParents.filter(function (clippingParent) {\n return isElement(clippingParent) && contains(clippingParent, clipperElement) && getNodeName(clippingParent) !== 'body';\n });\n} // Gets the maximum area that the element is visible in due to any number of\n// clipping parents\n\n\nexport default function getClippingRect(element, boundary, rootBoundary, strategy) {\n var mainClippingParents = boundary === 'clippingParents' ? getClippingParents(element) : [].concat(boundary);\n var clippingParents = [].concat(mainClippingParents, [rootBoundary]);\n var firstClippingParent = clippingParents[0];\n var clippingRect = clippingParents.reduce(function (accRect, clippingParent) {\n var rect = getClientRectFromMixedType(element, clippingParent, strategy);\n accRect.top = max(rect.top, accRect.top);\n accRect.right = min(rect.right, accRect.right);\n accRect.bottom = min(rect.bottom, accRect.bottom);\n accRect.left = max(rect.left, accRect.left);\n return accRect;\n }, getClientRectFromMixedType(element, firstClippingParent, strategy));\n clippingRect.width = clippingRect.right - clippingRect.left;\n clippingRect.height = clippingRect.bottom - clippingRect.top;\n clippingRect.x = clippingRect.left;\n clippingRect.y = clippingRect.top;\n return clippingRect;\n}","import getBasePlacement from \"./getBasePlacement.js\";\nimport getVariation from \"./getVariation.js\";\nimport getMainAxisFromPlacement from \"./getMainAxisFromPlacement.js\";\nimport { top, right, bottom, left, start, end } from \"../enums.js\";\nexport default function computeOffsets(_ref) {\n var reference = _ref.reference,\n element = _ref.element,\n placement = _ref.placement;\n var basePlacement = placement ? getBasePlacement(placement) : null;\n var variation = placement ? getVariation(placement) : null;\n var commonX = reference.x + reference.width / 2 - element.width / 2;\n var commonY = reference.y + reference.height / 2 - element.height / 2;\n var offsets;\n\n switch (basePlacement) {\n case top:\n offsets = {\n x: commonX,\n y: reference.y - element.height\n };\n break;\n\n case bottom:\n offsets = {\n x: commonX,\n y: reference.y + reference.height\n };\n break;\n\n case right:\n offsets = {\n x: reference.x + reference.width,\n y: commonY\n };\n break;\n\n case left:\n offsets = {\n x: reference.x - element.width,\n y: commonY\n };\n break;\n\n default:\n offsets = {\n x: reference.x,\n y: reference.y\n };\n }\n\n var mainAxis = basePlacement ? getMainAxisFromPlacement(basePlacement) : null;\n\n if (mainAxis != null) {\n var len = mainAxis === 'y' ? 'height' : 'width';\n\n switch (variation) {\n case start:\n offsets[mainAxis] = offsets[mainAxis] - (reference[len] / 2 - element[len] / 2);\n break;\n\n case end:\n offsets[mainAxis] = offsets[mainAxis] + (reference[len] / 2 - element[len] / 2);\n break;\n\n default:\n }\n }\n\n return offsets;\n}","import getClippingRect from \"../dom-utils/getClippingRect.js\";\nimport getDocumentElement from \"../dom-utils/getDocumentElement.js\";\nimport getBoundingClientRect from \"../dom-utils/getBoundingClientRect.js\";\nimport computeOffsets from \"./computeOffsets.js\";\nimport rectToClientRect from \"./rectToClientRect.js\";\nimport { clippingParents, reference, popper, bottom, top, right, basePlacements, viewport } from \"../enums.js\";\nimport { isElement } from \"../dom-utils/instanceOf.js\";\nimport mergePaddingObject from \"./mergePaddingObject.js\";\nimport expandToHashMap from \"./expandToHashMap.js\"; // eslint-disable-next-line import/no-unused-modules\n\nexport default function detectOverflow(state, options) {\n if (options === void 0) {\n options = {};\n }\n\n var _options = options,\n _options$placement = _options.placement,\n placement = _options$placement === void 0 ? state.placement : _options$placement,\n _options$strategy = _options.strategy,\n strategy = _options$strategy === void 0 ? state.strategy : _options$strategy,\n _options$boundary = _options.boundary,\n boundary = _options$boundary === void 0 ? clippingParents : _options$boundary,\n _options$rootBoundary = _options.rootBoundary,\n rootBoundary = _options$rootBoundary === void 0 ? viewport : _options$rootBoundary,\n _options$elementConte = _options.elementContext,\n elementContext = _options$elementConte === void 0 ? popper : _options$elementConte,\n _options$altBoundary = _options.altBoundary,\n altBoundary = _options$altBoundary === void 0 ? false : _options$altBoundary,\n _options$padding = _options.padding,\n padding = _options$padding === void 0 ? 0 : _options$padding;\n var paddingObject = mergePaddingObject(typeof padding !== 'number' ? padding : expandToHashMap(padding, basePlacements));\n var altContext = elementContext === popper ? reference : popper;\n var popperRect = state.rects.popper;\n var element = state.elements[altBoundary ? altContext : elementContext];\n var clippingClientRect = getClippingRect(isElement(element) ? element : element.contextElement || getDocumentElement(state.elements.popper), boundary, rootBoundary, strategy);\n var referenceClientRect = getBoundingClientRect(state.elements.reference);\n var popperOffsets = computeOffsets({\n reference: referenceClientRect,\n element: popperRect,\n strategy: 'absolute',\n placement: placement\n });\n var popperClientRect = rectToClientRect(Object.assign({}, popperRect, popperOffsets));\n var elementClientRect = elementContext === popper ? popperClientRect : referenceClientRect; // positive = overflowing the clipping rect\n // 0 or negative = within the clipping rect\n\n var overflowOffsets = {\n top: clippingClientRect.top - elementClientRect.top + paddingObject.top,\n bottom: elementClientRect.bottom - clippingClientRect.bottom + paddingObject.bottom,\n left: clippingClientRect.left - elementClientRect.left + paddingObject.left,\n right: elementClientRect.right - clippingClientRect.right + paddingObject.right\n };\n var offsetData = state.modifiersData.offset; // Offsets can be applied only to the popper element\n\n if (elementContext === popper && offsetData) {\n var offset = offsetData[placement];\n Object.keys(overflowOffsets).forEach(function (key) {\n var multiply = [right, bottom].indexOf(key) >= 0 ? 1 : -1;\n var axis = [top, bottom].indexOf(key) >= 0 ? 'y' : 'x';\n overflowOffsets[key] += offset[axis] * multiply;\n });\n }\n\n return overflowOffsets;\n}","import getVariation from \"./getVariation.js\";\nimport { variationPlacements, basePlacements, placements as allPlacements } from \"../enums.js\";\nimport detectOverflow from \"./detectOverflow.js\";\nimport getBasePlacement from \"./getBasePlacement.js\";\nexport default function computeAutoPlacement(state, options) {\n if (options === void 0) {\n options = {};\n }\n\n var _options = options,\n placement = _options.placement,\n boundary = _options.boundary,\n rootBoundary = _options.rootBoundary,\n padding = _options.padding,\n flipVariations = _options.flipVariations,\n _options$allowedAutoP = _options.allowedAutoPlacements,\n allowedAutoPlacements = _options$allowedAutoP === void 0 ? allPlacements : _options$allowedAutoP;\n var variation = getVariation(placement);\n var placements = variation ? flipVariations ? variationPlacements : variationPlacements.filter(function (placement) {\n return getVariation(placement) === variation;\n }) : basePlacements;\n var allowedPlacements = placements.filter(function (placement) {\n return allowedAutoPlacements.indexOf(placement) >= 0;\n });\n\n if (allowedPlacements.length === 0) {\n allowedPlacements = placements;\n } // $FlowFixMe[incompatible-type]: Flow seems to have problems with two array unions...\n\n\n var overflows = allowedPlacements.reduce(function (acc, placement) {\n acc[placement] = detectOverflow(state, {\n placement: placement,\n boundary: boundary,\n rootBoundary: rootBoundary,\n padding: padding\n })[getBasePlacement(placement)];\n return acc;\n }, {});\n return Object.keys(overflows).sort(function (a, b) {\n return overflows[a] - overflows[b];\n });\n}","import getOppositePlacement from \"../utils/getOppositePlacement.js\";\nimport getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getOppositeVariationPlacement from \"../utils/getOppositeVariationPlacement.js\";\nimport detectOverflow from \"../utils/detectOverflow.js\";\nimport computeAutoPlacement from \"../utils/computeAutoPlacement.js\";\nimport { bottom, top, start, right, left, auto } from \"../enums.js\";\nimport getVariation from \"../utils/getVariation.js\"; // eslint-disable-next-line import/no-unused-modules\n\nfunction getExpandedFallbackPlacements(placement) {\n if (getBasePlacement(placement) === auto) {\n return [];\n }\n\n var oppositePlacement = getOppositePlacement(placement);\n return [getOppositeVariationPlacement(placement), oppositePlacement, getOppositeVariationPlacement(oppositePlacement)];\n}\n\nfunction flip(_ref) {\n var state = _ref.state,\n options = _ref.options,\n name = _ref.name;\n\n if (state.modifiersData[name]._skip) {\n return;\n }\n\n var _options$mainAxis = options.mainAxis,\n checkMainAxis = _options$mainAxis === void 0 ? true : _options$mainAxis,\n _options$altAxis = options.altAxis,\n checkAltAxis = _options$altAxis === void 0 ? true : _options$altAxis,\n specifiedFallbackPlacements = options.fallbackPlacements,\n padding = options.padding,\n boundary = options.boundary,\n rootBoundary = options.rootBoundary,\n altBoundary = options.altBoundary,\n _options$flipVariatio = options.flipVariations,\n flipVariations = _options$flipVariatio === void 0 ? true : _options$flipVariatio,\n allowedAutoPlacements = options.allowedAutoPlacements;\n var preferredPlacement = state.options.placement;\n var basePlacement = getBasePlacement(preferredPlacement);\n var isBasePlacement = basePlacement === preferredPlacement;\n var fallbackPlacements = specifiedFallbackPlacements || (isBasePlacement || !flipVariations ? [getOppositePlacement(preferredPlacement)] : getExpandedFallbackPlacements(preferredPlacement));\n var placements = [preferredPlacement].concat(fallbackPlacements).reduce(function (acc, placement) {\n return acc.concat(getBasePlacement(placement) === auto ? computeAutoPlacement(state, {\n placement: placement,\n boundary: boundary,\n rootBoundary: rootBoundary,\n padding: padding,\n flipVariations: flipVariations,\n allowedAutoPlacements: allowedAutoPlacements\n }) : placement);\n }, []);\n var referenceRect = state.rects.reference;\n var popperRect = state.rects.popper;\n var checksMap = new Map();\n var makeFallbackChecks = true;\n var firstFittingPlacement = placements[0];\n\n for (var i = 0; i < placements.length; i++) {\n var placement = placements[i];\n\n var _basePlacement = getBasePlacement(placement);\n\n var isStartVariation = getVariation(placement) === start;\n var isVertical = [top, bottom].indexOf(_basePlacement) >= 0;\n var len = isVertical ? 'width' : 'height';\n var overflow = detectOverflow(state, {\n placement: placement,\n boundary: boundary,\n rootBoundary: rootBoundary,\n altBoundary: altBoundary,\n padding: padding\n });\n var mainVariationSide = isVertical ? isStartVariation ? right : left : isStartVariation ? bottom : top;\n\n if (referenceRect[len] > popperRect[len]) {\n mainVariationSide = getOppositePlacement(mainVariationSide);\n }\n\n var altVariationSide = getOppositePlacement(mainVariationSide);\n var checks = [];\n\n if (checkMainAxis) {\n checks.push(overflow[_basePlacement] <= 0);\n }\n\n if (checkAltAxis) {\n checks.push(overflow[mainVariationSide] <= 0, overflow[altVariationSide] <= 0);\n }\n\n if (checks.every(function (check) {\n return check;\n })) {\n firstFittingPlacement = placement;\n makeFallbackChecks = false;\n break;\n }\n\n checksMap.set(placement, checks);\n }\n\n if (makeFallbackChecks) {\n // `2` may be desired in some cases – research later\n var numberOfChecks = flipVariations ? 3 : 1;\n\n var _loop = function _loop(_i) {\n var fittingPlacement = placements.find(function (placement) {\n var checks = checksMap.get(placement);\n\n if (checks) {\n return checks.slice(0, _i).every(function (check) {\n return check;\n });\n }\n });\n\n if (fittingPlacement) {\n firstFittingPlacement = fittingPlacement;\n return \"break\";\n }\n };\n\n for (var _i = numberOfChecks; _i > 0; _i--) {\n var _ret = _loop(_i);\n\n if (_ret === \"break\") break;\n }\n }\n\n if (state.placement !== firstFittingPlacement) {\n state.modifiersData[name]._skip = true;\n state.placement = firstFittingPlacement;\n state.reset = true;\n }\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'flip',\n enabled: true,\n phase: 'main',\n fn: flip,\n requiresIfExists: ['offset'],\n data: {\n _skip: false\n }\n};","import { top, bottom, left, right } from \"../enums.js\";\nimport detectOverflow from \"../utils/detectOverflow.js\";\n\nfunction getSideOffsets(overflow, rect, preventedOffsets) {\n if (preventedOffsets === void 0) {\n preventedOffsets = {\n x: 0,\n y: 0\n };\n }\n\n return {\n top: overflow.top - rect.height - preventedOffsets.y,\n right: overflow.right - rect.width + preventedOffsets.x,\n bottom: overflow.bottom - rect.height + preventedOffsets.y,\n left: overflow.left - rect.width - preventedOffsets.x\n };\n}\n\nfunction isAnySideFullyClipped(overflow) {\n return [top, right, bottom, left].some(function (side) {\n return overflow[side] >= 0;\n });\n}\n\nfunction hide(_ref) {\n var state = _ref.state,\n name = _ref.name;\n var referenceRect = state.rects.reference;\n var popperRect = state.rects.popper;\n var preventedOffsets = state.modifiersData.preventOverflow;\n var referenceOverflow = detectOverflow(state, {\n elementContext: 'reference'\n });\n var popperAltOverflow = detectOverflow(state, {\n altBoundary: true\n });\n var referenceClippingOffsets = getSideOffsets(referenceOverflow, referenceRect);\n var popperEscapeOffsets = getSideOffsets(popperAltOverflow, popperRect, preventedOffsets);\n var isReferenceHidden = isAnySideFullyClipped(referenceClippingOffsets);\n var hasPopperEscaped = isAnySideFullyClipped(popperEscapeOffsets);\n state.modifiersData[name] = {\n referenceClippingOffsets: referenceClippingOffsets,\n popperEscapeOffsets: popperEscapeOffsets,\n isReferenceHidden: isReferenceHidden,\n hasPopperEscaped: hasPopperEscaped\n };\n state.attributes.popper = Object.assign({}, state.attributes.popper, {\n 'data-popper-reference-hidden': isReferenceHidden,\n 'data-popper-escaped': hasPopperEscaped\n });\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'hide',\n enabled: true,\n phase: 'main',\n requiresIfExists: ['preventOverflow'],\n fn: hide\n};","import getBasePlacement from \"../utils/getBasePlacement.js\";\nimport { top, left, right, placements } from \"../enums.js\"; // eslint-disable-next-line import/no-unused-modules\n\nexport function distanceAndSkiddingToXY(placement, rects, offset) {\n var basePlacement = getBasePlacement(placement);\n var invertDistance = [left, top].indexOf(basePlacement) >= 0 ? -1 : 1;\n\n var _ref = typeof offset === 'function' ? offset(Object.assign({}, rects, {\n placement: placement\n })) : offset,\n skidding = _ref[0],\n distance = _ref[1];\n\n skidding = skidding || 0;\n distance = (distance || 0) * invertDistance;\n return [left, right].indexOf(basePlacement) >= 0 ? {\n x: distance,\n y: skidding\n } : {\n x: skidding,\n y: distance\n };\n}\n\nfunction offset(_ref2) {\n var state = _ref2.state,\n options = _ref2.options,\n name = _ref2.name;\n var _options$offset = options.offset,\n offset = _options$offset === void 0 ? [0, 0] : _options$offset;\n var data = placements.reduce(function (acc, placement) {\n acc[placement] = distanceAndSkiddingToXY(placement, state.rects, offset);\n return acc;\n }, {});\n var _data$state$placement = data[state.placement],\n x = _data$state$placement.x,\n y = _data$state$placement.y;\n\n if (state.modifiersData.popperOffsets != null) {\n state.modifiersData.popperOffsets.x += x;\n state.modifiersData.popperOffsets.y += y;\n }\n\n state.modifiersData[name] = data;\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'offset',\n enabled: true,\n phase: 'main',\n requires: ['popperOffsets'],\n fn: offset\n};","import computeOffsets from \"../utils/computeOffsets.js\";\n\nfunction popperOffsets(_ref) {\n var state = _ref.state,\n name = _ref.name;\n // Offsets are the actual position the popper needs to have to be\n // properly positioned near its reference element\n // This is the most basic placement, and will be adjusted by\n // the modifiers in the next step\n state.modifiersData[name] = computeOffsets({\n reference: state.rects.reference,\n element: state.rects.popper,\n strategy: 'absolute',\n placement: state.placement\n });\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'popperOffsets',\n enabled: true,\n phase: 'read',\n fn: popperOffsets,\n data: {}\n};","export default function getAltAxis(axis) {\n return axis === 'x' ? 'y' : 'x';\n}","import { top, left, right, bottom, start } from \"../enums.js\";\nimport getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getMainAxisFromPlacement from \"../utils/getMainAxisFromPlacement.js\";\nimport getAltAxis from \"../utils/getAltAxis.js\";\nimport { within, withinMaxClamp } from \"../utils/within.js\";\nimport getLayoutRect from \"../dom-utils/getLayoutRect.js\";\nimport getOffsetParent from \"../dom-utils/getOffsetParent.js\";\nimport detectOverflow from \"../utils/detectOverflow.js\";\nimport getVariation from \"../utils/getVariation.js\";\nimport getFreshSideObject from \"../utils/getFreshSideObject.js\";\nimport { min as mathMin, max as mathMax } from \"../utils/math.js\";\n\nfunction preventOverflow(_ref) {\n var state = _ref.state,\n options = _ref.options,\n name = _ref.name;\n var _options$mainAxis = options.mainAxis,\n checkMainAxis = _options$mainAxis === void 0 ? true : _options$mainAxis,\n _options$altAxis = options.altAxis,\n checkAltAxis = _options$altAxis === void 0 ? false : _options$altAxis,\n boundary = options.boundary,\n rootBoundary = options.rootBoundary,\n altBoundary = options.altBoundary,\n padding = options.padding,\n _options$tether = options.tether,\n tether = _options$tether === void 0 ? true : _options$tether,\n _options$tetherOffset = options.tetherOffset,\n tetherOffset = _options$tetherOffset === void 0 ? 0 : _options$tetherOffset;\n var overflow = detectOverflow(state, {\n boundary: boundary,\n rootBoundary: rootBoundary,\n padding: padding,\n altBoundary: altBoundary\n });\n var basePlacement = getBasePlacement(state.placement);\n var variation = getVariation(state.placement);\n var isBasePlacement = !variation;\n var mainAxis = getMainAxisFromPlacement(basePlacement);\n var altAxis = getAltAxis(mainAxis);\n var popperOffsets = state.modifiersData.popperOffsets;\n var referenceRect = state.rects.reference;\n var popperRect = state.rects.popper;\n var tetherOffsetValue = typeof tetherOffset === 'function' ? tetherOffset(Object.assign({}, state.rects, {\n placement: state.placement\n })) : tetherOffset;\n var normalizedTetherOffsetValue = typeof tetherOffsetValue === 'number' ? {\n mainAxis: tetherOffsetValue,\n altAxis: tetherOffsetValue\n } : Object.assign({\n mainAxis: 0,\n altAxis: 0\n }, tetherOffsetValue);\n var offsetModifierState = state.modifiersData.offset ? state.modifiersData.offset[state.placement] : null;\n var data = {\n x: 0,\n y: 0\n };\n\n if (!popperOffsets) {\n return;\n }\n\n if (checkMainAxis) {\n var _offsetModifierState$;\n\n var mainSide = mainAxis === 'y' ? top : left;\n var altSide = mainAxis === 'y' ? bottom : right;\n var len = mainAxis === 'y' ? 'height' : 'width';\n var offset = popperOffsets[mainAxis];\n var min = offset + overflow[mainSide];\n var max = offset - overflow[altSide];\n var additive = tether ? -popperRect[len] / 2 : 0;\n var minLen = variation === start ? referenceRect[len] : popperRect[len];\n var maxLen = variation === start ? -popperRect[len] : -referenceRect[len]; // We need to include the arrow in the calculation so the arrow doesn't go\n // outside the reference bounds\n\n var arrowElement = state.elements.arrow;\n var arrowRect = tether && arrowElement ? getLayoutRect(arrowElement) : {\n width: 0,\n height: 0\n };\n var arrowPaddingObject = state.modifiersData['arrow#persistent'] ? state.modifiersData['arrow#persistent'].padding : getFreshSideObject();\n var arrowPaddingMin = arrowPaddingObject[mainSide];\n var arrowPaddingMax = arrowPaddingObject[altSide]; // If the reference length is smaller than the arrow length, we don't want\n // to include its full size in the calculation. If the reference is small\n // and near the edge of a boundary, the popper can overflow even if the\n // reference is not overflowing as well (e.g. virtual elements with no\n // width or height)\n\n var arrowLen = within(0, referenceRect[len], arrowRect[len]);\n var minOffset = isBasePlacement ? referenceRect[len] / 2 - additive - arrowLen - arrowPaddingMin - normalizedTetherOffsetValue.mainAxis : minLen - arrowLen - arrowPaddingMin - normalizedTetherOffsetValue.mainAxis;\n var maxOffset = isBasePlacement ? -referenceRect[len] / 2 + additive + arrowLen + arrowPaddingMax + normalizedTetherOffsetValue.mainAxis : maxLen + arrowLen + arrowPaddingMax + normalizedTetherOffsetValue.mainAxis;\n var arrowOffsetParent = state.elements.arrow && getOffsetParent(state.elements.arrow);\n var clientOffset = arrowOffsetParent ? mainAxis === 'y' ? arrowOffsetParent.clientTop || 0 : arrowOffsetParent.clientLeft || 0 : 0;\n var offsetModifierValue = (_offsetModifierState$ = offsetModifierState == null ? void 0 : offsetModifierState[mainAxis]) != null ? _offsetModifierState$ : 0;\n var tetherMin = offset + minOffset - offsetModifierValue - clientOffset;\n var tetherMax = offset + maxOffset - offsetModifierValue;\n var preventedOffset = within(tether ? mathMin(min, tetherMin) : min, offset, tether ? mathMax(max, tetherMax) : max);\n popperOffsets[mainAxis] = preventedOffset;\n data[mainAxis] = preventedOffset - offset;\n }\n\n if (checkAltAxis) {\n var _offsetModifierState$2;\n\n var _mainSide = mainAxis === 'x' ? top : left;\n\n var _altSide = mainAxis === 'x' ? bottom : right;\n\n var _offset = popperOffsets[altAxis];\n\n var _len = altAxis === 'y' ? 'height' : 'width';\n\n var _min = _offset + overflow[_mainSide];\n\n var _max = _offset - overflow[_altSide];\n\n var isOriginSide = [top, left].indexOf(basePlacement) !== -1;\n\n var _offsetModifierValue = (_offsetModifierState$2 = offsetModifierState == null ? void 0 : offsetModifierState[altAxis]) != null ? _offsetModifierState$2 : 0;\n\n var _tetherMin = isOriginSide ? _min : _offset - referenceRect[_len] - popperRect[_len] - _offsetModifierValue + normalizedTetherOffsetValue.altAxis;\n\n var _tetherMax = isOriginSide ? _offset + referenceRect[_len] + popperRect[_len] - _offsetModifierValue - normalizedTetherOffsetValue.altAxis : _max;\n\n var _preventedOffset = tether && isOriginSide ? withinMaxClamp(_tetherMin, _offset, _tetherMax) : within(tether ? _tetherMin : _min, _offset, tether ? _tetherMax : _max);\n\n popperOffsets[altAxis] = _preventedOffset;\n data[altAxis] = _preventedOffset - _offset;\n }\n\n state.modifiersData[name] = data;\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'preventOverflow',\n enabled: true,\n phase: 'main',\n fn: preventOverflow,\n requiresIfExists: ['offset']\n};","export default function getHTMLElementScroll(element) {\n return {\n scrollLeft: element.scrollLeft,\n scrollTop: element.scrollTop\n };\n}","import getWindowScroll from \"./getWindowScroll.js\";\nimport getWindow from \"./getWindow.js\";\nimport { isHTMLElement } from \"./instanceOf.js\";\nimport getHTMLElementScroll from \"./getHTMLElementScroll.js\";\nexport default function getNodeScroll(node) {\n if (node === getWindow(node) || !isHTMLElement(node)) {\n return getWindowScroll(node);\n } else {\n return getHTMLElementScroll(node);\n }\n}","import getBoundingClientRect from \"./getBoundingClientRect.js\";\nimport getNodeScroll from \"./getNodeScroll.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport { isHTMLElement } from \"./instanceOf.js\";\nimport getWindowScrollBarX from \"./getWindowScrollBarX.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport isScrollParent from \"./isScrollParent.js\";\nimport { round } from \"../utils/math.js\";\n\nfunction isElementScaled(element) {\n var rect = element.getBoundingClientRect();\n var scaleX = round(rect.width) / element.offsetWidth || 1;\n var scaleY = round(rect.height) / element.offsetHeight || 1;\n return scaleX !== 1 || scaleY !== 1;\n} // Returns the composite rect of an element relative to its offsetParent.\n// Composite means it takes into account transforms as well as layout.\n\n\nexport default function getCompositeRect(elementOrVirtualElement, offsetParent, isFixed) {\n if (isFixed === void 0) {\n isFixed = false;\n }\n\n var isOffsetParentAnElement = isHTMLElement(offsetParent);\n var offsetParentIsScaled = isHTMLElement(offsetParent) && isElementScaled(offsetParent);\n var documentElement = getDocumentElement(offsetParent);\n var rect = getBoundingClientRect(elementOrVirtualElement, offsetParentIsScaled, isFixed);\n var scroll = {\n scrollLeft: 0,\n scrollTop: 0\n };\n var offsets = {\n x: 0,\n y: 0\n };\n\n if (isOffsetParentAnElement || !isOffsetParentAnElement && !isFixed) {\n if (getNodeName(offsetParent) !== 'body' || // https://github.com/popperjs/popper-core/issues/1078\n isScrollParent(documentElement)) {\n scroll = getNodeScroll(offsetParent);\n }\n\n if (isHTMLElement(offsetParent)) {\n offsets = getBoundingClientRect(offsetParent, true);\n offsets.x += offsetParent.clientLeft;\n offsets.y += offsetParent.clientTop;\n } else if (documentElement) {\n offsets.x = getWindowScrollBarX(documentElement);\n }\n }\n\n return {\n x: rect.left + scroll.scrollLeft - offsets.x,\n y: rect.top + scroll.scrollTop - offsets.y,\n width: rect.width,\n height: rect.height\n };\n}","import { modifierPhases } from \"../enums.js\"; // source: https://stackoverflow.com/questions/49875255\n\nfunction order(modifiers) {\n var map = new Map();\n var visited = new Set();\n var result = [];\n modifiers.forEach(function (modifier) {\n map.set(modifier.name, modifier);\n }); // On visiting object, check for its dependencies and visit them recursively\n\n function sort(modifier) {\n visited.add(modifier.name);\n var requires = [].concat(modifier.requires || [], modifier.requiresIfExists || []);\n requires.forEach(function (dep) {\n if (!visited.has(dep)) {\n var depModifier = map.get(dep);\n\n if (depModifier) {\n sort(depModifier);\n }\n }\n });\n result.push(modifier);\n }\n\n modifiers.forEach(function (modifier) {\n if (!visited.has(modifier.name)) {\n // check for visited object\n sort(modifier);\n }\n });\n return result;\n}\n\nexport default function orderModifiers(modifiers) {\n // order based on dependencies\n var orderedModifiers = order(modifiers); // order based on phase\n\n return modifierPhases.reduce(function (acc, phase) {\n return acc.concat(orderedModifiers.filter(function (modifier) {\n return modifier.phase === phase;\n }));\n }, []);\n}","export default function debounce(fn) {\n var pending;\n return function () {\n if (!pending) {\n pending = new Promise(function (resolve) {\n Promise.resolve().then(function () {\n pending = undefined;\n resolve(fn());\n });\n });\n }\n\n return pending;\n };\n}","export default function mergeByName(modifiers) {\n var merged = modifiers.reduce(function (merged, current) {\n var existing = merged[current.name];\n merged[current.name] = existing ? Object.assign({}, existing, current, {\n options: Object.assign({}, existing.options, current.options),\n data: Object.assign({}, existing.data, current.data)\n }) : current;\n return merged;\n }, {}); // IE11 does not support Object.values\n\n return Object.keys(merged).map(function (key) {\n return merged[key];\n });\n}","import getCompositeRect from \"./dom-utils/getCompositeRect.js\";\nimport getLayoutRect from \"./dom-utils/getLayoutRect.js\";\nimport listScrollParents from \"./dom-utils/listScrollParents.js\";\nimport getOffsetParent from \"./dom-utils/getOffsetParent.js\";\nimport orderModifiers from \"./utils/orderModifiers.js\";\nimport debounce from \"./utils/debounce.js\";\nimport mergeByName from \"./utils/mergeByName.js\";\nimport detectOverflow from \"./utils/detectOverflow.js\";\nimport { isElement } from \"./dom-utils/instanceOf.js\";\nvar DEFAULT_OPTIONS = {\n placement: 'bottom',\n modifiers: [],\n strategy: 'absolute'\n};\n\nfunction areValidElements() {\n for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {\n args[_key] = arguments[_key];\n }\n\n return !args.some(function (element) {\n return !(element && typeof element.getBoundingClientRect === 'function');\n });\n}\n\nexport function popperGenerator(generatorOptions) {\n if (generatorOptions === void 0) {\n generatorOptions = {};\n }\n\n var _generatorOptions = generatorOptions,\n _generatorOptions$def = _generatorOptions.defaultModifiers,\n defaultModifiers = _generatorOptions$def === void 0 ? [] : _generatorOptions$def,\n _generatorOptions$def2 = _generatorOptions.defaultOptions,\n defaultOptions = _generatorOptions$def2 === void 0 ? DEFAULT_OPTIONS : _generatorOptions$def2;\n return function createPopper(reference, popper, options) {\n if (options === void 0) {\n options = defaultOptions;\n }\n\n var state = {\n placement: 'bottom',\n orderedModifiers: [],\n options: Object.assign({}, DEFAULT_OPTIONS, defaultOptions),\n modifiersData: {},\n elements: {\n reference: reference,\n popper: popper\n },\n attributes: {},\n styles: {}\n };\n var effectCleanupFns = [];\n var isDestroyed = false;\n var instance = {\n state: state,\n setOptions: function setOptions(setOptionsAction) {\n var options = typeof setOptionsAction === 'function' ? setOptionsAction(state.options) : setOptionsAction;\n cleanupModifierEffects();\n state.options = Object.assign({}, defaultOptions, state.options, options);\n state.scrollParents = {\n reference: isElement(reference) ? listScrollParents(reference) : reference.contextElement ? listScrollParents(reference.contextElement) : [],\n popper: listScrollParents(popper)\n }; // Orders the modifiers based on their dependencies and `phase`\n // properties\n\n var orderedModifiers = orderModifiers(mergeByName([].concat(defaultModifiers, state.options.modifiers))); // Strip out disabled modifiers\n\n state.orderedModifiers = orderedModifiers.filter(function (m) {\n return m.enabled;\n });\n runModifierEffects();\n return instance.update();\n },\n // Sync update – it will always be executed, even if not necessary. This\n // is useful for low frequency updates where sync behavior simplifies the\n // logic.\n // For high frequency updates (e.g. `resize` and `scroll` events), always\n // prefer the async Popper#update method\n forceUpdate: function forceUpdate() {\n if (isDestroyed) {\n return;\n }\n\n var _state$elements = state.elements,\n reference = _state$elements.reference,\n popper = _state$elements.popper; // Don't proceed if `reference` or `popper` are not valid elements\n // anymore\n\n if (!areValidElements(reference, popper)) {\n return;\n } // Store the reference and popper rects to be read by modifiers\n\n\n state.rects = {\n reference: getCompositeRect(reference, getOffsetParent(popper), state.options.strategy === 'fixed'),\n popper: getLayoutRect(popper)\n }; // Modifiers have the ability to reset the current update cycle. The\n // most common use case for this is the `flip` modifier changing the\n // placement, which then needs to re-run all the modifiers, because the\n // logic was previously ran for the previous placement and is therefore\n // stale/incorrect\n\n state.reset = false;\n state.placement = state.options.placement; // On each update cycle, the `modifiersData` property for each modifier\n // is filled with the initial data specified by the modifier. This means\n // it doesn't persist and is fresh on each update.\n // To ensure persistent data, use `${name}#persistent`\n\n state.orderedModifiers.forEach(function (modifier) {\n return state.modifiersData[modifier.name] = Object.assign({}, modifier.data);\n });\n\n for (var index = 0; index < state.orderedModifiers.length; index++) {\n if (state.reset === true) {\n state.reset = false;\n index = -1;\n continue;\n }\n\n var _state$orderedModifie = state.orderedModifiers[index],\n fn = _state$orderedModifie.fn,\n _state$orderedModifie2 = _state$orderedModifie.options,\n _options = _state$orderedModifie2 === void 0 ? {} : _state$orderedModifie2,\n name = _state$orderedModifie.name;\n\n if (typeof fn === 'function') {\n state = fn({\n state: state,\n options: _options,\n name: name,\n instance: instance\n }) || state;\n }\n }\n },\n // Async and optimistically optimized update – it will not be executed if\n // not necessary (debounced to run at most once-per-tick)\n update: debounce(function () {\n return new Promise(function (resolve) {\n instance.forceUpdate();\n resolve(state);\n });\n }),\n destroy: function destroy() {\n cleanupModifierEffects();\n isDestroyed = true;\n }\n };\n\n if (!areValidElements(reference, popper)) {\n return instance;\n }\n\n instance.setOptions(options).then(function (state) {\n if (!isDestroyed && options.onFirstUpdate) {\n options.onFirstUpdate(state);\n }\n }); // Modifiers have the ability to execute arbitrary code before the first\n // update cycle runs. They will be executed in the same order as the update\n // cycle. This is useful when a modifier adds some persistent data that\n // other modifiers need to use, but the modifier is run after the dependent\n // one.\n\n function runModifierEffects() {\n state.orderedModifiers.forEach(function (_ref) {\n var name = _ref.name,\n _ref$options = _ref.options,\n options = _ref$options === void 0 ? {} : _ref$options,\n effect = _ref.effect;\n\n if (typeof effect === 'function') {\n var cleanupFn = effect({\n state: state,\n name: name,\n instance: instance,\n options: options\n });\n\n var noopFn = function noopFn() {};\n\n effectCleanupFns.push(cleanupFn || noopFn);\n }\n });\n }\n\n function cleanupModifierEffects() {\n effectCleanupFns.forEach(function (fn) {\n return fn();\n });\n effectCleanupFns = [];\n }\n\n return instance;\n };\n}\nexport var createPopper = /*#__PURE__*/popperGenerator(); // eslint-disable-next-line import/no-unused-modules\n\nexport { detectOverflow };","import { popperGenerator, detectOverflow } from \"./createPopper.js\";\nimport eventListeners from \"./modifiers/eventListeners.js\";\nimport popperOffsets from \"./modifiers/popperOffsets.js\";\nimport computeStyles from \"./modifiers/computeStyles.js\";\nimport applyStyles from \"./modifiers/applyStyles.js\";\nimport offset from \"./modifiers/offset.js\";\nimport flip from \"./modifiers/flip.js\";\nimport preventOverflow from \"./modifiers/preventOverflow.js\";\nimport arrow from \"./modifiers/arrow.js\";\nimport hide from \"./modifiers/hide.js\";\nvar defaultModifiers = [eventListeners, popperOffsets, computeStyles, applyStyles, offset, flip, preventOverflow, arrow, hide];\nvar createPopper = /*#__PURE__*/popperGenerator({\n defaultModifiers: defaultModifiers\n}); // eslint-disable-next-line import/no-unused-modules\n\nexport { createPopper, popperGenerator, defaultModifiers, detectOverflow }; // eslint-disable-next-line import/no-unused-modules\n\nexport { createPopper as createPopperLite } from \"./popper-lite.js\"; // eslint-disable-next-line import/no-unused-modules\n\nexport * from \"./modifiers/index.js\";","import { generateUtilityClass } from '../generateUtilityClass';\nimport { generateUtilityClasses } from '../generateUtilityClasses';\nconst COMPONENT_NAME = 'Popper';\nexport function getPopperUtilityClass(slot) {\n return generateUtilityClass(COMPONENT_NAME, slot);\n}\nexport const popperClasses = generateUtilityClasses(COMPONENT_NAME, ['root']);","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"anchorEl\", \"children\", \"direction\", \"disablePortal\", \"modifiers\", \"open\", \"placement\", \"popperOptions\", \"popperRef\", \"slotProps\", \"slots\", \"TransitionProps\", \"ownerState\"],\n _excluded2 = [\"anchorEl\", \"children\", \"container\", \"direction\", \"disablePortal\", \"keepMounted\", \"modifiers\", \"open\", \"placement\", \"popperOptions\", \"popperRef\", \"style\", \"transition\", \"slotProps\", \"slots\"];\nimport * as React from 'react';\nimport { chainPropTypes, HTMLElementType, refType, unstable_ownerDocument as ownerDocument, unstable_useEnhancedEffect as useEnhancedEffect, unstable_useForkRef as useForkRef } from '@mui/utils';\nimport { createPopper } from '@popperjs/core';\nimport PropTypes from 'prop-types';\nimport { unstable_composeClasses as composeClasses } from '../composeClasses';\nimport { Portal } from '../Portal';\nimport { getPopperUtilityClass } from './popperClasses';\nimport { useSlotProps } from '../utils';\nimport { useClassNamesOverride } from '../utils/ClassNameConfigurator';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nfunction flipPlacement(placement, direction) {\n if (direction === 'ltr') {\n return placement;\n }\n switch (placement) {\n case 'bottom-end':\n return 'bottom-start';\n case 'bottom-start':\n return 'bottom-end';\n case 'top-end':\n return 'top-start';\n case 'top-start':\n return 'top-end';\n default:\n return placement;\n }\n}\nfunction resolveAnchorEl(anchorEl) {\n return typeof anchorEl === 'function' ? anchorEl() : anchorEl;\n}\nfunction isHTMLElement(element) {\n return element.nodeType !== undefined;\n}\nfunction isVirtualElement(element) {\n return !isHTMLElement(element);\n}\nconst useUtilityClasses = () => {\n const slots = {\n root: ['root']\n };\n return composeClasses(slots, useClassNamesOverride(getPopperUtilityClass));\n};\nconst defaultPopperOptions = {};\nconst PopperTooltip = /*#__PURE__*/React.forwardRef(function PopperTooltip(props, forwardedRef) {\n var _slots$root;\n const {\n anchorEl,\n children,\n direction,\n disablePortal,\n modifiers,\n open,\n placement: initialPlacement,\n popperOptions,\n popperRef: popperRefProp,\n slotProps = {},\n slots = {},\n TransitionProps\n // @ts-ignore internal logic\n // prevent from spreading to DOM, it can come from the parent component e.g. Select.\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const tooltipRef = React.useRef(null);\n const ownRef = useForkRef(tooltipRef, forwardedRef);\n const popperRef = React.useRef(null);\n const handlePopperRef = useForkRef(popperRef, popperRefProp);\n const handlePopperRefRef = React.useRef(handlePopperRef);\n useEnhancedEffect(() => {\n handlePopperRefRef.current = handlePopperRef;\n }, [handlePopperRef]);\n React.useImperativeHandle(popperRefProp, () => popperRef.current, []);\n const rtlPlacement = flipPlacement(initialPlacement, direction);\n /**\n * placement initialized from prop but can change during lifetime if modifiers.flip.\n * modifiers.flip is essentially a flip for controlled/uncontrolled behavior\n */\n const [placement, setPlacement] = React.useState(rtlPlacement);\n const [resolvedAnchorElement, setResolvedAnchorElement] = React.useState(resolveAnchorEl(anchorEl));\n React.useEffect(() => {\n if (popperRef.current) {\n popperRef.current.forceUpdate();\n }\n });\n React.useEffect(() => {\n if (anchorEl) {\n setResolvedAnchorElement(resolveAnchorEl(anchorEl));\n }\n }, [anchorEl]);\n useEnhancedEffect(() => {\n if (!resolvedAnchorElement || !open) {\n return undefined;\n }\n const handlePopperUpdate = data => {\n setPlacement(data.placement);\n };\n if (process.env.NODE_ENV !== 'production') {\n if (resolvedAnchorElement && isHTMLElement(resolvedAnchorElement) && resolvedAnchorElement.nodeType === 1) {\n const box = resolvedAnchorElement.getBoundingClientRect();\n if (process.env.NODE_ENV !== 'test' && box.top === 0 && box.left === 0 && box.right === 0 && box.bottom === 0) {\n console.warn(['MUI: The `anchorEl` prop provided to the component is invalid.', 'The anchor element should be part of the document layout.', \"Make sure the element is present in the document or that it's not display none.\"].join('\\n'));\n }\n }\n }\n let popperModifiers = [{\n name: 'preventOverflow',\n options: {\n altBoundary: disablePortal\n }\n }, {\n name: 'flip',\n options: {\n altBoundary: disablePortal\n }\n }, {\n name: 'onUpdate',\n enabled: true,\n phase: 'afterWrite',\n fn: ({\n state\n }) => {\n handlePopperUpdate(state);\n }\n }];\n if (modifiers != null) {\n popperModifiers = popperModifiers.concat(modifiers);\n }\n if (popperOptions && popperOptions.modifiers != null) {\n popperModifiers = popperModifiers.concat(popperOptions.modifiers);\n }\n const popper = createPopper(resolvedAnchorElement, tooltipRef.current, _extends({\n placement: rtlPlacement\n }, popperOptions, {\n modifiers: popperModifiers\n }));\n handlePopperRefRef.current(popper);\n return () => {\n popper.destroy();\n handlePopperRefRef.current(null);\n };\n }, [resolvedAnchorElement, disablePortal, modifiers, open, popperOptions, rtlPlacement]);\n const childProps = {\n placement: placement\n };\n if (TransitionProps !== null) {\n childProps.TransitionProps = TransitionProps;\n }\n const classes = useUtilityClasses();\n const Root = (_slots$root = slots.root) != null ? _slots$root : 'div';\n const rootProps = useSlotProps({\n elementType: Root,\n externalSlotProps: slotProps.root,\n externalForwardedProps: other,\n additionalProps: {\n role: 'tooltip',\n ref: ownRef\n },\n ownerState: props,\n className: classes.root\n });\n return /*#__PURE__*/_jsx(Root, _extends({}, rootProps, {\n children: typeof children === 'function' ? children(childProps) : children\n }));\n});\n\n/**\n * Poppers rely on the 3rd party library [Popper.js](https://popper.js.org/docs/v2/) for positioning.\n *\n * Demos:\n *\n * - [Popper](https://mui.com/base-ui/react-popper/)\n *\n * API:\n *\n * - [Popper API](https://mui.com/base-ui/react-popper/components-api/#popper)\n */\nconst Popper = /*#__PURE__*/React.forwardRef(function Popper(props, forwardedRef) {\n const {\n anchorEl,\n children,\n container: containerProp,\n direction = 'ltr',\n disablePortal = false,\n keepMounted = false,\n modifiers,\n open,\n placement = 'bottom',\n popperOptions = defaultPopperOptions,\n popperRef,\n style,\n transition = false,\n slotProps = {},\n slots = {}\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded2);\n const [exited, setExited] = React.useState(true);\n const handleEnter = () => {\n setExited(false);\n };\n const handleExited = () => {\n setExited(true);\n };\n if (!keepMounted && !open && (!transition || exited)) {\n return null;\n }\n\n // If the container prop is provided, use that\n // If the anchorEl prop is provided, use its parent body element as the container\n // If neither are provided let the Modal take care of choosing the container\n let container;\n if (containerProp) {\n container = containerProp;\n } else if (anchorEl) {\n const resolvedAnchorEl = resolveAnchorEl(anchorEl);\n container = resolvedAnchorEl && isHTMLElement(resolvedAnchorEl) ? ownerDocument(resolvedAnchorEl).body : ownerDocument(null).body;\n }\n const display = !open && keepMounted && (!transition || exited) ? 'none' : undefined;\n const transitionProps = transition ? {\n in: open,\n onEnter: handleEnter,\n onExited: handleExited\n } : undefined;\n return /*#__PURE__*/_jsx(Portal, {\n disablePortal: disablePortal,\n container: container,\n children: /*#__PURE__*/_jsx(PopperTooltip, _extends({\n anchorEl: anchorEl,\n direction: direction,\n disablePortal: disablePortal,\n modifiers: modifiers,\n ref: forwardedRef,\n open: transition ? !exited : open,\n placement: placement,\n popperOptions: popperOptions,\n popperRef: popperRef,\n slotProps: slotProps,\n slots: slots\n }, other, {\n style: _extends({\n // Prevents scroll issue, waiting for Popper.js to add this style once initiated.\n position: 'fixed',\n // Fix Popper.js display issue\n top: 0,\n left: 0,\n display\n }, style),\n TransitionProps: transitionProps,\n children: children\n }))\n });\n});\nprocess.env.NODE_ENV !== \"production\" ? Popper.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * An HTML element, [virtualElement](https://popper.js.org/docs/v2/virtual-elements/),\n * or a function that returns either.\n * It's used to set the position of the popper.\n * The return value will passed as the reference object of the Popper instance.\n */\n anchorEl: chainPropTypes(PropTypes.oneOfType([HTMLElementType, PropTypes.object, PropTypes.func]), props => {\n if (props.open) {\n const resolvedAnchorEl = resolveAnchorEl(props.anchorEl);\n if (resolvedAnchorEl && isHTMLElement(resolvedAnchorEl) && resolvedAnchorEl.nodeType === 1) {\n const box = resolvedAnchorEl.getBoundingClientRect();\n if (process.env.NODE_ENV !== 'test' && box.top === 0 && box.left === 0 && box.right === 0 && box.bottom === 0) {\n return new Error(['MUI: The `anchorEl` prop provided to the component is invalid.', 'The anchor element should be part of the document layout.', \"Make sure the element is present in the document or that it's not display none.\"].join('\\n'));\n }\n } else if (!resolvedAnchorEl || typeof resolvedAnchorEl.getBoundingClientRect !== 'function' || isVirtualElement(resolvedAnchorEl) && resolvedAnchorEl.contextElement != null && resolvedAnchorEl.contextElement.nodeType !== 1) {\n return new Error(['MUI: The `anchorEl` prop provided to the component is invalid.', 'It should be an HTML element instance or a virtualElement ', '(https://popper.js.org/docs/v2/virtual-elements/).'].join('\\n'));\n }\n }\n return null;\n }),\n /**\n * Popper render function or node.\n */\n children: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.node, PropTypes.func]),\n /**\n * An HTML element or function that returns one.\n * The `container` will have the portal children appended to it.\n *\n * You can also provide a callback, which is called in a React layout effect.\n * This lets you set the container from a ref, and also makes server-side rendering possible.\n *\n * By default, it uses the body of the top-level document object,\n * so it's simply `document.body` most of the time.\n */\n container: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.func]),\n /**\n * Direction of the text.\n * @default 'ltr'\n */\n direction: PropTypes.oneOf(['ltr', 'rtl']),\n /**\n * The `children` will be under the DOM hierarchy of the parent component.\n * @default false\n */\n disablePortal: PropTypes.bool,\n /**\n * Always keep the children in the DOM.\n * This prop can be useful in SEO situation or\n * when you want to maximize the responsiveness of the Popper.\n * @default false\n */\n keepMounted: PropTypes.bool,\n /**\n * Popper.js is based on a \"plugin-like\" architecture,\n * most of its features are fully encapsulated \"modifiers\".\n *\n * A modifier is a function that is called each time Popper.js needs to\n * compute the position of the popper.\n * For this reason, modifiers should be very performant to avoid bottlenecks.\n * To learn how to create a modifier, [read the modifiers documentation](https://popper.js.org/docs/v2/modifiers/).\n */\n modifiers: PropTypes.arrayOf(PropTypes.shape({\n data: PropTypes.object,\n effect: PropTypes.func,\n enabled: PropTypes.bool,\n fn: PropTypes.func,\n name: PropTypes.any,\n options: PropTypes.object,\n phase: PropTypes.oneOf(['afterMain', 'afterRead', 'afterWrite', 'beforeMain', 'beforeRead', 'beforeWrite', 'main', 'read', 'write']),\n requires: PropTypes.arrayOf(PropTypes.string),\n requiresIfExists: PropTypes.arrayOf(PropTypes.string)\n })),\n /**\n * If `true`, the component is shown.\n */\n open: PropTypes.bool.isRequired,\n /**\n * Popper placement.\n * @default 'bottom'\n */\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n /**\n * Options provided to the [`Popper.js`](https://popper.js.org/docs/v2/constructors/#options) instance.\n * @default {}\n */\n popperOptions: PropTypes.shape({\n modifiers: PropTypes.array,\n onFirstUpdate: PropTypes.func,\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n strategy: PropTypes.oneOf(['absolute', 'fixed'])\n }),\n /**\n * A ref that points to the used popper instance.\n */\n popperRef: refType,\n /**\n * The props used for each slot inside the Popper.\n * @default {}\n */\n slotProps: PropTypes.shape({\n root: PropTypes.oneOfType([PropTypes.func, PropTypes.object])\n }),\n /**\n * The components used for each slot inside the Popper.\n * Either a string to use a HTML element or a component.\n * @default {}\n */\n slots: PropTypes.shape({\n root: PropTypes.elementType\n }),\n /**\n * Help supporting a react-transition-group/Transition component.\n * @default false\n */\n transition: PropTypes.bool\n} : void 0;\nexport { Popper };","'use client';\n\nimport * as React from 'react';\nimport { useTheme as useThemeSystem } from '@mui/system';\nimport defaultTheme from './defaultTheme';\nimport THEME_ID from './identifier';\nexport default function useTheme() {\n const theme = useThemeSystem(defaultTheme);\n if (process.env.NODE_ENV !== 'production') {\n // eslint-disable-next-line react-hooks/rules-of-hooks\n React.useDebugValue(theme);\n }\n return theme[THEME_ID] || theme;\n}","export default function _setPrototypeOf(o, p) {\n _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function _setPrototypeOf(o, p) {\n o.__proto__ = p;\n return o;\n };\n return _setPrototypeOf(o, p);\n}","import setPrototypeOf from \"./setPrototypeOf.js\";\nexport default function _inheritsLoose(subClass, superClass) {\n subClass.prototype = Object.create(superClass.prototype);\n subClass.prototype.constructor = subClass;\n setPrototypeOf(subClass, superClass);\n}","export default {\n disabled: false\n};","import PropTypes from 'prop-types';\nexport var timeoutsShape = process.env.NODE_ENV !== 'production' ? PropTypes.oneOfType([PropTypes.number, PropTypes.shape({\n enter: PropTypes.number,\n exit: PropTypes.number,\n appear: PropTypes.number\n}).isRequired]) : null;\nexport var classNamesShape = process.env.NODE_ENV !== 'production' ? PropTypes.oneOfType([PropTypes.string, PropTypes.shape({\n enter: PropTypes.string,\n exit: PropTypes.string,\n active: PropTypes.string\n}), PropTypes.shape({\n enter: PropTypes.string,\n enterDone: PropTypes.string,\n enterActive: PropTypes.string,\n exit: PropTypes.string,\n exitDone: PropTypes.string,\n exitActive: PropTypes.string\n})]) : null;","import React from 'react';\nexport default React.createContext(null);","export var forceReflow = function forceReflow(node) {\n return node.scrollTop;\n};","import _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _inheritsLoose from \"@babel/runtime/helpers/esm/inheritsLoose\";\nimport PropTypes from 'prop-types';\nimport React from 'react';\nimport ReactDOM from 'react-dom';\nimport config from './config';\nimport { timeoutsShape } from './utils/PropTypes';\nimport TransitionGroupContext from './TransitionGroupContext';\nimport { forceReflow } from './utils/reflow';\nexport var UNMOUNTED = 'unmounted';\nexport var EXITED = 'exited';\nexport var ENTERING = 'entering';\nexport var ENTERED = 'entered';\nexport var EXITING = 'exiting';\n/**\n * The Transition component lets you describe a transition from one component\n * state to another _over time_ with a simple declarative API. Most commonly\n * it's used to animate the mounting and unmounting of a component, but can also\n * be used to describe in-place transition states as well.\n *\n * ---\n *\n * **Note**: `Transition` is a platform-agnostic base component. If you're using\n * transitions in CSS, you'll probably want to use\n * [`CSSTransition`](https://reactcommunity.org/react-transition-group/css-transition)\n * instead. It inherits all the features of `Transition`, but contains\n * additional features necessary to play nice with CSS transitions (hence the\n * name of the component).\n *\n * ---\n *\n * By default the `Transition` component does not alter the behavior of the\n * component it renders, it only tracks \"enter\" and \"exit\" states for the\n * components. It's up to you to give meaning and effect to those states. For\n * example we can add styles to a component when it enters or exits:\n *\n * ```jsx\n * import { Transition } from 'react-transition-group';\n *\n * const duration = 300;\n *\n * const defaultStyle = {\n * transition: `opacity ${duration}ms ease-in-out`,\n * opacity: 0,\n * }\n *\n * const transitionStyles = {\n * entering: { opacity: 1 },\n * entered: { opacity: 1 },\n * exiting: { opacity: 0 },\n * exited: { opacity: 0 },\n * };\n *\n * const Fade = ({ in: inProp }) => (\n * \n * {state => (\n *
    \n * I'm a fade Transition!\n *
    \n * )}\n *
    \n * );\n * ```\n *\n * There are 4 main states a Transition can be in:\n * - `'entering'`\n * - `'entered'`\n * - `'exiting'`\n * - `'exited'`\n *\n * Transition state is toggled via the `in` prop. When `true` the component\n * begins the \"Enter\" stage. During this stage, the component will shift from\n * its current transition state, to `'entering'` for the duration of the\n * transition and then to the `'entered'` stage once it's complete. Let's take\n * the following example (we'll use the\n * [useState](https://reactjs.org/docs/hooks-reference.html#usestate) hook):\n *\n * ```jsx\n * function App() {\n * const [inProp, setInProp] = useState(false);\n * return (\n *
    \n * \n * {state => (\n * // ...\n * )}\n * \n * \n *
    \n * );\n * }\n * ```\n *\n * When the button is clicked the component will shift to the `'entering'` state\n * and stay there for 500ms (the value of `timeout`) before it finally switches\n * to `'entered'`.\n *\n * When `in` is `false` the same thing happens except the state moves from\n * `'exiting'` to `'exited'`.\n */\n\nvar Transition = /*#__PURE__*/function (_React$Component) {\n _inheritsLoose(Transition, _React$Component);\n\n function Transition(props, context) {\n var _this;\n\n _this = _React$Component.call(this, props, context) || this;\n var parentGroup = context; // In the context of a TransitionGroup all enters are really appears\n\n var appear = parentGroup && !parentGroup.isMounting ? props.enter : props.appear;\n var initialStatus;\n _this.appearStatus = null;\n\n if (props.in) {\n if (appear) {\n initialStatus = EXITED;\n _this.appearStatus = ENTERING;\n } else {\n initialStatus = ENTERED;\n }\n } else {\n if (props.unmountOnExit || props.mountOnEnter) {\n initialStatus = UNMOUNTED;\n } else {\n initialStatus = EXITED;\n }\n }\n\n _this.state = {\n status: initialStatus\n };\n _this.nextCallback = null;\n return _this;\n }\n\n Transition.getDerivedStateFromProps = function getDerivedStateFromProps(_ref, prevState) {\n var nextIn = _ref.in;\n\n if (nextIn && prevState.status === UNMOUNTED) {\n return {\n status: EXITED\n };\n }\n\n return null;\n } // getSnapshotBeforeUpdate(prevProps) {\n // let nextStatus = null\n // if (prevProps !== this.props) {\n // const { status } = this.state\n // if (this.props.in) {\n // if (status !== ENTERING && status !== ENTERED) {\n // nextStatus = ENTERING\n // }\n // } else {\n // if (status === ENTERING || status === ENTERED) {\n // nextStatus = EXITING\n // }\n // }\n // }\n // return { nextStatus }\n // }\n ;\n\n var _proto = Transition.prototype;\n\n _proto.componentDidMount = function componentDidMount() {\n this.updateStatus(true, this.appearStatus);\n };\n\n _proto.componentDidUpdate = function componentDidUpdate(prevProps) {\n var nextStatus = null;\n\n if (prevProps !== this.props) {\n var status = this.state.status;\n\n if (this.props.in) {\n if (status !== ENTERING && status !== ENTERED) {\n nextStatus = ENTERING;\n }\n } else {\n if (status === ENTERING || status === ENTERED) {\n nextStatus = EXITING;\n }\n }\n }\n\n this.updateStatus(false, nextStatus);\n };\n\n _proto.componentWillUnmount = function componentWillUnmount() {\n this.cancelNextCallback();\n };\n\n _proto.getTimeouts = function getTimeouts() {\n var timeout = this.props.timeout;\n var exit, enter, appear;\n exit = enter = appear = timeout;\n\n if (timeout != null && typeof timeout !== 'number') {\n exit = timeout.exit;\n enter = timeout.enter; // TODO: remove fallback for next major\n\n appear = timeout.appear !== undefined ? timeout.appear : enter;\n }\n\n return {\n exit: exit,\n enter: enter,\n appear: appear\n };\n };\n\n _proto.updateStatus = function updateStatus(mounting, nextStatus) {\n if (mounting === void 0) {\n mounting = false;\n }\n\n if (nextStatus !== null) {\n // nextStatus will always be ENTERING or EXITING.\n this.cancelNextCallback();\n\n if (nextStatus === ENTERING) {\n if (this.props.unmountOnExit || this.props.mountOnEnter) {\n var node = this.props.nodeRef ? this.props.nodeRef.current : ReactDOM.findDOMNode(this); // https://github.com/reactjs/react-transition-group/pull/749\n // With unmountOnExit or mountOnEnter, the enter animation should happen at the transition between `exited` and `entering`.\n // To make the animation happen, we have to separate each rendering and avoid being processed as batched.\n\n if (node) forceReflow(node);\n }\n\n this.performEnter(mounting);\n } else {\n this.performExit();\n }\n } else if (this.props.unmountOnExit && this.state.status === EXITED) {\n this.setState({\n status: UNMOUNTED\n });\n }\n };\n\n _proto.performEnter = function performEnter(mounting) {\n var _this2 = this;\n\n var enter = this.props.enter;\n var appearing = this.context ? this.context.isMounting : mounting;\n\n var _ref2 = this.props.nodeRef ? [appearing] : [ReactDOM.findDOMNode(this), appearing],\n maybeNode = _ref2[0],\n maybeAppearing = _ref2[1];\n\n var timeouts = this.getTimeouts();\n var enterTimeout = appearing ? timeouts.appear : timeouts.enter; // no enter animation skip right to ENTERED\n // if we are mounting and running this it means appear _must_ be set\n\n if (!mounting && !enter || config.disabled) {\n this.safeSetState({\n status: ENTERED\n }, function () {\n _this2.props.onEntered(maybeNode);\n });\n return;\n }\n\n this.props.onEnter(maybeNode, maybeAppearing);\n this.safeSetState({\n status: ENTERING\n }, function () {\n _this2.props.onEntering(maybeNode, maybeAppearing);\n\n _this2.onTransitionEnd(enterTimeout, function () {\n _this2.safeSetState({\n status: ENTERED\n }, function () {\n _this2.props.onEntered(maybeNode, maybeAppearing);\n });\n });\n });\n };\n\n _proto.performExit = function performExit() {\n var _this3 = this;\n\n var exit = this.props.exit;\n var timeouts = this.getTimeouts();\n var maybeNode = this.props.nodeRef ? undefined : ReactDOM.findDOMNode(this); // no exit animation skip right to EXITED\n\n if (!exit || config.disabled) {\n this.safeSetState({\n status: EXITED\n }, function () {\n _this3.props.onExited(maybeNode);\n });\n return;\n }\n\n this.props.onExit(maybeNode);\n this.safeSetState({\n status: EXITING\n }, function () {\n _this3.props.onExiting(maybeNode);\n\n _this3.onTransitionEnd(timeouts.exit, function () {\n _this3.safeSetState({\n status: EXITED\n }, function () {\n _this3.props.onExited(maybeNode);\n });\n });\n });\n };\n\n _proto.cancelNextCallback = function cancelNextCallback() {\n if (this.nextCallback !== null) {\n this.nextCallback.cancel();\n this.nextCallback = null;\n }\n };\n\n _proto.safeSetState = function safeSetState(nextState, callback) {\n // This shouldn't be necessary, but there are weird race conditions with\n // setState callbacks and unmounting in testing, so always make sure that\n // we can cancel any pending setState callbacks after we unmount.\n callback = this.setNextCallback(callback);\n this.setState(nextState, callback);\n };\n\n _proto.setNextCallback = function setNextCallback(callback) {\n var _this4 = this;\n\n var active = true;\n\n this.nextCallback = function (event) {\n if (active) {\n active = false;\n _this4.nextCallback = null;\n callback(event);\n }\n };\n\n this.nextCallback.cancel = function () {\n active = false;\n };\n\n return this.nextCallback;\n };\n\n _proto.onTransitionEnd = function onTransitionEnd(timeout, handler) {\n this.setNextCallback(handler);\n var node = this.props.nodeRef ? this.props.nodeRef.current : ReactDOM.findDOMNode(this);\n var doesNotHaveTimeoutOrListener = timeout == null && !this.props.addEndListener;\n\n if (!node || doesNotHaveTimeoutOrListener) {\n setTimeout(this.nextCallback, 0);\n return;\n }\n\n if (this.props.addEndListener) {\n var _ref3 = this.props.nodeRef ? [this.nextCallback] : [node, this.nextCallback],\n maybeNode = _ref3[0],\n maybeNextCallback = _ref3[1];\n\n this.props.addEndListener(maybeNode, maybeNextCallback);\n }\n\n if (timeout != null) {\n setTimeout(this.nextCallback, timeout);\n }\n };\n\n _proto.render = function render() {\n var status = this.state.status;\n\n if (status === UNMOUNTED) {\n return null;\n }\n\n var _this$props = this.props,\n children = _this$props.children,\n _in = _this$props.in,\n _mountOnEnter = _this$props.mountOnEnter,\n _unmountOnExit = _this$props.unmountOnExit,\n _appear = _this$props.appear,\n _enter = _this$props.enter,\n _exit = _this$props.exit,\n _timeout = _this$props.timeout,\n _addEndListener = _this$props.addEndListener,\n _onEnter = _this$props.onEnter,\n _onEntering = _this$props.onEntering,\n _onEntered = _this$props.onEntered,\n _onExit = _this$props.onExit,\n _onExiting = _this$props.onExiting,\n _onExited = _this$props.onExited,\n _nodeRef = _this$props.nodeRef,\n childProps = _objectWithoutPropertiesLoose(_this$props, [\"children\", \"in\", \"mountOnEnter\", \"unmountOnExit\", \"appear\", \"enter\", \"exit\", \"timeout\", \"addEndListener\", \"onEnter\", \"onEntering\", \"onEntered\", \"onExit\", \"onExiting\", \"onExited\", \"nodeRef\"]);\n\n return (\n /*#__PURE__*/\n // allows for nested Transitions\n React.createElement(TransitionGroupContext.Provider, {\n value: null\n }, typeof children === 'function' ? children(status, childProps) : React.cloneElement(React.Children.only(children), childProps))\n );\n };\n\n return Transition;\n}(React.Component);\n\nTransition.contextType = TransitionGroupContext;\nTransition.propTypes = process.env.NODE_ENV !== \"production\" ? {\n /**\n * A React reference to DOM element that need to transition:\n * https://stackoverflow.com/a/51127130/4671932\n *\n * - When `nodeRef` prop is used, `node` is not passed to callback functions\n * (e.g. `onEnter`) because user already has direct access to the node.\n * - When changing `key` prop of `Transition` in a `TransitionGroup` a new\n * `nodeRef` need to be provided to `Transition` with changed `key` prop\n * (see\n * [test/CSSTransition-test.js](https://github.com/reactjs/react-transition-group/blob/13435f897b3ab71f6e19d724f145596f5910581c/test/CSSTransition-test.js#L362-L437)).\n */\n nodeRef: PropTypes.shape({\n current: typeof Element === 'undefined' ? PropTypes.any : function (propValue, key, componentName, location, propFullName, secret) {\n var value = propValue[key];\n return PropTypes.instanceOf(value && 'ownerDocument' in value ? value.ownerDocument.defaultView.Element : Element)(propValue, key, componentName, location, propFullName, secret);\n }\n }),\n\n /**\n * A `function` child can be used instead of a React element. This function is\n * called with the current transition status (`'entering'`, `'entered'`,\n * `'exiting'`, `'exited'`), which can be used to apply context\n * specific props to a component.\n *\n * ```jsx\n * \n * {state => (\n * \n * )}\n * \n * ```\n */\n children: PropTypes.oneOfType([PropTypes.func.isRequired, PropTypes.element.isRequired]).isRequired,\n\n /**\n * Show the component; triggers the enter or exit states\n */\n in: PropTypes.bool,\n\n /**\n * By default the child component is mounted immediately along with\n * the parent `Transition` component. If you want to \"lazy mount\" the component on the\n * first `in={true}` you can set `mountOnEnter`. After the first enter transition the component will stay\n * mounted, even on \"exited\", unless you also specify `unmountOnExit`.\n */\n mountOnEnter: PropTypes.bool,\n\n /**\n * By default the child component stays mounted after it reaches the `'exited'` state.\n * Set `unmountOnExit` if you'd prefer to unmount the component after it finishes exiting.\n */\n unmountOnExit: PropTypes.bool,\n\n /**\n * By default the child component does not perform the enter transition when\n * it first mounts, regardless of the value of `in`. If you want this\n * behavior, set both `appear` and `in` to `true`.\n *\n * > **Note**: there are no special appear states like `appearing`/`appeared`, this prop\n * > only adds an additional enter transition. However, in the\n * > `` component that first enter transition does result in\n * > additional `.appear-*` classes, that way you can choose to style it\n * > differently.\n */\n appear: PropTypes.bool,\n\n /**\n * Enable or disable enter transitions.\n */\n enter: PropTypes.bool,\n\n /**\n * Enable or disable exit transitions.\n */\n exit: PropTypes.bool,\n\n /**\n * The duration of the transition, in milliseconds.\n * Required unless `addEndListener` is provided.\n *\n * You may specify a single timeout for all transitions:\n *\n * ```jsx\n * timeout={500}\n * ```\n *\n * or individually:\n *\n * ```jsx\n * timeout={{\n * appear: 500,\n * enter: 300,\n * exit: 500,\n * }}\n * ```\n *\n * - `appear` defaults to the value of `enter`\n * - `enter` defaults to `0`\n * - `exit` defaults to `0`\n *\n * @type {number | { enter?: number, exit?: number, appear?: number }}\n */\n timeout: function timeout(props) {\n var pt = timeoutsShape;\n if (!props.addEndListener) pt = pt.isRequired;\n\n for (var _len = arguments.length, args = new Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) {\n args[_key - 1] = arguments[_key];\n }\n\n return pt.apply(void 0, [props].concat(args));\n },\n\n /**\n * Add a custom transition end trigger. Called with the transitioning\n * DOM node and a `done` callback. Allows for more fine grained transition end\n * logic. Timeouts are still used as a fallback if provided.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * ```jsx\n * addEndListener={(node, done) => {\n * // use the css transitionend event to mark the finish of a transition\n * node.addEventListener('transitionend', done, false);\n * }}\n * ```\n */\n addEndListener: PropTypes.func,\n\n /**\n * Callback fired before the \"entering\" status is applied. An extra parameter\n * `isAppearing` is supplied to indicate if the enter stage is occurring on the initial mount\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement, isAppearing: bool) -> void\n */\n onEnter: PropTypes.func,\n\n /**\n * Callback fired after the \"entering\" status is applied. An extra parameter\n * `isAppearing` is supplied to indicate if the enter stage is occurring on the initial mount\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement, isAppearing: bool)\n */\n onEntering: PropTypes.func,\n\n /**\n * Callback fired after the \"entered\" status is applied. An extra parameter\n * `isAppearing` is supplied to indicate if the enter stage is occurring on the initial mount\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement, isAppearing: bool) -> void\n */\n onEntered: PropTypes.func,\n\n /**\n * Callback fired before the \"exiting\" status is applied.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement) -> void\n */\n onExit: PropTypes.func,\n\n /**\n * Callback fired after the \"exiting\" status is applied.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement) -> void\n */\n onExiting: PropTypes.func,\n\n /**\n * Callback fired after the \"exited\" status is applied.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed\n *\n * @type Function(node: HtmlElement) -> void\n */\n onExited: PropTypes.func\n} : {}; // Name the function so it is clearer in the documentation\n\nfunction noop() {}\n\nTransition.defaultProps = {\n in: false,\n mountOnEnter: false,\n unmountOnExit: false,\n appear: false,\n enter: true,\n exit: true,\n onEnter: noop,\n onEntering: noop,\n onEntered: noop,\n onExit: noop,\n onExiting: noop,\n onExited: noop\n};\nTransition.UNMOUNTED = UNMOUNTED;\nTransition.EXITED = EXITED;\nTransition.ENTERING = ENTERING;\nTransition.ENTERED = ENTERED;\nTransition.EXITING = EXITING;\nexport default Transition;","export const reflow = node => node.scrollTop;\nexport function getTransitionProps(props, options) {\n var _style$transitionDura, _style$transitionTimi;\n const {\n timeout,\n easing,\n style = {}\n } = props;\n return {\n duration: (_style$transitionDura = style.transitionDuration) != null ? _style$transitionDura : typeof timeout === 'number' ? timeout : timeout[options.mode] || 0,\n easing: (_style$transitionTimi = style.transitionTimingFunction) != null ? _style$transitionTimi : typeof easing === 'object' ? easing[options.mode] : easing,\n delay: style.transitionDelay\n };\n}","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"addEndListener\", \"appear\", \"children\", \"easing\", \"in\", \"onEnter\", \"onEntered\", \"onEntering\", \"onExit\", \"onExited\", \"onExiting\", \"style\", \"timeout\", \"TransitionComponent\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport { elementAcceptingRef, unstable_useTimeout as useTimeout } from '@mui/utils';\nimport { Transition } from 'react-transition-group';\nimport useTheme from '../styles/useTheme';\nimport { getTransitionProps, reflow } from '../transitions/utils';\nimport useForkRef from '../utils/useForkRef';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nfunction getScale(value) {\n return `scale(${value}, ${value ** 2})`;\n}\nconst styles = {\n entering: {\n opacity: 1,\n transform: getScale(1)\n },\n entered: {\n opacity: 1,\n transform: 'none'\n }\n};\n\n/*\n TODO v6: remove\n Conditionally apply a workaround for the CSS transition bug in Safari 15.4 / WebKit browsers.\n */\nconst isWebKit154 = typeof navigator !== 'undefined' && /^((?!chrome|android).)*(safari|mobile)/i.test(navigator.userAgent) && /(os |version\\/)15(.|_)4/i.test(navigator.userAgent);\n\n/**\n * The Grow transition is used by the [Tooltip](/material-ui/react-tooltip/) and\n * [Popover](/material-ui/react-popover/) components.\n * It uses [react-transition-group](https://github.com/reactjs/react-transition-group) internally.\n */\nconst Grow = /*#__PURE__*/React.forwardRef(function Grow(props, ref) {\n const {\n addEndListener,\n appear = true,\n children,\n easing,\n in: inProp,\n onEnter,\n onEntered,\n onEntering,\n onExit,\n onExited,\n onExiting,\n style,\n timeout = 'auto',\n // eslint-disable-next-line react/prop-types\n TransitionComponent = Transition\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const timer = useTimeout();\n const autoTimeout = React.useRef();\n const theme = useTheme();\n const nodeRef = React.useRef(null);\n const handleRef = useForkRef(nodeRef, children.ref, ref);\n const normalizedTransitionCallback = callback => maybeIsAppearing => {\n if (callback) {\n const node = nodeRef.current;\n\n // onEnterXxx and onExitXxx callbacks have a different arguments.length value.\n if (maybeIsAppearing === undefined) {\n callback(node);\n } else {\n callback(node, maybeIsAppearing);\n }\n }\n };\n const handleEntering = normalizedTransitionCallback(onEntering);\n const handleEnter = normalizedTransitionCallback((node, isAppearing) => {\n reflow(node); // So the animation always start from the start.\n\n const {\n duration: transitionDuration,\n delay,\n easing: transitionTimingFunction\n } = getTransitionProps({\n style,\n timeout,\n easing\n }, {\n mode: 'enter'\n });\n let duration;\n if (timeout === 'auto') {\n duration = theme.transitions.getAutoHeightDuration(node.clientHeight);\n autoTimeout.current = duration;\n } else {\n duration = transitionDuration;\n }\n node.style.transition = [theme.transitions.create('opacity', {\n duration,\n delay\n }), theme.transitions.create('transform', {\n duration: isWebKit154 ? duration : duration * 0.666,\n delay,\n easing: transitionTimingFunction\n })].join(',');\n if (onEnter) {\n onEnter(node, isAppearing);\n }\n });\n const handleEntered = normalizedTransitionCallback(onEntered);\n const handleExiting = normalizedTransitionCallback(onExiting);\n const handleExit = normalizedTransitionCallback(node => {\n const {\n duration: transitionDuration,\n delay,\n easing: transitionTimingFunction\n } = getTransitionProps({\n style,\n timeout,\n easing\n }, {\n mode: 'exit'\n });\n let duration;\n if (timeout === 'auto') {\n duration = theme.transitions.getAutoHeightDuration(node.clientHeight);\n autoTimeout.current = duration;\n } else {\n duration = transitionDuration;\n }\n node.style.transition = [theme.transitions.create('opacity', {\n duration,\n delay\n }), theme.transitions.create('transform', {\n duration: isWebKit154 ? duration : duration * 0.666,\n delay: isWebKit154 ? delay : delay || duration * 0.333,\n easing: transitionTimingFunction\n })].join(',');\n node.style.opacity = 0;\n node.style.transform = getScale(0.75);\n if (onExit) {\n onExit(node);\n }\n });\n const handleExited = normalizedTransitionCallback(onExited);\n const handleAddEndListener = next => {\n if (timeout === 'auto') {\n timer.start(autoTimeout.current || 0, next);\n }\n if (addEndListener) {\n // Old call signature before `react-transition-group` implemented `nodeRef`\n addEndListener(nodeRef.current, next);\n }\n };\n return /*#__PURE__*/_jsx(TransitionComponent, _extends({\n appear: appear,\n in: inProp,\n nodeRef: nodeRef,\n onEnter: handleEnter,\n onEntered: handleEntered,\n onEntering: handleEntering,\n onExit: handleExit,\n onExited: handleExited,\n onExiting: handleExiting,\n addEndListener: handleAddEndListener,\n timeout: timeout === 'auto' ? null : timeout\n }, other, {\n children: (state, childProps) => {\n return /*#__PURE__*/React.cloneElement(children, _extends({\n style: _extends({\n opacity: 0,\n transform: getScale(0.75),\n visibility: state === 'exited' && !inProp ? 'hidden' : undefined\n }, styles[state], style, children.props.style),\n ref: handleRef\n }, childProps));\n }\n }));\n});\nprocess.env.NODE_ENV !== \"production\" ? Grow.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the d.ts file and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * Add a custom transition end trigger. Called with the transitioning DOM\n * node and a done callback. Allows for more fine grained transition end\n * logic. Note: Timeouts are still used as a fallback if provided.\n */\n addEndListener: PropTypes.func,\n /**\n * Perform the enter transition when it first mounts if `in` is also `true`.\n * Set this to `false` to disable this behavior.\n * @default true\n */\n appear: PropTypes.bool,\n /**\n * A single child content element.\n */\n children: elementAcceptingRef.isRequired,\n /**\n * The transition timing function.\n * You may specify a single easing or a object containing enter and exit values.\n */\n easing: PropTypes.oneOfType([PropTypes.shape({\n enter: PropTypes.string,\n exit: PropTypes.string\n }), PropTypes.string]),\n /**\n * If `true`, the component will transition in.\n */\n in: PropTypes.bool,\n /**\n * @ignore\n */\n onEnter: PropTypes.func,\n /**\n * @ignore\n */\n onEntered: PropTypes.func,\n /**\n * @ignore\n */\n onEntering: PropTypes.func,\n /**\n * @ignore\n */\n onExit: PropTypes.func,\n /**\n * @ignore\n */\n onExited: PropTypes.func,\n /**\n * @ignore\n */\n onExiting: PropTypes.func,\n /**\n * @ignore\n */\n style: PropTypes.object,\n /**\n * The duration for the transition, in milliseconds.\n * You may specify a single timeout for all transitions, or individually with an object.\n *\n * Set to 'auto' to automatically calculate transition time based on height.\n * @default 'auto'\n */\n timeout: PropTypes.oneOfType([PropTypes.oneOf(['auto']), PropTypes.number, PropTypes.shape({\n appear: PropTypes.number,\n enter: PropTypes.number,\n exit: PropTypes.number\n })])\n} : void 0;\nGrow.muiSupportAuto = true;\nexport default Grow;","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"anchorEl\", \"component\", \"components\", \"componentsProps\", \"container\", \"disablePortal\", \"keepMounted\", \"modifiers\", \"open\", \"placement\", \"popperOptions\", \"popperRef\", \"transition\", \"slots\", \"slotProps\"];\nimport { Popper as BasePopper } from '@mui/base/Popper';\nimport { useThemeWithoutDefault as useTheme } from '@mui/system';\nimport { HTMLElementType, refType } from '@mui/utils';\nimport PropTypes from 'prop-types';\nimport * as React from 'react';\nimport { styled, useThemeProps } from '../styles';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nconst PopperRoot = styled(BasePopper, {\n name: 'MuiPopper',\n slot: 'Root',\n overridesResolver: (props, styles) => styles.root\n})({});\n\n/**\n *\n * Demos:\n *\n * - [Autocomplete](https://mui.com/material-ui/react-autocomplete/)\n * - [Menu](https://mui.com/material-ui/react-menu/)\n * - [Popper](https://mui.com/material-ui/react-popper/)\n *\n * API:\n *\n * - [Popper API](https://mui.com/material-ui/api/popper/)\n */\nconst Popper = /*#__PURE__*/React.forwardRef(function Popper(inProps, ref) {\n var _slots$root;\n const theme = useTheme();\n const props = useThemeProps({\n props: inProps,\n name: 'MuiPopper'\n });\n const {\n anchorEl,\n component,\n components,\n componentsProps,\n container,\n disablePortal,\n keepMounted,\n modifiers,\n open,\n placement,\n popperOptions,\n popperRef,\n transition,\n slots,\n slotProps\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const RootComponent = (_slots$root = slots == null ? void 0 : slots.root) != null ? _slots$root : components == null ? void 0 : components.Root;\n const otherProps = _extends({\n anchorEl,\n container,\n disablePortal,\n keepMounted,\n modifiers,\n open,\n placement,\n popperOptions,\n popperRef,\n transition\n }, other);\n return /*#__PURE__*/_jsx(PopperRoot, _extends({\n as: component,\n direction: theme == null ? void 0 : theme.direction,\n slots: {\n root: RootComponent\n },\n slotProps: slotProps != null ? slotProps : componentsProps\n }, otherProps, {\n ref: ref\n }));\n});\nprocess.env.NODE_ENV !== \"production\" ? Popper.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * An HTML element, [virtualElement](https://popper.js.org/docs/v2/virtual-elements/),\n * or a function that returns either.\n * It's used to set the position of the popper.\n * The return value will passed as the reference object of the Popper instance.\n */\n anchorEl: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.object, PropTypes.func]),\n /**\n * Popper render function or node.\n */\n children: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.node, PropTypes.func]),\n /**\n * The component used for the root node.\n * Either a string to use a HTML element or a component.\n */\n component: PropTypes.elementType,\n /**\n * The components used for each slot inside the Popper.\n * Either a string to use a HTML element or a component.\n * @default {}\n */\n components: PropTypes.shape({\n Root: PropTypes.elementType\n }),\n /**\n * The props used for each slot inside the Popper.\n * @default {}\n */\n componentsProps: PropTypes.shape({\n root: PropTypes.oneOfType([PropTypes.func, PropTypes.object])\n }),\n /**\n * An HTML element or function that returns one.\n * The `container` will have the portal children appended to it.\n *\n * You can also provide a callback, which is called in a React layout effect.\n * This lets you set the container from a ref, and also makes server-side rendering possible.\n *\n * By default, it uses the body of the top-level document object,\n * so it's simply `document.body` most of the time.\n */\n container: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.func]),\n /**\n * The `children` will be under the DOM hierarchy of the parent component.\n * @default false\n */\n disablePortal: PropTypes.bool,\n /**\n * Always keep the children in the DOM.\n * This prop can be useful in SEO situation or\n * when you want to maximize the responsiveness of the Popper.\n * @default false\n */\n keepMounted: PropTypes.bool,\n /**\n * Popper.js is based on a \"plugin-like\" architecture,\n * most of its features are fully encapsulated \"modifiers\".\n *\n * A modifier is a function that is called each time Popper.js needs to\n * compute the position of the popper.\n * For this reason, modifiers should be very performant to avoid bottlenecks.\n * To learn how to create a modifier, [read the modifiers documentation](https://popper.js.org/docs/v2/modifiers/).\n */\n modifiers: PropTypes.arrayOf(PropTypes.shape({\n data: PropTypes.object,\n effect: PropTypes.func,\n enabled: PropTypes.bool,\n fn: PropTypes.func,\n name: PropTypes.any,\n options: PropTypes.object,\n phase: PropTypes.oneOf(['afterMain', 'afterRead', 'afterWrite', 'beforeMain', 'beforeRead', 'beforeWrite', 'main', 'read', 'write']),\n requires: PropTypes.arrayOf(PropTypes.string),\n requiresIfExists: PropTypes.arrayOf(PropTypes.string)\n })),\n /**\n * If `true`, the component is shown.\n */\n open: PropTypes.bool.isRequired,\n /**\n * Popper placement.\n * @default 'bottom'\n */\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n /**\n * Options provided to the [`Popper.js`](https://popper.js.org/docs/v2/constructors/#options) instance.\n * @default {}\n */\n popperOptions: PropTypes.shape({\n modifiers: PropTypes.array,\n onFirstUpdate: PropTypes.func,\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n strategy: PropTypes.oneOf(['absolute', 'fixed'])\n }),\n /**\n * A ref that points to the used popper instance.\n */\n popperRef: refType,\n /**\n * The props used for each slot inside the Popper.\n * @default {}\n */\n slotProps: PropTypes.shape({\n root: PropTypes.oneOfType([PropTypes.func, PropTypes.object])\n }),\n /**\n * The components used for each slot inside the Popper.\n * Either a string to use a HTML element or a component.\n * @default {}\n */\n slots: PropTypes.shape({\n root: PropTypes.elementType\n }),\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Help supporting a react-transition-group/Transition component.\n * @default false\n */\n transition: PropTypes.bool\n} : void 0;\nexport default Popper;","import generateUtilityClasses from '@mui/utils/generateUtilityClasses';\nimport generateUtilityClass from '@mui/utils/generateUtilityClass';\nexport function getTooltipUtilityClass(slot) {\n return generateUtilityClass('MuiTooltip', slot);\n}\nconst tooltipClasses = generateUtilityClasses('MuiTooltip', ['popper', 'popperInteractive', 'popperArrow', 'popperClose', 'tooltip', 'tooltipArrow', 'touch', 'tooltipPlacementLeft', 'tooltipPlacementRight', 'tooltipPlacementTop', 'tooltipPlacementBottom', 'arrow']);\nexport default tooltipClasses;","'use client';\n\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nconst _excluded = [\"arrow\", \"children\", \"classes\", \"components\", \"componentsProps\", \"describeChild\", \"disableFocusListener\", \"disableHoverListener\", \"disableInteractive\", \"disableTouchListener\", \"enterDelay\", \"enterNextDelay\", \"enterTouchDelay\", \"followCursor\", \"id\", \"leaveDelay\", \"leaveTouchDelay\", \"onClose\", \"onOpen\", \"open\", \"placement\", \"PopperComponent\", \"PopperProps\", \"slotProps\", \"slots\", \"title\", \"TransitionComponent\", \"TransitionProps\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport clsx from 'clsx';\nimport { elementAcceptingRef, unstable_useTimeout as useTimeout, unstable_Timeout as Timeout } from '@mui/utils';\nimport { unstable_composeClasses as composeClasses, appendOwnerState } from '@mui/base';\nimport { alpha } from '@mui/system';\nimport styled from '../styles/styled';\nimport useTheme from '../styles/useTheme';\nimport useThemeProps from '../styles/useThemeProps';\nimport capitalize from '../utils/capitalize';\nimport Grow from '../Grow';\nimport Popper from '../Popper';\nimport useEventCallback from '../utils/useEventCallback';\nimport useForkRef from '../utils/useForkRef';\nimport useId from '../utils/useId';\nimport useIsFocusVisible from '../utils/useIsFocusVisible';\nimport useControlled from '../utils/useControlled';\nimport tooltipClasses, { getTooltipUtilityClass } from './tooltipClasses';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nimport { jsxs as _jsxs } from \"react/jsx-runtime\";\nfunction round(value) {\n return Math.round(value * 1e5) / 1e5;\n}\nconst useUtilityClasses = ownerState => {\n const {\n classes,\n disableInteractive,\n arrow,\n touch,\n placement\n } = ownerState;\n const slots = {\n popper: ['popper', !disableInteractive && 'popperInteractive', arrow && 'popperArrow'],\n tooltip: ['tooltip', arrow && 'tooltipArrow', touch && 'touch', `tooltipPlacement${capitalize(placement.split('-')[0])}`],\n arrow: ['arrow']\n };\n return composeClasses(slots, getTooltipUtilityClass, classes);\n};\nconst TooltipPopper = styled(Popper, {\n name: 'MuiTooltip',\n slot: 'Popper',\n overridesResolver: (props, styles) => {\n const {\n ownerState\n } = props;\n return [styles.popper, !ownerState.disableInteractive && styles.popperInteractive, ownerState.arrow && styles.popperArrow, !ownerState.open && styles.popperClose];\n }\n})(({\n theme,\n ownerState,\n open\n}) => _extends({\n zIndex: (theme.vars || theme).zIndex.tooltip,\n pointerEvents: 'none'\n}, !ownerState.disableInteractive && {\n pointerEvents: 'auto'\n}, !open && {\n pointerEvents: 'none'\n}, ownerState.arrow && {\n [`&[data-popper-placement*=\"bottom\"] .${tooltipClasses.arrow}`]: {\n top: 0,\n marginTop: '-0.71em',\n '&::before': {\n transformOrigin: '0 100%'\n }\n },\n [`&[data-popper-placement*=\"top\"] .${tooltipClasses.arrow}`]: {\n bottom: 0,\n marginBottom: '-0.71em',\n '&::before': {\n transformOrigin: '100% 0'\n }\n },\n [`&[data-popper-placement*=\"right\"] .${tooltipClasses.arrow}`]: _extends({}, !ownerState.isRtl ? {\n left: 0,\n marginLeft: '-0.71em'\n } : {\n right: 0,\n marginRight: '-0.71em'\n }, {\n height: '1em',\n width: '0.71em',\n '&::before': {\n transformOrigin: '100% 100%'\n }\n }),\n [`&[data-popper-placement*=\"left\"] .${tooltipClasses.arrow}`]: _extends({}, !ownerState.isRtl ? {\n right: 0,\n marginRight: '-0.71em'\n } : {\n left: 0,\n marginLeft: '-0.71em'\n }, {\n height: '1em',\n width: '0.71em',\n '&::before': {\n transformOrigin: '0 0'\n }\n })\n}));\nconst TooltipTooltip = styled('div', {\n name: 'MuiTooltip',\n slot: 'Tooltip',\n overridesResolver: (props, styles) => {\n const {\n ownerState\n } = props;\n return [styles.tooltip, ownerState.touch && styles.touch, ownerState.arrow && styles.tooltipArrow, styles[`tooltipPlacement${capitalize(ownerState.placement.split('-')[0])}`]];\n }\n})(({\n theme,\n ownerState\n}) => _extends({\n backgroundColor: theme.vars ? theme.vars.palette.Tooltip.bg : alpha(theme.palette.grey[700], 0.92),\n borderRadius: (theme.vars || theme).shape.borderRadius,\n color: (theme.vars || theme).palette.common.white,\n fontFamily: theme.typography.fontFamily,\n padding: '4px 8px',\n fontSize: theme.typography.pxToRem(11),\n maxWidth: 300,\n margin: 2,\n wordWrap: 'break-word',\n fontWeight: theme.typography.fontWeightMedium\n}, ownerState.arrow && {\n position: 'relative',\n margin: 0\n}, ownerState.touch && {\n padding: '8px 16px',\n fontSize: theme.typography.pxToRem(14),\n lineHeight: `${round(16 / 14)}em`,\n fontWeight: theme.typography.fontWeightRegular\n}, {\n [`.${tooltipClasses.popper}[data-popper-placement*=\"left\"] &`]: _extends({\n transformOrigin: 'right center'\n }, !ownerState.isRtl ? _extends({\n marginRight: '14px'\n }, ownerState.touch && {\n marginRight: '24px'\n }) : _extends({\n marginLeft: '14px'\n }, ownerState.touch && {\n marginLeft: '24px'\n })),\n [`.${tooltipClasses.popper}[data-popper-placement*=\"right\"] &`]: _extends({\n transformOrigin: 'left center'\n }, !ownerState.isRtl ? _extends({\n marginLeft: '14px'\n }, ownerState.touch && {\n marginLeft: '24px'\n }) : _extends({\n marginRight: '14px'\n }, ownerState.touch && {\n marginRight: '24px'\n })),\n [`.${tooltipClasses.popper}[data-popper-placement*=\"top\"] &`]: _extends({\n transformOrigin: 'center bottom',\n marginBottom: '14px'\n }, ownerState.touch && {\n marginBottom: '24px'\n }),\n [`.${tooltipClasses.popper}[data-popper-placement*=\"bottom\"] &`]: _extends({\n transformOrigin: 'center top',\n marginTop: '14px'\n }, ownerState.touch && {\n marginTop: '24px'\n })\n}));\nconst TooltipArrow = styled('span', {\n name: 'MuiTooltip',\n slot: 'Arrow',\n overridesResolver: (props, styles) => styles.arrow\n})(({\n theme\n}) => ({\n overflow: 'hidden',\n position: 'absolute',\n width: '1em',\n height: '0.71em' /* = width / sqrt(2) = (length of the hypotenuse) */,\n boxSizing: 'border-box',\n color: theme.vars ? theme.vars.palette.Tooltip.bg : alpha(theme.palette.grey[700], 0.9),\n '&::before': {\n content: '\"\"',\n margin: 'auto',\n display: 'block',\n width: '100%',\n height: '100%',\n backgroundColor: 'currentColor',\n transform: 'rotate(45deg)'\n }\n}));\nlet hystersisOpen = false;\nconst hystersisTimer = new Timeout();\nlet cursorPosition = {\n x: 0,\n y: 0\n};\nexport function testReset() {\n hystersisOpen = false;\n hystersisTimer.clear();\n}\nfunction composeEventHandler(handler, eventHandler) {\n return event => {\n if (eventHandler) {\n eventHandler(event);\n }\n handler(event);\n };\n}\n\n// TODO v6: Remove PopperComponent, PopperProps, TransitionComponent and TransitionProps.\nconst Tooltip = /*#__PURE__*/React.forwardRef(function Tooltip(inProps, ref) {\n var _ref, _slots$popper, _ref2, _ref3, _slots$transition, _ref4, _slots$tooltip, _ref5, _slots$arrow, _slotProps$popper, _ref6, _slotProps$popper2, _slotProps$transition, _slotProps$tooltip, _ref7, _slotProps$tooltip2, _slotProps$arrow, _ref8, _slotProps$arrow2;\n const props = useThemeProps({\n props: inProps,\n name: 'MuiTooltip'\n });\n const {\n arrow = false,\n children: childrenProp,\n components = {},\n componentsProps = {},\n describeChild = false,\n disableFocusListener = false,\n disableHoverListener = false,\n disableInteractive: disableInteractiveProp = false,\n disableTouchListener = false,\n enterDelay = 100,\n enterNextDelay = 0,\n enterTouchDelay = 700,\n followCursor = false,\n id: idProp,\n leaveDelay = 0,\n leaveTouchDelay = 1500,\n onClose,\n onOpen,\n open: openProp,\n placement = 'bottom',\n PopperComponent: PopperComponentProp,\n PopperProps = {},\n slotProps = {},\n slots = {},\n title,\n TransitionComponent: TransitionComponentProp = Grow,\n TransitionProps\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n\n // to prevent runtime errors, developers will need to provide a child as a React element anyway.\n const children = /*#__PURE__*/React.isValidElement(childrenProp) ? childrenProp : /*#__PURE__*/_jsx(\"span\", {\n children: childrenProp\n });\n const theme = useTheme();\n const isRtl = theme.direction === 'rtl';\n const [childNode, setChildNode] = React.useState();\n const [arrowRef, setArrowRef] = React.useState(null);\n const ignoreNonTouchEvents = React.useRef(false);\n const disableInteractive = disableInteractiveProp || followCursor;\n const closeTimer = useTimeout();\n const enterTimer = useTimeout();\n const leaveTimer = useTimeout();\n const touchTimer = useTimeout();\n const [openState, setOpenState] = useControlled({\n controlled: openProp,\n default: false,\n name: 'Tooltip',\n state: 'open'\n });\n let open = openState;\n if (process.env.NODE_ENV !== 'production') {\n // eslint-disable-next-line react-hooks/rules-of-hooks\n const {\n current: isControlled\n } = React.useRef(openProp !== undefined);\n\n // eslint-disable-next-line react-hooks/rules-of-hooks\n React.useEffect(() => {\n if (childNode && childNode.disabled && !isControlled && title !== '' && childNode.tagName.toLowerCase() === 'button') {\n console.error(['MUI: You are providing a disabled `button` child to the Tooltip component.', 'A disabled element does not fire events.', \"Tooltip needs to listen to the child element's events to display the title.\", '', 'Add a simple wrapper element, such as a `span`.'].join('\\n'));\n }\n }, [title, childNode, isControlled]);\n }\n const id = useId(idProp);\n const prevUserSelect = React.useRef();\n const stopTouchInteraction = useEventCallback(() => {\n if (prevUserSelect.current !== undefined) {\n document.body.style.WebkitUserSelect = prevUserSelect.current;\n prevUserSelect.current = undefined;\n }\n touchTimer.clear();\n });\n React.useEffect(() => stopTouchInteraction, [stopTouchInteraction]);\n const handleOpen = event => {\n hystersisTimer.clear();\n hystersisOpen = true;\n\n // The mouseover event will trigger for every nested element in the tooltip.\n // We can skip rerendering when the tooltip is already open.\n // We are using the mouseover event instead of the mouseenter event to fix a hide/show issue.\n setOpenState(true);\n if (onOpen && !open) {\n onOpen(event);\n }\n };\n const handleClose = useEventCallback(\n /**\n * @param {React.SyntheticEvent | Event} event\n */\n event => {\n hystersisTimer.start(800 + leaveDelay, () => {\n hystersisOpen = false;\n });\n setOpenState(false);\n if (onClose && open) {\n onClose(event);\n }\n closeTimer.start(theme.transitions.duration.shortest, () => {\n ignoreNonTouchEvents.current = false;\n });\n });\n const handleEnter = event => {\n if (ignoreNonTouchEvents.current && event.type !== 'touchstart') {\n return;\n }\n\n // Remove the title ahead of time.\n // We don't want to wait for the next render commit.\n // We would risk displaying two tooltips at the same time (native + this one).\n if (childNode) {\n childNode.removeAttribute('title');\n }\n enterTimer.clear();\n leaveTimer.clear();\n if (enterDelay || hystersisOpen && enterNextDelay) {\n enterTimer.start(hystersisOpen ? enterNextDelay : enterDelay, () => {\n handleOpen(event);\n });\n } else {\n handleOpen(event);\n }\n };\n const handleLeave = event => {\n enterTimer.clear();\n leaveTimer.start(leaveDelay, () => {\n handleClose(event);\n });\n };\n const {\n isFocusVisibleRef,\n onBlur: handleBlurVisible,\n onFocus: handleFocusVisible,\n ref: focusVisibleRef\n } = useIsFocusVisible();\n // We don't necessarily care about the focusVisible state (which is safe to access via ref anyway).\n // We just need to re-render the Tooltip if the focus-visible state changes.\n const [, setChildIsFocusVisible] = React.useState(false);\n const handleBlur = event => {\n handleBlurVisible(event);\n if (isFocusVisibleRef.current === false) {\n setChildIsFocusVisible(false);\n handleLeave(event);\n }\n };\n const handleFocus = event => {\n // Workaround for https://github.com/facebook/react/issues/7769\n // The autoFocus of React might trigger the event before the componentDidMount.\n // We need to account for this eventuality.\n if (!childNode) {\n setChildNode(event.currentTarget);\n }\n handleFocusVisible(event);\n if (isFocusVisibleRef.current === true) {\n setChildIsFocusVisible(true);\n handleEnter(event);\n }\n };\n const detectTouchStart = event => {\n ignoreNonTouchEvents.current = true;\n const childrenProps = children.props;\n if (childrenProps.onTouchStart) {\n childrenProps.onTouchStart(event);\n }\n };\n const handleMouseOver = handleEnter;\n const handleMouseLeave = handleLeave;\n const handleTouchStart = event => {\n detectTouchStart(event);\n leaveTimer.clear();\n closeTimer.clear();\n stopTouchInteraction();\n prevUserSelect.current = document.body.style.WebkitUserSelect;\n // Prevent iOS text selection on long-tap.\n document.body.style.WebkitUserSelect = 'none';\n touchTimer.start(enterTouchDelay, () => {\n document.body.style.WebkitUserSelect = prevUserSelect.current;\n handleEnter(event);\n });\n };\n const handleTouchEnd = event => {\n if (children.props.onTouchEnd) {\n children.props.onTouchEnd(event);\n }\n stopTouchInteraction();\n leaveTimer.start(leaveTouchDelay, () => {\n handleClose(event);\n });\n };\n React.useEffect(() => {\n if (!open) {\n return undefined;\n }\n\n /**\n * @param {KeyboardEvent} nativeEvent\n */\n function handleKeyDown(nativeEvent) {\n // IE11, Edge (prior to using Bink?) use 'Esc'\n if (nativeEvent.key === 'Escape' || nativeEvent.key === 'Esc') {\n handleClose(nativeEvent);\n }\n }\n document.addEventListener('keydown', handleKeyDown);\n return () => {\n document.removeEventListener('keydown', handleKeyDown);\n };\n }, [handleClose, open]);\n const handleRef = useForkRef(children.ref, focusVisibleRef, setChildNode, ref);\n\n // There is no point in displaying an empty tooltip.\n // So we exclude all falsy values, except 0, which is valid.\n if (!title && title !== 0) {\n open = false;\n }\n const popperRef = React.useRef();\n const handleMouseMove = event => {\n const childrenProps = children.props;\n if (childrenProps.onMouseMove) {\n childrenProps.onMouseMove(event);\n }\n cursorPosition = {\n x: event.clientX,\n y: event.clientY\n };\n if (popperRef.current) {\n popperRef.current.update();\n }\n };\n const nameOrDescProps = {};\n const titleIsString = typeof title === 'string';\n if (describeChild) {\n nameOrDescProps.title = !open && titleIsString && !disableHoverListener ? title : null;\n nameOrDescProps['aria-describedby'] = open ? id : null;\n } else {\n nameOrDescProps['aria-label'] = titleIsString ? title : null;\n nameOrDescProps['aria-labelledby'] = open && !titleIsString ? id : null;\n }\n const childrenProps = _extends({}, nameOrDescProps, other, children.props, {\n className: clsx(other.className, children.props.className),\n onTouchStart: detectTouchStart,\n ref: handleRef\n }, followCursor ? {\n onMouseMove: handleMouseMove\n } : {});\n if (process.env.NODE_ENV !== 'production') {\n childrenProps['data-mui-internal-clone-element'] = true;\n\n // eslint-disable-next-line react-hooks/rules-of-hooks\n React.useEffect(() => {\n if (childNode && !childNode.getAttribute('data-mui-internal-clone-element')) {\n console.error(['MUI: The `children` component of the Tooltip is not forwarding its props correctly.', 'Please make sure that props are spread on the same element that the ref is applied to.'].join('\\n'));\n }\n }, [childNode]);\n }\n const interactiveWrapperListeners = {};\n if (!disableTouchListener) {\n childrenProps.onTouchStart = handleTouchStart;\n childrenProps.onTouchEnd = handleTouchEnd;\n }\n if (!disableHoverListener) {\n childrenProps.onMouseOver = composeEventHandler(handleMouseOver, childrenProps.onMouseOver);\n childrenProps.onMouseLeave = composeEventHandler(handleMouseLeave, childrenProps.onMouseLeave);\n if (!disableInteractive) {\n interactiveWrapperListeners.onMouseOver = handleMouseOver;\n interactiveWrapperListeners.onMouseLeave = handleMouseLeave;\n }\n }\n if (!disableFocusListener) {\n childrenProps.onFocus = composeEventHandler(handleFocus, childrenProps.onFocus);\n childrenProps.onBlur = composeEventHandler(handleBlur, childrenProps.onBlur);\n if (!disableInteractive) {\n interactiveWrapperListeners.onFocus = handleFocus;\n interactiveWrapperListeners.onBlur = handleBlur;\n }\n }\n if (process.env.NODE_ENV !== 'production') {\n if (children.props.title) {\n console.error(['MUI: You have provided a `title` prop to the child of .', `Remove this title prop \\`${children.props.title}\\` or the Tooltip component.`].join('\\n'));\n }\n }\n const popperOptions = React.useMemo(() => {\n var _PopperProps$popperOp;\n let tooltipModifiers = [{\n name: 'arrow',\n enabled: Boolean(arrowRef),\n options: {\n element: arrowRef,\n padding: 4\n }\n }];\n if ((_PopperProps$popperOp = PopperProps.popperOptions) != null && _PopperProps$popperOp.modifiers) {\n tooltipModifiers = tooltipModifiers.concat(PopperProps.popperOptions.modifiers);\n }\n return _extends({}, PopperProps.popperOptions, {\n modifiers: tooltipModifiers\n });\n }, [arrowRef, PopperProps]);\n const ownerState = _extends({}, props, {\n isRtl,\n arrow,\n disableInteractive,\n placement,\n PopperComponentProp,\n touch: ignoreNonTouchEvents.current\n });\n const classes = useUtilityClasses(ownerState);\n const PopperComponent = (_ref = (_slots$popper = slots.popper) != null ? _slots$popper : components.Popper) != null ? _ref : TooltipPopper;\n const TransitionComponent = (_ref2 = (_ref3 = (_slots$transition = slots.transition) != null ? _slots$transition : components.Transition) != null ? _ref3 : TransitionComponentProp) != null ? _ref2 : Grow;\n const TooltipComponent = (_ref4 = (_slots$tooltip = slots.tooltip) != null ? _slots$tooltip : components.Tooltip) != null ? _ref4 : TooltipTooltip;\n const ArrowComponent = (_ref5 = (_slots$arrow = slots.arrow) != null ? _slots$arrow : components.Arrow) != null ? _ref5 : TooltipArrow;\n const popperProps = appendOwnerState(PopperComponent, _extends({}, PopperProps, (_slotProps$popper = slotProps.popper) != null ? _slotProps$popper : componentsProps.popper, {\n className: clsx(classes.popper, PopperProps == null ? void 0 : PopperProps.className, (_ref6 = (_slotProps$popper2 = slotProps.popper) != null ? _slotProps$popper2 : componentsProps.popper) == null ? void 0 : _ref6.className)\n }), ownerState);\n const transitionProps = appendOwnerState(TransitionComponent, _extends({}, TransitionProps, (_slotProps$transition = slotProps.transition) != null ? _slotProps$transition : componentsProps.transition), ownerState);\n const tooltipProps = appendOwnerState(TooltipComponent, _extends({}, (_slotProps$tooltip = slotProps.tooltip) != null ? _slotProps$tooltip : componentsProps.tooltip, {\n className: clsx(classes.tooltip, (_ref7 = (_slotProps$tooltip2 = slotProps.tooltip) != null ? _slotProps$tooltip2 : componentsProps.tooltip) == null ? void 0 : _ref7.className)\n }), ownerState);\n const tooltipArrowProps = appendOwnerState(ArrowComponent, _extends({}, (_slotProps$arrow = slotProps.arrow) != null ? _slotProps$arrow : componentsProps.arrow, {\n className: clsx(classes.arrow, (_ref8 = (_slotProps$arrow2 = slotProps.arrow) != null ? _slotProps$arrow2 : componentsProps.arrow) == null ? void 0 : _ref8.className)\n }), ownerState);\n return /*#__PURE__*/_jsxs(React.Fragment, {\n children: [/*#__PURE__*/React.cloneElement(children, childrenProps), /*#__PURE__*/_jsx(PopperComponent, _extends({\n as: PopperComponentProp != null ? PopperComponentProp : Popper,\n placement: placement,\n anchorEl: followCursor ? {\n getBoundingClientRect: () => ({\n top: cursorPosition.y,\n left: cursorPosition.x,\n right: cursorPosition.x,\n bottom: cursorPosition.y,\n width: 0,\n height: 0\n })\n } : childNode,\n popperRef: popperRef,\n open: childNode ? open : false,\n id: id,\n transition: true\n }, interactiveWrapperListeners, popperProps, {\n popperOptions: popperOptions,\n children: ({\n TransitionProps: TransitionPropsInner\n }) => /*#__PURE__*/_jsx(TransitionComponent, _extends({\n timeout: theme.transitions.duration.shorter\n }, TransitionPropsInner, transitionProps, {\n children: /*#__PURE__*/_jsxs(TooltipComponent, _extends({}, tooltipProps, {\n children: [title, arrow ? /*#__PURE__*/_jsx(ArrowComponent, _extends({}, tooltipArrowProps, {\n ref: setArrowRef\n })) : null]\n }))\n }))\n }))]\n });\n});\nprocess.env.NODE_ENV !== \"production\" ? Tooltip.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the d.ts file and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * If `true`, adds an arrow to the tooltip.\n * @default false\n */\n arrow: PropTypes.bool,\n /**\n * Tooltip reference element.\n */\n children: elementAcceptingRef.isRequired,\n /**\n * Override or extend the styles applied to the component.\n */\n classes: PropTypes.object,\n /**\n * @ignore\n */\n className: PropTypes.string,\n /**\n * The components used for each slot inside.\n *\n * This prop is an alias for the `slots` prop.\n * It's recommended to use the `slots` prop instead.\n *\n * @default {}\n */\n components: PropTypes.shape({\n Arrow: PropTypes.elementType,\n Popper: PropTypes.elementType,\n Tooltip: PropTypes.elementType,\n Transition: PropTypes.elementType\n }),\n /**\n * The extra props for the slot components.\n * You can override the existing props or add new ones.\n *\n * This prop is an alias for the `slotProps` prop.\n * It's recommended to use the `slotProps` prop instead, as `componentsProps` will be deprecated in the future.\n *\n * @default {}\n */\n componentsProps: PropTypes.shape({\n arrow: PropTypes.object,\n popper: PropTypes.object,\n tooltip: PropTypes.object,\n transition: PropTypes.object\n }),\n /**\n * Set to `true` if the `title` acts as an accessible description.\n * By default the `title` acts as an accessible label for the child.\n * @default false\n */\n describeChild: PropTypes.bool,\n /**\n * Do not respond to focus-visible events.\n * @default false\n */\n disableFocusListener: PropTypes.bool,\n /**\n * Do not respond to hover events.\n * @default false\n */\n disableHoverListener: PropTypes.bool,\n /**\n * Makes a tooltip not interactive, i.e. it will close when the user\n * hovers over the tooltip before the `leaveDelay` is expired.\n * @default false\n */\n disableInteractive: PropTypes.bool,\n /**\n * Do not respond to long press touch events.\n * @default false\n */\n disableTouchListener: PropTypes.bool,\n /**\n * The number of milliseconds to wait before showing the tooltip.\n * This prop won't impact the enter touch delay (`enterTouchDelay`).\n * @default 100\n */\n enterDelay: PropTypes.number,\n /**\n * The number of milliseconds to wait before showing the tooltip when one was already recently opened.\n * @default 0\n */\n enterNextDelay: PropTypes.number,\n /**\n * The number of milliseconds a user must touch the element before showing the tooltip.\n * @default 700\n */\n enterTouchDelay: PropTypes.number,\n /**\n * If `true`, the tooltip follow the cursor over the wrapped element.\n * @default false\n */\n followCursor: PropTypes.bool,\n /**\n * This prop is used to help implement the accessibility logic.\n * If you don't provide this prop. It falls back to a randomly generated id.\n */\n id: PropTypes.string,\n /**\n * The number of milliseconds to wait before hiding the tooltip.\n * This prop won't impact the leave touch delay (`leaveTouchDelay`).\n * @default 0\n */\n leaveDelay: PropTypes.number,\n /**\n * The number of milliseconds after the user stops touching an element before hiding the tooltip.\n * @default 1500\n */\n leaveTouchDelay: PropTypes.number,\n /**\n * Callback fired when the component requests to be closed.\n *\n * @param {React.SyntheticEvent} event The event source of the callback.\n */\n onClose: PropTypes.func,\n /**\n * Callback fired when the component requests to be open.\n *\n * @param {React.SyntheticEvent} event The event source of the callback.\n */\n onOpen: PropTypes.func,\n /**\n * If `true`, the component is shown.\n */\n open: PropTypes.bool,\n /**\n * Tooltip placement.\n * @default 'bottom'\n */\n placement: PropTypes.oneOf(['bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n /**\n * The component used for the popper.\n * @default Popper\n */\n PopperComponent: PropTypes.elementType,\n /**\n * Props applied to the [`Popper`](/material-ui/api/popper/) element.\n * @default {}\n */\n PopperProps: PropTypes.object,\n /**\n * The extra props for the slot components.\n * You can override the existing props or add new ones.\n *\n * This prop is an alias for the `componentsProps` prop, which will be deprecated in the future.\n *\n * @default {}\n */\n slotProps: PropTypes.shape({\n arrow: PropTypes.object,\n popper: PropTypes.object,\n tooltip: PropTypes.object,\n transition: PropTypes.object\n }),\n /**\n * The components used for each slot inside.\n *\n * This prop is an alias for the `components` prop, which will be deprecated in the future.\n *\n * @default {}\n */\n slots: PropTypes.shape({\n arrow: PropTypes.elementType,\n popper: PropTypes.elementType,\n tooltip: PropTypes.elementType,\n transition: PropTypes.elementType\n }),\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Tooltip title. Zero-length titles string, undefined, null and false are never displayed.\n */\n title: PropTypes.node,\n /**\n * The component used for the transition.\n * [Follow this guide](/material-ui/transitions/#transitioncomponent-prop) to learn more about the requirements for this component.\n * @default Grow\n */\n TransitionComponent: PropTypes.elementType,\n /**\n * Props applied to the transition element.\n * By default, the element is based on this [`Transition`](http://reactcommunity.org/react-transition-group/transition/) component.\n */\n TransitionProps: PropTypes.object\n} : void 0;\nexport default Tooltip;","import '@/components/mui/menu-item.component.css';\nimport ArrowRightIcon from '@mui/icons-material/ArrowRight';\nimport {\n ListItemIcon as MuiListItemIcon,\n ListItemText as MuiListItemText,\n MenuItem as MuiMenuItem,\n} from '@mui/material';\nimport Tooltip from '@mui/material/Tooltip';\nimport { Localized, ReferencedItem, SingleColumnMenu } from 'platform-bible-utils';\nimport { MouseEvent, PropsWithChildren } from 'react';\n\ntype MenuItemInfoBase = {\n /** Text (displayable in the UI) as the name of the menu item */\n label: string;\n /** Text to display when the mouse hovers over the menu item */\n tooltip?: string;\n};\n\nexport type Command = MenuItemInfoBase & {\n /** Command to execute (string.string) */\n command: string;\n};\n\ntype SubMenu = MenuItemInfoBase & {\n /** Command to execute (string.string) */\n items: MenuItemInfo[];\n};\n\nexport interface CommandHandler {\n (command: Command): void;\n}\n\nexport type MenuPropsBase = {\n /*\n * The JSON defining the menu whose items are to be rendered. This will typically be one of the\n * menus in the \"defs\" in a Platform.Bible menu (see PlatformMenus). The schema for this is\n * menuDocumentSchema (at the end of menus.model.ts). Note that while this is a\n * \"SingleColumnMenu\", somewhat bizarrely, a MultiColumnMenu is a SingleColumnMenu, so it really\n * could be a MultiColumnMenu, in which case, column had better be defined so it can be used\n * to filter out the actual groups and items to display on the column.\n */\n menuDefinition: Localized;\n\n commandHandler: CommandHandler;\n\n /**\n * Additional action to perform when any menu item is clicked. Allows the caller to handle event\n * (e.g., to close the menu).\n */\n onClick?: (event: MouseEvent) => void;\n};\n\nexport type MenuItemListProps = MenuPropsBase & {\n /** Optional unique (column) identifier */\n columnId?: ReferencedItem;\n};\n\nexport type MenuItemProps = Omit &\n PropsWithChildren<{\n /** Optional unique identifier */\n id?: string;\n\n onClick: (event: MouseEvent) => void;\n }>;\n\ntype MenuItemInfo = (Command | SubMenu) & {\n /**\n * If specified, menu item will be inset if it does not have a leading icon.\n *\n * @default true\n */\n allowForLeadingIcons?: boolean;\n /**\n * If specified, the path to the icon image to display on the leading side of the menu text.\n *\n * @default undefined (no leading icon will be shown)\n */\n iconPathBefore?: string;\n /**\n * If specified, the path to the icon image to display on the trailing side of the menu text.\n *\n * @default undefined (no trailing icon will be shown)\n */\n iconPathAfter?: string;\n /**\n * If true, list item is focused during the first mount\n *\n * @default false\n */\n hasAutoFocus?: boolean;\n\n /** Additional css classes to help with unique styling of the menu item */\n className?: string;\n\n /**\n * If true, the menu item will appear disabled and it will not respond to clicks or mouse hovers.\n *\n * @default false\n */\n isDisabled?: boolean;\n\n /**\n * If true, compact vertical padding designed for keyboard and mouse input is used.\n *\n * @default true\n */\n isDense?: boolean;\n\n /**\n * If true, a right-arrow icon will be displayed (iconPathAfter, if specified, will be ignored).\n *\n * @default false\n */\n isSubMenuParent?: boolean;\n\n /**\n * If true, the left and right padding is removed\n *\n * @default false\n */\n hasDisabledGutters?: boolean;\n\n /**\n * If true, a 1px light border is added to bottom of menu item\n *\n * @default false\n */\n hasDivider?: boolean;\n\n /** Help identify which element has keyboard focus */\n focusVisibleClassName?: string;\n\n /** If it's a submenu, it should have the items property */\n items?: MenuItemInfo[];\n};\n\nfunction getIcon(icon: string | undefined, menuLabel: string, leading: boolean) {\n return icon ? (\n \n {`${leading\n \n ) : undefined;\n}\n\nexport default function MenuItem(props: MenuItemProps) {\n const {\n onClick,\n label,\n tooltip,\n allowForLeadingIcons = true,\n iconPathBefore = undefined,\n iconPathAfter = undefined,\n hasAutoFocus = false,\n className,\n isDisabled = false,\n isDense = true,\n isSubMenuParent = false,\n hasDisabledGutters = false,\n hasDivider = false,\n focusVisibleClassName,\n id,\n children,\n } = props;\n\n const menuItem = (\n \n {label ? (\n <>\n {getIcon(iconPathBefore, label, true)}\n \n {isSubMenuParent ? (\n \n \n \n ) : (\n getIcon(iconPathAfter, label, false)\n )}\n \n ) : (\n children\n )}\n \n );\n\n return tooltip ? (\n \n
    {menuItem}
    \n
    \n ) : (\n menuItem\n );\n}\n","import MenuItem, {\n MenuItemListProps,\n MenuItemProps,\n MenuPropsBase,\n} from '@/components/mui/menu-item.component';\nimport { Menu } from '@mui/material';\nimport {\n Localized,\n MenuGroupDetailsInSubMenu,\n MenuItemContainingCommand,\n MenuItemContainingSubmenu,\n OrderedExtensibleContainer,\n ReferencedItem,\n SingleColumnMenu,\n} from 'platform-bible-utils';\nimport { MouseEvent, useMemo, useState } from 'react';\n\n/**\n * All the exported types in this file should be regarded as \"internal\" (i.e., they should not be\n * exposed via index.ts).\n */\n\nexport type GroupedMenuPropsBase = MenuPropsBase & {\n /** Optional unique (column) identifier */\n columnId?: ReferencedItem;\n};\n\nexport type GroupedMenuItemListProps = MenuItemListProps & {\n /**\n * If the menuDefinition includes \"top-level\" groups (i.e., those that belong to a column as\n * opposed to those that belong to a submenu) that should not be included in the list, then this\n * array specifies which groups to include. Likewise, for a submenu, this list indicates which\n * groups are pertinent for that submenu. So then for a context menu this property need not be\n * specified since it is a top-level menu based on a \"true\" SingleColumnMenu (i.e., one that is\n * not a MultiColumnMenu).\n */\n includedGroups?: {\n id: string;\n group: Localized;\n }[];\n};\n\ninterface ItemInfo {\n item: Localized;\n isLastItemInGroup: boolean;\n}\n\ntype SubMenuProps = MenuPropsBase & {\n parentMenuItem: Localized;\n parentItemProps: Omit, 'iconPathAfter'>;\n};\n\nfunction getAllGroups(menuDefinition: Localized) {\n const groupEntries = Object.entries(menuDefinition.groups);\n // Convert array of entries to array of objects with id and group properties\n return groupEntries.map(([key, value]) => ({ id: key, group: value }));\n}\n\nfunction SubMenu(props: SubMenuProps) {\n const [anchorEl, setAnchorEl] = useState(undefined);\n\n const { parentMenuItem, parentItemProps, menuDefinition } = props;\n\n const handleParentMenuItemClick = (event: MouseEvent) => {\n setAnchorEl(event.currentTarget);\n };\n\n const handleClose = () => {\n setAnchorEl(undefined);\n };\n\n const renderSubMenuItems = () => {\n let includedGroups = getAllGroups(menuDefinition).filter((g) => 'menuItem' in g.group);\n\n // Ensure valid parent menu was provided. (If not, submenu will contain all groups!)\n if (!parentMenuItem?.id) throw new Error('A valid parent menu item is required for submenus.');\n\n // When laying out a submenu, only include groups associated with the provided parent menu.\n // Note: without the (annoying) redundant check that the included groups\n // have the menuItem field, TS doesn't think it exists.\n includedGroups = includedGroups.filter(\n (group) => 'menuItem' in group.group && group.group.menuItem === parentMenuItem.id,\n );\n\n return ;\n };\n\n return (\n <>\n \n \n {renderSubMenuItems()}\n \n \n );\n}\n\nconst getOrderedGroupItems = (\n groupId: string,\n allItems: Localized[],\n) => {\n // Filter items that belong to the specified group\n const itemsForGroup = allItems.filter((item) => item.group === groupId);\n // Sort items based on order\n const sortedItems = itemsForGroup.sort((a, b) => (a.order || 0) - (b.order || 0));\n return sortedItems;\n};\n\n/**\n * This component is internal; it does not need to be exposed to the outside world since it is not\n * useful on its own. It is used to generate and lay out the MenuItems that appear either on a\n * top-level menu (in a GridMenu or ContextMenu) or in a submenu.\n */\nexport default function GroupedMenuItemList(menuProps: GroupedMenuItemListProps) {\n const { menuDefinition, onClick, commandHandler, includedGroups } = menuProps;\n\n const { items, allowForLeadingIcons } = useMemo(() => {\n const groupsToInclude =\n includedGroups && includedGroups.length > 0\n ? includedGroups\n : // We're apparently laying out a single-column menu (presumably a context menu). In this\n // case, all groups should be included except ones that belong to a submenu.\n getAllGroups(menuDefinition).filter((g) => !('menuItem' in g.group));\n\n const sortedGroups = Object.values(groupsToInclude).sort(\n (a, b) => (a.group.order || 0) - (b.group.order || 0),\n );\n\n const itemArray: ItemInfo[] = [];\n\n sortedGroups.forEach((group) => {\n getOrderedGroupItems(group.id, menuDefinition.items).forEach((item) =>\n itemArray.push({ item, isLastItemInGroup: false }),\n );\n if (itemArray.length > 0) itemArray[itemArray.length - 1].isLastItemInGroup = true;\n });\n\n // No divider after last item in final group.\n if (itemArray.length > 0) itemArray[itemArray.length - 1].isLastItemInGroup = false;\n\n const allowSpaceForLeadingIcons = itemArray.some(\n (i) => 'iconPathBefore' in i.item && i.item.iconPathBefore,\n );\n\n return { items: itemArray, allowForLeadingIcons: allowSpaceForLeadingIcons };\n }, [includedGroups, menuDefinition]);\n\n // Create props for MenuItem component including setting hasDivider for the last item in a group\n const createMenuItemProps = ({ item, isLastItemInGroup }: ItemInfo) => {\n const menuItemProps = {\n className: 'papi-menu-item',\n label: item.label,\n tooltip: item.tooltip,\n iconPathBefore: 'iconPathBefore' in item ? item.iconPathBefore : undefined,\n iconPathAfter: 'iconPathAfter' in item ? item.iconPathAfter : undefined,\n hasDivider: isLastItemInGroup, // Set hasDivider to true for the last item in a group\n allowForLeadingIcons,\n };\n\n return menuItemProps;\n };\n\n const [firstItem] = items;\n\n if (!firstItem) return
    ;\n\n const divKey = firstItem.item.group;\n\n return (\n
    \n {items.map((itemInfo, index) => {\n const { item } = itemInfo;\n const menuItemProps = createMenuItemProps(itemInfo);\n if ('command' in item) {\n const key = item.group + index;\n return (\n ) => {\n onClick?.(event);\n commandHandler(item);\n }}\n {...menuItemProps}\n />\n );\n }\n return (\n \n );\n })}\n
    \n );\n}\n","import GroupedMenuItemList from '@/components/mui/grouped-menu-item-list.component';\nimport { MenuItemListProps } from '@/components/mui/menu-item.component';\nimport { MultiColumnMenu } from 'platform-bible-utils';\n\n/**\n * This component is internal; it does not need to be exposed to the outside world since it is not\n * useful on its own. Use either GridMenu or ContextMenu.\n */\nexport default function TopLevelMenu(props: MenuItemListProps) {\n const { menuDefinition, columnId } = props;\n\n const groupEntries = Object.entries(menuDefinition.groups);\n // Convert array of entries to array of objects with id and group properties\n const groups = groupEntries.map(([key, value]) => ({ id: key, group: value }));\n let includedGroups = groups.filter((g) => 'column' in g.group);\n\n // Check if column is provided and menuDefinition is a MultiColumnMenu\n if (\n columnId &&\n 'columns' in menuDefinition &&\n // Without this type assertion, TS doesn't know what columns is.\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n (menuDefinition as MultiColumnMenu).columns[columnId]\n ) {\n // When laying out a single column in a MultiColumnMenu, only include groups associated with\n // the provided column. Note: without the (annoying) redundant check that the included groups\n // have the colum field, TS doesn't think it exists.\n includedGroups = includedGroups.filter(\n (g) => 'column' in g.group && g.group.column === columnId,\n );\n }\n\n return ;\n}\n","import '@/components/mui/grid-menu.component.css';\nimport { GroupedMenuPropsBase } from '@/components/mui/grouped-menu-item-list.component';\nimport { CommandHandler } from '@/components/mui/menu-item.component';\nimport TopLevelMenu from '@/components/mui/top-level-menu.component';\nimport { Grid, List } from '@mui/material';\nimport {\n Localized,\n MenuColumnWithHeader,\n MultiColumnMenu,\n ReferencedItem,\n} from 'platform-bible-utils';\nimport { useMemo } from 'react';\n\ntype ColumnInfo = {\n /*\n * The ID (`${string}.${string}`) of a specific menu column.\n */\n id: ReferencedItem;\n\n /*\n * Metadata (label, order, etc.) for a specific menu column.\n */\n metadata: Localized;\n};\n\ntype MenuColumnProps = ColumnInfo &\n GroupedMenuPropsBase & {\n /** Additional css classes to help with unique styling of the menu column */\n className?: string;\n };\n\nexport type GridMenuInfo = {\n /** The menu object containing information about the columns, groups, and items to display. */\n multiColumnMenu: Localized;\n};\n\nexport type GridMenuProps = GridMenuInfo & {\n /** Optional unique identifier */\n id?: string;\n\n commandHandler: CommandHandler;\n\n /** Additional css classes to help with unique styling of the grid menu */\n className?: string;\n};\n\nfunction MenuColumn({\n commandHandler,\n menuDefinition,\n id,\n metadata,\n onClick,\n className,\n}: MenuColumnProps) {\n return (\n \n

    \n {metadata.label}\n

    \n {/* It would seem as though this List component were unnecessary, since it only contains one\n thing, but the \"dense\" property does affect the layout of the items (in a way I don't fully\n understand). There might be a better way. */}\n \n \n \n \n );\n}\n\nexport default function GridMenu({\n commandHandler,\n className,\n multiColumnMenu,\n id,\n}: GridMenuProps) {\n const { columns } = multiColumnMenu;\n\n const sortedColumns = useMemo(() => {\n const columnNumbers = new Map();\n Object.getOwnPropertyNames(columns).forEach((columnName: string) => {\n // We know for sure there is a (boolean) property 'isExtensible' that we are not interested in.\n if (columnName === 'isExtensible') return;\n // TS doesn't allow `columnName` above to be a ReferencedItem even though the type says it is\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const columnId = columnName as ReferencedItem;\n const column = columns[columnId];\n // As of right now (and hopefully forever after), all remaining properties of the\n // ColumnsWithHeaders object are columns whose property names are the IDs of the columns.\n // This is an additional (redundant) sanity check. Specifically we're interested in\n // MenuColumnWithHeader objects, which TypeScript now \"knows\" we have, but at runtime all we\n // can check for is that it's an object with a valid numeric order field. That's likely good\n // enough.\n if (\n typeof column === 'object' &&\n typeof column.order === 'number' &&\n !Number.isNaN(column.order)\n )\n columnNumbers.set(column.order, { id: columnId, metadata: column });\n else\n console.warn(\n `Property ${columnName} (${typeof column}) on menu ${id} is not a valid column and is being ignored. This might indicate data corruption`,\n );\n });\n\n // Extract values and sort them based on the 'order' property\n return Array.from(columnNumbers.values()).sort((a, b) => {\n return (a.metadata.order || 0) - (b.metadata.order || 0);\n });\n }, [columns, id]);\n\n // We might need something like this if we need to be able to prevent empty columns\n // sortedColumns.filter((c) => multiColumnMenu.groups.some((g) => 'column' in g && (g as .column)...\n\n return (\n \n {sortedColumns.map((col, index) => (\n \n ))}\n \n );\n}\n","import { useEffect, useRef, useState } from 'react';\n\nexport type UsePromiseOptions = {\n /**\n * Whether to leave the value as the most recent resolved promise value or set it back to\n * defaultValue while running the promise again. Defaults to true\n */\n preserveValue?: boolean;\n};\n\n/** Set up defaults for options for usePromise hook */\nfunction getUsePromiseOptionsDefaults(options: UsePromiseOptions): UsePromiseOptions {\n return {\n preserveValue: true,\n ...options,\n };\n}\n\n/**\n * Awaits a promise and returns a loading value while the promise is unresolved\n *\n * @param promiseFactoryCallback A function that returns the promise to await. If this callback is\n * undefined, the current value will be returned (defaultValue unless it was previously changed\n * and `options.preserveValue` is true), and there will be no loading.\n *\n * WARNING: MUST BE STABLE - const or wrapped in useCallback. The reference must not be updated\n * every render\n * @param defaultValue The initial value to return while first awaiting the promise. If\n * `options.preserveValue` is false, this value is also shown while awaiting the promise on\n * subsequent calls.\n *\n * Note: this parameter is internally assigned to a `ref`, so changing it will not cause any hooks\n * to re-run with its new value. This means that, if the `promiseFactoryCallback` changes and\n * `options.preserveValue` is `false`, the returned value will be set to the current\n * `defaultValue`. However, the returned value will not be updated if`defaultValue` changes.\n * @param options Various options for adjusting how this hook runs the `promiseFactoryCallback`\n *\n * Note: this parameter is internally assigned to a `ref`, so changing it will not cause any hooks\n * to re-run with its new value. However, the latest `options.preserveValue` will always be used\n * appropriately to determine whether to preserve the returned value when changing the\n * `promiseFactoryCallback`\n * @returns `[value, isLoading]`\n *\n * - `value`: the current value for the promise, either the defaultValue or the resolved promise value\n * - `isLoading`: whether the promise is waiting to be resolved\n */\nconst usePromise = (\n promiseFactoryCallback: (() => Promise) | undefined,\n defaultValue: T,\n options: UsePromiseOptions = {},\n): [value: T, isLoading: boolean] => {\n // Use defaultValue as a ref so it doesn't update dependency arrays\n const defaultValueRef = useRef(defaultValue);\n defaultValueRef.current = defaultValue;\n // Use options as a ref so it doesn't update dependency arrays\n const optionsDefaultedRef = useRef(options);\n optionsDefaultedRef.current = getUsePromiseOptionsDefaults(optionsDefaultedRef.current);\n\n const [value, setValue] = useState(() => defaultValueRef.current);\n const [isLoading, setIsLoading] = useState(true);\n useEffect(() => {\n let promiseIsCurrent = true;\n // If a promiseFactoryCallback was provided, we are loading. Otherwise, there is no loading to do\n setIsLoading(!!promiseFactoryCallback);\n (async () => {\n // If there is a callback to run, run it\n if (promiseFactoryCallback) {\n const result = await promiseFactoryCallback();\n // If the promise was not already replaced, update the value\n if (promiseIsCurrent) {\n setValue(() => result);\n setIsLoading(false);\n }\n }\n })();\n\n return () => {\n // Mark this promise as old and not to be used\n promiseIsCurrent = false;\n if (!optionsDefaultedRef.current.preserveValue) setValue(() => defaultValueRef.current);\n };\n }, [promiseFactoryCallback]);\n\n return [value, isLoading];\n};\nexport default usePromise;\n","\"use client\";\n\nimport createSvgIcon from './utils/createSvgIcon';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nexport default createSvgIcon( /*#__PURE__*/_jsx(\"path\", {\n d: \"M3 18h18v-2H3zm0-5h18v-2H3zm0-7v2h18V6z\"\n}), 'Menu');","import GridMenu from '@/components/mui/grid-menu.component';\nimport { Command, CommandHandler } from '@/components/mui/menu-item.component';\nimport usePromise from '@/hooks/use-promise.hook';\nimport { Menu as MenuIcon } from '@mui/icons-material';\nimport { Drawer, IconButton } from '@mui/material';\nimport { Localized, MultiColumnMenu } from 'platform-bible-utils';\nimport {\n MouseEvent,\n MutableRefObject,\n PropsWithChildren,\n useCallback,\n useEffect,\n useState,\n} from 'react';\n\nexport interface MultiColumnMenuProvider {\n (isSupportAndDevelopment: boolean): Promise>;\n}\n\nexport type HamburgerMenuButtonProps = PropsWithChildren & {\n /** The handler to use for menu commands (and eventually toolbar commands). */\n commandHandler: CommandHandler;\n\n /**\n * Optional reference to the \"div\" container that determines the where the menu should appear. If\n * not defined, then (1,1) used.\n */\n containerRef?: MutableRefObject;\n\n /**\n * The delegate to use to get the menu data. If not specified or if it returns undefined, the data\n * in normalMenu or fullMenu property will be used.\n */\n menuProvider?: MultiColumnMenuProvider;\n\n /**\n * The menu data to show when the menu is opened if the menuProvider property is not defined.\n * (This allows for a default or test-only static menu to be used.)\n */\n normalMenu?: Localized;\n\n /**\n * The menu data to show for \"full\" menu (when opened with the SHIFT key pressed) if the\n * menuProvider property is not defined. (This allows for a default or test-only static menu to be\n * used.)\n */\n fullMenu?: Localized;\n\n /** Additional css class(es) to help with unique styling of the sub-components */\n className?: string;\n\n /** Value to use as prefix for ARIA labels on interactive sub-components */\n ariaLabelPrefix?: string;\n};\n\nexport default function HamburgerMenuButton({\n menuProvider,\n normalMenu,\n fullMenu,\n commandHandler,\n containerRef,\n className,\n ariaLabelPrefix,\n children,\n}: HamburgerMenuButtonProps) {\n const [isMenuOpen, setMenuOpen] = useState(false);\n const [showFullMenu, setShowFullMenu] = useState(false);\n\n const handleMenuItemClick = useCallback(() => {\n if (isMenuOpen) setMenuOpen(false);\n setShowFullMenu(false);\n }, [isMenuOpen]);\n\n const handleMenuButtonClick = useCallback((e: MouseEvent) => {\n e.stopPropagation();\n setMenuOpen((prevIsOpen) => {\n const isOpening = !prevIsOpen;\n if (isOpening && e.shiftKey) setShowFullMenu(true);\n else if (!isOpening) setShowFullMenu(false);\n return isOpening;\n });\n }, []);\n\n const menuCommandHandler = useCallback(\n (command: Command) => {\n handleMenuItemClick();\n return commandHandler(command);\n },\n [commandHandler, handleMenuItemClick],\n );\n\n const [offset, setOffset] = useState({ top: 1, left: 1 });\n\n useEffect(() => {\n if (isMenuOpen) {\n const node = containerRef?.current;\n if (node) {\n const rect = node.getBoundingClientRect();\n const scrollTop = window.scrollY;\n const scrollLeft = window.scrollX;\n const top = rect.top + scrollTop + node.clientHeight;\n const left = rect.left + scrollLeft;\n setOffset({ top, left });\n }\n }\n }, [isMenuOpen, containerRef]);\n\n const [normalMenuData] = usePromise(\n useCallback(async () => {\n return menuProvider?.(false) ?? normalMenu;\n // isMenuOpen needs to be included for the menu contents to reevaluate when reopened\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [menuProvider, normalMenu, isMenuOpen]),\n normalMenu,\n );\n\n const [fullMenuData] = usePromise(\n useCallback(async () => {\n return menuProvider?.(true) ?? fullMenu ?? normalMenuData;\n // isMenuOpen needs to be included for the menu contents to reevaluate when reopened\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [menuProvider, fullMenu, normalMenuData, isMenuOpen]),\n fullMenu ?? normalMenuData,\n );\n\n const menu = showFullMenu && fullMenuData ? fullMenuData : normalMenuData;\n\n return (\n <>\n \n {children ?? }\n \n \n {menu ? (\n \n ) : undefined}\n \n \n );\n}\n","import '@/components/mui/icon-button.component.css';\nimport { IconButton as MuiIconButton } from '@mui/material';\nimport { MouseEventHandler, PropsWithChildren } from 'react';\n\nexport type IconButtonProps = PropsWithChildren<{\n /** Optional unique identifier */\n id?: string;\n /**\n * Required. Used as both the tooltip (aka, title) and the aria-label (used for accessibility,\n * testing, etc.), unless a distinct tooltip is supplied.\n */\n label: string;\n /**\n * Enabled status of button\n *\n * @default false\n */\n isDisabled?: boolean;\n /** Optional tooltip to display if different from the aria-label. */\n tooltip?: string;\n /** If true, no tooltip will be displayed. */\n isTooltipSuppressed?: boolean;\n /**\n * If given, uses a negative margin to counteract the padding on one side (this is often helpful\n * for aligning the left or right side of the icon with content above or below, without ruining\n * the border size and shape).\n *\n * @default false\n */\n adjustMarginToAlignToEdge?: 'end' | 'start' | false;\n /**\n * The size of the component. small is equivalent to the dense button styling.\n *\n * @default false\n */\n size: 'small' | 'medium' | 'large';\n /** Additional css classes to help with unique styling of the button */\n className?: string;\n /** Optional click handler */\n onClick?: MouseEventHandler;\n}>;\n\n/**\n * Iconic button a user can click to do something\n *\n * Thanks to MUI for heavy inspiration and documentation\n * https://mui.com/material-ui/getting-started/overview/\n */\nfunction IconButton({\n id,\n label,\n isDisabled = false,\n tooltip,\n isTooltipSuppressed = false,\n adjustMarginToAlignToEdge = false,\n size = 'medium',\n className,\n onClick,\n children,\n}: IconButtonProps) {\n return (\n \n {children /* the icon to display */}\n \n );\n}\n\nexport default IconButton;\n","import { cn } from '@/utils/shadcn-ui.util';\nimport { LoaderCircle, LucideProps } from 'lucide-react';\nimport { forwardRef } from 'react';\n\nexport type SpinnerProps = LucideProps;\n\nconst Spinner = forwardRef(({ className, ...props }, ref) => {\n return (\n \n );\n});\n\nSpinner.displayName = 'Spinner';\n\nexport default Spinner;\n","import { Input as ShadInput } from '@/components/shadcn-ui/input';\nimport { Label as ShadLabel } from '@/components/shadcn-ui/label';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { ChangeEventHandler, FocusEventHandler } from 'react';\n\nexport type TextFieldProps = {\n /** Optional unique identifier */\n id?: string;\n /**\n * If `true`, the component is disabled.\n *\n * @default false\n */\n isDisabled?: boolean;\n /**\n * If `true`, the label is displayed in an error state.\n *\n * @default false\n */\n hasError?: boolean;\n /**\n * If `true`, the input will take up the full width of its container.\n *\n * @default false\n */\n isFullWidth?: boolean;\n /** Text that gives the user instructions on what contents the TextField expects */\n helperText?: string;\n /** The title of the TextField */\n label?: string;\n /** The short hint displayed in the `input` before the user enters a value. */\n placeholder?: string;\n /**\n * If `true`, the label is displayed as required and the `input` element is required.\n *\n * @default false\n */\n isRequired?: boolean;\n /** Additional css classes to help with unique styling of the text field */\n className?: string;\n /** Starting value for the text field if it is not controlled */\n defaultValue?: string | number;\n /** Value of the text field if controlled */\n value?: string | number;\n /** Triggers when content of textfield is changed */\n onChange?: ChangeEventHandler;\n /** Triggers when textfield gets focus */\n onFocus?: FocusEventHandler;\n /** Triggers when textfield loses focus */\n onBlur?: FocusEventHandler;\n};\n\n/**\n * Text input field\n *\n * Thanks to Shadcn for heavy inspiration and documentation\n * https://ui.shadcn.com/docs/components/input#with-label\n */\nfunction TextField({\n id,\n isDisabled = false,\n hasError = false,\n isFullWidth = false,\n helperText,\n label,\n placeholder,\n isRequired = false,\n className,\n defaultValue,\n value,\n onChange,\n onFocus,\n onBlur,\n}: TextFieldProps) {\n return (\n
    \n {`${label}${isRequired ? '*' : ''}`}\n \n

    {helperText}

    \n
    \n );\n}\n\nexport default TextField;\n","import HamburgerMenuButton, {\n MultiColumnMenuProvider,\n} from '@/components/mui/hamburger-menu-button.component';\nimport { CommandHandler } from '@/components/mui/menu-item.component';\nimport '@/components/mui/toolbar.component.css';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { AppBar, Toolbar as MuiToolbar } from '@mui/material';\nimport { PropsWithChildren, useRef } from 'react';\n\nexport type ToolbarProps = PropsWithChildren<{\n /** The handler to use for menu commands (and eventually toolbar commands). */\n commandHandler: CommandHandler;\n\n /**\n * The optional delegate to use to get the menu data. If not specified, the \"hamburger\" menu will\n * not display.\n */\n menuProvider?: MultiColumnMenuProvider;\n\n /** Optional unique identifier */\n id?: string;\n\n /** Additional css classes to help with unique styling of the toolbar */\n className?: string;\n}>;\n\nexport default function Toolbar({\n menuProvider,\n commandHandler,\n className,\n id,\n children,\n}: ToolbarProps) {\n // This ref will always be defined\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const containerRef = useRef(undefined!);\n\n return (\n
    \n \n \n {menuProvider ? (\n \n ) : undefined}\n {children ?
    {children}
    : undefined}\n \n
    \n
    \n );\n}\n","import React from 'react';\nimport { cva, type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst alertVariants = cva(\n 'tw-relative tw-w-full tw-rounded-lg tw-border tw-p-4 [&>svg~*]:tw-pl-7 [&>svg+div]:tw-translate-y-[-3px] [&>svg]:tw-absolute [&>svg]:tw-left-4 [&>svg]:tw-top-4 [&>svg]:tw-text-foreground',\n {\n variants: {\n variant: {\n default: 'tw-bg-background tw-text-foreground',\n destructive:\n 'tw-border-destructive/50 tw-text-destructive dark:tw-border-destructive [&>svg]:tw-text-destructive',\n },\n },\n defaultVariants: {\n variant: 'default',\n },\n },\n);\n\nconst Alert = React.forwardRef<\n HTMLDivElement,\n React.HTMLAttributes & VariantProps\n>(({ className, variant, ...props }, ref) => (\n
    \n));\nAlert.displayName = 'Alert';\n\nconst AlertTitle = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n {/* added because of https://github.com/jsx-eslint/eslint-plugin-jsx-a11y/blob/main/docs/rules/heading-has-content.md */}\n {props.children}{' '}\n \n ),\n);\nAlertTitle.displayName = 'AlertTitle';\n\nconst AlertDescription = React.forwardRef<\n HTMLParagraphElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n
    \n));\nAlertDescription.displayName = 'AlertDescription';\n\nexport { Alert, AlertTitle, AlertDescription };\n","import { ComponentProps } from 'react';\nimport { toast as sonner, Toaster } from 'sonner';\n\ntype SonnerProps = ComponentProps;\n\nfunction Sonner({ ...props }: SonnerProps) {\n return (\n \n );\n}\n\n// The re-export of the sonner function was added manually\nexport { Sonner, sonner };\n","import React from 'react';\nimport * as SliderPrimitive from '@radix-ui/react-slider';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Slider = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n \n \n \n));\nSlider.displayName = SliderPrimitive.Root.displayName;\n\nexport { Slider };\n","import React from 'react';\nimport * as SwitchPrimitives from '@radix-ui/react-switch';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Switch = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n));\nSwitch.displayName = SwitchPrimitives.Root.displayName;\n\nexport { Switch };\n","import React from 'react';\nimport * as TabsPrimitive from '@radix-ui/react-tabs';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport const Tabs = TabsPrimitive.Root;\n\nexport type TabsListProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport type TabsTriggerProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport type TabsContentProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport const TabsList = React.forwardRef<\n React.ElementRef,\n TabsListProps\n>(({ className, ...props }, ref) => (\n \n));\nTabsList.displayName = TabsPrimitive.List.displayName;\n\nexport const TabsTrigger = React.forwardRef<\n React.ElementRef,\n TabsTriggerProps\n>(({ className, ...props }, ref) => (\n \n));\nTabsTrigger.displayName = TabsPrimitive.Trigger.displayName;\n\nexport const TabsContent = React.forwardRef<\n React.ElementRef,\n TabsContentProps\n>(({ className, ...props }, ref) => (\n \n));\nTabsContent.displayName = TabsPrimitive.Content.displayName;\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Download } from 'lucide-react';\n\ntype InstallButtonProps = {\n /** The installing boolean value determines the state of the button. */\n isInstalling: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n /** Optional text for the button. */\n buttonText?: string;\n} & ButtonProps;\n\n/**\n * The InstallButton component is a button designed for initiating installs. It includes visuals for\n * active installing and idle states.\n *\n * @param isInstalling The installing boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @param buttonText Optional text for the button.\n * @returns A install button.\n */\nexport default function InstallButton({\n isInstalling,\n handleClick,\n buttonText,\n className,\n ...props\n}: InstallButtonProps) {\n return (\n \n {isInstalling ? (\n \n ) : (\n <>\n \n {buttonText}\n \n )}\n \n );\n}\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\n\ntype EnableButtonProps = {\n /** The enabling boolean value determines the state of the button. */\n isEnabling: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n} & ButtonProps;\n\n/**\n * The EnableButton component is a button designed for initiating enabling of downloads. It includes\n * visuals for active enabling and idle states.\n *\n * @param isEnabling The enabling boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @returns A button that can be used to enable.\n */\nexport default function EnableButton({\n isEnabling,\n handleClick,\n className,\n ...props\n}: EnableButtonProps) {\n return (\n \n {isEnabling ? (\n <>\n \n Enabling...\n \n ) : (\n 'Enable'\n )}\n \n );\n}\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\n\ntype DisableButtonProps = {\n /** The disabling boolean value determines the state of the button. */\n isDisabling: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n} & ButtonProps;\n\n/**\n * The DisableButton component is a button designed for initiating disabling of downloads. It\n * includes visuals for active disabling and idle states.\n *\n * @param isDisabling The disabling boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @returns A button that can be used to disable.\n */\nexport default function DisableButton({\n isDisabling,\n handleClick,\n className,\n ...props\n}: DisableButtonProps) {\n return (\n \n {isDisabling ? (\n <>\n \n Disabling...\n \n ) : (\n 'Disable'\n )}\n \n );\n}\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\n\ntype UpdateButtonProps = {\n /** The updating boolean value determines the state of the button. */\n isUpdating: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n} & ButtonProps;\n\n/**\n * The UpdateButton component is a button designed for initiating updates for downloaded extensions.\n * It includes visuals for active updating and idle states.\n *\n * @param isUpdating The updating boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @returns A button that can be used to update.\n */\nexport default function UpdateButton({\n isUpdating,\n handleClick,\n className,\n ...props\n}: UpdateButtonProps) {\n return (\n \n {isUpdating ? (\n <>\n \n Updating...\n \n ) : (\n 'Update'\n )}\n \n );\n}\n","import { cn } from '@/utils/shadcn-ui.util';\nimport Markdown, { MarkdownToJSX } from 'markdown-to-jsx';\nimport { useMemo } from 'react';\n\ninterface MarkdownRendererProps {\n /** Optional unique identifier */\n id?: string;\n /** The markdown string to render */\n markdown: string;\n className?: string;\n /**\n * The [`target` attribute for `a` html\n * tags](https://developer.mozilla.org/en-US/docs/Web/HTML/Element/a#target). Defaults to not\n * adding a `target` to `a` tags\n */\n anchorTarget?: string;\n}\n\n/**\n * This component renders markdown content given a markdown string. It uses typography styles from\n * the platform.\n *\n * @param markdown The markdown string to render.\n * @param id Optional unique identifier\n * @returns A div containing the rendered markdown content.\n */\nexport default function MarkdownRenderer({\n id,\n markdown,\n className,\n anchorTarget,\n}: MarkdownRendererProps) {\n const options: MarkdownToJSX.Options = useMemo(\n () => ({\n overrides: {\n a: {\n props: {\n target: anchorTarget,\n },\n },\n },\n }),\n [anchorTarget],\n );\n return (\n
    \n {markdown}\n
    \n );\n}\n","import { Filter, ChevronDown } from 'lucide-react';\nimport { forwardRef } from 'react';\nimport { Button } from '@/components/shadcn-ui/button';\n\n/**\n * The FilterButton component is a button designed for initiating filtering of data. It is designed\n * to be used with the dropdown menu. It uses forwardRef to pass the button to the dropdown trigger\n * asChild.\n *\n * @returns A button that can be used to filter.\n */\nconst FilterButton = forwardRef((props, ref) => {\n return (\n \n \n Filter\n \n \n );\n});\n\nexport default FilterButton;\n","import {\n DropdownMenu,\n DropdownMenuTrigger,\n DropdownMenuContent,\n DropdownMenuLabel,\n DropdownMenuGroup,\n DropdownMenuCheckboxItem,\n DropdownMenuRadioItem,\n DropdownMenuSeparator,\n} from '@/components/shadcn-ui/dropdown-menu';\nimport FilterButton from './buttons/filter-button.component';\n\nexport enum DropdownMenuItemType {\n Check,\n Radio,\n}\n\nexport type DropdownItem = {\n /** The label is the text that will be displayed on the dropdown item. */\n label: string;\n /** The itemType determines the DropdownMenuItemType type as either Check or Radio. */\n itemType: DropdownMenuItemType;\n /** The onClick function is called when the item is clicked. */\n onClick: () => void;\n};\n\nexport type DropdownGroup = {\n /**\n * The label is the text that will be displayed on the dropdown group. It is used to categorize\n * the items in the group.\n */\n label: string;\n /** The items array contains the items that will be displayed in the dropdown group */\n items: DropdownItem[];\n};\n\nexport type FilterDropdownProps = {\n /** Object unique identifier */\n id?: string;\n /** The groups array contains the groups that will be displayed in the dropdown */\n groups: DropdownGroup[];\n}; // TODO: extend the props later\n\n/**\n * The FilterDropdown component is a dropdown designed for filtering content. It includes groups of\n * items that can be checkboxes or radio items.\n *\n * @param id Optional unique identifier\n * @param groups The groups array contains the groups that will be displayed in the dropdown\n * @returns A filter dropdown.\n */\nexport default function FilterDropdown({ id, groups }: FilterDropdownProps) {\n return (\n
    \n {/* TODO: remove this once the DropDown Menu shadcn has an id prop */}\n \n \n \n \n \n {groups.map((group) => (\n
    \n {group.label}\n \n {group.items.map((item) => (\n
    \n {item.itemType === DropdownMenuItemType.Check ? (\n \n {item.label}\n \n ) : (\n \n {item.label}\n \n )}\n
    \n ))}\n
    \n \n
    \n ))}\n
    \n
    \n
    \n );\n}\n","interface NoExtensionsFoundProps {\n /** Optional unique identifier */\n id?: string;\n /** The message to display */\n message: string;\n}\n/**\n * This component displays a message to the user when no extensions are found in the marketplace.\n *\n * @param id Optional unique identifier\n * @param message The message to display.\n * @returns {JSX.Element} - Returns the message component that displays the message to the user.\n */\nexport default function NoExtensionsFound({ id, message }: NoExtensionsFoundProps) {\n return (\n
    \n
    \n

    {message}

    \n
    \n
    \n );\n}\n","import { CircleHelp, Link as LucideLink, User } from 'lucide-react';\nimport { NumberFormat } from 'platform-bible-utils';\n\n/** Interface that stores the parameters passed to the More Info component */\ninterface MoreInfoProps {\n /** Optional unique identifier */\n id?: string;\n /** The category of the extension */\n category: string;\n /** The number of downloads for the extension */\n downloads: Record;\n /** The languages supported by the extension */\n languages: string[];\n /** The URL to the more info page of the extension */\n moreInfoUrl: string;\n}\n/**\n * This component displays the more info section of the extension which includes the category,\n * number of downloads, languages, and links to the website and support\n *\n * @param id Optional unique identifier\n * @param category The category of the extension\n * @param downloads The number of downloads for the extension\n * @param languages The languages supported by the extension\n * @param moreInfoUrl The URL to the more info page of the extension\n * @returns {JSX.Element} - Returns the more info component that displays the category, number of\n * downloads, languages, and links to the website and support\n */\nexport default function MoreInfo({\n id,\n category,\n downloads,\n languages,\n moreInfoUrl,\n}: MoreInfoProps) {\n /**\n * This constant formats the number of downloads into a more readable format.\n *\n * @example 1000 -> 1K\n *\n * @example 1000000 -> 1M\n *\n * @returns The formatted number of downloads\n */\n const numberFormatted = new NumberFormat('en', {\n notation: 'compact',\n compactDisplay: 'short',\n }).format(Object.values(downloads).reduce((a: number, b: number) => a + b, 0));\n\n /** This function scrolls the window to the bottom of the page. */\n const handleScrollToBottom = () => {\n window.scrollTo(0, document.body.scrollHeight);\n };\n\n return (\n \n
    \n
    \n {category}\n
    \n CATEGORY\n
    \n
    \n
    \n
    \n \n {numberFormatted}\n
    \n USERS\n
    \n
    \n
    \n
    \n {languages.slice(0, 3).map((locale) => (\n \n {locale.toUpperCase()}\n \n ))}\n
    \n {languages.length > 3 && (\n handleScrollToBottom()}\n className=\"tw-text-xs tw-text-gray-500 tw-underline\"\n >\n +{languages.length - 3} more languages\n \n )}\n
    \n
    \n
    \n \n Website\n \n \n \n Support\n \n \n
    \n
    \n );\n}\n","import { useState } from 'react';\n\nexport type VersionInformation = {\n /** Date the version was published */\n date: string;\n /** Description of the changes in the version */\n description: string;\n};\n\n/** Type to store the version history information */\nexport type VersionHistoryType = Record;\n\n/** Interface that stores the parameters passed to the Version History component */\ninterface VersionHistoryProps {\n /** Optional unique identifier */\n id?: string;\n /** Object containing the versions mapped with their information */\n versionHistory: VersionHistoryType;\n}\n\n/**\n * Component to render the version history information shown in the footer component. Lists the 5\n * most recent versions, with the options to show all versions by pressing a button.\n *\n * @param versionHistory Object containing the versions mapped with their information\n * @param id Optional unique identifier\n * @returns Rendered version history for the Footer component\n */\nexport default function VersionHistory({ id, versionHistory }: VersionHistoryProps) {\n const [showAllVersions, setShowAllVersions] = useState(false);\n const currentDate = new Date();\n\n /**\n * Function to format the time string for the version history in the form of 'X year(s) ago'.\n *\n * @param dateString ISO Date string to determine the time string from\n * @returns Formatted time string\n */\n function formatTimeString(dateString: string) {\n const date = new Date(dateString);\n const dateDiff = new Date(currentDate.getTime() - date.getTime());\n const yearDiff = dateDiff.getUTCFullYear() - 1970;\n const monthDiff = dateDiff.getUTCMonth();\n const dayDiff = dateDiff.getUTCDate() - 1;\n\n // Determines how long ago the version was published\n let timeString = '';\n if (yearDiff > 0) {\n timeString = `${yearDiff.toString()} year${yearDiff === 1 ? '' : 's'} ago`;\n } else if (monthDiff > 0) {\n timeString = `${monthDiff.toString()} month${monthDiff === 1 ? '' : 's'} ago`;\n } else if (dayDiff === 0) {\n timeString = 'today';\n } else {\n timeString = `${dayDiff.toString()} day${dayDiff === 1 ? '' : 's'} ago`;\n }\n\n return timeString;\n }\n\n // Sorts the version history by version number\n const sortedEntries = Object.entries(versionHistory).sort((a, b) => b[0].localeCompare(a[0]));\n\n return (\n
    \n

    What`s New

    \n
      \n {(showAllVersions ? sortedEntries : sortedEntries.slice(0, 5)).map((entry) => (\n
      \n
      \n
    • \n {entry[1].description}\n
    • \n
      \n
      \n
      Version {entry[0]}
      \n
      {formatTimeString(entry[1].date)}
      \n
      \n
      \n ))}\n
    \n {sortedEntries.length > 5 && (\n setShowAllVersions(!showAllVersions)}\n className=\"tw-text-xs tw-text-gray-500 tw-underline\"\n >\n {showAllVersions ? 'Show Less Version History' : 'Show All Version History'}\n \n )}\n
    \n );\n}\n","import { useMemo } from 'react';\nimport { formatBytes } from 'platform-bible-utils';\nimport VersionHistory, { VersionHistoryType } from './version-history.component';\n\n/** Interface to store the parameters passed to the Footer component */\ninterface FooterProps {\n /** Optional unique identifier */\n id?: string;\n /** Name of the publisher */\n publisherDisplayName: string;\n /** Size of the extension file in bytes */\n fileSize: number;\n /** List of language codes supported by the extension */\n locales: string[];\n /** Object containing the version history mapped with their information */\n versionHistory: VersionHistoryType;\n}\n\n/**\n * Component to render the footer for the extension details which contains information on the\n * publisher, version history, languages, and file size.\n *\n * @param id Optional unique identifier\n * @param publisherDisplayName Name of the publisher\n * @param fileSize Size of the extension file in bytes\n * @param locales List of language codes supported by the extension\n * @param versionHistory Object containing the version history mapped with their information\n * @returns The rendered Footer component\n */\nexport default function Footer({\n id,\n publisherDisplayName,\n fileSize,\n locales,\n versionHistory,\n}: FooterProps) {\n /** Formats the file size into a human-readable format */\n const formattedFileSize = useMemo(() => formatBytes(fileSize), [fileSize]);\n\n /**\n * This function gets the display names of the languages based on the language codes.\n *\n * @param codes The list of language codes\n * @returns The list of language names\n */\n const getLanguageNames = (codes: string[]) => {\n const displayNames = new Intl.DisplayNames(navigator.language, { type: 'language' });\n return codes.map((code) => displayNames.of(code));\n };\n\n const languageNames = getLanguageNames(locales);\n\n return (\n
    \n
    \n \n
    \n
    \n

    Information

    \n
    \n

    \n Publisher\n {publisherDisplayName}\n Size\n {formattedFileSize}\n

    \n
    \n

    \n Languages\n {languageNames.join(', ')}\n

    \n
    \n
    \n
    \n
    \n
    \n );\n}\n","import { PlatformEvent, PlatformEventHandler } from 'platform-bible-utils';\nimport { useEffect } from 'react';\n\n/**\n * Adds an event handler to an event so the event handler runs when the event is emitted. Use\n * `papi.network.getNetworkEvent` to use a networked event with this hook.\n *\n * @param event The event to subscribe to.\n *\n * - If event is a `PlatformEvent`, that event will be used\n * - If event is undefined, the callback will not be subscribed. Useful if the event is not yet\n * available for example\n *\n * @param eventHandler The callback to run when the event is emitted\n *\n * WARNING: MUST BE STABLE - const or wrapped in useCallback. The reference must not be updated\n * every render\n */\nconst useEvent = (\n event: PlatformEvent | undefined,\n eventHandler: PlatformEventHandler,\n) => {\n useEffect(() => {\n // Do nothing if the event is not provided (in case the event is not yet available, for example)\n if (!event) return () => {};\n\n const unsubscriber = event(eventHandler);\n return () => {\n unsubscriber();\n };\n }, [event, eventHandler]);\n};\nexport default useEvent;\n","import { useCallback, useEffect } from 'react';\nimport { PlatformEvent, PlatformEventAsync, PlatformEventHandler } from 'platform-bible-utils';\nimport usePromise from './use-promise.hook';\n\nconst noopUnsubscriber = () => false;\n\n/**\n * Adds an event handler to an asynchronously subscribing/unsubscribing event so the event handler\n * runs when the event is emitted. Use `papi.network.getNetworkEvent` to use a networked event with\n * this hook.\n *\n * @param event The asynchronously (un)subscribing event to subscribe to.\n *\n * - If event is a `PlatformEvent` or `PlatformEventAsync`, that event will be used\n * - If event is undefined, the callback will not be subscribed. Useful if the event is not yet\n * available for example\n *\n * @param eventHandler The callback to run when the event is emitted\n *\n * WARNING: MUST BE STABLE - const or wrapped in useCallback. The reference must not be updated\n * every render\n */\nconst useEventAsync = (\n event: PlatformEvent | PlatformEventAsync | undefined,\n eventHandler: PlatformEventHandler,\n) => {\n // Subscribe to the event asynchronously\n const [unsubscribe] = usePromise(\n useCallback(async () => {\n // Do nothing if the event is not provided (in case the event is not yet available, for example)\n if (!event) return noopUnsubscriber;\n\n // Wrap subscribe and unsubscribe in promises to allow normal events to be used as well\n const unsub = await Promise.resolve(event(eventHandler));\n return async () => unsub();\n }, [eventHandler, event]),\n noopUnsubscriber,\n // We want the unsubscriber to return to default value immediately upon changing subscription\n // So the useEffect below will unsubscribe asap\n { preserveValue: false },\n );\n\n // Unsubscribe from the event asynchronously (but we aren't awaiting the unsub)\n useEffect(() => {\n return () => {\n if (unsubscribe !== noopUnsubscriber) {\n unsubscribe();\n }\n };\n }, [unsubscribe]);\n};\n\nexport default useEventAsync;\n"],"names":["twMergeCustom","extendTailwindMerge","cn","inputs","clsx","Input","React","className","type","props","ref","jsx","BookChapterInput","forwardRef","handleSearch","handleKeyDown","handleOnClick","handleSubmit","jsxs","ShadInput","event","e","History","P","R","t","s","n","N","B","O","S","K","g","k","x","T","X","V","w","L","G","A","H","C","I","y","q","U","m","l","h","c","E","D","i","a","o","u","v","f","d","b","p","J","DropdownMenu","DropdownMenuPrimitive","DropdownMenuTrigger","DropdownMenuGroup","DropdownMenuPortal","DropdownMenuSub","DropdownMenuRadioGroup","DropdownMenuSubTrigger","inset","children","ChevronRight","DropdownMenuSubContent","DropdownMenuContent","sideOffset","DropdownMenuItem","DropdownMenuCheckboxItem","checked","Check","DropdownMenuRadioItem","Circle","DropdownMenuLabel","DropdownMenuSeparator","DropdownMenuShortcut","BookMenuItem","bookId","handleSelectBook","isSelected","handleHighlightBook","bookType","ShadDropdownMenuItem","Canon","ChapterSelect","handleSelectChapter","endChapter","activeChapter","highlightedChapter","handleHighlightedChapter","chapters","_","handleMouse","useCallback","chapterNumber","chapter","GoToMenuItem","handleSort","handleLocationHistory","handleBookmarks","ShadDropdownMenuLabel","ArrowDownWideNarrow","Clock","Bookmark","ALL_BOOK_IDS","BOOK_TYPE_LABELS","BOOK_TYPE_ARRAY","SCROLL_OFFSET","SEARCH_QUERY_FORMATS","fetchGroupedBooks","fetchEndChapter","getChaptersForBook","getAllEnglishNames","isValidBookEnglishName","bookName","getBookIdFromEnglishName","formattedBookName","BookChapterControl","scrRef","searchQuery","setSearchQuery","useState","selectedBookId","setSelectedBookId","setHighlightedChapter","highlightedBookId","setHighlightedBookId","isContentOpen","setIsContentOpen","isContentOpenDelayed","setIsContentOpenDelayed","inputRef","useRef","contentRef","menuItemRef","fetchFilteredBooks","englishNameLowerCase","normalizedQuery","handleSearchInput","searchString","shouldPreventAutoClosing","controlMenuState","open","updateReference","shouldClose","verse","handleInputSubmit","format","matches","book","englishName","handleKeyDownInput","handleKeyDownContent","key","handleKeyDownMenuItem","chapterOffSet","useEffect","useLayoutEffect","scrollTimeout","scrollPosition","ShadDropdownMenu","ShadDropdownMenuTrigger","ShadDropdownMenuContent","bookTypeIndex","element","ShadDropdownMenuSeparator","buttonVariants","cva","Button","variant","size","asChild","Comp","Slot","labelVariants","Label","LabelPrimitive","RadioGroup","RadioGroupPrimitive","RadioGroupItem","Popover","PopoverPrimitive","PopoverTrigger","PopoverContent","align","DialogPortal","DialogPrimitive","DialogOverlay","DialogContent","DialogTitle","DialogDescription","Command","CommandPrimitive","CommandInput","Search","CommandList","CommandEmpty","CommandGroup","CommandSeparator","CommandItem","getOptionLabelDefault","option","ComboBox","id","options","buttonClassName","popoverContentClassName","value","onChange","getOptionLabel","buttonPlaceholder","textPlaceholder","commandEmptyMessage","buttonVariant","dir","isDisabled","setOpen","ChevronsUpDown","ChapterRangeSelector","startChapter","handleSelectStartChapter","handleSelectEndChapter","chapterCount","chapterOptions","useMemo","index","onChangeStartChapter","onChangeEndChapter","Fragment","BookSelectionMode","BOOK_SELECTOR_STRING_KEYS","localizeString","strings","BookSelector","handleBookSelectionModeChange","currentBookName","onSelectBooks","selectedBookIds","localizedStrings","currentBookText","chooseText","chooseBooksText","bookSelectionMode","setBookSelectionMode","onSelectionModeChange","newMode","DataTableViewOptions","table","FilterIcon","column","Select","SelectPrimitive","SelectGroup","SelectValue","SelectTrigger","ChevronDown","SelectScrollUpButton","ChevronUp","SelectScrollDownButton","SelectContent","position","SelectLabel","SelectItem","SelectSeparator","DataTablePagination","pageSize","ArrowLeftIcon","ChevronLeftIcon","ChevronRightIcon","ArrowRightIcon","Table","stickyHeader","TableHeader","TableBody","TableFooter","TableRow","TableHead","TableCell","TableCaption","DataTable","columns","data","enablePagination","showPaginationControls","showColumnVisibilityControls","onRowClickHandler","sorting","setSorting","columnFilters","setColumnFilters","columnVisibility","setColumnVisibility","rowSelection","setRowSelection","useReactTable","getCoreRowModel","getPaginationRowModel","getSortedRowModel","getFilteredRowModel","headerGroup","header","flexRender","_a","row","cell","OccurrencesTable","occurrenceData","setScriptureReference","referenceHeaderText","occurrenceHeaderText","occurrences","uniqueOccurrences","occurrence","uniqueOccurrence","deepEqual","Checkbox","CheckboxPrimitive","getLinesFromUSFM","text","getNumberFromUSFM","regex","match","getBookNumFromId","getStatusForItem","item","approvedItems","unapprovedItems","toggleVariants","Toggle","TogglePrimitive","ToggleGroupContext","ToggleGroup","ToggleGroupPrimitive","ToggleGroupItem","context","getSortingIcon","sortDirection","ArrowUpIcon","ArrowDownIcon","ArrowUpDownIcon","inventoryItemColumn","itemLabel","inventoryAdditionalItemColumn","additionalItemLabel","additionalItemIndex","inventoryCountColumn","countLabel","statusChangeHandler","changedItems","newStatus","onApprovedItemsChange","onUnapprovedItemsChange","newApprovedItems","validItem","newUnapprovedItems","unapprovedItem","inventoryStatusColumn","statusLabel","status","CircleCheckIcon","CircleXIcon","CircleHelpIcon","INVENTORY_STRING_KEYS","filterItemData","itemData","statusFilter","textFilter","filteredItemData","createTableData","scriptureRef","itemRegex","tableData","currentBook","currentChapter","currentVerse","line","items","itemIndex","existingItem","tableEntry","newReference","substring","newItem","Inventory","scriptureReference","extractItems","additionalItemsLabels","scope","onScopeChange","allItemsText","approvedItemsText","unapprovedItemsText","unknownItemsText","scopeBookText","scopeChapterText","scopeVerseText","filterText","showAdditionalItemsText","showAdditionalItems","setShowAdditionalItems","setStatusFilter","setTextFilter","selectedItem","setSelectedItem","reducedTableData","newTableData","firstItem","existingEntry","newTableEntry","filteredTableData","allColumns","numberOfAdditionalItems","additionalColumns","_b","rowClickHandler","newSelection","handleScopeChange","handleStatusFilterChange","SearchBar","onSearch","placeholder","isFullWidth","handleInputChange","VerticalTabs","TabsPrimitive","VerticalTabsList","VerticalTabsTrigger","VerticalTabsContent","TabNavigationContentSearch","tabList","searchPlaceholder","headerTitle","isSearchBarFullWidth","direction","tab","Separator","orientation","decorative","SeparatorPrimitive","Sheet","SheetPrimitive","SheetPortal","SheetOverlay","sheetVariants","SheetContent","side","SheetTitle","SheetDescription","Skeleton","TooltipProvider","TooltipPrimitive","Tooltip","TooltipTrigger","TooltipContent","MOBILE_BREAKPOINT","useIsMobile","isMobile","setIsMobile","mql","SIDEBAR_COOKIE_NAME","SIDEBAR_COOKIE_MAX_AGE","SIDEBAR_WIDTH","SIDEBAR_WIDTH_MOBILE","SIDEBAR_WIDTH_ICON","SIDEBAR_KEYBOARD_SHORTCUT","SidebarContext","useSidebar","SidebarProvider","defaultOpen","openProp","setOpenProp","style","openMobile","setOpenMobile","_open","_setOpen","isOpen","openState","toggleSidebar","state","contextValue","Sidebar","collapsible","SidebarTrigger","onClick","PanelLeft","SidebarRail","SidebarInset","SidebarInput","SidebarHeader","SidebarFooter","SidebarSeparator","SidebarContent","SidebarGroup","SidebarGroupLabel","SidebarGroupAction","SidebarGroupContent","SidebarMenu","SidebarMenuItem","sidebarMenuButtonVariants","SidebarMenuButton","isActive","tooltip","button","SidebarMenuAction","showOnHover","SidebarMenuBadge","SidebarMenuSkeleton","showIcon","width","SidebarMenuSub","SidebarMenuSubItem","SidebarMenuSubButton","SettingsSidebar","extensionLabels","projectOptions","handleSelectSidebarItem","selectedSidebarItem","handleSelectItem","projectId","getProjectNameFromProjectId","project","getIsActive","label","selectedProjectName","SettingsSidebarContentSearch","scrBookColId","scrRefColId","typeColId","detailsColId","defaultScrRefColumnName","defaultScrBookGroupName","defaultTypeColumnName","defaultDetailsColumnName","getColumns","colInfo","showSourceColumn","showSrcCol","info","formatScrRef","compareScrRefs","toRefOrRange","scriptureSelection","offsetStart","offsetEnd","scrRefToBBBCCCVVV","getRowKey","ScriptureResultsViewer","sources","showColumnHeaders","scriptureReferenceColumnName","scriptureBookGroupName","typeColumnName","detailsColumnName","onRowSelected","grouping","setGrouping","scriptureResults","source","getExpandedRowModel","getGroupedRowModel","selectedRows","keys","selectedRow","scrBookGroupName","typeGroupName","groupingOptions","handleSelectChange","selectedGrouping","handleRowClick","getEvenOrOddBandingStyle","getIndent","groupingState","rowIndex","ChevronLeft","DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS","getLocalizeKeyForScrollGroupId","ScrollGroupSelector","availableScrollGroupIds","scrollGroupId","onChangeScrollGroupId","localizedStringsDefaulted","localizedStringKey","localizedStringValue","newScrollGroupString","scrollGroupOptionId","SettingsList","SettingsListItem","primary","secondary","isLoading","loadingMessage","SettingsListHeader","includeSeparator","Card","CardHeader","CardTitle","CardDescription","CardContent","CardFooter","SettingsCard","settingsGroupLabel","settingsGroupDescription","Checklist","listItems","selectedListItems","handleSelectListItem","createLabel","_interopRequireDefault","obj","module","chainPropTypes","propType1","propType2","args","_extends","target","isPlainObject","prototype","deepClone","output","deepmerge","r","z","reactIs_production_min","hasSymbol","REACT_ELEMENT_TYPE","REACT_PORTAL_TYPE","REACT_FRAGMENT_TYPE","REACT_STRICT_MODE_TYPE","REACT_PROFILER_TYPE","REACT_PROVIDER_TYPE","REACT_CONTEXT_TYPE","REACT_ASYNC_MODE_TYPE","REACT_CONCURRENT_MODE_TYPE","REACT_FORWARD_REF_TYPE","REACT_SUSPENSE_TYPE","REACT_SUSPENSE_LIST_TYPE","REACT_MEMO_TYPE","REACT_LAZY_TYPE","REACT_BLOCK_TYPE","REACT_FUNDAMENTAL_TYPE","REACT_RESPONDER_TYPE","REACT_SCOPE_TYPE","isValidElementType","typeOf","object","$$typeof","$$typeofType","AsyncMode","ConcurrentMode","ContextConsumer","ContextProvider","Element","ForwardRef","Lazy","Memo","Portal","Profiler","StrictMode","Suspense","hasWarnedAboutDeprecatedIsAsyncMode","isAsyncMode","isConcurrentMode","isContextConsumer","isContextProvider","isElement","isForwardRef","isFragment","isLazy","isMemo","isPortal","isProfiler","isStrictMode","isSuspense","reactIs_development","reactIsModule","require$$0","require$$1","getOwnPropertySymbols","hasOwnProperty","propIsEnumerable","toObject","val","shouldUseNative","test1","test2","order2","test3","letter","objectAssign","from","to","symbols","ReactPropTypesSecret","ReactPropTypesSecret_1","has","printWarning","loggedTypeFailures","message","checkPropTypes","typeSpecs","values","location","componentName","getStack","typeSpecName","error","err","ex","stack","checkPropTypes_1","ReactIs","assign","require$$2","require$$3","require$$4","emptyFunctionThatReturnsNull","factoryWithTypeCheckers","isValidElement","throwOnDirectAccess","ITERATOR_SYMBOL","FAUX_ITERATOR_SYMBOL","getIteratorFn","maybeIterable","iteratorFn","ANONYMOUS","ReactPropTypes","createPrimitiveTypeChecker","createAnyTypeChecker","createArrayOfTypeChecker","createElementTypeChecker","createElementTypeTypeChecker","createInstanceTypeChecker","createNodeChecker","createObjectOfTypeChecker","createEnumTypeChecker","createUnionTypeChecker","createShapeTypeChecker","createStrictShapeTypeChecker","is","PropTypeError","createChainableTypeChecker","validate","manualPropTypeCallCache","manualPropTypeWarningCount","checkType","isRequired","propName","propFullName","secret","cacheKey","chainedCheckType","expectedType","propValue","propType","getPropType","preciseType","getPreciseType","typeChecker","expectedClass","expectedClassName","actualClassName","getClassName","expectedValues","valuesString","arrayOfTypeCheckers","checker","getPostfixForTypeWarning","expectedTypes","checkerResult","expectedTypesMessage","isNode","invalidValidatorError","shapeTypes","allKeys","iterator","step","entry","isSymbol","emptyFunction","emptyFunctionWithReset","factoryWithThrowingShims","shim","getShim","propTypesModule","isClassComponent","elementType","acceptingRef","safePropName","warningHint","elementAcceptingRef","PropTypes","elementAcceptingRef$1","specialProperty","exactProp","propTypes","unsupportedProps","prop","formatMuiErrorMessage","code","url","REACT_SERVER_CONTEXT_TYPE","REACT_OFFSCREEN_TYPE","enableScopeAPI","enableCacheElement","enableTransitionTracing","enableLegacyHidden","enableDebugTracing","REACT_MODULE_REFERENCE","SuspenseList","hasWarnedAboutDeprecatedIsConcurrentMode","isSuspenseList","fnNameMatchRegex","getFunctionName","fn","getFunctionComponentName","Component","fallback","getWrappedName","outerType","innerType","wrapperName","functionName","getDisplayName","HTMLElementType","refType","refType$1","capitalize","string","_formatMuiErrorMessage","createChainedFunction","funcs","acc","func","debounce","wait","timeout","debounced","later","deprecatedPropType","validator","reason","componentNameSafe","propFullNameSafe","isMuiElement","muiNames","_muiName","_element$type","ownerDocument","node","ownerWindow","requirePropFactory","componentNameInError","prevPropTypes","requiredProp","defaultTypeChecker","typeCheckerResult","setRef","useEnhancedEffect","useEnhancedEffect$1","globalId","useGlobalId","idOverride","defaultId","setDefaultId","maybeReactUseId","useId","reactId","unsupportedProp","useControlled","controlled","defaultProp","name","isControlled","valueState","setValue","defaultValue","setValueIfUncontrolled","newValue","useEventCallback","useForkRef","refs","instance","UNINITIALIZED","useLazyRef","init","initArg","EMPTY","useOnMount","Timeout","delay","useTimeout","hadKeyboardEvent","hadFocusVisibleRecently","hadFocusVisibleRecentlyTimeout","inputTypesWhitelist","focusTriggersKeyboardModality","tagName","handlePointerDown","handleVisibilityChange","prepare","doc","isFocusVisible","useIsFocusVisible","isFocusVisibleRef","handleBlurVisible","handleFocusVisible","resolveProps","defaultProps","defaultSlotProps","slotProps","slotPropName","composeClasses","slots","getUtilityClass","classes","slot","utilityClass","defaultGenerator","createClassNameGenerator","generate","generator","ClassNameGenerator","ClassNameGenerator$1","globalStateClasses","generateUtilityClass","globalStatePrefix","globalStateClass","generateUtilityClasses","result","clamp","min","max","_objectWithoutPropertiesLoose","excluded","sourceKeys","_excluded","sortBreakpointsValues","breakpointsAsArray","breakpoint1","breakpoint2","createBreakpoints","breakpoints","unit","other","sortedValues","up","down","between","start","end","endIndex","only","not","keyIndex","shape","shape$1","responsivePropType","responsivePropType$1","merge","defaultBreakpoints","handleBreakpoints","styleFromPropValue","theme","themeBreakpoints","breakpoint","mediaKey","cssKey","createEmptyBreakpointObject","breakpointsInput","_breakpointsInput$key","breakpointStyleKey","removeUnusedBreakpoints","breakpointKeys","breakpointOutput","getPath","path","checkVars","getStyleValue","themeMapping","transform","propValueFinal","userValue","cssProperty","themeKey","memoize","cache","arg","properties","directions","aliases","getCssProperties","property","marginKeys","paddingKeys","spacingKeys","createUnaryUnit","_getPath","themeSpacing","abs","createUnarySpacing","getValue","transformer","transformed","getStyleFromPropValue","cssProperties","resolveCssProperty","margin","padding","createSpacing","spacingInput","spacing","argsInput","argument","compose","styles","handlers","borderTransform","createBorderStyle","border","borderTop","borderRight","borderBottom","borderLeft","borderColor","borderTopColor","borderRightColor","borderBottomColor","borderLeftColor","outline","outlineColor","borderRadius","gap","columnGap","rowGap","gridColumn","gridRow","gridAutoFlow","gridAutoColumns","gridAutoRows","gridTemplateColumns","gridTemplateRows","gridTemplateAreas","gridArea","paletteTransform","color","bgcolor","backgroundColor","sizingTransform","maxWidth","_props$theme","_props$theme2","breakpointsValues","minWidth","height","maxHeight","minHeight","boxSizing","defaultSxConfig","defaultSxConfig$1","objectsHaveSameKeys","objects","union","callIfFn","maybeFn","unstable_createStyleFunctionSx","getThemeValue","config","styleFunctionSx","_theme$unstable_sxCon","sx","traverse","sxInput","sxObject","emptyBreakpoints","breakpointsKeys","css","styleKey","styleFunctionSx$1","applyStyles","createTheme","paletteInput","shapeInput","muiTheme","isObjectEmpty","useTheme","defaultTheme","contextTheme","ThemeContext","systemDefaultTheme","useThemeWithoutDefault","_excluded2","_excluded3","isEmpty","isStringTag","tag","shouldForwardProp","lowercaseFirstLetter","resolveTheme","themeId","defaultOverridesResolver","processStyleArg","callableStyle","_ref","ownerState","resolvedStylesArg","resolvedStyle","variants","isMatch","createStyled","input","rootShouldForwardProp","slotShouldForwardProp","systemSx","inputOptions","processStyles","componentSlot","inputSkipVariantsResolver","inputSkipSx","overridesResolver","skipVariantsResolver","skipSx","shouldForwardPropOption","defaultStyledResolver","styledEngineStyled","transformStyleArg","stylesArg","muiStyledResolver","styleArg","expressions","transformedStyleArg","expressionsWithDefaultTheme","styleOverrides","resolvedStyleOverrides","slotKey","slotStyle","_theme$components","themeVariants","numOfCustomFnsApplied","placeholders","displayName","getThemeProps","params","useThemeProps","clampWrapper","hexToRgb","re","colors","decomposeColor","marker","colorSpace","recomposeColor","hslToRgb","rgb","getLuminance","getContrastRatio","foreground","background","lumA","lumB","alpha","darken","coefficient","lighten","createMixins","mixins","common","common$1","grey","grey$1","purple","purple$1","red","red$1","orange","orange$1","blue","blue$1","lightBlue","lightBlue$1","green","green$1","light","dark","addLightOrDark","intent","shade","tonalOffset","tonalOffsetLight","tonalOffsetDark","getDefaultPrimary","mode","getDefaultSecondary","getDefaultError","getDefaultInfo","getDefaultSuccess","getDefaultWarning","createPalette","palette","contrastThreshold","success","warning","getContrastText","contrastText","contrast","augmentColor","mainShade","lightShade","darkShade","modes","round","caseAllCaps","defaultFontFamily","createTypography","typography","fontFamily","fontSize","fontWeightLight","fontWeightRegular","fontWeightMedium","fontWeightBold","htmlFontSize","allVariants","pxToRem2","coef","pxToRem","buildVariant","fontWeight","lineHeight","letterSpacing","casing","shadowKeyUmbraOpacity","shadowKeyPenumbraOpacity","shadowAmbientShadowOpacity","createShadow","px","shadows","shadows$1","easing","duration","formatMs","milliseconds","getAutoHeightDuration","constant","createTransitions","inputTransitions","mergedEasing","mergedDuration","durationOption","easingOption","isString","isNumber","animatedProp","zIndex","zIndex$1","mixinsInput","transitionsInput","typographyInput","systemTheme","systemCreateTheme","stateClasses","component","child","stateClass","defaultTheme$1","THEME_ID","systemUseThemeProps","styled","styled$1","getSvgIconUtilityClass","useUtilityClasses","SvgIconRoot","_theme$transitions","_theme$transitions$cr","_theme$transitions2","_theme$typography","_theme$typography$pxT","_theme$typography2","_theme$typography2$px","_theme$typography3","_theme$typography3$px","_palette$ownerState$c","_palette","_palette2","_palette3","SvgIcon","inProps","htmlColor","inheritViewBox","titleAccess","viewBox","hasSvgAsChild","more","_jsxs","_jsx","SvgIcon$1","createSvgIcon","unstable_ClassNameGenerator","exports","_utils","ArrowRight","default_1","_createSvgIcon","_jsxRuntime","isHostComponent","appendOwnerState","otherProps","defaultContextValue","ClassNameConfiguratorContext","useClassNamesOverride","disableDefaultClasses","extractEventHandlers","excludeKeys","resolveComponentProps","componentProps","slotState","omitEventHandlers","mergeSlotProps","parameters","getSlotProps","additionalProps","externalSlotProps","externalForwardedProps","joinedClasses","mergedStyle","eventHandlers","componentsPropsWithoutEventHandlers","otherPropsWithoutEventHandlers","internalSlotProps","useSlotProps","_parameters$additiona","skipResolvingSlotProps","rest","resolvedComponentsProps","mergedProps","internalRef","GLOBAL_CLASS_PREFIX","buildStateClass","buildSlotClass","getContainer","container","forwardedRef","disablePortal","mountNode","setMountNode","handleRef","newProps","ReactDOM","top","bottom","right","left","auto","basePlacements","clippingParents","viewport","popper","reference","variationPlacements","placement","placements","beforeRead","read","afterRead","beforeMain","main","afterMain","beforeWrite","write","afterWrite","modifierPhases","getNodeName","getWindow","OwnElement","isHTMLElement","isShadowRoot","attributes","effect","_ref2","initialStyles","styleProperties","attribute","applyStyles$1","getBasePlacement","getUAString","uaData","isLayoutViewport","getBoundingClientRect","includeScale","isFixedStrategy","clientRect","scaleX","scaleY","visualViewport","addVisualOffsets","getLayoutRect","contains","parent","rootNode","next","getComputedStyle","isTableElement","getDocumentElement","getParentNode","getTrueOffsetParent","getContainingBlock","isFirefox","isIE","elementCss","currentNode","getOffsetParent","window","offsetParent","getMainAxisFromPlacement","within","mathMax","mathMin","withinMaxClamp","getFreshSideObject","mergePaddingObject","paddingObject","expandToHashMap","hashMap","toPaddingObject","arrow","_state$modifiersData$","arrowElement","popperOffsets","basePlacement","axis","isVertical","len","arrowRect","minProp","maxProp","endDiff","startDiff","arrowOffsetParent","clientSize","centerToReference","center","offset","axisProp","_options$element","arrow$1","getVariation","unsetSides","roundOffsetsByDPR","win","dpr","mapToStyles","_Object$assign2","popperRect","variation","offsets","gpuAcceleration","adaptive","roundOffsets","isFixed","_offsets$x","_offsets$y","_ref3","hasX","hasY","sideX","sideY","heightProp","widthProp","offsetY","offsetX","commonStyles","_ref4","_Object$assign","computeStyles","_ref5","_options$gpuAccelerat","_options$adaptive","_options$roundOffsets","computeStyles$1","passive","_options$scroll","scroll","_options$resize","resize","scrollParents","scrollParent","eventListeners","hash","getOppositePlacement","matched","getOppositeVariationPlacement","getWindowScroll","scrollLeft","scrollTop","getWindowScrollBarX","getViewportRect","strategy","html","layoutViewport","getDocumentRect","_element$ownerDocumen","winScroll","body","isScrollParent","_getComputedStyle","overflow","overflowX","overflowY","getScrollParent","listScrollParents","list","isBody","updatedList","rectToClientRect","rect","getInnerBoundingClientRect","getClientRectFromMixedType","clippingParent","getClippingParents","canEscapeClipping","clipperElement","getClippingRect","boundary","rootBoundary","mainClippingParents","firstClippingParent","clippingRect","accRect","computeOffsets","commonX","commonY","mainAxis","detectOverflow","_options","_options$placement","_options$strategy","_options$boundary","_options$rootBoundary","_options$elementConte","elementContext","_options$altBoundary","altBoundary","_options$padding","altContext","clippingClientRect","referenceClientRect","popperClientRect","elementClientRect","overflowOffsets","offsetData","multiply","computeAutoPlacement","flipVariations","_options$allowedAutoP","allowedAutoPlacements","allPlacements","allowedPlacements","overflows","getExpandedFallbackPlacements","oppositePlacement","flip","_options$mainAxis","checkMainAxis","_options$altAxis","checkAltAxis","specifiedFallbackPlacements","_options$flipVariatio","preferredPlacement","isBasePlacement","fallbackPlacements","referenceRect","checksMap","makeFallbackChecks","firstFittingPlacement","_basePlacement","isStartVariation","mainVariationSide","altVariationSide","checks","check","numberOfChecks","_loop","_i","fittingPlacement","_ret","flip$1","getSideOffsets","preventedOffsets","isAnySideFullyClipped","hide","referenceOverflow","popperAltOverflow","referenceClippingOffsets","popperEscapeOffsets","isReferenceHidden","hasPopperEscaped","hide$1","distanceAndSkiddingToXY","rects","invertDistance","skidding","distance","_options$offset","_data$state$placement","offset$1","popperOffsets$1","getAltAxis","preventOverflow","_options$tether","tether","_options$tetherOffset","tetherOffset","altAxis","tetherOffsetValue","normalizedTetherOffsetValue","offsetModifierState","_offsetModifierState$","mainSide","altSide","additive","minLen","maxLen","arrowPaddingObject","arrowPaddingMin","arrowPaddingMax","arrowLen","minOffset","maxOffset","clientOffset","offsetModifierValue","tetherMin","tetherMax","preventedOffset","_offsetModifierState$2","_mainSide","_altSide","_offset","_len","_min","_max","isOriginSide","_offsetModifierValue","_tetherMin","_tetherMax","_preventedOffset","preventOverflow$1","getHTMLElementScroll","getNodeScroll","isElementScaled","getCompositeRect","elementOrVirtualElement","isOffsetParentAnElement","offsetParentIsScaled","documentElement","order","modifiers","map","visited","modifier","sort","requires","dep","depModifier","orderModifiers","orderedModifiers","phase","pending","resolve","mergeByName","merged","current","existing","DEFAULT_OPTIONS","areValidElements","_key","popperGenerator","generatorOptions","_generatorOptions","_generatorOptions$def","defaultModifiers","_generatorOptions$def2","defaultOptions","effectCleanupFns","isDestroyed","setOptionsAction","cleanupModifierEffects","runModifierEffects","_state$elements","_state$orderedModifie","_state$orderedModifie2","_ref$options","cleanupFn","noopFn","createPopper","COMPONENT_NAME","getPopperUtilityClass","flipPlacement","resolveAnchorEl","anchorEl","isVirtualElement","defaultPopperOptions","PopperTooltip","_slots$root","initialPlacement","popperOptions","popperRefProp","TransitionProps","tooltipRef","ownRef","popperRef","handlePopperRef","handlePopperRefRef","rtlPlacement","setPlacement","resolvedAnchorElement","setResolvedAnchorElement","handlePopperUpdate","box","popperModifiers","childProps","Root","rootProps","Popper","containerProp","keepMounted","transition","exited","setExited","handleEnter","handleExited","resolvedAnchorEl","display","transitionProps","useThemeSystem","_setPrototypeOf","_inheritsLoose","subClass","superClass","setPrototypeOf","timeoutsShape","TransitionGroupContext","forceReflow","UNMOUNTED","EXITED","ENTERING","ENTERED","EXITING","Transition","_React$Component","_this","parentGroup","appear","initialStatus","prevState","nextIn","_proto","prevProps","nextStatus","exit","enter","mounting","_this2","appearing","maybeNode","maybeAppearing","timeouts","enterTimeout","_this3","nextState","callback","_this4","active","handler","doesNotHaveTimeoutOrListener","maybeNextCallback","_this$props","pt","noop","Transition$1","reflow","getTransitionProps","_style$transitionDura","_style$transitionTimi","getScale","isWebKit154","Grow","addEndListener","inProp","onEnter","onEntered","onEntering","onExit","onExited","onExiting","TransitionComponent","timer","autoTimeout","nodeRef","normalizedTransitionCallback","maybeIsAppearing","handleEntering","isAppearing","transitionDuration","transitionTimingFunction","handleEntered","handleExiting","handleExit","handleAddEndListener","Grow$1","PopperRoot","BasePopper","components","componentsProps","RootComponent","Popper$1","getTooltipUtilityClass","tooltipClasses","tooltipClasses$1","disableInteractive","touch","TooltipPopper","TooltipTooltip","TooltipArrow","hystersisOpen","hystersisTimer","cursorPosition","composeEventHandler","eventHandler","_slots$popper","_slots$transition","_slots$tooltip","_slots$arrow","_slotProps$popper","_ref6","_slotProps$popper2","_slotProps$transition","_slotProps$tooltip","_ref7","_slotProps$tooltip2","_slotProps$arrow","_ref8","_slotProps$arrow2","childrenProp","describeChild","disableFocusListener","disableHoverListener","disableInteractiveProp","disableTouchListener","enterDelay","enterNextDelay","enterTouchDelay","followCursor","idProp","leaveDelay","leaveTouchDelay","onClose","onOpen","PopperComponentProp","PopperProps","title","TransitionComponentProp","isRtl","childNode","setChildNode","arrowRef","setArrowRef","ignoreNonTouchEvents","closeTimer","enterTimer","leaveTimer","touchTimer","setOpenState","prevUserSelect","stopTouchInteraction","handleOpen","handleClose","handleLeave","focusVisibleRef","setChildIsFocusVisible","handleBlur","handleFocus","detectTouchStart","childrenProps","handleMouseOver","handleMouseLeave","handleTouchStart","handleTouchEnd","nativeEvent","handleMouseMove","nameOrDescProps","titleIsString","interactiveWrapperListeners","_PopperProps$popperOp","tooltipModifiers","PopperComponent","TooltipComponent","ArrowComponent","popperProps","tooltipProps","tooltipArrowProps","TransitionPropsInner","Tooltip$1","getIcon","icon","menuLabel","leading","MuiListItemIcon","MenuItem","allowForLeadingIcons","iconPathBefore","iconPathAfter","hasAutoFocus","isDense","isSubMenuParent","hasDisabledGutters","hasDivider","focusVisibleClassName","menuItem","MuiMenuItem","MuiListItemText","getAllGroups","menuDefinition","SubMenu","setAnchorEl","parentMenuItem","parentItemProps","handleParentMenuItemClick","renderSubMenuItems","includedGroups","group","GroupedMenuItemList","Menu","getOrderedGroupItems","groupId","allItems","menuProps","commandHandler","groupsToInclude","sortedGroups","itemArray","allowSpaceForLeadingIcons","createMenuItemProps","isLastItemInGroup","divKey","itemInfo","menuItemProps","TopLevelMenu","columnId","MenuColumn","metadata","Grid","List","GridMenu","multiColumnMenu","sortedColumns","columnNumbers","columnName","col","getUsePromiseOptionsDefaults","usePromise","promiseFactoryCallback","defaultValueRef","optionsDefaultedRef","setIsLoading","promiseIsCurrent","MenuIcon","HamburgerMenuButton","menuProvider","normalMenu","fullMenu","containerRef","ariaLabelPrefix","isMenuOpen","setMenuOpen","showFullMenu","setShowFullMenu","handleMenuItemClick","handleMenuButtonClick","prevIsOpen","isOpening","menuCommandHandler","command","setOffset","normalMenuData","fullMenuData","menu","IconButton","Drawer","isTooltipSuppressed","adjustMarginToAlignToEdge","MuiIconButton","Spinner","LoaderCircle","TextField","hasError","helperText","onFocus","onBlur","ShadLabel","Toolbar","AppBar","MuiToolbar","alertVariants","Alert","AlertTitle","AlertDescription","Sonner","Toaster","Slider","SliderPrimitive","Switch","SwitchPrimitives","Tabs","TabsList","TabsTrigger","TabsContent","InstallButton","isInstalling","handleClick","buttonText","Download","EnableButton","isEnabling","DisableButton","isDisabling","UpdateButton","isUpdating","MarkdownRenderer","markdown","anchorTarget","Markdown","FilterButton","Filter","DropdownMenuItemType","DropdownMenuItemType2","FilterDropdown","groups","NoExtensionsFound","MoreInfo","category","downloads","languages","moreInfoUrl","numberFormatted","NumberFormat","handleScrollToBottom","User","locale","LucideLink","CircleHelp","VersionHistory","versionHistory","showAllVersions","setShowAllVersions","currentDate","formatTimeString","dateString","date","dateDiff","yearDiff","monthDiff","dayDiff","timeString","sortedEntries","Footer","publisherDisplayName","fileSize","locales","formattedFileSize","formatBytes","languageNames","codes","displayNames","useEvent","unsubscriber","noopUnsubscriber","useEventAsync","unsubscribe","unsub"],"mappings":"28CAGA,MAAMA,GAAgBC,GAAAA,oBAAoB,CAAE,OAAQ,KAAO,CAAA,EAyDpD,SAASC,KAAMC,EAAsB,CACnC,OAAAH,GAAcI,GAAAA,KAAKD,CAAM,CAAC,CACnC,CCzDO,MAAME,GAAQC,EAAM,WACzB,CAAC,CAAE,UAAAC,EAAW,KAAAC,EAAM,GAAGC,CAAA,EAASC,IAE5BC,EAAA,IAAC,QAAA,CACC,KAAAH,EACA,UAAWN,EACT,sbACAK,CACF,EACA,IAAAG,EAEC,GAAGD,CAAA,CAAA,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,MACA,MACA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MAEA,MAEA,MAEA,MAEA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,MAEA,MAEA,MAEA,MAEA,MACA,MACA,MACA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,KACF,EAAGC,GAAI,CACL,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,KACF,EAAGC,GAAI,CACL,UACA,SACA,YACA,UACA,cACA,SACA,SACA,OACA,WACA,WACA,UACA,UACA,eACA,eACA,OACA,WACA,kBACA,MACA,SACA,WACA,eACA,gBACA,SACA,WACA,eACA,UACA,kBACA,QACA,OACA,OACA,UACA,QACA,QACA,QACA,WACA,YACA,SACA,YACA,UACA,UACA,OACA,OACA,OACA,OACA,SACA,gBACA,gBACA,YACA,YACA,cACA,aACA,kBACA,kBACA,YACA,YACA,QACA,WACA,UACA,QACA,UACA,UACA,SACA,SACA,SACA,OACA,aACA,QACA,SACA,eACA,oBACA,0BACA,SACA,qBACA,sBACA,UACA,qBACA,cACA,cACA,cACA,cACA,mBACA,mBACA,qBACA,YACA,OACA,oBAGA,uBACA,uBACA,sBACA,yBACA,wBACA,qBACA,UACA,UACA,UACA,UACA,UACA,UACA,UACA,eACA,cACA,eACA,oBACA,qBACA,0BACA,0BACA,eACA,eACA,YACA,gBACA,cACA,eACA,iBACA,wBACA,mBACA,WACA,QACA,aACA,aACA,aACA,2BACA,4BACA,YACF,EAAGC,GAAIC,KACP,SAASC,GAAER,EAAGJ,EAAI,GAAI,CACpB,OAAOA,IAAMI,EAAIA,EAAE,YAAa,GAAGA,KAAKM,GAAIA,GAAEN,CAAC,EAAI,CACrD,CACA,SAASS,GAAET,EAAG,CACZ,OAAOQ,GAAER,CAAC,EAAI,CAChB,CACA,SAASU,GAAEV,EAAG,CACZ,MAAMJ,EAAI,OAAOI,G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c,CACZ,SAAU,UACV,UAAWA,EACZ,EACD,WAAY,CACV,SAAU,UACV,UAAWA,EACZ,EACD,YAAa,CACX,SAAU,SACX,EACD,eAAgB,CACd,SAAU,SACX,EACD,iBAAkB,CAChB,SAAU,SACX,EACD,kBAAmB,CACjB,SAAU,SACX,EACD,gBAAiB,CACf,SAAU,SACX,EACD,QAAS,CACP,SAAU,UACV,UAAWA,EACZ,EACD,aAAc,CACZ,SAAU,SACX,EACD,aAAc,CACZ,SAAU,qBACV,MAAOc,EACR,EAED,MAAO,CACL,SAAU,UACV,UAAWa,EACZ,EACD,QAAS,CACP,SAAU,UACV,YAAa,kBACb,UAAWA,EACZ,EACD,gBAAiB,CACf,SAAU,UACV,UAAWA,EACZ,EAED,EAAG,CACD,MAAOpC,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,QAAS,CACP,MAAOA,EACR,EACD,WAAY,CACV,MAAOA,EACR,EACD,aAAc,CACZ,MAAOA,EACR,EACD,cAAe,CACb,MAAOA,EACR,EACD,YAAa,CACX,MAAOA,EACR,EACD,SAAU,CACR,MAAOA,EACR,EACD,SAAU,CACR,MAAOA,EACR,EACD,cAAe,CACb,MAAOA,EACR,EACD,mBAAoB,CAClB,MAAOA,EACR,EACD,iBAAkB,CAChB,MAAOA,EACR,EACD,aAAc,CACZ,MAAOA,EACR,EACD,kBAAmB,CACjB,MAAOA,EACR,EACD,gBAAiB,CACf,MAAOA,EACR,EACD,EAAG,CACD,MAAOD,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,OAAQ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;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","x_google_ignoreList":[3,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,83,84,85,86,87,88,89,90,91,92,93,94,95,96,97,98,99,100,101,102,103,104,105,106,107,108,109,110,111,112,113,114,115,116,117,118,119,120,121,122,123,124,125,126,127,128,129,130,131,132,133,134,135,136,137,138,139,140,141,142,143,144,145,146,147,148,149,150,151,152,153,154,155,156,157,158,159,160,161,162,163,164,165,166,167,168,169,170,171,172,173,174,175,176,177,178,179,180,181,182,183,184,185,186,187,188,189,190,191,192,193,194,195,196,197,198,199,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,230]} \ No newline at end of file diff --git a/lib/platform-bible-react/dist/index.d.ts b/lib/platform-bible-react/dist/index.d.ts index def11c4f2c..039501145d 100644 --- a/lib/platform-bible-react/dist/index.d.ts +++ b/lib/platform-bible-react/dist/index.d.ts @@ -450,7 +450,7 @@ export type SettingsSidebarProps = { /** Handler for selecting a sidebar item */ handleSelectSidebarItem: (key: string, projectId?: string) => void; /** The current selected value in the sidebar */ - selectedSidebarItem: SelectedSettingsSidebarItem | undefined; + selectedSidebarItem: SelectedSettingsSidebarItem; }; export function SettingsSidebar({ id, extensionLabels, projectOptions, handleSelectSidebarItem, selectedSidebarItem, }: SettingsSidebarProps): import("react/jsx-runtime").JSX.Element; export type SettingsSidebarContentSearchProps = SettingsSidebarProps & React$1.PropsWithChildren & { @@ -458,8 +458,10 @@ export type SettingsSidebarContentSearchProps = SettingsSidebarProps & React$1.P id?: string; /** Text direction ltr or rtl */ direction?: "ltr" | "rtl"; + /** Handler to run when the value of the search bar changes */ + onSearch: (searchQuery: string) => void; }; -export function SettingsSidebarContentSearch({ id, direction, extensionLabels, projectOptions, children, handleSelectSidebarItem, selectedSidebarItem, }: SettingsSidebarContentSearchProps): import("react/jsx-runtime").JSX.Element; +export function SettingsSidebarContentSearch({ id, direction, extensionLabels, projectOptions, children, handleSelectSidebarItem, selectedSidebarItem, onSearch, }: SettingsSidebarContentSearchProps): import("react/jsx-runtime").JSX.Element; /** * Information (e.g., a checking error or some other type of "transient" annotation) about something * noteworthy at a specific place in an instance of the Scriptures. @@ -925,6 +927,7 @@ export type IconButtonProps = React$1.PropsWithChildren<{ */ export declare function IconButton({ id, label, isDisabled, tooltip, isTooltipSuppressed, adjustMarginToAlignToEdge, size, className, onClick, children, }: IconButtonProps): import("react/jsx-runtime").JSX.Element; export type SearchBarProps = { + className?: string; /** * Callback fired to handle the search query when button pressed * @@ -936,7 +939,7 @@ export type SearchBarProps = { /** Optional boolean to set the input base to full width */ isFullWidth?: boolean; }; -export function SearchBar({ onSearch, placeholder, isFullWidth }: SearchBarProps): import("react/jsx-runtime").JSX.Element; +export function SearchBar({ className, onSearch, placeholder, isFullWidth, }: SearchBarProps): import("react/jsx-runtime").JSX.Element; export type SpinnerProps = LucideProps; export declare const Spinner: import("react").ForwardRefExoticComponent & import("react").RefAttributes>; export type TextFieldProps = { diff --git a/lib/platform-bible-react/dist/index.js b/lib/platform-bible-react/dist/index.js index 5e55e5c7b7..37bfa8aa66 100644 --- a/lib/platform-bible-react/dist/index.js +++ b/lib/platform-bible-react/dist/index.js @@ -1,12 +1,12 @@ -import Qs, { jsx as s, jsxs as x, Fragment as ie } from "react/jsx-runtime"; +import el, { jsx as s, jsxs as x, Fragment as ie } from "react/jsx-runtime"; import * as M from "react"; -import T, { forwardRef as Qn, useCallback as Tt, useState as ut, useRef as ge, useEffect as ae, useLayoutEffect as ta, useMemo as At } from "react"; -import { History as tl, ChevronRight as Ja, Check as tr, Circle as Za, ArrowDownWideNarrow as el, Clock as nl, Bookmark as rl, X as Qa, Search as ol, ChevronsUpDown as al, FilterIcon as il, ChevronDown as er, ChevronUp as sl, ArrowLeftIcon as ll, ChevronLeftIcon as cl, ChevronRightIcon as dl, ArrowRightIcon as pl, CircleCheckIcon as ul, CircleXIcon as wl, CircleHelpIcon as fl, ArrowUpIcon as ml, ArrowDownIcon as hl, ArrowUpDownIcon as gl, PanelLeft as bl, ChevronLeft as vl, LoaderCircle as yl, Download as xl, Filter as Nl, User as kl, Link as El, CircleHelp as Sl } from "lucide-react"; -import be, { clsx as Tl } from "clsx"; -import { extendTailwindMerge as Cl } from "tailwind-merge"; +import T, { forwardRef as Qn, useCallback as Et, useState as ut, useRef as ge, useEffect as ae, useLayoutEffect as ta, useMemo as It } from "react"; +import { History as nl, ChevronRight as Ja, Check as tr, Circle as Za, ArrowDownWideNarrow as rl, Clock as ol, Bookmark as al, X as Qa, Search as il, ChevronsUpDown as sl, FilterIcon as ll, ChevronDown as er, ChevronUp as cl, ArrowLeftIcon as dl, ChevronLeftIcon as pl, ChevronRightIcon as ul, ArrowRightIcon as wl, CircleCheckIcon as fl, CircleXIcon as ml, CircleHelpIcon as hl, ArrowUpIcon as gl, ArrowDownIcon as bl, ArrowUpDownIcon as vl, PanelLeft as yl, ChevronLeft as xl, LoaderCircle as Nl, Download as kl, Filter as El, User as Sl, Link as Tl, CircleHelp as Cl } from "lucide-react"; +import be, { clsx as Ol } from "clsx"; +import { extendTailwindMerge as Rl } from "tailwind-merge"; import * as wt from "@radix-ui/react-dropdown-menu"; -import { DropdownMenuTrigger as Ol } from "@radix-ui/react-dropdown-menu"; -import { getChaptersForBook as Rl, deepEqual as co, substring as _l, formatScrRef as Or, compareScrRefs as Hr, scrRefToBBBCCCVVV as Rr, getLocalizeKeyForScrollGroupId as pt, NumberFormat as Pl, formatBytes as $l } from "platform-bible-utils"; +import { DropdownMenuTrigger as _l } from "@radix-ui/react-dropdown-menu"; +import { getChaptersForBook as Pl, deepEqual as co, substring as $l, formatScrRef as Or, compareScrRefs as Hr, scrRefToBBBCCCVVV as Rr, getLocalizeKeyForScrollGroupId as pt, NumberFormat as Il, formatBytes as Al } from "platform-bible-utils"; import { Slot as He } from "@radix-ui/react-slot"; import { cva as Xe } from "class-variance-authority"; import * as ti from "@radix-ui/react-label"; @@ -14,7 +14,7 @@ import * as mn from "@radix-ui/react-radio-group"; import * as hn from "@radix-ui/react-popover"; import { Command as Rt } from "cmdk"; import * as vt from "@radix-ui/react-dialog"; -import { useReactTable as ei, getCoreRowModel as ni, getPaginationRowModel as Al, getSortedRowModel as ri, getFilteredRowModel as Il, flexRender as dn, getExpandedRowModel as Ml, getGroupedRowModel as Dl } from "@tanstack/react-table"; +import { useReactTable as ei, getCoreRowModel as ni, getPaginationRowModel as Ml, getSortedRowModel as ri, getFilteredRowModel as Dl, flexRender as dn, getExpandedRowModel as Bl, getGroupedRowModel as jl } from "@tanstack/react-table"; import * as bt from "@radix-ui/react-select"; import * as Xr from "@radix-ui/react-checkbox"; import * as nr from "@radix-ui/react-toggle-group"; @@ -22,18 +22,18 @@ import * as oi from "@radix-ui/react-toggle"; import * as _t from "@radix-ui/react-tabs"; import * as ai from "@radix-ui/react-separator"; import * as En from "@radix-ui/react-tooltip"; -import { CardContent as Bl, MenuItem as jl, ListItemText as Vl, ListItemIcon as ii, Menu as zl, Grid as si, List as Ll, IconButton as li, Drawer as Fl, AppBar as Ul, Toolbar as Gl } from "@mui/material"; -import Hl, { ThemeContext as Xl, internal_processStyles as Yl } from "@mui/styled-engine"; -import * as Wl from "react-dom"; +import Vl, { ThemeContext as zl, internal_processStyles as Ll } from "@mui/styled-engine"; +import { MenuItem as Fl, ListItemText as Ul, ListItemIcon as ii, Menu as Gl, Grid as si, List as Hl, IconButton as li, Drawer as Xl, AppBar as Yl, Toolbar as Wl } from "@mui/material"; +import * as ql from "react-dom"; import Bn from "react-dom"; -import { Toaster as ql } from "sonner"; -import { toast as Qh } from "sonner"; +import { Toaster as Kl } from "sonner"; +import { toast as Zh } from "sonner"; import * as an from "@radix-ui/react-slider"; import * as Yr from "@radix-ui/react-switch"; -import Kl from "markdown-to-jsx"; -const Jl = Cl({ prefix: "tw-" }); +import Jl from "markdown-to-jsx"; +const Zl = Rl({ prefix: "tw-" }); function N(...t) { - return Jl(Tl(t)); + return Zl(Ol(t)); } const Ye = T.forwardRef( ({ className: t, type: e, ...n }, r) => /* @__PURE__ */ s( @@ -50,7 +50,7 @@ const Ye = T.forwardRef( ) ); Ye.displayName = "Input"; -const Zl = Qn( +const Ql = Qn( ({ handleSearch: t, handleKeyDown: e, handleOnClick: n, handleSubmit: r, ...o }, a) => /* @__PURE__ */ x("div", { className: "tw-relative", children: [ /* @__PURE__ */ s( Ye, @@ -67,7 +67,7 @@ const Zl = Qn( } ), /* @__PURE__ */ s( - tl, + nl, { className: "tw-absolute tw-right-3 tw-top-1/2 tw-h-4 tw-w-4 tw--translate-y-1/2 tw-transform tw-cursor-pointer tw-text-muted-foreground", onClick: () => { @@ -77,7 +77,7 @@ const Zl = Qn( ) ] }) ); -var Ql = Object.defineProperty, tc = (t, e, n) => e in t ? Ql(t, e, { enumerable: !0, configurable: !0, writable: !0, value: n }) : t[e] = n, et = (t, e, n) => tc(t, typeof e != "symbol" ? e + "" : e, n); +var tc = Object.defineProperty, ec = (t, e, n) => e in t ? tc(t, e, { enumerable: !0, configurable: !0, writable: !0, value: n }) : t[e] = n, et = (t, e, n) => ec(t, typeof e != "symbol" ? e + "" : e, n); const ye = [ "GEN", "EXO", @@ -365,33 +365,33 @@ const ye = [ "Reproof (Proverbs 25-31)", "4 Baruch (Rest of Baruch)", "Laodiceans" -], ea = dc(); +], ea = pc(); function We(t, e = !0) { return e && (t = t.toUpperCase()), t in ea ? ea[t] : 0; } function uo(t) { return We(t) > 0; } -function ec(t) { +function nc(t) { const e = typeof t == "string" ? We(t) : t; return e >= 40 && e <= 66; } -function nc(t) { +function rc(t) { return (typeof t == "string" ? We(t) : t) <= 39; } function di(t) { return t <= 66; } -function rc(t) { +function oc(t) { const e = typeof t == "string" ? We(t) : t; return wi(e) && !di(e); } -function* oc() { +function* ac() { for (let t = 1; t <= ye.length; t++) yield t; } -const ac = 1, pi = ye.length; -function ic() { +const ic = 1, pi = ye.length; +function sc() { return ["XXA", "XXB", "XXC", "XXD", "XXE", "XXF", "XXG"]; } function wo(t, e = "***") { @@ -401,21 +401,21 @@ function wo(t, e = "***") { function ui(t) { return t <= 0 || t > pi ? "******" : ci[t - 1]; } -function sc(t) { +function lc(t) { return ui(We(t)); } function wi(t) { const e = typeof t == "number" ? wo(t) : t; return uo(e) && !po.includes(e); } -function lc(t) { +function cc(t) { const e = typeof t == "number" ? wo(t) : t; return uo(e) && po.includes(e); } -function cc(t) { +function dc(t) { return ci[t - 1].includes("*obsolete*"); } -function dc() { +function pc() { const t = {}; for (let e = 0; e < ye.length; e++) t[ye[e]] = e + 1; @@ -426,20 +426,20 @@ const ot = { nonCanonicalIds: po, bookIdToNumber: We, isBookIdValid: uo, - isBookNT: ec, - isBookOT: nc, + isBookNT: nc, + isBookOT: rc, isBookOTNT: di, - isBookDC: rc, - allBookNumbers: oc, - firstBook: ac, + isBookDC: oc, + allBookNumbers: ac, + firstBook: ic, lastBook: pi, - extraBooks: ic, + extraBooks: sc, bookNumberToId: wo, bookNumberToEnglishName: ui, - bookIdToEnglishName: sc, + bookIdToEnglishName: lc, isCanonical: wi, - isExtraMaterial: lc, - isObsolete: cc + isExtraMaterial: cc, + isObsolete: dc }; var Ht = /* @__PURE__ */ ((t) => (t[t.Unknown = 0] = "Unknown", t[t.Original = 1] = "Original", t[t.Septuagint = 2] = "Septuagint", t[t.Vulgate = 3] = "Vulgate", t[t.English = 4] = "English", t[t.RussianProtestant = 5] = "RussianProtestant", t[t.RussianOrthodox = 6] = "RussianOrthodox", t))(Ht || {}); const $t = class { @@ -465,7 +465,7 @@ function na(t, e) { return t.split(n); } var fi = /* @__PURE__ */ ((t) => (t[t.Valid = 0] = "Valid", t[t.UnknownVersification = 1] = "UnknownVersification", t[t.OutOfRange = 2] = "OutOfRange", t[t.VerseOutOfOrder = 3] = "VerseOutOfOrder", t[t.VerseRepeated = 4] = "VerseRepeated", t))(fi || {}); -const St = class nt { +const Tt = class nt { constructor(e, n, r, o) { if (et(this, "firstChapter"), et(this, "lastChapter"), et(this, "lastVerse"), et(this, "hasSegmentsDefined"), et(this, "text"), et(this, "BBBCCCVVVS"), et(this, "longHashCode"), et(this, "versification"), et(this, "rtlMark", "‏"), et(this, "_bookNum", 0), et(this, "_chapterNum", 0), et(this, "_verseNum", 0), et(this, "_verse"), r == null && o == null) if (e != null && typeof e == "string") { @@ -826,13 +826,13 @@ const St = class nt { this.bookNum = ot.bookIdToNumber(e), this.chapter = n, this.verse = r; } }; -et(St, "defaultVersification", ue.English), et(St, "verseRangeSeparator", "-"), et(St, "verseSequenceIndicator", ","), et(St, "verseRangeSeparators", [St.verseRangeSeparator]), et(St, "verseSequenceIndicators", [St.verseSequenceIndicator]), et(St, "chapterDigitShifter", 1e3), et(St, "bookDigitShifter", St.chapterDigitShifter * St.chapterDigitShifter), et(St, "bcvMaxValue", St.chapterDigitShifter - 1), /** +et(Tt, "defaultVersification", ue.English), et(Tt, "verseRangeSeparator", "-"), et(Tt, "verseSequenceIndicator", ","), et(Tt, "verseRangeSeparators", [Tt.verseRangeSeparator]), et(Tt, "verseSequenceIndicators", [Tt.verseSequenceIndicator]), et(Tt, "chapterDigitShifter", 1e3), et(Tt, "bookDigitShifter", Tt.chapterDigitShifter * Tt.chapterDigitShifter), et(Tt, "bcvMaxValue", Tt.chapterDigitShifter - 1), /** * The valid status of the VerseRef. */ -et(St, "ValidStatusType", fi); +et(Tt, "ValidStatusType", fi); class tn extends Error { } -const fo = wt.Root, mi = wt.Trigger, pc = wt.Group, mh = wt.Portal, hh = wt.Sub, gh = wt.RadioGroup, uc = T.forwardRef(({ className: t, inset: e, children: n, ...r }, o) => /* @__PURE__ */ x( +const fo = wt.Root, mi = wt.Trigger, uc = wt.Group, fh = wt.Portal, mh = wt.Sub, hh = wt.RadioGroup, wc = T.forwardRef(({ className: t, inset: e, children: n, ...r }, o) => /* @__PURE__ */ x( wt.SubTrigger, { ref: o, @@ -848,8 +848,8 @@ const fo = wt.Root, mi = wt.Trigger, pc = wt.Group, mh = wt.Portal, hh = wt.Sub, ] } )); -uc.displayName = wt.SubTrigger.displayName; -const wc = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( +wc.displayName = wt.SubTrigger.displayName; +const fc = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( wt.SubContent, { ref: n, @@ -860,7 +860,7 @@ const wc = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( ...e } )); -wc.displayName = wt.SubContent.displayName; +fc.displayName = wt.SubContent.displayName; const rr = T.forwardRef(({ className: t, sideOffset: e = 4, ...n }, r) => /* @__PURE__ */ s(wt.Portal, { children: /* @__PURE__ */ s( wt.Content, { @@ -940,7 +940,7 @@ const or = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( } )); or.displayName = wt.Separator.displayName; -function fc({ className: t, ...e }) { +function mc({ className: t, ...e }) { return /* @__PURE__ */ s( "span", { @@ -949,8 +949,8 @@ function fc({ className: t, ...e }) { } ); } -fc.displayName = "DropdownMenuShortcut"; -const mc = Qn( +mc.displayName = "DropdownMenuShortcut"; +const hc = Qn( ({ bookId: t, handleSelectBook: e, @@ -998,14 +998,14 @@ const mc = Qn( t ) ); -function hc({ +function gc({ handleSelectChapter: t, endChapter: e, activeChapter: n, highlightedChapter: r, handleHighlightedChapter: o }) { - const a = Array.from({ length: e }, (l, c) => c + 1), i = Tt( + const a = Array.from({ length: e }, (l, c) => c + 1), i = Et( (l) => { o(l); }, @@ -1035,26 +1035,26 @@ function hc({ l )) }); } -function gc({ handleSort: t, handleLocationHistory: e, handleBookmarks: n }) { +function bc({ handleSort: t, handleLocationHistory: e, handleBookmarks: n }) { return /* @__PURE__ */ x(Sn, { className: "tw-flex tw-justify-between", children: [ /* @__PURE__ */ s("p", { className: "tw-inline-block tw-align-middle", children: "Go To" }), /* @__PURE__ */ x("div", { className: "tw-flex tw-items-center", children: [ /* @__PURE__ */ s( - el, + rl, { onClick: t, className: "tw-m-2 tw-h-4 tw-w-4 tw-cursor-pointer tw-gap-2" } ), /* @__PURE__ */ s( - nl, + ol, { onClick: e, className: "tw-m-2 tw-h-4 tw-w-4 tw-cursor-pointer tw-gap-2" } ), /* @__PURE__ */ s( - rl, + al, { onClick: n, className: "tw-m-2 tw-h-4 tw-w-4 tw-cursor-pointer tw-gap-2" @@ -1063,40 +1063,40 @@ function gc({ handleSort: t, handleLocationHistory: e, handleBookmarks: n }) { ] }) ] }); } -const pn = ot.allBookIds, bc = { +const pn = ot.allBookIds, vc = { OT: "Old Testament", NT: "New Testament", DC: "Deuterocanon" -}, ra = ["OT", "NT", "DC"], vc = 32 + 32 + 32, yc = [ +}, ra = ["OT", "NT", "DC"], yc = 32 + 32 + 32, xc = [ /^(\w+)$/i, // Matches a single word (book name or id) /^(\w+)(?:\s(\d+))$/i, // Matches a word followed by a chapter number /^(\w+)(?:\s(\d+):(\d+))$/i // Matches a word followed by a chapter and verse number -], xc = (t) => ({ +], Nc = (t) => ({ OT: pn.filter((n) => ot.isBookOT(n)), NT: pn.filter((n) => ot.isBookNT(n)), DC: pn.filter((n) => ot.isBookDC(n)) -})[t], en = (t) => Rl(ot.bookIdToNumber(t)); -function Nc() { +})[t], en = (t) => Pl(ot.bookIdToNumber(t)); +function kc() { return pn.map((e) => ot.bookIdToEnglishName(e)); } -function kc(t) { - return Nc().includes(t); -} function Ec(t) { + return kc().includes(t); +} +function Sc(t) { const e = t.toLowerCase().replace(/^\w/, (n) => n.toUpperCase()); - if (kc(e)) + if (Ec(e)) return pn.find((r) => ot.bookIdToEnglishName(r) === e); } -function bh({ scrRef: t, handleSubmit: e }) { +function gh({ scrRef: t, handleSubmit: e }) { const [n, r] = ut(""), [o, a] = ut( ot.bookNumberToId(t.bookNum) ), [i, l] = ut(t.chapterNum ?? 0), [c, d] = ut( ot.bookNumberToId(t.bookNum) - ), [p, h] = ut(!1), [w, g] = ut(p), v = ge(void 0), f = ge(void 0), m = ge(void 0), E = Tt( - (k) => xc(k).filter((B) => { + ), [p, h] = ut(!1), [w, g] = ut(p), v = ge(void 0), f = ge(void 0), m = ge(void 0), E = Et( + (k) => Nc(k).filter((B) => { const D = ot.bookIdToEnglishName(B).toLowerCase(), J = n.replace(/[^a-zA-Z]/g, "").toLowerCase(); return D.includes(J) || // Match book name B.toLowerCase().includes(J); @@ -1104,13 +1104,13 @@ function bh({ scrRef: t, handleSubmit: e }) { [n] ), _ = (k) => { r(k); - }, C = ge(!1), S = Tt((k) => { + }, C = ge(!1), S = Et((k) => { if (C.current) { C.current = !1; return; } h(k); - }, []), b = Tt( + }, []), b = Et( (k, B, D, J) => { if (l( ot.bookNumberToId(t.bookNum) !== k ? 1 : t.chapterNum @@ -1125,13 +1125,13 @@ function bh({ scrRef: t, handleSubmit: e }) { a(o !== k ? k : ""), h(!B); }, [e, t.bookNum, t.chapterNum, o] - ), A = (k) => { + ), I = (k) => { k <= 0 || k > en(o) || b(o, !0, k); - }, z = Tt(() => { - yc.forEach((k) => { + }, z = Et(() => { + xc.forEach((k) => { const B = n.match(k); if (B) { - const [D, J = void 0, q = void 0] = B.slice(1), U = Ec(D); + const [D, J = void 0, q = void 0] = B.slice(1), U = Sc(D); (ot.isBookIdValid(D) || U) && b( U ?? D, !0, @@ -1140,7 +1140,7 @@ function bh({ scrRef: t, handleSubmit: e }) { ); } }); - }, [b, n]), H = Tt( + }, [b, n]), H = Et( (k) => { p ? (k.key === "ArrowDown" || k.key === "ArrowUp") && (typeof m < "u" && // Ref uses null // eslint-disable-next-line no-null/no-null @@ -1186,7 +1186,7 @@ function bh({ scrRef: t, handleSubmit: e }) { }, [p]), ta(() => { const k = setTimeout(() => { if (w && f.current && m.current) { - const D = m.current.offsetTop - vc; + const D = m.current.offsetTop - yc; f.current.scrollTo({ top: D, behavior: "instant" }); } }, 10); @@ -1195,7 +1195,7 @@ function bh({ scrRef: t, handleSubmit: e }) { }; }, [w]), /* @__PURE__ */ s("div", { className: "pr-twp tw-flex", children: /* @__PURE__ */ x(fo, { modal: !1, open: p, onOpenChange: S, children: [ /* @__PURE__ */ s(mi, { asChild: !0, children: /* @__PURE__ */ s( - Zl, + Ql, { ref: v, value: n, @@ -1221,7 +1221,7 @@ function bh({ scrRef: t, handleSubmit: e }) { ref: f, children: [ /* @__PURE__ */ s( - gc, + bc, { handleSort: () => console.log("sorting"), handleLocationHistory: () => console.log("location history"), @@ -1230,9 +1230,9 @@ function bh({ scrRef: t, handleSubmit: e }) { ), ra.map( (k, B) => E(k).length > 0 && /* @__PURE__ */ x("div", { children: [ - /* @__PURE__ */ s(Sn, { className: "tw-font-semibold tw-text-foreground/80", children: bc[k] }), + /* @__PURE__ */ s(Sn, { className: "tw-font-semibold tw-text-foreground/80", children: vc[k] }), E(k).map((D) => /* @__PURE__ */ s("div", { children: /* @__PURE__ */ s( - mc, + hc, { bookId: D, handleSelectBook: () => b(D, !1), @@ -1244,9 +1244,9 @@ function bh({ scrRef: t, handleSubmit: e }) { o === D && (m.current = J); }, children: /* @__PURE__ */ s( - hc, + gc, { - handleSelectChapter: A, + handleSelectChapter: I, endChapter: en(D), activeChapter: t.bookNum === ot.bookIdToNumber(D) ? t.chapterNum : 0, highlightedChapter: i, @@ -1265,7 +1265,7 @@ function bh({ scrRef: t, handleSubmit: e }) { ) ] }) }); } -const Sc = Xe( +const Tc = Xe( "pr-twp tw-inline-flex tw-items-center tw-justify-center tw-whitespace-nowrap tw-rounded-md tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-colors focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50", { variants: { @@ -1290,12 +1290,12 @@ const Sc = Xe( } } ), gt = T.forwardRef( - ({ className: t, variant: e, size: n, asChild: r = !1, ...o }, a) => /* @__PURE__ */ s(r ? He : "button", { className: N(Sc({ variant: e, size: n, className: t })), ref: a, ...o }) + ({ className: t, variant: e, size: n, asChild: r = !1, ...o }, a) => /* @__PURE__ */ s(r ? He : "button", { className: N(Tc({ variant: e, size: n, className: t })), ref: a, ...o }) ); gt.displayName = "Button"; -const Tc = Xe( +const Cc = Xe( "tw-text-sm tw-font-medium tw-leading-none peer-disabled:tw-cursor-not-allowed peer-disabled:tw-opacity-70" -), Xt = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s(ti.Root, { ref: n, className: N("pr-twp", Tc(), t), ...e })); +), Xt = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s(ti.Root, { ref: n, className: N("pr-twp", Cc(), t), ...e })); Xt.displayName = ti.Root.displayName; const bi = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( mn.Root, @@ -1319,7 +1319,7 @@ const Wr = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( } )); Wr.displayName = mn.Item.displayName; -const Cc = hn.Root, Oc = hn.Trigger, vi = T.forwardRef(({ className: t, align: e = "center", sideOffset: n = 4, ...r }, o) => /* @__PURE__ */ s(hn.Portal, { children: /* @__PURE__ */ s( +const Oc = hn.Root, Rc = hn.Trigger, vi = T.forwardRef(({ className: t, align: e = "center", sideOffset: n = 4, ...r }, o) => /* @__PURE__ */ s(hn.Portal, { children: /* @__PURE__ */ s( hn.Content, { ref: o, @@ -1333,7 +1333,7 @@ const Cc = hn.Root, Oc = hn.Trigger, vi = T.forwardRef(({ className: t, align: e } ) })); vi.displayName = hn.Content.displayName; -const Rc = vt.Portal, yi = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( +const _c = vt.Portal, yi = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( vt.Overlay, { ref: n, @@ -1345,7 +1345,7 @@ const Rc = vt.Portal, yi = T.forwardRef(({ className: t, ...e }, n) => /* @__PUR } )); yi.displayName = vt.Overlay.displayName; -const _c = T.forwardRef(({ className: t, children: e, ...n }, r) => /* @__PURE__ */ x(Rc, { children: [ +const Pc = T.forwardRef(({ className: t, children: e, ...n }, r) => /* @__PURE__ */ x(_c, { children: [ /* @__PURE__ */ s(yi, {}), /* @__PURE__ */ x( vt.Content, @@ -1366,8 +1366,8 @@ const _c = T.forwardRef(({ className: t, children: e, ...n }, r) => /* @__PURE__ } ) ] })); -_c.displayName = vt.Content.displayName; -const Pc = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( +Pc.displayName = vt.Content.displayName; +const $c = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( vt.Title, { ref: n, @@ -1375,8 +1375,8 @@ const Pc = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( ...e } )); -Pc.displayName = vt.Title.displayName; -const $c = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( +$c.displayName = vt.Title.displayName; +const Ic = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( vt.Description, { ref: n, @@ -1384,7 +1384,7 @@ const $c = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( ...e } )); -$c.displayName = vt.Description.displayName; +Ic.displayName = vt.Description.displayName; const xi = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( Rt, { @@ -1398,7 +1398,7 @@ const xi = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( )); xi.displayName = Rt.displayName; const Ni = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ x("div", { className: "tw-flex tw-items-center tw-border-b tw-px-3", children: [ - /* @__PURE__ */ s(ol, { className: "tw-me-2 tw-h-4 tw-w-4 tw-shrink-0 tw-opacity-50" }), + /* @__PURE__ */ s(il, { className: "tw-me-2 tw-h-4 tw-w-4 tw-shrink-0 tw-opacity-50" }), /* @__PURE__ */ s( Rt.Input, { @@ -1435,7 +1435,7 @@ const Ac = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( } )); Ac.displayName = Rt.Group.displayName; -const Ic = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( +const Mc = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( Rt.Separator, { ref: n, @@ -1443,7 +1443,7 @@ const Ic = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( ...e } )); -Ic.displayName = Rt.Separator.displayName; +Mc.displayName = Rt.Separator.displayName; const Si = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( Rt.Item, { @@ -1456,7 +1456,7 @@ const Si = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( } )); Si.displayName = Rt.Item.displayName; -function Mc(t) { +function Dc(t) { return typeof t == "string" ? t : typeof t == "number" ? t.toString() : t.label; } function qr({ @@ -1467,7 +1467,7 @@ function qr({ value: o, onChange: a = () => { }, - getOptionLabel: i = Mc, + getOptionLabel: i = Dc, buttonPlaceholder: l = "", textPlaceholder: c = "", commandEmptyMessage: d = "No option found", @@ -1477,8 +1477,8 @@ function qr({ ...g }) { const [v, f] = ut(!1); - return /* @__PURE__ */ x(Cc, { open: v, onOpenChange: f, ...g, children: [ - /* @__PURE__ */ s(Oc, { asChild: !0, children: /* @__PURE__ */ x( + return /* @__PURE__ */ x(Oc, { open: v, onOpenChange: f, ...g, children: [ + /* @__PURE__ */ s(Rc, { asChild: !0, children: /* @__PURE__ */ x( gt, { variant: p, @@ -1489,7 +1489,7 @@ function qr({ disabled: w, children: [ /* @__PURE__ */ s("span", { className: "tw-overflow-hidden tw-text-ellipsis tw-whitespace-nowrap", children: o ? i(o) : l }), - /* @__PURE__ */ s(al, { className: "tw-ms-2 tw-h-4 tw-w-4 tw-shrink-0 tw-opacity-50" }) + /* @__PURE__ */ s(sl, { className: "tw-ms-2 tw-h-4 tw-w-4 tw-shrink-0 tw-opacity-50" }) ] } ) }), @@ -1520,7 +1520,7 @@ function qr({ ] }) }) ] }); } -function Dc({ +function Bc({ startChapter: t, endChapter: e, handleSelectStartChapter: n, @@ -1528,7 +1528,7 @@ function Dc({ isDisabled: o = !1, chapterCount: a }) { - const i = At( + const i = It( () => Array.from({ length: a }, (d, p) => p + 1), [a] ); @@ -1565,13 +1565,13 @@ function Dc({ ) ] }); } -var Bc = /* @__PURE__ */ ((t) => (t.CURRENT_BOOK = "current book", t.CHOOSE_BOOKS = "choose books", t))(Bc || {}); -const vh = Object.freeze([ +var jc = /* @__PURE__ */ ((t) => (t.CURRENT_BOOK = "current book", t.CHOOSE_BOOKS = "choose books", t))(jc || {}); +const bh = Object.freeze([ "%webView_bookSelector_currentBook%", "%webView_bookSelector_choose%", "%webView_bookSelector_chooseBooks%" ]), _r = (t, e) => t[e] ?? e; -function yh({ +function vh({ handleBookSelectionModeChange: t, currentBookName: e, onSelectBooks: n, @@ -1606,7 +1606,7 @@ function yh({ ] }), /* @__PURE__ */ s(Xt, { className: "tw-flex tw-items-center", children: e }), /* @__PURE__ */ s("div", { className: "tw-flex tw-items-center tw-justify-end", children: /* @__PURE__ */ s( - Dc, + Bc, { isDisabled: g === "choose books", handleSelectStartChapter: c, @@ -1639,10 +1639,10 @@ function yh({ } ); } -function jc({ table: t }) { +function Vc({ table: t }) { return /* @__PURE__ */ x(fo, { children: [ - /* @__PURE__ */ s(Ol, { asChild: !0, children: /* @__PURE__ */ x(gt, { variant: "outline", size: "sm", className: "tw-ml-auto tw-hidden tw-h-8 lg:tw-flex", children: [ - /* @__PURE__ */ s(il, { className: "tw-mr-2 tw-h-4 tw-w-4" }), + /* @__PURE__ */ s(_l, { asChild: !0, children: /* @__PURE__ */ x(gt, { variant: "outline", size: "sm", className: "tw-ml-auto tw-hidden tw-h-8 lg:tw-flex", children: [ + /* @__PURE__ */ s(ll, { className: "tw-mr-2 tw-h-4 tw-w-4" }), "View" ] }) }), /* @__PURE__ */ x(rr, { align: "end", className: "tw-w-[150px]", children: [ @@ -1661,7 +1661,7 @@ function jc({ table: t }) { ] }) ] }); } -const gn = bt.Root, Vc = bt.Group, bn = bt.Value, De = T.forwardRef(({ className: t, children: e, ...n }, r) => /* @__PURE__ */ x( +const gn = bt.Root, zc = bt.Group, bn = bt.Value, De = T.forwardRef(({ className: t, children: e, ...n }, r) => /* @__PURE__ */ x( bt.Trigger, { ref: r, @@ -1683,7 +1683,7 @@ const Ti = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( ref: n, className: N("tw-flex tw-cursor-default tw-items-center tw-justify-center tw-py-1", t), ...e, - children: /* @__PURE__ */ s(sl, { className: "tw-h-4 tw-w-4" }) + children: /* @__PURE__ */ s(cl, { className: "tw-h-4 tw-w-4" }) } )); Ti.displayName = bt.ScrollUpButton.displayName; @@ -1725,7 +1725,7 @@ const Be = T.forwardRef(({ className: t, children: e, position: n = "popper", .. } ) })); Be.displayName = bt.Content.displayName; -const zc = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( +const Lc = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( bt.Label, { ref: n, @@ -1733,7 +1733,7 @@ const zc = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( ...e } )); -zc.displayName = bt.Label.displayName; +Lc.displayName = bt.Label.displayName; const Gt = T.forwardRef(({ className: t, children: e, ...n }, r) => /* @__PURE__ */ x( bt.Item, { @@ -1750,7 +1750,7 @@ const Gt = T.forwardRef(({ className: t, children: e, ...n }, r) => /* @__PURE__ } )); Gt.displayName = bt.Item.displayName; -const Lc = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( +const Fc = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( bt.Separator, { ref: n, @@ -1758,8 +1758,8 @@ const Lc = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( ...e } )); -Lc.displayName = bt.Separator.displayName; -function Fc({ table: t }) { +Fc.displayName = bt.Separator.displayName; +function Uc({ table: t }) { return /* @__PURE__ */ s("div", { className: "tw-flex tw-items-center tw-justify-between tw-px-2 tw-pb-3 tw-pt-3", children: /* @__PURE__ */ x("div", { className: "tw-flex tw-items-center tw-space-x-6 lg:tw-space-x-8", children: [ /* @__PURE__ */ x("div", { className: "tw-flex-1 tw-text-sm tw-text-muted-foreground", children: [ t.getFilteredSelectedRowModel().rows.length, @@ -1801,7 +1801,7 @@ function Fc({ table: t }) { disabled: !t.getCanPreviousPage(), children: [ /* @__PURE__ */ s("span", { className: "tw-sr-only", children: "Go to first page" }), - /* @__PURE__ */ s(ll, { className: "tw-h-4 tw-w-4" }) + /* @__PURE__ */ s(dl, { className: "tw-h-4 tw-w-4" }) ] } ), @@ -1815,7 +1815,7 @@ function Fc({ table: t }) { disabled: !t.getCanPreviousPage(), children: [ /* @__PURE__ */ s("span", { className: "tw-sr-only", children: "Go to previous page" }), - /* @__PURE__ */ s(cl, { className: "tw-h-4 tw-w-4" }) + /* @__PURE__ */ s(pl, { className: "tw-h-4 tw-w-4" }) ] } ), @@ -1829,7 +1829,7 @@ function Fc({ table: t }) { disabled: !t.getCanNextPage(), children: [ /* @__PURE__ */ s("span", { className: "tw-sr-only", children: "Go to next page" }), - /* @__PURE__ */ s(dl, { className: "tw-h-4 tw-w-4" }) + /* @__PURE__ */ s(ul, { className: "tw-h-4 tw-w-4" }) ] } ), @@ -1843,7 +1843,7 @@ function Fc({ table: t }) { disabled: !t.getCanNextPage(), children: [ /* @__PURE__ */ s("span", { className: "tw-sr-only", children: "Go to last page" }), - /* @__PURE__ */ s(pl, { className: "tw-h-4 tw-w-4" }) + /* @__PURE__ */ s(wl, { className: "tw-h-4 tw-w-4" }) ] } ) @@ -1874,7 +1874,7 @@ const ir = T.forwardRef(({ className: t, stickyHeader: e, ...n }, r) => /* @__PU ir.displayName = "TableHeader"; const sr = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s("tbody", { ref: n, className: N("[&_tr:last-child]:tw-border-0", t), ...e })); sr.displayName = "TableBody"; -const Uc = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( +const Gc = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( "tfoot", { ref: n, @@ -1882,7 +1882,7 @@ const Uc = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( ...e } )); -Uc.displayName = "TableFooter"; +Gc.displayName = "TableFooter"; const oe = T.forwardRef( ({ className: t, ...e }, n) => /* @__PURE__ */ s( "tr", @@ -1918,7 +1918,7 @@ const je = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( } )); je.displayName = "TableCell"; -const Gc = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( +const Hc = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( "caption", { ref: n, @@ -1926,8 +1926,8 @@ const Gc = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( ...e } )); -Gc.displayName = "TableCaption"; -function Hc({ +Hc.displayName = "TableCaption"; +function Xc({ columns: t, data: e, enablePagination: n = !1, @@ -1942,11 +1942,11 @@ function Hc({ data: e, columns: t, getCoreRowModel: ni(), - ...n && { getPaginationRowModel: Al() }, + ...n && { getPaginationRowModel: Ml() }, onSortingChange: c, getSortedRowModel: ri(), onColumnFiltersChange: p, - getFilteredRowModel: Il(), + getFilteredRowModel: Dl(), onColumnVisibilityChange: w, onRowSelectionChange: v, state: { @@ -1957,7 +1957,7 @@ function Hc({ } }); return /* @__PURE__ */ x("div", { className: "pr-twp", children: [ - o && /* @__PURE__ */ s(jc, { table: f }), + o && /* @__PURE__ */ s(Vc, { table: f }), /* @__PURE__ */ x(ar, { stickyHeader: a, children: [ /* @__PURE__ */ s(ir, { stickyHeader: a, children: f.getHeaderGroups().map((E) => /* @__PURE__ */ s(oe, { children: E.headers.map((_) => /* @__PURE__ */ s(vn, { children: _.isPlaceholder ? void 0 : dn(_.column.columnDef.header, _.getContext()) }, _.id)) }, E.id)) }), /* @__PURE__ */ s(sr, { children: (m = f.getRowModel().rows) != null && m.length ? f.getRowModel().rows.map((E) => /* @__PURE__ */ s( @@ -1992,15 +1992,15 @@ function Hc({ } ) ] }), - n && r && /* @__PURE__ */ s(Fc, { table: f }) + n && r && /* @__PURE__ */ s(Uc, { table: f }) ] }); } -function Xc({ +function Yc({ occurrenceData: t, setScriptureReference: e, localizedStrings: n }) { - const r = n["%webView_inventory_occurrences_table_header_reference%"], o = n["%webView_inventory_occurrences_table_header_occurrence%"], a = At(() => { + const r = n["%webView_inventory_occurrences_table_header_reference%"], o = n["%webView_inventory_occurrences_table_header_occurrence%"], a = It(() => { const i = []; return t.forEach((l) => { i.some((c) => co(c, l)) || i.push(l); @@ -2045,14 +2045,14 @@ const ho = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( } )); ho.displayName = Xr.Root.displayName; -const Yc = (t) => t.split(/(?:\r?\n|\r)|(?=(?:\\(?:v|c|id)))/g), oa = (t) => { +const Wc = (t) => t.split(/(?:\r?\n|\r)|(?=(?:\\(?:v|c|id)))/g), oa = (t) => { const e = /^\\[vc]\s+(\d+)/, n = t.match(e); if (n) return +n[1]; -}, Wc = (t) => { +}, qc = (t) => { const e = t.match(/^\\id\s+([A-Za-z]+)/); return e ? ot.bookIdToNumber(e[1]) : 0; -}, qc = (t, e, n) => n.includes(t) ? "unapproved" : e.includes(t) ? "approved" : "unknown", Oi = Xe( +}, Kc = (t, e, n) => n.includes(t) ? "unapproved" : e.includes(t) ? "approved" : "unknown", Oi = Xe( "pr-twp tw-inline-flex tw-items-center tw-justify-center tw-rounded-md tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-colors hover:tw-bg-muted hover:tw-text-muted-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50 data-[state=on]:tw-bg-accent data-[state=on]:tw-text-accent-foreground", { variants: { @@ -2071,7 +2071,7 @@ const Yc = (t) => t.split(/(?:\r?\n|\r)|(?=(?:\\(?:v|c|id)))/g), oa = (t) => { size: "default" } } -), Kc = T.forwardRef(({ className: t, variant: e, size: n, ...r }, o) => /* @__PURE__ */ s( +), Jc = T.forwardRef(({ className: t, variant: e, size: n, ...r }, o) => /* @__PURE__ */ s( oi.Root, { ref: o, @@ -2079,7 +2079,7 @@ const Yc = (t) => t.split(/(?:\r?\n|\r)|(?=(?:\\(?:v|c|id)))/g), oa = (t) => { ...r } )); -Kc.displayName = oi.Root.displayName; +Jc.displayName = oi.Root.displayName; const Ri = T.createContext({ size: "default", variant: "default" @@ -2118,21 +2118,21 @@ const Un = T.forwardRef(({ className: t, children: e, variant: n, size: r, ...o ); }); Un.displayName = nr.Item.displayName; -const lr = (t) => t === "asc" ? /* @__PURE__ */ s(ml, { className: "tw-ms-2 tw-h-4 tw-w-4" }) : t === "desc" ? /* @__PURE__ */ s(hl, { className: "tw-ms-2 tw-h-4 tw-w-4" }) : /* @__PURE__ */ s(gl, { className: "tw-ms-2 tw-h-4 tw-w-4" }), xh = (t) => ({ +const lr = (t) => t === "asc" ? /* @__PURE__ */ s(gl, { className: "tw-ms-2 tw-h-4 tw-w-4" }) : t === "desc" ? /* @__PURE__ */ s(bl, { className: "tw-ms-2 tw-h-4 tw-w-4" }) : /* @__PURE__ */ s(vl, { className: "tw-ms-2 tw-h-4 tw-w-4" }), yh = (t) => ({ accessorKey: "item", accessorFn: (e) => e.items[0], header: ({ column: e }) => /* @__PURE__ */ x(gt, { variant: "ghost", onClick: () => e.toggleSorting(void 0), children: [ t, lr(e.getIsSorted()) ] }) -}), Jc = (t, e) => ({ +}), Zc = (t, e) => ({ accessorKey: `item${e}`, accessorFn: (n) => n.items[e], header: ({ column: n }) => /* @__PURE__ */ x(gt, { variant: "ghost", onClick: () => n.toggleSorting(void 0), children: [ t, lr(n.getIsSorted()) ] }) -}), Nh = (t) => ({ +}), xh = (t) => ({ accessorKey: "count", header: ({ column: e }) => /* @__PURE__ */ s("div", { className: "tw-flex tw-justify-end tw-tabular-nums", children: /* @__PURE__ */ x(gt, { variant: "ghost", onClick: () => e.toggleSorting(void 0), children: [ t, @@ -2148,7 +2148,7 @@ const lr = (t) => t === "asc" ? /* @__PURE__ */ s(ml, { className: "tw-ms-2 tw-h t.forEach((c) => { e === "unapproved" ? l.includes(c) || l.push(c) : l = l.filter((d) => d !== c); }), a(l); -}, kh = (t, e, n, r, o) => ({ +}, Nh = (t, e, n, r, o) => ({ accessorKey: "status", header: ({ column: a }) => /* @__PURE__ */ s("div", { className: "tw-flex tw-justify-center", children: /* @__PURE__ */ x(gt, { variant: "ghost", onClick: () => a.toggleSorting(void 0), children: [ t, @@ -2169,7 +2169,7 @@ const lr = (t) => t === "asc" ? /* @__PURE__ */ s(ml, { className: "tw-ms-2 tw-h o ), value: "approved", - children: /* @__PURE__ */ s(ul, {}) + children: /* @__PURE__ */ s(fl, {}) } ), /* @__PURE__ */ s( @@ -2184,7 +2184,7 @@ const lr = (t) => t === "asc" ? /* @__PURE__ */ s(ml, { className: "tw-ms-2 tw-h o ), value: "unapproved", - children: /* @__PURE__ */ s(wl, {}) + children: /* @__PURE__ */ s(ml, {}) } ), /* @__PURE__ */ s( @@ -2199,12 +2199,12 @@ const lr = (t) => t === "asc" ? /* @__PURE__ */ s(ml, { className: "tw-ms-2 tw-h o ), value: "unknown", - children: /* @__PURE__ */ s(fl, {}) + children: /* @__PURE__ */ s(hl, {}) } ) ] }); } -}), Eh = Object.freeze([ +}), kh = Object.freeze([ "%webView_inventory_all%", "%webView_inventory_approved%", "%webView_inventory_unapproved%", @@ -2216,18 +2216,18 @@ const lr = (t) => t === "asc" ? /* @__PURE__ */ s(ml, { className: "tw-ms-2 tw-h "%webView_inventory_show_additional_items%", "%webView_inventory_occurrences_table_header_reference%", "%webView_inventory_occurrences_table_header_occurrence%" -]), Zc = (t, e, n) => { +]), Qc = (t, e, n) => { let r = t; return e !== "all" && (r = r.filter( (o) => e === "approved" && o.status === "approved" || e === "unapproved" && o.status === "unapproved" || e === "unknown" && o.status === "unknown" )), n !== "" && (r = r.filter((o) => o.items[0].includes(n))), r; -}, Qc = (t, e, n, r, o) => { +}, td = (t, e, n, r, o) => { if (!t) return []; const a = []; let i = e.bookNum, l = e.chapterNum, c = e.verseNum; - return Yc(t).forEach((p) => { - p.startsWith("\\id") && (i = Wc(p), l = 0, c = 0), p.startsWith("\\c") && (l = oa(p), c = 0), p.startsWith("\\v") && (c = oa(p), l === 0 && (l = e.chapterNum)); + return Wc(t).forEach((p) => { + p.startsWith("\\id") && (i = qc(p), l = 0, c = 0), p.startsWith("\\c") && (l = oa(p), c = 0), p.startsWith("\\v") && (c = oa(p), l === 0 && (l = e.chapterNum)); let h = o.exec(p) ?? void 0; for (; h; ) { const w = []; @@ -2238,7 +2238,7 @@ const lr = (t) => t === "asc" ? /* @__PURE__ */ s(ml, { className: "tw-ms-2 tw-h chapterNum: l !== void 0 ? l : -1, verseNum: c !== void 0 ? c : -1 }, - text: _l(p, Math.max(0, g - 25), Math.min(g + 25, p.length)) + text: $l(p, Math.max(0, g - 25), Math.min(g + 25, p.length)) }; if (v) v.count += 1, v.occurrences.push(f); @@ -2246,7 +2246,7 @@ const lr = (t) => t === "asc" ? /* @__PURE__ */ s(ml, { className: "tw-ms-2 tw-h const m = { items: w, count: 1, - status: qc(w[0], n, r), + status: Kc(w[0], n, r), occurrences: [f] }; a.push(m); @@ -2255,7 +2255,7 @@ const lr = (t) => t === "asc" ? /* @__PURE__ */ s(ml, { className: "tw-ms-2 tw-h } }), a; }, Jt = (t, e) => t[e] ?? e; -function Sh({ +function Eh({ scriptureReference: t, setScriptureReference: e, localizedStrings: n, @@ -2271,13 +2271,13 @@ function Sh({ const h = Jt(n, "%webView_inventory_all%"), w = Jt(n, "%webView_inventory_approved%"), g = Jt(n, "%webView_inventory_unapproved%"), v = Jt(n, "%webView_inventory_unknown%"), f = Jt(n, "%webView_inventory_scope_currentBook%"), m = Jt(n, "%webView_inventory_scope_chapter%"), E = Jt(n, "%webView_inventory_scope_verse%"), _ = Jt(n, "%webView_inventory_filter_text%"), C = Jt( n, "%webView_inventory_show_additional_items%" - ), [S, b] = ut(!1), [A, z] = ut("all"), [H, O] = ut(""), [$, k] = ut([]), B = At(() => l ? r instanceof RegExp ? Qc( + ), [S, b] = ut(!1), [I, z] = ut("all"), [H, O] = ut(""), [$, k] = ut([]), B = It(() => l ? r instanceof RegExp ? td( l, t, a, i, r - ) : r(l, t, a, i) : [], [l, r, t, a, i]), D = At(() => { + ) : r(l, t, a, i) : [], [l, r, t, a, i]), D = It(() => { if (S) return B; const y = []; @@ -2292,7 +2292,7 @@ function Sh({ status: R.status }); }), y; - }, [S, B]), J = At(() => Zc(D, A, H), [D, A, H]), q = At(() => { + }, [S, B]), J = It(() => Qc(D, I, H), [D, I, H]), q = It(() => { var L, F; if (!S) return p; @@ -2302,7 +2302,7 @@ function Sh({ const R = []; for (let V = 0; V < y; V++) R.push( - Jc( + Zc( ((F = o == null ? void 0 : o.tableHeaders) == null ? void 0 : F[V]) || "Additional Item", V + 1 ) @@ -2327,7 +2327,7 @@ function Sh({ z(y); else throw new Error(`Invalid status filter value: ${y}`); - }, rt = At(() => { + }, rt = It(() => { if (D.length === 0 || $.length === 0) return []; const y = D.filter((R) => co( @@ -2344,7 +2344,7 @@ function Sh({ gn, { onValueChange: (y) => at(y), - defaultValue: A, + defaultValue: I, children: [ /* @__PURE__ */ s(De, { className: "tw-m-1", children: /* @__PURE__ */ s(bn, { placeholder: "Select filter" }) }), /* @__PURE__ */ x(Be, { children: [ @@ -2390,7 +2390,7 @@ function Sh({ ] }) ] }), /* @__PURE__ */ s("div", { className: "tw-m-1 tw-flex-1 tw-overflow-auto tw-rounded-md tw-border", children: /* @__PURE__ */ s( - Hc, + Xc, { columns: q, data: J, @@ -2399,7 +2399,7 @@ function Sh({ } ) }), rt.length > 0 && /* @__PURE__ */ s("div", { className: "tw-m-1 tw-flex-1 tw-overflow-auto tw-rounded-md tw-border", children: /* @__PURE__ */ s( - Xc, + Yc, { occurrenceData: rt, setScriptureReference: e, @@ -2408,24 +2408,30 @@ function Sh({ ) }) ] }); } -function td({ onSearch: t, placeholder: e, isFullWidth: n }) { - const [r, o] = ut(""), a = (i) => { - o(i), t(i); +function Pi({ + className: t, + onSearch: e, + placeholder: n, + isFullWidth: r +}) { + const [o, a] = ut(""), i = (l) => { + a(l), e(l); }; return /* @__PURE__ */ s( Ye, { className: N( "tw-flex tw-h-10 tw-rounded-md tw-border tw-border-input tw-bg-background tw-px-3 tw-py-2 tw-text-sm tw-ring-offset-background file:tw-border-0 file:tw-bg-transparent file:tw-text-sm file:tw-font-medium placeholder:tw-text-muted-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-[color:hsl(240,5%,64.9%)] focus-visible:tw-ring-offset-2 disabled:tw-cursor-not-allowed disabled:tw-opacity-50", - { "tw-w-full": n } + { "tw-w-full": r }, + t ), - placeholder: e, - value: r, - onChange: (i) => a(i.target.value) + placeholder: n, + value: o, + onChange: (l) => i(l.target.value) } ); } -const Pi = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( +const $i = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( _t.Root, { orientation: "vertical", @@ -2434,8 +2440,8 @@ const Pi = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( ...e } )); -Pi.displayName = _t.List.displayName; -const $i = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( +$i.displayName = _t.List.displayName; +const Ii = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( _t.List, { ref: n, @@ -2446,7 +2452,7 @@ const $i = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( ...e } )); -$i.displayName = _t.List.displayName; +Ii.displayName = _t.List.displayName; const ed = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( _t.Trigger, { @@ -2470,7 +2476,7 @@ const ed = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( } )); Ai.displayName = _t.Content.displayName; -function Th({ +function Sh({ tabList: t, onSearch: e, searchPlaceholder: n, @@ -2482,7 +2488,7 @@ function Th({ /* @__PURE__ */ x("div", { className: "tw-sticky tw-top-0 tw-space-y-2 tw-pb-2", children: [ r ? /* @__PURE__ */ s("h1", { children: r }) : "", /* @__PURE__ */ s( - td, + Pi, { isFullWidth: o, onSearch: e, @@ -2490,8 +2496,8 @@ function Th({ } ) ] }), - /* @__PURE__ */ x(Pi, { dir: a, children: [ - /* @__PURE__ */ s($i, { children: t.map((i) => /* @__PURE__ */ s(ed, { value: i.value, children: i.value }, i.key)) }), + /* @__PURE__ */ x($i, { dir: a, children: [ + /* @__PURE__ */ s(Ii, { children: t.map((i) => /* @__PURE__ */ s(ed, { value: i.value, children: i.value }, i.key)) }), t.map((i) => /* @__PURE__ */ s(Ai, { value: i.value, children: i.content }, i.key)) ] }) ] }); @@ -2511,7 +2517,7 @@ const go = T.forwardRef(({ className: t, orientation: e = "horizontal", decorati } )); go.displayName = ai.Root.displayName; -const nd = vt.Root, rd = vt.Portal, Ii = M.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( +const nd = vt.Root, rd = vt.Portal, Mi = M.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( vt.Overlay, { className: N( @@ -2522,7 +2528,7 @@ const nd = vt.Root, rd = vt.Portal, Ii = M.forwardRef(({ className: t, ...e }, n ref: n } )); -Ii.displayName = vt.Overlay.displayName; +Mi.displayName = vt.Overlay.displayName; const od = Xe( "pr-twp tw-fixed tw-z-50 tw-gap-4 tw-bg-background tw-p-6 tw-shadow-lg tw-transition tw-ease-in-out data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-duration-300 data-[state=open]:tw-duration-500", { @@ -2538,8 +2544,8 @@ const od = Xe( side: "right" } } -), Mi = M.forwardRef(({ side: t = "right", className: e, children: n, ...r }, o) => /* @__PURE__ */ x(rd, { children: [ - /* @__PURE__ */ s(Ii, {}), +), Di = M.forwardRef(({ side: t = "right", className: e, children: n, ...r }, o) => /* @__PURE__ */ x(rd, { children: [ + /* @__PURE__ */ s(Mi, {}), /* @__PURE__ */ x(vt.Content, { ref: o, className: N(od({ side: t }), e), ...r, children: [ n, /* @__PURE__ */ x(vt.Close, { className: "tw-absolute tw-right-4 tw-top-4 tw-rounded-sm tw-opacity-70 tw-ring-offset-background tw-transition-opacity hover:tw-opacity-100 focus:tw-outline-none focus:tw-ring-2 focus:tw-ring-ring focus:tw-ring-offset-2 disabled:tw-pointer-events-none data-[state=open]:tw-bg-secondary", children: [ @@ -2548,7 +2554,7 @@ const od = Xe( ] }) ] }) ] })); -Mi.displayName = vt.Content.displayName; +Di.displayName = vt.Content.displayName; const ad = M.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( vt.Title, { @@ -2576,7 +2582,7 @@ function aa({ className: t, ...e }) { } ); } -const sd = En.Provider, ld = En.Root, cd = En.Trigger, Di = T.forwardRef(({ className: t, sideOffset: e = 4, ...n }, r) => /* @__PURE__ */ s( +const sd = En.Provider, ld = En.Root, cd = En.Trigger, Bi = T.forwardRef(({ className: t, sideOffset: e = 4, ...n }, r) => /* @__PURE__ */ s( En.Content, { ref: r, @@ -2588,7 +2594,7 @@ const sd = En.Provider, ld = En.Root, cd = En.Trigger, Di = T.forwardRef(({ clas ...n } )); -Di.displayName = En.Content.displayName; +Bi.displayName = En.Content.displayName; const $r = 768; function dd() { const [t, e] = M.useState(void 0); @@ -2599,14 +2605,14 @@ function dd() { return n.addEventListener("change", r), e(window.innerWidth < $r), () => n.removeEventListener("change", r); }, []), !!t; } -const pd = "sidebar:state", ud = 60 * 60 * 24 * 7, wd = "16rem", fd = "18rem", md = "3rem", hd = "b", Bi = T.createContext(void 0); +const pd = "sidebar:state", ud = 60 * 60 * 24 * 7, wd = "16rem", fd = "18rem", md = "3rem", hd = "b", ji = T.createContext(void 0); function cr() { - const t = T.useContext(Bi); + const t = T.useContext(ji); if (!t) throw new Error("useSidebar must be used within a SidebarProvider."); return t; } -const ji = T.forwardRef( +const Vi = T.forwardRef( ({ defaultOpen: t = !0, open: e, @@ -2641,7 +2647,7 @@ const ji = T.forwardRef( }), [m, g, v, c, d, p, f] ); - return /* @__PURE__ */ s(Bi.Provider, { value: E, children: /* @__PURE__ */ s(sd, { delayDuration: 0, children: /* @__PURE__ */ s( + return /* @__PURE__ */ s(ji.Provider, { value: E, children: /* @__PURE__ */ s(sd, { delayDuration: 0, children: /* @__PURE__ */ s( "div", { style: ( @@ -2653,7 +2659,8 @@ const ji = T.forwardRef( } ), className: N( - "tw-group/sidebar-wrapper pr-twp tw-flex tw-min-h-svh tw-w-full has-[[data-variant=inset]]:tw-bg-sidebar", + // Removed tw-min-h-svh + "tw-group/sidebar-wrapper pr-twp tw-flex tw-w-full has-[[data-variant=inset]]:tw-bg-sidebar", r ), ref: l, @@ -2663,8 +2670,8 @@ const ji = T.forwardRef( ) }) }); } ); -ji.displayName = "SidebarProvider"; -const Vi = T.forwardRef( +Vi.displayName = "SidebarProvider"; +const zi = T.forwardRef( ({ side: t = "left", variant: e = "sidebar", @@ -2686,7 +2693,7 @@ const Vi = T.forwardRef( children: o } ) : l ? /* @__PURE__ */ s(nd, { open: d, onOpenChange: p, ...a, children: /* @__PURE__ */ s( - Mi, + Di, { "data-sidebar": "sidebar", "data-mobile": "true", @@ -2748,7 +2755,7 @@ const Vi = T.forwardRef( ); } ); -Vi.displayName = "Sidebar"; +zi.displayName = "Sidebar"; const gd = T.forwardRef(({ className: t, onClick: e, ...n }, r) => { const { toggleSidebar: o } = cr(); return /* @__PURE__ */ x( @@ -2764,7 +2771,7 @@ const gd = T.forwardRef(({ className: t, onClick: e, ...n }, r) => { }, ...n, children: [ - /* @__PURE__ */ s(bl, {}), + /* @__PURE__ */ s(yl, {}), /* @__PURE__ */ s("span", { className: "tw-sr-only", children: "Toggle Sidebar" }) ] } @@ -2799,13 +2806,14 @@ const bd = T.forwardRef( } ); bd.displayName = "SidebarRail"; -const zi = T.forwardRef( +const Li = T.forwardRef( ({ className: t, ...e }, n) => /* @__PURE__ */ s( "main", { ref: n, className: N( - "tw-relative tw-flex tw-min-h-svh tw-flex-1 tw-flex-col tw-bg-background", + // Removed tw-min-h-svh + "tw-relative tw-flex tw-flex-1 tw-flex-col tw-bg-background", "peer-data-[variant=inset]:tw-min-h-[calc(100svh-theme(spacing.4))] md:peer-data-[variant=inset]:tw-m-2 md:peer-data-[state=collapsed]:peer-data-[variant=inset]:tw-ml-2 md:peer-data-[variant=inset]:tw-ml-0 md:peer-data-[variant=inset]:tw-rounded-xl md:peer-data-[variant=inset]:tw-shadow", t ), @@ -2813,7 +2821,7 @@ const zi = T.forwardRef( } ) ); -zi.displayName = "SidebarInset"; +Li.displayName = "SidebarInset"; const vd = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( Ye, { @@ -2861,7 +2869,7 @@ const Nd = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( } )); Nd.displayName = "SidebarSeparator"; -const Li = T.forwardRef( +const Fi = T.forwardRef( ({ className: t, ...e }, n) => /* @__PURE__ */ s( "div", { @@ -2875,7 +2883,7 @@ const Li = T.forwardRef( } ) ); -Li.displayName = "SidebarContent"; +Fi.displayName = "SidebarContent"; const Kr = T.forwardRef( ({ className: t, ...e }, n) => /* @__PURE__ */ s( "div", @@ -2930,7 +2938,7 @@ const Zr = T.forwardRef( ) ); Zr.displayName = "SidebarGroupContent"; -const Fi = T.forwardRef( +const Ui = T.forwardRef( ({ className: t, ...e }, n) => /* @__PURE__ */ s( "ul", { @@ -2941,8 +2949,8 @@ const Fi = T.forwardRef( } ) ); -Fi.displayName = "SidebarMenu"; -const Ui = T.forwardRef( +Ui.displayName = "SidebarMenu"; +const Gi = T.forwardRef( ({ className: t, ...e }, n) => /* @__PURE__ */ s( "li", { @@ -2953,9 +2961,10 @@ const Ui = T.forwardRef( } ) ); -Ui.displayName = "SidebarMenuItem"; +Gi.displayName = "SidebarMenuItem"; const Ed = Xe( - "tw-peer/menu-button tw-flex tw-w-full tw-items-center tw-gap-2 tw-overflow-hidden tw-rounded-md tw-p-2 tw-text-left tw-text-sm tw-outline-none tw-ring-sidebar-ring tw-transition-[width,height,padding] hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground focus-visible:tw-ring-2 active:tw-bg-sidebar-accent active:tw-text-sidebar-accent-foreground disabled:tw-pointer-events-none disabled:tw-opacity-50 tw-group-has-[[data-sidebar=menu-action]]/menu-item:pr-8 aria-disabled:tw-pointer-events-none aria-disabled:tw-opacity-50 data-[active=true]:tw-bg-sidebar-accent data-[active=true]:tw-font-medium data-[active=true]:tw-text-sidebar-accent-foreground data-[state=open]:hover:tw-bg-sidebar-accent data-[state=open]:hover:tw-text-sidebar-accent-foreground group-data-[collapsible=icon]:tw-!size-8 group-data-[collapsible=icon]:tw-!p-2 [&>span:last-child]:tw-truncate [&>svg]:tw-size-4 [&>svg]:tw-shrink-0", + // Removed data-[active=true]:tw-bg-sidebar-accent + "tw-peer/menu-button tw-flex tw-w-full tw-items-center tw-gap-2 tw-overflow-hidden tw-rounded-md tw-p-2 tw-text-left tw-text-sm tw-outline-none tw-ring-sidebar-ring tw-transition-[width,height,padding] hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground focus-visible:tw-ring-2 active:tw-bg-sidebar-accent active:tw-text-sidebar-accent-foreground disabled:tw-pointer-events-none disabled:tw-opacity-50 tw-group-has-[[data-sidebar=menu-action]]/menu-item:pr-8 aria-disabled:tw-pointer-events-none aria-disabled:tw-opacity-50 data-[active=true]:tw-font-medium data-[active=true]:tw-text-sidebar-accent-foreground data-[state=open]:hover:tw-bg-sidebar-accent data-[state=open]:hover:tw-text-sidebar-accent-foreground group-data-[collapsible=icon]:tw-!size-8 group-data-[collapsible=icon]:tw-!p-2 [&>span:last-child]:tw-truncate [&>svg]:tw-size-4 [&>svg]:tw-shrink-0", { variants: { variant: { @@ -2973,7 +2982,7 @@ const Ed = Xe( size: "default" } } -), Gi = T.forwardRef( +), Hi = T.forwardRef( ({ asChild: t = !1, isActive: e = !1, @@ -2999,7 +3008,7 @@ const Ed = Xe( }), /* @__PURE__ */ x(ld, { children: [ /* @__PURE__ */ s(cd, { asChild: !0, children: h }), /* @__PURE__ */ s( - Di, + Bi, { side: "right", align: "center", @@ -3010,7 +3019,7 @@ const Ed = Xe( ] })) : h; } ); -Gi.displayName = "SidebarMenuButton"; +Hi.displayName = "SidebarMenuButton"; const Sd = T.forwardRef(({ className: t, asChild: e = !1, showOnHover: n = !1, ...r }, o) => /* @__PURE__ */ s( e ? He : "button", { @@ -3126,79 +3135,106 @@ function Pd({ handleSelectSidebarItem: r, selectedSidebarItem: o }) { - const a = Tt( - (l, c) => { - r(l, c); + const a = Et( + (c, d) => { + r(c, d); }, [r] - ), i = Tt( - (l) => { - const c = n.find((d) => d.projectId === l); - return c ? c.projectName : l; + ), i = Et( + (c) => { + const d = n.find((p) => p.projectId === c); + return d ? d.projectName : c; }, [n] + ), l = Et( + (c) => !o.projectId && c === o.label, + [o] + ); + return /* @__PURE__ */ s( + zi, + { + id: t, + collapsible: "none", + variant: "inset", + className: "tw-w-96 tw-gap-2 tw-overflow-y-auto tw-rounded tw-bg-slate-100", + children: /* @__PURE__ */ x(Fi, { children: [ + /* @__PURE__ */ x(Kr, { children: [ + /* @__PURE__ */ s(Jr, { className: "tw-text-sm tw-text-gray-400", children: "Extensions" }), + /* @__PURE__ */ s(Zr, { children: /* @__PURE__ */ s(Ui, { children: e.map((c) => /* @__PURE__ */ s(Gi, { children: /* @__PURE__ */ s( + Hi, + { + className: N( + "tw-rounded tw-py-2 tw-text-sm tw-text-gray-500 hover:tw-bg-white hover:tw-text-gray-900 hover:tw-shadow-sm active:tw-bg-white", + { "tw-bg-white tw-text-gray-900 tw-shadow-sm": l(c) } + ), + onClick: () => a(c, void 0), + isActive: l(c), + children: /* @__PURE__ */ s("span", { className: "tw-pl-3", children: c }) + } + ) }, c)) }) }) + ] }), + /* @__PURE__ */ x(Kr, { children: [ + /* @__PURE__ */ s(Jr, { className: "tw-text-sm tw-text-gray-400", children: "Projects" }), + /* @__PURE__ */ s(Zr, { className: "tw-pl-3", children: /* @__PURE__ */ s( + qr, + { + popoverContentClassName: "tw-z-[1000]", + options: n.flatMap((c) => c.projectId), + getOptionLabel: (c) => i(c), + buttonPlaceholder: "Type or select project", + onChange: (c) => { + const d = i(c); + a(d, c); + }, + value: (o == null ? void 0 : o.projectId) ?? void 0 + } + ) }) + ] }) + ] }) + } ); - return /* @__PURE__ */ s(Vi, { id: t, collapsible: "offcanvas", variant: "sidebar", children: /* @__PURE__ */ x(Li, { children: [ - /* @__PURE__ */ x(Kr, { children: [ - /* @__PURE__ */ s(Jr, { children: "Extensions" }), - /* @__PURE__ */ s(Zr, { children: /* @__PURE__ */ s(Fi, { children: e.map((l) => /* @__PURE__ */ s(Ui, { children: /* @__PURE__ */ s( - Gi, - { - onClick: () => a(l), - isActive: !(o != null && o.projectId) && l === (o == null ? void 0 : o.label), - children: l - } - ) }, l)) }) }) - ] }), - /* @__PURE__ */ x(Kr, { children: [ - /* @__PURE__ */ s(Jr, { children: "Projects" }), - /* @__PURE__ */ s(Zr, { children: /* @__PURE__ */ s( - qr, - { - popoverContentClassName: "tw-z-[1000]", - options: n.flatMap((l) => l.projectId), - getOptionLabel: (l) => i(l), - buttonPlaceholder: "Type or select project", - onChange: (l) => { - const c = i(l); - a(c, l); - }, - value: (o == null ? void 0 : o.projectId) ?? void 0 - } - ) }) - ] }) - ] }) }); } -function Ch({ +function Th({ id: t, direction: e = "ltr", extensionLabels: n, projectOptions: r, children: o, handleSelectSidebarItem: a, - selectedSidebarItem: i + selectedSidebarItem: i, + onSearch: l }) { - return /* @__PURE__ */ x(ji, { dir: e, id: t, children: [ - /* @__PURE__ */ s( - Pd, + return /* @__PURE__ */ x("div", { className: "tw-h-full tw-p-3", children: [ + /* @__PURE__ */ s("div", { className: "tw-flex tw-items-center tw-justify-center tw-py-4", children: /* @__PURE__ */ s( + Pi, { - extensionLabels: n, - projectOptions: r, - handleSelectSidebarItem: a, - selectedSidebarItem: i + className: "tw-w-9/12", + onSearch: l, + placeholder: "Search app settings, extension settings, and project settings" } - ), - /* @__PURE__ */ s(zi, { children: o }) + ) }), + /* @__PURE__ */ x(Vi, { dir: e, id: t, className: "tw-gap-4", children: [ + /* @__PURE__ */ s( + Pd, + { + extensionLabels: n, + projectOptions: r, + handleSelectSidebarItem: a, + selectedSidebarItem: i + } + ), + /* @__PURE__ */ s(Li, { className: "tw-overflow-y-auto", children: o }) + ] }) ] }); } -const ne = "scrBook", $d = "scrRef", we = "source", Ad = "details", Id = "Scripture Reference", Md = "Scripture Book", Hi = "Type", Dd = "Details"; +const ne = "scrBook", $d = "scrRef", we = "source", Id = "details", Ad = "Scripture Reference", Md = "Scripture Book", Xi = "Type", Dd = "Details"; function Bd(t, e) { const n = e ?? !1; return [ { accessorFn: (r) => `${ot.bookNumberToId(r.start.bookNum)} ${r.start.chapterNum}:${r.start.verseNum}`, id: ne, - header: (t == null ? void 0 : t.scriptureReferenceColumnName) ?? Id, + header: (t == null ? void 0 : t.scriptureReferenceColumnName) ?? Ad, cell: (r) => { const o = r.row.original; return r.row.getIsGrouped() ? ot.bookNumberToEnglishName(o.start.bookNum) : r.row.groupingColumnId === ne ? Or(o.start) : void 0; @@ -3221,7 +3257,7 @@ function Bd(t, e) { { accessorFn: (r) => r.source.displayName, id: we, - header: n ? (t == null ? void 0 : t.typeColumnName) ?? Hi : void 0, + header: n ? (t == null ? void 0 : t.typeColumnName) ?? Xi : void 0, cell: (r) => n || r.row.getIsGrouped() ? r.getValue() : void 0, getGroupingValue: (r) => r.source.id, sortingFn: (r, o) => r.original.source.displayName.localeCompare(o.original.source.displayName), @@ -3229,7 +3265,7 @@ function Bd(t, e) { }, { accessorFn: (r) => r.detail, - id: Ad, + id: Id, header: (t == null ? void 0 : t.detailsColumnName) ?? Dd, cell: (r) => r.getValue(), enableGrouping: !1 @@ -3245,7 +3281,7 @@ const jd = (t) => { let n = 0; return t.end && ({ offset: n } = t.end), !t.end || Hr(t.start, t.end) === 0 ? `${Rr(t.start)}+${e}` : `${Rr(t.start)}+${e}-${Rr(t.end)}+${n}`; }, ia = (t) => `${jd({ start: t.start, end: t.end })} ${t.source.displayName} ${t.detail}`; -function Oh({ +function Ch({ sources: t, showColumnHeaders: e = !1, showSourceColumn: n = !1, @@ -3256,13 +3292,13 @@ function Oh({ onRowSelected: l, direction: c = "ltr" }) { - const [d, p] = ut([]), [h, w] = ut([{ id: ne, desc: !1 }]), [g, v] = ut({}), f = At( + const [d, p] = ut([]), [h, w] = ut([{ id: ne, desc: !1 }]), [g, v] = ut({}), f = It( () => t.flatMap((O) => O.data.map(($) => ({ ...$, source: O.source }))), [t] - ), m = At( + ), m = It( () => Bd( { scriptureReferenceColumnName: r, @@ -3290,8 +3326,8 @@ function Oh({ onGroupingChange: p, onSortingChange: w, onRowSelectionChange: v, - getExpandedRowModel: Ml(), - getGroupedRowModel: Dl(), + getExpandedRowModel: Bl(), + getGroupedRowModel: jl(), getCoreRowModel: ni(), getSortedRowModel: ri(), getRowId: ia, @@ -3308,7 +3344,7 @@ function Oh({ } } }, [g, f, l, E]); - const _ = o ?? Md, C = a ?? Hi, S = [ + const _ = o ?? Md, C = a ?? Xi, S = [ { label: "No Grouping", value: [] }, { label: `Group by ${_}`, value: [ne] }, { label: `Group by ${C}`, value: [we] }, @@ -3322,7 +3358,7 @@ function Oh({ } ], b = (O) => { p(JSON.parse(O)); - }, A = (O, $) => { + }, I = (O, $) => { !O.getIsGrouped() && !O.getIsSelected() && O.getToggleSelectedHandler()($); }, z = (O, $) => O.getIsGrouped() ? "" : N("banded-row", $ % 2 === 0 ? "even" : "odd"), H = (O, $, k) => { if (!((O == null ? void 0 : O.length) === 0 || $.depth < k.column.getGroupedIndex())) { @@ -3353,7 +3389,7 @@ function Oh({ }, children: [ /* @__PURE__ */ s(De, { className: "tw-mb-1 tw-mt-2", children: /* @__PURE__ */ s(bn, {}) }), - /* @__PURE__ */ s(Be, { position: "item-aligned", children: /* @__PURE__ */ s(Vc, { children: S.map((O) => /* @__PURE__ */ s(Gt, { value: JSON.stringify(O.value), children: O.label }, O.label)) }) }) + /* @__PURE__ */ s(Be, { position: "item-aligned", children: /* @__PURE__ */ s(zc, { children: S.map((O) => /* @__PURE__ */ s(Gt, { value: JSON.stringify(O.value), children: O.label }, O.label)) }) }) ] } ), @@ -3380,7 +3416,7 @@ function Oh({ { "data-state": O.getIsSelected() ? "selected" : "", className: N(z(O, $)), - onClick: (k) => A(O, k), + onClick: (k) => I(O, k), children: O.getVisibleCells().map((k) => { if (!(k.getIsPlaceholder() || k.column.columnDef.enableGrouping && !k.getIsGrouped() && (k.column.columnDef.id !== we || !n))) return /* @__PURE__ */ s( @@ -3399,7 +3435,7 @@ function Oh({ type: "button", children: [ O.getIsExpanded() && /* @__PURE__ */ s(er, {}), - !O.getIsExpanded() && (c === "ltr" ? /* @__PURE__ */ s(Ja, {}) : /* @__PURE__ */ s(vl, {})), + !O.getIsExpanded() && (c === "ltr" ? /* @__PURE__ */ s(Ja, {}) : /* @__PURE__ */ s(xl, {})), " ", dn(k.column.columnDef.cell, k.getContext()), " (", @@ -3418,7 +3454,7 @@ function Oh({ ] }) ] }); } -const Ar = { +const Ir = { [pt("undefined")]: "Ø", [pt(0)]: "A", [pt(1)]: "B", @@ -3447,19 +3483,19 @@ const Ar = { [pt(24)]: "Y", [pt(25)]: "Z" }; -function Rh({ +function Oh({ availableScrollGroupIds: t, scrollGroupId: e, onChangeScrollGroupId: n, localizedStrings: r = {} }) { const o = { - ...Ar, + ...Ir, ...Object.fromEntries( Object.entries(r).map( ([a, i]) => [ a, - a === i && a in Ar ? Ar[a] : i + a === i && a in Ir ? Ir[a] : i ] ) ) @@ -3489,10 +3525,10 @@ function Rh({ } ); } -function _h({ children: t }) { +function Rh({ children: t }) { return /* @__PURE__ */ s("div", { className: "pr-twp tw-grid", children: t }); } -function Ph({ +function _h({ primary: t, secondary: e, children: n, @@ -3507,7 +3543,7 @@ function Ph({ r ? /* @__PURE__ */ s("p", { className: "tw-text-sm tw-text-muted-foreground", children: o }) : /* @__PURE__ */ s("div", { children: n }) ] }); } -function $h({ +function Ph({ primary: t, secondary: e, includeSeparator: n = !1 @@ -3520,7 +3556,7 @@ function $h({ n ? /* @__PURE__ */ s(go, {}) : "" ] }); } -const Xi = T.forwardRef( +const Yi = T.forwardRef( ({ className: t, ...e }, n) => /* @__PURE__ */ s( "div", { @@ -3533,8 +3569,8 @@ const Xi = T.forwardRef( } ) ); -Xi.displayName = "Card"; -const Yi = T.forwardRef( +Yi.displayName = "Card"; +const Wi = T.forwardRef( ({ className: t, ...e }, n) => /* @__PURE__ */ s( "div", { @@ -3544,8 +3580,8 @@ const Yi = T.forwardRef( } ) ); -Yi.displayName = "CardHeader"; -const Wi = T.forwardRef( +Wi.displayName = "CardHeader"; +const qi = T.forwardRef( ({ className: t, ...e }, n) => /* @__PURE__ */ s( "h3", { @@ -3559,14 +3595,14 @@ const Wi = T.forwardRef( } ) ); -Wi.displayName = "CardTitle"; -const qi = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s("p", { ref: n, className: N("pr-twp tw-text-sm tw-text-muted-foreground", t), ...e })); -qi.displayName = "CardDescription"; -const Vd = T.forwardRef( +qi.displayName = "CardTitle"; +const Ki = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s("p", { ref: n, className: N("pr-twp tw-text-sm tw-text-muted-foreground", t), ...e })); +Ki.displayName = "CardDescription"; +const Ji = T.forwardRef( ({ className: t, ...e }, n) => /* @__PURE__ */ s("div", { ref: n, className: N("pr-twp tw-p-6 tw-pt-0", t), ...e }) ); -Vd.displayName = "CardContent"; -const zd = T.forwardRef( +Ji.displayName = "CardContent"; +const Vd = T.forwardRef( ({ className: t, ...e }, n) => /* @__PURE__ */ s( "div", { @@ -3576,19 +3612,19 @@ const zd = T.forwardRef( } ) ); -zd.displayName = "CardFooter"; -function Ah({ +Vd.displayName = "CardFooter"; +function $h({ id: t, settingsGroupLabel: e, settingsGroupDescription: n, children: r }) { - return /* @__PURE__ */ x(Xi, { id: t, children: [ - /* @__PURE__ */ x(Yi, { children: [ - /* @__PURE__ */ s(Wi, { children: e }), - n && /* @__PURE__ */ s(qi, { children: n }) + return /* @__PURE__ */ x(Yi, { id: t, children: [ + /* @__PURE__ */ x(Wi, { children: [ + /* @__PURE__ */ s(qi, { children: e }), + n && /* @__PURE__ */ s(Ki, { children: n }) ] }), - /* @__PURE__ */ s(Bl, { className: "tw-space-y-4", children: r }) + /* @__PURE__ */ s(Ji, { children: r }) ] }); } function Ih({ @@ -3611,10 +3647,10 @@ function Ih({ /* @__PURE__ */ s(Xt, { children: a ? a(i) : i }) ] }, i)) }); } -function Ld(t) { +function zd(t) { return t && t.__esModule && Object.prototype.hasOwnProperty.call(t, "default") ? t.default : t; } -function Fd(t) { +function Ld(t) { if (t.__esModule) return t; var e = t.default; @@ -3635,7 +3671,7 @@ function Fd(t) { }); }), n; } -var bo = {}, Ki = { exports: {} }; +var bo = {}, Zi = { exports: {} }; (function(t) { function e(n) { return n && n.__esModule ? n : { @@ -3643,8 +3679,8 @@ var bo = {}, Ki = { exports: {} }; }; } t.exports = e, t.exports.__esModule = !0, t.exports.default = t.exports; -})(Ki); -var Ud = Ki.exports, Ir = {}; +})(Zi); +var Fd = Zi.exports, Ar = {}; function vo(t, e) { return process.env.NODE_ENV === "production" ? () => null : function(...r) { return t(...r) || e(...r); @@ -3666,12 +3702,12 @@ function he(t) { const e = Object.getPrototypeOf(t); return (e === null || e === Object.prototype || Object.getPrototypeOf(e) === null) && !(Symbol.toStringTag in t) && !(Symbol.iterator in t); } -function Ji(t) { +function Qi(t) { if (!he(t)) return t; const e = {}; return Object.keys(t).forEach((n) => { - e[n] = Ji(t[n]); + e[n] = Qi(t[n]); }), e; } function Zt(t, e, n = { @@ -3679,7 +3715,7 @@ function Zt(t, e, n = { }) { const r = n.clone ? P({}, t) : t; return he(t) && he(e) && Object.keys(e).forEach((o) => { - o !== "__proto__" && (he(e[o]) && o in t && he(t[o]) ? r[o] = Zt(t[o], e[o], n) : n.clone ? r[o] = he(e[o]) ? Ji(e[o]) : e[o] : r[o] = e[o]); + o !== "__proto__" && (he(e[o]) && o in t && he(t[o]) ? r[o] = Zt(t[o], e[o], n) : n.clone ? r[o] = he(e[o]) ? Qi(e[o]) : e[o] : r[o] = e[o]); }), r; } var Qr = { exports: {} }, jn = { exports: {} }, it = {}; @@ -3692,15 +3728,15 @@ var Qr = { exports: {} }, jn = { exports: {} }, it = {}; * LICENSE file in the root directory of this source tree. */ var sa; -function Gd() { +function Ud() { if (sa) return it; sa = 1; var t = typeof Symbol == "function" && Symbol.for, e = t ? Symbol.for("react.element") : 60103, n = t ? Symbol.for("react.portal") : 60106, r = t ? Symbol.for("react.fragment") : 60107, o = t ? Symbol.for("react.strict_mode") : 60108, a = t ? Symbol.for("react.profiler") : 60114, i = t ? Symbol.for("react.provider") : 60109, l = t ? Symbol.for("react.context") : 60110, c = t ? Symbol.for("react.async_mode") : 60111, d = t ? Symbol.for("react.concurrent_mode") : 60111, p = t ? Symbol.for("react.forward_ref") : 60112, h = t ? Symbol.for("react.suspense") : 60113, w = t ? Symbol.for("react.suspense_list") : 60120, g = t ? Symbol.for("react.memo") : 60115, v = t ? Symbol.for("react.lazy") : 60116, f = t ? Symbol.for("react.block") : 60121, m = t ? Symbol.for("react.fundamental") : 60117, E = t ? Symbol.for("react.responder") : 60118, _ = t ? Symbol.for("react.scope") : 60119; function C(b) { if (typeof b == "object" && b !== null) { - var A = b.$$typeof; - switch (A) { + var I = b.$$typeof; + switch (I) { case e: switch (b = b.type, b) { case c: @@ -3719,11 +3755,11 @@ function Gd() { case i: return b; default: - return A; + return I; } } case n: - return A; + return I; } } } @@ -3768,19 +3804,19 @@ var st = {}; * LICENSE file in the root directory of this source tree. */ var la; -function Hd() { +function Gd() { return la || (la = 1, process.env.NODE_ENV !== "production" && function() { var t = typeof Symbol == "function" && Symbol.for, e = t ? Symbol.for("react.element") : 60103, n = t ? Symbol.for("react.portal") : 60106, r = t ? Symbol.for("react.fragment") : 60107, o = t ? Symbol.for("react.strict_mode") : 60108, a = t ? Symbol.for("react.profiler") : 60114, i = t ? Symbol.for("react.provider") : 60109, l = t ? Symbol.for("react.context") : 60110, c = t ? Symbol.for("react.async_mode") : 60111, d = t ? Symbol.for("react.concurrent_mode") : 60111, p = t ? Symbol.for("react.forward_ref") : 60112, h = t ? Symbol.for("react.suspense") : 60113, w = t ? Symbol.for("react.suspense_list") : 60120, g = t ? Symbol.for("react.memo") : 60115, v = t ? Symbol.for("react.lazy") : 60116, f = t ? Symbol.for("react.block") : 60121, m = t ? Symbol.for("react.fundamental") : 60117, E = t ? Symbol.for("react.responder") : 60118, _ = t ? Symbol.for("react.scope") : 60119; - function C(I) { - return typeof I == "string" || typeof I == "function" || // Note: its typeof might be other than 'symbol' or 'number' if it's a polyfill. - I === r || I === d || I === a || I === o || I === h || I === w || typeof I == "object" && I !== null && (I.$$typeof === v || I.$$typeof === g || I.$$typeof === i || I.$$typeof === l || I.$$typeof === p || I.$$typeof === m || I.$$typeof === E || I.$$typeof === _ || I.$$typeof === f); + function C(A) { + return typeof A == "string" || typeof A == "function" || // Note: its typeof might be other than 'symbol' or 'number' if it's a polyfill. + A === r || A === d || A === a || A === o || A === h || A === w || typeof A == "object" && A !== null && (A.$$typeof === v || A.$$typeof === g || A.$$typeof === i || A.$$typeof === l || A.$$typeof === p || A.$$typeof === m || A.$$typeof === E || A.$$typeof === _ || A.$$typeof === f); } - function S(I) { - if (typeof I == "object" && I !== null) { - var Nt = I.$$typeof; + function S(A) { + if (typeof A == "object" && A !== null) { + var Nt = A.$$typeof; switch (Nt) { case e: - var j = I.type; + var j = A.type; switch (j) { case c: case d: @@ -3807,52 +3843,52 @@ function Hd() { } } } - var b = c, A = d, z = l, H = i, O = e, $ = p, k = r, B = v, D = g, J = n, q = a, U = o, tt = h, at = !1; - function rt(I) { - return at || (at = !0, console.warn("The ReactIs.isAsyncMode() alias has been deprecated, and will be removed in React 17+. Update your code to use ReactIs.isConcurrentMode() instead. It has the exact same API.")), y(I) || S(I) === c; + var b = c, I = d, z = l, H = i, O = e, $ = p, k = r, B = v, D = g, J = n, q = a, U = o, tt = h, at = !1; + function rt(A) { + return at || (at = !0, console.warn("The ReactIs.isAsyncMode() alias has been deprecated, and will be removed in React 17+. Update your code to use ReactIs.isConcurrentMode() instead. It has the exact same API.")), y(A) || S(A) === c; } - function y(I) { - return S(I) === d; + function y(A) { + return S(A) === d; } - function R(I) { - return S(I) === l; + function R(A) { + return S(A) === l; } - function L(I) { - return S(I) === i; + function L(A) { + return S(A) === i; } - function F(I) { - return typeof I == "object" && I !== null && I.$$typeof === e; + function F(A) { + return typeof A == "object" && A !== null && A.$$typeof === e; } - function V(I) { - return S(I) === p; + function V(A) { + return S(A) === p; } - function W(I) { - return S(I) === r; + function W(A) { + return S(A) === r; } - function X(I) { - return S(I) === v; + function X(A) { + return S(A) === v; } - function Y(I) { - return S(I) === g; + function Y(A) { + return S(A) === g; } - function G(I) { - return S(I) === n; + function G(A) { + return S(A) === n; } - function K(I) { - return S(I) === a; + function K(A) { + return S(A) === a; } - function Z(I) { - return S(I) === o; + function Z(A) { + return S(A) === o; } - function dt(I) { - return S(I) === h; + function dt(A) { + return S(A) === h; } - st.AsyncMode = b, st.ConcurrentMode = A, st.ContextConsumer = z, st.ContextProvider = H, st.Element = O, st.ForwardRef = $, st.Fragment = k, st.Lazy = B, st.Memo = D, st.Portal = J, st.Profiler = q, st.StrictMode = U, st.Suspense = tt, st.isAsyncMode = rt, st.isConcurrentMode = y, st.isContextConsumer = R, st.isContextProvider = L, st.isElement = F, st.isForwardRef = V, st.isFragment = W, st.isLazy = X, st.isMemo = Y, st.isPortal = G, st.isProfiler = K, st.isStrictMode = Z, st.isSuspense = dt, st.isValidElementType = C, st.typeOf = S; + st.AsyncMode = b, st.ConcurrentMode = I, st.ContextConsumer = z, st.ContextProvider = H, st.Element = O, st.ForwardRef = $, st.Fragment = k, st.Lazy = B, st.Memo = D, st.Portal = J, st.Profiler = q, st.StrictMode = U, st.Suspense = tt, st.isAsyncMode = rt, st.isConcurrentMode = y, st.isContextConsumer = R, st.isContextProvider = L, st.isElement = F, st.isForwardRef = V, st.isFragment = W, st.isLazy = X, st.isMemo = Y, st.isPortal = G, st.isProfiler = K, st.isStrictMode = Z, st.isSuspense = dt, st.isValidElementType = C, st.typeOf = S; }()), st; } var ca; -function Zi() { - return ca || (ca = 1, process.env.NODE_ENV === "production" ? jn.exports = Gd() : jn.exports = Hd()), jn.exports; +function ts() { + return ca || (ca = 1, process.env.NODE_ENV === "production" ? jn.exports = Ud() : jn.exports = Gd()), jn.exports; } /* object-assign @@ -3860,7 +3896,7 @@ object-assign @license MIT */ var Mr, da; -function Xd() { +function Hd() { if (da) return Mr; da = 1; @@ -3915,18 +3951,18 @@ function yo() { return Dr = t, Dr; } var Br, ua; -function Qi() { +function es() { return ua || (ua = 1, Br = Function.call.bind(Object.prototype.hasOwnProperty)), Br; } var jr, wa; -function Yd() { +function Xd() { if (wa) return jr; wa = 1; var t = function() { }; if (process.env.NODE_ENV !== "production") { - var e = yo(), n = {}, r = Qi(); + var e = yo(), n = {}, r = es(); t = function(a) { var i = "Warning: " + a; typeof console < "u" && console.error(i); @@ -3969,11 +4005,11 @@ function Yd() { }, jr = o, jr; } var Vr, fa; -function Wd() { +function Yd() { if (fa) return Vr; fa = 1; - var t = Zi(), e = Xd(), n = yo(), r = Qi(), o = Yd(), a = function() { + var t = ts(), e = Hd(), n = yo(), r = es(), o = Xd(), a = function() { }; process.env.NODE_ENV !== "production" && (a = function(l) { var c = "Warning: " + l; @@ -4006,7 +4042,7 @@ function Wd() { arrayOf: C, element: S(), elementType: b(), - instanceOf: A, + instanceOf: I, node: $(), objectOf: H, oneOf: z, @@ -4027,10 +4063,10 @@ function Wd() { function F(W, X, Y, G, K, Z, dt) { if (G = G || w, Z = Z || Y, dt !== n) { if (c) { - var I = new Error( + var A = new Error( "Calling PropTypes validators directly is not supported by the `prop-types` package. Use `PropTypes.checkPropTypes()` to call them. Read more at http://fb.me/use-check-prop-types" ); - throw I.name = "Invariant Violation", I; + throw A.name = "Invariant Violation", A; } else if (process.env.NODE_ENV !== "production" && typeof console < "u") { var Nt = G + ":" + Y; !R[Nt] && // Avoid spamming the console because they are often not actionable except for lib authors @@ -4101,7 +4137,7 @@ function Wd() { } return m(y); } - function A(y) { + function I(y) { function R(L, F, V, W, X) { if (!(L[F] instanceof y)) { var Y = y.name || w, G = rt(L[F]); @@ -4120,9 +4156,9 @@ function Wd() { for (var Y = L[F], G = 0; G < y.length; G++) if (v(Y, y[G])) return null; - var K = JSON.stringify(y, function(dt, I) { - var Nt = tt(I); - return Nt === "symbol" ? String(I) : I; + var K = JSON.stringify(y, function(dt, A) { + var Nt = tt(A); + return Nt === "symbol" ? String(A) : A; }); return new f("Invalid " + W + " `" + X + "` of value `" + String(Y) + "` " + ("supplied to `" + V + "`, expected one of " + K + ".")); } @@ -4157,10 +4193,10 @@ function Wd() { } function F(V, W, X, Y, G) { for (var K = [], Z = 0; Z < y.length; Z++) { - var dt = y[Z], I = dt(V, W, X, Y, G, n); - if (I == null) + var dt = y[Z], A = dt(V, W, X, Y, G, n); + if (A == null) return null; - I.data && r(I.data, "expectedType") && K.push(I.data.expectedType); + A.data && r(A.data, "expectedType") && K.push(A.data.expectedType); } var Nt = K.length > 0 ? ", expected one of type [" + K.join(", ") + "]" : ""; return new f("Invalid " + Y + " `" + G + "` supplied to " + ("`" + X + "`" + Nt + ".")); @@ -4210,9 +4246,9 @@ function Wd() { "Invalid " + W + " `" + X + "` key `" + Z + "` supplied to `" + V + "`.\nBad object: " + JSON.stringify(L[F], null, " ") + ` Valid keys: ` + JSON.stringify(Object.keys(y), null, " ") ); - var I = dt(Y, Z, V, W, X + "." + Z, n); - if (I) - return I; + var A = dt(Y, Z, V, W, X + "." + Z, n); + if (A) + return A; } return null; } @@ -4291,7 +4327,7 @@ Valid keys: ` + JSON.stringify(Object.keys(y), null, " ") }, Vr; } var zr, ma; -function qd() { +function Wd() { if (ma) return zr; ma = 1; @@ -4340,19 +4376,19 @@ function qd() { }, zr; } if (process.env.NODE_ENV !== "production") { - var Kd = Zi(), Jd = !0; - Qr.exports = Wd()(Kd.isElement, Jd); + var qd = ts(), Kd = !0; + Qr.exports = Yd()(qd.isElement, Kd); } else - Qr.exports = qd()(); -var Zd = Qr.exports; -const u = /* @__PURE__ */ Ld(Zd); -function Qd(t) { + Qr.exports = Wd()(); +var Jd = Qr.exports; +const u = /* @__PURE__ */ zd(Jd); +function Zd(t) { const { prototype: e = {} } = t; return !!e.isReactComponent; } -function ts(t, e, n, r, o) { +function ns(t, e, n, r, o) { const a = t[e], i = o || e; if (a == null || // When server-side rendering React doesn't warn either. // This is not an accurate check for SSR. @@ -4362,14 +4398,14 @@ function ts(t, e, n, r, o) { return null; let l; const c = a.type; - return typeof c == "function" && !Qd(c) && (l = "Did you accidentally use a plain function component for an element instead?"), l !== void 0 ? new Error(`Invalid ${r} \`${i}\` supplied to \`${n}\`. Expected an element that can hold a ref. ${l} For more information see https://mui.com/r/caveat-with-refs-guide`) : null; + return typeof c == "function" && !Zd(c) && (l = "Did you accidentally use a plain function component for an element instead?"), l !== void 0 ? new Error(`Invalid ${r} \`${i}\` supplied to \`${n}\`. Expected an element that can hold a ref. ${l} For more information see https://mui.com/r/caveat-with-refs-guide`) : null; } -const es = vo(u.element, ts); -es.isRequired = vo(u.element.isRequired, ts); -const ns = es, tp = "exact-prop: ​"; -function ep(t) { +const rs = vo(u.element, ns); +rs.isRequired = vo(u.element.isRequired, ns); +const os = rs, Qd = "exact-prop: ​"; +function tp(t) { return process.env.NODE_ENV === "production" ? t : P({}, t, { - [tp]: (e) => { + [Qd]: (e) => { const n = Object.keys(e).filter((r) => !t.hasOwnProperty(r)); return n.length > 0 ? new Error(`The following props are not supported: ${n.map((r) => `\`${r}\``).join(", ")}. Please remove them.`) : null; } @@ -4392,7 +4428,7 @@ var to = { exports: {} }, lt = {}; * LICENSE file in the root directory of this source tree. */ var ha; -function np() { +function ep() { if (ha) return lt; ha = 1; @@ -4471,7 +4507,7 @@ var ct = {}; * LICENSE file in the root directory of this source tree. */ var ga; -function rp() { +function np() { return ga || (ga = 1, process.env.NODE_ENV !== "production" && function() { var t = Symbol.for("react.element"), e = Symbol.for("react.portal"), n = Symbol.for("react.fragment"), r = Symbol.for("react.strict_mode"), o = Symbol.for("react.profiler"), a = Symbol.for("react.provider"), i = Symbol.for("react.context"), l = Symbol.for("react.server_context"), c = Symbol.for("react.forward_ref"), d = Symbol.for("react.suspense"), p = Symbol.for("react.suspense_list"), h = Symbol.for("react.memo"), w = Symbol.for("react.lazy"), g = Symbol.for("react.offscreen"), v = !1, f = !1, m = !1, E = !1, _ = !1, C; C = Symbol.for("react.module.reference"); @@ -4514,7 +4550,7 @@ function rp() { } } } - var A = i, z = a, H = t, O = c, $ = n, k = w, B = h, D = e, J = o, q = r, U = d, tt = p, at = !1, rt = !1; + var I = i, z = a, H = t, O = c, $ = n, k = w, B = h, D = e, J = o, q = r, U = d, tt = p, at = !1, rt = !1; function y(j) { return at || (at = !0, console.warn("The ReactIs.isAsyncMode() alias has been deprecated, and will be removed in React 18+.")), !1; } @@ -4551,35 +4587,35 @@ function rp() { function dt(j) { return b(j) === r; } - function I(j) { + function A(j) { return b(j) === d; } function Nt(j) { return b(j) === p; } - ct.ContextConsumer = A, ct.ContextProvider = z, ct.Element = H, ct.ForwardRef = O, ct.Fragment = $, ct.Lazy = k, ct.Memo = B, ct.Portal = D, ct.Profiler = J, ct.StrictMode = q, ct.Suspense = U, ct.SuspenseList = tt, ct.isAsyncMode = y, ct.isConcurrentMode = R, ct.isContextConsumer = L, ct.isContextProvider = F, ct.isElement = V, ct.isForwardRef = W, ct.isFragment = X, ct.isLazy = Y, ct.isMemo = G, ct.isPortal = K, ct.isProfiler = Z, ct.isStrictMode = dt, ct.isSuspense = I, ct.isSuspenseList = Nt, ct.isValidElementType = S, ct.typeOf = b; + ct.ContextConsumer = I, ct.ContextProvider = z, ct.Element = H, ct.ForwardRef = O, ct.Fragment = $, ct.Lazy = k, ct.Memo = B, ct.Portal = D, ct.Profiler = J, ct.StrictMode = q, ct.Suspense = U, ct.SuspenseList = tt, ct.isAsyncMode = y, ct.isConcurrentMode = R, ct.isContextConsumer = L, ct.isContextProvider = F, ct.isElement = V, ct.isForwardRef = W, ct.isFragment = X, ct.isLazy = Y, ct.isMemo = G, ct.isPortal = K, ct.isProfiler = Z, ct.isStrictMode = dt, ct.isSuspense = A, ct.isSuspenseList = Nt, ct.isValidElementType = S, ct.typeOf = b; }()), ct; } -process.env.NODE_ENV === "production" ? to.exports = np() : to.exports = rp(); +process.env.NODE_ENV === "production" ? to.exports = ep() : to.exports = np(); var ba = to.exports; -const op = /^\s*function(?:\s|\s*\/\*.*\*\/\s*)+([^(\s/]*)\s*/; -function ap(t) { - const e = `${t}`.match(op); +const rp = /^\s*function(?:\s|\s*\/\*.*\*\/\s*)+([^(\s/]*)\s*/; +function op(t) { + const e = `${t}`.match(rp); return e && e[1] || ""; } -function rs(t, e = "") { - return t.displayName || t.name || ap(t) || e; +function as(t, e = "") { + return t.displayName || t.name || op(t) || e; } function va(t, e, n) { - const r = rs(e); + const r = as(e); return t.displayName || (r !== "" ? `${n}(${r})` : n); } -function ip(t) { +function ap(t) { if (t != null) { if (typeof t == "string") return t; if (typeof t == "function") - return rs(t, "Component"); + return as(t, "Component"); if (typeof t == "object") switch (t.$$typeof) { case ba.ForwardRef: @@ -4597,19 +4633,19 @@ function yn(t, e, n, r, o) { const a = t[e], i = o || e; return a == null ? null : a && a.nodeType !== 1 ? new Error(`Invalid ${r} \`${i}\` supplied to \`${n}\`. Expected an HTMLElement.`) : null; } -const sp = u.oneOfType([u.func, u.object]), os = sp; +const ip = u.oneOfType([u.func, u.object]), is = ip; function Wt(t) { if (typeof t != "string") throw new Error(process.env.NODE_ENV !== "production" ? "MUI: `capitalize(string)` expects a string argument." : Ve(7)); return t.charAt(0).toUpperCase() + t.slice(1); } -function lp(...t) { +function sp(...t) { return t.reduce((e, n) => n == null ? e : function(...o) { e.apply(this, o), n.apply(this, o); }, () => { }); } -function cp(t, e = 166) { +function lp(t, e = 166) { let n; function r(...o) { const a = () => { @@ -4621,13 +4657,13 @@ function cp(t, e = 166) { clearTimeout(n); }, r; } -function dp(t, e) { +function cp(t, e) { return process.env.NODE_ENV === "production" ? () => null : (n, r, o, a, i) => { const l = o || "<>", c = i || r; return typeof n[r] < "u" ? new Error(`The ${a} \`${c}\` of \`${l}\` is deprecated. ${e}`) : null; }; } -function pp(t, e) { +function dp(t, e) { var n, r; return /* @__PURE__ */ M.isValidElement(t) && e.indexOf( // For server components `muiName` is avaialble in element.type._payload.value.muiName @@ -4639,10 +4675,10 @@ function pp(t, e) { function Yn(t) { return t && t.ownerDocument || document; } -function up(t) { +function pp(t) { return Yn(t).defaultView || window; } -function wp(t, e) { +function up(t, e) { if (process.env.NODE_ENV === "production") return () => null; const n = e ? P({}, e.propTypes) : null; @@ -4659,29 +4695,29 @@ function wp(t, e) { function Wn(t, e) { typeof t == "function" ? t(e) : t && (t.current = e); } -const fp = typeof window < "u" ? M.useLayoutEffect : M.useEffect, ze = fp; +const wp = typeof window < "u" ? M.useLayoutEffect : M.useEffect, ze = wp; let ya = 0; -function mp(t) { +function fp(t) { const [e, n] = M.useState(t), r = t || e; return M.useEffect(() => { e == null && (ya += 1, n(`mui-${ya}`)); }, [e]), r; } const xa = M["useId".toString()]; -function as(t) { +function ss(t) { if (xa !== void 0) { const e = xa(); return t ?? e; } - return mp(t); + return fp(t); } -function hp(t, e, n, r, o) { +function mp(t, e, n, r, o) { if (process.env.NODE_ENV === "production") return null; const a = o || e; return typeof t[e] < "u" ? new Error(`The prop \`${a}\` is not supported. Please remove it.`) : null; } -function is({ +function ls({ controlled: t, default: e, name: n, @@ -4725,13 +4761,13 @@ function xe(...t) { }, t); } const Na = {}; -function gp(t, e) { +function hp(t, e) { const n = M.useRef(Na); return n.current === Na && (n.current = t(e)), n; } -const bp = []; -function vp(t) { - M.useEffect(t, bp); +const gp = []; +function bp(t) { + M.useEffect(t, gp); } class Tn { constructor() { @@ -4752,11 +4788,11 @@ class Tn { } } function sn() { - const t = gp(Tn.create).current; - return vp(t.disposeEffect), t; + const t = hp(Tn.create).current; + return bp(t.disposeEffect), t; } let dr = !0, no = !1; -const yp = new Tn(), xp = { +const vp = new Tn(), yp = { text: !0, search: !0, url: !0, @@ -4771,26 +4807,26 @@ const yp = new Tn(), xp = { datetime: !0, "datetime-local": !0 }; -function Np(t) { +function xp(t) { const { type: e, tagName: n } = t; - return !!(n === "INPUT" && xp[e] && !t.readOnly || n === "TEXTAREA" && !t.readOnly || t.isContentEditable); + return !!(n === "INPUT" && yp[e] && !t.readOnly || n === "TEXTAREA" && !t.readOnly || t.isContentEditable); } -function kp(t) { +function Np(t) { t.metaKey || t.altKey || t.ctrlKey || (dr = !0); } function Lr() { dr = !1; } -function Ep() { +function kp() { this.visibilityState === "hidden" && no && (dr = !0); } -function Sp(t) { - t.addEventListener("keydown", kp, !0), t.addEventListener("mousedown", Lr, !0), t.addEventListener("pointerdown", Lr, !0), t.addEventListener("touchstart", Lr, !0), t.addEventListener("visibilitychange", Ep, !0); +function Ep(t) { + t.addEventListener("keydown", Np, !0), t.addEventListener("mousedown", Lr, !0), t.addEventListener("pointerdown", Lr, !0), t.addEventListener("touchstart", Lr, !0), t.addEventListener("visibilitychange", kp, !0); } -function Tp(t) { +function Sp(t) { const { target: e } = t; @@ -4798,19 +4834,19 @@ function Tp(t) { return e.matches(":focus-visible"); } catch { } - return dr || Np(e); + return dr || xp(e); } -function ss() { +function cs() { const t = M.useCallback((o) => { - o != null && Sp(o.ownerDocument); + o != null && Ep(o.ownerDocument); }, []), e = M.useRef(!1); function n() { - return e.current ? (no = !0, yp.start(100, () => { + return e.current ? (no = !0, vp.start(100, () => { no = !1; }), e.current = !1, !0) : !1; } function r(o) { - return Tp(o) ? (e.current = !0, !0) : !1; + return Sp(o) ? (e.current = !0, !0) : !1; } return { isFocusVisibleRef: e, @@ -4819,7 +4855,7 @@ function ss() { ref: t }; } -function ls(t, e) { +function ds(t, e) { const n = P({}, e); return Object.keys(t).forEach((r) => { if (r.toString().match(/^(components|slots)$/)) @@ -4827,7 +4863,7 @@ function ls(t, e) { else if (r.toString().match(/^(componentsProps|slotProps)$/)) { const o = t[r] || {}, a = e[r]; n[r] = {}, !a || !Object.keys(a) ? n[r] = o : !o || !Object.keys(o) ? n[r] = a : (n[r] = P({}, a), Object.keys(o).forEach((i) => { - n[r][i] = ls(o[i], a[i]); + n[r][i] = ds(o[i], a[i]); })); } else n[r] === void 0 && (n[r] = t[r]); @@ -4849,7 +4885,7 @@ function xo(t, e, n = void 0) { } ), r; } -const ka = (t) => t, Cp = () => { +const ka = (t) => t, Tp = () => { let t = ka; return { configure(e) { @@ -4862,7 +4898,7 @@ const ka = (t) => t, Cp = () => { t = ka; } }; -}, Op = Cp(), cs = Op, ds = { +}, Cp = Tp(), ps = Cp, us = { active: "active", checked: "checked", completed: "completed", @@ -4877,16 +4913,16 @@ const ka = (t) => t, Cp = () => { selected: "selected" }; function pr(t, e, n = "Mui") { - const r = ds[e]; - return r ? `${n}-${r}` : `${cs.generate(t)}-${e}`; + const r = us[e]; + return r ? `${n}-${r}` : `${ps.generate(t)}-${e}`; } -function ps(t, e, n = "Mui") { +function ws(t, e, n = "Mui") { const r = {}; return e.forEach((o) => { r[o] = pr(t, o, n); }), r; } -function Rp(t, e = Number.MIN_SAFE_INTEGER, n = Number.MAX_SAFE_INTEGER) { +function Op(t, e = Number.MIN_SAFE_INTEGER, n = Number.MAX_SAFE_INTEGER) { return Math.max(e, Math.min(t, n)); } function kt(t, e) { @@ -4897,7 +4933,7 @@ function kt(t, e) { o = r[a], !(e.indexOf(o) >= 0) && (n[o] = t[o]); return n; } -const _p = ["values", "unit", "step"], Pp = (t) => { +const Rp = ["values", "unit", "step"], _p = (t) => { const e = Object.keys(t).map((n) => ({ key: n, val: t[n] @@ -4906,7 +4942,7 @@ const _p = ["values", "unit", "step"], Pp = (t) => { [r.key]: r.val }), {}); }; -function $p(t) { +function Pp(t) { const { // The breakpoint **start** at this value. // For instance with the first breakpoint xs: [xs, sm). @@ -4924,7 +4960,7 @@ function $p(t) { }, unit: n = "px", step: r = 5 - } = t, o = kt(t, _p), a = Pp(e), i = Object.keys(a); + } = t, o = kt(t, Rp), a = _p(e), i = Object.keys(a); function l(w) { return `@media (min-width:${typeof e[w] == "number" ? e[w] : w}${n})`; } @@ -4953,9 +4989,9 @@ function $p(t) { unit: n }, o); } -const Ap = { +const $p = { borderRadius: 4 -}, Ip = Ap, Mp = process.env.NODE_ENV !== "production" ? u.oneOfType([u.number, u.string, u.object, u.array]) : {}, se = Mp; +}, Ip = $p, Ap = process.env.NODE_ENV !== "production" ? u.oneOfType([u.number, u.string, u.object, u.array]) : {}, se = Ap; function un(t, e) { return e ? Zt(t, e, { clone: !1 @@ -5000,14 +5036,14 @@ function Qt(t, e, n) { } return n(e); } -function Dp(t = {}) { +function Mp(t = {}) { var e; return ((e = t.keys) == null ? void 0 : e.reduce((r, o) => { const a = t.up(o); return r[a] = {}, r; }, {})) || {}; } -function Bp(t, e) { +function Dp(t, e) { return t.reduce((n, r) => { const o = n[r]; return (!o || Object.keys(o).length === 0) && delete n[r], n; @@ -5048,14 +5084,14 @@ function yt(t) { [e]: se } : {}, a.filterProps = [e], a; } -function jp(t) { +function Bp(t) { const e = {}; return (n) => (e[n] === void 0 && (e[n] = t(n)), e[n]); } -const Vp = { +const jp = { m: "margin", p: "padding" -}, zp = { +}, Vp = { t: "Top", r: "Right", b: "Bottom", @@ -5067,15 +5103,15 @@ const Vp = { marginY: "my", paddingX: "px", paddingY: "py" -}, Lp = jp((t) => { +}, zp = Bp((t) => { if (t.length > 2) if (Sa[t]) t = Sa[t]; else return [t]; - const [e, n] = t.split(""), r = Vp[e], o = zp[n] || ""; + const [e, n] = t.split(""), r = jp[e], o = Vp[n] || ""; return Array.isArray(o) ? o.map((a) => r + a) : [r + o]; -}), wr = ["m", "mt", "mr", "mb", "ml", "mx", "my", "margin", "marginTop", "marginRight", "marginBottom", "marginLeft", "marginX", "marginY", "marginInline", "marginInlineStart", "marginInlineEnd", "marginBlock", "marginBlockStart", "marginBlockEnd"], fr = ["p", "pt", "pr", "pb", "pl", "px", "py", "padding", "paddingTop", "paddingRight", "paddingBottom", "paddingLeft", "paddingX", "paddingY", "paddingInline", "paddingInlineStart", "paddingInlineEnd", "paddingBlock", "paddingBlockStart", "paddingBlockEnd"], Fp = [...wr, ...fr]; +}), wr = ["m", "mt", "mr", "mb", "ml", "mx", "my", "margin", "marginTop", "marginRight", "marginBottom", "marginLeft", "marginX", "marginY", "marginInline", "marginInlineStart", "marginInlineEnd", "marginBlock", "marginBlockStart", "marginBlockEnd"], fr = ["p", "pt", "pr", "pb", "pl", "px", "py", "padding", "paddingTop", "paddingRight", "paddingBottom", "paddingLeft", "paddingX", "paddingY", "paddingInline", "paddingInlineStart", "paddingInlineEnd", "paddingBlock", "paddingBlockStart", "paddingBlockEnd"], Lp = [...wr, ...fr]; function Cn(t, e, n, r) { var o; const a = (o = ur(t, e, !1)) != null ? o : n; @@ -5085,7 +5121,7 @@ function Cn(t, e, n, r) { `)), () => { }); } -function us(t) { +function fs(t) { return Cn(t, "spacing", 8, "spacing"); } function On(t, e) { @@ -5094,34 +5130,34 @@ function On(t, e) { const n = Math.abs(e), r = t(n); return e >= 0 ? r : typeof r == "number" ? -r : `-${r}`; } -function Up(t, e) { +function Fp(t, e) { return (n) => t.reduce((r, o) => (r[o] = On(e, n), r), {}); } -function Gp(t, e, n, r) { +function Up(t, e, n, r) { if (e.indexOf(n) === -1) return null; - const o = Lp(n), a = Up(o, r), i = t[n]; + const o = zp(n), a = Fp(o, r), i = t[n]; return Qt(t, i, a); } -function ws(t, e) { - const n = us(t.theme); - return Object.keys(t).map((r) => Gp(t, e, r, n)).reduce(un, {}); +function ms(t, e) { + const n = fs(t.theme); + return Object.keys(t).map((r) => Up(t, e, r, n)).reduce(un, {}); } function mt(t) { - return ws(t, wr); + return ms(t, wr); } mt.propTypes = process.env.NODE_ENV !== "production" ? wr.reduce((t, e) => (t[e] = se, t), {}) : {}; mt.filterProps = wr; function ht(t) { - return ws(t, fr); + return ms(t, fr); } ht.propTypes = process.env.NODE_ENV !== "production" ? fr.reduce((t, e) => (t[e] = se, t), {}) : {}; ht.filterProps = fr; -process.env.NODE_ENV !== "production" && Fp.reduce((t, e) => (t[e] = se, t), {}); -function Hp(t = 8) { +process.env.NODE_ENV !== "production" && Lp.reduce((t, e) => (t[e] = se, t), {}); +function Gp(t = 8) { if (t.mui) return t; - const e = us({ + const e = fs({ spacing: t }), n = (...r) => (process.env.NODE_ENV !== "production" && (r.length <= 4 || console.error(`MUI: Too many arguments provided, expected between 0 and 4, got ${r.length}`)), (r.length === 0 ? [1] : r).map((a) => { const i = e(a); @@ -5145,7 +5181,7 @@ function Lt(t, e) { transform: e }); } -const Xp = Lt("border", Bt), Yp = Lt("borderTop", Bt), Wp = Lt("borderRight", Bt), qp = Lt("borderBottom", Bt), Kp = Lt("borderLeft", Bt), Jp = Lt("borderColor"), Zp = Lt("borderTopColor"), Qp = Lt("borderRightColor"), tu = Lt("borderBottomColor"), eu = Lt("borderLeftColor"), nu = Lt("outline", Bt), ru = Lt("outlineColor"), hr = (t) => { +const Hp = Lt("border", Bt), Xp = Lt("borderTop", Bt), Yp = Lt("borderRight", Bt), Wp = Lt("borderBottom", Bt), qp = Lt("borderLeft", Bt), Kp = Lt("borderColor"), Jp = Lt("borderTopColor"), Zp = Lt("borderRightColor"), Qp = Lt("borderBottomColor"), tu = Lt("borderLeftColor"), eu = Lt("outline", Bt), nu = Lt("outlineColor"), hr = (t) => { if (t.borderRadius !== void 0 && t.borderRadius !== null) { const e = Cn(t.theme, "shape.borderRadius", 4, "borderRadius"), n = (r) => ({ borderRadius: On(e, r) @@ -5158,7 +5194,7 @@ hr.propTypes = process.env.NODE_ENV !== "production" ? { borderRadius: se } : {}; hr.filterProps = ["borderRadius"]; -mr(Xp, Yp, Wp, qp, Kp, Jp, Zp, Qp, tu, eu, hr, nu, ru); +mr(Hp, Xp, Yp, Wp, qp, Kp, Jp, Zp, Qp, tu, hr, eu, nu); const gr = (t) => { if (t.gap !== void 0 && t.gap !== null) { const e = Cn(t.theme, "spacing", 8, "gap"), n = (r) => ({ @@ -5198,50 +5234,50 @@ vr.propTypes = process.env.NODE_ENV !== "production" ? { rowGap: se } : {}; vr.filterProps = ["rowGap"]; -const ou = yt({ +const ru = yt({ prop: "gridColumn" -}), au = yt({ +}), ou = yt({ prop: "gridRow" -}), iu = yt({ +}), au = yt({ prop: "gridAutoFlow" -}), su = yt({ +}), iu = yt({ prop: "gridAutoColumns" -}), lu = yt({ +}), su = yt({ prop: "gridAutoRows" -}), cu = yt({ +}), lu = yt({ prop: "gridTemplateColumns" -}), du = yt({ +}), cu = yt({ prop: "gridTemplateRows" -}), pu = yt({ +}), du = yt({ prop: "gridTemplateAreas" -}), uu = yt({ +}), pu = yt({ prop: "gridArea" }); -mr(gr, br, vr, ou, au, iu, su, lu, cu, du, pu, uu); +mr(gr, br, vr, ru, ou, au, iu, su, lu, cu, du, pu); function Me(t, e) { return e === "grey" ? e : t; } -const wu = yt({ +const uu = yt({ prop: "color", themeKey: "palette", transform: Me -}), fu = yt({ +}), wu = yt({ prop: "bgcolor", cssProperty: "backgroundColor", themeKey: "palette", transform: Me -}), mu = yt({ +}), fu = yt({ prop: "backgroundColor", themeKey: "palette", transform: Me }); -mr(wu, fu, mu); -function It(t) { +mr(uu, wu, fu); +function At(t) { return t <= 1 && t !== 0 ? `${t * 100}%` : t; } -const hu = yt({ +const mu = yt({ prop: "width", - transform: It + transform: At }), ko = (t) => { if (t.maxWidth !== void 0 && t.maxWidth !== null) { const e = (n) => { @@ -5252,7 +5288,7 @@ const hu = yt({ } : { maxWidth: a } : { - maxWidth: It(n) + maxWidth: At(n) }; }; return Qt(t, t.maxWidth, e); @@ -5260,34 +5296,34 @@ const hu = yt({ return null; }; ko.filterProps = ["maxWidth"]; -const gu = yt({ +const hu = yt({ prop: "minWidth", - transform: It -}), bu = yt({ + transform: At +}), gu = yt({ prop: "height", - transform: It -}), vu = yt({ + transform: At +}), bu = yt({ prop: "maxHeight", - transform: It -}), yu = yt({ + transform: At +}), vu = yt({ prop: "minHeight", - transform: It + transform: At }); yt({ prop: "size", cssProperty: "width", - transform: It + transform: At }); yt({ prop: "size", cssProperty: "height", - transform: It + transform: At }); -const xu = yt({ +const yu = yt({ prop: "boxSizing" }); -mr(hu, ko, gu, bu, vu, yu, xu); -const Nu = { +mr(mu, ko, hu, gu, bu, vu, yu); +const xu = { // borders border: { themeKey: "borders", @@ -5532,22 +5568,22 @@ const Nu = { }, // sizing width: { - transform: It + transform: At }, maxWidth: { style: ko }, minWidth: { - transform: It + transform: At }, height: { - transform: It + transform: At }, maxHeight: { - transform: It + transform: At }, minHeight: { - transform: It + transform: At }, boxSizing: {}, // typography @@ -5571,15 +5607,15 @@ const Nu = { cssProperty: !1, themeKey: "typography" } -}, Eo = Nu; -function ku(...t) { +}, Eo = xu; +function Nu(...t) { const e = t.reduce((r, o) => r.concat(Object.keys(o)), []), n = new Set(e); return t.every((r) => n.size === Object.keys(r).length); } -function Eu(t, e) { +function ku(t, e) { return typeof t == "function" ? t(e) : t; } -function Su() { +function Eu() { function t(n, r, o, a) { const i = { [n]: r, @@ -5626,10 +5662,10 @@ function Su() { return c; if (!d) return null; - const p = Dp(a.breakpoints), h = Object.keys(p); + const p = Mp(a.breakpoints), h = Object.keys(p); let w = p; return Object.keys(d).forEach((g) => { - const v = Eu(d[g], a); + const v = ku(d[g], a); if (v != null) if (typeof v == "object") if (i[g]) @@ -5640,36 +5676,36 @@ function Su() { }, v, (m) => ({ [g]: m })); - ku(f, v) ? w[g] = e({ + Nu(f, v) ? w[g] = e({ sx: v, theme: a }) : w = un(w, f); } else w = un(w, t(g, v, a, i)); - }), Bp(h, w); + }), Dp(h, w); } return Array.isArray(o) ? o.map(l) : l(o); } return e; } -const fs = Su(); -fs.filterProps = ["sx"]; -const So = fs; -function Tu(t, e) { +const hs = Eu(); +hs.filterProps = ["sx"]; +const So = hs; +function Su(t, e) { const n = this; return n.vars && typeof n.getColorSchemeSelector == "function" ? { [n.getColorSchemeSelector(t).replace(/(\[[^\]]+\])/, "*:where($1)")]: e } : n.palette.mode === t ? e : {}; } -const Cu = ["breakpoints", "palette", "spacing", "shape"]; +const Tu = ["breakpoints", "palette", "spacing", "shape"]; function To(t = {}, ...e) { const { breakpoints: n = {}, palette: r = {}, spacing: o, shape: a = {} - } = t, i = kt(t, Cu), l = $p(n), c = Hp(o); + } = t, i = kt(t, Tu), l = Pp(n), c = Gp(o); let d = Zt({ breakpoints: l, direction: "ltr", @@ -5681,26 +5717,26 @@ function To(t = {}, ...e) { spacing: c, shape: P({}, Ip, a) }, i); - return d.applyStyles = Tu, d = e.reduce((p, h) => Zt(p, h), d), d.unstable_sxConfig = P({}, Eo, i == null ? void 0 : i.unstable_sxConfig), d.unstable_sx = function(h) { + return d.applyStyles = Su, d = e.reduce((p, h) => Zt(p, h), d), d.unstable_sxConfig = P({}, Eo, i == null ? void 0 : i.unstable_sxConfig), d.unstable_sx = function(h) { return So({ sx: h, theme: this }); }, d; } -function Ou(t) { +function Cu(t) { return Object.keys(t).length === 0; } -function ms(t = null) { - const e = M.useContext(Xl); - return !e || Ou(e) ? t : e; +function gs(t = null) { + const e = M.useContext(zl); + return !e || Cu(e) ? t : e; } -const Ru = To(); -function hs(t = Ru) { - return ms(t); +const Ou = To(); +function bs(t = Ou) { + return gs(t); } -const _u = ["ownerState"], Pu = ["variants"], $u = ["name", "slot", "skipVariantsResolver", "skipSx", "overridesResolver"]; -function Au(t) { +const Ru = ["ownerState"], _u = ["variants"], Pu = ["name", "slot", "skipVariantsResolver", "skipSx", "overridesResolver"]; +function $u(t) { return Object.keys(t).length === 0; } function Iu(t) { @@ -5712,21 +5748,21 @@ function Iu(t) { function Gn(t) { return t !== "ownerState" && t !== "theme" && t !== "sx" && t !== "as"; } -const Mu = To(), Ta = (t) => t && t.charAt(0).toLowerCase() + t.slice(1); +const Au = To(), Ta = (t) => t && t.charAt(0).toLowerCase() + t.slice(1); function Vn({ defaultTheme: t, theme: e, themeId: n }) { - return Au(e) ? t : e[n] || e; + return $u(e) ? t : e[n] || e; } -function Du(t) { +function Mu(t) { return t ? (e, n) => n[t] : null; } function Hn(t, e) { let { ownerState: n - } = e, r = kt(e, _u); + } = e, r = kt(e, Ru); const o = typeof t == "function" ? t(P({ ownerState: n }, r)) : t; @@ -5738,7 +5774,7 @@ function Hn(t, e) { const { variants: a = [] } = o; - let l = kt(o, Pu); + let l = kt(o, _u); return a.forEach((c) => { let d = !0; typeof c.props == "function" ? d = c.props(P({ @@ -5752,10 +5788,10 @@ function Hn(t, e) { } return o; } -function Bu(t = {}) { +function Du(t = {}) { const { themeId: e, - defaultTheme: n = Mu, + defaultTheme: n = Au, rootShouldForwardProp: r = Gn, slotShouldForwardProp: o = Gn } = t, a = (i) => So(P({}, i, { @@ -5765,7 +5801,7 @@ function Bu(t = {}) { })) })); return a.__mui_systemSx = !0, (i, l = {}) => { - Yl(i, (b) => b.filter((A) => !(A != null && A.__mui_systemSx))); + Ll(i, (b) => b.filter((I) => !(I != null && I.__mui_systemSx))); const { name: c, slot: d, @@ -5773,8 +5809,8 @@ function Bu(t = {}) { skipSx: h, // TODO v6: remove `lowercaseFirstLetter()` in the next major release // For more details: https://github.com/mui/material-ui/pull/37908 - overridesResolver: w = Du(Ta(d)) - } = l, g = kt(l, $u), v = p !== void 0 ? p : ( + overridesResolver: w = Mu(Ta(d)) + } = l, g = kt(l, Pu), v = p !== void 0 ? p : ( // TODO v6: remove `Root` in the next major release // For more details: https://github.com/mui/material-ui/pull/37908 d && d !== "Root" && d !== "root" || !1 @@ -5783,18 +5819,18 @@ function Bu(t = {}) { process.env.NODE_ENV !== "production" && c && (m = `${c}-${Ta(d || "Root")}`); let E = Gn; d === "Root" || d === "root" ? E = r : d ? E = o : Iu(i) && (E = void 0); - const _ = Hl(i, P({ + const _ = Vl(i, P({ shouldForwardProp: E, label: m - }, g)), C = (b) => typeof b == "function" && b.__emotion_real !== b || he(b) ? (A) => Hn(b, P({}, A, { + }, g)), C = (b) => typeof b == "function" && b.__emotion_real !== b || he(b) ? (I) => Hn(b, P({}, I, { theme: Vn({ - theme: A.theme, + theme: I.theme, defaultTheme: n, themeId: e }) - })) : b, S = (b, ...A) => { + })) : b, S = (b, ...I) => { let z = C(b); - const H = A ? A.map(C) : []; + const H = I ? I.map(C) : []; c && w && H.push((k) => { const B = Vn(P({}, k, { defaultTheme: n, @@ -5820,7 +5856,7 @@ function Bu(t = {}) { theme: D })); }), f || H.push(a); - const O = H.length - A.length; + const O = H.length - I.length; if (Array.isArray(b) && O > 0) { const k = new Array(O).fill(""); z = [...b, ...k], z.raw = [...b.raw, ...k]; @@ -5828,38 +5864,38 @@ function Bu(t = {}) { const $ = _(z, ...H); if (process.env.NODE_ENV !== "production") { let k; - c && (k = `${c}${Wt(d || "")}`), k === void 0 && (k = `Styled(${ip(i)})`), $.displayName = k; + c && (k = `${c}${Wt(d || "")}`), k === void 0 && (k = `Styled(${ap(i)})`), $.displayName = k; } return i.muiName && ($.muiName = i.muiName), $; }; return _.withConfig && (S.withConfig = _.withConfig), S; }; } -function ju(t) { +function Bu(t) { const { theme: e, name: n, props: r } = t; - return !e || !e.components || !e.components[n] || !e.components[n].defaultProps ? r : ls(e.components[n].defaultProps, r); + return !e || !e.components || !e.components[n] || !e.components[n].defaultProps ? r : ds(e.components[n].defaultProps, r); } -function Vu({ +function ju({ props: t, name: e, defaultTheme: n, themeId: r }) { - let o = hs(n); - return r && (o = o[r] || o), ju({ + let o = bs(n); + return r && (o = o[r] || o), Bu({ theme: o, name: e, props: t }); } function Co(t, e = 0, n = 1) { - return process.env.NODE_ENV !== "production" && (t < e || t > n) && console.error(`MUI: The value provided ${t} is out of range [${e}, ${n}].`), Rp(t, e, n); + return process.env.NODE_ENV !== "production" && (t < e || t > n) && console.error(`MUI: The value provided ${t} is out of range [${e}, ${n}].`), Op(t, e, n); } -function zu(t) { +function Vu(t) { t = t.slice(1); const e = new RegExp(`.{1,${t.length >= 6 ? 2 : 1}}`, "g"); let n = t.match(e); @@ -5869,7 +5905,7 @@ function Ne(t) { if (t.type) return t; if (t.charAt(0) === "#") - return Ne(zu(t)); + return Ne(Vu(t)); const e = t.indexOf("("), n = t.substring(0, e); if (["rgb", "rgba", "hsl", "hsla", "color"].indexOf(n) === -1) throw new Error(process.env.NODE_ENV !== "production" ? `MUI: Unsupported \`${t}\` color. @@ -5897,7 +5933,7 @@ function yr(t) { } = t; return e.indexOf("rgb") !== -1 ? r = r.map((o, a) => a < 3 ? parseInt(o, 10) : o) : e.indexOf("hsl") !== -1 && (r[1] = `${r[1]}%`, r[2] = `${r[2]}%`), e.indexOf("color") !== -1 ? r = `${n} ${r.join(" ")}` : r = `${r.join(", ")}`, `${e}(${r})`; } -function Lu(t) { +function zu(t) { t = Ne(t); const { values: e @@ -5911,17 +5947,17 @@ function Lu(t) { } function Ca(t) { t = Ne(t); - let e = t.type === "hsl" || t.type === "hsla" ? Ne(Lu(t)).values : t.values; + let e = t.type === "hsl" || t.type === "hsla" ? Ne(zu(t)).values : t.values; return e = e.map((n) => (t.type !== "color" && (n /= 255), n <= 0.03928 ? n / 12.92 : ((n + 0.055) / 1.055) ** 2.4)), Number((0.2126 * e[0] + 0.7152 * e[1] + 0.0722 * e[2]).toFixed(3)); } function Oa(t, e) { const n = Ca(t), r = Ca(e); return (Math.max(n, r) + 0.05) / (Math.min(n, r) + 0.05); } -function gs(t, e) { +function vs(t, e) { return t = Ne(t), e = Co(e), (t.type === "rgb" || t.type === "hsl") && (t.type += "a"), t.type === "color" ? t.values[3] = `/${e}` : t.values[3] = e, yr(t); } -function Fu(t, e) { +function Lu(t, e) { if (t = Ne(t), e = Co(e), t.type.indexOf("hsl") !== -1) t.values[2] *= 1 - e; else if (t.type.indexOf("rgb") !== -1 || t.type.indexOf("color") !== -1) @@ -5929,7 +5965,7 @@ function Fu(t, e) { t.values[n] *= 1 - e; return yr(t); } -function Uu(t, e) { +function Fu(t, e) { if (t = Ne(t), e = Co(e), t.type.indexOf("hsl") !== -1) t.values[2] += (100 - t.values[2]) * e; else if (t.type.indexOf("rgb") !== -1) @@ -5940,7 +5976,7 @@ function Uu(t, e) { t.values[n] += (1 - t.values[n]) * e; return yr(t); } -function Gu(t, e) { +function Uu(t, e) { return P({ toolbar: { minHeight: 56, @@ -5955,10 +5991,10 @@ function Gu(t, e) { } }, e); } -const Hu = { +const Gu = { black: "#000", white: "#fff" -}, xn = Hu, Xu = { +}, xn = Gu, Hu = { 50: "#fafafa", 100: "#f5f5f5", 200: "#eeeeee", @@ -5973,7 +6009,7 @@ const Hu = { A200: "#eeeeee", A400: "#bdbdbd", A700: "#616161" -}, Yu = Xu, Wu = { +}, Xu = Hu, Yu = { 50: "#f3e5f5", 100: "#e1bee7", 200: "#ce93d8", @@ -5988,7 +6024,7 @@ const Hu = { A200: "#e040fb", A400: "#d500f9", A700: "#aa00ff" -}, Oe = Wu, qu = { +}, Oe = Yu, Wu = { 50: "#ffebee", 100: "#ffcdd2", 200: "#ef9a9a", @@ -6003,7 +6039,7 @@ const Hu = { A200: "#ff5252", A400: "#ff1744", A700: "#d50000" -}, Re = qu, Ku = { +}, Re = Wu, qu = { 50: "#fff3e0", 100: "#ffe0b2", 200: "#ffcc80", @@ -6018,7 +6054,7 @@ const Hu = { A200: "#ffab40", A400: "#ff9100", A700: "#ff6d00" -}, nn = Ku, Ju = { +}, nn = qu, Ku = { 50: "#e3f2fd", 100: "#bbdefb", 200: "#90caf9", @@ -6033,7 +6069,7 @@ const Hu = { A200: "#448aff", A400: "#2979ff", A700: "#2962ff" -}, _e = Ju, Zu = { +}, _e = Ku, Ju = { 50: "#e1f5fe", 100: "#b3e5fc", 200: "#81d4fa", @@ -6048,7 +6084,7 @@ const Hu = { A200: "#40c4ff", A400: "#00b0ff", A700: "#0091ea" -}, Pe = Zu, Qu = { +}, Pe = Ju, Zu = { 50: "#e8f5e9", 100: "#c8e6c9", 200: "#a5d6a7", @@ -6063,7 +6099,7 @@ const Hu = { A200: "#69f0ae", A400: "#00e676", A700: "#00c853" -}, $e = Qu, tw = ["mode", "contrastThreshold", "tonalOffset"], Ra = { +}, $e = Zu, Qu = ["mode", "contrastThreshold", "tonalOffset"], Ra = { // The colors used to style the text. text: { // The most important text. @@ -6128,9 +6164,9 @@ const Hu = { }; function _a(t, e, n, r) { const o = r.light || r, a = r.dark || r * 1.5; - t[e] || (t.hasOwnProperty(n) ? t[e] = t[n] : e === "light" ? t.light = Uu(t.main, o) : e === "dark" && (t.dark = Fu(t.main, a))); + t[e] || (t.hasOwnProperty(n) ? t[e] = t[n] : e === "light" ? t.light = Fu(t.main, o) : e === "dark" && (t.dark = Lu(t.main, a))); } -function ew(t = "light") { +function tw(t = "light") { return t === "dark" ? { main: _e[200], light: _e[50], @@ -6141,7 +6177,7 @@ function ew(t = "light") { dark: _e[800] }; } -function nw(t = "light") { +function ew(t = "light") { return t === "dark" ? { main: Oe[200], light: Oe[50], @@ -6152,7 +6188,7 @@ function nw(t = "light") { dark: Oe[700] }; } -function rw(t = "light") { +function nw(t = "light") { return t === "dark" ? { main: Re[500], light: Re[300], @@ -6163,7 +6199,7 @@ function rw(t = "light") { dark: Re[800] }; } -function ow(t = "light") { +function rw(t = "light") { return t === "dark" ? { main: Pe[400], light: Pe[300], @@ -6174,7 +6210,7 @@ function ow(t = "light") { dark: Pe[900] }; } -function aw(t = "light") { +function ow(t = "light") { return t === "dark" ? { main: $e[400], light: $e[300], @@ -6185,7 +6221,7 @@ function aw(t = "light") { dark: $e[900] }; } -function iw(t = "light") { +function aw(t = "light") { return t === "dark" ? { main: nn[400], light: nn[300], @@ -6197,12 +6233,12 @@ function iw(t = "light") { dark: nn[900] }; } -function sw(t) { +function iw(t) { const { mode: e = "light", contrastThreshold: n = 3, tonalOffset: r = 0.2 - } = t, o = kt(t, tw), a = t.primary || ew(e), i = t.secondary || nw(e), l = t.error || rw(e), c = t.info || ow(e), d = t.success || aw(e), p = t.warning || iw(e); + } = t, o = kt(t, Qu), a = t.primary || tw(e), i = t.secondary || ew(e), l = t.error || nw(e), c = t.info || rw(e), d = t.success || ow(e), p = t.warning || aw(e); function h(f) { const m = Oa(f, Fr.text.primary) >= n ? Fr.text.primary : Ra.text.primary; if (process.env.NODE_ENV !== "production") { @@ -6282,7 +6318,7 @@ const theme2 = createTheme({ palette: { name: "success" }), // The grey colors. - grey: Yu, + grey: Xu, // Used by `getContrastText()` to maximize the contrast between // the background and the text. contrastThreshold: n, @@ -6296,14 +6332,14 @@ const theme2 = createTheme({ palette: { tonalOffset: r }, g[e]), o); } -const lw = ["fontFamily", "fontSize", "fontWeightLight", "fontWeightRegular", "fontWeightMedium", "fontWeightBold", "htmlFontSize", "allVariants", "pxToRem"]; -function cw(t) { +const sw = ["fontFamily", "fontSize", "fontWeightLight", "fontWeightRegular", "fontWeightMedium", "fontWeightBold", "htmlFontSize", "allVariants", "pxToRem"]; +function lw(t) { return Math.round(t * 1e5) / 1e5; } const Pa = { textTransform: "uppercase" }, $a = '"Roboto", "Helvetica", "Arial", sans-serif'; -function dw(t, e) { +function cw(t, e) { const n = typeof e == "function" ? e(t) : e, { fontFamily: r = $a, // The default font size of the Material Specification. @@ -6319,7 +6355,7 @@ function dw(t, e) { // Apply the CSS properties to all the variants. allVariants: p, pxToRem: h - } = n, w = kt(n, lw); + } = n, w = kt(n, sw); process.env.NODE_ENV !== "production" && (typeof o != "number" && console.error("MUI: `fontSize` is required to be a number."), typeof d != "number" && console.error("MUI: `htmlFontSize` is required to be a number.")); const g = o / 14, v = h || ((E) => `${E / d * g}rem`), f = (E, _, C, S, b) => P({ fontFamily: r, @@ -6328,7 +6364,7 @@ function dw(t, e) { // Unitless following https://meyerweb.com/eric/thoughts/2006/02/08/unitless-line-heights/ lineHeight: C }, r === $a ? { - letterSpacing: `${cw(S / _)}em` + letterSpacing: `${lw(S / _)}em` } : {}, b, p), m = { h1: f(a, 96, 1.167, -1.5), h2: f(a, 60, 1.2, -0.5), @@ -6366,11 +6402,11 @@ function dw(t, e) { // No need to clone deep }); } -const pw = 0.2, uw = 0.14, ww = 0.12; +const dw = 0.2, pw = 0.14, uw = 0.12; function ft(...t) { - return [`${t[0]}px ${t[1]}px ${t[2]}px ${t[3]}px rgba(0,0,0,${pw})`, `${t[4]}px ${t[5]}px ${t[6]}px ${t[7]}px rgba(0,0,0,${uw})`, `${t[8]}px ${t[9]}px ${t[10]}px ${t[11]}px rgba(0,0,0,${ww})`].join(","); + return [`${t[0]}px ${t[1]}px ${t[2]}px ${t[3]}px rgba(0,0,0,${dw})`, `${t[4]}px ${t[5]}px ${t[6]}px ${t[7]}px rgba(0,0,0,${pw})`, `${t[8]}px ${t[9]}px ${t[10]}px ${t[11]}px rgba(0,0,0,${uw})`].join(","); } -const fw = ["none", ft(0, 2, 1, -1, 0, 1, 1, 0, 0, 1, 3, 0), ft(0, 3, 1, -2, 0, 2, 2, 0, 0, 1, 5, 0), ft(0, 3, 3, -2, 0, 3, 4, 0, 0, 1, 8, 0), ft(0, 2, 4, -1, 0, 4, 5, 0, 0, 1, 10, 0), ft(0, 3, 5, -1, 0, 5, 8, 0, 0, 1, 14, 0), ft(0, 3, 5, -1, 0, 6, 10, 0, 0, 1, 18, 0), ft(0, 4, 5, -2, 0, 7, 10, 1, 0, 2, 16, 1), ft(0, 5, 5, -3, 0, 8, 10, 1, 0, 3, 14, 2), ft(0, 5, 6, -3, 0, 9, 12, 1, 0, 3, 16, 2), ft(0, 6, 6, -3, 0, 10, 14, 1, 0, 4, 18, 3), ft(0, 6, 7, -4, 0, 11, 15, 1, 0, 4, 20, 3), ft(0, 7, 8, -4, 0, 12, 17, 2, 0, 5, 22, 4), ft(0, 7, 8, -4, 0, 13, 19, 2, 0, 5, 24, 4), ft(0, 7, 9, -4, 0, 14, 21, 2, 0, 5, 26, 4), ft(0, 8, 9, -5, 0, 15, 22, 2, 0, 6, 28, 5), ft(0, 8, 10, -5, 0, 16, 24, 2, 0, 6, 30, 5), ft(0, 8, 11, -5, 0, 17, 26, 2, 0, 6, 32, 5), ft(0, 9, 11, -5, 0, 18, 28, 2, 0, 7, 34, 6), ft(0, 9, 12, -6, 0, 19, 29, 2, 0, 7, 36, 6), ft(0, 10, 13, -6, 0, 20, 31, 3, 0, 8, 38, 7), ft(0, 10, 13, -6, 0, 21, 33, 3, 0, 8, 40, 7), ft(0, 10, 14, -6, 0, 22, 35, 3, 0, 8, 42, 7), ft(0, 11, 14, -7, 0, 23, 36, 3, 0, 9, 44, 8), ft(0, 11, 15, -7, 0, 24, 38, 3, 0, 9, 46, 8)], mw = fw, hw = ["duration", "easing", "delay"], gw = { +const ww = ["none", ft(0, 2, 1, -1, 0, 1, 1, 0, 0, 1, 3, 0), ft(0, 3, 1, -2, 0, 2, 2, 0, 0, 1, 5, 0), ft(0, 3, 3, -2, 0, 3, 4, 0, 0, 1, 8, 0), ft(0, 2, 4, -1, 0, 4, 5, 0, 0, 1, 10, 0), ft(0, 3, 5, -1, 0, 5, 8, 0, 0, 1, 14, 0), ft(0, 3, 5, -1, 0, 6, 10, 0, 0, 1, 18, 0), ft(0, 4, 5, -2, 0, 7, 10, 1, 0, 2, 16, 1), ft(0, 5, 5, -3, 0, 8, 10, 1, 0, 3, 14, 2), ft(0, 5, 6, -3, 0, 9, 12, 1, 0, 3, 16, 2), ft(0, 6, 6, -3, 0, 10, 14, 1, 0, 4, 18, 3), ft(0, 6, 7, -4, 0, 11, 15, 1, 0, 4, 20, 3), ft(0, 7, 8, -4, 0, 12, 17, 2, 0, 5, 22, 4), ft(0, 7, 8, -4, 0, 13, 19, 2, 0, 5, 24, 4), ft(0, 7, 9, -4, 0, 14, 21, 2, 0, 5, 26, 4), ft(0, 8, 9, -5, 0, 15, 22, 2, 0, 6, 28, 5), ft(0, 8, 10, -5, 0, 16, 24, 2, 0, 6, 30, 5), ft(0, 8, 11, -5, 0, 17, 26, 2, 0, 6, 32, 5), ft(0, 9, 11, -5, 0, 18, 28, 2, 0, 7, 34, 6), ft(0, 9, 12, -6, 0, 19, 29, 2, 0, 7, 36, 6), ft(0, 10, 13, -6, 0, 20, 31, 3, 0, 8, 38, 7), ft(0, 10, 13, -6, 0, 21, 33, 3, 0, 8, 40, 7), ft(0, 10, 14, -6, 0, 22, 35, 3, 0, 8, 42, 7), ft(0, 11, 14, -7, 0, 23, 36, 3, 0, 9, 44, 8), ft(0, 11, 15, -7, 0, 24, 38, 3, 0, 9, 46, 8)], fw = ww, mw = ["duration", "easing", "delay"], hw = { // This is the most common easing curve. easeInOut: "cubic-bezier(0.4, 0, 0.2, 1)", // Objects enter the screen at full velocity from off-screen and @@ -6380,7 +6416,7 @@ const fw = ["none", ft(0, 2, 1, -1, 0, 1, 1, 0, 0, 1, 3, 0), ft(0, 3, 1, -2, 0, easeIn: "cubic-bezier(0.4, 0, 1, 1)", // The sharp curve is used by objects that may return to the screen at any time. sharp: "cubic-bezier(0.4, 0, 0.6, 1)" -}, bw = { +}, gw = { shortest: 150, shorter: 200, short: 250, @@ -6393,38 +6429,38 @@ const fw = ["none", ft(0, 2, 1, -1, 0, 1, 1, 0, 0, 1, 3, 0), ft(0, 3, 1, -2, 0, // recommended when something is leaving screen leavingScreen: 195 }; -function Aa(t) { +function Ia(t) { return `${Math.round(t)}ms`; } -function vw(t) { +function bw(t) { if (!t) return 0; const e = t / 36; return Math.round((4 + 15 * e ** 0.25 + e / 5) * 10); } -function yw(t) { - const e = P({}, gw, t.easing), n = P({}, bw, t.duration); +function vw(t) { + const e = P({}, hw, t.easing), n = P({}, gw, t.duration); return P({ - getAutoHeightDuration: vw, + getAutoHeightDuration: bw, create: (o = ["all"], a = {}) => { const { duration: i = n.standard, easing: l = e.easeInOut, delay: c = 0 - } = a, d = kt(a, hw); + } = a, d = kt(a, mw); if (process.env.NODE_ENV !== "production") { const p = (w) => typeof w == "string", h = (w) => !isNaN(parseFloat(w)); !p(o) && !Array.isArray(o) && console.error('MUI: Argument "props" must be a string or Array.'), !h(i) && !p(i) && console.error(`MUI: Argument "duration" must be a number or a string but found ${i}.`), p(l) || console.error('MUI: Argument "easing" must be a string.'), !h(c) && !p(c) && console.error('MUI: Argument "delay" must be a number or a string.'), typeof a != "object" && console.error(["MUI: Secong argument of transition.create must be an object.", "Arguments should be either `create('prop1', options)` or `create(['prop1', 'prop2'], options)`"].join(` `)), Object.keys(d).length !== 0 && console.error(`MUI: Unrecognized argument(s) [${Object.keys(d).join(",")}].`); } - return (Array.isArray(o) ? o : [o]).map((p) => `${p} ${typeof i == "string" ? i : Aa(i)} ${l} ${typeof c == "string" ? c : Aa(c)}`).join(","); + return (Array.isArray(o) ? o : [o]).map((p) => `${p} ${typeof i == "string" ? i : Ia(i)} ${l} ${typeof c == "string" ? c : Ia(c)}`).join(","); } }, t, { easing: e, duration: n }); } -const xw = { +const yw = { mobileStepper: 1e3, fab: 1050, speedDial: 1050, @@ -6433,25 +6469,25 @@ const xw = { modal: 1300, snackbar: 1400, tooltip: 1500 -}, Nw = xw, kw = ["breakpoints", "mixins", "spacing", "palette", "transitions", "typography", "shape"]; -function Ew(t = {}, ...e) { +}, xw = yw, Nw = ["breakpoints", "mixins", "spacing", "palette", "transitions", "typography", "shape"]; +function kw(t = {}, ...e) { const { mixins: n = {}, palette: r = {}, transitions: o = {}, typography: a = {} - } = t, i = kt(t, kw); + } = t, i = kt(t, Nw); if (t.vars) throw new Error(process.env.NODE_ENV !== "production" ? "MUI: `vars` is a private field used for CSS variables support.\nPlease use another name." : Ve(18)); - const l = sw(r), c = To(t); + const l = iw(r), c = To(t); let d = Zt(c, { - mixins: Gu(c.breakpoints, n), + mixins: Uu(c.breakpoints, n), palette: l, // Don't use [...shadows] until you've verified its transpiled code is not invoking the iterator protocol. - shadows: mw.slice(), - typography: dw(l, a), - transitions: yw(o), - zIndex: P({}, Nw) + shadows: fw.slice(), + typography: cw(l, a), + transitions: vw(o), + zIndex: P({}, xw) }); if (d = Zt(d, i), d = e.reduce((p, h) => Zt(p, h), d), process.env.NODE_ENV !== "production") { const p = ["active", "checked", "completed", "disabled", "error", "expanded", "focused", "focusVisible", "required", "selected"], h = (w, g) => { @@ -6484,28 +6520,28 @@ function Ew(t = {}, ...e) { }); }, d; } -const Sw = Ew(), Oo = Sw, Ro = "$$material"; +const Ew = kw(), Oo = Ew, Ro = "$$material"; function _o({ props: t, name: e }) { - return Vu({ + return ju({ props: t, name: e, defaultTheme: Oo, themeId: Ro }); } -const Tw = (t) => Gn(t) && t !== "classes", Cw = Bu({ +const Sw = (t) => Gn(t) && t !== "classes", Tw = Du({ themeId: Ro, defaultTheme: Oo, - rootShouldForwardProp: Tw -}), Rn = Cw; -function Ow(t) { + rootShouldForwardProp: Sw +}), Rn = Tw; +function Cw(t) { return pr("MuiSvgIcon", t); } -ps("MuiSvgIcon", ["root", "colorPrimary", "colorSecondary", "colorAction", "colorError", "colorDisabled", "fontSizeInherit", "fontSizeSmall", "fontSizeMedium", "fontSizeLarge"]); -const Rw = ["children", "className", "color", "component", "fontSize", "htmlColor", "inheritViewBox", "titleAccess", "viewBox"], _w = (t) => { +ws("MuiSvgIcon", ["root", "colorPrimary", "colorSecondary", "colorAction", "colorError", "colorDisabled", "fontSizeInherit", "fontSizeSmall", "fontSizeMedium", "fontSizeLarge"]); +const Ow = ["children", "className", "color", "component", "fontSize", "htmlColor", "inheritViewBox", "titleAccess", "viewBox"], Rw = (t) => { const { color: e, fontSize: n, @@ -6513,8 +6549,8 @@ const Rw = ["children", "className", "color", "component", "fontSize", "htmlColo } = t, o = { root: ["root", e !== "inherit" && `color${Wt(e)}`, `fontSize${Wt(n)}`] }; - return xo(o, Ow, r); -}, Pw = Rn("svg", { + return xo(o, Cw, r); +}, _w = Rn("svg", { name: "MuiSvgIcon", slot: "Root", overridesResolver: (t, e) => { @@ -6567,7 +6603,7 @@ const Rw = ["children", "className", "color", "component", "fontSize", "htmlColo inheritViewBox: p = !1, titleAccess: h, viewBox: w = "0 0 24 24" - } = r, g = kt(r, Rw), v = /* @__PURE__ */ M.isValidElement(o) && o.type === "svg", f = P({}, r, { + } = r, g = kt(r, Ow), v = /* @__PURE__ */ M.isValidElement(o) && o.type === "svg", f = P({}, r, { color: i, component: l, fontSize: c, @@ -6577,8 +6613,8 @@ const Rw = ["children", "className", "color", "component", "fontSize", "htmlColo hasSvgAsChild: v }), m = {}; p || (m.viewBox = w); - const E = _w(f); - return /* @__PURE__ */ x(Pw, P({ + const E = Rw(f); + return /* @__PURE__ */ x(_w, P({ as: l, className: be(E.root, a), focusable: "false", @@ -6666,46 +6702,46 @@ process.env.NODE_ENV !== "production" && (Po.propTypes = { viewBox: u.string }); Po.muiName = "SvgIcon"; -const Ia = Po; -function bs(t, e) { +const Aa = Po; +function ys(t, e) { function n(r, o) { - return /* @__PURE__ */ s(Ia, P({ + return /* @__PURE__ */ s(Aa, P({ "data-testid": `${e}Icon`, ref: o }, r, { children: t })); } - return process.env.NODE_ENV !== "production" && (n.displayName = `${e}Icon`), n.muiName = Ia.muiName, /* @__PURE__ */ M.memo(/* @__PURE__ */ M.forwardRef(n)); + return process.env.NODE_ENV !== "production" && (n.displayName = `${e}Icon`), n.muiName = Aa.muiName, /* @__PURE__ */ M.memo(/* @__PURE__ */ M.forwardRef(n)); } -const $w = { +const Pw = { configure: (t) => { process.env.NODE_ENV !== "production" && console.warn(["MUI: `ClassNameGenerator` import from `@mui/material/utils` is outdated and might cause unexpected issues.", "", "You should use `import { unstable_ClassNameGenerator } from '@mui/material/className'` instead", "", "The detail of the issue: https://github.com/mui/material-ui/issues/30011#issuecomment-1024993401", "", "The updated documentation: https://mui.com/guides/classname-generator/"].join(` -`)), cs.configure(t); +`)), ps.configure(t); } -}, Aw = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({ +}, $w = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({ __proto__: null, capitalize: Wt, - createChainedFunction: lp, - createSvgIcon: bs, - debounce: cp, - deprecatedPropType: dp, - isMuiElement: pp, + createChainedFunction: sp, + createSvgIcon: ys, + debounce: lp, + deprecatedPropType: cp, + isMuiElement: dp, ownerDocument: Yn, - ownerWindow: up, - requirePropFactory: wp, + ownerWindow: pp, + requirePropFactory: up, setRef: Wn, - unstable_ClassNameGenerator: $w, + unstable_ClassNameGenerator: Pw, unstable_useEnhancedEffect: ze, - unstable_useId: as, - unsupportedProp: hp, - useControlled: is, + unstable_useId: ss, + unsupportedProp: mp, + useControlled: ls, useEventCallback: eo, useForkRef: xe, - useIsFocusVisible: ss -}, Symbol.toStringTag, { value: "Module" })), Iw = /* @__PURE__ */ Fd(Aw); + useIsFocusVisible: cs +}, Symbol.toStringTag, { value: "Module" })), Iw = /* @__PURE__ */ Ld($w); var Ma; -function Mw() { +function Aw() { return Ma || (Ma = 1, function(t) { "use client"; Object.defineProperty(t, "__esModule", { @@ -6717,34 +6753,34 @@ function Mw() { } }); var e = Iw; - }(Ir)), Ir; + }(Ar)), Ar; } -var Dw = Ud; +var Mw = Fd; Object.defineProperty(bo, "__esModule", { value: !0 }); -var vs = bo.default = void 0, Bw = Dw(Mw()), jw = Qs; -vs = bo.default = (0, Bw.default)(/* @__PURE__ */ (0, jw.jsx)("path", { +var xs = bo.default = void 0, Dw = Mw(Aw()), Bw = el; +xs = bo.default = (0, Dw.default)(/* @__PURE__ */ (0, Bw.jsx)("path", { d: "m10 17 5-5-5-5z" }), "ArrowRight"); -function Vw(t) { +function jw(t) { return typeof t == "string"; } function ln(t, e, n) { - return t === void 0 || Vw(t) ? e : P({}, e, { + return t === void 0 || jw(t) ? e : P({}, e, { ownerState: P({}, e.ownerState, n) }); } -const zw = { +const Vw = { disableDefaultClasses: !1 -}, Lw = /* @__PURE__ */ M.createContext(zw); -function Fw(t) { +}, zw = /* @__PURE__ */ M.createContext(Vw); +function Lw(t) { const { disableDefaultClasses: e - } = M.useContext(Lw); + } = M.useContext(zw); return (n) => e ? "" : t(n); } -function Uw(t, e = []) { +function Fw(t, e = []) { if (t === void 0) return {}; const n = {}; @@ -6752,7 +6788,7 @@ function Uw(t, e = []) { n[r] = t[r]; }), n; } -function Gw(t, e, n) { +function Uw(t, e, n) { return typeof t == "function" ? t(e, n) : t; } function Da(t) { @@ -6763,7 +6799,7 @@ function Da(t) { e[n] = t[n]; }), e; } -function Hw(t) { +function Gw(t) { const { getSlotProps: e, additionalProps: n, @@ -6778,48 +6814,48 @@ function Hw(t) { internalRef: void 0 }; } - const i = Uw(P({}, o, r)), l = Da(r), c = Da(o), d = e(i), p = be(d == null ? void 0 : d.className, n == null ? void 0 : n.className, a, o == null ? void 0 : o.className, r == null ? void 0 : r.className), h = P({}, d == null ? void 0 : d.style, n == null ? void 0 : n.style, o == null ? void 0 : o.style, r == null ? void 0 : r.style), w = P({}, d, n, c, l); + const i = Fw(P({}, o, r)), l = Da(r), c = Da(o), d = e(i), p = be(d == null ? void 0 : d.className, n == null ? void 0 : n.className, a, o == null ? void 0 : o.className, r == null ? void 0 : r.className), h = P({}, d == null ? void 0 : d.style, n == null ? void 0 : n.style, o == null ? void 0 : o.style, r == null ? void 0 : r.style), w = P({}, d, n, c, l); return p.length > 0 && (w.className = p), Object.keys(h).length > 0 && (w.style = h), { props: w, internalRef: d.ref }; } -const Xw = ["elementType", "externalSlotProps", "ownerState", "skipResolvingSlotProps"]; -function Yw(t) { +const Hw = ["elementType", "externalSlotProps", "ownerState", "skipResolvingSlotProps"]; +function Xw(t) { var e; const { elementType: n, externalSlotProps: r, ownerState: o, skipResolvingSlotProps: a = !1 - } = t, i = kt(t, Xw), l = a ? {} : Gw(r, o), { + } = t, i = kt(t, Hw), l = a ? {} : Uw(r, o), { props: c, internalRef: d - } = Hw(P({}, i, { + } = Gw(P({}, i, { externalSlotProps: l })), p = xe(d, l == null ? void 0 : l.ref, (e = t.additionalProps) == null ? void 0 : e.ref); return ln(n, P({}, c, { ref: p }), o); } -const ys = "base"; -function Ww(t) { - return `${ys}--${t}`; +const Ns = "base"; +function Yw(t) { + return `${Ns}--${t}`; } -function qw(t, e) { - return `${ys}-${t}-${e}`; +function Ww(t, e) { + return `${Ns}-${t}-${e}`; } -function xs(t, e) { - const n = ds[e]; - return n ? Ww(n) : qw(t, e); +function ks(t, e) { + const n = us[e]; + return n ? Yw(n) : Ww(t, e); } -function Kw(t, e) { +function qw(t, e) { const n = {}; return e.forEach((r) => { - n[r] = xs(t, r); + n[r] = ks(t, r); }), n; } -function Jw(t) { +function Kw(t) { return typeof t == "function" ? t() : t; } const Kn = /* @__PURE__ */ M.forwardRef(function(e, n) { @@ -6829,7 +6865,7 @@ const Kn = /* @__PURE__ */ M.forwardRef(function(e, n) { disablePortal: a = !1 } = e, [i, l] = M.useState(null), c = xe(/* @__PURE__ */ M.isValidElement(r) ? r.ref : null, n); if (ze(() => { - a || l(Jw(o) || document.body); + a || l(Kw(o) || document.body); }, [o, a]), ze(() => { if (i && !a) return Wn(n, i), () => { @@ -6847,7 +6883,7 @@ const Kn = /* @__PURE__ */ M.forwardRef(function(e, n) { }); } return /* @__PURE__ */ s(M.Fragment, { - children: i && /* @__PURE__ */ Wl.createPortal(r, i) + children: i && /* @__PURE__ */ ql.createPortal(r, i) }); }); process.env.NODE_ENV !== "production" && (Kn.propTypes = { @@ -6876,12 +6912,12 @@ process.env.NODE_ENV !== "production" && (Kn.propTypes = { */ disablePortal: u.bool }); -process.env.NODE_ENV !== "production" && (Kn["propTypes"] = ep(Kn.propTypes)); -var Ct = "top", Vt = "bottom", zt = "right", Ot = "left", $o = "auto", _n = [Ct, Vt, zt, Ot], Le = "start", Nn = "end", Zw = "clippingParents", Ns = "viewport", rn = "popper", Qw = "reference", Ba = /* @__PURE__ */ _n.reduce(function(t, e) { +process.env.NODE_ENV !== "production" && (Kn["propTypes"] = tp(Kn.propTypes)); +var Ct = "top", Vt = "bottom", zt = "right", Ot = "left", $o = "auto", _n = [Ct, Vt, zt, Ot], Le = "start", Nn = "end", Jw = "clippingParents", Es = "viewport", rn = "popper", Zw = "reference", Ba = /* @__PURE__ */ _n.reduce(function(t, e) { return t.concat([e + "-" + Le, e + "-" + Nn]); -}, []), ks = /* @__PURE__ */ [].concat(_n, [$o]).reduce(function(t, e) { +}, []), Ss = /* @__PURE__ */ [].concat(_n, [$o]).reduce(function(t, e) { return t.concat([e, e + "-" + Le, e + "-" + Nn]); -}, []), tf = "beforeRead", ef = "read", nf = "afterRead", rf = "beforeMain", of = "main", af = "afterMain", sf = "beforeWrite", lf = "write", cf = "afterWrite", df = [tf, ef, nf, rf, of, af, sf, lf, cf]; +}, []), Qw = "beforeRead", tf = "read", ef = "afterRead", nf = "beforeMain", rf = "main", of = "afterMain", af = "beforeWrite", sf = "write", lf = "afterWrite", cf = [Qw, tf, ef, nf, rf, of, af, sf, lf]; function qt(t) { return t ? (t.nodeName || "").toLowerCase() : null; } @@ -6902,13 +6938,13 @@ function jt(t) { var e = Mt(t).HTMLElement; return t instanceof e || t instanceof HTMLElement; } -function Ao(t) { +function Io(t) { if (typeof ShadowRoot > "u") return !1; var e = Mt(t).ShadowRoot; return t instanceof e || t instanceof ShadowRoot; } -function pf(t) { +function df(t) { var e = t.state; Object.keys(e.elements).forEach(function(n) { var r = e.styles[n] || {}, o = e.attributes[n] || {}, a = e.elements[n]; @@ -6918,7 +6954,7 @@ function pf(t) { })); }); } -function uf(t) { +function pf(t) { var e = t.state, n = { popper: { position: e.options.strategy, @@ -6942,12 +6978,12 @@ function uf(t) { }); }; } -const wf = { +const uf = { name: "applyStyles", enabled: !0, phase: "write", - fn: pf, - effect: uf, + fn: df, + effect: pf, requires: ["computeStyles"] }; function Yt(t) { @@ -6960,14 +6996,14 @@ function ro() { return e.brand + "/" + e.version; }).join(" ") : navigator.userAgent; } -function Es() { +function Ts() { return !/^((?!chrome|android).)*safari/i.test(ro()); } function Ue(t, e, n) { e === void 0 && (e = !1), n === void 0 && (n = !1); var r = t.getBoundingClientRect(), o = 1, a = 1; e && jt(t) && (o = t.offsetWidth > 0 && Fe(r.width) / t.offsetWidth || 1, a = t.offsetHeight > 0 && Fe(r.height) / t.offsetHeight || 1); - var i = ke(t) ? Mt(t) : window, l = i.visualViewport, c = !Es() && n, d = (r.left + (c && l ? l.offsetLeft : 0)) / o, p = (r.top + (c && l ? l.offsetTop : 0)) / a, h = r.width / o, w = r.height / a; + var i = ke(t) ? Mt(t) : window, l = i.visualViewport, c = !Ts() && n, d = (r.left + (c && l ? l.offsetLeft : 0)) / o, p = (r.top + (c && l ? l.offsetTop : 0)) / a, h = r.width / o, w = r.height / a; return { width: h, height: w, @@ -6979,7 +7015,7 @@ function Ue(t, e, n) { y: p }; } -function Io(t) { +function Ao(t) { var e = Ue(t), n = t.offsetWidth, r = t.offsetHeight; return Math.abs(e.width - n) <= 1 && (n = e.width), Math.abs(e.height - r) <= 1 && (r = e.height), { x: t.offsetLeft, @@ -6988,11 +7024,11 @@ function Io(t) { height: r }; } -function Ss(t, e) { +function Cs(t, e) { var n = e.getRootNode && e.getRootNode(); if (t.contains(e)) return !0; - if (n && Ao(n)) { + if (n && Io(n)) { var r = e; do { if (r && t.isSameNode(r)) @@ -7005,7 +7041,7 @@ function Ss(t, e) { function te(t) { return Mt(t).getComputedStyle(t); } -function ff(t) { +function wf(t) { return ["table", "td", "th"].indexOf(qt(t)) >= 0; } function le(t) { @@ -7021,7 +7057,7 @@ function xr(t) { // $FlowFixMe[prop-missing] t.assignedSlot || // step into the shadow DOM of the parent of a slotted node t.parentNode || // DOM Element detected - (Ao(t) ? t.host : null) || // ShadowRoot detected + (Io(t) ? t.host : null) || // ShadowRoot detected // $FlowFixMe[incompatible-call]: HTMLElement is a Node le(t) ); @@ -7030,7 +7066,7 @@ function ja(t) { return !jt(t) || // https://github.com/popperjs/popper-core/issues/837 te(t).position === "fixed" ? null : t.offsetParent; } -function mf(t) { +function ff(t) { var e = /firefox/i.test(ro()), n = /Trident/i.test(ro()); if (n && jt(t)) { var r = te(t); @@ -7038,7 +7074,7 @@ function mf(t) { return null; } var o = xr(t); - for (Ao(o) && (o = o.host); jt(o) && ["html", "body"].indexOf(qt(o)) < 0; ) { + for (Io(o) && (o = o.host); jt(o) && ["html", "body"].indexOf(qt(o)) < 0; ) { var a = te(o); if (a.transform !== "none" || a.perspective !== "none" || a.contain === "paint" || ["transform", "perspective"].indexOf(a.willChange) !== -1 || e && a.willChange === "filter" || e && a.filter && a.filter !== "none") return o; @@ -7047,9 +7083,9 @@ function mf(t) { return null; } function Pn(t) { - for (var e = Mt(t), n = ja(t); n && ff(n) && te(n).position === "static"; ) + for (var e = Mt(t), n = ja(t); n && wf(n) && te(n).position === "static"; ) n = ja(n); - return n && (qt(n) === "html" || qt(n) === "body" && te(n).position === "static") ? e : n || mf(t) || e; + return n && (qt(n) === "html" || qt(n) === "body" && te(n).position === "static") ? e : n || ff(t) || e; } function Mo(t) { return ["top", "bottom"].indexOf(t) >= 0 ? "x" : "y"; @@ -7057,11 +7093,11 @@ function Mo(t) { function wn(t, e, n) { return ve(t, Jn(e, n)); } -function hf(t, e, n) { +function mf(t, e, n) { var r = wn(t, e, n); return r > n ? n : r; } -function Ts() { +function Os() { return { top: 0, right: 0, @@ -7069,49 +7105,49 @@ function Ts() { left: 0 }; } -function Cs(t) { - return Object.assign({}, Ts(), t); +function Rs(t) { + return Object.assign({}, Os(), t); } -function Os(t, e) { +function _s(t, e) { return e.reduce(function(n, r) { return n[r] = t, n; }, {}); } -var gf = function(e, n) { +var hf = function(e, n) { return e = typeof e == "function" ? e(Object.assign({}, n.rects, { placement: n.placement - })) : e, Cs(typeof e != "number" ? e : Os(e, _n)); + })) : e, Rs(typeof e != "number" ? e : _s(e, _n)); }; -function bf(t) { +function gf(t) { var e, n = t.state, r = t.name, o = t.options, a = n.elements.arrow, i = n.modifiersData.popperOffsets, l = Yt(n.placement), c = Mo(l), d = [Ot, zt].indexOf(l) >= 0, p = d ? "height" : "width"; if (!(!a || !i)) { - var h = gf(o.padding, n), w = Io(a), g = c === "y" ? Ct : Ot, v = c === "y" ? Vt : zt, f = n.rects.reference[p] + n.rects.reference[c] - i[c] - n.rects.popper[p], m = i[c] - n.rects.reference[c], E = Pn(a), _ = E ? c === "y" ? E.clientHeight || 0 : E.clientWidth || 0 : 0, C = f / 2 - m / 2, S = h[g], b = _ - w[p] - h[v], A = _ / 2 - w[p] / 2 + C, z = wn(S, A, b), H = c; - n.modifiersData[r] = (e = {}, e[H] = z, e.centerOffset = z - A, e); + var h = hf(o.padding, n), w = Ao(a), g = c === "y" ? Ct : Ot, v = c === "y" ? Vt : zt, f = n.rects.reference[p] + n.rects.reference[c] - i[c] - n.rects.popper[p], m = i[c] - n.rects.reference[c], E = Pn(a), _ = E ? c === "y" ? E.clientHeight || 0 : E.clientWidth || 0 : 0, C = f / 2 - m / 2, S = h[g], b = _ - w[p] - h[v], I = _ / 2 - w[p] / 2 + C, z = wn(S, I, b), H = c; + n.modifiersData[r] = (e = {}, e[H] = z, e.centerOffset = z - I, e); } } -function vf(t) { +function bf(t) { var e = t.state, n = t.options, r = n.element, o = r === void 0 ? "[data-popper-arrow]" : r; - o != null && (typeof o == "string" && (o = e.elements.popper.querySelector(o), !o) || Ss(e.elements.popper, o) && (e.elements.arrow = o)); + o != null && (typeof o == "string" && (o = e.elements.popper.querySelector(o), !o) || Cs(e.elements.popper, o) && (e.elements.arrow = o)); } -const yf = { +const vf = { name: "arrow", enabled: !0, phase: "main", - fn: bf, - effect: vf, + fn: gf, + effect: bf, requires: ["popperOffsets"], requiresIfExists: ["preventOverflow"] }; function Ge(t) { return t.split("-")[1]; } -var xf = { +var yf = { top: "auto", right: "auto", bottom: "auto", left: "auto" }; -function Nf(t, e) { +function xf(t, e) { var n = t.x, r = t.y, o = e.devicePixelRatio || 1; return { x: Fe(n * o) / o || 0, @@ -7129,27 +7165,27 @@ function Va(t) { g = m.x, f = m.y; var E = i.hasOwnProperty("x"), _ = i.hasOwnProperty("y"), C = Ot, S = Ct, b = window; if (d) { - var A = Pn(n), z = "clientHeight", H = "clientWidth"; - if (A === Mt(n) && (A = le(n), te(A).position !== "static" && l === "absolute" && (z = "scrollHeight", H = "scrollWidth")), A = A, o === Ct || (o === Ot || o === zt) && a === Nn) { + var I = Pn(n), z = "clientHeight", H = "clientWidth"; + if (I === Mt(n) && (I = le(n), te(I).position !== "static" && l === "absolute" && (z = "scrollHeight", H = "scrollWidth")), I = I, o === Ct || (o === Ot || o === zt) && a === Nn) { S = Vt; - var O = h && A === b && b.visualViewport ? b.visualViewport.height : ( + var O = h && I === b && b.visualViewport ? b.visualViewport.height : ( // $FlowFixMe[prop-missing] - A[z] + I[z] ); f -= O - r.height, f *= c ? 1 : -1; } if (o === Ot || (o === Ct || o === Vt) && a === Nn) { C = zt; - var $ = h && A === b && b.visualViewport ? b.visualViewport.width : ( + var $ = h && I === b && b.visualViewport ? b.visualViewport.width : ( // $FlowFixMe[prop-missing] - A[H] + I[H] ); g -= $ - r.width, g *= c ? 1 : -1; } } var k = Object.assign({ position: l - }, d && xf), B = p === !0 ? Nf({ + }, d && yf), B = p === !0 ? xf({ x: g, y: f }, Mt(n)) : { @@ -7162,7 +7198,7 @@ function Va(t) { } return Object.assign({}, k, (e = {}, e[S] = _ ? f + "px" : "", e[C] = E ? g + "px" : "", e.transform = "", e)); } -function kf(t) { +function Nf(t) { var e = t.state, n = t.options, r = n.gpuAcceleration, o = r === void 0 ? !0 : r, a = n.adaptive, i = a === void 0 ? !0 : a, l = n.roundOffsets, c = l === void 0 ? !0 : l, d = { placement: Yt(e.placement), variation: Ge(e.placement), @@ -7185,17 +7221,17 @@ function kf(t) { "data-popper-placement": e.placement }); } -const Ef = { +const kf = { name: "computeStyles", enabled: !0, phase: "beforeWrite", - fn: kf, + fn: Nf, data: {} }; var zn = { passive: !0 }; -function Sf(t) { +function Ef(t) { var e = t.state, n = t.instance, r = t.options, o = r.scroll, a = o === void 0 ? !0 : o, i = r.resize, l = i === void 0 ? !0 : i, c = Mt(e.elements.popper), d = [].concat(e.scrollParents.reference, e.scrollParents.popper); return a && d.forEach(function(p) { p.addEventListener("scroll", n.update, zn); @@ -7205,16 +7241,16 @@ function Sf(t) { }), l && c.removeEventListener("resize", n.update, zn); }; } -const Tf = { +const Sf = { name: "eventListeners", enabled: !0, phase: "write", fn: function() { }, - effect: Sf, + effect: Ef, data: {} }; -var Cf = { +var Tf = { left: "right", right: "left", bottom: "top", @@ -7222,16 +7258,16 @@ var Cf = { }; function Xn(t) { return t.replace(/left|right|bottom|top/g, function(e) { - return Cf[e]; + return Tf[e]; }); } -var Of = { +var Cf = { start: "end", end: "start" }; function za(t) { return t.replace(/start|end/g, function(e) { - return Of[e]; + return Cf[e]; }); } function Do(t) { @@ -7244,11 +7280,11 @@ function Do(t) { function Bo(t) { return Ue(le(t)).left + Do(t).scrollLeft; } -function Rf(t, e) { +function Of(t, e) { var n = Mt(t), r = le(t), o = n.visualViewport, a = r.clientWidth, i = r.clientHeight, l = 0, c = 0; if (o) { a = o.width, i = o.height; - var d = Es(); + var d = Ts(); (d || !d && e === "fixed") && (l = o.offsetLeft, c = o.offsetTop); } return { @@ -7258,7 +7294,7 @@ function Rf(t, e) { y: c }; } -function _f(t) { +function Rf(t) { var e, n = le(t), r = Do(t), o = (e = t.ownerDocument) == null ? void 0 : e.body, a = ve(n.scrollWidth, n.clientWidth, o ? o.scrollWidth : 0, o ? o.clientWidth : 0), i = ve(n.scrollHeight, n.clientHeight, o ? o.scrollHeight : 0, o ? o.clientHeight : 0), l = -r.scrollLeft + Bo(t), c = -r.scrollTop; return te(o || n).direction === "rtl" && (l += ve(n.clientWidth, o ? o.clientWidth : 0) - a), { width: a, @@ -7271,13 +7307,13 @@ function jo(t) { var e = te(t), n = e.overflow, r = e.overflowX, o = e.overflowY; return /auto|scroll|overlay|hidden/.test(n + o + r); } -function Rs(t) { - return ["html", "body", "#document"].indexOf(qt(t)) >= 0 ? t.ownerDocument.body : jt(t) && jo(t) ? t : Rs(xr(t)); +function Ps(t) { + return ["html", "body", "#document"].indexOf(qt(t)) >= 0 ? t.ownerDocument.body : jt(t) && jo(t) ? t : Ps(xr(t)); } function fn(t, e) { var n; e === void 0 && (e = []); - var r = Rs(t), o = r === ((n = t.ownerDocument) == null ? void 0 : n.body), a = Mt(r), i = o ? [a].concat(a.visualViewport || [], jo(r) ? r : []) : r, l = e.concat(i); + var r = Ps(t), o = r === ((n = t.ownerDocument) == null ? void 0 : n.body), a = Mt(r), i = o ? [a].concat(a.visualViewport || [], jo(r) ? r : []) : r, l = e.concat(i); return o ? l : ( // $FlowFixMe[incompatible-call]: isBody tells us target will be an HTMLElement here l.concat(fn(xr(i))) @@ -7291,27 +7327,27 @@ function oo(t) { bottom: t.y + t.height }); } -function Pf(t, e) { +function _f(t, e) { var n = Ue(t, !1, e === "fixed"); return n.top = n.top + t.clientTop, n.left = n.left + t.clientLeft, n.bottom = n.top + t.clientHeight, n.right = n.left + t.clientWidth, n.width = t.clientWidth, n.height = t.clientHeight, n.x = n.left, n.y = n.top, n; } function La(t, e, n) { - return e === Ns ? oo(Rf(t, n)) : ke(e) ? Pf(e, n) : oo(_f(le(t))); + return e === Es ? oo(Of(t, n)) : ke(e) ? _f(e, n) : oo(Rf(le(t))); } -function $f(t) { +function Pf(t) { var e = fn(xr(t)), n = ["absolute", "fixed"].indexOf(te(t).position) >= 0, r = n && jt(t) ? Pn(t) : t; return ke(r) ? e.filter(function(o) { - return ke(o) && Ss(o, r) && qt(o) !== "body"; + return ke(o) && Cs(o, r) && qt(o) !== "body"; }) : []; } -function Af(t, e, n, r) { - var o = e === "clippingParents" ? $f(t) : [].concat(e), a = [].concat(o, [n]), i = a[0], l = a.reduce(function(c, d) { +function $f(t, e, n, r) { + var o = e === "clippingParents" ? Pf(t) : [].concat(e), a = [].concat(o, [n]), i = a[0], l = a.reduce(function(c, d) { var p = La(t, d, r); return c.top = ve(p.top, c.top), c.right = Jn(p.right, c.right), c.bottom = Jn(p.bottom, c.bottom), c.left = ve(p.left, c.left), c; }, La(t, i, r)); return l.width = l.right - l.left, l.height = l.bottom - l.top, l.x = l.left, l.y = l.top, l; } -function _s(t) { +function $s(t) { var e = t.reference, n = t.element, r = t.placement, o = r ? Yt(r) : null, a = r ? Ge(r) : null, i = e.x + e.width / 2 - n.width / 2, l = e.y + e.height / 2 - n.height / 2, c; switch (o) { case Ct: @@ -7360,12 +7396,12 @@ function _s(t) { } function kn(t, e) { e === void 0 && (e = {}); - var n = e, r = n.placement, o = r === void 0 ? t.placement : r, a = n.strategy, i = a === void 0 ? t.strategy : a, l = n.boundary, c = l === void 0 ? Zw : l, d = n.rootBoundary, p = d === void 0 ? Ns : d, h = n.elementContext, w = h === void 0 ? rn : h, g = n.altBoundary, v = g === void 0 ? !1 : g, f = n.padding, m = f === void 0 ? 0 : f, E = Cs(typeof m != "number" ? m : Os(m, _n)), _ = w === rn ? Qw : rn, C = t.rects.popper, S = t.elements[v ? _ : w], b = Af(ke(S) ? S : S.contextElement || le(t.elements.popper), c, p, i), A = Ue(t.elements.reference), z = _s({ - reference: A, + var n = e, r = n.placement, o = r === void 0 ? t.placement : r, a = n.strategy, i = a === void 0 ? t.strategy : a, l = n.boundary, c = l === void 0 ? Jw : l, d = n.rootBoundary, p = d === void 0 ? Es : d, h = n.elementContext, w = h === void 0 ? rn : h, g = n.altBoundary, v = g === void 0 ? !1 : g, f = n.padding, m = f === void 0 ? 0 : f, E = Rs(typeof m != "number" ? m : _s(m, _n)), _ = w === rn ? Zw : rn, C = t.rects.popper, S = t.elements[v ? _ : w], b = $f(ke(S) ? S : S.contextElement || le(t.elements.popper), c, p, i), I = Ue(t.elements.reference), z = $s({ + reference: I, element: C, strategy: "absolute", placement: o - }), H = oo(Object.assign({}, C, z)), O = w === rn ? H : A, $ = { + }), H = oo(Object.assign({}, C, z)), O = w === rn ? H : I, $ = { top: b.top - O.top + E.top, bottom: O.bottom - b.bottom + E.bottom, left: b.left - O.left + E.left, @@ -7382,7 +7418,7 @@ function kn(t, e) { } function If(t, e) { e === void 0 && (e = {}); - var n = e, r = n.placement, o = n.boundary, a = n.rootBoundary, i = n.padding, l = n.flipVariations, c = n.allowedAutoPlacements, d = c === void 0 ? ks : c, p = Ge(r), h = p ? l ? Ba : Ba.filter(function(v) { + var n = e, r = n.placement, o = n.boundary, a = n.rootBoundary, i = n.padding, l = n.flipVariations, c = n.allowedAutoPlacements, d = c === void 0 ? Ss : c, p = Ge(r), h = p ? l ? Ba : Ba.filter(function(v) { return Ge(v) === p; }) : _n, w = h.filter(function(v) { return d.indexOf(v) >= 0; @@ -7400,16 +7436,16 @@ function If(t, e) { return g[v] - g[f]; }); } -function Mf(t) { +function Af(t) { if (Yt(t) === $o) return []; var e = Xn(t); return [za(t), e, za(e)]; } -function Df(t) { +function Mf(t) { var e = t.state, n = t.options, r = t.name; if (!e.modifiersData[r]._skip) { - for (var o = n.mainAxis, a = o === void 0 ? !0 : o, i = n.altAxis, l = i === void 0 ? !0 : i, c = n.fallbackPlacements, d = n.padding, p = n.boundary, h = n.rootBoundary, w = n.altBoundary, g = n.flipVariations, v = g === void 0 ? !0 : g, f = n.allowedAutoPlacements, m = e.options.placement, E = Yt(m), _ = E === m, C = c || (_ || !v ? [Xn(m)] : Mf(m)), S = [m].concat(C).reduce(function(V, W) { + for (var o = n.mainAxis, a = o === void 0 ? !0 : o, i = n.altAxis, l = i === void 0 ? !0 : i, c = n.fallbackPlacements, d = n.padding, p = n.boundary, h = n.rootBoundary, w = n.altBoundary, g = n.flipVariations, v = g === void 0 ? !0 : g, f = n.allowedAutoPlacements, m = e.options.placement, E = Yt(m), _ = E === m, C = c || (_ || !v ? [Xn(m)] : Af(m)), S = [m].concat(C).reduce(function(V, W) { return V.concat(Yt(W) === $o ? If(e, { placement: W, boundary: p, @@ -7418,7 +7454,7 @@ function Df(t) { flipVariations: v, allowedAutoPlacements: f }) : W); - }, []), b = e.rects.reference, A = e.rects.popper, z = /* @__PURE__ */ new Map(), H = !0, O = S[0], $ = 0; $ < S.length; $++) { + }, []), b = e.rects.reference, I = e.rects.popper, z = /* @__PURE__ */ new Map(), H = !0, O = S[0], $ = 0; $ < S.length; $++) { var k = S[$], B = Yt(k), D = Ge(k) === Le, J = [Ct, Vt].indexOf(B) >= 0, q = J ? "width" : "height", U = kn(e, { placement: k, boundary: p, @@ -7426,7 +7462,7 @@ function Df(t) { altBoundary: w, padding: d }), tt = J ? D ? zt : Ot : D ? Vt : Ct; - b[q] > A[q] && (tt = Xn(tt)); + b[q] > I[q] && (tt = Xn(tt)); var at = Xn(tt), rt = []; if (a && rt.push(U[B] <= 0), l && rt.push(U[tt] <= 0, U[at] <= 0), rt.every(function(V) { return V; @@ -7455,11 +7491,11 @@ function Df(t) { e.placement !== O && (e.modifiersData[r]._skip = !0, e.placement = O, e.reset = !0); } } -const Bf = { +const Df = { name: "flip", enabled: !0, phase: "main", - fn: Df, + fn: Mf, requiresIfExists: ["offset"], data: { _skip: !1 @@ -7481,7 +7517,7 @@ function Ua(t) { return t[e] >= 0; }); } -function jf(t) { +function Bf(t) { var e = t.state, n = t.name, r = e.rects.reference, o = e.rects.popper, a = e.modifiersData.preventOverflow, i = kn(e, { elementContext: "reference" }), l = kn(e, { @@ -7497,14 +7533,14 @@ function jf(t) { "data-popper-escaped": h }); } -const Vf = { +const jf = { name: "hide", enabled: !0, phase: "main", requiresIfExists: ["preventOverflow"], - fn: jf + fn: Bf }; -function zf(t, e, n) { +function Vf(t, e, n) { var r = Yt(t), o = [Ot, Ct].indexOf(r) >= 0 ? -1 : 1, a = typeof n == "function" ? n(Object.assign({}, e, { placement: t })) : n, i = a[0], l = a[1]; @@ -7516,45 +7552,45 @@ function zf(t, e, n) { y: l }; } -function Lf(t) { - var e = t.state, n = t.options, r = t.name, o = n.offset, a = o === void 0 ? [0, 0] : o, i = ks.reduce(function(p, h) { - return p[h] = zf(h, e.rects, a), p; +function zf(t) { + var e = t.state, n = t.options, r = t.name, o = n.offset, a = o === void 0 ? [0, 0] : o, i = Ss.reduce(function(p, h) { + return p[h] = Vf(h, e.rects, a), p; }, {}), l = i[e.placement], c = l.x, d = l.y; e.modifiersData.popperOffsets != null && (e.modifiersData.popperOffsets.x += c, e.modifiersData.popperOffsets.y += d), e.modifiersData[r] = i; } -const Ff = { +const Lf = { name: "offset", enabled: !0, phase: "main", requires: ["popperOffsets"], - fn: Lf + fn: zf }; -function Uf(t) { +function Ff(t) { var e = t.state, n = t.name; - e.modifiersData[n] = _s({ + e.modifiersData[n] = $s({ reference: e.rects.reference, element: e.rects.popper, strategy: "absolute", placement: e.placement }); } -const Gf = { +const Uf = { name: "popperOffsets", enabled: !0, phase: "read", - fn: Uf, + fn: Ff, data: {} }; -function Hf(t) { +function Gf(t) { return t === "x" ? "y" : "x"; } -function Xf(t) { +function Hf(t) { var e = t.state, n = t.options, r = t.name, o = n.mainAxis, a = o === void 0 ? !0 : o, i = n.altAxis, l = i === void 0 ? !1 : i, c = n.boundary, d = n.rootBoundary, p = n.altBoundary, h = n.padding, w = n.tether, g = w === void 0 ? !0 : w, v = n.tetherOffset, f = v === void 0 ? 0 : v, m = kn(e, { boundary: c, rootBoundary: d, padding: h, altBoundary: p - }), E = Yt(e.placement), _ = Ge(e.placement), C = !_, S = Mo(E), b = Hf(S), A = e.modifiersData.popperOffsets, z = e.rects.reference, H = e.rects.popper, O = typeof f == "function" ? f(Object.assign({}, e.rects, { + }), E = Yt(e.placement), _ = Ge(e.placement), C = !_, S = Mo(E), b = Gf(S), I = e.modifiersData.popperOffsets, z = e.rects.reference, H = e.rects.popper, O = typeof f == "function" ? f(Object.assign({}, e.rects, { placement: e.placement })) : f, $ = typeof O == "number" ? { mainAxis: O, @@ -7566,44 +7602,44 @@ function Xf(t) { x: 0, y: 0 }; - if (A) { + if (I) { if (a) { - var D, J = S === "y" ? Ct : Ot, q = S === "y" ? Vt : zt, U = S === "y" ? "height" : "width", tt = A[S], at = tt + m[J], rt = tt - m[q], y = g ? -H[U] / 2 : 0, R = _ === Le ? z[U] : H[U], L = _ === Le ? -H[U] : -z[U], F = e.elements.arrow, V = g && F ? Io(F) : { + var D, J = S === "y" ? Ct : Ot, q = S === "y" ? Vt : zt, U = S === "y" ? "height" : "width", tt = I[S], at = tt + m[J], rt = tt - m[q], y = g ? -H[U] / 2 : 0, R = _ === Le ? z[U] : H[U], L = _ === Le ? -H[U] : -z[U], F = e.elements.arrow, V = g && F ? Ao(F) : { width: 0, height: 0 - }, W = e.modifiersData["arrow#persistent"] ? e.modifiersData["arrow#persistent"].padding : Ts(), X = W[J], Y = W[q], G = wn(0, z[U], V[U]), K = C ? z[U] / 2 - y - G - X - $.mainAxis : R - G - X - $.mainAxis, Z = C ? -z[U] / 2 + y + G + Y + $.mainAxis : L + G + Y + $.mainAxis, dt = e.elements.arrow && Pn(e.elements.arrow), I = dt ? S === "y" ? dt.clientTop || 0 : dt.clientLeft || 0 : 0, Nt = (D = k == null ? void 0 : k[S]) != null ? D : 0, j = tt + K - Nt - I, xt = tt + Z - Nt, Ft = wn(g ? Jn(at, j) : at, tt, g ? ve(rt, xt) : rt); - A[S] = Ft, B[S] = Ft - tt; + }, W = e.modifiersData["arrow#persistent"] ? e.modifiersData["arrow#persistent"].padding : Os(), X = W[J], Y = W[q], G = wn(0, z[U], V[U]), K = C ? z[U] / 2 - y - G - X - $.mainAxis : R - G - X - $.mainAxis, Z = C ? -z[U] / 2 + y + G + Y + $.mainAxis : L + G + Y + $.mainAxis, dt = e.elements.arrow && Pn(e.elements.arrow), A = dt ? S === "y" ? dt.clientTop || 0 : dt.clientLeft || 0 : 0, Nt = (D = k == null ? void 0 : k[S]) != null ? D : 0, j = tt + K - Nt - A, xt = tt + Z - Nt, Ft = wn(g ? Jn(at, j) : at, tt, g ? ve(rt, xt) : rt); + I[S] = Ft, B[S] = Ft - tt; } if (l) { - var ce, Et = S === "x" ? Ct : Ot, An = S === "x" ? Vt : zt, Ut = A[b], Ee = b === "y" ? "height" : "width", de = Ut + m[Et], Se = Ut - m[An], Te = [Ct, Ot].indexOf(E) !== -1, Ce = (ce = k == null ? void 0 : k[b]) != null ? ce : 0, pe = Te ? de : Ut - z[Ee] - H[Ee] - Ce + $.altAxis, qe = Te ? Ut + z[Ee] + H[Ee] - Ce - $.altAxis : Se, In = g && Te ? hf(pe, Ut, qe) : wn(g ? pe : de, Ut, g ? qe : Se); - A[b] = In, B[b] = In - Ut; + var ce, St = S === "x" ? Ct : Ot, In = S === "x" ? Vt : zt, Ut = I[b], Ee = b === "y" ? "height" : "width", de = Ut + m[St], Se = Ut - m[In], Te = [Ct, Ot].indexOf(E) !== -1, Ce = (ce = k == null ? void 0 : k[b]) != null ? ce : 0, pe = Te ? de : Ut - z[Ee] - H[Ee] - Ce + $.altAxis, qe = Te ? Ut + z[Ee] + H[Ee] - Ce - $.altAxis : Se, An = g && Te ? mf(pe, Ut, qe) : wn(g ? pe : de, Ut, g ? qe : Se); + I[b] = An, B[b] = An - Ut; } e.modifiersData[r] = B; } } -const Yf = { +const Xf = { name: "preventOverflow", enabled: !0, phase: "main", - fn: Xf, + fn: Hf, requiresIfExists: ["offset"] }; -function Wf(t) { +function Yf(t) { return { scrollLeft: t.scrollLeft, scrollTop: t.scrollTop }; } -function qf(t) { - return t === Mt(t) || !jt(t) ? Do(t) : Wf(t); +function Wf(t) { + return t === Mt(t) || !jt(t) ? Do(t) : Yf(t); } -function Kf(t) { +function qf(t) { var e = t.getBoundingClientRect(), n = Fe(e.width) / t.offsetWidth || 1, r = Fe(e.height) / t.offsetHeight || 1; return n !== 1 || r !== 1; } -function Jf(t, e, n) { +function Kf(t, e, n) { n === void 0 && (n = !1); - var r = jt(e), o = jt(e) && Kf(e), a = le(e), i = Ue(t, o, n), l = { + var r = jt(e), o = jt(e) && qf(e), a = le(e), i = Ue(t, o, n), l = { scrollLeft: 0, scrollTop: 0 }, c = { @@ -7611,14 +7647,14 @@ function Jf(t, e, n) { y: 0 }; return (r || !r && !n) && ((qt(e) !== "body" || // https://github.com/popperjs/popper-core/issues/1078 - jo(a)) && (l = qf(e)), jt(e) ? (c = Ue(e, !0), c.x += e.clientLeft, c.y += e.clientTop) : a && (c.x = Bo(a))), { + jo(a)) && (l = Wf(e)), jt(e) ? (c = Ue(e, !0), c.x += e.clientLeft, c.y += e.clientTop) : a && (c.x = Bo(a))), { x: i.left + l.scrollLeft - c.x, y: i.top + l.scrollTop - c.y, width: i.width, height: i.height }; } -function Zf(t) { +function Jf(t) { var e = /* @__PURE__ */ new Map(), n = /* @__PURE__ */ new Set(), r = []; t.forEach(function(a) { e.set(a.name, a); @@ -7637,15 +7673,15 @@ function Zf(t) { n.has(a.name) || o(a); }), r; } -function Qf(t) { - var e = Zf(t); - return df.reduce(function(n, r) { +function Zf(t) { + var e = Jf(t); + return cf.reduce(function(n, r) { return n.concat(e.filter(function(o) { return o.phase === r; })); }, []); } -function tm(t) { +function Qf(t) { var e; return function() { return e || (e = new Promise(function(n) { @@ -7655,7 +7691,7 @@ function tm(t) { })), e; }; } -function em(t) { +function tm(t) { var e = t.reduce(function(n, r) { var o = n[r.name]; return n[r.name] = o ? Object.assign({}, o, r, { @@ -7679,7 +7715,7 @@ function Ha() { return !(r && typeof r.getBoundingClientRect == "function"); }); } -function nm(t) { +function em(t) { t === void 0 && (t = {}); var e = t, n = e.defaultModifiers, r = n === void 0 ? [] : n, o = e.defaultOptions, a = o === void 0 ? Ga : o; return function(l, c, d) { @@ -7703,7 +7739,7 @@ function nm(t) { reference: ke(l) ? fn(l) : l.contextElement ? fn(l.contextElement) : [], popper: fn(c) }; - var C = Qf(em([].concat(r, p.options.modifiers))); + var C = Zf(tm([].concat(r, p.options.modifiers))); return p.orderedModifiers = C.filter(function(S) { return S.enabled; }), v(), g.update(); @@ -7718,8 +7754,8 @@ function nm(t) { var E = p.elements, _ = E.reference, C = E.popper; if (Ha(_, C)) { p.rects = { - reference: Jf(_, Pn(C), p.options.strategy === "fixed"), - popper: Io(C) + reference: Kf(_, Pn(C), p.options.strategy === "fixed"), + popper: Ao(C) }, p.reset = !1, p.placement = p.options.placement, p.orderedModifiers.forEach(function($) { return p.modifiersData[$.name] = Object.assign({}, $.data); }); @@ -7728,8 +7764,8 @@ function nm(t) { p.reset = !1, S = -1; continue; } - var b = p.orderedModifiers[S], A = b.fn, z = b.options, H = z === void 0 ? {} : z, O = b.name; - typeof A == "function" && (p = A({ + var b = p.orderedModifiers[S], I = b.fn, z = b.options, H = z === void 0 ? {} : z, O = b.name; + typeof I == "function" && (p = I({ state: p, options: H, name: O, @@ -7741,7 +7777,7 @@ function nm(t) { }, // Async and optimistically optimized update – it will not be executed if // not necessary (debounced to run at most once-per-tick) - update: tm(function() { + update: Qf(function() { return new Promise(function(m) { g.forceUpdate(), m(p); }); @@ -7764,9 +7800,9 @@ function nm(t) { name: E, instance: g, options: C - }), A = function() { + }), I = function() { }; - h.push(b || A); + h.push(b || I); } }); } @@ -7778,16 +7814,16 @@ function nm(t) { return g; }; } -var rm = [Tf, Gf, Ef, wf, Ff, Bf, Yf, yf, Vf], om = /* @__PURE__ */ nm({ - defaultModifiers: rm +var nm = [Sf, Uf, kf, uf, Lf, Df, Xf, vf, jf], rm = /* @__PURE__ */ em({ + defaultModifiers: nm }); -const Ps = "Popper"; -function am(t) { - return xs(Ps, t); +const Is = "Popper"; +function om(t) { + return ks(Is, t); } -Kw(Ps, ["root"]); -const im = ["anchorEl", "children", "direction", "disablePortal", "modifiers", "open", "placement", "popperOptions", "popperRef", "slotProps", "slots", "TransitionProps", "ownerState"], sm = ["anchorEl", "children", "container", "direction", "disablePortal", "keepMounted", "modifiers", "open", "placement", "popperOptions", "popperRef", "style", "transition", "slotProps", "slots"]; -function lm(t, e) { +qw(Is, ["root"]); +const am = ["anchorEl", "children", "direction", "disablePortal", "modifiers", "open", "placement", "popperOptions", "popperRef", "slotProps", "slots", "TransitionProps", "ownerState"], im = ["anchorEl", "children", "container", "direction", "disablePortal", "keepMounted", "modifiers", "open", "placement", "popperOptions", "popperRef", "style", "transition", "slotProps", "slots"]; +function sm(t, e) { if (e === "ltr") return t; switch (t) { @@ -7809,12 +7845,12 @@ function Zn(t) { function Nr(t) { return t.nodeType !== void 0; } -function cm(t) { +function lm(t) { return !Nr(t); } -const dm = () => xo({ +const cm = () => xo({ root: ["root"] -}, Fw(am)), pm = {}, um = /* @__PURE__ */ M.forwardRef(function(e, n) { +}, Lw(om)), dm = {}, pm = /* @__PURE__ */ M.forwardRef(function(e, n) { var r; const { anchorEl: o, @@ -7831,11 +7867,11 @@ const dm = () => xo({ TransitionProps: f // @ts-ignore internal logic // prevent from spreading to DOM, it can come from the parent component e.g. Select. - } = e, m = kt(e, im), E = M.useRef(null), _ = xe(E, n), C = M.useRef(null), S = xe(C, w), b = M.useRef(S); + } = e, m = kt(e, am), E = M.useRef(null), _ = xe(E, n), C = M.useRef(null), S = xe(C, w), b = M.useRef(S); ze(() => { b.current = S; }, [S]), M.useImperativeHandle(w, () => C.current, []); - const A = lm(p, i), [z, H] = M.useState(A), [O, $] = M.useState(Zn(o)); + const I = sm(p, i), [z, H] = M.useState(I), [O, $] = M.useState(Zn(o)); M.useEffect(() => { C.current && C.current.forceUpdate(); }), M.useEffect(() => { @@ -7872,20 +7908,20 @@ const dm = () => xo({ } }]; c != null && (U = U.concat(c)), h && h.modifiers != null && (U = U.concat(h.modifiers)); - const tt = om(O, E.current, P({ - placement: A + const tt = rm(O, E.current, P({ + placement: I }, h, { modifiers: U })); return b.current(tt), () => { tt.destroy(), b.current(null); }; - }, [O, l, c, d, h, A]); + }, [O, l, c, d, h, I]); const k = { placement: z }; f !== null && (k.TransitionProps = f); - const B = dm(), D = (r = v.root) != null ? r : "div", J = Yw({ + const B = cm(), D = (r = v.root) != null ? r : "div", J = Xw({ elementType: D, externalSlotProps: g.root, externalForwardedProps: m, @@ -7899,7 +7935,7 @@ const dm = () => xo({ return /* @__PURE__ */ s(D, P({}, J, { children: typeof a == "function" ? a(k) : a })); -}), $s = /* @__PURE__ */ M.forwardRef(function(e, n) { +}), As = /* @__PURE__ */ M.forwardRef(function(e, n) { const { anchorEl: r, children: o, @@ -7910,15 +7946,15 @@ const dm = () => xo({ modifiers: d, open: p, placement: h = "bottom", - popperOptions: w = pm, + popperOptions: w = dm, popperRef: g, style: v, transition: f = !1, slotProps: m = {}, slots: E = {} - } = e, _ = kt(e, sm), [C, S] = M.useState(!0), b = () => { + } = e, _ = kt(e, im), [C, S] = M.useState(!0), b = () => { S(!1); - }, A = () => { + }, I = () => { S(!0); }; if (!c && !p && (!f || C)) @@ -7933,12 +7969,12 @@ const dm = () => xo({ const H = !p && c && (!f || C) ? "none" : void 0, O = f ? { in: p, onEnter: b, - onExited: A + onExited: I } : void 0; return /* @__PURE__ */ s(Kn, { disablePortal: l, container: z, - children: /* @__PURE__ */ s(um, P({ + children: /* @__PURE__ */ s(pm, P({ anchorEl: r, direction: i, disablePortal: l, @@ -7964,7 +8000,7 @@ const dm = () => xo({ })) }); }); -process.env.NODE_ENV !== "production" && ($s.propTypes = { +process.env.NODE_ENV !== "production" && (As.propTypes = { // ┌────────────────────────────── Warning ──────────────────────────────┐ // │ These PropTypes are generated from the TypeScript type definitions. │ // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │ @@ -7983,7 +8019,7 @@ process.env.NODE_ENV !== "production" && ($s.propTypes = { if (process.env.NODE_ENV !== "test" && n.top === 0 && n.left === 0 && n.right === 0 && n.bottom === 0) return new Error(["MUI: The `anchorEl` prop provided to the component is invalid.", "The anchor element should be part of the document layout.", "Make sure the element is present in the document or that it's not display none."].join(` `)); - } else if (!e || typeof e.getBoundingClientRect != "function" || cm(e) && e.contextElement != null && e.contextElement.nodeType !== 1) + } else if (!e || typeof e.getBoundingClientRect != "function" || lm(e) && e.contextElement != null && e.contextElement.nodeType !== 1) return new Error(["MUI: The `anchorEl` prop provided to the component is invalid.", "It should be an HTML element instance or a virtualElement ", "(https://popper.js.org/docs/v2/virtual-elements/)."].join(` `)); } @@ -8063,7 +8099,7 @@ process.env.NODE_ENV !== "production" && ($s.propTypes = { /** * A ref that points to the used popper instance. */ - popperRef: os, + popperRef: is, /** * The props used for each slot inside the Popper. * @default {} @@ -8085,8 +8121,8 @@ process.env.NODE_ENV !== "production" && ($s.propTypes = { */ transition: u.bool }); -function As() { - const t = hs(Oo); +function Ms() { + const t = bs(Oo); return process.env.NODE_ENV !== "production" && M.useDebugValue(t), t[Ro] || t; } function ao(t, e) { @@ -8094,13 +8130,13 @@ function ao(t, e) { return r.__proto__ = o, r; }, ao(t, e); } -function wm(t, e) { +function um(t, e) { t.prototype = Object.create(e.prototype), t.prototype.constructor = t, ao(t, e); } const Xa = { disabled: !1 }; -var fm = process.env.NODE_ENV !== "production" ? u.oneOfType([u.number, u.shape({ +var wm = process.env.NODE_ENV !== "production" ? u.oneOfType([u.number, u.shape({ enter: u.number, exit: u.number, appear: u.number @@ -8117,16 +8153,16 @@ process.env.NODE_ENV !== "production" && u.oneOfType([u.string, u.shape({ exitDone: u.string, exitActive: u.string })]); -const Is = T.createContext(null); -var mm = function(e) { +const Ds = T.createContext(null); +var fm = function(e) { return e.scrollTop; -}, cn = "unmounted", fe = "exited", me = "entering", Ie = "entered", io = "exiting", ee = /* @__PURE__ */ function(t) { - wm(e, t); +}, cn = "unmounted", fe = "exited", me = "entering", Ae = "entered", io = "exiting", ee = /* @__PURE__ */ function(t) { + um(e, t); function e(r, o) { var a; a = t.call(this, r, o) || this; var i = o, l = i && !i.isMounting ? r.enter : r.appear, c; - return a.appearStatus = null, r.in ? l ? (c = fe, a.appearStatus = me) : c = Ie : r.unmountOnExit || r.mountOnEnter ? c = cn : c = fe, a.state = { + return a.appearStatus = null, r.in ? l ? (c = fe, a.appearStatus = me) : c = Ae : r.unmountOnExit || r.mountOnEnter ? c = cn : c = fe, a.state = { status: c }, a.nextCallback = null, a; } @@ -8143,7 +8179,7 @@ var mm = function(e) { var a = null; if (o !== this.props) { var i = this.state.status; - this.props.in ? i !== me && i !== Ie && (a = me) : (i === me || i === Ie) && (a = io); + this.props.in ? i !== me && i !== Ae && (a = me) : (i === me || i === Ae) && (a = io); } this.updateStatus(!1, a); }, n.componentWillUnmount = function() { @@ -8160,7 +8196,7 @@ var mm = function(e) { if (this.cancelNextCallback(), a === me) { if (this.props.unmountOnExit || this.props.mountOnEnter) { var i = this.props.nodeRef ? this.props.nodeRef.current : Bn.findDOMNode(this); - i && mm(i); + i && fm(i); } this.performEnter(o); } else @@ -8173,7 +8209,7 @@ var mm = function(e) { var a = this, i = this.props.enter, l = this.context ? this.context.isMounting : o, c = this.props.nodeRef ? [l] : [Bn.findDOMNode(this), l], d = c[0], p = c[1], h = this.getTimeouts(), w = l ? h.appear : h.enter; if (!o && !i || Xa.disabled) { this.safeSetState({ - status: Ie + status: Ae }, function() { a.props.onEntered(d); }); @@ -8184,7 +8220,7 @@ var mm = function(e) { }, function() { a.props.onEntering(d, p), a.onTransitionEnd(w, function() { a.safeSetState({ - status: Ie + status: Ae }, function() { a.props.onEntered(d, p); }); @@ -8243,13 +8279,13 @@ var mm = function(e) { var l = kt(a, ["children", "in", "mountOnEnter", "unmountOnExit", "appear", "enter", "exit", "timeout", "addEndListener", "onEnter", "onEntering", "onEntered", "onExit", "onExiting", "onExited", "nodeRef"]); return ( // allows for nested Transitions - /* @__PURE__ */ T.createElement(Is.Provider, { + /* @__PURE__ */ T.createElement(Ds.Provider, { value: null }, typeof i == "function" ? i(o, l) : T.cloneElement(T.Children.only(i), l)) ); }, e; }(T.Component); -ee.contextType = Is; +ee.contextType = Ds; ee.propTypes = process.env.NODE_ENV !== "production" ? { /** * A React reference to DOM element that need to transition: @@ -8346,7 +8382,7 @@ ee.propTypes = process.env.NODE_ENV !== "production" ? { * @type {number | { enter?: number, exit?: number, appear?: number }} */ timeout: function(e) { - var n = fm; + var n = wm; e.addEndListener || (n = n.isRequired); for (var r = arguments.length, o = new Array(r > 1 ? r - 1 : 0), a = 1; a < r; a++) o[a - 1] = arguments[a]; @@ -8419,7 +8455,7 @@ ee.propTypes = process.env.NODE_ENV !== "production" ? { */ onExited: u.func } : {}; -function Ae() { +function Ie() { } ee.defaultProps = { in: !1, @@ -8428,19 +8464,19 @@ ee.defaultProps = { appear: !1, enter: !0, exit: !0, - onEnter: Ae, - onEntering: Ae, - onEntered: Ae, - onExit: Ae, - onExiting: Ae, - onExited: Ae + onEnter: Ie, + onEntering: Ie, + onEntered: Ie, + onExit: Ie, + onExiting: Ie, + onExited: Ie }; ee.UNMOUNTED = cn; ee.EXITED = fe; ee.ENTERING = me; -ee.ENTERED = Ie; +ee.ENTERED = Ae; ee.EXITING = io; -const hm = ee, gm = (t) => t.scrollTop; +const mm = ee, hm = (t) => t.scrollTop; function Ya(t, e) { var n, r; const { @@ -8454,11 +8490,11 @@ function Ya(t, e) { delay: i.transitionDelay }; } -const bm = ["addEndListener", "appear", "children", "easing", "in", "onEnter", "onEntered", "onEntering", "onExit", "onExited", "onExiting", "style", "timeout", "TransitionComponent"]; +const gm = ["addEndListener", "appear", "children", "easing", "in", "onEnter", "onEntered", "onEntering", "onExit", "onExited", "onExiting", "style", "timeout", "TransitionComponent"]; function so(t) { return `scale(${t}, ${t ** 2})`; } -const vm = { +const bm = { entering: { opacity: 1, transform: so(1) @@ -8483,14 +8519,14 @@ const vm = { style: v, timeout: f = "auto", // eslint-disable-next-line react/prop-types - TransitionComponent: m = hm - } = e, E = kt(e, bm), _ = sn(), C = M.useRef(), S = As(), b = M.useRef(null), A = xe(b, a.ref, n), z = (q) => (U) => { + TransitionComponent: m = mm + } = e, E = kt(e, gm), _ = sn(), C = M.useRef(), S = Ms(), b = M.useRef(null), I = xe(b, a.ref, n), z = (q) => (U) => { if (q) { const tt = b.current; U === void 0 ? q(tt) : q(tt, U); } }, H = z(p), O = z((q, U) => { - gm(q); + hm(q); const { duration: tt, delay: at, @@ -8553,8 +8589,8 @@ const vm = { opacity: 0, transform: so(0.75), visibility: q === "exited" && !l ? "hidden" : void 0 - }, vm[q], v, a.props.style), - ref: A + }, bm[q], v, a.props.style), + ref: I }, U)) })); }); @@ -8578,7 +8614,7 @@ process.env.NODE_ENV !== "production" && (Vo.propTypes = { /** * A single child content element. */ - children: ns.isRequired, + children: os.isRequired, /** * The transition timing function. * You may specify a single easing or a object containing enter and exit values. @@ -8633,13 +8669,13 @@ process.env.NODE_ENV !== "production" && (Vo.propTypes = { })]) }); Vo.muiSupportAuto = !0; -const Wa = Vo, ym = ["anchorEl", "component", "components", "componentsProps", "container", "disablePortal", "keepMounted", "modifiers", "open", "placement", "popperOptions", "popperRef", "transition", "slots", "slotProps"], xm = Rn($s, { +const Wa = Vo, vm = ["anchorEl", "component", "components", "componentsProps", "container", "disablePortal", "keepMounted", "modifiers", "open", "placement", "popperOptions", "popperRef", "transition", "slots", "slotProps"], ym = Rn(As, { name: "MuiPopper", slot: "Root", overridesResolver: (t, e) => e.root -})({}), Ms = /* @__PURE__ */ M.forwardRef(function(e, n) { +})({}), Bs = /* @__PURE__ */ M.forwardRef(function(e, n) { var r; - const o = ms(), a = _o({ + const o = gs(), a = _o({ props: e, name: "MuiPopper" }), { @@ -8658,7 +8694,7 @@ const Wa = Vo, ym = ["anchorEl", "component", "components", "componentsProps", " transition: _, slots: C, slotProps: S - } = a, b = kt(a, ym), A = (r = C == null ? void 0 : C.root) != null ? r : c == null ? void 0 : c.Root, z = P({ + } = a, b = kt(a, vm), I = (r = C == null ? void 0 : C.root) != null ? r : c == null ? void 0 : c.Root, z = P({ anchorEl: i, container: p, disablePortal: h, @@ -8670,18 +8706,18 @@ const Wa = Vo, ym = ["anchorEl", "component", "components", "componentsProps", " popperRef: E, transition: _ }, b); - return /* @__PURE__ */ s(xm, P({ + return /* @__PURE__ */ s(ym, P({ as: l, direction: o == null ? void 0 : o.direction, slots: { - root: A + root: I }, slotProps: S ?? d }, z, { ref: n })); }); -process.env.NODE_ENV !== "production" && (Ms.propTypes = { +process.env.NODE_ENV !== "production" && (Bs.propTypes = { // ┌────────────────────────────── Warning ──────────────────────────────┐ // │ These PropTypes are generated from the TypeScript type definitions. │ // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │ @@ -8782,7 +8818,7 @@ process.env.NODE_ENV !== "production" && (Ms.propTypes = { /** * A ref that points to the used popper instance. */ - popperRef: os, + popperRef: is, /** * The props used for each slot inside the Popper. * @default {} @@ -8808,15 +8844,15 @@ process.env.NODE_ENV !== "production" && (Ms.propTypes = { */ transition: u.bool }); -const Ds = Ms; -function Nm(t) { +const js = Bs; +function xm(t) { return pr("MuiTooltip", t); } -const km = ps("MuiTooltip", ["popper", "popperInteractive", "popperArrow", "popperClose", "tooltip", "tooltipArrow", "touch", "tooltipPlacementLeft", "tooltipPlacementRight", "tooltipPlacementTop", "tooltipPlacementBottom", "arrow"]), re = km, Em = ["arrow", "children", "classes", "components", "componentsProps", "describeChild", "disableFocusListener", "disableHoverListener", "disableInteractive", "disableTouchListener", "enterDelay", "enterNextDelay", "enterTouchDelay", "followCursor", "id", "leaveDelay", "leaveTouchDelay", "onClose", "onOpen", "open", "placement", "PopperComponent", "PopperProps", "slotProps", "slots", "title", "TransitionComponent", "TransitionProps"]; -function Sm(t) { +const Nm = ws("MuiTooltip", ["popper", "popperInteractive", "popperArrow", "popperClose", "tooltip", "tooltipArrow", "touch", "tooltipPlacementLeft", "tooltipPlacementRight", "tooltipPlacementTop", "tooltipPlacementBottom", "arrow"]), re = Nm, km = ["arrow", "children", "classes", "components", "componentsProps", "describeChild", "disableFocusListener", "disableHoverListener", "disableInteractive", "disableTouchListener", "enterDelay", "enterNextDelay", "enterTouchDelay", "followCursor", "id", "leaveDelay", "leaveTouchDelay", "onClose", "onOpen", "open", "placement", "PopperComponent", "PopperProps", "slotProps", "slots", "title", "TransitionComponent", "TransitionProps"]; +function Em(t) { return Math.round(t * 1e5) / 1e5; } -const Tm = (t) => { +const Sm = (t) => { const { classes: e, disableInteractive: n, @@ -8828,8 +8864,8 @@ const Tm = (t) => { tooltip: ["tooltip", r && "tooltipArrow", o && "touch", `tooltipPlacement${Wt(a.split("-")[0])}`], arrow: ["arrow"] }; - return xo(i, Nm, e); -}, Cm = Rn(Ds, { + return xo(i, xm, e); +}, Tm = Rn(js, { name: "MuiTooltip", slot: "Popper", overridesResolver: (t, e) => { @@ -8890,7 +8926,7 @@ const Tm = (t) => { transformOrigin: "0 0" } }) -})), Om = Rn("div", { +})), Cm = Rn("div", { name: "MuiTooltip", slot: "Tooltip", overridesResolver: (t, e) => { @@ -8903,7 +8939,7 @@ const Tm = (t) => { theme: t, ownerState: e }) => P({ - backgroundColor: t.vars ? t.vars.palette.Tooltip.bg : gs(t.palette.grey[700], 0.92), + backgroundColor: t.vars ? t.vars.palette.Tooltip.bg : vs(t.palette.grey[700], 0.92), borderRadius: (t.vars || t).shape.borderRadius, color: (t.vars || t).palette.common.white, fontFamily: t.typography.fontFamily, @@ -8919,7 +8955,7 @@ const Tm = (t) => { }, e.touch && { padding: "8px 16px", fontSize: t.typography.pxToRem(14), - lineHeight: `${Sm(16 / 14)}em`, + lineHeight: `${Em(16 / 14)}em`, fontWeight: t.typography.fontWeightRegular }, { [`.${re.popper}[data-popper-placement*="left"] &`]: P({ @@ -8956,7 +8992,7 @@ const Tm = (t) => { }, e.touch && { marginTop: "24px" }) -})), Rm = Rn("span", { +})), Om = Rn("span", { name: "MuiTooltip", slot: "Arrow", overridesResolver: (t, e) => e.arrow @@ -8968,7 +9004,7 @@ const Tm = (t) => { width: "1em", height: "0.71em", boxSizing: "border-box", - color: t.vars ? t.vars.palette.Tooltip.bg : gs(t.palette.grey[700], 0.9), + color: t.vars ? t.vars.palette.Tooltip.bg : vs(t.palette.grey[700], 0.9), "&::before": { content: '""', margin: "auto", @@ -8990,9 +9026,9 @@ function Fn(t, e) { e && e(n), t(n); }; } -const Bs = /* @__PURE__ */ M.forwardRef(function(e, n) { +const Vs = /* @__PURE__ */ M.forwardRef(function(e, n) { var r, o, a, i, l, c, d, p, h, w, g, v, f, m, E, _, C, S, b; - const A = _o({ + const I = _o({ props: e, name: "MuiTooltip" }), { @@ -9021,27 +9057,27 @@ const Bs = /* @__PURE__ */ M.forwardRef(function(e, n) { slotProps: K = {}, slots: Z = {}, title: dt, - TransitionComponent: I = Wa, + TransitionComponent: A = Wa, TransitionProps: Nt - } = A, j = kt(A, Em), xt = /* @__PURE__ */ M.isValidElement(H) ? H : /* @__PURE__ */ s("span", { + } = I, j = kt(I, km), xt = /* @__PURE__ */ M.isValidElement(H) ? H : /* @__PURE__ */ s("span", { children: H - }), Ft = As(), ce = Ft.direction === "rtl", [Et, An] = M.useState(), [Ut, Ee] = M.useState(null), de = M.useRef(!1), Se = J || rt, Te = sn(), Ce = sn(), pe = sn(), qe = sn(), [In, zo] = is({ + }), Ft = Ms(), ce = Ft.direction === "rtl", [St, In] = M.useState(), [Ut, Ee] = M.useState(null), de = M.useRef(!1), Se = J || rt, Te = sn(), Ce = sn(), pe = sn(), qe = sn(), [An, zo] = ls({ controlled: W, default: !1, name: "Tooltip", state: "open" }); - let Kt = In; + let Kt = An; if (process.env.NODE_ENV !== "production") { const { current: Q } = M.useRef(W !== void 0); M.useEffect(() => { - Et && Et.disabled && !Q && dt !== "" && Et.tagName.toLowerCase() === "button" && console.error(["MUI: You are providing a disabled `button` child to the Tooltip component.", "A disabled element does not fire events.", "Tooltip needs to listen to the child element's events to display the title.", "", "Add a simple wrapper element, such as a `span`."].join(` + St && St.disabled && !Q && dt !== "" && St.tagName.toLowerCase() === "button" && console.error(["MUI: You are providing a disabled `button` child to the Tooltip component.", "A disabled element does not fire events.", "Tooltip needs to listen to the child element's events to display the title.", "", "Add a simple wrapper element, such as a `span`."].join(` `)); - }, [dt, Et, Q]); + }, [dt, St, Q]); } - const kr = as(y), Ke = M.useRef(), Mn = eo(() => { + const kr = ss(y), Ke = M.useRef(), Mn = eo(() => { Ke.current !== void 0 && (document.body.style.WebkitUserSelect = Ke.current, Ke.current = void 0), qe.clear(); }); M.useEffect(() => Mn, [Mn]); @@ -9059,7 +9095,7 @@ const Bs = /* @__PURE__ */ M.forwardRef(function(e, n) { }); } ), Er = (Q) => { - de.current && Q.type !== "touchstart" || (Et && Et.removeAttribute("title"), Ce.clear(), pe.clear(), U || Ln && tt ? Ce.start(Ln ? tt : U, () => { + de.current && Q.type !== "touchstart" || (St && St.removeAttribute("title"), Ce.clear(), pe.clear(), U || Ln && tt ? Ce.start(Ln ? tt : U, () => { Lo(Q); }) : Lo(Q)); }, Fo = (Q) => { @@ -9068,22 +9104,22 @@ const Bs = /* @__PURE__ */ M.forwardRef(function(e, n) { }); }, { isFocusVisibleRef: Uo, - onBlur: Ls, - onFocus: Fs, - ref: Us - } = ss(), [, Go] = M.useState(!1), Ho = (Q) => { - Ls(Q), Uo.current === !1 && (Go(!1), Fo(Q)); + onBlur: Us, + onFocus: Gs, + ref: Hs + } = cs(), [, Go] = M.useState(!1), Ho = (Q) => { + Us(Q), Uo.current === !1 && (Go(!1), Fo(Q)); }, Xo = (Q) => { - Et || An(Q.currentTarget), Fs(Q), Uo.current === !0 && (Go(!0), Er(Q)); + St || In(Q.currentTarget), Gs(Q), Uo.current === !0 && (Go(!0), Er(Q)); }, Yo = (Q) => { de.current = !0; const Pt = xt.props; Pt.onTouchStart && Pt.onTouchStart(Q); - }, Wo = Er, qo = Fo, Gs = (Q) => { + }, Wo = Er, qo = Fo, Xs = (Q) => { Yo(Q), pe.clear(), Te.clear(), Mn(), Ke.current = document.body.style.WebkitUserSelect, document.body.style.WebkitUserSelect = "none", qe.start(at, () => { document.body.style.WebkitUserSelect = Ke.current, Er(Q); }); - }, Hs = (Q) => { + }, Ys = (Q) => { xt.props.onTouchEnd && xt.props.onTouchEnd(Q), Mn(), pe.start(L, () => { Dn(Q); }); @@ -9098,9 +9134,9 @@ const Bs = /* @__PURE__ */ M.forwardRef(function(e, n) { document.removeEventListener("keydown", Q); }; }, [Dn, Kt]); - const Xs = xe(xt.ref, Us, An, n); + const Ws = xe(xt.ref, Hs, In, n); !dt && dt !== 0 && (Kt = !1); - const Sr = M.useRef(), Ys = (Q) => { + const Sr = M.useRef(), qs = (Q) => { const Pt = xt.props; Pt.onMouseMove && Pt.onMouseMove(Q), on = { x: Q.clientX, @@ -9111,18 +9147,18 @@ const Bs = /* @__PURE__ */ M.forwardRef(function(e, n) { const Dt = P({}, Je, j, xt.props, { className: be(j.className, xt.props.className), onTouchStart: Yo, - ref: Xs + ref: Ws }, rt ? { - onMouseMove: Ys + onMouseMove: qs } : {}); process.env.NODE_ENV !== "production" && (Dt["data-mui-internal-clone-element"] = !0, M.useEffect(() => { - Et && !Et.getAttribute("data-mui-internal-clone-element") && console.error(["MUI: The `children` component of the Tooltip is not forwarding its props correctly.", "Please make sure that props are spread on the same element that the ref is applied to."].join(` + St && !St.getAttribute("data-mui-internal-clone-element") && console.error(["MUI: The `children` component of the Tooltip is not forwarding its props correctly.", "Please make sure that props are spread on the same element that the ref is applied to."].join(` `)); - }, [Et])); + }, [St])); const Ze = {}; - q || (Dt.onTouchStart = Gs, Dt.onTouchEnd = Hs), D || (Dt.onMouseOver = Fn(Wo, Dt.onMouseOver), Dt.onMouseLeave = Fn(qo, Dt.onMouseLeave), Se || (Ze.onMouseOver = Wo, Ze.onMouseLeave = qo)), B || (Dt.onFocus = Fn(Xo, Dt.onFocus), Dt.onBlur = Fn(Ho, Dt.onBlur), Se || (Ze.onFocus = Xo, Ze.onBlur = Ho)), process.env.NODE_ENV !== "production" && xt.props.title && console.error(["MUI: You have provided a `title` prop to the child of .", `Remove this title prop \`${xt.props.title}\` or the Tooltip component.`].join(` + q || (Dt.onTouchStart = Xs, Dt.onTouchEnd = Ys), D || (Dt.onMouseOver = Fn(Wo, Dt.onMouseOver), Dt.onMouseLeave = Fn(qo, Dt.onMouseLeave), Se || (Ze.onMouseOver = Wo, Ze.onMouseLeave = qo)), B || (Dt.onFocus = Fn(Xo, Dt.onFocus), Dt.onBlur = Fn(Ho, Dt.onBlur), Se || (Ze.onFocus = Xo, Ze.onBlur = Ho)), process.env.NODE_ENV !== "production" && xt.props.title && console.error(["MUI: You have provided a `title` prop to the child of .", `Remove this title prop \`${xt.props.title}\` or the Tooltip component.`].join(` `)); - const Ws = M.useMemo(() => { + const Ks = M.useMemo(() => { var Q; let Pt = [{ name: "arrow", @@ -9135,23 +9171,23 @@ const Bs = /* @__PURE__ */ M.forwardRef(function(e, n) { return (Q = G.popperOptions) != null && Q.modifiers && (Pt = Pt.concat(G.popperOptions.modifiers)), P({}, G.popperOptions, { modifiers: Pt }); - }, [Ut, G]), Qe = P({}, A, { + }, [Ut, G]), Qe = P({}, I, { isRtl: ce, arrow: z, disableInteractive: Se, placement: X, PopperComponentProp: Y, touch: de.current - }), Cr = Tm(Qe), Ko = (r = (o = Z.popper) != null ? o : O.Popper) != null ? r : Cm, Jo = (a = (i = (l = Z.transition) != null ? l : O.Transition) != null ? i : I) != null ? a : Wa, Zo = (c = (d = Z.tooltip) != null ? d : O.Tooltip) != null ? c : Om, Qo = (p = (h = Z.arrow) != null ? h : O.Arrow) != null ? p : Rm, qs = ln(Ko, P({}, G, (w = K.popper) != null ? w : $.popper, { + }), Cr = Sm(Qe), Ko = (r = (o = Z.popper) != null ? o : O.Popper) != null ? r : Tm, Jo = (a = (i = (l = Z.transition) != null ? l : O.Transition) != null ? i : A) != null ? a : Wa, Zo = (c = (d = Z.tooltip) != null ? d : O.Tooltip) != null ? c : Cm, Qo = (p = (h = Z.arrow) != null ? h : O.Arrow) != null ? p : Om, Js = ln(Ko, P({}, G, (w = K.popper) != null ? w : $.popper, { className: be(Cr.popper, G == null ? void 0 : G.className, (g = (v = K.popper) != null ? v : $.popper) == null ? void 0 : g.className) - }), Qe), Ks = ln(Jo, P({}, Nt, (f = K.transition) != null ? f : $.transition), Qe), Js = ln(Zo, P({}, (m = K.tooltip) != null ? m : $.tooltip, { + }), Qe), Zs = ln(Jo, P({}, Nt, (f = K.transition) != null ? f : $.transition), Qe), Qs = ln(Zo, P({}, (m = K.tooltip) != null ? m : $.tooltip, { className: be(Cr.tooltip, (E = (_ = K.tooltip) != null ? _ : $.tooltip) == null ? void 0 : E.className) - }), Qe), Zs = ln(Qo, P({}, (C = K.arrow) != null ? C : $.arrow, { + }), Qe), tl = ln(Qo, P({}, (C = K.arrow) != null ? C : $.arrow, { className: be(Cr.arrow, (S = (b = K.arrow) != null ? b : $.arrow) == null ? void 0 : S.className) }), Qe); return /* @__PURE__ */ x(M.Fragment, { children: [/* @__PURE__ */ M.cloneElement(xt, Dt), /* @__PURE__ */ s(Ko, P({ - as: Y ?? Ds, + as: Y ?? js, placement: X, anchorEl: rt ? { getBoundingClientRect: () => ({ @@ -9162,20 +9198,20 @@ const Bs = /* @__PURE__ */ M.forwardRef(function(e, n) { width: 0, height: 0 }) - } : Et, + } : St, popperRef: Sr, - open: Et ? Kt : !1, + open: St ? Kt : !1, id: kr, transition: !0 - }, Ze, qs, { - popperOptions: Ws, + }, Ze, Js, { + popperOptions: Ks, children: ({ TransitionProps: Q }) => /* @__PURE__ */ s(Jo, P({ timeout: Ft.transitions.duration.shorter - }, Q, Ks, { - children: /* @__PURE__ */ x(Zo, P({}, Js, { - children: [dt, z ? /* @__PURE__ */ s(Qo, P({}, Zs, { + }, Q, Zs, { + children: /* @__PURE__ */ x(Zo, P({}, Qs, { + children: [dt, z ? /* @__PURE__ */ s(Qo, P({}, tl, { ref: Ee })) : null] })) @@ -9183,7 +9219,7 @@ const Bs = /* @__PURE__ */ M.forwardRef(function(e, n) { }))] }); }); -process.env.NODE_ENV !== "production" && (Bs.propTypes = { +process.env.NODE_ENV !== "production" && (Vs.propTypes = { // ┌────────────────────────────── Warning ──────────────────────────────┐ // │ These PropTypes are generated from the TypeScript type definitions. │ // │ To update them, edit the d.ts file and run `pnpm proptypes`. │ @@ -9196,7 +9232,7 @@ process.env.NODE_ENV !== "production" && (Bs.propTypes = { /** * Tooltip reference element. */ - children: ns.isRequired, + children: os.isRequired, /** * Override or extend the styles applied to the component. */ @@ -9376,11 +9412,11 @@ process.env.NODE_ENV !== "production" && (Bs.propTypes = { */ TransitionProps: u.object }); -const _m = Bs; +const Rm = Vs; function Ka(t, e, n) { return t ? /* @__PURE__ */ s(ii, { className: `papi-menu-icon-${n ? "leading" : "trailing"}`, children: /* @__PURE__ */ s("img", { src: t, alt: `${n ? "Leading" : "Trailing"} icon for ${e}` }) }) : void 0; } -function js(t) { +function zs(t) { const { onClick: e, label: n, @@ -9399,7 +9435,7 @@ function js(t) { id: f, children: m } = t, E = /* @__PURE__ */ s( - jl, + Fl, { sx: { lineHeight: 0.8 }, autoFocus: l, @@ -9413,33 +9449,33 @@ function js(t) { id: f, children: n ? /* @__PURE__ */ x(ie, { children: [ Ka(a, n, !0), - /* @__PURE__ */ s(Vl, { primary: n, inset: !a && o }), - h ? /* @__PURE__ */ s(ii, { className: "papi-menu-icon-trailing", children: /* @__PURE__ */ s(vs, {}) }) : Ka(i, n, !1) + /* @__PURE__ */ s(Ul, { primary: n, inset: !a && o }), + h ? /* @__PURE__ */ s(ii, { className: "papi-menu-icon-trailing", children: /* @__PURE__ */ s(xs, {}) }) : Ka(i, n, !1) ] }) : m } ); - return r ? /* @__PURE__ */ s(_m, { title: r, placement: "right", children: /* @__PURE__ */ s("div", { children: E }) }) : E; + return r ? /* @__PURE__ */ s(Rm, { title: r, placement: "right", children: /* @__PURE__ */ s("div", { children: E }) }) : E; } -function Vs(t) { +function Ls(t) { return Object.entries(t.groups).map(([n, r]) => ({ id: n, group: r })); } -function Pm(t) { +function _m(t) { const [e, n] = ut(void 0), { parentMenuItem: r, parentItemProps: o, menuDefinition: a } = t, i = (d) => { n(d.currentTarget); }, l = () => { n(void 0); }, c = () => { - let d = Vs(a).filter((p) => "menuItem" in p.group); + let d = Ls(a).filter((p) => "menuItem" in p.group); if (!(r != null && r.id)) throw new Error("A valid parent menu item is required for submenus."); return d = d.filter( (p) => "menuItem" in p.group && p.group.menuItem === r.id - ), /* @__PURE__ */ s(zs, { ...t, includedGroups: d }); + ), /* @__PURE__ */ s(Fs, { ...t, includedGroups: d }); }; return /* @__PURE__ */ x(ie, { children: [ - /* @__PURE__ */ s(js, { onClick: i, ...o, isSubMenuParent: !0 }), + /* @__PURE__ */ s(zs, { onClick: i, ...o, isSubMenuParent: !0 }), /* @__PURE__ */ s( - zl, + Gl, { anchorEl: e, open: !!e, @@ -9458,18 +9494,18 @@ function Pm(t) { ) ] }); } -const $m = (t, e) => e.filter((o) => o.group === t).sort((o, a) => (o.order || 0) - (a.order || 0)); -function zs(t) { - const { menuDefinition: e, onClick: n, commandHandler: r, includedGroups: o } = t, { items: a, allowForLeadingIcons: i } = At(() => { +const Pm = (t, e) => e.filter((o) => o.group === t).sort((o, a) => (o.order || 0) - (a.order || 0)); +function Fs(t) { + const { menuDefinition: e, onClick: n, commandHandler: r, includedGroups: o } = t, { items: a, allowForLeadingIcons: i } = It(() => { const p = o && o.length > 0 ? o : ( // We're apparently laying out a single-column menu (presumably a context menu). In this // case, all groups should be included except ones that belong to a submenu. - Vs(e).filter((v) => !("menuItem" in v.group)) + Ls(e).filter((v) => !("menuItem" in v.group)) ), h = Object.values(p).sort( (v, f) => (v.group.order || 0) - (f.group.order || 0) ), w = []; h.forEach((v) => { - $m(v.id, e.items).forEach( + Pm(v.id, e.items).forEach( (f) => w.push({ item: f, isLastItemInGroup: !1 }) ), w.length > 0 && (w[w.length - 1].isLastItemInGroup = !0); }), w.length > 0 && (w[w.length - 1].isLastItemInGroup = !1); @@ -9495,7 +9531,7 @@ function zs(t) { if ("command" in w) { const v = w.group + h; return /* @__PURE__ */ s( - js, + zs, { onClick: (f) => { n == null || n(f), r(w); @@ -9506,7 +9542,7 @@ function zs(t) { ); } return /* @__PURE__ */ s( - Pm, + _m, { parentMenuItem: w, parentItemProps: g, @@ -9516,14 +9552,14 @@ function zs(t) { ); }) }, d); } -function Am(t) { +function $m(t) { const { menuDefinition: e, columnId: n } = t; let a = Object.entries(e.groups).map(([i, l]) => ({ id: i, group: l })).filter((i) => "column" in i.group); return n && "columns" in e && // Without this type assertion, TS doesn't know what columns is. // eslint-disable-next-line no-type-assertion/no-type-assertion e.columns[n] && (a = a.filter( (i) => "column" in i.group && i.group.column === n - )), /* @__PURE__ */ s(zs, { ...t, includedGroups: a }); + )), /* @__PURE__ */ s(Fs, { ...t, includedGroups: a }); } function Im({ commandHandler: t, @@ -9544,8 +9580,8 @@ function Im({ className: `papi-menu-column ${a ?? ""}`, children: [ /* @__PURE__ */ s("h3", { "aria-label": r.label, className: `papi-menu-column-header ${a ?? ""}`, children: r.label }), - /* @__PURE__ */ s(Ll, { id: n, dense: !0, className: a ?? "", children: /* @__PURE__ */ s( - Am, + /* @__PURE__ */ s(Hl, { id: n, dense: !0, className: a ?? "", children: /* @__PURE__ */ s( + $m, { commandHandler: t, menuDefinition: e, @@ -9557,13 +9593,13 @@ function Im({ } ); } -function Mm({ +function Am({ commandHandler: t, className: e, multiColumnMenu: n, id: r }) { - const { columns: o } = n, a = At(() => { + const { columns: o } = n, a = It(() => { const i = /* @__PURE__ */ new Map(); return Object.getOwnPropertyNames(o).forEach((l) => { if (l === "isExtensible") @@ -9597,7 +9633,7 @@ function Mm({ } ); } -function Dm(t) { +function Mm(t) { return { preserveValue: !0, ...t @@ -9607,7 +9643,7 @@ const lo = (t, e, n = {}) => { const r = ge(e); r.current = e; const o = ge(n); - o.current = Dm(o.current); + o.current = Mm(o.current); const [a, i] = ut(() => r.current), [l, c] = ut(!0); return ae(() => { let d = !0; @@ -9620,10 +9656,10 @@ const lo = (t, e, n = {}) => { d = !1, o.current.preserveValue || i(() => r.current); }; }, [t]), [a, l]; -}, Bm = bs(/* @__PURE__ */ s("path", { +}, Dm = ys(/* @__PURE__ */ s("path", { d: "M3 18h18v-2H3zm0-5h18v-2H3zm0-7v2h18V6z" }), "Menu"); -function jm({ +function Bm({ menuProvider: t, normalMenu: e, fullMenu: n, @@ -9633,14 +9669,14 @@ function jm({ ariaLabelPrefix: i, children: l }) { - const [c, d] = ut(!1), [p, h] = ut(!1), w = Tt(() => { + const [c, d] = ut(!1), [p, h] = ut(!1), w = Et(() => { c && d(!1), h(!1); - }, [c]), g = Tt((S) => { + }, [c]), g = Et((S) => { S.stopPropagation(), d((b) => { - const A = !b; - return A && S.shiftKey ? h(!0) : A || h(!1), A; + const I = !b; + return I && S.shiftKey ? h(!0) : I || h(!1), I; }); - }, []), v = Tt( + }, []), v = Et( (S) => (w(), r(S)), [r, w] ), [f, m] = ut({ top: 1, left: 1 }); @@ -9648,16 +9684,16 @@ function jm({ if (c) { const S = o == null ? void 0 : o.current; if (S) { - const b = S.getBoundingClientRect(), A = window.scrollY, z = window.scrollX, H = b.top + A + S.clientHeight, O = b.left + z; + const b = S.getBoundingClientRect(), I = window.scrollY, z = window.scrollX, H = b.top + I + S.clientHeight, O = b.left + z; m({ top: H, left: O }); } } }, [c, o]); const [E] = lo( - Tt(async () => (t == null ? void 0 : t(!1)) ?? e, [t, e, c]), + Et(async () => (t == null ? void 0 : t(!1)) ?? e, [t, e, c]), e ), [_] = lo( - Tt(async () => (t == null ? void 0 : t(!0)) ?? n ?? E, [t, n, E, c]), + Et(async () => (t == null ? void 0 : t(!0)) ?? n ?? E, [t, n, E, c]), n ?? E ), C = p && _ ? _ : E; return /* @__PURE__ */ x(ie, { children: [ @@ -9673,11 +9709,11 @@ function jm({ color: "inherit", "aria-label": `${i ?? ""} menu button`, onClick: g, - children: l ?? /* @__PURE__ */ s(Bm, {}) + children: l ?? /* @__PURE__ */ s(Dm, {}) } ), /* @__PURE__ */ s( - Fl, + Xl, { className: `papi-menu-drawer ${a ?? ""}`, anchor: "left", @@ -9692,7 +9728,7 @@ function jm({ } }, children: C ? /* @__PURE__ */ s( - Mm, + Am, { className: a, id: `${i ?? ""} main menu`, @@ -9704,7 +9740,7 @@ function jm({ ) ] }); } -function Mh({ +function Ah({ id: t, label: e, isDisabled: n = !1, @@ -9731,9 +9767,9 @@ function Mh({ } ); } -const $n = Qn(({ className: t, ...e }, n) => /* @__PURE__ */ s(yl, { size: 35, className: N("tw-animate-spin", t), ...e, ref: n })); +const $n = Qn(({ className: t, ...e }, n) => /* @__PURE__ */ s(Nl, { size: 35, className: N("tw-animate-spin", t), ...e, ref: n })); $n.displayName = "Spinner"; -function Dh({ +function Mh({ id: t, isDisabled: e = !1, hasError: n = !1, @@ -9779,7 +9815,7 @@ function Dh({ /* @__PURE__ */ s("p", { className: N({ "tw-hidden": !o }), children: o }) ] }); } -function Bh({ +function Dh({ menuProvider: t, commandHandler: e, className: n, @@ -9787,14 +9823,14 @@ function Bh({ children: o }) { const a = ge(void 0); - return /* @__PURE__ */ s("div", { ref: a, style: { position: "relative" }, children: /* @__PURE__ */ s(Ul, { position: "static", id: r, children: /* @__PURE__ */ x( - Gl, + return /* @__PURE__ */ s("div", { ref: a, style: { position: "relative" }, children: /* @__PURE__ */ s(Yl, { position: "static", id: r, children: /* @__PURE__ */ x( + Wl, { className: N("tw-bg-muted tw-text-muted-foreground", n), variant: "dense", children: [ t ? /* @__PURE__ */ s( - jm, + Bm, { commandHandler: e, containerRef: a, @@ -9806,7 +9842,7 @@ function Bh({ } ) }) }); } -const Vm = Xe( +const jm = Xe( "tw-relative tw-w-full tw-rounded-lg tw-border tw-p-4 [&>svg~*]:tw-pl-7 [&>svg+div]:tw-translate-y-[-3px] [&>svg]:tw-absolute [&>svg]:tw-left-4 [&>svg]:tw-top-4 [&>svg]:tw-text-foreground", { variants: { @@ -9819,9 +9855,9 @@ const Vm = Xe( variant: "default" } } -), zm = T.forwardRef(({ className: t, variant: e, ...n }, r) => /* @__PURE__ */ s("div", { ref: r, role: "alert", className: N(Vm({ variant: e }), t), ...n })); -zm.displayName = "Alert"; -const Lm = T.forwardRef( +), Vm = T.forwardRef(({ className: t, variant: e, ...n }, r) => /* @__PURE__ */ s("div", { ref: r, role: "alert", className: N(jm({ variant: e }), t), ...n })); +Vm.displayName = "Alert"; +const zm = T.forwardRef( ({ className: t, ...e }, n) => /* @__PURE__ */ x( "h5", { @@ -9835,12 +9871,12 @@ const Lm = T.forwardRef( } ) ); -Lm.displayName = "AlertTitle"; -const Fm = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s("div", { ref: n, className: N("tw-text-sm [&_p]:tw-leading-relaxed", t), ...e })); -Fm.displayName = "AlertDescription"; -function jh({ ...t }) { +zm.displayName = "AlertTitle"; +const Lm = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s("div", { ref: n, className: N("tw-text-sm [&_p]:tw-leading-relaxed", t), ...e })); +Lm.displayName = "AlertDescription"; +function Bh({ ...t }) { return /* @__PURE__ */ s( - ql, + Kl, { className: "tw-toaster tw-group", toastOptions: { @@ -9855,7 +9891,7 @@ function jh({ ...t }) { } ); } -const Um = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ x( +const Fm = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ x( an.Root, { ref: n, @@ -9870,8 +9906,8 @@ const Um = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ x( ] } )); -Um.displayName = an.Root.displayName; -const Gm = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( +Fm.displayName = an.Root.displayName; +const Um = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( Yr.Root, { className: N( @@ -9890,8 +9926,8 @@ const Gm = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( ) } )); -Gm.displayName = Yr.Root.displayName; -const Vh = _t.Root, Hm = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( +Um.displayName = Yr.Root.displayName; +const jh = _t.Root, Gm = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( _t.List, { ref: n, @@ -9902,8 +9938,8 @@ const Vh = _t.Root, Hm = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE_ ...e } )); -Hm.displayName = _t.List.displayName; -const Xm = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( +Gm.displayName = _t.List.displayName; +const Hm = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( _t.Trigger, { ref: n, @@ -9914,8 +9950,8 @@ const Xm = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( ...e } )); -Xm.displayName = _t.Trigger.displayName; -const Ym = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( +Hm.displayName = _t.Trigger.displayName; +const Xm = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( _t.Content, { ref: n, @@ -9926,8 +9962,8 @@ const Ym = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( ...e } )); -Ym.displayName = _t.Content.displayName; -function zh({ +Xm.displayName = _t.Content.displayName; +function Vh({ isInstalling: t, handleClick: e, buttonText: n, @@ -9950,13 +9986,13 @@ function zh({ onClick: e, ...o, children: t ? /* @__PURE__ */ s($n, { size: 15 }) : /* @__PURE__ */ x(ie, { children: [ - /* @__PURE__ */ s(xl, { size: 25, className: N("tw-h-4 tw-w-4", { "tw-mr-1": n }) }), + /* @__PURE__ */ s(kl, { size: 25, className: N("tw-h-4 tw-w-4", { "tw-mr-1": n }) }), n ] }) } ); } -function Lh({ +function zh({ isEnabling: t, handleClick: e, className: n, @@ -9981,7 +10017,7 @@ function Lh({ } ); } -function Fh({ +function Lh({ isDisabling: t, handleClick: e, className: n, @@ -10006,7 +10042,7 @@ function Fh({ } ); } -function Uh({ +function Fh({ isUpdating: t, handleClick: e, className: n, @@ -10031,13 +10067,13 @@ function Uh({ } ); } -function Gh({ +function Uh({ id: t, markdown: e, className: n, anchorTarget: r }) { - const o = At( + const o = It( () => ({ overrides: { a: { @@ -10049,16 +10085,16 @@ function Gh({ }), [r] ); - return /* @__PURE__ */ s("div", { id: t, className: N("pr-twp tw-prose", n), children: /* @__PURE__ */ s(Kl, { options: o, children: e }) }); + return /* @__PURE__ */ s("div", { id: t, className: N("pr-twp tw-prose", n), children: /* @__PURE__ */ s(Jl, { options: o, children: e }) }); } -const Wm = Qn((t, e) => /* @__PURE__ */ x( +const Ym = Qn((t, e) => /* @__PURE__ */ x( gt, { ref: e, className: "tw-rounded-md tw-border tw-border-dashed tw-border-gray-400 tw-bg-white tw-px-4 tw-py-2 tw-text-black tw-transition tw-duration-300 tw-ease-in-out hover:tw-border-blue-600 hover:tw-bg-white hover:tw-text-blue-600", ...t, children: [ - /* @__PURE__ */ s(Nl, { size: 16, className: "tw-mr-2 tw-h-4 tw-w-4 tw-text-gray-700 hover:tw-text-blue-600" }), + /* @__PURE__ */ s(El, { size: 16, className: "tw-mr-2 tw-h-4 tw-w-4 tw-text-gray-700 hover:tw-text-blue-600" }), "Filter", /* @__PURE__ */ s( er, @@ -10070,28 +10106,28 @@ const Wm = Qn((t, e) => /* @__PURE__ */ x( ] } )); -var qm = /* @__PURE__ */ ((t) => (t[t.Check = 0] = "Check", t[t.Radio = 1] = "Radio", t))(qm || {}); -function Hh({ id: t, groups: e }) { +var Wm = /* @__PURE__ */ ((t) => (t[t.Check = 0] = "Check", t[t.Radio = 1] = "Radio", t))(Wm || {}); +function Gh({ id: t, groups: e }) { return /* @__PURE__ */ s("div", { id: t, children: /* @__PURE__ */ x(fo, { children: [ - /* @__PURE__ */ s(mi, { asChild: !0, children: /* @__PURE__ */ s(Wm, {}) }), + /* @__PURE__ */ s(mi, { asChild: !0, children: /* @__PURE__ */ s(Ym, {}) }), /* @__PURE__ */ s(rr, { children: e.map((n) => /* @__PURE__ */ x("div", { children: [ /* @__PURE__ */ s(Sn, { children: n.label }), - /* @__PURE__ */ s(pc, { children: n.items.map((r) => /* @__PURE__ */ s("div", { children: r.itemType === 0 ? /* @__PURE__ */ s(mo, { onClick: r.onClick, children: r.label }) : /* @__PURE__ */ s(gi, { onClick: r.onClick, value: r.label, children: r.label }) }, r.label)) }), + /* @__PURE__ */ s(uc, { children: n.items.map((r) => /* @__PURE__ */ s("div", { children: r.itemType === 0 ? /* @__PURE__ */ s(mo, { onClick: r.onClick, children: r.label }) : /* @__PURE__ */ s(gi, { onClick: r.onClick, value: r.label, children: r.label }) }, r.label)) }), /* @__PURE__ */ s(or, {}) ] }, n.label)) }) ] }) }); } -function Xh({ id: t, message: e }) { +function Hh({ id: t, message: e }) { return /* @__PURE__ */ s("div", { id: t, className: "tw-mb-20 tw-mt-20 tw-flex tw-items-center tw-justify-center", children: /* @__PURE__ */ s("div", { className: "tw-w-3/4 tw-rounded-lg tw-bg-gray-100 tw-p-8 tw-text-center", children: /* @__PURE__ */ s("p", { className: "tw-text-lg tw-text-gray-800", children: e }) }) }); } -function Yh({ +function Xh({ id: t, category: e, downloads: n, languages: r, moreInfoUrl: o }) { - const a = new Pl("en", { + const a = new Il("en", { notation: "compact", compactDisplay: "short" }).format(Object.values(n).reduce((l, c) => l + c, 0)), i = () => { @@ -10110,7 +10146,7 @@ function Yh({ /* @__PURE__ */ s("div", { className: "tw-mx-2 tw-h-10 tw-border-l tw-border-gray-300" }), /* @__PURE__ */ x("div", { className: "tw-flex tw-flex-col tw-items-center", children: [ /* @__PURE__ */ x("div", { className: "tw-flex tw-items-center tw-rounded-md tw-bg-gray-100 tw-px-2 tw-py-1", children: [ - /* @__PURE__ */ s(kl, { className: "tw-mr-1 tw-h-4 tw-w-4" }), + /* @__PURE__ */ s(Sl, { className: "tw-mr-1 tw-h-4 tw-w-4" }), /* @__PURE__ */ s("span", { className: "tw-text-xs tw-font-semibold tw-text-gray-700", children: a }) ] }), /* @__PURE__ */ s("span", { className: "tw-text-xs tw-text-gray-500", children: "USERS" }) @@ -10150,7 +10186,7 @@ function Yh({ className: "tw-flex tw-items-center tw-text-xs tw-font-semibold tw-text-gray-500 tw-underline", children: [ "Website", - /* @__PURE__ */ s(El, { className: "tw-ml-1 tw-inline tw-h-4 tw-w-4" }) + /* @__PURE__ */ s(Tl, { className: "tw-ml-1 tw-inline tw-h-4 tw-w-4" }) ] } ), @@ -10163,7 +10199,7 @@ function Yh({ className: "tw-flex tw-items-center tw-text-xs tw-font-semibold tw-text-gray-500 tw-underline", children: [ "Support", - /* @__PURE__ */ s(Sl, { className: "tw-ml-1 tw-inline tw-h-4 tw-w-4" }) + /* @__PURE__ */ s(Cl, { className: "tw-ml-1 tw-inline tw-h-4 tw-w-4" }) ] } ) @@ -10172,7 +10208,7 @@ function Yh({ } ); } -function Km({ id: t, versionHistory: e }) { +function qm({ id: t, versionHistory: e }) { const [n, r] = ut(!1), o = /* @__PURE__ */ new Date(); function a(l) { const c = new Date(l), d = new Date(o.getTime() - c.getTime()), p = d.getUTCFullYear() - 1970, h = d.getUTCMonth(), w = d.getUTCDate() - 1; @@ -10203,19 +10239,19 @@ function Km({ id: t, versionHistory: e }) { ) ] }); } -function Wh({ +function Yh({ id: t, publisherDisplayName: e, fileSize: n, locales: r, versionHistory: o }) { - const a = At(() => $l(n), [n]), l = ((c) => { + const a = It(() => Al(n), [n]), l = ((c) => { const d = new Intl.DisplayNames(navigator.language, { type: "language" }); return c.map((p) => d.of(p)); })(r); return /* @__PURE__ */ s("div", { id: t, className: "tw-border-t tw-pb-4 tw-pt-4", children: /* @__PURE__ */ x("div", { className: "tw-md:flex-row tw-md:space-x-8 tw-flex tw-flex-col tw-space-x-0", children: [ - /* @__PURE__ */ s(Km, { versionHistory: o }), + /* @__PURE__ */ s(qm, { versionHistory: o }), /* @__PURE__ */ s("div", { className: "tw-md:border-t-0 tw-md:border-l tw-md-h-auto tw-md-ml-8 tw-mt-4 tw-border-t tw-border-gray-300" }), /* @__PURE__ */ x("div", { className: "tw-md:mt-0 tw-mt-4 tw-flex-1 tw-space-y-3", children: [ /* @__PURE__ */ s("h2", { className: "tw-text-md tw-font-semibold", children: "Information" }), @@ -10234,7 +10270,7 @@ function Wh({ ] }) ] }) }); } -const qh = (t, e) => { +const Wh = (t, e) => { ae(() => { if (!t) return () => { @@ -10244,9 +10280,9 @@ const qh = (t, e) => { n(); }; }, [t, e]); -}, Gr = () => !1, Kh = (t, e) => { +}, Gr = () => !1, qh = (t, e) => { const [n] = lo( - Tt(async () => { + Et(async () => { if (!t) return Gr; const r = await Promise.resolve(t(e)); @@ -10261,13 +10297,13 @@ const qh = (t, e) => { n !== Gr && n(); }, [n]); }; -function Jm(t, e = "top") { +function Km(t, e = "top") { if (!t || typeof document > "u") return; const n = document.head || document.querySelector("head"), r = n.querySelector(":first-child"), o = document.createElement("style"); o.appendChild(document.createTextNode(t)), e === "top" && r ? n.insertBefore(o, r) : n.appendChild(o); } -Jm(`*, ::before, ::after { +Km(`*, ::before, ::after { --tw-border-spacing-x: 0; --tw-border-spacing-y: 0; --tw-translate-x: 0; @@ -11686,6 +11722,12 @@ video:where(.pr-twp,.pr-twp *) { .tw-w-9 { width: 2.25rem; } +.tw-w-9\\/12 { + width: 75%; +} +.tw-w-96 { + width: 24rem; +} .tw-w-\\[--sidebar-width\\] { width: var(--sidebar-width); } @@ -12001,6 +12043,9 @@ video:where(.pr-twp,.pr-twp *) { .tw-break-words { overflow-wrap: break-word; } +.tw-rounded { + border-radius: 0.25rem; +} .tw-rounded-full { border-radius: 9999px; } @@ -12223,6 +12268,10 @@ video:where(.pr-twp,.pr-twp *) { .tw-bg-sidebar-border { background-color: hsl(var(--sidebar-border)); } +.tw-bg-slate-100 { + --tw-bg-opacity: 1; + background-color: rgb(241 245 249 / var(--tw-bg-opacity)); +} .tw-bg-transparent { background-color: transparent; } @@ -12242,6 +12291,9 @@ video:where(.pr-twp,.pr-twp *) { .tw-p-2 { padding: 0.5rem; } +.tw-p-3 { + padding: 0.75rem; +} .tw-p-4 { padding: 1rem; } @@ -12330,6 +12382,9 @@ video:where(.pr-twp,.pr-twp *) { .tw-pe-2 { padding-inline-end: 0.5rem; } +.tw-pl-3 { + padding-left: 0.75rem; +} .tw-pl-4 { padding-left: 1rem; } @@ -12485,6 +12540,10 @@ video:where(.pr-twp,.pr-twp *) { .tw-text-foreground\\/80 { color: hsl(var(--foreground) / 0.8); } +.tw-text-gray-400 { + --tw-text-opacity: 1; + color: rgb(156 163 175 / var(--tw-text-opacity)); +} .tw-text-gray-500 { --tw-text-opacity: 1; color: rgb(107 114 128 / var(--tw-text-opacity)); @@ -12501,6 +12560,10 @@ video:where(.pr-twp,.pr-twp *) { --tw-text-opacity: 1; color: rgb(31 41 55 / var(--tw-text-opacity)); } +.tw-text-gray-900 { + --tw-text-opacity: 1; + color: rgb(17 24 39 / var(--tw-text-opacity)); +} .tw-text-inherit { color: inherit; } @@ -12826,6 +12889,11 @@ video:where(.pr-twp,.pr-twp *) { color: hsl(var(--foreground)); } +.hover\\:tw-text-gray-900:hover { + --tw-text-opacity: 1; + color: rgb(17 24 39 / var(--tw-text-opacity)); +} + .hover\\:tw-text-muted-foreground:hover { color: hsl(var(--muted-foreground)); } @@ -12853,6 +12921,12 @@ video:where(.pr-twp,.pr-twp *) { box-shadow: var(--tw-ring-offset-shadow, 0 0 #0000), var(--tw-ring-shadow, 0 0 #0000), var(--tw-shadow); } +.hover\\:tw-shadow-sm:hover { + --tw-shadow: 0 1px 2px 0 rgb(0 0 0 / 0.05); + --tw-shadow-colored: 0 1px 2px 0 var(--tw-shadow-color); + box-shadow: var(--tw-ring-offset-shadow, 0 0 #0000), var(--tw-ring-shadow, 0 0 #0000), var(--tw-shadow); +} + .hover\\:after\\:tw-bg-sidebar-border:hover::after { content: var(--tw-content); background-color: hsl(var(--sidebar-border)); @@ -12921,6 +12995,11 @@ video:where(.pr-twp,.pr-twp *) { background-color: hsl(var(--sidebar-accent)); } +.active\\:tw-bg-white:active { + --tw-bg-opacity: 1; + background-color: rgb(255 255 255 / var(--tw-bg-opacity)); +} + .active\\:tw-text-sidebar-accent-foreground:active { color: hsl(var(--sidebar-accent-foreground)); } @@ -13746,31 +13825,12 @@ video:where(.pr-twp,.pr-twp *) { [data-side=right] .\\[\\[data-side\\=right\\]_\\&\\]\\:tw-cursor-e-resize { cursor: e-resize; } -.papi-icon-button { - border: 0; - border-radius: 3em; +.banded-row:hover { cursor: pointer; - display: inline-block; -} - -.papi-icon-button.primary { - background-color: #1ea7fd; - color: white; -} - -.papi-icon-button.secondary { - background-color: transparent; - color: #333; -} - -.papi-icon-button.paratext { - background-color: darkgreen; - color: greenyellow; } -.papi-icon-button.paratext.bright { - background-color: greenyellow; - color: darkgreen; +.banded-row[data-state='selected']:hover { + cursor: default; } .papi-multi-column-menu { background-color: rgb(222, 222, 222); @@ -13806,25 +13866,31 @@ video:where(.pr-twp,.pr-twp *) { color: rgb(76, 106, 76); background-color: rgb(214, 255, 152); } -.papi-menu-item { - background-color: transparent; +.papi-icon-button { + border: 0; + border-radius: 3em; + cursor: pointer; + display: inline-block; } -.papi-menu-icon-trailing { - margin-left: 10px; - place-content: flex-end; +.papi-icon-button.primary { + background-color: #1ea7fd; + color: white; } -.papi-menu-item img { - max-width: 24px; - max-height: 24px; +.papi-icon-button.secondary { + background-color: transparent; + color: #333; } -.banded-row:hover { - cursor: pointer; + +.papi-icon-button.paratext { + background-color: darkgreen; + color: greenyellow; } -.banded-row[data-state='selected']:hover { - cursor: default; +.papi-icon-button.paratext.bright { + background-color: greenyellow; + color: darkgreen; } .papi-menu-drawer-paper { height: fit-content !important; @@ -13836,121 +13902,134 @@ video:where(.pr-twp,.pr-twp *) { display: flex; gap: 8px; } +.papi-menu-item { + background-color: transparent; +} + +.papi-menu-icon-trailing { + margin-left: 10px; + place-content: flex-end; +} + +.papi-menu-item img { + max-width: 24px; + max-height: 24px; +} `, "top"); export { - zm as Alert, - Fm as AlertDescription, - Lm as AlertTitle, - vh as BOOK_SELECTOR_STRING_KEYS, - bh as BookChapterControl, - Bc as BookSelectionMode, - yh as BookSelector, + Vm as Alert, + Lm as AlertDescription, + zm as AlertTitle, + bh as BOOK_SELECTOR_STRING_KEYS, + gh as BookChapterControl, + jc as BookSelectionMode, + vh as BookSelector, gt as Button, - Xi as Card, - Vd as CardContent, - qi as CardDescription, - zd as CardFooter, - Yi as CardHeader, - Wi as CardTitle, - Dc as ChapterRangeSelector, + Yi as Card, + Ji as CardContent, + Ki as CardDescription, + Vd as CardFooter, + Wi as CardHeader, + qi as CardTitle, + Bc as ChapterRangeSelector, ho as Checkbox, Ih as Checklist, qr as ComboBox, - Hc as DataTable, - Fh as DisableButton, + Xc as DataTable, + Lh as DisableButton, fo as DropdownMenu, mo as DropdownMenuCheckboxItem, rr as DropdownMenuContent, - pc as DropdownMenuGroup, + uc as DropdownMenuGroup, hi as DropdownMenuItem, - qm as DropdownMenuItemType, + Wm as DropdownMenuItemType, Sn as DropdownMenuLabel, - mh as DropdownMenuPortal, - gh as DropdownMenuRadioGroup, + fh as DropdownMenuPortal, + hh as DropdownMenuRadioGroup, gi as DropdownMenuRadioItem, or as DropdownMenuSeparator, - fc as DropdownMenuShortcut, - hh as DropdownMenuSub, - wc as DropdownMenuSubContent, - uc as DropdownMenuSubTrigger, + mc as DropdownMenuShortcut, + mh as DropdownMenuSub, + fc as DropdownMenuSubContent, + wc as DropdownMenuSubTrigger, mi as DropdownMenuTrigger, - Lh as EnableButton, - Wm as FilterButton, - Hh as FilterDropdown, - Wh as Footer, - Mm as GridMenu, - jm as HamburgerMenuButton, - Eh as INVENTORY_STRING_KEYS, - Mh as IconButton, + zh as EnableButton, + Ym as FilterButton, + Gh as FilterDropdown, + Yh as Footer, + Am as GridMenu, + Bm as HamburgerMenuButton, + kh as INVENTORY_STRING_KEYS, + Ah as IconButton, Ye as Input, - zh as InstallButton, - Sh as Inventory, + Vh as InstallButton, + Eh as Inventory, Xt as Label, - Gh as MarkdownRenderer, - js as MenuItem, - Yh as MoreInfo, - Th as NavigationContentSearch, - Xh as NoExtensionsFound, + Uh as MarkdownRenderer, + zs as MenuItem, + Xh as MoreInfo, + Sh as NavigationContentSearch, + Hh as NoExtensionsFound, bi as RadioGroup, Wr as RadioGroupItem, - Oh as ScriptureResultsViewer, - Rh as ScrollGroupSelector, - td as SearchBar, + Ch as ScriptureResultsViewer, + Oh as ScrollGroupSelector, + Pi as SearchBar, gn as Select, Be as SelectContent, - Vc as SelectGroup, + zc as SelectGroup, Gt as SelectItem, - zc as SelectLabel, + Lc as SelectLabel, Ci as SelectScrollDownButton, Ti as SelectScrollUpButton, - Lc as SelectSeparator, + Fc as SelectSeparator, De as SelectTrigger, bn as SelectValue, go as Separator, - Ah as SettingsCard, - _h as SettingsList, - $h as SettingsListHeader, - Ph as SettingsListItem, + $h as SettingsCard, + Rh as SettingsList, + Ph as SettingsListHeader, + _h as SettingsListItem, Pd as SettingsSidebar, - Ch as SettingsSidebarContentSearch, - Um as Slider, - jh as Sonner, + Th as SettingsSidebarContentSearch, + Fm as Slider, + Bh as Sonner, $n as Spinner, - Gm as Switch, + Um as Switch, ar as Table, sr as TableBody, - Gc as TableCaption, + Hc as TableCaption, je as TableCell, - Uc as TableFooter, + Gc as TableFooter, vn as TableHead, ir as TableHeader, oe as TableRow, - Vh as Tabs, - Ym as TabsContent, - Hm as TabsList, - Xm as TabsTrigger, - Dh as TextField, + jh as Tabs, + Xm as TabsContent, + Gm as TabsList, + Hm as TabsTrigger, + Mh as TextField, _i as ToggleGroup, Un as ToggleGroupItem, - Bh as Toolbar, - Uh as UpdateButton, - Km as VersionHistory, - Pi as VerticalTabs, + Dh as Toolbar, + Fh as UpdateButton, + qm as VersionHistory, + $i as VerticalTabs, Ai as VerticalTabsContent, - $i as VerticalTabsList, + Ii as VerticalTabsList, ed as VerticalTabsTrigger, - Sc as buttonVariants, + Tc as buttonVariants, N as cn, - Wc as getBookNumFromId, - Yc as getLinesFromUSFM, + qc as getBookNumFromId, + Wc as getLinesFromUSFM, oa as getNumberFromUSFM, - qc as getStatusForItem, - Nh as inventoryCountColumn, - xh as inventoryItemColumn, - kh as inventoryStatusColumn, - Qh as sonner, - qh as useEvent, - Kh as useEventAsync, + Kc as getStatusForItem, + xh as inventoryCountColumn, + yh as inventoryItemColumn, + Nh as inventoryStatusColumn, + Zh as sonner, + Wh as useEvent, + qh as useEventAsync, lo as usePromise }; //# sourceMappingURL=index.js.map diff --git a/lib/platform-bible-react/dist/index.js.map b/lib/platform-bible-react/dist/index.js.map index 0c8db16fd2..0acfd36a54 100644 --- a/lib/platform-bible-react/dist/index.js.map +++ b/lib/platform-bible-react/dist/index.js.map @@ -1 +1 @@ -{"version":3,"file":"index.js","sources":["../src/utils/shadcn-ui.util.ts","../src/components/shadcn-ui/input.tsx","../src/components/advanced/book-chapter-control/book-chapter-input.component.tsx","../../../node_modules/@sillsdev/scripture/dist/index.es.js","../src/components/shadcn-ui/dropdown-menu.tsx","../src/components/advanced/book-chapter-control/book-menu-item.component.tsx","../src/components/advanced/book-chapter-control/chapter-select.component.tsx","../src/components/advanced/book-chapter-control/go-to-menu-item.component.tsx","../src/components/advanced/book-chapter-control/book-chapter-control.component.tsx","../src/components/shadcn-ui/button.tsx","../src/components/shadcn-ui/label.tsx","../src/components/shadcn-ui/radio-group.tsx","../src/components/shadcn-ui/popover.tsx","../src/components/shadcn-ui/dialog.tsx","../src/components/shadcn-ui/command.tsx","../src/components/basics/combo-box.component.tsx","../src/components/basics/chapter-range-selector.component.tsx","../src/components/advanced/book-selector.component.tsx","../src/components/advanced/data-table/data-table-column-toggle.component.tsx","../src/components/shadcn-ui/select.tsx","../src/components/advanced/data-table/data-table-pagination.component.tsx","../src/components/shadcn-ui/table.tsx","../src/components/advanced/data-table/data-table.component.tsx","../src/components/advanced/inventory/occurrences-table.component.tsx","../src/components/shadcn-ui/checkbox.tsx","../src/components/advanced/inventory/inventory-utils.ts","../src/components/shadcn-ui/toggle.tsx","../src/components/shadcn-ui/toggle-group.tsx","../src/components/advanced/inventory/inventory-columns.tsx","../src/components/advanced/inventory/inventory.component.tsx","../src/components/basics/search-bar.component.tsx","../src/components/basics/tabs-vertical.tsx","../src/components/advanced/tab-navigation-content-search.component.tsx","../src/components/shadcn-ui/separator.tsx","../src/components/shadcn-ui/sheet.tsx","../src/components/shadcn-ui/skeleton.tsx","../src/components/shadcn-ui/tooltip.tsx","../src/components/hooks/use-mobile.tsx","../src/components/shadcn-ui/sidebar.tsx","../src/components/advanced/settings-components/settings-sidebar.component.tsx","../src/components/advanced/settings-components/settings-sidebar-content-search.component.tsx","../src/components/advanced/scripture-results-viewer/scripture-results-viewer.component.tsx","../src/components/advanced/scroll-group-selector.component.tsx","../src/components/advanced/settings-components/settings-list.component.tsx","../src/components/shadcn-ui/card.tsx","../src/components/advanced/settings-components/settings-card.component.tsx","../src/components/basics/checklist.component.tsx","../../../node_modules/@babel/runtime/helpers/interopRequireDefault.js","../../../node_modules/@mui/utils/chainPropTypes/chainPropTypes.js","../../../node_modules/@babel/runtime/helpers/esm/extends.js","../../../node_modules/@mui/utils/deepmerge/deepmerge.js","../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.production.min.js","../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.development.js","../../../node_modules/prop-types/node_modules/react-is/index.js","../../../node_modules/object-assign/index.js","../../../node_modules/prop-types/lib/ReactPropTypesSecret.js","../../../node_modules/prop-types/lib/has.js","../../../node_modules/prop-types/checkPropTypes.js","../../../node_modules/prop-types/factoryWithTypeCheckers.js","../../../node_modules/prop-types/factoryWithThrowingShims.js","../../../node_modules/prop-types/index.js","../../../node_modules/@mui/utils/elementAcceptingRef/elementAcceptingRef.js","../../../node_modules/@mui/utils/exactProp/exactProp.js","../../../node_modules/@mui/utils/formatMuiErrorMessage/formatMuiErrorMessage.js","../../../node_modules/react-is/cjs/react-is.production.min.js","../../../node_modules/react-is/cjs/react-is.development.js","../../../node_modules/react-is/index.js","../../../node_modules/@mui/utils/getDisplayName/getDisplayName.js","../../../node_modules/@mui/utils/HTMLElementType/HTMLElementType.js","../../../node_modules/@mui/utils/refType/refType.js","../../../node_modules/@mui/utils/capitalize/capitalize.js","../../../node_modules/@mui/utils/createChainedFunction/createChainedFunction.js","../../../node_modules/@mui/utils/debounce/debounce.js","../../../node_modules/@mui/utils/deprecatedPropType/deprecatedPropType.js","../../../node_modules/@mui/utils/isMuiElement/isMuiElement.js","../../../node_modules/@mui/utils/ownerDocument/ownerDocument.js","../../../node_modules/@mui/utils/ownerWindow/ownerWindow.js","../../../node_modules/@mui/utils/requirePropFactory/requirePropFactory.js","../../../node_modules/@mui/utils/setRef/setRef.js","../../../node_modules/@mui/utils/useEnhancedEffect/useEnhancedEffect.js","../../../node_modules/@mui/utils/useId/useId.js","../../../node_modules/@mui/utils/unsupportedProp/unsupportedProp.js","../../../node_modules/@mui/utils/useControlled/useControlled.js","../../../node_modules/@mui/utils/useEventCallback/useEventCallback.js","../../../node_modules/@mui/utils/useForkRef/useForkRef.js","../../../node_modules/@mui/utils/useLazyRef/useLazyRef.js","../../../node_modules/@mui/utils/useOnMount/useOnMount.js","../../../node_modules/@mui/utils/useTimeout/useTimeout.js","../../../node_modules/@mui/utils/useIsFocusVisible/useIsFocusVisible.js","../../../node_modules/@mui/utils/resolveProps/resolveProps.js","../../../node_modules/@mui/utils/composeClasses/composeClasses.js","../../../node_modules/@mui/utils/ClassNameGenerator/ClassNameGenerator.js","../../../node_modules/@mui/utils/generateUtilityClass/generateUtilityClass.js","../../../node_modules/@mui/utils/generateUtilityClasses/generateUtilityClasses.js","../../../node_modules/@mui/utils/clamp/clamp.js","../../../node_modules/@babel/runtime/helpers/esm/objectWithoutPropertiesLoose.js","../../../node_modules/@mui/system/esm/createTheme/createBreakpoints.js","../../../node_modules/@mui/system/esm/createTheme/shape.js","../../../node_modules/@mui/system/esm/responsivePropType.js","../../../node_modules/@mui/system/esm/merge.js","../../../node_modules/@mui/system/esm/breakpoints.js","../../../node_modules/@mui/system/esm/style.js","../../../node_modules/@mui/system/esm/memoize.js","../../../node_modules/@mui/system/esm/spacing.js","../../../node_modules/@mui/system/esm/createTheme/createSpacing.js","../../../node_modules/@mui/system/esm/compose.js","../../../node_modules/@mui/system/esm/borders.js","../../../node_modules/@mui/system/esm/cssGrid.js","../../../node_modules/@mui/system/esm/palette.js","../../../node_modules/@mui/system/esm/sizing.js","../../../node_modules/@mui/system/esm/styleFunctionSx/defaultSxConfig.js","../../../node_modules/@mui/system/esm/styleFunctionSx/styleFunctionSx.js","../../../node_modules/@mui/system/esm/createTheme/applyStyles.js","../../../node_modules/@mui/system/esm/createTheme/createTheme.js","../../../node_modules/@mui/system/esm/useThemeWithoutDefault.js","../../../node_modules/@mui/system/esm/useTheme.js","../../../node_modules/@mui/system/esm/createStyled.js","../../../node_modules/@mui/system/esm/useThemeProps/getThemeProps.js","../../../node_modules/@mui/system/esm/useThemeProps/useThemeProps.js","../../../node_modules/@mui/system/esm/colorManipulator.js","../../../node_modules/@mui/material/styles/createMixins.js","../../../node_modules/@mui/material/colors/common.js","../../../node_modules/@mui/material/colors/grey.js","../../../node_modules/@mui/material/colors/purple.js","../../../node_modules/@mui/material/colors/red.js","../../../node_modules/@mui/material/colors/orange.js","../../../node_modules/@mui/material/colors/blue.js","../../../node_modules/@mui/material/colors/lightBlue.js","../../../node_modules/@mui/material/colors/green.js","../../../node_modules/@mui/material/styles/createPalette.js","../../../node_modules/@mui/material/styles/createTypography.js","../../../node_modules/@mui/material/styles/shadows.js","../../../node_modules/@mui/material/styles/createTransitions.js","../../../node_modules/@mui/material/styles/zIndex.js","../../../node_modules/@mui/material/styles/createTheme.js","../../../node_modules/@mui/material/styles/defaultTheme.js","../../../node_modules/@mui/material/styles/identifier.js","../../../node_modules/@mui/material/styles/useThemeProps.js","../../../node_modules/@mui/material/styles/styled.js","../../../node_modules/@mui/material/SvgIcon/svgIconClasses.js","../../../node_modules/@mui/material/SvgIcon/SvgIcon.js","../../../node_modules/@mui/material/utils/createSvgIcon.js","../../../node_modules/@mui/material/utils/index.js","../../../node_modules/@mui/icons-material/utils/createSvgIcon.js","../../../node_modules/@mui/icons-material/ArrowRight.js","../../../node_modules/@mui/base/utils/isHostComponent.js","../../../node_modules/@mui/base/utils/appendOwnerState.js","../../../node_modules/@mui/base/utils/ClassNameConfigurator.js","../../../node_modules/@mui/base/utils/extractEventHandlers.js","../../../node_modules/@mui/base/utils/resolveComponentProps.js","../../../node_modules/@mui/base/utils/omitEventHandlers.js","../../../node_modules/@mui/base/utils/mergeSlotProps.js","../../../node_modules/@mui/base/utils/useSlotProps.js","../../../node_modules/@mui/base/generateUtilityClass/index.js","../../../node_modules/@mui/base/generateUtilityClasses/index.js","../../../node_modules/@mui/base/Portal/Portal.js","../../../node_modules/@popperjs/core/lib/enums.js","../../../node_modules/@popperjs/core/lib/dom-utils/getNodeName.js","../../../node_modules/@popperjs/core/lib/dom-utils/getWindow.js","../../../node_modules/@popperjs/core/lib/dom-utils/instanceOf.js","../../../node_modules/@popperjs/core/lib/modifiers/applyStyles.js","../../../node_modules/@popperjs/core/lib/utils/getBasePlacement.js","../../../node_modules/@popperjs/core/lib/utils/math.js","../../../node_modules/@popperjs/core/lib/utils/userAgent.js","../../../node_modules/@popperjs/core/lib/dom-utils/isLayoutViewport.js","../../../node_modules/@popperjs/core/lib/dom-utils/getBoundingClientRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/getLayoutRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/contains.js","../../../node_modules/@popperjs/core/lib/dom-utils/getComputedStyle.js","../../../node_modules/@popperjs/core/lib/dom-utils/isTableElement.js","../../../node_modules/@popperjs/core/lib/dom-utils/getDocumentElement.js","../../../node_modules/@popperjs/core/lib/dom-utils/getParentNode.js","../../../node_modules/@popperjs/core/lib/dom-utils/getOffsetParent.js","../../../node_modules/@popperjs/core/lib/utils/getMainAxisFromPlacement.js","../../../node_modules/@popperjs/core/lib/utils/within.js","../../../node_modules/@popperjs/core/lib/utils/getFreshSideObject.js","../../../node_modules/@popperjs/core/lib/utils/mergePaddingObject.js","../../../node_modules/@popperjs/core/lib/utils/expandToHashMap.js","../../../node_modules/@popperjs/core/lib/modifiers/arrow.js","../../../node_modules/@popperjs/core/lib/utils/getVariation.js","../../../node_modules/@popperjs/core/lib/modifiers/computeStyles.js","../../../node_modules/@popperjs/core/lib/modifiers/eventListeners.js","../../../node_modules/@popperjs/core/lib/utils/getOppositePlacement.js","../../../node_modules/@popperjs/core/lib/utils/getOppositeVariationPlacement.js","../../../node_modules/@popperjs/core/lib/dom-utils/getWindowScroll.js","../../../node_modules/@popperjs/core/lib/dom-utils/getWindowScrollBarX.js","../../../node_modules/@popperjs/core/lib/dom-utils/getViewportRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/getDocumentRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/isScrollParent.js","../../../node_modules/@popperjs/core/lib/dom-utils/getScrollParent.js","../../../node_modules/@popperjs/core/lib/dom-utils/listScrollParents.js","../../../node_modules/@popperjs/core/lib/utils/rectToClientRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/getClippingRect.js","../../../node_modules/@popperjs/core/lib/utils/computeOffsets.js","../../../node_modules/@popperjs/core/lib/utils/detectOverflow.js","../../../node_modules/@popperjs/core/lib/utils/computeAutoPlacement.js","../../../node_modules/@popperjs/core/lib/modifiers/flip.js","../../../node_modules/@popperjs/core/lib/modifiers/hide.js","../../../node_modules/@popperjs/core/lib/modifiers/offset.js","../../../node_modules/@popperjs/core/lib/modifiers/popperOffsets.js","../../../node_modules/@popperjs/core/lib/utils/getAltAxis.js","../../../node_modules/@popperjs/core/lib/modifiers/preventOverflow.js","../../../node_modules/@popperjs/core/lib/dom-utils/getHTMLElementScroll.js","../../../node_modules/@popperjs/core/lib/dom-utils/getNodeScroll.js","../../../node_modules/@popperjs/core/lib/dom-utils/getCompositeRect.js","../../../node_modules/@popperjs/core/lib/utils/orderModifiers.js","../../../node_modules/@popperjs/core/lib/utils/debounce.js","../../../node_modules/@popperjs/core/lib/utils/mergeByName.js","../../../node_modules/@popperjs/core/lib/createPopper.js","../../../node_modules/@popperjs/core/lib/popper.js","../../../node_modules/@mui/base/Popper/popperClasses.js","../../../node_modules/@mui/base/Popper/Popper.js","../../../node_modules/@mui/material/styles/useTheme.js","../../../node_modules/@babel/runtime/helpers/esm/setPrototypeOf.js","../../../node_modules/@babel/runtime/helpers/esm/inheritsLoose.js","../../../node_modules/react-transition-group/esm/config.js","../../../node_modules/react-transition-group/esm/utils/PropTypes.js","../../../node_modules/react-transition-group/esm/TransitionGroupContext.js","../../../node_modules/react-transition-group/esm/utils/reflow.js","../../../node_modules/react-transition-group/esm/Transition.js","../../../node_modules/@mui/material/transitions/utils.js","../../../node_modules/@mui/material/Grow/Grow.js","../../../node_modules/@mui/material/Popper/Popper.js","../../../node_modules/@mui/material/Tooltip/tooltipClasses.js","../../../node_modules/@mui/material/Tooltip/Tooltip.js","../src/components/mui/menu-item.component.tsx","../src/components/mui/grouped-menu-item-list.component.tsx","../src/components/mui/top-level-menu.component.tsx","../src/components/mui/grid-menu.component.tsx","../src/hooks/use-promise.hook.ts","../../../node_modules/@mui/icons-material/esm/Menu.js","../src/components/mui/hamburger-menu-button.component.tsx","../src/components/mui/icon-button.component.tsx","../src/components/basics/spinner.component.tsx","../src/components/basics/text-field.component.tsx","../src/components/mui/toolbar.component.tsx","../src/components/shadcn-ui/alert.tsx","../src/components/shadcn-ui/sonner.tsx","../src/components/shadcn-ui/slider.tsx","../src/components/shadcn-ui/switch.tsx","../src/components/shadcn-ui/tabs.tsx","../src/components/advanced/extension-marketplace/buttons/install-button.component.tsx","../src/components/advanced/extension-marketplace/buttons/enable-button.component.tsx","../src/components/advanced/extension-marketplace/buttons/disable-button.component.tsx","../src/components/advanced/extension-marketplace/buttons/update-button.component.tsx","../src/components/advanced/extension-marketplace/markdown-renderer.component.tsx","../src/components/advanced/extension-marketplace/buttons/filter-button.component.tsx","../src/components/advanced/extension-marketplace/filter-dropdown.component.tsx","../src/components/advanced/extension-marketplace/no-extensions-found.component.tsx","../src/components/advanced/extension-marketplace/more-info.component.tsx","../src/components/advanced/extension-marketplace/version-history.component.tsx","../src/components/advanced/extension-marketplace/footer.component.tsx","../src/hooks/use-event.hook.ts","../src/hooks/use-event-async.hook.ts"],"sourcesContent":["import { type ClassValue, clsx } from 'clsx';\nimport { extendTailwindMerge } from 'tailwind-merge';\n\nconst twMergeCustom = extendTailwindMerge({ prefix: 'tw-' });\n\n/**\n * Tailwind and CSS class application helper function. Uses\n * [`clsx`](https://www.npmjs.com/package/clsx) to make it easy to apply classes conditionally using\n * object syntax, and uses [`tailwind-merge`](https://www.npmjs.com/package/tailwind-merge) to make\n * it easy to merge/overwrite Tailwind classes in a programmer-logic-friendly way.\n *\n * Note: `tailwind-merge` is configured to use the prefix `tw-`, so you must use the same prefix\n * with any Tailwind classes you use with this function to successfully overwrite other Tailwind\n * classes. `platform-bible-react` is configured to use `tw-` as its Tailwind prefix, so any\n * Tailwind classes you pass into `platform-bible-react` components will be compared using the `tw-`\n * prefix.\n *\n * This function was popularized by\n * [shadcn/ui](https://ui.shadcn.com/docs/installation/manual#add-a-cn-helper). See [ByteGrad's\n * explanation video](https://www.youtube.com/watch?v=re2JFITR7TI) for more information.\n *\n * @example\n *\n * ```typescript\n * const borderShouldBeBlue = true;\n * const textShouldBeRed = true;\n * const heightShouldBe20 = false;\n * const classString = cn(\n * 'tw-bg-primary tw-h-10 tw-text-primary-foreground',\n * 'tw-bg-secondary',\n * {\n * 'tw-border-blue-500': borderShouldBeBlue,\n * 'tw-text-red-500': textShouldBeRed,\n * 'tw-h-20': heightShouldBe20,\n * },\n * 'some-class',\n * );\n * ```\n *\n * The resulting `classString` is `'tw-h-10 tw-bg-secondary tw-border-blue-500 tw-text-red-500\n * some-class'`\n *\n * - Notice that `'tw-bg-secondary'`, specified later, overwrote `'tw-bg-primary'`, specified earlier,\n * because they are Tailwind classes that affect the same css property\n * - Notice that `'tw-text-red-500'`, specified later, overwrote `'tw-text-primary-foreground'`,\n * specified earlier, because they are Tailwind classes that affect the same css property\n * - Notice that `'tw-h-20'`, specified later, did not overwrite `'tw-h-10'`, specified earlier,\n * because `'tw-h-20'` is part of a conditional class object and its value evaluated to `false`;\n * therefore it was not applied\n * - Notice that `'some-class'` was applied. This function is not limited only to Tailwind classes.\n *\n *\n * @param inputs Class strings or `clsx` conditional class objects to merge. Tailwind classes\n * specified later in the arguments overwrite similar Tailwind classes specified earlier in the\n * arguments\n * @returns Class string containing all applicable classes from the arguments based on the rules\n * described above\n */\n// shadcn/ui uses this export in its boilerplate code\n// eslint-disable-next-line import/prefer-default-export\nexport function cn(...inputs: ClassValue[]) {\n return twMergeCustom(clsx(inputs));\n}\n","import React from 'react';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport interface InputProps extends React.InputHTMLAttributes {}\n\nexport const Input = React.forwardRef(\n ({ className, type, ...props }, ref) => {\n return (\n \n );\n },\n);\nInput.displayName = 'Input';\n","import { FocusEventHandler, forwardRef, KeyboardEvent, MouseEventHandler } from 'react';\nimport { History } from 'lucide-react';\nimport { Input as ShadInput } from '@/components/shadcn-ui/input';\n\nexport type BookChapterInputProps = {\n handleSearch: (searchString: string) => void;\n handleKeyDown: (event: KeyboardEvent) => void;\n handleOnClick: MouseEventHandler;\n handleSubmit: () => void;\n onFocus?: FocusEventHandler;\n value: string;\n placeholder: string;\n};\n\n// Shadcn Input sets type to \"button\"- HAVE to prop spread before setting type\nconst BookChapterInput = forwardRef(\n (\n { handleSearch, handleKeyDown, handleOnClick, handleSubmit, ...props }: BookChapterInputProps,\n ref,\n ) => {\n return (\n
    \n handleSearch(event.target.value)}\n onKeyDown={(e) => {\n if (e.key === 'Enter') {\n handleSubmit();\n }\n handleKeyDown(e);\n }}\n onClick={handleOnClick}\n ref={ref}\n />\n {\n // eslint-disable-next-line no-console\n console.log('back in history');\n }}\n />\n
    \n );\n },\n);\n\nexport default BookChapterInput;\n","var P = Object.defineProperty;\nvar R = (t, e, s) => e in t ? P(t, e, { enumerable: !0, configurable: !0, writable: !0, value: s }) : t[e] = s;\nvar n = (t, e, s) => R(t, typeof e != \"symbol\" ? e + \"\" : e, s);\nclass _ {\n constructor() {\n n(this, \"books\");\n n(this, \"firstSelectedBookNum\");\n n(this, \"lastSelectedBookNum\");\n n(this, \"count\");\n n(this, \"selectedBookNumbers\");\n n(this, \"selectedBookIds\");\n }\n}\nconst N = [\n \"GEN\",\n \"EXO\",\n \"LEV\",\n \"NUM\",\n \"DEU\",\n \"JOS\",\n \"JDG\",\n \"RUT\",\n \"1SA\",\n \"2SA\",\n // 10\n \"1KI\",\n \"2KI\",\n \"1CH\",\n \"2CH\",\n \"EZR\",\n \"NEH\",\n \"EST\",\n \"JOB\",\n \"PSA\",\n \"PRO\",\n // 20\n \"ECC\",\n \"SNG\",\n \"ISA\",\n \"JER\",\n \"LAM\",\n \"EZK\",\n \"DAN\",\n \"HOS\",\n \"JOL\",\n \"AMO\",\n // 30\n \"OBA\",\n \"JON\",\n \"MIC\",\n \"NAM\",\n \"HAB\",\n \"ZEP\",\n \"HAG\",\n \"ZEC\",\n \"MAL\",\n \"MAT\",\n // 40\n \"MRK\",\n \"LUK\",\n \"JHN\",\n \"ACT\",\n \"ROM\",\n \"1CO\",\n \"2CO\",\n \"GAL\",\n \"EPH\",\n \"PHP\",\n // 50\n \"COL\",\n \"1TH\",\n \"2TH\",\n \"1TI\",\n \"2TI\",\n \"TIT\",\n \"PHM\",\n \"HEB\",\n \"JAS\",\n \"1PE\",\n // 60\n \"2PE\",\n \"1JN\",\n \"2JN\",\n \"3JN\",\n \"JUD\",\n \"REV\",\n \"TOB\",\n \"JDT\",\n \"ESG\",\n \"WIS\",\n // 70\n \"SIR\",\n \"BAR\",\n \"LJE\",\n \"S3Y\",\n \"SUS\",\n \"BEL\",\n \"1MA\",\n \"2MA\",\n \"3MA\",\n \"4MA\",\n // 80\n \"1ES\",\n \"2ES\",\n \"MAN\",\n \"PS2\",\n \"ODA\",\n \"PSS\",\n \"JSA\",\n // actual variant text for JOS, now in LXA text\n \"JDB\",\n // actual variant text for JDG, now in LXA text\n \"TBS\",\n // actual variant text for TOB, now in LXA text\n \"SST\",\n // actual variant text for SUS, now in LXA text // 90\n \"DNT\",\n // actual variant text for DAN, now in LXA text\n \"BLT\",\n // actual variant text for BEL, now in LXA text\n \"XXA\",\n \"XXB\",\n \"XXC\",\n \"XXD\",\n \"XXE\",\n \"XXF\",\n \"XXG\",\n \"FRT\",\n // 100\n \"BAK\",\n \"OTH\",\n \"3ES\",\n // Used previously but really should be 2ES\n \"EZA\",\n // Used to be called 4ES, but not actually in any known project\n \"5EZ\",\n // Used to be called 5ES, but not actually in any known project\n \"6EZ\",\n // Used to be called 6ES, but not actually in any known project\n \"INT\",\n \"CNC\",\n \"GLO\",\n \"TDX\",\n // 110\n \"NDX\",\n \"DAG\",\n \"PS3\",\n \"2BA\",\n \"LBA\",\n \"JUB\",\n \"ENO\",\n \"1MQ\",\n \"2MQ\",\n \"3MQ\",\n // 120\n \"REP\",\n \"4BA\",\n \"LAO\"\n], B = [\n \"XXA\",\n \"XXB\",\n \"XXC\",\n \"XXD\",\n \"XXE\",\n \"XXF\",\n \"XXG\",\n \"FRT\",\n \"BAK\",\n \"OTH\",\n \"INT\",\n \"CNC\",\n \"GLO\",\n \"TDX\",\n \"NDX\"\n], O = [\n \"Genesis\",\n \"Exodus\",\n \"Leviticus\",\n \"Numbers\",\n \"Deuteronomy\",\n \"Joshua\",\n \"Judges\",\n \"Ruth\",\n \"1 Samuel\",\n \"2 Samuel\",\n \"1 Kings\",\n \"2 Kings\",\n \"1 Chronicles\",\n \"2 Chronicles\",\n \"Ezra\",\n \"Nehemiah\",\n \"Esther (Hebrew)\",\n \"Job\",\n \"Psalms\",\n \"Proverbs\",\n \"Ecclesiastes\",\n \"Song of Songs\",\n \"Isaiah\",\n \"Jeremiah\",\n \"Lamentations\",\n \"Ezekiel\",\n \"Daniel (Hebrew)\",\n \"Hosea\",\n \"Joel\",\n \"Amos\",\n \"Obadiah\",\n \"Jonah\",\n \"Micah\",\n \"Nahum\",\n \"Habakkuk\",\n \"Zephaniah\",\n \"Haggai\",\n \"Zechariah\",\n \"Malachi\",\n \"Matthew\",\n \"Mark\",\n \"Luke\",\n \"John\",\n \"Acts\",\n \"Romans\",\n \"1 Corinthians\",\n \"2 Corinthians\",\n \"Galatians\",\n \"Ephesians\",\n \"Philippians\",\n \"Colossians\",\n \"1 Thessalonians\",\n \"2 Thessalonians\",\n \"1 Timothy\",\n \"2 Timothy\",\n \"Titus\",\n \"Philemon\",\n \"Hebrews\",\n \"James\",\n \"1 Peter\",\n \"2 Peter\",\n \"1 John\",\n \"2 John\",\n \"3 John\",\n \"Jude\",\n \"Revelation\",\n \"Tobit\",\n \"Judith\",\n \"Esther Greek\",\n \"Wisdom of Solomon\",\n \"Sirach (Ecclesiasticus)\",\n \"Baruch\",\n \"Letter of Jeremiah\",\n \"Song of 3 Young Men\",\n \"Susanna\",\n \"Bel and the Dragon\",\n \"1 Maccabees\",\n \"2 Maccabees\",\n \"3 Maccabees\",\n \"4 Maccabees\",\n \"1 Esdras (Greek)\",\n \"2 Esdras (Latin)\",\n \"Prayer of Manasseh\",\n \"Psalm 151\",\n \"Odes\",\n \"Psalms of Solomon\",\n // WARNING, if you change the spelling of the *obsolete* tag be sure to update\n // IsObsolete routine\n \"Joshua A. *obsolete*\",\n \"Judges B. *obsolete*\",\n \"Tobit S. *obsolete*\",\n \"Susanna Th. *obsolete*\",\n \"Daniel Th. *obsolete*\",\n \"Bel Th. *obsolete*\",\n \"Extra A\",\n \"Extra B\",\n \"Extra C\",\n \"Extra D\",\n \"Extra E\",\n \"Extra F\",\n \"Extra G\",\n \"Front Matter\",\n \"Back Matter\",\n \"Other Matter\",\n \"3 Ezra *obsolete*\",\n \"Apocalypse of Ezra\",\n \"5 Ezra (Latin Prologue)\",\n \"6 Ezra (Latin Epilogue)\",\n \"Introduction\",\n \"Concordance \",\n \"Glossary \",\n \"Topical Index\",\n \"Names Index\",\n \"Daniel Greek\",\n \"Psalms 152-155\",\n \"2 Baruch (Apocalypse)\",\n \"Letter of Baruch\",\n \"Jubilees\",\n \"Enoch\",\n \"1 Meqabyan\",\n \"2 Meqabyan\",\n \"3 Meqabyan\",\n \"Reproof (Proverbs 25-31)\",\n \"4 Baruch (Rest of Baruch)\",\n \"Laodiceans\"\n], S = K();\nfunction g(t, e = !0) {\n return e && (t = t.toUpperCase()), t in S ? S[t] : 0;\n}\nfunction k(t) {\n return g(t) > 0;\n}\nfunction x(t) {\n const e = typeof t == \"string\" ? g(t) : t;\n return e >= 40 && e <= 66;\n}\nfunction T(t) {\n return (typeof t == \"string\" ? g(t) : t) <= 39;\n}\nfunction X(t) {\n return t <= 66;\n}\nfunction V(t) {\n const e = typeof t == \"string\" ? g(t) : t;\n return w(e) && !X(e);\n}\nfunction* L() {\n for (let t = 1; t <= N.length; t++) yield t;\n}\nconst G = 1, A = N.length;\nfunction H() {\n return [\"XXA\", \"XXB\", \"XXC\", \"XXD\", \"XXE\", \"XXF\", \"XXG\"];\n}\nfunction C(t, e = \"***\") {\n const s = t - 1;\n return s < 0 || s >= N.length ? e : N[s];\n}\nfunction I(t) {\n return t <= 0 || t > A ? \"******\" : O[t - 1];\n}\nfunction y(t) {\n return I(g(t));\n}\nfunction w(t) {\n const e = typeof t == \"number\" ? C(t) : t;\n return k(e) && !B.includes(e);\n}\nfunction q(t) {\n const e = typeof t == \"number\" ? C(t) : t;\n return k(e) && B.includes(e);\n}\nfunction U(t) {\n return O[t - 1].includes(\"*obsolete*\");\n}\nfunction K() {\n const t = {};\n for (let e = 0; e < N.length; e++)\n t[N[e]] = e + 1;\n return t;\n}\nconst m = {\n allBookIds: N,\n nonCanonicalIds: B,\n bookIdToNumber: g,\n isBookIdValid: k,\n isBookNT: x,\n isBookOT: T,\n isBookOTNT: X,\n isBookDC: V,\n allBookNumbers: L,\n firstBook: G,\n lastBook: A,\n extraBooks: H,\n bookNumberToId: C,\n bookNumberToEnglishName: I,\n bookIdToEnglishName: y,\n isCanonical: w,\n isExtraMaterial: q,\n isObsolete: U\n};\nvar l = /* @__PURE__ */ ((t) => (t[t.Unknown = 0] = \"Unknown\", t[t.Original = 1] = \"Original\", t[t.Septuagint = 2] = \"Septuagint\", t[t.Vulgate = 3] = \"Vulgate\", t[t.English = 4] = \"English\", t[t.RussianProtestant = 5] = \"RussianProtestant\", t[t.RussianOrthodox = 6] = \"RussianOrthodox\", t))(l || {});\nconst h = class h {\n // private versInfo: Versification;\n constructor(e) {\n n(this, \"name\");\n n(this, \"fullPath\");\n n(this, \"isPresent\");\n n(this, \"hasVerseSegments\");\n n(this, \"isCustomized\");\n n(this, \"baseVersification\");\n n(this, \"scriptureBooks\");\n n(this, \"_type\");\n if (e == null)\n throw new Error(\"Argument undefined\");\n typeof e == \"string\" ? (this.name = e, this._type = l[e]) : (this._type = e, this.name = l[e]);\n }\n get type() {\n return this._type;\n }\n equals(e) {\n return !e.type || !this.type ? !1 : e.type === this.type;\n }\n};\nn(h, \"Original\", new h(l.Original)), n(h, \"Septuagint\", new h(l.Septuagint)), n(h, \"Vulgate\", new h(l.Vulgate)), n(h, \"English\", new h(l.English)), n(h, \"RussianProtestant\", new h(l.RussianProtestant)), n(h, \"RussianOrthodox\", new h(l.RussianOrthodox));\nlet c = h;\nfunction E(t, e) {\n const s = e[0];\n for (let r = 1; r < e.length; r++)\n t = t.split(e[r]).join(s);\n return t.split(s);\n}\nvar D = /* @__PURE__ */ ((t) => (t[t.Valid = 0] = \"Valid\", t[t.UnknownVersification = 1] = \"UnknownVersification\", t[t.OutOfRange = 2] = \"OutOfRange\", t[t.VerseOutOfOrder = 3] = \"VerseOutOfOrder\", t[t.VerseRepeated = 4] = \"VerseRepeated\", t))(D || {});\nconst i = class i {\n constructor(e, s, r, a) {\n /** Not yet implemented. */\n n(this, \"firstChapter\");\n /** Not yet implemented. */\n n(this, \"lastChapter\");\n /** Not yet implemented. */\n n(this, \"lastVerse\");\n /** Not yet implemented. */\n n(this, \"hasSegmentsDefined\");\n /** Not yet implemented. */\n n(this, \"text\");\n /** Not yet implemented. */\n n(this, \"BBBCCCVVVS\");\n /** Not yet implemented. */\n n(this, \"longHashCode\");\n /** The versification of the reference. */\n n(this, \"versification\");\n n(this, \"rtlMark\", \"‏\");\n n(this, \"_bookNum\", 0);\n n(this, \"_chapterNum\", 0);\n n(this, \"_verseNum\", 0);\n n(this, \"_verse\");\n if (r == null && a == null)\n if (e != null && typeof e == \"string\") {\n const o = e, u = s != null && s instanceof c ? s : void 0;\n this.setEmpty(u), this.parse(o);\n } else if (e != null && typeof e == \"number\") {\n const o = s != null && s instanceof c ? s : void 0;\n this.setEmpty(o), this._verseNum = e % i.chapterDigitShifter, this._chapterNum = Math.floor(\n e % i.bookDigitShifter / i.chapterDigitShifter\n ), this._bookNum = Math.floor(e / i.bookDigitShifter);\n } else if (s == null)\n if (e != null && e instanceof i) {\n const o = e;\n this._bookNum = o.bookNum, this._chapterNum = o.chapterNum, this._verseNum = o.verseNum, this._verse = o.verse, this.versification = o.versification;\n } else {\n if (e == null) return;\n const o = e instanceof c ? e : i.defaultVersification;\n this.setEmpty(o);\n }\n else\n throw new Error(\"VerseRef constructor not supported.\");\n else if (e != null && s != null && r != null)\n if (typeof e == \"string\" && typeof s == \"string\" && typeof r == \"string\")\n this.setEmpty(a), this.updateInternal(e, s, r);\n else if (typeof e == \"number\" && typeof s == \"number\" && typeof r == \"number\")\n this._bookNum = e, this._chapterNum = s, this._verseNum = r, this.versification = a ?? i.defaultVersification;\n else\n throw new Error(\"VerseRef constructor not supported.\");\n else\n throw new Error(\"VerseRef constructor not supported.\");\n }\n /**\n * Determines if the verse string is in a valid format (does not consider versification).\n */\n static isVerseParseable(e) {\n return e.length > 0 && \"0123456789\".includes(e[0]) && !e.endsWith(this.verseRangeSeparator) && !e.endsWith(this.verseSequenceIndicator);\n }\n /**\n * Tries to parse the specified string into a verse reference.\n * @param str - The string to attempt to parse.\n * @returns success: `true` if the specified string was successfully parsed, `false` otherwise.\n * @returns verseRef: The result of the parse if successful, or empty VerseRef if it failed\n */\n static tryParse(e) {\n let s;\n try {\n return s = new i(e), { success: !0, verseRef: s };\n } catch (r) {\n if (r instanceof v)\n return s = new i(), { success: !1, verseRef: s };\n throw r;\n }\n }\n /**\n * Gets the reference as a comparable integer where the book, chapter, and verse each occupy 3\n * digits.\n * @param bookNum - Book number (this is 1-based, not an index).\n * @param chapterNum - Chapter number.\n * @param verseNum - Verse number.\n * @returns The reference as a comparable integer where the book, chapter, and verse each occupy 3\n * digits.\n */\n static getBBBCCCVVV(e, s, r) {\n return e % i.bcvMaxValue * i.bookDigitShifter + (s >= 0 ? s % i.bcvMaxValue * i.chapterDigitShifter : 0) + (r >= 0 ? r % i.bcvMaxValue : 0);\n }\n /**\n * Deserializes a serialized VerseRef.\n * @param serializedVerseRef - Serialized VerseRef to create from.\n * @returns the deserialized VerseRef.\n */\n static fromJSON(e) {\n const { book: s, chapterNum: r, verseNum: a, verse: o, versificationStr: u } = e, f = o || a.toString();\n let d;\n return u && (d = new c(u)), s ? new i(s, r.toString(), f, d) : new i();\n }\n /**\n * Parses a verse string and gets the leading numeric portion as a number.\n * @param verseStr - verse string to parse\n * @returns true if the entire string could be parsed as a single, simple verse number (1-999);\n * false if the verse string represented a verse bridge, contained segment letters, or was invalid\n */\n static tryGetVerseNum(e) {\n let s;\n if (!e)\n return s = -1, { success: !0, vNum: s };\n s = 0;\n let r;\n for (let a = 0; a < e.length; a++) {\n if (r = e[a], r < \"0\" || r > \"9\")\n return a === 0 && (s = -1), { success: !1, vNum: s };\n if (s = s * 10 + +r - 0, s > i.bcvMaxValue)\n return s = -1, { success: !1, vNum: s };\n }\n return { success: !0, vNum: s };\n }\n /**\n * Checks to see if a VerseRef hasn't been set - all values are the default.\n */\n get isDefault() {\n return this.bookNum === 0 && this.chapterNum === 0 && this.verseNum === 0 && this.versification == null;\n }\n /**\n * Gets whether the verse contains multiple verses.\n */\n get hasMultiple() {\n return this._verse != null && (this._verse.includes(i.verseRangeSeparator) || this._verse.includes(i.verseSequenceIndicator));\n }\n /**\n * Gets or sets the book of the reference. Book is the 3-letter abbreviation in capital letters,\n * e.g. `'MAT'`.\n */\n get book() {\n return m.bookNumberToId(this.bookNum, \"\");\n }\n set book(e) {\n this.bookNum = m.bookIdToNumber(e);\n }\n /**\n * Gets or sets the chapter of the reference,. e.g. `'3'`.\n */\n get chapter() {\n return this.isDefault || this._chapterNum < 0 ? \"\" : this._chapterNum.toString();\n }\n set chapter(e) {\n const s = +e;\n this._chapterNum = Number.isInteger(s) ? s : -1;\n }\n /**\n * Gets or sets the verse of the reference, including range, segments, and sequences, e.g. `'4'`,\n * or `'4b-5a, 7'`.\n */\n get verse() {\n return this._verse != null ? this._verse : this.isDefault || this._verseNum < 0 ? \"\" : this._verseNum.toString();\n }\n set verse(e) {\n const { success: s, vNum: r } = i.tryGetVerseNum(e);\n this._verse = s ? void 0 : e.replace(this.rtlMark, \"\"), this._verseNum = r, !(this._verseNum >= 0) && ({ vNum: this._verseNum } = i.tryGetVerseNum(this._verse));\n }\n /**\n * Get or set Book based on book number, e.g. `42`.\n */\n get bookNum() {\n return this._bookNum;\n }\n set bookNum(e) {\n if (e <= 0 || e > m.lastBook)\n throw new v(\n \"BookNum must be greater than zero and less than or equal to last book\"\n );\n this._bookNum = e;\n }\n /**\n * Gets or sets the chapter number, e.g. `3`. `-1` if not valid.\n */\n get chapterNum() {\n return this._chapterNum;\n }\n set chapterNum(e) {\n this.chapterNum = e;\n }\n /**\n * Gets or sets verse start number, e.g. `4`. `-1` if not valid.\n */\n get verseNum() {\n return this._verseNum;\n }\n set verseNum(e) {\n this._verseNum = e;\n }\n /**\n * String representing the versification (should ONLY be used for serialization/deserialization).\n *\n * @remarks This is for backwards compatibility when ScrVers was an enumeration.\n */\n get versificationStr() {\n var e;\n return (e = this.versification) == null ? void 0 : e.name;\n }\n set versificationStr(e) {\n this.versification = this.versification != null ? new c(e) : void 0;\n }\n /**\n * Determines if the reference is valid.\n */\n get valid() {\n return this.validStatus === 0;\n }\n /**\n * Get the valid status for this reference.\n */\n get validStatus() {\n return this.validateVerse(i.verseRangeSeparators, i.verseSequenceIndicators);\n }\n /**\n * Gets the reference as a comparable integer where the book,\n * chapter, and verse each occupy three digits and the verse is 0.\n */\n get BBBCCC() {\n return i.getBBBCCCVVV(this._bookNum, this._chapterNum, 0);\n }\n /**\n * Gets the reference as a comparable integer where the book,\n * chapter, and verse each occupy three digits. If verse is not null\n * (i.e., this reference represents a complex reference with verse\n * segments or bridge) this cannot be used for an exact comparison.\n */\n get BBBCCCVVV() {\n return i.getBBBCCCVVV(this._bookNum, this._chapterNum, this._verseNum);\n }\n /**\n * Gets whether the verse is defined as an excluded verse in the versification.\n * Does not handle verse ranges.\n */\n // eslint-disable-next-line @typescript-eslint/class-literal-property-style\n get isExcluded() {\n return !1;\n }\n /**\n * Parses the reference in the specified string.\n * Optionally versification can follow reference as in GEN 3:11/4\n * Throw an exception if\n * - invalid book name\n * - chapter number is missing or not a number\n * - verse number is missing or does not start with a number\n * - versification is invalid\n * @param verseStr - string to parse e.g. 'MAT 3:11'\n */\n parse(e) {\n if (e = e.replace(this.rtlMark, \"\"), e.includes(\"/\")) {\n const o = e.split(\"/\");\n if (e = o[0], o.length > 1)\n try {\n const u = +o[1].trim();\n this.versification = new c(l[u]);\n } catch {\n throw new v(\"Invalid reference : \" + e);\n }\n }\n const s = e.trim().split(\" \");\n if (s.length !== 2)\n throw new v(\"Invalid reference : \" + e);\n const r = s[1].split(\":\"), a = +r[0];\n if (r.length !== 2 || m.bookIdToNumber(s[0]) === 0 || !Number.isInteger(a) || a < 0 || !i.isVerseParseable(r[1]))\n throw new v(\"Invalid reference : \" + e);\n this.updateInternal(s[0], r[0], r[1]);\n }\n /**\n * Simplifies this verse ref so that it has no bridging of verses or\n * verse segments like `'1a'`.\n */\n simplify() {\n this._verse = void 0;\n }\n /**\n * Makes a clone of the reference.\n *\n * @returns The cloned VerseRef.\n */\n clone() {\n return new i(this);\n }\n toString() {\n const e = this.book;\n return e === \"\" ? \"\" : `${e} ${this.chapter}:${this.verse}`;\n }\n toJSON() {\n let e = this.verse;\n (e === \"\" || e === this.verseNum.toString()) && (e = void 0);\n const s = {\n book: this.book,\n chapterNum: this.chapterNum,\n verseNum: this.verseNum,\n verse: e,\n versificationStr: this.versificationStr\n };\n return e || delete s.verse, s;\n }\n /**\n * Compares this `VerseRef` with supplied one.\n * @param verseRef - object to compare this one to.\n * @returns `true` if this `VerseRef` is equal to the supplied one, `false` otherwise.\n */\n equals(e) {\n return e instanceof i ? e._bookNum === this._bookNum && e._chapterNum === this._chapterNum && e._verseNum === this._verseNum && e.verse === this.verse && (e.versification == null && this.versification == null || e.versification != null && this.versification != null && e.versification.equals(this.versification)) : !1;\n }\n /**\n * Enumerate all individual verses contained in a VerseRef.\n * Verse ranges are indicated by \"-\" and consecutive verses by \",\"s.\n * Examples:\n * GEN 1:2 returns GEN 1:2\n * GEN 1:1a-3b,5 returns GEN 1:1a, GEN 1:2, GEN 1:3b, GEN 1:5\n * GEN 1:2a-2c returns //! ??????\n *\n * @param specifiedVersesOnly - if set to true return only verses that are\n * explicitly specified only, not verses within a range. Defaults to `false`.\n * @param verseRangeSeparators - Verse range separators.\n * Defaults to `VerseRef.verseRangeSeparators`.\n * @param verseSequenceSeparators - Verse sequence separators.\n * Defaults to `VerseRef.verseSequenceIndicators`.\n * @returns An array of all single verse references in this VerseRef.\n */\n allVerses(e = !1, s = i.verseRangeSeparators, r = i.verseSequenceIndicators) {\n if (this._verse == null || this.chapterNum <= 0)\n return [this.clone()];\n const a = [], o = E(this._verse, r);\n for (const u of o.map((f) => E(f, s))) {\n const f = this.clone();\n f.verse = u[0];\n const d = f.verseNum;\n if (a.push(f), u.length > 1) {\n const b = this.clone();\n if (b.verse = u[1], !e)\n for (let p = d + 1; p < b.verseNum; p++) {\n const J = new i(\n this._bookNum,\n this._chapterNum,\n p,\n this.versification\n );\n this.isExcluded || a.push(J);\n }\n a.push(b);\n }\n }\n return a;\n }\n /**\n * Validates a verse number using the supplied separators rather than the defaults.\n */\n validateVerse(e, s) {\n if (!this.verse)\n return this.internalValid;\n let r = 0;\n for (const a of this.allVerses(!0, e, s)) {\n const o = a.internalValid;\n if (o !== 0)\n return o;\n const u = a.BBBCCCVVV;\n if (r > u)\n return 3;\n if (r === u)\n return 4;\n r = u;\n }\n return 0;\n }\n /**\n * Gets whether a single verse reference is valid.\n */\n get internalValid() {\n return this.versification == null ? 1 : this._bookNum <= 0 || this._bookNum > m.lastBook ? 2 : (m.isCanonical(this._bookNum), 0);\n }\n setEmpty(e = i.defaultVersification) {\n this._bookNum = 0, this._chapterNum = -1, this._verse = void 0, this.versification = e;\n }\n updateInternal(e, s, r) {\n this.bookNum = m.bookIdToNumber(e), this.chapter = s, this.verse = r;\n }\n};\nn(i, \"defaultVersification\", c.English), n(i, \"verseRangeSeparator\", \"-\"), n(i, \"verseSequenceIndicator\", \",\"), n(i, \"verseRangeSeparators\", [i.verseRangeSeparator]), n(i, \"verseSequenceIndicators\", [i.verseSequenceIndicator]), n(i, \"chapterDigitShifter\", 1e3), n(i, \"bookDigitShifter\", i.chapterDigitShifter * i.chapterDigitShifter), n(i, \"bcvMaxValue\", i.chapterDigitShifter - 1), /**\n * The valid status of the VerseRef.\n */\nn(i, \"ValidStatusType\", D);\nlet M = i;\nclass v extends Error {\n}\nexport {\n _ as BookSet,\n m as Canon,\n c as ScrVers,\n l as ScrVersType,\n M as VerseRef,\n v as VerseRefException\n};\n//# sourceMappingURL=index.es.js.map\n","import React from 'react';\nimport * as DropdownMenuPrimitive from '@radix-ui/react-dropdown-menu';\nimport { Check, ChevronRight, Circle } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport const DropdownMenu = DropdownMenuPrimitive.Root;\n\nexport const DropdownMenuTrigger = DropdownMenuPrimitive.Trigger;\n\nexport const DropdownMenuGroup = DropdownMenuPrimitive.Group;\n\nexport const DropdownMenuPortal = DropdownMenuPrimitive.Portal;\n\nexport const DropdownMenuSub = DropdownMenuPrimitive.Sub;\n\nexport const DropdownMenuRadioGroup = DropdownMenuPrimitive.RadioGroup;\n\nexport type DropdownMenuSubTriggerProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.SubTrigger\n> & {\n className?: string;\n inset?: boolean;\n};\n\nexport type DropdownMenuSubContentProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.SubContent\n> & {\n className?: string;\n};\n\nexport type DropdownMenuContentProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Content\n> & {\n className?: string;\n sideOffset?: number;\n};\n\nexport type DropdownMenuItemProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Item\n> & {\n className?: string;\n inset?: boolean;\n};\n\nexport type DropdownMenuCheckboxItemProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.CheckboxItem\n> & {\n className?: string;\n checked?: boolean;\n};\n\nexport type DropdownMenuRadioItemProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.RadioItem\n> & {\n className?: string;\n};\n\nexport type DropdownMenuLabelProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Label\n> & {\n className?: string;\n inset?: boolean;\n};\n\nexport type DropdownMenuSeparatorProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Separator\n> & {\n className?: string;\n};\n\nexport type DropdownMenuShortcutProps = React.HTMLAttributes & {\n className?: string;\n};\n\nexport const DropdownMenuSubTrigger = React.forwardRef<\n React.ElementRef,\n DropdownMenuSubTriggerProps\n>(({ className, inset, children, ...props }, ref) => (\n \n {children}\n \n \n));\nDropdownMenuSubTrigger.displayName = DropdownMenuPrimitive.SubTrigger.displayName;\n\nexport const DropdownMenuSubContent = React.forwardRef<\n React.ElementRef,\n DropdownMenuSubContentProps\n>(({ className, ...props }, ref) => (\n \n));\nDropdownMenuSubContent.displayName = DropdownMenuPrimitive.SubContent.displayName;\n\nexport const DropdownMenuContent = React.forwardRef<\n React.ElementRef,\n DropdownMenuContentProps\n>(({ className, sideOffset = 4, ...props }, ref) => (\n \n \n \n));\nDropdownMenuContent.displayName = DropdownMenuPrimitive.Content.displayName;\n\n/**\n * TODO: fix: direction is not automatically handled by this component, so that shortcuts are\n * display always to the right\n */\nexport const DropdownMenuItem = React.forwardRef<\n React.ElementRef,\n DropdownMenuItemProps\n>(({ className, inset, ...props }, ref) => (\n \n));\nDropdownMenuItem.displayName = DropdownMenuPrimitive.Item.displayName;\n\nexport const DropdownMenuCheckboxItem = React.forwardRef<\n React.ElementRef,\n DropdownMenuCheckboxItemProps\n>(({ className, children, checked, ...props }, ref) => (\n \n \n \n \n \n \n {children}\n \n));\nDropdownMenuCheckboxItem.displayName = DropdownMenuPrimitive.CheckboxItem.displayName;\n\nexport const DropdownMenuRadioItem = React.forwardRef<\n React.ElementRef,\n DropdownMenuRadioItemProps\n>(({ className, children, ...props }, ref) => (\n \n \n \n \n \n \n {children}\n \n));\nDropdownMenuRadioItem.displayName = DropdownMenuPrimitive.RadioItem.displayName;\n\nexport const DropdownMenuLabel = React.forwardRef<\n React.ElementRef,\n DropdownMenuLabelProps\n>(({ className, inset, ...props }, ref) => (\n \n));\nDropdownMenuLabel.displayName = DropdownMenuPrimitive.Label.displayName;\n\nexport const DropdownMenuSeparator = React.forwardRef<\n React.ElementRef,\n DropdownMenuSeparatorProps\n>(({ className, ...props }, ref) => (\n \n));\nDropdownMenuSeparator.displayName = DropdownMenuPrimitive.Separator.displayName;\n\nexport function DropdownMenuShortcut({ className, ...props }: DropdownMenuShortcutProps) {\n return (\n \n );\n}\nDropdownMenuShortcut.displayName = 'DropdownMenuShortcut';\n","import { Canon } from '@sillsdev/scripture';\nimport { PropsWithChildren, KeyboardEvent, forwardRef } from 'react';\nimport { DropdownMenuItem as ShadDropdownMenuItem } from '@/components/shadcn-ui/dropdown-menu';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport type BookType = 'OT' | 'NT' | 'DC';\n\ntype BookMenuItemProps = PropsWithChildren<{\n /** String id of book */\n bookId: string;\n /** Callback to run when a book menu item is selected */\n handleSelectBook: () => void;\n /** Indicates if this menu item is currently selected */\n isSelected: boolean;\n /** Function that is called upon highlighting a book in the dropdown menu */\n handleHighlightBook: () => void;\n /**\n * Function that is called on pressing a key\n *\n * @param event Event that contains information about the key stroke\n */\n handleKeyDown: (event: KeyboardEvent) => void;\n /**\n * Type of book associated with this menu item, coordinates color labels ? Mock up has the labels\n * coordinated to genre\n */\n bookType: BookType;\n}>;\n\nconst BookMenuItem = forwardRef(\n (\n {\n bookId,\n handleSelectBook,\n isSelected,\n handleHighlightBook,\n handleKeyDown,\n bookType,\n children,\n }: BookMenuItemProps,\n ref,\n ) => {\n return (\n {\n // preventDefault() here prevents the entire dropdown menu from closing when selecting this item\n event.preventDefault();\n handleSelectBook();\n }}\n onKeyDown={(event: KeyboardEvent) => {\n handleKeyDown(event);\n }}\n onFocus={handleHighlightBook}\n onMouseMove={handleHighlightBook}\n >\n \n {Canon.bookIdToEnglishName(bookId)}\n \n {isSelected &&
    {children}
    }\n \n );\n },\n);\n\nexport default BookMenuItem;\n","import { cn } from '@/utils/shadcn-ui.util';\nimport { useCallback } from 'react';\n\nexport type ChapterSelectProps = {\n /**\n * Callback to run when a chapter div is selected\n *\n * @param chapterNumber Number of the chapter that has been selected\n */\n handleSelectChapter: (chapterNumber: number) => void;\n /** The highest chapter number in the book (of course equal to number of chapters in the book) */\n endChapter: number;\n /** The chapter number that is currently selected */\n activeChapter: number;\n /** The chapter number that is currently highlighted using keyboard or mouse navigation */\n highlightedChapter: number;\n /**\n * Callback to run when a chapter is highlighted by the user\n *\n * @param chapterNumber The chapter that is highlighted\n */\n handleHighlightedChapter: (chapterNumber: number) => void;\n};\n\nfunction ChapterSelect({\n handleSelectChapter,\n endChapter,\n activeChapter,\n highlightedChapter,\n handleHighlightedChapter,\n}: ChapterSelectProps) {\n const chapters = Array.from({ length: endChapter }, (_, i) => i + 1);\n\n const handleMouse = useCallback(\n (chapterNumber: number) => {\n handleHighlightedChapter(chapterNumber);\n },\n [handleHighlightedChapter],\n );\n\n return (\n
    \n {chapters.map((chapter) => (\n {\n event.preventDefault();\n event.stopPropagation();\n handleSelectChapter(chapter);\n }}\n role=\"button\"\n onKeyDown={(event) => {\n if (event.key === 'Enter') {\n handleSelectChapter(chapter);\n }\n }}\n tabIndex={0}\n onMouseMove={() => handleMouse(chapter)}\n >\n {chapter}\n
    \n ))}\n
    \n );\n}\n\nexport default ChapterSelect;\n","import { DropdownMenuLabel as ShadDropdownMenuLabel } from '@/components/shadcn-ui/dropdown-menu';\nimport { Bookmark, Clock, ArrowDownWideNarrow } from 'lucide-react';\n\nexport type GoToMenuItemProps = {\n handleSort: () => void;\n handleLocationHistory: () => void;\n handleBookmarks: () => void;\n};\n\nfunction GoToMenuItem({ handleSort, handleLocationHistory, handleBookmarks }: GoToMenuItemProps) {\n return (\n \n

    Go To

    \n
    \n \n \n \n
    \n
    \n );\n}\n\nexport default GoToMenuItem;\n","import BookChapterInput from '@/components/advanced/book-chapter-control/book-chapter-input.component';\nimport BookMenuItem, {\n BookType,\n} from '@/components/advanced/book-chapter-control/book-menu-item.component';\nimport ChapterSelect from '@/components/advanced/book-chapter-control/chapter-select.component';\nimport GoToMenuItem from '@/components/advanced/book-chapter-control/go-to-menu-item.component';\nimport {\n DropdownMenu as ShadDropdownMenu,\n DropdownMenuContent as ShadDropdownMenuContent,\n DropdownMenuLabel as ShadDropdownMenuLabel,\n DropdownMenuSeparator as ShadDropdownMenuSeparator,\n DropdownMenuTrigger as ShadDropdownMenuTrigger,\n} from '@/components/shadcn-ui/dropdown-menu';\nimport { Canon } from '@sillsdev/scripture';\nimport { ScriptureReference, getChaptersForBook } from 'platform-bible-utils';\nimport {\n KeyboardEvent as ReactKeyboardEvent,\n useCallback,\n useEffect,\n useLayoutEffect,\n useRef,\n useState,\n} from 'react';\n\ntype BookTypeLabels = {\n [bookType in BookType]: string;\n};\ntype BookChapterControlProps = {\n scrRef: ScriptureReference;\n handleSubmit: (scrRef: ScriptureReference) => void;\n};\n\nconst ALL_BOOK_IDS = Canon.allBookIds;\nconst BOOK_TYPE_LABELS: BookTypeLabels = {\n OT: 'Old Testament',\n NT: 'New Testament',\n DC: 'Deuterocanon',\n};\nconst BOOK_TYPE_ARRAY: BookType[] = ['OT', 'NT', 'DC'];\n// This is the height of three menu items to offset scrolling to the selected menu item\n// If you use menuItemRef.clientHeight- includes height of chapter div which is too big\nconst SCROLL_OFFSET = 32 + 32 + 32;\nconst SEARCH_QUERY_FORMATS = [\n /^(\\w+)$/i, // Matches a single word (book name or id)\n /^(\\w+)(?:\\s(\\d+))$/i, // Matches a word followed by a chapter number\n /^(\\w+)(?:\\s(\\d+):(\\d+))$/i, // Matches a word followed by a chapter and verse number\n];\nconst fetchGroupedBooks = (bookType: BookType) => {\n const groupedBooks = {\n OT: ALL_BOOK_IDS.filter((bookId) => Canon.isBookOT(bookId)),\n NT: ALL_BOOK_IDS.filter((bookId) => Canon.isBookNT(bookId)),\n DC: ALL_BOOK_IDS.filter((bookId) => Canon.isBookDC(bookId)),\n };\n return groupedBooks[bookType];\n};\nconst fetchEndChapter = (bookId: string) => {\n // getChaptersForBook returns -1 if not found in scrBookData\n // scrBookData only includes OT and NT, so all DC will return -1\n return getChaptersForBook(Canon.bookIdToNumber(bookId));\n};\n\n/**\n * Gets all of the English names from book ids\n *\n * @returns String[]\n */\nfunction getAllEnglishNames(): string[] {\n const allEnglishNames = ALL_BOOK_IDS.map((bookId) => {\n return Canon.bookIdToEnglishName(bookId);\n });\n return allEnglishNames;\n}\n\n/**\n * Determines if bookName is in allEnglishNames\n *\n * @param bookName Book English name\n * @returns True if bookName is included, false otherwise\n */\nfunction isValidBookEnglishName(bookName: string): boolean {\n return getAllEnglishNames().includes(bookName);\n}\n\n/**\n * Gets a bookId from given English name\n *\n * @param bookName Book English name\n * @returns BookId of provided bookName, undefined otherwise\n */\nfunction getBookIdFromEnglishName(bookName: string): string | undefined {\n // Convert bookName to lowercase and then capitalize the first letter\n const formattedBookName = bookName.toLowerCase().replace(/^\\w/, (c) => c.toUpperCase());\n\n if (isValidBookEnglishName(formattedBookName)) {\n const matchingBookId = ALL_BOOK_IDS.find((bookId) => {\n return Canon.bookIdToEnglishName(bookId) === formattedBookName;\n });\n return matchingBookId;\n }\n\n return undefined;\n}\n\nfunction BookChapterControl({ scrRef, handleSubmit }: BookChapterControlProps) {\n const [searchQuery, setSearchQuery] = useState('');\n const [selectedBookId, setSelectedBookId] = useState(\n Canon.bookNumberToId(scrRef.bookNum),\n );\n const [highlightedChapter, setHighlightedChapter] = useState(scrRef.chapterNum ?? 0);\n const [highlightedBookId, setHighlightedBookId] = useState(\n Canon.bookNumberToId(scrRef.bookNum),\n );\n const [isContentOpen, setIsContentOpen] = useState(false);\n const [isContentOpenDelayed, setIsContentOpenDelayed] = useState(isContentOpen);\n\n // This ref will always be defined\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const inputRef = useRef(undefined!);\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const contentRef = useRef(undefined!);\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const menuItemRef = useRef(undefined!);\n\n const fetchFilteredBooks = useCallback(\n (bookType: BookType) => {\n return fetchGroupedBooks(bookType).filter((bookId: string) => {\n const englishNameLowerCase = Canon.bookIdToEnglishName(bookId).toLowerCase();\n const normalizedQuery = searchQuery.replace(/[^a-zA-Z]/g, '').toLowerCase();\n return (\n englishNameLowerCase.includes(normalizedQuery) || // Match book name\n bookId.toLowerCase().includes(normalizedQuery) // Match book ID\n );\n });\n },\n [searchQuery],\n );\n\n const handleSearchInput = (searchString: string) => {\n setSearchQuery(searchString);\n };\n\n /**\n * Whether to prevent radix's logic from closing the dropdown. This is important because radix\n * tries to close the dropdown when the input first focuses, and we don't want it to do that. But\n * we don't want to prevent the dropdown from closing when we click away from the input, so we\n * don't want to just keep it open if the input is focused\n */\n const shouldPreventAutoClosing = useRef(false);\n\n const controlMenuState = useCallback((open: boolean) => {\n if (shouldPreventAutoClosing.current) {\n shouldPreventAutoClosing.current = false;\n return;\n }\n setIsContentOpen(open);\n }, []);\n\n const updateReference = useCallback(\n (bookId: string, shouldClose: boolean, chapter?: number, verse?: number) => {\n setHighlightedChapter(\n Canon.bookNumberToId(scrRef.bookNum) !== bookId ? 1 : scrRef.chapterNum,\n );\n\n if (shouldClose || fetchEndChapter(bookId) === -1) {\n handleSubmit({\n bookNum: Canon.bookIdToNumber(bookId),\n chapterNum: chapter || 1,\n verseNum: verse || 1,\n });\n\n setIsContentOpen(false);\n setSearchQuery('');\n return;\n }\n\n setSelectedBookId(selectedBookId !== bookId ? bookId : '');\n setIsContentOpen(!shouldClose);\n },\n [handleSubmit, scrRef.bookNum, scrRef.chapterNum, selectedBookId],\n );\n\n const handleSelectChapter = (chapterNumber: number) => {\n if (chapterNumber <= 0 || chapterNumber > fetchEndChapter(selectedBookId)) {\n return;\n }\n updateReference(selectedBookId, true, chapterNumber);\n };\n\n const handleInputSubmit = useCallback(() => {\n SEARCH_QUERY_FORMATS.forEach((format) => {\n const matches = searchQuery.match(format);\n if (matches) {\n // Book should be a bookId or an english name\n const [book, chapter = undefined, verse = undefined] = matches.slice(1);\n const englishName = getBookIdFromEnglishName(book);\n\n if (Canon.isBookIdValid(book) || englishName) {\n updateReference(\n englishName ?? book,\n true,\n chapter ? parseInt(chapter, 10) : 1,\n verse ? parseInt(verse, 10) : 1,\n );\n }\n }\n });\n }, [updateReference, searchQuery]);\n\n const handleKeyDownInput = useCallback(\n (event: ReactKeyboardEvent) => {\n if (!isContentOpen) {\n setIsContentOpen(true);\n } else if (event.key === 'ArrowDown' || event.key === 'ArrowUp') {\n if (\n typeof menuItemRef !== 'undefined' &&\n // Ref uses null\n // eslint-disable-next-line no-null/no-null\n menuItemRef.current !== null\n ) {\n menuItemRef.current.focus();\n } else if (\n typeof contentRef !== 'undefined' &&\n // Ref uses null\n // eslint-disable-next-line no-null/no-null\n contentRef.current !== null\n ) {\n contentRef.current.focus();\n }\n event.preventDefault();\n }\n },\n [isContentOpen],\n );\n\n const handleKeyDownContent = (event: ReactKeyboardEvent) => {\n // When the dropdown menu has focus, key strokes should give focus to the input component,\n // unless they're navigation keys (arrows and enter)\n const { key } = event;\n if (\n key === 'ArrowRight' ||\n key === 'ArrowLeft' ||\n key === 'ArrowDown' ||\n key === 'ArrowUp' ||\n key === 'Enter'\n ) {\n return;\n }\n\n inputRef.current.dispatchEvent(new KeyboardEvent('keydown', { key }));\n inputRef.current.focus();\n };\n\n const handleKeyDownMenuItem = (event: ReactKeyboardEvent) => {\n const { key } = event;\n if (highlightedBookId === selectedBookId) {\n if (key === 'Enter') {\n event.preventDefault();\n updateReference(selectedBookId, true, highlightedChapter);\n return;\n }\n\n let chapterOffSet = 0;\n if (key === 'ArrowRight') {\n if (highlightedChapter < fetchEndChapter(highlightedBookId)) {\n chapterOffSet = 1;\n } else {\n event.preventDefault();\n return;\n }\n } else if (key === 'ArrowLeft') {\n if (highlightedChapter > 1) {\n chapterOffSet = -1;\n } else {\n event.preventDefault();\n return;\n }\n } else if (key === 'ArrowDown') {\n chapterOffSet = 6;\n } else if (key === 'ArrowUp') {\n chapterOffSet = -6;\n }\n if (\n highlightedChapter + chapterOffSet <= 0 ||\n highlightedChapter + chapterOffSet > fetchEndChapter(highlightedBookId)\n ) {\n setHighlightedChapter(0);\n } else if (chapterOffSet !== 0) {\n setHighlightedChapter(highlightedChapter + chapterOffSet);\n event.preventDefault();\n }\n }\n };\n\n useEffect(() => {\n if (selectedBookId === highlightedBookId) {\n if (selectedBookId === Canon.bookNumberToId(scrRef.bookNum)) {\n setHighlightedChapter(scrRef.chapterNum);\n } else {\n setHighlightedChapter(1);\n }\n } else {\n setHighlightedChapter(0);\n }\n }, [highlightedBookId, scrRef.bookNum, scrRef.chapterNum, selectedBookId]);\n\n // The purpose of these useLayoutEffects and timeout is to delay the scroll just\n // enough so that the refs are defined and available when they are used after the timeout\n useLayoutEffect(() => {\n setIsContentOpenDelayed(isContentOpen);\n }, [isContentOpen]);\n\n useLayoutEffect(() => {\n const scrollTimeout = setTimeout(() => {\n if (isContentOpenDelayed && contentRef.current && menuItemRef.current) {\n const menuItemOffsetTop = menuItemRef.current.offsetTop;\n const scrollPosition = menuItemOffsetTop - SCROLL_OFFSET;\n contentRef.current.scrollTo({ top: scrollPosition, behavior: 'instant' });\n }\n }, 10);\n return () => {\n clearTimeout(scrollTimeout);\n };\n }, [isContentOpenDelayed]);\n\n return (\n
    \n \n \n {\n setSelectedBookId(Canon.bookNumberToId(scrRef.bookNum));\n setHighlightedBookId(Canon.bookNumberToId(scrRef.bookNum));\n setHighlightedChapter(scrRef.chapterNum > 0 ? scrRef.chapterNum : 0);\n setIsContentOpen(true);\n inputRef.current.focus();\n }}\n onFocus={() => {\n // Radix thinks we want to close because the input is being focused. Prevent that\n shouldPreventAutoClosing.current = true;\n }}\n handleSubmit={handleInputSubmit}\n placeholder={`${Canon.bookNumberToEnglishName(scrRef.bookNum)} ${scrRef.chapterNum}:${scrRef.verseNum}`}\n />\n \n \n console.log('sorting')}\n handleLocationHistory={() => console.log('location history')}\n handleBookmarks={() => console.log('bookmarks')}\n />\n {BOOK_TYPE_ARRAY.map(\n (bookType, bookTypeIndex) =>\n fetchFilteredBooks(bookType).length > 0 && (\n
    \n \n {BOOK_TYPE_LABELS[bookType]}\n \n\n {fetchFilteredBooks(bookType).map((bookId) => (\n
    \n updateReference(bookId, false)}\n isSelected={selectedBookId === bookId}\n handleHighlightBook={() => setHighlightedBookId(bookId)}\n handleKeyDown={handleKeyDownMenuItem}\n bookType={bookType}\n ref={(element: HTMLDivElement) => {\n if (selectedBookId === bookId) menuItemRef.current = element;\n }}\n >\n {\n setHighlightedChapter(chapterNumber);\n }}\n />\n \n
    \n ))}\n {BOOK_TYPE_ARRAY.length - 1 !== bookTypeIndex ? (\n \n ) : undefined}\n
    \n ),\n )}\n \n
    \n
    \n );\n}\n\nexport default BookChapterControl;\n","import React from 'react';\nimport { Slot } from '@radix-ui/react-slot';\nimport { cva, type VariantProps } from 'class-variance-authority';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport const buttonVariants = cva(\n 'pr-twp tw-inline-flex tw-items-center tw-justify-center tw-whitespace-nowrap tw-rounded-md tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-colors focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50',\n {\n variants: {\n variant: {\n default: 'tw-bg-primary tw-text-primary-foreground hover:tw-bg-primary/90',\n destructive: 'tw-bg-destructive tw-text-destructive-foreground hover:tw-bg-destructive/90',\n outline:\n 'tw-border tw-border-input tw-bg-background hover:tw-bg-accent hover:tw-text-accent-foreground',\n secondary: 'tw-bg-secondary tw-text-secondary-foreground hover:tw-bg-secondary/80',\n ghost: 'hover:tw-bg-accent hover:tw-text-accent-foreground',\n link: 'tw-text-primary tw-underline-offset-4 hover:tw-underline',\n },\n size: {\n default: 'tw-h-10 tw-px-4 tw-py-2',\n sm: 'tw-h-9 tw-rounded-md tw-px-3',\n lg: 'tw-h-11 tw-rounded-md tw-px-8',\n icon: 'tw-h-10 tw-w-10',\n },\n },\n defaultVariants: {\n variant: 'default',\n size: 'default',\n },\n },\n);\n\nexport interface ButtonProps\n extends React.ButtonHTMLAttributes,\n VariantProps {\n asChild?: boolean;\n}\n\nexport const Button = React.forwardRef(\n ({ className, variant, size, asChild = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'button';\n return (\n \n );\n },\n);\nButton.displayName = 'Button';\n","import React from 'react';\nimport * as LabelPrimitive from '@radix-ui/react-label';\nimport { cva, type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst labelVariants = cva(\n 'tw-text-sm tw-font-medium tw-leading-none peer-disabled:tw-cursor-not-allowed peer-disabled:tw-opacity-70',\n);\n\nexport const Label = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef & VariantProps\n>(({ className, ...props }, ref) => (\n \n));\nLabel.displayName = LabelPrimitive.Root.displayName;\n","import React from 'react';\nimport * as RadioGroupPrimitive from '@radix-ui/react-radio-group';\nimport { Circle } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst RadioGroup = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => {\n return (\n \n );\n});\nRadioGroup.displayName = RadioGroupPrimitive.Root.displayName;\n\nconst RadioGroupItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => {\n return (\n \n \n \n \n \n );\n});\nRadioGroupItem.displayName = RadioGroupPrimitive.Item.displayName;\n\nexport { RadioGroup, RadioGroupItem };\n","import React from 'react';\nimport * as PopoverPrimitive from '@radix-ui/react-popover';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Popover = PopoverPrimitive.Root;\n\nconst PopoverTrigger = PopoverPrimitive.Trigger;\n\nconst PopoverContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, align = 'center', sideOffset = 4, ...props }, ref) => (\n \n \n \n));\nPopoverContent.displayName = PopoverPrimitive.Content.displayName;\n\nexport { Popover, PopoverTrigger, PopoverContent };\n","import React from 'react';\nimport * as DialogPrimitive from '@radix-ui/react-dialog';\nimport { X } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Dialog = DialogPrimitive.Root;\n\nconst DialogTrigger = DialogPrimitive.Trigger;\n\nconst DialogPortal = DialogPrimitive.Portal;\n\nconst DialogClose = DialogPrimitive.Close;\n\nconst DialogOverlay = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nDialogOverlay.displayName = DialogPrimitive.Overlay.displayName;\n\nconst DialogContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, ...props }, ref) => (\n \n \n \n {children}\n \n \n Close\n \n \n \n));\nDialogContent.displayName = DialogPrimitive.Content.displayName;\n\nfunction DialogHeader({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nDialogHeader.displayName = 'DialogHeader';\n\nfunction DialogFooter({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nDialogFooter.displayName = 'DialogFooter';\n\nconst DialogTitle = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nDialogTitle.displayName = DialogPrimitive.Title.displayName;\n\nconst DialogDescription = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nDialogDescription.displayName = DialogPrimitive.Description.displayName;\n\nexport {\n Dialog,\n DialogPortal,\n DialogOverlay,\n DialogClose,\n DialogTrigger,\n DialogContent,\n DialogHeader,\n DialogFooter,\n DialogTitle,\n DialogDescription,\n};\n","import React from 'react';\nimport { type DialogProps } from '@radix-ui/react-dialog';\nimport { Command as CommandPrimitive } from 'cmdk';\nimport { Search } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Dialog, DialogContent } from '@/components/shadcn-ui/dialog';\n\nconst Command = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nCommand.displayName = CommandPrimitive.displayName;\n\ninterface CommandDialogProps extends DialogProps {}\n\nfunction CommandDialog({ children, ...props }: CommandDialogProps) {\n return (\n \n \n \n {children}\n \n \n \n );\n}\n\nconst CommandInput = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n
    \n \n \n
    \n));\n\nCommandInput.displayName = CommandPrimitive.Input.displayName;\n\nconst CommandList = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\n\nCommandList.displayName = CommandPrimitive.List.displayName;\n\nconst CommandEmpty = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>((props, ref) => (\n \n));\n\nCommandEmpty.displayName = CommandPrimitive.Empty.displayName;\n\nconst CommandGroup = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\n\nCommandGroup.displayName = CommandPrimitive.Group.displayName;\n\nconst CommandSeparator = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nCommandSeparator.displayName = CommandPrimitive.Separator.displayName;\n\nconst CommandItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\n\nCommandItem.displayName = CommandPrimitive.Item.displayName;\n\nfunction CommandShortcut({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nCommandShortcut.displayName = 'CommandShortcut';\n\nexport {\n Command,\n CommandDialog,\n CommandInput,\n CommandList,\n CommandEmpty,\n CommandGroup,\n CommandItem,\n CommandShortcut,\n CommandSeparator,\n};\n","import { useState } from 'react';\nimport { Check, ChevronsUpDown } from 'lucide-react';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport { Popover, PopoverContent, PopoverTrigger } from '@/components/shadcn-ui/popover';\nimport {\n Command,\n CommandEmpty,\n CommandInput,\n CommandItem,\n CommandList,\n} from '@/components/shadcn-ui/command';\nimport { PopoverProps } from '@radix-ui/react-popover';\n\nexport type ComboBoxLabelOption = { label: string };\nexport type ComboBoxOption = string | number | ComboBoxLabelOption;\n\nexport type ComboBoxProps = {\n /** Optional unique identifier */\n id?: string;\n /** Text label title for combobox */\n /** List of available options for the dropdown menu */\n options?: readonly T[];\n /** Additional css classes to help with unique styling of the combo box button */\n buttonClassName?: string;\n /** Additional css classes to help with unique styling of the combo box popover */\n popoverContentClassName?: string;\n /**\n * The selected value that the combo box currently holds. Must be shallow equal to one of the\n * options entries.\n */\n value?: T;\n /** Triggers when content of textfield is changed */\n onChange?: (newValue: T) => void;\n /** Used to determine the string value for a given option. */\n getOptionLabel?: (option: ComboBoxOption) => string;\n /** Text displayed on button if `value` is undefined */\n buttonPlaceholder?: string;\n /** Placeholder text for text field */\n textPlaceholder?: string;\n /** Text to display when no options match input */\n commandEmptyMessage?: string;\n /** Variant of button */\n buttonVariant?: ButtonProps['variant'];\n /** Text direction ltr or rtl */\n dir?: Direction;\n /** Optional boolean to set if trigger should be disabled */\n isDisabled?: boolean;\n} & PopoverProps;\n\ntype Direction = 'ltr' | 'rtl';\n\nfunction getOptionLabelDefault(option: ComboBoxOption): string {\n if (typeof option === 'string') {\n return option;\n }\n if (typeof option === 'number') {\n return option.toString();\n }\n return option.label;\n}\n\n/**\n * Autocomplete input and command palette with a list of suggestions.\n *\n * Thanks to Shadcn for heavy inspiration and documentation\n * https://ui.shadcn.com/docs/components/combobox\n */\nfunction ComboBox({\n id,\n options = [],\n buttonClassName,\n popoverContentClassName,\n value,\n onChange = () => {},\n getOptionLabel = getOptionLabelDefault,\n buttonPlaceholder = '',\n textPlaceholder = '',\n commandEmptyMessage = 'No option found',\n buttonVariant = 'outline',\n dir = 'ltr',\n isDisabled = false,\n ...props\n}: ComboBoxProps) {\n const [open, setOpen] = useState(false);\n\n return (\n \n \n \n \n {value ? getOptionLabel(value) : buttonPlaceholder}\n \n \n \n \n \n \n \n {commandEmptyMessage}\n \n {options.map((option) => (\n {\n onChange(option);\n setOpen(false);\n }}\n >\n \n {getOptionLabel(option)}\n \n ))}\n \n \n \n \n );\n}\n\nexport default ComboBox;\n","import { useMemo } from 'react';\nimport ComboBox from '@/components/basics/combo-box.component';\nimport { Label } from '@/components/shadcn-ui/label';\n\nexport type ChapterRangeSelectorProps = {\n startChapter: number;\n endChapter: number;\n handleSelectStartChapter: (chapter: number) => void;\n handleSelectEndChapter: (chapter: number) => void;\n isDisabled?: boolean;\n chapterCount: number;\n};\n\nexport default function ChapterRangeSelector({\n startChapter,\n endChapter,\n handleSelectStartChapter,\n handleSelectEndChapter,\n isDisabled = false,\n chapterCount,\n}: ChapterRangeSelectorProps) {\n const chapterOptions = useMemo(\n () => Array.from({ length: chapterCount }, (_, index) => index + 1),\n [chapterCount],\n );\n\n const onChangeStartChapter = (value: number) => {\n handleSelectStartChapter(value);\n if (value > endChapter) {\n handleSelectEndChapter(value);\n }\n };\n\n const onChangeEndChapter = (value: number) => {\n handleSelectEndChapter(value);\n if (value < startChapter) {\n handleSelectStartChapter(value);\n }\n };\n\n return (\n <>\n \n option.toString()}\n value={startChapter}\n />\n\n \n option.toString()}\n value={endChapter}\n />\n \n );\n}\n","import { Button } from '@/components/shadcn-ui/button';\nimport { Label } from '@/components/shadcn-ui/label';\nimport { RadioGroup, RadioGroupItem } from '@/components/shadcn-ui/radio-group';\nimport { Canon } from '@sillsdev/scripture';\nimport { LocalizedStringValue } from 'platform-bible-utils';\nimport { useState } from 'react';\nimport ChapterRangeSelector, {\n ChapterRangeSelectorProps,\n} from '../basics/chapter-range-selector.component';\n\nexport enum BookSelectionMode {\n CURRENT_BOOK = 'current book',\n CHOOSE_BOOKS = 'choose books',\n}\n\n/**\n * Object containing all keys used for localization in this component. If you're using this\n * component in an extension, you can pass it into the useLocalizedStrings hook to easily obtain the\n * localized strings and pass them into the localizedStrings prop of this component\n */\nexport const BOOK_SELECTOR_STRING_KEYS = Object.freeze([\n '%webView_bookSelector_currentBook%',\n '%webView_bookSelector_choose%',\n '%webView_bookSelector_chooseBooks%',\n] as const);\n\nexport type BookSelectorLocalizedStrings = {\n [localizedInventoryKey in (typeof BOOK_SELECTOR_STRING_KEYS)[number]]?: LocalizedStringValue;\n};\n\n/**\n * Gets the localized value for the provided key\n *\n * @param strings Object containing localized string\n * @param key Key for a localized string\n * @returns The localized value for the provided key, if available. Returns the key if no localized\n * value is available\n */\nconst localizeString = (\n strings: BookSelectorLocalizedStrings,\n key: keyof BookSelectorLocalizedStrings,\n) => {\n return strings[key] ?? key;\n};\n\ntype BookSelectorProps = ChapterRangeSelectorProps & {\n handleBookSelectionModeChange: (newMode: BookSelectionMode) => void;\n currentBookName: string;\n onSelectBooks: () => void;\n selectedBookIds: string[];\n localizedStrings: BookSelectorLocalizedStrings;\n};\n\nexport default function BookSelector({\n handleBookSelectionModeChange,\n currentBookName,\n onSelectBooks,\n selectedBookIds,\n chapterCount,\n endChapter,\n handleSelectEndChapter,\n startChapter,\n handleSelectStartChapter,\n localizedStrings,\n}: BookSelectorProps) {\n const currentBookText = localizeString(localizedStrings, '%webView_bookSelector_currentBook%');\n const chooseText = localizeString(localizedStrings, '%webView_bookSelector_choose%');\n const chooseBooksText = localizeString(localizedStrings, '%webView_bookSelector_chooseBooks%');\n\n const [bookSelectionMode, setBookSelectionMode] = useState(\n BookSelectionMode.CURRENT_BOOK,\n );\n\n const onSelectionModeChange = (newMode: BookSelectionMode) => {\n setBookSelectionMode(newMode);\n handleBookSelectionModeChange(newMode);\n };\n\n return (\n onSelectionModeChange(value as BookSelectionMode)}\n >\n
    \n
    \n
    \n \n \n
    \n \n
    \n \n
    \n
    \n
    \n
    \n \n \n
    \n \n onSelectBooks()}\n >\n {chooseText}\n \n
    \n
    \n \n );\n}\n","import { DropdownMenuTrigger } from '@radix-ui/react-dropdown-menu';\nimport { FilterIcon } from 'lucide-react';\nimport { Table } from '@tanstack/react-table';\n\nimport { Button } from '@/components/shadcn-ui/button';\nimport {\n DropdownMenu,\n DropdownMenuCheckboxItem,\n DropdownMenuContent,\n DropdownMenuLabel,\n DropdownMenuSeparator,\n} from '@/components/shadcn-ui/dropdown-menu';\n\ninterface DataTableViewOptionsProps {\n table: Table;\n}\n\nfunction DataTableViewOptions({ table }: DataTableViewOptionsProps) {\n return (\n \n \n \n \n \n Toggle columns\n \n {table\n .getAllColumns()\n .filter((column) => column.getCanHide())\n .map((column) => {\n return (\n column.toggleVisibility(!!value)}\n >\n {column.id}\n \n );\n })}\n \n \n );\n}\n\nexport default DataTableViewOptions;\n","import React from 'react';\nimport * as SelectPrimitive from '@radix-ui/react-select';\nimport { Check, ChevronDown, ChevronUp } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Select = SelectPrimitive.Root;\n\nconst SelectGroup = SelectPrimitive.Group;\n\nconst SelectValue = SelectPrimitive.Value;\n\nconst SelectTrigger = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, ...props }, ref) => (\n span]:tw-line-clamp-1',\n className,\n )}\n {...props}\n >\n {children}\n \n \n \n \n));\nSelectTrigger.displayName = SelectPrimitive.Trigger.displayName;\n\nconst SelectScrollUpButton = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n));\nSelectScrollUpButton.displayName = SelectPrimitive.ScrollUpButton.displayName;\n\nconst SelectScrollDownButton = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n));\nSelectScrollDownButton.displayName = SelectPrimitive.ScrollDownButton.displayName;\n\nconst SelectContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, position = 'popper', ...props }, ref) => (\n \n \n \n \n {children}\n \n \n \n \n));\nSelectContent.displayName = SelectPrimitive.Content.displayName;\n\nconst SelectLabel = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSelectLabel.displayName = SelectPrimitive.Label.displayName;\n\nconst SelectItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, ...props }, ref) => (\n \n \n \n \n \n \n\n {children}\n \n));\nSelectItem.displayName = SelectPrimitive.Item.displayName;\n\nconst SelectSeparator = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSelectSeparator.displayName = SelectPrimitive.Separator.displayName;\n\nexport {\n Select,\n SelectGroup,\n SelectValue,\n SelectTrigger,\n SelectContent,\n SelectLabel,\n SelectItem,\n SelectSeparator,\n SelectScrollUpButton,\n SelectScrollDownButton,\n};\n","import { ChevronLeftIcon, ChevronRightIcon, ArrowLeftIcon, ArrowRightIcon } from 'lucide-react';\nimport { Table } from '@tanstack/react-table';\n\nimport { Button } from '@/components/shadcn-ui/button';\nimport {\n Select,\n SelectContent,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\n\ninterface DataTablePaginationProps {\n table: Table;\n}\n\nfunction DataTablePagination({ table }: DataTablePaginationProps) {\n return (\n
    \n
    \n
    \n {table.getFilteredSelectedRowModel().rows.length} of{' '}\n {table.getFilteredRowModel().rows.length} row(s) selected\n
    \n
    \n

    Rows per page

    \n {\n table.setPageSize(Number(value));\n }}\n >\n \n \n \n \n {[10, 20, 30, 40, 50].map((pageSize) => (\n \n {pageSize}\n \n ))}\n \n \n
    \n
    \n Page {table.getState().pagination.pageIndex + 1} of {table.getPageCount()}\n
    \n
    \n table.setPageIndex(0)}\n disabled={!table.getCanPreviousPage()}\n >\n Go to first page\n \n \n table.previousPage()}\n disabled={!table.getCanPreviousPage()}\n >\n Go to previous page\n \n \n table.nextPage()}\n disabled={!table.getCanNextPage()}\n >\n Go to next page\n \n \n table.setPageIndex(table.getPageCount() - 1)}\n disabled={!table.getCanNextPage()}\n >\n Go to last page\n \n \n
    \n
    \n
    \n );\n}\n\nexport default DataTablePagination;\n","import React from 'react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Table = React.forwardRef<\n HTMLTableElement,\n React.HTMLAttributes & { stickyHeader?: boolean }\n>(({ className, stickyHeader, ...props }, ref) => (\n
    \n \n
    \n));\nTable.displayName = 'Table';\n\nconst TableHeader = React.forwardRef<\n HTMLTableSectionElement,\n React.HTMLAttributes & { stickyHeader?: boolean }\n>(({ className, stickyHeader, ...props }, ref) => (\n \n));\nTableHeader.displayName = 'TableHeader';\n\nconst TableBody = React.forwardRef<\n HTMLTableSectionElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableBody.displayName = 'TableBody';\n\nconst TableFooter = React.forwardRef<\n HTMLTableSectionElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n tr]:last:tw-border-b-0', className)}\n {...props}\n />\n));\nTableFooter.displayName = 'TableFooter';\n\nconst TableRow = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nTableRow.displayName = 'TableRow';\n\nconst TableHead = React.forwardRef<\n HTMLTableCellElement,\n React.ThHTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableHead.displayName = 'TableHead';\n\nconst TableCell = React.forwardRef<\n HTMLTableCellElement,\n React.TdHTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableCell.displayName = 'TableCell';\n\nconst TableCaption = React.forwardRef<\n HTMLTableCaptionElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableCaption.displayName = 'TableCaption';\n\nexport { Table, TableHeader, TableBody, TableFooter, TableHead, TableRow, TableCell, TableCaption };\n","import { useState } from 'react';\n\nimport {\n ColumnFiltersState,\n flexRender,\n getCoreRowModel,\n getFilteredRowModel,\n getPaginationRowModel,\n getSortedRowModel,\n SortingState,\n ColumnDef as TSColumnDef,\n Row as TSRow,\n RowSelectionState as TSRowSelectionState,\n SortDirection as TSSortDirection,\n Table as TSTable,\n useReactTable,\n VisibilityState,\n} from '@tanstack/react-table';\n\nimport DataTableViewOptions from '@/components/advanced/data-table/data-table-column-toggle.component';\nimport DataTablePagination from '@/components/advanced/data-table/data-table-pagination.component';\nimport { Button } from '@/components/shadcn-ui/button';\nimport {\n Table,\n TableBody,\n TableCell,\n TableHead,\n TableHeader,\n TableRow,\n} from '@/components/shadcn-ui/table';\n\nexport type ColumnDef = TSColumnDef;\nexport type RowContents = TSRow;\nexport type TableContents = TSTable;\nexport type SortDirection = TSSortDirection;\nexport type RowSelectionState = TSRowSelectionState;\n\ninterface DataTableProps {\n columns: ColumnDef[];\n data: TData[];\n enablePagination?: boolean;\n showPaginationControls?: boolean;\n showColumnVisibilityControls?: boolean;\n stickyHeader?: boolean;\n onRowClickHandler?: (row: RowContents, table: TableContents) => void;\n}\n\n/**\n * Feature-rich table component that infuses our basic shadcn-based Table component with features\n * from TanStack's React Table library\n */\nfunction DataTable({\n columns,\n data,\n enablePagination = false,\n showPaginationControls = false,\n showColumnVisibilityControls = false,\n stickyHeader = false,\n onRowClickHandler = () => {},\n}: DataTableProps) {\n const [sorting, setSorting] = useState([]);\n const [columnFilters, setColumnFilters] = useState([]);\n const [columnVisibility, setColumnVisibility] = useState({});\n const [rowSelection, setRowSelection] = useState({});\n\n const table = useReactTable({\n data,\n columns,\n getCoreRowModel: getCoreRowModel(),\n ...(enablePagination && { getPaginationRowModel: getPaginationRowModel() }),\n onSortingChange: setSorting,\n getSortedRowModel: getSortedRowModel(),\n onColumnFiltersChange: setColumnFilters,\n getFilteredRowModel: getFilteredRowModel(),\n onColumnVisibilityChange: setColumnVisibility,\n onRowSelectionChange: setRowSelection,\n state: {\n sorting,\n columnFilters,\n columnVisibility,\n rowSelection,\n },\n });\n\n return (\n
    \n {showColumnVisibilityControls && }\n \n \n {table.getHeaderGroups().map((headerGroup) => (\n \n {headerGroup.headers.map((header) => {\n return (\n \n {header.isPlaceholder\n ? undefined\n : flexRender(header.column.columnDef.header, header.getContext())}\n \n );\n })}\n \n ))}\n \n \n {table.getRowModel().rows?.length ? (\n table.getRowModel().rows.map((row) => (\n onRowClickHandler(row, table)}\n key={row.id}\n data-state={row.getIsSelected() && 'selected'}\n >\n {row.getVisibleCells().map((cell) => (\n \n {flexRender(cell.column.columnDef.cell, cell.getContext())}\n \n ))}\n \n ))\n ) : (\n \n \n No results.\n \n \n )}\n \n
    \n {enablePagination && (\n
    \n table.previousPage()}\n disabled={!table.getCanPreviousPage()}\n >\n Previous\n \n table.nextPage()}\n disabled={!table.getCanNextPage()}\n >\n Next\n \n
    \n )}\n {enablePagination && showPaginationControls && }\n
    \n );\n}\n\nexport default DataTable;\n","import {\n Table,\n TableBody,\n TableCell,\n TableHead,\n TableHeader,\n TableRow,\n} from '@/components/shadcn-ui/table';\nimport { Canon } from '@sillsdev/scripture';\nimport { deepEqual, LanguageStrings, ScriptureReference } from 'platform-bible-utils';\nimport { useMemo } from 'react';\nimport { InventoryItemOccurrence } from './inventory-utils';\n\n/** Props for the OccurrencesTable component */\ntype OccurrencesTableProps = {\n /** Data that contains scriptures references and snippets of scripture */\n occurrenceData: InventoryItemOccurrence[];\n /** Callback function that is executed when the scripture reference is changed */\n setScriptureReference: (scriptureReference: ScriptureReference) => void;\n /**\n * Object with all localized strings that the OccurrencesTable needs to work well across multiple\n * languages\n */\n localizedStrings: LanguageStrings;\n};\n\n/**\n * Table that shows occurrences of specified inventory item(s). The first column shows the related\n * scripture reference. The second column shows the snippet of scripture that contains the specified\n * inventory item\n */\nfunction OccurrencesTable({\n occurrenceData,\n setScriptureReference,\n localizedStrings,\n}: OccurrencesTableProps) {\n const referenceHeaderText =\n localizedStrings['%webView_inventory_occurrences_table_header_reference%'];\n const occurrenceHeaderText =\n localizedStrings['%webView_inventory_occurrences_table_header_occurrence%'];\n\n const occurrences: InventoryItemOccurrence[] = useMemo(() => {\n const uniqueOccurrences: InventoryItemOccurrence[] = [];\n\n occurrenceData.forEach((occurrence) => {\n if (!uniqueOccurrences.some((uniqueOccurrence) => deepEqual(uniqueOccurrence, occurrence))) {\n uniqueOccurrences.push(occurrence);\n }\n });\n\n return uniqueOccurrences;\n }, [occurrenceData]);\n\n return (\n \n \n \n {referenceHeaderText}\n {occurrenceHeaderText}\n \n \n \n {occurrences.length > 0 &&\n occurrences.map((occurrence) => (\n {\n setScriptureReference(occurrence.reference);\n }}\n >\n {`${Canon.bookNumberToEnglishName(occurrence.reference.bookNum)} ${occurrence.reference.chapterNum}:${occurrence.reference.verseNum}`}\n {occurrence.text}\n \n ))}\n \n
    \n );\n}\n\nexport default OccurrencesTable;\n","import React from 'react';\nimport * as CheckboxPrimitive from '@radix-ui/react-checkbox';\nimport { Check } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Checkbox = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n \n \n));\nCheckbox.displayName = CheckboxPrimitive.Root.displayName;\n\nexport default Checkbox;\n","import { Canon } from '@sillsdev/scripture';\nimport { ScriptureReference } from 'platform-bible-utils';\n\n/* #region Types */\n\n/**\n * Status of items that appear in inventories. 'approved' and 'unapproved' items are defined in the\n * project's `Settings.xml`. All other items are defined as 'unknown'\n */\nexport type Status = 'approved' | 'unapproved' | 'unknown';\n\n/** Occurrence of item in inventory. Primarily used by table that shows occurrences */\nexport type InventoryItemOccurrence = {\n /** Reference to scripture where the item appears */\n reference: ScriptureReference;\n /** Snippet of scripture that contains the occurrence */\n text: string;\n};\n\n/** Data structure that contains all information on an item that is shown in an inventory */\nexport type InventoryTableData = {\n /**\n * The item (e.g. a character in the characters inventory, a marker in the marker inventory) In\n * most cases the array will only have one element. In case of additional items (e.g. the\n * preceding marker in the markers check), the primary item should be stored in the first index.\n * To show additional items in the inventory, make sure to configure the `additionalItemsLabels`\n * prop for the Inventory component\n */\n items: string[];\n /** The number of times this item occurs in the selected scope */\n count: number;\n /** The status of this item (see documentation for `Status` type for more information) */\n status: Status;\n /** Occurrences of this item in the scripture text for the selected scope */\n occurrences: InventoryItemOccurrence[];\n};\n\n/* #endregion */\n\n/* #region Functions */\n\n/**\n * Splits USFM string into shorter line-like segments\n *\n * @param text A single (likely very large) USFM string\n * @returns An array containing the input text, split into shorter segments\n */\nexport const getLinesFromUSFM = (text: string) => {\n // Splits on (CR)LF, CR, \\v, \\c and \\id\n return text.split(/(?:\\r?\\n|\\r)|(?=(?:\\\\(?:v|c|id)))/g);\n};\n\n/**\n * Extracts chapter or verse number from USFM strings that start with a \\c or \\v marker\n *\n * @param text USFM string that is expected to start with \\c or \\v marker\n * @returns Chapter or verse number if one is found. Else returns 0.\n */\nexport const getNumberFromUSFM = (text: string): number | undefined => {\n // Captures all digits that follow \\v or \\c markers followed by whitespace located at the start of a string\n const regex = /^\\\\[vc]\\s+(\\d+)/;\n const match = text.match(regex);\n\n if (match) {\n return +match[1];\n }\n return undefined;\n};\n\n/**\n * Gets book ID from USFM string that starts with the \\id marker, and returns book number for it\n *\n * @param text USFM string that is expected to start with \\id marker\n * @returns Book number corresponding to the \\id marker in the input text. Returns 0 if no marker is\n * found or the marker is not valid\n */\nexport const getBookNumFromId = (text: string): number => {\n // Captures all digits that follow an \\id marker followed by whitespace located at the start of a string\n const match = text.match(/^\\\\id\\s+([A-Za-z]+)/);\n if (match) {\n return Canon.bookIdToNumber(match[1]);\n }\n return 0;\n};\n\n/**\n * Gets the status for an item, typically used in the Inventory component\n *\n * @param item The item for which the status is being requested\n * @param approvedItems Array of approved items, typically as defined in `Settings.xml`\n * @param unapprovedItems Array of unapproved items, typically as defined in `Settings.xml`\n * @returns The status for the specified item\n */\nexport const getStatusForItem = (\n item: string,\n approvedItems: string[],\n unapprovedItems: string[],\n): Status => {\n if (unapprovedItems.includes(item)) return 'unapproved';\n if (approvedItems.includes(item)) return 'approved';\n return 'unknown';\n};\n\n/* #endregion */\n","import React from 'react';\nimport * as TogglePrimitive from '@radix-ui/react-toggle';\nimport { cva, type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst toggleVariants = cva(\n 'pr-twp tw-inline-flex tw-items-center tw-justify-center tw-rounded-md tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-colors hover:tw-bg-muted hover:tw-text-muted-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50 data-[state=on]:tw-bg-accent data-[state=on]:tw-text-accent-foreground',\n {\n variants: {\n variant: {\n default: 'tw-bg-transparent',\n outline:\n 'tw-border tw-border-input tw-bg-transparent hover:tw-bg-accent hover:tw-text-accent-foreground',\n },\n size: {\n default: 'tw-h-10 tw-px-3',\n sm: 'tw-h-9 tw-px-2.5',\n lg: 'tw-h-11 tw-px-5',\n },\n },\n defaultVariants: {\n variant: 'default',\n size: 'default',\n },\n },\n);\n\nconst Toggle = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef & VariantProps\n>(({ className, variant, size, ...props }, ref) => (\n \n));\n\nToggle.displayName = TogglePrimitive.Root.displayName;\n\nexport { Toggle, toggleVariants };\n","import React from 'react';\nimport * as ToggleGroupPrimitive from '@radix-ui/react-toggle-group';\nimport { type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { toggleVariants } from '@/components/shadcn-ui/toggle';\n\nconst ToggleGroupContext = React.createContext>({\n size: 'default',\n variant: 'default',\n});\n\nconst ToggleGroup = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef &\n VariantProps\n>(({ className, variant, size, children, ...props }, ref) => (\n \n \n {children}\n \n \n));\n\nToggleGroup.displayName = ToggleGroupPrimitive.Root.displayName;\n\nconst ToggleGroupItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef &\n VariantProps\n>(({ className, children, variant, size, ...props }, ref) => {\n const context = React.useContext(ToggleGroupContext);\n\n return (\n \n {children}\n \n );\n});\n\nToggleGroupItem.displayName = ToggleGroupPrimitive.Item.displayName;\n\nexport { ToggleGroup, ToggleGroupItem };\n","import { ColumnDef, SortDirection } from '@/components/advanced/data-table/data-table.component';\nimport { Button } from '@/components/shadcn-ui/button';\nimport { ToggleGroup, ToggleGroupItem } from '@/components/shadcn-ui/toggle-group';\nimport {\n ArrowDownIcon,\n ArrowUpDownIcon,\n ArrowUpIcon,\n CircleCheckIcon,\n CircleHelpIcon,\n CircleXIcon,\n} from 'lucide-react';\nimport { ReactNode } from 'react';\nimport { InventoryTableData, Status } from './inventory-utils';\n\n/**\n * Gets an icon that indicates the current sorting direction based on the provided input\n *\n * @param sortDirection Sorting direction. Can be ascending ('asc'), descending ('desc') or false (\n * i.e. not sorted)\n * @returns The appropriate sorting icon for the provided sorting direction\n */\nconst getSortingIcon = (sortDirection: false | SortDirection): ReactNode => {\n if (sortDirection === 'asc') {\n return ;\n }\n if (sortDirection === 'desc') {\n return ;\n }\n return ;\n};\n\n/**\n * Function that creates the item column for inventories\n *\n * @param itemLabel Localized label for the item column (e.g. 'Character', 'Repeated Word', etc.)\n * @returns Column that shows the inventory items. Should be used with the DataTable component\n */\nexport const inventoryItemColumn = (itemLabel: string): ColumnDef => {\n return {\n accessorKey: 'item',\n accessorFn: (row: InventoryTableData) => row.items[0],\n header: ({ column }) => (\n \n ),\n };\n};\n\n/**\n * Function that creates the additional item columns for inventories\n *\n * @param additionalItemLabel Localized label for the additional item column (e.g. 'Preceding\n * Marker')\n * @param additionalItemIndex Index that locates the desired item in the items array of the\n * inventory\n * @returns Column that shows additional inventory items. Should be used with the DataTable\n * component\n */\nexport const inventoryAdditionalItemColumn = (\n additionalItemLabel: string,\n additionalItemIndex: number,\n): ColumnDef => {\n return {\n accessorKey: `item${additionalItemIndex}`,\n accessorFn: (row: InventoryTableData) => row.items[additionalItemIndex],\n header: ({ column }) => (\n \n ),\n };\n};\n\n/**\n * Function that creates the count column for inventories. Should be used with the DataTable\n * component.\n *\n * @param itemLabel Localized label for the count column\n * @returns Column that shows the number of occurrences of the related inventory items\n */\nexport const inventoryCountColumn = (countLabel: string): ColumnDef => {\n return {\n accessorKey: 'count',\n header: ({ column }) => (\n
    \n \n
    \n ),\n cell: ({ row }) =>
    {row.getValue('count')}
    ,\n };\n};\n\n/**\n * Function that updates project settings when status for item(s) changes\n *\n * @param changedItems Array of items for which the status is being updated\n * @param newStatus The status that the items are being given\n * @param approvedItems Array of currently approved items\n * @param onApprovedItemsChange Callback function that stores the updated list of approved items\n * @param unapprovedItems Array of currently unapproved items\n * @param onUnapprovedItemsChange Callback function that stores the updated list of unapproved items\n */\nconst statusChangeHandler = (\n changedItems: string[],\n newStatus: Status,\n approvedItems: string[],\n onApprovedItemsChange: (items: string[]) => void,\n unapprovedItems: string[],\n onUnapprovedItemsChange: (items: string[]) => void,\n) => {\n let newApprovedItems: string[] = [...approvedItems];\n changedItems.forEach((item) => {\n if (newStatus === 'approved') {\n if (!newApprovedItems.includes(item)) {\n newApprovedItems.push(item);\n }\n } else {\n newApprovedItems = newApprovedItems.filter((validItem) => validItem !== item);\n }\n });\n onApprovedItemsChange(newApprovedItems);\n\n let newUnapprovedItems: string[] = [...unapprovedItems];\n changedItems.forEach((item) => {\n if (newStatus === 'unapproved') {\n if (!newUnapprovedItems.includes(item)) {\n newUnapprovedItems.push(item);\n }\n } else {\n newUnapprovedItems = newUnapprovedItems.filter((unapprovedItem) => unapprovedItem !== item);\n }\n });\n onUnapprovedItemsChange(newUnapprovedItems);\n};\n\n/**\n * Function that creates the status column for inventories. Should be used with the DataTable\n * component.\n *\n * @param statusLabel Localized label for the status column\n * @param approvedItems Array of approved items, typically as defined in `Settings.xml`\n * @param onApprovedItemsChange Callback function that stores the updated list of approved items\n * @param unapprovedItems Array of unapproved items, typically as defined in `Settings.xml`\n * @param onUnapprovedItemsChange Callback function that stores the updated list of unapproved items\n * @returns Column that shows the status buttons for the related inventory item. The button for the\n * current status of the item is selected\n */\nexport const inventoryStatusColumn = (\n statusLabel: string,\n approvedItems: string[],\n onApprovedItemsChange: (items: string[]) => void,\n unapprovedItems: string[],\n onUnapprovedItemsChange: (items: string[]) => void,\n): ColumnDef => {\n return {\n accessorKey: 'status',\n header: ({ column }) => {\n return (\n
    \n \n
    \n );\n },\n cell: ({ row }) => {\n const status: Status = row.getValue('status');\n const item: string = row.getValue('item');\n return (\n \n \n statusChangeHandler(\n [item],\n 'approved',\n approvedItems,\n onApprovedItemsChange,\n unapprovedItems,\n onUnapprovedItemsChange,\n )\n }\n value=\"approved\"\n >\n \n \n \n statusChangeHandler(\n [item],\n 'unapproved',\n approvedItems,\n onApprovedItemsChange,\n unapprovedItems,\n onUnapprovedItemsChange,\n )\n }\n value=\"unapproved\"\n >\n \n \n \n statusChangeHandler(\n [item],\n 'unknown',\n approvedItems,\n onApprovedItemsChange,\n unapprovedItems,\n onUnapprovedItemsChange,\n )\n }\n value=\"unknown\"\n >\n \n \n \n );\n },\n };\n};\n","import DataTable, {\n ColumnDef,\n RowContents,\n RowSelectionState,\n TableContents,\n} from '@/components/advanced/data-table/data-table.component';\nimport OccurrencesTable from '@/components/advanced/inventory/occurrences-table.component';\nimport Checkbox from '@/components/shadcn-ui/checkbox';\nimport { Input } from '@/components/shadcn-ui/input';\nimport { Label } from '@/components/shadcn-ui/label';\nimport {\n Select,\n SelectContent,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\nimport {\n deepEqual,\n LocalizedStringValue,\n ScriptureReference,\n substring,\n} from 'platform-bible-utils';\nimport { useEffect, useMemo, useState } from 'react';\nimport {\n getBookNumFromId,\n getLinesFromUSFM,\n getNumberFromUSFM,\n getStatusForItem,\n InventoryItemOccurrence,\n InventoryTableData,\n Status,\n} from './inventory-utils';\nimport { inventoryAdditionalItemColumn } from './inventory-columns';\n\n/**\n * Object containing all keys used for localization in this component. If you're using this\n * component in an extension, you can pass it into the useLocalizedStrings hook to easily obtain the\n * localized strings and pass them into the localizedStrings prop of this component\n */\nexport const INVENTORY_STRING_KEYS = Object.freeze([\n '%webView_inventory_all%',\n '%webView_inventory_approved%',\n '%webView_inventory_unapproved%',\n '%webView_inventory_unknown%',\n '%webView_inventory_scope_currentBook%',\n '%webView_inventory_scope_chapter%',\n '%webView_inventory_scope_verse%',\n '%webView_inventory_filter_text%',\n '%webView_inventory_show_additional_items%',\n '%webView_inventory_occurrences_table_header_reference%',\n '%webView_inventory_occurrences_table_header_occurrence%',\n] as const);\n\nexport type InventoryLocalizedStrings = {\n [localizedInventoryKey in (typeof INVENTORY_STRING_KEYS)[number]]?: LocalizedStringValue;\n};\n\n/** Scope of scripture that the inventory can operate on */\nexport type Scope = 'book' | 'chapter' | 'verse';\n\n/** Status values that the status filter can select from */\ntype StatusFilter = Status | 'all';\n\n/** Text labels for the inventory columns and the control components of additional inventory items */\ntype AdditionalItemsLabels = {\n checkboxText?: string;\n tableHeaders?: string[];\n};\n\n/**\n * Filters data that is shown in the DataTable section of the Inventory\n *\n * @param itemData All inventory items and their related information\n * @param statusFilter Allows filtering by status (i.e. show all items, or only items that are\n * 'approved', 'unapproved' or 'unknown')\n * @param textFilter Allows filtering by text. All items that include the filter text will be\n * selected.\n * @returns Array of items and their related information that are matched by the specified filters\n */\nconst filterItemData = (\n itemData: InventoryTableData[],\n statusFilter: StatusFilter,\n textFilter: string,\n): InventoryTableData[] => {\n let filteredItemData: InventoryTableData[] = itemData;\n\n if (statusFilter !== 'all') {\n filteredItemData = filteredItemData.filter(\n (item) =>\n (statusFilter === 'approved' && item.status === 'approved') ||\n (statusFilter === 'unapproved' && item.status === 'unapproved') ||\n (statusFilter === 'unknown' && item.status === 'unknown'),\n );\n }\n\n if (textFilter !== '')\n filteredItemData = filteredItemData.filter((item) => item.items[0].includes(textFilter));\n\n return filteredItemData;\n};\n\n/**\n * Turns array of strings into array of inventory items, along with their count and status\n *\n * @param text The source scripture text that is searched for inventory items\n * @param scriptureRef The scripture reference that the application is currently set to\n * @param approvedItems Array of approved items, typically as defined in `Settings.xml`\n * @param unapprovedItems Array of unapproved items, typically as defined in `Settings.xml`\n * @param itemRegex Regular expression that describes what items this Inventory should extract from\n * the provided scripture text\n * @returns Array of inventory items, along with their count and status\n */\nconst createTableData = (\n text: string | undefined,\n scriptureRef: ScriptureReference,\n approvedItems: string[],\n unapprovedItems: string[],\n itemRegex: RegExp,\n): InventoryTableData[] => {\n if (!text) return [];\n\n const tableData: InventoryTableData[] = [];\n\n let currentBook: number | undefined = scriptureRef.bookNum;\n let currentChapter: number | undefined = scriptureRef.chapterNum;\n let currentVerse: number | undefined = scriptureRef.verseNum;\n\n const lines = getLinesFromUSFM(text);\n\n lines.forEach((line: string) => {\n if (line.startsWith('\\\\id')) {\n currentBook = getBookNumFromId(line);\n currentChapter = 0;\n currentVerse = 0;\n }\n if (line.startsWith('\\\\c')) {\n currentChapter = getNumberFromUSFM(line);\n currentVerse = 0;\n }\n if (line.startsWith('\\\\v')) {\n currentVerse = getNumberFromUSFM(line);\n if (currentChapter === 0) {\n currentChapter = scriptureRef.chapterNum;\n }\n }\n\n let match: RegExpExecArray | undefined = itemRegex.exec(line) ?? undefined;\n while (match) {\n const items: string[] = [];\n match.forEach((item) => items.push(item));\n const itemIndex = match.index;\n const existingItem = tableData.find((tableEntry) => deepEqual(tableEntry.items, items));\n const newReference: InventoryItemOccurrence = {\n reference: {\n bookNum: currentBook !== undefined ? currentBook : -1,\n chapterNum: currentChapter !== undefined ? currentChapter : -1,\n verseNum: currentVerse !== undefined ? currentVerse : -1,\n },\n text: substring(line, Math.max(0, itemIndex - 25), Math.min(itemIndex + 25, line.length)),\n };\n if (existingItem) {\n existingItem.count += 1;\n existingItem.occurrences.push(newReference);\n } else {\n const newItem: InventoryTableData = {\n items,\n count: 1,\n status: getStatusForItem(items[0], approvedItems, unapprovedItems),\n occurrences: [newReference],\n };\n tableData.push(newItem);\n }\n\n match = itemRegex.exec(line) ?? undefined;\n }\n });\n\n return tableData;\n};\n\n/**\n * Gets the localized value for the provided key\n *\n * @param strings Object containing localized string\n * @param key Key for a localized string\n * @returns The localized value for the provided key, if available. Returns the key if no localized\n * value is available\n */\nconst localizeString = (\n strings: InventoryLocalizedStrings,\n key: keyof InventoryLocalizedStrings,\n) => {\n return strings[key] ?? key;\n};\n\n/** Props for the Inventory component */\ntype InventoryProps = {\n /** The scripture reference that the application is currently set to */\n scriptureReference: ScriptureReference;\n /** Callback function that is executed when the scripture reference is changed */\n setScriptureReference: (scriptureReference: ScriptureReference) => void;\n /**\n * Object with all localized strings that the Inventory needs to work well across multiple\n * languages. When using this component with Platform.Bible, you can import\n * `INVENTORY_STRING_KEYS` from this library, pass it in to the Platform's localization hook, and\n * pass the localized keys that are returned by the hook into this prop.\n */\n localizedStrings: InventoryLocalizedStrings;\n /**\n * The logic that finds the desired items in the source text. This can either be a Regular\n * expression that captures one or multiple items (preferred), or a custom function that builds\n * and return an InventoryDataTable[] manually. Note: In case the logic captures more than one\n * item (i.e. InventoryTableData.items has a length greater than 1), you must provide text labels\n * for the related columns and control elements to show by setting the `additionalItemsLabels`\n * prop\n */\n extractItems:\n | RegExp\n | ((\n text: string | undefined,\n scriptureRef: ScriptureReference,\n approvedItems: string[],\n unapprovedItems: string[],\n ) => InventoryTableData[]);\n /**\n * Text labels for control elements and additional column headers in case your Inventory has more\n * than one item to show (e.g. The 'Preceding Marker' in the Markers Inventory)\n */\n additionalItemsLabels?: AdditionalItemsLabels;\n /** Array of approved items, typically as defined in `Settings.xml` */\n approvedItems: string[];\n /** Array of unapproved items, typically as defined in `Settings.xml` */\n unapprovedItems: string[];\n /** The source scripture text that is searched for in inventory items */\n text: string | undefined;\n /** Scope of scripture that the inventory will operate on */\n scope: Scope;\n /** Callback function that is executed when the scope is changed from the Inventory */\n onScopeChange: (scope: Scope) => void;\n /**\n * Column definitions for the Inventory data table. The most commonly used column definitions are\n * pre-configured for your convenience and can be imported (e.g. inventoryItemColumn,\n * inventoryAdditionalItemColumn inventoryCountColumn, and inventoryStatusColumn). If you need any\n * other columns you can add these yourself\n */\n columns: ColumnDef[];\n};\n\n/** Inventory component that is used to view and control the status of provided project settings */\nexport default function Inventory({\n scriptureReference,\n setScriptureReference,\n localizedStrings,\n extractItems,\n additionalItemsLabels,\n approvedItems,\n unapprovedItems,\n text,\n scope,\n onScopeChange,\n columns,\n}: InventoryProps) {\n const allItemsText = localizeString(localizedStrings, '%webView_inventory_all%');\n const approvedItemsText = localizeString(localizedStrings, '%webView_inventory_approved%');\n const unapprovedItemsText = localizeString(localizedStrings, '%webView_inventory_unapproved%');\n const unknownItemsText = localizeString(localizedStrings, '%webView_inventory_unknown%');\n const scopeBookText = localizeString(localizedStrings, '%webView_inventory_scope_currentBook%');\n const scopeChapterText = localizeString(localizedStrings, '%webView_inventory_scope_chapter%');\n const scopeVerseText = localizeString(localizedStrings, '%webView_inventory_scope_verse%');\n const filterText = localizeString(localizedStrings, '%webView_inventory_filter_text%');\n const showAdditionalItemsText = localizeString(\n localizedStrings,\n '%webView_inventory_show_additional_items%',\n );\n\n const [showAdditionalItems, setShowAdditionalItems] = useState(false);\n const [statusFilter, setStatusFilter] = useState('all');\n const [textFilter, setTextFilter] = useState('');\n const [selectedItem, setSelectedItem] = useState([]);\n\n const tableData: InventoryTableData[] = useMemo(() => {\n if (!text) return [];\n if (extractItems instanceof RegExp)\n return createTableData(\n text,\n scriptureReference,\n approvedItems,\n unapprovedItems,\n extractItems,\n );\n return extractItems(text, scriptureReference, approvedItems, unapprovedItems);\n }, [text, extractItems, scriptureReference, approvedItems, unapprovedItems]);\n\n const reducedTableData: InventoryTableData[] = useMemo(() => {\n if (showAdditionalItems) return tableData;\n\n const newTableData: InventoryTableData[] = [];\n\n tableData.forEach((tableEntry) => {\n const firstItem = tableEntry.items[0];\n\n const existingEntry = newTableData.find(\n (newTableEntry) => newTableEntry.items[0] === firstItem,\n );\n\n if (existingEntry) {\n existingEntry.count += tableEntry.count;\n existingEntry.occurrences = existingEntry.occurrences.concat(tableEntry.occurrences);\n } else {\n newTableData.push({\n items: [firstItem],\n count: tableEntry.count,\n occurrences: tableEntry.occurrences,\n status: tableEntry.status,\n });\n }\n });\n\n return newTableData;\n }, [showAdditionalItems, tableData]);\n\n const filteredTableData: InventoryTableData[] = useMemo(() => {\n return filterItemData(reducedTableData, statusFilter, textFilter);\n }, [reducedTableData, statusFilter, textFilter]);\n\n const allColumns: ColumnDef[] = useMemo(() => {\n if (!showAdditionalItems) return columns;\n\n const numberOfAdditionalItems = additionalItemsLabels?.tableHeaders?.length;\n if (!numberOfAdditionalItems) return columns;\n\n const additionalColumns: ColumnDef[] = [];\n\n for (let index = 0; index < numberOfAdditionalItems; index++) {\n additionalColumns.push(\n inventoryAdditionalItemColumn(\n additionalItemsLabels?.tableHeaders?.[index] || 'Additional Item',\n index + 1,\n ),\n );\n }\n\n return [...additionalColumns, ...columns];\n }, [additionalItemsLabels?.tableHeaders, columns, showAdditionalItems]);\n\n useEffect(() => {\n setSelectedItem([]);\n }, [filteredTableData]);\n\n const rowClickHandler = (\n row: RowContents,\n table: TableContents,\n ) => {\n table.setRowSelection(() => {\n const newSelection: RowSelectionState = {};\n newSelection[row.index] = true;\n return newSelection;\n });\n\n setSelectedItem(row.original.items);\n };\n\n const handleScopeChange = (value: string) => {\n if (value === 'book' || value === 'chapter' || value === 'verse') {\n onScopeChange(value);\n } else {\n throw new Error(`Invalid scope value: ${value}`);\n }\n };\n\n const handleStatusFilterChange = (value: string) => {\n if (value === 'all' || value === 'approved' || value === 'unapproved' || value === 'unknown') {\n setStatusFilter(value);\n } else {\n throw new Error(`Invalid status filter value: ${value}`);\n }\n };\n\n const occurrenceData: InventoryItemOccurrence[] = useMemo(() => {\n if (reducedTableData.length === 0 || selectedItem.length === 0) return [];\n const occurrence = reducedTableData.filter((tableEntry: InventoryTableData) => {\n return deepEqual(\n showAdditionalItems ? tableEntry.items : [tableEntry.items[0]],\n selectedItem,\n );\n });\n if (occurrence.length > 1) throw new Error('Selected item is not unique');\n return occurrence[0].occurrences;\n }, [selectedItem, showAdditionalItems, reducedTableData]);\n\n return (\n
    \n
    \n handleStatusFilterChange(value)}\n defaultValue={statusFilter}\n >\n \n \n \n \n {allItemsText}\n {approvedItemsText}\n {unapprovedItemsText}\n {unknownItemsText}\n \n \n \n {\n setTextFilter(event.target.value);\n }}\n />\n {additionalItemsLabels && (\n
    \n {\n setSelectedItem([]);\n setShowAdditionalItems(checked);\n }}\n />\n \n
    \n )}\n
    \n
    \n \n
    \n {occurrenceData.length > 0 && (\n
    \n \n
    \n )}\n
    \n );\n}\n","import { Input } from '@/components/shadcn-ui/input';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { useState } from 'react';\n\nexport type SearchBarProps = {\n /**\n * Callback fired to handle the search query when button pressed\n *\n * @param searchQuery\n */\n onSearch: (searchQuery: string) => void;\n\n /** Optional string that appears in the search bar without a search string */\n placeholder?: string;\n\n /** Optional boolean to set the input base to full width */\n isFullWidth?: boolean;\n};\n\nexport default function SearchBar({ onSearch, placeholder, isFullWidth }: SearchBarProps) {\n const [searchQuery, setSearchQuery] = useState('');\n\n const handleInputChange = (searchString: string) => {\n setSearchQuery(searchString);\n onSearch(searchString);\n };\n\n return (\n handleInputChange(e.target.value)}\n />\n );\n}\n","// adapted from: https://github.com/shadcn-ui/ui/discussions/752\n\n'use client';\n\nimport { TabsContentProps, TabsListProps, TabsTriggerProps } from '@/components/shadcn-ui/tabs';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport * as TabsPrimitive from '@radix-ui/react-tabs';\nimport React from 'react';\n\nexport type VerticalTabsProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport type LeftTabsTriggerProps = TabsTriggerProps & {\n value: string;\n ref?: React.Ref;\n};\n\nexport const VerticalTabs = React.forwardRef<\n React.ElementRef,\n VerticalTabsProps\n>(({ className, ...props }, ref) => (\n \n));\n\nVerticalTabs.displayName = TabsPrimitive.List.displayName;\n\nexport const VerticalTabsList = React.forwardRef<\n React.ElementRef,\n TabsListProps\n>(({ className, ...props }, ref) => (\n \n));\nVerticalTabsList.displayName = TabsPrimitive.List.displayName;\n\nexport const VerticalTabsTrigger = React.forwardRef<\n React.ElementRef,\n LeftTabsTriggerProps\n>(({ className, ...props }, ref) => (\n \n));\n\nexport const VerticalTabsContent = React.forwardRef<\n React.ElementRef,\n TabsContentProps\n>(({ className, ...props }, ref) => (\n \n));\nVerticalTabsContent.displayName = TabsPrimitive.Content.displayName;\n","import SearchBar from '@/components/basics/search-bar.component';\nimport {\n VerticalTabs,\n VerticalTabsContent,\n VerticalTabsList,\n VerticalTabsTrigger,\n} from '@/components/basics/tabs-vertical';\nimport { ReactNode } from 'react';\n\nexport type TabKeyValueContent = {\n key: string;\n value: string;\n content: ReactNode;\n};\n\nexport type TabNavigationContentSearchProps = {\n /** List of values and keys for each tab this component should provide */\n tabList: TabKeyValueContent[];\n\n /** Handler to run when the value of the search bar changes */\n onSearch: (searchQuery: string) => void;\n\n /** Optional placeholder for the search bar */\n searchPlaceholder?: string;\n\n /** Optional title to include in the header */\n headerTitle?: string;\n\n /** Optional flag to make the search bar appear full width */\n isSearchBarFullWidth?: boolean;\n\n /** Text direction ltr or rtl */\n direction?: 'ltr' | 'rtl';\n};\n\nexport default function TabNavigationContentSearch({\n tabList,\n onSearch,\n searchPlaceholder,\n headerTitle,\n isSearchBarFullWidth = false,\n direction = 'ltr',\n}: TabNavigationContentSearchProps) {\n return (\n
    \n
    \n {headerTitle ?

    {headerTitle}

    : ''}\n \n
    \n \n \n {tabList.map((tab) => (\n \n {tab.value}\n \n ))}\n \n {tabList.map((tab) => (\n \n {tab.content}\n \n ))}\n \n
    \n );\n}\n","import React from 'react';\nimport * as SeparatorPrimitive from '@radix-ui/react-separator';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Separator = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, orientation = 'horizontal', decorative = true, ...props }, ref) => (\n \n));\nSeparator.displayName = SeparatorPrimitive.Root.displayName;\n\nexport { Separator };\n","'use client';\n\nimport * as React from 'react';\nimport * as SheetPrimitive from '@radix-ui/react-dialog';\nimport { cva, type VariantProps } from 'class-variance-authority';\nimport { X } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Sheet = SheetPrimitive.Root;\n\nconst SheetTrigger = SheetPrimitive.Trigger;\n\nconst SheetClose = SheetPrimitive.Close;\n\nconst SheetPortal = SheetPrimitive.Portal;\n\nconst SheetOverlay = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSheetOverlay.displayName = SheetPrimitive.Overlay.displayName;\n\nconst sheetVariants = cva(\n 'pr-twp tw-fixed tw-z-50 tw-gap-4 tw-bg-background tw-p-6 tw-shadow-lg tw-transition tw-ease-in-out data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-duration-300 data-[state=open]:tw-duration-500',\n {\n variants: {\n side: {\n top: 'tw-inset-x-0 tw-top-0 tw-border-b data-[state=closed]:tw-slide-out-to-top data-[state=open]:tw-slide-in-from-top',\n bottom:\n 'tw-inset-x-0 tw-bottom-0 tw-border-t data-[state=closed]:tw-slide-out-to-bottom data-[state=open]:tw-slide-in-from-bottom',\n left: 'tw-inset-y-0 tw-left-0 tw-h-full tw-w-3/4 tw-border-r data-[state=closed]:tw-slide-out-to-left data-[state=open]:tw-slide-in-from-left sm:tw-max-w-sm',\n right:\n 'tw-inset-y-0 tw-right-0 tw-h-full tw-w-3/4 tw- tw-border-l data-[state=closed]:tw-slide-out-to-right data-[state=open]:tw-slide-in-from-right sm:tw-max-w-sm',\n },\n },\n defaultVariants: {\n side: 'right',\n },\n },\n);\n\ninterface SheetContentProps\n extends React.ComponentPropsWithoutRef,\n VariantProps {}\n\nconst SheetContent = React.forwardRef<\n React.ElementRef,\n SheetContentProps\n>(({ side = 'right', className, children, ...props }, ref) => (\n \n \n \n {children}\n \n \n Close\n \n \n \n));\nSheetContent.displayName = SheetPrimitive.Content.displayName;\n\nfunction SheetHeader({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nSheetHeader.displayName = 'SheetHeader';\n\nfunction SheetFooter({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nSheetFooter.displayName = 'SheetFooter';\n\nconst SheetTitle = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSheetTitle.displayName = SheetPrimitive.Title.displayName;\n\nconst SheetDescription = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSheetDescription.displayName = SheetPrimitive.Description.displayName;\n\nexport {\n Sheet,\n SheetPortal,\n SheetOverlay,\n SheetTrigger,\n SheetClose,\n SheetContent,\n SheetHeader,\n SheetFooter,\n SheetTitle,\n SheetDescription,\n};\n","import React from 'react';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nfunction Skeleton({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\n\nexport { Skeleton };\n","import React from 'react';\nimport * as TooltipPrimitive from '@radix-ui/react-tooltip';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst TooltipProvider = TooltipPrimitive.Provider;\n\nconst Tooltip = TooltipPrimitive.Root;\n\nconst TooltipTrigger = TooltipPrimitive.Trigger;\n\nconst TooltipContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, sideOffset = 4, ...props }, ref) => (\n \n));\nTooltipContent.displayName = TooltipPrimitive.Content.displayName;\n\nexport { Tooltip, TooltipTrigger, TooltipContent, TooltipProvider };\n","import * as React from 'react';\n\nconst MOBILE_BREAKPOINT = 768;\n\nexport default function useIsMobile() {\n const [isMobile, setIsMobile] = React.useState(undefined);\n\n React.useEffect(() => {\n const mql = window.matchMedia(`(max-width: ${MOBILE_BREAKPOINT - 1}px)`);\n const onChange = () => {\n setIsMobile(window.innerWidth < MOBILE_BREAKPOINT);\n };\n mql.addEventListener('change', onChange);\n setIsMobile(window.innerWidth < MOBILE_BREAKPOINT);\n return () => mql.removeEventListener('change', onChange);\n }, []);\n\n return !!isMobile;\n}\n","import React from 'react';\nimport { Slot } from '@radix-ui/react-slot';\nimport { VariantProps, cva } from 'class-variance-authority';\nimport { PanelLeft } from 'lucide-react';\n\nimport { Button } from '@/components/shadcn-ui/button';\nimport { Input } from '@/components/shadcn-ui/input';\nimport { Separator } from '@/components/shadcn-ui/separator';\nimport { Sheet, SheetContent } from '@/components/shadcn-ui/sheet';\nimport { Skeleton } from '@/components/shadcn-ui/skeleton';\nimport {\n Tooltip,\n TooltipContent,\n TooltipProvider,\n TooltipTrigger,\n} from '@/components/shadcn-ui/tooltip';\nimport useIsMobile from '@/components/hooks/use-mobile';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst SIDEBAR_COOKIE_NAME = 'sidebar:state';\nconst SIDEBAR_COOKIE_MAX_AGE = 60 * 60 * 24 * 7;\nconst SIDEBAR_WIDTH = '16rem';\nconst SIDEBAR_WIDTH_MOBILE = '18rem';\nconst SIDEBAR_WIDTH_ICON = '3rem';\nconst SIDEBAR_KEYBOARD_SHORTCUT = 'b';\n\ntype SidebarContextProps = {\n state: 'expanded' | 'collapsed';\n open: boolean;\n setOpen: (open: boolean) => void;\n openMobile: boolean;\n setOpenMobile: (open: boolean) => void;\n isMobile: boolean;\n toggleSidebar: () => void;\n};\n\nconst SidebarContext = React.createContext(undefined);\n\nfunction useSidebar() {\n const context = React.useContext(SidebarContext);\n if (!context) {\n throw new Error('useSidebar must be used within a SidebarProvider.');\n }\n\n return context;\n}\n\nconst SidebarProvider = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & {\n defaultOpen?: boolean;\n open?: boolean;\n onOpenChange?: (open: boolean) => void;\n }\n>(\n (\n {\n defaultOpen = true,\n open: openProp,\n onOpenChange: setOpenProp,\n className,\n style,\n children,\n ...props\n },\n ref,\n ) => {\n const isMobile = useIsMobile();\n const [openMobile, setOpenMobile] = React.useState(false);\n\n // This is the internal state of the sidebar.\n // We use openProp and setOpenProp for control from outside the component.\n const [_open, _setOpen] = React.useState(defaultOpen);\n const isOpen = openProp ?? _open;\n const setOpen = React.useCallback(\n (value: boolean | ((value: boolean) => boolean)) => {\n const openState = typeof value === 'function' ? value(isOpen) : value;\n if (setOpenProp) {\n setOpenProp(openState);\n } else {\n _setOpen(openState);\n }\n\n // This sets the cookie to keep the sidebar state.\n document.cookie = `${SIDEBAR_COOKIE_NAME}=${openState}; path=/; max-age=${SIDEBAR_COOKIE_MAX_AGE}`;\n },\n [setOpenProp, isOpen],\n );\n\n // Helper to toggle the sidebar.\n const toggleSidebar = React.useCallback(() => {\n return isMobile ? setOpenMobile((open) => !open) : setOpen((open) => !open);\n }, [isMobile, setOpen, setOpenMobile]);\n\n // Adds a keyboard shortcut to toggle the sidebar.\n React.useEffect(() => {\n const handleKeyDown = (event: KeyboardEvent) => {\n if (event.key === SIDEBAR_KEYBOARD_SHORTCUT && (event.metaKey || event.ctrlKey)) {\n event.preventDefault();\n toggleSidebar();\n }\n };\n\n window.addEventListener('keydown', handleKeyDown);\n return () => window.removeEventListener('keydown', handleKeyDown);\n }, [toggleSidebar]);\n\n // We add a state so that we can do data-state=\"expanded\" or \"collapsed\".\n // This makes it easier to style the sidebar with Tailwind classes.\n const state = isOpen ? 'expanded' : 'collapsed';\n\n const contextValue = React.useMemo(\n () => ({\n state,\n open: isOpen,\n setOpen,\n isMobile,\n openMobile,\n setOpenMobile,\n toggleSidebar,\n }),\n [state, isOpen, setOpen, isMobile, openMobile, setOpenMobile, toggleSidebar],\n );\n\n return (\n \n \n \n {children}\n
    \n \n \n );\n },\n);\nSidebarProvider.displayName = 'SidebarProvider';\n\nconst Sidebar = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & {\n side?: 'left' | 'right';\n variant?: 'sidebar' | 'floating' | 'inset';\n collapsible?: 'offcanvas' | 'icon' | 'none';\n }\n>(\n (\n {\n side = 'left',\n variant = 'sidebar',\n collapsible = 'offcanvas',\n className,\n children,\n ...props\n },\n ref,\n ) => {\n const { isMobile, state, openMobile, setOpenMobile } = useSidebar();\n\n if (collapsible === 'none') {\n return (\n \n {children}\n
    \n );\n }\n\n if (isMobile) {\n return (\n \n button]:tw-hidden\"\n style={\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n {\n '--sidebar-width': SIDEBAR_WIDTH_MOBILE,\n } as React.CSSProperties\n }\n side={side}\n >\n
    {children}
    \n \n
    \n );\n }\n\n return (\n \n {/* This is what handles the sidebar gap on desktop */}\n \n \n \n {children}\n
    \n
    \n
    \n );\n },\n);\nSidebar.displayName = 'Sidebar';\n\nconst SidebarTrigger = React.forwardRef<\n React.ElementRef,\n React.ComponentProps\n>(({ className, onClick, ...props }, ref) => {\n const { toggleSidebar } = useSidebar();\n\n return (\n {\n onClick?.(event);\n toggleSidebar();\n }}\n {...props}\n >\n \n Toggle Sidebar\n \n );\n});\nSidebarTrigger.displayName = 'SidebarTrigger';\n\nconst SidebarRail = React.forwardRef>(\n ({ className, ...props }, ref) => {\n const { toggleSidebar } = useSidebar();\n\n return (\n \n );\n },\n);\nSidebarRail.displayName = 'SidebarRail';\n\nconst SidebarInset = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarInset.displayName = 'SidebarInset';\n\nconst SidebarInput = React.forwardRef<\n React.ElementRef,\n React.ComponentProps\n>(({ className, ...props }, ref) => {\n return (\n \n );\n});\nSidebarInput.displayName = 'SidebarInput';\n\nconst SidebarHeader = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarHeader.displayName = 'SidebarHeader';\n\nconst SidebarFooter = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarFooter.displayName = 'SidebarFooter';\n\nconst SidebarSeparator = React.forwardRef<\n React.ElementRef,\n React.ComponentProps\n>(({ className, ...props }, ref) => {\n return (\n \n );\n});\nSidebarSeparator.displayName = 'SidebarSeparator';\n\nconst SidebarContent = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarContent.displayName = 'SidebarContent';\n\nconst SidebarGroup = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarGroup.displayName = 'SidebarGroup';\n\nconst SidebarGroupLabel = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & { asChild?: boolean }\n>(({ className, asChild = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'div';\n\n return (\n svg]:tw-size-4 [&>svg]:tw-shrink-0',\n 'group-data-[collapsible=icon]:tw--mt-8 group-data-[collapsible=icon]:tw-opacity-0',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarGroupLabel.displayName = 'SidebarGroupLabel';\n\nconst SidebarGroupAction = React.forwardRef<\n HTMLButtonElement,\n React.ComponentProps<'button'> & { asChild?: boolean }\n>(({ className, asChild = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'button';\n\n return (\n svg]:tw-size-4 [&>svg]:tw-shrink-0',\n // Increases the hit area of the button on mobile.\n 'after:tw-absolute after:tw--inset-2 after:md:tw-hidden',\n 'group-data-[collapsible=icon]:tw-hidden',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarGroupAction.displayName = 'SidebarGroupAction';\n\nconst SidebarGroupContent = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarGroupContent.displayName = 'SidebarGroupContent';\n\nconst SidebarMenu = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenu.displayName = 'SidebarMenu';\n\nconst SidebarMenuItem = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenuItem.displayName = 'SidebarMenuItem';\n\nconst sidebarMenuButtonVariants = cva(\n 'tw-peer/menu-button tw-flex tw-w-full tw-items-center tw-gap-2 tw-overflow-hidden tw-rounded-md tw-p-2 tw-text-left tw-text-sm tw-outline-none tw-ring-sidebar-ring tw-transition-[width,height,padding] hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground focus-visible:tw-ring-2 active:tw-bg-sidebar-accent active:tw-text-sidebar-accent-foreground disabled:tw-pointer-events-none disabled:tw-opacity-50 tw-group-has-[[data-sidebar=menu-action]]/menu-item:pr-8 aria-disabled:tw-pointer-events-none aria-disabled:tw-opacity-50 data-[active=true]:tw-bg-sidebar-accent data-[active=true]:tw-font-medium data-[active=true]:tw-text-sidebar-accent-foreground data-[state=open]:hover:tw-bg-sidebar-accent data-[state=open]:hover:tw-text-sidebar-accent-foreground group-data-[collapsible=icon]:tw-!size-8 group-data-[collapsible=icon]:tw-!p-2 [&>span:last-child]:tw-truncate [&>svg]:tw-size-4 [&>svg]:tw-shrink-0',\n {\n variants: {\n variant: {\n default: 'hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground',\n outline:\n 'tw-bg-background tw-shadow-[0_0_0_1px_hsl(var(--sidebar-border))] hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground hover:tw-shadow-[0_0_0_1px_hsl(var(--sidebar-accent))]',\n },\n size: {\n default: 'tw-h-8 tw-text-sm',\n sm: 'tw-h-7 tw-text-xs',\n lg: 'tw-h-12 tw-text-sm group-data-[collapsible=icon]:tw-!p-0',\n },\n },\n defaultVariants: {\n variant: 'default',\n size: 'default',\n },\n },\n);\n\nconst SidebarMenuButton = React.forwardRef<\n HTMLButtonElement,\n React.ComponentProps<'button'> & {\n asChild?: boolean;\n isActive?: boolean;\n tooltip?: string | React.ComponentProps;\n } & VariantProps\n>(\n (\n {\n asChild = false,\n isActive = false,\n variant = 'default',\n size = 'default',\n tooltip,\n className,\n ...props\n },\n ref,\n ) => {\n const Comp = asChild ? Slot : 'button';\n const { isMobile, state } = useSidebar();\n\n const button = (\n \n );\n\n if (!tooltip) {\n return button;\n }\n\n if (typeof tooltip === 'string') {\n // eslint-disable-next-line no-param-reassign\n tooltip = {\n children: tooltip,\n };\n }\n\n return (\n \n {button}\n \n );\n },\n);\nSidebarMenuButton.displayName = 'SidebarMenuButton';\n\nconst SidebarMenuAction = React.forwardRef<\n HTMLButtonElement,\n React.ComponentProps<'button'> & {\n asChild?: boolean;\n showOnHover?: boolean;\n }\n>(({ className, asChild = false, showOnHover = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'button';\n\n return (\n svg]:tw-size-4 [&>svg]:tw-shrink-0',\n // Increases the hit area of the button on mobile.\n 'after:tw-absolute after:tw--inset-2 after:md:tw-hidden',\n 'tw-peer-data-[size=sm]/menu-button:top-1',\n 'tw-peer-data-[size=default]/menu-button:top-1.5',\n 'tw-peer-data-[size=lg]/menu-button:top-2.5',\n 'group-data-[collapsible=icon]:tw-hidden',\n showOnHover &&\n 'tw-group-focus-within/menu-item:opacity-100 tw-group-hover/menu-item:opacity-100 tw-peer-data-[active=true]/menu-button:text-sidebar-accent-foreground data-[state=open]:tw-opacity-100 md:tw-opacity-0',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarMenuAction.displayName = 'SidebarMenuAction';\n\nconst SidebarMenuBadge = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenuBadge.displayName = 'SidebarMenuBadge';\n\nconst SidebarMenuSkeleton = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & {\n showIcon?: boolean;\n }\n>(({ className, showIcon = false, ...props }, ref) => {\n // Random width between 50 to 90%.\n const width = React.useMemo(() => {\n return `${Math.floor(Math.random() * 40) + 50}%`;\n }, []);\n\n return (\n \n {showIcon && (\n \n )}\n \n
    \n );\n});\nSidebarMenuSkeleton.displayName = 'SidebarMenuSkeleton';\n\nconst SidebarMenuSub = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenuSub.displayName = 'SidebarMenuSub';\n\nconst SidebarMenuSubItem = React.forwardRef>(\n ({ ...props }, ref) =>
  • ,\n);\nSidebarMenuSubItem.displayName = 'SidebarMenuSubItem';\n\nconst SidebarMenuSubButton = React.forwardRef<\n HTMLAnchorElement,\n React.ComponentProps<'a'> & {\n asChild?: boolean;\n size?: 'sm' | 'md';\n isActive?: boolean;\n }\n>(({ asChild = false, size = 'md', isActive, className, ...props }, ref) => {\n const Comp = asChild ? Slot : 'a';\n\n return (\n span:last-child]:tw-truncate [&>svg]:tw-size-4 [&>svg]:tw-shrink-0 [&>svg]:tw-text-sidebar-accent-foreground',\n 'data-[active=true]:tw-bg-sidebar-accent data-[active=true]:tw-text-sidebar-accent-foreground',\n size === 'sm' && 'tw-text-xs',\n size === 'md' && 'tw-text-sm',\n 'group-data-[collapsible=icon]:tw-hidden',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarMenuSubButton.displayName = 'SidebarMenuSubButton';\n\nexport {\n Sidebar,\n SidebarContent,\n SidebarFooter,\n SidebarGroup,\n SidebarGroupAction,\n SidebarGroupContent,\n SidebarGroupLabel,\n SidebarHeader,\n SidebarInput,\n SidebarInset,\n SidebarMenu,\n SidebarMenuAction,\n SidebarMenuBadge,\n SidebarMenuButton,\n SidebarMenuItem,\n SidebarMenuSkeleton,\n SidebarMenuSub,\n SidebarMenuSubButton,\n SidebarMenuSubItem,\n SidebarProvider,\n SidebarRail,\n SidebarSeparator,\n SidebarTrigger,\n useSidebar,\n};\n","import ComboBox, { ComboBoxOption } from '@/components/basics/combo-box.component';\nimport {\n Sidebar,\n SidebarContent,\n SidebarGroup,\n SidebarGroupLabel,\n SidebarGroupContent,\n SidebarMenu,\n SidebarMenuItem,\n SidebarMenuButton,\n} from '@/components/shadcn-ui/sidebar';\nimport { useCallback } from 'react';\n\nexport type SelectedSettingsSidebarItem = {\n label: string;\n projectId?: string;\n};\n\nexport type ProjectOptions = { projectId: string; projectName: string };\n\nexport type SettingsSidebarProps = {\n /** Optional id for testing */\n id?: string;\n\n /** Extension labels from contribution */\n extensionLabels: string[];\n\n /** Project names and ids */\n projectOptions: ProjectOptions[];\n\n /** Handler for selecting a sidebar item */\n handleSelectSidebarItem: (key: string, projectId?: string) => void;\n\n /** The current selected value in the sidebar */\n selectedSidebarItem: SelectedSettingsSidebarItem | undefined;\n};\n\nexport default function SettingsSidebar({\n id,\n extensionLabels,\n projectOptions,\n handleSelectSidebarItem,\n selectedSidebarItem,\n}: SettingsSidebarProps) {\n const handleSelectItem = useCallback(\n (item: string, projectId?: string) => {\n handleSelectSidebarItem(item, projectId);\n },\n [handleSelectSidebarItem],\n );\n\n const getProjectNameFromProjectId = useCallback(\n (projectId: string) => {\n const project = projectOptions.find((option) => option.projectId === projectId);\n return project ? project.projectName : projectId;\n },\n [projectOptions],\n );\n\n return (\n \n \n \n Extensions\n \n \n {extensionLabels.map((label) => (\n \n handleSelectItem(label)}\n isActive={\n !selectedSidebarItem?.projectId && label === selectedSidebarItem?.label\n }\n >\n {label}\n \n \n ))}\n \n \n \n \n Projects\n \n option.projectId)}\n getOptionLabel={(projectId: ComboBoxOption) => {\n // This function expects a ComboBoxOption, but we know it is a string\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n return getProjectNameFromProjectId(projectId as string);\n }}\n buttonPlaceholder=\"Type or select project\"\n onChange={(projectId: string) => {\n const selectedProjectName = getProjectNameFromProjectId(projectId);\n handleSelectItem(selectedProjectName, projectId);\n }}\n value={selectedSidebarItem?.projectId ?? undefined}\n />\n \n \n \n \n );\n}\n","import { SidebarInset, SidebarProvider } from '@/components/shadcn-ui/sidebar';\nimport { PropsWithChildren } from 'react';\nimport SettingsSidebar, { SettingsSidebarProps } from './settings-sidebar.component';\n\nexport type SettingsSidebarContentSearchProps = SettingsSidebarProps &\n PropsWithChildren & {\n /** Optional id for testing */\n id?: string;\n\n /** Text direction ltr or rtl */\n direction?: 'ltr' | 'rtl';\n };\n\nexport default function SettingsSidebarContentSearch({\n id,\n direction = 'ltr',\n extensionLabels,\n projectOptions,\n children,\n handleSelectSidebarItem,\n selectedSidebarItem,\n}: SettingsSidebarContentSearchProps) {\n return (\n \n \n {children}\n \n );\n}\n","import { Button } from '@/components/shadcn-ui/button';\nimport {\n Select,\n SelectContent,\n SelectGroup,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\nimport {\n Table,\n TableBody,\n TableCell,\n TableHead,\n TableHeader,\n TableRow,\n} from '@/components/shadcn-ui/table';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Canon } from '@sillsdev/scripture';\nimport {\n Cell,\n ColumnDef,\n flexRender,\n getCoreRowModel,\n getExpandedRowModel,\n getGroupedRowModel,\n getSortedRowModel,\n GroupingState,\n Row,\n RowSelectionState,\n SortingState,\n useReactTable,\n} from '@tanstack/react-table';\nimport '@/components/advanced/scripture-results-viewer/scripture-results-viewer.component.css';\nimport {\n compareScrRefs,\n formatScrRef,\n ScriptureSelection,\n scrRefToBBBCCCVVV,\n} from 'platform-bible-utils';\nimport { MouseEvent, useEffect, useMemo, useState } from 'react';\nimport { ChevronDown, ChevronLeft, ChevronRight } from 'lucide-react';\n\n/**\n * Information (e.g., a checking error or some other type of \"transient\" annotation) about something\n * noteworthy at a specific place in an instance of the Scriptures.\n */\nexport type ScriptureItemDetail = ScriptureSelection & {\n /**\n * Text of the error, note, etc. In the future, we might want to support something more than just\n * text so that a JSX element could be provided with a link or some other controls related to the\n * issue being reported.\n */\n detail: string;\n};\n\n/**\n * A uniquely identifiable source of results that can be displayed in the ScriptureResultsViewer.\n * Generally, the source will be a particular Scripture check, but there may be other types of\n * sources.\n */\nexport type ResultsSource = {\n /**\n * Uniquely identifies the source.\n *\n * @type {string}\n */\n id: string;\n\n /**\n * Name (potentially localized) of the source, suitable for display in the UI.\n *\n * @type {string}\n */\n displayName: string;\n};\n\nexport type ScriptureSrcItemDetail = ScriptureItemDetail & {\n /** Source/type of detail. Can be used for grouping. */\n source: ResultsSource;\n};\n\n/**\n * Represents a set of results keyed by Scripture reference. Generally, the source will be a\n * particular Scripture check, but this type also allows for other types of uniquely identifiable\n * sources.\n */\nexport type ResultsSet = {\n /**\n * The backing source associated with this set of results.\n *\n * @type {ResultsSource}\n */\n source: ResultsSource;\n\n /**\n * Array of Scripture item details (messages keyed by Scripture reference).\n *\n * @type {ScriptureItemDetail[]}\n */\n data: ScriptureItemDetail[];\n};\n\nconst scrBookColId = 'scrBook';\nconst scrRefColId = 'scrRef';\nconst typeColId = 'source';\nconst detailsColId = 'details';\n\nconst defaultScrRefColumnName = 'Scripture Reference';\nconst defaultScrBookGroupName = 'Scripture Book';\nconst defaultTypeColumnName = 'Type';\nconst defaultDetailsColumnName = 'Details';\n\nexport type ScriptureResultsViewerColumnInfo = {\n /** Optional header to display for the Reference column. Default value: 'Scripture Reference'. */\n scriptureReferenceColumnName?: string;\n\n /** Optional text to display to refer to the Scripture book group. Default value: 'Scripture Book'. */\n scriptureBookGroupName?: string;\n\n /** Optional header to display for the Type column. Default value: 'Type'. */\n typeColumnName?: string;\n\n /** Optional header to display for the Details column. Default value: 'Details' */\n detailsColumnName?: string;\n};\n\nexport type ScriptureResultsViewerProps = ScriptureResultsViewerColumnInfo & {\n /** Groups of ScriptureItemDetail objects from particular sources (e.g., Scripture checks) */\n sources: ResultsSet[];\n\n /** Flag indicating whether to display column headers. Default is false. */\n showColumnHeaders?: boolean;\n\n /** Flag indicating whether to display source column. Default is false. */\n showSourceColumn?: boolean;\n\n /** Callback function to notify when a row is selected */\n onRowSelected?: (selectedRow: ScriptureSrcItemDetail | undefined) => void;\n\n /** Text direction ltr or rtl */\n direction?: 'ltr' | 'rtl';\n};\n\nfunction getColumns(\n colInfo?: ScriptureResultsViewerColumnInfo,\n showSourceColumn?: boolean,\n): ColumnDef[] {\n const showSrcCol = showSourceColumn ?? false;\n return [\n {\n accessorFn: (row) =>\n `${Canon.bookNumberToId(row.start.bookNum)} ${row.start.chapterNum}:${row.start.verseNum}`,\n id: scrBookColId,\n header: colInfo?.scriptureReferenceColumnName ?? defaultScrRefColumnName,\n cell: (info) => {\n const row = info.row.original;\n if (info.row.getIsGrouped()) {\n return Canon.bookNumberToEnglishName(row.start.bookNum);\n }\n return info.row.groupingColumnId === scrBookColId ? formatScrRef(row.start) : undefined;\n },\n getGroupingValue: (row) => row.start.bookNum,\n sortingFn: (a, b) => {\n return compareScrRefs(a.original.start, b.original.start);\n },\n enableGrouping: true,\n },\n {\n accessorFn: (row) => formatScrRef(row.start),\n id: scrRefColId,\n header: undefined,\n cell: (info) => {\n const row = info.row.original;\n return info.row.getIsGrouped() ? undefined : formatScrRef(row.start);\n },\n sortingFn: (a, b) => {\n return compareScrRefs(a.original.start, b.original.start);\n },\n enableGrouping: false,\n },\n {\n accessorFn: (row) => row.source.displayName,\n id: typeColId,\n header: showSrcCol ? (colInfo?.typeColumnName ?? defaultTypeColumnName) : undefined,\n cell: (info) => (showSrcCol || info.row.getIsGrouped() ? info.getValue() : undefined),\n getGroupingValue: (row) => row.source.id,\n sortingFn: (a, b) =>\n a.original.source.displayName.localeCompare(b.original.source.displayName),\n enableGrouping: true,\n },\n {\n accessorFn: (row) => row.detail,\n id: detailsColId,\n header: colInfo?.detailsColumnName ?? defaultDetailsColumnName,\n cell: (info) => info.getValue(),\n enableGrouping: false,\n },\n ];\n}\n\nconst toRefOrRange = (scriptureSelection: ScriptureSelection) => {\n if (!('offset' in scriptureSelection.start))\n throw new Error('No offset available in range start');\n if (scriptureSelection.end && !('offset' in scriptureSelection.end))\n throw new Error('No offset available in range end');\n const { offset: offsetStart } = scriptureSelection.start;\n let offsetEnd: number = 0;\n if (scriptureSelection.end) ({ offset: offsetEnd } = scriptureSelection.end);\n if (\n !scriptureSelection.end ||\n compareScrRefs(scriptureSelection.start, scriptureSelection.end) === 0\n )\n return `${scrRefToBBBCCCVVV(scriptureSelection.start)}+${offsetStart}`;\n return `${scrRefToBBBCCCVVV(scriptureSelection.start)}+${offsetStart}-${scrRefToBBBCCCVVV(scriptureSelection.end)}+${offsetEnd}`;\n};\n\nconst getRowKey = (row: ScriptureSrcItemDetail) =>\n `${toRefOrRange({ start: row.start, end: row.end })} ${row.source.displayName} ${row.detail}`;\n\n/**\n * Component to display a combined list of detailed items from one or more sources, where the items\n * are keyed primarily by Scripture reference. This is particularly useful for displaying a list of\n * results from Scripture checks, but more generally could be used to display any \"results\" from any\n * source(s). The component allows for grouping by Scripture book, source, or both. By default, it\n * displays somewhat \"tree-like\" which allows it to be more horizontally compact and intuitive. But\n * it also has the option of displaying as a traditional table with column headings (with or without\n * the source column showing).\n */\nexport default function ScriptureResultsViewer({\n sources,\n showColumnHeaders = false,\n showSourceColumn = false,\n scriptureReferenceColumnName,\n scriptureBookGroupName,\n typeColumnName,\n detailsColumnName,\n onRowSelected,\n direction = 'ltr',\n}: ScriptureResultsViewerProps) {\n const [grouping, setGrouping] = useState([]);\n const [sorting, setSorting] = useState([{ id: scrBookColId, desc: false }]);\n const [rowSelection, setRowSelection] = useState({});\n\n const scriptureResults = useMemo(\n () =>\n sources.flatMap((source) => {\n return source.data.map((item) => ({\n ...item,\n source: source.source,\n }));\n }),\n [sources],\n );\n\n const columns = useMemo(\n () =>\n getColumns(\n {\n scriptureReferenceColumnName,\n typeColumnName,\n detailsColumnName,\n },\n showSourceColumn,\n ),\n [scriptureReferenceColumnName, typeColumnName, detailsColumnName, showSourceColumn],\n );\n\n useEffect(() => {\n // Ensure sorting is applied correctly when grouped by type\n if (grouping.includes(typeColId)) {\n setSorting([\n { id: typeColId, desc: false },\n { id: scrBookColId, desc: false },\n ]);\n } else {\n setSorting([{ id: scrBookColId, desc: false }]);\n }\n }, [grouping]);\n\n const table = useReactTable({\n data: scriptureResults,\n columns,\n state: {\n grouping,\n sorting,\n rowSelection,\n },\n onGroupingChange: setGrouping,\n onSortingChange: setSorting,\n onRowSelectionChange: setRowSelection,\n getExpandedRowModel: getExpandedRowModel(),\n getGroupedRowModel: getGroupedRowModel(),\n getCoreRowModel: getCoreRowModel(),\n getSortedRowModel: getSortedRowModel(),\n getRowId: getRowKey,\n autoResetExpanded: false,\n enableMultiRowSelection: false,\n enableSubRowSelection: false,\n });\n\n useEffect(() => {\n if (onRowSelected) {\n const selectedRows = table.getSelectedRowModel().rowsById;\n const keys = Object.keys(selectedRows);\n if (keys.length === 1) {\n const selectedRow = scriptureResults.find((row) => getRowKey(row) === keys[0]) || undefined;\n if (selectedRow) onRowSelected(selectedRow);\n }\n }\n }, [rowSelection, scriptureResults, onRowSelected, table]);\n\n // Define possible grouping options\n const scrBookGroupName = scriptureBookGroupName ?? defaultScrBookGroupName;\n const typeGroupName = typeColumnName ?? defaultTypeColumnName;\n\n const groupingOptions = [\n { label: 'No Grouping', value: [] },\n { label: `Group by ${scrBookGroupName}`, value: [scrBookColId] },\n { label: `Group by ${typeGroupName}`, value: [typeColId] },\n {\n label: `Group by ${scrBookGroupName} and ${typeGroupName}`,\n value: [scrBookColId, typeColId],\n },\n {\n label: `Group by ${typeGroupName} and ${scrBookGroupName}`,\n value: [typeColId, scrBookColId],\n },\n ];\n\n const handleSelectChange = (selectedGrouping: string) => {\n setGrouping(JSON.parse(selectedGrouping));\n };\n\n const handleRowClick = (row: Row, event: MouseEvent) => {\n if (!row.getIsGrouped() && !row.getIsSelected()) {\n row.getToggleSelectedHandler()(event);\n }\n };\n\n const getEvenOrOddBandingStyle = (row: Row, index: number) => {\n if (row.getIsGrouped()) return '';\n // UX has now said they don't think they want banding. I'm leaving in the code to\n // set even and odd styles, but there's nothing in the CSS to style them differently.\n // The \"even\" style used to also have tw-bg-neutral-300 (along with even) to create\n // a visual banding effect. That could be added back in if UX changes the decision.\n return cn('banded-row', index % 2 === 0 ? 'even' : 'odd');\n };\n\n const getIndent = (\n groupingState: GroupingState,\n row: Row,\n cell: Cell,\n ) => {\n if (groupingState?.length === 0 || row.depth < cell.column.getGroupedIndex()) return undefined;\n if (row.getIsGrouped()) {\n switch (row.depth) {\n case 1:\n return 'tw-ps-4';\n default:\n return undefined;\n }\n }\n switch (row.depth) {\n case 1:\n return 'tw-ps-8';\n case 2:\n return 'tw-ps-12';\n default:\n return undefined;\n }\n };\n\n return (\n
    \n {!showColumnHeaders && (\n {\n handleSelectChange(value);\n }}\n >\n \n \n \n \n \n {groupingOptions.map((option) => (\n \n {option.label}\n \n ))}\n \n \n \n )}\n \n {showColumnHeaders && (\n \n {table.getHeaderGroups().map((headerGroup) => (\n \n {headerGroup.headers\n .filter((h) => h.column.columnDef.header)\n .map((header) => (\n /* For sticky column headers to work, we probably need to change the default definition of the shadcn Table component. See https://github.com/shadcn-ui/ui/issues/1151 */\n \n {header.isPlaceholder ? undefined : (\n
    \n {header.column.getCanGroup() ? (\n \n {header.column.getIsGrouped() ? `🛑` : `👊 `}\n \n ) : undefined}{' '}\n {flexRender(header.column.columnDef.header, header.getContext())}\n
    \n )}\n
    \n ))}\n
    \n ))}\n
    \n )}\n \n {table.getRowModel().rows.map((row, rowIndex) => {\n return (\n handleRowClick(row, event)}\n >\n {row.getVisibleCells().map((cell) => {\n if (\n cell.getIsPlaceholder() ||\n (cell.column.columnDef.enableGrouping &&\n !cell.getIsGrouped() &&\n (cell.column.columnDef.id !== typeColId || !showSourceColumn))\n )\n return undefined;\n return (\n \n {(() => {\n if (cell.getIsGrouped()) {\n return (\n \n {row.getIsExpanded() && }\n {!row.getIsExpanded() &&\n (direction === 'ltr' ? : )}{' '}\n {flexRender(cell.column.columnDef.cell, cell.getContext())} (\n {row.subRows.length})\n \n );\n }\n\n // if (cell.getIsAggregated()) {\n // flexRender(\n // cell.column.columnDef.aggregatedCell ?? cell.column.columnDef.cell,\n // cell.getContext(),\n // );\n // }\n\n return flexRender(cell.column.columnDef.cell, cell.getContext());\n })()}\n \n );\n })}\n \n );\n })}\n \n
    \n
    \n );\n}\n","import {\n getLocalizeKeyForScrollGroupId,\n LanguageStrings,\n ScrollGroupId,\n} from 'platform-bible-utils';\nimport {\n Select,\n SelectContent,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\n\nconst DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS = {\n [getLocalizeKeyForScrollGroupId('undefined')]: 'Ø',\n [getLocalizeKeyForScrollGroupId(0)]: 'A',\n [getLocalizeKeyForScrollGroupId(1)]: 'B',\n [getLocalizeKeyForScrollGroupId(2)]: 'C',\n [getLocalizeKeyForScrollGroupId(3)]: 'D',\n [getLocalizeKeyForScrollGroupId(4)]: 'E',\n [getLocalizeKeyForScrollGroupId(5)]: 'F',\n [getLocalizeKeyForScrollGroupId(6)]: 'G',\n [getLocalizeKeyForScrollGroupId(7)]: 'H',\n [getLocalizeKeyForScrollGroupId(8)]: 'I',\n [getLocalizeKeyForScrollGroupId(9)]: 'J',\n [getLocalizeKeyForScrollGroupId(10)]: 'K',\n [getLocalizeKeyForScrollGroupId(11)]: 'L',\n [getLocalizeKeyForScrollGroupId(12)]: 'M',\n [getLocalizeKeyForScrollGroupId(13)]: 'N',\n [getLocalizeKeyForScrollGroupId(14)]: 'O',\n [getLocalizeKeyForScrollGroupId(15)]: 'P',\n [getLocalizeKeyForScrollGroupId(16)]: 'Q',\n [getLocalizeKeyForScrollGroupId(17)]: 'R',\n [getLocalizeKeyForScrollGroupId(18)]: 'S',\n [getLocalizeKeyForScrollGroupId(19)]: 'T',\n [getLocalizeKeyForScrollGroupId(20)]: 'U',\n [getLocalizeKeyForScrollGroupId(21)]: 'V',\n [getLocalizeKeyForScrollGroupId(22)]: 'W',\n [getLocalizeKeyForScrollGroupId(23)]: 'X',\n [getLocalizeKeyForScrollGroupId(24)]: 'Y',\n [getLocalizeKeyForScrollGroupId(25)]: 'Z',\n};\n\nexport type ScrollGroupSelectorProps = {\n /**\n * List of scroll group ids to show to the user. Either a {@link ScrollGroupId} or `undefined` for\n * no scroll group\n */\n availableScrollGroupIds: (ScrollGroupId | undefined)[];\n /** Currently selected scroll group id. `undefined` for no scroll group */\n scrollGroupId: ScrollGroupId | undefined;\n /** Callback function run when the user tries to change the scroll group id */\n onChangeScrollGroupId: (newScrollGroupId: ScrollGroupId | undefined) => void;\n /**\n * Localized strings to use for displaying scroll group ids. Must be an object whose keys are\n * `getLocalizeKeyForScrollGroupId(scrollGroupId)` for all scroll group ids (and `undefined` if\n * included) in {@link ScrollGroupSelectorProps.availableScrollGroupIds} and whose values are the\n * localized strings to use for those scroll group ids.\n *\n * Defaults to English localizations of English alphabet for scroll groups 0-25 (e.g. 0 is A) and\n * Ø for `undefined`. Will fill in any that are not provided with these English localizations.\n * Also, if any values match the keys, the English localization will be used. This is useful in\n * case you want to pass in a temporary version of the localized strings while your localized\n * strings load.\n *\n * @example\n *\n * ```typescript\n * const myScrollGroupIdLocalizedStrings = {\n * [getLocalizeKeyForScrollGroupId('undefined')]: 'Ø',\n * [getLocalizeKeyForScrollGroupId(0)]: 'A',\n * [getLocalizeKeyForScrollGroupId(1)]: 'B',\n * [getLocalizeKeyForScrollGroupId(2)]: 'C',\n * [getLocalizeKeyForScrollGroupId(3)]: 'D',\n * [getLocalizeKeyForScrollGroupId(4)]: 'E',\n * };\n * ```\n *\n * @example\n *\n * ```tsx\n * const availableScrollGroupIds = [undefined, 0, 1, 2, 3, 4];\n *\n * const localizeKeys = getLocalizeKeysForScrollGroupIds();\n *\n * const [localizedStrings] = useLocalizedStrings(localizeKeys);\n *\n * ...\n *\n * \n * ```\n */\n localizedStrings?: LanguageStrings;\n};\n\n/** Selector component for choosing a scroll group */\nexport default function ScrollGroupSelector({\n availableScrollGroupIds,\n scrollGroupId,\n onChangeScrollGroupId,\n localizedStrings = {},\n}: ScrollGroupSelectorProps) {\n const localizedStringsDefaulted = {\n ...DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS,\n ...Object.fromEntries(\n Object.entries(localizedStrings).map(\n ([localizedStringKey, localizedStringValue]: [string, string]) => [\n localizedStringKey,\n localizedStringKey === localizedStringValue &&\n localizedStringKey in DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS\n ? DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS[localizedStringKey]\n : localizedStringValue,\n ],\n ),\n ),\n };\n return (\n \n onChangeScrollGroupId(\n newScrollGroupString === 'undefined' ? undefined : parseInt(newScrollGroupString, 10),\n )\n }\n >\n \n \n \n \n {availableScrollGroupIds.map((scrollGroupOptionId) => (\n \n {localizedStringsDefaulted[getLocalizeKeyForScrollGroupId(scrollGroupOptionId)]}\n \n ))}\n \n \n );\n}\n","import { PropsWithChildren } from 'react';\nimport { Separator } from '@/components/shadcn-ui/separator';\n\n/** Props for the SettingsList component, currently just children */\ntype SettingsListProps = PropsWithChildren;\n\n/**\n * SettingsList component is a wrapper for list items. Rendered with a formatted div\n *\n * @param children To populate the list with\n * @returns Formatted div encompassing the children\n */\nexport function SettingsList({ children }: SettingsListProps) {\n return
    {children}
    ;\n}\n\n/** Props for SettingsListItem component */\ntype SettingsListItemProps = PropsWithChildren & {\n /** Primary text of the list item */\n primary: string;\n\n /** Optional text of the list item */\n secondary?: string | undefined;\n\n /** Optional boolean to display a message if the children aren't loaded yet. Defaults to false */\n isLoading?: boolean;\n\n /** Optional message to display if isLoading */\n loadingMessage?: string;\n};\n\n/**\n * SettingsListItem component is a common list item. Rendered with a formatted div\n *\n * @param primary Primary text of the list item\n * @param secondary Optional secondary text of the list item\n * @param isLoading Optional, to display a message if the action component isn't generated yet,\n * defaults to false\n * @param children The action component(s) to provide for this item\n * @param loadingMessage Optional, message to display if isLoading\n * @returns Formatted div encompassing the list item content\n */\nexport function SettingsListItem({\n primary,\n secondary,\n children,\n isLoading = false,\n loadingMessage,\n}: SettingsListItemProps) {\n return (\n
    \n
    \n

    {primary}

    \n

    \n {secondary}\n

    \n
    \n\n {isLoading ? (\n

    {loadingMessage}

    \n ) : (\n
    {children}
    \n )}\n
    \n );\n}\n\n/** Props for SettingsListHeader component */\ntype SettingsListHeaderProps = {\n /** The primary text of the list header */\n primary: string;\n\n /** Optional secondary text of the list header */\n secondary?: string | undefined;\n\n /** Optional boolean to include a separator underneath the secondary text. Defaults to false */\n includeSeparator?: boolean;\n};\n\n/**\n * SettingsListHeader component displays text above the list\n *\n * @param primary The primary text of the list header\n * @param secondary Optional secondary text of the list header\n * @param includeSeparator Optional boolean to include a separator underneath the secondary text.\n * Defaults to false\n * @returns Formatted div with list header content\n */\nexport function SettingsListHeader({\n primary,\n secondary,\n includeSeparator = false,\n}: SettingsListHeaderProps) {\n return (\n
    \n
    \n

    {primary}

    \n

    {secondary}

    \n
    \n {includeSeparator ? : ''}\n
    \n );\n}\n","import React from 'react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Card = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nCard.displayName = 'Card';\n\nconst CardHeader = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nCardHeader.displayName = 'CardHeader';\n\nconst CardTitle = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n {/* added because of https://github.com/jsx-eslint/eslint-plugin-jsx-a11y/blob/main/docs/rules/heading-has-content.md */}\n {props.children}\n \n ),\n);\nCardTitle.displayName = 'CardTitle';\n\nconst CardDescription = React.forwardRef<\n HTMLParagraphElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n

    \n));\nCardDescription.displayName = 'CardDescription';\n\nconst CardContent = React.forwardRef>(\n ({ className, ...props }, ref) => (\n

    \n ),\n);\nCardContent.displayName = 'CardContent';\n\nconst CardFooter = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nCardFooter.displayName = 'CardFooter';\n\nexport { Card, CardHeader, CardFooter, CardTitle, CardDescription, CardContent };\n","import { Card, CardDescription, CardHeader, CardTitle } from '@/components/shadcn-ui/card';\nimport { CardContent } from '@mui/material';\nimport { PropsWithChildren } from 'react';\n\ntype SettingsCardProps = PropsWithChildren & {\n /** Optional id for testing */\n id?: string;\n\n /** Label of the settings group */\n settingsGroupLabel: string;\n\n /** Optional description of the settings group */\n settingsGroupDescription?: string;\n};\n\nexport default function SettingsCard({\n id,\n settingsGroupLabel,\n settingsGroupDescription,\n children,\n}: SettingsCardProps) {\n return (\n \n \n {settingsGroupLabel}\n {settingsGroupDescription && {settingsGroupDescription}}\n \n {children}\n \n );\n}\n","import Checkbox from '@/components/shadcn-ui/checkbox';\nimport { Label } from '@/components/shadcn-ui/label';\n\nexport type ChecklistProps = {\n /** Optional string representing the id attribute of the Checklist */\n id?: string;\n /** Optional string representing CSS class name(s) for styling */\n className?: string;\n /** Array of strings representing the checkable items */\n listItems: string[];\n /** Array of strings representing the checked items */\n selectedListItems: string[];\n /**\n * Function that is called when a checkbox item is selected or deselected\n *\n * @param item The string description for this item\n * @param selected True if selected, false if not selected\n */\n handleSelectListItem: (item: string, selected: boolean) => void;\n\n /**\n * Optional function creates a label for a provided checkable item\n *\n * @param item The item for which a label is to be created\n * @returns A string representing the label text for the checkbox associated with that item\n */\n createLabel?: (item: string) => string;\n};\n\n/** Renders a list of checkboxes. Each checkbox corresponds to an item from the `listItems` array. */\nexport default function Checklist({\n id,\n className,\n listItems,\n selectedListItems,\n handleSelectListItem,\n createLabel,\n}: ChecklistProps) {\n return (\n
    \n {listItems.map((item) => (\n
    \n handleSelectListItem(item, value)}\n />\n \n
    \n ))}\n
    \n );\n}\n","function _interopRequireDefault(obj) {\n return obj && obj.__esModule ? obj : {\n \"default\": obj\n };\n}\nmodule.exports = _interopRequireDefault, module.exports.__esModule = true, module.exports[\"default\"] = module.exports;","export default function chainPropTypes(propType1, propType2) {\n if (process.env.NODE_ENV === 'production') {\n return () => null;\n }\n return function validate(...args) {\n return propType1(...args) || propType2(...args);\n };\n}","export default function _extends() {\n _extends = Object.assign ? Object.assign.bind() : function (target) {\n for (var i = 1; i < arguments.length; i++) {\n var source = arguments[i];\n for (var key in source) {\n if (Object.prototype.hasOwnProperty.call(source, key)) {\n target[key] = source[key];\n }\n }\n }\n return target;\n };\n return _extends.apply(this, arguments);\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\n// https://github.com/sindresorhus/is-plain-obj/blob/main/index.js\nexport function isPlainObject(item) {\n if (typeof item !== 'object' || item === null) {\n return false;\n }\n const prototype = Object.getPrototypeOf(item);\n return (prototype === null || prototype === Object.prototype || Object.getPrototypeOf(prototype) === null) && !(Symbol.toStringTag in item) && !(Symbol.iterator in item);\n}\nfunction deepClone(source) {\n if (!isPlainObject(source)) {\n return source;\n }\n const output = {};\n Object.keys(source).forEach(key => {\n output[key] = deepClone(source[key]);\n });\n return output;\n}\nexport default function deepmerge(target, source, options = {\n clone: true\n}) {\n const output = options.clone ? _extends({}, target) : target;\n if (isPlainObject(target) && isPlainObject(source)) {\n Object.keys(source).forEach(key => {\n // Avoid prototype pollution\n if (key === '__proto__') {\n return;\n }\n if (isPlainObject(source[key]) && key in target && isPlainObject(target[key])) {\n // Since `output` is a clone of `target` and we have narrowed `target` in this block we can cast to the same type.\n output[key] = deepmerge(target[key], source[key], options);\n } else if (options.clone) {\n output[key] = isPlainObject(source[key]) ? deepClone(source[key]) : source[key];\n } else {\n output[key] = source[key];\n }\n });\n }\n return output;\n}","/** @license React v16.13.1\n * react-is.production.min.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';var b=\"function\"===typeof Symbol&&Symbol.for,c=b?Symbol.for(\"react.element\"):60103,d=b?Symbol.for(\"react.portal\"):60106,e=b?Symbol.for(\"react.fragment\"):60107,f=b?Symbol.for(\"react.strict_mode\"):60108,g=b?Symbol.for(\"react.profiler\"):60114,h=b?Symbol.for(\"react.provider\"):60109,k=b?Symbol.for(\"react.context\"):60110,l=b?Symbol.for(\"react.async_mode\"):60111,m=b?Symbol.for(\"react.concurrent_mode\"):60111,n=b?Symbol.for(\"react.forward_ref\"):60112,p=b?Symbol.for(\"react.suspense\"):60113,q=b?\nSymbol.for(\"react.suspense_list\"):60120,r=b?Symbol.for(\"react.memo\"):60115,t=b?Symbol.for(\"react.lazy\"):60116,v=b?Symbol.for(\"react.block\"):60121,w=b?Symbol.for(\"react.fundamental\"):60117,x=b?Symbol.for(\"react.responder\"):60118,y=b?Symbol.for(\"react.scope\"):60119;\nfunction z(a){if(\"object\"===typeof a&&null!==a){var u=a.$$typeof;switch(u){case c:switch(a=a.type,a){case l:case m:case e:case g:case f:case p:return a;default:switch(a=a&&a.$$typeof,a){case k:case n:case t:case r:case h:return a;default:return u}}case d:return u}}}function A(a){return z(a)===m}exports.AsyncMode=l;exports.ConcurrentMode=m;exports.ContextConsumer=k;exports.ContextProvider=h;exports.Element=c;exports.ForwardRef=n;exports.Fragment=e;exports.Lazy=t;exports.Memo=r;exports.Portal=d;\nexports.Profiler=g;exports.StrictMode=f;exports.Suspense=p;exports.isAsyncMode=function(a){return A(a)||z(a)===l};exports.isConcurrentMode=A;exports.isContextConsumer=function(a){return z(a)===k};exports.isContextProvider=function(a){return z(a)===h};exports.isElement=function(a){return\"object\"===typeof a&&null!==a&&a.$$typeof===c};exports.isForwardRef=function(a){return z(a)===n};exports.isFragment=function(a){return z(a)===e};exports.isLazy=function(a){return z(a)===t};\nexports.isMemo=function(a){return z(a)===r};exports.isPortal=function(a){return z(a)===d};exports.isProfiler=function(a){return z(a)===g};exports.isStrictMode=function(a){return z(a)===f};exports.isSuspense=function(a){return z(a)===p};\nexports.isValidElementType=function(a){return\"string\"===typeof a||\"function\"===typeof a||a===e||a===m||a===g||a===f||a===p||a===q||\"object\"===typeof a&&null!==a&&(a.$$typeof===t||a.$$typeof===r||a.$$typeof===h||a.$$typeof===k||a.$$typeof===n||a.$$typeof===w||a.$$typeof===x||a.$$typeof===y||a.$$typeof===v)};exports.typeOf=z;\n","/** @license React v16.13.1\n * react-is.development.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\n\n\nif (process.env.NODE_ENV !== \"production\") {\n (function() {\n'use strict';\n\n// The Symbol used to tag the ReactElement-like types. If there is no native Symbol\n// nor polyfill, then a plain number is used for performance.\nvar hasSymbol = typeof Symbol === 'function' && Symbol.for;\nvar REACT_ELEMENT_TYPE = hasSymbol ? Symbol.for('react.element') : 0xeac7;\nvar REACT_PORTAL_TYPE = hasSymbol ? Symbol.for('react.portal') : 0xeaca;\nvar REACT_FRAGMENT_TYPE = hasSymbol ? Symbol.for('react.fragment') : 0xeacb;\nvar REACT_STRICT_MODE_TYPE = hasSymbol ? Symbol.for('react.strict_mode') : 0xeacc;\nvar REACT_PROFILER_TYPE = hasSymbol ? Symbol.for('react.profiler') : 0xead2;\nvar REACT_PROVIDER_TYPE = hasSymbol ? Symbol.for('react.provider') : 0xeacd;\nvar REACT_CONTEXT_TYPE = hasSymbol ? Symbol.for('react.context') : 0xeace; // TODO: We don't use AsyncMode or ConcurrentMode anymore. They were temporary\n// (unstable) APIs that have been removed. Can we remove the symbols?\n\nvar REACT_ASYNC_MODE_TYPE = hasSymbol ? Symbol.for('react.async_mode') : 0xeacf;\nvar REACT_CONCURRENT_MODE_TYPE = hasSymbol ? Symbol.for('react.concurrent_mode') : 0xeacf;\nvar REACT_FORWARD_REF_TYPE = hasSymbol ? Symbol.for('react.forward_ref') : 0xead0;\nvar REACT_SUSPENSE_TYPE = hasSymbol ? Symbol.for('react.suspense') : 0xead1;\nvar REACT_SUSPENSE_LIST_TYPE = hasSymbol ? Symbol.for('react.suspense_list') : 0xead8;\nvar REACT_MEMO_TYPE = hasSymbol ? Symbol.for('react.memo') : 0xead3;\nvar REACT_LAZY_TYPE = hasSymbol ? Symbol.for('react.lazy') : 0xead4;\nvar REACT_BLOCK_TYPE = hasSymbol ? Symbol.for('react.block') : 0xead9;\nvar REACT_FUNDAMENTAL_TYPE = hasSymbol ? Symbol.for('react.fundamental') : 0xead5;\nvar REACT_RESPONDER_TYPE = hasSymbol ? Symbol.for('react.responder') : 0xead6;\nvar REACT_SCOPE_TYPE = hasSymbol ? Symbol.for('react.scope') : 0xead7;\n\nfunction isValidElementType(type) {\n return typeof type === 'string' || typeof type === 'function' || // Note: its typeof might be other than 'symbol' or 'number' if it's a polyfill.\n type === REACT_FRAGMENT_TYPE || type === REACT_CONCURRENT_MODE_TYPE || type === REACT_PROFILER_TYPE || type === REACT_STRICT_MODE_TYPE || type === REACT_SUSPENSE_TYPE || type === REACT_SUSPENSE_LIST_TYPE || typeof type === 'object' && type !== null && (type.$$typeof === REACT_LAZY_TYPE || type.$$typeof === REACT_MEMO_TYPE || type.$$typeof === REACT_PROVIDER_TYPE || type.$$typeof === REACT_CONTEXT_TYPE || type.$$typeof === REACT_FORWARD_REF_TYPE || type.$$typeof === REACT_FUNDAMENTAL_TYPE || type.$$typeof === REACT_RESPONDER_TYPE || type.$$typeof === REACT_SCOPE_TYPE || type.$$typeof === REACT_BLOCK_TYPE);\n}\n\nfunction typeOf(object) {\n if (typeof object === 'object' && object !== null) {\n var $$typeof = object.$$typeof;\n\n switch ($$typeof) {\n case REACT_ELEMENT_TYPE:\n var type = object.type;\n\n switch (type) {\n case REACT_ASYNC_MODE_TYPE:\n case REACT_CONCURRENT_MODE_TYPE:\n case REACT_FRAGMENT_TYPE:\n case REACT_PROFILER_TYPE:\n case REACT_STRICT_MODE_TYPE:\n case REACT_SUSPENSE_TYPE:\n return type;\n\n default:\n var $$typeofType = type && type.$$typeof;\n\n switch ($$typeofType) {\n case REACT_CONTEXT_TYPE:\n case REACT_FORWARD_REF_TYPE:\n case REACT_LAZY_TYPE:\n case REACT_MEMO_TYPE:\n case REACT_PROVIDER_TYPE:\n return $$typeofType;\n\n default:\n return $$typeof;\n }\n\n }\n\n case REACT_PORTAL_TYPE:\n return $$typeof;\n }\n }\n\n return undefined;\n} // AsyncMode is deprecated along with isAsyncMode\n\nvar AsyncMode = REACT_ASYNC_MODE_TYPE;\nvar ConcurrentMode = REACT_CONCURRENT_MODE_TYPE;\nvar ContextConsumer = REACT_CONTEXT_TYPE;\nvar ContextProvider = REACT_PROVIDER_TYPE;\nvar Element = REACT_ELEMENT_TYPE;\nvar ForwardRef = REACT_FORWARD_REF_TYPE;\nvar Fragment = REACT_FRAGMENT_TYPE;\nvar Lazy = REACT_LAZY_TYPE;\nvar Memo = REACT_MEMO_TYPE;\nvar Portal = REACT_PORTAL_TYPE;\nvar Profiler = REACT_PROFILER_TYPE;\nvar StrictMode = REACT_STRICT_MODE_TYPE;\nvar Suspense = REACT_SUSPENSE_TYPE;\nvar hasWarnedAboutDeprecatedIsAsyncMode = false; // AsyncMode should be deprecated\n\nfunction isAsyncMode(object) {\n {\n if (!hasWarnedAboutDeprecatedIsAsyncMode) {\n hasWarnedAboutDeprecatedIsAsyncMode = true; // Using console['warn'] to evade Babel and ESLint\n\n console['warn']('The ReactIs.isAsyncMode() alias has been deprecated, ' + 'and will be removed in React 17+. Update your code to use ' + 'ReactIs.isConcurrentMode() instead. It has the exact same API.');\n }\n }\n\n return isConcurrentMode(object) || typeOf(object) === REACT_ASYNC_MODE_TYPE;\n}\nfunction isConcurrentMode(object) {\n return typeOf(object) === REACT_CONCURRENT_MODE_TYPE;\n}\nfunction isContextConsumer(object) {\n return typeOf(object) === REACT_CONTEXT_TYPE;\n}\nfunction isContextProvider(object) {\n return typeOf(object) === REACT_PROVIDER_TYPE;\n}\nfunction isElement(object) {\n return typeof object === 'object' && object !== null && object.$$typeof === REACT_ELEMENT_TYPE;\n}\nfunction isForwardRef(object) {\n return typeOf(object) === REACT_FORWARD_REF_TYPE;\n}\nfunction isFragment(object) {\n return typeOf(object) === REACT_FRAGMENT_TYPE;\n}\nfunction isLazy(object) {\n return typeOf(object) === REACT_LAZY_TYPE;\n}\nfunction isMemo(object) {\n return typeOf(object) === REACT_MEMO_TYPE;\n}\nfunction isPortal(object) {\n return typeOf(object) === REACT_PORTAL_TYPE;\n}\nfunction isProfiler(object) {\n return typeOf(object) === REACT_PROFILER_TYPE;\n}\nfunction isStrictMode(object) {\n return typeOf(object) === REACT_STRICT_MODE_TYPE;\n}\nfunction isSuspense(object) {\n return typeOf(object) === REACT_SUSPENSE_TYPE;\n}\n\nexports.AsyncMode = AsyncMode;\nexports.ConcurrentMode = ConcurrentMode;\nexports.ContextConsumer = ContextConsumer;\nexports.ContextProvider = ContextProvider;\nexports.Element = Element;\nexports.ForwardRef = ForwardRef;\nexports.Fragment = Fragment;\nexports.Lazy = Lazy;\nexports.Memo = Memo;\nexports.Portal = Portal;\nexports.Profiler = Profiler;\nexports.StrictMode = StrictMode;\nexports.Suspense = Suspense;\nexports.isAsyncMode = isAsyncMode;\nexports.isConcurrentMode = isConcurrentMode;\nexports.isContextConsumer = isContextConsumer;\nexports.isContextProvider = isContextProvider;\nexports.isElement = isElement;\nexports.isForwardRef = isForwardRef;\nexports.isFragment = isFragment;\nexports.isLazy = isLazy;\nexports.isMemo = isMemo;\nexports.isPortal = isPortal;\nexports.isProfiler = isProfiler;\nexports.isStrictMode = isStrictMode;\nexports.isSuspense = isSuspense;\nexports.isValidElementType = isValidElementType;\nexports.typeOf = typeOf;\n })();\n}\n","'use strict';\n\nif (process.env.NODE_ENV === 'production') {\n module.exports = require('./cjs/react-is.production.min.js');\n} else {\n module.exports = require('./cjs/react-is.development.js');\n}\n","/*\nobject-assign\n(c) Sindre Sorhus\n@license MIT\n*/\n\n'use strict';\n/* eslint-disable no-unused-vars */\nvar getOwnPropertySymbols = Object.getOwnPropertySymbols;\nvar hasOwnProperty = Object.prototype.hasOwnProperty;\nvar propIsEnumerable = Object.prototype.propertyIsEnumerable;\n\nfunction toObject(val) {\n\tif (val === null || val === undefined) {\n\t\tthrow new TypeError('Object.assign cannot be called with null or undefined');\n\t}\n\n\treturn Object(val);\n}\n\nfunction shouldUseNative() {\n\ttry {\n\t\tif (!Object.assign) {\n\t\t\treturn false;\n\t\t}\n\n\t\t// Detect buggy property enumeration order in older V8 versions.\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=4118\n\t\tvar test1 = new String('abc'); // eslint-disable-line no-new-wrappers\n\t\ttest1[5] = 'de';\n\t\tif (Object.getOwnPropertyNames(test1)[0] === '5') {\n\t\t\treturn false;\n\t\t}\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=3056\n\t\tvar test2 = {};\n\t\tfor (var i = 0; i < 10; i++) {\n\t\t\ttest2['_' + String.fromCharCode(i)] = i;\n\t\t}\n\t\tvar order2 = Object.getOwnPropertyNames(test2).map(function (n) {\n\t\t\treturn test2[n];\n\t\t});\n\t\tif (order2.join('') !== '0123456789') {\n\t\t\treturn false;\n\t\t}\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=3056\n\t\tvar test3 = {};\n\t\t'abcdefghijklmnopqrst'.split('').forEach(function (letter) {\n\t\t\ttest3[letter] = letter;\n\t\t});\n\t\tif (Object.keys(Object.assign({}, test3)).join('') !==\n\t\t\t\t'abcdefghijklmnopqrst') {\n\t\t\treturn false;\n\t\t}\n\n\t\treturn true;\n\t} catch (err) {\n\t\t// We don't expect any of the above to throw, but better to be safe.\n\t\treturn false;\n\t}\n}\n\nmodule.exports = shouldUseNative() ? Object.assign : function (target, source) {\n\tvar from;\n\tvar to = toObject(target);\n\tvar symbols;\n\n\tfor (var s = 1; s < arguments.length; s++) {\n\t\tfrom = Object(arguments[s]);\n\n\t\tfor (var key in from) {\n\t\t\tif (hasOwnProperty.call(from, key)) {\n\t\t\t\tto[key] = from[key];\n\t\t\t}\n\t\t}\n\n\t\tif (getOwnPropertySymbols) {\n\t\t\tsymbols = getOwnPropertySymbols(from);\n\t\t\tfor (var i = 0; i < symbols.length; i++) {\n\t\t\t\tif (propIsEnumerable.call(from, symbols[i])) {\n\t\t\t\t\tto[symbols[i]] = from[symbols[i]];\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\n\treturn to;\n};\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar ReactPropTypesSecret = 'SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED';\n\nmodule.exports = ReactPropTypesSecret;\n","module.exports = Function.call.bind(Object.prototype.hasOwnProperty);\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar printWarning = function() {};\n\nif (process.env.NODE_ENV !== 'production') {\n var ReactPropTypesSecret = require('./lib/ReactPropTypesSecret');\n var loggedTypeFailures = {};\n var has = require('./lib/has');\n\n printWarning = function(text) {\n var message = 'Warning: ' + text;\n if (typeof console !== 'undefined') {\n console.error(message);\n }\n try {\n // --- Welcome to debugging React ---\n // This error was thrown as a convenience so that you can use this stack\n // to find the callsite that caused this warning to fire.\n throw new Error(message);\n } catch (x) { /**/ }\n };\n}\n\n/**\n * Assert that the values match with the type specs.\n * Error messages are memorized and will only be shown once.\n *\n * @param {object} typeSpecs Map of name to a ReactPropType\n * @param {object} values Runtime values that need to be type-checked\n * @param {string} location e.g. \"prop\", \"context\", \"child context\"\n * @param {string} componentName Name of the component for error messages.\n * @param {?Function} getStack Returns the component stack.\n * @private\n */\nfunction checkPropTypes(typeSpecs, values, location, componentName, getStack) {\n if (process.env.NODE_ENV !== 'production') {\n for (var typeSpecName in typeSpecs) {\n if (has(typeSpecs, typeSpecName)) {\n var error;\n // Prop type validation may throw. In case they do, we don't want to\n // fail the render phase where it didn't fail before. So we log it.\n // After these have been cleaned up, we'll let them throw.\n try {\n // This is intentionally an invariant that gets caught. It's the same\n // behavior as without this statement except with a better message.\n if (typeof typeSpecs[typeSpecName] !== 'function') {\n var err = Error(\n (componentName || 'React class') + ': ' + location + ' type `' + typeSpecName + '` is invalid; ' +\n 'it must be a function, usually from the `prop-types` package, but received `' + typeof typeSpecs[typeSpecName] + '`.' +\n 'This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.'\n );\n err.name = 'Invariant Violation';\n throw err;\n }\n error = typeSpecs[typeSpecName](values, typeSpecName, componentName, location, null, ReactPropTypesSecret);\n } catch (ex) {\n error = ex;\n }\n if (error && !(error instanceof Error)) {\n printWarning(\n (componentName || 'React class') + ': type specification of ' +\n location + ' `' + typeSpecName + '` is invalid; the type checker ' +\n 'function must return `null` or an `Error` but returned a ' + typeof error + '. ' +\n 'You may have forgotten to pass an argument to the type checker ' +\n 'creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and ' +\n 'shape all require an argument).'\n );\n }\n if (error instanceof Error && !(error.message in loggedTypeFailures)) {\n // Only monitor this failure once because there tends to be a lot of the\n // same error.\n loggedTypeFailures[error.message] = true;\n\n var stack = getStack ? getStack() : '';\n\n printWarning(\n 'Failed ' + location + ' type: ' + error.message + (stack != null ? stack : '')\n );\n }\n }\n }\n }\n}\n\n/**\n * Resets warning cache when testing.\n *\n * @private\n */\ncheckPropTypes.resetWarningCache = function() {\n if (process.env.NODE_ENV !== 'production') {\n loggedTypeFailures = {};\n }\n}\n\nmodule.exports = checkPropTypes;\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar ReactIs = require('react-is');\nvar assign = require('object-assign');\n\nvar ReactPropTypesSecret = require('./lib/ReactPropTypesSecret');\nvar has = require('./lib/has');\nvar checkPropTypes = require('./checkPropTypes');\n\nvar printWarning = function() {};\n\nif (process.env.NODE_ENV !== 'production') {\n printWarning = function(text) {\n var message = 'Warning: ' + text;\n if (typeof console !== 'undefined') {\n console.error(message);\n }\n try {\n // --- Welcome to debugging React ---\n // This error was thrown as a convenience so that you can use this stack\n // to find the callsite that caused this warning to fire.\n throw new Error(message);\n } catch (x) {}\n };\n}\n\nfunction emptyFunctionThatReturnsNull() {\n return null;\n}\n\nmodule.exports = function(isValidElement, throwOnDirectAccess) {\n /* global Symbol */\n var ITERATOR_SYMBOL = typeof Symbol === 'function' && Symbol.iterator;\n var FAUX_ITERATOR_SYMBOL = '@@iterator'; // Before Symbol spec.\n\n /**\n * Returns the iterator method function contained on the iterable object.\n *\n * Be sure to invoke the function with the iterable as context:\n *\n * var iteratorFn = getIteratorFn(myIterable);\n * if (iteratorFn) {\n * var iterator = iteratorFn.call(myIterable);\n * ...\n * }\n *\n * @param {?object} maybeIterable\n * @return {?function}\n */\n function getIteratorFn(maybeIterable) {\n var iteratorFn = maybeIterable && (ITERATOR_SYMBOL && maybeIterable[ITERATOR_SYMBOL] || maybeIterable[FAUX_ITERATOR_SYMBOL]);\n if (typeof iteratorFn === 'function') {\n return iteratorFn;\n }\n }\n\n /**\n * Collection of methods that allow declaration and validation of props that are\n * supplied to React components. Example usage:\n *\n * var Props = require('ReactPropTypes');\n * var MyArticle = React.createClass({\n * propTypes: {\n * // An optional string prop named \"description\".\n * description: Props.string,\n *\n * // A required enum prop named \"category\".\n * category: Props.oneOf(['News','Photos']).isRequired,\n *\n * // A prop named \"dialog\" that requires an instance of Dialog.\n * dialog: Props.instanceOf(Dialog).isRequired\n * },\n * render: function() { ... }\n * });\n *\n * A more formal specification of how these methods are used:\n *\n * type := array|bool|func|object|number|string|oneOf([...])|instanceOf(...)\n * decl := ReactPropTypes.{type}(.isRequired)?\n *\n * Each and every declaration produces a function with the same signature. This\n * allows the creation of custom validation functions. For example:\n *\n * var MyLink = React.createClass({\n * propTypes: {\n * // An optional string or URI prop named \"href\".\n * href: function(props, propName, componentName) {\n * var propValue = props[propName];\n * if (propValue != null && typeof propValue !== 'string' &&\n * !(propValue instanceof URI)) {\n * return new Error(\n * 'Expected a string or an URI for ' + propName + ' in ' +\n * componentName\n * );\n * }\n * }\n * },\n * render: function() {...}\n * });\n *\n * @internal\n */\n\n var ANONYMOUS = '<>';\n\n // Important!\n // Keep this list in sync with production version in `./factoryWithThrowingShims.js`.\n var ReactPropTypes = {\n array: createPrimitiveTypeChecker('array'),\n bigint: createPrimitiveTypeChecker('bigint'),\n bool: createPrimitiveTypeChecker('boolean'),\n func: createPrimitiveTypeChecker('function'),\n number: createPrimitiveTypeChecker('number'),\n object: createPrimitiveTypeChecker('object'),\n string: createPrimitiveTypeChecker('string'),\n symbol: createPrimitiveTypeChecker('symbol'),\n\n any: createAnyTypeChecker(),\n arrayOf: createArrayOfTypeChecker,\n element: createElementTypeChecker(),\n elementType: createElementTypeTypeChecker(),\n instanceOf: createInstanceTypeChecker,\n node: createNodeChecker(),\n objectOf: createObjectOfTypeChecker,\n oneOf: createEnumTypeChecker,\n oneOfType: createUnionTypeChecker,\n shape: createShapeTypeChecker,\n exact: createStrictShapeTypeChecker,\n };\n\n /**\n * inlined Object.is polyfill to avoid requiring consumers ship their own\n * https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object/is\n */\n /*eslint-disable no-self-compare*/\n function is(x, y) {\n // SameValue algorithm\n if (x === y) {\n // Steps 1-5, 7-10\n // Steps 6.b-6.e: +0 != -0\n return x !== 0 || 1 / x === 1 / y;\n } else {\n // Step 6.a: NaN == NaN\n return x !== x && y !== y;\n }\n }\n /*eslint-enable no-self-compare*/\n\n /**\n * We use an Error-like object for backward compatibility as people may call\n * PropTypes directly and inspect their output. However, we don't use real\n * Errors anymore. We don't inspect their stack anyway, and creating them\n * is prohibitively expensive if they are created too often, such as what\n * happens in oneOfType() for any type before the one that matched.\n */\n function PropTypeError(message, data) {\n this.message = message;\n this.data = data && typeof data === 'object' ? data: {};\n this.stack = '';\n }\n // Make `instanceof Error` still work for returned errors.\n PropTypeError.prototype = Error.prototype;\n\n function createChainableTypeChecker(validate) {\n if (process.env.NODE_ENV !== 'production') {\n var manualPropTypeCallCache = {};\n var manualPropTypeWarningCount = 0;\n }\n function checkType(isRequired, props, propName, componentName, location, propFullName, secret) {\n componentName = componentName || ANONYMOUS;\n propFullName = propFullName || propName;\n\n if (secret !== ReactPropTypesSecret) {\n if (throwOnDirectAccess) {\n // New behavior only for users of `prop-types` package\n var err = new Error(\n 'Calling PropTypes validators directly is not supported by the `prop-types` package. ' +\n 'Use `PropTypes.checkPropTypes()` to call them. ' +\n 'Read more at http://fb.me/use-check-prop-types'\n );\n err.name = 'Invariant Violation';\n throw err;\n } else if (process.env.NODE_ENV !== 'production' && typeof console !== 'undefined') {\n // Old behavior for people using React.PropTypes\n var cacheKey = componentName + ':' + propName;\n if (\n !manualPropTypeCallCache[cacheKey] &&\n // Avoid spamming the console because they are often not actionable except for lib authors\n manualPropTypeWarningCount < 3\n ) {\n printWarning(\n 'You are manually calling a React.PropTypes validation ' +\n 'function for the `' + propFullName + '` prop on `' + componentName + '`. This is deprecated ' +\n 'and will throw in the standalone `prop-types` package. ' +\n 'You may be seeing this warning due to a third-party PropTypes ' +\n 'library. See https://fb.me/react-warning-dont-call-proptypes ' + 'for details.'\n );\n manualPropTypeCallCache[cacheKey] = true;\n manualPropTypeWarningCount++;\n }\n }\n }\n if (props[propName] == null) {\n if (isRequired) {\n if (props[propName] === null) {\n return new PropTypeError('The ' + location + ' `' + propFullName + '` is marked as required ' + ('in `' + componentName + '`, but its value is `null`.'));\n }\n return new PropTypeError('The ' + location + ' `' + propFullName + '` is marked as required in ' + ('`' + componentName + '`, but its value is `undefined`.'));\n }\n return null;\n } else {\n return validate(props, propName, componentName, location, propFullName);\n }\n }\n\n var chainedCheckType = checkType.bind(null, false);\n chainedCheckType.isRequired = checkType.bind(null, true);\n\n return chainedCheckType;\n }\n\n function createPrimitiveTypeChecker(expectedType) {\n function validate(props, propName, componentName, location, propFullName, secret) {\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== expectedType) {\n // `propValue` being instance of, say, date/regexp, pass the 'object'\n // check, but we can offer a more precise error message here rather than\n // 'of type `object`'.\n var preciseType = getPreciseType(propValue);\n\n return new PropTypeError(\n 'Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + preciseType + '` supplied to `' + componentName + '`, expected ') + ('`' + expectedType + '`.'),\n {expectedType: expectedType}\n );\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createAnyTypeChecker() {\n return createChainableTypeChecker(emptyFunctionThatReturnsNull);\n }\n\n function createArrayOfTypeChecker(typeChecker) {\n function validate(props, propName, componentName, location, propFullName) {\n if (typeof typeChecker !== 'function') {\n return new PropTypeError('Property `' + propFullName + '` of component `' + componentName + '` has invalid PropType notation inside arrayOf.');\n }\n var propValue = props[propName];\n if (!Array.isArray(propValue)) {\n var propType = getPropType(propValue);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected an array.'));\n }\n for (var i = 0; i < propValue.length; i++) {\n var error = typeChecker(propValue, i, componentName, location, propFullName + '[' + i + ']', ReactPropTypesSecret);\n if (error instanceof Error) {\n return error;\n }\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createElementTypeChecker() {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n if (!isValidElement(propValue)) {\n var propType = getPropType(propValue);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected a single ReactElement.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createElementTypeTypeChecker() {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n if (!ReactIs.isValidElementType(propValue)) {\n var propType = getPropType(propValue);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected a single ReactElement type.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createInstanceTypeChecker(expectedClass) {\n function validate(props, propName, componentName, location, propFullName) {\n if (!(props[propName] instanceof expectedClass)) {\n var expectedClassName = expectedClass.name || ANONYMOUS;\n var actualClassName = getClassName(props[propName]);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + actualClassName + '` supplied to `' + componentName + '`, expected ') + ('instance of `' + expectedClassName + '`.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createEnumTypeChecker(expectedValues) {\n if (!Array.isArray(expectedValues)) {\n if (process.env.NODE_ENV !== 'production') {\n if (arguments.length > 1) {\n printWarning(\n 'Invalid arguments supplied to oneOf, expected an array, got ' + arguments.length + ' arguments. ' +\n 'A common mistake is to write oneOf(x, y, z) instead of oneOf([x, y, z]).'\n );\n } else {\n printWarning('Invalid argument supplied to oneOf, expected an array.');\n }\n }\n return emptyFunctionThatReturnsNull;\n }\n\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n for (var i = 0; i < expectedValues.length; i++) {\n if (is(propValue, expectedValues[i])) {\n return null;\n }\n }\n\n var valuesString = JSON.stringify(expectedValues, function replacer(key, value) {\n var type = getPreciseType(value);\n if (type === 'symbol') {\n return String(value);\n }\n return value;\n });\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of value `' + String(propValue) + '` ' + ('supplied to `' + componentName + '`, expected one of ' + valuesString + '.'));\n }\n return createChainableTypeChecker(validate);\n }\n\n function createObjectOfTypeChecker(typeChecker) {\n function validate(props, propName, componentName, location, propFullName) {\n if (typeof typeChecker !== 'function') {\n return new PropTypeError('Property `' + propFullName + '` of component `' + componentName + '` has invalid PropType notation inside objectOf.');\n }\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== 'object') {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected an object.'));\n }\n for (var key in propValue) {\n if (has(propValue, key)) {\n var error = typeChecker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret);\n if (error instanceof Error) {\n return error;\n }\n }\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createUnionTypeChecker(arrayOfTypeCheckers) {\n if (!Array.isArray(arrayOfTypeCheckers)) {\n process.env.NODE_ENV !== 'production' ? printWarning('Invalid argument supplied to oneOfType, expected an instance of array.') : void 0;\n return emptyFunctionThatReturnsNull;\n }\n\n for (var i = 0; i < arrayOfTypeCheckers.length; i++) {\n var checker = arrayOfTypeCheckers[i];\n if (typeof checker !== 'function') {\n printWarning(\n 'Invalid argument supplied to oneOfType. Expected an array of check functions, but ' +\n 'received ' + getPostfixForTypeWarning(checker) + ' at index ' + i + '.'\n );\n return emptyFunctionThatReturnsNull;\n }\n }\n\n function validate(props, propName, componentName, location, propFullName) {\n var expectedTypes = [];\n for (var i = 0; i < arrayOfTypeCheckers.length; i++) {\n var checker = arrayOfTypeCheckers[i];\n var checkerResult = checker(props, propName, componentName, location, propFullName, ReactPropTypesSecret);\n if (checkerResult == null) {\n return null;\n }\n if (checkerResult.data && has(checkerResult.data, 'expectedType')) {\n expectedTypes.push(checkerResult.data.expectedType);\n }\n }\n var expectedTypesMessage = (expectedTypes.length > 0) ? ', expected one of type [' + expectedTypes.join(', ') + ']': '';\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` supplied to ' + ('`' + componentName + '`' + expectedTypesMessage + '.'));\n }\n return createChainableTypeChecker(validate);\n }\n\n function createNodeChecker() {\n function validate(props, propName, componentName, location, propFullName) {\n if (!isNode(props[propName])) {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` supplied to ' + ('`' + componentName + '`, expected a ReactNode.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function invalidValidatorError(componentName, location, propFullName, key, type) {\n return new PropTypeError(\n (componentName || 'React class') + ': ' + location + ' type `' + propFullName + '.' + key + '` is invalid; ' +\n 'it must be a function, usually from the `prop-types` package, but received `' + type + '`.'\n );\n }\n\n function createShapeTypeChecker(shapeTypes) {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== 'object') {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type `' + propType + '` ' + ('supplied to `' + componentName + '`, expected `object`.'));\n }\n for (var key in shapeTypes) {\n var checker = shapeTypes[key];\n if (typeof checker !== 'function') {\n return invalidValidatorError(componentName, location, propFullName, key, getPreciseType(checker));\n }\n var error = checker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret);\n if (error) {\n return error;\n }\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createStrictShapeTypeChecker(shapeTypes) {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== 'object') {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type `' + propType + '` ' + ('supplied to `' + componentName + '`, expected `object`.'));\n }\n // We need to check all keys in case some are required but missing from props.\n var allKeys = assign({}, props[propName], shapeTypes);\n for (var key in allKeys) {\n var checker = shapeTypes[key];\n if (has(shapeTypes, key) && typeof checker !== 'function') {\n return invalidValidatorError(componentName, location, propFullName, key, getPreciseType(checker));\n }\n if (!checker) {\n return new PropTypeError(\n 'Invalid ' + location + ' `' + propFullName + '` key `' + key + '` supplied to `' + componentName + '`.' +\n '\\nBad object: ' + JSON.stringify(props[propName], null, ' ') +\n '\\nValid keys: ' + JSON.stringify(Object.keys(shapeTypes), null, ' ')\n );\n }\n var error = checker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret);\n if (error) {\n return error;\n }\n }\n return null;\n }\n\n return createChainableTypeChecker(validate);\n }\n\n function isNode(propValue) {\n switch (typeof propValue) {\n case 'number':\n case 'string':\n case 'undefined':\n return true;\n case 'boolean':\n return !propValue;\n case 'object':\n if (Array.isArray(propValue)) {\n return propValue.every(isNode);\n }\n if (propValue === null || isValidElement(propValue)) {\n return true;\n }\n\n var iteratorFn = getIteratorFn(propValue);\n if (iteratorFn) {\n var iterator = iteratorFn.call(propValue);\n var step;\n if (iteratorFn !== propValue.entries) {\n while (!(step = iterator.next()).done) {\n if (!isNode(step.value)) {\n return false;\n }\n }\n } else {\n // Iterator will provide entry [k,v] tuples rather than values.\n while (!(step = iterator.next()).done) {\n var entry = step.value;\n if (entry) {\n if (!isNode(entry[1])) {\n return false;\n }\n }\n }\n }\n } else {\n return false;\n }\n\n return true;\n default:\n return false;\n }\n }\n\n function isSymbol(propType, propValue) {\n // Native Symbol.\n if (propType === 'symbol') {\n return true;\n }\n\n // falsy value can't be a Symbol\n if (!propValue) {\n return false;\n }\n\n // 19.4.3.5 Symbol.prototype[@@toStringTag] === 'Symbol'\n if (propValue['@@toStringTag'] === 'Symbol') {\n return true;\n }\n\n // Fallback for non-spec compliant Symbols which are polyfilled.\n if (typeof Symbol === 'function' && propValue instanceof Symbol) {\n return true;\n }\n\n return false;\n }\n\n // Equivalent of `typeof` but with special handling for array and regexp.\n function getPropType(propValue) {\n var propType = typeof propValue;\n if (Array.isArray(propValue)) {\n return 'array';\n }\n if (propValue instanceof RegExp) {\n // Old webkits (at least until Android 4.0) return 'function' rather than\n // 'object' for typeof a RegExp. We'll normalize this here so that /bla/\n // passes PropTypes.object.\n return 'object';\n }\n if (isSymbol(propType, propValue)) {\n return 'symbol';\n }\n return propType;\n }\n\n // This handles more types than `getPropType`. Only used for error messages.\n // See `createPrimitiveTypeChecker`.\n function getPreciseType(propValue) {\n if (typeof propValue === 'undefined' || propValue === null) {\n return '' + propValue;\n }\n var propType = getPropType(propValue);\n if (propType === 'object') {\n if (propValue instanceof Date) {\n return 'date';\n } else if (propValue instanceof RegExp) {\n return 'regexp';\n }\n }\n return propType;\n }\n\n // Returns a string that is postfixed to a warning about an invalid type.\n // For example, \"undefined\" or \"of type array\"\n function getPostfixForTypeWarning(value) {\n var type = getPreciseType(value);\n switch (type) {\n case 'array':\n case 'object':\n return 'an ' + type;\n case 'boolean':\n case 'date':\n case 'regexp':\n return 'a ' + type;\n default:\n return type;\n }\n }\n\n // Returns class name of the object, if any.\n function getClassName(propValue) {\n if (!propValue.constructor || !propValue.constructor.name) {\n return ANONYMOUS;\n }\n return propValue.constructor.name;\n }\n\n ReactPropTypes.checkPropTypes = checkPropTypes;\n ReactPropTypes.resetWarningCache = checkPropTypes.resetWarningCache;\n ReactPropTypes.PropTypes = ReactPropTypes;\n\n return ReactPropTypes;\n};\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar ReactPropTypesSecret = require('./lib/ReactPropTypesSecret');\n\nfunction emptyFunction() {}\nfunction emptyFunctionWithReset() {}\nemptyFunctionWithReset.resetWarningCache = emptyFunction;\n\nmodule.exports = function() {\n function shim(props, propName, componentName, location, propFullName, secret) {\n if (secret === ReactPropTypesSecret) {\n // It is still safe when called from React.\n return;\n }\n var err = new Error(\n 'Calling PropTypes validators directly is not supported by the `prop-types` package. ' +\n 'Use PropTypes.checkPropTypes() to call them. ' +\n 'Read more at http://fb.me/use-check-prop-types'\n );\n err.name = 'Invariant Violation';\n throw err;\n };\n shim.isRequired = shim;\n function getShim() {\n return shim;\n };\n // Important!\n // Keep this list in sync with production version in `./factoryWithTypeCheckers.js`.\n var ReactPropTypes = {\n array: shim,\n bigint: shim,\n bool: shim,\n func: shim,\n number: shim,\n object: shim,\n string: shim,\n symbol: shim,\n\n any: shim,\n arrayOf: getShim,\n element: shim,\n elementType: shim,\n instanceOf: getShim,\n node: shim,\n objectOf: getShim,\n oneOf: getShim,\n oneOfType: getShim,\n shape: getShim,\n exact: getShim,\n\n checkPropTypes: emptyFunctionWithReset,\n resetWarningCache: emptyFunction\n };\n\n ReactPropTypes.PropTypes = ReactPropTypes;\n\n return ReactPropTypes;\n};\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\nif (process.env.NODE_ENV !== 'production') {\n var ReactIs = require('react-is');\n\n // By explicitly using `prop-types` you are opting into new development behavior.\n // http://fb.me/prop-types-in-prod\n var throwOnDirectAccess = true;\n module.exports = require('./factoryWithTypeCheckers')(ReactIs.isElement, throwOnDirectAccess);\n} else {\n // By explicitly using `prop-types` you are opting into new production behavior.\n // http://fb.me/prop-types-in-prod\n module.exports = require('./factoryWithThrowingShims')();\n}\n","import PropTypes from 'prop-types';\nimport chainPropTypes from '../chainPropTypes';\nfunction isClassComponent(elementType) {\n // elementType.prototype?.isReactComponent\n const {\n prototype = {}\n } = elementType;\n return Boolean(prototype.isReactComponent);\n}\nfunction acceptingRef(props, propName, componentName, location, propFullName) {\n const element = props[propName];\n const safePropName = propFullName || propName;\n if (element == null ||\n // When server-side rendering React doesn't warn either.\n // This is not an accurate check for SSR.\n // This is only in place for Emotion compat.\n // TODO: Revisit once https://github.com/facebook/react/issues/20047 is resolved.\n typeof window === 'undefined') {\n return null;\n }\n let warningHint;\n const elementType = element.type;\n /**\n * Blacklisting instead of whitelisting\n *\n * Blacklisting will miss some components, such as React.Fragment. Those will at least\n * trigger a warning in React.\n * We can't whitelist because there is no safe way to detect React.forwardRef\n * or class components. \"Safe\" means there's no public API.\n *\n */\n if (typeof elementType === 'function' && !isClassComponent(elementType)) {\n warningHint = 'Did you accidentally use a plain function component for an element instead?';\n }\n if (warningHint !== undefined) {\n return new Error(`Invalid ${location} \\`${safePropName}\\` supplied to \\`${componentName}\\`. ` + `Expected an element that can hold a ref. ${warningHint} ` + 'For more information see https://mui.com/r/caveat-with-refs-guide');\n }\n return null;\n}\nconst elementAcceptingRef = chainPropTypes(PropTypes.element, acceptingRef);\nelementAcceptingRef.isRequired = chainPropTypes(PropTypes.element.isRequired, acceptingRef);\nexport default elementAcceptingRef;","import _extends from \"@babel/runtime/helpers/esm/extends\";\n// This module is based on https://github.com/airbnb/prop-types-exact repository.\n// However, in order to reduce the number of dependencies and to remove some extra safe checks\n// the module was forked.\n\nconst specialProperty = 'exact-prop: \\u200b';\nexport default function exactProp(propTypes) {\n if (process.env.NODE_ENV === 'production') {\n return propTypes;\n }\n return _extends({}, propTypes, {\n [specialProperty]: props => {\n const unsupportedProps = Object.keys(props).filter(prop => !propTypes.hasOwnProperty(prop));\n if (unsupportedProps.length > 0) {\n return new Error(`The following props are not supported: ${unsupportedProps.map(prop => `\\`${prop}\\``).join(', ')}. Please remove them.`);\n }\n return null;\n }\n });\n}","/**\n * WARNING: Don't import this directly.\n * Use `MuiError` from `@mui/internal-babel-macros/MuiError.macro` instead.\n * @param {number} code\n */\nexport default function formatMuiErrorMessage(code) {\n // Apply babel-plugin-transform-template-literals in loose mode\n // loose mode is safe if we're concatenating primitives\n // see https://babeljs.io/docs/en/babel-plugin-transform-template-literals#loose\n /* eslint-disable prefer-template */\n let url = 'https://mui.com/production-error/?code=' + code;\n for (let i = 1; i < arguments.length; i += 1) {\n // rest params over-transpile for this case\n // eslint-disable-next-line prefer-rest-params\n url += '&args[]=' + encodeURIComponent(arguments[i]);\n }\n return 'Minified MUI error #' + code + '; visit ' + url + ' for the full message.';\n /* eslint-enable prefer-template */\n}","/**\n * @license React\n * react-is.production.min.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n'use strict';var b=Symbol.for(\"react.element\"),c=Symbol.for(\"react.portal\"),d=Symbol.for(\"react.fragment\"),e=Symbol.for(\"react.strict_mode\"),f=Symbol.for(\"react.profiler\"),g=Symbol.for(\"react.provider\"),h=Symbol.for(\"react.context\"),k=Symbol.for(\"react.server_context\"),l=Symbol.for(\"react.forward_ref\"),m=Symbol.for(\"react.suspense\"),n=Symbol.for(\"react.suspense_list\"),p=Symbol.for(\"react.memo\"),q=Symbol.for(\"react.lazy\"),t=Symbol.for(\"react.offscreen\"),u;u=Symbol.for(\"react.module.reference\");\nfunction v(a){if(\"object\"===typeof a&&null!==a){var r=a.$$typeof;switch(r){case b:switch(a=a.type,a){case d:case f:case e:case m:case n:return a;default:switch(a=a&&a.$$typeof,a){case k:case h:case l:case q:case p:case g:return a;default:return r}}case c:return r}}}exports.ContextConsumer=h;exports.ContextProvider=g;exports.Element=b;exports.ForwardRef=l;exports.Fragment=d;exports.Lazy=q;exports.Memo=p;exports.Portal=c;exports.Profiler=f;exports.StrictMode=e;exports.Suspense=m;\nexports.SuspenseList=n;exports.isAsyncMode=function(){return!1};exports.isConcurrentMode=function(){return!1};exports.isContextConsumer=function(a){return v(a)===h};exports.isContextProvider=function(a){return v(a)===g};exports.isElement=function(a){return\"object\"===typeof a&&null!==a&&a.$$typeof===b};exports.isForwardRef=function(a){return v(a)===l};exports.isFragment=function(a){return v(a)===d};exports.isLazy=function(a){return v(a)===q};exports.isMemo=function(a){return v(a)===p};\nexports.isPortal=function(a){return v(a)===c};exports.isProfiler=function(a){return v(a)===f};exports.isStrictMode=function(a){return v(a)===e};exports.isSuspense=function(a){return v(a)===m};exports.isSuspenseList=function(a){return v(a)===n};\nexports.isValidElementType=function(a){return\"string\"===typeof a||\"function\"===typeof a||a===d||a===f||a===e||a===m||a===n||a===t||\"object\"===typeof a&&null!==a&&(a.$$typeof===q||a.$$typeof===p||a.$$typeof===g||a.$$typeof===h||a.$$typeof===l||a.$$typeof===u||void 0!==a.getModuleId)?!0:!1};exports.typeOf=v;\n","/**\n * @license React\n * react-is.development.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nif (process.env.NODE_ENV !== \"production\") {\n (function() {\n'use strict';\n\n// ATTENTION\n// When adding new symbols to this file,\n// Please consider also adding to 'react-devtools-shared/src/backend/ReactSymbols'\n// The Symbol used to tag the ReactElement-like types.\nvar REACT_ELEMENT_TYPE = Symbol.for('react.element');\nvar REACT_PORTAL_TYPE = Symbol.for('react.portal');\nvar REACT_FRAGMENT_TYPE = Symbol.for('react.fragment');\nvar REACT_STRICT_MODE_TYPE = Symbol.for('react.strict_mode');\nvar REACT_PROFILER_TYPE = Symbol.for('react.profiler');\nvar REACT_PROVIDER_TYPE = Symbol.for('react.provider');\nvar REACT_CONTEXT_TYPE = Symbol.for('react.context');\nvar REACT_SERVER_CONTEXT_TYPE = Symbol.for('react.server_context');\nvar REACT_FORWARD_REF_TYPE = Symbol.for('react.forward_ref');\nvar REACT_SUSPENSE_TYPE = Symbol.for('react.suspense');\nvar REACT_SUSPENSE_LIST_TYPE = Symbol.for('react.suspense_list');\nvar REACT_MEMO_TYPE = Symbol.for('react.memo');\nvar REACT_LAZY_TYPE = Symbol.for('react.lazy');\nvar REACT_OFFSCREEN_TYPE = Symbol.for('react.offscreen');\n\n// -----------------------------------------------------------------------------\n\nvar enableScopeAPI = false; // Experimental Create Event Handle API.\nvar enableCacheElement = false;\nvar enableTransitionTracing = false; // No known bugs, but needs performance testing\n\nvar enableLegacyHidden = false; // Enables unstable_avoidThisFallback feature in Fiber\n// stuff. Intended to enable React core members to more easily debug scheduling\n// issues in DEV builds.\n\nvar enableDebugTracing = false; // Track which Fiber(s) schedule render work.\n\nvar REACT_MODULE_REFERENCE;\n\n{\n REACT_MODULE_REFERENCE = Symbol.for('react.module.reference');\n}\n\nfunction isValidElementType(type) {\n if (typeof type === 'string' || typeof type === 'function') {\n return true;\n } // Note: typeof might be other than 'symbol' or 'number' (e.g. if it's a polyfill).\n\n\n if (type === REACT_FRAGMENT_TYPE || type === REACT_PROFILER_TYPE || enableDebugTracing || type === REACT_STRICT_MODE_TYPE || type === REACT_SUSPENSE_TYPE || type === REACT_SUSPENSE_LIST_TYPE || enableLegacyHidden || type === REACT_OFFSCREEN_TYPE || enableScopeAPI || enableCacheElement || enableTransitionTracing ) {\n return true;\n }\n\n if (typeof type === 'object' && type !== null) {\n if (type.$$typeof === REACT_LAZY_TYPE || type.$$typeof === REACT_MEMO_TYPE || type.$$typeof === REACT_PROVIDER_TYPE || type.$$typeof === REACT_CONTEXT_TYPE || type.$$typeof === REACT_FORWARD_REF_TYPE || // This needs to include all possible module reference object\n // types supported by any Flight configuration anywhere since\n // we don't know which Flight build this will end up being used\n // with.\n type.$$typeof === REACT_MODULE_REFERENCE || type.getModuleId !== undefined) {\n return true;\n }\n }\n\n return false;\n}\n\nfunction typeOf(object) {\n if (typeof object === 'object' && object !== null) {\n var $$typeof = object.$$typeof;\n\n switch ($$typeof) {\n case REACT_ELEMENT_TYPE:\n var type = object.type;\n\n switch (type) {\n case REACT_FRAGMENT_TYPE:\n case REACT_PROFILER_TYPE:\n case REACT_STRICT_MODE_TYPE:\n case REACT_SUSPENSE_TYPE:\n case REACT_SUSPENSE_LIST_TYPE:\n return type;\n\n default:\n var $$typeofType = type && type.$$typeof;\n\n switch ($$typeofType) {\n case REACT_SERVER_CONTEXT_TYPE:\n case REACT_CONTEXT_TYPE:\n case REACT_FORWARD_REF_TYPE:\n case REACT_LAZY_TYPE:\n case REACT_MEMO_TYPE:\n case REACT_PROVIDER_TYPE:\n return $$typeofType;\n\n default:\n return $$typeof;\n }\n\n }\n\n case REACT_PORTAL_TYPE:\n return $$typeof;\n }\n }\n\n return undefined;\n}\nvar ContextConsumer = REACT_CONTEXT_TYPE;\nvar ContextProvider = REACT_PROVIDER_TYPE;\nvar Element = REACT_ELEMENT_TYPE;\nvar ForwardRef = REACT_FORWARD_REF_TYPE;\nvar Fragment = REACT_FRAGMENT_TYPE;\nvar Lazy = REACT_LAZY_TYPE;\nvar Memo = REACT_MEMO_TYPE;\nvar Portal = REACT_PORTAL_TYPE;\nvar Profiler = REACT_PROFILER_TYPE;\nvar StrictMode = REACT_STRICT_MODE_TYPE;\nvar Suspense = REACT_SUSPENSE_TYPE;\nvar SuspenseList = REACT_SUSPENSE_LIST_TYPE;\nvar hasWarnedAboutDeprecatedIsAsyncMode = false;\nvar hasWarnedAboutDeprecatedIsConcurrentMode = false; // AsyncMode should be deprecated\n\nfunction isAsyncMode(object) {\n {\n if (!hasWarnedAboutDeprecatedIsAsyncMode) {\n hasWarnedAboutDeprecatedIsAsyncMode = true; // Using console['warn'] to evade Babel and ESLint\n\n console['warn']('The ReactIs.isAsyncMode() alias has been deprecated, ' + 'and will be removed in React 18+.');\n }\n }\n\n return false;\n}\nfunction isConcurrentMode(object) {\n {\n if (!hasWarnedAboutDeprecatedIsConcurrentMode) {\n hasWarnedAboutDeprecatedIsConcurrentMode = true; // Using console['warn'] to evade Babel and ESLint\n\n console['warn']('The ReactIs.isConcurrentMode() alias has been deprecated, ' + 'and will be removed in React 18+.');\n }\n }\n\n return false;\n}\nfunction isContextConsumer(object) {\n return typeOf(object) === REACT_CONTEXT_TYPE;\n}\nfunction isContextProvider(object) {\n return typeOf(object) === REACT_PROVIDER_TYPE;\n}\nfunction isElement(object) {\n return typeof object === 'object' && object !== null && object.$$typeof === REACT_ELEMENT_TYPE;\n}\nfunction isForwardRef(object) {\n return typeOf(object) === REACT_FORWARD_REF_TYPE;\n}\nfunction isFragment(object) {\n return typeOf(object) === REACT_FRAGMENT_TYPE;\n}\nfunction isLazy(object) {\n return typeOf(object) === REACT_LAZY_TYPE;\n}\nfunction isMemo(object) {\n return typeOf(object) === REACT_MEMO_TYPE;\n}\nfunction isPortal(object) {\n return typeOf(object) === REACT_PORTAL_TYPE;\n}\nfunction isProfiler(object) {\n return typeOf(object) === REACT_PROFILER_TYPE;\n}\nfunction isStrictMode(object) {\n return typeOf(object) === REACT_STRICT_MODE_TYPE;\n}\nfunction isSuspense(object) {\n return typeOf(object) === REACT_SUSPENSE_TYPE;\n}\nfunction isSuspenseList(object) {\n return typeOf(object) === REACT_SUSPENSE_LIST_TYPE;\n}\n\nexports.ContextConsumer = ContextConsumer;\nexports.ContextProvider = ContextProvider;\nexports.Element = Element;\nexports.ForwardRef = ForwardRef;\nexports.Fragment = Fragment;\nexports.Lazy = Lazy;\nexports.Memo = Memo;\nexports.Portal = Portal;\nexports.Profiler = Profiler;\nexports.StrictMode = StrictMode;\nexports.Suspense = Suspense;\nexports.SuspenseList = SuspenseList;\nexports.isAsyncMode = isAsyncMode;\nexports.isConcurrentMode = isConcurrentMode;\nexports.isContextConsumer = isContextConsumer;\nexports.isContextProvider = isContextProvider;\nexports.isElement = isElement;\nexports.isForwardRef = isForwardRef;\nexports.isFragment = isFragment;\nexports.isLazy = isLazy;\nexports.isMemo = isMemo;\nexports.isPortal = isPortal;\nexports.isProfiler = isProfiler;\nexports.isStrictMode = isStrictMode;\nexports.isSuspense = isSuspense;\nexports.isSuspenseList = isSuspenseList;\nexports.isValidElementType = isValidElementType;\nexports.typeOf = typeOf;\n })();\n}\n","'use strict';\n\nif (process.env.NODE_ENV === 'production') {\n module.exports = require('./cjs/react-is.production.min.js');\n} else {\n module.exports = require('./cjs/react-is.development.js');\n}\n","import { ForwardRef, Memo } from 'react-is';\n\n// Simplified polyfill for IE11 support\n// https://github.com/JamesMGreene/Function.name/blob/58b314d4a983110c3682f1228f845d39ccca1817/Function.name.js#L3\nconst fnNameMatchRegex = /^\\s*function(?:\\s|\\s*\\/\\*.*\\*\\/\\s*)+([^(\\s/]*)\\s*/;\nexport function getFunctionName(fn) {\n const match = `${fn}`.match(fnNameMatchRegex);\n const name = match && match[1];\n return name || '';\n}\nfunction getFunctionComponentName(Component, fallback = '') {\n return Component.displayName || Component.name || getFunctionName(Component) || fallback;\n}\nfunction getWrappedName(outerType, innerType, wrapperName) {\n const functionName = getFunctionComponentName(innerType);\n return outerType.displayName || (functionName !== '' ? `${wrapperName}(${functionName})` : wrapperName);\n}\n\n/**\n * cherry-pick from\n * https://github.com/facebook/react/blob/769b1f270e1251d9dbdce0fcbd9e92e502d059b8/packages/shared/getComponentName.js\n * originally forked from recompose/getDisplayName with added IE11 support\n */\nexport default function getDisplayName(Component) {\n if (Component == null) {\n return undefined;\n }\n if (typeof Component === 'string') {\n return Component;\n }\n if (typeof Component === 'function') {\n return getFunctionComponentName(Component, 'Component');\n }\n\n // TypeScript can't have components as objects but they exist in the form of `memo` or `Suspense`\n if (typeof Component === 'object') {\n switch (Component.$$typeof) {\n case ForwardRef:\n return getWrappedName(Component, Component.render, 'ForwardRef');\n case Memo:\n return getWrappedName(Component, Component.type, 'memo');\n default:\n return undefined;\n }\n }\n return undefined;\n}","export default function HTMLElementType(props, propName, componentName, location, propFullName) {\n if (process.env.NODE_ENV === 'production') {\n return null;\n }\n const propValue = props[propName];\n const safePropName = propFullName || propName;\n if (propValue == null) {\n return null;\n }\n if (propValue && propValue.nodeType !== 1) {\n return new Error(`Invalid ${location} \\`${safePropName}\\` supplied to \\`${componentName}\\`. ` + `Expected an HTMLElement.`);\n }\n return null;\n}","import PropTypes from 'prop-types';\nconst refType = PropTypes.oneOfType([PropTypes.func, PropTypes.object]);\nexport default refType;","import _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\n// It should to be noted that this function isn't equivalent to `text-transform: capitalize`.\n//\n// A strict capitalization should uppercase the first letter of each word in the sentence.\n// We only handle the first word.\nexport default function capitalize(string) {\n if (typeof string !== 'string') {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: \\`capitalize(string)\\` expects a string argument.` : _formatMuiErrorMessage(7));\n }\n return string.charAt(0).toUpperCase() + string.slice(1);\n}","/**\n * Safe chained function.\n *\n * Will only create a new function if needed,\n * otherwise will pass back existing functions or null.\n */\nexport default function createChainedFunction(...funcs) {\n return funcs.reduce((acc, func) => {\n if (func == null) {\n return acc;\n }\n return function chainedFunction(...args) {\n acc.apply(this, args);\n func.apply(this, args);\n };\n }, () => {});\n}","// Corresponds to 10 frames at 60 Hz.\n// A few bytes payload overhead when lodash/debounce is ~3 kB and debounce ~300 B.\nexport default function debounce(func, wait = 166) {\n let timeout;\n function debounced(...args) {\n const later = () => {\n // @ts-ignore\n func.apply(this, args);\n };\n clearTimeout(timeout);\n timeout = setTimeout(later, wait);\n }\n debounced.clear = () => {\n clearTimeout(timeout);\n };\n return debounced;\n}","export default function deprecatedPropType(validator, reason) {\n if (process.env.NODE_ENV === 'production') {\n return () => null;\n }\n return (props, propName, componentName, location, propFullName) => {\n const componentNameSafe = componentName || '<>';\n const propFullNameSafe = propFullName || propName;\n if (typeof props[propName] !== 'undefined') {\n return new Error(`The ${location} \\`${propFullNameSafe}\\` of ` + `\\`${componentNameSafe}\\` is deprecated. ${reason}`);\n }\n return null;\n };\n}","import * as React from 'react';\nexport default function isMuiElement(element, muiNames) {\n var _muiName, _element$type;\n return /*#__PURE__*/React.isValidElement(element) && muiNames.indexOf( // For server components `muiName` is avaialble in element.type._payload.value.muiName\n // relevant info - https://github.com/facebook/react/blob/2807d781a08db8e9873687fccc25c0f12b4fb3d4/packages/react/src/ReactLazy.js#L45\n // eslint-disable-next-line no-underscore-dangle\n (_muiName = element.type.muiName) != null ? _muiName : (_element$type = element.type) == null || (_element$type = _element$type._payload) == null || (_element$type = _element$type.value) == null ? void 0 : _element$type.muiName) !== -1;\n}","export default function ownerDocument(node) {\n return node && node.ownerDocument || document;\n}","import ownerDocument from '../ownerDocument';\nexport default function ownerWindow(node) {\n const doc = ownerDocument(node);\n return doc.defaultView || window;\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nexport default function requirePropFactory(componentNameInError, Component) {\n if (process.env.NODE_ENV === 'production') {\n return () => null;\n }\n\n // eslint-disable-next-line react/forbid-foreign-prop-types\n const prevPropTypes = Component ? _extends({}, Component.propTypes) : null;\n const requireProp = requiredProp => (props, propName, componentName, location, propFullName, ...args) => {\n const propFullNameSafe = propFullName || propName;\n const defaultTypeChecker = prevPropTypes == null ? void 0 : prevPropTypes[propFullNameSafe];\n if (defaultTypeChecker) {\n const typeCheckerResult = defaultTypeChecker(props, propName, componentName, location, propFullName, ...args);\n if (typeCheckerResult) {\n return typeCheckerResult;\n }\n }\n if (typeof props[propName] !== 'undefined' && !props[requiredProp]) {\n return new Error(`The prop \\`${propFullNameSafe}\\` of ` + `\\`${componentNameInError}\\` can only be used together with the \\`${requiredProp}\\` prop.`);\n }\n return null;\n };\n return requireProp;\n}","/**\n * TODO v5: consider making it private\n *\n * passes {value} to {ref}\n *\n * WARNING: Be sure to only call this inside a callback that is passed as a ref.\n * Otherwise, make sure to cleanup the previous {ref} if it changes. See\n * https://github.com/mui/material-ui/issues/13539\n *\n * Useful if you want to expose the ref of an inner component to the public API\n * while still using it inside the component.\n * @param ref A ref callback or ref object. If anything falsy, this is a no-op.\n */\nexport default function setRef(ref, value) {\n if (typeof ref === 'function') {\n ref(value);\n } else if (ref) {\n ref.current = value;\n }\n}","'use client';\n\nimport * as React from 'react';\n\n/**\n * A version of `React.useLayoutEffect` that does not show a warning when server-side rendering.\n * This is useful for effects that are only needed for client-side rendering but not for SSR.\n *\n * Before you use this hook, make sure to read https://gist.github.com/gaearon/e7d97cdf38a2907924ea12e4ebdf3c85\n * and confirm it doesn't apply to your use-case.\n */\nconst useEnhancedEffect = typeof window !== 'undefined' ? React.useLayoutEffect : React.useEffect;\nexport default useEnhancedEffect;","'use client';\n\nimport * as React from 'react';\nlet globalId = 0;\nfunction useGlobalId(idOverride) {\n const [defaultId, setDefaultId] = React.useState(idOverride);\n const id = idOverride || defaultId;\n React.useEffect(() => {\n if (defaultId == null) {\n // Fallback to this default id when possible.\n // Use the incrementing value for client-side rendering only.\n // We can't use it server-side.\n // If you want to use random values please consider the Birthday Problem: https://en.wikipedia.org/wiki/Birthday_problem\n globalId += 1;\n setDefaultId(`mui-${globalId}`);\n }\n }, [defaultId]);\n return id;\n}\n\n// downstream bundlers may remove unnecessary concatenation, but won't remove toString call -- Workaround for https://github.com/webpack/webpack/issues/14814\nconst maybeReactUseId = React['useId'.toString()];\n/**\n *\n * @example
    \n * @param idOverride\n * @returns {string}\n */\nexport default function useId(idOverride) {\n if (maybeReactUseId !== undefined) {\n const reactId = maybeReactUseId();\n return idOverride != null ? idOverride : reactId;\n }\n // eslint-disable-next-line react-hooks/rules-of-hooks -- `React.useId` is invariant at runtime.\n return useGlobalId(idOverride);\n}","export default function unsupportedProp(props, propName, componentName, location, propFullName) {\n if (process.env.NODE_ENV === 'production') {\n return null;\n }\n const propFullNameSafe = propFullName || propName;\n if (typeof props[propName] !== 'undefined') {\n return new Error(`The prop \\`${propFullNameSafe}\\` is not supported. Please remove it.`);\n }\n return null;\n}","'use client';\n\n/* eslint-disable react-hooks/rules-of-hooks, react-hooks/exhaustive-deps */\nimport * as React from 'react';\nexport default function useControlled({\n controlled,\n default: defaultProp,\n name,\n state = 'value'\n}) {\n // isControlled is ignored in the hook dependency lists as it should never change.\n const {\n current: isControlled\n } = React.useRef(controlled !== undefined);\n const [valueState, setValue] = React.useState(defaultProp);\n const value = isControlled ? controlled : valueState;\n if (process.env.NODE_ENV !== 'production') {\n React.useEffect(() => {\n if (isControlled !== (controlled !== undefined)) {\n console.error([`MUI: A component is changing the ${isControlled ? '' : 'un'}controlled ${state} state of ${name} to be ${isControlled ? 'un' : ''}controlled.`, 'Elements should not switch from uncontrolled to controlled (or vice versa).', `Decide between using a controlled or uncontrolled ${name} ` + 'element for the lifetime of the component.', \"The nature of the state is determined during the first render. It's considered controlled if the value is not `undefined`.\", 'More info: https://fb.me/react-controlled-components'].join('\\n'));\n }\n }, [state, name, controlled]);\n const {\n current: defaultValue\n } = React.useRef(defaultProp);\n React.useEffect(() => {\n if (!isControlled && defaultValue !== defaultProp) {\n console.error([`MUI: A component is changing the default ${state} state of an uncontrolled ${name} after being initialized. ` + `To suppress this warning opt to use a controlled ${name}.`].join('\\n'));\n }\n }, [JSON.stringify(defaultProp)]);\n }\n const setValueIfUncontrolled = React.useCallback(newValue => {\n if (!isControlled) {\n setValue(newValue);\n }\n }, []);\n return [value, setValueIfUncontrolled];\n}","'use client';\n\nimport * as React from 'react';\nimport useEnhancedEffect from '../useEnhancedEffect';\n\n/**\n * Inspired by https://github.com/facebook/react/issues/14099#issuecomment-440013892\n * See RFC in https://github.com/reactjs/rfcs/pull/220\n */\n\nfunction useEventCallback(fn) {\n const ref = React.useRef(fn);\n useEnhancedEffect(() => {\n ref.current = fn;\n });\n return React.useRef((...args) =>\n // @ts-expect-error hide `this`\n (0, ref.current)(...args)).current;\n}\nexport default useEventCallback;","'use client';\n\nimport * as React from 'react';\nimport setRef from '../setRef';\nexport default function useForkRef(...refs) {\n /**\n * This will create a new function if the refs passed to this hook change and are all defined.\n * This means react will call the old forkRef with `null` and the new forkRef\n * with the ref. Cleanup naturally emerges from this behavior.\n */\n return React.useMemo(() => {\n if (refs.every(ref => ref == null)) {\n return null;\n }\n return instance => {\n refs.forEach(ref => {\n setRef(ref, instance);\n });\n };\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, refs);\n}","'use client';\n\nimport * as React from 'react';\nconst UNINITIALIZED = {};\n\n/**\n * A React.useRef() that is initialized lazily with a function. Note that it accepts an optional\n * initialization argument, so the initialization function doesn't need to be an inline closure.\n *\n * @usage\n * const ref = useLazyRef(sortColumns, columns)\n */\nexport default function useLazyRef(init, initArg) {\n const ref = React.useRef(UNINITIALIZED);\n if (ref.current === UNINITIALIZED) {\n ref.current = init(initArg);\n }\n return ref;\n}","'use client';\n\nimport * as React from 'react';\nconst EMPTY = [];\n\n/**\n * A React.useEffect equivalent that runs once, when the component is mounted.\n */\nexport default function useOnMount(fn) {\n /* eslint-disable react-hooks/exhaustive-deps */\n React.useEffect(fn, EMPTY);\n /* eslint-enable react-hooks/exhaustive-deps */\n}","'use client';\n\nimport useLazyRef from '../useLazyRef/useLazyRef';\nimport useOnMount from '../useOnMount/useOnMount';\nexport class Timeout {\n constructor() {\n this.currentId = null;\n this.clear = () => {\n if (this.currentId !== null) {\n clearTimeout(this.currentId);\n this.currentId = null;\n }\n };\n this.disposeEffect = () => {\n return this.clear;\n };\n }\n static create() {\n return new Timeout();\n }\n /**\n * Executes `fn` after `delay`, clearing any previously scheduled call.\n */\n start(delay, fn) {\n this.clear();\n this.currentId = setTimeout(() => {\n this.currentId = null;\n fn();\n }, delay);\n }\n}\nexport default function useTimeout() {\n const timeout = useLazyRef(Timeout.create).current;\n useOnMount(timeout.disposeEffect);\n return timeout;\n}","'use client';\n\n// based on https://github.com/WICG/focus-visible/blob/v4.1.5/src/focus-visible.js\nimport * as React from 'react';\nimport { Timeout } from '../useTimeout/useTimeout';\nlet hadKeyboardEvent = true;\nlet hadFocusVisibleRecently = false;\nconst hadFocusVisibleRecentlyTimeout = new Timeout();\nconst inputTypesWhitelist = {\n text: true,\n search: true,\n url: true,\n tel: true,\n email: true,\n password: true,\n number: true,\n date: true,\n month: true,\n week: true,\n time: true,\n datetime: true,\n 'datetime-local': true\n};\n\n/**\n * Computes whether the given element should automatically trigger the\n * `focus-visible` class being added, i.e. whether it should always match\n * `:focus-visible` when focused.\n * @param {Element} node\n * @returns {boolean}\n */\nfunction focusTriggersKeyboardModality(node) {\n const {\n type,\n tagName\n } = node;\n if (tagName === 'INPUT' && inputTypesWhitelist[type] && !node.readOnly) {\n return true;\n }\n if (tagName === 'TEXTAREA' && !node.readOnly) {\n return true;\n }\n if (node.isContentEditable) {\n return true;\n }\n return false;\n}\n\n/**\n * Keep track of our keyboard modality state with `hadKeyboardEvent`.\n * If the most recent user interaction was via the keyboard;\n * and the key press did not include a meta, alt/option, or control key;\n * then the modality is keyboard. Otherwise, the modality is not keyboard.\n * @param {KeyboardEvent} event\n */\nfunction handleKeyDown(event) {\n if (event.metaKey || event.altKey || event.ctrlKey) {\n return;\n }\n hadKeyboardEvent = true;\n}\n\n/**\n * If at any point a user clicks with a pointing device, ensure that we change\n * the modality away from keyboard.\n * This avoids the situation where a user presses a key on an already focused\n * element, and then clicks on a different element, focusing it with a\n * pointing device, while we still think we're in keyboard modality.\n */\nfunction handlePointerDown() {\n hadKeyboardEvent = false;\n}\nfunction handleVisibilityChange() {\n if (this.visibilityState === 'hidden') {\n // If the tab becomes active again, the browser will handle calling focus\n // on the element (Safari actually calls it twice).\n // If this tab change caused a blur on an element with focus-visible,\n // re-apply the class when the user switches back to the tab.\n if (hadFocusVisibleRecently) {\n hadKeyboardEvent = true;\n }\n }\n}\nfunction prepare(doc) {\n doc.addEventListener('keydown', handleKeyDown, true);\n doc.addEventListener('mousedown', handlePointerDown, true);\n doc.addEventListener('pointerdown', handlePointerDown, true);\n doc.addEventListener('touchstart', handlePointerDown, true);\n doc.addEventListener('visibilitychange', handleVisibilityChange, true);\n}\nexport function teardown(doc) {\n doc.removeEventListener('keydown', handleKeyDown, true);\n doc.removeEventListener('mousedown', handlePointerDown, true);\n doc.removeEventListener('pointerdown', handlePointerDown, true);\n doc.removeEventListener('touchstart', handlePointerDown, true);\n doc.removeEventListener('visibilitychange', handleVisibilityChange, true);\n}\nfunction isFocusVisible(event) {\n const {\n target\n } = event;\n try {\n return target.matches(':focus-visible');\n } catch (error) {\n // Browsers not implementing :focus-visible will throw a SyntaxError.\n // We use our own heuristic for those browsers.\n // Rethrow might be better if it's not the expected error but do we really\n // want to crash if focus-visible malfunctioned?\n }\n\n // No need for validFocusTarget check. The user does that by attaching it to\n // focusable events only.\n return hadKeyboardEvent || focusTriggersKeyboardModality(target);\n}\nexport default function useIsFocusVisible() {\n const ref = React.useCallback(node => {\n if (node != null) {\n prepare(node.ownerDocument);\n }\n }, []);\n const isFocusVisibleRef = React.useRef(false);\n\n /**\n * Should be called if a blur event is fired\n */\n function handleBlurVisible() {\n // checking against potential state variable does not suffice if we focus and blur synchronously.\n // React wouldn't have time to trigger a re-render so `focusVisible` would be stale.\n // Ideally we would adjust `isFocusVisible(event)` to look at `relatedTarget` for blur events.\n // This doesn't work in IE11 due to https://github.com/facebook/react/issues/3751\n // TODO: check again if React releases their internal changes to focus event handling (https://github.com/facebook/react/pull/19186).\n if (isFocusVisibleRef.current) {\n // To detect a tab/window switch, we look for a blur event followed\n // rapidly by a visibility change.\n // If we don't see a visibility change within 100ms, it's probably a\n // regular focus change.\n hadFocusVisibleRecently = true;\n hadFocusVisibleRecentlyTimeout.start(100, () => {\n hadFocusVisibleRecently = false;\n });\n isFocusVisibleRef.current = false;\n return true;\n }\n return false;\n }\n\n /**\n * Should be called if a blur event is fired\n */\n function handleFocusVisible(event) {\n if (isFocusVisible(event)) {\n isFocusVisibleRef.current = true;\n return true;\n }\n return false;\n }\n return {\n isFocusVisibleRef,\n onFocus: handleFocusVisible,\n onBlur: handleBlurVisible,\n ref\n };\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\n/**\n * Add keys, values of `defaultProps` that does not exist in `props`\n * @param {object} defaultProps\n * @param {object} props\n * @returns {object} resolved props\n */\nexport default function resolveProps(defaultProps, props) {\n const output = _extends({}, props);\n Object.keys(defaultProps).forEach(propName => {\n if (propName.toString().match(/^(components|slots)$/)) {\n output[propName] = _extends({}, defaultProps[propName], output[propName]);\n } else if (propName.toString().match(/^(componentsProps|slotProps)$/)) {\n const defaultSlotProps = defaultProps[propName] || {};\n const slotProps = props[propName];\n output[propName] = {};\n if (!slotProps || !Object.keys(slotProps)) {\n // Reduce the iteration if the slot props is empty\n output[propName] = defaultSlotProps;\n } else if (!defaultSlotProps || !Object.keys(defaultSlotProps)) {\n // Reduce the iteration if the default slot props is empty\n output[propName] = slotProps;\n } else {\n output[propName] = _extends({}, slotProps);\n Object.keys(defaultSlotProps).forEach(slotPropName => {\n output[propName][slotPropName] = resolveProps(defaultSlotProps[slotPropName], slotProps[slotPropName]);\n });\n }\n } else if (output[propName] === undefined) {\n output[propName] = defaultProps[propName];\n }\n });\n return output;\n}","export default function composeClasses(slots, getUtilityClass, classes = undefined) {\n const output = {};\n Object.keys(slots).forEach(\n // `Object.keys(slots)` can't be wider than `T` because we infer `T` from `slots`.\n // @ts-expect-error https://github.com/microsoft/TypeScript/pull/12253#issuecomment-263132208\n slot => {\n output[slot] = slots[slot].reduce((acc, key) => {\n if (key) {\n const utilityClass = getUtilityClass(key);\n if (utilityClass !== '') {\n acc.push(utilityClass);\n }\n if (classes && classes[key]) {\n acc.push(classes[key]);\n }\n }\n return acc;\n }, []).join(' ');\n });\n return output;\n}","const defaultGenerator = componentName => componentName;\nconst createClassNameGenerator = () => {\n let generate = defaultGenerator;\n return {\n configure(generator) {\n generate = generator;\n },\n generate(componentName) {\n return generate(componentName);\n },\n reset() {\n generate = defaultGenerator;\n }\n };\n};\nconst ClassNameGenerator = createClassNameGenerator();\nexport default ClassNameGenerator;","import ClassNameGenerator from '../ClassNameGenerator';\nexport const globalStateClasses = {\n active: 'active',\n checked: 'checked',\n completed: 'completed',\n disabled: 'disabled',\n error: 'error',\n expanded: 'expanded',\n focused: 'focused',\n focusVisible: 'focusVisible',\n open: 'open',\n readOnly: 'readOnly',\n required: 'required',\n selected: 'selected'\n};\nexport default function generateUtilityClass(componentName, slot, globalStatePrefix = 'Mui') {\n const globalStateClass = globalStateClasses[slot];\n return globalStateClass ? `${globalStatePrefix}-${globalStateClass}` : `${ClassNameGenerator.generate(componentName)}-${slot}`;\n}\nexport function isGlobalState(slot) {\n return globalStateClasses[slot] !== undefined;\n}","import generateUtilityClass from '../generateUtilityClass';\nexport default function generateUtilityClasses(componentName, slots, globalStatePrefix = 'Mui') {\n const result = {};\n slots.forEach(slot => {\n result[slot] = generateUtilityClass(componentName, slot, globalStatePrefix);\n });\n return result;\n}","function clamp(val, min = Number.MIN_SAFE_INTEGER, max = Number.MAX_SAFE_INTEGER) {\n return Math.max(min, Math.min(val, max));\n}\nexport default clamp;","export default function _objectWithoutPropertiesLoose(source, excluded) {\n if (source == null) return {};\n var target = {};\n var sourceKeys = Object.keys(source);\n var key, i;\n for (i = 0; i < sourceKeys.length; i++) {\n key = sourceKeys[i];\n if (excluded.indexOf(key) >= 0) continue;\n target[key] = source[key];\n }\n return target;\n}","import _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nconst _excluded = [\"values\", \"unit\", \"step\"];\n// Sorted ASC by size. That's important.\n// It can't be configured as it's used statically for propTypes.\nexport const breakpointKeys = ['xs', 'sm', 'md', 'lg', 'xl'];\nconst sortBreakpointsValues = values => {\n const breakpointsAsArray = Object.keys(values).map(key => ({\n key,\n val: values[key]\n })) || [];\n // Sort in ascending order\n breakpointsAsArray.sort((breakpoint1, breakpoint2) => breakpoint1.val - breakpoint2.val);\n return breakpointsAsArray.reduce((acc, obj) => {\n return _extends({}, acc, {\n [obj.key]: obj.val\n });\n }, {});\n};\n\n// Keep in mind that @media is inclusive by the CSS specification.\nexport default function createBreakpoints(breakpoints) {\n const {\n // The breakpoint **start** at this value.\n // For instance with the first breakpoint xs: [xs, sm).\n values = {\n xs: 0,\n // phone\n sm: 600,\n // tablet\n md: 900,\n // small laptop\n lg: 1200,\n // desktop\n xl: 1536 // large screen\n },\n unit = 'px',\n step = 5\n } = breakpoints,\n other = _objectWithoutPropertiesLoose(breakpoints, _excluded);\n const sortedValues = sortBreakpointsValues(values);\n const keys = Object.keys(sortedValues);\n function up(key) {\n const value = typeof values[key] === 'number' ? values[key] : key;\n return `@media (min-width:${value}${unit})`;\n }\n function down(key) {\n const value = typeof values[key] === 'number' ? values[key] : key;\n return `@media (max-width:${value - step / 100}${unit})`;\n }\n function between(start, end) {\n const endIndex = keys.indexOf(end);\n return `@media (min-width:${typeof values[start] === 'number' ? values[start] : start}${unit}) and ` + `(max-width:${(endIndex !== -1 && typeof values[keys[endIndex]] === 'number' ? values[keys[endIndex]] : end) - step / 100}${unit})`;\n }\n function only(key) {\n if (keys.indexOf(key) + 1 < keys.length) {\n return between(key, keys[keys.indexOf(key) + 1]);\n }\n return up(key);\n }\n function not(key) {\n // handle first and last key separately, for better readability\n const keyIndex = keys.indexOf(key);\n if (keyIndex === 0) {\n return up(keys[1]);\n }\n if (keyIndex === keys.length - 1) {\n return down(keys[keyIndex]);\n }\n return between(key, keys[keys.indexOf(key) + 1]).replace('@media', '@media not all and');\n }\n return _extends({\n keys,\n values: sortedValues,\n up,\n down,\n between,\n only,\n not,\n unit\n }, other);\n}","const shape = {\n borderRadius: 4\n};\nexport default shape;","import PropTypes from 'prop-types';\nconst responsivePropType = process.env.NODE_ENV !== 'production' ? PropTypes.oneOfType([PropTypes.number, PropTypes.string, PropTypes.object, PropTypes.array]) : {};\nexport default responsivePropType;","import deepmerge from '@mui/utils/deepmerge';\nfunction merge(acc, item) {\n if (!item) {\n return acc;\n }\n return deepmerge(acc, item, {\n clone: false // No need to clone deep, it's way faster.\n });\n}\nexport default merge;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport PropTypes from 'prop-types';\nimport deepmerge from '@mui/utils/deepmerge';\nimport merge from './merge';\n\n// The breakpoint **start** at this value.\n// For instance with the first breakpoint xs: [xs, sm[.\nexport const values = {\n xs: 0,\n // phone\n sm: 600,\n // tablet\n md: 900,\n // small laptop\n lg: 1200,\n // desktop\n xl: 1536 // large screen\n};\nconst defaultBreakpoints = {\n // Sorted ASC by size. That's important.\n // It can't be configured as it's used statically for propTypes.\n keys: ['xs', 'sm', 'md', 'lg', 'xl'],\n up: key => `@media (min-width:${values[key]}px)`\n};\nexport function handleBreakpoints(props, propValue, styleFromPropValue) {\n const theme = props.theme || {};\n if (Array.isArray(propValue)) {\n const themeBreakpoints = theme.breakpoints || defaultBreakpoints;\n return propValue.reduce((acc, item, index) => {\n acc[themeBreakpoints.up(themeBreakpoints.keys[index])] = styleFromPropValue(propValue[index]);\n return acc;\n }, {});\n }\n if (typeof propValue === 'object') {\n const themeBreakpoints = theme.breakpoints || defaultBreakpoints;\n return Object.keys(propValue).reduce((acc, breakpoint) => {\n // key is breakpoint\n if (Object.keys(themeBreakpoints.values || values).indexOf(breakpoint) !== -1) {\n const mediaKey = themeBreakpoints.up(breakpoint);\n acc[mediaKey] = styleFromPropValue(propValue[breakpoint], breakpoint);\n } else {\n const cssKey = breakpoint;\n acc[cssKey] = propValue[cssKey];\n }\n return acc;\n }, {});\n }\n const output = styleFromPropValue(propValue);\n return output;\n}\nfunction breakpoints(styleFunction) {\n // false positive\n // eslint-disable-next-line react/function-component-definition\n const newStyleFunction = props => {\n const theme = props.theme || {};\n const base = styleFunction(props);\n const themeBreakpoints = theme.breakpoints || defaultBreakpoints;\n const extended = themeBreakpoints.keys.reduce((acc, key) => {\n if (props[key]) {\n acc = acc || {};\n acc[themeBreakpoints.up(key)] = styleFunction(_extends({\n theme\n }, props[key]));\n }\n return acc;\n }, null);\n return merge(base, extended);\n };\n newStyleFunction.propTypes = process.env.NODE_ENV !== 'production' ? _extends({}, styleFunction.propTypes, {\n xs: PropTypes.object,\n sm: PropTypes.object,\n md: PropTypes.object,\n lg: PropTypes.object,\n xl: PropTypes.object\n }) : {};\n newStyleFunction.filterProps = ['xs', 'sm', 'md', 'lg', 'xl', ...styleFunction.filterProps];\n return newStyleFunction;\n}\nexport function createEmptyBreakpointObject(breakpointsInput = {}) {\n var _breakpointsInput$key;\n const breakpointsInOrder = (_breakpointsInput$key = breakpointsInput.keys) == null ? void 0 : _breakpointsInput$key.reduce((acc, key) => {\n const breakpointStyleKey = breakpointsInput.up(key);\n acc[breakpointStyleKey] = {};\n return acc;\n }, {});\n return breakpointsInOrder || {};\n}\nexport function removeUnusedBreakpoints(breakpointKeys, style) {\n return breakpointKeys.reduce((acc, key) => {\n const breakpointOutput = acc[key];\n const isBreakpointUnused = !breakpointOutput || Object.keys(breakpointOutput).length === 0;\n if (isBreakpointUnused) {\n delete acc[key];\n }\n return acc;\n }, style);\n}\nexport function mergeBreakpointsInOrder(breakpointsInput, ...styles) {\n const emptyBreakpoints = createEmptyBreakpointObject(breakpointsInput);\n const mergedOutput = [emptyBreakpoints, ...styles].reduce((prev, next) => deepmerge(prev, next), {});\n return removeUnusedBreakpoints(Object.keys(emptyBreakpoints), mergedOutput);\n}\n\n// compute base for responsive values; e.g.,\n// [1,2,3] => {xs: true, sm: true, md: true}\n// {xs: 1, sm: 2, md: 3} => {xs: true, sm: true, md: true}\nexport function computeBreakpointsBase(breakpointValues, themeBreakpoints) {\n // fixed value\n if (typeof breakpointValues !== 'object') {\n return {};\n }\n const base = {};\n const breakpointsKeys = Object.keys(themeBreakpoints);\n if (Array.isArray(breakpointValues)) {\n breakpointsKeys.forEach((breakpoint, i) => {\n if (i < breakpointValues.length) {\n base[breakpoint] = true;\n }\n });\n } else {\n breakpointsKeys.forEach(breakpoint => {\n if (breakpointValues[breakpoint] != null) {\n base[breakpoint] = true;\n }\n });\n }\n return base;\n}\nexport function resolveBreakpointValues({\n values: breakpointValues,\n breakpoints: themeBreakpoints,\n base: customBase\n}) {\n const base = customBase || computeBreakpointsBase(breakpointValues, themeBreakpoints);\n const keys = Object.keys(base);\n if (keys.length === 0) {\n return breakpointValues;\n }\n let previous;\n return keys.reduce((acc, breakpoint, i) => {\n if (Array.isArray(breakpointValues)) {\n acc[breakpoint] = breakpointValues[i] != null ? breakpointValues[i] : breakpointValues[previous];\n previous = i;\n } else if (typeof breakpointValues === 'object') {\n acc[breakpoint] = breakpointValues[breakpoint] != null ? breakpointValues[breakpoint] : breakpointValues[previous];\n previous = breakpoint;\n } else {\n acc[breakpoint] = breakpointValues;\n }\n return acc;\n }, {});\n}\nexport default breakpoints;","import capitalize from '@mui/utils/capitalize';\nimport responsivePropType from './responsivePropType';\nimport { handleBreakpoints } from './breakpoints';\nexport function getPath(obj, path, checkVars = true) {\n if (!path || typeof path !== 'string') {\n return null;\n }\n\n // Check if CSS variables are used\n if (obj && obj.vars && checkVars) {\n const val = `vars.${path}`.split('.').reduce((acc, item) => acc && acc[item] ? acc[item] : null, obj);\n if (val != null) {\n return val;\n }\n }\n return path.split('.').reduce((acc, item) => {\n if (acc && acc[item] != null) {\n return acc[item];\n }\n return null;\n }, obj);\n}\nexport function getStyleValue(themeMapping, transform, propValueFinal, userValue = propValueFinal) {\n let value;\n if (typeof themeMapping === 'function') {\n value = themeMapping(propValueFinal);\n } else if (Array.isArray(themeMapping)) {\n value = themeMapping[propValueFinal] || userValue;\n } else {\n value = getPath(themeMapping, propValueFinal) || userValue;\n }\n if (transform) {\n value = transform(value, userValue, themeMapping);\n }\n return value;\n}\nfunction style(options) {\n const {\n prop,\n cssProperty = options.prop,\n themeKey,\n transform\n } = options;\n\n // false positive\n // eslint-disable-next-line react/function-component-definition\n const fn = props => {\n if (props[prop] == null) {\n return null;\n }\n const propValue = props[prop];\n const theme = props.theme;\n const themeMapping = getPath(theme, themeKey) || {};\n const styleFromPropValue = propValueFinal => {\n let value = getStyleValue(themeMapping, transform, propValueFinal);\n if (propValueFinal === value && typeof propValueFinal === 'string') {\n // Haven't found value\n value = getStyleValue(themeMapping, transform, `${prop}${propValueFinal === 'default' ? '' : capitalize(propValueFinal)}`, propValueFinal);\n }\n if (cssProperty === false) {\n return value;\n }\n return {\n [cssProperty]: value\n };\n };\n return handleBreakpoints(props, propValue, styleFromPropValue);\n };\n fn.propTypes = process.env.NODE_ENV !== 'production' ? {\n [prop]: responsivePropType\n } : {};\n fn.filterProps = [prop];\n return fn;\n}\nexport default style;","export default function memoize(fn) {\n const cache = {};\n return arg => {\n if (cache[arg] === undefined) {\n cache[arg] = fn(arg);\n }\n return cache[arg];\n };\n}","import responsivePropType from './responsivePropType';\nimport { handleBreakpoints } from './breakpoints';\nimport { getPath } from './style';\nimport merge from './merge';\nimport memoize from './memoize';\nconst properties = {\n m: 'margin',\n p: 'padding'\n};\nconst directions = {\n t: 'Top',\n r: 'Right',\n b: 'Bottom',\n l: 'Left',\n x: ['Left', 'Right'],\n y: ['Top', 'Bottom']\n};\nconst aliases = {\n marginX: 'mx',\n marginY: 'my',\n paddingX: 'px',\n paddingY: 'py'\n};\n\n// memoize() impact:\n// From 300,000 ops/sec\n// To 350,000 ops/sec\nconst getCssProperties = memoize(prop => {\n // It's not a shorthand notation.\n if (prop.length > 2) {\n if (aliases[prop]) {\n prop = aliases[prop];\n } else {\n return [prop];\n }\n }\n const [a, b] = prop.split('');\n const property = properties[a];\n const direction = directions[b] || '';\n return Array.isArray(direction) ? direction.map(dir => property + dir) : [property + direction];\n});\nexport const marginKeys = ['m', 'mt', 'mr', 'mb', 'ml', 'mx', 'my', 'margin', 'marginTop', 'marginRight', 'marginBottom', 'marginLeft', 'marginX', 'marginY', 'marginInline', 'marginInlineStart', 'marginInlineEnd', 'marginBlock', 'marginBlockStart', 'marginBlockEnd'];\nexport const paddingKeys = ['p', 'pt', 'pr', 'pb', 'pl', 'px', 'py', 'padding', 'paddingTop', 'paddingRight', 'paddingBottom', 'paddingLeft', 'paddingX', 'paddingY', 'paddingInline', 'paddingInlineStart', 'paddingInlineEnd', 'paddingBlock', 'paddingBlockStart', 'paddingBlockEnd'];\nconst spacingKeys = [...marginKeys, ...paddingKeys];\nexport function createUnaryUnit(theme, themeKey, defaultValue, propName) {\n var _getPath;\n const themeSpacing = (_getPath = getPath(theme, themeKey, false)) != null ? _getPath : defaultValue;\n if (typeof themeSpacing === 'number') {\n return abs => {\n if (typeof abs === 'string') {\n return abs;\n }\n if (process.env.NODE_ENV !== 'production') {\n if (typeof abs !== 'number') {\n console.error(`MUI: Expected ${propName} argument to be a number or a string, got ${abs}.`);\n }\n }\n return themeSpacing * abs;\n };\n }\n if (Array.isArray(themeSpacing)) {\n return abs => {\n if (typeof abs === 'string') {\n return abs;\n }\n if (process.env.NODE_ENV !== 'production') {\n if (!Number.isInteger(abs)) {\n console.error([`MUI: The \\`theme.${themeKey}\\` array type cannot be combined with non integer values.` + `You should either use an integer value that can be used as index, or define the \\`theme.${themeKey}\\` as a number.`].join('\\n'));\n } else if (abs > themeSpacing.length - 1) {\n console.error([`MUI: The value provided (${abs}) overflows.`, `The supported values are: ${JSON.stringify(themeSpacing)}.`, `${abs} > ${themeSpacing.length - 1}, you need to add the missing values.`].join('\\n'));\n }\n }\n return themeSpacing[abs];\n };\n }\n if (typeof themeSpacing === 'function') {\n return themeSpacing;\n }\n if (process.env.NODE_ENV !== 'production') {\n console.error([`MUI: The \\`theme.${themeKey}\\` value (${themeSpacing}) is invalid.`, 'It should be a number, an array or a function.'].join('\\n'));\n }\n return () => undefined;\n}\nexport function createUnarySpacing(theme) {\n return createUnaryUnit(theme, 'spacing', 8, 'spacing');\n}\nexport function getValue(transformer, propValue) {\n if (typeof propValue === 'string' || propValue == null) {\n return propValue;\n }\n const abs = Math.abs(propValue);\n const transformed = transformer(abs);\n if (propValue >= 0) {\n return transformed;\n }\n if (typeof transformed === 'number') {\n return -transformed;\n }\n return `-${transformed}`;\n}\nexport function getStyleFromPropValue(cssProperties, transformer) {\n return propValue => cssProperties.reduce((acc, cssProperty) => {\n acc[cssProperty] = getValue(transformer, propValue);\n return acc;\n }, {});\n}\nfunction resolveCssProperty(props, keys, prop, transformer) {\n // Using a hash computation over an array iteration could be faster, but with only 28 items,\n // it's doesn't worth the bundle size.\n if (keys.indexOf(prop) === -1) {\n return null;\n }\n const cssProperties = getCssProperties(prop);\n const styleFromPropValue = getStyleFromPropValue(cssProperties, transformer);\n const propValue = props[prop];\n return handleBreakpoints(props, propValue, styleFromPropValue);\n}\nfunction style(props, keys) {\n const transformer = createUnarySpacing(props.theme);\n return Object.keys(props).map(prop => resolveCssProperty(props, keys, prop, transformer)).reduce(merge, {});\n}\nexport function margin(props) {\n return style(props, marginKeys);\n}\nmargin.propTypes = process.env.NODE_ENV !== 'production' ? marginKeys.reduce((obj, key) => {\n obj[key] = responsivePropType;\n return obj;\n}, {}) : {};\nmargin.filterProps = marginKeys;\nexport function padding(props) {\n return style(props, paddingKeys);\n}\npadding.propTypes = process.env.NODE_ENV !== 'production' ? paddingKeys.reduce((obj, key) => {\n obj[key] = responsivePropType;\n return obj;\n}, {}) : {};\npadding.filterProps = paddingKeys;\nfunction spacing(props) {\n return style(props, spacingKeys);\n}\nspacing.propTypes = process.env.NODE_ENV !== 'production' ? spacingKeys.reduce((obj, key) => {\n obj[key] = responsivePropType;\n return obj;\n}, {}) : {};\nspacing.filterProps = spacingKeys;\nexport default spacing;","import { createUnarySpacing } from '../spacing';\n\n// The different signatures imply different meaning for their arguments that can't be expressed structurally.\n// We express the difference with variable names.\n\nexport default function createSpacing(spacingInput = 8) {\n // Already transformed.\n if (spacingInput.mui) {\n return spacingInput;\n }\n\n // Material Design layouts are visually balanced. Most measurements align to an 8dp grid, which aligns both spacing and the overall layout.\n // Smaller components, such as icons, can align to a 4dp grid.\n // https://m2.material.io/design/layout/understanding-layout.html\n const transform = createUnarySpacing({\n spacing: spacingInput\n });\n const spacing = (...argsInput) => {\n if (process.env.NODE_ENV !== 'production') {\n if (!(argsInput.length <= 4)) {\n console.error(`MUI: Too many arguments provided, expected between 0 and 4, got ${argsInput.length}`);\n }\n }\n const args = argsInput.length === 0 ? [1] : argsInput;\n return args.map(argument => {\n const output = transform(argument);\n return typeof output === 'number' ? `${output}px` : output;\n }).join(' ');\n };\n spacing.mui = true;\n return spacing;\n}","import merge from './merge';\nfunction compose(...styles) {\n const handlers = styles.reduce((acc, style) => {\n style.filterProps.forEach(prop => {\n acc[prop] = style;\n });\n return acc;\n }, {});\n\n // false positive\n // eslint-disable-next-line react/function-component-definition\n const fn = props => {\n return Object.keys(props).reduce((acc, prop) => {\n if (handlers[prop]) {\n return merge(acc, handlers[prop](props));\n }\n return acc;\n }, {});\n };\n fn.propTypes = process.env.NODE_ENV !== 'production' ? styles.reduce((acc, style) => Object.assign(acc, style.propTypes), {}) : {};\n fn.filterProps = styles.reduce((acc, style) => acc.concat(style.filterProps), []);\n return fn;\n}\nexport default compose;","import responsivePropType from './responsivePropType';\nimport style from './style';\nimport compose from './compose';\nimport { createUnaryUnit, getValue } from './spacing';\nimport { handleBreakpoints } from './breakpoints';\nexport function borderTransform(value) {\n if (typeof value !== 'number') {\n return value;\n }\n return `${value}px solid`;\n}\nfunction createBorderStyle(prop, transform) {\n return style({\n prop,\n themeKey: 'borders',\n transform\n });\n}\nexport const border = createBorderStyle('border', borderTransform);\nexport const borderTop = createBorderStyle('borderTop', borderTransform);\nexport const borderRight = createBorderStyle('borderRight', borderTransform);\nexport const borderBottom = createBorderStyle('borderBottom', borderTransform);\nexport const borderLeft = createBorderStyle('borderLeft', borderTransform);\nexport const borderColor = createBorderStyle('borderColor');\nexport const borderTopColor = createBorderStyle('borderTopColor');\nexport const borderRightColor = createBorderStyle('borderRightColor');\nexport const borderBottomColor = createBorderStyle('borderBottomColor');\nexport const borderLeftColor = createBorderStyle('borderLeftColor');\nexport const outline = createBorderStyle('outline', borderTransform);\nexport const outlineColor = createBorderStyle('outlineColor');\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const borderRadius = props => {\n if (props.borderRadius !== undefined && props.borderRadius !== null) {\n const transformer = createUnaryUnit(props.theme, 'shape.borderRadius', 4, 'borderRadius');\n const styleFromPropValue = propValue => ({\n borderRadius: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.borderRadius, styleFromPropValue);\n }\n return null;\n};\nborderRadius.propTypes = process.env.NODE_ENV !== 'production' ? {\n borderRadius: responsivePropType\n} : {};\nborderRadius.filterProps = ['borderRadius'];\nconst borders = compose(border, borderTop, borderRight, borderBottom, borderLeft, borderColor, borderTopColor, borderRightColor, borderBottomColor, borderLeftColor, borderRadius, outline, outlineColor);\nexport default borders;","import style from './style';\nimport compose from './compose';\nimport { createUnaryUnit, getValue } from './spacing';\nimport { handleBreakpoints } from './breakpoints';\nimport responsivePropType from './responsivePropType';\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const gap = props => {\n if (props.gap !== undefined && props.gap !== null) {\n const transformer = createUnaryUnit(props.theme, 'spacing', 8, 'gap');\n const styleFromPropValue = propValue => ({\n gap: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.gap, styleFromPropValue);\n }\n return null;\n};\ngap.propTypes = process.env.NODE_ENV !== 'production' ? {\n gap: responsivePropType\n} : {};\ngap.filterProps = ['gap'];\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const columnGap = props => {\n if (props.columnGap !== undefined && props.columnGap !== null) {\n const transformer = createUnaryUnit(props.theme, 'spacing', 8, 'columnGap');\n const styleFromPropValue = propValue => ({\n columnGap: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.columnGap, styleFromPropValue);\n }\n return null;\n};\ncolumnGap.propTypes = process.env.NODE_ENV !== 'production' ? {\n columnGap: responsivePropType\n} : {};\ncolumnGap.filterProps = ['columnGap'];\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const rowGap = props => {\n if (props.rowGap !== undefined && props.rowGap !== null) {\n const transformer = createUnaryUnit(props.theme, 'spacing', 8, 'rowGap');\n const styleFromPropValue = propValue => ({\n rowGap: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.rowGap, styleFromPropValue);\n }\n return null;\n};\nrowGap.propTypes = process.env.NODE_ENV !== 'production' ? {\n rowGap: responsivePropType\n} : {};\nrowGap.filterProps = ['rowGap'];\nexport const gridColumn = style({\n prop: 'gridColumn'\n});\nexport const gridRow = style({\n prop: 'gridRow'\n});\nexport const gridAutoFlow = style({\n prop: 'gridAutoFlow'\n});\nexport const gridAutoColumns = style({\n prop: 'gridAutoColumns'\n});\nexport const gridAutoRows = style({\n prop: 'gridAutoRows'\n});\nexport const gridTemplateColumns = style({\n prop: 'gridTemplateColumns'\n});\nexport const gridTemplateRows = style({\n prop: 'gridTemplateRows'\n});\nexport const gridTemplateAreas = style({\n prop: 'gridTemplateAreas'\n});\nexport const gridArea = style({\n prop: 'gridArea'\n});\nconst grid = compose(gap, columnGap, rowGap, gridColumn, gridRow, gridAutoFlow, gridAutoColumns, gridAutoRows, gridTemplateColumns, gridTemplateRows, gridTemplateAreas, gridArea);\nexport default grid;","import style from './style';\nimport compose from './compose';\nexport function paletteTransform(value, userValue) {\n if (userValue === 'grey') {\n return userValue;\n }\n return value;\n}\nexport const color = style({\n prop: 'color',\n themeKey: 'palette',\n transform: paletteTransform\n});\nexport const bgcolor = style({\n prop: 'bgcolor',\n cssProperty: 'backgroundColor',\n themeKey: 'palette',\n transform: paletteTransform\n});\nexport const backgroundColor = style({\n prop: 'backgroundColor',\n themeKey: 'palette',\n transform: paletteTransform\n});\nconst palette = compose(color, bgcolor, backgroundColor);\nexport default palette;","import style from './style';\nimport compose from './compose';\nimport { handleBreakpoints, values as breakpointsValues } from './breakpoints';\nexport function sizingTransform(value) {\n return value <= 1 && value !== 0 ? `${value * 100}%` : value;\n}\nexport const width = style({\n prop: 'width',\n transform: sizingTransform\n});\nexport const maxWidth = props => {\n if (props.maxWidth !== undefined && props.maxWidth !== null) {\n const styleFromPropValue = propValue => {\n var _props$theme, _props$theme2;\n const breakpoint = ((_props$theme = props.theme) == null || (_props$theme = _props$theme.breakpoints) == null || (_props$theme = _props$theme.values) == null ? void 0 : _props$theme[propValue]) || breakpointsValues[propValue];\n if (!breakpoint) {\n return {\n maxWidth: sizingTransform(propValue)\n };\n }\n if (((_props$theme2 = props.theme) == null || (_props$theme2 = _props$theme2.breakpoints) == null ? void 0 : _props$theme2.unit) !== 'px') {\n return {\n maxWidth: `${breakpoint}${props.theme.breakpoints.unit}`\n };\n }\n return {\n maxWidth: breakpoint\n };\n };\n return handleBreakpoints(props, props.maxWidth, styleFromPropValue);\n }\n return null;\n};\nmaxWidth.filterProps = ['maxWidth'];\nexport const minWidth = style({\n prop: 'minWidth',\n transform: sizingTransform\n});\nexport const height = style({\n prop: 'height',\n transform: sizingTransform\n});\nexport const maxHeight = style({\n prop: 'maxHeight',\n transform: sizingTransform\n});\nexport const minHeight = style({\n prop: 'minHeight',\n transform: sizingTransform\n});\nexport const sizeWidth = style({\n prop: 'size',\n cssProperty: 'width',\n transform: sizingTransform\n});\nexport const sizeHeight = style({\n prop: 'size',\n cssProperty: 'height',\n transform: sizingTransform\n});\nexport const boxSizing = style({\n prop: 'boxSizing'\n});\nconst sizing = compose(width, maxWidth, minWidth, height, maxHeight, minHeight, boxSizing);\nexport default sizing;","import { padding, margin } from '../spacing';\nimport { borderRadius, borderTransform } from '../borders';\nimport { gap, rowGap, columnGap } from '../cssGrid';\nimport { paletteTransform } from '../palette';\nimport { maxWidth, sizingTransform } from '../sizing';\nconst defaultSxConfig = {\n // borders\n border: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderTop: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderRight: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderBottom: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderLeft: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderColor: {\n themeKey: 'palette'\n },\n borderTopColor: {\n themeKey: 'palette'\n },\n borderRightColor: {\n themeKey: 'palette'\n },\n borderBottomColor: {\n themeKey: 'palette'\n },\n borderLeftColor: {\n themeKey: 'palette'\n },\n outline: {\n themeKey: 'borders',\n transform: borderTransform\n },\n outlineColor: {\n themeKey: 'palette'\n },\n borderRadius: {\n themeKey: 'shape.borderRadius',\n style: borderRadius\n },\n // palette\n color: {\n themeKey: 'palette',\n transform: paletteTransform\n },\n bgcolor: {\n themeKey: 'palette',\n cssProperty: 'backgroundColor',\n transform: paletteTransform\n },\n backgroundColor: {\n themeKey: 'palette',\n transform: paletteTransform\n },\n // spacing\n p: {\n style: padding\n },\n pt: {\n style: padding\n },\n pr: {\n style: padding\n },\n pb: {\n style: padding\n },\n pl: {\n style: padding\n },\n px: {\n style: padding\n },\n py: {\n style: padding\n },\n padding: {\n style: padding\n },\n paddingTop: {\n style: padding\n },\n paddingRight: {\n style: padding\n },\n paddingBottom: {\n style: padding\n },\n paddingLeft: {\n style: padding\n },\n paddingX: {\n style: padding\n },\n paddingY: {\n style: padding\n },\n paddingInline: {\n style: padding\n },\n paddingInlineStart: {\n style: padding\n },\n paddingInlineEnd: {\n style: padding\n },\n paddingBlock: {\n style: padding\n },\n paddingBlockStart: {\n style: padding\n },\n paddingBlockEnd: {\n style: padding\n },\n m: {\n style: margin\n },\n mt: {\n style: margin\n },\n mr: {\n style: margin\n },\n mb: {\n style: margin\n },\n ml: {\n style: margin\n },\n mx: {\n style: margin\n },\n my: {\n style: margin\n },\n margin: {\n style: margin\n },\n marginTop: {\n style: margin\n },\n marginRight: {\n style: margin\n },\n marginBottom: {\n style: margin\n },\n marginLeft: {\n style: margin\n },\n marginX: {\n style: margin\n },\n marginY: {\n style: margin\n },\n marginInline: {\n style: margin\n },\n marginInlineStart: {\n style: margin\n },\n marginInlineEnd: {\n style: margin\n },\n marginBlock: {\n style: margin\n },\n marginBlockStart: {\n style: margin\n },\n marginBlockEnd: {\n style: margin\n },\n // display\n displayPrint: {\n cssProperty: false,\n transform: value => ({\n '@media print': {\n display: value\n }\n })\n },\n display: {},\n overflow: {},\n textOverflow: {},\n visibility: {},\n whiteSpace: {},\n // flexbox\n flexBasis: {},\n flexDirection: {},\n flexWrap: {},\n justifyContent: {},\n alignItems: {},\n alignContent: {},\n order: {},\n flex: {},\n flexGrow: {},\n flexShrink: {},\n alignSelf: {},\n justifyItems: {},\n justifySelf: {},\n // grid\n gap: {\n style: gap\n },\n rowGap: {\n style: rowGap\n },\n columnGap: {\n style: columnGap\n },\n gridColumn: {},\n gridRow: {},\n gridAutoFlow: {},\n gridAutoColumns: {},\n gridAutoRows: {},\n gridTemplateColumns: {},\n gridTemplateRows: {},\n gridTemplateAreas: {},\n gridArea: {},\n // positions\n position: {},\n zIndex: {\n themeKey: 'zIndex'\n },\n top: {},\n right: {},\n bottom: {},\n left: {},\n // shadows\n boxShadow: {\n themeKey: 'shadows'\n },\n // sizing\n width: {\n transform: sizingTransform\n },\n maxWidth: {\n style: maxWidth\n },\n minWidth: {\n transform: sizingTransform\n },\n height: {\n transform: sizingTransform\n },\n maxHeight: {\n transform: sizingTransform\n },\n minHeight: {\n transform: sizingTransform\n },\n boxSizing: {},\n // typography\n fontFamily: {\n themeKey: 'typography'\n },\n fontSize: {\n themeKey: 'typography'\n },\n fontStyle: {\n themeKey: 'typography'\n },\n fontWeight: {\n themeKey: 'typography'\n },\n letterSpacing: {},\n textTransform: {},\n lineHeight: {},\n textAlign: {},\n typography: {\n cssProperty: false,\n themeKey: 'typography'\n }\n};\nexport default defaultSxConfig;","import capitalize from '@mui/utils/capitalize';\nimport merge from '../merge';\nimport { getPath, getStyleValue as getValue } from '../style';\nimport { handleBreakpoints, createEmptyBreakpointObject, removeUnusedBreakpoints } from '../breakpoints';\nimport defaultSxConfig from './defaultSxConfig';\nfunction objectsHaveSameKeys(...objects) {\n const allKeys = objects.reduce((keys, object) => keys.concat(Object.keys(object)), []);\n const union = new Set(allKeys);\n return objects.every(object => union.size === Object.keys(object).length);\n}\nfunction callIfFn(maybeFn, arg) {\n return typeof maybeFn === 'function' ? maybeFn(arg) : maybeFn;\n}\n\n// eslint-disable-next-line @typescript-eslint/naming-convention\nexport function unstable_createStyleFunctionSx() {\n function getThemeValue(prop, val, theme, config) {\n const props = {\n [prop]: val,\n theme\n };\n const options = config[prop];\n if (!options) {\n return {\n [prop]: val\n };\n }\n const {\n cssProperty = prop,\n themeKey,\n transform,\n style\n } = options;\n if (val == null) {\n return null;\n }\n\n // TODO v6: remove, see https://github.com/mui/material-ui/pull/38123\n if (themeKey === 'typography' && val === 'inherit') {\n return {\n [prop]: val\n };\n }\n const themeMapping = getPath(theme, themeKey) || {};\n if (style) {\n return style(props);\n }\n const styleFromPropValue = propValueFinal => {\n let value = getValue(themeMapping, transform, propValueFinal);\n if (propValueFinal === value && typeof propValueFinal === 'string') {\n // Haven't found value\n value = getValue(themeMapping, transform, `${prop}${propValueFinal === 'default' ? '' : capitalize(propValueFinal)}`, propValueFinal);\n }\n if (cssProperty === false) {\n return value;\n }\n return {\n [cssProperty]: value\n };\n };\n return handleBreakpoints(props, val, styleFromPropValue);\n }\n function styleFunctionSx(props) {\n var _theme$unstable_sxCon;\n const {\n sx,\n theme = {}\n } = props || {};\n if (!sx) {\n return null; // Emotion & styled-components will neglect null\n }\n const config = (_theme$unstable_sxCon = theme.unstable_sxConfig) != null ? _theme$unstable_sxCon : defaultSxConfig;\n\n /*\n * Receive `sxInput` as object or callback\n * and then recursively check keys & values to create media query object styles.\n * (the result will be used in `styled`)\n */\n function traverse(sxInput) {\n let sxObject = sxInput;\n if (typeof sxInput === 'function') {\n sxObject = sxInput(theme);\n } else if (typeof sxInput !== 'object') {\n // value\n return sxInput;\n }\n if (!sxObject) {\n return null;\n }\n const emptyBreakpoints = createEmptyBreakpointObject(theme.breakpoints);\n const breakpointsKeys = Object.keys(emptyBreakpoints);\n let css = emptyBreakpoints;\n Object.keys(sxObject).forEach(styleKey => {\n const value = callIfFn(sxObject[styleKey], theme);\n if (value !== null && value !== undefined) {\n if (typeof value === 'object') {\n if (config[styleKey]) {\n css = merge(css, getThemeValue(styleKey, value, theme, config));\n } else {\n const breakpointsValues = handleBreakpoints({\n theme\n }, value, x => ({\n [styleKey]: x\n }));\n if (objectsHaveSameKeys(breakpointsValues, value)) {\n css[styleKey] = styleFunctionSx({\n sx: value,\n theme\n });\n } else {\n css = merge(css, breakpointsValues);\n }\n }\n } else {\n css = merge(css, getThemeValue(styleKey, value, theme, config));\n }\n }\n });\n return removeUnusedBreakpoints(breakpointsKeys, css);\n }\n return Array.isArray(sx) ? sx.map(traverse) : traverse(sx);\n }\n return styleFunctionSx;\n}\nconst styleFunctionSx = unstable_createStyleFunctionSx();\nstyleFunctionSx.filterProps = ['sx'];\nexport default styleFunctionSx;","/**\n * A universal utility to style components with multiple color modes. Always use it from the theme object.\n * It works with:\n * - [Basic theme](https://mui.com/material-ui/customization/dark-mode/)\n * - [CSS theme variables](https://mui.com/material-ui/experimental-api/css-theme-variables/overview/)\n * - Zero-runtime engine\n *\n * Tips: Use an array over object spread and place `theme.applyStyles()` last.\n *\n * ✅ [{ background: '#e5e5e5' }, theme.applyStyles('dark', { background: '#1c1c1c' })]\n *\n * 🚫 { background: '#e5e5e5', ...theme.applyStyles('dark', { background: '#1c1c1c' })}\n *\n * @example\n * 1. using with `styled`:\n * ```jsx\n * const Component = styled('div')(({ theme }) => [\n * { background: '#e5e5e5' },\n * theme.applyStyles('dark', {\n * background: '#1c1c1c',\n * color: '#fff',\n * }),\n * ]);\n * ```\n *\n * @example\n * 2. using with `sx` prop:\n * ```jsx\n * [\n * { background: '#e5e5e5' },\n * theme.applyStyles('dark', {\n * background: '#1c1c1c',\n * color: '#fff',\n * }),\n * ]}\n * />\n * ```\n *\n * @example\n * 3. theming a component:\n * ```jsx\n * extendTheme({\n * components: {\n * MuiButton: {\n * styleOverrides: {\n * root: ({ theme }) => [\n * { background: '#e5e5e5' },\n * theme.applyStyles('dark', {\n * background: '#1c1c1c',\n * color: '#fff',\n * }),\n * ],\n * },\n * }\n * }\n * })\n *```\n */\nexport default function applyStyles(key, styles) {\n // @ts-expect-error this is 'any' type\n const theme = this;\n if (theme.vars && typeof theme.getColorSchemeSelector === 'function') {\n // If CssVarsProvider is used as a provider,\n // returns '* :where([data-mui-color-scheme=\"light|dark\"]) &'\n const selector = theme.getColorSchemeSelector(key).replace(/(\\[[^\\]]+\\])/, '*:where($1)');\n return {\n [selector]: styles\n };\n }\n if (theme.palette.mode === key) {\n return styles;\n }\n return {};\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"breakpoints\", \"palette\", \"spacing\", \"shape\"];\nimport deepmerge from '@mui/utils/deepmerge';\nimport createBreakpoints from './createBreakpoints';\nimport shape from './shape';\nimport createSpacing from './createSpacing';\nimport styleFunctionSx from '../styleFunctionSx/styleFunctionSx';\nimport defaultSxConfig from '../styleFunctionSx/defaultSxConfig';\nimport applyStyles from './applyStyles';\nfunction createTheme(options = {}, ...args) {\n const {\n breakpoints: breakpointsInput = {},\n palette: paletteInput = {},\n spacing: spacingInput,\n shape: shapeInput = {}\n } = options,\n other = _objectWithoutPropertiesLoose(options, _excluded);\n const breakpoints = createBreakpoints(breakpointsInput);\n const spacing = createSpacing(spacingInput);\n let muiTheme = deepmerge({\n breakpoints,\n direction: 'ltr',\n components: {},\n // Inject component definitions.\n palette: _extends({\n mode: 'light'\n }, paletteInput),\n spacing,\n shape: _extends({}, shape, shapeInput)\n }, other);\n muiTheme.applyStyles = applyStyles;\n muiTheme = args.reduce((acc, argument) => deepmerge(acc, argument), muiTheme);\n muiTheme.unstable_sxConfig = _extends({}, defaultSxConfig, other == null ? void 0 : other.unstable_sxConfig);\n muiTheme.unstable_sx = function sx(props) {\n return styleFunctionSx({\n sx: props,\n theme: this\n });\n };\n return muiTheme;\n}\nexport default createTheme;","'use client';\n\nimport * as React from 'react';\nimport { ThemeContext } from '@mui/styled-engine';\nfunction isObjectEmpty(obj) {\n return Object.keys(obj).length === 0;\n}\nfunction useTheme(defaultTheme = null) {\n const contextTheme = React.useContext(ThemeContext);\n return !contextTheme || isObjectEmpty(contextTheme) ? defaultTheme : contextTheme;\n}\nexport default useTheme;","'use client';\n\nimport createTheme from './createTheme';\nimport useThemeWithoutDefault from './useThemeWithoutDefault';\nexport const systemDefaultTheme = createTheme();\nfunction useTheme(defaultTheme = systemDefaultTheme) {\n return useThemeWithoutDefault(defaultTheme);\n}\nexport default useTheme;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"ownerState\"],\n _excluded2 = [\"variants\"],\n _excluded3 = [\"name\", \"slot\", \"skipVariantsResolver\", \"skipSx\", \"overridesResolver\"];\n/* eslint-disable no-underscore-dangle */\nimport styledEngineStyled, { internal_processStyles as processStyles } from '@mui/styled-engine';\nimport { isPlainObject } from '@mui/utils/deepmerge';\nimport capitalize from '@mui/utils/capitalize';\nimport getDisplayName from '@mui/utils/getDisplayName';\nimport createTheme from './createTheme';\nimport styleFunctionSx from './styleFunctionSx';\nfunction isEmpty(obj) {\n return Object.keys(obj).length === 0;\n}\n\n// https://github.com/emotion-js/emotion/blob/26ded6109fcd8ca9875cc2ce4564fee678a3f3c5/packages/styled/src/utils.js#L40\nfunction isStringTag(tag) {\n return typeof tag === 'string' &&\n // 96 is one less than the char code\n // for \"a\" so this is checking that\n // it's a lowercase character\n tag.charCodeAt(0) > 96;\n}\n\n// Update /system/styled/#api in case if this changes\nexport function shouldForwardProp(prop) {\n return prop !== 'ownerState' && prop !== 'theme' && prop !== 'sx' && prop !== 'as';\n}\nexport const systemDefaultTheme = createTheme();\nconst lowercaseFirstLetter = string => {\n if (!string) {\n return string;\n }\n return string.charAt(0).toLowerCase() + string.slice(1);\n};\nfunction resolveTheme({\n defaultTheme,\n theme,\n themeId\n}) {\n return isEmpty(theme) ? defaultTheme : theme[themeId] || theme;\n}\nfunction defaultOverridesResolver(slot) {\n if (!slot) {\n return null;\n }\n return (props, styles) => styles[slot];\n}\nfunction processStyleArg(callableStyle, _ref) {\n let {\n ownerState\n } = _ref,\n props = _objectWithoutPropertiesLoose(_ref, _excluded);\n const resolvedStylesArg = typeof callableStyle === 'function' ? callableStyle(_extends({\n ownerState\n }, props)) : callableStyle;\n if (Array.isArray(resolvedStylesArg)) {\n return resolvedStylesArg.flatMap(resolvedStyle => processStyleArg(resolvedStyle, _extends({\n ownerState\n }, props)));\n }\n if (!!resolvedStylesArg && typeof resolvedStylesArg === 'object' && Array.isArray(resolvedStylesArg.variants)) {\n const {\n variants = []\n } = resolvedStylesArg,\n otherStyles = _objectWithoutPropertiesLoose(resolvedStylesArg, _excluded2);\n let result = otherStyles;\n variants.forEach(variant => {\n let isMatch = true;\n if (typeof variant.props === 'function') {\n isMatch = variant.props(_extends({\n ownerState\n }, props, ownerState));\n } else {\n Object.keys(variant.props).forEach(key => {\n if ((ownerState == null ? void 0 : ownerState[key]) !== variant.props[key] && props[key] !== variant.props[key]) {\n isMatch = false;\n }\n });\n }\n if (isMatch) {\n if (!Array.isArray(result)) {\n result = [result];\n }\n result.push(typeof variant.style === 'function' ? variant.style(_extends({\n ownerState\n }, props, ownerState)) : variant.style);\n }\n });\n return result;\n }\n return resolvedStylesArg;\n}\nexport default function createStyled(input = {}) {\n const {\n themeId,\n defaultTheme = systemDefaultTheme,\n rootShouldForwardProp = shouldForwardProp,\n slotShouldForwardProp = shouldForwardProp\n } = input;\n const systemSx = props => {\n return styleFunctionSx(_extends({}, props, {\n theme: resolveTheme(_extends({}, props, {\n defaultTheme,\n themeId\n }))\n }));\n };\n systemSx.__mui_systemSx = true;\n return (tag, inputOptions = {}) => {\n // Filter out the `sx` style function from the previous styled component to prevent unnecessary styles generated by the composite components.\n processStyles(tag, styles => styles.filter(style => !(style != null && style.__mui_systemSx)));\n const {\n name: componentName,\n slot: componentSlot,\n skipVariantsResolver: inputSkipVariantsResolver,\n skipSx: inputSkipSx,\n // TODO v6: remove `lowercaseFirstLetter()` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n overridesResolver = defaultOverridesResolver(lowercaseFirstLetter(componentSlot))\n } = inputOptions,\n options = _objectWithoutPropertiesLoose(inputOptions, _excluded3);\n\n // if skipVariantsResolver option is defined, take the value, otherwise, true for root and false for other slots.\n const skipVariantsResolver = inputSkipVariantsResolver !== undefined ? inputSkipVariantsResolver :\n // TODO v6: remove `Root` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n componentSlot && componentSlot !== 'Root' && componentSlot !== 'root' || false;\n const skipSx = inputSkipSx || false;\n let label;\n if (process.env.NODE_ENV !== 'production') {\n if (componentName) {\n // TODO v6: remove `lowercaseFirstLetter()` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n label = `${componentName}-${lowercaseFirstLetter(componentSlot || 'Root')}`;\n }\n }\n let shouldForwardPropOption = shouldForwardProp;\n\n // TODO v6: remove `Root` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n if (componentSlot === 'Root' || componentSlot === 'root') {\n shouldForwardPropOption = rootShouldForwardProp;\n } else if (componentSlot) {\n // any other slot specified\n shouldForwardPropOption = slotShouldForwardProp;\n } else if (isStringTag(tag)) {\n // for string (html) tag, preserve the behavior in emotion & styled-components.\n shouldForwardPropOption = undefined;\n }\n const defaultStyledResolver = styledEngineStyled(tag, _extends({\n shouldForwardProp: shouldForwardPropOption,\n label\n }, options));\n const transformStyleArg = stylesArg => {\n // On the server Emotion doesn't use React.forwardRef for creating components, so the created\n // component stays as a function. This condition makes sure that we do not interpolate functions\n // which are basically components used as a selectors.\n if (typeof stylesArg === 'function' && stylesArg.__emotion_real !== stylesArg || isPlainObject(stylesArg)) {\n return props => processStyleArg(stylesArg, _extends({}, props, {\n theme: resolveTheme({\n theme: props.theme,\n defaultTheme,\n themeId\n })\n }));\n }\n return stylesArg;\n };\n const muiStyledResolver = (styleArg, ...expressions) => {\n let transformedStyleArg = transformStyleArg(styleArg);\n const expressionsWithDefaultTheme = expressions ? expressions.map(transformStyleArg) : [];\n if (componentName && overridesResolver) {\n expressionsWithDefaultTheme.push(props => {\n const theme = resolveTheme(_extends({}, props, {\n defaultTheme,\n themeId\n }));\n if (!theme.components || !theme.components[componentName] || !theme.components[componentName].styleOverrides) {\n return null;\n }\n const styleOverrides = theme.components[componentName].styleOverrides;\n const resolvedStyleOverrides = {};\n // TODO: v7 remove iteration and use `resolveStyleArg(styleOverrides[slot])` directly\n Object.entries(styleOverrides).forEach(([slotKey, slotStyle]) => {\n resolvedStyleOverrides[slotKey] = processStyleArg(slotStyle, _extends({}, props, {\n theme\n }));\n });\n return overridesResolver(props, resolvedStyleOverrides);\n });\n }\n if (componentName && !skipVariantsResolver) {\n expressionsWithDefaultTheme.push(props => {\n var _theme$components;\n const theme = resolveTheme(_extends({}, props, {\n defaultTheme,\n themeId\n }));\n const themeVariants = theme == null || (_theme$components = theme.components) == null || (_theme$components = _theme$components[componentName]) == null ? void 0 : _theme$components.variants;\n return processStyleArg({\n variants: themeVariants\n }, _extends({}, props, {\n theme\n }));\n });\n }\n if (!skipSx) {\n expressionsWithDefaultTheme.push(systemSx);\n }\n const numOfCustomFnsApplied = expressionsWithDefaultTheme.length - expressions.length;\n if (Array.isArray(styleArg) && numOfCustomFnsApplied > 0) {\n const placeholders = new Array(numOfCustomFnsApplied).fill('');\n // If the type is array, than we need to add placeholders in the template for the overrides, variants and the sx styles.\n transformedStyleArg = [...styleArg, ...placeholders];\n transformedStyleArg.raw = [...styleArg.raw, ...placeholders];\n }\n const Component = defaultStyledResolver(transformedStyleArg, ...expressionsWithDefaultTheme);\n if (process.env.NODE_ENV !== 'production') {\n let displayName;\n if (componentName) {\n displayName = `${componentName}${capitalize(componentSlot || '')}`;\n }\n if (displayName === undefined) {\n displayName = `Styled(${getDisplayName(tag)})`;\n }\n Component.displayName = displayName;\n }\n if (tag.muiName) {\n Component.muiName = tag.muiName;\n }\n return Component;\n };\n if (defaultStyledResolver.withConfig) {\n muiStyledResolver.withConfig = defaultStyledResolver.withConfig;\n }\n return muiStyledResolver;\n };\n}","import resolveProps from '@mui/utils/resolveProps';\nexport default function getThemeProps(params) {\n const {\n theme,\n name,\n props\n } = params;\n if (!theme || !theme.components || !theme.components[name] || !theme.components[name].defaultProps) {\n return props;\n }\n return resolveProps(theme.components[name].defaultProps, props);\n}","'use client';\n\nimport getThemeProps from './getThemeProps';\nimport useTheme from '../useTheme';\nexport default function useThemeProps({\n props,\n name,\n defaultTheme,\n themeId\n}) {\n let theme = useTheme(defaultTheme);\n if (themeId) {\n theme = theme[themeId] || theme;\n }\n const mergedProps = getThemeProps({\n theme,\n name,\n props\n });\n return mergedProps;\n}","import _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\n/* eslint-disable @typescript-eslint/naming-convention */\nimport clamp from '@mui/utils/clamp';\n/**\n * Returns a number whose value is limited to the given range.\n * @param {number} value The value to be clamped\n * @param {number} min The lower boundary of the output range\n * @param {number} max The upper boundary of the output range\n * @returns {number} A number in the range [min, max]\n */\nfunction clampWrapper(value, min = 0, max = 1) {\n if (process.env.NODE_ENV !== 'production') {\n if (value < min || value > max) {\n console.error(`MUI: The value provided ${value} is out of range [${min}, ${max}].`);\n }\n }\n return clamp(value, min, max);\n}\n\n/**\n * Converts a color from CSS hex format to CSS rgb format.\n * @param {string} color - Hex color, i.e. #nnn or #nnnnnn\n * @returns {string} A CSS rgb color string\n */\nexport function hexToRgb(color) {\n color = color.slice(1);\n const re = new RegExp(`.{1,${color.length >= 6 ? 2 : 1}}`, 'g');\n let colors = color.match(re);\n if (colors && colors[0].length === 1) {\n colors = colors.map(n => n + n);\n }\n return colors ? `rgb${colors.length === 4 ? 'a' : ''}(${colors.map((n, index) => {\n return index < 3 ? parseInt(n, 16) : Math.round(parseInt(n, 16) / 255 * 1000) / 1000;\n }).join(', ')})` : '';\n}\nfunction intToHex(int) {\n const hex = int.toString(16);\n return hex.length === 1 ? `0${hex}` : hex;\n}\n\n/**\n * Returns an object with the type and values of a color.\n *\n * Note: Does not support rgb % values.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @returns {object} - A MUI color object: {type: string, values: number[]}\n */\nexport function decomposeColor(color) {\n // Idempotent\n if (color.type) {\n return color;\n }\n if (color.charAt(0) === '#') {\n return decomposeColor(hexToRgb(color));\n }\n const marker = color.indexOf('(');\n const type = color.substring(0, marker);\n if (['rgb', 'rgba', 'hsl', 'hsla', 'color'].indexOf(type) === -1) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: Unsupported \\`${color}\\` color.\nThe following formats are supported: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color().` : _formatMuiErrorMessage(9, color));\n }\n let values = color.substring(marker + 1, color.length - 1);\n let colorSpace;\n if (type === 'color') {\n values = values.split(' ');\n colorSpace = values.shift();\n if (values.length === 4 && values[3].charAt(0) === '/') {\n values[3] = values[3].slice(1);\n }\n if (['srgb', 'display-p3', 'a98-rgb', 'prophoto-rgb', 'rec-2020'].indexOf(colorSpace) === -1) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: unsupported \\`${colorSpace}\\` color space.\nThe following color spaces are supported: srgb, display-p3, a98-rgb, prophoto-rgb, rec-2020.` : _formatMuiErrorMessage(10, colorSpace));\n }\n } else {\n values = values.split(',');\n }\n values = values.map(value => parseFloat(value));\n return {\n type,\n values,\n colorSpace\n };\n}\n\n/**\n * Returns a channel created from the input color.\n *\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @returns {string} - The channel for the color, that can be used in rgba or hsla colors\n */\nexport const colorChannel = color => {\n const decomposedColor = decomposeColor(color);\n return decomposedColor.values.slice(0, 3).map((val, idx) => decomposedColor.type.indexOf('hsl') !== -1 && idx !== 0 ? `${val}%` : val).join(' ');\n};\nexport const private_safeColorChannel = (color, warning) => {\n try {\n return colorChannel(color);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n};\n\n/**\n * Converts a color object with type and values to a string.\n * @param {object} color - Decomposed color\n * @param {string} color.type - One of: 'rgb', 'rgba', 'hsl', 'hsla', 'color'\n * @param {array} color.values - [n,n,n] or [n,n,n,n]\n * @returns {string} A CSS color string\n */\nexport function recomposeColor(color) {\n const {\n type,\n colorSpace\n } = color;\n let {\n values\n } = color;\n if (type.indexOf('rgb') !== -1) {\n // Only convert the first 3 values to int (i.e. not alpha)\n values = values.map((n, i) => i < 3 ? parseInt(n, 10) : n);\n } else if (type.indexOf('hsl') !== -1) {\n values[1] = `${values[1]}%`;\n values[2] = `${values[2]}%`;\n }\n if (type.indexOf('color') !== -1) {\n values = `${colorSpace} ${values.join(' ')}`;\n } else {\n values = `${values.join(', ')}`;\n }\n return `${type}(${values})`;\n}\n\n/**\n * Converts a color from CSS rgb format to CSS hex format.\n * @param {string} color - RGB color, i.e. rgb(n, n, n)\n * @returns {string} A CSS rgb color string, i.e. #nnnnnn\n */\nexport function rgbToHex(color) {\n // Idempotent\n if (color.indexOf('#') === 0) {\n return color;\n }\n const {\n values\n } = decomposeColor(color);\n return `#${values.map((n, i) => intToHex(i === 3 ? Math.round(255 * n) : n)).join('')}`;\n}\n\n/**\n * Converts a color from hsl format to rgb format.\n * @param {string} color - HSL color values\n * @returns {string} rgb color values\n */\nexport function hslToRgb(color) {\n color = decomposeColor(color);\n const {\n values\n } = color;\n const h = values[0];\n const s = values[1] / 100;\n const l = values[2] / 100;\n const a = s * Math.min(l, 1 - l);\n const f = (n, k = (n + h / 30) % 12) => l - a * Math.max(Math.min(k - 3, 9 - k, 1), -1);\n let type = 'rgb';\n const rgb = [Math.round(f(0) * 255), Math.round(f(8) * 255), Math.round(f(4) * 255)];\n if (color.type === 'hsla') {\n type += 'a';\n rgb.push(values[3]);\n }\n return recomposeColor({\n type,\n values: rgb\n });\n}\n/**\n * The relative brightness of any point in a color space,\n * normalized to 0 for darkest black and 1 for lightest white.\n *\n * Formula: https://www.w3.org/TR/WCAG20-TECHS/G17.html#G17-tests\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @returns {number} The relative brightness of the color in the range 0 - 1\n */\nexport function getLuminance(color) {\n color = decomposeColor(color);\n let rgb = color.type === 'hsl' || color.type === 'hsla' ? decomposeColor(hslToRgb(color)).values : color.values;\n rgb = rgb.map(val => {\n if (color.type !== 'color') {\n val /= 255; // normalized\n }\n return val <= 0.03928 ? val / 12.92 : ((val + 0.055) / 1.055) ** 2.4;\n });\n\n // Truncate at 3 digits\n return Number((0.2126 * rgb[0] + 0.7152 * rgb[1] + 0.0722 * rgb[2]).toFixed(3));\n}\n\n/**\n * Calculates the contrast ratio between two colors.\n *\n * Formula: https://www.w3.org/TR/WCAG20-TECHS/G17.html#G17-tests\n * @param {string} foreground - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla()\n * @param {string} background - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla()\n * @returns {number} A contrast ratio value in the range 0 - 21.\n */\nexport function getContrastRatio(foreground, background) {\n const lumA = getLuminance(foreground);\n const lumB = getLuminance(background);\n return (Math.max(lumA, lumB) + 0.05) / (Math.min(lumA, lumB) + 0.05);\n}\n\n/**\n * Sets the absolute transparency of a color.\n * Any existing alpha values are overwritten.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} value - value to set the alpha channel to in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function alpha(color, value) {\n color = decomposeColor(color);\n value = clampWrapper(value);\n if (color.type === 'rgb' || color.type === 'hsl') {\n color.type += 'a';\n }\n if (color.type === 'color') {\n color.values[3] = `/${value}`;\n } else {\n color.values[3] = value;\n }\n return recomposeColor(color);\n}\nexport function private_safeAlpha(color, value, warning) {\n try {\n return alpha(color, value);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Darkens a color.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} coefficient - multiplier in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function darken(color, coefficient) {\n color = decomposeColor(color);\n coefficient = clampWrapper(coefficient);\n if (color.type.indexOf('hsl') !== -1) {\n color.values[2] *= 1 - coefficient;\n } else if (color.type.indexOf('rgb') !== -1 || color.type.indexOf('color') !== -1) {\n for (let i = 0; i < 3; i += 1) {\n color.values[i] *= 1 - coefficient;\n }\n }\n return recomposeColor(color);\n}\nexport function private_safeDarken(color, coefficient, warning) {\n try {\n return darken(color, coefficient);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Lightens a color.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} coefficient - multiplier in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function lighten(color, coefficient) {\n color = decomposeColor(color);\n coefficient = clampWrapper(coefficient);\n if (color.type.indexOf('hsl') !== -1) {\n color.values[2] += (100 - color.values[2]) * coefficient;\n } else if (color.type.indexOf('rgb') !== -1) {\n for (let i = 0; i < 3; i += 1) {\n color.values[i] += (255 - color.values[i]) * coefficient;\n }\n } else if (color.type.indexOf('color') !== -1) {\n for (let i = 0; i < 3; i += 1) {\n color.values[i] += (1 - color.values[i]) * coefficient;\n }\n }\n return recomposeColor(color);\n}\nexport function private_safeLighten(color, coefficient, warning) {\n try {\n return lighten(color, coefficient);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Darken or lighten a color, depending on its luminance.\n * Light colors are darkened, dark colors are lightened.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} coefficient=0.15 - multiplier in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function emphasize(color, coefficient = 0.15) {\n return getLuminance(color) > 0.5 ? darken(color, coefficient) : lighten(color, coefficient);\n}\nexport function private_safeEmphasize(color, coefficient, warning) {\n try {\n return emphasize(color, coefficient);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Blend a transparent overlay color with a background color, resulting in a single\n * RGB color.\n * @param {string} background - CSS color\n * @param {string} overlay - CSS color\n * @param {number} opacity - Opacity multiplier in the range 0 - 1\n * @param {number} [gamma=1.0] - Gamma correction factor. For gamma-correct blending, 2.2 is usual.\n */\nexport function blend(background, overlay, opacity, gamma = 1.0) {\n const blendChannel = (b, o) => Math.round((b ** (1 / gamma) * (1 - opacity) + o ** (1 / gamma) * opacity) ** gamma);\n const backgroundColor = decomposeColor(background);\n const overlayColor = decomposeColor(overlay);\n const rgb = [blendChannel(backgroundColor.values[0], overlayColor.values[0]), blendChannel(backgroundColor.values[1], overlayColor.values[1]), blendChannel(backgroundColor.values[2], overlayColor.values[2])];\n return recomposeColor({\n type: 'rgb',\n values: rgb\n });\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nexport default function createMixins(breakpoints, mixins) {\n return _extends({\n toolbar: {\n minHeight: 56,\n [breakpoints.up('xs')]: {\n '@media (orientation: landscape)': {\n minHeight: 48\n }\n },\n [breakpoints.up('sm')]: {\n minHeight: 64\n }\n }\n }, mixins);\n}","const common = {\n black: '#000',\n white: '#fff'\n};\nexport default common;","const grey = {\n 50: '#fafafa',\n 100: '#f5f5f5',\n 200: '#eeeeee',\n 300: '#e0e0e0',\n 400: '#bdbdbd',\n 500: '#9e9e9e',\n 600: '#757575',\n 700: '#616161',\n 800: '#424242',\n 900: '#212121',\n A100: '#f5f5f5',\n A200: '#eeeeee',\n A400: '#bdbdbd',\n A700: '#616161'\n};\nexport default grey;","const purple = {\n 50: '#f3e5f5',\n 100: '#e1bee7',\n 200: '#ce93d8',\n 300: '#ba68c8',\n 400: '#ab47bc',\n 500: '#9c27b0',\n 600: '#8e24aa',\n 700: '#7b1fa2',\n 800: '#6a1b9a',\n 900: '#4a148c',\n A100: '#ea80fc',\n A200: '#e040fb',\n A400: '#d500f9',\n A700: '#aa00ff'\n};\nexport default purple;","const red = {\n 50: '#ffebee',\n 100: '#ffcdd2',\n 200: '#ef9a9a',\n 300: '#e57373',\n 400: '#ef5350',\n 500: '#f44336',\n 600: '#e53935',\n 700: '#d32f2f',\n 800: '#c62828',\n 900: '#b71c1c',\n A100: '#ff8a80',\n A200: '#ff5252',\n A400: '#ff1744',\n A700: '#d50000'\n};\nexport default red;","const orange = {\n 50: '#fff3e0',\n 100: '#ffe0b2',\n 200: '#ffcc80',\n 300: '#ffb74d',\n 400: '#ffa726',\n 500: '#ff9800',\n 600: '#fb8c00',\n 700: '#f57c00',\n 800: '#ef6c00',\n 900: '#e65100',\n A100: '#ffd180',\n A200: '#ffab40',\n A400: '#ff9100',\n A700: '#ff6d00'\n};\nexport default orange;","const blue = {\n 50: '#e3f2fd',\n 100: '#bbdefb',\n 200: '#90caf9',\n 300: '#64b5f6',\n 400: '#42a5f5',\n 500: '#2196f3',\n 600: '#1e88e5',\n 700: '#1976d2',\n 800: '#1565c0',\n 900: '#0d47a1',\n A100: '#82b1ff',\n A200: '#448aff',\n A400: '#2979ff',\n A700: '#2962ff'\n};\nexport default blue;","const lightBlue = {\n 50: '#e1f5fe',\n 100: '#b3e5fc',\n 200: '#81d4fa',\n 300: '#4fc3f7',\n 400: '#29b6f6',\n 500: '#03a9f4',\n 600: '#039be5',\n 700: '#0288d1',\n 800: '#0277bd',\n 900: '#01579b',\n A100: '#80d8ff',\n A200: '#40c4ff',\n A400: '#00b0ff',\n A700: '#0091ea'\n};\nexport default lightBlue;","const green = {\n 50: '#e8f5e9',\n 100: '#c8e6c9',\n 200: '#a5d6a7',\n 300: '#81c784',\n 400: '#66bb6a',\n 500: '#4caf50',\n 600: '#43a047',\n 700: '#388e3c',\n 800: '#2e7d32',\n 900: '#1b5e20',\n A100: '#b9f6ca',\n A200: '#69f0ae',\n A400: '#00e676',\n A700: '#00c853'\n};\nexport default green;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\nconst _excluded = [\"mode\", \"contrastThreshold\", \"tonalOffset\"];\nimport { deepmerge } from '@mui/utils';\nimport { darken, getContrastRatio, lighten } from '@mui/system';\nimport common from '../colors/common';\nimport grey from '../colors/grey';\nimport purple from '../colors/purple';\nimport red from '../colors/red';\nimport orange from '../colors/orange';\nimport blue from '../colors/blue';\nimport lightBlue from '../colors/lightBlue';\nimport green from '../colors/green';\nexport const light = {\n // The colors used to style the text.\n text: {\n // The most important text.\n primary: 'rgba(0, 0, 0, 0.87)',\n // Secondary text.\n secondary: 'rgba(0, 0, 0, 0.6)',\n // Disabled text have even lower visual prominence.\n disabled: 'rgba(0, 0, 0, 0.38)'\n },\n // The color used to divide different elements.\n divider: 'rgba(0, 0, 0, 0.12)',\n // The background colors used to style the surfaces.\n // Consistency between these values is important.\n background: {\n paper: common.white,\n default: common.white\n },\n // The colors used to style the action elements.\n action: {\n // The color of an active action like an icon button.\n active: 'rgba(0, 0, 0, 0.54)',\n // The color of an hovered action.\n hover: 'rgba(0, 0, 0, 0.04)',\n hoverOpacity: 0.04,\n // The color of a selected action.\n selected: 'rgba(0, 0, 0, 0.08)',\n selectedOpacity: 0.08,\n // The color of a disabled action.\n disabled: 'rgba(0, 0, 0, 0.26)',\n // The background color of a disabled action.\n disabledBackground: 'rgba(0, 0, 0, 0.12)',\n disabledOpacity: 0.38,\n focus: 'rgba(0, 0, 0, 0.12)',\n focusOpacity: 0.12,\n activatedOpacity: 0.12\n }\n};\nexport const dark = {\n text: {\n primary: common.white,\n secondary: 'rgba(255, 255, 255, 0.7)',\n disabled: 'rgba(255, 255, 255, 0.5)',\n icon: 'rgba(255, 255, 255, 0.5)'\n },\n divider: 'rgba(255, 255, 255, 0.12)',\n background: {\n paper: '#121212',\n default: '#121212'\n },\n action: {\n active: common.white,\n hover: 'rgba(255, 255, 255, 0.08)',\n hoverOpacity: 0.08,\n selected: 'rgba(255, 255, 255, 0.16)',\n selectedOpacity: 0.16,\n disabled: 'rgba(255, 255, 255, 0.3)',\n disabledBackground: 'rgba(255, 255, 255, 0.12)',\n disabledOpacity: 0.38,\n focus: 'rgba(255, 255, 255, 0.12)',\n focusOpacity: 0.12,\n activatedOpacity: 0.24\n }\n};\nfunction addLightOrDark(intent, direction, shade, tonalOffset) {\n const tonalOffsetLight = tonalOffset.light || tonalOffset;\n const tonalOffsetDark = tonalOffset.dark || tonalOffset * 1.5;\n if (!intent[direction]) {\n if (intent.hasOwnProperty(shade)) {\n intent[direction] = intent[shade];\n } else if (direction === 'light') {\n intent.light = lighten(intent.main, tonalOffsetLight);\n } else if (direction === 'dark') {\n intent.dark = darken(intent.main, tonalOffsetDark);\n }\n }\n}\nfunction getDefaultPrimary(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: blue[200],\n light: blue[50],\n dark: blue[400]\n };\n }\n return {\n main: blue[700],\n light: blue[400],\n dark: blue[800]\n };\n}\nfunction getDefaultSecondary(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: purple[200],\n light: purple[50],\n dark: purple[400]\n };\n }\n return {\n main: purple[500],\n light: purple[300],\n dark: purple[700]\n };\n}\nfunction getDefaultError(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: red[500],\n light: red[300],\n dark: red[700]\n };\n }\n return {\n main: red[700],\n light: red[400],\n dark: red[800]\n };\n}\nfunction getDefaultInfo(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: lightBlue[400],\n light: lightBlue[300],\n dark: lightBlue[700]\n };\n }\n return {\n main: lightBlue[700],\n light: lightBlue[500],\n dark: lightBlue[900]\n };\n}\nfunction getDefaultSuccess(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: green[400],\n light: green[300],\n dark: green[700]\n };\n }\n return {\n main: green[800],\n light: green[500],\n dark: green[900]\n };\n}\nfunction getDefaultWarning(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: orange[400],\n light: orange[300],\n dark: orange[700]\n };\n }\n return {\n main: '#ed6c02',\n // closest to orange[800] that pass 3:1.\n light: orange[500],\n dark: orange[900]\n };\n}\nexport default function createPalette(palette) {\n const {\n mode = 'light',\n contrastThreshold = 3,\n tonalOffset = 0.2\n } = palette,\n other = _objectWithoutPropertiesLoose(palette, _excluded);\n const primary = palette.primary || getDefaultPrimary(mode);\n const secondary = palette.secondary || getDefaultSecondary(mode);\n const error = palette.error || getDefaultError(mode);\n const info = palette.info || getDefaultInfo(mode);\n const success = palette.success || getDefaultSuccess(mode);\n const warning = palette.warning || getDefaultWarning(mode);\n\n // Use the same logic as\n // Bootstrap: https://github.com/twbs/bootstrap/blob/1d6e3710dd447de1a200f29e8fa521f8a0908f70/scss/_functions.scss#L59\n // and material-components-web https://github.com/material-components/material-components-web/blob/ac46b8863c4dab9fc22c4c662dc6bd1b65dd652f/packages/mdc-theme/_functions.scss#L54\n function getContrastText(background) {\n const contrastText = getContrastRatio(background, dark.text.primary) >= contrastThreshold ? dark.text.primary : light.text.primary;\n if (process.env.NODE_ENV !== 'production') {\n const contrast = getContrastRatio(background, contrastText);\n if (contrast < 3) {\n console.error([`MUI: The contrast ratio of ${contrast}:1 for ${contrastText} on ${background}`, 'falls below the WCAG recommended absolute minimum contrast ratio of 3:1.', 'https://www.w3.org/TR/2008/REC-WCAG20-20081211/#visual-audio-contrast-contrast'].join('\\n'));\n }\n }\n return contrastText;\n }\n const augmentColor = ({\n color,\n name,\n mainShade = 500,\n lightShade = 300,\n darkShade = 700\n }) => {\n color = _extends({}, color);\n if (!color.main && color[mainShade]) {\n color.main = color[mainShade];\n }\n if (!color.hasOwnProperty('main')) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: The color${name ? ` (${name})` : ''} provided to augmentColor(color) is invalid.\nThe color object needs to have a \\`main\\` property or a \\`${mainShade}\\` property.` : _formatMuiErrorMessage(11, name ? ` (${name})` : '', mainShade));\n }\n if (typeof color.main !== 'string') {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: The color${name ? ` (${name})` : ''} provided to augmentColor(color) is invalid.\n\\`color.main\\` should be a string, but \\`${JSON.stringify(color.main)}\\` was provided instead.\n\nDid you intend to use one of the following approaches?\n\nimport { green } from \"@mui/material/colors\";\n\nconst theme1 = createTheme({ palette: {\n primary: green,\n} });\n\nconst theme2 = createTheme({ palette: {\n primary: { main: green[500] },\n} });` : _formatMuiErrorMessage(12, name ? ` (${name})` : '', JSON.stringify(color.main)));\n }\n addLightOrDark(color, 'light', lightShade, tonalOffset);\n addLightOrDark(color, 'dark', darkShade, tonalOffset);\n if (!color.contrastText) {\n color.contrastText = getContrastText(color.main);\n }\n return color;\n };\n const modes = {\n dark,\n light\n };\n if (process.env.NODE_ENV !== 'production') {\n if (!modes[mode]) {\n console.error(`MUI: The palette mode \\`${mode}\\` is not supported.`);\n }\n }\n const paletteOutput = deepmerge(_extends({\n // A collection of common colors.\n common: _extends({}, common),\n // prevent mutable object.\n // The palette mode, can be light or dark.\n mode,\n // The colors used to represent primary interface elements for a user.\n primary: augmentColor({\n color: primary,\n name: 'primary'\n }),\n // The colors used to represent secondary interface elements for a user.\n secondary: augmentColor({\n color: secondary,\n name: 'secondary',\n mainShade: 'A400',\n lightShade: 'A200',\n darkShade: 'A700'\n }),\n // The colors used to represent interface elements that the user should be made aware of.\n error: augmentColor({\n color: error,\n name: 'error'\n }),\n // The colors used to represent potentially dangerous actions or important messages.\n warning: augmentColor({\n color: warning,\n name: 'warning'\n }),\n // The colors used to present information to the user that is neutral and not necessarily important.\n info: augmentColor({\n color: info,\n name: 'info'\n }),\n // The colors used to indicate the successful completion of an action that user triggered.\n success: augmentColor({\n color: success,\n name: 'success'\n }),\n // The grey colors.\n grey,\n // Used by `getContrastText()` to maximize the contrast between\n // the background and the text.\n contrastThreshold,\n // Takes a background color and returns the text color that maximizes the contrast.\n getContrastText,\n // Generate a rich color object.\n augmentColor,\n // Used by the functions below to shift a color's luminance by approximately\n // two indexes within its tonal palette.\n // E.g., shift from Red 500 to Red 300 or Red 700.\n tonalOffset\n }, modes[mode]), other);\n return paletteOutput;\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"fontFamily\", \"fontSize\", \"fontWeightLight\", \"fontWeightRegular\", \"fontWeightMedium\", \"fontWeightBold\", \"htmlFontSize\", \"allVariants\", \"pxToRem\"];\nimport { deepmerge } from '@mui/utils';\nfunction round(value) {\n return Math.round(value * 1e5) / 1e5;\n}\nconst caseAllCaps = {\n textTransform: 'uppercase'\n};\nconst defaultFontFamily = '\"Roboto\", \"Helvetica\", \"Arial\", sans-serif';\n\n/**\n * @see @link{https://m2.material.io/design/typography/the-type-system.html}\n * @see @link{https://m2.material.io/design/typography/understanding-typography.html}\n */\nexport default function createTypography(palette, typography) {\n const _ref = typeof typography === 'function' ? typography(palette) : typography,\n {\n fontFamily = defaultFontFamily,\n // The default font size of the Material Specification.\n fontSize = 14,\n // px\n fontWeightLight = 300,\n fontWeightRegular = 400,\n fontWeightMedium = 500,\n fontWeightBold = 700,\n // Tell MUI what's the font-size on the html element.\n // 16px is the default font-size used by browsers.\n htmlFontSize = 16,\n // Apply the CSS properties to all the variants.\n allVariants,\n pxToRem: pxToRem2\n } = _ref,\n other = _objectWithoutPropertiesLoose(_ref, _excluded);\n if (process.env.NODE_ENV !== 'production') {\n if (typeof fontSize !== 'number') {\n console.error('MUI: `fontSize` is required to be a number.');\n }\n if (typeof htmlFontSize !== 'number') {\n console.error('MUI: `htmlFontSize` is required to be a number.');\n }\n }\n const coef = fontSize / 14;\n const pxToRem = pxToRem2 || (size => `${size / htmlFontSize * coef}rem`);\n const buildVariant = (fontWeight, size, lineHeight, letterSpacing, casing) => _extends({\n fontFamily,\n fontWeight,\n fontSize: pxToRem(size),\n // Unitless following https://meyerweb.com/eric/thoughts/2006/02/08/unitless-line-heights/\n lineHeight\n }, fontFamily === defaultFontFamily ? {\n letterSpacing: `${round(letterSpacing / size)}em`\n } : {}, casing, allVariants);\n const variants = {\n h1: buildVariant(fontWeightLight, 96, 1.167, -1.5),\n h2: buildVariant(fontWeightLight, 60, 1.2, -0.5),\n h3: buildVariant(fontWeightRegular, 48, 1.167, 0),\n h4: buildVariant(fontWeightRegular, 34, 1.235, 0.25),\n h5: buildVariant(fontWeightRegular, 24, 1.334, 0),\n h6: buildVariant(fontWeightMedium, 20, 1.6, 0.15),\n subtitle1: buildVariant(fontWeightRegular, 16, 1.75, 0.15),\n subtitle2: buildVariant(fontWeightMedium, 14, 1.57, 0.1),\n body1: buildVariant(fontWeightRegular, 16, 1.5, 0.15),\n body2: buildVariant(fontWeightRegular, 14, 1.43, 0.15),\n button: buildVariant(fontWeightMedium, 14, 1.75, 0.4, caseAllCaps),\n caption: buildVariant(fontWeightRegular, 12, 1.66, 0.4),\n overline: buildVariant(fontWeightRegular, 12, 2.66, 1, caseAllCaps),\n // TODO v6: Remove handling of 'inherit' variant from the theme as it is already handled in Material UI's Typography component. Also, remember to remove the associated types.\n inherit: {\n fontFamily: 'inherit',\n fontWeight: 'inherit',\n fontSize: 'inherit',\n lineHeight: 'inherit',\n letterSpacing: 'inherit'\n }\n };\n return deepmerge(_extends({\n htmlFontSize,\n pxToRem,\n fontFamily,\n fontSize,\n fontWeightLight,\n fontWeightRegular,\n fontWeightMedium,\n fontWeightBold\n }, variants), other, {\n clone: false // No need to clone deep\n });\n}","const shadowKeyUmbraOpacity = 0.2;\nconst shadowKeyPenumbraOpacity = 0.14;\nconst shadowAmbientShadowOpacity = 0.12;\nfunction createShadow(...px) {\n return [`${px[0]}px ${px[1]}px ${px[2]}px ${px[3]}px rgba(0,0,0,${shadowKeyUmbraOpacity})`, `${px[4]}px ${px[5]}px ${px[6]}px ${px[7]}px rgba(0,0,0,${shadowKeyPenumbraOpacity})`, `${px[8]}px ${px[9]}px ${px[10]}px ${px[11]}px rgba(0,0,0,${shadowAmbientShadowOpacity})`].join(',');\n}\n\n// Values from https://github.com/material-components/material-components-web/blob/be8747f94574669cb5e7add1a7c54fa41a89cec7/packages/mdc-elevation/_variables.scss\nconst shadows = ['none', createShadow(0, 2, 1, -1, 0, 1, 1, 0, 0, 1, 3, 0), createShadow(0, 3, 1, -2, 0, 2, 2, 0, 0, 1, 5, 0), createShadow(0, 3, 3, -2, 0, 3, 4, 0, 0, 1, 8, 0), createShadow(0, 2, 4, -1, 0, 4, 5, 0, 0, 1, 10, 0), createShadow(0, 3, 5, -1, 0, 5, 8, 0, 0, 1, 14, 0), createShadow(0, 3, 5, -1, 0, 6, 10, 0, 0, 1, 18, 0), createShadow(0, 4, 5, -2, 0, 7, 10, 1, 0, 2, 16, 1), createShadow(0, 5, 5, -3, 0, 8, 10, 1, 0, 3, 14, 2), createShadow(0, 5, 6, -3, 0, 9, 12, 1, 0, 3, 16, 2), createShadow(0, 6, 6, -3, 0, 10, 14, 1, 0, 4, 18, 3), createShadow(0, 6, 7, -4, 0, 11, 15, 1, 0, 4, 20, 3), createShadow(0, 7, 8, -4, 0, 12, 17, 2, 0, 5, 22, 4), createShadow(0, 7, 8, -4, 0, 13, 19, 2, 0, 5, 24, 4), createShadow(0, 7, 9, -4, 0, 14, 21, 2, 0, 5, 26, 4), createShadow(0, 8, 9, -5, 0, 15, 22, 2, 0, 6, 28, 5), createShadow(0, 8, 10, -5, 0, 16, 24, 2, 0, 6, 30, 5), createShadow(0, 8, 11, -5, 0, 17, 26, 2, 0, 6, 32, 5), createShadow(0, 9, 11, -5, 0, 18, 28, 2, 0, 7, 34, 6), createShadow(0, 9, 12, -6, 0, 19, 29, 2, 0, 7, 36, 6), createShadow(0, 10, 13, -6, 0, 20, 31, 3, 0, 8, 38, 7), createShadow(0, 10, 13, -6, 0, 21, 33, 3, 0, 8, 40, 7), createShadow(0, 10, 14, -6, 0, 22, 35, 3, 0, 8, 42, 7), createShadow(0, 11, 14, -7, 0, 23, 36, 3, 0, 9, 44, 8), createShadow(0, 11, 15, -7, 0, 24, 38, 3, 0, 9, 46, 8)];\nexport default shadows;","import _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nconst _excluded = [\"duration\", \"easing\", \"delay\"];\n// Follow https://material.google.com/motion/duration-easing.html#duration-easing-natural-easing-curves\n// to learn the context in which each easing should be used.\nexport const easing = {\n // This is the most common easing curve.\n easeInOut: 'cubic-bezier(0.4, 0, 0.2, 1)',\n // Objects enter the screen at full velocity from off-screen and\n // slowly decelerate to a resting point.\n easeOut: 'cubic-bezier(0.0, 0, 0.2, 1)',\n // Objects leave the screen at full velocity. They do not decelerate when off-screen.\n easeIn: 'cubic-bezier(0.4, 0, 1, 1)',\n // The sharp curve is used by objects that may return to the screen at any time.\n sharp: 'cubic-bezier(0.4, 0, 0.6, 1)'\n};\n\n// Follow https://m2.material.io/guidelines/motion/duration-easing.html#duration-easing-common-durations\n// to learn when use what timing\nexport const duration = {\n shortest: 150,\n shorter: 200,\n short: 250,\n // most basic recommended timing\n standard: 300,\n // this is to be used in complex animations\n complex: 375,\n // recommended when something is entering screen\n enteringScreen: 225,\n // recommended when something is leaving screen\n leavingScreen: 195\n};\nfunction formatMs(milliseconds) {\n return `${Math.round(milliseconds)}ms`;\n}\nfunction getAutoHeightDuration(height) {\n if (!height) {\n return 0;\n }\n const constant = height / 36;\n\n // https://www.wolframalpha.com/input/?i=(4+%2B+15+*+(x+%2F+36+)+**+0.25+%2B+(x+%2F+36)+%2F+5)+*+10\n return Math.round((4 + 15 * constant ** 0.25 + constant / 5) * 10);\n}\nexport default function createTransitions(inputTransitions) {\n const mergedEasing = _extends({}, easing, inputTransitions.easing);\n const mergedDuration = _extends({}, duration, inputTransitions.duration);\n const create = (props = ['all'], options = {}) => {\n const {\n duration: durationOption = mergedDuration.standard,\n easing: easingOption = mergedEasing.easeInOut,\n delay = 0\n } = options,\n other = _objectWithoutPropertiesLoose(options, _excluded);\n if (process.env.NODE_ENV !== 'production') {\n const isString = value => typeof value === 'string';\n // IE11 support, replace with Number.isNaN\n // eslint-disable-next-line no-restricted-globals\n const isNumber = value => !isNaN(parseFloat(value));\n if (!isString(props) && !Array.isArray(props)) {\n console.error('MUI: Argument \"props\" must be a string or Array.');\n }\n if (!isNumber(durationOption) && !isString(durationOption)) {\n console.error(`MUI: Argument \"duration\" must be a number or a string but found ${durationOption}.`);\n }\n if (!isString(easingOption)) {\n console.error('MUI: Argument \"easing\" must be a string.');\n }\n if (!isNumber(delay) && !isString(delay)) {\n console.error('MUI: Argument \"delay\" must be a number or a string.');\n }\n if (typeof options !== 'object') {\n console.error(['MUI: Secong argument of transition.create must be an object.', \"Arguments should be either `create('prop1', options)` or `create(['prop1', 'prop2'], options)`\"].join('\\n'));\n }\n if (Object.keys(other).length !== 0) {\n console.error(`MUI: Unrecognized argument(s) [${Object.keys(other).join(',')}].`);\n }\n }\n return (Array.isArray(props) ? props : [props]).map(animatedProp => `${animatedProp} ${typeof durationOption === 'string' ? durationOption : formatMs(durationOption)} ${easingOption} ${typeof delay === 'string' ? delay : formatMs(delay)}`).join(',');\n };\n return _extends({\n getAutoHeightDuration,\n create\n }, inputTransitions, {\n easing: mergedEasing,\n duration: mergedDuration\n });\n}","// We need to centralize the zIndex definitions as they work\n// like global values in the browser.\nconst zIndex = {\n mobileStepper: 1000,\n fab: 1050,\n speedDial: 1050,\n appBar: 1100,\n drawer: 1200,\n modal: 1300,\n snackbar: 1400,\n tooltip: 1500\n};\nexport default zIndex;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\nconst _excluded = [\"breakpoints\", \"mixins\", \"spacing\", \"palette\", \"transitions\", \"typography\", \"shape\"];\nimport { deepmerge } from '@mui/utils';\nimport { createTheme as systemCreateTheme, unstable_defaultSxConfig as defaultSxConfig, unstable_styleFunctionSx as styleFunctionSx } from '@mui/system';\nimport generateUtilityClass from '@mui/utils/generateUtilityClass';\nimport createMixins from './createMixins';\nimport createPalette from './createPalette';\nimport createTypography from './createTypography';\nimport shadows from './shadows';\nimport createTransitions from './createTransitions';\nimport zIndex from './zIndex';\nfunction createTheme(options = {}, ...args) {\n const {\n mixins: mixinsInput = {},\n palette: paletteInput = {},\n transitions: transitionsInput = {},\n typography: typographyInput = {}\n } = options,\n other = _objectWithoutPropertiesLoose(options, _excluded);\n if (options.vars) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: \\`vars\\` is a private field used for CSS variables support.\nPlease use another name.` : _formatMuiErrorMessage(18));\n }\n const palette = createPalette(paletteInput);\n const systemTheme = systemCreateTheme(options);\n let muiTheme = deepmerge(systemTheme, {\n mixins: createMixins(systemTheme.breakpoints, mixinsInput),\n palette,\n // Don't use [...shadows] until you've verified its transpiled code is not invoking the iterator protocol.\n shadows: shadows.slice(),\n typography: createTypography(palette, typographyInput),\n transitions: createTransitions(transitionsInput),\n zIndex: _extends({}, zIndex)\n });\n muiTheme = deepmerge(muiTheme, other);\n muiTheme = args.reduce((acc, argument) => deepmerge(acc, argument), muiTheme);\n if (process.env.NODE_ENV !== 'production') {\n // TODO v6: Refactor to use globalStateClassesMapping from @mui/utils once `readOnly` state class is used in Rating component.\n const stateClasses = ['active', 'checked', 'completed', 'disabled', 'error', 'expanded', 'focused', 'focusVisible', 'required', 'selected'];\n const traverse = (node, component) => {\n let key;\n\n // eslint-disable-next-line guard-for-in, no-restricted-syntax\n for (key in node) {\n const child = node[key];\n if (stateClasses.indexOf(key) !== -1 && Object.keys(child).length > 0) {\n if (process.env.NODE_ENV !== 'production') {\n const stateClass = generateUtilityClass('', key);\n console.error([`MUI: The \\`${component}\\` component increases ` + `the CSS specificity of the \\`${key}\\` internal state.`, 'You can not override it like this: ', JSON.stringify(node, null, 2), '', `Instead, you need to use the '&.${stateClass}' syntax:`, JSON.stringify({\n root: {\n [`&.${stateClass}`]: child\n }\n }, null, 2), '', 'https://mui.com/r/state-classes-guide'].join('\\n'));\n }\n // Remove the style to prevent global conflicts.\n node[key] = {};\n }\n }\n };\n Object.keys(muiTheme.components).forEach(component => {\n const styleOverrides = muiTheme.components[component].styleOverrides;\n if (styleOverrides && component.indexOf('Mui') === 0) {\n traverse(styleOverrides, component);\n }\n });\n }\n muiTheme.unstable_sxConfig = _extends({}, defaultSxConfig, other == null ? void 0 : other.unstable_sxConfig);\n muiTheme.unstable_sx = function sx(props) {\n return styleFunctionSx({\n sx: props,\n theme: this\n });\n };\n return muiTheme;\n}\nlet warnedOnce = false;\nexport function createMuiTheme(...args) {\n if (process.env.NODE_ENV !== 'production') {\n if (!warnedOnce) {\n warnedOnce = true;\n console.error(['MUI: the createMuiTheme function was renamed to createTheme.', '', \"You should use `import { createTheme } from '@mui/material/styles'`\"].join('\\n'));\n }\n }\n return createTheme(...args);\n}\nexport default createTheme;","'use client';\n\nimport createTheme from './createTheme';\nconst defaultTheme = createTheme();\nexport default defaultTheme;","export default '$$material';","'use client';\n\nimport { useThemeProps as systemUseThemeProps } from '@mui/system';\nimport defaultTheme from './defaultTheme';\nimport THEME_ID from './identifier';\nexport default function useThemeProps({\n props,\n name\n}) {\n return systemUseThemeProps({\n props,\n name,\n defaultTheme,\n themeId: THEME_ID\n });\n}","'use client';\n\nimport { createStyled, shouldForwardProp } from '@mui/system';\nimport defaultTheme from './defaultTheme';\nimport THEME_ID from './identifier';\nexport const rootShouldForwardProp = prop => shouldForwardProp(prop) && prop !== 'classes';\nexport const slotShouldForwardProp = shouldForwardProp;\nconst styled = createStyled({\n themeId: THEME_ID,\n defaultTheme,\n rootShouldForwardProp\n});\nexport default styled;","import generateUtilityClasses from '@mui/utils/generateUtilityClasses';\nimport generateUtilityClass from '@mui/utils/generateUtilityClass';\nexport function getSvgIconUtilityClass(slot) {\n return generateUtilityClass('MuiSvgIcon', slot);\n}\nconst svgIconClasses = generateUtilityClasses('MuiSvgIcon', ['root', 'colorPrimary', 'colorSecondary', 'colorAction', 'colorError', 'colorDisabled', 'fontSizeInherit', 'fontSizeSmall', 'fontSizeMedium', 'fontSizeLarge']);\nexport default svgIconClasses;","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"children\", \"className\", \"color\", \"component\", \"fontSize\", \"htmlColor\", \"inheritViewBox\", \"titleAccess\", \"viewBox\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport clsx from 'clsx';\nimport { unstable_composeClasses as composeClasses } from '@mui/base/composeClasses';\nimport capitalize from '../utils/capitalize';\nimport useThemeProps from '../styles/useThemeProps';\nimport styled from '../styles/styled';\nimport { getSvgIconUtilityClass } from './svgIconClasses';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nimport { jsxs as _jsxs } from \"react/jsx-runtime\";\nconst useUtilityClasses = ownerState => {\n const {\n color,\n fontSize,\n classes\n } = ownerState;\n const slots = {\n root: ['root', color !== 'inherit' && `color${capitalize(color)}`, `fontSize${capitalize(fontSize)}`]\n };\n return composeClasses(slots, getSvgIconUtilityClass, classes);\n};\nconst SvgIconRoot = styled('svg', {\n name: 'MuiSvgIcon',\n slot: 'Root',\n overridesResolver: (props, styles) => {\n const {\n ownerState\n } = props;\n return [styles.root, ownerState.color !== 'inherit' && styles[`color${capitalize(ownerState.color)}`], styles[`fontSize${capitalize(ownerState.fontSize)}`]];\n }\n})(({\n theme,\n ownerState\n}) => {\n var _theme$transitions, _theme$transitions$cr, _theme$transitions2, _theme$typography, _theme$typography$pxT, _theme$typography2, _theme$typography2$px, _theme$typography3, _theme$typography3$px, _palette$ownerState$c, _palette, _palette2, _palette3;\n return {\n userSelect: 'none',\n width: '1em',\n height: '1em',\n display: 'inline-block',\n // the will define the property that has `currentColor`\n // e.g. heroicons uses fill=\"none\" and stroke=\"currentColor\"\n fill: ownerState.hasSvgAsChild ? undefined : 'currentColor',\n flexShrink: 0,\n transition: (_theme$transitions = theme.transitions) == null || (_theme$transitions$cr = _theme$transitions.create) == null ? void 0 : _theme$transitions$cr.call(_theme$transitions, 'fill', {\n duration: (_theme$transitions2 = theme.transitions) == null || (_theme$transitions2 = _theme$transitions2.duration) == null ? void 0 : _theme$transitions2.shorter\n }),\n fontSize: {\n inherit: 'inherit',\n small: ((_theme$typography = theme.typography) == null || (_theme$typography$pxT = _theme$typography.pxToRem) == null ? void 0 : _theme$typography$pxT.call(_theme$typography, 20)) || '1.25rem',\n medium: ((_theme$typography2 = theme.typography) == null || (_theme$typography2$px = _theme$typography2.pxToRem) == null ? void 0 : _theme$typography2$px.call(_theme$typography2, 24)) || '1.5rem',\n large: ((_theme$typography3 = theme.typography) == null || (_theme$typography3$px = _theme$typography3.pxToRem) == null ? void 0 : _theme$typography3$px.call(_theme$typography3, 35)) || '2.1875rem'\n }[ownerState.fontSize],\n // TODO v5 deprecate, v6 remove for sx\n color: (_palette$ownerState$c = (_palette = (theme.vars || theme).palette) == null || (_palette = _palette[ownerState.color]) == null ? void 0 : _palette.main) != null ? _palette$ownerState$c : {\n action: (_palette2 = (theme.vars || theme).palette) == null || (_palette2 = _palette2.action) == null ? void 0 : _palette2.active,\n disabled: (_palette3 = (theme.vars || theme).palette) == null || (_palette3 = _palette3.action) == null ? void 0 : _palette3.disabled,\n inherit: undefined\n }[ownerState.color]\n };\n});\nconst SvgIcon = /*#__PURE__*/React.forwardRef(function SvgIcon(inProps, ref) {\n const props = useThemeProps({\n props: inProps,\n name: 'MuiSvgIcon'\n });\n const {\n children,\n className,\n color = 'inherit',\n component = 'svg',\n fontSize = 'medium',\n htmlColor,\n inheritViewBox = false,\n titleAccess,\n viewBox = '0 0 24 24'\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const hasSvgAsChild = /*#__PURE__*/React.isValidElement(children) && children.type === 'svg';\n const ownerState = _extends({}, props, {\n color,\n component,\n fontSize,\n instanceFontSize: inProps.fontSize,\n inheritViewBox,\n viewBox,\n hasSvgAsChild\n });\n const more = {};\n if (!inheritViewBox) {\n more.viewBox = viewBox;\n }\n const classes = useUtilityClasses(ownerState);\n return /*#__PURE__*/_jsxs(SvgIconRoot, _extends({\n as: component,\n className: clsx(classes.root, className),\n focusable: \"false\",\n color: htmlColor,\n \"aria-hidden\": titleAccess ? undefined : true,\n role: titleAccess ? 'img' : undefined,\n ref: ref\n }, more, other, hasSvgAsChild && children.props, {\n ownerState: ownerState,\n children: [hasSvgAsChild ? children.props.children : children, titleAccess ? /*#__PURE__*/_jsx(\"title\", {\n children: titleAccess\n }) : null]\n }));\n});\nprocess.env.NODE_ENV !== \"production\" ? SvgIcon.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the d.ts file and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * Node passed into the SVG element.\n */\n children: PropTypes.node,\n /**\n * Override or extend the styles applied to the component.\n */\n classes: PropTypes.object,\n /**\n * @ignore\n */\n className: PropTypes.string,\n /**\n * The color of the component.\n * It supports both default and custom theme colors, which can be added as shown in the\n * [palette customization guide](https://mui.com/material-ui/customization/palette/#custom-colors).\n * You can use the `htmlColor` prop to apply a color attribute to the SVG element.\n * @default 'inherit'\n */\n color: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.oneOf(['inherit', 'action', 'disabled', 'primary', 'secondary', 'error', 'info', 'success', 'warning']), PropTypes.string]),\n /**\n * The component used for the root node.\n * Either a string to use a HTML element or a component.\n */\n component: PropTypes.elementType,\n /**\n * The fontSize applied to the icon. Defaults to 24px, but can be configure to inherit font size.\n * @default 'medium'\n */\n fontSize: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.oneOf(['inherit', 'large', 'medium', 'small']), PropTypes.string]),\n /**\n * Applies a color attribute to the SVG element.\n */\n htmlColor: PropTypes.string,\n /**\n * If `true`, the root node will inherit the custom `component`'s viewBox and the `viewBox`\n * prop will be ignored.\n * Useful when you want to reference a custom `component` and have `SvgIcon` pass that\n * `component`'s viewBox to the root node.\n * @default false\n */\n inheritViewBox: PropTypes.bool,\n /**\n * The shape-rendering attribute. The behavior of the different options is described on the\n * [MDN Web Docs](https://developer.mozilla.org/en-US/docs/Web/SVG/Attribute/shape-rendering).\n * If you are having issues with blurry icons you should investigate this prop.\n */\n shapeRendering: PropTypes.string,\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Provides a human-readable title for the element that contains it.\n * https://www.w3.org/TR/SVG-access/#Equivalent\n */\n titleAccess: PropTypes.string,\n /**\n * Allows you to redefine what the coordinates without units mean inside an SVG element.\n * For example, if the SVG element is 500 (width) by 200 (height),\n * and you pass viewBox=\"0 0 50 20\",\n * this means that the coordinates inside the SVG will go from the top left corner (0,0)\n * to bottom right (50,20) and each unit will be worth 10px.\n * @default '0 0 24 24'\n */\n viewBox: PropTypes.string\n} : void 0;\nSvgIcon.muiName = 'SvgIcon';\nexport default SvgIcon;","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport * as React from 'react';\nimport SvgIcon from '../SvgIcon';\n\n/**\n * Private module reserved for @mui packages.\n */\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nexport default function createSvgIcon(path, displayName) {\n function Component(props, ref) {\n return /*#__PURE__*/_jsx(SvgIcon, _extends({\n \"data-testid\": `${displayName}Icon`,\n ref: ref\n }, props, {\n children: path\n }));\n }\n if (process.env.NODE_ENV !== 'production') {\n // Need to set `displayName` on the inner component for React.memo.\n // React prior to 16.14 ignores `displayName` on the wrapper.\n Component.displayName = `${displayName}Icon`;\n }\n Component.muiName = SvgIcon.muiName;\n return /*#__PURE__*/React.memo( /*#__PURE__*/React.forwardRef(Component));\n}","'use client';\n\nimport { unstable_ClassNameGenerator as ClassNameGenerator } from '@mui/base/ClassNameGenerator';\nexport { default as capitalize } from './capitalize';\nexport { default as createChainedFunction } from './createChainedFunction';\nexport { default as createSvgIcon } from './createSvgIcon';\nexport { default as debounce } from './debounce';\nexport { default as deprecatedPropType } from './deprecatedPropType';\nexport { default as isMuiElement } from './isMuiElement';\nexport { default as ownerDocument } from './ownerDocument';\nexport { default as ownerWindow } from './ownerWindow';\nexport { default as requirePropFactory } from './requirePropFactory';\nexport { default as setRef } from './setRef';\nexport { default as unstable_useEnhancedEffect } from './useEnhancedEffect';\nexport { default as unstable_useId } from './useId';\nexport { default as unsupportedProp } from './unsupportedProp';\nexport { default as useControlled } from './useControlled';\nexport { default as useEventCallback } from './useEventCallback';\nexport { default as useForkRef } from './useForkRef';\nexport { default as useIsFocusVisible } from './useIsFocusVisible';\n// TODO: remove this export once ClassNameGenerator is stable\n// eslint-disable-next-line @typescript-eslint/naming-convention\nexport const unstable_ClassNameGenerator = {\n configure: generator => {\n if (process.env.NODE_ENV !== 'production') {\n console.warn(['MUI: `ClassNameGenerator` import from `@mui/material/utils` is outdated and might cause unexpected issues.', '', \"You should use `import { unstable_ClassNameGenerator } from '@mui/material/className'` instead\", '', 'The detail of the issue: https://github.com/mui/material-ui/issues/30011#issuecomment-1024993401', '', 'The updated documentation: https://mui.com/guides/classname-generator/'].join('\\n'));\n }\n ClassNameGenerator.configure(generator);\n }\n};","\"use strict\";\n'use client';\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nObject.defineProperty(exports, \"default\", {\n enumerable: true,\n get: function () {\n return _utils.createSvgIcon;\n }\n});\nvar _utils = require(\"@mui/material/utils\");","\"use strict\";\n\"use client\";\n\nvar _interopRequireDefault = require(\"@babel/runtime/helpers/interopRequireDefault\");\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = void 0;\nvar _createSvgIcon = _interopRequireDefault(require(\"./utils/createSvgIcon\"));\nvar _jsxRuntime = require(\"react/jsx-runtime\");\nvar _default = exports.default = (0, _createSvgIcon.default)( /*#__PURE__*/(0, _jsxRuntime.jsx)(\"path\", {\n d: \"m10 17 5-5-5-5z\"\n}), 'ArrowRight');","/**\n * Determines if a given element is a DOM element name (i.e. not a React component).\n */\nexport function isHostComponent(element) {\n return typeof element === 'string';\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport { isHostComponent } from './isHostComponent';\n\n/**\n * Type of the ownerState based on the type of an element it applies to.\n * This resolves to the provided OwnerState for React components and `undefined` for host components.\n * Falls back to `OwnerState | undefined` when the exact type can't be determined in development time.\n */\n\n/**\n * Appends the ownerState object to the props, merging with the existing one if necessary.\n *\n * @param elementType Type of the element that owns the `existingProps`. If the element is a DOM node or undefined, `ownerState` is not applied.\n * @param otherProps Props of the element.\n * @param ownerState\n */\nexport function appendOwnerState(elementType, otherProps, ownerState) {\n if (elementType === undefined || isHostComponent(elementType)) {\n return otherProps;\n }\n return _extends({}, otherProps, {\n ownerState: _extends({}, otherProps.ownerState, ownerState)\n });\n}","'use client';\n\nimport * as React from 'react';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nconst defaultContextValue = {\n disableDefaultClasses: false\n};\nconst ClassNameConfiguratorContext = /*#__PURE__*/React.createContext(defaultContextValue);\n/**\n * @ignore - internal hook.\n *\n * Wraps the `generateUtilityClass` function and controls how the classes are generated.\n * Currently it only affects whether the classes are applied or not.\n *\n * @returns Function to be called with the `generateUtilityClass` function specific to a component to generate the classes.\n */\nexport function useClassNamesOverride(generateUtilityClass) {\n const {\n disableDefaultClasses\n } = React.useContext(ClassNameConfiguratorContext);\n return slot => {\n if (disableDefaultClasses) {\n return '';\n }\n return generateUtilityClass(slot);\n };\n}\n\n/**\n * Allows to configure the components within to not apply any built-in classes.\n */\nexport function ClassNameConfigurator(props) {\n const {\n disableDefaultClasses,\n children\n } = props;\n const contextValue = React.useMemo(() => ({\n disableDefaultClasses: disableDefaultClasses != null ? disableDefaultClasses : false\n }), [disableDefaultClasses]);\n return /*#__PURE__*/_jsx(ClassNameConfiguratorContext.Provider, {\n value: contextValue,\n children: children\n });\n}","/**\n * Extracts event handlers from a given object.\n * A prop is considered an event handler if it is a function and its name starts with `on`.\n *\n * @param object An object to extract event handlers from.\n * @param excludeKeys An array of keys to exclude from the returned object.\n */\nexport function extractEventHandlers(object, excludeKeys = []) {\n if (object === undefined) {\n return {};\n }\n const result = {};\n Object.keys(object).filter(prop => prop.match(/^on[A-Z]/) && typeof object[prop] === 'function' && !excludeKeys.includes(prop)).forEach(prop => {\n result[prop] = object[prop];\n });\n return result;\n}","/**\n * If `componentProps` is a function, calls it with the provided `ownerState`.\n * Otherwise, just returns `componentProps`.\n */\nexport function resolveComponentProps(componentProps, ownerState, slotState) {\n if (typeof componentProps === 'function') {\n return componentProps(ownerState, slotState);\n }\n return componentProps;\n}","/**\n * Removes event handlers from the given object.\n * A field is considered an event handler if it is a function with a name beginning with `on`.\n *\n * @param object Object to remove event handlers from.\n * @returns Object with event handlers removed.\n */\nexport function omitEventHandlers(object) {\n if (object === undefined) {\n return {};\n }\n const result = {};\n Object.keys(object).filter(prop => !(prop.match(/^on[A-Z]/) && typeof object[prop] === 'function')).forEach(prop => {\n result[prop] = object[prop];\n });\n return result;\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport clsx from 'clsx';\nimport { extractEventHandlers } from './extractEventHandlers';\nimport { omitEventHandlers } from './omitEventHandlers';\n/**\n * Merges the slot component internal props (usually coming from a hook)\n * with the externally provided ones.\n *\n * The merge order is (the latter overrides the former):\n * 1. The internal props (specified as a getter function to work with get*Props hook result)\n * 2. Additional props (specified internally on a Base UI component)\n * 3. External props specified on the owner component. These should only be used on a root slot.\n * 4. External props specified in the `slotProps.*` prop.\n * 5. The `className` prop - combined from all the above.\n * @param parameters\n * @returns\n */\nexport function mergeSlotProps(parameters) {\n const {\n getSlotProps,\n additionalProps,\n externalSlotProps,\n externalForwardedProps,\n className\n } = parameters;\n if (!getSlotProps) {\n // The simpler case - getSlotProps is not defined, so no internal event handlers are defined,\n // so we can simply merge all the props without having to worry about extracting event handlers.\n const joinedClasses = clsx(additionalProps == null ? void 0 : additionalProps.className, className, externalForwardedProps == null ? void 0 : externalForwardedProps.className, externalSlotProps == null ? void 0 : externalSlotProps.className);\n const mergedStyle = _extends({}, additionalProps == null ? void 0 : additionalProps.style, externalForwardedProps == null ? void 0 : externalForwardedProps.style, externalSlotProps == null ? void 0 : externalSlotProps.style);\n const props = _extends({}, additionalProps, externalForwardedProps, externalSlotProps);\n if (joinedClasses.length > 0) {\n props.className = joinedClasses;\n }\n if (Object.keys(mergedStyle).length > 0) {\n props.style = mergedStyle;\n }\n return {\n props,\n internalRef: undefined\n };\n }\n\n // In this case, getSlotProps is responsible for calling the external event handlers.\n // We don't need to include them in the merged props because of this.\n\n const eventHandlers = extractEventHandlers(_extends({}, externalForwardedProps, externalSlotProps));\n const componentsPropsWithoutEventHandlers = omitEventHandlers(externalSlotProps);\n const otherPropsWithoutEventHandlers = omitEventHandlers(externalForwardedProps);\n const internalSlotProps = getSlotProps(eventHandlers);\n\n // The order of classes is important here.\n // Emotion (that we use in libraries consuming Base UI) depends on this order\n // to properly override style. It requires the most important classes to be last\n // (see https://github.com/mui/material-ui/pull/33205) for the related discussion.\n const joinedClasses = clsx(internalSlotProps == null ? void 0 : internalSlotProps.className, additionalProps == null ? void 0 : additionalProps.className, className, externalForwardedProps == null ? void 0 : externalForwardedProps.className, externalSlotProps == null ? void 0 : externalSlotProps.className);\n const mergedStyle = _extends({}, internalSlotProps == null ? void 0 : internalSlotProps.style, additionalProps == null ? void 0 : additionalProps.style, externalForwardedProps == null ? void 0 : externalForwardedProps.style, externalSlotProps == null ? void 0 : externalSlotProps.style);\n const props = _extends({}, internalSlotProps, additionalProps, otherPropsWithoutEventHandlers, componentsPropsWithoutEventHandlers);\n if (joinedClasses.length > 0) {\n props.className = joinedClasses;\n }\n if (Object.keys(mergedStyle).length > 0) {\n props.style = mergedStyle;\n }\n return {\n props,\n internalRef: internalSlotProps.ref\n };\n}","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"elementType\", \"externalSlotProps\", \"ownerState\", \"skipResolvingSlotProps\"];\nimport { unstable_useForkRef as useForkRef } from '@mui/utils';\nimport { appendOwnerState } from './appendOwnerState';\nimport { mergeSlotProps } from './mergeSlotProps';\nimport { resolveComponentProps } from './resolveComponentProps';\n/**\n * @ignore - do not document.\n * Builds the props to be passed into the slot of an unstyled component.\n * It merges the internal props of the component with the ones supplied by the user, allowing to customize the behavior.\n * If the slot component is not a host component, it also merges in the `ownerState`.\n *\n * @param parameters.getSlotProps - A function that returns the props to be passed to the slot component.\n */\nexport function useSlotProps(parameters) {\n var _parameters$additiona;\n const {\n elementType,\n externalSlotProps,\n ownerState,\n skipResolvingSlotProps = false\n } = parameters,\n rest = _objectWithoutPropertiesLoose(parameters, _excluded);\n const resolvedComponentsProps = skipResolvingSlotProps ? {} : resolveComponentProps(externalSlotProps, ownerState);\n const {\n props: mergedProps,\n internalRef\n } = mergeSlotProps(_extends({}, rest, {\n externalSlotProps: resolvedComponentsProps\n }));\n const ref = useForkRef(internalRef, resolvedComponentsProps == null ? void 0 : resolvedComponentsProps.ref, (_parameters$additiona = parameters.additionalProps) == null ? void 0 : _parameters$additiona.ref);\n const props = appendOwnerState(elementType, _extends({}, mergedProps, {\n ref\n }), ownerState);\n return props;\n}","import { globalStateClasses } from '@mui/utils/generateUtilityClass';\nconst GLOBAL_CLASS_PREFIX = 'base';\nfunction buildStateClass(state) {\n return `${GLOBAL_CLASS_PREFIX}--${state}`;\n}\nfunction buildSlotClass(componentName, slot) {\n return `${GLOBAL_CLASS_PREFIX}-${componentName}-${slot}`;\n}\nexport function generateUtilityClass(componentName, slot) {\n const globalStateClass = globalStateClasses[slot];\n return globalStateClass ? buildStateClass(globalStateClass) : buildSlotClass(componentName, slot);\n}\nexport function isGlobalState(slot) {\n return globalStateClasses[slot] !== undefined;\n}","import { generateUtilityClass } from '../generateUtilityClass';\nexport function generateUtilityClasses(componentName, slots) {\n const result = {};\n slots.forEach(slot => {\n result[slot] = generateUtilityClass(componentName, slot);\n });\n return result;\n}","'use client';\n\nimport * as React from 'react';\nimport * as ReactDOM from 'react-dom';\nimport PropTypes from 'prop-types';\nimport { exactProp, HTMLElementType, unstable_useEnhancedEffect as useEnhancedEffect, unstable_useForkRef as useForkRef, unstable_setRef as setRef } from '@mui/utils';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nfunction getContainer(container) {\n return typeof container === 'function' ? container() : container;\n}\n\n/**\n * Portals provide a first-class way to render children into a DOM node\n * that exists outside the DOM hierarchy of the parent component.\n *\n * Demos:\n *\n * - [Portal](https://mui.com/base-ui/react-portal/)\n *\n * API:\n *\n * - [Portal API](https://mui.com/base-ui/react-portal/components-api/#portal)\n */\nconst Portal = /*#__PURE__*/React.forwardRef(function Portal(props, forwardedRef) {\n const {\n children,\n container,\n disablePortal = false\n } = props;\n const [mountNode, setMountNode] = React.useState(null);\n // @ts-expect-error TODO upstream fix\n const handleRef = useForkRef( /*#__PURE__*/React.isValidElement(children) ? children.ref : null, forwardedRef);\n useEnhancedEffect(() => {\n if (!disablePortal) {\n setMountNode(getContainer(container) || document.body);\n }\n }, [container, disablePortal]);\n useEnhancedEffect(() => {\n if (mountNode && !disablePortal) {\n setRef(forwardedRef, mountNode);\n return () => {\n setRef(forwardedRef, null);\n };\n }\n return undefined;\n }, [forwardedRef, mountNode, disablePortal]);\n if (disablePortal) {\n if ( /*#__PURE__*/React.isValidElement(children)) {\n const newProps = {\n ref: handleRef\n };\n return /*#__PURE__*/React.cloneElement(children, newProps);\n }\n return /*#__PURE__*/_jsx(React.Fragment, {\n children: children\n });\n }\n return /*#__PURE__*/_jsx(React.Fragment, {\n children: mountNode ? /*#__PURE__*/ReactDOM.createPortal(children, mountNode) : mountNode\n });\n});\nprocess.env.NODE_ENV !== \"production\" ? Portal.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * The children to render into the `container`.\n */\n children: PropTypes.node,\n /**\n * An HTML element or function that returns one.\n * The `container` will have the portal children appended to it.\n *\n * You can also provide a callback, which is called in a React layout effect.\n * This lets you set the container from a ref, and also makes server-side rendering possible.\n *\n * By default, it uses the body of the top-level document object,\n * so it's simply `document.body` most of the time.\n */\n container: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.func]),\n /**\n * The `children` will be under the DOM hierarchy of the parent component.\n * @default false\n */\n disablePortal: PropTypes.bool\n} : void 0;\nif (process.env.NODE_ENV !== 'production') {\n // eslint-disable-next-line\n Portal['propTypes' + ''] = exactProp(Portal.propTypes);\n}\nexport { Portal };","export var top = 'top';\nexport var bottom = 'bottom';\nexport var right = 'right';\nexport var left = 'left';\nexport var auto = 'auto';\nexport var basePlacements = [top, bottom, right, left];\nexport var start = 'start';\nexport var end = 'end';\nexport var clippingParents = 'clippingParents';\nexport var viewport = 'viewport';\nexport var popper = 'popper';\nexport var reference = 'reference';\nexport var variationPlacements = /*#__PURE__*/basePlacements.reduce(function (acc, placement) {\n return acc.concat([placement + \"-\" + start, placement + \"-\" + end]);\n}, []);\nexport var placements = /*#__PURE__*/[].concat(basePlacements, [auto]).reduce(function (acc, placement) {\n return acc.concat([placement, placement + \"-\" + start, placement + \"-\" + end]);\n}, []); // modifiers that need to read the DOM\n\nexport var beforeRead = 'beforeRead';\nexport var read = 'read';\nexport var afterRead = 'afterRead'; // pure-logic modifiers\n\nexport var beforeMain = 'beforeMain';\nexport var main = 'main';\nexport var afterMain = 'afterMain'; // modifier with the purpose to write to the DOM (or write into a framework state)\n\nexport var beforeWrite = 'beforeWrite';\nexport var write = 'write';\nexport var afterWrite = 'afterWrite';\nexport var modifierPhases = [beforeRead, read, afterRead, beforeMain, main, afterMain, beforeWrite, write, afterWrite];","export default function getNodeName(element) {\n return element ? (element.nodeName || '').toLowerCase() : null;\n}","export default function getWindow(node) {\n if (node == null) {\n return window;\n }\n\n if (node.toString() !== '[object Window]') {\n var ownerDocument = node.ownerDocument;\n return ownerDocument ? ownerDocument.defaultView || window : window;\n }\n\n return node;\n}","import getWindow from \"./getWindow.js\";\n\nfunction isElement(node) {\n var OwnElement = getWindow(node).Element;\n return node instanceof OwnElement || node instanceof Element;\n}\n\nfunction isHTMLElement(node) {\n var OwnElement = getWindow(node).HTMLElement;\n return node instanceof OwnElement || node instanceof HTMLElement;\n}\n\nfunction isShadowRoot(node) {\n // IE 11 has no ShadowRoot\n if (typeof ShadowRoot === 'undefined') {\n return false;\n }\n\n var OwnElement = getWindow(node).ShadowRoot;\n return node instanceof OwnElement || node instanceof ShadowRoot;\n}\n\nexport { isElement, isHTMLElement, isShadowRoot };","import getNodeName from \"../dom-utils/getNodeName.js\";\nimport { isHTMLElement } from \"../dom-utils/instanceOf.js\"; // This modifier takes the styles prepared by the `computeStyles` modifier\n// and applies them to the HTMLElements such as popper and arrow\n\nfunction applyStyles(_ref) {\n var state = _ref.state;\n Object.keys(state.elements).forEach(function (name) {\n var style = state.styles[name] || {};\n var attributes = state.attributes[name] || {};\n var element = state.elements[name]; // arrow is optional + virtual elements\n\n if (!isHTMLElement(element) || !getNodeName(element)) {\n return;\n } // Flow doesn't support to extend this property, but it's the most\n // effective way to apply styles to an HTMLElement\n // $FlowFixMe[cannot-write]\n\n\n Object.assign(element.style, style);\n Object.keys(attributes).forEach(function (name) {\n var value = attributes[name];\n\n if (value === false) {\n element.removeAttribute(name);\n } else {\n element.setAttribute(name, value === true ? '' : value);\n }\n });\n });\n}\n\nfunction effect(_ref2) {\n var state = _ref2.state;\n var initialStyles = {\n popper: {\n position: state.options.strategy,\n left: '0',\n top: '0',\n margin: '0'\n },\n arrow: {\n position: 'absolute'\n },\n reference: {}\n };\n Object.assign(state.elements.popper.style, initialStyles.popper);\n state.styles = initialStyles;\n\n if (state.elements.arrow) {\n Object.assign(state.elements.arrow.style, initialStyles.arrow);\n }\n\n return function () {\n Object.keys(state.elements).forEach(function (name) {\n var element = state.elements[name];\n var attributes = state.attributes[name] || {};\n var styleProperties = Object.keys(state.styles.hasOwnProperty(name) ? state.styles[name] : initialStyles[name]); // Set all values to an empty string to unset them\n\n var style = styleProperties.reduce(function (style, property) {\n style[property] = '';\n return style;\n }, {}); // arrow is optional + virtual elements\n\n if (!isHTMLElement(element) || !getNodeName(element)) {\n return;\n }\n\n Object.assign(element.style, style);\n Object.keys(attributes).forEach(function (attribute) {\n element.removeAttribute(attribute);\n });\n });\n };\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'applyStyles',\n enabled: true,\n phase: 'write',\n fn: applyStyles,\n effect: effect,\n requires: ['computeStyles']\n};","import { auto } from \"../enums.js\";\nexport default function getBasePlacement(placement) {\n return placement.split('-')[0];\n}","export var max = Math.max;\nexport var min = Math.min;\nexport var round = Math.round;","export default function getUAString() {\n var uaData = navigator.userAgentData;\n\n if (uaData != null && uaData.brands && Array.isArray(uaData.brands)) {\n return uaData.brands.map(function (item) {\n return item.brand + \"/\" + item.version;\n }).join(' ');\n }\n\n return navigator.userAgent;\n}","import getUAString from \"../utils/userAgent.js\";\nexport default function isLayoutViewport() {\n return !/^((?!chrome|android).)*safari/i.test(getUAString());\n}","import { isElement, isHTMLElement } from \"./instanceOf.js\";\nimport { round } from \"../utils/math.js\";\nimport getWindow from \"./getWindow.js\";\nimport isLayoutViewport from \"./isLayoutViewport.js\";\nexport default function getBoundingClientRect(element, includeScale, isFixedStrategy) {\n if (includeScale === void 0) {\n includeScale = false;\n }\n\n if (isFixedStrategy === void 0) {\n isFixedStrategy = false;\n }\n\n var clientRect = element.getBoundingClientRect();\n var scaleX = 1;\n var scaleY = 1;\n\n if (includeScale && isHTMLElement(element)) {\n scaleX = element.offsetWidth > 0 ? round(clientRect.width) / element.offsetWidth || 1 : 1;\n scaleY = element.offsetHeight > 0 ? round(clientRect.height) / element.offsetHeight || 1 : 1;\n }\n\n var _ref = isElement(element) ? getWindow(element) : window,\n visualViewport = _ref.visualViewport;\n\n var addVisualOffsets = !isLayoutViewport() && isFixedStrategy;\n var x = (clientRect.left + (addVisualOffsets && visualViewport ? visualViewport.offsetLeft : 0)) / scaleX;\n var y = (clientRect.top + (addVisualOffsets && visualViewport ? visualViewport.offsetTop : 0)) / scaleY;\n var width = clientRect.width / scaleX;\n var height = clientRect.height / scaleY;\n return {\n width: width,\n height: height,\n top: y,\n right: x + width,\n bottom: y + height,\n left: x,\n x: x,\n y: y\n };\n}","import getBoundingClientRect from \"./getBoundingClientRect.js\"; // Returns the layout rect of an element relative to its offsetParent. Layout\n// means it doesn't take into account transforms.\n\nexport default function getLayoutRect(element) {\n var clientRect = getBoundingClientRect(element); // Use the clientRect sizes if it's not been transformed.\n // Fixes https://github.com/popperjs/popper-core/issues/1223\n\n var width = element.offsetWidth;\n var height = element.offsetHeight;\n\n if (Math.abs(clientRect.width - width) <= 1) {\n width = clientRect.width;\n }\n\n if (Math.abs(clientRect.height - height) <= 1) {\n height = clientRect.height;\n }\n\n return {\n x: element.offsetLeft,\n y: element.offsetTop,\n width: width,\n height: height\n };\n}","import { isShadowRoot } from \"./instanceOf.js\";\nexport default function contains(parent, child) {\n var rootNode = child.getRootNode && child.getRootNode(); // First, attempt with faster native method\n\n if (parent.contains(child)) {\n return true;\n } // then fallback to custom implementation with Shadow DOM support\n else if (rootNode && isShadowRoot(rootNode)) {\n var next = child;\n\n do {\n if (next && parent.isSameNode(next)) {\n return true;\n } // $FlowFixMe[prop-missing]: need a better way to handle this...\n\n\n next = next.parentNode || next.host;\n } while (next);\n } // Give up, the result is false\n\n\n return false;\n}","import getWindow from \"./getWindow.js\";\nexport default function getComputedStyle(element) {\n return getWindow(element).getComputedStyle(element);\n}","import getNodeName from \"./getNodeName.js\";\nexport default function isTableElement(element) {\n return ['table', 'td', 'th'].indexOf(getNodeName(element)) >= 0;\n}","import { isElement } from \"./instanceOf.js\";\nexport default function getDocumentElement(element) {\n // $FlowFixMe[incompatible-return]: assume body is always available\n return ((isElement(element) ? element.ownerDocument : // $FlowFixMe[prop-missing]\n element.document) || window.document).documentElement;\n}","import getNodeName from \"./getNodeName.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport { isShadowRoot } from \"./instanceOf.js\";\nexport default function getParentNode(element) {\n if (getNodeName(element) === 'html') {\n return element;\n }\n\n return (// this is a quicker (but less type safe) way to save quite some bytes from the bundle\n // $FlowFixMe[incompatible-return]\n // $FlowFixMe[prop-missing]\n element.assignedSlot || // step into the shadow DOM of the parent of a slotted node\n element.parentNode || ( // DOM Element detected\n isShadowRoot(element) ? element.host : null) || // ShadowRoot detected\n // $FlowFixMe[incompatible-call]: HTMLElement is a Node\n getDocumentElement(element) // fallback\n\n );\n}","import getWindow from \"./getWindow.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport getComputedStyle from \"./getComputedStyle.js\";\nimport { isHTMLElement, isShadowRoot } from \"./instanceOf.js\";\nimport isTableElement from \"./isTableElement.js\";\nimport getParentNode from \"./getParentNode.js\";\nimport getUAString from \"../utils/userAgent.js\";\n\nfunction getTrueOffsetParent(element) {\n if (!isHTMLElement(element) || // https://github.com/popperjs/popper-core/issues/837\n getComputedStyle(element).position === 'fixed') {\n return null;\n }\n\n return element.offsetParent;\n} // `.offsetParent` reports `null` for fixed elements, while absolute elements\n// return the containing block\n\n\nfunction getContainingBlock(element) {\n var isFirefox = /firefox/i.test(getUAString());\n var isIE = /Trident/i.test(getUAString());\n\n if (isIE && isHTMLElement(element)) {\n // In IE 9, 10 and 11 fixed elements containing block is always established by the viewport\n var elementCss = getComputedStyle(element);\n\n if (elementCss.position === 'fixed') {\n return null;\n }\n }\n\n var currentNode = getParentNode(element);\n\n if (isShadowRoot(currentNode)) {\n currentNode = currentNode.host;\n }\n\n while (isHTMLElement(currentNode) && ['html', 'body'].indexOf(getNodeName(currentNode)) < 0) {\n var css = getComputedStyle(currentNode); // This is non-exhaustive but covers the most common CSS properties that\n // create a containing block.\n // https://developer.mozilla.org/en-US/docs/Web/CSS/Containing_block#identifying_the_containing_block\n\n if (css.transform !== 'none' || css.perspective !== 'none' || css.contain === 'paint' || ['transform', 'perspective'].indexOf(css.willChange) !== -1 || isFirefox && css.willChange === 'filter' || isFirefox && css.filter && css.filter !== 'none') {\n return currentNode;\n } else {\n currentNode = currentNode.parentNode;\n }\n }\n\n return null;\n} // Gets the closest ancestor positioned element. Handles some edge cases,\n// such as table ancestors and cross browser bugs.\n\n\nexport default function getOffsetParent(element) {\n var window = getWindow(element);\n var offsetParent = getTrueOffsetParent(element);\n\n while (offsetParent && isTableElement(offsetParent) && getComputedStyle(offsetParent).position === 'static') {\n offsetParent = getTrueOffsetParent(offsetParent);\n }\n\n if (offsetParent && (getNodeName(offsetParent) === 'html' || getNodeName(offsetParent) === 'body' && getComputedStyle(offsetParent).position === 'static')) {\n return window;\n }\n\n return offsetParent || getContainingBlock(element) || window;\n}","export default function getMainAxisFromPlacement(placement) {\n return ['top', 'bottom'].indexOf(placement) >= 0 ? 'x' : 'y';\n}","import { max as mathMax, min as mathMin } from \"./math.js\";\nexport function within(min, value, max) {\n return mathMax(min, mathMin(value, max));\n}\nexport function withinMaxClamp(min, value, max) {\n var v = within(min, value, max);\n return v > max ? max : v;\n}","export default function getFreshSideObject() {\n return {\n top: 0,\n right: 0,\n bottom: 0,\n left: 0\n };\n}","import getFreshSideObject from \"./getFreshSideObject.js\";\nexport default function mergePaddingObject(paddingObject) {\n return Object.assign({}, getFreshSideObject(), paddingObject);\n}","export default function expandToHashMap(value, keys) {\n return keys.reduce(function (hashMap, key) {\n hashMap[key] = value;\n return hashMap;\n }, {});\n}","import getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getLayoutRect from \"../dom-utils/getLayoutRect.js\";\nimport contains from \"../dom-utils/contains.js\";\nimport getOffsetParent from \"../dom-utils/getOffsetParent.js\";\nimport getMainAxisFromPlacement from \"../utils/getMainAxisFromPlacement.js\";\nimport { within } from \"../utils/within.js\";\nimport mergePaddingObject from \"../utils/mergePaddingObject.js\";\nimport expandToHashMap from \"../utils/expandToHashMap.js\";\nimport { left, right, basePlacements, top, bottom } from \"../enums.js\"; // eslint-disable-next-line import/no-unused-modules\n\nvar toPaddingObject = function toPaddingObject(padding, state) {\n padding = typeof padding === 'function' ? padding(Object.assign({}, state.rects, {\n placement: state.placement\n })) : padding;\n return mergePaddingObject(typeof padding !== 'number' ? padding : expandToHashMap(padding, basePlacements));\n};\n\nfunction arrow(_ref) {\n var _state$modifiersData$;\n\n var state = _ref.state,\n name = _ref.name,\n options = _ref.options;\n var arrowElement = state.elements.arrow;\n var popperOffsets = state.modifiersData.popperOffsets;\n var basePlacement = getBasePlacement(state.placement);\n var axis = getMainAxisFromPlacement(basePlacement);\n var isVertical = [left, right].indexOf(basePlacement) >= 0;\n var len = isVertical ? 'height' : 'width';\n\n if (!arrowElement || !popperOffsets) {\n return;\n }\n\n var paddingObject = toPaddingObject(options.padding, state);\n var arrowRect = getLayoutRect(arrowElement);\n var minProp = axis === 'y' ? top : left;\n var maxProp = axis === 'y' ? bottom : right;\n var endDiff = state.rects.reference[len] + state.rects.reference[axis] - popperOffsets[axis] - state.rects.popper[len];\n var startDiff = popperOffsets[axis] - state.rects.reference[axis];\n var arrowOffsetParent = getOffsetParent(arrowElement);\n var clientSize = arrowOffsetParent ? axis === 'y' ? arrowOffsetParent.clientHeight || 0 : arrowOffsetParent.clientWidth || 0 : 0;\n var centerToReference = endDiff / 2 - startDiff / 2; // Make sure the arrow doesn't overflow the popper if the center point is\n // outside of the popper bounds\n\n var min = paddingObject[minProp];\n var max = clientSize - arrowRect[len] - paddingObject[maxProp];\n var center = clientSize / 2 - arrowRect[len] / 2 + centerToReference;\n var offset = within(min, center, max); // Prevents breaking syntax highlighting...\n\n var axisProp = axis;\n state.modifiersData[name] = (_state$modifiersData$ = {}, _state$modifiersData$[axisProp] = offset, _state$modifiersData$.centerOffset = offset - center, _state$modifiersData$);\n}\n\nfunction effect(_ref2) {\n var state = _ref2.state,\n options = _ref2.options;\n var _options$element = options.element,\n arrowElement = _options$element === void 0 ? '[data-popper-arrow]' : _options$element;\n\n if (arrowElement == null) {\n return;\n } // CSS selector\n\n\n if (typeof arrowElement === 'string') {\n arrowElement = state.elements.popper.querySelector(arrowElement);\n\n if (!arrowElement) {\n return;\n }\n }\n\n if (!contains(state.elements.popper, arrowElement)) {\n return;\n }\n\n state.elements.arrow = arrowElement;\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'arrow',\n enabled: true,\n phase: 'main',\n fn: arrow,\n effect: effect,\n requires: ['popperOffsets'],\n requiresIfExists: ['preventOverflow']\n};","export default function getVariation(placement) {\n return placement.split('-')[1];\n}","import { top, left, right, bottom, end } from \"../enums.js\";\nimport getOffsetParent from \"../dom-utils/getOffsetParent.js\";\nimport getWindow from \"../dom-utils/getWindow.js\";\nimport getDocumentElement from \"../dom-utils/getDocumentElement.js\";\nimport getComputedStyle from \"../dom-utils/getComputedStyle.js\";\nimport getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getVariation from \"../utils/getVariation.js\";\nimport { round } from \"../utils/math.js\"; // eslint-disable-next-line import/no-unused-modules\n\nvar unsetSides = {\n top: 'auto',\n right: 'auto',\n bottom: 'auto',\n left: 'auto'\n}; // Round the offsets to the nearest suitable subpixel based on the DPR.\n// Zooming can change the DPR, but it seems to report a value that will\n// cleanly divide the values into the appropriate subpixels.\n\nfunction roundOffsetsByDPR(_ref, win) {\n var x = _ref.x,\n y = _ref.y;\n var dpr = win.devicePixelRatio || 1;\n return {\n x: round(x * dpr) / dpr || 0,\n y: round(y * dpr) / dpr || 0\n };\n}\n\nexport function mapToStyles(_ref2) {\n var _Object$assign2;\n\n var popper = _ref2.popper,\n popperRect = _ref2.popperRect,\n placement = _ref2.placement,\n variation = _ref2.variation,\n offsets = _ref2.offsets,\n position = _ref2.position,\n gpuAcceleration = _ref2.gpuAcceleration,\n adaptive = _ref2.adaptive,\n roundOffsets = _ref2.roundOffsets,\n isFixed = _ref2.isFixed;\n var _offsets$x = offsets.x,\n x = _offsets$x === void 0 ? 0 : _offsets$x,\n _offsets$y = offsets.y,\n y = _offsets$y === void 0 ? 0 : _offsets$y;\n\n var _ref3 = typeof roundOffsets === 'function' ? roundOffsets({\n x: x,\n y: y\n }) : {\n x: x,\n y: y\n };\n\n x = _ref3.x;\n y = _ref3.y;\n var hasX = offsets.hasOwnProperty('x');\n var hasY = offsets.hasOwnProperty('y');\n var sideX = left;\n var sideY = top;\n var win = window;\n\n if (adaptive) {\n var offsetParent = getOffsetParent(popper);\n var heightProp = 'clientHeight';\n var widthProp = 'clientWidth';\n\n if (offsetParent === getWindow(popper)) {\n offsetParent = getDocumentElement(popper);\n\n if (getComputedStyle(offsetParent).position !== 'static' && position === 'absolute') {\n heightProp = 'scrollHeight';\n widthProp = 'scrollWidth';\n }\n } // $FlowFixMe[incompatible-cast]: force type refinement, we compare offsetParent with window above, but Flow doesn't detect it\n\n\n offsetParent = offsetParent;\n\n if (placement === top || (placement === left || placement === right) && variation === end) {\n sideY = bottom;\n var offsetY = isFixed && offsetParent === win && win.visualViewport ? win.visualViewport.height : // $FlowFixMe[prop-missing]\n offsetParent[heightProp];\n y -= offsetY - popperRect.height;\n y *= gpuAcceleration ? 1 : -1;\n }\n\n if (placement === left || (placement === top || placement === bottom) && variation === end) {\n sideX = right;\n var offsetX = isFixed && offsetParent === win && win.visualViewport ? win.visualViewport.width : // $FlowFixMe[prop-missing]\n offsetParent[widthProp];\n x -= offsetX - popperRect.width;\n x *= gpuAcceleration ? 1 : -1;\n }\n }\n\n var commonStyles = Object.assign({\n position: position\n }, adaptive && unsetSides);\n\n var _ref4 = roundOffsets === true ? roundOffsetsByDPR({\n x: x,\n y: y\n }, getWindow(popper)) : {\n x: x,\n y: y\n };\n\n x = _ref4.x;\n y = _ref4.y;\n\n if (gpuAcceleration) {\n var _Object$assign;\n\n return Object.assign({}, commonStyles, (_Object$assign = {}, _Object$assign[sideY] = hasY ? '0' : '', _Object$assign[sideX] = hasX ? '0' : '', _Object$assign.transform = (win.devicePixelRatio || 1) <= 1 ? \"translate(\" + x + \"px, \" + y + \"px)\" : \"translate3d(\" + x + \"px, \" + y + \"px, 0)\", _Object$assign));\n }\n\n return Object.assign({}, commonStyles, (_Object$assign2 = {}, _Object$assign2[sideY] = hasY ? y + \"px\" : '', _Object$assign2[sideX] = hasX ? x + \"px\" : '', _Object$assign2.transform = '', _Object$assign2));\n}\n\nfunction computeStyles(_ref5) {\n var state = _ref5.state,\n options = _ref5.options;\n var _options$gpuAccelerat = options.gpuAcceleration,\n gpuAcceleration = _options$gpuAccelerat === void 0 ? true : _options$gpuAccelerat,\n _options$adaptive = options.adaptive,\n adaptive = _options$adaptive === void 0 ? true : _options$adaptive,\n _options$roundOffsets = options.roundOffsets,\n roundOffsets = _options$roundOffsets === void 0 ? true : _options$roundOffsets;\n var commonStyles = {\n placement: getBasePlacement(state.placement),\n variation: getVariation(state.placement),\n popper: state.elements.popper,\n popperRect: state.rects.popper,\n gpuAcceleration: gpuAcceleration,\n isFixed: state.options.strategy === 'fixed'\n };\n\n if (state.modifiersData.popperOffsets != null) {\n state.styles.popper = Object.assign({}, state.styles.popper, mapToStyles(Object.assign({}, commonStyles, {\n offsets: state.modifiersData.popperOffsets,\n position: state.options.strategy,\n adaptive: adaptive,\n roundOffsets: roundOffsets\n })));\n }\n\n if (state.modifiersData.arrow != null) {\n state.styles.arrow = Object.assign({}, state.styles.arrow, mapToStyles(Object.assign({}, commonStyles, {\n offsets: state.modifiersData.arrow,\n position: 'absolute',\n adaptive: false,\n roundOffsets: roundOffsets\n })));\n }\n\n state.attributes.popper = Object.assign({}, state.attributes.popper, {\n 'data-popper-placement': state.placement\n });\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'computeStyles',\n enabled: true,\n phase: 'beforeWrite',\n fn: computeStyles,\n data: {}\n};","import getWindow from \"../dom-utils/getWindow.js\"; // eslint-disable-next-line import/no-unused-modules\n\nvar passive = {\n passive: true\n};\n\nfunction effect(_ref) {\n var state = _ref.state,\n instance = _ref.instance,\n options = _ref.options;\n var _options$scroll = options.scroll,\n scroll = _options$scroll === void 0 ? true : _options$scroll,\n _options$resize = options.resize,\n resize = _options$resize === void 0 ? true : _options$resize;\n var window = getWindow(state.elements.popper);\n var scrollParents = [].concat(state.scrollParents.reference, state.scrollParents.popper);\n\n if (scroll) {\n scrollParents.forEach(function (scrollParent) {\n scrollParent.addEventListener('scroll', instance.update, passive);\n });\n }\n\n if (resize) {\n window.addEventListener('resize', instance.update, passive);\n }\n\n return function () {\n if (scroll) {\n scrollParents.forEach(function (scrollParent) {\n scrollParent.removeEventListener('scroll', instance.update, passive);\n });\n }\n\n if (resize) {\n window.removeEventListener('resize', instance.update, passive);\n }\n };\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'eventListeners',\n enabled: true,\n phase: 'write',\n fn: function fn() {},\n effect: effect,\n data: {}\n};","var hash = {\n left: 'right',\n right: 'left',\n bottom: 'top',\n top: 'bottom'\n};\nexport default function getOppositePlacement(placement) {\n return placement.replace(/left|right|bottom|top/g, function (matched) {\n return hash[matched];\n });\n}","var hash = {\n start: 'end',\n end: 'start'\n};\nexport default function getOppositeVariationPlacement(placement) {\n return placement.replace(/start|end/g, function (matched) {\n return hash[matched];\n });\n}","import getWindow from \"./getWindow.js\";\nexport default function getWindowScroll(node) {\n var win = getWindow(node);\n var scrollLeft = win.pageXOffset;\n var scrollTop = win.pageYOffset;\n return {\n scrollLeft: scrollLeft,\n scrollTop: scrollTop\n };\n}","import getBoundingClientRect from \"./getBoundingClientRect.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport getWindowScroll from \"./getWindowScroll.js\";\nexport default function getWindowScrollBarX(element) {\n // If has a CSS width greater than the viewport, then this will be\n // incorrect for RTL.\n // Popper 1 is broken in this case and never had a bug report so let's assume\n // it's not an issue. I don't think anyone ever specifies width on \n // anyway.\n // Browsers where the left scrollbar doesn't cause an issue report `0` for\n // this (e.g. Edge 2019, IE11, Safari)\n return getBoundingClientRect(getDocumentElement(element)).left + getWindowScroll(element).scrollLeft;\n}","import getWindow from \"./getWindow.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport getWindowScrollBarX from \"./getWindowScrollBarX.js\";\nimport isLayoutViewport from \"./isLayoutViewport.js\";\nexport default function getViewportRect(element, strategy) {\n var win = getWindow(element);\n var html = getDocumentElement(element);\n var visualViewport = win.visualViewport;\n var width = html.clientWidth;\n var height = html.clientHeight;\n var x = 0;\n var y = 0;\n\n if (visualViewport) {\n width = visualViewport.width;\n height = visualViewport.height;\n var layoutViewport = isLayoutViewport();\n\n if (layoutViewport || !layoutViewport && strategy === 'fixed') {\n x = visualViewport.offsetLeft;\n y = visualViewport.offsetTop;\n }\n }\n\n return {\n width: width,\n height: height,\n x: x + getWindowScrollBarX(element),\n y: y\n };\n}","import getDocumentElement from \"./getDocumentElement.js\";\nimport getComputedStyle from \"./getComputedStyle.js\";\nimport getWindowScrollBarX from \"./getWindowScrollBarX.js\";\nimport getWindowScroll from \"./getWindowScroll.js\";\nimport { max } from \"../utils/math.js\"; // Gets the entire size of the scrollable document area, even extending outside\n// of the `` and `` rect bounds if horizontally scrollable\n\nexport default function getDocumentRect(element) {\n var _element$ownerDocumen;\n\n var html = getDocumentElement(element);\n var winScroll = getWindowScroll(element);\n var body = (_element$ownerDocumen = element.ownerDocument) == null ? void 0 : _element$ownerDocumen.body;\n var width = max(html.scrollWidth, html.clientWidth, body ? body.scrollWidth : 0, body ? body.clientWidth : 0);\n var height = max(html.scrollHeight, html.clientHeight, body ? body.scrollHeight : 0, body ? body.clientHeight : 0);\n var x = -winScroll.scrollLeft + getWindowScrollBarX(element);\n var y = -winScroll.scrollTop;\n\n if (getComputedStyle(body || html).direction === 'rtl') {\n x += max(html.clientWidth, body ? body.clientWidth : 0) - width;\n }\n\n return {\n width: width,\n height: height,\n x: x,\n y: y\n };\n}","import getComputedStyle from \"./getComputedStyle.js\";\nexport default function isScrollParent(element) {\n // Firefox wants us to check `-x` and `-y` variations as well\n var _getComputedStyle = getComputedStyle(element),\n overflow = _getComputedStyle.overflow,\n overflowX = _getComputedStyle.overflowX,\n overflowY = _getComputedStyle.overflowY;\n\n return /auto|scroll|overlay|hidden/.test(overflow + overflowY + overflowX);\n}","import getParentNode from \"./getParentNode.js\";\nimport isScrollParent from \"./isScrollParent.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport { isHTMLElement } from \"./instanceOf.js\";\nexport default function getScrollParent(node) {\n if (['html', 'body', '#document'].indexOf(getNodeName(node)) >= 0) {\n // $FlowFixMe[incompatible-return]: assume body is always available\n return node.ownerDocument.body;\n }\n\n if (isHTMLElement(node) && isScrollParent(node)) {\n return node;\n }\n\n return getScrollParent(getParentNode(node));\n}","import getScrollParent from \"./getScrollParent.js\";\nimport getParentNode from \"./getParentNode.js\";\nimport getWindow from \"./getWindow.js\";\nimport isScrollParent from \"./isScrollParent.js\";\n/*\ngiven a DOM element, return the list of all scroll parents, up the list of ancesors\nuntil we get to the top window object. This list is what we attach scroll listeners\nto, because if any of these parent elements scroll, we'll need to re-calculate the\nreference element's position.\n*/\n\nexport default function listScrollParents(element, list) {\n var _element$ownerDocumen;\n\n if (list === void 0) {\n list = [];\n }\n\n var scrollParent = getScrollParent(element);\n var isBody = scrollParent === ((_element$ownerDocumen = element.ownerDocument) == null ? void 0 : _element$ownerDocumen.body);\n var win = getWindow(scrollParent);\n var target = isBody ? [win].concat(win.visualViewport || [], isScrollParent(scrollParent) ? scrollParent : []) : scrollParent;\n var updatedList = list.concat(target);\n return isBody ? updatedList : // $FlowFixMe[incompatible-call]: isBody tells us target will be an HTMLElement here\n updatedList.concat(listScrollParents(getParentNode(target)));\n}","export default function rectToClientRect(rect) {\n return Object.assign({}, rect, {\n left: rect.x,\n top: rect.y,\n right: rect.x + rect.width,\n bottom: rect.y + rect.height\n });\n}","import { viewport } from \"../enums.js\";\nimport getViewportRect from \"./getViewportRect.js\";\nimport getDocumentRect from \"./getDocumentRect.js\";\nimport listScrollParents from \"./listScrollParents.js\";\nimport getOffsetParent from \"./getOffsetParent.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport getComputedStyle from \"./getComputedStyle.js\";\nimport { isElement, isHTMLElement } from \"./instanceOf.js\";\nimport getBoundingClientRect from \"./getBoundingClientRect.js\";\nimport getParentNode from \"./getParentNode.js\";\nimport contains from \"./contains.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport rectToClientRect from \"../utils/rectToClientRect.js\";\nimport { max, min } from \"../utils/math.js\";\n\nfunction getInnerBoundingClientRect(element, strategy) {\n var rect = getBoundingClientRect(element, false, strategy === 'fixed');\n rect.top = rect.top + element.clientTop;\n rect.left = rect.left + element.clientLeft;\n rect.bottom = rect.top + element.clientHeight;\n rect.right = rect.left + element.clientWidth;\n rect.width = element.clientWidth;\n rect.height = element.clientHeight;\n rect.x = rect.left;\n rect.y = rect.top;\n return rect;\n}\n\nfunction getClientRectFromMixedType(element, clippingParent, strategy) {\n return clippingParent === viewport ? rectToClientRect(getViewportRect(element, strategy)) : isElement(clippingParent) ? getInnerBoundingClientRect(clippingParent, strategy) : rectToClientRect(getDocumentRect(getDocumentElement(element)));\n} // A \"clipping parent\" is an overflowable container with the characteristic of\n// clipping (or hiding) overflowing elements with a position different from\n// `initial`\n\n\nfunction getClippingParents(element) {\n var clippingParents = listScrollParents(getParentNode(element));\n var canEscapeClipping = ['absolute', 'fixed'].indexOf(getComputedStyle(element).position) >= 0;\n var clipperElement = canEscapeClipping && isHTMLElement(element) ? getOffsetParent(element) : element;\n\n if (!isElement(clipperElement)) {\n return [];\n } // $FlowFixMe[incompatible-return]: https://github.com/facebook/flow/issues/1414\n\n\n return clippingParents.filter(function (clippingParent) {\n return isElement(clippingParent) && contains(clippingParent, clipperElement) && getNodeName(clippingParent) !== 'body';\n });\n} // Gets the maximum area that the element is visible in due to any number of\n// clipping parents\n\n\nexport default function getClippingRect(element, boundary, rootBoundary, strategy) {\n var mainClippingParents = boundary === 'clippingParents' ? getClippingParents(element) : [].concat(boundary);\n var clippingParents = [].concat(mainClippingParents, [rootBoundary]);\n var firstClippingParent = clippingParents[0];\n var clippingRect = clippingParents.reduce(function (accRect, clippingParent) {\n var rect = getClientRectFromMixedType(element, clippingParent, strategy);\n accRect.top = max(rect.top, accRect.top);\n accRect.right = min(rect.right, accRect.right);\n accRect.bottom = min(rect.bottom, accRect.bottom);\n accRect.left = max(rect.left, accRect.left);\n return accRect;\n }, getClientRectFromMixedType(element, firstClippingParent, strategy));\n clippingRect.width = clippingRect.right - clippingRect.left;\n clippingRect.height = clippingRect.bottom - clippingRect.top;\n clippingRect.x = clippingRect.left;\n clippingRect.y = clippingRect.top;\n return clippingRect;\n}","import getBasePlacement from \"./getBasePlacement.js\";\nimport getVariation from \"./getVariation.js\";\nimport getMainAxisFromPlacement from \"./getMainAxisFromPlacement.js\";\nimport { top, right, bottom, left, start, end } from \"../enums.js\";\nexport default function computeOffsets(_ref) {\n var reference = _ref.reference,\n element = _ref.element,\n placement = _ref.placement;\n var basePlacement = placement ? getBasePlacement(placement) : null;\n var variation = placement ? getVariation(placement) : null;\n var commonX = reference.x + reference.width / 2 - element.width / 2;\n var commonY = reference.y + reference.height / 2 - element.height / 2;\n var offsets;\n\n switch (basePlacement) {\n case top:\n offsets = {\n x: commonX,\n y: reference.y - element.height\n };\n break;\n\n case bottom:\n offsets = {\n x: commonX,\n y: reference.y + reference.height\n };\n break;\n\n case right:\n offsets = {\n x: reference.x + reference.width,\n y: commonY\n };\n break;\n\n case left:\n offsets = {\n x: reference.x - element.width,\n y: commonY\n };\n break;\n\n default:\n offsets = {\n x: reference.x,\n y: reference.y\n };\n }\n\n var mainAxis = basePlacement ? getMainAxisFromPlacement(basePlacement) : null;\n\n if (mainAxis != null) {\n var len = mainAxis === 'y' ? 'height' : 'width';\n\n switch (variation) {\n case start:\n offsets[mainAxis] = offsets[mainAxis] - (reference[len] / 2 - element[len] / 2);\n break;\n\n case end:\n offsets[mainAxis] = offsets[mainAxis] + (reference[len] / 2 - element[len] / 2);\n break;\n\n default:\n }\n }\n\n return offsets;\n}","import getClippingRect from \"../dom-utils/getClippingRect.js\";\nimport getDocumentElement from \"../dom-utils/getDocumentElement.js\";\nimport getBoundingClientRect from \"../dom-utils/getBoundingClientRect.js\";\nimport computeOffsets from \"./computeOffsets.js\";\nimport rectToClientRect from \"./rectToClientRect.js\";\nimport { clippingParents, reference, popper, bottom, top, right, basePlacements, viewport } from \"../enums.js\";\nimport { isElement } from \"../dom-utils/instanceOf.js\";\nimport mergePaddingObject from \"./mergePaddingObject.js\";\nimport expandToHashMap from \"./expandToHashMap.js\"; // eslint-disable-next-line import/no-unused-modules\n\nexport default function detectOverflow(state, options) {\n if (options === void 0) {\n options = {};\n }\n\n var _options = options,\n _options$placement = _options.placement,\n placement = _options$placement === void 0 ? state.placement : _options$placement,\n _options$strategy = _options.strategy,\n strategy = _options$strategy === void 0 ? state.strategy : _options$strategy,\n _options$boundary = _options.boundary,\n boundary = _options$boundary === void 0 ? clippingParents : _options$boundary,\n _options$rootBoundary = _options.rootBoundary,\n rootBoundary = _options$rootBoundary === void 0 ? viewport : _options$rootBoundary,\n _options$elementConte = _options.elementContext,\n elementContext = _options$elementConte === void 0 ? popper : _options$elementConte,\n _options$altBoundary = _options.altBoundary,\n altBoundary = _options$altBoundary === void 0 ? false : _options$altBoundary,\n _options$padding = _options.padding,\n padding = _options$padding === void 0 ? 0 : _options$padding;\n var paddingObject = mergePaddingObject(typeof padding !== 'number' ? padding : expandToHashMap(padding, basePlacements));\n var altContext = elementContext === popper ? reference : popper;\n var popperRect = state.rects.popper;\n var element = state.elements[altBoundary ? altContext : elementContext];\n var clippingClientRect = getClippingRect(isElement(element) ? element : element.contextElement || getDocumentElement(state.elements.popper), boundary, rootBoundary, strategy);\n var referenceClientRect = getBoundingClientRect(state.elements.reference);\n var popperOffsets = computeOffsets({\n reference: referenceClientRect,\n element: popperRect,\n strategy: 'absolute',\n placement: placement\n });\n var popperClientRect = rectToClientRect(Object.assign({}, popperRect, popperOffsets));\n var elementClientRect = elementContext === popper ? popperClientRect : referenceClientRect; // positive = overflowing the clipping rect\n // 0 or negative = within the clipping rect\n\n var overflowOffsets = {\n top: clippingClientRect.top - elementClientRect.top + paddingObject.top,\n bottom: elementClientRect.bottom - clippingClientRect.bottom + paddingObject.bottom,\n left: clippingClientRect.left - elementClientRect.left + paddingObject.left,\n right: elementClientRect.right - clippingClientRect.right + paddingObject.right\n };\n var offsetData = state.modifiersData.offset; // Offsets can be applied only to the popper element\n\n if (elementContext === popper && offsetData) {\n var offset = offsetData[placement];\n Object.keys(overflowOffsets).forEach(function (key) {\n var multiply = [right, bottom].indexOf(key) >= 0 ? 1 : -1;\n var axis = [top, bottom].indexOf(key) >= 0 ? 'y' : 'x';\n overflowOffsets[key] += offset[axis] * multiply;\n });\n }\n\n return overflowOffsets;\n}","import getVariation from \"./getVariation.js\";\nimport { variationPlacements, basePlacements, placements as allPlacements } from \"../enums.js\";\nimport detectOverflow from \"./detectOverflow.js\";\nimport getBasePlacement from \"./getBasePlacement.js\";\nexport default function computeAutoPlacement(state, options) {\n if (options === void 0) {\n options = {};\n }\n\n var _options = options,\n placement = _options.placement,\n boundary = _options.boundary,\n rootBoundary = _options.rootBoundary,\n padding = _options.padding,\n flipVariations = _options.flipVariations,\n _options$allowedAutoP = _options.allowedAutoPlacements,\n allowedAutoPlacements = _options$allowedAutoP === void 0 ? allPlacements : _options$allowedAutoP;\n var variation = getVariation(placement);\n var placements = variation ? flipVariations ? variationPlacements : variationPlacements.filter(function (placement) {\n return getVariation(placement) === variation;\n }) : basePlacements;\n var allowedPlacements = placements.filter(function (placement) {\n return allowedAutoPlacements.indexOf(placement) >= 0;\n });\n\n if (allowedPlacements.length === 0) {\n allowedPlacements = placements;\n } // $FlowFixMe[incompatible-type]: Flow seems to have problems with two array unions...\n\n\n var overflows = allowedPlacements.reduce(function (acc, placement) {\n acc[placement] = detectOverflow(state, {\n placement: placement,\n boundary: boundary,\n rootBoundary: rootBoundary,\n padding: padding\n })[getBasePlacement(placement)];\n return acc;\n }, {});\n return Object.keys(overflows).sort(function (a, b) {\n return overflows[a] - overflows[b];\n });\n}","import getOppositePlacement from \"../utils/getOppositePlacement.js\";\nimport getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getOppositeVariationPlacement from \"../utils/getOppositeVariationPlacement.js\";\nimport detectOverflow from \"../utils/detectOverflow.js\";\nimport computeAutoPlacement from \"../utils/computeAutoPlacement.js\";\nimport { bottom, top, start, right, left, auto } from \"../enums.js\";\nimport getVariation from \"../utils/getVariation.js\"; // eslint-disable-next-line import/no-unused-modules\n\nfunction getExpandedFallbackPlacements(placement) {\n if (getBasePlacement(placement) === auto) {\n return [];\n }\n\n var oppositePlacement = getOppositePlacement(placement);\n return [getOppositeVariationPlacement(placement), oppositePlacement, getOppositeVariationPlacement(oppositePlacement)];\n}\n\nfunction flip(_ref) {\n var state = _ref.state,\n options = _ref.options,\n name = _ref.name;\n\n if (state.modifiersData[name]._skip) {\n return;\n }\n\n var _options$mainAxis = options.mainAxis,\n checkMainAxis = _options$mainAxis === void 0 ? true : _options$mainAxis,\n _options$altAxis = options.altAxis,\n checkAltAxis = _options$altAxis === void 0 ? true : _options$altAxis,\n specifiedFallbackPlacements = options.fallbackPlacements,\n padding = options.padding,\n boundary = options.boundary,\n rootBoundary = options.rootBoundary,\n altBoundary = options.altBoundary,\n _options$flipVariatio = options.flipVariations,\n flipVariations = _options$flipVariatio === void 0 ? true : _options$flipVariatio,\n allowedAutoPlacements = options.allowedAutoPlacements;\n var preferredPlacement = state.options.placement;\n var basePlacement = getBasePlacement(preferredPlacement);\n var isBasePlacement = basePlacement === preferredPlacement;\n var fallbackPlacements = specifiedFallbackPlacements || (isBasePlacement || !flipVariations ? [getOppositePlacement(preferredPlacement)] : getExpandedFallbackPlacements(preferredPlacement));\n var placements = [preferredPlacement].concat(fallbackPlacements).reduce(function (acc, placement) {\n return acc.concat(getBasePlacement(placement) === auto ? computeAutoPlacement(state, {\n placement: placement,\n boundary: boundary,\n rootBoundary: rootBoundary,\n padding: padding,\n flipVariations: flipVariations,\n allowedAutoPlacements: allowedAutoPlacements\n }) : placement);\n }, []);\n var referenceRect = state.rects.reference;\n var popperRect = state.rects.popper;\n var checksMap = new Map();\n var makeFallbackChecks = true;\n var firstFittingPlacement = placements[0];\n\n for (var i = 0; i < placements.length; i++) {\n var placement = placements[i];\n\n var _basePlacement = getBasePlacement(placement);\n\n var isStartVariation = getVariation(placement) === start;\n var isVertical = [top, bottom].indexOf(_basePlacement) >= 0;\n var len = isVertical ? 'width' : 'height';\n var overflow = detectOverflow(state, {\n placement: placement,\n boundary: boundary,\n rootBoundary: rootBoundary,\n altBoundary: altBoundary,\n padding: padding\n });\n var mainVariationSide = isVertical ? isStartVariation ? right : left : isStartVariation ? bottom : top;\n\n if (referenceRect[len] > popperRect[len]) {\n mainVariationSide = getOppositePlacement(mainVariationSide);\n }\n\n var altVariationSide = getOppositePlacement(mainVariationSide);\n var checks = [];\n\n if (checkMainAxis) {\n checks.push(overflow[_basePlacement] <= 0);\n }\n\n if (checkAltAxis) {\n checks.push(overflow[mainVariationSide] <= 0, overflow[altVariationSide] <= 0);\n }\n\n if (checks.every(function (check) {\n return check;\n })) {\n firstFittingPlacement = placement;\n makeFallbackChecks = false;\n break;\n }\n\n checksMap.set(placement, checks);\n }\n\n if (makeFallbackChecks) {\n // `2` may be desired in some cases – research later\n var numberOfChecks = flipVariations ? 3 : 1;\n\n var _loop = function _loop(_i) {\n var fittingPlacement = placements.find(function (placement) {\n var checks = checksMap.get(placement);\n\n if (checks) {\n return checks.slice(0, _i).every(function (check) {\n return check;\n });\n }\n });\n\n if (fittingPlacement) {\n firstFittingPlacement = fittingPlacement;\n return \"break\";\n }\n };\n\n for (var _i = numberOfChecks; _i > 0; _i--) {\n var _ret = _loop(_i);\n\n if (_ret === \"break\") break;\n }\n }\n\n if (state.placement !== firstFittingPlacement) {\n state.modifiersData[name]._skip = true;\n state.placement = firstFittingPlacement;\n state.reset = true;\n }\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'flip',\n enabled: true,\n phase: 'main',\n fn: flip,\n requiresIfExists: ['offset'],\n data: {\n _skip: false\n }\n};","import { top, bottom, left, right } from \"../enums.js\";\nimport detectOverflow from \"../utils/detectOverflow.js\";\n\nfunction getSideOffsets(overflow, rect, preventedOffsets) {\n if (preventedOffsets === void 0) {\n preventedOffsets = {\n x: 0,\n y: 0\n };\n }\n\n return {\n top: overflow.top - rect.height - preventedOffsets.y,\n right: overflow.right - rect.width + preventedOffsets.x,\n bottom: overflow.bottom - rect.height + preventedOffsets.y,\n left: overflow.left - rect.width - preventedOffsets.x\n };\n}\n\nfunction isAnySideFullyClipped(overflow) {\n return [top, right, bottom, left].some(function (side) {\n return overflow[side] >= 0;\n });\n}\n\nfunction hide(_ref) {\n var state = _ref.state,\n name = _ref.name;\n var referenceRect = state.rects.reference;\n var popperRect = state.rects.popper;\n var preventedOffsets = state.modifiersData.preventOverflow;\n var referenceOverflow = detectOverflow(state, {\n elementContext: 'reference'\n });\n var popperAltOverflow = detectOverflow(state, {\n altBoundary: true\n });\n var referenceClippingOffsets = getSideOffsets(referenceOverflow, referenceRect);\n var popperEscapeOffsets = getSideOffsets(popperAltOverflow, popperRect, preventedOffsets);\n var isReferenceHidden = isAnySideFullyClipped(referenceClippingOffsets);\n var hasPopperEscaped = isAnySideFullyClipped(popperEscapeOffsets);\n state.modifiersData[name] = {\n referenceClippingOffsets: referenceClippingOffsets,\n popperEscapeOffsets: popperEscapeOffsets,\n isReferenceHidden: isReferenceHidden,\n hasPopperEscaped: hasPopperEscaped\n };\n state.attributes.popper = Object.assign({}, state.attributes.popper, {\n 'data-popper-reference-hidden': isReferenceHidden,\n 'data-popper-escaped': hasPopperEscaped\n });\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'hide',\n enabled: true,\n phase: 'main',\n requiresIfExists: ['preventOverflow'],\n fn: hide\n};","import getBasePlacement from \"../utils/getBasePlacement.js\";\nimport { top, left, right, placements } from \"../enums.js\"; // eslint-disable-next-line import/no-unused-modules\n\nexport function distanceAndSkiddingToXY(placement, rects, offset) {\n var basePlacement = getBasePlacement(placement);\n var invertDistance = [left, top].indexOf(basePlacement) >= 0 ? -1 : 1;\n\n var _ref = typeof offset === 'function' ? offset(Object.assign({}, rects, {\n placement: placement\n })) : offset,\n skidding = _ref[0],\n distance = _ref[1];\n\n skidding = skidding || 0;\n distance = (distance || 0) * invertDistance;\n return [left, right].indexOf(basePlacement) >= 0 ? {\n x: distance,\n y: skidding\n } : {\n x: skidding,\n y: distance\n };\n}\n\nfunction offset(_ref2) {\n var state = _ref2.state,\n options = _ref2.options,\n name = _ref2.name;\n var _options$offset = options.offset,\n offset = _options$offset === void 0 ? [0, 0] : _options$offset;\n var data = placements.reduce(function (acc, placement) {\n acc[placement] = distanceAndSkiddingToXY(placement, state.rects, offset);\n return acc;\n }, {});\n var _data$state$placement = data[state.placement],\n x = _data$state$placement.x,\n y = _data$state$placement.y;\n\n if (state.modifiersData.popperOffsets != null) {\n state.modifiersData.popperOffsets.x += x;\n state.modifiersData.popperOffsets.y += y;\n }\n\n state.modifiersData[name] = data;\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'offset',\n enabled: true,\n phase: 'main',\n requires: ['popperOffsets'],\n fn: offset\n};","import computeOffsets from \"../utils/computeOffsets.js\";\n\nfunction popperOffsets(_ref) {\n var state = _ref.state,\n name = _ref.name;\n // Offsets are the actual position the popper needs to have to be\n // properly positioned near its reference element\n // This is the most basic placement, and will be adjusted by\n // the modifiers in the next step\n state.modifiersData[name] = computeOffsets({\n reference: state.rects.reference,\n element: state.rects.popper,\n strategy: 'absolute',\n placement: state.placement\n });\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'popperOffsets',\n enabled: true,\n phase: 'read',\n fn: popperOffsets,\n data: {}\n};","export default function getAltAxis(axis) {\n return axis === 'x' ? 'y' : 'x';\n}","import { top, left, right, bottom, start } from \"../enums.js\";\nimport getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getMainAxisFromPlacement from \"../utils/getMainAxisFromPlacement.js\";\nimport getAltAxis from \"../utils/getAltAxis.js\";\nimport { within, withinMaxClamp } from \"../utils/within.js\";\nimport getLayoutRect from \"../dom-utils/getLayoutRect.js\";\nimport getOffsetParent from \"../dom-utils/getOffsetParent.js\";\nimport detectOverflow from \"../utils/detectOverflow.js\";\nimport getVariation from \"../utils/getVariation.js\";\nimport getFreshSideObject from \"../utils/getFreshSideObject.js\";\nimport { min as mathMin, max as mathMax } from \"../utils/math.js\";\n\nfunction preventOverflow(_ref) {\n var state = _ref.state,\n options = _ref.options,\n name = _ref.name;\n var _options$mainAxis = options.mainAxis,\n checkMainAxis = _options$mainAxis === void 0 ? true : _options$mainAxis,\n _options$altAxis = options.altAxis,\n checkAltAxis = _options$altAxis === void 0 ? false : _options$altAxis,\n boundary = options.boundary,\n rootBoundary = options.rootBoundary,\n altBoundary = options.altBoundary,\n padding = options.padding,\n _options$tether = options.tether,\n tether = _options$tether === void 0 ? true : _options$tether,\n _options$tetherOffset = options.tetherOffset,\n tetherOffset = _options$tetherOffset === void 0 ? 0 : _options$tetherOffset;\n var overflow = detectOverflow(state, {\n boundary: boundary,\n rootBoundary: rootBoundary,\n padding: padding,\n altBoundary: altBoundary\n });\n var basePlacement = getBasePlacement(state.placement);\n var variation = getVariation(state.placement);\n var isBasePlacement = !variation;\n var mainAxis = getMainAxisFromPlacement(basePlacement);\n var altAxis = getAltAxis(mainAxis);\n var popperOffsets = state.modifiersData.popperOffsets;\n var referenceRect = state.rects.reference;\n var popperRect = state.rects.popper;\n var tetherOffsetValue = typeof tetherOffset === 'function' ? tetherOffset(Object.assign({}, state.rects, {\n placement: state.placement\n })) : tetherOffset;\n var normalizedTetherOffsetValue = typeof tetherOffsetValue === 'number' ? {\n mainAxis: tetherOffsetValue,\n altAxis: tetherOffsetValue\n } : Object.assign({\n mainAxis: 0,\n altAxis: 0\n }, tetherOffsetValue);\n var offsetModifierState = state.modifiersData.offset ? state.modifiersData.offset[state.placement] : null;\n var data = {\n x: 0,\n y: 0\n };\n\n if (!popperOffsets) {\n return;\n }\n\n if (checkMainAxis) {\n var _offsetModifierState$;\n\n var mainSide = mainAxis === 'y' ? top : left;\n var altSide = mainAxis === 'y' ? bottom : right;\n var len = mainAxis === 'y' ? 'height' : 'width';\n var offset = popperOffsets[mainAxis];\n var min = offset + overflow[mainSide];\n var max = offset - overflow[altSide];\n var additive = tether ? -popperRect[len] / 2 : 0;\n var minLen = variation === start ? referenceRect[len] : popperRect[len];\n var maxLen = variation === start ? -popperRect[len] : -referenceRect[len]; // We need to include the arrow in the calculation so the arrow doesn't go\n // outside the reference bounds\n\n var arrowElement = state.elements.arrow;\n var arrowRect = tether && arrowElement ? getLayoutRect(arrowElement) : {\n width: 0,\n height: 0\n };\n var arrowPaddingObject = state.modifiersData['arrow#persistent'] ? state.modifiersData['arrow#persistent'].padding : getFreshSideObject();\n var arrowPaddingMin = arrowPaddingObject[mainSide];\n var arrowPaddingMax = arrowPaddingObject[altSide]; // If the reference length is smaller than the arrow length, we don't want\n // to include its full size in the calculation. If the reference is small\n // and near the edge of a boundary, the popper can overflow even if the\n // reference is not overflowing as well (e.g. virtual elements with no\n // width or height)\n\n var arrowLen = within(0, referenceRect[len], arrowRect[len]);\n var minOffset = isBasePlacement ? referenceRect[len] / 2 - additive - arrowLen - arrowPaddingMin - normalizedTetherOffsetValue.mainAxis : minLen - arrowLen - arrowPaddingMin - normalizedTetherOffsetValue.mainAxis;\n var maxOffset = isBasePlacement ? -referenceRect[len] / 2 + additive + arrowLen + arrowPaddingMax + normalizedTetherOffsetValue.mainAxis : maxLen + arrowLen + arrowPaddingMax + normalizedTetherOffsetValue.mainAxis;\n var arrowOffsetParent = state.elements.arrow && getOffsetParent(state.elements.arrow);\n var clientOffset = arrowOffsetParent ? mainAxis === 'y' ? arrowOffsetParent.clientTop || 0 : arrowOffsetParent.clientLeft || 0 : 0;\n var offsetModifierValue = (_offsetModifierState$ = offsetModifierState == null ? void 0 : offsetModifierState[mainAxis]) != null ? _offsetModifierState$ : 0;\n var tetherMin = offset + minOffset - offsetModifierValue - clientOffset;\n var tetherMax = offset + maxOffset - offsetModifierValue;\n var preventedOffset = within(tether ? mathMin(min, tetherMin) : min, offset, tether ? mathMax(max, tetherMax) : max);\n popperOffsets[mainAxis] = preventedOffset;\n data[mainAxis] = preventedOffset - offset;\n }\n\n if (checkAltAxis) {\n var _offsetModifierState$2;\n\n var _mainSide = mainAxis === 'x' ? top : left;\n\n var _altSide = mainAxis === 'x' ? bottom : right;\n\n var _offset = popperOffsets[altAxis];\n\n var _len = altAxis === 'y' ? 'height' : 'width';\n\n var _min = _offset + overflow[_mainSide];\n\n var _max = _offset - overflow[_altSide];\n\n var isOriginSide = [top, left].indexOf(basePlacement) !== -1;\n\n var _offsetModifierValue = (_offsetModifierState$2 = offsetModifierState == null ? void 0 : offsetModifierState[altAxis]) != null ? _offsetModifierState$2 : 0;\n\n var _tetherMin = isOriginSide ? _min : _offset - referenceRect[_len] - popperRect[_len] - _offsetModifierValue + normalizedTetherOffsetValue.altAxis;\n\n var _tetherMax = isOriginSide ? _offset + referenceRect[_len] + popperRect[_len] - _offsetModifierValue - normalizedTetherOffsetValue.altAxis : _max;\n\n var _preventedOffset = tether && isOriginSide ? withinMaxClamp(_tetherMin, _offset, _tetherMax) : within(tether ? _tetherMin : _min, _offset, tether ? _tetherMax : _max);\n\n popperOffsets[altAxis] = _preventedOffset;\n data[altAxis] = _preventedOffset - _offset;\n }\n\n state.modifiersData[name] = data;\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'preventOverflow',\n enabled: true,\n phase: 'main',\n fn: preventOverflow,\n requiresIfExists: ['offset']\n};","export default function getHTMLElementScroll(element) {\n return {\n scrollLeft: element.scrollLeft,\n scrollTop: element.scrollTop\n };\n}","import getWindowScroll from \"./getWindowScroll.js\";\nimport getWindow from \"./getWindow.js\";\nimport { isHTMLElement } from \"./instanceOf.js\";\nimport getHTMLElementScroll from \"./getHTMLElementScroll.js\";\nexport default function getNodeScroll(node) {\n if (node === getWindow(node) || !isHTMLElement(node)) {\n return getWindowScroll(node);\n } else {\n return getHTMLElementScroll(node);\n }\n}","import getBoundingClientRect from \"./getBoundingClientRect.js\";\nimport getNodeScroll from \"./getNodeScroll.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport { isHTMLElement } from \"./instanceOf.js\";\nimport getWindowScrollBarX from \"./getWindowScrollBarX.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport isScrollParent from \"./isScrollParent.js\";\nimport { round } from \"../utils/math.js\";\n\nfunction isElementScaled(element) {\n var rect = element.getBoundingClientRect();\n var scaleX = round(rect.width) / element.offsetWidth || 1;\n var scaleY = round(rect.height) / element.offsetHeight || 1;\n return scaleX !== 1 || scaleY !== 1;\n} // Returns the composite rect of an element relative to its offsetParent.\n// Composite means it takes into account transforms as well as layout.\n\n\nexport default function getCompositeRect(elementOrVirtualElement, offsetParent, isFixed) {\n if (isFixed === void 0) {\n isFixed = false;\n }\n\n var isOffsetParentAnElement = isHTMLElement(offsetParent);\n var offsetParentIsScaled = isHTMLElement(offsetParent) && isElementScaled(offsetParent);\n var documentElement = getDocumentElement(offsetParent);\n var rect = getBoundingClientRect(elementOrVirtualElement, offsetParentIsScaled, isFixed);\n var scroll = {\n scrollLeft: 0,\n scrollTop: 0\n };\n var offsets = {\n x: 0,\n y: 0\n };\n\n if (isOffsetParentAnElement || !isOffsetParentAnElement && !isFixed) {\n if (getNodeName(offsetParent) !== 'body' || // https://github.com/popperjs/popper-core/issues/1078\n isScrollParent(documentElement)) {\n scroll = getNodeScroll(offsetParent);\n }\n\n if (isHTMLElement(offsetParent)) {\n offsets = getBoundingClientRect(offsetParent, true);\n offsets.x += offsetParent.clientLeft;\n offsets.y += offsetParent.clientTop;\n } else if (documentElement) {\n offsets.x = getWindowScrollBarX(documentElement);\n }\n }\n\n return {\n x: rect.left + scroll.scrollLeft - offsets.x,\n y: rect.top + scroll.scrollTop - offsets.y,\n width: rect.width,\n height: rect.height\n };\n}","import { modifierPhases } from \"../enums.js\"; // source: https://stackoverflow.com/questions/49875255\n\nfunction order(modifiers) {\n var map = new Map();\n var visited = new Set();\n var result = [];\n modifiers.forEach(function (modifier) {\n map.set(modifier.name, modifier);\n }); // On visiting object, check for its dependencies and visit them recursively\n\n function sort(modifier) {\n visited.add(modifier.name);\n var requires = [].concat(modifier.requires || [], modifier.requiresIfExists || []);\n requires.forEach(function (dep) {\n if (!visited.has(dep)) {\n var depModifier = map.get(dep);\n\n if (depModifier) {\n sort(depModifier);\n }\n }\n });\n result.push(modifier);\n }\n\n modifiers.forEach(function (modifier) {\n if (!visited.has(modifier.name)) {\n // check for visited object\n sort(modifier);\n }\n });\n return result;\n}\n\nexport default function orderModifiers(modifiers) {\n // order based on dependencies\n var orderedModifiers = order(modifiers); // order based on phase\n\n return modifierPhases.reduce(function (acc, phase) {\n return acc.concat(orderedModifiers.filter(function (modifier) {\n return modifier.phase === phase;\n }));\n }, []);\n}","export default function debounce(fn) {\n var pending;\n return function () {\n if (!pending) {\n pending = new Promise(function (resolve) {\n Promise.resolve().then(function () {\n pending = undefined;\n resolve(fn());\n });\n });\n }\n\n return pending;\n };\n}","export default function mergeByName(modifiers) {\n var merged = modifiers.reduce(function (merged, current) {\n var existing = merged[current.name];\n merged[current.name] = existing ? Object.assign({}, existing, current, {\n options: Object.assign({}, existing.options, current.options),\n data: Object.assign({}, existing.data, current.data)\n }) : current;\n return merged;\n }, {}); // IE11 does not support Object.values\n\n return Object.keys(merged).map(function (key) {\n return merged[key];\n });\n}","import getCompositeRect from \"./dom-utils/getCompositeRect.js\";\nimport getLayoutRect from \"./dom-utils/getLayoutRect.js\";\nimport listScrollParents from \"./dom-utils/listScrollParents.js\";\nimport getOffsetParent from \"./dom-utils/getOffsetParent.js\";\nimport orderModifiers from \"./utils/orderModifiers.js\";\nimport debounce from \"./utils/debounce.js\";\nimport mergeByName from \"./utils/mergeByName.js\";\nimport detectOverflow from \"./utils/detectOverflow.js\";\nimport { isElement } from \"./dom-utils/instanceOf.js\";\nvar DEFAULT_OPTIONS = {\n placement: 'bottom',\n modifiers: [],\n strategy: 'absolute'\n};\n\nfunction areValidElements() {\n for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {\n args[_key] = arguments[_key];\n }\n\n return !args.some(function (element) {\n return !(element && typeof element.getBoundingClientRect === 'function');\n });\n}\n\nexport function popperGenerator(generatorOptions) {\n if (generatorOptions === void 0) {\n generatorOptions = {};\n }\n\n var _generatorOptions = generatorOptions,\n _generatorOptions$def = _generatorOptions.defaultModifiers,\n defaultModifiers = _generatorOptions$def === void 0 ? [] : _generatorOptions$def,\n _generatorOptions$def2 = _generatorOptions.defaultOptions,\n defaultOptions = _generatorOptions$def2 === void 0 ? DEFAULT_OPTIONS : _generatorOptions$def2;\n return function createPopper(reference, popper, options) {\n if (options === void 0) {\n options = defaultOptions;\n }\n\n var state = {\n placement: 'bottom',\n orderedModifiers: [],\n options: Object.assign({}, DEFAULT_OPTIONS, defaultOptions),\n modifiersData: {},\n elements: {\n reference: reference,\n popper: popper\n },\n attributes: {},\n styles: {}\n };\n var effectCleanupFns = [];\n var isDestroyed = false;\n var instance = {\n state: state,\n setOptions: function setOptions(setOptionsAction) {\n var options = typeof setOptionsAction === 'function' ? setOptionsAction(state.options) : setOptionsAction;\n cleanupModifierEffects();\n state.options = Object.assign({}, defaultOptions, state.options, options);\n state.scrollParents = {\n reference: isElement(reference) ? listScrollParents(reference) : reference.contextElement ? listScrollParents(reference.contextElement) : [],\n popper: listScrollParents(popper)\n }; // Orders the modifiers based on their dependencies and `phase`\n // properties\n\n var orderedModifiers = orderModifiers(mergeByName([].concat(defaultModifiers, state.options.modifiers))); // Strip out disabled modifiers\n\n state.orderedModifiers = orderedModifiers.filter(function (m) {\n return m.enabled;\n });\n runModifierEffects();\n return instance.update();\n },\n // Sync update – it will always be executed, even if not necessary. This\n // is useful for low frequency updates where sync behavior simplifies the\n // logic.\n // For high frequency updates (e.g. `resize` and `scroll` events), always\n // prefer the async Popper#update method\n forceUpdate: function forceUpdate() {\n if (isDestroyed) {\n return;\n }\n\n var _state$elements = state.elements,\n reference = _state$elements.reference,\n popper = _state$elements.popper; // Don't proceed if `reference` or `popper` are not valid elements\n // anymore\n\n if (!areValidElements(reference, popper)) {\n return;\n } // Store the reference and popper rects to be read by modifiers\n\n\n state.rects = {\n reference: getCompositeRect(reference, getOffsetParent(popper), state.options.strategy === 'fixed'),\n popper: getLayoutRect(popper)\n }; // Modifiers have the ability to reset the current update cycle. The\n // most common use case for this is the `flip` modifier changing the\n // placement, which then needs to re-run all the modifiers, because the\n // logic was previously ran for the previous placement and is therefore\n // stale/incorrect\n\n state.reset = false;\n state.placement = state.options.placement; // On each update cycle, the `modifiersData` property for each modifier\n // is filled with the initial data specified by the modifier. This means\n // it doesn't persist and is fresh on each update.\n // To ensure persistent data, use `${name}#persistent`\n\n state.orderedModifiers.forEach(function (modifier) {\n return state.modifiersData[modifier.name] = Object.assign({}, modifier.data);\n });\n\n for (var index = 0; index < state.orderedModifiers.length; index++) {\n if (state.reset === true) {\n state.reset = false;\n index = -1;\n continue;\n }\n\n var _state$orderedModifie = state.orderedModifiers[index],\n fn = _state$orderedModifie.fn,\n _state$orderedModifie2 = _state$orderedModifie.options,\n _options = _state$orderedModifie2 === void 0 ? {} : _state$orderedModifie2,\n name = _state$orderedModifie.name;\n\n if (typeof fn === 'function') {\n state = fn({\n state: state,\n options: _options,\n name: name,\n instance: instance\n }) || state;\n }\n }\n },\n // Async and optimistically optimized update – it will not be executed if\n // not necessary (debounced to run at most once-per-tick)\n update: debounce(function () {\n return new Promise(function (resolve) {\n instance.forceUpdate();\n resolve(state);\n });\n }),\n destroy: function destroy() {\n cleanupModifierEffects();\n isDestroyed = true;\n }\n };\n\n if (!areValidElements(reference, popper)) {\n return instance;\n }\n\n instance.setOptions(options).then(function (state) {\n if (!isDestroyed && options.onFirstUpdate) {\n options.onFirstUpdate(state);\n }\n }); // Modifiers have the ability to execute arbitrary code before the first\n // update cycle runs. They will be executed in the same order as the update\n // cycle. This is useful when a modifier adds some persistent data that\n // other modifiers need to use, but the modifier is run after the dependent\n // one.\n\n function runModifierEffects() {\n state.orderedModifiers.forEach(function (_ref) {\n var name = _ref.name,\n _ref$options = _ref.options,\n options = _ref$options === void 0 ? {} : _ref$options,\n effect = _ref.effect;\n\n if (typeof effect === 'function') {\n var cleanupFn = effect({\n state: state,\n name: name,\n instance: instance,\n options: options\n });\n\n var noopFn = function noopFn() {};\n\n effectCleanupFns.push(cleanupFn || noopFn);\n }\n });\n }\n\n function cleanupModifierEffects() {\n effectCleanupFns.forEach(function (fn) {\n return fn();\n });\n effectCleanupFns = [];\n }\n\n return instance;\n };\n}\nexport var createPopper = /*#__PURE__*/popperGenerator(); // eslint-disable-next-line import/no-unused-modules\n\nexport { detectOverflow };","import { popperGenerator, detectOverflow } from \"./createPopper.js\";\nimport eventListeners from \"./modifiers/eventListeners.js\";\nimport popperOffsets from \"./modifiers/popperOffsets.js\";\nimport computeStyles from \"./modifiers/computeStyles.js\";\nimport applyStyles from \"./modifiers/applyStyles.js\";\nimport offset from \"./modifiers/offset.js\";\nimport flip from \"./modifiers/flip.js\";\nimport preventOverflow from \"./modifiers/preventOverflow.js\";\nimport arrow from \"./modifiers/arrow.js\";\nimport hide from \"./modifiers/hide.js\";\nvar defaultModifiers = [eventListeners, popperOffsets, computeStyles, applyStyles, offset, flip, preventOverflow, arrow, hide];\nvar createPopper = /*#__PURE__*/popperGenerator({\n defaultModifiers: defaultModifiers\n}); // eslint-disable-next-line import/no-unused-modules\n\nexport { createPopper, popperGenerator, defaultModifiers, detectOverflow }; // eslint-disable-next-line import/no-unused-modules\n\nexport { createPopper as createPopperLite } from \"./popper-lite.js\"; // eslint-disable-next-line import/no-unused-modules\n\nexport * from \"./modifiers/index.js\";","import { generateUtilityClass } from '../generateUtilityClass';\nimport { generateUtilityClasses } from '../generateUtilityClasses';\nconst COMPONENT_NAME = 'Popper';\nexport function getPopperUtilityClass(slot) {\n return generateUtilityClass(COMPONENT_NAME, slot);\n}\nexport const popperClasses = generateUtilityClasses(COMPONENT_NAME, ['root']);","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"anchorEl\", \"children\", \"direction\", \"disablePortal\", \"modifiers\", \"open\", \"placement\", \"popperOptions\", \"popperRef\", \"slotProps\", \"slots\", \"TransitionProps\", \"ownerState\"],\n _excluded2 = [\"anchorEl\", \"children\", \"container\", \"direction\", \"disablePortal\", \"keepMounted\", \"modifiers\", \"open\", \"placement\", \"popperOptions\", \"popperRef\", \"style\", \"transition\", \"slotProps\", \"slots\"];\nimport * as React from 'react';\nimport { chainPropTypes, HTMLElementType, refType, unstable_ownerDocument as ownerDocument, unstable_useEnhancedEffect as useEnhancedEffect, unstable_useForkRef as useForkRef } from '@mui/utils';\nimport { createPopper } from '@popperjs/core';\nimport PropTypes from 'prop-types';\nimport { unstable_composeClasses as composeClasses } from '../composeClasses';\nimport { Portal } from '../Portal';\nimport { getPopperUtilityClass } from './popperClasses';\nimport { useSlotProps } from '../utils';\nimport { useClassNamesOverride } from '../utils/ClassNameConfigurator';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nfunction flipPlacement(placement, direction) {\n if (direction === 'ltr') {\n return placement;\n }\n switch (placement) {\n case 'bottom-end':\n return 'bottom-start';\n case 'bottom-start':\n return 'bottom-end';\n case 'top-end':\n return 'top-start';\n case 'top-start':\n return 'top-end';\n default:\n return placement;\n }\n}\nfunction resolveAnchorEl(anchorEl) {\n return typeof anchorEl === 'function' ? anchorEl() : anchorEl;\n}\nfunction isHTMLElement(element) {\n return element.nodeType !== undefined;\n}\nfunction isVirtualElement(element) {\n return !isHTMLElement(element);\n}\nconst useUtilityClasses = () => {\n const slots = {\n root: ['root']\n };\n return composeClasses(slots, useClassNamesOverride(getPopperUtilityClass));\n};\nconst defaultPopperOptions = {};\nconst PopperTooltip = /*#__PURE__*/React.forwardRef(function PopperTooltip(props, forwardedRef) {\n var _slots$root;\n const {\n anchorEl,\n children,\n direction,\n disablePortal,\n modifiers,\n open,\n placement: initialPlacement,\n popperOptions,\n popperRef: popperRefProp,\n slotProps = {},\n slots = {},\n TransitionProps\n // @ts-ignore internal logic\n // prevent from spreading to DOM, it can come from the parent component e.g. Select.\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const tooltipRef = React.useRef(null);\n const ownRef = useForkRef(tooltipRef, forwardedRef);\n const popperRef = React.useRef(null);\n const handlePopperRef = useForkRef(popperRef, popperRefProp);\n const handlePopperRefRef = React.useRef(handlePopperRef);\n useEnhancedEffect(() => {\n handlePopperRefRef.current = handlePopperRef;\n }, [handlePopperRef]);\n React.useImperativeHandle(popperRefProp, () => popperRef.current, []);\n const rtlPlacement = flipPlacement(initialPlacement, direction);\n /**\n * placement initialized from prop but can change during lifetime if modifiers.flip.\n * modifiers.flip is essentially a flip for controlled/uncontrolled behavior\n */\n const [placement, setPlacement] = React.useState(rtlPlacement);\n const [resolvedAnchorElement, setResolvedAnchorElement] = React.useState(resolveAnchorEl(anchorEl));\n React.useEffect(() => {\n if (popperRef.current) {\n popperRef.current.forceUpdate();\n }\n });\n React.useEffect(() => {\n if (anchorEl) {\n setResolvedAnchorElement(resolveAnchorEl(anchorEl));\n }\n }, [anchorEl]);\n useEnhancedEffect(() => {\n if (!resolvedAnchorElement || !open) {\n return undefined;\n }\n const handlePopperUpdate = data => {\n setPlacement(data.placement);\n };\n if (process.env.NODE_ENV !== 'production') {\n if (resolvedAnchorElement && isHTMLElement(resolvedAnchorElement) && resolvedAnchorElement.nodeType === 1) {\n const box = resolvedAnchorElement.getBoundingClientRect();\n if (process.env.NODE_ENV !== 'test' && box.top === 0 && box.left === 0 && box.right === 0 && box.bottom === 0) {\n console.warn(['MUI: The `anchorEl` prop provided to the component is invalid.', 'The anchor element should be part of the document layout.', \"Make sure the element is present in the document or that it's not display none.\"].join('\\n'));\n }\n }\n }\n let popperModifiers = [{\n name: 'preventOverflow',\n options: {\n altBoundary: disablePortal\n }\n }, {\n name: 'flip',\n options: {\n altBoundary: disablePortal\n }\n }, {\n name: 'onUpdate',\n enabled: true,\n phase: 'afterWrite',\n fn: ({\n state\n }) => {\n handlePopperUpdate(state);\n }\n }];\n if (modifiers != null) {\n popperModifiers = popperModifiers.concat(modifiers);\n }\n if (popperOptions && popperOptions.modifiers != null) {\n popperModifiers = popperModifiers.concat(popperOptions.modifiers);\n }\n const popper = createPopper(resolvedAnchorElement, tooltipRef.current, _extends({\n placement: rtlPlacement\n }, popperOptions, {\n modifiers: popperModifiers\n }));\n handlePopperRefRef.current(popper);\n return () => {\n popper.destroy();\n handlePopperRefRef.current(null);\n };\n }, [resolvedAnchorElement, disablePortal, modifiers, open, popperOptions, rtlPlacement]);\n const childProps = {\n placement: placement\n };\n if (TransitionProps !== null) {\n childProps.TransitionProps = TransitionProps;\n }\n const classes = useUtilityClasses();\n const Root = (_slots$root = slots.root) != null ? _slots$root : 'div';\n const rootProps = useSlotProps({\n elementType: Root,\n externalSlotProps: slotProps.root,\n externalForwardedProps: other,\n additionalProps: {\n role: 'tooltip',\n ref: ownRef\n },\n ownerState: props,\n className: classes.root\n });\n return /*#__PURE__*/_jsx(Root, _extends({}, rootProps, {\n children: typeof children === 'function' ? children(childProps) : children\n }));\n});\n\n/**\n * Poppers rely on the 3rd party library [Popper.js](https://popper.js.org/docs/v2/) for positioning.\n *\n * Demos:\n *\n * - [Popper](https://mui.com/base-ui/react-popper/)\n *\n * API:\n *\n * - [Popper API](https://mui.com/base-ui/react-popper/components-api/#popper)\n */\nconst Popper = /*#__PURE__*/React.forwardRef(function Popper(props, forwardedRef) {\n const {\n anchorEl,\n children,\n container: containerProp,\n direction = 'ltr',\n disablePortal = false,\n keepMounted = false,\n modifiers,\n open,\n placement = 'bottom',\n popperOptions = defaultPopperOptions,\n popperRef,\n style,\n transition = false,\n slotProps = {},\n slots = {}\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded2);\n const [exited, setExited] = React.useState(true);\n const handleEnter = () => {\n setExited(false);\n };\n const handleExited = () => {\n setExited(true);\n };\n if (!keepMounted && !open && (!transition || exited)) {\n return null;\n }\n\n // If the container prop is provided, use that\n // If the anchorEl prop is provided, use its parent body element as the container\n // If neither are provided let the Modal take care of choosing the container\n let container;\n if (containerProp) {\n container = containerProp;\n } else if (anchorEl) {\n const resolvedAnchorEl = resolveAnchorEl(anchorEl);\n container = resolvedAnchorEl && isHTMLElement(resolvedAnchorEl) ? ownerDocument(resolvedAnchorEl).body : ownerDocument(null).body;\n }\n const display = !open && keepMounted && (!transition || exited) ? 'none' : undefined;\n const transitionProps = transition ? {\n in: open,\n onEnter: handleEnter,\n onExited: handleExited\n } : undefined;\n return /*#__PURE__*/_jsx(Portal, {\n disablePortal: disablePortal,\n container: container,\n children: /*#__PURE__*/_jsx(PopperTooltip, _extends({\n anchorEl: anchorEl,\n direction: direction,\n disablePortal: disablePortal,\n modifiers: modifiers,\n ref: forwardedRef,\n open: transition ? !exited : open,\n placement: placement,\n popperOptions: popperOptions,\n popperRef: popperRef,\n slotProps: slotProps,\n slots: slots\n }, other, {\n style: _extends({\n // Prevents scroll issue, waiting for Popper.js to add this style once initiated.\n position: 'fixed',\n // Fix Popper.js display issue\n top: 0,\n left: 0,\n display\n }, style),\n TransitionProps: transitionProps,\n children: children\n }))\n });\n});\nprocess.env.NODE_ENV !== \"production\" ? Popper.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * An HTML element, [virtualElement](https://popper.js.org/docs/v2/virtual-elements/),\n * or a function that returns either.\n * It's used to set the position of the popper.\n * The return value will passed as the reference object of the Popper instance.\n */\n anchorEl: chainPropTypes(PropTypes.oneOfType([HTMLElementType, PropTypes.object, PropTypes.func]), props => {\n if (props.open) {\n const resolvedAnchorEl = resolveAnchorEl(props.anchorEl);\n if (resolvedAnchorEl && isHTMLElement(resolvedAnchorEl) && resolvedAnchorEl.nodeType === 1) {\n const box = resolvedAnchorEl.getBoundingClientRect();\n if (process.env.NODE_ENV !== 'test' && box.top === 0 && box.left === 0 && box.right === 0 && box.bottom === 0) {\n return new Error(['MUI: The `anchorEl` prop provided to the component is invalid.', 'The anchor element should be part of the document layout.', \"Make sure the element is present in the document or that it's not display none.\"].join('\\n'));\n }\n } else if (!resolvedAnchorEl || typeof resolvedAnchorEl.getBoundingClientRect !== 'function' || isVirtualElement(resolvedAnchorEl) && resolvedAnchorEl.contextElement != null && resolvedAnchorEl.contextElement.nodeType !== 1) {\n return new Error(['MUI: The `anchorEl` prop provided to the component is invalid.', 'It should be an HTML element instance or a virtualElement ', '(https://popper.js.org/docs/v2/virtual-elements/).'].join('\\n'));\n }\n }\n return null;\n }),\n /**\n * Popper render function or node.\n */\n children: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.node, PropTypes.func]),\n /**\n * An HTML element or function that returns one.\n * The `container` will have the portal children appended to it.\n *\n * You can also provide a callback, which is called in a React layout effect.\n * This lets you set the container from a ref, and also makes server-side rendering possible.\n *\n * By default, it uses the body of the top-level document object,\n * so it's simply `document.body` most of the time.\n */\n container: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.func]),\n /**\n * Direction of the text.\n * @default 'ltr'\n */\n direction: PropTypes.oneOf(['ltr', 'rtl']),\n /**\n * The `children` will be under the DOM hierarchy of the parent component.\n * @default false\n */\n disablePortal: PropTypes.bool,\n /**\n * Always keep the children in the DOM.\n * This prop can be useful in SEO situation or\n * when you want to maximize the responsiveness of the Popper.\n * @default false\n */\n keepMounted: PropTypes.bool,\n /**\n * Popper.js is based on a \"plugin-like\" architecture,\n * most of its features are fully encapsulated \"modifiers\".\n *\n * A modifier is a function that is called each time Popper.js needs to\n * compute the position of the popper.\n * For this reason, modifiers should be very performant to avoid bottlenecks.\n * To learn how to create a modifier, [read the modifiers documentation](https://popper.js.org/docs/v2/modifiers/).\n */\n modifiers: PropTypes.arrayOf(PropTypes.shape({\n data: PropTypes.object,\n effect: PropTypes.func,\n enabled: PropTypes.bool,\n fn: PropTypes.func,\n name: PropTypes.any,\n options: PropTypes.object,\n phase: PropTypes.oneOf(['afterMain', 'afterRead', 'afterWrite', 'beforeMain', 'beforeRead', 'beforeWrite', 'main', 'read', 'write']),\n requires: PropTypes.arrayOf(PropTypes.string),\n requiresIfExists: PropTypes.arrayOf(PropTypes.string)\n })),\n /**\n * If `true`, the component is shown.\n */\n open: PropTypes.bool.isRequired,\n /**\n * Popper placement.\n * @default 'bottom'\n */\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n /**\n * Options provided to the [`Popper.js`](https://popper.js.org/docs/v2/constructors/#options) instance.\n * @default {}\n */\n popperOptions: PropTypes.shape({\n modifiers: PropTypes.array,\n onFirstUpdate: PropTypes.func,\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n strategy: PropTypes.oneOf(['absolute', 'fixed'])\n }),\n /**\n * A ref that points to the used popper instance.\n */\n popperRef: refType,\n /**\n * The props used for each slot inside the Popper.\n * @default {}\n */\n slotProps: PropTypes.shape({\n root: PropTypes.oneOfType([PropTypes.func, PropTypes.object])\n }),\n /**\n * The components used for each slot inside the Popper.\n * Either a string to use a HTML element or a component.\n * @default {}\n */\n slots: PropTypes.shape({\n root: PropTypes.elementType\n }),\n /**\n * Help supporting a react-transition-group/Transition component.\n * @default false\n */\n transition: PropTypes.bool\n} : void 0;\nexport { Popper };","'use client';\n\nimport * as React from 'react';\nimport { useTheme as useThemeSystem } from '@mui/system';\nimport defaultTheme from './defaultTheme';\nimport THEME_ID from './identifier';\nexport default function useTheme() {\n const theme = useThemeSystem(defaultTheme);\n if (process.env.NODE_ENV !== 'production') {\n // eslint-disable-next-line react-hooks/rules-of-hooks\n React.useDebugValue(theme);\n }\n return theme[THEME_ID] || theme;\n}","export default function _setPrototypeOf(o, p) {\n _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function _setPrototypeOf(o, p) {\n o.__proto__ = p;\n return o;\n };\n return _setPrototypeOf(o, p);\n}","import setPrototypeOf from \"./setPrototypeOf.js\";\nexport default function _inheritsLoose(subClass, superClass) {\n subClass.prototype = Object.create(superClass.prototype);\n subClass.prototype.constructor = subClass;\n setPrototypeOf(subClass, superClass);\n}","export default {\n disabled: false\n};","import PropTypes from 'prop-types';\nexport var timeoutsShape = process.env.NODE_ENV !== 'production' ? PropTypes.oneOfType([PropTypes.number, PropTypes.shape({\n enter: PropTypes.number,\n exit: PropTypes.number,\n appear: PropTypes.number\n}).isRequired]) : null;\nexport var classNamesShape = process.env.NODE_ENV !== 'production' ? PropTypes.oneOfType([PropTypes.string, PropTypes.shape({\n enter: PropTypes.string,\n exit: PropTypes.string,\n active: PropTypes.string\n}), PropTypes.shape({\n enter: PropTypes.string,\n enterDone: PropTypes.string,\n enterActive: PropTypes.string,\n exit: PropTypes.string,\n exitDone: PropTypes.string,\n exitActive: PropTypes.string\n})]) : null;","import React from 'react';\nexport default React.createContext(null);","export var forceReflow = function forceReflow(node) {\n return node.scrollTop;\n};","import _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _inheritsLoose from \"@babel/runtime/helpers/esm/inheritsLoose\";\nimport PropTypes from 'prop-types';\nimport React from 'react';\nimport ReactDOM from 'react-dom';\nimport config from './config';\nimport { timeoutsShape } from './utils/PropTypes';\nimport TransitionGroupContext from './TransitionGroupContext';\nimport { forceReflow } from './utils/reflow';\nexport var UNMOUNTED = 'unmounted';\nexport var EXITED = 'exited';\nexport var ENTERING = 'entering';\nexport var ENTERED = 'entered';\nexport var EXITING = 'exiting';\n/**\n * The Transition component lets you describe a transition from one component\n * state to another _over time_ with a simple declarative API. Most commonly\n * it's used to animate the mounting and unmounting of a component, but can also\n * be used to describe in-place transition states as well.\n *\n * ---\n *\n * **Note**: `Transition` is a platform-agnostic base component. If you're using\n * transitions in CSS, you'll probably want to use\n * [`CSSTransition`](https://reactcommunity.org/react-transition-group/css-transition)\n * instead. It inherits all the features of `Transition`, but contains\n * additional features necessary to play nice with CSS transitions (hence the\n * name of the component).\n *\n * ---\n *\n * By default the `Transition` component does not alter the behavior of the\n * component it renders, it only tracks \"enter\" and \"exit\" states for the\n * components. It's up to you to give meaning and effect to those states. For\n * example we can add styles to a component when it enters or exits:\n *\n * ```jsx\n * import { Transition } from 'react-transition-group';\n *\n * const duration = 300;\n *\n * const defaultStyle = {\n * transition: `opacity ${duration}ms ease-in-out`,\n * opacity: 0,\n * }\n *\n * const transitionStyles = {\n * entering: { opacity: 1 },\n * entered: { opacity: 1 },\n * exiting: { opacity: 0 },\n * exited: { opacity: 0 },\n * };\n *\n * const Fade = ({ in: inProp }) => (\n * \n * {state => (\n *
    \n * I'm a fade Transition!\n *
    \n * )}\n *
    \n * );\n * ```\n *\n * There are 4 main states a Transition can be in:\n * - `'entering'`\n * - `'entered'`\n * - `'exiting'`\n * - `'exited'`\n *\n * Transition state is toggled via the `in` prop. When `true` the component\n * begins the \"Enter\" stage. During this stage, the component will shift from\n * its current transition state, to `'entering'` for the duration of the\n * transition and then to the `'entered'` stage once it's complete. Let's take\n * the following example (we'll use the\n * [useState](https://reactjs.org/docs/hooks-reference.html#usestate) hook):\n *\n * ```jsx\n * function App() {\n * const [inProp, setInProp] = useState(false);\n * return (\n *
    \n * \n * {state => (\n * // ...\n * )}\n * \n * \n *
    \n * );\n * }\n * ```\n *\n * When the button is clicked the component will shift to the `'entering'` state\n * and stay there for 500ms (the value of `timeout`) before it finally switches\n * to `'entered'`.\n *\n * When `in` is `false` the same thing happens except the state moves from\n * `'exiting'` to `'exited'`.\n */\n\nvar Transition = /*#__PURE__*/function (_React$Component) {\n _inheritsLoose(Transition, _React$Component);\n\n function Transition(props, context) {\n var _this;\n\n _this = _React$Component.call(this, props, context) || this;\n var parentGroup = context; // In the context of a TransitionGroup all enters are really appears\n\n var appear = parentGroup && !parentGroup.isMounting ? props.enter : props.appear;\n var initialStatus;\n _this.appearStatus = null;\n\n if (props.in) {\n if (appear) {\n initialStatus = EXITED;\n _this.appearStatus = ENTERING;\n } else {\n initialStatus = ENTERED;\n }\n } else {\n if (props.unmountOnExit || props.mountOnEnter) {\n initialStatus = UNMOUNTED;\n } else {\n initialStatus = EXITED;\n }\n }\n\n _this.state = {\n status: initialStatus\n };\n _this.nextCallback = null;\n return _this;\n }\n\n Transition.getDerivedStateFromProps = function getDerivedStateFromProps(_ref, prevState) {\n var nextIn = _ref.in;\n\n if (nextIn && prevState.status === UNMOUNTED) {\n return {\n status: EXITED\n };\n }\n\n return null;\n } // getSnapshotBeforeUpdate(prevProps) {\n // let nextStatus = null\n // if (prevProps !== this.props) {\n // const { status } = this.state\n // if (this.props.in) {\n // if (status !== ENTERING && status !== ENTERED) {\n // nextStatus = ENTERING\n // }\n // } else {\n // if (status === ENTERING || status === ENTERED) {\n // nextStatus = EXITING\n // }\n // }\n // }\n // return { nextStatus }\n // }\n ;\n\n var _proto = Transition.prototype;\n\n _proto.componentDidMount = function componentDidMount() {\n this.updateStatus(true, this.appearStatus);\n };\n\n _proto.componentDidUpdate = function componentDidUpdate(prevProps) {\n var nextStatus = null;\n\n if (prevProps !== this.props) {\n var status = this.state.status;\n\n if (this.props.in) {\n if (status !== ENTERING && status !== ENTERED) {\n nextStatus = ENTERING;\n }\n } else {\n if (status === ENTERING || status === ENTERED) {\n nextStatus = EXITING;\n }\n }\n }\n\n this.updateStatus(false, nextStatus);\n };\n\n _proto.componentWillUnmount = function componentWillUnmount() {\n this.cancelNextCallback();\n };\n\n _proto.getTimeouts = function getTimeouts() {\n var timeout = this.props.timeout;\n var exit, enter, appear;\n exit = enter = appear = timeout;\n\n if (timeout != null && typeof timeout !== 'number') {\n exit = timeout.exit;\n enter = timeout.enter; // TODO: remove fallback for next major\n\n appear = timeout.appear !== undefined ? timeout.appear : enter;\n }\n\n return {\n exit: exit,\n enter: enter,\n appear: appear\n };\n };\n\n _proto.updateStatus = function updateStatus(mounting, nextStatus) {\n if (mounting === void 0) {\n mounting = false;\n }\n\n if (nextStatus !== null) {\n // nextStatus will always be ENTERING or EXITING.\n this.cancelNextCallback();\n\n if (nextStatus === ENTERING) {\n if (this.props.unmountOnExit || this.props.mountOnEnter) {\n var node = this.props.nodeRef ? this.props.nodeRef.current : ReactDOM.findDOMNode(this); // https://github.com/reactjs/react-transition-group/pull/749\n // With unmountOnExit or mountOnEnter, the enter animation should happen at the transition between `exited` and `entering`.\n // To make the animation happen, we have to separate each rendering and avoid being processed as batched.\n\n if (node) forceReflow(node);\n }\n\n this.performEnter(mounting);\n } else {\n this.performExit();\n }\n } else if (this.props.unmountOnExit && this.state.status === EXITED) {\n this.setState({\n status: UNMOUNTED\n });\n }\n };\n\n _proto.performEnter = function performEnter(mounting) {\n var _this2 = this;\n\n var enter = this.props.enter;\n var appearing = this.context ? this.context.isMounting : mounting;\n\n var _ref2 = this.props.nodeRef ? [appearing] : [ReactDOM.findDOMNode(this), appearing],\n maybeNode = _ref2[0],\n maybeAppearing = _ref2[1];\n\n var timeouts = this.getTimeouts();\n var enterTimeout = appearing ? timeouts.appear : timeouts.enter; // no enter animation skip right to ENTERED\n // if we are mounting and running this it means appear _must_ be set\n\n if (!mounting && !enter || config.disabled) {\n this.safeSetState({\n status: ENTERED\n }, function () {\n _this2.props.onEntered(maybeNode);\n });\n return;\n }\n\n this.props.onEnter(maybeNode, maybeAppearing);\n this.safeSetState({\n status: ENTERING\n }, function () {\n _this2.props.onEntering(maybeNode, maybeAppearing);\n\n _this2.onTransitionEnd(enterTimeout, function () {\n _this2.safeSetState({\n status: ENTERED\n }, function () {\n _this2.props.onEntered(maybeNode, maybeAppearing);\n });\n });\n });\n };\n\n _proto.performExit = function performExit() {\n var _this3 = this;\n\n var exit = this.props.exit;\n var timeouts = this.getTimeouts();\n var maybeNode = this.props.nodeRef ? undefined : ReactDOM.findDOMNode(this); // no exit animation skip right to EXITED\n\n if (!exit || config.disabled) {\n this.safeSetState({\n status: EXITED\n }, function () {\n _this3.props.onExited(maybeNode);\n });\n return;\n }\n\n this.props.onExit(maybeNode);\n this.safeSetState({\n status: EXITING\n }, function () {\n _this3.props.onExiting(maybeNode);\n\n _this3.onTransitionEnd(timeouts.exit, function () {\n _this3.safeSetState({\n status: EXITED\n }, function () {\n _this3.props.onExited(maybeNode);\n });\n });\n });\n };\n\n _proto.cancelNextCallback = function cancelNextCallback() {\n if (this.nextCallback !== null) {\n this.nextCallback.cancel();\n this.nextCallback = null;\n }\n };\n\n _proto.safeSetState = function safeSetState(nextState, callback) {\n // This shouldn't be necessary, but there are weird race conditions with\n // setState callbacks and unmounting in testing, so always make sure that\n // we can cancel any pending setState callbacks after we unmount.\n callback = this.setNextCallback(callback);\n this.setState(nextState, callback);\n };\n\n _proto.setNextCallback = function setNextCallback(callback) {\n var _this4 = this;\n\n var active = true;\n\n this.nextCallback = function (event) {\n if (active) {\n active = false;\n _this4.nextCallback = null;\n callback(event);\n }\n };\n\n this.nextCallback.cancel = function () {\n active = false;\n };\n\n return this.nextCallback;\n };\n\n _proto.onTransitionEnd = function onTransitionEnd(timeout, handler) {\n this.setNextCallback(handler);\n var node = this.props.nodeRef ? this.props.nodeRef.current : ReactDOM.findDOMNode(this);\n var doesNotHaveTimeoutOrListener = timeout == null && !this.props.addEndListener;\n\n if (!node || doesNotHaveTimeoutOrListener) {\n setTimeout(this.nextCallback, 0);\n return;\n }\n\n if (this.props.addEndListener) {\n var _ref3 = this.props.nodeRef ? [this.nextCallback] : [node, this.nextCallback],\n maybeNode = _ref3[0],\n maybeNextCallback = _ref3[1];\n\n this.props.addEndListener(maybeNode, maybeNextCallback);\n }\n\n if (timeout != null) {\n setTimeout(this.nextCallback, timeout);\n }\n };\n\n _proto.render = function render() {\n var status = this.state.status;\n\n if (status === UNMOUNTED) {\n return null;\n }\n\n var _this$props = this.props,\n children = _this$props.children,\n _in = _this$props.in,\n _mountOnEnter = _this$props.mountOnEnter,\n _unmountOnExit = _this$props.unmountOnExit,\n _appear = _this$props.appear,\n _enter = _this$props.enter,\n _exit = _this$props.exit,\n _timeout = _this$props.timeout,\n _addEndListener = _this$props.addEndListener,\n _onEnter = _this$props.onEnter,\n _onEntering = _this$props.onEntering,\n _onEntered = _this$props.onEntered,\n _onExit = _this$props.onExit,\n _onExiting = _this$props.onExiting,\n _onExited = _this$props.onExited,\n _nodeRef = _this$props.nodeRef,\n childProps = _objectWithoutPropertiesLoose(_this$props, [\"children\", \"in\", \"mountOnEnter\", \"unmountOnExit\", \"appear\", \"enter\", \"exit\", \"timeout\", \"addEndListener\", \"onEnter\", \"onEntering\", \"onEntered\", \"onExit\", \"onExiting\", \"onExited\", \"nodeRef\"]);\n\n return (\n /*#__PURE__*/\n // allows for nested Transitions\n React.createElement(TransitionGroupContext.Provider, {\n value: null\n }, typeof children === 'function' ? children(status, childProps) : React.cloneElement(React.Children.only(children), childProps))\n );\n };\n\n return Transition;\n}(React.Component);\n\nTransition.contextType = TransitionGroupContext;\nTransition.propTypes = process.env.NODE_ENV !== \"production\" ? {\n /**\n * A React reference to DOM element that need to transition:\n * https://stackoverflow.com/a/51127130/4671932\n *\n * - When `nodeRef` prop is used, `node` is not passed to callback functions\n * (e.g. `onEnter`) because user already has direct access to the node.\n * - When changing `key` prop of `Transition` in a `TransitionGroup` a new\n * `nodeRef` need to be provided to `Transition` with changed `key` prop\n * (see\n * [test/CSSTransition-test.js](https://github.com/reactjs/react-transition-group/blob/13435f897b3ab71f6e19d724f145596f5910581c/test/CSSTransition-test.js#L362-L437)).\n */\n nodeRef: PropTypes.shape({\n current: typeof Element === 'undefined' ? PropTypes.any : function (propValue, key, componentName, location, propFullName, secret) {\n var value = propValue[key];\n return PropTypes.instanceOf(value && 'ownerDocument' in value ? value.ownerDocument.defaultView.Element : Element)(propValue, key, componentName, location, propFullName, secret);\n }\n }),\n\n /**\n * A `function` child can be used instead of a React element. This function is\n * called with the current transition status (`'entering'`, `'entered'`,\n * `'exiting'`, `'exited'`), which can be used to apply context\n * specific props to a component.\n *\n * ```jsx\n * \n * {state => (\n * \n * )}\n * \n * ```\n */\n children: PropTypes.oneOfType([PropTypes.func.isRequired, PropTypes.element.isRequired]).isRequired,\n\n /**\n * Show the component; triggers the enter or exit states\n */\n in: PropTypes.bool,\n\n /**\n * By default the child component is mounted immediately along with\n * the parent `Transition` component. If you want to \"lazy mount\" the component on the\n * first `in={true}` you can set `mountOnEnter`. After the first enter transition the component will stay\n * mounted, even on \"exited\", unless you also specify `unmountOnExit`.\n */\n mountOnEnter: PropTypes.bool,\n\n /**\n * By default the child component stays mounted after it reaches the `'exited'` state.\n * Set `unmountOnExit` if you'd prefer to unmount the component after it finishes exiting.\n */\n unmountOnExit: PropTypes.bool,\n\n /**\n * By default the child component does not perform the enter transition when\n * it first mounts, regardless of the value of `in`. If you want this\n * behavior, set both `appear` and `in` to `true`.\n *\n * > **Note**: there are no special appear states like `appearing`/`appeared`, this prop\n * > only adds an additional enter transition. However, in the\n * > `` component that first enter transition does result in\n * > additional `.appear-*` classes, that way you can choose to style it\n * > differently.\n */\n appear: PropTypes.bool,\n\n /**\n * Enable or disable enter transitions.\n */\n enter: PropTypes.bool,\n\n /**\n * Enable or disable exit transitions.\n */\n exit: PropTypes.bool,\n\n /**\n * The duration of the transition, in milliseconds.\n * Required unless `addEndListener` is provided.\n *\n * You may specify a single timeout for all transitions:\n *\n * ```jsx\n * timeout={500}\n * ```\n *\n * or individually:\n *\n * ```jsx\n * timeout={{\n * appear: 500,\n * enter: 300,\n * exit: 500,\n * }}\n * ```\n *\n * - `appear` defaults to the value of `enter`\n * - `enter` defaults to `0`\n * - `exit` defaults to `0`\n *\n * @type {number | { enter?: number, exit?: number, appear?: number }}\n */\n timeout: function timeout(props) {\n var pt = timeoutsShape;\n if (!props.addEndListener) pt = pt.isRequired;\n\n for (var _len = arguments.length, args = new Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) {\n args[_key - 1] = arguments[_key];\n }\n\n return pt.apply(void 0, [props].concat(args));\n },\n\n /**\n * Add a custom transition end trigger. Called with the transitioning\n * DOM node and a `done` callback. Allows for more fine grained transition end\n * logic. Timeouts are still used as a fallback if provided.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * ```jsx\n * addEndListener={(node, done) => {\n * // use the css transitionend event to mark the finish of a transition\n * node.addEventListener('transitionend', done, false);\n * }}\n * ```\n */\n addEndListener: PropTypes.func,\n\n /**\n * Callback fired before the \"entering\" status is applied. An extra parameter\n * `isAppearing` is supplied to indicate if the enter stage is occurring on the initial mount\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement, isAppearing: bool) -> void\n */\n onEnter: PropTypes.func,\n\n /**\n * Callback fired after the \"entering\" status is applied. An extra parameter\n * `isAppearing` is supplied to indicate if the enter stage is occurring on the initial mount\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement, isAppearing: bool)\n */\n onEntering: PropTypes.func,\n\n /**\n * Callback fired after the \"entered\" status is applied. An extra parameter\n * `isAppearing` is supplied to indicate if the enter stage is occurring on the initial mount\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement, isAppearing: bool) -> void\n */\n onEntered: PropTypes.func,\n\n /**\n * Callback fired before the \"exiting\" status is applied.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement) -> void\n */\n onExit: PropTypes.func,\n\n /**\n * Callback fired after the \"exiting\" status is applied.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement) -> void\n */\n onExiting: PropTypes.func,\n\n /**\n * Callback fired after the \"exited\" status is applied.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed\n *\n * @type Function(node: HtmlElement) -> void\n */\n onExited: PropTypes.func\n} : {}; // Name the function so it is clearer in the documentation\n\nfunction noop() {}\n\nTransition.defaultProps = {\n in: false,\n mountOnEnter: false,\n unmountOnExit: false,\n appear: false,\n enter: true,\n exit: true,\n onEnter: noop,\n onEntering: noop,\n onEntered: noop,\n onExit: noop,\n onExiting: noop,\n onExited: noop\n};\nTransition.UNMOUNTED = UNMOUNTED;\nTransition.EXITED = EXITED;\nTransition.ENTERING = ENTERING;\nTransition.ENTERED = ENTERED;\nTransition.EXITING = EXITING;\nexport default Transition;","export const reflow = node => node.scrollTop;\nexport function getTransitionProps(props, options) {\n var _style$transitionDura, _style$transitionTimi;\n const {\n timeout,\n easing,\n style = {}\n } = props;\n return {\n duration: (_style$transitionDura = style.transitionDuration) != null ? _style$transitionDura : typeof timeout === 'number' ? timeout : timeout[options.mode] || 0,\n easing: (_style$transitionTimi = style.transitionTimingFunction) != null ? _style$transitionTimi : typeof easing === 'object' ? easing[options.mode] : easing,\n delay: style.transitionDelay\n };\n}","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"addEndListener\", \"appear\", \"children\", \"easing\", \"in\", \"onEnter\", \"onEntered\", \"onEntering\", \"onExit\", \"onExited\", \"onExiting\", \"style\", \"timeout\", \"TransitionComponent\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport { elementAcceptingRef, unstable_useTimeout as useTimeout } from '@mui/utils';\nimport { Transition } from 'react-transition-group';\nimport useTheme from '../styles/useTheme';\nimport { getTransitionProps, reflow } from '../transitions/utils';\nimport useForkRef from '../utils/useForkRef';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nfunction getScale(value) {\n return `scale(${value}, ${value ** 2})`;\n}\nconst styles = {\n entering: {\n opacity: 1,\n transform: getScale(1)\n },\n entered: {\n opacity: 1,\n transform: 'none'\n }\n};\n\n/*\n TODO v6: remove\n Conditionally apply a workaround for the CSS transition bug in Safari 15.4 / WebKit browsers.\n */\nconst isWebKit154 = typeof navigator !== 'undefined' && /^((?!chrome|android).)*(safari|mobile)/i.test(navigator.userAgent) && /(os |version\\/)15(.|_)4/i.test(navigator.userAgent);\n\n/**\n * The Grow transition is used by the [Tooltip](/material-ui/react-tooltip/) and\n * [Popover](/material-ui/react-popover/) components.\n * It uses [react-transition-group](https://github.com/reactjs/react-transition-group) internally.\n */\nconst Grow = /*#__PURE__*/React.forwardRef(function Grow(props, ref) {\n const {\n addEndListener,\n appear = true,\n children,\n easing,\n in: inProp,\n onEnter,\n onEntered,\n onEntering,\n onExit,\n onExited,\n onExiting,\n style,\n timeout = 'auto',\n // eslint-disable-next-line react/prop-types\n TransitionComponent = Transition\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const timer = useTimeout();\n const autoTimeout = React.useRef();\n const theme = useTheme();\n const nodeRef = React.useRef(null);\n const handleRef = useForkRef(nodeRef, children.ref, ref);\n const normalizedTransitionCallback = callback => maybeIsAppearing => {\n if (callback) {\n const node = nodeRef.current;\n\n // onEnterXxx and onExitXxx callbacks have a different arguments.length value.\n if (maybeIsAppearing === undefined) {\n callback(node);\n } else {\n callback(node, maybeIsAppearing);\n }\n }\n };\n const handleEntering = normalizedTransitionCallback(onEntering);\n const handleEnter = normalizedTransitionCallback((node, isAppearing) => {\n reflow(node); // So the animation always start from the start.\n\n const {\n duration: transitionDuration,\n delay,\n easing: transitionTimingFunction\n } = getTransitionProps({\n style,\n timeout,\n easing\n }, {\n mode: 'enter'\n });\n let duration;\n if (timeout === 'auto') {\n duration = theme.transitions.getAutoHeightDuration(node.clientHeight);\n autoTimeout.current = duration;\n } else {\n duration = transitionDuration;\n }\n node.style.transition = [theme.transitions.create('opacity', {\n duration,\n delay\n }), theme.transitions.create('transform', {\n duration: isWebKit154 ? duration : duration * 0.666,\n delay,\n easing: transitionTimingFunction\n })].join(',');\n if (onEnter) {\n onEnter(node, isAppearing);\n }\n });\n const handleEntered = normalizedTransitionCallback(onEntered);\n const handleExiting = normalizedTransitionCallback(onExiting);\n const handleExit = normalizedTransitionCallback(node => {\n const {\n duration: transitionDuration,\n delay,\n easing: transitionTimingFunction\n } = getTransitionProps({\n style,\n timeout,\n easing\n }, {\n mode: 'exit'\n });\n let duration;\n if (timeout === 'auto') {\n duration = theme.transitions.getAutoHeightDuration(node.clientHeight);\n autoTimeout.current = duration;\n } else {\n duration = transitionDuration;\n }\n node.style.transition = [theme.transitions.create('opacity', {\n duration,\n delay\n }), theme.transitions.create('transform', {\n duration: isWebKit154 ? duration : duration * 0.666,\n delay: isWebKit154 ? delay : delay || duration * 0.333,\n easing: transitionTimingFunction\n })].join(',');\n node.style.opacity = 0;\n node.style.transform = getScale(0.75);\n if (onExit) {\n onExit(node);\n }\n });\n const handleExited = normalizedTransitionCallback(onExited);\n const handleAddEndListener = next => {\n if (timeout === 'auto') {\n timer.start(autoTimeout.current || 0, next);\n }\n if (addEndListener) {\n // Old call signature before `react-transition-group` implemented `nodeRef`\n addEndListener(nodeRef.current, next);\n }\n };\n return /*#__PURE__*/_jsx(TransitionComponent, _extends({\n appear: appear,\n in: inProp,\n nodeRef: nodeRef,\n onEnter: handleEnter,\n onEntered: handleEntered,\n onEntering: handleEntering,\n onExit: handleExit,\n onExited: handleExited,\n onExiting: handleExiting,\n addEndListener: handleAddEndListener,\n timeout: timeout === 'auto' ? null : timeout\n }, other, {\n children: (state, childProps) => {\n return /*#__PURE__*/React.cloneElement(children, _extends({\n style: _extends({\n opacity: 0,\n transform: getScale(0.75),\n visibility: state === 'exited' && !inProp ? 'hidden' : undefined\n }, styles[state], style, children.props.style),\n ref: handleRef\n }, childProps));\n }\n }));\n});\nprocess.env.NODE_ENV !== \"production\" ? Grow.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the d.ts file and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * Add a custom transition end trigger. Called with the transitioning DOM\n * node and a done callback. Allows for more fine grained transition end\n * logic. Note: Timeouts are still used as a fallback if provided.\n */\n addEndListener: PropTypes.func,\n /**\n * Perform the enter transition when it first mounts if `in` is also `true`.\n * Set this to `false` to disable this behavior.\n * @default true\n */\n appear: PropTypes.bool,\n /**\n * A single child content element.\n */\n children: elementAcceptingRef.isRequired,\n /**\n * The transition timing function.\n * You may specify a single easing or a object containing enter and exit values.\n */\n easing: PropTypes.oneOfType([PropTypes.shape({\n enter: PropTypes.string,\n exit: PropTypes.string\n }), PropTypes.string]),\n /**\n * If `true`, the component will transition in.\n */\n in: PropTypes.bool,\n /**\n * @ignore\n */\n onEnter: PropTypes.func,\n /**\n * @ignore\n */\n onEntered: PropTypes.func,\n /**\n * @ignore\n */\n onEntering: PropTypes.func,\n /**\n * @ignore\n */\n onExit: PropTypes.func,\n /**\n * @ignore\n */\n onExited: PropTypes.func,\n /**\n * @ignore\n */\n onExiting: PropTypes.func,\n /**\n * @ignore\n */\n style: PropTypes.object,\n /**\n * The duration for the transition, in milliseconds.\n * You may specify a single timeout for all transitions, or individually with an object.\n *\n * Set to 'auto' to automatically calculate transition time based on height.\n * @default 'auto'\n */\n timeout: PropTypes.oneOfType([PropTypes.oneOf(['auto']), PropTypes.number, PropTypes.shape({\n appear: PropTypes.number,\n enter: PropTypes.number,\n exit: PropTypes.number\n })])\n} : void 0;\nGrow.muiSupportAuto = true;\nexport default Grow;","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"anchorEl\", \"component\", \"components\", \"componentsProps\", \"container\", \"disablePortal\", \"keepMounted\", \"modifiers\", \"open\", \"placement\", \"popperOptions\", \"popperRef\", \"transition\", \"slots\", \"slotProps\"];\nimport { Popper as BasePopper } from '@mui/base/Popper';\nimport { useThemeWithoutDefault as useTheme } from '@mui/system';\nimport { HTMLElementType, refType } from '@mui/utils';\nimport PropTypes from 'prop-types';\nimport * as React from 'react';\nimport { styled, useThemeProps } from '../styles';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nconst PopperRoot = styled(BasePopper, {\n name: 'MuiPopper',\n slot: 'Root',\n overridesResolver: (props, styles) => styles.root\n})({});\n\n/**\n *\n * Demos:\n *\n * - [Autocomplete](https://mui.com/material-ui/react-autocomplete/)\n * - [Menu](https://mui.com/material-ui/react-menu/)\n * - [Popper](https://mui.com/material-ui/react-popper/)\n *\n * API:\n *\n * - [Popper API](https://mui.com/material-ui/api/popper/)\n */\nconst Popper = /*#__PURE__*/React.forwardRef(function Popper(inProps, ref) {\n var _slots$root;\n const theme = useTheme();\n const props = useThemeProps({\n props: inProps,\n name: 'MuiPopper'\n });\n const {\n anchorEl,\n component,\n components,\n componentsProps,\n container,\n disablePortal,\n keepMounted,\n modifiers,\n open,\n placement,\n popperOptions,\n popperRef,\n transition,\n slots,\n slotProps\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const RootComponent = (_slots$root = slots == null ? void 0 : slots.root) != null ? _slots$root : components == null ? void 0 : components.Root;\n const otherProps = _extends({\n anchorEl,\n container,\n disablePortal,\n keepMounted,\n modifiers,\n open,\n placement,\n popperOptions,\n popperRef,\n transition\n }, other);\n return /*#__PURE__*/_jsx(PopperRoot, _extends({\n as: component,\n direction: theme == null ? void 0 : theme.direction,\n slots: {\n root: RootComponent\n },\n slotProps: slotProps != null ? slotProps : componentsProps\n }, otherProps, {\n ref: ref\n }));\n});\nprocess.env.NODE_ENV !== \"production\" ? Popper.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * An HTML element, [virtualElement](https://popper.js.org/docs/v2/virtual-elements/),\n * or a function that returns either.\n * It's used to set the position of the popper.\n * The return value will passed as the reference object of the Popper instance.\n */\n anchorEl: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.object, PropTypes.func]),\n /**\n * Popper render function or node.\n */\n children: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.node, PropTypes.func]),\n /**\n * The component used for the root node.\n * Either a string to use a HTML element or a component.\n */\n component: PropTypes.elementType,\n /**\n * The components used for each slot inside the Popper.\n * Either a string to use a HTML element or a component.\n * @default {}\n */\n components: PropTypes.shape({\n Root: PropTypes.elementType\n }),\n /**\n * The props used for each slot inside the Popper.\n * @default {}\n */\n componentsProps: PropTypes.shape({\n root: PropTypes.oneOfType([PropTypes.func, PropTypes.object])\n }),\n /**\n * An HTML element or function that returns one.\n * The `container` will have the portal children appended to it.\n *\n * You can also provide a callback, which is called in a React layout effect.\n * This lets you set the container from a ref, and also makes server-side rendering possible.\n *\n * By default, it uses the body of the top-level document object,\n * so it's simply `document.body` most of the time.\n */\n container: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.func]),\n /**\n * The `children` will be under the DOM hierarchy of the parent component.\n * @default false\n */\n disablePortal: PropTypes.bool,\n /**\n * Always keep the children in the DOM.\n * This prop can be useful in SEO situation or\n * when you want to maximize the responsiveness of the Popper.\n * @default false\n */\n keepMounted: PropTypes.bool,\n /**\n * Popper.js is based on a \"plugin-like\" architecture,\n * most of its features are fully encapsulated \"modifiers\".\n *\n * A modifier is a function that is called each time Popper.js needs to\n * compute the position of the popper.\n * For this reason, modifiers should be very performant to avoid bottlenecks.\n * To learn how to create a modifier, [read the modifiers documentation](https://popper.js.org/docs/v2/modifiers/).\n */\n modifiers: PropTypes.arrayOf(PropTypes.shape({\n data: PropTypes.object,\n effect: PropTypes.func,\n enabled: PropTypes.bool,\n fn: PropTypes.func,\n name: PropTypes.any,\n options: PropTypes.object,\n phase: PropTypes.oneOf(['afterMain', 'afterRead', 'afterWrite', 'beforeMain', 'beforeRead', 'beforeWrite', 'main', 'read', 'write']),\n requires: PropTypes.arrayOf(PropTypes.string),\n requiresIfExists: PropTypes.arrayOf(PropTypes.string)\n })),\n /**\n * If `true`, the component is shown.\n */\n open: PropTypes.bool.isRequired,\n /**\n * Popper placement.\n * @default 'bottom'\n */\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n /**\n * Options provided to the [`Popper.js`](https://popper.js.org/docs/v2/constructors/#options) instance.\n * @default {}\n */\n popperOptions: PropTypes.shape({\n modifiers: PropTypes.array,\n onFirstUpdate: PropTypes.func,\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n strategy: PropTypes.oneOf(['absolute', 'fixed'])\n }),\n /**\n * A ref that points to the used popper instance.\n */\n popperRef: refType,\n /**\n * The props used for each slot inside the Popper.\n * @default {}\n */\n slotProps: PropTypes.shape({\n root: PropTypes.oneOfType([PropTypes.func, PropTypes.object])\n }),\n /**\n * The components used for each slot inside the Popper.\n * Either a string to use a HTML element or a component.\n * @default {}\n */\n slots: PropTypes.shape({\n root: PropTypes.elementType\n }),\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Help supporting a react-transition-group/Transition component.\n * @default false\n */\n transition: PropTypes.bool\n} : void 0;\nexport default Popper;","import generateUtilityClasses from '@mui/utils/generateUtilityClasses';\nimport generateUtilityClass from '@mui/utils/generateUtilityClass';\nexport function getTooltipUtilityClass(slot) {\n return generateUtilityClass('MuiTooltip', slot);\n}\nconst tooltipClasses = generateUtilityClasses('MuiTooltip', ['popper', 'popperInteractive', 'popperArrow', 'popperClose', 'tooltip', 'tooltipArrow', 'touch', 'tooltipPlacementLeft', 'tooltipPlacementRight', 'tooltipPlacementTop', 'tooltipPlacementBottom', 'arrow']);\nexport default tooltipClasses;","'use client';\n\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nconst _excluded = [\"arrow\", \"children\", \"classes\", \"components\", \"componentsProps\", \"describeChild\", \"disableFocusListener\", \"disableHoverListener\", \"disableInteractive\", \"disableTouchListener\", \"enterDelay\", \"enterNextDelay\", \"enterTouchDelay\", \"followCursor\", \"id\", \"leaveDelay\", \"leaveTouchDelay\", \"onClose\", \"onOpen\", \"open\", \"placement\", \"PopperComponent\", \"PopperProps\", \"slotProps\", \"slots\", \"title\", \"TransitionComponent\", \"TransitionProps\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport clsx from 'clsx';\nimport { elementAcceptingRef, unstable_useTimeout as useTimeout, unstable_Timeout as Timeout } from '@mui/utils';\nimport { unstable_composeClasses as composeClasses, appendOwnerState } from '@mui/base';\nimport { alpha } from '@mui/system';\nimport styled from '../styles/styled';\nimport useTheme from '../styles/useTheme';\nimport useThemeProps from '../styles/useThemeProps';\nimport capitalize from '../utils/capitalize';\nimport Grow from '../Grow';\nimport Popper from '../Popper';\nimport useEventCallback from '../utils/useEventCallback';\nimport useForkRef from '../utils/useForkRef';\nimport useId from '../utils/useId';\nimport useIsFocusVisible from '../utils/useIsFocusVisible';\nimport useControlled from '../utils/useControlled';\nimport tooltipClasses, { getTooltipUtilityClass } from './tooltipClasses';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nimport { jsxs as _jsxs } from \"react/jsx-runtime\";\nfunction round(value) {\n return Math.round(value * 1e5) / 1e5;\n}\nconst useUtilityClasses = ownerState => {\n const {\n classes,\n disableInteractive,\n arrow,\n touch,\n placement\n } = ownerState;\n const slots = {\n popper: ['popper', !disableInteractive && 'popperInteractive', arrow && 'popperArrow'],\n tooltip: ['tooltip', arrow && 'tooltipArrow', touch && 'touch', `tooltipPlacement${capitalize(placement.split('-')[0])}`],\n arrow: ['arrow']\n };\n return composeClasses(slots, getTooltipUtilityClass, classes);\n};\nconst TooltipPopper = styled(Popper, {\n name: 'MuiTooltip',\n slot: 'Popper',\n overridesResolver: (props, styles) => {\n const {\n ownerState\n } = props;\n return [styles.popper, !ownerState.disableInteractive && styles.popperInteractive, ownerState.arrow && styles.popperArrow, !ownerState.open && styles.popperClose];\n }\n})(({\n theme,\n ownerState,\n open\n}) => _extends({\n zIndex: (theme.vars || theme).zIndex.tooltip,\n pointerEvents: 'none'\n}, !ownerState.disableInteractive && {\n pointerEvents: 'auto'\n}, !open && {\n pointerEvents: 'none'\n}, ownerState.arrow && {\n [`&[data-popper-placement*=\"bottom\"] .${tooltipClasses.arrow}`]: {\n top: 0,\n marginTop: '-0.71em',\n '&::before': {\n transformOrigin: '0 100%'\n }\n },\n [`&[data-popper-placement*=\"top\"] .${tooltipClasses.arrow}`]: {\n bottom: 0,\n marginBottom: '-0.71em',\n '&::before': {\n transformOrigin: '100% 0'\n }\n },\n [`&[data-popper-placement*=\"right\"] .${tooltipClasses.arrow}`]: _extends({}, !ownerState.isRtl ? {\n left: 0,\n marginLeft: '-0.71em'\n } : {\n right: 0,\n marginRight: '-0.71em'\n }, {\n height: '1em',\n width: '0.71em',\n '&::before': {\n transformOrigin: '100% 100%'\n }\n }),\n [`&[data-popper-placement*=\"left\"] .${tooltipClasses.arrow}`]: _extends({}, !ownerState.isRtl ? {\n right: 0,\n marginRight: '-0.71em'\n } : {\n left: 0,\n marginLeft: '-0.71em'\n }, {\n height: '1em',\n width: '0.71em',\n '&::before': {\n transformOrigin: '0 0'\n }\n })\n}));\nconst TooltipTooltip = styled('div', {\n name: 'MuiTooltip',\n slot: 'Tooltip',\n overridesResolver: (props, styles) => {\n const {\n ownerState\n } = props;\n return [styles.tooltip, ownerState.touch && styles.touch, ownerState.arrow && styles.tooltipArrow, styles[`tooltipPlacement${capitalize(ownerState.placement.split('-')[0])}`]];\n }\n})(({\n theme,\n ownerState\n}) => _extends({\n backgroundColor: theme.vars ? theme.vars.palette.Tooltip.bg : alpha(theme.palette.grey[700], 0.92),\n borderRadius: (theme.vars || theme).shape.borderRadius,\n color: (theme.vars || theme).palette.common.white,\n fontFamily: theme.typography.fontFamily,\n padding: '4px 8px',\n fontSize: theme.typography.pxToRem(11),\n maxWidth: 300,\n margin: 2,\n wordWrap: 'break-word',\n fontWeight: theme.typography.fontWeightMedium\n}, ownerState.arrow && {\n position: 'relative',\n margin: 0\n}, ownerState.touch && {\n padding: '8px 16px',\n fontSize: theme.typography.pxToRem(14),\n lineHeight: `${round(16 / 14)}em`,\n fontWeight: theme.typography.fontWeightRegular\n}, {\n [`.${tooltipClasses.popper}[data-popper-placement*=\"left\"] &`]: _extends({\n transformOrigin: 'right center'\n }, !ownerState.isRtl ? _extends({\n marginRight: '14px'\n }, ownerState.touch && {\n marginRight: '24px'\n }) : _extends({\n marginLeft: '14px'\n }, ownerState.touch && {\n marginLeft: '24px'\n })),\n [`.${tooltipClasses.popper}[data-popper-placement*=\"right\"] &`]: _extends({\n transformOrigin: 'left center'\n }, !ownerState.isRtl ? _extends({\n marginLeft: '14px'\n }, ownerState.touch && {\n marginLeft: '24px'\n }) : _extends({\n marginRight: '14px'\n }, ownerState.touch && {\n marginRight: '24px'\n })),\n [`.${tooltipClasses.popper}[data-popper-placement*=\"top\"] &`]: _extends({\n transformOrigin: 'center bottom',\n marginBottom: '14px'\n }, ownerState.touch && {\n marginBottom: '24px'\n }),\n [`.${tooltipClasses.popper}[data-popper-placement*=\"bottom\"] &`]: _extends({\n transformOrigin: 'center top',\n marginTop: '14px'\n }, ownerState.touch && {\n marginTop: '24px'\n })\n}));\nconst TooltipArrow = styled('span', {\n name: 'MuiTooltip',\n slot: 'Arrow',\n overridesResolver: (props, styles) => styles.arrow\n})(({\n theme\n}) => ({\n overflow: 'hidden',\n position: 'absolute',\n width: '1em',\n height: '0.71em' /* = width / sqrt(2) = (length of the hypotenuse) */,\n boxSizing: 'border-box',\n color: theme.vars ? theme.vars.palette.Tooltip.bg : alpha(theme.palette.grey[700], 0.9),\n '&::before': {\n content: '\"\"',\n margin: 'auto',\n display: 'block',\n width: '100%',\n height: '100%',\n backgroundColor: 'currentColor',\n transform: 'rotate(45deg)'\n }\n}));\nlet hystersisOpen = false;\nconst hystersisTimer = new Timeout();\nlet cursorPosition = {\n x: 0,\n y: 0\n};\nexport function testReset() {\n hystersisOpen = false;\n hystersisTimer.clear();\n}\nfunction composeEventHandler(handler, eventHandler) {\n return event => {\n if (eventHandler) {\n eventHandler(event);\n }\n handler(event);\n };\n}\n\n// TODO v6: Remove PopperComponent, PopperProps, TransitionComponent and TransitionProps.\nconst Tooltip = /*#__PURE__*/React.forwardRef(function Tooltip(inProps, ref) {\n var _ref, _slots$popper, _ref2, _ref3, _slots$transition, _ref4, _slots$tooltip, _ref5, _slots$arrow, _slotProps$popper, _ref6, _slotProps$popper2, _slotProps$transition, _slotProps$tooltip, _ref7, _slotProps$tooltip2, _slotProps$arrow, _ref8, _slotProps$arrow2;\n const props = useThemeProps({\n props: inProps,\n name: 'MuiTooltip'\n });\n const {\n arrow = false,\n children: childrenProp,\n components = {},\n componentsProps = {},\n describeChild = false,\n disableFocusListener = false,\n disableHoverListener = false,\n disableInteractive: disableInteractiveProp = false,\n disableTouchListener = false,\n enterDelay = 100,\n enterNextDelay = 0,\n enterTouchDelay = 700,\n followCursor = false,\n id: idProp,\n leaveDelay = 0,\n leaveTouchDelay = 1500,\n onClose,\n onOpen,\n open: openProp,\n placement = 'bottom',\n PopperComponent: PopperComponentProp,\n PopperProps = {},\n slotProps = {},\n slots = {},\n title,\n TransitionComponent: TransitionComponentProp = Grow,\n TransitionProps\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n\n // to prevent runtime errors, developers will need to provide a child as a React element anyway.\n const children = /*#__PURE__*/React.isValidElement(childrenProp) ? childrenProp : /*#__PURE__*/_jsx(\"span\", {\n children: childrenProp\n });\n const theme = useTheme();\n const isRtl = theme.direction === 'rtl';\n const [childNode, setChildNode] = React.useState();\n const [arrowRef, setArrowRef] = React.useState(null);\n const ignoreNonTouchEvents = React.useRef(false);\n const disableInteractive = disableInteractiveProp || followCursor;\n const closeTimer = useTimeout();\n const enterTimer = useTimeout();\n const leaveTimer = useTimeout();\n const touchTimer = useTimeout();\n const [openState, setOpenState] = useControlled({\n controlled: openProp,\n default: false,\n name: 'Tooltip',\n state: 'open'\n });\n let open = openState;\n if (process.env.NODE_ENV !== 'production') {\n // eslint-disable-next-line react-hooks/rules-of-hooks\n const {\n current: isControlled\n } = React.useRef(openProp !== undefined);\n\n // eslint-disable-next-line react-hooks/rules-of-hooks\n React.useEffect(() => {\n if (childNode && childNode.disabled && !isControlled && title !== '' && childNode.tagName.toLowerCase() === 'button') {\n console.error(['MUI: You are providing a disabled `button` child to the Tooltip component.', 'A disabled element does not fire events.', \"Tooltip needs to listen to the child element's events to display the title.\", '', 'Add a simple wrapper element, such as a `span`.'].join('\\n'));\n }\n }, [title, childNode, isControlled]);\n }\n const id = useId(idProp);\n const prevUserSelect = React.useRef();\n const stopTouchInteraction = useEventCallback(() => {\n if (prevUserSelect.current !== undefined) {\n document.body.style.WebkitUserSelect = prevUserSelect.current;\n prevUserSelect.current = undefined;\n }\n touchTimer.clear();\n });\n React.useEffect(() => stopTouchInteraction, [stopTouchInteraction]);\n const handleOpen = event => {\n hystersisTimer.clear();\n hystersisOpen = true;\n\n // The mouseover event will trigger for every nested element in the tooltip.\n // We can skip rerendering when the tooltip is already open.\n // We are using the mouseover event instead of the mouseenter event to fix a hide/show issue.\n setOpenState(true);\n if (onOpen && !open) {\n onOpen(event);\n }\n };\n const handleClose = useEventCallback(\n /**\n * @param {React.SyntheticEvent | Event} event\n */\n event => {\n hystersisTimer.start(800 + leaveDelay, () => {\n hystersisOpen = false;\n });\n setOpenState(false);\n if (onClose && open) {\n onClose(event);\n }\n closeTimer.start(theme.transitions.duration.shortest, () => {\n ignoreNonTouchEvents.current = false;\n });\n });\n const handleEnter = event => {\n if (ignoreNonTouchEvents.current && event.type !== 'touchstart') {\n return;\n }\n\n // Remove the title ahead of time.\n // We don't want to wait for the next render commit.\n // We would risk displaying two tooltips at the same time (native + this one).\n if (childNode) {\n childNode.removeAttribute('title');\n }\n enterTimer.clear();\n leaveTimer.clear();\n if (enterDelay || hystersisOpen && enterNextDelay) {\n enterTimer.start(hystersisOpen ? enterNextDelay : enterDelay, () => {\n handleOpen(event);\n });\n } else {\n handleOpen(event);\n }\n };\n const handleLeave = event => {\n enterTimer.clear();\n leaveTimer.start(leaveDelay, () => {\n handleClose(event);\n });\n };\n const {\n isFocusVisibleRef,\n onBlur: handleBlurVisible,\n onFocus: handleFocusVisible,\n ref: focusVisibleRef\n } = useIsFocusVisible();\n // We don't necessarily care about the focusVisible state (which is safe to access via ref anyway).\n // We just need to re-render the Tooltip if the focus-visible state changes.\n const [, setChildIsFocusVisible] = React.useState(false);\n const handleBlur = event => {\n handleBlurVisible(event);\n if (isFocusVisibleRef.current === false) {\n setChildIsFocusVisible(false);\n handleLeave(event);\n }\n };\n const handleFocus = event => {\n // Workaround for https://github.com/facebook/react/issues/7769\n // The autoFocus of React might trigger the event before the componentDidMount.\n // We need to account for this eventuality.\n if (!childNode) {\n setChildNode(event.currentTarget);\n }\n handleFocusVisible(event);\n if (isFocusVisibleRef.current === true) {\n setChildIsFocusVisible(true);\n handleEnter(event);\n }\n };\n const detectTouchStart = event => {\n ignoreNonTouchEvents.current = true;\n const childrenProps = children.props;\n if (childrenProps.onTouchStart) {\n childrenProps.onTouchStart(event);\n }\n };\n const handleMouseOver = handleEnter;\n const handleMouseLeave = handleLeave;\n const handleTouchStart = event => {\n detectTouchStart(event);\n leaveTimer.clear();\n closeTimer.clear();\n stopTouchInteraction();\n prevUserSelect.current = document.body.style.WebkitUserSelect;\n // Prevent iOS text selection on long-tap.\n document.body.style.WebkitUserSelect = 'none';\n touchTimer.start(enterTouchDelay, () => {\n document.body.style.WebkitUserSelect = prevUserSelect.current;\n handleEnter(event);\n });\n };\n const handleTouchEnd = event => {\n if (children.props.onTouchEnd) {\n children.props.onTouchEnd(event);\n }\n stopTouchInteraction();\n leaveTimer.start(leaveTouchDelay, () => {\n handleClose(event);\n });\n };\n React.useEffect(() => {\n if (!open) {\n return undefined;\n }\n\n /**\n * @param {KeyboardEvent} nativeEvent\n */\n function handleKeyDown(nativeEvent) {\n // IE11, Edge (prior to using Bink?) use 'Esc'\n if (nativeEvent.key === 'Escape' || nativeEvent.key === 'Esc') {\n handleClose(nativeEvent);\n }\n }\n document.addEventListener('keydown', handleKeyDown);\n return () => {\n document.removeEventListener('keydown', handleKeyDown);\n };\n }, [handleClose, open]);\n const handleRef = useForkRef(children.ref, focusVisibleRef, setChildNode, ref);\n\n // There is no point in displaying an empty tooltip.\n // So we exclude all falsy values, except 0, which is valid.\n if (!title && title !== 0) {\n open = false;\n }\n const popperRef = React.useRef();\n const handleMouseMove = event => {\n const childrenProps = children.props;\n if (childrenProps.onMouseMove) {\n childrenProps.onMouseMove(event);\n }\n cursorPosition = {\n x: event.clientX,\n y: event.clientY\n };\n if (popperRef.current) {\n popperRef.current.update();\n }\n };\n const nameOrDescProps = {};\n const titleIsString = typeof title === 'string';\n if (describeChild) {\n nameOrDescProps.title = !open && titleIsString && !disableHoverListener ? title : null;\n nameOrDescProps['aria-describedby'] = open ? id : null;\n } else {\n nameOrDescProps['aria-label'] = titleIsString ? title : null;\n nameOrDescProps['aria-labelledby'] = open && !titleIsString ? id : null;\n }\n const childrenProps = _extends({}, nameOrDescProps, other, children.props, {\n className: clsx(other.className, children.props.className),\n onTouchStart: detectTouchStart,\n ref: handleRef\n }, followCursor ? {\n onMouseMove: handleMouseMove\n } : {});\n if (process.env.NODE_ENV !== 'production') {\n childrenProps['data-mui-internal-clone-element'] = true;\n\n // eslint-disable-next-line react-hooks/rules-of-hooks\n React.useEffect(() => {\n if (childNode && !childNode.getAttribute('data-mui-internal-clone-element')) {\n console.error(['MUI: The `children` component of the Tooltip is not forwarding its props correctly.', 'Please make sure that props are spread on the same element that the ref is applied to.'].join('\\n'));\n }\n }, [childNode]);\n }\n const interactiveWrapperListeners = {};\n if (!disableTouchListener) {\n childrenProps.onTouchStart = handleTouchStart;\n childrenProps.onTouchEnd = handleTouchEnd;\n }\n if (!disableHoverListener) {\n childrenProps.onMouseOver = composeEventHandler(handleMouseOver, childrenProps.onMouseOver);\n childrenProps.onMouseLeave = composeEventHandler(handleMouseLeave, childrenProps.onMouseLeave);\n if (!disableInteractive) {\n interactiveWrapperListeners.onMouseOver = handleMouseOver;\n interactiveWrapperListeners.onMouseLeave = handleMouseLeave;\n }\n }\n if (!disableFocusListener) {\n childrenProps.onFocus = composeEventHandler(handleFocus, childrenProps.onFocus);\n childrenProps.onBlur = composeEventHandler(handleBlur, childrenProps.onBlur);\n if (!disableInteractive) {\n interactiveWrapperListeners.onFocus = handleFocus;\n interactiveWrapperListeners.onBlur = handleBlur;\n }\n }\n if (process.env.NODE_ENV !== 'production') {\n if (children.props.title) {\n console.error(['MUI: You have provided a `title` prop to the child of .', `Remove this title prop \\`${children.props.title}\\` or the Tooltip component.`].join('\\n'));\n }\n }\n const popperOptions = React.useMemo(() => {\n var _PopperProps$popperOp;\n let tooltipModifiers = [{\n name: 'arrow',\n enabled: Boolean(arrowRef),\n options: {\n element: arrowRef,\n padding: 4\n }\n }];\n if ((_PopperProps$popperOp = PopperProps.popperOptions) != null && _PopperProps$popperOp.modifiers) {\n tooltipModifiers = tooltipModifiers.concat(PopperProps.popperOptions.modifiers);\n }\n return _extends({}, PopperProps.popperOptions, {\n modifiers: tooltipModifiers\n });\n }, [arrowRef, PopperProps]);\n const ownerState = _extends({}, props, {\n isRtl,\n arrow,\n disableInteractive,\n placement,\n PopperComponentProp,\n touch: ignoreNonTouchEvents.current\n });\n const classes = useUtilityClasses(ownerState);\n const PopperComponent = (_ref = (_slots$popper = slots.popper) != null ? _slots$popper : components.Popper) != null ? _ref : TooltipPopper;\n const TransitionComponent = (_ref2 = (_ref3 = (_slots$transition = slots.transition) != null ? _slots$transition : components.Transition) != null ? _ref3 : TransitionComponentProp) != null ? _ref2 : Grow;\n const TooltipComponent = (_ref4 = (_slots$tooltip = slots.tooltip) != null ? _slots$tooltip : components.Tooltip) != null ? _ref4 : TooltipTooltip;\n const ArrowComponent = (_ref5 = (_slots$arrow = slots.arrow) != null ? _slots$arrow : components.Arrow) != null ? _ref5 : TooltipArrow;\n const popperProps = appendOwnerState(PopperComponent, _extends({}, PopperProps, (_slotProps$popper = slotProps.popper) != null ? _slotProps$popper : componentsProps.popper, {\n className: clsx(classes.popper, PopperProps == null ? void 0 : PopperProps.className, (_ref6 = (_slotProps$popper2 = slotProps.popper) != null ? _slotProps$popper2 : componentsProps.popper) == null ? void 0 : _ref6.className)\n }), ownerState);\n const transitionProps = appendOwnerState(TransitionComponent, _extends({}, TransitionProps, (_slotProps$transition = slotProps.transition) != null ? _slotProps$transition : componentsProps.transition), ownerState);\n const tooltipProps = appendOwnerState(TooltipComponent, _extends({}, (_slotProps$tooltip = slotProps.tooltip) != null ? _slotProps$tooltip : componentsProps.tooltip, {\n className: clsx(classes.tooltip, (_ref7 = (_slotProps$tooltip2 = slotProps.tooltip) != null ? _slotProps$tooltip2 : componentsProps.tooltip) == null ? void 0 : _ref7.className)\n }), ownerState);\n const tooltipArrowProps = appendOwnerState(ArrowComponent, _extends({}, (_slotProps$arrow = slotProps.arrow) != null ? _slotProps$arrow : componentsProps.arrow, {\n className: clsx(classes.arrow, (_ref8 = (_slotProps$arrow2 = slotProps.arrow) != null ? _slotProps$arrow2 : componentsProps.arrow) == null ? void 0 : _ref8.className)\n }), ownerState);\n return /*#__PURE__*/_jsxs(React.Fragment, {\n children: [/*#__PURE__*/React.cloneElement(children, childrenProps), /*#__PURE__*/_jsx(PopperComponent, _extends({\n as: PopperComponentProp != null ? PopperComponentProp : Popper,\n placement: placement,\n anchorEl: followCursor ? {\n getBoundingClientRect: () => ({\n top: cursorPosition.y,\n left: cursorPosition.x,\n right: cursorPosition.x,\n bottom: cursorPosition.y,\n width: 0,\n height: 0\n })\n } : childNode,\n popperRef: popperRef,\n open: childNode ? open : false,\n id: id,\n transition: true\n }, interactiveWrapperListeners, popperProps, {\n popperOptions: popperOptions,\n children: ({\n TransitionProps: TransitionPropsInner\n }) => /*#__PURE__*/_jsx(TransitionComponent, _extends({\n timeout: theme.transitions.duration.shorter\n }, TransitionPropsInner, transitionProps, {\n children: /*#__PURE__*/_jsxs(TooltipComponent, _extends({}, tooltipProps, {\n children: [title, arrow ? /*#__PURE__*/_jsx(ArrowComponent, _extends({}, tooltipArrowProps, {\n ref: setArrowRef\n })) : null]\n }))\n }))\n }))]\n });\n});\nprocess.env.NODE_ENV !== \"production\" ? Tooltip.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the d.ts file and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * If `true`, adds an arrow to the tooltip.\n * @default false\n */\n arrow: PropTypes.bool,\n /**\n * Tooltip reference element.\n */\n children: elementAcceptingRef.isRequired,\n /**\n * Override or extend the styles applied to the component.\n */\n classes: PropTypes.object,\n /**\n * @ignore\n */\n className: PropTypes.string,\n /**\n * The components used for each slot inside.\n *\n * This prop is an alias for the `slots` prop.\n * It's recommended to use the `slots` prop instead.\n *\n * @default {}\n */\n components: PropTypes.shape({\n Arrow: PropTypes.elementType,\n Popper: PropTypes.elementType,\n Tooltip: PropTypes.elementType,\n Transition: PropTypes.elementType\n }),\n /**\n * The extra props for the slot components.\n * You can override the existing props or add new ones.\n *\n * This prop is an alias for the `slotProps` prop.\n * It's recommended to use the `slotProps` prop instead, as `componentsProps` will be deprecated in the future.\n *\n * @default {}\n */\n componentsProps: PropTypes.shape({\n arrow: PropTypes.object,\n popper: PropTypes.object,\n tooltip: PropTypes.object,\n transition: PropTypes.object\n }),\n /**\n * Set to `true` if the `title` acts as an accessible description.\n * By default the `title` acts as an accessible label for the child.\n * @default false\n */\n describeChild: PropTypes.bool,\n /**\n * Do not respond to focus-visible events.\n * @default false\n */\n disableFocusListener: PropTypes.bool,\n /**\n * Do not respond to hover events.\n * @default false\n */\n disableHoverListener: PropTypes.bool,\n /**\n * Makes a tooltip not interactive, i.e. it will close when the user\n * hovers over the tooltip before the `leaveDelay` is expired.\n * @default false\n */\n disableInteractive: PropTypes.bool,\n /**\n * Do not respond to long press touch events.\n * @default false\n */\n disableTouchListener: PropTypes.bool,\n /**\n * The number of milliseconds to wait before showing the tooltip.\n * This prop won't impact the enter touch delay (`enterTouchDelay`).\n * @default 100\n */\n enterDelay: PropTypes.number,\n /**\n * The number of milliseconds to wait before showing the tooltip when one was already recently opened.\n * @default 0\n */\n enterNextDelay: PropTypes.number,\n /**\n * The number of milliseconds a user must touch the element before showing the tooltip.\n * @default 700\n */\n enterTouchDelay: PropTypes.number,\n /**\n * If `true`, the tooltip follow the cursor over the wrapped element.\n * @default false\n */\n followCursor: PropTypes.bool,\n /**\n * This prop is used to help implement the accessibility logic.\n * If you don't provide this prop. It falls back to a randomly generated id.\n */\n id: PropTypes.string,\n /**\n * The number of milliseconds to wait before hiding the tooltip.\n * This prop won't impact the leave touch delay (`leaveTouchDelay`).\n * @default 0\n */\n leaveDelay: PropTypes.number,\n /**\n * The number of milliseconds after the user stops touching an element before hiding the tooltip.\n * @default 1500\n */\n leaveTouchDelay: PropTypes.number,\n /**\n * Callback fired when the component requests to be closed.\n *\n * @param {React.SyntheticEvent} event The event source of the callback.\n */\n onClose: PropTypes.func,\n /**\n * Callback fired when the component requests to be open.\n *\n * @param {React.SyntheticEvent} event The event source of the callback.\n */\n onOpen: PropTypes.func,\n /**\n * If `true`, the component is shown.\n */\n open: PropTypes.bool,\n /**\n * Tooltip placement.\n * @default 'bottom'\n */\n placement: PropTypes.oneOf(['bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n /**\n * The component used for the popper.\n * @default Popper\n */\n PopperComponent: PropTypes.elementType,\n /**\n * Props applied to the [`Popper`](/material-ui/api/popper/) element.\n * @default {}\n */\n PopperProps: PropTypes.object,\n /**\n * The extra props for the slot components.\n * You can override the existing props or add new ones.\n *\n * This prop is an alias for the `componentsProps` prop, which will be deprecated in the future.\n *\n * @default {}\n */\n slotProps: PropTypes.shape({\n arrow: PropTypes.object,\n popper: PropTypes.object,\n tooltip: PropTypes.object,\n transition: PropTypes.object\n }),\n /**\n * The components used for each slot inside.\n *\n * This prop is an alias for the `components` prop, which will be deprecated in the future.\n *\n * @default {}\n */\n slots: PropTypes.shape({\n arrow: PropTypes.elementType,\n popper: PropTypes.elementType,\n tooltip: PropTypes.elementType,\n transition: PropTypes.elementType\n }),\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Tooltip title. Zero-length titles string, undefined, null and false are never displayed.\n */\n title: PropTypes.node,\n /**\n * The component used for the transition.\n * [Follow this guide](/material-ui/transitions/#transitioncomponent-prop) to learn more about the requirements for this component.\n * @default Grow\n */\n TransitionComponent: PropTypes.elementType,\n /**\n * Props applied to the transition element.\n * By default, the element is based on this [`Transition`](http://reactcommunity.org/react-transition-group/transition/) component.\n */\n TransitionProps: PropTypes.object\n} : void 0;\nexport default Tooltip;","import '@/components/mui/menu-item.component.css';\nimport ArrowRightIcon from '@mui/icons-material/ArrowRight';\nimport {\n ListItemIcon as MuiListItemIcon,\n ListItemText as MuiListItemText,\n MenuItem as MuiMenuItem,\n} from '@mui/material';\nimport Tooltip from '@mui/material/Tooltip';\nimport { Localized, ReferencedItem, SingleColumnMenu } from 'platform-bible-utils';\nimport { MouseEvent, PropsWithChildren } from 'react';\n\ntype MenuItemInfoBase = {\n /** Text (displayable in the UI) as the name of the menu item */\n label: string;\n /** Text to display when the mouse hovers over the menu item */\n tooltip?: string;\n};\n\nexport type Command = MenuItemInfoBase & {\n /** Command to execute (string.string) */\n command: string;\n};\n\ntype SubMenu = MenuItemInfoBase & {\n /** Command to execute (string.string) */\n items: MenuItemInfo[];\n};\n\nexport interface CommandHandler {\n (command: Command): void;\n}\n\nexport type MenuPropsBase = {\n /*\n * The JSON defining the menu whose items are to be rendered. This will typically be one of the\n * menus in the \"defs\" in a Platform.Bible menu (see PlatformMenus). The schema for this is\n * menuDocumentSchema (at the end of menus.model.ts). Note that while this is a\n * \"SingleColumnMenu\", somewhat bizarrely, a MultiColumnMenu is a SingleColumnMenu, so it really\n * could be a MultiColumnMenu, in which case, column had better be defined so it can be used\n * to filter out the actual groups and items to display on the column.\n */\n menuDefinition: Localized;\n\n commandHandler: CommandHandler;\n\n /**\n * Additional action to perform when any menu item is clicked. Allows the caller to handle event\n * (e.g., to close the menu).\n */\n onClick?: (event: MouseEvent) => void;\n};\n\nexport type MenuItemListProps = MenuPropsBase & {\n /** Optional unique (column) identifier */\n columnId?: ReferencedItem;\n};\n\nexport type MenuItemProps = Omit &\n PropsWithChildren<{\n /** Optional unique identifier */\n id?: string;\n\n onClick: (event: MouseEvent) => void;\n }>;\n\ntype MenuItemInfo = (Command | SubMenu) & {\n /**\n * If specified, menu item will be inset if it does not have a leading icon.\n *\n * @default true\n */\n allowForLeadingIcons?: boolean;\n /**\n * If specified, the path to the icon image to display on the leading side of the menu text.\n *\n * @default undefined (no leading icon will be shown)\n */\n iconPathBefore?: string;\n /**\n * If specified, the path to the icon image to display on the trailing side of the menu text.\n *\n * @default undefined (no trailing icon will be shown)\n */\n iconPathAfter?: string;\n /**\n * If true, list item is focused during the first mount\n *\n * @default false\n */\n hasAutoFocus?: boolean;\n\n /** Additional css classes to help with unique styling of the menu item */\n className?: string;\n\n /**\n * If true, the menu item will appear disabled and it will not respond to clicks or mouse hovers.\n *\n * @default false\n */\n isDisabled?: boolean;\n\n /**\n * If true, compact vertical padding designed for keyboard and mouse input is used.\n *\n * @default true\n */\n isDense?: boolean;\n\n /**\n * If true, a right-arrow icon will be displayed (iconPathAfter, if specified, will be ignored).\n *\n * @default false\n */\n isSubMenuParent?: boolean;\n\n /**\n * If true, the left and right padding is removed\n *\n * @default false\n */\n hasDisabledGutters?: boolean;\n\n /**\n * If true, a 1px light border is added to bottom of menu item\n *\n * @default false\n */\n hasDivider?: boolean;\n\n /** Help identify which element has keyboard focus */\n focusVisibleClassName?: string;\n\n /** If it's a submenu, it should have the items property */\n items?: MenuItemInfo[];\n};\n\nfunction getIcon(icon: string | undefined, menuLabel: string, leading: boolean) {\n return icon ? (\n \n {`${leading\n \n ) : undefined;\n}\n\nexport default function MenuItem(props: MenuItemProps) {\n const {\n onClick,\n label,\n tooltip,\n allowForLeadingIcons = true,\n iconPathBefore = undefined,\n iconPathAfter = undefined,\n hasAutoFocus = false,\n className,\n isDisabled = false,\n isDense = true,\n isSubMenuParent = false,\n hasDisabledGutters = false,\n hasDivider = false,\n focusVisibleClassName,\n id,\n children,\n } = props;\n\n const menuItem = (\n \n {label ? (\n <>\n {getIcon(iconPathBefore, label, true)}\n \n {isSubMenuParent ? (\n \n \n \n ) : (\n getIcon(iconPathAfter, label, false)\n )}\n \n ) : (\n children\n )}\n \n );\n\n return tooltip ? (\n \n
    {menuItem}
    \n
    \n ) : (\n menuItem\n );\n}\n","import MenuItem, {\n MenuItemListProps,\n MenuItemProps,\n MenuPropsBase,\n} from '@/components/mui/menu-item.component';\nimport { Menu } from '@mui/material';\nimport {\n Localized,\n MenuGroupDetailsInSubMenu,\n MenuItemContainingCommand,\n MenuItemContainingSubmenu,\n OrderedExtensibleContainer,\n ReferencedItem,\n SingleColumnMenu,\n} from 'platform-bible-utils';\nimport { MouseEvent, useMemo, useState } from 'react';\n\n/**\n * All the exported types in this file should be regarded as \"internal\" (i.e., they should not be\n * exposed via index.ts).\n */\n\nexport type GroupedMenuPropsBase = MenuPropsBase & {\n /** Optional unique (column) identifier */\n columnId?: ReferencedItem;\n};\n\nexport type GroupedMenuItemListProps = MenuItemListProps & {\n /**\n * If the menuDefinition includes \"top-level\" groups (i.e., those that belong to a column as\n * opposed to those that belong to a submenu) that should not be included in the list, then this\n * array specifies which groups to include. Likewise, for a submenu, this list indicates which\n * groups are pertinent for that submenu. So then for a context menu this property need not be\n * specified since it is a top-level menu based on a \"true\" SingleColumnMenu (i.e., one that is\n * not a MultiColumnMenu).\n */\n includedGroups?: {\n id: string;\n group: Localized;\n }[];\n};\n\ninterface ItemInfo {\n item: Localized;\n isLastItemInGroup: boolean;\n}\n\ntype SubMenuProps = MenuPropsBase & {\n parentMenuItem: Localized;\n parentItemProps: Omit, 'iconPathAfter'>;\n};\n\nfunction getAllGroups(menuDefinition: Localized) {\n const groupEntries = Object.entries(menuDefinition.groups);\n // Convert array of entries to array of objects with id and group properties\n return groupEntries.map(([key, value]) => ({ id: key, group: value }));\n}\n\nfunction SubMenu(props: SubMenuProps) {\n const [anchorEl, setAnchorEl] = useState(undefined);\n\n const { parentMenuItem, parentItemProps, menuDefinition } = props;\n\n const handleParentMenuItemClick = (event: MouseEvent) => {\n setAnchorEl(event.currentTarget);\n };\n\n const handleClose = () => {\n setAnchorEl(undefined);\n };\n\n const renderSubMenuItems = () => {\n let includedGroups = getAllGroups(menuDefinition).filter((g) => 'menuItem' in g.group);\n\n // Ensure valid parent menu was provided. (If not, submenu will contain all groups!)\n if (!parentMenuItem?.id) throw new Error('A valid parent menu item is required for submenus.');\n\n // When laying out a submenu, only include groups associated with the provided parent menu.\n // Note: without the (annoying) redundant check that the included groups\n // have the menuItem field, TS doesn't think it exists.\n includedGroups = includedGroups.filter(\n (group) => 'menuItem' in group.group && group.group.menuItem === parentMenuItem.id,\n );\n\n return ;\n };\n\n return (\n <>\n \n \n {renderSubMenuItems()}\n \n \n );\n}\n\nconst getOrderedGroupItems = (\n groupId: string,\n allItems: Localized[],\n) => {\n // Filter items that belong to the specified group\n const itemsForGroup = allItems.filter((item) => item.group === groupId);\n // Sort items based on order\n const sortedItems = itemsForGroup.sort((a, b) => (a.order || 0) - (b.order || 0));\n return sortedItems;\n};\n\n/**\n * This component is internal; it does not need to be exposed to the outside world since it is not\n * useful on its own. It is used to generate and lay out the MenuItems that appear either on a\n * top-level menu (in a GridMenu or ContextMenu) or in a submenu.\n */\nexport default function GroupedMenuItemList(menuProps: GroupedMenuItemListProps) {\n const { menuDefinition, onClick, commandHandler, includedGroups } = menuProps;\n\n const { items, allowForLeadingIcons } = useMemo(() => {\n const groupsToInclude =\n includedGroups && includedGroups.length > 0\n ? includedGroups\n : // We're apparently laying out a single-column menu (presumably a context menu). In this\n // case, all groups should be included except ones that belong to a submenu.\n getAllGroups(menuDefinition).filter((g) => !('menuItem' in g.group));\n\n const sortedGroups = Object.values(groupsToInclude).sort(\n (a, b) => (a.group.order || 0) - (b.group.order || 0),\n );\n\n const itemArray: ItemInfo[] = [];\n\n sortedGroups.forEach((group) => {\n getOrderedGroupItems(group.id, menuDefinition.items).forEach((item) =>\n itemArray.push({ item, isLastItemInGroup: false }),\n );\n if (itemArray.length > 0) itemArray[itemArray.length - 1].isLastItemInGroup = true;\n });\n\n // No divider after last item in final group.\n if (itemArray.length > 0) itemArray[itemArray.length - 1].isLastItemInGroup = false;\n\n const allowSpaceForLeadingIcons = itemArray.some(\n (i) => 'iconPathBefore' in i.item && i.item.iconPathBefore,\n );\n\n return { items: itemArray, allowForLeadingIcons: allowSpaceForLeadingIcons };\n }, [includedGroups, menuDefinition]);\n\n // Create props for MenuItem component including setting hasDivider for the last item in a group\n const createMenuItemProps = ({ item, isLastItemInGroup }: ItemInfo) => {\n const menuItemProps = {\n className: 'papi-menu-item',\n label: item.label,\n tooltip: item.tooltip,\n iconPathBefore: 'iconPathBefore' in item ? item.iconPathBefore : undefined,\n iconPathAfter: 'iconPathAfter' in item ? item.iconPathAfter : undefined,\n hasDivider: isLastItemInGroup, // Set hasDivider to true for the last item in a group\n allowForLeadingIcons,\n };\n\n return menuItemProps;\n };\n\n const [firstItem] = items;\n\n if (!firstItem) return
    ;\n\n const divKey = firstItem.item.group;\n\n return (\n
    \n {items.map((itemInfo, index) => {\n const { item } = itemInfo;\n const menuItemProps = createMenuItemProps(itemInfo);\n if ('command' in item) {\n const key = item.group + index;\n return (\n ) => {\n onClick?.(event);\n commandHandler(item);\n }}\n {...menuItemProps}\n />\n );\n }\n return (\n \n );\n })}\n
    \n );\n}\n","import GroupedMenuItemList from '@/components/mui/grouped-menu-item-list.component';\nimport { MenuItemListProps } from '@/components/mui/menu-item.component';\nimport { MultiColumnMenu } from 'platform-bible-utils';\n\n/**\n * This component is internal; it does not need to be exposed to the outside world since it is not\n * useful on its own. Use either GridMenu or ContextMenu.\n */\nexport default function TopLevelMenu(props: MenuItemListProps) {\n const { menuDefinition, columnId } = props;\n\n const groupEntries = Object.entries(menuDefinition.groups);\n // Convert array of entries to array of objects with id and group properties\n const groups = groupEntries.map(([key, value]) => ({ id: key, group: value }));\n let includedGroups = groups.filter((g) => 'column' in g.group);\n\n // Check if column is provided and menuDefinition is a MultiColumnMenu\n if (\n columnId &&\n 'columns' in menuDefinition &&\n // Without this type assertion, TS doesn't know what columns is.\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n (menuDefinition as MultiColumnMenu).columns[columnId]\n ) {\n // When laying out a single column in a MultiColumnMenu, only include groups associated with\n // the provided column. Note: without the (annoying) redundant check that the included groups\n // have the colum field, TS doesn't think it exists.\n includedGroups = includedGroups.filter(\n (g) => 'column' in g.group && g.group.column === columnId,\n );\n }\n\n return ;\n}\n","import '@/components/mui/grid-menu.component.css';\nimport { GroupedMenuPropsBase } from '@/components/mui/grouped-menu-item-list.component';\nimport { CommandHandler } from '@/components/mui/menu-item.component';\nimport TopLevelMenu from '@/components/mui/top-level-menu.component';\nimport { Grid, List } from '@mui/material';\nimport {\n Localized,\n MenuColumnWithHeader,\n MultiColumnMenu,\n ReferencedItem,\n} from 'platform-bible-utils';\nimport { useMemo } from 'react';\n\ntype ColumnInfo = {\n /*\n * The ID (`${string}.${string}`) of a specific menu column.\n */\n id: ReferencedItem;\n\n /*\n * Metadata (label, order, etc.) for a specific menu column.\n */\n metadata: Localized;\n};\n\ntype MenuColumnProps = ColumnInfo &\n GroupedMenuPropsBase & {\n /** Additional css classes to help with unique styling of the menu column */\n className?: string;\n };\n\nexport type GridMenuInfo = {\n /** The menu object containing information about the columns, groups, and items to display. */\n multiColumnMenu: Localized;\n};\n\nexport type GridMenuProps = GridMenuInfo & {\n /** Optional unique identifier */\n id?: string;\n\n commandHandler: CommandHandler;\n\n /** Additional css classes to help with unique styling of the grid menu */\n className?: string;\n};\n\nfunction MenuColumn({\n commandHandler,\n menuDefinition,\n id,\n metadata,\n onClick,\n className,\n}: MenuColumnProps) {\n return (\n \n

    \n {metadata.label}\n

    \n {/* It would seem as though this List component were unnecessary, since it only contains one\n thing, but the \"dense\" property does affect the layout of the items (in a way I don't fully\n understand). There might be a better way. */}\n \n \n \n \n );\n}\n\nexport default function GridMenu({\n commandHandler,\n className,\n multiColumnMenu,\n id,\n}: GridMenuProps) {\n const { columns } = multiColumnMenu;\n\n const sortedColumns = useMemo(() => {\n const columnNumbers = new Map();\n Object.getOwnPropertyNames(columns).forEach((columnName: string) => {\n // We know for sure there is a (boolean) property 'isExtensible' that we are not interested in.\n if (columnName === 'isExtensible') return;\n // TS doesn't allow `columnName` above to be a ReferencedItem even though the type says it is\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const columnId = columnName as ReferencedItem;\n const column = columns[columnId];\n // As of right now (and hopefully forever after), all remaining properties of the\n // ColumnsWithHeaders object are columns whose property names are the IDs of the columns.\n // This is an additional (redundant) sanity check. Specifically we're interested in\n // MenuColumnWithHeader objects, which TypeScript now \"knows\" we have, but at runtime all we\n // can check for is that it's an object with a valid numeric order field. That's likely good\n // enough.\n if (\n typeof column === 'object' &&\n typeof column.order === 'number' &&\n !Number.isNaN(column.order)\n )\n columnNumbers.set(column.order, { id: columnId, metadata: column });\n else\n console.warn(\n `Property ${columnName} (${typeof column}) on menu ${id} is not a valid column and is being ignored. This might indicate data corruption`,\n );\n });\n\n // Extract values and sort them based on the 'order' property\n return Array.from(columnNumbers.values()).sort((a, b) => {\n return (a.metadata.order || 0) - (b.metadata.order || 0);\n });\n }, [columns, id]);\n\n // We might need something like this if we need to be able to prevent empty columns\n // sortedColumns.filter((c) => multiColumnMenu.groups.some((g) => 'column' in g && (g as .column)...\n\n return (\n \n {sortedColumns.map((col, index) => (\n \n ))}\n \n );\n}\n","import { useEffect, useRef, useState } from 'react';\n\nexport type UsePromiseOptions = {\n /**\n * Whether to leave the value as the most recent resolved promise value or set it back to\n * defaultValue while running the promise again. Defaults to true\n */\n preserveValue?: boolean;\n};\n\n/** Set up defaults for options for usePromise hook */\nfunction getUsePromiseOptionsDefaults(options: UsePromiseOptions): UsePromiseOptions {\n return {\n preserveValue: true,\n ...options,\n };\n}\n\n/**\n * Awaits a promise and returns a loading value while the promise is unresolved\n *\n * @param promiseFactoryCallback A function that returns the promise to await. If this callback is\n * undefined, the current value will be returned (defaultValue unless it was previously changed\n * and `options.preserveValue` is true), and there will be no loading.\n *\n * WARNING: MUST BE STABLE - const or wrapped in useCallback. The reference must not be updated\n * every render\n * @param defaultValue The initial value to return while first awaiting the promise. If\n * `options.preserveValue` is false, this value is also shown while awaiting the promise on\n * subsequent calls.\n *\n * Note: this parameter is internally assigned to a `ref`, so changing it will not cause any hooks\n * to re-run with its new value. This means that, if the `promiseFactoryCallback` changes and\n * `options.preserveValue` is `false`, the returned value will be set to the current\n * `defaultValue`. However, the returned value will not be updated if`defaultValue` changes.\n * @param options Various options for adjusting how this hook runs the `promiseFactoryCallback`\n *\n * Note: this parameter is internally assigned to a `ref`, so changing it will not cause any hooks\n * to re-run with its new value. However, the latest `options.preserveValue` will always be used\n * appropriately to determine whether to preserve the returned value when changing the\n * `promiseFactoryCallback`\n * @returns `[value, isLoading]`\n *\n * - `value`: the current value for the promise, either the defaultValue or the resolved promise value\n * - `isLoading`: whether the promise is waiting to be resolved\n */\nconst usePromise = (\n promiseFactoryCallback: (() => Promise) | undefined,\n defaultValue: T,\n options: UsePromiseOptions = {},\n): [value: T, isLoading: boolean] => {\n // Use defaultValue as a ref so it doesn't update dependency arrays\n const defaultValueRef = useRef(defaultValue);\n defaultValueRef.current = defaultValue;\n // Use options as a ref so it doesn't update dependency arrays\n const optionsDefaultedRef = useRef(options);\n optionsDefaultedRef.current = getUsePromiseOptionsDefaults(optionsDefaultedRef.current);\n\n const [value, setValue] = useState(() => defaultValueRef.current);\n const [isLoading, setIsLoading] = useState(true);\n useEffect(() => {\n let promiseIsCurrent = true;\n // If a promiseFactoryCallback was provided, we are loading. Otherwise, there is no loading to do\n setIsLoading(!!promiseFactoryCallback);\n (async () => {\n // If there is a callback to run, run it\n if (promiseFactoryCallback) {\n const result = await promiseFactoryCallback();\n // If the promise was not already replaced, update the value\n if (promiseIsCurrent) {\n setValue(() => result);\n setIsLoading(false);\n }\n }\n })();\n\n return () => {\n // Mark this promise as old and not to be used\n promiseIsCurrent = false;\n if (!optionsDefaultedRef.current.preserveValue) setValue(() => defaultValueRef.current);\n };\n }, [promiseFactoryCallback]);\n\n return [value, isLoading];\n};\nexport default usePromise;\n","\"use client\";\n\nimport createSvgIcon from './utils/createSvgIcon';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nexport default createSvgIcon( /*#__PURE__*/_jsx(\"path\", {\n d: \"M3 18h18v-2H3zm0-5h18v-2H3zm0-7v2h18V6z\"\n}), 'Menu');","import GridMenu from '@/components/mui/grid-menu.component';\nimport { Command, CommandHandler } from '@/components/mui/menu-item.component';\nimport usePromise from '@/hooks/use-promise.hook';\nimport { Menu as MenuIcon } from '@mui/icons-material';\nimport { Drawer, IconButton } from '@mui/material';\nimport { Localized, MultiColumnMenu } from 'platform-bible-utils';\nimport {\n MouseEvent,\n MutableRefObject,\n PropsWithChildren,\n useCallback,\n useEffect,\n useState,\n} from 'react';\n\nexport interface MultiColumnMenuProvider {\n (isSupportAndDevelopment: boolean): Promise>;\n}\n\nexport type HamburgerMenuButtonProps = PropsWithChildren & {\n /** The handler to use for menu commands (and eventually toolbar commands). */\n commandHandler: CommandHandler;\n\n /**\n * Optional reference to the \"div\" container that determines the where the menu should appear. If\n * not defined, then (1,1) used.\n */\n containerRef?: MutableRefObject;\n\n /**\n * The delegate to use to get the menu data. If not specified or if it returns undefined, the data\n * in normalMenu or fullMenu property will be used.\n */\n menuProvider?: MultiColumnMenuProvider;\n\n /**\n * The menu data to show when the menu is opened if the menuProvider property is not defined.\n * (This allows for a default or test-only static menu to be used.)\n */\n normalMenu?: Localized;\n\n /**\n * The menu data to show for \"full\" menu (when opened with the SHIFT key pressed) if the\n * menuProvider property is not defined. (This allows for a default or test-only static menu to be\n * used.)\n */\n fullMenu?: Localized;\n\n /** Additional css class(es) to help with unique styling of the sub-components */\n className?: string;\n\n /** Value to use as prefix for ARIA labels on interactive sub-components */\n ariaLabelPrefix?: string;\n};\n\nexport default function HamburgerMenuButton({\n menuProvider,\n normalMenu,\n fullMenu,\n commandHandler,\n containerRef,\n className,\n ariaLabelPrefix,\n children,\n}: HamburgerMenuButtonProps) {\n const [isMenuOpen, setMenuOpen] = useState(false);\n const [showFullMenu, setShowFullMenu] = useState(false);\n\n const handleMenuItemClick = useCallback(() => {\n if (isMenuOpen) setMenuOpen(false);\n setShowFullMenu(false);\n }, [isMenuOpen]);\n\n const handleMenuButtonClick = useCallback((e: MouseEvent) => {\n e.stopPropagation();\n setMenuOpen((prevIsOpen) => {\n const isOpening = !prevIsOpen;\n if (isOpening && e.shiftKey) setShowFullMenu(true);\n else if (!isOpening) setShowFullMenu(false);\n return isOpening;\n });\n }, []);\n\n const menuCommandHandler = useCallback(\n (command: Command) => {\n handleMenuItemClick();\n return commandHandler(command);\n },\n [commandHandler, handleMenuItemClick],\n );\n\n const [offset, setOffset] = useState({ top: 1, left: 1 });\n\n useEffect(() => {\n if (isMenuOpen) {\n const node = containerRef?.current;\n if (node) {\n const rect = node.getBoundingClientRect();\n const scrollTop = window.scrollY;\n const scrollLeft = window.scrollX;\n const top = rect.top + scrollTop + node.clientHeight;\n const left = rect.left + scrollLeft;\n setOffset({ top, left });\n }\n }\n }, [isMenuOpen, containerRef]);\n\n const [normalMenuData] = usePromise(\n useCallback(async () => {\n return menuProvider?.(false) ?? normalMenu;\n // isMenuOpen needs to be included for the menu contents to reevaluate when reopened\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [menuProvider, normalMenu, isMenuOpen]),\n normalMenu,\n );\n\n const [fullMenuData] = usePromise(\n useCallback(async () => {\n return menuProvider?.(true) ?? fullMenu ?? normalMenuData;\n // isMenuOpen needs to be included for the menu contents to reevaluate when reopened\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [menuProvider, fullMenu, normalMenuData, isMenuOpen]),\n fullMenu ?? normalMenuData,\n );\n\n const menu = showFullMenu && fullMenuData ? fullMenuData : normalMenuData;\n\n return (\n <>\n \n {children ?? }\n \n \n {menu ? (\n \n ) : undefined}\n \n \n );\n}\n","import '@/components/mui/icon-button.component.css';\nimport { IconButton as MuiIconButton } from '@mui/material';\nimport { MouseEventHandler, PropsWithChildren } from 'react';\n\nexport type IconButtonProps = PropsWithChildren<{\n /** Optional unique identifier */\n id?: string;\n /**\n * Required. Used as both the tooltip (aka, title) and the aria-label (used for accessibility,\n * testing, etc.), unless a distinct tooltip is supplied.\n */\n label: string;\n /**\n * Enabled status of button\n *\n * @default false\n */\n isDisabled?: boolean;\n /** Optional tooltip to display if different from the aria-label. */\n tooltip?: string;\n /** If true, no tooltip will be displayed. */\n isTooltipSuppressed?: boolean;\n /**\n * If given, uses a negative margin to counteract the padding on one side (this is often helpful\n * for aligning the left or right side of the icon with content above or below, without ruining\n * the border size and shape).\n *\n * @default false\n */\n adjustMarginToAlignToEdge?: 'end' | 'start' | false;\n /**\n * The size of the component. small is equivalent to the dense button styling.\n *\n * @default false\n */\n size: 'small' | 'medium' | 'large';\n /** Additional css classes to help with unique styling of the button */\n className?: string;\n /** Optional click handler */\n onClick?: MouseEventHandler;\n}>;\n\n/**\n * Iconic button a user can click to do something\n *\n * Thanks to MUI for heavy inspiration and documentation\n * https://mui.com/material-ui/getting-started/overview/\n */\nfunction IconButton({\n id,\n label,\n isDisabled = false,\n tooltip,\n isTooltipSuppressed = false,\n adjustMarginToAlignToEdge = false,\n size = 'medium',\n className,\n onClick,\n children,\n}: IconButtonProps) {\n return (\n \n {children /* the icon to display */}\n \n );\n}\n\nexport default IconButton;\n","import { cn } from '@/utils/shadcn-ui.util';\nimport { LoaderCircle, LucideProps } from 'lucide-react';\nimport { forwardRef } from 'react';\n\nexport type SpinnerProps = LucideProps;\n\nconst Spinner = forwardRef(({ className, ...props }, ref) => {\n return (\n \n );\n});\n\nSpinner.displayName = 'Spinner';\n\nexport default Spinner;\n","import { Input as ShadInput } from '@/components/shadcn-ui/input';\nimport { Label as ShadLabel } from '@/components/shadcn-ui/label';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { ChangeEventHandler, FocusEventHandler } from 'react';\n\nexport type TextFieldProps = {\n /** Optional unique identifier */\n id?: string;\n /**\n * If `true`, the component is disabled.\n *\n * @default false\n */\n isDisabled?: boolean;\n /**\n * If `true`, the label is displayed in an error state.\n *\n * @default false\n */\n hasError?: boolean;\n /**\n * If `true`, the input will take up the full width of its container.\n *\n * @default false\n */\n isFullWidth?: boolean;\n /** Text that gives the user instructions on what contents the TextField expects */\n helperText?: string;\n /** The title of the TextField */\n label?: string;\n /** The short hint displayed in the `input` before the user enters a value. */\n placeholder?: string;\n /**\n * If `true`, the label is displayed as required and the `input` element is required.\n *\n * @default false\n */\n isRequired?: boolean;\n /** Additional css classes to help with unique styling of the text field */\n className?: string;\n /** Starting value for the text field if it is not controlled */\n defaultValue?: string | number;\n /** Value of the text field if controlled */\n value?: string | number;\n /** Triggers when content of textfield is changed */\n onChange?: ChangeEventHandler;\n /** Triggers when textfield gets focus */\n onFocus?: FocusEventHandler;\n /** Triggers when textfield loses focus */\n onBlur?: FocusEventHandler;\n};\n\n/**\n * Text input field\n *\n * Thanks to Shadcn for heavy inspiration and documentation\n * https://ui.shadcn.com/docs/components/input#with-label\n */\nfunction TextField({\n id,\n isDisabled = false,\n hasError = false,\n isFullWidth = false,\n helperText,\n label,\n placeholder,\n isRequired = false,\n className,\n defaultValue,\n value,\n onChange,\n onFocus,\n onBlur,\n}: TextFieldProps) {\n return (\n
    \n {`${label}${isRequired ? '*' : ''}`}\n \n

    {helperText}

    \n
    \n );\n}\n\nexport default TextField;\n","import HamburgerMenuButton, {\n MultiColumnMenuProvider,\n} from '@/components/mui/hamburger-menu-button.component';\nimport { CommandHandler } from '@/components/mui/menu-item.component';\nimport '@/components/mui/toolbar.component.css';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { AppBar, Toolbar as MuiToolbar } from '@mui/material';\nimport { PropsWithChildren, useRef } from 'react';\n\nexport type ToolbarProps = PropsWithChildren<{\n /** The handler to use for menu commands (and eventually toolbar commands). */\n commandHandler: CommandHandler;\n\n /**\n * The optional delegate to use to get the menu data. If not specified, the \"hamburger\" menu will\n * not display.\n */\n menuProvider?: MultiColumnMenuProvider;\n\n /** Optional unique identifier */\n id?: string;\n\n /** Additional css classes to help with unique styling of the toolbar */\n className?: string;\n}>;\n\nexport default function Toolbar({\n menuProvider,\n commandHandler,\n className,\n id,\n children,\n}: ToolbarProps) {\n // This ref will always be defined\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const containerRef = useRef(undefined!);\n\n return (\n
    \n \n \n {menuProvider ? (\n \n ) : undefined}\n {children ?
    {children}
    : undefined}\n \n
    \n
    \n );\n}\n","import React from 'react';\nimport { cva, type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst alertVariants = cva(\n 'tw-relative tw-w-full tw-rounded-lg tw-border tw-p-4 [&>svg~*]:tw-pl-7 [&>svg+div]:tw-translate-y-[-3px] [&>svg]:tw-absolute [&>svg]:tw-left-4 [&>svg]:tw-top-4 [&>svg]:tw-text-foreground',\n {\n variants: {\n variant: {\n default: 'tw-bg-background tw-text-foreground',\n destructive:\n 'tw-border-destructive/50 tw-text-destructive dark:tw-border-destructive [&>svg]:tw-text-destructive',\n },\n },\n defaultVariants: {\n variant: 'default',\n },\n },\n);\n\nconst Alert = React.forwardRef<\n HTMLDivElement,\n React.HTMLAttributes & VariantProps\n>(({ className, variant, ...props }, ref) => (\n
    \n));\nAlert.displayName = 'Alert';\n\nconst AlertTitle = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n {/* added because of https://github.com/jsx-eslint/eslint-plugin-jsx-a11y/blob/main/docs/rules/heading-has-content.md */}\n {props.children}{' '}\n \n ),\n);\nAlertTitle.displayName = 'AlertTitle';\n\nconst AlertDescription = React.forwardRef<\n HTMLParagraphElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n
    \n));\nAlertDescription.displayName = 'AlertDescription';\n\nexport { Alert, AlertTitle, AlertDescription };\n","import { ComponentProps } from 'react';\nimport { toast as sonner, Toaster } from 'sonner';\n\ntype SonnerProps = ComponentProps;\n\nfunction Sonner({ ...props }: SonnerProps) {\n return (\n \n );\n}\n\n// The re-export of the sonner function was added manually\nexport { Sonner, sonner };\n","import React from 'react';\nimport * as SliderPrimitive from '@radix-ui/react-slider';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Slider = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n \n \n \n));\nSlider.displayName = SliderPrimitive.Root.displayName;\n\nexport { Slider };\n","import React from 'react';\nimport * as SwitchPrimitives from '@radix-ui/react-switch';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Switch = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n));\nSwitch.displayName = SwitchPrimitives.Root.displayName;\n\nexport { Switch };\n","import React from 'react';\nimport * as TabsPrimitive from '@radix-ui/react-tabs';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport const Tabs = TabsPrimitive.Root;\n\nexport type TabsListProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport type TabsTriggerProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport type TabsContentProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport const TabsList = React.forwardRef<\n React.ElementRef,\n TabsListProps\n>(({ className, ...props }, ref) => (\n \n));\nTabsList.displayName = TabsPrimitive.List.displayName;\n\nexport const TabsTrigger = React.forwardRef<\n React.ElementRef,\n TabsTriggerProps\n>(({ className, ...props }, ref) => (\n \n));\nTabsTrigger.displayName = TabsPrimitive.Trigger.displayName;\n\nexport const TabsContent = React.forwardRef<\n React.ElementRef,\n TabsContentProps\n>(({ className, ...props }, ref) => (\n \n));\nTabsContent.displayName = TabsPrimitive.Content.displayName;\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Download } from 'lucide-react';\n\ntype InstallButtonProps = {\n /** The installing boolean value determines the state of the button. */\n isInstalling: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n /** Optional text for the button. */\n buttonText?: string;\n} & ButtonProps;\n\n/**\n * The InstallButton component is a button designed for initiating installs. It includes visuals for\n * active installing and idle states.\n *\n * @param isInstalling The installing boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @param buttonText Optional text for the button.\n * @returns A install button.\n */\nexport default function InstallButton({\n isInstalling,\n handleClick,\n buttonText,\n className,\n ...props\n}: InstallButtonProps) {\n return (\n \n {isInstalling ? (\n \n ) : (\n <>\n \n {buttonText}\n \n )}\n \n );\n}\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\n\ntype EnableButtonProps = {\n /** The enabling boolean value determines the state of the button. */\n isEnabling: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n} & ButtonProps;\n\n/**\n * The EnableButton component is a button designed for initiating enabling of downloads. It includes\n * visuals for active enabling and idle states.\n *\n * @param isEnabling The enabling boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @returns A button that can be used to enable.\n */\nexport default function EnableButton({\n isEnabling,\n handleClick,\n className,\n ...props\n}: EnableButtonProps) {\n return (\n \n {isEnabling ? (\n <>\n \n Enabling...\n \n ) : (\n 'Enable'\n )}\n \n );\n}\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\n\ntype DisableButtonProps = {\n /** The disabling boolean value determines the state of the button. */\n isDisabling: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n} & ButtonProps;\n\n/**\n * The DisableButton component is a button designed for initiating disabling of downloads. It\n * includes visuals for active disabling and idle states.\n *\n * @param isDisabling The disabling boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @returns A button that can be used to disable.\n */\nexport default function DisableButton({\n isDisabling,\n handleClick,\n className,\n ...props\n}: DisableButtonProps) {\n return (\n \n {isDisabling ? (\n <>\n \n Disabling...\n \n ) : (\n 'Disable'\n )}\n \n );\n}\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\n\ntype UpdateButtonProps = {\n /** The updating boolean value determines the state of the button. */\n isUpdating: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n} & ButtonProps;\n\n/**\n * The UpdateButton component is a button designed for initiating updates for downloaded extensions.\n * It includes visuals for active updating and idle states.\n *\n * @param isUpdating The updating boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @returns A button that can be used to update.\n */\nexport default function UpdateButton({\n isUpdating,\n handleClick,\n className,\n ...props\n}: UpdateButtonProps) {\n return (\n \n {isUpdating ? (\n <>\n \n Updating...\n \n ) : (\n 'Update'\n )}\n \n );\n}\n","import { cn } from '@/utils/shadcn-ui.util';\nimport Markdown, { MarkdownToJSX } from 'markdown-to-jsx';\nimport { useMemo } from 'react';\n\ninterface MarkdownRendererProps {\n /** Optional unique identifier */\n id?: string;\n /** The markdown string to render */\n markdown: string;\n className?: string;\n /**\n * The [`target` attribute for `a` html\n * tags](https://developer.mozilla.org/en-US/docs/Web/HTML/Element/a#target). Defaults to not\n * adding a `target` to `a` tags\n */\n anchorTarget?: string;\n}\n\n/**\n * This component renders markdown content given a markdown string. It uses typography styles from\n * the platform.\n *\n * @param markdown The markdown string to render.\n * @param id Optional unique identifier\n * @returns A div containing the rendered markdown content.\n */\nexport default function MarkdownRenderer({\n id,\n markdown,\n className,\n anchorTarget,\n}: MarkdownRendererProps) {\n const options: MarkdownToJSX.Options = useMemo(\n () => ({\n overrides: {\n a: {\n props: {\n target: anchorTarget,\n },\n },\n },\n }),\n [anchorTarget],\n );\n return (\n
    \n {markdown}\n
    \n );\n}\n","import { Filter, ChevronDown } from 'lucide-react';\nimport { forwardRef } from 'react';\nimport { Button } from '@/components/shadcn-ui/button';\n\n/**\n * The FilterButton component is a button designed for initiating filtering of data. It is designed\n * to be used with the dropdown menu. It uses forwardRef to pass the button to the dropdown trigger\n * asChild.\n *\n * @returns A button that can be used to filter.\n */\nconst FilterButton = forwardRef((props, ref) => {\n return (\n \n \n Filter\n \n \n );\n});\n\nexport default FilterButton;\n","import {\n DropdownMenu,\n DropdownMenuTrigger,\n DropdownMenuContent,\n DropdownMenuLabel,\n DropdownMenuGroup,\n DropdownMenuCheckboxItem,\n DropdownMenuRadioItem,\n DropdownMenuSeparator,\n} from '@/components/shadcn-ui/dropdown-menu';\nimport FilterButton from './buttons/filter-button.component';\n\nexport enum DropdownMenuItemType {\n Check,\n Radio,\n}\n\nexport type DropdownItem = {\n /** The label is the text that will be displayed on the dropdown item. */\n label: string;\n /** The itemType determines the DropdownMenuItemType type as either Check or Radio. */\n itemType: DropdownMenuItemType;\n /** The onClick function is called when the item is clicked. */\n onClick: () => void;\n};\n\nexport type DropdownGroup = {\n /**\n * The label is the text that will be displayed on the dropdown group. It is used to categorize\n * the items in the group.\n */\n label: string;\n /** The items array contains the items that will be displayed in the dropdown group */\n items: DropdownItem[];\n};\n\nexport type FilterDropdownProps = {\n /** Object unique identifier */\n id?: string;\n /** The groups array contains the groups that will be displayed in the dropdown */\n groups: DropdownGroup[];\n}; // TODO: extend the props later\n\n/**\n * The FilterDropdown component is a dropdown designed for filtering content. It includes groups of\n * items that can be checkboxes or radio items.\n *\n * @param id Optional unique identifier\n * @param groups The groups array contains the groups that will be displayed in the dropdown\n * @returns A filter dropdown.\n */\nexport default function FilterDropdown({ id, groups }: FilterDropdownProps) {\n return (\n
    \n {/* TODO: remove this once the DropDown Menu shadcn has an id prop */}\n \n \n \n \n \n {groups.map((group) => (\n
    \n {group.label}\n \n {group.items.map((item) => (\n
    \n {item.itemType === DropdownMenuItemType.Check ? (\n \n {item.label}\n \n ) : (\n \n {item.label}\n \n )}\n
    \n ))}\n
    \n \n
    \n ))}\n
    \n
    \n
    \n );\n}\n","interface NoExtensionsFoundProps {\n /** Optional unique identifier */\n id?: string;\n /** The message to display */\n message: string;\n}\n/**\n * This component displays a message to the user when no extensions are found in the marketplace.\n *\n * @param id Optional unique identifier\n * @param message The message to display.\n * @returns {JSX.Element} - Returns the message component that displays the message to the user.\n */\nexport default function NoExtensionsFound({ id, message }: NoExtensionsFoundProps) {\n return (\n
    \n
    \n

    {message}

    \n
    \n
    \n );\n}\n","import { CircleHelp, Link as LucideLink, User } from 'lucide-react';\nimport { NumberFormat } from 'platform-bible-utils';\n\n/** Interface that stores the parameters passed to the More Info component */\ninterface MoreInfoProps {\n /** Optional unique identifier */\n id?: string;\n /** The category of the extension */\n category: string;\n /** The number of downloads for the extension */\n downloads: Record;\n /** The languages supported by the extension */\n languages: string[];\n /** The URL to the more info page of the extension */\n moreInfoUrl: string;\n}\n/**\n * This component displays the more info section of the extension which includes the category,\n * number of downloads, languages, and links to the website and support\n *\n * @param id Optional unique identifier\n * @param category The category of the extension\n * @param downloads The number of downloads for the extension\n * @param languages The languages supported by the extension\n * @param moreInfoUrl The URL to the more info page of the extension\n * @returns {JSX.Element} - Returns the more info component that displays the category, number of\n * downloads, languages, and links to the website and support\n */\nexport default function MoreInfo({\n id,\n category,\n downloads,\n languages,\n moreInfoUrl,\n}: MoreInfoProps) {\n /**\n * This constant formats the number of downloads into a more readable format.\n *\n * @example 1000 -> 1K\n *\n * @example 1000000 -> 1M\n *\n * @returns The formatted number of downloads\n */\n const numberFormatted = new NumberFormat('en', {\n notation: 'compact',\n compactDisplay: 'short',\n }).format(Object.values(downloads).reduce((a: number, b: number) => a + b, 0));\n\n /** This function scrolls the window to the bottom of the page. */\n const handleScrollToBottom = () => {\n window.scrollTo(0, document.body.scrollHeight);\n };\n\n return (\n \n
    \n
    \n {category}\n
    \n CATEGORY\n
    \n
    \n
    \n
    \n \n {numberFormatted}\n
    \n USERS\n
    \n
    \n
    \n
    \n {languages.slice(0, 3).map((locale) => (\n \n {locale.toUpperCase()}\n \n ))}\n
    \n {languages.length > 3 && (\n handleScrollToBottom()}\n className=\"tw-text-xs tw-text-gray-500 tw-underline\"\n >\n +{languages.length - 3} more languages\n \n )}\n
    \n
    \n
    \n \n Website\n \n \n \n Support\n \n \n
    \n
    \n );\n}\n","import { useState } from 'react';\n\nexport type VersionInformation = {\n /** Date the version was published */\n date: string;\n /** Description of the changes in the version */\n description: string;\n};\n\n/** Type to store the version history information */\nexport type VersionHistoryType = Record;\n\n/** Interface that stores the parameters passed to the Version History component */\ninterface VersionHistoryProps {\n /** Optional unique identifier */\n id?: string;\n /** Object containing the versions mapped with their information */\n versionHistory: VersionHistoryType;\n}\n\n/**\n * Component to render the version history information shown in the footer component. Lists the 5\n * most recent versions, with the options to show all versions by pressing a button.\n *\n * @param versionHistory Object containing the versions mapped with their information\n * @param id Optional unique identifier\n * @returns Rendered version history for the Footer component\n */\nexport default function VersionHistory({ id, versionHistory }: VersionHistoryProps) {\n const [showAllVersions, setShowAllVersions] = useState(false);\n const currentDate = new Date();\n\n /**\n * Function to format the time string for the version history in the form of 'X year(s) ago'.\n *\n * @param dateString ISO Date string to determine the time string from\n * @returns Formatted time string\n */\n function formatTimeString(dateString: string) {\n const date = new Date(dateString);\n const dateDiff = new Date(currentDate.getTime() - date.getTime());\n const yearDiff = dateDiff.getUTCFullYear() - 1970;\n const monthDiff = dateDiff.getUTCMonth();\n const dayDiff = dateDiff.getUTCDate() - 1;\n\n // Determines how long ago the version was published\n let timeString = '';\n if (yearDiff > 0) {\n timeString = `${yearDiff.toString()} year${yearDiff === 1 ? '' : 's'} ago`;\n } else if (monthDiff > 0) {\n timeString = `${monthDiff.toString()} month${monthDiff === 1 ? '' : 's'} ago`;\n } else if (dayDiff === 0) {\n timeString = 'today';\n } else {\n timeString = `${dayDiff.toString()} day${dayDiff === 1 ? '' : 's'} ago`;\n }\n\n return timeString;\n }\n\n // Sorts the version history by version number\n const sortedEntries = Object.entries(versionHistory).sort((a, b) => b[0].localeCompare(a[0]));\n\n return (\n
    \n

    What`s New

    \n
      \n {(showAllVersions ? sortedEntries : sortedEntries.slice(0, 5)).map((entry) => (\n
      \n
      \n
    • \n {entry[1].description}\n
    • \n
      \n
      \n
      Version {entry[0]}
      \n
      {formatTimeString(entry[1].date)}
      \n
      \n
      \n ))}\n
    \n {sortedEntries.length > 5 && (\n setShowAllVersions(!showAllVersions)}\n className=\"tw-text-xs tw-text-gray-500 tw-underline\"\n >\n {showAllVersions ? 'Show Less Version History' : 'Show All Version History'}\n \n )}\n
    \n );\n}\n","import { useMemo } from 'react';\nimport { formatBytes } from 'platform-bible-utils';\nimport VersionHistory, { VersionHistoryType } from './version-history.component';\n\n/** Interface to store the parameters passed to the Footer component */\ninterface FooterProps {\n /** Optional unique identifier */\n id?: string;\n /** Name of the publisher */\n publisherDisplayName: string;\n /** Size of the extension file in bytes */\n fileSize: number;\n /** List of language codes supported by the extension */\n locales: string[];\n /** Object containing the version history mapped with their information */\n versionHistory: VersionHistoryType;\n}\n\n/**\n * Component to render the footer for the extension details which contains information on the\n * publisher, version history, languages, and file size.\n *\n * @param id Optional unique identifier\n * @param publisherDisplayName Name of the publisher\n * @param fileSize Size of the extension file in bytes\n * @param locales List of language codes supported by the extension\n * @param versionHistory Object containing the version history mapped with their information\n * @returns The rendered Footer component\n */\nexport default function Footer({\n id,\n publisherDisplayName,\n fileSize,\n locales,\n versionHistory,\n}: FooterProps) {\n /** Formats the file size into a human-readable format */\n const formattedFileSize = useMemo(() => formatBytes(fileSize), [fileSize]);\n\n /**\n * This function gets the display names of the languages based on the language codes.\n *\n * @param codes The list of language codes\n * @returns The list of language names\n */\n const getLanguageNames = (codes: string[]) => {\n const displayNames = new Intl.DisplayNames(navigator.language, { type: 'language' });\n return codes.map((code) => displayNames.of(code));\n };\n\n const languageNames = getLanguageNames(locales);\n\n return (\n
    \n
    \n \n
    \n
    \n

    Information

    \n
    \n

    \n Publisher\n {publisherDisplayName}\n Size\n {formattedFileSize}\n

    \n
    \n

    \n Languages\n {languageNames.join(', ')}\n

    \n
    \n
    \n
    \n
    \n
    \n );\n}\n","import { PlatformEvent, PlatformEventHandler } from 'platform-bible-utils';\nimport { useEffect } from 'react';\n\n/**\n * Adds an event handler to an event so the event handler runs when the event is emitted. Use\n * `papi.network.getNetworkEvent` to use a networked event with this hook.\n *\n * @param event The event to subscribe to.\n *\n * - If event is a `PlatformEvent`, that event will be used\n * - If event is undefined, the callback will not be subscribed. Useful if the event is not yet\n * available for example\n *\n * @param eventHandler The callback to run when the event is emitted\n *\n * WARNING: MUST BE STABLE - const or wrapped in useCallback. The reference must not be updated\n * every render\n */\nconst useEvent = (\n event: PlatformEvent | undefined,\n eventHandler: PlatformEventHandler,\n) => {\n useEffect(() => {\n // Do nothing if the event is not provided (in case the event is not yet available, for example)\n if (!event) return () => {};\n\n const unsubscriber = event(eventHandler);\n return () => {\n unsubscriber();\n };\n }, [event, eventHandler]);\n};\nexport default useEvent;\n","import { useCallback, useEffect } from 'react';\nimport { PlatformEvent, PlatformEventAsync, PlatformEventHandler } from 'platform-bible-utils';\nimport usePromise from './use-promise.hook';\n\nconst noopUnsubscriber = () => false;\n\n/**\n * Adds an event handler to an asynchronously subscribing/unsubscribing event so the event handler\n * runs when the event is emitted. Use `papi.network.getNetworkEvent` to use a networked event with\n * this hook.\n *\n * @param event The asynchronously (un)subscribing event to subscribe to.\n *\n * - If event is a `PlatformEvent` or `PlatformEventAsync`, that event will be used\n * - If event is undefined, the callback will not be subscribed. Useful if the event is not yet\n * available for example\n *\n * @param eventHandler The callback to run when the event is emitted\n *\n * WARNING: MUST BE STABLE - const or wrapped in useCallback. The reference must not be updated\n * every render\n */\nconst useEventAsync = (\n event: PlatformEvent | PlatformEventAsync | undefined,\n eventHandler: PlatformEventHandler,\n) => {\n // Subscribe to the event asynchronously\n const [unsubscribe] = usePromise(\n useCallback(async () => {\n // Do nothing if the event is not provided (in case the event is not yet available, for example)\n if (!event) return noopUnsubscriber;\n\n // Wrap subscribe and unsubscribe in promises to allow normal events to be used as well\n const unsub = await Promise.resolve(event(eventHandler));\n return async () => unsub();\n }, [eventHandler, event]),\n noopUnsubscriber,\n // We want the unsubscriber to return to default value immediately upon changing subscription\n // So the useEffect below will unsubscribe asap\n { preserveValue: false },\n );\n\n // Unsubscribe from the event asynchronously (but we aren't awaiting the unsub)\n useEffect(() => {\n return () => {\n if (unsubscribe !== noopUnsubscriber) {\n unsubscribe();\n }\n };\n }, [unsubscribe]);\n};\n\nexport default useEventAsync;\n"],"names":["twMergeCustom","extendTailwindMerge","cn","inputs","clsx","Input","React","className","type","props","ref","jsx","BookChapterInput","forwardRef","handleSearch","handleKeyDown","handleOnClick","handleSubmit","jsxs","ShadInput","event","e","History","P","R","s","n","N","B","O","S","K","g","k","x","T","X","V","w","L","G","A","H","C","I","y","q","U","m","l","h","c","E","D","i","a","o","u","v","f","d","b","J","DropdownMenu","DropdownMenuPrimitive","DropdownMenuTrigger","DropdownMenuGroup","DropdownMenuPortal","DropdownMenuSub","DropdownMenuRadioGroup","DropdownMenuSubTrigger","inset","children","ChevronRight","DropdownMenuSubContent","DropdownMenuContent","sideOffset","DropdownMenuItem","DropdownMenuCheckboxItem","checked","Check","DropdownMenuRadioItem","Circle","DropdownMenuLabel","DropdownMenuSeparator","DropdownMenuShortcut","BookMenuItem","bookId","handleSelectBook","isSelected","handleHighlightBook","bookType","ShadDropdownMenuItem","Canon","ChapterSelect","handleSelectChapter","endChapter","activeChapter","highlightedChapter","handleHighlightedChapter","chapters","_","handleMouse","useCallback","chapterNumber","chapter","GoToMenuItem","handleSort","handleLocationHistory","handleBookmarks","ShadDropdownMenuLabel","ArrowDownWideNarrow","Clock","Bookmark","ALL_BOOK_IDS","BOOK_TYPE_LABELS","BOOK_TYPE_ARRAY","SCROLL_OFFSET","SEARCH_QUERY_FORMATS","fetchGroupedBooks","fetchEndChapter","getChaptersForBook","getAllEnglishNames","isValidBookEnglishName","bookName","getBookIdFromEnglishName","formattedBookName","BookChapterControl","scrRef","searchQuery","setSearchQuery","useState","selectedBookId","setSelectedBookId","setHighlightedChapter","highlightedBookId","setHighlightedBookId","isContentOpen","setIsContentOpen","isContentOpenDelayed","setIsContentOpenDelayed","inputRef","useRef","contentRef","menuItemRef","fetchFilteredBooks","englishNameLowerCase","normalizedQuery","handleSearchInput","searchString","shouldPreventAutoClosing","controlMenuState","open","updateReference","shouldClose","verse","handleInputSubmit","format","matches","book","englishName","handleKeyDownInput","handleKeyDownContent","key","handleKeyDownMenuItem","chapterOffSet","useEffect","useLayoutEffect","scrollTimeout","scrollPosition","ShadDropdownMenu","ShadDropdownMenuTrigger","ShadDropdownMenuContent","bookTypeIndex","element","ShadDropdownMenuSeparator","buttonVariants","cva","Button","variant","size","asChild","Slot","labelVariants","Label","LabelPrimitive","RadioGroup","RadioGroupPrimitive","RadioGroupItem","Popover","PopoverPrimitive","PopoverTrigger","PopoverContent","align","DialogPortal","DialogPrimitive","DialogOverlay","DialogContent","DialogTitle","DialogDescription","Command","CommandPrimitive","CommandInput","Search","CommandList","CommandEmpty","CommandGroup","CommandSeparator","CommandItem","getOptionLabelDefault","option","ComboBox","id","options","buttonClassName","popoverContentClassName","value","onChange","getOptionLabel","buttonPlaceholder","textPlaceholder","commandEmptyMessage","buttonVariant","dir","isDisabled","setOpen","ChevronsUpDown","ChapterRangeSelector","startChapter","handleSelectStartChapter","handleSelectEndChapter","chapterCount","chapterOptions","useMemo","index","Fragment","BookSelectionMode","BOOK_SELECTOR_STRING_KEYS","localizeString","strings","BookSelector","handleBookSelectionModeChange","currentBookName","onSelectBooks","selectedBookIds","localizedStrings","currentBookText","chooseText","chooseBooksText","bookSelectionMode","setBookSelectionMode","onSelectionModeChange","newMode","DataTableViewOptions","table","FilterIcon","column","Select","SelectPrimitive","SelectGroup","SelectValue","SelectTrigger","ChevronDown","SelectScrollUpButton","ChevronUp","SelectScrollDownButton","SelectContent","position","SelectLabel","SelectItem","SelectSeparator","DataTablePagination","pageSize","ArrowLeftIcon","ChevronLeftIcon","ChevronRightIcon","ArrowRightIcon","Table","stickyHeader","TableHeader","TableBody","TableFooter","TableRow","TableHead","TableCell","TableCaption","DataTable","columns","data","enablePagination","showPaginationControls","showColumnVisibilityControls","onRowClickHandler","sorting","setSorting","columnFilters","setColumnFilters","columnVisibility","setColumnVisibility","rowSelection","setRowSelection","useReactTable","getCoreRowModel","getPaginationRowModel","getSortedRowModel","getFilteredRowModel","headerGroup","header","flexRender","_a","row","cell","OccurrencesTable","occurrenceData","setScriptureReference","referenceHeaderText","occurrenceHeaderText","occurrences","uniqueOccurrences","occurrence","uniqueOccurrence","deepEqual","Checkbox","CheckboxPrimitive","getLinesFromUSFM","text","getNumberFromUSFM","regex","match","getBookNumFromId","getStatusForItem","item","approvedItems","unapprovedItems","toggleVariants","Toggle","TogglePrimitive","ToggleGroupContext","ToggleGroup","ToggleGroupPrimitive","ToggleGroupItem","context","getSortingIcon","sortDirection","ArrowUpIcon","ArrowDownIcon","ArrowUpDownIcon","inventoryItemColumn","itemLabel","inventoryAdditionalItemColumn","additionalItemLabel","additionalItemIndex","inventoryCountColumn","countLabel","statusChangeHandler","changedItems","newStatus","onApprovedItemsChange","onUnapprovedItemsChange","newApprovedItems","validItem","newUnapprovedItems","unapprovedItem","inventoryStatusColumn","statusLabel","status","CircleCheckIcon","CircleXIcon","CircleHelpIcon","INVENTORY_STRING_KEYS","filterItemData","itemData","statusFilter","textFilter","filteredItemData","createTableData","scriptureRef","itemRegex","tableData","currentBook","currentChapter","currentVerse","line","items","itemIndex","existingItem","tableEntry","newReference","substring","newItem","Inventory","scriptureReference","extractItems","additionalItemsLabels","scope","onScopeChange","allItemsText","approvedItemsText","unapprovedItemsText","unknownItemsText","scopeBookText","scopeChapterText","scopeVerseText","filterText","showAdditionalItemsText","showAdditionalItems","setShowAdditionalItems","setStatusFilter","setTextFilter","selectedItem","setSelectedItem","reducedTableData","newTableData","firstItem","existingEntry","newTableEntry","filteredTableData","allColumns","numberOfAdditionalItems","additionalColumns","_b","rowClickHandler","newSelection","handleScopeChange","handleStatusFilterChange","SearchBar","onSearch","placeholder","isFullWidth","handleInputChange","VerticalTabs","TabsPrimitive","VerticalTabsList","VerticalTabsTrigger","VerticalTabsContent","TabNavigationContentSearch","tabList","searchPlaceholder","headerTitle","isSearchBarFullWidth","direction","tab","Separator","orientation","decorative","SeparatorPrimitive","Sheet","SheetPrimitive","SheetPortal","SheetOverlay","sheetVariants","SheetContent","side","SheetTitle","SheetDescription","Skeleton","TooltipProvider","TooltipPrimitive","Tooltip","TooltipTrigger","TooltipContent","MOBILE_BREAKPOINT","useIsMobile","isMobile","setIsMobile","mql","SIDEBAR_COOKIE_NAME","SIDEBAR_COOKIE_MAX_AGE","SIDEBAR_WIDTH","SIDEBAR_WIDTH_MOBILE","SIDEBAR_WIDTH_ICON","SIDEBAR_KEYBOARD_SHORTCUT","SidebarContext","useSidebar","SidebarProvider","defaultOpen","openProp","setOpenProp","style","openMobile","setOpenMobile","_open","_setOpen","isOpen","openState","toggleSidebar","state","contextValue","Sidebar","collapsible","SidebarTrigger","onClick","PanelLeft","SidebarRail","SidebarInset","SidebarInput","SidebarHeader","SidebarFooter","SidebarSeparator","SidebarContent","SidebarGroup","SidebarGroupLabel","SidebarGroupAction","SidebarGroupContent","SidebarMenu","SidebarMenuItem","sidebarMenuButtonVariants","SidebarMenuButton","isActive","tooltip","Comp","button","SidebarMenuAction","showOnHover","SidebarMenuBadge","SidebarMenuSkeleton","showIcon","width","SidebarMenuSub","SidebarMenuSubItem","SidebarMenuSubButton","SettingsSidebar","extensionLabels","projectOptions","handleSelectSidebarItem","selectedSidebarItem","handleSelectItem","projectId","getProjectNameFromProjectId","project","label","selectedProjectName","SettingsSidebarContentSearch","scrBookColId","scrRefColId","typeColId","detailsColId","defaultScrRefColumnName","defaultScrBookGroupName","defaultTypeColumnName","defaultDetailsColumnName","getColumns","colInfo","showSourceColumn","showSrcCol","info","formatScrRef","compareScrRefs","toRefOrRange","scriptureSelection","offsetStart","offsetEnd","scrRefToBBBCCCVVV","getRowKey","ScriptureResultsViewer","sources","showColumnHeaders","scriptureReferenceColumnName","scriptureBookGroupName","typeColumnName","detailsColumnName","onRowSelected","grouping","setGrouping","scriptureResults","source","getExpandedRowModel","getGroupedRowModel","selectedRows","keys","selectedRow","scrBookGroupName","typeGroupName","groupingOptions","handleSelectChange","selectedGrouping","handleRowClick","getEvenOrOddBandingStyle","getIndent","groupingState","rowIndex","ChevronLeft","DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS","getLocalizeKeyForScrollGroupId","ScrollGroupSelector","availableScrollGroupIds","scrollGroupId","onChangeScrollGroupId","localizedStringsDefaulted","localizedStringKey","localizedStringValue","newScrollGroupString","scrollGroupOptionId","SettingsList","SettingsListItem","primary","secondary","isLoading","loadingMessage","SettingsListHeader","includeSeparator","Card","CardHeader","CardTitle","CardDescription","CardContent","CardFooter","SettingsCard","settingsGroupLabel","settingsGroupDescription","Checklist","listItems","selectedListItems","handleSelectListItem","createLabel","_interopRequireDefault","obj","module","chainPropTypes","propType1","propType2","args","_extends","target","isPlainObject","prototype","deepClone","output","deepmerge","p","r","t","z","reactIs_production_min","hasSymbol","REACT_ELEMENT_TYPE","REACT_PORTAL_TYPE","REACT_FRAGMENT_TYPE","REACT_STRICT_MODE_TYPE","REACT_PROFILER_TYPE","REACT_PROVIDER_TYPE","REACT_CONTEXT_TYPE","REACT_ASYNC_MODE_TYPE","REACT_CONCURRENT_MODE_TYPE","REACT_FORWARD_REF_TYPE","REACT_SUSPENSE_TYPE","REACT_SUSPENSE_LIST_TYPE","REACT_MEMO_TYPE","REACT_LAZY_TYPE","REACT_BLOCK_TYPE","REACT_FUNDAMENTAL_TYPE","REACT_RESPONDER_TYPE","REACT_SCOPE_TYPE","isValidElementType","typeOf","object","$$typeof","$$typeofType","AsyncMode","ConcurrentMode","ContextConsumer","ContextProvider","Element","ForwardRef","Lazy","Memo","Portal","Profiler","StrictMode","Suspense","hasWarnedAboutDeprecatedIsAsyncMode","isAsyncMode","isConcurrentMode","isContextConsumer","isContextProvider","isElement","isForwardRef","isFragment","isLazy","isMemo","isPortal","isProfiler","isStrictMode","isSuspense","reactIs_development","reactIsModule","require$$0","require$$1","getOwnPropertySymbols","hasOwnProperty","propIsEnumerable","toObject","val","shouldUseNative","test1","test2","order2","test3","letter","objectAssign","from","to","symbols","ReactPropTypesSecret","ReactPropTypesSecret_1","has","printWarning","loggedTypeFailures","message","checkPropTypes","typeSpecs","values","location","componentName","getStack","typeSpecName","error","err","ex","stack","checkPropTypes_1","ReactIs","assign","require$$2","require$$3","require$$4","emptyFunctionThatReturnsNull","factoryWithTypeCheckers","isValidElement","throwOnDirectAccess","ITERATOR_SYMBOL","FAUX_ITERATOR_SYMBOL","getIteratorFn","maybeIterable","iteratorFn","ANONYMOUS","ReactPropTypes","createPrimitiveTypeChecker","createAnyTypeChecker","createArrayOfTypeChecker","createElementTypeChecker","createElementTypeTypeChecker","createInstanceTypeChecker","createNodeChecker","createObjectOfTypeChecker","createEnumTypeChecker","createUnionTypeChecker","createShapeTypeChecker","createStrictShapeTypeChecker","is","PropTypeError","createChainableTypeChecker","validate","manualPropTypeCallCache","manualPropTypeWarningCount","checkType","isRequired","propName","propFullName","secret","cacheKey","chainedCheckType","expectedType","propValue","propType","getPropType","preciseType","getPreciseType","typeChecker","expectedClass","expectedClassName","actualClassName","getClassName","expectedValues","valuesString","arrayOfTypeCheckers","checker","getPostfixForTypeWarning","expectedTypes","checkerResult","expectedTypesMessage","isNode","invalidValidatorError","shapeTypes","allKeys","iterator","step","entry","isSymbol","emptyFunction","emptyFunctionWithReset","factoryWithThrowingShims","shim","getShim","propTypesModule","isClassComponent","elementType","acceptingRef","safePropName","warningHint","elementAcceptingRef","PropTypes","elementAcceptingRef$1","specialProperty","exactProp","propTypes","unsupportedProps","prop","formatMuiErrorMessage","code","url","REACT_SERVER_CONTEXT_TYPE","REACT_OFFSCREEN_TYPE","enableScopeAPI","enableCacheElement","enableTransitionTracing","enableLegacyHidden","enableDebugTracing","REACT_MODULE_REFERENCE","SuspenseList","hasWarnedAboutDeprecatedIsConcurrentMode","isSuspenseList","fnNameMatchRegex","getFunctionName","fn","getFunctionComponentName","Component","fallback","getWrappedName","outerType","innerType","wrapperName","functionName","getDisplayName","HTMLElementType","refType","refType$1","capitalize","string","_formatMuiErrorMessage","createChainedFunction","funcs","acc","func","debounce","wait","timeout","debounced","later","deprecatedPropType","validator","reason","componentNameSafe","propFullNameSafe","isMuiElement","muiNames","_muiName","_element$type","ownerDocument","node","ownerWindow","requirePropFactory","componentNameInError","prevPropTypes","requiredProp","defaultTypeChecker","typeCheckerResult","setRef","useEnhancedEffect","useEnhancedEffect$1","globalId","useGlobalId","idOverride","defaultId","setDefaultId","maybeReactUseId","useId","reactId","unsupportedProp","useControlled","controlled","defaultProp","name","isControlled","valueState","setValue","defaultValue","setValueIfUncontrolled","newValue","useEventCallback","useForkRef","refs","instance","UNINITIALIZED","useLazyRef","init","initArg","EMPTY","useOnMount","Timeout","delay","useTimeout","hadKeyboardEvent","hadFocusVisibleRecently","hadFocusVisibleRecentlyTimeout","inputTypesWhitelist","focusTriggersKeyboardModality","tagName","handlePointerDown","handleVisibilityChange","prepare","doc","isFocusVisible","useIsFocusVisible","isFocusVisibleRef","handleBlurVisible","handleFocusVisible","resolveProps","defaultProps","defaultSlotProps","slotProps","slotPropName","composeClasses","slots","getUtilityClass","classes","slot","utilityClass","defaultGenerator","createClassNameGenerator","generate","generator","ClassNameGenerator","ClassNameGenerator$1","globalStateClasses","generateUtilityClass","globalStatePrefix","globalStateClass","generateUtilityClasses","result","clamp","min","max","_objectWithoutPropertiesLoose","excluded","sourceKeys","_excluded","sortBreakpointsValues","breakpointsAsArray","breakpoint1","breakpoint2","createBreakpoints","breakpoints","unit","other","sortedValues","up","down","between","start","end","endIndex","only","not","keyIndex","shape","shape$1","responsivePropType","responsivePropType$1","merge","defaultBreakpoints","handleBreakpoints","styleFromPropValue","theme","themeBreakpoints","breakpoint","mediaKey","cssKey","createEmptyBreakpointObject","breakpointsInput","_breakpointsInput$key","breakpointStyleKey","removeUnusedBreakpoints","breakpointKeys","breakpointOutput","getPath","path","checkVars","getStyleValue","themeMapping","transform","propValueFinal","userValue","cssProperty","themeKey","memoize","cache","arg","properties","directions","aliases","getCssProperties","property","marginKeys","paddingKeys","spacingKeys","createUnaryUnit","_getPath","themeSpacing","abs","createUnarySpacing","getValue","transformer","transformed","getStyleFromPropValue","cssProperties","resolveCssProperty","margin","padding","createSpacing","spacingInput","spacing","argsInput","argument","compose","styles","handlers","borderTransform","createBorderStyle","border","borderTop","borderRight","borderBottom","borderLeft","borderColor","borderTopColor","borderRightColor","borderBottomColor","borderLeftColor","outline","outlineColor","borderRadius","gap","columnGap","rowGap","gridColumn","gridRow","gridAutoFlow","gridAutoColumns","gridAutoRows","gridTemplateColumns","gridTemplateRows","gridTemplateAreas","gridArea","paletteTransform","color","bgcolor","backgroundColor","sizingTransform","maxWidth","_props$theme","_props$theme2","breakpointsValues","minWidth","height","maxHeight","minHeight","boxSizing","defaultSxConfig","defaultSxConfig$1","objectsHaveSameKeys","objects","union","callIfFn","maybeFn","unstable_createStyleFunctionSx","getThemeValue","config","styleFunctionSx","_theme$unstable_sxCon","sx","traverse","sxInput","sxObject","emptyBreakpoints","breakpointsKeys","css","styleKey","styleFunctionSx$1","applyStyles","createTheme","paletteInput","shapeInput","muiTheme","isObjectEmpty","useTheme","defaultTheme","contextTheme","ThemeContext","systemDefaultTheme","useThemeWithoutDefault","_excluded2","_excluded3","isEmpty","isStringTag","tag","shouldForwardProp","lowercaseFirstLetter","resolveTheme","themeId","defaultOverridesResolver","processStyleArg","callableStyle","_ref","ownerState","resolvedStylesArg","resolvedStyle","variants","isMatch","createStyled","input","rootShouldForwardProp","slotShouldForwardProp","systemSx","inputOptions","processStyles","componentSlot","inputSkipVariantsResolver","inputSkipSx","overridesResolver","skipVariantsResolver","skipSx","shouldForwardPropOption","defaultStyledResolver","styledEngineStyled","transformStyleArg","stylesArg","muiStyledResolver","styleArg","expressions","transformedStyleArg","expressionsWithDefaultTheme","styleOverrides","resolvedStyleOverrides","slotKey","slotStyle","_theme$components","themeVariants","numOfCustomFnsApplied","placeholders","displayName","getThemeProps","params","useThemeProps","clampWrapper","hexToRgb","re","colors","decomposeColor","marker","colorSpace","recomposeColor","hslToRgb","rgb","getLuminance","getContrastRatio","foreground","background","lumA","lumB","alpha","darken","coefficient","lighten","createMixins","mixins","common","common$1","grey","grey$1","purple","purple$1","red","red$1","orange","orange$1","blue","blue$1","lightBlue","lightBlue$1","green","green$1","light","dark","addLightOrDark","intent","shade","tonalOffset","tonalOffsetLight","tonalOffsetDark","getDefaultPrimary","mode","getDefaultSecondary","getDefaultError","getDefaultInfo","getDefaultSuccess","getDefaultWarning","createPalette","palette","contrastThreshold","success","warning","getContrastText","contrastText","contrast","augmentColor","mainShade","lightShade","darkShade","modes","round","caseAllCaps","defaultFontFamily","createTypography","typography","fontFamily","fontSize","fontWeightLight","fontWeightRegular","fontWeightMedium","fontWeightBold","htmlFontSize","allVariants","pxToRem2","coef","pxToRem","buildVariant","fontWeight","lineHeight","letterSpacing","casing","shadowKeyUmbraOpacity","shadowKeyPenumbraOpacity","shadowAmbientShadowOpacity","createShadow","px","shadows","shadows$1","easing","duration","formatMs","milliseconds","getAutoHeightDuration","constant","createTransitions","inputTransitions","mergedEasing","mergedDuration","durationOption","easingOption","isString","isNumber","animatedProp","zIndex","zIndex$1","mixinsInput","transitionsInput","typographyInput","systemTheme","systemCreateTheme","stateClasses","component","child","stateClass","defaultTheme$1","THEME_ID","systemUseThemeProps","styled","styled$1","getSvgIconUtilityClass","useUtilityClasses","SvgIconRoot","_theme$transitions","_theme$transitions$cr","_theme$transitions2","_theme$typography","_theme$typography$pxT","_theme$typography2","_theme$typography2$px","_theme$typography3","_theme$typography3$px","_palette$ownerState$c","_palette","_palette2","_palette3","SvgIcon","inProps","htmlColor","inheritViewBox","titleAccess","viewBox","hasSvgAsChild","more","_jsxs","_jsx","SvgIcon$1","createSvgIcon","unstable_ClassNameGenerator","exports","_utils","ArrowRight","default_1","_createSvgIcon","_jsxRuntime","isHostComponent","appendOwnerState","otherProps","defaultContextValue","ClassNameConfiguratorContext","useClassNamesOverride","disableDefaultClasses","extractEventHandlers","excludeKeys","resolveComponentProps","componentProps","slotState","omitEventHandlers","mergeSlotProps","parameters","getSlotProps","additionalProps","externalSlotProps","externalForwardedProps","joinedClasses","mergedStyle","eventHandlers","componentsPropsWithoutEventHandlers","otherPropsWithoutEventHandlers","internalSlotProps","useSlotProps","_parameters$additiona","skipResolvingSlotProps","rest","resolvedComponentsProps","mergedProps","internalRef","GLOBAL_CLASS_PREFIX","buildStateClass","buildSlotClass","getContainer","container","forwardedRef","disablePortal","mountNode","setMountNode","handleRef","newProps","ReactDOM","top","bottom","right","left","auto","basePlacements","clippingParents","viewport","popper","reference","variationPlacements","placement","placements","beforeRead","read","afterRead","beforeMain","main","afterMain","beforeWrite","write","afterWrite","modifierPhases","getNodeName","getWindow","OwnElement","isHTMLElement","isShadowRoot","attributes","effect","_ref2","initialStyles","styleProperties","attribute","applyStyles$1","getBasePlacement","getUAString","uaData","isLayoutViewport","getBoundingClientRect","includeScale","isFixedStrategy","clientRect","scaleX","scaleY","visualViewport","addVisualOffsets","getLayoutRect","contains","parent","rootNode","next","getComputedStyle","isTableElement","getDocumentElement","getParentNode","getTrueOffsetParent","getContainingBlock","isFirefox","isIE","elementCss","currentNode","getOffsetParent","window","offsetParent","getMainAxisFromPlacement","within","mathMax","mathMin","withinMaxClamp","getFreshSideObject","mergePaddingObject","paddingObject","expandToHashMap","hashMap","toPaddingObject","arrow","_state$modifiersData$","arrowElement","popperOffsets","basePlacement","axis","isVertical","len","arrowRect","minProp","maxProp","endDiff","startDiff","arrowOffsetParent","clientSize","centerToReference","center","offset","axisProp","_options$element","arrow$1","getVariation","unsetSides","roundOffsetsByDPR","win","dpr","mapToStyles","_Object$assign2","popperRect","variation","offsets","gpuAcceleration","adaptive","roundOffsets","isFixed","_offsets$x","_offsets$y","_ref3","hasX","hasY","sideX","sideY","heightProp","widthProp","offsetY","offsetX","commonStyles","_ref4","_Object$assign","computeStyles","_ref5","_options$gpuAccelerat","_options$adaptive","_options$roundOffsets","computeStyles$1","passive","_options$scroll","scroll","_options$resize","resize","scrollParents","scrollParent","eventListeners","hash","getOppositePlacement","matched","getOppositeVariationPlacement","getWindowScroll","scrollLeft","scrollTop","getWindowScrollBarX","getViewportRect","strategy","html","layoutViewport","getDocumentRect","_element$ownerDocumen","winScroll","body","isScrollParent","_getComputedStyle","overflow","overflowX","overflowY","getScrollParent","listScrollParents","list","isBody","updatedList","rectToClientRect","rect","getInnerBoundingClientRect","getClientRectFromMixedType","clippingParent","getClippingParents","canEscapeClipping","clipperElement","getClippingRect","boundary","rootBoundary","mainClippingParents","firstClippingParent","clippingRect","accRect","computeOffsets","commonX","commonY","mainAxis","detectOverflow","_options","_options$placement","_options$strategy","_options$boundary","_options$rootBoundary","_options$elementConte","elementContext","_options$altBoundary","altBoundary","_options$padding","altContext","clippingClientRect","referenceClientRect","popperClientRect","elementClientRect","overflowOffsets","offsetData","multiply","computeAutoPlacement","flipVariations","_options$allowedAutoP","allowedAutoPlacements","allPlacements","allowedPlacements","overflows","getExpandedFallbackPlacements","oppositePlacement","flip","_options$mainAxis","checkMainAxis","_options$altAxis","checkAltAxis","specifiedFallbackPlacements","_options$flipVariatio","preferredPlacement","isBasePlacement","fallbackPlacements","referenceRect","checksMap","makeFallbackChecks","firstFittingPlacement","_basePlacement","isStartVariation","mainVariationSide","altVariationSide","checks","check","numberOfChecks","_loop","_i","fittingPlacement","_ret","flip$1","getSideOffsets","preventedOffsets","isAnySideFullyClipped","hide","referenceOverflow","popperAltOverflow","referenceClippingOffsets","popperEscapeOffsets","isReferenceHidden","hasPopperEscaped","hide$1","distanceAndSkiddingToXY","rects","invertDistance","skidding","distance","_options$offset","_data$state$placement","offset$1","popperOffsets$1","getAltAxis","preventOverflow","_options$tether","tether","_options$tetherOffset","tetherOffset","altAxis","tetherOffsetValue","normalizedTetherOffsetValue","offsetModifierState","_offsetModifierState$","mainSide","altSide","additive","minLen","maxLen","arrowPaddingObject","arrowPaddingMin","arrowPaddingMax","arrowLen","minOffset","maxOffset","clientOffset","offsetModifierValue","tetherMin","tetherMax","preventedOffset","_offsetModifierState$2","_mainSide","_altSide","_offset","_len","_min","_max","isOriginSide","_offsetModifierValue","_tetherMin","_tetherMax","_preventedOffset","preventOverflow$1","getHTMLElementScroll","getNodeScroll","isElementScaled","getCompositeRect","elementOrVirtualElement","isOffsetParentAnElement","offsetParentIsScaled","documentElement","order","modifiers","map","visited","modifier","sort","requires","dep","depModifier","orderModifiers","orderedModifiers","phase","pending","resolve","mergeByName","merged","current","existing","DEFAULT_OPTIONS","areValidElements","_key","popperGenerator","generatorOptions","_generatorOptions","_generatorOptions$def","defaultModifiers","_generatorOptions$def2","defaultOptions","effectCleanupFns","isDestroyed","setOptionsAction","cleanupModifierEffects","runModifierEffects","_state$elements","_state$orderedModifie","_state$orderedModifie2","_ref$options","cleanupFn","noopFn","createPopper","COMPONENT_NAME","getPopperUtilityClass","flipPlacement","resolveAnchorEl","anchorEl","isVirtualElement","defaultPopperOptions","PopperTooltip","_slots$root","initialPlacement","popperOptions","popperRefProp","TransitionProps","tooltipRef","ownRef","popperRef","handlePopperRef","handlePopperRefRef","rtlPlacement","setPlacement","resolvedAnchorElement","setResolvedAnchorElement","handlePopperUpdate","box","popperModifiers","childProps","Root","rootProps","Popper","containerProp","keepMounted","transition","exited","setExited","handleEnter","handleExited","resolvedAnchorEl","display","transitionProps","useThemeSystem","_setPrototypeOf","_inheritsLoose","subClass","superClass","setPrototypeOf","timeoutsShape","TransitionGroupContext","forceReflow","UNMOUNTED","EXITED","ENTERING","ENTERED","EXITING","Transition","_React$Component","_this","parentGroup","appear","initialStatus","prevState","nextIn","_proto","prevProps","nextStatus","exit","enter","mounting","_this2","appearing","maybeNode","maybeAppearing","timeouts","enterTimeout","_this3","nextState","callback","_this4","active","handler","doesNotHaveTimeoutOrListener","maybeNextCallback","_this$props","pt","noop","Transition$1","reflow","getTransitionProps","_style$transitionDura","_style$transitionTimi","getScale","isWebKit154","Grow","addEndListener","inProp","onEnter","onEntered","onEntering","onExit","onExited","onExiting","TransitionComponent","timer","autoTimeout","nodeRef","normalizedTransitionCallback","maybeIsAppearing","handleEntering","isAppearing","transitionDuration","transitionTimingFunction","handleEntered","handleExiting","handleExit","Grow$1","PopperRoot","BasePopper","components","componentsProps","RootComponent","Popper$1","getTooltipUtilityClass","tooltipClasses","tooltipClasses$1","disableInteractive","touch","TooltipPopper","TooltipTooltip","TooltipArrow","hystersisOpen","hystersisTimer","cursorPosition","composeEventHandler","eventHandler","_slots$popper","_slots$transition","_slots$tooltip","_slots$arrow","_slotProps$popper","_ref6","_slotProps$popper2","_slotProps$transition","_slotProps$tooltip","_ref7","_slotProps$tooltip2","_slotProps$arrow","_ref8","_slotProps$arrow2","childrenProp","describeChild","disableFocusListener","disableHoverListener","disableInteractiveProp","disableTouchListener","enterDelay","enterNextDelay","enterTouchDelay","followCursor","idProp","leaveDelay","leaveTouchDelay","onClose","onOpen","PopperComponentProp","PopperProps","title","TransitionComponentProp","isRtl","childNode","setChildNode","arrowRef","setArrowRef","ignoreNonTouchEvents","closeTimer","enterTimer","leaveTimer","touchTimer","setOpenState","prevUserSelect","stopTouchInteraction","handleOpen","handleClose","handleLeave","focusVisibleRef","setChildIsFocusVisible","handleBlur","handleFocus","detectTouchStart","childrenProps","handleMouseOver","handleMouseLeave","handleTouchStart","handleTouchEnd","nativeEvent","handleMouseMove","nameOrDescProps","titleIsString","interactiveWrapperListeners","_PopperProps$popperOp","tooltipModifiers","PopperComponent","TooltipComponent","ArrowComponent","popperProps","tooltipProps","tooltipArrowProps","TransitionPropsInner","Tooltip$1","getIcon","icon","menuLabel","leading","MuiListItemIcon","MenuItem","allowForLeadingIcons","iconPathBefore","iconPathAfter","hasAutoFocus","isDense","isSubMenuParent","hasDisabledGutters","hasDivider","focusVisibleClassName","menuItem","MuiMenuItem","MuiListItemText","getAllGroups","menuDefinition","SubMenu","setAnchorEl","parentMenuItem","parentItemProps","handleParentMenuItemClick","renderSubMenuItems","includedGroups","group","GroupedMenuItemList","Menu","getOrderedGroupItems","groupId","allItems","menuProps","commandHandler","groupsToInclude","sortedGroups","itemArray","allowSpaceForLeadingIcons","createMenuItemProps","isLastItemInGroup","divKey","itemInfo","menuItemProps","TopLevelMenu","columnId","MenuColumn","metadata","Grid","List","GridMenu","multiColumnMenu","sortedColumns","columnNumbers","columnName","col","getUsePromiseOptionsDefaults","usePromise","promiseFactoryCallback","defaultValueRef","optionsDefaultedRef","setIsLoading","promiseIsCurrent","MenuIcon","HamburgerMenuButton","menuProvider","normalMenu","fullMenu","containerRef","ariaLabelPrefix","isMenuOpen","setMenuOpen","showFullMenu","setShowFullMenu","handleMenuItemClick","handleMenuButtonClick","prevIsOpen","isOpening","menuCommandHandler","command","setOffset","normalMenuData","fullMenuData","menu","IconButton","Drawer","isTooltipSuppressed","adjustMarginToAlignToEdge","MuiIconButton","Spinner","LoaderCircle","TextField","hasError","helperText","onFocus","onBlur","ShadLabel","Toolbar","AppBar","MuiToolbar","alertVariants","Alert","AlertTitle","AlertDescription","Sonner","Toaster","Slider","SliderPrimitive","Switch","SwitchPrimitives","Tabs","TabsList","TabsTrigger","TabsContent","InstallButton","isInstalling","handleClick","buttonText","Download","EnableButton","isEnabling","DisableButton","isDisabling","UpdateButton","isUpdating","MarkdownRenderer","markdown","anchorTarget","Markdown","FilterButton","Filter","DropdownMenuItemType","DropdownMenuItemType2","FilterDropdown","groups","NoExtensionsFound","MoreInfo","category","downloads","languages","moreInfoUrl","numberFormatted","NumberFormat","handleScrollToBottom","User","locale","LucideLink","CircleHelp","VersionHistory","versionHistory","showAllVersions","setShowAllVersions","currentDate","formatTimeString","dateString","date","dateDiff","yearDiff","monthDiff","dayDiff","timeString","sortedEntries","Footer","publisherDisplayName","fileSize","locales","formattedFileSize","formatBytes","languageNames","codes","displayNames","useEvent","unsubscriber","noopUnsubscriber","useEventAsync","unsubscribe","unsub"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAGA,MAAMA,KAAgBC,GAAoB,EAAE,QAAQ,MAAO,CAAA;AAyDpD,SAASC,KAAMC,GAAsB;AACnC,SAAAH,GAAcI,GAAKD,CAAM,CAAC;AACnC;ACzDO,MAAME,KAAQC,EAAM;AAAA,EACzB,CAAC,EAAE,WAAAC,GAAW,MAAAC,GAAM,GAAGC,EAAA,GAASC,MAE5B,gBAAAC;AAAA,IAAC;AAAA,IAAA;AAAA,MACC,MAAAH;AAAA,MACA,WAAWN;AAAA,QACT;AAAA,QACAK;AAAA,MACF;A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AA,EACA;AAAA,EACA;AAAA;AAAA,EAEA;AAAA,EACA;AAAA,EACA;AACF,GAAGC,KAAI;AAAA,EACL;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AACF,GAAGC,KAAI;AAAA,EACL;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA;AAAA;AAAA,EAGA;AAAA,EACA;AAAA,EAC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;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","x_google_ignoreList":[3,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,83,84,85,86,87,88,89,90,91,92,93,94,95,96,97,98,99,100,101,102,103,104,105,106,107,108,109,110,111,112,113,114,115,116,117,118,119,120,121,122,123,124,125,126,127,128,129,130,131,132,133,134,135,136,137,138,139,140,141,142,143,144,145,146,147,148,149,150,151,152,153,154,155,156,157,158,159,160,161,162,163,164,165,166,167,168,169,170,171,172,173,174,175,176,177,178,179,180,181,182,183,184,185,186,187,188,189,190,191,192,193,194,195,196,197,198,199,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,230]} \ No newline at end of file +{"version":3,"file":"index.js","sources":["../src/utils/shadcn-ui.util.ts","../src/components/shadcn-ui/input.tsx","../src/components/advanced/book-chapter-control/book-chapter-input.component.tsx","../../../node_modules/@sillsdev/scripture/dist/index.es.js","../src/components/shadcn-ui/dropdown-menu.tsx","../src/components/advanced/book-chapter-control/book-menu-item.component.tsx","../src/components/advanced/book-chapter-control/chapter-select.component.tsx","../src/components/advanced/book-chapter-control/go-to-menu-item.component.tsx","../src/components/advanced/book-chapter-control/book-chapter-control.component.tsx","../src/components/shadcn-ui/button.tsx","../src/components/shadcn-ui/label.tsx","../src/components/shadcn-ui/radio-group.tsx","../src/components/shadcn-ui/popover.tsx","../src/components/shadcn-ui/dialog.tsx","../src/components/shadcn-ui/command.tsx","../src/components/basics/combo-box.component.tsx","../src/components/basics/chapter-range-selector.component.tsx","../src/components/advanced/book-selector.component.tsx","../src/components/advanced/data-table/data-table-column-toggle.component.tsx","../src/components/shadcn-ui/select.tsx","../src/components/advanced/data-table/data-table-pagination.component.tsx","../src/components/shadcn-ui/table.tsx","../src/components/advanced/data-table/data-table.component.tsx","../src/components/advanced/inventory/occurrences-table.component.tsx","../src/components/shadcn-ui/checkbox.tsx","../src/components/advanced/inventory/inventory-utils.ts","../src/components/shadcn-ui/toggle.tsx","../src/components/shadcn-ui/toggle-group.tsx","../src/components/advanced/inventory/inventory-columns.tsx","../src/components/advanced/inventory/inventory.component.tsx","../src/components/basics/search-bar.component.tsx","../src/components/basics/tabs-vertical.tsx","../src/components/advanced/tab-navigation-content-search.component.tsx","../src/components/shadcn-ui/separator.tsx","../src/components/shadcn-ui/sheet.tsx","../src/components/shadcn-ui/skeleton.tsx","../src/components/shadcn-ui/tooltip.tsx","../src/components/hooks/use-mobile.tsx","../src/components/shadcn-ui/sidebar.tsx","../src/components/advanced/settings-components/settings-sidebar.component.tsx","../src/components/advanced/settings-components/settings-sidebar-content-search.component.tsx","../src/components/advanced/scripture-results-viewer/scripture-results-viewer.component.tsx","../src/components/advanced/scroll-group-selector.component.tsx","../src/components/advanced/settings-components/settings-list.component.tsx","../src/components/shadcn-ui/card.tsx","../src/components/advanced/settings-components/settings-card.component.tsx","../src/components/basics/checklist.component.tsx","../../../node_modules/@babel/runtime/helpers/interopRequireDefault.js","../../../node_modules/@mui/utils/chainPropTypes/chainPropTypes.js","../../../node_modules/@babel/runtime/helpers/esm/extends.js","../../../node_modules/@mui/utils/deepmerge/deepmerge.js","../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.production.min.js","../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.development.js","../../../node_modules/prop-types/node_modules/react-is/index.js","../../../node_modules/object-assign/index.js","../../../node_modules/prop-types/lib/ReactPropTypesSecret.js","../../../node_modules/prop-types/lib/has.js","../../../node_modules/prop-types/checkPropTypes.js","../../../node_modules/prop-types/factoryWithTypeCheckers.js","../../../node_modules/prop-types/factoryWithThrowingShims.js","../../../node_modules/prop-types/index.js","../../../node_modules/@mui/utils/elementAcceptingRef/elementAcceptingRef.js","../../../node_modules/@mui/utils/exactProp/exactProp.js","../../../node_modules/@mui/utils/formatMuiErrorMessage/formatMuiErrorMessage.js","../../../node_modules/react-is/cjs/react-is.production.min.js","../../../node_modules/react-is/cjs/react-is.development.js","../../../node_modules/react-is/index.js","../../../node_modules/@mui/utils/getDisplayName/getDisplayName.js","../../../node_modules/@mui/utils/HTMLElementType/HTMLElementType.js","../../../node_modules/@mui/utils/refType/refType.js","../../../node_modules/@mui/utils/capitalize/capitalize.js","../../../node_modules/@mui/utils/createChainedFunction/createChainedFunction.js","../../../node_modules/@mui/utils/debounce/debounce.js","../../../node_modules/@mui/utils/deprecatedPropType/deprecatedPropType.js","../../../node_modules/@mui/utils/isMuiElement/isMuiElement.js","../../../node_modules/@mui/utils/ownerDocument/ownerDocument.js","../../../node_modules/@mui/utils/ownerWindow/ownerWindow.js","../../../node_modules/@mui/utils/requirePropFactory/requirePropFactory.js","../../../node_modules/@mui/utils/setRef/setRef.js","../../../node_modules/@mui/utils/useEnhancedEffect/useEnhancedEffect.js","../../../node_modules/@mui/utils/useId/useId.js","../../../node_modules/@mui/utils/unsupportedProp/unsupportedProp.js","../../../node_modules/@mui/utils/useControlled/useControlled.js","../../../node_modules/@mui/utils/useEventCallback/useEventCallback.js","../../../node_modules/@mui/utils/useForkRef/useForkRef.js","../../../node_modules/@mui/utils/useLazyRef/useLazyRef.js","../../../node_modules/@mui/utils/useOnMount/useOnMount.js","../../../node_modules/@mui/utils/useTimeout/useTimeout.js","../../../node_modules/@mui/utils/useIsFocusVisible/useIsFocusVisible.js","../../../node_modules/@mui/utils/resolveProps/resolveProps.js","../../../node_modules/@mui/utils/composeClasses/composeClasses.js","../../../node_modules/@mui/utils/ClassNameGenerator/ClassNameGenerator.js","../../../node_modules/@mui/utils/generateUtilityClass/generateUtilityClass.js","../../../node_modules/@mui/utils/generateUtilityClasses/generateUtilityClasses.js","../../../node_modules/@mui/utils/clamp/clamp.js","../../../node_modules/@babel/runtime/helpers/esm/objectWithoutPropertiesLoose.js","../../../node_modules/@mui/system/esm/createTheme/createBreakpoints.js","../../../node_modules/@mui/system/esm/createTheme/shape.js","../../../node_modules/@mui/system/esm/responsivePropType.js","../../../node_modules/@mui/system/esm/merge.js","../../../node_modules/@mui/system/esm/breakpoints.js","../../../node_modules/@mui/system/esm/style.js","../../../node_modules/@mui/system/esm/memoize.js","../../../node_modules/@mui/system/esm/spacing.js","../../../node_modules/@mui/system/esm/createTheme/createSpacing.js","../../../node_modules/@mui/system/esm/compose.js","../../../node_modules/@mui/system/esm/borders.js","../../../node_modules/@mui/system/esm/cssGrid.js","../../../node_modules/@mui/system/esm/palette.js","../../../node_modules/@mui/system/esm/sizing.js","../../../node_modules/@mui/system/esm/styleFunctionSx/defaultSxConfig.js","../../../node_modules/@mui/system/esm/styleFunctionSx/styleFunctionSx.js","../../../node_modules/@mui/system/esm/createTheme/applyStyles.js","../../../node_modules/@mui/system/esm/createTheme/createTheme.js","../../../node_modules/@mui/system/esm/useThemeWithoutDefault.js","../../../node_modules/@mui/system/esm/useTheme.js","../../../node_modules/@mui/system/esm/createStyled.js","../../../node_modules/@mui/system/esm/useThemeProps/getThemeProps.js","../../../node_modules/@mui/system/esm/useThemeProps/useThemeProps.js","../../../node_modules/@mui/system/esm/colorManipulator.js","../../../node_modules/@mui/material/styles/createMixins.js","../../../node_modules/@mui/material/colors/common.js","../../../node_modules/@mui/material/colors/grey.js","../../../node_modules/@mui/material/colors/purple.js","../../../node_modules/@mui/material/colors/red.js","../../../node_modules/@mui/material/colors/orange.js","../../../node_modules/@mui/material/colors/blue.js","../../../node_modules/@mui/material/colors/lightBlue.js","../../../node_modules/@mui/material/colors/green.js","../../../node_modules/@mui/material/styles/createPalette.js","../../../node_modules/@mui/material/styles/createTypography.js","../../../node_modules/@mui/material/styles/shadows.js","../../../node_modules/@mui/material/styles/createTransitions.js","../../../node_modules/@mui/material/styles/zIndex.js","../../../node_modules/@mui/material/styles/createTheme.js","../../../node_modules/@mui/material/styles/defaultTheme.js","../../../node_modules/@mui/material/styles/identifier.js","../../../node_modules/@mui/material/styles/useThemeProps.js","../../../node_modules/@mui/material/styles/styled.js","../../../node_modules/@mui/material/SvgIcon/svgIconClasses.js","../../../node_modules/@mui/material/SvgIcon/SvgIcon.js","../../../node_modules/@mui/material/utils/createSvgIcon.js","../../../node_modules/@mui/material/utils/index.js","../../../node_modules/@mui/icons-material/utils/createSvgIcon.js","../../../node_modules/@mui/icons-material/ArrowRight.js","../../../node_modules/@mui/base/utils/isHostComponent.js","../../../node_modules/@mui/base/utils/appendOwnerState.js","../../../node_modules/@mui/base/utils/ClassNameConfigurator.js","../../../node_modules/@mui/base/utils/extractEventHandlers.js","../../../node_modules/@mui/base/utils/resolveComponentProps.js","../../../node_modules/@mui/base/utils/omitEventHandlers.js","../../../node_modules/@mui/base/utils/mergeSlotProps.js","../../../node_modules/@mui/base/utils/useSlotProps.js","../../../node_modules/@mui/base/generateUtilityClass/index.js","../../../node_modules/@mui/base/generateUtilityClasses/index.js","../../../node_modules/@mui/base/Portal/Portal.js","../../../node_modules/@popperjs/core/lib/enums.js","../../../node_modules/@popperjs/core/lib/dom-utils/getNodeName.js","../../../node_modules/@popperjs/core/lib/dom-utils/getWindow.js","../../../node_modules/@popperjs/core/lib/dom-utils/instanceOf.js","../../../node_modules/@popperjs/core/lib/modifiers/applyStyles.js","../../../node_modules/@popperjs/core/lib/utils/getBasePlacement.js","../../../node_modules/@popperjs/core/lib/utils/math.js","../../../node_modules/@popperjs/core/lib/utils/userAgent.js","../../../node_modules/@popperjs/core/lib/dom-utils/isLayoutViewport.js","../../../node_modules/@popperjs/core/lib/dom-utils/getBoundingClientRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/getLayoutRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/contains.js","../../../node_modules/@popperjs/core/lib/dom-utils/getComputedStyle.js","../../../node_modules/@popperjs/core/lib/dom-utils/isTableElement.js","../../../node_modules/@popperjs/core/lib/dom-utils/getDocumentElement.js","../../../node_modules/@popperjs/core/lib/dom-utils/getParentNode.js","../../../node_modules/@popperjs/core/lib/dom-utils/getOffsetParent.js","../../../node_modules/@popperjs/core/lib/utils/getMainAxisFromPlacement.js","../../../node_modules/@popperjs/core/lib/utils/within.js","../../../node_modules/@popperjs/core/lib/utils/getFreshSideObject.js","../../../node_modules/@popperjs/core/lib/utils/mergePaddingObject.js","../../../node_modules/@popperjs/core/lib/utils/expandToHashMap.js","../../../node_modules/@popperjs/core/lib/modifiers/arrow.js","../../../node_modules/@popperjs/core/lib/utils/getVariation.js","../../../node_modules/@popperjs/core/lib/modifiers/computeStyles.js","../../../node_modules/@popperjs/core/lib/modifiers/eventListeners.js","../../../node_modules/@popperjs/core/lib/utils/getOppositePlacement.js","../../../node_modules/@popperjs/core/lib/utils/getOppositeVariationPlacement.js","../../../node_modules/@popperjs/core/lib/dom-utils/getWindowScroll.js","../../../node_modules/@popperjs/core/lib/dom-utils/getWindowScrollBarX.js","../../../node_modules/@popperjs/core/lib/dom-utils/getViewportRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/getDocumentRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/isScrollParent.js","../../../node_modules/@popperjs/core/lib/dom-utils/getScrollParent.js","../../../node_modules/@popperjs/core/lib/dom-utils/listScrollParents.js","../../../node_modules/@popperjs/core/lib/utils/rectToClientRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/getClippingRect.js","../../../node_modules/@popperjs/core/lib/utils/computeOffsets.js","../../../node_modules/@popperjs/core/lib/utils/detectOverflow.js","../../../node_modules/@popperjs/core/lib/utils/computeAutoPlacement.js","../../../node_modules/@popperjs/core/lib/modifiers/flip.js","../../../node_modules/@popperjs/core/lib/modifiers/hide.js","../../../node_modules/@popperjs/core/lib/modifiers/offset.js","../../../node_modules/@popperjs/core/lib/modifiers/popperOffsets.js","../../../node_modules/@popperjs/core/lib/utils/getAltAxis.js","../../../node_modules/@popperjs/core/lib/modifiers/preventOverflow.js","../../../node_modules/@popperjs/core/lib/dom-utils/getHTMLElementScroll.js","../../../node_modules/@popperjs/core/lib/dom-utils/getNodeScroll.js","../../../node_modules/@popperjs/core/lib/dom-utils/getCompositeRect.js","../../../node_modules/@popperjs/core/lib/utils/orderModifiers.js","../../../node_modules/@popperjs/core/lib/utils/debounce.js","../../../node_modules/@popperjs/core/lib/utils/mergeByName.js","../../../node_modules/@popperjs/core/lib/createPopper.js","../../../node_modules/@popperjs/core/lib/popper.js","../../../node_modules/@mui/base/Popper/popperClasses.js","../../../node_modules/@mui/base/Popper/Popper.js","../../../node_modules/@mui/material/styles/useTheme.js","../../../node_modules/@babel/runtime/helpers/esm/setPrototypeOf.js","../../../node_modules/@babel/runtime/helpers/esm/inheritsLoose.js","../../../node_modules/react-transition-group/esm/config.js","../../../node_modules/react-transition-group/esm/utils/PropTypes.js","../../../node_modules/react-transition-group/esm/TransitionGroupContext.js","../../../node_modules/react-transition-group/esm/utils/reflow.js","../../../node_modules/react-transition-group/esm/Transition.js","../../../node_modules/@mui/material/transitions/utils.js","../../../node_modules/@mui/material/Grow/Grow.js","../../../node_modules/@mui/material/Popper/Popper.js","../../../node_modules/@mui/material/Tooltip/tooltipClasses.js","../../../node_modules/@mui/material/Tooltip/Tooltip.js","../src/components/mui/menu-item.component.tsx","../src/components/mui/grouped-menu-item-list.component.tsx","../src/components/mui/top-level-menu.component.tsx","../src/components/mui/grid-menu.component.tsx","../src/hooks/use-promise.hook.ts","../../../node_modules/@mui/icons-material/esm/Menu.js","../src/components/mui/hamburger-menu-button.component.tsx","../src/components/mui/icon-button.component.tsx","../src/components/basics/spinner.component.tsx","../src/components/basics/text-field.component.tsx","../src/components/mui/toolbar.component.tsx","../src/components/shadcn-ui/alert.tsx","../src/components/shadcn-ui/sonner.tsx","../src/components/shadcn-ui/slider.tsx","../src/components/shadcn-ui/switch.tsx","../src/components/shadcn-ui/tabs.tsx","../src/components/advanced/extension-marketplace/buttons/install-button.component.tsx","../src/components/advanced/extension-marketplace/buttons/enable-button.component.tsx","../src/components/advanced/extension-marketplace/buttons/disable-button.component.tsx","../src/components/advanced/extension-marketplace/buttons/update-button.component.tsx","../src/components/advanced/extension-marketplace/markdown-renderer.component.tsx","../src/components/advanced/extension-marketplace/buttons/filter-button.component.tsx","../src/components/advanced/extension-marketplace/filter-dropdown.component.tsx","../src/components/advanced/extension-marketplace/no-extensions-found.component.tsx","../src/components/advanced/extension-marketplace/more-info.component.tsx","../src/components/advanced/extension-marketplace/version-history.component.tsx","../src/components/advanced/extension-marketplace/footer.component.tsx","../src/hooks/use-event.hook.ts","../src/hooks/use-event-async.hook.ts"],"sourcesContent":["import { type ClassValue, clsx } from 'clsx';\nimport { extendTailwindMerge } from 'tailwind-merge';\n\nconst twMergeCustom = extendTailwindMerge({ prefix: 'tw-' });\n\n/**\n * Tailwind and CSS class application helper function. Uses\n * [`clsx`](https://www.npmjs.com/package/clsx) to make it easy to apply classes conditionally using\n * object syntax, and uses [`tailwind-merge`](https://www.npmjs.com/package/tailwind-merge) to make\n * it easy to merge/overwrite Tailwind classes in a programmer-logic-friendly way.\n *\n * Note: `tailwind-merge` is configured to use the prefix `tw-`, so you must use the same prefix\n * with any Tailwind classes you use with this function to successfully overwrite other Tailwind\n * classes. `platform-bible-react` is configured to use `tw-` as its Tailwind prefix, so any\n * Tailwind classes you pass into `platform-bible-react` components will be compared using the `tw-`\n * prefix.\n *\n * This function was popularized by\n * [shadcn/ui](https://ui.shadcn.com/docs/installation/manual#add-a-cn-helper). See [ByteGrad's\n * explanation video](https://www.youtube.com/watch?v=re2JFITR7TI) for more information.\n *\n * @example\n *\n * ```typescript\n * const borderShouldBeBlue = true;\n * const textShouldBeRed = true;\n * const heightShouldBe20 = false;\n * const classString = cn(\n * 'tw-bg-primary tw-h-10 tw-text-primary-foreground',\n * 'tw-bg-secondary',\n * {\n * 'tw-border-blue-500': borderShouldBeBlue,\n * 'tw-text-red-500': textShouldBeRed,\n * 'tw-h-20': heightShouldBe20,\n * },\n * 'some-class',\n * );\n * ```\n *\n * The resulting `classString` is `'tw-h-10 tw-bg-secondary tw-border-blue-500 tw-text-red-500\n * some-class'`\n *\n * - Notice that `'tw-bg-secondary'`, specified later, overwrote `'tw-bg-primary'`, specified earlier,\n * because they are Tailwind classes that affect the same css property\n * - Notice that `'tw-text-red-500'`, specified later, overwrote `'tw-text-primary-foreground'`,\n * specified earlier, because they are Tailwind classes that affect the same css property\n * - Notice that `'tw-h-20'`, specified later, did not overwrite `'tw-h-10'`, specified earlier,\n * because `'tw-h-20'` is part of a conditional class object and its value evaluated to `false`;\n * therefore it was not applied\n * - Notice that `'some-class'` was applied. This function is not limited only to Tailwind classes.\n *\n *\n * @param inputs Class strings or `clsx` conditional class objects to merge. Tailwind classes\n * specified later in the arguments overwrite similar Tailwind classes specified earlier in the\n * arguments\n * @returns Class string containing all applicable classes from the arguments based on the rules\n * described above\n */\n// shadcn/ui uses this export in its boilerplate code\n// eslint-disable-next-line import/prefer-default-export\nexport function cn(...inputs: ClassValue[]) {\n return twMergeCustom(clsx(inputs));\n}\n","import React from 'react';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport interface InputProps extends React.InputHTMLAttributes {}\n\nexport const Input = React.forwardRef(\n ({ className, type, ...props }, ref) => {\n return (\n \n );\n },\n);\nInput.displayName = 'Input';\n","import { FocusEventHandler, forwardRef, KeyboardEvent, MouseEventHandler } from 'react';\nimport { History } from 'lucide-react';\nimport { Input as ShadInput } from '@/components/shadcn-ui/input';\n\nexport type BookChapterInputProps = {\n handleSearch: (searchString: string) => void;\n handleKeyDown: (event: KeyboardEvent) => void;\n handleOnClick: MouseEventHandler;\n handleSubmit: () => void;\n onFocus?: FocusEventHandler;\n value: string;\n placeholder: string;\n};\n\n// Shadcn Input sets type to \"button\"- HAVE to prop spread before setting type\nconst BookChapterInput = forwardRef(\n (\n { handleSearch, handleKeyDown, handleOnClick, handleSubmit, ...props }: BookChapterInputProps,\n ref,\n ) => {\n return (\n
    \n handleSearch(event.target.value)}\n onKeyDown={(e) => {\n if (e.key === 'Enter') {\n handleSubmit();\n }\n handleKeyDown(e);\n }}\n onClick={handleOnClick}\n ref={ref}\n />\n {\n // eslint-disable-next-line no-console\n console.log('back in history');\n }}\n />\n
    \n );\n },\n);\n\nexport default BookChapterInput;\n","var P = Object.defineProperty;\nvar R = (t, e, s) => e in t ? P(t, e, { enumerable: !0, configurable: !0, writable: !0, value: s }) : t[e] = s;\nvar n = (t, e, s) => R(t, typeof e != \"symbol\" ? e + \"\" : e, s);\nclass _ {\n constructor() {\n n(this, \"books\");\n n(this, \"firstSelectedBookNum\");\n n(this, \"lastSelectedBookNum\");\n n(this, \"count\");\n n(this, \"selectedBookNumbers\");\n n(this, \"selectedBookIds\");\n }\n}\nconst N = [\n \"GEN\",\n \"EXO\",\n \"LEV\",\n \"NUM\",\n \"DEU\",\n \"JOS\",\n \"JDG\",\n \"RUT\",\n \"1SA\",\n \"2SA\",\n // 10\n \"1KI\",\n \"2KI\",\n \"1CH\",\n \"2CH\",\n \"EZR\",\n \"NEH\",\n \"EST\",\n \"JOB\",\n \"PSA\",\n \"PRO\",\n // 20\n \"ECC\",\n \"SNG\",\n \"ISA\",\n \"JER\",\n \"LAM\",\n \"EZK\",\n \"DAN\",\n \"HOS\",\n \"JOL\",\n \"AMO\",\n // 30\n \"OBA\",\n \"JON\",\n \"MIC\",\n \"NAM\",\n \"HAB\",\n \"ZEP\",\n \"HAG\",\n \"ZEC\",\n \"MAL\",\n \"MAT\",\n // 40\n \"MRK\",\n \"LUK\",\n \"JHN\",\n \"ACT\",\n \"ROM\",\n \"1CO\",\n \"2CO\",\n \"GAL\",\n \"EPH\",\n \"PHP\",\n // 50\n \"COL\",\n \"1TH\",\n \"2TH\",\n \"1TI\",\n \"2TI\",\n \"TIT\",\n \"PHM\",\n \"HEB\",\n \"JAS\",\n \"1PE\",\n // 60\n \"2PE\",\n \"1JN\",\n \"2JN\",\n \"3JN\",\n \"JUD\",\n \"REV\",\n \"TOB\",\n \"JDT\",\n \"ESG\",\n \"WIS\",\n // 70\n \"SIR\",\n \"BAR\",\n \"LJE\",\n \"S3Y\",\n \"SUS\",\n \"BEL\",\n \"1MA\",\n \"2MA\",\n \"3MA\",\n \"4MA\",\n // 80\n \"1ES\",\n \"2ES\",\n \"MAN\",\n \"PS2\",\n \"ODA\",\n \"PSS\",\n \"JSA\",\n // actual variant text for JOS, now in LXA text\n \"JDB\",\n // actual variant text for JDG, now in LXA text\n \"TBS\",\n // actual variant text for TOB, now in LXA text\n \"SST\",\n // actual variant text for SUS, now in LXA text // 90\n \"DNT\",\n // actual variant text for DAN, now in LXA text\n \"BLT\",\n // actual variant text for BEL, now in LXA text\n \"XXA\",\n \"XXB\",\n \"XXC\",\n \"XXD\",\n \"XXE\",\n \"XXF\",\n \"XXG\",\n \"FRT\",\n // 100\n \"BAK\",\n \"OTH\",\n \"3ES\",\n // Used previously but really should be 2ES\n \"EZA\",\n // Used to be called 4ES, but not actually in any known project\n \"5EZ\",\n // Used to be called 5ES, but not actually in any known project\n \"6EZ\",\n // Used to be called 6ES, but not actually in any known project\n \"INT\",\n \"CNC\",\n \"GLO\",\n \"TDX\",\n // 110\n \"NDX\",\n \"DAG\",\n \"PS3\",\n \"2BA\",\n \"LBA\",\n \"JUB\",\n \"ENO\",\n \"1MQ\",\n \"2MQ\",\n \"3MQ\",\n // 120\n \"REP\",\n \"4BA\",\n \"LAO\"\n], B = [\n \"XXA\",\n \"XXB\",\n \"XXC\",\n \"XXD\",\n \"XXE\",\n \"XXF\",\n \"XXG\",\n \"FRT\",\n \"BAK\",\n \"OTH\",\n \"INT\",\n \"CNC\",\n \"GLO\",\n \"TDX\",\n \"NDX\"\n], O = [\n \"Genesis\",\n \"Exodus\",\n \"Leviticus\",\n \"Numbers\",\n \"Deuteronomy\",\n \"Joshua\",\n \"Judges\",\n \"Ruth\",\n \"1 Samuel\",\n \"2 Samuel\",\n \"1 Kings\",\n \"2 Kings\",\n \"1 Chronicles\",\n \"2 Chronicles\",\n \"Ezra\",\n \"Nehemiah\",\n \"Esther (Hebrew)\",\n \"Job\",\n \"Psalms\",\n \"Proverbs\",\n \"Ecclesiastes\",\n \"Song of Songs\",\n \"Isaiah\",\n \"Jeremiah\",\n \"Lamentations\",\n \"Ezekiel\",\n \"Daniel (Hebrew)\",\n \"Hosea\",\n \"Joel\",\n \"Amos\",\n \"Obadiah\",\n \"Jonah\",\n \"Micah\",\n \"Nahum\",\n \"Habakkuk\",\n \"Zephaniah\",\n \"Haggai\",\n \"Zechariah\",\n \"Malachi\",\n \"Matthew\",\n \"Mark\",\n \"Luke\",\n \"John\",\n \"Acts\",\n \"Romans\",\n \"1 Corinthians\",\n \"2 Corinthians\",\n \"Galatians\",\n \"Ephesians\",\n \"Philippians\",\n \"Colossians\",\n \"1 Thessalonians\",\n \"2 Thessalonians\",\n \"1 Timothy\",\n \"2 Timothy\",\n \"Titus\",\n \"Philemon\",\n \"Hebrews\",\n \"James\",\n \"1 Peter\",\n \"2 Peter\",\n \"1 John\",\n \"2 John\",\n \"3 John\",\n \"Jude\",\n \"Revelation\",\n \"Tobit\",\n \"Judith\",\n \"Esther Greek\",\n \"Wisdom of Solomon\",\n \"Sirach (Ecclesiasticus)\",\n \"Baruch\",\n \"Letter of Jeremiah\",\n \"Song of 3 Young Men\",\n \"Susanna\",\n \"Bel and the Dragon\",\n \"1 Maccabees\",\n \"2 Maccabees\",\n \"3 Maccabees\",\n \"4 Maccabees\",\n \"1 Esdras (Greek)\",\n \"2 Esdras (Latin)\",\n \"Prayer of Manasseh\",\n \"Psalm 151\",\n \"Odes\",\n \"Psalms of Solomon\",\n // WARNING, if you change the spelling of the *obsolete* tag be sure to update\n // IsObsolete routine\n \"Joshua A. *obsolete*\",\n \"Judges B. *obsolete*\",\n \"Tobit S. *obsolete*\",\n \"Susanna Th. *obsolete*\",\n \"Daniel Th. *obsolete*\",\n \"Bel Th. *obsolete*\",\n \"Extra A\",\n \"Extra B\",\n \"Extra C\",\n \"Extra D\",\n \"Extra E\",\n \"Extra F\",\n \"Extra G\",\n \"Front Matter\",\n \"Back Matter\",\n \"Other Matter\",\n \"3 Ezra *obsolete*\",\n \"Apocalypse of Ezra\",\n \"5 Ezra (Latin Prologue)\",\n \"6 Ezra (Latin Epilogue)\",\n \"Introduction\",\n \"Concordance \",\n \"Glossary \",\n \"Topical Index\",\n \"Names Index\",\n \"Daniel Greek\",\n \"Psalms 152-155\",\n \"2 Baruch (Apocalypse)\",\n \"Letter of Baruch\",\n \"Jubilees\",\n \"Enoch\",\n \"1 Meqabyan\",\n \"2 Meqabyan\",\n \"3 Meqabyan\",\n \"Reproof (Proverbs 25-31)\",\n \"4 Baruch (Rest of Baruch)\",\n \"Laodiceans\"\n], S = K();\nfunction g(t, e = !0) {\n return e && (t = t.toUpperCase()), t in S ? S[t] : 0;\n}\nfunction k(t) {\n return g(t) > 0;\n}\nfunction x(t) {\n const e = typeof t == \"string\" ? g(t) : t;\n return e >= 40 && e <= 66;\n}\nfunction T(t) {\n return (typeof t == \"string\" ? g(t) : t) <= 39;\n}\nfunction X(t) {\n return t <= 66;\n}\nfunction V(t) {\n const e = typeof t == \"string\" ? g(t) : t;\n return w(e) && !X(e);\n}\nfunction* L() {\n for (let t = 1; t <= N.length; t++) yield t;\n}\nconst G = 1, A = N.length;\nfunction H() {\n return [\"XXA\", \"XXB\", \"XXC\", \"XXD\", \"XXE\", \"XXF\", \"XXG\"];\n}\nfunction C(t, e = \"***\") {\n const s = t - 1;\n return s < 0 || s >= N.length ? e : N[s];\n}\nfunction I(t) {\n return t <= 0 || t > A ? \"******\" : O[t - 1];\n}\nfunction y(t) {\n return I(g(t));\n}\nfunction w(t) {\n const e = typeof t == \"number\" ? C(t) : t;\n return k(e) && !B.includes(e);\n}\nfunction q(t) {\n const e = typeof t == \"number\" ? C(t) : t;\n return k(e) && B.includes(e);\n}\nfunction U(t) {\n return O[t - 1].includes(\"*obsolete*\");\n}\nfunction K() {\n const t = {};\n for (let e = 0; e < N.length; e++)\n t[N[e]] = e + 1;\n return t;\n}\nconst m = {\n allBookIds: N,\n nonCanonicalIds: B,\n bookIdToNumber: g,\n isBookIdValid: k,\n isBookNT: x,\n isBookOT: T,\n isBookOTNT: X,\n isBookDC: V,\n allBookNumbers: L,\n firstBook: G,\n lastBook: A,\n extraBooks: H,\n bookNumberToId: C,\n bookNumberToEnglishName: I,\n bookIdToEnglishName: y,\n isCanonical: w,\n isExtraMaterial: q,\n isObsolete: U\n};\nvar l = /* @__PURE__ */ ((t) => (t[t.Unknown = 0] = \"Unknown\", t[t.Original = 1] = \"Original\", t[t.Septuagint = 2] = \"Septuagint\", t[t.Vulgate = 3] = \"Vulgate\", t[t.English = 4] = \"English\", t[t.RussianProtestant = 5] = \"RussianProtestant\", t[t.RussianOrthodox = 6] = \"RussianOrthodox\", t))(l || {});\nconst h = class h {\n // private versInfo: Versification;\n constructor(e) {\n n(this, \"name\");\n n(this, \"fullPath\");\n n(this, \"isPresent\");\n n(this, \"hasVerseSegments\");\n n(this, \"isCustomized\");\n n(this, \"baseVersification\");\n n(this, \"scriptureBooks\");\n n(this, \"_type\");\n if (e == null)\n throw new Error(\"Argument undefined\");\n typeof e == \"string\" ? (this.name = e, this._type = l[e]) : (this._type = e, this.name = l[e]);\n }\n get type() {\n return this._type;\n }\n equals(e) {\n return !e.type || !this.type ? !1 : e.type === this.type;\n }\n};\nn(h, \"Original\", new h(l.Original)), n(h, \"Septuagint\", new h(l.Septuagint)), n(h, \"Vulgate\", new h(l.Vulgate)), n(h, \"English\", new h(l.English)), n(h, \"RussianProtestant\", new h(l.RussianProtestant)), n(h, \"RussianOrthodox\", new h(l.RussianOrthodox));\nlet c = h;\nfunction E(t, e) {\n const s = e[0];\n for (let r = 1; r < e.length; r++)\n t = t.split(e[r]).join(s);\n return t.split(s);\n}\nvar D = /* @__PURE__ */ ((t) => (t[t.Valid = 0] = \"Valid\", t[t.UnknownVersification = 1] = \"UnknownVersification\", t[t.OutOfRange = 2] = \"OutOfRange\", t[t.VerseOutOfOrder = 3] = \"VerseOutOfOrder\", t[t.VerseRepeated = 4] = \"VerseRepeated\", t))(D || {});\nconst i = class i {\n constructor(e, s, r, a) {\n /** Not yet implemented. */\n n(this, \"firstChapter\");\n /** Not yet implemented. */\n n(this, \"lastChapter\");\n /** Not yet implemented. */\n n(this, \"lastVerse\");\n /** Not yet implemented. */\n n(this, \"hasSegmentsDefined\");\n /** Not yet implemented. */\n n(this, \"text\");\n /** Not yet implemented. */\n n(this, \"BBBCCCVVVS\");\n /** Not yet implemented. */\n n(this, \"longHashCode\");\n /** The versification of the reference. */\n n(this, \"versification\");\n n(this, \"rtlMark\", \"‏\");\n n(this, \"_bookNum\", 0);\n n(this, \"_chapterNum\", 0);\n n(this, \"_verseNum\", 0);\n n(this, \"_verse\");\n if (r == null && a == null)\n if (e != null && typeof e == \"string\") {\n const o = e, u = s != null && s instanceof c ? s : void 0;\n this.setEmpty(u), this.parse(o);\n } else if (e != null && typeof e == \"number\") {\n const o = s != null && s instanceof c ? s : void 0;\n this.setEmpty(o), this._verseNum = e % i.chapterDigitShifter, this._chapterNum = Math.floor(\n e % i.bookDigitShifter / i.chapterDigitShifter\n ), this._bookNum = Math.floor(e / i.bookDigitShifter);\n } else if (s == null)\n if (e != null && e instanceof i) {\n const o = e;\n this._bookNum = o.bookNum, this._chapterNum = o.chapterNum, this._verseNum = o.verseNum, this._verse = o.verse, this.versification = o.versification;\n } else {\n if (e == null) return;\n const o = e instanceof c ? e : i.defaultVersification;\n this.setEmpty(o);\n }\n else\n throw new Error(\"VerseRef constructor not supported.\");\n else if (e != null && s != null && r != null)\n if (typeof e == \"string\" && typeof s == \"string\" && typeof r == \"string\")\n this.setEmpty(a), this.updateInternal(e, s, r);\n else if (typeof e == \"number\" && typeof s == \"number\" && typeof r == \"number\")\n this._bookNum = e, this._chapterNum = s, this._verseNum = r, this.versification = a ?? i.defaultVersification;\n else\n throw new Error(\"VerseRef constructor not supported.\");\n else\n throw new Error(\"VerseRef constructor not supported.\");\n }\n /**\n * Determines if the verse string is in a valid format (does not consider versification).\n */\n static isVerseParseable(e) {\n return e.length > 0 && \"0123456789\".includes(e[0]) && !e.endsWith(this.verseRangeSeparator) && !e.endsWith(this.verseSequenceIndicator);\n }\n /**\n * Tries to parse the specified string into a verse reference.\n * @param str - The string to attempt to parse.\n * @returns success: `true` if the specified string was successfully parsed, `false` otherwise.\n * @returns verseRef: The result of the parse if successful, or empty VerseRef if it failed\n */\n static tryParse(e) {\n let s;\n try {\n return s = new i(e), { success: !0, verseRef: s };\n } catch (r) {\n if (r instanceof v)\n return s = new i(), { success: !1, verseRef: s };\n throw r;\n }\n }\n /**\n * Gets the reference as a comparable integer where the book, chapter, and verse each occupy 3\n * digits.\n * @param bookNum - Book number (this is 1-based, not an index).\n * @param chapterNum - Chapter number.\n * @param verseNum - Verse number.\n * @returns The reference as a comparable integer where the book, chapter, and verse each occupy 3\n * digits.\n */\n static getBBBCCCVVV(e, s, r) {\n return e % i.bcvMaxValue * i.bookDigitShifter + (s >= 0 ? s % i.bcvMaxValue * i.chapterDigitShifter : 0) + (r >= 0 ? r % i.bcvMaxValue : 0);\n }\n /**\n * Deserializes a serialized VerseRef.\n * @param serializedVerseRef - Serialized VerseRef to create from.\n * @returns the deserialized VerseRef.\n */\n static fromJSON(e) {\n const { book: s, chapterNum: r, verseNum: a, verse: o, versificationStr: u } = e, f = o || a.toString();\n let d;\n return u && (d = new c(u)), s ? new i(s, r.toString(), f, d) : new i();\n }\n /**\n * Parses a verse string and gets the leading numeric portion as a number.\n * @param verseStr - verse string to parse\n * @returns true if the entire string could be parsed as a single, simple verse number (1-999);\n * false if the verse string represented a verse bridge, contained segment letters, or was invalid\n */\n static tryGetVerseNum(e) {\n let s;\n if (!e)\n return s = -1, { success: !0, vNum: s };\n s = 0;\n let r;\n for (let a = 0; a < e.length; a++) {\n if (r = e[a], r < \"0\" || r > \"9\")\n return a === 0 && (s = -1), { success: !1, vNum: s };\n if (s = s * 10 + +r - 0, s > i.bcvMaxValue)\n return s = -1, { success: !1, vNum: s };\n }\n return { success: !0, vNum: s };\n }\n /**\n * Checks to see if a VerseRef hasn't been set - all values are the default.\n */\n get isDefault() {\n return this.bookNum === 0 && this.chapterNum === 0 && this.verseNum === 0 && this.versification == null;\n }\n /**\n * Gets whether the verse contains multiple verses.\n */\n get hasMultiple() {\n return this._verse != null && (this._verse.includes(i.verseRangeSeparator) || this._verse.includes(i.verseSequenceIndicator));\n }\n /**\n * Gets or sets the book of the reference. Book is the 3-letter abbreviation in capital letters,\n * e.g. `'MAT'`.\n */\n get book() {\n return m.bookNumberToId(this.bookNum, \"\");\n }\n set book(e) {\n this.bookNum = m.bookIdToNumber(e);\n }\n /**\n * Gets or sets the chapter of the reference,. e.g. `'3'`.\n */\n get chapter() {\n return this.isDefault || this._chapterNum < 0 ? \"\" : this._chapterNum.toString();\n }\n set chapter(e) {\n const s = +e;\n this._chapterNum = Number.isInteger(s) ? s : -1;\n }\n /**\n * Gets or sets the verse of the reference, including range, segments, and sequences, e.g. `'4'`,\n * or `'4b-5a, 7'`.\n */\n get verse() {\n return this._verse != null ? this._verse : this.isDefault || this._verseNum < 0 ? \"\" : this._verseNum.toString();\n }\n set verse(e) {\n const { success: s, vNum: r } = i.tryGetVerseNum(e);\n this._verse = s ? void 0 : e.replace(this.rtlMark, \"\"), this._verseNum = r, !(this._verseNum >= 0) && ({ vNum: this._verseNum } = i.tryGetVerseNum(this._verse));\n }\n /**\n * Get or set Book based on book number, e.g. `42`.\n */\n get bookNum() {\n return this._bookNum;\n }\n set bookNum(e) {\n if (e <= 0 || e > m.lastBook)\n throw new v(\n \"BookNum must be greater than zero and less than or equal to last book\"\n );\n this._bookNum = e;\n }\n /**\n * Gets or sets the chapter number, e.g. `3`. `-1` if not valid.\n */\n get chapterNum() {\n return this._chapterNum;\n }\n set chapterNum(e) {\n this.chapterNum = e;\n }\n /**\n * Gets or sets verse start number, e.g. `4`. `-1` if not valid.\n */\n get verseNum() {\n return this._verseNum;\n }\n set verseNum(e) {\n this._verseNum = e;\n }\n /**\n * String representing the versification (should ONLY be used for serialization/deserialization).\n *\n * @remarks This is for backwards compatibility when ScrVers was an enumeration.\n */\n get versificationStr() {\n var e;\n return (e = this.versification) == null ? void 0 : e.name;\n }\n set versificationStr(e) {\n this.versification = this.versification != null ? new c(e) : void 0;\n }\n /**\n * Determines if the reference is valid.\n */\n get valid() {\n return this.validStatus === 0;\n }\n /**\n * Get the valid status for this reference.\n */\n get validStatus() {\n return this.validateVerse(i.verseRangeSeparators, i.verseSequenceIndicators);\n }\n /**\n * Gets the reference as a comparable integer where the book,\n * chapter, and verse each occupy three digits and the verse is 0.\n */\n get BBBCCC() {\n return i.getBBBCCCVVV(this._bookNum, this._chapterNum, 0);\n }\n /**\n * Gets the reference as a comparable integer where the book,\n * chapter, and verse each occupy three digits. If verse is not null\n * (i.e., this reference represents a complex reference with verse\n * segments or bridge) this cannot be used for an exact comparison.\n */\n get BBBCCCVVV() {\n return i.getBBBCCCVVV(this._bookNum, this._chapterNum, this._verseNum);\n }\n /**\n * Gets whether the verse is defined as an excluded verse in the versification.\n * Does not handle verse ranges.\n */\n // eslint-disable-next-line @typescript-eslint/class-literal-property-style\n get isExcluded() {\n return !1;\n }\n /**\n * Parses the reference in the specified string.\n * Optionally versification can follow reference as in GEN 3:11/4\n * Throw an exception if\n * - invalid book name\n * - chapter number is missing or not a number\n * - verse number is missing or does not start with a number\n * - versification is invalid\n * @param verseStr - string to parse e.g. 'MAT 3:11'\n */\n parse(e) {\n if (e = e.replace(this.rtlMark, \"\"), e.includes(\"/\")) {\n const o = e.split(\"/\");\n if (e = o[0], o.length > 1)\n try {\n const u = +o[1].trim();\n this.versification = new c(l[u]);\n } catch {\n throw new v(\"Invalid reference : \" + e);\n }\n }\n const s = e.trim().split(\" \");\n if (s.length !== 2)\n throw new v(\"Invalid reference : \" + e);\n const r = s[1].split(\":\"), a = +r[0];\n if (r.length !== 2 || m.bookIdToNumber(s[0]) === 0 || !Number.isInteger(a) || a < 0 || !i.isVerseParseable(r[1]))\n throw new v(\"Invalid reference : \" + e);\n this.updateInternal(s[0], r[0], r[1]);\n }\n /**\n * Simplifies this verse ref so that it has no bridging of verses or\n * verse segments like `'1a'`.\n */\n simplify() {\n this._verse = void 0;\n }\n /**\n * Makes a clone of the reference.\n *\n * @returns The cloned VerseRef.\n */\n clone() {\n return new i(this);\n }\n toString() {\n const e = this.book;\n return e === \"\" ? \"\" : `${e} ${this.chapter}:${this.verse}`;\n }\n toJSON() {\n let e = this.verse;\n (e === \"\" || e === this.verseNum.toString()) && (e = void 0);\n const s = {\n book: this.book,\n chapterNum: this.chapterNum,\n verseNum: this.verseNum,\n verse: e,\n versificationStr: this.versificationStr\n };\n return e || delete s.verse, s;\n }\n /**\n * Compares this `VerseRef` with supplied one.\n * @param verseRef - object to compare this one to.\n * @returns `true` if this `VerseRef` is equal to the supplied one, `false` otherwise.\n */\n equals(e) {\n return e instanceof i ? e._bookNum === this._bookNum && e._chapterNum === this._chapterNum && e._verseNum === this._verseNum && e.verse === this.verse && (e.versification == null && this.versification == null || e.versification != null && this.versification != null && e.versification.equals(this.versification)) : !1;\n }\n /**\n * Enumerate all individual verses contained in a VerseRef.\n * Verse ranges are indicated by \"-\" and consecutive verses by \",\"s.\n * Examples:\n * GEN 1:2 returns GEN 1:2\n * GEN 1:1a-3b,5 returns GEN 1:1a, GEN 1:2, GEN 1:3b, GEN 1:5\n * GEN 1:2a-2c returns //! ??????\n *\n * @param specifiedVersesOnly - if set to true return only verses that are\n * explicitly specified only, not verses within a range. Defaults to `false`.\n * @param verseRangeSeparators - Verse range separators.\n * Defaults to `VerseRef.verseRangeSeparators`.\n * @param verseSequenceSeparators - Verse sequence separators.\n * Defaults to `VerseRef.verseSequenceIndicators`.\n * @returns An array of all single verse references in this VerseRef.\n */\n allVerses(e = !1, s = i.verseRangeSeparators, r = i.verseSequenceIndicators) {\n if (this._verse == null || this.chapterNum <= 0)\n return [this.clone()];\n const a = [], o = E(this._verse, r);\n for (const u of o.map((f) => E(f, s))) {\n const f = this.clone();\n f.verse = u[0];\n const d = f.verseNum;\n if (a.push(f), u.length > 1) {\n const b = this.clone();\n if (b.verse = u[1], !e)\n for (let p = d + 1; p < b.verseNum; p++) {\n const J = new i(\n this._bookNum,\n this._chapterNum,\n p,\n this.versification\n );\n this.isExcluded || a.push(J);\n }\n a.push(b);\n }\n }\n return a;\n }\n /**\n * Validates a verse number using the supplied separators rather than the defaults.\n */\n validateVerse(e, s) {\n if (!this.verse)\n return this.internalValid;\n let r = 0;\n for (const a of this.allVerses(!0, e, s)) {\n const o = a.internalValid;\n if (o !== 0)\n return o;\n const u = a.BBBCCCVVV;\n if (r > u)\n return 3;\n if (r === u)\n return 4;\n r = u;\n }\n return 0;\n }\n /**\n * Gets whether a single verse reference is valid.\n */\n get internalValid() {\n return this.versification == null ? 1 : this._bookNum <= 0 || this._bookNum > m.lastBook ? 2 : (m.isCanonical(this._bookNum), 0);\n }\n setEmpty(e = i.defaultVersification) {\n this._bookNum = 0, this._chapterNum = -1, this._verse = void 0, this.versification = e;\n }\n updateInternal(e, s, r) {\n this.bookNum = m.bookIdToNumber(e), this.chapter = s, this.verse = r;\n }\n};\nn(i, \"defaultVersification\", c.English), n(i, \"verseRangeSeparator\", \"-\"), n(i, \"verseSequenceIndicator\", \",\"), n(i, \"verseRangeSeparators\", [i.verseRangeSeparator]), n(i, \"verseSequenceIndicators\", [i.verseSequenceIndicator]), n(i, \"chapterDigitShifter\", 1e3), n(i, \"bookDigitShifter\", i.chapterDigitShifter * i.chapterDigitShifter), n(i, \"bcvMaxValue\", i.chapterDigitShifter - 1), /**\n * The valid status of the VerseRef.\n */\nn(i, \"ValidStatusType\", D);\nlet M = i;\nclass v extends Error {\n}\nexport {\n _ as BookSet,\n m as Canon,\n c as ScrVers,\n l as ScrVersType,\n M as VerseRef,\n v as VerseRefException\n};\n//# sourceMappingURL=index.es.js.map\n","import React from 'react';\nimport * as DropdownMenuPrimitive from '@radix-ui/react-dropdown-menu';\nimport { Check, ChevronRight, Circle } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport const DropdownMenu = DropdownMenuPrimitive.Root;\n\nexport const DropdownMenuTrigger = DropdownMenuPrimitive.Trigger;\n\nexport const DropdownMenuGroup = DropdownMenuPrimitive.Group;\n\nexport const DropdownMenuPortal = DropdownMenuPrimitive.Portal;\n\nexport const DropdownMenuSub = DropdownMenuPrimitive.Sub;\n\nexport const DropdownMenuRadioGroup = DropdownMenuPrimitive.RadioGroup;\n\nexport type DropdownMenuSubTriggerProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.SubTrigger\n> & {\n className?: string;\n inset?: boolean;\n};\n\nexport type DropdownMenuSubContentProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.SubContent\n> & {\n className?: string;\n};\n\nexport type DropdownMenuContentProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Content\n> & {\n className?: string;\n sideOffset?: number;\n};\n\nexport type DropdownMenuItemProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Item\n> & {\n className?: string;\n inset?: boolean;\n};\n\nexport type DropdownMenuCheckboxItemProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.CheckboxItem\n> & {\n className?: string;\n checked?: boolean;\n};\n\nexport type DropdownMenuRadioItemProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.RadioItem\n> & {\n className?: string;\n};\n\nexport type DropdownMenuLabelProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Label\n> & {\n className?: string;\n inset?: boolean;\n};\n\nexport type DropdownMenuSeparatorProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Separator\n> & {\n className?: string;\n};\n\nexport type DropdownMenuShortcutProps = React.HTMLAttributes & {\n className?: string;\n};\n\nexport const DropdownMenuSubTrigger = React.forwardRef<\n React.ElementRef,\n DropdownMenuSubTriggerProps\n>(({ className, inset, children, ...props }, ref) => (\n \n {children}\n \n \n));\nDropdownMenuSubTrigger.displayName = DropdownMenuPrimitive.SubTrigger.displayName;\n\nexport const DropdownMenuSubContent = React.forwardRef<\n React.ElementRef,\n DropdownMenuSubContentProps\n>(({ className, ...props }, ref) => (\n \n));\nDropdownMenuSubContent.displayName = DropdownMenuPrimitive.SubContent.displayName;\n\nexport const DropdownMenuContent = React.forwardRef<\n React.ElementRef,\n DropdownMenuContentProps\n>(({ className, sideOffset = 4, ...props }, ref) => (\n \n \n \n));\nDropdownMenuContent.displayName = DropdownMenuPrimitive.Content.displayName;\n\n/**\n * TODO: fix: direction is not automatically handled by this component, so that shortcuts are\n * display always to the right\n */\nexport const DropdownMenuItem = React.forwardRef<\n React.ElementRef,\n DropdownMenuItemProps\n>(({ className, inset, ...props }, ref) => (\n \n));\nDropdownMenuItem.displayName = DropdownMenuPrimitive.Item.displayName;\n\nexport const DropdownMenuCheckboxItem = React.forwardRef<\n React.ElementRef,\n DropdownMenuCheckboxItemProps\n>(({ className, children, checked, ...props }, ref) => (\n \n \n \n \n \n \n {children}\n \n));\nDropdownMenuCheckboxItem.displayName = DropdownMenuPrimitive.CheckboxItem.displayName;\n\nexport const DropdownMenuRadioItem = React.forwardRef<\n React.ElementRef,\n DropdownMenuRadioItemProps\n>(({ className, children, ...props }, ref) => (\n \n \n \n \n \n \n {children}\n \n));\nDropdownMenuRadioItem.displayName = DropdownMenuPrimitive.RadioItem.displayName;\n\nexport const DropdownMenuLabel = React.forwardRef<\n React.ElementRef,\n DropdownMenuLabelProps\n>(({ className, inset, ...props }, ref) => (\n \n));\nDropdownMenuLabel.displayName = DropdownMenuPrimitive.Label.displayName;\n\nexport const DropdownMenuSeparator = React.forwardRef<\n React.ElementRef,\n DropdownMenuSeparatorProps\n>(({ className, ...props }, ref) => (\n \n));\nDropdownMenuSeparator.displayName = DropdownMenuPrimitive.Separator.displayName;\n\nexport function DropdownMenuShortcut({ className, ...props }: DropdownMenuShortcutProps) {\n return (\n \n );\n}\nDropdownMenuShortcut.displayName = 'DropdownMenuShortcut';\n","import { Canon } from '@sillsdev/scripture';\nimport { PropsWithChildren, KeyboardEvent, forwardRef } from 'react';\nimport { DropdownMenuItem as ShadDropdownMenuItem } from '@/components/shadcn-ui/dropdown-menu';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport type BookType = 'OT' | 'NT' | 'DC';\n\ntype BookMenuItemProps = PropsWithChildren<{\n /** String id of book */\n bookId: string;\n /** Callback to run when a book menu item is selected */\n handleSelectBook: () => void;\n /** Indicates if this menu item is currently selected */\n isSelected: boolean;\n /** Function that is called upon highlighting a book in the dropdown menu */\n handleHighlightBook: () => void;\n /**\n * Function that is called on pressing a key\n *\n * @param event Event that contains information about the key stroke\n */\n handleKeyDown: (event: KeyboardEvent) => void;\n /**\n * Type of book associated with this menu item, coordinates color labels ? Mock up has the labels\n * coordinated to genre\n */\n bookType: BookType;\n}>;\n\nconst BookMenuItem = forwardRef(\n (\n {\n bookId,\n handleSelectBook,\n isSelected,\n handleHighlightBook,\n handleKeyDown,\n bookType,\n children,\n }: BookMenuItemProps,\n ref,\n ) => {\n return (\n {\n // preventDefault() here prevents the entire dropdown menu from closing when selecting this item\n event.preventDefault();\n handleSelectBook();\n }}\n onKeyDown={(event: KeyboardEvent) => {\n handleKeyDown(event);\n }}\n onFocus={handleHighlightBook}\n onMouseMove={handleHighlightBook}\n >\n \n {Canon.bookIdToEnglishName(bookId)}\n \n {isSelected &&
    {children}
    }\n \n );\n },\n);\n\nexport default BookMenuItem;\n","import { cn } from '@/utils/shadcn-ui.util';\nimport { useCallback } from 'react';\n\nexport type ChapterSelectProps = {\n /**\n * Callback to run when a chapter div is selected\n *\n * @param chapterNumber Number of the chapter that has been selected\n */\n handleSelectChapter: (chapterNumber: number) => void;\n /** The highest chapter number in the book (of course equal to number of chapters in the book) */\n endChapter: number;\n /** The chapter number that is currently selected */\n activeChapter: number;\n /** The chapter number that is currently highlighted using keyboard or mouse navigation */\n highlightedChapter: number;\n /**\n * Callback to run when a chapter is highlighted by the user\n *\n * @param chapterNumber The chapter that is highlighted\n */\n handleHighlightedChapter: (chapterNumber: number) => void;\n};\n\nfunction ChapterSelect({\n handleSelectChapter,\n endChapter,\n activeChapter,\n highlightedChapter,\n handleHighlightedChapter,\n}: ChapterSelectProps) {\n const chapters = Array.from({ length: endChapter }, (_, i) => i + 1);\n\n const handleMouse = useCallback(\n (chapterNumber: number) => {\n handleHighlightedChapter(chapterNumber);\n },\n [handleHighlightedChapter],\n );\n\n return (\n
    \n {chapters.map((chapter) => (\n {\n event.preventDefault();\n event.stopPropagation();\n handleSelectChapter(chapter);\n }}\n role=\"button\"\n onKeyDown={(event) => {\n if (event.key === 'Enter') {\n handleSelectChapter(chapter);\n }\n }}\n tabIndex={0}\n onMouseMove={() => handleMouse(chapter)}\n >\n {chapter}\n
    \n ))}\n
    \n );\n}\n\nexport default ChapterSelect;\n","import { DropdownMenuLabel as ShadDropdownMenuLabel } from '@/components/shadcn-ui/dropdown-menu';\nimport { Bookmark, Clock, ArrowDownWideNarrow } from 'lucide-react';\n\nexport type GoToMenuItemProps = {\n handleSort: () => void;\n handleLocationHistory: () => void;\n handleBookmarks: () => void;\n};\n\nfunction GoToMenuItem({ handleSort, handleLocationHistory, handleBookmarks }: GoToMenuItemProps) {\n return (\n \n

    Go To

    \n
    \n \n \n \n
    \n
    \n );\n}\n\nexport default GoToMenuItem;\n","import BookChapterInput from '@/components/advanced/book-chapter-control/book-chapter-input.component';\nimport BookMenuItem, {\n BookType,\n} from '@/components/advanced/book-chapter-control/book-menu-item.component';\nimport ChapterSelect from '@/components/advanced/book-chapter-control/chapter-select.component';\nimport GoToMenuItem from '@/components/advanced/book-chapter-control/go-to-menu-item.component';\nimport {\n DropdownMenu as ShadDropdownMenu,\n DropdownMenuContent as ShadDropdownMenuContent,\n DropdownMenuLabel as ShadDropdownMenuLabel,\n DropdownMenuSeparator as ShadDropdownMenuSeparator,\n DropdownMenuTrigger as ShadDropdownMenuTrigger,\n} from '@/components/shadcn-ui/dropdown-menu';\nimport { Canon } from '@sillsdev/scripture';\nimport { ScriptureReference, getChaptersForBook } from 'platform-bible-utils';\nimport {\n KeyboardEvent as ReactKeyboardEvent,\n useCallback,\n useEffect,\n useLayoutEffect,\n useRef,\n useState,\n} from 'react';\n\ntype BookTypeLabels = {\n [bookType in BookType]: string;\n};\ntype BookChapterControlProps = {\n scrRef: ScriptureReference;\n handleSubmit: (scrRef: ScriptureReference) => void;\n};\n\nconst ALL_BOOK_IDS = Canon.allBookIds;\nconst BOOK_TYPE_LABELS: BookTypeLabels = {\n OT: 'Old Testament',\n NT: 'New Testament',\n DC: 'Deuterocanon',\n};\nconst BOOK_TYPE_ARRAY: BookType[] = ['OT', 'NT', 'DC'];\n// This is the height of three menu items to offset scrolling to the selected menu item\n// If you use menuItemRef.clientHeight- includes height of chapter div which is too big\nconst SCROLL_OFFSET = 32 + 32 + 32;\nconst SEARCH_QUERY_FORMATS = [\n /^(\\w+)$/i, // Matches a single word (book name or id)\n /^(\\w+)(?:\\s(\\d+))$/i, // Matches a word followed by a chapter number\n /^(\\w+)(?:\\s(\\d+):(\\d+))$/i, // Matches a word followed by a chapter and verse number\n];\nconst fetchGroupedBooks = (bookType: BookType) => {\n const groupedBooks = {\n OT: ALL_BOOK_IDS.filter((bookId) => Canon.isBookOT(bookId)),\n NT: ALL_BOOK_IDS.filter((bookId) => Canon.isBookNT(bookId)),\n DC: ALL_BOOK_IDS.filter((bookId) => Canon.isBookDC(bookId)),\n };\n return groupedBooks[bookType];\n};\nconst fetchEndChapter = (bookId: string) => {\n // getChaptersForBook returns -1 if not found in scrBookData\n // scrBookData only includes OT and NT, so all DC will return -1\n return getChaptersForBook(Canon.bookIdToNumber(bookId));\n};\n\n/**\n * Gets all of the English names from book ids\n *\n * @returns String[]\n */\nfunction getAllEnglishNames(): string[] {\n const allEnglishNames = ALL_BOOK_IDS.map((bookId) => {\n return Canon.bookIdToEnglishName(bookId);\n });\n return allEnglishNames;\n}\n\n/**\n * Determines if bookName is in allEnglishNames\n *\n * @param bookName Book English name\n * @returns True if bookName is included, false otherwise\n */\nfunction isValidBookEnglishName(bookName: string): boolean {\n return getAllEnglishNames().includes(bookName);\n}\n\n/**\n * Gets a bookId from given English name\n *\n * @param bookName Book English name\n * @returns BookId of provided bookName, undefined otherwise\n */\nfunction getBookIdFromEnglishName(bookName: string): string | undefined {\n // Convert bookName to lowercase and then capitalize the first letter\n const formattedBookName = bookName.toLowerCase().replace(/^\\w/, (c) => c.toUpperCase());\n\n if (isValidBookEnglishName(formattedBookName)) {\n const matchingBookId = ALL_BOOK_IDS.find((bookId) => {\n return Canon.bookIdToEnglishName(bookId) === formattedBookName;\n });\n return matchingBookId;\n }\n\n return undefined;\n}\n\nfunction BookChapterControl({ scrRef, handleSubmit }: BookChapterControlProps) {\n const [searchQuery, setSearchQuery] = useState('');\n const [selectedBookId, setSelectedBookId] = useState(\n Canon.bookNumberToId(scrRef.bookNum),\n );\n const [highlightedChapter, setHighlightedChapter] = useState(scrRef.chapterNum ?? 0);\n const [highlightedBookId, setHighlightedBookId] = useState(\n Canon.bookNumberToId(scrRef.bookNum),\n );\n const [isContentOpen, setIsContentOpen] = useState(false);\n const [isContentOpenDelayed, setIsContentOpenDelayed] = useState(isContentOpen);\n\n // This ref will always be defined\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const inputRef = useRef(undefined!);\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const contentRef = useRef(undefined!);\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const menuItemRef = useRef(undefined!);\n\n const fetchFilteredBooks = useCallback(\n (bookType: BookType) => {\n return fetchGroupedBooks(bookType).filter((bookId: string) => {\n const englishNameLowerCase = Canon.bookIdToEnglishName(bookId).toLowerCase();\n const normalizedQuery = searchQuery.replace(/[^a-zA-Z]/g, '').toLowerCase();\n return (\n englishNameLowerCase.includes(normalizedQuery) || // Match book name\n bookId.toLowerCase().includes(normalizedQuery) // Match book ID\n );\n });\n },\n [searchQuery],\n );\n\n const handleSearchInput = (searchString: string) => {\n setSearchQuery(searchString);\n };\n\n /**\n * Whether to prevent radix's logic from closing the dropdown. This is important because radix\n * tries to close the dropdown when the input first focuses, and we don't want it to do that. But\n * we don't want to prevent the dropdown from closing when we click away from the input, so we\n * don't want to just keep it open if the input is focused\n */\n const shouldPreventAutoClosing = useRef(false);\n\n const controlMenuState = useCallback((open: boolean) => {\n if (shouldPreventAutoClosing.current) {\n shouldPreventAutoClosing.current = false;\n return;\n }\n setIsContentOpen(open);\n }, []);\n\n const updateReference = useCallback(\n (bookId: string, shouldClose: boolean, chapter?: number, verse?: number) => {\n setHighlightedChapter(\n Canon.bookNumberToId(scrRef.bookNum) !== bookId ? 1 : scrRef.chapterNum,\n );\n\n if (shouldClose || fetchEndChapter(bookId) === -1) {\n handleSubmit({\n bookNum: Canon.bookIdToNumber(bookId),\n chapterNum: chapter || 1,\n verseNum: verse || 1,\n });\n\n setIsContentOpen(false);\n setSearchQuery('');\n return;\n }\n\n setSelectedBookId(selectedBookId !== bookId ? bookId : '');\n setIsContentOpen(!shouldClose);\n },\n [handleSubmit, scrRef.bookNum, scrRef.chapterNum, selectedBookId],\n );\n\n const handleSelectChapter = (chapterNumber: number) => {\n if (chapterNumber <= 0 || chapterNumber > fetchEndChapter(selectedBookId)) {\n return;\n }\n updateReference(selectedBookId, true, chapterNumber);\n };\n\n const handleInputSubmit = useCallback(() => {\n SEARCH_QUERY_FORMATS.forEach((format) => {\n const matches = searchQuery.match(format);\n if (matches) {\n // Book should be a bookId or an english name\n const [book, chapter = undefined, verse = undefined] = matches.slice(1);\n const englishName = getBookIdFromEnglishName(book);\n\n if (Canon.isBookIdValid(book) || englishName) {\n updateReference(\n englishName ?? book,\n true,\n chapter ? parseInt(chapter, 10) : 1,\n verse ? parseInt(verse, 10) : 1,\n );\n }\n }\n });\n }, [updateReference, searchQuery]);\n\n const handleKeyDownInput = useCallback(\n (event: ReactKeyboardEvent) => {\n if (!isContentOpen) {\n setIsContentOpen(true);\n } else if (event.key === 'ArrowDown' || event.key === 'ArrowUp') {\n if (\n typeof menuItemRef !== 'undefined' &&\n // Ref uses null\n // eslint-disable-next-line no-null/no-null\n menuItemRef.current !== null\n ) {\n menuItemRef.current.focus();\n } else if (\n typeof contentRef !== 'undefined' &&\n // Ref uses null\n // eslint-disable-next-line no-null/no-null\n contentRef.current !== null\n ) {\n contentRef.current.focus();\n }\n event.preventDefault();\n }\n },\n [isContentOpen],\n );\n\n const handleKeyDownContent = (event: ReactKeyboardEvent) => {\n // When the dropdown menu has focus, key strokes should give focus to the input component,\n // unless they're navigation keys (arrows and enter)\n const { key } = event;\n if (\n key === 'ArrowRight' ||\n key === 'ArrowLeft' ||\n key === 'ArrowDown' ||\n key === 'ArrowUp' ||\n key === 'Enter'\n ) {\n return;\n }\n\n inputRef.current.dispatchEvent(new KeyboardEvent('keydown', { key }));\n inputRef.current.focus();\n };\n\n const handleKeyDownMenuItem = (event: ReactKeyboardEvent) => {\n const { key } = event;\n if (highlightedBookId === selectedBookId) {\n if (key === 'Enter') {\n event.preventDefault();\n updateReference(selectedBookId, true, highlightedChapter);\n return;\n }\n\n let chapterOffSet = 0;\n if (key === 'ArrowRight') {\n if (highlightedChapter < fetchEndChapter(highlightedBookId)) {\n chapterOffSet = 1;\n } else {\n event.preventDefault();\n return;\n }\n } else if (key === 'ArrowLeft') {\n if (highlightedChapter > 1) {\n chapterOffSet = -1;\n } else {\n event.preventDefault();\n return;\n }\n } else if (key === 'ArrowDown') {\n chapterOffSet = 6;\n } else if (key === 'ArrowUp') {\n chapterOffSet = -6;\n }\n if (\n highlightedChapter + chapterOffSet <= 0 ||\n highlightedChapter + chapterOffSet > fetchEndChapter(highlightedBookId)\n ) {\n setHighlightedChapter(0);\n } else if (chapterOffSet !== 0) {\n setHighlightedChapter(highlightedChapter + chapterOffSet);\n event.preventDefault();\n }\n }\n };\n\n useEffect(() => {\n if (selectedBookId === highlightedBookId) {\n if (selectedBookId === Canon.bookNumberToId(scrRef.bookNum)) {\n setHighlightedChapter(scrRef.chapterNum);\n } else {\n setHighlightedChapter(1);\n }\n } else {\n setHighlightedChapter(0);\n }\n }, [highlightedBookId, scrRef.bookNum, scrRef.chapterNum, selectedBookId]);\n\n // The purpose of these useLayoutEffects and timeout is to delay the scroll just\n // enough so that the refs are defined and available when they are used after the timeout\n useLayoutEffect(() => {\n setIsContentOpenDelayed(isContentOpen);\n }, [isContentOpen]);\n\n useLayoutEffect(() => {\n const scrollTimeout = setTimeout(() => {\n if (isContentOpenDelayed && contentRef.current && menuItemRef.current) {\n const menuItemOffsetTop = menuItemRef.current.offsetTop;\n const scrollPosition = menuItemOffsetTop - SCROLL_OFFSET;\n contentRef.current.scrollTo({ top: scrollPosition, behavior: 'instant' });\n }\n }, 10);\n return () => {\n clearTimeout(scrollTimeout);\n };\n }, [isContentOpenDelayed]);\n\n return (\n
    \n \n \n {\n setSelectedBookId(Canon.bookNumberToId(scrRef.bookNum));\n setHighlightedBookId(Canon.bookNumberToId(scrRef.bookNum));\n setHighlightedChapter(scrRef.chapterNum > 0 ? scrRef.chapterNum : 0);\n setIsContentOpen(true);\n inputRef.current.focus();\n }}\n onFocus={() => {\n // Radix thinks we want to close because the input is being focused. Prevent that\n shouldPreventAutoClosing.current = true;\n }}\n handleSubmit={handleInputSubmit}\n placeholder={`${Canon.bookNumberToEnglishName(scrRef.bookNum)} ${scrRef.chapterNum}:${scrRef.verseNum}`}\n />\n \n \n console.log('sorting')}\n handleLocationHistory={() => console.log('location history')}\n handleBookmarks={() => console.log('bookmarks')}\n />\n {BOOK_TYPE_ARRAY.map(\n (bookType, bookTypeIndex) =>\n fetchFilteredBooks(bookType).length > 0 && (\n
    \n \n {BOOK_TYPE_LABELS[bookType]}\n \n\n {fetchFilteredBooks(bookType).map((bookId) => (\n
    \n updateReference(bookId, false)}\n isSelected={selectedBookId === bookId}\n handleHighlightBook={() => setHighlightedBookId(bookId)}\n handleKeyDown={handleKeyDownMenuItem}\n bookType={bookType}\n ref={(element: HTMLDivElement) => {\n if (selectedBookId === bookId) menuItemRef.current = element;\n }}\n >\n {\n setHighlightedChapter(chapterNumber);\n }}\n />\n \n
    \n ))}\n {BOOK_TYPE_ARRAY.length - 1 !== bookTypeIndex ? (\n \n ) : undefined}\n
    \n ),\n )}\n \n
    \n
    \n );\n}\n\nexport default BookChapterControl;\n","import React from 'react';\nimport { Slot } from '@radix-ui/react-slot';\nimport { cva, type VariantProps } from 'class-variance-authority';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport const buttonVariants = cva(\n 'pr-twp tw-inline-flex tw-items-center tw-justify-center tw-whitespace-nowrap tw-rounded-md tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-colors focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50',\n {\n variants: {\n variant: {\n default: 'tw-bg-primary tw-text-primary-foreground hover:tw-bg-primary/90',\n destructive: 'tw-bg-destructive tw-text-destructive-foreground hover:tw-bg-destructive/90',\n outline:\n 'tw-border tw-border-input tw-bg-background hover:tw-bg-accent hover:tw-text-accent-foreground',\n secondary: 'tw-bg-secondary tw-text-secondary-foreground hover:tw-bg-secondary/80',\n ghost: 'hover:tw-bg-accent hover:tw-text-accent-foreground',\n link: 'tw-text-primary tw-underline-offset-4 hover:tw-underline',\n },\n size: {\n default: 'tw-h-10 tw-px-4 tw-py-2',\n sm: 'tw-h-9 tw-rounded-md tw-px-3',\n lg: 'tw-h-11 tw-rounded-md tw-px-8',\n icon: 'tw-h-10 tw-w-10',\n },\n },\n defaultVariants: {\n variant: 'default',\n size: 'default',\n },\n },\n);\n\nexport interface ButtonProps\n extends React.ButtonHTMLAttributes,\n VariantProps {\n asChild?: boolean;\n}\n\nexport const Button = React.forwardRef(\n ({ className, variant, size, asChild = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'button';\n return (\n \n );\n },\n);\nButton.displayName = 'Button';\n","import React from 'react';\nimport * as LabelPrimitive from '@radix-ui/react-label';\nimport { cva, type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst labelVariants = cva(\n 'tw-text-sm tw-font-medium tw-leading-none peer-disabled:tw-cursor-not-allowed peer-disabled:tw-opacity-70',\n);\n\nexport const Label = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef & VariantProps\n>(({ className, ...props }, ref) => (\n \n));\nLabel.displayName = LabelPrimitive.Root.displayName;\n","import React from 'react';\nimport * as RadioGroupPrimitive from '@radix-ui/react-radio-group';\nimport { Circle } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst RadioGroup = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => {\n return (\n \n );\n});\nRadioGroup.displayName = RadioGroupPrimitive.Root.displayName;\n\nconst RadioGroupItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => {\n return (\n \n \n \n \n \n );\n});\nRadioGroupItem.displayName = RadioGroupPrimitive.Item.displayName;\n\nexport { RadioGroup, RadioGroupItem };\n","import React from 'react';\nimport * as PopoverPrimitive from '@radix-ui/react-popover';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Popover = PopoverPrimitive.Root;\n\nconst PopoverTrigger = PopoverPrimitive.Trigger;\n\nconst PopoverContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, align = 'center', sideOffset = 4, ...props }, ref) => (\n \n \n \n));\nPopoverContent.displayName = PopoverPrimitive.Content.displayName;\n\nexport { Popover, PopoverTrigger, PopoverContent };\n","import React from 'react';\nimport * as DialogPrimitive from '@radix-ui/react-dialog';\nimport { X } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Dialog = DialogPrimitive.Root;\n\nconst DialogTrigger = DialogPrimitive.Trigger;\n\nconst DialogPortal = DialogPrimitive.Portal;\n\nconst DialogClose = DialogPrimitive.Close;\n\nconst DialogOverlay = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nDialogOverlay.displayName = DialogPrimitive.Overlay.displayName;\n\nconst DialogContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, ...props }, ref) => (\n \n \n \n {children}\n \n \n Close\n \n \n \n));\nDialogContent.displayName = DialogPrimitive.Content.displayName;\n\nfunction DialogHeader({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nDialogHeader.displayName = 'DialogHeader';\n\nfunction DialogFooter({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nDialogFooter.displayName = 'DialogFooter';\n\nconst DialogTitle = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nDialogTitle.displayName = DialogPrimitive.Title.displayName;\n\nconst DialogDescription = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nDialogDescription.displayName = DialogPrimitive.Description.displayName;\n\nexport {\n Dialog,\n DialogPortal,\n DialogOverlay,\n DialogClose,\n DialogTrigger,\n DialogContent,\n DialogHeader,\n DialogFooter,\n DialogTitle,\n DialogDescription,\n};\n","import React from 'react';\nimport { type DialogProps } from '@radix-ui/react-dialog';\nimport { Command as CommandPrimitive } from 'cmdk';\nimport { Search } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Dialog, DialogContent } from '@/components/shadcn-ui/dialog';\n\nconst Command = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nCommand.displayName = CommandPrimitive.displayName;\n\ninterface CommandDialogProps extends DialogProps {}\n\nfunction CommandDialog({ children, ...props }: CommandDialogProps) {\n return (\n \n \n \n {children}\n \n \n \n );\n}\n\nconst CommandInput = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n
    \n \n \n
    \n));\n\nCommandInput.displayName = CommandPrimitive.Input.displayName;\n\nconst CommandList = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\n\nCommandList.displayName = CommandPrimitive.List.displayName;\n\nconst CommandEmpty = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>((props, ref) => (\n \n));\n\nCommandEmpty.displayName = CommandPrimitive.Empty.displayName;\n\nconst CommandGroup = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\n\nCommandGroup.displayName = CommandPrimitive.Group.displayName;\n\nconst CommandSeparator = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nCommandSeparator.displayName = CommandPrimitive.Separator.displayName;\n\nconst CommandItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\n\nCommandItem.displayName = CommandPrimitive.Item.displayName;\n\nfunction CommandShortcut({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nCommandShortcut.displayName = 'CommandShortcut';\n\nexport {\n Command,\n CommandDialog,\n CommandInput,\n CommandList,\n CommandEmpty,\n CommandGroup,\n CommandItem,\n CommandShortcut,\n CommandSeparator,\n};\n","import { useState } from 'react';\nimport { Check, ChevronsUpDown } from 'lucide-react';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport { Popover, PopoverContent, PopoverTrigger } from '@/components/shadcn-ui/popover';\nimport {\n Command,\n CommandEmpty,\n CommandInput,\n CommandItem,\n CommandList,\n} from '@/components/shadcn-ui/command';\nimport { PopoverProps } from '@radix-ui/react-popover';\n\nexport type ComboBoxLabelOption = { label: string };\nexport type ComboBoxOption = string | number | ComboBoxLabelOption;\n\nexport type ComboBoxProps = {\n /** Optional unique identifier */\n id?: string;\n /** Text label title for combobox */\n /** List of available options for the dropdown menu */\n options?: readonly T[];\n /** Additional css classes to help with unique styling of the combo box button */\n buttonClassName?: string;\n /** Additional css classes to help with unique styling of the combo box popover */\n popoverContentClassName?: string;\n /**\n * The selected value that the combo box currently holds. Must be shallow equal to one of the\n * options entries.\n */\n value?: T;\n /** Triggers when content of textfield is changed */\n onChange?: (newValue: T) => void;\n /** Used to determine the string value for a given option. */\n getOptionLabel?: (option: ComboBoxOption) => string;\n /** Text displayed on button if `value` is undefined */\n buttonPlaceholder?: string;\n /** Placeholder text for text field */\n textPlaceholder?: string;\n /** Text to display when no options match input */\n commandEmptyMessage?: string;\n /** Variant of button */\n buttonVariant?: ButtonProps['variant'];\n /** Text direction ltr or rtl */\n dir?: Direction;\n /** Optional boolean to set if trigger should be disabled */\n isDisabled?: boolean;\n} & PopoverProps;\n\ntype Direction = 'ltr' | 'rtl';\n\nfunction getOptionLabelDefault(option: ComboBoxOption): string {\n if (typeof option === 'string') {\n return option;\n }\n if (typeof option === 'number') {\n return option.toString();\n }\n return option.label;\n}\n\n/**\n * Autocomplete input and command palette with a list of suggestions.\n *\n * Thanks to Shadcn for heavy inspiration and documentation\n * https://ui.shadcn.com/docs/components/combobox\n */\nfunction ComboBox({\n id,\n options = [],\n buttonClassName,\n popoverContentClassName,\n value,\n onChange = () => {},\n getOptionLabel = getOptionLabelDefault,\n buttonPlaceholder = '',\n textPlaceholder = '',\n commandEmptyMessage = 'No option found',\n buttonVariant = 'outline',\n dir = 'ltr',\n isDisabled = false,\n ...props\n}: ComboBoxProps) {\n const [open, setOpen] = useState(false);\n\n return (\n \n \n \n \n {value ? getOptionLabel(value) : buttonPlaceholder}\n \n \n \n \n \n \n \n {commandEmptyMessage}\n \n {options.map((option) => (\n {\n onChange(option);\n setOpen(false);\n }}\n >\n \n {getOptionLabel(option)}\n \n ))}\n \n \n \n \n );\n}\n\nexport default ComboBox;\n","import { useMemo } from 'react';\nimport ComboBox from '@/components/basics/combo-box.component';\nimport { Label } from '@/components/shadcn-ui/label';\n\nexport type ChapterRangeSelectorProps = {\n startChapter: number;\n endChapter: number;\n handleSelectStartChapter: (chapter: number) => void;\n handleSelectEndChapter: (chapter: number) => void;\n isDisabled?: boolean;\n chapterCount: number;\n};\n\nexport default function ChapterRangeSelector({\n startChapter,\n endChapter,\n handleSelectStartChapter,\n handleSelectEndChapter,\n isDisabled = false,\n chapterCount,\n}: ChapterRangeSelectorProps) {\n const chapterOptions = useMemo(\n () => Array.from({ length: chapterCount }, (_, index) => index + 1),\n [chapterCount],\n );\n\n const onChangeStartChapter = (value: number) => {\n handleSelectStartChapter(value);\n if (value > endChapter) {\n handleSelectEndChapter(value);\n }\n };\n\n const onChangeEndChapter = (value: number) => {\n handleSelectEndChapter(value);\n if (value < startChapter) {\n handleSelectStartChapter(value);\n }\n };\n\n return (\n <>\n \n option.toString()}\n value={startChapter}\n />\n\n \n option.toString()}\n value={endChapter}\n />\n \n );\n}\n","import { Button } from '@/components/shadcn-ui/button';\nimport { Label } from '@/components/shadcn-ui/label';\nimport { RadioGroup, RadioGroupItem } from '@/components/shadcn-ui/radio-group';\nimport { Canon } from '@sillsdev/scripture';\nimport { LocalizedStringValue } from 'platform-bible-utils';\nimport { useState } from 'react';\nimport ChapterRangeSelector, {\n ChapterRangeSelectorProps,\n} from '../basics/chapter-range-selector.component';\n\nexport enum BookSelectionMode {\n CURRENT_BOOK = 'current book',\n CHOOSE_BOOKS = 'choose books',\n}\n\n/**\n * Object containing all keys used for localization in this component. If you're using this\n * component in an extension, you can pass it into the useLocalizedStrings hook to easily obtain the\n * localized strings and pass them into the localizedStrings prop of this component\n */\nexport const BOOK_SELECTOR_STRING_KEYS = Object.freeze([\n '%webView_bookSelector_currentBook%',\n '%webView_bookSelector_choose%',\n '%webView_bookSelector_chooseBooks%',\n] as const);\n\nexport type BookSelectorLocalizedStrings = {\n [localizedInventoryKey in (typeof BOOK_SELECTOR_STRING_KEYS)[number]]?: LocalizedStringValue;\n};\n\n/**\n * Gets the localized value for the provided key\n *\n * @param strings Object containing localized string\n * @param key Key for a localized string\n * @returns The localized value for the provided key, if available. Returns the key if no localized\n * value is available\n */\nconst localizeString = (\n strings: BookSelectorLocalizedStrings,\n key: keyof BookSelectorLocalizedStrings,\n) => {\n return strings[key] ?? key;\n};\n\ntype BookSelectorProps = ChapterRangeSelectorProps & {\n handleBookSelectionModeChange: (newMode: BookSelectionMode) => void;\n currentBookName: string;\n onSelectBooks: () => void;\n selectedBookIds: string[];\n localizedStrings: BookSelectorLocalizedStrings;\n};\n\nexport default function BookSelector({\n handleBookSelectionModeChange,\n currentBookName,\n onSelectBooks,\n selectedBookIds,\n chapterCount,\n endChapter,\n handleSelectEndChapter,\n startChapter,\n handleSelectStartChapter,\n localizedStrings,\n}: BookSelectorProps) {\n const currentBookText = localizeString(localizedStrings, '%webView_bookSelector_currentBook%');\n const chooseText = localizeString(localizedStrings, '%webView_bookSelector_choose%');\n const chooseBooksText = localizeString(localizedStrings, '%webView_bookSelector_chooseBooks%');\n\n const [bookSelectionMode, setBookSelectionMode] = useState(\n BookSelectionMode.CURRENT_BOOK,\n );\n\n const onSelectionModeChange = (newMode: BookSelectionMode) => {\n setBookSelectionMode(newMode);\n handleBookSelectionModeChange(newMode);\n };\n\n return (\n onSelectionModeChange(value as BookSelectionMode)}\n >\n
    \n
    \n
    \n \n \n
    \n \n
    \n \n
    \n
    \n
    \n
    \n \n \n
    \n \n onSelectBooks()}\n >\n {chooseText}\n \n
    \n
    \n \n );\n}\n","import { DropdownMenuTrigger } from '@radix-ui/react-dropdown-menu';\nimport { FilterIcon } from 'lucide-react';\nimport { Table } from '@tanstack/react-table';\n\nimport { Button } from '@/components/shadcn-ui/button';\nimport {\n DropdownMenu,\n DropdownMenuCheckboxItem,\n DropdownMenuContent,\n DropdownMenuLabel,\n DropdownMenuSeparator,\n} from '@/components/shadcn-ui/dropdown-menu';\n\ninterface DataTableViewOptionsProps {\n table: Table;\n}\n\nfunction DataTableViewOptions({ table }: DataTableViewOptionsProps) {\n return (\n \n \n \n \n \n Toggle columns\n \n {table\n .getAllColumns()\n .filter((column) => column.getCanHide())\n .map((column) => {\n return (\n column.toggleVisibility(!!value)}\n >\n {column.id}\n \n );\n })}\n \n \n );\n}\n\nexport default DataTableViewOptions;\n","import React from 'react';\nimport * as SelectPrimitive from '@radix-ui/react-select';\nimport { Check, ChevronDown, ChevronUp } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Select = SelectPrimitive.Root;\n\nconst SelectGroup = SelectPrimitive.Group;\n\nconst SelectValue = SelectPrimitive.Value;\n\nconst SelectTrigger = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, ...props }, ref) => (\n span]:tw-line-clamp-1',\n className,\n )}\n {...props}\n >\n {children}\n \n \n \n \n));\nSelectTrigger.displayName = SelectPrimitive.Trigger.displayName;\n\nconst SelectScrollUpButton = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n));\nSelectScrollUpButton.displayName = SelectPrimitive.ScrollUpButton.displayName;\n\nconst SelectScrollDownButton = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n));\nSelectScrollDownButton.displayName = SelectPrimitive.ScrollDownButton.displayName;\n\nconst SelectContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, position = 'popper', ...props }, ref) => (\n \n \n \n \n {children}\n \n \n \n \n));\nSelectContent.displayName = SelectPrimitive.Content.displayName;\n\nconst SelectLabel = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSelectLabel.displayName = SelectPrimitive.Label.displayName;\n\nconst SelectItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, ...props }, ref) => (\n \n \n \n \n \n \n\n {children}\n \n));\nSelectItem.displayName = SelectPrimitive.Item.displayName;\n\nconst SelectSeparator = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSelectSeparator.displayName = SelectPrimitive.Separator.displayName;\n\nexport {\n Select,\n SelectGroup,\n SelectValue,\n SelectTrigger,\n SelectContent,\n SelectLabel,\n SelectItem,\n SelectSeparator,\n SelectScrollUpButton,\n SelectScrollDownButton,\n};\n","import { ChevronLeftIcon, ChevronRightIcon, ArrowLeftIcon, ArrowRightIcon } from 'lucide-react';\nimport { Table } from '@tanstack/react-table';\n\nimport { Button } from '@/components/shadcn-ui/button';\nimport {\n Select,\n SelectContent,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\n\ninterface DataTablePaginationProps {\n table: Table;\n}\n\nfunction DataTablePagination({ table }: DataTablePaginationProps) {\n return (\n
    \n
    \n
    \n {table.getFilteredSelectedRowModel().rows.length} of{' '}\n {table.getFilteredRowModel().rows.length} row(s) selected\n
    \n
    \n

    Rows per page

    \n {\n table.setPageSize(Number(value));\n }}\n >\n \n \n \n \n {[10, 20, 30, 40, 50].map((pageSize) => (\n \n {pageSize}\n \n ))}\n \n \n
    \n
    \n Page {table.getState().pagination.pageIndex + 1} of {table.getPageCount()}\n
    \n
    \n table.setPageIndex(0)}\n disabled={!table.getCanPreviousPage()}\n >\n Go to first page\n \n \n table.previousPage()}\n disabled={!table.getCanPreviousPage()}\n >\n Go to previous page\n \n \n table.nextPage()}\n disabled={!table.getCanNextPage()}\n >\n Go to next page\n \n \n table.setPageIndex(table.getPageCount() - 1)}\n disabled={!table.getCanNextPage()}\n >\n Go to last page\n \n \n
    \n
    \n
    \n );\n}\n\nexport default DataTablePagination;\n","import React from 'react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Table = React.forwardRef<\n HTMLTableElement,\n React.HTMLAttributes & { stickyHeader?: boolean }\n>(({ className, stickyHeader, ...props }, ref) => (\n
    \n \n
    \n));\nTable.displayName = 'Table';\n\nconst TableHeader = React.forwardRef<\n HTMLTableSectionElement,\n React.HTMLAttributes & { stickyHeader?: boolean }\n>(({ className, stickyHeader, ...props }, ref) => (\n \n));\nTableHeader.displayName = 'TableHeader';\n\nconst TableBody = React.forwardRef<\n HTMLTableSectionElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableBody.displayName = 'TableBody';\n\nconst TableFooter = React.forwardRef<\n HTMLTableSectionElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n tr]:last:tw-border-b-0', className)}\n {...props}\n />\n));\nTableFooter.displayName = 'TableFooter';\n\nconst TableRow = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nTableRow.displayName = 'TableRow';\n\nconst TableHead = React.forwardRef<\n HTMLTableCellElement,\n React.ThHTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableHead.displayName = 'TableHead';\n\nconst TableCell = React.forwardRef<\n HTMLTableCellElement,\n React.TdHTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableCell.displayName = 'TableCell';\n\nconst TableCaption = React.forwardRef<\n HTMLTableCaptionElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableCaption.displayName = 'TableCaption';\n\nexport { Table, TableHeader, TableBody, TableFooter, TableHead, TableRow, TableCell, TableCaption };\n","import { useState } from 'react';\n\nimport {\n ColumnFiltersState,\n flexRender,\n getCoreRowModel,\n getFilteredRowModel,\n getPaginationRowModel,\n getSortedRowModel,\n SortingState,\n ColumnDef as TSColumnDef,\n Row as TSRow,\n RowSelectionState as TSRowSelectionState,\n SortDirection as TSSortDirection,\n Table as TSTable,\n useReactTable,\n VisibilityState,\n} from '@tanstack/react-table';\n\nimport DataTableViewOptions from '@/components/advanced/data-table/data-table-column-toggle.component';\nimport DataTablePagination from '@/components/advanced/data-table/data-table-pagination.component';\nimport { Button } from '@/components/shadcn-ui/button';\nimport {\n Table,\n TableBody,\n TableCell,\n TableHead,\n TableHeader,\n TableRow,\n} from '@/components/shadcn-ui/table';\n\nexport type ColumnDef = TSColumnDef;\nexport type RowContents = TSRow;\nexport type TableContents = TSTable;\nexport type SortDirection = TSSortDirection;\nexport type RowSelectionState = TSRowSelectionState;\n\ninterface DataTableProps {\n columns: ColumnDef[];\n data: TData[];\n enablePagination?: boolean;\n showPaginationControls?: boolean;\n showColumnVisibilityControls?: boolean;\n stickyHeader?: boolean;\n onRowClickHandler?: (row: RowContents, table: TableContents) => void;\n}\n\n/**\n * Feature-rich table component that infuses our basic shadcn-based Table component with features\n * from TanStack's React Table library\n */\nfunction DataTable({\n columns,\n data,\n enablePagination = false,\n showPaginationControls = false,\n showColumnVisibilityControls = false,\n stickyHeader = false,\n onRowClickHandler = () => {},\n}: DataTableProps) {\n const [sorting, setSorting] = useState([]);\n const [columnFilters, setColumnFilters] = useState([]);\n const [columnVisibility, setColumnVisibility] = useState({});\n const [rowSelection, setRowSelection] = useState({});\n\n const table = useReactTable({\n data,\n columns,\n getCoreRowModel: getCoreRowModel(),\n ...(enablePagination && { getPaginationRowModel: getPaginationRowModel() }),\n onSortingChange: setSorting,\n getSortedRowModel: getSortedRowModel(),\n onColumnFiltersChange: setColumnFilters,\n getFilteredRowModel: getFilteredRowModel(),\n onColumnVisibilityChange: setColumnVisibility,\n onRowSelectionChange: setRowSelection,\n state: {\n sorting,\n columnFilters,\n columnVisibility,\n rowSelection,\n },\n });\n\n return (\n
    \n {showColumnVisibilityControls && }\n \n \n {table.getHeaderGroups().map((headerGroup) => (\n \n {headerGroup.headers.map((header) => {\n return (\n \n {header.isPlaceholder\n ? undefined\n : flexRender(header.column.columnDef.header, header.getContext())}\n \n );\n })}\n \n ))}\n \n \n {table.getRowModel().rows?.length ? (\n table.getRowModel().rows.map((row) => (\n onRowClickHandler(row, table)}\n key={row.id}\n data-state={row.getIsSelected() && 'selected'}\n >\n {row.getVisibleCells().map((cell) => (\n \n {flexRender(cell.column.columnDef.cell, cell.getContext())}\n \n ))}\n \n ))\n ) : (\n \n \n No results.\n \n \n )}\n \n
    \n {enablePagination && (\n
    \n table.previousPage()}\n disabled={!table.getCanPreviousPage()}\n >\n Previous\n \n table.nextPage()}\n disabled={!table.getCanNextPage()}\n >\n Next\n \n
    \n )}\n {enablePagination && showPaginationControls && }\n
    \n );\n}\n\nexport default DataTable;\n","import {\n Table,\n TableBody,\n TableCell,\n TableHead,\n TableHeader,\n TableRow,\n} from '@/components/shadcn-ui/table';\nimport { Canon } from '@sillsdev/scripture';\nimport { deepEqual, LanguageStrings, ScriptureReference } from 'platform-bible-utils';\nimport { useMemo } from 'react';\nimport { InventoryItemOccurrence } from './inventory-utils';\n\n/** Props for the OccurrencesTable component */\ntype OccurrencesTableProps = {\n /** Data that contains scriptures references and snippets of scripture */\n occurrenceData: InventoryItemOccurrence[];\n /** Callback function that is executed when the scripture reference is changed */\n setScriptureReference: (scriptureReference: ScriptureReference) => void;\n /**\n * Object with all localized strings that the OccurrencesTable needs to work well across multiple\n * languages\n */\n localizedStrings: LanguageStrings;\n};\n\n/**\n * Table that shows occurrences of specified inventory item(s). The first column shows the related\n * scripture reference. The second column shows the snippet of scripture that contains the specified\n * inventory item\n */\nfunction OccurrencesTable({\n occurrenceData,\n setScriptureReference,\n localizedStrings,\n}: OccurrencesTableProps) {\n const referenceHeaderText =\n localizedStrings['%webView_inventory_occurrences_table_header_reference%'];\n const occurrenceHeaderText =\n localizedStrings['%webView_inventory_occurrences_table_header_occurrence%'];\n\n const occurrences: InventoryItemOccurrence[] = useMemo(() => {\n const uniqueOccurrences: InventoryItemOccurrence[] = [];\n\n occurrenceData.forEach((occurrence) => {\n if (!uniqueOccurrences.some((uniqueOccurrence) => deepEqual(uniqueOccurrence, occurrence))) {\n uniqueOccurrences.push(occurrence);\n }\n });\n\n return uniqueOccurrences;\n }, [occurrenceData]);\n\n return (\n \n \n \n {referenceHeaderText}\n {occurrenceHeaderText}\n \n \n \n {occurrences.length > 0 &&\n occurrences.map((occurrence) => (\n {\n setScriptureReference(occurrence.reference);\n }}\n >\n {`${Canon.bookNumberToEnglishName(occurrence.reference.bookNum)} ${occurrence.reference.chapterNum}:${occurrence.reference.verseNum}`}\n {occurrence.text}\n \n ))}\n \n
    \n );\n}\n\nexport default OccurrencesTable;\n","import React from 'react';\nimport * as CheckboxPrimitive from '@radix-ui/react-checkbox';\nimport { Check } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Checkbox = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n \n \n));\nCheckbox.displayName = CheckboxPrimitive.Root.displayName;\n\nexport default Checkbox;\n","import { Canon } from '@sillsdev/scripture';\nimport { ScriptureReference } from 'platform-bible-utils';\n\n/* #region Types */\n\n/**\n * Status of items that appear in inventories. 'approved' and 'unapproved' items are defined in the\n * project's `Settings.xml`. All other items are defined as 'unknown'\n */\nexport type Status = 'approved' | 'unapproved' | 'unknown';\n\n/** Occurrence of item in inventory. Primarily used by table that shows occurrences */\nexport type InventoryItemOccurrence = {\n /** Reference to scripture where the item appears */\n reference: ScriptureReference;\n /** Snippet of scripture that contains the occurrence */\n text: string;\n};\n\n/** Data structure that contains all information on an item that is shown in an inventory */\nexport type InventoryTableData = {\n /**\n * The item (e.g. a character in the characters inventory, a marker in the marker inventory) In\n * most cases the array will only have one element. In case of additional items (e.g. the\n * preceding marker in the markers check), the primary item should be stored in the first index.\n * To show additional items in the inventory, make sure to configure the `additionalItemsLabels`\n * prop for the Inventory component\n */\n items: string[];\n /** The number of times this item occurs in the selected scope */\n count: number;\n /** The status of this item (see documentation for `Status` type for more information) */\n status: Status;\n /** Occurrences of this item in the scripture text for the selected scope */\n occurrences: InventoryItemOccurrence[];\n};\n\n/* #endregion */\n\n/* #region Functions */\n\n/**\n * Splits USFM string into shorter line-like segments\n *\n * @param text A single (likely very large) USFM string\n * @returns An array containing the input text, split into shorter segments\n */\nexport const getLinesFromUSFM = (text: string) => {\n // Splits on (CR)LF, CR, \\v, \\c and \\id\n return text.split(/(?:\\r?\\n|\\r)|(?=(?:\\\\(?:v|c|id)))/g);\n};\n\n/**\n * Extracts chapter or verse number from USFM strings that start with a \\c or \\v marker\n *\n * @param text USFM string that is expected to start with \\c or \\v marker\n * @returns Chapter or verse number if one is found. Else returns 0.\n */\nexport const getNumberFromUSFM = (text: string): number | undefined => {\n // Captures all digits that follow \\v or \\c markers followed by whitespace located at the start of a string\n const regex = /^\\\\[vc]\\s+(\\d+)/;\n const match = text.match(regex);\n\n if (match) {\n return +match[1];\n }\n return undefined;\n};\n\n/**\n * Gets book ID from USFM string that starts with the \\id marker, and returns book number for it\n *\n * @param text USFM string that is expected to start with \\id marker\n * @returns Book number corresponding to the \\id marker in the input text. Returns 0 if no marker is\n * found or the marker is not valid\n */\nexport const getBookNumFromId = (text: string): number => {\n // Captures all digits that follow an \\id marker followed by whitespace located at the start of a string\n const match = text.match(/^\\\\id\\s+([A-Za-z]+)/);\n if (match) {\n return Canon.bookIdToNumber(match[1]);\n }\n return 0;\n};\n\n/**\n * Gets the status for an item, typically used in the Inventory component\n *\n * @param item The item for which the status is being requested\n * @param approvedItems Array of approved items, typically as defined in `Settings.xml`\n * @param unapprovedItems Array of unapproved items, typically as defined in `Settings.xml`\n * @returns The status for the specified item\n */\nexport const getStatusForItem = (\n item: string,\n approvedItems: string[],\n unapprovedItems: string[],\n): Status => {\n if (unapprovedItems.includes(item)) return 'unapproved';\n if (approvedItems.includes(item)) return 'approved';\n return 'unknown';\n};\n\n/* #endregion */\n","import React from 'react';\nimport * as TogglePrimitive from '@radix-ui/react-toggle';\nimport { cva, type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst toggleVariants = cva(\n 'pr-twp tw-inline-flex tw-items-center tw-justify-center tw-rounded-md tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-colors hover:tw-bg-muted hover:tw-text-muted-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50 data-[state=on]:tw-bg-accent data-[state=on]:tw-text-accent-foreground',\n {\n variants: {\n variant: {\n default: 'tw-bg-transparent',\n outline:\n 'tw-border tw-border-input tw-bg-transparent hover:tw-bg-accent hover:tw-text-accent-foreground',\n },\n size: {\n default: 'tw-h-10 tw-px-3',\n sm: 'tw-h-9 tw-px-2.5',\n lg: 'tw-h-11 tw-px-5',\n },\n },\n defaultVariants: {\n variant: 'default',\n size: 'default',\n },\n },\n);\n\nconst Toggle = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef & VariantProps\n>(({ className, variant, size, ...props }, ref) => (\n \n));\n\nToggle.displayName = TogglePrimitive.Root.displayName;\n\nexport { Toggle, toggleVariants };\n","import React from 'react';\nimport * as ToggleGroupPrimitive from '@radix-ui/react-toggle-group';\nimport { type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { toggleVariants } from '@/components/shadcn-ui/toggle';\n\nconst ToggleGroupContext = React.createContext>({\n size: 'default',\n variant: 'default',\n});\n\nconst ToggleGroup = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef &\n VariantProps\n>(({ className, variant, size, children, ...props }, ref) => (\n \n \n {children}\n \n \n));\n\nToggleGroup.displayName = ToggleGroupPrimitive.Root.displayName;\n\nconst ToggleGroupItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef &\n VariantProps\n>(({ className, children, variant, size, ...props }, ref) => {\n const context = React.useContext(ToggleGroupContext);\n\n return (\n \n {children}\n \n );\n});\n\nToggleGroupItem.displayName = ToggleGroupPrimitive.Item.displayName;\n\nexport { ToggleGroup, ToggleGroupItem };\n","import { ColumnDef, SortDirection } from '@/components/advanced/data-table/data-table.component';\nimport { Button } from '@/components/shadcn-ui/button';\nimport { ToggleGroup, ToggleGroupItem } from '@/components/shadcn-ui/toggle-group';\nimport {\n ArrowDownIcon,\n ArrowUpDownIcon,\n ArrowUpIcon,\n CircleCheckIcon,\n CircleHelpIcon,\n CircleXIcon,\n} from 'lucide-react';\nimport { ReactNode } from 'react';\nimport { InventoryTableData, Status } from './inventory-utils';\n\n/**\n * Gets an icon that indicates the current sorting direction based on the provided input\n *\n * @param sortDirection Sorting direction. Can be ascending ('asc'), descending ('desc') or false (\n * i.e. not sorted)\n * @returns The appropriate sorting icon for the provided sorting direction\n */\nconst getSortingIcon = (sortDirection: false | SortDirection): ReactNode => {\n if (sortDirection === 'asc') {\n return ;\n }\n if (sortDirection === 'desc') {\n return ;\n }\n return ;\n};\n\n/**\n * Function that creates the item column for inventories\n *\n * @param itemLabel Localized label for the item column (e.g. 'Character', 'Repeated Word', etc.)\n * @returns Column that shows the inventory items. Should be used with the DataTable component\n */\nexport const inventoryItemColumn = (itemLabel: string): ColumnDef => {\n return {\n accessorKey: 'item',\n accessorFn: (row: InventoryTableData) => row.items[0],\n header: ({ column }) => (\n \n ),\n };\n};\n\n/**\n * Function that creates the additional item columns for inventories\n *\n * @param additionalItemLabel Localized label for the additional item column (e.g. 'Preceding\n * Marker')\n * @param additionalItemIndex Index that locates the desired item in the items array of the\n * inventory\n * @returns Column that shows additional inventory items. Should be used with the DataTable\n * component\n */\nexport const inventoryAdditionalItemColumn = (\n additionalItemLabel: string,\n additionalItemIndex: number,\n): ColumnDef => {\n return {\n accessorKey: `item${additionalItemIndex}`,\n accessorFn: (row: InventoryTableData) => row.items[additionalItemIndex],\n header: ({ column }) => (\n \n ),\n };\n};\n\n/**\n * Function that creates the count column for inventories. Should be used with the DataTable\n * component.\n *\n * @param itemLabel Localized label for the count column\n * @returns Column that shows the number of occurrences of the related inventory items\n */\nexport const inventoryCountColumn = (countLabel: string): ColumnDef => {\n return {\n accessorKey: 'count',\n header: ({ column }) => (\n
    \n \n
    \n ),\n cell: ({ row }) =>
    {row.getValue('count')}
    ,\n };\n};\n\n/**\n * Function that updates project settings when status for item(s) changes\n *\n * @param changedItems Array of items for which the status is being updated\n * @param newStatus The status that the items are being given\n * @param approvedItems Array of currently approved items\n * @param onApprovedItemsChange Callback function that stores the updated list of approved items\n * @param unapprovedItems Array of currently unapproved items\n * @param onUnapprovedItemsChange Callback function that stores the updated list of unapproved items\n */\nconst statusChangeHandler = (\n changedItems: string[],\n newStatus: Status,\n approvedItems: string[],\n onApprovedItemsChange: (items: string[]) => void,\n unapprovedItems: string[],\n onUnapprovedItemsChange: (items: string[]) => void,\n) => {\n let newApprovedItems: string[] = [...approvedItems];\n changedItems.forEach((item) => {\n if (newStatus === 'approved') {\n if (!newApprovedItems.includes(item)) {\n newApprovedItems.push(item);\n }\n } else {\n newApprovedItems = newApprovedItems.filter((validItem) => validItem !== item);\n }\n });\n onApprovedItemsChange(newApprovedItems);\n\n let newUnapprovedItems: string[] = [...unapprovedItems];\n changedItems.forEach((item) => {\n if (newStatus === 'unapproved') {\n if (!newUnapprovedItems.includes(item)) {\n newUnapprovedItems.push(item);\n }\n } else {\n newUnapprovedItems = newUnapprovedItems.filter((unapprovedItem) => unapprovedItem !== item);\n }\n });\n onUnapprovedItemsChange(newUnapprovedItems);\n};\n\n/**\n * Function that creates the status column for inventories. Should be used with the DataTable\n * component.\n *\n * @param statusLabel Localized label for the status column\n * @param approvedItems Array of approved items, typically as defined in `Settings.xml`\n * @param onApprovedItemsChange Callback function that stores the updated list of approved items\n * @param unapprovedItems Array of unapproved items, typically as defined in `Settings.xml`\n * @param onUnapprovedItemsChange Callback function that stores the updated list of unapproved items\n * @returns Column that shows the status buttons for the related inventory item. The button for the\n * current status of the item is selected\n */\nexport const inventoryStatusColumn = (\n statusLabel: string,\n approvedItems: string[],\n onApprovedItemsChange: (items: string[]) => void,\n unapprovedItems: string[],\n onUnapprovedItemsChange: (items: string[]) => void,\n): ColumnDef => {\n return {\n accessorKey: 'status',\n header: ({ column }) => {\n return (\n
    \n \n
    \n );\n },\n cell: ({ row }) => {\n const status: Status = row.getValue('status');\n const item: string = row.getValue('item');\n return (\n \n \n statusChangeHandler(\n [item],\n 'approved',\n approvedItems,\n onApprovedItemsChange,\n unapprovedItems,\n onUnapprovedItemsChange,\n )\n }\n value=\"approved\"\n >\n \n \n \n statusChangeHandler(\n [item],\n 'unapproved',\n approvedItems,\n onApprovedItemsChange,\n unapprovedItems,\n onUnapprovedItemsChange,\n )\n }\n value=\"unapproved\"\n >\n \n \n \n statusChangeHandler(\n [item],\n 'unknown',\n approvedItems,\n onApprovedItemsChange,\n unapprovedItems,\n onUnapprovedItemsChange,\n )\n }\n value=\"unknown\"\n >\n \n \n \n );\n },\n };\n};\n","import DataTable, {\n ColumnDef,\n RowContents,\n RowSelectionState,\n TableContents,\n} from '@/components/advanced/data-table/data-table.component';\nimport OccurrencesTable from '@/components/advanced/inventory/occurrences-table.component';\nimport Checkbox from '@/components/shadcn-ui/checkbox';\nimport { Input } from '@/components/shadcn-ui/input';\nimport { Label } from '@/components/shadcn-ui/label';\nimport {\n Select,\n SelectContent,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\nimport {\n deepEqual,\n LocalizedStringValue,\n ScriptureReference,\n substring,\n} from 'platform-bible-utils';\nimport { useEffect, useMemo, useState } from 'react';\nimport {\n getBookNumFromId,\n getLinesFromUSFM,\n getNumberFromUSFM,\n getStatusForItem,\n InventoryItemOccurrence,\n InventoryTableData,\n Status,\n} from './inventory-utils';\nimport { inventoryAdditionalItemColumn } from './inventory-columns';\n\n/**\n * Object containing all keys used for localization in this component. If you're using this\n * component in an extension, you can pass it into the useLocalizedStrings hook to easily obtain the\n * localized strings and pass them into the localizedStrings prop of this component\n */\nexport const INVENTORY_STRING_KEYS = Object.freeze([\n '%webView_inventory_all%',\n '%webView_inventory_approved%',\n '%webView_inventory_unapproved%',\n '%webView_inventory_unknown%',\n '%webView_inventory_scope_currentBook%',\n '%webView_inventory_scope_chapter%',\n '%webView_inventory_scope_verse%',\n '%webView_inventory_filter_text%',\n '%webView_inventory_show_additional_items%',\n '%webView_inventory_occurrences_table_header_reference%',\n '%webView_inventory_occurrences_table_header_occurrence%',\n] as const);\n\nexport type InventoryLocalizedStrings = {\n [localizedInventoryKey in (typeof INVENTORY_STRING_KEYS)[number]]?: LocalizedStringValue;\n};\n\n/** Scope of scripture that the inventory can operate on */\nexport type Scope = 'book' | 'chapter' | 'verse';\n\n/** Status values that the status filter can select from */\ntype StatusFilter = Status | 'all';\n\n/** Text labels for the inventory columns and the control components of additional inventory items */\ntype AdditionalItemsLabels = {\n checkboxText?: string;\n tableHeaders?: string[];\n};\n\n/**\n * Filters data that is shown in the DataTable section of the Inventory\n *\n * @param itemData All inventory items and their related information\n * @param statusFilter Allows filtering by status (i.e. show all items, or only items that are\n * 'approved', 'unapproved' or 'unknown')\n * @param textFilter Allows filtering by text. All items that include the filter text will be\n * selected.\n * @returns Array of items and their related information that are matched by the specified filters\n */\nconst filterItemData = (\n itemData: InventoryTableData[],\n statusFilter: StatusFilter,\n textFilter: string,\n): InventoryTableData[] => {\n let filteredItemData: InventoryTableData[] = itemData;\n\n if (statusFilter !== 'all') {\n filteredItemData = filteredItemData.filter(\n (item) =>\n (statusFilter === 'approved' && item.status === 'approved') ||\n (statusFilter === 'unapproved' && item.status === 'unapproved') ||\n (statusFilter === 'unknown' && item.status === 'unknown'),\n );\n }\n\n if (textFilter !== '')\n filteredItemData = filteredItemData.filter((item) => item.items[0].includes(textFilter));\n\n return filteredItemData;\n};\n\n/**\n * Turns array of strings into array of inventory items, along with their count and status\n *\n * @param text The source scripture text that is searched for inventory items\n * @param scriptureRef The scripture reference that the application is currently set to\n * @param approvedItems Array of approved items, typically as defined in `Settings.xml`\n * @param unapprovedItems Array of unapproved items, typically as defined in `Settings.xml`\n * @param itemRegex Regular expression that describes what items this Inventory should extract from\n * the provided scripture text\n * @returns Array of inventory items, along with their count and status\n */\nconst createTableData = (\n text: string | undefined,\n scriptureRef: ScriptureReference,\n approvedItems: string[],\n unapprovedItems: string[],\n itemRegex: RegExp,\n): InventoryTableData[] => {\n if (!text) return [];\n\n const tableData: InventoryTableData[] = [];\n\n let currentBook: number | undefined = scriptureRef.bookNum;\n let currentChapter: number | undefined = scriptureRef.chapterNum;\n let currentVerse: number | undefined = scriptureRef.verseNum;\n\n const lines = getLinesFromUSFM(text);\n\n lines.forEach((line: string) => {\n if (line.startsWith('\\\\id')) {\n currentBook = getBookNumFromId(line);\n currentChapter = 0;\n currentVerse = 0;\n }\n if (line.startsWith('\\\\c')) {\n currentChapter = getNumberFromUSFM(line);\n currentVerse = 0;\n }\n if (line.startsWith('\\\\v')) {\n currentVerse = getNumberFromUSFM(line);\n if (currentChapter === 0) {\n currentChapter = scriptureRef.chapterNum;\n }\n }\n\n let match: RegExpExecArray | undefined = itemRegex.exec(line) ?? undefined;\n while (match) {\n const items: string[] = [];\n match.forEach((item) => items.push(item));\n const itemIndex = match.index;\n const existingItem = tableData.find((tableEntry) => deepEqual(tableEntry.items, items));\n const newReference: InventoryItemOccurrence = {\n reference: {\n bookNum: currentBook !== undefined ? currentBook : -1,\n chapterNum: currentChapter !== undefined ? currentChapter : -1,\n verseNum: currentVerse !== undefined ? currentVerse : -1,\n },\n text: substring(line, Math.max(0, itemIndex - 25), Math.min(itemIndex + 25, line.length)),\n };\n if (existingItem) {\n existingItem.count += 1;\n existingItem.occurrences.push(newReference);\n } else {\n const newItem: InventoryTableData = {\n items,\n count: 1,\n status: getStatusForItem(items[0], approvedItems, unapprovedItems),\n occurrences: [newReference],\n };\n tableData.push(newItem);\n }\n\n match = itemRegex.exec(line) ?? undefined;\n }\n });\n\n return tableData;\n};\n\n/**\n * Gets the localized value for the provided key\n *\n * @param strings Object containing localized string\n * @param key Key for a localized string\n * @returns The localized value for the provided key, if available. Returns the key if no localized\n * value is available\n */\nconst localizeString = (\n strings: InventoryLocalizedStrings,\n key: keyof InventoryLocalizedStrings,\n) => {\n return strings[key] ?? key;\n};\n\n/** Props for the Inventory component */\ntype InventoryProps = {\n /** The scripture reference that the application is currently set to */\n scriptureReference: ScriptureReference;\n /** Callback function that is executed when the scripture reference is changed */\n setScriptureReference: (scriptureReference: ScriptureReference) => void;\n /**\n * Object with all localized strings that the Inventory needs to work well across multiple\n * languages. When using this component with Platform.Bible, you can import\n * `INVENTORY_STRING_KEYS` from this library, pass it in to the Platform's localization hook, and\n * pass the localized keys that are returned by the hook into this prop.\n */\n localizedStrings: InventoryLocalizedStrings;\n /**\n * The logic that finds the desired items in the source text. This can either be a Regular\n * expression that captures one or multiple items (preferred), or a custom function that builds\n * and return an InventoryDataTable[] manually. Note: In case the logic captures more than one\n * item (i.e. InventoryTableData.items has a length greater than 1), you must provide text labels\n * for the related columns and control elements to show by setting the `additionalItemsLabels`\n * prop\n */\n extractItems:\n | RegExp\n | ((\n text: string | undefined,\n scriptureRef: ScriptureReference,\n approvedItems: string[],\n unapprovedItems: string[],\n ) => InventoryTableData[]);\n /**\n * Text labels for control elements and additional column headers in case your Inventory has more\n * than one item to show (e.g. The 'Preceding Marker' in the Markers Inventory)\n */\n additionalItemsLabels?: AdditionalItemsLabels;\n /** Array of approved items, typically as defined in `Settings.xml` */\n approvedItems: string[];\n /** Array of unapproved items, typically as defined in `Settings.xml` */\n unapprovedItems: string[];\n /** The source scripture text that is searched for in inventory items */\n text: string | undefined;\n /** Scope of scripture that the inventory will operate on */\n scope: Scope;\n /** Callback function that is executed when the scope is changed from the Inventory */\n onScopeChange: (scope: Scope) => void;\n /**\n * Column definitions for the Inventory data table. The most commonly used column definitions are\n * pre-configured for your convenience and can be imported (e.g. inventoryItemColumn,\n * inventoryAdditionalItemColumn inventoryCountColumn, and inventoryStatusColumn). If you need any\n * other columns you can add these yourself\n */\n columns: ColumnDef[];\n};\n\n/** Inventory component that is used to view and control the status of provided project settings */\nexport default function Inventory({\n scriptureReference,\n setScriptureReference,\n localizedStrings,\n extractItems,\n additionalItemsLabels,\n approvedItems,\n unapprovedItems,\n text,\n scope,\n onScopeChange,\n columns,\n}: InventoryProps) {\n const allItemsText = localizeString(localizedStrings, '%webView_inventory_all%');\n const approvedItemsText = localizeString(localizedStrings, '%webView_inventory_approved%');\n const unapprovedItemsText = localizeString(localizedStrings, '%webView_inventory_unapproved%');\n const unknownItemsText = localizeString(localizedStrings, '%webView_inventory_unknown%');\n const scopeBookText = localizeString(localizedStrings, '%webView_inventory_scope_currentBook%');\n const scopeChapterText = localizeString(localizedStrings, '%webView_inventory_scope_chapter%');\n const scopeVerseText = localizeString(localizedStrings, '%webView_inventory_scope_verse%');\n const filterText = localizeString(localizedStrings, '%webView_inventory_filter_text%');\n const showAdditionalItemsText = localizeString(\n localizedStrings,\n '%webView_inventory_show_additional_items%',\n );\n\n const [showAdditionalItems, setShowAdditionalItems] = useState(false);\n const [statusFilter, setStatusFilter] = useState('all');\n const [textFilter, setTextFilter] = useState('');\n const [selectedItem, setSelectedItem] = useState([]);\n\n const tableData: InventoryTableData[] = useMemo(() => {\n if (!text) return [];\n if (extractItems instanceof RegExp)\n return createTableData(\n text,\n scriptureReference,\n approvedItems,\n unapprovedItems,\n extractItems,\n );\n return extractItems(text, scriptureReference, approvedItems, unapprovedItems);\n }, [text, extractItems, scriptureReference, approvedItems, unapprovedItems]);\n\n const reducedTableData: InventoryTableData[] = useMemo(() => {\n if (showAdditionalItems) return tableData;\n\n const newTableData: InventoryTableData[] = [];\n\n tableData.forEach((tableEntry) => {\n const firstItem = tableEntry.items[0];\n\n const existingEntry = newTableData.find(\n (newTableEntry) => newTableEntry.items[0] === firstItem,\n );\n\n if (existingEntry) {\n existingEntry.count += tableEntry.count;\n existingEntry.occurrences = existingEntry.occurrences.concat(tableEntry.occurrences);\n } else {\n newTableData.push({\n items: [firstItem],\n count: tableEntry.count,\n occurrences: tableEntry.occurrences,\n status: tableEntry.status,\n });\n }\n });\n\n return newTableData;\n }, [showAdditionalItems, tableData]);\n\n const filteredTableData: InventoryTableData[] = useMemo(() => {\n return filterItemData(reducedTableData, statusFilter, textFilter);\n }, [reducedTableData, statusFilter, textFilter]);\n\n const allColumns: ColumnDef[] = useMemo(() => {\n if (!showAdditionalItems) return columns;\n\n const numberOfAdditionalItems = additionalItemsLabels?.tableHeaders?.length;\n if (!numberOfAdditionalItems) return columns;\n\n const additionalColumns: ColumnDef[] = [];\n\n for (let index = 0; index < numberOfAdditionalItems; index++) {\n additionalColumns.push(\n inventoryAdditionalItemColumn(\n additionalItemsLabels?.tableHeaders?.[index] || 'Additional Item',\n index + 1,\n ),\n );\n }\n\n return [...additionalColumns, ...columns];\n }, [additionalItemsLabels?.tableHeaders, columns, showAdditionalItems]);\n\n useEffect(() => {\n setSelectedItem([]);\n }, [filteredTableData]);\n\n const rowClickHandler = (\n row: RowContents,\n table: TableContents,\n ) => {\n table.setRowSelection(() => {\n const newSelection: RowSelectionState = {};\n newSelection[row.index] = true;\n return newSelection;\n });\n\n setSelectedItem(row.original.items);\n };\n\n const handleScopeChange = (value: string) => {\n if (value === 'book' || value === 'chapter' || value === 'verse') {\n onScopeChange(value);\n } else {\n throw new Error(`Invalid scope value: ${value}`);\n }\n };\n\n const handleStatusFilterChange = (value: string) => {\n if (value === 'all' || value === 'approved' || value === 'unapproved' || value === 'unknown') {\n setStatusFilter(value);\n } else {\n throw new Error(`Invalid status filter value: ${value}`);\n }\n };\n\n const occurrenceData: InventoryItemOccurrence[] = useMemo(() => {\n if (reducedTableData.length === 0 || selectedItem.length === 0) return [];\n const occurrence = reducedTableData.filter((tableEntry: InventoryTableData) => {\n return deepEqual(\n showAdditionalItems ? tableEntry.items : [tableEntry.items[0]],\n selectedItem,\n );\n });\n if (occurrence.length > 1) throw new Error('Selected item is not unique');\n return occurrence[0].occurrences;\n }, [selectedItem, showAdditionalItems, reducedTableData]);\n\n return (\n
    \n
    \n handleStatusFilterChange(value)}\n defaultValue={statusFilter}\n >\n \n \n \n \n {allItemsText}\n {approvedItemsText}\n {unapprovedItemsText}\n {unknownItemsText}\n \n \n \n {\n setTextFilter(event.target.value);\n }}\n />\n {additionalItemsLabels && (\n
    \n {\n setSelectedItem([]);\n setShowAdditionalItems(checked);\n }}\n />\n \n
    \n )}\n
    \n
    \n \n
    \n {occurrenceData.length > 0 && (\n
    \n \n
    \n )}\n
    \n );\n}\n","import { Input } from '@/components/shadcn-ui/input';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { useState } from 'react';\n\nexport type SearchBarProps = {\n className?: string;\n /**\n * Callback fired to handle the search query when button pressed\n *\n * @param searchQuery\n */\n onSearch: (searchQuery: string) => void;\n\n /** Optional string that appears in the search bar without a search string */\n placeholder?: string;\n\n /** Optional boolean to set the input base to full width */\n isFullWidth?: boolean;\n};\n\nexport default function SearchBar({\n className,\n onSearch,\n placeholder,\n isFullWidth,\n}: SearchBarProps) {\n const [searchQuery, setSearchQuery] = useState('');\n\n const handleInputChange = (searchString: string) => {\n setSearchQuery(searchString);\n onSearch(searchString);\n };\n\n return (\n handleInputChange(e.target.value)}\n />\n );\n}\n","// adapted from: https://github.com/shadcn-ui/ui/discussions/752\n\n'use client';\n\nimport { TabsContentProps, TabsListProps, TabsTriggerProps } from '@/components/shadcn-ui/tabs';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport * as TabsPrimitive from '@radix-ui/react-tabs';\nimport React from 'react';\n\nexport type VerticalTabsProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport type LeftTabsTriggerProps = TabsTriggerProps & {\n value: string;\n ref?: React.Ref;\n};\n\nexport const VerticalTabs = React.forwardRef<\n React.ElementRef,\n VerticalTabsProps\n>(({ className, ...props }, ref) => (\n \n));\n\nVerticalTabs.displayName = TabsPrimitive.List.displayName;\n\nexport const VerticalTabsList = React.forwardRef<\n React.ElementRef,\n TabsListProps\n>(({ className, ...props }, ref) => (\n \n));\nVerticalTabsList.displayName = TabsPrimitive.List.displayName;\n\nexport const VerticalTabsTrigger = React.forwardRef<\n React.ElementRef,\n LeftTabsTriggerProps\n>(({ className, ...props }, ref) => (\n \n));\n\nexport const VerticalTabsContent = React.forwardRef<\n React.ElementRef,\n TabsContentProps\n>(({ className, ...props }, ref) => (\n \n));\nVerticalTabsContent.displayName = TabsPrimitive.Content.displayName;\n","import SearchBar from '@/components/basics/search-bar.component';\nimport {\n VerticalTabs,\n VerticalTabsContent,\n VerticalTabsList,\n VerticalTabsTrigger,\n} from '@/components/basics/tabs-vertical';\nimport { ReactNode } from 'react';\n\nexport type TabKeyValueContent = {\n key: string;\n value: string;\n content: ReactNode;\n};\n\nexport type TabNavigationContentSearchProps = {\n /** List of values and keys for each tab this component should provide */\n tabList: TabKeyValueContent[];\n\n /** Handler to run when the value of the search bar changes */\n onSearch: (searchQuery: string) => void;\n\n /** Optional placeholder for the search bar */\n searchPlaceholder?: string;\n\n /** Optional title to include in the header */\n headerTitle?: string;\n\n /** Optional flag to make the search bar appear full width */\n isSearchBarFullWidth?: boolean;\n\n /** Text direction ltr or rtl */\n direction?: 'ltr' | 'rtl';\n};\n\nexport default function TabNavigationContentSearch({\n tabList,\n onSearch,\n searchPlaceholder,\n headerTitle,\n isSearchBarFullWidth = false,\n direction = 'ltr',\n}: TabNavigationContentSearchProps) {\n return (\n
    \n
    \n {headerTitle ?

    {headerTitle}

    : ''}\n \n
    \n \n \n {tabList.map((tab) => (\n \n {tab.value}\n \n ))}\n \n {tabList.map((tab) => (\n \n {tab.content}\n \n ))}\n \n
    \n );\n}\n","import React from 'react';\nimport * as SeparatorPrimitive from '@radix-ui/react-separator';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Separator = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, orientation = 'horizontal', decorative = true, ...props }, ref) => (\n \n));\nSeparator.displayName = SeparatorPrimitive.Root.displayName;\n\nexport { Separator };\n","'use client';\n\nimport * as React from 'react';\nimport * as SheetPrimitive from '@radix-ui/react-dialog';\nimport { cva, type VariantProps } from 'class-variance-authority';\nimport { X } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Sheet = SheetPrimitive.Root;\n\nconst SheetTrigger = SheetPrimitive.Trigger;\n\nconst SheetClose = SheetPrimitive.Close;\n\nconst SheetPortal = SheetPrimitive.Portal;\n\nconst SheetOverlay = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSheetOverlay.displayName = SheetPrimitive.Overlay.displayName;\n\nconst sheetVariants = cva(\n 'pr-twp tw-fixed tw-z-50 tw-gap-4 tw-bg-background tw-p-6 tw-shadow-lg tw-transition tw-ease-in-out data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-duration-300 data-[state=open]:tw-duration-500',\n {\n variants: {\n side: {\n top: 'tw-inset-x-0 tw-top-0 tw-border-b data-[state=closed]:tw-slide-out-to-top data-[state=open]:tw-slide-in-from-top',\n bottom:\n 'tw-inset-x-0 tw-bottom-0 tw-border-t data-[state=closed]:tw-slide-out-to-bottom data-[state=open]:tw-slide-in-from-bottom',\n left: 'tw-inset-y-0 tw-left-0 tw-h-full tw-w-3/4 tw-border-r data-[state=closed]:tw-slide-out-to-left data-[state=open]:tw-slide-in-from-left sm:tw-max-w-sm',\n right:\n 'tw-inset-y-0 tw-right-0 tw-h-full tw-w-3/4 tw- tw-border-l data-[state=closed]:tw-slide-out-to-right data-[state=open]:tw-slide-in-from-right sm:tw-max-w-sm',\n },\n },\n defaultVariants: {\n side: 'right',\n },\n },\n);\n\ninterface SheetContentProps\n extends React.ComponentPropsWithoutRef,\n VariantProps {}\n\nconst SheetContent = React.forwardRef<\n React.ElementRef,\n SheetContentProps\n>(({ side = 'right', className, children, ...props }, ref) => (\n \n \n \n {children}\n \n \n Close\n \n \n \n));\nSheetContent.displayName = SheetPrimitive.Content.displayName;\n\nfunction SheetHeader({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nSheetHeader.displayName = 'SheetHeader';\n\nfunction SheetFooter({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nSheetFooter.displayName = 'SheetFooter';\n\nconst SheetTitle = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSheetTitle.displayName = SheetPrimitive.Title.displayName;\n\nconst SheetDescription = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSheetDescription.displayName = SheetPrimitive.Description.displayName;\n\nexport {\n Sheet,\n SheetPortal,\n SheetOverlay,\n SheetTrigger,\n SheetClose,\n SheetContent,\n SheetHeader,\n SheetFooter,\n SheetTitle,\n SheetDescription,\n};\n","import React from 'react';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nfunction Skeleton({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\n\nexport { Skeleton };\n","import React from 'react';\nimport * as TooltipPrimitive from '@radix-ui/react-tooltip';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst TooltipProvider = TooltipPrimitive.Provider;\n\nconst Tooltip = TooltipPrimitive.Root;\n\nconst TooltipTrigger = TooltipPrimitive.Trigger;\n\nconst TooltipContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, sideOffset = 4, ...props }, ref) => (\n \n));\nTooltipContent.displayName = TooltipPrimitive.Content.displayName;\n\nexport { Tooltip, TooltipTrigger, TooltipContent, TooltipProvider };\n","import * as React from 'react';\n\nconst MOBILE_BREAKPOINT = 768;\n\nexport default function useIsMobile() {\n const [isMobile, setIsMobile] = React.useState(undefined);\n\n React.useEffect(() => {\n const mql = window.matchMedia(`(max-width: ${MOBILE_BREAKPOINT - 1}px)`);\n const onChange = () => {\n setIsMobile(window.innerWidth < MOBILE_BREAKPOINT);\n };\n mql.addEventListener('change', onChange);\n setIsMobile(window.innerWidth < MOBILE_BREAKPOINT);\n return () => mql.removeEventListener('change', onChange);\n }, []);\n\n return !!isMobile;\n}\n","import React from 'react';\nimport { Slot } from '@radix-ui/react-slot';\nimport { VariantProps, cva } from 'class-variance-authority';\nimport { PanelLeft } from 'lucide-react';\n\nimport { Button } from '@/components/shadcn-ui/button';\nimport { Input } from '@/components/shadcn-ui/input';\nimport { Separator } from '@/components/shadcn-ui/separator';\nimport { Sheet, SheetContent } from '@/components/shadcn-ui/sheet';\nimport { Skeleton } from '@/components/shadcn-ui/skeleton';\nimport {\n Tooltip,\n TooltipContent,\n TooltipProvider,\n TooltipTrigger,\n} from '@/components/shadcn-ui/tooltip';\nimport useIsMobile from '@/components/hooks/use-mobile';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst SIDEBAR_COOKIE_NAME = 'sidebar:state';\nconst SIDEBAR_COOKIE_MAX_AGE = 60 * 60 * 24 * 7;\nconst SIDEBAR_WIDTH = '16rem';\nconst SIDEBAR_WIDTH_MOBILE = '18rem';\nconst SIDEBAR_WIDTH_ICON = '3rem';\nconst SIDEBAR_KEYBOARD_SHORTCUT = 'b';\n\ntype SidebarContextProps = {\n state: 'expanded' | 'collapsed';\n open: boolean;\n setOpen: (open: boolean) => void;\n openMobile: boolean;\n setOpenMobile: (open: boolean) => void;\n isMobile: boolean;\n toggleSidebar: () => void;\n};\n\nconst SidebarContext = React.createContext(undefined);\n\nfunction useSidebar() {\n const context = React.useContext(SidebarContext);\n if (!context) {\n throw new Error('useSidebar must be used within a SidebarProvider.');\n }\n\n return context;\n}\n\nconst SidebarProvider = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & {\n defaultOpen?: boolean;\n open?: boolean;\n onOpenChange?: (open: boolean) => void;\n }\n>(\n (\n {\n defaultOpen = true,\n open: openProp,\n onOpenChange: setOpenProp,\n className,\n style,\n children,\n ...props\n },\n ref,\n ) => {\n const isMobile = useIsMobile();\n const [openMobile, setOpenMobile] = React.useState(false);\n\n // This is the internal state of the sidebar.\n // We use openProp and setOpenProp for control from outside the component.\n const [_open, _setOpen] = React.useState(defaultOpen);\n const isOpen = openProp ?? _open;\n const setOpen = React.useCallback(\n (value: boolean | ((value: boolean) => boolean)) => {\n const openState = typeof value === 'function' ? value(isOpen) : value;\n if (setOpenProp) {\n setOpenProp(openState);\n } else {\n _setOpen(openState);\n }\n\n // This sets the cookie to keep the sidebar state.\n document.cookie = `${SIDEBAR_COOKIE_NAME}=${openState}; path=/; max-age=${SIDEBAR_COOKIE_MAX_AGE}`;\n },\n [setOpenProp, isOpen],\n );\n\n // Helper to toggle the sidebar.\n const toggleSidebar = React.useCallback(() => {\n return isMobile ? setOpenMobile((open) => !open) : setOpen((open) => !open);\n }, [isMobile, setOpen, setOpenMobile]);\n\n // Adds a keyboard shortcut to toggle the sidebar.\n React.useEffect(() => {\n const handleKeyDown = (event: KeyboardEvent) => {\n if (event.key === SIDEBAR_KEYBOARD_SHORTCUT && (event.metaKey || event.ctrlKey)) {\n event.preventDefault();\n toggleSidebar();\n }\n };\n\n window.addEventListener('keydown', handleKeyDown);\n return () => window.removeEventListener('keydown', handleKeyDown);\n }, [toggleSidebar]);\n\n // We add a state so that we can do data-state=\"expanded\" or \"collapsed\".\n // This makes it easier to style the sidebar with Tailwind classes.\n const state = isOpen ? 'expanded' : 'collapsed';\n\n const contextValue = React.useMemo(\n () => ({\n state,\n open: isOpen,\n setOpen,\n isMobile,\n openMobile,\n setOpenMobile,\n toggleSidebar,\n }),\n [state, isOpen, setOpen, isMobile, openMobile, setOpenMobile, toggleSidebar],\n );\n\n return (\n \n \n \n {children}\n
    \n \n \n );\n },\n);\nSidebarProvider.displayName = 'SidebarProvider';\n\nconst Sidebar = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & {\n side?: 'left' | 'right';\n variant?: 'sidebar' | 'floating' | 'inset';\n collapsible?: 'offcanvas' | 'icon' | 'none';\n }\n>(\n (\n {\n side = 'left',\n variant = 'sidebar',\n collapsible = 'offcanvas',\n className,\n children,\n ...props\n },\n ref,\n ) => {\n const { isMobile, state, openMobile, setOpenMobile } = useSidebar();\n\n if (collapsible === 'none') {\n return (\n \n {children}\n
    \n );\n }\n\n if (isMobile) {\n return (\n \n button]:tw-hidden\"\n style={\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n {\n '--sidebar-width': SIDEBAR_WIDTH_MOBILE,\n } as React.CSSProperties\n }\n side={side}\n >\n
    {children}
    \n \n
    \n );\n }\n\n return (\n \n {/* This is what handles the sidebar gap on desktop */}\n \n \n \n {children}\n
    \n
    \n
    \n );\n },\n);\nSidebar.displayName = 'Sidebar';\n\nconst SidebarTrigger = React.forwardRef<\n React.ElementRef,\n React.ComponentProps\n>(({ className, onClick, ...props }, ref) => {\n const { toggleSidebar } = useSidebar();\n\n return (\n {\n onClick?.(event);\n toggleSidebar();\n }}\n {...props}\n >\n \n Toggle Sidebar\n \n );\n});\nSidebarTrigger.displayName = 'SidebarTrigger';\n\nconst SidebarRail = React.forwardRef>(\n ({ className, ...props }, ref) => {\n const { toggleSidebar } = useSidebar();\n\n return (\n \n );\n },\n);\nSidebarRail.displayName = 'SidebarRail';\n\nconst SidebarInset = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarInset.displayName = 'SidebarInset';\n\nconst SidebarInput = React.forwardRef<\n React.ElementRef,\n React.ComponentProps\n>(({ className, ...props }, ref) => {\n return (\n \n );\n});\nSidebarInput.displayName = 'SidebarInput';\n\nconst SidebarHeader = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarHeader.displayName = 'SidebarHeader';\n\nconst SidebarFooter = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarFooter.displayName = 'SidebarFooter';\n\nconst SidebarSeparator = React.forwardRef<\n React.ElementRef,\n React.ComponentProps\n>(({ className, ...props }, ref) => {\n return (\n \n );\n});\nSidebarSeparator.displayName = 'SidebarSeparator';\n\nconst SidebarContent = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarContent.displayName = 'SidebarContent';\n\nconst SidebarGroup = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarGroup.displayName = 'SidebarGroup';\n\nconst SidebarGroupLabel = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & { asChild?: boolean }\n>(({ className, asChild = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'div';\n\n return (\n svg]:tw-size-4 [&>svg]:tw-shrink-0',\n 'group-data-[collapsible=icon]:tw--mt-8 group-data-[collapsible=icon]:tw-opacity-0',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarGroupLabel.displayName = 'SidebarGroupLabel';\n\nconst SidebarGroupAction = React.forwardRef<\n HTMLButtonElement,\n React.ComponentProps<'button'> & { asChild?: boolean }\n>(({ className, asChild = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'button';\n\n return (\n svg]:tw-size-4 [&>svg]:tw-shrink-0',\n // Increases the hit area of the button on mobile.\n 'after:tw-absolute after:tw--inset-2 after:md:tw-hidden',\n 'group-data-[collapsible=icon]:tw-hidden',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarGroupAction.displayName = 'SidebarGroupAction';\n\nconst SidebarGroupContent = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarGroupContent.displayName = 'SidebarGroupContent';\n\nconst SidebarMenu = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenu.displayName = 'SidebarMenu';\n\nconst SidebarMenuItem = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenuItem.displayName = 'SidebarMenuItem';\n\nconst sidebarMenuButtonVariants = cva(\n // Removed data-[active=true]:tw-bg-sidebar-accent\n 'tw-peer/menu-button tw-flex tw-w-full tw-items-center tw-gap-2 tw-overflow-hidden tw-rounded-md tw-p-2 tw-text-left tw-text-sm tw-outline-none tw-ring-sidebar-ring tw-transition-[width,height,padding] hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground focus-visible:tw-ring-2 active:tw-bg-sidebar-accent active:tw-text-sidebar-accent-foreground disabled:tw-pointer-events-none disabled:tw-opacity-50 tw-group-has-[[data-sidebar=menu-action]]/menu-item:pr-8 aria-disabled:tw-pointer-events-none aria-disabled:tw-opacity-50 data-[active=true]:tw-font-medium data-[active=true]:tw-text-sidebar-accent-foreground data-[state=open]:hover:tw-bg-sidebar-accent data-[state=open]:hover:tw-text-sidebar-accent-foreground group-data-[collapsible=icon]:tw-!size-8 group-data-[collapsible=icon]:tw-!p-2 [&>span:last-child]:tw-truncate [&>svg]:tw-size-4 [&>svg]:tw-shrink-0',\n {\n variants: {\n variant: {\n default: 'hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground',\n outline:\n 'tw-bg-background tw-shadow-[0_0_0_1px_hsl(var(--sidebar-border))] hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground hover:tw-shadow-[0_0_0_1px_hsl(var(--sidebar-accent))]',\n },\n size: {\n default: 'tw-h-8 tw-text-sm',\n sm: 'tw-h-7 tw-text-xs',\n lg: 'tw-h-12 tw-text-sm group-data-[collapsible=icon]:tw-!p-0',\n },\n },\n defaultVariants: {\n variant: 'default',\n size: 'default',\n },\n },\n);\n\nconst SidebarMenuButton = React.forwardRef<\n HTMLButtonElement,\n React.ComponentProps<'button'> & {\n asChild?: boolean;\n isActive?: boolean;\n tooltip?: string | React.ComponentProps;\n } & VariantProps\n>(\n (\n {\n asChild = false,\n isActive = false,\n variant = 'default',\n size = 'default',\n tooltip,\n className,\n ...props\n },\n ref,\n ) => {\n const Comp = asChild ? Slot : 'button';\n const { isMobile, state } = useSidebar();\n\n const button = (\n \n );\n\n if (!tooltip) {\n return button;\n }\n\n if (typeof tooltip === 'string') {\n // eslint-disable-next-line no-param-reassign\n tooltip = {\n children: tooltip,\n };\n }\n\n return (\n \n {button}\n \n );\n },\n);\nSidebarMenuButton.displayName = 'SidebarMenuButton';\n\nconst SidebarMenuAction = React.forwardRef<\n HTMLButtonElement,\n React.ComponentProps<'button'> & {\n asChild?: boolean;\n showOnHover?: boolean;\n }\n>(({ className, asChild = false, showOnHover = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'button';\n\n return (\n svg]:tw-size-4 [&>svg]:tw-shrink-0',\n // Increases the hit area of the button on mobile.\n 'after:tw-absolute after:tw--inset-2 after:md:tw-hidden',\n 'tw-peer-data-[size=sm]/menu-button:top-1',\n 'tw-peer-data-[size=default]/menu-button:top-1.5',\n 'tw-peer-data-[size=lg]/menu-button:top-2.5',\n 'group-data-[collapsible=icon]:tw-hidden',\n showOnHover &&\n 'tw-group-focus-within/menu-item:opacity-100 tw-group-hover/menu-item:opacity-100 tw-peer-data-[active=true]/menu-button:text-sidebar-accent-foreground data-[state=open]:tw-opacity-100 md:tw-opacity-0',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarMenuAction.displayName = 'SidebarMenuAction';\n\nconst SidebarMenuBadge = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenuBadge.displayName = 'SidebarMenuBadge';\n\nconst SidebarMenuSkeleton = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & {\n showIcon?: boolean;\n }\n>(({ className, showIcon = false, ...props }, ref) => {\n // Random width between 50 to 90%.\n const width = React.useMemo(() => {\n return `${Math.floor(Math.random() * 40) + 50}%`;\n }, []);\n\n return (\n \n {showIcon && (\n \n )}\n \n
    \n );\n});\nSidebarMenuSkeleton.displayName = 'SidebarMenuSkeleton';\n\nconst SidebarMenuSub = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenuSub.displayName = 'SidebarMenuSub';\n\nconst SidebarMenuSubItem = React.forwardRef>(\n ({ ...props }, ref) =>
  • ,\n);\nSidebarMenuSubItem.displayName = 'SidebarMenuSubItem';\n\nconst SidebarMenuSubButton = React.forwardRef<\n HTMLAnchorElement,\n React.ComponentProps<'a'> & {\n asChild?: boolean;\n size?: 'sm' | 'md';\n isActive?: boolean;\n }\n>(({ asChild = false, size = 'md', isActive, className, ...props }, ref) => {\n const Comp = asChild ? Slot : 'a';\n\n return (\n span:last-child]:tw-truncate [&>svg]:tw-size-4 [&>svg]:tw-shrink-0 [&>svg]:tw-text-sidebar-accent-foreground',\n 'data-[active=true]:tw-bg-sidebar-accent data-[active=true]:tw-text-sidebar-accent-foreground',\n size === 'sm' && 'tw-text-xs',\n size === 'md' && 'tw-text-sm',\n 'group-data-[collapsible=icon]:tw-hidden',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarMenuSubButton.displayName = 'SidebarMenuSubButton';\n\nexport {\n Sidebar,\n SidebarContent,\n SidebarFooter,\n SidebarGroup,\n SidebarGroupAction,\n SidebarGroupContent,\n SidebarGroupLabel,\n SidebarHeader,\n SidebarInput,\n SidebarInset,\n SidebarMenu,\n SidebarMenuAction,\n SidebarMenuBadge,\n SidebarMenuButton,\n SidebarMenuItem,\n SidebarMenuSkeleton,\n SidebarMenuSub,\n SidebarMenuSubButton,\n SidebarMenuSubItem,\n SidebarProvider,\n SidebarRail,\n SidebarSeparator,\n SidebarTrigger,\n useSidebar,\n};\n","import ComboBox, { ComboBoxOption } from '@/components/basics/combo-box.component';\nimport {\n Sidebar,\n SidebarContent,\n SidebarGroup,\n SidebarGroupLabel,\n SidebarGroupContent,\n SidebarMenu,\n SidebarMenuItem,\n SidebarMenuButton,\n} from '@/components/shadcn-ui/sidebar';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { useCallback } from 'react';\n\nexport type SelectedSettingsSidebarItem = {\n label: string;\n projectId?: string;\n};\n\nexport type ProjectOptions = { projectId: string; projectName: string };\n\nexport type SettingsSidebarProps = {\n /** Optional id for testing */\n id?: string;\n\n /** Extension labels from contribution */\n extensionLabels: string[];\n\n /** Project names and ids */\n projectOptions: ProjectOptions[];\n\n /** Handler for selecting a sidebar item */\n handleSelectSidebarItem: (key: string, projectId?: string) => void;\n\n /** The current selected value in the sidebar */\n selectedSidebarItem: SelectedSettingsSidebarItem;\n};\n\nexport default function SettingsSidebar({\n id,\n extensionLabels,\n projectOptions,\n handleSelectSidebarItem,\n selectedSidebarItem,\n}: SettingsSidebarProps) {\n const handleSelectItem = useCallback(\n (item: string, projectId?: string) => {\n handleSelectSidebarItem(item, projectId);\n },\n [handleSelectSidebarItem],\n );\n\n const getProjectNameFromProjectId = useCallback(\n (projectId: string) => {\n const project = projectOptions.find((option) => option.projectId === projectId);\n return project ? project.projectName : projectId;\n },\n [projectOptions],\n );\n\n const getIsActive: (label: string) => boolean = useCallback(\n (label: string) => !selectedSidebarItem.projectId && label === selectedSidebarItem.label,\n [selectedSidebarItem],\n );\n\n return (\n \n \n \n Extensions\n \n \n {extensionLabels.map((label) => (\n \n handleSelectItem(label, undefined)}\n isActive={getIsActive(label)}\n >\n {label}\n \n \n ))}\n \n \n \n \n Projects\n \n option.projectId)}\n getOptionLabel={(projectId: ComboBoxOption) => {\n // This function expects a ComboBoxOption, but we know it is a string\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n return getProjectNameFromProjectId(projectId as string);\n }}\n buttonPlaceholder=\"Type or select project\"\n onChange={(projectId: string) => {\n const selectedProjectName = getProjectNameFromProjectId(projectId);\n handleSelectItem(selectedProjectName, projectId);\n }}\n value={selectedSidebarItem?.projectId ?? undefined}\n />\n \n \n \n \n );\n}\n","import { SidebarInset, SidebarProvider } from '@/components/shadcn-ui/sidebar';\nimport { PropsWithChildren } from 'react';\nimport SearchBar from '@/components/basics/search-bar.component';\nimport SettingsSidebar, { SettingsSidebarProps } from './settings-sidebar.component';\n\nexport type SettingsSidebarContentSearchProps = SettingsSidebarProps &\n PropsWithChildren & {\n /** Optional id for testing */\n id?: string;\n\n /** Text direction ltr or rtl */\n direction?: 'ltr' | 'rtl';\n\n /** Handler to run when the value of the search bar changes */\n onSearch: (searchQuery: string) => void;\n };\n\nexport default function SettingsSidebarContentSearch({\n id,\n direction = 'ltr',\n extensionLabels,\n projectOptions,\n children,\n handleSelectSidebarItem,\n selectedSidebarItem,\n onSearch,\n}: SettingsSidebarContentSearchProps) {\n return (\n
    \n
    \n \n
    \n \n \n {children}\n \n
    \n );\n}\n","import { Button } from '@/components/shadcn-ui/button';\nimport {\n Select,\n SelectContent,\n SelectGroup,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\nimport {\n Table,\n TableBody,\n TableCell,\n TableHead,\n TableHeader,\n TableRow,\n} from '@/components/shadcn-ui/table';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Canon } from '@sillsdev/scripture';\nimport {\n Cell,\n ColumnDef,\n flexRender,\n getCoreRowModel,\n getExpandedRowModel,\n getGroupedRowModel,\n getSortedRowModel,\n GroupingState,\n Row,\n RowSelectionState,\n SortingState,\n useReactTable,\n} from '@tanstack/react-table';\nimport '@/components/advanced/scripture-results-viewer/scripture-results-viewer.component.css';\nimport {\n compareScrRefs,\n formatScrRef,\n ScriptureSelection,\n scrRefToBBBCCCVVV,\n} from 'platform-bible-utils';\nimport { MouseEvent, useEffect, useMemo, useState } from 'react';\nimport { ChevronDown, ChevronLeft, ChevronRight } from 'lucide-react';\n\n/**\n * Information (e.g., a checking error or some other type of \"transient\" annotation) about something\n * noteworthy at a specific place in an instance of the Scriptures.\n */\nexport type ScriptureItemDetail = ScriptureSelection & {\n /**\n * Text of the error, note, etc. In the future, we might want to support something more than just\n * text so that a JSX element could be provided with a link or some other controls related to the\n * issue being reported.\n */\n detail: string;\n};\n\n/**\n * A uniquely identifiable source of results that can be displayed in the ScriptureResultsViewer.\n * Generally, the source will be a particular Scripture check, but there may be other types of\n * sources.\n */\nexport type ResultsSource = {\n /**\n * Uniquely identifies the source.\n *\n * @type {string}\n */\n id: string;\n\n /**\n * Name (potentially localized) of the source, suitable for display in the UI.\n *\n * @type {string}\n */\n displayName: string;\n};\n\nexport type ScriptureSrcItemDetail = ScriptureItemDetail & {\n /** Source/type of detail. Can be used for grouping. */\n source: ResultsSource;\n};\n\n/**\n * Represents a set of results keyed by Scripture reference. Generally, the source will be a\n * particular Scripture check, but this type also allows for other types of uniquely identifiable\n * sources.\n */\nexport type ResultsSet = {\n /**\n * The backing source associated with this set of results.\n *\n * @type {ResultsSource}\n */\n source: ResultsSource;\n\n /**\n * Array of Scripture item details (messages keyed by Scripture reference).\n *\n * @type {ScriptureItemDetail[]}\n */\n data: ScriptureItemDetail[];\n};\n\nconst scrBookColId = 'scrBook';\nconst scrRefColId = 'scrRef';\nconst typeColId = 'source';\nconst detailsColId = 'details';\n\nconst defaultScrRefColumnName = 'Scripture Reference';\nconst defaultScrBookGroupName = 'Scripture Book';\nconst defaultTypeColumnName = 'Type';\nconst defaultDetailsColumnName = 'Details';\n\nexport type ScriptureResultsViewerColumnInfo = {\n /** Optional header to display for the Reference column. Default value: 'Scripture Reference'. */\n scriptureReferenceColumnName?: string;\n\n /** Optional text to display to refer to the Scripture book group. Default value: 'Scripture Book'. */\n scriptureBookGroupName?: string;\n\n /** Optional header to display for the Type column. Default value: 'Type'. */\n typeColumnName?: string;\n\n /** Optional header to display for the Details column. Default value: 'Details' */\n detailsColumnName?: string;\n};\n\nexport type ScriptureResultsViewerProps = ScriptureResultsViewerColumnInfo & {\n /** Groups of ScriptureItemDetail objects from particular sources (e.g., Scripture checks) */\n sources: ResultsSet[];\n\n /** Flag indicating whether to display column headers. Default is false. */\n showColumnHeaders?: boolean;\n\n /** Flag indicating whether to display source column. Default is false. */\n showSourceColumn?: boolean;\n\n /** Callback function to notify when a row is selected */\n onRowSelected?: (selectedRow: ScriptureSrcItemDetail | undefined) => void;\n\n /** Text direction ltr or rtl */\n direction?: 'ltr' | 'rtl';\n};\n\nfunction getColumns(\n colInfo?: ScriptureResultsViewerColumnInfo,\n showSourceColumn?: boolean,\n): ColumnDef[] {\n const showSrcCol = showSourceColumn ?? false;\n return [\n {\n accessorFn: (row) =>\n `${Canon.bookNumberToId(row.start.bookNum)} ${row.start.chapterNum}:${row.start.verseNum}`,\n id: scrBookColId,\n header: colInfo?.scriptureReferenceColumnName ?? defaultScrRefColumnName,\n cell: (info) => {\n const row = info.row.original;\n if (info.row.getIsGrouped()) {\n return Canon.bookNumberToEnglishName(row.start.bookNum);\n }\n return info.row.groupingColumnId === scrBookColId ? formatScrRef(row.start) : undefined;\n },\n getGroupingValue: (row) => row.start.bookNum,\n sortingFn: (a, b) => {\n return compareScrRefs(a.original.start, b.original.start);\n },\n enableGrouping: true,\n },\n {\n accessorFn: (row) => formatScrRef(row.start),\n id: scrRefColId,\n header: undefined,\n cell: (info) => {\n const row = info.row.original;\n return info.row.getIsGrouped() ? undefined : formatScrRef(row.start);\n },\n sortingFn: (a, b) => {\n return compareScrRefs(a.original.start, b.original.start);\n },\n enableGrouping: false,\n },\n {\n accessorFn: (row) => row.source.displayName,\n id: typeColId,\n header: showSrcCol ? (colInfo?.typeColumnName ?? defaultTypeColumnName) : undefined,\n cell: (info) => (showSrcCol || info.row.getIsGrouped() ? info.getValue() : undefined),\n getGroupingValue: (row) => row.source.id,\n sortingFn: (a, b) =>\n a.original.source.displayName.localeCompare(b.original.source.displayName),\n enableGrouping: true,\n },\n {\n accessorFn: (row) => row.detail,\n id: detailsColId,\n header: colInfo?.detailsColumnName ?? defaultDetailsColumnName,\n cell: (info) => info.getValue(),\n enableGrouping: false,\n },\n ];\n}\n\nconst toRefOrRange = (scriptureSelection: ScriptureSelection) => {\n if (!('offset' in scriptureSelection.start))\n throw new Error('No offset available in range start');\n if (scriptureSelection.end && !('offset' in scriptureSelection.end))\n throw new Error('No offset available in range end');\n const { offset: offsetStart } = scriptureSelection.start;\n let offsetEnd: number = 0;\n if (scriptureSelection.end) ({ offset: offsetEnd } = scriptureSelection.end);\n if (\n !scriptureSelection.end ||\n compareScrRefs(scriptureSelection.start, scriptureSelection.end) === 0\n )\n return `${scrRefToBBBCCCVVV(scriptureSelection.start)}+${offsetStart}`;\n return `${scrRefToBBBCCCVVV(scriptureSelection.start)}+${offsetStart}-${scrRefToBBBCCCVVV(scriptureSelection.end)}+${offsetEnd}`;\n};\n\nconst getRowKey = (row: ScriptureSrcItemDetail) =>\n `${toRefOrRange({ start: row.start, end: row.end })} ${row.source.displayName} ${row.detail}`;\n\n/**\n * Component to display a combined list of detailed items from one or more sources, where the items\n * are keyed primarily by Scripture reference. This is particularly useful for displaying a list of\n * results from Scripture checks, but more generally could be used to display any \"results\" from any\n * source(s). The component allows for grouping by Scripture book, source, or both. By default, it\n * displays somewhat \"tree-like\" which allows it to be more horizontally compact and intuitive. But\n * it also has the option of displaying as a traditional table with column headings (with or without\n * the source column showing).\n */\nexport default function ScriptureResultsViewer({\n sources,\n showColumnHeaders = false,\n showSourceColumn = false,\n scriptureReferenceColumnName,\n scriptureBookGroupName,\n typeColumnName,\n detailsColumnName,\n onRowSelected,\n direction = 'ltr',\n}: ScriptureResultsViewerProps) {\n const [grouping, setGrouping] = useState([]);\n const [sorting, setSorting] = useState([{ id: scrBookColId, desc: false }]);\n const [rowSelection, setRowSelection] = useState({});\n\n const scriptureResults = useMemo(\n () =>\n sources.flatMap((source) => {\n return source.data.map((item) => ({\n ...item,\n source: source.source,\n }));\n }),\n [sources],\n );\n\n const columns = useMemo(\n () =>\n getColumns(\n {\n scriptureReferenceColumnName,\n typeColumnName,\n detailsColumnName,\n },\n showSourceColumn,\n ),\n [scriptureReferenceColumnName, typeColumnName, detailsColumnName, showSourceColumn],\n );\n\n useEffect(() => {\n // Ensure sorting is applied correctly when grouped by type\n if (grouping.includes(typeColId)) {\n setSorting([\n { id: typeColId, desc: false },\n { id: scrBookColId, desc: false },\n ]);\n } else {\n setSorting([{ id: scrBookColId, desc: false }]);\n }\n }, [grouping]);\n\n const table = useReactTable({\n data: scriptureResults,\n columns,\n state: {\n grouping,\n sorting,\n rowSelection,\n },\n onGroupingChange: setGrouping,\n onSortingChange: setSorting,\n onRowSelectionChange: setRowSelection,\n getExpandedRowModel: getExpandedRowModel(),\n getGroupedRowModel: getGroupedRowModel(),\n getCoreRowModel: getCoreRowModel(),\n getSortedRowModel: getSortedRowModel(),\n getRowId: getRowKey,\n autoResetExpanded: false,\n enableMultiRowSelection: false,\n enableSubRowSelection: false,\n });\n\n useEffect(() => {\n if (onRowSelected) {\n const selectedRows = table.getSelectedRowModel().rowsById;\n const keys = Object.keys(selectedRows);\n if (keys.length === 1) {\n const selectedRow = scriptureResults.find((row) => getRowKey(row) === keys[0]) || undefined;\n if (selectedRow) onRowSelected(selectedRow);\n }\n }\n }, [rowSelection, scriptureResults, onRowSelected, table]);\n\n // Define possible grouping options\n const scrBookGroupName = scriptureBookGroupName ?? defaultScrBookGroupName;\n const typeGroupName = typeColumnName ?? defaultTypeColumnName;\n\n const groupingOptions = [\n { label: 'No Grouping', value: [] },\n { label: `Group by ${scrBookGroupName}`, value: [scrBookColId] },\n { label: `Group by ${typeGroupName}`, value: [typeColId] },\n {\n label: `Group by ${scrBookGroupName} and ${typeGroupName}`,\n value: [scrBookColId, typeColId],\n },\n {\n label: `Group by ${typeGroupName} and ${scrBookGroupName}`,\n value: [typeColId, scrBookColId],\n },\n ];\n\n const handleSelectChange = (selectedGrouping: string) => {\n setGrouping(JSON.parse(selectedGrouping));\n };\n\n const handleRowClick = (row: Row, event: MouseEvent) => {\n if (!row.getIsGrouped() && !row.getIsSelected()) {\n row.getToggleSelectedHandler()(event);\n }\n };\n\n const getEvenOrOddBandingStyle = (row: Row, index: number) => {\n if (row.getIsGrouped()) return '';\n // UX has now said they don't think they want banding. I'm leaving in the code to\n // set even and odd styles, but there's nothing in the CSS to style them differently.\n // The \"even\" style used to also have tw-bg-neutral-300 (along with even) to create\n // a visual banding effect. That could be added back in if UX changes the decision.\n return cn('banded-row', index % 2 === 0 ? 'even' : 'odd');\n };\n\n const getIndent = (\n groupingState: GroupingState,\n row: Row,\n cell: Cell,\n ) => {\n if (groupingState?.length === 0 || row.depth < cell.column.getGroupedIndex()) return undefined;\n if (row.getIsGrouped()) {\n switch (row.depth) {\n case 1:\n return 'tw-ps-4';\n default:\n return undefined;\n }\n }\n switch (row.depth) {\n case 1:\n return 'tw-ps-8';\n case 2:\n return 'tw-ps-12';\n default:\n return undefined;\n }\n };\n\n return (\n
    \n {!showColumnHeaders && (\n {\n handleSelectChange(value);\n }}\n >\n \n \n \n \n \n {groupingOptions.map((option) => (\n \n {option.label}\n \n ))}\n \n \n \n )}\n \n {showColumnHeaders && (\n \n {table.getHeaderGroups().map((headerGroup) => (\n \n {headerGroup.headers\n .filter((h) => h.column.columnDef.header)\n .map((header) => (\n /* For sticky column headers to work, we probably need to change the default definition of the shadcn Table component. See https://github.com/shadcn-ui/ui/issues/1151 */\n \n {header.isPlaceholder ? undefined : (\n
    \n {header.column.getCanGroup() ? (\n \n {header.column.getIsGrouped() ? `🛑` : `👊 `}\n \n ) : undefined}{' '}\n {flexRender(header.column.columnDef.header, header.getContext())}\n
    \n )}\n
    \n ))}\n
    \n ))}\n
    \n )}\n \n {table.getRowModel().rows.map((row, rowIndex) => {\n return (\n handleRowClick(row, event)}\n >\n {row.getVisibleCells().map((cell) => {\n if (\n cell.getIsPlaceholder() ||\n (cell.column.columnDef.enableGrouping &&\n !cell.getIsGrouped() &&\n (cell.column.columnDef.id !== typeColId || !showSourceColumn))\n )\n return undefined;\n return (\n \n {(() => {\n if (cell.getIsGrouped()) {\n return (\n \n {row.getIsExpanded() && }\n {!row.getIsExpanded() &&\n (direction === 'ltr' ? : )}{' '}\n {flexRender(cell.column.columnDef.cell, cell.getContext())} (\n {row.subRows.length})\n \n );\n }\n\n // if (cell.getIsAggregated()) {\n // flexRender(\n // cell.column.columnDef.aggregatedCell ?? cell.column.columnDef.cell,\n // cell.getContext(),\n // );\n // }\n\n return flexRender(cell.column.columnDef.cell, cell.getContext());\n })()}\n \n );\n })}\n \n );\n })}\n \n
    \n
    \n );\n}\n","import {\n getLocalizeKeyForScrollGroupId,\n LanguageStrings,\n ScrollGroupId,\n} from 'platform-bible-utils';\nimport {\n Select,\n SelectContent,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\n\nconst DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS = {\n [getLocalizeKeyForScrollGroupId('undefined')]: 'Ø',\n [getLocalizeKeyForScrollGroupId(0)]: 'A',\n [getLocalizeKeyForScrollGroupId(1)]: 'B',\n [getLocalizeKeyForScrollGroupId(2)]: 'C',\n [getLocalizeKeyForScrollGroupId(3)]: 'D',\n [getLocalizeKeyForScrollGroupId(4)]: 'E',\n [getLocalizeKeyForScrollGroupId(5)]: 'F',\n [getLocalizeKeyForScrollGroupId(6)]: 'G',\n [getLocalizeKeyForScrollGroupId(7)]: 'H',\n [getLocalizeKeyForScrollGroupId(8)]: 'I',\n [getLocalizeKeyForScrollGroupId(9)]: 'J',\n [getLocalizeKeyForScrollGroupId(10)]: 'K',\n [getLocalizeKeyForScrollGroupId(11)]: 'L',\n [getLocalizeKeyForScrollGroupId(12)]: 'M',\n [getLocalizeKeyForScrollGroupId(13)]: 'N',\n [getLocalizeKeyForScrollGroupId(14)]: 'O',\n [getLocalizeKeyForScrollGroupId(15)]: 'P',\n [getLocalizeKeyForScrollGroupId(16)]: 'Q',\n [getLocalizeKeyForScrollGroupId(17)]: 'R',\n [getLocalizeKeyForScrollGroupId(18)]: 'S',\n [getLocalizeKeyForScrollGroupId(19)]: 'T',\n [getLocalizeKeyForScrollGroupId(20)]: 'U',\n [getLocalizeKeyForScrollGroupId(21)]: 'V',\n [getLocalizeKeyForScrollGroupId(22)]: 'W',\n [getLocalizeKeyForScrollGroupId(23)]: 'X',\n [getLocalizeKeyForScrollGroupId(24)]: 'Y',\n [getLocalizeKeyForScrollGroupId(25)]: 'Z',\n};\n\nexport type ScrollGroupSelectorProps = {\n /**\n * List of scroll group ids to show to the user. Either a {@link ScrollGroupId} or `undefined` for\n * no scroll group\n */\n availableScrollGroupIds: (ScrollGroupId | undefined)[];\n /** Currently selected scroll group id. `undefined` for no scroll group */\n scrollGroupId: ScrollGroupId | undefined;\n /** Callback function run when the user tries to change the scroll group id */\n onChangeScrollGroupId: (newScrollGroupId: ScrollGroupId | undefined) => void;\n /**\n * Localized strings to use for displaying scroll group ids. Must be an object whose keys are\n * `getLocalizeKeyForScrollGroupId(scrollGroupId)` for all scroll group ids (and `undefined` if\n * included) in {@link ScrollGroupSelectorProps.availableScrollGroupIds} and whose values are the\n * localized strings to use for those scroll group ids.\n *\n * Defaults to English localizations of English alphabet for scroll groups 0-25 (e.g. 0 is A) and\n * Ø for `undefined`. Will fill in any that are not provided with these English localizations.\n * Also, if any values match the keys, the English localization will be used. This is useful in\n * case you want to pass in a temporary version of the localized strings while your localized\n * strings load.\n *\n * @example\n *\n * ```typescript\n * const myScrollGroupIdLocalizedStrings = {\n * [getLocalizeKeyForScrollGroupId('undefined')]: 'Ø',\n * [getLocalizeKeyForScrollGroupId(0)]: 'A',\n * [getLocalizeKeyForScrollGroupId(1)]: 'B',\n * [getLocalizeKeyForScrollGroupId(2)]: 'C',\n * [getLocalizeKeyForScrollGroupId(3)]: 'D',\n * [getLocalizeKeyForScrollGroupId(4)]: 'E',\n * };\n * ```\n *\n * @example\n *\n * ```tsx\n * const availableScrollGroupIds = [undefined, 0, 1, 2, 3, 4];\n *\n * const localizeKeys = getLocalizeKeysForScrollGroupIds();\n *\n * const [localizedStrings] = useLocalizedStrings(localizeKeys);\n *\n * ...\n *\n * \n * ```\n */\n localizedStrings?: LanguageStrings;\n};\n\n/** Selector component for choosing a scroll group */\nexport default function ScrollGroupSelector({\n availableScrollGroupIds,\n scrollGroupId,\n onChangeScrollGroupId,\n localizedStrings = {},\n}: ScrollGroupSelectorProps) {\n const localizedStringsDefaulted = {\n ...DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS,\n ...Object.fromEntries(\n Object.entries(localizedStrings).map(\n ([localizedStringKey, localizedStringValue]: [string, string]) => [\n localizedStringKey,\n localizedStringKey === localizedStringValue &&\n localizedStringKey in DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS\n ? DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS[localizedStringKey]\n : localizedStringValue,\n ],\n ),\n ),\n };\n return (\n \n onChangeScrollGroupId(\n newScrollGroupString === 'undefined' ? undefined : parseInt(newScrollGroupString, 10),\n )\n }\n >\n \n \n \n \n {availableScrollGroupIds.map((scrollGroupOptionId) => (\n \n {localizedStringsDefaulted[getLocalizeKeyForScrollGroupId(scrollGroupOptionId)]}\n \n ))}\n \n \n );\n}\n","import { PropsWithChildren } from 'react';\nimport { Separator } from '@/components/shadcn-ui/separator';\n\n/** Props for the SettingsList component, currently just children */\ntype SettingsListProps = PropsWithChildren;\n\n/**\n * SettingsList component is a wrapper for list items. Rendered with a formatted div\n *\n * @param children To populate the list with\n * @returns Formatted div encompassing the children\n */\nexport function SettingsList({ children }: SettingsListProps) {\n return
    {children}
    ;\n}\n\n/** Props for SettingsListItem component */\ntype SettingsListItemProps = PropsWithChildren & {\n /** Primary text of the list item */\n primary: string;\n\n /** Optional text of the list item */\n secondary?: string | undefined;\n\n /** Optional boolean to display a message if the children aren't loaded yet. Defaults to false */\n isLoading?: boolean;\n\n /** Optional message to display if isLoading */\n loadingMessage?: string;\n};\n\n/**\n * SettingsListItem component is a common list item. Rendered with a formatted div\n *\n * @param primary Primary text of the list item\n * @param secondary Optional secondary text of the list item\n * @param isLoading Optional, to display a message if the action component isn't generated yet,\n * defaults to false\n * @param children The action component(s) to provide for this item\n * @param loadingMessage Optional, message to display if isLoading\n * @returns Formatted div encompassing the list item content\n */\nexport function SettingsListItem({\n primary,\n secondary,\n children,\n isLoading = false,\n loadingMessage,\n}: SettingsListItemProps) {\n return (\n
    \n
    \n

    {primary}

    \n

    \n {secondary}\n

    \n
    \n\n {isLoading ? (\n

    {loadingMessage}

    \n ) : (\n
    {children}
    \n )}\n
    \n );\n}\n\n/** Props for SettingsListHeader component */\ntype SettingsListHeaderProps = {\n /** The primary text of the list header */\n primary: string;\n\n /** Optional secondary text of the list header */\n secondary?: string | undefined;\n\n /** Optional boolean to include a separator underneath the secondary text. Defaults to false */\n includeSeparator?: boolean;\n};\n\n/**\n * SettingsListHeader component displays text above the list\n *\n * @param primary The primary text of the list header\n * @param secondary Optional secondary text of the list header\n * @param includeSeparator Optional boolean to include a separator underneath the secondary text.\n * Defaults to false\n * @returns Formatted div with list header content\n */\nexport function SettingsListHeader({\n primary,\n secondary,\n includeSeparator = false,\n}: SettingsListHeaderProps) {\n return (\n
    \n
    \n

    {primary}

    \n

    {secondary}

    \n
    \n {includeSeparator ? : ''}\n
    \n );\n}\n","import React from 'react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Card = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nCard.displayName = 'Card';\n\nconst CardHeader = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nCardHeader.displayName = 'CardHeader';\n\nconst CardTitle = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n {/* added because of https://github.com/jsx-eslint/eslint-plugin-jsx-a11y/blob/main/docs/rules/heading-has-content.md */}\n {props.children}\n \n ),\n);\nCardTitle.displayName = 'CardTitle';\n\nconst CardDescription = React.forwardRef<\n HTMLParagraphElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n

    \n));\nCardDescription.displayName = 'CardDescription';\n\nconst CardContent = React.forwardRef>(\n ({ className, ...props }, ref) => (\n

    \n ),\n);\nCardContent.displayName = 'CardContent';\n\nconst CardFooter = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nCardFooter.displayName = 'CardFooter';\n\nexport { Card, CardHeader, CardFooter, CardTitle, CardDescription, CardContent };\n","import {\n Card,\n CardDescription,\n CardHeader,\n CardTitle,\n CardContent,\n} from '@/components/shadcn-ui/card';\nimport { PropsWithChildren } from 'react';\n\ntype SettingsCardProps = PropsWithChildren & {\n /** Optional id for testing */\n id?: string;\n\n /** Label of the settings group */\n settingsGroupLabel: string;\n\n /** Optional description of the settings group */\n settingsGroupDescription?: string;\n};\n\nexport default function SettingsCard({\n id,\n settingsGroupLabel,\n settingsGroupDescription,\n children,\n}: SettingsCardProps) {\n return (\n \n \n {settingsGroupLabel}\n {settingsGroupDescription && {settingsGroupDescription}}\n \n {children}\n \n );\n}\n","import Checkbox from '@/components/shadcn-ui/checkbox';\nimport { Label } from '@/components/shadcn-ui/label';\n\nexport type ChecklistProps = {\n /** Optional string representing the id attribute of the Checklist */\n id?: string;\n /** Optional string representing CSS class name(s) for styling */\n className?: string;\n /** Array of strings representing the checkable items */\n listItems: string[];\n /** Array of strings representing the checked items */\n selectedListItems: string[];\n /**\n * Function that is called when a checkbox item is selected or deselected\n *\n * @param item The string description for this item\n * @param selected True if selected, false if not selected\n */\n handleSelectListItem: (item: string, selected: boolean) => void;\n\n /**\n * Optional function creates a label for a provided checkable item\n *\n * @param item The item for which a label is to be created\n * @returns A string representing the label text for the checkbox associated with that item\n */\n createLabel?: (item: string) => string;\n};\n\n/** Renders a list of checkboxes. Each checkbox corresponds to an item from the `listItems` array. */\nexport default function Checklist({\n id,\n className,\n listItems,\n selectedListItems,\n handleSelectListItem,\n createLabel,\n}: ChecklistProps) {\n return (\n
    \n {listItems.map((item) => (\n
    \n handleSelectListItem(item, value)}\n />\n \n
    \n ))}\n
    \n );\n}\n","function _interopRequireDefault(obj) {\n return obj && obj.__esModule ? obj : {\n \"default\": obj\n };\n}\nmodule.exports = _interopRequireDefault, module.exports.__esModule = true, module.exports[\"default\"] = module.exports;","export default function chainPropTypes(propType1, propType2) {\n if (process.env.NODE_ENV === 'production') {\n return () => null;\n }\n return function validate(...args) {\n return propType1(...args) || propType2(...args);\n };\n}","export default function _extends() {\n _extends = Object.assign ? Object.assign.bind() : function (target) {\n for (var i = 1; i < arguments.length; i++) {\n var source = arguments[i];\n for (var key in source) {\n if (Object.prototype.hasOwnProperty.call(source, key)) {\n target[key] = source[key];\n }\n }\n }\n return target;\n };\n return _extends.apply(this, arguments);\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\n// https://github.com/sindresorhus/is-plain-obj/blob/main/index.js\nexport function isPlainObject(item) {\n if (typeof item !== 'object' || item === null) {\n return false;\n }\n const prototype = Object.getPrototypeOf(item);\n return (prototype === null || prototype === Object.prototype || Object.getPrototypeOf(prototype) === null) && !(Symbol.toStringTag in item) && !(Symbol.iterator in item);\n}\nfunction deepClone(source) {\n if (!isPlainObject(source)) {\n return source;\n }\n const output = {};\n Object.keys(source).forEach(key => {\n output[key] = deepClone(source[key]);\n });\n return output;\n}\nexport default function deepmerge(target, source, options = {\n clone: true\n}) {\n const output = options.clone ? _extends({}, target) : target;\n if (isPlainObject(target) && isPlainObject(source)) {\n Object.keys(source).forEach(key => {\n // Avoid prototype pollution\n if (key === '__proto__') {\n return;\n }\n if (isPlainObject(source[key]) && key in target && isPlainObject(target[key])) {\n // Since `output` is a clone of `target` and we have narrowed `target` in this block we can cast to the same type.\n output[key] = deepmerge(target[key], source[key], options);\n } else if (options.clone) {\n output[key] = isPlainObject(source[key]) ? deepClone(source[key]) : source[key];\n } else {\n output[key] = source[key];\n }\n });\n }\n return output;\n}","/** @license React v16.13.1\n * react-is.production.min.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';var b=\"function\"===typeof Symbol&&Symbol.for,c=b?Symbol.for(\"react.element\"):60103,d=b?Symbol.for(\"react.portal\"):60106,e=b?Symbol.for(\"react.fragment\"):60107,f=b?Symbol.for(\"react.strict_mode\"):60108,g=b?Symbol.for(\"react.profiler\"):60114,h=b?Symbol.for(\"react.provider\"):60109,k=b?Symbol.for(\"react.context\"):60110,l=b?Symbol.for(\"react.async_mode\"):60111,m=b?Symbol.for(\"react.concurrent_mode\"):60111,n=b?Symbol.for(\"react.forward_ref\"):60112,p=b?Symbol.for(\"react.suspense\"):60113,q=b?\nSymbol.for(\"react.suspense_list\"):60120,r=b?Symbol.for(\"react.memo\"):60115,t=b?Symbol.for(\"react.lazy\"):60116,v=b?Symbol.for(\"react.block\"):60121,w=b?Symbol.for(\"react.fundamental\"):60117,x=b?Symbol.for(\"react.responder\"):60118,y=b?Symbol.for(\"react.scope\"):60119;\nfunction z(a){if(\"object\"===typeof a&&null!==a){var u=a.$$typeof;switch(u){case c:switch(a=a.type,a){case l:case m:case e:case g:case f:case p:return a;default:switch(a=a&&a.$$typeof,a){case k:case n:case t:case r:case h:return a;default:return u}}case d:return u}}}function A(a){return z(a)===m}exports.AsyncMode=l;exports.ConcurrentMode=m;exports.ContextConsumer=k;exports.ContextProvider=h;exports.Element=c;exports.ForwardRef=n;exports.Fragment=e;exports.Lazy=t;exports.Memo=r;exports.Portal=d;\nexports.Profiler=g;exports.StrictMode=f;exports.Suspense=p;exports.isAsyncMode=function(a){return A(a)||z(a)===l};exports.isConcurrentMode=A;exports.isContextConsumer=function(a){return z(a)===k};exports.isContextProvider=function(a){return z(a)===h};exports.isElement=function(a){return\"object\"===typeof a&&null!==a&&a.$$typeof===c};exports.isForwardRef=function(a){return z(a)===n};exports.isFragment=function(a){return z(a)===e};exports.isLazy=function(a){return z(a)===t};\nexports.isMemo=function(a){return z(a)===r};exports.isPortal=function(a){return z(a)===d};exports.isProfiler=function(a){return z(a)===g};exports.isStrictMode=function(a){return z(a)===f};exports.isSuspense=function(a){return z(a)===p};\nexports.isValidElementType=function(a){return\"string\"===typeof a||\"function\"===typeof a||a===e||a===m||a===g||a===f||a===p||a===q||\"object\"===typeof a&&null!==a&&(a.$$typeof===t||a.$$typeof===r||a.$$typeof===h||a.$$typeof===k||a.$$typeof===n||a.$$typeof===w||a.$$typeof===x||a.$$typeof===y||a.$$typeof===v)};exports.typeOf=z;\n","/** @license React v16.13.1\n * react-is.development.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\n\n\nif (process.env.NODE_ENV !== \"production\") {\n (function() {\n'use strict';\n\n// The Symbol used to tag the ReactElement-like types. If there is no native Symbol\n// nor polyfill, then a plain number is used for performance.\nvar hasSymbol = typeof Symbol === 'function' && Symbol.for;\nvar REACT_ELEMENT_TYPE = hasSymbol ? Symbol.for('react.element') : 0xeac7;\nvar REACT_PORTAL_TYPE = hasSymbol ? Symbol.for('react.portal') : 0xeaca;\nvar REACT_FRAGMENT_TYPE = hasSymbol ? Symbol.for('react.fragment') : 0xeacb;\nvar REACT_STRICT_MODE_TYPE = hasSymbol ? Symbol.for('react.strict_mode') : 0xeacc;\nvar REACT_PROFILER_TYPE = hasSymbol ? Symbol.for('react.profiler') : 0xead2;\nvar REACT_PROVIDER_TYPE = hasSymbol ? Symbol.for('react.provider') : 0xeacd;\nvar REACT_CONTEXT_TYPE = hasSymbol ? Symbol.for('react.context') : 0xeace; // TODO: We don't use AsyncMode or ConcurrentMode anymore. They were temporary\n// (unstable) APIs that have been removed. Can we remove the symbols?\n\nvar REACT_ASYNC_MODE_TYPE = hasSymbol ? Symbol.for('react.async_mode') : 0xeacf;\nvar REACT_CONCURRENT_MODE_TYPE = hasSymbol ? Symbol.for('react.concurrent_mode') : 0xeacf;\nvar REACT_FORWARD_REF_TYPE = hasSymbol ? Symbol.for('react.forward_ref') : 0xead0;\nvar REACT_SUSPENSE_TYPE = hasSymbol ? Symbol.for('react.suspense') : 0xead1;\nvar REACT_SUSPENSE_LIST_TYPE = hasSymbol ? Symbol.for('react.suspense_list') : 0xead8;\nvar REACT_MEMO_TYPE = hasSymbol ? Symbol.for('react.memo') : 0xead3;\nvar REACT_LAZY_TYPE = hasSymbol ? Symbol.for('react.lazy') : 0xead4;\nvar REACT_BLOCK_TYPE = hasSymbol ? Symbol.for('react.block') : 0xead9;\nvar REACT_FUNDAMENTAL_TYPE = hasSymbol ? Symbol.for('react.fundamental') : 0xead5;\nvar REACT_RESPONDER_TYPE = hasSymbol ? Symbol.for('react.responder') : 0xead6;\nvar REACT_SCOPE_TYPE = hasSymbol ? Symbol.for('react.scope') : 0xead7;\n\nfunction isValidElementType(type) {\n return typeof type === 'string' || typeof type === 'function' || // Note: its typeof might be other than 'symbol' or 'number' if it's a polyfill.\n type === REACT_FRAGMENT_TYPE || type === REACT_CONCURRENT_MODE_TYPE || type === REACT_PROFILER_TYPE || type === REACT_STRICT_MODE_TYPE || type === REACT_SUSPENSE_TYPE || type === REACT_SUSPENSE_LIST_TYPE || typeof type === 'object' && type !== null && (type.$$typeof === REACT_LAZY_TYPE || type.$$typeof === REACT_MEMO_TYPE || type.$$typeof === REACT_PROVIDER_TYPE || type.$$typeof === REACT_CONTEXT_TYPE || type.$$typeof === REACT_FORWARD_REF_TYPE || type.$$typeof === REACT_FUNDAMENTAL_TYPE || type.$$typeof === REACT_RESPONDER_TYPE || type.$$typeof === REACT_SCOPE_TYPE || type.$$typeof === REACT_BLOCK_TYPE);\n}\n\nfunction typeOf(object) {\n if (typeof object === 'object' && object !== null) {\n var $$typeof = object.$$typeof;\n\n switch ($$typeof) {\n case REACT_ELEMENT_TYPE:\n var type = object.type;\n\n switch (type) {\n case REACT_ASYNC_MODE_TYPE:\n case REACT_CONCURRENT_MODE_TYPE:\n case REACT_FRAGMENT_TYPE:\n case REACT_PROFILER_TYPE:\n case REACT_STRICT_MODE_TYPE:\n case REACT_SUSPENSE_TYPE:\n return type;\n\n default:\n var $$typeofType = type && type.$$typeof;\n\n switch ($$typeofType) {\n case REACT_CONTEXT_TYPE:\n case REACT_FORWARD_REF_TYPE:\n case REACT_LAZY_TYPE:\n case REACT_MEMO_TYPE:\n case REACT_PROVIDER_TYPE:\n return $$typeofType;\n\n default:\n return $$typeof;\n }\n\n }\n\n case REACT_PORTAL_TYPE:\n return $$typeof;\n }\n }\n\n return undefined;\n} // AsyncMode is deprecated along with isAsyncMode\n\nvar AsyncMode = REACT_ASYNC_MODE_TYPE;\nvar ConcurrentMode = REACT_CONCURRENT_MODE_TYPE;\nvar ContextConsumer = REACT_CONTEXT_TYPE;\nvar ContextProvider = REACT_PROVIDER_TYPE;\nvar Element = REACT_ELEMENT_TYPE;\nvar ForwardRef = REACT_FORWARD_REF_TYPE;\nvar Fragment = REACT_FRAGMENT_TYPE;\nvar Lazy = REACT_LAZY_TYPE;\nvar Memo = REACT_MEMO_TYPE;\nvar Portal = REACT_PORTAL_TYPE;\nvar Profiler = REACT_PROFILER_TYPE;\nvar StrictMode = REACT_STRICT_MODE_TYPE;\nvar Suspense = REACT_SUSPENSE_TYPE;\nvar hasWarnedAboutDeprecatedIsAsyncMode = false; // AsyncMode should be deprecated\n\nfunction isAsyncMode(object) {\n {\n if (!hasWarnedAboutDeprecatedIsAsyncMode) {\n hasWarnedAboutDeprecatedIsAsyncMode = true; // Using console['warn'] to evade Babel and ESLint\n\n console['warn']('The ReactIs.isAsyncMode() alias has been deprecated, ' + 'and will be removed in React 17+. Update your code to use ' + 'ReactIs.isConcurrentMode() instead. It has the exact same API.');\n }\n }\n\n return isConcurrentMode(object) || typeOf(object) === REACT_ASYNC_MODE_TYPE;\n}\nfunction isConcurrentMode(object) {\n return typeOf(object) === REACT_CONCURRENT_MODE_TYPE;\n}\nfunction isContextConsumer(object) {\n return typeOf(object) === REACT_CONTEXT_TYPE;\n}\nfunction isContextProvider(object) {\n return typeOf(object) === REACT_PROVIDER_TYPE;\n}\nfunction isElement(object) {\n return typeof object === 'object' && object !== null && object.$$typeof === REACT_ELEMENT_TYPE;\n}\nfunction isForwardRef(object) {\n return typeOf(object) === REACT_FORWARD_REF_TYPE;\n}\nfunction isFragment(object) {\n return typeOf(object) === REACT_FRAGMENT_TYPE;\n}\nfunction isLazy(object) {\n return typeOf(object) === REACT_LAZY_TYPE;\n}\nfunction isMemo(object) {\n return typeOf(object) === REACT_MEMO_TYPE;\n}\nfunction isPortal(object) {\n return typeOf(object) === REACT_PORTAL_TYPE;\n}\nfunction isProfiler(object) {\n return typeOf(object) === REACT_PROFILER_TYPE;\n}\nfunction isStrictMode(object) {\n return typeOf(object) === REACT_STRICT_MODE_TYPE;\n}\nfunction isSuspense(object) {\n return typeOf(object) === REACT_SUSPENSE_TYPE;\n}\n\nexports.AsyncMode = AsyncMode;\nexports.ConcurrentMode = ConcurrentMode;\nexports.ContextConsumer = ContextConsumer;\nexports.ContextProvider = ContextProvider;\nexports.Element = Element;\nexports.ForwardRef = ForwardRef;\nexports.Fragment = Fragment;\nexports.Lazy = Lazy;\nexports.Memo = Memo;\nexports.Portal = Portal;\nexports.Profiler = Profiler;\nexports.StrictMode = StrictMode;\nexports.Suspense = Suspense;\nexports.isAsyncMode = isAsyncMode;\nexports.isConcurrentMode = isConcurrentMode;\nexports.isContextConsumer = isContextConsumer;\nexports.isContextProvider = isContextProvider;\nexports.isElement = isElement;\nexports.isForwardRef = isForwardRef;\nexports.isFragment = isFragment;\nexports.isLazy = isLazy;\nexports.isMemo = isMemo;\nexports.isPortal = isPortal;\nexports.isProfiler = isProfiler;\nexports.isStrictMode = isStrictMode;\nexports.isSuspense = isSuspense;\nexports.isValidElementType = isValidElementType;\nexports.typeOf = typeOf;\n })();\n}\n","'use strict';\n\nif (process.env.NODE_ENV === 'production') {\n module.exports = require('./cjs/react-is.production.min.js');\n} else {\n module.exports = require('./cjs/react-is.development.js');\n}\n","/*\nobject-assign\n(c) Sindre Sorhus\n@license MIT\n*/\n\n'use strict';\n/* eslint-disable no-unused-vars */\nvar getOwnPropertySymbols = Object.getOwnPropertySymbols;\nvar hasOwnProperty = Object.prototype.hasOwnProperty;\nvar propIsEnumerable = Object.prototype.propertyIsEnumerable;\n\nfunction toObject(val) {\n\tif (val === null || val === undefined) {\n\t\tthrow new TypeError('Object.assign cannot be called with null or undefined');\n\t}\n\n\treturn Object(val);\n}\n\nfunction shouldUseNative() {\n\ttry {\n\t\tif (!Object.assign) {\n\t\t\treturn false;\n\t\t}\n\n\t\t// Detect buggy property enumeration order in older V8 versions.\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=4118\n\t\tvar test1 = new String('abc'); // eslint-disable-line no-new-wrappers\n\t\ttest1[5] = 'de';\n\t\tif (Object.getOwnPropertyNames(test1)[0] === '5') {\n\t\t\treturn false;\n\t\t}\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=3056\n\t\tvar test2 = {};\n\t\tfor (var i = 0; i < 10; i++) {\n\t\t\ttest2['_' + String.fromCharCode(i)] = i;\n\t\t}\n\t\tvar order2 = Object.getOwnPropertyNames(test2).map(function (n) {\n\t\t\treturn test2[n];\n\t\t});\n\t\tif (order2.join('') !== '0123456789') {\n\t\t\treturn false;\n\t\t}\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=3056\n\t\tvar test3 = {};\n\t\t'abcdefghijklmnopqrst'.split('').forEach(function (letter) {\n\t\t\ttest3[letter] = letter;\n\t\t});\n\t\tif (Object.keys(Object.assign({}, test3)).join('') !==\n\t\t\t\t'abcdefghijklmnopqrst') {\n\t\t\treturn false;\n\t\t}\n\n\t\treturn true;\n\t} catch (err) {\n\t\t// We don't expect any of the above to throw, but better to be safe.\n\t\treturn false;\n\t}\n}\n\nmodule.exports = shouldUseNative() ? Object.assign : function (target, source) {\n\tvar from;\n\tvar to = toObject(target);\n\tvar symbols;\n\n\tfor (var s = 1; s < arguments.length; s++) {\n\t\tfrom = Object(arguments[s]);\n\n\t\tfor (var key in from) {\n\t\t\tif (hasOwnProperty.call(from, key)) {\n\t\t\t\tto[key] = from[key];\n\t\t\t}\n\t\t}\n\n\t\tif (getOwnPropertySymbols) {\n\t\t\tsymbols = getOwnPropertySymbols(from);\n\t\t\tfor (var i = 0; i < symbols.length; i++) {\n\t\t\t\tif (propIsEnumerable.call(from, symbols[i])) {\n\t\t\t\t\tto[symbols[i]] = from[symbols[i]];\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\n\treturn to;\n};\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar ReactPropTypesSecret = 'SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED';\n\nmodule.exports = ReactPropTypesSecret;\n","module.exports = Function.call.bind(Object.prototype.hasOwnProperty);\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar printWarning = function() {};\n\nif (process.env.NODE_ENV !== 'production') {\n var ReactPropTypesSecret = require('./lib/ReactPropTypesSecret');\n var loggedTypeFailures = {};\n var has = require('./lib/has');\n\n printWarning = function(text) {\n var message = 'Warning: ' + text;\n if (typeof console !== 'undefined') {\n console.error(message);\n }\n try {\n // --- Welcome to debugging React ---\n // This error was thrown as a convenience so that you can use this stack\n // to find the callsite that caused this warning to fire.\n throw new Error(message);\n } catch (x) { /**/ }\n };\n}\n\n/**\n * Assert that the values match with the type specs.\n * Error messages are memorized and will only be shown once.\n *\n * @param {object} typeSpecs Map of name to a ReactPropType\n * @param {object} values Runtime values that need to be type-checked\n * @param {string} location e.g. \"prop\", \"context\", \"child context\"\n * @param {string} componentName Name of the component for error messages.\n * @param {?Function} getStack Returns the component stack.\n * @private\n */\nfunction checkPropTypes(typeSpecs, values, location, componentName, getStack) {\n if (process.env.NODE_ENV !== 'production') {\n for (var typeSpecName in typeSpecs) {\n if (has(typeSpecs, typeSpecName)) {\n var error;\n // Prop type validation may throw. In case they do, we don't want to\n // fail the render phase where it didn't fail before. So we log it.\n // After these have been cleaned up, we'll let them throw.\n try {\n // This is intentionally an invariant that gets caught. It's the same\n // behavior as without this statement except with a better message.\n if (typeof typeSpecs[typeSpecName] !== 'function') {\n var err = Error(\n (componentName || 'React class') + ': ' + location + ' type `' + typeSpecName + '` is invalid; ' +\n 'it must be a function, usually from the `prop-types` package, but received `' + typeof typeSpecs[typeSpecName] + '`.' +\n 'This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.'\n );\n err.name = 'Invariant Violation';\n throw err;\n }\n error = typeSpecs[typeSpecName](values, typeSpecName, componentName, location, null, ReactPropTypesSecret);\n } catch (ex) {\n error = ex;\n }\n if (error && !(error instanceof Error)) {\n printWarning(\n (componentName || 'React class') + ': type specification of ' +\n location + ' `' + typeSpecName + '` is invalid; the type checker ' +\n 'function must return `null` or an `Error` but returned a ' + typeof error + '. ' +\n 'You may have forgotten to pass an argument to the type checker ' +\n 'creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and ' +\n 'shape all require an argument).'\n );\n }\n if (error instanceof Error && !(error.message in loggedTypeFailures)) {\n // Only monitor this failure once because there tends to be a lot of the\n // same error.\n loggedTypeFailures[error.message] = true;\n\n var stack = getStack ? getStack() : '';\n\n printWarning(\n 'Failed ' + location + ' type: ' + error.message + (stack != null ? stack : '')\n );\n }\n }\n }\n }\n}\n\n/**\n * Resets warning cache when testing.\n *\n * @private\n */\ncheckPropTypes.resetWarningCache = function() {\n if (process.env.NODE_ENV !== 'production') {\n loggedTypeFailures = {};\n }\n}\n\nmodule.exports = checkPropTypes;\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar ReactIs = require('react-is');\nvar assign = require('object-assign');\n\nvar ReactPropTypesSecret = require('./lib/ReactPropTypesSecret');\nvar has = require('./lib/has');\nvar checkPropTypes = require('./checkPropTypes');\n\nvar printWarning = function() {};\n\nif (process.env.NODE_ENV !== 'production') {\n printWarning = function(text) {\n var message = 'Warning: ' + text;\n if (typeof console !== 'undefined') {\n console.error(message);\n }\n try {\n // --- Welcome to debugging React ---\n // This error was thrown as a convenience so that you can use this stack\n // to find the callsite that caused this warning to fire.\n throw new Error(message);\n } catch (x) {}\n };\n}\n\nfunction emptyFunctionThatReturnsNull() {\n return null;\n}\n\nmodule.exports = function(isValidElement, throwOnDirectAccess) {\n /* global Symbol */\n var ITERATOR_SYMBOL = typeof Symbol === 'function' && Symbol.iterator;\n var FAUX_ITERATOR_SYMBOL = '@@iterator'; // Before Symbol spec.\n\n /**\n * Returns the iterator method function contained on the iterable object.\n *\n * Be sure to invoke the function with the iterable as context:\n *\n * var iteratorFn = getIteratorFn(myIterable);\n * if (iteratorFn) {\n * var iterator = iteratorFn.call(myIterable);\n * ...\n * }\n *\n * @param {?object} maybeIterable\n * @return {?function}\n */\n function getIteratorFn(maybeIterable) {\n var iteratorFn = maybeIterable && (ITERATOR_SYMBOL && maybeIterable[ITERATOR_SYMBOL] || maybeIterable[FAUX_ITERATOR_SYMBOL]);\n if (typeof iteratorFn === 'function') {\n return iteratorFn;\n }\n }\n\n /**\n * Collection of methods that allow declaration and validation of props that are\n * supplied to React components. Example usage:\n *\n * var Props = require('ReactPropTypes');\n * var MyArticle = React.createClass({\n * propTypes: {\n * // An optional string prop named \"description\".\n * description: Props.string,\n *\n * // A required enum prop named \"category\".\n * category: Props.oneOf(['News','Photos']).isRequired,\n *\n * // A prop named \"dialog\" that requires an instance of Dialog.\n * dialog: Props.instanceOf(Dialog).isRequired\n * },\n * render: function() { ... }\n * });\n *\n * A more formal specification of how these methods are used:\n *\n * type := array|bool|func|object|number|string|oneOf([...])|instanceOf(...)\n * decl := ReactPropTypes.{type}(.isRequired)?\n *\n * Each and every declaration produces a function with the same signature. This\n * allows the creation of custom validation functions. For example:\n *\n * var MyLink = React.createClass({\n * propTypes: {\n * // An optional string or URI prop named \"href\".\n * href: function(props, propName, componentName) {\n * var propValue = props[propName];\n * if (propValue != null && typeof propValue !== 'string' &&\n * !(propValue instanceof URI)) {\n * return new Error(\n * 'Expected a string or an URI for ' + propName + ' in ' +\n * componentName\n * );\n * }\n * }\n * },\n * render: function() {...}\n * });\n *\n * @internal\n */\n\n var ANONYMOUS = '<>';\n\n // Important!\n // Keep this list in sync with production version in `./factoryWithThrowingShims.js`.\n var ReactPropTypes = {\n array: createPrimitiveTypeChecker('array'),\n bigint: createPrimitiveTypeChecker('bigint'),\n bool: createPrimitiveTypeChecker('boolean'),\n func: createPrimitiveTypeChecker('function'),\n number: createPrimitiveTypeChecker('number'),\n object: createPrimitiveTypeChecker('object'),\n string: createPrimitiveTypeChecker('string'),\n symbol: createPrimitiveTypeChecker('symbol'),\n\n any: createAnyTypeChecker(),\n arrayOf: createArrayOfTypeChecker,\n element: createElementTypeChecker(),\n elementType: createElementTypeTypeChecker(),\n instanceOf: createInstanceTypeChecker,\n node: createNodeChecker(),\n objectOf: createObjectOfTypeChecker,\n oneOf: createEnumTypeChecker,\n oneOfType: createUnionTypeChecker,\n shape: createShapeTypeChecker,\n exact: createStrictShapeTypeChecker,\n };\n\n /**\n * inlined Object.is polyfill to avoid requiring consumers ship their own\n * https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object/is\n */\n /*eslint-disable no-self-compare*/\n function is(x, y) {\n // SameValue algorithm\n if (x === y) {\n // Steps 1-5, 7-10\n // Steps 6.b-6.e: +0 != -0\n return x !== 0 || 1 / x === 1 / y;\n } else {\n // Step 6.a: NaN == NaN\n return x !== x && y !== y;\n }\n }\n /*eslint-enable no-self-compare*/\n\n /**\n * We use an Error-like object for backward compatibility as people may call\n * PropTypes directly and inspect their output. However, we don't use real\n * Errors anymore. We don't inspect their stack anyway, and creating them\n * is prohibitively expensive if they are created too often, such as what\n * happens in oneOfType() for any type before the one that matched.\n */\n function PropTypeError(message, data) {\n this.message = message;\n this.data = data && typeof data === 'object' ? data: {};\n this.stack = '';\n }\n // Make `instanceof Error` still work for returned errors.\n PropTypeError.prototype = Error.prototype;\n\n function createChainableTypeChecker(validate) {\n if (process.env.NODE_ENV !== 'production') {\n var manualPropTypeCallCache = {};\n var manualPropTypeWarningCount = 0;\n }\n function checkType(isRequired, props, propName, componentName, location, propFullName, secret) {\n componentName = componentName || ANONYMOUS;\n propFullName = propFullName || propName;\n\n if (secret !== ReactPropTypesSecret) {\n if (throwOnDirectAccess) {\n // New behavior only for users of `prop-types` package\n var err = new Error(\n 'Calling PropTypes validators directly is not supported by the `prop-types` package. ' +\n 'Use `PropTypes.checkPropTypes()` to call them. ' +\n 'Read more at http://fb.me/use-check-prop-types'\n );\n err.name = 'Invariant Violation';\n throw err;\n } else if (process.env.NODE_ENV !== 'production' && typeof console !== 'undefined') {\n // Old behavior for people using React.PropTypes\n var cacheKey = componentName + ':' + propName;\n if (\n !manualPropTypeCallCache[cacheKey] &&\n // Avoid spamming the console because they are often not actionable except for lib authors\n manualPropTypeWarningCount < 3\n ) {\n printWarning(\n 'You are manually calling a React.PropTypes validation ' +\n 'function for the `' + propFullName + '` prop on `' + componentName + '`. This is deprecated ' +\n 'and will throw in the standalone `prop-types` package. ' +\n 'You may be seeing this warning due to a third-party PropTypes ' +\n 'library. See https://fb.me/react-warning-dont-call-proptypes ' + 'for details.'\n );\n manualPropTypeCallCache[cacheKey] = true;\n manualPropTypeWarningCount++;\n }\n }\n }\n if (props[propName] == null) {\n if (isRequired) {\n if (props[propName] === null) {\n return new PropTypeError('The ' + location + ' `' + propFullName + '` is marked as required ' + ('in `' + componentName + '`, but its value is `null`.'));\n }\n return new PropTypeError('The ' + location + ' `' + propFullName + '` is marked as required in ' + ('`' + componentName + '`, but its value is `undefined`.'));\n }\n return null;\n } else {\n return validate(props, propName, componentName, location, propFullName);\n }\n }\n\n var chainedCheckType = checkType.bind(null, false);\n chainedCheckType.isRequired = checkType.bind(null, true);\n\n return chainedCheckType;\n }\n\n function createPrimitiveTypeChecker(expectedType) {\n function validate(props, propName, componentName, location, propFullName, secret) {\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== expectedType) {\n // `propValue` being instance of, say, date/regexp, pass the 'object'\n // check, but we can offer a more precise error message here rather than\n // 'of type `object`'.\n var preciseType = getPreciseType(propValue);\n\n return new PropTypeError(\n 'Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + preciseType + '` supplied to `' + componentName + '`, expected ') + ('`' + expectedType + '`.'),\n {expectedType: expectedType}\n );\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createAnyTypeChecker() {\n return createChainableTypeChecker(emptyFunctionThatReturnsNull);\n }\n\n function createArrayOfTypeChecker(typeChecker) {\n function validate(props, propName, componentName, location, propFullName) {\n if (typeof typeChecker !== 'function') {\n return new PropTypeError('Property `' + propFullName + '` of component `' + componentName + '` has invalid PropType notation inside arrayOf.');\n }\n var propValue = props[propName];\n if (!Array.isArray(propValue)) {\n var propType = getPropType(propValue);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected an array.'));\n }\n for (var i = 0; i < propValue.length; i++) {\n var error = typeChecker(propValue, i, componentName, location, propFullName + '[' + i + ']', ReactPropTypesSecret);\n if (error instanceof Error) {\n return error;\n }\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createElementTypeChecker() {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n if (!isValidElement(propValue)) {\n var propType = getPropType(propValue);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected a single ReactElement.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createElementTypeTypeChecker() {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n if (!ReactIs.isValidElementType(propValue)) {\n var propType = getPropType(propValue);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected a single ReactElement type.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createInstanceTypeChecker(expectedClass) {\n function validate(props, propName, componentName, location, propFullName) {\n if (!(props[propName] instanceof expectedClass)) {\n var expectedClassName = expectedClass.name || ANONYMOUS;\n var actualClassName = getClassName(props[propName]);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + actualClassName + '` supplied to `' + componentName + '`, expected ') + ('instance of `' + expectedClassName + '`.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createEnumTypeChecker(expectedValues) {\n if (!Array.isArray(expectedValues)) {\n if (process.env.NODE_ENV !== 'production') {\n if (arguments.length > 1) {\n printWarning(\n 'Invalid arguments supplied to oneOf, expected an array, got ' + arguments.length + ' arguments. ' +\n 'A common mistake is to write oneOf(x, y, z) instead of oneOf([x, y, z]).'\n );\n } else {\n printWarning('Invalid argument supplied to oneOf, expected an array.');\n }\n }\n return emptyFunctionThatReturnsNull;\n }\n\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n for (var i = 0; i < expectedValues.length; i++) {\n if (is(propValue, expectedValues[i])) {\n return null;\n }\n }\n\n var valuesString = JSON.stringify(expectedValues, function replacer(key, value) {\n var type = getPreciseType(value);\n if (type === 'symbol') {\n return String(value);\n }\n return value;\n });\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of value `' + String(propValue) + '` ' + ('supplied to `' + componentName + '`, expected one of ' + valuesString + '.'));\n }\n return createChainableTypeChecker(validate);\n }\n\n function createObjectOfTypeChecker(typeChecker) {\n function validate(props, propName, componentName, location, propFullName) {\n if (typeof typeChecker !== 'function') {\n return new PropTypeError('Property `' + propFullName + '` of component `' + componentName + '` has invalid PropType notation inside objectOf.');\n }\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== 'object') {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected an object.'));\n }\n for (var key in propValue) {\n if (has(propValue, key)) {\n var error = typeChecker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret);\n if (error instanceof Error) {\n return error;\n }\n }\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createUnionTypeChecker(arrayOfTypeCheckers) {\n if (!Array.isArray(arrayOfTypeCheckers)) {\n process.env.NODE_ENV !== 'production' ? printWarning('Invalid argument supplied to oneOfType, expected an instance of array.') : void 0;\n return emptyFunctionThatReturnsNull;\n }\n\n for (var i = 0; i < arrayOfTypeCheckers.length; i++) {\n var checker = arrayOfTypeCheckers[i];\n if (typeof checker !== 'function') {\n printWarning(\n 'Invalid argument supplied to oneOfType. Expected an array of check functions, but ' +\n 'received ' + getPostfixForTypeWarning(checker) + ' at index ' + i + '.'\n );\n return emptyFunctionThatReturnsNull;\n }\n }\n\n function validate(props, propName, componentName, location, propFullName) {\n var expectedTypes = [];\n for (var i = 0; i < arrayOfTypeCheckers.length; i++) {\n var checker = arrayOfTypeCheckers[i];\n var checkerResult = checker(props, propName, componentName, location, propFullName, ReactPropTypesSecret);\n if (checkerResult == null) {\n return null;\n }\n if (checkerResult.data && has(checkerResult.data, 'expectedType')) {\n expectedTypes.push(checkerResult.data.expectedType);\n }\n }\n var expectedTypesMessage = (expectedTypes.length > 0) ? ', expected one of type [' + expectedTypes.join(', ') + ']': '';\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` supplied to ' + ('`' + componentName + '`' + expectedTypesMessage + '.'));\n }\n return createChainableTypeChecker(validate);\n }\n\n function createNodeChecker() {\n function validate(props, propName, componentName, location, propFullName) {\n if (!isNode(props[propName])) {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` supplied to ' + ('`' + componentName + '`, expected a ReactNode.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function invalidValidatorError(componentName, location, propFullName, key, type) {\n return new PropTypeError(\n (componentName || 'React class') + ': ' + location + ' type `' + propFullName + '.' + key + '` is invalid; ' +\n 'it must be a function, usually from the `prop-types` package, but received `' + type + '`.'\n );\n }\n\n function createShapeTypeChecker(shapeTypes) {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== 'object') {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type `' + propType + '` ' + ('supplied to `' + componentName + '`, expected `object`.'));\n }\n for (var key in shapeTypes) {\n var checker = shapeTypes[key];\n if (typeof checker !== 'function') {\n return invalidValidatorError(componentName, location, propFullName, key, getPreciseType(checker));\n }\n var error = checker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret);\n if (error) {\n return error;\n }\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createStrictShapeTypeChecker(shapeTypes) {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== 'object') {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type `' + propType + '` ' + ('supplied to `' + componentName + '`, expected `object`.'));\n }\n // We need to check all keys in case some are required but missing from props.\n var allKeys = assign({}, props[propName], shapeTypes);\n for (var key in allKeys) {\n var checker = shapeTypes[key];\n if (has(shapeTypes, key) && typeof checker !== 'function') {\n return invalidValidatorError(componentName, location, propFullName, key, getPreciseType(checker));\n }\n if (!checker) {\n return new PropTypeError(\n 'Invalid ' + location + ' `' + propFullName + '` key `' + key + '` supplied to `' + componentName + '`.' +\n '\\nBad object: ' + JSON.stringify(props[propName], null, ' ') +\n '\\nValid keys: ' + JSON.stringify(Object.keys(shapeTypes), null, ' ')\n );\n }\n var error = checker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret);\n if (error) {\n return error;\n }\n }\n return null;\n }\n\n return createChainableTypeChecker(validate);\n }\n\n function isNode(propValue) {\n switch (typeof propValue) {\n case 'number':\n case 'string':\n case 'undefined':\n return true;\n case 'boolean':\n return !propValue;\n case 'object':\n if (Array.isArray(propValue)) {\n return propValue.every(isNode);\n }\n if (propValue === null || isValidElement(propValue)) {\n return true;\n }\n\n var iteratorFn = getIteratorFn(propValue);\n if (iteratorFn) {\n var iterator = iteratorFn.call(propValue);\n var step;\n if (iteratorFn !== propValue.entries) {\n while (!(step = iterator.next()).done) {\n if (!isNode(step.value)) {\n return false;\n }\n }\n } else {\n // Iterator will provide entry [k,v] tuples rather than values.\n while (!(step = iterator.next()).done) {\n var entry = step.value;\n if (entry) {\n if (!isNode(entry[1])) {\n return false;\n }\n }\n }\n }\n } else {\n return false;\n }\n\n return true;\n default:\n return false;\n }\n }\n\n function isSymbol(propType, propValue) {\n // Native Symbol.\n if (propType === 'symbol') {\n return true;\n }\n\n // falsy value can't be a Symbol\n if (!propValue) {\n return false;\n }\n\n // 19.4.3.5 Symbol.prototype[@@toStringTag] === 'Symbol'\n if (propValue['@@toStringTag'] === 'Symbol') {\n return true;\n }\n\n // Fallback for non-spec compliant Symbols which are polyfilled.\n if (typeof Symbol === 'function' && propValue instanceof Symbol) {\n return true;\n }\n\n return false;\n }\n\n // Equivalent of `typeof` but with special handling for array and regexp.\n function getPropType(propValue) {\n var propType = typeof propValue;\n if (Array.isArray(propValue)) {\n return 'array';\n }\n if (propValue instanceof RegExp) {\n // Old webkits (at least until Android 4.0) return 'function' rather than\n // 'object' for typeof a RegExp. We'll normalize this here so that /bla/\n // passes PropTypes.object.\n return 'object';\n }\n if (isSymbol(propType, propValue)) {\n return 'symbol';\n }\n return propType;\n }\n\n // This handles more types than `getPropType`. Only used for error messages.\n // See `createPrimitiveTypeChecker`.\n function getPreciseType(propValue) {\n if (typeof propValue === 'undefined' || propValue === null) {\n return '' + propValue;\n }\n var propType = getPropType(propValue);\n if (propType === 'object') {\n if (propValue instanceof Date) {\n return 'date';\n } else if (propValue instanceof RegExp) {\n return 'regexp';\n }\n }\n return propType;\n }\n\n // Returns a string that is postfixed to a warning about an invalid type.\n // For example, \"undefined\" or \"of type array\"\n function getPostfixForTypeWarning(value) {\n var type = getPreciseType(value);\n switch (type) {\n case 'array':\n case 'object':\n return 'an ' + type;\n case 'boolean':\n case 'date':\n case 'regexp':\n return 'a ' + type;\n default:\n return type;\n }\n }\n\n // Returns class name of the object, if any.\n function getClassName(propValue) {\n if (!propValue.constructor || !propValue.constructor.name) {\n return ANONYMOUS;\n }\n return propValue.constructor.name;\n }\n\n ReactPropTypes.checkPropTypes = checkPropTypes;\n ReactPropTypes.resetWarningCache = checkPropTypes.resetWarningCache;\n ReactPropTypes.PropTypes = ReactPropTypes;\n\n return ReactPropTypes;\n};\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar ReactPropTypesSecret = require('./lib/ReactPropTypesSecret');\n\nfunction emptyFunction() {}\nfunction emptyFunctionWithReset() {}\nemptyFunctionWithReset.resetWarningCache = emptyFunction;\n\nmodule.exports = function() {\n function shim(props, propName, componentName, location, propFullName, secret) {\n if (secret === ReactPropTypesSecret) {\n // It is still safe when called from React.\n return;\n }\n var err = new Error(\n 'Calling PropTypes validators directly is not supported by the `prop-types` package. ' +\n 'Use PropTypes.checkPropTypes() to call them. ' +\n 'Read more at http://fb.me/use-check-prop-types'\n );\n err.name = 'Invariant Violation';\n throw err;\n };\n shim.isRequired = shim;\n function getShim() {\n return shim;\n };\n // Important!\n // Keep this list in sync with production version in `./factoryWithTypeCheckers.js`.\n var ReactPropTypes = {\n array: shim,\n bigint: shim,\n bool: shim,\n func: shim,\n number: shim,\n object: shim,\n string: shim,\n symbol: shim,\n\n any: shim,\n arrayOf: getShim,\n element: shim,\n elementType: shim,\n instanceOf: getShim,\n node: shim,\n objectOf: getShim,\n oneOf: getShim,\n oneOfType: getShim,\n shape: getShim,\n exact: getShim,\n\n checkPropTypes: emptyFunctionWithReset,\n resetWarningCache: emptyFunction\n };\n\n ReactPropTypes.PropTypes = ReactPropTypes;\n\n return ReactPropTypes;\n};\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\nif (process.env.NODE_ENV !== 'production') {\n var ReactIs = require('react-is');\n\n // By explicitly using `prop-types` you are opting into new development behavior.\n // http://fb.me/prop-types-in-prod\n var throwOnDirectAccess = true;\n module.exports = require('./factoryWithTypeCheckers')(ReactIs.isElement, throwOnDirectAccess);\n} else {\n // By explicitly using `prop-types` you are opting into new production behavior.\n // http://fb.me/prop-types-in-prod\n module.exports = require('./factoryWithThrowingShims')();\n}\n","import PropTypes from 'prop-types';\nimport chainPropTypes from '../chainPropTypes';\nfunction isClassComponent(elementType) {\n // elementType.prototype?.isReactComponent\n const {\n prototype = {}\n } = elementType;\n return Boolean(prototype.isReactComponent);\n}\nfunction acceptingRef(props, propName, componentName, location, propFullName) {\n const element = props[propName];\n const safePropName = propFullName || propName;\n if (element == null ||\n // When server-side rendering React doesn't warn either.\n // This is not an accurate check for SSR.\n // This is only in place for Emotion compat.\n // TODO: Revisit once https://github.com/facebook/react/issues/20047 is resolved.\n typeof window === 'undefined') {\n return null;\n }\n let warningHint;\n const elementType = element.type;\n /**\n * Blacklisting instead of whitelisting\n *\n * Blacklisting will miss some components, such as React.Fragment. Those will at least\n * trigger a warning in React.\n * We can't whitelist because there is no safe way to detect React.forwardRef\n * or class components. \"Safe\" means there's no public API.\n *\n */\n if (typeof elementType === 'function' && !isClassComponent(elementType)) {\n warningHint = 'Did you accidentally use a plain function component for an element instead?';\n }\n if (warningHint !== undefined) {\n return new Error(`Invalid ${location} \\`${safePropName}\\` supplied to \\`${componentName}\\`. ` + `Expected an element that can hold a ref. ${warningHint} ` + 'For more information see https://mui.com/r/caveat-with-refs-guide');\n }\n return null;\n}\nconst elementAcceptingRef = chainPropTypes(PropTypes.element, acceptingRef);\nelementAcceptingRef.isRequired = chainPropTypes(PropTypes.element.isRequired, acceptingRef);\nexport default elementAcceptingRef;","import _extends from \"@babel/runtime/helpers/esm/extends\";\n// This module is based on https://github.com/airbnb/prop-types-exact repository.\n// However, in order to reduce the number of dependencies and to remove some extra safe checks\n// the module was forked.\n\nconst specialProperty = 'exact-prop: \\u200b';\nexport default function exactProp(propTypes) {\n if (process.env.NODE_ENV === 'production') {\n return propTypes;\n }\n return _extends({}, propTypes, {\n [specialProperty]: props => {\n const unsupportedProps = Object.keys(props).filter(prop => !propTypes.hasOwnProperty(prop));\n if (unsupportedProps.length > 0) {\n return new Error(`The following props are not supported: ${unsupportedProps.map(prop => `\\`${prop}\\``).join(', ')}. Please remove them.`);\n }\n return null;\n }\n });\n}","/**\n * WARNING: Don't import this directly.\n * Use `MuiError` from `@mui/internal-babel-macros/MuiError.macro` instead.\n * @param {number} code\n */\nexport default function formatMuiErrorMessage(code) {\n // Apply babel-plugin-transform-template-literals in loose mode\n // loose mode is safe if we're concatenating primitives\n // see https://babeljs.io/docs/en/babel-plugin-transform-template-literals#loose\n /* eslint-disable prefer-template */\n let url = 'https://mui.com/production-error/?code=' + code;\n for (let i = 1; i < arguments.length; i += 1) {\n // rest params over-transpile for this case\n // eslint-disable-next-line prefer-rest-params\n url += '&args[]=' + encodeURIComponent(arguments[i]);\n }\n return 'Minified MUI error #' + code + '; visit ' + url + ' for the full message.';\n /* eslint-enable prefer-template */\n}","/**\n * @license React\n * react-is.production.min.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n'use strict';var b=Symbol.for(\"react.element\"),c=Symbol.for(\"react.portal\"),d=Symbol.for(\"react.fragment\"),e=Symbol.for(\"react.strict_mode\"),f=Symbol.for(\"react.profiler\"),g=Symbol.for(\"react.provider\"),h=Symbol.for(\"react.context\"),k=Symbol.for(\"react.server_context\"),l=Symbol.for(\"react.forward_ref\"),m=Symbol.for(\"react.suspense\"),n=Symbol.for(\"react.suspense_list\"),p=Symbol.for(\"react.memo\"),q=Symbol.for(\"react.lazy\"),t=Symbol.for(\"react.offscreen\"),u;u=Symbol.for(\"react.module.reference\");\nfunction v(a){if(\"object\"===typeof a&&null!==a){var r=a.$$typeof;switch(r){case b:switch(a=a.type,a){case d:case f:case e:case m:case n:return a;default:switch(a=a&&a.$$typeof,a){case k:case h:case l:case q:case p:case g:return a;default:return r}}case c:return r}}}exports.ContextConsumer=h;exports.ContextProvider=g;exports.Element=b;exports.ForwardRef=l;exports.Fragment=d;exports.Lazy=q;exports.Memo=p;exports.Portal=c;exports.Profiler=f;exports.StrictMode=e;exports.Suspense=m;\nexports.SuspenseList=n;exports.isAsyncMode=function(){return!1};exports.isConcurrentMode=function(){return!1};exports.isContextConsumer=function(a){return v(a)===h};exports.isContextProvider=function(a){return v(a)===g};exports.isElement=function(a){return\"object\"===typeof a&&null!==a&&a.$$typeof===b};exports.isForwardRef=function(a){return v(a)===l};exports.isFragment=function(a){return v(a)===d};exports.isLazy=function(a){return v(a)===q};exports.isMemo=function(a){return v(a)===p};\nexports.isPortal=function(a){return v(a)===c};exports.isProfiler=function(a){return v(a)===f};exports.isStrictMode=function(a){return v(a)===e};exports.isSuspense=function(a){return v(a)===m};exports.isSuspenseList=function(a){return v(a)===n};\nexports.isValidElementType=function(a){return\"string\"===typeof a||\"function\"===typeof a||a===d||a===f||a===e||a===m||a===n||a===t||\"object\"===typeof a&&null!==a&&(a.$$typeof===q||a.$$typeof===p||a.$$typeof===g||a.$$typeof===h||a.$$typeof===l||a.$$typeof===u||void 0!==a.getModuleId)?!0:!1};exports.typeOf=v;\n","/**\n * @license React\n * react-is.development.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nif (process.env.NODE_ENV !== \"production\") {\n (function() {\n'use strict';\n\n// ATTENTION\n// When adding new symbols to this file,\n// Please consider also adding to 'react-devtools-shared/src/backend/ReactSymbols'\n// The Symbol used to tag the ReactElement-like types.\nvar REACT_ELEMENT_TYPE = Symbol.for('react.element');\nvar REACT_PORTAL_TYPE = Symbol.for('react.portal');\nvar REACT_FRAGMENT_TYPE = Symbol.for('react.fragment');\nvar REACT_STRICT_MODE_TYPE = Symbol.for('react.strict_mode');\nvar REACT_PROFILER_TYPE = Symbol.for('react.profiler');\nvar REACT_PROVIDER_TYPE = Symbol.for('react.provider');\nvar REACT_CONTEXT_TYPE = Symbol.for('react.context');\nvar REACT_SERVER_CONTEXT_TYPE = Symbol.for('react.server_context');\nvar REACT_FORWARD_REF_TYPE = Symbol.for('react.forward_ref');\nvar REACT_SUSPENSE_TYPE = Symbol.for('react.suspense');\nvar REACT_SUSPENSE_LIST_TYPE = Symbol.for('react.suspense_list');\nvar REACT_MEMO_TYPE = Symbol.for('react.memo');\nvar REACT_LAZY_TYPE = Symbol.for('react.lazy');\nvar REACT_OFFSCREEN_TYPE = Symbol.for('react.offscreen');\n\n// -----------------------------------------------------------------------------\n\nvar enableScopeAPI = false; // Experimental Create Event Handle API.\nvar enableCacheElement = false;\nvar enableTransitionTracing = false; // No known bugs, but needs performance testing\n\nvar enableLegacyHidden = false; // Enables unstable_avoidThisFallback feature in Fiber\n// stuff. Intended to enable React core members to more easily debug scheduling\n// issues in DEV builds.\n\nvar enableDebugTracing = false; // Track which Fiber(s) schedule render work.\n\nvar REACT_MODULE_REFERENCE;\n\n{\n REACT_MODULE_REFERENCE = Symbol.for('react.module.reference');\n}\n\nfunction isValidElementType(type) {\n if (typeof type === 'string' || typeof type === 'function') {\n return true;\n } // Note: typeof might be other than 'symbol' or 'number' (e.g. if it's a polyfill).\n\n\n if (type === REACT_FRAGMENT_TYPE || type === REACT_PROFILER_TYPE || enableDebugTracing || type === REACT_STRICT_MODE_TYPE || type === REACT_SUSPENSE_TYPE || type === REACT_SUSPENSE_LIST_TYPE || enableLegacyHidden || type === REACT_OFFSCREEN_TYPE || enableScopeAPI || enableCacheElement || enableTransitionTracing ) {\n return true;\n }\n\n if (typeof type === 'object' && type !== null) {\n if (type.$$typeof === REACT_LAZY_TYPE || type.$$typeof === REACT_MEMO_TYPE || type.$$typeof === REACT_PROVIDER_TYPE || type.$$typeof === REACT_CONTEXT_TYPE || type.$$typeof === REACT_FORWARD_REF_TYPE || // This needs to include all possible module reference object\n // types supported by any Flight configuration anywhere since\n // we don't know which Flight build this will end up being used\n // with.\n type.$$typeof === REACT_MODULE_REFERENCE || type.getModuleId !== undefined) {\n return true;\n }\n }\n\n return false;\n}\n\nfunction typeOf(object) {\n if (typeof object === 'object' && object !== null) {\n var $$typeof = object.$$typeof;\n\n switch ($$typeof) {\n case REACT_ELEMENT_TYPE:\n var type = object.type;\n\n switch (type) {\n case REACT_FRAGMENT_TYPE:\n case REACT_PROFILER_TYPE:\n case REACT_STRICT_MODE_TYPE:\n case REACT_SUSPENSE_TYPE:\n case REACT_SUSPENSE_LIST_TYPE:\n return type;\n\n default:\n var $$typeofType = type && type.$$typeof;\n\n switch ($$typeofType) {\n case REACT_SERVER_CONTEXT_TYPE:\n case REACT_CONTEXT_TYPE:\n case REACT_FORWARD_REF_TYPE:\n case REACT_LAZY_TYPE:\n case REACT_MEMO_TYPE:\n case REACT_PROVIDER_TYPE:\n return $$typeofType;\n\n default:\n return $$typeof;\n }\n\n }\n\n case REACT_PORTAL_TYPE:\n return $$typeof;\n }\n }\n\n return undefined;\n}\nvar ContextConsumer = REACT_CONTEXT_TYPE;\nvar ContextProvider = REACT_PROVIDER_TYPE;\nvar Element = REACT_ELEMENT_TYPE;\nvar ForwardRef = REACT_FORWARD_REF_TYPE;\nvar Fragment = REACT_FRAGMENT_TYPE;\nvar Lazy = REACT_LAZY_TYPE;\nvar Memo = REACT_MEMO_TYPE;\nvar Portal = REACT_PORTAL_TYPE;\nvar Profiler = REACT_PROFILER_TYPE;\nvar StrictMode = REACT_STRICT_MODE_TYPE;\nvar Suspense = REACT_SUSPENSE_TYPE;\nvar SuspenseList = REACT_SUSPENSE_LIST_TYPE;\nvar hasWarnedAboutDeprecatedIsAsyncMode = false;\nvar hasWarnedAboutDeprecatedIsConcurrentMode = false; // AsyncMode should be deprecated\n\nfunction isAsyncMode(object) {\n {\n if (!hasWarnedAboutDeprecatedIsAsyncMode) {\n hasWarnedAboutDeprecatedIsAsyncMode = true; // Using console['warn'] to evade Babel and ESLint\n\n console['warn']('The ReactIs.isAsyncMode() alias has been deprecated, ' + 'and will be removed in React 18+.');\n }\n }\n\n return false;\n}\nfunction isConcurrentMode(object) {\n {\n if (!hasWarnedAboutDeprecatedIsConcurrentMode) {\n hasWarnedAboutDeprecatedIsConcurrentMode = true; // Using console['warn'] to evade Babel and ESLint\n\n console['warn']('The ReactIs.isConcurrentMode() alias has been deprecated, ' + 'and will be removed in React 18+.');\n }\n }\n\n return false;\n}\nfunction isContextConsumer(object) {\n return typeOf(object) === REACT_CONTEXT_TYPE;\n}\nfunction isContextProvider(object) {\n return typeOf(object) === REACT_PROVIDER_TYPE;\n}\nfunction isElement(object) {\n return typeof object === 'object' && object !== null && object.$$typeof === REACT_ELEMENT_TYPE;\n}\nfunction isForwardRef(object) {\n return typeOf(object) === REACT_FORWARD_REF_TYPE;\n}\nfunction isFragment(object) {\n return typeOf(object) === REACT_FRAGMENT_TYPE;\n}\nfunction isLazy(object) {\n return typeOf(object) === REACT_LAZY_TYPE;\n}\nfunction isMemo(object) {\n return typeOf(object) === REACT_MEMO_TYPE;\n}\nfunction isPortal(object) {\n return typeOf(object) === REACT_PORTAL_TYPE;\n}\nfunction isProfiler(object) {\n return typeOf(object) === REACT_PROFILER_TYPE;\n}\nfunction isStrictMode(object) {\n return typeOf(object) === REACT_STRICT_MODE_TYPE;\n}\nfunction isSuspense(object) {\n return typeOf(object) === REACT_SUSPENSE_TYPE;\n}\nfunction isSuspenseList(object) {\n return typeOf(object) === REACT_SUSPENSE_LIST_TYPE;\n}\n\nexports.ContextConsumer = ContextConsumer;\nexports.ContextProvider = ContextProvider;\nexports.Element = Element;\nexports.ForwardRef = ForwardRef;\nexports.Fragment = Fragment;\nexports.Lazy = Lazy;\nexports.Memo = Memo;\nexports.Portal = Portal;\nexports.Profiler = Profiler;\nexports.StrictMode = StrictMode;\nexports.Suspense = Suspense;\nexports.SuspenseList = SuspenseList;\nexports.isAsyncMode = isAsyncMode;\nexports.isConcurrentMode = isConcurrentMode;\nexports.isContextConsumer = isContextConsumer;\nexports.isContextProvider = isContextProvider;\nexports.isElement = isElement;\nexports.isForwardRef = isForwardRef;\nexports.isFragment = isFragment;\nexports.isLazy = isLazy;\nexports.isMemo = isMemo;\nexports.isPortal = isPortal;\nexports.isProfiler = isProfiler;\nexports.isStrictMode = isStrictMode;\nexports.isSuspense = isSuspense;\nexports.isSuspenseList = isSuspenseList;\nexports.isValidElementType = isValidElementType;\nexports.typeOf = typeOf;\n })();\n}\n","'use strict';\n\nif (process.env.NODE_ENV === 'production') {\n module.exports = require('./cjs/react-is.production.min.js');\n} else {\n module.exports = require('./cjs/react-is.development.js');\n}\n","import { ForwardRef, Memo } from 'react-is';\n\n// Simplified polyfill for IE11 support\n// https://github.com/JamesMGreene/Function.name/blob/58b314d4a983110c3682f1228f845d39ccca1817/Function.name.js#L3\nconst fnNameMatchRegex = /^\\s*function(?:\\s|\\s*\\/\\*.*\\*\\/\\s*)+([^(\\s/]*)\\s*/;\nexport function getFunctionName(fn) {\n const match = `${fn}`.match(fnNameMatchRegex);\n const name = match && match[1];\n return name || '';\n}\nfunction getFunctionComponentName(Component, fallback = '') {\n return Component.displayName || Component.name || getFunctionName(Component) || fallback;\n}\nfunction getWrappedName(outerType, innerType, wrapperName) {\n const functionName = getFunctionComponentName(innerType);\n return outerType.displayName || (functionName !== '' ? `${wrapperName}(${functionName})` : wrapperName);\n}\n\n/**\n * cherry-pick from\n * https://github.com/facebook/react/blob/769b1f270e1251d9dbdce0fcbd9e92e502d059b8/packages/shared/getComponentName.js\n * originally forked from recompose/getDisplayName with added IE11 support\n */\nexport default function getDisplayName(Component) {\n if (Component == null) {\n return undefined;\n }\n if (typeof Component === 'string') {\n return Component;\n }\n if (typeof Component === 'function') {\n return getFunctionComponentName(Component, 'Component');\n }\n\n // TypeScript can't have components as objects but they exist in the form of `memo` or `Suspense`\n if (typeof Component === 'object') {\n switch (Component.$$typeof) {\n case ForwardRef:\n return getWrappedName(Component, Component.render, 'ForwardRef');\n case Memo:\n return getWrappedName(Component, Component.type, 'memo');\n default:\n return undefined;\n }\n }\n return undefined;\n}","export default function HTMLElementType(props, propName, componentName, location, propFullName) {\n if (process.env.NODE_ENV === 'production') {\n return null;\n }\n const propValue = props[propName];\n const safePropName = propFullName || propName;\n if (propValue == null) {\n return null;\n }\n if (propValue && propValue.nodeType !== 1) {\n return new Error(`Invalid ${location} \\`${safePropName}\\` supplied to \\`${componentName}\\`. ` + `Expected an HTMLElement.`);\n }\n return null;\n}","import PropTypes from 'prop-types';\nconst refType = PropTypes.oneOfType([PropTypes.func, PropTypes.object]);\nexport default refType;","import _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\n// It should to be noted that this function isn't equivalent to `text-transform: capitalize`.\n//\n// A strict capitalization should uppercase the first letter of each word in the sentence.\n// We only handle the first word.\nexport default function capitalize(string) {\n if (typeof string !== 'string') {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: \\`capitalize(string)\\` expects a string argument.` : _formatMuiErrorMessage(7));\n }\n return string.charAt(0).toUpperCase() + string.slice(1);\n}","/**\n * Safe chained function.\n *\n * Will only create a new function if needed,\n * otherwise will pass back existing functions or null.\n */\nexport default function createChainedFunction(...funcs) {\n return funcs.reduce((acc, func) => {\n if (func == null) {\n return acc;\n }\n return function chainedFunction(...args) {\n acc.apply(this, args);\n func.apply(this, args);\n };\n }, () => {});\n}","// Corresponds to 10 frames at 60 Hz.\n// A few bytes payload overhead when lodash/debounce is ~3 kB and debounce ~300 B.\nexport default function debounce(func, wait = 166) {\n let timeout;\n function debounced(...args) {\n const later = () => {\n // @ts-ignore\n func.apply(this, args);\n };\n clearTimeout(timeout);\n timeout = setTimeout(later, wait);\n }\n debounced.clear = () => {\n clearTimeout(timeout);\n };\n return debounced;\n}","export default function deprecatedPropType(validator, reason) {\n if (process.env.NODE_ENV === 'production') {\n return () => null;\n }\n return (props, propName, componentName, location, propFullName) => {\n const componentNameSafe = componentName || '<>';\n const propFullNameSafe = propFullName || propName;\n if (typeof props[propName] !== 'undefined') {\n return new Error(`The ${location} \\`${propFullNameSafe}\\` of ` + `\\`${componentNameSafe}\\` is deprecated. ${reason}`);\n }\n return null;\n };\n}","import * as React from 'react';\nexport default function isMuiElement(element, muiNames) {\n var _muiName, _element$type;\n return /*#__PURE__*/React.isValidElement(element) && muiNames.indexOf( // For server components `muiName` is avaialble in element.type._payload.value.muiName\n // relevant info - https://github.com/facebook/react/blob/2807d781a08db8e9873687fccc25c0f12b4fb3d4/packages/react/src/ReactLazy.js#L45\n // eslint-disable-next-line no-underscore-dangle\n (_muiName = element.type.muiName) != null ? _muiName : (_element$type = element.type) == null || (_element$type = _element$type._payload) == null || (_element$type = _element$type.value) == null ? void 0 : _element$type.muiName) !== -1;\n}","export default function ownerDocument(node) {\n return node && node.ownerDocument || document;\n}","import ownerDocument from '../ownerDocument';\nexport default function ownerWindow(node) {\n const doc = ownerDocument(node);\n return doc.defaultView || window;\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nexport default function requirePropFactory(componentNameInError, Component) {\n if (process.env.NODE_ENV === 'production') {\n return () => null;\n }\n\n // eslint-disable-next-line react/forbid-foreign-prop-types\n const prevPropTypes = Component ? _extends({}, Component.propTypes) : null;\n const requireProp = requiredProp => (props, propName, componentName, location, propFullName, ...args) => {\n const propFullNameSafe = propFullName || propName;\n const defaultTypeChecker = prevPropTypes == null ? void 0 : prevPropTypes[propFullNameSafe];\n if (defaultTypeChecker) {\n const typeCheckerResult = defaultTypeChecker(props, propName, componentName, location, propFullName, ...args);\n if (typeCheckerResult) {\n return typeCheckerResult;\n }\n }\n if (typeof props[propName] !== 'undefined' && !props[requiredProp]) {\n return new Error(`The prop \\`${propFullNameSafe}\\` of ` + `\\`${componentNameInError}\\` can only be used together with the \\`${requiredProp}\\` prop.`);\n }\n return null;\n };\n return requireProp;\n}","/**\n * TODO v5: consider making it private\n *\n * passes {value} to {ref}\n *\n * WARNING: Be sure to only call this inside a callback that is passed as a ref.\n * Otherwise, make sure to cleanup the previous {ref} if it changes. See\n * https://github.com/mui/material-ui/issues/13539\n *\n * Useful if you want to expose the ref of an inner component to the public API\n * while still using it inside the component.\n * @param ref A ref callback or ref object. If anything falsy, this is a no-op.\n */\nexport default function setRef(ref, value) {\n if (typeof ref === 'function') {\n ref(value);\n } else if (ref) {\n ref.current = value;\n }\n}","'use client';\n\nimport * as React from 'react';\n\n/**\n * A version of `React.useLayoutEffect` that does not show a warning when server-side rendering.\n * This is useful for effects that are only needed for client-side rendering but not for SSR.\n *\n * Before you use this hook, make sure to read https://gist.github.com/gaearon/e7d97cdf38a2907924ea12e4ebdf3c85\n * and confirm it doesn't apply to your use-case.\n */\nconst useEnhancedEffect = typeof window !== 'undefined' ? React.useLayoutEffect : React.useEffect;\nexport default useEnhancedEffect;","'use client';\n\nimport * as React from 'react';\nlet globalId = 0;\nfunction useGlobalId(idOverride) {\n const [defaultId, setDefaultId] = React.useState(idOverride);\n const id = idOverride || defaultId;\n React.useEffect(() => {\n if (defaultId == null) {\n // Fallback to this default id when possible.\n // Use the incrementing value for client-side rendering only.\n // We can't use it server-side.\n // If you want to use random values please consider the Birthday Problem: https://en.wikipedia.org/wiki/Birthday_problem\n globalId += 1;\n setDefaultId(`mui-${globalId}`);\n }\n }, [defaultId]);\n return id;\n}\n\n// downstream bundlers may remove unnecessary concatenation, but won't remove toString call -- Workaround for https://github.com/webpack/webpack/issues/14814\nconst maybeReactUseId = React['useId'.toString()];\n/**\n *\n * @example
    \n * @param idOverride\n * @returns {string}\n */\nexport default function useId(idOverride) {\n if (maybeReactUseId !== undefined) {\n const reactId = maybeReactUseId();\n return idOverride != null ? idOverride : reactId;\n }\n // eslint-disable-next-line react-hooks/rules-of-hooks -- `React.useId` is invariant at runtime.\n return useGlobalId(idOverride);\n}","export default function unsupportedProp(props, propName, componentName, location, propFullName) {\n if (process.env.NODE_ENV === 'production') {\n return null;\n }\n const propFullNameSafe = propFullName || propName;\n if (typeof props[propName] !== 'undefined') {\n return new Error(`The prop \\`${propFullNameSafe}\\` is not supported. Please remove it.`);\n }\n return null;\n}","'use client';\n\n/* eslint-disable react-hooks/rules-of-hooks, react-hooks/exhaustive-deps */\nimport * as React from 'react';\nexport default function useControlled({\n controlled,\n default: defaultProp,\n name,\n state = 'value'\n}) {\n // isControlled is ignored in the hook dependency lists as it should never change.\n const {\n current: isControlled\n } = React.useRef(controlled !== undefined);\n const [valueState, setValue] = React.useState(defaultProp);\n const value = isControlled ? controlled : valueState;\n if (process.env.NODE_ENV !== 'production') {\n React.useEffect(() => {\n if (isControlled !== (controlled !== undefined)) {\n console.error([`MUI: A component is changing the ${isControlled ? '' : 'un'}controlled ${state} state of ${name} to be ${isControlled ? 'un' : ''}controlled.`, 'Elements should not switch from uncontrolled to controlled (or vice versa).', `Decide between using a controlled or uncontrolled ${name} ` + 'element for the lifetime of the component.', \"The nature of the state is determined during the first render. It's considered controlled if the value is not `undefined`.\", 'More info: https://fb.me/react-controlled-components'].join('\\n'));\n }\n }, [state, name, controlled]);\n const {\n current: defaultValue\n } = React.useRef(defaultProp);\n React.useEffect(() => {\n if (!isControlled && defaultValue !== defaultProp) {\n console.error([`MUI: A component is changing the default ${state} state of an uncontrolled ${name} after being initialized. ` + `To suppress this warning opt to use a controlled ${name}.`].join('\\n'));\n }\n }, [JSON.stringify(defaultProp)]);\n }\n const setValueIfUncontrolled = React.useCallback(newValue => {\n if (!isControlled) {\n setValue(newValue);\n }\n }, []);\n return [value, setValueIfUncontrolled];\n}","'use client';\n\nimport * as React from 'react';\nimport useEnhancedEffect from '../useEnhancedEffect';\n\n/**\n * Inspired by https://github.com/facebook/react/issues/14099#issuecomment-440013892\n * See RFC in https://github.com/reactjs/rfcs/pull/220\n */\n\nfunction useEventCallback(fn) {\n const ref = React.useRef(fn);\n useEnhancedEffect(() => {\n ref.current = fn;\n });\n return React.useRef((...args) =>\n // @ts-expect-error hide `this`\n (0, ref.current)(...args)).current;\n}\nexport default useEventCallback;","'use client';\n\nimport * as React from 'react';\nimport setRef from '../setRef';\nexport default function useForkRef(...refs) {\n /**\n * This will create a new function if the refs passed to this hook change and are all defined.\n * This means react will call the old forkRef with `null` and the new forkRef\n * with the ref. Cleanup naturally emerges from this behavior.\n */\n return React.useMemo(() => {\n if (refs.every(ref => ref == null)) {\n return null;\n }\n return instance => {\n refs.forEach(ref => {\n setRef(ref, instance);\n });\n };\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, refs);\n}","'use client';\n\nimport * as React from 'react';\nconst UNINITIALIZED = {};\n\n/**\n * A React.useRef() that is initialized lazily with a function. Note that it accepts an optional\n * initialization argument, so the initialization function doesn't need to be an inline closure.\n *\n * @usage\n * const ref = useLazyRef(sortColumns, columns)\n */\nexport default function useLazyRef(init, initArg) {\n const ref = React.useRef(UNINITIALIZED);\n if (ref.current === UNINITIALIZED) {\n ref.current = init(initArg);\n }\n return ref;\n}","'use client';\n\nimport * as React from 'react';\nconst EMPTY = [];\n\n/**\n * A React.useEffect equivalent that runs once, when the component is mounted.\n */\nexport default function useOnMount(fn) {\n /* eslint-disable react-hooks/exhaustive-deps */\n React.useEffect(fn, EMPTY);\n /* eslint-enable react-hooks/exhaustive-deps */\n}","'use client';\n\nimport useLazyRef from '../useLazyRef/useLazyRef';\nimport useOnMount from '../useOnMount/useOnMount';\nexport class Timeout {\n constructor() {\n this.currentId = null;\n this.clear = () => {\n if (this.currentId !== null) {\n clearTimeout(this.currentId);\n this.currentId = null;\n }\n };\n this.disposeEffect = () => {\n return this.clear;\n };\n }\n static create() {\n return new Timeout();\n }\n /**\n * Executes `fn` after `delay`, clearing any previously scheduled call.\n */\n start(delay, fn) {\n this.clear();\n this.currentId = setTimeout(() => {\n this.currentId = null;\n fn();\n }, delay);\n }\n}\nexport default function useTimeout() {\n const timeout = useLazyRef(Timeout.create).current;\n useOnMount(timeout.disposeEffect);\n return timeout;\n}","'use client';\n\n// based on https://github.com/WICG/focus-visible/blob/v4.1.5/src/focus-visible.js\nimport * as React from 'react';\nimport { Timeout } from '../useTimeout/useTimeout';\nlet hadKeyboardEvent = true;\nlet hadFocusVisibleRecently = false;\nconst hadFocusVisibleRecentlyTimeout = new Timeout();\nconst inputTypesWhitelist = {\n text: true,\n search: true,\n url: true,\n tel: true,\n email: true,\n password: true,\n number: true,\n date: true,\n month: true,\n week: true,\n time: true,\n datetime: true,\n 'datetime-local': true\n};\n\n/**\n * Computes whether the given element should automatically trigger the\n * `focus-visible` class being added, i.e. whether it should always match\n * `:focus-visible` when focused.\n * @param {Element} node\n * @returns {boolean}\n */\nfunction focusTriggersKeyboardModality(node) {\n const {\n type,\n tagName\n } = node;\n if (tagName === 'INPUT' && inputTypesWhitelist[type] && !node.readOnly) {\n return true;\n }\n if (tagName === 'TEXTAREA' && !node.readOnly) {\n return true;\n }\n if (node.isContentEditable) {\n return true;\n }\n return false;\n}\n\n/**\n * Keep track of our keyboard modality state with `hadKeyboardEvent`.\n * If the most recent user interaction was via the keyboard;\n * and the key press did not include a meta, alt/option, or control key;\n * then the modality is keyboard. Otherwise, the modality is not keyboard.\n * @param {KeyboardEvent} event\n */\nfunction handleKeyDown(event) {\n if (event.metaKey || event.altKey || event.ctrlKey) {\n return;\n }\n hadKeyboardEvent = true;\n}\n\n/**\n * If at any point a user clicks with a pointing device, ensure that we change\n * the modality away from keyboard.\n * This avoids the situation where a user presses a key on an already focused\n * element, and then clicks on a different element, focusing it with a\n * pointing device, while we still think we're in keyboard modality.\n */\nfunction handlePointerDown() {\n hadKeyboardEvent = false;\n}\nfunction handleVisibilityChange() {\n if (this.visibilityState === 'hidden') {\n // If the tab becomes active again, the browser will handle calling focus\n // on the element (Safari actually calls it twice).\n // If this tab change caused a blur on an element with focus-visible,\n // re-apply the class when the user switches back to the tab.\n if (hadFocusVisibleRecently) {\n hadKeyboardEvent = true;\n }\n }\n}\nfunction prepare(doc) {\n doc.addEventListener('keydown', handleKeyDown, true);\n doc.addEventListener('mousedown', handlePointerDown, true);\n doc.addEventListener('pointerdown', handlePointerDown, true);\n doc.addEventListener('touchstart', handlePointerDown, true);\n doc.addEventListener('visibilitychange', handleVisibilityChange, true);\n}\nexport function teardown(doc) {\n doc.removeEventListener('keydown', handleKeyDown, true);\n doc.removeEventListener('mousedown', handlePointerDown, true);\n doc.removeEventListener('pointerdown', handlePointerDown, true);\n doc.removeEventListener('touchstart', handlePointerDown, true);\n doc.removeEventListener('visibilitychange', handleVisibilityChange, true);\n}\nfunction isFocusVisible(event) {\n const {\n target\n } = event;\n try {\n return target.matches(':focus-visible');\n } catch (error) {\n // Browsers not implementing :focus-visible will throw a SyntaxError.\n // We use our own heuristic for those browsers.\n // Rethrow might be better if it's not the expected error but do we really\n // want to crash if focus-visible malfunctioned?\n }\n\n // No need for validFocusTarget check. The user does that by attaching it to\n // focusable events only.\n return hadKeyboardEvent || focusTriggersKeyboardModality(target);\n}\nexport default function useIsFocusVisible() {\n const ref = React.useCallback(node => {\n if (node != null) {\n prepare(node.ownerDocument);\n }\n }, []);\n const isFocusVisibleRef = React.useRef(false);\n\n /**\n * Should be called if a blur event is fired\n */\n function handleBlurVisible() {\n // checking against potential state variable does not suffice if we focus and blur synchronously.\n // React wouldn't have time to trigger a re-render so `focusVisible` would be stale.\n // Ideally we would adjust `isFocusVisible(event)` to look at `relatedTarget` for blur events.\n // This doesn't work in IE11 due to https://github.com/facebook/react/issues/3751\n // TODO: check again if React releases their internal changes to focus event handling (https://github.com/facebook/react/pull/19186).\n if (isFocusVisibleRef.current) {\n // To detect a tab/window switch, we look for a blur event followed\n // rapidly by a visibility change.\n // If we don't see a visibility change within 100ms, it's probably a\n // regular focus change.\n hadFocusVisibleRecently = true;\n hadFocusVisibleRecentlyTimeout.start(100, () => {\n hadFocusVisibleRecently = false;\n });\n isFocusVisibleRef.current = false;\n return true;\n }\n return false;\n }\n\n /**\n * Should be called if a blur event is fired\n */\n function handleFocusVisible(event) {\n if (isFocusVisible(event)) {\n isFocusVisibleRef.current = true;\n return true;\n }\n return false;\n }\n return {\n isFocusVisibleRef,\n onFocus: handleFocusVisible,\n onBlur: handleBlurVisible,\n ref\n };\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\n/**\n * Add keys, values of `defaultProps` that does not exist in `props`\n * @param {object} defaultProps\n * @param {object} props\n * @returns {object} resolved props\n */\nexport default function resolveProps(defaultProps, props) {\n const output = _extends({}, props);\n Object.keys(defaultProps).forEach(propName => {\n if (propName.toString().match(/^(components|slots)$/)) {\n output[propName] = _extends({}, defaultProps[propName], output[propName]);\n } else if (propName.toString().match(/^(componentsProps|slotProps)$/)) {\n const defaultSlotProps = defaultProps[propName] || {};\n const slotProps = props[propName];\n output[propName] = {};\n if (!slotProps || !Object.keys(slotProps)) {\n // Reduce the iteration if the slot props is empty\n output[propName] = defaultSlotProps;\n } else if (!defaultSlotProps || !Object.keys(defaultSlotProps)) {\n // Reduce the iteration if the default slot props is empty\n output[propName] = slotProps;\n } else {\n output[propName] = _extends({}, slotProps);\n Object.keys(defaultSlotProps).forEach(slotPropName => {\n output[propName][slotPropName] = resolveProps(defaultSlotProps[slotPropName], slotProps[slotPropName]);\n });\n }\n } else if (output[propName] === undefined) {\n output[propName] = defaultProps[propName];\n }\n });\n return output;\n}","export default function composeClasses(slots, getUtilityClass, classes = undefined) {\n const output = {};\n Object.keys(slots).forEach(\n // `Object.keys(slots)` can't be wider than `T` because we infer `T` from `slots`.\n // @ts-expect-error https://github.com/microsoft/TypeScript/pull/12253#issuecomment-263132208\n slot => {\n output[slot] = slots[slot].reduce((acc, key) => {\n if (key) {\n const utilityClass = getUtilityClass(key);\n if (utilityClass !== '') {\n acc.push(utilityClass);\n }\n if (classes && classes[key]) {\n acc.push(classes[key]);\n }\n }\n return acc;\n }, []).join(' ');\n });\n return output;\n}","const defaultGenerator = componentName => componentName;\nconst createClassNameGenerator = () => {\n let generate = defaultGenerator;\n return {\n configure(generator) {\n generate = generator;\n },\n generate(componentName) {\n return generate(componentName);\n },\n reset() {\n generate = defaultGenerator;\n }\n };\n};\nconst ClassNameGenerator = createClassNameGenerator();\nexport default ClassNameGenerator;","import ClassNameGenerator from '../ClassNameGenerator';\nexport const globalStateClasses = {\n active: 'active',\n checked: 'checked',\n completed: 'completed',\n disabled: 'disabled',\n error: 'error',\n expanded: 'expanded',\n focused: 'focused',\n focusVisible: 'focusVisible',\n open: 'open',\n readOnly: 'readOnly',\n required: 'required',\n selected: 'selected'\n};\nexport default function generateUtilityClass(componentName, slot, globalStatePrefix = 'Mui') {\n const globalStateClass = globalStateClasses[slot];\n return globalStateClass ? `${globalStatePrefix}-${globalStateClass}` : `${ClassNameGenerator.generate(componentName)}-${slot}`;\n}\nexport function isGlobalState(slot) {\n return globalStateClasses[slot] !== undefined;\n}","import generateUtilityClass from '../generateUtilityClass';\nexport default function generateUtilityClasses(componentName, slots, globalStatePrefix = 'Mui') {\n const result = {};\n slots.forEach(slot => {\n result[slot] = generateUtilityClass(componentName, slot, globalStatePrefix);\n });\n return result;\n}","function clamp(val, min = Number.MIN_SAFE_INTEGER, max = Number.MAX_SAFE_INTEGER) {\n return Math.max(min, Math.min(val, max));\n}\nexport default clamp;","export default function _objectWithoutPropertiesLoose(source, excluded) {\n if (source == null) return {};\n var target = {};\n var sourceKeys = Object.keys(source);\n var key, i;\n for (i = 0; i < sourceKeys.length; i++) {\n key = sourceKeys[i];\n if (excluded.indexOf(key) >= 0) continue;\n target[key] = source[key];\n }\n return target;\n}","import _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nconst _excluded = [\"values\", \"unit\", \"step\"];\n// Sorted ASC by size. That's important.\n// It can't be configured as it's used statically for propTypes.\nexport const breakpointKeys = ['xs', 'sm', 'md', 'lg', 'xl'];\nconst sortBreakpointsValues = values => {\n const breakpointsAsArray = Object.keys(values).map(key => ({\n key,\n val: values[key]\n })) || [];\n // Sort in ascending order\n breakpointsAsArray.sort((breakpoint1, breakpoint2) => breakpoint1.val - breakpoint2.val);\n return breakpointsAsArray.reduce((acc, obj) => {\n return _extends({}, acc, {\n [obj.key]: obj.val\n });\n }, {});\n};\n\n// Keep in mind that @media is inclusive by the CSS specification.\nexport default function createBreakpoints(breakpoints) {\n const {\n // The breakpoint **start** at this value.\n // For instance with the first breakpoint xs: [xs, sm).\n values = {\n xs: 0,\n // phone\n sm: 600,\n // tablet\n md: 900,\n // small laptop\n lg: 1200,\n // desktop\n xl: 1536 // large screen\n },\n unit = 'px',\n step = 5\n } = breakpoints,\n other = _objectWithoutPropertiesLoose(breakpoints, _excluded);\n const sortedValues = sortBreakpointsValues(values);\n const keys = Object.keys(sortedValues);\n function up(key) {\n const value = typeof values[key] === 'number' ? values[key] : key;\n return `@media (min-width:${value}${unit})`;\n }\n function down(key) {\n const value = typeof values[key] === 'number' ? values[key] : key;\n return `@media (max-width:${value - step / 100}${unit})`;\n }\n function between(start, end) {\n const endIndex = keys.indexOf(end);\n return `@media (min-width:${typeof values[start] === 'number' ? values[start] : start}${unit}) and ` + `(max-width:${(endIndex !== -1 && typeof values[keys[endIndex]] === 'number' ? values[keys[endIndex]] : end) - step / 100}${unit})`;\n }\n function only(key) {\n if (keys.indexOf(key) + 1 < keys.length) {\n return between(key, keys[keys.indexOf(key) + 1]);\n }\n return up(key);\n }\n function not(key) {\n // handle first and last key separately, for better readability\n const keyIndex = keys.indexOf(key);\n if (keyIndex === 0) {\n return up(keys[1]);\n }\n if (keyIndex === keys.length - 1) {\n return down(keys[keyIndex]);\n }\n return between(key, keys[keys.indexOf(key) + 1]).replace('@media', '@media not all and');\n }\n return _extends({\n keys,\n values: sortedValues,\n up,\n down,\n between,\n only,\n not,\n unit\n }, other);\n}","const shape = {\n borderRadius: 4\n};\nexport default shape;","import PropTypes from 'prop-types';\nconst responsivePropType = process.env.NODE_ENV !== 'production' ? PropTypes.oneOfType([PropTypes.number, PropTypes.string, PropTypes.object, PropTypes.array]) : {};\nexport default responsivePropType;","import deepmerge from '@mui/utils/deepmerge';\nfunction merge(acc, item) {\n if (!item) {\n return acc;\n }\n return deepmerge(acc, item, {\n clone: false // No need to clone deep, it's way faster.\n });\n}\nexport default merge;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport PropTypes from 'prop-types';\nimport deepmerge from '@mui/utils/deepmerge';\nimport merge from './merge';\n\n// The breakpoint **start** at this value.\n// For instance with the first breakpoint xs: [xs, sm[.\nexport const values = {\n xs: 0,\n // phone\n sm: 600,\n // tablet\n md: 900,\n // small laptop\n lg: 1200,\n // desktop\n xl: 1536 // large screen\n};\nconst defaultBreakpoints = {\n // Sorted ASC by size. That's important.\n // It can't be configured as it's used statically for propTypes.\n keys: ['xs', 'sm', 'md', 'lg', 'xl'],\n up: key => `@media (min-width:${values[key]}px)`\n};\nexport function handleBreakpoints(props, propValue, styleFromPropValue) {\n const theme = props.theme || {};\n if (Array.isArray(propValue)) {\n const themeBreakpoints = theme.breakpoints || defaultBreakpoints;\n return propValue.reduce((acc, item, index) => {\n acc[themeBreakpoints.up(themeBreakpoints.keys[index])] = styleFromPropValue(propValue[index]);\n return acc;\n }, {});\n }\n if (typeof propValue === 'object') {\n const themeBreakpoints = theme.breakpoints || defaultBreakpoints;\n return Object.keys(propValue).reduce((acc, breakpoint) => {\n // key is breakpoint\n if (Object.keys(themeBreakpoints.values || values).indexOf(breakpoint) !== -1) {\n const mediaKey = themeBreakpoints.up(breakpoint);\n acc[mediaKey] = styleFromPropValue(propValue[breakpoint], breakpoint);\n } else {\n const cssKey = breakpoint;\n acc[cssKey] = propValue[cssKey];\n }\n return acc;\n }, {});\n }\n const output = styleFromPropValue(propValue);\n return output;\n}\nfunction breakpoints(styleFunction) {\n // false positive\n // eslint-disable-next-line react/function-component-definition\n const newStyleFunction = props => {\n const theme = props.theme || {};\n const base = styleFunction(props);\n const themeBreakpoints = theme.breakpoints || defaultBreakpoints;\n const extended = themeBreakpoints.keys.reduce((acc, key) => {\n if (props[key]) {\n acc = acc || {};\n acc[themeBreakpoints.up(key)] = styleFunction(_extends({\n theme\n }, props[key]));\n }\n return acc;\n }, null);\n return merge(base, extended);\n };\n newStyleFunction.propTypes = process.env.NODE_ENV !== 'production' ? _extends({}, styleFunction.propTypes, {\n xs: PropTypes.object,\n sm: PropTypes.object,\n md: PropTypes.object,\n lg: PropTypes.object,\n xl: PropTypes.object\n }) : {};\n newStyleFunction.filterProps = ['xs', 'sm', 'md', 'lg', 'xl', ...styleFunction.filterProps];\n return newStyleFunction;\n}\nexport function createEmptyBreakpointObject(breakpointsInput = {}) {\n var _breakpointsInput$key;\n const breakpointsInOrder = (_breakpointsInput$key = breakpointsInput.keys) == null ? void 0 : _breakpointsInput$key.reduce((acc, key) => {\n const breakpointStyleKey = breakpointsInput.up(key);\n acc[breakpointStyleKey] = {};\n return acc;\n }, {});\n return breakpointsInOrder || {};\n}\nexport function removeUnusedBreakpoints(breakpointKeys, style) {\n return breakpointKeys.reduce((acc, key) => {\n const breakpointOutput = acc[key];\n const isBreakpointUnused = !breakpointOutput || Object.keys(breakpointOutput).length === 0;\n if (isBreakpointUnused) {\n delete acc[key];\n }\n return acc;\n }, style);\n}\nexport function mergeBreakpointsInOrder(breakpointsInput, ...styles) {\n const emptyBreakpoints = createEmptyBreakpointObject(breakpointsInput);\n const mergedOutput = [emptyBreakpoints, ...styles].reduce((prev, next) => deepmerge(prev, next), {});\n return removeUnusedBreakpoints(Object.keys(emptyBreakpoints), mergedOutput);\n}\n\n// compute base for responsive values; e.g.,\n// [1,2,3] => {xs: true, sm: true, md: true}\n// {xs: 1, sm: 2, md: 3} => {xs: true, sm: true, md: true}\nexport function computeBreakpointsBase(breakpointValues, themeBreakpoints) {\n // fixed value\n if (typeof breakpointValues !== 'object') {\n return {};\n }\n const base = {};\n const breakpointsKeys = Object.keys(themeBreakpoints);\n if (Array.isArray(breakpointValues)) {\n breakpointsKeys.forEach((breakpoint, i) => {\n if (i < breakpointValues.length) {\n base[breakpoint] = true;\n }\n });\n } else {\n breakpointsKeys.forEach(breakpoint => {\n if (breakpointValues[breakpoint] != null) {\n base[breakpoint] = true;\n }\n });\n }\n return base;\n}\nexport function resolveBreakpointValues({\n values: breakpointValues,\n breakpoints: themeBreakpoints,\n base: customBase\n}) {\n const base = customBase || computeBreakpointsBase(breakpointValues, themeBreakpoints);\n const keys = Object.keys(base);\n if (keys.length === 0) {\n return breakpointValues;\n }\n let previous;\n return keys.reduce((acc, breakpoint, i) => {\n if (Array.isArray(breakpointValues)) {\n acc[breakpoint] = breakpointValues[i] != null ? breakpointValues[i] : breakpointValues[previous];\n previous = i;\n } else if (typeof breakpointValues === 'object') {\n acc[breakpoint] = breakpointValues[breakpoint] != null ? breakpointValues[breakpoint] : breakpointValues[previous];\n previous = breakpoint;\n } else {\n acc[breakpoint] = breakpointValues;\n }\n return acc;\n }, {});\n}\nexport default breakpoints;","import capitalize from '@mui/utils/capitalize';\nimport responsivePropType from './responsivePropType';\nimport { handleBreakpoints } from './breakpoints';\nexport function getPath(obj, path, checkVars = true) {\n if (!path || typeof path !== 'string') {\n return null;\n }\n\n // Check if CSS variables are used\n if (obj && obj.vars && checkVars) {\n const val = `vars.${path}`.split('.').reduce((acc, item) => acc && acc[item] ? acc[item] : null, obj);\n if (val != null) {\n return val;\n }\n }\n return path.split('.').reduce((acc, item) => {\n if (acc && acc[item] != null) {\n return acc[item];\n }\n return null;\n }, obj);\n}\nexport function getStyleValue(themeMapping, transform, propValueFinal, userValue = propValueFinal) {\n let value;\n if (typeof themeMapping === 'function') {\n value = themeMapping(propValueFinal);\n } else if (Array.isArray(themeMapping)) {\n value = themeMapping[propValueFinal] || userValue;\n } else {\n value = getPath(themeMapping, propValueFinal) || userValue;\n }\n if (transform) {\n value = transform(value, userValue, themeMapping);\n }\n return value;\n}\nfunction style(options) {\n const {\n prop,\n cssProperty = options.prop,\n themeKey,\n transform\n } = options;\n\n // false positive\n // eslint-disable-next-line react/function-component-definition\n const fn = props => {\n if (props[prop] == null) {\n return null;\n }\n const propValue = props[prop];\n const theme = props.theme;\n const themeMapping = getPath(theme, themeKey) || {};\n const styleFromPropValue = propValueFinal => {\n let value = getStyleValue(themeMapping, transform, propValueFinal);\n if (propValueFinal === value && typeof propValueFinal === 'string') {\n // Haven't found value\n value = getStyleValue(themeMapping, transform, `${prop}${propValueFinal === 'default' ? '' : capitalize(propValueFinal)}`, propValueFinal);\n }\n if (cssProperty === false) {\n return value;\n }\n return {\n [cssProperty]: value\n };\n };\n return handleBreakpoints(props, propValue, styleFromPropValue);\n };\n fn.propTypes = process.env.NODE_ENV !== 'production' ? {\n [prop]: responsivePropType\n } : {};\n fn.filterProps = [prop];\n return fn;\n}\nexport default style;","export default function memoize(fn) {\n const cache = {};\n return arg => {\n if (cache[arg] === undefined) {\n cache[arg] = fn(arg);\n }\n return cache[arg];\n };\n}","import responsivePropType from './responsivePropType';\nimport { handleBreakpoints } from './breakpoints';\nimport { getPath } from './style';\nimport merge from './merge';\nimport memoize from './memoize';\nconst properties = {\n m: 'margin',\n p: 'padding'\n};\nconst directions = {\n t: 'Top',\n r: 'Right',\n b: 'Bottom',\n l: 'Left',\n x: ['Left', 'Right'],\n y: ['Top', 'Bottom']\n};\nconst aliases = {\n marginX: 'mx',\n marginY: 'my',\n paddingX: 'px',\n paddingY: 'py'\n};\n\n// memoize() impact:\n// From 300,000 ops/sec\n// To 350,000 ops/sec\nconst getCssProperties = memoize(prop => {\n // It's not a shorthand notation.\n if (prop.length > 2) {\n if (aliases[prop]) {\n prop = aliases[prop];\n } else {\n return [prop];\n }\n }\n const [a, b] = prop.split('');\n const property = properties[a];\n const direction = directions[b] || '';\n return Array.isArray(direction) ? direction.map(dir => property + dir) : [property + direction];\n});\nexport const marginKeys = ['m', 'mt', 'mr', 'mb', 'ml', 'mx', 'my', 'margin', 'marginTop', 'marginRight', 'marginBottom', 'marginLeft', 'marginX', 'marginY', 'marginInline', 'marginInlineStart', 'marginInlineEnd', 'marginBlock', 'marginBlockStart', 'marginBlockEnd'];\nexport const paddingKeys = ['p', 'pt', 'pr', 'pb', 'pl', 'px', 'py', 'padding', 'paddingTop', 'paddingRight', 'paddingBottom', 'paddingLeft', 'paddingX', 'paddingY', 'paddingInline', 'paddingInlineStart', 'paddingInlineEnd', 'paddingBlock', 'paddingBlockStart', 'paddingBlockEnd'];\nconst spacingKeys = [...marginKeys, ...paddingKeys];\nexport function createUnaryUnit(theme, themeKey, defaultValue, propName) {\n var _getPath;\n const themeSpacing = (_getPath = getPath(theme, themeKey, false)) != null ? _getPath : defaultValue;\n if (typeof themeSpacing === 'number') {\n return abs => {\n if (typeof abs === 'string') {\n return abs;\n }\n if (process.env.NODE_ENV !== 'production') {\n if (typeof abs !== 'number') {\n console.error(`MUI: Expected ${propName} argument to be a number or a string, got ${abs}.`);\n }\n }\n return themeSpacing * abs;\n };\n }\n if (Array.isArray(themeSpacing)) {\n return abs => {\n if (typeof abs === 'string') {\n return abs;\n }\n if (process.env.NODE_ENV !== 'production') {\n if (!Number.isInteger(abs)) {\n console.error([`MUI: The \\`theme.${themeKey}\\` array type cannot be combined with non integer values.` + `You should either use an integer value that can be used as index, or define the \\`theme.${themeKey}\\` as a number.`].join('\\n'));\n } else if (abs > themeSpacing.length - 1) {\n console.error([`MUI: The value provided (${abs}) overflows.`, `The supported values are: ${JSON.stringify(themeSpacing)}.`, `${abs} > ${themeSpacing.length - 1}, you need to add the missing values.`].join('\\n'));\n }\n }\n return themeSpacing[abs];\n };\n }\n if (typeof themeSpacing === 'function') {\n return themeSpacing;\n }\n if (process.env.NODE_ENV !== 'production') {\n console.error([`MUI: The \\`theme.${themeKey}\\` value (${themeSpacing}) is invalid.`, 'It should be a number, an array or a function.'].join('\\n'));\n }\n return () => undefined;\n}\nexport function createUnarySpacing(theme) {\n return createUnaryUnit(theme, 'spacing', 8, 'spacing');\n}\nexport function getValue(transformer, propValue) {\n if (typeof propValue === 'string' || propValue == null) {\n return propValue;\n }\n const abs = Math.abs(propValue);\n const transformed = transformer(abs);\n if (propValue >= 0) {\n return transformed;\n }\n if (typeof transformed === 'number') {\n return -transformed;\n }\n return `-${transformed}`;\n}\nexport function getStyleFromPropValue(cssProperties, transformer) {\n return propValue => cssProperties.reduce((acc, cssProperty) => {\n acc[cssProperty] = getValue(transformer, propValue);\n return acc;\n }, {});\n}\nfunction resolveCssProperty(props, keys, prop, transformer) {\n // Using a hash computation over an array iteration could be faster, but with only 28 items,\n // it's doesn't worth the bundle size.\n if (keys.indexOf(prop) === -1) {\n return null;\n }\n const cssProperties = getCssProperties(prop);\n const styleFromPropValue = getStyleFromPropValue(cssProperties, transformer);\n const propValue = props[prop];\n return handleBreakpoints(props, propValue, styleFromPropValue);\n}\nfunction style(props, keys) {\n const transformer = createUnarySpacing(props.theme);\n return Object.keys(props).map(prop => resolveCssProperty(props, keys, prop, transformer)).reduce(merge, {});\n}\nexport function margin(props) {\n return style(props, marginKeys);\n}\nmargin.propTypes = process.env.NODE_ENV !== 'production' ? marginKeys.reduce((obj, key) => {\n obj[key] = responsivePropType;\n return obj;\n}, {}) : {};\nmargin.filterProps = marginKeys;\nexport function padding(props) {\n return style(props, paddingKeys);\n}\npadding.propTypes = process.env.NODE_ENV !== 'production' ? paddingKeys.reduce((obj, key) => {\n obj[key] = responsivePropType;\n return obj;\n}, {}) : {};\npadding.filterProps = paddingKeys;\nfunction spacing(props) {\n return style(props, spacingKeys);\n}\nspacing.propTypes = process.env.NODE_ENV !== 'production' ? spacingKeys.reduce((obj, key) => {\n obj[key] = responsivePropType;\n return obj;\n}, {}) : {};\nspacing.filterProps = spacingKeys;\nexport default spacing;","import { createUnarySpacing } from '../spacing';\n\n// The different signatures imply different meaning for their arguments that can't be expressed structurally.\n// We express the difference with variable names.\n\nexport default function createSpacing(spacingInput = 8) {\n // Already transformed.\n if (spacingInput.mui) {\n return spacingInput;\n }\n\n // Material Design layouts are visually balanced. Most measurements align to an 8dp grid, which aligns both spacing and the overall layout.\n // Smaller components, such as icons, can align to a 4dp grid.\n // https://m2.material.io/design/layout/understanding-layout.html\n const transform = createUnarySpacing({\n spacing: spacingInput\n });\n const spacing = (...argsInput) => {\n if (process.env.NODE_ENV !== 'production') {\n if (!(argsInput.length <= 4)) {\n console.error(`MUI: Too many arguments provided, expected between 0 and 4, got ${argsInput.length}`);\n }\n }\n const args = argsInput.length === 0 ? [1] : argsInput;\n return args.map(argument => {\n const output = transform(argument);\n return typeof output === 'number' ? `${output}px` : output;\n }).join(' ');\n };\n spacing.mui = true;\n return spacing;\n}","import merge from './merge';\nfunction compose(...styles) {\n const handlers = styles.reduce((acc, style) => {\n style.filterProps.forEach(prop => {\n acc[prop] = style;\n });\n return acc;\n }, {});\n\n // false positive\n // eslint-disable-next-line react/function-component-definition\n const fn = props => {\n return Object.keys(props).reduce((acc, prop) => {\n if (handlers[prop]) {\n return merge(acc, handlers[prop](props));\n }\n return acc;\n }, {});\n };\n fn.propTypes = process.env.NODE_ENV !== 'production' ? styles.reduce((acc, style) => Object.assign(acc, style.propTypes), {}) : {};\n fn.filterProps = styles.reduce((acc, style) => acc.concat(style.filterProps), []);\n return fn;\n}\nexport default compose;","import responsivePropType from './responsivePropType';\nimport style from './style';\nimport compose from './compose';\nimport { createUnaryUnit, getValue } from './spacing';\nimport { handleBreakpoints } from './breakpoints';\nexport function borderTransform(value) {\n if (typeof value !== 'number') {\n return value;\n }\n return `${value}px solid`;\n}\nfunction createBorderStyle(prop, transform) {\n return style({\n prop,\n themeKey: 'borders',\n transform\n });\n}\nexport const border = createBorderStyle('border', borderTransform);\nexport const borderTop = createBorderStyle('borderTop', borderTransform);\nexport const borderRight = createBorderStyle('borderRight', borderTransform);\nexport const borderBottom = createBorderStyle('borderBottom', borderTransform);\nexport const borderLeft = createBorderStyle('borderLeft', borderTransform);\nexport const borderColor = createBorderStyle('borderColor');\nexport const borderTopColor = createBorderStyle('borderTopColor');\nexport const borderRightColor = createBorderStyle('borderRightColor');\nexport const borderBottomColor = createBorderStyle('borderBottomColor');\nexport const borderLeftColor = createBorderStyle('borderLeftColor');\nexport const outline = createBorderStyle('outline', borderTransform);\nexport const outlineColor = createBorderStyle('outlineColor');\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const borderRadius = props => {\n if (props.borderRadius !== undefined && props.borderRadius !== null) {\n const transformer = createUnaryUnit(props.theme, 'shape.borderRadius', 4, 'borderRadius');\n const styleFromPropValue = propValue => ({\n borderRadius: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.borderRadius, styleFromPropValue);\n }\n return null;\n};\nborderRadius.propTypes = process.env.NODE_ENV !== 'production' ? {\n borderRadius: responsivePropType\n} : {};\nborderRadius.filterProps = ['borderRadius'];\nconst borders = compose(border, borderTop, borderRight, borderBottom, borderLeft, borderColor, borderTopColor, borderRightColor, borderBottomColor, borderLeftColor, borderRadius, outline, outlineColor);\nexport default borders;","import style from './style';\nimport compose from './compose';\nimport { createUnaryUnit, getValue } from './spacing';\nimport { handleBreakpoints } from './breakpoints';\nimport responsivePropType from './responsivePropType';\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const gap = props => {\n if (props.gap !== undefined && props.gap !== null) {\n const transformer = createUnaryUnit(props.theme, 'spacing', 8, 'gap');\n const styleFromPropValue = propValue => ({\n gap: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.gap, styleFromPropValue);\n }\n return null;\n};\ngap.propTypes = process.env.NODE_ENV !== 'production' ? {\n gap: responsivePropType\n} : {};\ngap.filterProps = ['gap'];\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const columnGap = props => {\n if (props.columnGap !== undefined && props.columnGap !== null) {\n const transformer = createUnaryUnit(props.theme, 'spacing', 8, 'columnGap');\n const styleFromPropValue = propValue => ({\n columnGap: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.columnGap, styleFromPropValue);\n }\n return null;\n};\ncolumnGap.propTypes = process.env.NODE_ENV !== 'production' ? {\n columnGap: responsivePropType\n} : {};\ncolumnGap.filterProps = ['columnGap'];\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const rowGap = props => {\n if (props.rowGap !== undefined && props.rowGap !== null) {\n const transformer = createUnaryUnit(props.theme, 'spacing', 8, 'rowGap');\n const styleFromPropValue = propValue => ({\n rowGap: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.rowGap, styleFromPropValue);\n }\n return null;\n};\nrowGap.propTypes = process.env.NODE_ENV !== 'production' ? {\n rowGap: responsivePropType\n} : {};\nrowGap.filterProps = ['rowGap'];\nexport const gridColumn = style({\n prop: 'gridColumn'\n});\nexport const gridRow = style({\n prop: 'gridRow'\n});\nexport const gridAutoFlow = style({\n prop: 'gridAutoFlow'\n});\nexport const gridAutoColumns = style({\n prop: 'gridAutoColumns'\n});\nexport const gridAutoRows = style({\n prop: 'gridAutoRows'\n});\nexport const gridTemplateColumns = style({\n prop: 'gridTemplateColumns'\n});\nexport const gridTemplateRows = style({\n prop: 'gridTemplateRows'\n});\nexport const gridTemplateAreas = style({\n prop: 'gridTemplateAreas'\n});\nexport const gridArea = style({\n prop: 'gridArea'\n});\nconst grid = compose(gap, columnGap, rowGap, gridColumn, gridRow, gridAutoFlow, gridAutoColumns, gridAutoRows, gridTemplateColumns, gridTemplateRows, gridTemplateAreas, gridArea);\nexport default grid;","import style from './style';\nimport compose from './compose';\nexport function paletteTransform(value, userValue) {\n if (userValue === 'grey') {\n return userValue;\n }\n return value;\n}\nexport const color = style({\n prop: 'color',\n themeKey: 'palette',\n transform: paletteTransform\n});\nexport const bgcolor = style({\n prop: 'bgcolor',\n cssProperty: 'backgroundColor',\n themeKey: 'palette',\n transform: paletteTransform\n});\nexport const backgroundColor = style({\n prop: 'backgroundColor',\n themeKey: 'palette',\n transform: paletteTransform\n});\nconst palette = compose(color, bgcolor, backgroundColor);\nexport default palette;","import style from './style';\nimport compose from './compose';\nimport { handleBreakpoints, values as breakpointsValues } from './breakpoints';\nexport function sizingTransform(value) {\n return value <= 1 && value !== 0 ? `${value * 100}%` : value;\n}\nexport const width = style({\n prop: 'width',\n transform: sizingTransform\n});\nexport const maxWidth = props => {\n if (props.maxWidth !== undefined && props.maxWidth !== null) {\n const styleFromPropValue = propValue => {\n var _props$theme, _props$theme2;\n const breakpoint = ((_props$theme = props.theme) == null || (_props$theme = _props$theme.breakpoints) == null || (_props$theme = _props$theme.values) == null ? void 0 : _props$theme[propValue]) || breakpointsValues[propValue];\n if (!breakpoint) {\n return {\n maxWidth: sizingTransform(propValue)\n };\n }\n if (((_props$theme2 = props.theme) == null || (_props$theme2 = _props$theme2.breakpoints) == null ? void 0 : _props$theme2.unit) !== 'px') {\n return {\n maxWidth: `${breakpoint}${props.theme.breakpoints.unit}`\n };\n }\n return {\n maxWidth: breakpoint\n };\n };\n return handleBreakpoints(props, props.maxWidth, styleFromPropValue);\n }\n return null;\n};\nmaxWidth.filterProps = ['maxWidth'];\nexport const minWidth = style({\n prop: 'minWidth',\n transform: sizingTransform\n});\nexport const height = style({\n prop: 'height',\n transform: sizingTransform\n});\nexport const maxHeight = style({\n prop: 'maxHeight',\n transform: sizingTransform\n});\nexport const minHeight = style({\n prop: 'minHeight',\n transform: sizingTransform\n});\nexport const sizeWidth = style({\n prop: 'size',\n cssProperty: 'width',\n transform: sizingTransform\n});\nexport const sizeHeight = style({\n prop: 'size',\n cssProperty: 'height',\n transform: sizingTransform\n});\nexport const boxSizing = style({\n prop: 'boxSizing'\n});\nconst sizing = compose(width, maxWidth, minWidth, height, maxHeight, minHeight, boxSizing);\nexport default sizing;","import { padding, margin } from '../spacing';\nimport { borderRadius, borderTransform } from '../borders';\nimport { gap, rowGap, columnGap } from '../cssGrid';\nimport { paletteTransform } from '../palette';\nimport { maxWidth, sizingTransform } from '../sizing';\nconst defaultSxConfig = {\n // borders\n border: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderTop: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderRight: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderBottom: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderLeft: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderColor: {\n themeKey: 'palette'\n },\n borderTopColor: {\n themeKey: 'palette'\n },\n borderRightColor: {\n themeKey: 'palette'\n },\n borderBottomColor: {\n themeKey: 'palette'\n },\n borderLeftColor: {\n themeKey: 'palette'\n },\n outline: {\n themeKey: 'borders',\n transform: borderTransform\n },\n outlineColor: {\n themeKey: 'palette'\n },\n borderRadius: {\n themeKey: 'shape.borderRadius',\n style: borderRadius\n },\n // palette\n color: {\n themeKey: 'palette',\n transform: paletteTransform\n },\n bgcolor: {\n themeKey: 'palette',\n cssProperty: 'backgroundColor',\n transform: paletteTransform\n },\n backgroundColor: {\n themeKey: 'palette',\n transform: paletteTransform\n },\n // spacing\n p: {\n style: padding\n },\n pt: {\n style: padding\n },\n pr: {\n style: padding\n },\n pb: {\n style: padding\n },\n pl: {\n style: padding\n },\n px: {\n style: padding\n },\n py: {\n style: padding\n },\n padding: {\n style: padding\n },\n paddingTop: {\n style: padding\n },\n paddingRight: {\n style: padding\n },\n paddingBottom: {\n style: padding\n },\n paddingLeft: {\n style: padding\n },\n paddingX: {\n style: padding\n },\n paddingY: {\n style: padding\n },\n paddingInline: {\n style: padding\n },\n paddingInlineStart: {\n style: padding\n },\n paddingInlineEnd: {\n style: padding\n },\n paddingBlock: {\n style: padding\n },\n paddingBlockStart: {\n style: padding\n },\n paddingBlockEnd: {\n style: padding\n },\n m: {\n style: margin\n },\n mt: {\n style: margin\n },\n mr: {\n style: margin\n },\n mb: {\n style: margin\n },\n ml: {\n style: margin\n },\n mx: {\n style: margin\n },\n my: {\n style: margin\n },\n margin: {\n style: margin\n },\n marginTop: {\n style: margin\n },\n marginRight: {\n style: margin\n },\n marginBottom: {\n style: margin\n },\n marginLeft: {\n style: margin\n },\n marginX: {\n style: margin\n },\n marginY: {\n style: margin\n },\n marginInline: {\n style: margin\n },\n marginInlineStart: {\n style: margin\n },\n marginInlineEnd: {\n style: margin\n },\n marginBlock: {\n style: margin\n },\n marginBlockStart: {\n style: margin\n },\n marginBlockEnd: {\n style: margin\n },\n // display\n displayPrint: {\n cssProperty: false,\n transform: value => ({\n '@media print': {\n display: value\n }\n })\n },\n display: {},\n overflow: {},\n textOverflow: {},\n visibility: {},\n whiteSpace: {},\n // flexbox\n flexBasis: {},\n flexDirection: {},\n flexWrap: {},\n justifyContent: {},\n alignItems: {},\n alignContent: {},\n order: {},\n flex: {},\n flexGrow: {},\n flexShrink: {},\n alignSelf: {},\n justifyItems: {},\n justifySelf: {},\n // grid\n gap: {\n style: gap\n },\n rowGap: {\n style: rowGap\n },\n columnGap: {\n style: columnGap\n },\n gridColumn: {},\n gridRow: {},\n gridAutoFlow: {},\n gridAutoColumns: {},\n gridAutoRows: {},\n gridTemplateColumns: {},\n gridTemplateRows: {},\n gridTemplateAreas: {},\n gridArea: {},\n // positions\n position: {},\n zIndex: {\n themeKey: 'zIndex'\n },\n top: {},\n right: {},\n bottom: {},\n left: {},\n // shadows\n boxShadow: {\n themeKey: 'shadows'\n },\n // sizing\n width: {\n transform: sizingTransform\n },\n maxWidth: {\n style: maxWidth\n },\n minWidth: {\n transform: sizingTransform\n },\n height: {\n transform: sizingTransform\n },\n maxHeight: {\n transform: sizingTransform\n },\n minHeight: {\n transform: sizingTransform\n },\n boxSizing: {},\n // typography\n fontFamily: {\n themeKey: 'typography'\n },\n fontSize: {\n themeKey: 'typography'\n },\n fontStyle: {\n themeKey: 'typography'\n },\n fontWeight: {\n themeKey: 'typography'\n },\n letterSpacing: {},\n textTransform: {},\n lineHeight: {},\n textAlign: {},\n typography: {\n cssProperty: false,\n themeKey: 'typography'\n }\n};\nexport default defaultSxConfig;","import capitalize from '@mui/utils/capitalize';\nimport merge from '../merge';\nimport { getPath, getStyleValue as getValue } from '../style';\nimport { handleBreakpoints, createEmptyBreakpointObject, removeUnusedBreakpoints } from '../breakpoints';\nimport defaultSxConfig from './defaultSxConfig';\nfunction objectsHaveSameKeys(...objects) {\n const allKeys = objects.reduce((keys, object) => keys.concat(Object.keys(object)), []);\n const union = new Set(allKeys);\n return objects.every(object => union.size === Object.keys(object).length);\n}\nfunction callIfFn(maybeFn, arg) {\n return typeof maybeFn === 'function' ? maybeFn(arg) : maybeFn;\n}\n\n// eslint-disable-next-line @typescript-eslint/naming-convention\nexport function unstable_createStyleFunctionSx() {\n function getThemeValue(prop, val, theme, config) {\n const props = {\n [prop]: val,\n theme\n };\n const options = config[prop];\n if (!options) {\n return {\n [prop]: val\n };\n }\n const {\n cssProperty = prop,\n themeKey,\n transform,\n style\n } = options;\n if (val == null) {\n return null;\n }\n\n // TODO v6: remove, see https://github.com/mui/material-ui/pull/38123\n if (themeKey === 'typography' && val === 'inherit') {\n return {\n [prop]: val\n };\n }\n const themeMapping = getPath(theme, themeKey) || {};\n if (style) {\n return style(props);\n }\n const styleFromPropValue = propValueFinal => {\n let value = getValue(themeMapping, transform, propValueFinal);\n if (propValueFinal === value && typeof propValueFinal === 'string') {\n // Haven't found value\n value = getValue(themeMapping, transform, `${prop}${propValueFinal === 'default' ? '' : capitalize(propValueFinal)}`, propValueFinal);\n }\n if (cssProperty === false) {\n return value;\n }\n return {\n [cssProperty]: value\n };\n };\n return handleBreakpoints(props, val, styleFromPropValue);\n }\n function styleFunctionSx(props) {\n var _theme$unstable_sxCon;\n const {\n sx,\n theme = {}\n } = props || {};\n if (!sx) {\n return null; // Emotion & styled-components will neglect null\n }\n const config = (_theme$unstable_sxCon = theme.unstable_sxConfig) != null ? _theme$unstable_sxCon : defaultSxConfig;\n\n /*\n * Receive `sxInput` as object or callback\n * and then recursively check keys & values to create media query object styles.\n * (the result will be used in `styled`)\n */\n function traverse(sxInput) {\n let sxObject = sxInput;\n if (typeof sxInput === 'function') {\n sxObject = sxInput(theme);\n } else if (typeof sxInput !== 'object') {\n // value\n return sxInput;\n }\n if (!sxObject) {\n return null;\n }\n const emptyBreakpoints = createEmptyBreakpointObject(theme.breakpoints);\n const breakpointsKeys = Object.keys(emptyBreakpoints);\n let css = emptyBreakpoints;\n Object.keys(sxObject).forEach(styleKey => {\n const value = callIfFn(sxObject[styleKey], theme);\n if (value !== null && value !== undefined) {\n if (typeof value === 'object') {\n if (config[styleKey]) {\n css = merge(css, getThemeValue(styleKey, value, theme, config));\n } else {\n const breakpointsValues = handleBreakpoints({\n theme\n }, value, x => ({\n [styleKey]: x\n }));\n if (objectsHaveSameKeys(breakpointsValues, value)) {\n css[styleKey] = styleFunctionSx({\n sx: value,\n theme\n });\n } else {\n css = merge(css, breakpointsValues);\n }\n }\n } else {\n css = merge(css, getThemeValue(styleKey, value, theme, config));\n }\n }\n });\n return removeUnusedBreakpoints(breakpointsKeys, css);\n }\n return Array.isArray(sx) ? sx.map(traverse) : traverse(sx);\n }\n return styleFunctionSx;\n}\nconst styleFunctionSx = unstable_createStyleFunctionSx();\nstyleFunctionSx.filterProps = ['sx'];\nexport default styleFunctionSx;","/**\n * A universal utility to style components with multiple color modes. Always use it from the theme object.\n * It works with:\n * - [Basic theme](https://mui.com/material-ui/customization/dark-mode/)\n * - [CSS theme variables](https://mui.com/material-ui/experimental-api/css-theme-variables/overview/)\n * - Zero-runtime engine\n *\n * Tips: Use an array over object spread and place `theme.applyStyles()` last.\n *\n * ✅ [{ background: '#e5e5e5' }, theme.applyStyles('dark', { background: '#1c1c1c' })]\n *\n * 🚫 { background: '#e5e5e5', ...theme.applyStyles('dark', { background: '#1c1c1c' })}\n *\n * @example\n * 1. using with `styled`:\n * ```jsx\n * const Component = styled('div')(({ theme }) => [\n * { background: '#e5e5e5' },\n * theme.applyStyles('dark', {\n * background: '#1c1c1c',\n * color: '#fff',\n * }),\n * ]);\n * ```\n *\n * @example\n * 2. using with `sx` prop:\n * ```jsx\n * [\n * { background: '#e5e5e5' },\n * theme.applyStyles('dark', {\n * background: '#1c1c1c',\n * color: '#fff',\n * }),\n * ]}\n * />\n * ```\n *\n * @example\n * 3. theming a component:\n * ```jsx\n * extendTheme({\n * components: {\n * MuiButton: {\n * styleOverrides: {\n * root: ({ theme }) => [\n * { background: '#e5e5e5' },\n * theme.applyStyles('dark', {\n * background: '#1c1c1c',\n * color: '#fff',\n * }),\n * ],\n * },\n * }\n * }\n * })\n *```\n */\nexport default function applyStyles(key, styles) {\n // @ts-expect-error this is 'any' type\n const theme = this;\n if (theme.vars && typeof theme.getColorSchemeSelector === 'function') {\n // If CssVarsProvider is used as a provider,\n // returns '* :where([data-mui-color-scheme=\"light|dark\"]) &'\n const selector = theme.getColorSchemeSelector(key).replace(/(\\[[^\\]]+\\])/, '*:where($1)');\n return {\n [selector]: styles\n };\n }\n if (theme.palette.mode === key) {\n return styles;\n }\n return {};\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"breakpoints\", \"palette\", \"spacing\", \"shape\"];\nimport deepmerge from '@mui/utils/deepmerge';\nimport createBreakpoints from './createBreakpoints';\nimport shape from './shape';\nimport createSpacing from './createSpacing';\nimport styleFunctionSx from '../styleFunctionSx/styleFunctionSx';\nimport defaultSxConfig from '../styleFunctionSx/defaultSxConfig';\nimport applyStyles from './applyStyles';\nfunction createTheme(options = {}, ...args) {\n const {\n breakpoints: breakpointsInput = {},\n palette: paletteInput = {},\n spacing: spacingInput,\n shape: shapeInput = {}\n } = options,\n other = _objectWithoutPropertiesLoose(options, _excluded);\n const breakpoints = createBreakpoints(breakpointsInput);\n const spacing = createSpacing(spacingInput);\n let muiTheme = deepmerge({\n breakpoints,\n direction: 'ltr',\n components: {},\n // Inject component definitions.\n palette: _extends({\n mode: 'light'\n }, paletteInput),\n spacing,\n shape: _extends({}, shape, shapeInput)\n }, other);\n muiTheme.applyStyles = applyStyles;\n muiTheme = args.reduce((acc, argument) => deepmerge(acc, argument), muiTheme);\n muiTheme.unstable_sxConfig = _extends({}, defaultSxConfig, other == null ? void 0 : other.unstable_sxConfig);\n muiTheme.unstable_sx = function sx(props) {\n return styleFunctionSx({\n sx: props,\n theme: this\n });\n };\n return muiTheme;\n}\nexport default createTheme;","'use client';\n\nimport * as React from 'react';\nimport { ThemeContext } from '@mui/styled-engine';\nfunction isObjectEmpty(obj) {\n return Object.keys(obj).length === 0;\n}\nfunction useTheme(defaultTheme = null) {\n const contextTheme = React.useContext(ThemeContext);\n return !contextTheme || isObjectEmpty(contextTheme) ? defaultTheme : contextTheme;\n}\nexport default useTheme;","'use client';\n\nimport createTheme from './createTheme';\nimport useThemeWithoutDefault from './useThemeWithoutDefault';\nexport const systemDefaultTheme = createTheme();\nfunction useTheme(defaultTheme = systemDefaultTheme) {\n return useThemeWithoutDefault(defaultTheme);\n}\nexport default useTheme;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"ownerState\"],\n _excluded2 = [\"variants\"],\n _excluded3 = [\"name\", \"slot\", \"skipVariantsResolver\", \"skipSx\", \"overridesResolver\"];\n/* eslint-disable no-underscore-dangle */\nimport styledEngineStyled, { internal_processStyles as processStyles } from '@mui/styled-engine';\nimport { isPlainObject } from '@mui/utils/deepmerge';\nimport capitalize from '@mui/utils/capitalize';\nimport getDisplayName from '@mui/utils/getDisplayName';\nimport createTheme from './createTheme';\nimport styleFunctionSx from './styleFunctionSx';\nfunction isEmpty(obj) {\n return Object.keys(obj).length === 0;\n}\n\n// https://github.com/emotion-js/emotion/blob/26ded6109fcd8ca9875cc2ce4564fee678a3f3c5/packages/styled/src/utils.js#L40\nfunction isStringTag(tag) {\n return typeof tag === 'string' &&\n // 96 is one less than the char code\n // for \"a\" so this is checking that\n // it's a lowercase character\n tag.charCodeAt(0) > 96;\n}\n\n// Update /system/styled/#api in case if this changes\nexport function shouldForwardProp(prop) {\n return prop !== 'ownerState' && prop !== 'theme' && prop !== 'sx' && prop !== 'as';\n}\nexport const systemDefaultTheme = createTheme();\nconst lowercaseFirstLetter = string => {\n if (!string) {\n return string;\n }\n return string.charAt(0).toLowerCase() + string.slice(1);\n};\nfunction resolveTheme({\n defaultTheme,\n theme,\n themeId\n}) {\n return isEmpty(theme) ? defaultTheme : theme[themeId] || theme;\n}\nfunction defaultOverridesResolver(slot) {\n if (!slot) {\n return null;\n }\n return (props, styles) => styles[slot];\n}\nfunction processStyleArg(callableStyle, _ref) {\n let {\n ownerState\n } = _ref,\n props = _objectWithoutPropertiesLoose(_ref, _excluded);\n const resolvedStylesArg = typeof callableStyle === 'function' ? callableStyle(_extends({\n ownerState\n }, props)) : callableStyle;\n if (Array.isArray(resolvedStylesArg)) {\n return resolvedStylesArg.flatMap(resolvedStyle => processStyleArg(resolvedStyle, _extends({\n ownerState\n }, props)));\n }\n if (!!resolvedStylesArg && typeof resolvedStylesArg === 'object' && Array.isArray(resolvedStylesArg.variants)) {\n const {\n variants = []\n } = resolvedStylesArg,\n otherStyles = _objectWithoutPropertiesLoose(resolvedStylesArg, _excluded2);\n let result = otherStyles;\n variants.forEach(variant => {\n let isMatch = true;\n if (typeof variant.props === 'function') {\n isMatch = variant.props(_extends({\n ownerState\n }, props, ownerState));\n } else {\n Object.keys(variant.props).forEach(key => {\n if ((ownerState == null ? void 0 : ownerState[key]) !== variant.props[key] && props[key] !== variant.props[key]) {\n isMatch = false;\n }\n });\n }\n if (isMatch) {\n if (!Array.isArray(result)) {\n result = [result];\n }\n result.push(typeof variant.style === 'function' ? variant.style(_extends({\n ownerState\n }, props, ownerState)) : variant.style);\n }\n });\n return result;\n }\n return resolvedStylesArg;\n}\nexport default function createStyled(input = {}) {\n const {\n themeId,\n defaultTheme = systemDefaultTheme,\n rootShouldForwardProp = shouldForwardProp,\n slotShouldForwardProp = shouldForwardProp\n } = input;\n const systemSx = props => {\n return styleFunctionSx(_extends({}, props, {\n theme: resolveTheme(_extends({}, props, {\n defaultTheme,\n themeId\n }))\n }));\n };\n systemSx.__mui_systemSx = true;\n return (tag, inputOptions = {}) => {\n // Filter out the `sx` style function from the previous styled component to prevent unnecessary styles generated by the composite components.\n processStyles(tag, styles => styles.filter(style => !(style != null && style.__mui_systemSx)));\n const {\n name: componentName,\n slot: componentSlot,\n skipVariantsResolver: inputSkipVariantsResolver,\n skipSx: inputSkipSx,\n // TODO v6: remove `lowercaseFirstLetter()` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n overridesResolver = defaultOverridesResolver(lowercaseFirstLetter(componentSlot))\n } = inputOptions,\n options = _objectWithoutPropertiesLoose(inputOptions, _excluded3);\n\n // if skipVariantsResolver option is defined, take the value, otherwise, true for root and false for other slots.\n const skipVariantsResolver = inputSkipVariantsResolver !== undefined ? inputSkipVariantsResolver :\n // TODO v6: remove `Root` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n componentSlot && componentSlot !== 'Root' && componentSlot !== 'root' || false;\n const skipSx = inputSkipSx || false;\n let label;\n if (process.env.NODE_ENV !== 'production') {\n if (componentName) {\n // TODO v6: remove `lowercaseFirstLetter()` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n label = `${componentName}-${lowercaseFirstLetter(componentSlot || 'Root')}`;\n }\n }\n let shouldForwardPropOption = shouldForwardProp;\n\n // TODO v6: remove `Root` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n if (componentSlot === 'Root' || componentSlot === 'root') {\n shouldForwardPropOption = rootShouldForwardProp;\n } else if (componentSlot) {\n // any other slot specified\n shouldForwardPropOption = slotShouldForwardProp;\n } else if (isStringTag(tag)) {\n // for string (html) tag, preserve the behavior in emotion & styled-components.\n shouldForwardPropOption = undefined;\n }\n const defaultStyledResolver = styledEngineStyled(tag, _extends({\n shouldForwardProp: shouldForwardPropOption,\n label\n }, options));\n const transformStyleArg = stylesArg => {\n // On the server Emotion doesn't use React.forwardRef for creating components, so the created\n // component stays as a function. This condition makes sure that we do not interpolate functions\n // which are basically components used as a selectors.\n if (typeof stylesArg === 'function' && stylesArg.__emotion_real !== stylesArg || isPlainObject(stylesArg)) {\n return props => processStyleArg(stylesArg, _extends({}, props, {\n theme: resolveTheme({\n theme: props.theme,\n defaultTheme,\n themeId\n })\n }));\n }\n return stylesArg;\n };\n const muiStyledResolver = (styleArg, ...expressions) => {\n let transformedStyleArg = transformStyleArg(styleArg);\n const expressionsWithDefaultTheme = expressions ? expressions.map(transformStyleArg) : [];\n if (componentName && overridesResolver) {\n expressionsWithDefaultTheme.push(props => {\n const theme = resolveTheme(_extends({}, props, {\n defaultTheme,\n themeId\n }));\n if (!theme.components || !theme.components[componentName] || !theme.components[componentName].styleOverrides) {\n return null;\n }\n const styleOverrides = theme.components[componentName].styleOverrides;\n const resolvedStyleOverrides = {};\n // TODO: v7 remove iteration and use `resolveStyleArg(styleOverrides[slot])` directly\n Object.entries(styleOverrides).forEach(([slotKey, slotStyle]) => {\n resolvedStyleOverrides[slotKey] = processStyleArg(slotStyle, _extends({}, props, {\n theme\n }));\n });\n return overridesResolver(props, resolvedStyleOverrides);\n });\n }\n if (componentName && !skipVariantsResolver) {\n expressionsWithDefaultTheme.push(props => {\n var _theme$components;\n const theme = resolveTheme(_extends({}, props, {\n defaultTheme,\n themeId\n }));\n const themeVariants = theme == null || (_theme$components = theme.components) == null || (_theme$components = _theme$components[componentName]) == null ? void 0 : _theme$components.variants;\n return processStyleArg({\n variants: themeVariants\n }, _extends({}, props, {\n theme\n }));\n });\n }\n if (!skipSx) {\n expressionsWithDefaultTheme.push(systemSx);\n }\n const numOfCustomFnsApplied = expressionsWithDefaultTheme.length - expressions.length;\n if (Array.isArray(styleArg) && numOfCustomFnsApplied > 0) {\n const placeholders = new Array(numOfCustomFnsApplied).fill('');\n // If the type is array, than we need to add placeholders in the template for the overrides, variants and the sx styles.\n transformedStyleArg = [...styleArg, ...placeholders];\n transformedStyleArg.raw = [...styleArg.raw, ...placeholders];\n }\n const Component = defaultStyledResolver(transformedStyleArg, ...expressionsWithDefaultTheme);\n if (process.env.NODE_ENV !== 'production') {\n let displayName;\n if (componentName) {\n displayName = `${componentName}${capitalize(componentSlot || '')}`;\n }\n if (displayName === undefined) {\n displayName = `Styled(${getDisplayName(tag)})`;\n }\n Component.displayName = displayName;\n }\n if (tag.muiName) {\n Component.muiName = tag.muiName;\n }\n return Component;\n };\n if (defaultStyledResolver.withConfig) {\n muiStyledResolver.withConfig = defaultStyledResolver.withConfig;\n }\n return muiStyledResolver;\n };\n}","import resolveProps from '@mui/utils/resolveProps';\nexport default function getThemeProps(params) {\n const {\n theme,\n name,\n props\n } = params;\n if (!theme || !theme.components || !theme.components[name] || !theme.components[name].defaultProps) {\n return props;\n }\n return resolveProps(theme.components[name].defaultProps, props);\n}","'use client';\n\nimport getThemeProps from './getThemeProps';\nimport useTheme from '../useTheme';\nexport default function useThemeProps({\n props,\n name,\n defaultTheme,\n themeId\n}) {\n let theme = useTheme(defaultTheme);\n if (themeId) {\n theme = theme[themeId] || theme;\n }\n const mergedProps = getThemeProps({\n theme,\n name,\n props\n });\n return mergedProps;\n}","import _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\n/* eslint-disable @typescript-eslint/naming-convention */\nimport clamp from '@mui/utils/clamp';\n/**\n * Returns a number whose value is limited to the given range.\n * @param {number} value The value to be clamped\n * @param {number} min The lower boundary of the output range\n * @param {number} max The upper boundary of the output range\n * @returns {number} A number in the range [min, max]\n */\nfunction clampWrapper(value, min = 0, max = 1) {\n if (process.env.NODE_ENV !== 'production') {\n if (value < min || value > max) {\n console.error(`MUI: The value provided ${value} is out of range [${min}, ${max}].`);\n }\n }\n return clamp(value, min, max);\n}\n\n/**\n * Converts a color from CSS hex format to CSS rgb format.\n * @param {string} color - Hex color, i.e. #nnn or #nnnnnn\n * @returns {string} A CSS rgb color string\n */\nexport function hexToRgb(color) {\n color = color.slice(1);\n const re = new RegExp(`.{1,${color.length >= 6 ? 2 : 1}}`, 'g');\n let colors = color.match(re);\n if (colors && colors[0].length === 1) {\n colors = colors.map(n => n + n);\n }\n return colors ? `rgb${colors.length === 4 ? 'a' : ''}(${colors.map((n, index) => {\n return index < 3 ? parseInt(n, 16) : Math.round(parseInt(n, 16) / 255 * 1000) / 1000;\n }).join(', ')})` : '';\n}\nfunction intToHex(int) {\n const hex = int.toString(16);\n return hex.length === 1 ? `0${hex}` : hex;\n}\n\n/**\n * Returns an object with the type and values of a color.\n *\n * Note: Does not support rgb % values.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @returns {object} - A MUI color object: {type: string, values: number[]}\n */\nexport function decomposeColor(color) {\n // Idempotent\n if (color.type) {\n return color;\n }\n if (color.charAt(0) === '#') {\n return decomposeColor(hexToRgb(color));\n }\n const marker = color.indexOf('(');\n const type = color.substring(0, marker);\n if (['rgb', 'rgba', 'hsl', 'hsla', 'color'].indexOf(type) === -1) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: Unsupported \\`${color}\\` color.\nThe following formats are supported: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color().` : _formatMuiErrorMessage(9, color));\n }\n let values = color.substring(marker + 1, color.length - 1);\n let colorSpace;\n if (type === 'color') {\n values = values.split(' ');\n colorSpace = values.shift();\n if (values.length === 4 && values[3].charAt(0) === '/') {\n values[3] = values[3].slice(1);\n }\n if (['srgb', 'display-p3', 'a98-rgb', 'prophoto-rgb', 'rec-2020'].indexOf(colorSpace) === -1) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: unsupported \\`${colorSpace}\\` color space.\nThe following color spaces are supported: srgb, display-p3, a98-rgb, prophoto-rgb, rec-2020.` : _formatMuiErrorMessage(10, colorSpace));\n }\n } else {\n values = values.split(',');\n }\n values = values.map(value => parseFloat(value));\n return {\n type,\n values,\n colorSpace\n };\n}\n\n/**\n * Returns a channel created from the input color.\n *\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @returns {string} - The channel for the color, that can be used in rgba or hsla colors\n */\nexport const colorChannel = color => {\n const decomposedColor = decomposeColor(color);\n return decomposedColor.values.slice(0, 3).map((val, idx) => decomposedColor.type.indexOf('hsl') !== -1 && idx !== 0 ? `${val}%` : val).join(' ');\n};\nexport const private_safeColorChannel = (color, warning) => {\n try {\n return colorChannel(color);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n};\n\n/**\n * Converts a color object with type and values to a string.\n * @param {object} color - Decomposed color\n * @param {string} color.type - One of: 'rgb', 'rgba', 'hsl', 'hsla', 'color'\n * @param {array} color.values - [n,n,n] or [n,n,n,n]\n * @returns {string} A CSS color string\n */\nexport function recomposeColor(color) {\n const {\n type,\n colorSpace\n } = color;\n let {\n values\n } = color;\n if (type.indexOf('rgb') !== -1) {\n // Only convert the first 3 values to int (i.e. not alpha)\n values = values.map((n, i) => i < 3 ? parseInt(n, 10) : n);\n } else if (type.indexOf('hsl') !== -1) {\n values[1] = `${values[1]}%`;\n values[2] = `${values[2]}%`;\n }\n if (type.indexOf('color') !== -1) {\n values = `${colorSpace} ${values.join(' ')}`;\n } else {\n values = `${values.join(', ')}`;\n }\n return `${type}(${values})`;\n}\n\n/**\n * Converts a color from CSS rgb format to CSS hex format.\n * @param {string} color - RGB color, i.e. rgb(n, n, n)\n * @returns {string} A CSS rgb color string, i.e. #nnnnnn\n */\nexport function rgbToHex(color) {\n // Idempotent\n if (color.indexOf('#') === 0) {\n return color;\n }\n const {\n values\n } = decomposeColor(color);\n return `#${values.map((n, i) => intToHex(i === 3 ? Math.round(255 * n) : n)).join('')}`;\n}\n\n/**\n * Converts a color from hsl format to rgb format.\n * @param {string} color - HSL color values\n * @returns {string} rgb color values\n */\nexport function hslToRgb(color) {\n color = decomposeColor(color);\n const {\n values\n } = color;\n const h = values[0];\n const s = values[1] / 100;\n const l = values[2] / 100;\n const a = s * Math.min(l, 1 - l);\n const f = (n, k = (n + h / 30) % 12) => l - a * Math.max(Math.min(k - 3, 9 - k, 1), -1);\n let type = 'rgb';\n const rgb = [Math.round(f(0) * 255), Math.round(f(8) * 255), Math.round(f(4) * 255)];\n if (color.type === 'hsla') {\n type += 'a';\n rgb.push(values[3]);\n }\n return recomposeColor({\n type,\n values: rgb\n });\n}\n/**\n * The relative brightness of any point in a color space,\n * normalized to 0 for darkest black and 1 for lightest white.\n *\n * Formula: https://www.w3.org/TR/WCAG20-TECHS/G17.html#G17-tests\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @returns {number} The relative brightness of the color in the range 0 - 1\n */\nexport function getLuminance(color) {\n color = decomposeColor(color);\n let rgb = color.type === 'hsl' || color.type === 'hsla' ? decomposeColor(hslToRgb(color)).values : color.values;\n rgb = rgb.map(val => {\n if (color.type !== 'color') {\n val /= 255; // normalized\n }\n return val <= 0.03928 ? val / 12.92 : ((val + 0.055) / 1.055) ** 2.4;\n });\n\n // Truncate at 3 digits\n return Number((0.2126 * rgb[0] + 0.7152 * rgb[1] + 0.0722 * rgb[2]).toFixed(3));\n}\n\n/**\n * Calculates the contrast ratio between two colors.\n *\n * Formula: https://www.w3.org/TR/WCAG20-TECHS/G17.html#G17-tests\n * @param {string} foreground - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla()\n * @param {string} background - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla()\n * @returns {number} A contrast ratio value in the range 0 - 21.\n */\nexport function getContrastRatio(foreground, background) {\n const lumA = getLuminance(foreground);\n const lumB = getLuminance(background);\n return (Math.max(lumA, lumB) + 0.05) / (Math.min(lumA, lumB) + 0.05);\n}\n\n/**\n * Sets the absolute transparency of a color.\n * Any existing alpha values are overwritten.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} value - value to set the alpha channel to in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function alpha(color, value) {\n color = decomposeColor(color);\n value = clampWrapper(value);\n if (color.type === 'rgb' || color.type === 'hsl') {\n color.type += 'a';\n }\n if (color.type === 'color') {\n color.values[3] = `/${value}`;\n } else {\n color.values[3] = value;\n }\n return recomposeColor(color);\n}\nexport function private_safeAlpha(color, value, warning) {\n try {\n return alpha(color, value);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Darkens a color.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} coefficient - multiplier in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function darken(color, coefficient) {\n color = decomposeColor(color);\n coefficient = clampWrapper(coefficient);\n if (color.type.indexOf('hsl') !== -1) {\n color.values[2] *= 1 - coefficient;\n } else if (color.type.indexOf('rgb') !== -1 || color.type.indexOf('color') !== -1) {\n for (let i = 0; i < 3; i += 1) {\n color.values[i] *= 1 - coefficient;\n }\n }\n return recomposeColor(color);\n}\nexport function private_safeDarken(color, coefficient, warning) {\n try {\n return darken(color, coefficient);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Lightens a color.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} coefficient - multiplier in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function lighten(color, coefficient) {\n color = decomposeColor(color);\n coefficient = clampWrapper(coefficient);\n if (color.type.indexOf('hsl') !== -1) {\n color.values[2] += (100 - color.values[2]) * coefficient;\n } else if (color.type.indexOf('rgb') !== -1) {\n for (let i = 0; i < 3; i += 1) {\n color.values[i] += (255 - color.values[i]) * coefficient;\n }\n } else if (color.type.indexOf('color') !== -1) {\n for (let i = 0; i < 3; i += 1) {\n color.values[i] += (1 - color.values[i]) * coefficient;\n }\n }\n return recomposeColor(color);\n}\nexport function private_safeLighten(color, coefficient, warning) {\n try {\n return lighten(color, coefficient);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Darken or lighten a color, depending on its luminance.\n * Light colors are darkened, dark colors are lightened.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} coefficient=0.15 - multiplier in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function emphasize(color, coefficient = 0.15) {\n return getLuminance(color) > 0.5 ? darken(color, coefficient) : lighten(color, coefficient);\n}\nexport function private_safeEmphasize(color, coefficient, warning) {\n try {\n return emphasize(color, coefficient);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Blend a transparent overlay color with a background color, resulting in a single\n * RGB color.\n * @param {string} background - CSS color\n * @param {string} overlay - CSS color\n * @param {number} opacity - Opacity multiplier in the range 0 - 1\n * @param {number} [gamma=1.0] - Gamma correction factor. For gamma-correct blending, 2.2 is usual.\n */\nexport function blend(background, overlay, opacity, gamma = 1.0) {\n const blendChannel = (b, o) => Math.round((b ** (1 / gamma) * (1 - opacity) + o ** (1 / gamma) * opacity) ** gamma);\n const backgroundColor = decomposeColor(background);\n const overlayColor = decomposeColor(overlay);\n const rgb = [blendChannel(backgroundColor.values[0], overlayColor.values[0]), blendChannel(backgroundColor.values[1], overlayColor.values[1]), blendChannel(backgroundColor.values[2], overlayColor.values[2])];\n return recomposeColor({\n type: 'rgb',\n values: rgb\n });\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nexport default function createMixins(breakpoints, mixins) {\n return _extends({\n toolbar: {\n minHeight: 56,\n [breakpoints.up('xs')]: {\n '@media (orientation: landscape)': {\n minHeight: 48\n }\n },\n [breakpoints.up('sm')]: {\n minHeight: 64\n }\n }\n }, mixins);\n}","const common = {\n black: '#000',\n white: '#fff'\n};\nexport default common;","const grey = {\n 50: '#fafafa',\n 100: '#f5f5f5',\n 200: '#eeeeee',\n 300: '#e0e0e0',\n 400: '#bdbdbd',\n 500: '#9e9e9e',\n 600: '#757575',\n 700: '#616161',\n 800: '#424242',\n 900: '#212121',\n A100: '#f5f5f5',\n A200: '#eeeeee',\n A400: '#bdbdbd',\n A700: '#616161'\n};\nexport default grey;","const purple = {\n 50: '#f3e5f5',\n 100: '#e1bee7',\n 200: '#ce93d8',\n 300: '#ba68c8',\n 400: '#ab47bc',\n 500: '#9c27b0',\n 600: '#8e24aa',\n 700: '#7b1fa2',\n 800: '#6a1b9a',\n 900: '#4a148c',\n A100: '#ea80fc',\n A200: '#e040fb',\n A400: '#d500f9',\n A700: '#aa00ff'\n};\nexport default purple;","const red = {\n 50: '#ffebee',\n 100: '#ffcdd2',\n 200: '#ef9a9a',\n 300: '#e57373',\n 400: '#ef5350',\n 500: '#f44336',\n 600: '#e53935',\n 700: '#d32f2f',\n 800: '#c62828',\n 900: '#b71c1c',\n A100: '#ff8a80',\n A200: '#ff5252',\n A400: '#ff1744',\n A700: '#d50000'\n};\nexport default red;","const orange = {\n 50: '#fff3e0',\n 100: '#ffe0b2',\n 200: '#ffcc80',\n 300: '#ffb74d',\n 400: '#ffa726',\n 500: '#ff9800',\n 600: '#fb8c00',\n 700: '#f57c00',\n 800: '#ef6c00',\n 900: '#e65100',\n A100: '#ffd180',\n A200: '#ffab40',\n A400: '#ff9100',\n A700: '#ff6d00'\n};\nexport default orange;","const blue = {\n 50: '#e3f2fd',\n 100: '#bbdefb',\n 200: '#90caf9',\n 300: '#64b5f6',\n 400: '#42a5f5',\n 500: '#2196f3',\n 600: '#1e88e5',\n 700: '#1976d2',\n 800: '#1565c0',\n 900: '#0d47a1',\n A100: '#82b1ff',\n A200: '#448aff',\n A400: '#2979ff',\n A700: '#2962ff'\n};\nexport default blue;","const lightBlue = {\n 50: '#e1f5fe',\n 100: '#b3e5fc',\n 200: '#81d4fa',\n 300: '#4fc3f7',\n 400: '#29b6f6',\n 500: '#03a9f4',\n 600: '#039be5',\n 700: '#0288d1',\n 800: '#0277bd',\n 900: '#01579b',\n A100: '#80d8ff',\n A200: '#40c4ff',\n A400: '#00b0ff',\n A700: '#0091ea'\n};\nexport default lightBlue;","const green = {\n 50: '#e8f5e9',\n 100: '#c8e6c9',\n 200: '#a5d6a7',\n 300: '#81c784',\n 400: '#66bb6a',\n 500: '#4caf50',\n 600: '#43a047',\n 700: '#388e3c',\n 800: '#2e7d32',\n 900: '#1b5e20',\n A100: '#b9f6ca',\n A200: '#69f0ae',\n A400: '#00e676',\n A700: '#00c853'\n};\nexport default green;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\nconst _excluded = [\"mode\", \"contrastThreshold\", \"tonalOffset\"];\nimport { deepmerge } from '@mui/utils';\nimport { darken, getContrastRatio, lighten } from '@mui/system';\nimport common from '../colors/common';\nimport grey from '../colors/grey';\nimport purple from '../colors/purple';\nimport red from '../colors/red';\nimport orange from '../colors/orange';\nimport blue from '../colors/blue';\nimport lightBlue from '../colors/lightBlue';\nimport green from '../colors/green';\nexport const light = {\n // The colors used to style the text.\n text: {\n // The most important text.\n primary: 'rgba(0, 0, 0, 0.87)',\n // Secondary text.\n secondary: 'rgba(0, 0, 0, 0.6)',\n // Disabled text have even lower visual prominence.\n disabled: 'rgba(0, 0, 0, 0.38)'\n },\n // The color used to divide different elements.\n divider: 'rgba(0, 0, 0, 0.12)',\n // The background colors used to style the surfaces.\n // Consistency between these values is important.\n background: {\n paper: common.white,\n default: common.white\n },\n // The colors used to style the action elements.\n action: {\n // The color of an active action like an icon button.\n active: 'rgba(0, 0, 0, 0.54)',\n // The color of an hovered action.\n hover: 'rgba(0, 0, 0, 0.04)',\n hoverOpacity: 0.04,\n // The color of a selected action.\n selected: 'rgba(0, 0, 0, 0.08)',\n selectedOpacity: 0.08,\n // The color of a disabled action.\n disabled: 'rgba(0, 0, 0, 0.26)',\n // The background color of a disabled action.\n disabledBackground: 'rgba(0, 0, 0, 0.12)',\n disabledOpacity: 0.38,\n focus: 'rgba(0, 0, 0, 0.12)',\n focusOpacity: 0.12,\n activatedOpacity: 0.12\n }\n};\nexport const dark = {\n text: {\n primary: common.white,\n secondary: 'rgba(255, 255, 255, 0.7)',\n disabled: 'rgba(255, 255, 255, 0.5)',\n icon: 'rgba(255, 255, 255, 0.5)'\n },\n divider: 'rgba(255, 255, 255, 0.12)',\n background: {\n paper: '#121212',\n default: '#121212'\n },\n action: {\n active: common.white,\n hover: 'rgba(255, 255, 255, 0.08)',\n hoverOpacity: 0.08,\n selected: 'rgba(255, 255, 255, 0.16)',\n selectedOpacity: 0.16,\n disabled: 'rgba(255, 255, 255, 0.3)',\n disabledBackground: 'rgba(255, 255, 255, 0.12)',\n disabledOpacity: 0.38,\n focus: 'rgba(255, 255, 255, 0.12)',\n focusOpacity: 0.12,\n activatedOpacity: 0.24\n }\n};\nfunction addLightOrDark(intent, direction, shade, tonalOffset) {\n const tonalOffsetLight = tonalOffset.light || tonalOffset;\n const tonalOffsetDark = tonalOffset.dark || tonalOffset * 1.5;\n if (!intent[direction]) {\n if (intent.hasOwnProperty(shade)) {\n intent[direction] = intent[shade];\n } else if (direction === 'light') {\n intent.light = lighten(intent.main, tonalOffsetLight);\n } else if (direction === 'dark') {\n intent.dark = darken(intent.main, tonalOffsetDark);\n }\n }\n}\nfunction getDefaultPrimary(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: blue[200],\n light: blue[50],\n dark: blue[400]\n };\n }\n return {\n main: blue[700],\n light: blue[400],\n dark: blue[800]\n };\n}\nfunction getDefaultSecondary(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: purple[200],\n light: purple[50],\n dark: purple[400]\n };\n }\n return {\n main: purple[500],\n light: purple[300],\n dark: purple[700]\n };\n}\nfunction getDefaultError(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: red[500],\n light: red[300],\n dark: red[700]\n };\n }\n return {\n main: red[700],\n light: red[400],\n dark: red[800]\n };\n}\nfunction getDefaultInfo(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: lightBlue[400],\n light: lightBlue[300],\n dark: lightBlue[700]\n };\n }\n return {\n main: lightBlue[700],\n light: lightBlue[500],\n dark: lightBlue[900]\n };\n}\nfunction getDefaultSuccess(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: green[400],\n light: green[300],\n dark: green[700]\n };\n }\n return {\n main: green[800],\n light: green[500],\n dark: green[900]\n };\n}\nfunction getDefaultWarning(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: orange[400],\n light: orange[300],\n dark: orange[700]\n };\n }\n return {\n main: '#ed6c02',\n // closest to orange[800] that pass 3:1.\n light: orange[500],\n dark: orange[900]\n };\n}\nexport default function createPalette(palette) {\n const {\n mode = 'light',\n contrastThreshold = 3,\n tonalOffset = 0.2\n } = palette,\n other = _objectWithoutPropertiesLoose(palette, _excluded);\n const primary = palette.primary || getDefaultPrimary(mode);\n const secondary = palette.secondary || getDefaultSecondary(mode);\n const error = palette.error || getDefaultError(mode);\n const info = palette.info || getDefaultInfo(mode);\n const success = palette.success || getDefaultSuccess(mode);\n const warning = palette.warning || getDefaultWarning(mode);\n\n // Use the same logic as\n // Bootstrap: https://github.com/twbs/bootstrap/blob/1d6e3710dd447de1a200f29e8fa521f8a0908f70/scss/_functions.scss#L59\n // and material-components-web https://github.com/material-components/material-components-web/blob/ac46b8863c4dab9fc22c4c662dc6bd1b65dd652f/packages/mdc-theme/_functions.scss#L54\n function getContrastText(background) {\n const contrastText = getContrastRatio(background, dark.text.primary) >= contrastThreshold ? dark.text.primary : light.text.primary;\n if (process.env.NODE_ENV !== 'production') {\n const contrast = getContrastRatio(background, contrastText);\n if (contrast < 3) {\n console.error([`MUI: The contrast ratio of ${contrast}:1 for ${contrastText} on ${background}`, 'falls below the WCAG recommended absolute minimum contrast ratio of 3:1.', 'https://www.w3.org/TR/2008/REC-WCAG20-20081211/#visual-audio-contrast-contrast'].join('\\n'));\n }\n }\n return contrastText;\n }\n const augmentColor = ({\n color,\n name,\n mainShade = 500,\n lightShade = 300,\n darkShade = 700\n }) => {\n color = _extends({}, color);\n if (!color.main && color[mainShade]) {\n color.main = color[mainShade];\n }\n if (!color.hasOwnProperty('main')) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: The color${name ? ` (${name})` : ''} provided to augmentColor(color) is invalid.\nThe color object needs to have a \\`main\\` property or a \\`${mainShade}\\` property.` : _formatMuiErrorMessage(11, name ? ` (${name})` : '', mainShade));\n }\n if (typeof color.main !== 'string') {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: The color${name ? ` (${name})` : ''} provided to augmentColor(color) is invalid.\n\\`color.main\\` should be a string, but \\`${JSON.stringify(color.main)}\\` was provided instead.\n\nDid you intend to use one of the following approaches?\n\nimport { green } from \"@mui/material/colors\";\n\nconst theme1 = createTheme({ palette: {\n primary: green,\n} });\n\nconst theme2 = createTheme({ palette: {\n primary: { main: green[500] },\n} });` : _formatMuiErrorMessage(12, name ? ` (${name})` : '', JSON.stringify(color.main)));\n }\n addLightOrDark(color, 'light', lightShade, tonalOffset);\n addLightOrDark(color, 'dark', darkShade, tonalOffset);\n if (!color.contrastText) {\n color.contrastText = getContrastText(color.main);\n }\n return color;\n };\n const modes = {\n dark,\n light\n };\n if (process.env.NODE_ENV !== 'production') {\n if (!modes[mode]) {\n console.error(`MUI: The palette mode \\`${mode}\\` is not supported.`);\n }\n }\n const paletteOutput = deepmerge(_extends({\n // A collection of common colors.\n common: _extends({}, common),\n // prevent mutable object.\n // The palette mode, can be light or dark.\n mode,\n // The colors used to represent primary interface elements for a user.\n primary: augmentColor({\n color: primary,\n name: 'primary'\n }),\n // The colors used to represent secondary interface elements for a user.\n secondary: augmentColor({\n color: secondary,\n name: 'secondary',\n mainShade: 'A400',\n lightShade: 'A200',\n darkShade: 'A700'\n }),\n // The colors used to represent interface elements that the user should be made aware of.\n error: augmentColor({\n color: error,\n name: 'error'\n }),\n // The colors used to represent potentially dangerous actions or important messages.\n warning: augmentColor({\n color: warning,\n name: 'warning'\n }),\n // The colors used to present information to the user that is neutral and not necessarily important.\n info: augmentColor({\n color: info,\n name: 'info'\n }),\n // The colors used to indicate the successful completion of an action that user triggered.\n success: augmentColor({\n color: success,\n name: 'success'\n }),\n // The grey colors.\n grey,\n // Used by `getContrastText()` to maximize the contrast between\n // the background and the text.\n contrastThreshold,\n // Takes a background color and returns the text color that maximizes the contrast.\n getContrastText,\n // Generate a rich color object.\n augmentColor,\n // Used by the functions below to shift a color's luminance by approximately\n // two indexes within its tonal palette.\n // E.g., shift from Red 500 to Red 300 or Red 700.\n tonalOffset\n }, modes[mode]), other);\n return paletteOutput;\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"fontFamily\", \"fontSize\", \"fontWeightLight\", \"fontWeightRegular\", \"fontWeightMedium\", \"fontWeightBold\", \"htmlFontSize\", \"allVariants\", \"pxToRem\"];\nimport { deepmerge } from '@mui/utils';\nfunction round(value) {\n return Math.round(value * 1e5) / 1e5;\n}\nconst caseAllCaps = {\n textTransform: 'uppercase'\n};\nconst defaultFontFamily = '\"Roboto\", \"Helvetica\", \"Arial\", sans-serif';\n\n/**\n * @see @link{https://m2.material.io/design/typography/the-type-system.html}\n * @see @link{https://m2.material.io/design/typography/understanding-typography.html}\n */\nexport default function createTypography(palette, typography) {\n const _ref = typeof typography === 'function' ? typography(palette) : typography,\n {\n fontFamily = defaultFontFamily,\n // The default font size of the Material Specification.\n fontSize = 14,\n // px\n fontWeightLight = 300,\n fontWeightRegular = 400,\n fontWeightMedium = 500,\n fontWeightBold = 700,\n // Tell MUI what's the font-size on the html element.\n // 16px is the default font-size used by browsers.\n htmlFontSize = 16,\n // Apply the CSS properties to all the variants.\n allVariants,\n pxToRem: pxToRem2\n } = _ref,\n other = _objectWithoutPropertiesLoose(_ref, _excluded);\n if (process.env.NODE_ENV !== 'production') {\n if (typeof fontSize !== 'number') {\n console.error('MUI: `fontSize` is required to be a number.');\n }\n if (typeof htmlFontSize !== 'number') {\n console.error('MUI: `htmlFontSize` is required to be a number.');\n }\n }\n const coef = fontSize / 14;\n const pxToRem = pxToRem2 || (size => `${size / htmlFontSize * coef}rem`);\n const buildVariant = (fontWeight, size, lineHeight, letterSpacing, casing) => _extends({\n fontFamily,\n fontWeight,\n fontSize: pxToRem(size),\n // Unitless following https://meyerweb.com/eric/thoughts/2006/02/08/unitless-line-heights/\n lineHeight\n }, fontFamily === defaultFontFamily ? {\n letterSpacing: `${round(letterSpacing / size)}em`\n } : {}, casing, allVariants);\n const variants = {\n h1: buildVariant(fontWeightLight, 96, 1.167, -1.5),\n h2: buildVariant(fontWeightLight, 60, 1.2, -0.5),\n h3: buildVariant(fontWeightRegular, 48, 1.167, 0),\n h4: buildVariant(fontWeightRegular, 34, 1.235, 0.25),\n h5: buildVariant(fontWeightRegular, 24, 1.334, 0),\n h6: buildVariant(fontWeightMedium, 20, 1.6, 0.15),\n subtitle1: buildVariant(fontWeightRegular, 16, 1.75, 0.15),\n subtitle2: buildVariant(fontWeightMedium, 14, 1.57, 0.1),\n body1: buildVariant(fontWeightRegular, 16, 1.5, 0.15),\n body2: buildVariant(fontWeightRegular, 14, 1.43, 0.15),\n button: buildVariant(fontWeightMedium, 14, 1.75, 0.4, caseAllCaps),\n caption: buildVariant(fontWeightRegular, 12, 1.66, 0.4),\n overline: buildVariant(fontWeightRegular, 12, 2.66, 1, caseAllCaps),\n // TODO v6: Remove handling of 'inherit' variant from the theme as it is already handled in Material UI's Typography component. Also, remember to remove the associated types.\n inherit: {\n fontFamily: 'inherit',\n fontWeight: 'inherit',\n fontSize: 'inherit',\n lineHeight: 'inherit',\n letterSpacing: 'inherit'\n }\n };\n return deepmerge(_extends({\n htmlFontSize,\n pxToRem,\n fontFamily,\n fontSize,\n fontWeightLight,\n fontWeightRegular,\n fontWeightMedium,\n fontWeightBold\n }, variants), other, {\n clone: false // No need to clone deep\n });\n}","const shadowKeyUmbraOpacity = 0.2;\nconst shadowKeyPenumbraOpacity = 0.14;\nconst shadowAmbientShadowOpacity = 0.12;\nfunction createShadow(...px) {\n return [`${px[0]}px ${px[1]}px ${px[2]}px ${px[3]}px rgba(0,0,0,${shadowKeyUmbraOpacity})`, `${px[4]}px ${px[5]}px ${px[6]}px ${px[7]}px rgba(0,0,0,${shadowKeyPenumbraOpacity})`, `${px[8]}px ${px[9]}px ${px[10]}px ${px[11]}px rgba(0,0,0,${shadowAmbientShadowOpacity})`].join(',');\n}\n\n// Values from https://github.com/material-components/material-components-web/blob/be8747f94574669cb5e7add1a7c54fa41a89cec7/packages/mdc-elevation/_variables.scss\nconst shadows = ['none', createShadow(0, 2, 1, -1, 0, 1, 1, 0, 0, 1, 3, 0), createShadow(0, 3, 1, -2, 0, 2, 2, 0, 0, 1, 5, 0), createShadow(0, 3, 3, -2, 0, 3, 4, 0, 0, 1, 8, 0), createShadow(0, 2, 4, -1, 0, 4, 5, 0, 0, 1, 10, 0), createShadow(0, 3, 5, -1, 0, 5, 8, 0, 0, 1, 14, 0), createShadow(0, 3, 5, -1, 0, 6, 10, 0, 0, 1, 18, 0), createShadow(0, 4, 5, -2, 0, 7, 10, 1, 0, 2, 16, 1), createShadow(0, 5, 5, -3, 0, 8, 10, 1, 0, 3, 14, 2), createShadow(0, 5, 6, -3, 0, 9, 12, 1, 0, 3, 16, 2), createShadow(0, 6, 6, -3, 0, 10, 14, 1, 0, 4, 18, 3), createShadow(0, 6, 7, -4, 0, 11, 15, 1, 0, 4, 20, 3), createShadow(0, 7, 8, -4, 0, 12, 17, 2, 0, 5, 22, 4), createShadow(0, 7, 8, -4, 0, 13, 19, 2, 0, 5, 24, 4), createShadow(0, 7, 9, -4, 0, 14, 21, 2, 0, 5, 26, 4), createShadow(0, 8, 9, -5, 0, 15, 22, 2, 0, 6, 28, 5), createShadow(0, 8, 10, -5, 0, 16, 24, 2, 0, 6, 30, 5), createShadow(0, 8, 11, -5, 0, 17, 26, 2, 0, 6, 32, 5), createShadow(0, 9, 11, -5, 0, 18, 28, 2, 0, 7, 34, 6), createShadow(0, 9, 12, -6, 0, 19, 29, 2, 0, 7, 36, 6), createShadow(0, 10, 13, -6, 0, 20, 31, 3, 0, 8, 38, 7), createShadow(0, 10, 13, -6, 0, 21, 33, 3, 0, 8, 40, 7), createShadow(0, 10, 14, -6, 0, 22, 35, 3, 0, 8, 42, 7), createShadow(0, 11, 14, -7, 0, 23, 36, 3, 0, 9, 44, 8), createShadow(0, 11, 15, -7, 0, 24, 38, 3, 0, 9, 46, 8)];\nexport default shadows;","import _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nconst _excluded = [\"duration\", \"easing\", \"delay\"];\n// Follow https://material.google.com/motion/duration-easing.html#duration-easing-natural-easing-curves\n// to learn the context in which each easing should be used.\nexport const easing = {\n // This is the most common easing curve.\n easeInOut: 'cubic-bezier(0.4, 0, 0.2, 1)',\n // Objects enter the screen at full velocity from off-screen and\n // slowly decelerate to a resting point.\n easeOut: 'cubic-bezier(0.0, 0, 0.2, 1)',\n // Objects leave the screen at full velocity. They do not decelerate when off-screen.\n easeIn: 'cubic-bezier(0.4, 0, 1, 1)',\n // The sharp curve is used by objects that may return to the screen at any time.\n sharp: 'cubic-bezier(0.4, 0, 0.6, 1)'\n};\n\n// Follow https://m2.material.io/guidelines/motion/duration-easing.html#duration-easing-common-durations\n// to learn when use what timing\nexport const duration = {\n shortest: 150,\n shorter: 200,\n short: 250,\n // most basic recommended timing\n standard: 300,\n // this is to be used in complex animations\n complex: 375,\n // recommended when something is entering screen\n enteringScreen: 225,\n // recommended when something is leaving screen\n leavingScreen: 195\n};\nfunction formatMs(milliseconds) {\n return `${Math.round(milliseconds)}ms`;\n}\nfunction getAutoHeightDuration(height) {\n if (!height) {\n return 0;\n }\n const constant = height / 36;\n\n // https://www.wolframalpha.com/input/?i=(4+%2B+15+*+(x+%2F+36+)+**+0.25+%2B+(x+%2F+36)+%2F+5)+*+10\n return Math.round((4 + 15 * constant ** 0.25 + constant / 5) * 10);\n}\nexport default function createTransitions(inputTransitions) {\n const mergedEasing = _extends({}, easing, inputTransitions.easing);\n const mergedDuration = _extends({}, duration, inputTransitions.duration);\n const create = (props = ['all'], options = {}) => {\n const {\n duration: durationOption = mergedDuration.standard,\n easing: easingOption = mergedEasing.easeInOut,\n delay = 0\n } = options,\n other = _objectWithoutPropertiesLoose(options, _excluded);\n if (process.env.NODE_ENV !== 'production') {\n const isString = value => typeof value === 'string';\n // IE11 support, replace with Number.isNaN\n // eslint-disable-next-line no-restricted-globals\n const isNumber = value => !isNaN(parseFloat(value));\n if (!isString(props) && !Array.isArray(props)) {\n console.error('MUI: Argument \"props\" must be a string or Array.');\n }\n if (!isNumber(durationOption) && !isString(durationOption)) {\n console.error(`MUI: Argument \"duration\" must be a number or a string but found ${durationOption}.`);\n }\n if (!isString(easingOption)) {\n console.error('MUI: Argument \"easing\" must be a string.');\n }\n if (!isNumber(delay) && !isString(delay)) {\n console.error('MUI: Argument \"delay\" must be a number or a string.');\n }\n if (typeof options !== 'object') {\n console.error(['MUI: Secong argument of transition.create must be an object.', \"Arguments should be either `create('prop1', options)` or `create(['prop1', 'prop2'], options)`\"].join('\\n'));\n }\n if (Object.keys(other).length !== 0) {\n console.error(`MUI: Unrecognized argument(s) [${Object.keys(other).join(',')}].`);\n }\n }\n return (Array.isArray(props) ? props : [props]).map(animatedProp => `${animatedProp} ${typeof durationOption === 'string' ? durationOption : formatMs(durationOption)} ${easingOption} ${typeof delay === 'string' ? delay : formatMs(delay)}`).join(',');\n };\n return _extends({\n getAutoHeightDuration,\n create\n }, inputTransitions, {\n easing: mergedEasing,\n duration: mergedDuration\n });\n}","// We need to centralize the zIndex definitions as they work\n// like global values in the browser.\nconst zIndex = {\n mobileStepper: 1000,\n fab: 1050,\n speedDial: 1050,\n appBar: 1100,\n drawer: 1200,\n modal: 1300,\n snackbar: 1400,\n tooltip: 1500\n};\nexport default zIndex;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\nconst _excluded = [\"breakpoints\", \"mixins\", \"spacing\", \"palette\", \"transitions\", \"typography\", \"shape\"];\nimport { deepmerge } from '@mui/utils';\nimport { createTheme as systemCreateTheme, unstable_defaultSxConfig as defaultSxConfig, unstable_styleFunctionSx as styleFunctionSx } from '@mui/system';\nimport generateUtilityClass from '@mui/utils/generateUtilityClass';\nimport createMixins from './createMixins';\nimport createPalette from './createPalette';\nimport createTypography from './createTypography';\nimport shadows from './shadows';\nimport createTransitions from './createTransitions';\nimport zIndex from './zIndex';\nfunction createTheme(options = {}, ...args) {\n const {\n mixins: mixinsInput = {},\n palette: paletteInput = {},\n transitions: transitionsInput = {},\n typography: typographyInput = {}\n } = options,\n other = _objectWithoutPropertiesLoose(options, _excluded);\n if (options.vars) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: \\`vars\\` is a private field used for CSS variables support.\nPlease use another name.` : _formatMuiErrorMessage(18));\n }\n const palette = createPalette(paletteInput);\n const systemTheme = systemCreateTheme(options);\n let muiTheme = deepmerge(systemTheme, {\n mixins: createMixins(systemTheme.breakpoints, mixinsInput),\n palette,\n // Don't use [...shadows] until you've verified its transpiled code is not invoking the iterator protocol.\n shadows: shadows.slice(),\n typography: createTypography(palette, typographyInput),\n transitions: createTransitions(transitionsInput),\n zIndex: _extends({}, zIndex)\n });\n muiTheme = deepmerge(muiTheme, other);\n muiTheme = args.reduce((acc, argument) => deepmerge(acc, argument), muiTheme);\n if (process.env.NODE_ENV !== 'production') {\n // TODO v6: Refactor to use globalStateClassesMapping from @mui/utils once `readOnly` state class is used in Rating component.\n const stateClasses = ['active', 'checked', 'completed', 'disabled', 'error', 'expanded', 'focused', 'focusVisible', 'required', 'selected'];\n const traverse = (node, component) => {\n let key;\n\n // eslint-disable-next-line guard-for-in, no-restricted-syntax\n for (key in node) {\n const child = node[key];\n if (stateClasses.indexOf(key) !== -1 && Object.keys(child).length > 0) {\n if (process.env.NODE_ENV !== 'production') {\n const stateClass = generateUtilityClass('', key);\n console.error([`MUI: The \\`${component}\\` component increases ` + `the CSS specificity of the \\`${key}\\` internal state.`, 'You can not override it like this: ', JSON.stringify(node, null, 2), '', `Instead, you need to use the '&.${stateClass}' syntax:`, JSON.stringify({\n root: {\n [`&.${stateClass}`]: child\n }\n }, null, 2), '', 'https://mui.com/r/state-classes-guide'].join('\\n'));\n }\n // Remove the style to prevent global conflicts.\n node[key] = {};\n }\n }\n };\n Object.keys(muiTheme.components).forEach(component => {\n const styleOverrides = muiTheme.components[component].styleOverrides;\n if (styleOverrides && component.indexOf('Mui') === 0) {\n traverse(styleOverrides, component);\n }\n });\n }\n muiTheme.unstable_sxConfig = _extends({}, defaultSxConfig, other == null ? void 0 : other.unstable_sxConfig);\n muiTheme.unstable_sx = function sx(props) {\n return styleFunctionSx({\n sx: props,\n theme: this\n });\n };\n return muiTheme;\n}\nlet warnedOnce = false;\nexport function createMuiTheme(...args) {\n if (process.env.NODE_ENV !== 'production') {\n if (!warnedOnce) {\n warnedOnce = true;\n console.error(['MUI: the createMuiTheme function was renamed to createTheme.', '', \"You should use `import { createTheme } from '@mui/material/styles'`\"].join('\\n'));\n }\n }\n return createTheme(...args);\n}\nexport default createTheme;","'use client';\n\nimport createTheme from './createTheme';\nconst defaultTheme = createTheme();\nexport default defaultTheme;","export default '$$material';","'use client';\n\nimport { useThemeProps as systemUseThemeProps } from '@mui/system';\nimport defaultTheme from './defaultTheme';\nimport THEME_ID from './identifier';\nexport default function useThemeProps({\n props,\n name\n}) {\n return systemUseThemeProps({\n props,\n name,\n defaultTheme,\n themeId: THEME_ID\n });\n}","'use client';\n\nimport { createStyled, shouldForwardProp } from '@mui/system';\nimport defaultTheme from './defaultTheme';\nimport THEME_ID from './identifier';\nexport const rootShouldForwardProp = prop => shouldForwardProp(prop) && prop !== 'classes';\nexport const slotShouldForwardProp = shouldForwardProp;\nconst styled = createStyled({\n themeId: THEME_ID,\n defaultTheme,\n rootShouldForwardProp\n});\nexport default styled;","import generateUtilityClasses from '@mui/utils/generateUtilityClasses';\nimport generateUtilityClass from '@mui/utils/generateUtilityClass';\nexport function getSvgIconUtilityClass(slot) {\n return generateUtilityClass('MuiSvgIcon', slot);\n}\nconst svgIconClasses = generateUtilityClasses('MuiSvgIcon', ['root', 'colorPrimary', 'colorSecondary', 'colorAction', 'colorError', 'colorDisabled', 'fontSizeInherit', 'fontSizeSmall', 'fontSizeMedium', 'fontSizeLarge']);\nexport default svgIconClasses;","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"children\", \"className\", \"color\", \"component\", \"fontSize\", \"htmlColor\", \"inheritViewBox\", \"titleAccess\", \"viewBox\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport clsx from 'clsx';\nimport { unstable_composeClasses as composeClasses } from '@mui/base/composeClasses';\nimport capitalize from '../utils/capitalize';\nimport useThemeProps from '../styles/useThemeProps';\nimport styled from '../styles/styled';\nimport { getSvgIconUtilityClass } from './svgIconClasses';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nimport { jsxs as _jsxs } from \"react/jsx-runtime\";\nconst useUtilityClasses = ownerState => {\n const {\n color,\n fontSize,\n classes\n } = ownerState;\n const slots = {\n root: ['root', color !== 'inherit' && `color${capitalize(color)}`, `fontSize${capitalize(fontSize)}`]\n };\n return composeClasses(slots, getSvgIconUtilityClass, classes);\n};\nconst SvgIconRoot = styled('svg', {\n name: 'MuiSvgIcon',\n slot: 'Root',\n overridesResolver: (props, styles) => {\n const {\n ownerState\n } = props;\n return [styles.root, ownerState.color !== 'inherit' && styles[`color${capitalize(ownerState.color)}`], styles[`fontSize${capitalize(ownerState.fontSize)}`]];\n }\n})(({\n theme,\n ownerState\n}) => {\n var _theme$transitions, _theme$transitions$cr, _theme$transitions2, _theme$typography, _theme$typography$pxT, _theme$typography2, _theme$typography2$px, _theme$typography3, _theme$typography3$px, _palette$ownerState$c, _palette, _palette2, _palette3;\n return {\n userSelect: 'none',\n width: '1em',\n height: '1em',\n display: 'inline-block',\n // the will define the property that has `currentColor`\n // e.g. heroicons uses fill=\"none\" and stroke=\"currentColor\"\n fill: ownerState.hasSvgAsChild ? undefined : 'currentColor',\n flexShrink: 0,\n transition: (_theme$transitions = theme.transitions) == null || (_theme$transitions$cr = _theme$transitions.create) == null ? void 0 : _theme$transitions$cr.call(_theme$transitions, 'fill', {\n duration: (_theme$transitions2 = theme.transitions) == null || (_theme$transitions2 = _theme$transitions2.duration) == null ? void 0 : _theme$transitions2.shorter\n }),\n fontSize: {\n inherit: 'inherit',\n small: ((_theme$typography = theme.typography) == null || (_theme$typography$pxT = _theme$typography.pxToRem) == null ? void 0 : _theme$typography$pxT.call(_theme$typography, 20)) || '1.25rem',\n medium: ((_theme$typography2 = theme.typography) == null || (_theme$typography2$px = _theme$typography2.pxToRem) == null ? void 0 : _theme$typography2$px.call(_theme$typography2, 24)) || '1.5rem',\n large: ((_theme$typography3 = theme.typography) == null || (_theme$typography3$px = _theme$typography3.pxToRem) == null ? void 0 : _theme$typography3$px.call(_theme$typography3, 35)) || '2.1875rem'\n }[ownerState.fontSize],\n // TODO v5 deprecate, v6 remove for sx\n color: (_palette$ownerState$c = (_palette = (theme.vars || theme).palette) == null || (_palette = _palette[ownerState.color]) == null ? void 0 : _palette.main) != null ? _palette$ownerState$c : {\n action: (_palette2 = (theme.vars || theme).palette) == null || (_palette2 = _palette2.action) == null ? void 0 : _palette2.active,\n disabled: (_palette3 = (theme.vars || theme).palette) == null || (_palette3 = _palette3.action) == null ? void 0 : _palette3.disabled,\n inherit: undefined\n }[ownerState.color]\n };\n});\nconst SvgIcon = /*#__PURE__*/React.forwardRef(function SvgIcon(inProps, ref) {\n const props = useThemeProps({\n props: inProps,\n name: 'MuiSvgIcon'\n });\n const {\n children,\n className,\n color = 'inherit',\n component = 'svg',\n fontSize = 'medium',\n htmlColor,\n inheritViewBox = false,\n titleAccess,\n viewBox = '0 0 24 24'\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const hasSvgAsChild = /*#__PURE__*/React.isValidElement(children) && children.type === 'svg';\n const ownerState = _extends({}, props, {\n color,\n component,\n fontSize,\n instanceFontSize: inProps.fontSize,\n inheritViewBox,\n viewBox,\n hasSvgAsChild\n });\n const more = {};\n if (!inheritViewBox) {\n more.viewBox = viewBox;\n }\n const classes = useUtilityClasses(ownerState);\n return /*#__PURE__*/_jsxs(SvgIconRoot, _extends({\n as: component,\n className: clsx(classes.root, className),\n focusable: \"false\",\n color: htmlColor,\n \"aria-hidden\": titleAccess ? undefined : true,\n role: titleAccess ? 'img' : undefined,\n ref: ref\n }, more, other, hasSvgAsChild && children.props, {\n ownerState: ownerState,\n children: [hasSvgAsChild ? children.props.children : children, titleAccess ? /*#__PURE__*/_jsx(\"title\", {\n children: titleAccess\n }) : null]\n }));\n});\nprocess.env.NODE_ENV !== \"production\" ? SvgIcon.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the d.ts file and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * Node passed into the SVG element.\n */\n children: PropTypes.node,\n /**\n * Override or extend the styles applied to the component.\n */\n classes: PropTypes.object,\n /**\n * @ignore\n */\n className: PropTypes.string,\n /**\n * The color of the component.\n * It supports both default and custom theme colors, which can be added as shown in the\n * [palette customization guide](https://mui.com/material-ui/customization/palette/#custom-colors).\n * You can use the `htmlColor` prop to apply a color attribute to the SVG element.\n * @default 'inherit'\n */\n color: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.oneOf(['inherit', 'action', 'disabled', 'primary', 'secondary', 'error', 'info', 'success', 'warning']), PropTypes.string]),\n /**\n * The component used for the root node.\n * Either a string to use a HTML element or a component.\n */\n component: PropTypes.elementType,\n /**\n * The fontSize applied to the icon. Defaults to 24px, but can be configure to inherit font size.\n * @default 'medium'\n */\n fontSize: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.oneOf(['inherit', 'large', 'medium', 'small']), PropTypes.string]),\n /**\n * Applies a color attribute to the SVG element.\n */\n htmlColor: PropTypes.string,\n /**\n * If `true`, the root node will inherit the custom `component`'s viewBox and the `viewBox`\n * prop will be ignored.\n * Useful when you want to reference a custom `component` and have `SvgIcon` pass that\n * `component`'s viewBox to the root node.\n * @default false\n */\n inheritViewBox: PropTypes.bool,\n /**\n * The shape-rendering attribute. The behavior of the different options is described on the\n * [MDN Web Docs](https://developer.mozilla.org/en-US/docs/Web/SVG/Attribute/shape-rendering).\n * If you are having issues with blurry icons you should investigate this prop.\n */\n shapeRendering: PropTypes.string,\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Provides a human-readable title for the element that contains it.\n * https://www.w3.org/TR/SVG-access/#Equivalent\n */\n titleAccess: PropTypes.string,\n /**\n * Allows you to redefine what the coordinates without units mean inside an SVG element.\n * For example, if the SVG element is 500 (width) by 200 (height),\n * and you pass viewBox=\"0 0 50 20\",\n * this means that the coordinates inside the SVG will go from the top left corner (0,0)\n * to bottom right (50,20) and each unit will be worth 10px.\n * @default '0 0 24 24'\n */\n viewBox: PropTypes.string\n} : void 0;\nSvgIcon.muiName = 'SvgIcon';\nexport default SvgIcon;","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport * as React from 'react';\nimport SvgIcon from '../SvgIcon';\n\n/**\n * Private module reserved for @mui packages.\n */\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nexport default function createSvgIcon(path, displayName) {\n function Component(props, ref) {\n return /*#__PURE__*/_jsx(SvgIcon, _extends({\n \"data-testid\": `${displayName}Icon`,\n ref: ref\n }, props, {\n children: path\n }));\n }\n if (process.env.NODE_ENV !== 'production') {\n // Need to set `displayName` on the inner component for React.memo.\n // React prior to 16.14 ignores `displayName` on the wrapper.\n Component.displayName = `${displayName}Icon`;\n }\n Component.muiName = SvgIcon.muiName;\n return /*#__PURE__*/React.memo( /*#__PURE__*/React.forwardRef(Component));\n}","'use client';\n\nimport { unstable_ClassNameGenerator as ClassNameGenerator } from '@mui/base/ClassNameGenerator';\nexport { default as capitalize } from './capitalize';\nexport { default as createChainedFunction } from './createChainedFunction';\nexport { default as createSvgIcon } from './createSvgIcon';\nexport { default as debounce } from './debounce';\nexport { default as deprecatedPropType } from './deprecatedPropType';\nexport { default as isMuiElement } from './isMuiElement';\nexport { default as ownerDocument } from './ownerDocument';\nexport { default as ownerWindow } from './ownerWindow';\nexport { default as requirePropFactory } from './requirePropFactory';\nexport { default as setRef } from './setRef';\nexport { default as unstable_useEnhancedEffect } from './useEnhancedEffect';\nexport { default as unstable_useId } from './useId';\nexport { default as unsupportedProp } from './unsupportedProp';\nexport { default as useControlled } from './useControlled';\nexport { default as useEventCallback } from './useEventCallback';\nexport { default as useForkRef } from './useForkRef';\nexport { default as useIsFocusVisible } from './useIsFocusVisible';\n// TODO: remove this export once ClassNameGenerator is stable\n// eslint-disable-next-line @typescript-eslint/naming-convention\nexport const unstable_ClassNameGenerator = {\n configure: generator => {\n if (process.env.NODE_ENV !== 'production') {\n console.warn(['MUI: `ClassNameGenerator` import from `@mui/material/utils` is outdated and might cause unexpected issues.', '', \"You should use `import { unstable_ClassNameGenerator } from '@mui/material/className'` instead\", '', 'The detail of the issue: https://github.com/mui/material-ui/issues/30011#issuecomment-1024993401', '', 'The updated documentation: https://mui.com/guides/classname-generator/'].join('\\n'));\n }\n ClassNameGenerator.configure(generator);\n }\n};","\"use strict\";\n'use client';\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nObject.defineProperty(exports, \"default\", {\n enumerable: true,\n get: function () {\n return _utils.createSvgIcon;\n }\n});\nvar _utils = require(\"@mui/material/utils\");","\"use strict\";\n\"use client\";\n\nvar _interopRequireDefault = require(\"@babel/runtime/helpers/interopRequireDefault\");\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = void 0;\nvar _createSvgIcon = _interopRequireDefault(require(\"./utils/createSvgIcon\"));\nvar _jsxRuntime = require(\"react/jsx-runtime\");\nvar _default = exports.default = (0, _createSvgIcon.default)( /*#__PURE__*/(0, _jsxRuntime.jsx)(\"path\", {\n d: \"m10 17 5-5-5-5z\"\n}), 'ArrowRight');","/**\n * Determines if a given element is a DOM element name (i.e. not a React component).\n */\nexport function isHostComponent(element) {\n return typeof element === 'string';\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport { isHostComponent } from './isHostComponent';\n\n/**\n * Type of the ownerState based on the type of an element it applies to.\n * This resolves to the provided OwnerState for React components and `undefined` for host components.\n * Falls back to `OwnerState | undefined` when the exact type can't be determined in development time.\n */\n\n/**\n * Appends the ownerState object to the props, merging with the existing one if necessary.\n *\n * @param elementType Type of the element that owns the `existingProps`. If the element is a DOM node or undefined, `ownerState` is not applied.\n * @param otherProps Props of the element.\n * @param ownerState\n */\nexport function appendOwnerState(elementType, otherProps, ownerState) {\n if (elementType === undefined || isHostComponent(elementType)) {\n return otherProps;\n }\n return _extends({}, otherProps, {\n ownerState: _extends({}, otherProps.ownerState, ownerState)\n });\n}","'use client';\n\nimport * as React from 'react';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nconst defaultContextValue = {\n disableDefaultClasses: false\n};\nconst ClassNameConfiguratorContext = /*#__PURE__*/React.createContext(defaultContextValue);\n/**\n * @ignore - internal hook.\n *\n * Wraps the `generateUtilityClass` function and controls how the classes are generated.\n * Currently it only affects whether the classes are applied or not.\n *\n * @returns Function to be called with the `generateUtilityClass` function specific to a component to generate the classes.\n */\nexport function useClassNamesOverride(generateUtilityClass) {\n const {\n disableDefaultClasses\n } = React.useContext(ClassNameConfiguratorContext);\n return slot => {\n if (disableDefaultClasses) {\n return '';\n }\n return generateUtilityClass(slot);\n };\n}\n\n/**\n * Allows to configure the components within to not apply any built-in classes.\n */\nexport function ClassNameConfigurator(props) {\n const {\n disableDefaultClasses,\n children\n } = props;\n const contextValue = React.useMemo(() => ({\n disableDefaultClasses: disableDefaultClasses != null ? disableDefaultClasses : false\n }), [disableDefaultClasses]);\n return /*#__PURE__*/_jsx(ClassNameConfiguratorContext.Provider, {\n value: contextValue,\n children: children\n });\n}","/**\n * Extracts event handlers from a given object.\n * A prop is considered an event handler if it is a function and its name starts with `on`.\n *\n * @param object An object to extract event handlers from.\n * @param excludeKeys An array of keys to exclude from the returned object.\n */\nexport function extractEventHandlers(object, excludeKeys = []) {\n if (object === undefined) {\n return {};\n }\n const result = {};\n Object.keys(object).filter(prop => prop.match(/^on[A-Z]/) && typeof object[prop] === 'function' && !excludeKeys.includes(prop)).forEach(prop => {\n result[prop] = object[prop];\n });\n return result;\n}","/**\n * If `componentProps` is a function, calls it with the provided `ownerState`.\n * Otherwise, just returns `componentProps`.\n */\nexport function resolveComponentProps(componentProps, ownerState, slotState) {\n if (typeof componentProps === 'function') {\n return componentProps(ownerState, slotState);\n }\n return componentProps;\n}","/**\n * Removes event handlers from the given object.\n * A field is considered an event handler if it is a function with a name beginning with `on`.\n *\n * @param object Object to remove event handlers from.\n * @returns Object with event handlers removed.\n */\nexport function omitEventHandlers(object) {\n if (object === undefined) {\n return {};\n }\n const result = {};\n Object.keys(object).filter(prop => !(prop.match(/^on[A-Z]/) && typeof object[prop] === 'function')).forEach(prop => {\n result[prop] = object[prop];\n });\n return result;\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport clsx from 'clsx';\nimport { extractEventHandlers } from './extractEventHandlers';\nimport { omitEventHandlers } from './omitEventHandlers';\n/**\n * Merges the slot component internal props (usually coming from a hook)\n * with the externally provided ones.\n *\n * The merge order is (the latter overrides the former):\n * 1. The internal props (specified as a getter function to work with get*Props hook result)\n * 2. Additional props (specified internally on a Base UI component)\n * 3. External props specified on the owner component. These should only be used on a root slot.\n * 4. External props specified in the `slotProps.*` prop.\n * 5. The `className` prop - combined from all the above.\n * @param parameters\n * @returns\n */\nexport function mergeSlotProps(parameters) {\n const {\n getSlotProps,\n additionalProps,\n externalSlotProps,\n externalForwardedProps,\n className\n } = parameters;\n if (!getSlotProps) {\n // The simpler case - getSlotProps is not defined, so no internal event handlers are defined,\n // so we can simply merge all the props without having to worry about extracting event handlers.\n const joinedClasses = clsx(additionalProps == null ? void 0 : additionalProps.className, className, externalForwardedProps == null ? void 0 : externalForwardedProps.className, externalSlotProps == null ? void 0 : externalSlotProps.className);\n const mergedStyle = _extends({}, additionalProps == null ? void 0 : additionalProps.style, externalForwardedProps == null ? void 0 : externalForwardedProps.style, externalSlotProps == null ? void 0 : externalSlotProps.style);\n const props = _extends({}, additionalProps, externalForwardedProps, externalSlotProps);\n if (joinedClasses.length > 0) {\n props.className = joinedClasses;\n }\n if (Object.keys(mergedStyle).length > 0) {\n props.style = mergedStyle;\n }\n return {\n props,\n internalRef: undefined\n };\n }\n\n // In this case, getSlotProps is responsible for calling the external event handlers.\n // We don't need to include them in the merged props because of this.\n\n const eventHandlers = extractEventHandlers(_extends({}, externalForwardedProps, externalSlotProps));\n const componentsPropsWithoutEventHandlers = omitEventHandlers(externalSlotProps);\n const otherPropsWithoutEventHandlers = omitEventHandlers(externalForwardedProps);\n const internalSlotProps = getSlotProps(eventHandlers);\n\n // The order of classes is important here.\n // Emotion (that we use in libraries consuming Base UI) depends on this order\n // to properly override style. It requires the most important classes to be last\n // (see https://github.com/mui/material-ui/pull/33205) for the related discussion.\n const joinedClasses = clsx(internalSlotProps == null ? void 0 : internalSlotProps.className, additionalProps == null ? void 0 : additionalProps.className, className, externalForwardedProps == null ? void 0 : externalForwardedProps.className, externalSlotProps == null ? void 0 : externalSlotProps.className);\n const mergedStyle = _extends({}, internalSlotProps == null ? void 0 : internalSlotProps.style, additionalProps == null ? void 0 : additionalProps.style, externalForwardedProps == null ? void 0 : externalForwardedProps.style, externalSlotProps == null ? void 0 : externalSlotProps.style);\n const props = _extends({}, internalSlotProps, additionalProps, otherPropsWithoutEventHandlers, componentsPropsWithoutEventHandlers);\n if (joinedClasses.length > 0) {\n props.className = joinedClasses;\n }\n if (Object.keys(mergedStyle).length > 0) {\n props.style = mergedStyle;\n }\n return {\n props,\n internalRef: internalSlotProps.ref\n };\n}","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"elementType\", \"externalSlotProps\", \"ownerState\", \"skipResolvingSlotProps\"];\nimport { unstable_useForkRef as useForkRef } from '@mui/utils';\nimport { appendOwnerState } from './appendOwnerState';\nimport { mergeSlotProps } from './mergeSlotProps';\nimport { resolveComponentProps } from './resolveComponentProps';\n/**\n * @ignore - do not document.\n * Builds the props to be passed into the slot of an unstyled component.\n * It merges the internal props of the component with the ones supplied by the user, allowing to customize the behavior.\n * If the slot component is not a host component, it also merges in the `ownerState`.\n *\n * @param parameters.getSlotProps - A function that returns the props to be passed to the slot component.\n */\nexport function useSlotProps(parameters) {\n var _parameters$additiona;\n const {\n elementType,\n externalSlotProps,\n ownerState,\n skipResolvingSlotProps = false\n } = parameters,\n rest = _objectWithoutPropertiesLoose(parameters, _excluded);\n const resolvedComponentsProps = skipResolvingSlotProps ? {} : resolveComponentProps(externalSlotProps, ownerState);\n const {\n props: mergedProps,\n internalRef\n } = mergeSlotProps(_extends({}, rest, {\n externalSlotProps: resolvedComponentsProps\n }));\n const ref = useForkRef(internalRef, resolvedComponentsProps == null ? void 0 : resolvedComponentsProps.ref, (_parameters$additiona = parameters.additionalProps) == null ? void 0 : _parameters$additiona.ref);\n const props = appendOwnerState(elementType, _extends({}, mergedProps, {\n ref\n }), ownerState);\n return props;\n}","import { globalStateClasses } from '@mui/utils/generateUtilityClass';\nconst GLOBAL_CLASS_PREFIX = 'base';\nfunction buildStateClass(state) {\n return `${GLOBAL_CLASS_PREFIX}--${state}`;\n}\nfunction buildSlotClass(componentName, slot) {\n return `${GLOBAL_CLASS_PREFIX}-${componentName}-${slot}`;\n}\nexport function generateUtilityClass(componentName, slot) {\n const globalStateClass = globalStateClasses[slot];\n return globalStateClass ? buildStateClass(globalStateClass) : buildSlotClass(componentName, slot);\n}\nexport function isGlobalState(slot) {\n return globalStateClasses[slot] !== undefined;\n}","import { generateUtilityClass } from '../generateUtilityClass';\nexport function generateUtilityClasses(componentName, slots) {\n const result = {};\n slots.forEach(slot => {\n result[slot] = generateUtilityClass(componentName, slot);\n });\n return result;\n}","'use client';\n\nimport * as React from 'react';\nimport * as ReactDOM from 'react-dom';\nimport PropTypes from 'prop-types';\nimport { exactProp, HTMLElementType, unstable_useEnhancedEffect as useEnhancedEffect, unstable_useForkRef as useForkRef, unstable_setRef as setRef } from '@mui/utils';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nfunction getContainer(container) {\n return typeof container === 'function' ? container() : container;\n}\n\n/**\n * Portals provide a first-class way to render children into a DOM node\n * that exists outside the DOM hierarchy of the parent component.\n *\n * Demos:\n *\n * - [Portal](https://mui.com/base-ui/react-portal/)\n *\n * API:\n *\n * - [Portal API](https://mui.com/base-ui/react-portal/components-api/#portal)\n */\nconst Portal = /*#__PURE__*/React.forwardRef(function Portal(props, forwardedRef) {\n const {\n children,\n container,\n disablePortal = false\n } = props;\n const [mountNode, setMountNode] = React.useState(null);\n // @ts-expect-error TODO upstream fix\n const handleRef = useForkRef( /*#__PURE__*/React.isValidElement(children) ? children.ref : null, forwardedRef);\n useEnhancedEffect(() => {\n if (!disablePortal) {\n setMountNode(getContainer(container) || document.body);\n }\n }, [container, disablePortal]);\n useEnhancedEffect(() => {\n if (mountNode && !disablePortal) {\n setRef(forwardedRef, mountNode);\n return () => {\n setRef(forwardedRef, null);\n };\n }\n return undefined;\n }, [forwardedRef, mountNode, disablePortal]);\n if (disablePortal) {\n if ( /*#__PURE__*/React.isValidElement(children)) {\n const newProps = {\n ref: handleRef\n };\n return /*#__PURE__*/React.cloneElement(children, newProps);\n }\n return /*#__PURE__*/_jsx(React.Fragment, {\n children: children\n });\n }\n return /*#__PURE__*/_jsx(React.Fragment, {\n children: mountNode ? /*#__PURE__*/ReactDOM.createPortal(children, mountNode) : mountNode\n });\n});\nprocess.env.NODE_ENV !== \"production\" ? Portal.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * The children to render into the `container`.\n */\n children: PropTypes.node,\n /**\n * An HTML element or function that returns one.\n * The `container` will have the portal children appended to it.\n *\n * You can also provide a callback, which is called in a React layout effect.\n * This lets you set the container from a ref, and also makes server-side rendering possible.\n *\n * By default, it uses the body of the top-level document object,\n * so it's simply `document.body` most of the time.\n */\n container: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.func]),\n /**\n * The `children` will be under the DOM hierarchy of the parent component.\n * @default false\n */\n disablePortal: PropTypes.bool\n} : void 0;\nif (process.env.NODE_ENV !== 'production') {\n // eslint-disable-next-line\n Portal['propTypes' + ''] = exactProp(Portal.propTypes);\n}\nexport { Portal };","export var top = 'top';\nexport var bottom = 'bottom';\nexport var right = 'right';\nexport var left = 'left';\nexport var auto = 'auto';\nexport var basePlacements = [top, bottom, right, left];\nexport var start = 'start';\nexport var end = 'end';\nexport var clippingParents = 'clippingParents';\nexport var viewport = 'viewport';\nexport var popper = 'popper';\nexport var reference = 'reference';\nexport var variationPlacements = /*#__PURE__*/basePlacements.reduce(function (acc, placement) {\n return acc.concat([placement + \"-\" + start, placement + \"-\" + end]);\n}, []);\nexport var placements = /*#__PURE__*/[].concat(basePlacements, [auto]).reduce(function (acc, placement) {\n return acc.concat([placement, placement + \"-\" + start, placement + \"-\" + end]);\n}, []); // modifiers that need to read the DOM\n\nexport var beforeRead = 'beforeRead';\nexport var read = 'read';\nexport var afterRead = 'afterRead'; // pure-logic modifiers\n\nexport var beforeMain = 'beforeMain';\nexport var main = 'main';\nexport var afterMain = 'afterMain'; // modifier with the purpose to write to the DOM (or write into a framework state)\n\nexport var beforeWrite = 'beforeWrite';\nexport var write = 'write';\nexport var afterWrite = 'afterWrite';\nexport var modifierPhases = [beforeRead, read, afterRead, beforeMain, main, afterMain, beforeWrite, write, afterWrite];","export default function getNodeName(element) {\n return element ? (element.nodeName || '').toLowerCase() : null;\n}","export default function getWindow(node) {\n if (node == null) {\n return window;\n }\n\n if (node.toString() !== '[object Window]') {\n var ownerDocument = node.ownerDocument;\n return ownerDocument ? ownerDocument.defaultView || window : window;\n }\n\n return node;\n}","import getWindow from \"./getWindow.js\";\n\nfunction isElement(node) {\n var OwnElement = getWindow(node).Element;\n return node instanceof OwnElement || node instanceof Element;\n}\n\nfunction isHTMLElement(node) {\n var OwnElement = getWindow(node).HTMLElement;\n return node instanceof OwnElement || node instanceof HTMLElement;\n}\n\nfunction isShadowRoot(node) {\n // IE 11 has no ShadowRoot\n if (typeof ShadowRoot === 'undefined') {\n return false;\n }\n\n var OwnElement = getWindow(node).ShadowRoot;\n return node instanceof OwnElement || node instanceof ShadowRoot;\n}\n\nexport { isElement, isHTMLElement, isShadowRoot };","import getNodeName from \"../dom-utils/getNodeName.js\";\nimport { isHTMLElement } from \"../dom-utils/instanceOf.js\"; // This modifier takes the styles prepared by the `computeStyles` modifier\n// and applies them to the HTMLElements such as popper and arrow\n\nfunction applyStyles(_ref) {\n var state = _ref.state;\n Object.keys(state.elements).forEach(function (name) {\n var style = state.styles[name] || {};\n var attributes = state.attributes[name] || {};\n var element = state.elements[name]; // arrow is optional + virtual elements\n\n if (!isHTMLElement(element) || !getNodeName(element)) {\n return;\n } // Flow doesn't support to extend this property, but it's the most\n // effective way to apply styles to an HTMLElement\n // $FlowFixMe[cannot-write]\n\n\n Object.assign(element.style, style);\n Object.keys(attributes).forEach(function (name) {\n var value = attributes[name];\n\n if (value === false) {\n element.removeAttribute(name);\n } else {\n element.setAttribute(name, value === true ? '' : value);\n }\n });\n });\n}\n\nfunction effect(_ref2) {\n var state = _ref2.state;\n var initialStyles = {\n popper: {\n position: state.options.strategy,\n left: '0',\n top: '0',\n margin: '0'\n },\n arrow: {\n position: 'absolute'\n },\n reference: {}\n };\n Object.assign(state.elements.popper.style, initialStyles.popper);\n state.styles = initialStyles;\n\n if (state.elements.arrow) {\n Object.assign(state.elements.arrow.style, initialStyles.arrow);\n }\n\n return function () {\n Object.keys(state.elements).forEach(function (name) {\n var element = state.elements[name];\n var attributes = state.attributes[name] || {};\n var styleProperties = Object.keys(state.styles.hasOwnProperty(name) ? state.styles[name] : initialStyles[name]); // Set all values to an empty string to unset them\n\n var style = styleProperties.reduce(function (style, property) {\n style[property] = '';\n return style;\n }, {}); // arrow is optional + virtual elements\n\n if (!isHTMLElement(element) || !getNodeName(element)) {\n return;\n }\n\n Object.assign(element.style, style);\n Object.keys(attributes).forEach(function (attribute) {\n element.removeAttribute(attribute);\n });\n });\n };\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'applyStyles',\n enabled: true,\n phase: 'write',\n fn: applyStyles,\n effect: effect,\n requires: ['computeStyles']\n};","import { auto } from \"../enums.js\";\nexport default function getBasePlacement(placement) {\n return placement.split('-')[0];\n}","export var max = Math.max;\nexport var min = Math.min;\nexport var round = Math.round;","export default function getUAString() {\n var uaData = navigator.userAgentData;\n\n if (uaData != null && uaData.brands && Array.isArray(uaData.brands)) {\n return uaData.brands.map(function (item) {\n return item.brand + \"/\" + item.version;\n }).join(' ');\n }\n\n return navigator.userAgent;\n}","import getUAString from \"../utils/userAgent.js\";\nexport default function isLayoutViewport() {\n return !/^((?!chrome|android).)*safari/i.test(getUAString());\n}","import { isElement, isHTMLElement } from \"./instanceOf.js\";\nimport { round } from \"../utils/math.js\";\nimport getWindow from \"./getWindow.js\";\nimport isLayoutViewport from \"./isLayoutViewport.js\";\nexport default function getBoundingClientRect(element, includeScale, isFixedStrategy) {\n if (includeScale === void 0) {\n includeScale = false;\n }\n\n if (isFixedStrategy === void 0) {\n isFixedStrategy = false;\n }\n\n var clientRect = element.getBoundingClientRect();\n var scaleX = 1;\n var scaleY = 1;\n\n if (includeScale && isHTMLElement(element)) {\n scaleX = element.offsetWidth > 0 ? round(clientRect.width) / element.offsetWidth || 1 : 1;\n scaleY = element.offsetHeight > 0 ? round(clientRect.height) / element.offsetHeight || 1 : 1;\n }\n\n var _ref = isElement(element) ? getWindow(element) : window,\n visualViewport = _ref.visualViewport;\n\n var addVisualOffsets = !isLayoutViewport() && isFixedStrategy;\n var x = (clientRect.left + (addVisualOffsets && visualViewport ? visualViewport.offsetLeft : 0)) / scaleX;\n var y = (clientRect.top + (addVisualOffsets && visualViewport ? visualViewport.offsetTop : 0)) / scaleY;\n var width = clientRect.width / scaleX;\n var height = clientRect.height / scaleY;\n return {\n width: width,\n height: height,\n top: y,\n right: x + width,\n bottom: y + height,\n left: x,\n x: x,\n y: y\n };\n}","import getBoundingClientRect from \"./getBoundingClientRect.js\"; // Returns the layout rect of an element relative to its offsetParent. Layout\n// means it doesn't take into account transforms.\n\nexport default function getLayoutRect(element) {\n var clientRect = getBoundingClientRect(element); // Use the clientRect sizes if it's not been transformed.\n // Fixes https://github.com/popperjs/popper-core/issues/1223\n\n var width = element.offsetWidth;\n var height = element.offsetHeight;\n\n if (Math.abs(clientRect.width - width) <= 1) {\n width = clientRect.width;\n }\n\n if (Math.abs(clientRect.height - height) <= 1) {\n height = clientRect.height;\n }\n\n return {\n x: element.offsetLeft,\n y: element.offsetTop,\n width: width,\n height: height\n };\n}","import { isShadowRoot } from \"./instanceOf.js\";\nexport default function contains(parent, child) {\n var rootNode = child.getRootNode && child.getRootNode(); // First, attempt with faster native method\n\n if (parent.contains(child)) {\n return true;\n } // then fallback to custom implementation with Shadow DOM support\n else if (rootNode && isShadowRoot(rootNode)) {\n var next = child;\n\n do {\n if (next && parent.isSameNode(next)) {\n return true;\n } // $FlowFixMe[prop-missing]: need a better way to handle this...\n\n\n next = next.parentNode || next.host;\n } while (next);\n } // Give up, the result is false\n\n\n return false;\n}","import getWindow from \"./getWindow.js\";\nexport default function getComputedStyle(element) {\n return getWindow(element).getComputedStyle(element);\n}","import getNodeName from \"./getNodeName.js\";\nexport default function isTableElement(element) {\n return ['table', 'td', 'th'].indexOf(getNodeName(element)) >= 0;\n}","import { isElement } from \"./instanceOf.js\";\nexport default function getDocumentElement(element) {\n // $FlowFixMe[incompatible-return]: assume body is always available\n return ((isElement(element) ? element.ownerDocument : // $FlowFixMe[prop-missing]\n element.document) || window.document).documentElement;\n}","import getNodeName from \"./getNodeName.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport { isShadowRoot } from \"./instanceOf.js\";\nexport default function getParentNode(element) {\n if (getNodeName(element) === 'html') {\n return element;\n }\n\n return (// this is a quicker (but less type safe) way to save quite some bytes from the bundle\n // $FlowFixMe[incompatible-return]\n // $FlowFixMe[prop-missing]\n element.assignedSlot || // step into the shadow DOM of the parent of a slotted node\n element.parentNode || ( // DOM Element detected\n isShadowRoot(element) ? element.host : null) || // ShadowRoot detected\n // $FlowFixMe[incompatible-call]: HTMLElement is a Node\n getDocumentElement(element) // fallback\n\n );\n}","import getWindow from \"./getWindow.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport getComputedStyle from \"./getComputedStyle.js\";\nimport { isHTMLElement, isShadowRoot } from \"./instanceOf.js\";\nimport isTableElement from \"./isTableElement.js\";\nimport getParentNode from \"./getParentNode.js\";\nimport getUAString from \"../utils/userAgent.js\";\n\nfunction getTrueOffsetParent(element) {\n if (!isHTMLElement(element) || // https://github.com/popperjs/popper-core/issues/837\n getComputedStyle(element).position === 'fixed') {\n return null;\n }\n\n return element.offsetParent;\n} // `.offsetParent` reports `null` for fixed elements, while absolute elements\n// return the containing block\n\n\nfunction getContainingBlock(element) {\n var isFirefox = /firefox/i.test(getUAString());\n var isIE = /Trident/i.test(getUAString());\n\n if (isIE && isHTMLElement(element)) {\n // In IE 9, 10 and 11 fixed elements containing block is always established by the viewport\n var elementCss = getComputedStyle(element);\n\n if (elementCss.position === 'fixed') {\n return null;\n }\n }\n\n var currentNode = getParentNode(element);\n\n if (isShadowRoot(currentNode)) {\n currentNode = currentNode.host;\n }\n\n while (isHTMLElement(currentNode) && ['html', 'body'].indexOf(getNodeName(currentNode)) < 0) {\n var css = getComputedStyle(currentNode); // This is non-exhaustive but covers the most common CSS properties that\n // create a containing block.\n // https://developer.mozilla.org/en-US/docs/Web/CSS/Containing_block#identifying_the_containing_block\n\n if (css.transform !== 'none' || css.perspective !== 'none' || css.contain === 'paint' || ['transform', 'perspective'].indexOf(css.willChange) !== -1 || isFirefox && css.willChange === 'filter' || isFirefox && css.filter && css.filter !== 'none') {\n return currentNode;\n } else {\n currentNode = currentNode.parentNode;\n }\n }\n\n return null;\n} // Gets the closest ancestor positioned element. Handles some edge cases,\n// such as table ancestors and cross browser bugs.\n\n\nexport default function getOffsetParent(element) {\n var window = getWindow(element);\n var offsetParent = getTrueOffsetParent(element);\n\n while (offsetParent && isTableElement(offsetParent) && getComputedStyle(offsetParent).position === 'static') {\n offsetParent = getTrueOffsetParent(offsetParent);\n }\n\n if (offsetParent && (getNodeName(offsetParent) === 'html' || getNodeName(offsetParent) === 'body' && getComputedStyle(offsetParent).position === 'static')) {\n return window;\n }\n\n return offsetParent || getContainingBlock(element) || window;\n}","export default function getMainAxisFromPlacement(placement) {\n return ['top', 'bottom'].indexOf(placement) >= 0 ? 'x' : 'y';\n}","import { max as mathMax, min as mathMin } from \"./math.js\";\nexport function within(min, value, max) {\n return mathMax(min, mathMin(value, max));\n}\nexport function withinMaxClamp(min, value, max) {\n var v = within(min, value, max);\n return v > max ? max : v;\n}","export default function getFreshSideObject() {\n return {\n top: 0,\n right: 0,\n bottom: 0,\n left: 0\n };\n}","import getFreshSideObject from \"./getFreshSideObject.js\";\nexport default function mergePaddingObject(paddingObject) {\n return Object.assign({}, getFreshSideObject(), paddingObject);\n}","export default function expandToHashMap(value, keys) {\n return keys.reduce(function (hashMap, key) {\n hashMap[key] = value;\n return hashMap;\n }, {});\n}","import getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getLayoutRect from \"../dom-utils/getLayoutRect.js\";\nimport contains from \"../dom-utils/contains.js\";\nimport getOffsetParent from \"../dom-utils/getOffsetParent.js\";\nimport getMainAxisFromPlacement from \"../utils/getMainAxisFromPlacement.js\";\nimport { within } from \"../utils/within.js\";\nimport mergePaddingObject from \"../utils/mergePaddingObject.js\";\nimport expandToHashMap from \"../utils/expandToHashMap.js\";\nimport { left, right, basePlacements, top, bottom } from \"../enums.js\"; // eslint-disable-next-line import/no-unused-modules\n\nvar toPaddingObject = function toPaddingObject(padding, state) {\n padding = typeof padding === 'function' ? padding(Object.assign({}, state.rects, {\n placement: state.placement\n })) : padding;\n return mergePaddingObject(typeof padding !== 'number' ? padding : expandToHashMap(padding, basePlacements));\n};\n\nfunction arrow(_ref) {\n var _state$modifiersData$;\n\n var state = _ref.state,\n name = _ref.name,\n options = _ref.options;\n var arrowElement = state.elements.arrow;\n var popperOffsets = state.modifiersData.popperOffsets;\n var basePlacement = getBasePlacement(state.placement);\n var axis = getMainAxisFromPlacement(basePlacement);\n var isVertical = [left, right].indexOf(basePlacement) >= 0;\n var len = isVertical ? 'height' : 'width';\n\n if (!arrowElement || !popperOffsets) {\n return;\n }\n\n var paddingObject = toPaddingObject(options.padding, state);\n var arrowRect = getLayoutRect(arrowElement);\n var minProp = axis === 'y' ? top : left;\n var maxProp = axis === 'y' ? bottom : right;\n var endDiff = state.rects.reference[len] + state.rects.reference[axis] - popperOffsets[axis] - state.rects.popper[len];\n var startDiff = popperOffsets[axis] - state.rects.reference[axis];\n var arrowOffsetParent = getOffsetParent(arrowElement);\n var clientSize = arrowOffsetParent ? axis === 'y' ? arrowOffsetParent.clientHeight || 0 : arrowOffsetParent.clientWidth || 0 : 0;\n var centerToReference = endDiff / 2 - startDiff / 2; // Make sure the arrow doesn't overflow the popper if the center point is\n // outside of the popper bounds\n\n var min = paddingObject[minProp];\n var max = clientSize - arrowRect[len] - paddingObject[maxProp];\n var center = clientSize / 2 - arrowRect[len] / 2 + centerToReference;\n var offset = within(min, center, max); // Prevents breaking syntax highlighting...\n\n var axisProp = axis;\n state.modifiersData[name] = (_state$modifiersData$ = {}, _state$modifiersData$[axisProp] = offset, _state$modifiersData$.centerOffset = offset - center, _state$modifiersData$);\n}\n\nfunction effect(_ref2) {\n var state = _ref2.state,\n options = _ref2.options;\n var _options$element = options.element,\n arrowElement = _options$element === void 0 ? '[data-popper-arrow]' : _options$element;\n\n if (arrowElement == null) {\n return;\n } // CSS selector\n\n\n if (typeof arrowElement === 'string') {\n arrowElement = state.elements.popper.querySelector(arrowElement);\n\n if (!arrowElement) {\n return;\n }\n }\n\n if (!contains(state.elements.popper, arrowElement)) {\n return;\n }\n\n state.elements.arrow = arrowElement;\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'arrow',\n enabled: true,\n phase: 'main',\n fn: arrow,\n effect: effect,\n requires: ['popperOffsets'],\n requiresIfExists: ['preventOverflow']\n};","export default function getVariation(placement) {\n return placement.split('-')[1];\n}","import { top, left, right, bottom, end } from \"../enums.js\";\nimport getOffsetParent from \"../dom-utils/getOffsetParent.js\";\nimport getWindow from \"../dom-utils/getWindow.js\";\nimport getDocumentElement from \"../dom-utils/getDocumentElement.js\";\nimport getComputedStyle from \"../dom-utils/getComputedStyle.js\";\nimport getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getVariation from \"../utils/getVariation.js\";\nimport { round } from \"../utils/math.js\"; // eslint-disable-next-line import/no-unused-modules\n\nvar unsetSides = {\n top: 'auto',\n right: 'auto',\n bottom: 'auto',\n left: 'auto'\n}; // Round the offsets to the nearest suitable subpixel based on the DPR.\n// Zooming can change the DPR, but it seems to report a value that will\n// cleanly divide the values into the appropriate subpixels.\n\nfunction roundOffsetsByDPR(_ref, win) {\n var x = _ref.x,\n y = _ref.y;\n var dpr = win.devicePixelRatio || 1;\n return {\n x: round(x * dpr) / dpr || 0,\n y: round(y * dpr) / dpr || 0\n };\n}\n\nexport function mapToStyles(_ref2) {\n var _Object$assign2;\n\n var popper = _ref2.popper,\n popperRect = _ref2.popperRect,\n placement = _ref2.placement,\n variation = _ref2.variation,\n offsets = _ref2.offsets,\n position = _ref2.position,\n gpuAcceleration = _ref2.gpuAcceleration,\n adaptive = _ref2.adaptive,\n roundOffsets = _ref2.roundOffsets,\n isFixed = _ref2.isFixed;\n var _offsets$x = offsets.x,\n x = _offsets$x === void 0 ? 0 : _offsets$x,\n _offsets$y = offsets.y,\n y = _offsets$y === void 0 ? 0 : _offsets$y;\n\n var _ref3 = typeof roundOffsets === 'function' ? roundOffsets({\n x: x,\n y: y\n }) : {\n x: x,\n y: y\n };\n\n x = _ref3.x;\n y = _ref3.y;\n var hasX = offsets.hasOwnProperty('x');\n var hasY = offsets.hasOwnProperty('y');\n var sideX = left;\n var sideY = top;\n var win = window;\n\n if (adaptive) {\n var offsetParent = getOffsetParent(popper);\n var heightProp = 'clientHeight';\n var widthProp = 'clientWidth';\n\n if (offsetParent === getWindow(popper)) {\n offsetParent = getDocumentElement(popper);\n\n if (getComputedStyle(offsetParent).position !== 'static' && position === 'absolute') {\n heightProp = 'scrollHeight';\n widthProp = 'scrollWidth';\n }\n } // $FlowFixMe[incompatible-cast]: force type refinement, we compare offsetParent with window above, but Flow doesn't detect it\n\n\n offsetParent = offsetParent;\n\n if (placement === top || (placement === left || placement === right) && variation === end) {\n sideY = bottom;\n var offsetY = isFixed && offsetParent === win && win.visualViewport ? win.visualViewport.height : // $FlowFixMe[prop-missing]\n offsetParent[heightProp];\n y -= offsetY - popperRect.height;\n y *= gpuAcceleration ? 1 : -1;\n }\n\n if (placement === left || (placement === top || placement === bottom) && variation === end) {\n sideX = right;\n var offsetX = isFixed && offsetParent === win && win.visualViewport ? win.visualViewport.width : // $FlowFixMe[prop-missing]\n offsetParent[widthProp];\n x -= offsetX - popperRect.width;\n x *= gpuAcceleration ? 1 : -1;\n }\n }\n\n var commonStyles = Object.assign({\n position: position\n }, adaptive && unsetSides);\n\n var _ref4 = roundOffsets === true ? roundOffsetsByDPR({\n x: x,\n y: y\n }, getWindow(popper)) : {\n x: x,\n y: y\n };\n\n x = _ref4.x;\n y = _ref4.y;\n\n if (gpuAcceleration) {\n var _Object$assign;\n\n return Object.assign({}, commonStyles, (_Object$assign = {}, _Object$assign[sideY] = hasY ? '0' : '', _Object$assign[sideX] = hasX ? '0' : '', _Object$assign.transform = (win.devicePixelRatio || 1) <= 1 ? \"translate(\" + x + \"px, \" + y + \"px)\" : \"translate3d(\" + x + \"px, \" + y + \"px, 0)\", _Object$assign));\n }\n\n return Object.assign({}, commonStyles, (_Object$assign2 = {}, _Object$assign2[sideY] = hasY ? y + \"px\" : '', _Object$assign2[sideX] = hasX ? x + \"px\" : '', _Object$assign2.transform = '', _Object$assign2));\n}\n\nfunction computeStyles(_ref5) {\n var state = _ref5.state,\n options = _ref5.options;\n var _options$gpuAccelerat = options.gpuAcceleration,\n gpuAcceleration = _options$gpuAccelerat === void 0 ? true : _options$gpuAccelerat,\n _options$adaptive = options.adaptive,\n adaptive = _options$adaptive === void 0 ? true : _options$adaptive,\n _options$roundOffsets = options.roundOffsets,\n roundOffsets = _options$roundOffsets === void 0 ? true : _options$roundOffsets;\n var commonStyles = {\n placement: getBasePlacement(state.placement),\n variation: getVariation(state.placement),\n popper: state.elements.popper,\n popperRect: state.rects.popper,\n gpuAcceleration: gpuAcceleration,\n isFixed: state.options.strategy === 'fixed'\n };\n\n if (state.modifiersData.popperOffsets != null) {\n state.styles.popper = Object.assign({}, state.styles.popper, mapToStyles(Object.assign({}, commonStyles, {\n offsets: state.modifiersData.popperOffsets,\n position: state.options.strategy,\n adaptive: adaptive,\n roundOffsets: roundOffsets\n })));\n }\n\n if (state.modifiersData.arrow != null) {\n state.styles.arrow = Object.assign({}, state.styles.arrow, mapToStyles(Object.assign({}, commonStyles, {\n offsets: state.modifiersData.arrow,\n position: 'absolute',\n adaptive: false,\n roundOffsets: roundOffsets\n })));\n }\n\n state.attributes.popper = Object.assign({}, state.attributes.popper, {\n 'data-popper-placement': state.placement\n });\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'computeStyles',\n enabled: true,\n phase: 'beforeWrite',\n fn: computeStyles,\n data: {}\n};","import getWindow from \"../dom-utils/getWindow.js\"; // eslint-disable-next-line import/no-unused-modules\n\nvar passive = {\n passive: true\n};\n\nfunction effect(_ref) {\n var state = _ref.state,\n instance = _ref.instance,\n options = _ref.options;\n var _options$scroll = options.scroll,\n scroll = _options$scroll === void 0 ? true : _options$scroll,\n _options$resize = options.resize,\n resize = _options$resize === void 0 ? true : _options$resize;\n var window = getWindow(state.elements.popper);\n var scrollParents = [].concat(state.scrollParents.reference, state.scrollParents.popper);\n\n if (scroll) {\n scrollParents.forEach(function (scrollParent) {\n scrollParent.addEventListener('scroll', instance.update, passive);\n });\n }\n\n if (resize) {\n window.addEventListener('resize', instance.update, passive);\n }\n\n return function () {\n if (scroll) {\n scrollParents.forEach(function (scrollParent) {\n scrollParent.removeEventListener('scroll', instance.update, passive);\n });\n }\n\n if (resize) {\n window.removeEventListener('resize', instance.update, passive);\n }\n };\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'eventListeners',\n enabled: true,\n phase: 'write',\n fn: function fn() {},\n effect: effect,\n data: {}\n};","var hash = {\n left: 'right',\n right: 'left',\n bottom: 'top',\n top: 'bottom'\n};\nexport default function getOppositePlacement(placement) {\n return placement.replace(/left|right|bottom|top/g, function (matched) {\n return hash[matched];\n });\n}","var hash = {\n start: 'end',\n end: 'start'\n};\nexport default function getOppositeVariationPlacement(placement) {\n return placement.replace(/start|end/g, function (matched) {\n return hash[matched];\n });\n}","import getWindow from \"./getWindow.js\";\nexport default function getWindowScroll(node) {\n var win = getWindow(node);\n var scrollLeft = win.pageXOffset;\n var scrollTop = win.pageYOffset;\n return {\n scrollLeft: scrollLeft,\n scrollTop: scrollTop\n };\n}","import getBoundingClientRect from \"./getBoundingClientRect.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport getWindowScroll from \"./getWindowScroll.js\";\nexport default function getWindowScrollBarX(element) {\n // If has a CSS width greater than the viewport, then this will be\n // incorrect for RTL.\n // Popper 1 is broken in this case and never had a bug report so let's assume\n // it's not an issue. I don't think anyone ever specifies width on \n // anyway.\n // Browsers where the left scrollbar doesn't cause an issue report `0` for\n // this (e.g. Edge 2019, IE11, Safari)\n return getBoundingClientRect(getDocumentElement(element)).left + getWindowScroll(element).scrollLeft;\n}","import getWindow from \"./getWindow.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport getWindowScrollBarX from \"./getWindowScrollBarX.js\";\nimport isLayoutViewport from \"./isLayoutViewport.js\";\nexport default function getViewportRect(element, strategy) {\n var win = getWindow(element);\n var html = getDocumentElement(element);\n var visualViewport = win.visualViewport;\n var width = html.clientWidth;\n var height = html.clientHeight;\n var x = 0;\n var y = 0;\n\n if (visualViewport) {\n width = visualViewport.width;\n height = visualViewport.height;\n var layoutViewport = isLayoutViewport();\n\n if (layoutViewport || !layoutViewport && strategy === 'fixed') {\n x = visualViewport.offsetLeft;\n y = visualViewport.offsetTop;\n }\n }\n\n return {\n width: width,\n height: height,\n x: x + getWindowScrollBarX(element),\n y: y\n };\n}","import getDocumentElement from \"./getDocumentElement.js\";\nimport getComputedStyle from \"./getComputedStyle.js\";\nimport getWindowScrollBarX from \"./getWindowScrollBarX.js\";\nimport getWindowScroll from \"./getWindowScroll.js\";\nimport { max } from \"../utils/math.js\"; // Gets the entire size of the scrollable document area, even extending outside\n// of the `` and `` rect bounds if horizontally scrollable\n\nexport default function getDocumentRect(element) {\n var _element$ownerDocumen;\n\n var html = getDocumentElement(element);\n var winScroll = getWindowScroll(element);\n var body = (_element$ownerDocumen = element.ownerDocument) == null ? void 0 : _element$ownerDocumen.body;\n var width = max(html.scrollWidth, html.clientWidth, body ? body.scrollWidth : 0, body ? body.clientWidth : 0);\n var height = max(html.scrollHeight, html.clientHeight, body ? body.scrollHeight : 0, body ? body.clientHeight : 0);\n var x = -winScroll.scrollLeft + getWindowScrollBarX(element);\n var y = -winScroll.scrollTop;\n\n if (getComputedStyle(body || html).direction === 'rtl') {\n x += max(html.clientWidth, body ? body.clientWidth : 0) - width;\n }\n\n return {\n width: width,\n height: height,\n x: x,\n y: y\n };\n}","import getComputedStyle from \"./getComputedStyle.js\";\nexport default function isScrollParent(element) {\n // Firefox wants us to check `-x` and `-y` variations as well\n var _getComputedStyle = getComputedStyle(element),\n overflow = _getComputedStyle.overflow,\n overflowX = _getComputedStyle.overflowX,\n overflowY = _getComputedStyle.overflowY;\n\n return /auto|scroll|overlay|hidden/.test(overflow + overflowY + overflowX);\n}","import getParentNode from \"./getParentNode.js\";\nimport isScrollParent from \"./isScrollParent.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport { isHTMLElement } from \"./instanceOf.js\";\nexport default function getScrollParent(node) {\n if (['html', 'body', '#document'].indexOf(getNodeName(node)) >= 0) {\n // $FlowFixMe[incompatible-return]: assume body is always available\n return node.ownerDocument.body;\n }\n\n if (isHTMLElement(node) && isScrollParent(node)) {\n return node;\n }\n\n return getScrollParent(getParentNode(node));\n}","import getScrollParent from \"./getScrollParent.js\";\nimport getParentNode from \"./getParentNode.js\";\nimport getWindow from \"./getWindow.js\";\nimport isScrollParent from \"./isScrollParent.js\";\n/*\ngiven a DOM element, return the list of all scroll parents, up the list of ancesors\nuntil we get to the top window object. This list is what we attach scroll listeners\nto, because if any of these parent elements scroll, we'll need to re-calculate the\nreference element's position.\n*/\n\nexport default function listScrollParents(element, list) {\n var _element$ownerDocumen;\n\n if (list === void 0) {\n list = [];\n }\n\n var scrollParent = getScrollParent(element);\n var isBody = scrollParent === ((_element$ownerDocumen = element.ownerDocument) == null ? void 0 : _element$ownerDocumen.body);\n var win = getWindow(scrollParent);\n var target = isBody ? [win].concat(win.visualViewport || [], isScrollParent(scrollParent) ? scrollParent : []) : scrollParent;\n var updatedList = list.concat(target);\n return isBody ? updatedList : // $FlowFixMe[incompatible-call]: isBody tells us target will be an HTMLElement here\n updatedList.concat(listScrollParents(getParentNode(target)));\n}","export default function rectToClientRect(rect) {\n return Object.assign({}, rect, {\n left: rect.x,\n top: rect.y,\n right: rect.x + rect.width,\n bottom: rect.y + rect.height\n });\n}","import { viewport } from \"../enums.js\";\nimport getViewportRect from \"./getViewportRect.js\";\nimport getDocumentRect from \"./getDocumentRect.js\";\nimport listScrollParents from \"./listScrollParents.js\";\nimport getOffsetParent from \"./getOffsetParent.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport getComputedStyle from \"./getComputedStyle.js\";\nimport { isElement, isHTMLElement } from \"./instanceOf.js\";\nimport getBoundingClientRect from \"./getBoundingClientRect.js\";\nimport getParentNode from \"./getParentNode.js\";\nimport contains from \"./contains.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport rectToClientRect from \"../utils/rectToClientRect.js\";\nimport { max, min } from \"../utils/math.js\";\n\nfunction getInnerBoundingClientRect(element, strategy) {\n var rect = getBoundingClientRect(element, false, strategy === 'fixed');\n rect.top = rect.top + element.clientTop;\n rect.left = rect.left + element.clientLeft;\n rect.bottom = rect.top + element.clientHeight;\n rect.right = rect.left + element.clientWidth;\n rect.width = element.clientWidth;\n rect.height = element.clientHeight;\n rect.x = rect.left;\n rect.y = rect.top;\n return rect;\n}\n\nfunction getClientRectFromMixedType(element, clippingParent, strategy) {\n return clippingParent === viewport ? rectToClientRect(getViewportRect(element, strategy)) : isElement(clippingParent) ? getInnerBoundingClientRect(clippingParent, strategy) : rectToClientRect(getDocumentRect(getDocumentElement(element)));\n} // A \"clipping parent\" is an overflowable container with the characteristic of\n// clipping (or hiding) overflowing elements with a position different from\n// `initial`\n\n\nfunction getClippingParents(element) {\n var clippingParents = listScrollParents(getParentNode(element));\n var canEscapeClipping = ['absolute', 'fixed'].indexOf(getComputedStyle(element).position) >= 0;\n var clipperElement = canEscapeClipping && isHTMLElement(element) ? getOffsetParent(element) : element;\n\n if (!isElement(clipperElement)) {\n return [];\n } // $FlowFixMe[incompatible-return]: https://github.com/facebook/flow/issues/1414\n\n\n return clippingParents.filter(function (clippingParent) {\n return isElement(clippingParent) && contains(clippingParent, clipperElement) && getNodeName(clippingParent) !== 'body';\n });\n} // Gets the maximum area that the element is visible in due to any number of\n// clipping parents\n\n\nexport default function getClippingRect(element, boundary, rootBoundary, strategy) {\n var mainClippingParents = boundary === 'clippingParents' ? getClippingParents(element) : [].concat(boundary);\n var clippingParents = [].concat(mainClippingParents, [rootBoundary]);\n var firstClippingParent = clippingParents[0];\n var clippingRect = clippingParents.reduce(function (accRect, clippingParent) {\n var rect = getClientRectFromMixedType(element, clippingParent, strategy);\n accRect.top = max(rect.top, accRect.top);\n accRect.right = min(rect.right, accRect.right);\n accRect.bottom = min(rect.bottom, accRect.bottom);\n accRect.left = max(rect.left, accRect.left);\n return accRect;\n }, getClientRectFromMixedType(element, firstClippingParent, strategy));\n clippingRect.width = clippingRect.right - clippingRect.left;\n clippingRect.height = clippingRect.bottom - clippingRect.top;\n clippingRect.x = clippingRect.left;\n clippingRect.y = clippingRect.top;\n return clippingRect;\n}","import getBasePlacement from \"./getBasePlacement.js\";\nimport getVariation from \"./getVariation.js\";\nimport getMainAxisFromPlacement from \"./getMainAxisFromPlacement.js\";\nimport { top, right, bottom, left, start, end } from \"../enums.js\";\nexport default function computeOffsets(_ref) {\n var reference = _ref.reference,\n element = _ref.element,\n placement = _ref.placement;\n var basePlacement = placement ? getBasePlacement(placement) : null;\n var variation = placement ? getVariation(placement) : null;\n var commonX = reference.x + reference.width / 2 - element.width / 2;\n var commonY = reference.y + reference.height / 2 - element.height / 2;\n var offsets;\n\n switch (basePlacement) {\n case top:\n offsets = {\n x: commonX,\n y: reference.y - element.height\n };\n break;\n\n case bottom:\n offsets = {\n x: commonX,\n y: reference.y + reference.height\n };\n break;\n\n case right:\n offsets = {\n x: reference.x + reference.width,\n y: commonY\n };\n break;\n\n case left:\n offsets = {\n x: reference.x - element.width,\n y: commonY\n };\n break;\n\n default:\n offsets = {\n x: reference.x,\n y: reference.y\n };\n }\n\n var mainAxis = basePlacement ? getMainAxisFromPlacement(basePlacement) : null;\n\n if (mainAxis != null) {\n var len = mainAxis === 'y' ? 'height' : 'width';\n\n switch (variation) {\n case start:\n offsets[mainAxis] = offsets[mainAxis] - (reference[len] / 2 - element[len] / 2);\n break;\n\n case end:\n offsets[mainAxis] = offsets[mainAxis] + (reference[len] / 2 - element[len] / 2);\n break;\n\n default:\n }\n }\n\n return offsets;\n}","import getClippingRect from \"../dom-utils/getClippingRect.js\";\nimport getDocumentElement from \"../dom-utils/getDocumentElement.js\";\nimport getBoundingClientRect from \"../dom-utils/getBoundingClientRect.js\";\nimport computeOffsets from \"./computeOffsets.js\";\nimport rectToClientRect from \"./rectToClientRect.js\";\nimport { clippingParents, reference, popper, bottom, top, right, basePlacements, viewport } from \"../enums.js\";\nimport { isElement } from \"../dom-utils/instanceOf.js\";\nimport mergePaddingObject from \"./mergePaddingObject.js\";\nimport expandToHashMap from \"./expandToHashMap.js\"; // eslint-disable-next-line import/no-unused-modules\n\nexport default function detectOverflow(state, options) {\n if (options === void 0) {\n options = {};\n }\n\n var _options = options,\n _options$placement = _options.placement,\n placement = _options$placement === void 0 ? state.placement : _options$placement,\n _options$strategy = _options.strategy,\n strategy = _options$strategy === void 0 ? state.strategy : _options$strategy,\n _options$boundary = _options.boundary,\n boundary = _options$boundary === void 0 ? clippingParents : _options$boundary,\n _options$rootBoundary = _options.rootBoundary,\n rootBoundary = _options$rootBoundary === void 0 ? viewport : _options$rootBoundary,\n _options$elementConte = _options.elementContext,\n elementContext = _options$elementConte === void 0 ? popper : _options$elementConte,\n _options$altBoundary = _options.altBoundary,\n altBoundary = _options$altBoundary === void 0 ? false : _options$altBoundary,\n _options$padding = _options.padding,\n padding = _options$padding === void 0 ? 0 : _options$padding;\n var paddingObject = mergePaddingObject(typeof padding !== 'number' ? padding : expandToHashMap(padding, basePlacements));\n var altContext = elementContext === popper ? reference : popper;\n var popperRect = state.rects.popper;\n var element = state.elements[altBoundary ? altContext : elementContext];\n var clippingClientRect = getClippingRect(isElement(element) ? element : element.contextElement || getDocumentElement(state.elements.popper), boundary, rootBoundary, strategy);\n var referenceClientRect = getBoundingClientRect(state.elements.reference);\n var popperOffsets = computeOffsets({\n reference: referenceClientRect,\n element: popperRect,\n strategy: 'absolute',\n placement: placement\n });\n var popperClientRect = rectToClientRect(Object.assign({}, popperRect, popperOffsets));\n var elementClientRect = elementContext === popper ? popperClientRect : referenceClientRect; // positive = overflowing the clipping rect\n // 0 or negative = within the clipping rect\n\n var overflowOffsets = {\n top: clippingClientRect.top - elementClientRect.top + paddingObject.top,\n bottom: elementClientRect.bottom - clippingClientRect.bottom + paddingObject.bottom,\n left: clippingClientRect.left - elementClientRect.left + paddingObject.left,\n right: elementClientRect.right - clippingClientRect.right + paddingObject.right\n };\n var offsetData = state.modifiersData.offset; // Offsets can be applied only to the popper element\n\n if (elementContext === popper && offsetData) {\n var offset = offsetData[placement];\n Object.keys(overflowOffsets).forEach(function (key) {\n var multiply = [right, bottom].indexOf(key) >= 0 ? 1 : -1;\n var axis = [top, bottom].indexOf(key) >= 0 ? 'y' : 'x';\n overflowOffsets[key] += offset[axis] * multiply;\n });\n }\n\n return overflowOffsets;\n}","import getVariation from \"./getVariation.js\";\nimport { variationPlacements, basePlacements, placements as allPlacements } from \"../enums.js\";\nimport detectOverflow from \"./detectOverflow.js\";\nimport getBasePlacement from \"./getBasePlacement.js\";\nexport default function computeAutoPlacement(state, options) {\n if (options === void 0) {\n options = {};\n }\n\n var _options = options,\n placement = _options.placement,\n boundary = _options.boundary,\n rootBoundary = _options.rootBoundary,\n padding = _options.padding,\n flipVariations = _options.flipVariations,\n _options$allowedAutoP = _options.allowedAutoPlacements,\n allowedAutoPlacements = _options$allowedAutoP === void 0 ? allPlacements : _options$allowedAutoP;\n var variation = getVariation(placement);\n var placements = variation ? flipVariations ? variationPlacements : variationPlacements.filter(function (placement) {\n return getVariation(placement) === variation;\n }) : basePlacements;\n var allowedPlacements = placements.filter(function (placement) {\n return allowedAutoPlacements.indexOf(placement) >= 0;\n });\n\n if (allowedPlacements.length === 0) {\n allowedPlacements = placements;\n } // $FlowFixMe[incompatible-type]: Flow seems to have problems with two array unions...\n\n\n var overflows = allowedPlacements.reduce(function (acc, placement) {\n acc[placement] = detectOverflow(state, {\n placement: placement,\n boundary: boundary,\n rootBoundary: rootBoundary,\n padding: padding\n })[getBasePlacement(placement)];\n return acc;\n }, {});\n return Object.keys(overflows).sort(function (a, b) {\n return overflows[a] - overflows[b];\n });\n}","import getOppositePlacement from \"../utils/getOppositePlacement.js\";\nimport getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getOppositeVariationPlacement from \"../utils/getOppositeVariationPlacement.js\";\nimport detectOverflow from \"../utils/detectOverflow.js\";\nimport computeAutoPlacement from \"../utils/computeAutoPlacement.js\";\nimport { bottom, top, start, right, left, auto } from \"../enums.js\";\nimport getVariation from \"../utils/getVariation.js\"; // eslint-disable-next-line import/no-unused-modules\n\nfunction getExpandedFallbackPlacements(placement) {\n if (getBasePlacement(placement) === auto) {\n return [];\n }\n\n var oppositePlacement = getOppositePlacement(placement);\n return [getOppositeVariationPlacement(placement), oppositePlacement, getOppositeVariationPlacement(oppositePlacement)];\n}\n\nfunction flip(_ref) {\n var state = _ref.state,\n options = _ref.options,\n name = _ref.name;\n\n if (state.modifiersData[name]._skip) {\n return;\n }\n\n var _options$mainAxis = options.mainAxis,\n checkMainAxis = _options$mainAxis === void 0 ? true : _options$mainAxis,\n _options$altAxis = options.altAxis,\n checkAltAxis = _options$altAxis === void 0 ? true : _options$altAxis,\n specifiedFallbackPlacements = options.fallbackPlacements,\n padding = options.padding,\n boundary = options.boundary,\n rootBoundary = options.rootBoundary,\n altBoundary = options.altBoundary,\n _options$flipVariatio = options.flipVariations,\n flipVariations = _options$flipVariatio === void 0 ? true : _options$flipVariatio,\n allowedAutoPlacements = options.allowedAutoPlacements;\n var preferredPlacement = state.options.placement;\n var basePlacement = getBasePlacement(preferredPlacement);\n var isBasePlacement = basePlacement === preferredPlacement;\n var fallbackPlacements = specifiedFallbackPlacements || (isBasePlacement || !flipVariations ? [getOppositePlacement(preferredPlacement)] : getExpandedFallbackPlacements(preferredPlacement));\n var placements = [preferredPlacement].concat(fallbackPlacements).reduce(function (acc, placement) {\n return acc.concat(getBasePlacement(placement) === auto ? computeAutoPlacement(state, {\n placement: placement,\n boundary: boundary,\n rootBoundary: rootBoundary,\n padding: padding,\n flipVariations: flipVariations,\n allowedAutoPlacements: allowedAutoPlacements\n }) : placement);\n }, []);\n var referenceRect = state.rects.reference;\n var popperRect = state.rects.popper;\n var checksMap = new Map();\n var makeFallbackChecks = true;\n var firstFittingPlacement = placements[0];\n\n for (var i = 0; i < placements.length; i++) {\n var placement = placements[i];\n\n var _basePlacement = getBasePlacement(placement);\n\n var isStartVariation = getVariation(placement) === start;\n var isVertical = [top, bottom].indexOf(_basePlacement) >= 0;\n var len = isVertical ? 'width' : 'height';\n var overflow = detectOverflow(state, {\n placement: placement,\n boundary: boundary,\n rootBoundary: rootBoundary,\n altBoundary: altBoundary,\n padding: padding\n });\n var mainVariationSide = isVertical ? isStartVariation ? right : left : isStartVariation ? bottom : top;\n\n if (referenceRect[len] > popperRect[len]) {\n mainVariationSide = getOppositePlacement(mainVariationSide);\n }\n\n var altVariationSide = getOppositePlacement(mainVariationSide);\n var checks = [];\n\n if (checkMainAxis) {\n checks.push(overflow[_basePlacement] <= 0);\n }\n\n if (checkAltAxis) {\n checks.push(overflow[mainVariationSide] <= 0, overflow[altVariationSide] <= 0);\n }\n\n if (checks.every(function (check) {\n return check;\n })) {\n firstFittingPlacement = placement;\n makeFallbackChecks = false;\n break;\n }\n\n checksMap.set(placement, checks);\n }\n\n if (makeFallbackChecks) {\n // `2` may be desired in some cases – research later\n var numberOfChecks = flipVariations ? 3 : 1;\n\n var _loop = function _loop(_i) {\n var fittingPlacement = placements.find(function (placement) {\n var checks = checksMap.get(placement);\n\n if (checks) {\n return checks.slice(0, _i).every(function (check) {\n return check;\n });\n }\n });\n\n if (fittingPlacement) {\n firstFittingPlacement = fittingPlacement;\n return \"break\";\n }\n };\n\n for (var _i = numberOfChecks; _i > 0; _i--) {\n var _ret = _loop(_i);\n\n if (_ret === \"break\") break;\n }\n }\n\n if (state.placement !== firstFittingPlacement) {\n state.modifiersData[name]._skip = true;\n state.placement = firstFittingPlacement;\n state.reset = true;\n }\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'flip',\n enabled: true,\n phase: 'main',\n fn: flip,\n requiresIfExists: ['offset'],\n data: {\n _skip: false\n }\n};","import { top, bottom, left, right } from \"../enums.js\";\nimport detectOverflow from \"../utils/detectOverflow.js\";\n\nfunction getSideOffsets(overflow, rect, preventedOffsets) {\n if (preventedOffsets === void 0) {\n preventedOffsets = {\n x: 0,\n y: 0\n };\n }\n\n return {\n top: overflow.top - rect.height - preventedOffsets.y,\n right: overflow.right - rect.width + preventedOffsets.x,\n bottom: overflow.bottom - rect.height + preventedOffsets.y,\n left: overflow.left - rect.width - preventedOffsets.x\n };\n}\n\nfunction isAnySideFullyClipped(overflow) {\n return [top, right, bottom, left].some(function (side) {\n return overflow[side] >= 0;\n });\n}\n\nfunction hide(_ref) {\n var state = _ref.state,\n name = _ref.name;\n var referenceRect = state.rects.reference;\n var popperRect = state.rects.popper;\n var preventedOffsets = state.modifiersData.preventOverflow;\n var referenceOverflow = detectOverflow(state, {\n elementContext: 'reference'\n });\n var popperAltOverflow = detectOverflow(state, {\n altBoundary: true\n });\n var referenceClippingOffsets = getSideOffsets(referenceOverflow, referenceRect);\n var popperEscapeOffsets = getSideOffsets(popperAltOverflow, popperRect, preventedOffsets);\n var isReferenceHidden = isAnySideFullyClipped(referenceClippingOffsets);\n var hasPopperEscaped = isAnySideFullyClipped(popperEscapeOffsets);\n state.modifiersData[name] = {\n referenceClippingOffsets: referenceClippingOffsets,\n popperEscapeOffsets: popperEscapeOffsets,\n isReferenceHidden: isReferenceHidden,\n hasPopperEscaped: hasPopperEscaped\n };\n state.attributes.popper = Object.assign({}, state.attributes.popper, {\n 'data-popper-reference-hidden': isReferenceHidden,\n 'data-popper-escaped': hasPopperEscaped\n });\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'hide',\n enabled: true,\n phase: 'main',\n requiresIfExists: ['preventOverflow'],\n fn: hide\n};","import getBasePlacement from \"../utils/getBasePlacement.js\";\nimport { top, left, right, placements } from \"../enums.js\"; // eslint-disable-next-line import/no-unused-modules\n\nexport function distanceAndSkiddingToXY(placement, rects, offset) {\n var basePlacement = getBasePlacement(placement);\n var invertDistance = [left, top].indexOf(basePlacement) >= 0 ? -1 : 1;\n\n var _ref = typeof offset === 'function' ? offset(Object.assign({}, rects, {\n placement: placement\n })) : offset,\n skidding = _ref[0],\n distance = _ref[1];\n\n skidding = skidding || 0;\n distance = (distance || 0) * invertDistance;\n return [left, right].indexOf(basePlacement) >= 0 ? {\n x: distance,\n y: skidding\n } : {\n x: skidding,\n y: distance\n };\n}\n\nfunction offset(_ref2) {\n var state = _ref2.state,\n options = _ref2.options,\n name = _ref2.name;\n var _options$offset = options.offset,\n offset = _options$offset === void 0 ? [0, 0] : _options$offset;\n var data = placements.reduce(function (acc, placement) {\n acc[placement] = distanceAndSkiddingToXY(placement, state.rects, offset);\n return acc;\n }, {});\n var _data$state$placement = data[state.placement],\n x = _data$state$placement.x,\n y = _data$state$placement.y;\n\n if (state.modifiersData.popperOffsets != null) {\n state.modifiersData.popperOffsets.x += x;\n state.modifiersData.popperOffsets.y += y;\n }\n\n state.modifiersData[name] = data;\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'offset',\n enabled: true,\n phase: 'main',\n requires: ['popperOffsets'],\n fn: offset\n};","import computeOffsets from \"../utils/computeOffsets.js\";\n\nfunction popperOffsets(_ref) {\n var state = _ref.state,\n name = _ref.name;\n // Offsets are the actual position the popper needs to have to be\n // properly positioned near its reference element\n // This is the most basic placement, and will be adjusted by\n // the modifiers in the next step\n state.modifiersData[name] = computeOffsets({\n reference: state.rects.reference,\n element: state.rects.popper,\n strategy: 'absolute',\n placement: state.placement\n });\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'popperOffsets',\n enabled: true,\n phase: 'read',\n fn: popperOffsets,\n data: {}\n};","export default function getAltAxis(axis) {\n return axis === 'x' ? 'y' : 'x';\n}","import { top, left, right, bottom, start } from \"../enums.js\";\nimport getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getMainAxisFromPlacement from \"../utils/getMainAxisFromPlacement.js\";\nimport getAltAxis from \"../utils/getAltAxis.js\";\nimport { within, withinMaxClamp } from \"../utils/within.js\";\nimport getLayoutRect from \"../dom-utils/getLayoutRect.js\";\nimport getOffsetParent from \"../dom-utils/getOffsetParent.js\";\nimport detectOverflow from \"../utils/detectOverflow.js\";\nimport getVariation from \"../utils/getVariation.js\";\nimport getFreshSideObject from \"../utils/getFreshSideObject.js\";\nimport { min as mathMin, max as mathMax } from \"../utils/math.js\";\n\nfunction preventOverflow(_ref) {\n var state = _ref.state,\n options = _ref.options,\n name = _ref.name;\n var _options$mainAxis = options.mainAxis,\n checkMainAxis = _options$mainAxis === void 0 ? true : _options$mainAxis,\n _options$altAxis = options.altAxis,\n checkAltAxis = _options$altAxis === void 0 ? false : _options$altAxis,\n boundary = options.boundary,\n rootBoundary = options.rootBoundary,\n altBoundary = options.altBoundary,\n padding = options.padding,\n _options$tether = options.tether,\n tether = _options$tether === void 0 ? true : _options$tether,\n _options$tetherOffset = options.tetherOffset,\n tetherOffset = _options$tetherOffset === void 0 ? 0 : _options$tetherOffset;\n var overflow = detectOverflow(state, {\n boundary: boundary,\n rootBoundary: rootBoundary,\n padding: padding,\n altBoundary: altBoundary\n });\n var basePlacement = getBasePlacement(state.placement);\n var variation = getVariation(state.placement);\n var isBasePlacement = !variation;\n var mainAxis = getMainAxisFromPlacement(basePlacement);\n var altAxis = getAltAxis(mainAxis);\n var popperOffsets = state.modifiersData.popperOffsets;\n var referenceRect = state.rects.reference;\n var popperRect = state.rects.popper;\n var tetherOffsetValue = typeof tetherOffset === 'function' ? tetherOffset(Object.assign({}, state.rects, {\n placement: state.placement\n })) : tetherOffset;\n var normalizedTetherOffsetValue = typeof tetherOffsetValue === 'number' ? {\n mainAxis: tetherOffsetValue,\n altAxis: tetherOffsetValue\n } : Object.assign({\n mainAxis: 0,\n altAxis: 0\n }, tetherOffsetValue);\n var offsetModifierState = state.modifiersData.offset ? state.modifiersData.offset[state.placement] : null;\n var data = {\n x: 0,\n y: 0\n };\n\n if (!popperOffsets) {\n return;\n }\n\n if (checkMainAxis) {\n var _offsetModifierState$;\n\n var mainSide = mainAxis === 'y' ? top : left;\n var altSide = mainAxis === 'y' ? bottom : right;\n var len = mainAxis === 'y' ? 'height' : 'width';\n var offset = popperOffsets[mainAxis];\n var min = offset + overflow[mainSide];\n var max = offset - overflow[altSide];\n var additive = tether ? -popperRect[len] / 2 : 0;\n var minLen = variation === start ? referenceRect[len] : popperRect[len];\n var maxLen = variation === start ? -popperRect[len] : -referenceRect[len]; // We need to include the arrow in the calculation so the arrow doesn't go\n // outside the reference bounds\n\n var arrowElement = state.elements.arrow;\n var arrowRect = tether && arrowElement ? getLayoutRect(arrowElement) : {\n width: 0,\n height: 0\n };\n var arrowPaddingObject = state.modifiersData['arrow#persistent'] ? state.modifiersData['arrow#persistent'].padding : getFreshSideObject();\n var arrowPaddingMin = arrowPaddingObject[mainSide];\n var arrowPaddingMax = arrowPaddingObject[altSide]; // If the reference length is smaller than the arrow length, we don't want\n // to include its full size in the calculation. If the reference is small\n // and near the edge of a boundary, the popper can overflow even if the\n // reference is not overflowing as well (e.g. virtual elements with no\n // width or height)\n\n var arrowLen = within(0, referenceRect[len], arrowRect[len]);\n var minOffset = isBasePlacement ? referenceRect[len] / 2 - additive - arrowLen - arrowPaddingMin - normalizedTetherOffsetValue.mainAxis : minLen - arrowLen - arrowPaddingMin - normalizedTetherOffsetValue.mainAxis;\n var maxOffset = isBasePlacement ? -referenceRect[len] / 2 + additive + arrowLen + arrowPaddingMax + normalizedTetherOffsetValue.mainAxis : maxLen + arrowLen + arrowPaddingMax + normalizedTetherOffsetValue.mainAxis;\n var arrowOffsetParent = state.elements.arrow && getOffsetParent(state.elements.arrow);\n var clientOffset = arrowOffsetParent ? mainAxis === 'y' ? arrowOffsetParent.clientTop || 0 : arrowOffsetParent.clientLeft || 0 : 0;\n var offsetModifierValue = (_offsetModifierState$ = offsetModifierState == null ? void 0 : offsetModifierState[mainAxis]) != null ? _offsetModifierState$ : 0;\n var tetherMin = offset + minOffset - offsetModifierValue - clientOffset;\n var tetherMax = offset + maxOffset - offsetModifierValue;\n var preventedOffset = within(tether ? mathMin(min, tetherMin) : min, offset, tether ? mathMax(max, tetherMax) : max);\n popperOffsets[mainAxis] = preventedOffset;\n data[mainAxis] = preventedOffset - offset;\n }\n\n if (checkAltAxis) {\n var _offsetModifierState$2;\n\n var _mainSide = mainAxis === 'x' ? top : left;\n\n var _altSide = mainAxis === 'x' ? bottom : right;\n\n var _offset = popperOffsets[altAxis];\n\n var _len = altAxis === 'y' ? 'height' : 'width';\n\n var _min = _offset + overflow[_mainSide];\n\n var _max = _offset - overflow[_altSide];\n\n var isOriginSide = [top, left].indexOf(basePlacement) !== -1;\n\n var _offsetModifierValue = (_offsetModifierState$2 = offsetModifierState == null ? void 0 : offsetModifierState[altAxis]) != null ? _offsetModifierState$2 : 0;\n\n var _tetherMin = isOriginSide ? _min : _offset - referenceRect[_len] - popperRect[_len] - _offsetModifierValue + normalizedTetherOffsetValue.altAxis;\n\n var _tetherMax = isOriginSide ? _offset + referenceRect[_len] + popperRect[_len] - _offsetModifierValue - normalizedTetherOffsetValue.altAxis : _max;\n\n var _preventedOffset = tether && isOriginSide ? withinMaxClamp(_tetherMin, _offset, _tetherMax) : within(tether ? _tetherMin : _min, _offset, tether ? _tetherMax : _max);\n\n popperOffsets[altAxis] = _preventedOffset;\n data[altAxis] = _preventedOffset - _offset;\n }\n\n state.modifiersData[name] = data;\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'preventOverflow',\n enabled: true,\n phase: 'main',\n fn: preventOverflow,\n requiresIfExists: ['offset']\n};","export default function getHTMLElementScroll(element) {\n return {\n scrollLeft: element.scrollLeft,\n scrollTop: element.scrollTop\n };\n}","import getWindowScroll from \"./getWindowScroll.js\";\nimport getWindow from \"./getWindow.js\";\nimport { isHTMLElement } from \"./instanceOf.js\";\nimport getHTMLElementScroll from \"./getHTMLElementScroll.js\";\nexport default function getNodeScroll(node) {\n if (node === getWindow(node) || !isHTMLElement(node)) {\n return getWindowScroll(node);\n } else {\n return getHTMLElementScroll(node);\n }\n}","import getBoundingClientRect from \"./getBoundingClientRect.js\";\nimport getNodeScroll from \"./getNodeScroll.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport { isHTMLElement } from \"./instanceOf.js\";\nimport getWindowScrollBarX from \"./getWindowScrollBarX.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport isScrollParent from \"./isScrollParent.js\";\nimport { round } from \"../utils/math.js\";\n\nfunction isElementScaled(element) {\n var rect = element.getBoundingClientRect();\n var scaleX = round(rect.width) / element.offsetWidth || 1;\n var scaleY = round(rect.height) / element.offsetHeight || 1;\n return scaleX !== 1 || scaleY !== 1;\n} // Returns the composite rect of an element relative to its offsetParent.\n// Composite means it takes into account transforms as well as layout.\n\n\nexport default function getCompositeRect(elementOrVirtualElement, offsetParent, isFixed) {\n if (isFixed === void 0) {\n isFixed = false;\n }\n\n var isOffsetParentAnElement = isHTMLElement(offsetParent);\n var offsetParentIsScaled = isHTMLElement(offsetParent) && isElementScaled(offsetParent);\n var documentElement = getDocumentElement(offsetParent);\n var rect = getBoundingClientRect(elementOrVirtualElement, offsetParentIsScaled, isFixed);\n var scroll = {\n scrollLeft: 0,\n scrollTop: 0\n };\n var offsets = {\n x: 0,\n y: 0\n };\n\n if (isOffsetParentAnElement || !isOffsetParentAnElement && !isFixed) {\n if (getNodeName(offsetParent) !== 'body' || // https://github.com/popperjs/popper-core/issues/1078\n isScrollParent(documentElement)) {\n scroll = getNodeScroll(offsetParent);\n }\n\n if (isHTMLElement(offsetParent)) {\n offsets = getBoundingClientRect(offsetParent, true);\n offsets.x += offsetParent.clientLeft;\n offsets.y += offsetParent.clientTop;\n } else if (documentElement) {\n offsets.x = getWindowScrollBarX(documentElement);\n }\n }\n\n return {\n x: rect.left + scroll.scrollLeft - offsets.x,\n y: rect.top + scroll.scrollTop - offsets.y,\n width: rect.width,\n height: rect.height\n };\n}","import { modifierPhases } from \"../enums.js\"; // source: https://stackoverflow.com/questions/49875255\n\nfunction order(modifiers) {\n var map = new Map();\n var visited = new Set();\n var result = [];\n modifiers.forEach(function (modifier) {\n map.set(modifier.name, modifier);\n }); // On visiting object, check for its dependencies and visit them recursively\n\n function sort(modifier) {\n visited.add(modifier.name);\n var requires = [].concat(modifier.requires || [], modifier.requiresIfExists || []);\n requires.forEach(function (dep) {\n if (!visited.has(dep)) {\n var depModifier = map.get(dep);\n\n if (depModifier) {\n sort(depModifier);\n }\n }\n });\n result.push(modifier);\n }\n\n modifiers.forEach(function (modifier) {\n if (!visited.has(modifier.name)) {\n // check for visited object\n sort(modifier);\n }\n });\n return result;\n}\n\nexport default function orderModifiers(modifiers) {\n // order based on dependencies\n var orderedModifiers = order(modifiers); // order based on phase\n\n return modifierPhases.reduce(function (acc, phase) {\n return acc.concat(orderedModifiers.filter(function (modifier) {\n return modifier.phase === phase;\n }));\n }, []);\n}","export default function debounce(fn) {\n var pending;\n return function () {\n if (!pending) {\n pending = new Promise(function (resolve) {\n Promise.resolve().then(function () {\n pending = undefined;\n resolve(fn());\n });\n });\n }\n\n return pending;\n };\n}","export default function mergeByName(modifiers) {\n var merged = modifiers.reduce(function (merged, current) {\n var existing = merged[current.name];\n merged[current.name] = existing ? Object.assign({}, existing, current, {\n options: Object.assign({}, existing.options, current.options),\n data: Object.assign({}, existing.data, current.data)\n }) : current;\n return merged;\n }, {}); // IE11 does not support Object.values\n\n return Object.keys(merged).map(function (key) {\n return merged[key];\n });\n}","import getCompositeRect from \"./dom-utils/getCompositeRect.js\";\nimport getLayoutRect from \"./dom-utils/getLayoutRect.js\";\nimport listScrollParents from \"./dom-utils/listScrollParents.js\";\nimport getOffsetParent from \"./dom-utils/getOffsetParent.js\";\nimport orderModifiers from \"./utils/orderModifiers.js\";\nimport debounce from \"./utils/debounce.js\";\nimport mergeByName from \"./utils/mergeByName.js\";\nimport detectOverflow from \"./utils/detectOverflow.js\";\nimport { isElement } from \"./dom-utils/instanceOf.js\";\nvar DEFAULT_OPTIONS = {\n placement: 'bottom',\n modifiers: [],\n strategy: 'absolute'\n};\n\nfunction areValidElements() {\n for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {\n args[_key] = arguments[_key];\n }\n\n return !args.some(function (element) {\n return !(element && typeof element.getBoundingClientRect === 'function');\n });\n}\n\nexport function popperGenerator(generatorOptions) {\n if (generatorOptions === void 0) {\n generatorOptions = {};\n }\n\n var _generatorOptions = generatorOptions,\n _generatorOptions$def = _generatorOptions.defaultModifiers,\n defaultModifiers = _generatorOptions$def === void 0 ? [] : _generatorOptions$def,\n _generatorOptions$def2 = _generatorOptions.defaultOptions,\n defaultOptions = _generatorOptions$def2 === void 0 ? DEFAULT_OPTIONS : _generatorOptions$def2;\n return function createPopper(reference, popper, options) {\n if (options === void 0) {\n options = defaultOptions;\n }\n\n var state = {\n placement: 'bottom',\n orderedModifiers: [],\n options: Object.assign({}, DEFAULT_OPTIONS, defaultOptions),\n modifiersData: {},\n elements: {\n reference: reference,\n popper: popper\n },\n attributes: {},\n styles: {}\n };\n var effectCleanupFns = [];\n var isDestroyed = false;\n var instance = {\n state: state,\n setOptions: function setOptions(setOptionsAction) {\n var options = typeof setOptionsAction === 'function' ? setOptionsAction(state.options) : setOptionsAction;\n cleanupModifierEffects();\n state.options = Object.assign({}, defaultOptions, state.options, options);\n state.scrollParents = {\n reference: isElement(reference) ? listScrollParents(reference) : reference.contextElement ? listScrollParents(reference.contextElement) : [],\n popper: listScrollParents(popper)\n }; // Orders the modifiers based on their dependencies and `phase`\n // properties\n\n var orderedModifiers = orderModifiers(mergeByName([].concat(defaultModifiers, state.options.modifiers))); // Strip out disabled modifiers\n\n state.orderedModifiers = orderedModifiers.filter(function (m) {\n return m.enabled;\n });\n runModifierEffects();\n return instance.update();\n },\n // Sync update – it will always be executed, even if not necessary. This\n // is useful for low frequency updates where sync behavior simplifies the\n // logic.\n // For high frequency updates (e.g. `resize` and `scroll` events), always\n // prefer the async Popper#update method\n forceUpdate: function forceUpdate() {\n if (isDestroyed) {\n return;\n }\n\n var _state$elements = state.elements,\n reference = _state$elements.reference,\n popper = _state$elements.popper; // Don't proceed if `reference` or `popper` are not valid elements\n // anymore\n\n if (!areValidElements(reference, popper)) {\n return;\n } // Store the reference and popper rects to be read by modifiers\n\n\n state.rects = {\n reference: getCompositeRect(reference, getOffsetParent(popper), state.options.strategy === 'fixed'),\n popper: getLayoutRect(popper)\n }; // Modifiers have the ability to reset the current update cycle. The\n // most common use case for this is the `flip` modifier changing the\n // placement, which then needs to re-run all the modifiers, because the\n // logic was previously ran for the previous placement and is therefore\n // stale/incorrect\n\n state.reset = false;\n state.placement = state.options.placement; // On each update cycle, the `modifiersData` property for each modifier\n // is filled with the initial data specified by the modifier. This means\n // it doesn't persist and is fresh on each update.\n // To ensure persistent data, use `${name}#persistent`\n\n state.orderedModifiers.forEach(function (modifier) {\n return state.modifiersData[modifier.name] = Object.assign({}, modifier.data);\n });\n\n for (var index = 0; index < state.orderedModifiers.length; index++) {\n if (state.reset === true) {\n state.reset = false;\n index = -1;\n continue;\n }\n\n var _state$orderedModifie = state.orderedModifiers[index],\n fn = _state$orderedModifie.fn,\n _state$orderedModifie2 = _state$orderedModifie.options,\n _options = _state$orderedModifie2 === void 0 ? {} : _state$orderedModifie2,\n name = _state$orderedModifie.name;\n\n if (typeof fn === 'function') {\n state = fn({\n state: state,\n options: _options,\n name: name,\n instance: instance\n }) || state;\n }\n }\n },\n // Async and optimistically optimized update – it will not be executed if\n // not necessary (debounced to run at most once-per-tick)\n update: debounce(function () {\n return new Promise(function (resolve) {\n instance.forceUpdate();\n resolve(state);\n });\n }),\n destroy: function destroy() {\n cleanupModifierEffects();\n isDestroyed = true;\n }\n };\n\n if (!areValidElements(reference, popper)) {\n return instance;\n }\n\n instance.setOptions(options).then(function (state) {\n if (!isDestroyed && options.onFirstUpdate) {\n options.onFirstUpdate(state);\n }\n }); // Modifiers have the ability to execute arbitrary code before the first\n // update cycle runs. They will be executed in the same order as the update\n // cycle. This is useful when a modifier adds some persistent data that\n // other modifiers need to use, but the modifier is run after the dependent\n // one.\n\n function runModifierEffects() {\n state.orderedModifiers.forEach(function (_ref) {\n var name = _ref.name,\n _ref$options = _ref.options,\n options = _ref$options === void 0 ? {} : _ref$options,\n effect = _ref.effect;\n\n if (typeof effect === 'function') {\n var cleanupFn = effect({\n state: state,\n name: name,\n instance: instance,\n options: options\n });\n\n var noopFn = function noopFn() {};\n\n effectCleanupFns.push(cleanupFn || noopFn);\n }\n });\n }\n\n function cleanupModifierEffects() {\n effectCleanupFns.forEach(function (fn) {\n return fn();\n });\n effectCleanupFns = [];\n }\n\n return instance;\n };\n}\nexport var createPopper = /*#__PURE__*/popperGenerator(); // eslint-disable-next-line import/no-unused-modules\n\nexport { detectOverflow };","import { popperGenerator, detectOverflow } from \"./createPopper.js\";\nimport eventListeners from \"./modifiers/eventListeners.js\";\nimport popperOffsets from \"./modifiers/popperOffsets.js\";\nimport computeStyles from \"./modifiers/computeStyles.js\";\nimport applyStyles from \"./modifiers/applyStyles.js\";\nimport offset from \"./modifiers/offset.js\";\nimport flip from \"./modifiers/flip.js\";\nimport preventOverflow from \"./modifiers/preventOverflow.js\";\nimport arrow from \"./modifiers/arrow.js\";\nimport hide from \"./modifiers/hide.js\";\nvar defaultModifiers = [eventListeners, popperOffsets, computeStyles, applyStyles, offset, flip, preventOverflow, arrow, hide];\nvar createPopper = /*#__PURE__*/popperGenerator({\n defaultModifiers: defaultModifiers\n}); // eslint-disable-next-line import/no-unused-modules\n\nexport { createPopper, popperGenerator, defaultModifiers, detectOverflow }; // eslint-disable-next-line import/no-unused-modules\n\nexport { createPopper as createPopperLite } from \"./popper-lite.js\"; // eslint-disable-next-line import/no-unused-modules\n\nexport * from \"./modifiers/index.js\";","import { generateUtilityClass } from '../generateUtilityClass';\nimport { generateUtilityClasses } from '../generateUtilityClasses';\nconst COMPONENT_NAME = 'Popper';\nexport function getPopperUtilityClass(slot) {\n return generateUtilityClass(COMPONENT_NAME, slot);\n}\nexport const popperClasses = generateUtilityClasses(COMPONENT_NAME, ['root']);","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"anchorEl\", \"children\", \"direction\", \"disablePortal\", \"modifiers\", \"open\", \"placement\", \"popperOptions\", \"popperRef\", \"slotProps\", \"slots\", \"TransitionProps\", \"ownerState\"],\n _excluded2 = [\"anchorEl\", \"children\", \"container\", \"direction\", \"disablePortal\", \"keepMounted\", \"modifiers\", \"open\", \"placement\", \"popperOptions\", \"popperRef\", \"style\", \"transition\", \"slotProps\", \"slots\"];\nimport * as React from 'react';\nimport { chainPropTypes, HTMLElementType, refType, unstable_ownerDocument as ownerDocument, unstable_useEnhancedEffect as useEnhancedEffect, unstable_useForkRef as useForkRef } from '@mui/utils';\nimport { createPopper } from '@popperjs/core';\nimport PropTypes from 'prop-types';\nimport { unstable_composeClasses as composeClasses } from '../composeClasses';\nimport { Portal } from '../Portal';\nimport { getPopperUtilityClass } from './popperClasses';\nimport { useSlotProps } from '../utils';\nimport { useClassNamesOverride } from '../utils/ClassNameConfigurator';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nfunction flipPlacement(placement, direction) {\n if (direction === 'ltr') {\n return placement;\n }\n switch (placement) {\n case 'bottom-end':\n return 'bottom-start';\n case 'bottom-start':\n return 'bottom-end';\n case 'top-end':\n return 'top-start';\n case 'top-start':\n return 'top-end';\n default:\n return placement;\n }\n}\nfunction resolveAnchorEl(anchorEl) {\n return typeof anchorEl === 'function' ? anchorEl() : anchorEl;\n}\nfunction isHTMLElement(element) {\n return element.nodeType !== undefined;\n}\nfunction isVirtualElement(element) {\n return !isHTMLElement(element);\n}\nconst useUtilityClasses = () => {\n const slots = {\n root: ['root']\n };\n return composeClasses(slots, useClassNamesOverride(getPopperUtilityClass));\n};\nconst defaultPopperOptions = {};\nconst PopperTooltip = /*#__PURE__*/React.forwardRef(function PopperTooltip(props, forwardedRef) {\n var _slots$root;\n const {\n anchorEl,\n children,\n direction,\n disablePortal,\n modifiers,\n open,\n placement: initialPlacement,\n popperOptions,\n popperRef: popperRefProp,\n slotProps = {},\n slots = {},\n TransitionProps\n // @ts-ignore internal logic\n // prevent from spreading to DOM, it can come from the parent component e.g. Select.\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const tooltipRef = React.useRef(null);\n const ownRef = useForkRef(tooltipRef, forwardedRef);\n const popperRef = React.useRef(null);\n const handlePopperRef = useForkRef(popperRef, popperRefProp);\n const handlePopperRefRef = React.useRef(handlePopperRef);\n useEnhancedEffect(() => {\n handlePopperRefRef.current = handlePopperRef;\n }, [handlePopperRef]);\n React.useImperativeHandle(popperRefProp, () => popperRef.current, []);\n const rtlPlacement = flipPlacement(initialPlacement, direction);\n /**\n * placement initialized from prop but can change during lifetime if modifiers.flip.\n * modifiers.flip is essentially a flip for controlled/uncontrolled behavior\n */\n const [placement, setPlacement] = React.useState(rtlPlacement);\n const [resolvedAnchorElement, setResolvedAnchorElement] = React.useState(resolveAnchorEl(anchorEl));\n React.useEffect(() => {\n if (popperRef.current) {\n popperRef.current.forceUpdate();\n }\n });\n React.useEffect(() => {\n if (anchorEl) {\n setResolvedAnchorElement(resolveAnchorEl(anchorEl));\n }\n }, [anchorEl]);\n useEnhancedEffect(() => {\n if (!resolvedAnchorElement || !open) {\n return undefined;\n }\n const handlePopperUpdate = data => {\n setPlacement(data.placement);\n };\n if (process.env.NODE_ENV !== 'production') {\n if (resolvedAnchorElement && isHTMLElement(resolvedAnchorElement) && resolvedAnchorElement.nodeType === 1) {\n const box = resolvedAnchorElement.getBoundingClientRect();\n if (process.env.NODE_ENV !== 'test' && box.top === 0 && box.left === 0 && box.right === 0 && box.bottom === 0) {\n console.warn(['MUI: The `anchorEl` prop provided to the component is invalid.', 'The anchor element should be part of the document layout.', \"Make sure the element is present in the document or that it's not display none.\"].join('\\n'));\n }\n }\n }\n let popperModifiers = [{\n name: 'preventOverflow',\n options: {\n altBoundary: disablePortal\n }\n }, {\n name: 'flip',\n options: {\n altBoundary: disablePortal\n }\n }, {\n name: 'onUpdate',\n enabled: true,\n phase: 'afterWrite',\n fn: ({\n state\n }) => {\n handlePopperUpdate(state);\n }\n }];\n if (modifiers != null) {\n popperModifiers = popperModifiers.concat(modifiers);\n }\n if (popperOptions && popperOptions.modifiers != null) {\n popperModifiers = popperModifiers.concat(popperOptions.modifiers);\n }\n const popper = createPopper(resolvedAnchorElement, tooltipRef.current, _extends({\n placement: rtlPlacement\n }, popperOptions, {\n modifiers: popperModifiers\n }));\n handlePopperRefRef.current(popper);\n return () => {\n popper.destroy();\n handlePopperRefRef.current(null);\n };\n }, [resolvedAnchorElement, disablePortal, modifiers, open, popperOptions, rtlPlacement]);\n const childProps = {\n placement: placement\n };\n if (TransitionProps !== null) {\n childProps.TransitionProps = TransitionProps;\n }\n const classes = useUtilityClasses();\n const Root = (_slots$root = slots.root) != null ? _slots$root : 'div';\n const rootProps = useSlotProps({\n elementType: Root,\n externalSlotProps: slotProps.root,\n externalForwardedProps: other,\n additionalProps: {\n role: 'tooltip',\n ref: ownRef\n },\n ownerState: props,\n className: classes.root\n });\n return /*#__PURE__*/_jsx(Root, _extends({}, rootProps, {\n children: typeof children === 'function' ? children(childProps) : children\n }));\n});\n\n/**\n * Poppers rely on the 3rd party library [Popper.js](https://popper.js.org/docs/v2/) for positioning.\n *\n * Demos:\n *\n * - [Popper](https://mui.com/base-ui/react-popper/)\n *\n * API:\n *\n * - [Popper API](https://mui.com/base-ui/react-popper/components-api/#popper)\n */\nconst Popper = /*#__PURE__*/React.forwardRef(function Popper(props, forwardedRef) {\n const {\n anchorEl,\n children,\n container: containerProp,\n direction = 'ltr',\n disablePortal = false,\n keepMounted = false,\n modifiers,\n open,\n placement = 'bottom',\n popperOptions = defaultPopperOptions,\n popperRef,\n style,\n transition = false,\n slotProps = {},\n slots = {}\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded2);\n const [exited, setExited] = React.useState(true);\n const handleEnter = () => {\n setExited(false);\n };\n const handleExited = () => {\n setExited(true);\n };\n if (!keepMounted && !open && (!transition || exited)) {\n return null;\n }\n\n // If the container prop is provided, use that\n // If the anchorEl prop is provided, use its parent body element as the container\n // If neither are provided let the Modal take care of choosing the container\n let container;\n if (containerProp) {\n container = containerProp;\n } else if (anchorEl) {\n const resolvedAnchorEl = resolveAnchorEl(anchorEl);\n container = resolvedAnchorEl && isHTMLElement(resolvedAnchorEl) ? ownerDocument(resolvedAnchorEl).body : ownerDocument(null).body;\n }\n const display = !open && keepMounted && (!transition || exited) ? 'none' : undefined;\n const transitionProps = transition ? {\n in: open,\n onEnter: handleEnter,\n onExited: handleExited\n } : undefined;\n return /*#__PURE__*/_jsx(Portal, {\n disablePortal: disablePortal,\n container: container,\n children: /*#__PURE__*/_jsx(PopperTooltip, _extends({\n anchorEl: anchorEl,\n direction: direction,\n disablePortal: disablePortal,\n modifiers: modifiers,\n ref: forwardedRef,\n open: transition ? !exited : open,\n placement: placement,\n popperOptions: popperOptions,\n popperRef: popperRef,\n slotProps: slotProps,\n slots: slots\n }, other, {\n style: _extends({\n // Prevents scroll issue, waiting for Popper.js to add this style once initiated.\n position: 'fixed',\n // Fix Popper.js display issue\n top: 0,\n left: 0,\n display\n }, style),\n TransitionProps: transitionProps,\n children: children\n }))\n });\n});\nprocess.env.NODE_ENV !== \"production\" ? Popper.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * An HTML element, [virtualElement](https://popper.js.org/docs/v2/virtual-elements/),\n * or a function that returns either.\n * It's used to set the position of the popper.\n * The return value will passed as the reference object of the Popper instance.\n */\n anchorEl: chainPropTypes(PropTypes.oneOfType([HTMLElementType, PropTypes.object, PropTypes.func]), props => {\n if (props.open) {\n const resolvedAnchorEl = resolveAnchorEl(props.anchorEl);\n if (resolvedAnchorEl && isHTMLElement(resolvedAnchorEl) && resolvedAnchorEl.nodeType === 1) {\n const box = resolvedAnchorEl.getBoundingClientRect();\n if (process.env.NODE_ENV !== 'test' && box.top === 0 && box.left === 0 && box.right === 0 && box.bottom === 0) {\n return new Error(['MUI: The `anchorEl` prop provided to the component is invalid.', 'The anchor element should be part of the document layout.', \"Make sure the element is present in the document or that it's not display none.\"].join('\\n'));\n }\n } else if (!resolvedAnchorEl || typeof resolvedAnchorEl.getBoundingClientRect !== 'function' || isVirtualElement(resolvedAnchorEl) && resolvedAnchorEl.contextElement != null && resolvedAnchorEl.contextElement.nodeType !== 1) {\n return new Error(['MUI: The `anchorEl` prop provided to the component is invalid.', 'It should be an HTML element instance or a virtualElement ', '(https://popper.js.org/docs/v2/virtual-elements/).'].join('\\n'));\n }\n }\n return null;\n }),\n /**\n * Popper render function or node.\n */\n children: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.node, PropTypes.func]),\n /**\n * An HTML element or function that returns one.\n * The `container` will have the portal children appended to it.\n *\n * You can also provide a callback, which is called in a React layout effect.\n * This lets you set the container from a ref, and also makes server-side rendering possible.\n *\n * By default, it uses the body of the top-level document object,\n * so it's simply `document.body` most of the time.\n */\n container: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.func]),\n /**\n * Direction of the text.\n * @default 'ltr'\n */\n direction: PropTypes.oneOf(['ltr', 'rtl']),\n /**\n * The `children` will be under the DOM hierarchy of the parent component.\n * @default false\n */\n disablePortal: PropTypes.bool,\n /**\n * Always keep the children in the DOM.\n * This prop can be useful in SEO situation or\n * when you want to maximize the responsiveness of the Popper.\n * @default false\n */\n keepMounted: PropTypes.bool,\n /**\n * Popper.js is based on a \"plugin-like\" architecture,\n * most of its features are fully encapsulated \"modifiers\".\n *\n * A modifier is a function that is called each time Popper.js needs to\n * compute the position of the popper.\n * For this reason, modifiers should be very performant to avoid bottlenecks.\n * To learn how to create a modifier, [read the modifiers documentation](https://popper.js.org/docs/v2/modifiers/).\n */\n modifiers: PropTypes.arrayOf(PropTypes.shape({\n data: PropTypes.object,\n effect: PropTypes.func,\n enabled: PropTypes.bool,\n fn: PropTypes.func,\n name: PropTypes.any,\n options: PropTypes.object,\n phase: PropTypes.oneOf(['afterMain', 'afterRead', 'afterWrite', 'beforeMain', 'beforeRead', 'beforeWrite', 'main', 'read', 'write']),\n requires: PropTypes.arrayOf(PropTypes.string),\n requiresIfExists: PropTypes.arrayOf(PropTypes.string)\n })),\n /**\n * If `true`, the component is shown.\n */\n open: PropTypes.bool.isRequired,\n /**\n * Popper placement.\n * @default 'bottom'\n */\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n /**\n * Options provided to the [`Popper.js`](https://popper.js.org/docs/v2/constructors/#options) instance.\n * @default {}\n */\n popperOptions: PropTypes.shape({\n modifiers: PropTypes.array,\n onFirstUpdate: PropTypes.func,\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n strategy: PropTypes.oneOf(['absolute', 'fixed'])\n }),\n /**\n * A ref that points to the used popper instance.\n */\n popperRef: refType,\n /**\n * The props used for each slot inside the Popper.\n * @default {}\n */\n slotProps: PropTypes.shape({\n root: PropTypes.oneOfType([PropTypes.func, PropTypes.object])\n }),\n /**\n * The components used for each slot inside the Popper.\n * Either a string to use a HTML element or a component.\n * @default {}\n */\n slots: PropTypes.shape({\n root: PropTypes.elementType\n }),\n /**\n * Help supporting a react-transition-group/Transition component.\n * @default false\n */\n transition: PropTypes.bool\n} : void 0;\nexport { Popper };","'use client';\n\nimport * as React from 'react';\nimport { useTheme as useThemeSystem } from '@mui/system';\nimport defaultTheme from './defaultTheme';\nimport THEME_ID from './identifier';\nexport default function useTheme() {\n const theme = useThemeSystem(defaultTheme);\n if (process.env.NODE_ENV !== 'production') {\n // eslint-disable-next-line react-hooks/rules-of-hooks\n React.useDebugValue(theme);\n }\n return theme[THEME_ID] || theme;\n}","export default function _setPrototypeOf(o, p) {\n _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function _setPrototypeOf(o, p) {\n o.__proto__ = p;\n return o;\n };\n return _setPrototypeOf(o, p);\n}","import setPrototypeOf from \"./setPrototypeOf.js\";\nexport default function _inheritsLoose(subClass, superClass) {\n subClass.prototype = Object.create(superClass.prototype);\n subClass.prototype.constructor = subClass;\n setPrototypeOf(subClass, superClass);\n}","export default {\n disabled: false\n};","import PropTypes from 'prop-types';\nexport var timeoutsShape = process.env.NODE_ENV !== 'production' ? PropTypes.oneOfType([PropTypes.number, PropTypes.shape({\n enter: PropTypes.number,\n exit: PropTypes.number,\n appear: PropTypes.number\n}).isRequired]) : null;\nexport var classNamesShape = process.env.NODE_ENV !== 'production' ? PropTypes.oneOfType([PropTypes.string, PropTypes.shape({\n enter: PropTypes.string,\n exit: PropTypes.string,\n active: PropTypes.string\n}), PropTypes.shape({\n enter: PropTypes.string,\n enterDone: PropTypes.string,\n enterActive: PropTypes.string,\n exit: PropTypes.string,\n exitDone: PropTypes.string,\n exitActive: PropTypes.string\n})]) : null;","import React from 'react';\nexport default React.createContext(null);","export var forceReflow = function forceReflow(node) {\n return node.scrollTop;\n};","import _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _inheritsLoose from \"@babel/runtime/helpers/esm/inheritsLoose\";\nimport PropTypes from 'prop-types';\nimport React from 'react';\nimport ReactDOM from 'react-dom';\nimport config from './config';\nimport { timeoutsShape } from './utils/PropTypes';\nimport TransitionGroupContext from './TransitionGroupContext';\nimport { forceReflow } from './utils/reflow';\nexport var UNMOUNTED = 'unmounted';\nexport var EXITED = 'exited';\nexport var ENTERING = 'entering';\nexport var ENTERED = 'entered';\nexport var EXITING = 'exiting';\n/**\n * The Transition component lets you describe a transition from one component\n * state to another _over time_ with a simple declarative API. Most commonly\n * it's used to animate the mounting and unmounting of a component, but can also\n * be used to describe in-place transition states as well.\n *\n * ---\n *\n * **Note**: `Transition` is a platform-agnostic base component. If you're using\n * transitions in CSS, you'll probably want to use\n * [`CSSTransition`](https://reactcommunity.org/react-transition-group/css-transition)\n * instead. It inherits all the features of `Transition`, but contains\n * additional features necessary to play nice with CSS transitions (hence the\n * name of the component).\n *\n * ---\n *\n * By default the `Transition` component does not alter the behavior of the\n * component it renders, it only tracks \"enter\" and \"exit\" states for the\n * components. It's up to you to give meaning and effect to those states. For\n * example we can add styles to a component when it enters or exits:\n *\n * ```jsx\n * import { Transition } from 'react-transition-group';\n *\n * const duration = 300;\n *\n * const defaultStyle = {\n * transition: `opacity ${duration}ms ease-in-out`,\n * opacity: 0,\n * }\n *\n * const transitionStyles = {\n * entering: { opacity: 1 },\n * entered: { opacity: 1 },\n * exiting: { opacity: 0 },\n * exited: { opacity: 0 },\n * };\n *\n * const Fade = ({ in: inProp }) => (\n * \n * {state => (\n *
    \n * I'm a fade Transition!\n *
    \n * )}\n *
    \n * );\n * ```\n *\n * There are 4 main states a Transition can be in:\n * - `'entering'`\n * - `'entered'`\n * - `'exiting'`\n * - `'exited'`\n *\n * Transition state is toggled via the `in` prop. When `true` the component\n * begins the \"Enter\" stage. During this stage, the component will shift from\n * its current transition state, to `'entering'` for the duration of the\n * transition and then to the `'entered'` stage once it's complete. Let's take\n * the following example (we'll use the\n * [useState](https://reactjs.org/docs/hooks-reference.html#usestate) hook):\n *\n * ```jsx\n * function App() {\n * const [inProp, setInProp] = useState(false);\n * return (\n *
    \n * \n * {state => (\n * // ...\n * )}\n * \n * \n *
    \n * );\n * }\n * ```\n *\n * When the button is clicked the component will shift to the `'entering'` state\n * and stay there for 500ms (the value of `timeout`) before it finally switches\n * to `'entered'`.\n *\n * When `in` is `false` the same thing happens except the state moves from\n * `'exiting'` to `'exited'`.\n */\n\nvar Transition = /*#__PURE__*/function (_React$Component) {\n _inheritsLoose(Transition, _React$Component);\n\n function Transition(props, context) {\n var _this;\n\n _this = _React$Component.call(this, props, context) || this;\n var parentGroup = context; // In the context of a TransitionGroup all enters are really appears\n\n var appear = parentGroup && !parentGroup.isMounting ? props.enter : props.appear;\n var initialStatus;\n _this.appearStatus = null;\n\n if (props.in) {\n if (appear) {\n initialStatus = EXITED;\n _this.appearStatus = ENTERING;\n } else {\n initialStatus = ENTERED;\n }\n } else {\n if (props.unmountOnExit || props.mountOnEnter) {\n initialStatus = UNMOUNTED;\n } else {\n initialStatus = EXITED;\n }\n }\n\n _this.state = {\n status: initialStatus\n };\n _this.nextCallback = null;\n return _this;\n }\n\n Transition.getDerivedStateFromProps = function getDerivedStateFromProps(_ref, prevState) {\n var nextIn = _ref.in;\n\n if (nextIn && prevState.status === UNMOUNTED) {\n return {\n status: EXITED\n };\n }\n\n return null;\n } // getSnapshotBeforeUpdate(prevProps) {\n // let nextStatus = null\n // if (prevProps !== this.props) {\n // const { status } = this.state\n // if (this.props.in) {\n // if (status !== ENTERING && status !== ENTERED) {\n // nextStatus = ENTERING\n // }\n // } else {\n // if (status === ENTERING || status === ENTERED) {\n // nextStatus = EXITING\n // }\n // }\n // }\n // return { nextStatus }\n // }\n ;\n\n var _proto = Transition.prototype;\n\n _proto.componentDidMount = function componentDidMount() {\n this.updateStatus(true, this.appearStatus);\n };\n\n _proto.componentDidUpdate = function componentDidUpdate(prevProps) {\n var nextStatus = null;\n\n if (prevProps !== this.props) {\n var status = this.state.status;\n\n if (this.props.in) {\n if (status !== ENTERING && status !== ENTERED) {\n nextStatus = ENTERING;\n }\n } else {\n if (status === ENTERING || status === ENTERED) {\n nextStatus = EXITING;\n }\n }\n }\n\n this.updateStatus(false, nextStatus);\n };\n\n _proto.componentWillUnmount = function componentWillUnmount() {\n this.cancelNextCallback();\n };\n\n _proto.getTimeouts = function getTimeouts() {\n var timeout = this.props.timeout;\n var exit, enter, appear;\n exit = enter = appear = timeout;\n\n if (timeout != null && typeof timeout !== 'number') {\n exit = timeout.exit;\n enter = timeout.enter; // TODO: remove fallback for next major\n\n appear = timeout.appear !== undefined ? timeout.appear : enter;\n }\n\n return {\n exit: exit,\n enter: enter,\n appear: appear\n };\n };\n\n _proto.updateStatus = function updateStatus(mounting, nextStatus) {\n if (mounting === void 0) {\n mounting = false;\n }\n\n if (nextStatus !== null) {\n // nextStatus will always be ENTERING or EXITING.\n this.cancelNextCallback();\n\n if (nextStatus === ENTERING) {\n if (this.props.unmountOnExit || this.props.mountOnEnter) {\n var node = this.props.nodeRef ? this.props.nodeRef.current : ReactDOM.findDOMNode(this); // https://github.com/reactjs/react-transition-group/pull/749\n // With unmountOnExit or mountOnEnter, the enter animation should happen at the transition between `exited` and `entering`.\n // To make the animation happen, we have to separate each rendering and avoid being processed as batched.\n\n if (node) forceReflow(node);\n }\n\n this.performEnter(mounting);\n } else {\n this.performExit();\n }\n } else if (this.props.unmountOnExit && this.state.status === EXITED) {\n this.setState({\n status: UNMOUNTED\n });\n }\n };\n\n _proto.performEnter = function performEnter(mounting) {\n var _this2 = this;\n\n var enter = this.props.enter;\n var appearing = this.context ? this.context.isMounting : mounting;\n\n var _ref2 = this.props.nodeRef ? [appearing] : [ReactDOM.findDOMNode(this), appearing],\n maybeNode = _ref2[0],\n maybeAppearing = _ref2[1];\n\n var timeouts = this.getTimeouts();\n var enterTimeout = appearing ? timeouts.appear : timeouts.enter; // no enter animation skip right to ENTERED\n // if we are mounting and running this it means appear _must_ be set\n\n if (!mounting && !enter || config.disabled) {\n this.safeSetState({\n status: ENTERED\n }, function () {\n _this2.props.onEntered(maybeNode);\n });\n return;\n }\n\n this.props.onEnter(maybeNode, maybeAppearing);\n this.safeSetState({\n status: ENTERING\n }, function () {\n _this2.props.onEntering(maybeNode, maybeAppearing);\n\n _this2.onTransitionEnd(enterTimeout, function () {\n _this2.safeSetState({\n status: ENTERED\n }, function () {\n _this2.props.onEntered(maybeNode, maybeAppearing);\n });\n });\n });\n };\n\n _proto.performExit = function performExit() {\n var _this3 = this;\n\n var exit = this.props.exit;\n var timeouts = this.getTimeouts();\n var maybeNode = this.props.nodeRef ? undefined : ReactDOM.findDOMNode(this); // no exit animation skip right to EXITED\n\n if (!exit || config.disabled) {\n this.safeSetState({\n status: EXITED\n }, function () {\n _this3.props.onExited(maybeNode);\n });\n return;\n }\n\n this.props.onExit(maybeNode);\n this.safeSetState({\n status: EXITING\n }, function () {\n _this3.props.onExiting(maybeNode);\n\n _this3.onTransitionEnd(timeouts.exit, function () {\n _this3.safeSetState({\n status: EXITED\n }, function () {\n _this3.props.onExited(maybeNode);\n });\n });\n });\n };\n\n _proto.cancelNextCallback = function cancelNextCallback() {\n if (this.nextCallback !== null) {\n this.nextCallback.cancel();\n this.nextCallback = null;\n }\n };\n\n _proto.safeSetState = function safeSetState(nextState, callback) {\n // This shouldn't be necessary, but there are weird race conditions with\n // setState callbacks and unmounting in testing, so always make sure that\n // we can cancel any pending setState callbacks after we unmount.\n callback = this.setNextCallback(callback);\n this.setState(nextState, callback);\n };\n\n _proto.setNextCallback = function setNextCallback(callback) {\n var _this4 = this;\n\n var active = true;\n\n this.nextCallback = function (event) {\n if (active) {\n active = false;\n _this4.nextCallback = null;\n callback(event);\n }\n };\n\n this.nextCallback.cancel = function () {\n active = false;\n };\n\n return this.nextCallback;\n };\n\n _proto.onTransitionEnd = function onTransitionEnd(timeout, handler) {\n this.setNextCallback(handler);\n var node = this.props.nodeRef ? this.props.nodeRef.current : ReactDOM.findDOMNode(this);\n var doesNotHaveTimeoutOrListener = timeout == null && !this.props.addEndListener;\n\n if (!node || doesNotHaveTimeoutOrListener) {\n setTimeout(this.nextCallback, 0);\n return;\n }\n\n if (this.props.addEndListener) {\n var _ref3 = this.props.nodeRef ? [this.nextCallback] : [node, this.nextCallback],\n maybeNode = _ref3[0],\n maybeNextCallback = _ref3[1];\n\n this.props.addEndListener(maybeNode, maybeNextCallback);\n }\n\n if (timeout != null) {\n setTimeout(this.nextCallback, timeout);\n }\n };\n\n _proto.render = function render() {\n var status = this.state.status;\n\n if (status === UNMOUNTED) {\n return null;\n }\n\n var _this$props = this.props,\n children = _this$props.children,\n _in = _this$props.in,\n _mountOnEnter = _this$props.mountOnEnter,\n _unmountOnExit = _this$props.unmountOnExit,\n _appear = _this$props.appear,\n _enter = _this$props.enter,\n _exit = _this$props.exit,\n _timeout = _this$props.timeout,\n _addEndListener = _this$props.addEndListener,\n _onEnter = _this$props.onEnter,\n _onEntering = _this$props.onEntering,\n _onEntered = _this$props.onEntered,\n _onExit = _this$props.onExit,\n _onExiting = _this$props.onExiting,\n _onExited = _this$props.onExited,\n _nodeRef = _this$props.nodeRef,\n childProps = _objectWithoutPropertiesLoose(_this$props, [\"children\", \"in\", \"mountOnEnter\", \"unmountOnExit\", \"appear\", \"enter\", \"exit\", \"timeout\", \"addEndListener\", \"onEnter\", \"onEntering\", \"onEntered\", \"onExit\", \"onExiting\", \"onExited\", \"nodeRef\"]);\n\n return (\n /*#__PURE__*/\n // allows for nested Transitions\n React.createElement(TransitionGroupContext.Provider, {\n value: null\n }, typeof children === 'function' ? children(status, childProps) : React.cloneElement(React.Children.only(children), childProps))\n );\n };\n\n return Transition;\n}(React.Component);\n\nTransition.contextType = TransitionGroupContext;\nTransition.propTypes = process.env.NODE_ENV !== \"production\" ? {\n /**\n * A React reference to DOM element that need to transition:\n * https://stackoverflow.com/a/51127130/4671932\n *\n * - When `nodeRef` prop is used, `node` is not passed to callback functions\n * (e.g. `onEnter`) because user already has direct access to the node.\n * - When changing `key` prop of `Transition` in a `TransitionGroup` a new\n * `nodeRef` need to be provided to `Transition` with changed `key` prop\n * (see\n * [test/CSSTransition-test.js](https://github.com/reactjs/react-transition-group/blob/13435f897b3ab71f6e19d724f145596f5910581c/test/CSSTransition-test.js#L362-L437)).\n */\n nodeRef: PropTypes.shape({\n current: typeof Element === 'undefined' ? PropTypes.any : function (propValue, key, componentName, location, propFullName, secret) {\n var value = propValue[key];\n return PropTypes.instanceOf(value && 'ownerDocument' in value ? value.ownerDocument.defaultView.Element : Element)(propValue, key, componentName, location, propFullName, secret);\n }\n }),\n\n /**\n * A `function` child can be used instead of a React element. This function is\n * called with the current transition status (`'entering'`, `'entered'`,\n * `'exiting'`, `'exited'`), which can be used to apply context\n * specific props to a component.\n *\n * ```jsx\n * \n * {state => (\n * \n * )}\n * \n * ```\n */\n children: PropTypes.oneOfType([PropTypes.func.isRequired, PropTypes.element.isRequired]).isRequired,\n\n /**\n * Show the component; triggers the enter or exit states\n */\n in: PropTypes.bool,\n\n /**\n * By default the child component is mounted immediately along with\n * the parent `Transition` component. If you want to \"lazy mount\" the component on the\n * first `in={true}` you can set `mountOnEnter`. After the first enter transition the component will stay\n * mounted, even on \"exited\", unless you also specify `unmountOnExit`.\n */\n mountOnEnter: PropTypes.bool,\n\n /**\n * By default the child component stays mounted after it reaches the `'exited'` state.\n * Set `unmountOnExit` if you'd prefer to unmount the component after it finishes exiting.\n */\n unmountOnExit: PropTypes.bool,\n\n /**\n * By default the child component does not perform the enter transition when\n * it first mounts, regardless of the value of `in`. If you want this\n * behavior, set both `appear` and `in` to `true`.\n *\n * > **Note**: there are no special appear states like `appearing`/`appeared`, this prop\n * > only adds an additional enter transition. However, in the\n * > `` component that first enter transition does result in\n * > additional `.appear-*` classes, that way you can choose to style it\n * > differently.\n */\n appear: PropTypes.bool,\n\n /**\n * Enable or disable enter transitions.\n */\n enter: PropTypes.bool,\n\n /**\n * Enable or disable exit transitions.\n */\n exit: PropTypes.bool,\n\n /**\n * The duration of the transition, in milliseconds.\n * Required unless `addEndListener` is provided.\n *\n * You may specify a single timeout for all transitions:\n *\n * ```jsx\n * timeout={500}\n * ```\n *\n * or individually:\n *\n * ```jsx\n * timeout={{\n * appear: 500,\n * enter: 300,\n * exit: 500,\n * }}\n * ```\n *\n * - `appear` defaults to the value of `enter`\n * - `enter` defaults to `0`\n * - `exit` defaults to `0`\n *\n * @type {number | { enter?: number, exit?: number, appear?: number }}\n */\n timeout: function timeout(props) {\n var pt = timeoutsShape;\n if (!props.addEndListener) pt = pt.isRequired;\n\n for (var _len = arguments.length, args = new Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) {\n args[_key - 1] = arguments[_key];\n }\n\n return pt.apply(void 0, [props].concat(args));\n },\n\n /**\n * Add a custom transition end trigger. Called with the transitioning\n * DOM node and a `done` callback. Allows for more fine grained transition end\n * logic. Timeouts are still used as a fallback if provided.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * ```jsx\n * addEndListener={(node, done) => {\n * // use the css transitionend event to mark the finish of a transition\n * node.addEventListener('transitionend', done, false);\n * }}\n * ```\n */\n addEndListener: PropTypes.func,\n\n /**\n * Callback fired before the \"entering\" status is applied. An extra parameter\n * `isAppearing` is supplied to indicate if the enter stage is occurring on the initial mount\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement, isAppearing: bool) -> void\n */\n onEnter: PropTypes.func,\n\n /**\n * Callback fired after the \"entering\" status is applied. An extra parameter\n * `isAppearing` is supplied to indicate if the enter stage is occurring on the initial mount\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement, isAppearing: bool)\n */\n onEntering: PropTypes.func,\n\n /**\n * Callback fired after the \"entered\" status is applied. An extra parameter\n * `isAppearing` is supplied to indicate if the enter stage is occurring on the initial mount\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement, isAppearing: bool) -> void\n */\n onEntered: PropTypes.func,\n\n /**\n * Callback fired before the \"exiting\" status is applied.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement) -> void\n */\n onExit: PropTypes.func,\n\n /**\n * Callback fired after the \"exiting\" status is applied.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement) -> void\n */\n onExiting: PropTypes.func,\n\n /**\n * Callback fired after the \"exited\" status is applied.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed\n *\n * @type Function(node: HtmlElement) -> void\n */\n onExited: PropTypes.func\n} : {}; // Name the function so it is clearer in the documentation\n\nfunction noop() {}\n\nTransition.defaultProps = {\n in: false,\n mountOnEnter: false,\n unmountOnExit: false,\n appear: false,\n enter: true,\n exit: true,\n onEnter: noop,\n onEntering: noop,\n onEntered: noop,\n onExit: noop,\n onExiting: noop,\n onExited: noop\n};\nTransition.UNMOUNTED = UNMOUNTED;\nTransition.EXITED = EXITED;\nTransition.ENTERING = ENTERING;\nTransition.ENTERED = ENTERED;\nTransition.EXITING = EXITING;\nexport default Transition;","export const reflow = node => node.scrollTop;\nexport function getTransitionProps(props, options) {\n var _style$transitionDura, _style$transitionTimi;\n const {\n timeout,\n easing,\n style = {}\n } = props;\n return {\n duration: (_style$transitionDura = style.transitionDuration) != null ? _style$transitionDura : typeof timeout === 'number' ? timeout : timeout[options.mode] || 0,\n easing: (_style$transitionTimi = style.transitionTimingFunction) != null ? _style$transitionTimi : typeof easing === 'object' ? easing[options.mode] : easing,\n delay: style.transitionDelay\n };\n}","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"addEndListener\", \"appear\", \"children\", \"easing\", \"in\", \"onEnter\", \"onEntered\", \"onEntering\", \"onExit\", \"onExited\", \"onExiting\", \"style\", \"timeout\", \"TransitionComponent\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport { elementAcceptingRef, unstable_useTimeout as useTimeout } from '@mui/utils';\nimport { Transition } from 'react-transition-group';\nimport useTheme from '../styles/useTheme';\nimport { getTransitionProps, reflow } from '../transitions/utils';\nimport useForkRef from '../utils/useForkRef';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nfunction getScale(value) {\n return `scale(${value}, ${value ** 2})`;\n}\nconst styles = {\n entering: {\n opacity: 1,\n transform: getScale(1)\n },\n entered: {\n opacity: 1,\n transform: 'none'\n }\n};\n\n/*\n TODO v6: remove\n Conditionally apply a workaround for the CSS transition bug in Safari 15.4 / WebKit browsers.\n */\nconst isWebKit154 = typeof navigator !== 'undefined' && /^((?!chrome|android).)*(safari|mobile)/i.test(navigator.userAgent) && /(os |version\\/)15(.|_)4/i.test(navigator.userAgent);\n\n/**\n * The Grow transition is used by the [Tooltip](/material-ui/react-tooltip/) and\n * [Popover](/material-ui/react-popover/) components.\n * It uses [react-transition-group](https://github.com/reactjs/react-transition-group) internally.\n */\nconst Grow = /*#__PURE__*/React.forwardRef(function Grow(props, ref) {\n const {\n addEndListener,\n appear = true,\n children,\n easing,\n in: inProp,\n onEnter,\n onEntered,\n onEntering,\n onExit,\n onExited,\n onExiting,\n style,\n timeout = 'auto',\n // eslint-disable-next-line react/prop-types\n TransitionComponent = Transition\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const timer = useTimeout();\n const autoTimeout = React.useRef();\n const theme = useTheme();\n const nodeRef = React.useRef(null);\n const handleRef = useForkRef(nodeRef, children.ref, ref);\n const normalizedTransitionCallback = callback => maybeIsAppearing => {\n if (callback) {\n const node = nodeRef.current;\n\n // onEnterXxx and onExitXxx callbacks have a different arguments.length value.\n if (maybeIsAppearing === undefined) {\n callback(node);\n } else {\n callback(node, maybeIsAppearing);\n }\n }\n };\n const handleEntering = normalizedTransitionCallback(onEntering);\n const handleEnter = normalizedTransitionCallback((node, isAppearing) => {\n reflow(node); // So the animation always start from the start.\n\n const {\n duration: transitionDuration,\n delay,\n easing: transitionTimingFunction\n } = getTransitionProps({\n style,\n timeout,\n easing\n }, {\n mode: 'enter'\n });\n let duration;\n if (timeout === 'auto') {\n duration = theme.transitions.getAutoHeightDuration(node.clientHeight);\n autoTimeout.current = duration;\n } else {\n duration = transitionDuration;\n }\n node.style.transition = [theme.transitions.create('opacity', {\n duration,\n delay\n }), theme.transitions.create('transform', {\n duration: isWebKit154 ? duration : duration * 0.666,\n delay,\n easing: transitionTimingFunction\n })].join(',');\n if (onEnter) {\n onEnter(node, isAppearing);\n }\n });\n const handleEntered = normalizedTransitionCallback(onEntered);\n const handleExiting = normalizedTransitionCallback(onExiting);\n const handleExit = normalizedTransitionCallback(node => {\n const {\n duration: transitionDuration,\n delay,\n easing: transitionTimingFunction\n } = getTransitionProps({\n style,\n timeout,\n easing\n }, {\n mode: 'exit'\n });\n let duration;\n if (timeout === 'auto') {\n duration = theme.transitions.getAutoHeightDuration(node.clientHeight);\n autoTimeout.current = duration;\n } else {\n duration = transitionDuration;\n }\n node.style.transition = [theme.transitions.create('opacity', {\n duration,\n delay\n }), theme.transitions.create('transform', {\n duration: isWebKit154 ? duration : duration * 0.666,\n delay: isWebKit154 ? delay : delay || duration * 0.333,\n easing: transitionTimingFunction\n })].join(',');\n node.style.opacity = 0;\n node.style.transform = getScale(0.75);\n if (onExit) {\n onExit(node);\n }\n });\n const handleExited = normalizedTransitionCallback(onExited);\n const handleAddEndListener = next => {\n if (timeout === 'auto') {\n timer.start(autoTimeout.current || 0, next);\n }\n if (addEndListener) {\n // Old call signature before `react-transition-group` implemented `nodeRef`\n addEndListener(nodeRef.current, next);\n }\n };\n return /*#__PURE__*/_jsx(TransitionComponent, _extends({\n appear: appear,\n in: inProp,\n nodeRef: nodeRef,\n onEnter: handleEnter,\n onEntered: handleEntered,\n onEntering: handleEntering,\n onExit: handleExit,\n onExited: handleExited,\n onExiting: handleExiting,\n addEndListener: handleAddEndListener,\n timeout: timeout === 'auto' ? null : timeout\n }, other, {\n children: (state, childProps) => {\n return /*#__PURE__*/React.cloneElement(children, _extends({\n style: _extends({\n opacity: 0,\n transform: getScale(0.75),\n visibility: state === 'exited' && !inProp ? 'hidden' : undefined\n }, styles[state], style, children.props.style),\n ref: handleRef\n }, childProps));\n }\n }));\n});\nprocess.env.NODE_ENV !== \"production\" ? Grow.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the d.ts file and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * Add a custom transition end trigger. Called with the transitioning DOM\n * node and a done callback. Allows for more fine grained transition end\n * logic. Note: Timeouts are still used as a fallback if provided.\n */\n addEndListener: PropTypes.func,\n /**\n * Perform the enter transition when it first mounts if `in` is also `true`.\n * Set this to `false` to disable this behavior.\n * @default true\n */\n appear: PropTypes.bool,\n /**\n * A single child content element.\n */\n children: elementAcceptingRef.isRequired,\n /**\n * The transition timing function.\n * You may specify a single easing or a object containing enter and exit values.\n */\n easing: PropTypes.oneOfType([PropTypes.shape({\n enter: PropTypes.string,\n exit: PropTypes.string\n }), PropTypes.string]),\n /**\n * If `true`, the component will transition in.\n */\n in: PropTypes.bool,\n /**\n * @ignore\n */\n onEnter: PropTypes.func,\n /**\n * @ignore\n */\n onEntered: PropTypes.func,\n /**\n * @ignore\n */\n onEntering: PropTypes.func,\n /**\n * @ignore\n */\n onExit: PropTypes.func,\n /**\n * @ignore\n */\n onExited: PropTypes.func,\n /**\n * @ignore\n */\n onExiting: PropTypes.func,\n /**\n * @ignore\n */\n style: PropTypes.object,\n /**\n * The duration for the transition, in milliseconds.\n * You may specify a single timeout for all transitions, or individually with an object.\n *\n * Set to 'auto' to automatically calculate transition time based on height.\n * @default 'auto'\n */\n timeout: PropTypes.oneOfType([PropTypes.oneOf(['auto']), PropTypes.number, PropTypes.shape({\n appear: PropTypes.number,\n enter: PropTypes.number,\n exit: PropTypes.number\n })])\n} : void 0;\nGrow.muiSupportAuto = true;\nexport default Grow;","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"anchorEl\", \"component\", \"components\", \"componentsProps\", \"container\", \"disablePortal\", \"keepMounted\", \"modifiers\", \"open\", \"placement\", \"popperOptions\", \"popperRef\", \"transition\", \"slots\", \"slotProps\"];\nimport { Popper as BasePopper } from '@mui/base/Popper';\nimport { useThemeWithoutDefault as useTheme } from '@mui/system';\nimport { HTMLElementType, refType } from '@mui/utils';\nimport PropTypes from 'prop-types';\nimport * as React from 'react';\nimport { styled, useThemeProps } from '../styles';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nconst PopperRoot = styled(BasePopper, {\n name: 'MuiPopper',\n slot: 'Root',\n overridesResolver: (props, styles) => styles.root\n})({});\n\n/**\n *\n * Demos:\n *\n * - [Autocomplete](https://mui.com/material-ui/react-autocomplete/)\n * - [Menu](https://mui.com/material-ui/react-menu/)\n * - [Popper](https://mui.com/material-ui/react-popper/)\n *\n * API:\n *\n * - [Popper API](https://mui.com/material-ui/api/popper/)\n */\nconst Popper = /*#__PURE__*/React.forwardRef(function Popper(inProps, ref) {\n var _slots$root;\n const theme = useTheme();\n const props = useThemeProps({\n props: inProps,\n name: 'MuiPopper'\n });\n const {\n anchorEl,\n component,\n components,\n componentsProps,\n container,\n disablePortal,\n keepMounted,\n modifiers,\n open,\n placement,\n popperOptions,\n popperRef,\n transition,\n slots,\n slotProps\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const RootComponent = (_slots$root = slots == null ? void 0 : slots.root) != null ? _slots$root : components == null ? void 0 : components.Root;\n const otherProps = _extends({\n anchorEl,\n container,\n disablePortal,\n keepMounted,\n modifiers,\n open,\n placement,\n popperOptions,\n popperRef,\n transition\n }, other);\n return /*#__PURE__*/_jsx(PopperRoot, _extends({\n as: component,\n direction: theme == null ? void 0 : theme.direction,\n slots: {\n root: RootComponent\n },\n slotProps: slotProps != null ? slotProps : componentsProps\n }, otherProps, {\n ref: ref\n }));\n});\nprocess.env.NODE_ENV !== \"production\" ? Popper.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * An HTML element, [virtualElement](https://popper.js.org/docs/v2/virtual-elements/),\n * or a function that returns either.\n * It's used to set the position of the popper.\n * The return value will passed as the reference object of the Popper instance.\n */\n anchorEl: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.object, PropTypes.func]),\n /**\n * Popper render function or node.\n */\n children: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.node, PropTypes.func]),\n /**\n * The component used for the root node.\n * Either a string to use a HTML element or a component.\n */\n component: PropTypes.elementType,\n /**\n * The components used for each slot inside the Popper.\n * Either a string to use a HTML element or a component.\n * @default {}\n */\n components: PropTypes.shape({\n Root: PropTypes.elementType\n }),\n /**\n * The props used for each slot inside the Popper.\n * @default {}\n */\n componentsProps: PropTypes.shape({\n root: PropTypes.oneOfType([PropTypes.func, PropTypes.object])\n }),\n /**\n * An HTML element or function that returns one.\n * The `container` will have the portal children appended to it.\n *\n * You can also provide a callback, which is called in a React layout effect.\n * This lets you set the container from a ref, and also makes server-side rendering possible.\n *\n * By default, it uses the body of the top-level document object,\n * so it's simply `document.body` most of the time.\n */\n container: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.func]),\n /**\n * The `children` will be under the DOM hierarchy of the parent component.\n * @default false\n */\n disablePortal: PropTypes.bool,\n /**\n * Always keep the children in the DOM.\n * This prop can be useful in SEO situation or\n * when you want to maximize the responsiveness of the Popper.\n * @default false\n */\n keepMounted: PropTypes.bool,\n /**\n * Popper.js is based on a \"plugin-like\" architecture,\n * most of its features are fully encapsulated \"modifiers\".\n *\n * A modifier is a function that is called each time Popper.js needs to\n * compute the position of the popper.\n * For this reason, modifiers should be very performant to avoid bottlenecks.\n * To learn how to create a modifier, [read the modifiers documentation](https://popper.js.org/docs/v2/modifiers/).\n */\n modifiers: PropTypes.arrayOf(PropTypes.shape({\n data: PropTypes.object,\n effect: PropTypes.func,\n enabled: PropTypes.bool,\n fn: PropTypes.func,\n name: PropTypes.any,\n options: PropTypes.object,\n phase: PropTypes.oneOf(['afterMain', 'afterRead', 'afterWrite', 'beforeMain', 'beforeRead', 'beforeWrite', 'main', 'read', 'write']),\n requires: PropTypes.arrayOf(PropTypes.string),\n requiresIfExists: PropTypes.arrayOf(PropTypes.string)\n })),\n /**\n * If `true`, the component is shown.\n */\n open: PropTypes.bool.isRequired,\n /**\n * Popper placement.\n * @default 'bottom'\n */\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n /**\n * Options provided to the [`Popper.js`](https://popper.js.org/docs/v2/constructors/#options) instance.\n * @default {}\n */\n popperOptions: PropTypes.shape({\n modifiers: PropTypes.array,\n onFirstUpdate: PropTypes.func,\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n strategy: PropTypes.oneOf(['absolute', 'fixed'])\n }),\n /**\n * A ref that points to the used popper instance.\n */\n popperRef: refType,\n /**\n * The props used for each slot inside the Popper.\n * @default {}\n */\n slotProps: PropTypes.shape({\n root: PropTypes.oneOfType([PropTypes.func, PropTypes.object])\n }),\n /**\n * The components used for each slot inside the Popper.\n * Either a string to use a HTML element or a component.\n * @default {}\n */\n slots: PropTypes.shape({\n root: PropTypes.elementType\n }),\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Help supporting a react-transition-group/Transition component.\n * @default false\n */\n transition: PropTypes.bool\n} : void 0;\nexport default Popper;","import generateUtilityClasses from '@mui/utils/generateUtilityClasses';\nimport generateUtilityClass from '@mui/utils/generateUtilityClass';\nexport function getTooltipUtilityClass(slot) {\n return generateUtilityClass('MuiTooltip', slot);\n}\nconst tooltipClasses = generateUtilityClasses('MuiTooltip', ['popper', 'popperInteractive', 'popperArrow', 'popperClose', 'tooltip', 'tooltipArrow', 'touch', 'tooltipPlacementLeft', 'tooltipPlacementRight', 'tooltipPlacementTop', 'tooltipPlacementBottom', 'arrow']);\nexport default tooltipClasses;","'use client';\n\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nconst _excluded = [\"arrow\", \"children\", \"classes\", \"components\", \"componentsProps\", \"describeChild\", \"disableFocusListener\", \"disableHoverListener\", \"disableInteractive\", \"disableTouchListener\", \"enterDelay\", \"enterNextDelay\", \"enterTouchDelay\", \"followCursor\", \"id\", \"leaveDelay\", \"leaveTouchDelay\", \"onClose\", \"onOpen\", \"open\", \"placement\", \"PopperComponent\", \"PopperProps\", \"slotProps\", \"slots\", \"title\", \"TransitionComponent\", \"TransitionProps\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport clsx from 'clsx';\nimport { elementAcceptingRef, unstable_useTimeout as useTimeout, unstable_Timeout as Timeout } from '@mui/utils';\nimport { unstable_composeClasses as composeClasses, appendOwnerState } from '@mui/base';\nimport { alpha } from '@mui/system';\nimport styled from '../styles/styled';\nimport useTheme from '../styles/useTheme';\nimport useThemeProps from '../styles/useThemeProps';\nimport capitalize from '../utils/capitalize';\nimport Grow from '../Grow';\nimport Popper from '../Popper';\nimport useEventCallback from '../utils/useEventCallback';\nimport useForkRef from '../utils/useForkRef';\nimport useId from '../utils/useId';\nimport useIsFocusVisible from '../utils/useIsFocusVisible';\nimport useControlled from '../utils/useControlled';\nimport tooltipClasses, { getTooltipUtilityClass } from './tooltipClasses';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nimport { jsxs as _jsxs } from \"react/jsx-runtime\";\nfunction round(value) {\n return Math.round(value * 1e5) / 1e5;\n}\nconst useUtilityClasses = ownerState => {\n const {\n classes,\n disableInteractive,\n arrow,\n touch,\n placement\n } = ownerState;\n const slots = {\n popper: ['popper', !disableInteractive && 'popperInteractive', arrow && 'popperArrow'],\n tooltip: ['tooltip', arrow && 'tooltipArrow', touch && 'touch', `tooltipPlacement${capitalize(placement.split('-')[0])}`],\n arrow: ['arrow']\n };\n return composeClasses(slots, getTooltipUtilityClass, classes);\n};\nconst TooltipPopper = styled(Popper, {\n name: 'MuiTooltip',\n slot: 'Popper',\n overridesResolver: (props, styles) => {\n const {\n ownerState\n } = props;\n return [styles.popper, !ownerState.disableInteractive && styles.popperInteractive, ownerState.arrow && styles.popperArrow, !ownerState.open && styles.popperClose];\n }\n})(({\n theme,\n ownerState,\n open\n}) => _extends({\n zIndex: (theme.vars || theme).zIndex.tooltip,\n pointerEvents: 'none'\n}, !ownerState.disableInteractive && {\n pointerEvents: 'auto'\n}, !open && {\n pointerEvents: 'none'\n}, ownerState.arrow && {\n [`&[data-popper-placement*=\"bottom\"] .${tooltipClasses.arrow}`]: {\n top: 0,\n marginTop: '-0.71em',\n '&::before': {\n transformOrigin: '0 100%'\n }\n },\n [`&[data-popper-placement*=\"top\"] .${tooltipClasses.arrow}`]: {\n bottom: 0,\n marginBottom: '-0.71em',\n '&::before': {\n transformOrigin: '100% 0'\n }\n },\n [`&[data-popper-placement*=\"right\"] .${tooltipClasses.arrow}`]: _extends({}, !ownerState.isRtl ? {\n left: 0,\n marginLeft: '-0.71em'\n } : {\n right: 0,\n marginRight: '-0.71em'\n }, {\n height: '1em',\n width: '0.71em',\n '&::before': {\n transformOrigin: '100% 100%'\n }\n }),\n [`&[data-popper-placement*=\"left\"] .${tooltipClasses.arrow}`]: _extends({}, !ownerState.isRtl ? {\n right: 0,\n marginRight: '-0.71em'\n } : {\n left: 0,\n marginLeft: '-0.71em'\n }, {\n height: '1em',\n width: '0.71em',\n '&::before': {\n transformOrigin: '0 0'\n }\n })\n}));\nconst TooltipTooltip = styled('div', {\n name: 'MuiTooltip',\n slot: 'Tooltip',\n overridesResolver: (props, styles) => {\n const {\n ownerState\n } = props;\n return [styles.tooltip, ownerState.touch && styles.touch, ownerState.arrow && styles.tooltipArrow, styles[`tooltipPlacement${capitalize(ownerState.placement.split('-')[0])}`]];\n }\n})(({\n theme,\n ownerState\n}) => _extends({\n backgroundColor: theme.vars ? theme.vars.palette.Tooltip.bg : alpha(theme.palette.grey[700], 0.92),\n borderRadius: (theme.vars || theme).shape.borderRadius,\n color: (theme.vars || theme).palette.common.white,\n fontFamily: theme.typography.fontFamily,\n padding: '4px 8px',\n fontSize: theme.typography.pxToRem(11),\n maxWidth: 300,\n margin: 2,\n wordWrap: 'break-word',\n fontWeight: theme.typography.fontWeightMedium\n}, ownerState.arrow && {\n position: 'relative',\n margin: 0\n}, ownerState.touch && {\n padding: '8px 16px',\n fontSize: theme.typography.pxToRem(14),\n lineHeight: `${round(16 / 14)}em`,\n fontWeight: theme.typography.fontWeightRegular\n}, {\n [`.${tooltipClasses.popper}[data-popper-placement*=\"left\"] &`]: _extends({\n transformOrigin: 'right center'\n }, !ownerState.isRtl ? _extends({\n marginRight: '14px'\n }, ownerState.touch && {\n marginRight: '24px'\n }) : _extends({\n marginLeft: '14px'\n }, ownerState.touch && {\n marginLeft: '24px'\n })),\n [`.${tooltipClasses.popper}[data-popper-placement*=\"right\"] &`]: _extends({\n transformOrigin: 'left center'\n }, !ownerState.isRtl ? _extends({\n marginLeft: '14px'\n }, ownerState.touch && {\n marginLeft: '24px'\n }) : _extends({\n marginRight: '14px'\n }, ownerState.touch && {\n marginRight: '24px'\n })),\n [`.${tooltipClasses.popper}[data-popper-placement*=\"top\"] &`]: _extends({\n transformOrigin: 'center bottom',\n marginBottom: '14px'\n }, ownerState.touch && {\n marginBottom: '24px'\n }),\n [`.${tooltipClasses.popper}[data-popper-placement*=\"bottom\"] &`]: _extends({\n transformOrigin: 'center top',\n marginTop: '14px'\n }, ownerState.touch && {\n marginTop: '24px'\n })\n}));\nconst TooltipArrow = styled('span', {\n name: 'MuiTooltip',\n slot: 'Arrow',\n overridesResolver: (props, styles) => styles.arrow\n})(({\n theme\n}) => ({\n overflow: 'hidden',\n position: 'absolute',\n width: '1em',\n height: '0.71em' /* = width / sqrt(2) = (length of the hypotenuse) */,\n boxSizing: 'border-box',\n color: theme.vars ? theme.vars.palette.Tooltip.bg : alpha(theme.palette.grey[700], 0.9),\n '&::before': {\n content: '\"\"',\n margin: 'auto',\n display: 'block',\n width: '100%',\n height: '100%',\n backgroundColor: 'currentColor',\n transform: 'rotate(45deg)'\n }\n}));\nlet hystersisOpen = false;\nconst hystersisTimer = new Timeout();\nlet cursorPosition = {\n x: 0,\n y: 0\n};\nexport function testReset() {\n hystersisOpen = false;\n hystersisTimer.clear();\n}\nfunction composeEventHandler(handler, eventHandler) {\n return event => {\n if (eventHandler) {\n eventHandler(event);\n }\n handler(event);\n };\n}\n\n// TODO v6: Remove PopperComponent, PopperProps, TransitionComponent and TransitionProps.\nconst Tooltip = /*#__PURE__*/React.forwardRef(function Tooltip(inProps, ref) {\n var _ref, _slots$popper, _ref2, _ref3, _slots$transition, _ref4, _slots$tooltip, _ref5, _slots$arrow, _slotProps$popper, _ref6, _slotProps$popper2, _slotProps$transition, _slotProps$tooltip, _ref7, _slotProps$tooltip2, _slotProps$arrow, _ref8, _slotProps$arrow2;\n const props = useThemeProps({\n props: inProps,\n name: 'MuiTooltip'\n });\n const {\n arrow = false,\n children: childrenProp,\n components = {},\n componentsProps = {},\n describeChild = false,\n disableFocusListener = false,\n disableHoverListener = false,\n disableInteractive: disableInteractiveProp = false,\n disableTouchListener = false,\n enterDelay = 100,\n enterNextDelay = 0,\n enterTouchDelay = 700,\n followCursor = false,\n id: idProp,\n leaveDelay = 0,\n leaveTouchDelay = 1500,\n onClose,\n onOpen,\n open: openProp,\n placement = 'bottom',\n PopperComponent: PopperComponentProp,\n PopperProps = {},\n slotProps = {},\n slots = {},\n title,\n TransitionComponent: TransitionComponentProp = Grow,\n TransitionProps\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n\n // to prevent runtime errors, developers will need to provide a child as a React element anyway.\n const children = /*#__PURE__*/React.isValidElement(childrenProp) ? childrenProp : /*#__PURE__*/_jsx(\"span\", {\n children: childrenProp\n });\n const theme = useTheme();\n const isRtl = theme.direction === 'rtl';\n const [childNode, setChildNode] = React.useState();\n const [arrowRef, setArrowRef] = React.useState(null);\n const ignoreNonTouchEvents = React.useRef(false);\n const disableInteractive = disableInteractiveProp || followCursor;\n const closeTimer = useTimeout();\n const enterTimer = useTimeout();\n const leaveTimer = useTimeout();\n const touchTimer = useTimeout();\n const [openState, setOpenState] = useControlled({\n controlled: openProp,\n default: false,\n name: 'Tooltip',\n state: 'open'\n });\n let open = openState;\n if (process.env.NODE_ENV !== 'production') {\n // eslint-disable-next-line react-hooks/rules-of-hooks\n const {\n current: isControlled\n } = React.useRef(openProp !== undefined);\n\n // eslint-disable-next-line react-hooks/rules-of-hooks\n React.useEffect(() => {\n if (childNode && childNode.disabled && !isControlled && title !== '' && childNode.tagName.toLowerCase() === 'button') {\n console.error(['MUI: You are providing a disabled `button` child to the Tooltip component.', 'A disabled element does not fire events.', \"Tooltip needs to listen to the child element's events to display the title.\", '', 'Add a simple wrapper element, such as a `span`.'].join('\\n'));\n }\n }, [title, childNode, isControlled]);\n }\n const id = useId(idProp);\n const prevUserSelect = React.useRef();\n const stopTouchInteraction = useEventCallback(() => {\n if (prevUserSelect.current !== undefined) {\n document.body.style.WebkitUserSelect = prevUserSelect.current;\n prevUserSelect.current = undefined;\n }\n touchTimer.clear();\n });\n React.useEffect(() => stopTouchInteraction, [stopTouchInteraction]);\n const handleOpen = event => {\n hystersisTimer.clear();\n hystersisOpen = true;\n\n // The mouseover event will trigger for every nested element in the tooltip.\n // We can skip rerendering when the tooltip is already open.\n // We are using the mouseover event instead of the mouseenter event to fix a hide/show issue.\n setOpenState(true);\n if (onOpen && !open) {\n onOpen(event);\n }\n };\n const handleClose = useEventCallback(\n /**\n * @param {React.SyntheticEvent | Event} event\n */\n event => {\n hystersisTimer.start(800 + leaveDelay, () => {\n hystersisOpen = false;\n });\n setOpenState(false);\n if (onClose && open) {\n onClose(event);\n }\n closeTimer.start(theme.transitions.duration.shortest, () => {\n ignoreNonTouchEvents.current = false;\n });\n });\n const handleEnter = event => {\n if (ignoreNonTouchEvents.current && event.type !== 'touchstart') {\n return;\n }\n\n // Remove the title ahead of time.\n // We don't want to wait for the next render commit.\n // We would risk displaying two tooltips at the same time (native + this one).\n if (childNode) {\n childNode.removeAttribute('title');\n }\n enterTimer.clear();\n leaveTimer.clear();\n if (enterDelay || hystersisOpen && enterNextDelay) {\n enterTimer.start(hystersisOpen ? enterNextDelay : enterDelay, () => {\n handleOpen(event);\n });\n } else {\n handleOpen(event);\n }\n };\n const handleLeave = event => {\n enterTimer.clear();\n leaveTimer.start(leaveDelay, () => {\n handleClose(event);\n });\n };\n const {\n isFocusVisibleRef,\n onBlur: handleBlurVisible,\n onFocus: handleFocusVisible,\n ref: focusVisibleRef\n } = useIsFocusVisible();\n // We don't necessarily care about the focusVisible state (which is safe to access via ref anyway).\n // We just need to re-render the Tooltip if the focus-visible state changes.\n const [, setChildIsFocusVisible] = React.useState(false);\n const handleBlur = event => {\n handleBlurVisible(event);\n if (isFocusVisibleRef.current === false) {\n setChildIsFocusVisible(false);\n handleLeave(event);\n }\n };\n const handleFocus = event => {\n // Workaround for https://github.com/facebook/react/issues/7769\n // The autoFocus of React might trigger the event before the componentDidMount.\n // We need to account for this eventuality.\n if (!childNode) {\n setChildNode(event.currentTarget);\n }\n handleFocusVisible(event);\n if (isFocusVisibleRef.current === true) {\n setChildIsFocusVisible(true);\n handleEnter(event);\n }\n };\n const detectTouchStart = event => {\n ignoreNonTouchEvents.current = true;\n const childrenProps = children.props;\n if (childrenProps.onTouchStart) {\n childrenProps.onTouchStart(event);\n }\n };\n const handleMouseOver = handleEnter;\n const handleMouseLeave = handleLeave;\n const handleTouchStart = event => {\n detectTouchStart(event);\n leaveTimer.clear();\n closeTimer.clear();\n stopTouchInteraction();\n prevUserSelect.current = document.body.style.WebkitUserSelect;\n // Prevent iOS text selection on long-tap.\n document.body.style.WebkitUserSelect = 'none';\n touchTimer.start(enterTouchDelay, () => {\n document.body.style.WebkitUserSelect = prevUserSelect.current;\n handleEnter(event);\n });\n };\n const handleTouchEnd = event => {\n if (children.props.onTouchEnd) {\n children.props.onTouchEnd(event);\n }\n stopTouchInteraction();\n leaveTimer.start(leaveTouchDelay, () => {\n handleClose(event);\n });\n };\n React.useEffect(() => {\n if (!open) {\n return undefined;\n }\n\n /**\n * @param {KeyboardEvent} nativeEvent\n */\n function handleKeyDown(nativeEvent) {\n // IE11, Edge (prior to using Bink?) use 'Esc'\n if (nativeEvent.key === 'Escape' || nativeEvent.key === 'Esc') {\n handleClose(nativeEvent);\n }\n }\n document.addEventListener('keydown', handleKeyDown);\n return () => {\n document.removeEventListener('keydown', handleKeyDown);\n };\n }, [handleClose, open]);\n const handleRef = useForkRef(children.ref, focusVisibleRef, setChildNode, ref);\n\n // There is no point in displaying an empty tooltip.\n // So we exclude all falsy values, except 0, which is valid.\n if (!title && title !== 0) {\n open = false;\n }\n const popperRef = React.useRef();\n const handleMouseMove = event => {\n const childrenProps = children.props;\n if (childrenProps.onMouseMove) {\n childrenProps.onMouseMove(event);\n }\n cursorPosition = {\n x: event.clientX,\n y: event.clientY\n };\n if (popperRef.current) {\n popperRef.current.update();\n }\n };\n const nameOrDescProps = {};\n const titleIsString = typeof title === 'string';\n if (describeChild) {\n nameOrDescProps.title = !open && titleIsString && !disableHoverListener ? title : null;\n nameOrDescProps['aria-describedby'] = open ? id : null;\n } else {\n nameOrDescProps['aria-label'] = titleIsString ? title : null;\n nameOrDescProps['aria-labelledby'] = open && !titleIsString ? id : null;\n }\n const childrenProps = _extends({}, nameOrDescProps, other, children.props, {\n className: clsx(other.className, children.props.className),\n onTouchStart: detectTouchStart,\n ref: handleRef\n }, followCursor ? {\n onMouseMove: handleMouseMove\n } : {});\n if (process.env.NODE_ENV !== 'production') {\n childrenProps['data-mui-internal-clone-element'] = true;\n\n // eslint-disable-next-line react-hooks/rules-of-hooks\n React.useEffect(() => {\n if (childNode && !childNode.getAttribute('data-mui-internal-clone-element')) {\n console.error(['MUI: The `children` component of the Tooltip is not forwarding its props correctly.', 'Please make sure that props are spread on the same element that the ref is applied to.'].join('\\n'));\n }\n }, [childNode]);\n }\n const interactiveWrapperListeners = {};\n if (!disableTouchListener) {\n childrenProps.onTouchStart = handleTouchStart;\n childrenProps.onTouchEnd = handleTouchEnd;\n }\n if (!disableHoverListener) {\n childrenProps.onMouseOver = composeEventHandler(handleMouseOver, childrenProps.onMouseOver);\n childrenProps.onMouseLeave = composeEventHandler(handleMouseLeave, childrenProps.onMouseLeave);\n if (!disableInteractive) {\n interactiveWrapperListeners.onMouseOver = handleMouseOver;\n interactiveWrapperListeners.onMouseLeave = handleMouseLeave;\n }\n }\n if (!disableFocusListener) {\n childrenProps.onFocus = composeEventHandler(handleFocus, childrenProps.onFocus);\n childrenProps.onBlur = composeEventHandler(handleBlur, childrenProps.onBlur);\n if (!disableInteractive) {\n interactiveWrapperListeners.onFocus = handleFocus;\n interactiveWrapperListeners.onBlur = handleBlur;\n }\n }\n if (process.env.NODE_ENV !== 'production') {\n if (children.props.title) {\n console.error(['MUI: You have provided a `title` prop to the child of .', `Remove this title prop \\`${children.props.title}\\` or the Tooltip component.`].join('\\n'));\n }\n }\n const popperOptions = React.useMemo(() => {\n var _PopperProps$popperOp;\n let tooltipModifiers = [{\n name: 'arrow',\n enabled: Boolean(arrowRef),\n options: {\n element: arrowRef,\n padding: 4\n }\n }];\n if ((_PopperProps$popperOp = PopperProps.popperOptions) != null && _PopperProps$popperOp.modifiers) {\n tooltipModifiers = tooltipModifiers.concat(PopperProps.popperOptions.modifiers);\n }\n return _extends({}, PopperProps.popperOptions, {\n modifiers: tooltipModifiers\n });\n }, [arrowRef, PopperProps]);\n const ownerState = _extends({}, props, {\n isRtl,\n arrow,\n disableInteractive,\n placement,\n PopperComponentProp,\n touch: ignoreNonTouchEvents.current\n });\n const classes = useUtilityClasses(ownerState);\n const PopperComponent = (_ref = (_slots$popper = slots.popper) != null ? _slots$popper : components.Popper) != null ? _ref : TooltipPopper;\n const TransitionComponent = (_ref2 = (_ref3 = (_slots$transition = slots.transition) != null ? _slots$transition : components.Transition) != null ? _ref3 : TransitionComponentProp) != null ? _ref2 : Grow;\n const TooltipComponent = (_ref4 = (_slots$tooltip = slots.tooltip) != null ? _slots$tooltip : components.Tooltip) != null ? _ref4 : TooltipTooltip;\n const ArrowComponent = (_ref5 = (_slots$arrow = slots.arrow) != null ? _slots$arrow : components.Arrow) != null ? _ref5 : TooltipArrow;\n const popperProps = appendOwnerState(PopperComponent, _extends({}, PopperProps, (_slotProps$popper = slotProps.popper) != null ? _slotProps$popper : componentsProps.popper, {\n className: clsx(classes.popper, PopperProps == null ? void 0 : PopperProps.className, (_ref6 = (_slotProps$popper2 = slotProps.popper) != null ? _slotProps$popper2 : componentsProps.popper) == null ? void 0 : _ref6.className)\n }), ownerState);\n const transitionProps = appendOwnerState(TransitionComponent, _extends({}, TransitionProps, (_slotProps$transition = slotProps.transition) != null ? _slotProps$transition : componentsProps.transition), ownerState);\n const tooltipProps = appendOwnerState(TooltipComponent, _extends({}, (_slotProps$tooltip = slotProps.tooltip) != null ? _slotProps$tooltip : componentsProps.tooltip, {\n className: clsx(classes.tooltip, (_ref7 = (_slotProps$tooltip2 = slotProps.tooltip) != null ? _slotProps$tooltip2 : componentsProps.tooltip) == null ? void 0 : _ref7.className)\n }), ownerState);\n const tooltipArrowProps = appendOwnerState(ArrowComponent, _extends({}, (_slotProps$arrow = slotProps.arrow) != null ? _slotProps$arrow : componentsProps.arrow, {\n className: clsx(classes.arrow, (_ref8 = (_slotProps$arrow2 = slotProps.arrow) != null ? _slotProps$arrow2 : componentsProps.arrow) == null ? void 0 : _ref8.className)\n }), ownerState);\n return /*#__PURE__*/_jsxs(React.Fragment, {\n children: [/*#__PURE__*/React.cloneElement(children, childrenProps), /*#__PURE__*/_jsx(PopperComponent, _extends({\n as: PopperComponentProp != null ? PopperComponentProp : Popper,\n placement: placement,\n anchorEl: followCursor ? {\n getBoundingClientRect: () => ({\n top: cursorPosition.y,\n left: cursorPosition.x,\n right: cursorPosition.x,\n bottom: cursorPosition.y,\n width: 0,\n height: 0\n })\n } : childNode,\n popperRef: popperRef,\n open: childNode ? open : false,\n id: id,\n transition: true\n }, interactiveWrapperListeners, popperProps, {\n popperOptions: popperOptions,\n children: ({\n TransitionProps: TransitionPropsInner\n }) => /*#__PURE__*/_jsx(TransitionComponent, _extends({\n timeout: theme.transitions.duration.shorter\n }, TransitionPropsInner, transitionProps, {\n children: /*#__PURE__*/_jsxs(TooltipComponent, _extends({}, tooltipProps, {\n children: [title, arrow ? /*#__PURE__*/_jsx(ArrowComponent, _extends({}, tooltipArrowProps, {\n ref: setArrowRef\n })) : null]\n }))\n }))\n }))]\n });\n});\nprocess.env.NODE_ENV !== \"production\" ? Tooltip.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the d.ts file and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * If `true`, adds an arrow to the tooltip.\n * @default false\n */\n arrow: PropTypes.bool,\n /**\n * Tooltip reference element.\n */\n children: elementAcceptingRef.isRequired,\n /**\n * Override or extend the styles applied to the component.\n */\n classes: PropTypes.object,\n /**\n * @ignore\n */\n className: PropTypes.string,\n /**\n * The components used for each slot inside.\n *\n * This prop is an alias for the `slots` prop.\n * It's recommended to use the `slots` prop instead.\n *\n * @default {}\n */\n components: PropTypes.shape({\n Arrow: PropTypes.elementType,\n Popper: PropTypes.elementType,\n Tooltip: PropTypes.elementType,\n Transition: PropTypes.elementType\n }),\n /**\n * The extra props for the slot components.\n * You can override the existing props or add new ones.\n *\n * This prop is an alias for the `slotProps` prop.\n * It's recommended to use the `slotProps` prop instead, as `componentsProps` will be deprecated in the future.\n *\n * @default {}\n */\n componentsProps: PropTypes.shape({\n arrow: PropTypes.object,\n popper: PropTypes.object,\n tooltip: PropTypes.object,\n transition: PropTypes.object\n }),\n /**\n * Set to `true` if the `title` acts as an accessible description.\n * By default the `title` acts as an accessible label for the child.\n * @default false\n */\n describeChild: PropTypes.bool,\n /**\n * Do not respond to focus-visible events.\n * @default false\n */\n disableFocusListener: PropTypes.bool,\n /**\n * Do not respond to hover events.\n * @default false\n */\n disableHoverListener: PropTypes.bool,\n /**\n * Makes a tooltip not interactive, i.e. it will close when the user\n * hovers over the tooltip before the `leaveDelay` is expired.\n * @default false\n */\n disableInteractive: PropTypes.bool,\n /**\n * Do not respond to long press touch events.\n * @default false\n */\n disableTouchListener: PropTypes.bool,\n /**\n * The number of milliseconds to wait before showing the tooltip.\n * This prop won't impact the enter touch delay (`enterTouchDelay`).\n * @default 100\n */\n enterDelay: PropTypes.number,\n /**\n * The number of milliseconds to wait before showing the tooltip when one was already recently opened.\n * @default 0\n */\n enterNextDelay: PropTypes.number,\n /**\n * The number of milliseconds a user must touch the element before showing the tooltip.\n * @default 700\n */\n enterTouchDelay: PropTypes.number,\n /**\n * If `true`, the tooltip follow the cursor over the wrapped element.\n * @default false\n */\n followCursor: PropTypes.bool,\n /**\n * This prop is used to help implement the accessibility logic.\n * If you don't provide this prop. It falls back to a randomly generated id.\n */\n id: PropTypes.string,\n /**\n * The number of milliseconds to wait before hiding the tooltip.\n * This prop won't impact the leave touch delay (`leaveTouchDelay`).\n * @default 0\n */\n leaveDelay: PropTypes.number,\n /**\n * The number of milliseconds after the user stops touching an element before hiding the tooltip.\n * @default 1500\n */\n leaveTouchDelay: PropTypes.number,\n /**\n * Callback fired when the component requests to be closed.\n *\n * @param {React.SyntheticEvent} event The event source of the callback.\n */\n onClose: PropTypes.func,\n /**\n * Callback fired when the component requests to be open.\n *\n * @param {React.SyntheticEvent} event The event source of the callback.\n */\n onOpen: PropTypes.func,\n /**\n * If `true`, the component is shown.\n */\n open: PropTypes.bool,\n /**\n * Tooltip placement.\n * @default 'bottom'\n */\n placement: PropTypes.oneOf(['bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n /**\n * The component used for the popper.\n * @default Popper\n */\n PopperComponent: PropTypes.elementType,\n /**\n * Props applied to the [`Popper`](/material-ui/api/popper/) element.\n * @default {}\n */\n PopperProps: PropTypes.object,\n /**\n * The extra props for the slot components.\n * You can override the existing props or add new ones.\n *\n * This prop is an alias for the `componentsProps` prop, which will be deprecated in the future.\n *\n * @default {}\n */\n slotProps: PropTypes.shape({\n arrow: PropTypes.object,\n popper: PropTypes.object,\n tooltip: PropTypes.object,\n transition: PropTypes.object\n }),\n /**\n * The components used for each slot inside.\n *\n * This prop is an alias for the `components` prop, which will be deprecated in the future.\n *\n * @default {}\n */\n slots: PropTypes.shape({\n arrow: PropTypes.elementType,\n popper: PropTypes.elementType,\n tooltip: PropTypes.elementType,\n transition: PropTypes.elementType\n }),\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Tooltip title. Zero-length titles string, undefined, null and false are never displayed.\n */\n title: PropTypes.node,\n /**\n * The component used for the transition.\n * [Follow this guide](/material-ui/transitions/#transitioncomponent-prop) to learn more about the requirements for this component.\n * @default Grow\n */\n TransitionComponent: PropTypes.elementType,\n /**\n * Props applied to the transition element.\n * By default, the element is based on this [`Transition`](http://reactcommunity.org/react-transition-group/transition/) component.\n */\n TransitionProps: PropTypes.object\n} : void 0;\nexport default Tooltip;","import '@/components/mui/menu-item.component.css';\nimport ArrowRightIcon from '@mui/icons-material/ArrowRight';\nimport {\n ListItemIcon as MuiListItemIcon,\n ListItemText as MuiListItemText,\n MenuItem as MuiMenuItem,\n} from '@mui/material';\nimport Tooltip from '@mui/material/Tooltip';\nimport { Localized, ReferencedItem, SingleColumnMenu } from 'platform-bible-utils';\nimport { MouseEvent, PropsWithChildren } from 'react';\n\ntype MenuItemInfoBase = {\n /** Text (displayable in the UI) as the name of the menu item */\n label: string;\n /** Text to display when the mouse hovers over the menu item */\n tooltip?: string;\n};\n\nexport type Command = MenuItemInfoBase & {\n /** Command to execute (string.string) */\n command: string;\n};\n\ntype SubMenu = MenuItemInfoBase & {\n /** Command to execute (string.string) */\n items: MenuItemInfo[];\n};\n\nexport interface CommandHandler {\n (command: Command): void;\n}\n\nexport type MenuPropsBase = {\n /*\n * The JSON defining the menu whose items are to be rendered. This will typically be one of the\n * menus in the \"defs\" in a Platform.Bible menu (see PlatformMenus). The schema for this is\n * menuDocumentSchema (at the end of menus.model.ts). Note that while this is a\n * \"SingleColumnMenu\", somewhat bizarrely, a MultiColumnMenu is a SingleColumnMenu, so it really\n * could be a MultiColumnMenu, in which case, column had better be defined so it can be used\n * to filter out the actual groups and items to display on the column.\n */\n menuDefinition: Localized;\n\n commandHandler: CommandHandler;\n\n /**\n * Additional action to perform when any menu item is clicked. Allows the caller to handle event\n * (e.g., to close the menu).\n */\n onClick?: (event: MouseEvent) => void;\n};\n\nexport type MenuItemListProps = MenuPropsBase & {\n /** Optional unique (column) identifier */\n columnId?: ReferencedItem;\n};\n\nexport type MenuItemProps = Omit &\n PropsWithChildren<{\n /** Optional unique identifier */\n id?: string;\n\n onClick: (event: MouseEvent) => void;\n }>;\n\ntype MenuItemInfo = (Command | SubMenu) & {\n /**\n * If specified, menu item will be inset if it does not have a leading icon.\n *\n * @default true\n */\n allowForLeadingIcons?: boolean;\n /**\n * If specified, the path to the icon image to display on the leading side of the menu text.\n *\n * @default undefined (no leading icon will be shown)\n */\n iconPathBefore?: string;\n /**\n * If specified, the path to the icon image to display on the trailing side of the menu text.\n *\n * @default undefined (no trailing icon will be shown)\n */\n iconPathAfter?: string;\n /**\n * If true, list item is focused during the first mount\n *\n * @default false\n */\n hasAutoFocus?: boolean;\n\n /** Additional css classes to help with unique styling of the menu item */\n className?: string;\n\n /**\n * If true, the menu item will appear disabled and it will not respond to clicks or mouse hovers.\n *\n * @default false\n */\n isDisabled?: boolean;\n\n /**\n * If true, compact vertical padding designed for keyboard and mouse input is used.\n *\n * @default true\n */\n isDense?: boolean;\n\n /**\n * If true, a right-arrow icon will be displayed (iconPathAfter, if specified, will be ignored).\n *\n * @default false\n */\n isSubMenuParent?: boolean;\n\n /**\n * If true, the left and right padding is removed\n *\n * @default false\n */\n hasDisabledGutters?: boolean;\n\n /**\n * If true, a 1px light border is added to bottom of menu item\n *\n * @default false\n */\n hasDivider?: boolean;\n\n /** Help identify which element has keyboard focus */\n focusVisibleClassName?: string;\n\n /** If it's a submenu, it should have the items property */\n items?: MenuItemInfo[];\n};\n\nfunction getIcon(icon: string | undefined, menuLabel: string, leading: boolean) {\n return icon ? (\n \n {`${leading\n \n ) : undefined;\n}\n\nexport default function MenuItem(props: MenuItemProps) {\n const {\n onClick,\n label,\n tooltip,\n allowForLeadingIcons = true,\n iconPathBefore = undefined,\n iconPathAfter = undefined,\n hasAutoFocus = false,\n className,\n isDisabled = false,\n isDense = true,\n isSubMenuParent = false,\n hasDisabledGutters = false,\n hasDivider = false,\n focusVisibleClassName,\n id,\n children,\n } = props;\n\n const menuItem = (\n \n {label ? (\n <>\n {getIcon(iconPathBefore, label, true)}\n \n {isSubMenuParent ? (\n \n \n \n ) : (\n getIcon(iconPathAfter, label, false)\n )}\n \n ) : (\n children\n )}\n \n );\n\n return tooltip ? (\n \n
    {menuItem}
    \n
    \n ) : (\n menuItem\n );\n}\n","import MenuItem, {\n MenuItemListProps,\n MenuItemProps,\n MenuPropsBase,\n} from '@/components/mui/menu-item.component';\nimport { Menu } from '@mui/material';\nimport {\n Localized,\n MenuGroupDetailsInSubMenu,\n MenuItemContainingCommand,\n MenuItemContainingSubmenu,\n OrderedExtensibleContainer,\n ReferencedItem,\n SingleColumnMenu,\n} from 'platform-bible-utils';\nimport { MouseEvent, useMemo, useState } from 'react';\n\n/**\n * All the exported types in this file should be regarded as \"internal\" (i.e., they should not be\n * exposed via index.ts).\n */\n\nexport type GroupedMenuPropsBase = MenuPropsBase & {\n /** Optional unique (column) identifier */\n columnId?: ReferencedItem;\n};\n\nexport type GroupedMenuItemListProps = MenuItemListProps & {\n /**\n * If the menuDefinition includes \"top-level\" groups (i.e., those that belong to a column as\n * opposed to those that belong to a submenu) that should not be included in the list, then this\n * array specifies which groups to include. Likewise, for a submenu, this list indicates which\n * groups are pertinent for that submenu. So then for a context menu this property need not be\n * specified since it is a top-level menu based on a \"true\" SingleColumnMenu (i.e., one that is\n * not a MultiColumnMenu).\n */\n includedGroups?: {\n id: string;\n group: Localized;\n }[];\n};\n\ninterface ItemInfo {\n item: Localized;\n isLastItemInGroup: boolean;\n}\n\ntype SubMenuProps = MenuPropsBase & {\n parentMenuItem: Localized;\n parentItemProps: Omit, 'iconPathAfter'>;\n};\n\nfunction getAllGroups(menuDefinition: Localized) {\n const groupEntries = Object.entries(menuDefinition.groups);\n // Convert array of entries to array of objects with id and group properties\n return groupEntries.map(([key, value]) => ({ id: key, group: value }));\n}\n\nfunction SubMenu(props: SubMenuProps) {\n const [anchorEl, setAnchorEl] = useState(undefined);\n\n const { parentMenuItem, parentItemProps, menuDefinition } = props;\n\n const handleParentMenuItemClick = (event: MouseEvent) => {\n setAnchorEl(event.currentTarget);\n };\n\n const handleClose = () => {\n setAnchorEl(undefined);\n };\n\n const renderSubMenuItems = () => {\n let includedGroups = getAllGroups(menuDefinition).filter((g) => 'menuItem' in g.group);\n\n // Ensure valid parent menu was provided. (If not, submenu will contain all groups!)\n if (!parentMenuItem?.id) throw new Error('A valid parent menu item is required for submenus.');\n\n // When laying out a submenu, only include groups associated with the provided parent menu.\n // Note: without the (annoying) redundant check that the included groups\n // have the menuItem field, TS doesn't think it exists.\n includedGroups = includedGroups.filter(\n (group) => 'menuItem' in group.group && group.group.menuItem === parentMenuItem.id,\n );\n\n return ;\n };\n\n return (\n <>\n \n \n {renderSubMenuItems()}\n \n \n );\n}\n\nconst getOrderedGroupItems = (\n groupId: string,\n allItems: Localized[],\n) => {\n // Filter items that belong to the specified group\n const itemsForGroup = allItems.filter((item) => item.group === groupId);\n // Sort items based on order\n const sortedItems = itemsForGroup.sort((a, b) => (a.order || 0) - (b.order || 0));\n return sortedItems;\n};\n\n/**\n * This component is internal; it does not need to be exposed to the outside world since it is not\n * useful on its own. It is used to generate and lay out the MenuItems that appear either on a\n * top-level menu (in a GridMenu or ContextMenu) or in a submenu.\n */\nexport default function GroupedMenuItemList(menuProps: GroupedMenuItemListProps) {\n const { menuDefinition, onClick, commandHandler, includedGroups } = menuProps;\n\n const { items, allowForLeadingIcons } = useMemo(() => {\n const groupsToInclude =\n includedGroups && includedGroups.length > 0\n ? includedGroups\n : // We're apparently laying out a single-column menu (presumably a context menu). In this\n // case, all groups should be included except ones that belong to a submenu.\n getAllGroups(menuDefinition).filter((g) => !('menuItem' in g.group));\n\n const sortedGroups = Object.values(groupsToInclude).sort(\n (a, b) => (a.group.order || 0) - (b.group.order || 0),\n );\n\n const itemArray: ItemInfo[] = [];\n\n sortedGroups.forEach((group) => {\n getOrderedGroupItems(group.id, menuDefinition.items).forEach((item) =>\n itemArray.push({ item, isLastItemInGroup: false }),\n );\n if (itemArray.length > 0) itemArray[itemArray.length - 1].isLastItemInGroup = true;\n });\n\n // No divider after last item in final group.\n if (itemArray.length > 0) itemArray[itemArray.length - 1].isLastItemInGroup = false;\n\n const allowSpaceForLeadingIcons = itemArray.some(\n (i) => 'iconPathBefore' in i.item && i.item.iconPathBefore,\n );\n\n return { items: itemArray, allowForLeadingIcons: allowSpaceForLeadingIcons };\n }, [includedGroups, menuDefinition]);\n\n // Create props for MenuItem component including setting hasDivider for the last item in a group\n const createMenuItemProps = ({ item, isLastItemInGroup }: ItemInfo) => {\n const menuItemProps = {\n className: 'papi-menu-item',\n label: item.label,\n tooltip: item.tooltip,\n iconPathBefore: 'iconPathBefore' in item ? item.iconPathBefore : undefined,\n iconPathAfter: 'iconPathAfter' in item ? item.iconPathAfter : undefined,\n hasDivider: isLastItemInGroup, // Set hasDivider to true for the last item in a group\n allowForLeadingIcons,\n };\n\n return menuItemProps;\n };\n\n const [firstItem] = items;\n\n if (!firstItem) return
    ;\n\n const divKey = firstItem.item.group;\n\n return (\n
    \n {items.map((itemInfo, index) => {\n const { item } = itemInfo;\n const menuItemProps = createMenuItemProps(itemInfo);\n if ('command' in item) {\n const key = item.group + index;\n return (\n ) => {\n onClick?.(event);\n commandHandler(item);\n }}\n {...menuItemProps}\n />\n );\n }\n return (\n \n );\n })}\n
    \n );\n}\n","import GroupedMenuItemList from '@/components/mui/grouped-menu-item-list.component';\nimport { MenuItemListProps } from '@/components/mui/menu-item.component';\nimport { MultiColumnMenu } from 'platform-bible-utils';\n\n/**\n * This component is internal; it does not need to be exposed to the outside world since it is not\n * useful on its own. Use either GridMenu or ContextMenu.\n */\nexport default function TopLevelMenu(props: MenuItemListProps) {\n const { menuDefinition, columnId } = props;\n\n const groupEntries = Object.entries(menuDefinition.groups);\n // Convert array of entries to array of objects with id and group properties\n const groups = groupEntries.map(([key, value]) => ({ id: key, group: value }));\n let includedGroups = groups.filter((g) => 'column' in g.group);\n\n // Check if column is provided and menuDefinition is a MultiColumnMenu\n if (\n columnId &&\n 'columns' in menuDefinition &&\n // Without this type assertion, TS doesn't know what columns is.\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n (menuDefinition as MultiColumnMenu).columns[columnId]\n ) {\n // When laying out a single column in a MultiColumnMenu, only include groups associated with\n // the provided column. Note: without the (annoying) redundant check that the included groups\n // have the colum field, TS doesn't think it exists.\n includedGroups = includedGroups.filter(\n (g) => 'column' in g.group && g.group.column === columnId,\n );\n }\n\n return ;\n}\n","import '@/components/mui/grid-menu.component.css';\nimport { GroupedMenuPropsBase } from '@/components/mui/grouped-menu-item-list.component';\nimport { CommandHandler } from '@/components/mui/menu-item.component';\nimport TopLevelMenu from '@/components/mui/top-level-menu.component';\nimport { Grid, List } from '@mui/material';\nimport {\n Localized,\n MenuColumnWithHeader,\n MultiColumnMenu,\n ReferencedItem,\n} from 'platform-bible-utils';\nimport { useMemo } from 'react';\n\ntype ColumnInfo = {\n /*\n * The ID (`${string}.${string}`) of a specific menu column.\n */\n id: ReferencedItem;\n\n /*\n * Metadata (label, order, etc.) for a specific menu column.\n */\n metadata: Localized;\n};\n\ntype MenuColumnProps = ColumnInfo &\n GroupedMenuPropsBase & {\n /** Additional css classes to help with unique styling of the menu column */\n className?: string;\n };\n\nexport type GridMenuInfo = {\n /** The menu object containing information about the columns, groups, and items to display. */\n multiColumnMenu: Localized;\n};\n\nexport type GridMenuProps = GridMenuInfo & {\n /** Optional unique identifier */\n id?: string;\n\n commandHandler: CommandHandler;\n\n /** Additional css classes to help with unique styling of the grid menu */\n className?: string;\n};\n\nfunction MenuColumn({\n commandHandler,\n menuDefinition,\n id,\n metadata,\n onClick,\n className,\n}: MenuColumnProps) {\n return (\n \n

    \n {metadata.label}\n

    \n {/* It would seem as though this List component were unnecessary, since it only contains one\n thing, but the \"dense\" property does affect the layout of the items (in a way I don't fully\n understand). There might be a better way. */}\n \n \n \n \n );\n}\n\nexport default function GridMenu({\n commandHandler,\n className,\n multiColumnMenu,\n id,\n}: GridMenuProps) {\n const { columns } = multiColumnMenu;\n\n const sortedColumns = useMemo(() => {\n const columnNumbers = new Map();\n Object.getOwnPropertyNames(columns).forEach((columnName: string) => {\n // We know for sure there is a (boolean) property 'isExtensible' that we are not interested in.\n if (columnName === 'isExtensible') return;\n // TS doesn't allow `columnName` above to be a ReferencedItem even though the type says it is\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const columnId = columnName as ReferencedItem;\n const column = columns[columnId];\n // As of right now (and hopefully forever after), all remaining properties of the\n // ColumnsWithHeaders object are columns whose property names are the IDs of the columns.\n // This is an additional (redundant) sanity check. Specifically we're interested in\n // MenuColumnWithHeader objects, which TypeScript now \"knows\" we have, but at runtime all we\n // can check for is that it's an object with a valid numeric order field. That's likely good\n // enough.\n if (\n typeof column === 'object' &&\n typeof column.order === 'number' &&\n !Number.isNaN(column.order)\n )\n columnNumbers.set(column.order, { id: columnId, metadata: column });\n else\n console.warn(\n `Property ${columnName} (${typeof column}) on menu ${id} is not a valid column and is being ignored. This might indicate data corruption`,\n );\n });\n\n // Extract values and sort them based on the 'order' property\n return Array.from(columnNumbers.values()).sort((a, b) => {\n return (a.metadata.order || 0) - (b.metadata.order || 0);\n });\n }, [columns, id]);\n\n // We might need something like this if we need to be able to prevent empty columns\n // sortedColumns.filter((c) => multiColumnMenu.groups.some((g) => 'column' in g && (g as .column)...\n\n return (\n \n {sortedColumns.map((col, index) => (\n \n ))}\n \n );\n}\n","import { useEffect, useRef, useState } from 'react';\n\nexport type UsePromiseOptions = {\n /**\n * Whether to leave the value as the most recent resolved promise value or set it back to\n * defaultValue while running the promise again. Defaults to true\n */\n preserveValue?: boolean;\n};\n\n/** Set up defaults for options for usePromise hook */\nfunction getUsePromiseOptionsDefaults(options: UsePromiseOptions): UsePromiseOptions {\n return {\n preserveValue: true,\n ...options,\n };\n}\n\n/**\n * Awaits a promise and returns a loading value while the promise is unresolved\n *\n * @param promiseFactoryCallback A function that returns the promise to await. If this callback is\n * undefined, the current value will be returned (defaultValue unless it was previously changed\n * and `options.preserveValue` is true), and there will be no loading.\n *\n * WARNING: MUST BE STABLE - const or wrapped in useCallback. The reference must not be updated\n * every render\n * @param defaultValue The initial value to return while first awaiting the promise. If\n * `options.preserveValue` is false, this value is also shown while awaiting the promise on\n * subsequent calls.\n *\n * Note: this parameter is internally assigned to a `ref`, so changing it will not cause any hooks\n * to re-run with its new value. This means that, if the `promiseFactoryCallback` changes and\n * `options.preserveValue` is `false`, the returned value will be set to the current\n * `defaultValue`. However, the returned value will not be updated if`defaultValue` changes.\n * @param options Various options for adjusting how this hook runs the `promiseFactoryCallback`\n *\n * Note: this parameter is internally assigned to a `ref`, so changing it will not cause any hooks\n * to re-run with its new value. However, the latest `options.preserveValue` will always be used\n * appropriately to determine whether to preserve the returned value when changing the\n * `promiseFactoryCallback`\n * @returns `[value, isLoading]`\n *\n * - `value`: the current value for the promise, either the defaultValue or the resolved promise value\n * - `isLoading`: whether the promise is waiting to be resolved\n */\nconst usePromise = (\n promiseFactoryCallback: (() => Promise) | undefined,\n defaultValue: T,\n options: UsePromiseOptions = {},\n): [value: T, isLoading: boolean] => {\n // Use defaultValue as a ref so it doesn't update dependency arrays\n const defaultValueRef = useRef(defaultValue);\n defaultValueRef.current = defaultValue;\n // Use options as a ref so it doesn't update dependency arrays\n const optionsDefaultedRef = useRef(options);\n optionsDefaultedRef.current = getUsePromiseOptionsDefaults(optionsDefaultedRef.current);\n\n const [value, setValue] = useState(() => defaultValueRef.current);\n const [isLoading, setIsLoading] = useState(true);\n useEffect(() => {\n let promiseIsCurrent = true;\n // If a promiseFactoryCallback was provided, we are loading. Otherwise, there is no loading to do\n setIsLoading(!!promiseFactoryCallback);\n (async () => {\n // If there is a callback to run, run it\n if (promiseFactoryCallback) {\n const result = await promiseFactoryCallback();\n // If the promise was not already replaced, update the value\n if (promiseIsCurrent) {\n setValue(() => result);\n setIsLoading(false);\n }\n }\n })();\n\n return () => {\n // Mark this promise as old and not to be used\n promiseIsCurrent = false;\n if (!optionsDefaultedRef.current.preserveValue) setValue(() => defaultValueRef.current);\n };\n }, [promiseFactoryCallback]);\n\n return [value, isLoading];\n};\nexport default usePromise;\n","\"use client\";\n\nimport createSvgIcon from './utils/createSvgIcon';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nexport default createSvgIcon( /*#__PURE__*/_jsx(\"path\", {\n d: \"M3 18h18v-2H3zm0-5h18v-2H3zm0-7v2h18V6z\"\n}), 'Menu');","import GridMenu from '@/components/mui/grid-menu.component';\nimport { Command, CommandHandler } from '@/components/mui/menu-item.component';\nimport usePromise from '@/hooks/use-promise.hook';\nimport { Menu as MenuIcon } from '@mui/icons-material';\nimport { Drawer, IconButton } from '@mui/material';\nimport { Localized, MultiColumnMenu } from 'platform-bible-utils';\nimport {\n MouseEvent,\n MutableRefObject,\n PropsWithChildren,\n useCallback,\n useEffect,\n useState,\n} from 'react';\n\nexport interface MultiColumnMenuProvider {\n (isSupportAndDevelopment: boolean): Promise>;\n}\n\nexport type HamburgerMenuButtonProps = PropsWithChildren & {\n /** The handler to use for menu commands (and eventually toolbar commands). */\n commandHandler: CommandHandler;\n\n /**\n * Optional reference to the \"div\" container that determines the where the menu should appear. If\n * not defined, then (1,1) used.\n */\n containerRef?: MutableRefObject;\n\n /**\n * The delegate to use to get the menu data. If not specified or if it returns undefined, the data\n * in normalMenu or fullMenu property will be used.\n */\n menuProvider?: MultiColumnMenuProvider;\n\n /**\n * The menu data to show when the menu is opened if the menuProvider property is not defined.\n * (This allows for a default or test-only static menu to be used.)\n */\n normalMenu?: Localized;\n\n /**\n * The menu data to show for \"full\" menu (when opened with the SHIFT key pressed) if the\n * menuProvider property is not defined. (This allows for a default or test-only static menu to be\n * used.)\n */\n fullMenu?: Localized;\n\n /** Additional css class(es) to help with unique styling of the sub-components */\n className?: string;\n\n /** Value to use as prefix for ARIA labels on interactive sub-components */\n ariaLabelPrefix?: string;\n};\n\nexport default function HamburgerMenuButton({\n menuProvider,\n normalMenu,\n fullMenu,\n commandHandler,\n containerRef,\n className,\n ariaLabelPrefix,\n children,\n}: HamburgerMenuButtonProps) {\n const [isMenuOpen, setMenuOpen] = useState(false);\n const [showFullMenu, setShowFullMenu] = useState(false);\n\n const handleMenuItemClick = useCallback(() => {\n if (isMenuOpen) setMenuOpen(false);\n setShowFullMenu(false);\n }, [isMenuOpen]);\n\n const handleMenuButtonClick = useCallback((e: MouseEvent) => {\n e.stopPropagation();\n setMenuOpen((prevIsOpen) => {\n const isOpening = !prevIsOpen;\n if (isOpening && e.shiftKey) setShowFullMenu(true);\n else if (!isOpening) setShowFullMenu(false);\n return isOpening;\n });\n }, []);\n\n const menuCommandHandler = useCallback(\n (command: Command) => {\n handleMenuItemClick();\n return commandHandler(command);\n },\n [commandHandler, handleMenuItemClick],\n );\n\n const [offset, setOffset] = useState({ top: 1, left: 1 });\n\n useEffect(() => {\n if (isMenuOpen) {\n const node = containerRef?.current;\n if (node) {\n const rect = node.getBoundingClientRect();\n const scrollTop = window.scrollY;\n const scrollLeft = window.scrollX;\n const top = rect.top + scrollTop + node.clientHeight;\n const left = rect.left + scrollLeft;\n setOffset({ top, left });\n }\n }\n }, [isMenuOpen, containerRef]);\n\n const [normalMenuData] = usePromise(\n useCallback(async () => {\n return menuProvider?.(false) ?? normalMenu;\n // isMenuOpen needs to be included for the menu contents to reevaluate when reopened\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [menuProvider, normalMenu, isMenuOpen]),\n normalMenu,\n );\n\n const [fullMenuData] = usePromise(\n useCallback(async () => {\n return menuProvider?.(true) ?? fullMenu ?? normalMenuData;\n // isMenuOpen needs to be included for the menu contents to reevaluate when reopened\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [menuProvider, fullMenu, normalMenuData, isMenuOpen]),\n fullMenu ?? normalMenuData,\n );\n\n const menu = showFullMenu && fullMenuData ? fullMenuData : normalMenuData;\n\n return (\n <>\n \n {children ?? }\n \n \n {menu ? (\n \n ) : undefined}\n \n \n );\n}\n","import '@/components/mui/icon-button.component.css';\nimport { IconButton as MuiIconButton } from '@mui/material';\nimport { MouseEventHandler, PropsWithChildren } from 'react';\n\nexport type IconButtonProps = PropsWithChildren<{\n /** Optional unique identifier */\n id?: string;\n /**\n * Required. Used as both the tooltip (aka, title) and the aria-label (used for accessibility,\n * testing, etc.), unless a distinct tooltip is supplied.\n */\n label: string;\n /**\n * Enabled status of button\n *\n * @default false\n */\n isDisabled?: boolean;\n /** Optional tooltip to display if different from the aria-label. */\n tooltip?: string;\n /** If true, no tooltip will be displayed. */\n isTooltipSuppressed?: boolean;\n /**\n * If given, uses a negative margin to counteract the padding on one side (this is often helpful\n * for aligning the left or right side of the icon with content above or below, without ruining\n * the border size and shape).\n *\n * @default false\n */\n adjustMarginToAlignToEdge?: 'end' | 'start' | false;\n /**\n * The size of the component. small is equivalent to the dense button styling.\n *\n * @default false\n */\n size: 'small' | 'medium' | 'large';\n /** Additional css classes to help with unique styling of the button */\n className?: string;\n /** Optional click handler */\n onClick?: MouseEventHandler;\n}>;\n\n/**\n * Iconic button a user can click to do something\n *\n * Thanks to MUI for heavy inspiration and documentation\n * https://mui.com/material-ui/getting-started/overview/\n */\nfunction IconButton({\n id,\n label,\n isDisabled = false,\n tooltip,\n isTooltipSuppressed = false,\n adjustMarginToAlignToEdge = false,\n size = 'medium',\n className,\n onClick,\n children,\n}: IconButtonProps) {\n return (\n \n {children /* the icon to display */}\n \n );\n}\n\nexport default IconButton;\n","import { cn } from '@/utils/shadcn-ui.util';\nimport { LoaderCircle, LucideProps } from 'lucide-react';\nimport { forwardRef } from 'react';\n\nexport type SpinnerProps = LucideProps;\n\nconst Spinner = forwardRef(({ className, ...props }, ref) => {\n return (\n \n );\n});\n\nSpinner.displayName = 'Spinner';\n\nexport default Spinner;\n","import { Input as ShadInput } from '@/components/shadcn-ui/input';\nimport { Label as ShadLabel } from '@/components/shadcn-ui/label';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { ChangeEventHandler, FocusEventHandler } from 'react';\n\nexport type TextFieldProps = {\n /** Optional unique identifier */\n id?: string;\n /**\n * If `true`, the component is disabled.\n *\n * @default false\n */\n isDisabled?: boolean;\n /**\n * If `true`, the label is displayed in an error state.\n *\n * @default false\n */\n hasError?: boolean;\n /**\n * If `true`, the input will take up the full width of its container.\n *\n * @default false\n */\n isFullWidth?: boolean;\n /** Text that gives the user instructions on what contents the TextField expects */\n helperText?: string;\n /** The title of the TextField */\n label?: string;\n /** The short hint displayed in the `input` before the user enters a value. */\n placeholder?: string;\n /**\n * If `true`, the label is displayed as required and the `input` element is required.\n *\n * @default false\n */\n isRequired?: boolean;\n /** Additional css classes to help with unique styling of the text field */\n className?: string;\n /** Starting value for the text field if it is not controlled */\n defaultValue?: string | number;\n /** Value of the text field if controlled */\n value?: string | number;\n /** Triggers when content of textfield is changed */\n onChange?: ChangeEventHandler;\n /** Triggers when textfield gets focus */\n onFocus?: FocusEventHandler;\n /** Triggers when textfield loses focus */\n onBlur?: FocusEventHandler;\n};\n\n/**\n * Text input field\n *\n * Thanks to Shadcn for heavy inspiration and documentation\n * https://ui.shadcn.com/docs/components/input#with-label\n */\nfunction TextField({\n id,\n isDisabled = false,\n hasError = false,\n isFullWidth = false,\n helperText,\n label,\n placeholder,\n isRequired = false,\n className,\n defaultValue,\n value,\n onChange,\n onFocus,\n onBlur,\n}: TextFieldProps) {\n return (\n
    \n {`${label}${isRequired ? '*' : ''}`}\n \n

    {helperText}

    \n
    \n );\n}\n\nexport default TextField;\n","import HamburgerMenuButton, {\n MultiColumnMenuProvider,\n} from '@/components/mui/hamburger-menu-button.component';\nimport { CommandHandler } from '@/components/mui/menu-item.component';\nimport '@/components/mui/toolbar.component.css';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { AppBar, Toolbar as MuiToolbar } from '@mui/material';\nimport { PropsWithChildren, useRef } from 'react';\n\nexport type ToolbarProps = PropsWithChildren<{\n /** The handler to use for menu commands (and eventually toolbar commands). */\n commandHandler: CommandHandler;\n\n /**\n * The optional delegate to use to get the menu data. If not specified, the \"hamburger\" menu will\n * not display.\n */\n menuProvider?: MultiColumnMenuProvider;\n\n /** Optional unique identifier */\n id?: string;\n\n /** Additional css classes to help with unique styling of the toolbar */\n className?: string;\n}>;\n\nexport default function Toolbar({\n menuProvider,\n commandHandler,\n className,\n id,\n children,\n}: ToolbarProps) {\n // This ref will always be defined\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const containerRef = useRef(undefined!);\n\n return (\n
    \n \n \n {menuProvider ? (\n \n ) : undefined}\n {children ?
    {children}
    : undefined}\n \n
    \n
    \n );\n}\n","import React from 'react';\nimport { cva, type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst alertVariants = cva(\n 'tw-relative tw-w-full tw-rounded-lg tw-border tw-p-4 [&>svg~*]:tw-pl-7 [&>svg+div]:tw-translate-y-[-3px] [&>svg]:tw-absolute [&>svg]:tw-left-4 [&>svg]:tw-top-4 [&>svg]:tw-text-foreground',\n {\n variants: {\n variant: {\n default: 'tw-bg-background tw-text-foreground',\n destructive:\n 'tw-border-destructive/50 tw-text-destructive dark:tw-border-destructive [&>svg]:tw-text-destructive',\n },\n },\n defaultVariants: {\n variant: 'default',\n },\n },\n);\n\nconst Alert = React.forwardRef<\n HTMLDivElement,\n React.HTMLAttributes & VariantProps\n>(({ className, variant, ...props }, ref) => (\n
    \n));\nAlert.displayName = 'Alert';\n\nconst AlertTitle = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n {/* added because of https://github.com/jsx-eslint/eslint-plugin-jsx-a11y/blob/main/docs/rules/heading-has-content.md */}\n {props.children}{' '}\n \n ),\n);\nAlertTitle.displayName = 'AlertTitle';\n\nconst AlertDescription = React.forwardRef<\n HTMLParagraphElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n
    \n));\nAlertDescription.displayName = 'AlertDescription';\n\nexport { Alert, AlertTitle, AlertDescription };\n","import { ComponentProps } from 'react';\nimport { toast as sonner, Toaster } from 'sonner';\n\ntype SonnerProps = ComponentProps;\n\nfunction Sonner({ ...props }: SonnerProps) {\n return (\n \n );\n}\n\n// The re-export of the sonner function was added manually\nexport { Sonner, sonner };\n","import React from 'react';\nimport * as SliderPrimitive from '@radix-ui/react-slider';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Slider = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n \n \n \n));\nSlider.displayName = SliderPrimitive.Root.displayName;\n\nexport { Slider };\n","import React from 'react';\nimport * as SwitchPrimitives from '@radix-ui/react-switch';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Switch = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n));\nSwitch.displayName = SwitchPrimitives.Root.displayName;\n\nexport { Switch };\n","import React from 'react';\nimport * as TabsPrimitive from '@radix-ui/react-tabs';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport const Tabs = TabsPrimitive.Root;\n\nexport type TabsListProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport type TabsTriggerProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport type TabsContentProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport const TabsList = React.forwardRef<\n React.ElementRef,\n TabsListProps\n>(({ className, ...props }, ref) => (\n \n));\nTabsList.displayName = TabsPrimitive.List.displayName;\n\nexport const TabsTrigger = React.forwardRef<\n React.ElementRef,\n TabsTriggerProps\n>(({ className, ...props }, ref) => (\n \n));\nTabsTrigger.displayName = TabsPrimitive.Trigger.displayName;\n\nexport const TabsContent = React.forwardRef<\n React.ElementRef,\n TabsContentProps\n>(({ className, ...props }, ref) => (\n \n));\nTabsContent.displayName = TabsPrimitive.Content.displayName;\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Download } from 'lucide-react';\n\ntype InstallButtonProps = {\n /** The installing boolean value determines the state of the button. */\n isInstalling: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n /** Optional text for the button. */\n buttonText?: string;\n} & ButtonProps;\n\n/**\n * The InstallButton component is a button designed for initiating installs. It includes visuals for\n * active installing and idle states.\n *\n * @param isInstalling The installing boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @param buttonText Optional text for the button.\n * @returns A install button.\n */\nexport default function InstallButton({\n isInstalling,\n handleClick,\n buttonText,\n className,\n ...props\n}: InstallButtonProps) {\n return (\n \n {isInstalling ? (\n \n ) : (\n <>\n \n {buttonText}\n \n )}\n \n );\n}\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\n\ntype EnableButtonProps = {\n /** The enabling boolean value determines the state of the button. */\n isEnabling: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n} & ButtonProps;\n\n/**\n * The EnableButton component is a button designed for initiating enabling of downloads. It includes\n * visuals for active enabling and idle states.\n *\n * @param isEnabling The enabling boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @returns A button that can be used to enable.\n */\nexport default function EnableButton({\n isEnabling,\n handleClick,\n className,\n ...props\n}: EnableButtonProps) {\n return (\n \n {isEnabling ? (\n <>\n \n Enabling...\n \n ) : (\n 'Enable'\n )}\n \n );\n}\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\n\ntype DisableButtonProps = {\n /** The disabling boolean value determines the state of the button. */\n isDisabling: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n} & ButtonProps;\n\n/**\n * The DisableButton component is a button designed for initiating disabling of downloads. It\n * includes visuals for active disabling and idle states.\n *\n * @param isDisabling The disabling boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @returns A button that can be used to disable.\n */\nexport default function DisableButton({\n isDisabling,\n handleClick,\n className,\n ...props\n}: DisableButtonProps) {\n return (\n \n {isDisabling ? (\n <>\n \n Disabling...\n \n ) : (\n 'Disable'\n )}\n \n );\n}\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\n\ntype UpdateButtonProps = {\n /** The updating boolean value determines the state of the button. */\n isUpdating: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n} & ButtonProps;\n\n/**\n * The UpdateButton component is a button designed for initiating updates for downloaded extensions.\n * It includes visuals for active updating and idle states.\n *\n * @param isUpdating The updating boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @returns A button that can be used to update.\n */\nexport default function UpdateButton({\n isUpdating,\n handleClick,\n className,\n ...props\n}: UpdateButtonProps) {\n return (\n \n {isUpdating ? (\n <>\n \n Updating...\n \n ) : (\n 'Update'\n )}\n \n );\n}\n","import { cn } from '@/utils/shadcn-ui.util';\nimport Markdown, { MarkdownToJSX } from 'markdown-to-jsx';\nimport { useMemo } from 'react';\n\ninterface MarkdownRendererProps {\n /** Optional unique identifier */\n id?: string;\n /** The markdown string to render */\n markdown: string;\n className?: string;\n /**\n * The [`target` attribute for `a` html\n * tags](https://developer.mozilla.org/en-US/docs/Web/HTML/Element/a#target). Defaults to not\n * adding a `target` to `a` tags\n */\n anchorTarget?: string;\n}\n\n/**\n * This component renders markdown content given a markdown string. It uses typography styles from\n * the platform.\n *\n * @param markdown The markdown string to render.\n * @param id Optional unique identifier\n * @returns A div containing the rendered markdown content.\n */\nexport default function MarkdownRenderer({\n id,\n markdown,\n className,\n anchorTarget,\n}: MarkdownRendererProps) {\n const options: MarkdownToJSX.Options = useMemo(\n () => ({\n overrides: {\n a: {\n props: {\n target: anchorTarget,\n },\n },\n },\n }),\n [anchorTarget],\n );\n return (\n
    \n {markdown}\n
    \n );\n}\n","import { Filter, ChevronDown } from 'lucide-react';\nimport { forwardRef } from 'react';\nimport { Button } from '@/components/shadcn-ui/button';\n\n/**\n * The FilterButton component is a button designed for initiating filtering of data. It is designed\n * to be used with the dropdown menu. It uses forwardRef to pass the button to the dropdown trigger\n * asChild.\n *\n * @returns A button that can be used to filter.\n */\nconst FilterButton = forwardRef((props, ref) => {\n return (\n \n \n Filter\n \n \n );\n});\n\nexport default FilterButton;\n","import {\n DropdownMenu,\n DropdownMenuTrigger,\n DropdownMenuContent,\n DropdownMenuLabel,\n DropdownMenuGroup,\n DropdownMenuCheckboxItem,\n DropdownMenuRadioItem,\n DropdownMenuSeparator,\n} from '@/components/shadcn-ui/dropdown-menu';\nimport FilterButton from './buttons/filter-button.component';\n\nexport enum DropdownMenuItemType {\n Check,\n Radio,\n}\n\nexport type DropdownItem = {\n /** The label is the text that will be displayed on the dropdown item. */\n label: string;\n /** The itemType determines the DropdownMenuItemType type as either Check or Radio. */\n itemType: DropdownMenuItemType;\n /** The onClick function is called when the item is clicked. */\n onClick: () => void;\n};\n\nexport type DropdownGroup = {\n /**\n * The label is the text that will be displayed on the dropdown group. It is used to categorize\n * the items in the group.\n */\n label: string;\n /** The items array contains the items that will be displayed in the dropdown group */\n items: DropdownItem[];\n};\n\nexport type FilterDropdownProps = {\n /** Object unique identifier */\n id?: string;\n /** The groups array contains the groups that will be displayed in the dropdown */\n groups: DropdownGroup[];\n}; // TODO: extend the props later\n\n/**\n * The FilterDropdown component is a dropdown designed for filtering content. It includes groups of\n * items that can be checkboxes or radio items.\n *\n * @param id Optional unique identifier\n * @param groups The groups array contains the groups that will be displayed in the dropdown\n * @returns A filter dropdown.\n */\nexport default function FilterDropdown({ id, groups }: FilterDropdownProps) {\n return (\n
    \n {/* TODO: remove this once the DropDown Menu shadcn has an id prop */}\n \n \n \n \n \n {groups.map((group) => (\n
    \n {group.label}\n \n {group.items.map((item) => (\n
    \n {item.itemType === DropdownMenuItemType.Check ? (\n \n {item.label}\n \n ) : (\n \n {item.label}\n \n )}\n
    \n ))}\n
    \n \n
    \n ))}\n
    \n
    \n
    \n );\n}\n","interface NoExtensionsFoundProps {\n /** Optional unique identifier */\n id?: string;\n /** The message to display */\n message: string;\n}\n/**\n * This component displays a message to the user when no extensions are found in the marketplace.\n *\n * @param id Optional unique identifier\n * @param message The message to display.\n * @returns {JSX.Element} - Returns the message component that displays the message to the user.\n */\nexport default function NoExtensionsFound({ id, message }: NoExtensionsFoundProps) {\n return (\n
    \n
    \n

    {message}

    \n
    \n
    \n );\n}\n","import { CircleHelp, Link as LucideLink, User } from 'lucide-react';\nimport { NumberFormat } from 'platform-bible-utils';\n\n/** Interface that stores the parameters passed to the More Info component */\ninterface MoreInfoProps {\n /** Optional unique identifier */\n id?: string;\n /** The category of the extension */\n category: string;\n /** The number of downloads for the extension */\n downloads: Record;\n /** The languages supported by the extension */\n languages: string[];\n /** The URL to the more info page of the extension */\n moreInfoUrl: string;\n}\n/**\n * This component displays the more info section of the extension which includes the category,\n * number of downloads, languages, and links to the website and support\n *\n * @param id Optional unique identifier\n * @param category The category of the extension\n * @param downloads The number of downloads for the extension\n * @param languages The languages supported by the extension\n * @param moreInfoUrl The URL to the more info page of the extension\n * @returns {JSX.Element} - Returns the more info component that displays the category, number of\n * downloads, languages, and links to the website and support\n */\nexport default function MoreInfo({\n id,\n category,\n downloads,\n languages,\n moreInfoUrl,\n}: MoreInfoProps) {\n /**\n * This constant formats the number of downloads into a more readable format.\n *\n * @example 1000 -> 1K\n *\n * @example 1000000 -> 1M\n *\n * @returns The formatted number of downloads\n */\n const numberFormatted = new NumberFormat('en', {\n notation: 'compact',\n compactDisplay: 'short',\n }).format(Object.values(downloads).reduce((a: number, b: number) => a + b, 0));\n\n /** This function scrolls the window to the bottom of the page. */\n const handleScrollToBottom = () => {\n window.scrollTo(0, document.body.scrollHeight);\n };\n\n return (\n \n
    \n
    \n {category}\n
    \n CATEGORY\n
    \n
    \n
    \n
    \n \n {numberFormatted}\n
    \n USERS\n
    \n
    \n
    \n
    \n {languages.slice(0, 3).map((locale) => (\n \n {locale.toUpperCase()}\n \n ))}\n
    \n {languages.length > 3 && (\n handleScrollToBottom()}\n className=\"tw-text-xs tw-text-gray-500 tw-underline\"\n >\n +{languages.length - 3} more languages\n \n )}\n
    \n
    \n
    \n \n Website\n \n \n \n Support\n \n \n
    \n
    \n );\n}\n","import { useState } from 'react';\n\nexport type VersionInformation = {\n /** Date the version was published */\n date: string;\n /** Description of the changes in the version */\n description: string;\n};\n\n/** Type to store the version history information */\nexport type VersionHistoryType = Record;\n\n/** Interface that stores the parameters passed to the Version History component */\ninterface VersionHistoryProps {\n /** Optional unique identifier */\n id?: string;\n /** Object containing the versions mapped with their information */\n versionHistory: VersionHistoryType;\n}\n\n/**\n * Component to render the version history information shown in the footer component. Lists the 5\n * most recent versions, with the options to show all versions by pressing a button.\n *\n * @param versionHistory Object containing the versions mapped with their information\n * @param id Optional unique identifier\n * @returns Rendered version history for the Footer component\n */\nexport default function VersionHistory({ id, versionHistory }: VersionHistoryProps) {\n const [showAllVersions, setShowAllVersions] = useState(false);\n const currentDate = new Date();\n\n /**\n * Function to format the time string for the version history in the form of 'X year(s) ago'.\n *\n * @param dateString ISO Date string to determine the time string from\n * @returns Formatted time string\n */\n function formatTimeString(dateString: string) {\n const date = new Date(dateString);\n const dateDiff = new Date(currentDate.getTime() - date.getTime());\n const yearDiff = dateDiff.getUTCFullYear() - 1970;\n const monthDiff = dateDiff.getUTCMonth();\n const dayDiff = dateDiff.getUTCDate() - 1;\n\n // Determines how long ago the version was published\n let timeString = '';\n if (yearDiff > 0) {\n timeString = `${yearDiff.toString()} year${yearDiff === 1 ? '' : 's'} ago`;\n } else if (monthDiff > 0) {\n timeString = `${monthDiff.toString()} month${monthDiff === 1 ? '' : 's'} ago`;\n } else if (dayDiff === 0) {\n timeString = 'today';\n } else {\n timeString = `${dayDiff.toString()} day${dayDiff === 1 ? '' : 's'} ago`;\n }\n\n return timeString;\n }\n\n // Sorts the version history by version number\n const sortedEntries = Object.entries(versionHistory).sort((a, b) => b[0].localeCompare(a[0]));\n\n return (\n
    \n

    What`s New

    \n
      \n {(showAllVersions ? sortedEntries : sortedEntries.slice(0, 5)).map((entry) => (\n
      \n
      \n
    • \n {entry[1].description}\n
    • \n
      \n
      \n
      Version {entry[0]}
      \n
      {formatTimeString(entry[1].date)}
      \n
      \n
      \n ))}\n
    \n {sortedEntries.length > 5 && (\n setShowAllVersions(!showAllVersions)}\n className=\"tw-text-xs tw-text-gray-500 tw-underline\"\n >\n {showAllVersions ? 'Show Less Version History' : 'Show All Version History'}\n \n )}\n
    \n );\n}\n","import { useMemo } from 'react';\nimport { formatBytes } from 'platform-bible-utils';\nimport VersionHistory, { VersionHistoryType } from './version-history.component';\n\n/** Interface to store the parameters passed to the Footer component */\ninterface FooterProps {\n /** Optional unique identifier */\n id?: string;\n /** Name of the publisher */\n publisherDisplayName: string;\n /** Size of the extension file in bytes */\n fileSize: number;\n /** List of language codes supported by the extension */\n locales: string[];\n /** Object containing the version history mapped with their information */\n versionHistory: VersionHistoryType;\n}\n\n/**\n * Component to render the footer for the extension details which contains information on the\n * publisher, version history, languages, and file size.\n *\n * @param id Optional unique identifier\n * @param publisherDisplayName Name of the publisher\n * @param fileSize Size of the extension file in bytes\n * @param locales List of language codes supported by the extension\n * @param versionHistory Object containing the version history mapped with their information\n * @returns The rendered Footer component\n */\nexport default function Footer({\n id,\n publisherDisplayName,\n fileSize,\n locales,\n versionHistory,\n}: FooterProps) {\n /** Formats the file size into a human-readable format */\n const formattedFileSize = useMemo(() => formatBytes(fileSize), [fileSize]);\n\n /**\n * This function gets the display names of the languages based on the language codes.\n *\n * @param codes The list of language codes\n * @returns The list of language names\n */\n const getLanguageNames = (codes: string[]) => {\n const displayNames = new Intl.DisplayNames(navigator.language, { type: 'language' });\n return codes.map((code) => displayNames.of(code));\n };\n\n const languageNames = getLanguageNames(locales);\n\n return (\n
    \n
    \n \n
    \n
    \n

    Information

    \n
    \n

    \n Publisher\n {publisherDisplayName}\n Size\n {formattedFileSize}\n

    \n
    \n

    \n Languages\n {languageNames.join(', ')}\n

    \n
    \n
    \n
    \n
    \n
    \n );\n}\n","import { PlatformEvent, PlatformEventHandler } from 'platform-bible-utils';\nimport { useEffect } from 'react';\n\n/**\n * Adds an event handler to an event so the event handler runs when the event is emitted. Use\n * `papi.network.getNetworkEvent` to use a networked event with this hook.\n *\n * @param event The event to subscribe to.\n *\n * - If event is a `PlatformEvent`, that event will be used\n * - If event is undefined, the callback will not be subscribed. Useful if the event is not yet\n * available for example\n *\n * @param eventHandler The callback to run when the event is emitted\n *\n * WARNING: MUST BE STABLE - const or wrapped in useCallback. The reference must not be updated\n * every render\n */\nconst useEvent = (\n event: PlatformEvent | undefined,\n eventHandler: PlatformEventHandler,\n) => {\n useEffect(() => {\n // Do nothing if the event is not provided (in case the event is not yet available, for example)\n if (!event) return () => {};\n\n const unsubscriber = event(eventHandler);\n return () => {\n unsubscriber();\n };\n }, [event, eventHandler]);\n};\nexport default useEvent;\n","import { useCallback, useEffect } from 'react';\nimport { PlatformEvent, PlatformEventAsync, PlatformEventHandler } from 'platform-bible-utils';\nimport usePromise from './use-promise.hook';\n\nconst noopUnsubscriber = () => false;\n\n/**\n * Adds an event handler to an asynchronously subscribing/unsubscribing event so the event handler\n * runs when the event is emitted. Use `papi.network.getNetworkEvent` to use a networked event with\n * this hook.\n *\n * @param event The asynchronously (un)subscribing event to subscribe to.\n *\n * - If event is a `PlatformEvent` or `PlatformEventAsync`, that event will be used\n * - If event is undefined, the callback will not be subscribed. Useful if the event is not yet\n * available for example\n *\n * @param eventHandler The callback to run when the event is emitted\n *\n * WARNING: MUST BE STABLE - const or wrapped in useCallback. The reference must not be updated\n * every render\n */\nconst useEventAsync = (\n event: PlatformEvent | PlatformEventAsync | undefined,\n eventHandler: PlatformEventHandler,\n) => {\n // Subscribe to the event asynchronously\n const [unsubscribe] = usePromise(\n useCallback(async () => {\n // Do nothing if the event is not provided (in case the event is not yet available, for example)\n if (!event) return noopUnsubscriber;\n\n // Wrap subscribe and unsubscribe in promises to allow normal events to be used as well\n const unsub = await Promise.resolve(event(eventHandler));\n return async () => unsub();\n }, [eventHandler, event]),\n noopUnsubscriber,\n // We want the unsubscriber to return to default value immediately upon changing subscription\n // So the useEffect below will unsubscribe asap\n { preserveValue: false },\n );\n\n // Unsubscribe from the event asynchronously (but we aren't awaiting the unsub)\n useEffect(() => {\n return () => {\n if (unsubscribe !== noopUnsubscriber) {\n unsubscribe();\n }\n };\n }, [unsubscribe]);\n};\n\nexport default useEventAsync;\n"],"names":["twMergeCustom","extendTailwindMerge","cn","inputs","clsx","Input","React","className","type","props","ref","jsx","BookChapterInput","forwardRef","handleSearch","handleKeyDown","handleOnClick","handleSubmit","jsxs","ShadInput","event","e","History","P","R","s","n","N","B","O","S","K","g","k","x","T","X","V","w","L","G","A","H","C","I","y","q","U","m","l","h","c","E","D","i","a","o","u","v","f","d","b","J","DropdownMenu","DropdownMenuPrimitive","DropdownMenuTrigger","DropdownMenuGroup","DropdownMenuPortal","DropdownMenuSub","DropdownMenuRadioGroup","DropdownMenuSubTrigger","inset","children","ChevronRight","DropdownMenuSubContent","DropdownMenuContent","sideOffset","DropdownMenuItem","DropdownMenuCheckboxItem","checked","Check","DropdownMenuRadioItem","Circle","DropdownMenuLabel","DropdownMenuSeparator","DropdownMenuShortcut","BookMenuItem","bookId","handleSelectBook","isSelected","handleHighlightBook","bookType","ShadDropdownMenuItem","Canon","ChapterSelect","handleSelectChapter","endChapter","activeChapter","highlightedChapter","handleHighlightedChapter","chapters","_","handleMouse","useCallback","chapterNumber","chapter","GoToMenuItem","handleSort","handleLocationHistory","handleBookmarks","ShadDropdownMenuLabel","ArrowDownWideNarrow","Clock","Bookmark","ALL_BOOK_IDS","BOOK_TYPE_LABELS","BOOK_TYPE_ARRAY","SCROLL_OFFSET","SEARCH_QUERY_FORMATS","fetchGroupedBooks","fetchEndChapter","getChaptersForBook","getAllEnglishNames","isValidBookEnglishName","bookName","getBookIdFromEnglishName","formattedBookName","BookChapterControl","scrRef","searchQuery","setSearchQuery","useState","selectedBookId","setSelectedBookId","setHighlightedChapter","highlightedBookId","setHighlightedBookId","isContentOpen","setIsContentOpen","isContentOpenDelayed","setIsContentOpenDelayed","inputRef","useRef","contentRef","menuItemRef","fetchFilteredBooks","englishNameLowerCase","normalizedQuery","handleSearchInput","searchString","shouldPreventAutoClosing","controlMenuState","open","updateReference","shouldClose","verse","handleInputSubmit","format","matches","book","englishName","handleKeyDownInput","handleKeyDownContent","key","handleKeyDownMenuItem","chapterOffSet","useEffect","useLayoutEffect","scrollTimeout","scrollPosition","ShadDropdownMenu","ShadDropdownMenuTrigger","ShadDropdownMenuContent","bookTypeIndex","element","ShadDropdownMenuSeparator","buttonVariants","cva","Button","variant","size","asChild","Slot","labelVariants","Label","LabelPrimitive","RadioGroup","RadioGroupPrimitive","RadioGroupItem","Popover","PopoverPrimitive","PopoverTrigger","PopoverContent","align","DialogPortal","DialogPrimitive","DialogOverlay","DialogContent","DialogTitle","DialogDescription","Command","CommandPrimitive","CommandInput","Search","CommandList","CommandEmpty","CommandGroup","CommandSeparator","CommandItem","getOptionLabelDefault","option","ComboBox","id","options","buttonClassName","popoverContentClassName","value","onChange","getOptionLabel","buttonPlaceholder","textPlaceholder","commandEmptyMessage","buttonVariant","dir","isDisabled","setOpen","ChevronsUpDown","ChapterRangeSelector","startChapter","handleSelectStartChapter","handleSelectEndChapter","chapterCount","chapterOptions","useMemo","index","Fragment","BookSelectionMode","BOOK_SELECTOR_STRING_KEYS","localizeString","strings","BookSelector","handleBookSelectionModeChange","currentBookName","onSelectBooks","selectedBookIds","localizedStrings","currentBookText","chooseText","chooseBooksText","bookSelectionMode","setBookSelectionMode","onSelectionModeChange","newMode","DataTableViewOptions","table","FilterIcon","column","Select","SelectPrimitive","SelectGroup","SelectValue","SelectTrigger","ChevronDown","SelectScrollUpButton","ChevronUp","SelectScrollDownButton","SelectContent","position","SelectLabel","SelectItem","SelectSeparator","DataTablePagination","pageSize","ArrowLeftIcon","ChevronLeftIcon","ChevronRightIcon","ArrowRightIcon","Table","stickyHeader","TableHeader","TableBody","TableFooter","TableRow","TableHead","TableCell","TableCaption","DataTable","columns","data","enablePagination","showPaginationControls","showColumnVisibilityControls","onRowClickHandler","sorting","setSorting","columnFilters","setColumnFilters","columnVisibility","setColumnVisibility","rowSelection","setRowSelection","useReactTable","getCoreRowModel","getPaginationRowModel","getSortedRowModel","getFilteredRowModel","headerGroup","header","flexRender","_a","row","cell","OccurrencesTable","occurrenceData","setScriptureReference","referenceHeaderText","occurrenceHeaderText","occurrences","uniqueOccurrences","occurrence","uniqueOccurrence","deepEqual","Checkbox","CheckboxPrimitive","getLinesFromUSFM","text","getNumberFromUSFM","regex","match","getBookNumFromId","getStatusForItem","item","approvedItems","unapprovedItems","toggleVariants","Toggle","TogglePrimitive","ToggleGroupContext","ToggleGroup","ToggleGroupPrimitive","ToggleGroupItem","context","getSortingIcon","sortDirection","ArrowUpIcon","ArrowDownIcon","ArrowUpDownIcon","inventoryItemColumn","itemLabel","inventoryAdditionalItemColumn","additionalItemLabel","additionalItemIndex","inventoryCountColumn","countLabel","statusChangeHandler","changedItems","newStatus","onApprovedItemsChange","onUnapprovedItemsChange","newApprovedItems","validItem","newUnapprovedItems","unapprovedItem","inventoryStatusColumn","statusLabel","status","CircleCheckIcon","CircleXIcon","CircleHelpIcon","INVENTORY_STRING_KEYS","filterItemData","itemData","statusFilter","textFilter","filteredItemData","createTableData","scriptureRef","itemRegex","tableData","currentBook","currentChapter","currentVerse","line","items","itemIndex","existingItem","tableEntry","newReference","substring","newItem","Inventory","scriptureReference","extractItems","additionalItemsLabels","scope","onScopeChange","allItemsText","approvedItemsText","unapprovedItemsText","unknownItemsText","scopeBookText","scopeChapterText","scopeVerseText","filterText","showAdditionalItemsText","showAdditionalItems","setShowAdditionalItems","setStatusFilter","setTextFilter","selectedItem","setSelectedItem","reducedTableData","newTableData","firstItem","existingEntry","newTableEntry","filteredTableData","allColumns","numberOfAdditionalItems","additionalColumns","_b","rowClickHandler","newSelection","handleScopeChange","handleStatusFilterChange","SearchBar","onSearch","placeholder","isFullWidth","handleInputChange","VerticalTabs","TabsPrimitive","VerticalTabsList","VerticalTabsTrigger","VerticalTabsContent","TabNavigationContentSearch","tabList","searchPlaceholder","headerTitle","isSearchBarFullWidth","direction","tab","Separator","orientation","decorative","SeparatorPrimitive","Sheet","SheetPrimitive","SheetPortal","SheetOverlay","sheetVariants","SheetContent","side","SheetTitle","SheetDescription","Skeleton","TooltipProvider","TooltipPrimitive","Tooltip","TooltipTrigger","TooltipContent","MOBILE_BREAKPOINT","useIsMobile","isMobile","setIsMobile","mql","SIDEBAR_COOKIE_NAME","SIDEBAR_COOKIE_MAX_AGE","SIDEBAR_WIDTH","SIDEBAR_WIDTH_MOBILE","SIDEBAR_WIDTH_ICON","SIDEBAR_KEYBOARD_SHORTCUT","SidebarContext","useSidebar","SidebarProvider","defaultOpen","openProp","setOpenProp","style","openMobile","setOpenMobile","_open","_setOpen","isOpen","openState","toggleSidebar","state","contextValue","Sidebar","collapsible","SidebarTrigger","onClick","PanelLeft","SidebarRail","SidebarInset","SidebarInput","SidebarHeader","SidebarFooter","SidebarSeparator","SidebarContent","SidebarGroup","SidebarGroupLabel","SidebarGroupAction","SidebarGroupContent","SidebarMenu","SidebarMenuItem","sidebarMenuButtonVariants","SidebarMenuButton","isActive","tooltip","Comp","button","SidebarMenuAction","showOnHover","SidebarMenuBadge","SidebarMenuSkeleton","showIcon","width","SidebarMenuSub","SidebarMenuSubItem","SidebarMenuSubButton","SettingsSidebar","extensionLabels","projectOptions","handleSelectSidebarItem","selectedSidebarItem","handleSelectItem","projectId","getProjectNameFromProjectId","project","getIsActive","label","selectedProjectName","SettingsSidebarContentSearch","scrBookColId","scrRefColId","typeColId","detailsColId","defaultScrRefColumnName","defaultScrBookGroupName","defaultTypeColumnName","defaultDetailsColumnName","getColumns","colInfo","showSourceColumn","showSrcCol","info","formatScrRef","compareScrRefs","toRefOrRange","scriptureSelection","offsetStart","offsetEnd","scrRefToBBBCCCVVV","getRowKey","ScriptureResultsViewer","sources","showColumnHeaders","scriptureReferenceColumnName","scriptureBookGroupName","typeColumnName","detailsColumnName","onRowSelected","grouping","setGrouping","scriptureResults","source","getExpandedRowModel","getGroupedRowModel","selectedRows","keys","selectedRow","scrBookGroupName","typeGroupName","groupingOptions","handleSelectChange","selectedGrouping","handleRowClick","getEvenOrOddBandingStyle","getIndent","groupingState","rowIndex","ChevronLeft","DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS","getLocalizeKeyForScrollGroupId","ScrollGroupSelector","availableScrollGroupIds","scrollGroupId","onChangeScrollGroupId","localizedStringsDefaulted","localizedStringKey","localizedStringValue","newScrollGroupString","scrollGroupOptionId","SettingsList","SettingsListItem","primary","secondary","isLoading","loadingMessage","SettingsListHeader","includeSeparator","Card","CardHeader","CardTitle","CardDescription","CardContent","CardFooter","SettingsCard","settingsGroupLabel","settingsGroupDescription","Checklist","listItems","selectedListItems","handleSelectListItem","createLabel","_interopRequireDefault","obj","module","chainPropTypes","propType1","propType2","args","_extends","target","isPlainObject","prototype","deepClone","output","deepmerge","p","r","t","z","reactIs_production_min","hasSymbol","REACT_ELEMENT_TYPE","REACT_PORTAL_TYPE","REACT_FRAGMENT_TYPE","REACT_STRICT_MODE_TYPE","REACT_PROFILER_TYPE","REACT_PROVIDER_TYPE","REACT_CONTEXT_TYPE","REACT_ASYNC_MODE_TYPE","REACT_CONCURRENT_MODE_TYPE","REACT_FORWARD_REF_TYPE","REACT_SUSPENSE_TYPE","REACT_SUSPENSE_LIST_TYPE","REACT_MEMO_TYPE","REACT_LAZY_TYPE","REACT_BLOCK_TYPE","REACT_FUNDAMENTAL_TYPE","REACT_RESPONDER_TYPE","REACT_SCOPE_TYPE","isValidElementType","typeOf","object","$$typeof","$$typeofType","AsyncMode","ConcurrentMode","ContextConsumer","ContextProvider","Element","ForwardRef","Lazy","Memo","Portal","Profiler","StrictMode","Suspense","hasWarnedAboutDeprecatedIsAsyncMode","isAsyncMode","isConcurrentMode","isContextConsumer","isContextProvider","isElement","isForwardRef","isFragment","isLazy","isMemo","isPortal","isProfiler","isStrictMode","isSuspense","reactIs_development","reactIsModule","require$$0","require$$1","getOwnPropertySymbols","hasOwnProperty","propIsEnumerable","toObject","val","shouldUseNative","test1","test2","order2","test3","letter","objectAssign","from","to","symbols","ReactPropTypesSecret","ReactPropTypesSecret_1","has","printWarning","loggedTypeFailures","message","checkPropTypes","typeSpecs","values","location","componentName","getStack","typeSpecName","error","err","ex","stack","checkPropTypes_1","ReactIs","assign","require$$2","require$$3","require$$4","emptyFunctionThatReturnsNull","factoryWithTypeCheckers","isValidElement","throwOnDirectAccess","ITERATOR_SYMBOL","FAUX_ITERATOR_SYMBOL","getIteratorFn","maybeIterable","iteratorFn","ANONYMOUS","ReactPropTypes","createPrimitiveTypeChecker","createAnyTypeChecker","createArrayOfTypeChecker","createElementTypeChecker","createElementTypeTypeChecker","createInstanceTypeChecker","createNodeChecker","createObjectOfTypeChecker","createEnumTypeChecker","createUnionTypeChecker","createShapeTypeChecker","createStrictShapeTypeChecker","is","PropTypeError","createChainableTypeChecker","validate","manualPropTypeCallCache","manualPropTypeWarningCount","checkType","isRequired","propName","propFullName","secret","cacheKey","chainedCheckType","expectedType","propValue","propType","getPropType","preciseType","getPreciseType","typeChecker","expectedClass","expectedClassName","actualClassName","getClassName","expectedValues","valuesString","arrayOfTypeCheckers","checker","getPostfixForTypeWarning","expectedTypes","checkerResult","expectedTypesMessage","isNode","invalidValidatorError","shapeTypes","allKeys","iterator","step","entry","isSymbol","emptyFunction","emptyFunctionWithReset","factoryWithThrowingShims","shim","getShim","propTypesModule","isClassComponent","elementType","acceptingRef","safePropName","warningHint","elementAcceptingRef","PropTypes","elementAcceptingRef$1","specialProperty","exactProp","propTypes","unsupportedProps","prop","formatMuiErrorMessage","code","url","REACT_SERVER_CONTEXT_TYPE","REACT_OFFSCREEN_TYPE","enableScopeAPI","enableCacheElement","enableTransitionTracing","enableLegacyHidden","enableDebugTracing","REACT_MODULE_REFERENCE","SuspenseList","hasWarnedAboutDeprecatedIsConcurrentMode","isSuspenseList","fnNameMatchRegex","getFunctionName","fn","getFunctionComponentName","Component","fallback","getWrappedName","outerType","innerType","wrapperName","functionName","getDisplayName","HTMLElementType","refType","refType$1","capitalize","string","_formatMuiErrorMessage","createChainedFunction","funcs","acc","func","debounce","wait","timeout","debounced","later","deprecatedPropType","validator","reason","componentNameSafe","propFullNameSafe","isMuiElement","muiNames","_muiName","_element$type","ownerDocument","node","ownerWindow","requirePropFactory","componentNameInError","prevPropTypes","requiredProp","defaultTypeChecker","typeCheckerResult","setRef","useEnhancedEffect","useEnhancedEffect$1","globalId","useGlobalId","idOverride","defaultId","setDefaultId","maybeReactUseId","useId","reactId","unsupportedProp","useControlled","controlled","defaultProp","name","isControlled","valueState","setValue","defaultValue","setValueIfUncontrolled","newValue","useEventCallback","useForkRef","refs","instance","UNINITIALIZED","useLazyRef","init","initArg","EMPTY","useOnMount","Timeout","delay","useTimeout","hadKeyboardEvent","hadFocusVisibleRecently","hadFocusVisibleRecentlyTimeout","inputTypesWhitelist","focusTriggersKeyboardModality","tagName","handlePointerDown","handleVisibilityChange","prepare","doc","isFocusVisible","useIsFocusVisible","isFocusVisibleRef","handleBlurVisible","handleFocusVisible","resolveProps","defaultProps","defaultSlotProps","slotProps","slotPropName","composeClasses","slots","getUtilityClass","classes","slot","utilityClass","defaultGenerator","createClassNameGenerator","generate","generator","ClassNameGenerator","ClassNameGenerator$1","globalStateClasses","generateUtilityClass","globalStatePrefix","globalStateClass","generateUtilityClasses","result","clamp","min","max","_objectWithoutPropertiesLoose","excluded","sourceKeys","_excluded","sortBreakpointsValues","breakpointsAsArray","breakpoint1","breakpoint2","createBreakpoints","breakpoints","unit","other","sortedValues","up","down","between","start","end","endIndex","only","not","keyIndex","shape","shape$1","responsivePropType","responsivePropType$1","merge","defaultBreakpoints","handleBreakpoints","styleFromPropValue","theme","themeBreakpoints","breakpoint","mediaKey","cssKey","createEmptyBreakpointObject","breakpointsInput","_breakpointsInput$key","breakpointStyleKey","removeUnusedBreakpoints","breakpointKeys","breakpointOutput","getPath","path","checkVars","getStyleValue","themeMapping","transform","propValueFinal","userValue","cssProperty","themeKey","memoize","cache","arg","properties","directions","aliases","getCssProperties","property","marginKeys","paddingKeys","spacingKeys","createUnaryUnit","_getPath","themeSpacing","abs","createUnarySpacing","getValue","transformer","transformed","getStyleFromPropValue","cssProperties","resolveCssProperty","margin","padding","createSpacing","spacingInput","spacing","argsInput","argument","compose","styles","handlers","borderTransform","createBorderStyle","border","borderTop","borderRight","borderBottom","borderLeft","borderColor","borderTopColor","borderRightColor","borderBottomColor","borderLeftColor","outline","outlineColor","borderRadius","gap","columnGap","rowGap","gridColumn","gridRow","gridAutoFlow","gridAutoColumns","gridAutoRows","gridTemplateColumns","gridTemplateRows","gridTemplateAreas","gridArea","paletteTransform","color","bgcolor","backgroundColor","sizingTransform","maxWidth","_props$theme","_props$theme2","breakpointsValues","minWidth","height","maxHeight","minHeight","boxSizing","defaultSxConfig","defaultSxConfig$1","objectsHaveSameKeys","objects","union","callIfFn","maybeFn","unstable_createStyleFunctionSx","getThemeValue","config","styleFunctionSx","_theme$unstable_sxCon","sx","traverse","sxInput","sxObject","emptyBreakpoints","breakpointsKeys","css","styleKey","styleFunctionSx$1","applyStyles","createTheme","paletteInput","shapeInput","muiTheme","isObjectEmpty","useTheme","defaultTheme","contextTheme","ThemeContext","systemDefaultTheme","useThemeWithoutDefault","_excluded2","_excluded3","isEmpty","isStringTag","tag","shouldForwardProp","lowercaseFirstLetter","resolveTheme","themeId","defaultOverridesResolver","processStyleArg","callableStyle","_ref","ownerState","resolvedStylesArg","resolvedStyle","variants","isMatch","createStyled","input","rootShouldForwardProp","slotShouldForwardProp","systemSx","inputOptions","processStyles","componentSlot","inputSkipVariantsResolver","inputSkipSx","overridesResolver","skipVariantsResolver","skipSx","shouldForwardPropOption","defaultStyledResolver","styledEngineStyled","transformStyleArg","stylesArg","muiStyledResolver","styleArg","expressions","transformedStyleArg","expressionsWithDefaultTheme","styleOverrides","resolvedStyleOverrides","slotKey","slotStyle","_theme$components","themeVariants","numOfCustomFnsApplied","placeholders","displayName","getThemeProps","params","useThemeProps","clampWrapper","hexToRgb","re","colors","decomposeColor","marker","colorSpace","recomposeColor","hslToRgb","rgb","getLuminance","getContrastRatio","foreground","background","lumA","lumB","alpha","darken","coefficient","lighten","createMixins","mixins","common","common$1","grey","grey$1","purple","purple$1","red","red$1","orange","orange$1","blue","blue$1","lightBlue","lightBlue$1","green","green$1","light","dark","addLightOrDark","intent","shade","tonalOffset","tonalOffsetLight","tonalOffsetDark","getDefaultPrimary","mode","getDefaultSecondary","getDefaultError","getDefaultInfo","getDefaultSuccess","getDefaultWarning","createPalette","palette","contrastThreshold","success","warning","getContrastText","contrastText","contrast","augmentColor","mainShade","lightShade","darkShade","modes","round","caseAllCaps","defaultFontFamily","createTypography","typography","fontFamily","fontSize","fontWeightLight","fontWeightRegular","fontWeightMedium","fontWeightBold","htmlFontSize","allVariants","pxToRem2","coef","pxToRem","buildVariant","fontWeight","lineHeight","letterSpacing","casing","shadowKeyUmbraOpacity","shadowKeyPenumbraOpacity","shadowAmbientShadowOpacity","createShadow","px","shadows","shadows$1","easing","duration","formatMs","milliseconds","getAutoHeightDuration","constant","createTransitions","inputTransitions","mergedEasing","mergedDuration","durationOption","easingOption","isString","isNumber","animatedProp","zIndex","zIndex$1","mixinsInput","transitionsInput","typographyInput","systemTheme","systemCreateTheme","stateClasses","component","child","stateClass","defaultTheme$1","THEME_ID","systemUseThemeProps","styled","styled$1","getSvgIconUtilityClass","useUtilityClasses","SvgIconRoot","_theme$transitions","_theme$transitions$cr","_theme$transitions2","_theme$typography","_theme$typography$pxT","_theme$typography2","_theme$typography2$px","_theme$typography3","_theme$typography3$px","_palette$ownerState$c","_palette","_palette2","_palette3","SvgIcon","inProps","htmlColor","inheritViewBox","titleAccess","viewBox","hasSvgAsChild","more","_jsxs","_jsx","SvgIcon$1","createSvgIcon","unstable_ClassNameGenerator","exports","_utils","ArrowRight","default_1","_createSvgIcon","_jsxRuntime","isHostComponent","appendOwnerState","otherProps","defaultContextValue","ClassNameConfiguratorContext","useClassNamesOverride","disableDefaultClasses","extractEventHandlers","excludeKeys","resolveComponentProps","componentProps","slotState","omitEventHandlers","mergeSlotProps","parameters","getSlotProps","additionalProps","externalSlotProps","externalForwardedProps","joinedClasses","mergedStyle","eventHandlers","componentsPropsWithoutEventHandlers","otherPropsWithoutEventHandlers","internalSlotProps","useSlotProps","_parameters$additiona","skipResolvingSlotProps","rest","resolvedComponentsProps","mergedProps","internalRef","GLOBAL_CLASS_PREFIX","buildStateClass","buildSlotClass","getContainer","container","forwardedRef","disablePortal","mountNode","setMountNode","handleRef","newProps","ReactDOM","top","bottom","right","left","auto","basePlacements","clippingParents","viewport","popper","reference","variationPlacements","placement","placements","beforeRead","read","afterRead","beforeMain","main","afterMain","beforeWrite","write","afterWrite","modifierPhases","getNodeName","getWindow","OwnElement","isHTMLElement","isShadowRoot","attributes","effect","_ref2","initialStyles","styleProperties","attribute","applyStyles$1","getBasePlacement","getUAString","uaData","isLayoutViewport","getBoundingClientRect","includeScale","isFixedStrategy","clientRect","scaleX","scaleY","visualViewport","addVisualOffsets","getLayoutRect","contains","parent","rootNode","next","getComputedStyle","isTableElement","getDocumentElement","getParentNode","getTrueOffsetParent","getContainingBlock","isFirefox","isIE","elementCss","currentNode","getOffsetParent","window","offsetParent","getMainAxisFromPlacement","within","mathMax","mathMin","withinMaxClamp","getFreshSideObject","mergePaddingObject","paddingObject","expandToHashMap","hashMap","toPaddingObject","arrow","_state$modifiersData$","arrowElement","popperOffsets","basePlacement","axis","isVertical","len","arrowRect","minProp","maxProp","endDiff","startDiff","arrowOffsetParent","clientSize","centerToReference","center","offset","axisProp","_options$element","arrow$1","getVariation","unsetSides","roundOffsetsByDPR","win","dpr","mapToStyles","_Object$assign2","popperRect","variation","offsets","gpuAcceleration","adaptive","roundOffsets","isFixed","_offsets$x","_offsets$y","_ref3","hasX","hasY","sideX","sideY","heightProp","widthProp","offsetY","offsetX","commonStyles","_ref4","_Object$assign","computeStyles","_ref5","_options$gpuAccelerat","_options$adaptive","_options$roundOffsets","computeStyles$1","passive","_options$scroll","scroll","_options$resize","resize","scrollParents","scrollParent","eventListeners","hash","getOppositePlacement","matched","getOppositeVariationPlacement","getWindowScroll","scrollLeft","scrollTop","getWindowScrollBarX","getViewportRect","strategy","html","layoutViewport","getDocumentRect","_element$ownerDocumen","winScroll","body","isScrollParent","_getComputedStyle","overflow","overflowX","overflowY","getScrollParent","listScrollParents","list","isBody","updatedList","rectToClientRect","rect","getInnerBoundingClientRect","getClientRectFromMixedType","clippingParent","getClippingParents","canEscapeClipping","clipperElement","getClippingRect","boundary","rootBoundary","mainClippingParents","firstClippingParent","clippingRect","accRect","computeOffsets","commonX","commonY","mainAxis","detectOverflow","_options","_options$placement","_options$strategy","_options$boundary","_options$rootBoundary","_options$elementConte","elementContext","_options$altBoundary","altBoundary","_options$padding","altContext","clippingClientRect","referenceClientRect","popperClientRect","elementClientRect","overflowOffsets","offsetData","multiply","computeAutoPlacement","flipVariations","_options$allowedAutoP","allowedAutoPlacements","allPlacements","allowedPlacements","overflows","getExpandedFallbackPlacements","oppositePlacement","flip","_options$mainAxis","checkMainAxis","_options$altAxis","checkAltAxis","specifiedFallbackPlacements","_options$flipVariatio","preferredPlacement","isBasePlacement","fallbackPlacements","referenceRect","checksMap","makeFallbackChecks","firstFittingPlacement","_basePlacement","isStartVariation","mainVariationSide","altVariationSide","checks","check","numberOfChecks","_loop","_i","fittingPlacement","_ret","flip$1","getSideOffsets","preventedOffsets","isAnySideFullyClipped","hide","referenceOverflow","popperAltOverflow","referenceClippingOffsets","popperEscapeOffsets","isReferenceHidden","hasPopperEscaped","hide$1","distanceAndSkiddingToXY","rects","invertDistance","skidding","distance","_options$offset","_data$state$placement","offset$1","popperOffsets$1","getAltAxis","preventOverflow","_options$tether","tether","_options$tetherOffset","tetherOffset","altAxis","tetherOffsetValue","normalizedTetherOffsetValue","offsetModifierState","_offsetModifierState$","mainSide","altSide","additive","minLen","maxLen","arrowPaddingObject","arrowPaddingMin","arrowPaddingMax","arrowLen","minOffset","maxOffset","clientOffset","offsetModifierValue","tetherMin","tetherMax","preventedOffset","_offsetModifierState$2","_mainSide","_altSide","_offset","_len","_min","_max","isOriginSide","_offsetModifierValue","_tetherMin","_tetherMax","_preventedOffset","preventOverflow$1","getHTMLElementScroll","getNodeScroll","isElementScaled","getCompositeRect","elementOrVirtualElement","isOffsetParentAnElement","offsetParentIsScaled","documentElement","order","modifiers","map","visited","modifier","sort","requires","dep","depModifier","orderModifiers","orderedModifiers","phase","pending","resolve","mergeByName","merged","current","existing","DEFAULT_OPTIONS","areValidElements","_key","popperGenerator","generatorOptions","_generatorOptions","_generatorOptions$def","defaultModifiers","_generatorOptions$def2","defaultOptions","effectCleanupFns","isDestroyed","setOptionsAction","cleanupModifierEffects","runModifierEffects","_state$elements","_state$orderedModifie","_state$orderedModifie2","_ref$options","cleanupFn","noopFn","createPopper","COMPONENT_NAME","getPopperUtilityClass","flipPlacement","resolveAnchorEl","anchorEl","isVirtualElement","defaultPopperOptions","PopperTooltip","_slots$root","initialPlacement","popperOptions","popperRefProp","TransitionProps","tooltipRef","ownRef","popperRef","handlePopperRef","handlePopperRefRef","rtlPlacement","setPlacement","resolvedAnchorElement","setResolvedAnchorElement","handlePopperUpdate","box","popperModifiers","childProps","Root","rootProps","Popper","containerProp","keepMounted","transition","exited","setExited","handleEnter","handleExited","resolvedAnchorEl","display","transitionProps","useThemeSystem","_setPrototypeOf","_inheritsLoose","subClass","superClass","setPrototypeOf","timeoutsShape","TransitionGroupContext","forceReflow","UNMOUNTED","EXITED","ENTERING","ENTERED","EXITING","Transition","_React$Component","_this","parentGroup","appear","initialStatus","prevState","nextIn","_proto","prevProps","nextStatus","exit","enter","mounting","_this2","appearing","maybeNode","maybeAppearing","timeouts","enterTimeout","_this3","nextState","callback","_this4","active","handler","doesNotHaveTimeoutOrListener","maybeNextCallback","_this$props","pt","noop","Transition$1","reflow","getTransitionProps","_style$transitionDura","_style$transitionTimi","getScale","isWebKit154","Grow","addEndListener","inProp","onEnter","onEntered","onEntering","onExit","onExited","onExiting","TransitionComponent","timer","autoTimeout","nodeRef","normalizedTransitionCallback","maybeIsAppearing","handleEntering","isAppearing","transitionDuration","transitionTimingFunction","handleEntered","handleExiting","handleExit","Grow$1","PopperRoot","BasePopper","components","componentsProps","RootComponent","Popper$1","getTooltipUtilityClass","tooltipClasses","tooltipClasses$1","disableInteractive","touch","TooltipPopper","TooltipTooltip","TooltipArrow","hystersisOpen","hystersisTimer","cursorPosition","composeEventHandler","eventHandler","_slots$popper","_slots$transition","_slots$tooltip","_slots$arrow","_slotProps$popper","_ref6","_slotProps$popper2","_slotProps$transition","_slotProps$tooltip","_ref7","_slotProps$tooltip2","_slotProps$arrow","_ref8","_slotProps$arrow2","childrenProp","describeChild","disableFocusListener","disableHoverListener","disableInteractiveProp","disableTouchListener","enterDelay","enterNextDelay","enterTouchDelay","followCursor","idProp","leaveDelay","leaveTouchDelay","onClose","onOpen","PopperComponentProp","PopperProps","title","TransitionComponentProp","isRtl","childNode","setChildNode","arrowRef","setArrowRef","ignoreNonTouchEvents","closeTimer","enterTimer","leaveTimer","touchTimer","setOpenState","prevUserSelect","stopTouchInteraction","handleOpen","handleClose","handleLeave","focusVisibleRef","setChildIsFocusVisible","handleBlur","handleFocus","detectTouchStart","childrenProps","handleMouseOver","handleMouseLeave","handleTouchStart","handleTouchEnd","nativeEvent","handleMouseMove","nameOrDescProps","titleIsString","interactiveWrapperListeners","_PopperProps$popperOp","tooltipModifiers","PopperComponent","TooltipComponent","ArrowComponent","popperProps","tooltipProps","tooltipArrowProps","TransitionPropsInner","Tooltip$1","getIcon","icon","menuLabel","leading","MuiListItemIcon","MenuItem","allowForLeadingIcons","iconPathBefore","iconPathAfter","hasAutoFocus","isDense","isSubMenuParent","hasDisabledGutters","hasDivider","focusVisibleClassName","menuItem","MuiMenuItem","MuiListItemText","getAllGroups","menuDefinition","SubMenu","setAnchorEl","parentMenuItem","parentItemProps","handleParentMenuItemClick","renderSubMenuItems","includedGroups","group","GroupedMenuItemList","Menu","getOrderedGroupItems","groupId","allItems","menuProps","commandHandler","groupsToInclude","sortedGroups","itemArray","allowSpaceForLeadingIcons","createMenuItemProps","isLastItemInGroup","divKey","itemInfo","menuItemProps","TopLevelMenu","columnId","MenuColumn","metadata","Grid","List","GridMenu","multiColumnMenu","sortedColumns","columnNumbers","columnName","col","getUsePromiseOptionsDefaults","usePromise","promiseFactoryCallback","defaultValueRef","optionsDefaultedRef","setIsLoading","promiseIsCurrent","MenuIcon","HamburgerMenuButton","menuProvider","normalMenu","fullMenu","containerRef","ariaLabelPrefix","isMenuOpen","setMenuOpen","showFullMenu","setShowFullMenu","handleMenuItemClick","handleMenuButtonClick","prevIsOpen","isOpening","menuCommandHandler","command","setOffset","normalMenuData","fullMenuData","menu","IconButton","Drawer","isTooltipSuppressed","adjustMarginToAlignToEdge","MuiIconButton","Spinner","LoaderCircle","TextField","hasError","helperText","onFocus","onBlur","ShadLabel","Toolbar","AppBar","MuiToolbar","alertVariants","Alert","AlertTitle","AlertDescription","Sonner","Toaster","Slider","SliderPrimitive","Switch","SwitchPrimitives","Tabs","TabsList","TabsTrigger","TabsContent","InstallButton","isInstalling","handleClick","buttonText","Download","EnableButton","isEnabling","DisableButton","isDisabling","UpdateButton","isUpdating","MarkdownRenderer","markdown","anchorTarget","Markdown","FilterButton","Filter","DropdownMenuItemType","DropdownMenuItemType2","FilterDropdown","groups","NoExtensionsFound","MoreInfo","category","downloads","languages","moreInfoUrl","numberFormatted","NumberFormat","handleScrollToBottom","User","locale","LucideLink","CircleHelp","VersionHistory","versionHistory","showAllVersions","setShowAllVersions","currentDate","formatTimeString","dateString","date","dateDiff","yearDiff","monthDiff","dayDiff","timeString","sortedEntries","Footer","publisherDisplayName","fileSize","locales","formattedFileSize","formatBytes","languageNames","codes","displayNames","useEvent","unsubscriber","noopUnsubscriber","useEventAsync","unsubscribe","unsub"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAGA,MAAMA,KAAgBC,GAAoB,EAAE,QAAQ,MAAO,CAAA;AAyDpD,SAASC,KAAMC,GAAsB;AACnC,SAAAH,GAAcI,GAAKD,CAAM,CAAC;AACnC;ACzDO,MAAME,KAAQC,EAAM;AAAA,EACzB,CAAC,EAAE,WAAAC,GAAW,MAAAC,GAAM,GAAGC,EAAA,GAASC,MAE5B,gBAAAC;AAAA,IAAC;AAAA,IAAA;AAAA,MACC,MAAAH;AAAA,MACA,WAAWN;AAAA,QACT;AAAA,QACAK;AAAA,MACF;AAAA,MACA,KAAAG;AAAA,MAEC,GAAGD;AAAA,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,EACA;AAAA,EACA;AACF,GAAGC,KAAI;AAAA,EACL;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AACF,GAAGC,KAAI;AAAA,EACL;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA;AAAA;AAAA,EAGA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,E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;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","x_google_ignoreList":[3,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,83,84,85,86,87,88,89,90,91,92,93,94,95,96,97,98,99,100,101,102,103,104,105,106,107,108,109,110,111,112,113,114,115,116,117,118,119,120,121,122,123,124,125,126,127,128,129,130,131,132,133,134,135,136,137,138,139,140,141,142,143,144,145,146,147,148,149,150,151,152,153,154,155,156,157,158,159,160,161,162,163,164,165,166,167,168,169,170,171,172,173,174,175,176,177,178,179,180,181,182,183,184,185,186,187,188,189,190,191,192,193,194,195,196,197,198,199,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,230]} \ No newline at end of file diff --git a/lib/platform-bible-react/src/components/advanced/settings-components/settings-card.component.tsx b/lib/platform-bible-react/src/components/advanced/settings-components/settings-card.component.tsx index 9ce28a9ee1..dbc66ffc72 100644 --- a/lib/platform-bible-react/src/components/advanced/settings-components/settings-card.component.tsx +++ b/lib/platform-bible-react/src/components/advanced/settings-components/settings-card.component.tsx @@ -1,5 +1,10 @@ -import { Card, CardDescription, CardHeader, CardTitle } from '@/components/shadcn-ui/card'; -import { CardContent } from '@mui/material'; +import { + Card, + CardDescription, + CardHeader, + CardTitle, + CardContent, +} from '@/components/shadcn-ui/card'; import { PropsWithChildren } from 'react'; type SettingsCardProps = PropsWithChildren & { @@ -25,7 +30,7 @@ export default function SettingsCard({ {settingsGroupLabel} {settingsGroupDescription && {settingsGroupDescription}} - {children} + {children} ); } diff --git a/lib/platform-bible-react/src/components/advanced/settings-components/settings-sidebar-content-search.component.tsx b/lib/platform-bible-react/src/components/advanced/settings-components/settings-sidebar-content-search.component.tsx index 868ac81b07..e418d3af1c 100644 --- a/lib/platform-bible-react/src/components/advanced/settings-components/settings-sidebar-content-search.component.tsx +++ b/lib/platform-bible-react/src/components/advanced/settings-components/settings-sidebar-content-search.component.tsx @@ -1,5 +1,6 @@ import { SidebarInset, SidebarProvider } from '@/components/shadcn-ui/sidebar'; import { PropsWithChildren } from 'react'; +import SearchBar from '@/components/basics/search-bar.component'; import SettingsSidebar, { SettingsSidebarProps } from './settings-sidebar.component'; export type SettingsSidebarContentSearchProps = SettingsSidebarProps & @@ -9,6 +10,9 @@ export type SettingsSidebarContentSearchProps = SettingsSidebarProps & /** Text direction ltr or rtl */ direction?: 'ltr' | 'rtl'; + + /** Handler to run when the value of the search bar changes */ + onSearch: (searchQuery: string) => void; }; export default function SettingsSidebarContentSearch({ @@ -19,16 +23,26 @@ export default function SettingsSidebarContentSearch({ children, handleSelectSidebarItem, selectedSidebarItem, + onSearch, }: SettingsSidebarContentSearchProps) { return ( - - - {children} - +
    +
    + +
    + + + {children} + +
    ); } diff --git a/lib/platform-bible-react/src/components/advanced/settings-components/settings-sidebar.component.tsx b/lib/platform-bible-react/src/components/advanced/settings-components/settings-sidebar.component.tsx index f96ada612f..1652119d9e 100644 --- a/lib/platform-bible-react/src/components/advanced/settings-components/settings-sidebar.component.tsx +++ b/lib/platform-bible-react/src/components/advanced/settings-components/settings-sidebar.component.tsx @@ -9,6 +9,7 @@ import { SidebarMenuItem, SidebarMenuButton, } from '@/components/shadcn-ui/sidebar'; +import { cn } from '@/utils/shadcn-ui.util'; import { useCallback } from 'react'; export type SelectedSettingsSidebarItem = { @@ -32,7 +33,7 @@ export type SettingsSidebarProps = { handleSelectSidebarItem: (key: string, projectId?: string) => void; /** The current selected value in the sidebar */ - selectedSidebarItem: SelectedSettingsSidebarItem | undefined; + selectedSidebarItem: SelectedSettingsSidebarItem; }; export default function SettingsSidebar({ @@ -57,22 +58,34 @@ export default function SettingsSidebar({ [projectOptions], ); + const getIsActive: (label: string) => boolean = useCallback( + (label: string) => !selectedSidebarItem.projectId && label === selectedSidebarItem.label, + [selectedSidebarItem], + ); + return ( - + - Extensions + Extensions {extensionLabels.map((label) => ( handleSelectItem(label)} - isActive={ - !selectedSidebarItem?.projectId && label === selectedSidebarItem?.label - } + className={cn( + 'tw-rounded tw-py-2 tw-text-sm tw-text-gray-500 hover:tw-bg-white hover:tw-text-gray-900 hover:tw-shadow-sm active:tw-bg-white', + { 'tw-bg-white tw-text-gray-900 tw-shadow-sm': getIsActive(label) }, + )} + onClick={() => handleSelectItem(label, undefined)} + isActive={getIsActive(label)} > - {label} + {label} ))} @@ -80,8 +93,8 @@ export default function SettingsSidebar({ - Projects - + Projects + option.projectId)} diff --git a/lib/platform-bible-react/src/components/basics/search-bar.component.tsx b/lib/platform-bible-react/src/components/basics/search-bar.component.tsx index 5ab104401c..40163aa5d1 100644 --- a/lib/platform-bible-react/src/components/basics/search-bar.component.tsx +++ b/lib/platform-bible-react/src/components/basics/search-bar.component.tsx @@ -3,6 +3,7 @@ import { cn } from '@/utils/shadcn-ui.util'; import { useState } from 'react'; export type SearchBarProps = { + className?: string; /** * Callback fired to handle the search query when button pressed * @@ -17,7 +18,12 @@ export type SearchBarProps = { isFullWidth?: boolean; }; -export default function SearchBar({ onSearch, placeholder, isFullWidth }: SearchBarProps) { +export default function SearchBar({ + className, + onSearch, + placeholder, + isFullWidth, +}: SearchBarProps) { const [searchQuery, setSearchQuery] = useState(''); const handleInputChange = (searchString: string) => { @@ -30,6 +36,7 @@ export default function SearchBar({ onSearch, placeholder, isFullWidth }: Search className={cn( 'tw-flex tw-h-10 tw-rounded-md tw-border tw-border-input tw-bg-background tw-px-3 tw-py-2 tw-text-sm tw-ring-offset-background file:tw-border-0 file:tw-bg-transparent file:tw-text-sm file:tw-font-medium placeholder:tw-text-muted-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-[color:hsl(240,5%,64.9%)] focus-visible:tw-ring-offset-2 disabled:tw-cursor-not-allowed disabled:tw-opacity-50', { 'tw-w-full': isFullWidth }, + className, )} placeholder={placeholder} value={searchQuery} diff --git a/lib/platform-bible-react/src/components/shadcn-ui/sidebar.tsx b/lib/platform-bible-react/src/components/shadcn-ui/sidebar.tsx index b3d1fd03db..4afc8f245d 100644 --- a/lib/platform-bible-react/src/components/shadcn-ui/sidebar.tsx +++ b/lib/platform-bible-react/src/components/shadcn-ui/sidebar.tsx @@ -135,7 +135,8 @@ const SidebarProvider = React.forwardRef< } as React.CSSProperties } className={cn( - 'tw-group/sidebar-wrapper pr-twp tw-flex tw-min-h-svh tw-w-full has-[[data-variant=inset]]:tw-bg-sidebar', + // Removed tw-min-h-svh + 'tw-group/sidebar-wrapper pr-twp tw-flex tw-w-full has-[[data-variant=inset]]:tw-bg-sidebar', className, )} ref={ref} @@ -316,7 +317,8 @@ const SidebarInset = React.forwardRefspan:last-child]:tw-truncate [&>svg]:tw-size-4 [&>svg]:tw-shrink-0', + // Removed data-[active=true]:tw-bg-sidebar-accent + 'tw-peer/menu-button tw-flex tw-w-full tw-items-center tw-gap-2 tw-overflow-hidden tw-rounded-md tw-p-2 tw-text-left tw-text-sm tw-outline-none tw-ring-sidebar-ring tw-transition-[width,height,padding] hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground focus-visible:tw-ring-2 active:tw-bg-sidebar-accent active:tw-text-sidebar-accent-foreground disabled:tw-pointer-events-none disabled:tw-opacity-50 tw-group-has-[[data-sidebar=menu-action]]/menu-item:pr-8 aria-disabled:tw-pointer-events-none aria-disabled:tw-opacity-50 data-[active=true]:tw-font-medium data-[active=true]:tw-text-sidebar-accent-foreground data-[state=open]:hover:tw-bg-sidebar-accent data-[state=open]:hover:tw-text-sidebar-accent-foreground group-data-[collapsible=icon]:tw-!size-8 group-data-[collapsible=icon]:tw-!p-2 [&>span:last-child]:tw-truncate [&>svg]:tw-size-4 [&>svg]:tw-shrink-0', { variants: { variant: { diff --git a/lib/platform-bible-react/src/preview/pages/components/basics.component.tsx b/lib/platform-bible-react/src/preview/pages/components/basics.component.tsx index dfb6857bb8..6dcfdb40cd 100644 --- a/lib/platform-bible-react/src/preview/pages/components/basics.component.tsx +++ b/lib/platform-bible-react/src/preview/pages/components/basics.component.tsx @@ -17,7 +17,7 @@ import DropdownExamples from './basics/dropdown.examples.component'; import InputExamples from './basics/input.examples.component'; import RadioGroupExamples from './basics/radio-group.examples'; import SelectExamples from './basics/select.examples.component'; -import SidebarExamples from './basics/sidebar.examples.component'; +import SettingsSidebarExamples from './basics/sidebar.examples.component'; import SliderExamples from './basics/slider.examples.component'; import SonnerExamples from './basics/sonner.examples.component'; import SpinnerExamples from './basics/spinner.examples.component'; @@ -105,7 +105,7 @@ function Basics({ direction }: HasDirection) {
    - +
    diff --git a/src/renderer/components/settings-tabs/settings-components/project-or-other-settings-list.component.tsx b/src/renderer/components/settings-tabs/settings-components/project-or-other-settings-list.component.tsx index d2d44f0390..e121a29550 100644 --- a/src/renderer/components/settings-tabs/settings-components/project-or-other-settings-list.component.tsx +++ b/src/renderer/components/settings-tabs/settings-components/project-or-other-settings-list.component.tsx @@ -48,7 +48,7 @@ export default function ProjectOrOtherSettingsList({ return ( -
    +
    {Object.entries(filteredSettingsProperties).map(([key, property]) => projectId ? ( { - let component =

    No setting component

    ; + let component =

    No setting component

    ; // isLoading ?

    Loading setting

    : if (typeof setting === 'string' || typeof setting === 'number') component = ( @@ -186,9 +184,9 @@ export default function Setting({ ); return ( -
    +
    {component} - {errorMessage &&
    {errorMessage}
    } + {errorMessage && }
    ); }, [setting, settingKey, debouncedHandleChange, errorMessage]); @@ -198,8 +196,10 @@ export default function Setting({ // const localizedLoadingSetting = localizedStrings[loadingSettingKey]; return ( -
    - +
    + {generateComponent()}
    ); diff --git a/src/renderer/components/settings-tabs/settings-tab.component.scss b/src/renderer/components/settings-tabs/settings-tab.component.scss index 93d88a49d4..4a6b06f3de 100644 --- a/src/renderer/components/settings-tabs/settings-tab.component.scss +++ b/src/renderer/components/settings-tabs/settings-tab.component.scss @@ -1,7 +1,6 @@ .settings-tab { - padding: 0 2% 2%; + padding: 2%; height: inherit; - overflow-y: auto; } .sidebar { diff --git a/src/renderer/components/settings-tabs/settings-tab.component.tsx b/src/renderer/components/settings-tabs/settings-tab.component.tsx index 7bd52d8b62..e8020195eb 100644 --- a/src/renderer/components/settings-tabs/settings-tab.component.tsx +++ b/src/renderer/components/settings-tabs/settings-tab.component.tsx @@ -13,17 +13,27 @@ import settingsService from '@shared/services/settings.service'; import './settings-tab.component.scss'; import projectLookupService from '@shared/services/project-lookup.service'; import { projectDataProviders } from '@renderer/services/papi-frontend.service'; +import { ProjectSettingsContributionInfo } from '@shared/utils/project-settings-document-combiner'; +import { Localized } from 'platform-bible-utils'; import ProjectOrOtherSettingsList from './settings-components/project-or-other-settings-list.component'; export const TAB_TYPE_SETTINGS_TAB = 'settings-tab'; type SettingsTabProps = { /** Optional project Id, when passed in, will only show settings for that project */ - projectId?: string; + projectIdToLimitSettings?: string; }; -export default function SettingsTab({ projectId }: SettingsTabProps) { - const [selectedSidebarItem, setSelectedSidebarItem] = useState(); +export default function SettingsTab({ projectIdToLimitSettings }: SettingsTabProps) { + const [selectedSidebarItem, setSelectedSidebarItem] = useState({ + label: '', + projectId: undefined, + }); + const [searchQuery, setSearchQuery] = useState(''); + + const handleSearchInput = (newSearchTerm: string) => { + setSearchQuery(newSearchTerm); + }; const [settingsContributions, isLoadingSettingsContributions] = usePromise( useCallback(async () => { @@ -38,6 +48,7 @@ export default function SettingsTab({ projectId }: SettingsTabProps) { ), ); + // Default selected item to the first settings tab setSelectedSidebarItem({ label: Object.keys(filteredContributions)[0], }); @@ -54,35 +65,35 @@ export default function SettingsTab({ projectId }: SettingsTabProps) { if (!contributions) return undefined; // Filter out the projects that do not have setting groups - const filteredContributions = Object.fromEntries( + return Object.fromEntries( Object.entries(contributions).filter( ([, projectSettingsGroups]) => Array.isArray(projectSettingsGroups) && projectSettingsGroups.length > 0, ), ); - - return filteredContributions; }, []), useMemo(() => { return undefined; }, []), ); - const [filteredProjectSettingsContributions] = usePromise( + const [filteredProjectSettingsContributions]: [ + Localized | undefined, + boolean, + ] = usePromise( useCallback(async () => { - if (!selectedSidebarItem || !selectedSidebarItem.projectId) return undefined; + if (!selectedSidebarItem.projectId) return undefined; const projectInterfacesFromProjectId = ( await projectLookupService.getMetadataForProject(selectedSidebarItem.projectId) ).projectInterfaces; - const filteredContributionsByInterface = - await filterProjectSettingsContributionsByProjectInterfaces( + return ( + filterProjectSettingsContributionsByProjectInterfaces( projectSettingsContributions, projectInterfacesFromProjectId, - ); - - return filteredContributionsByInterface; + ) || {} + ); }, [projectSettingsContributions, selectedSidebarItem]), useMemo(() => undefined, []), ); @@ -132,24 +143,39 @@ export default function SettingsTab({ projectId }: SettingsTabProps) { if (isLoadingSettingsContributions || isLoadingProjectSettingsContributions) return
    Loading Settings
    ; - // TODO: fix - if (projectId && filteredProjectSettingsContributions) { + const renderProjectSettingsList = ( + contributions: Localized, + projectId: string, + ) => { + if (!contributions) return undefined; + + return Object.entries(contributions).map(([, settingsGroups]) => + settingsGroups + ? Object.entries(settingsGroups).map(([, settingsGroup]) => ( + + )) + : undefined, + ); + }; + + if (projectIdToLimitSettings) { + // setSelectedSidebarItem({ label: '', projectId: projectIdToLimitSettings }); + return (
    - {Object.entries(filteredProjectSettingsContributions).map( - ([, settingsGroups]) => - settingsGroups && - Object.entries(settingsGroups).map(([, settingsGroup]) => ( - - )), - )} + {filteredProjectSettingsContributions + ? renderProjectSettingsList( + filteredProjectSettingsContributions, + projectIdToLimitSettings, + ) + : 'No settings'}
    ); } @@ -164,25 +190,15 @@ export default function SettingsTab({ projectId }: SettingsTabProps) { setSelectedSidebarItem({ label: key, projectId: projId }) } selectedSidebarItem={selectedSidebarItem} + onSearch={handleSearchInput} > - {/* eslint-disable-next-line no-nested-ternary */} - {selectedSidebarItem?.projectId && filteredProjectSettingsContributions - ? Object.entries(filteredProjectSettingsContributions).map( - ([, settingsGroups]) => - settingsGroups && - Object.entries(settingsGroups).map(([, settingsGroup]) => ( - - )), - ) - : selectedSidebarItem?.label && settingsContributions - ? settingsContributions[selectedSidebarItem.label]?.map((group) => ( +
    + {selectedSidebarItem.projectId && filteredProjectSettingsContributions + ? renderProjectSettingsList( + filteredProjectSettingsContributions, + selectedSidebarItem.projectId, + ) + : settingsContributions[selectedSidebarItem.label]?.map((group) => ( - )) - : undefined} + ))} +
    @@ -206,11 +222,11 @@ export const loadSettingsTab = (savedTabInfo: SavedTabInfo): TabInfo => { const tabData: SettingsTabData = savedTabInfo.data as SettingsTabData; // TODO project name in title ? - const title = tabData.projectId ? 'Project Settings' : 'Settings'; + const title = tabData.projectIdToLimitSettings ? 'Project Settings' : 'Settings'; return { ...savedTabInfo, tabTitle: title, - content: , + content: , }; }; From ee96ff830c875997624b9cf9c9ab03486ef1ec16 Mon Sep 17 00:00:00 2001 From: Jolie Rabideau Date: Mon, 25 Nov 2024 20:12:56 -0500 Subject: [PATCH 04/18] Fix opening one project's settings, resize window, remove unnecessary component, attempt to fix scrolling --- lib/papi-dts/papi.d.ts | 3 +- lib/platform-bible-react/dist/index.cjs | 66 +- lib/platform-bible-react/dist/index.cjs.map | 2 +- lib/platform-bible-react/dist/index.d.ts | 9 - lib/platform-bible-react/dist/index.js | 2191 ++++++++--------- lib/platform-bible-react/dist/index.js.map | 2 +- .../settings-card.component.tsx | 36 - ...tings-sidebar-content-search.component.tsx | 4 +- lib/platform-bible-react/src/index.ts | 1 - src/declarations/papi-shared-types.ts | 3 +- src/extension-host/data/menu.data.json | 7 + ...oject-or-other-settings-list.component.tsx | 72 +- .../settings-tabs/settings-tab.component.scss | 12 + .../settings-tabs/settings-tab.component.tsx | 93 +- .../services/web-view.service-host.ts | 4 +- 15 files changed, 1225 insertions(+), 1280 deletions(-) delete mode 100644 lib/platform-bible-react/src/components/advanced/settings-components/settings-card.component.tsx diff --git a/lib/papi-dts/papi.d.ts b/lib/papi-dts/papi.d.ts index b48f6b1d84..892dedb38c 100644 --- a/lib/papi-dts/papi.d.ts +++ b/lib/papi-dts/papi.d.ts @@ -2868,6 +2868,7 @@ declare module 'papi-shared-types' { import type IDataProvider from 'shared/models/data-provider.interface'; import type ExtractDataProviderDataTypes from 'shared/models/extract-data-provider-data-types.model'; import type { NetworkableObject } from 'shared/models/network-object.model'; + import { WebViewId } from 'shared/models/web-view.model'; /** * Function types for each command available on the papi. Each extension can extend this interface * to add commands that it registers on the papi with `papi.commands.registerCommand`. @@ -2898,7 +2899,7 @@ declare module 'papi-shared-types' { 'platform.quit': () => Promise; /** Restart the application */ 'platform.restart': () => Promise; - 'platform.openSettings': (webViewId?: string) => Promise; + 'platform.openSettings': (webViewId?: WebViewId) => Promise; 'test.addMany': (...nums: number[]) => number; 'test.throwErrorExtensionHost': (message: string) => void; } diff --git a/lib/platform-bible-react/dist/index.cjs b/lib/platform-bible-react/dist/index.cjs index af2af2c6c9..d7659007e5 100644 --- a/lib/platform-bible-react/dist/index.cjs +++ b/lib/platform-bible-react/dist/index.cjs @@ -1,23 +1,23 @@ -"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const a=require("react/jsx-runtime"),g=require("react"),Q=require("lucide-react"),ot=require("clsx"),ml=require("tailwind-merge"),rs=require("@radix-ui/react-dropdown-menu"),W=require("platform-bible-utils"),Ht=require("@radix-ui/react-slot"),Xt=require("class-variance-authority"),hl=require("@radix-ui/react-label"),gl=require("@radix-ui/react-radio-group"),bl=require("@radix-ui/react-popover"),Re=require("cmdk"),vl=require("@radix-ui/react-dialog"),Se=require("@tanstack/react-table"),xl=require("@radix-ui/react-select"),yl=require("@radix-ui/react-checkbox"),Nl=require("@radix-ui/react-toggle-group"),kl=require("@radix-ui/react-toggle"),Sl=require("@radix-ui/react-tabs"),El=require("@radix-ui/react-separator"),jl=require("@radix-ui/react-tooltip"),Gr=require("@mui/styled-engine"),Me=require("@mui/material"),ln=require("react-dom"),os=require("sonner"),Cl=require("@radix-ui/react-slider"),Tl=require("@radix-ui/react-switch"),Rl=require("markdown-to-jsx");function ke(e){const t=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(e){for(const n in e)if(n!=="default"){const r=Object.getOwnPropertyDescriptor(e,n);Object.defineProperty(t,n,r.get?r:{enumerable:!0,get:()=>e[n]})}}return t.default=e,Object.freeze(t)}const M=ke(g),pe=ke(rs),as=ke(hl),bn=ke(gl),vn=ke(bl),be=ke(vl),ge=ke(xl),Ur=ke(yl),rr=ke(Nl),ss=ke(kl),Oe=ke(Sl),is=ke(El),Sn=ke(jl),Ol=ke(ln),cn=ke(Cl),qr=ke(Tl);const _l=ml.extendTailwindMerge({prefix:"tw-"});function N(...e){return _l(ot.clsx(e))}const St=g.forwardRef(({className:e,type:t,...n},r)=>a.jsx("input",{type:t,className:N("pr-twp tw-flex tw-h-10 tw-rounded-md tw-border tw-border-input tw-bg-background tw-px-3 tw-py-2 tw-text-sm tw-ring-offset-background file:tw-border-0 file:tw-bg-transparent file:tw-text-sm file:tw-font-medium file:tw-text-foreground placeholder:tw-text-muted-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-cursor-not-allowed disabled:tw-opacity-50",e),ref:r,...n}));St.displayName="Input";const Pl=g.forwardRef(({handleSearch:e,handleKeyDown:t,handleOnClick:n,handleSubmit:r,...o},s)=>a.jsxs("div",{className:"tw-relative",children:[a.jsx(St,{...o,type:"text",className:"tw-box-border tw-gap-2.5 tw-rounded-lg tw-border tw-border-solid tw-bg-background tw-py-2 tw-pl-4 tw-pr-3 tw-font-medium tw-shadow-none tw-outline-none",onChange:i=>e(i.target.value),onKeyDown:i=>{i.key==="Enter"&&r(),t(i)},onClick:n,ref:s}),a.jsx(Q.History,{className:"tw-absolute tw-right-3 tw-top-1/2 tw-h-4 tw-w-4 tw--translate-y-1/2 tw-transform tw-cursor-pointer tw-text-muted-foreground",onClick:()=>{console.log("back in history")}})]}));var Il=Object.defineProperty,Ml=(e,t,n)=>t in e?Il(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,ne=(e,t,n)=>Ml(e,typeof t!="symbol"?t+"":t,n);const gt=["GEN","EXO","LEV","NUM","DEU","JOS","JDG","RUT","1SA","2SA","1KI","2KI","1CH","2CH","EZR","NEH","EST","JOB","PSA","PRO","ECC","SNG","ISA","JER","LAM","EZK","DAN","HOS","JOL","AMO","OBA","JON","MIC","NAM","HAB","ZEP","HAG","ZEC","MAL","MAT","MRK","LUK","JHN","ACT","ROM","1CO","2CO","GAL","EPH","PHP","COL","1TH","2TH","1TI","2TI","TIT","PHM","HEB","JAS","1PE","2PE","1JN","2JN","3JN","JUD","REV","TOB","JDT","ESG","WIS","SIR","BAR","LJE","S3Y","SUS","BEL","1MA","2MA","3MA","4MA","1ES","2ES","MAN","PS2","ODA","PSS","JSA","JDB","TBS","SST","DNT","BLT","XXA","XXB","XXC","XXD","XXE","XXF","XXG","FRT","BAK","OTH","3ES","EZA","5EZ","6EZ","INT","CNC","GLO","TDX","NDX","DAG","PS3","2BA","LBA","JUB","ENO","1MQ","2MQ","3MQ","REP","4BA","LAO"],ao=["XXA","XXB","XXC","XXD","XXE","XXF","XXG","FRT","BAK","OTH","INT","CNC","GLO","TDX","NDX"],ls=["Genesis","Exodus","Leviticus","Numbers","Deuteronomy","Joshua","Judges","Ruth","1 Samuel","2 Samuel","1 Kings","2 Kings","1 Chronicles","2 Chronicles","Ezra","Nehemiah","Esther (Hebrew)","Job","Psalms","Proverbs","Ecclesiastes","Song of Songs","Isaiah","Jeremiah","Lamentations","Ezekiel","Daniel (Hebrew)","Hosea","Joel","Amos","Obadiah","Jonah","Micah","Nahum","Habakkuk","Zephaniah","Haggai","Zechariah","Malachi","Matthew","Mark","Luke","John","Acts","Romans","1 Corinthians","2 Corinthians","Galatians","Ephesians","Philippians","Colossians","1 Thessalonians","2 Thessalonians","1 Timothy","2 Timothy","Titus","Philemon","Hebrews","James","1 Peter","2 Peter","1 John","2 John","3 John","Jude","Revelation","Tobit","Judith","Esther Greek","Wisdom of Solomon","Sirach (Ecclesiasticus)","Baruch","Letter of Jeremiah","Song of 3 Young Men","Susanna","Bel and the Dragon","1 Maccabees","2 Maccabees","3 Maccabees","4 Maccabees","1 Esdras (Greek)","2 Esdras (Latin)","Prayer of Manasseh","Psalm 151","Odes","Psalms of Solomon","Joshua A. *obsolete*","Judges B. *obsolete*","Tobit S. *obsolete*","Susanna Th. *obsolete*","Daniel Th. *obsolete*","Bel Th. *obsolete*","Extra A","Extra B","Extra C","Extra D","Extra E","Extra F","Extra G","Front Matter","Back Matter","Other Matter","3 Ezra *obsolete*","Apocalypse of Ezra","5 Ezra (Latin Prologue)","6 Ezra (Latin Epilogue)","Introduction","Concordance ","Glossary ","Topical Index","Names Index","Daniel Greek","Psalms 152-155","2 Baruch (Apocalypse)","Letter of Baruch","Jubilees","Enoch","1 Meqabyan","2 Meqabyan","3 Meqabyan","Reproof (Proverbs 25-31)","4 Baruch (Rest of Baruch)","Laodiceans"],la=Ul();function Yt(e,t=!0){return t&&(e=e.toUpperCase()),e in la?la[e]:0}function so(e){return Yt(e)>0}function $l(e){const t=typeof e=="string"?Yt(e):e;return t>=40&&t<=66}function Al(e){return(typeof e=="string"?Yt(e):e)<=39}function cs(e){return e<=66}function Dl(e){const t=typeof e=="string"?Yt(e):e;return ps(t)&&!cs(t)}function*Bl(){for(let e=1;e<=gt.length;e++)yield e}const Vl=1,ds=gt.length;function zl(){return["XXA","XXB","XXC","XXD","XXE","XXF","XXG"]}function io(e,t="***"){const n=e-1;return n<0||n>=gt.length?t:gt[n]}function us(e){return e<=0||e>ds?"******":ls[e-1]}function Ll(e){return us(Yt(e))}function ps(e){const t=typeof e=="number"?io(e):e;return so(t)&&!ao.includes(t)}function Fl(e){const t=typeof e=="number"?io(e):e;return so(t)&&ao.includes(t)}function Gl(e){return ls[e-1].includes("*obsolete*")}function Ul(){const e={};for(let t=0;t(e[e.Unknown=0]="Unknown",e[e.Original=1]="Original",e[e.Septuagint=2]="Septuagint",e[e.Vulgate=3]="Vulgate",e[e.English=4]="English",e[e.RussianProtestant=5]="RussianProtestant",e[e.RussianOrthodox=6]="RussianOrthodox",e))(He||{});const Pe=class{constructor(t){if(ne(this,"name"),ne(this,"fullPath"),ne(this,"isPresent"),ne(this,"hasVerseSegments"),ne(this,"isCustomized"),ne(this,"baseVersification"),ne(this,"scriptureBooks"),ne(this,"_type"),t==null)throw new Error("Argument undefined");typeof t=="string"?(this.name=t,this._type=He[t]):(this._type=t,this.name=He[t])}get type(){return this._type}equals(t){return!t.type||!this.type?!1:t.type===this.type}};ne(Pe,"Original",new Pe(He.Original)),ne(Pe,"Septuagint",new Pe(He.Septuagint)),ne(Pe,"Vulgate",new Pe(He.Vulgate)),ne(Pe,"English",new Pe(He.English)),ne(Pe,"RussianProtestant",new Pe(He.RussianProtestant)),ne(Pe,"RussianOrthodox",new Pe(He.RussianOrthodox));let ut=Pe;function ca(e,t){const n=t[0];for(let r=1;r(e[e.Valid=0]="Valid",e[e.UnknownVersification=1]="UnknownVersification",e[e.OutOfRange=2]="OutOfRange",e[e.VerseOutOfOrder=3]="VerseOutOfOrder",e[e.VerseRepeated=4]="VerseRepeated",e))(ws||{});const je=class re{constructor(t,n,r,o){if(ne(this,"firstChapter"),ne(this,"lastChapter"),ne(this,"lastVerse"),ne(this,"hasSegmentsDefined"),ne(this,"text"),ne(this,"BBBCCCVVVS"),ne(this,"longHashCode"),ne(this,"versification"),ne(this,"rtlMark","‏"),ne(this,"_bookNum",0),ne(this,"_chapterNum",0),ne(this,"_verseNum",0),ne(this,"_verse"),r==null&&o==null)if(t!=null&&typeof t=="string"){const s=t,i=n!=null&&n instanceof ut?n:void 0;this.setEmpty(i),this.parse(s)}else if(t!=null&&typeof t=="number"){const s=n!=null&&n instanceof ut?n:void 0;this.setEmpty(s),this._verseNum=t%re.chapterDigitShifter,this._chapterNum=Math.floor(t%re.bookDigitShifter/re.chapterDigitShifter),this._bookNum=Math.floor(t/re.bookDigitShifter)}else if(n==null)if(t!=null&&t instanceof re){const s=t;this._bookNum=s.bookNum,this._chapterNum=s.chapterNum,this._verseNum=s.verseNum,this._verse=s.verse,this.versification=s.versification}else{if(t==null)return;const s=t instanceof ut?t:re.defaultVersification;this.setEmpty(s)}else throw new Error("VerseRef constructor not supported.");else if(t!=null&&n!=null&&r!=null)if(typeof t=="string"&&typeof n=="string"&&typeof r=="string")this.setEmpty(o),this.updateInternal(t,n,r);else if(typeof t=="number"&&typeof n=="number"&&typeof r=="number")this._bookNum=t,this._chapterNum=n,this._verseNum=r,this.versification=o??re.defaultVersification;else throw new Error("VerseRef constructor not supported.");else throw new Error("VerseRef constructor not supported.")}static isVerseParseable(t){return t.length>0&&"0123456789".includes(t[0])&&!t.endsWith(this.verseRangeSeparator)&&!t.endsWith(this.verseSequenceIndicator)}static tryParse(t){let n;try{return n=new re(t),{success:!0,verseRef:n}}catch(r){if(r instanceof nn)return n=new re,{success:!1,verseRef:n};throw r}}static getBBBCCCVVV(t,n,r){return t%re.bcvMaxValue*re.bookDigitShifter+(n>=0?n%re.bcvMaxValue*re.chapterDigitShifter:0)+(r>=0?r%re.bcvMaxValue:0)}static fromJSON(t){const{book:n,chapterNum:r,verseNum:o,verse:s,versificationStr:i}=t,l=s||o.toString();let c;return i&&(c=new ut(i)),n?new re(n,r.toString(),l,c):new re}static tryGetVerseNum(t){let n;if(!t)return n=-1,{success:!0,vNum:n};n=0;let r;for(let o=0;o"9")return o===0&&(n=-1),{success:!1,vNum:n};if(n=n*10+ +r-0,n>re.bcvMaxValue)return n=-1,{success:!1,vNum:n}}return{success:!0,vNum:n}}get isDefault(){return this.bookNum===0&&this.chapterNum===0&&this.verseNum===0&&this.versification==null}get hasMultiple(){return this._verse!=null&&(this._verse.includes(re.verseRangeSeparator)||this._verse.includes(re.verseSequenceIndicator))}get book(){return ae.bookNumberToId(this.bookNum,"")}set book(t){this.bookNum=ae.bookIdToNumber(t)}get chapter(){return this.isDefault||this._chapterNum<0?"":this._chapterNum.toString()}set chapter(t){const n=+t;this._chapterNum=Number.isInteger(n)?n:-1}get verse(){return this._verse!=null?this._verse:this.isDefault||this._verseNum<0?"":this._verseNum.toString()}set verse(t){const{success:n,vNum:r}=re.tryGetVerseNum(t);this._verse=n?void 0:t.replace(this.rtlMark,""),this._verseNum=r,!(this._verseNum>=0)&&({vNum:this._verseNum}=re.tryGetVerseNum(this._verse))}get bookNum(){return this._bookNum}set bookNum(t){if(t<=0||t>ae.lastBook)throw new nn("BookNum must be greater than zero and less than or equal to last book");this._bookNum=t}get chapterNum(){return this._chapterNum}set chapterNum(t){this.chapterNum=t}get verseNum(){return this._verseNum}set verseNum(t){this._verseNum=t}get versificationStr(){var t;return(t=this.versification)==null?void 0:t.name}set versificationStr(t){this.versification=this.versification!=null?new ut(t):void 0}get valid(){return this.validStatus===0}get validStatus(){return this.validateVerse(re.verseRangeSeparators,re.verseSequenceIndicators)}get BBBCCC(){return re.getBBBCCCVVV(this._bookNum,this._chapterNum,0)}get BBBCCCVVV(){return re.getBBBCCCVVV(this._bookNum,this._chapterNum,this._verseNum)}get isExcluded(){return!1}parse(t){if(t=t.replace(this.rtlMark,""),t.includes("/")){const s=t.split("/");if(t=s[0],s.length>1)try{const i=+s[1].trim();this.versification=new ut(He[i])}catch{throw new nn("Invalid reference : "+t)}}const n=t.trim().split(" ");if(n.length!==2)throw new nn("Invalid reference : "+t);const r=n[1].split(":"),o=+r[0];if(r.length!==2||ae.bookIdToNumber(n[0])===0||!Number.isInteger(o)||o<0||!re.isVerseParseable(r[1]))throw new nn("Invalid reference : "+t);this.updateInternal(n[0],r[0],r[1])}simplify(){this._verse=void 0}clone(){return new re(this)}toString(){const t=this.book;return t===""?"":`${t} ${this.chapter}:${this.verse}`}toJSON(){let t=this.verse;(t===""||t===this.verseNum.toString())&&(t=void 0);const n={book:this.book,chapterNum:this.chapterNum,verseNum:this.verseNum,verse:t,versificationStr:this.versificationStr};return t||delete n.verse,n}equals(t){return t instanceof re?t._bookNum===this._bookNum&&t._chapterNum===this._chapterNum&&t._verseNum===this._verseNum&&t.verse===this.verse&&(t.versification==null&&this.versification==null||t.versification!=null&&this.versification!=null&&t.versification.equals(this.versification)):!1}allVerses(t=!1,n=re.verseRangeSeparators,r=re.verseSequenceIndicators){if(this._verse==null||this.chapterNum<=0)return[this.clone()];const o=[],s=ca(this._verse,r);for(const i of s.map(l=>ca(l,n))){const l=this.clone();l.verse=i[0];const c=l.verseNum;if(o.push(l),i.length>1){const d=this.clone();if(d.verse=i[1],!t)for(let u=c+1;ui)return 3;if(r===i)return 4;r=i}return 0}get internalValid(){return this.versification==null?1:this._bookNum<=0||this._bookNum>ae.lastBook?2:(ae.isCanonical(this._bookNum),0)}setEmpty(t=re.defaultVersification){this._bookNum=0,this._chapterNum=-1,this._verse=void 0,this.versification=t}updateInternal(t,n,r){this.bookNum=ae.bookIdToNumber(t),this.chapter=n,this.verse=r}};ne(je,"defaultVersification",ut.English),ne(je,"verseRangeSeparator","-"),ne(je,"verseSequenceIndicator",","),ne(je,"verseRangeSeparators",[je.verseRangeSeparator]),ne(je,"verseSequenceIndicators",[je.verseSequenceIndicator]),ne(je,"chapterDigitShifter",1e3),ne(je,"bookDigitShifter",je.chapterDigitShifter*je.chapterDigitShifter),ne(je,"bcvMaxValue",je.chapterDigitShifter-1),ne(je,"ValidStatusType",ws);class nn extends Error{}const or=pe.Root,lo=pe.Trigger,fs=pe.Group,ql=pe.Portal,Hl=pe.Sub,Xl=pe.RadioGroup,ms=g.forwardRef(({className:e,inset:t,children:n,...r},o)=>a.jsxs(pe.SubTrigger,{ref:o,className:N("tw-flex tw-cursor-default tw-select-none tw-items-center tw-rounded-sm tw-px-2 tw-py-1.5 tw-text-sm tw-outline-none focus:tw-bg-accent data-[state=open]:tw-bg-accent",t&&"tw-pl-8",e),...r,children:[n,a.jsx(Q.ChevronRight,{className:"tw-ml-auto tw-h-4 tw-w-4"})]}));ms.displayName=pe.SubTrigger.displayName;const hs=g.forwardRef(({className:e,...t},n)=>a.jsx(pe.SubContent,{ref:n,className:N("tw-z-50 tw-min-w-[8rem] tw-overflow-hidden tw-rounded-md tw-border tw-bg-popover tw-p-1 tw-text-popover-foreground tw-shadow-lg data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0 data-[state=closed]:tw-zoom-out-95 data-[state=open]:tw-zoom-in-95 data-[side=bottom]:tw-slide-in-from-top-2 data-[side=left]:tw-slide-in-from-right-2 data-[side=right]:tw-slide-in-from-left-2 data-[side=top]:tw-slide-in-from-bottom-2",e),...t}));hs.displayName=pe.SubContent.displayName;const En=g.forwardRef(({className:e,sideOffset:t=4,...n},r)=>a.jsx(pe.Portal,{children:a.jsx(pe.Content,{ref:r,sideOffset:t,className:N("pr-twp tw-z-50 tw-min-w-[8rem] tw-overflow-hidden tw-rounded-md tw-border tw-bg-popover tw-p-1 tw-text-popover-foreground tw-shadow-md data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0 data-[state=closed]:tw-zoom-out-95 data-[state=open]:tw-zoom-in-95 data-[side=bottom]:tw-slide-in-from-top-2 data-[side=left]:tw-slide-in-from-right-2 data-[side=right]:tw-slide-in-from-left-2 data-[side=top]:tw-slide-in-from-bottom-2",e),...n})}));En.displayName=pe.Content.displayName;const co=g.forwardRef(({className:e,inset:t,...n},r)=>a.jsx(pe.Item,{ref:r,className:N("tw-cursor-default tw-select-none tw-items-center tw-rounded-sm tw-px-2 tw-py-1.5 tw-text-sm tw-outline-none tw-transition-colors focus:tw-bg-accent data-[disabled]:tw-pointer-events-none data-[disabled]:tw-opacity-50",t&&"tw-pl-8",e),...n}));co.displayName=pe.Item.displayName;const ar=g.forwardRef(({className:e,children:t,checked:n,...r},o)=>a.jsxs(pe.CheckboxItem,{ref:o,className:N("tw-relative tw-flex tw-cursor-default tw-select-none tw-items-center tw-rounded-sm tw-py-1.5 tw-pl-8 tw-pr-2 tw-text-sm tw-outline-none tw-transition-colors focus:tw-bg-accent focus:tw-text-accent-foreground data-[disabled]:tw-pointer-events-none data-[disabled]:tw-opacity-50",e),checked:n,...r,children:[a.jsx("span",{className:"tw-absolute tw-left-2 tw-flex tw-h-3.5 tw-w-3.5 tw-items-center tw-justify-center",children:a.jsx(pe.ItemIndicator,{children:a.jsx(Q.Check,{className:"tw-h-4 tw-w-4"})})}),t]}));ar.displayName=pe.CheckboxItem.displayName;const uo=g.forwardRef(({className:e,children:t,...n},r)=>a.jsxs(pe.RadioItem,{ref:r,className:N("tw-relative tw-flex tw-cursor-default tw-select-none tw-items-center tw-rounded-sm tw-py-1.5 tw-pl-8 tw-pr-2 tw-text-sm tw-outline-none tw-transition-colors focus:tw-bg-accent focus:tw-text-accent-foreground data-[disabled]:tw-pointer-events-none data-[disabled]:tw-opacity-50",e),...n,children:[a.jsx("span",{className:"tw-absolute tw-left-2 tw-flex tw-h-3.5 tw-w-3.5 tw-items-center tw-justify-center",children:a.jsx(pe.ItemIndicator,{children:a.jsx(Q.Circle,{className:"tw-h-2 tw-w-2 tw-fill-current"})})}),t]}));uo.displayName=pe.RadioItem.displayName;const Wt=g.forwardRef(({className:e,inset:t,...n},r)=>a.jsx(pe.Label,{ref:r,className:N("tw-px-2 tw-py-1.5 tw-text-sm tw-font-semibold",t&&"tw-pl-8",e),...n}));Wt.displayName=pe.Label.displayName;const jn=g.forwardRef(({className:e,...t},n)=>a.jsx(pe.Separator,{ref:n,className:N("tw--mx-1 tw-my-1 tw-h-px tw-bg-muted",e),...t}));jn.displayName=pe.Separator.displayName;function gs({className:e,...t}){return a.jsx("span",{className:N("tw-ml-auto tw-text-xs tw-tracking-widest tw-opacity-60",e),...t})}gs.displayName="DropdownMenuShortcut";const Yl=g.forwardRef(({bookId:e,handleSelectBook:t,isSelected:n,handleHighlightBook:r,handleKeyDown:o,bookType:s,children:i},l)=>a.jsxs(co,{ref:l,textValue:e,className:N("tw-mx-1 tw-px-1 tw-font-normal tw-text-foreground/80",{"tw-bg-amber-50 tw-text-yellow-900 data-[highlighted]:tw-bg-amber-100":n}),onSelect:c=>{c.preventDefault(),t()},onKeyDown:c=>{o(c)},onFocus:r,onMouseMove:r,children:[a.jsx("span",{className:N("tw-border-b-0 tw-border-l-2 tw-border-r-0 tw-border-t-0 tw-border-solid tw-px-2",{"tw-font-bold":n,"tw-border-l-red-200":s.toLowerCase()==="ot","tw-border-l-purple-200":s.toLowerCase()==="nt","tw-border-l-indigo-200":s.toLowerCase()==="dc"}),children:ae.bookIdToEnglishName(e)}),n&&a.jsx("div",{children:i})]},e));function Wl({handleSelectChapter:e,endChapter:t,activeChapter:n,highlightedChapter:r,handleHighlightedChapter:o}){const s=Array.from({length:t},(l,c)=>c+1),i=g.useCallback(l=>{o(l)},[o]);return a.jsx("div",{className:N("tw-flex tw-flex-wrap tw-items-start tw-justify-start tw-self-stretch"),children:s.map(l=>a.jsx("div",{className:N("tw-box-content tw-flex tw-h-4 tw-w-4 tw-cursor-pointer tw-items-center tw-justify-end tw-rounded-md tw-p-2 tw-text-amber-800",{"tw-font-semibold tw-text-amber-900":l===n,"tw-bg-amber-200":l===r}),onClick:c=>{c.preventDefault(),c.stopPropagation(),e(l)},role:"button",onKeyDown:c=>{c.key==="Enter"&&e(l)},tabIndex:0,onMouseMove:()=>i(l),children:l},l))})}function Kl({handleSort:e,handleLocationHistory:t,handleBookmarks:n}){return a.jsxs(Wt,{className:"tw-flex tw-justify-between",children:[a.jsx("p",{className:"tw-inline-block tw-align-middle",children:"Go To"}),a.jsxs("div",{className:"tw-flex tw-items-center",children:[a.jsx(Q.ArrowDownWideNarrow,{onClick:e,className:"tw-m-2 tw-h-4 tw-w-4 tw-cursor-pointer tw-gap-2"}),a.jsx(Q.Clock,{onClick:t,className:"tw-m-2 tw-h-4 tw-w-4 tw-cursor-pointer tw-gap-2"}),a.jsx(Q.Bookmark,{onClick:n,className:"tw-m-2 tw-h-4 tw-w-4 tw-cursor-pointer tw-gap-2"})]})]})}const wn=ae.allBookIds,Jl={OT:"Old Testament",NT:"New Testament",DC:"Deuterocanon"},da=["OT","NT","DC"],Zl=32+32+32,Ql=[/^(\w+)$/i,/^(\w+)(?:\s(\d+))$/i,/^(\w+)(?:\s(\d+):(\d+))$/i],ec=e=>({OT:wn.filter(n=>ae.isBookOT(n)),NT:wn.filter(n=>ae.isBookNT(n)),DC:wn.filter(n=>ae.isBookDC(n))})[e],rn=e=>W.getChaptersForBook(ae.bookIdToNumber(e));function tc(){return wn.map(t=>ae.bookIdToEnglishName(t))}function nc(e){return tc().includes(e)}function rc(e){const t=e.toLowerCase().replace(/^\w/,n=>n.toUpperCase());if(nc(t))return wn.find(r=>ae.bookIdToEnglishName(r)===t)}function oc({scrRef:e,handleSubmit:t}){const[n,r]=g.useState(""),[o,s]=g.useState(ae.bookNumberToId(e.bookNum)),[i,l]=g.useState(e.chapterNum??0),[c,d]=g.useState(ae.bookNumberToId(e.bookNum)),[u,h]=g.useState(!1),[w,b]=g.useState(u),x=g.useRef(void 0),f=g.useRef(void 0),m=g.useRef(void 0),S=g.useCallback(k=>ec(k).filter(A=>{const $=ae.bookIdToEnglishName(A).toLowerCase(),J=n.replace(/[^a-zA-Z]/g,"").toLowerCase();return $.includes(J)||A.toLowerCase().includes(J)}),[n]),R=k=>{r(k)},j=g.useRef(!1),E=g.useCallback(k=>{if(j.current){j.current=!1;return}h(k)},[]),v=g.useCallback((k,A,$,J)=>{if(l(ae.bookNumberToId(e.bookNum)!==k?1:e.chapterNum),A||rn(k)===-1){t({bookNum:ae.bookIdToNumber(k),chapterNum:$||1,verseNum:J||1}),h(!1),r("");return}s(o!==k?k:""),h(!A)},[t,e.bookNum,e.chapterNum,o]),P=k=>{k<=0||k>rn(o)||v(o,!0,k)},V=g.useCallback(()=>{Ql.forEach(k=>{const A=n.match(k);if(A){const[$,J=void 0,Y=void 0]=A.slice(1),F=rc($);(ae.isBookIdValid($)||F)&&v(F??$,!0,J?parseInt(J,10):1,Y?parseInt(Y,10):1)}})},[v,n]),U=g.useCallback(k=>{u?(k.key==="ArrowDown"||k.key==="ArrowUp")&&(typeof m<"u"&&m.current!==null?m.current.focus():typeof f<"u"&&f.current!==null&&f.current.focus(),k.preventDefault()):h(!0)},[u]),C=k=>{const{key:A}=k;A==="ArrowRight"||A==="ArrowLeft"||A==="ArrowDown"||A==="ArrowUp"||A==="Enter"||(x.current.dispatchEvent(new KeyboardEvent("keydown",{key:A})),x.current.focus())},_=k=>{const{key:A}=k;if(c===o){if(A==="Enter"){k.preventDefault(),v(o,!0,i);return}let $=0;if(A==="ArrowRight")if(i1)$=-1;else{k.preventDefault();return}else A==="ArrowDown"?$=6:A==="ArrowUp"&&($=-6);i+$<=0||i+$>rn(c)?l(0):$!==0&&(l(i+$),k.preventDefault())}};return g.useEffect(()=>{o===c?o===ae.bookNumberToId(e.bookNum)?l(e.chapterNum):l(1):l(0)},[c,e.bookNum,e.chapterNum,o]),g.useLayoutEffect(()=>{b(u)},[u]),g.useLayoutEffect(()=>{const k=setTimeout(()=>{if(w&&f.current&&m.current){const $=m.current.offsetTop-Zl;f.current.scrollTo({top:$,behavior:"instant"})}},10);return()=>{clearTimeout(k)}},[w]),a.jsx("div",{className:"pr-twp tw-flex",children:a.jsxs(or,{modal:!1,open:u,onOpenChange:E,children:[a.jsx(lo,{asChild:!0,children:a.jsx(Pl,{ref:x,value:n,handleSearch:R,handleKeyDown:U,handleOnClick:()=>{s(ae.bookNumberToId(e.bookNum)),d(ae.bookNumberToId(e.bookNum)),l(e.chapterNum>0?e.chapterNum:0),h(!0),x.current.focus()},onFocus:()=>{j.current=!0},handleSubmit:V,placeholder:`${ae.bookNumberToEnglishName(e.bookNum)} ${e.chapterNum}:${e.verseNum}`})}),a.jsxs(En,{className:"tw-m-1 tw-overflow-y-auto tw-p-0 tw-font-normal tw-text-foreground/80",style:{width:"233px",maxHeight:"500px",zIndex:"250"},onKeyDown:C,align:"start",ref:f,children:[a.jsx(Kl,{handleSort:()=>console.log("sorting"),handleLocationHistory:()=>console.log("location history"),handleBookmarks:()=>console.log("bookmarks")}),da.map((k,A)=>S(k).length>0&&a.jsxs("div",{children:[a.jsx(Wt,{className:"tw-font-semibold tw-text-foreground/80",children:Jl[k]}),S(k).map($=>a.jsx("div",{children:a.jsx(Yl,{bookId:$,handleSelectBook:()=>v($,!1),isSelected:o===$,handleHighlightBook:()=>d($),handleKeyDown:_,bookType:k,ref:J=>{o===$&&(m.current=J)},children:a.jsx(Wl,{handleSelectChapter:P,endChapter:rn($),activeChapter:e.bookNum===ae.bookIdToNumber($)?e.chapterNum:0,highlightedChapter:i,handleHighlightedChapter:J=>{l(J)}})})},$)),da.length-1!==A?a.jsx(jn,{}):void 0]},k))]})]})})}const bs=Xt.cva("pr-twp tw-inline-flex tw-items-center tw-justify-center tw-whitespace-nowrap tw-rounded-md tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-colors focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50",{variants:{variant:{default:"tw-bg-primary tw-text-primary-foreground hover:tw-bg-primary/90",destructive:"tw-bg-destructive tw-text-destructive-foreground hover:tw-bg-destructive/90",outline:"tw-border tw-border-input tw-bg-background hover:tw-bg-accent hover:tw-text-accent-foreground",secondary:"tw-bg-secondary tw-text-secondary-foreground hover:tw-bg-secondary/80",ghost:"hover:tw-bg-accent hover:tw-text-accent-foreground",link:"tw-text-primary tw-underline-offset-4 hover:tw-underline"},size:{default:"tw-h-10 tw-px-4 tw-py-2",sm:"tw-h-9 tw-rounded-md tw-px-3",lg:"tw-h-11 tw-rounded-md tw-px-8",icon:"tw-h-10 tw-w-10"}},defaultVariants:{variant:"default",size:"default"}}),fe=g.forwardRef(({className:e,variant:t,size:n,asChild:r=!1,...o},s)=>{const i=r?Ht.Slot:"button";return a.jsx(i,{className:N(bs({variant:t,size:n,className:e})),ref:s,...o})});fe.displayName="Button";const ac=Xt.cva("tw-text-sm tw-font-medium tw-leading-none peer-disabled:tw-cursor-not-allowed peer-disabled:tw-opacity-70"),qe=g.forwardRef(({className:e,...t},n)=>a.jsx(as.Root,{ref:n,className:N("pr-twp",ac(),e),...t}));qe.displayName=as.Root.displayName;const po=g.forwardRef(({className:e,...t},n)=>a.jsx(bn.Root,{className:N("pr-twp tw-grid tw-gap-2",e),...t,ref:n}));po.displayName=bn.Root.displayName;const Yn=g.forwardRef(({className:e,...t},n)=>a.jsx(bn.Item,{ref:n,className:N("pr-twp tw-aspect-square tw-h-4 tw-w-4 tw-rounded-full tw-border tw-border-primary tw-text-primary tw-ring-offset-background focus:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-cursor-not-allowed disabled:tw-opacity-50",e),...t,children:a.jsx(bn.Indicator,{className:"tw-flex tw-items-center tw-justify-center",children:a.jsx(Q.Circle,{className:"tw-h-2.5 tw-w-2.5 tw-fill-current tw-text-current"})})}));Yn.displayName=bn.Item.displayName;const sc=vn.Root,ic=vn.Trigger,vs=g.forwardRef(({className:e,align:t="center",sideOffset:n=4,...r},o)=>a.jsx(vn.Portal,{children:a.jsx(vn.Content,{ref:o,align:t,sideOffset:n,className:N("pr-twp tw-z-50 tw-w-72 tw-rounded-md tw-border tw-bg-popover tw-p-4 tw-text-popover-foreground tw-shadow-md tw-outline-none data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0 data-[state=closed]:tw-zoom-out-95 data-[state=open]:tw-zoom-in-95 data-[side=bottom]:tw-slide-in-from-top-2 data-[side=left]:tw-slide-in-from-right-2 data-[side=right]:tw-slide-in-from-left-2 data-[side=top]:tw-slide-in-from-bottom-2",e),...r})}));vs.displayName=vn.Content.displayName;const lc=be.Portal,xs=g.forwardRef(({className:e,...t},n)=>a.jsx(be.Overlay,{ref:n,className:N("tw-fixed tw-inset-0 tw-z-50 tw-bg-black/80 data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0",e),...t}));xs.displayName=be.Overlay.displayName;const cc=g.forwardRef(({className:e,children:t,...n},r)=>a.jsxs(lc,{children:[a.jsx(xs,{}),a.jsxs(be.Content,{ref:r,className:N("tw-fixed tw-left-[50%] tw-top-[50%] tw-z-50 tw-grid tw-w-full tw-max-w-lg tw-translate-x-[-50%] tw-translate-y-[-50%] tw-gap-4 tw-border tw-bg-background tw-p-6 tw-shadow-lg tw-duration-200 data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0 data-[state=closed]:tw-zoom-out-95 data-[state=open]:tw-zoom-in-95 data-[state=closed]:tw-slide-out-to-left-1/2 data-[state=closed]:tw-slide-out-to-top-[48%] data-[state=open]:tw-slide-in-from-left-1/2 data-[state=open]:tw-slide-in-from-top-[48%] sm:tw-rounded-lg",e),...n,children:[t,a.jsxs(be.Close,{className:"tw-absolute tw-right-4 tw-top-4 tw-rounded-sm tw-opacity-70 tw-ring-offset-background tw-transition-opacity hover:tw-opacity-100 focus:tw-outline-none focus:tw-ring-2 focus:tw-ring-ring focus:tw-ring-offset-2 disabled:tw-pointer-events-none data-[state=open]:tw-bg-accent data-[state=open]:tw-text-muted-foreground",children:[a.jsx(Q.X,{className:"tw-h-4 tw-w-4"}),a.jsx("span",{className:"tw-sr-only",children:"Close"})]})]})]}));cc.displayName=be.Content.displayName;const dc=g.forwardRef(({className:e,...t},n)=>a.jsx(be.Title,{ref:n,className:N("tw-text-lg tw-font-semibold tw-leading-none tw-tracking-tight",e),...t}));dc.displayName=be.Title.displayName;const uc=g.forwardRef(({className:e,...t},n)=>a.jsx(be.Description,{ref:n,className:N("tw-text-sm tw-text-muted-foreground",e),...t}));uc.displayName=be.Description.displayName;const ys=g.forwardRef(({className:e,...t},n)=>a.jsx(Re.Command,{ref:n,className:N("tw-flex tw-h-full tw-w-full tw-flex-col tw-overflow-hidden tw-rounded-md tw-bg-popover tw-text-popover-foreground",e),...t}));ys.displayName=Re.Command.displayName;const Ns=g.forwardRef(({className:e,...t},n)=>a.jsxs("div",{className:"tw-flex tw-items-center tw-border-b tw-px-3",children:[a.jsx(Q.Search,{className:"tw-me-2 tw-h-4 tw-w-4 tw-shrink-0 tw-opacity-50"}),a.jsx(Re.Command.Input,{ref:n,className:N("tw-flex tw-h-11 tw-w-full tw-rounded-md tw-bg-transparent tw-py-3 tw-text-sm tw-outline-none placeholder:tw-text-muted-foreground disabled:tw-cursor-not-allowed disabled:tw-opacity-50",e),...t})]}));Ns.displayName=Re.Command.Input.displayName;const ks=g.forwardRef(({className:e,...t},n)=>a.jsx(Re.Command.List,{ref:n,className:N("tw-max-h-[300px] tw-overflow-y-auto tw-overflow-x-hidden",e),...t}));ks.displayName=Re.Command.List.displayName;const Ss=g.forwardRef((e,t)=>a.jsx(Re.Command.Empty,{ref:t,className:"tw-py-6 tw-text-center tw-text-sm",...e}));Ss.displayName=Re.Command.Empty.displayName;const pc=g.forwardRef(({className:e,...t},n)=>a.jsx(Re.Command.Group,{ref:n,className:N("tw-overflow-hidden tw-p-1 tw-text-foreground [&_[cmdk-group-heading]]:tw-px-2 [&_[cmdk-group-heading]]:tw-py-1.5 [&_[cmdk-group-heading]]:tw-text-xs [&_[cmdk-group-heading]]:tw-font-medium [&_[cmdk-group-heading]]:tw-text-muted-foreground",e),...t}));pc.displayName=Re.Command.Group.displayName;const wc=g.forwardRef(({className:e,...t},n)=>a.jsx(Re.Command.Separator,{ref:n,className:N("tw--mx-1 tw-h-px tw-bg-border",e),...t}));wc.displayName=Re.Command.Separator.displayName;const Es=g.forwardRef(({className:e,...t},n)=>a.jsx(Re.Command.Item,{ref:n,className:N("tw-relative tw-flex tw-cursor-default tw-select-none tw-items-center tw-rounded-sm tw-px-2 tw-py-1.5 tw-text-sm tw-outline-none data-[disabled=true]:tw-pointer-events-none data-[selected=true]:tw-bg-accent data-[selected=true]:tw-text-accent-foreground data-[disabled=true]:tw-opacity-50",e),...t}));Es.displayName=Re.Command.Item.displayName;function fc(e){return typeof e=="string"?e:typeof e=="number"?e.toString():e.label}function Wn({id:e,options:t=[],buttonClassName:n,popoverContentClassName:r,value:o,onChange:s=()=>{},getOptionLabel:i=fc,buttonPlaceholder:l="",textPlaceholder:c="",commandEmptyMessage:d="No option found",buttonVariant:u="outline",dir:h="ltr",isDisabled:w=!1,...b}){const[x,f]=g.useState(!1);return a.jsxs(sc,{open:x,onOpenChange:f,...b,children:[a.jsx(ic,{asChild:!0,children:a.jsxs(fe,{variant:u,role:"combobox","aria-expanded":x,id:e,className:N("tw-w-[200px] tw-justify-between",n),disabled:w,children:[a.jsx("span",{className:"tw-overflow-hidden tw-text-ellipsis tw-whitespace-nowrap",children:o?i(o):l}),a.jsx(Q.ChevronsUpDown,{className:"tw-ms-2 tw-h-4 tw-w-4 tw-shrink-0 tw-opacity-50"})]})}),a.jsx(vs,{className:N("tw-w-[200px] tw-p-0",r),dir:h,children:a.jsxs(ys,{children:[a.jsx(Ns,{dir:h,placeholder:c,className:"tw-text-inherit"}),a.jsx(Ss,{children:d}),a.jsx(ks,{children:t.map(m=>a.jsxs(Es,{value:i(m),onSelect:()=>{s(m),f(!1)},children:[a.jsx(Q.Check,{className:N("tw-me-2 tw-h-4 tw-w-4",{"tw-opacity-0":!o||i(o)!==i(m)})}),i(m)]},i(m)))})]})})]})}function js({startChapter:e,endChapter:t,handleSelectStartChapter:n,handleSelectEndChapter:r,isDisabled:o=!1,chapterCount:s}){const i=g.useMemo(()=>Array.from({length:s},(d,u)=>u+1),[s]),l=d=>{n(d),d>t&&r(d)},c=d=>{r(d),dd.toString(),value:e},"start chapter"),a.jsx(qe,{htmlFor:"end-chapters-combobox",children:"to"}),a.jsx(Wn,{isDisabled:o,onChange:c,buttonClassName:"tw-ml-2 tw-w-20",options:i,getOptionLabel:d=>d.toString(),value:t},"end chapter")]})}var Cs=(e=>(e.CURRENT_BOOK="current book",e.CHOOSE_BOOKS="choose books",e))(Cs||{});const mc=Object.freeze(["%webView_bookSelector_currentBook%","%webView_bookSelector_choose%","%webView_bookSelector_chooseBooks%"]),Tr=(e,t)=>e[t]??t;function hc({handleBookSelectionModeChange:e,currentBookName:t,onSelectBooks:n,selectedBookIds:r,chapterCount:o,endChapter:s,handleSelectEndChapter:i,startChapter:l,handleSelectStartChapter:c,localizedStrings:d}){const u=Tr(d,"%webView_bookSelector_currentBook%"),h=Tr(d,"%webView_bookSelector_choose%"),w=Tr(d,"%webView_bookSelector_chooseBooks%"),[b,x]=g.useState("current book"),f=m=>{x(m),e(m)};return a.jsx(po,{className:"pr-twp tw-flex",value:b,onValueChange:m=>f(m),children:a.jsxs("div",{className:"tw-flex tw-w-full tw-flex-col tw-gap-4",children:[a.jsxs("div",{className:"tw-grid tw-grid-cols-[25%,25%,50%]",children:[a.jsxs("div",{className:"tw-flex tw-items-center",children:[a.jsx(Yn,{value:"current book"}),a.jsx(qe,{className:"tw-ml-1",children:u})]}),a.jsx(qe,{className:"tw-flex tw-items-center",children:t}),a.jsx("div",{className:"tw-flex tw-items-center tw-justify-end",children:a.jsx(js,{isDisabled:b==="choose books",handleSelectStartChapter:c,handleSelectEndChapter:i,chapterCount:o,startChapter:l,endChapter:s})})]}),a.jsxs("div",{className:"tw-grid tw-grid-cols-[25%,50%,25%]",children:[a.jsxs("div",{className:"tw-flex tw-items-center",children:[a.jsx(Yn,{value:"choose books"}),a.jsx(qe,{className:"tw-ml-1",children:w})]}),a.jsx(qe,{className:"tw-flex tw-items-center",children:r.map(m=>ae.bookIdToEnglishName(m)).join(", ")}),a.jsx(fe,{disabled:b==="current book",onClick:()=>n(),children:h})]})]})})}function gc({table:e}){return a.jsxs(or,{children:[a.jsx(rs.DropdownMenuTrigger,{asChild:!0,children:a.jsxs(fe,{variant:"outline",size:"sm",className:"tw-ml-auto tw-hidden tw-h-8 lg:tw-flex",children:[a.jsx(Q.FilterIcon,{className:"tw-mr-2 tw-h-4 tw-w-4"}),"View"]})}),a.jsxs(En,{align:"end",className:"tw-w-[150px]",children:[a.jsx(Wt,{children:"Toggle columns"}),a.jsx(jn,{}),e.getAllColumns().filter(t=>t.getCanHide()).map(t=>a.jsx(ar,{className:"tw-capitalize",checked:t.getIsVisible(),onCheckedChange:n=>t.toggleVisibility(!!n),children:t.id},t.id))]})]})}const Dt=ge.Root,Ts=ge.Group,Bt=ge.Value,bt=g.forwardRef(({className:e,children:t,...n},r)=>a.jsxs(ge.Trigger,{ref:r,className:N("tw-flex tw-h-10 tw-w-full tw-items-center tw-justify-between tw-rounded-md tw-border tw-border-input tw-bg-background tw-px-3 tw-py-2 tw-text-sm tw-ring-offset-background placeholder:tw-text-muted-foreground focus:tw-outline-none focus:tw-ring-2 focus:tw-ring-ring focus:tw-ring-offset-2 disabled:tw-cursor-not-allowed disabled:tw-opacity-50 [&>span]:tw-line-clamp-1",e),...n,children:[t,a.jsx(ge.Icon,{asChild:!0,children:a.jsx(Q.ChevronDown,{className:"tw-h-4 tw-w-4 tw-opacity-50"})})]}));bt.displayName=ge.Trigger.displayName;const wo=g.forwardRef(({className:e,...t},n)=>a.jsx(ge.ScrollUpButton,{ref:n,className:N("tw-flex tw-cursor-default tw-items-center tw-justify-center tw-py-1",e),...t,children:a.jsx(Q.ChevronUp,{className:"tw-h-4 tw-w-4"})}));wo.displayName=ge.ScrollUpButton.displayName;const fo=g.forwardRef(({className:e,...t},n)=>a.jsx(ge.ScrollDownButton,{ref:n,className:N("tw-flex tw-cursor-default tw-items-center tw-justify-center tw-py-1",e),...t,children:a.jsx(Q.ChevronDown,{className:"tw-h-4 tw-w-4"})}));fo.displayName=ge.ScrollDownButton.displayName;const vt=g.forwardRef(({className:e,children:t,position:n="popper",...r},o)=>a.jsx(ge.Portal,{children:a.jsxs(ge.Content,{ref:o,className:N("pr-twp tw-relative tw-z-50 tw-max-h-96 tw-min-w-[8rem] tw-overflow-hidden tw-rounded-md tw-border tw-bg-popover tw-text-popover-foreground tw-shadow-md data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0 data-[state=closed]:tw-zoom-out-95 data-[state=open]:tw-zoom-in-95 data-[side=bottom]:tw-slide-in-from-top-2 data-[side=left]:tw-slide-in-from-right-2 data-[side=right]:tw-slide-in-from-left-2 data-[side=top]:tw-slide-in-from-bottom-2",n==="popper"&&"data-[side=bottom]:tw-translate-y-1 data-[side=left]:tw--translate-x-1 data-[side=right]:tw-translate-x-1 data-[side=top]:tw--translate-y-1",e),position:n,...r,children:[a.jsx(wo,{}),a.jsx(ge.Viewport,{className:N("tw-p-1",n==="popper"&&"tw-h-[var(--radix-select-trigger-height)] tw-w-full tw-min-w-[var(--radix-select-trigger-width)]"),children:t}),a.jsx(fo,{})]})}));vt.displayName=ge.Content.displayName;const Rs=g.forwardRef(({className:e,...t},n)=>a.jsx(ge.Label,{ref:n,className:N("tw-py-1.5 tw-pl-8 tw-pr-2 tw-text-sm tw-font-semibold",e),...t}));Rs.displayName=ge.Label.displayName;const De=g.forwardRef(({className:e,children:t,...n},r)=>a.jsxs(ge.Item,{ref:r,className:N("tw-relative tw-flex tw-w-full tw-cursor-default tw-select-none tw-items-center tw-rounded-sm tw-py-1.5 tw-pl-8 tw-pr-2 tw-text-sm tw-outline-none focus:tw-bg-accent focus:tw-text-accent-foreground data-[disabled]:tw-pointer-events-none data-[disabled]:tw-opacity-50",e),...n,children:[a.jsx("span",{className:"tw-absolute tw-left-2 tw-flex tw-h-3.5 tw-w-3.5 tw-items-center tw-justify-center",children:a.jsx(ge.ItemIndicator,{children:a.jsx(Q.Check,{className:"tw-h-4 tw-w-4"})})}),a.jsx(ge.ItemText,{children:t})]}));De.displayName=ge.Item.displayName;const Os=g.forwardRef(({className:e,...t},n)=>a.jsx(ge.Separator,{ref:n,className:N("tw--mx-1 tw-my-1 tw-h-px tw-bg-muted",e),...t}));Os.displayName=ge.Separator.displayName;function bc({table:e}){return a.jsx("div",{className:"tw-flex tw-items-center tw-justify-between tw-px-2 tw-pb-3 tw-pt-3",children:a.jsxs("div",{className:"tw-flex tw-items-center tw-space-x-6 lg:tw-space-x-8",children:[a.jsxs("div",{className:"tw-flex-1 tw-text-sm tw-text-muted-foreground",children:[e.getFilteredSelectedRowModel().rows.length," of"," ",e.getFilteredRowModel().rows.length," row(s) selected"]}),a.jsxs("div",{className:"tw-flex tw-items-center tw-space-x-2",children:[a.jsx("p",{className:"tw-text-nowrap tw-text-sm tw-font-medium",children:"Rows per page"}),a.jsxs(Dt,{value:`${e.getState().pagination.pageSize}`,onValueChange:t=>{e.setPageSize(Number(t))},children:[a.jsx(bt,{className:"tw-h-8 tw-w-[70px]",children:a.jsx(Bt,{placeholder:e.getState().pagination.pageSize})}),a.jsx(vt,{side:"top",children:[10,20,30,40,50].map(t=>a.jsx(De,{value:`${t}`,children:t},t))})]})]}),a.jsxs("div",{className:"tw-flex tw-w-[100px] tw-items-center tw-justify-center tw-text-sm tw-font-medium",children:["Page ",e.getState().pagination.pageIndex+1," of ",e.getPageCount()]}),a.jsxs("div",{className:"tw-flex tw-items-center tw-space-x-2",children:[a.jsxs(fe,{variant:"outline",size:"icon",className:"tw-hidden tw-h-8 tw-w-8 tw-p-0 lg:tw-flex",onClick:()=>e.setPageIndex(0),disabled:!e.getCanPreviousPage(),children:[a.jsx("span",{className:"tw-sr-only",children:"Go to first page"}),a.jsx(Q.ArrowLeftIcon,{className:"tw-h-4 tw-w-4"})]}),a.jsxs(fe,{variant:"outline",size:"icon",className:"tw-h-8 tw-w-8 tw-p-0",onClick:()=>e.previousPage(),disabled:!e.getCanPreviousPage(),children:[a.jsx("span",{className:"tw-sr-only",children:"Go to previous page"}),a.jsx(Q.ChevronLeftIcon,{className:"tw-h-4 tw-w-4"})]}),a.jsxs(fe,{variant:"outline",size:"icon",className:"tw-h-8 tw-w-8 tw-p-0",onClick:()=>e.nextPage(),disabled:!e.getCanNextPage(),children:[a.jsx("span",{className:"tw-sr-only",children:"Go to next page"}),a.jsx(Q.ChevronRightIcon,{className:"tw-h-4 tw-w-4"})]}),a.jsxs(fe,{variant:"outline",size:"icon",className:"tw-hidden tw-h-8 tw-w-8 tw-p-0 lg:tw-flex",onClick:()=>e.setPageIndex(e.getPageCount()-1),disabled:!e.getCanNextPage(),children:[a.jsx("span",{className:"tw-sr-only",children:"Go to last page"}),a.jsx(Q.ArrowRightIcon,{className:"tw-h-4 tw-w-4"})]})]})]})})}const Cn=g.forwardRef(({className:e,stickyHeader:t,...n},r)=>a.jsx("div",{className:N("pr-twp tw-relative tw-w-full",{"tw-overflow-auto":!t}),children:a.jsx("table",{ref:r,className:N("tw-w-full tw-caption-bottom tw-text-sm",e),...n})}));Cn.displayName="Table";const Tn=g.forwardRef(({className:e,stickyHeader:t,...n},r)=>a.jsx("thead",{ref:r,className:N({"tw-sticky tw-top-[-1px] tw-bg-background tw-drop-shadow-sm":t},"[&_tr]:tw-border-b",e),...n}));Tn.displayName="TableHeader";const Rn=g.forwardRef(({className:e,...t},n)=>a.jsx("tbody",{ref:n,className:N("[&_tr:last-child]:tw-border-0",e),...t}));Rn.displayName="TableBody";const _s=g.forwardRef(({className:e,...t},n)=>a.jsx("tfoot",{ref:n,className:N("tw-border-t tw-bg-muted/50 tw-font-medium [&>tr]:last:tw-border-b-0",e),...t}));_s.displayName="TableFooter";const Ze=g.forwardRef(({className:e,...t},n)=>a.jsx("tr",{ref:n,className:N("tw-border-b tw-transition-colors hover:tw-bg-muted/50 data-[state=selected]:tw-bg-muted",e),...t}));Ze.displayName="TableRow";const Vt=g.forwardRef(({className:e,...t},n)=>a.jsx("th",{ref:n,className:N("tw-h-12 tw-px-4 tw-text-start tw-align-middle tw-font-medium tw-text-muted-foreground [&:has([role=checkbox])]:tw-pe-0",e),...t}));Vt.displayName="TableHead";const xt=g.forwardRef(({className:e,...t},n)=>a.jsx("td",{ref:n,className:N("tw-p-4 tw-align-middle [&:has([role=checkbox])]:tw-pe-0",e),...t}));xt.displayName="TableCell";const Ps=g.forwardRef(({className:e,...t},n)=>a.jsx("caption",{ref:n,className:N("tw-mt-4 tw-text-sm tw-text-muted-foreground",e),...t}));Ps.displayName="TableCaption";function Is({columns:e,data:t,enablePagination:n=!1,showPaginationControls:r=!1,showColumnVisibilityControls:o=!1,stickyHeader:s=!1,onRowClickHandler:i=()=>{}}){var m;const[l,c]=g.useState([]),[d,u]=g.useState([]),[h,w]=g.useState({}),[b,x]=g.useState({}),f=Se.useReactTable({data:t,columns:e,getCoreRowModel:Se.getCoreRowModel(),...n&&{getPaginationRowModel:Se.getPaginationRowModel()},onSortingChange:c,getSortedRowModel:Se.getSortedRowModel(),onColumnFiltersChange:u,getFilteredRowModel:Se.getFilteredRowModel(),onColumnVisibilityChange:w,onRowSelectionChange:x,state:{sorting:l,columnFilters:d,columnVisibility:h,rowSelection:b}});return a.jsxs("div",{className:"pr-twp",children:[o&&a.jsx(gc,{table:f}),a.jsxs(Cn,{stickyHeader:s,children:[a.jsx(Tn,{stickyHeader:s,children:f.getHeaderGroups().map(S=>a.jsx(Ze,{children:S.headers.map(R=>a.jsx(Vt,{children:R.isPlaceholder?void 0:Se.flexRender(R.column.columnDef.header,R.getContext())},R.id))},S.id))}),a.jsx(Rn,{children:(m=f.getRowModel().rows)!=null&&m.length?f.getRowModel().rows.map(S=>a.jsx(Ze,{onClick:()=>i(S,f),"data-state":S.getIsSelected()&&"selected",children:S.getVisibleCells().map(R=>a.jsx(xt,{children:Se.flexRender(R.column.columnDef.cell,R.getContext())},R.id))},S.id)):a.jsx(Ze,{children:a.jsx(xt,{colSpan:e.length,className:"tw-h-24 tw-text-center",children:"No results."})})})]}),n&&a.jsxs("div",{className:"tw-flex tw-items-center tw-justify-end tw-space-x-2 tw-py-4",children:[a.jsx(fe,{variant:"outline",size:"sm",onClick:()=>f.previousPage(),disabled:!f.getCanPreviousPage(),children:"Previous"}),a.jsx(fe,{variant:"outline",size:"sm",onClick:()=>f.nextPage(),disabled:!f.getCanNextPage(),children:"Next"})]}),n&&r&&a.jsx(bc,{table:f})]})}function vc({occurrenceData:e,setScriptureReference:t,localizedStrings:n}){const r=n["%webView_inventory_occurrences_table_header_reference%"],o=n["%webView_inventory_occurrences_table_header_occurrence%"],s=g.useMemo(()=>{const i=[];return e.forEach(l=>{i.some(c=>W.deepEqual(c,l))||i.push(l)}),i},[e]);return a.jsxs(Cn,{stickyHeader:!0,children:[a.jsx(Tn,{stickyHeader:!0,children:a.jsxs(Ze,{children:[a.jsx(Vt,{children:r}),a.jsx(Vt,{children:o})]})}),a.jsx(Rn,{children:s.length>0&&s.map(i=>a.jsxs(Ze,{onClick:()=>{t(i.reference)},children:[a.jsx(xt,{children:`${ae.bookNumberToEnglishName(i.reference.bookNum)} ${i.reference.chapterNum}:${i.reference.verseNum}`}),a.jsx(xt,{children:i.text})]},`${i.reference.bookNum} ${i.reference.chapterNum}:${i.reference.verseNum}-${i.text}`))})]})}const sr=g.forwardRef(({className:e,...t},n)=>a.jsx(Ur.Root,{ref:n,className:N("tw-peer pr-twp tw-h-4 tw-w-4 tw-shrink-0 tw-rounded-sm tw-border tw-border-primary tw-ring-offset-background focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-cursor-not-allowed disabled:tw-opacity-50 data-[state=checked]:tw-bg-primary data-[state=checked]:tw-text-primary-foreground",e),...t,children:a.jsx(Ur.Indicator,{className:N("tw-flex tw-items-center tw-justify-center tw-text-current"),children:a.jsx(Q.Check,{className:"tw-h-4 tw-w-4"})})}));sr.displayName=Ur.Root.displayName;const Ms=e=>e.split(/(?:\r?\n|\r)|(?=(?:\\(?:v|c|id)))/g),Hr=e=>{const t=/^\\[vc]\s+(\d+)/,n=e.match(t);if(n)return+n[1]},$s=e=>{const t=e.match(/^\\id\s+([A-Za-z]+)/);return t?ae.bookIdToNumber(t[1]):0},As=(e,t,n)=>n.includes(e)?"unapproved":t.includes(e)?"approved":"unknown",Ds=Xt.cva("pr-twp tw-inline-flex tw-items-center tw-justify-center tw-rounded-md tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-colors hover:tw-bg-muted hover:tw-text-muted-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50 data-[state=on]:tw-bg-accent data-[state=on]:tw-text-accent-foreground",{variants:{variant:{default:"tw-bg-transparent",outline:"tw-border tw-border-input tw-bg-transparent hover:tw-bg-accent hover:tw-text-accent-foreground"},size:{default:"tw-h-10 tw-px-3",sm:"tw-h-9 tw-px-2.5",lg:"tw-h-11 tw-px-5"}},defaultVariants:{variant:"default",size:"default"}}),xc=g.forwardRef(({className:e,variant:t,size:n,...r},o)=>a.jsx(ss.Root,{ref:o,className:N(Ds({variant:t,size:n,className:e})),...r}));xc.displayName=ss.Root.displayName;const Bs=g.createContext({size:"default",variant:"default"}),mo=g.forwardRef(({className:e,variant:t,size:n,children:r,...o},s)=>a.jsx(rr.Root,{ref:s,className:N("pr-twp tw-flex tw-items-center tw-justify-center tw-gap-1",e),...o,children:a.jsx(Bs.Provider,{value:{variant:t,size:n},children:r})}));mo.displayName=rr.Root.displayName;const fn=g.forwardRef(({className:e,children:t,variant:n,size:r,...o},s)=>{const i=g.useContext(Bs);return a.jsx(rr.Item,{ref:s,className:N(Ds({variant:i.variant||n,size:i.size||r}),e),...o,children:t})});fn.displayName=rr.Item.displayName;const ir=e=>e==="asc"?a.jsx(Q.ArrowUpIcon,{className:"tw-ms-2 tw-h-4 tw-w-4"}):e==="desc"?a.jsx(Q.ArrowDownIcon,{className:"tw-ms-2 tw-h-4 tw-w-4"}):a.jsx(Q.ArrowUpDownIcon,{className:"tw-ms-2 tw-h-4 tw-w-4"}),yc=e=>({accessorKey:"item",accessorFn:t=>t.items[0],header:({column:t})=>a.jsxs(fe,{variant:"ghost",onClick:()=>t.toggleSorting(void 0),children:[e,ir(t.getIsSorted())]})}),Nc=(e,t)=>({accessorKey:`item${t}`,accessorFn:n=>n.items[t],header:({column:n})=>a.jsxs(fe,{variant:"ghost",onClick:()=>n.toggleSorting(void 0),children:[e,ir(n.getIsSorted())]})}),kc=e=>({accessorKey:"count",header:({column:t})=>a.jsx("div",{className:"tw-flex tw-justify-end tw-tabular-nums",children:a.jsxs(fe,{variant:"ghost",onClick:()=>t.toggleSorting(void 0),children:[e,ir(t.getIsSorted())]})}),cell:({row:t})=>a.jsx("div",{className:"tw-flex tw-justify-end",children:t.getValue("count")})}),Rr=(e,t,n,r,o,s)=>{let i=[...n];e.forEach(c=>{t==="approved"?i.includes(c)||i.push(c):i=i.filter(d=>d!==c)}),r(i);let l=[...o];e.forEach(c=>{t==="unapproved"?l.includes(c)||l.push(c):l=l.filter(d=>d!==c)}),s(l)},Sc=(e,t,n,r,o)=>({accessorKey:"status",header:({column:s})=>a.jsx("div",{className:"tw-flex tw-justify-center",children:a.jsxs(fe,{variant:"ghost",onClick:()=>s.toggleSorting(void 0),children:[e,ir(s.getIsSorted())]})}),cell:({row:s})=>{const i=s.getValue("status"),l=s.getValue("item");return a.jsxs(mo,{value:i,variant:"outline",type:"single",children:[a.jsx(fn,{onClick:()=>Rr([l],"approved",t,n,r,o),value:"approved",children:a.jsx(Q.CircleCheckIcon,{})}),a.jsx(fn,{onClick:()=>Rr([l],"unapproved",t,n,r,o),value:"unapproved",children:a.jsx(Q.CircleXIcon,{})}),a.jsx(fn,{onClick:()=>Rr([l],"unknown",t,n,r,o),value:"unknown",children:a.jsx(Q.CircleHelpIcon,{})})]})}}),Ec=Object.freeze(["%webView_inventory_all%","%webView_inventory_approved%","%webView_inventory_unapproved%","%webView_inventory_unknown%","%webView_inventory_scope_currentBook%","%webView_inventory_scope_chapter%","%webView_inventory_scope_verse%","%webView_inventory_filter_text%","%webView_inventory_show_additional_items%","%webView_inventory_occurrences_table_header_reference%","%webView_inventory_occurrences_table_header_occurrence%"]),jc=(e,t,n)=>{let r=e;return t!=="all"&&(r=r.filter(o=>t==="approved"&&o.status==="approved"||t==="unapproved"&&o.status==="unapproved"||t==="unknown"&&o.status==="unknown")),n!==""&&(r=r.filter(o=>o.items[0].includes(n))),r},Cc=(e,t,n,r,o)=>{if(!e)return[];const s=[];let i=t.bookNum,l=t.chapterNum,c=t.verseNum;return Ms(e).forEach(u=>{u.startsWith("\\id")&&(i=$s(u),l=0,c=0),u.startsWith("\\c")&&(l=Hr(u),c=0),u.startsWith("\\v")&&(c=Hr(u),l===0&&(l=t.chapterNum));let h=o.exec(u)??void 0;for(;h;){const w=[];h.forEach(m=>w.push(m));const b=h.index,x=s.find(m=>W.deepEqual(m.items,w)),f={reference:{bookNum:i!==void 0?i:-1,chapterNum:l!==void 0?l:-1,verseNum:c!==void 0?c:-1},text:W.substring(u,Math.max(0,b-25),Math.min(b+25,u.length))};if(x)x.count+=1,x.occurrences.push(f);else{const m={items:w,count:1,status:As(w[0],n,r),occurrences:[f]};s.push(m)}h=o.exec(u)??void 0}}),s},Je=(e,t)=>e[t]??t;function Tc({scriptureReference:e,setScriptureReference:t,localizedStrings:n,extractItems:r,additionalItemsLabels:o,approvedItems:s,unapprovedItems:i,text:l,scope:c,onScopeChange:d,columns:u}){const h=Je(n,"%webView_inventory_all%"),w=Je(n,"%webView_inventory_approved%"),b=Je(n,"%webView_inventory_unapproved%"),x=Je(n,"%webView_inventory_unknown%"),f=Je(n,"%webView_inventory_scope_currentBook%"),m=Je(n,"%webView_inventory_scope_chapter%"),S=Je(n,"%webView_inventory_scope_verse%"),R=Je(n,"%webView_inventory_filter_text%"),j=Je(n,"%webView_inventory_show_additional_items%"),[E,v]=g.useState(!1),[P,V]=g.useState("all"),[U,C]=g.useState(""),[_,k]=g.useState([]),A=g.useMemo(()=>l?r instanceof RegExp?Cc(l,e,s,i,r):r(l,e,s,i):[],[l,r,e,s,i]),$=g.useMemo(()=>{if(E)return A;const y=[];return A.forEach(T=>{const z=T.items[0],L=y.find(B=>B.items[0]===z);L?(L.count+=T.count,L.occurrences=L.occurrences.concat(T.occurrences)):y.push({items:[z],count:T.count,occurrences:T.occurrences,status:T.status})}),y},[E,A]),J=g.useMemo(()=>jc($,P,U),[$,P,U]),Y=g.useMemo(()=>{var z,L;if(!E)return u;const y=(z=o==null?void 0:o.tableHeaders)==null?void 0:z.length;if(!y)return u;const T=[];for(let B=0;B{k([])},[J]);const F=(y,T)=>{T.setRowSelection(()=>{const z={};return z[y.index]=!0,z}),k(y.original.items)},te=y=>{if(y==="book"||y==="chapter"||y==="verse")d(y);else throw new Error(`Invalid scope value: ${y}`)},se=y=>{if(y==="all"||y==="approved"||y==="unapproved"||y==="unknown")V(y);else throw new Error(`Invalid status filter value: ${y}`)},oe=g.useMemo(()=>{if($.length===0||_.length===0)return[];const y=$.filter(T=>W.deepEqual(E?T.items:[T.items[0]],_));if(y.length>1)throw new Error("Selected item is not unique");return y[0].occurrences},[_,E,$]);return a.jsxs("div",{className:"pr-twp tw-flex tw-h-full tw-flex-col",children:[a.jsxs("div",{className:"tw-flex tw-items-stretch",children:[a.jsxs(Dt,{onValueChange:y=>se(y),defaultValue:P,children:[a.jsx(bt,{className:"tw-m-1",children:a.jsx(Bt,{placeholder:"Select filter"})}),a.jsxs(vt,{children:[a.jsx(De,{value:"all",children:h}),a.jsx(De,{value:"approved",children:w}),a.jsx(De,{value:"unapproved",children:b}),a.jsx(De,{value:"unknown",children:x})]})]}),a.jsxs(Dt,{onValueChange:y=>te(y),defaultValue:c,children:[a.jsx(bt,{className:"tw-m-1",children:a.jsx(Bt,{placeholder:"Select scope"})}),a.jsxs(vt,{children:[a.jsx(De,{value:"book",children:f}),a.jsx(De,{value:"chapter",children:m}),a.jsx(De,{value:"verse",children:S})]})]}),a.jsx(St,{className:"tw-m-1 tw-rounded-md tw-border",placeholder:R,value:U,onChange:y=>{C(y.target.value)}}),o&&a.jsxs("div",{className:"tw-m-1 tw-flex tw-items-center tw-rounded-md tw-border",children:[a.jsx(sr,{className:"tw-m-1",checked:E,onCheckedChange:y=>{k([]),v(y)}}),a.jsx(qe,{className:"tw-m-1 tw-flex-shrink-0 tw-whitespace-nowrap",children:(o==null?void 0:o.checkboxText)??j})]})]}),a.jsx("div",{className:"tw-m-1 tw-flex-1 tw-overflow-auto tw-rounded-md tw-border",children:a.jsx(Is,{columns:Y,data:J,onRowClickHandler:F,stickyHeader:!0})}),oe.length>0&&a.jsx("div",{className:"tw-m-1 tw-flex-1 tw-overflow-auto tw-rounded-md tw-border",children:a.jsx(vc,{occurrenceData:oe,setScriptureReference:t,localizedStrings:n})})]})}function ho({className:e,onSearch:t,placeholder:n,isFullWidth:r}){const[o,s]=g.useState(""),i=l=>{s(l),t(l)};return a.jsx(St,{className:N("tw-flex tw-h-10 tw-rounded-md tw-border tw-border-input tw-bg-background tw-px-3 tw-py-2 tw-text-sm tw-ring-offset-background file:tw-border-0 file:tw-bg-transparent file:tw-text-sm file:tw-font-medium placeholder:tw-text-muted-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-[color:hsl(240,5%,64.9%)] focus-visible:tw-ring-offset-2 disabled:tw-cursor-not-allowed disabled:tw-opacity-50",{"tw-w-full":r},e),placeholder:n,value:o,onChange:l=>i(l.target.value)})}const go=g.forwardRef(({className:e,...t},n)=>a.jsx(Oe.Root,{orientation:"vertical",ref:n,className:N("tw-flex tw-gap-1 tw-rounded-md tw-text-muted-foreground",e),...t}));go.displayName=Oe.List.displayName;const bo=g.forwardRef(({className:e,...t},n)=>a.jsx(Oe.List,{ref:n,className:N("tw-flex-fit tw-mlk-items-center tw-w-[124px] tw-justify-center tw-rounded-md tw-bg-muted tw-p-1 tw-text-muted-foreground",e),...t}));bo.displayName=Oe.List.displayName;const Vs=g.forwardRef(({className:e,...t},n)=>a.jsx(Oe.Trigger,{ref:n,...t,className:N("overflow-clip tw-inline-flex tw-w-[116px] tw-cursor-pointer tw-items-center tw-justify-center tw-break-words tw-rounded-sm tw-border-0 tw-bg-muted tw-px-3 tw-py-1.5 tw-text-sm tw-font-medium tw-text-inherit tw-ring-offset-background tw-transition-all hover:tw-text-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50 data-[state=active]:tw-bg-background data-[state=active]:tw-text-foreground data-[state=active]:tw-shadow-sm",e)})),vo=g.forwardRef(({className:e,...t},n)=>a.jsx(Oe.Content,{ref:n,className:N("tw-ms-5 tw-flex-grow tw-text-foreground tw-ring-offset-background focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2",e),...t}));vo.displayName=Oe.Content.displayName;function Rc({tabList:e,onSearch:t,searchPlaceholder:n,headerTitle:r,isSearchBarFullWidth:o=!1,direction:s="ltr"}){return a.jsxs("div",{className:"pr-twp",children:[a.jsxs("div",{className:"tw-sticky tw-top-0 tw-space-y-2 tw-pb-2",children:[r?a.jsx("h1",{children:r}):"",a.jsx(ho,{isFullWidth:o,onSearch:t,placeholder:n})]}),a.jsxs(go,{dir:s,children:[a.jsx(bo,{children:e.map(i=>a.jsx(Vs,{value:i.value,children:i.value},i.key))}),e.map(i=>a.jsx(vo,{value:i.value,children:i.content},i.key))]})]})}const lr=g.forwardRef(({className:e,orientation:t="horizontal",decorative:n=!0,...r},o)=>a.jsx(is.Root,{ref:o,decorative:n,orientation:t,className:N("pr-twp tw-shrink-0 tw-bg-border",t==="horizontal"?"tw-h-[1px] tw-w-full":"tw-h-full tw-w-[1px]",e),...r}));lr.displayName=is.Root.displayName;const Oc=be.Root,_c=be.Portal,zs=M.forwardRef(({className:e,...t},n)=>a.jsx(be.Overlay,{className:N("tw-fixed tw-inset-0 tw-z-50 tw-bg-black/80 data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0",e),...t,ref:n}));zs.displayName=be.Overlay.displayName;const Pc=Xt.cva("pr-twp tw-fixed tw-z-50 tw-gap-4 tw-bg-background tw-p-6 tw-shadow-lg tw-transition tw-ease-in-out data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-duration-300 data-[state=open]:tw-duration-500",{variants:{side:{top:"tw-inset-x-0 tw-top-0 tw-border-b data-[state=closed]:tw-slide-out-to-top data-[state=open]:tw-slide-in-from-top",bottom:"tw-inset-x-0 tw-bottom-0 tw-border-t data-[state=closed]:tw-slide-out-to-bottom data-[state=open]:tw-slide-in-from-bottom",left:"tw-inset-y-0 tw-left-0 tw-h-full tw-w-3/4 tw-border-r data-[state=closed]:tw-slide-out-to-left data-[state=open]:tw-slide-in-from-left sm:tw-max-w-sm",right:"tw-inset-y-0 tw-right-0 tw-h-full tw-w-3/4 tw- tw-border-l data-[state=closed]:tw-slide-out-to-right data-[state=open]:tw-slide-in-from-right sm:tw-max-w-sm"}},defaultVariants:{side:"right"}}),Ls=M.forwardRef(({side:e="right",className:t,children:n,...r},o)=>a.jsxs(_c,{children:[a.jsx(zs,{}),a.jsxs(be.Content,{ref:o,className:N(Pc({side:e}),t),...r,children:[n,a.jsxs(be.Close,{className:"tw-absolute tw-right-4 tw-top-4 tw-rounded-sm tw-opacity-70 tw-ring-offset-background tw-transition-opacity hover:tw-opacity-100 focus:tw-outline-none focus:tw-ring-2 focus:tw-ring-ring focus:tw-ring-offset-2 disabled:tw-pointer-events-none data-[state=open]:tw-bg-secondary",children:[a.jsx(Q.X,{className:"tw-h-4 tw-w-4"}),a.jsx("span",{className:"tw-sr-only",children:"Close"})]})]})]}));Ls.displayName=be.Content.displayName;const Ic=M.forwardRef(({className:e,...t},n)=>a.jsx(be.Title,{ref:n,className:N("tw-text-lg tw-font-semibold tw-text-foreground",e),...t}));Ic.displayName=be.Title.displayName;const Mc=M.forwardRef(({className:e,...t},n)=>a.jsx(be.Description,{ref:n,className:N("tw-text-sm tw-text-muted-foreground",e),...t}));Mc.displayName=be.Description.displayName;function ua({className:e,...t}){return a.jsx("div",{className:N("pr-twp tw-animate-pulse tw-rounded-md tw-bg-muted",e),...t})}const $c=Sn.Provider,Ac=Sn.Root,Dc=Sn.Trigger,Fs=g.forwardRef(({className:e,sideOffset:t=4,...n},r)=>a.jsx(Sn.Content,{ref:r,sideOffset:t,className:N("pr-twp tw-z-50 tw-overflow-hidden tw-rounded-md tw-border tw-bg-popover tw-px-3 tw-py-1.5 tw-text-sm tw-text-popover-foreground tw-shadow-md tw-animate-in tw-fade-in-0 tw-zoom-in-95 data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=closed]:tw-zoom-out-95 data-[side=bottom]:tw-slide-in-from-top-2 data-[side=left]:tw-slide-in-from-right-2 data-[side=right]:tw-slide-in-from-left-2 data-[side=top]:tw-slide-in-from-bottom-2",e),...n}));Fs.displayName=Sn.Content.displayName;const Or=768;function Bc(){const[e,t]=M.useState(void 0);return M.useEffect(()=>{const n=window.matchMedia(`(max-width: ${Or-1}px)`),r=()=>{t(window.innerWidthn.removeEventListener("change",r)},[]),!!e}const Vc="sidebar:state",zc=60*60*24*7,Lc="16rem",Fc="18rem",Gc="3rem",Uc="b",Gs=g.createContext(void 0);function cr(){const e=g.useContext(Gs);if(!e)throw new Error("useSidebar must be used within a SidebarProvider.");return e}const Us=g.forwardRef(({defaultOpen:e=!0,open:t,onOpenChange:n,className:r,style:o,children:s,...i},l)=>{const c=Bc(),[d,u]=g.useState(!1),[h,w]=g.useState(e),b=t??h,x=g.useCallback(R=>{const j=typeof R=="function"?R(b):R;n?n(j):w(j),document.cookie=`${Vc}=${j}; path=/; max-age=${zc}`},[n,b]),f=g.useCallback(()=>c?u(R=>!R):x(R=>!R),[c,x,u]);g.useEffect(()=>{const R=j=>{j.key===Uc&&(j.metaKey||j.ctrlKey)&&(j.preventDefault(),f())};return window.addEventListener("keydown",R),()=>window.removeEventListener("keydown",R)},[f]);const m=b?"expanded":"collapsed",S=g.useMemo(()=>({state:m,open:b,setOpen:x,isMobile:c,openMobile:d,setOpenMobile:u,toggleSidebar:f}),[m,b,x,c,d,u,f]);return a.jsx(Gs.Provider,{value:S,children:a.jsx($c,{delayDuration:0,children:a.jsx("div",{style:{"--sidebar-width":Lc,"--sidebar-width-icon":Gc,...o},className:N("tw-group/sidebar-wrapper pr-twp tw-flex tw-w-full has-[[data-variant=inset]]:tw-bg-sidebar",r),ref:l,...i,children:s})})})});Us.displayName="SidebarProvider";const qs=g.forwardRef(({side:e="left",variant:t="sidebar",collapsible:n="offcanvas",className:r,children:o,...s},i)=>{const{isMobile:l,state:c,openMobile:d,setOpenMobile:u}=cr();return n==="none"?a.jsx("div",{className:N("tw-flex tw-h-full tw-w-[--sidebar-width] tw-flex-col tw-bg-sidebar tw-text-sidebar-foreground",r),ref:i,...s,children:o}):l?a.jsx(Oc,{open:d,onOpenChange:u,...s,children:a.jsx(Ls,{"data-sidebar":"sidebar","data-mobile":"true",className:"tw-w-[--sidebar-width] tw-bg-sidebar tw-p-0 tw-text-sidebar-foreground [&>button]:tw-hidden",style:{"--sidebar-width":Fc},side:e,children:a.jsx("div",{className:"tw-flex tw-h-full tw-w-full tw-flex-col",children:o})})}):a.jsxs("div",{ref:i,className:"tw-group tw-peer tw-hidden tw-text-sidebar-foreground md:tw-block","data-state":c,"data-collapsible":c==="collapsed"?n:"","data-variant":t,"data-side":e,children:[a.jsx("div",{className:N("tw-relative tw-h-svh tw-w-[--sidebar-width] tw-bg-transparent tw-transition-[width] tw-duration-200 tw-ease-linear","group-data-[collapsible=offcanvas]:tw-w-0","group-data-[side=right]:tw-rotate-180",t==="floating"||t==="inset"?"group-data-[collapsible=icon]:tw-w-[calc(var(--sidebar-width-icon)_+_theme(spacing.4))]":"group-data-[collapsible=icon]:tw-w-[--sidebar-width-icon]")}),a.jsx("div",{className:N("tw-absolute tw-inset-y-0 tw-z-10 tw-hidden tw-h-svh tw-w-[--sidebar-width] tw-transition-[left,right,width] tw-duration-200 tw-ease-linear md:tw-flex",e==="left"?"tw-left-0 group-data-[collapsible=offcanvas]:tw-left-[calc(var(--sidebar-width)*-1)]":"tw-right-0 group-data-[collapsible=offcanvas]:tw-right-[calc(var(--sidebar-width)*-1)]",t==="floating"||t==="inset"?"tw-p-2 group-data-[collapsible=icon]:tw-w-[calc(var(--sidebar-width-icon)_+_theme(spacing.4)_+2px)]":"group-data-[collapsible=icon]:tw-w-[--sidebar-width-icon] group-data-[side=left]:tw-border-r group-data-[side=right]:tw-border-l",r),...s,children:a.jsx("div",{"data-sidebar":"sidebar",className:"tw-flex tw-h-full tw-w-full tw-flex-col tw-bg-sidebar group-data-[variant=floating]:tw-rounded-lg group-data-[variant=floating]:tw-border group-data-[variant=floating]:tw-border-sidebar-border group-data-[variant=floating]:tw-shadow",children:o})})]})});qs.displayName="Sidebar";const qc=g.forwardRef(({className:e,onClick:t,...n},r)=>{const{toggleSidebar:o}=cr();return a.jsxs(fe,{ref:r,"data-sidebar":"trigger",variant:"ghost",size:"icon",className:N("tw-h-7 tw-w-7",e),onClick:s=>{t==null||t(s),o()},...n,children:[a.jsx(Q.PanelLeft,{}),a.jsx("span",{className:"tw-sr-only",children:"Toggle Sidebar"})]})});qc.displayName="SidebarTrigger";const Hc=g.forwardRef(({className:e,...t},n)=>{const{toggleSidebar:r}=cr();return a.jsx("button",{type:"button",ref:n,"data-sidebar":"rail","aria-label":"Toggle Sidebar",tabIndex:-1,onClick:r,title:"Toggle Sidebar",className:N("tw-absolute tw-inset-y-0 tw-z-20 tw-hidden tw-w-4 tw--translate-x-1/2 tw-transition-all tw-ease-linear after:tw-absolute after:tw-inset-y-0 after:tw-left-1/2 after:tw-w-[2px] hover:after:tw-bg-sidebar-border group-data-[side=left]:tw--right-4 group-data-[side=right]:tw-left-0 sm:tw-flex","[[data-side=left]_&]:tw-cursor-w-resize [[data-side=right]_&]:tw-cursor-e-resize","[[data-side=left][data-state=collapsed]_&]:tw-cursor-e-resize [[data-side=right][data-state=collapsed]_&]:tw-cursor-w-resize","group-data-[collapsible=offcanvas]:tw-translate-x-0 group-data-[collapsible=offcanvas]:after:tw-left-full group-data-[collapsible=offcanvas]:hover:tw-bg-sidebar","[[data-side=left][data-collapsible=offcanvas]_&]:tw--right-2","[[data-side=right][data-collapsible=offcanvas]_&]:tw--left-2",e),...t})});Hc.displayName="SidebarRail";const Hs=g.forwardRef(({className:e,...t},n)=>a.jsx("main",{ref:n,className:N("tw-relative tw-flex tw-flex-1 tw-flex-col tw-bg-background","peer-data-[variant=inset]:tw-min-h-[calc(100svh-theme(spacing.4))] md:peer-data-[variant=inset]:tw-m-2 md:peer-data-[state=collapsed]:peer-data-[variant=inset]:tw-ml-2 md:peer-data-[variant=inset]:tw-ml-0 md:peer-data-[variant=inset]:tw-rounded-xl md:peer-data-[variant=inset]:tw-shadow",e),...t}));Hs.displayName="SidebarInset";const Xc=g.forwardRef(({className:e,...t},n)=>a.jsx(St,{ref:n,"data-sidebar":"input",className:N("tw-h-8 tw-w-full tw-bg-background tw-shadow-none focus-visible:tw-ring-2 focus-visible:tw-ring-sidebar-ring",e),...t}));Xc.displayName="SidebarInput";const Yc=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,"data-sidebar":"header",className:N("tw-flex tw-flex-col tw-gap-2 tw-p-2",e),...t}));Yc.displayName="SidebarHeader";const Wc=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,"data-sidebar":"footer",className:N("tw-flex tw-flex-col tw-gap-2 tw-p-2",e),...t}));Wc.displayName="SidebarFooter";const Kc=g.forwardRef(({className:e,...t},n)=>a.jsx(lr,{ref:n,"data-sidebar":"separator",className:N("tw-mx-2 tw-w-auto tw-bg-sidebar-border",e),...t}));Kc.displayName="SidebarSeparator";const Xs=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,"data-sidebar":"content",className:N("tw-flex tw-min-h-0 tw-flex-1 tw-flex-col tw-gap-2 tw-overflow-auto group-data-[collapsible=icon]:tw-overflow-hidden",e),...t}));Xs.displayName="SidebarContent";const Xr=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,"data-sidebar":"group",className:N("tw-relative tw-flex tw-w-full tw-min-w-0 tw-flex-col tw-p-2",e),...t}));Xr.displayName="SidebarGroup";const Yr=g.forwardRef(({className:e,asChild:t=!1,...n},r)=>{const o=t?Ht.Slot:"div";return a.jsx(o,{ref:r,"data-sidebar":"group-label",className:N("tw-flex tw-h-8 tw-shrink-0 tw-items-center tw-rounded-md tw-px-2 tw-text-xs tw-font-medium tw-text-sidebar-foreground/70 tw-outline-none tw-ring-sidebar-ring tw-transition-[margin,opa] tw-duration-200 tw-ease-linear focus-visible:tw-ring-2 [&>svg]:tw-size-4 [&>svg]:tw-shrink-0","group-data-[collapsible=icon]:tw--mt-8 group-data-[collapsible=icon]:tw-opacity-0",e),...n})});Yr.displayName="SidebarGroupLabel";const Jc=g.forwardRef(({className:e,asChild:t=!1,...n},r)=>{const o=t?Ht.Slot:"button";return a.jsx(o,{ref:r,"data-sidebar":"group-action",className:N("tw-absolute tw-right-3 tw-top-3.5 tw-flex tw-aspect-square tw-w-5 tw-items-center tw-justify-center tw-rounded-md tw-p-0 tw-text-sidebar-foreground tw-outline-none tw-ring-sidebar-ring tw-transition-transform hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground focus-visible:tw-ring-2 [&>svg]:tw-size-4 [&>svg]:tw-shrink-0","after:tw-absolute after:tw--inset-2 after:md:tw-hidden","group-data-[collapsible=icon]:tw-hidden",e),...n})});Jc.displayName="SidebarGroupAction";const Wr=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,"data-sidebar":"group-content",className:N("tw-w-full tw-text-sm",e),...t}));Wr.displayName="SidebarGroupContent";const Ys=g.forwardRef(({className:e,...t},n)=>a.jsx("ul",{ref:n,"data-sidebar":"menu",className:N("tw-flex tw-w-full tw-min-w-0 tw-flex-col tw-gap-1",e),...t}));Ys.displayName="SidebarMenu";const Ws=g.forwardRef(({className:e,...t},n)=>a.jsx("li",{ref:n,"data-sidebar":"menu-item",className:N("tw-group/menu-item tw-relative",e),...t}));Ws.displayName="SidebarMenuItem";const Zc=Xt.cva("tw-peer/menu-button tw-flex tw-w-full tw-items-center tw-gap-2 tw-overflow-hidden tw-rounded-md tw-p-2 tw-text-left tw-text-sm tw-outline-none tw-ring-sidebar-ring tw-transition-[width,height,padding] hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground focus-visible:tw-ring-2 active:tw-bg-sidebar-accent active:tw-text-sidebar-accent-foreground disabled:tw-pointer-events-none disabled:tw-opacity-50 tw-group-has-[[data-sidebar=menu-action]]/menu-item:pr-8 aria-disabled:tw-pointer-events-none aria-disabled:tw-opacity-50 data-[active=true]:tw-font-medium data-[active=true]:tw-text-sidebar-accent-foreground data-[state=open]:hover:tw-bg-sidebar-accent data-[state=open]:hover:tw-text-sidebar-accent-foreground group-data-[collapsible=icon]:tw-!size-8 group-data-[collapsible=icon]:tw-!p-2 [&>span:last-child]:tw-truncate [&>svg]:tw-size-4 [&>svg]:tw-shrink-0",{variants:{variant:{default:"hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground",outline:"tw-bg-background tw-shadow-[0_0_0_1px_hsl(var(--sidebar-border))] hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground hover:tw-shadow-[0_0_0_1px_hsl(var(--sidebar-accent))]"},size:{default:"tw-h-8 tw-text-sm",sm:"tw-h-7 tw-text-xs",lg:"tw-h-12 tw-text-sm group-data-[collapsible=icon]:tw-!p-0"}},defaultVariants:{variant:"default",size:"default"}}),Ks=g.forwardRef(({asChild:e=!1,isActive:t=!1,variant:n="default",size:r="default",tooltip:o,className:s,...i},l)=>{const c=e?Ht.Slot:"button",{isMobile:d,state:u}=cr(),h=a.jsx(c,{ref:l,"data-sidebar":"menu-button","data-size":r,"data-active":t,className:N(Zc({variant:n,size:r}),s),...i});return o?(typeof o=="string"&&(o={children:o}),a.jsxs(Ac,{children:[a.jsx(Dc,{asChild:!0,children:h}),a.jsx(Fs,{side:"right",align:"center",hidden:u!=="collapsed"||d,...o})]})):h});Ks.displayName="SidebarMenuButton";const Qc=g.forwardRef(({className:e,asChild:t=!1,showOnHover:n=!1,...r},o)=>{const s=t?Ht.Slot:"button";return a.jsx(s,{ref:o,"data-sidebar":"menu-action",className:N("tw-peer-hover/menu-button:text-sidebar-accent-foreground tw-absolute tw-right-1 tw-top-1.5 tw-flex tw-aspect-square tw-w-5 tw-items-center tw-justify-center tw-rounded-md tw-p-0 tw-text-sidebar-foreground tw-outline-none tw-ring-sidebar-ring tw-transition-transform hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground focus-visible:tw-ring-2 [&>svg]:tw-size-4 [&>svg]:tw-shrink-0","after:tw-absolute after:tw--inset-2 after:md:tw-hidden","tw-peer-data-[size=sm]/menu-button:top-1","tw-peer-data-[size=default]/menu-button:top-1.5","tw-peer-data-[size=lg]/menu-button:top-2.5","group-data-[collapsible=icon]:tw-hidden",n&&"tw-group-focus-within/menu-item:opacity-100 tw-group-hover/menu-item:opacity-100 tw-peer-data-[active=true]/menu-button:text-sidebar-accent-foreground data-[state=open]:tw-opacity-100 md:tw-opacity-0",e),...r})});Qc.displayName="SidebarMenuAction";const ed=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,"data-sidebar":"menu-badge",className:N("tw-pointer-events-none tw-absolute tw-right-1 tw-flex tw-h-5 tw-min-w-5 tw-select-none tw-items-center tw-justify-center tw-rounded-md tw-px-1 tw-text-xs tw-font-medium tw-tabular-nums tw-text-sidebar-foreground","tw-peer-hover/menu-button:text-sidebar-accent-foreground tw-peer-data-[active=true]/menu-button:text-sidebar-accent-foreground","tw-peer-data-[size=sm]/menu-button:top-1","tw-peer-data-[size=default]/menu-button:top-1.5","tw-peer-data-[size=lg]/menu-button:top-2.5","group-data-[collapsible=icon]:tw-hidden",e),...t}));ed.displayName="SidebarMenuBadge";const td=g.forwardRef(({className:e,showIcon:t=!1,...n},r)=>{const o=g.useMemo(()=>`${Math.floor(Math.random()*40)+50}%`,[]);return a.jsxs("div",{ref:r,"data-sidebar":"menu-skeleton",className:N("tw-flex tw-h-8 tw-items-center tw-gap-2 tw-rounded-md tw-px-2",e),...n,children:[t&&a.jsx(ua,{className:"tw-size-4 tw-rounded-md","data-sidebar":"menu-skeleton-icon"}),a.jsx(ua,{className:"tw-h-4 tw-max-w-[--skeleton-width] tw-flex-1","data-sidebar":"menu-skeleton-text",style:{"--skeleton-width":o}})]})});td.displayName="SidebarMenuSkeleton";const nd=g.forwardRef(({className:e,...t},n)=>a.jsx("ul",{ref:n,"data-sidebar":"menu-sub",className:N("tw-mx-3.5 tw-flex tw-min-w-0 tw-translate-x-px tw-flex-col tw-gap-1 tw-border-l tw-border-sidebar-border tw-px-2.5 tw-py-0.5","group-data-[collapsible=icon]:tw-hidden",e),...t}));nd.displayName="SidebarMenuSub";const rd=g.forwardRef(({...e},t)=>a.jsx("li",{ref:t,...e}));rd.displayName="SidebarMenuSubItem";const od=g.forwardRef(({asChild:e=!1,size:t="md",isActive:n,className:r,...o},s)=>{const i=e?Ht.Slot:"a";return a.jsx(i,{ref:s,"data-sidebar":"menu-sub-button","data-size":t,"data-active":n,className:N("tw-flex tw-h-7 tw-min-w-0 tw--translate-x-px tw-items-center tw-gap-2 tw-overflow-hidden tw-rounded-md tw-px-2 tw-text-sidebar-foreground tw-outline-none tw-ring-sidebar-ring hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground focus-visible:tw-ring-2 active:tw-bg-sidebar-accent active:tw-text-sidebar-accent-foreground disabled:tw-pointer-events-none disabled:tw-opacity-50 aria-disabled:tw-pointer-events-none aria-disabled:tw-opacity-50 [&>span:last-child]:tw-truncate [&>svg]:tw-size-4 [&>svg]:tw-shrink-0 [&>svg]:tw-text-sidebar-accent-foreground","data-[active=true]:tw-bg-sidebar-accent data-[active=true]:tw-text-sidebar-accent-foreground",t==="sm"&&"tw-text-xs",t==="md"&&"tw-text-sm","group-data-[collapsible=icon]:tw-hidden",r),...o})});od.displayName="SidebarMenuSubButton";function Js({id:e,extensionLabels:t,projectOptions:n,handleSelectSidebarItem:r,selectedSidebarItem:o}){const s=g.useCallback((c,d)=>{r(c,d)},[r]),i=g.useCallback(c=>{const d=n.find(u=>u.projectId===c);return d?d.projectName:c},[n]),l=g.useCallback(c=>!o.projectId&&c===o.label,[o]);return a.jsx(qs,{id:e,collapsible:"none",variant:"inset",className:"tw-w-96 tw-gap-2 tw-overflow-y-auto tw-rounded tw-bg-slate-100",children:a.jsxs(Xs,{children:[a.jsxs(Xr,{children:[a.jsx(Yr,{className:"tw-text-sm tw-text-gray-400",children:"Extensions"}),a.jsx(Wr,{children:a.jsx(Ys,{children:t.map(c=>a.jsx(Ws,{children:a.jsx(Ks,{className:N("tw-rounded tw-py-2 tw-text-sm tw-text-gray-500 hover:tw-bg-white hover:tw-text-gray-900 hover:tw-shadow-sm active:tw-bg-white",{"tw-bg-white tw-text-gray-900 tw-shadow-sm":l(c)}),onClick:()=>s(c,void 0),isActive:l(c),children:a.jsx("span",{className:"tw-pl-3",children:c})})},c))})})]}),a.jsxs(Xr,{children:[a.jsx(Yr,{className:"tw-text-sm tw-text-gray-400",children:"Projects"}),a.jsx(Wr,{className:"tw-pl-3",children:a.jsx(Wn,{popoverContentClassName:"tw-z-[1000]",options:n.flatMap(c=>c.projectId),getOptionLabel:c=>i(c),buttonPlaceholder:"Type or select project",onChange:c=>{const d=i(c);s(d,c)},value:(o==null?void 0:o.projectId)??void 0})})]})]})})}function ad({id:e,direction:t="ltr",extensionLabels:n,projectOptions:r,children:o,handleSelectSidebarItem:s,selectedSidebarItem:i,onSearch:l}){return a.jsxs("div",{className:"tw-h-full tw-p-3",children:[a.jsx("div",{className:"tw-flex tw-items-center tw-justify-center tw-py-4",children:a.jsx(ho,{className:"tw-w-9/12",onSearch:l,placeholder:"Search app settings, extension settings, and project settings"})}),a.jsxs(Us,{dir:t,id:e,className:"tw-gap-4",children:[a.jsx(Js,{extensionLabels:n,projectOptions:r,handleSelectSidebarItem:s,selectedSidebarItem:i}),a.jsx(Hs,{className:"tw-overflow-y-auto",children:o})]})]})}const rt="scrBook",sd="scrRef",pt="source",id="details",ld="Scripture Reference",cd="Scripture Book",Zs="Type",dd="Details";function ud(e,t){const n=t??!1;return[{accessorFn:r=>`${ae.bookNumberToId(r.start.bookNum)} ${r.start.chapterNum}:${r.start.verseNum}`,id:rt,header:(e==null?void 0:e.scriptureReferenceColumnName)??ld,cell:r=>{const o=r.row.original;return r.row.getIsGrouped()?ae.bookNumberToEnglishName(o.start.bookNum):r.row.groupingColumnId===rt?W.formatScrRef(o.start):void 0},getGroupingValue:r=>r.start.bookNum,sortingFn:(r,o)=>W.compareScrRefs(r.original.start,o.original.start),enableGrouping:!0},{accessorFn:r=>W.formatScrRef(r.start),id:sd,header:void 0,cell:r=>{const o=r.row.original;return r.row.getIsGrouped()?void 0:W.formatScrRef(o.start)},sortingFn:(r,o)=>W.compareScrRefs(r.original.start,o.original.start),enableGrouping:!1},{accessorFn:r=>r.source.displayName,id:pt,header:n?(e==null?void 0:e.typeColumnName)??Zs:void 0,cell:r=>n||r.row.getIsGrouped()?r.getValue():void 0,getGroupingValue:r=>r.source.id,sortingFn:(r,o)=>r.original.source.displayName.localeCompare(o.original.source.displayName),enableGrouping:!0},{accessorFn:r=>r.detail,id,header:(e==null?void 0:e.detailsColumnName)??dd,cell:r=>r.getValue(),enableGrouping:!1}]}const pd=e=>{if(!("offset"in e.start))throw new Error("No offset available in range start");if(e.end&&!("offset"in e.end))throw new Error("No offset available in range end");const{offset:t}=e.start;let n=0;return e.end&&({offset:n}=e.end),!e.end||W.compareScrRefs(e.start,e.end)===0?`${W.scrRefToBBBCCCVVV(e.start)}+${t}`:`${W.scrRefToBBBCCCVVV(e.start)}+${t}-${W.scrRefToBBBCCCVVV(e.end)}+${n}`},pa=e=>`${pd({start:e.start,end:e.end})} ${e.source.displayName} ${e.detail}`;function wd({sources:e,showColumnHeaders:t=!1,showSourceColumn:n=!1,scriptureReferenceColumnName:r,scriptureBookGroupName:o,typeColumnName:s,detailsColumnName:i,onRowSelected:l,direction:c="ltr"}){const[d,u]=g.useState([]),[h,w]=g.useState([{id:rt,desc:!1}]),[b,x]=g.useState({}),f=g.useMemo(()=>e.flatMap(C=>C.data.map(_=>({..._,source:C.source}))),[e]),m=g.useMemo(()=>ud({scriptureReferenceColumnName:r,typeColumnName:s,detailsColumnName:i},n),[r,s,i,n]);g.useEffect(()=>{d.includes(pt)?w([{id:pt,desc:!1},{id:rt,desc:!1}]):w([{id:rt,desc:!1}])},[d]);const S=Se.useReactTable({data:f,columns:m,state:{grouping:d,sorting:h,rowSelection:b},onGroupingChange:u,onSortingChange:w,onRowSelectionChange:x,getExpandedRowModel:Se.getExpandedRowModel(),getGroupedRowModel:Se.getGroupedRowModel(),getCoreRowModel:Se.getCoreRowModel(),getSortedRowModel:Se.getSortedRowModel(),getRowId:pa,autoResetExpanded:!1,enableMultiRowSelection:!1,enableSubRowSelection:!1});g.useEffect(()=>{if(l){const C=S.getSelectedRowModel().rowsById,_=Object.keys(C);if(_.length===1){const k=f.find(A=>pa(A)===_[0])||void 0;k&&l(k)}}},[b,f,l,S]);const R=o??cd,j=s??Zs,E=[{label:"No Grouping",value:[]},{label:`Group by ${R}`,value:[rt]},{label:`Group by ${j}`,value:[pt]},{label:`Group by ${R} and ${j}`,value:[rt,pt]},{label:`Group by ${j} and ${R}`,value:[pt,rt]}],v=C=>{u(JSON.parse(C))},P=(C,_)=>{!C.getIsGrouped()&&!C.getIsSelected()&&C.getToggleSelectedHandler()(_)},V=(C,_)=>C.getIsGrouped()?"":N("banded-row",_%2===0?"even":"odd"),U=(C,_,k)=>{if(!((C==null?void 0:C.length)===0||_.depth{v(C)},children:[a.jsx(bt,{className:"tw-mb-1 tw-mt-2",children:a.jsx(Bt,{})}),a.jsx(vt,{position:"item-aligned",children:a.jsx(Ts,{children:E.map(C=>a.jsx(De,{value:JSON.stringify(C.value),children:C.label},C.label))})})]}),a.jsxs(Cn,{className:"tw-relative tw-flex tw-flex-col tw-overflow-y-auto tw-p-0",children:[t&&a.jsx(Tn,{children:S.getHeaderGroups().map(C=>a.jsx(Ze,{children:C.headers.filter(_=>_.column.columnDef.header).map(_=>a.jsx(Vt,{colSpan:_.colSpan,className:"top-0 tw-sticky",children:_.isPlaceholder?void 0:a.jsxs("div",{children:[_.column.getCanGroup()?a.jsx(fe,{variant:"ghost",title:`Toggle grouping by ${_.column.columnDef.header}`,onClick:_.column.getToggleGroupingHandler(),type:"button",children:_.column.getIsGrouped()?"🛑":"👊 "}):void 0," ",Se.flexRender(_.column.columnDef.header,_.getContext())]})},_.id))},C.id))}),a.jsx(Rn,{children:S.getRowModel().rows.map((C,_)=>a.jsx(Ze,{"data-state":C.getIsSelected()?"selected":"",className:N(V(C,_)),onClick:k=>P(C,k),children:C.getVisibleCells().map(k=>{if(!(k.getIsPlaceholder()||k.column.columnDef.enableGrouping&&!k.getIsGrouped()&&(k.column.columnDef.id!==pt||!n)))return a.jsx(xt,{className:N(k.column.columnDef.id,"tw-p-[1px]",U(d,C,k)),children:(()=>k.getIsGrouped()?a.jsxs(fe,{variant:"link",onClick:C.getToggleExpandedHandler(),type:"button",children:[C.getIsExpanded()&&a.jsx(Q.ChevronDown,{}),!C.getIsExpanded()&&(c==="ltr"?a.jsx(Q.ChevronRight,{}):a.jsx(Q.ChevronLeft,{}))," ",Se.flexRender(k.column.columnDef.cell,k.getContext())," (",C.subRows.length,")"]}):Se.flexRender(k.column.columnDef.cell,k.getContext()))()},k.id)})},C.id))})]})]})}const _r={[W.getLocalizeKeyForScrollGroupId("undefined")]:"Ø",[W.getLocalizeKeyForScrollGroupId(0)]:"A",[W.getLocalizeKeyForScrollGroupId(1)]:"B",[W.getLocalizeKeyForScrollGroupId(2)]:"C",[W.getLocalizeKeyForScrollGroupId(3)]:"D",[W.getLocalizeKeyForScrollGroupId(4)]:"E",[W.getLocalizeKeyForScrollGroupId(5)]:"F",[W.getLocalizeKeyForScrollGroupId(6)]:"G",[W.getLocalizeKeyForScrollGroupId(7)]:"H",[W.getLocalizeKeyForScrollGroupId(8)]:"I",[W.getLocalizeKeyForScrollGroupId(9)]:"J",[W.getLocalizeKeyForScrollGroupId(10)]:"K",[W.getLocalizeKeyForScrollGroupId(11)]:"L",[W.getLocalizeKeyForScrollGroupId(12)]:"M",[W.getLocalizeKeyForScrollGroupId(13)]:"N",[W.getLocalizeKeyForScrollGroupId(14)]:"O",[W.getLocalizeKeyForScrollGroupId(15)]:"P",[W.getLocalizeKeyForScrollGroupId(16)]:"Q",[W.getLocalizeKeyForScrollGroupId(17)]:"R",[W.getLocalizeKeyForScrollGroupId(18)]:"S",[W.getLocalizeKeyForScrollGroupId(19)]:"T",[W.getLocalizeKeyForScrollGroupId(20)]:"U",[W.getLocalizeKeyForScrollGroupId(21)]:"V",[W.getLocalizeKeyForScrollGroupId(22)]:"W",[W.getLocalizeKeyForScrollGroupId(23)]:"X",[W.getLocalizeKeyForScrollGroupId(24)]:"Y",[W.getLocalizeKeyForScrollGroupId(25)]:"Z"};function fd({availableScrollGroupIds:e,scrollGroupId:t,onChangeScrollGroupId:n,localizedStrings:r={}}){const o={..._r,...Object.fromEntries(Object.entries(r).map(([s,i])=>[s,s===i&&s in _r?_r[s]:i]))};return a.jsxs(Dt,{value:`${t}`,onValueChange:s=>n(s==="undefined"?void 0:parseInt(s,10)),children:[a.jsx(bt,{className:"pr-twp tw-w-auto",children:a.jsx(Bt,{placeholder:o[W.getLocalizeKeyForScrollGroupId(t)]??t})}),a.jsx(vt,{style:{zIndex:250},children:e.map(s=>a.jsx(De,{value:`${s}`,children:o[W.getLocalizeKeyForScrollGroupId(s)]},`${s}`))})]})}function md({children:e}){return a.jsx("div",{className:"pr-twp tw-grid",children:e})}function hd({primary:e,secondary:t,children:n,isLoading:r=!1,loadingMessage:o}){return a.jsxs("div",{className:"tw-flex tw-items-center tw-justify-between tw-space-x-4 tw-py-2",children:[a.jsxs("div",{children:[a.jsx("p",{className:"tw-text-sm tw-font-medium tw-leading-none",children:e}),a.jsx("p",{className:"tw-whitespace-normal tw-break-words tw-text-sm tw-text-muted-foreground",children:t})]}),r?a.jsx("p",{className:"tw-text-sm tw-text-muted-foreground",children:o}):a.jsx("div",{children:n})]})}function gd({primary:e,secondary:t,includeSeparator:n=!1}){return a.jsxs("div",{className:"tw-space-y-4 tw-py-2",children:[a.jsxs("div",{children:[a.jsx("h3",{className:"tw-text-lg tw-font-medium",children:e}),a.jsx("p",{className:"tw-text-sm tw-text-muted-foreground",children:t})]}),n?a.jsx(lr,{}):""]})}const xo=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,className:N("pr-twp tw-rounded-lg tw-border tw-bg-card tw-text-card-foreground tw-shadow-sm",e),...t}));xo.displayName="Card";const yo=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,className:N("pr-twp tw-flex tw-flex-col tw-space-y-1.5 tw-p-6",e),...t}));yo.displayName="CardHeader";const No=g.forwardRef(({className:e,...t},n)=>a.jsx("h3",{ref:n,className:N("pr-twp tw-text-2xl tw-font-semibold tw-leading-none tw-tracking-tight",e),...t,children:t.children}));No.displayName="CardTitle";const ko=g.forwardRef(({className:e,...t},n)=>a.jsx("p",{ref:n,className:N("pr-twp tw-text-sm tw-text-muted-foreground",e),...t}));ko.displayName="CardDescription";const So=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,className:N("pr-twp tw-p-6 tw-pt-0",e),...t}));So.displayName="CardContent";const Qs=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,className:N("pr-twp tw-flex tw-items-center tw-p-6 tw-pt-0",e),...t}));Qs.displayName="CardFooter";function bd({id:e,settingsGroupLabel:t,settingsGroupDescription:n,children:r}){return a.jsxs(xo,{id:e,children:[a.jsxs(yo,{children:[a.jsx(No,{children:t}),n&&a.jsx(ko,{children:n})]}),a.jsx(So,{children:r})]})}function vd({id:e,className:t,listItems:n,selectedListItems:r,handleSelectListItem:o,createLabel:s}){return a.jsx("div",{id:e,className:t,children:n.map(i=>a.jsxs("div",{className:"tw-m-2 tw-flex tw-items-center",children:[a.jsx(sr,{className:"tw-mr-2 tw-align-middle",checked:r.includes(i),onCheckedChange:l=>o(i,l)}),a.jsx(qe,{children:s?s(i):i})]},i))})}function xd(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}function yd(e){if(e.__esModule)return e;var t=e.default;if(typeof t=="function"){var n=function r(){return this instanceof r?Reflect.construct(t,arguments,this.constructor):t.apply(this,arguments)};n.prototype=t.prototype}else n={};return Object.defineProperty(n,"__esModule",{value:!0}),Object.keys(e).forEach(function(r){var o=Object.getOwnPropertyDescriptor(e,r);Object.defineProperty(n,r,o.get?o:{enumerable:!0,get:function(){return e[r]}})}),n}var Eo={},ei={exports:{}};(function(e){function t(n){return n&&n.__esModule?n:{default:n}}e.exports=t,e.exports.__esModule=!0,e.exports.default=e.exports})(ei);var Nd=ei.exports,Pr={};function jo(e,t){return process.env.NODE_ENV==="production"?()=>null:function(...r){return e(...r)||t(...r)}}function O(){return O=Object.assign?Object.assign.bind():function(e){for(var t=1;t{t[n]=ti(e[n])}),t}function Qe(e,t,n={clone:!0}){const r=n.clone?O({},e):e;return mt(e)&&mt(t)&&Object.keys(t).forEach(o=>{o!=="__proto__"&&(mt(t[o])&&o in e&&mt(e[o])?r[o]=Qe(e[o],t[o],n):n.clone?r[o]=mt(t[o])?ti(t[o]):t[o]:r[o]=t[o])}),r}var Kr={exports:{}},zn={exports:{}},ie={};/** @license React v16.13.1 +"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const a=require("react/jsx-runtime"),g=require("react"),Q=require("lucide-react"),ot=require("clsx"),ml=require("tailwind-merge"),Za=require("@radix-ui/react-dropdown-menu"),W=require("platform-bible-utils"),Ht=require("@radix-ui/react-slot"),Xt=require("class-variance-authority"),hl=require("@radix-ui/react-label"),gl=require("@radix-ui/react-radio-group"),bl=require("@radix-ui/react-popover"),Re=require("cmdk"),vl=require("@radix-ui/react-dialog"),Se=require("@tanstack/react-table"),xl=require("@radix-ui/react-select"),yl=require("@radix-ui/react-checkbox"),Nl=require("@radix-ui/react-toggle-group"),kl=require("@radix-ui/react-toggle"),Sl=require("@radix-ui/react-tabs"),El=require("@radix-ui/react-separator"),jl=require("@radix-ui/react-tooltip"),Gr=require("@mui/styled-engine"),Me=require("@mui/material"),ln=require("react-dom"),Qa=require("sonner"),Cl=require("@radix-ui/react-slider"),Tl=require("@radix-ui/react-switch"),Rl=require("markdown-to-jsx");function ke(e){const t=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(e){for(const n in e)if(n!=="default"){const r=Object.getOwnPropertyDescriptor(e,n);Object.defineProperty(t,n,r.get?r:{enumerable:!0,get:()=>e[n]})}}return t.default=e,Object.freeze(t)}const M=ke(g),pe=ke(Za),es=ke(hl),bn=ke(gl),vn=ke(bl),be=ke(vl),ge=ke(xl),Ur=ke(yl),rr=ke(Nl),ts=ke(kl),Oe=ke(Sl),ns=ke(El),Sn=ke(jl),Ol=ke(ln),cn=ke(Cl),qr=ke(Tl);const _l=ml.extendTailwindMerge({prefix:"tw-"});function N(...e){return _l(ot.clsx(e))}const St=g.forwardRef(({className:e,type:t,...n},r)=>a.jsx("input",{type:t,className:N("pr-twp tw-flex tw-h-10 tw-rounded-md tw-border tw-border-input tw-bg-background tw-px-3 tw-py-2 tw-text-sm tw-ring-offset-background file:tw-border-0 file:tw-bg-transparent file:tw-text-sm file:tw-font-medium file:tw-text-foreground placeholder:tw-text-muted-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-cursor-not-allowed disabled:tw-opacity-50",e),ref:r,...n}));St.displayName="Input";const Pl=g.forwardRef(({handleSearch:e,handleKeyDown:t,handleOnClick:n,handleSubmit:r,...o},s)=>a.jsxs("div",{className:"tw-relative",children:[a.jsx(St,{...o,type:"text",className:"tw-box-border tw-gap-2.5 tw-rounded-lg tw-border tw-border-solid tw-bg-background tw-py-2 tw-pl-4 tw-pr-3 tw-font-medium tw-shadow-none tw-outline-none",onChange:i=>e(i.target.value),onKeyDown:i=>{i.key==="Enter"&&r(),t(i)},onClick:n,ref:s}),a.jsx(Q.History,{className:"tw-absolute tw-right-3 tw-top-1/2 tw-h-4 tw-w-4 tw--translate-y-1/2 tw-transform tw-cursor-pointer tw-text-muted-foreground",onClick:()=>{console.log("back in history")}})]}));var Il=Object.defineProperty,Ml=(e,t,n)=>t in e?Il(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,ne=(e,t,n)=>Ml(e,typeof t!="symbol"?t+"":t,n);const gt=["GEN","EXO","LEV","NUM","DEU","JOS","JDG","RUT","1SA","2SA","1KI","2KI","1CH","2CH","EZR","NEH","EST","JOB","PSA","PRO","ECC","SNG","ISA","JER","LAM","EZK","DAN","HOS","JOL","AMO","OBA","JON","MIC","NAM","HAB","ZEP","HAG","ZEC","MAL","MAT","MRK","LUK","JHN","ACT","ROM","1CO","2CO","GAL","EPH","PHP","COL","1TH","2TH","1TI","2TI","TIT","PHM","HEB","JAS","1PE","2PE","1JN","2JN","3JN","JUD","REV","TOB","JDT","ESG","WIS","SIR","BAR","LJE","S3Y","SUS","BEL","1MA","2MA","3MA","4MA","1ES","2ES","MAN","PS2","ODA","PSS","JSA","JDB","TBS","SST","DNT","BLT","XXA","XXB","XXC","XXD","XXE","XXF","XXG","FRT","BAK","OTH","3ES","EZA","5EZ","6EZ","INT","CNC","GLO","TDX","NDX","DAG","PS3","2BA","LBA","JUB","ENO","1MQ","2MQ","3MQ","REP","4BA","LAO"],ao=["XXA","XXB","XXC","XXD","XXE","XXF","XXG","FRT","BAK","OTH","INT","CNC","GLO","TDX","NDX"],rs=["Genesis","Exodus","Leviticus","Numbers","Deuteronomy","Joshua","Judges","Ruth","1 Samuel","2 Samuel","1 Kings","2 Kings","1 Chronicles","2 Chronicles","Ezra","Nehemiah","Esther (Hebrew)","Job","Psalms","Proverbs","Ecclesiastes","Song of Songs","Isaiah","Jeremiah","Lamentations","Ezekiel","Daniel (Hebrew)","Hosea","Joel","Amos","Obadiah","Jonah","Micah","Nahum","Habakkuk","Zephaniah","Haggai","Zechariah","Malachi","Matthew","Mark","Luke","John","Acts","Romans","1 Corinthians","2 Corinthians","Galatians","Ephesians","Philippians","Colossians","1 Thessalonians","2 Thessalonians","1 Timothy","2 Timothy","Titus","Philemon","Hebrews","James","1 Peter","2 Peter","1 John","2 John","3 John","Jude","Revelation","Tobit","Judith","Esther Greek","Wisdom of Solomon","Sirach (Ecclesiasticus)","Baruch","Letter of Jeremiah","Song of 3 Young Men","Susanna","Bel and the Dragon","1 Maccabees","2 Maccabees","3 Maccabees","4 Maccabees","1 Esdras (Greek)","2 Esdras (Latin)","Prayer of Manasseh","Psalm 151","Odes","Psalms of Solomon","Joshua A. *obsolete*","Judges B. *obsolete*","Tobit S. *obsolete*","Susanna Th. *obsolete*","Daniel Th. *obsolete*","Bel Th. *obsolete*","Extra A","Extra B","Extra C","Extra D","Extra E","Extra F","Extra G","Front Matter","Back Matter","Other Matter","3 Ezra *obsolete*","Apocalypse of Ezra","5 Ezra (Latin Prologue)","6 Ezra (Latin Epilogue)","Introduction","Concordance ","Glossary ","Topical Index","Names Index","Daniel Greek","Psalms 152-155","2 Baruch (Apocalypse)","Letter of Baruch","Jubilees","Enoch","1 Meqabyan","2 Meqabyan","3 Meqabyan","Reproof (Proverbs 25-31)","4 Baruch (Rest of Baruch)","Laodiceans"],ra=Ul();function Yt(e,t=!0){return t&&(e=e.toUpperCase()),e in ra?ra[e]:0}function so(e){return Yt(e)>0}function $l(e){const t=typeof e=="string"?Yt(e):e;return t>=40&&t<=66}function Dl(e){return(typeof e=="string"?Yt(e):e)<=39}function os(e){return e<=66}function Al(e){const t=typeof e=="string"?Yt(e):e;return is(t)&&!os(t)}function*Bl(){for(let e=1;e<=gt.length;e++)yield e}const Vl=1,as=gt.length;function zl(){return["XXA","XXB","XXC","XXD","XXE","XXF","XXG"]}function io(e,t="***"){const n=e-1;return n<0||n>=gt.length?t:gt[n]}function ss(e){return e<=0||e>as?"******":rs[e-1]}function Ll(e){return ss(Yt(e))}function is(e){const t=typeof e=="number"?io(e):e;return so(t)&&!ao.includes(t)}function Fl(e){const t=typeof e=="number"?io(e):e;return so(t)&&ao.includes(t)}function Gl(e){return rs[e-1].includes("*obsolete*")}function Ul(){const e={};for(let t=0;t(e[e.Unknown=0]="Unknown",e[e.Original=1]="Original",e[e.Septuagint=2]="Septuagint",e[e.Vulgate=3]="Vulgate",e[e.English=4]="English",e[e.RussianProtestant=5]="RussianProtestant",e[e.RussianOrthodox=6]="RussianOrthodox",e))(He||{});const Pe=class{constructor(t){if(ne(this,"name"),ne(this,"fullPath"),ne(this,"isPresent"),ne(this,"hasVerseSegments"),ne(this,"isCustomized"),ne(this,"baseVersification"),ne(this,"scriptureBooks"),ne(this,"_type"),t==null)throw new Error("Argument undefined");typeof t=="string"?(this.name=t,this._type=He[t]):(this._type=t,this.name=He[t])}get type(){return this._type}equals(t){return!t.type||!this.type?!1:t.type===this.type}};ne(Pe,"Original",new Pe(He.Original)),ne(Pe,"Septuagint",new Pe(He.Septuagint)),ne(Pe,"Vulgate",new Pe(He.Vulgate)),ne(Pe,"English",new Pe(He.English)),ne(Pe,"RussianProtestant",new Pe(He.RussianProtestant)),ne(Pe,"RussianOrthodox",new Pe(He.RussianOrthodox));let ut=Pe;function oa(e,t){const n=t[0];for(let r=1;r(e[e.Valid=0]="Valid",e[e.UnknownVersification=1]="UnknownVersification",e[e.OutOfRange=2]="OutOfRange",e[e.VerseOutOfOrder=3]="VerseOutOfOrder",e[e.VerseRepeated=4]="VerseRepeated",e))(ls||{});const je=class re{constructor(t,n,r,o){if(ne(this,"firstChapter"),ne(this,"lastChapter"),ne(this,"lastVerse"),ne(this,"hasSegmentsDefined"),ne(this,"text"),ne(this,"BBBCCCVVVS"),ne(this,"longHashCode"),ne(this,"versification"),ne(this,"rtlMark","‏"),ne(this,"_bookNum",0),ne(this,"_chapterNum",0),ne(this,"_verseNum",0),ne(this,"_verse"),r==null&&o==null)if(t!=null&&typeof t=="string"){const s=t,i=n!=null&&n instanceof ut?n:void 0;this.setEmpty(i),this.parse(s)}else if(t!=null&&typeof t=="number"){const s=n!=null&&n instanceof ut?n:void 0;this.setEmpty(s),this._verseNum=t%re.chapterDigitShifter,this._chapterNum=Math.floor(t%re.bookDigitShifter/re.chapterDigitShifter),this._bookNum=Math.floor(t/re.bookDigitShifter)}else if(n==null)if(t!=null&&t instanceof re){const s=t;this._bookNum=s.bookNum,this._chapterNum=s.chapterNum,this._verseNum=s.verseNum,this._verse=s.verse,this.versification=s.versification}else{if(t==null)return;const s=t instanceof ut?t:re.defaultVersification;this.setEmpty(s)}else throw new Error("VerseRef constructor not supported.");else if(t!=null&&n!=null&&r!=null)if(typeof t=="string"&&typeof n=="string"&&typeof r=="string")this.setEmpty(o),this.updateInternal(t,n,r);else if(typeof t=="number"&&typeof n=="number"&&typeof r=="number")this._bookNum=t,this._chapterNum=n,this._verseNum=r,this.versification=o??re.defaultVersification;else throw new Error("VerseRef constructor not supported.");else throw new Error("VerseRef constructor not supported.")}static isVerseParseable(t){return t.length>0&&"0123456789".includes(t[0])&&!t.endsWith(this.verseRangeSeparator)&&!t.endsWith(this.verseSequenceIndicator)}static tryParse(t){let n;try{return n=new re(t),{success:!0,verseRef:n}}catch(r){if(r instanceof nn)return n=new re,{success:!1,verseRef:n};throw r}}static getBBBCCCVVV(t,n,r){return t%re.bcvMaxValue*re.bookDigitShifter+(n>=0?n%re.bcvMaxValue*re.chapterDigitShifter:0)+(r>=0?r%re.bcvMaxValue:0)}static fromJSON(t){const{book:n,chapterNum:r,verseNum:o,verse:s,versificationStr:i}=t,l=s||o.toString();let c;return i&&(c=new ut(i)),n?new re(n,r.toString(),l,c):new re}static tryGetVerseNum(t){let n;if(!t)return n=-1,{success:!0,vNum:n};n=0;let r;for(let o=0;o"9")return o===0&&(n=-1),{success:!1,vNum:n};if(n=n*10+ +r-0,n>re.bcvMaxValue)return n=-1,{success:!1,vNum:n}}return{success:!0,vNum:n}}get isDefault(){return this.bookNum===0&&this.chapterNum===0&&this.verseNum===0&&this.versification==null}get hasMultiple(){return this._verse!=null&&(this._verse.includes(re.verseRangeSeparator)||this._verse.includes(re.verseSequenceIndicator))}get book(){return ae.bookNumberToId(this.bookNum,"")}set book(t){this.bookNum=ae.bookIdToNumber(t)}get chapter(){return this.isDefault||this._chapterNum<0?"":this._chapterNum.toString()}set chapter(t){const n=+t;this._chapterNum=Number.isInteger(n)?n:-1}get verse(){return this._verse!=null?this._verse:this.isDefault||this._verseNum<0?"":this._verseNum.toString()}set verse(t){const{success:n,vNum:r}=re.tryGetVerseNum(t);this._verse=n?void 0:t.replace(this.rtlMark,""),this._verseNum=r,!(this._verseNum>=0)&&({vNum:this._verseNum}=re.tryGetVerseNum(this._verse))}get bookNum(){return this._bookNum}set bookNum(t){if(t<=0||t>ae.lastBook)throw new nn("BookNum must be greater than zero and less than or equal to last book");this._bookNum=t}get chapterNum(){return this._chapterNum}set chapterNum(t){this.chapterNum=t}get verseNum(){return this._verseNum}set verseNum(t){this._verseNum=t}get versificationStr(){var t;return(t=this.versification)==null?void 0:t.name}set versificationStr(t){this.versification=this.versification!=null?new ut(t):void 0}get valid(){return this.validStatus===0}get validStatus(){return this.validateVerse(re.verseRangeSeparators,re.verseSequenceIndicators)}get BBBCCC(){return re.getBBBCCCVVV(this._bookNum,this._chapterNum,0)}get BBBCCCVVV(){return re.getBBBCCCVVV(this._bookNum,this._chapterNum,this._verseNum)}get isExcluded(){return!1}parse(t){if(t=t.replace(this.rtlMark,""),t.includes("/")){const s=t.split("/");if(t=s[0],s.length>1)try{const i=+s[1].trim();this.versification=new ut(He[i])}catch{throw new nn("Invalid reference : "+t)}}const n=t.trim().split(" ");if(n.length!==2)throw new nn("Invalid reference : "+t);const r=n[1].split(":"),o=+r[0];if(r.length!==2||ae.bookIdToNumber(n[0])===0||!Number.isInteger(o)||o<0||!re.isVerseParseable(r[1]))throw new nn("Invalid reference : "+t);this.updateInternal(n[0],r[0],r[1])}simplify(){this._verse=void 0}clone(){return new re(this)}toString(){const t=this.book;return t===""?"":`${t} ${this.chapter}:${this.verse}`}toJSON(){let t=this.verse;(t===""||t===this.verseNum.toString())&&(t=void 0);const n={book:this.book,chapterNum:this.chapterNum,verseNum:this.verseNum,verse:t,versificationStr:this.versificationStr};return t||delete n.verse,n}equals(t){return t instanceof re?t._bookNum===this._bookNum&&t._chapterNum===this._chapterNum&&t._verseNum===this._verseNum&&t.verse===this.verse&&(t.versification==null&&this.versification==null||t.versification!=null&&this.versification!=null&&t.versification.equals(this.versification)):!1}allVerses(t=!1,n=re.verseRangeSeparators,r=re.verseSequenceIndicators){if(this._verse==null||this.chapterNum<=0)return[this.clone()];const o=[],s=oa(this._verse,r);for(const i of s.map(l=>oa(l,n))){const l=this.clone();l.verse=i[0];const c=l.verseNum;if(o.push(l),i.length>1){const d=this.clone();if(d.verse=i[1],!t)for(let u=c+1;ui)return 3;if(r===i)return 4;r=i}return 0}get internalValid(){return this.versification==null?1:this._bookNum<=0||this._bookNum>ae.lastBook?2:(ae.isCanonical(this._bookNum),0)}setEmpty(t=re.defaultVersification){this._bookNum=0,this._chapterNum=-1,this._verse=void 0,this.versification=t}updateInternal(t,n,r){this.bookNum=ae.bookIdToNumber(t),this.chapter=n,this.verse=r}};ne(je,"defaultVersification",ut.English),ne(je,"verseRangeSeparator","-"),ne(je,"verseSequenceIndicator",","),ne(je,"verseRangeSeparators",[je.verseRangeSeparator]),ne(je,"verseSequenceIndicators",[je.verseSequenceIndicator]),ne(je,"chapterDigitShifter",1e3),ne(je,"bookDigitShifter",je.chapterDigitShifter*je.chapterDigitShifter),ne(je,"bcvMaxValue",je.chapterDigitShifter-1),ne(je,"ValidStatusType",ls);class nn extends Error{}const or=pe.Root,lo=pe.Trigger,cs=pe.Group,ql=pe.Portal,Hl=pe.Sub,Xl=pe.RadioGroup,ds=g.forwardRef(({className:e,inset:t,children:n,...r},o)=>a.jsxs(pe.SubTrigger,{ref:o,className:N("tw-flex tw-cursor-default tw-select-none tw-items-center tw-rounded-sm tw-px-2 tw-py-1.5 tw-text-sm tw-outline-none focus:tw-bg-accent data-[state=open]:tw-bg-accent",t&&"tw-pl-8",e),...r,children:[n,a.jsx(Q.ChevronRight,{className:"tw-ml-auto tw-h-4 tw-w-4"})]}));ds.displayName=pe.SubTrigger.displayName;const us=g.forwardRef(({className:e,...t},n)=>a.jsx(pe.SubContent,{ref:n,className:N("tw-z-50 tw-min-w-[8rem] tw-overflow-hidden tw-rounded-md tw-border tw-bg-popover tw-p-1 tw-text-popover-foreground tw-shadow-lg data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0 data-[state=closed]:tw-zoom-out-95 data-[state=open]:tw-zoom-in-95 data-[side=bottom]:tw-slide-in-from-top-2 data-[side=left]:tw-slide-in-from-right-2 data-[side=right]:tw-slide-in-from-left-2 data-[side=top]:tw-slide-in-from-bottom-2",e),...t}));us.displayName=pe.SubContent.displayName;const En=g.forwardRef(({className:e,sideOffset:t=4,...n},r)=>a.jsx(pe.Portal,{children:a.jsx(pe.Content,{ref:r,sideOffset:t,className:N("pr-twp tw-z-50 tw-min-w-[8rem] tw-overflow-hidden tw-rounded-md tw-border tw-bg-popover tw-p-1 tw-text-popover-foreground tw-shadow-md data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0 data-[state=closed]:tw-zoom-out-95 data-[state=open]:tw-zoom-in-95 data-[side=bottom]:tw-slide-in-from-top-2 data-[side=left]:tw-slide-in-from-right-2 data-[side=right]:tw-slide-in-from-left-2 data-[side=top]:tw-slide-in-from-bottom-2",e),...n})}));En.displayName=pe.Content.displayName;const co=g.forwardRef(({className:e,inset:t,...n},r)=>a.jsx(pe.Item,{ref:r,className:N("tw-cursor-default tw-select-none tw-items-center tw-rounded-sm tw-px-2 tw-py-1.5 tw-text-sm tw-outline-none tw-transition-colors focus:tw-bg-accent data-[disabled]:tw-pointer-events-none data-[disabled]:tw-opacity-50",t&&"tw-pl-8",e),...n}));co.displayName=pe.Item.displayName;const ar=g.forwardRef(({className:e,children:t,checked:n,...r},o)=>a.jsxs(pe.CheckboxItem,{ref:o,className:N("tw-relative tw-flex tw-cursor-default tw-select-none tw-items-center tw-rounded-sm tw-py-1.5 tw-pl-8 tw-pr-2 tw-text-sm tw-outline-none tw-transition-colors focus:tw-bg-accent focus:tw-text-accent-foreground data-[disabled]:tw-pointer-events-none data-[disabled]:tw-opacity-50",e),checked:n,...r,children:[a.jsx("span",{className:"tw-absolute tw-left-2 tw-flex tw-h-3.5 tw-w-3.5 tw-items-center tw-justify-center",children:a.jsx(pe.ItemIndicator,{children:a.jsx(Q.Check,{className:"tw-h-4 tw-w-4"})})}),t]}));ar.displayName=pe.CheckboxItem.displayName;const uo=g.forwardRef(({className:e,children:t,...n},r)=>a.jsxs(pe.RadioItem,{ref:r,className:N("tw-relative tw-flex tw-cursor-default tw-select-none tw-items-center tw-rounded-sm tw-py-1.5 tw-pl-8 tw-pr-2 tw-text-sm tw-outline-none tw-transition-colors focus:tw-bg-accent focus:tw-text-accent-foreground data-[disabled]:tw-pointer-events-none data-[disabled]:tw-opacity-50",e),...n,children:[a.jsx("span",{className:"tw-absolute tw-left-2 tw-flex tw-h-3.5 tw-w-3.5 tw-items-center tw-justify-center",children:a.jsx(pe.ItemIndicator,{children:a.jsx(Q.Circle,{className:"tw-h-2 tw-w-2 tw-fill-current"})})}),t]}));uo.displayName=pe.RadioItem.displayName;const Wt=g.forwardRef(({className:e,inset:t,...n},r)=>a.jsx(pe.Label,{ref:r,className:N("tw-px-2 tw-py-1.5 tw-text-sm tw-font-semibold",t&&"tw-pl-8",e),...n}));Wt.displayName=pe.Label.displayName;const jn=g.forwardRef(({className:e,...t},n)=>a.jsx(pe.Separator,{ref:n,className:N("tw--mx-1 tw-my-1 tw-h-px tw-bg-muted",e),...t}));jn.displayName=pe.Separator.displayName;function ps({className:e,...t}){return a.jsx("span",{className:N("tw-ml-auto tw-text-xs tw-tracking-widest tw-opacity-60",e),...t})}ps.displayName="DropdownMenuShortcut";const Yl=g.forwardRef(({bookId:e,handleSelectBook:t,isSelected:n,handleHighlightBook:r,handleKeyDown:o,bookType:s,children:i},l)=>a.jsxs(co,{ref:l,textValue:e,className:N("tw-mx-1 tw-px-1 tw-font-normal tw-text-foreground/80",{"tw-bg-amber-50 tw-text-yellow-900 data-[highlighted]:tw-bg-amber-100":n}),onSelect:c=>{c.preventDefault(),t()},onKeyDown:c=>{o(c)},onFocus:r,onMouseMove:r,children:[a.jsx("span",{className:N("tw-border-b-0 tw-border-l-2 tw-border-r-0 tw-border-t-0 tw-border-solid tw-px-2",{"tw-font-bold":n,"tw-border-l-red-200":s.toLowerCase()==="ot","tw-border-l-purple-200":s.toLowerCase()==="nt","tw-border-l-indigo-200":s.toLowerCase()==="dc"}),children:ae.bookIdToEnglishName(e)}),n&&a.jsx("div",{children:i})]},e));function Wl({handleSelectChapter:e,endChapter:t,activeChapter:n,highlightedChapter:r,handleHighlightedChapter:o}){const s=Array.from({length:t},(l,c)=>c+1),i=g.useCallback(l=>{o(l)},[o]);return a.jsx("div",{className:N("tw-flex tw-flex-wrap tw-items-start tw-justify-start tw-self-stretch"),children:s.map(l=>a.jsx("div",{className:N("tw-box-content tw-flex tw-h-4 tw-w-4 tw-cursor-pointer tw-items-center tw-justify-end tw-rounded-md tw-p-2 tw-text-amber-800",{"tw-font-semibold tw-text-amber-900":l===n,"tw-bg-amber-200":l===r}),onClick:c=>{c.preventDefault(),c.stopPropagation(),e(l)},role:"button",onKeyDown:c=>{c.key==="Enter"&&e(l)},tabIndex:0,onMouseMove:()=>i(l),children:l},l))})}function Kl({handleSort:e,handleLocationHistory:t,handleBookmarks:n}){return a.jsxs(Wt,{className:"tw-flex tw-justify-between",children:[a.jsx("p",{className:"tw-inline-block tw-align-middle",children:"Go To"}),a.jsxs("div",{className:"tw-flex tw-items-center",children:[a.jsx(Q.ArrowDownWideNarrow,{onClick:e,className:"tw-m-2 tw-h-4 tw-w-4 tw-cursor-pointer tw-gap-2"}),a.jsx(Q.Clock,{onClick:t,className:"tw-m-2 tw-h-4 tw-w-4 tw-cursor-pointer tw-gap-2"}),a.jsx(Q.Bookmark,{onClick:n,className:"tw-m-2 tw-h-4 tw-w-4 tw-cursor-pointer tw-gap-2"})]})]})}const wn=ae.allBookIds,Jl={OT:"Old Testament",NT:"New Testament",DC:"Deuterocanon"},aa=["OT","NT","DC"],Zl=32+32+32,Ql=[/^(\w+)$/i,/^(\w+)(?:\s(\d+))$/i,/^(\w+)(?:\s(\d+):(\d+))$/i],ec=e=>({OT:wn.filter(n=>ae.isBookOT(n)),NT:wn.filter(n=>ae.isBookNT(n)),DC:wn.filter(n=>ae.isBookDC(n))})[e],rn=e=>W.getChaptersForBook(ae.bookIdToNumber(e));function tc(){return wn.map(t=>ae.bookIdToEnglishName(t))}function nc(e){return tc().includes(e)}function rc(e){const t=e.toLowerCase().replace(/^\w/,n=>n.toUpperCase());if(nc(t))return wn.find(r=>ae.bookIdToEnglishName(r)===t)}function oc({scrRef:e,handleSubmit:t}){const[n,r]=g.useState(""),[o,s]=g.useState(ae.bookNumberToId(e.bookNum)),[i,l]=g.useState(e.chapterNum??0),[c,d]=g.useState(ae.bookNumberToId(e.bookNum)),[u,h]=g.useState(!1),[w,b]=g.useState(u),x=g.useRef(void 0),f=g.useRef(void 0),m=g.useRef(void 0),S=g.useCallback(k=>ec(k).filter(D=>{const $=ae.bookIdToEnglishName(D).toLowerCase(),J=n.replace(/[^a-zA-Z]/g,"").toLowerCase();return $.includes(J)||D.toLowerCase().includes(J)}),[n]),R=k=>{r(k)},j=g.useRef(!1),E=g.useCallback(k=>{if(j.current){j.current=!1;return}h(k)},[]),v=g.useCallback((k,D,$,J)=>{if(l(ae.bookNumberToId(e.bookNum)!==k?1:e.chapterNum),D||rn(k)===-1){t({bookNum:ae.bookIdToNumber(k),chapterNum:$||1,verseNum:J||1}),h(!1),r("");return}s(o!==k?k:""),h(!D)},[t,e.bookNum,e.chapterNum,o]),P=k=>{k<=0||k>rn(o)||v(o,!0,k)},V=g.useCallback(()=>{Ql.forEach(k=>{const D=n.match(k);if(D){const[$,J=void 0,Y=void 0]=D.slice(1),F=rc($);(ae.isBookIdValid($)||F)&&v(F??$,!0,J?parseInt(J,10):1,Y?parseInt(Y,10):1)}})},[v,n]),U=g.useCallback(k=>{u?(k.key==="ArrowDown"||k.key==="ArrowUp")&&(typeof m<"u"&&m.current!==null?m.current.focus():typeof f<"u"&&f.current!==null&&f.current.focus(),k.preventDefault()):h(!0)},[u]),C=k=>{const{key:D}=k;D==="ArrowRight"||D==="ArrowLeft"||D==="ArrowDown"||D==="ArrowUp"||D==="Enter"||(x.current.dispatchEvent(new KeyboardEvent("keydown",{key:D})),x.current.focus())},_=k=>{const{key:D}=k;if(c===o){if(D==="Enter"){k.preventDefault(),v(o,!0,i);return}let $=0;if(D==="ArrowRight")if(i1)$=-1;else{k.preventDefault();return}else D==="ArrowDown"?$=6:D==="ArrowUp"&&($=-6);i+$<=0||i+$>rn(c)?l(0):$!==0&&(l(i+$),k.preventDefault())}};return g.useEffect(()=>{o===c?o===ae.bookNumberToId(e.bookNum)?l(e.chapterNum):l(1):l(0)},[c,e.bookNum,e.chapterNum,o]),g.useLayoutEffect(()=>{b(u)},[u]),g.useLayoutEffect(()=>{const k=setTimeout(()=>{if(w&&f.current&&m.current){const $=m.current.offsetTop-Zl;f.current.scrollTo({top:$,behavior:"instant"})}},10);return()=>{clearTimeout(k)}},[w]),a.jsx("div",{className:"pr-twp tw-flex",children:a.jsxs(or,{modal:!1,open:u,onOpenChange:E,children:[a.jsx(lo,{asChild:!0,children:a.jsx(Pl,{ref:x,value:n,handleSearch:R,handleKeyDown:U,handleOnClick:()=>{s(ae.bookNumberToId(e.bookNum)),d(ae.bookNumberToId(e.bookNum)),l(e.chapterNum>0?e.chapterNum:0),h(!0),x.current.focus()},onFocus:()=>{j.current=!0},handleSubmit:V,placeholder:`${ae.bookNumberToEnglishName(e.bookNum)} ${e.chapterNum}:${e.verseNum}`})}),a.jsxs(En,{className:"tw-m-1 tw-overflow-y-auto tw-p-0 tw-font-normal tw-text-foreground/80",style:{width:"233px",maxHeight:"500px",zIndex:"250"},onKeyDown:C,align:"start",ref:f,children:[a.jsx(Kl,{handleSort:()=>console.log("sorting"),handleLocationHistory:()=>console.log("location history"),handleBookmarks:()=>console.log("bookmarks")}),aa.map((k,D)=>S(k).length>0&&a.jsxs("div",{children:[a.jsx(Wt,{className:"tw-font-semibold tw-text-foreground/80",children:Jl[k]}),S(k).map($=>a.jsx("div",{children:a.jsx(Yl,{bookId:$,handleSelectBook:()=>v($,!1),isSelected:o===$,handleHighlightBook:()=>d($),handleKeyDown:_,bookType:k,ref:J=>{o===$&&(m.current=J)},children:a.jsx(Wl,{handleSelectChapter:P,endChapter:rn($),activeChapter:e.bookNum===ae.bookIdToNumber($)?e.chapterNum:0,highlightedChapter:i,handleHighlightedChapter:J=>{l(J)}})})},$)),aa.length-1!==D?a.jsx(jn,{}):void 0]},k))]})]})})}const ws=Xt.cva("pr-twp tw-inline-flex tw-items-center tw-justify-center tw-whitespace-nowrap tw-rounded-md tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-colors focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50",{variants:{variant:{default:"tw-bg-primary tw-text-primary-foreground hover:tw-bg-primary/90",destructive:"tw-bg-destructive tw-text-destructive-foreground hover:tw-bg-destructive/90",outline:"tw-border tw-border-input tw-bg-background hover:tw-bg-accent hover:tw-text-accent-foreground",secondary:"tw-bg-secondary tw-text-secondary-foreground hover:tw-bg-secondary/80",ghost:"hover:tw-bg-accent hover:tw-text-accent-foreground",link:"tw-text-primary tw-underline-offset-4 hover:tw-underline"},size:{default:"tw-h-10 tw-px-4 tw-py-2",sm:"tw-h-9 tw-rounded-md tw-px-3",lg:"tw-h-11 tw-rounded-md tw-px-8",icon:"tw-h-10 tw-w-10"}},defaultVariants:{variant:"default",size:"default"}}),fe=g.forwardRef(({className:e,variant:t,size:n,asChild:r=!1,...o},s)=>{const i=r?Ht.Slot:"button";return a.jsx(i,{className:N(ws({variant:t,size:n,className:e})),ref:s,...o})});fe.displayName="Button";const ac=Xt.cva("tw-text-sm tw-font-medium tw-leading-none peer-disabled:tw-cursor-not-allowed peer-disabled:tw-opacity-70"),qe=g.forwardRef(({className:e,...t},n)=>a.jsx(es.Root,{ref:n,className:N("pr-twp",ac(),e),...t}));qe.displayName=es.Root.displayName;const po=g.forwardRef(({className:e,...t},n)=>a.jsx(bn.Root,{className:N("pr-twp tw-grid tw-gap-2",e),...t,ref:n}));po.displayName=bn.Root.displayName;const Yn=g.forwardRef(({className:e,...t},n)=>a.jsx(bn.Item,{ref:n,className:N("pr-twp tw-aspect-square tw-h-4 tw-w-4 tw-rounded-full tw-border tw-border-primary tw-text-primary tw-ring-offset-background focus:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-cursor-not-allowed disabled:tw-opacity-50",e),...t,children:a.jsx(bn.Indicator,{className:"tw-flex tw-items-center tw-justify-center",children:a.jsx(Q.Circle,{className:"tw-h-2.5 tw-w-2.5 tw-fill-current tw-text-current"})})}));Yn.displayName=bn.Item.displayName;const sc=vn.Root,ic=vn.Trigger,fs=g.forwardRef(({className:e,align:t="center",sideOffset:n=4,...r},o)=>a.jsx(vn.Portal,{children:a.jsx(vn.Content,{ref:o,align:t,sideOffset:n,className:N("pr-twp tw-z-50 tw-w-72 tw-rounded-md tw-border tw-bg-popover tw-p-4 tw-text-popover-foreground tw-shadow-md tw-outline-none data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0 data-[state=closed]:tw-zoom-out-95 data-[state=open]:tw-zoom-in-95 data-[side=bottom]:tw-slide-in-from-top-2 data-[side=left]:tw-slide-in-from-right-2 data-[side=right]:tw-slide-in-from-left-2 data-[side=top]:tw-slide-in-from-bottom-2",e),...r})}));fs.displayName=vn.Content.displayName;const lc=be.Portal,ms=g.forwardRef(({className:e,...t},n)=>a.jsx(be.Overlay,{ref:n,className:N("tw-fixed tw-inset-0 tw-z-50 tw-bg-black/80 data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0",e),...t}));ms.displayName=be.Overlay.displayName;const cc=g.forwardRef(({className:e,children:t,...n},r)=>a.jsxs(lc,{children:[a.jsx(ms,{}),a.jsxs(be.Content,{ref:r,className:N("tw-fixed tw-left-[50%] tw-top-[50%] tw-z-50 tw-grid tw-w-full tw-max-w-lg tw-translate-x-[-50%] tw-translate-y-[-50%] tw-gap-4 tw-border tw-bg-background tw-p-6 tw-shadow-lg tw-duration-200 data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0 data-[state=closed]:tw-zoom-out-95 data-[state=open]:tw-zoom-in-95 data-[state=closed]:tw-slide-out-to-left-1/2 data-[state=closed]:tw-slide-out-to-top-[48%] data-[state=open]:tw-slide-in-from-left-1/2 data-[state=open]:tw-slide-in-from-top-[48%] sm:tw-rounded-lg",e),...n,children:[t,a.jsxs(be.Close,{className:"tw-absolute tw-right-4 tw-top-4 tw-rounded-sm tw-opacity-70 tw-ring-offset-background tw-transition-opacity hover:tw-opacity-100 focus:tw-outline-none focus:tw-ring-2 focus:tw-ring-ring focus:tw-ring-offset-2 disabled:tw-pointer-events-none data-[state=open]:tw-bg-accent data-[state=open]:tw-text-muted-foreground",children:[a.jsx(Q.X,{className:"tw-h-4 tw-w-4"}),a.jsx("span",{className:"tw-sr-only",children:"Close"})]})]})]}));cc.displayName=be.Content.displayName;const dc=g.forwardRef(({className:e,...t},n)=>a.jsx(be.Title,{ref:n,className:N("tw-text-lg tw-font-semibold tw-leading-none tw-tracking-tight",e),...t}));dc.displayName=be.Title.displayName;const uc=g.forwardRef(({className:e,...t},n)=>a.jsx(be.Description,{ref:n,className:N("tw-text-sm tw-text-muted-foreground",e),...t}));uc.displayName=be.Description.displayName;const hs=g.forwardRef(({className:e,...t},n)=>a.jsx(Re.Command,{ref:n,className:N("tw-flex tw-h-full tw-w-full tw-flex-col tw-overflow-hidden tw-rounded-md tw-bg-popover tw-text-popover-foreground",e),...t}));hs.displayName=Re.Command.displayName;const gs=g.forwardRef(({className:e,...t},n)=>a.jsxs("div",{className:"tw-flex tw-items-center tw-border-b tw-px-3",children:[a.jsx(Q.Search,{className:"tw-me-2 tw-h-4 tw-w-4 tw-shrink-0 tw-opacity-50"}),a.jsx(Re.Command.Input,{ref:n,className:N("tw-flex tw-h-11 tw-w-full tw-rounded-md tw-bg-transparent tw-py-3 tw-text-sm tw-outline-none placeholder:tw-text-muted-foreground disabled:tw-cursor-not-allowed disabled:tw-opacity-50",e),...t})]}));gs.displayName=Re.Command.Input.displayName;const bs=g.forwardRef(({className:e,...t},n)=>a.jsx(Re.Command.List,{ref:n,className:N("tw-max-h-[300px] tw-overflow-y-auto tw-overflow-x-hidden",e),...t}));bs.displayName=Re.Command.List.displayName;const vs=g.forwardRef((e,t)=>a.jsx(Re.Command.Empty,{ref:t,className:"tw-py-6 tw-text-center tw-text-sm",...e}));vs.displayName=Re.Command.Empty.displayName;const pc=g.forwardRef(({className:e,...t},n)=>a.jsx(Re.Command.Group,{ref:n,className:N("tw-overflow-hidden tw-p-1 tw-text-foreground [&_[cmdk-group-heading]]:tw-px-2 [&_[cmdk-group-heading]]:tw-py-1.5 [&_[cmdk-group-heading]]:tw-text-xs [&_[cmdk-group-heading]]:tw-font-medium [&_[cmdk-group-heading]]:tw-text-muted-foreground",e),...t}));pc.displayName=Re.Command.Group.displayName;const wc=g.forwardRef(({className:e,...t},n)=>a.jsx(Re.Command.Separator,{ref:n,className:N("tw--mx-1 tw-h-px tw-bg-border",e),...t}));wc.displayName=Re.Command.Separator.displayName;const xs=g.forwardRef(({className:e,...t},n)=>a.jsx(Re.Command.Item,{ref:n,className:N("tw-relative tw-flex tw-cursor-default tw-select-none tw-items-center tw-rounded-sm tw-px-2 tw-py-1.5 tw-text-sm tw-outline-none data-[disabled=true]:tw-pointer-events-none data-[selected=true]:tw-bg-accent data-[selected=true]:tw-text-accent-foreground data-[disabled=true]:tw-opacity-50",e),...t}));xs.displayName=Re.Command.Item.displayName;function fc(e){return typeof e=="string"?e:typeof e=="number"?e.toString():e.label}function Wn({id:e,options:t=[],buttonClassName:n,popoverContentClassName:r,value:o,onChange:s=()=>{},getOptionLabel:i=fc,buttonPlaceholder:l="",textPlaceholder:c="",commandEmptyMessage:d="No option found",buttonVariant:u="outline",dir:h="ltr",isDisabled:w=!1,...b}){const[x,f]=g.useState(!1);return a.jsxs(sc,{open:x,onOpenChange:f,...b,children:[a.jsx(ic,{asChild:!0,children:a.jsxs(fe,{variant:u,role:"combobox","aria-expanded":x,id:e,className:N("tw-w-[200px] tw-justify-between",n),disabled:w,children:[a.jsx("span",{className:"tw-overflow-hidden tw-text-ellipsis tw-whitespace-nowrap",children:o?i(o):l}),a.jsx(Q.ChevronsUpDown,{className:"tw-ms-2 tw-h-4 tw-w-4 tw-shrink-0 tw-opacity-50"})]})}),a.jsx(fs,{className:N("tw-w-[200px] tw-p-0",r),dir:h,children:a.jsxs(hs,{children:[a.jsx(gs,{dir:h,placeholder:c,className:"tw-text-inherit"}),a.jsx(vs,{children:d}),a.jsx(bs,{children:t.map(m=>a.jsxs(xs,{value:i(m),onSelect:()=>{s(m),f(!1)},children:[a.jsx(Q.Check,{className:N("tw-me-2 tw-h-4 tw-w-4",{"tw-opacity-0":!o||i(o)!==i(m)})}),i(m)]},i(m)))})]})})]})}function ys({startChapter:e,endChapter:t,handleSelectStartChapter:n,handleSelectEndChapter:r,isDisabled:o=!1,chapterCount:s}){const i=g.useMemo(()=>Array.from({length:s},(d,u)=>u+1),[s]),l=d=>{n(d),d>t&&r(d)},c=d=>{r(d),dd.toString(),value:e},"start chapter"),a.jsx(qe,{htmlFor:"end-chapters-combobox",children:"to"}),a.jsx(Wn,{isDisabled:o,onChange:c,buttonClassName:"tw-ml-2 tw-w-20",options:i,getOptionLabel:d=>d.toString(),value:t},"end chapter")]})}var Ns=(e=>(e.CURRENT_BOOK="current book",e.CHOOSE_BOOKS="choose books",e))(Ns||{});const mc=Object.freeze(["%webView_bookSelector_currentBook%","%webView_bookSelector_choose%","%webView_bookSelector_chooseBooks%"]),Tr=(e,t)=>e[t]??t;function hc({handleBookSelectionModeChange:e,currentBookName:t,onSelectBooks:n,selectedBookIds:r,chapterCount:o,endChapter:s,handleSelectEndChapter:i,startChapter:l,handleSelectStartChapter:c,localizedStrings:d}){const u=Tr(d,"%webView_bookSelector_currentBook%"),h=Tr(d,"%webView_bookSelector_choose%"),w=Tr(d,"%webView_bookSelector_chooseBooks%"),[b,x]=g.useState("current book"),f=m=>{x(m),e(m)};return a.jsx(po,{className:"pr-twp tw-flex",value:b,onValueChange:m=>f(m),children:a.jsxs("div",{className:"tw-flex tw-w-full tw-flex-col tw-gap-4",children:[a.jsxs("div",{className:"tw-grid tw-grid-cols-[25%,25%,50%]",children:[a.jsxs("div",{className:"tw-flex tw-items-center",children:[a.jsx(Yn,{value:"current book"}),a.jsx(qe,{className:"tw-ml-1",children:u})]}),a.jsx(qe,{className:"tw-flex tw-items-center",children:t}),a.jsx("div",{className:"tw-flex tw-items-center tw-justify-end",children:a.jsx(ys,{isDisabled:b==="choose books",handleSelectStartChapter:c,handleSelectEndChapter:i,chapterCount:o,startChapter:l,endChapter:s})})]}),a.jsxs("div",{className:"tw-grid tw-grid-cols-[25%,50%,25%]",children:[a.jsxs("div",{className:"tw-flex tw-items-center",children:[a.jsx(Yn,{value:"choose books"}),a.jsx(qe,{className:"tw-ml-1",children:w})]}),a.jsx(qe,{className:"tw-flex tw-items-center",children:r.map(m=>ae.bookIdToEnglishName(m)).join(", ")}),a.jsx(fe,{disabled:b==="current book",onClick:()=>n(),children:h})]})]})})}function gc({table:e}){return a.jsxs(or,{children:[a.jsx(Za.DropdownMenuTrigger,{asChild:!0,children:a.jsxs(fe,{variant:"outline",size:"sm",className:"tw-ml-auto tw-hidden tw-h-8 lg:tw-flex",children:[a.jsx(Q.FilterIcon,{className:"tw-mr-2 tw-h-4 tw-w-4"}),"View"]})}),a.jsxs(En,{align:"end",className:"tw-w-[150px]",children:[a.jsx(Wt,{children:"Toggle columns"}),a.jsx(jn,{}),e.getAllColumns().filter(t=>t.getCanHide()).map(t=>a.jsx(ar,{className:"tw-capitalize",checked:t.getIsVisible(),onCheckedChange:n=>t.toggleVisibility(!!n),children:t.id},t.id))]})]})}const At=ge.Root,ks=ge.Group,Bt=ge.Value,bt=g.forwardRef(({className:e,children:t,...n},r)=>a.jsxs(ge.Trigger,{ref:r,className:N("tw-flex tw-h-10 tw-w-full tw-items-center tw-justify-between tw-rounded-md tw-border tw-border-input tw-bg-background tw-px-3 tw-py-2 tw-text-sm tw-ring-offset-background placeholder:tw-text-muted-foreground focus:tw-outline-none focus:tw-ring-2 focus:tw-ring-ring focus:tw-ring-offset-2 disabled:tw-cursor-not-allowed disabled:tw-opacity-50 [&>span]:tw-line-clamp-1",e),...n,children:[t,a.jsx(ge.Icon,{asChild:!0,children:a.jsx(Q.ChevronDown,{className:"tw-h-4 tw-w-4 tw-opacity-50"})})]}));bt.displayName=ge.Trigger.displayName;const wo=g.forwardRef(({className:e,...t},n)=>a.jsx(ge.ScrollUpButton,{ref:n,className:N("tw-flex tw-cursor-default tw-items-center tw-justify-center tw-py-1",e),...t,children:a.jsx(Q.ChevronUp,{className:"tw-h-4 tw-w-4"})}));wo.displayName=ge.ScrollUpButton.displayName;const fo=g.forwardRef(({className:e,...t},n)=>a.jsx(ge.ScrollDownButton,{ref:n,className:N("tw-flex tw-cursor-default tw-items-center tw-justify-center tw-py-1",e),...t,children:a.jsx(Q.ChevronDown,{className:"tw-h-4 tw-w-4"})}));fo.displayName=ge.ScrollDownButton.displayName;const vt=g.forwardRef(({className:e,children:t,position:n="popper",...r},o)=>a.jsx(ge.Portal,{children:a.jsxs(ge.Content,{ref:o,className:N("pr-twp tw-relative tw-z-50 tw-max-h-96 tw-min-w-[8rem] tw-overflow-hidden tw-rounded-md tw-border tw-bg-popover tw-text-popover-foreground tw-shadow-md data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0 data-[state=closed]:tw-zoom-out-95 data-[state=open]:tw-zoom-in-95 data-[side=bottom]:tw-slide-in-from-top-2 data-[side=left]:tw-slide-in-from-right-2 data-[side=right]:tw-slide-in-from-left-2 data-[side=top]:tw-slide-in-from-bottom-2",n==="popper"&&"data-[side=bottom]:tw-translate-y-1 data-[side=left]:tw--translate-x-1 data-[side=right]:tw-translate-x-1 data-[side=top]:tw--translate-y-1",e),position:n,...r,children:[a.jsx(wo,{}),a.jsx(ge.Viewport,{className:N("tw-p-1",n==="popper"&&"tw-h-[var(--radix-select-trigger-height)] tw-w-full tw-min-w-[var(--radix-select-trigger-width)]"),children:t}),a.jsx(fo,{})]})}));vt.displayName=ge.Content.displayName;const Ss=g.forwardRef(({className:e,...t},n)=>a.jsx(ge.Label,{ref:n,className:N("tw-py-1.5 tw-pl-8 tw-pr-2 tw-text-sm tw-font-semibold",e),...t}));Ss.displayName=ge.Label.displayName;const Ae=g.forwardRef(({className:e,children:t,...n},r)=>a.jsxs(ge.Item,{ref:r,className:N("tw-relative tw-flex tw-w-full tw-cursor-default tw-select-none tw-items-center tw-rounded-sm tw-py-1.5 tw-pl-8 tw-pr-2 tw-text-sm tw-outline-none focus:tw-bg-accent focus:tw-text-accent-foreground data-[disabled]:tw-pointer-events-none data-[disabled]:tw-opacity-50",e),...n,children:[a.jsx("span",{className:"tw-absolute tw-left-2 tw-flex tw-h-3.5 tw-w-3.5 tw-items-center tw-justify-center",children:a.jsx(ge.ItemIndicator,{children:a.jsx(Q.Check,{className:"tw-h-4 tw-w-4"})})}),a.jsx(ge.ItemText,{children:t})]}));Ae.displayName=ge.Item.displayName;const Es=g.forwardRef(({className:e,...t},n)=>a.jsx(ge.Separator,{ref:n,className:N("tw--mx-1 tw-my-1 tw-h-px tw-bg-muted",e),...t}));Es.displayName=ge.Separator.displayName;function bc({table:e}){return a.jsx("div",{className:"tw-flex tw-items-center tw-justify-between tw-px-2 tw-pb-3 tw-pt-3",children:a.jsxs("div",{className:"tw-flex tw-items-center tw-space-x-6 lg:tw-space-x-8",children:[a.jsxs("div",{className:"tw-flex-1 tw-text-sm tw-text-muted-foreground",children:[e.getFilteredSelectedRowModel().rows.length," of"," ",e.getFilteredRowModel().rows.length," row(s) selected"]}),a.jsxs("div",{className:"tw-flex tw-items-center tw-space-x-2",children:[a.jsx("p",{className:"tw-text-nowrap tw-text-sm tw-font-medium",children:"Rows per page"}),a.jsxs(At,{value:`${e.getState().pagination.pageSize}`,onValueChange:t=>{e.setPageSize(Number(t))},children:[a.jsx(bt,{className:"tw-h-8 tw-w-[70px]",children:a.jsx(Bt,{placeholder:e.getState().pagination.pageSize})}),a.jsx(vt,{side:"top",children:[10,20,30,40,50].map(t=>a.jsx(Ae,{value:`${t}`,children:t},t))})]})]}),a.jsxs("div",{className:"tw-flex tw-w-[100px] tw-items-center tw-justify-center tw-text-sm tw-font-medium",children:["Page ",e.getState().pagination.pageIndex+1," of ",e.getPageCount()]}),a.jsxs("div",{className:"tw-flex tw-items-center tw-space-x-2",children:[a.jsxs(fe,{variant:"outline",size:"icon",className:"tw-hidden tw-h-8 tw-w-8 tw-p-0 lg:tw-flex",onClick:()=>e.setPageIndex(0),disabled:!e.getCanPreviousPage(),children:[a.jsx("span",{className:"tw-sr-only",children:"Go to first page"}),a.jsx(Q.ArrowLeftIcon,{className:"tw-h-4 tw-w-4"})]}),a.jsxs(fe,{variant:"outline",size:"icon",className:"tw-h-8 tw-w-8 tw-p-0",onClick:()=>e.previousPage(),disabled:!e.getCanPreviousPage(),children:[a.jsx("span",{className:"tw-sr-only",children:"Go to previous page"}),a.jsx(Q.ChevronLeftIcon,{className:"tw-h-4 tw-w-4"})]}),a.jsxs(fe,{variant:"outline",size:"icon",className:"tw-h-8 tw-w-8 tw-p-0",onClick:()=>e.nextPage(),disabled:!e.getCanNextPage(),children:[a.jsx("span",{className:"tw-sr-only",children:"Go to next page"}),a.jsx(Q.ChevronRightIcon,{className:"tw-h-4 tw-w-4"})]}),a.jsxs(fe,{variant:"outline",size:"icon",className:"tw-hidden tw-h-8 tw-w-8 tw-p-0 lg:tw-flex",onClick:()=>e.setPageIndex(e.getPageCount()-1),disabled:!e.getCanNextPage(),children:[a.jsx("span",{className:"tw-sr-only",children:"Go to last page"}),a.jsx(Q.ArrowRightIcon,{className:"tw-h-4 tw-w-4"})]})]})]})})}const Cn=g.forwardRef(({className:e,stickyHeader:t,...n},r)=>a.jsx("div",{className:N("pr-twp tw-relative tw-w-full",{"tw-overflow-auto":!t}),children:a.jsx("table",{ref:r,className:N("tw-w-full tw-caption-bottom tw-text-sm",e),...n})}));Cn.displayName="Table";const Tn=g.forwardRef(({className:e,stickyHeader:t,...n},r)=>a.jsx("thead",{ref:r,className:N({"tw-sticky tw-top-[-1px] tw-bg-background tw-drop-shadow-sm":t},"[&_tr]:tw-border-b",e),...n}));Tn.displayName="TableHeader";const Rn=g.forwardRef(({className:e,...t},n)=>a.jsx("tbody",{ref:n,className:N("[&_tr:last-child]:tw-border-0",e),...t}));Rn.displayName="TableBody";const js=g.forwardRef(({className:e,...t},n)=>a.jsx("tfoot",{ref:n,className:N("tw-border-t tw-bg-muted/50 tw-font-medium [&>tr]:last:tw-border-b-0",e),...t}));js.displayName="TableFooter";const Ze=g.forwardRef(({className:e,...t},n)=>a.jsx("tr",{ref:n,className:N("tw-border-b tw-transition-colors hover:tw-bg-muted/50 data-[state=selected]:tw-bg-muted",e),...t}));Ze.displayName="TableRow";const Vt=g.forwardRef(({className:e,...t},n)=>a.jsx("th",{ref:n,className:N("tw-h-12 tw-px-4 tw-text-start tw-align-middle tw-font-medium tw-text-muted-foreground [&:has([role=checkbox])]:tw-pe-0",e),...t}));Vt.displayName="TableHead";const xt=g.forwardRef(({className:e,...t},n)=>a.jsx("td",{ref:n,className:N("tw-p-4 tw-align-middle [&:has([role=checkbox])]:tw-pe-0",e),...t}));xt.displayName="TableCell";const Cs=g.forwardRef(({className:e,...t},n)=>a.jsx("caption",{ref:n,className:N("tw-mt-4 tw-text-sm tw-text-muted-foreground",e),...t}));Cs.displayName="TableCaption";function Ts({columns:e,data:t,enablePagination:n=!1,showPaginationControls:r=!1,showColumnVisibilityControls:o=!1,stickyHeader:s=!1,onRowClickHandler:i=()=>{}}){var m;const[l,c]=g.useState([]),[d,u]=g.useState([]),[h,w]=g.useState({}),[b,x]=g.useState({}),f=Se.useReactTable({data:t,columns:e,getCoreRowModel:Se.getCoreRowModel(),...n&&{getPaginationRowModel:Se.getPaginationRowModel()},onSortingChange:c,getSortedRowModel:Se.getSortedRowModel(),onColumnFiltersChange:u,getFilteredRowModel:Se.getFilteredRowModel(),onColumnVisibilityChange:w,onRowSelectionChange:x,state:{sorting:l,columnFilters:d,columnVisibility:h,rowSelection:b}});return a.jsxs("div",{className:"pr-twp",children:[o&&a.jsx(gc,{table:f}),a.jsxs(Cn,{stickyHeader:s,children:[a.jsx(Tn,{stickyHeader:s,children:f.getHeaderGroups().map(S=>a.jsx(Ze,{children:S.headers.map(R=>a.jsx(Vt,{children:R.isPlaceholder?void 0:Se.flexRender(R.column.columnDef.header,R.getContext())},R.id))},S.id))}),a.jsx(Rn,{children:(m=f.getRowModel().rows)!=null&&m.length?f.getRowModel().rows.map(S=>a.jsx(Ze,{onClick:()=>i(S,f),"data-state":S.getIsSelected()&&"selected",children:S.getVisibleCells().map(R=>a.jsx(xt,{children:Se.flexRender(R.column.columnDef.cell,R.getContext())},R.id))},S.id)):a.jsx(Ze,{children:a.jsx(xt,{colSpan:e.length,className:"tw-h-24 tw-text-center",children:"No results."})})})]}),n&&a.jsxs("div",{className:"tw-flex tw-items-center tw-justify-end tw-space-x-2 tw-py-4",children:[a.jsx(fe,{variant:"outline",size:"sm",onClick:()=>f.previousPage(),disabled:!f.getCanPreviousPage(),children:"Previous"}),a.jsx(fe,{variant:"outline",size:"sm",onClick:()=>f.nextPage(),disabled:!f.getCanNextPage(),children:"Next"})]}),n&&r&&a.jsx(bc,{table:f})]})}function vc({occurrenceData:e,setScriptureReference:t,localizedStrings:n}){const r=n["%webView_inventory_occurrences_table_header_reference%"],o=n["%webView_inventory_occurrences_table_header_occurrence%"],s=g.useMemo(()=>{const i=[];return e.forEach(l=>{i.some(c=>W.deepEqual(c,l))||i.push(l)}),i},[e]);return a.jsxs(Cn,{stickyHeader:!0,children:[a.jsx(Tn,{stickyHeader:!0,children:a.jsxs(Ze,{children:[a.jsx(Vt,{children:r}),a.jsx(Vt,{children:o})]})}),a.jsx(Rn,{children:s.length>0&&s.map(i=>a.jsxs(Ze,{onClick:()=>{t(i.reference)},children:[a.jsx(xt,{children:`${ae.bookNumberToEnglishName(i.reference.bookNum)} ${i.reference.chapterNum}:${i.reference.verseNum}`}),a.jsx(xt,{children:i.text})]},`${i.reference.bookNum} ${i.reference.chapterNum}:${i.reference.verseNum}-${i.text}`))})]})}const sr=g.forwardRef(({className:e,...t},n)=>a.jsx(Ur.Root,{ref:n,className:N("tw-peer pr-twp tw-h-4 tw-w-4 tw-shrink-0 tw-rounded-sm tw-border tw-border-primary tw-ring-offset-background focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-cursor-not-allowed disabled:tw-opacity-50 data-[state=checked]:tw-bg-primary data-[state=checked]:tw-text-primary-foreground",e),...t,children:a.jsx(Ur.Indicator,{className:N("tw-flex tw-items-center tw-justify-center tw-text-current"),children:a.jsx(Q.Check,{className:"tw-h-4 tw-w-4"})})}));sr.displayName=Ur.Root.displayName;const Rs=e=>e.split(/(?:\r?\n|\r)|(?=(?:\\(?:v|c|id)))/g),Hr=e=>{const t=/^\\[vc]\s+(\d+)/,n=e.match(t);if(n)return+n[1]},Os=e=>{const t=e.match(/^\\id\s+([A-Za-z]+)/);return t?ae.bookIdToNumber(t[1]):0},_s=(e,t,n)=>n.includes(e)?"unapproved":t.includes(e)?"approved":"unknown",Ps=Xt.cva("pr-twp tw-inline-flex tw-items-center tw-justify-center tw-rounded-md tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-colors hover:tw-bg-muted hover:tw-text-muted-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50 data-[state=on]:tw-bg-accent data-[state=on]:tw-text-accent-foreground",{variants:{variant:{default:"tw-bg-transparent",outline:"tw-border tw-border-input tw-bg-transparent hover:tw-bg-accent hover:tw-text-accent-foreground"},size:{default:"tw-h-10 tw-px-3",sm:"tw-h-9 tw-px-2.5",lg:"tw-h-11 tw-px-5"}},defaultVariants:{variant:"default",size:"default"}}),xc=g.forwardRef(({className:e,variant:t,size:n,...r},o)=>a.jsx(ts.Root,{ref:o,className:N(Ps({variant:t,size:n,className:e})),...r}));xc.displayName=ts.Root.displayName;const Is=g.createContext({size:"default",variant:"default"}),mo=g.forwardRef(({className:e,variant:t,size:n,children:r,...o},s)=>a.jsx(rr.Root,{ref:s,className:N("pr-twp tw-flex tw-items-center tw-justify-center tw-gap-1",e),...o,children:a.jsx(Is.Provider,{value:{variant:t,size:n},children:r})}));mo.displayName=rr.Root.displayName;const fn=g.forwardRef(({className:e,children:t,variant:n,size:r,...o},s)=>{const i=g.useContext(Is);return a.jsx(rr.Item,{ref:s,className:N(Ps({variant:i.variant||n,size:i.size||r}),e),...o,children:t})});fn.displayName=rr.Item.displayName;const ir=e=>e==="asc"?a.jsx(Q.ArrowUpIcon,{className:"tw-ms-2 tw-h-4 tw-w-4"}):e==="desc"?a.jsx(Q.ArrowDownIcon,{className:"tw-ms-2 tw-h-4 tw-w-4"}):a.jsx(Q.ArrowUpDownIcon,{className:"tw-ms-2 tw-h-4 tw-w-4"}),yc=e=>({accessorKey:"item",accessorFn:t=>t.items[0],header:({column:t})=>a.jsxs(fe,{variant:"ghost",onClick:()=>t.toggleSorting(void 0),children:[e,ir(t.getIsSorted())]})}),Nc=(e,t)=>({accessorKey:`item${t}`,accessorFn:n=>n.items[t],header:({column:n})=>a.jsxs(fe,{variant:"ghost",onClick:()=>n.toggleSorting(void 0),children:[e,ir(n.getIsSorted())]})}),kc=e=>({accessorKey:"count",header:({column:t})=>a.jsx("div",{className:"tw-flex tw-justify-end tw-tabular-nums",children:a.jsxs(fe,{variant:"ghost",onClick:()=>t.toggleSorting(void 0),children:[e,ir(t.getIsSorted())]})}),cell:({row:t})=>a.jsx("div",{className:"tw-flex tw-justify-end",children:t.getValue("count")})}),Rr=(e,t,n,r,o,s)=>{let i=[...n];e.forEach(c=>{t==="approved"?i.includes(c)||i.push(c):i=i.filter(d=>d!==c)}),r(i);let l=[...o];e.forEach(c=>{t==="unapproved"?l.includes(c)||l.push(c):l=l.filter(d=>d!==c)}),s(l)},Sc=(e,t,n,r,o)=>({accessorKey:"status",header:({column:s})=>a.jsx("div",{className:"tw-flex tw-justify-center",children:a.jsxs(fe,{variant:"ghost",onClick:()=>s.toggleSorting(void 0),children:[e,ir(s.getIsSorted())]})}),cell:({row:s})=>{const i=s.getValue("status"),l=s.getValue("item");return a.jsxs(mo,{value:i,variant:"outline",type:"single",children:[a.jsx(fn,{onClick:()=>Rr([l],"approved",t,n,r,o),value:"approved",children:a.jsx(Q.CircleCheckIcon,{})}),a.jsx(fn,{onClick:()=>Rr([l],"unapproved",t,n,r,o),value:"unapproved",children:a.jsx(Q.CircleXIcon,{})}),a.jsx(fn,{onClick:()=>Rr([l],"unknown",t,n,r,o),value:"unknown",children:a.jsx(Q.CircleHelpIcon,{})})]})}}),Ec=Object.freeze(["%webView_inventory_all%","%webView_inventory_approved%","%webView_inventory_unapproved%","%webView_inventory_unknown%","%webView_inventory_scope_currentBook%","%webView_inventory_scope_chapter%","%webView_inventory_scope_verse%","%webView_inventory_filter_text%","%webView_inventory_show_additional_items%","%webView_inventory_occurrences_table_header_reference%","%webView_inventory_occurrences_table_header_occurrence%"]),jc=(e,t,n)=>{let r=e;return t!=="all"&&(r=r.filter(o=>t==="approved"&&o.status==="approved"||t==="unapproved"&&o.status==="unapproved"||t==="unknown"&&o.status==="unknown")),n!==""&&(r=r.filter(o=>o.items[0].includes(n))),r},Cc=(e,t,n,r,o)=>{if(!e)return[];const s=[];let i=t.bookNum,l=t.chapterNum,c=t.verseNum;return Rs(e).forEach(u=>{u.startsWith("\\id")&&(i=Os(u),l=0,c=0),u.startsWith("\\c")&&(l=Hr(u),c=0),u.startsWith("\\v")&&(c=Hr(u),l===0&&(l=t.chapterNum));let h=o.exec(u)??void 0;for(;h;){const w=[];h.forEach(m=>w.push(m));const b=h.index,x=s.find(m=>W.deepEqual(m.items,w)),f={reference:{bookNum:i!==void 0?i:-1,chapterNum:l!==void 0?l:-1,verseNum:c!==void 0?c:-1},text:W.substring(u,Math.max(0,b-25),Math.min(b+25,u.length))};if(x)x.count+=1,x.occurrences.push(f);else{const m={items:w,count:1,status:_s(w[0],n,r),occurrences:[f]};s.push(m)}h=o.exec(u)??void 0}}),s},Je=(e,t)=>e[t]??t;function Tc({scriptureReference:e,setScriptureReference:t,localizedStrings:n,extractItems:r,additionalItemsLabels:o,approvedItems:s,unapprovedItems:i,text:l,scope:c,onScopeChange:d,columns:u}){const h=Je(n,"%webView_inventory_all%"),w=Je(n,"%webView_inventory_approved%"),b=Je(n,"%webView_inventory_unapproved%"),x=Je(n,"%webView_inventory_unknown%"),f=Je(n,"%webView_inventory_scope_currentBook%"),m=Je(n,"%webView_inventory_scope_chapter%"),S=Je(n,"%webView_inventory_scope_verse%"),R=Je(n,"%webView_inventory_filter_text%"),j=Je(n,"%webView_inventory_show_additional_items%"),[E,v]=g.useState(!1),[P,V]=g.useState("all"),[U,C]=g.useState(""),[_,k]=g.useState([]),D=g.useMemo(()=>l?r instanceof RegExp?Cc(l,e,s,i,r):r(l,e,s,i):[],[l,r,e,s,i]),$=g.useMemo(()=>{if(E)return D;const y=[];return D.forEach(T=>{const z=T.items[0],L=y.find(B=>B.items[0]===z);L?(L.count+=T.count,L.occurrences=L.occurrences.concat(T.occurrences)):y.push({items:[z],count:T.count,occurrences:T.occurrences,status:T.status})}),y},[E,D]),J=g.useMemo(()=>jc($,P,U),[$,P,U]),Y=g.useMemo(()=>{var z,L;if(!E)return u;const y=(z=o==null?void 0:o.tableHeaders)==null?void 0:z.length;if(!y)return u;const T=[];for(let B=0;B{k([])},[J]);const F=(y,T)=>{T.setRowSelection(()=>{const z={};return z[y.index]=!0,z}),k(y.original.items)},te=y=>{if(y==="book"||y==="chapter"||y==="verse")d(y);else throw new Error(`Invalid scope value: ${y}`)},se=y=>{if(y==="all"||y==="approved"||y==="unapproved"||y==="unknown")V(y);else throw new Error(`Invalid status filter value: ${y}`)},oe=g.useMemo(()=>{if($.length===0||_.length===0)return[];const y=$.filter(T=>W.deepEqual(E?T.items:[T.items[0]],_));if(y.length>1)throw new Error("Selected item is not unique");return y[0].occurrences},[_,E,$]);return a.jsxs("div",{className:"pr-twp tw-flex tw-h-full tw-flex-col",children:[a.jsxs("div",{className:"tw-flex tw-items-stretch",children:[a.jsxs(At,{onValueChange:y=>se(y),defaultValue:P,children:[a.jsx(bt,{className:"tw-m-1",children:a.jsx(Bt,{placeholder:"Select filter"})}),a.jsxs(vt,{children:[a.jsx(Ae,{value:"all",children:h}),a.jsx(Ae,{value:"approved",children:w}),a.jsx(Ae,{value:"unapproved",children:b}),a.jsx(Ae,{value:"unknown",children:x})]})]}),a.jsxs(At,{onValueChange:y=>te(y),defaultValue:c,children:[a.jsx(bt,{className:"tw-m-1",children:a.jsx(Bt,{placeholder:"Select scope"})}),a.jsxs(vt,{children:[a.jsx(Ae,{value:"book",children:f}),a.jsx(Ae,{value:"chapter",children:m}),a.jsx(Ae,{value:"verse",children:S})]})]}),a.jsx(St,{className:"tw-m-1 tw-rounded-md tw-border",placeholder:R,value:U,onChange:y=>{C(y.target.value)}}),o&&a.jsxs("div",{className:"tw-m-1 tw-flex tw-items-center tw-rounded-md tw-border",children:[a.jsx(sr,{className:"tw-m-1",checked:E,onCheckedChange:y=>{k([]),v(y)}}),a.jsx(qe,{className:"tw-m-1 tw-flex-shrink-0 tw-whitespace-nowrap",children:(o==null?void 0:o.checkboxText)??j})]})]}),a.jsx("div",{className:"tw-m-1 tw-flex-1 tw-overflow-auto tw-rounded-md tw-border",children:a.jsx(Ts,{columns:Y,data:J,onRowClickHandler:F,stickyHeader:!0})}),oe.length>0&&a.jsx("div",{className:"tw-m-1 tw-flex-1 tw-overflow-auto tw-rounded-md tw-border",children:a.jsx(vc,{occurrenceData:oe,setScriptureReference:t,localizedStrings:n})})]})}function ho({className:e,onSearch:t,placeholder:n,isFullWidth:r}){const[o,s]=g.useState(""),i=l=>{s(l),t(l)};return a.jsx(St,{className:N("tw-flex tw-h-10 tw-rounded-md tw-border tw-border-input tw-bg-background tw-px-3 tw-py-2 tw-text-sm tw-ring-offset-background file:tw-border-0 file:tw-bg-transparent file:tw-text-sm file:tw-font-medium placeholder:tw-text-muted-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-[color:hsl(240,5%,64.9%)] focus-visible:tw-ring-offset-2 disabled:tw-cursor-not-allowed disabled:tw-opacity-50",{"tw-w-full":r},e),placeholder:n,value:o,onChange:l=>i(l.target.value)})}const go=g.forwardRef(({className:e,...t},n)=>a.jsx(Oe.Root,{orientation:"vertical",ref:n,className:N("tw-flex tw-gap-1 tw-rounded-md tw-text-muted-foreground",e),...t}));go.displayName=Oe.List.displayName;const bo=g.forwardRef(({className:e,...t},n)=>a.jsx(Oe.List,{ref:n,className:N("tw-flex-fit tw-mlk-items-center tw-w-[124px] tw-justify-center tw-rounded-md tw-bg-muted tw-p-1 tw-text-muted-foreground",e),...t}));bo.displayName=Oe.List.displayName;const Ms=g.forwardRef(({className:e,...t},n)=>a.jsx(Oe.Trigger,{ref:n,...t,className:N("overflow-clip tw-inline-flex tw-w-[116px] tw-cursor-pointer tw-items-center tw-justify-center tw-break-words tw-rounded-sm tw-border-0 tw-bg-muted tw-px-3 tw-py-1.5 tw-text-sm tw-font-medium tw-text-inherit tw-ring-offset-background tw-transition-all hover:tw-text-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50 data-[state=active]:tw-bg-background data-[state=active]:tw-text-foreground data-[state=active]:tw-shadow-sm",e)})),vo=g.forwardRef(({className:e,...t},n)=>a.jsx(Oe.Content,{ref:n,className:N("tw-ms-5 tw-flex-grow tw-text-foreground tw-ring-offset-background focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2",e),...t}));vo.displayName=Oe.Content.displayName;function Rc({tabList:e,onSearch:t,searchPlaceholder:n,headerTitle:r,isSearchBarFullWidth:o=!1,direction:s="ltr"}){return a.jsxs("div",{className:"pr-twp",children:[a.jsxs("div",{className:"tw-sticky tw-top-0 tw-space-y-2 tw-pb-2",children:[r?a.jsx("h1",{children:r}):"",a.jsx(ho,{isFullWidth:o,onSearch:t,placeholder:n})]}),a.jsxs(go,{dir:s,children:[a.jsx(bo,{children:e.map(i=>a.jsx(Ms,{value:i.value,children:i.value},i.key))}),e.map(i=>a.jsx(vo,{value:i.value,children:i.content},i.key))]})]})}const lr=g.forwardRef(({className:e,orientation:t="horizontal",decorative:n=!0,...r},o)=>a.jsx(ns.Root,{ref:o,decorative:n,orientation:t,className:N("pr-twp tw-shrink-0 tw-bg-border",t==="horizontal"?"tw-h-[1px] tw-w-full":"tw-h-full tw-w-[1px]",e),...r}));lr.displayName=ns.Root.displayName;const Oc=be.Root,_c=be.Portal,$s=M.forwardRef(({className:e,...t},n)=>a.jsx(be.Overlay,{className:N("tw-fixed tw-inset-0 tw-z-50 tw-bg-black/80 data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0",e),...t,ref:n}));$s.displayName=be.Overlay.displayName;const Pc=Xt.cva("pr-twp tw-fixed tw-z-50 tw-gap-4 tw-bg-background tw-p-6 tw-shadow-lg tw-transition tw-ease-in-out data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-duration-300 data-[state=open]:tw-duration-500",{variants:{side:{top:"tw-inset-x-0 tw-top-0 tw-border-b data-[state=closed]:tw-slide-out-to-top data-[state=open]:tw-slide-in-from-top",bottom:"tw-inset-x-0 tw-bottom-0 tw-border-t data-[state=closed]:tw-slide-out-to-bottom data-[state=open]:tw-slide-in-from-bottom",left:"tw-inset-y-0 tw-left-0 tw-h-full tw-w-3/4 tw-border-r data-[state=closed]:tw-slide-out-to-left data-[state=open]:tw-slide-in-from-left sm:tw-max-w-sm",right:"tw-inset-y-0 tw-right-0 tw-h-full tw-w-3/4 tw- tw-border-l data-[state=closed]:tw-slide-out-to-right data-[state=open]:tw-slide-in-from-right sm:tw-max-w-sm"}},defaultVariants:{side:"right"}}),Ds=M.forwardRef(({side:e="right",className:t,children:n,...r},o)=>a.jsxs(_c,{children:[a.jsx($s,{}),a.jsxs(be.Content,{ref:o,className:N(Pc({side:e}),t),...r,children:[n,a.jsxs(be.Close,{className:"tw-absolute tw-right-4 tw-top-4 tw-rounded-sm tw-opacity-70 tw-ring-offset-background tw-transition-opacity hover:tw-opacity-100 focus:tw-outline-none focus:tw-ring-2 focus:tw-ring-ring focus:tw-ring-offset-2 disabled:tw-pointer-events-none data-[state=open]:tw-bg-secondary",children:[a.jsx(Q.X,{className:"tw-h-4 tw-w-4"}),a.jsx("span",{className:"tw-sr-only",children:"Close"})]})]})]}));Ds.displayName=be.Content.displayName;const Ic=M.forwardRef(({className:e,...t},n)=>a.jsx(be.Title,{ref:n,className:N("tw-text-lg tw-font-semibold tw-text-foreground",e),...t}));Ic.displayName=be.Title.displayName;const Mc=M.forwardRef(({className:e,...t},n)=>a.jsx(be.Description,{ref:n,className:N("tw-text-sm tw-text-muted-foreground",e),...t}));Mc.displayName=be.Description.displayName;function sa({className:e,...t}){return a.jsx("div",{className:N("pr-twp tw-animate-pulse tw-rounded-md tw-bg-muted",e),...t})}const $c=Sn.Provider,Dc=Sn.Root,Ac=Sn.Trigger,As=g.forwardRef(({className:e,sideOffset:t=4,...n},r)=>a.jsx(Sn.Content,{ref:r,sideOffset:t,className:N("pr-twp tw-z-50 tw-overflow-hidden tw-rounded-md tw-border tw-bg-popover tw-px-3 tw-py-1.5 tw-text-sm tw-text-popover-foreground tw-shadow-md tw-animate-in tw-fade-in-0 tw-zoom-in-95 data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=closed]:tw-zoom-out-95 data-[side=bottom]:tw-slide-in-from-top-2 data-[side=left]:tw-slide-in-from-right-2 data-[side=right]:tw-slide-in-from-left-2 data-[side=top]:tw-slide-in-from-bottom-2",e),...n}));As.displayName=Sn.Content.displayName;const Or=768;function Bc(){const[e,t]=M.useState(void 0);return M.useEffect(()=>{const n=window.matchMedia(`(max-width: ${Or-1}px)`),r=()=>{t(window.innerWidthn.removeEventListener("change",r)},[]),!!e}const Vc="sidebar:state",zc=60*60*24*7,Lc="16rem",Fc="18rem",Gc="3rem",Uc="b",Bs=g.createContext(void 0);function cr(){const e=g.useContext(Bs);if(!e)throw new Error("useSidebar must be used within a SidebarProvider.");return e}const Vs=g.forwardRef(({defaultOpen:e=!0,open:t,onOpenChange:n,className:r,style:o,children:s,...i},l)=>{const c=Bc(),[d,u]=g.useState(!1),[h,w]=g.useState(e),b=t??h,x=g.useCallback(R=>{const j=typeof R=="function"?R(b):R;n?n(j):w(j),document.cookie=`${Vc}=${j}; path=/; max-age=${zc}`},[n,b]),f=g.useCallback(()=>c?u(R=>!R):x(R=>!R),[c,x,u]);g.useEffect(()=>{const R=j=>{j.key===Uc&&(j.metaKey||j.ctrlKey)&&(j.preventDefault(),f())};return window.addEventListener("keydown",R),()=>window.removeEventListener("keydown",R)},[f]);const m=b?"expanded":"collapsed",S=g.useMemo(()=>({state:m,open:b,setOpen:x,isMobile:c,openMobile:d,setOpenMobile:u,toggleSidebar:f}),[m,b,x,c,d,u,f]);return a.jsx(Bs.Provider,{value:S,children:a.jsx($c,{delayDuration:0,children:a.jsx("div",{style:{"--sidebar-width":Lc,"--sidebar-width-icon":Gc,...o},className:N("tw-group/sidebar-wrapper pr-twp tw-flex tw-w-full has-[[data-variant=inset]]:tw-bg-sidebar",r),ref:l,...i,children:s})})})});Vs.displayName="SidebarProvider";const zs=g.forwardRef(({side:e="left",variant:t="sidebar",collapsible:n="offcanvas",className:r,children:o,...s},i)=>{const{isMobile:l,state:c,openMobile:d,setOpenMobile:u}=cr();return n==="none"?a.jsx("div",{className:N("tw-flex tw-h-full tw-w-[--sidebar-width] tw-flex-col tw-bg-sidebar tw-text-sidebar-foreground",r),ref:i,...s,children:o}):l?a.jsx(Oc,{open:d,onOpenChange:u,...s,children:a.jsx(Ds,{"data-sidebar":"sidebar","data-mobile":"true",className:"tw-w-[--sidebar-width] tw-bg-sidebar tw-p-0 tw-text-sidebar-foreground [&>button]:tw-hidden",style:{"--sidebar-width":Fc},side:e,children:a.jsx("div",{className:"tw-flex tw-h-full tw-w-full tw-flex-col",children:o})})}):a.jsxs("div",{ref:i,className:"tw-group tw-peer tw-hidden tw-text-sidebar-foreground md:tw-block","data-state":c,"data-collapsible":c==="collapsed"?n:"","data-variant":t,"data-side":e,children:[a.jsx("div",{className:N("tw-relative tw-h-svh tw-w-[--sidebar-width] tw-bg-transparent tw-transition-[width] tw-duration-200 tw-ease-linear","group-data-[collapsible=offcanvas]:tw-w-0","group-data-[side=right]:tw-rotate-180",t==="floating"||t==="inset"?"group-data-[collapsible=icon]:tw-w-[calc(var(--sidebar-width-icon)_+_theme(spacing.4))]":"group-data-[collapsible=icon]:tw-w-[--sidebar-width-icon]")}),a.jsx("div",{className:N("tw-absolute tw-inset-y-0 tw-z-10 tw-hidden tw-h-svh tw-w-[--sidebar-width] tw-transition-[left,right,width] tw-duration-200 tw-ease-linear md:tw-flex",e==="left"?"tw-left-0 group-data-[collapsible=offcanvas]:tw-left-[calc(var(--sidebar-width)*-1)]":"tw-right-0 group-data-[collapsible=offcanvas]:tw-right-[calc(var(--sidebar-width)*-1)]",t==="floating"||t==="inset"?"tw-p-2 group-data-[collapsible=icon]:tw-w-[calc(var(--sidebar-width-icon)_+_theme(spacing.4)_+2px)]":"group-data-[collapsible=icon]:tw-w-[--sidebar-width-icon] group-data-[side=left]:tw-border-r group-data-[side=right]:tw-border-l",r),...s,children:a.jsx("div",{"data-sidebar":"sidebar",className:"tw-flex tw-h-full tw-w-full tw-flex-col tw-bg-sidebar group-data-[variant=floating]:tw-rounded-lg group-data-[variant=floating]:tw-border group-data-[variant=floating]:tw-border-sidebar-border group-data-[variant=floating]:tw-shadow",children:o})})]})});zs.displayName="Sidebar";const qc=g.forwardRef(({className:e,onClick:t,...n},r)=>{const{toggleSidebar:o}=cr();return a.jsxs(fe,{ref:r,"data-sidebar":"trigger",variant:"ghost",size:"icon",className:N("tw-h-7 tw-w-7",e),onClick:s=>{t==null||t(s),o()},...n,children:[a.jsx(Q.PanelLeft,{}),a.jsx("span",{className:"tw-sr-only",children:"Toggle Sidebar"})]})});qc.displayName="SidebarTrigger";const Hc=g.forwardRef(({className:e,...t},n)=>{const{toggleSidebar:r}=cr();return a.jsx("button",{type:"button",ref:n,"data-sidebar":"rail","aria-label":"Toggle Sidebar",tabIndex:-1,onClick:r,title:"Toggle Sidebar",className:N("tw-absolute tw-inset-y-0 tw-z-20 tw-hidden tw-w-4 tw--translate-x-1/2 tw-transition-all tw-ease-linear after:tw-absolute after:tw-inset-y-0 after:tw-left-1/2 after:tw-w-[2px] hover:after:tw-bg-sidebar-border group-data-[side=left]:tw--right-4 group-data-[side=right]:tw-left-0 sm:tw-flex","[[data-side=left]_&]:tw-cursor-w-resize [[data-side=right]_&]:tw-cursor-e-resize","[[data-side=left][data-state=collapsed]_&]:tw-cursor-e-resize [[data-side=right][data-state=collapsed]_&]:tw-cursor-w-resize","group-data-[collapsible=offcanvas]:tw-translate-x-0 group-data-[collapsible=offcanvas]:after:tw-left-full group-data-[collapsible=offcanvas]:hover:tw-bg-sidebar","[[data-side=left][data-collapsible=offcanvas]_&]:tw--right-2","[[data-side=right][data-collapsible=offcanvas]_&]:tw--left-2",e),...t})});Hc.displayName="SidebarRail";const Ls=g.forwardRef(({className:e,...t},n)=>a.jsx("main",{ref:n,className:N("tw-relative tw-flex tw-flex-1 tw-flex-col tw-bg-background","peer-data-[variant=inset]:tw-min-h-[calc(100svh-theme(spacing.4))] md:peer-data-[variant=inset]:tw-m-2 md:peer-data-[state=collapsed]:peer-data-[variant=inset]:tw-ml-2 md:peer-data-[variant=inset]:tw-ml-0 md:peer-data-[variant=inset]:tw-rounded-xl md:peer-data-[variant=inset]:tw-shadow",e),...t}));Ls.displayName="SidebarInset";const Xc=g.forwardRef(({className:e,...t},n)=>a.jsx(St,{ref:n,"data-sidebar":"input",className:N("tw-h-8 tw-w-full tw-bg-background tw-shadow-none focus-visible:tw-ring-2 focus-visible:tw-ring-sidebar-ring",e),...t}));Xc.displayName="SidebarInput";const Yc=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,"data-sidebar":"header",className:N("tw-flex tw-flex-col tw-gap-2 tw-p-2",e),...t}));Yc.displayName="SidebarHeader";const Wc=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,"data-sidebar":"footer",className:N("tw-flex tw-flex-col tw-gap-2 tw-p-2",e),...t}));Wc.displayName="SidebarFooter";const Kc=g.forwardRef(({className:e,...t},n)=>a.jsx(lr,{ref:n,"data-sidebar":"separator",className:N("tw-mx-2 tw-w-auto tw-bg-sidebar-border",e),...t}));Kc.displayName="SidebarSeparator";const Fs=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,"data-sidebar":"content",className:N("tw-flex tw-min-h-0 tw-flex-1 tw-flex-col tw-gap-2 tw-overflow-auto group-data-[collapsible=icon]:tw-overflow-hidden",e),...t}));Fs.displayName="SidebarContent";const Xr=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,"data-sidebar":"group",className:N("tw-relative tw-flex tw-w-full tw-min-w-0 tw-flex-col tw-p-2",e),...t}));Xr.displayName="SidebarGroup";const Yr=g.forwardRef(({className:e,asChild:t=!1,...n},r)=>{const o=t?Ht.Slot:"div";return a.jsx(o,{ref:r,"data-sidebar":"group-label",className:N("tw-flex tw-h-8 tw-shrink-0 tw-items-center tw-rounded-md tw-px-2 tw-text-xs tw-font-medium tw-text-sidebar-foreground/70 tw-outline-none tw-ring-sidebar-ring tw-transition-[margin,opa] tw-duration-200 tw-ease-linear focus-visible:tw-ring-2 [&>svg]:tw-size-4 [&>svg]:tw-shrink-0","group-data-[collapsible=icon]:tw--mt-8 group-data-[collapsible=icon]:tw-opacity-0",e),...n})});Yr.displayName="SidebarGroupLabel";const Jc=g.forwardRef(({className:e,asChild:t=!1,...n},r)=>{const o=t?Ht.Slot:"button";return a.jsx(o,{ref:r,"data-sidebar":"group-action",className:N("tw-absolute tw-right-3 tw-top-3.5 tw-flex tw-aspect-square tw-w-5 tw-items-center tw-justify-center tw-rounded-md tw-p-0 tw-text-sidebar-foreground tw-outline-none tw-ring-sidebar-ring tw-transition-transform hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground focus-visible:tw-ring-2 [&>svg]:tw-size-4 [&>svg]:tw-shrink-0","after:tw-absolute after:tw--inset-2 after:md:tw-hidden","group-data-[collapsible=icon]:tw-hidden",e),...n})});Jc.displayName="SidebarGroupAction";const Wr=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,"data-sidebar":"group-content",className:N("tw-w-full tw-text-sm",e),...t}));Wr.displayName="SidebarGroupContent";const Gs=g.forwardRef(({className:e,...t},n)=>a.jsx("ul",{ref:n,"data-sidebar":"menu",className:N("tw-flex tw-w-full tw-min-w-0 tw-flex-col tw-gap-1",e),...t}));Gs.displayName="SidebarMenu";const Us=g.forwardRef(({className:e,...t},n)=>a.jsx("li",{ref:n,"data-sidebar":"menu-item",className:N("tw-group/menu-item tw-relative",e),...t}));Us.displayName="SidebarMenuItem";const Zc=Xt.cva("tw-peer/menu-button tw-flex tw-w-full tw-items-center tw-gap-2 tw-overflow-hidden tw-rounded-md tw-p-2 tw-text-left tw-text-sm tw-outline-none tw-ring-sidebar-ring tw-transition-[width,height,padding] hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground focus-visible:tw-ring-2 active:tw-bg-sidebar-accent active:tw-text-sidebar-accent-foreground disabled:tw-pointer-events-none disabled:tw-opacity-50 tw-group-has-[[data-sidebar=menu-action]]/menu-item:pr-8 aria-disabled:tw-pointer-events-none aria-disabled:tw-opacity-50 data-[active=true]:tw-font-medium data-[active=true]:tw-text-sidebar-accent-foreground data-[state=open]:hover:tw-bg-sidebar-accent data-[state=open]:hover:tw-text-sidebar-accent-foreground group-data-[collapsible=icon]:tw-!size-8 group-data-[collapsible=icon]:tw-!p-2 [&>span:last-child]:tw-truncate [&>svg]:tw-size-4 [&>svg]:tw-shrink-0",{variants:{variant:{default:"hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground",outline:"tw-bg-background tw-shadow-[0_0_0_1px_hsl(var(--sidebar-border))] hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground hover:tw-shadow-[0_0_0_1px_hsl(var(--sidebar-accent))]"},size:{default:"tw-h-8 tw-text-sm",sm:"tw-h-7 tw-text-xs",lg:"tw-h-12 tw-text-sm group-data-[collapsible=icon]:tw-!p-0"}},defaultVariants:{variant:"default",size:"default"}}),qs=g.forwardRef(({asChild:e=!1,isActive:t=!1,variant:n="default",size:r="default",tooltip:o,className:s,...i},l)=>{const c=e?Ht.Slot:"button",{isMobile:d,state:u}=cr(),h=a.jsx(c,{ref:l,"data-sidebar":"menu-button","data-size":r,"data-active":t,className:N(Zc({variant:n,size:r}),s),...i});return o?(typeof o=="string"&&(o={children:o}),a.jsxs(Dc,{children:[a.jsx(Ac,{asChild:!0,children:h}),a.jsx(As,{side:"right",align:"center",hidden:u!=="collapsed"||d,...o})]})):h});qs.displayName="SidebarMenuButton";const Qc=g.forwardRef(({className:e,asChild:t=!1,showOnHover:n=!1,...r},o)=>{const s=t?Ht.Slot:"button";return a.jsx(s,{ref:o,"data-sidebar":"menu-action",className:N("tw-peer-hover/menu-button:text-sidebar-accent-foreground tw-absolute tw-right-1 tw-top-1.5 tw-flex tw-aspect-square tw-w-5 tw-items-center tw-justify-center tw-rounded-md tw-p-0 tw-text-sidebar-foreground tw-outline-none tw-ring-sidebar-ring tw-transition-transform hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground focus-visible:tw-ring-2 [&>svg]:tw-size-4 [&>svg]:tw-shrink-0","after:tw-absolute after:tw--inset-2 after:md:tw-hidden","tw-peer-data-[size=sm]/menu-button:top-1","tw-peer-data-[size=default]/menu-button:top-1.5","tw-peer-data-[size=lg]/menu-button:top-2.5","group-data-[collapsible=icon]:tw-hidden",n&&"tw-group-focus-within/menu-item:opacity-100 tw-group-hover/menu-item:opacity-100 tw-peer-data-[active=true]/menu-button:text-sidebar-accent-foreground data-[state=open]:tw-opacity-100 md:tw-opacity-0",e),...r})});Qc.displayName="SidebarMenuAction";const ed=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,"data-sidebar":"menu-badge",className:N("tw-pointer-events-none tw-absolute tw-right-1 tw-flex tw-h-5 tw-min-w-5 tw-select-none tw-items-center tw-justify-center tw-rounded-md tw-px-1 tw-text-xs tw-font-medium tw-tabular-nums tw-text-sidebar-foreground","tw-peer-hover/menu-button:text-sidebar-accent-foreground tw-peer-data-[active=true]/menu-button:text-sidebar-accent-foreground","tw-peer-data-[size=sm]/menu-button:top-1","tw-peer-data-[size=default]/menu-button:top-1.5","tw-peer-data-[size=lg]/menu-button:top-2.5","group-data-[collapsible=icon]:tw-hidden",e),...t}));ed.displayName="SidebarMenuBadge";const td=g.forwardRef(({className:e,showIcon:t=!1,...n},r)=>{const o=g.useMemo(()=>`${Math.floor(Math.random()*40)+50}%`,[]);return a.jsxs("div",{ref:r,"data-sidebar":"menu-skeleton",className:N("tw-flex tw-h-8 tw-items-center tw-gap-2 tw-rounded-md tw-px-2",e),...n,children:[t&&a.jsx(sa,{className:"tw-size-4 tw-rounded-md","data-sidebar":"menu-skeleton-icon"}),a.jsx(sa,{className:"tw-h-4 tw-max-w-[--skeleton-width] tw-flex-1","data-sidebar":"menu-skeleton-text",style:{"--skeleton-width":o}})]})});td.displayName="SidebarMenuSkeleton";const nd=g.forwardRef(({className:e,...t},n)=>a.jsx("ul",{ref:n,"data-sidebar":"menu-sub",className:N("tw-mx-3.5 tw-flex tw-min-w-0 tw-translate-x-px tw-flex-col tw-gap-1 tw-border-l tw-border-sidebar-border tw-px-2.5 tw-py-0.5","group-data-[collapsible=icon]:tw-hidden",e),...t}));nd.displayName="SidebarMenuSub";const rd=g.forwardRef(({...e},t)=>a.jsx("li",{ref:t,...e}));rd.displayName="SidebarMenuSubItem";const od=g.forwardRef(({asChild:e=!1,size:t="md",isActive:n,className:r,...o},s)=>{const i=e?Ht.Slot:"a";return a.jsx(i,{ref:s,"data-sidebar":"menu-sub-button","data-size":t,"data-active":n,className:N("tw-flex tw-h-7 tw-min-w-0 tw--translate-x-px tw-items-center tw-gap-2 tw-overflow-hidden tw-rounded-md tw-px-2 tw-text-sidebar-foreground tw-outline-none tw-ring-sidebar-ring hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground focus-visible:tw-ring-2 active:tw-bg-sidebar-accent active:tw-text-sidebar-accent-foreground disabled:tw-pointer-events-none disabled:tw-opacity-50 aria-disabled:tw-pointer-events-none aria-disabled:tw-opacity-50 [&>span:last-child]:tw-truncate [&>svg]:tw-size-4 [&>svg]:tw-shrink-0 [&>svg]:tw-text-sidebar-accent-foreground","data-[active=true]:tw-bg-sidebar-accent data-[active=true]:tw-text-sidebar-accent-foreground",t==="sm"&&"tw-text-xs",t==="md"&&"tw-text-sm","group-data-[collapsible=icon]:tw-hidden",r),...o})});od.displayName="SidebarMenuSubButton";function Hs({id:e,extensionLabels:t,projectOptions:n,handleSelectSidebarItem:r,selectedSidebarItem:o}){const s=g.useCallback((c,d)=>{r(c,d)},[r]),i=g.useCallback(c=>{const d=n.find(u=>u.projectId===c);return d?d.projectName:c},[n]),l=g.useCallback(c=>!o.projectId&&c===o.label,[o]);return a.jsx(zs,{id:e,collapsible:"none",variant:"inset",className:"tw-w-96 tw-gap-2 tw-overflow-y-auto tw-rounded tw-bg-slate-100",children:a.jsxs(Fs,{children:[a.jsxs(Xr,{children:[a.jsx(Yr,{className:"tw-text-sm tw-text-gray-400",children:"Extensions"}),a.jsx(Wr,{children:a.jsx(Gs,{children:t.map(c=>a.jsx(Us,{children:a.jsx(qs,{className:N("tw-rounded tw-py-2 tw-text-sm tw-text-gray-500 hover:tw-bg-white hover:tw-text-gray-900 hover:tw-shadow-sm active:tw-bg-white",{"tw-bg-white tw-text-gray-900 tw-shadow-sm":l(c)}),onClick:()=>s(c,void 0),isActive:l(c),children:a.jsx("span",{className:"tw-pl-3",children:c})})},c))})})]}),a.jsxs(Xr,{children:[a.jsx(Yr,{className:"tw-text-sm tw-text-gray-400",children:"Projects"}),a.jsx(Wr,{className:"tw-pl-3",children:a.jsx(Wn,{popoverContentClassName:"tw-z-[1000]",options:n.flatMap(c=>c.projectId),getOptionLabel:c=>i(c),buttonPlaceholder:"Type or select project",onChange:c=>{const d=i(c);s(d,c)},value:(o==null?void 0:o.projectId)??void 0})})]})]})})}function ad({id:e,direction:t="ltr",extensionLabels:n,projectOptions:r,children:o,handleSelectSidebarItem:s,selectedSidebarItem:i,onSearch:l}){return a.jsxs("div",{className:"tw-flex tw-h-full tw-flex-col tw-p-3 tw-pb-2",children:[a.jsx("div",{className:"tw-flex tw-items-center tw-justify-center tw-py-4",children:a.jsx(ho,{className:"tw-w-9/12",onSearch:l,placeholder:"Search app settings, extension settings, and project settings"})}),a.jsxs(Vs,{dir:t,id:e,className:"tw-h-full tw-flex-1 tw-gap-4",children:[a.jsx(Hs,{extensionLabels:n,projectOptions:r,handleSelectSidebarItem:s,selectedSidebarItem:i}),a.jsx(Ls,{className:"tw-overflow-y-auto",children:o})]})]})}const rt="scrBook",sd="scrRef",pt="source",id="details",ld="Scripture Reference",cd="Scripture Book",Xs="Type",dd="Details";function ud(e,t){const n=t??!1;return[{accessorFn:r=>`${ae.bookNumberToId(r.start.bookNum)} ${r.start.chapterNum}:${r.start.verseNum}`,id:rt,header:(e==null?void 0:e.scriptureReferenceColumnName)??ld,cell:r=>{const o=r.row.original;return r.row.getIsGrouped()?ae.bookNumberToEnglishName(o.start.bookNum):r.row.groupingColumnId===rt?W.formatScrRef(o.start):void 0},getGroupingValue:r=>r.start.bookNum,sortingFn:(r,o)=>W.compareScrRefs(r.original.start,o.original.start),enableGrouping:!0},{accessorFn:r=>W.formatScrRef(r.start),id:sd,header:void 0,cell:r=>{const o=r.row.original;return r.row.getIsGrouped()?void 0:W.formatScrRef(o.start)},sortingFn:(r,o)=>W.compareScrRefs(r.original.start,o.original.start),enableGrouping:!1},{accessorFn:r=>r.source.displayName,id:pt,header:n?(e==null?void 0:e.typeColumnName)??Xs:void 0,cell:r=>n||r.row.getIsGrouped()?r.getValue():void 0,getGroupingValue:r=>r.source.id,sortingFn:(r,o)=>r.original.source.displayName.localeCompare(o.original.source.displayName),enableGrouping:!0},{accessorFn:r=>r.detail,id,header:(e==null?void 0:e.detailsColumnName)??dd,cell:r=>r.getValue(),enableGrouping:!1}]}const pd=e=>{if(!("offset"in e.start))throw new Error("No offset available in range start");if(e.end&&!("offset"in e.end))throw new Error("No offset available in range end");const{offset:t}=e.start;let n=0;return e.end&&({offset:n}=e.end),!e.end||W.compareScrRefs(e.start,e.end)===0?`${W.scrRefToBBBCCCVVV(e.start)}+${t}`:`${W.scrRefToBBBCCCVVV(e.start)}+${t}-${W.scrRefToBBBCCCVVV(e.end)}+${n}`},ia=e=>`${pd({start:e.start,end:e.end})} ${e.source.displayName} ${e.detail}`;function wd({sources:e,showColumnHeaders:t=!1,showSourceColumn:n=!1,scriptureReferenceColumnName:r,scriptureBookGroupName:o,typeColumnName:s,detailsColumnName:i,onRowSelected:l,direction:c="ltr"}){const[d,u]=g.useState([]),[h,w]=g.useState([{id:rt,desc:!1}]),[b,x]=g.useState({}),f=g.useMemo(()=>e.flatMap(C=>C.data.map(_=>({..._,source:C.source}))),[e]),m=g.useMemo(()=>ud({scriptureReferenceColumnName:r,typeColumnName:s,detailsColumnName:i},n),[r,s,i,n]);g.useEffect(()=>{d.includes(pt)?w([{id:pt,desc:!1},{id:rt,desc:!1}]):w([{id:rt,desc:!1}])},[d]);const S=Se.useReactTable({data:f,columns:m,state:{grouping:d,sorting:h,rowSelection:b},onGroupingChange:u,onSortingChange:w,onRowSelectionChange:x,getExpandedRowModel:Se.getExpandedRowModel(),getGroupedRowModel:Se.getGroupedRowModel(),getCoreRowModel:Se.getCoreRowModel(),getSortedRowModel:Se.getSortedRowModel(),getRowId:ia,autoResetExpanded:!1,enableMultiRowSelection:!1,enableSubRowSelection:!1});g.useEffect(()=>{if(l){const C=S.getSelectedRowModel().rowsById,_=Object.keys(C);if(_.length===1){const k=f.find(D=>ia(D)===_[0])||void 0;k&&l(k)}}},[b,f,l,S]);const R=o??cd,j=s??Xs,E=[{label:"No Grouping",value:[]},{label:`Group by ${R}`,value:[rt]},{label:`Group by ${j}`,value:[pt]},{label:`Group by ${R} and ${j}`,value:[rt,pt]},{label:`Group by ${j} and ${R}`,value:[pt,rt]}],v=C=>{u(JSON.parse(C))},P=(C,_)=>{!C.getIsGrouped()&&!C.getIsSelected()&&C.getToggleSelectedHandler()(_)},V=(C,_)=>C.getIsGrouped()?"":N("banded-row",_%2===0?"even":"odd"),U=(C,_,k)=>{if(!((C==null?void 0:C.length)===0||_.depth{v(C)},children:[a.jsx(bt,{className:"tw-mb-1 tw-mt-2",children:a.jsx(Bt,{})}),a.jsx(vt,{position:"item-aligned",children:a.jsx(ks,{children:E.map(C=>a.jsx(Ae,{value:JSON.stringify(C.value),children:C.label},C.label))})})]}),a.jsxs(Cn,{className:"tw-relative tw-flex tw-flex-col tw-overflow-y-auto tw-p-0",children:[t&&a.jsx(Tn,{children:S.getHeaderGroups().map(C=>a.jsx(Ze,{children:C.headers.filter(_=>_.column.columnDef.header).map(_=>a.jsx(Vt,{colSpan:_.colSpan,className:"top-0 tw-sticky",children:_.isPlaceholder?void 0:a.jsxs("div",{children:[_.column.getCanGroup()?a.jsx(fe,{variant:"ghost",title:`Toggle grouping by ${_.column.columnDef.header}`,onClick:_.column.getToggleGroupingHandler(),type:"button",children:_.column.getIsGrouped()?"🛑":"👊 "}):void 0," ",Se.flexRender(_.column.columnDef.header,_.getContext())]})},_.id))},C.id))}),a.jsx(Rn,{children:S.getRowModel().rows.map((C,_)=>a.jsx(Ze,{"data-state":C.getIsSelected()?"selected":"",className:N(V(C,_)),onClick:k=>P(C,k),children:C.getVisibleCells().map(k=>{if(!(k.getIsPlaceholder()||k.column.columnDef.enableGrouping&&!k.getIsGrouped()&&(k.column.columnDef.id!==pt||!n)))return a.jsx(xt,{className:N(k.column.columnDef.id,"tw-p-[1px]",U(d,C,k)),children:(()=>k.getIsGrouped()?a.jsxs(fe,{variant:"link",onClick:C.getToggleExpandedHandler(),type:"button",children:[C.getIsExpanded()&&a.jsx(Q.ChevronDown,{}),!C.getIsExpanded()&&(c==="ltr"?a.jsx(Q.ChevronRight,{}):a.jsx(Q.ChevronLeft,{}))," ",Se.flexRender(k.column.columnDef.cell,k.getContext())," (",C.subRows.length,")"]}):Se.flexRender(k.column.columnDef.cell,k.getContext()))()},k.id)})},C.id))})]})]})}const _r={[W.getLocalizeKeyForScrollGroupId("undefined")]:"Ø",[W.getLocalizeKeyForScrollGroupId(0)]:"A",[W.getLocalizeKeyForScrollGroupId(1)]:"B",[W.getLocalizeKeyForScrollGroupId(2)]:"C",[W.getLocalizeKeyForScrollGroupId(3)]:"D",[W.getLocalizeKeyForScrollGroupId(4)]:"E",[W.getLocalizeKeyForScrollGroupId(5)]:"F",[W.getLocalizeKeyForScrollGroupId(6)]:"G",[W.getLocalizeKeyForScrollGroupId(7)]:"H",[W.getLocalizeKeyForScrollGroupId(8)]:"I",[W.getLocalizeKeyForScrollGroupId(9)]:"J",[W.getLocalizeKeyForScrollGroupId(10)]:"K",[W.getLocalizeKeyForScrollGroupId(11)]:"L",[W.getLocalizeKeyForScrollGroupId(12)]:"M",[W.getLocalizeKeyForScrollGroupId(13)]:"N",[W.getLocalizeKeyForScrollGroupId(14)]:"O",[W.getLocalizeKeyForScrollGroupId(15)]:"P",[W.getLocalizeKeyForScrollGroupId(16)]:"Q",[W.getLocalizeKeyForScrollGroupId(17)]:"R",[W.getLocalizeKeyForScrollGroupId(18)]:"S",[W.getLocalizeKeyForScrollGroupId(19)]:"T",[W.getLocalizeKeyForScrollGroupId(20)]:"U",[W.getLocalizeKeyForScrollGroupId(21)]:"V",[W.getLocalizeKeyForScrollGroupId(22)]:"W",[W.getLocalizeKeyForScrollGroupId(23)]:"X",[W.getLocalizeKeyForScrollGroupId(24)]:"Y",[W.getLocalizeKeyForScrollGroupId(25)]:"Z"};function fd({availableScrollGroupIds:e,scrollGroupId:t,onChangeScrollGroupId:n,localizedStrings:r={}}){const o={..._r,...Object.fromEntries(Object.entries(r).map(([s,i])=>[s,s===i&&s in _r?_r[s]:i]))};return a.jsxs(At,{value:`${t}`,onValueChange:s=>n(s==="undefined"?void 0:parseInt(s,10)),children:[a.jsx(bt,{className:"pr-twp tw-w-auto",children:a.jsx(Bt,{placeholder:o[W.getLocalizeKeyForScrollGroupId(t)]??t})}),a.jsx(vt,{style:{zIndex:250},children:e.map(s=>a.jsx(Ae,{value:`${s}`,children:o[W.getLocalizeKeyForScrollGroupId(s)]},`${s}`))})]})}function md({children:e}){return a.jsx("div",{className:"pr-twp tw-grid",children:e})}function hd({primary:e,secondary:t,children:n,isLoading:r=!1,loadingMessage:o}){return a.jsxs("div",{className:"tw-flex tw-items-center tw-justify-between tw-space-x-4 tw-py-2",children:[a.jsxs("div",{children:[a.jsx("p",{className:"tw-text-sm tw-font-medium tw-leading-none",children:e}),a.jsx("p",{className:"tw-whitespace-normal tw-break-words tw-text-sm tw-text-muted-foreground",children:t})]}),r?a.jsx("p",{className:"tw-text-sm tw-text-muted-foreground",children:o}):a.jsx("div",{children:n})]})}function gd({primary:e,secondary:t,includeSeparator:n=!1}){return a.jsxs("div",{className:"tw-space-y-4 tw-py-2",children:[a.jsxs("div",{children:[a.jsx("h3",{className:"tw-text-lg tw-font-medium",children:e}),a.jsx("p",{className:"tw-text-sm tw-text-muted-foreground",children:t})]}),n?a.jsx(lr,{}):""]})}function bd({id:e,className:t,listItems:n,selectedListItems:r,handleSelectListItem:o,createLabel:s}){return a.jsx("div",{id:e,className:t,children:n.map(i=>a.jsxs("div",{className:"tw-m-2 tw-flex tw-items-center",children:[a.jsx(sr,{className:"tw-mr-2 tw-align-middle",checked:r.includes(i),onCheckedChange:l=>o(i,l)}),a.jsx(qe,{children:s?s(i):i})]},i))})}function vd(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}function xd(e){if(e.__esModule)return e;var t=e.default;if(typeof t=="function"){var n=function r(){return this instanceof r?Reflect.construct(t,arguments,this.constructor):t.apply(this,arguments)};n.prototype=t.prototype}else n={};return Object.defineProperty(n,"__esModule",{value:!0}),Object.keys(e).forEach(function(r){var o=Object.getOwnPropertyDescriptor(e,r);Object.defineProperty(n,r,o.get?o:{enumerable:!0,get:function(){return e[r]}})}),n}var xo={},Ys={exports:{}};(function(e){function t(n){return n&&n.__esModule?n:{default:n}}e.exports=t,e.exports.__esModule=!0,e.exports.default=e.exports})(Ys);var yd=Ys.exports,Pr={};function yo(e,t){return process.env.NODE_ENV==="production"?()=>null:function(...r){return e(...r)||t(...r)}}function O(){return O=Object.assign?Object.assign.bind():function(e){for(var t=1;t{t[n]=Ws(e[n])}),t}function Qe(e,t,n={clone:!0}){const r=n.clone?O({},e):e;return mt(e)&&mt(t)&&Object.keys(t).forEach(o=>{o!=="__proto__"&&(mt(t[o])&&o in e&&mt(e[o])?r[o]=Qe(e[o],t[o],n):n.clone?r[o]=mt(t[o])?Ws(t[o]):t[o]:r[o]=t[o])}),r}var Kr={exports:{}},zn={exports:{}},ie={};/** @license React v16.13.1 * react-is.production.min.js * * Copyright (c) Facebook, Inc. and its affiliates. * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. - */var wa;function kd(){if(wa)return ie;wa=1;var e=typeof Symbol=="function"&&Symbol.for,t=e?Symbol.for("react.element"):60103,n=e?Symbol.for("react.portal"):60106,r=e?Symbol.for("react.fragment"):60107,o=e?Symbol.for("react.strict_mode"):60108,s=e?Symbol.for("react.profiler"):60114,i=e?Symbol.for("react.provider"):60109,l=e?Symbol.for("react.context"):60110,c=e?Symbol.for("react.async_mode"):60111,d=e?Symbol.for("react.concurrent_mode"):60111,u=e?Symbol.for("react.forward_ref"):60112,h=e?Symbol.for("react.suspense"):60113,w=e?Symbol.for("react.suspense_list"):60120,b=e?Symbol.for("react.memo"):60115,x=e?Symbol.for("react.lazy"):60116,f=e?Symbol.for("react.block"):60121,m=e?Symbol.for("react.fundamental"):60117,S=e?Symbol.for("react.responder"):60118,R=e?Symbol.for("react.scope"):60119;function j(v){if(typeof v=="object"&&v!==null){var P=v.$$typeof;switch(P){case t:switch(v=v.type,v){case c:case d:case r:case s:case o:case h:return v;default:switch(v=v&&v.$$typeof,v){case l:case u:case x:case b:case i:return v;default:return P}}case n:return P}}}function E(v){return j(v)===d}return ie.AsyncMode=c,ie.ConcurrentMode=d,ie.ContextConsumer=l,ie.ContextProvider=i,ie.Element=t,ie.ForwardRef=u,ie.Fragment=r,ie.Lazy=x,ie.Memo=b,ie.Portal=n,ie.Profiler=s,ie.StrictMode=o,ie.Suspense=h,ie.isAsyncMode=function(v){return E(v)||j(v)===c},ie.isConcurrentMode=E,ie.isContextConsumer=function(v){return j(v)===l},ie.isContextProvider=function(v){return j(v)===i},ie.isElement=function(v){return typeof v=="object"&&v!==null&&v.$$typeof===t},ie.isForwardRef=function(v){return j(v)===u},ie.isFragment=function(v){return j(v)===r},ie.isLazy=function(v){return j(v)===x},ie.isMemo=function(v){return j(v)===b},ie.isPortal=function(v){return j(v)===n},ie.isProfiler=function(v){return j(v)===s},ie.isStrictMode=function(v){return j(v)===o},ie.isSuspense=function(v){return j(v)===h},ie.isValidElementType=function(v){return typeof v=="string"||typeof v=="function"||v===r||v===d||v===s||v===o||v===h||v===w||typeof v=="object"&&v!==null&&(v.$$typeof===x||v.$$typeof===b||v.$$typeof===i||v.$$typeof===l||v.$$typeof===u||v.$$typeof===m||v.$$typeof===S||v.$$typeof===R||v.$$typeof===f)},ie.typeOf=j,ie}var le={};/** @license React v16.13.1 + */var la;function Nd(){if(la)return ie;la=1;var e=typeof Symbol=="function"&&Symbol.for,t=e?Symbol.for("react.element"):60103,n=e?Symbol.for("react.portal"):60106,r=e?Symbol.for("react.fragment"):60107,o=e?Symbol.for("react.strict_mode"):60108,s=e?Symbol.for("react.profiler"):60114,i=e?Symbol.for("react.provider"):60109,l=e?Symbol.for("react.context"):60110,c=e?Symbol.for("react.async_mode"):60111,d=e?Symbol.for("react.concurrent_mode"):60111,u=e?Symbol.for("react.forward_ref"):60112,h=e?Symbol.for("react.suspense"):60113,w=e?Symbol.for("react.suspense_list"):60120,b=e?Symbol.for("react.memo"):60115,x=e?Symbol.for("react.lazy"):60116,f=e?Symbol.for("react.block"):60121,m=e?Symbol.for("react.fundamental"):60117,S=e?Symbol.for("react.responder"):60118,R=e?Symbol.for("react.scope"):60119;function j(v){if(typeof v=="object"&&v!==null){var P=v.$$typeof;switch(P){case t:switch(v=v.type,v){case c:case d:case r:case s:case o:case h:return v;default:switch(v=v&&v.$$typeof,v){case l:case u:case x:case b:case i:return v;default:return P}}case n:return P}}}function E(v){return j(v)===d}return ie.AsyncMode=c,ie.ConcurrentMode=d,ie.ContextConsumer=l,ie.ContextProvider=i,ie.Element=t,ie.ForwardRef=u,ie.Fragment=r,ie.Lazy=x,ie.Memo=b,ie.Portal=n,ie.Profiler=s,ie.StrictMode=o,ie.Suspense=h,ie.isAsyncMode=function(v){return E(v)||j(v)===c},ie.isConcurrentMode=E,ie.isContextConsumer=function(v){return j(v)===l},ie.isContextProvider=function(v){return j(v)===i},ie.isElement=function(v){return typeof v=="object"&&v!==null&&v.$$typeof===t},ie.isForwardRef=function(v){return j(v)===u},ie.isFragment=function(v){return j(v)===r},ie.isLazy=function(v){return j(v)===x},ie.isMemo=function(v){return j(v)===b},ie.isPortal=function(v){return j(v)===n},ie.isProfiler=function(v){return j(v)===s},ie.isStrictMode=function(v){return j(v)===o},ie.isSuspense=function(v){return j(v)===h},ie.isValidElementType=function(v){return typeof v=="string"||typeof v=="function"||v===r||v===d||v===s||v===o||v===h||v===w||typeof v=="object"&&v!==null&&(v.$$typeof===x||v.$$typeof===b||v.$$typeof===i||v.$$typeof===l||v.$$typeof===u||v.$$typeof===m||v.$$typeof===S||v.$$typeof===R||v.$$typeof===f)},ie.typeOf=j,ie}var le={};/** @license React v16.13.1 * react-is.development.js * * Copyright (c) Facebook, Inc. and its affiliates. * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. - */var fa;function Sd(){return fa||(fa=1,process.env.NODE_ENV!=="production"&&function(){var e=typeof Symbol=="function"&&Symbol.for,t=e?Symbol.for("react.element"):60103,n=e?Symbol.for("react.portal"):60106,r=e?Symbol.for("react.fragment"):60107,o=e?Symbol.for("react.strict_mode"):60108,s=e?Symbol.for("react.profiler"):60114,i=e?Symbol.for("react.provider"):60109,l=e?Symbol.for("react.context"):60110,c=e?Symbol.for("react.async_mode"):60111,d=e?Symbol.for("react.concurrent_mode"):60111,u=e?Symbol.for("react.forward_ref"):60112,h=e?Symbol.for("react.suspense"):60113,w=e?Symbol.for("react.suspense_list"):60120,b=e?Symbol.for("react.memo"):60115,x=e?Symbol.for("react.lazy"):60116,f=e?Symbol.for("react.block"):60121,m=e?Symbol.for("react.fundamental"):60117,S=e?Symbol.for("react.responder"):60118,R=e?Symbol.for("react.scope"):60119;function j(I){return typeof I=="string"||typeof I=="function"||I===r||I===d||I===s||I===o||I===h||I===w||typeof I=="object"&&I!==null&&(I.$$typeof===x||I.$$typeof===b||I.$$typeof===i||I.$$typeof===l||I.$$typeof===u||I.$$typeof===m||I.$$typeof===S||I.$$typeof===R||I.$$typeof===f)}function E(I){if(typeof I=="object"&&I!==null){var ye=I.$$typeof;switch(ye){case t:var D=I.type;switch(D){case c:case d:case r:case s:case o:case h:return D;default:var xe=D&&D.$$typeof;switch(xe){case l:case u:case x:case b:case i:return xe;default:return ye}}case n:return ye}}}var v=c,P=d,V=l,U=i,C=t,_=u,k=r,A=x,$=b,J=n,Y=s,F=o,te=h,se=!1;function oe(I){return se||(se=!0,console.warn("The ReactIs.isAsyncMode() alias has been deprecated, and will be removed in React 17+. Update your code to use ReactIs.isConcurrentMode() instead. It has the exact same API.")),y(I)||E(I)===c}function y(I){return E(I)===d}function T(I){return E(I)===l}function z(I){return E(I)===i}function L(I){return typeof I=="object"&&I!==null&&I.$$typeof===t}function B(I){return E(I)===u}function X(I){return E(I)===r}function q(I){return E(I)===x}function H(I){return E(I)===b}function G(I){return E(I)===n}function K(I){return E(I)===s}function Z(I){return E(I)===o}function ue(I){return E(I)===h}le.AsyncMode=v,le.ConcurrentMode=P,le.ContextConsumer=V,le.ContextProvider=U,le.Element=C,le.ForwardRef=_,le.Fragment=k,le.Lazy=A,le.Memo=$,le.Portal=J,le.Profiler=Y,le.StrictMode=F,le.Suspense=te,le.isAsyncMode=oe,le.isConcurrentMode=y,le.isContextConsumer=T,le.isContextProvider=z,le.isElement=L,le.isForwardRef=B,le.isFragment=X,le.isLazy=q,le.isMemo=H,le.isPortal=G,le.isProfiler=K,le.isStrictMode=Z,le.isSuspense=ue,le.isValidElementType=j,le.typeOf=E}()),le}var ma;function ni(){return ma||(ma=1,process.env.NODE_ENV==="production"?zn.exports=kd():zn.exports=Sd()),zn.exports}/* + */var ca;function kd(){return ca||(ca=1,process.env.NODE_ENV!=="production"&&function(){var e=typeof Symbol=="function"&&Symbol.for,t=e?Symbol.for("react.element"):60103,n=e?Symbol.for("react.portal"):60106,r=e?Symbol.for("react.fragment"):60107,o=e?Symbol.for("react.strict_mode"):60108,s=e?Symbol.for("react.profiler"):60114,i=e?Symbol.for("react.provider"):60109,l=e?Symbol.for("react.context"):60110,c=e?Symbol.for("react.async_mode"):60111,d=e?Symbol.for("react.concurrent_mode"):60111,u=e?Symbol.for("react.forward_ref"):60112,h=e?Symbol.for("react.suspense"):60113,w=e?Symbol.for("react.suspense_list"):60120,b=e?Symbol.for("react.memo"):60115,x=e?Symbol.for("react.lazy"):60116,f=e?Symbol.for("react.block"):60121,m=e?Symbol.for("react.fundamental"):60117,S=e?Symbol.for("react.responder"):60118,R=e?Symbol.for("react.scope"):60119;function j(I){return typeof I=="string"||typeof I=="function"||I===r||I===d||I===s||I===o||I===h||I===w||typeof I=="object"&&I!==null&&(I.$$typeof===x||I.$$typeof===b||I.$$typeof===i||I.$$typeof===l||I.$$typeof===u||I.$$typeof===m||I.$$typeof===S||I.$$typeof===R||I.$$typeof===f)}function E(I){if(typeof I=="object"&&I!==null){var ye=I.$$typeof;switch(ye){case t:var A=I.type;switch(A){case c:case d:case r:case s:case o:case h:return A;default:var xe=A&&A.$$typeof;switch(xe){case l:case u:case x:case b:case i:return xe;default:return ye}}case n:return ye}}}var v=c,P=d,V=l,U=i,C=t,_=u,k=r,D=x,$=b,J=n,Y=s,F=o,te=h,se=!1;function oe(I){return se||(se=!0,console.warn("The ReactIs.isAsyncMode() alias has been deprecated, and will be removed in React 17+. Update your code to use ReactIs.isConcurrentMode() instead. It has the exact same API.")),y(I)||E(I)===c}function y(I){return E(I)===d}function T(I){return E(I)===l}function z(I){return E(I)===i}function L(I){return typeof I=="object"&&I!==null&&I.$$typeof===t}function B(I){return E(I)===u}function X(I){return E(I)===r}function q(I){return E(I)===x}function H(I){return E(I)===b}function G(I){return E(I)===n}function K(I){return E(I)===s}function Z(I){return E(I)===o}function ue(I){return E(I)===h}le.AsyncMode=v,le.ConcurrentMode=P,le.ContextConsumer=V,le.ContextProvider=U,le.Element=C,le.ForwardRef=_,le.Fragment=k,le.Lazy=D,le.Memo=$,le.Portal=J,le.Profiler=Y,le.StrictMode=F,le.Suspense=te,le.isAsyncMode=oe,le.isConcurrentMode=y,le.isContextConsumer=T,le.isContextProvider=z,le.isElement=L,le.isForwardRef=B,le.isFragment=X,le.isLazy=q,le.isMemo=H,le.isPortal=G,le.isProfiler=K,le.isStrictMode=Z,le.isSuspense=ue,le.isValidElementType=j,le.typeOf=E}()),le}var da;function Ks(){return da||(da=1,process.env.NODE_ENV==="production"?zn.exports=Nd():zn.exports=kd()),zn.exports}/* object-assign (c) Sindre Sorhus @license MIT -*/var Ir,ha;function Ed(){if(ha)return Ir;ha=1;var e=Object.getOwnPropertySymbols,t=Object.prototype.hasOwnProperty,n=Object.prototype.propertyIsEnumerable;function r(s){if(s==null)throw new TypeError("Object.assign cannot be called with null or undefined");return Object(s)}function o(){try{if(!Object.assign)return!1;var s=new String("abc");if(s[5]="de",Object.getOwnPropertyNames(s)[0]==="5")return!1;for(var i={},l=0;l<10;l++)i["_"+String.fromCharCode(l)]=l;var c=Object.getOwnPropertyNames(i).map(function(u){return i[u]});if(c.join("")!=="0123456789")return!1;var d={};return"abcdefghijklmnopqrst".split("").forEach(function(u){d[u]=u}),Object.keys(Object.assign({},d)).join("")==="abcdefghijklmnopqrst"}catch{return!1}}return Ir=o()?Object.assign:function(s,i){for(var l,c=r(s),d,u=1;u1?s("Invalid arguments supplied to oneOf, expected an array, got "+arguments.length+" arguments. A common mistake is to write oneOf(x, y, z) instead of oneOf([x, y, z])."):s("Invalid argument supplied to oneOf, expected an array.")),i;function T(z,L,B,X,q){for(var H=z[L],G=0;G0?", expected one of type ["+K.join(", ")+"]":"";return new f("Invalid "+H+" `"+G+"` supplied to "+("`"+q+"`"+ye+"."))}return m(L)}function _(){function y(T,z,L,B,X){return J(T[z])?null:new f("Invalid "+B+" `"+X+"` supplied to "+("`"+L+"`, expected a ReactNode."))}return m(y)}function k(y,T,z,L,B){return new f((y||"React class")+": "+T+" type `"+z+"."+L+"` is invalid; it must be a function, usually from the `prop-types` package, but received `"+B+"`.")}function A(y){function T(z,L,B,X,q){var H=z[L],G=F(H);if(G!=="object")return new f("Invalid "+X+" `"+q+"` of type `"+G+"` "+("supplied to `"+B+"`, expected `object`."));for(var K in y){var Z=y[K];if(typeof Z!="function")return k(B,X,q,K,te(Z));var ue=Z(H,K,B,X,q+"."+K,n);if(ue)return ue}return null}return m(T)}function $(y){function T(z,L,B,X,q){var H=z[L],G=F(H);if(G!=="object")return new f("Invalid "+X+" `"+q+"` of type `"+G+"` "+("supplied to `"+B+"`, expected `object`."));var K=t({},z[L],y);for(var Z in K){var ue=y[Z];if(r(y,Z)&&typeof ue!="function")return k(B,X,q,Z,te(ue));if(!ue)return new f("Invalid "+X+" `"+q+"` key `"+Z+"` supplied to `"+B+"`.\nBad object: "+JSON.stringify(z[L],null," ")+` -Valid keys: `+JSON.stringify(Object.keys(y),null," "));var I=ue(H,Z,B,X,q+"."+Z,n);if(I)return I}return null}return m(T)}function J(y){switch(typeof y){case"number":case"string":case"undefined":return!0;case"boolean":return!y;case"object":if(Array.isArray(y))return y.every(J);if(y===null||l(y))return!0;var T=h(y);if(T){var z=T.call(y),L;if(T!==y.entries){for(;!(L=z.next()).done;)if(!J(L.value))return!1}else for(;!(L=z.next()).done;){var B=L.value;if(B&&!J(B[1]))return!1}}else return!1;return!0;default:return!1}}function Y(y,T){return y==="symbol"?!0:T?T["@@toStringTag"]==="Symbol"||typeof Symbol=="function"&&T instanceof Symbol:!1}function F(y){var T=typeof y;return Array.isArray(y)?"array":y instanceof RegExp?"object":Y(T,y)?"symbol":T}function te(y){if(typeof y>"u"||y===null)return""+y;var T=F(y);if(T==="object"){if(y instanceof Date)return"date";if(y instanceof RegExp)return"regexp"}return T}function se(y){var T=te(y);switch(T){case"array":case"object":return"an "+T;case"boolean":case"date":case"regexp":return"a "+T;default:return T}}function oe(y){return!y.constructor||!y.constructor.name?w:y.constructor.name}return b.checkPropTypes=o,b.resetWarningCache=o.resetWarningCache,b.PropTypes=b,b},Dr}var Br,ya;function Td(){if(ya)return Br;ya=1;var e=Co();function t(){}function n(){}return n.resetWarningCache=t,Br=function(){function r(i,l,c,d,u,h){if(h!==e){var w=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types");throw w.name="Invariant Violation",w}}r.isRequired=r;function o(){return r}var s={array:r,bigint:r,bool:r,func:r,number:r,object:r,string:r,symbol:r,any:r,arrayOf:o,element:r,elementType:r,instanceOf:o,node:r,objectOf:o,oneOf:o,oneOfType:o,shape:o,exact:o,checkPropTypes:n,resetWarningCache:t};return s.PropTypes=s,s},Br}if(process.env.NODE_ENV!=="production"){var Rd=ni(),Od=!0;Kr.exports=Cd()(Rd.isElement,Od)}else Kr.exports=Td()();var _d=Kr.exports;const p=xd(_d);function Pd(e){const{prototype:t={}}=e;return!!t.isReactComponent}function oi(e,t,n,r,o){const s=e[t],i=o||t;if(s==null||typeof window>"u")return null;let l;const c=s.type;return typeof c=="function"&&!Pd(c)&&(l="Did you accidentally use a plain function component for an element instead?"),l!==void 0?new Error(`Invalid ${r} \`${i}\` supplied to \`${n}\`. Expected an element that can hold a ref. ${l} For more information see https://mui.com/r/caveat-with-refs-guide`):null}const ai=jo(p.element,oi);ai.isRequired=jo(p.element.isRequired,oi);const si=ai,Id="exact-prop: ​";function Md(e){return process.env.NODE_ENV==="production"?e:O({},e,{[Id]:t=>{const n=Object.keys(t).filter(r=>!e.hasOwnProperty(r));return n.length>0?new Error(`The following props are not supported: ${n.map(r=>`\`${r}\``).join(", ")}. Please remove them.`):null}})}function zt(e){let t="https://mui.com/production-error/?code="+e;for(let n=1;n1?s("Invalid arguments supplied to oneOf, expected an array, got "+arguments.length+" arguments. A common mistake is to write oneOf(x, y, z) instead of oneOf([x, y, z])."):s("Invalid argument supplied to oneOf, expected an array.")),i;function T(z,L,B,X,q){for(var H=z[L],G=0;G0?", expected one of type ["+K.join(", ")+"]":"";return new f("Invalid "+H+" `"+G+"` supplied to "+("`"+q+"`"+ye+"."))}return m(L)}function _(){function y(T,z,L,B,X){return J(T[z])?null:new f("Invalid "+B+" `"+X+"` supplied to "+("`"+L+"`, expected a ReactNode."))}return m(y)}function k(y,T,z,L,B){return new f((y||"React class")+": "+T+" type `"+z+"."+L+"` is invalid; it must be a function, usually from the `prop-types` package, but received `"+B+"`.")}function D(y){function T(z,L,B,X,q){var H=z[L],G=F(H);if(G!=="object")return new f("Invalid "+X+" `"+q+"` of type `"+G+"` "+("supplied to `"+B+"`, expected `object`."));for(var K in y){var Z=y[K];if(typeof Z!="function")return k(B,X,q,K,te(Z));var ue=Z(H,K,B,X,q+"."+K,n);if(ue)return ue}return null}return m(T)}function $(y){function T(z,L,B,X,q){var H=z[L],G=F(H);if(G!=="object")return new f("Invalid "+X+" `"+q+"` of type `"+G+"` "+("supplied to `"+B+"`, expected `object`."));var K=t({},z[L],y);for(var Z in K){var ue=y[Z];if(r(y,Z)&&typeof ue!="function")return k(B,X,q,Z,te(ue));if(!ue)return new f("Invalid "+X+" `"+q+"` key `"+Z+"` supplied to `"+B+"`.\nBad object: "+JSON.stringify(z[L],null," ")+` +Valid keys: `+JSON.stringify(Object.keys(y),null," "));var I=ue(H,Z,B,X,q+"."+Z,n);if(I)return I}return null}return m(T)}function J(y){switch(typeof y){case"number":case"string":case"undefined":return!0;case"boolean":return!y;case"object":if(Array.isArray(y))return y.every(J);if(y===null||l(y))return!0;var T=h(y);if(T){var z=T.call(y),L;if(T!==y.entries){for(;!(L=z.next()).done;)if(!J(L.value))return!1}else for(;!(L=z.next()).done;){var B=L.value;if(B&&!J(B[1]))return!1}}else return!1;return!0;default:return!1}}function Y(y,T){return y==="symbol"?!0:T?T["@@toStringTag"]==="Symbol"||typeof Symbol=="function"&&T instanceof Symbol:!1}function F(y){var T=typeof y;return Array.isArray(y)?"array":y instanceof RegExp?"object":Y(T,y)?"symbol":T}function te(y){if(typeof y>"u"||y===null)return""+y;var T=F(y);if(T==="object"){if(y instanceof Date)return"date";if(y instanceof RegExp)return"regexp"}return T}function se(y){var T=te(y);switch(T){case"array":case"object":return"an "+T;case"boolean":case"date":case"regexp":return"a "+T;default:return T}}function oe(y){return!y.constructor||!y.constructor.name?w:y.constructor.name}return b.checkPropTypes=o,b.resetWarningCache=o.resetWarningCache,b.PropTypes=b,b},Ar}var Br,ha;function Cd(){if(ha)return Br;ha=1;var e=No();function t(){}function n(){}return n.resetWarningCache=t,Br=function(){function r(i,l,c,d,u,h){if(h!==e){var w=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types");throw w.name="Invariant Violation",w}}r.isRequired=r;function o(){return r}var s={array:r,bigint:r,bool:r,func:r,number:r,object:r,string:r,symbol:r,any:r,arrayOf:o,element:r,elementType:r,instanceOf:o,node:r,objectOf:o,oneOf:o,oneOfType:o,shape:o,exact:o,checkPropTypes:n,resetWarningCache:t};return s.PropTypes=s,s},Br}if(process.env.NODE_ENV!=="production"){var Td=Ks(),Rd=!0;Kr.exports=jd()(Td.isElement,Rd)}else Kr.exports=Cd()();var Od=Kr.exports;const p=vd(Od);function _d(e){const{prototype:t={}}=e;return!!t.isReactComponent}function Zs(e,t,n,r,o){const s=e[t],i=o||t;if(s==null||typeof window>"u")return null;let l;const c=s.type;return typeof c=="function"&&!_d(c)&&(l="Did you accidentally use a plain function component for an element instead?"),l!==void 0?new Error(`Invalid ${r} \`${i}\` supplied to \`${n}\`. Expected an element that can hold a ref. ${l} For more information see https://mui.com/r/caveat-with-refs-guide`):null}const Qs=yo(p.element,Zs);Qs.isRequired=yo(p.element.isRequired,Zs);const ei=Qs,Pd="exact-prop: ​";function Id(e){return process.env.NODE_ENV==="production"?e:O({},e,{[Pd]:t=>{const n=Object.keys(t).filter(r=>!e.hasOwnProperty(r));return n.length>0?new Error(`The following props are not supported: ${n.map(r=>`\`${r}\``).join(", ")}. Please remove them.`):null}})}function zt(e){let t="https://mui.com/production-error/?code="+e;for(let n=1;nn==null?t:function(...o){t.apply(this,o),n.apply(this,o)},()=>{})}function Fd(e,t=166){let n;function r(...o){const s=()=>{e.apply(this,o)};clearTimeout(n),n=setTimeout(s,t)}return r.clear=()=>{clearTimeout(n)},r}function Gd(e,t){return process.env.NODE_ENV==="production"?()=>null:(n,r,o,s,i)=>{const l=o||"<>",c=i||r;return typeof n[r]<"u"?new Error(`The ${s} \`${c}\` of \`${l}\` is deprecated. ${t}`):null}}function Ud(e,t){var n,r;return M.isValidElement(e)&&t.indexOf((n=e.type.muiName)!=null?n:(r=e.type)==null||(r=r._payload)==null||(r=r.value)==null?void 0:r.muiName)!==-1}function Kn(e){return e&&e.ownerDocument||document}function qd(e){return Kn(e).defaultView||window}function Hd(e,t){if(process.env.NODE_ENV==="production")return()=>null;const n=t?O({},t.propTypes):null;return o=>(s,i,l,c,d,...u)=>{const h=d||i,w=n==null?void 0:n[h];if(w){const b=w(s,i,l,c,d,...u);if(b)return b}return typeof s[i]<"u"&&!s[o]?new Error(`The prop \`${h}\` of \`${e}\` can only be used together with the \`${o}\` prop.`):null}}function Jn(e,t){typeof e=="function"?e(t):e&&(e.current=t)}const Xd=typeof window<"u"?M.useLayoutEffect:M.useEffect,Lt=Xd;let ja=0;function Yd(e){const[t,n]=M.useState(e),r=e||t;return M.useEffect(()=>{t==null&&(ja+=1,n(`mui-${ja}`))},[t]),r}const Ca=M["useId".toString()];function ci(e){if(Ca!==void 0){const t=Ca();return e??t}return Yd(e)}function Wd(e,t,n,r,o){if(process.env.NODE_ENV==="production")return null;const s=o||t;return typeof e[t]<"u"?new Error(`The prop \`${s}\` is not supported. Please remove it.`):null}function di({controlled:e,default:t,name:n,state:r="value"}){const{current:o}=M.useRef(e!==void 0),[s,i]=M.useState(t),l=o?e:s;if(process.env.NODE_ENV!=="production"){M.useEffect(()=>{o!==(e!==void 0)&&console.error([`MUI: A component is changing the ${o?"":"un"}controlled ${r} state of ${n} to be ${o?"un":""}controlled.`,"Elements should not switch from uncontrolled to controlled (or vice versa).",`Decide between using a controlled or uncontrolled ${n} element for the lifetime of the component.`,"The nature of the state is determined during the first render. It's considered controlled if the value is not `undefined`.","More info: https://fb.me/react-controlled-components"].join(` + */var ba;function $d(){return ba||(ba=1,process.env.NODE_ENV!=="production"&&function(){var e=Symbol.for("react.element"),t=Symbol.for("react.portal"),n=Symbol.for("react.fragment"),r=Symbol.for("react.strict_mode"),o=Symbol.for("react.profiler"),s=Symbol.for("react.provider"),i=Symbol.for("react.context"),l=Symbol.for("react.server_context"),c=Symbol.for("react.forward_ref"),d=Symbol.for("react.suspense"),u=Symbol.for("react.suspense_list"),h=Symbol.for("react.memo"),w=Symbol.for("react.lazy"),b=Symbol.for("react.offscreen"),x=!1,f=!1,m=!1,S=!1,R=!1,j;j=Symbol.for("react.module.reference");function E(A){return!!(typeof A=="string"||typeof A=="function"||A===n||A===o||R||A===r||A===d||A===u||S||A===b||x||f||m||typeof A=="object"&&A!==null&&(A.$$typeof===w||A.$$typeof===h||A.$$typeof===s||A.$$typeof===i||A.$$typeof===c||A.$$typeof===j||A.getModuleId!==void 0))}function v(A){if(typeof A=="object"&&A!==null){var xe=A.$$typeof;switch(xe){case e:var Ge=A.type;switch(Ge){case n:case o:case r:case d:case u:return Ge;default:var lt=Ge&&Ge.$$typeof;switch(lt){case l:case i:case c:case w:case h:case s:return lt;default:return xe}}case t:return xe}}}var P=i,V=s,U=e,C=c,_=n,k=w,D=h,$=t,J=o,Y=r,F=d,te=u,se=!1,oe=!1;function y(A){return se||(se=!0,console.warn("The ReactIs.isAsyncMode() alias has been deprecated, and will be removed in React 18+.")),!1}function T(A){return oe||(oe=!0,console.warn("The ReactIs.isConcurrentMode() alias has been deprecated, and will be removed in React 18+.")),!1}function z(A){return v(A)===i}function L(A){return v(A)===s}function B(A){return typeof A=="object"&&A!==null&&A.$$typeof===e}function X(A){return v(A)===c}function q(A){return v(A)===n}function H(A){return v(A)===w}function G(A){return v(A)===h}function K(A){return v(A)===t}function Z(A){return v(A)===o}function ue(A){return v(A)===r}function I(A){return v(A)===d}function ye(A){return v(A)===u}de.ContextConsumer=P,de.ContextProvider=V,de.Element=U,de.ForwardRef=C,de.Fragment=_,de.Lazy=k,de.Memo=D,de.Portal=$,de.Profiler=J,de.StrictMode=Y,de.Suspense=F,de.SuspenseList=te,de.isAsyncMode=y,de.isConcurrentMode=T,de.isContextConsumer=z,de.isContextProvider=L,de.isElement=B,de.isForwardRef=X,de.isFragment=q,de.isLazy=H,de.isMemo=G,de.isPortal=K,de.isProfiler=Z,de.isStrictMode=ue,de.isSuspense=I,de.isSuspenseList=ye,de.isValidElementType=E,de.typeOf=v}()),de}process.env.NODE_ENV==="production"?Jr.exports=Md():Jr.exports=$d();var va=Jr.exports;const Dd=/^\s*function(?:\s|\s*\/\*.*\*\/\s*)+([^(\s/]*)\s*/;function Ad(e){const t=`${e}`.match(Dd);return t&&t[1]||""}function ti(e,t=""){return e.displayName||e.name||Ad(e)||t}function xa(e,t,n){const r=ti(t);return e.displayName||(r!==""?`${n}(${r})`:n)}function Bd(e){if(e!=null){if(typeof e=="string")return e;if(typeof e=="function")return ti(e,"Component");if(typeof e=="object")switch(e.$$typeof){case va.ForwardRef:return xa(e,e.render,"ForwardRef");case va.Memo:return xa(e,e.type,"memo");default:return}}}function xn(e,t,n,r,o){if(process.env.NODE_ENV==="production")return null;const s=e[t],i=o||t;return s==null?null:s&&s.nodeType!==1?new Error(`Invalid ${r} \`${i}\` supplied to \`${n}\`. Expected an HTMLElement.`):null}const Vd=p.oneOfType([p.func,p.object]),ni=Vd;function Ye(e){if(typeof e!="string")throw new Error(process.env.NODE_ENV!=="production"?"MUI: `capitalize(string)` expects a string argument.":zt(7));return e.charAt(0).toUpperCase()+e.slice(1)}function zd(...e){return e.reduce((t,n)=>n==null?t:function(...o){t.apply(this,o),n.apply(this,o)},()=>{})}function Ld(e,t=166){let n;function r(...o){const s=()=>{e.apply(this,o)};clearTimeout(n),n=setTimeout(s,t)}return r.clear=()=>{clearTimeout(n)},r}function Fd(e,t){return process.env.NODE_ENV==="production"?()=>null:(n,r,o,s,i)=>{const l=o||"<>",c=i||r;return typeof n[r]<"u"?new Error(`The ${s} \`${c}\` of \`${l}\` is deprecated. ${t}`):null}}function Gd(e,t){var n,r;return M.isValidElement(e)&&t.indexOf((n=e.type.muiName)!=null?n:(r=e.type)==null||(r=r._payload)==null||(r=r.value)==null?void 0:r.muiName)!==-1}function Kn(e){return e&&e.ownerDocument||document}function Ud(e){return Kn(e).defaultView||window}function qd(e,t){if(process.env.NODE_ENV==="production")return()=>null;const n=t?O({},t.propTypes):null;return o=>(s,i,l,c,d,...u)=>{const h=d||i,w=n==null?void 0:n[h];if(w){const b=w(s,i,l,c,d,...u);if(b)return b}return typeof s[i]<"u"&&!s[o]?new Error(`The prop \`${h}\` of \`${e}\` can only be used together with the \`${o}\` prop.`):null}}function Jn(e,t){typeof e=="function"?e(t):e&&(e.current=t)}const Hd=typeof window<"u"?M.useLayoutEffect:M.useEffect,Lt=Hd;let ya=0;function Xd(e){const[t,n]=M.useState(e),r=e||t;return M.useEffect(()=>{t==null&&(ya+=1,n(`mui-${ya}`))},[t]),r}const Na=M["useId".toString()];function ri(e){if(Na!==void 0){const t=Na();return e??t}return Xd(e)}function Yd(e,t,n,r,o){if(process.env.NODE_ENV==="production")return null;const s=o||t;return typeof e[t]<"u"?new Error(`The prop \`${s}\` is not supported. Please remove it.`):null}function oi({controlled:e,default:t,name:n,state:r="value"}){const{current:o}=M.useRef(e!==void 0),[s,i]=M.useState(t),l=o?e:s;if(process.env.NODE_ENV!=="production"){M.useEffect(()=>{o!==(e!==void 0)&&console.error([`MUI: A component is changing the ${o?"":"un"}controlled ${r} state of ${n} to be ${o?"un":""}controlled.`,"Elements should not switch from uncontrolled to controlled (or vice versa).",`Decide between using a controlled or uncontrolled ${n} element for the lifetime of the component.`,"The nature of the state is determined during the first render. It's considered controlled if the value is not `undefined`.","More info: https://fb.me/react-controlled-components"].join(` `))},[r,n,e]);const{current:d}=M.useRef(t);M.useEffect(()=>{!o&&d!==t&&console.error([`MUI: A component is changing the default ${r} state of an uncontrolled ${n} after being initialized. To suppress this warning opt to use a controlled ${n}.`].join(` -`))},[JSON.stringify(t)])}const c=M.useCallback(d=>{o||i(d)},[]);return[l,c]}function Zr(e){const t=M.useRef(e);return Lt(()=>{t.current=e}),M.useRef((...n)=>(0,t.current)(...n)).current}function yt(...e){return M.useMemo(()=>e.every(t=>t==null)?null:t=>{e.forEach(n=>{Jn(n,t)})},e)}const Ta={};function Kd(e,t){const n=M.useRef(Ta);return n.current===Ta&&(n.current=e(t)),n}const Jd=[];function Zd(e){M.useEffect(e,Jd)}class On{constructor(){this.currentId=null,this.clear=()=>{this.currentId!==null&&(clearTimeout(this.currentId),this.currentId=null)},this.disposeEffect=()=>this.clear}static create(){return new On}start(t,n){this.clear(),this.currentId=setTimeout(()=>{this.currentId=null,n()},t)}}function dn(){const e=Kd(On.create).current;return Zd(e.disposeEffect),e}let dr=!0,Qr=!1;const Qd=new On,eu={text:!0,search:!0,url:!0,tel:!0,email:!0,password:!0,number:!0,date:!0,month:!0,week:!0,time:!0,datetime:!0,"datetime-local":!0};function tu(e){const{type:t,tagName:n}=e;return!!(n==="INPUT"&&eu[t]&&!e.readOnly||n==="TEXTAREA"&&!e.readOnly||e.isContentEditable)}function nu(e){e.metaKey||e.altKey||e.ctrlKey||(dr=!0)}function Vr(){dr=!1}function ru(){this.visibilityState==="hidden"&&Qr&&(dr=!0)}function ou(e){e.addEventListener("keydown",nu,!0),e.addEventListener("mousedown",Vr,!0),e.addEventListener("pointerdown",Vr,!0),e.addEventListener("touchstart",Vr,!0),e.addEventListener("visibilitychange",ru,!0)}function au(e){const{target:t}=e;try{return t.matches(":focus-visible")}catch{}return dr||tu(t)}function ui(){const e=M.useCallback(o=>{o!=null&&ou(o.ownerDocument)},[]),t=M.useRef(!1);function n(){return t.current?(Qr=!0,Qd.start(100,()=>{Qr=!1}),t.current=!1,!0):!1}function r(o){return au(o)?(t.current=!0,!0):!1}return{isFocusVisibleRef:t,onFocus:r,onBlur:n,ref:e}}function pi(e,t){const n=O({},t);return Object.keys(e).forEach(r=>{if(r.toString().match(/^(components|slots)$/))n[r]=O({},e[r],n[r]);else if(r.toString().match(/^(componentsProps|slotProps)$/)){const o=e[r]||{},s=t[r];n[r]={},!s||!Object.keys(s)?n[r]=o:!o||!Object.keys(o)?n[r]=s:(n[r]=O({},s),Object.keys(o).forEach(i=>{n[r][i]=pi(o[i],s[i])}))}else n[r]===void 0&&(n[r]=e[r])}),n}function To(e,t,n=void 0){const r={};return Object.keys(e).forEach(o=>{r[o]=e[o].reduce((s,i)=>{if(i){const l=t(i);l!==""&&s.push(l),n&&n[i]&&s.push(n[i])}return s},[]).join(" ")}),r}const Ra=e=>e,su=()=>{let e=Ra;return{configure(t){e=t},generate(t){return e(t)},reset(){e=Ra}}},iu=su(),wi=iu,fi={active:"active",checked:"checked",completed:"completed",disabled:"disabled",error:"error",expanded:"expanded",focused:"focused",focusVisible:"focusVisible",open:"open",readOnly:"readOnly",required:"required",selected:"selected"};function ur(e,t,n="Mui"){const r=fi[t];return r?`${n}-${r}`:`${wi.generate(e)}-${t}`}function mi(e,t,n="Mui"){const r={};return t.forEach(o=>{r[o]=ur(e,o,n)}),r}function lu(e,t=Number.MIN_SAFE_INTEGER,n=Number.MAX_SAFE_INTEGER){return Math.max(t,Math.min(e,n))}function Ne(e,t){if(e==null)return{};var n={},r=Object.keys(e),o,s;for(s=0;s=0)&&(n[o]=e[o]);return n}const cu=["values","unit","step"],du=e=>{const t=Object.keys(e).map(n=>({key:n,val:e[n]}))||[];return t.sort((n,r)=>n.val-r.val),t.reduce((n,r)=>O({},n,{[r.key]:r.val}),{})};function uu(e){const{values:t={xs:0,sm:600,md:900,lg:1200,xl:1536},unit:n="px",step:r=5}=e,o=Ne(e,cu),s=du(t),i=Object.keys(s);function l(w){return`@media (min-width:${typeof t[w]=="number"?t[w]:w}${n})`}function c(w){return`@media (max-width:${(typeof t[w]=="number"?t[w]:w)-r/100}${n})`}function d(w,b){const x=i.indexOf(b);return`@media (min-width:${typeof t[w]=="number"?t[w]:w}${n}) and (max-width:${(x!==-1&&typeof t[i[x]]=="number"?t[i[x]]:b)-r/100}${n})`}function u(w){return i.indexOf(w)+1`@media (min-width:${Ro[e]}px)`};function et(e,t,n){const r=e.theme||{};if(Array.isArray(t)){const s=r.breakpoints||Oa;return t.reduce((i,l,c)=>(i[s.up(s.keys[c])]=n(t[c]),i),{})}if(typeof t=="object"){const s=r.breakpoints||Oa;return Object.keys(t).reduce((i,l)=>{if(Object.keys(s.values||Ro).indexOf(l)!==-1){const c=s.up(l);i[c]=n(t[l],l)}else{const c=l;i[c]=t[c]}return i},{})}return n(t)}function mu(e={}){var t;return((t=e.keys)==null?void 0:t.reduce((r,o)=>{const s=e.up(o);return r[s]={},r},{}))||{}}function hu(e,t){return e.reduce((n,r)=>{const o=n[r];return(!o||Object.keys(o).length===0)&&delete n[r],n},t)}function pr(e,t,n=!0){if(!t||typeof t!="string")return null;if(e&&e.vars&&n){const r=`vars.${t}`.split(".").reduce((o,s)=>o&&o[s]?o[s]:null,e);if(r!=null)return r}return t.split(".").reduce((r,o)=>r&&r[o]!=null?r[o]:null,e)}function Zn(e,t,n,r=n){let o;return typeof e=="function"?o=e(n):Array.isArray(e)?o=e[n]||r:o=pr(e,n)||r,t&&(o=t(o,r,e)),o}function ve(e){const{prop:t,cssProperty:n=e.prop,themeKey:r,transform:o}=e,s=i=>{if(i[t]==null)return null;const l=i[t],c=i.theme,d=pr(c,r)||{};return et(i,l,h=>{let w=Zn(d,o,h);return h===w&&typeof h=="string"&&(w=Zn(d,o,`${t}${h==="default"?"":Ye(h)}`,h)),n===!1?w:{[n]:w}})};return s.propTypes=process.env.NODE_ENV!=="production"?{[t]:st}:{},s.filterProps=[t],s}function gu(e){const t={};return n=>(t[n]===void 0&&(t[n]=e(n)),t[n])}const bu={m:"margin",p:"padding"},vu={t:"Top",r:"Right",b:"Bottom",l:"Left",x:["Left","Right"],y:["Top","Bottom"]},_a={marginX:"mx",marginY:"my",paddingX:"px",paddingY:"py"},xu=gu(e=>{if(e.length>2)if(_a[e])e=_a[e];else return[e];const[t,n]=e.split(""),r=bu[t],o=vu[n]||"";return Array.isArray(o)?o.map(s=>r+s):[r+o]}),wr=["m","mt","mr","mb","ml","mx","my","margin","marginTop","marginRight","marginBottom","marginLeft","marginX","marginY","marginInline","marginInlineStart","marginInlineEnd","marginBlock","marginBlockStart","marginBlockEnd"],fr=["p","pt","pr","pb","pl","px","py","padding","paddingTop","paddingRight","paddingBottom","paddingLeft","paddingX","paddingY","paddingInline","paddingInlineStart","paddingInlineEnd","paddingBlock","paddingBlockStart","paddingBlockEnd"],yu=[...wr,...fr];function _n(e,t,n,r){var o;const s=(o=pr(e,t,!1))!=null?o:n;return typeof s=="number"?i=>typeof i=="string"?i:(process.env.NODE_ENV!=="production"&&typeof i!="number"&&console.error(`MUI: Expected ${r} argument to be a number or a string, got ${i}.`),s*i):Array.isArray(s)?i=>typeof i=="string"?i:(process.env.NODE_ENV!=="production"&&(Number.isInteger(i)?i>s.length-1&&console.error([`MUI: The value provided (${i}) overflows.`,`The supported values are: ${JSON.stringify(s)}.`,`${i} > ${s.length-1}, you need to add the missing values.`].join(` +`))},[JSON.stringify(t)])}const c=M.useCallback(d=>{o||i(d)},[]);return[l,c]}function Zr(e){const t=M.useRef(e);return Lt(()=>{t.current=e}),M.useRef((...n)=>(0,t.current)(...n)).current}function yt(...e){return M.useMemo(()=>e.every(t=>t==null)?null:t=>{e.forEach(n=>{Jn(n,t)})},e)}const ka={};function Wd(e,t){const n=M.useRef(ka);return n.current===ka&&(n.current=e(t)),n}const Kd=[];function Jd(e){M.useEffect(e,Kd)}class On{constructor(){this.currentId=null,this.clear=()=>{this.currentId!==null&&(clearTimeout(this.currentId),this.currentId=null)},this.disposeEffect=()=>this.clear}static create(){return new On}start(t,n){this.clear(),this.currentId=setTimeout(()=>{this.currentId=null,n()},t)}}function dn(){const e=Wd(On.create).current;return Jd(e.disposeEffect),e}let dr=!0,Qr=!1;const Zd=new On,Qd={text:!0,search:!0,url:!0,tel:!0,email:!0,password:!0,number:!0,date:!0,month:!0,week:!0,time:!0,datetime:!0,"datetime-local":!0};function eu(e){const{type:t,tagName:n}=e;return!!(n==="INPUT"&&Qd[t]&&!e.readOnly||n==="TEXTAREA"&&!e.readOnly||e.isContentEditable)}function tu(e){e.metaKey||e.altKey||e.ctrlKey||(dr=!0)}function Vr(){dr=!1}function nu(){this.visibilityState==="hidden"&&Qr&&(dr=!0)}function ru(e){e.addEventListener("keydown",tu,!0),e.addEventListener("mousedown",Vr,!0),e.addEventListener("pointerdown",Vr,!0),e.addEventListener("touchstart",Vr,!0),e.addEventListener("visibilitychange",nu,!0)}function ou(e){const{target:t}=e;try{return t.matches(":focus-visible")}catch{}return dr||eu(t)}function ai(){const e=M.useCallback(o=>{o!=null&&ru(o.ownerDocument)},[]),t=M.useRef(!1);function n(){return t.current?(Qr=!0,Zd.start(100,()=>{Qr=!1}),t.current=!1,!0):!1}function r(o){return ou(o)?(t.current=!0,!0):!1}return{isFocusVisibleRef:t,onFocus:r,onBlur:n,ref:e}}function si(e,t){const n=O({},t);return Object.keys(e).forEach(r=>{if(r.toString().match(/^(components|slots)$/))n[r]=O({},e[r],n[r]);else if(r.toString().match(/^(componentsProps|slotProps)$/)){const o=e[r]||{},s=t[r];n[r]={},!s||!Object.keys(s)?n[r]=o:!o||!Object.keys(o)?n[r]=s:(n[r]=O({},s),Object.keys(o).forEach(i=>{n[r][i]=si(o[i],s[i])}))}else n[r]===void 0&&(n[r]=e[r])}),n}function ko(e,t,n=void 0){const r={};return Object.keys(e).forEach(o=>{r[o]=e[o].reduce((s,i)=>{if(i){const l=t(i);l!==""&&s.push(l),n&&n[i]&&s.push(n[i])}return s},[]).join(" ")}),r}const Sa=e=>e,au=()=>{let e=Sa;return{configure(t){e=t},generate(t){return e(t)},reset(){e=Sa}}},su=au(),ii=su,li={active:"active",checked:"checked",completed:"completed",disabled:"disabled",error:"error",expanded:"expanded",focused:"focused",focusVisible:"focusVisible",open:"open",readOnly:"readOnly",required:"required",selected:"selected"};function ur(e,t,n="Mui"){const r=li[t];return r?`${n}-${r}`:`${ii.generate(e)}-${t}`}function ci(e,t,n="Mui"){const r={};return t.forEach(o=>{r[o]=ur(e,o,n)}),r}function iu(e,t=Number.MIN_SAFE_INTEGER,n=Number.MAX_SAFE_INTEGER){return Math.max(t,Math.min(e,n))}function Ne(e,t){if(e==null)return{};var n={},r=Object.keys(e),o,s;for(s=0;s=0)&&(n[o]=e[o]);return n}const lu=["values","unit","step"],cu=e=>{const t=Object.keys(e).map(n=>({key:n,val:e[n]}))||[];return t.sort((n,r)=>n.val-r.val),t.reduce((n,r)=>O({},n,{[r.key]:r.val}),{})};function du(e){const{values:t={xs:0,sm:600,md:900,lg:1200,xl:1536},unit:n="px",step:r=5}=e,o=Ne(e,lu),s=cu(t),i=Object.keys(s);function l(w){return`@media (min-width:${typeof t[w]=="number"?t[w]:w}${n})`}function c(w){return`@media (max-width:${(typeof t[w]=="number"?t[w]:w)-r/100}${n})`}function d(w,b){const x=i.indexOf(b);return`@media (min-width:${typeof t[w]=="number"?t[w]:w}${n}) and (max-width:${(x!==-1&&typeof t[i[x]]=="number"?t[i[x]]:b)-r/100}${n})`}function u(w){return i.indexOf(w)+1`@media (min-width:${So[e]}px)`};function et(e,t,n){const r=e.theme||{};if(Array.isArray(t)){const s=r.breakpoints||Ea;return t.reduce((i,l,c)=>(i[s.up(s.keys[c])]=n(t[c]),i),{})}if(typeof t=="object"){const s=r.breakpoints||Ea;return Object.keys(t).reduce((i,l)=>{if(Object.keys(s.values||So).indexOf(l)!==-1){const c=s.up(l);i[c]=n(t[l],l)}else{const c=l;i[c]=t[c]}return i},{})}return n(t)}function fu(e={}){var t;return((t=e.keys)==null?void 0:t.reduce((r,o)=>{const s=e.up(o);return r[s]={},r},{}))||{}}function mu(e,t){return e.reduce((n,r)=>{const o=n[r];return(!o||Object.keys(o).length===0)&&delete n[r],n},t)}function pr(e,t,n=!0){if(!t||typeof t!="string")return null;if(e&&e.vars&&n){const r=`vars.${t}`.split(".").reduce((o,s)=>o&&o[s]?o[s]:null,e);if(r!=null)return r}return t.split(".").reduce((r,o)=>r&&r[o]!=null?r[o]:null,e)}function Zn(e,t,n,r=n){let o;return typeof e=="function"?o=e(n):Array.isArray(e)?o=e[n]||r:o=pr(e,n)||r,t&&(o=t(o,r,e)),o}function ve(e){const{prop:t,cssProperty:n=e.prop,themeKey:r,transform:o}=e,s=i=>{if(i[t]==null)return null;const l=i[t],c=i.theme,d=pr(c,r)||{};return et(i,l,h=>{let w=Zn(d,o,h);return h===w&&typeof h=="string"&&(w=Zn(d,o,`${t}${h==="default"?"":Ye(h)}`,h)),n===!1?w:{[n]:w}})};return s.propTypes=process.env.NODE_ENV!=="production"?{[t]:st}:{},s.filterProps=[t],s}function hu(e){const t={};return n=>(t[n]===void 0&&(t[n]=e(n)),t[n])}const gu={m:"margin",p:"padding"},bu={t:"Top",r:"Right",b:"Bottom",l:"Left",x:["Left","Right"],y:["Top","Bottom"]},ja={marginX:"mx",marginY:"my",paddingX:"px",paddingY:"py"},vu=hu(e=>{if(e.length>2)if(ja[e])e=ja[e];else return[e];const[t,n]=e.split(""),r=gu[t],o=bu[n]||"";return Array.isArray(o)?o.map(s=>r+s):[r+o]}),wr=["m","mt","mr","mb","ml","mx","my","margin","marginTop","marginRight","marginBottom","marginLeft","marginX","marginY","marginInline","marginInlineStart","marginInlineEnd","marginBlock","marginBlockStart","marginBlockEnd"],fr=["p","pt","pr","pb","pl","px","py","padding","paddingTop","paddingRight","paddingBottom","paddingLeft","paddingX","paddingY","paddingInline","paddingInlineStart","paddingInlineEnd","paddingBlock","paddingBlockStart","paddingBlockEnd"],xu=[...wr,...fr];function _n(e,t,n,r){var o;const s=(o=pr(e,t,!1))!=null?o:n;return typeof s=="number"?i=>typeof i=="string"?i:(process.env.NODE_ENV!=="production"&&typeof i!="number"&&console.error(`MUI: Expected ${r} argument to be a number or a string, got ${i}.`),s*i):Array.isArray(s)?i=>typeof i=="string"?i:(process.env.NODE_ENV!=="production"&&(Number.isInteger(i)?i>s.length-1&&console.error([`MUI: The value provided (${i}) overflows.`,`The supported values are: ${JSON.stringify(s)}.`,`${i} > ${s.length-1}, you need to add the missing values.`].join(` `)):console.error([`MUI: The \`theme.${t}\` array type cannot be combined with non integer values.You should either use an integer value that can be used as index, or define the \`theme.${t}\` as a number.`].join(` `))),s[i]):typeof s=="function"?s:(process.env.NODE_ENV!=="production"&&console.error([`MUI: The \`theme.${t}\` value (${s}) is invalid.`,"It should be a number, an array or a function."].join(` -`)),()=>{})}function hi(e){return _n(e,"spacing",8,"spacing")}function Pn(e,t){if(typeof t=="string"||t==null)return t;const n=Math.abs(t),r=e(n);return t>=0?r:typeof r=="number"?-r:`-${r}`}function Nu(e,t){return n=>e.reduce((r,o)=>(r[o]=Pn(t,n),r),{})}function ku(e,t,n,r){if(t.indexOf(n)===-1)return null;const o=xu(n),s=Nu(o,r),i=e[n];return et(e,i,s)}function gi(e,t){const n=hi(e.theme);return Object.keys(e).map(r=>ku(e,t,r,n)).reduce(mn,{})}function me(e){return gi(e,wr)}me.propTypes=process.env.NODE_ENV!=="production"?wr.reduce((e,t)=>(e[t]=st,e),{}):{};me.filterProps=wr;function he(e){return gi(e,fr)}he.propTypes=process.env.NODE_ENV!=="production"?fr.reduce((e,t)=>(e[t]=st,e),{}):{};he.filterProps=fr;process.env.NODE_ENV!=="production"&&yu.reduce((e,t)=>(e[t]=st,e),{});function Su(e=8){if(e.mui)return e;const t=hi({spacing:e}),n=(...r)=>(process.env.NODE_ENV!=="production"&&(r.length<=4||console.error(`MUI: Too many arguments provided, expected between 0 and 4, got ${r.length}`)),(r.length===0?[1]:r).map(s=>{const i=t(s);return typeof i=="number"?`${i}px`:i}).join(" "));return n.mui=!0,n}function mr(...e){const t=e.reduce((r,o)=>(o.filterProps.forEach(s=>{r[s]=o}),r),{}),n=r=>Object.keys(r).reduce((o,s)=>t[s]?mn(o,t[s](r)):o,{});return n.propTypes=process.env.NODE_ENV!=="production"?e.reduce((r,o)=>Object.assign(r,o.propTypes),{}):{},n.filterProps=e.reduce((r,o)=>r.concat(o.filterProps),[]),n}function Be(e){return typeof e!="number"?e:`${e}px solid`}function Fe(e,t){return ve({prop:e,themeKey:"borders",transform:t})}const Eu=Fe("border",Be),ju=Fe("borderTop",Be),Cu=Fe("borderRight",Be),Tu=Fe("borderBottom",Be),Ru=Fe("borderLeft",Be),Ou=Fe("borderColor"),_u=Fe("borderTopColor"),Pu=Fe("borderRightColor"),Iu=Fe("borderBottomColor"),Mu=Fe("borderLeftColor"),$u=Fe("outline",Be),Au=Fe("outlineColor"),hr=e=>{if(e.borderRadius!==void 0&&e.borderRadius!==null){const t=_n(e.theme,"shape.borderRadius",4,"borderRadius"),n=r=>({borderRadius:Pn(t,r)});return et(e,e.borderRadius,n)}return null};hr.propTypes=process.env.NODE_ENV!=="production"?{borderRadius:st}:{};hr.filterProps=["borderRadius"];mr(Eu,ju,Cu,Tu,Ru,Ou,_u,Pu,Iu,Mu,hr,$u,Au);const gr=e=>{if(e.gap!==void 0&&e.gap!==null){const t=_n(e.theme,"spacing",8,"gap"),n=r=>({gap:Pn(t,r)});return et(e,e.gap,n)}return null};gr.propTypes=process.env.NODE_ENV!=="production"?{gap:st}:{};gr.filterProps=["gap"];const br=e=>{if(e.columnGap!==void 0&&e.columnGap!==null){const t=_n(e.theme,"spacing",8,"columnGap"),n=r=>({columnGap:Pn(t,r)});return et(e,e.columnGap,n)}return null};br.propTypes=process.env.NODE_ENV!=="production"?{columnGap:st}:{};br.filterProps=["columnGap"];const vr=e=>{if(e.rowGap!==void 0&&e.rowGap!==null){const t=_n(e.theme,"spacing",8,"rowGap"),n=r=>({rowGap:Pn(t,r)});return et(e,e.rowGap,n)}return null};vr.propTypes=process.env.NODE_ENV!=="production"?{rowGap:st}:{};vr.filterProps=["rowGap"];const Du=ve({prop:"gridColumn"}),Bu=ve({prop:"gridRow"}),Vu=ve({prop:"gridAutoFlow"}),zu=ve({prop:"gridAutoColumns"}),Lu=ve({prop:"gridAutoRows"}),Fu=ve({prop:"gridTemplateColumns"}),Gu=ve({prop:"gridTemplateRows"}),Uu=ve({prop:"gridTemplateAreas"}),qu=ve({prop:"gridArea"});mr(gr,br,vr,Du,Bu,Vu,zu,Lu,Fu,Gu,Uu,qu);function At(e,t){return t==="grey"?t:e}const Hu=ve({prop:"color",themeKey:"palette",transform:At}),Xu=ve({prop:"bgcolor",cssProperty:"backgroundColor",themeKey:"palette",transform:At}),Yu=ve({prop:"backgroundColor",themeKey:"palette",transform:At});mr(Hu,Xu,Yu);function Ie(e){return e<=1&&e!==0?`${e*100}%`:e}const Wu=ve({prop:"width",transform:Ie}),Oo=e=>{if(e.maxWidth!==void 0&&e.maxWidth!==null){const t=n=>{var r,o;const s=((r=e.theme)==null||(r=r.breakpoints)==null||(r=r.values)==null?void 0:r[n])||Ro[n];return s?((o=e.theme)==null||(o=o.breakpoints)==null?void 0:o.unit)!=="px"?{maxWidth:`${s}${e.theme.breakpoints.unit}`}:{maxWidth:s}:{maxWidth:Ie(n)}};return et(e,e.maxWidth,t)}return null};Oo.filterProps=["maxWidth"];const Ku=ve({prop:"minWidth",transform:Ie}),Ju=ve({prop:"height",transform:Ie}),Zu=ve({prop:"maxHeight",transform:Ie}),Qu=ve({prop:"minHeight",transform:Ie});ve({prop:"size",cssProperty:"width",transform:Ie});ve({prop:"size",cssProperty:"height",transform:Ie});const ep=ve({prop:"boxSizing"});mr(Wu,Oo,Ku,Ju,Zu,Qu,ep);const tp={border:{themeKey:"borders",transform:Be},borderTop:{themeKey:"borders",transform:Be},borderRight:{themeKey:"borders",transform:Be},borderBottom:{themeKey:"borders",transform:Be},borderLeft:{themeKey:"borders",transform:Be},borderColor:{themeKey:"palette"},borderTopColor:{themeKey:"palette"},borderRightColor:{themeKey:"palette"},borderBottomColor:{themeKey:"palette"},borderLeftColor:{themeKey:"palette"},outline:{themeKey:"borders",transform:Be},outlineColor:{themeKey:"palette"},borderRadius:{themeKey:"shape.borderRadius",style:hr},color:{themeKey:"palette",transform:At},bgcolor:{themeKey:"palette",cssProperty:"backgroundColor",transform:At},backgroundColor:{themeKey:"palette",transform:At},p:{style:he},pt:{style:he},pr:{style:he},pb:{style:he},pl:{style:he},px:{style:he},py:{style:he},padding:{style:he},paddingTop:{style:he},paddingRight:{style:he},paddingBottom:{style:he},paddingLeft:{style:he},paddingX:{style:he},paddingY:{style:he},paddingInline:{style:he},paddingInlineStart:{style:he},paddingInlineEnd:{style:he},paddingBlock:{style:he},paddingBlockStart:{style:he},paddingBlockEnd:{style:he},m:{style:me},mt:{style:me},mr:{style:me},mb:{style:me},ml:{style:me},mx:{style:me},my:{style:me},margin:{style:me},marginTop:{style:me},marginRight:{style:me},marginBottom:{style:me},marginLeft:{style:me},marginX:{style:me},marginY:{style:me},marginInline:{style:me},marginInlineStart:{style:me},marginInlineEnd:{style:me},marginBlock:{style:me},marginBlockStart:{style:me},marginBlockEnd:{style:me},displayPrint:{cssProperty:!1,transform:e=>({"@media print":{display:e}})},display:{},overflow:{},textOverflow:{},visibility:{},whiteSpace:{},flexBasis:{},flexDirection:{},flexWrap:{},justifyContent:{},alignItems:{},alignContent:{},order:{},flex:{},flexGrow:{},flexShrink:{},alignSelf:{},justifyItems:{},justifySelf:{},gap:{style:gr},rowGap:{style:vr},columnGap:{style:br},gridColumn:{},gridRow:{},gridAutoFlow:{},gridAutoColumns:{},gridAutoRows:{},gridTemplateColumns:{},gridTemplateRows:{},gridTemplateAreas:{},gridArea:{},position:{},zIndex:{themeKey:"zIndex"},top:{},right:{},bottom:{},left:{},boxShadow:{themeKey:"shadows"},width:{transform:Ie},maxWidth:{style:Oo},minWidth:{transform:Ie},height:{transform:Ie},maxHeight:{transform:Ie},minHeight:{transform:Ie},boxSizing:{},fontFamily:{themeKey:"typography"},fontSize:{themeKey:"typography"},fontStyle:{themeKey:"typography"},fontWeight:{themeKey:"typography"},letterSpacing:{},textTransform:{},lineHeight:{},textAlign:{},typography:{cssProperty:!1,themeKey:"typography"}},_o=tp;function np(...e){const t=e.reduce((r,o)=>r.concat(Object.keys(o)),[]),n=new Set(t);return e.every(r=>n.size===Object.keys(r).length)}function rp(e,t){return typeof e=="function"?e(t):e}function op(){function e(n,r,o,s){const i={[n]:r,theme:o},l=s[n];if(!l)return{[n]:r};const{cssProperty:c=n,themeKey:d,transform:u,style:h}=l;if(r==null)return null;if(d==="typography"&&r==="inherit")return{[n]:r};const w=pr(o,d)||{};return h?h(i):et(i,r,x=>{let f=Zn(w,u,x);return x===f&&typeof x=="string"&&(f=Zn(w,u,`${n}${x==="default"?"":Ye(x)}`,x)),c===!1?f:{[c]:f}})}function t(n){var r;const{sx:o,theme:s={}}=n||{};if(!o)return null;const i=(r=s.unstable_sxConfig)!=null?r:_o;function l(c){let d=c;if(typeof c=="function")d=c(s);else if(typeof c!="object")return c;if(!d)return null;const u=mu(s.breakpoints),h=Object.keys(u);let w=u;return Object.keys(d).forEach(b=>{const x=rp(d[b],s);if(x!=null)if(typeof x=="object")if(i[b])w=mn(w,e(b,x,s,i));else{const f=et({theme:s},x,m=>({[b]:m}));np(f,x)?w[b]=t({sx:x,theme:s}):w=mn(w,f)}else w=mn(w,e(b,x,s,i))}),hu(h,w)}return Array.isArray(o)?o.map(l):l(o)}return t}const bi=op();bi.filterProps=["sx"];const Po=bi;function ap(e,t){const n=this;return n.vars&&typeof n.getColorSchemeSelector=="function"?{[n.getColorSchemeSelector(e).replace(/(\[[^\]]+\])/,"*:where($1)")]:t}:n.palette.mode===e?t:{}}const sp=["breakpoints","palette","spacing","shape"];function Io(e={},...t){const{breakpoints:n={},palette:r={},spacing:o,shape:s={}}=e,i=Ne(e,sp),l=uu(n),c=Su(o);let d=Qe({breakpoints:l,direction:"ltr",components:{},palette:O({mode:"light"},r),spacing:c,shape:O({},wu,s)},i);return d.applyStyles=ap,d=t.reduce((u,h)=>Qe(u,h),d),d.unstable_sxConfig=O({},_o,i==null?void 0:i.unstable_sxConfig),d.unstable_sx=function(h){return Po({sx:h,theme:this})},d}function ip(e){return Object.keys(e).length===0}function vi(e=null){const t=M.useContext(Gr.ThemeContext);return!t||ip(t)?e:t}const lp=Io();function xi(e=lp){return vi(e)}const cp=["ownerState"],dp=["variants"],up=["name","slot","skipVariantsResolver","skipSx","overridesResolver"];function pp(e){return Object.keys(e).length===0}function wp(e){return typeof e=="string"&&e.charCodeAt(0)>96}function qn(e){return e!=="ownerState"&&e!=="theme"&&e!=="sx"&&e!=="as"}const fp=Io(),Pa=e=>e&&e.charAt(0).toLowerCase()+e.slice(1);function Ln({defaultTheme:e,theme:t,themeId:n}){return pp(t)?e:t[n]||t}function mp(e){return e?(t,n)=>n[e]:null}function Hn(e,t){let{ownerState:n}=t,r=Ne(t,cp);const o=typeof e=="function"?e(O({ownerState:n},r)):e;if(Array.isArray(o))return o.flatMap(s=>Hn(s,O({ownerState:n},r)));if(o&&typeof o=="object"&&Array.isArray(o.variants)){const{variants:s=[]}=o;let l=Ne(o,dp);return s.forEach(c=>{let d=!0;typeof c.props=="function"?d=c.props(O({ownerState:n},r,n)):Object.keys(c.props).forEach(u=>{(n==null?void 0:n[u])!==c.props[u]&&r[u]!==c.props[u]&&(d=!1)}),d&&(Array.isArray(l)||(l=[l]),l.push(typeof c.style=="function"?c.style(O({ownerState:n},r,n)):c.style))}),l}return o}function hp(e={}){const{themeId:t,defaultTheme:n=fp,rootShouldForwardProp:r=qn,slotShouldForwardProp:o=qn}=e,s=i=>Po(O({},i,{theme:Ln(O({},i,{defaultTheme:n,themeId:t}))}));return s.__mui_systemSx=!0,(i,l={})=>{Gr.internal_processStyles(i,v=>v.filter(P=>!(P!=null&&P.__mui_systemSx)));const{name:c,slot:d,skipVariantsResolver:u,skipSx:h,overridesResolver:w=mp(Pa(d))}=l,b=Ne(l,up),x=u!==void 0?u:d&&d!=="Root"&&d!=="root"||!1,f=h||!1;let m;process.env.NODE_ENV!=="production"&&c&&(m=`${c}-${Pa(d||"Root")}`);let S=qn;d==="Root"||d==="root"?S=r:d?S=o:wp(i)&&(S=void 0);const R=Gr(i,O({shouldForwardProp:S,label:m},b)),j=v=>typeof v=="function"&&v.__emotion_real!==v||mt(v)?P=>Hn(v,O({},P,{theme:Ln({theme:P.theme,defaultTheme:n,themeId:t})})):v,E=(v,...P)=>{let V=j(v);const U=P?P.map(j):[];c&&w&&U.push(k=>{const A=Ln(O({},k,{defaultTheme:n,themeId:t}));if(!A.components||!A.components[c]||!A.components[c].styleOverrides)return null;const $=A.components[c].styleOverrides,J={};return Object.entries($).forEach(([Y,F])=>{J[Y]=Hn(F,O({},k,{theme:A}))}),w(k,J)}),c&&!x&&U.push(k=>{var A;const $=Ln(O({},k,{defaultTheme:n,themeId:t})),J=$==null||(A=$.components)==null||(A=A[c])==null?void 0:A.variants;return Hn({variants:J},O({},k,{theme:$}))}),f||U.push(s);const C=U.length-P.length;if(Array.isArray(v)&&C>0){const k=new Array(C).fill("");V=[...v,...k],V.raw=[...v.raw,...k]}const _=R(V,...U);if(process.env.NODE_ENV!=="production"){let k;c&&(k=`${c}${Ye(d||"")}`),k===void 0&&(k=`Styled(${Vd(i)})`),_.displayName=k}return i.muiName&&(_.muiName=i.muiName),_};return R.withConfig&&(E.withConfig=R.withConfig),E}}function gp(e){const{theme:t,name:n,props:r}=e;return!t||!t.components||!t.components[n]||!t.components[n].defaultProps?r:pi(t.components[n].defaultProps,r)}function bp({props:e,name:t,defaultTheme:n,themeId:r}){let o=xi(n);return r&&(o=o[r]||o),gp({theme:o,name:t,props:e})}function Mo(e,t=0,n=1){return process.env.NODE_ENV!=="production"&&(en)&&console.error(`MUI: The value provided ${e} is out of range [${t}, ${n}].`),lu(e,t,n)}function vp(e){e=e.slice(1);const t=new RegExp(`.{1,${e.length>=6?2:1}}`,"g");let n=e.match(t);return n&&n[0].length===1&&(n=n.map(r=>r+r)),n?`rgb${n.length===4?"a":""}(${n.map((r,o)=>o<3?parseInt(r,16):Math.round(parseInt(r,16)/255*1e3)/1e3).join(", ")})`:""}function Nt(e){if(e.type)return e;if(e.charAt(0)==="#")return Nt(vp(e));const t=e.indexOf("("),n=e.substring(0,t);if(["rgb","rgba","hsl","hsla","color"].indexOf(n)===-1)throw new Error(process.env.NODE_ENV!=="production"?`MUI: Unsupported \`${e}\` color. +`)),()=>{})}function di(e){return _n(e,"spacing",8,"spacing")}function Pn(e,t){if(typeof t=="string"||t==null)return t;const n=Math.abs(t),r=e(n);return t>=0?r:typeof r=="number"?-r:`-${r}`}function yu(e,t){return n=>e.reduce((r,o)=>(r[o]=Pn(t,n),r),{})}function Nu(e,t,n,r){if(t.indexOf(n)===-1)return null;const o=vu(n),s=yu(o,r),i=e[n];return et(e,i,s)}function ui(e,t){const n=di(e.theme);return Object.keys(e).map(r=>Nu(e,t,r,n)).reduce(mn,{})}function me(e){return ui(e,wr)}me.propTypes=process.env.NODE_ENV!=="production"?wr.reduce((e,t)=>(e[t]=st,e),{}):{};me.filterProps=wr;function he(e){return ui(e,fr)}he.propTypes=process.env.NODE_ENV!=="production"?fr.reduce((e,t)=>(e[t]=st,e),{}):{};he.filterProps=fr;process.env.NODE_ENV!=="production"&&xu.reduce((e,t)=>(e[t]=st,e),{});function ku(e=8){if(e.mui)return e;const t=di({spacing:e}),n=(...r)=>(process.env.NODE_ENV!=="production"&&(r.length<=4||console.error(`MUI: Too many arguments provided, expected between 0 and 4, got ${r.length}`)),(r.length===0?[1]:r).map(s=>{const i=t(s);return typeof i=="number"?`${i}px`:i}).join(" "));return n.mui=!0,n}function mr(...e){const t=e.reduce((r,o)=>(o.filterProps.forEach(s=>{r[s]=o}),r),{}),n=r=>Object.keys(r).reduce((o,s)=>t[s]?mn(o,t[s](r)):o,{});return n.propTypes=process.env.NODE_ENV!=="production"?e.reduce((r,o)=>Object.assign(r,o.propTypes),{}):{},n.filterProps=e.reduce((r,o)=>r.concat(o.filterProps),[]),n}function Be(e){return typeof e!="number"?e:`${e}px solid`}function Fe(e,t){return ve({prop:e,themeKey:"borders",transform:t})}const Su=Fe("border",Be),Eu=Fe("borderTop",Be),ju=Fe("borderRight",Be),Cu=Fe("borderBottom",Be),Tu=Fe("borderLeft",Be),Ru=Fe("borderColor"),Ou=Fe("borderTopColor"),_u=Fe("borderRightColor"),Pu=Fe("borderBottomColor"),Iu=Fe("borderLeftColor"),Mu=Fe("outline",Be),$u=Fe("outlineColor"),hr=e=>{if(e.borderRadius!==void 0&&e.borderRadius!==null){const t=_n(e.theme,"shape.borderRadius",4,"borderRadius"),n=r=>({borderRadius:Pn(t,r)});return et(e,e.borderRadius,n)}return null};hr.propTypes=process.env.NODE_ENV!=="production"?{borderRadius:st}:{};hr.filterProps=["borderRadius"];mr(Su,Eu,ju,Cu,Tu,Ru,Ou,_u,Pu,Iu,hr,Mu,$u);const gr=e=>{if(e.gap!==void 0&&e.gap!==null){const t=_n(e.theme,"spacing",8,"gap"),n=r=>({gap:Pn(t,r)});return et(e,e.gap,n)}return null};gr.propTypes=process.env.NODE_ENV!=="production"?{gap:st}:{};gr.filterProps=["gap"];const br=e=>{if(e.columnGap!==void 0&&e.columnGap!==null){const t=_n(e.theme,"spacing",8,"columnGap"),n=r=>({columnGap:Pn(t,r)});return et(e,e.columnGap,n)}return null};br.propTypes=process.env.NODE_ENV!=="production"?{columnGap:st}:{};br.filterProps=["columnGap"];const vr=e=>{if(e.rowGap!==void 0&&e.rowGap!==null){const t=_n(e.theme,"spacing",8,"rowGap"),n=r=>({rowGap:Pn(t,r)});return et(e,e.rowGap,n)}return null};vr.propTypes=process.env.NODE_ENV!=="production"?{rowGap:st}:{};vr.filterProps=["rowGap"];const Du=ve({prop:"gridColumn"}),Au=ve({prop:"gridRow"}),Bu=ve({prop:"gridAutoFlow"}),Vu=ve({prop:"gridAutoColumns"}),zu=ve({prop:"gridAutoRows"}),Lu=ve({prop:"gridTemplateColumns"}),Fu=ve({prop:"gridTemplateRows"}),Gu=ve({prop:"gridTemplateAreas"}),Uu=ve({prop:"gridArea"});mr(gr,br,vr,Du,Au,Bu,Vu,zu,Lu,Fu,Gu,Uu);function Dt(e,t){return t==="grey"?t:e}const qu=ve({prop:"color",themeKey:"palette",transform:Dt}),Hu=ve({prop:"bgcolor",cssProperty:"backgroundColor",themeKey:"palette",transform:Dt}),Xu=ve({prop:"backgroundColor",themeKey:"palette",transform:Dt});mr(qu,Hu,Xu);function Ie(e){return e<=1&&e!==0?`${e*100}%`:e}const Yu=ve({prop:"width",transform:Ie}),Eo=e=>{if(e.maxWidth!==void 0&&e.maxWidth!==null){const t=n=>{var r,o;const s=((r=e.theme)==null||(r=r.breakpoints)==null||(r=r.values)==null?void 0:r[n])||So[n];return s?((o=e.theme)==null||(o=o.breakpoints)==null?void 0:o.unit)!=="px"?{maxWidth:`${s}${e.theme.breakpoints.unit}`}:{maxWidth:s}:{maxWidth:Ie(n)}};return et(e,e.maxWidth,t)}return null};Eo.filterProps=["maxWidth"];const Wu=ve({prop:"minWidth",transform:Ie}),Ku=ve({prop:"height",transform:Ie}),Ju=ve({prop:"maxHeight",transform:Ie}),Zu=ve({prop:"minHeight",transform:Ie});ve({prop:"size",cssProperty:"width",transform:Ie});ve({prop:"size",cssProperty:"height",transform:Ie});const Qu=ve({prop:"boxSizing"});mr(Yu,Eo,Wu,Ku,Ju,Zu,Qu);const ep={border:{themeKey:"borders",transform:Be},borderTop:{themeKey:"borders",transform:Be},borderRight:{themeKey:"borders",transform:Be},borderBottom:{themeKey:"borders",transform:Be},borderLeft:{themeKey:"borders",transform:Be},borderColor:{themeKey:"palette"},borderTopColor:{themeKey:"palette"},borderRightColor:{themeKey:"palette"},borderBottomColor:{themeKey:"palette"},borderLeftColor:{themeKey:"palette"},outline:{themeKey:"borders",transform:Be},outlineColor:{themeKey:"palette"},borderRadius:{themeKey:"shape.borderRadius",style:hr},color:{themeKey:"palette",transform:Dt},bgcolor:{themeKey:"palette",cssProperty:"backgroundColor",transform:Dt},backgroundColor:{themeKey:"palette",transform:Dt},p:{style:he},pt:{style:he},pr:{style:he},pb:{style:he},pl:{style:he},px:{style:he},py:{style:he},padding:{style:he},paddingTop:{style:he},paddingRight:{style:he},paddingBottom:{style:he},paddingLeft:{style:he},paddingX:{style:he},paddingY:{style:he},paddingInline:{style:he},paddingInlineStart:{style:he},paddingInlineEnd:{style:he},paddingBlock:{style:he},paddingBlockStart:{style:he},paddingBlockEnd:{style:he},m:{style:me},mt:{style:me},mr:{style:me},mb:{style:me},ml:{style:me},mx:{style:me},my:{style:me},margin:{style:me},marginTop:{style:me},marginRight:{style:me},marginBottom:{style:me},marginLeft:{style:me},marginX:{style:me},marginY:{style:me},marginInline:{style:me},marginInlineStart:{style:me},marginInlineEnd:{style:me},marginBlock:{style:me},marginBlockStart:{style:me},marginBlockEnd:{style:me},displayPrint:{cssProperty:!1,transform:e=>({"@media print":{display:e}})},display:{},overflow:{},textOverflow:{},visibility:{},whiteSpace:{},flexBasis:{},flexDirection:{},flexWrap:{},justifyContent:{},alignItems:{},alignContent:{},order:{},flex:{},flexGrow:{},flexShrink:{},alignSelf:{},justifyItems:{},justifySelf:{},gap:{style:gr},rowGap:{style:vr},columnGap:{style:br},gridColumn:{},gridRow:{},gridAutoFlow:{},gridAutoColumns:{},gridAutoRows:{},gridTemplateColumns:{},gridTemplateRows:{},gridTemplateAreas:{},gridArea:{},position:{},zIndex:{themeKey:"zIndex"},top:{},right:{},bottom:{},left:{},boxShadow:{themeKey:"shadows"},width:{transform:Ie},maxWidth:{style:Eo},minWidth:{transform:Ie},height:{transform:Ie},maxHeight:{transform:Ie},minHeight:{transform:Ie},boxSizing:{},fontFamily:{themeKey:"typography"},fontSize:{themeKey:"typography"},fontStyle:{themeKey:"typography"},fontWeight:{themeKey:"typography"},letterSpacing:{},textTransform:{},lineHeight:{},textAlign:{},typography:{cssProperty:!1,themeKey:"typography"}},jo=ep;function tp(...e){const t=e.reduce((r,o)=>r.concat(Object.keys(o)),[]),n=new Set(t);return e.every(r=>n.size===Object.keys(r).length)}function np(e,t){return typeof e=="function"?e(t):e}function rp(){function e(n,r,o,s){const i={[n]:r,theme:o},l=s[n];if(!l)return{[n]:r};const{cssProperty:c=n,themeKey:d,transform:u,style:h}=l;if(r==null)return null;if(d==="typography"&&r==="inherit")return{[n]:r};const w=pr(o,d)||{};return h?h(i):et(i,r,x=>{let f=Zn(w,u,x);return x===f&&typeof x=="string"&&(f=Zn(w,u,`${n}${x==="default"?"":Ye(x)}`,x)),c===!1?f:{[c]:f}})}function t(n){var r;const{sx:o,theme:s={}}=n||{};if(!o)return null;const i=(r=s.unstable_sxConfig)!=null?r:jo;function l(c){let d=c;if(typeof c=="function")d=c(s);else if(typeof c!="object")return c;if(!d)return null;const u=fu(s.breakpoints),h=Object.keys(u);let w=u;return Object.keys(d).forEach(b=>{const x=np(d[b],s);if(x!=null)if(typeof x=="object")if(i[b])w=mn(w,e(b,x,s,i));else{const f=et({theme:s},x,m=>({[b]:m}));tp(f,x)?w[b]=t({sx:x,theme:s}):w=mn(w,f)}else w=mn(w,e(b,x,s,i))}),mu(h,w)}return Array.isArray(o)?o.map(l):l(o)}return t}const pi=rp();pi.filterProps=["sx"];const Co=pi;function op(e,t){const n=this;return n.vars&&typeof n.getColorSchemeSelector=="function"?{[n.getColorSchemeSelector(e).replace(/(\[[^\]]+\])/,"*:where($1)")]:t}:n.palette.mode===e?t:{}}const ap=["breakpoints","palette","spacing","shape"];function To(e={},...t){const{breakpoints:n={},palette:r={},spacing:o,shape:s={}}=e,i=Ne(e,ap),l=du(n),c=ku(o);let d=Qe({breakpoints:l,direction:"ltr",components:{},palette:O({mode:"light"},r),spacing:c,shape:O({},pu,s)},i);return d.applyStyles=op,d=t.reduce((u,h)=>Qe(u,h),d),d.unstable_sxConfig=O({},jo,i==null?void 0:i.unstable_sxConfig),d.unstable_sx=function(h){return Co({sx:h,theme:this})},d}function sp(e){return Object.keys(e).length===0}function wi(e=null){const t=M.useContext(Gr.ThemeContext);return!t||sp(t)?e:t}const ip=To();function fi(e=ip){return wi(e)}const lp=["ownerState"],cp=["variants"],dp=["name","slot","skipVariantsResolver","skipSx","overridesResolver"];function up(e){return Object.keys(e).length===0}function pp(e){return typeof e=="string"&&e.charCodeAt(0)>96}function qn(e){return e!=="ownerState"&&e!=="theme"&&e!=="sx"&&e!=="as"}const wp=To(),Ca=e=>e&&e.charAt(0).toLowerCase()+e.slice(1);function Ln({defaultTheme:e,theme:t,themeId:n}){return up(t)?e:t[n]||t}function fp(e){return e?(t,n)=>n[e]:null}function Hn(e,t){let{ownerState:n}=t,r=Ne(t,lp);const o=typeof e=="function"?e(O({ownerState:n},r)):e;if(Array.isArray(o))return o.flatMap(s=>Hn(s,O({ownerState:n},r)));if(o&&typeof o=="object"&&Array.isArray(o.variants)){const{variants:s=[]}=o;let l=Ne(o,cp);return s.forEach(c=>{let d=!0;typeof c.props=="function"?d=c.props(O({ownerState:n},r,n)):Object.keys(c.props).forEach(u=>{(n==null?void 0:n[u])!==c.props[u]&&r[u]!==c.props[u]&&(d=!1)}),d&&(Array.isArray(l)||(l=[l]),l.push(typeof c.style=="function"?c.style(O({ownerState:n},r,n)):c.style))}),l}return o}function mp(e={}){const{themeId:t,defaultTheme:n=wp,rootShouldForwardProp:r=qn,slotShouldForwardProp:o=qn}=e,s=i=>Co(O({},i,{theme:Ln(O({},i,{defaultTheme:n,themeId:t}))}));return s.__mui_systemSx=!0,(i,l={})=>{Gr.internal_processStyles(i,v=>v.filter(P=>!(P!=null&&P.__mui_systemSx)));const{name:c,slot:d,skipVariantsResolver:u,skipSx:h,overridesResolver:w=fp(Ca(d))}=l,b=Ne(l,dp),x=u!==void 0?u:d&&d!=="Root"&&d!=="root"||!1,f=h||!1;let m;process.env.NODE_ENV!=="production"&&c&&(m=`${c}-${Ca(d||"Root")}`);let S=qn;d==="Root"||d==="root"?S=r:d?S=o:pp(i)&&(S=void 0);const R=Gr(i,O({shouldForwardProp:S,label:m},b)),j=v=>typeof v=="function"&&v.__emotion_real!==v||mt(v)?P=>Hn(v,O({},P,{theme:Ln({theme:P.theme,defaultTheme:n,themeId:t})})):v,E=(v,...P)=>{let V=j(v);const U=P?P.map(j):[];c&&w&&U.push(k=>{const D=Ln(O({},k,{defaultTheme:n,themeId:t}));if(!D.components||!D.components[c]||!D.components[c].styleOverrides)return null;const $=D.components[c].styleOverrides,J={};return Object.entries($).forEach(([Y,F])=>{J[Y]=Hn(F,O({},k,{theme:D}))}),w(k,J)}),c&&!x&&U.push(k=>{var D;const $=Ln(O({},k,{defaultTheme:n,themeId:t})),J=$==null||(D=$.components)==null||(D=D[c])==null?void 0:D.variants;return Hn({variants:J},O({},k,{theme:$}))}),f||U.push(s);const C=U.length-P.length;if(Array.isArray(v)&&C>0){const k=new Array(C).fill("");V=[...v,...k],V.raw=[...v.raw,...k]}const _=R(V,...U);if(process.env.NODE_ENV!=="production"){let k;c&&(k=`${c}${Ye(d||"")}`),k===void 0&&(k=`Styled(${Bd(i)})`),_.displayName=k}return i.muiName&&(_.muiName=i.muiName),_};return R.withConfig&&(E.withConfig=R.withConfig),E}}function hp(e){const{theme:t,name:n,props:r}=e;return!t||!t.components||!t.components[n]||!t.components[n].defaultProps?r:si(t.components[n].defaultProps,r)}function gp({props:e,name:t,defaultTheme:n,themeId:r}){let o=fi(n);return r&&(o=o[r]||o),hp({theme:o,name:t,props:e})}function Ro(e,t=0,n=1){return process.env.NODE_ENV!=="production"&&(en)&&console.error(`MUI: The value provided ${e} is out of range [${t}, ${n}].`),iu(e,t,n)}function bp(e){e=e.slice(1);const t=new RegExp(`.{1,${e.length>=6?2:1}}`,"g");let n=e.match(t);return n&&n[0].length===1&&(n=n.map(r=>r+r)),n?`rgb${n.length===4?"a":""}(${n.map((r,o)=>o<3?parseInt(r,16):Math.round(parseInt(r,16)/255*1e3)/1e3).join(", ")})`:""}function Nt(e){if(e.type)return e;if(e.charAt(0)==="#")return Nt(bp(e));const t=e.indexOf("("),n=e.substring(0,t);if(["rgb","rgba","hsl","hsla","color"].indexOf(n)===-1)throw new Error(process.env.NODE_ENV!=="production"?`MUI: Unsupported \`${e}\` color. The following formats are supported: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color().`:zt(9,e));let r=e.substring(t+1,e.length-1),o;if(n==="color"){if(r=r.split(" "),o=r.shift(),r.length===4&&r[3].charAt(0)==="/"&&(r[3]=r[3].slice(1)),["srgb","display-p3","a98-rgb","prophoto-rgb","rec-2020"].indexOf(o)===-1)throw new Error(process.env.NODE_ENV!=="production"?`MUI: unsupported \`${o}\` color space. -The following color spaces are supported: srgb, display-p3, a98-rgb, prophoto-rgb, rec-2020.`:zt(10,o))}else r=r.split(",");return r=r.map(s=>parseFloat(s)),{type:n,values:r,colorSpace:o}}function xr(e){const{type:t,colorSpace:n}=e;let{values:r}=e;return t.indexOf("rgb")!==-1?r=r.map((o,s)=>s<3?parseInt(o,10):o):t.indexOf("hsl")!==-1&&(r[1]=`${r[1]}%`,r[2]=`${r[2]}%`),t.indexOf("color")!==-1?r=`${n} ${r.join(" ")}`:r=`${r.join(", ")}`,`${t}(${r})`}function xp(e){e=Nt(e);const{values:t}=e,n=t[0],r=t[1]/100,o=t[2]/100,s=r*Math.min(o,1-o),i=(d,u=(d+n/30)%12)=>o-s*Math.max(Math.min(u-3,9-u,1),-1);let l="rgb";const c=[Math.round(i(0)*255),Math.round(i(8)*255),Math.round(i(4)*255)];return e.type==="hsla"&&(l+="a",c.push(t[3])),xr({type:l,values:c})}function Ia(e){e=Nt(e);let t=e.type==="hsl"||e.type==="hsla"?Nt(xp(e)).values:e.values;return t=t.map(n=>(e.type!=="color"&&(n/=255),n<=.03928?n/12.92:((n+.055)/1.055)**2.4)),Number((.2126*t[0]+.7152*t[1]+.0722*t[2]).toFixed(3))}function Ma(e,t){const n=Ia(e),r=Ia(t);return(Math.max(n,r)+.05)/(Math.min(n,r)+.05)}function yi(e,t){return e=Nt(e),t=Mo(t),(e.type==="rgb"||e.type==="hsl")&&(e.type+="a"),e.type==="color"?e.values[3]=`/${t}`:e.values[3]=t,xr(e)}function yp(e,t){if(e=Nt(e),t=Mo(t),e.type.indexOf("hsl")!==-1)e.values[2]*=1-t;else if(e.type.indexOf("rgb")!==-1||e.type.indexOf("color")!==-1)for(let n=0;n<3;n+=1)e.values[n]*=1-t;return xr(e)}function Np(e,t){if(e=Nt(e),t=Mo(t),e.type.indexOf("hsl")!==-1)e.values[2]+=(100-e.values[2])*t;else if(e.type.indexOf("rgb")!==-1)for(let n=0;n<3;n+=1)e.values[n]+=(255-e.values[n])*t;else if(e.type.indexOf("color")!==-1)for(let n=0;n<3;n+=1)e.values[n]+=(1-e.values[n])*t;return xr(e)}function kp(e,t){return O({toolbar:{minHeight:56,[e.up("xs")]:{"@media (orientation: landscape)":{minHeight:48}},[e.up("sm")]:{minHeight:64}}},t)}const Sp={black:"#000",white:"#fff"},yn=Sp,Ep={50:"#fafafa",100:"#f5f5f5",200:"#eeeeee",300:"#e0e0e0",400:"#bdbdbd",500:"#9e9e9e",600:"#757575",700:"#616161",800:"#424242",900:"#212121",A100:"#f5f5f5",A200:"#eeeeee",A400:"#bdbdbd",A700:"#616161"},jp=Ep,Cp={50:"#f3e5f5",100:"#e1bee7",200:"#ce93d8",300:"#ba68c8",400:"#ab47bc",500:"#9c27b0",600:"#8e24aa",700:"#7b1fa2",800:"#6a1b9a",900:"#4a148c",A100:"#ea80fc",A200:"#e040fb",A400:"#d500f9",A700:"#aa00ff"},Rt=Cp,Tp={50:"#ffebee",100:"#ffcdd2",200:"#ef9a9a",300:"#e57373",400:"#ef5350",500:"#f44336",600:"#e53935",700:"#d32f2f",800:"#c62828",900:"#b71c1c",A100:"#ff8a80",A200:"#ff5252",A400:"#ff1744",A700:"#d50000"},Ot=Tp,Rp={50:"#fff3e0",100:"#ffe0b2",200:"#ffcc80",300:"#ffb74d",400:"#ffa726",500:"#ff9800",600:"#fb8c00",700:"#f57c00",800:"#ef6c00",900:"#e65100",A100:"#ffd180",A200:"#ffab40",A400:"#ff9100",A700:"#ff6d00"},on=Rp,Op={50:"#e3f2fd",100:"#bbdefb",200:"#90caf9",300:"#64b5f6",400:"#42a5f5",500:"#2196f3",600:"#1e88e5",700:"#1976d2",800:"#1565c0",900:"#0d47a1",A100:"#82b1ff",A200:"#448aff",A400:"#2979ff",A700:"#2962ff"},_t=Op,_p={50:"#e1f5fe",100:"#b3e5fc",200:"#81d4fa",300:"#4fc3f7",400:"#29b6f6",500:"#03a9f4",600:"#039be5",700:"#0288d1",800:"#0277bd",900:"#01579b",A100:"#80d8ff",A200:"#40c4ff",A400:"#00b0ff",A700:"#0091ea"},Pt=_p,Pp={50:"#e8f5e9",100:"#c8e6c9",200:"#a5d6a7",300:"#81c784",400:"#66bb6a",500:"#4caf50",600:"#43a047",700:"#388e3c",800:"#2e7d32",900:"#1b5e20",A100:"#b9f6ca",A200:"#69f0ae",A400:"#00e676",A700:"#00c853"},It=Pp,Ip=["mode","contrastThreshold","tonalOffset"],$a={text:{primary:"rgba(0, 0, 0, 0.87)",secondary:"rgba(0, 0, 0, 0.6)",disabled:"rgba(0, 0, 0, 0.38)"},divider:"rgba(0, 0, 0, 0.12)",background:{paper:yn.white,default:yn.white},action:{active:"rgba(0, 0, 0, 0.54)",hover:"rgba(0, 0, 0, 0.04)",hoverOpacity:.04,selected:"rgba(0, 0, 0, 0.08)",selectedOpacity:.08,disabled:"rgba(0, 0, 0, 0.26)",disabledBackground:"rgba(0, 0, 0, 0.12)",disabledOpacity:.38,focus:"rgba(0, 0, 0, 0.12)",focusOpacity:.12,activatedOpacity:.12}},zr={text:{primary:yn.white,secondary:"rgba(255, 255, 255, 0.7)",disabled:"rgba(255, 255, 255, 0.5)",icon:"rgba(255, 255, 255, 0.5)"},divider:"rgba(255, 255, 255, 0.12)",background:{paper:"#121212",default:"#121212"},action:{active:yn.white,hover:"rgba(255, 255, 255, 0.08)",hoverOpacity:.08,selected:"rgba(255, 255, 255, 0.16)",selectedOpacity:.16,disabled:"rgba(255, 255, 255, 0.3)",disabledBackground:"rgba(255, 255, 255, 0.12)",disabledOpacity:.38,focus:"rgba(255, 255, 255, 0.12)",focusOpacity:.12,activatedOpacity:.24}};function Aa(e,t,n,r){const o=r.light||r,s=r.dark||r*1.5;e[t]||(e.hasOwnProperty(n)?e[t]=e[n]:t==="light"?e.light=Np(e.main,o):t==="dark"&&(e.dark=yp(e.main,s)))}function Mp(e="light"){return e==="dark"?{main:_t[200],light:_t[50],dark:_t[400]}:{main:_t[700],light:_t[400],dark:_t[800]}}function $p(e="light"){return e==="dark"?{main:Rt[200],light:Rt[50],dark:Rt[400]}:{main:Rt[500],light:Rt[300],dark:Rt[700]}}function Ap(e="light"){return e==="dark"?{main:Ot[500],light:Ot[300],dark:Ot[700]}:{main:Ot[700],light:Ot[400],dark:Ot[800]}}function Dp(e="light"){return e==="dark"?{main:Pt[400],light:Pt[300],dark:Pt[700]}:{main:Pt[700],light:Pt[500],dark:Pt[900]}}function Bp(e="light"){return e==="dark"?{main:It[400],light:It[300],dark:It[700]}:{main:It[800],light:It[500],dark:It[900]}}function Vp(e="light"){return e==="dark"?{main:on[400],light:on[300],dark:on[700]}:{main:"#ed6c02",light:on[500],dark:on[900]}}function zp(e){const{mode:t="light",contrastThreshold:n=3,tonalOffset:r=.2}=e,o=Ne(e,Ip),s=e.primary||Mp(t),i=e.secondary||$p(t),l=e.error||Ap(t),c=e.info||Dp(t),d=e.success||Bp(t),u=e.warning||Vp(t);function h(f){const m=Ma(f,zr.text.primary)>=n?zr.text.primary:$a.text.primary;if(process.env.NODE_ENV!=="production"){const S=Ma(f,m);S<3&&console.error([`MUI: The contrast ratio of ${S}:1 for ${m} on ${f}`,"falls below the WCAG recommended absolute minimum contrast ratio of 3:1.","https://www.w3.org/TR/2008/REC-WCAG20-20081211/#visual-audio-contrast-contrast"].join(` +The following color spaces are supported: srgb, display-p3, a98-rgb, prophoto-rgb, rec-2020.`:zt(10,o))}else r=r.split(",");return r=r.map(s=>parseFloat(s)),{type:n,values:r,colorSpace:o}}function xr(e){const{type:t,colorSpace:n}=e;let{values:r}=e;return t.indexOf("rgb")!==-1?r=r.map((o,s)=>s<3?parseInt(o,10):o):t.indexOf("hsl")!==-1&&(r[1]=`${r[1]}%`,r[2]=`${r[2]}%`),t.indexOf("color")!==-1?r=`${n} ${r.join(" ")}`:r=`${r.join(", ")}`,`${t}(${r})`}function vp(e){e=Nt(e);const{values:t}=e,n=t[0],r=t[1]/100,o=t[2]/100,s=r*Math.min(o,1-o),i=(d,u=(d+n/30)%12)=>o-s*Math.max(Math.min(u-3,9-u,1),-1);let l="rgb";const c=[Math.round(i(0)*255),Math.round(i(8)*255),Math.round(i(4)*255)];return e.type==="hsla"&&(l+="a",c.push(t[3])),xr({type:l,values:c})}function Ta(e){e=Nt(e);let t=e.type==="hsl"||e.type==="hsla"?Nt(vp(e)).values:e.values;return t=t.map(n=>(e.type!=="color"&&(n/=255),n<=.03928?n/12.92:((n+.055)/1.055)**2.4)),Number((.2126*t[0]+.7152*t[1]+.0722*t[2]).toFixed(3))}function Ra(e,t){const n=Ta(e),r=Ta(t);return(Math.max(n,r)+.05)/(Math.min(n,r)+.05)}function mi(e,t){return e=Nt(e),t=Ro(t),(e.type==="rgb"||e.type==="hsl")&&(e.type+="a"),e.type==="color"?e.values[3]=`/${t}`:e.values[3]=t,xr(e)}function xp(e,t){if(e=Nt(e),t=Ro(t),e.type.indexOf("hsl")!==-1)e.values[2]*=1-t;else if(e.type.indexOf("rgb")!==-1||e.type.indexOf("color")!==-1)for(let n=0;n<3;n+=1)e.values[n]*=1-t;return xr(e)}function yp(e,t){if(e=Nt(e),t=Ro(t),e.type.indexOf("hsl")!==-1)e.values[2]+=(100-e.values[2])*t;else if(e.type.indexOf("rgb")!==-1)for(let n=0;n<3;n+=1)e.values[n]+=(255-e.values[n])*t;else if(e.type.indexOf("color")!==-1)for(let n=0;n<3;n+=1)e.values[n]+=(1-e.values[n])*t;return xr(e)}function Np(e,t){return O({toolbar:{minHeight:56,[e.up("xs")]:{"@media (orientation: landscape)":{minHeight:48}},[e.up("sm")]:{minHeight:64}}},t)}const kp={black:"#000",white:"#fff"},yn=kp,Sp={50:"#fafafa",100:"#f5f5f5",200:"#eeeeee",300:"#e0e0e0",400:"#bdbdbd",500:"#9e9e9e",600:"#757575",700:"#616161",800:"#424242",900:"#212121",A100:"#f5f5f5",A200:"#eeeeee",A400:"#bdbdbd",A700:"#616161"},Ep=Sp,jp={50:"#f3e5f5",100:"#e1bee7",200:"#ce93d8",300:"#ba68c8",400:"#ab47bc",500:"#9c27b0",600:"#8e24aa",700:"#7b1fa2",800:"#6a1b9a",900:"#4a148c",A100:"#ea80fc",A200:"#e040fb",A400:"#d500f9",A700:"#aa00ff"},Rt=jp,Cp={50:"#ffebee",100:"#ffcdd2",200:"#ef9a9a",300:"#e57373",400:"#ef5350",500:"#f44336",600:"#e53935",700:"#d32f2f",800:"#c62828",900:"#b71c1c",A100:"#ff8a80",A200:"#ff5252",A400:"#ff1744",A700:"#d50000"},Ot=Cp,Tp={50:"#fff3e0",100:"#ffe0b2",200:"#ffcc80",300:"#ffb74d",400:"#ffa726",500:"#ff9800",600:"#fb8c00",700:"#f57c00",800:"#ef6c00",900:"#e65100",A100:"#ffd180",A200:"#ffab40",A400:"#ff9100",A700:"#ff6d00"},on=Tp,Rp={50:"#e3f2fd",100:"#bbdefb",200:"#90caf9",300:"#64b5f6",400:"#42a5f5",500:"#2196f3",600:"#1e88e5",700:"#1976d2",800:"#1565c0",900:"#0d47a1",A100:"#82b1ff",A200:"#448aff",A400:"#2979ff",A700:"#2962ff"},_t=Rp,Op={50:"#e1f5fe",100:"#b3e5fc",200:"#81d4fa",300:"#4fc3f7",400:"#29b6f6",500:"#03a9f4",600:"#039be5",700:"#0288d1",800:"#0277bd",900:"#01579b",A100:"#80d8ff",A200:"#40c4ff",A400:"#00b0ff",A700:"#0091ea"},Pt=Op,_p={50:"#e8f5e9",100:"#c8e6c9",200:"#a5d6a7",300:"#81c784",400:"#66bb6a",500:"#4caf50",600:"#43a047",700:"#388e3c",800:"#2e7d32",900:"#1b5e20",A100:"#b9f6ca",A200:"#69f0ae",A400:"#00e676",A700:"#00c853"},It=_p,Pp=["mode","contrastThreshold","tonalOffset"],Oa={text:{primary:"rgba(0, 0, 0, 0.87)",secondary:"rgba(0, 0, 0, 0.6)",disabled:"rgba(0, 0, 0, 0.38)"},divider:"rgba(0, 0, 0, 0.12)",background:{paper:yn.white,default:yn.white},action:{active:"rgba(0, 0, 0, 0.54)",hover:"rgba(0, 0, 0, 0.04)",hoverOpacity:.04,selected:"rgba(0, 0, 0, 0.08)",selectedOpacity:.08,disabled:"rgba(0, 0, 0, 0.26)",disabledBackground:"rgba(0, 0, 0, 0.12)",disabledOpacity:.38,focus:"rgba(0, 0, 0, 0.12)",focusOpacity:.12,activatedOpacity:.12}},zr={text:{primary:yn.white,secondary:"rgba(255, 255, 255, 0.7)",disabled:"rgba(255, 255, 255, 0.5)",icon:"rgba(255, 255, 255, 0.5)"},divider:"rgba(255, 255, 255, 0.12)",background:{paper:"#121212",default:"#121212"},action:{active:yn.white,hover:"rgba(255, 255, 255, 0.08)",hoverOpacity:.08,selected:"rgba(255, 255, 255, 0.16)",selectedOpacity:.16,disabled:"rgba(255, 255, 255, 0.3)",disabledBackground:"rgba(255, 255, 255, 0.12)",disabledOpacity:.38,focus:"rgba(255, 255, 255, 0.12)",focusOpacity:.12,activatedOpacity:.24}};function _a(e,t,n,r){const o=r.light||r,s=r.dark||r*1.5;e[t]||(e.hasOwnProperty(n)?e[t]=e[n]:t==="light"?e.light=yp(e.main,o):t==="dark"&&(e.dark=xp(e.main,s)))}function Ip(e="light"){return e==="dark"?{main:_t[200],light:_t[50],dark:_t[400]}:{main:_t[700],light:_t[400],dark:_t[800]}}function Mp(e="light"){return e==="dark"?{main:Rt[200],light:Rt[50],dark:Rt[400]}:{main:Rt[500],light:Rt[300],dark:Rt[700]}}function $p(e="light"){return e==="dark"?{main:Ot[500],light:Ot[300],dark:Ot[700]}:{main:Ot[700],light:Ot[400],dark:Ot[800]}}function Dp(e="light"){return e==="dark"?{main:Pt[400],light:Pt[300],dark:Pt[700]}:{main:Pt[700],light:Pt[500],dark:Pt[900]}}function Ap(e="light"){return e==="dark"?{main:It[400],light:It[300],dark:It[700]}:{main:It[800],light:It[500],dark:It[900]}}function Bp(e="light"){return e==="dark"?{main:on[400],light:on[300],dark:on[700]}:{main:"#ed6c02",light:on[500],dark:on[900]}}function Vp(e){const{mode:t="light",contrastThreshold:n=3,tonalOffset:r=.2}=e,o=Ne(e,Pp),s=e.primary||Ip(t),i=e.secondary||Mp(t),l=e.error||$p(t),c=e.info||Dp(t),d=e.success||Ap(t),u=e.warning||Bp(t);function h(f){const m=Ra(f,zr.text.primary)>=n?zr.text.primary:Oa.text.primary;if(process.env.NODE_ENV!=="production"){const S=Ra(f,m);S<3&&console.error([`MUI: The contrast ratio of ${S}:1 for ${m} on ${f}`,"falls below the WCAG recommended absolute minimum contrast ratio of 3:1.","https://www.w3.org/TR/2008/REC-WCAG20-20081211/#visual-audio-contrast-contrast"].join(` `))}return m}const w=({color:f,name:m,mainShade:S=500,lightShade:R=300,darkShade:j=700})=>{if(f=O({},f),!f.main&&f[S]&&(f.main=f[S]),!f.hasOwnProperty("main"))throw new Error(process.env.NODE_ENV!=="production"?`MUI: The color${m?` (${m})`:""} provided to augmentColor(color) is invalid. The color object needs to have a \`main\` property or a \`${S}\` property.`:zt(11,m?` (${m})`:"",S));if(typeof f.main!="string")throw new Error(process.env.NODE_ENV!=="production"?`MUI: The color${m?` (${m})`:""} provided to augmentColor(color) is invalid. \`color.main\` should be a string, but \`${JSON.stringify(f.main)}\` was provided instead. @@ -55,16 +55,16 @@ const theme1 = createTheme({ palette: { const theme2 = createTheme({ palette: { primary: { main: green[500] }, -} });`:zt(12,m?` (${m})`:"",JSON.stringify(f.main)));return Aa(f,"light",R,r),Aa(f,"dark",j,r),f.contrastText||(f.contrastText=h(f.main)),f},b={dark:zr,light:$a};return process.env.NODE_ENV!=="production"&&(b[t]||console.error(`MUI: The palette mode \`${t}\` is not supported.`)),Qe(O({common:O({},yn),mode:t,primary:w({color:s,name:"primary"}),secondary:w({color:i,name:"secondary",mainShade:"A400",lightShade:"A200",darkShade:"A700"}),error:w({color:l,name:"error"}),warning:w({color:u,name:"warning"}),info:w({color:c,name:"info"}),success:w({color:d,name:"success"}),grey:jp,contrastThreshold:n,getContrastText:h,augmentColor:w,tonalOffset:r},b[t]),o)}const Lp=["fontFamily","fontSize","fontWeightLight","fontWeightRegular","fontWeightMedium","fontWeightBold","htmlFontSize","allVariants","pxToRem"];function Fp(e){return Math.round(e*1e5)/1e5}const Da={textTransform:"uppercase"},Ba='"Roboto", "Helvetica", "Arial", sans-serif';function Gp(e,t){const n=typeof t=="function"?t(e):t,{fontFamily:r=Ba,fontSize:o=14,fontWeightLight:s=300,fontWeightRegular:i=400,fontWeightMedium:l=500,fontWeightBold:c=700,htmlFontSize:d=16,allVariants:u,pxToRem:h}=n,w=Ne(n,Lp);process.env.NODE_ENV!=="production"&&(typeof o!="number"&&console.error("MUI: `fontSize` is required to be a number."),typeof d!="number"&&console.error("MUI: `htmlFontSize` is required to be a number."));const b=o/14,x=h||(S=>`${S/d*b}rem`),f=(S,R,j,E,v)=>O({fontFamily:r,fontWeight:S,fontSize:x(R),lineHeight:j},r===Ba?{letterSpacing:`${Fp(E/R)}em`}:{},v,u),m={h1:f(s,96,1.167,-1.5),h2:f(s,60,1.2,-.5),h3:f(i,48,1.167,0),h4:f(i,34,1.235,.25),h5:f(i,24,1.334,0),h6:f(l,20,1.6,.15),subtitle1:f(i,16,1.75,.15),subtitle2:f(l,14,1.57,.1),body1:f(i,16,1.5,.15),body2:f(i,14,1.43,.15),button:f(l,14,1.75,.4,Da),caption:f(i,12,1.66,.4),overline:f(i,12,2.66,1,Da),inherit:{fontFamily:"inherit",fontWeight:"inherit",fontSize:"inherit",lineHeight:"inherit",letterSpacing:"inherit"}};return Qe(O({htmlFontSize:d,pxToRem:x,fontFamily:r,fontSize:o,fontWeightLight:s,fontWeightRegular:i,fontWeightMedium:l,fontWeightBold:c},m),w,{clone:!1})}const Up=.2,qp=.14,Hp=.12;function we(...e){return[`${e[0]}px ${e[1]}px ${e[2]}px ${e[3]}px rgba(0,0,0,${Up})`,`${e[4]}px ${e[5]}px ${e[6]}px ${e[7]}px rgba(0,0,0,${qp})`,`${e[8]}px ${e[9]}px ${e[10]}px ${e[11]}px rgba(0,0,0,${Hp})`].join(",")}const Xp=["none",we(0,2,1,-1,0,1,1,0,0,1,3,0),we(0,3,1,-2,0,2,2,0,0,1,5,0),we(0,3,3,-2,0,3,4,0,0,1,8,0),we(0,2,4,-1,0,4,5,0,0,1,10,0),we(0,3,5,-1,0,5,8,0,0,1,14,0),we(0,3,5,-1,0,6,10,0,0,1,18,0),we(0,4,5,-2,0,7,10,1,0,2,16,1),we(0,5,5,-3,0,8,10,1,0,3,14,2),we(0,5,6,-3,0,9,12,1,0,3,16,2),we(0,6,6,-3,0,10,14,1,0,4,18,3),we(0,6,7,-4,0,11,15,1,0,4,20,3),we(0,7,8,-4,0,12,17,2,0,5,22,4),we(0,7,8,-4,0,13,19,2,0,5,24,4),we(0,7,9,-4,0,14,21,2,0,5,26,4),we(0,8,9,-5,0,15,22,2,0,6,28,5),we(0,8,10,-5,0,16,24,2,0,6,30,5),we(0,8,11,-5,0,17,26,2,0,6,32,5),we(0,9,11,-5,0,18,28,2,0,7,34,6),we(0,9,12,-6,0,19,29,2,0,7,36,6),we(0,10,13,-6,0,20,31,3,0,8,38,7),we(0,10,13,-6,0,21,33,3,0,8,40,7),we(0,10,14,-6,0,22,35,3,0,8,42,7),we(0,11,14,-7,0,23,36,3,0,9,44,8),we(0,11,15,-7,0,24,38,3,0,9,46,8)],Yp=Xp,Wp=["duration","easing","delay"],Kp={easeInOut:"cubic-bezier(0.4, 0, 0.2, 1)",easeOut:"cubic-bezier(0.0, 0, 0.2, 1)",easeIn:"cubic-bezier(0.4, 0, 1, 1)",sharp:"cubic-bezier(0.4, 0, 0.6, 1)"},Jp={shortest:150,shorter:200,short:250,standard:300,complex:375,enteringScreen:225,leavingScreen:195};function Va(e){return`${Math.round(e)}ms`}function Zp(e){if(!e)return 0;const t=e/36;return Math.round((4+15*t**.25+t/5)*10)}function Qp(e){const t=O({},Kp,e.easing),n=O({},Jp,e.duration);return O({getAutoHeightDuration:Zp,create:(o=["all"],s={})=>{const{duration:i=n.standard,easing:l=t.easeInOut,delay:c=0}=s,d=Ne(s,Wp);if(process.env.NODE_ENV!=="production"){const u=w=>typeof w=="string",h=w=>!isNaN(parseFloat(w));!u(o)&&!Array.isArray(o)&&console.error('MUI: Argument "props" must be a string or Array.'),!h(i)&&!u(i)&&console.error(`MUI: Argument "duration" must be a number or a string but found ${i}.`),u(l)||console.error('MUI: Argument "easing" must be a string.'),!h(c)&&!u(c)&&console.error('MUI: Argument "delay" must be a number or a string.'),typeof s!="object"&&console.error(["MUI: Secong argument of transition.create must be an object.","Arguments should be either `create('prop1', options)` or `create(['prop1', 'prop2'], options)`"].join(` -`)),Object.keys(d).length!==0&&console.error(`MUI: Unrecognized argument(s) [${Object.keys(d).join(",")}].`)}return(Array.isArray(o)?o:[o]).map(u=>`${u} ${typeof i=="string"?i:Va(i)} ${l} ${typeof c=="string"?c:Va(c)}`).join(",")}},e,{easing:t,duration:n})}const ew={mobileStepper:1e3,fab:1050,speedDial:1050,appBar:1100,drawer:1200,modal:1300,snackbar:1400,tooltip:1500},tw=ew,nw=["breakpoints","mixins","spacing","palette","transitions","typography","shape"];function rw(e={},...t){const{mixins:n={},palette:r={},transitions:o={},typography:s={}}=e,i=Ne(e,nw);if(e.vars)throw new Error(process.env.NODE_ENV!=="production"?"MUI: `vars` is a private field used for CSS variables support.\nPlease use another name.":zt(18));const l=zp(r),c=Io(e);let d=Qe(c,{mixins:kp(c.breakpoints,n),palette:l,shadows:Yp.slice(),typography:Gp(l,s),transitions:Qp(o),zIndex:O({},tw)});if(d=Qe(d,i),d=t.reduce((u,h)=>Qe(u,h),d),process.env.NODE_ENV!=="production"){const u=["active","checked","completed","disabled","error","expanded","focused","focusVisible","required","selected"],h=(w,b)=>{let x;for(x in w){const f=w[x];if(u.indexOf(x)!==-1&&Object.keys(f).length>0){if(process.env.NODE_ENV!=="production"){const m=ur("",x);console.error([`MUI: The \`${b}\` component increases the CSS specificity of the \`${x}\` internal state.`,"You can not override it like this: ",JSON.stringify(w,null,2),"",`Instead, you need to use the '&.${m}' syntax:`,JSON.stringify({root:{[`&.${m}`]:f}},null,2),"","https://mui.com/r/state-classes-guide"].join(` -`))}w[x]={}}}};Object.keys(d.components).forEach(w=>{const b=d.components[w].styleOverrides;b&&w.indexOf("Mui")===0&&h(b,w)})}return d.unstable_sxConfig=O({},_o,i==null?void 0:i.unstable_sxConfig),d.unstable_sx=function(h){return Po({sx:h,theme:this})},d}const ow=rw(),$o=ow,Ao="$$material";function Do({props:e,name:t}){return bp({props:e,name:t,defaultTheme:$o,themeId:Ao})}const aw=e=>qn(e)&&e!=="classes",sw=hp({themeId:Ao,defaultTheme:$o,rootShouldForwardProp:aw}),In=sw;function iw(e){return ur("MuiSvgIcon",e)}mi("MuiSvgIcon",["root","colorPrimary","colorSecondary","colorAction","colorError","colorDisabled","fontSizeInherit","fontSizeSmall","fontSizeMedium","fontSizeLarge"]);const lw=["children","className","color","component","fontSize","htmlColor","inheritViewBox","titleAccess","viewBox"],cw=e=>{const{color:t,fontSize:n,classes:r}=e,o={root:["root",t!=="inherit"&&`color${Ye(t)}`,`fontSize${Ye(n)}`]};return To(o,iw,r)},dw=In("svg",{name:"MuiSvgIcon",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.root,n.color!=="inherit"&&t[`color${Ye(n.color)}`],t[`fontSize${Ye(n.fontSize)}`]]}})(({theme:e,ownerState:t})=>{var n,r,o,s,i,l,c,d,u,h,w,b,x;return{userSelect:"none",width:"1em",height:"1em",display:"inline-block",fill:t.hasSvgAsChild?void 0:"currentColor",flexShrink:0,transition:(n=e.transitions)==null||(r=n.create)==null?void 0:r.call(n,"fill",{duration:(o=e.transitions)==null||(o=o.duration)==null?void 0:o.shorter}),fontSize:{inherit:"inherit",small:((s=e.typography)==null||(i=s.pxToRem)==null?void 0:i.call(s,20))||"1.25rem",medium:((l=e.typography)==null||(c=l.pxToRem)==null?void 0:c.call(l,24))||"1.5rem",large:((d=e.typography)==null||(u=d.pxToRem)==null?void 0:u.call(d,35))||"2.1875rem"}[t.fontSize],color:(h=(w=(e.vars||e).palette)==null||(w=w[t.color])==null?void 0:w.main)!=null?h:{action:(b=(e.vars||e).palette)==null||(b=b.action)==null?void 0:b.active,disabled:(x=(e.vars||e).palette)==null||(x=x.action)==null?void 0:x.disabled,inherit:void 0}[t.color]}}),Bo=M.forwardRef(function(t,n){const r=Do({props:t,name:"MuiSvgIcon"}),{children:o,className:s,color:i="inherit",component:l="svg",fontSize:c="medium",htmlColor:d,inheritViewBox:u=!1,titleAccess:h,viewBox:w="0 0 24 24"}=r,b=Ne(r,lw),x=M.isValidElement(o)&&o.type==="svg",f=O({},r,{color:i,component:l,fontSize:c,instanceFontSize:t.fontSize,inheritViewBox:u,viewBox:w,hasSvgAsChild:x}),m={};u||(m.viewBox=w);const S=cw(f);return a.jsxs(dw,O({as:l,className:ot(S.root,s),focusable:"false",color:d,"aria-hidden":h?void 0:!0,role:h?"img":void 0,ref:n},m,b,x&&o.props,{ownerState:f,children:[x?o.props.children:o,h?a.jsx("title",{children:h}):null]}))});process.env.NODE_ENV!=="production"&&(Bo.propTypes={children:p.node,classes:p.object,className:p.string,color:p.oneOfType([p.oneOf(["inherit","action","disabled","primary","secondary","error","info","success","warning"]),p.string]),component:p.elementType,fontSize:p.oneOfType([p.oneOf(["inherit","large","medium","small"]),p.string]),htmlColor:p.string,inheritViewBox:p.bool,shapeRendering:p.string,sx:p.oneOfType([p.arrayOf(p.oneOfType([p.func,p.object,p.bool])),p.func,p.object]),titleAccess:p.string,viewBox:p.string});Bo.muiName="SvgIcon";const za=Bo;function Ni(e,t){function n(r,o){return a.jsx(za,O({"data-testid":`${t}Icon`,ref:o},r,{children:e}))}return process.env.NODE_ENV!=="production"&&(n.displayName=`${t}Icon`),n.muiName=za.muiName,M.memo(M.forwardRef(n))}const uw={configure:e=>{process.env.NODE_ENV!=="production"&&console.warn(["MUI: `ClassNameGenerator` import from `@mui/material/utils` is outdated and might cause unexpected issues.","","You should use `import { unstable_ClassNameGenerator } from '@mui/material/className'` instead","","The detail of the issue: https://github.com/mui/material-ui/issues/30011#issuecomment-1024993401","","The updated documentation: https://mui.com/guides/classname-generator/"].join(` -`)),wi.configure(e)}},pw=Object.freeze(Object.defineProperty({__proto__:null,capitalize:Ye,createChainedFunction:Ld,createSvgIcon:Ni,debounce:Fd,deprecatedPropType:Gd,isMuiElement:Ud,ownerDocument:Kn,ownerWindow:qd,requirePropFactory:Hd,setRef:Jn,unstable_ClassNameGenerator:uw,unstable_useEnhancedEffect:Lt,unstable_useId:ci,unsupportedProp:Wd,useControlled:di,useEventCallback:Zr,useForkRef:yt,useIsFocusVisible:ui},Symbol.toStringTag,{value:"Module"})),ww=yd(pw);var La;function fw(){return La||(La=1,function(e){"use client";Object.defineProperty(e,"__esModule",{value:!0}),Object.defineProperty(e,"default",{enumerable:!0,get:function(){return t.createSvgIcon}});var t=ww}(Pr)),Pr}var mw=Nd;Object.defineProperty(Eo,"__esModule",{value:!0});var ki=Eo.default=void 0,hw=mw(fw()),gw=a;ki=Eo.default=(0,hw.default)((0,gw.jsx)("path",{d:"m10 17 5-5-5-5z"}),"ArrowRight");function bw(e){return typeof e=="string"}function un(e,t,n){return e===void 0||bw(e)?t:O({},t,{ownerState:O({},t.ownerState,n)})}const vw={disableDefaultClasses:!1},xw=M.createContext(vw);function yw(e){const{disableDefaultClasses:t}=M.useContext(xw);return n=>t?"":e(n)}function Nw(e,t=[]){if(e===void 0)return{};const n={};return Object.keys(e).filter(r=>r.match(/^on[A-Z]/)&&typeof e[r]=="function"&&!t.includes(r)).forEach(r=>{n[r]=e[r]}),n}function kw(e,t,n){return typeof e=="function"?e(t,n):e}function Fa(e){if(e===void 0)return{};const t={};return Object.keys(e).filter(n=>!(n.match(/^on[A-Z]/)&&typeof e[n]=="function")).forEach(n=>{t[n]=e[n]}),t}function Sw(e){const{getSlotProps:t,additionalProps:n,externalSlotProps:r,externalForwardedProps:o,className:s}=e;if(!t){const b=ot(n==null?void 0:n.className,s,o==null?void 0:o.className,r==null?void 0:r.className),x=O({},n==null?void 0:n.style,o==null?void 0:o.style,r==null?void 0:r.style),f=O({},n,o,r);return b.length>0&&(f.className=b),Object.keys(x).length>0&&(f.style=x),{props:f,internalRef:void 0}}const i=Nw(O({},o,r)),l=Fa(r),c=Fa(o),d=t(i),u=ot(d==null?void 0:d.className,n==null?void 0:n.className,s,o==null?void 0:o.className,r==null?void 0:r.className),h=O({},d==null?void 0:d.style,n==null?void 0:n.style,o==null?void 0:o.style,r==null?void 0:r.style),w=O({},d,n,c,l);return u.length>0&&(w.className=u),Object.keys(h).length>0&&(w.style=h),{props:w,internalRef:d.ref}}const Ew=["elementType","externalSlotProps","ownerState","skipResolvingSlotProps"];function jw(e){var t;const{elementType:n,externalSlotProps:r,ownerState:o,skipResolvingSlotProps:s=!1}=e,i=Ne(e,Ew),l=s?{}:kw(r,o),{props:c,internalRef:d}=Sw(O({},i,{externalSlotProps:l})),u=yt(d,l==null?void 0:l.ref,(t=e.additionalProps)==null?void 0:t.ref);return un(n,O({},c,{ref:u}),o)}const Si="base";function Cw(e){return`${Si}--${e}`}function Tw(e,t){return`${Si}-${e}-${t}`}function Ei(e,t){const n=fi[t];return n?Cw(n):Tw(e,t)}function Rw(e,t){const n={};return t.forEach(r=>{n[r]=Ei(e,r)}),n}function Ow(e){return typeof e=="function"?e():e}const Qn=M.forwardRef(function(t,n){const{children:r,container:o,disablePortal:s=!1}=t,[i,l]=M.useState(null),c=yt(M.isValidElement(r)?r.ref:null,n);if(Lt(()=>{s||l(Ow(o)||document.body)},[o,s]),Lt(()=>{if(i&&!s)return Jn(n,i),()=>{Jn(n,null)}},[n,i,s]),s){if(M.isValidElement(r)){const d={ref:c};return M.cloneElement(r,d)}return a.jsx(M.Fragment,{children:r})}return a.jsx(M.Fragment,{children:i&&Ol.createPortal(r,i)})});process.env.NODE_ENV!=="production"&&(Qn.propTypes={children:p.node,container:p.oneOfType([xn,p.func]),disablePortal:p.bool});process.env.NODE_ENV!=="production"&&(Qn["propTypes"]=Md(Qn.propTypes));var Ce="top",ze="bottom",Le="right",Te="left",Vo="auto",Mn=[Ce,ze,Le,Te],Ft="start",Nn="end",_w="clippingParents",ji="viewport",an="popper",Pw="reference",Ga=Mn.reduce(function(e,t){return e.concat([t+"-"+Ft,t+"-"+Nn])},[]),Ci=[].concat(Mn,[Vo]).reduce(function(e,t){return e.concat([t,t+"-"+Ft,t+"-"+Nn])},[]),Iw="beforeRead",Mw="read",$w="afterRead",Aw="beforeMain",Dw="main",Bw="afterMain",Vw="beforeWrite",zw="write",Lw="afterWrite",Fw=[Iw,Mw,$w,Aw,Dw,Bw,Vw,zw,Lw];function We(e){return e?(e.nodeName||"").toLowerCase():null}function $e(e){if(e==null)return window;if(e.toString()!=="[object Window]"){var t=e.ownerDocument;return t&&t.defaultView||window}return e}function kt(e){var t=$e(e).Element;return e instanceof t||e instanceof Element}function Ve(e){var t=$e(e).HTMLElement;return e instanceof t||e instanceof HTMLElement}function zo(e){if(typeof ShadowRoot>"u")return!1;var t=$e(e).ShadowRoot;return e instanceof t||e instanceof ShadowRoot}function Gw(e){var t=e.state;Object.keys(t.elements).forEach(function(n){var r=t.styles[n]||{},o=t.attributes[n]||{},s=t.elements[n];!Ve(s)||!We(s)||(Object.assign(s.style,r),Object.keys(o).forEach(function(i){var l=o[i];l===!1?s.removeAttribute(i):s.setAttribute(i,l===!0?"":l)}))})}function Uw(e){var t=e.state,n={popper:{position:t.options.strategy,left:"0",top:"0",margin:"0"},arrow:{position:"absolute"},reference:{}};return Object.assign(t.elements.popper.style,n.popper),t.styles=n,t.elements.arrow&&Object.assign(t.elements.arrow.style,n.arrow),function(){Object.keys(t.elements).forEach(function(r){var o=t.elements[r],s=t.attributes[r]||{},i=Object.keys(t.styles.hasOwnProperty(r)?t.styles[r]:n[r]),l=i.reduce(function(c,d){return c[d]="",c},{});!Ve(o)||!We(o)||(Object.assign(o.style,l),Object.keys(s).forEach(function(c){o.removeAttribute(c)}))})}}const qw={name:"applyStyles",enabled:!0,phase:"write",fn:Gw,effect:Uw,requires:["computeStyles"]};function Xe(e){return e.split("-")[0]}var ht=Math.max,er=Math.min,Gt=Math.round;function eo(){var e=navigator.userAgentData;return e!=null&&e.brands&&Array.isArray(e.brands)?e.brands.map(function(t){return t.brand+"/"+t.version}).join(" "):navigator.userAgent}function Ti(){return!/^((?!chrome|android).)*safari/i.test(eo())}function Ut(e,t,n){t===void 0&&(t=!1),n===void 0&&(n=!1);var r=e.getBoundingClientRect(),o=1,s=1;t&&Ve(e)&&(o=e.offsetWidth>0&&Gt(r.width)/e.offsetWidth||1,s=e.offsetHeight>0&&Gt(r.height)/e.offsetHeight||1);var i=kt(e)?$e(e):window,l=i.visualViewport,c=!Ti()&&n,d=(r.left+(c&&l?l.offsetLeft:0))/o,u=(r.top+(c&&l?l.offsetTop:0))/s,h=r.width/o,w=r.height/s;return{width:h,height:w,top:u,right:d+h,bottom:u+w,left:d,x:d,y:u}}function Lo(e){var t=Ut(e),n=e.offsetWidth,r=e.offsetHeight;return Math.abs(t.width-n)<=1&&(n=t.width),Math.abs(t.height-r)<=1&&(r=t.height),{x:e.offsetLeft,y:e.offsetTop,width:n,height:r}}function Ri(e,t){var n=t.getRootNode&&t.getRootNode();if(e.contains(t))return!0;if(n&&zo(n)){var r=t;do{if(r&&e.isSameNode(r))return!0;r=r.parentNode||r.host}while(r)}return!1}function tt(e){return $e(e).getComputedStyle(e)}function Hw(e){return["table","td","th"].indexOf(We(e))>=0}function it(e){return((kt(e)?e.ownerDocument:e.document)||window.document).documentElement}function yr(e){return We(e)==="html"?e:e.assignedSlot||e.parentNode||(zo(e)?e.host:null)||it(e)}function Ua(e){return!Ve(e)||tt(e).position==="fixed"?null:e.offsetParent}function Xw(e){var t=/firefox/i.test(eo()),n=/Trident/i.test(eo());if(n&&Ve(e)){var r=tt(e);if(r.position==="fixed")return null}var o=yr(e);for(zo(o)&&(o=o.host);Ve(o)&&["html","body"].indexOf(We(o))<0;){var s=tt(o);if(s.transform!=="none"||s.perspective!=="none"||s.contain==="paint"||["transform","perspective"].indexOf(s.willChange)!==-1||t&&s.willChange==="filter"||t&&s.filter&&s.filter!=="none")return o;o=o.parentNode}return null}function $n(e){for(var t=$e(e),n=Ua(e);n&&Hw(n)&&tt(n).position==="static";)n=Ua(n);return n&&(We(n)==="html"||We(n)==="body"&&tt(n).position==="static")?t:n||Xw(e)||t}function Fo(e){return["top","bottom"].indexOf(e)>=0?"x":"y"}function hn(e,t,n){return ht(e,er(t,n))}function Yw(e,t,n){var r=hn(e,t,n);return r>n?n:r}function Oi(){return{top:0,right:0,bottom:0,left:0}}function _i(e){return Object.assign({},Oi(),e)}function Pi(e,t){return t.reduce(function(n,r){return n[r]=e,n},{})}var Ww=function(t,n){return t=typeof t=="function"?t(Object.assign({},n.rects,{placement:n.placement})):t,_i(typeof t!="number"?t:Pi(t,Mn))};function Kw(e){var t,n=e.state,r=e.name,o=e.options,s=n.elements.arrow,i=n.modifiersData.popperOffsets,l=Xe(n.placement),c=Fo(l),d=[Te,Le].indexOf(l)>=0,u=d?"height":"width";if(!(!s||!i)){var h=Ww(o.padding,n),w=Lo(s),b=c==="y"?Ce:Te,x=c==="y"?ze:Le,f=n.rects.reference[u]+n.rects.reference[c]-i[c]-n.rects.popper[u],m=i[c]-n.rects.reference[c],S=$n(s),R=S?c==="y"?S.clientHeight||0:S.clientWidth||0:0,j=f/2-m/2,E=h[b],v=R-w[u]-h[x],P=R/2-w[u]/2+j,V=hn(E,P,v),U=c;n.modifiersData[r]=(t={},t[U]=V,t.centerOffset=V-P,t)}}function Jw(e){var t=e.state,n=e.options,r=n.element,o=r===void 0?"[data-popper-arrow]":r;o!=null&&(typeof o=="string"&&(o=t.elements.popper.querySelector(o),!o)||Ri(t.elements.popper,o)&&(t.elements.arrow=o))}const Zw={name:"arrow",enabled:!0,phase:"main",fn:Kw,effect:Jw,requires:["popperOffsets"],requiresIfExists:["preventOverflow"]};function qt(e){return e.split("-")[1]}var Qw={top:"auto",right:"auto",bottom:"auto",left:"auto"};function ef(e,t){var n=e.x,r=e.y,o=t.devicePixelRatio||1;return{x:Gt(n*o)/o||0,y:Gt(r*o)/o||0}}function qa(e){var t,n=e.popper,r=e.popperRect,o=e.placement,s=e.variation,i=e.offsets,l=e.position,c=e.gpuAcceleration,d=e.adaptive,u=e.roundOffsets,h=e.isFixed,w=i.x,b=w===void 0?0:w,x=i.y,f=x===void 0?0:x,m=typeof u=="function"?u({x:b,y:f}):{x:b,y:f};b=m.x,f=m.y;var S=i.hasOwnProperty("x"),R=i.hasOwnProperty("y"),j=Te,E=Ce,v=window;if(d){var P=$n(n),V="clientHeight",U="clientWidth";if(P===$e(n)&&(P=it(n),tt(P).position!=="static"&&l==="absolute"&&(V="scrollHeight",U="scrollWidth")),P=P,o===Ce||(o===Te||o===Le)&&s===Nn){E=ze;var C=h&&P===v&&v.visualViewport?v.visualViewport.height:P[V];f-=C-r.height,f*=c?1:-1}if(o===Te||(o===Ce||o===ze)&&s===Nn){j=Le;var _=h&&P===v&&v.visualViewport?v.visualViewport.width:P[U];b-=_-r.width,b*=c?1:-1}}var k=Object.assign({position:l},d&&Qw),A=u===!0?ef({x:b,y:f},$e(n)):{x:b,y:f};if(b=A.x,f=A.y,c){var $;return Object.assign({},k,($={},$[E]=R?"0":"",$[j]=S?"0":"",$.transform=(v.devicePixelRatio||1)<=1?"translate("+b+"px, "+f+"px)":"translate3d("+b+"px, "+f+"px, 0)",$))}return Object.assign({},k,(t={},t[E]=R?f+"px":"",t[j]=S?b+"px":"",t.transform="",t))}function tf(e){var t=e.state,n=e.options,r=n.gpuAcceleration,o=r===void 0?!0:r,s=n.adaptive,i=s===void 0?!0:s,l=n.roundOffsets,c=l===void 0?!0:l,d={placement:Xe(t.placement),variation:qt(t.placement),popper:t.elements.popper,popperRect:t.rects.popper,gpuAcceleration:o,isFixed:t.options.strategy==="fixed"};t.modifiersData.popperOffsets!=null&&(t.styles.popper=Object.assign({},t.styles.popper,qa(Object.assign({},d,{offsets:t.modifiersData.popperOffsets,position:t.options.strategy,adaptive:i,roundOffsets:c})))),t.modifiersData.arrow!=null&&(t.styles.arrow=Object.assign({},t.styles.arrow,qa(Object.assign({},d,{offsets:t.modifiersData.arrow,position:"absolute",adaptive:!1,roundOffsets:c})))),t.attributes.popper=Object.assign({},t.attributes.popper,{"data-popper-placement":t.placement})}const nf={name:"computeStyles",enabled:!0,phase:"beforeWrite",fn:tf,data:{}};var Fn={passive:!0};function rf(e){var t=e.state,n=e.instance,r=e.options,o=r.scroll,s=o===void 0?!0:o,i=r.resize,l=i===void 0?!0:i,c=$e(t.elements.popper),d=[].concat(t.scrollParents.reference,t.scrollParents.popper);return s&&d.forEach(function(u){u.addEventListener("scroll",n.update,Fn)}),l&&c.addEventListener("resize",n.update,Fn),function(){s&&d.forEach(function(u){u.removeEventListener("scroll",n.update,Fn)}),l&&c.removeEventListener("resize",n.update,Fn)}}const of={name:"eventListeners",enabled:!0,phase:"write",fn:function(){},effect:rf,data:{}};var af={left:"right",right:"left",bottom:"top",top:"bottom"};function Xn(e){return e.replace(/left|right|bottom|top/g,function(t){return af[t]})}var sf={start:"end",end:"start"};function Ha(e){return e.replace(/start|end/g,function(t){return sf[t]})}function Go(e){var t=$e(e),n=t.pageXOffset,r=t.pageYOffset;return{scrollLeft:n,scrollTop:r}}function Uo(e){return Ut(it(e)).left+Go(e).scrollLeft}function lf(e,t){var n=$e(e),r=it(e),o=n.visualViewport,s=r.clientWidth,i=r.clientHeight,l=0,c=0;if(o){s=o.width,i=o.height;var d=Ti();(d||!d&&t==="fixed")&&(l=o.offsetLeft,c=o.offsetTop)}return{width:s,height:i,x:l+Uo(e),y:c}}function cf(e){var t,n=it(e),r=Go(e),o=(t=e.ownerDocument)==null?void 0:t.body,s=ht(n.scrollWidth,n.clientWidth,o?o.scrollWidth:0,o?o.clientWidth:0),i=ht(n.scrollHeight,n.clientHeight,o?o.scrollHeight:0,o?o.clientHeight:0),l=-r.scrollLeft+Uo(e),c=-r.scrollTop;return tt(o||n).direction==="rtl"&&(l+=ht(n.clientWidth,o?o.clientWidth:0)-s),{width:s,height:i,x:l,y:c}}function qo(e){var t=tt(e),n=t.overflow,r=t.overflowX,o=t.overflowY;return/auto|scroll|overlay|hidden/.test(n+o+r)}function Ii(e){return["html","body","#document"].indexOf(We(e))>=0?e.ownerDocument.body:Ve(e)&&qo(e)?e:Ii(yr(e))}function gn(e,t){var n;t===void 0&&(t=[]);var r=Ii(e),o=r===((n=e.ownerDocument)==null?void 0:n.body),s=$e(r),i=o?[s].concat(s.visualViewport||[],qo(r)?r:[]):r,l=t.concat(i);return o?l:l.concat(gn(yr(i)))}function to(e){return Object.assign({},e,{left:e.x,top:e.y,right:e.x+e.width,bottom:e.y+e.height})}function df(e,t){var n=Ut(e,!1,t==="fixed");return n.top=n.top+e.clientTop,n.left=n.left+e.clientLeft,n.bottom=n.top+e.clientHeight,n.right=n.left+e.clientWidth,n.width=e.clientWidth,n.height=e.clientHeight,n.x=n.left,n.y=n.top,n}function Xa(e,t,n){return t===ji?to(lf(e,n)):kt(t)?df(t,n):to(cf(it(e)))}function uf(e){var t=gn(yr(e)),n=["absolute","fixed"].indexOf(tt(e).position)>=0,r=n&&Ve(e)?$n(e):e;return kt(r)?t.filter(function(o){return kt(o)&&Ri(o,r)&&We(o)!=="body"}):[]}function pf(e,t,n,r){var o=t==="clippingParents"?uf(e):[].concat(t),s=[].concat(o,[n]),i=s[0],l=s.reduce(function(c,d){var u=Xa(e,d,r);return c.top=ht(u.top,c.top),c.right=er(u.right,c.right),c.bottom=er(u.bottom,c.bottom),c.left=ht(u.left,c.left),c},Xa(e,i,r));return l.width=l.right-l.left,l.height=l.bottom-l.top,l.x=l.left,l.y=l.top,l}function Mi(e){var t=e.reference,n=e.element,r=e.placement,o=r?Xe(r):null,s=r?qt(r):null,i=t.x+t.width/2-n.width/2,l=t.y+t.height/2-n.height/2,c;switch(o){case Ce:c={x:i,y:t.y-n.height};break;case ze:c={x:i,y:t.y+t.height};break;case Le:c={x:t.x+t.width,y:l};break;case Te:c={x:t.x-n.width,y:l};break;default:c={x:t.x,y:t.y}}var d=o?Fo(o):null;if(d!=null){var u=d==="y"?"height":"width";switch(s){case Ft:c[d]=c[d]-(t[u]/2-n[u]/2);break;case Nn:c[d]=c[d]+(t[u]/2-n[u]/2);break}}return c}function kn(e,t){t===void 0&&(t={});var n=t,r=n.placement,o=r===void 0?e.placement:r,s=n.strategy,i=s===void 0?e.strategy:s,l=n.boundary,c=l===void 0?_w:l,d=n.rootBoundary,u=d===void 0?ji:d,h=n.elementContext,w=h===void 0?an:h,b=n.altBoundary,x=b===void 0?!1:b,f=n.padding,m=f===void 0?0:f,S=_i(typeof m!="number"?m:Pi(m,Mn)),R=w===an?Pw:an,j=e.rects.popper,E=e.elements[x?R:w],v=pf(kt(E)?E:E.contextElement||it(e.elements.popper),c,u,i),P=Ut(e.elements.reference),V=Mi({reference:P,element:j,strategy:"absolute",placement:o}),U=to(Object.assign({},j,V)),C=w===an?U:P,_={top:v.top-C.top+S.top,bottom:C.bottom-v.bottom+S.bottom,left:v.left-C.left+S.left,right:C.right-v.right+S.right},k=e.modifiersData.offset;if(w===an&&k){var A=k[o];Object.keys(_).forEach(function($){var J=[Le,ze].indexOf($)>=0?1:-1,Y=[Ce,ze].indexOf($)>=0?"y":"x";_[$]+=A[Y]*J})}return _}function wf(e,t){t===void 0&&(t={});var n=t,r=n.placement,o=n.boundary,s=n.rootBoundary,i=n.padding,l=n.flipVariations,c=n.allowedAutoPlacements,d=c===void 0?Ci:c,u=qt(r),h=u?l?Ga:Ga.filter(function(x){return qt(x)===u}):Mn,w=h.filter(function(x){return d.indexOf(x)>=0});w.length===0&&(w=h);var b=w.reduce(function(x,f){return x[f]=kn(e,{placement:f,boundary:o,rootBoundary:s,padding:i})[Xe(f)],x},{});return Object.keys(b).sort(function(x,f){return b[x]-b[f]})}function ff(e){if(Xe(e)===Vo)return[];var t=Xn(e);return[Ha(e),t,Ha(t)]}function mf(e){var t=e.state,n=e.options,r=e.name;if(!t.modifiersData[r]._skip){for(var o=n.mainAxis,s=o===void 0?!0:o,i=n.altAxis,l=i===void 0?!0:i,c=n.fallbackPlacements,d=n.padding,u=n.boundary,h=n.rootBoundary,w=n.altBoundary,b=n.flipVariations,x=b===void 0?!0:b,f=n.allowedAutoPlacements,m=t.options.placement,S=Xe(m),R=S===m,j=c||(R||!x?[Xn(m)]:ff(m)),E=[m].concat(j).reduce(function(B,X){return B.concat(Xe(X)===Vo?wf(t,{placement:X,boundary:u,rootBoundary:h,padding:d,flipVariations:x,allowedAutoPlacements:f}):X)},[]),v=t.rects.reference,P=t.rects.popper,V=new Map,U=!0,C=E[0],_=0;_=0,Y=J?"width":"height",F=kn(t,{placement:k,boundary:u,rootBoundary:h,altBoundary:w,padding:d}),te=J?$?Le:Te:$?ze:Ce;v[Y]>P[Y]&&(te=Xn(te));var se=Xn(te),oe=[];if(s&&oe.push(F[A]<=0),l&&oe.push(F[te]<=0,F[se]<=0),oe.every(function(B){return B})){C=k,U=!1;break}V.set(k,oe)}if(U)for(var y=x?3:1,T=function(X){var q=E.find(function(H){var G=V.get(H);if(G)return G.slice(0,X).every(function(K){return K})});if(q)return C=q,"break"},z=y;z>0;z--){var L=T(z);if(L==="break")break}t.placement!==C&&(t.modifiersData[r]._skip=!0,t.placement=C,t.reset=!0)}}const hf={name:"flip",enabled:!0,phase:"main",fn:mf,requiresIfExists:["offset"],data:{_skip:!1}};function Ya(e,t,n){return n===void 0&&(n={x:0,y:0}),{top:e.top-t.height-n.y,right:e.right-t.width+n.x,bottom:e.bottom-t.height+n.y,left:e.left-t.width-n.x}}function Wa(e){return[Ce,Le,ze,Te].some(function(t){return e[t]>=0})}function gf(e){var t=e.state,n=e.name,r=t.rects.reference,o=t.rects.popper,s=t.modifiersData.preventOverflow,i=kn(t,{elementContext:"reference"}),l=kn(t,{altBoundary:!0}),c=Ya(i,r),d=Ya(l,o,s),u=Wa(c),h=Wa(d);t.modifiersData[n]={referenceClippingOffsets:c,popperEscapeOffsets:d,isReferenceHidden:u,hasPopperEscaped:h},t.attributes.popper=Object.assign({},t.attributes.popper,{"data-popper-reference-hidden":u,"data-popper-escaped":h})}const bf={name:"hide",enabled:!0,phase:"main",requiresIfExists:["preventOverflow"],fn:gf};function vf(e,t,n){var r=Xe(e),o=[Te,Ce].indexOf(r)>=0?-1:1,s=typeof n=="function"?n(Object.assign({},t,{placement:e})):n,i=s[0],l=s[1];return i=i||0,l=(l||0)*o,[Te,Le].indexOf(r)>=0?{x:l,y:i}:{x:i,y:l}}function xf(e){var t=e.state,n=e.options,r=e.name,o=n.offset,s=o===void 0?[0,0]:o,i=Ci.reduce(function(u,h){return u[h]=vf(h,t.rects,s),u},{}),l=i[t.placement],c=l.x,d=l.y;t.modifiersData.popperOffsets!=null&&(t.modifiersData.popperOffsets.x+=c,t.modifiersData.popperOffsets.y+=d),t.modifiersData[r]=i}const yf={name:"offset",enabled:!0,phase:"main",requires:["popperOffsets"],fn:xf};function Nf(e){var t=e.state,n=e.name;t.modifiersData[n]=Mi({reference:t.rects.reference,element:t.rects.popper,strategy:"absolute",placement:t.placement})}const kf={name:"popperOffsets",enabled:!0,phase:"read",fn:Nf,data:{}};function Sf(e){return e==="x"?"y":"x"}function Ef(e){var t=e.state,n=e.options,r=e.name,o=n.mainAxis,s=o===void 0?!0:o,i=n.altAxis,l=i===void 0?!1:i,c=n.boundary,d=n.rootBoundary,u=n.altBoundary,h=n.padding,w=n.tether,b=w===void 0?!0:w,x=n.tetherOffset,f=x===void 0?0:x,m=kn(t,{boundary:c,rootBoundary:d,padding:h,altBoundary:u}),S=Xe(t.placement),R=qt(t.placement),j=!R,E=Fo(S),v=Sf(E),P=t.modifiersData.popperOffsets,V=t.rects.reference,U=t.rects.popper,C=typeof f=="function"?f(Object.assign({},t.rects,{placement:t.placement})):f,_=typeof C=="number"?{mainAxis:C,altAxis:C}:Object.assign({mainAxis:0,altAxis:0},C),k=t.modifiersData.offset?t.modifiersData.offset[t.placement]:null,A={x:0,y:0};if(P){if(s){var $,J=E==="y"?Ce:Te,Y=E==="y"?ze:Le,F=E==="y"?"height":"width",te=P[E],se=te+m[J],oe=te-m[Y],y=b?-U[F]/2:0,T=R===Ft?V[F]:U[F],z=R===Ft?-U[F]:-V[F],L=t.elements.arrow,B=b&&L?Lo(L):{width:0,height:0},X=t.modifiersData["arrow#persistent"]?t.modifiersData["arrow#persistent"].padding:Oi(),q=X[J],H=X[Y],G=hn(0,V[F],B[F]),K=j?V[F]/2-y-G-q-_.mainAxis:T-G-q-_.mainAxis,Z=j?-V[F]/2+y+G+H+_.mainAxis:z+G+H+_.mainAxis,ue=t.elements.arrow&&$n(t.elements.arrow),I=ue?E==="y"?ue.clientTop||0:ue.clientLeft||0:0,ye=($=k==null?void 0:k[E])!=null?$:0,D=te+K-ye-I,xe=te+Z-ye,Ge=hn(b?er(se,D):se,te,b?ht(oe,xe):oe);P[E]=Ge,A[E]=Ge-te}if(l){var lt,Ee=E==="x"?Ce:Te,An=E==="x"?ze:Le,Ue=P[v],Et=v==="y"?"height":"width",ct=Ue+m[Ee],jt=Ue-m[An],Ct=[Ce,Te].indexOf(S)!==-1,Tt=(lt=k==null?void 0:k[v])!=null?lt:0,dt=Ct?ct:Ue-V[Et]-U[Et]-Tt+_.altAxis,Jt=Ct?Ue+V[Et]+U[Et]-Tt-_.altAxis:jt,Dn=b&&Ct?Yw(dt,Ue,Jt):hn(b?dt:ct,Ue,b?Jt:jt);P[v]=Dn,A[v]=Dn-Ue}t.modifiersData[r]=A}}const jf={name:"preventOverflow",enabled:!0,phase:"main",fn:Ef,requiresIfExists:["offset"]};function Cf(e){return{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}}function Tf(e){return e===$e(e)||!Ve(e)?Go(e):Cf(e)}function Rf(e){var t=e.getBoundingClientRect(),n=Gt(t.width)/e.offsetWidth||1,r=Gt(t.height)/e.offsetHeight||1;return n!==1||r!==1}function Of(e,t,n){n===void 0&&(n=!1);var r=Ve(t),o=Ve(t)&&Rf(t),s=it(t),i=Ut(e,o,n),l={scrollLeft:0,scrollTop:0},c={x:0,y:0};return(r||!r&&!n)&&((We(t)!=="body"||qo(s))&&(l=Tf(t)),Ve(t)?(c=Ut(t,!0),c.x+=t.clientLeft,c.y+=t.clientTop):s&&(c.x=Uo(s))),{x:i.left+l.scrollLeft-c.x,y:i.top+l.scrollTop-c.y,width:i.width,height:i.height}}function _f(e){var t=new Map,n=new Set,r=[];e.forEach(function(s){t.set(s.name,s)});function o(s){n.add(s.name);var i=[].concat(s.requires||[],s.requiresIfExists||[]);i.forEach(function(l){if(!n.has(l)){var c=t.get(l);c&&o(c)}}),r.push(s)}return e.forEach(function(s){n.has(s.name)||o(s)}),r}function Pf(e){var t=_f(e);return Fw.reduce(function(n,r){return n.concat(t.filter(function(o){return o.phase===r}))},[])}function If(e){var t;return function(){return t||(t=new Promise(function(n){Promise.resolve().then(function(){t=void 0,n(e())})})),t}}function Mf(e){var t=e.reduce(function(n,r){var o=n[r.name];return n[r.name]=o?Object.assign({},o,r,{options:Object.assign({},o.options,r.options),data:Object.assign({},o.data,r.data)}):r,n},{});return Object.keys(t).map(function(n){return t[n]})}var Ka={placement:"bottom",modifiers:[],strategy:"absolute"};function Ja(){for(var e=arguments.length,t=new Array(e),n=0;nTo({root:["root"]},yw(Bf)),Uf={},qf=M.forwardRef(function(t,n){var r;const{anchorEl:o,children:s,direction:i,disablePortal:l,modifiers:c,open:d,placement:u,popperOptions:h,popperRef:w,slotProps:b={},slots:x={},TransitionProps:f}=t,m=Ne(t,Vf),S=M.useRef(null),R=yt(S,n),j=M.useRef(null),E=yt(j,w),v=M.useRef(E);Lt(()=>{v.current=E},[E]),M.useImperativeHandle(w,()=>j.current,[]);const P=Lf(u,i),[V,U]=M.useState(P),[C,_]=M.useState(tr(o));M.useEffect(()=>{j.current&&j.current.forceUpdate()}),M.useEffect(()=>{o&&_(tr(o))},[o]),Lt(()=>{if(!C||!d)return;const Y=se=>{U(se.placement)};if(process.env.NODE_ENV!=="production"&&C&&Nr(C)&&C.nodeType===1){const se=C.getBoundingClientRect();process.env.NODE_ENV!=="test"&&se.top===0&&se.left===0&&se.right===0&&se.bottom===0&&console.warn(["MUI: The `anchorEl` prop provided to the component is invalid.","The anchor element should be part of the document layout.","Make sure the element is present in the document or that it's not display none."].join(` -`))}let F=[{name:"preventOverflow",options:{altBoundary:l}},{name:"flip",options:{altBoundary:l}},{name:"onUpdate",enabled:!0,phase:"afterWrite",fn:({state:se})=>{Y(se)}}];c!=null&&(F=F.concat(c)),h&&h.modifiers!=null&&(F=F.concat(h.modifiers));const te=Df(C,S.current,O({placement:P},h,{modifiers:F}));return v.current(te),()=>{te.destroy(),v.current(null)}},[C,l,c,d,h,P]);const k={placement:V};f!==null&&(k.TransitionProps=f);const A=Gf(),$=(r=x.root)!=null?r:"div",J=jw({elementType:$,externalSlotProps:b.root,externalForwardedProps:m,additionalProps:{role:"tooltip",ref:R},ownerState:t,className:A.root});return a.jsx($,O({},J,{children:typeof s=="function"?s(k):s}))}),Ai=M.forwardRef(function(t,n){const{anchorEl:r,children:o,container:s,direction:i="ltr",disablePortal:l=!1,keepMounted:c=!1,modifiers:d,open:u,placement:h="bottom",popperOptions:w=Uf,popperRef:b,style:x,transition:f=!1,slotProps:m={},slots:S={}}=t,R=Ne(t,zf),[j,E]=M.useState(!0),v=()=>{E(!1)},P=()=>{E(!0)};if(!c&&!u&&(!f||j))return null;let V;if(s)V=s;else if(r){const _=tr(r);V=_&&Nr(_)?Kn(_).body:Kn(null).body}const U=!u&&c&&(!f||j)?"none":void 0,C=f?{in:u,onEnter:v,onExited:P}:void 0;return a.jsx(Qn,{disablePortal:l,container:V,children:a.jsx(qf,O({anchorEl:r,direction:i,disablePortal:l,modifiers:d,ref:n,open:f?!j:u,placement:h,popperOptions:w,popperRef:b,slotProps:m,slots:S},R,{style:O({position:"fixed",top:0,left:0,display:U},x),TransitionProps:C,children:o}))})});process.env.NODE_ENV!=="production"&&(Ai.propTypes={anchorEl:jo(p.oneOfType([xn,p.object,p.func]),e=>{if(e.open){const t=tr(e.anchorEl);if(t&&Nr(t)&&t.nodeType===1){const n=t.getBoundingClientRect();if(process.env.NODE_ENV!=="test"&&n.top===0&&n.left===0&&n.right===0&&n.bottom===0)return new Error(["MUI: The `anchorEl` prop provided to the component is invalid.","The anchor element should be part of the document layout.","Make sure the element is present in the document or that it's not display none."].join(` -`))}else if(!t||typeof t.getBoundingClientRect!="function"||Ff(t)&&t.contextElement!=null&&t.contextElement.nodeType!==1)return new Error(["MUI: The `anchorEl` prop provided to the component is invalid.","It should be an HTML element instance or a virtualElement ","(https://popper.js.org/docs/v2/virtual-elements/)."].join(` -`))}return null}),children:p.oneOfType([p.node,p.func]),container:p.oneOfType([xn,p.func]),direction:p.oneOf(["ltr","rtl"]),disablePortal:p.bool,keepMounted:p.bool,modifiers:p.arrayOf(p.shape({data:p.object,effect:p.func,enabled:p.bool,fn:p.func,name:p.any,options:p.object,phase:p.oneOf(["afterMain","afterRead","afterWrite","beforeMain","beforeRead","beforeWrite","main","read","write"]),requires:p.arrayOf(p.string),requiresIfExists:p.arrayOf(p.string)})),open:p.bool.isRequired,placement:p.oneOf(["auto-end","auto-start","auto","bottom-end","bottom-start","bottom","left-end","left-start","left","right-end","right-start","right","top-end","top-start","top"]),popperOptions:p.shape({modifiers:p.array,onFirstUpdate:p.func,placement:p.oneOf(["auto-end","auto-start","auto","bottom-end","bottom-start","bottom","left-end","left-start","left","right-end","right-start","right","top-end","top-start","top"]),strategy:p.oneOf(["absolute","fixed"])}),popperRef:li,slotProps:p.shape({root:p.oneOfType([p.func,p.object])}),slots:p.shape({root:p.elementType}),transition:p.bool});function Di(){const e=xi($o);return process.env.NODE_ENV!=="production"&&M.useDebugValue(e),e[Ao]||e}function no(e,t){return no=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,o){return r.__proto__=o,r},no(e,t)}function Hf(e,t){e.prototype=Object.create(t.prototype),e.prototype.constructor=e,no(e,t)}const Za={disabled:!1};var Xf=process.env.NODE_ENV!=="production"?p.oneOfType([p.number,p.shape({enter:p.number,exit:p.number,appear:p.number}).isRequired]):null;process.env.NODE_ENV!=="production"&&p.oneOfType([p.string,p.shape({enter:p.string,exit:p.string,active:p.string}),p.shape({enter:p.string,enterDone:p.string,enterActive:p.string,exit:p.string,exitDone:p.string,exitActive:p.string})]);const Bi=g.createContext(null);var Yf=function(t){return t.scrollTop},pn="unmounted",wt="exited",ft="entering",$t="entered",ro="exiting",nt=function(e){Hf(t,e);function t(r,o){var s;s=e.call(this,r,o)||this;var i=o,l=i&&!i.isMounting?r.enter:r.appear,c;return s.appearStatus=null,r.in?l?(c=wt,s.appearStatus=ft):c=$t:r.unmountOnExit||r.mountOnEnter?c=pn:c=wt,s.state={status:c},s.nextCallback=null,s}t.getDerivedStateFromProps=function(o,s){var i=o.in;return i&&s.status===pn?{status:wt}:null};var n=t.prototype;return n.componentDidMount=function(){this.updateStatus(!0,this.appearStatus)},n.componentDidUpdate=function(o){var s=null;if(o!==this.props){var i=this.state.status;this.props.in?i!==ft&&i!==$t&&(s=ft):(i===ft||i===$t)&&(s=ro)}this.updateStatus(!1,s)},n.componentWillUnmount=function(){this.cancelNextCallback()},n.getTimeouts=function(){var o=this.props.timeout,s,i,l;return s=i=l=o,o!=null&&typeof o!="number"&&(s=o.exit,i=o.enter,l=o.appear!==void 0?o.appear:i),{exit:s,enter:i,appear:l}},n.updateStatus=function(o,s){if(o===void 0&&(o=!1),s!==null)if(this.cancelNextCallback(),s===ft){if(this.props.unmountOnExit||this.props.mountOnEnter){var i=this.props.nodeRef?this.props.nodeRef.current:ln.findDOMNode(this);i&&Yf(i)}this.performEnter(o)}else this.performExit();else this.props.unmountOnExit&&this.state.status===wt&&this.setState({status:pn})},n.performEnter=function(o){var s=this,i=this.props.enter,l=this.context?this.context.isMounting:o,c=this.props.nodeRef?[l]:[ln.findDOMNode(this),l],d=c[0],u=c[1],h=this.getTimeouts(),w=l?h.appear:h.enter;if(!o&&!i||Za.disabled){this.safeSetState({status:$t},function(){s.props.onEntered(d)});return}this.props.onEnter(d,u),this.safeSetState({status:ft},function(){s.props.onEntering(d,u),s.onTransitionEnd(w,function(){s.safeSetState({status:$t},function(){s.props.onEntered(d,u)})})})},n.performExit=function(){var o=this,s=this.props.exit,i=this.getTimeouts(),l=this.props.nodeRef?void 0:ln.findDOMNode(this);if(!s||Za.disabled){this.safeSetState({status:wt},function(){o.props.onExited(l)});return}this.props.onExit(l),this.safeSetState({status:ro},function(){o.props.onExiting(l),o.onTransitionEnd(i.exit,function(){o.safeSetState({status:wt},function(){o.props.onExited(l)})})})},n.cancelNextCallback=function(){this.nextCallback!==null&&(this.nextCallback.cancel(),this.nextCallback=null)},n.safeSetState=function(o,s){s=this.setNextCallback(s),this.setState(o,s)},n.setNextCallback=function(o){var s=this,i=!0;return this.nextCallback=function(l){i&&(i=!1,s.nextCallback=null,o(l))},this.nextCallback.cancel=function(){i=!1},this.nextCallback},n.onTransitionEnd=function(o,s){this.setNextCallback(s);var i=this.props.nodeRef?this.props.nodeRef.current:ln.findDOMNode(this),l=o==null&&!this.props.addEndListener;if(!i||l){setTimeout(this.nextCallback,0);return}if(this.props.addEndListener){var c=this.props.nodeRef?[this.nextCallback]:[i,this.nextCallback],d=c[0],u=c[1];this.props.addEndListener(d,u)}o!=null&&setTimeout(this.nextCallback,o)},n.render=function(){var o=this.state.status;if(o===pn)return null;var s=this.props,i=s.children;s.in,s.mountOnEnter,s.unmountOnExit,s.appear,s.enter,s.exit,s.timeout,s.addEndListener,s.onEnter,s.onEntering,s.onEntered,s.onExit,s.onExiting,s.onExited,s.nodeRef;var l=Ne(s,["children","in","mountOnEnter","unmountOnExit","appear","enter","exit","timeout","addEndListener","onEnter","onEntering","onEntered","onExit","onExiting","onExited","nodeRef"]);return g.createElement(Bi.Provider,{value:null},typeof i=="function"?i(o,l):g.cloneElement(g.Children.only(i),l))},t}(g.Component);nt.contextType=Bi;nt.propTypes=process.env.NODE_ENV!=="production"?{nodeRef:p.shape({current:typeof Element>"u"?p.any:function(e,t,n,r,o,s){var i=e[t];return p.instanceOf(i&&"ownerDocument"in i?i.ownerDocument.defaultView.Element:Element)(e,t,n,r,o,s)}}),children:p.oneOfType([p.func.isRequired,p.element.isRequired]).isRequired,in:p.bool,mountOnEnter:p.bool,unmountOnExit:p.bool,appear:p.bool,enter:p.bool,exit:p.bool,timeout:function(t){var n=Xf;t.addEndListener||(n=n.isRequired);for(var r=arguments.length,o=new Array(r>1?r-1:0),s=1;se.scrollTop;function Qa(e,t){var n,r;const{timeout:o,easing:s,style:i={}}=e;return{duration:(n=i.transitionDuration)!=null?n:typeof o=="number"?o:o[t.mode]||0,easing:(r=i.transitionTimingFunction)!=null?r:typeof s=="object"?s[t.mode]:s,delay:i.transitionDelay}}const Jf=["addEndListener","appear","children","easing","in","onEnter","onEntered","onEntering","onExit","onExited","onExiting","style","timeout","TransitionComponent"];function oo(e){return`scale(${e}, ${e**2})`}const Zf={entering:{opacity:1,transform:oo(1)},entered:{opacity:1,transform:"none"}},Lr=typeof navigator<"u"&&/^((?!chrome|android).)*(safari|mobile)/i.test(navigator.userAgent)&&/(os |version\/)15(.|_)4/i.test(navigator.userAgent),Ho=M.forwardRef(function(t,n){const{addEndListener:r,appear:o=!0,children:s,easing:i,in:l,onEnter:c,onEntered:d,onEntering:u,onExit:h,onExited:w,onExiting:b,style:x,timeout:f="auto",TransitionComponent:m=Wf}=t,S=Ne(t,Jf),R=dn(),j=M.useRef(),E=Di(),v=M.useRef(null),P=yt(v,s.ref,n),V=Y=>F=>{if(Y){const te=v.current;F===void 0?Y(te):Y(te,F)}},U=V(u),C=V((Y,F)=>{Kf(Y);const{duration:te,delay:se,easing:oe}=Qa({style:x,timeout:f,easing:i},{mode:"enter"});let y;f==="auto"?(y=E.transitions.getAutoHeightDuration(Y.clientHeight),j.current=y):y=te,Y.style.transition=[E.transitions.create("opacity",{duration:y,delay:se}),E.transitions.create("transform",{duration:Lr?y:y*.666,delay:se,easing:oe})].join(","),c&&c(Y,F)}),_=V(d),k=V(b),A=V(Y=>{const{duration:F,delay:te,easing:se}=Qa({style:x,timeout:f,easing:i},{mode:"exit"});let oe;f==="auto"?(oe=E.transitions.getAutoHeightDuration(Y.clientHeight),j.current=oe):oe=F,Y.style.transition=[E.transitions.create("opacity",{duration:oe,delay:te}),E.transitions.create("transform",{duration:Lr?oe:oe*.666,delay:Lr?te:te||oe*.333,easing:se})].join(","),Y.style.opacity=0,Y.style.transform=oo(.75),h&&h(Y)}),$=V(w),J=Y=>{f==="auto"&&R.start(j.current||0,Y),r&&r(v.current,Y)};return a.jsx(m,O({appear:o,in:l,nodeRef:v,onEnter:C,onEntered:_,onEntering:U,onExit:A,onExited:$,onExiting:k,addEndListener:J,timeout:f==="auto"?null:f},S,{children:(Y,F)=>M.cloneElement(s,O({style:O({opacity:0,transform:oo(.75),visibility:Y==="exited"&&!l?"hidden":void 0},Zf[Y],x,s.props.style),ref:P},F))}))});process.env.NODE_ENV!=="production"&&(Ho.propTypes={addEndListener:p.func,appear:p.bool,children:si.isRequired,easing:p.oneOfType([p.shape({enter:p.string,exit:p.string}),p.string]),in:p.bool,onEnter:p.func,onEntered:p.func,onEntering:p.func,onExit:p.func,onExited:p.func,onExiting:p.func,style:p.object,timeout:p.oneOfType([p.oneOf(["auto"]),p.number,p.shape({appear:p.number,enter:p.number,exit:p.number})])});Ho.muiSupportAuto=!0;const es=Ho,Qf=["anchorEl","component","components","componentsProps","container","disablePortal","keepMounted","modifiers","open","placement","popperOptions","popperRef","transition","slots","slotProps"],em=In(Ai,{name:"MuiPopper",slot:"Root",overridesResolver:(e,t)=>t.root})({}),Vi=M.forwardRef(function(t,n){var r;const o=vi(),s=Do({props:t,name:"MuiPopper"}),{anchorEl:i,component:l,components:c,componentsProps:d,container:u,disablePortal:h,keepMounted:w,modifiers:b,open:x,placement:f,popperOptions:m,popperRef:S,transition:R,slots:j,slotProps:E}=s,v=Ne(s,Qf),P=(r=j==null?void 0:j.root)!=null?r:c==null?void 0:c.Root,V=O({anchorEl:i,container:u,disablePortal:h,keepMounted:w,modifiers:b,open:x,placement:f,popperOptions:m,popperRef:S,transition:R},v);return a.jsx(em,O({as:l,direction:o==null?void 0:o.direction,slots:{root:P},slotProps:E??d},V,{ref:n}))});process.env.NODE_ENV!=="production"&&(Vi.propTypes={anchorEl:p.oneOfType([xn,p.object,p.func]),children:p.oneOfType([p.node,p.func]),component:p.elementType,components:p.shape({Root:p.elementType}),componentsProps:p.shape({root:p.oneOfType([p.func,p.object])}),container:p.oneOfType([xn,p.func]),disablePortal:p.bool,keepMounted:p.bool,modifiers:p.arrayOf(p.shape({data:p.object,effect:p.func,enabled:p.bool,fn:p.func,name:p.any,options:p.object,phase:p.oneOf(["afterMain","afterRead","afterWrite","beforeMain","beforeRead","beforeWrite","main","read","write"]),requires:p.arrayOf(p.string),requiresIfExists:p.arrayOf(p.string)})),open:p.bool.isRequired,placement:p.oneOf(["auto-end","auto-start","auto","bottom-end","bottom-start","bottom","left-end","left-start","left","right-end","right-start","right","top-end","top-start","top"]),popperOptions:p.shape({modifiers:p.array,onFirstUpdate:p.func,placement:p.oneOf(["auto-end","auto-start","auto","bottom-end","bottom-start","bottom","left-end","left-start","left","right-end","right-start","right","top-end","top-start","top"]),strategy:p.oneOf(["absolute","fixed"])}),popperRef:li,slotProps:p.shape({root:p.oneOfType([p.func,p.object])}),slots:p.shape({root:p.elementType}),sx:p.oneOfType([p.arrayOf(p.oneOfType([p.func,p.object,p.bool])),p.func,p.object]),transition:p.bool});const zi=Vi;function tm(e){return ur("MuiTooltip",e)}const nm=mi("MuiTooltip",["popper","popperInteractive","popperArrow","popperClose","tooltip","tooltipArrow","touch","tooltipPlacementLeft","tooltipPlacementRight","tooltipPlacementTop","tooltipPlacementBottom","arrow"]),at=nm,rm=["arrow","children","classes","components","componentsProps","describeChild","disableFocusListener","disableHoverListener","disableInteractive","disableTouchListener","enterDelay","enterNextDelay","enterTouchDelay","followCursor","id","leaveDelay","leaveTouchDelay","onClose","onOpen","open","placement","PopperComponent","PopperProps","slotProps","slots","title","TransitionComponent","TransitionProps"];function om(e){return Math.round(e*1e5)/1e5}const am=e=>{const{classes:t,disableInteractive:n,arrow:r,touch:o,placement:s}=e,i={popper:["popper",!n&&"popperInteractive",r&&"popperArrow"],tooltip:["tooltip",r&&"tooltipArrow",o&&"touch",`tooltipPlacement${Ye(s.split("-")[0])}`],arrow:["arrow"]};return To(i,tm,t)},sm=In(zi,{name:"MuiTooltip",slot:"Popper",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.popper,!n.disableInteractive&&t.popperInteractive,n.arrow&&t.popperArrow,!n.open&&t.popperClose]}})(({theme:e,ownerState:t,open:n})=>O({zIndex:(e.vars||e).zIndex.tooltip,pointerEvents:"none"},!t.disableInteractive&&{pointerEvents:"auto"},!n&&{pointerEvents:"none"},t.arrow&&{[`&[data-popper-placement*="bottom"] .${at.arrow}`]:{top:0,marginTop:"-0.71em","&::before":{transformOrigin:"0 100%"}},[`&[data-popper-placement*="top"] .${at.arrow}`]:{bottom:0,marginBottom:"-0.71em","&::before":{transformOrigin:"100% 0"}},[`&[data-popper-placement*="right"] .${at.arrow}`]:O({},t.isRtl?{right:0,marginRight:"-0.71em"}:{left:0,marginLeft:"-0.71em"},{height:"1em",width:"0.71em","&::before":{transformOrigin:"100% 100%"}}),[`&[data-popper-placement*="left"] .${at.arrow}`]:O({},t.isRtl?{left:0,marginLeft:"-0.71em"}:{right:0,marginRight:"-0.71em"},{height:"1em",width:"0.71em","&::before":{transformOrigin:"0 0"}})})),im=In("div",{name:"MuiTooltip",slot:"Tooltip",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.tooltip,n.touch&&t.touch,n.arrow&&t.tooltipArrow,t[`tooltipPlacement${Ye(n.placement.split("-")[0])}`]]}})(({theme:e,ownerState:t})=>O({backgroundColor:e.vars?e.vars.palette.Tooltip.bg:yi(e.palette.grey[700],.92),borderRadius:(e.vars||e).shape.borderRadius,color:(e.vars||e).palette.common.white,fontFamily:e.typography.fontFamily,padding:"4px 8px",fontSize:e.typography.pxToRem(11),maxWidth:300,margin:2,wordWrap:"break-word",fontWeight:e.typography.fontWeightMedium},t.arrow&&{position:"relative",margin:0},t.touch&&{padding:"8px 16px",fontSize:e.typography.pxToRem(14),lineHeight:`${om(16/14)}em`,fontWeight:e.typography.fontWeightRegular},{[`.${at.popper}[data-popper-placement*="left"] &`]:O({transformOrigin:"right center"},t.isRtl?O({marginLeft:"14px"},t.touch&&{marginLeft:"24px"}):O({marginRight:"14px"},t.touch&&{marginRight:"24px"})),[`.${at.popper}[data-popper-placement*="right"] &`]:O({transformOrigin:"left center"},t.isRtl?O({marginRight:"14px"},t.touch&&{marginRight:"24px"}):O({marginLeft:"14px"},t.touch&&{marginLeft:"24px"})),[`.${at.popper}[data-popper-placement*="top"] &`]:O({transformOrigin:"center bottom",marginBottom:"14px"},t.touch&&{marginBottom:"24px"}),[`.${at.popper}[data-popper-placement*="bottom"] &`]:O({transformOrigin:"center top",marginTop:"14px"},t.touch&&{marginTop:"24px"})})),lm=In("span",{name:"MuiTooltip",slot:"Arrow",overridesResolver:(e,t)=>t.arrow})(({theme:e})=>({overflow:"hidden",position:"absolute",width:"1em",height:"0.71em",boxSizing:"border-box",color:e.vars?e.vars.palette.Tooltip.bg:yi(e.palette.grey[700],.9),"&::before":{content:'""',margin:"auto",display:"block",width:"100%",height:"100%",backgroundColor:"currentColor",transform:"rotate(45deg)"}}));let Gn=!1;const ts=new On;let sn={x:0,y:0};function Un(e,t){return n=>{t&&t(n),e(n)}}const Li=M.forwardRef(function(t,n){var r,o,s,i,l,c,d,u,h,w,b,x,f,m,S,R,j,E,v;const P=Do({props:t,name:"MuiTooltip"}),{arrow:V=!1,children:U,components:C={},componentsProps:_={},describeChild:k=!1,disableFocusListener:A=!1,disableHoverListener:$=!1,disableInteractive:J=!1,disableTouchListener:Y=!1,enterDelay:F=100,enterNextDelay:te=0,enterTouchDelay:se=700,followCursor:oe=!1,id:y,leaveDelay:T=0,leaveTouchDelay:z=1500,onClose:L,onOpen:B,open:X,placement:q="bottom",PopperComponent:H,PopperProps:G={},slotProps:K={},slots:Z={},title:ue,TransitionComponent:I=es,TransitionProps:ye}=P,D=Ne(P,rm),xe=M.isValidElement(U)?U:a.jsx("span",{children:U}),Ge=Di(),lt=Ge.direction==="rtl",[Ee,An]=M.useState(),[Ue,Et]=M.useState(null),ct=M.useRef(!1),jt=J||oe,Ct=dn(),Tt=dn(),dt=dn(),Jt=dn(),[Dn,Yo]=di({controlled:X,default:!1,name:"Tooltip",state:"open"});let Ke=Dn;if(process.env.NODE_ENV!=="production"){const{current:ee}=M.useRef(X!==void 0);M.useEffect(()=>{Ee&&Ee.disabled&&!ee&&ue!==""&&Ee.tagName.toLowerCase()==="button"&&console.error(["MUI: You are providing a disabled `button` child to the Tooltip component.","A disabled element does not fire events.","Tooltip needs to listen to the child element's events to display the title.","","Add a simple wrapper element, such as a `span`."].join(` -`))},[ue,Ee,ee])}const kr=ci(y),Zt=M.useRef(),Bn=Zr(()=>{Zt.current!==void 0&&(document.body.style.WebkitUserSelect=Zt.current,Zt.current=void 0),Jt.clear()});M.useEffect(()=>Bn,[Bn]);const Wo=ee=>{ts.clear(),Gn=!0,Yo(!0),B&&!Ke&&B(ee)},Vn=Zr(ee=>{ts.start(800+T,()=>{Gn=!1}),Yo(!1),L&&Ke&&L(ee),Ct.start(Ge.transitions.duration.shortest,()=>{ct.current=!1})}),Sr=ee=>{ct.current&&ee.type!=="touchstart"||(Ee&&Ee.removeAttribute("title"),Tt.clear(),dt.clear(),F||Gn&&te?Tt.start(Gn?te:F,()=>{Wo(ee)}):Wo(ee))},Ko=ee=>{Tt.clear(),dt.start(T,()=>{Vn(ee)})},{isFocusVisibleRef:Jo,onBlur:rl,onFocus:ol,ref:al}=ui(),[,Zo]=M.useState(!1),Qo=ee=>{rl(ee),Jo.current===!1&&(Zo(!1),Ko(ee))},ea=ee=>{Ee||An(ee.currentTarget),ol(ee),Jo.current===!0&&(Zo(!0),Sr(ee))},ta=ee=>{ct.current=!0;const _e=xe.props;_e.onTouchStart&&_e.onTouchStart(ee)},na=Sr,ra=Ko,sl=ee=>{ta(ee),dt.clear(),Ct.clear(),Bn(),Zt.current=document.body.style.WebkitUserSelect,document.body.style.WebkitUserSelect="none",Jt.start(se,()=>{document.body.style.WebkitUserSelect=Zt.current,Sr(ee)})},il=ee=>{xe.props.onTouchEnd&&xe.props.onTouchEnd(ee),Bn(),dt.start(z,()=>{Vn(ee)})};M.useEffect(()=>{if(!Ke)return;function ee(_e){(_e.key==="Escape"||_e.key==="Esc")&&Vn(_e)}return document.addEventListener("keydown",ee),()=>{document.removeEventListener("keydown",ee)}},[Vn,Ke]);const ll=yt(xe.ref,al,An,n);!ue&&ue!==0&&(Ke=!1);const Er=M.useRef(),cl=ee=>{const _e=xe.props;_e.onMouseMove&&_e.onMouseMove(ee),sn={x:ee.clientX,y:ee.clientY},Er.current&&Er.current.update()},Qt={},jr=typeof ue=="string";k?(Qt.title=!Ke&&jr&&!$?ue:null,Qt["aria-describedby"]=Ke?kr:null):(Qt["aria-label"]=jr?ue:null,Qt["aria-labelledby"]=Ke&&!jr?kr:null);const Ae=O({},Qt,D,xe.props,{className:ot(D.className,xe.props.className),onTouchStart:ta,ref:ll},oe?{onMouseMove:cl}:{});process.env.NODE_ENV!=="production"&&(Ae["data-mui-internal-clone-element"]=!0,M.useEffect(()=>{Ee&&!Ee.getAttribute("data-mui-internal-clone-element")&&console.error(["MUI: The `children` component of the Tooltip is not forwarding its props correctly.","Please make sure that props are spread on the same element that the ref is applied to."].join(` -`))},[Ee]));const en={};Y||(Ae.onTouchStart=sl,Ae.onTouchEnd=il),$||(Ae.onMouseOver=Un(na,Ae.onMouseOver),Ae.onMouseLeave=Un(ra,Ae.onMouseLeave),jt||(en.onMouseOver=na,en.onMouseLeave=ra)),A||(Ae.onFocus=Un(ea,Ae.onFocus),Ae.onBlur=Un(Qo,Ae.onBlur),jt||(en.onFocus=ea,en.onBlur=Qo)),process.env.NODE_ENV!=="production"&&xe.props.title&&console.error(["MUI: You have provided a `title` prop to the child of .",`Remove this title prop \`${xe.props.title}\` or the Tooltip component.`].join(` -`));const dl=M.useMemo(()=>{var ee;let _e=[{name:"arrow",enabled:!!Ue,options:{element:Ue,padding:4}}];return(ee=G.popperOptions)!=null&&ee.modifiers&&(_e=_e.concat(G.popperOptions.modifiers)),O({},G.popperOptions,{modifiers:_e})},[Ue,G]),tn=O({},P,{isRtl:lt,arrow:V,disableInteractive:jt,placement:q,PopperComponentProp:H,touch:ct.current}),Cr=am(tn),oa=(r=(o=Z.popper)!=null?o:C.Popper)!=null?r:sm,aa=(s=(i=(l=Z.transition)!=null?l:C.Transition)!=null?i:I)!=null?s:es,sa=(c=(d=Z.tooltip)!=null?d:C.Tooltip)!=null?c:im,ia=(u=(h=Z.arrow)!=null?h:C.Arrow)!=null?u:lm,ul=un(oa,O({},G,(w=K.popper)!=null?w:_.popper,{className:ot(Cr.popper,G==null?void 0:G.className,(b=(x=K.popper)!=null?x:_.popper)==null?void 0:b.className)}),tn),pl=un(aa,O({},ye,(f=K.transition)!=null?f:_.transition),tn),wl=un(sa,O({},(m=K.tooltip)!=null?m:_.tooltip,{className:ot(Cr.tooltip,(S=(R=K.tooltip)!=null?R:_.tooltip)==null?void 0:S.className)}),tn),fl=un(ia,O({},(j=K.arrow)!=null?j:_.arrow,{className:ot(Cr.arrow,(E=(v=K.arrow)!=null?v:_.arrow)==null?void 0:E.className)}),tn);return a.jsxs(M.Fragment,{children:[M.cloneElement(xe,Ae),a.jsx(oa,O({as:H??zi,placement:q,anchorEl:oe?{getBoundingClientRect:()=>({top:sn.y,left:sn.x,right:sn.x,bottom:sn.y,width:0,height:0})}:Ee,popperRef:Er,open:Ee?Ke:!1,id:kr,transition:!0},en,ul,{popperOptions:dl,children:({TransitionProps:ee})=>a.jsx(aa,O({timeout:Ge.transitions.duration.shorter},ee,pl,{children:a.jsxs(sa,O({},wl,{children:[ue,V?a.jsx(ia,O({},fl,{ref:Et})):null]}))}))}))]})});process.env.NODE_ENV!=="production"&&(Li.propTypes={arrow:p.bool,children:si.isRequired,classes:p.object,className:p.string,components:p.shape({Arrow:p.elementType,Popper:p.elementType,Tooltip:p.elementType,Transition:p.elementType}),componentsProps:p.shape({arrow:p.object,popper:p.object,tooltip:p.object,transition:p.object}),describeChild:p.bool,disableFocusListener:p.bool,disableHoverListener:p.bool,disableInteractive:p.bool,disableTouchListener:p.bool,enterDelay:p.number,enterNextDelay:p.number,enterTouchDelay:p.number,followCursor:p.bool,id:p.string,leaveDelay:p.number,leaveTouchDelay:p.number,onClose:p.func,onOpen:p.func,open:p.bool,placement:p.oneOf(["bottom-end","bottom-start","bottom","left-end","left-start","left","right-end","right-start","right","top-end","top-start","top"]),PopperComponent:p.elementType,PopperProps:p.object,slotProps:p.shape({arrow:p.object,popper:p.object,tooltip:p.object,transition:p.object}),slots:p.shape({arrow:p.elementType,popper:p.elementType,tooltip:p.elementType,transition:p.elementType}),sx:p.oneOfType([p.arrayOf(p.oneOfType([p.func,p.object,p.bool])),p.func,p.object]),title:p.node,TransitionComponent:p.elementType,TransitionProps:p.object});const cm=Li;function ns(e,t,n){return e?a.jsx(Me.ListItemIcon,{className:`papi-menu-icon-${n?"leading":"trailing"}`,children:a.jsx("img",{src:e,alt:`${n?"Leading":"Trailing"} icon for ${t}`})}):void 0}function Xo(e){const{onClick:t,label:n,tooltip:r,allowForLeadingIcons:o=!0,iconPathBefore:s=void 0,iconPathAfter:i=void 0,hasAutoFocus:l=!1,className:c,isDisabled:d=!1,isDense:u=!0,isSubMenuParent:h=!1,hasDisabledGutters:w=!1,hasDivider:b=!1,focusVisibleClassName:x,id:f,children:m}=e,S=a.jsx(Me.MenuItem,{sx:{lineHeight:.8},autoFocus:l,className:c,disabled:d,dense:u,disableGutters:w,divider:b,focusVisibleClassName:x,onClick:t,id:f,children:n?a.jsxs(a.Fragment,{children:[ns(s,n,!0),a.jsx(Me.ListItemText,{primary:n,inset:!s&&o}),h?a.jsx(Me.ListItemIcon,{className:"papi-menu-icon-trailing",children:a.jsx(ki,{})}):ns(i,n,!1)]}):m});return r?a.jsx(cm,{title:r,placement:"right",children:a.jsx("div",{children:S})}):S}function Fi(e){return Object.entries(e.groups).map(([n,r])=>({id:n,group:r}))}function dm(e){const[t,n]=g.useState(void 0),{parentMenuItem:r,parentItemProps:o,menuDefinition:s}=e,i=d=>{n(d.currentTarget)},l=()=>{n(void 0)},c=()=>{let d=Fi(s).filter(u=>"menuItem"in u.group);if(!(r!=null&&r.id))throw new Error("A valid parent menu item is required for submenus.");return d=d.filter(u=>"menuItem"in u.group&&u.group.menuItem===r.id),a.jsx(Gi,{...e,includedGroups:d})};return a.jsxs(a.Fragment,{children:[a.jsx(Xo,{onClick:i,...o,isSubMenuParent:!0}),a.jsx(Me.Menu,{anchorEl:t,open:!!t,onClose:l,anchorOrigin:{vertical:"top",horizontal:"right"},transformOrigin:{vertical:"top",horizontal:"left"},children:c()},r.id)]})}const um=(e,t)=>t.filter(o=>o.group===e).sort((o,s)=>(o.order||0)-(s.order||0));function Gi(e){const{menuDefinition:t,onClick:n,commandHandler:r,includedGroups:o}=e,{items:s,allowForLeadingIcons:i}=g.useMemo(()=>{const u=o&&o.length>0?o:Fi(t).filter(x=>!("menuItem"in x.group)),h=Object.values(u).sort((x,f)=>(x.group.order||0)-(f.group.order||0)),w=[];h.forEach(x=>{um(x.id,t.items).forEach(f=>w.push({item:f,isLastItemInGroup:!1})),w.length>0&&(w[w.length-1].isLastItemInGroup=!0)}),w.length>0&&(w[w.length-1].isLastItemInGroup=!1);const b=w.some(x=>"iconPathBefore"in x.item&&x.item.iconPathBefore);return{items:w,allowForLeadingIcons:b}},[o,t]),l=({item:u,isLastItemInGroup:h})=>({className:"papi-menu-item",label:u.label,tooltip:u.tooltip,iconPathBefore:"iconPathBefore"in u?u.iconPathBefore:void 0,iconPathAfter:"iconPathAfter"in u?u.iconPathAfter:void 0,hasDivider:h,allowForLeadingIcons:i}),[c]=s;if(!c)return a.jsx("div",{});const d=c.item.group;return a.jsx("div",{role:"menu","aria-label":d,children:s.map((u,h)=>{const{item:w}=u,b=l(u);if("command"in w){const x=w.group+h;return a.jsx(Xo,{onClick:f=>{n==null||n(f),r(w)},...b},x)}return a.jsx(dm,{parentMenuItem:w,parentItemProps:b,...e},d+w.id)})},d)}function pm(e){const{menuDefinition:t,columnId:n}=e;let s=Object.entries(t.groups).map(([i,l])=>({id:i,group:l})).filter(i=>"column"in i.group);return n&&"columns"in t&&t.columns[n]&&(s=s.filter(i=>"column"in i.group&&i.group.column===n)),a.jsx(Gi,{...e,includedGroups:s})}function wm({commandHandler:e,menuDefinition:t,id:n,metadata:r,onClick:o,className:s}){return a.jsxs(Me.Grid,{id:n,item:!0,xs:"auto",role:"menu","aria-label":n,className:`papi-menu-column ${s??""}`,children:[a.jsx("h3",{"aria-label":r.label,className:`papi-menu-column-header ${s??""}`,children:r.label}),a.jsx(Me.List,{id:n,dense:!0,className:s??"",children:a.jsx(pm,{commandHandler:e,menuDefinition:t,columnId:n,onClick:o})})]})}function Ui({commandHandler:e,className:t,multiColumnMenu:n,id:r}){const{columns:o}=n,s=g.useMemo(()=>{const i=new Map;return Object.getOwnPropertyNames(o).forEach(l=>{if(l==="isExtensible")return;const c=l,d=o[c];typeof d=="object"&&typeof d.order=="number"&&!Number.isNaN(d.order)?i.set(d.order,{id:c,metadata:d}):console.warn(`Property ${l} (${typeof d}) on menu ${r} is not a valid column and is being ignored. This might indicate data corruption`)}),Array.from(i.values()).sort((l,c)=>(l.metadata.order||0)-(c.metadata.order||0))},[o,r]);return a.jsx(Me.Grid,{container:!0,spacing:0,className:`papi-multi-column-menu ${t??""}`,columns:s.length,role:"menu","aria-label":"GridMenu",id:r,children:s.map((i,l)=>a.jsx(wm,{commandHandler:e,menuDefinition:n,...i,className:t},l))})}function fm(e){return{preserveValue:!0,...e}}const nr=(e,t,n={})=>{const r=g.useRef(t);r.current=t;const o=g.useRef(n);o.current=fm(o.current);const[s,i]=g.useState(()=>r.current),[l,c]=g.useState(!0);return g.useEffect(()=>{let d=!0;return c(!!e),(async()=>{if(e){const u=await e();d&&(i(()=>u),c(!1))}})(),()=>{d=!1,o.current.preserveValue||i(()=>r.current)}},[e]),[s,l]},mm=Ni(a.jsx("path",{d:"M3 18h18v-2H3zm0-5h18v-2H3zm0-7v2h18V6z"}),"Menu");function qi({menuProvider:e,normalMenu:t,fullMenu:n,commandHandler:r,containerRef:o,className:s,ariaLabelPrefix:i,children:l}){const[c,d]=g.useState(!1),[u,h]=g.useState(!1),w=g.useCallback(()=>{c&&d(!1),h(!1)},[c]),b=g.useCallback(E=>{E.stopPropagation(),d(v=>{const P=!v;return P&&E.shiftKey?h(!0):P||h(!1),P})},[]),x=g.useCallback(E=>(w(),r(E)),[r,w]),[f,m]=g.useState({top:1,left:1});g.useEffect(()=>{if(c){const E=o==null?void 0:o.current;if(E){const v=E.getBoundingClientRect(),P=window.scrollY,V=window.scrollX,U=v.top+P+E.clientHeight,C=v.left+V;m({top:U,left:C})}}},[c,o]);const[S]=nr(g.useCallback(async()=>(e==null?void 0:e(!1))??t,[e,t,c]),t),[R]=nr(g.useCallback(async()=>(e==null?void 0:e(!0))??n??S,[e,n,S,c]),n??S),j=u&&R?R:S;return a.jsxs(a.Fragment,{children:[a.jsx(Me.IconButton,{sx:{paddingTop:0,paddingBottom:0},edge:"start",className:`papi-menuButton ${s??""}`,color:"inherit","aria-label":`${i??""} menu button`,onClick:b,children:l??a.jsx(mm,{})}),a.jsx(Me.Drawer,{className:`papi-menu-drawer ${s??""}`,anchor:"left",variant:"temporary",open:c,onClose:w,PaperProps:{className:"papi-menu-drawer-paper",style:{top:f.top,left:f.left}},children:j?a.jsx(Ui,{className:s,id:`${i??""} main menu`,commandHandler:x,multiColumnMenu:j}):void 0})]})}function hm({id:e,label:t,isDisabled:n=!1,tooltip:r,isTooltipSuppressed:o=!1,adjustMarginToAlignToEdge:s=!1,size:i="medium",className:l,onClick:c,children:d}){return a.jsx(Me.IconButton,{id:e,disabled:n,edge:s,size:i,"aria-label":t,title:o?void 0:r??t,className:`papi-icon-button ${l??""}`,onClick:c,children:d})}const Kt=g.forwardRef(({className:e,...t},n)=>a.jsx(Q.LoaderCircle,{size:35,className:N("tw-animate-spin",e),...t,ref:n}));Kt.displayName="Spinner";function gm({id:e,isDisabled:t=!1,hasError:n=!1,isFullWidth:r=!1,helperText:o,label:s,placeholder:i,isRequired:l=!1,className:c,defaultValue:d,value:u,onChange:h,onFocus:w,onBlur:b}){return a.jsxs("div",{className:N("tw-inline-grid tw-items-center tw-gap-1.5",{"tw-w-full":r}),children:[a.jsx(qe,{htmlFor:e,className:N({"tw-text-red-600":n,"tw-hidden":!s}),children:`${s}${l?"*":""}`}),a.jsx(St,{id:e,disabled:t,placeholder:i,required:l,className:N(c,{"tw-border-red-600":n}),defaultValue:d,value:u,onChange:h,onFocus:w,onBlur:b}),a.jsx("p",{className:N({"tw-hidden":!o}),children:o})]})}function bm({menuProvider:e,commandHandler:t,className:n,id:r,children:o}){const s=g.useRef(void 0);return a.jsx("div",{ref:s,style:{position:"relative"},children:a.jsx(Me.AppBar,{position:"static",id:r,children:a.jsxs(Me.Toolbar,{className:N("tw-bg-muted tw-text-muted-foreground",n),variant:"dense",children:[e?a.jsx(qi,{commandHandler:t,containerRef:s,menuProvider:e}):void 0,o?a.jsx("div",{className:"papi-toolbar-children",children:o}):void 0]})})})}const vm=Xt.cva("tw-relative tw-w-full tw-rounded-lg tw-border tw-p-4 [&>svg~*]:tw-pl-7 [&>svg+div]:tw-translate-y-[-3px] [&>svg]:tw-absolute [&>svg]:tw-left-4 [&>svg]:tw-top-4 [&>svg]:tw-text-foreground",{variants:{variant:{default:"tw-bg-background tw-text-foreground",destructive:"tw-border-destructive/50 tw-text-destructive dark:tw-border-destructive [&>svg]:tw-text-destructive"}},defaultVariants:{variant:"default"}}),Hi=g.forwardRef(({className:e,variant:t,...n},r)=>a.jsx("div",{ref:r,role:"alert",className:N(vm({variant:t}),e),...n}));Hi.displayName="Alert";const Xi=g.forwardRef(({className:e,...t},n)=>a.jsxs("h5",{ref:n,className:N("tw-mb-1 tw-font-medium tw-leading-none tw-tracking-tight",e),...t,children:[t.children," "]}));Xi.displayName="AlertTitle";const Yi=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,className:N("tw-text-sm [&_p]:tw-leading-relaxed",e),...t}));Yi.displayName="AlertDescription";function xm({...e}){return a.jsx(os.Toaster,{className:"tw-toaster tw-group",toastOptions:{classNames:{toast:"group toast group-[.toaster]:bg-background group-[.toaster]:text-foreground group-[.toaster]:border-border group-[.toaster]:shadow-lg",description:"group-[.toast]:text-muted-foreground",actionButton:"group-[.toast]:bg-primary group-[.toast]:text-primary-foreground",cancelButton:"group-[.toast]:bg-muted group-[.toast]:text-muted-foreground"}},...e})}const Wi=g.forwardRef(({className:e,...t},n)=>a.jsxs(cn.Root,{ref:n,className:N("pr-twp tw-relative tw-flex tw-w-full tw-touch-none tw-select-none tw-items-center",e),...t,children:[a.jsx(cn.Track,{className:"tw-relative tw-h-2 tw-w-full tw-grow tw-overflow-hidden tw-rounded-full tw-bg-secondary",children:a.jsx(cn.Range,{className:"tw-absolute tw-h-full tw-bg-primary"})}),a.jsx(cn.Thumb,{className:"tw-block tw-h-5 tw-w-5 tw-rounded-full tw-border-2 tw-border-primary tw-bg-background tw-ring-offset-background tw-transition-colors focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50"})]}));Wi.displayName=cn.Root.displayName;const Ki=g.forwardRef(({className:e,...t},n)=>a.jsx(qr.Root,{className:N("tw-peer pr-twp tw-inline-flex tw-h-6 tw-w-11 tw-shrink-0 tw-cursor-pointer tw-items-center tw-rounded-full tw-border-2 tw-border-transparent tw-transition-colors focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 focus-visible:tw-ring-offset-background disabled:tw-cursor-not-allowed disabled:tw-opacity-50 data-[state=checked]:tw-bg-primary data-[state=unchecked]:tw-bg-input",e),...t,ref:n,children:a.jsx(qr.Thumb,{className:N("pr-twp tw-pointer-events-none tw-block tw-h-5 tw-w-5 tw-rounded-full tw-bg-background tw-shadow-lg tw-ring-0 tw-transition-transform data-[state=checked]:tw-translate-x-5 data-[state=unchecked]:tw-translate-x-0")})}));Ki.displayName=qr.Root.displayName;const ym=Oe.Root,Ji=g.forwardRef(({className:e,...t},n)=>a.jsx(Oe.List,{ref:n,className:N("tw-inline-flex tw-h-10 tw-items-center tw-justify-center tw-rounded-md tw-bg-muted tw-p-1 tw-text-muted-foreground",e),...t}));Ji.displayName=Oe.List.displayName;const Zi=g.forwardRef(({className:e,...t},n)=>a.jsx(Oe.Trigger,{ref:n,className:N("tw-inline-flex tw-items-center tw-justify-center tw-whitespace-nowrap tw-rounded-sm tw-px-3 tw-py-1.5 tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-all hover:tw-text-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50 data-[state=active]:tw-bg-background data-[state=active]:tw-text-foreground data-[state=active]:tw-shadow-sm",e),...t}));Zi.displayName=Oe.Trigger.displayName;const Qi=g.forwardRef(({className:e,...t},n)=>a.jsx(Oe.Content,{ref:n,className:N("tw-mt-2 tw-ring-offset-background focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2",e),...t}));Qi.displayName=Oe.Content.displayName;function Nm({isInstalling:e,handleClick:t,buttonText:n,className:r,...o}){return a.jsx(fe,{className:N("tw-h-8 tw-rounded-md tw-text-white tw-transition tw-duration-300 tw-ease-in-out hover:tw-bg-blue-700",{"tw-cursor-not-allowed tw-bg-blue-700":e,"tw-bg-blue-600":!e,"tw-bg-white tw-text-blue-600 hover:tw-text-white":!n,"tw-w-20":n},r),onClick:t,...o,children:e?a.jsx(Kt,{size:15}):a.jsxs(a.Fragment,{children:[a.jsx(Q.Download,{size:25,className:N("tw-h-4 tw-w-4",{"tw-mr-1":n})}),n]})})}function km({isEnabling:e,handleClick:t,className:n,...r}){return a.jsx(fe,{className:N("tw-h-8 tw-rounded-md tw-bg-blue-600 tw-px-4 tw-text-white tw-transition tw-duration-300 tw-ease-in-out hover:tw-bg-blue-700",{"tw-cursor-not-allowed tw-bg-blue-700":e},n),onClick:t,...r,children:e?a.jsxs(a.Fragment,{children:[a.jsx(Kt,{size:15,className:"tw-mr-1 tw-text-white"}),"Enabling..."]}):"Enable"})}function Sm({isDisabling:e,handleClick:t,className:n,...r}){return a.jsx(fe,{className:N("tw-h-8 tw-rounded-md tw-bg-gray-300 tw-text-black tw-transition tw-duration-300 tw-ease-in-out hover:tw-bg-gray-400",{"tw-cursor-not-allowed tw-bg-gray-400":e},n),onClick:t,...r,children:e?a.jsxs(a.Fragment,{children:[a.jsx(Kt,{size:15,className:"tw-mr-1 tw-text-black"}),"Disabling..."]}):"Disable"})}function Em({isUpdating:e,handleClick:t,className:n,...r}){return a.jsx(fe,{className:N("tw-h-8 tw-rounded-md tw-bg-blue-600 tw-px-4 tw-text-white tw-transition tw-duration-300 tw-ease-in-out hover:tw-bg-blue-700 hover:tw-text-white",{"tw-cursor-not-allowed tw-bg-blue-700":e},n),onClick:t,...r,children:e?a.jsxs(a.Fragment,{children:[a.jsx(Kt,{size:15,className:"tw-mr-1 tw-text-white"}),"Updating..."]}):"Update"})}function jm({id:e,markdown:t,className:n,anchorTarget:r}){const o=g.useMemo(()=>({overrides:{a:{props:{target:r}}}}),[r]);return a.jsx("div",{id:e,className:N("pr-twp tw-prose",n),children:a.jsx(Rl,{options:o,children:t})})}const el=g.forwardRef((e,t)=>a.jsxs(fe,{ref:t,className:"tw-rounded-md tw-border tw-border-dashed tw-border-gray-400 tw-bg-white tw-px-4 tw-py-2 tw-text-black tw-transition tw-duration-300 tw-ease-in-out hover:tw-border-blue-600 hover:tw-bg-white hover:tw-text-blue-600",...e,children:[a.jsx(Q.Filter,{size:16,className:"tw-mr-2 tw-h-4 tw-w-4 tw-text-gray-700 hover:tw-text-blue-600"}),"Filter",a.jsx(Q.ChevronDown,{size:16,className:"tw-ml-2 tw-h-4 tw-w-4 tw-text-gray-700 hover:tw-text-blue-600"})]}));var tl=(e=>(e[e.Check=0]="Check",e[e.Radio=1]="Radio",e))(tl||{});function Cm({id:e,groups:t}){return a.jsx("div",{id:e,children:a.jsxs(or,{children:[a.jsx(lo,{asChild:!0,children:a.jsx(el,{})}),a.jsx(En,{children:t.map(n=>a.jsxs("div",{children:[a.jsx(Wt,{children:n.label}),a.jsx(fs,{children:n.items.map(r=>a.jsx("div",{children:r.itemType===0?a.jsx(ar,{onClick:r.onClick,children:r.label}):a.jsx(uo,{onClick:r.onClick,value:r.label,children:r.label})},r.label))}),a.jsx(jn,{})]},n.label))})]})})}function Tm({id:e,message:t}){return a.jsx("div",{id:e,className:"tw-mb-20 tw-mt-20 tw-flex tw-items-center tw-justify-center",children:a.jsx("div",{className:"tw-w-3/4 tw-rounded-lg tw-bg-gray-100 tw-p-8 tw-text-center",children:a.jsx("p",{className:"tw-text-lg tw-text-gray-800",children:t})})})}function Rm({id:e,category:t,downloads:n,languages:r,moreInfoUrl:o}){const s=new W.NumberFormat("en",{notation:"compact",compactDisplay:"short"}).format(Object.values(n).reduce((l,c)=>l+c,0)),i=()=>{window.scrollTo(0,document.body.scrollHeight)};return a.jsxs("div",{id:e,className:"tw-flex tw-flex-wrap tw-items-start tw-space-x-4 tw-border-b tw-border-t tw-bg-white tw-pb-4 tw-pt-4",children:[a.jsxs("div",{className:"tw-flex tw-flex-col tw-items-center",children:[a.jsx("div",{className:"tw-flex tw-items-center tw-rounded-md tw-bg-gray-100 tw-px-2 tw-py-1",children:a.jsx("span",{className:"tw-text-xs tw-font-semibold tw-text-gray-700",children:t})}),a.jsx("span",{className:"tw-text-xs tw-text-gray-500",children:"CATEGORY"})]}),a.jsx("div",{className:"tw-mx-2 tw-h-10 tw-border-l tw-border-gray-300"}),a.jsxs("div",{className:"tw-flex tw-flex-col tw-items-center",children:[a.jsxs("div",{className:"tw-flex tw-items-center tw-rounded-md tw-bg-gray-100 tw-px-2 tw-py-1",children:[a.jsx(Q.User,{className:"tw-mr-1 tw-h-4 tw-w-4"}),a.jsx("span",{className:"tw-text-xs tw-font-semibold tw-text-gray-700",children:s})]}),a.jsx("span",{className:"tw-text-xs tw-text-gray-500",children:"USERS"})]}),a.jsx("div",{className:"tw-mx-2 tw-h-10 tw-border-l tw-border-gray-300"}),a.jsxs("div",{className:"tw-flex tw-flex-col tw-items-center",children:[a.jsx("div",{className:"tw-flex tw-items-center",children:r.slice(0,3).map(l=>a.jsx("span",{className:"tw-ml-1 tw-rounded-md tw-bg-gray-100 tw-px-2 tw-py-1 tw-text-xs tw-font-semibold tw-text-gray-700",children:l.toUpperCase()},l))}),r.length>3&&a.jsxs("button",{type:"button",onClick:()=>i(),className:"tw-text-xs tw-text-gray-500 tw-underline",children:["+",r.length-3," more languages"]})]}),a.jsx("div",{className:"tw-mx-2 tw-h-10 tw-border-l tw-border-gray-300"}),a.jsxs("div",{className:"tw-ml-auto tw-flex tw-flex-col tw-space-y-2",children:[a.jsxs("a",{href:o,target:"_blank",rel:"noreferrer",className:"tw-flex tw-items-center tw-text-xs tw-font-semibold tw-text-gray-500 tw-underline",children:["Website",a.jsx(Q.Link,{className:"tw-ml-1 tw-inline tw-h-4 tw-w-4"})]}),a.jsxs("a",{href:"https://example.com",target:"_blank",rel:"noreferrer",className:"tw-flex tw-items-center tw-text-xs tw-font-semibold tw-text-gray-500 tw-underline",children:["Support",a.jsx(Q.CircleHelp,{className:"tw-ml-1 tw-inline tw-h-4 tw-w-4"})]})]})]})}function nl({id:e,versionHistory:t}){const[n,r]=g.useState(!1),o=new Date;function s(l){const c=new Date(l),d=new Date(o.getTime()-c.getTime()),u=d.getUTCFullYear()-1970,h=d.getUTCMonth(),w=d.getUTCDate()-1;let b="";return u>0?b=`${u.toString()} year${u===1?"":"s"} ago`:h>0?b=`${h.toString()} month${h===1?"":"s"} ago`:w===0?b="today":b=`${w.toString()} day${w===1?"":"s"} ago`,b}const i=Object.entries(t).sort((l,c)=>c[0].localeCompare(l[0]));return a.jsxs("div",{id:e,children:[a.jsx("h3",{className:"tw-text-md tw-font-semibold",children:"What`s New"}),a.jsx("ul",{className:"tw-list-disc tw-pl-5 tw-pr-4 tw-text-xs tw-text-gray-600",children:(n?i:i.slice(0,5)).map(l=>a.jsxs("div",{className:"tw-mt-3 tw-flex tw-justify-between",children:[a.jsx("div",{className:"tw-text-gray-600",children:a.jsx("li",{className:"tw-prose tw-text-xs",children:a.jsx("span",{children:l[1].description})})}),a.jsxs("div",{className:"tw-justify-end tw-text-right",children:[a.jsxs("div",{children:["Version ",l[0]]}),a.jsx("div",{children:s(l[1].date)})]})]},l[0]))}),i.length>5&&a.jsx("button",{type:"button",onClick:()=>r(!n),className:"tw-text-xs tw-text-gray-500 tw-underline",children:n?"Show Less Version History":"Show All Version History"})]})}function Om({id:e,publisherDisplayName:t,fileSize:n,locales:r,versionHistory:o}){const s=g.useMemo(()=>W.formatBytes(n),[n]),l=(c=>{const d=new Intl.DisplayNames(navigator.language,{type:"language"});return c.map(u=>d.of(u))})(r);return a.jsx("div",{id:e,className:"tw-border-t tw-pb-4 tw-pt-4",children:a.jsxs("div",{className:"tw-md:flex-row tw-md:space-x-8 tw-flex tw-flex-col tw-space-x-0",children:[a.jsx(nl,{versionHistory:o}),a.jsx("div",{className:"tw-md:border-t-0 tw-md:border-l tw-md-h-auto tw-md-ml-8 tw-mt-4 tw-border-t tw-border-gray-300"}),a.jsxs("div",{className:"tw-md:mt-0 tw-mt-4 tw-flex-1 tw-space-y-3",children:[a.jsx("h2",{className:"tw-text-md tw-font-semibold",children:"Information"}),a.jsxs("div",{className:"tw-flex tw-items-start tw-justify-between tw-pr-4 tw-text-xs tw-text-gray-600",children:[a.jsxs("p",{className:"tw-flex tw-flex-col tw-justify-start",children:[a.jsx("span",{className:"tw-mb-2",children:"Publisher"}),a.jsx("span",{className:"tw-font-semibold",children:t}),a.jsx("span",{className:"tw-mb-2 tw-mt-4",children:"Size"}),a.jsx("span",{className:"tw-font-semibold",children:s})]}),a.jsx("div",{className:"tw-flex tw-w-3/4 tw-items-center tw-justify-between tw-text-xs tw-text-gray-600",children:a.jsxs("p",{className:"tw-flex tw-flex-col tw-justify-start",children:[a.jsx("span",{className:"tw-mb-2",children:"Languages"}),a.jsx("span",{className:"tw-font-semibold",children:l.join(", ")})]})})]})]})]})})}const _m=(e,t)=>{g.useEffect(()=>{if(!e)return()=>{};const n=e(t);return()=>{n()}},[e,t])},Fr=()=>!1,Pm=(e,t)=>{const[n]=nr(g.useCallback(async()=>{if(!e)return Fr;const r=await Promise.resolve(e(t));return async()=>r()},[t,e]),Fr,{preserveValue:!1});g.useEffect(()=>()=>{n!==Fr&&n()},[n])};Object.defineProperty(exports,"sonner",{enumerable:!0,get:()=>os.toast});exports.Alert=Hi;exports.AlertDescription=Yi;exports.AlertTitle=Xi;exports.BOOK_SELECTOR_STRING_KEYS=mc;exports.BookChapterControl=oc;exports.BookSelectionMode=Cs;exports.BookSelector=hc;exports.Button=fe;exports.Card=xo;exports.CardContent=So;exports.CardDescription=ko;exports.CardFooter=Qs;exports.CardHeader=yo;exports.CardTitle=No;exports.ChapterRangeSelector=js;exports.Checkbox=sr;exports.Checklist=vd;exports.ComboBox=Wn;exports.DataTable=Is;exports.DisableButton=Sm;exports.DropdownMenu=or;exports.DropdownMenuCheckboxItem=ar;exports.DropdownMenuContent=En;exports.DropdownMenuGroup=fs;exports.DropdownMenuItem=co;exports.DropdownMenuItemType=tl;exports.DropdownMenuLabel=Wt;exports.DropdownMenuPortal=ql;exports.DropdownMenuRadioGroup=Xl;exports.DropdownMenuRadioItem=uo;exports.DropdownMenuSeparator=jn;exports.DropdownMenuShortcut=gs;exports.DropdownMenuSub=Hl;exports.DropdownMenuSubContent=hs;exports.DropdownMenuSubTrigger=ms;exports.DropdownMenuTrigger=lo;exports.EnableButton=km;exports.FilterButton=el;exports.FilterDropdown=Cm;exports.Footer=Om;exports.GridMenu=Ui;exports.HamburgerMenuButton=qi;exports.INVENTORY_STRING_KEYS=Ec;exports.IconButton=hm;exports.Input=St;exports.InstallButton=Nm;exports.Inventory=Tc;exports.Label=qe;exports.MarkdownRenderer=jm;exports.MenuItem=Xo;exports.MoreInfo=Rm;exports.NavigationContentSearch=Rc;exports.NoExtensionsFound=Tm;exports.RadioGroup=po;exports.RadioGroupItem=Yn;exports.ScriptureResultsViewer=wd;exports.ScrollGroupSelector=fd;exports.SearchBar=ho;exports.Select=Dt;exports.SelectContent=vt;exports.SelectGroup=Ts;exports.SelectItem=De;exports.SelectLabel=Rs;exports.SelectScrollDownButton=fo;exports.SelectScrollUpButton=wo;exports.SelectSeparator=Os;exports.SelectTrigger=bt;exports.SelectValue=Bt;exports.Separator=lr;exports.SettingsCard=bd;exports.SettingsList=md;exports.SettingsListHeader=gd;exports.SettingsListItem=hd;exports.SettingsSidebar=Js;exports.SettingsSidebarContentSearch=ad;exports.Slider=Wi;exports.Sonner=xm;exports.Spinner=Kt;exports.Switch=Ki;exports.Table=Cn;exports.TableBody=Rn;exports.TableCaption=Ps;exports.TableCell=xt;exports.TableFooter=_s;exports.TableHead=Vt;exports.TableHeader=Tn;exports.TableRow=Ze;exports.Tabs=ym;exports.TabsContent=Qi;exports.TabsList=Ji;exports.TabsTrigger=Zi;exports.TextField=gm;exports.ToggleGroup=mo;exports.ToggleGroupItem=fn;exports.Toolbar=bm;exports.UpdateButton=Em;exports.VersionHistory=nl;exports.VerticalTabs=go;exports.VerticalTabsContent=vo;exports.VerticalTabsList=bo;exports.VerticalTabsTrigger=Vs;exports.buttonVariants=bs;exports.cn=N;exports.getBookNumFromId=$s;exports.getLinesFromUSFM=Ms;exports.getNumberFromUSFM=Hr;exports.getStatusForItem=As;exports.inventoryCountColumn=kc;exports.inventoryItemColumn=yc;exports.inventoryStatusColumn=Sc;exports.useEvent=_m;exports.useEventAsync=Pm;exports.usePromise=nr;function Im(e,t="top"){if(!e||typeof document>"u")return;const n=document.head||document.querySelector("head"),r=n.querySelector(":first-child"),o=document.createElement("style");o.appendChild(document.createTextNode(e)),t==="top"&&r?n.insertBefore(o,r):n.appendChild(o)}Im(`*, ::before, ::after { +} });`:zt(12,m?` (${m})`:"",JSON.stringify(f.main)));return _a(f,"light",R,r),_a(f,"dark",j,r),f.contrastText||(f.contrastText=h(f.main)),f},b={dark:zr,light:Oa};return process.env.NODE_ENV!=="production"&&(b[t]||console.error(`MUI: The palette mode \`${t}\` is not supported.`)),Qe(O({common:O({},yn),mode:t,primary:w({color:s,name:"primary"}),secondary:w({color:i,name:"secondary",mainShade:"A400",lightShade:"A200",darkShade:"A700"}),error:w({color:l,name:"error"}),warning:w({color:u,name:"warning"}),info:w({color:c,name:"info"}),success:w({color:d,name:"success"}),grey:Ep,contrastThreshold:n,getContrastText:h,augmentColor:w,tonalOffset:r},b[t]),o)}const zp=["fontFamily","fontSize","fontWeightLight","fontWeightRegular","fontWeightMedium","fontWeightBold","htmlFontSize","allVariants","pxToRem"];function Lp(e){return Math.round(e*1e5)/1e5}const Pa={textTransform:"uppercase"},Ia='"Roboto", "Helvetica", "Arial", sans-serif';function Fp(e,t){const n=typeof t=="function"?t(e):t,{fontFamily:r=Ia,fontSize:o=14,fontWeightLight:s=300,fontWeightRegular:i=400,fontWeightMedium:l=500,fontWeightBold:c=700,htmlFontSize:d=16,allVariants:u,pxToRem:h}=n,w=Ne(n,zp);process.env.NODE_ENV!=="production"&&(typeof o!="number"&&console.error("MUI: `fontSize` is required to be a number."),typeof d!="number"&&console.error("MUI: `htmlFontSize` is required to be a number."));const b=o/14,x=h||(S=>`${S/d*b}rem`),f=(S,R,j,E,v)=>O({fontFamily:r,fontWeight:S,fontSize:x(R),lineHeight:j},r===Ia?{letterSpacing:`${Lp(E/R)}em`}:{},v,u),m={h1:f(s,96,1.167,-1.5),h2:f(s,60,1.2,-.5),h3:f(i,48,1.167,0),h4:f(i,34,1.235,.25),h5:f(i,24,1.334,0),h6:f(l,20,1.6,.15),subtitle1:f(i,16,1.75,.15),subtitle2:f(l,14,1.57,.1),body1:f(i,16,1.5,.15),body2:f(i,14,1.43,.15),button:f(l,14,1.75,.4,Pa),caption:f(i,12,1.66,.4),overline:f(i,12,2.66,1,Pa),inherit:{fontFamily:"inherit",fontWeight:"inherit",fontSize:"inherit",lineHeight:"inherit",letterSpacing:"inherit"}};return Qe(O({htmlFontSize:d,pxToRem:x,fontFamily:r,fontSize:o,fontWeightLight:s,fontWeightRegular:i,fontWeightMedium:l,fontWeightBold:c},m),w,{clone:!1})}const Gp=.2,Up=.14,qp=.12;function we(...e){return[`${e[0]}px ${e[1]}px ${e[2]}px ${e[3]}px rgba(0,0,0,${Gp})`,`${e[4]}px ${e[5]}px ${e[6]}px ${e[7]}px rgba(0,0,0,${Up})`,`${e[8]}px ${e[9]}px ${e[10]}px ${e[11]}px rgba(0,0,0,${qp})`].join(",")}const Hp=["none",we(0,2,1,-1,0,1,1,0,0,1,3,0),we(0,3,1,-2,0,2,2,0,0,1,5,0),we(0,3,3,-2,0,3,4,0,0,1,8,0),we(0,2,4,-1,0,4,5,0,0,1,10,0),we(0,3,5,-1,0,5,8,0,0,1,14,0),we(0,3,5,-1,0,6,10,0,0,1,18,0),we(0,4,5,-2,0,7,10,1,0,2,16,1),we(0,5,5,-3,0,8,10,1,0,3,14,2),we(0,5,6,-3,0,9,12,1,0,3,16,2),we(0,6,6,-3,0,10,14,1,0,4,18,3),we(0,6,7,-4,0,11,15,1,0,4,20,3),we(0,7,8,-4,0,12,17,2,0,5,22,4),we(0,7,8,-4,0,13,19,2,0,5,24,4),we(0,7,9,-4,0,14,21,2,0,5,26,4),we(0,8,9,-5,0,15,22,2,0,6,28,5),we(0,8,10,-5,0,16,24,2,0,6,30,5),we(0,8,11,-5,0,17,26,2,0,6,32,5),we(0,9,11,-5,0,18,28,2,0,7,34,6),we(0,9,12,-6,0,19,29,2,0,7,36,6),we(0,10,13,-6,0,20,31,3,0,8,38,7),we(0,10,13,-6,0,21,33,3,0,8,40,7),we(0,10,14,-6,0,22,35,3,0,8,42,7),we(0,11,14,-7,0,23,36,3,0,9,44,8),we(0,11,15,-7,0,24,38,3,0,9,46,8)],Xp=Hp,Yp=["duration","easing","delay"],Wp={easeInOut:"cubic-bezier(0.4, 0, 0.2, 1)",easeOut:"cubic-bezier(0.0, 0, 0.2, 1)",easeIn:"cubic-bezier(0.4, 0, 1, 1)",sharp:"cubic-bezier(0.4, 0, 0.6, 1)"},Kp={shortest:150,shorter:200,short:250,standard:300,complex:375,enteringScreen:225,leavingScreen:195};function Ma(e){return`${Math.round(e)}ms`}function Jp(e){if(!e)return 0;const t=e/36;return Math.round((4+15*t**.25+t/5)*10)}function Zp(e){const t=O({},Wp,e.easing),n=O({},Kp,e.duration);return O({getAutoHeightDuration:Jp,create:(o=["all"],s={})=>{const{duration:i=n.standard,easing:l=t.easeInOut,delay:c=0}=s,d=Ne(s,Yp);if(process.env.NODE_ENV!=="production"){const u=w=>typeof w=="string",h=w=>!isNaN(parseFloat(w));!u(o)&&!Array.isArray(o)&&console.error('MUI: Argument "props" must be a string or Array.'),!h(i)&&!u(i)&&console.error(`MUI: Argument "duration" must be a number or a string but found ${i}.`),u(l)||console.error('MUI: Argument "easing" must be a string.'),!h(c)&&!u(c)&&console.error('MUI: Argument "delay" must be a number or a string.'),typeof s!="object"&&console.error(["MUI: Secong argument of transition.create must be an object.","Arguments should be either `create('prop1', options)` or `create(['prop1', 'prop2'], options)`"].join(` +`)),Object.keys(d).length!==0&&console.error(`MUI: Unrecognized argument(s) [${Object.keys(d).join(",")}].`)}return(Array.isArray(o)?o:[o]).map(u=>`${u} ${typeof i=="string"?i:Ma(i)} ${l} ${typeof c=="string"?c:Ma(c)}`).join(",")}},e,{easing:t,duration:n})}const Qp={mobileStepper:1e3,fab:1050,speedDial:1050,appBar:1100,drawer:1200,modal:1300,snackbar:1400,tooltip:1500},ew=Qp,tw=["breakpoints","mixins","spacing","palette","transitions","typography","shape"];function nw(e={},...t){const{mixins:n={},palette:r={},transitions:o={},typography:s={}}=e,i=Ne(e,tw);if(e.vars)throw new Error(process.env.NODE_ENV!=="production"?"MUI: `vars` is a private field used for CSS variables support.\nPlease use another name.":zt(18));const l=Vp(r),c=To(e);let d=Qe(c,{mixins:Np(c.breakpoints,n),palette:l,shadows:Xp.slice(),typography:Fp(l,s),transitions:Zp(o),zIndex:O({},ew)});if(d=Qe(d,i),d=t.reduce((u,h)=>Qe(u,h),d),process.env.NODE_ENV!=="production"){const u=["active","checked","completed","disabled","error","expanded","focused","focusVisible","required","selected"],h=(w,b)=>{let x;for(x in w){const f=w[x];if(u.indexOf(x)!==-1&&Object.keys(f).length>0){if(process.env.NODE_ENV!=="production"){const m=ur("",x);console.error([`MUI: The \`${b}\` component increases the CSS specificity of the \`${x}\` internal state.`,"You can not override it like this: ",JSON.stringify(w,null,2),"",`Instead, you need to use the '&.${m}' syntax:`,JSON.stringify({root:{[`&.${m}`]:f}},null,2),"","https://mui.com/r/state-classes-guide"].join(` +`))}w[x]={}}}};Object.keys(d.components).forEach(w=>{const b=d.components[w].styleOverrides;b&&w.indexOf("Mui")===0&&h(b,w)})}return d.unstable_sxConfig=O({},jo,i==null?void 0:i.unstable_sxConfig),d.unstable_sx=function(h){return Co({sx:h,theme:this})},d}const rw=nw(),Oo=rw,_o="$$material";function Po({props:e,name:t}){return gp({props:e,name:t,defaultTheme:Oo,themeId:_o})}const ow=e=>qn(e)&&e!=="classes",aw=mp({themeId:_o,defaultTheme:Oo,rootShouldForwardProp:ow}),In=aw;function sw(e){return ur("MuiSvgIcon",e)}ci("MuiSvgIcon",["root","colorPrimary","colorSecondary","colorAction","colorError","colorDisabled","fontSizeInherit","fontSizeSmall","fontSizeMedium","fontSizeLarge"]);const iw=["children","className","color","component","fontSize","htmlColor","inheritViewBox","titleAccess","viewBox"],lw=e=>{const{color:t,fontSize:n,classes:r}=e,o={root:["root",t!=="inherit"&&`color${Ye(t)}`,`fontSize${Ye(n)}`]};return ko(o,sw,r)},cw=In("svg",{name:"MuiSvgIcon",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.root,n.color!=="inherit"&&t[`color${Ye(n.color)}`],t[`fontSize${Ye(n.fontSize)}`]]}})(({theme:e,ownerState:t})=>{var n,r,o,s,i,l,c,d,u,h,w,b,x;return{userSelect:"none",width:"1em",height:"1em",display:"inline-block",fill:t.hasSvgAsChild?void 0:"currentColor",flexShrink:0,transition:(n=e.transitions)==null||(r=n.create)==null?void 0:r.call(n,"fill",{duration:(o=e.transitions)==null||(o=o.duration)==null?void 0:o.shorter}),fontSize:{inherit:"inherit",small:((s=e.typography)==null||(i=s.pxToRem)==null?void 0:i.call(s,20))||"1.25rem",medium:((l=e.typography)==null||(c=l.pxToRem)==null?void 0:c.call(l,24))||"1.5rem",large:((d=e.typography)==null||(u=d.pxToRem)==null?void 0:u.call(d,35))||"2.1875rem"}[t.fontSize],color:(h=(w=(e.vars||e).palette)==null||(w=w[t.color])==null?void 0:w.main)!=null?h:{action:(b=(e.vars||e).palette)==null||(b=b.action)==null?void 0:b.active,disabled:(x=(e.vars||e).palette)==null||(x=x.action)==null?void 0:x.disabled,inherit:void 0}[t.color]}}),Io=M.forwardRef(function(t,n){const r=Po({props:t,name:"MuiSvgIcon"}),{children:o,className:s,color:i="inherit",component:l="svg",fontSize:c="medium",htmlColor:d,inheritViewBox:u=!1,titleAccess:h,viewBox:w="0 0 24 24"}=r,b=Ne(r,iw),x=M.isValidElement(o)&&o.type==="svg",f=O({},r,{color:i,component:l,fontSize:c,instanceFontSize:t.fontSize,inheritViewBox:u,viewBox:w,hasSvgAsChild:x}),m={};u||(m.viewBox=w);const S=lw(f);return a.jsxs(cw,O({as:l,className:ot(S.root,s),focusable:"false",color:d,"aria-hidden":h?void 0:!0,role:h?"img":void 0,ref:n},m,b,x&&o.props,{ownerState:f,children:[x?o.props.children:o,h?a.jsx("title",{children:h}):null]}))});process.env.NODE_ENV!=="production"&&(Io.propTypes={children:p.node,classes:p.object,className:p.string,color:p.oneOfType([p.oneOf(["inherit","action","disabled","primary","secondary","error","info","success","warning"]),p.string]),component:p.elementType,fontSize:p.oneOfType([p.oneOf(["inherit","large","medium","small"]),p.string]),htmlColor:p.string,inheritViewBox:p.bool,shapeRendering:p.string,sx:p.oneOfType([p.arrayOf(p.oneOfType([p.func,p.object,p.bool])),p.func,p.object]),titleAccess:p.string,viewBox:p.string});Io.muiName="SvgIcon";const $a=Io;function hi(e,t){function n(r,o){return a.jsx($a,O({"data-testid":`${t}Icon`,ref:o},r,{children:e}))}return process.env.NODE_ENV!=="production"&&(n.displayName=`${t}Icon`),n.muiName=$a.muiName,M.memo(M.forwardRef(n))}const dw={configure:e=>{process.env.NODE_ENV!=="production"&&console.warn(["MUI: `ClassNameGenerator` import from `@mui/material/utils` is outdated and might cause unexpected issues.","","You should use `import { unstable_ClassNameGenerator } from '@mui/material/className'` instead","","The detail of the issue: https://github.com/mui/material-ui/issues/30011#issuecomment-1024993401","","The updated documentation: https://mui.com/guides/classname-generator/"].join(` +`)),ii.configure(e)}},uw=Object.freeze(Object.defineProperty({__proto__:null,capitalize:Ye,createChainedFunction:zd,createSvgIcon:hi,debounce:Ld,deprecatedPropType:Fd,isMuiElement:Gd,ownerDocument:Kn,ownerWindow:Ud,requirePropFactory:qd,setRef:Jn,unstable_ClassNameGenerator:dw,unstable_useEnhancedEffect:Lt,unstable_useId:ri,unsupportedProp:Yd,useControlled:oi,useEventCallback:Zr,useForkRef:yt,useIsFocusVisible:ai},Symbol.toStringTag,{value:"Module"})),pw=xd(uw);var Da;function ww(){return Da||(Da=1,function(e){"use client";Object.defineProperty(e,"__esModule",{value:!0}),Object.defineProperty(e,"default",{enumerable:!0,get:function(){return t.createSvgIcon}});var t=pw}(Pr)),Pr}var fw=yd;Object.defineProperty(xo,"__esModule",{value:!0});var gi=xo.default=void 0,mw=fw(ww()),hw=a;gi=xo.default=(0,mw.default)((0,hw.jsx)("path",{d:"m10 17 5-5-5-5z"}),"ArrowRight");function gw(e){return typeof e=="string"}function un(e,t,n){return e===void 0||gw(e)?t:O({},t,{ownerState:O({},t.ownerState,n)})}const bw={disableDefaultClasses:!1},vw=M.createContext(bw);function xw(e){const{disableDefaultClasses:t}=M.useContext(vw);return n=>t?"":e(n)}function yw(e,t=[]){if(e===void 0)return{};const n={};return Object.keys(e).filter(r=>r.match(/^on[A-Z]/)&&typeof e[r]=="function"&&!t.includes(r)).forEach(r=>{n[r]=e[r]}),n}function Nw(e,t,n){return typeof e=="function"?e(t,n):e}function Aa(e){if(e===void 0)return{};const t={};return Object.keys(e).filter(n=>!(n.match(/^on[A-Z]/)&&typeof e[n]=="function")).forEach(n=>{t[n]=e[n]}),t}function kw(e){const{getSlotProps:t,additionalProps:n,externalSlotProps:r,externalForwardedProps:o,className:s}=e;if(!t){const b=ot(n==null?void 0:n.className,s,o==null?void 0:o.className,r==null?void 0:r.className),x=O({},n==null?void 0:n.style,o==null?void 0:o.style,r==null?void 0:r.style),f=O({},n,o,r);return b.length>0&&(f.className=b),Object.keys(x).length>0&&(f.style=x),{props:f,internalRef:void 0}}const i=yw(O({},o,r)),l=Aa(r),c=Aa(o),d=t(i),u=ot(d==null?void 0:d.className,n==null?void 0:n.className,s,o==null?void 0:o.className,r==null?void 0:r.className),h=O({},d==null?void 0:d.style,n==null?void 0:n.style,o==null?void 0:o.style,r==null?void 0:r.style),w=O({},d,n,c,l);return u.length>0&&(w.className=u),Object.keys(h).length>0&&(w.style=h),{props:w,internalRef:d.ref}}const Sw=["elementType","externalSlotProps","ownerState","skipResolvingSlotProps"];function Ew(e){var t;const{elementType:n,externalSlotProps:r,ownerState:o,skipResolvingSlotProps:s=!1}=e,i=Ne(e,Sw),l=s?{}:Nw(r,o),{props:c,internalRef:d}=kw(O({},i,{externalSlotProps:l})),u=yt(d,l==null?void 0:l.ref,(t=e.additionalProps)==null?void 0:t.ref);return un(n,O({},c,{ref:u}),o)}const bi="base";function jw(e){return`${bi}--${e}`}function Cw(e,t){return`${bi}-${e}-${t}`}function vi(e,t){const n=li[t];return n?jw(n):Cw(e,t)}function Tw(e,t){const n={};return t.forEach(r=>{n[r]=vi(e,r)}),n}function Rw(e){return typeof e=="function"?e():e}const Qn=M.forwardRef(function(t,n){const{children:r,container:o,disablePortal:s=!1}=t,[i,l]=M.useState(null),c=yt(M.isValidElement(r)?r.ref:null,n);if(Lt(()=>{s||l(Rw(o)||document.body)},[o,s]),Lt(()=>{if(i&&!s)return Jn(n,i),()=>{Jn(n,null)}},[n,i,s]),s){if(M.isValidElement(r)){const d={ref:c};return M.cloneElement(r,d)}return a.jsx(M.Fragment,{children:r})}return a.jsx(M.Fragment,{children:i&&Ol.createPortal(r,i)})});process.env.NODE_ENV!=="production"&&(Qn.propTypes={children:p.node,container:p.oneOfType([xn,p.func]),disablePortal:p.bool});process.env.NODE_ENV!=="production"&&(Qn["propTypes"]=Id(Qn.propTypes));var Ce="top",ze="bottom",Le="right",Te="left",Mo="auto",Mn=[Ce,ze,Le,Te],Ft="start",Nn="end",Ow="clippingParents",xi="viewport",an="popper",_w="reference",Ba=Mn.reduce(function(e,t){return e.concat([t+"-"+Ft,t+"-"+Nn])},[]),yi=[].concat(Mn,[Mo]).reduce(function(e,t){return e.concat([t,t+"-"+Ft,t+"-"+Nn])},[]),Pw="beforeRead",Iw="read",Mw="afterRead",$w="beforeMain",Dw="main",Aw="afterMain",Bw="beforeWrite",Vw="write",zw="afterWrite",Lw=[Pw,Iw,Mw,$w,Dw,Aw,Bw,Vw,zw];function We(e){return e?(e.nodeName||"").toLowerCase():null}function $e(e){if(e==null)return window;if(e.toString()!=="[object Window]"){var t=e.ownerDocument;return t&&t.defaultView||window}return e}function kt(e){var t=$e(e).Element;return e instanceof t||e instanceof Element}function Ve(e){var t=$e(e).HTMLElement;return e instanceof t||e instanceof HTMLElement}function $o(e){if(typeof ShadowRoot>"u")return!1;var t=$e(e).ShadowRoot;return e instanceof t||e instanceof ShadowRoot}function Fw(e){var t=e.state;Object.keys(t.elements).forEach(function(n){var r=t.styles[n]||{},o=t.attributes[n]||{},s=t.elements[n];!Ve(s)||!We(s)||(Object.assign(s.style,r),Object.keys(o).forEach(function(i){var l=o[i];l===!1?s.removeAttribute(i):s.setAttribute(i,l===!0?"":l)}))})}function Gw(e){var t=e.state,n={popper:{position:t.options.strategy,left:"0",top:"0",margin:"0"},arrow:{position:"absolute"},reference:{}};return Object.assign(t.elements.popper.style,n.popper),t.styles=n,t.elements.arrow&&Object.assign(t.elements.arrow.style,n.arrow),function(){Object.keys(t.elements).forEach(function(r){var o=t.elements[r],s=t.attributes[r]||{},i=Object.keys(t.styles.hasOwnProperty(r)?t.styles[r]:n[r]),l=i.reduce(function(c,d){return c[d]="",c},{});!Ve(o)||!We(o)||(Object.assign(o.style,l),Object.keys(s).forEach(function(c){o.removeAttribute(c)}))})}}const Uw={name:"applyStyles",enabled:!0,phase:"write",fn:Fw,effect:Gw,requires:["computeStyles"]};function Xe(e){return e.split("-")[0]}var ht=Math.max,er=Math.min,Gt=Math.round;function eo(){var e=navigator.userAgentData;return e!=null&&e.brands&&Array.isArray(e.brands)?e.brands.map(function(t){return t.brand+"/"+t.version}).join(" "):navigator.userAgent}function Ni(){return!/^((?!chrome|android).)*safari/i.test(eo())}function Ut(e,t,n){t===void 0&&(t=!1),n===void 0&&(n=!1);var r=e.getBoundingClientRect(),o=1,s=1;t&&Ve(e)&&(o=e.offsetWidth>0&&Gt(r.width)/e.offsetWidth||1,s=e.offsetHeight>0&&Gt(r.height)/e.offsetHeight||1);var i=kt(e)?$e(e):window,l=i.visualViewport,c=!Ni()&&n,d=(r.left+(c&&l?l.offsetLeft:0))/o,u=(r.top+(c&&l?l.offsetTop:0))/s,h=r.width/o,w=r.height/s;return{width:h,height:w,top:u,right:d+h,bottom:u+w,left:d,x:d,y:u}}function Do(e){var t=Ut(e),n=e.offsetWidth,r=e.offsetHeight;return Math.abs(t.width-n)<=1&&(n=t.width),Math.abs(t.height-r)<=1&&(r=t.height),{x:e.offsetLeft,y:e.offsetTop,width:n,height:r}}function ki(e,t){var n=t.getRootNode&&t.getRootNode();if(e.contains(t))return!0;if(n&&$o(n)){var r=t;do{if(r&&e.isSameNode(r))return!0;r=r.parentNode||r.host}while(r)}return!1}function tt(e){return $e(e).getComputedStyle(e)}function qw(e){return["table","td","th"].indexOf(We(e))>=0}function it(e){return((kt(e)?e.ownerDocument:e.document)||window.document).documentElement}function yr(e){return We(e)==="html"?e:e.assignedSlot||e.parentNode||($o(e)?e.host:null)||it(e)}function Va(e){return!Ve(e)||tt(e).position==="fixed"?null:e.offsetParent}function Hw(e){var t=/firefox/i.test(eo()),n=/Trident/i.test(eo());if(n&&Ve(e)){var r=tt(e);if(r.position==="fixed")return null}var o=yr(e);for($o(o)&&(o=o.host);Ve(o)&&["html","body"].indexOf(We(o))<0;){var s=tt(o);if(s.transform!=="none"||s.perspective!=="none"||s.contain==="paint"||["transform","perspective"].indexOf(s.willChange)!==-1||t&&s.willChange==="filter"||t&&s.filter&&s.filter!=="none")return o;o=o.parentNode}return null}function $n(e){for(var t=$e(e),n=Va(e);n&&qw(n)&&tt(n).position==="static";)n=Va(n);return n&&(We(n)==="html"||We(n)==="body"&&tt(n).position==="static")?t:n||Hw(e)||t}function Ao(e){return["top","bottom"].indexOf(e)>=0?"x":"y"}function hn(e,t,n){return ht(e,er(t,n))}function Xw(e,t,n){var r=hn(e,t,n);return r>n?n:r}function Si(){return{top:0,right:0,bottom:0,left:0}}function Ei(e){return Object.assign({},Si(),e)}function ji(e,t){return t.reduce(function(n,r){return n[r]=e,n},{})}var Yw=function(t,n){return t=typeof t=="function"?t(Object.assign({},n.rects,{placement:n.placement})):t,Ei(typeof t!="number"?t:ji(t,Mn))};function Ww(e){var t,n=e.state,r=e.name,o=e.options,s=n.elements.arrow,i=n.modifiersData.popperOffsets,l=Xe(n.placement),c=Ao(l),d=[Te,Le].indexOf(l)>=0,u=d?"height":"width";if(!(!s||!i)){var h=Yw(o.padding,n),w=Do(s),b=c==="y"?Ce:Te,x=c==="y"?ze:Le,f=n.rects.reference[u]+n.rects.reference[c]-i[c]-n.rects.popper[u],m=i[c]-n.rects.reference[c],S=$n(s),R=S?c==="y"?S.clientHeight||0:S.clientWidth||0:0,j=f/2-m/2,E=h[b],v=R-w[u]-h[x],P=R/2-w[u]/2+j,V=hn(E,P,v),U=c;n.modifiersData[r]=(t={},t[U]=V,t.centerOffset=V-P,t)}}function Kw(e){var t=e.state,n=e.options,r=n.element,o=r===void 0?"[data-popper-arrow]":r;o!=null&&(typeof o=="string"&&(o=t.elements.popper.querySelector(o),!o)||ki(t.elements.popper,o)&&(t.elements.arrow=o))}const Jw={name:"arrow",enabled:!0,phase:"main",fn:Ww,effect:Kw,requires:["popperOffsets"],requiresIfExists:["preventOverflow"]};function qt(e){return e.split("-")[1]}var Zw={top:"auto",right:"auto",bottom:"auto",left:"auto"};function Qw(e,t){var n=e.x,r=e.y,o=t.devicePixelRatio||1;return{x:Gt(n*o)/o||0,y:Gt(r*o)/o||0}}function za(e){var t,n=e.popper,r=e.popperRect,o=e.placement,s=e.variation,i=e.offsets,l=e.position,c=e.gpuAcceleration,d=e.adaptive,u=e.roundOffsets,h=e.isFixed,w=i.x,b=w===void 0?0:w,x=i.y,f=x===void 0?0:x,m=typeof u=="function"?u({x:b,y:f}):{x:b,y:f};b=m.x,f=m.y;var S=i.hasOwnProperty("x"),R=i.hasOwnProperty("y"),j=Te,E=Ce,v=window;if(d){var P=$n(n),V="clientHeight",U="clientWidth";if(P===$e(n)&&(P=it(n),tt(P).position!=="static"&&l==="absolute"&&(V="scrollHeight",U="scrollWidth")),P=P,o===Ce||(o===Te||o===Le)&&s===Nn){E=ze;var C=h&&P===v&&v.visualViewport?v.visualViewport.height:P[V];f-=C-r.height,f*=c?1:-1}if(o===Te||(o===Ce||o===ze)&&s===Nn){j=Le;var _=h&&P===v&&v.visualViewport?v.visualViewport.width:P[U];b-=_-r.width,b*=c?1:-1}}var k=Object.assign({position:l},d&&Zw),D=u===!0?Qw({x:b,y:f},$e(n)):{x:b,y:f};if(b=D.x,f=D.y,c){var $;return Object.assign({},k,($={},$[E]=R?"0":"",$[j]=S?"0":"",$.transform=(v.devicePixelRatio||1)<=1?"translate("+b+"px, "+f+"px)":"translate3d("+b+"px, "+f+"px, 0)",$))}return Object.assign({},k,(t={},t[E]=R?f+"px":"",t[j]=S?b+"px":"",t.transform="",t))}function ef(e){var t=e.state,n=e.options,r=n.gpuAcceleration,o=r===void 0?!0:r,s=n.adaptive,i=s===void 0?!0:s,l=n.roundOffsets,c=l===void 0?!0:l,d={placement:Xe(t.placement),variation:qt(t.placement),popper:t.elements.popper,popperRect:t.rects.popper,gpuAcceleration:o,isFixed:t.options.strategy==="fixed"};t.modifiersData.popperOffsets!=null&&(t.styles.popper=Object.assign({},t.styles.popper,za(Object.assign({},d,{offsets:t.modifiersData.popperOffsets,position:t.options.strategy,adaptive:i,roundOffsets:c})))),t.modifiersData.arrow!=null&&(t.styles.arrow=Object.assign({},t.styles.arrow,za(Object.assign({},d,{offsets:t.modifiersData.arrow,position:"absolute",adaptive:!1,roundOffsets:c})))),t.attributes.popper=Object.assign({},t.attributes.popper,{"data-popper-placement":t.placement})}const tf={name:"computeStyles",enabled:!0,phase:"beforeWrite",fn:ef,data:{}};var Fn={passive:!0};function nf(e){var t=e.state,n=e.instance,r=e.options,o=r.scroll,s=o===void 0?!0:o,i=r.resize,l=i===void 0?!0:i,c=$e(t.elements.popper),d=[].concat(t.scrollParents.reference,t.scrollParents.popper);return s&&d.forEach(function(u){u.addEventListener("scroll",n.update,Fn)}),l&&c.addEventListener("resize",n.update,Fn),function(){s&&d.forEach(function(u){u.removeEventListener("scroll",n.update,Fn)}),l&&c.removeEventListener("resize",n.update,Fn)}}const rf={name:"eventListeners",enabled:!0,phase:"write",fn:function(){},effect:nf,data:{}};var of={left:"right",right:"left",bottom:"top",top:"bottom"};function Xn(e){return e.replace(/left|right|bottom|top/g,function(t){return of[t]})}var af={start:"end",end:"start"};function La(e){return e.replace(/start|end/g,function(t){return af[t]})}function Bo(e){var t=$e(e),n=t.pageXOffset,r=t.pageYOffset;return{scrollLeft:n,scrollTop:r}}function Vo(e){return Ut(it(e)).left+Bo(e).scrollLeft}function sf(e,t){var n=$e(e),r=it(e),o=n.visualViewport,s=r.clientWidth,i=r.clientHeight,l=0,c=0;if(o){s=o.width,i=o.height;var d=Ni();(d||!d&&t==="fixed")&&(l=o.offsetLeft,c=o.offsetTop)}return{width:s,height:i,x:l+Vo(e),y:c}}function lf(e){var t,n=it(e),r=Bo(e),o=(t=e.ownerDocument)==null?void 0:t.body,s=ht(n.scrollWidth,n.clientWidth,o?o.scrollWidth:0,o?o.clientWidth:0),i=ht(n.scrollHeight,n.clientHeight,o?o.scrollHeight:0,o?o.clientHeight:0),l=-r.scrollLeft+Vo(e),c=-r.scrollTop;return tt(o||n).direction==="rtl"&&(l+=ht(n.clientWidth,o?o.clientWidth:0)-s),{width:s,height:i,x:l,y:c}}function zo(e){var t=tt(e),n=t.overflow,r=t.overflowX,o=t.overflowY;return/auto|scroll|overlay|hidden/.test(n+o+r)}function Ci(e){return["html","body","#document"].indexOf(We(e))>=0?e.ownerDocument.body:Ve(e)&&zo(e)?e:Ci(yr(e))}function gn(e,t){var n;t===void 0&&(t=[]);var r=Ci(e),o=r===((n=e.ownerDocument)==null?void 0:n.body),s=$e(r),i=o?[s].concat(s.visualViewport||[],zo(r)?r:[]):r,l=t.concat(i);return o?l:l.concat(gn(yr(i)))}function to(e){return Object.assign({},e,{left:e.x,top:e.y,right:e.x+e.width,bottom:e.y+e.height})}function cf(e,t){var n=Ut(e,!1,t==="fixed");return n.top=n.top+e.clientTop,n.left=n.left+e.clientLeft,n.bottom=n.top+e.clientHeight,n.right=n.left+e.clientWidth,n.width=e.clientWidth,n.height=e.clientHeight,n.x=n.left,n.y=n.top,n}function Fa(e,t,n){return t===xi?to(sf(e,n)):kt(t)?cf(t,n):to(lf(it(e)))}function df(e){var t=gn(yr(e)),n=["absolute","fixed"].indexOf(tt(e).position)>=0,r=n&&Ve(e)?$n(e):e;return kt(r)?t.filter(function(o){return kt(o)&&ki(o,r)&&We(o)!=="body"}):[]}function uf(e,t,n,r){var o=t==="clippingParents"?df(e):[].concat(t),s=[].concat(o,[n]),i=s[0],l=s.reduce(function(c,d){var u=Fa(e,d,r);return c.top=ht(u.top,c.top),c.right=er(u.right,c.right),c.bottom=er(u.bottom,c.bottom),c.left=ht(u.left,c.left),c},Fa(e,i,r));return l.width=l.right-l.left,l.height=l.bottom-l.top,l.x=l.left,l.y=l.top,l}function Ti(e){var t=e.reference,n=e.element,r=e.placement,o=r?Xe(r):null,s=r?qt(r):null,i=t.x+t.width/2-n.width/2,l=t.y+t.height/2-n.height/2,c;switch(o){case Ce:c={x:i,y:t.y-n.height};break;case ze:c={x:i,y:t.y+t.height};break;case Le:c={x:t.x+t.width,y:l};break;case Te:c={x:t.x-n.width,y:l};break;default:c={x:t.x,y:t.y}}var d=o?Ao(o):null;if(d!=null){var u=d==="y"?"height":"width";switch(s){case Ft:c[d]=c[d]-(t[u]/2-n[u]/2);break;case Nn:c[d]=c[d]+(t[u]/2-n[u]/2);break}}return c}function kn(e,t){t===void 0&&(t={});var n=t,r=n.placement,o=r===void 0?e.placement:r,s=n.strategy,i=s===void 0?e.strategy:s,l=n.boundary,c=l===void 0?Ow:l,d=n.rootBoundary,u=d===void 0?xi:d,h=n.elementContext,w=h===void 0?an:h,b=n.altBoundary,x=b===void 0?!1:b,f=n.padding,m=f===void 0?0:f,S=Ei(typeof m!="number"?m:ji(m,Mn)),R=w===an?_w:an,j=e.rects.popper,E=e.elements[x?R:w],v=uf(kt(E)?E:E.contextElement||it(e.elements.popper),c,u,i),P=Ut(e.elements.reference),V=Ti({reference:P,element:j,strategy:"absolute",placement:o}),U=to(Object.assign({},j,V)),C=w===an?U:P,_={top:v.top-C.top+S.top,bottom:C.bottom-v.bottom+S.bottom,left:v.left-C.left+S.left,right:C.right-v.right+S.right},k=e.modifiersData.offset;if(w===an&&k){var D=k[o];Object.keys(_).forEach(function($){var J=[Le,ze].indexOf($)>=0?1:-1,Y=[Ce,ze].indexOf($)>=0?"y":"x";_[$]+=D[Y]*J})}return _}function pf(e,t){t===void 0&&(t={});var n=t,r=n.placement,o=n.boundary,s=n.rootBoundary,i=n.padding,l=n.flipVariations,c=n.allowedAutoPlacements,d=c===void 0?yi:c,u=qt(r),h=u?l?Ba:Ba.filter(function(x){return qt(x)===u}):Mn,w=h.filter(function(x){return d.indexOf(x)>=0});w.length===0&&(w=h);var b=w.reduce(function(x,f){return x[f]=kn(e,{placement:f,boundary:o,rootBoundary:s,padding:i})[Xe(f)],x},{});return Object.keys(b).sort(function(x,f){return b[x]-b[f]})}function wf(e){if(Xe(e)===Mo)return[];var t=Xn(e);return[La(e),t,La(t)]}function ff(e){var t=e.state,n=e.options,r=e.name;if(!t.modifiersData[r]._skip){for(var o=n.mainAxis,s=o===void 0?!0:o,i=n.altAxis,l=i===void 0?!0:i,c=n.fallbackPlacements,d=n.padding,u=n.boundary,h=n.rootBoundary,w=n.altBoundary,b=n.flipVariations,x=b===void 0?!0:b,f=n.allowedAutoPlacements,m=t.options.placement,S=Xe(m),R=S===m,j=c||(R||!x?[Xn(m)]:wf(m)),E=[m].concat(j).reduce(function(B,X){return B.concat(Xe(X)===Mo?pf(t,{placement:X,boundary:u,rootBoundary:h,padding:d,flipVariations:x,allowedAutoPlacements:f}):X)},[]),v=t.rects.reference,P=t.rects.popper,V=new Map,U=!0,C=E[0],_=0;_=0,Y=J?"width":"height",F=kn(t,{placement:k,boundary:u,rootBoundary:h,altBoundary:w,padding:d}),te=J?$?Le:Te:$?ze:Ce;v[Y]>P[Y]&&(te=Xn(te));var se=Xn(te),oe=[];if(s&&oe.push(F[D]<=0),l&&oe.push(F[te]<=0,F[se]<=0),oe.every(function(B){return B})){C=k,U=!1;break}V.set(k,oe)}if(U)for(var y=x?3:1,T=function(X){var q=E.find(function(H){var G=V.get(H);if(G)return G.slice(0,X).every(function(K){return K})});if(q)return C=q,"break"},z=y;z>0;z--){var L=T(z);if(L==="break")break}t.placement!==C&&(t.modifiersData[r]._skip=!0,t.placement=C,t.reset=!0)}}const mf={name:"flip",enabled:!0,phase:"main",fn:ff,requiresIfExists:["offset"],data:{_skip:!1}};function Ga(e,t,n){return n===void 0&&(n={x:0,y:0}),{top:e.top-t.height-n.y,right:e.right-t.width+n.x,bottom:e.bottom-t.height+n.y,left:e.left-t.width-n.x}}function Ua(e){return[Ce,Le,ze,Te].some(function(t){return e[t]>=0})}function hf(e){var t=e.state,n=e.name,r=t.rects.reference,o=t.rects.popper,s=t.modifiersData.preventOverflow,i=kn(t,{elementContext:"reference"}),l=kn(t,{altBoundary:!0}),c=Ga(i,r),d=Ga(l,o,s),u=Ua(c),h=Ua(d);t.modifiersData[n]={referenceClippingOffsets:c,popperEscapeOffsets:d,isReferenceHidden:u,hasPopperEscaped:h},t.attributes.popper=Object.assign({},t.attributes.popper,{"data-popper-reference-hidden":u,"data-popper-escaped":h})}const gf={name:"hide",enabled:!0,phase:"main",requiresIfExists:["preventOverflow"],fn:hf};function bf(e,t,n){var r=Xe(e),o=[Te,Ce].indexOf(r)>=0?-1:1,s=typeof n=="function"?n(Object.assign({},t,{placement:e})):n,i=s[0],l=s[1];return i=i||0,l=(l||0)*o,[Te,Le].indexOf(r)>=0?{x:l,y:i}:{x:i,y:l}}function vf(e){var t=e.state,n=e.options,r=e.name,o=n.offset,s=o===void 0?[0,0]:o,i=yi.reduce(function(u,h){return u[h]=bf(h,t.rects,s),u},{}),l=i[t.placement],c=l.x,d=l.y;t.modifiersData.popperOffsets!=null&&(t.modifiersData.popperOffsets.x+=c,t.modifiersData.popperOffsets.y+=d),t.modifiersData[r]=i}const xf={name:"offset",enabled:!0,phase:"main",requires:["popperOffsets"],fn:vf};function yf(e){var t=e.state,n=e.name;t.modifiersData[n]=Ti({reference:t.rects.reference,element:t.rects.popper,strategy:"absolute",placement:t.placement})}const Nf={name:"popperOffsets",enabled:!0,phase:"read",fn:yf,data:{}};function kf(e){return e==="x"?"y":"x"}function Sf(e){var t=e.state,n=e.options,r=e.name,o=n.mainAxis,s=o===void 0?!0:o,i=n.altAxis,l=i===void 0?!1:i,c=n.boundary,d=n.rootBoundary,u=n.altBoundary,h=n.padding,w=n.tether,b=w===void 0?!0:w,x=n.tetherOffset,f=x===void 0?0:x,m=kn(t,{boundary:c,rootBoundary:d,padding:h,altBoundary:u}),S=Xe(t.placement),R=qt(t.placement),j=!R,E=Ao(S),v=kf(E),P=t.modifiersData.popperOffsets,V=t.rects.reference,U=t.rects.popper,C=typeof f=="function"?f(Object.assign({},t.rects,{placement:t.placement})):f,_=typeof C=="number"?{mainAxis:C,altAxis:C}:Object.assign({mainAxis:0,altAxis:0},C),k=t.modifiersData.offset?t.modifiersData.offset[t.placement]:null,D={x:0,y:0};if(P){if(s){var $,J=E==="y"?Ce:Te,Y=E==="y"?ze:Le,F=E==="y"?"height":"width",te=P[E],se=te+m[J],oe=te-m[Y],y=b?-U[F]/2:0,T=R===Ft?V[F]:U[F],z=R===Ft?-U[F]:-V[F],L=t.elements.arrow,B=b&&L?Do(L):{width:0,height:0},X=t.modifiersData["arrow#persistent"]?t.modifiersData["arrow#persistent"].padding:Si(),q=X[J],H=X[Y],G=hn(0,V[F],B[F]),K=j?V[F]/2-y-G-q-_.mainAxis:T-G-q-_.mainAxis,Z=j?-V[F]/2+y+G+H+_.mainAxis:z+G+H+_.mainAxis,ue=t.elements.arrow&&$n(t.elements.arrow),I=ue?E==="y"?ue.clientTop||0:ue.clientLeft||0:0,ye=($=k==null?void 0:k[E])!=null?$:0,A=te+K-ye-I,xe=te+Z-ye,Ge=hn(b?er(se,A):se,te,b?ht(oe,xe):oe);P[E]=Ge,D[E]=Ge-te}if(l){var lt,Ee=E==="x"?Ce:Te,Dn=E==="x"?ze:Le,Ue=P[v],Et=v==="y"?"height":"width",ct=Ue+m[Ee],jt=Ue-m[Dn],Ct=[Ce,Te].indexOf(S)!==-1,Tt=(lt=k==null?void 0:k[v])!=null?lt:0,dt=Ct?ct:Ue-V[Et]-U[Et]-Tt+_.altAxis,Jt=Ct?Ue+V[Et]+U[Et]-Tt-_.altAxis:jt,An=b&&Ct?Xw(dt,Ue,Jt):hn(b?dt:ct,Ue,b?Jt:jt);P[v]=An,D[v]=An-Ue}t.modifiersData[r]=D}}const Ef={name:"preventOverflow",enabled:!0,phase:"main",fn:Sf,requiresIfExists:["offset"]};function jf(e){return{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}}function Cf(e){return e===$e(e)||!Ve(e)?Bo(e):jf(e)}function Tf(e){var t=e.getBoundingClientRect(),n=Gt(t.width)/e.offsetWidth||1,r=Gt(t.height)/e.offsetHeight||1;return n!==1||r!==1}function Rf(e,t,n){n===void 0&&(n=!1);var r=Ve(t),o=Ve(t)&&Tf(t),s=it(t),i=Ut(e,o,n),l={scrollLeft:0,scrollTop:0},c={x:0,y:0};return(r||!r&&!n)&&((We(t)!=="body"||zo(s))&&(l=Cf(t)),Ve(t)?(c=Ut(t,!0),c.x+=t.clientLeft,c.y+=t.clientTop):s&&(c.x=Vo(s))),{x:i.left+l.scrollLeft-c.x,y:i.top+l.scrollTop-c.y,width:i.width,height:i.height}}function Of(e){var t=new Map,n=new Set,r=[];e.forEach(function(s){t.set(s.name,s)});function o(s){n.add(s.name);var i=[].concat(s.requires||[],s.requiresIfExists||[]);i.forEach(function(l){if(!n.has(l)){var c=t.get(l);c&&o(c)}}),r.push(s)}return e.forEach(function(s){n.has(s.name)||o(s)}),r}function _f(e){var t=Of(e);return Lw.reduce(function(n,r){return n.concat(t.filter(function(o){return o.phase===r}))},[])}function Pf(e){var t;return function(){return t||(t=new Promise(function(n){Promise.resolve().then(function(){t=void 0,n(e())})})),t}}function If(e){var t=e.reduce(function(n,r){var o=n[r.name];return n[r.name]=o?Object.assign({},o,r,{options:Object.assign({},o.options,r.options),data:Object.assign({},o.data,r.data)}):r,n},{});return Object.keys(t).map(function(n){return t[n]})}var qa={placement:"bottom",modifiers:[],strategy:"absolute"};function Ha(){for(var e=arguments.length,t=new Array(e),n=0;nko({root:["root"]},xw(Af)),Gf={},Uf=M.forwardRef(function(t,n){var r;const{anchorEl:o,children:s,direction:i,disablePortal:l,modifiers:c,open:d,placement:u,popperOptions:h,popperRef:w,slotProps:b={},slots:x={},TransitionProps:f}=t,m=Ne(t,Bf),S=M.useRef(null),R=yt(S,n),j=M.useRef(null),E=yt(j,w),v=M.useRef(E);Lt(()=>{v.current=E},[E]),M.useImperativeHandle(w,()=>j.current,[]);const P=zf(u,i),[V,U]=M.useState(P),[C,_]=M.useState(tr(o));M.useEffect(()=>{j.current&&j.current.forceUpdate()}),M.useEffect(()=>{o&&_(tr(o))},[o]),Lt(()=>{if(!C||!d)return;const Y=se=>{U(se.placement)};if(process.env.NODE_ENV!=="production"&&C&&Nr(C)&&C.nodeType===1){const se=C.getBoundingClientRect();process.env.NODE_ENV!=="test"&&se.top===0&&se.left===0&&se.right===0&&se.bottom===0&&console.warn(["MUI: The `anchorEl` prop provided to the component is invalid.","The anchor element should be part of the document layout.","Make sure the element is present in the document or that it's not display none."].join(` +`))}let F=[{name:"preventOverflow",options:{altBoundary:l}},{name:"flip",options:{altBoundary:l}},{name:"onUpdate",enabled:!0,phase:"afterWrite",fn:({state:se})=>{Y(se)}}];c!=null&&(F=F.concat(c)),h&&h.modifiers!=null&&(F=F.concat(h.modifiers));const te=Df(C,S.current,O({placement:P},h,{modifiers:F}));return v.current(te),()=>{te.destroy(),v.current(null)}},[C,l,c,d,h,P]);const k={placement:V};f!==null&&(k.TransitionProps=f);const D=Ff(),$=(r=x.root)!=null?r:"div",J=Ew({elementType:$,externalSlotProps:b.root,externalForwardedProps:m,additionalProps:{role:"tooltip",ref:R},ownerState:t,className:D.root});return a.jsx($,O({},J,{children:typeof s=="function"?s(k):s}))}),Oi=M.forwardRef(function(t,n){const{anchorEl:r,children:o,container:s,direction:i="ltr",disablePortal:l=!1,keepMounted:c=!1,modifiers:d,open:u,placement:h="bottom",popperOptions:w=Gf,popperRef:b,style:x,transition:f=!1,slotProps:m={},slots:S={}}=t,R=Ne(t,Vf),[j,E]=M.useState(!0),v=()=>{E(!1)},P=()=>{E(!0)};if(!c&&!u&&(!f||j))return null;let V;if(s)V=s;else if(r){const _=tr(r);V=_&&Nr(_)?Kn(_).body:Kn(null).body}const U=!u&&c&&(!f||j)?"none":void 0,C=f?{in:u,onEnter:v,onExited:P}:void 0;return a.jsx(Qn,{disablePortal:l,container:V,children:a.jsx(Uf,O({anchorEl:r,direction:i,disablePortal:l,modifiers:d,ref:n,open:f?!j:u,placement:h,popperOptions:w,popperRef:b,slotProps:m,slots:S},R,{style:O({position:"fixed",top:0,left:0,display:U},x),TransitionProps:C,children:o}))})});process.env.NODE_ENV!=="production"&&(Oi.propTypes={anchorEl:yo(p.oneOfType([xn,p.object,p.func]),e=>{if(e.open){const t=tr(e.anchorEl);if(t&&Nr(t)&&t.nodeType===1){const n=t.getBoundingClientRect();if(process.env.NODE_ENV!=="test"&&n.top===0&&n.left===0&&n.right===0&&n.bottom===0)return new Error(["MUI: The `anchorEl` prop provided to the component is invalid.","The anchor element should be part of the document layout.","Make sure the element is present in the document or that it's not display none."].join(` +`))}else if(!t||typeof t.getBoundingClientRect!="function"||Lf(t)&&t.contextElement!=null&&t.contextElement.nodeType!==1)return new Error(["MUI: The `anchorEl` prop provided to the component is invalid.","It should be an HTML element instance or a virtualElement ","(https://popper.js.org/docs/v2/virtual-elements/)."].join(` +`))}return null}),children:p.oneOfType([p.node,p.func]),container:p.oneOfType([xn,p.func]),direction:p.oneOf(["ltr","rtl"]),disablePortal:p.bool,keepMounted:p.bool,modifiers:p.arrayOf(p.shape({data:p.object,effect:p.func,enabled:p.bool,fn:p.func,name:p.any,options:p.object,phase:p.oneOf(["afterMain","afterRead","afterWrite","beforeMain","beforeRead","beforeWrite","main","read","write"]),requires:p.arrayOf(p.string),requiresIfExists:p.arrayOf(p.string)})),open:p.bool.isRequired,placement:p.oneOf(["auto-end","auto-start","auto","bottom-end","bottom-start","bottom","left-end","left-start","left","right-end","right-start","right","top-end","top-start","top"]),popperOptions:p.shape({modifiers:p.array,onFirstUpdate:p.func,placement:p.oneOf(["auto-end","auto-start","auto","bottom-end","bottom-start","bottom","left-end","left-start","left","right-end","right-start","right","top-end","top-start","top"]),strategy:p.oneOf(["absolute","fixed"])}),popperRef:ni,slotProps:p.shape({root:p.oneOfType([p.func,p.object])}),slots:p.shape({root:p.elementType}),transition:p.bool});function _i(){const e=fi(Oo);return process.env.NODE_ENV!=="production"&&M.useDebugValue(e),e[_o]||e}function no(e,t){return no=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,o){return r.__proto__=o,r},no(e,t)}function qf(e,t){e.prototype=Object.create(t.prototype),e.prototype.constructor=e,no(e,t)}const Xa={disabled:!1};var Hf=process.env.NODE_ENV!=="production"?p.oneOfType([p.number,p.shape({enter:p.number,exit:p.number,appear:p.number}).isRequired]):null;process.env.NODE_ENV!=="production"&&p.oneOfType([p.string,p.shape({enter:p.string,exit:p.string,active:p.string}),p.shape({enter:p.string,enterDone:p.string,enterActive:p.string,exit:p.string,exitDone:p.string,exitActive:p.string})]);const Pi=g.createContext(null);var Xf=function(t){return t.scrollTop},pn="unmounted",wt="exited",ft="entering",$t="entered",ro="exiting",nt=function(e){qf(t,e);function t(r,o){var s;s=e.call(this,r,o)||this;var i=o,l=i&&!i.isMounting?r.enter:r.appear,c;return s.appearStatus=null,r.in?l?(c=wt,s.appearStatus=ft):c=$t:r.unmountOnExit||r.mountOnEnter?c=pn:c=wt,s.state={status:c},s.nextCallback=null,s}t.getDerivedStateFromProps=function(o,s){var i=o.in;return i&&s.status===pn?{status:wt}:null};var n=t.prototype;return n.componentDidMount=function(){this.updateStatus(!0,this.appearStatus)},n.componentDidUpdate=function(o){var s=null;if(o!==this.props){var i=this.state.status;this.props.in?i!==ft&&i!==$t&&(s=ft):(i===ft||i===$t)&&(s=ro)}this.updateStatus(!1,s)},n.componentWillUnmount=function(){this.cancelNextCallback()},n.getTimeouts=function(){var o=this.props.timeout,s,i,l;return s=i=l=o,o!=null&&typeof o!="number"&&(s=o.exit,i=o.enter,l=o.appear!==void 0?o.appear:i),{exit:s,enter:i,appear:l}},n.updateStatus=function(o,s){if(o===void 0&&(o=!1),s!==null)if(this.cancelNextCallback(),s===ft){if(this.props.unmountOnExit||this.props.mountOnEnter){var i=this.props.nodeRef?this.props.nodeRef.current:ln.findDOMNode(this);i&&Xf(i)}this.performEnter(o)}else this.performExit();else this.props.unmountOnExit&&this.state.status===wt&&this.setState({status:pn})},n.performEnter=function(o){var s=this,i=this.props.enter,l=this.context?this.context.isMounting:o,c=this.props.nodeRef?[l]:[ln.findDOMNode(this),l],d=c[0],u=c[1],h=this.getTimeouts(),w=l?h.appear:h.enter;if(!o&&!i||Xa.disabled){this.safeSetState({status:$t},function(){s.props.onEntered(d)});return}this.props.onEnter(d,u),this.safeSetState({status:ft},function(){s.props.onEntering(d,u),s.onTransitionEnd(w,function(){s.safeSetState({status:$t},function(){s.props.onEntered(d,u)})})})},n.performExit=function(){var o=this,s=this.props.exit,i=this.getTimeouts(),l=this.props.nodeRef?void 0:ln.findDOMNode(this);if(!s||Xa.disabled){this.safeSetState({status:wt},function(){o.props.onExited(l)});return}this.props.onExit(l),this.safeSetState({status:ro},function(){o.props.onExiting(l),o.onTransitionEnd(i.exit,function(){o.safeSetState({status:wt},function(){o.props.onExited(l)})})})},n.cancelNextCallback=function(){this.nextCallback!==null&&(this.nextCallback.cancel(),this.nextCallback=null)},n.safeSetState=function(o,s){s=this.setNextCallback(s),this.setState(o,s)},n.setNextCallback=function(o){var s=this,i=!0;return this.nextCallback=function(l){i&&(i=!1,s.nextCallback=null,o(l))},this.nextCallback.cancel=function(){i=!1},this.nextCallback},n.onTransitionEnd=function(o,s){this.setNextCallback(s);var i=this.props.nodeRef?this.props.nodeRef.current:ln.findDOMNode(this),l=o==null&&!this.props.addEndListener;if(!i||l){setTimeout(this.nextCallback,0);return}if(this.props.addEndListener){var c=this.props.nodeRef?[this.nextCallback]:[i,this.nextCallback],d=c[0],u=c[1];this.props.addEndListener(d,u)}o!=null&&setTimeout(this.nextCallback,o)},n.render=function(){var o=this.state.status;if(o===pn)return null;var s=this.props,i=s.children;s.in,s.mountOnEnter,s.unmountOnExit,s.appear,s.enter,s.exit,s.timeout,s.addEndListener,s.onEnter,s.onEntering,s.onEntered,s.onExit,s.onExiting,s.onExited,s.nodeRef;var l=Ne(s,["children","in","mountOnEnter","unmountOnExit","appear","enter","exit","timeout","addEndListener","onEnter","onEntering","onEntered","onExit","onExiting","onExited","nodeRef"]);return g.createElement(Pi.Provider,{value:null},typeof i=="function"?i(o,l):g.cloneElement(g.Children.only(i),l))},t}(g.Component);nt.contextType=Pi;nt.propTypes=process.env.NODE_ENV!=="production"?{nodeRef:p.shape({current:typeof Element>"u"?p.any:function(e,t,n,r,o,s){var i=e[t];return p.instanceOf(i&&"ownerDocument"in i?i.ownerDocument.defaultView.Element:Element)(e,t,n,r,o,s)}}),children:p.oneOfType([p.func.isRequired,p.element.isRequired]).isRequired,in:p.bool,mountOnEnter:p.bool,unmountOnExit:p.bool,appear:p.bool,enter:p.bool,exit:p.bool,timeout:function(t){var n=Hf;t.addEndListener||(n=n.isRequired);for(var r=arguments.length,o=new Array(r>1?r-1:0),s=1;se.scrollTop;function Ya(e,t){var n,r;const{timeout:o,easing:s,style:i={}}=e;return{duration:(n=i.transitionDuration)!=null?n:typeof o=="number"?o:o[t.mode]||0,easing:(r=i.transitionTimingFunction)!=null?r:typeof s=="object"?s[t.mode]:s,delay:i.transitionDelay}}const Kf=["addEndListener","appear","children","easing","in","onEnter","onEntered","onEntering","onExit","onExited","onExiting","style","timeout","TransitionComponent"];function oo(e){return`scale(${e}, ${e**2})`}const Jf={entering:{opacity:1,transform:oo(1)},entered:{opacity:1,transform:"none"}},Lr=typeof navigator<"u"&&/^((?!chrome|android).)*(safari|mobile)/i.test(navigator.userAgent)&&/(os |version\/)15(.|_)4/i.test(navigator.userAgent),Lo=M.forwardRef(function(t,n){const{addEndListener:r,appear:o=!0,children:s,easing:i,in:l,onEnter:c,onEntered:d,onEntering:u,onExit:h,onExited:w,onExiting:b,style:x,timeout:f="auto",TransitionComponent:m=Yf}=t,S=Ne(t,Kf),R=dn(),j=M.useRef(),E=_i(),v=M.useRef(null),P=yt(v,s.ref,n),V=Y=>F=>{if(Y){const te=v.current;F===void 0?Y(te):Y(te,F)}},U=V(u),C=V((Y,F)=>{Wf(Y);const{duration:te,delay:se,easing:oe}=Ya({style:x,timeout:f,easing:i},{mode:"enter"});let y;f==="auto"?(y=E.transitions.getAutoHeightDuration(Y.clientHeight),j.current=y):y=te,Y.style.transition=[E.transitions.create("opacity",{duration:y,delay:se}),E.transitions.create("transform",{duration:Lr?y:y*.666,delay:se,easing:oe})].join(","),c&&c(Y,F)}),_=V(d),k=V(b),D=V(Y=>{const{duration:F,delay:te,easing:se}=Ya({style:x,timeout:f,easing:i},{mode:"exit"});let oe;f==="auto"?(oe=E.transitions.getAutoHeightDuration(Y.clientHeight),j.current=oe):oe=F,Y.style.transition=[E.transitions.create("opacity",{duration:oe,delay:te}),E.transitions.create("transform",{duration:Lr?oe:oe*.666,delay:Lr?te:te||oe*.333,easing:se})].join(","),Y.style.opacity=0,Y.style.transform=oo(.75),h&&h(Y)}),$=V(w),J=Y=>{f==="auto"&&R.start(j.current||0,Y),r&&r(v.current,Y)};return a.jsx(m,O({appear:o,in:l,nodeRef:v,onEnter:C,onEntered:_,onEntering:U,onExit:D,onExited:$,onExiting:k,addEndListener:J,timeout:f==="auto"?null:f},S,{children:(Y,F)=>M.cloneElement(s,O({style:O({opacity:0,transform:oo(.75),visibility:Y==="exited"&&!l?"hidden":void 0},Jf[Y],x,s.props.style),ref:P},F))}))});process.env.NODE_ENV!=="production"&&(Lo.propTypes={addEndListener:p.func,appear:p.bool,children:ei.isRequired,easing:p.oneOfType([p.shape({enter:p.string,exit:p.string}),p.string]),in:p.bool,onEnter:p.func,onEntered:p.func,onEntering:p.func,onExit:p.func,onExited:p.func,onExiting:p.func,style:p.object,timeout:p.oneOfType([p.oneOf(["auto"]),p.number,p.shape({appear:p.number,enter:p.number,exit:p.number})])});Lo.muiSupportAuto=!0;const Wa=Lo,Zf=["anchorEl","component","components","componentsProps","container","disablePortal","keepMounted","modifiers","open","placement","popperOptions","popperRef","transition","slots","slotProps"],Qf=In(Oi,{name:"MuiPopper",slot:"Root",overridesResolver:(e,t)=>t.root})({}),Ii=M.forwardRef(function(t,n){var r;const o=wi(),s=Po({props:t,name:"MuiPopper"}),{anchorEl:i,component:l,components:c,componentsProps:d,container:u,disablePortal:h,keepMounted:w,modifiers:b,open:x,placement:f,popperOptions:m,popperRef:S,transition:R,slots:j,slotProps:E}=s,v=Ne(s,Zf),P=(r=j==null?void 0:j.root)!=null?r:c==null?void 0:c.Root,V=O({anchorEl:i,container:u,disablePortal:h,keepMounted:w,modifiers:b,open:x,placement:f,popperOptions:m,popperRef:S,transition:R},v);return a.jsx(Qf,O({as:l,direction:o==null?void 0:o.direction,slots:{root:P},slotProps:E??d},V,{ref:n}))});process.env.NODE_ENV!=="production"&&(Ii.propTypes={anchorEl:p.oneOfType([xn,p.object,p.func]),children:p.oneOfType([p.node,p.func]),component:p.elementType,components:p.shape({Root:p.elementType}),componentsProps:p.shape({root:p.oneOfType([p.func,p.object])}),container:p.oneOfType([xn,p.func]),disablePortal:p.bool,keepMounted:p.bool,modifiers:p.arrayOf(p.shape({data:p.object,effect:p.func,enabled:p.bool,fn:p.func,name:p.any,options:p.object,phase:p.oneOf(["afterMain","afterRead","afterWrite","beforeMain","beforeRead","beforeWrite","main","read","write"]),requires:p.arrayOf(p.string),requiresIfExists:p.arrayOf(p.string)})),open:p.bool.isRequired,placement:p.oneOf(["auto-end","auto-start","auto","bottom-end","bottom-start","bottom","left-end","left-start","left","right-end","right-start","right","top-end","top-start","top"]),popperOptions:p.shape({modifiers:p.array,onFirstUpdate:p.func,placement:p.oneOf(["auto-end","auto-start","auto","bottom-end","bottom-start","bottom","left-end","left-start","left","right-end","right-start","right","top-end","top-start","top"]),strategy:p.oneOf(["absolute","fixed"])}),popperRef:ni,slotProps:p.shape({root:p.oneOfType([p.func,p.object])}),slots:p.shape({root:p.elementType}),sx:p.oneOfType([p.arrayOf(p.oneOfType([p.func,p.object,p.bool])),p.func,p.object]),transition:p.bool});const Mi=Ii;function em(e){return ur("MuiTooltip",e)}const tm=ci("MuiTooltip",["popper","popperInteractive","popperArrow","popperClose","tooltip","tooltipArrow","touch","tooltipPlacementLeft","tooltipPlacementRight","tooltipPlacementTop","tooltipPlacementBottom","arrow"]),at=tm,nm=["arrow","children","classes","components","componentsProps","describeChild","disableFocusListener","disableHoverListener","disableInteractive","disableTouchListener","enterDelay","enterNextDelay","enterTouchDelay","followCursor","id","leaveDelay","leaveTouchDelay","onClose","onOpen","open","placement","PopperComponent","PopperProps","slotProps","slots","title","TransitionComponent","TransitionProps"];function rm(e){return Math.round(e*1e5)/1e5}const om=e=>{const{classes:t,disableInteractive:n,arrow:r,touch:o,placement:s}=e,i={popper:["popper",!n&&"popperInteractive",r&&"popperArrow"],tooltip:["tooltip",r&&"tooltipArrow",o&&"touch",`tooltipPlacement${Ye(s.split("-")[0])}`],arrow:["arrow"]};return ko(i,em,t)},am=In(Mi,{name:"MuiTooltip",slot:"Popper",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.popper,!n.disableInteractive&&t.popperInteractive,n.arrow&&t.popperArrow,!n.open&&t.popperClose]}})(({theme:e,ownerState:t,open:n})=>O({zIndex:(e.vars||e).zIndex.tooltip,pointerEvents:"none"},!t.disableInteractive&&{pointerEvents:"auto"},!n&&{pointerEvents:"none"},t.arrow&&{[`&[data-popper-placement*="bottom"] .${at.arrow}`]:{top:0,marginTop:"-0.71em","&::before":{transformOrigin:"0 100%"}},[`&[data-popper-placement*="top"] .${at.arrow}`]:{bottom:0,marginBottom:"-0.71em","&::before":{transformOrigin:"100% 0"}},[`&[data-popper-placement*="right"] .${at.arrow}`]:O({},t.isRtl?{right:0,marginRight:"-0.71em"}:{left:0,marginLeft:"-0.71em"},{height:"1em",width:"0.71em","&::before":{transformOrigin:"100% 100%"}}),[`&[data-popper-placement*="left"] .${at.arrow}`]:O({},t.isRtl?{left:0,marginLeft:"-0.71em"}:{right:0,marginRight:"-0.71em"},{height:"1em",width:"0.71em","&::before":{transformOrigin:"0 0"}})})),sm=In("div",{name:"MuiTooltip",slot:"Tooltip",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.tooltip,n.touch&&t.touch,n.arrow&&t.tooltipArrow,t[`tooltipPlacement${Ye(n.placement.split("-")[0])}`]]}})(({theme:e,ownerState:t})=>O({backgroundColor:e.vars?e.vars.palette.Tooltip.bg:mi(e.palette.grey[700],.92),borderRadius:(e.vars||e).shape.borderRadius,color:(e.vars||e).palette.common.white,fontFamily:e.typography.fontFamily,padding:"4px 8px",fontSize:e.typography.pxToRem(11),maxWidth:300,margin:2,wordWrap:"break-word",fontWeight:e.typography.fontWeightMedium},t.arrow&&{position:"relative",margin:0},t.touch&&{padding:"8px 16px",fontSize:e.typography.pxToRem(14),lineHeight:`${rm(16/14)}em`,fontWeight:e.typography.fontWeightRegular},{[`.${at.popper}[data-popper-placement*="left"] &`]:O({transformOrigin:"right center"},t.isRtl?O({marginLeft:"14px"},t.touch&&{marginLeft:"24px"}):O({marginRight:"14px"},t.touch&&{marginRight:"24px"})),[`.${at.popper}[data-popper-placement*="right"] &`]:O({transformOrigin:"left center"},t.isRtl?O({marginRight:"14px"},t.touch&&{marginRight:"24px"}):O({marginLeft:"14px"},t.touch&&{marginLeft:"24px"})),[`.${at.popper}[data-popper-placement*="top"] &`]:O({transformOrigin:"center bottom",marginBottom:"14px"},t.touch&&{marginBottom:"24px"}),[`.${at.popper}[data-popper-placement*="bottom"] &`]:O({transformOrigin:"center top",marginTop:"14px"},t.touch&&{marginTop:"24px"})})),im=In("span",{name:"MuiTooltip",slot:"Arrow",overridesResolver:(e,t)=>t.arrow})(({theme:e})=>({overflow:"hidden",position:"absolute",width:"1em",height:"0.71em",boxSizing:"border-box",color:e.vars?e.vars.palette.Tooltip.bg:mi(e.palette.grey[700],.9),"&::before":{content:'""',margin:"auto",display:"block",width:"100%",height:"100%",backgroundColor:"currentColor",transform:"rotate(45deg)"}}));let Gn=!1;const Ka=new On;let sn={x:0,y:0};function Un(e,t){return n=>{t&&t(n),e(n)}}const $i=M.forwardRef(function(t,n){var r,o,s,i,l,c,d,u,h,w,b,x,f,m,S,R,j,E,v;const P=Po({props:t,name:"MuiTooltip"}),{arrow:V=!1,children:U,components:C={},componentsProps:_={},describeChild:k=!1,disableFocusListener:D=!1,disableHoverListener:$=!1,disableInteractive:J=!1,disableTouchListener:Y=!1,enterDelay:F=100,enterNextDelay:te=0,enterTouchDelay:se=700,followCursor:oe=!1,id:y,leaveDelay:T=0,leaveTouchDelay:z=1500,onClose:L,onOpen:B,open:X,placement:q="bottom",PopperComponent:H,PopperProps:G={},slotProps:K={},slots:Z={},title:ue,TransitionComponent:I=Wa,TransitionProps:ye}=P,A=Ne(P,nm),xe=M.isValidElement(U)?U:a.jsx("span",{children:U}),Ge=_i(),lt=Ge.direction==="rtl",[Ee,Dn]=M.useState(),[Ue,Et]=M.useState(null),ct=M.useRef(!1),jt=J||oe,Ct=dn(),Tt=dn(),dt=dn(),Jt=dn(),[An,Go]=oi({controlled:X,default:!1,name:"Tooltip",state:"open"});let Ke=An;if(process.env.NODE_ENV!=="production"){const{current:ee}=M.useRef(X!==void 0);M.useEffect(()=>{Ee&&Ee.disabled&&!ee&&ue!==""&&Ee.tagName.toLowerCase()==="button"&&console.error(["MUI: You are providing a disabled `button` child to the Tooltip component.","A disabled element does not fire events.","Tooltip needs to listen to the child element's events to display the title.","","Add a simple wrapper element, such as a `span`."].join(` +`))},[ue,Ee,ee])}const kr=ri(y),Zt=M.useRef(),Bn=Zr(()=>{Zt.current!==void 0&&(document.body.style.WebkitUserSelect=Zt.current,Zt.current=void 0),Jt.clear()});M.useEffect(()=>Bn,[Bn]);const Uo=ee=>{Ka.clear(),Gn=!0,Go(!0),B&&!Ke&&B(ee)},Vn=Zr(ee=>{Ka.start(800+T,()=>{Gn=!1}),Go(!1),L&&Ke&&L(ee),Ct.start(Ge.transitions.duration.shortest,()=>{ct.current=!1})}),Sr=ee=>{ct.current&&ee.type!=="touchstart"||(Ee&&Ee.removeAttribute("title"),Tt.clear(),dt.clear(),F||Gn&&te?Tt.start(Gn?te:F,()=>{Uo(ee)}):Uo(ee))},qo=ee=>{Tt.clear(),dt.start(T,()=>{Vn(ee)})},{isFocusVisibleRef:Ho,onBlur:rl,onFocus:ol,ref:al}=ai(),[,Xo]=M.useState(!1),Yo=ee=>{rl(ee),Ho.current===!1&&(Xo(!1),qo(ee))},Wo=ee=>{Ee||Dn(ee.currentTarget),ol(ee),Ho.current===!0&&(Xo(!0),Sr(ee))},Ko=ee=>{ct.current=!0;const _e=xe.props;_e.onTouchStart&&_e.onTouchStart(ee)},Jo=Sr,Zo=qo,sl=ee=>{Ko(ee),dt.clear(),Ct.clear(),Bn(),Zt.current=document.body.style.WebkitUserSelect,document.body.style.WebkitUserSelect="none",Jt.start(se,()=>{document.body.style.WebkitUserSelect=Zt.current,Sr(ee)})},il=ee=>{xe.props.onTouchEnd&&xe.props.onTouchEnd(ee),Bn(),dt.start(z,()=>{Vn(ee)})};M.useEffect(()=>{if(!Ke)return;function ee(_e){(_e.key==="Escape"||_e.key==="Esc")&&Vn(_e)}return document.addEventListener("keydown",ee),()=>{document.removeEventListener("keydown",ee)}},[Vn,Ke]);const ll=yt(xe.ref,al,Dn,n);!ue&&ue!==0&&(Ke=!1);const Er=M.useRef(),cl=ee=>{const _e=xe.props;_e.onMouseMove&&_e.onMouseMove(ee),sn={x:ee.clientX,y:ee.clientY},Er.current&&Er.current.update()},Qt={},jr=typeof ue=="string";k?(Qt.title=!Ke&&jr&&!$?ue:null,Qt["aria-describedby"]=Ke?kr:null):(Qt["aria-label"]=jr?ue:null,Qt["aria-labelledby"]=Ke&&!jr?kr:null);const De=O({},Qt,A,xe.props,{className:ot(A.className,xe.props.className),onTouchStart:Ko,ref:ll},oe?{onMouseMove:cl}:{});process.env.NODE_ENV!=="production"&&(De["data-mui-internal-clone-element"]=!0,M.useEffect(()=>{Ee&&!Ee.getAttribute("data-mui-internal-clone-element")&&console.error(["MUI: The `children` component of the Tooltip is not forwarding its props correctly.","Please make sure that props are spread on the same element that the ref is applied to."].join(` +`))},[Ee]));const en={};Y||(De.onTouchStart=sl,De.onTouchEnd=il),$||(De.onMouseOver=Un(Jo,De.onMouseOver),De.onMouseLeave=Un(Zo,De.onMouseLeave),jt||(en.onMouseOver=Jo,en.onMouseLeave=Zo)),D||(De.onFocus=Un(Wo,De.onFocus),De.onBlur=Un(Yo,De.onBlur),jt||(en.onFocus=Wo,en.onBlur=Yo)),process.env.NODE_ENV!=="production"&&xe.props.title&&console.error(["MUI: You have provided a `title` prop to the child of .",`Remove this title prop \`${xe.props.title}\` or the Tooltip component.`].join(` +`));const dl=M.useMemo(()=>{var ee;let _e=[{name:"arrow",enabled:!!Ue,options:{element:Ue,padding:4}}];return(ee=G.popperOptions)!=null&&ee.modifiers&&(_e=_e.concat(G.popperOptions.modifiers)),O({},G.popperOptions,{modifiers:_e})},[Ue,G]),tn=O({},P,{isRtl:lt,arrow:V,disableInteractive:jt,placement:q,PopperComponentProp:H,touch:ct.current}),Cr=om(tn),Qo=(r=(o=Z.popper)!=null?o:C.Popper)!=null?r:am,ea=(s=(i=(l=Z.transition)!=null?l:C.Transition)!=null?i:I)!=null?s:Wa,ta=(c=(d=Z.tooltip)!=null?d:C.Tooltip)!=null?c:sm,na=(u=(h=Z.arrow)!=null?h:C.Arrow)!=null?u:im,ul=un(Qo,O({},G,(w=K.popper)!=null?w:_.popper,{className:ot(Cr.popper,G==null?void 0:G.className,(b=(x=K.popper)!=null?x:_.popper)==null?void 0:b.className)}),tn),pl=un(ea,O({},ye,(f=K.transition)!=null?f:_.transition),tn),wl=un(ta,O({},(m=K.tooltip)!=null?m:_.tooltip,{className:ot(Cr.tooltip,(S=(R=K.tooltip)!=null?R:_.tooltip)==null?void 0:S.className)}),tn),fl=un(na,O({},(j=K.arrow)!=null?j:_.arrow,{className:ot(Cr.arrow,(E=(v=K.arrow)!=null?v:_.arrow)==null?void 0:E.className)}),tn);return a.jsxs(M.Fragment,{children:[M.cloneElement(xe,De),a.jsx(Qo,O({as:H??Mi,placement:q,anchorEl:oe?{getBoundingClientRect:()=>({top:sn.y,left:sn.x,right:sn.x,bottom:sn.y,width:0,height:0})}:Ee,popperRef:Er,open:Ee?Ke:!1,id:kr,transition:!0},en,ul,{popperOptions:dl,children:({TransitionProps:ee})=>a.jsx(ea,O({timeout:Ge.transitions.duration.shorter},ee,pl,{children:a.jsxs(ta,O({},wl,{children:[ue,V?a.jsx(na,O({},fl,{ref:Et})):null]}))}))}))]})});process.env.NODE_ENV!=="production"&&($i.propTypes={arrow:p.bool,children:ei.isRequired,classes:p.object,className:p.string,components:p.shape({Arrow:p.elementType,Popper:p.elementType,Tooltip:p.elementType,Transition:p.elementType}),componentsProps:p.shape({arrow:p.object,popper:p.object,tooltip:p.object,transition:p.object}),describeChild:p.bool,disableFocusListener:p.bool,disableHoverListener:p.bool,disableInteractive:p.bool,disableTouchListener:p.bool,enterDelay:p.number,enterNextDelay:p.number,enterTouchDelay:p.number,followCursor:p.bool,id:p.string,leaveDelay:p.number,leaveTouchDelay:p.number,onClose:p.func,onOpen:p.func,open:p.bool,placement:p.oneOf(["bottom-end","bottom-start","bottom","left-end","left-start","left","right-end","right-start","right","top-end","top-start","top"]),PopperComponent:p.elementType,PopperProps:p.object,slotProps:p.shape({arrow:p.object,popper:p.object,tooltip:p.object,transition:p.object}),slots:p.shape({arrow:p.elementType,popper:p.elementType,tooltip:p.elementType,transition:p.elementType}),sx:p.oneOfType([p.arrayOf(p.oneOfType([p.func,p.object,p.bool])),p.func,p.object]),title:p.node,TransitionComponent:p.elementType,TransitionProps:p.object});const lm=$i;function Ja(e,t,n){return e?a.jsx(Me.ListItemIcon,{className:`papi-menu-icon-${n?"leading":"trailing"}`,children:a.jsx("img",{src:e,alt:`${n?"Leading":"Trailing"} icon for ${t}`})}):void 0}function Fo(e){const{onClick:t,label:n,tooltip:r,allowForLeadingIcons:o=!0,iconPathBefore:s=void 0,iconPathAfter:i=void 0,hasAutoFocus:l=!1,className:c,isDisabled:d=!1,isDense:u=!0,isSubMenuParent:h=!1,hasDisabledGutters:w=!1,hasDivider:b=!1,focusVisibleClassName:x,id:f,children:m}=e,S=a.jsx(Me.MenuItem,{sx:{lineHeight:.8},autoFocus:l,className:c,disabled:d,dense:u,disableGutters:w,divider:b,focusVisibleClassName:x,onClick:t,id:f,children:n?a.jsxs(a.Fragment,{children:[Ja(s,n,!0),a.jsx(Me.ListItemText,{primary:n,inset:!s&&o}),h?a.jsx(Me.ListItemIcon,{className:"papi-menu-icon-trailing",children:a.jsx(gi,{})}):Ja(i,n,!1)]}):m});return r?a.jsx(lm,{title:r,placement:"right",children:a.jsx("div",{children:S})}):S}function Di(e){return Object.entries(e.groups).map(([n,r])=>({id:n,group:r}))}function cm(e){const[t,n]=g.useState(void 0),{parentMenuItem:r,parentItemProps:o,menuDefinition:s}=e,i=d=>{n(d.currentTarget)},l=()=>{n(void 0)},c=()=>{let d=Di(s).filter(u=>"menuItem"in u.group);if(!(r!=null&&r.id))throw new Error("A valid parent menu item is required for submenus.");return d=d.filter(u=>"menuItem"in u.group&&u.group.menuItem===r.id),a.jsx(Ai,{...e,includedGroups:d})};return a.jsxs(a.Fragment,{children:[a.jsx(Fo,{onClick:i,...o,isSubMenuParent:!0}),a.jsx(Me.Menu,{anchorEl:t,open:!!t,onClose:l,anchorOrigin:{vertical:"top",horizontal:"right"},transformOrigin:{vertical:"top",horizontal:"left"},children:c()},r.id)]})}const dm=(e,t)=>t.filter(o=>o.group===e).sort((o,s)=>(o.order||0)-(s.order||0));function Ai(e){const{menuDefinition:t,onClick:n,commandHandler:r,includedGroups:o}=e,{items:s,allowForLeadingIcons:i}=g.useMemo(()=>{const u=o&&o.length>0?o:Di(t).filter(x=>!("menuItem"in x.group)),h=Object.values(u).sort((x,f)=>(x.group.order||0)-(f.group.order||0)),w=[];h.forEach(x=>{dm(x.id,t.items).forEach(f=>w.push({item:f,isLastItemInGroup:!1})),w.length>0&&(w[w.length-1].isLastItemInGroup=!0)}),w.length>0&&(w[w.length-1].isLastItemInGroup=!1);const b=w.some(x=>"iconPathBefore"in x.item&&x.item.iconPathBefore);return{items:w,allowForLeadingIcons:b}},[o,t]),l=({item:u,isLastItemInGroup:h})=>({className:"papi-menu-item",label:u.label,tooltip:u.tooltip,iconPathBefore:"iconPathBefore"in u?u.iconPathBefore:void 0,iconPathAfter:"iconPathAfter"in u?u.iconPathAfter:void 0,hasDivider:h,allowForLeadingIcons:i}),[c]=s;if(!c)return a.jsx("div",{});const d=c.item.group;return a.jsx("div",{role:"menu","aria-label":d,children:s.map((u,h)=>{const{item:w}=u,b=l(u);if("command"in w){const x=w.group+h;return a.jsx(Fo,{onClick:f=>{n==null||n(f),r(w)},...b},x)}return a.jsx(cm,{parentMenuItem:w,parentItemProps:b,...e},d+w.id)})},d)}function um(e){const{menuDefinition:t,columnId:n}=e;let s=Object.entries(t.groups).map(([i,l])=>({id:i,group:l})).filter(i=>"column"in i.group);return n&&"columns"in t&&t.columns[n]&&(s=s.filter(i=>"column"in i.group&&i.group.column===n)),a.jsx(Ai,{...e,includedGroups:s})}function pm({commandHandler:e,menuDefinition:t,id:n,metadata:r,onClick:o,className:s}){return a.jsxs(Me.Grid,{id:n,item:!0,xs:"auto",role:"menu","aria-label":n,className:`papi-menu-column ${s??""}`,children:[a.jsx("h3",{"aria-label":r.label,className:`papi-menu-column-header ${s??""}`,children:r.label}),a.jsx(Me.List,{id:n,dense:!0,className:s??"",children:a.jsx(um,{commandHandler:e,menuDefinition:t,columnId:n,onClick:o})})]})}function Bi({commandHandler:e,className:t,multiColumnMenu:n,id:r}){const{columns:o}=n,s=g.useMemo(()=>{const i=new Map;return Object.getOwnPropertyNames(o).forEach(l=>{if(l==="isExtensible")return;const c=l,d=o[c];typeof d=="object"&&typeof d.order=="number"&&!Number.isNaN(d.order)?i.set(d.order,{id:c,metadata:d}):console.warn(`Property ${l} (${typeof d}) on menu ${r} is not a valid column and is being ignored. This might indicate data corruption`)}),Array.from(i.values()).sort((l,c)=>(l.metadata.order||0)-(c.metadata.order||0))},[o,r]);return a.jsx(Me.Grid,{container:!0,spacing:0,className:`papi-multi-column-menu ${t??""}`,columns:s.length,role:"menu","aria-label":"GridMenu",id:r,children:s.map((i,l)=>a.jsx(pm,{commandHandler:e,menuDefinition:n,...i,className:t},l))})}function wm(e){return{preserveValue:!0,...e}}const nr=(e,t,n={})=>{const r=g.useRef(t);r.current=t;const o=g.useRef(n);o.current=wm(o.current);const[s,i]=g.useState(()=>r.current),[l,c]=g.useState(!0);return g.useEffect(()=>{let d=!0;return c(!!e),(async()=>{if(e){const u=await e();d&&(i(()=>u),c(!1))}})(),()=>{d=!1,o.current.preserveValue||i(()=>r.current)}},[e]),[s,l]},fm=hi(a.jsx("path",{d:"M3 18h18v-2H3zm0-5h18v-2H3zm0-7v2h18V6z"}),"Menu");function Vi({menuProvider:e,normalMenu:t,fullMenu:n,commandHandler:r,containerRef:o,className:s,ariaLabelPrefix:i,children:l}){const[c,d]=g.useState(!1),[u,h]=g.useState(!1),w=g.useCallback(()=>{c&&d(!1),h(!1)},[c]),b=g.useCallback(E=>{E.stopPropagation(),d(v=>{const P=!v;return P&&E.shiftKey?h(!0):P||h(!1),P})},[]),x=g.useCallback(E=>(w(),r(E)),[r,w]),[f,m]=g.useState({top:1,left:1});g.useEffect(()=>{if(c){const E=o==null?void 0:o.current;if(E){const v=E.getBoundingClientRect(),P=window.scrollY,V=window.scrollX,U=v.top+P+E.clientHeight,C=v.left+V;m({top:U,left:C})}}},[c,o]);const[S]=nr(g.useCallback(async()=>(e==null?void 0:e(!1))??t,[e,t,c]),t),[R]=nr(g.useCallback(async()=>(e==null?void 0:e(!0))??n??S,[e,n,S,c]),n??S),j=u&&R?R:S;return a.jsxs(a.Fragment,{children:[a.jsx(Me.IconButton,{sx:{paddingTop:0,paddingBottom:0},edge:"start",className:`papi-menuButton ${s??""}`,color:"inherit","aria-label":`${i??""} menu button`,onClick:b,children:l??a.jsx(fm,{})}),a.jsx(Me.Drawer,{className:`papi-menu-drawer ${s??""}`,anchor:"left",variant:"temporary",open:c,onClose:w,PaperProps:{className:"papi-menu-drawer-paper",style:{top:f.top,left:f.left}},children:j?a.jsx(Bi,{className:s,id:`${i??""} main menu`,commandHandler:x,multiColumnMenu:j}):void 0})]})}function mm({id:e,label:t,isDisabled:n=!1,tooltip:r,isTooltipSuppressed:o=!1,adjustMarginToAlignToEdge:s=!1,size:i="medium",className:l,onClick:c,children:d}){return a.jsx(Me.IconButton,{id:e,disabled:n,edge:s,size:i,"aria-label":t,title:o?void 0:r??t,className:`papi-icon-button ${l??""}`,onClick:c,children:d})}const Kt=g.forwardRef(({className:e,...t},n)=>a.jsx(Q.LoaderCircle,{size:35,className:N("tw-animate-spin",e),...t,ref:n}));Kt.displayName="Spinner";function hm({id:e,isDisabled:t=!1,hasError:n=!1,isFullWidth:r=!1,helperText:o,label:s,placeholder:i,isRequired:l=!1,className:c,defaultValue:d,value:u,onChange:h,onFocus:w,onBlur:b}){return a.jsxs("div",{className:N("tw-inline-grid tw-items-center tw-gap-1.5",{"tw-w-full":r}),children:[a.jsx(qe,{htmlFor:e,className:N({"tw-text-red-600":n,"tw-hidden":!s}),children:`${s}${l?"*":""}`}),a.jsx(St,{id:e,disabled:t,placeholder:i,required:l,className:N(c,{"tw-border-red-600":n}),defaultValue:d,value:u,onChange:h,onFocus:w,onBlur:b}),a.jsx("p",{className:N({"tw-hidden":!o}),children:o})]})}function gm({menuProvider:e,commandHandler:t,className:n,id:r,children:o}){const s=g.useRef(void 0);return a.jsx("div",{ref:s,style:{position:"relative"},children:a.jsx(Me.AppBar,{position:"static",id:r,children:a.jsxs(Me.Toolbar,{className:N("tw-bg-muted tw-text-muted-foreground",n),variant:"dense",children:[e?a.jsx(Vi,{commandHandler:t,containerRef:s,menuProvider:e}):void 0,o?a.jsx("div",{className:"papi-toolbar-children",children:o}):void 0]})})})}const bm=Xt.cva("tw-relative tw-w-full tw-rounded-lg tw-border tw-p-4 [&>svg~*]:tw-pl-7 [&>svg+div]:tw-translate-y-[-3px] [&>svg]:tw-absolute [&>svg]:tw-left-4 [&>svg]:tw-top-4 [&>svg]:tw-text-foreground",{variants:{variant:{default:"tw-bg-background tw-text-foreground",destructive:"tw-border-destructive/50 tw-text-destructive dark:tw-border-destructive [&>svg]:tw-text-destructive"}},defaultVariants:{variant:"default"}}),zi=g.forwardRef(({className:e,variant:t,...n},r)=>a.jsx("div",{ref:r,role:"alert",className:N(bm({variant:t}),e),...n}));zi.displayName="Alert";const Li=g.forwardRef(({className:e,...t},n)=>a.jsxs("h5",{ref:n,className:N("tw-mb-1 tw-font-medium tw-leading-none tw-tracking-tight",e),...t,children:[t.children," "]}));Li.displayName="AlertTitle";const Fi=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,className:N("tw-text-sm [&_p]:tw-leading-relaxed",e),...t}));Fi.displayName="AlertDescription";const Gi=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,className:N("pr-twp tw-rounded-lg tw-border tw-bg-card tw-text-card-foreground tw-shadow-sm",e),...t}));Gi.displayName="Card";const Ui=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,className:N("pr-twp tw-flex tw-flex-col tw-space-y-1.5 tw-p-6",e),...t}));Ui.displayName="CardHeader";const qi=g.forwardRef(({className:e,...t},n)=>a.jsx("h3",{ref:n,className:N("pr-twp tw-text-2xl tw-font-semibold tw-leading-none tw-tracking-tight",e),...t,children:t.children}));qi.displayName="CardTitle";const Hi=g.forwardRef(({className:e,...t},n)=>a.jsx("p",{ref:n,className:N("pr-twp tw-text-sm tw-text-muted-foreground",e),...t}));Hi.displayName="CardDescription";const Xi=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,className:N("pr-twp tw-p-6 tw-pt-0",e),...t}));Xi.displayName="CardContent";const Yi=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,className:N("pr-twp tw-flex tw-items-center tw-p-6 tw-pt-0",e),...t}));Yi.displayName="CardFooter";function vm({...e}){return a.jsx(Qa.Toaster,{className:"tw-toaster tw-group",toastOptions:{classNames:{toast:"group toast group-[.toaster]:bg-background group-[.toaster]:text-foreground group-[.toaster]:border-border group-[.toaster]:shadow-lg",description:"group-[.toast]:text-muted-foreground",actionButton:"group-[.toast]:bg-primary group-[.toast]:text-primary-foreground",cancelButton:"group-[.toast]:bg-muted group-[.toast]:text-muted-foreground"}},...e})}const Wi=g.forwardRef(({className:e,...t},n)=>a.jsxs(cn.Root,{ref:n,className:N("pr-twp tw-relative tw-flex tw-w-full tw-touch-none tw-select-none tw-items-center",e),...t,children:[a.jsx(cn.Track,{className:"tw-relative tw-h-2 tw-w-full tw-grow tw-overflow-hidden tw-rounded-full tw-bg-secondary",children:a.jsx(cn.Range,{className:"tw-absolute tw-h-full tw-bg-primary"})}),a.jsx(cn.Thumb,{className:"tw-block tw-h-5 tw-w-5 tw-rounded-full tw-border-2 tw-border-primary tw-bg-background tw-ring-offset-background tw-transition-colors focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50"})]}));Wi.displayName=cn.Root.displayName;const Ki=g.forwardRef(({className:e,...t},n)=>a.jsx(qr.Root,{className:N("tw-peer pr-twp tw-inline-flex tw-h-6 tw-w-11 tw-shrink-0 tw-cursor-pointer tw-items-center tw-rounded-full tw-border-2 tw-border-transparent tw-transition-colors focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 focus-visible:tw-ring-offset-background disabled:tw-cursor-not-allowed disabled:tw-opacity-50 data-[state=checked]:tw-bg-primary data-[state=unchecked]:tw-bg-input",e),...t,ref:n,children:a.jsx(qr.Thumb,{className:N("pr-twp tw-pointer-events-none tw-block tw-h-5 tw-w-5 tw-rounded-full tw-bg-background tw-shadow-lg tw-ring-0 tw-transition-transform data-[state=checked]:tw-translate-x-5 data-[state=unchecked]:tw-translate-x-0")})}));Ki.displayName=qr.Root.displayName;const xm=Oe.Root,Ji=g.forwardRef(({className:e,...t},n)=>a.jsx(Oe.List,{ref:n,className:N("tw-inline-flex tw-h-10 tw-items-center tw-justify-center tw-rounded-md tw-bg-muted tw-p-1 tw-text-muted-foreground",e),...t}));Ji.displayName=Oe.List.displayName;const Zi=g.forwardRef(({className:e,...t},n)=>a.jsx(Oe.Trigger,{ref:n,className:N("tw-inline-flex tw-items-center tw-justify-center tw-whitespace-nowrap tw-rounded-sm tw-px-3 tw-py-1.5 tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-all hover:tw-text-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50 data-[state=active]:tw-bg-background data-[state=active]:tw-text-foreground data-[state=active]:tw-shadow-sm",e),...t}));Zi.displayName=Oe.Trigger.displayName;const Qi=g.forwardRef(({className:e,...t},n)=>a.jsx(Oe.Content,{ref:n,className:N("tw-mt-2 tw-ring-offset-background focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2",e),...t}));Qi.displayName=Oe.Content.displayName;function ym({isInstalling:e,handleClick:t,buttonText:n,className:r,...o}){return a.jsx(fe,{className:N("tw-h-8 tw-rounded-md tw-text-white tw-transition tw-duration-300 tw-ease-in-out hover:tw-bg-blue-700",{"tw-cursor-not-allowed tw-bg-blue-700":e,"tw-bg-blue-600":!e,"tw-bg-white tw-text-blue-600 hover:tw-text-white":!n,"tw-w-20":n},r),onClick:t,...o,children:e?a.jsx(Kt,{size:15}):a.jsxs(a.Fragment,{children:[a.jsx(Q.Download,{size:25,className:N("tw-h-4 tw-w-4",{"tw-mr-1":n})}),n]})})}function Nm({isEnabling:e,handleClick:t,className:n,...r}){return a.jsx(fe,{className:N("tw-h-8 tw-rounded-md tw-bg-blue-600 tw-px-4 tw-text-white tw-transition tw-duration-300 tw-ease-in-out hover:tw-bg-blue-700",{"tw-cursor-not-allowed tw-bg-blue-700":e},n),onClick:t,...r,children:e?a.jsxs(a.Fragment,{children:[a.jsx(Kt,{size:15,className:"tw-mr-1 tw-text-white"}),"Enabling..."]}):"Enable"})}function km({isDisabling:e,handleClick:t,className:n,...r}){return a.jsx(fe,{className:N("tw-h-8 tw-rounded-md tw-bg-gray-300 tw-text-black tw-transition tw-duration-300 tw-ease-in-out hover:tw-bg-gray-400",{"tw-cursor-not-allowed tw-bg-gray-400":e},n),onClick:t,...r,children:e?a.jsxs(a.Fragment,{children:[a.jsx(Kt,{size:15,className:"tw-mr-1 tw-text-black"}),"Disabling..."]}):"Disable"})}function Sm({isUpdating:e,handleClick:t,className:n,...r}){return a.jsx(fe,{className:N("tw-h-8 tw-rounded-md tw-bg-blue-600 tw-px-4 tw-text-white tw-transition tw-duration-300 tw-ease-in-out hover:tw-bg-blue-700 hover:tw-text-white",{"tw-cursor-not-allowed tw-bg-blue-700":e},n),onClick:t,...r,children:e?a.jsxs(a.Fragment,{children:[a.jsx(Kt,{size:15,className:"tw-mr-1 tw-text-white"}),"Updating..."]}):"Update"})}function Em({id:e,markdown:t,className:n,anchorTarget:r}){const o=g.useMemo(()=>({overrides:{a:{props:{target:r}}}}),[r]);return a.jsx("div",{id:e,className:N("pr-twp tw-prose",n),children:a.jsx(Rl,{options:o,children:t})})}const el=g.forwardRef((e,t)=>a.jsxs(fe,{ref:t,className:"tw-rounded-md tw-border tw-border-dashed tw-border-gray-400 tw-bg-white tw-px-4 tw-py-2 tw-text-black tw-transition tw-duration-300 tw-ease-in-out hover:tw-border-blue-600 hover:tw-bg-white hover:tw-text-blue-600",...e,children:[a.jsx(Q.Filter,{size:16,className:"tw-mr-2 tw-h-4 tw-w-4 tw-text-gray-700 hover:tw-text-blue-600"}),"Filter",a.jsx(Q.ChevronDown,{size:16,className:"tw-ml-2 tw-h-4 tw-w-4 tw-text-gray-700 hover:tw-text-blue-600"})]}));var tl=(e=>(e[e.Check=0]="Check",e[e.Radio=1]="Radio",e))(tl||{});function jm({id:e,groups:t}){return a.jsx("div",{id:e,children:a.jsxs(or,{children:[a.jsx(lo,{asChild:!0,children:a.jsx(el,{})}),a.jsx(En,{children:t.map(n=>a.jsxs("div",{children:[a.jsx(Wt,{children:n.label}),a.jsx(cs,{children:n.items.map(r=>a.jsx("div",{children:r.itemType===0?a.jsx(ar,{onClick:r.onClick,children:r.label}):a.jsx(uo,{onClick:r.onClick,value:r.label,children:r.label})},r.label))}),a.jsx(jn,{})]},n.label))})]})})}function Cm({id:e,message:t}){return a.jsx("div",{id:e,className:"tw-mb-20 tw-mt-20 tw-flex tw-items-center tw-justify-center",children:a.jsx("div",{className:"tw-w-3/4 tw-rounded-lg tw-bg-gray-100 tw-p-8 tw-text-center",children:a.jsx("p",{className:"tw-text-lg tw-text-gray-800",children:t})})})}function Tm({id:e,category:t,downloads:n,languages:r,moreInfoUrl:o}){const s=new W.NumberFormat("en",{notation:"compact",compactDisplay:"short"}).format(Object.values(n).reduce((l,c)=>l+c,0)),i=()=>{window.scrollTo(0,document.body.scrollHeight)};return a.jsxs("div",{id:e,className:"tw-flex tw-flex-wrap tw-items-start tw-space-x-4 tw-border-b tw-border-t tw-bg-white tw-pb-4 tw-pt-4",children:[a.jsxs("div",{className:"tw-flex tw-flex-col tw-items-center",children:[a.jsx("div",{className:"tw-flex tw-items-center tw-rounded-md tw-bg-gray-100 tw-px-2 tw-py-1",children:a.jsx("span",{className:"tw-text-xs tw-font-semibold tw-text-gray-700",children:t})}),a.jsx("span",{className:"tw-text-xs tw-text-gray-500",children:"CATEGORY"})]}),a.jsx("div",{className:"tw-mx-2 tw-h-10 tw-border-l tw-border-gray-300"}),a.jsxs("div",{className:"tw-flex tw-flex-col tw-items-center",children:[a.jsxs("div",{className:"tw-flex tw-items-center tw-rounded-md tw-bg-gray-100 tw-px-2 tw-py-1",children:[a.jsx(Q.User,{className:"tw-mr-1 tw-h-4 tw-w-4"}),a.jsx("span",{className:"tw-text-xs tw-font-semibold tw-text-gray-700",children:s})]}),a.jsx("span",{className:"tw-text-xs tw-text-gray-500",children:"USERS"})]}),a.jsx("div",{className:"tw-mx-2 tw-h-10 tw-border-l tw-border-gray-300"}),a.jsxs("div",{className:"tw-flex tw-flex-col tw-items-center",children:[a.jsx("div",{className:"tw-flex tw-items-center",children:r.slice(0,3).map(l=>a.jsx("span",{className:"tw-ml-1 tw-rounded-md tw-bg-gray-100 tw-px-2 tw-py-1 tw-text-xs tw-font-semibold tw-text-gray-700",children:l.toUpperCase()},l))}),r.length>3&&a.jsxs("button",{type:"button",onClick:()=>i(),className:"tw-text-xs tw-text-gray-500 tw-underline",children:["+",r.length-3," more languages"]})]}),a.jsx("div",{className:"tw-mx-2 tw-h-10 tw-border-l tw-border-gray-300"}),a.jsxs("div",{className:"tw-ml-auto tw-flex tw-flex-col tw-space-y-2",children:[a.jsxs("a",{href:o,target:"_blank",rel:"noreferrer",className:"tw-flex tw-items-center tw-text-xs tw-font-semibold tw-text-gray-500 tw-underline",children:["Website",a.jsx(Q.Link,{className:"tw-ml-1 tw-inline tw-h-4 tw-w-4"})]}),a.jsxs("a",{href:"https://example.com",target:"_blank",rel:"noreferrer",className:"tw-flex tw-items-center tw-text-xs tw-font-semibold tw-text-gray-500 tw-underline",children:["Support",a.jsx(Q.CircleHelp,{className:"tw-ml-1 tw-inline tw-h-4 tw-w-4"})]})]})]})}function nl({id:e,versionHistory:t}){const[n,r]=g.useState(!1),o=new Date;function s(l){const c=new Date(l),d=new Date(o.getTime()-c.getTime()),u=d.getUTCFullYear()-1970,h=d.getUTCMonth(),w=d.getUTCDate()-1;let b="";return u>0?b=`${u.toString()} year${u===1?"":"s"} ago`:h>0?b=`${h.toString()} month${h===1?"":"s"} ago`:w===0?b="today":b=`${w.toString()} day${w===1?"":"s"} ago`,b}const i=Object.entries(t).sort((l,c)=>c[0].localeCompare(l[0]));return a.jsxs("div",{id:e,children:[a.jsx("h3",{className:"tw-text-md tw-font-semibold",children:"What`s New"}),a.jsx("ul",{className:"tw-list-disc tw-pl-5 tw-pr-4 tw-text-xs tw-text-gray-600",children:(n?i:i.slice(0,5)).map(l=>a.jsxs("div",{className:"tw-mt-3 tw-flex tw-justify-between",children:[a.jsx("div",{className:"tw-text-gray-600",children:a.jsx("li",{className:"tw-prose tw-text-xs",children:a.jsx("span",{children:l[1].description})})}),a.jsxs("div",{className:"tw-justify-end tw-text-right",children:[a.jsxs("div",{children:["Version ",l[0]]}),a.jsx("div",{children:s(l[1].date)})]})]},l[0]))}),i.length>5&&a.jsx("button",{type:"button",onClick:()=>r(!n),className:"tw-text-xs tw-text-gray-500 tw-underline",children:n?"Show Less Version History":"Show All Version History"})]})}function Rm({id:e,publisherDisplayName:t,fileSize:n,locales:r,versionHistory:o}){const s=g.useMemo(()=>W.formatBytes(n),[n]),l=(c=>{const d=new Intl.DisplayNames(navigator.language,{type:"language"});return c.map(u=>d.of(u))})(r);return a.jsx("div",{id:e,className:"tw-border-t tw-pb-4 tw-pt-4",children:a.jsxs("div",{className:"tw-md:flex-row tw-md:space-x-8 tw-flex tw-flex-col tw-space-x-0",children:[a.jsx(nl,{versionHistory:o}),a.jsx("div",{className:"tw-md:border-t-0 tw-md:border-l tw-md-h-auto tw-md-ml-8 tw-mt-4 tw-border-t tw-border-gray-300"}),a.jsxs("div",{className:"tw-md:mt-0 tw-mt-4 tw-flex-1 tw-space-y-3",children:[a.jsx("h2",{className:"tw-text-md tw-font-semibold",children:"Information"}),a.jsxs("div",{className:"tw-flex tw-items-start tw-justify-between tw-pr-4 tw-text-xs tw-text-gray-600",children:[a.jsxs("p",{className:"tw-flex tw-flex-col tw-justify-start",children:[a.jsx("span",{className:"tw-mb-2",children:"Publisher"}),a.jsx("span",{className:"tw-font-semibold",children:t}),a.jsx("span",{className:"tw-mb-2 tw-mt-4",children:"Size"}),a.jsx("span",{className:"tw-font-semibold",children:s})]}),a.jsx("div",{className:"tw-flex tw-w-3/4 tw-items-center tw-justify-between tw-text-xs tw-text-gray-600",children:a.jsxs("p",{className:"tw-flex tw-flex-col tw-justify-start",children:[a.jsx("span",{className:"tw-mb-2",children:"Languages"}),a.jsx("span",{className:"tw-font-semibold",children:l.join(", ")})]})})]})]})]})})}const Om=(e,t)=>{g.useEffect(()=>{if(!e)return()=>{};const n=e(t);return()=>{n()}},[e,t])},Fr=()=>!1,_m=(e,t)=>{const[n]=nr(g.useCallback(async()=>{if(!e)return Fr;const r=await Promise.resolve(e(t));return async()=>r()},[t,e]),Fr,{preserveValue:!1});g.useEffect(()=>()=>{n!==Fr&&n()},[n])};Object.defineProperty(exports,"sonner",{enumerable:!0,get:()=>Qa.toast});exports.Alert=zi;exports.AlertDescription=Fi;exports.AlertTitle=Li;exports.BOOK_SELECTOR_STRING_KEYS=mc;exports.BookChapterControl=oc;exports.BookSelectionMode=Ns;exports.BookSelector=hc;exports.Button=fe;exports.Card=Gi;exports.CardContent=Xi;exports.CardDescription=Hi;exports.CardFooter=Yi;exports.CardHeader=Ui;exports.CardTitle=qi;exports.ChapterRangeSelector=ys;exports.Checkbox=sr;exports.Checklist=bd;exports.ComboBox=Wn;exports.DataTable=Ts;exports.DisableButton=km;exports.DropdownMenu=or;exports.DropdownMenuCheckboxItem=ar;exports.DropdownMenuContent=En;exports.DropdownMenuGroup=cs;exports.DropdownMenuItem=co;exports.DropdownMenuItemType=tl;exports.DropdownMenuLabel=Wt;exports.DropdownMenuPortal=ql;exports.DropdownMenuRadioGroup=Xl;exports.DropdownMenuRadioItem=uo;exports.DropdownMenuSeparator=jn;exports.DropdownMenuShortcut=ps;exports.DropdownMenuSub=Hl;exports.DropdownMenuSubContent=us;exports.DropdownMenuSubTrigger=ds;exports.DropdownMenuTrigger=lo;exports.EnableButton=Nm;exports.FilterButton=el;exports.FilterDropdown=jm;exports.Footer=Rm;exports.GridMenu=Bi;exports.HamburgerMenuButton=Vi;exports.INVENTORY_STRING_KEYS=Ec;exports.IconButton=mm;exports.Input=St;exports.InstallButton=ym;exports.Inventory=Tc;exports.Label=qe;exports.MarkdownRenderer=Em;exports.MenuItem=Fo;exports.MoreInfo=Tm;exports.NavigationContentSearch=Rc;exports.NoExtensionsFound=Cm;exports.RadioGroup=po;exports.RadioGroupItem=Yn;exports.ScriptureResultsViewer=wd;exports.ScrollGroupSelector=fd;exports.SearchBar=ho;exports.Select=At;exports.SelectContent=vt;exports.SelectGroup=ks;exports.SelectItem=Ae;exports.SelectLabel=Ss;exports.SelectScrollDownButton=fo;exports.SelectScrollUpButton=wo;exports.SelectSeparator=Es;exports.SelectTrigger=bt;exports.SelectValue=Bt;exports.Separator=lr;exports.SettingsList=md;exports.SettingsListHeader=gd;exports.SettingsListItem=hd;exports.SettingsSidebar=Hs;exports.SettingsSidebarContentSearch=ad;exports.Slider=Wi;exports.Sonner=vm;exports.Spinner=Kt;exports.Switch=Ki;exports.Table=Cn;exports.TableBody=Rn;exports.TableCaption=Cs;exports.TableCell=xt;exports.TableFooter=js;exports.TableHead=Vt;exports.TableHeader=Tn;exports.TableRow=Ze;exports.Tabs=xm;exports.TabsContent=Qi;exports.TabsList=Ji;exports.TabsTrigger=Zi;exports.TextField=hm;exports.ToggleGroup=mo;exports.ToggleGroupItem=fn;exports.Toolbar=gm;exports.UpdateButton=Sm;exports.VersionHistory=nl;exports.VerticalTabs=go;exports.VerticalTabsContent=vo;exports.VerticalTabsList=bo;exports.VerticalTabsTrigger=Ms;exports.buttonVariants=ws;exports.cn=N;exports.getBookNumFromId=Os;exports.getLinesFromUSFM=Rs;exports.getNumberFromUSFM=Hr;exports.getStatusForItem=_s;exports.inventoryCountColumn=kc;exports.inventoryItemColumn=yc;exports.inventoryStatusColumn=Sc;exports.useEvent=Om;exports.useEventAsync=_m;exports.usePromise=nr;function Pm(e,t="top"){if(!e||typeof document>"u")return;const n=document.head||document.querySelector("head"),r=n.querySelector(":first-child"),o=document.createElement("style");o.appendChild(document.createTextNode(e)),t==="top"&&r?n.insertBefore(o,r):n.appendChild(o)}Pm(`*, ::before, ::after { --tw-border-spacing-x: 0; --tw-border-spacing-y: 0; --tw-translate-x: 0; @@ -3627,6 +3627,19 @@ video:where(.pr-twp,.pr-twp *) { color: rgb(76, 106, 76); background-color: rgb(214, 255, 152); } +.papi-menu-item { + background-color: transparent; +} + +.papi-menu-icon-trailing { + margin-left: 10px; + place-content: flex-end; +} + +.papi-menu-item img { + max-width: 24px; + max-height: 24px; +} .papi-icon-button { border: 0; border-radius: 3em; @@ -3663,18 +3676,5 @@ video:where(.pr-twp,.pr-twp *) { display: flex; gap: 8px; } -.papi-menu-item { - background-color: transparent; -} - -.papi-menu-icon-trailing { - margin-left: 10px; - place-content: flex-end; -} - -.papi-menu-item img { - max-width: 24px; - max-height: 24px; -} `,"top"); //# sourceMappingURL=index.cjs.map diff --git a/lib/platform-bible-react/dist/index.cjs.map b/lib/platform-bible-react/dist/index.cjs.map index 8ce8531647..75c874e8f7 100644 --- a/lib/platform-bible-react/dist/index.cjs.map +++ b/lib/platform-bible-react/dist/index.cjs.map @@ -1 +1 @@ -{"version":3,"file":"index.cjs","sources":["../src/utils/shadcn-ui.util.ts","../src/components/shadcn-ui/input.tsx","../src/components/advanced/book-chapter-control/book-chapter-input.component.tsx","../../../node_modules/@sillsdev/scripture/dist/index.es.js","../src/components/shadcn-ui/dropdown-menu.tsx","../src/components/advanced/book-chapter-control/book-menu-item.component.tsx","../src/components/advanced/book-chapter-control/chapter-select.component.tsx","../src/components/advanced/book-chapter-control/go-to-menu-item.component.tsx","../src/components/advanced/book-chapter-control/book-chapter-control.component.tsx","../src/components/shadcn-ui/button.tsx","../src/components/shadcn-ui/label.tsx","../src/components/shadcn-ui/radio-group.tsx","../src/components/shadcn-ui/popover.tsx","../src/components/shadcn-ui/dialog.tsx","../src/components/shadcn-ui/command.tsx","../src/components/basics/combo-box.component.tsx","../src/components/basics/chapter-range-selector.component.tsx","../src/components/advanced/book-selector.component.tsx","../src/components/advanced/data-table/data-table-column-toggle.component.tsx","../src/components/shadcn-ui/select.tsx","../src/components/advanced/data-table/data-table-pagination.component.tsx","../src/components/shadcn-ui/table.tsx","../src/components/advanced/data-table/data-table.component.tsx","../src/components/advanced/inventory/occurrences-table.component.tsx","../src/components/shadcn-ui/checkbox.tsx","../src/components/advanced/inventory/inventory-utils.ts","../src/components/shadcn-ui/toggle.tsx","../src/components/shadcn-ui/toggle-group.tsx","../src/components/advanced/inventory/inventory-columns.tsx","../src/components/advanced/inventory/inventory.component.tsx","../src/components/basics/search-bar.component.tsx","../src/components/basics/tabs-vertical.tsx","../src/components/advanced/tab-navigation-content-search.component.tsx","../src/components/shadcn-ui/separator.tsx","../src/components/shadcn-ui/sheet.tsx","../src/components/shadcn-ui/skeleton.tsx","../src/components/shadcn-ui/tooltip.tsx","../src/components/hooks/use-mobile.tsx","../src/components/shadcn-ui/sidebar.tsx","../src/components/advanced/settings-components/settings-sidebar.component.tsx","../src/components/advanced/settings-components/settings-sidebar-content-search.component.tsx","../src/components/advanced/scripture-results-viewer/scripture-results-viewer.component.tsx","../src/components/advanced/scroll-group-selector.component.tsx","../src/components/advanced/settings-components/settings-list.component.tsx","../src/components/shadcn-ui/card.tsx","../src/components/advanced/settings-components/settings-card.component.tsx","../src/components/basics/checklist.component.tsx","../../../node_modules/@babel/runtime/helpers/interopRequireDefault.js","../../../node_modules/@mui/utils/chainPropTypes/chainPropTypes.js","../../../node_modules/@babel/runtime/helpers/esm/extends.js","../../../node_modules/@mui/utils/deepmerge/deepmerge.js","../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.production.min.js","../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.development.js","../../../node_modules/prop-types/node_modules/react-is/index.js","../../../node_modules/object-assign/index.js","../../../node_modules/prop-types/lib/ReactPropTypesSecret.js","../../../node_modules/prop-types/lib/has.js","../../../node_modules/prop-types/checkPropTypes.js","../../../node_modules/prop-types/factoryWithTypeCheckers.js","../../../node_modules/prop-types/factoryWithThrowingShims.js","../../../node_modules/prop-types/index.js","../../../node_modules/@mui/utils/elementAcceptingRef/elementAcceptingRef.js","../../../node_modules/@mui/utils/exactProp/exactProp.js","../../../node_modules/@mui/utils/formatMuiErrorMessage/formatMuiErrorMessage.js","../../../node_modules/react-is/cjs/react-is.production.min.js","../../../node_modules/react-is/cjs/react-is.development.js","../../../node_modules/react-is/index.js","../../../node_modules/@mui/utils/getDisplayName/getDisplayName.js","../../../node_modules/@mui/utils/HTMLElementType/HTMLElementType.js","../../../node_modules/@mui/utils/refType/refType.js","../../../node_modules/@mui/utils/capitalize/capitalize.js","../../../node_modules/@mui/utils/createChainedFunction/createChainedFunction.js","../../../node_modules/@mui/utils/debounce/debounce.js","../../../node_modules/@mui/utils/deprecatedPropType/deprecatedPropType.js","../../../node_modules/@mui/utils/isMuiElement/isMuiElement.js","../../../node_modules/@mui/utils/ownerDocument/ownerDocument.js","../../../node_modules/@mui/utils/ownerWindow/ownerWindow.js","../../../node_modules/@mui/utils/requirePropFactory/requirePropFactory.js","../../../node_modules/@mui/utils/setRef/setRef.js","../../../node_modules/@mui/utils/useEnhancedEffect/useEnhancedEffect.js","../../../node_modules/@mui/utils/useId/useId.js","../../../node_modules/@mui/utils/unsupportedProp/unsupportedProp.js","../../../node_modules/@mui/utils/useControlled/useControlled.js","../../../node_modules/@mui/utils/useEventCallback/useEventCallback.js","../../../node_modules/@mui/utils/useForkRef/useForkRef.js","../../../node_modules/@mui/utils/useLazyRef/useLazyRef.js","../../../node_modules/@mui/utils/useOnMount/useOnMount.js","../../../node_modules/@mui/utils/useTimeout/useTimeout.js","../../../node_modules/@mui/utils/useIsFocusVisible/useIsFocusVisible.js","../../../node_modules/@mui/utils/resolveProps/resolveProps.js","../../../node_modules/@mui/utils/composeClasses/composeClasses.js","../../../node_modules/@mui/utils/ClassNameGenerator/ClassNameGenerator.js","../../../node_modules/@mui/utils/generateUtilityClass/generateUtilityClass.js","../../../node_modules/@mui/utils/generateUtilityClasses/generateUtilityClasses.js","../../../node_modules/@mui/utils/clamp/clamp.js","../../../node_modules/@babel/runtime/helpers/esm/objectWithoutPropertiesLoose.js","../../../node_modules/@mui/system/esm/createTheme/createBreakpoints.js","../../../node_modules/@mui/system/esm/createTheme/shape.js","../../../node_modules/@mui/system/esm/responsivePropType.js","../../../node_modules/@mui/system/esm/merge.js","../../../node_modules/@mui/system/esm/breakpoints.js","../../../node_modules/@mui/system/esm/style.js","../../../node_modules/@mui/system/esm/memoize.js","../../../node_modules/@mui/system/esm/spacing.js","../../../node_modules/@mui/system/esm/createTheme/createSpacing.js","../../../node_modules/@mui/system/esm/compose.js","../../../node_modules/@mui/system/esm/borders.js","../../../node_modules/@mui/system/esm/cssGrid.js","../../../node_modules/@mui/system/esm/palette.js","../../../node_modules/@mui/system/esm/sizing.js","../../../node_modules/@mui/system/esm/styleFunctionSx/defaultSxConfig.js","../../../node_modules/@mui/system/esm/styleFunctionSx/styleFunctionSx.js","../../../node_modules/@mui/system/esm/createTheme/applyStyles.js","../../../node_modules/@mui/system/esm/createTheme/createTheme.js","../../../node_modules/@mui/system/esm/useThemeWithoutDefault.js","../../../node_modules/@mui/system/esm/useTheme.js","../../../node_modules/@mui/system/esm/createStyled.js","../../../node_modules/@mui/system/esm/useThemeProps/getThemeProps.js","../../../node_modules/@mui/system/esm/useThemeProps/useThemeProps.js","../../../node_modules/@mui/system/esm/colorManipulator.js","../../../node_modules/@mui/material/styles/createMixins.js","../../../node_modules/@mui/material/colors/common.js","../../../node_modules/@mui/material/colors/grey.js","../../../node_modules/@mui/material/colors/purple.js","../../../node_modules/@mui/material/colors/red.js","../../../node_modules/@mui/material/colors/orange.js","../../../node_modules/@mui/material/colors/blue.js","../../../node_modules/@mui/material/colors/lightBlue.js","../../../node_modules/@mui/material/colors/green.js","../../../node_modules/@mui/material/styles/createPalette.js","../../../node_modules/@mui/material/styles/createTypography.js","../../../node_modules/@mui/material/styles/shadows.js","../../../node_modules/@mui/material/styles/createTransitions.js","../../../node_modules/@mui/material/styles/zIndex.js","../../../node_modules/@mui/material/styles/createTheme.js","../../../node_modules/@mui/material/styles/defaultTheme.js","../../../node_modules/@mui/material/styles/identifier.js","../../../node_modules/@mui/material/styles/useThemeProps.js","../../../node_modules/@mui/material/styles/styled.js","../../../node_modules/@mui/material/SvgIcon/svgIconClasses.js","../../../node_modules/@mui/material/SvgIcon/SvgIcon.js","../../../node_modules/@mui/material/utils/createSvgIcon.js","../../../node_modules/@mui/material/utils/index.js","../../../node_modules/@mui/icons-material/utils/createSvgIcon.js","../../../node_modules/@mui/icons-material/ArrowRight.js","../../../node_modules/@mui/base/utils/isHostComponent.js","../../../node_modules/@mui/base/utils/appendOwnerState.js","../../../node_modules/@mui/base/utils/ClassNameConfigurator.js","../../../node_modules/@mui/base/utils/extractEventHandlers.js","../../../node_modules/@mui/base/utils/resolveComponentProps.js","../../../node_modules/@mui/base/utils/omitEventHandlers.js","../../../node_modules/@mui/base/utils/mergeSlotProps.js","../../../node_modules/@mui/base/utils/useSlotProps.js","../../../node_modules/@mui/base/generateUtilityClass/index.js","../../../node_modules/@mui/base/generateUtilityClasses/index.js","../../../node_modules/@mui/base/Portal/Portal.js","../../../node_modules/@popperjs/core/lib/enums.js","../../../node_modules/@popperjs/core/lib/dom-utils/getNodeName.js","../../../node_modules/@popperjs/core/lib/dom-utils/getWindow.js","../../../node_modules/@popperjs/core/lib/dom-utils/instanceOf.js","../../../node_modules/@popperjs/core/lib/modifiers/applyStyles.js","../../../node_modules/@popperjs/core/lib/utils/getBasePlacement.js","../../../node_modules/@popperjs/core/lib/utils/math.js","../../../node_modules/@popperjs/core/lib/utils/userAgent.js","../../../node_modules/@popperjs/core/lib/dom-utils/isLayoutViewport.js","../../../node_modules/@popperjs/core/lib/dom-utils/getBoundingClientRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/getLayoutRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/contains.js","../../../node_modules/@popperjs/core/lib/dom-utils/getComputedStyle.js","../../../node_modules/@popperjs/core/lib/dom-utils/isTableElement.js","../../../node_modules/@popperjs/core/lib/dom-utils/getDocumentElement.js","../../../node_modules/@popperjs/core/lib/dom-utils/getParentNode.js","../../../node_modules/@popperjs/core/lib/dom-utils/getOffsetParent.js","../../../node_modules/@popperjs/core/lib/utils/getMainAxisFromPlacement.js","../../../node_modules/@popperjs/core/lib/utils/within.js","../../../node_modules/@popperjs/core/lib/utils/getFreshSideObject.js","../../../node_modules/@popperjs/core/lib/utils/mergePaddingObject.js","../../../node_modules/@popperjs/core/lib/utils/expandToHashMap.js","../../../node_modules/@popperjs/core/lib/modifiers/arrow.js","../../../node_modules/@popperjs/core/lib/utils/getVariation.js","../../../node_modules/@popperjs/core/lib/modifiers/computeStyles.js","../../../node_modules/@popperjs/core/lib/modifiers/eventListeners.js","../../../node_modules/@popperjs/core/lib/utils/getOppositePlacement.js","../../../node_modules/@popperjs/core/lib/utils/getOppositeVariationPlacement.js","../../../node_modules/@popperjs/core/lib/dom-utils/getWindowScroll.js","../../../node_modules/@popperjs/core/lib/dom-utils/getWindowScrollBarX.js","../../../node_modules/@popperjs/core/lib/dom-utils/getViewportRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/getDocumentRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/isScrollParent.js","../../../node_modules/@popperjs/core/lib/dom-utils/getScrollParent.js","../../../node_modules/@popperjs/core/lib/dom-utils/listScrollParents.js","../../../node_modules/@popperjs/core/lib/utils/rectToClientRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/getClippingRect.js","../../../node_modules/@popperjs/core/lib/utils/computeOffsets.js","../../../node_modules/@popperjs/core/lib/utils/detectOverflow.js","../../../node_modules/@popperjs/core/lib/utils/computeAutoPlacement.js","../../../node_modules/@popperjs/core/lib/modifiers/flip.js","../../../node_modules/@popperjs/core/lib/modifiers/hide.js","../../../node_modules/@popperjs/core/lib/modifiers/offset.js","../../../node_modules/@popperjs/core/lib/modifiers/popperOffsets.js","../../../node_modules/@popperjs/core/lib/utils/getAltAxis.js","../../../node_modules/@popperjs/core/lib/modifiers/preventOverflow.js","../../../node_modules/@popperjs/core/lib/dom-utils/getHTMLElementScroll.js","../../../node_modules/@popperjs/core/lib/dom-utils/getNodeScroll.js","../../../node_modules/@popperjs/core/lib/dom-utils/getCompositeRect.js","../../../node_modules/@popperjs/core/lib/utils/orderModifiers.js","../../../node_modules/@popperjs/core/lib/utils/debounce.js","../../../node_modules/@popperjs/core/lib/utils/mergeByName.js","../../../node_modules/@popperjs/core/lib/createPopper.js","../../../node_modules/@popperjs/core/lib/popper.js","../../../node_modules/@mui/base/Popper/popperClasses.js","../../../node_modules/@mui/base/Popper/Popper.js","../../../node_modules/@mui/material/styles/useTheme.js","../../../node_modules/@babel/runtime/helpers/esm/setPrototypeOf.js","../../../node_modules/@babel/runtime/helpers/esm/inheritsLoose.js","../../../node_modules/react-transition-group/esm/config.js","../../../node_modules/react-transition-group/esm/utils/PropTypes.js","../../../node_modules/react-transition-group/esm/TransitionGroupContext.js","../../../node_modules/react-transition-group/esm/utils/reflow.js","../../../node_modules/react-transition-group/esm/Transition.js","../../../node_modules/@mui/material/transitions/utils.js","../../../node_modules/@mui/material/Grow/Grow.js","../../../node_modules/@mui/material/Popper/Popper.js","../../../node_modules/@mui/material/Tooltip/tooltipClasses.js","../../../node_modules/@mui/material/Tooltip/Tooltip.js","../src/components/mui/menu-item.component.tsx","../src/components/mui/grouped-menu-item-list.component.tsx","../src/components/mui/top-level-menu.component.tsx","../src/components/mui/grid-menu.component.tsx","../src/hooks/use-promise.hook.ts","../../../node_modules/@mui/icons-material/esm/Menu.js","../src/components/mui/hamburger-menu-button.component.tsx","../src/components/mui/icon-button.component.tsx","../src/components/basics/spinner.component.tsx","../src/components/basics/text-field.component.tsx","../src/components/mui/toolbar.component.tsx","../src/components/shadcn-ui/alert.tsx","../src/components/shadcn-ui/sonner.tsx","../src/components/shadcn-ui/slider.tsx","../src/components/shadcn-ui/switch.tsx","../src/components/shadcn-ui/tabs.tsx","../src/components/advanced/extension-marketplace/buttons/install-button.component.tsx","../src/components/advanced/extension-marketplace/buttons/enable-button.component.tsx","../src/components/advanced/extension-marketplace/buttons/disable-button.component.tsx","../src/components/advanced/extension-marketplace/buttons/update-button.component.tsx","../src/components/advanced/extension-marketplace/markdown-renderer.component.tsx","../src/components/advanced/extension-marketplace/buttons/filter-button.component.tsx","../src/components/advanced/extension-marketplace/filter-dropdown.component.tsx","../src/components/advanced/extension-marketplace/no-extensions-found.component.tsx","../src/components/advanced/extension-marketplace/more-info.component.tsx","../src/components/advanced/extension-marketplace/version-history.component.tsx","../src/components/advanced/extension-marketplace/footer.component.tsx","../src/hooks/use-event.hook.ts","../src/hooks/use-event-async.hook.ts"],"sourcesContent":["import { type ClassValue, clsx } from 'clsx';\nimport { extendTailwindMerge } from 'tailwind-merge';\n\nconst twMergeCustom = extendTailwindMerge({ prefix: 'tw-' });\n\n/**\n * Tailwind and CSS class application helper function. Uses\n * [`clsx`](https://www.npmjs.com/package/clsx) to make it easy to apply classes conditionally using\n * object syntax, and uses [`tailwind-merge`](https://www.npmjs.com/package/tailwind-merge) to make\n * it easy to merge/overwrite Tailwind classes in a programmer-logic-friendly way.\n *\n * Note: `tailwind-merge` is configured to use the prefix `tw-`, so you must use the same prefix\n * with any Tailwind classes you use with this function to successfully overwrite other Tailwind\n * classes. `platform-bible-react` is configured to use `tw-` as its Tailwind prefix, so any\n * Tailwind classes you pass into `platform-bible-react` components will be compared using the `tw-`\n * prefix.\n *\n * This function was popularized by\n * [shadcn/ui](https://ui.shadcn.com/docs/installation/manual#add-a-cn-helper). See [ByteGrad's\n * explanation video](https://www.youtube.com/watch?v=re2JFITR7TI) for more information.\n *\n * @example\n *\n * ```typescript\n * const borderShouldBeBlue = true;\n * const textShouldBeRed = true;\n * const heightShouldBe20 = false;\n * const classString = cn(\n * 'tw-bg-primary tw-h-10 tw-text-primary-foreground',\n * 'tw-bg-secondary',\n * {\n * 'tw-border-blue-500': borderShouldBeBlue,\n * 'tw-text-red-500': textShouldBeRed,\n * 'tw-h-20': heightShouldBe20,\n * },\n * 'some-class',\n * );\n * ```\n *\n * The resulting `classString` is `'tw-h-10 tw-bg-secondary tw-border-blue-500 tw-text-red-500\n * some-class'`\n *\n * - Notice that `'tw-bg-secondary'`, specified later, overwrote `'tw-bg-primary'`, specified earlier,\n * because they are Tailwind classes that affect the same css property\n * - Notice that `'tw-text-red-500'`, specified later, overwrote `'tw-text-primary-foreground'`,\n * specified earlier, because they are Tailwind classes that affect the same css property\n * - Notice that `'tw-h-20'`, specified later, did not overwrite `'tw-h-10'`, specified earlier,\n * because `'tw-h-20'` is part of a conditional class object and its value evaluated to `false`;\n * therefore it was not applied\n * - Notice that `'some-class'` was applied. This function is not limited only to Tailwind classes.\n *\n *\n * @param inputs Class strings or `clsx` conditional class objects to merge. Tailwind classes\n * specified later in the arguments overwrite similar Tailwind classes specified earlier in the\n * arguments\n * @returns Class string containing all applicable classes from the arguments based on the rules\n * described above\n */\n// shadcn/ui uses this export in its boilerplate code\n// eslint-disable-next-line import/prefer-default-export\nexport function cn(...inputs: ClassValue[]) {\n return twMergeCustom(clsx(inputs));\n}\n","import React from 'react';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport interface InputProps extends React.InputHTMLAttributes {}\n\nexport const Input = React.forwardRef(\n ({ className, type, ...props }, ref) => {\n return (\n \n );\n },\n);\nInput.displayName = 'Input';\n","import { FocusEventHandler, forwardRef, KeyboardEvent, MouseEventHandler } from 'react';\nimport { History } from 'lucide-react';\nimport { Input as ShadInput } from '@/components/shadcn-ui/input';\n\nexport type BookChapterInputProps = {\n handleSearch: (searchString: string) => void;\n handleKeyDown: (event: KeyboardEvent) => void;\n handleOnClick: MouseEventHandler;\n handleSubmit: () => void;\n onFocus?: FocusEventHandler;\n value: string;\n placeholder: string;\n};\n\n// Shadcn Input sets type to \"button\"- HAVE to prop spread before setting type\nconst BookChapterInput = forwardRef(\n (\n { handleSearch, handleKeyDown, handleOnClick, handleSubmit, ...props }: BookChapterInputProps,\n ref,\n ) => {\n return (\n
    \n handleSearch(event.target.value)}\n onKeyDown={(e) => {\n if (e.key === 'Enter') {\n handleSubmit();\n }\n handleKeyDown(e);\n }}\n onClick={handleOnClick}\n ref={ref}\n />\n {\n // eslint-disable-next-line no-console\n console.log('back in history');\n }}\n />\n
    \n );\n },\n);\n\nexport default BookChapterInput;\n","var P = Object.defineProperty;\nvar R = (t, e, s) => e in t ? P(t, e, { enumerable: !0, configurable: !0, writable: !0, value: s }) : t[e] = s;\nvar n = (t, e, s) => R(t, typeof e != \"symbol\" ? e + \"\" : e, s);\nclass _ {\n constructor() {\n n(this, \"books\");\n n(this, \"firstSelectedBookNum\");\n n(this, \"lastSelectedBookNum\");\n n(this, \"count\");\n n(this, \"selectedBookNumbers\");\n n(this, \"selectedBookIds\");\n }\n}\nconst N = [\n \"GEN\",\n \"EXO\",\n \"LEV\",\n \"NUM\",\n \"DEU\",\n \"JOS\",\n \"JDG\",\n \"RUT\",\n \"1SA\",\n \"2SA\",\n // 10\n \"1KI\",\n \"2KI\",\n \"1CH\",\n \"2CH\",\n \"EZR\",\n \"NEH\",\n \"EST\",\n \"JOB\",\n \"PSA\",\n \"PRO\",\n // 20\n \"ECC\",\n \"SNG\",\n \"ISA\",\n \"JER\",\n \"LAM\",\n \"EZK\",\n \"DAN\",\n \"HOS\",\n \"JOL\",\n \"AMO\",\n // 30\n \"OBA\",\n \"JON\",\n \"MIC\",\n \"NAM\",\n \"HAB\",\n \"ZEP\",\n \"HAG\",\n \"ZEC\",\n \"MAL\",\n \"MAT\",\n // 40\n \"MRK\",\n \"LUK\",\n \"JHN\",\n \"ACT\",\n \"ROM\",\n \"1CO\",\n \"2CO\",\n \"GAL\",\n \"EPH\",\n \"PHP\",\n // 50\n \"COL\",\n \"1TH\",\n \"2TH\",\n \"1TI\",\n \"2TI\",\n \"TIT\",\n \"PHM\",\n \"HEB\",\n \"JAS\",\n \"1PE\",\n // 60\n \"2PE\",\n \"1JN\",\n \"2JN\",\n \"3JN\",\n \"JUD\",\n \"REV\",\n \"TOB\",\n \"JDT\",\n \"ESG\",\n \"WIS\",\n // 70\n \"SIR\",\n \"BAR\",\n \"LJE\",\n \"S3Y\",\n \"SUS\",\n \"BEL\",\n \"1MA\",\n \"2MA\",\n \"3MA\",\n \"4MA\",\n // 80\n \"1ES\",\n \"2ES\",\n \"MAN\",\n \"PS2\",\n \"ODA\",\n \"PSS\",\n \"JSA\",\n // actual variant text for JOS, now in LXA text\n \"JDB\",\n // actual variant text for JDG, now in LXA text\n \"TBS\",\n // actual variant text for TOB, now in LXA text\n \"SST\",\n // actual variant text for SUS, now in LXA text // 90\n \"DNT\",\n // actual variant text for DAN, now in LXA text\n \"BLT\",\n // actual variant text for BEL, now in LXA text\n \"XXA\",\n \"XXB\",\n \"XXC\",\n \"XXD\",\n \"XXE\",\n \"XXF\",\n \"XXG\",\n \"FRT\",\n // 100\n \"BAK\",\n \"OTH\",\n \"3ES\",\n // Used previously but really should be 2ES\n \"EZA\",\n // Used to be called 4ES, but not actually in any known project\n \"5EZ\",\n // Used to be called 5ES, but not actually in any known project\n \"6EZ\",\n // Used to be called 6ES, but not actually in any known project\n \"INT\",\n \"CNC\",\n \"GLO\",\n \"TDX\",\n // 110\n \"NDX\",\n \"DAG\",\n \"PS3\",\n \"2BA\",\n \"LBA\",\n \"JUB\",\n \"ENO\",\n \"1MQ\",\n \"2MQ\",\n \"3MQ\",\n // 120\n \"REP\",\n \"4BA\",\n \"LAO\"\n], B = [\n \"XXA\",\n \"XXB\",\n \"XXC\",\n \"XXD\",\n \"XXE\",\n \"XXF\",\n \"XXG\",\n \"FRT\",\n \"BAK\",\n \"OTH\",\n \"INT\",\n \"CNC\",\n \"GLO\",\n \"TDX\",\n \"NDX\"\n], O = [\n \"Genesis\",\n \"Exodus\",\n \"Leviticus\",\n \"Numbers\",\n \"Deuteronomy\",\n \"Joshua\",\n \"Judges\",\n \"Ruth\",\n \"1 Samuel\",\n \"2 Samuel\",\n \"1 Kings\",\n \"2 Kings\",\n \"1 Chronicles\",\n \"2 Chronicles\",\n \"Ezra\",\n \"Nehemiah\",\n \"Esther (Hebrew)\",\n \"Job\",\n \"Psalms\",\n \"Proverbs\",\n \"Ecclesiastes\",\n \"Song of Songs\",\n \"Isaiah\",\n \"Jeremiah\",\n \"Lamentations\",\n \"Ezekiel\",\n \"Daniel (Hebrew)\",\n \"Hosea\",\n \"Joel\",\n \"Amos\",\n \"Obadiah\",\n \"Jonah\",\n \"Micah\",\n \"Nahum\",\n \"Habakkuk\",\n \"Zephaniah\",\n \"Haggai\",\n \"Zechariah\",\n \"Malachi\",\n \"Matthew\",\n \"Mark\",\n \"Luke\",\n \"John\",\n \"Acts\",\n \"Romans\",\n \"1 Corinthians\",\n \"2 Corinthians\",\n \"Galatians\",\n \"Ephesians\",\n \"Philippians\",\n \"Colossians\",\n \"1 Thessalonians\",\n \"2 Thessalonians\",\n \"1 Timothy\",\n \"2 Timothy\",\n \"Titus\",\n \"Philemon\",\n \"Hebrews\",\n \"James\",\n \"1 Peter\",\n \"2 Peter\",\n \"1 John\",\n \"2 John\",\n \"3 John\",\n \"Jude\",\n \"Revelation\",\n \"Tobit\",\n \"Judith\",\n \"Esther Greek\",\n \"Wisdom of Solomon\",\n \"Sirach (Ecclesiasticus)\",\n \"Baruch\",\n \"Letter of Jeremiah\",\n \"Song of 3 Young Men\",\n \"Susanna\",\n \"Bel and the Dragon\",\n \"1 Maccabees\",\n \"2 Maccabees\",\n \"3 Maccabees\",\n \"4 Maccabees\",\n \"1 Esdras (Greek)\",\n \"2 Esdras (Latin)\",\n \"Prayer of Manasseh\",\n \"Psalm 151\",\n \"Odes\",\n \"Psalms of Solomon\",\n // WARNING, if you change the spelling of the *obsolete* tag be sure to update\n // IsObsolete routine\n \"Joshua A. *obsolete*\",\n \"Judges B. *obsolete*\",\n \"Tobit S. *obsolete*\",\n \"Susanna Th. *obsolete*\",\n \"Daniel Th. *obsolete*\",\n \"Bel Th. *obsolete*\",\n \"Extra A\",\n \"Extra B\",\n \"Extra C\",\n \"Extra D\",\n \"Extra E\",\n \"Extra F\",\n \"Extra G\",\n \"Front Matter\",\n \"Back Matter\",\n \"Other Matter\",\n \"3 Ezra *obsolete*\",\n \"Apocalypse of Ezra\",\n \"5 Ezra (Latin Prologue)\",\n \"6 Ezra (Latin Epilogue)\",\n \"Introduction\",\n \"Concordance \",\n \"Glossary \",\n \"Topical Index\",\n \"Names Index\",\n \"Daniel Greek\",\n \"Psalms 152-155\",\n \"2 Baruch (Apocalypse)\",\n \"Letter of Baruch\",\n \"Jubilees\",\n \"Enoch\",\n \"1 Meqabyan\",\n \"2 Meqabyan\",\n \"3 Meqabyan\",\n \"Reproof (Proverbs 25-31)\",\n \"4 Baruch (Rest of Baruch)\",\n \"Laodiceans\"\n], S = K();\nfunction g(t, e = !0) {\n return e && (t = t.toUpperCase()), t in S ? S[t] : 0;\n}\nfunction k(t) {\n return g(t) > 0;\n}\nfunction x(t) {\n const e = typeof t == \"string\" ? g(t) : t;\n return e >= 40 && e <= 66;\n}\nfunction T(t) {\n return (typeof t == \"string\" ? g(t) : t) <= 39;\n}\nfunction X(t) {\n return t <= 66;\n}\nfunction V(t) {\n const e = typeof t == \"string\" ? g(t) : t;\n return w(e) && !X(e);\n}\nfunction* L() {\n for (let t = 1; t <= N.length; t++) yield t;\n}\nconst G = 1, A = N.length;\nfunction H() {\n return [\"XXA\", \"XXB\", \"XXC\", \"XXD\", \"XXE\", \"XXF\", \"XXG\"];\n}\nfunction C(t, e = \"***\") {\n const s = t - 1;\n return s < 0 || s >= N.length ? e : N[s];\n}\nfunction I(t) {\n return t <= 0 || t > A ? \"******\" : O[t - 1];\n}\nfunction y(t) {\n return I(g(t));\n}\nfunction w(t) {\n const e = typeof t == \"number\" ? C(t) : t;\n return k(e) && !B.includes(e);\n}\nfunction q(t) {\n const e = typeof t == \"number\" ? C(t) : t;\n return k(e) && B.includes(e);\n}\nfunction U(t) {\n return O[t - 1].includes(\"*obsolete*\");\n}\nfunction K() {\n const t = {};\n for (let e = 0; e < N.length; e++)\n t[N[e]] = e + 1;\n return t;\n}\nconst m = {\n allBookIds: N,\n nonCanonicalIds: B,\n bookIdToNumber: g,\n isBookIdValid: k,\n isBookNT: x,\n isBookOT: T,\n isBookOTNT: X,\n isBookDC: V,\n allBookNumbers: L,\n firstBook: G,\n lastBook: A,\n extraBooks: H,\n bookNumberToId: C,\n bookNumberToEnglishName: I,\n bookIdToEnglishName: y,\n isCanonical: w,\n isExtraMaterial: q,\n isObsolete: U\n};\nvar l = /* @__PURE__ */ ((t) => (t[t.Unknown = 0] = \"Unknown\", t[t.Original = 1] = \"Original\", t[t.Septuagint = 2] = \"Septuagint\", t[t.Vulgate = 3] = \"Vulgate\", t[t.English = 4] = \"English\", t[t.RussianProtestant = 5] = \"RussianProtestant\", t[t.RussianOrthodox = 6] = \"RussianOrthodox\", t))(l || {});\nconst h = class h {\n // private versInfo: Versification;\n constructor(e) {\n n(this, \"name\");\n n(this, \"fullPath\");\n n(this, \"isPresent\");\n n(this, \"hasVerseSegments\");\n n(this, \"isCustomized\");\n n(this, \"baseVersification\");\n n(this, \"scriptureBooks\");\n n(this, \"_type\");\n if (e == null)\n throw new Error(\"Argument undefined\");\n typeof e == \"string\" ? (this.name = e, this._type = l[e]) : (this._type = e, this.name = l[e]);\n }\n get type() {\n return this._type;\n }\n equals(e) {\n return !e.type || !this.type ? !1 : e.type === this.type;\n }\n};\nn(h, \"Original\", new h(l.Original)), n(h, \"Septuagint\", new h(l.Septuagint)), n(h, \"Vulgate\", new h(l.Vulgate)), n(h, \"English\", new h(l.English)), n(h, \"RussianProtestant\", new h(l.RussianProtestant)), n(h, \"RussianOrthodox\", new h(l.RussianOrthodox));\nlet c = h;\nfunction E(t, e) {\n const s = e[0];\n for (let r = 1; r < e.length; r++)\n t = t.split(e[r]).join(s);\n return t.split(s);\n}\nvar D = /* @__PURE__ */ ((t) => (t[t.Valid = 0] = \"Valid\", t[t.UnknownVersification = 1] = \"UnknownVersification\", t[t.OutOfRange = 2] = \"OutOfRange\", t[t.VerseOutOfOrder = 3] = \"VerseOutOfOrder\", t[t.VerseRepeated = 4] = \"VerseRepeated\", t))(D || {});\nconst i = class i {\n constructor(e, s, r, a) {\n /** Not yet implemented. */\n n(this, \"firstChapter\");\n /** Not yet implemented. */\n n(this, \"lastChapter\");\n /** Not yet implemented. */\n n(this, \"lastVerse\");\n /** Not yet implemented. */\n n(this, \"hasSegmentsDefined\");\n /** Not yet implemented. */\n n(this, \"text\");\n /** Not yet implemented. */\n n(this, \"BBBCCCVVVS\");\n /** Not yet implemented. */\n n(this, \"longHashCode\");\n /** The versification of the reference. */\n n(this, \"versification\");\n n(this, \"rtlMark\", \"‏\");\n n(this, \"_bookNum\", 0);\n n(this, \"_chapterNum\", 0);\n n(this, \"_verseNum\", 0);\n n(this, \"_verse\");\n if (r == null && a == null)\n if (e != null && typeof e == \"string\") {\n const o = e, u = s != null && s instanceof c ? s : void 0;\n this.setEmpty(u), this.parse(o);\n } else if (e != null && typeof e == \"number\") {\n const o = s != null && s instanceof c ? s : void 0;\n this.setEmpty(o), this._verseNum = e % i.chapterDigitShifter, this._chapterNum = Math.floor(\n e % i.bookDigitShifter / i.chapterDigitShifter\n ), this._bookNum = Math.floor(e / i.bookDigitShifter);\n } else if (s == null)\n if (e != null && e instanceof i) {\n const o = e;\n this._bookNum = o.bookNum, this._chapterNum = o.chapterNum, this._verseNum = o.verseNum, this._verse = o.verse, this.versification = o.versification;\n } else {\n if (e == null) return;\n const o = e instanceof c ? e : i.defaultVersification;\n this.setEmpty(o);\n }\n else\n throw new Error(\"VerseRef constructor not supported.\");\n else if (e != null && s != null && r != null)\n if (typeof e == \"string\" && typeof s == \"string\" && typeof r == \"string\")\n this.setEmpty(a), this.updateInternal(e, s, r);\n else if (typeof e == \"number\" && typeof s == \"number\" && typeof r == \"number\")\n this._bookNum = e, this._chapterNum = s, this._verseNum = r, this.versification = a ?? i.defaultVersification;\n else\n throw new Error(\"VerseRef constructor not supported.\");\n else\n throw new Error(\"VerseRef constructor not supported.\");\n }\n /**\n * Determines if the verse string is in a valid format (does not consider versification).\n */\n static isVerseParseable(e) {\n return e.length > 0 && \"0123456789\".includes(e[0]) && !e.endsWith(this.verseRangeSeparator) && !e.endsWith(this.verseSequenceIndicator);\n }\n /**\n * Tries to parse the specified string into a verse reference.\n * @param str - The string to attempt to parse.\n * @returns success: `true` if the specified string was successfully parsed, `false` otherwise.\n * @returns verseRef: The result of the parse if successful, or empty VerseRef if it failed\n */\n static tryParse(e) {\n let s;\n try {\n return s = new i(e), { success: !0, verseRef: s };\n } catch (r) {\n if (r instanceof v)\n return s = new i(), { success: !1, verseRef: s };\n throw r;\n }\n }\n /**\n * Gets the reference as a comparable integer where the book, chapter, and verse each occupy 3\n * digits.\n * @param bookNum - Book number (this is 1-based, not an index).\n * @param chapterNum - Chapter number.\n * @param verseNum - Verse number.\n * @returns The reference as a comparable integer where the book, chapter, and verse each occupy 3\n * digits.\n */\n static getBBBCCCVVV(e, s, r) {\n return e % i.bcvMaxValue * i.bookDigitShifter + (s >= 0 ? s % i.bcvMaxValue * i.chapterDigitShifter : 0) + (r >= 0 ? r % i.bcvMaxValue : 0);\n }\n /**\n * Deserializes a serialized VerseRef.\n * @param serializedVerseRef - Serialized VerseRef to create from.\n * @returns the deserialized VerseRef.\n */\n static fromJSON(e) {\n const { book: s, chapterNum: r, verseNum: a, verse: o, versificationStr: u } = e, f = o || a.toString();\n let d;\n return u && (d = new c(u)), s ? new i(s, r.toString(), f, d) : new i();\n }\n /**\n * Parses a verse string and gets the leading numeric portion as a number.\n * @param verseStr - verse string to parse\n * @returns true if the entire string could be parsed as a single, simple verse number (1-999);\n * false if the verse string represented a verse bridge, contained segment letters, or was invalid\n */\n static tryGetVerseNum(e) {\n let s;\n if (!e)\n return s = -1, { success: !0, vNum: s };\n s = 0;\n let r;\n for (let a = 0; a < e.length; a++) {\n if (r = e[a], r < \"0\" || r > \"9\")\n return a === 0 && (s = -1), { success: !1, vNum: s };\n if (s = s * 10 + +r - 0, s > i.bcvMaxValue)\n return s = -1, { success: !1, vNum: s };\n }\n return { success: !0, vNum: s };\n }\n /**\n * Checks to see if a VerseRef hasn't been set - all values are the default.\n */\n get isDefault() {\n return this.bookNum === 0 && this.chapterNum === 0 && this.verseNum === 0 && this.versification == null;\n }\n /**\n * Gets whether the verse contains multiple verses.\n */\n get hasMultiple() {\n return this._verse != null && (this._verse.includes(i.verseRangeSeparator) || this._verse.includes(i.verseSequenceIndicator));\n }\n /**\n * Gets or sets the book of the reference. Book is the 3-letter abbreviation in capital letters,\n * e.g. `'MAT'`.\n */\n get book() {\n return m.bookNumberToId(this.bookNum, \"\");\n }\n set book(e) {\n this.bookNum = m.bookIdToNumber(e);\n }\n /**\n * Gets or sets the chapter of the reference,. e.g. `'3'`.\n */\n get chapter() {\n return this.isDefault || this._chapterNum < 0 ? \"\" : this._chapterNum.toString();\n }\n set chapter(e) {\n const s = +e;\n this._chapterNum = Number.isInteger(s) ? s : -1;\n }\n /**\n * Gets or sets the verse of the reference, including range, segments, and sequences, e.g. `'4'`,\n * or `'4b-5a, 7'`.\n */\n get verse() {\n return this._verse != null ? this._verse : this.isDefault || this._verseNum < 0 ? \"\" : this._verseNum.toString();\n }\n set verse(e) {\n const { success: s, vNum: r } = i.tryGetVerseNum(e);\n this._verse = s ? void 0 : e.replace(this.rtlMark, \"\"), this._verseNum = r, !(this._verseNum >= 0) && ({ vNum: this._verseNum } = i.tryGetVerseNum(this._verse));\n }\n /**\n * Get or set Book based on book number, e.g. `42`.\n */\n get bookNum() {\n return this._bookNum;\n }\n set bookNum(e) {\n if (e <= 0 || e > m.lastBook)\n throw new v(\n \"BookNum must be greater than zero and less than or equal to last book\"\n );\n this._bookNum = e;\n }\n /**\n * Gets or sets the chapter number, e.g. `3`. `-1` if not valid.\n */\n get chapterNum() {\n return this._chapterNum;\n }\n set chapterNum(e) {\n this.chapterNum = e;\n }\n /**\n * Gets or sets verse start number, e.g. `4`. `-1` if not valid.\n */\n get verseNum() {\n return this._verseNum;\n }\n set verseNum(e) {\n this._verseNum = e;\n }\n /**\n * String representing the versification (should ONLY be used for serialization/deserialization).\n *\n * @remarks This is for backwards compatibility when ScrVers was an enumeration.\n */\n get versificationStr() {\n var e;\n return (e = this.versification) == null ? void 0 : e.name;\n }\n set versificationStr(e) {\n this.versification = this.versification != null ? new c(e) : void 0;\n }\n /**\n * Determines if the reference is valid.\n */\n get valid() {\n return this.validStatus === 0;\n }\n /**\n * Get the valid status for this reference.\n */\n get validStatus() {\n return this.validateVerse(i.verseRangeSeparators, i.verseSequenceIndicators);\n }\n /**\n * Gets the reference as a comparable integer where the book,\n * chapter, and verse each occupy three digits and the verse is 0.\n */\n get BBBCCC() {\n return i.getBBBCCCVVV(this._bookNum, this._chapterNum, 0);\n }\n /**\n * Gets the reference as a comparable integer where the book,\n * chapter, and verse each occupy three digits. If verse is not null\n * (i.e., this reference represents a complex reference with verse\n * segments or bridge) this cannot be used for an exact comparison.\n */\n get BBBCCCVVV() {\n return i.getBBBCCCVVV(this._bookNum, this._chapterNum, this._verseNum);\n }\n /**\n * Gets whether the verse is defined as an excluded verse in the versification.\n * Does not handle verse ranges.\n */\n // eslint-disable-next-line @typescript-eslint/class-literal-property-style\n get isExcluded() {\n return !1;\n }\n /**\n * Parses the reference in the specified string.\n * Optionally versification can follow reference as in GEN 3:11/4\n * Throw an exception if\n * - invalid book name\n * - chapter number is missing or not a number\n * - verse number is missing or does not start with a number\n * - versification is invalid\n * @param verseStr - string to parse e.g. 'MAT 3:11'\n */\n parse(e) {\n if (e = e.replace(this.rtlMark, \"\"), e.includes(\"/\")) {\n const o = e.split(\"/\");\n if (e = o[0], o.length > 1)\n try {\n const u = +o[1].trim();\n this.versification = new c(l[u]);\n } catch {\n throw new v(\"Invalid reference : \" + e);\n }\n }\n const s = e.trim().split(\" \");\n if (s.length !== 2)\n throw new v(\"Invalid reference : \" + e);\n const r = s[1].split(\":\"), a = +r[0];\n if (r.length !== 2 || m.bookIdToNumber(s[0]) === 0 || !Number.isInteger(a) || a < 0 || !i.isVerseParseable(r[1]))\n throw new v(\"Invalid reference : \" + e);\n this.updateInternal(s[0], r[0], r[1]);\n }\n /**\n * Simplifies this verse ref so that it has no bridging of verses or\n * verse segments like `'1a'`.\n */\n simplify() {\n this._verse = void 0;\n }\n /**\n * Makes a clone of the reference.\n *\n * @returns The cloned VerseRef.\n */\n clone() {\n return new i(this);\n }\n toString() {\n const e = this.book;\n return e === \"\" ? \"\" : `${e} ${this.chapter}:${this.verse}`;\n }\n toJSON() {\n let e = this.verse;\n (e === \"\" || e === this.verseNum.toString()) && (e = void 0);\n const s = {\n book: this.book,\n chapterNum: this.chapterNum,\n verseNum: this.verseNum,\n verse: e,\n versificationStr: this.versificationStr\n };\n return e || delete s.verse, s;\n }\n /**\n * Compares this `VerseRef` with supplied one.\n * @param verseRef - object to compare this one to.\n * @returns `true` if this `VerseRef` is equal to the supplied one, `false` otherwise.\n */\n equals(e) {\n return e instanceof i ? e._bookNum === this._bookNum && e._chapterNum === this._chapterNum && e._verseNum === this._verseNum && e.verse === this.verse && (e.versification == null && this.versification == null || e.versification != null && this.versification != null && e.versification.equals(this.versification)) : !1;\n }\n /**\n * Enumerate all individual verses contained in a VerseRef.\n * Verse ranges are indicated by \"-\" and consecutive verses by \",\"s.\n * Examples:\n * GEN 1:2 returns GEN 1:2\n * GEN 1:1a-3b,5 returns GEN 1:1a, GEN 1:2, GEN 1:3b, GEN 1:5\n * GEN 1:2a-2c returns //! ??????\n *\n * @param specifiedVersesOnly - if set to true return only verses that are\n * explicitly specified only, not verses within a range. Defaults to `false`.\n * @param verseRangeSeparators - Verse range separators.\n * Defaults to `VerseRef.verseRangeSeparators`.\n * @param verseSequenceSeparators - Verse sequence separators.\n * Defaults to `VerseRef.verseSequenceIndicators`.\n * @returns An array of all single verse references in this VerseRef.\n */\n allVerses(e = !1, s = i.verseRangeSeparators, r = i.verseSequenceIndicators) {\n if (this._verse == null || this.chapterNum <= 0)\n return [this.clone()];\n const a = [], o = E(this._verse, r);\n for (const u of o.map((f) => E(f, s))) {\n const f = this.clone();\n f.verse = u[0];\n const d = f.verseNum;\n if (a.push(f), u.length > 1) {\n const b = this.clone();\n if (b.verse = u[1], !e)\n for (let p = d + 1; p < b.verseNum; p++) {\n const J = new i(\n this._bookNum,\n this._chapterNum,\n p,\n this.versification\n );\n this.isExcluded || a.push(J);\n }\n a.push(b);\n }\n }\n return a;\n }\n /**\n * Validates a verse number using the supplied separators rather than the defaults.\n */\n validateVerse(e, s) {\n if (!this.verse)\n return this.internalValid;\n let r = 0;\n for (const a of this.allVerses(!0, e, s)) {\n const o = a.internalValid;\n if (o !== 0)\n return o;\n const u = a.BBBCCCVVV;\n if (r > u)\n return 3;\n if (r === u)\n return 4;\n r = u;\n }\n return 0;\n }\n /**\n * Gets whether a single verse reference is valid.\n */\n get internalValid() {\n return this.versification == null ? 1 : this._bookNum <= 0 || this._bookNum > m.lastBook ? 2 : (m.isCanonical(this._bookNum), 0);\n }\n setEmpty(e = i.defaultVersification) {\n this._bookNum = 0, this._chapterNum = -1, this._verse = void 0, this.versification = e;\n }\n updateInternal(e, s, r) {\n this.bookNum = m.bookIdToNumber(e), this.chapter = s, this.verse = r;\n }\n};\nn(i, \"defaultVersification\", c.English), n(i, \"verseRangeSeparator\", \"-\"), n(i, \"verseSequenceIndicator\", \",\"), n(i, \"verseRangeSeparators\", [i.verseRangeSeparator]), n(i, \"verseSequenceIndicators\", [i.verseSequenceIndicator]), n(i, \"chapterDigitShifter\", 1e3), n(i, \"bookDigitShifter\", i.chapterDigitShifter * i.chapterDigitShifter), n(i, \"bcvMaxValue\", i.chapterDigitShifter - 1), /**\n * The valid status of the VerseRef.\n */\nn(i, \"ValidStatusType\", D);\nlet M = i;\nclass v extends Error {\n}\nexport {\n _ as BookSet,\n m as Canon,\n c as ScrVers,\n l as ScrVersType,\n M as VerseRef,\n v as VerseRefException\n};\n//# sourceMappingURL=index.es.js.map\n","import React from 'react';\nimport * as DropdownMenuPrimitive from '@radix-ui/react-dropdown-menu';\nimport { Check, ChevronRight, Circle } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport const DropdownMenu = DropdownMenuPrimitive.Root;\n\nexport const DropdownMenuTrigger = DropdownMenuPrimitive.Trigger;\n\nexport const DropdownMenuGroup = DropdownMenuPrimitive.Group;\n\nexport const DropdownMenuPortal = DropdownMenuPrimitive.Portal;\n\nexport const DropdownMenuSub = DropdownMenuPrimitive.Sub;\n\nexport const DropdownMenuRadioGroup = DropdownMenuPrimitive.RadioGroup;\n\nexport type DropdownMenuSubTriggerProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.SubTrigger\n> & {\n className?: string;\n inset?: boolean;\n};\n\nexport type DropdownMenuSubContentProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.SubContent\n> & {\n className?: string;\n};\n\nexport type DropdownMenuContentProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Content\n> & {\n className?: string;\n sideOffset?: number;\n};\n\nexport type DropdownMenuItemProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Item\n> & {\n className?: string;\n inset?: boolean;\n};\n\nexport type DropdownMenuCheckboxItemProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.CheckboxItem\n> & {\n className?: string;\n checked?: boolean;\n};\n\nexport type DropdownMenuRadioItemProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.RadioItem\n> & {\n className?: string;\n};\n\nexport type DropdownMenuLabelProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Label\n> & {\n className?: string;\n inset?: boolean;\n};\n\nexport type DropdownMenuSeparatorProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Separator\n> & {\n className?: string;\n};\n\nexport type DropdownMenuShortcutProps = React.HTMLAttributes & {\n className?: string;\n};\n\nexport const DropdownMenuSubTrigger = React.forwardRef<\n React.ElementRef,\n DropdownMenuSubTriggerProps\n>(({ className, inset, children, ...props }, ref) => (\n \n {children}\n \n \n));\nDropdownMenuSubTrigger.displayName = DropdownMenuPrimitive.SubTrigger.displayName;\n\nexport const DropdownMenuSubContent = React.forwardRef<\n React.ElementRef,\n DropdownMenuSubContentProps\n>(({ className, ...props }, ref) => (\n \n));\nDropdownMenuSubContent.displayName = DropdownMenuPrimitive.SubContent.displayName;\n\nexport const DropdownMenuContent = React.forwardRef<\n React.ElementRef,\n DropdownMenuContentProps\n>(({ className, sideOffset = 4, ...props }, ref) => (\n \n \n \n));\nDropdownMenuContent.displayName = DropdownMenuPrimitive.Content.displayName;\n\n/**\n * TODO: fix: direction is not automatically handled by this component, so that shortcuts are\n * display always to the right\n */\nexport const DropdownMenuItem = React.forwardRef<\n React.ElementRef,\n DropdownMenuItemProps\n>(({ className, inset, ...props }, ref) => (\n \n));\nDropdownMenuItem.displayName = DropdownMenuPrimitive.Item.displayName;\n\nexport const DropdownMenuCheckboxItem = React.forwardRef<\n React.ElementRef,\n DropdownMenuCheckboxItemProps\n>(({ className, children, checked, ...props }, ref) => (\n \n \n \n \n \n \n {children}\n \n));\nDropdownMenuCheckboxItem.displayName = DropdownMenuPrimitive.CheckboxItem.displayName;\n\nexport const DropdownMenuRadioItem = React.forwardRef<\n React.ElementRef,\n DropdownMenuRadioItemProps\n>(({ className, children, ...props }, ref) => (\n \n \n \n \n \n \n {children}\n \n));\nDropdownMenuRadioItem.displayName = DropdownMenuPrimitive.RadioItem.displayName;\n\nexport const DropdownMenuLabel = React.forwardRef<\n React.ElementRef,\n DropdownMenuLabelProps\n>(({ className, inset, ...props }, ref) => (\n \n));\nDropdownMenuLabel.displayName = DropdownMenuPrimitive.Label.displayName;\n\nexport const DropdownMenuSeparator = React.forwardRef<\n React.ElementRef,\n DropdownMenuSeparatorProps\n>(({ className, ...props }, ref) => (\n \n));\nDropdownMenuSeparator.displayName = DropdownMenuPrimitive.Separator.displayName;\n\nexport function DropdownMenuShortcut({ className, ...props }: DropdownMenuShortcutProps) {\n return (\n \n );\n}\nDropdownMenuShortcut.displayName = 'DropdownMenuShortcut';\n","import { Canon } from '@sillsdev/scripture';\nimport { PropsWithChildren, KeyboardEvent, forwardRef } from 'react';\nimport { DropdownMenuItem as ShadDropdownMenuItem } from '@/components/shadcn-ui/dropdown-menu';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport type BookType = 'OT' | 'NT' | 'DC';\n\ntype BookMenuItemProps = PropsWithChildren<{\n /** String id of book */\n bookId: string;\n /** Callback to run when a book menu item is selected */\n handleSelectBook: () => void;\n /** Indicates if this menu item is currently selected */\n isSelected: boolean;\n /** Function that is called upon highlighting a book in the dropdown menu */\n handleHighlightBook: () => void;\n /**\n * Function that is called on pressing a key\n *\n * @param event Event that contains information about the key stroke\n */\n handleKeyDown: (event: KeyboardEvent) => void;\n /**\n * Type of book associated with this menu item, coordinates color labels ? Mock up has the labels\n * coordinated to genre\n */\n bookType: BookType;\n}>;\n\nconst BookMenuItem = forwardRef(\n (\n {\n bookId,\n handleSelectBook,\n isSelected,\n handleHighlightBook,\n handleKeyDown,\n bookType,\n children,\n }: BookMenuItemProps,\n ref,\n ) => {\n return (\n {\n // preventDefault() here prevents the entire dropdown menu from closing when selecting this item\n event.preventDefault();\n handleSelectBook();\n }}\n onKeyDown={(event: KeyboardEvent) => {\n handleKeyDown(event);\n }}\n onFocus={handleHighlightBook}\n onMouseMove={handleHighlightBook}\n >\n \n {Canon.bookIdToEnglishName(bookId)}\n \n {isSelected &&
    {children}
    }\n \n );\n },\n);\n\nexport default BookMenuItem;\n","import { cn } from '@/utils/shadcn-ui.util';\nimport { useCallback } from 'react';\n\nexport type ChapterSelectProps = {\n /**\n * Callback to run when a chapter div is selected\n *\n * @param chapterNumber Number of the chapter that has been selected\n */\n handleSelectChapter: (chapterNumber: number) => void;\n /** The highest chapter number in the book (of course equal to number of chapters in the book) */\n endChapter: number;\n /** The chapter number that is currently selected */\n activeChapter: number;\n /** The chapter number that is currently highlighted using keyboard or mouse navigation */\n highlightedChapter: number;\n /**\n * Callback to run when a chapter is highlighted by the user\n *\n * @param chapterNumber The chapter that is highlighted\n */\n handleHighlightedChapter: (chapterNumber: number) => void;\n};\n\nfunction ChapterSelect({\n handleSelectChapter,\n endChapter,\n activeChapter,\n highlightedChapter,\n handleHighlightedChapter,\n}: ChapterSelectProps) {\n const chapters = Array.from({ length: endChapter }, (_, i) => i + 1);\n\n const handleMouse = useCallback(\n (chapterNumber: number) => {\n handleHighlightedChapter(chapterNumber);\n },\n [handleHighlightedChapter],\n );\n\n return (\n
    \n {chapters.map((chapter) => (\n {\n event.preventDefault();\n event.stopPropagation();\n handleSelectChapter(chapter);\n }}\n role=\"button\"\n onKeyDown={(event) => {\n if (event.key === 'Enter') {\n handleSelectChapter(chapter);\n }\n }}\n tabIndex={0}\n onMouseMove={() => handleMouse(chapter)}\n >\n {chapter}\n
    \n ))}\n
    \n );\n}\n\nexport default ChapterSelect;\n","import { DropdownMenuLabel as ShadDropdownMenuLabel } from '@/components/shadcn-ui/dropdown-menu';\nimport { Bookmark, Clock, ArrowDownWideNarrow } from 'lucide-react';\n\nexport type GoToMenuItemProps = {\n handleSort: () => void;\n handleLocationHistory: () => void;\n handleBookmarks: () => void;\n};\n\nfunction GoToMenuItem({ handleSort, handleLocationHistory, handleBookmarks }: GoToMenuItemProps) {\n return (\n \n

    Go To

    \n
    \n \n \n \n
    \n
    \n );\n}\n\nexport default GoToMenuItem;\n","import BookChapterInput from '@/components/advanced/book-chapter-control/book-chapter-input.component';\nimport BookMenuItem, {\n BookType,\n} from '@/components/advanced/book-chapter-control/book-menu-item.component';\nimport ChapterSelect from '@/components/advanced/book-chapter-control/chapter-select.component';\nimport GoToMenuItem from '@/components/advanced/book-chapter-control/go-to-menu-item.component';\nimport {\n DropdownMenu as ShadDropdownMenu,\n DropdownMenuContent as ShadDropdownMenuContent,\n DropdownMenuLabel as ShadDropdownMenuLabel,\n DropdownMenuSeparator as ShadDropdownMenuSeparator,\n DropdownMenuTrigger as ShadDropdownMenuTrigger,\n} from '@/components/shadcn-ui/dropdown-menu';\nimport { Canon } from '@sillsdev/scripture';\nimport { ScriptureReference, getChaptersForBook } from 'platform-bible-utils';\nimport {\n KeyboardEvent as ReactKeyboardEvent,\n useCallback,\n useEffect,\n useLayoutEffect,\n useRef,\n useState,\n} from 'react';\n\ntype BookTypeLabels = {\n [bookType in BookType]: string;\n};\ntype BookChapterControlProps = {\n scrRef: ScriptureReference;\n handleSubmit: (scrRef: ScriptureReference) => void;\n};\n\nconst ALL_BOOK_IDS = Canon.allBookIds;\nconst BOOK_TYPE_LABELS: BookTypeLabels = {\n OT: 'Old Testament',\n NT: 'New Testament',\n DC: 'Deuterocanon',\n};\nconst BOOK_TYPE_ARRAY: BookType[] = ['OT', 'NT', 'DC'];\n// This is the height of three menu items to offset scrolling to the selected menu item\n// If you use menuItemRef.clientHeight- includes height of chapter div which is too big\nconst SCROLL_OFFSET = 32 + 32 + 32;\nconst SEARCH_QUERY_FORMATS = [\n /^(\\w+)$/i, // Matches a single word (book name or id)\n /^(\\w+)(?:\\s(\\d+))$/i, // Matches a word followed by a chapter number\n /^(\\w+)(?:\\s(\\d+):(\\d+))$/i, // Matches a word followed by a chapter and verse number\n];\nconst fetchGroupedBooks = (bookType: BookType) => {\n const groupedBooks = {\n OT: ALL_BOOK_IDS.filter((bookId) => Canon.isBookOT(bookId)),\n NT: ALL_BOOK_IDS.filter((bookId) => Canon.isBookNT(bookId)),\n DC: ALL_BOOK_IDS.filter((bookId) => Canon.isBookDC(bookId)),\n };\n return groupedBooks[bookType];\n};\nconst fetchEndChapter = (bookId: string) => {\n // getChaptersForBook returns -1 if not found in scrBookData\n // scrBookData only includes OT and NT, so all DC will return -1\n return getChaptersForBook(Canon.bookIdToNumber(bookId));\n};\n\n/**\n * Gets all of the English names from book ids\n *\n * @returns String[]\n */\nfunction getAllEnglishNames(): string[] {\n const allEnglishNames = ALL_BOOK_IDS.map((bookId) => {\n return Canon.bookIdToEnglishName(bookId);\n });\n return allEnglishNames;\n}\n\n/**\n * Determines if bookName is in allEnglishNames\n *\n * @param bookName Book English name\n * @returns True if bookName is included, false otherwise\n */\nfunction isValidBookEnglishName(bookName: string): boolean {\n return getAllEnglishNames().includes(bookName);\n}\n\n/**\n * Gets a bookId from given English name\n *\n * @param bookName Book English name\n * @returns BookId of provided bookName, undefined otherwise\n */\nfunction getBookIdFromEnglishName(bookName: string): string | undefined {\n // Convert bookName to lowercase and then capitalize the first letter\n const formattedBookName = bookName.toLowerCase().replace(/^\\w/, (c) => c.toUpperCase());\n\n if (isValidBookEnglishName(formattedBookName)) {\n const matchingBookId = ALL_BOOK_IDS.find((bookId) => {\n return Canon.bookIdToEnglishName(bookId) === formattedBookName;\n });\n return matchingBookId;\n }\n\n return undefined;\n}\n\nfunction BookChapterControl({ scrRef, handleSubmit }: BookChapterControlProps) {\n const [searchQuery, setSearchQuery] = useState('');\n const [selectedBookId, setSelectedBookId] = useState(\n Canon.bookNumberToId(scrRef.bookNum),\n );\n const [highlightedChapter, setHighlightedChapter] = useState(scrRef.chapterNum ?? 0);\n const [highlightedBookId, setHighlightedBookId] = useState(\n Canon.bookNumberToId(scrRef.bookNum),\n );\n const [isContentOpen, setIsContentOpen] = useState(false);\n const [isContentOpenDelayed, setIsContentOpenDelayed] = useState(isContentOpen);\n\n // This ref will always be defined\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const inputRef = useRef(undefined!);\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const contentRef = useRef(undefined!);\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const menuItemRef = useRef(undefined!);\n\n const fetchFilteredBooks = useCallback(\n (bookType: BookType) => {\n return fetchGroupedBooks(bookType).filter((bookId: string) => {\n const englishNameLowerCase = Canon.bookIdToEnglishName(bookId).toLowerCase();\n const normalizedQuery = searchQuery.replace(/[^a-zA-Z]/g, '').toLowerCase();\n return (\n englishNameLowerCase.includes(normalizedQuery) || // Match book name\n bookId.toLowerCase().includes(normalizedQuery) // Match book ID\n );\n });\n },\n [searchQuery],\n );\n\n const handleSearchInput = (searchString: string) => {\n setSearchQuery(searchString);\n };\n\n /**\n * Whether to prevent radix's logic from closing the dropdown. This is important because radix\n * tries to close the dropdown when the input first focuses, and we don't want it to do that. But\n * we don't want to prevent the dropdown from closing when we click away from the input, so we\n * don't want to just keep it open if the input is focused\n */\n const shouldPreventAutoClosing = useRef(false);\n\n const controlMenuState = useCallback((open: boolean) => {\n if (shouldPreventAutoClosing.current) {\n shouldPreventAutoClosing.current = false;\n return;\n }\n setIsContentOpen(open);\n }, []);\n\n const updateReference = useCallback(\n (bookId: string, shouldClose: boolean, chapter?: number, verse?: number) => {\n setHighlightedChapter(\n Canon.bookNumberToId(scrRef.bookNum) !== bookId ? 1 : scrRef.chapterNum,\n );\n\n if (shouldClose || fetchEndChapter(bookId) === -1) {\n handleSubmit({\n bookNum: Canon.bookIdToNumber(bookId),\n chapterNum: chapter || 1,\n verseNum: verse || 1,\n });\n\n setIsContentOpen(false);\n setSearchQuery('');\n return;\n }\n\n setSelectedBookId(selectedBookId !== bookId ? bookId : '');\n setIsContentOpen(!shouldClose);\n },\n [handleSubmit, scrRef.bookNum, scrRef.chapterNum, selectedBookId],\n );\n\n const handleSelectChapter = (chapterNumber: number) => {\n if (chapterNumber <= 0 || chapterNumber > fetchEndChapter(selectedBookId)) {\n return;\n }\n updateReference(selectedBookId, true, chapterNumber);\n };\n\n const handleInputSubmit = useCallback(() => {\n SEARCH_QUERY_FORMATS.forEach((format) => {\n const matches = searchQuery.match(format);\n if (matches) {\n // Book should be a bookId or an english name\n const [book, chapter = undefined, verse = undefined] = matches.slice(1);\n const englishName = getBookIdFromEnglishName(book);\n\n if (Canon.isBookIdValid(book) || englishName) {\n updateReference(\n englishName ?? book,\n true,\n chapter ? parseInt(chapter, 10) : 1,\n verse ? parseInt(verse, 10) : 1,\n );\n }\n }\n });\n }, [updateReference, searchQuery]);\n\n const handleKeyDownInput = useCallback(\n (event: ReactKeyboardEvent) => {\n if (!isContentOpen) {\n setIsContentOpen(true);\n } else if (event.key === 'ArrowDown' || event.key === 'ArrowUp') {\n if (\n typeof menuItemRef !== 'undefined' &&\n // Ref uses null\n // eslint-disable-next-line no-null/no-null\n menuItemRef.current !== null\n ) {\n menuItemRef.current.focus();\n } else if (\n typeof contentRef !== 'undefined' &&\n // Ref uses null\n // eslint-disable-next-line no-null/no-null\n contentRef.current !== null\n ) {\n contentRef.current.focus();\n }\n event.preventDefault();\n }\n },\n [isContentOpen],\n );\n\n const handleKeyDownContent = (event: ReactKeyboardEvent) => {\n // When the dropdown menu has focus, key strokes should give focus to the input component,\n // unless they're navigation keys (arrows and enter)\n const { key } = event;\n if (\n key === 'ArrowRight' ||\n key === 'ArrowLeft' ||\n key === 'ArrowDown' ||\n key === 'ArrowUp' ||\n key === 'Enter'\n ) {\n return;\n }\n\n inputRef.current.dispatchEvent(new KeyboardEvent('keydown', { key }));\n inputRef.current.focus();\n };\n\n const handleKeyDownMenuItem = (event: ReactKeyboardEvent) => {\n const { key } = event;\n if (highlightedBookId === selectedBookId) {\n if (key === 'Enter') {\n event.preventDefault();\n updateReference(selectedBookId, true, highlightedChapter);\n return;\n }\n\n let chapterOffSet = 0;\n if (key === 'ArrowRight') {\n if (highlightedChapter < fetchEndChapter(highlightedBookId)) {\n chapterOffSet = 1;\n } else {\n event.preventDefault();\n return;\n }\n } else if (key === 'ArrowLeft') {\n if (highlightedChapter > 1) {\n chapterOffSet = -1;\n } else {\n event.preventDefault();\n return;\n }\n } else if (key === 'ArrowDown') {\n chapterOffSet = 6;\n } else if (key === 'ArrowUp') {\n chapterOffSet = -6;\n }\n if (\n highlightedChapter + chapterOffSet <= 0 ||\n highlightedChapter + chapterOffSet > fetchEndChapter(highlightedBookId)\n ) {\n setHighlightedChapter(0);\n } else if (chapterOffSet !== 0) {\n setHighlightedChapter(highlightedChapter + chapterOffSet);\n event.preventDefault();\n }\n }\n };\n\n useEffect(() => {\n if (selectedBookId === highlightedBookId) {\n if (selectedBookId === Canon.bookNumberToId(scrRef.bookNum)) {\n setHighlightedChapter(scrRef.chapterNum);\n } else {\n setHighlightedChapter(1);\n }\n } else {\n setHighlightedChapter(0);\n }\n }, [highlightedBookId, scrRef.bookNum, scrRef.chapterNum, selectedBookId]);\n\n // The purpose of these useLayoutEffects and timeout is to delay the scroll just\n // enough so that the refs are defined and available when they are used after the timeout\n useLayoutEffect(() => {\n setIsContentOpenDelayed(isContentOpen);\n }, [isContentOpen]);\n\n useLayoutEffect(() => {\n const scrollTimeout = setTimeout(() => {\n if (isContentOpenDelayed && contentRef.current && menuItemRef.current) {\n const menuItemOffsetTop = menuItemRef.current.offsetTop;\n const scrollPosition = menuItemOffsetTop - SCROLL_OFFSET;\n contentRef.current.scrollTo({ top: scrollPosition, behavior: 'instant' });\n }\n }, 10);\n return () => {\n clearTimeout(scrollTimeout);\n };\n }, [isContentOpenDelayed]);\n\n return (\n
    \n \n \n {\n setSelectedBookId(Canon.bookNumberToId(scrRef.bookNum));\n setHighlightedBookId(Canon.bookNumberToId(scrRef.bookNum));\n setHighlightedChapter(scrRef.chapterNum > 0 ? scrRef.chapterNum : 0);\n setIsContentOpen(true);\n inputRef.current.focus();\n }}\n onFocus={() => {\n // Radix thinks we want to close because the input is being focused. Prevent that\n shouldPreventAutoClosing.current = true;\n }}\n handleSubmit={handleInputSubmit}\n placeholder={`${Canon.bookNumberToEnglishName(scrRef.bookNum)} ${scrRef.chapterNum}:${scrRef.verseNum}`}\n />\n \n \n console.log('sorting')}\n handleLocationHistory={() => console.log('location history')}\n handleBookmarks={() => console.log('bookmarks')}\n />\n {BOOK_TYPE_ARRAY.map(\n (bookType, bookTypeIndex) =>\n fetchFilteredBooks(bookType).length > 0 && (\n
    \n \n {BOOK_TYPE_LABELS[bookType]}\n \n\n {fetchFilteredBooks(bookType).map((bookId) => (\n
    \n updateReference(bookId, false)}\n isSelected={selectedBookId === bookId}\n handleHighlightBook={() => setHighlightedBookId(bookId)}\n handleKeyDown={handleKeyDownMenuItem}\n bookType={bookType}\n ref={(element: HTMLDivElement) => {\n if (selectedBookId === bookId) menuItemRef.current = element;\n }}\n >\n {\n setHighlightedChapter(chapterNumber);\n }}\n />\n \n
    \n ))}\n {BOOK_TYPE_ARRAY.length - 1 !== bookTypeIndex ? (\n \n ) : undefined}\n
    \n ),\n )}\n \n
    \n
    \n );\n}\n\nexport default BookChapterControl;\n","import React from 'react';\nimport { Slot } from '@radix-ui/react-slot';\nimport { cva, type VariantProps } from 'class-variance-authority';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport const buttonVariants = cva(\n 'pr-twp tw-inline-flex tw-items-center tw-justify-center tw-whitespace-nowrap tw-rounded-md tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-colors focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50',\n {\n variants: {\n variant: {\n default: 'tw-bg-primary tw-text-primary-foreground hover:tw-bg-primary/90',\n destructive: 'tw-bg-destructive tw-text-destructive-foreground hover:tw-bg-destructive/90',\n outline:\n 'tw-border tw-border-input tw-bg-background hover:tw-bg-accent hover:tw-text-accent-foreground',\n secondary: 'tw-bg-secondary tw-text-secondary-foreground hover:tw-bg-secondary/80',\n ghost: 'hover:tw-bg-accent hover:tw-text-accent-foreground',\n link: 'tw-text-primary tw-underline-offset-4 hover:tw-underline',\n },\n size: {\n default: 'tw-h-10 tw-px-4 tw-py-2',\n sm: 'tw-h-9 tw-rounded-md tw-px-3',\n lg: 'tw-h-11 tw-rounded-md tw-px-8',\n icon: 'tw-h-10 tw-w-10',\n },\n },\n defaultVariants: {\n variant: 'default',\n size: 'default',\n },\n },\n);\n\nexport interface ButtonProps\n extends React.ButtonHTMLAttributes,\n VariantProps {\n asChild?: boolean;\n}\n\nexport const Button = React.forwardRef(\n ({ className, variant, size, asChild = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'button';\n return (\n \n );\n },\n);\nButton.displayName = 'Button';\n","import React from 'react';\nimport * as LabelPrimitive from '@radix-ui/react-label';\nimport { cva, type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst labelVariants = cva(\n 'tw-text-sm tw-font-medium tw-leading-none peer-disabled:tw-cursor-not-allowed peer-disabled:tw-opacity-70',\n);\n\nexport const Label = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef & VariantProps\n>(({ className, ...props }, ref) => (\n \n));\nLabel.displayName = LabelPrimitive.Root.displayName;\n","import React from 'react';\nimport * as RadioGroupPrimitive from '@radix-ui/react-radio-group';\nimport { Circle } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst RadioGroup = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => {\n return (\n \n );\n});\nRadioGroup.displayName = RadioGroupPrimitive.Root.displayName;\n\nconst RadioGroupItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => {\n return (\n \n \n \n \n \n );\n});\nRadioGroupItem.displayName = RadioGroupPrimitive.Item.displayName;\n\nexport { RadioGroup, RadioGroupItem };\n","import React from 'react';\nimport * as PopoverPrimitive from '@radix-ui/react-popover';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Popover = PopoverPrimitive.Root;\n\nconst PopoverTrigger = PopoverPrimitive.Trigger;\n\nconst PopoverContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, align = 'center', sideOffset = 4, ...props }, ref) => (\n \n \n \n));\nPopoverContent.displayName = PopoverPrimitive.Content.displayName;\n\nexport { Popover, PopoverTrigger, PopoverContent };\n","import React from 'react';\nimport * as DialogPrimitive from '@radix-ui/react-dialog';\nimport { X } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Dialog = DialogPrimitive.Root;\n\nconst DialogTrigger = DialogPrimitive.Trigger;\n\nconst DialogPortal = DialogPrimitive.Portal;\n\nconst DialogClose = DialogPrimitive.Close;\n\nconst DialogOverlay = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nDialogOverlay.displayName = DialogPrimitive.Overlay.displayName;\n\nconst DialogContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, ...props }, ref) => (\n \n \n \n {children}\n \n \n Close\n \n \n \n));\nDialogContent.displayName = DialogPrimitive.Content.displayName;\n\nfunction DialogHeader({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nDialogHeader.displayName = 'DialogHeader';\n\nfunction DialogFooter({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nDialogFooter.displayName = 'DialogFooter';\n\nconst DialogTitle = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nDialogTitle.displayName = DialogPrimitive.Title.displayName;\n\nconst DialogDescription = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nDialogDescription.displayName = DialogPrimitive.Description.displayName;\n\nexport {\n Dialog,\n DialogPortal,\n DialogOverlay,\n DialogClose,\n DialogTrigger,\n DialogContent,\n DialogHeader,\n DialogFooter,\n DialogTitle,\n DialogDescription,\n};\n","import React from 'react';\nimport { type DialogProps } from '@radix-ui/react-dialog';\nimport { Command as CommandPrimitive } from 'cmdk';\nimport { Search } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Dialog, DialogContent } from '@/components/shadcn-ui/dialog';\n\nconst Command = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nCommand.displayName = CommandPrimitive.displayName;\n\ninterface CommandDialogProps extends DialogProps {}\n\nfunction CommandDialog({ children, ...props }: CommandDialogProps) {\n return (\n \n \n \n {children}\n \n \n \n );\n}\n\nconst CommandInput = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n
    \n \n \n
    \n));\n\nCommandInput.displayName = CommandPrimitive.Input.displayName;\n\nconst CommandList = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\n\nCommandList.displayName = CommandPrimitive.List.displayName;\n\nconst CommandEmpty = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>((props, ref) => (\n \n));\n\nCommandEmpty.displayName = CommandPrimitive.Empty.displayName;\n\nconst CommandGroup = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\n\nCommandGroup.displayName = CommandPrimitive.Group.displayName;\n\nconst CommandSeparator = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nCommandSeparator.displayName = CommandPrimitive.Separator.displayName;\n\nconst CommandItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\n\nCommandItem.displayName = CommandPrimitive.Item.displayName;\n\nfunction CommandShortcut({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nCommandShortcut.displayName = 'CommandShortcut';\n\nexport {\n Command,\n CommandDialog,\n CommandInput,\n CommandList,\n CommandEmpty,\n CommandGroup,\n CommandItem,\n CommandShortcut,\n CommandSeparator,\n};\n","import { useState } from 'react';\nimport { Check, ChevronsUpDown } from 'lucide-react';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport { Popover, PopoverContent, PopoverTrigger } from '@/components/shadcn-ui/popover';\nimport {\n Command,\n CommandEmpty,\n CommandInput,\n CommandItem,\n CommandList,\n} from '@/components/shadcn-ui/command';\nimport { PopoverProps } from '@radix-ui/react-popover';\n\nexport type ComboBoxLabelOption = { label: string };\nexport type ComboBoxOption = string | number | ComboBoxLabelOption;\n\nexport type ComboBoxProps = {\n /** Optional unique identifier */\n id?: string;\n /** Text label title for combobox */\n /** List of available options for the dropdown menu */\n options?: readonly T[];\n /** Additional css classes to help with unique styling of the combo box button */\n buttonClassName?: string;\n /** Additional css classes to help with unique styling of the combo box popover */\n popoverContentClassName?: string;\n /**\n * The selected value that the combo box currently holds. Must be shallow equal to one of the\n * options entries.\n */\n value?: T;\n /** Triggers when content of textfield is changed */\n onChange?: (newValue: T) => void;\n /** Used to determine the string value for a given option. */\n getOptionLabel?: (option: ComboBoxOption) => string;\n /** Text displayed on button if `value` is undefined */\n buttonPlaceholder?: string;\n /** Placeholder text for text field */\n textPlaceholder?: string;\n /** Text to display when no options match input */\n commandEmptyMessage?: string;\n /** Variant of button */\n buttonVariant?: ButtonProps['variant'];\n /** Text direction ltr or rtl */\n dir?: Direction;\n /** Optional boolean to set if trigger should be disabled */\n isDisabled?: boolean;\n} & PopoverProps;\n\ntype Direction = 'ltr' | 'rtl';\n\nfunction getOptionLabelDefault(option: ComboBoxOption): string {\n if (typeof option === 'string') {\n return option;\n }\n if (typeof option === 'number') {\n return option.toString();\n }\n return option.label;\n}\n\n/**\n * Autocomplete input and command palette with a list of suggestions.\n *\n * Thanks to Shadcn for heavy inspiration and documentation\n * https://ui.shadcn.com/docs/components/combobox\n */\nfunction ComboBox({\n id,\n options = [],\n buttonClassName,\n popoverContentClassName,\n value,\n onChange = () => {},\n getOptionLabel = getOptionLabelDefault,\n buttonPlaceholder = '',\n textPlaceholder = '',\n commandEmptyMessage = 'No option found',\n buttonVariant = 'outline',\n dir = 'ltr',\n isDisabled = false,\n ...props\n}: ComboBoxProps) {\n const [open, setOpen] = useState(false);\n\n return (\n \n \n \n \n {value ? getOptionLabel(value) : buttonPlaceholder}\n \n \n \n \n \n \n \n {commandEmptyMessage}\n \n {options.map((option) => (\n {\n onChange(option);\n setOpen(false);\n }}\n >\n \n {getOptionLabel(option)}\n \n ))}\n \n \n \n \n );\n}\n\nexport default ComboBox;\n","import { useMemo } from 'react';\nimport ComboBox from '@/components/basics/combo-box.component';\nimport { Label } from '@/components/shadcn-ui/label';\n\nexport type ChapterRangeSelectorProps = {\n startChapter: number;\n endChapter: number;\n handleSelectStartChapter: (chapter: number) => void;\n handleSelectEndChapter: (chapter: number) => void;\n isDisabled?: boolean;\n chapterCount: number;\n};\n\nexport default function ChapterRangeSelector({\n startChapter,\n endChapter,\n handleSelectStartChapter,\n handleSelectEndChapter,\n isDisabled = false,\n chapterCount,\n}: ChapterRangeSelectorProps) {\n const chapterOptions = useMemo(\n () => Array.from({ length: chapterCount }, (_, index) => index + 1),\n [chapterCount],\n );\n\n const onChangeStartChapter = (value: number) => {\n handleSelectStartChapter(value);\n if (value > endChapter) {\n handleSelectEndChapter(value);\n }\n };\n\n const onChangeEndChapter = (value: number) => {\n handleSelectEndChapter(value);\n if (value < startChapter) {\n handleSelectStartChapter(value);\n }\n };\n\n return (\n <>\n \n option.toString()}\n value={startChapter}\n />\n\n \n option.toString()}\n value={endChapter}\n />\n \n );\n}\n","import { Button } from '@/components/shadcn-ui/button';\nimport { Label } from '@/components/shadcn-ui/label';\nimport { RadioGroup, RadioGroupItem } from '@/components/shadcn-ui/radio-group';\nimport { Canon } from '@sillsdev/scripture';\nimport { LocalizedStringValue } from 'platform-bible-utils';\nimport { useState } from 'react';\nimport ChapterRangeSelector, {\n ChapterRangeSelectorProps,\n} from '../basics/chapter-range-selector.component';\n\nexport enum BookSelectionMode {\n CURRENT_BOOK = 'current book',\n CHOOSE_BOOKS = 'choose books',\n}\n\n/**\n * Object containing all keys used for localization in this component. If you're using this\n * component in an extension, you can pass it into the useLocalizedStrings hook to easily obtain the\n * localized strings and pass them into the localizedStrings prop of this component\n */\nexport const BOOK_SELECTOR_STRING_KEYS = Object.freeze([\n '%webView_bookSelector_currentBook%',\n '%webView_bookSelector_choose%',\n '%webView_bookSelector_chooseBooks%',\n] as const);\n\nexport type BookSelectorLocalizedStrings = {\n [localizedInventoryKey in (typeof BOOK_SELECTOR_STRING_KEYS)[number]]?: LocalizedStringValue;\n};\n\n/**\n * Gets the localized value for the provided key\n *\n * @param strings Object containing localized string\n * @param key Key for a localized string\n * @returns The localized value for the provided key, if available. Returns the key if no localized\n * value is available\n */\nconst localizeString = (\n strings: BookSelectorLocalizedStrings,\n key: keyof BookSelectorLocalizedStrings,\n) => {\n return strings[key] ?? key;\n};\n\ntype BookSelectorProps = ChapterRangeSelectorProps & {\n handleBookSelectionModeChange: (newMode: BookSelectionMode) => void;\n currentBookName: string;\n onSelectBooks: () => void;\n selectedBookIds: string[];\n localizedStrings: BookSelectorLocalizedStrings;\n};\n\nexport default function BookSelector({\n handleBookSelectionModeChange,\n currentBookName,\n onSelectBooks,\n selectedBookIds,\n chapterCount,\n endChapter,\n handleSelectEndChapter,\n startChapter,\n handleSelectStartChapter,\n localizedStrings,\n}: BookSelectorProps) {\n const currentBookText = localizeString(localizedStrings, '%webView_bookSelector_currentBook%');\n const chooseText = localizeString(localizedStrings, '%webView_bookSelector_choose%');\n const chooseBooksText = localizeString(localizedStrings, '%webView_bookSelector_chooseBooks%');\n\n const [bookSelectionMode, setBookSelectionMode] = useState(\n BookSelectionMode.CURRENT_BOOK,\n );\n\n const onSelectionModeChange = (newMode: BookSelectionMode) => {\n setBookSelectionMode(newMode);\n handleBookSelectionModeChange(newMode);\n };\n\n return (\n onSelectionModeChange(value as BookSelectionMode)}\n >\n
    \n
    \n
    \n \n \n
    \n \n
    \n \n
    \n
    \n
    \n
    \n \n \n
    \n \n onSelectBooks()}\n >\n {chooseText}\n \n
    \n
    \n \n );\n}\n","import { DropdownMenuTrigger } from '@radix-ui/react-dropdown-menu';\nimport { FilterIcon } from 'lucide-react';\nimport { Table } from '@tanstack/react-table';\n\nimport { Button } from '@/components/shadcn-ui/button';\nimport {\n DropdownMenu,\n DropdownMenuCheckboxItem,\n DropdownMenuContent,\n DropdownMenuLabel,\n DropdownMenuSeparator,\n} from '@/components/shadcn-ui/dropdown-menu';\n\ninterface DataTableViewOptionsProps {\n table: Table;\n}\n\nfunction DataTableViewOptions({ table }: DataTableViewOptionsProps) {\n return (\n \n \n \n \n \n Toggle columns\n \n {table\n .getAllColumns()\n .filter((column) => column.getCanHide())\n .map((column) => {\n return (\n column.toggleVisibility(!!value)}\n >\n {column.id}\n \n );\n })}\n \n \n );\n}\n\nexport default DataTableViewOptions;\n","import React from 'react';\nimport * as SelectPrimitive from '@radix-ui/react-select';\nimport { Check, ChevronDown, ChevronUp } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Select = SelectPrimitive.Root;\n\nconst SelectGroup = SelectPrimitive.Group;\n\nconst SelectValue = SelectPrimitive.Value;\n\nconst SelectTrigger = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, ...props }, ref) => (\n span]:tw-line-clamp-1',\n className,\n )}\n {...props}\n >\n {children}\n \n \n \n \n));\nSelectTrigger.displayName = SelectPrimitive.Trigger.displayName;\n\nconst SelectScrollUpButton = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n));\nSelectScrollUpButton.displayName = SelectPrimitive.ScrollUpButton.displayName;\n\nconst SelectScrollDownButton = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n));\nSelectScrollDownButton.displayName = SelectPrimitive.ScrollDownButton.displayName;\n\nconst SelectContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, position = 'popper', ...props }, ref) => (\n \n \n \n \n {children}\n \n \n \n \n));\nSelectContent.displayName = SelectPrimitive.Content.displayName;\n\nconst SelectLabel = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSelectLabel.displayName = SelectPrimitive.Label.displayName;\n\nconst SelectItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, ...props }, ref) => (\n \n \n \n \n \n \n\n {children}\n \n));\nSelectItem.displayName = SelectPrimitive.Item.displayName;\n\nconst SelectSeparator = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSelectSeparator.displayName = SelectPrimitive.Separator.displayName;\n\nexport {\n Select,\n SelectGroup,\n SelectValue,\n SelectTrigger,\n SelectContent,\n SelectLabel,\n SelectItem,\n SelectSeparator,\n SelectScrollUpButton,\n SelectScrollDownButton,\n};\n","import { ChevronLeftIcon, ChevronRightIcon, ArrowLeftIcon, ArrowRightIcon } from 'lucide-react';\nimport { Table } from '@tanstack/react-table';\n\nimport { Button } from '@/components/shadcn-ui/button';\nimport {\n Select,\n SelectContent,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\n\ninterface DataTablePaginationProps {\n table: Table;\n}\n\nfunction DataTablePagination({ table }: DataTablePaginationProps) {\n return (\n
    \n
    \n
    \n {table.getFilteredSelectedRowModel().rows.length} of{' '}\n {table.getFilteredRowModel().rows.length} row(s) selected\n
    \n
    \n

    Rows per page

    \n {\n table.setPageSize(Number(value));\n }}\n >\n \n \n \n \n {[10, 20, 30, 40, 50].map((pageSize) => (\n \n {pageSize}\n \n ))}\n \n \n
    \n
    \n Page {table.getState().pagination.pageIndex + 1} of {table.getPageCount()}\n
    \n
    \n table.setPageIndex(0)}\n disabled={!table.getCanPreviousPage()}\n >\n Go to first page\n \n \n table.previousPage()}\n disabled={!table.getCanPreviousPage()}\n >\n Go to previous page\n \n \n table.nextPage()}\n disabled={!table.getCanNextPage()}\n >\n Go to next page\n \n \n table.setPageIndex(table.getPageCount() - 1)}\n disabled={!table.getCanNextPage()}\n >\n Go to last page\n \n \n
    \n
    \n
    \n );\n}\n\nexport default DataTablePagination;\n","import React from 'react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Table = React.forwardRef<\n HTMLTableElement,\n React.HTMLAttributes & { stickyHeader?: boolean }\n>(({ className, stickyHeader, ...props }, ref) => (\n
    \n \n
    \n));\nTable.displayName = 'Table';\n\nconst TableHeader = React.forwardRef<\n HTMLTableSectionElement,\n React.HTMLAttributes & { stickyHeader?: boolean }\n>(({ className, stickyHeader, ...props }, ref) => (\n \n));\nTableHeader.displayName = 'TableHeader';\n\nconst TableBody = React.forwardRef<\n HTMLTableSectionElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableBody.displayName = 'TableBody';\n\nconst TableFooter = React.forwardRef<\n HTMLTableSectionElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n tr]:last:tw-border-b-0', className)}\n {...props}\n />\n));\nTableFooter.displayName = 'TableFooter';\n\nconst TableRow = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nTableRow.displayName = 'TableRow';\n\nconst TableHead = React.forwardRef<\n HTMLTableCellElement,\n React.ThHTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableHead.displayName = 'TableHead';\n\nconst TableCell = React.forwardRef<\n HTMLTableCellElement,\n React.TdHTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableCell.displayName = 'TableCell';\n\nconst TableCaption = React.forwardRef<\n HTMLTableCaptionElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableCaption.displayName = 'TableCaption';\n\nexport { Table, TableHeader, TableBody, TableFooter, TableHead, TableRow, TableCell, TableCaption };\n","import { useState } from 'react';\n\nimport {\n ColumnFiltersState,\n flexRender,\n getCoreRowModel,\n getFilteredRowModel,\n getPaginationRowModel,\n getSortedRowModel,\n SortingState,\n ColumnDef as TSColumnDef,\n Row as TSRow,\n RowSelectionState as TSRowSelectionState,\n SortDirection as TSSortDirection,\n Table as TSTable,\n useReactTable,\n VisibilityState,\n} from '@tanstack/react-table';\n\nimport DataTableViewOptions from '@/components/advanced/data-table/data-table-column-toggle.component';\nimport DataTablePagination from '@/components/advanced/data-table/data-table-pagination.component';\nimport { Button } from '@/components/shadcn-ui/button';\nimport {\n Table,\n TableBody,\n TableCell,\n TableHead,\n TableHeader,\n TableRow,\n} from '@/components/shadcn-ui/table';\n\nexport type ColumnDef = TSColumnDef;\nexport type RowContents = TSRow;\nexport type TableContents = TSTable;\nexport type SortDirection = TSSortDirection;\nexport type RowSelectionState = TSRowSelectionState;\n\ninterface DataTableProps {\n columns: ColumnDef[];\n data: TData[];\n enablePagination?: boolean;\n showPaginationControls?: boolean;\n showColumnVisibilityControls?: boolean;\n stickyHeader?: boolean;\n onRowClickHandler?: (row: RowContents, table: TableContents) => void;\n}\n\n/**\n * Feature-rich table component that infuses our basic shadcn-based Table component with features\n * from TanStack's React Table library\n */\nfunction DataTable({\n columns,\n data,\n enablePagination = false,\n showPaginationControls = false,\n showColumnVisibilityControls = false,\n stickyHeader = false,\n onRowClickHandler = () => {},\n}: DataTableProps) {\n const [sorting, setSorting] = useState([]);\n const [columnFilters, setColumnFilters] = useState([]);\n const [columnVisibility, setColumnVisibility] = useState({});\n const [rowSelection, setRowSelection] = useState({});\n\n const table = useReactTable({\n data,\n columns,\n getCoreRowModel: getCoreRowModel(),\n ...(enablePagination && { getPaginationRowModel: getPaginationRowModel() }),\n onSortingChange: setSorting,\n getSortedRowModel: getSortedRowModel(),\n onColumnFiltersChange: setColumnFilters,\n getFilteredRowModel: getFilteredRowModel(),\n onColumnVisibilityChange: setColumnVisibility,\n onRowSelectionChange: setRowSelection,\n state: {\n sorting,\n columnFilters,\n columnVisibility,\n rowSelection,\n },\n });\n\n return (\n
    \n {showColumnVisibilityControls && }\n \n \n {table.getHeaderGroups().map((headerGroup) => (\n \n {headerGroup.headers.map((header) => {\n return (\n \n {header.isPlaceholder\n ? undefined\n : flexRender(header.column.columnDef.header, header.getContext())}\n \n );\n })}\n \n ))}\n \n \n {table.getRowModel().rows?.length ? (\n table.getRowModel().rows.map((row) => (\n onRowClickHandler(row, table)}\n key={row.id}\n data-state={row.getIsSelected() && 'selected'}\n >\n {row.getVisibleCells().map((cell) => (\n \n {flexRender(cell.column.columnDef.cell, cell.getContext())}\n \n ))}\n \n ))\n ) : (\n \n \n No results.\n \n \n )}\n \n
    \n {enablePagination && (\n
    \n table.previousPage()}\n disabled={!table.getCanPreviousPage()}\n >\n Previous\n \n table.nextPage()}\n disabled={!table.getCanNextPage()}\n >\n Next\n \n
    \n )}\n {enablePagination && showPaginationControls && }\n
    \n );\n}\n\nexport default DataTable;\n","import {\n Table,\n TableBody,\n TableCell,\n TableHead,\n TableHeader,\n TableRow,\n} from '@/components/shadcn-ui/table';\nimport { Canon } from '@sillsdev/scripture';\nimport { deepEqual, LanguageStrings, ScriptureReference } from 'platform-bible-utils';\nimport { useMemo } from 'react';\nimport { InventoryItemOccurrence } from './inventory-utils';\n\n/** Props for the OccurrencesTable component */\ntype OccurrencesTableProps = {\n /** Data that contains scriptures references and snippets of scripture */\n occurrenceData: InventoryItemOccurrence[];\n /** Callback function that is executed when the scripture reference is changed */\n setScriptureReference: (scriptureReference: ScriptureReference) => void;\n /**\n * Object with all localized strings that the OccurrencesTable needs to work well across multiple\n * languages\n */\n localizedStrings: LanguageStrings;\n};\n\n/**\n * Table that shows occurrences of specified inventory item(s). The first column shows the related\n * scripture reference. The second column shows the snippet of scripture that contains the specified\n * inventory item\n */\nfunction OccurrencesTable({\n occurrenceData,\n setScriptureReference,\n localizedStrings,\n}: OccurrencesTableProps) {\n const referenceHeaderText =\n localizedStrings['%webView_inventory_occurrences_table_header_reference%'];\n const occurrenceHeaderText =\n localizedStrings['%webView_inventory_occurrences_table_header_occurrence%'];\n\n const occurrences: InventoryItemOccurrence[] = useMemo(() => {\n const uniqueOccurrences: InventoryItemOccurrence[] = [];\n\n occurrenceData.forEach((occurrence) => {\n if (!uniqueOccurrences.some((uniqueOccurrence) => deepEqual(uniqueOccurrence, occurrence))) {\n uniqueOccurrences.push(occurrence);\n }\n });\n\n return uniqueOccurrences;\n }, [occurrenceData]);\n\n return (\n \n \n \n {referenceHeaderText}\n {occurrenceHeaderText}\n \n \n \n {occurrences.length > 0 &&\n occurrences.map((occurrence) => (\n {\n setScriptureReference(occurrence.reference);\n }}\n >\n {`${Canon.bookNumberToEnglishName(occurrence.reference.bookNum)} ${occurrence.reference.chapterNum}:${occurrence.reference.verseNum}`}\n {occurrence.text}\n \n ))}\n \n
    \n );\n}\n\nexport default OccurrencesTable;\n","import React from 'react';\nimport * as CheckboxPrimitive from '@radix-ui/react-checkbox';\nimport { Check } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Checkbox = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n \n \n));\nCheckbox.displayName = CheckboxPrimitive.Root.displayName;\n\nexport default Checkbox;\n","import { Canon } from '@sillsdev/scripture';\nimport { ScriptureReference } from 'platform-bible-utils';\n\n/* #region Types */\n\n/**\n * Status of items that appear in inventories. 'approved' and 'unapproved' items are defined in the\n * project's `Settings.xml`. All other items are defined as 'unknown'\n */\nexport type Status = 'approved' | 'unapproved' | 'unknown';\n\n/** Occurrence of item in inventory. Primarily used by table that shows occurrences */\nexport type InventoryItemOccurrence = {\n /** Reference to scripture where the item appears */\n reference: ScriptureReference;\n /** Snippet of scripture that contains the occurrence */\n text: string;\n};\n\n/** Data structure that contains all information on an item that is shown in an inventory */\nexport type InventoryTableData = {\n /**\n * The item (e.g. a character in the characters inventory, a marker in the marker inventory) In\n * most cases the array will only have one element. In case of additional items (e.g. the\n * preceding marker in the markers check), the primary item should be stored in the first index.\n * To show additional items in the inventory, make sure to configure the `additionalItemsLabels`\n * prop for the Inventory component\n */\n items: string[];\n /** The number of times this item occurs in the selected scope */\n count: number;\n /** The status of this item (see documentation for `Status` type for more information) */\n status: Status;\n /** Occurrences of this item in the scripture text for the selected scope */\n occurrences: InventoryItemOccurrence[];\n};\n\n/* #endregion */\n\n/* #region Functions */\n\n/**\n * Splits USFM string into shorter line-like segments\n *\n * @param text A single (likely very large) USFM string\n * @returns An array containing the input text, split into shorter segments\n */\nexport const getLinesFromUSFM = (text: string) => {\n // Splits on (CR)LF, CR, \\v, \\c and \\id\n return text.split(/(?:\\r?\\n|\\r)|(?=(?:\\\\(?:v|c|id)))/g);\n};\n\n/**\n * Extracts chapter or verse number from USFM strings that start with a \\c or \\v marker\n *\n * @param text USFM string that is expected to start with \\c or \\v marker\n * @returns Chapter or verse number if one is found. Else returns 0.\n */\nexport const getNumberFromUSFM = (text: string): number | undefined => {\n // Captures all digits that follow \\v or \\c markers followed by whitespace located at the start of a string\n const regex = /^\\\\[vc]\\s+(\\d+)/;\n const match = text.match(regex);\n\n if (match) {\n return +match[1];\n }\n return undefined;\n};\n\n/**\n * Gets book ID from USFM string that starts with the \\id marker, and returns book number for it\n *\n * @param text USFM string that is expected to start with \\id marker\n * @returns Book number corresponding to the \\id marker in the input text. Returns 0 if no marker is\n * found or the marker is not valid\n */\nexport const getBookNumFromId = (text: string): number => {\n // Captures all digits that follow an \\id marker followed by whitespace located at the start of a string\n const match = text.match(/^\\\\id\\s+([A-Za-z]+)/);\n if (match) {\n return Canon.bookIdToNumber(match[1]);\n }\n return 0;\n};\n\n/**\n * Gets the status for an item, typically used in the Inventory component\n *\n * @param item The item for which the status is being requested\n * @param approvedItems Array of approved items, typically as defined in `Settings.xml`\n * @param unapprovedItems Array of unapproved items, typically as defined in `Settings.xml`\n * @returns The status for the specified item\n */\nexport const getStatusForItem = (\n item: string,\n approvedItems: string[],\n unapprovedItems: string[],\n): Status => {\n if (unapprovedItems.includes(item)) return 'unapproved';\n if (approvedItems.includes(item)) return 'approved';\n return 'unknown';\n};\n\n/* #endregion */\n","import React from 'react';\nimport * as TogglePrimitive from '@radix-ui/react-toggle';\nimport { cva, type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst toggleVariants = cva(\n 'pr-twp tw-inline-flex tw-items-center tw-justify-center tw-rounded-md tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-colors hover:tw-bg-muted hover:tw-text-muted-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50 data-[state=on]:tw-bg-accent data-[state=on]:tw-text-accent-foreground',\n {\n variants: {\n variant: {\n default: 'tw-bg-transparent',\n outline:\n 'tw-border tw-border-input tw-bg-transparent hover:tw-bg-accent hover:tw-text-accent-foreground',\n },\n size: {\n default: 'tw-h-10 tw-px-3',\n sm: 'tw-h-9 tw-px-2.5',\n lg: 'tw-h-11 tw-px-5',\n },\n },\n defaultVariants: {\n variant: 'default',\n size: 'default',\n },\n },\n);\n\nconst Toggle = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef & VariantProps\n>(({ className, variant, size, ...props }, ref) => (\n \n));\n\nToggle.displayName = TogglePrimitive.Root.displayName;\n\nexport { Toggle, toggleVariants };\n","import React from 'react';\nimport * as ToggleGroupPrimitive from '@radix-ui/react-toggle-group';\nimport { type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { toggleVariants } from '@/components/shadcn-ui/toggle';\n\nconst ToggleGroupContext = React.createContext>({\n size: 'default',\n variant: 'default',\n});\n\nconst ToggleGroup = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef &\n VariantProps\n>(({ className, variant, size, children, ...props }, ref) => (\n \n \n {children}\n \n \n));\n\nToggleGroup.displayName = ToggleGroupPrimitive.Root.displayName;\n\nconst ToggleGroupItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef &\n VariantProps\n>(({ className, children, variant, size, ...props }, ref) => {\n const context = React.useContext(ToggleGroupContext);\n\n return (\n \n {children}\n \n );\n});\n\nToggleGroupItem.displayName = ToggleGroupPrimitive.Item.displayName;\n\nexport { ToggleGroup, ToggleGroupItem };\n","import { ColumnDef, SortDirection } from '@/components/advanced/data-table/data-table.component';\nimport { Button } from '@/components/shadcn-ui/button';\nimport { ToggleGroup, ToggleGroupItem } from '@/components/shadcn-ui/toggle-group';\nimport {\n ArrowDownIcon,\n ArrowUpDownIcon,\n ArrowUpIcon,\n CircleCheckIcon,\n CircleHelpIcon,\n CircleXIcon,\n} from 'lucide-react';\nimport { ReactNode } from 'react';\nimport { InventoryTableData, Status } from './inventory-utils';\n\n/**\n * Gets an icon that indicates the current sorting direction based on the provided input\n *\n * @param sortDirection Sorting direction. Can be ascending ('asc'), descending ('desc') or false (\n * i.e. not sorted)\n * @returns The appropriate sorting icon for the provided sorting direction\n */\nconst getSortingIcon = (sortDirection: false | SortDirection): ReactNode => {\n if (sortDirection === 'asc') {\n return ;\n }\n if (sortDirection === 'desc') {\n return ;\n }\n return ;\n};\n\n/**\n * Function that creates the item column for inventories\n *\n * @param itemLabel Localized label for the item column (e.g. 'Character', 'Repeated Word', etc.)\n * @returns Column that shows the inventory items. Should be used with the DataTable component\n */\nexport const inventoryItemColumn = (itemLabel: string): ColumnDef => {\n return {\n accessorKey: 'item',\n accessorFn: (row: InventoryTableData) => row.items[0],\n header: ({ column }) => (\n \n ),\n };\n};\n\n/**\n * Function that creates the additional item columns for inventories\n *\n * @param additionalItemLabel Localized label for the additional item column (e.g. 'Preceding\n * Marker')\n * @param additionalItemIndex Index that locates the desired item in the items array of the\n * inventory\n * @returns Column that shows additional inventory items. Should be used with the DataTable\n * component\n */\nexport const inventoryAdditionalItemColumn = (\n additionalItemLabel: string,\n additionalItemIndex: number,\n): ColumnDef => {\n return {\n accessorKey: `item${additionalItemIndex}`,\n accessorFn: (row: InventoryTableData) => row.items[additionalItemIndex],\n header: ({ column }) => (\n \n ),\n };\n};\n\n/**\n * Function that creates the count column for inventories. Should be used with the DataTable\n * component.\n *\n * @param itemLabel Localized label for the count column\n * @returns Column that shows the number of occurrences of the related inventory items\n */\nexport const inventoryCountColumn = (countLabel: string): ColumnDef => {\n return {\n accessorKey: 'count',\n header: ({ column }) => (\n
    \n \n
    \n ),\n cell: ({ row }) =>
    {row.getValue('count')}
    ,\n };\n};\n\n/**\n * Function that updates project settings when status for item(s) changes\n *\n * @param changedItems Array of items for which the status is being updated\n * @param newStatus The status that the items are being given\n * @param approvedItems Array of currently approved items\n * @param onApprovedItemsChange Callback function that stores the updated list of approved items\n * @param unapprovedItems Array of currently unapproved items\n * @param onUnapprovedItemsChange Callback function that stores the updated list of unapproved items\n */\nconst statusChangeHandler = (\n changedItems: string[],\n newStatus: Status,\n approvedItems: string[],\n onApprovedItemsChange: (items: string[]) => void,\n unapprovedItems: string[],\n onUnapprovedItemsChange: (items: string[]) => void,\n) => {\n let newApprovedItems: string[] = [...approvedItems];\n changedItems.forEach((item) => {\n if (newStatus === 'approved') {\n if (!newApprovedItems.includes(item)) {\n newApprovedItems.push(item);\n }\n } else {\n newApprovedItems = newApprovedItems.filter((validItem) => validItem !== item);\n }\n });\n onApprovedItemsChange(newApprovedItems);\n\n let newUnapprovedItems: string[] = [...unapprovedItems];\n changedItems.forEach((item) => {\n if (newStatus === 'unapproved') {\n if (!newUnapprovedItems.includes(item)) {\n newUnapprovedItems.push(item);\n }\n } else {\n newUnapprovedItems = newUnapprovedItems.filter((unapprovedItem) => unapprovedItem !== item);\n }\n });\n onUnapprovedItemsChange(newUnapprovedItems);\n};\n\n/**\n * Function that creates the status column for inventories. Should be used with the DataTable\n * component.\n *\n * @param statusLabel Localized label for the status column\n * @param approvedItems Array of approved items, typically as defined in `Settings.xml`\n * @param onApprovedItemsChange Callback function that stores the updated list of approved items\n * @param unapprovedItems Array of unapproved items, typically as defined in `Settings.xml`\n * @param onUnapprovedItemsChange Callback function that stores the updated list of unapproved items\n * @returns Column that shows the status buttons for the related inventory item. The button for the\n * current status of the item is selected\n */\nexport const inventoryStatusColumn = (\n statusLabel: string,\n approvedItems: string[],\n onApprovedItemsChange: (items: string[]) => void,\n unapprovedItems: string[],\n onUnapprovedItemsChange: (items: string[]) => void,\n): ColumnDef => {\n return {\n accessorKey: 'status',\n header: ({ column }) => {\n return (\n
    \n \n
    \n );\n },\n cell: ({ row }) => {\n const status: Status = row.getValue('status');\n const item: string = row.getValue('item');\n return (\n \n \n statusChangeHandler(\n [item],\n 'approved',\n approvedItems,\n onApprovedItemsChange,\n unapprovedItems,\n onUnapprovedItemsChange,\n )\n }\n value=\"approved\"\n >\n \n \n \n statusChangeHandler(\n [item],\n 'unapproved',\n approvedItems,\n onApprovedItemsChange,\n unapprovedItems,\n onUnapprovedItemsChange,\n )\n }\n value=\"unapproved\"\n >\n \n \n \n statusChangeHandler(\n [item],\n 'unknown',\n approvedItems,\n onApprovedItemsChange,\n unapprovedItems,\n onUnapprovedItemsChange,\n )\n }\n value=\"unknown\"\n >\n \n \n \n );\n },\n };\n};\n","import DataTable, {\n ColumnDef,\n RowContents,\n RowSelectionState,\n TableContents,\n} from '@/components/advanced/data-table/data-table.component';\nimport OccurrencesTable from '@/components/advanced/inventory/occurrences-table.component';\nimport Checkbox from '@/components/shadcn-ui/checkbox';\nimport { Input } from '@/components/shadcn-ui/input';\nimport { Label } from '@/components/shadcn-ui/label';\nimport {\n Select,\n SelectContent,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\nimport {\n deepEqual,\n LocalizedStringValue,\n ScriptureReference,\n substring,\n} from 'platform-bible-utils';\nimport { useEffect, useMemo, useState } from 'react';\nimport {\n getBookNumFromId,\n getLinesFromUSFM,\n getNumberFromUSFM,\n getStatusForItem,\n InventoryItemOccurrence,\n InventoryTableData,\n Status,\n} from './inventory-utils';\nimport { inventoryAdditionalItemColumn } from './inventory-columns';\n\n/**\n * Object containing all keys used for localization in this component. If you're using this\n * component in an extension, you can pass it into the useLocalizedStrings hook to easily obtain the\n * localized strings and pass them into the localizedStrings prop of this component\n */\nexport const INVENTORY_STRING_KEYS = Object.freeze([\n '%webView_inventory_all%',\n '%webView_inventory_approved%',\n '%webView_inventory_unapproved%',\n '%webView_inventory_unknown%',\n '%webView_inventory_scope_currentBook%',\n '%webView_inventory_scope_chapter%',\n '%webView_inventory_scope_verse%',\n '%webView_inventory_filter_text%',\n '%webView_inventory_show_additional_items%',\n '%webView_inventory_occurrences_table_header_reference%',\n '%webView_inventory_occurrences_table_header_occurrence%',\n] as const);\n\nexport type InventoryLocalizedStrings = {\n [localizedInventoryKey in (typeof INVENTORY_STRING_KEYS)[number]]?: LocalizedStringValue;\n};\n\n/** Scope of scripture that the inventory can operate on */\nexport type Scope = 'book' | 'chapter' | 'verse';\n\n/** Status values that the status filter can select from */\ntype StatusFilter = Status | 'all';\n\n/** Text labels for the inventory columns and the control components of additional inventory items */\ntype AdditionalItemsLabels = {\n checkboxText?: string;\n tableHeaders?: string[];\n};\n\n/**\n * Filters data that is shown in the DataTable section of the Inventory\n *\n * @param itemData All inventory items and their related information\n * @param statusFilter Allows filtering by status (i.e. show all items, or only items that are\n * 'approved', 'unapproved' or 'unknown')\n * @param textFilter Allows filtering by text. All items that include the filter text will be\n * selected.\n * @returns Array of items and their related information that are matched by the specified filters\n */\nconst filterItemData = (\n itemData: InventoryTableData[],\n statusFilter: StatusFilter,\n textFilter: string,\n): InventoryTableData[] => {\n let filteredItemData: InventoryTableData[] = itemData;\n\n if (statusFilter !== 'all') {\n filteredItemData = filteredItemData.filter(\n (item) =>\n (statusFilter === 'approved' && item.status === 'approved') ||\n (statusFilter === 'unapproved' && item.status === 'unapproved') ||\n (statusFilter === 'unknown' && item.status === 'unknown'),\n );\n }\n\n if (textFilter !== '')\n filteredItemData = filteredItemData.filter((item) => item.items[0].includes(textFilter));\n\n return filteredItemData;\n};\n\n/**\n * Turns array of strings into array of inventory items, along with their count and status\n *\n * @param text The source scripture text that is searched for inventory items\n * @param scriptureRef The scripture reference that the application is currently set to\n * @param approvedItems Array of approved items, typically as defined in `Settings.xml`\n * @param unapprovedItems Array of unapproved items, typically as defined in `Settings.xml`\n * @param itemRegex Regular expression that describes what items this Inventory should extract from\n * the provided scripture text\n * @returns Array of inventory items, along with their count and status\n */\nconst createTableData = (\n text: string | undefined,\n scriptureRef: ScriptureReference,\n approvedItems: string[],\n unapprovedItems: string[],\n itemRegex: RegExp,\n): InventoryTableData[] => {\n if (!text) return [];\n\n const tableData: InventoryTableData[] = [];\n\n let currentBook: number | undefined = scriptureRef.bookNum;\n let currentChapter: number | undefined = scriptureRef.chapterNum;\n let currentVerse: number | undefined = scriptureRef.verseNum;\n\n const lines = getLinesFromUSFM(text);\n\n lines.forEach((line: string) => {\n if (line.startsWith('\\\\id')) {\n currentBook = getBookNumFromId(line);\n currentChapter = 0;\n currentVerse = 0;\n }\n if (line.startsWith('\\\\c')) {\n currentChapter = getNumberFromUSFM(line);\n currentVerse = 0;\n }\n if (line.startsWith('\\\\v')) {\n currentVerse = getNumberFromUSFM(line);\n if (currentChapter === 0) {\n currentChapter = scriptureRef.chapterNum;\n }\n }\n\n let match: RegExpExecArray | undefined = itemRegex.exec(line) ?? undefined;\n while (match) {\n const items: string[] = [];\n match.forEach((item) => items.push(item));\n const itemIndex = match.index;\n const existingItem = tableData.find((tableEntry) => deepEqual(tableEntry.items, items));\n const newReference: InventoryItemOccurrence = {\n reference: {\n bookNum: currentBook !== undefined ? currentBook : -1,\n chapterNum: currentChapter !== undefined ? currentChapter : -1,\n verseNum: currentVerse !== undefined ? currentVerse : -1,\n },\n text: substring(line, Math.max(0, itemIndex - 25), Math.min(itemIndex + 25, line.length)),\n };\n if (existingItem) {\n existingItem.count += 1;\n existingItem.occurrences.push(newReference);\n } else {\n const newItem: InventoryTableData = {\n items,\n count: 1,\n status: getStatusForItem(items[0], approvedItems, unapprovedItems),\n occurrences: [newReference],\n };\n tableData.push(newItem);\n }\n\n match = itemRegex.exec(line) ?? undefined;\n }\n });\n\n return tableData;\n};\n\n/**\n * Gets the localized value for the provided key\n *\n * @param strings Object containing localized string\n * @param key Key for a localized string\n * @returns The localized value for the provided key, if available. Returns the key if no localized\n * value is available\n */\nconst localizeString = (\n strings: InventoryLocalizedStrings,\n key: keyof InventoryLocalizedStrings,\n) => {\n return strings[key] ?? key;\n};\n\n/** Props for the Inventory component */\ntype InventoryProps = {\n /** The scripture reference that the application is currently set to */\n scriptureReference: ScriptureReference;\n /** Callback function that is executed when the scripture reference is changed */\n setScriptureReference: (scriptureReference: ScriptureReference) => void;\n /**\n * Object with all localized strings that the Inventory needs to work well across multiple\n * languages. When using this component with Platform.Bible, you can import\n * `INVENTORY_STRING_KEYS` from this library, pass it in to the Platform's localization hook, and\n * pass the localized keys that are returned by the hook into this prop.\n */\n localizedStrings: InventoryLocalizedStrings;\n /**\n * The logic that finds the desired items in the source text. This can either be a Regular\n * expression that captures one or multiple items (preferred), or a custom function that builds\n * and return an InventoryDataTable[] manually. Note: In case the logic captures more than one\n * item (i.e. InventoryTableData.items has a length greater than 1), you must provide text labels\n * for the related columns and control elements to show by setting the `additionalItemsLabels`\n * prop\n */\n extractItems:\n | RegExp\n | ((\n text: string | undefined,\n scriptureRef: ScriptureReference,\n approvedItems: string[],\n unapprovedItems: string[],\n ) => InventoryTableData[]);\n /**\n * Text labels for control elements and additional column headers in case your Inventory has more\n * than one item to show (e.g. The 'Preceding Marker' in the Markers Inventory)\n */\n additionalItemsLabels?: AdditionalItemsLabels;\n /** Array of approved items, typically as defined in `Settings.xml` */\n approvedItems: string[];\n /** Array of unapproved items, typically as defined in `Settings.xml` */\n unapprovedItems: string[];\n /** The source scripture text that is searched for in inventory items */\n text: string | undefined;\n /** Scope of scripture that the inventory will operate on */\n scope: Scope;\n /** Callback function that is executed when the scope is changed from the Inventory */\n onScopeChange: (scope: Scope) => void;\n /**\n * Column definitions for the Inventory data table. The most commonly used column definitions are\n * pre-configured for your convenience and can be imported (e.g. inventoryItemColumn,\n * inventoryAdditionalItemColumn inventoryCountColumn, and inventoryStatusColumn). If you need any\n * other columns you can add these yourself\n */\n columns: ColumnDef[];\n};\n\n/** Inventory component that is used to view and control the status of provided project settings */\nexport default function Inventory({\n scriptureReference,\n setScriptureReference,\n localizedStrings,\n extractItems,\n additionalItemsLabels,\n approvedItems,\n unapprovedItems,\n text,\n scope,\n onScopeChange,\n columns,\n}: InventoryProps) {\n const allItemsText = localizeString(localizedStrings, '%webView_inventory_all%');\n const approvedItemsText = localizeString(localizedStrings, '%webView_inventory_approved%');\n const unapprovedItemsText = localizeString(localizedStrings, '%webView_inventory_unapproved%');\n const unknownItemsText = localizeString(localizedStrings, '%webView_inventory_unknown%');\n const scopeBookText = localizeString(localizedStrings, '%webView_inventory_scope_currentBook%');\n const scopeChapterText = localizeString(localizedStrings, '%webView_inventory_scope_chapter%');\n const scopeVerseText = localizeString(localizedStrings, '%webView_inventory_scope_verse%');\n const filterText = localizeString(localizedStrings, '%webView_inventory_filter_text%');\n const showAdditionalItemsText = localizeString(\n localizedStrings,\n '%webView_inventory_show_additional_items%',\n );\n\n const [showAdditionalItems, setShowAdditionalItems] = useState(false);\n const [statusFilter, setStatusFilter] = useState('all');\n const [textFilter, setTextFilter] = useState('');\n const [selectedItem, setSelectedItem] = useState([]);\n\n const tableData: InventoryTableData[] = useMemo(() => {\n if (!text) return [];\n if (extractItems instanceof RegExp)\n return createTableData(\n text,\n scriptureReference,\n approvedItems,\n unapprovedItems,\n extractItems,\n );\n return extractItems(text, scriptureReference, approvedItems, unapprovedItems);\n }, [text, extractItems, scriptureReference, approvedItems, unapprovedItems]);\n\n const reducedTableData: InventoryTableData[] = useMemo(() => {\n if (showAdditionalItems) return tableData;\n\n const newTableData: InventoryTableData[] = [];\n\n tableData.forEach((tableEntry) => {\n const firstItem = tableEntry.items[0];\n\n const existingEntry = newTableData.find(\n (newTableEntry) => newTableEntry.items[0] === firstItem,\n );\n\n if (existingEntry) {\n existingEntry.count += tableEntry.count;\n existingEntry.occurrences = existingEntry.occurrences.concat(tableEntry.occurrences);\n } else {\n newTableData.push({\n items: [firstItem],\n count: tableEntry.count,\n occurrences: tableEntry.occurrences,\n status: tableEntry.status,\n });\n }\n });\n\n return newTableData;\n }, [showAdditionalItems, tableData]);\n\n const filteredTableData: InventoryTableData[] = useMemo(() => {\n return filterItemData(reducedTableData, statusFilter, textFilter);\n }, [reducedTableData, statusFilter, textFilter]);\n\n const allColumns: ColumnDef[] = useMemo(() => {\n if (!showAdditionalItems) return columns;\n\n const numberOfAdditionalItems = additionalItemsLabels?.tableHeaders?.length;\n if (!numberOfAdditionalItems) return columns;\n\n const additionalColumns: ColumnDef[] = [];\n\n for (let index = 0; index < numberOfAdditionalItems; index++) {\n additionalColumns.push(\n inventoryAdditionalItemColumn(\n additionalItemsLabels?.tableHeaders?.[index] || 'Additional Item',\n index + 1,\n ),\n );\n }\n\n return [...additionalColumns, ...columns];\n }, [additionalItemsLabels?.tableHeaders, columns, showAdditionalItems]);\n\n useEffect(() => {\n setSelectedItem([]);\n }, [filteredTableData]);\n\n const rowClickHandler = (\n row: RowContents,\n table: TableContents,\n ) => {\n table.setRowSelection(() => {\n const newSelection: RowSelectionState = {};\n newSelection[row.index] = true;\n return newSelection;\n });\n\n setSelectedItem(row.original.items);\n };\n\n const handleScopeChange = (value: string) => {\n if (value === 'book' || value === 'chapter' || value === 'verse') {\n onScopeChange(value);\n } else {\n throw new Error(`Invalid scope value: ${value}`);\n }\n };\n\n const handleStatusFilterChange = (value: string) => {\n if (value === 'all' || value === 'approved' || value === 'unapproved' || value === 'unknown') {\n setStatusFilter(value);\n } else {\n throw new Error(`Invalid status filter value: ${value}`);\n }\n };\n\n const occurrenceData: InventoryItemOccurrence[] = useMemo(() => {\n if (reducedTableData.length === 0 || selectedItem.length === 0) return [];\n const occurrence = reducedTableData.filter((tableEntry: InventoryTableData) => {\n return deepEqual(\n showAdditionalItems ? tableEntry.items : [tableEntry.items[0]],\n selectedItem,\n );\n });\n if (occurrence.length > 1) throw new Error('Selected item is not unique');\n return occurrence[0].occurrences;\n }, [selectedItem, showAdditionalItems, reducedTableData]);\n\n return (\n
    \n
    \n handleStatusFilterChange(value)}\n defaultValue={statusFilter}\n >\n \n \n \n \n {allItemsText}\n {approvedItemsText}\n {unapprovedItemsText}\n {unknownItemsText}\n \n \n \n {\n setTextFilter(event.target.value);\n }}\n />\n {additionalItemsLabels && (\n
    \n {\n setSelectedItem([]);\n setShowAdditionalItems(checked);\n }}\n />\n \n
    \n )}\n
    \n
    \n \n
    \n {occurrenceData.length > 0 && (\n
    \n \n
    \n )}\n
    \n );\n}\n","import { Input } from '@/components/shadcn-ui/input';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { useState } from 'react';\n\nexport type SearchBarProps = {\n className?: string;\n /**\n * Callback fired to handle the search query when button pressed\n *\n * @param searchQuery\n */\n onSearch: (searchQuery: string) => void;\n\n /** Optional string that appears in the search bar without a search string */\n placeholder?: string;\n\n /** Optional boolean to set the input base to full width */\n isFullWidth?: boolean;\n};\n\nexport default function SearchBar({\n className,\n onSearch,\n placeholder,\n isFullWidth,\n}: SearchBarProps) {\n const [searchQuery, setSearchQuery] = useState('');\n\n const handleInputChange = (searchString: string) => {\n setSearchQuery(searchString);\n onSearch(searchString);\n };\n\n return (\n handleInputChange(e.target.value)}\n />\n );\n}\n","// adapted from: https://github.com/shadcn-ui/ui/discussions/752\n\n'use client';\n\nimport { TabsContentProps, TabsListProps, TabsTriggerProps } from '@/components/shadcn-ui/tabs';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport * as TabsPrimitive from '@radix-ui/react-tabs';\nimport React from 'react';\n\nexport type VerticalTabsProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport type LeftTabsTriggerProps = TabsTriggerProps & {\n value: string;\n ref?: React.Ref;\n};\n\nexport const VerticalTabs = React.forwardRef<\n React.ElementRef,\n VerticalTabsProps\n>(({ className, ...props }, ref) => (\n \n));\n\nVerticalTabs.displayName = TabsPrimitive.List.displayName;\n\nexport const VerticalTabsList = React.forwardRef<\n React.ElementRef,\n TabsListProps\n>(({ className, ...props }, ref) => (\n \n));\nVerticalTabsList.displayName = TabsPrimitive.List.displayName;\n\nexport const VerticalTabsTrigger = React.forwardRef<\n React.ElementRef,\n LeftTabsTriggerProps\n>(({ className, ...props }, ref) => (\n \n));\n\nexport const VerticalTabsContent = React.forwardRef<\n React.ElementRef,\n TabsContentProps\n>(({ className, ...props }, ref) => (\n \n));\nVerticalTabsContent.displayName = TabsPrimitive.Content.displayName;\n","import SearchBar from '@/components/basics/search-bar.component';\nimport {\n VerticalTabs,\n VerticalTabsContent,\n VerticalTabsList,\n VerticalTabsTrigger,\n} from '@/components/basics/tabs-vertical';\nimport { ReactNode } from 'react';\n\nexport type TabKeyValueContent = {\n key: string;\n value: string;\n content: ReactNode;\n};\n\nexport type TabNavigationContentSearchProps = {\n /** List of values and keys for each tab this component should provide */\n tabList: TabKeyValueContent[];\n\n /** Handler to run when the value of the search bar changes */\n onSearch: (searchQuery: string) => void;\n\n /** Optional placeholder for the search bar */\n searchPlaceholder?: string;\n\n /** Optional title to include in the header */\n headerTitle?: string;\n\n /** Optional flag to make the search bar appear full width */\n isSearchBarFullWidth?: boolean;\n\n /** Text direction ltr or rtl */\n direction?: 'ltr' | 'rtl';\n};\n\nexport default function TabNavigationContentSearch({\n tabList,\n onSearch,\n searchPlaceholder,\n headerTitle,\n isSearchBarFullWidth = false,\n direction = 'ltr',\n}: TabNavigationContentSearchProps) {\n return (\n
    \n
    \n {headerTitle ?

    {headerTitle}

    : ''}\n \n
    \n \n \n {tabList.map((tab) => (\n \n {tab.value}\n \n ))}\n \n {tabList.map((tab) => (\n \n {tab.content}\n \n ))}\n \n
    \n );\n}\n","import React from 'react';\nimport * as SeparatorPrimitive from '@radix-ui/react-separator';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Separator = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, orientation = 'horizontal', decorative = true, ...props }, ref) => (\n \n));\nSeparator.displayName = SeparatorPrimitive.Root.displayName;\n\nexport { Separator };\n","'use client';\n\nimport * as React from 'react';\nimport * as SheetPrimitive from '@radix-ui/react-dialog';\nimport { cva, type VariantProps } from 'class-variance-authority';\nimport { X } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Sheet = SheetPrimitive.Root;\n\nconst SheetTrigger = SheetPrimitive.Trigger;\n\nconst SheetClose = SheetPrimitive.Close;\n\nconst SheetPortal = SheetPrimitive.Portal;\n\nconst SheetOverlay = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSheetOverlay.displayName = SheetPrimitive.Overlay.displayName;\n\nconst sheetVariants = cva(\n 'pr-twp tw-fixed tw-z-50 tw-gap-4 tw-bg-background tw-p-6 tw-shadow-lg tw-transition tw-ease-in-out data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-duration-300 data-[state=open]:tw-duration-500',\n {\n variants: {\n side: {\n top: 'tw-inset-x-0 tw-top-0 tw-border-b data-[state=closed]:tw-slide-out-to-top data-[state=open]:tw-slide-in-from-top',\n bottom:\n 'tw-inset-x-0 tw-bottom-0 tw-border-t data-[state=closed]:tw-slide-out-to-bottom data-[state=open]:tw-slide-in-from-bottom',\n left: 'tw-inset-y-0 tw-left-0 tw-h-full tw-w-3/4 tw-border-r data-[state=closed]:tw-slide-out-to-left data-[state=open]:tw-slide-in-from-left sm:tw-max-w-sm',\n right:\n 'tw-inset-y-0 tw-right-0 tw-h-full tw-w-3/4 tw- tw-border-l data-[state=closed]:tw-slide-out-to-right data-[state=open]:tw-slide-in-from-right sm:tw-max-w-sm',\n },\n },\n defaultVariants: {\n side: 'right',\n },\n },\n);\n\ninterface SheetContentProps\n extends React.ComponentPropsWithoutRef,\n VariantProps {}\n\nconst SheetContent = React.forwardRef<\n React.ElementRef,\n SheetContentProps\n>(({ side = 'right', className, children, ...props }, ref) => (\n \n \n \n {children}\n \n \n Close\n \n \n \n));\nSheetContent.displayName = SheetPrimitive.Content.displayName;\n\nfunction SheetHeader({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nSheetHeader.displayName = 'SheetHeader';\n\nfunction SheetFooter({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nSheetFooter.displayName = 'SheetFooter';\n\nconst SheetTitle = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSheetTitle.displayName = SheetPrimitive.Title.displayName;\n\nconst SheetDescription = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSheetDescription.displayName = SheetPrimitive.Description.displayName;\n\nexport {\n Sheet,\n SheetPortal,\n SheetOverlay,\n SheetTrigger,\n SheetClose,\n SheetContent,\n SheetHeader,\n SheetFooter,\n SheetTitle,\n SheetDescription,\n};\n","import React from 'react';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nfunction Skeleton({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\n\nexport { Skeleton };\n","import React from 'react';\nimport * as TooltipPrimitive from '@radix-ui/react-tooltip';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst TooltipProvider = TooltipPrimitive.Provider;\n\nconst Tooltip = TooltipPrimitive.Root;\n\nconst TooltipTrigger = TooltipPrimitive.Trigger;\n\nconst TooltipContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, sideOffset = 4, ...props }, ref) => (\n \n));\nTooltipContent.displayName = TooltipPrimitive.Content.displayName;\n\nexport { Tooltip, TooltipTrigger, TooltipContent, TooltipProvider };\n","import * as React from 'react';\n\nconst MOBILE_BREAKPOINT = 768;\n\nexport default function useIsMobile() {\n const [isMobile, setIsMobile] = React.useState(undefined);\n\n React.useEffect(() => {\n const mql = window.matchMedia(`(max-width: ${MOBILE_BREAKPOINT - 1}px)`);\n const onChange = () => {\n setIsMobile(window.innerWidth < MOBILE_BREAKPOINT);\n };\n mql.addEventListener('change', onChange);\n setIsMobile(window.innerWidth < MOBILE_BREAKPOINT);\n return () => mql.removeEventListener('change', onChange);\n }, []);\n\n return !!isMobile;\n}\n","import React from 'react';\nimport { Slot } from '@radix-ui/react-slot';\nimport { VariantProps, cva } from 'class-variance-authority';\nimport { PanelLeft } from 'lucide-react';\n\nimport { Button } from '@/components/shadcn-ui/button';\nimport { Input } from '@/components/shadcn-ui/input';\nimport { Separator } from '@/components/shadcn-ui/separator';\nimport { Sheet, SheetContent } from '@/components/shadcn-ui/sheet';\nimport { Skeleton } from '@/components/shadcn-ui/skeleton';\nimport {\n Tooltip,\n TooltipContent,\n TooltipProvider,\n TooltipTrigger,\n} from '@/components/shadcn-ui/tooltip';\nimport useIsMobile from '@/components/hooks/use-mobile';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst SIDEBAR_COOKIE_NAME = 'sidebar:state';\nconst SIDEBAR_COOKIE_MAX_AGE = 60 * 60 * 24 * 7;\nconst SIDEBAR_WIDTH = '16rem';\nconst SIDEBAR_WIDTH_MOBILE = '18rem';\nconst SIDEBAR_WIDTH_ICON = '3rem';\nconst SIDEBAR_KEYBOARD_SHORTCUT = 'b';\n\ntype SidebarContextProps = {\n state: 'expanded' | 'collapsed';\n open: boolean;\n setOpen: (open: boolean) => void;\n openMobile: boolean;\n setOpenMobile: (open: boolean) => void;\n isMobile: boolean;\n toggleSidebar: () => void;\n};\n\nconst SidebarContext = React.createContext(undefined);\n\nfunction useSidebar() {\n const context = React.useContext(SidebarContext);\n if (!context) {\n throw new Error('useSidebar must be used within a SidebarProvider.');\n }\n\n return context;\n}\n\nconst SidebarProvider = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & {\n defaultOpen?: boolean;\n open?: boolean;\n onOpenChange?: (open: boolean) => void;\n }\n>(\n (\n {\n defaultOpen = true,\n open: openProp,\n onOpenChange: setOpenProp,\n className,\n style,\n children,\n ...props\n },\n ref,\n ) => {\n const isMobile = useIsMobile();\n const [openMobile, setOpenMobile] = React.useState(false);\n\n // This is the internal state of the sidebar.\n // We use openProp and setOpenProp for control from outside the component.\n const [_open, _setOpen] = React.useState(defaultOpen);\n const isOpen = openProp ?? _open;\n const setOpen = React.useCallback(\n (value: boolean | ((value: boolean) => boolean)) => {\n const openState = typeof value === 'function' ? value(isOpen) : value;\n if (setOpenProp) {\n setOpenProp(openState);\n } else {\n _setOpen(openState);\n }\n\n // This sets the cookie to keep the sidebar state.\n document.cookie = `${SIDEBAR_COOKIE_NAME}=${openState}; path=/; max-age=${SIDEBAR_COOKIE_MAX_AGE}`;\n },\n [setOpenProp, isOpen],\n );\n\n // Helper to toggle the sidebar.\n const toggleSidebar = React.useCallback(() => {\n return isMobile ? setOpenMobile((open) => !open) : setOpen((open) => !open);\n }, [isMobile, setOpen, setOpenMobile]);\n\n // Adds a keyboard shortcut to toggle the sidebar.\n React.useEffect(() => {\n const handleKeyDown = (event: KeyboardEvent) => {\n if (event.key === SIDEBAR_KEYBOARD_SHORTCUT && (event.metaKey || event.ctrlKey)) {\n event.preventDefault();\n toggleSidebar();\n }\n };\n\n window.addEventListener('keydown', handleKeyDown);\n return () => window.removeEventListener('keydown', handleKeyDown);\n }, [toggleSidebar]);\n\n // We add a state so that we can do data-state=\"expanded\" or \"collapsed\".\n // This makes it easier to style the sidebar with Tailwind classes.\n const state = isOpen ? 'expanded' : 'collapsed';\n\n const contextValue = React.useMemo(\n () => ({\n state,\n open: isOpen,\n setOpen,\n isMobile,\n openMobile,\n setOpenMobile,\n toggleSidebar,\n }),\n [state, isOpen, setOpen, isMobile, openMobile, setOpenMobile, toggleSidebar],\n );\n\n return (\n \n \n \n {children}\n
    \n \n \n );\n },\n);\nSidebarProvider.displayName = 'SidebarProvider';\n\nconst Sidebar = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & {\n side?: 'left' | 'right';\n variant?: 'sidebar' | 'floating' | 'inset';\n collapsible?: 'offcanvas' | 'icon' | 'none';\n }\n>(\n (\n {\n side = 'left',\n variant = 'sidebar',\n collapsible = 'offcanvas',\n className,\n children,\n ...props\n },\n ref,\n ) => {\n const { isMobile, state, openMobile, setOpenMobile } = useSidebar();\n\n if (collapsible === 'none') {\n return (\n \n {children}\n
    \n );\n }\n\n if (isMobile) {\n return (\n \n button]:tw-hidden\"\n style={\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n {\n '--sidebar-width': SIDEBAR_WIDTH_MOBILE,\n } as React.CSSProperties\n }\n side={side}\n >\n
    {children}
    \n \n
    \n );\n }\n\n return (\n \n {/* This is what handles the sidebar gap on desktop */}\n \n \n \n {children}\n
    \n
    \n
    \n );\n },\n);\nSidebar.displayName = 'Sidebar';\n\nconst SidebarTrigger = React.forwardRef<\n React.ElementRef,\n React.ComponentProps\n>(({ className, onClick, ...props }, ref) => {\n const { toggleSidebar } = useSidebar();\n\n return (\n {\n onClick?.(event);\n toggleSidebar();\n }}\n {...props}\n >\n \n Toggle Sidebar\n \n );\n});\nSidebarTrigger.displayName = 'SidebarTrigger';\n\nconst SidebarRail = React.forwardRef>(\n ({ className, ...props }, ref) => {\n const { toggleSidebar } = useSidebar();\n\n return (\n \n );\n },\n);\nSidebarRail.displayName = 'SidebarRail';\n\nconst SidebarInset = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarInset.displayName = 'SidebarInset';\n\nconst SidebarInput = React.forwardRef<\n React.ElementRef,\n React.ComponentProps\n>(({ className, ...props }, ref) => {\n return (\n \n );\n});\nSidebarInput.displayName = 'SidebarInput';\n\nconst SidebarHeader = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarHeader.displayName = 'SidebarHeader';\n\nconst SidebarFooter = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarFooter.displayName = 'SidebarFooter';\n\nconst SidebarSeparator = React.forwardRef<\n React.ElementRef,\n React.ComponentProps\n>(({ className, ...props }, ref) => {\n return (\n \n );\n});\nSidebarSeparator.displayName = 'SidebarSeparator';\n\nconst SidebarContent = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarContent.displayName = 'SidebarContent';\n\nconst SidebarGroup = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarGroup.displayName = 'SidebarGroup';\n\nconst SidebarGroupLabel = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & { asChild?: boolean }\n>(({ className, asChild = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'div';\n\n return (\n svg]:tw-size-4 [&>svg]:tw-shrink-0',\n 'group-data-[collapsible=icon]:tw--mt-8 group-data-[collapsible=icon]:tw-opacity-0',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarGroupLabel.displayName = 'SidebarGroupLabel';\n\nconst SidebarGroupAction = React.forwardRef<\n HTMLButtonElement,\n React.ComponentProps<'button'> & { asChild?: boolean }\n>(({ className, asChild = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'button';\n\n return (\n svg]:tw-size-4 [&>svg]:tw-shrink-0',\n // Increases the hit area of the button on mobile.\n 'after:tw-absolute after:tw--inset-2 after:md:tw-hidden',\n 'group-data-[collapsible=icon]:tw-hidden',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarGroupAction.displayName = 'SidebarGroupAction';\n\nconst SidebarGroupContent = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarGroupContent.displayName = 'SidebarGroupContent';\n\nconst SidebarMenu = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenu.displayName = 'SidebarMenu';\n\nconst SidebarMenuItem = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenuItem.displayName = 'SidebarMenuItem';\n\nconst sidebarMenuButtonVariants = cva(\n // Removed data-[active=true]:tw-bg-sidebar-accent\n 'tw-peer/menu-button tw-flex tw-w-full tw-items-center tw-gap-2 tw-overflow-hidden tw-rounded-md tw-p-2 tw-text-left tw-text-sm tw-outline-none tw-ring-sidebar-ring tw-transition-[width,height,padding] hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground focus-visible:tw-ring-2 active:tw-bg-sidebar-accent active:tw-text-sidebar-accent-foreground disabled:tw-pointer-events-none disabled:tw-opacity-50 tw-group-has-[[data-sidebar=menu-action]]/menu-item:pr-8 aria-disabled:tw-pointer-events-none aria-disabled:tw-opacity-50 data-[active=true]:tw-font-medium data-[active=true]:tw-text-sidebar-accent-foreground data-[state=open]:hover:tw-bg-sidebar-accent data-[state=open]:hover:tw-text-sidebar-accent-foreground group-data-[collapsible=icon]:tw-!size-8 group-data-[collapsible=icon]:tw-!p-2 [&>span:last-child]:tw-truncate [&>svg]:tw-size-4 [&>svg]:tw-shrink-0',\n {\n variants: {\n variant: {\n default: 'hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground',\n outline:\n 'tw-bg-background tw-shadow-[0_0_0_1px_hsl(var(--sidebar-border))] hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground hover:tw-shadow-[0_0_0_1px_hsl(var(--sidebar-accent))]',\n },\n size: {\n default: 'tw-h-8 tw-text-sm',\n sm: 'tw-h-7 tw-text-xs',\n lg: 'tw-h-12 tw-text-sm group-data-[collapsible=icon]:tw-!p-0',\n },\n },\n defaultVariants: {\n variant: 'default',\n size: 'default',\n },\n },\n);\n\nconst SidebarMenuButton = React.forwardRef<\n HTMLButtonElement,\n React.ComponentProps<'button'> & {\n asChild?: boolean;\n isActive?: boolean;\n tooltip?: string | React.ComponentProps;\n } & VariantProps\n>(\n (\n {\n asChild = false,\n isActive = false,\n variant = 'default',\n size = 'default',\n tooltip,\n className,\n ...props\n },\n ref,\n ) => {\n const Comp = asChild ? Slot : 'button';\n const { isMobile, state } = useSidebar();\n\n const button = (\n \n );\n\n if (!tooltip) {\n return button;\n }\n\n if (typeof tooltip === 'string') {\n // eslint-disable-next-line no-param-reassign\n tooltip = {\n children: tooltip,\n };\n }\n\n return (\n \n {button}\n \n );\n },\n);\nSidebarMenuButton.displayName = 'SidebarMenuButton';\n\nconst SidebarMenuAction = React.forwardRef<\n HTMLButtonElement,\n React.ComponentProps<'button'> & {\n asChild?: boolean;\n showOnHover?: boolean;\n }\n>(({ className, asChild = false, showOnHover = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'button';\n\n return (\n svg]:tw-size-4 [&>svg]:tw-shrink-0',\n // Increases the hit area of the button on mobile.\n 'after:tw-absolute after:tw--inset-2 after:md:tw-hidden',\n 'tw-peer-data-[size=sm]/menu-button:top-1',\n 'tw-peer-data-[size=default]/menu-button:top-1.5',\n 'tw-peer-data-[size=lg]/menu-button:top-2.5',\n 'group-data-[collapsible=icon]:tw-hidden',\n showOnHover &&\n 'tw-group-focus-within/menu-item:opacity-100 tw-group-hover/menu-item:opacity-100 tw-peer-data-[active=true]/menu-button:text-sidebar-accent-foreground data-[state=open]:tw-opacity-100 md:tw-opacity-0',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarMenuAction.displayName = 'SidebarMenuAction';\n\nconst SidebarMenuBadge = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenuBadge.displayName = 'SidebarMenuBadge';\n\nconst SidebarMenuSkeleton = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & {\n showIcon?: boolean;\n }\n>(({ className, showIcon = false, ...props }, ref) => {\n // Random width between 50 to 90%.\n const width = React.useMemo(() => {\n return `${Math.floor(Math.random() * 40) + 50}%`;\n }, []);\n\n return (\n \n {showIcon && (\n \n )}\n \n
    \n );\n});\nSidebarMenuSkeleton.displayName = 'SidebarMenuSkeleton';\n\nconst SidebarMenuSub = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenuSub.displayName = 'SidebarMenuSub';\n\nconst SidebarMenuSubItem = React.forwardRef>(\n ({ ...props }, ref) =>
  • ,\n);\nSidebarMenuSubItem.displayName = 'SidebarMenuSubItem';\n\nconst SidebarMenuSubButton = React.forwardRef<\n HTMLAnchorElement,\n React.ComponentProps<'a'> & {\n asChild?: boolean;\n size?: 'sm' | 'md';\n isActive?: boolean;\n }\n>(({ asChild = false, size = 'md', isActive, className, ...props }, ref) => {\n const Comp = asChild ? Slot : 'a';\n\n return (\n span:last-child]:tw-truncate [&>svg]:tw-size-4 [&>svg]:tw-shrink-0 [&>svg]:tw-text-sidebar-accent-foreground',\n 'data-[active=true]:tw-bg-sidebar-accent data-[active=true]:tw-text-sidebar-accent-foreground',\n size === 'sm' && 'tw-text-xs',\n size === 'md' && 'tw-text-sm',\n 'group-data-[collapsible=icon]:tw-hidden',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarMenuSubButton.displayName = 'SidebarMenuSubButton';\n\nexport {\n Sidebar,\n SidebarContent,\n SidebarFooter,\n SidebarGroup,\n SidebarGroupAction,\n SidebarGroupContent,\n SidebarGroupLabel,\n SidebarHeader,\n SidebarInput,\n SidebarInset,\n SidebarMenu,\n SidebarMenuAction,\n SidebarMenuBadge,\n SidebarMenuButton,\n SidebarMenuItem,\n SidebarMenuSkeleton,\n SidebarMenuSub,\n SidebarMenuSubButton,\n SidebarMenuSubItem,\n SidebarProvider,\n SidebarRail,\n SidebarSeparator,\n SidebarTrigger,\n useSidebar,\n};\n","import ComboBox, { ComboBoxOption } from '@/components/basics/combo-box.component';\nimport {\n Sidebar,\n SidebarContent,\n SidebarGroup,\n SidebarGroupLabel,\n SidebarGroupContent,\n SidebarMenu,\n SidebarMenuItem,\n SidebarMenuButton,\n} from '@/components/shadcn-ui/sidebar';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { useCallback } from 'react';\n\nexport type SelectedSettingsSidebarItem = {\n label: string;\n projectId?: string;\n};\n\nexport type ProjectOptions = { projectId: string; projectName: string };\n\nexport type SettingsSidebarProps = {\n /** Optional id for testing */\n id?: string;\n\n /** Extension labels from contribution */\n extensionLabels: string[];\n\n /** Project names and ids */\n projectOptions: ProjectOptions[];\n\n /** Handler for selecting a sidebar item */\n handleSelectSidebarItem: (key: string, projectId?: string) => void;\n\n /** The current selected value in the sidebar */\n selectedSidebarItem: SelectedSettingsSidebarItem;\n};\n\nexport default function SettingsSidebar({\n id,\n extensionLabels,\n projectOptions,\n handleSelectSidebarItem,\n selectedSidebarItem,\n}: SettingsSidebarProps) {\n const handleSelectItem = useCallback(\n (item: string, projectId?: string) => {\n handleSelectSidebarItem(item, projectId);\n },\n [handleSelectSidebarItem],\n );\n\n const getProjectNameFromProjectId = useCallback(\n (projectId: string) => {\n const project = projectOptions.find((option) => option.projectId === projectId);\n return project ? project.projectName : projectId;\n },\n [projectOptions],\n );\n\n const getIsActive: (label: string) => boolean = useCallback(\n (label: string) => !selectedSidebarItem.projectId && label === selectedSidebarItem.label,\n [selectedSidebarItem],\n );\n\n return (\n \n \n \n Extensions\n \n \n {extensionLabels.map((label) => (\n \n handleSelectItem(label, undefined)}\n isActive={getIsActive(label)}\n >\n {label}\n \n \n ))}\n \n \n \n \n Projects\n \n option.projectId)}\n getOptionLabel={(projectId: ComboBoxOption) => {\n // This function expects a ComboBoxOption, but we know it is a string\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n return getProjectNameFromProjectId(projectId as string);\n }}\n buttonPlaceholder=\"Type or select project\"\n onChange={(projectId: string) => {\n const selectedProjectName = getProjectNameFromProjectId(projectId);\n handleSelectItem(selectedProjectName, projectId);\n }}\n value={selectedSidebarItem?.projectId ?? undefined}\n />\n \n \n \n \n );\n}\n","import { SidebarInset, SidebarProvider } from '@/components/shadcn-ui/sidebar';\nimport { PropsWithChildren } from 'react';\nimport SearchBar from '@/components/basics/search-bar.component';\nimport SettingsSidebar, { SettingsSidebarProps } from './settings-sidebar.component';\n\nexport type SettingsSidebarContentSearchProps = SettingsSidebarProps &\n PropsWithChildren & {\n /** Optional id for testing */\n id?: string;\n\n /** Text direction ltr or rtl */\n direction?: 'ltr' | 'rtl';\n\n /** Handler to run when the value of the search bar changes */\n onSearch: (searchQuery: string) => void;\n };\n\nexport default function SettingsSidebarContentSearch({\n id,\n direction = 'ltr',\n extensionLabels,\n projectOptions,\n children,\n handleSelectSidebarItem,\n selectedSidebarItem,\n onSearch,\n}: SettingsSidebarContentSearchProps) {\n return (\n
    \n
    \n \n
    \n \n \n {children}\n \n
    \n );\n}\n","import { Button } from '@/components/shadcn-ui/button';\nimport {\n Select,\n SelectContent,\n SelectGroup,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\nimport {\n Table,\n TableBody,\n TableCell,\n TableHead,\n TableHeader,\n TableRow,\n} from '@/components/shadcn-ui/table';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Canon } from '@sillsdev/scripture';\nimport {\n Cell,\n ColumnDef,\n flexRender,\n getCoreRowModel,\n getExpandedRowModel,\n getGroupedRowModel,\n getSortedRowModel,\n GroupingState,\n Row,\n RowSelectionState,\n SortingState,\n useReactTable,\n} from '@tanstack/react-table';\nimport '@/components/advanced/scripture-results-viewer/scripture-results-viewer.component.css';\nimport {\n compareScrRefs,\n formatScrRef,\n ScriptureSelection,\n scrRefToBBBCCCVVV,\n} from 'platform-bible-utils';\nimport { MouseEvent, useEffect, useMemo, useState } from 'react';\nimport { ChevronDown, ChevronLeft, ChevronRight } from 'lucide-react';\n\n/**\n * Information (e.g., a checking error or some other type of \"transient\" annotation) about something\n * noteworthy at a specific place in an instance of the Scriptures.\n */\nexport type ScriptureItemDetail = ScriptureSelection & {\n /**\n * Text of the error, note, etc. In the future, we might want to support something more than just\n * text so that a JSX element could be provided with a link or some other controls related to the\n * issue being reported.\n */\n detail: string;\n};\n\n/**\n * A uniquely identifiable source of results that can be displayed in the ScriptureResultsViewer.\n * Generally, the source will be a particular Scripture check, but there may be other types of\n * sources.\n */\nexport type ResultsSource = {\n /**\n * Uniquely identifies the source.\n *\n * @type {string}\n */\n id: string;\n\n /**\n * Name (potentially localized) of the source, suitable for display in the UI.\n *\n * @type {string}\n */\n displayName: string;\n};\n\nexport type ScriptureSrcItemDetail = ScriptureItemDetail & {\n /** Source/type of detail. Can be used for grouping. */\n source: ResultsSource;\n};\n\n/**\n * Represents a set of results keyed by Scripture reference. Generally, the source will be a\n * particular Scripture check, but this type also allows for other types of uniquely identifiable\n * sources.\n */\nexport type ResultsSet = {\n /**\n * The backing source associated with this set of results.\n *\n * @type {ResultsSource}\n */\n source: ResultsSource;\n\n /**\n * Array of Scripture item details (messages keyed by Scripture reference).\n *\n * @type {ScriptureItemDetail[]}\n */\n data: ScriptureItemDetail[];\n};\n\nconst scrBookColId = 'scrBook';\nconst scrRefColId = 'scrRef';\nconst typeColId = 'source';\nconst detailsColId = 'details';\n\nconst defaultScrRefColumnName = 'Scripture Reference';\nconst defaultScrBookGroupName = 'Scripture Book';\nconst defaultTypeColumnName = 'Type';\nconst defaultDetailsColumnName = 'Details';\n\nexport type ScriptureResultsViewerColumnInfo = {\n /** Optional header to display for the Reference column. Default value: 'Scripture Reference'. */\n scriptureReferenceColumnName?: string;\n\n /** Optional text to display to refer to the Scripture book group. Default value: 'Scripture Book'. */\n scriptureBookGroupName?: string;\n\n /** Optional header to display for the Type column. Default value: 'Type'. */\n typeColumnName?: string;\n\n /** Optional header to display for the Details column. Default value: 'Details' */\n detailsColumnName?: string;\n};\n\nexport type ScriptureResultsViewerProps = ScriptureResultsViewerColumnInfo & {\n /** Groups of ScriptureItemDetail objects from particular sources (e.g., Scripture checks) */\n sources: ResultsSet[];\n\n /** Flag indicating whether to display column headers. Default is false. */\n showColumnHeaders?: boolean;\n\n /** Flag indicating whether to display source column. Default is false. */\n showSourceColumn?: boolean;\n\n /** Callback function to notify when a row is selected */\n onRowSelected?: (selectedRow: ScriptureSrcItemDetail | undefined) => void;\n\n /** Text direction ltr or rtl */\n direction?: 'ltr' | 'rtl';\n};\n\nfunction getColumns(\n colInfo?: ScriptureResultsViewerColumnInfo,\n showSourceColumn?: boolean,\n): ColumnDef[] {\n const showSrcCol = showSourceColumn ?? false;\n return [\n {\n accessorFn: (row) =>\n `${Canon.bookNumberToId(row.start.bookNum)} ${row.start.chapterNum}:${row.start.verseNum}`,\n id: scrBookColId,\n header: colInfo?.scriptureReferenceColumnName ?? defaultScrRefColumnName,\n cell: (info) => {\n const row = info.row.original;\n if (info.row.getIsGrouped()) {\n return Canon.bookNumberToEnglishName(row.start.bookNum);\n }\n return info.row.groupingColumnId === scrBookColId ? formatScrRef(row.start) : undefined;\n },\n getGroupingValue: (row) => row.start.bookNum,\n sortingFn: (a, b) => {\n return compareScrRefs(a.original.start, b.original.start);\n },\n enableGrouping: true,\n },\n {\n accessorFn: (row) => formatScrRef(row.start),\n id: scrRefColId,\n header: undefined,\n cell: (info) => {\n const row = info.row.original;\n return info.row.getIsGrouped() ? undefined : formatScrRef(row.start);\n },\n sortingFn: (a, b) => {\n return compareScrRefs(a.original.start, b.original.start);\n },\n enableGrouping: false,\n },\n {\n accessorFn: (row) => row.source.displayName,\n id: typeColId,\n header: showSrcCol ? (colInfo?.typeColumnName ?? defaultTypeColumnName) : undefined,\n cell: (info) => (showSrcCol || info.row.getIsGrouped() ? info.getValue() : undefined),\n getGroupingValue: (row) => row.source.id,\n sortingFn: (a, b) =>\n a.original.source.displayName.localeCompare(b.original.source.displayName),\n enableGrouping: true,\n },\n {\n accessorFn: (row) => row.detail,\n id: detailsColId,\n header: colInfo?.detailsColumnName ?? defaultDetailsColumnName,\n cell: (info) => info.getValue(),\n enableGrouping: false,\n },\n ];\n}\n\nconst toRefOrRange = (scriptureSelection: ScriptureSelection) => {\n if (!('offset' in scriptureSelection.start))\n throw new Error('No offset available in range start');\n if (scriptureSelection.end && !('offset' in scriptureSelection.end))\n throw new Error('No offset available in range end');\n const { offset: offsetStart } = scriptureSelection.start;\n let offsetEnd: number = 0;\n if (scriptureSelection.end) ({ offset: offsetEnd } = scriptureSelection.end);\n if (\n !scriptureSelection.end ||\n compareScrRefs(scriptureSelection.start, scriptureSelection.end) === 0\n )\n return `${scrRefToBBBCCCVVV(scriptureSelection.start)}+${offsetStart}`;\n return `${scrRefToBBBCCCVVV(scriptureSelection.start)}+${offsetStart}-${scrRefToBBBCCCVVV(scriptureSelection.end)}+${offsetEnd}`;\n};\n\nconst getRowKey = (row: ScriptureSrcItemDetail) =>\n `${toRefOrRange({ start: row.start, end: row.end })} ${row.source.displayName} ${row.detail}`;\n\n/**\n * Component to display a combined list of detailed items from one or more sources, where the items\n * are keyed primarily by Scripture reference. This is particularly useful for displaying a list of\n * results from Scripture checks, but more generally could be used to display any \"results\" from any\n * source(s). The component allows for grouping by Scripture book, source, or both. By default, it\n * displays somewhat \"tree-like\" which allows it to be more horizontally compact and intuitive. But\n * it also has the option of displaying as a traditional table with column headings (with or without\n * the source column showing).\n */\nexport default function ScriptureResultsViewer({\n sources,\n showColumnHeaders = false,\n showSourceColumn = false,\n scriptureReferenceColumnName,\n scriptureBookGroupName,\n typeColumnName,\n detailsColumnName,\n onRowSelected,\n direction = 'ltr',\n}: ScriptureResultsViewerProps) {\n const [grouping, setGrouping] = useState([]);\n const [sorting, setSorting] = useState([{ id: scrBookColId, desc: false }]);\n const [rowSelection, setRowSelection] = useState({});\n\n const scriptureResults = useMemo(\n () =>\n sources.flatMap((source) => {\n return source.data.map((item) => ({\n ...item,\n source: source.source,\n }));\n }),\n [sources],\n );\n\n const columns = useMemo(\n () =>\n getColumns(\n {\n scriptureReferenceColumnName,\n typeColumnName,\n detailsColumnName,\n },\n showSourceColumn,\n ),\n [scriptureReferenceColumnName, typeColumnName, detailsColumnName, showSourceColumn],\n );\n\n useEffect(() => {\n // Ensure sorting is applied correctly when grouped by type\n if (grouping.includes(typeColId)) {\n setSorting([\n { id: typeColId, desc: false },\n { id: scrBookColId, desc: false },\n ]);\n } else {\n setSorting([{ id: scrBookColId, desc: false }]);\n }\n }, [grouping]);\n\n const table = useReactTable({\n data: scriptureResults,\n columns,\n state: {\n grouping,\n sorting,\n rowSelection,\n },\n onGroupingChange: setGrouping,\n onSortingChange: setSorting,\n onRowSelectionChange: setRowSelection,\n getExpandedRowModel: getExpandedRowModel(),\n getGroupedRowModel: getGroupedRowModel(),\n getCoreRowModel: getCoreRowModel(),\n getSortedRowModel: getSortedRowModel(),\n getRowId: getRowKey,\n autoResetExpanded: false,\n enableMultiRowSelection: false,\n enableSubRowSelection: false,\n });\n\n useEffect(() => {\n if (onRowSelected) {\n const selectedRows = table.getSelectedRowModel().rowsById;\n const keys = Object.keys(selectedRows);\n if (keys.length === 1) {\n const selectedRow = scriptureResults.find((row) => getRowKey(row) === keys[0]) || undefined;\n if (selectedRow) onRowSelected(selectedRow);\n }\n }\n }, [rowSelection, scriptureResults, onRowSelected, table]);\n\n // Define possible grouping options\n const scrBookGroupName = scriptureBookGroupName ?? defaultScrBookGroupName;\n const typeGroupName = typeColumnName ?? defaultTypeColumnName;\n\n const groupingOptions = [\n { label: 'No Grouping', value: [] },\n { label: `Group by ${scrBookGroupName}`, value: [scrBookColId] },\n { label: `Group by ${typeGroupName}`, value: [typeColId] },\n {\n label: `Group by ${scrBookGroupName} and ${typeGroupName}`,\n value: [scrBookColId, typeColId],\n },\n {\n label: `Group by ${typeGroupName} and ${scrBookGroupName}`,\n value: [typeColId, scrBookColId],\n },\n ];\n\n const handleSelectChange = (selectedGrouping: string) => {\n setGrouping(JSON.parse(selectedGrouping));\n };\n\n const handleRowClick = (row: Row, event: MouseEvent) => {\n if (!row.getIsGrouped() && !row.getIsSelected()) {\n row.getToggleSelectedHandler()(event);\n }\n };\n\n const getEvenOrOddBandingStyle = (row: Row, index: number) => {\n if (row.getIsGrouped()) return '';\n // UX has now said they don't think they want banding. I'm leaving in the code to\n // set even and odd styles, but there's nothing in the CSS to style them differently.\n // The \"even\" style used to also have tw-bg-neutral-300 (along with even) to create\n // a visual banding effect. That could be added back in if UX changes the decision.\n return cn('banded-row', index % 2 === 0 ? 'even' : 'odd');\n };\n\n const getIndent = (\n groupingState: GroupingState,\n row: Row,\n cell: Cell,\n ) => {\n if (groupingState?.length === 0 || row.depth < cell.column.getGroupedIndex()) return undefined;\n if (row.getIsGrouped()) {\n switch (row.depth) {\n case 1:\n return 'tw-ps-4';\n default:\n return undefined;\n }\n }\n switch (row.depth) {\n case 1:\n return 'tw-ps-8';\n case 2:\n return 'tw-ps-12';\n default:\n return undefined;\n }\n };\n\n return (\n
    \n {!showColumnHeaders && (\n {\n handleSelectChange(value);\n }}\n >\n \n \n \n \n \n {groupingOptions.map((option) => (\n \n {option.label}\n \n ))}\n \n \n \n )}\n \n {showColumnHeaders && (\n \n {table.getHeaderGroups().map((headerGroup) => (\n \n {headerGroup.headers\n .filter((h) => h.column.columnDef.header)\n .map((header) => (\n /* For sticky column headers to work, we probably need to change the default definition of the shadcn Table component. See https://github.com/shadcn-ui/ui/issues/1151 */\n \n {header.isPlaceholder ? undefined : (\n
    \n {header.column.getCanGroup() ? (\n \n {header.column.getIsGrouped() ? `🛑` : `👊 `}\n \n ) : undefined}{' '}\n {flexRender(header.column.columnDef.header, header.getContext())}\n
    \n )}\n
    \n ))}\n
    \n ))}\n
    \n )}\n \n {table.getRowModel().rows.map((row, rowIndex) => {\n return (\n handleRowClick(row, event)}\n >\n {row.getVisibleCells().map((cell) => {\n if (\n cell.getIsPlaceholder() ||\n (cell.column.columnDef.enableGrouping &&\n !cell.getIsGrouped() &&\n (cell.column.columnDef.id !== typeColId || !showSourceColumn))\n )\n return undefined;\n return (\n \n {(() => {\n if (cell.getIsGrouped()) {\n return (\n \n {row.getIsExpanded() && }\n {!row.getIsExpanded() &&\n (direction === 'ltr' ? : )}{' '}\n {flexRender(cell.column.columnDef.cell, cell.getContext())} (\n {row.subRows.length})\n \n );\n }\n\n // if (cell.getIsAggregated()) {\n // flexRender(\n // cell.column.columnDef.aggregatedCell ?? cell.column.columnDef.cell,\n // cell.getContext(),\n // );\n // }\n\n return flexRender(cell.column.columnDef.cell, cell.getContext());\n })()}\n \n );\n })}\n \n );\n })}\n \n
    \n
    \n );\n}\n","import {\n getLocalizeKeyForScrollGroupId,\n LanguageStrings,\n ScrollGroupId,\n} from 'platform-bible-utils';\nimport {\n Select,\n SelectContent,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\n\nconst DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS = {\n [getLocalizeKeyForScrollGroupId('undefined')]: 'Ø',\n [getLocalizeKeyForScrollGroupId(0)]: 'A',\n [getLocalizeKeyForScrollGroupId(1)]: 'B',\n [getLocalizeKeyForScrollGroupId(2)]: 'C',\n [getLocalizeKeyForScrollGroupId(3)]: 'D',\n [getLocalizeKeyForScrollGroupId(4)]: 'E',\n [getLocalizeKeyForScrollGroupId(5)]: 'F',\n [getLocalizeKeyForScrollGroupId(6)]: 'G',\n [getLocalizeKeyForScrollGroupId(7)]: 'H',\n [getLocalizeKeyForScrollGroupId(8)]: 'I',\n [getLocalizeKeyForScrollGroupId(9)]: 'J',\n [getLocalizeKeyForScrollGroupId(10)]: 'K',\n [getLocalizeKeyForScrollGroupId(11)]: 'L',\n [getLocalizeKeyForScrollGroupId(12)]: 'M',\n [getLocalizeKeyForScrollGroupId(13)]: 'N',\n [getLocalizeKeyForScrollGroupId(14)]: 'O',\n [getLocalizeKeyForScrollGroupId(15)]: 'P',\n [getLocalizeKeyForScrollGroupId(16)]: 'Q',\n [getLocalizeKeyForScrollGroupId(17)]: 'R',\n [getLocalizeKeyForScrollGroupId(18)]: 'S',\n [getLocalizeKeyForScrollGroupId(19)]: 'T',\n [getLocalizeKeyForScrollGroupId(20)]: 'U',\n [getLocalizeKeyForScrollGroupId(21)]: 'V',\n [getLocalizeKeyForScrollGroupId(22)]: 'W',\n [getLocalizeKeyForScrollGroupId(23)]: 'X',\n [getLocalizeKeyForScrollGroupId(24)]: 'Y',\n [getLocalizeKeyForScrollGroupId(25)]: 'Z',\n};\n\nexport type ScrollGroupSelectorProps = {\n /**\n * List of scroll group ids to show to the user. Either a {@link ScrollGroupId} or `undefined` for\n * no scroll group\n */\n availableScrollGroupIds: (ScrollGroupId | undefined)[];\n /** Currently selected scroll group id. `undefined` for no scroll group */\n scrollGroupId: ScrollGroupId | undefined;\n /** Callback function run when the user tries to change the scroll group id */\n onChangeScrollGroupId: (newScrollGroupId: ScrollGroupId | undefined) => void;\n /**\n * Localized strings to use for displaying scroll group ids. Must be an object whose keys are\n * `getLocalizeKeyForScrollGroupId(scrollGroupId)` for all scroll group ids (and `undefined` if\n * included) in {@link ScrollGroupSelectorProps.availableScrollGroupIds} and whose values are the\n * localized strings to use for those scroll group ids.\n *\n * Defaults to English localizations of English alphabet for scroll groups 0-25 (e.g. 0 is A) and\n * Ø for `undefined`. Will fill in any that are not provided with these English localizations.\n * Also, if any values match the keys, the English localization will be used. This is useful in\n * case you want to pass in a temporary version of the localized strings while your localized\n * strings load.\n *\n * @example\n *\n * ```typescript\n * const myScrollGroupIdLocalizedStrings = {\n * [getLocalizeKeyForScrollGroupId('undefined')]: 'Ø',\n * [getLocalizeKeyForScrollGroupId(0)]: 'A',\n * [getLocalizeKeyForScrollGroupId(1)]: 'B',\n * [getLocalizeKeyForScrollGroupId(2)]: 'C',\n * [getLocalizeKeyForScrollGroupId(3)]: 'D',\n * [getLocalizeKeyForScrollGroupId(4)]: 'E',\n * };\n * ```\n *\n * @example\n *\n * ```tsx\n * const availableScrollGroupIds = [undefined, 0, 1, 2, 3, 4];\n *\n * const localizeKeys = getLocalizeKeysForScrollGroupIds();\n *\n * const [localizedStrings] = useLocalizedStrings(localizeKeys);\n *\n * ...\n *\n * \n * ```\n */\n localizedStrings?: LanguageStrings;\n};\n\n/** Selector component for choosing a scroll group */\nexport default function ScrollGroupSelector({\n availableScrollGroupIds,\n scrollGroupId,\n onChangeScrollGroupId,\n localizedStrings = {},\n}: ScrollGroupSelectorProps) {\n const localizedStringsDefaulted = {\n ...DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS,\n ...Object.fromEntries(\n Object.entries(localizedStrings).map(\n ([localizedStringKey, localizedStringValue]: [string, string]) => [\n localizedStringKey,\n localizedStringKey === localizedStringValue &&\n localizedStringKey in DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS\n ? DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS[localizedStringKey]\n : localizedStringValue,\n ],\n ),\n ),\n };\n return (\n \n onChangeScrollGroupId(\n newScrollGroupString === 'undefined' ? undefined : parseInt(newScrollGroupString, 10),\n )\n }\n >\n \n \n \n \n {availableScrollGroupIds.map((scrollGroupOptionId) => (\n \n {localizedStringsDefaulted[getLocalizeKeyForScrollGroupId(scrollGroupOptionId)]}\n \n ))}\n \n \n );\n}\n","import { PropsWithChildren } from 'react';\nimport { Separator } from '@/components/shadcn-ui/separator';\n\n/** Props for the SettingsList component, currently just children */\ntype SettingsListProps = PropsWithChildren;\n\n/**\n * SettingsList component is a wrapper for list items. Rendered with a formatted div\n *\n * @param children To populate the list with\n * @returns Formatted div encompassing the children\n */\nexport function SettingsList({ children }: SettingsListProps) {\n return
    {children}
    ;\n}\n\n/** Props for SettingsListItem component */\ntype SettingsListItemProps = PropsWithChildren & {\n /** Primary text of the list item */\n primary: string;\n\n /** Optional text of the list item */\n secondary?: string | undefined;\n\n /** Optional boolean to display a message if the children aren't loaded yet. Defaults to false */\n isLoading?: boolean;\n\n /** Optional message to display if isLoading */\n loadingMessage?: string;\n};\n\n/**\n * SettingsListItem component is a common list item. Rendered with a formatted div\n *\n * @param primary Primary text of the list item\n * @param secondary Optional secondary text of the list item\n * @param isLoading Optional, to display a message if the action component isn't generated yet,\n * defaults to false\n * @param children The action component(s) to provide for this item\n * @param loadingMessage Optional, message to display if isLoading\n * @returns Formatted div encompassing the list item content\n */\nexport function SettingsListItem({\n primary,\n secondary,\n children,\n isLoading = false,\n loadingMessage,\n}: SettingsListItemProps) {\n return (\n
    \n
    \n

    {primary}

    \n

    \n {secondary}\n

    \n
    \n\n {isLoading ? (\n

    {loadingMessage}

    \n ) : (\n
    {children}
    \n )}\n
    \n );\n}\n\n/** Props for SettingsListHeader component */\ntype SettingsListHeaderProps = {\n /** The primary text of the list header */\n primary: string;\n\n /** Optional secondary text of the list header */\n secondary?: string | undefined;\n\n /** Optional boolean to include a separator underneath the secondary text. Defaults to false */\n includeSeparator?: boolean;\n};\n\n/**\n * SettingsListHeader component displays text above the list\n *\n * @param primary The primary text of the list header\n * @param secondary Optional secondary text of the list header\n * @param includeSeparator Optional boolean to include a separator underneath the secondary text.\n * Defaults to false\n * @returns Formatted div with list header content\n */\nexport function SettingsListHeader({\n primary,\n secondary,\n includeSeparator = false,\n}: SettingsListHeaderProps) {\n return (\n
    \n
    \n

    {primary}

    \n

    {secondary}

    \n
    \n {includeSeparator ? : ''}\n
    \n );\n}\n","import React from 'react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Card = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nCard.displayName = 'Card';\n\nconst CardHeader = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nCardHeader.displayName = 'CardHeader';\n\nconst CardTitle = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n {/* added because of https://github.com/jsx-eslint/eslint-plugin-jsx-a11y/blob/main/docs/rules/heading-has-content.md */}\n {props.children}\n \n ),\n);\nCardTitle.displayName = 'CardTitle';\n\nconst CardDescription = React.forwardRef<\n HTMLParagraphElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n

    \n));\nCardDescription.displayName = 'CardDescription';\n\nconst CardContent = React.forwardRef>(\n ({ className, ...props }, ref) => (\n

    \n ),\n);\nCardContent.displayName = 'CardContent';\n\nconst CardFooter = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nCardFooter.displayName = 'CardFooter';\n\nexport { Card, CardHeader, CardFooter, CardTitle, CardDescription, CardContent };\n","import {\n Card,\n CardDescription,\n CardHeader,\n CardTitle,\n CardContent,\n} from '@/components/shadcn-ui/card';\nimport { PropsWithChildren } from 'react';\n\ntype SettingsCardProps = PropsWithChildren & {\n /** Optional id for testing */\n id?: string;\n\n /** Label of the settings group */\n settingsGroupLabel: string;\n\n /** Optional description of the settings group */\n settingsGroupDescription?: string;\n};\n\nexport default function SettingsCard({\n id,\n settingsGroupLabel,\n settingsGroupDescription,\n children,\n}: SettingsCardProps) {\n return (\n \n \n {settingsGroupLabel}\n {settingsGroupDescription && {settingsGroupDescription}}\n \n {children}\n \n );\n}\n","import Checkbox from '@/components/shadcn-ui/checkbox';\nimport { Label } from '@/components/shadcn-ui/label';\n\nexport type ChecklistProps = {\n /** Optional string representing the id attribute of the Checklist */\n id?: string;\n /** Optional string representing CSS class name(s) for styling */\n className?: string;\n /** Array of strings representing the checkable items */\n listItems: string[];\n /** Array of strings representing the checked items */\n selectedListItems: string[];\n /**\n * Function that is called when a checkbox item is selected or deselected\n *\n * @param item The string description for this item\n * @param selected True if selected, false if not selected\n */\n handleSelectListItem: (item: string, selected: boolean) => void;\n\n /**\n * Optional function creates a label for a provided checkable item\n *\n * @param item The item for which a label is to be created\n * @returns A string representing the label text for the checkbox associated with that item\n */\n createLabel?: (item: string) => string;\n};\n\n/** Renders a list of checkboxes. Each checkbox corresponds to an item from the `listItems` array. */\nexport default function Checklist({\n id,\n className,\n listItems,\n selectedListItems,\n handleSelectListItem,\n createLabel,\n}: ChecklistProps) {\n return (\n
    \n {listItems.map((item) => (\n
    \n handleSelectListItem(item, value)}\n />\n \n
    \n ))}\n
    \n );\n}\n","function _interopRequireDefault(obj) {\n return obj && obj.__esModule ? obj : {\n \"default\": obj\n };\n}\nmodule.exports = _interopRequireDefault, module.exports.__esModule = true, module.exports[\"default\"] = module.exports;","export default function chainPropTypes(propType1, propType2) {\n if (process.env.NODE_ENV === 'production') {\n return () => null;\n }\n return function validate(...args) {\n return propType1(...args) || propType2(...args);\n };\n}","export default function _extends() {\n _extends = Object.assign ? Object.assign.bind() : function (target) {\n for (var i = 1; i < arguments.length; i++) {\n var source = arguments[i];\n for (var key in source) {\n if (Object.prototype.hasOwnProperty.call(source, key)) {\n target[key] = source[key];\n }\n }\n }\n return target;\n };\n return _extends.apply(this, arguments);\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\n// https://github.com/sindresorhus/is-plain-obj/blob/main/index.js\nexport function isPlainObject(item) {\n if (typeof item !== 'object' || item === null) {\n return false;\n }\n const prototype = Object.getPrototypeOf(item);\n return (prototype === null || prototype === Object.prototype || Object.getPrototypeOf(prototype) === null) && !(Symbol.toStringTag in item) && !(Symbol.iterator in item);\n}\nfunction deepClone(source) {\n if (!isPlainObject(source)) {\n return source;\n }\n const output = {};\n Object.keys(source).forEach(key => {\n output[key] = deepClone(source[key]);\n });\n return output;\n}\nexport default function deepmerge(target, source, options = {\n clone: true\n}) {\n const output = options.clone ? _extends({}, target) : target;\n if (isPlainObject(target) && isPlainObject(source)) {\n Object.keys(source).forEach(key => {\n // Avoid prototype pollution\n if (key === '__proto__') {\n return;\n }\n if (isPlainObject(source[key]) && key in target && isPlainObject(target[key])) {\n // Since `output` is a clone of `target` and we have narrowed `target` in this block we can cast to the same type.\n output[key] = deepmerge(target[key], source[key], options);\n } else if (options.clone) {\n output[key] = isPlainObject(source[key]) ? deepClone(source[key]) : source[key];\n } else {\n output[key] = source[key];\n }\n });\n }\n return output;\n}","/** @license React v16.13.1\n * react-is.production.min.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';var b=\"function\"===typeof Symbol&&Symbol.for,c=b?Symbol.for(\"react.element\"):60103,d=b?Symbol.for(\"react.portal\"):60106,e=b?Symbol.for(\"react.fragment\"):60107,f=b?Symbol.for(\"react.strict_mode\"):60108,g=b?Symbol.for(\"react.profiler\"):60114,h=b?Symbol.for(\"react.provider\"):60109,k=b?Symbol.for(\"react.context\"):60110,l=b?Symbol.for(\"react.async_mode\"):60111,m=b?Symbol.for(\"react.concurrent_mode\"):60111,n=b?Symbol.for(\"react.forward_ref\"):60112,p=b?Symbol.for(\"react.suspense\"):60113,q=b?\nSymbol.for(\"react.suspense_list\"):60120,r=b?Symbol.for(\"react.memo\"):60115,t=b?Symbol.for(\"react.lazy\"):60116,v=b?Symbol.for(\"react.block\"):60121,w=b?Symbol.for(\"react.fundamental\"):60117,x=b?Symbol.for(\"react.responder\"):60118,y=b?Symbol.for(\"react.scope\"):60119;\nfunction z(a){if(\"object\"===typeof a&&null!==a){var u=a.$$typeof;switch(u){case c:switch(a=a.type,a){case l:case m:case e:case g:case f:case p:return a;default:switch(a=a&&a.$$typeof,a){case k:case n:case t:case r:case h:return a;default:return u}}case d:return u}}}function A(a){return z(a)===m}exports.AsyncMode=l;exports.ConcurrentMode=m;exports.ContextConsumer=k;exports.ContextProvider=h;exports.Element=c;exports.ForwardRef=n;exports.Fragment=e;exports.Lazy=t;exports.Memo=r;exports.Portal=d;\nexports.Profiler=g;exports.StrictMode=f;exports.Suspense=p;exports.isAsyncMode=function(a){return A(a)||z(a)===l};exports.isConcurrentMode=A;exports.isContextConsumer=function(a){return z(a)===k};exports.isContextProvider=function(a){return z(a)===h};exports.isElement=function(a){return\"object\"===typeof a&&null!==a&&a.$$typeof===c};exports.isForwardRef=function(a){return z(a)===n};exports.isFragment=function(a){return z(a)===e};exports.isLazy=function(a){return z(a)===t};\nexports.isMemo=function(a){return z(a)===r};exports.isPortal=function(a){return z(a)===d};exports.isProfiler=function(a){return z(a)===g};exports.isStrictMode=function(a){return z(a)===f};exports.isSuspense=function(a){return z(a)===p};\nexports.isValidElementType=function(a){return\"string\"===typeof a||\"function\"===typeof a||a===e||a===m||a===g||a===f||a===p||a===q||\"object\"===typeof a&&null!==a&&(a.$$typeof===t||a.$$typeof===r||a.$$typeof===h||a.$$typeof===k||a.$$typeof===n||a.$$typeof===w||a.$$typeof===x||a.$$typeof===y||a.$$typeof===v)};exports.typeOf=z;\n","/** @license React v16.13.1\n * react-is.development.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\n\n\nif (process.env.NODE_ENV !== \"production\") {\n (function() {\n'use strict';\n\n// The Symbol used to tag the ReactElement-like types. If there is no native Symbol\n// nor polyfill, then a plain number is used for performance.\nvar hasSymbol = typeof Symbol === 'function' && Symbol.for;\nvar REACT_ELEMENT_TYPE = hasSymbol ? Symbol.for('react.element') : 0xeac7;\nvar REACT_PORTAL_TYPE = hasSymbol ? Symbol.for('react.portal') : 0xeaca;\nvar REACT_FRAGMENT_TYPE = hasSymbol ? Symbol.for('react.fragment') : 0xeacb;\nvar REACT_STRICT_MODE_TYPE = hasSymbol ? Symbol.for('react.strict_mode') : 0xeacc;\nvar REACT_PROFILER_TYPE = hasSymbol ? Symbol.for('react.profiler') : 0xead2;\nvar REACT_PROVIDER_TYPE = hasSymbol ? Symbol.for('react.provider') : 0xeacd;\nvar REACT_CONTEXT_TYPE = hasSymbol ? Symbol.for('react.context') : 0xeace; // TODO: We don't use AsyncMode or ConcurrentMode anymore. They were temporary\n// (unstable) APIs that have been removed. Can we remove the symbols?\n\nvar REACT_ASYNC_MODE_TYPE = hasSymbol ? Symbol.for('react.async_mode') : 0xeacf;\nvar REACT_CONCURRENT_MODE_TYPE = hasSymbol ? Symbol.for('react.concurrent_mode') : 0xeacf;\nvar REACT_FORWARD_REF_TYPE = hasSymbol ? Symbol.for('react.forward_ref') : 0xead0;\nvar REACT_SUSPENSE_TYPE = hasSymbol ? Symbol.for('react.suspense') : 0xead1;\nvar REACT_SUSPENSE_LIST_TYPE = hasSymbol ? Symbol.for('react.suspense_list') : 0xead8;\nvar REACT_MEMO_TYPE = hasSymbol ? Symbol.for('react.memo') : 0xead3;\nvar REACT_LAZY_TYPE = hasSymbol ? Symbol.for('react.lazy') : 0xead4;\nvar REACT_BLOCK_TYPE = hasSymbol ? Symbol.for('react.block') : 0xead9;\nvar REACT_FUNDAMENTAL_TYPE = hasSymbol ? Symbol.for('react.fundamental') : 0xead5;\nvar REACT_RESPONDER_TYPE = hasSymbol ? Symbol.for('react.responder') : 0xead6;\nvar REACT_SCOPE_TYPE = hasSymbol ? Symbol.for('react.scope') : 0xead7;\n\nfunction isValidElementType(type) {\n return typeof type === 'string' || typeof type === 'function' || // Note: its typeof might be other than 'symbol' or 'number' if it's a polyfill.\n type === REACT_FRAGMENT_TYPE || type === REACT_CONCURRENT_MODE_TYPE || type === REACT_PROFILER_TYPE || type === REACT_STRICT_MODE_TYPE || type === REACT_SUSPENSE_TYPE || type === REACT_SUSPENSE_LIST_TYPE || typeof type === 'object' && type !== null && (type.$$typeof === REACT_LAZY_TYPE || type.$$typeof === REACT_MEMO_TYPE || type.$$typeof === REACT_PROVIDER_TYPE || type.$$typeof === REACT_CONTEXT_TYPE || type.$$typeof === REACT_FORWARD_REF_TYPE || type.$$typeof === REACT_FUNDAMENTAL_TYPE || type.$$typeof === REACT_RESPONDER_TYPE || type.$$typeof === REACT_SCOPE_TYPE || type.$$typeof === REACT_BLOCK_TYPE);\n}\n\nfunction typeOf(object) {\n if (typeof object === 'object' && object !== null) {\n var $$typeof = object.$$typeof;\n\n switch ($$typeof) {\n case REACT_ELEMENT_TYPE:\n var type = object.type;\n\n switch (type) {\n case REACT_ASYNC_MODE_TYPE:\n case REACT_CONCURRENT_MODE_TYPE:\n case REACT_FRAGMENT_TYPE:\n case REACT_PROFILER_TYPE:\n case REACT_STRICT_MODE_TYPE:\n case REACT_SUSPENSE_TYPE:\n return type;\n\n default:\n var $$typeofType = type && type.$$typeof;\n\n switch ($$typeofType) {\n case REACT_CONTEXT_TYPE:\n case REACT_FORWARD_REF_TYPE:\n case REACT_LAZY_TYPE:\n case REACT_MEMO_TYPE:\n case REACT_PROVIDER_TYPE:\n return $$typeofType;\n\n default:\n return $$typeof;\n }\n\n }\n\n case REACT_PORTAL_TYPE:\n return $$typeof;\n }\n }\n\n return undefined;\n} // AsyncMode is deprecated along with isAsyncMode\n\nvar AsyncMode = REACT_ASYNC_MODE_TYPE;\nvar ConcurrentMode = REACT_CONCURRENT_MODE_TYPE;\nvar ContextConsumer = REACT_CONTEXT_TYPE;\nvar ContextProvider = REACT_PROVIDER_TYPE;\nvar Element = REACT_ELEMENT_TYPE;\nvar ForwardRef = REACT_FORWARD_REF_TYPE;\nvar Fragment = REACT_FRAGMENT_TYPE;\nvar Lazy = REACT_LAZY_TYPE;\nvar Memo = REACT_MEMO_TYPE;\nvar Portal = REACT_PORTAL_TYPE;\nvar Profiler = REACT_PROFILER_TYPE;\nvar StrictMode = REACT_STRICT_MODE_TYPE;\nvar Suspense = REACT_SUSPENSE_TYPE;\nvar hasWarnedAboutDeprecatedIsAsyncMode = false; // AsyncMode should be deprecated\n\nfunction isAsyncMode(object) {\n {\n if (!hasWarnedAboutDeprecatedIsAsyncMode) {\n hasWarnedAboutDeprecatedIsAsyncMode = true; // Using console['warn'] to evade Babel and ESLint\n\n console['warn']('The ReactIs.isAsyncMode() alias has been deprecated, ' + 'and will be removed in React 17+. Update your code to use ' + 'ReactIs.isConcurrentMode() instead. It has the exact same API.');\n }\n }\n\n return isConcurrentMode(object) || typeOf(object) === REACT_ASYNC_MODE_TYPE;\n}\nfunction isConcurrentMode(object) {\n return typeOf(object) === REACT_CONCURRENT_MODE_TYPE;\n}\nfunction isContextConsumer(object) {\n return typeOf(object) === REACT_CONTEXT_TYPE;\n}\nfunction isContextProvider(object) {\n return typeOf(object) === REACT_PROVIDER_TYPE;\n}\nfunction isElement(object) {\n return typeof object === 'object' && object !== null && object.$$typeof === REACT_ELEMENT_TYPE;\n}\nfunction isForwardRef(object) {\n return typeOf(object) === REACT_FORWARD_REF_TYPE;\n}\nfunction isFragment(object) {\n return typeOf(object) === REACT_FRAGMENT_TYPE;\n}\nfunction isLazy(object) {\n return typeOf(object) === REACT_LAZY_TYPE;\n}\nfunction isMemo(object) {\n return typeOf(object) === REACT_MEMO_TYPE;\n}\nfunction isPortal(object) {\n return typeOf(object) === REACT_PORTAL_TYPE;\n}\nfunction isProfiler(object) {\n return typeOf(object) === REACT_PROFILER_TYPE;\n}\nfunction isStrictMode(object) {\n return typeOf(object) === REACT_STRICT_MODE_TYPE;\n}\nfunction isSuspense(object) {\n return typeOf(object) === REACT_SUSPENSE_TYPE;\n}\n\nexports.AsyncMode = AsyncMode;\nexports.ConcurrentMode = ConcurrentMode;\nexports.ContextConsumer = ContextConsumer;\nexports.ContextProvider = ContextProvider;\nexports.Element = Element;\nexports.ForwardRef = ForwardRef;\nexports.Fragment = Fragment;\nexports.Lazy = Lazy;\nexports.Memo = Memo;\nexports.Portal = Portal;\nexports.Profiler = Profiler;\nexports.StrictMode = StrictMode;\nexports.Suspense = Suspense;\nexports.isAsyncMode = isAsyncMode;\nexports.isConcurrentMode = isConcurrentMode;\nexports.isContextConsumer = isContextConsumer;\nexports.isContextProvider = isContextProvider;\nexports.isElement = isElement;\nexports.isForwardRef = isForwardRef;\nexports.isFragment = isFragment;\nexports.isLazy = isLazy;\nexports.isMemo = isMemo;\nexports.isPortal = isPortal;\nexports.isProfiler = isProfiler;\nexports.isStrictMode = isStrictMode;\nexports.isSuspense = isSuspense;\nexports.isValidElementType = isValidElementType;\nexports.typeOf = typeOf;\n })();\n}\n","'use strict';\n\nif (process.env.NODE_ENV === 'production') {\n module.exports = require('./cjs/react-is.production.min.js');\n} else {\n module.exports = require('./cjs/react-is.development.js');\n}\n","/*\nobject-assign\n(c) Sindre Sorhus\n@license MIT\n*/\n\n'use strict';\n/* eslint-disable no-unused-vars */\nvar getOwnPropertySymbols = Object.getOwnPropertySymbols;\nvar hasOwnProperty = Object.prototype.hasOwnProperty;\nvar propIsEnumerable = Object.prototype.propertyIsEnumerable;\n\nfunction toObject(val) {\n\tif (val === null || val === undefined) {\n\t\tthrow new TypeError('Object.assign cannot be called with null or undefined');\n\t}\n\n\treturn Object(val);\n}\n\nfunction shouldUseNative() {\n\ttry {\n\t\tif (!Object.assign) {\n\t\t\treturn false;\n\t\t}\n\n\t\t// Detect buggy property enumeration order in older V8 versions.\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=4118\n\t\tvar test1 = new String('abc'); // eslint-disable-line no-new-wrappers\n\t\ttest1[5] = 'de';\n\t\tif (Object.getOwnPropertyNames(test1)[0] === '5') {\n\t\t\treturn false;\n\t\t}\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=3056\n\t\tvar test2 = {};\n\t\tfor (var i = 0; i < 10; i++) {\n\t\t\ttest2['_' + String.fromCharCode(i)] = i;\n\t\t}\n\t\tvar order2 = Object.getOwnPropertyNames(test2).map(function (n) {\n\t\t\treturn test2[n];\n\t\t});\n\t\tif (order2.join('') !== '0123456789') {\n\t\t\treturn false;\n\t\t}\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=3056\n\t\tvar test3 = {};\n\t\t'abcdefghijklmnopqrst'.split('').forEach(function (letter) {\n\t\t\ttest3[letter] = letter;\n\t\t});\n\t\tif (Object.keys(Object.assign({}, test3)).join('') !==\n\t\t\t\t'abcdefghijklmnopqrst') {\n\t\t\treturn false;\n\t\t}\n\n\t\treturn true;\n\t} catch (err) {\n\t\t// We don't expect any of the above to throw, but better to be safe.\n\t\treturn false;\n\t}\n}\n\nmodule.exports = shouldUseNative() ? Object.assign : function (target, source) {\n\tvar from;\n\tvar to = toObject(target);\n\tvar symbols;\n\n\tfor (var s = 1; s < arguments.length; s++) {\n\t\tfrom = Object(arguments[s]);\n\n\t\tfor (var key in from) {\n\t\t\tif (hasOwnProperty.call(from, key)) {\n\t\t\t\tto[key] = from[key];\n\t\t\t}\n\t\t}\n\n\t\tif (getOwnPropertySymbols) {\n\t\t\tsymbols = getOwnPropertySymbols(from);\n\t\t\tfor (var i = 0; i < symbols.length; i++) {\n\t\t\t\tif (propIsEnumerable.call(from, symbols[i])) {\n\t\t\t\t\tto[symbols[i]] = from[symbols[i]];\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\n\treturn to;\n};\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar ReactPropTypesSecret = 'SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED';\n\nmodule.exports = ReactPropTypesSecret;\n","module.exports = Function.call.bind(Object.prototype.hasOwnProperty);\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar printWarning = function() {};\n\nif (process.env.NODE_ENV !== 'production') {\n var ReactPropTypesSecret = require('./lib/ReactPropTypesSecret');\n var loggedTypeFailures = {};\n var has = require('./lib/has');\n\n printWarning = function(text) {\n var message = 'Warning: ' + text;\n if (typeof console !== 'undefined') {\n console.error(message);\n }\n try {\n // --- Welcome to debugging React ---\n // This error was thrown as a convenience so that you can use this stack\n // to find the callsite that caused this warning to fire.\n throw new Error(message);\n } catch (x) { /**/ }\n };\n}\n\n/**\n * Assert that the values match with the type specs.\n * Error messages are memorized and will only be shown once.\n *\n * @param {object} typeSpecs Map of name to a ReactPropType\n * @param {object} values Runtime values that need to be type-checked\n * @param {string} location e.g. \"prop\", \"context\", \"child context\"\n * @param {string} componentName Name of the component for error messages.\n * @param {?Function} getStack Returns the component stack.\n * @private\n */\nfunction checkPropTypes(typeSpecs, values, location, componentName, getStack) {\n if (process.env.NODE_ENV !== 'production') {\n for (var typeSpecName in typeSpecs) {\n if (has(typeSpecs, typeSpecName)) {\n var error;\n // Prop type validation may throw. In case they do, we don't want to\n // fail the render phase where it didn't fail before. So we log it.\n // After these have been cleaned up, we'll let them throw.\n try {\n // This is intentionally an invariant that gets caught. It's the same\n // behavior as without this statement except with a better message.\n if (typeof typeSpecs[typeSpecName] !== 'function') {\n var err = Error(\n (componentName || 'React class') + ': ' + location + ' type `' + typeSpecName + '` is invalid; ' +\n 'it must be a function, usually from the `prop-types` package, but received `' + typeof typeSpecs[typeSpecName] + '`.' +\n 'This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.'\n );\n err.name = 'Invariant Violation';\n throw err;\n }\n error = typeSpecs[typeSpecName](values, typeSpecName, componentName, location, null, ReactPropTypesSecret);\n } catch (ex) {\n error = ex;\n }\n if (error && !(error instanceof Error)) {\n printWarning(\n (componentName || 'React class') + ': type specification of ' +\n location + ' `' + typeSpecName + '` is invalid; the type checker ' +\n 'function must return `null` or an `Error` but returned a ' + typeof error + '. ' +\n 'You may have forgotten to pass an argument to the type checker ' +\n 'creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and ' +\n 'shape all require an argument).'\n );\n }\n if (error instanceof Error && !(error.message in loggedTypeFailures)) {\n // Only monitor this failure once because there tends to be a lot of the\n // same error.\n loggedTypeFailures[error.message] = true;\n\n var stack = getStack ? getStack() : '';\n\n printWarning(\n 'Failed ' + location + ' type: ' + error.message + (stack != null ? stack : '')\n );\n }\n }\n }\n }\n}\n\n/**\n * Resets warning cache when testing.\n *\n * @private\n */\ncheckPropTypes.resetWarningCache = function() {\n if (process.env.NODE_ENV !== 'production') {\n loggedTypeFailures = {};\n }\n}\n\nmodule.exports = checkPropTypes;\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar ReactIs = require('react-is');\nvar assign = require('object-assign');\n\nvar ReactPropTypesSecret = require('./lib/ReactPropTypesSecret');\nvar has = require('./lib/has');\nvar checkPropTypes = require('./checkPropTypes');\n\nvar printWarning = function() {};\n\nif (process.env.NODE_ENV !== 'production') {\n printWarning = function(text) {\n var message = 'Warning: ' + text;\n if (typeof console !== 'undefined') {\n console.error(message);\n }\n try {\n // --- Welcome to debugging React ---\n // This error was thrown as a convenience so that you can use this stack\n // to find the callsite that caused this warning to fire.\n throw new Error(message);\n } catch (x) {}\n };\n}\n\nfunction emptyFunctionThatReturnsNull() {\n return null;\n}\n\nmodule.exports = function(isValidElement, throwOnDirectAccess) {\n /* global Symbol */\n var ITERATOR_SYMBOL = typeof Symbol === 'function' && Symbol.iterator;\n var FAUX_ITERATOR_SYMBOL = '@@iterator'; // Before Symbol spec.\n\n /**\n * Returns the iterator method function contained on the iterable object.\n *\n * Be sure to invoke the function with the iterable as context:\n *\n * var iteratorFn = getIteratorFn(myIterable);\n * if (iteratorFn) {\n * var iterator = iteratorFn.call(myIterable);\n * ...\n * }\n *\n * @param {?object} maybeIterable\n * @return {?function}\n */\n function getIteratorFn(maybeIterable) {\n var iteratorFn = maybeIterable && (ITERATOR_SYMBOL && maybeIterable[ITERATOR_SYMBOL] || maybeIterable[FAUX_ITERATOR_SYMBOL]);\n if (typeof iteratorFn === 'function') {\n return iteratorFn;\n }\n }\n\n /**\n * Collection of methods that allow declaration and validation of props that are\n * supplied to React components. Example usage:\n *\n * var Props = require('ReactPropTypes');\n * var MyArticle = React.createClass({\n * propTypes: {\n * // An optional string prop named \"description\".\n * description: Props.string,\n *\n * // A required enum prop named \"category\".\n * category: Props.oneOf(['News','Photos']).isRequired,\n *\n * // A prop named \"dialog\" that requires an instance of Dialog.\n * dialog: Props.instanceOf(Dialog).isRequired\n * },\n * render: function() { ... }\n * });\n *\n * A more formal specification of how these methods are used:\n *\n * type := array|bool|func|object|number|string|oneOf([...])|instanceOf(...)\n * decl := ReactPropTypes.{type}(.isRequired)?\n *\n * Each and every declaration produces a function with the same signature. This\n * allows the creation of custom validation functions. For example:\n *\n * var MyLink = React.createClass({\n * propTypes: {\n * // An optional string or URI prop named \"href\".\n * href: function(props, propName, componentName) {\n * var propValue = props[propName];\n * if (propValue != null && typeof propValue !== 'string' &&\n * !(propValue instanceof URI)) {\n * return new Error(\n * 'Expected a string or an URI for ' + propName + ' in ' +\n * componentName\n * );\n * }\n * }\n * },\n * render: function() {...}\n * });\n *\n * @internal\n */\n\n var ANONYMOUS = '<>';\n\n // Important!\n // Keep this list in sync with production version in `./factoryWithThrowingShims.js`.\n var ReactPropTypes = {\n array: createPrimitiveTypeChecker('array'),\n bigint: createPrimitiveTypeChecker('bigint'),\n bool: createPrimitiveTypeChecker('boolean'),\n func: createPrimitiveTypeChecker('function'),\n number: createPrimitiveTypeChecker('number'),\n object: createPrimitiveTypeChecker('object'),\n string: createPrimitiveTypeChecker('string'),\n symbol: createPrimitiveTypeChecker('symbol'),\n\n any: createAnyTypeChecker(),\n arrayOf: createArrayOfTypeChecker,\n element: createElementTypeChecker(),\n elementType: createElementTypeTypeChecker(),\n instanceOf: createInstanceTypeChecker,\n node: createNodeChecker(),\n objectOf: createObjectOfTypeChecker,\n oneOf: createEnumTypeChecker,\n oneOfType: createUnionTypeChecker,\n shape: createShapeTypeChecker,\n exact: createStrictShapeTypeChecker,\n };\n\n /**\n * inlined Object.is polyfill to avoid requiring consumers ship their own\n * https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object/is\n */\n /*eslint-disable no-self-compare*/\n function is(x, y) {\n // SameValue algorithm\n if (x === y) {\n // Steps 1-5, 7-10\n // Steps 6.b-6.e: +0 != -0\n return x !== 0 || 1 / x === 1 / y;\n } else {\n // Step 6.a: NaN == NaN\n return x !== x && y !== y;\n }\n }\n /*eslint-enable no-self-compare*/\n\n /**\n * We use an Error-like object for backward compatibility as people may call\n * PropTypes directly and inspect their output. However, we don't use real\n * Errors anymore. We don't inspect their stack anyway, and creating them\n * is prohibitively expensive if they are created too often, such as what\n * happens in oneOfType() for any type before the one that matched.\n */\n function PropTypeError(message, data) {\n this.message = message;\n this.data = data && typeof data === 'object' ? data: {};\n this.stack = '';\n }\n // Make `instanceof Error` still work for returned errors.\n PropTypeError.prototype = Error.prototype;\n\n function createChainableTypeChecker(validate) {\n if (process.env.NODE_ENV !== 'production') {\n var manualPropTypeCallCache = {};\n var manualPropTypeWarningCount = 0;\n }\n function checkType(isRequired, props, propName, componentName, location, propFullName, secret) {\n componentName = componentName || ANONYMOUS;\n propFullName = propFullName || propName;\n\n if (secret !== ReactPropTypesSecret) {\n if (throwOnDirectAccess) {\n // New behavior only for users of `prop-types` package\n var err = new Error(\n 'Calling PropTypes validators directly is not supported by the `prop-types` package. ' +\n 'Use `PropTypes.checkPropTypes()` to call them. ' +\n 'Read more at http://fb.me/use-check-prop-types'\n );\n err.name = 'Invariant Violation';\n throw err;\n } else if (process.env.NODE_ENV !== 'production' && typeof console !== 'undefined') {\n // Old behavior for people using React.PropTypes\n var cacheKey = componentName + ':' + propName;\n if (\n !manualPropTypeCallCache[cacheKey] &&\n // Avoid spamming the console because they are often not actionable except for lib authors\n manualPropTypeWarningCount < 3\n ) {\n printWarning(\n 'You are manually calling a React.PropTypes validation ' +\n 'function for the `' + propFullName + '` prop on `' + componentName + '`. This is deprecated ' +\n 'and will throw in the standalone `prop-types` package. ' +\n 'You may be seeing this warning due to a third-party PropTypes ' +\n 'library. See https://fb.me/react-warning-dont-call-proptypes ' + 'for details.'\n );\n manualPropTypeCallCache[cacheKey] = true;\n manualPropTypeWarningCount++;\n }\n }\n }\n if (props[propName] == null) {\n if (isRequired) {\n if (props[propName] === null) {\n return new PropTypeError('The ' + location + ' `' + propFullName + '` is marked as required ' + ('in `' + componentName + '`, but its value is `null`.'));\n }\n return new PropTypeError('The ' + location + ' `' + propFullName + '` is marked as required in ' + ('`' + componentName + '`, but its value is `undefined`.'));\n }\n return null;\n } else {\n return validate(props, propName, componentName, location, propFullName);\n }\n }\n\n var chainedCheckType = checkType.bind(null, false);\n chainedCheckType.isRequired = checkType.bind(null, true);\n\n return chainedCheckType;\n }\n\n function createPrimitiveTypeChecker(expectedType) {\n function validate(props, propName, componentName, location, propFullName, secret) {\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== expectedType) {\n // `propValue` being instance of, say, date/regexp, pass the 'object'\n // check, but we can offer a more precise error message here rather than\n // 'of type `object`'.\n var preciseType = getPreciseType(propValue);\n\n return new PropTypeError(\n 'Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + preciseType + '` supplied to `' + componentName + '`, expected ') + ('`' + expectedType + '`.'),\n {expectedType: expectedType}\n );\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createAnyTypeChecker() {\n return createChainableTypeChecker(emptyFunctionThatReturnsNull);\n }\n\n function createArrayOfTypeChecker(typeChecker) {\n function validate(props, propName, componentName, location, propFullName) {\n if (typeof typeChecker !== 'function') {\n return new PropTypeError('Property `' + propFullName + '` of component `' + componentName + '` has invalid PropType notation inside arrayOf.');\n }\n var propValue = props[propName];\n if (!Array.isArray(propValue)) {\n var propType = getPropType(propValue);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected an array.'));\n }\n for (var i = 0; i < propValue.length; i++) {\n var error = typeChecker(propValue, i, componentName, location, propFullName + '[' + i + ']', ReactPropTypesSecret);\n if (error instanceof Error) {\n return error;\n }\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createElementTypeChecker() {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n if (!isValidElement(propValue)) {\n var propType = getPropType(propValue);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected a single ReactElement.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createElementTypeTypeChecker() {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n if (!ReactIs.isValidElementType(propValue)) {\n var propType = getPropType(propValue);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected a single ReactElement type.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createInstanceTypeChecker(expectedClass) {\n function validate(props, propName, componentName, location, propFullName) {\n if (!(props[propName] instanceof expectedClass)) {\n var expectedClassName = expectedClass.name || ANONYMOUS;\n var actualClassName = getClassName(props[propName]);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + actualClassName + '` supplied to `' + componentName + '`, expected ') + ('instance of `' + expectedClassName + '`.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createEnumTypeChecker(expectedValues) {\n if (!Array.isArray(expectedValues)) {\n if (process.env.NODE_ENV !== 'production') {\n if (arguments.length > 1) {\n printWarning(\n 'Invalid arguments supplied to oneOf, expected an array, got ' + arguments.length + ' arguments. ' +\n 'A common mistake is to write oneOf(x, y, z) instead of oneOf([x, y, z]).'\n );\n } else {\n printWarning('Invalid argument supplied to oneOf, expected an array.');\n }\n }\n return emptyFunctionThatReturnsNull;\n }\n\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n for (var i = 0; i < expectedValues.length; i++) {\n if (is(propValue, expectedValues[i])) {\n return null;\n }\n }\n\n var valuesString = JSON.stringify(expectedValues, function replacer(key, value) {\n var type = getPreciseType(value);\n if (type === 'symbol') {\n return String(value);\n }\n return value;\n });\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of value `' + String(propValue) + '` ' + ('supplied to `' + componentName + '`, expected one of ' + valuesString + '.'));\n }\n return createChainableTypeChecker(validate);\n }\n\n function createObjectOfTypeChecker(typeChecker) {\n function validate(props, propName, componentName, location, propFullName) {\n if (typeof typeChecker !== 'function') {\n return new PropTypeError('Property `' + propFullName + '` of component `' + componentName + '` has invalid PropType notation inside objectOf.');\n }\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== 'object') {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected an object.'));\n }\n for (var key in propValue) {\n if (has(propValue, key)) {\n var error = typeChecker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret);\n if (error instanceof Error) {\n return error;\n }\n }\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createUnionTypeChecker(arrayOfTypeCheckers) {\n if (!Array.isArray(arrayOfTypeCheckers)) {\n process.env.NODE_ENV !== 'production' ? printWarning('Invalid argument supplied to oneOfType, expected an instance of array.') : void 0;\n return emptyFunctionThatReturnsNull;\n }\n\n for (var i = 0; i < arrayOfTypeCheckers.length; i++) {\n var checker = arrayOfTypeCheckers[i];\n if (typeof checker !== 'function') {\n printWarning(\n 'Invalid argument supplied to oneOfType. Expected an array of check functions, but ' +\n 'received ' + getPostfixForTypeWarning(checker) + ' at index ' + i + '.'\n );\n return emptyFunctionThatReturnsNull;\n }\n }\n\n function validate(props, propName, componentName, location, propFullName) {\n var expectedTypes = [];\n for (var i = 0; i < arrayOfTypeCheckers.length; i++) {\n var checker = arrayOfTypeCheckers[i];\n var checkerResult = checker(props, propName, componentName, location, propFullName, ReactPropTypesSecret);\n if (checkerResult == null) {\n return null;\n }\n if (checkerResult.data && has(checkerResult.data, 'expectedType')) {\n expectedTypes.push(checkerResult.data.expectedType);\n }\n }\n var expectedTypesMessage = (expectedTypes.length > 0) ? ', expected one of type [' + expectedTypes.join(', ') + ']': '';\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` supplied to ' + ('`' + componentName + '`' + expectedTypesMessage + '.'));\n }\n return createChainableTypeChecker(validate);\n }\n\n function createNodeChecker() {\n function validate(props, propName, componentName, location, propFullName) {\n if (!isNode(props[propName])) {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` supplied to ' + ('`' + componentName + '`, expected a ReactNode.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function invalidValidatorError(componentName, location, propFullName, key, type) {\n return new PropTypeError(\n (componentName || 'React class') + ': ' + location + ' type `' + propFullName + '.' + key + '` is invalid; ' +\n 'it must be a function, usually from the `prop-types` package, but received `' + type + '`.'\n );\n }\n\n function createShapeTypeChecker(shapeTypes) {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== 'object') {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type `' + propType + '` ' + ('supplied to `' + componentName + '`, expected `object`.'));\n }\n for (var key in shapeTypes) {\n var checker = shapeTypes[key];\n if (typeof checker !== 'function') {\n return invalidValidatorError(componentName, location, propFullName, key, getPreciseType(checker));\n }\n var error = checker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret);\n if (error) {\n return error;\n }\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createStrictShapeTypeChecker(shapeTypes) {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== 'object') {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type `' + propType + '` ' + ('supplied to `' + componentName + '`, expected `object`.'));\n }\n // We need to check all keys in case some are required but missing from props.\n var allKeys = assign({}, props[propName], shapeTypes);\n for (var key in allKeys) {\n var checker = shapeTypes[key];\n if (has(shapeTypes, key) && typeof checker !== 'function') {\n return invalidValidatorError(componentName, location, propFullName, key, getPreciseType(checker));\n }\n if (!checker) {\n return new PropTypeError(\n 'Invalid ' + location + ' `' + propFullName + '` key `' + key + '` supplied to `' + componentName + '`.' +\n '\\nBad object: ' + JSON.stringify(props[propName], null, ' ') +\n '\\nValid keys: ' + JSON.stringify(Object.keys(shapeTypes), null, ' ')\n );\n }\n var error = checker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret);\n if (error) {\n return error;\n }\n }\n return null;\n }\n\n return createChainableTypeChecker(validate);\n }\n\n function isNode(propValue) {\n switch (typeof propValue) {\n case 'number':\n case 'string':\n case 'undefined':\n return true;\n case 'boolean':\n return !propValue;\n case 'object':\n if (Array.isArray(propValue)) {\n return propValue.every(isNode);\n }\n if (propValue === null || isValidElement(propValue)) {\n return true;\n }\n\n var iteratorFn = getIteratorFn(propValue);\n if (iteratorFn) {\n var iterator = iteratorFn.call(propValue);\n var step;\n if (iteratorFn !== propValue.entries) {\n while (!(step = iterator.next()).done) {\n if (!isNode(step.value)) {\n return false;\n }\n }\n } else {\n // Iterator will provide entry [k,v] tuples rather than values.\n while (!(step = iterator.next()).done) {\n var entry = step.value;\n if (entry) {\n if (!isNode(entry[1])) {\n return false;\n }\n }\n }\n }\n } else {\n return false;\n }\n\n return true;\n default:\n return false;\n }\n }\n\n function isSymbol(propType, propValue) {\n // Native Symbol.\n if (propType === 'symbol') {\n return true;\n }\n\n // falsy value can't be a Symbol\n if (!propValue) {\n return false;\n }\n\n // 19.4.3.5 Symbol.prototype[@@toStringTag] === 'Symbol'\n if (propValue['@@toStringTag'] === 'Symbol') {\n return true;\n }\n\n // Fallback for non-spec compliant Symbols which are polyfilled.\n if (typeof Symbol === 'function' && propValue instanceof Symbol) {\n return true;\n }\n\n return false;\n }\n\n // Equivalent of `typeof` but with special handling for array and regexp.\n function getPropType(propValue) {\n var propType = typeof propValue;\n if (Array.isArray(propValue)) {\n return 'array';\n }\n if (propValue instanceof RegExp) {\n // Old webkits (at least until Android 4.0) return 'function' rather than\n // 'object' for typeof a RegExp. We'll normalize this here so that /bla/\n // passes PropTypes.object.\n return 'object';\n }\n if (isSymbol(propType, propValue)) {\n return 'symbol';\n }\n return propType;\n }\n\n // This handles more types than `getPropType`. Only used for error messages.\n // See `createPrimitiveTypeChecker`.\n function getPreciseType(propValue) {\n if (typeof propValue === 'undefined' || propValue === null) {\n return '' + propValue;\n }\n var propType = getPropType(propValue);\n if (propType === 'object') {\n if (propValue instanceof Date) {\n return 'date';\n } else if (propValue instanceof RegExp) {\n return 'regexp';\n }\n }\n return propType;\n }\n\n // Returns a string that is postfixed to a warning about an invalid type.\n // For example, \"undefined\" or \"of type array\"\n function getPostfixForTypeWarning(value) {\n var type = getPreciseType(value);\n switch (type) {\n case 'array':\n case 'object':\n return 'an ' + type;\n case 'boolean':\n case 'date':\n case 'regexp':\n return 'a ' + type;\n default:\n return type;\n }\n }\n\n // Returns class name of the object, if any.\n function getClassName(propValue) {\n if (!propValue.constructor || !propValue.constructor.name) {\n return ANONYMOUS;\n }\n return propValue.constructor.name;\n }\n\n ReactPropTypes.checkPropTypes = checkPropTypes;\n ReactPropTypes.resetWarningCache = checkPropTypes.resetWarningCache;\n ReactPropTypes.PropTypes = ReactPropTypes;\n\n return ReactPropTypes;\n};\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar ReactPropTypesSecret = require('./lib/ReactPropTypesSecret');\n\nfunction emptyFunction() {}\nfunction emptyFunctionWithReset() {}\nemptyFunctionWithReset.resetWarningCache = emptyFunction;\n\nmodule.exports = function() {\n function shim(props, propName, componentName, location, propFullName, secret) {\n if (secret === ReactPropTypesSecret) {\n // It is still safe when called from React.\n return;\n }\n var err = new Error(\n 'Calling PropTypes validators directly is not supported by the `prop-types` package. ' +\n 'Use PropTypes.checkPropTypes() to call them. ' +\n 'Read more at http://fb.me/use-check-prop-types'\n );\n err.name = 'Invariant Violation';\n throw err;\n };\n shim.isRequired = shim;\n function getShim() {\n return shim;\n };\n // Important!\n // Keep this list in sync with production version in `./factoryWithTypeCheckers.js`.\n var ReactPropTypes = {\n array: shim,\n bigint: shim,\n bool: shim,\n func: shim,\n number: shim,\n object: shim,\n string: shim,\n symbol: shim,\n\n any: shim,\n arrayOf: getShim,\n element: shim,\n elementType: shim,\n instanceOf: getShim,\n node: shim,\n objectOf: getShim,\n oneOf: getShim,\n oneOfType: getShim,\n shape: getShim,\n exact: getShim,\n\n checkPropTypes: emptyFunctionWithReset,\n resetWarningCache: emptyFunction\n };\n\n ReactPropTypes.PropTypes = ReactPropTypes;\n\n return ReactPropTypes;\n};\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\nif (process.env.NODE_ENV !== 'production') {\n var ReactIs = require('react-is');\n\n // By explicitly using `prop-types` you are opting into new development behavior.\n // http://fb.me/prop-types-in-prod\n var throwOnDirectAccess = true;\n module.exports = require('./factoryWithTypeCheckers')(ReactIs.isElement, throwOnDirectAccess);\n} else {\n // By explicitly using `prop-types` you are opting into new production behavior.\n // http://fb.me/prop-types-in-prod\n module.exports = require('./factoryWithThrowingShims')();\n}\n","import PropTypes from 'prop-types';\nimport chainPropTypes from '../chainPropTypes';\nfunction isClassComponent(elementType) {\n // elementType.prototype?.isReactComponent\n const {\n prototype = {}\n } = elementType;\n return Boolean(prototype.isReactComponent);\n}\nfunction acceptingRef(props, propName, componentName, location, propFullName) {\n const element = props[propName];\n const safePropName = propFullName || propName;\n if (element == null ||\n // When server-side rendering React doesn't warn either.\n // This is not an accurate check for SSR.\n // This is only in place for Emotion compat.\n // TODO: Revisit once https://github.com/facebook/react/issues/20047 is resolved.\n typeof window === 'undefined') {\n return null;\n }\n let warningHint;\n const elementType = element.type;\n /**\n * Blacklisting instead of whitelisting\n *\n * Blacklisting will miss some components, such as React.Fragment. Those will at least\n * trigger a warning in React.\n * We can't whitelist because there is no safe way to detect React.forwardRef\n * or class components. \"Safe\" means there's no public API.\n *\n */\n if (typeof elementType === 'function' && !isClassComponent(elementType)) {\n warningHint = 'Did you accidentally use a plain function component for an element instead?';\n }\n if (warningHint !== undefined) {\n return new Error(`Invalid ${location} \\`${safePropName}\\` supplied to \\`${componentName}\\`. ` + `Expected an element that can hold a ref. ${warningHint} ` + 'For more information see https://mui.com/r/caveat-with-refs-guide');\n }\n return null;\n}\nconst elementAcceptingRef = chainPropTypes(PropTypes.element, acceptingRef);\nelementAcceptingRef.isRequired = chainPropTypes(PropTypes.element.isRequired, acceptingRef);\nexport default elementAcceptingRef;","import _extends from \"@babel/runtime/helpers/esm/extends\";\n// This module is based on https://github.com/airbnb/prop-types-exact repository.\n// However, in order to reduce the number of dependencies and to remove some extra safe checks\n// the module was forked.\n\nconst specialProperty = 'exact-prop: \\u200b';\nexport default function exactProp(propTypes) {\n if (process.env.NODE_ENV === 'production') {\n return propTypes;\n }\n return _extends({}, propTypes, {\n [specialProperty]: props => {\n const unsupportedProps = Object.keys(props).filter(prop => !propTypes.hasOwnProperty(prop));\n if (unsupportedProps.length > 0) {\n return new Error(`The following props are not supported: ${unsupportedProps.map(prop => `\\`${prop}\\``).join(', ')}. Please remove them.`);\n }\n return null;\n }\n });\n}","/**\n * WARNING: Don't import this directly.\n * Use `MuiError` from `@mui/internal-babel-macros/MuiError.macro` instead.\n * @param {number} code\n */\nexport default function formatMuiErrorMessage(code) {\n // Apply babel-plugin-transform-template-literals in loose mode\n // loose mode is safe if we're concatenating primitives\n // see https://babeljs.io/docs/en/babel-plugin-transform-template-literals#loose\n /* eslint-disable prefer-template */\n let url = 'https://mui.com/production-error/?code=' + code;\n for (let i = 1; i < arguments.length; i += 1) {\n // rest params over-transpile for this case\n // eslint-disable-next-line prefer-rest-params\n url += '&args[]=' + encodeURIComponent(arguments[i]);\n }\n return 'Minified MUI error #' + code + '; visit ' + url + ' for the full message.';\n /* eslint-enable prefer-template */\n}","/**\n * @license React\n * react-is.production.min.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n'use strict';var b=Symbol.for(\"react.element\"),c=Symbol.for(\"react.portal\"),d=Symbol.for(\"react.fragment\"),e=Symbol.for(\"react.strict_mode\"),f=Symbol.for(\"react.profiler\"),g=Symbol.for(\"react.provider\"),h=Symbol.for(\"react.context\"),k=Symbol.for(\"react.server_context\"),l=Symbol.for(\"react.forward_ref\"),m=Symbol.for(\"react.suspense\"),n=Symbol.for(\"react.suspense_list\"),p=Symbol.for(\"react.memo\"),q=Symbol.for(\"react.lazy\"),t=Symbol.for(\"react.offscreen\"),u;u=Symbol.for(\"react.module.reference\");\nfunction v(a){if(\"object\"===typeof a&&null!==a){var r=a.$$typeof;switch(r){case b:switch(a=a.type,a){case d:case f:case e:case m:case n:return a;default:switch(a=a&&a.$$typeof,a){case k:case h:case l:case q:case p:case g:return a;default:return r}}case c:return r}}}exports.ContextConsumer=h;exports.ContextProvider=g;exports.Element=b;exports.ForwardRef=l;exports.Fragment=d;exports.Lazy=q;exports.Memo=p;exports.Portal=c;exports.Profiler=f;exports.StrictMode=e;exports.Suspense=m;\nexports.SuspenseList=n;exports.isAsyncMode=function(){return!1};exports.isConcurrentMode=function(){return!1};exports.isContextConsumer=function(a){return v(a)===h};exports.isContextProvider=function(a){return v(a)===g};exports.isElement=function(a){return\"object\"===typeof a&&null!==a&&a.$$typeof===b};exports.isForwardRef=function(a){return v(a)===l};exports.isFragment=function(a){return v(a)===d};exports.isLazy=function(a){return v(a)===q};exports.isMemo=function(a){return v(a)===p};\nexports.isPortal=function(a){return v(a)===c};exports.isProfiler=function(a){return v(a)===f};exports.isStrictMode=function(a){return v(a)===e};exports.isSuspense=function(a){return v(a)===m};exports.isSuspenseList=function(a){return v(a)===n};\nexports.isValidElementType=function(a){return\"string\"===typeof a||\"function\"===typeof a||a===d||a===f||a===e||a===m||a===n||a===t||\"object\"===typeof a&&null!==a&&(a.$$typeof===q||a.$$typeof===p||a.$$typeof===g||a.$$typeof===h||a.$$typeof===l||a.$$typeof===u||void 0!==a.getModuleId)?!0:!1};exports.typeOf=v;\n","/**\n * @license React\n * react-is.development.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nif (process.env.NODE_ENV !== \"production\") {\n (function() {\n'use strict';\n\n// ATTENTION\n// When adding new symbols to this file,\n// Please consider also adding to 'react-devtools-shared/src/backend/ReactSymbols'\n// The Symbol used to tag the ReactElement-like types.\nvar REACT_ELEMENT_TYPE = Symbol.for('react.element');\nvar REACT_PORTAL_TYPE = Symbol.for('react.portal');\nvar REACT_FRAGMENT_TYPE = Symbol.for('react.fragment');\nvar REACT_STRICT_MODE_TYPE = Symbol.for('react.strict_mode');\nvar REACT_PROFILER_TYPE = Symbol.for('react.profiler');\nvar REACT_PROVIDER_TYPE = Symbol.for('react.provider');\nvar REACT_CONTEXT_TYPE = Symbol.for('react.context');\nvar REACT_SERVER_CONTEXT_TYPE = Symbol.for('react.server_context');\nvar REACT_FORWARD_REF_TYPE = Symbol.for('react.forward_ref');\nvar REACT_SUSPENSE_TYPE = Symbol.for('react.suspense');\nvar REACT_SUSPENSE_LIST_TYPE = Symbol.for('react.suspense_list');\nvar REACT_MEMO_TYPE = Symbol.for('react.memo');\nvar REACT_LAZY_TYPE = Symbol.for('react.lazy');\nvar REACT_OFFSCREEN_TYPE = Symbol.for('react.offscreen');\n\n// -----------------------------------------------------------------------------\n\nvar enableScopeAPI = false; // Experimental Create Event Handle API.\nvar enableCacheElement = false;\nvar enableTransitionTracing = false; // No known bugs, but needs performance testing\n\nvar enableLegacyHidden = false; // Enables unstable_avoidThisFallback feature in Fiber\n// stuff. Intended to enable React core members to more easily debug scheduling\n// issues in DEV builds.\n\nvar enableDebugTracing = false; // Track which Fiber(s) schedule render work.\n\nvar REACT_MODULE_REFERENCE;\n\n{\n REACT_MODULE_REFERENCE = Symbol.for('react.module.reference');\n}\n\nfunction isValidElementType(type) {\n if (typeof type === 'string' || typeof type === 'function') {\n return true;\n } // Note: typeof might be other than 'symbol' or 'number' (e.g. if it's a polyfill).\n\n\n if (type === REACT_FRAGMENT_TYPE || type === REACT_PROFILER_TYPE || enableDebugTracing || type === REACT_STRICT_MODE_TYPE || type === REACT_SUSPENSE_TYPE || type === REACT_SUSPENSE_LIST_TYPE || enableLegacyHidden || type === REACT_OFFSCREEN_TYPE || enableScopeAPI || enableCacheElement || enableTransitionTracing ) {\n return true;\n }\n\n if (typeof type === 'object' && type !== null) {\n if (type.$$typeof === REACT_LAZY_TYPE || type.$$typeof === REACT_MEMO_TYPE || type.$$typeof === REACT_PROVIDER_TYPE || type.$$typeof === REACT_CONTEXT_TYPE || type.$$typeof === REACT_FORWARD_REF_TYPE || // This needs to include all possible module reference object\n // types supported by any Flight configuration anywhere since\n // we don't know which Flight build this will end up being used\n // with.\n type.$$typeof === REACT_MODULE_REFERENCE || type.getModuleId !== undefined) {\n return true;\n }\n }\n\n return false;\n}\n\nfunction typeOf(object) {\n if (typeof object === 'object' && object !== null) {\n var $$typeof = object.$$typeof;\n\n switch ($$typeof) {\n case REACT_ELEMENT_TYPE:\n var type = object.type;\n\n switch (type) {\n case REACT_FRAGMENT_TYPE:\n case REACT_PROFILER_TYPE:\n case REACT_STRICT_MODE_TYPE:\n case REACT_SUSPENSE_TYPE:\n case REACT_SUSPENSE_LIST_TYPE:\n return type;\n\n default:\n var $$typeofType = type && type.$$typeof;\n\n switch ($$typeofType) {\n case REACT_SERVER_CONTEXT_TYPE:\n case REACT_CONTEXT_TYPE:\n case REACT_FORWARD_REF_TYPE:\n case REACT_LAZY_TYPE:\n case REACT_MEMO_TYPE:\n case REACT_PROVIDER_TYPE:\n return $$typeofType;\n\n default:\n return $$typeof;\n }\n\n }\n\n case REACT_PORTAL_TYPE:\n return $$typeof;\n }\n }\n\n return undefined;\n}\nvar ContextConsumer = REACT_CONTEXT_TYPE;\nvar ContextProvider = REACT_PROVIDER_TYPE;\nvar Element = REACT_ELEMENT_TYPE;\nvar ForwardRef = REACT_FORWARD_REF_TYPE;\nvar Fragment = REACT_FRAGMENT_TYPE;\nvar Lazy = REACT_LAZY_TYPE;\nvar Memo = REACT_MEMO_TYPE;\nvar Portal = REACT_PORTAL_TYPE;\nvar Profiler = REACT_PROFILER_TYPE;\nvar StrictMode = REACT_STRICT_MODE_TYPE;\nvar Suspense = REACT_SUSPENSE_TYPE;\nvar SuspenseList = REACT_SUSPENSE_LIST_TYPE;\nvar hasWarnedAboutDeprecatedIsAsyncMode = false;\nvar hasWarnedAboutDeprecatedIsConcurrentMode = false; // AsyncMode should be deprecated\n\nfunction isAsyncMode(object) {\n {\n if (!hasWarnedAboutDeprecatedIsAsyncMode) {\n hasWarnedAboutDeprecatedIsAsyncMode = true; // Using console['warn'] to evade Babel and ESLint\n\n console['warn']('The ReactIs.isAsyncMode() alias has been deprecated, ' + 'and will be removed in React 18+.');\n }\n }\n\n return false;\n}\nfunction isConcurrentMode(object) {\n {\n if (!hasWarnedAboutDeprecatedIsConcurrentMode) {\n hasWarnedAboutDeprecatedIsConcurrentMode = true; // Using console['warn'] to evade Babel and ESLint\n\n console['warn']('The ReactIs.isConcurrentMode() alias has been deprecated, ' + 'and will be removed in React 18+.');\n }\n }\n\n return false;\n}\nfunction isContextConsumer(object) {\n return typeOf(object) === REACT_CONTEXT_TYPE;\n}\nfunction isContextProvider(object) {\n return typeOf(object) === REACT_PROVIDER_TYPE;\n}\nfunction isElement(object) {\n return typeof object === 'object' && object !== null && object.$$typeof === REACT_ELEMENT_TYPE;\n}\nfunction isForwardRef(object) {\n return typeOf(object) === REACT_FORWARD_REF_TYPE;\n}\nfunction isFragment(object) {\n return typeOf(object) === REACT_FRAGMENT_TYPE;\n}\nfunction isLazy(object) {\n return typeOf(object) === REACT_LAZY_TYPE;\n}\nfunction isMemo(object) {\n return typeOf(object) === REACT_MEMO_TYPE;\n}\nfunction isPortal(object) {\n return typeOf(object) === REACT_PORTAL_TYPE;\n}\nfunction isProfiler(object) {\n return typeOf(object) === REACT_PROFILER_TYPE;\n}\nfunction isStrictMode(object) {\n return typeOf(object) === REACT_STRICT_MODE_TYPE;\n}\nfunction isSuspense(object) {\n return typeOf(object) === REACT_SUSPENSE_TYPE;\n}\nfunction isSuspenseList(object) {\n return typeOf(object) === REACT_SUSPENSE_LIST_TYPE;\n}\n\nexports.ContextConsumer = ContextConsumer;\nexports.ContextProvider = ContextProvider;\nexports.Element = Element;\nexports.ForwardRef = ForwardRef;\nexports.Fragment = Fragment;\nexports.Lazy = Lazy;\nexports.Memo = Memo;\nexports.Portal = Portal;\nexports.Profiler = Profiler;\nexports.StrictMode = StrictMode;\nexports.Suspense = Suspense;\nexports.SuspenseList = SuspenseList;\nexports.isAsyncMode = isAsyncMode;\nexports.isConcurrentMode = isConcurrentMode;\nexports.isContextConsumer = isContextConsumer;\nexports.isContextProvider = isContextProvider;\nexports.isElement = isElement;\nexports.isForwardRef = isForwardRef;\nexports.isFragment = isFragment;\nexports.isLazy = isLazy;\nexports.isMemo = isMemo;\nexports.isPortal = isPortal;\nexports.isProfiler = isProfiler;\nexports.isStrictMode = isStrictMode;\nexports.isSuspense = isSuspense;\nexports.isSuspenseList = isSuspenseList;\nexports.isValidElementType = isValidElementType;\nexports.typeOf = typeOf;\n })();\n}\n","'use strict';\n\nif (process.env.NODE_ENV === 'production') {\n module.exports = require('./cjs/react-is.production.min.js');\n} else {\n module.exports = require('./cjs/react-is.development.js');\n}\n","import { ForwardRef, Memo } from 'react-is';\n\n// Simplified polyfill for IE11 support\n// https://github.com/JamesMGreene/Function.name/blob/58b314d4a983110c3682f1228f845d39ccca1817/Function.name.js#L3\nconst fnNameMatchRegex = /^\\s*function(?:\\s|\\s*\\/\\*.*\\*\\/\\s*)+([^(\\s/]*)\\s*/;\nexport function getFunctionName(fn) {\n const match = `${fn}`.match(fnNameMatchRegex);\n const name = match && match[1];\n return name || '';\n}\nfunction getFunctionComponentName(Component, fallback = '') {\n return Component.displayName || Component.name || getFunctionName(Component) || fallback;\n}\nfunction getWrappedName(outerType, innerType, wrapperName) {\n const functionName = getFunctionComponentName(innerType);\n return outerType.displayName || (functionName !== '' ? `${wrapperName}(${functionName})` : wrapperName);\n}\n\n/**\n * cherry-pick from\n * https://github.com/facebook/react/blob/769b1f270e1251d9dbdce0fcbd9e92e502d059b8/packages/shared/getComponentName.js\n * originally forked from recompose/getDisplayName with added IE11 support\n */\nexport default function getDisplayName(Component) {\n if (Component == null) {\n return undefined;\n }\n if (typeof Component === 'string') {\n return Component;\n }\n if (typeof Component === 'function') {\n return getFunctionComponentName(Component, 'Component');\n }\n\n // TypeScript can't have components as objects but they exist in the form of `memo` or `Suspense`\n if (typeof Component === 'object') {\n switch (Component.$$typeof) {\n case ForwardRef:\n return getWrappedName(Component, Component.render, 'ForwardRef');\n case Memo:\n return getWrappedName(Component, Component.type, 'memo');\n default:\n return undefined;\n }\n }\n return undefined;\n}","export default function HTMLElementType(props, propName, componentName, location, propFullName) {\n if (process.env.NODE_ENV === 'production') {\n return null;\n }\n const propValue = props[propName];\n const safePropName = propFullName || propName;\n if (propValue == null) {\n return null;\n }\n if (propValue && propValue.nodeType !== 1) {\n return new Error(`Invalid ${location} \\`${safePropName}\\` supplied to \\`${componentName}\\`. ` + `Expected an HTMLElement.`);\n }\n return null;\n}","import PropTypes from 'prop-types';\nconst refType = PropTypes.oneOfType([PropTypes.func, PropTypes.object]);\nexport default refType;","import _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\n// It should to be noted that this function isn't equivalent to `text-transform: capitalize`.\n//\n// A strict capitalization should uppercase the first letter of each word in the sentence.\n// We only handle the first word.\nexport default function capitalize(string) {\n if (typeof string !== 'string') {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: \\`capitalize(string)\\` expects a string argument.` : _formatMuiErrorMessage(7));\n }\n return string.charAt(0).toUpperCase() + string.slice(1);\n}","/**\n * Safe chained function.\n *\n * Will only create a new function if needed,\n * otherwise will pass back existing functions or null.\n */\nexport default function createChainedFunction(...funcs) {\n return funcs.reduce((acc, func) => {\n if (func == null) {\n return acc;\n }\n return function chainedFunction(...args) {\n acc.apply(this, args);\n func.apply(this, args);\n };\n }, () => {});\n}","// Corresponds to 10 frames at 60 Hz.\n// A few bytes payload overhead when lodash/debounce is ~3 kB and debounce ~300 B.\nexport default function debounce(func, wait = 166) {\n let timeout;\n function debounced(...args) {\n const later = () => {\n // @ts-ignore\n func.apply(this, args);\n };\n clearTimeout(timeout);\n timeout = setTimeout(later, wait);\n }\n debounced.clear = () => {\n clearTimeout(timeout);\n };\n return debounced;\n}","export default function deprecatedPropType(validator, reason) {\n if (process.env.NODE_ENV === 'production') {\n return () => null;\n }\n return (props, propName, componentName, location, propFullName) => {\n const componentNameSafe = componentName || '<>';\n const propFullNameSafe = propFullName || propName;\n if (typeof props[propName] !== 'undefined') {\n return new Error(`The ${location} \\`${propFullNameSafe}\\` of ` + `\\`${componentNameSafe}\\` is deprecated. ${reason}`);\n }\n return null;\n };\n}","import * as React from 'react';\nexport default function isMuiElement(element, muiNames) {\n var _muiName, _element$type;\n return /*#__PURE__*/React.isValidElement(element) && muiNames.indexOf( // For server components `muiName` is avaialble in element.type._payload.value.muiName\n // relevant info - https://github.com/facebook/react/blob/2807d781a08db8e9873687fccc25c0f12b4fb3d4/packages/react/src/ReactLazy.js#L45\n // eslint-disable-next-line no-underscore-dangle\n (_muiName = element.type.muiName) != null ? _muiName : (_element$type = element.type) == null || (_element$type = _element$type._payload) == null || (_element$type = _element$type.value) == null ? void 0 : _element$type.muiName) !== -1;\n}","export default function ownerDocument(node) {\n return node && node.ownerDocument || document;\n}","import ownerDocument from '../ownerDocument';\nexport default function ownerWindow(node) {\n const doc = ownerDocument(node);\n return doc.defaultView || window;\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nexport default function requirePropFactory(componentNameInError, Component) {\n if (process.env.NODE_ENV === 'production') {\n return () => null;\n }\n\n // eslint-disable-next-line react/forbid-foreign-prop-types\n const prevPropTypes = Component ? _extends({}, Component.propTypes) : null;\n const requireProp = requiredProp => (props, propName, componentName, location, propFullName, ...args) => {\n const propFullNameSafe = propFullName || propName;\n const defaultTypeChecker = prevPropTypes == null ? void 0 : prevPropTypes[propFullNameSafe];\n if (defaultTypeChecker) {\n const typeCheckerResult = defaultTypeChecker(props, propName, componentName, location, propFullName, ...args);\n if (typeCheckerResult) {\n return typeCheckerResult;\n }\n }\n if (typeof props[propName] !== 'undefined' && !props[requiredProp]) {\n return new Error(`The prop \\`${propFullNameSafe}\\` of ` + `\\`${componentNameInError}\\` can only be used together with the \\`${requiredProp}\\` prop.`);\n }\n return null;\n };\n return requireProp;\n}","/**\n * TODO v5: consider making it private\n *\n * passes {value} to {ref}\n *\n * WARNING: Be sure to only call this inside a callback that is passed as a ref.\n * Otherwise, make sure to cleanup the previous {ref} if it changes. See\n * https://github.com/mui/material-ui/issues/13539\n *\n * Useful if you want to expose the ref of an inner component to the public API\n * while still using it inside the component.\n * @param ref A ref callback or ref object. If anything falsy, this is a no-op.\n */\nexport default function setRef(ref, value) {\n if (typeof ref === 'function') {\n ref(value);\n } else if (ref) {\n ref.current = value;\n }\n}","'use client';\n\nimport * as React from 'react';\n\n/**\n * A version of `React.useLayoutEffect` that does not show a warning when server-side rendering.\n * This is useful for effects that are only needed for client-side rendering but not for SSR.\n *\n * Before you use this hook, make sure to read https://gist.github.com/gaearon/e7d97cdf38a2907924ea12e4ebdf3c85\n * and confirm it doesn't apply to your use-case.\n */\nconst useEnhancedEffect = typeof window !== 'undefined' ? React.useLayoutEffect : React.useEffect;\nexport default useEnhancedEffect;","'use client';\n\nimport * as React from 'react';\nlet globalId = 0;\nfunction useGlobalId(idOverride) {\n const [defaultId, setDefaultId] = React.useState(idOverride);\n const id = idOverride || defaultId;\n React.useEffect(() => {\n if (defaultId == null) {\n // Fallback to this default id when possible.\n // Use the incrementing value for client-side rendering only.\n // We can't use it server-side.\n // If you want to use random values please consider the Birthday Problem: https://en.wikipedia.org/wiki/Birthday_problem\n globalId += 1;\n setDefaultId(`mui-${globalId}`);\n }\n }, [defaultId]);\n return id;\n}\n\n// downstream bundlers may remove unnecessary concatenation, but won't remove toString call -- Workaround for https://github.com/webpack/webpack/issues/14814\nconst maybeReactUseId = React['useId'.toString()];\n/**\n *\n * @example
    \n * @param idOverride\n * @returns {string}\n */\nexport default function useId(idOverride) {\n if (maybeReactUseId !== undefined) {\n const reactId = maybeReactUseId();\n return idOverride != null ? idOverride : reactId;\n }\n // eslint-disable-next-line react-hooks/rules-of-hooks -- `React.useId` is invariant at runtime.\n return useGlobalId(idOverride);\n}","export default function unsupportedProp(props, propName, componentName, location, propFullName) {\n if (process.env.NODE_ENV === 'production') {\n return null;\n }\n const propFullNameSafe = propFullName || propName;\n if (typeof props[propName] !== 'undefined') {\n return new Error(`The prop \\`${propFullNameSafe}\\` is not supported. Please remove it.`);\n }\n return null;\n}","'use client';\n\n/* eslint-disable react-hooks/rules-of-hooks, react-hooks/exhaustive-deps */\nimport * as React from 'react';\nexport default function useControlled({\n controlled,\n default: defaultProp,\n name,\n state = 'value'\n}) {\n // isControlled is ignored in the hook dependency lists as it should never change.\n const {\n current: isControlled\n } = React.useRef(controlled !== undefined);\n const [valueState, setValue] = React.useState(defaultProp);\n const value = isControlled ? controlled : valueState;\n if (process.env.NODE_ENV !== 'production') {\n React.useEffect(() => {\n if (isControlled !== (controlled !== undefined)) {\n console.error([`MUI: A component is changing the ${isControlled ? '' : 'un'}controlled ${state} state of ${name} to be ${isControlled ? 'un' : ''}controlled.`, 'Elements should not switch from uncontrolled to controlled (or vice versa).', `Decide between using a controlled or uncontrolled ${name} ` + 'element for the lifetime of the component.', \"The nature of the state is determined during the first render. It's considered controlled if the value is not `undefined`.\", 'More info: https://fb.me/react-controlled-components'].join('\\n'));\n }\n }, [state, name, controlled]);\n const {\n current: defaultValue\n } = React.useRef(defaultProp);\n React.useEffect(() => {\n if (!isControlled && defaultValue !== defaultProp) {\n console.error([`MUI: A component is changing the default ${state} state of an uncontrolled ${name} after being initialized. ` + `To suppress this warning opt to use a controlled ${name}.`].join('\\n'));\n }\n }, [JSON.stringify(defaultProp)]);\n }\n const setValueIfUncontrolled = React.useCallback(newValue => {\n if (!isControlled) {\n setValue(newValue);\n }\n }, []);\n return [value, setValueIfUncontrolled];\n}","'use client';\n\nimport * as React from 'react';\nimport useEnhancedEffect from '../useEnhancedEffect';\n\n/**\n * Inspired by https://github.com/facebook/react/issues/14099#issuecomment-440013892\n * See RFC in https://github.com/reactjs/rfcs/pull/220\n */\n\nfunction useEventCallback(fn) {\n const ref = React.useRef(fn);\n useEnhancedEffect(() => {\n ref.current = fn;\n });\n return React.useRef((...args) =>\n // @ts-expect-error hide `this`\n (0, ref.current)(...args)).current;\n}\nexport default useEventCallback;","'use client';\n\nimport * as React from 'react';\nimport setRef from '../setRef';\nexport default function useForkRef(...refs) {\n /**\n * This will create a new function if the refs passed to this hook change and are all defined.\n * This means react will call the old forkRef with `null` and the new forkRef\n * with the ref. Cleanup naturally emerges from this behavior.\n */\n return React.useMemo(() => {\n if (refs.every(ref => ref == null)) {\n return null;\n }\n return instance => {\n refs.forEach(ref => {\n setRef(ref, instance);\n });\n };\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, refs);\n}","'use client';\n\nimport * as React from 'react';\nconst UNINITIALIZED = {};\n\n/**\n * A React.useRef() that is initialized lazily with a function. Note that it accepts an optional\n * initialization argument, so the initialization function doesn't need to be an inline closure.\n *\n * @usage\n * const ref = useLazyRef(sortColumns, columns)\n */\nexport default function useLazyRef(init, initArg) {\n const ref = React.useRef(UNINITIALIZED);\n if (ref.current === UNINITIALIZED) {\n ref.current = init(initArg);\n }\n return ref;\n}","'use client';\n\nimport * as React from 'react';\nconst EMPTY = [];\n\n/**\n * A React.useEffect equivalent that runs once, when the component is mounted.\n */\nexport default function useOnMount(fn) {\n /* eslint-disable react-hooks/exhaustive-deps */\n React.useEffect(fn, EMPTY);\n /* eslint-enable react-hooks/exhaustive-deps */\n}","'use client';\n\nimport useLazyRef from '../useLazyRef/useLazyRef';\nimport useOnMount from '../useOnMount/useOnMount';\nexport class Timeout {\n constructor() {\n this.currentId = null;\n this.clear = () => {\n if (this.currentId !== null) {\n clearTimeout(this.currentId);\n this.currentId = null;\n }\n };\n this.disposeEffect = () => {\n return this.clear;\n };\n }\n static create() {\n return new Timeout();\n }\n /**\n * Executes `fn` after `delay`, clearing any previously scheduled call.\n */\n start(delay, fn) {\n this.clear();\n this.currentId = setTimeout(() => {\n this.currentId = null;\n fn();\n }, delay);\n }\n}\nexport default function useTimeout() {\n const timeout = useLazyRef(Timeout.create).current;\n useOnMount(timeout.disposeEffect);\n return timeout;\n}","'use client';\n\n// based on https://github.com/WICG/focus-visible/blob/v4.1.5/src/focus-visible.js\nimport * as React from 'react';\nimport { Timeout } from '../useTimeout/useTimeout';\nlet hadKeyboardEvent = true;\nlet hadFocusVisibleRecently = false;\nconst hadFocusVisibleRecentlyTimeout = new Timeout();\nconst inputTypesWhitelist = {\n text: true,\n search: true,\n url: true,\n tel: true,\n email: true,\n password: true,\n number: true,\n date: true,\n month: true,\n week: true,\n time: true,\n datetime: true,\n 'datetime-local': true\n};\n\n/**\n * Computes whether the given element should automatically trigger the\n * `focus-visible` class being added, i.e. whether it should always match\n * `:focus-visible` when focused.\n * @param {Element} node\n * @returns {boolean}\n */\nfunction focusTriggersKeyboardModality(node) {\n const {\n type,\n tagName\n } = node;\n if (tagName === 'INPUT' && inputTypesWhitelist[type] && !node.readOnly) {\n return true;\n }\n if (tagName === 'TEXTAREA' && !node.readOnly) {\n return true;\n }\n if (node.isContentEditable) {\n return true;\n }\n return false;\n}\n\n/**\n * Keep track of our keyboard modality state with `hadKeyboardEvent`.\n * If the most recent user interaction was via the keyboard;\n * and the key press did not include a meta, alt/option, or control key;\n * then the modality is keyboard. Otherwise, the modality is not keyboard.\n * @param {KeyboardEvent} event\n */\nfunction handleKeyDown(event) {\n if (event.metaKey || event.altKey || event.ctrlKey) {\n return;\n }\n hadKeyboardEvent = true;\n}\n\n/**\n * If at any point a user clicks with a pointing device, ensure that we change\n * the modality away from keyboard.\n * This avoids the situation where a user presses a key on an already focused\n * element, and then clicks on a different element, focusing it with a\n * pointing device, while we still think we're in keyboard modality.\n */\nfunction handlePointerDown() {\n hadKeyboardEvent = false;\n}\nfunction handleVisibilityChange() {\n if (this.visibilityState === 'hidden') {\n // If the tab becomes active again, the browser will handle calling focus\n // on the element (Safari actually calls it twice).\n // If this tab change caused a blur on an element with focus-visible,\n // re-apply the class when the user switches back to the tab.\n if (hadFocusVisibleRecently) {\n hadKeyboardEvent = true;\n }\n }\n}\nfunction prepare(doc) {\n doc.addEventListener('keydown', handleKeyDown, true);\n doc.addEventListener('mousedown', handlePointerDown, true);\n doc.addEventListener('pointerdown', handlePointerDown, true);\n doc.addEventListener('touchstart', handlePointerDown, true);\n doc.addEventListener('visibilitychange', handleVisibilityChange, true);\n}\nexport function teardown(doc) {\n doc.removeEventListener('keydown', handleKeyDown, true);\n doc.removeEventListener('mousedown', handlePointerDown, true);\n doc.removeEventListener('pointerdown', handlePointerDown, true);\n doc.removeEventListener('touchstart', handlePointerDown, true);\n doc.removeEventListener('visibilitychange', handleVisibilityChange, true);\n}\nfunction isFocusVisible(event) {\n const {\n target\n } = event;\n try {\n return target.matches(':focus-visible');\n } catch (error) {\n // Browsers not implementing :focus-visible will throw a SyntaxError.\n // We use our own heuristic for those browsers.\n // Rethrow might be better if it's not the expected error but do we really\n // want to crash if focus-visible malfunctioned?\n }\n\n // No need for validFocusTarget check. The user does that by attaching it to\n // focusable events only.\n return hadKeyboardEvent || focusTriggersKeyboardModality(target);\n}\nexport default function useIsFocusVisible() {\n const ref = React.useCallback(node => {\n if (node != null) {\n prepare(node.ownerDocument);\n }\n }, []);\n const isFocusVisibleRef = React.useRef(false);\n\n /**\n * Should be called if a blur event is fired\n */\n function handleBlurVisible() {\n // checking against potential state variable does not suffice if we focus and blur synchronously.\n // React wouldn't have time to trigger a re-render so `focusVisible` would be stale.\n // Ideally we would adjust `isFocusVisible(event)` to look at `relatedTarget` for blur events.\n // This doesn't work in IE11 due to https://github.com/facebook/react/issues/3751\n // TODO: check again if React releases their internal changes to focus event handling (https://github.com/facebook/react/pull/19186).\n if (isFocusVisibleRef.current) {\n // To detect a tab/window switch, we look for a blur event followed\n // rapidly by a visibility change.\n // If we don't see a visibility change within 100ms, it's probably a\n // regular focus change.\n hadFocusVisibleRecently = true;\n hadFocusVisibleRecentlyTimeout.start(100, () => {\n hadFocusVisibleRecently = false;\n });\n isFocusVisibleRef.current = false;\n return true;\n }\n return false;\n }\n\n /**\n * Should be called if a blur event is fired\n */\n function handleFocusVisible(event) {\n if (isFocusVisible(event)) {\n isFocusVisibleRef.current = true;\n return true;\n }\n return false;\n }\n return {\n isFocusVisibleRef,\n onFocus: handleFocusVisible,\n onBlur: handleBlurVisible,\n ref\n };\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\n/**\n * Add keys, values of `defaultProps` that does not exist in `props`\n * @param {object} defaultProps\n * @param {object} props\n * @returns {object} resolved props\n */\nexport default function resolveProps(defaultProps, props) {\n const output = _extends({}, props);\n Object.keys(defaultProps).forEach(propName => {\n if (propName.toString().match(/^(components|slots)$/)) {\n output[propName] = _extends({}, defaultProps[propName], output[propName]);\n } else if (propName.toString().match(/^(componentsProps|slotProps)$/)) {\n const defaultSlotProps = defaultProps[propName] || {};\n const slotProps = props[propName];\n output[propName] = {};\n if (!slotProps || !Object.keys(slotProps)) {\n // Reduce the iteration if the slot props is empty\n output[propName] = defaultSlotProps;\n } else if (!defaultSlotProps || !Object.keys(defaultSlotProps)) {\n // Reduce the iteration if the default slot props is empty\n output[propName] = slotProps;\n } else {\n output[propName] = _extends({}, slotProps);\n Object.keys(defaultSlotProps).forEach(slotPropName => {\n output[propName][slotPropName] = resolveProps(defaultSlotProps[slotPropName], slotProps[slotPropName]);\n });\n }\n } else if (output[propName] === undefined) {\n output[propName] = defaultProps[propName];\n }\n });\n return output;\n}","export default function composeClasses(slots, getUtilityClass, classes = undefined) {\n const output = {};\n Object.keys(slots).forEach(\n // `Object.keys(slots)` can't be wider than `T` because we infer `T` from `slots`.\n // @ts-expect-error https://github.com/microsoft/TypeScript/pull/12253#issuecomment-263132208\n slot => {\n output[slot] = slots[slot].reduce((acc, key) => {\n if (key) {\n const utilityClass = getUtilityClass(key);\n if (utilityClass !== '') {\n acc.push(utilityClass);\n }\n if (classes && classes[key]) {\n acc.push(classes[key]);\n }\n }\n return acc;\n }, []).join(' ');\n });\n return output;\n}","const defaultGenerator = componentName => componentName;\nconst createClassNameGenerator = () => {\n let generate = defaultGenerator;\n return {\n configure(generator) {\n generate = generator;\n },\n generate(componentName) {\n return generate(componentName);\n },\n reset() {\n generate = defaultGenerator;\n }\n };\n};\nconst ClassNameGenerator = createClassNameGenerator();\nexport default ClassNameGenerator;","import ClassNameGenerator from '../ClassNameGenerator';\nexport const globalStateClasses = {\n active: 'active',\n checked: 'checked',\n completed: 'completed',\n disabled: 'disabled',\n error: 'error',\n expanded: 'expanded',\n focused: 'focused',\n focusVisible: 'focusVisible',\n open: 'open',\n readOnly: 'readOnly',\n required: 'required',\n selected: 'selected'\n};\nexport default function generateUtilityClass(componentName, slot, globalStatePrefix = 'Mui') {\n const globalStateClass = globalStateClasses[slot];\n return globalStateClass ? `${globalStatePrefix}-${globalStateClass}` : `${ClassNameGenerator.generate(componentName)}-${slot}`;\n}\nexport function isGlobalState(slot) {\n return globalStateClasses[slot] !== undefined;\n}","import generateUtilityClass from '../generateUtilityClass';\nexport default function generateUtilityClasses(componentName, slots, globalStatePrefix = 'Mui') {\n const result = {};\n slots.forEach(slot => {\n result[slot] = generateUtilityClass(componentName, slot, globalStatePrefix);\n });\n return result;\n}","function clamp(val, min = Number.MIN_SAFE_INTEGER, max = Number.MAX_SAFE_INTEGER) {\n return Math.max(min, Math.min(val, max));\n}\nexport default clamp;","export default function _objectWithoutPropertiesLoose(source, excluded) {\n if (source == null) return {};\n var target = {};\n var sourceKeys = Object.keys(source);\n var key, i;\n for (i = 0; i < sourceKeys.length; i++) {\n key = sourceKeys[i];\n if (excluded.indexOf(key) >= 0) continue;\n target[key] = source[key];\n }\n return target;\n}","import _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nconst _excluded = [\"values\", \"unit\", \"step\"];\n// Sorted ASC by size. That's important.\n// It can't be configured as it's used statically for propTypes.\nexport const breakpointKeys = ['xs', 'sm', 'md', 'lg', 'xl'];\nconst sortBreakpointsValues = values => {\n const breakpointsAsArray = Object.keys(values).map(key => ({\n key,\n val: values[key]\n })) || [];\n // Sort in ascending order\n breakpointsAsArray.sort((breakpoint1, breakpoint2) => breakpoint1.val - breakpoint2.val);\n return breakpointsAsArray.reduce((acc, obj) => {\n return _extends({}, acc, {\n [obj.key]: obj.val\n });\n }, {});\n};\n\n// Keep in mind that @media is inclusive by the CSS specification.\nexport default function createBreakpoints(breakpoints) {\n const {\n // The breakpoint **start** at this value.\n // For instance with the first breakpoint xs: [xs, sm).\n values = {\n xs: 0,\n // phone\n sm: 600,\n // tablet\n md: 900,\n // small laptop\n lg: 1200,\n // desktop\n xl: 1536 // large screen\n },\n unit = 'px',\n step = 5\n } = breakpoints,\n other = _objectWithoutPropertiesLoose(breakpoints, _excluded);\n const sortedValues = sortBreakpointsValues(values);\n const keys = Object.keys(sortedValues);\n function up(key) {\n const value = typeof values[key] === 'number' ? values[key] : key;\n return `@media (min-width:${value}${unit})`;\n }\n function down(key) {\n const value = typeof values[key] === 'number' ? values[key] : key;\n return `@media (max-width:${value - step / 100}${unit})`;\n }\n function between(start, end) {\n const endIndex = keys.indexOf(end);\n return `@media (min-width:${typeof values[start] === 'number' ? values[start] : start}${unit}) and ` + `(max-width:${(endIndex !== -1 && typeof values[keys[endIndex]] === 'number' ? values[keys[endIndex]] : end) - step / 100}${unit})`;\n }\n function only(key) {\n if (keys.indexOf(key) + 1 < keys.length) {\n return between(key, keys[keys.indexOf(key) + 1]);\n }\n return up(key);\n }\n function not(key) {\n // handle first and last key separately, for better readability\n const keyIndex = keys.indexOf(key);\n if (keyIndex === 0) {\n return up(keys[1]);\n }\n if (keyIndex === keys.length - 1) {\n return down(keys[keyIndex]);\n }\n return between(key, keys[keys.indexOf(key) + 1]).replace('@media', '@media not all and');\n }\n return _extends({\n keys,\n values: sortedValues,\n up,\n down,\n between,\n only,\n not,\n unit\n }, other);\n}","const shape = {\n borderRadius: 4\n};\nexport default shape;","import PropTypes from 'prop-types';\nconst responsivePropType = process.env.NODE_ENV !== 'production' ? PropTypes.oneOfType([PropTypes.number, PropTypes.string, PropTypes.object, PropTypes.array]) : {};\nexport default responsivePropType;","import deepmerge from '@mui/utils/deepmerge';\nfunction merge(acc, item) {\n if (!item) {\n return acc;\n }\n return deepmerge(acc, item, {\n clone: false // No need to clone deep, it's way faster.\n });\n}\nexport default merge;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport PropTypes from 'prop-types';\nimport deepmerge from '@mui/utils/deepmerge';\nimport merge from './merge';\n\n// The breakpoint **start** at this value.\n// For instance with the first breakpoint xs: [xs, sm[.\nexport const values = {\n xs: 0,\n // phone\n sm: 600,\n // tablet\n md: 900,\n // small laptop\n lg: 1200,\n // desktop\n xl: 1536 // large screen\n};\nconst defaultBreakpoints = {\n // Sorted ASC by size. That's important.\n // It can't be configured as it's used statically for propTypes.\n keys: ['xs', 'sm', 'md', 'lg', 'xl'],\n up: key => `@media (min-width:${values[key]}px)`\n};\nexport function handleBreakpoints(props, propValue, styleFromPropValue) {\n const theme = props.theme || {};\n if (Array.isArray(propValue)) {\n const themeBreakpoints = theme.breakpoints || defaultBreakpoints;\n return propValue.reduce((acc, item, index) => {\n acc[themeBreakpoints.up(themeBreakpoints.keys[index])] = styleFromPropValue(propValue[index]);\n return acc;\n }, {});\n }\n if (typeof propValue === 'object') {\n const themeBreakpoints = theme.breakpoints || defaultBreakpoints;\n return Object.keys(propValue).reduce((acc, breakpoint) => {\n // key is breakpoint\n if (Object.keys(themeBreakpoints.values || values).indexOf(breakpoint) !== -1) {\n const mediaKey = themeBreakpoints.up(breakpoint);\n acc[mediaKey] = styleFromPropValue(propValue[breakpoint], breakpoint);\n } else {\n const cssKey = breakpoint;\n acc[cssKey] = propValue[cssKey];\n }\n return acc;\n }, {});\n }\n const output = styleFromPropValue(propValue);\n return output;\n}\nfunction breakpoints(styleFunction) {\n // false positive\n // eslint-disable-next-line react/function-component-definition\n const newStyleFunction = props => {\n const theme = props.theme || {};\n const base = styleFunction(props);\n const themeBreakpoints = theme.breakpoints || defaultBreakpoints;\n const extended = themeBreakpoints.keys.reduce((acc, key) => {\n if (props[key]) {\n acc = acc || {};\n acc[themeBreakpoints.up(key)] = styleFunction(_extends({\n theme\n }, props[key]));\n }\n return acc;\n }, null);\n return merge(base, extended);\n };\n newStyleFunction.propTypes = process.env.NODE_ENV !== 'production' ? _extends({}, styleFunction.propTypes, {\n xs: PropTypes.object,\n sm: PropTypes.object,\n md: PropTypes.object,\n lg: PropTypes.object,\n xl: PropTypes.object\n }) : {};\n newStyleFunction.filterProps = ['xs', 'sm', 'md', 'lg', 'xl', ...styleFunction.filterProps];\n return newStyleFunction;\n}\nexport function createEmptyBreakpointObject(breakpointsInput = {}) {\n var _breakpointsInput$key;\n const breakpointsInOrder = (_breakpointsInput$key = breakpointsInput.keys) == null ? void 0 : _breakpointsInput$key.reduce((acc, key) => {\n const breakpointStyleKey = breakpointsInput.up(key);\n acc[breakpointStyleKey] = {};\n return acc;\n }, {});\n return breakpointsInOrder || {};\n}\nexport function removeUnusedBreakpoints(breakpointKeys, style) {\n return breakpointKeys.reduce((acc, key) => {\n const breakpointOutput = acc[key];\n const isBreakpointUnused = !breakpointOutput || Object.keys(breakpointOutput).length === 0;\n if (isBreakpointUnused) {\n delete acc[key];\n }\n return acc;\n }, style);\n}\nexport function mergeBreakpointsInOrder(breakpointsInput, ...styles) {\n const emptyBreakpoints = createEmptyBreakpointObject(breakpointsInput);\n const mergedOutput = [emptyBreakpoints, ...styles].reduce((prev, next) => deepmerge(prev, next), {});\n return removeUnusedBreakpoints(Object.keys(emptyBreakpoints), mergedOutput);\n}\n\n// compute base for responsive values; e.g.,\n// [1,2,3] => {xs: true, sm: true, md: true}\n// {xs: 1, sm: 2, md: 3} => {xs: true, sm: true, md: true}\nexport function computeBreakpointsBase(breakpointValues, themeBreakpoints) {\n // fixed value\n if (typeof breakpointValues !== 'object') {\n return {};\n }\n const base = {};\n const breakpointsKeys = Object.keys(themeBreakpoints);\n if (Array.isArray(breakpointValues)) {\n breakpointsKeys.forEach((breakpoint, i) => {\n if (i < breakpointValues.length) {\n base[breakpoint] = true;\n }\n });\n } else {\n breakpointsKeys.forEach(breakpoint => {\n if (breakpointValues[breakpoint] != null) {\n base[breakpoint] = true;\n }\n });\n }\n return base;\n}\nexport function resolveBreakpointValues({\n values: breakpointValues,\n breakpoints: themeBreakpoints,\n base: customBase\n}) {\n const base = customBase || computeBreakpointsBase(breakpointValues, themeBreakpoints);\n const keys = Object.keys(base);\n if (keys.length === 0) {\n return breakpointValues;\n }\n let previous;\n return keys.reduce((acc, breakpoint, i) => {\n if (Array.isArray(breakpointValues)) {\n acc[breakpoint] = breakpointValues[i] != null ? breakpointValues[i] : breakpointValues[previous];\n previous = i;\n } else if (typeof breakpointValues === 'object') {\n acc[breakpoint] = breakpointValues[breakpoint] != null ? breakpointValues[breakpoint] : breakpointValues[previous];\n previous = breakpoint;\n } else {\n acc[breakpoint] = breakpointValues;\n }\n return acc;\n }, {});\n}\nexport default breakpoints;","import capitalize from '@mui/utils/capitalize';\nimport responsivePropType from './responsivePropType';\nimport { handleBreakpoints } from './breakpoints';\nexport function getPath(obj, path, checkVars = true) {\n if (!path || typeof path !== 'string') {\n return null;\n }\n\n // Check if CSS variables are used\n if (obj && obj.vars && checkVars) {\n const val = `vars.${path}`.split('.').reduce((acc, item) => acc && acc[item] ? acc[item] : null, obj);\n if (val != null) {\n return val;\n }\n }\n return path.split('.').reduce((acc, item) => {\n if (acc && acc[item] != null) {\n return acc[item];\n }\n return null;\n }, obj);\n}\nexport function getStyleValue(themeMapping, transform, propValueFinal, userValue = propValueFinal) {\n let value;\n if (typeof themeMapping === 'function') {\n value = themeMapping(propValueFinal);\n } else if (Array.isArray(themeMapping)) {\n value = themeMapping[propValueFinal] || userValue;\n } else {\n value = getPath(themeMapping, propValueFinal) || userValue;\n }\n if (transform) {\n value = transform(value, userValue, themeMapping);\n }\n return value;\n}\nfunction style(options) {\n const {\n prop,\n cssProperty = options.prop,\n themeKey,\n transform\n } = options;\n\n // false positive\n // eslint-disable-next-line react/function-component-definition\n const fn = props => {\n if (props[prop] == null) {\n return null;\n }\n const propValue = props[prop];\n const theme = props.theme;\n const themeMapping = getPath(theme, themeKey) || {};\n const styleFromPropValue = propValueFinal => {\n let value = getStyleValue(themeMapping, transform, propValueFinal);\n if (propValueFinal === value && typeof propValueFinal === 'string') {\n // Haven't found value\n value = getStyleValue(themeMapping, transform, `${prop}${propValueFinal === 'default' ? '' : capitalize(propValueFinal)}`, propValueFinal);\n }\n if (cssProperty === false) {\n return value;\n }\n return {\n [cssProperty]: value\n };\n };\n return handleBreakpoints(props, propValue, styleFromPropValue);\n };\n fn.propTypes = process.env.NODE_ENV !== 'production' ? {\n [prop]: responsivePropType\n } : {};\n fn.filterProps = [prop];\n return fn;\n}\nexport default style;","export default function memoize(fn) {\n const cache = {};\n return arg => {\n if (cache[arg] === undefined) {\n cache[arg] = fn(arg);\n }\n return cache[arg];\n };\n}","import responsivePropType from './responsivePropType';\nimport { handleBreakpoints } from './breakpoints';\nimport { getPath } from './style';\nimport merge from './merge';\nimport memoize from './memoize';\nconst properties = {\n m: 'margin',\n p: 'padding'\n};\nconst directions = {\n t: 'Top',\n r: 'Right',\n b: 'Bottom',\n l: 'Left',\n x: ['Left', 'Right'],\n y: ['Top', 'Bottom']\n};\nconst aliases = {\n marginX: 'mx',\n marginY: 'my',\n paddingX: 'px',\n paddingY: 'py'\n};\n\n// memoize() impact:\n// From 300,000 ops/sec\n// To 350,000 ops/sec\nconst getCssProperties = memoize(prop => {\n // It's not a shorthand notation.\n if (prop.length > 2) {\n if (aliases[prop]) {\n prop = aliases[prop];\n } else {\n return [prop];\n }\n }\n const [a, b] = prop.split('');\n const property = properties[a];\n const direction = directions[b] || '';\n return Array.isArray(direction) ? direction.map(dir => property + dir) : [property + direction];\n});\nexport const marginKeys = ['m', 'mt', 'mr', 'mb', 'ml', 'mx', 'my', 'margin', 'marginTop', 'marginRight', 'marginBottom', 'marginLeft', 'marginX', 'marginY', 'marginInline', 'marginInlineStart', 'marginInlineEnd', 'marginBlock', 'marginBlockStart', 'marginBlockEnd'];\nexport const paddingKeys = ['p', 'pt', 'pr', 'pb', 'pl', 'px', 'py', 'padding', 'paddingTop', 'paddingRight', 'paddingBottom', 'paddingLeft', 'paddingX', 'paddingY', 'paddingInline', 'paddingInlineStart', 'paddingInlineEnd', 'paddingBlock', 'paddingBlockStart', 'paddingBlockEnd'];\nconst spacingKeys = [...marginKeys, ...paddingKeys];\nexport function createUnaryUnit(theme, themeKey, defaultValue, propName) {\n var _getPath;\n const themeSpacing = (_getPath = getPath(theme, themeKey, false)) != null ? _getPath : defaultValue;\n if (typeof themeSpacing === 'number') {\n return abs => {\n if (typeof abs === 'string') {\n return abs;\n }\n if (process.env.NODE_ENV !== 'production') {\n if (typeof abs !== 'number') {\n console.error(`MUI: Expected ${propName} argument to be a number or a string, got ${abs}.`);\n }\n }\n return themeSpacing * abs;\n };\n }\n if (Array.isArray(themeSpacing)) {\n return abs => {\n if (typeof abs === 'string') {\n return abs;\n }\n if (process.env.NODE_ENV !== 'production') {\n if (!Number.isInteger(abs)) {\n console.error([`MUI: The \\`theme.${themeKey}\\` array type cannot be combined with non integer values.` + `You should either use an integer value that can be used as index, or define the \\`theme.${themeKey}\\` as a number.`].join('\\n'));\n } else if (abs > themeSpacing.length - 1) {\n console.error([`MUI: The value provided (${abs}) overflows.`, `The supported values are: ${JSON.stringify(themeSpacing)}.`, `${abs} > ${themeSpacing.length - 1}, you need to add the missing values.`].join('\\n'));\n }\n }\n return themeSpacing[abs];\n };\n }\n if (typeof themeSpacing === 'function') {\n return themeSpacing;\n }\n if (process.env.NODE_ENV !== 'production') {\n console.error([`MUI: The \\`theme.${themeKey}\\` value (${themeSpacing}) is invalid.`, 'It should be a number, an array or a function.'].join('\\n'));\n }\n return () => undefined;\n}\nexport function createUnarySpacing(theme) {\n return createUnaryUnit(theme, 'spacing', 8, 'spacing');\n}\nexport function getValue(transformer, propValue) {\n if (typeof propValue === 'string' || propValue == null) {\n return propValue;\n }\n const abs = Math.abs(propValue);\n const transformed = transformer(abs);\n if (propValue >= 0) {\n return transformed;\n }\n if (typeof transformed === 'number') {\n return -transformed;\n }\n return `-${transformed}`;\n}\nexport function getStyleFromPropValue(cssProperties, transformer) {\n return propValue => cssProperties.reduce((acc, cssProperty) => {\n acc[cssProperty] = getValue(transformer, propValue);\n return acc;\n }, {});\n}\nfunction resolveCssProperty(props, keys, prop, transformer) {\n // Using a hash computation over an array iteration could be faster, but with only 28 items,\n // it's doesn't worth the bundle size.\n if (keys.indexOf(prop) === -1) {\n return null;\n }\n const cssProperties = getCssProperties(prop);\n const styleFromPropValue = getStyleFromPropValue(cssProperties, transformer);\n const propValue = props[prop];\n return handleBreakpoints(props, propValue, styleFromPropValue);\n}\nfunction style(props, keys) {\n const transformer = createUnarySpacing(props.theme);\n return Object.keys(props).map(prop => resolveCssProperty(props, keys, prop, transformer)).reduce(merge, {});\n}\nexport function margin(props) {\n return style(props, marginKeys);\n}\nmargin.propTypes = process.env.NODE_ENV !== 'production' ? marginKeys.reduce((obj, key) => {\n obj[key] = responsivePropType;\n return obj;\n}, {}) : {};\nmargin.filterProps = marginKeys;\nexport function padding(props) {\n return style(props, paddingKeys);\n}\npadding.propTypes = process.env.NODE_ENV !== 'production' ? paddingKeys.reduce((obj, key) => {\n obj[key] = responsivePropType;\n return obj;\n}, {}) : {};\npadding.filterProps = paddingKeys;\nfunction spacing(props) {\n return style(props, spacingKeys);\n}\nspacing.propTypes = process.env.NODE_ENV !== 'production' ? spacingKeys.reduce((obj, key) => {\n obj[key] = responsivePropType;\n return obj;\n}, {}) : {};\nspacing.filterProps = spacingKeys;\nexport default spacing;","import { createUnarySpacing } from '../spacing';\n\n// The different signatures imply different meaning for their arguments that can't be expressed structurally.\n// We express the difference with variable names.\n\nexport default function createSpacing(spacingInput = 8) {\n // Already transformed.\n if (spacingInput.mui) {\n return spacingInput;\n }\n\n // Material Design layouts are visually balanced. Most measurements align to an 8dp grid, which aligns both spacing and the overall layout.\n // Smaller components, such as icons, can align to a 4dp grid.\n // https://m2.material.io/design/layout/understanding-layout.html\n const transform = createUnarySpacing({\n spacing: spacingInput\n });\n const spacing = (...argsInput) => {\n if (process.env.NODE_ENV !== 'production') {\n if (!(argsInput.length <= 4)) {\n console.error(`MUI: Too many arguments provided, expected between 0 and 4, got ${argsInput.length}`);\n }\n }\n const args = argsInput.length === 0 ? [1] : argsInput;\n return args.map(argument => {\n const output = transform(argument);\n return typeof output === 'number' ? `${output}px` : output;\n }).join(' ');\n };\n spacing.mui = true;\n return spacing;\n}","import merge from './merge';\nfunction compose(...styles) {\n const handlers = styles.reduce((acc, style) => {\n style.filterProps.forEach(prop => {\n acc[prop] = style;\n });\n return acc;\n }, {});\n\n // false positive\n // eslint-disable-next-line react/function-component-definition\n const fn = props => {\n return Object.keys(props).reduce((acc, prop) => {\n if (handlers[prop]) {\n return merge(acc, handlers[prop](props));\n }\n return acc;\n }, {});\n };\n fn.propTypes = process.env.NODE_ENV !== 'production' ? styles.reduce((acc, style) => Object.assign(acc, style.propTypes), {}) : {};\n fn.filterProps = styles.reduce((acc, style) => acc.concat(style.filterProps), []);\n return fn;\n}\nexport default compose;","import responsivePropType from './responsivePropType';\nimport style from './style';\nimport compose from './compose';\nimport { createUnaryUnit, getValue } from './spacing';\nimport { handleBreakpoints } from './breakpoints';\nexport function borderTransform(value) {\n if (typeof value !== 'number') {\n return value;\n }\n return `${value}px solid`;\n}\nfunction createBorderStyle(prop, transform) {\n return style({\n prop,\n themeKey: 'borders',\n transform\n });\n}\nexport const border = createBorderStyle('border', borderTransform);\nexport const borderTop = createBorderStyle('borderTop', borderTransform);\nexport const borderRight = createBorderStyle('borderRight', borderTransform);\nexport const borderBottom = createBorderStyle('borderBottom', borderTransform);\nexport const borderLeft = createBorderStyle('borderLeft', borderTransform);\nexport const borderColor = createBorderStyle('borderColor');\nexport const borderTopColor = createBorderStyle('borderTopColor');\nexport const borderRightColor = createBorderStyle('borderRightColor');\nexport const borderBottomColor = createBorderStyle('borderBottomColor');\nexport const borderLeftColor = createBorderStyle('borderLeftColor');\nexport const outline = createBorderStyle('outline', borderTransform);\nexport const outlineColor = createBorderStyle('outlineColor');\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const borderRadius = props => {\n if (props.borderRadius !== undefined && props.borderRadius !== null) {\n const transformer = createUnaryUnit(props.theme, 'shape.borderRadius', 4, 'borderRadius');\n const styleFromPropValue = propValue => ({\n borderRadius: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.borderRadius, styleFromPropValue);\n }\n return null;\n};\nborderRadius.propTypes = process.env.NODE_ENV !== 'production' ? {\n borderRadius: responsivePropType\n} : {};\nborderRadius.filterProps = ['borderRadius'];\nconst borders = compose(border, borderTop, borderRight, borderBottom, borderLeft, borderColor, borderTopColor, borderRightColor, borderBottomColor, borderLeftColor, borderRadius, outline, outlineColor);\nexport default borders;","import style from './style';\nimport compose from './compose';\nimport { createUnaryUnit, getValue } from './spacing';\nimport { handleBreakpoints } from './breakpoints';\nimport responsivePropType from './responsivePropType';\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const gap = props => {\n if (props.gap !== undefined && props.gap !== null) {\n const transformer = createUnaryUnit(props.theme, 'spacing', 8, 'gap');\n const styleFromPropValue = propValue => ({\n gap: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.gap, styleFromPropValue);\n }\n return null;\n};\ngap.propTypes = process.env.NODE_ENV !== 'production' ? {\n gap: responsivePropType\n} : {};\ngap.filterProps = ['gap'];\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const columnGap = props => {\n if (props.columnGap !== undefined && props.columnGap !== null) {\n const transformer = createUnaryUnit(props.theme, 'spacing', 8, 'columnGap');\n const styleFromPropValue = propValue => ({\n columnGap: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.columnGap, styleFromPropValue);\n }\n return null;\n};\ncolumnGap.propTypes = process.env.NODE_ENV !== 'production' ? {\n columnGap: responsivePropType\n} : {};\ncolumnGap.filterProps = ['columnGap'];\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const rowGap = props => {\n if (props.rowGap !== undefined && props.rowGap !== null) {\n const transformer = createUnaryUnit(props.theme, 'spacing', 8, 'rowGap');\n const styleFromPropValue = propValue => ({\n rowGap: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.rowGap, styleFromPropValue);\n }\n return null;\n};\nrowGap.propTypes = process.env.NODE_ENV !== 'production' ? {\n rowGap: responsivePropType\n} : {};\nrowGap.filterProps = ['rowGap'];\nexport const gridColumn = style({\n prop: 'gridColumn'\n});\nexport const gridRow = style({\n prop: 'gridRow'\n});\nexport const gridAutoFlow = style({\n prop: 'gridAutoFlow'\n});\nexport const gridAutoColumns = style({\n prop: 'gridAutoColumns'\n});\nexport const gridAutoRows = style({\n prop: 'gridAutoRows'\n});\nexport const gridTemplateColumns = style({\n prop: 'gridTemplateColumns'\n});\nexport const gridTemplateRows = style({\n prop: 'gridTemplateRows'\n});\nexport const gridTemplateAreas = style({\n prop: 'gridTemplateAreas'\n});\nexport const gridArea = style({\n prop: 'gridArea'\n});\nconst grid = compose(gap, columnGap, rowGap, gridColumn, gridRow, gridAutoFlow, gridAutoColumns, gridAutoRows, gridTemplateColumns, gridTemplateRows, gridTemplateAreas, gridArea);\nexport default grid;","import style from './style';\nimport compose from './compose';\nexport function paletteTransform(value, userValue) {\n if (userValue === 'grey') {\n return userValue;\n }\n return value;\n}\nexport const color = style({\n prop: 'color',\n themeKey: 'palette',\n transform: paletteTransform\n});\nexport const bgcolor = style({\n prop: 'bgcolor',\n cssProperty: 'backgroundColor',\n themeKey: 'palette',\n transform: paletteTransform\n});\nexport const backgroundColor = style({\n prop: 'backgroundColor',\n themeKey: 'palette',\n transform: paletteTransform\n});\nconst palette = compose(color, bgcolor, backgroundColor);\nexport default palette;","import style from './style';\nimport compose from './compose';\nimport { handleBreakpoints, values as breakpointsValues } from './breakpoints';\nexport function sizingTransform(value) {\n return value <= 1 && value !== 0 ? `${value * 100}%` : value;\n}\nexport const width = style({\n prop: 'width',\n transform: sizingTransform\n});\nexport const maxWidth = props => {\n if (props.maxWidth !== undefined && props.maxWidth !== null) {\n const styleFromPropValue = propValue => {\n var _props$theme, _props$theme2;\n const breakpoint = ((_props$theme = props.theme) == null || (_props$theme = _props$theme.breakpoints) == null || (_props$theme = _props$theme.values) == null ? void 0 : _props$theme[propValue]) || breakpointsValues[propValue];\n if (!breakpoint) {\n return {\n maxWidth: sizingTransform(propValue)\n };\n }\n if (((_props$theme2 = props.theme) == null || (_props$theme2 = _props$theme2.breakpoints) == null ? void 0 : _props$theme2.unit) !== 'px') {\n return {\n maxWidth: `${breakpoint}${props.theme.breakpoints.unit}`\n };\n }\n return {\n maxWidth: breakpoint\n };\n };\n return handleBreakpoints(props, props.maxWidth, styleFromPropValue);\n }\n return null;\n};\nmaxWidth.filterProps = ['maxWidth'];\nexport const minWidth = style({\n prop: 'minWidth',\n transform: sizingTransform\n});\nexport const height = style({\n prop: 'height',\n transform: sizingTransform\n});\nexport const maxHeight = style({\n prop: 'maxHeight',\n transform: sizingTransform\n});\nexport const minHeight = style({\n prop: 'minHeight',\n transform: sizingTransform\n});\nexport const sizeWidth = style({\n prop: 'size',\n cssProperty: 'width',\n transform: sizingTransform\n});\nexport const sizeHeight = style({\n prop: 'size',\n cssProperty: 'height',\n transform: sizingTransform\n});\nexport const boxSizing = style({\n prop: 'boxSizing'\n});\nconst sizing = compose(width, maxWidth, minWidth, height, maxHeight, minHeight, boxSizing);\nexport default sizing;","import { padding, margin } from '../spacing';\nimport { borderRadius, borderTransform } from '../borders';\nimport { gap, rowGap, columnGap } from '../cssGrid';\nimport { paletteTransform } from '../palette';\nimport { maxWidth, sizingTransform } from '../sizing';\nconst defaultSxConfig = {\n // borders\n border: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderTop: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderRight: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderBottom: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderLeft: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderColor: {\n themeKey: 'palette'\n },\n borderTopColor: {\n themeKey: 'palette'\n },\n borderRightColor: {\n themeKey: 'palette'\n },\n borderBottomColor: {\n themeKey: 'palette'\n },\n borderLeftColor: {\n themeKey: 'palette'\n },\n outline: {\n themeKey: 'borders',\n transform: borderTransform\n },\n outlineColor: {\n themeKey: 'palette'\n },\n borderRadius: {\n themeKey: 'shape.borderRadius',\n style: borderRadius\n },\n // palette\n color: {\n themeKey: 'palette',\n transform: paletteTransform\n },\n bgcolor: {\n themeKey: 'palette',\n cssProperty: 'backgroundColor',\n transform: paletteTransform\n },\n backgroundColor: {\n themeKey: 'palette',\n transform: paletteTransform\n },\n // spacing\n p: {\n style: padding\n },\n pt: {\n style: padding\n },\n pr: {\n style: padding\n },\n pb: {\n style: padding\n },\n pl: {\n style: padding\n },\n px: {\n style: padding\n },\n py: {\n style: padding\n },\n padding: {\n style: padding\n },\n paddingTop: {\n style: padding\n },\n paddingRight: {\n style: padding\n },\n paddingBottom: {\n style: padding\n },\n paddingLeft: {\n style: padding\n },\n paddingX: {\n style: padding\n },\n paddingY: {\n style: padding\n },\n paddingInline: {\n style: padding\n },\n paddingInlineStart: {\n style: padding\n },\n paddingInlineEnd: {\n style: padding\n },\n paddingBlock: {\n style: padding\n },\n paddingBlockStart: {\n style: padding\n },\n paddingBlockEnd: {\n style: padding\n },\n m: {\n style: margin\n },\n mt: {\n style: margin\n },\n mr: {\n style: margin\n },\n mb: {\n style: margin\n },\n ml: {\n style: margin\n },\n mx: {\n style: margin\n },\n my: {\n style: margin\n },\n margin: {\n style: margin\n },\n marginTop: {\n style: margin\n },\n marginRight: {\n style: margin\n },\n marginBottom: {\n style: margin\n },\n marginLeft: {\n style: margin\n },\n marginX: {\n style: margin\n },\n marginY: {\n style: margin\n },\n marginInline: {\n style: margin\n },\n marginInlineStart: {\n style: margin\n },\n marginInlineEnd: {\n style: margin\n },\n marginBlock: {\n style: margin\n },\n marginBlockStart: {\n style: margin\n },\n marginBlockEnd: {\n style: margin\n },\n // display\n displayPrint: {\n cssProperty: false,\n transform: value => ({\n '@media print': {\n display: value\n }\n })\n },\n display: {},\n overflow: {},\n textOverflow: {},\n visibility: {},\n whiteSpace: {},\n // flexbox\n flexBasis: {},\n flexDirection: {},\n flexWrap: {},\n justifyContent: {},\n alignItems: {},\n alignContent: {},\n order: {},\n flex: {},\n flexGrow: {},\n flexShrink: {},\n alignSelf: {},\n justifyItems: {},\n justifySelf: {},\n // grid\n gap: {\n style: gap\n },\n rowGap: {\n style: rowGap\n },\n columnGap: {\n style: columnGap\n },\n gridColumn: {},\n gridRow: {},\n gridAutoFlow: {},\n gridAutoColumns: {},\n gridAutoRows: {},\n gridTemplateColumns: {},\n gridTemplateRows: {},\n gridTemplateAreas: {},\n gridArea: {},\n // positions\n position: {},\n zIndex: {\n themeKey: 'zIndex'\n },\n top: {},\n right: {},\n bottom: {},\n left: {},\n // shadows\n boxShadow: {\n themeKey: 'shadows'\n },\n // sizing\n width: {\n transform: sizingTransform\n },\n maxWidth: {\n style: maxWidth\n },\n minWidth: {\n transform: sizingTransform\n },\n height: {\n transform: sizingTransform\n },\n maxHeight: {\n transform: sizingTransform\n },\n minHeight: {\n transform: sizingTransform\n },\n boxSizing: {},\n // typography\n fontFamily: {\n themeKey: 'typography'\n },\n fontSize: {\n themeKey: 'typography'\n },\n fontStyle: {\n themeKey: 'typography'\n },\n fontWeight: {\n themeKey: 'typography'\n },\n letterSpacing: {},\n textTransform: {},\n lineHeight: {},\n textAlign: {},\n typography: {\n cssProperty: false,\n themeKey: 'typography'\n }\n};\nexport default defaultSxConfig;","import capitalize from '@mui/utils/capitalize';\nimport merge from '../merge';\nimport { getPath, getStyleValue as getValue } from '../style';\nimport { handleBreakpoints, createEmptyBreakpointObject, removeUnusedBreakpoints } from '../breakpoints';\nimport defaultSxConfig from './defaultSxConfig';\nfunction objectsHaveSameKeys(...objects) {\n const allKeys = objects.reduce((keys, object) => keys.concat(Object.keys(object)), []);\n const union = new Set(allKeys);\n return objects.every(object => union.size === Object.keys(object).length);\n}\nfunction callIfFn(maybeFn, arg) {\n return typeof maybeFn === 'function' ? maybeFn(arg) : maybeFn;\n}\n\n// eslint-disable-next-line @typescript-eslint/naming-convention\nexport function unstable_createStyleFunctionSx() {\n function getThemeValue(prop, val, theme, config) {\n const props = {\n [prop]: val,\n theme\n };\n const options = config[prop];\n if (!options) {\n return {\n [prop]: val\n };\n }\n const {\n cssProperty = prop,\n themeKey,\n transform,\n style\n } = options;\n if (val == null) {\n return null;\n }\n\n // TODO v6: remove, see https://github.com/mui/material-ui/pull/38123\n if (themeKey === 'typography' && val === 'inherit') {\n return {\n [prop]: val\n };\n }\n const themeMapping = getPath(theme, themeKey) || {};\n if (style) {\n return style(props);\n }\n const styleFromPropValue = propValueFinal => {\n let value = getValue(themeMapping, transform, propValueFinal);\n if (propValueFinal === value && typeof propValueFinal === 'string') {\n // Haven't found value\n value = getValue(themeMapping, transform, `${prop}${propValueFinal === 'default' ? '' : capitalize(propValueFinal)}`, propValueFinal);\n }\n if (cssProperty === false) {\n return value;\n }\n return {\n [cssProperty]: value\n };\n };\n return handleBreakpoints(props, val, styleFromPropValue);\n }\n function styleFunctionSx(props) {\n var _theme$unstable_sxCon;\n const {\n sx,\n theme = {}\n } = props || {};\n if (!sx) {\n return null; // Emotion & styled-components will neglect null\n }\n const config = (_theme$unstable_sxCon = theme.unstable_sxConfig) != null ? _theme$unstable_sxCon : defaultSxConfig;\n\n /*\n * Receive `sxInput` as object or callback\n * and then recursively check keys & values to create media query object styles.\n * (the result will be used in `styled`)\n */\n function traverse(sxInput) {\n let sxObject = sxInput;\n if (typeof sxInput === 'function') {\n sxObject = sxInput(theme);\n } else if (typeof sxInput !== 'object') {\n // value\n return sxInput;\n }\n if (!sxObject) {\n return null;\n }\n const emptyBreakpoints = createEmptyBreakpointObject(theme.breakpoints);\n const breakpointsKeys = Object.keys(emptyBreakpoints);\n let css = emptyBreakpoints;\n Object.keys(sxObject).forEach(styleKey => {\n const value = callIfFn(sxObject[styleKey], theme);\n if (value !== null && value !== undefined) {\n if (typeof value === 'object') {\n if (config[styleKey]) {\n css = merge(css, getThemeValue(styleKey, value, theme, config));\n } else {\n const breakpointsValues = handleBreakpoints({\n theme\n }, value, x => ({\n [styleKey]: x\n }));\n if (objectsHaveSameKeys(breakpointsValues, value)) {\n css[styleKey] = styleFunctionSx({\n sx: value,\n theme\n });\n } else {\n css = merge(css, breakpointsValues);\n }\n }\n } else {\n css = merge(css, getThemeValue(styleKey, value, theme, config));\n }\n }\n });\n return removeUnusedBreakpoints(breakpointsKeys, css);\n }\n return Array.isArray(sx) ? sx.map(traverse) : traverse(sx);\n }\n return styleFunctionSx;\n}\nconst styleFunctionSx = unstable_createStyleFunctionSx();\nstyleFunctionSx.filterProps = ['sx'];\nexport default styleFunctionSx;","/**\n * A universal utility to style components with multiple color modes. Always use it from the theme object.\n * It works with:\n * - [Basic theme](https://mui.com/material-ui/customization/dark-mode/)\n * - [CSS theme variables](https://mui.com/material-ui/experimental-api/css-theme-variables/overview/)\n * - Zero-runtime engine\n *\n * Tips: Use an array over object spread and place `theme.applyStyles()` last.\n *\n * ✅ [{ background: '#e5e5e5' }, theme.applyStyles('dark', { background: '#1c1c1c' })]\n *\n * 🚫 { background: '#e5e5e5', ...theme.applyStyles('dark', { background: '#1c1c1c' })}\n *\n * @example\n * 1. using with `styled`:\n * ```jsx\n * const Component = styled('div')(({ theme }) => [\n * { background: '#e5e5e5' },\n * theme.applyStyles('dark', {\n * background: '#1c1c1c',\n * color: '#fff',\n * }),\n * ]);\n * ```\n *\n * @example\n * 2. using with `sx` prop:\n * ```jsx\n * [\n * { background: '#e5e5e5' },\n * theme.applyStyles('dark', {\n * background: '#1c1c1c',\n * color: '#fff',\n * }),\n * ]}\n * />\n * ```\n *\n * @example\n * 3. theming a component:\n * ```jsx\n * extendTheme({\n * components: {\n * MuiButton: {\n * styleOverrides: {\n * root: ({ theme }) => [\n * { background: '#e5e5e5' },\n * theme.applyStyles('dark', {\n * background: '#1c1c1c',\n * color: '#fff',\n * }),\n * ],\n * },\n * }\n * }\n * })\n *```\n */\nexport default function applyStyles(key, styles) {\n // @ts-expect-error this is 'any' type\n const theme = this;\n if (theme.vars && typeof theme.getColorSchemeSelector === 'function') {\n // If CssVarsProvider is used as a provider,\n // returns '* :where([data-mui-color-scheme=\"light|dark\"]) &'\n const selector = theme.getColorSchemeSelector(key).replace(/(\\[[^\\]]+\\])/, '*:where($1)');\n return {\n [selector]: styles\n };\n }\n if (theme.palette.mode === key) {\n return styles;\n }\n return {};\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"breakpoints\", \"palette\", \"spacing\", \"shape\"];\nimport deepmerge from '@mui/utils/deepmerge';\nimport createBreakpoints from './createBreakpoints';\nimport shape from './shape';\nimport createSpacing from './createSpacing';\nimport styleFunctionSx from '../styleFunctionSx/styleFunctionSx';\nimport defaultSxConfig from '../styleFunctionSx/defaultSxConfig';\nimport applyStyles from './applyStyles';\nfunction createTheme(options = {}, ...args) {\n const {\n breakpoints: breakpointsInput = {},\n palette: paletteInput = {},\n spacing: spacingInput,\n shape: shapeInput = {}\n } = options,\n other = _objectWithoutPropertiesLoose(options, _excluded);\n const breakpoints = createBreakpoints(breakpointsInput);\n const spacing = createSpacing(spacingInput);\n let muiTheme = deepmerge({\n breakpoints,\n direction: 'ltr',\n components: {},\n // Inject component definitions.\n palette: _extends({\n mode: 'light'\n }, paletteInput),\n spacing,\n shape: _extends({}, shape, shapeInput)\n }, other);\n muiTheme.applyStyles = applyStyles;\n muiTheme = args.reduce((acc, argument) => deepmerge(acc, argument), muiTheme);\n muiTheme.unstable_sxConfig = _extends({}, defaultSxConfig, other == null ? void 0 : other.unstable_sxConfig);\n muiTheme.unstable_sx = function sx(props) {\n return styleFunctionSx({\n sx: props,\n theme: this\n });\n };\n return muiTheme;\n}\nexport default createTheme;","'use client';\n\nimport * as React from 'react';\nimport { ThemeContext } from '@mui/styled-engine';\nfunction isObjectEmpty(obj) {\n return Object.keys(obj).length === 0;\n}\nfunction useTheme(defaultTheme = null) {\n const contextTheme = React.useContext(ThemeContext);\n return !contextTheme || isObjectEmpty(contextTheme) ? defaultTheme : contextTheme;\n}\nexport default useTheme;","'use client';\n\nimport createTheme from './createTheme';\nimport useThemeWithoutDefault from './useThemeWithoutDefault';\nexport const systemDefaultTheme = createTheme();\nfunction useTheme(defaultTheme = systemDefaultTheme) {\n return useThemeWithoutDefault(defaultTheme);\n}\nexport default useTheme;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"ownerState\"],\n _excluded2 = [\"variants\"],\n _excluded3 = [\"name\", \"slot\", \"skipVariantsResolver\", \"skipSx\", \"overridesResolver\"];\n/* eslint-disable no-underscore-dangle */\nimport styledEngineStyled, { internal_processStyles as processStyles } from '@mui/styled-engine';\nimport { isPlainObject } from '@mui/utils/deepmerge';\nimport capitalize from '@mui/utils/capitalize';\nimport getDisplayName from '@mui/utils/getDisplayName';\nimport createTheme from './createTheme';\nimport styleFunctionSx from './styleFunctionSx';\nfunction isEmpty(obj) {\n return Object.keys(obj).length === 0;\n}\n\n// https://github.com/emotion-js/emotion/blob/26ded6109fcd8ca9875cc2ce4564fee678a3f3c5/packages/styled/src/utils.js#L40\nfunction isStringTag(tag) {\n return typeof tag === 'string' &&\n // 96 is one less than the char code\n // for \"a\" so this is checking that\n // it's a lowercase character\n tag.charCodeAt(0) > 96;\n}\n\n// Update /system/styled/#api in case if this changes\nexport function shouldForwardProp(prop) {\n return prop !== 'ownerState' && prop !== 'theme' && prop !== 'sx' && prop !== 'as';\n}\nexport const systemDefaultTheme = createTheme();\nconst lowercaseFirstLetter = string => {\n if (!string) {\n return string;\n }\n return string.charAt(0).toLowerCase() + string.slice(1);\n};\nfunction resolveTheme({\n defaultTheme,\n theme,\n themeId\n}) {\n return isEmpty(theme) ? defaultTheme : theme[themeId] || theme;\n}\nfunction defaultOverridesResolver(slot) {\n if (!slot) {\n return null;\n }\n return (props, styles) => styles[slot];\n}\nfunction processStyleArg(callableStyle, _ref) {\n let {\n ownerState\n } = _ref,\n props = _objectWithoutPropertiesLoose(_ref, _excluded);\n const resolvedStylesArg = typeof callableStyle === 'function' ? callableStyle(_extends({\n ownerState\n }, props)) : callableStyle;\n if (Array.isArray(resolvedStylesArg)) {\n return resolvedStylesArg.flatMap(resolvedStyle => processStyleArg(resolvedStyle, _extends({\n ownerState\n }, props)));\n }\n if (!!resolvedStylesArg && typeof resolvedStylesArg === 'object' && Array.isArray(resolvedStylesArg.variants)) {\n const {\n variants = []\n } = resolvedStylesArg,\n otherStyles = _objectWithoutPropertiesLoose(resolvedStylesArg, _excluded2);\n let result = otherStyles;\n variants.forEach(variant => {\n let isMatch = true;\n if (typeof variant.props === 'function') {\n isMatch = variant.props(_extends({\n ownerState\n }, props, ownerState));\n } else {\n Object.keys(variant.props).forEach(key => {\n if ((ownerState == null ? void 0 : ownerState[key]) !== variant.props[key] && props[key] !== variant.props[key]) {\n isMatch = false;\n }\n });\n }\n if (isMatch) {\n if (!Array.isArray(result)) {\n result = [result];\n }\n result.push(typeof variant.style === 'function' ? variant.style(_extends({\n ownerState\n }, props, ownerState)) : variant.style);\n }\n });\n return result;\n }\n return resolvedStylesArg;\n}\nexport default function createStyled(input = {}) {\n const {\n themeId,\n defaultTheme = systemDefaultTheme,\n rootShouldForwardProp = shouldForwardProp,\n slotShouldForwardProp = shouldForwardProp\n } = input;\n const systemSx = props => {\n return styleFunctionSx(_extends({}, props, {\n theme: resolveTheme(_extends({}, props, {\n defaultTheme,\n themeId\n }))\n }));\n };\n systemSx.__mui_systemSx = true;\n return (tag, inputOptions = {}) => {\n // Filter out the `sx` style function from the previous styled component to prevent unnecessary styles generated by the composite components.\n processStyles(tag, styles => styles.filter(style => !(style != null && style.__mui_systemSx)));\n const {\n name: componentName,\n slot: componentSlot,\n skipVariantsResolver: inputSkipVariantsResolver,\n skipSx: inputSkipSx,\n // TODO v6: remove `lowercaseFirstLetter()` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n overridesResolver = defaultOverridesResolver(lowercaseFirstLetter(componentSlot))\n } = inputOptions,\n options = _objectWithoutPropertiesLoose(inputOptions, _excluded3);\n\n // if skipVariantsResolver option is defined, take the value, otherwise, true for root and false for other slots.\n const skipVariantsResolver = inputSkipVariantsResolver !== undefined ? inputSkipVariantsResolver :\n // TODO v6: remove `Root` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n componentSlot && componentSlot !== 'Root' && componentSlot !== 'root' || false;\n const skipSx = inputSkipSx || false;\n let label;\n if (process.env.NODE_ENV !== 'production') {\n if (componentName) {\n // TODO v6: remove `lowercaseFirstLetter()` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n label = `${componentName}-${lowercaseFirstLetter(componentSlot || 'Root')}`;\n }\n }\n let shouldForwardPropOption = shouldForwardProp;\n\n // TODO v6: remove `Root` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n if (componentSlot === 'Root' || componentSlot === 'root') {\n shouldForwardPropOption = rootShouldForwardProp;\n } else if (componentSlot) {\n // any other slot specified\n shouldForwardPropOption = slotShouldForwardProp;\n } else if (isStringTag(tag)) {\n // for string (html) tag, preserve the behavior in emotion & styled-components.\n shouldForwardPropOption = undefined;\n }\n const defaultStyledResolver = styledEngineStyled(tag, _extends({\n shouldForwardProp: shouldForwardPropOption,\n label\n }, options));\n const transformStyleArg = stylesArg => {\n // On the server Emotion doesn't use React.forwardRef for creating components, so the created\n // component stays as a function. This condition makes sure that we do not interpolate functions\n // which are basically components used as a selectors.\n if (typeof stylesArg === 'function' && stylesArg.__emotion_real !== stylesArg || isPlainObject(stylesArg)) {\n return props => processStyleArg(stylesArg, _extends({}, props, {\n theme: resolveTheme({\n theme: props.theme,\n defaultTheme,\n themeId\n })\n }));\n }\n return stylesArg;\n };\n const muiStyledResolver = (styleArg, ...expressions) => {\n let transformedStyleArg = transformStyleArg(styleArg);\n const expressionsWithDefaultTheme = expressions ? expressions.map(transformStyleArg) : [];\n if (componentName && overridesResolver) {\n expressionsWithDefaultTheme.push(props => {\n const theme = resolveTheme(_extends({}, props, {\n defaultTheme,\n themeId\n }));\n if (!theme.components || !theme.components[componentName] || !theme.components[componentName].styleOverrides) {\n return null;\n }\n const styleOverrides = theme.components[componentName].styleOverrides;\n const resolvedStyleOverrides = {};\n // TODO: v7 remove iteration and use `resolveStyleArg(styleOverrides[slot])` directly\n Object.entries(styleOverrides).forEach(([slotKey, slotStyle]) => {\n resolvedStyleOverrides[slotKey] = processStyleArg(slotStyle, _extends({}, props, {\n theme\n }));\n });\n return overridesResolver(props, resolvedStyleOverrides);\n });\n }\n if (componentName && !skipVariantsResolver) {\n expressionsWithDefaultTheme.push(props => {\n var _theme$components;\n const theme = resolveTheme(_extends({}, props, {\n defaultTheme,\n themeId\n }));\n const themeVariants = theme == null || (_theme$components = theme.components) == null || (_theme$components = _theme$components[componentName]) == null ? void 0 : _theme$components.variants;\n return processStyleArg({\n variants: themeVariants\n }, _extends({}, props, {\n theme\n }));\n });\n }\n if (!skipSx) {\n expressionsWithDefaultTheme.push(systemSx);\n }\n const numOfCustomFnsApplied = expressionsWithDefaultTheme.length - expressions.length;\n if (Array.isArray(styleArg) && numOfCustomFnsApplied > 0) {\n const placeholders = new Array(numOfCustomFnsApplied).fill('');\n // If the type is array, than we need to add placeholders in the template for the overrides, variants and the sx styles.\n transformedStyleArg = [...styleArg, ...placeholders];\n transformedStyleArg.raw = [...styleArg.raw, ...placeholders];\n }\n const Component = defaultStyledResolver(transformedStyleArg, ...expressionsWithDefaultTheme);\n if (process.env.NODE_ENV !== 'production') {\n let displayName;\n if (componentName) {\n displayName = `${componentName}${capitalize(componentSlot || '')}`;\n }\n if (displayName === undefined) {\n displayName = `Styled(${getDisplayName(tag)})`;\n }\n Component.displayName = displayName;\n }\n if (tag.muiName) {\n Component.muiName = tag.muiName;\n }\n return Component;\n };\n if (defaultStyledResolver.withConfig) {\n muiStyledResolver.withConfig = defaultStyledResolver.withConfig;\n }\n return muiStyledResolver;\n };\n}","import resolveProps from '@mui/utils/resolveProps';\nexport default function getThemeProps(params) {\n const {\n theme,\n name,\n props\n } = params;\n if (!theme || !theme.components || !theme.components[name] || !theme.components[name].defaultProps) {\n return props;\n }\n return resolveProps(theme.components[name].defaultProps, props);\n}","'use client';\n\nimport getThemeProps from './getThemeProps';\nimport useTheme from '../useTheme';\nexport default function useThemeProps({\n props,\n name,\n defaultTheme,\n themeId\n}) {\n let theme = useTheme(defaultTheme);\n if (themeId) {\n theme = theme[themeId] || theme;\n }\n const mergedProps = getThemeProps({\n theme,\n name,\n props\n });\n return mergedProps;\n}","import _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\n/* eslint-disable @typescript-eslint/naming-convention */\nimport clamp from '@mui/utils/clamp';\n/**\n * Returns a number whose value is limited to the given range.\n * @param {number} value The value to be clamped\n * @param {number} min The lower boundary of the output range\n * @param {number} max The upper boundary of the output range\n * @returns {number} A number in the range [min, max]\n */\nfunction clampWrapper(value, min = 0, max = 1) {\n if (process.env.NODE_ENV !== 'production') {\n if (value < min || value > max) {\n console.error(`MUI: The value provided ${value} is out of range [${min}, ${max}].`);\n }\n }\n return clamp(value, min, max);\n}\n\n/**\n * Converts a color from CSS hex format to CSS rgb format.\n * @param {string} color - Hex color, i.e. #nnn or #nnnnnn\n * @returns {string} A CSS rgb color string\n */\nexport function hexToRgb(color) {\n color = color.slice(1);\n const re = new RegExp(`.{1,${color.length >= 6 ? 2 : 1}}`, 'g');\n let colors = color.match(re);\n if (colors && colors[0].length === 1) {\n colors = colors.map(n => n + n);\n }\n return colors ? `rgb${colors.length === 4 ? 'a' : ''}(${colors.map((n, index) => {\n return index < 3 ? parseInt(n, 16) : Math.round(parseInt(n, 16) / 255 * 1000) / 1000;\n }).join(', ')})` : '';\n}\nfunction intToHex(int) {\n const hex = int.toString(16);\n return hex.length === 1 ? `0${hex}` : hex;\n}\n\n/**\n * Returns an object with the type and values of a color.\n *\n * Note: Does not support rgb % values.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @returns {object} - A MUI color object: {type: string, values: number[]}\n */\nexport function decomposeColor(color) {\n // Idempotent\n if (color.type) {\n return color;\n }\n if (color.charAt(0) === '#') {\n return decomposeColor(hexToRgb(color));\n }\n const marker = color.indexOf('(');\n const type = color.substring(0, marker);\n if (['rgb', 'rgba', 'hsl', 'hsla', 'color'].indexOf(type) === -1) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: Unsupported \\`${color}\\` color.\nThe following formats are supported: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color().` : _formatMuiErrorMessage(9, color));\n }\n let values = color.substring(marker + 1, color.length - 1);\n let colorSpace;\n if (type === 'color') {\n values = values.split(' ');\n colorSpace = values.shift();\n if (values.length === 4 && values[3].charAt(0) === '/') {\n values[3] = values[3].slice(1);\n }\n if (['srgb', 'display-p3', 'a98-rgb', 'prophoto-rgb', 'rec-2020'].indexOf(colorSpace) === -1) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: unsupported \\`${colorSpace}\\` color space.\nThe following color spaces are supported: srgb, display-p3, a98-rgb, prophoto-rgb, rec-2020.` : _formatMuiErrorMessage(10, colorSpace));\n }\n } else {\n values = values.split(',');\n }\n values = values.map(value => parseFloat(value));\n return {\n type,\n values,\n colorSpace\n };\n}\n\n/**\n * Returns a channel created from the input color.\n *\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @returns {string} - The channel for the color, that can be used in rgba or hsla colors\n */\nexport const colorChannel = color => {\n const decomposedColor = decomposeColor(color);\n return decomposedColor.values.slice(0, 3).map((val, idx) => decomposedColor.type.indexOf('hsl') !== -1 && idx !== 0 ? `${val}%` : val).join(' ');\n};\nexport const private_safeColorChannel = (color, warning) => {\n try {\n return colorChannel(color);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n};\n\n/**\n * Converts a color object with type and values to a string.\n * @param {object} color - Decomposed color\n * @param {string} color.type - One of: 'rgb', 'rgba', 'hsl', 'hsla', 'color'\n * @param {array} color.values - [n,n,n] or [n,n,n,n]\n * @returns {string} A CSS color string\n */\nexport function recomposeColor(color) {\n const {\n type,\n colorSpace\n } = color;\n let {\n values\n } = color;\n if (type.indexOf('rgb') !== -1) {\n // Only convert the first 3 values to int (i.e. not alpha)\n values = values.map((n, i) => i < 3 ? parseInt(n, 10) : n);\n } else if (type.indexOf('hsl') !== -1) {\n values[1] = `${values[1]}%`;\n values[2] = `${values[2]}%`;\n }\n if (type.indexOf('color') !== -1) {\n values = `${colorSpace} ${values.join(' ')}`;\n } else {\n values = `${values.join(', ')}`;\n }\n return `${type}(${values})`;\n}\n\n/**\n * Converts a color from CSS rgb format to CSS hex format.\n * @param {string} color - RGB color, i.e. rgb(n, n, n)\n * @returns {string} A CSS rgb color string, i.e. #nnnnnn\n */\nexport function rgbToHex(color) {\n // Idempotent\n if (color.indexOf('#') === 0) {\n return color;\n }\n const {\n values\n } = decomposeColor(color);\n return `#${values.map((n, i) => intToHex(i === 3 ? Math.round(255 * n) : n)).join('')}`;\n}\n\n/**\n * Converts a color from hsl format to rgb format.\n * @param {string} color - HSL color values\n * @returns {string} rgb color values\n */\nexport function hslToRgb(color) {\n color = decomposeColor(color);\n const {\n values\n } = color;\n const h = values[0];\n const s = values[1] / 100;\n const l = values[2] / 100;\n const a = s * Math.min(l, 1 - l);\n const f = (n, k = (n + h / 30) % 12) => l - a * Math.max(Math.min(k - 3, 9 - k, 1), -1);\n let type = 'rgb';\n const rgb = [Math.round(f(0) * 255), Math.round(f(8) * 255), Math.round(f(4) * 255)];\n if (color.type === 'hsla') {\n type += 'a';\n rgb.push(values[3]);\n }\n return recomposeColor({\n type,\n values: rgb\n });\n}\n/**\n * The relative brightness of any point in a color space,\n * normalized to 0 for darkest black and 1 for lightest white.\n *\n * Formula: https://www.w3.org/TR/WCAG20-TECHS/G17.html#G17-tests\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @returns {number} The relative brightness of the color in the range 0 - 1\n */\nexport function getLuminance(color) {\n color = decomposeColor(color);\n let rgb = color.type === 'hsl' || color.type === 'hsla' ? decomposeColor(hslToRgb(color)).values : color.values;\n rgb = rgb.map(val => {\n if (color.type !== 'color') {\n val /= 255; // normalized\n }\n return val <= 0.03928 ? val / 12.92 : ((val + 0.055) / 1.055) ** 2.4;\n });\n\n // Truncate at 3 digits\n return Number((0.2126 * rgb[0] + 0.7152 * rgb[1] + 0.0722 * rgb[2]).toFixed(3));\n}\n\n/**\n * Calculates the contrast ratio between two colors.\n *\n * Formula: https://www.w3.org/TR/WCAG20-TECHS/G17.html#G17-tests\n * @param {string} foreground - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla()\n * @param {string} background - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla()\n * @returns {number} A contrast ratio value in the range 0 - 21.\n */\nexport function getContrastRatio(foreground, background) {\n const lumA = getLuminance(foreground);\n const lumB = getLuminance(background);\n return (Math.max(lumA, lumB) + 0.05) / (Math.min(lumA, lumB) + 0.05);\n}\n\n/**\n * Sets the absolute transparency of a color.\n * Any existing alpha values are overwritten.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} value - value to set the alpha channel to in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function alpha(color, value) {\n color = decomposeColor(color);\n value = clampWrapper(value);\n if (color.type === 'rgb' || color.type === 'hsl') {\n color.type += 'a';\n }\n if (color.type === 'color') {\n color.values[3] = `/${value}`;\n } else {\n color.values[3] = value;\n }\n return recomposeColor(color);\n}\nexport function private_safeAlpha(color, value, warning) {\n try {\n return alpha(color, value);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Darkens a color.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} coefficient - multiplier in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function darken(color, coefficient) {\n color = decomposeColor(color);\n coefficient = clampWrapper(coefficient);\n if (color.type.indexOf('hsl') !== -1) {\n color.values[2] *= 1 - coefficient;\n } else if (color.type.indexOf('rgb') !== -1 || color.type.indexOf('color') !== -1) {\n for (let i = 0; i < 3; i += 1) {\n color.values[i] *= 1 - coefficient;\n }\n }\n return recomposeColor(color);\n}\nexport function private_safeDarken(color, coefficient, warning) {\n try {\n return darken(color, coefficient);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Lightens a color.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} coefficient - multiplier in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function lighten(color, coefficient) {\n color = decomposeColor(color);\n coefficient = clampWrapper(coefficient);\n if (color.type.indexOf('hsl') !== -1) {\n color.values[2] += (100 - color.values[2]) * coefficient;\n } else if (color.type.indexOf('rgb') !== -1) {\n for (let i = 0; i < 3; i += 1) {\n color.values[i] += (255 - color.values[i]) * coefficient;\n }\n } else if (color.type.indexOf('color') !== -1) {\n for (let i = 0; i < 3; i += 1) {\n color.values[i] += (1 - color.values[i]) * coefficient;\n }\n }\n return recomposeColor(color);\n}\nexport function private_safeLighten(color, coefficient, warning) {\n try {\n return lighten(color, coefficient);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Darken or lighten a color, depending on its luminance.\n * Light colors are darkened, dark colors are lightened.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} coefficient=0.15 - multiplier in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function emphasize(color, coefficient = 0.15) {\n return getLuminance(color) > 0.5 ? darken(color, coefficient) : lighten(color, coefficient);\n}\nexport function private_safeEmphasize(color, coefficient, warning) {\n try {\n return emphasize(color, coefficient);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Blend a transparent overlay color with a background color, resulting in a single\n * RGB color.\n * @param {string} background - CSS color\n * @param {string} overlay - CSS color\n * @param {number} opacity - Opacity multiplier in the range 0 - 1\n * @param {number} [gamma=1.0] - Gamma correction factor. For gamma-correct blending, 2.2 is usual.\n */\nexport function blend(background, overlay, opacity, gamma = 1.0) {\n const blendChannel = (b, o) => Math.round((b ** (1 / gamma) * (1 - opacity) + o ** (1 / gamma) * opacity) ** gamma);\n const backgroundColor = decomposeColor(background);\n const overlayColor = decomposeColor(overlay);\n const rgb = [blendChannel(backgroundColor.values[0], overlayColor.values[0]), blendChannel(backgroundColor.values[1], overlayColor.values[1]), blendChannel(backgroundColor.values[2], overlayColor.values[2])];\n return recomposeColor({\n type: 'rgb',\n values: rgb\n });\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nexport default function createMixins(breakpoints, mixins) {\n return _extends({\n toolbar: {\n minHeight: 56,\n [breakpoints.up('xs')]: {\n '@media (orientation: landscape)': {\n minHeight: 48\n }\n },\n [breakpoints.up('sm')]: {\n minHeight: 64\n }\n }\n }, mixins);\n}","const common = {\n black: '#000',\n white: '#fff'\n};\nexport default common;","const grey = {\n 50: '#fafafa',\n 100: '#f5f5f5',\n 200: '#eeeeee',\n 300: '#e0e0e0',\n 400: '#bdbdbd',\n 500: '#9e9e9e',\n 600: '#757575',\n 700: '#616161',\n 800: '#424242',\n 900: '#212121',\n A100: '#f5f5f5',\n A200: '#eeeeee',\n A400: '#bdbdbd',\n A700: '#616161'\n};\nexport default grey;","const purple = {\n 50: '#f3e5f5',\n 100: '#e1bee7',\n 200: '#ce93d8',\n 300: '#ba68c8',\n 400: '#ab47bc',\n 500: '#9c27b0',\n 600: '#8e24aa',\n 700: '#7b1fa2',\n 800: '#6a1b9a',\n 900: '#4a148c',\n A100: '#ea80fc',\n A200: '#e040fb',\n A400: '#d500f9',\n A700: '#aa00ff'\n};\nexport default purple;","const red = {\n 50: '#ffebee',\n 100: '#ffcdd2',\n 200: '#ef9a9a',\n 300: '#e57373',\n 400: '#ef5350',\n 500: '#f44336',\n 600: '#e53935',\n 700: '#d32f2f',\n 800: '#c62828',\n 900: '#b71c1c',\n A100: '#ff8a80',\n A200: '#ff5252',\n A400: '#ff1744',\n A700: '#d50000'\n};\nexport default red;","const orange = {\n 50: '#fff3e0',\n 100: '#ffe0b2',\n 200: '#ffcc80',\n 300: '#ffb74d',\n 400: '#ffa726',\n 500: '#ff9800',\n 600: '#fb8c00',\n 700: '#f57c00',\n 800: '#ef6c00',\n 900: '#e65100',\n A100: '#ffd180',\n A200: '#ffab40',\n A400: '#ff9100',\n A700: '#ff6d00'\n};\nexport default orange;","const blue = {\n 50: '#e3f2fd',\n 100: '#bbdefb',\n 200: '#90caf9',\n 300: '#64b5f6',\n 400: '#42a5f5',\n 500: '#2196f3',\n 600: '#1e88e5',\n 700: '#1976d2',\n 800: '#1565c0',\n 900: '#0d47a1',\n A100: '#82b1ff',\n A200: '#448aff',\n A400: '#2979ff',\n A700: '#2962ff'\n};\nexport default blue;","const lightBlue = {\n 50: '#e1f5fe',\n 100: '#b3e5fc',\n 200: '#81d4fa',\n 300: '#4fc3f7',\n 400: '#29b6f6',\n 500: '#03a9f4',\n 600: '#039be5',\n 700: '#0288d1',\n 800: '#0277bd',\n 900: '#01579b',\n A100: '#80d8ff',\n A200: '#40c4ff',\n A400: '#00b0ff',\n A700: '#0091ea'\n};\nexport default lightBlue;","const green = {\n 50: '#e8f5e9',\n 100: '#c8e6c9',\n 200: '#a5d6a7',\n 300: '#81c784',\n 400: '#66bb6a',\n 500: '#4caf50',\n 600: '#43a047',\n 700: '#388e3c',\n 800: '#2e7d32',\n 900: '#1b5e20',\n A100: '#b9f6ca',\n A200: '#69f0ae',\n A400: '#00e676',\n A700: '#00c853'\n};\nexport default green;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\nconst _excluded = [\"mode\", \"contrastThreshold\", \"tonalOffset\"];\nimport { deepmerge } from '@mui/utils';\nimport { darken, getContrastRatio, lighten } from '@mui/system';\nimport common from '../colors/common';\nimport grey from '../colors/grey';\nimport purple from '../colors/purple';\nimport red from '../colors/red';\nimport orange from '../colors/orange';\nimport blue from '../colors/blue';\nimport lightBlue from '../colors/lightBlue';\nimport green from '../colors/green';\nexport const light = {\n // The colors used to style the text.\n text: {\n // The most important text.\n primary: 'rgba(0, 0, 0, 0.87)',\n // Secondary text.\n secondary: 'rgba(0, 0, 0, 0.6)',\n // Disabled text have even lower visual prominence.\n disabled: 'rgba(0, 0, 0, 0.38)'\n },\n // The color used to divide different elements.\n divider: 'rgba(0, 0, 0, 0.12)',\n // The background colors used to style the surfaces.\n // Consistency between these values is important.\n background: {\n paper: common.white,\n default: common.white\n },\n // The colors used to style the action elements.\n action: {\n // The color of an active action like an icon button.\n active: 'rgba(0, 0, 0, 0.54)',\n // The color of an hovered action.\n hover: 'rgba(0, 0, 0, 0.04)',\n hoverOpacity: 0.04,\n // The color of a selected action.\n selected: 'rgba(0, 0, 0, 0.08)',\n selectedOpacity: 0.08,\n // The color of a disabled action.\n disabled: 'rgba(0, 0, 0, 0.26)',\n // The background color of a disabled action.\n disabledBackground: 'rgba(0, 0, 0, 0.12)',\n disabledOpacity: 0.38,\n focus: 'rgba(0, 0, 0, 0.12)',\n focusOpacity: 0.12,\n activatedOpacity: 0.12\n }\n};\nexport const dark = {\n text: {\n primary: common.white,\n secondary: 'rgba(255, 255, 255, 0.7)',\n disabled: 'rgba(255, 255, 255, 0.5)',\n icon: 'rgba(255, 255, 255, 0.5)'\n },\n divider: 'rgba(255, 255, 255, 0.12)',\n background: {\n paper: '#121212',\n default: '#121212'\n },\n action: {\n active: common.white,\n hover: 'rgba(255, 255, 255, 0.08)',\n hoverOpacity: 0.08,\n selected: 'rgba(255, 255, 255, 0.16)',\n selectedOpacity: 0.16,\n disabled: 'rgba(255, 255, 255, 0.3)',\n disabledBackground: 'rgba(255, 255, 255, 0.12)',\n disabledOpacity: 0.38,\n focus: 'rgba(255, 255, 255, 0.12)',\n focusOpacity: 0.12,\n activatedOpacity: 0.24\n }\n};\nfunction addLightOrDark(intent, direction, shade, tonalOffset) {\n const tonalOffsetLight = tonalOffset.light || tonalOffset;\n const tonalOffsetDark = tonalOffset.dark || tonalOffset * 1.5;\n if (!intent[direction]) {\n if (intent.hasOwnProperty(shade)) {\n intent[direction] = intent[shade];\n } else if (direction === 'light') {\n intent.light = lighten(intent.main, tonalOffsetLight);\n } else if (direction === 'dark') {\n intent.dark = darken(intent.main, tonalOffsetDark);\n }\n }\n}\nfunction getDefaultPrimary(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: blue[200],\n light: blue[50],\n dark: blue[400]\n };\n }\n return {\n main: blue[700],\n light: blue[400],\n dark: blue[800]\n };\n}\nfunction getDefaultSecondary(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: purple[200],\n light: purple[50],\n dark: purple[400]\n };\n }\n return {\n main: purple[500],\n light: purple[300],\n dark: purple[700]\n };\n}\nfunction getDefaultError(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: red[500],\n light: red[300],\n dark: red[700]\n };\n }\n return {\n main: red[700],\n light: red[400],\n dark: red[800]\n };\n}\nfunction getDefaultInfo(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: lightBlue[400],\n light: lightBlue[300],\n dark: lightBlue[700]\n };\n }\n return {\n main: lightBlue[700],\n light: lightBlue[500],\n dark: lightBlue[900]\n };\n}\nfunction getDefaultSuccess(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: green[400],\n light: green[300],\n dark: green[700]\n };\n }\n return {\n main: green[800],\n light: green[500],\n dark: green[900]\n };\n}\nfunction getDefaultWarning(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: orange[400],\n light: orange[300],\n dark: orange[700]\n };\n }\n return {\n main: '#ed6c02',\n // closest to orange[800] that pass 3:1.\n light: orange[500],\n dark: orange[900]\n };\n}\nexport default function createPalette(palette) {\n const {\n mode = 'light',\n contrastThreshold = 3,\n tonalOffset = 0.2\n } = palette,\n other = _objectWithoutPropertiesLoose(palette, _excluded);\n const primary = palette.primary || getDefaultPrimary(mode);\n const secondary = palette.secondary || getDefaultSecondary(mode);\n const error = palette.error || getDefaultError(mode);\n const info = palette.info || getDefaultInfo(mode);\n const success = palette.success || getDefaultSuccess(mode);\n const warning = palette.warning || getDefaultWarning(mode);\n\n // Use the same logic as\n // Bootstrap: https://github.com/twbs/bootstrap/blob/1d6e3710dd447de1a200f29e8fa521f8a0908f70/scss/_functions.scss#L59\n // and material-components-web https://github.com/material-components/material-components-web/blob/ac46b8863c4dab9fc22c4c662dc6bd1b65dd652f/packages/mdc-theme/_functions.scss#L54\n function getContrastText(background) {\n const contrastText = getContrastRatio(background, dark.text.primary) >= contrastThreshold ? dark.text.primary : light.text.primary;\n if (process.env.NODE_ENV !== 'production') {\n const contrast = getContrastRatio(background, contrastText);\n if (contrast < 3) {\n console.error([`MUI: The contrast ratio of ${contrast}:1 for ${contrastText} on ${background}`, 'falls below the WCAG recommended absolute minimum contrast ratio of 3:1.', 'https://www.w3.org/TR/2008/REC-WCAG20-20081211/#visual-audio-contrast-contrast'].join('\\n'));\n }\n }\n return contrastText;\n }\n const augmentColor = ({\n color,\n name,\n mainShade = 500,\n lightShade = 300,\n darkShade = 700\n }) => {\n color = _extends({}, color);\n if (!color.main && color[mainShade]) {\n color.main = color[mainShade];\n }\n if (!color.hasOwnProperty('main')) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: The color${name ? ` (${name})` : ''} provided to augmentColor(color) is invalid.\nThe color object needs to have a \\`main\\` property or a \\`${mainShade}\\` property.` : _formatMuiErrorMessage(11, name ? ` (${name})` : '', mainShade));\n }\n if (typeof color.main !== 'string') {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: The color${name ? ` (${name})` : ''} provided to augmentColor(color) is invalid.\n\\`color.main\\` should be a string, but \\`${JSON.stringify(color.main)}\\` was provided instead.\n\nDid you intend to use one of the following approaches?\n\nimport { green } from \"@mui/material/colors\";\n\nconst theme1 = createTheme({ palette: {\n primary: green,\n} });\n\nconst theme2 = createTheme({ palette: {\n primary: { main: green[500] },\n} });` : _formatMuiErrorMessage(12, name ? ` (${name})` : '', JSON.stringify(color.main)));\n }\n addLightOrDark(color, 'light', lightShade, tonalOffset);\n addLightOrDark(color, 'dark', darkShade, tonalOffset);\n if (!color.contrastText) {\n color.contrastText = getContrastText(color.main);\n }\n return color;\n };\n const modes = {\n dark,\n light\n };\n if (process.env.NODE_ENV !== 'production') {\n if (!modes[mode]) {\n console.error(`MUI: The palette mode \\`${mode}\\` is not supported.`);\n }\n }\n const paletteOutput = deepmerge(_extends({\n // A collection of common colors.\n common: _extends({}, common),\n // prevent mutable object.\n // The palette mode, can be light or dark.\n mode,\n // The colors used to represent primary interface elements for a user.\n primary: augmentColor({\n color: primary,\n name: 'primary'\n }),\n // The colors used to represent secondary interface elements for a user.\n secondary: augmentColor({\n color: secondary,\n name: 'secondary',\n mainShade: 'A400',\n lightShade: 'A200',\n darkShade: 'A700'\n }),\n // The colors used to represent interface elements that the user should be made aware of.\n error: augmentColor({\n color: error,\n name: 'error'\n }),\n // The colors used to represent potentially dangerous actions or important messages.\n warning: augmentColor({\n color: warning,\n name: 'warning'\n }),\n // The colors used to present information to the user that is neutral and not necessarily important.\n info: augmentColor({\n color: info,\n name: 'info'\n }),\n // The colors used to indicate the successful completion of an action that user triggered.\n success: augmentColor({\n color: success,\n name: 'success'\n }),\n // The grey colors.\n grey,\n // Used by `getContrastText()` to maximize the contrast between\n // the background and the text.\n contrastThreshold,\n // Takes a background color and returns the text color that maximizes the contrast.\n getContrastText,\n // Generate a rich color object.\n augmentColor,\n // Used by the functions below to shift a color's luminance by approximately\n // two indexes within its tonal palette.\n // E.g., shift from Red 500 to Red 300 or Red 700.\n tonalOffset\n }, modes[mode]), other);\n return paletteOutput;\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"fontFamily\", \"fontSize\", \"fontWeightLight\", \"fontWeightRegular\", \"fontWeightMedium\", \"fontWeightBold\", \"htmlFontSize\", \"allVariants\", \"pxToRem\"];\nimport { deepmerge } from '@mui/utils';\nfunction round(value) {\n return Math.round(value * 1e5) / 1e5;\n}\nconst caseAllCaps = {\n textTransform: 'uppercase'\n};\nconst defaultFontFamily = '\"Roboto\", \"Helvetica\", \"Arial\", sans-serif';\n\n/**\n * @see @link{https://m2.material.io/design/typography/the-type-system.html}\n * @see @link{https://m2.material.io/design/typography/understanding-typography.html}\n */\nexport default function createTypography(palette, typography) {\n const _ref = typeof typography === 'function' ? typography(palette) : typography,\n {\n fontFamily = defaultFontFamily,\n // The default font size of the Material Specification.\n fontSize = 14,\n // px\n fontWeightLight = 300,\n fontWeightRegular = 400,\n fontWeightMedium = 500,\n fontWeightBold = 700,\n // Tell MUI what's the font-size on the html element.\n // 16px is the default font-size used by browsers.\n htmlFontSize = 16,\n // Apply the CSS properties to all the variants.\n allVariants,\n pxToRem: pxToRem2\n } = _ref,\n other = _objectWithoutPropertiesLoose(_ref, _excluded);\n if (process.env.NODE_ENV !== 'production') {\n if (typeof fontSize !== 'number') {\n console.error('MUI: `fontSize` is required to be a number.');\n }\n if (typeof htmlFontSize !== 'number') {\n console.error('MUI: `htmlFontSize` is required to be a number.');\n }\n }\n const coef = fontSize / 14;\n const pxToRem = pxToRem2 || (size => `${size / htmlFontSize * coef}rem`);\n const buildVariant = (fontWeight, size, lineHeight, letterSpacing, casing) => _extends({\n fontFamily,\n fontWeight,\n fontSize: pxToRem(size),\n // Unitless following https://meyerweb.com/eric/thoughts/2006/02/08/unitless-line-heights/\n lineHeight\n }, fontFamily === defaultFontFamily ? {\n letterSpacing: `${round(letterSpacing / size)}em`\n } : {}, casing, allVariants);\n const variants = {\n h1: buildVariant(fontWeightLight, 96, 1.167, -1.5),\n h2: buildVariant(fontWeightLight, 60, 1.2, -0.5),\n h3: buildVariant(fontWeightRegular, 48, 1.167, 0),\n h4: buildVariant(fontWeightRegular, 34, 1.235, 0.25),\n h5: buildVariant(fontWeightRegular, 24, 1.334, 0),\n h6: buildVariant(fontWeightMedium, 20, 1.6, 0.15),\n subtitle1: buildVariant(fontWeightRegular, 16, 1.75, 0.15),\n subtitle2: buildVariant(fontWeightMedium, 14, 1.57, 0.1),\n body1: buildVariant(fontWeightRegular, 16, 1.5, 0.15),\n body2: buildVariant(fontWeightRegular, 14, 1.43, 0.15),\n button: buildVariant(fontWeightMedium, 14, 1.75, 0.4, caseAllCaps),\n caption: buildVariant(fontWeightRegular, 12, 1.66, 0.4),\n overline: buildVariant(fontWeightRegular, 12, 2.66, 1, caseAllCaps),\n // TODO v6: Remove handling of 'inherit' variant from the theme as it is already handled in Material UI's Typography component. Also, remember to remove the associated types.\n inherit: {\n fontFamily: 'inherit',\n fontWeight: 'inherit',\n fontSize: 'inherit',\n lineHeight: 'inherit',\n letterSpacing: 'inherit'\n }\n };\n return deepmerge(_extends({\n htmlFontSize,\n pxToRem,\n fontFamily,\n fontSize,\n fontWeightLight,\n fontWeightRegular,\n fontWeightMedium,\n fontWeightBold\n }, variants), other, {\n clone: false // No need to clone deep\n });\n}","const shadowKeyUmbraOpacity = 0.2;\nconst shadowKeyPenumbraOpacity = 0.14;\nconst shadowAmbientShadowOpacity = 0.12;\nfunction createShadow(...px) {\n return [`${px[0]}px ${px[1]}px ${px[2]}px ${px[3]}px rgba(0,0,0,${shadowKeyUmbraOpacity})`, `${px[4]}px ${px[5]}px ${px[6]}px ${px[7]}px rgba(0,0,0,${shadowKeyPenumbraOpacity})`, `${px[8]}px ${px[9]}px ${px[10]}px ${px[11]}px rgba(0,0,0,${shadowAmbientShadowOpacity})`].join(',');\n}\n\n// Values from https://github.com/material-components/material-components-web/blob/be8747f94574669cb5e7add1a7c54fa41a89cec7/packages/mdc-elevation/_variables.scss\nconst shadows = ['none', createShadow(0, 2, 1, -1, 0, 1, 1, 0, 0, 1, 3, 0), createShadow(0, 3, 1, -2, 0, 2, 2, 0, 0, 1, 5, 0), createShadow(0, 3, 3, -2, 0, 3, 4, 0, 0, 1, 8, 0), createShadow(0, 2, 4, -1, 0, 4, 5, 0, 0, 1, 10, 0), createShadow(0, 3, 5, -1, 0, 5, 8, 0, 0, 1, 14, 0), createShadow(0, 3, 5, -1, 0, 6, 10, 0, 0, 1, 18, 0), createShadow(0, 4, 5, -2, 0, 7, 10, 1, 0, 2, 16, 1), createShadow(0, 5, 5, -3, 0, 8, 10, 1, 0, 3, 14, 2), createShadow(0, 5, 6, -3, 0, 9, 12, 1, 0, 3, 16, 2), createShadow(0, 6, 6, -3, 0, 10, 14, 1, 0, 4, 18, 3), createShadow(0, 6, 7, -4, 0, 11, 15, 1, 0, 4, 20, 3), createShadow(0, 7, 8, -4, 0, 12, 17, 2, 0, 5, 22, 4), createShadow(0, 7, 8, -4, 0, 13, 19, 2, 0, 5, 24, 4), createShadow(0, 7, 9, -4, 0, 14, 21, 2, 0, 5, 26, 4), createShadow(0, 8, 9, -5, 0, 15, 22, 2, 0, 6, 28, 5), createShadow(0, 8, 10, -5, 0, 16, 24, 2, 0, 6, 30, 5), createShadow(0, 8, 11, -5, 0, 17, 26, 2, 0, 6, 32, 5), createShadow(0, 9, 11, -5, 0, 18, 28, 2, 0, 7, 34, 6), createShadow(0, 9, 12, -6, 0, 19, 29, 2, 0, 7, 36, 6), createShadow(0, 10, 13, -6, 0, 20, 31, 3, 0, 8, 38, 7), createShadow(0, 10, 13, -6, 0, 21, 33, 3, 0, 8, 40, 7), createShadow(0, 10, 14, -6, 0, 22, 35, 3, 0, 8, 42, 7), createShadow(0, 11, 14, -7, 0, 23, 36, 3, 0, 9, 44, 8), createShadow(0, 11, 15, -7, 0, 24, 38, 3, 0, 9, 46, 8)];\nexport default shadows;","import _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nconst _excluded = [\"duration\", \"easing\", \"delay\"];\n// Follow https://material.google.com/motion/duration-easing.html#duration-easing-natural-easing-curves\n// to learn the context in which each easing should be used.\nexport const easing = {\n // This is the most common easing curve.\n easeInOut: 'cubic-bezier(0.4, 0, 0.2, 1)',\n // Objects enter the screen at full velocity from off-screen and\n // slowly decelerate to a resting point.\n easeOut: 'cubic-bezier(0.0, 0, 0.2, 1)',\n // Objects leave the screen at full velocity. They do not decelerate when off-screen.\n easeIn: 'cubic-bezier(0.4, 0, 1, 1)',\n // The sharp curve is used by objects that may return to the screen at any time.\n sharp: 'cubic-bezier(0.4, 0, 0.6, 1)'\n};\n\n// Follow https://m2.material.io/guidelines/motion/duration-easing.html#duration-easing-common-durations\n// to learn when use what timing\nexport const duration = {\n shortest: 150,\n shorter: 200,\n short: 250,\n // most basic recommended timing\n standard: 300,\n // this is to be used in complex animations\n complex: 375,\n // recommended when something is entering screen\n enteringScreen: 225,\n // recommended when something is leaving screen\n leavingScreen: 195\n};\nfunction formatMs(milliseconds) {\n return `${Math.round(milliseconds)}ms`;\n}\nfunction getAutoHeightDuration(height) {\n if (!height) {\n return 0;\n }\n const constant = height / 36;\n\n // https://www.wolframalpha.com/input/?i=(4+%2B+15+*+(x+%2F+36+)+**+0.25+%2B+(x+%2F+36)+%2F+5)+*+10\n return Math.round((4 + 15 * constant ** 0.25 + constant / 5) * 10);\n}\nexport default function createTransitions(inputTransitions) {\n const mergedEasing = _extends({}, easing, inputTransitions.easing);\n const mergedDuration = _extends({}, duration, inputTransitions.duration);\n const create = (props = ['all'], options = {}) => {\n const {\n duration: durationOption = mergedDuration.standard,\n easing: easingOption = mergedEasing.easeInOut,\n delay = 0\n } = options,\n other = _objectWithoutPropertiesLoose(options, _excluded);\n if (process.env.NODE_ENV !== 'production') {\n const isString = value => typeof value === 'string';\n // IE11 support, replace with Number.isNaN\n // eslint-disable-next-line no-restricted-globals\n const isNumber = value => !isNaN(parseFloat(value));\n if (!isString(props) && !Array.isArray(props)) {\n console.error('MUI: Argument \"props\" must be a string or Array.');\n }\n if (!isNumber(durationOption) && !isString(durationOption)) {\n console.error(`MUI: Argument \"duration\" must be a number or a string but found ${durationOption}.`);\n }\n if (!isString(easingOption)) {\n console.error('MUI: Argument \"easing\" must be a string.');\n }\n if (!isNumber(delay) && !isString(delay)) {\n console.error('MUI: Argument \"delay\" must be a number or a string.');\n }\n if (typeof options !== 'object') {\n console.error(['MUI: Secong argument of transition.create must be an object.', \"Arguments should be either `create('prop1', options)` or `create(['prop1', 'prop2'], options)`\"].join('\\n'));\n }\n if (Object.keys(other).length !== 0) {\n console.error(`MUI: Unrecognized argument(s) [${Object.keys(other).join(',')}].`);\n }\n }\n return (Array.isArray(props) ? props : [props]).map(animatedProp => `${animatedProp} ${typeof durationOption === 'string' ? durationOption : formatMs(durationOption)} ${easingOption} ${typeof delay === 'string' ? delay : formatMs(delay)}`).join(',');\n };\n return _extends({\n getAutoHeightDuration,\n create\n }, inputTransitions, {\n easing: mergedEasing,\n duration: mergedDuration\n });\n}","// We need to centralize the zIndex definitions as they work\n// like global values in the browser.\nconst zIndex = {\n mobileStepper: 1000,\n fab: 1050,\n speedDial: 1050,\n appBar: 1100,\n drawer: 1200,\n modal: 1300,\n snackbar: 1400,\n tooltip: 1500\n};\nexport default zIndex;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\nconst _excluded = [\"breakpoints\", \"mixins\", \"spacing\", \"palette\", \"transitions\", \"typography\", \"shape\"];\nimport { deepmerge } from '@mui/utils';\nimport { createTheme as systemCreateTheme, unstable_defaultSxConfig as defaultSxConfig, unstable_styleFunctionSx as styleFunctionSx } from '@mui/system';\nimport generateUtilityClass from '@mui/utils/generateUtilityClass';\nimport createMixins from './createMixins';\nimport createPalette from './createPalette';\nimport createTypography from './createTypography';\nimport shadows from './shadows';\nimport createTransitions from './createTransitions';\nimport zIndex from './zIndex';\nfunction createTheme(options = {}, ...args) {\n const {\n mixins: mixinsInput = {},\n palette: paletteInput = {},\n transitions: transitionsInput = {},\n typography: typographyInput = {}\n } = options,\n other = _objectWithoutPropertiesLoose(options, _excluded);\n if (options.vars) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: \\`vars\\` is a private field used for CSS variables support.\nPlease use another name.` : _formatMuiErrorMessage(18));\n }\n const palette = createPalette(paletteInput);\n const systemTheme = systemCreateTheme(options);\n let muiTheme = deepmerge(systemTheme, {\n mixins: createMixins(systemTheme.breakpoints, mixinsInput),\n palette,\n // Don't use [...shadows] until you've verified its transpiled code is not invoking the iterator protocol.\n shadows: shadows.slice(),\n typography: createTypography(palette, typographyInput),\n transitions: createTransitions(transitionsInput),\n zIndex: _extends({}, zIndex)\n });\n muiTheme = deepmerge(muiTheme, other);\n muiTheme = args.reduce((acc, argument) => deepmerge(acc, argument), muiTheme);\n if (process.env.NODE_ENV !== 'production') {\n // TODO v6: Refactor to use globalStateClassesMapping from @mui/utils once `readOnly` state class is used in Rating component.\n const stateClasses = ['active', 'checked', 'completed', 'disabled', 'error', 'expanded', 'focused', 'focusVisible', 'required', 'selected'];\n const traverse = (node, component) => {\n let key;\n\n // eslint-disable-next-line guard-for-in, no-restricted-syntax\n for (key in node) {\n const child = node[key];\n if (stateClasses.indexOf(key) !== -1 && Object.keys(child).length > 0) {\n if (process.env.NODE_ENV !== 'production') {\n const stateClass = generateUtilityClass('', key);\n console.error([`MUI: The \\`${component}\\` component increases ` + `the CSS specificity of the \\`${key}\\` internal state.`, 'You can not override it like this: ', JSON.stringify(node, null, 2), '', `Instead, you need to use the '&.${stateClass}' syntax:`, JSON.stringify({\n root: {\n [`&.${stateClass}`]: child\n }\n }, null, 2), '', 'https://mui.com/r/state-classes-guide'].join('\\n'));\n }\n // Remove the style to prevent global conflicts.\n node[key] = {};\n }\n }\n };\n Object.keys(muiTheme.components).forEach(component => {\n const styleOverrides = muiTheme.components[component].styleOverrides;\n if (styleOverrides && component.indexOf('Mui') === 0) {\n traverse(styleOverrides, component);\n }\n });\n }\n muiTheme.unstable_sxConfig = _extends({}, defaultSxConfig, other == null ? void 0 : other.unstable_sxConfig);\n muiTheme.unstable_sx = function sx(props) {\n return styleFunctionSx({\n sx: props,\n theme: this\n });\n };\n return muiTheme;\n}\nlet warnedOnce = false;\nexport function createMuiTheme(...args) {\n if (process.env.NODE_ENV !== 'production') {\n if (!warnedOnce) {\n warnedOnce = true;\n console.error(['MUI: the createMuiTheme function was renamed to createTheme.', '', \"You should use `import { createTheme } from '@mui/material/styles'`\"].join('\\n'));\n }\n }\n return createTheme(...args);\n}\nexport default createTheme;","'use client';\n\nimport createTheme from './createTheme';\nconst defaultTheme = createTheme();\nexport default defaultTheme;","export default '$$material';","'use client';\n\nimport { useThemeProps as systemUseThemeProps } from '@mui/system';\nimport defaultTheme from './defaultTheme';\nimport THEME_ID from './identifier';\nexport default function useThemeProps({\n props,\n name\n}) {\n return systemUseThemeProps({\n props,\n name,\n defaultTheme,\n themeId: THEME_ID\n });\n}","'use client';\n\nimport { createStyled, shouldForwardProp } from '@mui/system';\nimport defaultTheme from './defaultTheme';\nimport THEME_ID from './identifier';\nexport const rootShouldForwardProp = prop => shouldForwardProp(prop) && prop !== 'classes';\nexport const slotShouldForwardProp = shouldForwardProp;\nconst styled = createStyled({\n themeId: THEME_ID,\n defaultTheme,\n rootShouldForwardProp\n});\nexport default styled;","import generateUtilityClasses from '@mui/utils/generateUtilityClasses';\nimport generateUtilityClass from '@mui/utils/generateUtilityClass';\nexport function getSvgIconUtilityClass(slot) {\n return generateUtilityClass('MuiSvgIcon', slot);\n}\nconst svgIconClasses = generateUtilityClasses('MuiSvgIcon', ['root', 'colorPrimary', 'colorSecondary', 'colorAction', 'colorError', 'colorDisabled', 'fontSizeInherit', 'fontSizeSmall', 'fontSizeMedium', 'fontSizeLarge']);\nexport default svgIconClasses;","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"children\", \"className\", \"color\", \"component\", \"fontSize\", \"htmlColor\", \"inheritViewBox\", \"titleAccess\", \"viewBox\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport clsx from 'clsx';\nimport { unstable_composeClasses as composeClasses } from '@mui/base/composeClasses';\nimport capitalize from '../utils/capitalize';\nimport useThemeProps from '../styles/useThemeProps';\nimport styled from '../styles/styled';\nimport { getSvgIconUtilityClass } from './svgIconClasses';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nimport { jsxs as _jsxs } from \"react/jsx-runtime\";\nconst useUtilityClasses = ownerState => {\n const {\n color,\n fontSize,\n classes\n } = ownerState;\n const slots = {\n root: ['root', color !== 'inherit' && `color${capitalize(color)}`, `fontSize${capitalize(fontSize)}`]\n };\n return composeClasses(slots, getSvgIconUtilityClass, classes);\n};\nconst SvgIconRoot = styled('svg', {\n name: 'MuiSvgIcon',\n slot: 'Root',\n overridesResolver: (props, styles) => {\n const {\n ownerState\n } = props;\n return [styles.root, ownerState.color !== 'inherit' && styles[`color${capitalize(ownerState.color)}`], styles[`fontSize${capitalize(ownerState.fontSize)}`]];\n }\n})(({\n theme,\n ownerState\n}) => {\n var _theme$transitions, _theme$transitions$cr, _theme$transitions2, _theme$typography, _theme$typography$pxT, _theme$typography2, _theme$typography2$px, _theme$typography3, _theme$typography3$px, _palette$ownerState$c, _palette, _palette2, _palette3;\n return {\n userSelect: 'none',\n width: '1em',\n height: '1em',\n display: 'inline-block',\n // the will define the property that has `currentColor`\n // e.g. heroicons uses fill=\"none\" and stroke=\"currentColor\"\n fill: ownerState.hasSvgAsChild ? undefined : 'currentColor',\n flexShrink: 0,\n transition: (_theme$transitions = theme.transitions) == null || (_theme$transitions$cr = _theme$transitions.create) == null ? void 0 : _theme$transitions$cr.call(_theme$transitions, 'fill', {\n duration: (_theme$transitions2 = theme.transitions) == null || (_theme$transitions2 = _theme$transitions2.duration) == null ? void 0 : _theme$transitions2.shorter\n }),\n fontSize: {\n inherit: 'inherit',\n small: ((_theme$typography = theme.typography) == null || (_theme$typography$pxT = _theme$typography.pxToRem) == null ? void 0 : _theme$typography$pxT.call(_theme$typography, 20)) || '1.25rem',\n medium: ((_theme$typography2 = theme.typography) == null || (_theme$typography2$px = _theme$typography2.pxToRem) == null ? void 0 : _theme$typography2$px.call(_theme$typography2, 24)) || '1.5rem',\n large: ((_theme$typography3 = theme.typography) == null || (_theme$typography3$px = _theme$typography3.pxToRem) == null ? void 0 : _theme$typography3$px.call(_theme$typography3, 35)) || '2.1875rem'\n }[ownerState.fontSize],\n // TODO v5 deprecate, v6 remove for sx\n color: (_palette$ownerState$c = (_palette = (theme.vars || theme).palette) == null || (_palette = _palette[ownerState.color]) == null ? void 0 : _palette.main) != null ? _palette$ownerState$c : {\n action: (_palette2 = (theme.vars || theme).palette) == null || (_palette2 = _palette2.action) == null ? void 0 : _palette2.active,\n disabled: (_palette3 = (theme.vars || theme).palette) == null || (_palette3 = _palette3.action) == null ? void 0 : _palette3.disabled,\n inherit: undefined\n }[ownerState.color]\n };\n});\nconst SvgIcon = /*#__PURE__*/React.forwardRef(function SvgIcon(inProps, ref) {\n const props = useThemeProps({\n props: inProps,\n name: 'MuiSvgIcon'\n });\n const {\n children,\n className,\n color = 'inherit',\n component = 'svg',\n fontSize = 'medium',\n htmlColor,\n inheritViewBox = false,\n titleAccess,\n viewBox = '0 0 24 24'\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const hasSvgAsChild = /*#__PURE__*/React.isValidElement(children) && children.type === 'svg';\n const ownerState = _extends({}, props, {\n color,\n component,\n fontSize,\n instanceFontSize: inProps.fontSize,\n inheritViewBox,\n viewBox,\n hasSvgAsChild\n });\n const more = {};\n if (!inheritViewBox) {\n more.viewBox = viewBox;\n }\n const classes = useUtilityClasses(ownerState);\n return /*#__PURE__*/_jsxs(SvgIconRoot, _extends({\n as: component,\n className: clsx(classes.root, className),\n focusable: \"false\",\n color: htmlColor,\n \"aria-hidden\": titleAccess ? undefined : true,\n role: titleAccess ? 'img' : undefined,\n ref: ref\n }, more, other, hasSvgAsChild && children.props, {\n ownerState: ownerState,\n children: [hasSvgAsChild ? children.props.children : children, titleAccess ? /*#__PURE__*/_jsx(\"title\", {\n children: titleAccess\n }) : null]\n }));\n});\nprocess.env.NODE_ENV !== \"production\" ? SvgIcon.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the d.ts file and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * Node passed into the SVG element.\n */\n children: PropTypes.node,\n /**\n * Override or extend the styles applied to the component.\n */\n classes: PropTypes.object,\n /**\n * @ignore\n */\n className: PropTypes.string,\n /**\n * The color of the component.\n * It supports both default and custom theme colors, which can be added as shown in the\n * [palette customization guide](https://mui.com/material-ui/customization/palette/#custom-colors).\n * You can use the `htmlColor` prop to apply a color attribute to the SVG element.\n * @default 'inherit'\n */\n color: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.oneOf(['inherit', 'action', 'disabled', 'primary', 'secondary', 'error', 'info', 'success', 'warning']), PropTypes.string]),\n /**\n * The component used for the root node.\n * Either a string to use a HTML element or a component.\n */\n component: PropTypes.elementType,\n /**\n * The fontSize applied to the icon. Defaults to 24px, but can be configure to inherit font size.\n * @default 'medium'\n */\n fontSize: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.oneOf(['inherit', 'large', 'medium', 'small']), PropTypes.string]),\n /**\n * Applies a color attribute to the SVG element.\n */\n htmlColor: PropTypes.string,\n /**\n * If `true`, the root node will inherit the custom `component`'s viewBox and the `viewBox`\n * prop will be ignored.\n * Useful when you want to reference a custom `component` and have `SvgIcon` pass that\n * `component`'s viewBox to the root node.\n * @default false\n */\n inheritViewBox: PropTypes.bool,\n /**\n * The shape-rendering attribute. The behavior of the different options is described on the\n * [MDN Web Docs](https://developer.mozilla.org/en-US/docs/Web/SVG/Attribute/shape-rendering).\n * If you are having issues with blurry icons you should investigate this prop.\n */\n shapeRendering: PropTypes.string,\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Provides a human-readable title for the element that contains it.\n * https://www.w3.org/TR/SVG-access/#Equivalent\n */\n titleAccess: PropTypes.string,\n /**\n * Allows you to redefine what the coordinates without units mean inside an SVG element.\n * For example, if the SVG element is 500 (width) by 200 (height),\n * and you pass viewBox=\"0 0 50 20\",\n * this means that the coordinates inside the SVG will go from the top left corner (0,0)\n * to bottom right (50,20) and each unit will be worth 10px.\n * @default '0 0 24 24'\n */\n viewBox: PropTypes.string\n} : void 0;\nSvgIcon.muiName = 'SvgIcon';\nexport default SvgIcon;","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport * as React from 'react';\nimport SvgIcon from '../SvgIcon';\n\n/**\n * Private module reserved for @mui packages.\n */\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nexport default function createSvgIcon(path, displayName) {\n function Component(props, ref) {\n return /*#__PURE__*/_jsx(SvgIcon, _extends({\n \"data-testid\": `${displayName}Icon`,\n ref: ref\n }, props, {\n children: path\n }));\n }\n if (process.env.NODE_ENV !== 'production') {\n // Need to set `displayName` on the inner component for React.memo.\n // React prior to 16.14 ignores `displayName` on the wrapper.\n Component.displayName = `${displayName}Icon`;\n }\n Component.muiName = SvgIcon.muiName;\n return /*#__PURE__*/React.memo( /*#__PURE__*/React.forwardRef(Component));\n}","'use client';\n\nimport { unstable_ClassNameGenerator as ClassNameGenerator } from '@mui/base/ClassNameGenerator';\nexport { default as capitalize } from './capitalize';\nexport { default as createChainedFunction } from './createChainedFunction';\nexport { default as createSvgIcon } from './createSvgIcon';\nexport { default as debounce } from './debounce';\nexport { default as deprecatedPropType } from './deprecatedPropType';\nexport { default as isMuiElement } from './isMuiElement';\nexport { default as ownerDocument } from './ownerDocument';\nexport { default as ownerWindow } from './ownerWindow';\nexport { default as requirePropFactory } from './requirePropFactory';\nexport { default as setRef } from './setRef';\nexport { default as unstable_useEnhancedEffect } from './useEnhancedEffect';\nexport { default as unstable_useId } from './useId';\nexport { default as unsupportedProp } from './unsupportedProp';\nexport { default as useControlled } from './useControlled';\nexport { default as useEventCallback } from './useEventCallback';\nexport { default as useForkRef } from './useForkRef';\nexport { default as useIsFocusVisible } from './useIsFocusVisible';\n// TODO: remove this export once ClassNameGenerator is stable\n// eslint-disable-next-line @typescript-eslint/naming-convention\nexport const unstable_ClassNameGenerator = {\n configure: generator => {\n if (process.env.NODE_ENV !== 'production') {\n console.warn(['MUI: `ClassNameGenerator` import from `@mui/material/utils` is outdated and might cause unexpected issues.', '', \"You should use `import { unstable_ClassNameGenerator } from '@mui/material/className'` instead\", '', 'The detail of the issue: https://github.com/mui/material-ui/issues/30011#issuecomment-1024993401', '', 'The updated documentation: https://mui.com/guides/classname-generator/'].join('\\n'));\n }\n ClassNameGenerator.configure(generator);\n }\n};","\"use strict\";\n'use client';\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nObject.defineProperty(exports, \"default\", {\n enumerable: true,\n get: function () {\n return _utils.createSvgIcon;\n }\n});\nvar _utils = require(\"@mui/material/utils\");","\"use strict\";\n\"use client\";\n\nvar _interopRequireDefault = require(\"@babel/runtime/helpers/interopRequireDefault\");\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = void 0;\nvar _createSvgIcon = _interopRequireDefault(require(\"./utils/createSvgIcon\"));\nvar _jsxRuntime = require(\"react/jsx-runtime\");\nvar _default = exports.default = (0, _createSvgIcon.default)( /*#__PURE__*/(0, _jsxRuntime.jsx)(\"path\", {\n d: \"m10 17 5-5-5-5z\"\n}), 'ArrowRight');","/**\n * Determines if a given element is a DOM element name (i.e. not a React component).\n */\nexport function isHostComponent(element) {\n return typeof element === 'string';\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport { isHostComponent } from './isHostComponent';\n\n/**\n * Type of the ownerState based on the type of an element it applies to.\n * This resolves to the provided OwnerState for React components and `undefined` for host components.\n * Falls back to `OwnerState | undefined` when the exact type can't be determined in development time.\n */\n\n/**\n * Appends the ownerState object to the props, merging with the existing one if necessary.\n *\n * @param elementType Type of the element that owns the `existingProps`. If the element is a DOM node or undefined, `ownerState` is not applied.\n * @param otherProps Props of the element.\n * @param ownerState\n */\nexport function appendOwnerState(elementType, otherProps, ownerState) {\n if (elementType === undefined || isHostComponent(elementType)) {\n return otherProps;\n }\n return _extends({}, otherProps, {\n ownerState: _extends({}, otherProps.ownerState, ownerState)\n });\n}","'use client';\n\nimport * as React from 'react';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nconst defaultContextValue = {\n disableDefaultClasses: false\n};\nconst ClassNameConfiguratorContext = /*#__PURE__*/React.createContext(defaultContextValue);\n/**\n * @ignore - internal hook.\n *\n * Wraps the `generateUtilityClass` function and controls how the classes are generated.\n * Currently it only affects whether the classes are applied or not.\n *\n * @returns Function to be called with the `generateUtilityClass` function specific to a component to generate the classes.\n */\nexport function useClassNamesOverride(generateUtilityClass) {\n const {\n disableDefaultClasses\n } = React.useContext(ClassNameConfiguratorContext);\n return slot => {\n if (disableDefaultClasses) {\n return '';\n }\n return generateUtilityClass(slot);\n };\n}\n\n/**\n * Allows to configure the components within to not apply any built-in classes.\n */\nexport function ClassNameConfigurator(props) {\n const {\n disableDefaultClasses,\n children\n } = props;\n const contextValue = React.useMemo(() => ({\n disableDefaultClasses: disableDefaultClasses != null ? disableDefaultClasses : false\n }), [disableDefaultClasses]);\n return /*#__PURE__*/_jsx(ClassNameConfiguratorContext.Provider, {\n value: contextValue,\n children: children\n });\n}","/**\n * Extracts event handlers from a given object.\n * A prop is considered an event handler if it is a function and its name starts with `on`.\n *\n * @param object An object to extract event handlers from.\n * @param excludeKeys An array of keys to exclude from the returned object.\n */\nexport function extractEventHandlers(object, excludeKeys = []) {\n if (object === undefined) {\n return {};\n }\n const result = {};\n Object.keys(object).filter(prop => prop.match(/^on[A-Z]/) && typeof object[prop] === 'function' && !excludeKeys.includes(prop)).forEach(prop => {\n result[prop] = object[prop];\n });\n return result;\n}","/**\n * If `componentProps` is a function, calls it with the provided `ownerState`.\n * Otherwise, just returns `componentProps`.\n */\nexport function resolveComponentProps(componentProps, ownerState, slotState) {\n if (typeof componentProps === 'function') {\n return componentProps(ownerState, slotState);\n }\n return componentProps;\n}","/**\n * Removes event handlers from the given object.\n * A field is considered an event handler if it is a function with a name beginning with `on`.\n *\n * @param object Object to remove event handlers from.\n * @returns Object with event handlers removed.\n */\nexport function omitEventHandlers(object) {\n if (object === undefined) {\n return {};\n }\n const result = {};\n Object.keys(object).filter(prop => !(prop.match(/^on[A-Z]/) && typeof object[prop] === 'function')).forEach(prop => {\n result[prop] = object[prop];\n });\n return result;\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport clsx from 'clsx';\nimport { extractEventHandlers } from './extractEventHandlers';\nimport { omitEventHandlers } from './omitEventHandlers';\n/**\n * Merges the slot component internal props (usually coming from a hook)\n * with the externally provided ones.\n *\n * The merge order is (the latter overrides the former):\n * 1. The internal props (specified as a getter function to work with get*Props hook result)\n * 2. Additional props (specified internally on a Base UI component)\n * 3. External props specified on the owner component. These should only be used on a root slot.\n * 4. External props specified in the `slotProps.*` prop.\n * 5. The `className` prop - combined from all the above.\n * @param parameters\n * @returns\n */\nexport function mergeSlotProps(parameters) {\n const {\n getSlotProps,\n additionalProps,\n externalSlotProps,\n externalForwardedProps,\n className\n } = parameters;\n if (!getSlotProps) {\n // The simpler case - getSlotProps is not defined, so no internal event handlers are defined,\n // so we can simply merge all the props without having to worry about extracting event handlers.\n const joinedClasses = clsx(additionalProps == null ? void 0 : additionalProps.className, className, externalForwardedProps == null ? void 0 : externalForwardedProps.className, externalSlotProps == null ? void 0 : externalSlotProps.className);\n const mergedStyle = _extends({}, additionalProps == null ? void 0 : additionalProps.style, externalForwardedProps == null ? void 0 : externalForwardedProps.style, externalSlotProps == null ? void 0 : externalSlotProps.style);\n const props = _extends({}, additionalProps, externalForwardedProps, externalSlotProps);\n if (joinedClasses.length > 0) {\n props.className = joinedClasses;\n }\n if (Object.keys(mergedStyle).length > 0) {\n props.style = mergedStyle;\n }\n return {\n props,\n internalRef: undefined\n };\n }\n\n // In this case, getSlotProps is responsible for calling the external event handlers.\n // We don't need to include them in the merged props because of this.\n\n const eventHandlers = extractEventHandlers(_extends({}, externalForwardedProps, externalSlotProps));\n const componentsPropsWithoutEventHandlers = omitEventHandlers(externalSlotProps);\n const otherPropsWithoutEventHandlers = omitEventHandlers(externalForwardedProps);\n const internalSlotProps = getSlotProps(eventHandlers);\n\n // The order of classes is important here.\n // Emotion (that we use in libraries consuming Base UI) depends on this order\n // to properly override style. It requires the most important classes to be last\n // (see https://github.com/mui/material-ui/pull/33205) for the related discussion.\n const joinedClasses = clsx(internalSlotProps == null ? void 0 : internalSlotProps.className, additionalProps == null ? void 0 : additionalProps.className, className, externalForwardedProps == null ? void 0 : externalForwardedProps.className, externalSlotProps == null ? void 0 : externalSlotProps.className);\n const mergedStyle = _extends({}, internalSlotProps == null ? void 0 : internalSlotProps.style, additionalProps == null ? void 0 : additionalProps.style, externalForwardedProps == null ? void 0 : externalForwardedProps.style, externalSlotProps == null ? void 0 : externalSlotProps.style);\n const props = _extends({}, internalSlotProps, additionalProps, otherPropsWithoutEventHandlers, componentsPropsWithoutEventHandlers);\n if (joinedClasses.length > 0) {\n props.className = joinedClasses;\n }\n if (Object.keys(mergedStyle).length > 0) {\n props.style = mergedStyle;\n }\n return {\n props,\n internalRef: internalSlotProps.ref\n };\n}","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"elementType\", \"externalSlotProps\", \"ownerState\", \"skipResolvingSlotProps\"];\nimport { unstable_useForkRef as useForkRef } from '@mui/utils';\nimport { appendOwnerState } from './appendOwnerState';\nimport { mergeSlotProps } from './mergeSlotProps';\nimport { resolveComponentProps } from './resolveComponentProps';\n/**\n * @ignore - do not document.\n * Builds the props to be passed into the slot of an unstyled component.\n * It merges the internal props of the component with the ones supplied by the user, allowing to customize the behavior.\n * If the slot component is not a host component, it also merges in the `ownerState`.\n *\n * @param parameters.getSlotProps - A function that returns the props to be passed to the slot component.\n */\nexport function useSlotProps(parameters) {\n var _parameters$additiona;\n const {\n elementType,\n externalSlotProps,\n ownerState,\n skipResolvingSlotProps = false\n } = parameters,\n rest = _objectWithoutPropertiesLoose(parameters, _excluded);\n const resolvedComponentsProps = skipResolvingSlotProps ? {} : resolveComponentProps(externalSlotProps, ownerState);\n const {\n props: mergedProps,\n internalRef\n } = mergeSlotProps(_extends({}, rest, {\n externalSlotProps: resolvedComponentsProps\n }));\n const ref = useForkRef(internalRef, resolvedComponentsProps == null ? void 0 : resolvedComponentsProps.ref, (_parameters$additiona = parameters.additionalProps) == null ? void 0 : _parameters$additiona.ref);\n const props = appendOwnerState(elementType, _extends({}, mergedProps, {\n ref\n }), ownerState);\n return props;\n}","import { globalStateClasses } from '@mui/utils/generateUtilityClass';\nconst GLOBAL_CLASS_PREFIX = 'base';\nfunction buildStateClass(state) {\n return `${GLOBAL_CLASS_PREFIX}--${state}`;\n}\nfunction buildSlotClass(componentName, slot) {\n return `${GLOBAL_CLASS_PREFIX}-${componentName}-${slot}`;\n}\nexport function generateUtilityClass(componentName, slot) {\n const globalStateClass = globalStateClasses[slot];\n return globalStateClass ? buildStateClass(globalStateClass) : buildSlotClass(componentName, slot);\n}\nexport function isGlobalState(slot) {\n return globalStateClasses[slot] !== undefined;\n}","import { generateUtilityClass } from '../generateUtilityClass';\nexport function generateUtilityClasses(componentName, slots) {\n const result = {};\n slots.forEach(slot => {\n result[slot] = generateUtilityClass(componentName, slot);\n });\n return result;\n}","'use client';\n\nimport * as React from 'react';\nimport * as ReactDOM from 'react-dom';\nimport PropTypes from 'prop-types';\nimport { exactProp, HTMLElementType, unstable_useEnhancedEffect as useEnhancedEffect, unstable_useForkRef as useForkRef, unstable_setRef as setRef } from '@mui/utils';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nfunction getContainer(container) {\n return typeof container === 'function' ? container() : container;\n}\n\n/**\n * Portals provide a first-class way to render children into a DOM node\n * that exists outside the DOM hierarchy of the parent component.\n *\n * Demos:\n *\n * - [Portal](https://mui.com/base-ui/react-portal/)\n *\n * API:\n *\n * - [Portal API](https://mui.com/base-ui/react-portal/components-api/#portal)\n */\nconst Portal = /*#__PURE__*/React.forwardRef(function Portal(props, forwardedRef) {\n const {\n children,\n container,\n disablePortal = false\n } = props;\n const [mountNode, setMountNode] = React.useState(null);\n // @ts-expect-error TODO upstream fix\n const handleRef = useForkRef( /*#__PURE__*/React.isValidElement(children) ? children.ref : null, forwardedRef);\n useEnhancedEffect(() => {\n if (!disablePortal) {\n setMountNode(getContainer(container) || document.body);\n }\n }, [container, disablePortal]);\n useEnhancedEffect(() => {\n if (mountNode && !disablePortal) {\n setRef(forwardedRef, mountNode);\n return () => {\n setRef(forwardedRef, null);\n };\n }\n return undefined;\n }, [forwardedRef, mountNode, disablePortal]);\n if (disablePortal) {\n if ( /*#__PURE__*/React.isValidElement(children)) {\n const newProps = {\n ref: handleRef\n };\n return /*#__PURE__*/React.cloneElement(children, newProps);\n }\n return /*#__PURE__*/_jsx(React.Fragment, {\n children: children\n });\n }\n return /*#__PURE__*/_jsx(React.Fragment, {\n children: mountNode ? /*#__PURE__*/ReactDOM.createPortal(children, mountNode) : mountNode\n });\n});\nprocess.env.NODE_ENV !== \"production\" ? Portal.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * The children to render into the `container`.\n */\n children: PropTypes.node,\n /**\n * An HTML element or function that returns one.\n * The `container` will have the portal children appended to it.\n *\n * You can also provide a callback, which is called in a React layout effect.\n * This lets you set the container from a ref, and also makes server-side rendering possible.\n *\n * By default, it uses the body of the top-level document object,\n * so it's simply `document.body` most of the time.\n */\n container: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.func]),\n /**\n * The `children` will be under the DOM hierarchy of the parent component.\n * @default false\n */\n disablePortal: PropTypes.bool\n} : void 0;\nif (process.env.NODE_ENV !== 'production') {\n // eslint-disable-next-line\n Portal['propTypes' + ''] = exactProp(Portal.propTypes);\n}\nexport { Portal };","export var top = 'top';\nexport var bottom = 'bottom';\nexport var right = 'right';\nexport var left = 'left';\nexport var auto = 'auto';\nexport var basePlacements = [top, bottom, right, left];\nexport var start = 'start';\nexport var end = 'end';\nexport var clippingParents = 'clippingParents';\nexport var viewport = 'viewport';\nexport var popper = 'popper';\nexport var reference = 'reference';\nexport var variationPlacements = /*#__PURE__*/basePlacements.reduce(function (acc, placement) {\n return acc.concat([placement + \"-\" + start, placement + \"-\" + end]);\n}, []);\nexport var placements = /*#__PURE__*/[].concat(basePlacements, [auto]).reduce(function (acc, placement) {\n return acc.concat([placement, placement + \"-\" + start, placement + \"-\" + end]);\n}, []); // modifiers that need to read the DOM\n\nexport var beforeRead = 'beforeRead';\nexport var read = 'read';\nexport var afterRead = 'afterRead'; // pure-logic modifiers\n\nexport var beforeMain = 'beforeMain';\nexport var main = 'main';\nexport var afterMain = 'afterMain'; // modifier with the purpose to write to the DOM (or write into a framework state)\n\nexport var beforeWrite = 'beforeWrite';\nexport var write = 'write';\nexport var afterWrite = 'afterWrite';\nexport var modifierPhases = [beforeRead, read, afterRead, beforeMain, main, afterMain, beforeWrite, write, afterWrite];","export default function getNodeName(element) {\n return element ? (element.nodeName || '').toLowerCase() : null;\n}","export default function getWindow(node) {\n if (node == null) {\n return window;\n }\n\n if (node.toString() !== '[object Window]') {\n var ownerDocument = node.ownerDocument;\n return ownerDocument ? ownerDocument.defaultView || window : window;\n }\n\n return node;\n}","import getWindow from \"./getWindow.js\";\n\nfunction isElement(node) {\n var OwnElement = getWindow(node).Element;\n return node instanceof OwnElement || node instanceof Element;\n}\n\nfunction isHTMLElement(node) {\n var OwnElement = getWindow(node).HTMLElement;\n return node instanceof OwnElement || node instanceof HTMLElement;\n}\n\nfunction isShadowRoot(node) {\n // IE 11 has no ShadowRoot\n if (typeof ShadowRoot === 'undefined') {\n return false;\n }\n\n var OwnElement = getWindow(node).ShadowRoot;\n return node instanceof OwnElement || node instanceof ShadowRoot;\n}\n\nexport { isElement, isHTMLElement, isShadowRoot };","import getNodeName from \"../dom-utils/getNodeName.js\";\nimport { isHTMLElement } from \"../dom-utils/instanceOf.js\"; // This modifier takes the styles prepared by the `computeStyles` modifier\n// and applies them to the HTMLElements such as popper and arrow\n\nfunction applyStyles(_ref) {\n var state = _ref.state;\n Object.keys(state.elements).forEach(function (name) {\n var style = state.styles[name] || {};\n var attributes = state.attributes[name] || {};\n var element = state.elements[name]; // arrow is optional + virtual elements\n\n if (!isHTMLElement(element) || !getNodeName(element)) {\n return;\n } // Flow doesn't support to extend this property, but it's the most\n // effective way to apply styles to an HTMLElement\n // $FlowFixMe[cannot-write]\n\n\n Object.assign(element.style, style);\n Object.keys(attributes).forEach(function (name) {\n var value = attributes[name];\n\n if (value === false) {\n element.removeAttribute(name);\n } else {\n element.setAttribute(name, value === true ? '' : value);\n }\n });\n });\n}\n\nfunction effect(_ref2) {\n var state = _ref2.state;\n var initialStyles = {\n popper: {\n position: state.options.strategy,\n left: '0',\n top: '0',\n margin: '0'\n },\n arrow: {\n position: 'absolute'\n },\n reference: {}\n };\n Object.assign(state.elements.popper.style, initialStyles.popper);\n state.styles = initialStyles;\n\n if (state.elements.arrow) {\n Object.assign(state.elements.arrow.style, initialStyles.arrow);\n }\n\n return function () {\n Object.keys(state.elements).forEach(function (name) {\n var element = state.elements[name];\n var attributes = state.attributes[name] || {};\n var styleProperties = Object.keys(state.styles.hasOwnProperty(name) ? state.styles[name] : initialStyles[name]); // Set all values to an empty string to unset them\n\n var style = styleProperties.reduce(function (style, property) {\n style[property] = '';\n return style;\n }, {}); // arrow is optional + virtual elements\n\n if (!isHTMLElement(element) || !getNodeName(element)) {\n return;\n }\n\n Object.assign(element.style, style);\n Object.keys(attributes).forEach(function (attribute) {\n element.removeAttribute(attribute);\n });\n });\n };\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'applyStyles',\n enabled: true,\n phase: 'write',\n fn: applyStyles,\n effect: effect,\n requires: ['computeStyles']\n};","import { auto } from \"../enums.js\";\nexport default function getBasePlacement(placement) {\n return placement.split('-')[0];\n}","export var max = Math.max;\nexport var min = Math.min;\nexport var round = Math.round;","export default function getUAString() {\n var uaData = navigator.userAgentData;\n\n if (uaData != null && uaData.brands && Array.isArray(uaData.brands)) {\n return uaData.brands.map(function (item) {\n return item.brand + \"/\" + item.version;\n }).join(' ');\n }\n\n return navigator.userAgent;\n}","import getUAString from \"../utils/userAgent.js\";\nexport default function isLayoutViewport() {\n return !/^((?!chrome|android).)*safari/i.test(getUAString());\n}","import { isElement, isHTMLElement } from \"./instanceOf.js\";\nimport { round } from \"../utils/math.js\";\nimport getWindow from \"./getWindow.js\";\nimport isLayoutViewport from \"./isLayoutViewport.js\";\nexport default function getBoundingClientRect(element, includeScale, isFixedStrategy) {\n if (includeScale === void 0) {\n includeScale = false;\n }\n\n if (isFixedStrategy === void 0) {\n isFixedStrategy = false;\n }\n\n var clientRect = element.getBoundingClientRect();\n var scaleX = 1;\n var scaleY = 1;\n\n if (includeScale && isHTMLElement(element)) {\n scaleX = element.offsetWidth > 0 ? round(clientRect.width) / element.offsetWidth || 1 : 1;\n scaleY = element.offsetHeight > 0 ? round(clientRect.height) / element.offsetHeight || 1 : 1;\n }\n\n var _ref = isElement(element) ? getWindow(element) : window,\n visualViewport = _ref.visualViewport;\n\n var addVisualOffsets = !isLayoutViewport() && isFixedStrategy;\n var x = (clientRect.left + (addVisualOffsets && visualViewport ? visualViewport.offsetLeft : 0)) / scaleX;\n var y = (clientRect.top + (addVisualOffsets && visualViewport ? visualViewport.offsetTop : 0)) / scaleY;\n var width = clientRect.width / scaleX;\n var height = clientRect.height / scaleY;\n return {\n width: width,\n height: height,\n top: y,\n right: x + width,\n bottom: y + height,\n left: x,\n x: x,\n y: y\n };\n}","import getBoundingClientRect from \"./getBoundingClientRect.js\"; // Returns the layout rect of an element relative to its offsetParent. Layout\n// means it doesn't take into account transforms.\n\nexport default function getLayoutRect(element) {\n var clientRect = getBoundingClientRect(element); // Use the clientRect sizes if it's not been transformed.\n // Fixes https://github.com/popperjs/popper-core/issues/1223\n\n var width = element.offsetWidth;\n var height = element.offsetHeight;\n\n if (Math.abs(clientRect.width - width) <= 1) {\n width = clientRect.width;\n }\n\n if (Math.abs(clientRect.height - height) <= 1) {\n height = clientRect.height;\n }\n\n return {\n x: element.offsetLeft,\n y: element.offsetTop,\n width: width,\n height: height\n };\n}","import { isShadowRoot } from \"./instanceOf.js\";\nexport default function contains(parent, child) {\n var rootNode = child.getRootNode && child.getRootNode(); // First, attempt with faster native method\n\n if (parent.contains(child)) {\n return true;\n } // then fallback to custom implementation with Shadow DOM support\n else if (rootNode && isShadowRoot(rootNode)) {\n var next = child;\n\n do {\n if (next && parent.isSameNode(next)) {\n return true;\n } // $FlowFixMe[prop-missing]: need a better way to handle this...\n\n\n next = next.parentNode || next.host;\n } while (next);\n } // Give up, the result is false\n\n\n return false;\n}","import getWindow from \"./getWindow.js\";\nexport default function getComputedStyle(element) {\n return getWindow(element).getComputedStyle(element);\n}","import getNodeName from \"./getNodeName.js\";\nexport default function isTableElement(element) {\n return ['table', 'td', 'th'].indexOf(getNodeName(element)) >= 0;\n}","import { isElement } from \"./instanceOf.js\";\nexport default function getDocumentElement(element) {\n // $FlowFixMe[incompatible-return]: assume body is always available\n return ((isElement(element) ? element.ownerDocument : // $FlowFixMe[prop-missing]\n element.document) || window.document).documentElement;\n}","import getNodeName from \"./getNodeName.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport { isShadowRoot } from \"./instanceOf.js\";\nexport default function getParentNode(element) {\n if (getNodeName(element) === 'html') {\n return element;\n }\n\n return (// this is a quicker (but less type safe) way to save quite some bytes from the bundle\n // $FlowFixMe[incompatible-return]\n // $FlowFixMe[prop-missing]\n element.assignedSlot || // step into the shadow DOM of the parent of a slotted node\n element.parentNode || ( // DOM Element detected\n isShadowRoot(element) ? element.host : null) || // ShadowRoot detected\n // $FlowFixMe[incompatible-call]: HTMLElement is a Node\n getDocumentElement(element) // fallback\n\n );\n}","import getWindow from \"./getWindow.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport getComputedStyle from \"./getComputedStyle.js\";\nimport { isHTMLElement, isShadowRoot } from \"./instanceOf.js\";\nimport isTableElement from \"./isTableElement.js\";\nimport getParentNode from \"./getParentNode.js\";\nimport getUAString from \"../utils/userAgent.js\";\n\nfunction getTrueOffsetParent(element) {\n if (!isHTMLElement(element) || // https://github.com/popperjs/popper-core/issues/837\n getComputedStyle(element).position === 'fixed') {\n return null;\n }\n\n return element.offsetParent;\n} // `.offsetParent` reports `null` for fixed elements, while absolute elements\n// return the containing block\n\n\nfunction getContainingBlock(element) {\n var isFirefox = /firefox/i.test(getUAString());\n var isIE = /Trident/i.test(getUAString());\n\n if (isIE && isHTMLElement(element)) {\n // In IE 9, 10 and 11 fixed elements containing block is always established by the viewport\n var elementCss = getComputedStyle(element);\n\n if (elementCss.position === 'fixed') {\n return null;\n }\n }\n\n var currentNode = getParentNode(element);\n\n if (isShadowRoot(currentNode)) {\n currentNode = currentNode.host;\n }\n\n while (isHTMLElement(currentNode) && ['html', 'body'].indexOf(getNodeName(currentNode)) < 0) {\n var css = getComputedStyle(currentNode); // This is non-exhaustive but covers the most common CSS properties that\n // create a containing block.\n // https://developer.mozilla.org/en-US/docs/Web/CSS/Containing_block#identifying_the_containing_block\n\n if (css.transform !== 'none' || css.perspective !== 'none' || css.contain === 'paint' || ['transform', 'perspective'].indexOf(css.willChange) !== -1 || isFirefox && css.willChange === 'filter' || isFirefox && css.filter && css.filter !== 'none') {\n return currentNode;\n } else {\n currentNode = currentNode.parentNode;\n }\n }\n\n return null;\n} // Gets the closest ancestor positioned element. Handles some edge cases,\n// such as table ancestors and cross browser bugs.\n\n\nexport default function getOffsetParent(element) {\n var window = getWindow(element);\n var offsetParent = getTrueOffsetParent(element);\n\n while (offsetParent && isTableElement(offsetParent) && getComputedStyle(offsetParent).position === 'static') {\n offsetParent = getTrueOffsetParent(offsetParent);\n }\n\n if (offsetParent && (getNodeName(offsetParent) === 'html' || getNodeName(offsetParent) === 'body' && getComputedStyle(offsetParent).position === 'static')) {\n return window;\n }\n\n return offsetParent || getContainingBlock(element) || window;\n}","export default function getMainAxisFromPlacement(placement) {\n return ['top', 'bottom'].indexOf(placement) >= 0 ? 'x' : 'y';\n}","import { max as mathMax, min as mathMin } from \"./math.js\";\nexport function within(min, value, max) {\n return mathMax(min, mathMin(value, max));\n}\nexport function withinMaxClamp(min, value, max) {\n var v = within(min, value, max);\n return v > max ? max : v;\n}","export default function getFreshSideObject() {\n return {\n top: 0,\n right: 0,\n bottom: 0,\n left: 0\n };\n}","import getFreshSideObject from \"./getFreshSideObject.js\";\nexport default function mergePaddingObject(paddingObject) {\n return Object.assign({}, getFreshSideObject(), paddingObject);\n}","export default function expandToHashMap(value, keys) {\n return keys.reduce(function (hashMap, key) {\n hashMap[key] = value;\n return hashMap;\n }, {});\n}","import getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getLayoutRect from \"../dom-utils/getLayoutRect.js\";\nimport contains from \"../dom-utils/contains.js\";\nimport getOffsetParent from \"../dom-utils/getOffsetParent.js\";\nimport getMainAxisFromPlacement from \"../utils/getMainAxisFromPlacement.js\";\nimport { within } from \"../utils/within.js\";\nimport mergePaddingObject from \"../utils/mergePaddingObject.js\";\nimport expandToHashMap from \"../utils/expandToHashMap.js\";\nimport { left, right, basePlacements, top, bottom } from \"../enums.js\"; // eslint-disable-next-line import/no-unused-modules\n\nvar toPaddingObject = function toPaddingObject(padding, state) {\n padding = typeof padding === 'function' ? padding(Object.assign({}, state.rects, {\n placement: state.placement\n })) : padding;\n return mergePaddingObject(typeof padding !== 'number' ? padding : expandToHashMap(padding, basePlacements));\n};\n\nfunction arrow(_ref) {\n var _state$modifiersData$;\n\n var state = _ref.state,\n name = _ref.name,\n options = _ref.options;\n var arrowElement = state.elements.arrow;\n var popperOffsets = state.modifiersData.popperOffsets;\n var basePlacement = getBasePlacement(state.placement);\n var axis = getMainAxisFromPlacement(basePlacement);\n var isVertical = [left, right].indexOf(basePlacement) >= 0;\n var len = isVertical ? 'height' : 'width';\n\n if (!arrowElement || !popperOffsets) {\n return;\n }\n\n var paddingObject = toPaddingObject(options.padding, state);\n var arrowRect = getLayoutRect(arrowElement);\n var minProp = axis === 'y' ? top : left;\n var maxProp = axis === 'y' ? bottom : right;\n var endDiff = state.rects.reference[len] + state.rects.reference[axis] - popperOffsets[axis] - state.rects.popper[len];\n var startDiff = popperOffsets[axis] - state.rects.reference[axis];\n var arrowOffsetParent = getOffsetParent(arrowElement);\n var clientSize = arrowOffsetParent ? axis === 'y' ? arrowOffsetParent.clientHeight || 0 : arrowOffsetParent.clientWidth || 0 : 0;\n var centerToReference = endDiff / 2 - startDiff / 2; // Make sure the arrow doesn't overflow the popper if the center point is\n // outside of the popper bounds\n\n var min = paddingObject[minProp];\n var max = clientSize - arrowRect[len] - paddingObject[maxProp];\n var center = clientSize / 2 - arrowRect[len] / 2 + centerToReference;\n var offset = within(min, center, max); // Prevents breaking syntax highlighting...\n\n var axisProp = axis;\n state.modifiersData[name] = (_state$modifiersData$ = {}, _state$modifiersData$[axisProp] = offset, _state$modifiersData$.centerOffset = offset - center, _state$modifiersData$);\n}\n\nfunction effect(_ref2) {\n var state = _ref2.state,\n options = _ref2.options;\n var _options$element = options.element,\n arrowElement = _options$element === void 0 ? '[data-popper-arrow]' : _options$element;\n\n if (arrowElement == null) {\n return;\n } // CSS selector\n\n\n if (typeof arrowElement === 'string') {\n arrowElement = state.elements.popper.querySelector(arrowElement);\n\n if (!arrowElement) {\n return;\n }\n }\n\n if (!contains(state.elements.popper, arrowElement)) {\n return;\n }\n\n state.elements.arrow = arrowElement;\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'arrow',\n enabled: true,\n phase: 'main',\n fn: arrow,\n effect: effect,\n requires: ['popperOffsets'],\n requiresIfExists: ['preventOverflow']\n};","export default function getVariation(placement) {\n return placement.split('-')[1];\n}","import { top, left, right, bottom, end } from \"../enums.js\";\nimport getOffsetParent from \"../dom-utils/getOffsetParent.js\";\nimport getWindow from \"../dom-utils/getWindow.js\";\nimport getDocumentElement from \"../dom-utils/getDocumentElement.js\";\nimport getComputedStyle from \"../dom-utils/getComputedStyle.js\";\nimport getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getVariation from \"../utils/getVariation.js\";\nimport { round } from \"../utils/math.js\"; // eslint-disable-next-line import/no-unused-modules\n\nvar unsetSides = {\n top: 'auto',\n right: 'auto',\n bottom: 'auto',\n left: 'auto'\n}; // Round the offsets to the nearest suitable subpixel based on the DPR.\n// Zooming can change the DPR, but it seems to report a value that will\n// cleanly divide the values into the appropriate subpixels.\n\nfunction roundOffsetsByDPR(_ref, win) {\n var x = _ref.x,\n y = _ref.y;\n var dpr = win.devicePixelRatio || 1;\n return {\n x: round(x * dpr) / dpr || 0,\n y: round(y * dpr) / dpr || 0\n };\n}\n\nexport function mapToStyles(_ref2) {\n var _Object$assign2;\n\n var popper = _ref2.popper,\n popperRect = _ref2.popperRect,\n placement = _ref2.placement,\n variation = _ref2.variation,\n offsets = _ref2.offsets,\n position = _ref2.position,\n gpuAcceleration = _ref2.gpuAcceleration,\n adaptive = _ref2.adaptive,\n roundOffsets = _ref2.roundOffsets,\n isFixed = _ref2.isFixed;\n var _offsets$x = offsets.x,\n x = _offsets$x === void 0 ? 0 : _offsets$x,\n _offsets$y = offsets.y,\n y = _offsets$y === void 0 ? 0 : _offsets$y;\n\n var _ref3 = typeof roundOffsets === 'function' ? roundOffsets({\n x: x,\n y: y\n }) : {\n x: x,\n y: y\n };\n\n x = _ref3.x;\n y = _ref3.y;\n var hasX = offsets.hasOwnProperty('x');\n var hasY = offsets.hasOwnProperty('y');\n var sideX = left;\n var sideY = top;\n var win = window;\n\n if (adaptive) {\n var offsetParent = getOffsetParent(popper);\n var heightProp = 'clientHeight';\n var widthProp = 'clientWidth';\n\n if (offsetParent === getWindow(popper)) {\n offsetParent = getDocumentElement(popper);\n\n if (getComputedStyle(offsetParent).position !== 'static' && position === 'absolute') {\n heightProp = 'scrollHeight';\n widthProp = 'scrollWidth';\n }\n } // $FlowFixMe[incompatible-cast]: force type refinement, we compare offsetParent with window above, but Flow doesn't detect it\n\n\n offsetParent = offsetParent;\n\n if (placement === top || (placement === left || placement === right) && variation === end) {\n sideY = bottom;\n var offsetY = isFixed && offsetParent === win && win.visualViewport ? win.visualViewport.height : // $FlowFixMe[prop-missing]\n offsetParent[heightProp];\n y -= offsetY - popperRect.height;\n y *= gpuAcceleration ? 1 : -1;\n }\n\n if (placement === left || (placement === top || placement === bottom) && variation === end) {\n sideX = right;\n var offsetX = isFixed && offsetParent === win && win.visualViewport ? win.visualViewport.width : // $FlowFixMe[prop-missing]\n offsetParent[widthProp];\n x -= offsetX - popperRect.width;\n x *= gpuAcceleration ? 1 : -1;\n }\n }\n\n var commonStyles = Object.assign({\n position: position\n }, adaptive && unsetSides);\n\n var _ref4 = roundOffsets === true ? roundOffsetsByDPR({\n x: x,\n y: y\n }, getWindow(popper)) : {\n x: x,\n y: y\n };\n\n x = _ref4.x;\n y = _ref4.y;\n\n if (gpuAcceleration) {\n var _Object$assign;\n\n return Object.assign({}, commonStyles, (_Object$assign = {}, _Object$assign[sideY] = hasY ? '0' : '', _Object$assign[sideX] = hasX ? '0' : '', _Object$assign.transform = (win.devicePixelRatio || 1) <= 1 ? \"translate(\" + x + \"px, \" + y + \"px)\" : \"translate3d(\" + x + \"px, \" + y + \"px, 0)\", _Object$assign));\n }\n\n return Object.assign({}, commonStyles, (_Object$assign2 = {}, _Object$assign2[sideY] = hasY ? y + \"px\" : '', _Object$assign2[sideX] = hasX ? x + \"px\" : '', _Object$assign2.transform = '', _Object$assign2));\n}\n\nfunction computeStyles(_ref5) {\n var state = _ref5.state,\n options = _ref5.options;\n var _options$gpuAccelerat = options.gpuAcceleration,\n gpuAcceleration = _options$gpuAccelerat === void 0 ? true : _options$gpuAccelerat,\n _options$adaptive = options.adaptive,\n adaptive = _options$adaptive === void 0 ? true : _options$adaptive,\n _options$roundOffsets = options.roundOffsets,\n roundOffsets = _options$roundOffsets === void 0 ? true : _options$roundOffsets;\n var commonStyles = {\n placement: getBasePlacement(state.placement),\n variation: getVariation(state.placement),\n popper: state.elements.popper,\n popperRect: state.rects.popper,\n gpuAcceleration: gpuAcceleration,\n isFixed: state.options.strategy === 'fixed'\n };\n\n if (state.modifiersData.popperOffsets != null) {\n state.styles.popper = Object.assign({}, state.styles.popper, mapToStyles(Object.assign({}, commonStyles, {\n offsets: state.modifiersData.popperOffsets,\n position: state.options.strategy,\n adaptive: adaptive,\n roundOffsets: roundOffsets\n })));\n }\n\n if (state.modifiersData.arrow != null) {\n state.styles.arrow = Object.assign({}, state.styles.arrow, mapToStyles(Object.assign({}, commonStyles, {\n offsets: state.modifiersData.arrow,\n position: 'absolute',\n adaptive: false,\n roundOffsets: roundOffsets\n })));\n }\n\n state.attributes.popper = Object.assign({}, state.attributes.popper, {\n 'data-popper-placement': state.placement\n });\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'computeStyles',\n enabled: true,\n phase: 'beforeWrite',\n fn: computeStyles,\n data: {}\n};","import getWindow from \"../dom-utils/getWindow.js\"; // eslint-disable-next-line import/no-unused-modules\n\nvar passive = {\n passive: true\n};\n\nfunction effect(_ref) {\n var state = _ref.state,\n instance = _ref.instance,\n options = _ref.options;\n var _options$scroll = options.scroll,\n scroll = _options$scroll === void 0 ? true : _options$scroll,\n _options$resize = options.resize,\n resize = _options$resize === void 0 ? true : _options$resize;\n var window = getWindow(state.elements.popper);\n var scrollParents = [].concat(state.scrollParents.reference, state.scrollParents.popper);\n\n if (scroll) {\n scrollParents.forEach(function (scrollParent) {\n scrollParent.addEventListener('scroll', instance.update, passive);\n });\n }\n\n if (resize) {\n window.addEventListener('resize', instance.update, passive);\n }\n\n return function () {\n if (scroll) {\n scrollParents.forEach(function (scrollParent) {\n scrollParent.removeEventListener('scroll', instance.update, passive);\n });\n }\n\n if (resize) {\n window.removeEventListener('resize', instance.update, passive);\n }\n };\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'eventListeners',\n enabled: true,\n phase: 'write',\n fn: function fn() {},\n effect: effect,\n data: {}\n};","var hash = {\n left: 'right',\n right: 'left',\n bottom: 'top',\n top: 'bottom'\n};\nexport default function getOppositePlacement(placement) {\n return placement.replace(/left|right|bottom|top/g, function (matched) {\n return hash[matched];\n });\n}","var hash = {\n start: 'end',\n end: 'start'\n};\nexport default function getOppositeVariationPlacement(placement) {\n return placement.replace(/start|end/g, function (matched) {\n return hash[matched];\n });\n}","import getWindow from \"./getWindow.js\";\nexport default function getWindowScroll(node) {\n var win = getWindow(node);\n var scrollLeft = win.pageXOffset;\n var scrollTop = win.pageYOffset;\n return {\n scrollLeft: scrollLeft,\n scrollTop: scrollTop\n };\n}","import getBoundingClientRect from \"./getBoundingClientRect.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport getWindowScroll from \"./getWindowScroll.js\";\nexport default function getWindowScrollBarX(element) {\n // If has a CSS width greater than the viewport, then this will be\n // incorrect for RTL.\n // Popper 1 is broken in this case and never had a bug report so let's assume\n // it's not an issue. I don't think anyone ever specifies width on \n // anyway.\n // Browsers where the left scrollbar doesn't cause an issue report `0` for\n // this (e.g. Edge 2019, IE11, Safari)\n return getBoundingClientRect(getDocumentElement(element)).left + getWindowScroll(element).scrollLeft;\n}","import getWindow from \"./getWindow.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport getWindowScrollBarX from \"./getWindowScrollBarX.js\";\nimport isLayoutViewport from \"./isLayoutViewport.js\";\nexport default function getViewportRect(element, strategy) {\n var win = getWindow(element);\n var html = getDocumentElement(element);\n var visualViewport = win.visualViewport;\n var width = html.clientWidth;\n var height = html.clientHeight;\n var x = 0;\n var y = 0;\n\n if (visualViewport) {\n width = visualViewport.width;\n height = visualViewport.height;\n var layoutViewport = isLayoutViewport();\n\n if (layoutViewport || !layoutViewport && strategy === 'fixed') {\n x = visualViewport.offsetLeft;\n y = visualViewport.offsetTop;\n }\n }\n\n return {\n width: width,\n height: height,\n x: x + getWindowScrollBarX(element),\n y: y\n };\n}","import getDocumentElement from \"./getDocumentElement.js\";\nimport getComputedStyle from \"./getComputedStyle.js\";\nimport getWindowScrollBarX from \"./getWindowScrollBarX.js\";\nimport getWindowScroll from \"./getWindowScroll.js\";\nimport { max } from \"../utils/math.js\"; // Gets the entire size of the scrollable document area, even extending outside\n// of the `` and `` rect bounds if horizontally scrollable\n\nexport default function getDocumentRect(element) {\n var _element$ownerDocumen;\n\n var html = getDocumentElement(element);\n var winScroll = getWindowScroll(element);\n var body = (_element$ownerDocumen = element.ownerDocument) == null ? void 0 : _element$ownerDocumen.body;\n var width = max(html.scrollWidth, html.clientWidth, body ? body.scrollWidth : 0, body ? body.clientWidth : 0);\n var height = max(html.scrollHeight, html.clientHeight, body ? body.scrollHeight : 0, body ? body.clientHeight : 0);\n var x = -winScroll.scrollLeft + getWindowScrollBarX(element);\n var y = -winScroll.scrollTop;\n\n if (getComputedStyle(body || html).direction === 'rtl') {\n x += max(html.clientWidth, body ? body.clientWidth : 0) - width;\n }\n\n return {\n width: width,\n height: height,\n x: x,\n y: y\n };\n}","import getComputedStyle from \"./getComputedStyle.js\";\nexport default function isScrollParent(element) {\n // Firefox wants us to check `-x` and `-y` variations as well\n var _getComputedStyle = getComputedStyle(element),\n overflow = _getComputedStyle.overflow,\n overflowX = _getComputedStyle.overflowX,\n overflowY = _getComputedStyle.overflowY;\n\n return /auto|scroll|overlay|hidden/.test(overflow + overflowY + overflowX);\n}","import getParentNode from \"./getParentNode.js\";\nimport isScrollParent from \"./isScrollParent.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport { isHTMLElement } from \"./instanceOf.js\";\nexport default function getScrollParent(node) {\n if (['html', 'body', '#document'].indexOf(getNodeName(node)) >= 0) {\n // $FlowFixMe[incompatible-return]: assume body is always available\n return node.ownerDocument.body;\n }\n\n if (isHTMLElement(node) && isScrollParent(node)) {\n return node;\n }\n\n return getScrollParent(getParentNode(node));\n}","import getScrollParent from \"./getScrollParent.js\";\nimport getParentNode from \"./getParentNode.js\";\nimport getWindow from \"./getWindow.js\";\nimport isScrollParent from \"./isScrollParent.js\";\n/*\ngiven a DOM element, return the list of all scroll parents, up the list of ancesors\nuntil we get to the top window object. This list is what we attach scroll listeners\nto, because if any of these parent elements scroll, we'll need to re-calculate the\nreference element's position.\n*/\n\nexport default function listScrollParents(element, list) {\n var _element$ownerDocumen;\n\n if (list === void 0) {\n list = [];\n }\n\n var scrollParent = getScrollParent(element);\n var isBody = scrollParent === ((_element$ownerDocumen = element.ownerDocument) == null ? void 0 : _element$ownerDocumen.body);\n var win = getWindow(scrollParent);\n var target = isBody ? [win].concat(win.visualViewport || [], isScrollParent(scrollParent) ? scrollParent : []) : scrollParent;\n var updatedList = list.concat(target);\n return isBody ? updatedList : // $FlowFixMe[incompatible-call]: isBody tells us target will be an HTMLElement here\n updatedList.concat(listScrollParents(getParentNode(target)));\n}","export default function rectToClientRect(rect) {\n return Object.assign({}, rect, {\n left: rect.x,\n top: rect.y,\n right: rect.x + rect.width,\n bottom: rect.y + rect.height\n });\n}","import { viewport } from \"../enums.js\";\nimport getViewportRect from \"./getViewportRect.js\";\nimport getDocumentRect from \"./getDocumentRect.js\";\nimport listScrollParents from \"./listScrollParents.js\";\nimport getOffsetParent from \"./getOffsetParent.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport getComputedStyle from \"./getComputedStyle.js\";\nimport { isElement, isHTMLElement } from \"./instanceOf.js\";\nimport getBoundingClientRect from \"./getBoundingClientRect.js\";\nimport getParentNode from \"./getParentNode.js\";\nimport contains from \"./contains.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport rectToClientRect from \"../utils/rectToClientRect.js\";\nimport { max, min } from \"../utils/math.js\";\n\nfunction getInnerBoundingClientRect(element, strategy) {\n var rect = getBoundingClientRect(element, false, strategy === 'fixed');\n rect.top = rect.top + element.clientTop;\n rect.left = rect.left + element.clientLeft;\n rect.bottom = rect.top + element.clientHeight;\n rect.right = rect.left + element.clientWidth;\n rect.width = element.clientWidth;\n rect.height = element.clientHeight;\n rect.x = rect.left;\n rect.y = rect.top;\n return rect;\n}\n\nfunction getClientRectFromMixedType(element, clippingParent, strategy) {\n return clippingParent === viewport ? rectToClientRect(getViewportRect(element, strategy)) : isElement(clippingParent) ? getInnerBoundingClientRect(clippingParent, strategy) : rectToClientRect(getDocumentRect(getDocumentElement(element)));\n} // A \"clipping parent\" is an overflowable container with the characteristic of\n// clipping (or hiding) overflowing elements with a position different from\n// `initial`\n\n\nfunction getClippingParents(element) {\n var clippingParents = listScrollParents(getParentNode(element));\n var canEscapeClipping = ['absolute', 'fixed'].indexOf(getComputedStyle(element).position) >= 0;\n var clipperElement = canEscapeClipping && isHTMLElement(element) ? getOffsetParent(element) : element;\n\n if (!isElement(clipperElement)) {\n return [];\n } // $FlowFixMe[incompatible-return]: https://github.com/facebook/flow/issues/1414\n\n\n return clippingParents.filter(function (clippingParent) {\n return isElement(clippingParent) && contains(clippingParent, clipperElement) && getNodeName(clippingParent) !== 'body';\n });\n} // Gets the maximum area that the element is visible in due to any number of\n// clipping parents\n\n\nexport default function getClippingRect(element, boundary, rootBoundary, strategy) {\n var mainClippingParents = boundary === 'clippingParents' ? getClippingParents(element) : [].concat(boundary);\n var clippingParents = [].concat(mainClippingParents, [rootBoundary]);\n var firstClippingParent = clippingParents[0];\n var clippingRect = clippingParents.reduce(function (accRect, clippingParent) {\n var rect = getClientRectFromMixedType(element, clippingParent, strategy);\n accRect.top = max(rect.top, accRect.top);\n accRect.right = min(rect.right, accRect.right);\n accRect.bottom = min(rect.bottom, accRect.bottom);\n accRect.left = max(rect.left, accRect.left);\n return accRect;\n }, getClientRectFromMixedType(element, firstClippingParent, strategy));\n clippingRect.width = clippingRect.right - clippingRect.left;\n clippingRect.height = clippingRect.bottom - clippingRect.top;\n clippingRect.x = clippingRect.left;\n clippingRect.y = clippingRect.top;\n return clippingRect;\n}","import getBasePlacement from \"./getBasePlacement.js\";\nimport getVariation from \"./getVariation.js\";\nimport getMainAxisFromPlacement from \"./getMainAxisFromPlacement.js\";\nimport { top, right, bottom, left, start, end } from \"../enums.js\";\nexport default function computeOffsets(_ref) {\n var reference = _ref.reference,\n element = _ref.element,\n placement = _ref.placement;\n var basePlacement = placement ? getBasePlacement(placement) : null;\n var variation = placement ? getVariation(placement) : null;\n var commonX = reference.x + reference.width / 2 - element.width / 2;\n var commonY = reference.y + reference.height / 2 - element.height / 2;\n var offsets;\n\n switch (basePlacement) {\n case top:\n offsets = {\n x: commonX,\n y: reference.y - element.height\n };\n break;\n\n case bottom:\n offsets = {\n x: commonX,\n y: reference.y + reference.height\n };\n break;\n\n case right:\n offsets = {\n x: reference.x + reference.width,\n y: commonY\n };\n break;\n\n case left:\n offsets = {\n x: reference.x - element.width,\n y: commonY\n };\n break;\n\n default:\n offsets = {\n x: reference.x,\n y: reference.y\n };\n }\n\n var mainAxis = basePlacement ? getMainAxisFromPlacement(basePlacement) : null;\n\n if (mainAxis != null) {\n var len = mainAxis === 'y' ? 'height' : 'width';\n\n switch (variation) {\n case start:\n offsets[mainAxis] = offsets[mainAxis] - (reference[len] / 2 - element[len] / 2);\n break;\n\n case end:\n offsets[mainAxis] = offsets[mainAxis] + (reference[len] / 2 - element[len] / 2);\n break;\n\n default:\n }\n }\n\n return offsets;\n}","import getClippingRect from \"../dom-utils/getClippingRect.js\";\nimport getDocumentElement from \"../dom-utils/getDocumentElement.js\";\nimport getBoundingClientRect from \"../dom-utils/getBoundingClientRect.js\";\nimport computeOffsets from \"./computeOffsets.js\";\nimport rectToClientRect from \"./rectToClientRect.js\";\nimport { clippingParents, reference, popper, bottom, top, right, basePlacements, viewport } from \"../enums.js\";\nimport { isElement } from \"../dom-utils/instanceOf.js\";\nimport mergePaddingObject from \"./mergePaddingObject.js\";\nimport expandToHashMap from \"./expandToHashMap.js\"; // eslint-disable-next-line import/no-unused-modules\n\nexport default function detectOverflow(state, options) {\n if (options === void 0) {\n options = {};\n }\n\n var _options = options,\n _options$placement = _options.placement,\n placement = _options$placement === void 0 ? state.placement : _options$placement,\n _options$strategy = _options.strategy,\n strategy = _options$strategy === void 0 ? state.strategy : _options$strategy,\n _options$boundary = _options.boundary,\n boundary = _options$boundary === void 0 ? clippingParents : _options$boundary,\n _options$rootBoundary = _options.rootBoundary,\n rootBoundary = _options$rootBoundary === void 0 ? viewport : _options$rootBoundary,\n _options$elementConte = _options.elementContext,\n elementContext = _options$elementConte === void 0 ? popper : _options$elementConte,\n _options$altBoundary = _options.altBoundary,\n altBoundary = _options$altBoundary === void 0 ? false : _options$altBoundary,\n _options$padding = _options.padding,\n padding = _options$padding === void 0 ? 0 : _options$padding;\n var paddingObject = mergePaddingObject(typeof padding !== 'number' ? padding : expandToHashMap(padding, basePlacements));\n var altContext = elementContext === popper ? reference : popper;\n var popperRect = state.rects.popper;\n var element = state.elements[altBoundary ? altContext : elementContext];\n var clippingClientRect = getClippingRect(isElement(element) ? element : element.contextElement || getDocumentElement(state.elements.popper), boundary, rootBoundary, strategy);\n var referenceClientRect = getBoundingClientRect(state.elements.reference);\n var popperOffsets = computeOffsets({\n reference: referenceClientRect,\n element: popperRect,\n strategy: 'absolute',\n placement: placement\n });\n var popperClientRect = rectToClientRect(Object.assign({}, popperRect, popperOffsets));\n var elementClientRect = elementContext === popper ? popperClientRect : referenceClientRect; // positive = overflowing the clipping rect\n // 0 or negative = within the clipping rect\n\n var overflowOffsets = {\n top: clippingClientRect.top - elementClientRect.top + paddingObject.top,\n bottom: elementClientRect.bottom - clippingClientRect.bottom + paddingObject.bottom,\n left: clippingClientRect.left - elementClientRect.left + paddingObject.left,\n right: elementClientRect.right - clippingClientRect.right + paddingObject.right\n };\n var offsetData = state.modifiersData.offset; // Offsets can be applied only to the popper element\n\n if (elementContext === popper && offsetData) {\n var offset = offsetData[placement];\n Object.keys(overflowOffsets).forEach(function (key) {\n var multiply = [right, bottom].indexOf(key) >= 0 ? 1 : -1;\n var axis = [top, bottom].indexOf(key) >= 0 ? 'y' : 'x';\n overflowOffsets[key] += offset[axis] * multiply;\n });\n }\n\n return overflowOffsets;\n}","import getVariation from \"./getVariation.js\";\nimport { variationPlacements, basePlacements, placements as allPlacements } from \"../enums.js\";\nimport detectOverflow from \"./detectOverflow.js\";\nimport getBasePlacement from \"./getBasePlacement.js\";\nexport default function computeAutoPlacement(state, options) {\n if (options === void 0) {\n options = {};\n }\n\n var _options = options,\n placement = _options.placement,\n boundary = _options.boundary,\n rootBoundary = _options.rootBoundary,\n padding = _options.padding,\n flipVariations = _options.flipVariations,\n _options$allowedAutoP = _options.allowedAutoPlacements,\n allowedAutoPlacements = _options$allowedAutoP === void 0 ? allPlacements : _options$allowedAutoP;\n var variation = getVariation(placement);\n var placements = variation ? flipVariations ? variationPlacements : variationPlacements.filter(function (placement) {\n return getVariation(placement) === variation;\n }) : basePlacements;\n var allowedPlacements = placements.filter(function (placement) {\n return allowedAutoPlacements.indexOf(placement) >= 0;\n });\n\n if (allowedPlacements.length === 0) {\n allowedPlacements = placements;\n } // $FlowFixMe[incompatible-type]: Flow seems to have problems with two array unions...\n\n\n var overflows = allowedPlacements.reduce(function (acc, placement) {\n acc[placement] = detectOverflow(state, {\n placement: placement,\n boundary: boundary,\n rootBoundary: rootBoundary,\n padding: padding\n })[getBasePlacement(placement)];\n return acc;\n }, {});\n return Object.keys(overflows).sort(function (a, b) {\n return overflows[a] - overflows[b];\n });\n}","import getOppositePlacement from \"../utils/getOppositePlacement.js\";\nimport getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getOppositeVariationPlacement from \"../utils/getOppositeVariationPlacement.js\";\nimport detectOverflow from \"../utils/detectOverflow.js\";\nimport computeAutoPlacement from \"../utils/computeAutoPlacement.js\";\nimport { bottom, top, start, right, left, auto } from \"../enums.js\";\nimport getVariation from \"../utils/getVariation.js\"; // eslint-disable-next-line import/no-unused-modules\n\nfunction getExpandedFallbackPlacements(placement) {\n if (getBasePlacement(placement) === auto) {\n return [];\n }\n\n var oppositePlacement = getOppositePlacement(placement);\n return [getOppositeVariationPlacement(placement), oppositePlacement, getOppositeVariationPlacement(oppositePlacement)];\n}\n\nfunction flip(_ref) {\n var state = _ref.state,\n options = _ref.options,\n name = _ref.name;\n\n if (state.modifiersData[name]._skip) {\n return;\n }\n\n var _options$mainAxis = options.mainAxis,\n checkMainAxis = _options$mainAxis === void 0 ? true : _options$mainAxis,\n _options$altAxis = options.altAxis,\n checkAltAxis = _options$altAxis === void 0 ? true : _options$altAxis,\n specifiedFallbackPlacements = options.fallbackPlacements,\n padding = options.padding,\n boundary = options.boundary,\n rootBoundary = options.rootBoundary,\n altBoundary = options.altBoundary,\n _options$flipVariatio = options.flipVariations,\n flipVariations = _options$flipVariatio === void 0 ? true : _options$flipVariatio,\n allowedAutoPlacements = options.allowedAutoPlacements;\n var preferredPlacement = state.options.placement;\n var basePlacement = getBasePlacement(preferredPlacement);\n var isBasePlacement = basePlacement === preferredPlacement;\n var fallbackPlacements = specifiedFallbackPlacements || (isBasePlacement || !flipVariations ? [getOppositePlacement(preferredPlacement)] : getExpandedFallbackPlacements(preferredPlacement));\n var placements = [preferredPlacement].concat(fallbackPlacements).reduce(function (acc, placement) {\n return acc.concat(getBasePlacement(placement) === auto ? computeAutoPlacement(state, {\n placement: placement,\n boundary: boundary,\n rootBoundary: rootBoundary,\n padding: padding,\n flipVariations: flipVariations,\n allowedAutoPlacements: allowedAutoPlacements\n }) : placement);\n }, []);\n var referenceRect = state.rects.reference;\n var popperRect = state.rects.popper;\n var checksMap = new Map();\n var makeFallbackChecks = true;\n var firstFittingPlacement = placements[0];\n\n for (var i = 0; i < placements.length; i++) {\n var placement = placements[i];\n\n var _basePlacement = getBasePlacement(placement);\n\n var isStartVariation = getVariation(placement) === start;\n var isVertical = [top, bottom].indexOf(_basePlacement) >= 0;\n var len = isVertical ? 'width' : 'height';\n var overflow = detectOverflow(state, {\n placement: placement,\n boundary: boundary,\n rootBoundary: rootBoundary,\n altBoundary: altBoundary,\n padding: padding\n });\n var mainVariationSide = isVertical ? isStartVariation ? right : left : isStartVariation ? bottom : top;\n\n if (referenceRect[len] > popperRect[len]) {\n mainVariationSide = getOppositePlacement(mainVariationSide);\n }\n\n var altVariationSide = getOppositePlacement(mainVariationSide);\n var checks = [];\n\n if (checkMainAxis) {\n checks.push(overflow[_basePlacement] <= 0);\n }\n\n if (checkAltAxis) {\n checks.push(overflow[mainVariationSide] <= 0, overflow[altVariationSide] <= 0);\n }\n\n if (checks.every(function (check) {\n return check;\n })) {\n firstFittingPlacement = placement;\n makeFallbackChecks = false;\n break;\n }\n\n checksMap.set(placement, checks);\n }\n\n if (makeFallbackChecks) {\n // `2` may be desired in some cases – research later\n var numberOfChecks = flipVariations ? 3 : 1;\n\n var _loop = function _loop(_i) {\n var fittingPlacement = placements.find(function (placement) {\n var checks = checksMap.get(placement);\n\n if (checks) {\n return checks.slice(0, _i).every(function (check) {\n return check;\n });\n }\n });\n\n if (fittingPlacement) {\n firstFittingPlacement = fittingPlacement;\n return \"break\";\n }\n };\n\n for (var _i = numberOfChecks; _i > 0; _i--) {\n var _ret = _loop(_i);\n\n if (_ret === \"break\") break;\n }\n }\n\n if (state.placement !== firstFittingPlacement) {\n state.modifiersData[name]._skip = true;\n state.placement = firstFittingPlacement;\n state.reset = true;\n }\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'flip',\n enabled: true,\n phase: 'main',\n fn: flip,\n requiresIfExists: ['offset'],\n data: {\n _skip: false\n }\n};","import { top, bottom, left, right } from \"../enums.js\";\nimport detectOverflow from \"../utils/detectOverflow.js\";\n\nfunction getSideOffsets(overflow, rect, preventedOffsets) {\n if (preventedOffsets === void 0) {\n preventedOffsets = {\n x: 0,\n y: 0\n };\n }\n\n return {\n top: overflow.top - rect.height - preventedOffsets.y,\n right: overflow.right - rect.width + preventedOffsets.x,\n bottom: overflow.bottom - rect.height + preventedOffsets.y,\n left: overflow.left - rect.width - preventedOffsets.x\n };\n}\n\nfunction isAnySideFullyClipped(overflow) {\n return [top, right, bottom, left].some(function (side) {\n return overflow[side] >= 0;\n });\n}\n\nfunction hide(_ref) {\n var state = _ref.state,\n name = _ref.name;\n var referenceRect = state.rects.reference;\n var popperRect = state.rects.popper;\n var preventedOffsets = state.modifiersData.preventOverflow;\n var referenceOverflow = detectOverflow(state, {\n elementContext: 'reference'\n });\n var popperAltOverflow = detectOverflow(state, {\n altBoundary: true\n });\n var referenceClippingOffsets = getSideOffsets(referenceOverflow, referenceRect);\n var popperEscapeOffsets = getSideOffsets(popperAltOverflow, popperRect, preventedOffsets);\n var isReferenceHidden = isAnySideFullyClipped(referenceClippingOffsets);\n var hasPopperEscaped = isAnySideFullyClipped(popperEscapeOffsets);\n state.modifiersData[name] = {\n referenceClippingOffsets: referenceClippingOffsets,\n popperEscapeOffsets: popperEscapeOffsets,\n isReferenceHidden: isReferenceHidden,\n hasPopperEscaped: hasPopperEscaped\n };\n state.attributes.popper = Object.assign({}, state.attributes.popper, {\n 'data-popper-reference-hidden': isReferenceHidden,\n 'data-popper-escaped': hasPopperEscaped\n });\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'hide',\n enabled: true,\n phase: 'main',\n requiresIfExists: ['preventOverflow'],\n fn: hide\n};","import getBasePlacement from \"../utils/getBasePlacement.js\";\nimport { top, left, right, placements } from \"../enums.js\"; // eslint-disable-next-line import/no-unused-modules\n\nexport function distanceAndSkiddingToXY(placement, rects, offset) {\n var basePlacement = getBasePlacement(placement);\n var invertDistance = [left, top].indexOf(basePlacement) >= 0 ? -1 : 1;\n\n var _ref = typeof offset === 'function' ? offset(Object.assign({}, rects, {\n placement: placement\n })) : offset,\n skidding = _ref[0],\n distance = _ref[1];\n\n skidding = skidding || 0;\n distance = (distance || 0) * invertDistance;\n return [left, right].indexOf(basePlacement) >= 0 ? {\n x: distance,\n y: skidding\n } : {\n x: skidding,\n y: distance\n };\n}\n\nfunction offset(_ref2) {\n var state = _ref2.state,\n options = _ref2.options,\n name = _ref2.name;\n var _options$offset = options.offset,\n offset = _options$offset === void 0 ? [0, 0] : _options$offset;\n var data = placements.reduce(function (acc, placement) {\n acc[placement] = distanceAndSkiddingToXY(placement, state.rects, offset);\n return acc;\n }, {});\n var _data$state$placement = data[state.placement],\n x = _data$state$placement.x,\n y = _data$state$placement.y;\n\n if (state.modifiersData.popperOffsets != null) {\n state.modifiersData.popperOffsets.x += x;\n state.modifiersData.popperOffsets.y += y;\n }\n\n state.modifiersData[name] = data;\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'offset',\n enabled: true,\n phase: 'main',\n requires: ['popperOffsets'],\n fn: offset\n};","import computeOffsets from \"../utils/computeOffsets.js\";\n\nfunction popperOffsets(_ref) {\n var state = _ref.state,\n name = _ref.name;\n // Offsets are the actual position the popper needs to have to be\n // properly positioned near its reference element\n // This is the most basic placement, and will be adjusted by\n // the modifiers in the next step\n state.modifiersData[name] = computeOffsets({\n reference: state.rects.reference,\n element: state.rects.popper,\n strategy: 'absolute',\n placement: state.placement\n });\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'popperOffsets',\n enabled: true,\n phase: 'read',\n fn: popperOffsets,\n data: {}\n};","export default function getAltAxis(axis) {\n return axis === 'x' ? 'y' : 'x';\n}","import { top, left, right, bottom, start } from \"../enums.js\";\nimport getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getMainAxisFromPlacement from \"../utils/getMainAxisFromPlacement.js\";\nimport getAltAxis from \"../utils/getAltAxis.js\";\nimport { within, withinMaxClamp } from \"../utils/within.js\";\nimport getLayoutRect from \"../dom-utils/getLayoutRect.js\";\nimport getOffsetParent from \"../dom-utils/getOffsetParent.js\";\nimport detectOverflow from \"../utils/detectOverflow.js\";\nimport getVariation from \"../utils/getVariation.js\";\nimport getFreshSideObject from \"../utils/getFreshSideObject.js\";\nimport { min as mathMin, max as mathMax } from \"../utils/math.js\";\n\nfunction preventOverflow(_ref) {\n var state = _ref.state,\n options = _ref.options,\n name = _ref.name;\n var _options$mainAxis = options.mainAxis,\n checkMainAxis = _options$mainAxis === void 0 ? true : _options$mainAxis,\n _options$altAxis = options.altAxis,\n checkAltAxis = _options$altAxis === void 0 ? false : _options$altAxis,\n boundary = options.boundary,\n rootBoundary = options.rootBoundary,\n altBoundary = options.altBoundary,\n padding = options.padding,\n _options$tether = options.tether,\n tether = _options$tether === void 0 ? true : _options$tether,\n _options$tetherOffset = options.tetherOffset,\n tetherOffset = _options$tetherOffset === void 0 ? 0 : _options$tetherOffset;\n var overflow = detectOverflow(state, {\n boundary: boundary,\n rootBoundary: rootBoundary,\n padding: padding,\n altBoundary: altBoundary\n });\n var basePlacement = getBasePlacement(state.placement);\n var variation = getVariation(state.placement);\n var isBasePlacement = !variation;\n var mainAxis = getMainAxisFromPlacement(basePlacement);\n var altAxis = getAltAxis(mainAxis);\n var popperOffsets = state.modifiersData.popperOffsets;\n var referenceRect = state.rects.reference;\n var popperRect = state.rects.popper;\n var tetherOffsetValue = typeof tetherOffset === 'function' ? tetherOffset(Object.assign({}, state.rects, {\n placement: state.placement\n })) : tetherOffset;\n var normalizedTetherOffsetValue = typeof tetherOffsetValue === 'number' ? {\n mainAxis: tetherOffsetValue,\n altAxis: tetherOffsetValue\n } : Object.assign({\n mainAxis: 0,\n altAxis: 0\n }, tetherOffsetValue);\n var offsetModifierState = state.modifiersData.offset ? state.modifiersData.offset[state.placement] : null;\n var data = {\n x: 0,\n y: 0\n };\n\n if (!popperOffsets) {\n return;\n }\n\n if (checkMainAxis) {\n var _offsetModifierState$;\n\n var mainSide = mainAxis === 'y' ? top : left;\n var altSide = mainAxis === 'y' ? bottom : right;\n var len = mainAxis === 'y' ? 'height' : 'width';\n var offset = popperOffsets[mainAxis];\n var min = offset + overflow[mainSide];\n var max = offset - overflow[altSide];\n var additive = tether ? -popperRect[len] / 2 : 0;\n var minLen = variation === start ? referenceRect[len] : popperRect[len];\n var maxLen = variation === start ? -popperRect[len] : -referenceRect[len]; // We need to include the arrow in the calculation so the arrow doesn't go\n // outside the reference bounds\n\n var arrowElement = state.elements.arrow;\n var arrowRect = tether && arrowElement ? getLayoutRect(arrowElement) : {\n width: 0,\n height: 0\n };\n var arrowPaddingObject = state.modifiersData['arrow#persistent'] ? state.modifiersData['arrow#persistent'].padding : getFreshSideObject();\n var arrowPaddingMin = arrowPaddingObject[mainSide];\n var arrowPaddingMax = arrowPaddingObject[altSide]; // If the reference length is smaller than the arrow length, we don't want\n // to include its full size in the calculation. If the reference is small\n // and near the edge of a boundary, the popper can overflow even if the\n // reference is not overflowing as well (e.g. virtual elements with no\n // width or height)\n\n var arrowLen = within(0, referenceRect[len], arrowRect[len]);\n var minOffset = isBasePlacement ? referenceRect[len] / 2 - additive - arrowLen - arrowPaddingMin - normalizedTetherOffsetValue.mainAxis : minLen - arrowLen - arrowPaddingMin - normalizedTetherOffsetValue.mainAxis;\n var maxOffset = isBasePlacement ? -referenceRect[len] / 2 + additive + arrowLen + arrowPaddingMax + normalizedTetherOffsetValue.mainAxis : maxLen + arrowLen + arrowPaddingMax + normalizedTetherOffsetValue.mainAxis;\n var arrowOffsetParent = state.elements.arrow && getOffsetParent(state.elements.arrow);\n var clientOffset = arrowOffsetParent ? mainAxis === 'y' ? arrowOffsetParent.clientTop || 0 : arrowOffsetParent.clientLeft || 0 : 0;\n var offsetModifierValue = (_offsetModifierState$ = offsetModifierState == null ? void 0 : offsetModifierState[mainAxis]) != null ? _offsetModifierState$ : 0;\n var tetherMin = offset + minOffset - offsetModifierValue - clientOffset;\n var tetherMax = offset + maxOffset - offsetModifierValue;\n var preventedOffset = within(tether ? mathMin(min, tetherMin) : min, offset, tether ? mathMax(max, tetherMax) : max);\n popperOffsets[mainAxis] = preventedOffset;\n data[mainAxis] = preventedOffset - offset;\n }\n\n if (checkAltAxis) {\n var _offsetModifierState$2;\n\n var _mainSide = mainAxis === 'x' ? top : left;\n\n var _altSide = mainAxis === 'x' ? bottom : right;\n\n var _offset = popperOffsets[altAxis];\n\n var _len = altAxis === 'y' ? 'height' : 'width';\n\n var _min = _offset + overflow[_mainSide];\n\n var _max = _offset - overflow[_altSide];\n\n var isOriginSide = [top, left].indexOf(basePlacement) !== -1;\n\n var _offsetModifierValue = (_offsetModifierState$2 = offsetModifierState == null ? void 0 : offsetModifierState[altAxis]) != null ? _offsetModifierState$2 : 0;\n\n var _tetherMin = isOriginSide ? _min : _offset - referenceRect[_len] - popperRect[_len] - _offsetModifierValue + normalizedTetherOffsetValue.altAxis;\n\n var _tetherMax = isOriginSide ? _offset + referenceRect[_len] + popperRect[_len] - _offsetModifierValue - normalizedTetherOffsetValue.altAxis : _max;\n\n var _preventedOffset = tether && isOriginSide ? withinMaxClamp(_tetherMin, _offset, _tetherMax) : within(tether ? _tetherMin : _min, _offset, tether ? _tetherMax : _max);\n\n popperOffsets[altAxis] = _preventedOffset;\n data[altAxis] = _preventedOffset - _offset;\n }\n\n state.modifiersData[name] = data;\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'preventOverflow',\n enabled: true,\n phase: 'main',\n fn: preventOverflow,\n requiresIfExists: ['offset']\n};","export default function getHTMLElementScroll(element) {\n return {\n scrollLeft: element.scrollLeft,\n scrollTop: element.scrollTop\n };\n}","import getWindowScroll from \"./getWindowScroll.js\";\nimport getWindow from \"./getWindow.js\";\nimport { isHTMLElement } from \"./instanceOf.js\";\nimport getHTMLElementScroll from \"./getHTMLElementScroll.js\";\nexport default function getNodeScroll(node) {\n if (node === getWindow(node) || !isHTMLElement(node)) {\n return getWindowScroll(node);\n } else {\n return getHTMLElementScroll(node);\n }\n}","import getBoundingClientRect from \"./getBoundingClientRect.js\";\nimport getNodeScroll from \"./getNodeScroll.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport { isHTMLElement } from \"./instanceOf.js\";\nimport getWindowScrollBarX from \"./getWindowScrollBarX.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport isScrollParent from \"./isScrollParent.js\";\nimport { round } from \"../utils/math.js\";\n\nfunction isElementScaled(element) {\n var rect = element.getBoundingClientRect();\n var scaleX = round(rect.width) / element.offsetWidth || 1;\n var scaleY = round(rect.height) / element.offsetHeight || 1;\n return scaleX !== 1 || scaleY !== 1;\n} // Returns the composite rect of an element relative to its offsetParent.\n// Composite means it takes into account transforms as well as layout.\n\n\nexport default function getCompositeRect(elementOrVirtualElement, offsetParent, isFixed) {\n if (isFixed === void 0) {\n isFixed = false;\n }\n\n var isOffsetParentAnElement = isHTMLElement(offsetParent);\n var offsetParentIsScaled = isHTMLElement(offsetParent) && isElementScaled(offsetParent);\n var documentElement = getDocumentElement(offsetParent);\n var rect = getBoundingClientRect(elementOrVirtualElement, offsetParentIsScaled, isFixed);\n var scroll = {\n scrollLeft: 0,\n scrollTop: 0\n };\n var offsets = {\n x: 0,\n y: 0\n };\n\n if (isOffsetParentAnElement || !isOffsetParentAnElement && !isFixed) {\n if (getNodeName(offsetParent) !== 'body' || // https://github.com/popperjs/popper-core/issues/1078\n isScrollParent(documentElement)) {\n scroll = getNodeScroll(offsetParent);\n }\n\n if (isHTMLElement(offsetParent)) {\n offsets = getBoundingClientRect(offsetParent, true);\n offsets.x += offsetParent.clientLeft;\n offsets.y += offsetParent.clientTop;\n } else if (documentElement) {\n offsets.x = getWindowScrollBarX(documentElement);\n }\n }\n\n return {\n x: rect.left + scroll.scrollLeft - offsets.x,\n y: rect.top + scroll.scrollTop - offsets.y,\n width: rect.width,\n height: rect.height\n };\n}","import { modifierPhases } from \"../enums.js\"; // source: https://stackoverflow.com/questions/49875255\n\nfunction order(modifiers) {\n var map = new Map();\n var visited = new Set();\n var result = [];\n modifiers.forEach(function (modifier) {\n map.set(modifier.name, modifier);\n }); // On visiting object, check for its dependencies and visit them recursively\n\n function sort(modifier) {\n visited.add(modifier.name);\n var requires = [].concat(modifier.requires || [], modifier.requiresIfExists || []);\n requires.forEach(function (dep) {\n if (!visited.has(dep)) {\n var depModifier = map.get(dep);\n\n if (depModifier) {\n sort(depModifier);\n }\n }\n });\n result.push(modifier);\n }\n\n modifiers.forEach(function (modifier) {\n if (!visited.has(modifier.name)) {\n // check for visited object\n sort(modifier);\n }\n });\n return result;\n}\n\nexport default function orderModifiers(modifiers) {\n // order based on dependencies\n var orderedModifiers = order(modifiers); // order based on phase\n\n return modifierPhases.reduce(function (acc, phase) {\n return acc.concat(orderedModifiers.filter(function (modifier) {\n return modifier.phase === phase;\n }));\n }, []);\n}","export default function debounce(fn) {\n var pending;\n return function () {\n if (!pending) {\n pending = new Promise(function (resolve) {\n Promise.resolve().then(function () {\n pending = undefined;\n resolve(fn());\n });\n });\n }\n\n return pending;\n };\n}","export default function mergeByName(modifiers) {\n var merged = modifiers.reduce(function (merged, current) {\n var existing = merged[current.name];\n merged[current.name] = existing ? Object.assign({}, existing, current, {\n options: Object.assign({}, existing.options, current.options),\n data: Object.assign({}, existing.data, current.data)\n }) : current;\n return merged;\n }, {}); // IE11 does not support Object.values\n\n return Object.keys(merged).map(function (key) {\n return merged[key];\n });\n}","import getCompositeRect from \"./dom-utils/getCompositeRect.js\";\nimport getLayoutRect from \"./dom-utils/getLayoutRect.js\";\nimport listScrollParents from \"./dom-utils/listScrollParents.js\";\nimport getOffsetParent from \"./dom-utils/getOffsetParent.js\";\nimport orderModifiers from \"./utils/orderModifiers.js\";\nimport debounce from \"./utils/debounce.js\";\nimport mergeByName from \"./utils/mergeByName.js\";\nimport detectOverflow from \"./utils/detectOverflow.js\";\nimport { isElement } from \"./dom-utils/instanceOf.js\";\nvar DEFAULT_OPTIONS = {\n placement: 'bottom',\n modifiers: [],\n strategy: 'absolute'\n};\n\nfunction areValidElements() {\n for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {\n args[_key] = arguments[_key];\n }\n\n return !args.some(function (element) {\n return !(element && typeof element.getBoundingClientRect === 'function');\n });\n}\n\nexport function popperGenerator(generatorOptions) {\n if (generatorOptions === void 0) {\n generatorOptions = {};\n }\n\n var _generatorOptions = generatorOptions,\n _generatorOptions$def = _generatorOptions.defaultModifiers,\n defaultModifiers = _generatorOptions$def === void 0 ? [] : _generatorOptions$def,\n _generatorOptions$def2 = _generatorOptions.defaultOptions,\n defaultOptions = _generatorOptions$def2 === void 0 ? DEFAULT_OPTIONS : _generatorOptions$def2;\n return function createPopper(reference, popper, options) {\n if (options === void 0) {\n options = defaultOptions;\n }\n\n var state = {\n placement: 'bottom',\n orderedModifiers: [],\n options: Object.assign({}, DEFAULT_OPTIONS, defaultOptions),\n modifiersData: {},\n elements: {\n reference: reference,\n popper: popper\n },\n attributes: {},\n styles: {}\n };\n var effectCleanupFns = [];\n var isDestroyed = false;\n var instance = {\n state: state,\n setOptions: function setOptions(setOptionsAction) {\n var options = typeof setOptionsAction === 'function' ? setOptionsAction(state.options) : setOptionsAction;\n cleanupModifierEffects();\n state.options = Object.assign({}, defaultOptions, state.options, options);\n state.scrollParents = {\n reference: isElement(reference) ? listScrollParents(reference) : reference.contextElement ? listScrollParents(reference.contextElement) : [],\n popper: listScrollParents(popper)\n }; // Orders the modifiers based on their dependencies and `phase`\n // properties\n\n var orderedModifiers = orderModifiers(mergeByName([].concat(defaultModifiers, state.options.modifiers))); // Strip out disabled modifiers\n\n state.orderedModifiers = orderedModifiers.filter(function (m) {\n return m.enabled;\n });\n runModifierEffects();\n return instance.update();\n },\n // Sync update – it will always be executed, even if not necessary. This\n // is useful for low frequency updates where sync behavior simplifies the\n // logic.\n // For high frequency updates (e.g. `resize` and `scroll` events), always\n // prefer the async Popper#update method\n forceUpdate: function forceUpdate() {\n if (isDestroyed) {\n return;\n }\n\n var _state$elements = state.elements,\n reference = _state$elements.reference,\n popper = _state$elements.popper; // Don't proceed if `reference` or `popper` are not valid elements\n // anymore\n\n if (!areValidElements(reference, popper)) {\n return;\n } // Store the reference and popper rects to be read by modifiers\n\n\n state.rects = {\n reference: getCompositeRect(reference, getOffsetParent(popper), state.options.strategy === 'fixed'),\n popper: getLayoutRect(popper)\n }; // Modifiers have the ability to reset the current update cycle. The\n // most common use case for this is the `flip` modifier changing the\n // placement, which then needs to re-run all the modifiers, because the\n // logic was previously ran for the previous placement and is therefore\n // stale/incorrect\n\n state.reset = false;\n state.placement = state.options.placement; // On each update cycle, the `modifiersData` property for each modifier\n // is filled with the initial data specified by the modifier. This means\n // it doesn't persist and is fresh on each update.\n // To ensure persistent data, use `${name}#persistent`\n\n state.orderedModifiers.forEach(function (modifier) {\n return state.modifiersData[modifier.name] = Object.assign({}, modifier.data);\n });\n\n for (var index = 0; index < state.orderedModifiers.length; index++) {\n if (state.reset === true) {\n state.reset = false;\n index = -1;\n continue;\n }\n\n var _state$orderedModifie = state.orderedModifiers[index],\n fn = _state$orderedModifie.fn,\n _state$orderedModifie2 = _state$orderedModifie.options,\n _options = _state$orderedModifie2 === void 0 ? {} : _state$orderedModifie2,\n name = _state$orderedModifie.name;\n\n if (typeof fn === 'function') {\n state = fn({\n state: state,\n options: _options,\n name: name,\n instance: instance\n }) || state;\n }\n }\n },\n // Async and optimistically optimized update – it will not be executed if\n // not necessary (debounced to run at most once-per-tick)\n update: debounce(function () {\n return new Promise(function (resolve) {\n instance.forceUpdate();\n resolve(state);\n });\n }),\n destroy: function destroy() {\n cleanupModifierEffects();\n isDestroyed = true;\n }\n };\n\n if (!areValidElements(reference, popper)) {\n return instance;\n }\n\n instance.setOptions(options).then(function (state) {\n if (!isDestroyed && options.onFirstUpdate) {\n options.onFirstUpdate(state);\n }\n }); // Modifiers have the ability to execute arbitrary code before the first\n // update cycle runs. They will be executed in the same order as the update\n // cycle. This is useful when a modifier adds some persistent data that\n // other modifiers need to use, but the modifier is run after the dependent\n // one.\n\n function runModifierEffects() {\n state.orderedModifiers.forEach(function (_ref) {\n var name = _ref.name,\n _ref$options = _ref.options,\n options = _ref$options === void 0 ? {} : _ref$options,\n effect = _ref.effect;\n\n if (typeof effect === 'function') {\n var cleanupFn = effect({\n state: state,\n name: name,\n instance: instance,\n options: options\n });\n\n var noopFn = function noopFn() {};\n\n effectCleanupFns.push(cleanupFn || noopFn);\n }\n });\n }\n\n function cleanupModifierEffects() {\n effectCleanupFns.forEach(function (fn) {\n return fn();\n });\n effectCleanupFns = [];\n }\n\n return instance;\n };\n}\nexport var createPopper = /*#__PURE__*/popperGenerator(); // eslint-disable-next-line import/no-unused-modules\n\nexport { detectOverflow };","import { popperGenerator, detectOverflow } from \"./createPopper.js\";\nimport eventListeners from \"./modifiers/eventListeners.js\";\nimport popperOffsets from \"./modifiers/popperOffsets.js\";\nimport computeStyles from \"./modifiers/computeStyles.js\";\nimport applyStyles from \"./modifiers/applyStyles.js\";\nimport offset from \"./modifiers/offset.js\";\nimport flip from \"./modifiers/flip.js\";\nimport preventOverflow from \"./modifiers/preventOverflow.js\";\nimport arrow from \"./modifiers/arrow.js\";\nimport hide from \"./modifiers/hide.js\";\nvar defaultModifiers = [eventListeners, popperOffsets, computeStyles, applyStyles, offset, flip, preventOverflow, arrow, hide];\nvar createPopper = /*#__PURE__*/popperGenerator({\n defaultModifiers: defaultModifiers\n}); // eslint-disable-next-line import/no-unused-modules\n\nexport { createPopper, popperGenerator, defaultModifiers, detectOverflow }; // eslint-disable-next-line import/no-unused-modules\n\nexport { createPopper as createPopperLite } from \"./popper-lite.js\"; // eslint-disable-next-line import/no-unused-modules\n\nexport * from \"./modifiers/index.js\";","import { generateUtilityClass } from '../generateUtilityClass';\nimport { generateUtilityClasses } from '../generateUtilityClasses';\nconst COMPONENT_NAME = 'Popper';\nexport function getPopperUtilityClass(slot) {\n return generateUtilityClass(COMPONENT_NAME, slot);\n}\nexport const popperClasses = generateUtilityClasses(COMPONENT_NAME, ['root']);","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"anchorEl\", \"children\", \"direction\", \"disablePortal\", \"modifiers\", \"open\", \"placement\", \"popperOptions\", \"popperRef\", \"slotProps\", \"slots\", \"TransitionProps\", \"ownerState\"],\n _excluded2 = [\"anchorEl\", \"children\", \"container\", \"direction\", \"disablePortal\", \"keepMounted\", \"modifiers\", \"open\", \"placement\", \"popperOptions\", \"popperRef\", \"style\", \"transition\", \"slotProps\", \"slots\"];\nimport * as React from 'react';\nimport { chainPropTypes, HTMLElementType, refType, unstable_ownerDocument as ownerDocument, unstable_useEnhancedEffect as useEnhancedEffect, unstable_useForkRef as useForkRef } from '@mui/utils';\nimport { createPopper } from '@popperjs/core';\nimport PropTypes from 'prop-types';\nimport { unstable_composeClasses as composeClasses } from '../composeClasses';\nimport { Portal } from '../Portal';\nimport { getPopperUtilityClass } from './popperClasses';\nimport { useSlotProps } from '../utils';\nimport { useClassNamesOverride } from '../utils/ClassNameConfigurator';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nfunction flipPlacement(placement, direction) {\n if (direction === 'ltr') {\n return placement;\n }\n switch (placement) {\n case 'bottom-end':\n return 'bottom-start';\n case 'bottom-start':\n return 'bottom-end';\n case 'top-end':\n return 'top-start';\n case 'top-start':\n return 'top-end';\n default:\n return placement;\n }\n}\nfunction resolveAnchorEl(anchorEl) {\n return typeof anchorEl === 'function' ? anchorEl() : anchorEl;\n}\nfunction isHTMLElement(element) {\n return element.nodeType !== undefined;\n}\nfunction isVirtualElement(element) {\n return !isHTMLElement(element);\n}\nconst useUtilityClasses = () => {\n const slots = {\n root: ['root']\n };\n return composeClasses(slots, useClassNamesOverride(getPopperUtilityClass));\n};\nconst defaultPopperOptions = {};\nconst PopperTooltip = /*#__PURE__*/React.forwardRef(function PopperTooltip(props, forwardedRef) {\n var _slots$root;\n const {\n anchorEl,\n children,\n direction,\n disablePortal,\n modifiers,\n open,\n placement: initialPlacement,\n popperOptions,\n popperRef: popperRefProp,\n slotProps = {},\n slots = {},\n TransitionProps\n // @ts-ignore internal logic\n // prevent from spreading to DOM, it can come from the parent component e.g. Select.\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const tooltipRef = React.useRef(null);\n const ownRef = useForkRef(tooltipRef, forwardedRef);\n const popperRef = React.useRef(null);\n const handlePopperRef = useForkRef(popperRef, popperRefProp);\n const handlePopperRefRef = React.useRef(handlePopperRef);\n useEnhancedEffect(() => {\n handlePopperRefRef.current = handlePopperRef;\n }, [handlePopperRef]);\n React.useImperativeHandle(popperRefProp, () => popperRef.current, []);\n const rtlPlacement = flipPlacement(initialPlacement, direction);\n /**\n * placement initialized from prop but can change during lifetime if modifiers.flip.\n * modifiers.flip is essentially a flip for controlled/uncontrolled behavior\n */\n const [placement, setPlacement] = React.useState(rtlPlacement);\n const [resolvedAnchorElement, setResolvedAnchorElement] = React.useState(resolveAnchorEl(anchorEl));\n React.useEffect(() => {\n if (popperRef.current) {\n popperRef.current.forceUpdate();\n }\n });\n React.useEffect(() => {\n if (anchorEl) {\n setResolvedAnchorElement(resolveAnchorEl(anchorEl));\n }\n }, [anchorEl]);\n useEnhancedEffect(() => {\n if (!resolvedAnchorElement || !open) {\n return undefined;\n }\n const handlePopperUpdate = data => {\n setPlacement(data.placement);\n };\n if (process.env.NODE_ENV !== 'production') {\n if (resolvedAnchorElement && isHTMLElement(resolvedAnchorElement) && resolvedAnchorElement.nodeType === 1) {\n const box = resolvedAnchorElement.getBoundingClientRect();\n if (process.env.NODE_ENV !== 'test' && box.top === 0 && box.left === 0 && box.right === 0 && box.bottom === 0) {\n console.warn(['MUI: The `anchorEl` prop provided to the component is invalid.', 'The anchor element should be part of the document layout.', \"Make sure the element is present in the document or that it's not display none.\"].join('\\n'));\n }\n }\n }\n let popperModifiers = [{\n name: 'preventOverflow',\n options: {\n altBoundary: disablePortal\n }\n }, {\n name: 'flip',\n options: {\n altBoundary: disablePortal\n }\n }, {\n name: 'onUpdate',\n enabled: true,\n phase: 'afterWrite',\n fn: ({\n state\n }) => {\n handlePopperUpdate(state);\n }\n }];\n if (modifiers != null) {\n popperModifiers = popperModifiers.concat(modifiers);\n }\n if (popperOptions && popperOptions.modifiers != null) {\n popperModifiers = popperModifiers.concat(popperOptions.modifiers);\n }\n const popper = createPopper(resolvedAnchorElement, tooltipRef.current, _extends({\n placement: rtlPlacement\n }, popperOptions, {\n modifiers: popperModifiers\n }));\n handlePopperRefRef.current(popper);\n return () => {\n popper.destroy();\n handlePopperRefRef.current(null);\n };\n }, [resolvedAnchorElement, disablePortal, modifiers, open, popperOptions, rtlPlacement]);\n const childProps = {\n placement: placement\n };\n if (TransitionProps !== null) {\n childProps.TransitionProps = TransitionProps;\n }\n const classes = useUtilityClasses();\n const Root = (_slots$root = slots.root) != null ? _slots$root : 'div';\n const rootProps = useSlotProps({\n elementType: Root,\n externalSlotProps: slotProps.root,\n externalForwardedProps: other,\n additionalProps: {\n role: 'tooltip',\n ref: ownRef\n },\n ownerState: props,\n className: classes.root\n });\n return /*#__PURE__*/_jsx(Root, _extends({}, rootProps, {\n children: typeof children === 'function' ? children(childProps) : children\n }));\n});\n\n/**\n * Poppers rely on the 3rd party library [Popper.js](https://popper.js.org/docs/v2/) for positioning.\n *\n * Demos:\n *\n * - [Popper](https://mui.com/base-ui/react-popper/)\n *\n * API:\n *\n * - [Popper API](https://mui.com/base-ui/react-popper/components-api/#popper)\n */\nconst Popper = /*#__PURE__*/React.forwardRef(function Popper(props, forwardedRef) {\n const {\n anchorEl,\n children,\n container: containerProp,\n direction = 'ltr',\n disablePortal = false,\n keepMounted = false,\n modifiers,\n open,\n placement = 'bottom',\n popperOptions = defaultPopperOptions,\n popperRef,\n style,\n transition = false,\n slotProps = {},\n slots = {}\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded2);\n const [exited, setExited] = React.useState(true);\n const handleEnter = () => {\n setExited(false);\n };\n const handleExited = () => {\n setExited(true);\n };\n if (!keepMounted && !open && (!transition || exited)) {\n return null;\n }\n\n // If the container prop is provided, use that\n // If the anchorEl prop is provided, use its parent body element as the container\n // If neither are provided let the Modal take care of choosing the container\n let container;\n if (containerProp) {\n container = containerProp;\n } else if (anchorEl) {\n const resolvedAnchorEl = resolveAnchorEl(anchorEl);\n container = resolvedAnchorEl && isHTMLElement(resolvedAnchorEl) ? ownerDocument(resolvedAnchorEl).body : ownerDocument(null).body;\n }\n const display = !open && keepMounted && (!transition || exited) ? 'none' : undefined;\n const transitionProps = transition ? {\n in: open,\n onEnter: handleEnter,\n onExited: handleExited\n } : undefined;\n return /*#__PURE__*/_jsx(Portal, {\n disablePortal: disablePortal,\n container: container,\n children: /*#__PURE__*/_jsx(PopperTooltip, _extends({\n anchorEl: anchorEl,\n direction: direction,\n disablePortal: disablePortal,\n modifiers: modifiers,\n ref: forwardedRef,\n open: transition ? !exited : open,\n placement: placement,\n popperOptions: popperOptions,\n popperRef: popperRef,\n slotProps: slotProps,\n slots: slots\n }, other, {\n style: _extends({\n // Prevents scroll issue, waiting for Popper.js to add this style once initiated.\n position: 'fixed',\n // Fix Popper.js display issue\n top: 0,\n left: 0,\n display\n }, style),\n TransitionProps: transitionProps,\n children: children\n }))\n });\n});\nprocess.env.NODE_ENV !== \"production\" ? Popper.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * An HTML element, [virtualElement](https://popper.js.org/docs/v2/virtual-elements/),\n * or a function that returns either.\n * It's used to set the position of the popper.\n * The return value will passed as the reference object of the Popper instance.\n */\n anchorEl: chainPropTypes(PropTypes.oneOfType([HTMLElementType, PropTypes.object, PropTypes.func]), props => {\n if (props.open) {\n const resolvedAnchorEl = resolveAnchorEl(props.anchorEl);\n if (resolvedAnchorEl && isHTMLElement(resolvedAnchorEl) && resolvedAnchorEl.nodeType === 1) {\n const box = resolvedAnchorEl.getBoundingClientRect();\n if (process.env.NODE_ENV !== 'test' && box.top === 0 && box.left === 0 && box.right === 0 && box.bottom === 0) {\n return new Error(['MUI: The `anchorEl` prop provided to the component is invalid.', 'The anchor element should be part of the document layout.', \"Make sure the element is present in the document or that it's not display none.\"].join('\\n'));\n }\n } else if (!resolvedAnchorEl || typeof resolvedAnchorEl.getBoundingClientRect !== 'function' || isVirtualElement(resolvedAnchorEl) && resolvedAnchorEl.contextElement != null && resolvedAnchorEl.contextElement.nodeType !== 1) {\n return new Error(['MUI: The `anchorEl` prop provided to the component is invalid.', 'It should be an HTML element instance or a virtualElement ', '(https://popper.js.org/docs/v2/virtual-elements/).'].join('\\n'));\n }\n }\n return null;\n }),\n /**\n * Popper render function or node.\n */\n children: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.node, PropTypes.func]),\n /**\n * An HTML element or function that returns one.\n * The `container` will have the portal children appended to it.\n *\n * You can also provide a callback, which is called in a React layout effect.\n * This lets you set the container from a ref, and also makes server-side rendering possible.\n *\n * By default, it uses the body of the top-level document object,\n * so it's simply `document.body` most of the time.\n */\n container: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.func]),\n /**\n * Direction of the text.\n * @default 'ltr'\n */\n direction: PropTypes.oneOf(['ltr', 'rtl']),\n /**\n * The `children` will be under the DOM hierarchy of the parent component.\n * @default false\n */\n disablePortal: PropTypes.bool,\n /**\n * Always keep the children in the DOM.\n * This prop can be useful in SEO situation or\n * when you want to maximize the responsiveness of the Popper.\n * @default false\n */\n keepMounted: PropTypes.bool,\n /**\n * Popper.js is based on a \"plugin-like\" architecture,\n * most of its features are fully encapsulated \"modifiers\".\n *\n * A modifier is a function that is called each time Popper.js needs to\n * compute the position of the popper.\n * For this reason, modifiers should be very performant to avoid bottlenecks.\n * To learn how to create a modifier, [read the modifiers documentation](https://popper.js.org/docs/v2/modifiers/).\n */\n modifiers: PropTypes.arrayOf(PropTypes.shape({\n data: PropTypes.object,\n effect: PropTypes.func,\n enabled: PropTypes.bool,\n fn: PropTypes.func,\n name: PropTypes.any,\n options: PropTypes.object,\n phase: PropTypes.oneOf(['afterMain', 'afterRead', 'afterWrite', 'beforeMain', 'beforeRead', 'beforeWrite', 'main', 'read', 'write']),\n requires: PropTypes.arrayOf(PropTypes.string),\n requiresIfExists: PropTypes.arrayOf(PropTypes.string)\n })),\n /**\n * If `true`, the component is shown.\n */\n open: PropTypes.bool.isRequired,\n /**\n * Popper placement.\n * @default 'bottom'\n */\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n /**\n * Options provided to the [`Popper.js`](https://popper.js.org/docs/v2/constructors/#options) instance.\n * @default {}\n */\n popperOptions: PropTypes.shape({\n modifiers: PropTypes.array,\n onFirstUpdate: PropTypes.func,\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n strategy: PropTypes.oneOf(['absolute', 'fixed'])\n }),\n /**\n * A ref that points to the used popper instance.\n */\n popperRef: refType,\n /**\n * The props used for each slot inside the Popper.\n * @default {}\n */\n slotProps: PropTypes.shape({\n root: PropTypes.oneOfType([PropTypes.func, PropTypes.object])\n }),\n /**\n * The components used for each slot inside the Popper.\n * Either a string to use a HTML element or a component.\n * @default {}\n */\n slots: PropTypes.shape({\n root: PropTypes.elementType\n }),\n /**\n * Help supporting a react-transition-group/Transition component.\n * @default false\n */\n transition: PropTypes.bool\n} : void 0;\nexport { Popper };","'use client';\n\nimport * as React from 'react';\nimport { useTheme as useThemeSystem } from '@mui/system';\nimport defaultTheme from './defaultTheme';\nimport THEME_ID from './identifier';\nexport default function useTheme() {\n const theme = useThemeSystem(defaultTheme);\n if (process.env.NODE_ENV !== 'production') {\n // eslint-disable-next-line react-hooks/rules-of-hooks\n React.useDebugValue(theme);\n }\n return theme[THEME_ID] || theme;\n}","export default function _setPrototypeOf(o, p) {\n _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function _setPrototypeOf(o, p) {\n o.__proto__ = p;\n return o;\n };\n return _setPrototypeOf(o, p);\n}","import setPrototypeOf from \"./setPrototypeOf.js\";\nexport default function _inheritsLoose(subClass, superClass) {\n subClass.prototype = Object.create(superClass.prototype);\n subClass.prototype.constructor = subClass;\n setPrototypeOf(subClass, superClass);\n}","export default {\n disabled: false\n};","import PropTypes from 'prop-types';\nexport var timeoutsShape = process.env.NODE_ENV !== 'production' ? PropTypes.oneOfType([PropTypes.number, PropTypes.shape({\n enter: PropTypes.number,\n exit: PropTypes.number,\n appear: PropTypes.number\n}).isRequired]) : null;\nexport var classNamesShape = process.env.NODE_ENV !== 'production' ? PropTypes.oneOfType([PropTypes.string, PropTypes.shape({\n enter: PropTypes.string,\n exit: PropTypes.string,\n active: PropTypes.string\n}), PropTypes.shape({\n enter: PropTypes.string,\n enterDone: PropTypes.string,\n enterActive: PropTypes.string,\n exit: PropTypes.string,\n exitDone: PropTypes.string,\n exitActive: PropTypes.string\n})]) : null;","import React from 'react';\nexport default React.createContext(null);","export var forceReflow = function forceReflow(node) {\n return node.scrollTop;\n};","import _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _inheritsLoose from \"@babel/runtime/helpers/esm/inheritsLoose\";\nimport PropTypes from 'prop-types';\nimport React from 'react';\nimport ReactDOM from 'react-dom';\nimport config from './config';\nimport { timeoutsShape } from './utils/PropTypes';\nimport TransitionGroupContext from './TransitionGroupContext';\nimport { forceReflow } from './utils/reflow';\nexport var UNMOUNTED = 'unmounted';\nexport var EXITED = 'exited';\nexport var ENTERING = 'entering';\nexport var ENTERED = 'entered';\nexport var EXITING = 'exiting';\n/**\n * The Transition component lets you describe a transition from one component\n * state to another _over time_ with a simple declarative API. Most commonly\n * it's used to animate the mounting and unmounting of a component, but can also\n * be used to describe in-place transition states as well.\n *\n * ---\n *\n * **Note**: `Transition` is a platform-agnostic base component. If you're using\n * transitions in CSS, you'll probably want to use\n * [`CSSTransition`](https://reactcommunity.org/react-transition-group/css-transition)\n * instead. It inherits all the features of `Transition`, but contains\n * additional features necessary to play nice with CSS transitions (hence the\n * name of the component).\n *\n * ---\n *\n * By default the `Transition` component does not alter the behavior of the\n * component it renders, it only tracks \"enter\" and \"exit\" states for the\n * components. It's up to you to give meaning and effect to those states. For\n * example we can add styles to a component when it enters or exits:\n *\n * ```jsx\n * import { Transition } from 'react-transition-group';\n *\n * const duration = 300;\n *\n * const defaultStyle = {\n * transition: `opacity ${duration}ms ease-in-out`,\n * opacity: 0,\n * }\n *\n * const transitionStyles = {\n * entering: { opacity: 1 },\n * entered: { opacity: 1 },\n * exiting: { opacity: 0 },\n * exited: { opacity: 0 },\n * };\n *\n * const Fade = ({ in: inProp }) => (\n * \n * {state => (\n *
    \n * I'm a fade Transition!\n *
    \n * )}\n *
    \n * );\n * ```\n *\n * There are 4 main states a Transition can be in:\n * - `'entering'`\n * - `'entered'`\n * - `'exiting'`\n * - `'exited'`\n *\n * Transition state is toggled via the `in` prop. When `true` the component\n * begins the \"Enter\" stage. During this stage, the component will shift from\n * its current transition state, to `'entering'` for the duration of the\n * transition and then to the `'entered'` stage once it's complete. Let's take\n * the following example (we'll use the\n * [useState](https://reactjs.org/docs/hooks-reference.html#usestate) hook):\n *\n * ```jsx\n * function App() {\n * const [inProp, setInProp] = useState(false);\n * return (\n *
    \n * \n * {state => (\n * // ...\n * )}\n * \n * \n *
    \n * );\n * }\n * ```\n *\n * When the button is clicked the component will shift to the `'entering'` state\n * and stay there for 500ms (the value of `timeout`) before it finally switches\n * to `'entered'`.\n *\n * When `in` is `false` the same thing happens except the state moves from\n * `'exiting'` to `'exited'`.\n */\n\nvar Transition = /*#__PURE__*/function (_React$Component) {\n _inheritsLoose(Transition, _React$Component);\n\n function Transition(props, context) {\n var _this;\n\n _this = _React$Component.call(this, props, context) || this;\n var parentGroup = context; // In the context of a TransitionGroup all enters are really appears\n\n var appear = parentGroup && !parentGroup.isMounting ? props.enter : props.appear;\n var initialStatus;\n _this.appearStatus = null;\n\n if (props.in) {\n if (appear) {\n initialStatus = EXITED;\n _this.appearStatus = ENTERING;\n } else {\n initialStatus = ENTERED;\n }\n } else {\n if (props.unmountOnExit || props.mountOnEnter) {\n initialStatus = UNMOUNTED;\n } else {\n initialStatus = EXITED;\n }\n }\n\n _this.state = {\n status: initialStatus\n };\n _this.nextCallback = null;\n return _this;\n }\n\n Transition.getDerivedStateFromProps = function getDerivedStateFromProps(_ref, prevState) {\n var nextIn = _ref.in;\n\n if (nextIn && prevState.status === UNMOUNTED) {\n return {\n status: EXITED\n };\n }\n\n return null;\n } // getSnapshotBeforeUpdate(prevProps) {\n // let nextStatus = null\n // if (prevProps !== this.props) {\n // const { status } = this.state\n // if (this.props.in) {\n // if (status !== ENTERING && status !== ENTERED) {\n // nextStatus = ENTERING\n // }\n // } else {\n // if (status === ENTERING || status === ENTERED) {\n // nextStatus = EXITING\n // }\n // }\n // }\n // return { nextStatus }\n // }\n ;\n\n var _proto = Transition.prototype;\n\n _proto.componentDidMount = function componentDidMount() {\n this.updateStatus(true, this.appearStatus);\n };\n\n _proto.componentDidUpdate = function componentDidUpdate(prevProps) {\n var nextStatus = null;\n\n if (prevProps !== this.props) {\n var status = this.state.status;\n\n if (this.props.in) {\n if (status !== ENTERING && status !== ENTERED) {\n nextStatus = ENTERING;\n }\n } else {\n if (status === ENTERING || status === ENTERED) {\n nextStatus = EXITING;\n }\n }\n }\n\n this.updateStatus(false, nextStatus);\n };\n\n _proto.componentWillUnmount = function componentWillUnmount() {\n this.cancelNextCallback();\n };\n\n _proto.getTimeouts = function getTimeouts() {\n var timeout = this.props.timeout;\n var exit, enter, appear;\n exit = enter = appear = timeout;\n\n if (timeout != null && typeof timeout !== 'number') {\n exit = timeout.exit;\n enter = timeout.enter; // TODO: remove fallback for next major\n\n appear = timeout.appear !== undefined ? timeout.appear : enter;\n }\n\n return {\n exit: exit,\n enter: enter,\n appear: appear\n };\n };\n\n _proto.updateStatus = function updateStatus(mounting, nextStatus) {\n if (mounting === void 0) {\n mounting = false;\n }\n\n if (nextStatus !== null) {\n // nextStatus will always be ENTERING or EXITING.\n this.cancelNextCallback();\n\n if (nextStatus === ENTERING) {\n if (this.props.unmountOnExit || this.props.mountOnEnter) {\n var node = this.props.nodeRef ? this.props.nodeRef.current : ReactDOM.findDOMNode(this); // https://github.com/reactjs/react-transition-group/pull/749\n // With unmountOnExit or mountOnEnter, the enter animation should happen at the transition between `exited` and `entering`.\n // To make the animation happen, we have to separate each rendering and avoid being processed as batched.\n\n if (node) forceReflow(node);\n }\n\n this.performEnter(mounting);\n } else {\n this.performExit();\n }\n } else if (this.props.unmountOnExit && this.state.status === EXITED) {\n this.setState({\n status: UNMOUNTED\n });\n }\n };\n\n _proto.performEnter = function performEnter(mounting) {\n var _this2 = this;\n\n var enter = this.props.enter;\n var appearing = this.context ? this.context.isMounting : mounting;\n\n var _ref2 = this.props.nodeRef ? [appearing] : [ReactDOM.findDOMNode(this), appearing],\n maybeNode = _ref2[0],\n maybeAppearing = _ref2[1];\n\n var timeouts = this.getTimeouts();\n var enterTimeout = appearing ? timeouts.appear : timeouts.enter; // no enter animation skip right to ENTERED\n // if we are mounting and running this it means appear _must_ be set\n\n if (!mounting && !enter || config.disabled) {\n this.safeSetState({\n status: ENTERED\n }, function () {\n _this2.props.onEntered(maybeNode);\n });\n return;\n }\n\n this.props.onEnter(maybeNode, maybeAppearing);\n this.safeSetState({\n status: ENTERING\n }, function () {\n _this2.props.onEntering(maybeNode, maybeAppearing);\n\n _this2.onTransitionEnd(enterTimeout, function () {\n _this2.safeSetState({\n status: ENTERED\n }, function () {\n _this2.props.onEntered(maybeNode, maybeAppearing);\n });\n });\n });\n };\n\n _proto.performExit = function performExit() {\n var _this3 = this;\n\n var exit = this.props.exit;\n var timeouts = this.getTimeouts();\n var maybeNode = this.props.nodeRef ? undefined : ReactDOM.findDOMNode(this); // no exit animation skip right to EXITED\n\n if (!exit || config.disabled) {\n this.safeSetState({\n status: EXITED\n }, function () {\n _this3.props.onExited(maybeNode);\n });\n return;\n }\n\n this.props.onExit(maybeNode);\n this.safeSetState({\n status: EXITING\n }, function () {\n _this3.props.onExiting(maybeNode);\n\n _this3.onTransitionEnd(timeouts.exit, function () {\n _this3.safeSetState({\n status: EXITED\n }, function () {\n _this3.props.onExited(maybeNode);\n });\n });\n });\n };\n\n _proto.cancelNextCallback = function cancelNextCallback() {\n if (this.nextCallback !== null) {\n this.nextCallback.cancel();\n this.nextCallback = null;\n }\n };\n\n _proto.safeSetState = function safeSetState(nextState, callback) {\n // This shouldn't be necessary, but there are weird race conditions with\n // setState callbacks and unmounting in testing, so always make sure that\n // we can cancel any pending setState callbacks after we unmount.\n callback = this.setNextCallback(callback);\n this.setState(nextState, callback);\n };\n\n _proto.setNextCallback = function setNextCallback(callback) {\n var _this4 = this;\n\n var active = true;\n\n this.nextCallback = function (event) {\n if (active) {\n active = false;\n _this4.nextCallback = null;\n callback(event);\n }\n };\n\n this.nextCallback.cancel = function () {\n active = false;\n };\n\n return this.nextCallback;\n };\n\n _proto.onTransitionEnd = function onTransitionEnd(timeout, handler) {\n this.setNextCallback(handler);\n var node = this.props.nodeRef ? this.props.nodeRef.current : ReactDOM.findDOMNode(this);\n var doesNotHaveTimeoutOrListener = timeout == null && !this.props.addEndListener;\n\n if (!node || doesNotHaveTimeoutOrListener) {\n setTimeout(this.nextCallback, 0);\n return;\n }\n\n if (this.props.addEndListener) {\n var _ref3 = this.props.nodeRef ? [this.nextCallback] : [node, this.nextCallback],\n maybeNode = _ref3[0],\n maybeNextCallback = _ref3[1];\n\n this.props.addEndListener(maybeNode, maybeNextCallback);\n }\n\n if (timeout != null) {\n setTimeout(this.nextCallback, timeout);\n }\n };\n\n _proto.render = function render() {\n var status = this.state.status;\n\n if (status === UNMOUNTED) {\n return null;\n }\n\n var _this$props = this.props,\n children = _this$props.children,\n _in = _this$props.in,\n _mountOnEnter = _this$props.mountOnEnter,\n _unmountOnExit = _this$props.unmountOnExit,\n _appear = _this$props.appear,\n _enter = _this$props.enter,\n _exit = _this$props.exit,\n _timeout = _this$props.timeout,\n _addEndListener = _this$props.addEndListener,\n _onEnter = _this$props.onEnter,\n _onEntering = _this$props.onEntering,\n _onEntered = _this$props.onEntered,\n _onExit = _this$props.onExit,\n _onExiting = _this$props.onExiting,\n _onExited = _this$props.onExited,\n _nodeRef = _this$props.nodeRef,\n childProps = _objectWithoutPropertiesLoose(_this$props, [\"children\", \"in\", \"mountOnEnter\", \"unmountOnExit\", \"appear\", \"enter\", \"exit\", \"timeout\", \"addEndListener\", \"onEnter\", \"onEntering\", \"onEntered\", \"onExit\", \"onExiting\", \"onExited\", \"nodeRef\"]);\n\n return (\n /*#__PURE__*/\n // allows for nested Transitions\n React.createElement(TransitionGroupContext.Provider, {\n value: null\n }, typeof children === 'function' ? children(status, childProps) : React.cloneElement(React.Children.only(children), childProps))\n );\n };\n\n return Transition;\n}(React.Component);\n\nTransition.contextType = TransitionGroupContext;\nTransition.propTypes = process.env.NODE_ENV !== \"production\" ? {\n /**\n * A React reference to DOM element that need to transition:\n * https://stackoverflow.com/a/51127130/4671932\n *\n * - When `nodeRef` prop is used, `node` is not passed to callback functions\n * (e.g. `onEnter`) because user already has direct access to the node.\n * - When changing `key` prop of `Transition` in a `TransitionGroup` a new\n * `nodeRef` need to be provided to `Transition` with changed `key` prop\n * (see\n * [test/CSSTransition-test.js](https://github.com/reactjs/react-transition-group/blob/13435f897b3ab71f6e19d724f145596f5910581c/test/CSSTransition-test.js#L362-L437)).\n */\n nodeRef: PropTypes.shape({\n current: typeof Element === 'undefined' ? PropTypes.any : function (propValue, key, componentName, location, propFullName, secret) {\n var value = propValue[key];\n return PropTypes.instanceOf(value && 'ownerDocument' in value ? value.ownerDocument.defaultView.Element : Element)(propValue, key, componentName, location, propFullName, secret);\n }\n }),\n\n /**\n * A `function` child can be used instead of a React element. This function is\n * called with the current transition status (`'entering'`, `'entered'`,\n * `'exiting'`, `'exited'`), which can be used to apply context\n * specific props to a component.\n *\n * ```jsx\n * \n * {state => (\n * \n * )}\n * \n * ```\n */\n children: PropTypes.oneOfType([PropTypes.func.isRequired, PropTypes.element.isRequired]).isRequired,\n\n /**\n * Show the component; triggers the enter or exit states\n */\n in: PropTypes.bool,\n\n /**\n * By default the child component is mounted immediately along with\n * the parent `Transition` component. If you want to \"lazy mount\" the component on the\n * first `in={true}` you can set `mountOnEnter`. After the first enter transition the component will stay\n * mounted, even on \"exited\", unless you also specify `unmountOnExit`.\n */\n mountOnEnter: PropTypes.bool,\n\n /**\n * By default the child component stays mounted after it reaches the `'exited'` state.\n * Set `unmountOnExit` if you'd prefer to unmount the component after it finishes exiting.\n */\n unmountOnExit: PropTypes.bool,\n\n /**\n * By default the child component does not perform the enter transition when\n * it first mounts, regardless of the value of `in`. If you want this\n * behavior, set both `appear` and `in` to `true`.\n *\n * > **Note**: there are no special appear states like `appearing`/`appeared`, this prop\n * > only adds an additional enter transition. However, in the\n * > `` component that first enter transition does result in\n * > additional `.appear-*` classes, that way you can choose to style it\n * > differently.\n */\n appear: PropTypes.bool,\n\n /**\n * Enable or disable enter transitions.\n */\n enter: PropTypes.bool,\n\n /**\n * Enable or disable exit transitions.\n */\n exit: PropTypes.bool,\n\n /**\n * The duration of the transition, in milliseconds.\n * Required unless `addEndListener` is provided.\n *\n * You may specify a single timeout for all transitions:\n *\n * ```jsx\n * timeout={500}\n * ```\n *\n * or individually:\n *\n * ```jsx\n * timeout={{\n * appear: 500,\n * enter: 300,\n * exit: 500,\n * }}\n * ```\n *\n * - `appear` defaults to the value of `enter`\n * - `enter` defaults to `0`\n * - `exit` defaults to `0`\n *\n * @type {number | { enter?: number, exit?: number, appear?: number }}\n */\n timeout: function timeout(props) {\n var pt = timeoutsShape;\n if (!props.addEndListener) pt = pt.isRequired;\n\n for (var _len = arguments.length, args = new Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) {\n args[_key - 1] = arguments[_key];\n }\n\n return pt.apply(void 0, [props].concat(args));\n },\n\n /**\n * Add a custom transition end trigger. Called with the transitioning\n * DOM node and a `done` callback. Allows for more fine grained transition end\n * logic. Timeouts are still used as a fallback if provided.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * ```jsx\n * addEndListener={(node, done) => {\n * // use the css transitionend event to mark the finish of a transition\n * node.addEventListener('transitionend', done, false);\n * }}\n * ```\n */\n addEndListener: PropTypes.func,\n\n /**\n * Callback fired before the \"entering\" status is applied. An extra parameter\n * `isAppearing` is supplied to indicate if the enter stage is occurring on the initial mount\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement, isAppearing: bool) -> void\n */\n onEnter: PropTypes.func,\n\n /**\n * Callback fired after the \"entering\" status is applied. An extra parameter\n * `isAppearing` is supplied to indicate if the enter stage is occurring on the initial mount\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement, isAppearing: bool)\n */\n onEntering: PropTypes.func,\n\n /**\n * Callback fired after the \"entered\" status is applied. An extra parameter\n * `isAppearing` is supplied to indicate if the enter stage is occurring on the initial mount\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement, isAppearing: bool) -> void\n */\n onEntered: PropTypes.func,\n\n /**\n * Callback fired before the \"exiting\" status is applied.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement) -> void\n */\n onExit: PropTypes.func,\n\n /**\n * Callback fired after the \"exiting\" status is applied.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement) -> void\n */\n onExiting: PropTypes.func,\n\n /**\n * Callback fired after the \"exited\" status is applied.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed\n *\n * @type Function(node: HtmlElement) -> void\n */\n onExited: PropTypes.func\n} : {}; // Name the function so it is clearer in the documentation\n\nfunction noop() {}\n\nTransition.defaultProps = {\n in: false,\n mountOnEnter: false,\n unmountOnExit: false,\n appear: false,\n enter: true,\n exit: true,\n onEnter: noop,\n onEntering: noop,\n onEntered: noop,\n onExit: noop,\n onExiting: noop,\n onExited: noop\n};\nTransition.UNMOUNTED = UNMOUNTED;\nTransition.EXITED = EXITED;\nTransition.ENTERING = ENTERING;\nTransition.ENTERED = ENTERED;\nTransition.EXITING = EXITING;\nexport default Transition;","export const reflow = node => node.scrollTop;\nexport function getTransitionProps(props, options) {\n var _style$transitionDura, _style$transitionTimi;\n const {\n timeout,\n easing,\n style = {}\n } = props;\n return {\n duration: (_style$transitionDura = style.transitionDuration) != null ? _style$transitionDura : typeof timeout === 'number' ? timeout : timeout[options.mode] || 0,\n easing: (_style$transitionTimi = style.transitionTimingFunction) != null ? _style$transitionTimi : typeof easing === 'object' ? easing[options.mode] : easing,\n delay: style.transitionDelay\n };\n}","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"addEndListener\", \"appear\", \"children\", \"easing\", \"in\", \"onEnter\", \"onEntered\", \"onEntering\", \"onExit\", \"onExited\", \"onExiting\", \"style\", \"timeout\", \"TransitionComponent\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport { elementAcceptingRef, unstable_useTimeout as useTimeout } from '@mui/utils';\nimport { Transition } from 'react-transition-group';\nimport useTheme from '../styles/useTheme';\nimport { getTransitionProps, reflow } from '../transitions/utils';\nimport useForkRef from '../utils/useForkRef';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nfunction getScale(value) {\n return `scale(${value}, ${value ** 2})`;\n}\nconst styles = {\n entering: {\n opacity: 1,\n transform: getScale(1)\n },\n entered: {\n opacity: 1,\n transform: 'none'\n }\n};\n\n/*\n TODO v6: remove\n Conditionally apply a workaround for the CSS transition bug in Safari 15.4 / WebKit browsers.\n */\nconst isWebKit154 = typeof navigator !== 'undefined' && /^((?!chrome|android).)*(safari|mobile)/i.test(navigator.userAgent) && /(os |version\\/)15(.|_)4/i.test(navigator.userAgent);\n\n/**\n * The Grow transition is used by the [Tooltip](/material-ui/react-tooltip/) and\n * [Popover](/material-ui/react-popover/) components.\n * It uses [react-transition-group](https://github.com/reactjs/react-transition-group) internally.\n */\nconst Grow = /*#__PURE__*/React.forwardRef(function Grow(props, ref) {\n const {\n addEndListener,\n appear = true,\n children,\n easing,\n in: inProp,\n onEnter,\n onEntered,\n onEntering,\n onExit,\n onExited,\n onExiting,\n style,\n timeout = 'auto',\n // eslint-disable-next-line react/prop-types\n TransitionComponent = Transition\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const timer = useTimeout();\n const autoTimeout = React.useRef();\n const theme = useTheme();\n const nodeRef = React.useRef(null);\n const handleRef = useForkRef(nodeRef, children.ref, ref);\n const normalizedTransitionCallback = callback => maybeIsAppearing => {\n if (callback) {\n const node = nodeRef.current;\n\n // onEnterXxx and onExitXxx callbacks have a different arguments.length value.\n if (maybeIsAppearing === undefined) {\n callback(node);\n } else {\n callback(node, maybeIsAppearing);\n }\n }\n };\n const handleEntering = normalizedTransitionCallback(onEntering);\n const handleEnter = normalizedTransitionCallback((node, isAppearing) => {\n reflow(node); // So the animation always start from the start.\n\n const {\n duration: transitionDuration,\n delay,\n easing: transitionTimingFunction\n } = getTransitionProps({\n style,\n timeout,\n easing\n }, {\n mode: 'enter'\n });\n let duration;\n if (timeout === 'auto') {\n duration = theme.transitions.getAutoHeightDuration(node.clientHeight);\n autoTimeout.current = duration;\n } else {\n duration = transitionDuration;\n }\n node.style.transition = [theme.transitions.create('opacity', {\n duration,\n delay\n }), theme.transitions.create('transform', {\n duration: isWebKit154 ? duration : duration * 0.666,\n delay,\n easing: transitionTimingFunction\n })].join(',');\n if (onEnter) {\n onEnter(node, isAppearing);\n }\n });\n const handleEntered = normalizedTransitionCallback(onEntered);\n const handleExiting = normalizedTransitionCallback(onExiting);\n const handleExit = normalizedTransitionCallback(node => {\n const {\n duration: transitionDuration,\n delay,\n easing: transitionTimingFunction\n } = getTransitionProps({\n style,\n timeout,\n easing\n }, {\n mode: 'exit'\n });\n let duration;\n if (timeout === 'auto') {\n duration = theme.transitions.getAutoHeightDuration(node.clientHeight);\n autoTimeout.current = duration;\n } else {\n duration = transitionDuration;\n }\n node.style.transition = [theme.transitions.create('opacity', {\n duration,\n delay\n }), theme.transitions.create('transform', {\n duration: isWebKit154 ? duration : duration * 0.666,\n delay: isWebKit154 ? delay : delay || duration * 0.333,\n easing: transitionTimingFunction\n })].join(',');\n node.style.opacity = 0;\n node.style.transform = getScale(0.75);\n if (onExit) {\n onExit(node);\n }\n });\n const handleExited = normalizedTransitionCallback(onExited);\n const handleAddEndListener = next => {\n if (timeout === 'auto') {\n timer.start(autoTimeout.current || 0, next);\n }\n if (addEndListener) {\n // Old call signature before `react-transition-group` implemented `nodeRef`\n addEndListener(nodeRef.current, next);\n }\n };\n return /*#__PURE__*/_jsx(TransitionComponent, _extends({\n appear: appear,\n in: inProp,\n nodeRef: nodeRef,\n onEnter: handleEnter,\n onEntered: handleEntered,\n onEntering: handleEntering,\n onExit: handleExit,\n onExited: handleExited,\n onExiting: handleExiting,\n addEndListener: handleAddEndListener,\n timeout: timeout === 'auto' ? null : timeout\n }, other, {\n children: (state, childProps) => {\n return /*#__PURE__*/React.cloneElement(children, _extends({\n style: _extends({\n opacity: 0,\n transform: getScale(0.75),\n visibility: state === 'exited' && !inProp ? 'hidden' : undefined\n }, styles[state], style, children.props.style),\n ref: handleRef\n }, childProps));\n }\n }));\n});\nprocess.env.NODE_ENV !== \"production\" ? Grow.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the d.ts file and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * Add a custom transition end trigger. Called with the transitioning DOM\n * node and a done callback. Allows for more fine grained transition end\n * logic. Note: Timeouts are still used as a fallback if provided.\n */\n addEndListener: PropTypes.func,\n /**\n * Perform the enter transition when it first mounts if `in` is also `true`.\n * Set this to `false` to disable this behavior.\n * @default true\n */\n appear: PropTypes.bool,\n /**\n * A single child content element.\n */\n children: elementAcceptingRef.isRequired,\n /**\n * The transition timing function.\n * You may specify a single easing or a object containing enter and exit values.\n */\n easing: PropTypes.oneOfType([PropTypes.shape({\n enter: PropTypes.string,\n exit: PropTypes.string\n }), PropTypes.string]),\n /**\n * If `true`, the component will transition in.\n */\n in: PropTypes.bool,\n /**\n * @ignore\n */\n onEnter: PropTypes.func,\n /**\n * @ignore\n */\n onEntered: PropTypes.func,\n /**\n * @ignore\n */\n onEntering: PropTypes.func,\n /**\n * @ignore\n */\n onExit: PropTypes.func,\n /**\n * @ignore\n */\n onExited: PropTypes.func,\n /**\n * @ignore\n */\n onExiting: PropTypes.func,\n /**\n * @ignore\n */\n style: PropTypes.object,\n /**\n * The duration for the transition, in milliseconds.\n * You may specify a single timeout for all transitions, or individually with an object.\n *\n * Set to 'auto' to automatically calculate transition time based on height.\n * @default 'auto'\n */\n timeout: PropTypes.oneOfType([PropTypes.oneOf(['auto']), PropTypes.number, PropTypes.shape({\n appear: PropTypes.number,\n enter: PropTypes.number,\n exit: PropTypes.number\n })])\n} : void 0;\nGrow.muiSupportAuto = true;\nexport default Grow;","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"anchorEl\", \"component\", \"components\", \"componentsProps\", \"container\", \"disablePortal\", \"keepMounted\", \"modifiers\", \"open\", \"placement\", \"popperOptions\", \"popperRef\", \"transition\", \"slots\", \"slotProps\"];\nimport { Popper as BasePopper } from '@mui/base/Popper';\nimport { useThemeWithoutDefault as useTheme } from '@mui/system';\nimport { HTMLElementType, refType } from '@mui/utils';\nimport PropTypes from 'prop-types';\nimport * as React from 'react';\nimport { styled, useThemeProps } from '../styles';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nconst PopperRoot = styled(BasePopper, {\n name: 'MuiPopper',\n slot: 'Root',\n overridesResolver: (props, styles) => styles.root\n})({});\n\n/**\n *\n * Demos:\n *\n * - [Autocomplete](https://mui.com/material-ui/react-autocomplete/)\n * - [Menu](https://mui.com/material-ui/react-menu/)\n * - [Popper](https://mui.com/material-ui/react-popper/)\n *\n * API:\n *\n * - [Popper API](https://mui.com/material-ui/api/popper/)\n */\nconst Popper = /*#__PURE__*/React.forwardRef(function Popper(inProps, ref) {\n var _slots$root;\n const theme = useTheme();\n const props = useThemeProps({\n props: inProps,\n name: 'MuiPopper'\n });\n const {\n anchorEl,\n component,\n components,\n componentsProps,\n container,\n disablePortal,\n keepMounted,\n modifiers,\n open,\n placement,\n popperOptions,\n popperRef,\n transition,\n slots,\n slotProps\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const RootComponent = (_slots$root = slots == null ? void 0 : slots.root) != null ? _slots$root : components == null ? void 0 : components.Root;\n const otherProps = _extends({\n anchorEl,\n container,\n disablePortal,\n keepMounted,\n modifiers,\n open,\n placement,\n popperOptions,\n popperRef,\n transition\n }, other);\n return /*#__PURE__*/_jsx(PopperRoot, _extends({\n as: component,\n direction: theme == null ? void 0 : theme.direction,\n slots: {\n root: RootComponent\n },\n slotProps: slotProps != null ? slotProps : componentsProps\n }, otherProps, {\n ref: ref\n }));\n});\nprocess.env.NODE_ENV !== \"production\" ? Popper.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * An HTML element, [virtualElement](https://popper.js.org/docs/v2/virtual-elements/),\n * or a function that returns either.\n * It's used to set the position of the popper.\n * The return value will passed as the reference object of the Popper instance.\n */\n anchorEl: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.object, PropTypes.func]),\n /**\n * Popper render function or node.\n */\n children: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.node, PropTypes.func]),\n /**\n * The component used for the root node.\n * Either a string to use a HTML element or a component.\n */\n component: PropTypes.elementType,\n /**\n * The components used for each slot inside the Popper.\n * Either a string to use a HTML element or a component.\n * @default {}\n */\n components: PropTypes.shape({\n Root: PropTypes.elementType\n }),\n /**\n * The props used for each slot inside the Popper.\n * @default {}\n */\n componentsProps: PropTypes.shape({\n root: PropTypes.oneOfType([PropTypes.func, PropTypes.object])\n }),\n /**\n * An HTML element or function that returns one.\n * The `container` will have the portal children appended to it.\n *\n * You can also provide a callback, which is called in a React layout effect.\n * This lets you set the container from a ref, and also makes server-side rendering possible.\n *\n * By default, it uses the body of the top-level document object,\n * so it's simply `document.body` most of the time.\n */\n container: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.func]),\n /**\n * The `children` will be under the DOM hierarchy of the parent component.\n * @default false\n */\n disablePortal: PropTypes.bool,\n /**\n * Always keep the children in the DOM.\n * This prop can be useful in SEO situation or\n * when you want to maximize the responsiveness of the Popper.\n * @default false\n */\n keepMounted: PropTypes.bool,\n /**\n * Popper.js is based on a \"plugin-like\" architecture,\n * most of its features are fully encapsulated \"modifiers\".\n *\n * A modifier is a function that is called each time Popper.js needs to\n * compute the position of the popper.\n * For this reason, modifiers should be very performant to avoid bottlenecks.\n * To learn how to create a modifier, [read the modifiers documentation](https://popper.js.org/docs/v2/modifiers/).\n */\n modifiers: PropTypes.arrayOf(PropTypes.shape({\n data: PropTypes.object,\n effect: PropTypes.func,\n enabled: PropTypes.bool,\n fn: PropTypes.func,\n name: PropTypes.any,\n options: PropTypes.object,\n phase: PropTypes.oneOf(['afterMain', 'afterRead', 'afterWrite', 'beforeMain', 'beforeRead', 'beforeWrite', 'main', 'read', 'write']),\n requires: PropTypes.arrayOf(PropTypes.string),\n requiresIfExists: PropTypes.arrayOf(PropTypes.string)\n })),\n /**\n * If `true`, the component is shown.\n */\n open: PropTypes.bool.isRequired,\n /**\n * Popper placement.\n * @default 'bottom'\n */\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n /**\n * Options provided to the [`Popper.js`](https://popper.js.org/docs/v2/constructors/#options) instance.\n * @default {}\n */\n popperOptions: PropTypes.shape({\n modifiers: PropTypes.array,\n onFirstUpdate: PropTypes.func,\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n strategy: PropTypes.oneOf(['absolute', 'fixed'])\n }),\n /**\n * A ref that points to the used popper instance.\n */\n popperRef: refType,\n /**\n * The props used for each slot inside the Popper.\n * @default {}\n */\n slotProps: PropTypes.shape({\n root: PropTypes.oneOfType([PropTypes.func, PropTypes.object])\n }),\n /**\n * The components used for each slot inside the Popper.\n * Either a string to use a HTML element or a component.\n * @default {}\n */\n slots: PropTypes.shape({\n root: PropTypes.elementType\n }),\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Help supporting a react-transition-group/Transition component.\n * @default false\n */\n transition: PropTypes.bool\n} : void 0;\nexport default Popper;","import generateUtilityClasses from '@mui/utils/generateUtilityClasses';\nimport generateUtilityClass from '@mui/utils/generateUtilityClass';\nexport function getTooltipUtilityClass(slot) {\n return generateUtilityClass('MuiTooltip', slot);\n}\nconst tooltipClasses = generateUtilityClasses('MuiTooltip', ['popper', 'popperInteractive', 'popperArrow', 'popperClose', 'tooltip', 'tooltipArrow', 'touch', 'tooltipPlacementLeft', 'tooltipPlacementRight', 'tooltipPlacementTop', 'tooltipPlacementBottom', 'arrow']);\nexport default tooltipClasses;","'use client';\n\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nconst _excluded = [\"arrow\", \"children\", \"classes\", \"components\", \"componentsProps\", \"describeChild\", \"disableFocusListener\", \"disableHoverListener\", \"disableInteractive\", \"disableTouchListener\", \"enterDelay\", \"enterNextDelay\", \"enterTouchDelay\", \"followCursor\", \"id\", \"leaveDelay\", \"leaveTouchDelay\", \"onClose\", \"onOpen\", \"open\", \"placement\", \"PopperComponent\", \"PopperProps\", \"slotProps\", \"slots\", \"title\", \"TransitionComponent\", \"TransitionProps\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport clsx from 'clsx';\nimport { elementAcceptingRef, unstable_useTimeout as useTimeout, unstable_Timeout as Timeout } from '@mui/utils';\nimport { unstable_composeClasses as composeClasses, appendOwnerState } from '@mui/base';\nimport { alpha } from '@mui/system';\nimport styled from '../styles/styled';\nimport useTheme from '../styles/useTheme';\nimport useThemeProps from '../styles/useThemeProps';\nimport capitalize from '../utils/capitalize';\nimport Grow from '../Grow';\nimport Popper from '../Popper';\nimport useEventCallback from '../utils/useEventCallback';\nimport useForkRef from '../utils/useForkRef';\nimport useId from '../utils/useId';\nimport useIsFocusVisible from '../utils/useIsFocusVisible';\nimport useControlled from '../utils/useControlled';\nimport tooltipClasses, { getTooltipUtilityClass } from './tooltipClasses';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nimport { jsxs as _jsxs } from \"react/jsx-runtime\";\nfunction round(value) {\n return Math.round(value * 1e5) / 1e5;\n}\nconst useUtilityClasses = ownerState => {\n const {\n classes,\n disableInteractive,\n arrow,\n touch,\n placement\n } = ownerState;\n const slots = {\n popper: ['popper', !disableInteractive && 'popperInteractive', arrow && 'popperArrow'],\n tooltip: ['tooltip', arrow && 'tooltipArrow', touch && 'touch', `tooltipPlacement${capitalize(placement.split('-')[0])}`],\n arrow: ['arrow']\n };\n return composeClasses(slots, getTooltipUtilityClass, classes);\n};\nconst TooltipPopper = styled(Popper, {\n name: 'MuiTooltip',\n slot: 'Popper',\n overridesResolver: (props, styles) => {\n const {\n ownerState\n } = props;\n return [styles.popper, !ownerState.disableInteractive && styles.popperInteractive, ownerState.arrow && styles.popperArrow, !ownerState.open && styles.popperClose];\n }\n})(({\n theme,\n ownerState,\n open\n}) => _extends({\n zIndex: (theme.vars || theme).zIndex.tooltip,\n pointerEvents: 'none'\n}, !ownerState.disableInteractive && {\n pointerEvents: 'auto'\n}, !open && {\n pointerEvents: 'none'\n}, ownerState.arrow && {\n [`&[data-popper-placement*=\"bottom\"] .${tooltipClasses.arrow}`]: {\n top: 0,\n marginTop: '-0.71em',\n '&::before': {\n transformOrigin: '0 100%'\n }\n },\n [`&[data-popper-placement*=\"top\"] .${tooltipClasses.arrow}`]: {\n bottom: 0,\n marginBottom: '-0.71em',\n '&::before': {\n transformOrigin: '100% 0'\n }\n },\n [`&[data-popper-placement*=\"right\"] .${tooltipClasses.arrow}`]: _extends({}, !ownerState.isRtl ? {\n left: 0,\n marginLeft: '-0.71em'\n } : {\n right: 0,\n marginRight: '-0.71em'\n }, {\n height: '1em',\n width: '0.71em',\n '&::before': {\n transformOrigin: '100% 100%'\n }\n }),\n [`&[data-popper-placement*=\"left\"] .${tooltipClasses.arrow}`]: _extends({}, !ownerState.isRtl ? {\n right: 0,\n marginRight: '-0.71em'\n } : {\n left: 0,\n marginLeft: '-0.71em'\n }, {\n height: '1em',\n width: '0.71em',\n '&::before': {\n transformOrigin: '0 0'\n }\n })\n}));\nconst TooltipTooltip = styled('div', {\n name: 'MuiTooltip',\n slot: 'Tooltip',\n overridesResolver: (props, styles) => {\n const {\n ownerState\n } = props;\n return [styles.tooltip, ownerState.touch && styles.touch, ownerState.arrow && styles.tooltipArrow, styles[`tooltipPlacement${capitalize(ownerState.placement.split('-')[0])}`]];\n }\n})(({\n theme,\n ownerState\n}) => _extends({\n backgroundColor: theme.vars ? theme.vars.palette.Tooltip.bg : alpha(theme.palette.grey[700], 0.92),\n borderRadius: (theme.vars || theme).shape.borderRadius,\n color: (theme.vars || theme).palette.common.white,\n fontFamily: theme.typography.fontFamily,\n padding: '4px 8px',\n fontSize: theme.typography.pxToRem(11),\n maxWidth: 300,\n margin: 2,\n wordWrap: 'break-word',\n fontWeight: theme.typography.fontWeightMedium\n}, ownerState.arrow && {\n position: 'relative',\n margin: 0\n}, ownerState.touch && {\n padding: '8px 16px',\n fontSize: theme.typography.pxToRem(14),\n lineHeight: `${round(16 / 14)}em`,\n fontWeight: theme.typography.fontWeightRegular\n}, {\n [`.${tooltipClasses.popper}[data-popper-placement*=\"left\"] &`]: _extends({\n transformOrigin: 'right center'\n }, !ownerState.isRtl ? _extends({\n marginRight: '14px'\n }, ownerState.touch && {\n marginRight: '24px'\n }) : _extends({\n marginLeft: '14px'\n }, ownerState.touch && {\n marginLeft: '24px'\n })),\n [`.${tooltipClasses.popper}[data-popper-placement*=\"right\"] &`]: _extends({\n transformOrigin: 'left center'\n }, !ownerState.isRtl ? _extends({\n marginLeft: '14px'\n }, ownerState.touch && {\n marginLeft: '24px'\n }) : _extends({\n marginRight: '14px'\n }, ownerState.touch && {\n marginRight: '24px'\n })),\n [`.${tooltipClasses.popper}[data-popper-placement*=\"top\"] &`]: _extends({\n transformOrigin: 'center bottom',\n marginBottom: '14px'\n }, ownerState.touch && {\n marginBottom: '24px'\n }),\n [`.${tooltipClasses.popper}[data-popper-placement*=\"bottom\"] &`]: _extends({\n transformOrigin: 'center top',\n marginTop: '14px'\n }, ownerState.touch && {\n marginTop: '24px'\n })\n}));\nconst TooltipArrow = styled('span', {\n name: 'MuiTooltip',\n slot: 'Arrow',\n overridesResolver: (props, styles) => styles.arrow\n})(({\n theme\n}) => ({\n overflow: 'hidden',\n position: 'absolute',\n width: '1em',\n height: '0.71em' /* = width / sqrt(2) = (length of the hypotenuse) */,\n boxSizing: 'border-box',\n color: theme.vars ? theme.vars.palette.Tooltip.bg : alpha(theme.palette.grey[700], 0.9),\n '&::before': {\n content: '\"\"',\n margin: 'auto',\n display: 'block',\n width: '100%',\n height: '100%',\n backgroundColor: 'currentColor',\n transform: 'rotate(45deg)'\n }\n}));\nlet hystersisOpen = false;\nconst hystersisTimer = new Timeout();\nlet cursorPosition = {\n x: 0,\n y: 0\n};\nexport function testReset() {\n hystersisOpen = false;\n hystersisTimer.clear();\n}\nfunction composeEventHandler(handler, eventHandler) {\n return event => {\n if (eventHandler) {\n eventHandler(event);\n }\n handler(event);\n };\n}\n\n// TODO v6: Remove PopperComponent, PopperProps, TransitionComponent and TransitionProps.\nconst Tooltip = /*#__PURE__*/React.forwardRef(function Tooltip(inProps, ref) {\n var _ref, _slots$popper, _ref2, _ref3, _slots$transition, _ref4, _slots$tooltip, _ref5, _slots$arrow, _slotProps$popper, _ref6, _slotProps$popper2, _slotProps$transition, _slotProps$tooltip, _ref7, _slotProps$tooltip2, _slotProps$arrow, _ref8, _slotProps$arrow2;\n const props = useThemeProps({\n props: inProps,\n name: 'MuiTooltip'\n });\n const {\n arrow = false,\n children: childrenProp,\n components = {},\n componentsProps = {},\n describeChild = false,\n disableFocusListener = false,\n disableHoverListener = false,\n disableInteractive: disableInteractiveProp = false,\n disableTouchListener = false,\n enterDelay = 100,\n enterNextDelay = 0,\n enterTouchDelay = 700,\n followCursor = false,\n id: idProp,\n leaveDelay = 0,\n leaveTouchDelay = 1500,\n onClose,\n onOpen,\n open: openProp,\n placement = 'bottom',\n PopperComponent: PopperComponentProp,\n PopperProps = {},\n slotProps = {},\n slots = {},\n title,\n TransitionComponent: TransitionComponentProp = Grow,\n TransitionProps\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n\n // to prevent runtime errors, developers will need to provide a child as a React element anyway.\n const children = /*#__PURE__*/React.isValidElement(childrenProp) ? childrenProp : /*#__PURE__*/_jsx(\"span\", {\n children: childrenProp\n });\n const theme = useTheme();\n const isRtl = theme.direction === 'rtl';\n const [childNode, setChildNode] = React.useState();\n const [arrowRef, setArrowRef] = React.useState(null);\n const ignoreNonTouchEvents = React.useRef(false);\n const disableInteractive = disableInteractiveProp || followCursor;\n const closeTimer = useTimeout();\n const enterTimer = useTimeout();\n const leaveTimer = useTimeout();\n const touchTimer = useTimeout();\n const [openState, setOpenState] = useControlled({\n controlled: openProp,\n default: false,\n name: 'Tooltip',\n state: 'open'\n });\n let open = openState;\n if (process.env.NODE_ENV !== 'production') {\n // eslint-disable-next-line react-hooks/rules-of-hooks\n const {\n current: isControlled\n } = React.useRef(openProp !== undefined);\n\n // eslint-disable-next-line react-hooks/rules-of-hooks\n React.useEffect(() => {\n if (childNode && childNode.disabled && !isControlled && title !== '' && childNode.tagName.toLowerCase() === 'button') {\n console.error(['MUI: You are providing a disabled `button` child to the Tooltip component.', 'A disabled element does not fire events.', \"Tooltip needs to listen to the child element's events to display the title.\", '', 'Add a simple wrapper element, such as a `span`.'].join('\\n'));\n }\n }, [title, childNode, isControlled]);\n }\n const id = useId(idProp);\n const prevUserSelect = React.useRef();\n const stopTouchInteraction = useEventCallback(() => {\n if (prevUserSelect.current !== undefined) {\n document.body.style.WebkitUserSelect = prevUserSelect.current;\n prevUserSelect.current = undefined;\n }\n touchTimer.clear();\n });\n React.useEffect(() => stopTouchInteraction, [stopTouchInteraction]);\n const handleOpen = event => {\n hystersisTimer.clear();\n hystersisOpen = true;\n\n // The mouseover event will trigger for every nested element in the tooltip.\n // We can skip rerendering when the tooltip is already open.\n // We are using the mouseover event instead of the mouseenter event to fix a hide/show issue.\n setOpenState(true);\n if (onOpen && !open) {\n onOpen(event);\n }\n };\n const handleClose = useEventCallback(\n /**\n * @param {React.SyntheticEvent | Event} event\n */\n event => {\n hystersisTimer.start(800 + leaveDelay, () => {\n hystersisOpen = false;\n });\n setOpenState(false);\n if (onClose && open) {\n onClose(event);\n }\n closeTimer.start(theme.transitions.duration.shortest, () => {\n ignoreNonTouchEvents.current = false;\n });\n });\n const handleEnter = event => {\n if (ignoreNonTouchEvents.current && event.type !== 'touchstart') {\n return;\n }\n\n // Remove the title ahead of time.\n // We don't want to wait for the next render commit.\n // We would risk displaying two tooltips at the same time (native + this one).\n if (childNode) {\n childNode.removeAttribute('title');\n }\n enterTimer.clear();\n leaveTimer.clear();\n if (enterDelay || hystersisOpen && enterNextDelay) {\n enterTimer.start(hystersisOpen ? enterNextDelay : enterDelay, () => {\n handleOpen(event);\n });\n } else {\n handleOpen(event);\n }\n };\n const handleLeave = event => {\n enterTimer.clear();\n leaveTimer.start(leaveDelay, () => {\n handleClose(event);\n });\n };\n const {\n isFocusVisibleRef,\n onBlur: handleBlurVisible,\n onFocus: handleFocusVisible,\n ref: focusVisibleRef\n } = useIsFocusVisible();\n // We don't necessarily care about the focusVisible state (which is safe to access via ref anyway).\n // We just need to re-render the Tooltip if the focus-visible state changes.\n const [, setChildIsFocusVisible] = React.useState(false);\n const handleBlur = event => {\n handleBlurVisible(event);\n if (isFocusVisibleRef.current === false) {\n setChildIsFocusVisible(false);\n handleLeave(event);\n }\n };\n const handleFocus = event => {\n // Workaround for https://github.com/facebook/react/issues/7769\n // The autoFocus of React might trigger the event before the componentDidMount.\n // We need to account for this eventuality.\n if (!childNode) {\n setChildNode(event.currentTarget);\n }\n handleFocusVisible(event);\n if (isFocusVisibleRef.current === true) {\n setChildIsFocusVisible(true);\n handleEnter(event);\n }\n };\n const detectTouchStart = event => {\n ignoreNonTouchEvents.current = true;\n const childrenProps = children.props;\n if (childrenProps.onTouchStart) {\n childrenProps.onTouchStart(event);\n }\n };\n const handleMouseOver = handleEnter;\n const handleMouseLeave = handleLeave;\n const handleTouchStart = event => {\n detectTouchStart(event);\n leaveTimer.clear();\n closeTimer.clear();\n stopTouchInteraction();\n prevUserSelect.current = document.body.style.WebkitUserSelect;\n // Prevent iOS text selection on long-tap.\n document.body.style.WebkitUserSelect = 'none';\n touchTimer.start(enterTouchDelay, () => {\n document.body.style.WebkitUserSelect = prevUserSelect.current;\n handleEnter(event);\n });\n };\n const handleTouchEnd = event => {\n if (children.props.onTouchEnd) {\n children.props.onTouchEnd(event);\n }\n stopTouchInteraction();\n leaveTimer.start(leaveTouchDelay, () => {\n handleClose(event);\n });\n };\n React.useEffect(() => {\n if (!open) {\n return undefined;\n }\n\n /**\n * @param {KeyboardEvent} nativeEvent\n */\n function handleKeyDown(nativeEvent) {\n // IE11, Edge (prior to using Bink?) use 'Esc'\n if (nativeEvent.key === 'Escape' || nativeEvent.key === 'Esc') {\n handleClose(nativeEvent);\n }\n }\n document.addEventListener('keydown', handleKeyDown);\n return () => {\n document.removeEventListener('keydown', handleKeyDown);\n };\n }, [handleClose, open]);\n const handleRef = useForkRef(children.ref, focusVisibleRef, setChildNode, ref);\n\n // There is no point in displaying an empty tooltip.\n // So we exclude all falsy values, except 0, which is valid.\n if (!title && title !== 0) {\n open = false;\n }\n const popperRef = React.useRef();\n const handleMouseMove = event => {\n const childrenProps = children.props;\n if (childrenProps.onMouseMove) {\n childrenProps.onMouseMove(event);\n }\n cursorPosition = {\n x: event.clientX,\n y: event.clientY\n };\n if (popperRef.current) {\n popperRef.current.update();\n }\n };\n const nameOrDescProps = {};\n const titleIsString = typeof title === 'string';\n if (describeChild) {\n nameOrDescProps.title = !open && titleIsString && !disableHoverListener ? title : null;\n nameOrDescProps['aria-describedby'] = open ? id : null;\n } else {\n nameOrDescProps['aria-label'] = titleIsString ? title : null;\n nameOrDescProps['aria-labelledby'] = open && !titleIsString ? id : null;\n }\n const childrenProps = _extends({}, nameOrDescProps, other, children.props, {\n className: clsx(other.className, children.props.className),\n onTouchStart: detectTouchStart,\n ref: handleRef\n }, followCursor ? {\n onMouseMove: handleMouseMove\n } : {});\n if (process.env.NODE_ENV !== 'production') {\n childrenProps['data-mui-internal-clone-element'] = true;\n\n // eslint-disable-next-line react-hooks/rules-of-hooks\n React.useEffect(() => {\n if (childNode && !childNode.getAttribute('data-mui-internal-clone-element')) {\n console.error(['MUI: The `children` component of the Tooltip is not forwarding its props correctly.', 'Please make sure that props are spread on the same element that the ref is applied to.'].join('\\n'));\n }\n }, [childNode]);\n }\n const interactiveWrapperListeners = {};\n if (!disableTouchListener) {\n childrenProps.onTouchStart = handleTouchStart;\n childrenProps.onTouchEnd = handleTouchEnd;\n }\n if (!disableHoverListener) {\n childrenProps.onMouseOver = composeEventHandler(handleMouseOver, childrenProps.onMouseOver);\n childrenProps.onMouseLeave = composeEventHandler(handleMouseLeave, childrenProps.onMouseLeave);\n if (!disableInteractive) {\n interactiveWrapperListeners.onMouseOver = handleMouseOver;\n interactiveWrapperListeners.onMouseLeave = handleMouseLeave;\n }\n }\n if (!disableFocusListener) {\n childrenProps.onFocus = composeEventHandler(handleFocus, childrenProps.onFocus);\n childrenProps.onBlur = composeEventHandler(handleBlur, childrenProps.onBlur);\n if (!disableInteractive) {\n interactiveWrapperListeners.onFocus = handleFocus;\n interactiveWrapperListeners.onBlur = handleBlur;\n }\n }\n if (process.env.NODE_ENV !== 'production') {\n if (children.props.title) {\n console.error(['MUI: You have provided a `title` prop to the child of .', `Remove this title prop \\`${children.props.title}\\` or the Tooltip component.`].join('\\n'));\n }\n }\n const popperOptions = React.useMemo(() => {\n var _PopperProps$popperOp;\n let tooltipModifiers = [{\n name: 'arrow',\n enabled: Boolean(arrowRef),\n options: {\n element: arrowRef,\n padding: 4\n }\n }];\n if ((_PopperProps$popperOp = PopperProps.popperOptions) != null && _PopperProps$popperOp.modifiers) {\n tooltipModifiers = tooltipModifiers.concat(PopperProps.popperOptions.modifiers);\n }\n return _extends({}, PopperProps.popperOptions, {\n modifiers: tooltipModifiers\n });\n }, [arrowRef, PopperProps]);\n const ownerState = _extends({}, props, {\n isRtl,\n arrow,\n disableInteractive,\n placement,\n PopperComponentProp,\n touch: ignoreNonTouchEvents.current\n });\n const classes = useUtilityClasses(ownerState);\n const PopperComponent = (_ref = (_slots$popper = slots.popper) != null ? _slots$popper : components.Popper) != null ? _ref : TooltipPopper;\n const TransitionComponent = (_ref2 = (_ref3 = (_slots$transition = slots.transition) != null ? _slots$transition : components.Transition) != null ? _ref3 : TransitionComponentProp) != null ? _ref2 : Grow;\n const TooltipComponent = (_ref4 = (_slots$tooltip = slots.tooltip) != null ? _slots$tooltip : components.Tooltip) != null ? _ref4 : TooltipTooltip;\n const ArrowComponent = (_ref5 = (_slots$arrow = slots.arrow) != null ? _slots$arrow : components.Arrow) != null ? _ref5 : TooltipArrow;\n const popperProps = appendOwnerState(PopperComponent, _extends({}, PopperProps, (_slotProps$popper = slotProps.popper) != null ? _slotProps$popper : componentsProps.popper, {\n className: clsx(classes.popper, PopperProps == null ? void 0 : PopperProps.className, (_ref6 = (_slotProps$popper2 = slotProps.popper) != null ? _slotProps$popper2 : componentsProps.popper) == null ? void 0 : _ref6.className)\n }), ownerState);\n const transitionProps = appendOwnerState(TransitionComponent, _extends({}, TransitionProps, (_slotProps$transition = slotProps.transition) != null ? _slotProps$transition : componentsProps.transition), ownerState);\n const tooltipProps = appendOwnerState(TooltipComponent, _extends({}, (_slotProps$tooltip = slotProps.tooltip) != null ? _slotProps$tooltip : componentsProps.tooltip, {\n className: clsx(classes.tooltip, (_ref7 = (_slotProps$tooltip2 = slotProps.tooltip) != null ? _slotProps$tooltip2 : componentsProps.tooltip) == null ? void 0 : _ref7.className)\n }), ownerState);\n const tooltipArrowProps = appendOwnerState(ArrowComponent, _extends({}, (_slotProps$arrow = slotProps.arrow) != null ? _slotProps$arrow : componentsProps.arrow, {\n className: clsx(classes.arrow, (_ref8 = (_slotProps$arrow2 = slotProps.arrow) != null ? _slotProps$arrow2 : componentsProps.arrow) == null ? void 0 : _ref8.className)\n }), ownerState);\n return /*#__PURE__*/_jsxs(React.Fragment, {\n children: [/*#__PURE__*/React.cloneElement(children, childrenProps), /*#__PURE__*/_jsx(PopperComponent, _extends({\n as: PopperComponentProp != null ? PopperComponentProp : Popper,\n placement: placement,\n anchorEl: followCursor ? {\n getBoundingClientRect: () => ({\n top: cursorPosition.y,\n left: cursorPosition.x,\n right: cursorPosition.x,\n bottom: cursorPosition.y,\n width: 0,\n height: 0\n })\n } : childNode,\n popperRef: popperRef,\n open: childNode ? open : false,\n id: id,\n transition: true\n }, interactiveWrapperListeners, popperProps, {\n popperOptions: popperOptions,\n children: ({\n TransitionProps: TransitionPropsInner\n }) => /*#__PURE__*/_jsx(TransitionComponent, _extends({\n timeout: theme.transitions.duration.shorter\n }, TransitionPropsInner, transitionProps, {\n children: /*#__PURE__*/_jsxs(TooltipComponent, _extends({}, tooltipProps, {\n children: [title, arrow ? /*#__PURE__*/_jsx(ArrowComponent, _extends({}, tooltipArrowProps, {\n ref: setArrowRef\n })) : null]\n }))\n }))\n }))]\n });\n});\nprocess.env.NODE_ENV !== \"production\" ? Tooltip.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the d.ts file and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * If `true`, adds an arrow to the tooltip.\n * @default false\n */\n arrow: PropTypes.bool,\n /**\n * Tooltip reference element.\n */\n children: elementAcceptingRef.isRequired,\n /**\n * Override or extend the styles applied to the component.\n */\n classes: PropTypes.object,\n /**\n * @ignore\n */\n className: PropTypes.string,\n /**\n * The components used for each slot inside.\n *\n * This prop is an alias for the `slots` prop.\n * It's recommended to use the `slots` prop instead.\n *\n * @default {}\n */\n components: PropTypes.shape({\n Arrow: PropTypes.elementType,\n Popper: PropTypes.elementType,\n Tooltip: PropTypes.elementType,\n Transition: PropTypes.elementType\n }),\n /**\n * The extra props for the slot components.\n * You can override the existing props or add new ones.\n *\n * This prop is an alias for the `slotProps` prop.\n * It's recommended to use the `slotProps` prop instead, as `componentsProps` will be deprecated in the future.\n *\n * @default {}\n */\n componentsProps: PropTypes.shape({\n arrow: PropTypes.object,\n popper: PropTypes.object,\n tooltip: PropTypes.object,\n transition: PropTypes.object\n }),\n /**\n * Set to `true` if the `title` acts as an accessible description.\n * By default the `title` acts as an accessible label for the child.\n * @default false\n */\n describeChild: PropTypes.bool,\n /**\n * Do not respond to focus-visible events.\n * @default false\n */\n disableFocusListener: PropTypes.bool,\n /**\n * Do not respond to hover events.\n * @default false\n */\n disableHoverListener: PropTypes.bool,\n /**\n * Makes a tooltip not interactive, i.e. it will close when the user\n * hovers over the tooltip before the `leaveDelay` is expired.\n * @default false\n */\n disableInteractive: PropTypes.bool,\n /**\n * Do not respond to long press touch events.\n * @default false\n */\n disableTouchListener: PropTypes.bool,\n /**\n * The number of milliseconds to wait before showing the tooltip.\n * This prop won't impact the enter touch delay (`enterTouchDelay`).\n * @default 100\n */\n enterDelay: PropTypes.number,\n /**\n * The number of milliseconds to wait before showing the tooltip when one was already recently opened.\n * @default 0\n */\n enterNextDelay: PropTypes.number,\n /**\n * The number of milliseconds a user must touch the element before showing the tooltip.\n * @default 700\n */\n enterTouchDelay: PropTypes.number,\n /**\n * If `true`, the tooltip follow the cursor over the wrapped element.\n * @default false\n */\n followCursor: PropTypes.bool,\n /**\n * This prop is used to help implement the accessibility logic.\n * If you don't provide this prop. It falls back to a randomly generated id.\n */\n id: PropTypes.string,\n /**\n * The number of milliseconds to wait before hiding the tooltip.\n * This prop won't impact the leave touch delay (`leaveTouchDelay`).\n * @default 0\n */\n leaveDelay: PropTypes.number,\n /**\n * The number of milliseconds after the user stops touching an element before hiding the tooltip.\n * @default 1500\n */\n leaveTouchDelay: PropTypes.number,\n /**\n * Callback fired when the component requests to be closed.\n *\n * @param {React.SyntheticEvent} event The event source of the callback.\n */\n onClose: PropTypes.func,\n /**\n * Callback fired when the component requests to be open.\n *\n * @param {React.SyntheticEvent} event The event source of the callback.\n */\n onOpen: PropTypes.func,\n /**\n * If `true`, the component is shown.\n */\n open: PropTypes.bool,\n /**\n * Tooltip placement.\n * @default 'bottom'\n */\n placement: PropTypes.oneOf(['bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n /**\n * The component used for the popper.\n * @default Popper\n */\n PopperComponent: PropTypes.elementType,\n /**\n * Props applied to the [`Popper`](/material-ui/api/popper/) element.\n * @default {}\n */\n PopperProps: PropTypes.object,\n /**\n * The extra props for the slot components.\n * You can override the existing props or add new ones.\n *\n * This prop is an alias for the `componentsProps` prop, which will be deprecated in the future.\n *\n * @default {}\n */\n slotProps: PropTypes.shape({\n arrow: PropTypes.object,\n popper: PropTypes.object,\n tooltip: PropTypes.object,\n transition: PropTypes.object\n }),\n /**\n * The components used for each slot inside.\n *\n * This prop is an alias for the `components` prop, which will be deprecated in the future.\n *\n * @default {}\n */\n slots: PropTypes.shape({\n arrow: PropTypes.elementType,\n popper: PropTypes.elementType,\n tooltip: PropTypes.elementType,\n transition: PropTypes.elementType\n }),\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Tooltip title. Zero-length titles string, undefined, null and false are never displayed.\n */\n title: PropTypes.node,\n /**\n * The component used for the transition.\n * [Follow this guide](/material-ui/transitions/#transitioncomponent-prop) to learn more about the requirements for this component.\n * @default Grow\n */\n TransitionComponent: PropTypes.elementType,\n /**\n * Props applied to the transition element.\n * By default, the element is based on this [`Transition`](http://reactcommunity.org/react-transition-group/transition/) component.\n */\n TransitionProps: PropTypes.object\n} : void 0;\nexport default Tooltip;","import '@/components/mui/menu-item.component.css';\nimport ArrowRightIcon from '@mui/icons-material/ArrowRight';\nimport {\n ListItemIcon as MuiListItemIcon,\n ListItemText as MuiListItemText,\n MenuItem as MuiMenuItem,\n} from '@mui/material';\nimport Tooltip from '@mui/material/Tooltip';\nimport { Localized, ReferencedItem, SingleColumnMenu } from 'platform-bible-utils';\nimport { MouseEvent, PropsWithChildren } from 'react';\n\ntype MenuItemInfoBase = {\n /** Text (displayable in the UI) as the name of the menu item */\n label: string;\n /** Text to display when the mouse hovers over the menu item */\n tooltip?: string;\n};\n\nexport type Command = MenuItemInfoBase & {\n /** Command to execute (string.string) */\n command: string;\n};\n\ntype SubMenu = MenuItemInfoBase & {\n /** Command to execute (string.string) */\n items: MenuItemInfo[];\n};\n\nexport interface CommandHandler {\n (command: Command): void;\n}\n\nexport type MenuPropsBase = {\n /*\n * The JSON defining the menu whose items are to be rendered. This will typically be one of the\n * menus in the \"defs\" in a Platform.Bible menu (see PlatformMenus). The schema for this is\n * menuDocumentSchema (at the end of menus.model.ts). Note that while this is a\n * \"SingleColumnMenu\", somewhat bizarrely, a MultiColumnMenu is a SingleColumnMenu, so it really\n * could be a MultiColumnMenu, in which case, column had better be defined so it can be used\n * to filter out the actual groups and items to display on the column.\n */\n menuDefinition: Localized;\n\n commandHandler: CommandHandler;\n\n /**\n * Additional action to perform when any menu item is clicked. Allows the caller to handle event\n * (e.g., to close the menu).\n */\n onClick?: (event: MouseEvent) => void;\n};\n\nexport type MenuItemListProps = MenuPropsBase & {\n /** Optional unique (column) identifier */\n columnId?: ReferencedItem;\n};\n\nexport type MenuItemProps = Omit &\n PropsWithChildren<{\n /** Optional unique identifier */\n id?: string;\n\n onClick: (event: MouseEvent) => void;\n }>;\n\ntype MenuItemInfo = (Command | SubMenu) & {\n /**\n * If specified, menu item will be inset if it does not have a leading icon.\n *\n * @default true\n */\n allowForLeadingIcons?: boolean;\n /**\n * If specified, the path to the icon image to display on the leading side of the menu text.\n *\n * @default undefined (no leading icon will be shown)\n */\n iconPathBefore?: string;\n /**\n * If specified, the path to the icon image to display on the trailing side of the menu text.\n *\n * @default undefined (no trailing icon will be shown)\n */\n iconPathAfter?: string;\n /**\n * If true, list item is focused during the first mount\n *\n * @default false\n */\n hasAutoFocus?: boolean;\n\n /** Additional css classes to help with unique styling of the menu item */\n className?: string;\n\n /**\n * If true, the menu item will appear disabled and it will not respond to clicks or mouse hovers.\n *\n * @default false\n */\n isDisabled?: boolean;\n\n /**\n * If true, compact vertical padding designed for keyboard and mouse input is used.\n *\n * @default true\n */\n isDense?: boolean;\n\n /**\n * If true, a right-arrow icon will be displayed (iconPathAfter, if specified, will be ignored).\n *\n * @default false\n */\n isSubMenuParent?: boolean;\n\n /**\n * If true, the left and right padding is removed\n *\n * @default false\n */\n hasDisabledGutters?: boolean;\n\n /**\n * If true, a 1px light border is added to bottom of menu item\n *\n * @default false\n */\n hasDivider?: boolean;\n\n /** Help identify which element has keyboard focus */\n focusVisibleClassName?: string;\n\n /** If it's a submenu, it should have the items property */\n items?: MenuItemInfo[];\n};\n\nfunction getIcon(icon: string | undefined, menuLabel: string, leading: boolean) {\n return icon ? (\n \n {`${leading\n \n ) : undefined;\n}\n\nexport default function MenuItem(props: MenuItemProps) {\n const {\n onClick,\n label,\n tooltip,\n allowForLeadingIcons = true,\n iconPathBefore = undefined,\n iconPathAfter = undefined,\n hasAutoFocus = false,\n className,\n isDisabled = false,\n isDense = true,\n isSubMenuParent = false,\n hasDisabledGutters = false,\n hasDivider = false,\n focusVisibleClassName,\n id,\n children,\n } = props;\n\n const menuItem = (\n \n {label ? (\n <>\n {getIcon(iconPathBefore, label, true)}\n \n {isSubMenuParent ? (\n \n \n \n ) : (\n getIcon(iconPathAfter, label, false)\n )}\n \n ) : (\n children\n )}\n \n );\n\n return tooltip ? (\n \n
    {menuItem}
    \n
    \n ) : (\n menuItem\n );\n}\n","import MenuItem, {\n MenuItemListProps,\n MenuItemProps,\n MenuPropsBase,\n} from '@/components/mui/menu-item.component';\nimport { Menu } from '@mui/material';\nimport {\n Localized,\n MenuGroupDetailsInSubMenu,\n MenuItemContainingCommand,\n MenuItemContainingSubmenu,\n OrderedExtensibleContainer,\n ReferencedItem,\n SingleColumnMenu,\n} from 'platform-bible-utils';\nimport { MouseEvent, useMemo, useState } from 'react';\n\n/**\n * All the exported types in this file should be regarded as \"internal\" (i.e., they should not be\n * exposed via index.ts).\n */\n\nexport type GroupedMenuPropsBase = MenuPropsBase & {\n /** Optional unique (column) identifier */\n columnId?: ReferencedItem;\n};\n\nexport type GroupedMenuItemListProps = MenuItemListProps & {\n /**\n * If the menuDefinition includes \"top-level\" groups (i.e., those that belong to a column as\n * opposed to those that belong to a submenu) that should not be included in the list, then this\n * array specifies which groups to include. Likewise, for a submenu, this list indicates which\n * groups are pertinent for that submenu. So then for a context menu this property need not be\n * specified since it is a top-level menu based on a \"true\" SingleColumnMenu (i.e., one that is\n * not a MultiColumnMenu).\n */\n includedGroups?: {\n id: string;\n group: Localized;\n }[];\n};\n\ninterface ItemInfo {\n item: Localized;\n isLastItemInGroup: boolean;\n}\n\ntype SubMenuProps = MenuPropsBase & {\n parentMenuItem: Localized;\n parentItemProps: Omit, 'iconPathAfter'>;\n};\n\nfunction getAllGroups(menuDefinition: Localized) {\n const groupEntries = Object.entries(menuDefinition.groups);\n // Convert array of entries to array of objects with id and group properties\n return groupEntries.map(([key, value]) => ({ id: key, group: value }));\n}\n\nfunction SubMenu(props: SubMenuProps) {\n const [anchorEl, setAnchorEl] = useState(undefined);\n\n const { parentMenuItem, parentItemProps, menuDefinition } = props;\n\n const handleParentMenuItemClick = (event: MouseEvent) => {\n setAnchorEl(event.currentTarget);\n };\n\n const handleClose = () => {\n setAnchorEl(undefined);\n };\n\n const renderSubMenuItems = () => {\n let includedGroups = getAllGroups(menuDefinition).filter((g) => 'menuItem' in g.group);\n\n // Ensure valid parent menu was provided. (If not, submenu will contain all groups!)\n if (!parentMenuItem?.id) throw new Error('A valid parent menu item is required for submenus.');\n\n // When laying out a submenu, only include groups associated with the provided parent menu.\n // Note: without the (annoying) redundant check that the included groups\n // have the menuItem field, TS doesn't think it exists.\n includedGroups = includedGroups.filter(\n (group) => 'menuItem' in group.group && group.group.menuItem === parentMenuItem.id,\n );\n\n return ;\n };\n\n return (\n <>\n \n \n {renderSubMenuItems()}\n \n \n );\n}\n\nconst getOrderedGroupItems = (\n groupId: string,\n allItems: Localized[],\n) => {\n // Filter items that belong to the specified group\n const itemsForGroup = allItems.filter((item) => item.group === groupId);\n // Sort items based on order\n const sortedItems = itemsForGroup.sort((a, b) => (a.order || 0) - (b.order || 0));\n return sortedItems;\n};\n\n/**\n * This component is internal; it does not need to be exposed to the outside world since it is not\n * useful on its own. It is used to generate and lay out the MenuItems that appear either on a\n * top-level menu (in a GridMenu or ContextMenu) or in a submenu.\n */\nexport default function GroupedMenuItemList(menuProps: GroupedMenuItemListProps) {\n const { menuDefinition, onClick, commandHandler, includedGroups } = menuProps;\n\n const { items, allowForLeadingIcons } = useMemo(() => {\n const groupsToInclude =\n includedGroups && includedGroups.length > 0\n ? includedGroups\n : // We're apparently laying out a single-column menu (presumably a context menu). In this\n // case, all groups should be included except ones that belong to a submenu.\n getAllGroups(menuDefinition).filter((g) => !('menuItem' in g.group));\n\n const sortedGroups = Object.values(groupsToInclude).sort(\n (a, b) => (a.group.order || 0) - (b.group.order || 0),\n );\n\n const itemArray: ItemInfo[] = [];\n\n sortedGroups.forEach((group) => {\n getOrderedGroupItems(group.id, menuDefinition.items).forEach((item) =>\n itemArray.push({ item, isLastItemInGroup: false }),\n );\n if (itemArray.length > 0) itemArray[itemArray.length - 1].isLastItemInGroup = true;\n });\n\n // No divider after last item in final group.\n if (itemArray.length > 0) itemArray[itemArray.length - 1].isLastItemInGroup = false;\n\n const allowSpaceForLeadingIcons = itemArray.some(\n (i) => 'iconPathBefore' in i.item && i.item.iconPathBefore,\n );\n\n return { items: itemArray, allowForLeadingIcons: allowSpaceForLeadingIcons };\n }, [includedGroups, menuDefinition]);\n\n // Create props for MenuItem component including setting hasDivider for the last item in a group\n const createMenuItemProps = ({ item, isLastItemInGroup }: ItemInfo) => {\n const menuItemProps = {\n className: 'papi-menu-item',\n label: item.label,\n tooltip: item.tooltip,\n iconPathBefore: 'iconPathBefore' in item ? item.iconPathBefore : undefined,\n iconPathAfter: 'iconPathAfter' in item ? item.iconPathAfter : undefined,\n hasDivider: isLastItemInGroup, // Set hasDivider to true for the last item in a group\n allowForLeadingIcons,\n };\n\n return menuItemProps;\n };\n\n const [firstItem] = items;\n\n if (!firstItem) return
    ;\n\n const divKey = firstItem.item.group;\n\n return (\n
    \n {items.map((itemInfo, index) => {\n const { item } = itemInfo;\n const menuItemProps = createMenuItemProps(itemInfo);\n if ('command' in item) {\n const key = item.group + index;\n return (\n ) => {\n onClick?.(event);\n commandHandler(item);\n }}\n {...menuItemProps}\n />\n );\n }\n return (\n \n );\n })}\n
    \n );\n}\n","import GroupedMenuItemList from '@/components/mui/grouped-menu-item-list.component';\nimport { MenuItemListProps } from '@/components/mui/menu-item.component';\nimport { MultiColumnMenu } from 'platform-bible-utils';\n\n/**\n * This component is internal; it does not need to be exposed to the outside world since it is not\n * useful on its own. Use either GridMenu or ContextMenu.\n */\nexport default function TopLevelMenu(props: MenuItemListProps) {\n const { menuDefinition, columnId } = props;\n\n const groupEntries = Object.entries(menuDefinition.groups);\n // Convert array of entries to array of objects with id and group properties\n const groups = groupEntries.map(([key, value]) => ({ id: key, group: value }));\n let includedGroups = groups.filter((g) => 'column' in g.group);\n\n // Check if column is provided and menuDefinition is a MultiColumnMenu\n if (\n columnId &&\n 'columns' in menuDefinition &&\n // Without this type assertion, TS doesn't know what columns is.\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n (menuDefinition as MultiColumnMenu).columns[columnId]\n ) {\n // When laying out a single column in a MultiColumnMenu, only include groups associated with\n // the provided column. Note: without the (annoying) redundant check that the included groups\n // have the colum field, TS doesn't think it exists.\n includedGroups = includedGroups.filter(\n (g) => 'column' in g.group && g.group.column === columnId,\n );\n }\n\n return ;\n}\n","import '@/components/mui/grid-menu.component.css';\nimport { GroupedMenuPropsBase } from '@/components/mui/grouped-menu-item-list.component';\nimport { CommandHandler } from '@/components/mui/menu-item.component';\nimport TopLevelMenu from '@/components/mui/top-level-menu.component';\nimport { Grid, List } from '@mui/material';\nimport {\n Localized,\n MenuColumnWithHeader,\n MultiColumnMenu,\n ReferencedItem,\n} from 'platform-bible-utils';\nimport { useMemo } from 'react';\n\ntype ColumnInfo = {\n /*\n * The ID (`${string}.${string}`) of a specific menu column.\n */\n id: ReferencedItem;\n\n /*\n * Metadata (label, order, etc.) for a specific menu column.\n */\n metadata: Localized;\n};\n\ntype MenuColumnProps = ColumnInfo &\n GroupedMenuPropsBase & {\n /** Additional css classes to help with unique styling of the menu column */\n className?: string;\n };\n\nexport type GridMenuInfo = {\n /** The menu object containing information about the columns, groups, and items to display. */\n multiColumnMenu: Localized;\n};\n\nexport type GridMenuProps = GridMenuInfo & {\n /** Optional unique identifier */\n id?: string;\n\n commandHandler: CommandHandler;\n\n /** Additional css classes to help with unique styling of the grid menu */\n className?: string;\n};\n\nfunction MenuColumn({\n commandHandler,\n menuDefinition,\n id,\n metadata,\n onClick,\n className,\n}: MenuColumnProps) {\n return (\n \n

    \n {metadata.label}\n

    \n {/* It would seem as though this List component were unnecessary, since it only contains one\n thing, but the \"dense\" property does affect the layout of the items (in a way I don't fully\n understand). There might be a better way. */}\n \n \n \n \n );\n}\n\nexport default function GridMenu({\n commandHandler,\n className,\n multiColumnMenu,\n id,\n}: GridMenuProps) {\n const { columns } = multiColumnMenu;\n\n const sortedColumns = useMemo(() => {\n const columnNumbers = new Map();\n Object.getOwnPropertyNames(columns).forEach((columnName: string) => {\n // We know for sure there is a (boolean) property 'isExtensible' that we are not interested in.\n if (columnName === 'isExtensible') return;\n // TS doesn't allow `columnName` above to be a ReferencedItem even though the type says it is\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const columnId = columnName as ReferencedItem;\n const column = columns[columnId];\n // As of right now (and hopefully forever after), all remaining properties of the\n // ColumnsWithHeaders object are columns whose property names are the IDs of the columns.\n // This is an additional (redundant) sanity check. Specifically we're interested in\n // MenuColumnWithHeader objects, which TypeScript now \"knows\" we have, but at runtime all we\n // can check for is that it's an object with a valid numeric order field. That's likely good\n // enough.\n if (\n typeof column === 'object' &&\n typeof column.order === 'number' &&\n !Number.isNaN(column.order)\n )\n columnNumbers.set(column.order, { id: columnId, metadata: column });\n else\n console.warn(\n `Property ${columnName} (${typeof column}) on menu ${id} is not a valid column and is being ignored. This might indicate data corruption`,\n );\n });\n\n // Extract values and sort them based on the 'order' property\n return Array.from(columnNumbers.values()).sort((a, b) => {\n return (a.metadata.order || 0) - (b.metadata.order || 0);\n });\n }, [columns, id]);\n\n // We might need something like this if we need to be able to prevent empty columns\n // sortedColumns.filter((c) => multiColumnMenu.groups.some((g) => 'column' in g && (g as .column)...\n\n return (\n \n {sortedColumns.map((col, index) => (\n \n ))}\n \n );\n}\n","import { useEffect, useRef, useState } from 'react';\n\nexport type UsePromiseOptions = {\n /**\n * Whether to leave the value as the most recent resolved promise value or set it back to\n * defaultValue while running the promise again. Defaults to true\n */\n preserveValue?: boolean;\n};\n\n/** Set up defaults for options for usePromise hook */\nfunction getUsePromiseOptionsDefaults(options: UsePromiseOptions): UsePromiseOptions {\n return {\n preserveValue: true,\n ...options,\n };\n}\n\n/**\n * Awaits a promise and returns a loading value while the promise is unresolved\n *\n * @param promiseFactoryCallback A function that returns the promise to await. If this callback is\n * undefined, the current value will be returned (defaultValue unless it was previously changed\n * and `options.preserveValue` is true), and there will be no loading.\n *\n * WARNING: MUST BE STABLE - const or wrapped in useCallback. The reference must not be updated\n * every render\n * @param defaultValue The initial value to return while first awaiting the promise. If\n * `options.preserveValue` is false, this value is also shown while awaiting the promise on\n * subsequent calls.\n *\n * Note: this parameter is internally assigned to a `ref`, so changing it will not cause any hooks\n * to re-run with its new value. This means that, if the `promiseFactoryCallback` changes and\n * `options.preserveValue` is `false`, the returned value will be set to the current\n * `defaultValue`. However, the returned value will not be updated if`defaultValue` changes.\n * @param options Various options for adjusting how this hook runs the `promiseFactoryCallback`\n *\n * Note: this parameter is internally assigned to a `ref`, so changing it will not cause any hooks\n * to re-run with its new value. However, the latest `options.preserveValue` will always be used\n * appropriately to determine whether to preserve the returned value when changing the\n * `promiseFactoryCallback`\n * @returns `[value, isLoading]`\n *\n * - `value`: the current value for the promise, either the defaultValue or the resolved promise value\n * - `isLoading`: whether the promise is waiting to be resolved\n */\nconst usePromise = (\n promiseFactoryCallback: (() => Promise) | undefined,\n defaultValue: T,\n options: UsePromiseOptions = {},\n): [value: T, isLoading: boolean] => {\n // Use defaultValue as a ref so it doesn't update dependency arrays\n const defaultValueRef = useRef(defaultValue);\n defaultValueRef.current = defaultValue;\n // Use options as a ref so it doesn't update dependency arrays\n const optionsDefaultedRef = useRef(options);\n optionsDefaultedRef.current = getUsePromiseOptionsDefaults(optionsDefaultedRef.current);\n\n const [value, setValue] = useState(() => defaultValueRef.current);\n const [isLoading, setIsLoading] = useState(true);\n useEffect(() => {\n let promiseIsCurrent = true;\n // If a promiseFactoryCallback was provided, we are loading. Otherwise, there is no loading to do\n setIsLoading(!!promiseFactoryCallback);\n (async () => {\n // If there is a callback to run, run it\n if (promiseFactoryCallback) {\n const result = await promiseFactoryCallback();\n // If the promise was not already replaced, update the value\n if (promiseIsCurrent) {\n setValue(() => result);\n setIsLoading(false);\n }\n }\n })();\n\n return () => {\n // Mark this promise as old and not to be used\n promiseIsCurrent = false;\n if (!optionsDefaultedRef.current.preserveValue) setValue(() => defaultValueRef.current);\n };\n }, [promiseFactoryCallback]);\n\n return [value, isLoading];\n};\nexport default usePromise;\n","\"use client\";\n\nimport createSvgIcon from './utils/createSvgIcon';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nexport default createSvgIcon( /*#__PURE__*/_jsx(\"path\", {\n d: \"M3 18h18v-2H3zm0-5h18v-2H3zm0-7v2h18V6z\"\n}), 'Menu');","import GridMenu from '@/components/mui/grid-menu.component';\nimport { Command, CommandHandler } from '@/components/mui/menu-item.component';\nimport usePromise from '@/hooks/use-promise.hook';\nimport { Menu as MenuIcon } from '@mui/icons-material';\nimport { Drawer, IconButton } from '@mui/material';\nimport { Localized, MultiColumnMenu } from 'platform-bible-utils';\nimport {\n MouseEvent,\n MutableRefObject,\n PropsWithChildren,\n useCallback,\n useEffect,\n useState,\n} from 'react';\n\nexport interface MultiColumnMenuProvider {\n (isSupportAndDevelopment: boolean): Promise>;\n}\n\nexport type HamburgerMenuButtonProps = PropsWithChildren & {\n /** The handler to use for menu commands (and eventually toolbar commands). */\n commandHandler: CommandHandler;\n\n /**\n * Optional reference to the \"div\" container that determines the where the menu should appear. If\n * not defined, then (1,1) used.\n */\n containerRef?: MutableRefObject;\n\n /**\n * The delegate to use to get the menu data. If not specified or if it returns undefined, the data\n * in normalMenu or fullMenu property will be used.\n */\n menuProvider?: MultiColumnMenuProvider;\n\n /**\n * The menu data to show when the menu is opened if the menuProvider property is not defined.\n * (This allows for a default or test-only static menu to be used.)\n */\n normalMenu?: Localized;\n\n /**\n * The menu data to show for \"full\" menu (when opened with the SHIFT key pressed) if the\n * menuProvider property is not defined. (This allows for a default or test-only static menu to be\n * used.)\n */\n fullMenu?: Localized;\n\n /** Additional css class(es) to help with unique styling of the sub-components */\n className?: string;\n\n /** Value to use as prefix for ARIA labels on interactive sub-components */\n ariaLabelPrefix?: string;\n};\n\nexport default function HamburgerMenuButton({\n menuProvider,\n normalMenu,\n fullMenu,\n commandHandler,\n containerRef,\n className,\n ariaLabelPrefix,\n children,\n}: HamburgerMenuButtonProps) {\n const [isMenuOpen, setMenuOpen] = useState(false);\n const [showFullMenu, setShowFullMenu] = useState(false);\n\n const handleMenuItemClick = useCallback(() => {\n if (isMenuOpen) setMenuOpen(false);\n setShowFullMenu(false);\n }, [isMenuOpen]);\n\n const handleMenuButtonClick = useCallback((e: MouseEvent) => {\n e.stopPropagation();\n setMenuOpen((prevIsOpen) => {\n const isOpening = !prevIsOpen;\n if (isOpening && e.shiftKey) setShowFullMenu(true);\n else if (!isOpening) setShowFullMenu(false);\n return isOpening;\n });\n }, []);\n\n const menuCommandHandler = useCallback(\n (command: Command) => {\n handleMenuItemClick();\n return commandHandler(command);\n },\n [commandHandler, handleMenuItemClick],\n );\n\n const [offset, setOffset] = useState({ top: 1, left: 1 });\n\n useEffect(() => {\n if (isMenuOpen) {\n const node = containerRef?.current;\n if (node) {\n const rect = node.getBoundingClientRect();\n const scrollTop = window.scrollY;\n const scrollLeft = window.scrollX;\n const top = rect.top + scrollTop + node.clientHeight;\n const left = rect.left + scrollLeft;\n setOffset({ top, left });\n }\n }\n }, [isMenuOpen, containerRef]);\n\n const [normalMenuData] = usePromise(\n useCallback(async () => {\n return menuProvider?.(false) ?? normalMenu;\n // isMenuOpen needs to be included for the menu contents to reevaluate when reopened\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [menuProvider, normalMenu, isMenuOpen]),\n normalMenu,\n );\n\n const [fullMenuData] = usePromise(\n useCallback(async () => {\n return menuProvider?.(true) ?? fullMenu ?? normalMenuData;\n // isMenuOpen needs to be included for the menu contents to reevaluate when reopened\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [menuProvider, fullMenu, normalMenuData, isMenuOpen]),\n fullMenu ?? normalMenuData,\n );\n\n const menu = showFullMenu && fullMenuData ? fullMenuData : normalMenuData;\n\n return (\n <>\n \n {children ?? }\n \n \n {menu ? (\n \n ) : undefined}\n \n \n );\n}\n","import '@/components/mui/icon-button.component.css';\nimport { IconButton as MuiIconButton } from '@mui/material';\nimport { MouseEventHandler, PropsWithChildren } from 'react';\n\nexport type IconButtonProps = PropsWithChildren<{\n /** Optional unique identifier */\n id?: string;\n /**\n * Required. Used as both the tooltip (aka, title) and the aria-label (used for accessibility,\n * testing, etc.), unless a distinct tooltip is supplied.\n */\n label: string;\n /**\n * Enabled status of button\n *\n * @default false\n */\n isDisabled?: boolean;\n /** Optional tooltip to display if different from the aria-label. */\n tooltip?: string;\n /** If true, no tooltip will be displayed. */\n isTooltipSuppressed?: boolean;\n /**\n * If given, uses a negative margin to counteract the padding on one side (this is often helpful\n * for aligning the left or right side of the icon with content above or below, without ruining\n * the border size and shape).\n *\n * @default false\n */\n adjustMarginToAlignToEdge?: 'end' | 'start' | false;\n /**\n * The size of the component. small is equivalent to the dense button styling.\n *\n * @default false\n */\n size: 'small' | 'medium' | 'large';\n /** Additional css classes to help with unique styling of the button */\n className?: string;\n /** Optional click handler */\n onClick?: MouseEventHandler;\n}>;\n\n/**\n * Iconic button a user can click to do something\n *\n * Thanks to MUI for heavy inspiration and documentation\n * https://mui.com/material-ui/getting-started/overview/\n */\nfunction IconButton({\n id,\n label,\n isDisabled = false,\n tooltip,\n isTooltipSuppressed = false,\n adjustMarginToAlignToEdge = false,\n size = 'medium',\n className,\n onClick,\n children,\n}: IconButtonProps) {\n return (\n \n {children /* the icon to display */}\n \n );\n}\n\nexport default IconButton;\n","import { cn } from '@/utils/shadcn-ui.util';\nimport { LoaderCircle, LucideProps } from 'lucide-react';\nimport { forwardRef } from 'react';\n\nexport type SpinnerProps = LucideProps;\n\nconst Spinner = forwardRef(({ className, ...props }, ref) => {\n return (\n \n );\n});\n\nSpinner.displayName = 'Spinner';\n\nexport default Spinner;\n","import { Input as ShadInput } from '@/components/shadcn-ui/input';\nimport { Label as ShadLabel } from '@/components/shadcn-ui/label';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { ChangeEventHandler, FocusEventHandler } from 'react';\n\nexport type TextFieldProps = {\n /** Optional unique identifier */\n id?: string;\n /**\n * If `true`, the component is disabled.\n *\n * @default false\n */\n isDisabled?: boolean;\n /**\n * If `true`, the label is displayed in an error state.\n *\n * @default false\n */\n hasError?: boolean;\n /**\n * If `true`, the input will take up the full width of its container.\n *\n * @default false\n */\n isFullWidth?: boolean;\n /** Text that gives the user instructions on what contents the TextField expects */\n helperText?: string;\n /** The title of the TextField */\n label?: string;\n /** The short hint displayed in the `input` before the user enters a value. */\n placeholder?: string;\n /**\n * If `true`, the label is displayed as required and the `input` element is required.\n *\n * @default false\n */\n isRequired?: boolean;\n /** Additional css classes to help with unique styling of the text field */\n className?: string;\n /** Starting value for the text field if it is not controlled */\n defaultValue?: string | number;\n /** Value of the text field if controlled */\n value?: string | number;\n /** Triggers when content of textfield is changed */\n onChange?: ChangeEventHandler;\n /** Triggers when textfield gets focus */\n onFocus?: FocusEventHandler;\n /** Triggers when textfield loses focus */\n onBlur?: FocusEventHandler;\n};\n\n/**\n * Text input field\n *\n * Thanks to Shadcn for heavy inspiration and documentation\n * https://ui.shadcn.com/docs/components/input#with-label\n */\nfunction TextField({\n id,\n isDisabled = false,\n hasError = false,\n isFullWidth = false,\n helperText,\n label,\n placeholder,\n isRequired = false,\n className,\n defaultValue,\n value,\n onChange,\n onFocus,\n onBlur,\n}: TextFieldProps) {\n return (\n
    \n {`${label}${isRequired ? '*' : ''}`}\n \n

    {helperText}

    \n
    \n );\n}\n\nexport default TextField;\n","import HamburgerMenuButton, {\n MultiColumnMenuProvider,\n} from '@/components/mui/hamburger-menu-button.component';\nimport { CommandHandler } from '@/components/mui/menu-item.component';\nimport '@/components/mui/toolbar.component.css';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { AppBar, Toolbar as MuiToolbar } from '@mui/material';\nimport { PropsWithChildren, useRef } from 'react';\n\nexport type ToolbarProps = PropsWithChildren<{\n /** The handler to use for menu commands (and eventually toolbar commands). */\n commandHandler: CommandHandler;\n\n /**\n * The optional delegate to use to get the menu data. If not specified, the \"hamburger\" menu will\n * not display.\n */\n menuProvider?: MultiColumnMenuProvider;\n\n /** Optional unique identifier */\n id?: string;\n\n /** Additional css classes to help with unique styling of the toolbar */\n className?: string;\n}>;\n\nexport default function Toolbar({\n menuProvider,\n commandHandler,\n className,\n id,\n children,\n}: ToolbarProps) {\n // This ref will always be defined\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const containerRef = useRef(undefined!);\n\n return (\n
    \n \n \n {menuProvider ? (\n \n ) : undefined}\n {children ?
    {children}
    : undefined}\n \n
    \n
    \n );\n}\n","import React from 'react';\nimport { cva, type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst alertVariants = cva(\n 'tw-relative tw-w-full tw-rounded-lg tw-border tw-p-4 [&>svg~*]:tw-pl-7 [&>svg+div]:tw-translate-y-[-3px] [&>svg]:tw-absolute [&>svg]:tw-left-4 [&>svg]:tw-top-4 [&>svg]:tw-text-foreground',\n {\n variants: {\n variant: {\n default: 'tw-bg-background tw-text-foreground',\n destructive:\n 'tw-border-destructive/50 tw-text-destructive dark:tw-border-destructive [&>svg]:tw-text-destructive',\n },\n },\n defaultVariants: {\n variant: 'default',\n },\n },\n);\n\nconst Alert = React.forwardRef<\n HTMLDivElement,\n React.HTMLAttributes & VariantProps\n>(({ className, variant, ...props }, ref) => (\n
    \n));\nAlert.displayName = 'Alert';\n\nconst AlertTitle = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n {/* added because of https://github.com/jsx-eslint/eslint-plugin-jsx-a11y/blob/main/docs/rules/heading-has-content.md */}\n {props.children}{' '}\n \n ),\n);\nAlertTitle.displayName = 'AlertTitle';\n\nconst AlertDescription = React.forwardRef<\n HTMLParagraphElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n
    \n));\nAlertDescription.displayName = 'AlertDescription';\n\nexport { Alert, AlertTitle, AlertDescription };\n","import { ComponentProps } from 'react';\nimport { toast as sonner, Toaster } from 'sonner';\n\ntype SonnerProps = ComponentProps;\n\nfunction Sonner({ ...props }: SonnerProps) {\n return (\n \n );\n}\n\n// The re-export of the sonner function was added manually\nexport { Sonner, sonner };\n","import React from 'react';\nimport * as SliderPrimitive from '@radix-ui/react-slider';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Slider = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n \n \n \n));\nSlider.displayName = SliderPrimitive.Root.displayName;\n\nexport { Slider };\n","import React from 'react';\nimport * as SwitchPrimitives from '@radix-ui/react-switch';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Switch = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n));\nSwitch.displayName = SwitchPrimitives.Root.displayName;\n\nexport { Switch };\n","import React from 'react';\nimport * as TabsPrimitive from '@radix-ui/react-tabs';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport const Tabs = TabsPrimitive.Root;\n\nexport type TabsListProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport type TabsTriggerProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport type TabsContentProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport const TabsList = React.forwardRef<\n React.ElementRef,\n TabsListProps\n>(({ className, ...props }, ref) => (\n \n));\nTabsList.displayName = TabsPrimitive.List.displayName;\n\nexport const TabsTrigger = React.forwardRef<\n React.ElementRef,\n TabsTriggerProps\n>(({ className, ...props }, ref) => (\n \n));\nTabsTrigger.displayName = TabsPrimitive.Trigger.displayName;\n\nexport const TabsContent = React.forwardRef<\n React.ElementRef,\n TabsContentProps\n>(({ className, ...props }, ref) => (\n \n));\nTabsContent.displayName = TabsPrimitive.Content.displayName;\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Download } from 'lucide-react';\n\ntype InstallButtonProps = {\n /** The installing boolean value determines the state of the button. */\n isInstalling: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n /** Optional text for the button. */\n buttonText?: string;\n} & ButtonProps;\n\n/**\n * The InstallButton component is a button designed for initiating installs. It includes visuals for\n * active installing and idle states.\n *\n * @param isInstalling The installing boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @param buttonText Optional text for the button.\n * @returns A install button.\n */\nexport default function InstallButton({\n isInstalling,\n handleClick,\n buttonText,\n className,\n ...props\n}: InstallButtonProps) {\n return (\n \n {isInstalling ? (\n \n ) : (\n <>\n \n {buttonText}\n \n )}\n \n );\n}\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\n\ntype EnableButtonProps = {\n /** The enabling boolean value determines the state of the button. */\n isEnabling: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n} & ButtonProps;\n\n/**\n * The EnableButton component is a button designed for initiating enabling of downloads. It includes\n * visuals for active enabling and idle states.\n *\n * @param isEnabling The enabling boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @returns A button that can be used to enable.\n */\nexport default function EnableButton({\n isEnabling,\n handleClick,\n className,\n ...props\n}: EnableButtonProps) {\n return (\n \n {isEnabling ? (\n <>\n \n Enabling...\n \n ) : (\n 'Enable'\n )}\n \n );\n}\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\n\ntype DisableButtonProps = {\n /** The disabling boolean value determines the state of the button. */\n isDisabling: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n} & ButtonProps;\n\n/**\n * The DisableButton component is a button designed for initiating disabling of downloads. It\n * includes visuals for active disabling and idle states.\n *\n * @param isDisabling The disabling boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @returns A button that can be used to disable.\n */\nexport default function DisableButton({\n isDisabling,\n handleClick,\n className,\n ...props\n}: DisableButtonProps) {\n return (\n \n {isDisabling ? (\n <>\n \n Disabling...\n \n ) : (\n 'Disable'\n )}\n \n );\n}\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\n\ntype UpdateButtonProps = {\n /** The updating boolean value determines the state of the button. */\n isUpdating: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n} & ButtonProps;\n\n/**\n * The UpdateButton component is a button designed for initiating updates for downloaded extensions.\n * It includes visuals for active updating and idle states.\n *\n * @param isUpdating The updating boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @returns A button that can be used to update.\n */\nexport default function UpdateButton({\n isUpdating,\n handleClick,\n className,\n ...props\n}: UpdateButtonProps) {\n return (\n \n {isUpdating ? (\n <>\n \n Updating...\n \n ) : (\n 'Update'\n )}\n \n );\n}\n","import { cn } from '@/utils/shadcn-ui.util';\nimport Markdown, { MarkdownToJSX } from 'markdown-to-jsx';\nimport { useMemo } from 'react';\n\ninterface MarkdownRendererProps {\n /** Optional unique identifier */\n id?: string;\n /** The markdown string to render */\n markdown: string;\n className?: string;\n /**\n * The [`target` attribute for `a` html\n * tags](https://developer.mozilla.org/en-US/docs/Web/HTML/Element/a#target). Defaults to not\n * adding a `target` to `a` tags\n */\n anchorTarget?: string;\n}\n\n/**\n * This component renders markdown content given a markdown string. It uses typography styles from\n * the platform.\n *\n * @param markdown The markdown string to render.\n * @param id Optional unique identifier\n * @returns A div containing the rendered markdown content.\n */\nexport default function MarkdownRenderer({\n id,\n markdown,\n className,\n anchorTarget,\n}: MarkdownRendererProps) {\n const options: MarkdownToJSX.Options = useMemo(\n () => ({\n overrides: {\n a: {\n props: {\n target: anchorTarget,\n },\n },\n },\n }),\n [anchorTarget],\n );\n return (\n
    \n {markdown}\n
    \n );\n}\n","import { Filter, ChevronDown } from 'lucide-react';\nimport { forwardRef } from 'react';\nimport { Button } from '@/components/shadcn-ui/button';\n\n/**\n * The FilterButton component is a button designed for initiating filtering of data. It is designed\n * to be used with the dropdown menu. It uses forwardRef to pass the button to the dropdown trigger\n * asChild.\n *\n * @returns A button that can be used to filter.\n */\nconst FilterButton = forwardRef((props, ref) => {\n return (\n \n \n Filter\n \n \n );\n});\n\nexport default FilterButton;\n","import {\n DropdownMenu,\n DropdownMenuTrigger,\n DropdownMenuContent,\n DropdownMenuLabel,\n DropdownMenuGroup,\n DropdownMenuCheckboxItem,\n DropdownMenuRadioItem,\n DropdownMenuSeparator,\n} from '@/components/shadcn-ui/dropdown-menu';\nimport FilterButton from './buttons/filter-button.component';\n\nexport enum DropdownMenuItemType {\n Check,\n Radio,\n}\n\nexport type DropdownItem = {\n /** The label is the text that will be displayed on the dropdown item. */\n label: string;\n /** The itemType determines the DropdownMenuItemType type as either Check or Radio. */\n itemType: DropdownMenuItemType;\n /** The onClick function is called when the item is clicked. */\n onClick: () => void;\n};\n\nexport type DropdownGroup = {\n /**\n * The label is the text that will be displayed on the dropdown group. It is used to categorize\n * the items in the group.\n */\n label: string;\n /** The items array contains the items that will be displayed in the dropdown group */\n items: DropdownItem[];\n};\n\nexport type FilterDropdownProps = {\n /** Object unique identifier */\n id?: string;\n /** The groups array contains the groups that will be displayed in the dropdown */\n groups: DropdownGroup[];\n}; // TODO: extend the props later\n\n/**\n * The FilterDropdown component is a dropdown designed for filtering content. It includes groups of\n * items that can be checkboxes or radio items.\n *\n * @param id Optional unique identifier\n * @param groups The groups array contains the groups that will be displayed in the dropdown\n * @returns A filter dropdown.\n */\nexport default function FilterDropdown({ id, groups }: FilterDropdownProps) {\n return (\n
    \n {/* TODO: remove this once the DropDown Menu shadcn has an id prop */}\n \n \n \n \n \n {groups.map((group) => (\n
    \n {group.label}\n \n {group.items.map((item) => (\n
    \n {item.itemType === DropdownMenuItemType.Check ? (\n \n {item.label}\n \n ) : (\n \n {item.label}\n \n )}\n
    \n ))}\n
    \n \n
    \n ))}\n
    \n
    \n
    \n );\n}\n","interface NoExtensionsFoundProps {\n /** Optional unique identifier */\n id?: string;\n /** The message to display */\n message: string;\n}\n/**\n * This component displays a message to the user when no extensions are found in the marketplace.\n *\n * @param id Optional unique identifier\n * @param message The message to display.\n * @returns {JSX.Element} - Returns the message component that displays the message to the user.\n */\nexport default function NoExtensionsFound({ id, message }: NoExtensionsFoundProps) {\n return (\n
    \n
    \n

    {message}

    \n
    \n
    \n );\n}\n","import { CircleHelp, Link as LucideLink, User } from 'lucide-react';\nimport { NumberFormat } from 'platform-bible-utils';\n\n/** Interface that stores the parameters passed to the More Info component */\ninterface MoreInfoProps {\n /** Optional unique identifier */\n id?: string;\n /** The category of the extension */\n category: string;\n /** The number of downloads for the extension */\n downloads: Record;\n /** The languages supported by the extension */\n languages: string[];\n /** The URL to the more info page of the extension */\n moreInfoUrl: string;\n}\n/**\n * This component displays the more info section of the extension which includes the category,\n * number of downloads, languages, and links to the website and support\n *\n * @param id Optional unique identifier\n * @param category The category of the extension\n * @param downloads The number of downloads for the extension\n * @param languages The languages supported by the extension\n * @param moreInfoUrl The URL to the more info page of the extension\n * @returns {JSX.Element} - Returns the more info component that displays the category, number of\n * downloads, languages, and links to the website and support\n */\nexport default function MoreInfo({\n id,\n category,\n downloads,\n languages,\n moreInfoUrl,\n}: MoreInfoProps) {\n /**\n * This constant formats the number of downloads into a more readable format.\n *\n * @example 1000 -> 1K\n *\n * @example 1000000 -> 1M\n *\n * @returns The formatted number of downloads\n */\n const numberFormatted = new NumberFormat('en', {\n notation: 'compact',\n compactDisplay: 'short',\n }).format(Object.values(downloads).reduce((a: number, b: number) => a + b, 0));\n\n /** This function scrolls the window to the bottom of the page. */\n const handleScrollToBottom = () => {\n window.scrollTo(0, document.body.scrollHeight);\n };\n\n return (\n \n
    \n
    \n {category}\n
    \n CATEGORY\n
    \n
    \n
    \n
    \n \n {numberFormatted}\n
    \n USERS\n
    \n
    \n
    \n
    \n {languages.slice(0, 3).map((locale) => (\n \n {locale.toUpperCase()}\n \n ))}\n
    \n {languages.length > 3 && (\n handleScrollToBottom()}\n className=\"tw-text-xs tw-text-gray-500 tw-underline\"\n >\n +{languages.length - 3} more languages\n \n )}\n
    \n
    \n
    \n \n Website\n \n \n \n Support\n \n \n
    \n
    \n );\n}\n","import { useState } from 'react';\n\nexport type VersionInformation = {\n /** Date the version was published */\n date: string;\n /** Description of the changes in the version */\n description: string;\n};\n\n/** Type to store the version history information */\nexport type VersionHistoryType = Record;\n\n/** Interface that stores the parameters passed to the Version History component */\ninterface VersionHistoryProps {\n /** Optional unique identifier */\n id?: string;\n /** Object containing the versions mapped with their information */\n versionHistory: VersionHistoryType;\n}\n\n/**\n * Component to render the version history information shown in the footer component. Lists the 5\n * most recent versions, with the options to show all versions by pressing a button.\n *\n * @param versionHistory Object containing the versions mapped with their information\n * @param id Optional unique identifier\n * @returns Rendered version history for the Footer component\n */\nexport default function VersionHistory({ id, versionHistory }: VersionHistoryProps) {\n const [showAllVersions, setShowAllVersions] = useState(false);\n const currentDate = new Date();\n\n /**\n * Function to format the time string for the version history in the form of 'X year(s) ago'.\n *\n * @param dateString ISO Date string to determine the time string from\n * @returns Formatted time string\n */\n function formatTimeString(dateString: string) {\n const date = new Date(dateString);\n const dateDiff = new Date(currentDate.getTime() - date.getTime());\n const yearDiff = dateDiff.getUTCFullYear() - 1970;\n const monthDiff = dateDiff.getUTCMonth();\n const dayDiff = dateDiff.getUTCDate() - 1;\n\n // Determines how long ago the version was published\n let timeString = '';\n if (yearDiff > 0) {\n timeString = `${yearDiff.toString()} year${yearDiff === 1 ? '' : 's'} ago`;\n } else if (monthDiff > 0) {\n timeString = `${monthDiff.toString()} month${monthDiff === 1 ? '' : 's'} ago`;\n } else if (dayDiff === 0) {\n timeString = 'today';\n } else {\n timeString = `${dayDiff.toString()} day${dayDiff === 1 ? '' : 's'} ago`;\n }\n\n return timeString;\n }\n\n // Sorts the version history by version number\n const sortedEntries = Object.entries(versionHistory).sort((a, b) => b[0].localeCompare(a[0]));\n\n return (\n
    \n

    What`s New

    \n
      \n {(showAllVersions ? sortedEntries : sortedEntries.slice(0, 5)).map((entry) => (\n
      \n
      \n
    • \n {entry[1].description}\n
    • \n
      \n
      \n
      Version {entry[0]}
      \n
      {formatTimeString(entry[1].date)}
      \n
      \n
      \n ))}\n
    \n {sortedEntries.length > 5 && (\n setShowAllVersions(!showAllVersions)}\n className=\"tw-text-xs tw-text-gray-500 tw-underline\"\n >\n {showAllVersions ? 'Show Less Version History' : 'Show All Version History'}\n \n )}\n
    \n );\n}\n","import { useMemo } from 'react';\nimport { formatBytes } from 'platform-bible-utils';\nimport VersionHistory, { VersionHistoryType } from './version-history.component';\n\n/** Interface to store the parameters passed to the Footer component */\ninterface FooterProps {\n /** Optional unique identifier */\n id?: string;\n /** Name of the publisher */\n publisherDisplayName: string;\n /** Size of the extension file in bytes */\n fileSize: number;\n /** List of language codes supported by the extension */\n locales: string[];\n /** Object containing the version history mapped with their information */\n versionHistory: VersionHistoryType;\n}\n\n/**\n * Component to render the footer for the extension details which contains information on the\n * publisher, version history, languages, and file size.\n *\n * @param id Optional unique identifier\n * @param publisherDisplayName Name of the publisher\n * @param fileSize Size of the extension file in bytes\n * @param locales List of language codes supported by the extension\n * @param versionHistory Object containing the version history mapped with their information\n * @returns The rendered Footer component\n */\nexport default function Footer({\n id,\n publisherDisplayName,\n fileSize,\n locales,\n versionHistory,\n}: FooterProps) {\n /** Formats the file size into a human-readable format */\n const formattedFileSize = useMemo(() => formatBytes(fileSize), [fileSize]);\n\n /**\n * This function gets the display names of the languages based on the language codes.\n *\n * @param codes The list of language codes\n * @returns The list of language names\n */\n const getLanguageNames = (codes: string[]) => {\n const displayNames = new Intl.DisplayNames(navigator.language, { type: 'language' });\n return codes.map((code) => displayNames.of(code));\n };\n\n const languageNames = getLanguageNames(locales);\n\n return (\n
    \n
    \n \n
    \n
    \n

    Information

    \n
    \n

    \n Publisher\n {publisherDisplayName}\n Size\n {formattedFileSize}\n

    \n
    \n

    \n Languages\n {languageNames.join(', ')}\n

    \n
    \n
    \n
    \n
    \n
    \n );\n}\n","import { PlatformEvent, PlatformEventHandler } from 'platform-bible-utils';\nimport { useEffect } from 'react';\n\n/**\n * Adds an event handler to an event so the event handler runs when the event is emitted. Use\n * `papi.network.getNetworkEvent` to use a networked event with this hook.\n *\n * @param event The event to subscribe to.\n *\n * - If event is a `PlatformEvent`, that event will be used\n * - If event is undefined, the callback will not be subscribed. Useful if the event is not yet\n * available for example\n *\n * @param eventHandler The callback to run when the event is emitted\n *\n * WARNING: MUST BE STABLE - const or wrapped in useCallback. The reference must not be updated\n * every render\n */\nconst useEvent = (\n event: PlatformEvent | undefined,\n eventHandler: PlatformEventHandler,\n) => {\n useEffect(() => {\n // Do nothing if the event is not provided (in case the event is not yet available, for example)\n if (!event) return () => {};\n\n const unsubscriber = event(eventHandler);\n return () => {\n unsubscriber();\n };\n }, [event, eventHandler]);\n};\nexport default useEvent;\n","import { useCallback, useEffect } from 'react';\nimport { PlatformEvent, PlatformEventAsync, PlatformEventHandler } from 'platform-bible-utils';\nimport usePromise from './use-promise.hook';\n\nconst noopUnsubscriber = () => false;\n\n/**\n * Adds an event handler to an asynchronously subscribing/unsubscribing event so the event handler\n * runs when the event is emitted. Use `papi.network.getNetworkEvent` to use a networked event with\n * this hook.\n *\n * @param event The asynchronously (un)subscribing event to subscribe to.\n *\n * - If event is a `PlatformEvent` or `PlatformEventAsync`, that event will be used\n * - If event is undefined, the callback will not be subscribed. Useful if the event is not yet\n * available for example\n *\n * @param eventHandler The callback to run when the event is emitted\n *\n * WARNING: MUST BE STABLE - const or wrapped in useCallback. The reference must not be updated\n * every render\n */\nconst useEventAsync = (\n event: PlatformEvent | PlatformEventAsync | undefined,\n eventHandler: PlatformEventHandler,\n) => {\n // Subscribe to the event asynchronously\n const [unsubscribe] = usePromise(\n useCallback(async () => {\n // Do nothing if the event is not provided (in case the event is not yet available, for example)\n if (!event) return noopUnsubscriber;\n\n // Wrap subscribe and unsubscribe in promises to allow normal events to be used as well\n const unsub = await Promise.resolve(event(eventHandler));\n return async () => unsub();\n }, [eventHandler, event]),\n noopUnsubscriber,\n // We want the unsubscriber to return to default value immediately upon changing subscription\n // So the useEffect below will unsubscribe asap\n { preserveValue: false },\n );\n\n // Unsubscribe from the event asynchronously (but we aren't awaiting the unsub)\n useEffect(() => {\n return () => {\n if (unsubscribe !== noopUnsubscriber) {\n unsubscribe();\n }\n };\n }, [unsubscribe]);\n};\n\nexport default useEventAsync;\n"],"names":["twMergeCustom","extendTailwindMerge","cn","inputs","clsx","Input","React","className","type","props","ref","jsx","BookChapterInput","forwardRef","handleSearch","handleKeyDown","handleOnClick","handleSubmit","jsxs","ShadInput","event","e","History","P","R","t","s","n","N","B","O","S","K","g","k","x","T","X","V","w","L","G","A","H","C","I","y","q","U","m","l","h","c","E","D","i","a","o","u","v","f","d","b","p","J","DropdownMenu","DropdownMenuPrimitive","DropdownMenuTrigger","DropdownMenuGroup","DropdownMenuPortal","DropdownMenuSub","DropdownMenuRadioGroup","DropdownMenuSubTrigger","inset","children","ChevronRight","DropdownMenuSubContent","DropdownMenuContent","sideOffset","DropdownMenuItem","DropdownMenuCheckboxItem","checked","Check","DropdownMenuRadioItem","Circle","DropdownMenuLabel","DropdownMenuSeparator","DropdownMenuShortcut","BookMenuItem","bookId","handleSelectBook","isSelected","handleHighlightBook","bookType","ShadDropdownMenuItem","Canon","ChapterSelect","handleSelectChapter","endChapter","activeChapter","highlightedChapter","handleHighlightedChapter","chapters","_","handleMouse","useCallback","chapterNumber","chapter","GoToMenuItem","handleSort","handleLocationHistory","handleBookmarks","ShadDropdownMenuLabel","ArrowDownWideNarrow","Clock","Bookmark","ALL_BOOK_IDS","BOOK_TYPE_LABELS","BOOK_TYPE_ARRAY","SCROLL_OFFSET","SEARCH_QUERY_FORMATS","fetchGroupedBooks","fetchEndChapter","getChaptersForBook","getAllEnglishNames","isValidBookEnglishName","bookName","getBookIdFromEnglishName","formattedBookName","BookChapterControl","scrRef","searchQuery","setSearchQuery","useState","selectedBookId","setSelectedBookId","setHighlightedChapter","highlightedBookId","setHighlightedBookId","isContentOpen","setIsContentOpen","isContentOpenDelayed","setIsContentOpenDelayed","inputRef","useRef","contentRef","menuItemRef","fetchFilteredBooks","englishNameLowerCase","normalizedQuery","handleSearchInput","searchString","shouldPreventAutoClosing","controlMenuState","open","updateReference","shouldClose","verse","handleInputSubmit","format","matches","book","englishName","handleKeyDownInput","handleKeyDownContent","key","handleKeyDownMenuItem","chapterOffSet","useEffect","useLayoutEffect","scrollTimeout","scrollPosition","ShadDropdownMenu","ShadDropdownMenuTrigger","ShadDropdownMenuContent","bookTypeIndex","element","ShadDropdownMenuSeparator","buttonVariants","cva","Button","variant","size","asChild","Comp","Slot","labelVariants","Label","LabelPrimitive","RadioGroup","RadioGroupPrimitive","RadioGroupItem","Popover","PopoverPrimitive","PopoverTrigger","PopoverContent","align","DialogPortal","DialogPrimitive","DialogOverlay","DialogContent","DialogTitle","DialogDescription","Command","CommandPrimitive","CommandInput","Search","CommandList","CommandEmpty","CommandGroup","CommandSeparator","CommandItem","getOptionLabelDefault","option","ComboBox","id","options","buttonClassName","popoverContentClassName","value","onChange","getOptionLabel","buttonPlaceholder","textPlaceholder","commandEmptyMessage","buttonVariant","dir","isDisabled","setOpen","ChevronsUpDown","ChapterRangeSelector","startChapter","handleSelectStartChapter","handleSelectEndChapter","chapterCount","chapterOptions","useMemo","index","onChangeStartChapter","onChangeEndChapter","Fragment","BookSelectionMode","BOOK_SELECTOR_STRING_KEYS","localizeString","strings","BookSelector","handleBookSelectionModeChange","currentBookName","onSelectBooks","selectedBookIds","localizedStrings","currentBookText","chooseText","chooseBooksText","bookSelectionMode","setBookSelectionMode","onSelectionModeChange","newMode","DataTableViewOptions","table","FilterIcon","column","Select","SelectPrimitive","SelectGroup","SelectValue","SelectTrigger","ChevronDown","SelectScrollUpButton","ChevronUp","SelectScrollDownButton","SelectContent","position","SelectLabel","SelectItem","SelectSeparator","DataTablePagination","pageSize","ArrowLeftIcon","ChevronLeftIcon","ChevronRightIcon","ArrowRightIcon","Table","stickyHeader","TableHeader","TableBody","TableFooter","TableRow","TableHead","TableCell","TableCaption","DataTable","columns","data","enablePagination","showPaginationControls","showColumnVisibilityControls","onRowClickHandler","sorting","setSorting","columnFilters","setColumnFilters","columnVisibility","setColumnVisibility","rowSelection","setRowSelection","useReactTable","getCoreRowModel","getPaginationRowModel","getSortedRowModel","getFilteredRowModel","headerGroup","header","flexRender","_a","row","cell","OccurrencesTable","occurrenceData","setScriptureReference","referenceHeaderText","occurrenceHeaderText","occurrences","uniqueOccurrences","occurrence","uniqueOccurrence","deepEqual","Checkbox","CheckboxPrimitive","getLinesFromUSFM","text","getNumberFromUSFM","regex","match","getBookNumFromId","getStatusForItem","item","approvedItems","unapprovedItems","toggleVariants","Toggle","TogglePrimitive","ToggleGroupContext","ToggleGroup","ToggleGroupPrimitive","ToggleGroupItem","context","getSortingIcon","sortDirection","ArrowUpIcon","ArrowDownIcon","ArrowUpDownIcon","inventoryItemColumn","itemLabel","inventoryAdditionalItemColumn","additionalItemLabel","additionalItemIndex","inventoryCountColumn","countLabel","statusChangeHandler","changedItems","newStatus","onApprovedItemsChange","onUnapprovedItemsChange","newApprovedItems","validItem","newUnapprovedItems","unapprovedItem","inventoryStatusColumn","statusLabel","status","CircleCheckIcon","CircleXIcon","CircleHelpIcon","INVENTORY_STRING_KEYS","filterItemData","itemData","statusFilter","textFilter","filteredItemData","createTableData","scriptureRef","itemRegex","tableData","currentBook","currentChapter","currentVerse","line","items","itemIndex","existingItem","tableEntry","newReference","substring","newItem","Inventory","scriptureReference","extractItems","additionalItemsLabels","scope","onScopeChange","allItemsText","approvedItemsText","unapprovedItemsText","unknownItemsText","scopeBookText","scopeChapterText","scopeVerseText","filterText","showAdditionalItemsText","showAdditionalItems","setShowAdditionalItems","setStatusFilter","setTextFilter","selectedItem","setSelectedItem","reducedTableData","newTableData","firstItem","existingEntry","newTableEntry","filteredTableData","allColumns","numberOfAdditionalItems","additionalColumns","_b","rowClickHandler","newSelection","handleScopeChange","handleStatusFilterChange","SearchBar","onSearch","placeholder","isFullWidth","handleInputChange","VerticalTabs","TabsPrimitive","VerticalTabsList","VerticalTabsTrigger","VerticalTabsContent","TabNavigationContentSearch","tabList","searchPlaceholder","headerTitle","isSearchBarFullWidth","direction","tab","Separator","orientation","decorative","SeparatorPrimitive","Sheet","SheetPrimitive","SheetPortal","SheetOverlay","sheetVariants","SheetContent","side","SheetTitle","SheetDescription","Skeleton","TooltipProvider","TooltipPrimitive","Tooltip","TooltipTrigger","TooltipContent","MOBILE_BREAKPOINT","useIsMobile","isMobile","setIsMobile","mql","SIDEBAR_COOKIE_NAME","SIDEBAR_COOKIE_MAX_AGE","SIDEBAR_WIDTH","SIDEBAR_WIDTH_MOBILE","SIDEBAR_WIDTH_ICON","SIDEBAR_KEYBOARD_SHORTCUT","SidebarContext","useSidebar","SidebarProvider","defaultOpen","openProp","setOpenProp","style","openMobile","setOpenMobile","_open","_setOpen","isOpen","openState","toggleSidebar","state","contextValue","Sidebar","collapsible","SidebarTrigger","onClick","PanelLeft","SidebarRail","SidebarInset","SidebarInput","SidebarHeader","SidebarFooter","SidebarSeparator","SidebarContent","SidebarGroup","SidebarGroupLabel","SidebarGroupAction","SidebarGroupContent","SidebarMenu","SidebarMenuItem","sidebarMenuButtonVariants","SidebarMenuButton","isActive","tooltip","button","SidebarMenuAction","showOnHover","SidebarMenuBadge","SidebarMenuSkeleton","showIcon","width","SidebarMenuSub","SidebarMenuSubItem","SidebarMenuSubButton","SettingsSidebar","extensionLabels","projectOptions","handleSelectSidebarItem","selectedSidebarItem","handleSelectItem","projectId","getProjectNameFromProjectId","project","getIsActive","label","selectedProjectName","SettingsSidebarContentSearch","scrBookColId","scrRefColId","typeColId","detailsColId","defaultScrRefColumnName","defaultScrBookGroupName","defaultTypeColumnName","defaultDetailsColumnName","getColumns","colInfo","showSourceColumn","showSrcCol","info","formatScrRef","compareScrRefs","toRefOrRange","scriptureSelection","offsetStart","offsetEnd","scrRefToBBBCCCVVV","getRowKey","ScriptureResultsViewer","sources","showColumnHeaders","scriptureReferenceColumnName","scriptureBookGroupName","typeColumnName","detailsColumnName","onRowSelected","grouping","setGrouping","scriptureResults","source","getExpandedRowModel","getGroupedRowModel","selectedRows","keys","selectedRow","scrBookGroupName","typeGroupName","groupingOptions","handleSelectChange","selectedGrouping","handleRowClick","getEvenOrOddBandingStyle","getIndent","groupingState","rowIndex","ChevronLeft","DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS","getLocalizeKeyForScrollGroupId","ScrollGroupSelector","availableScrollGroupIds","scrollGroupId","onChangeScrollGroupId","localizedStringsDefaulted","localizedStringKey","localizedStringValue","newScrollGroupString","scrollGroupOptionId","SettingsList","SettingsListItem","primary","secondary","isLoading","loadingMessage","SettingsListHeader","includeSeparator","Card","CardHeader","CardTitle","CardDescription","CardContent","CardFooter","SettingsCard","settingsGroupLabel","settingsGroupDescription","Checklist","listItems","selectedListItems","handleSelectListItem","createLabel","_interopRequireDefault","obj","module","chainPropTypes","propType1","propType2","args","_extends","target","isPlainObject","prototype","deepClone","output","deepmerge","r","z","reactIs_production_min","hasSymbol","REACT_ELEMENT_TYPE","REACT_PORTAL_TYPE","REACT_FRAGMENT_TYPE","REACT_STRICT_MODE_TYPE","REACT_PROFILER_TYPE","REACT_PROVIDER_TYPE","REACT_CONTEXT_TYPE","REACT_ASYNC_MODE_TYPE","REACT_CONCURRENT_MODE_TYPE","REACT_FORWARD_REF_TYPE","REACT_SUSPENSE_TYPE","REACT_SUSPENSE_LIST_TYPE","REACT_MEMO_TYPE","REACT_LAZY_TYPE","REACT_BLOCK_TYPE","REACT_FUNDAMENTAL_TYPE","REACT_RESPONDER_TYPE","REACT_SCOPE_TYPE","isValidElementType","typeOf","object","$$typeof","$$typeofType","AsyncMode","ConcurrentMode","ContextConsumer","ContextProvider","Element","ForwardRef","Lazy","Memo","Portal","Profiler","StrictMode","Suspense","hasWarnedAboutDeprecatedIsAsyncMode","isAsyncMode","isConcurrentMode","isContextConsumer","isContextProvider","isElement","isForwardRef","isFragment","isLazy","isMemo","isPortal","isProfiler","isStrictMode","isSuspense","reactIs_development","reactIsModule","require$$0","require$$1","getOwnPropertySymbols","hasOwnProperty","propIsEnumerable","toObject","val","shouldUseNative","test1","test2","order2","test3","letter","objectAssign","from","to","symbols","ReactPropTypesSecret","ReactPropTypesSecret_1","has","printWarning","loggedTypeFailures","message","checkPropTypes","typeSpecs","values","location","componentName","getStack","typeSpecName","error","err","ex","stack","checkPropTypes_1","ReactIs","assign","require$$2","require$$3","require$$4","emptyFunctionThatReturnsNull","factoryWithTypeCheckers","isValidElement","throwOnDirectAccess","ITERATOR_SYMBOL","FAUX_ITERATOR_SYMBOL","getIteratorFn","maybeIterable","iteratorFn","ANONYMOUS","ReactPropTypes","createPrimitiveTypeChecker","createAnyTypeChecker","createArrayOfTypeChecker","createElementTypeChecker","createElementTypeTypeChecker","createInstanceTypeChecker","createNodeChecker","createObjectOfTypeChecker","createEnumTypeChecker","createUnionTypeChecker","createShapeTypeChecker","createStrictShapeTypeChecker","is","PropTypeError","createChainableTypeChecker","validate","manualPropTypeCallCache","manualPropTypeWarningCount","checkType","isRequired","propName","propFullName","secret","cacheKey","chainedCheckType","expectedType","propValue","propType","getPropType","preciseType","getPreciseType","typeChecker","expectedClass","expectedClassName","actualClassName","getClassName","expectedValues","valuesString","arrayOfTypeCheckers","checker","getPostfixForTypeWarning","expectedTypes","checkerResult","expectedTypesMessage","isNode","invalidValidatorError","shapeTypes","allKeys","iterator","step","entry","isSymbol","emptyFunction","emptyFunctionWithReset","factoryWithThrowingShims","shim","getShim","propTypesModule","isClassComponent","elementType","acceptingRef","safePropName","warningHint","elementAcceptingRef","PropTypes","elementAcceptingRef$1","specialProperty","exactProp","propTypes","unsupportedProps","prop","formatMuiErrorMessage","code","url","REACT_SERVER_CONTEXT_TYPE","REACT_OFFSCREEN_TYPE","enableScopeAPI","enableCacheElement","enableTransitionTracing","enableLegacyHidden","enableDebugTracing","REACT_MODULE_REFERENCE","SuspenseList","hasWarnedAboutDeprecatedIsConcurrentMode","isSuspenseList","fnNameMatchRegex","getFunctionName","fn","getFunctionComponentName","Component","fallback","getWrappedName","outerType","innerType","wrapperName","functionName","getDisplayName","HTMLElementType","refType","refType$1","capitalize","string","_formatMuiErrorMessage","createChainedFunction","funcs","acc","func","debounce","wait","timeout","debounced","later","deprecatedPropType","validator","reason","componentNameSafe","propFullNameSafe","isMuiElement","muiNames","_muiName","_element$type","ownerDocument","node","ownerWindow","requirePropFactory","componentNameInError","prevPropTypes","requiredProp","defaultTypeChecker","typeCheckerResult","setRef","useEnhancedEffect","useEnhancedEffect$1","globalId","useGlobalId","idOverride","defaultId","setDefaultId","maybeReactUseId","useId","reactId","unsupportedProp","useControlled","controlled","defaultProp","name","isControlled","valueState","setValue","defaultValue","setValueIfUncontrolled","newValue","useEventCallback","useForkRef","refs","instance","UNINITIALIZED","useLazyRef","init","initArg","EMPTY","useOnMount","Timeout","delay","useTimeout","hadKeyboardEvent","hadFocusVisibleRecently","hadFocusVisibleRecentlyTimeout","inputTypesWhitelist","focusTriggersKeyboardModality","tagName","handlePointerDown","handleVisibilityChange","prepare","doc","isFocusVisible","useIsFocusVisible","isFocusVisibleRef","handleBlurVisible","handleFocusVisible","resolveProps","defaultProps","defaultSlotProps","slotProps","slotPropName","composeClasses","slots","getUtilityClass","classes","slot","utilityClass","defaultGenerator","createClassNameGenerator","generate","generator","ClassNameGenerator","ClassNameGenerator$1","globalStateClasses","generateUtilityClass","globalStatePrefix","globalStateClass","generateUtilityClasses","result","clamp","min","max","_objectWithoutPropertiesLoose","excluded","sourceKeys","_excluded","sortBreakpointsValues","breakpointsAsArray","breakpoint1","breakpoint2","createBreakpoints","breakpoints","unit","other","sortedValues","up","down","between","start","end","endIndex","only","not","keyIndex","shape","shape$1","responsivePropType","responsivePropType$1","merge","defaultBreakpoints","handleBreakpoints","styleFromPropValue","theme","themeBreakpoints","breakpoint","mediaKey","cssKey","createEmptyBreakpointObject","breakpointsInput","_breakpointsInput$key","breakpointStyleKey","removeUnusedBreakpoints","breakpointKeys","breakpointOutput","getPath","path","checkVars","getStyleValue","themeMapping","transform","propValueFinal","userValue","cssProperty","themeKey","memoize","cache","arg","properties","directions","aliases","getCssProperties","property","marginKeys","paddingKeys","spacingKeys","createUnaryUnit","_getPath","themeSpacing","abs","createUnarySpacing","getValue","transformer","transformed","getStyleFromPropValue","cssProperties","resolveCssProperty","margin","padding","createSpacing","spacingInput","spacing","argsInput","argument","compose","styles","handlers","borderTransform","createBorderStyle","border","borderTop","borderRight","borderBottom","borderLeft","borderColor","borderTopColor","borderRightColor","borderBottomColor","borderLeftColor","outline","outlineColor","borderRadius","gap","columnGap","rowGap","gridColumn","gridRow","gridAutoFlow","gridAutoColumns","gridAutoRows","gridTemplateColumns","gridTemplateRows","gridTemplateAreas","gridArea","paletteTransform","color","bgcolor","backgroundColor","sizingTransform","maxWidth","_props$theme","_props$theme2","breakpointsValues","minWidth","height","maxHeight","minHeight","boxSizing","defaultSxConfig","defaultSxConfig$1","objectsHaveSameKeys","objects","union","callIfFn","maybeFn","unstable_createStyleFunctionSx","getThemeValue","config","styleFunctionSx","_theme$unstable_sxCon","sx","traverse","sxInput","sxObject","emptyBreakpoints","breakpointsKeys","css","styleKey","styleFunctionSx$1","applyStyles","createTheme","paletteInput","shapeInput","muiTheme","isObjectEmpty","useTheme","defaultTheme","contextTheme","ThemeContext","systemDefaultTheme","useThemeWithoutDefault","_excluded2","_excluded3","isEmpty","isStringTag","tag","shouldForwardProp","lowercaseFirstLetter","resolveTheme","themeId","defaultOverridesResolver","processStyleArg","callableStyle","_ref","ownerState","resolvedStylesArg","resolvedStyle","variants","isMatch","createStyled","input","rootShouldForwardProp","slotShouldForwardProp","systemSx","inputOptions","processStyles","componentSlot","inputSkipVariantsResolver","inputSkipSx","overridesResolver","skipVariantsResolver","skipSx","shouldForwardPropOption","defaultStyledResolver","styledEngineStyled","transformStyleArg","stylesArg","muiStyledResolver","styleArg","expressions","transformedStyleArg","expressionsWithDefaultTheme","styleOverrides","resolvedStyleOverrides","slotKey","slotStyle","_theme$components","themeVariants","numOfCustomFnsApplied","placeholders","displayName","getThemeProps","params","useThemeProps","clampWrapper","hexToRgb","re","colors","decomposeColor","marker","colorSpace","recomposeColor","hslToRgb","rgb","getLuminance","getContrastRatio","foreground","background","lumA","lumB","alpha","darken","coefficient","lighten","createMixins","mixins","common","common$1","grey","grey$1","purple","purple$1","red","red$1","orange","orange$1","blue","blue$1","lightBlue","lightBlue$1","green","green$1","light","dark","addLightOrDark","intent","shade","tonalOffset","tonalOffsetLight","tonalOffsetDark","getDefaultPrimary","mode","getDefaultSecondary","getDefaultError","getDefaultInfo","getDefaultSuccess","getDefaultWarning","createPalette","palette","contrastThreshold","success","warning","getContrastText","contrastText","contrast","augmentColor","mainShade","lightShade","darkShade","modes","round","caseAllCaps","defaultFontFamily","createTypography","typography","fontFamily","fontSize","fontWeightLight","fontWeightRegular","fontWeightMedium","fontWeightBold","htmlFontSize","allVariants","pxToRem2","coef","pxToRem","buildVariant","fontWeight","lineHeight","letterSpacing","casing","shadowKeyUmbraOpacity","shadowKeyPenumbraOpacity","shadowAmbientShadowOpacity","createShadow","px","shadows","shadows$1","easing","duration","formatMs","milliseconds","getAutoHeightDuration","constant","createTransitions","inputTransitions","mergedEasing","mergedDuration","durationOption","easingOption","isString","isNumber","animatedProp","zIndex","zIndex$1","mixinsInput","transitionsInput","typographyInput","systemTheme","systemCreateTheme","stateClasses","component","child","stateClass","defaultTheme$1","THEME_ID","systemUseThemeProps","styled","styled$1","getSvgIconUtilityClass","useUtilityClasses","SvgIconRoot","_theme$transitions","_theme$transitions$cr","_theme$transitions2","_theme$typography","_theme$typography$pxT","_theme$typography2","_theme$typography2$px","_theme$typography3","_theme$typography3$px","_palette$ownerState$c","_palette","_palette2","_palette3","SvgIcon","inProps","htmlColor","inheritViewBox","titleAccess","viewBox","hasSvgAsChild","more","_jsxs","_jsx","SvgIcon$1","createSvgIcon","unstable_ClassNameGenerator","exports","_utils","ArrowRight","default_1","_createSvgIcon","_jsxRuntime","isHostComponent","appendOwnerState","otherProps","defaultContextValue","ClassNameConfiguratorContext","useClassNamesOverride","disableDefaultClasses","extractEventHandlers","excludeKeys","resolveComponentProps","componentProps","slotState","omitEventHandlers","mergeSlotProps","parameters","getSlotProps","additionalProps","externalSlotProps","externalForwardedProps","joinedClasses","mergedStyle","eventHandlers","componentsPropsWithoutEventHandlers","otherPropsWithoutEventHandlers","internalSlotProps","useSlotProps","_parameters$additiona","skipResolvingSlotProps","rest","resolvedComponentsProps","mergedProps","internalRef","GLOBAL_CLASS_PREFIX","buildStateClass","buildSlotClass","getContainer","container","forwardedRef","disablePortal","mountNode","setMountNode","handleRef","newProps","ReactDOM","top","bottom","right","left","auto","basePlacements","clippingParents","viewport","popper","reference","variationPlacements","placement","placements","beforeRead","read","afterRead","beforeMain","main","afterMain","beforeWrite","write","afterWrite","modifierPhases","getNodeName","getWindow","OwnElement","isHTMLElement","isShadowRoot","attributes","effect","_ref2","initialStyles","styleProperties","attribute","applyStyles$1","getBasePlacement","getUAString","uaData","isLayoutViewport","getBoundingClientRect","includeScale","isFixedStrategy","clientRect","scaleX","scaleY","visualViewport","addVisualOffsets","getLayoutRect","contains","parent","rootNode","next","getComputedStyle","isTableElement","getDocumentElement","getParentNode","getTrueOffsetParent","getContainingBlock","isFirefox","isIE","elementCss","currentNode","getOffsetParent","window","offsetParent","getMainAxisFromPlacement","within","mathMax","mathMin","withinMaxClamp","getFreshSideObject","mergePaddingObject","paddingObject","expandToHashMap","hashMap","toPaddingObject","arrow","_state$modifiersData$","arrowElement","popperOffsets","basePlacement","axis","isVertical","len","arrowRect","minProp","maxProp","endDiff","startDiff","arrowOffsetParent","clientSize","centerToReference","center","offset","axisProp","_options$element","arrow$1","getVariation","unsetSides","roundOffsetsByDPR","win","dpr","mapToStyles","_Object$assign2","popperRect","variation","offsets","gpuAcceleration","adaptive","roundOffsets","isFixed","_offsets$x","_offsets$y","_ref3","hasX","hasY","sideX","sideY","heightProp","widthProp","offsetY","offsetX","commonStyles","_ref4","_Object$assign","computeStyles","_ref5","_options$gpuAccelerat","_options$adaptive","_options$roundOffsets","computeStyles$1","passive","_options$scroll","scroll","_options$resize","resize","scrollParents","scrollParent","eventListeners","hash","getOppositePlacement","matched","getOppositeVariationPlacement","getWindowScroll","scrollLeft","scrollTop","getWindowScrollBarX","getViewportRect","strategy","html","layoutViewport","getDocumentRect","_element$ownerDocumen","winScroll","body","isScrollParent","_getComputedStyle","overflow","overflowX","overflowY","getScrollParent","listScrollParents","list","isBody","updatedList","rectToClientRect","rect","getInnerBoundingClientRect","getClientRectFromMixedType","clippingParent","getClippingParents","canEscapeClipping","clipperElement","getClippingRect","boundary","rootBoundary","mainClippingParents","firstClippingParent","clippingRect","accRect","computeOffsets","commonX","commonY","mainAxis","detectOverflow","_options","_options$placement","_options$strategy","_options$boundary","_options$rootBoundary","_options$elementConte","elementContext","_options$altBoundary","altBoundary","_options$padding","altContext","clippingClientRect","referenceClientRect","popperClientRect","elementClientRect","overflowOffsets","offsetData","multiply","computeAutoPlacement","flipVariations","_options$allowedAutoP","allowedAutoPlacements","allPlacements","allowedPlacements","overflows","getExpandedFallbackPlacements","oppositePlacement","flip","_options$mainAxis","checkMainAxis","_options$altAxis","checkAltAxis","specifiedFallbackPlacements","_options$flipVariatio","preferredPlacement","isBasePlacement","fallbackPlacements","referenceRect","checksMap","makeFallbackChecks","firstFittingPlacement","_basePlacement","isStartVariation","mainVariationSide","altVariationSide","checks","check","numberOfChecks","_loop","_i","fittingPlacement","_ret","flip$1","getSideOffsets","preventedOffsets","isAnySideFullyClipped","hide","referenceOverflow","popperAltOverflow","referenceClippingOffsets","popperEscapeOffsets","isReferenceHidden","hasPopperEscaped","hide$1","distanceAndSkiddingToXY","rects","invertDistance","skidding","distance","_options$offset","_data$state$placement","offset$1","popperOffsets$1","getAltAxis","preventOverflow","_options$tether","tether","_options$tetherOffset","tetherOffset","altAxis","tetherOffsetValue","normalizedTetherOffsetValue","offsetModifierState","_offsetModifierState$","mainSide","altSide","additive","minLen","maxLen","arrowPaddingObject","arrowPaddingMin","arrowPaddingMax","arrowLen","minOffset","maxOffset","clientOffset","offsetModifierValue","tetherMin","tetherMax","preventedOffset","_offsetModifierState$2","_mainSide","_altSide","_offset","_len","_min","_max","isOriginSide","_offsetModifierValue","_tetherMin","_tetherMax","_preventedOffset","preventOverflow$1","getHTMLElementScroll","getNodeScroll","isElementScaled","getCompositeRect","elementOrVirtualElement","isOffsetParentAnElement","offsetParentIsScaled","documentElement","order","modifiers","map","visited","modifier","sort","requires","dep","depModifier","orderModifiers","orderedModifiers","phase","pending","resolve","mergeByName","merged","current","existing","DEFAULT_OPTIONS","areValidElements","_key","popperGenerator","generatorOptions","_generatorOptions","_generatorOptions$def","defaultModifiers","_generatorOptions$def2","defaultOptions","effectCleanupFns","isDestroyed","setOptionsAction","cleanupModifierEffects","runModifierEffects","_state$elements","_state$orderedModifie","_state$orderedModifie2","_ref$options","cleanupFn","noopFn","createPopper","COMPONENT_NAME","getPopperUtilityClass","flipPlacement","resolveAnchorEl","anchorEl","isVirtualElement","defaultPopperOptions","PopperTooltip","_slots$root","initialPlacement","popperOptions","popperRefProp","TransitionProps","tooltipRef","ownRef","popperRef","handlePopperRef","handlePopperRefRef","rtlPlacement","setPlacement","resolvedAnchorElement","setResolvedAnchorElement","handlePopperUpdate","box","popperModifiers","childProps","Root","rootProps","Popper","containerProp","keepMounted","transition","exited","setExited","handleEnter","handleExited","resolvedAnchorEl","display","transitionProps","useThemeSystem","_setPrototypeOf","_inheritsLoose","subClass","superClass","setPrototypeOf","timeoutsShape","TransitionGroupContext","forceReflow","UNMOUNTED","EXITED","ENTERING","ENTERED","EXITING","Transition","_React$Component","_this","parentGroup","appear","initialStatus","prevState","nextIn","_proto","prevProps","nextStatus","exit","enter","mounting","_this2","appearing","maybeNode","maybeAppearing","timeouts","enterTimeout","_this3","nextState","callback","_this4","active","handler","doesNotHaveTimeoutOrListener","maybeNextCallback","_this$props","pt","noop","Transition$1","reflow","getTransitionProps","_style$transitionDura","_style$transitionTimi","getScale","isWebKit154","Grow","addEndListener","inProp","onEnter","onEntered","onEntering","onExit","onExited","onExiting","TransitionComponent","timer","autoTimeout","nodeRef","normalizedTransitionCallback","maybeIsAppearing","handleEntering","isAppearing","transitionDuration","transitionTimingFunction","handleEntered","handleExiting","handleExit","handleAddEndListener","Grow$1","PopperRoot","BasePopper","components","componentsProps","RootComponent","Popper$1","getTooltipUtilityClass","tooltipClasses","tooltipClasses$1","disableInteractive","touch","TooltipPopper","TooltipTooltip","TooltipArrow","hystersisOpen","hystersisTimer","cursorPosition","composeEventHandler","eventHandler","_slots$popper","_slots$transition","_slots$tooltip","_slots$arrow","_slotProps$popper","_ref6","_slotProps$popper2","_slotProps$transition","_slotProps$tooltip","_ref7","_slotProps$tooltip2","_slotProps$arrow","_ref8","_slotProps$arrow2","childrenProp","describeChild","disableFocusListener","disableHoverListener","disableInteractiveProp","disableTouchListener","enterDelay","enterNextDelay","enterTouchDelay","followCursor","idProp","leaveDelay","leaveTouchDelay","onClose","onOpen","PopperComponentProp","PopperProps","title","TransitionComponentProp","isRtl","childNode","setChildNode","arrowRef","setArrowRef","ignoreNonTouchEvents","closeTimer","enterTimer","leaveTimer","touchTimer","setOpenState","prevUserSelect","stopTouchInteraction","handleOpen","handleClose","handleLeave","focusVisibleRef","setChildIsFocusVisible","handleBlur","handleFocus","detectTouchStart","childrenProps","handleMouseOver","handleMouseLeave","handleTouchStart","handleTouchEnd","nativeEvent","handleMouseMove","nameOrDescProps","titleIsString","interactiveWrapperListeners","_PopperProps$popperOp","tooltipModifiers","PopperComponent","TooltipComponent","ArrowComponent","popperProps","tooltipProps","tooltipArrowProps","TransitionPropsInner","Tooltip$1","getIcon","icon","menuLabel","leading","MuiListItemIcon","MenuItem","allowForLeadingIcons","iconPathBefore","iconPathAfter","hasAutoFocus","isDense","isSubMenuParent","hasDisabledGutters","hasDivider","focusVisibleClassName","menuItem","MuiMenuItem","MuiListItemText","getAllGroups","menuDefinition","SubMenu","setAnchorEl","parentMenuItem","parentItemProps","handleParentMenuItemClick","renderSubMenuItems","includedGroups","group","GroupedMenuItemList","Menu","getOrderedGroupItems","groupId","allItems","menuProps","commandHandler","groupsToInclude","sortedGroups","itemArray","allowSpaceForLeadingIcons","createMenuItemProps","isLastItemInGroup","divKey","itemInfo","menuItemProps","TopLevelMenu","columnId","MenuColumn","metadata","Grid","List","GridMenu","multiColumnMenu","sortedColumns","columnNumbers","columnName","col","getUsePromiseOptionsDefaults","usePromise","promiseFactoryCallback","defaultValueRef","optionsDefaultedRef","setIsLoading","promiseIsCurrent","MenuIcon","HamburgerMenuButton","menuProvider","normalMenu","fullMenu","containerRef","ariaLabelPrefix","isMenuOpen","setMenuOpen","showFullMenu","setShowFullMenu","handleMenuItemClick","handleMenuButtonClick","prevIsOpen","isOpening","menuCommandHandler","command","setOffset","normalMenuData","fullMenuData","menu","IconButton","Drawer","isTooltipSuppressed","adjustMarginToAlignToEdge","MuiIconButton","Spinner","LoaderCircle","TextField","hasError","helperText","onFocus","onBlur","ShadLabel","Toolbar","AppBar","MuiToolbar","alertVariants","Alert","AlertTitle","AlertDescription","Sonner","Toaster","Slider","SliderPrimitive","Switch","SwitchPrimitives","Tabs","TabsList","TabsTrigger","TabsContent","InstallButton","isInstalling","handleClick","buttonText","Download","EnableButton","isEnabling","DisableButton","isDisabling","UpdateButton","isUpdating","MarkdownRenderer","markdown","anchorTarget","Markdown","FilterButton","Filter","DropdownMenuItemType","DropdownMenuItemType2","FilterDropdown","groups","NoExtensionsFound","MoreInfo","category","downloads","languages","moreInfoUrl","numberFormatted","NumberFormat","handleScrollToBottom","User","locale","LucideLink","CircleHelp","VersionHistory","versionHistory","showAllVersions","setShowAllVersions","currentDate","formatTimeString","dateString","date","dateDiff","yearDiff","monthDiff","dayDiff","timeString","sortedEntries","Footer","publisherDisplayName","fileSize","locales","formattedFileSize","formatBytes","languageNames","codes","displayNames","useEvent","unsubscriber","noopUnsubscriber","useEventAsync","unsubscribe","unsub"],"mappings":"28CAGA,MAAMA,GAAgBC,GAAAA,oBAAoB,CAAE,OAAQ,KAAO,CAAA,EAyDpD,SAASC,KAAMC,EAAsB,CACnC,OAAAH,GAAcI,GAAAA,KAAKD,CAAM,CAAC,CACnC,CCzDO,MAAME,GAAQC,EAAM,WACzB,CAAC,CAAE,UAAAC,EAAW,KAAAC,EAAM,GAAGC,CAAA,EAASC,IAE5BC,EAAA,IAAC,QAAA,CACC,KAAAH,EACA,UAAWN,EACT,sbACAK,CACF,EACA,IAAAG,EAEC,GAAGD,CAAA,CAAA,CAIZ,EACAJ,GAAM,YAAc,QCNpB,MAAMO,GAAmBC,EAAA,WACvB,CACE,CAAE,aAAAC,EAAc,cAAAC,EAAe,cAAAC,EAAe,aAAAC,EAAc,GAAGR,CAAM,EACrEC,IAGEQ,EAAA,KAAC,MAAI,CAAA,UAAU,cACb,SAAA,CAAAP,EAAA,IAACQ,GAAA,CACE,GAAGV,EACJ,KAAK,OACL,UAAU,0JACV,SAAWW,GAAUN,EAAaM,EAAM,OAAO,KAAK,EACpD,UAAYC,GAAM,CACZA,EAAE,MAAQ,SACCJ,IAEfF,EAAcM,CAAC,CACjB,EACA,QAASL,EACT,IAAAN,CAAA,CACF,EACAC,EAAA,IAACW,EAAA,QAAA,CACC,UAAU,8HACV,QAAS,IAAM,CAEb,QAAQ,IAAI,iBAAiB,CAC/B,CAAA,CACF,CACF,CAAA,CAAA,CAGN,EC9CA,IAAIC,GAAI,OAAO,eACXC,GAAI,CAACC,EAAGJ,EAAGK,IAAML,KAAKI,EAAIF,GAAEE,EAAGJ,EAAG,CAAE,WAAY,GAAI,aAAc,GAAI,SAAU,GAAI,MAAOK,CAAC,CAAE,EAAID,EAAEJ,CAAC,EAAIK,EACzGC,GAAI,CAACF,EAAGJ,EAAGK,IAAMF,GAAEC,EAAG,OAAOJ,GAAK,SAAWA,EAAI,GAAKA,EAAGK,CAAC,EAW9D,MAAME,GAAI,CACR,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MAEA,MAEA,MAEA,MAEA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,MAEA,MAEA,MAEA,MAEA,MACA,MACA,MACA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,KACF,EAAGC,GAAI,CACL,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,KACF,EAAGC,GAAI,CACL,UACA,SACA,YACA,UACA,cACA,SACA,SACA,OACA,WACA,WACA,UACA,UACA,eACA,eACA,OACA,WACA,kBACA,MACA,SACA,WACA,eACA,gBACA,SACA,WACA,eACA,UACA,kBACA,QACA,OACA,OACA,UACA,QACA,QACA,QACA,WACA,YACA,SACA,YACA,UACA,UACA,OACA,OACA,OACA,OACA,SACA,gBACA,gBACA,YACA,YACA,cACA,aACA,kBACA,kBACA,YACA,YACA,QACA,WACA,UACA,QACA,UACA,UACA,SACA,SACA,SACA,OACA,aACA,QACA,SACA,eACA,oBACA,0BACA,SACA,qBACA,sBACA,UACA,qBACA,cACA,cACA,cACA,cACA,mBACA,mBACA,qBACA,YACA,OACA,oBAGA,uBACA,uBACA,sBACA,yBACA,wBACA,qBACA,UACA,UACA,UACA,UACA,UACA,UACA,UACA,eACA,cACA,eACA,oBACA,qBACA,0BACA,0BACA,eACA,eACA,YACA,gBACA,cACA,eACA,iBACA,wBACA,mBACA,WACA,QACA,aACA,aACA,aACA,2BACA,4BACA,YACF,EAAGC,GAAIC,KACP,SAASC,GAAER,EAAGJ,EAAI,GAAI,CACpB,OAAOA,IAAMI,EAAIA,EAAE,YAAa,GAAGA,KAAKM,GAAIA,GAAEN,CAAC,EAAI,CACrD,CACA,SAASS,GAAET,EAAG,CACZ,OAAOQ,GAAER,CAAC,EAAI,CAChB,CACA,SAASU,GAAEV,EAAG,CACZ,MAAMJ,EAAI,OAAOI,GAAK,SAAWQ,GAAER,CAAC,EAAIA,EACxC,OAAOJ,GAAK,IAAMA,GAAK,EACzB,CACA,SAASe,GAAEX,EAAG,CACZ,OAAQ,OAAOA,GAAK,SAAWQ,GAAER,CAAC,EAAIA,IAAM,EAC9C,CACA,SAASY,GAAEZ,EAAG,CACZ,OAAOA,GAAK,EACd,CACA,SAASa,GAAEb,EAAG,CACZ,MAAMJ,EAAI,OA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aAAc,CACZ,SAAU,SACX,EACD,aAAc,CACZ,SAAU,qBACV,MAAOc,EACR,EAED,MAAO,CACL,SAAU,UACV,UAAWa,EACZ,EACD,QAAS,CACP,SAAU,UACV,YAAa,kBACb,UAAWA,EACZ,EACD,gBAAiB,CACf,SAAU,UACV,UAAWA,EACZ,EAED,EAAG,CACD,MAAOpC,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,QAAS,CACP,MAAOA,EACR,EACD,WAAY,CACV,MAAOA,EACR,EACD,aAAc,CACZ,MAAOA,EACR,EACD,cAAe,CACb,MAAOA,EACR,EACD,YAAa,CACX,MAAOA,EACR,EACD,SAAU,CACR,MAAOA,EACR,EACD,SAAU,CACR,MAAOA,EACR,EACD,cAAe,CACb,MAAOA,EACR,EACD,mBAAoB,CAClB,MAAOA,EACR,EACD,iBAAkB,CAChB,MAAOA,EACR,EACD,aAAc,CACZ,MAAOA,EACR,EACD,kBAAmB,CACjB,MAAOA,EACR,EACD,gBAAiB,CACf,MAAOA,EACR,EACD,EAAG,CACD,MAAOD,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,OAAQ,CACN,MAAOA,EACR,EACD,UAAW,CACT,MAAOA,EACR,EACD,YAAa,CACX,MAAOA,EACR,EACD,aAAc,CACZ,MAAOA,EACR,EACD,WAAY,CACV,MAAOA,EACR,EACD,QAAS,CACP,MAAOA,EACR,EACD,QAAS,CACP,MAAOA,EACR,EACD,aAAc,CACZ,MAAOA,EACR,EACD,kBAAmB,CACjB,MAAOA,EACR,EACD,gBAAiB,C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;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","x_google_ignoreList":[3,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,83,84,85,86,87,88,89,90,91,92,93,94,95,96,97,98,99,100,101,102,103,104,105,106,107,108,109,110,111,112,113,114,115,116,117,118,119,120,121,122,123,124,125,126,127,128,129,130,131,132,133,134,135,136,137,138,139,140,141,142,143,144,145,146,147,148,149,150,151,152,153,154,155,156,157,158,159,160,161,162,163,164,165,166,167,168,169,170,171,172,173,174,175,176,177,178,179,180,181,182,183,184,185,186,187,188,189,190,191,192,193,194,195,196,197,198,199,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,230]} \ No newline at end of file +{"version":3,"file":"index.cjs","sources":["../src/utils/shadcn-ui.util.ts","../src/components/shadcn-ui/input.tsx","../src/components/advanced/book-chapter-control/book-chapter-input.component.tsx","../../../node_modules/@sillsdev/scripture/dist/index.es.js","../src/components/shadcn-ui/dropdown-menu.tsx","../src/components/advanced/book-chapter-control/book-menu-item.component.tsx","../src/components/advanced/book-chapter-control/chapter-select.component.tsx","../src/components/advanced/book-chapter-control/go-to-menu-item.component.tsx","../src/components/advanced/book-chapter-control/book-chapter-control.component.tsx","../src/components/shadcn-ui/button.tsx","../src/components/shadcn-ui/label.tsx","../src/components/shadcn-ui/radio-group.tsx","../src/components/shadcn-ui/popover.tsx","../src/components/shadcn-ui/dialog.tsx","../src/components/shadcn-ui/command.tsx","../src/components/basics/combo-box.component.tsx","../src/components/basics/chapter-range-selector.component.tsx","../src/components/advanced/book-selector.component.tsx","../src/components/advanced/data-table/data-table-column-toggle.component.tsx","../src/components/shadcn-ui/select.tsx","../src/components/advanced/data-table/data-table-pagination.component.tsx","../src/components/shadcn-ui/table.tsx","../src/components/advanced/data-table/data-table.component.tsx","../src/components/advanced/inventory/occurrences-table.component.tsx","../src/components/shadcn-ui/checkbox.tsx","../src/components/advanced/inventory/inventory-utils.ts","../src/components/shadcn-ui/toggle.tsx","../src/components/shadcn-ui/toggle-group.tsx","../src/components/advanced/inventory/inventory-columns.tsx","../src/components/advanced/inventory/inventory.component.tsx","../src/components/basics/search-bar.component.tsx","../src/components/basics/tabs-vertical.tsx","../src/components/advanced/tab-navigation-content-search.component.tsx","../src/components/shadcn-ui/separator.tsx","../src/components/shadcn-ui/sheet.tsx","../src/components/shadcn-ui/skeleton.tsx","../src/components/shadcn-ui/tooltip.tsx","../src/components/hooks/use-mobile.tsx","../src/components/shadcn-ui/sidebar.tsx","../src/components/advanced/settings-components/settings-sidebar.component.tsx","../src/components/advanced/settings-components/settings-sidebar-content-search.component.tsx","../src/components/advanced/scripture-results-viewer/scripture-results-viewer.component.tsx","../src/components/advanced/scroll-group-selector.component.tsx","../src/components/advanced/settings-components/settings-list.component.tsx","../src/components/basics/checklist.component.tsx","../../../node_modules/@babel/runtime/helpers/interopRequireDefault.js","../../../node_modules/@mui/utils/chainPropTypes/chainPropTypes.js","../../../node_modules/@babel/runtime/helpers/esm/extends.js","../../../node_modules/@mui/utils/deepmerge/deepmerge.js","../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.production.min.js","../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.development.js","../../../node_modules/prop-types/node_modules/react-is/index.js","../../../node_modules/object-assign/index.js","../../../node_modules/prop-types/lib/ReactPropTypesSecret.js","../../../node_modules/prop-types/lib/has.js","../../../node_modules/prop-types/checkPropTypes.js","../../../node_modules/prop-types/factoryWithTypeCheckers.js","../../../node_modules/prop-types/factoryWithThrowingShims.js","../../../node_modules/prop-types/index.js","../../../node_modules/@mui/utils/elementAcceptingRef/elementAcceptingRef.js","../../../node_modules/@mui/utils/exactProp/exactProp.js","../../../node_modules/@mui/utils/formatMuiErrorMessage/formatMuiErrorMessage.js","../../../node_modules/react-is/cjs/react-is.production.min.js","../../../node_modules/react-is/cjs/react-is.development.js","../../../node_modules/react-is/index.js","../../../node_modules/@mui/utils/getDisplayName/getDisplayName.js","../../../node_modules/@mui/utils/HTMLElementType/HTMLElementType.js","../../../node_modules/@mui/utils/refType/refType.js","../../../node_modules/@mui/utils/capitalize/capitalize.js","../../../node_modules/@mui/utils/createChainedFunction/createChainedFunction.js","../../../node_modules/@mui/utils/debounce/debounce.js","../../../node_modules/@mui/utils/deprecatedPropType/deprecatedPropType.js","../../../node_modules/@mui/utils/isMuiElement/isMuiElement.js","../../../node_modules/@mui/utils/ownerDocument/ownerDocument.js","../../../node_modules/@mui/utils/ownerWindow/ownerWindow.js","../../../node_modules/@mui/utils/requirePropFactory/requirePropFactory.js","../../../node_modules/@mui/utils/setRef/setRef.js","../../../node_modules/@mui/utils/useEnhancedEffect/useEnhancedEffect.js","../../../node_modules/@mui/utils/useId/useId.js","../../../node_modules/@mui/utils/unsupportedProp/unsupportedProp.js","../../../node_modules/@mui/utils/useControlled/useControlled.js","../../../node_modules/@mui/utils/useEventCallback/useEventCallback.js","../../../node_modules/@mui/utils/useForkRef/useForkRef.js","../../../node_modules/@mui/utils/useLazyRef/useLazyRef.js","../../../node_modules/@mui/utils/useOnMount/useOnMount.js","../../../node_modules/@mui/utils/useTimeout/useTimeout.js","../../../node_modules/@mui/utils/useIsFocusVisible/useIsFocusVisible.js","../../../node_modules/@mui/utils/resolveProps/resolveProps.js","../../../node_modules/@mui/utils/composeClasses/composeClasses.js","../../../node_modules/@mui/utils/ClassNameGenerator/ClassNameGenerator.js","../../../node_modules/@mui/utils/generateUtilityClass/generateUtilityClass.js","../../../node_modules/@mui/utils/generateUtilityClasses/generateUtilityClasses.js","../../../node_modules/@mui/utils/clamp/clamp.js","../../../node_modules/@babel/runtime/helpers/esm/objectWithoutPropertiesLoose.js","../../../node_modules/@mui/system/esm/createTheme/createBreakpoints.js","../../../node_modules/@mui/system/esm/createTheme/shape.js","../../../node_modules/@mui/system/esm/responsivePropType.js","../../../node_modules/@mui/system/esm/merge.js","../../../node_modules/@mui/system/esm/breakpoints.js","../../../node_modules/@mui/system/esm/style.js","../../../node_modules/@mui/system/esm/memoize.js","../../../node_modules/@mui/system/esm/spacing.js","../../../node_modules/@mui/system/esm/createTheme/createSpacing.js","../../../node_modules/@mui/system/esm/compose.js","../../../node_modules/@mui/system/esm/borders.js","../../../node_modules/@mui/system/esm/cssGrid.js","../../../node_modules/@mui/system/esm/palette.js","../../../node_modules/@mui/system/esm/sizing.js","../../../node_modules/@mui/system/esm/styleFunctionSx/defaultSxConfig.js","../../../node_modules/@mui/system/esm/styleFunctionSx/styleFunctionSx.js","../../../node_modules/@mui/system/esm/createTheme/applyStyles.js","../../../node_modules/@mui/system/esm/createTheme/createTheme.js","../../../node_modules/@mui/system/esm/useThemeWithoutDefault.js","../../../node_modules/@mui/system/esm/useTheme.js","../../../node_modules/@mui/system/esm/createStyled.js","../../../node_modules/@mui/system/esm/useThemeProps/getThemeProps.js","../../../node_modules/@mui/system/esm/useThemeProps/useThemeProps.js","../../../node_modules/@mui/system/esm/colorManipulator.js","../../../node_modules/@mui/material/styles/createMixins.js","../../../node_modules/@mui/material/colors/common.js","../../../node_modules/@mui/material/colors/grey.js","../../../node_modules/@mui/material/colors/purple.js","../../../node_modules/@mui/material/colors/red.js","../../../node_modules/@mui/material/colors/orange.js","../../../node_modules/@mui/material/colors/blue.js","../../../node_modules/@mui/material/colors/lightBlue.js","../../../node_modules/@mui/material/colors/green.js","../../../node_modules/@mui/material/styles/createPalette.js","../../../node_modules/@mui/material/styles/createTypography.js","../../../node_modules/@mui/material/styles/shadows.js","../../../node_modules/@mui/material/styles/createTransitions.js","../../../node_modules/@mui/material/styles/zIndex.js","../../../node_modules/@mui/material/styles/createTheme.js","../../../node_modules/@mui/material/styles/defaultTheme.js","../../../node_modules/@mui/material/styles/identifier.js","../../../node_modules/@mui/material/styles/useThemeProps.js","../../../node_modules/@mui/material/styles/styled.js","../../../node_modules/@mui/material/SvgIcon/svgIconClasses.js","../../../node_modules/@mui/material/SvgIcon/SvgIcon.js","../../../node_modules/@mui/material/utils/createSvgIcon.js","../../../node_modules/@mui/material/utils/index.js","../../../node_modules/@mui/icons-material/utils/createSvgIcon.js","../../../node_modules/@mui/icons-material/ArrowRight.js","../../../node_modules/@mui/base/utils/isHostComponent.js","../../../node_modules/@mui/base/utils/appendOwnerState.js","../../../node_modules/@mui/base/utils/ClassNameConfigurator.js","../../../node_modules/@mui/base/utils/extractEventHandlers.js","../../../node_modules/@mui/base/utils/resolveComponentProps.js","../../../node_modules/@mui/base/utils/omitEventHandlers.js","../../../node_modules/@mui/base/utils/mergeSlotProps.js","../../../node_modules/@mui/base/utils/useSlotProps.js","../../../node_modules/@mui/base/generateUtilityClass/index.js","../../../node_modules/@mui/base/generateUtilityClasses/index.js","../../../node_modules/@mui/base/Portal/Portal.js","../../../node_modules/@popperjs/core/lib/enums.js","../../../node_modules/@popperjs/core/lib/dom-utils/getNodeName.js","../../../node_modules/@popperjs/core/lib/dom-utils/getWindow.js","../../../node_modules/@popperjs/core/lib/dom-utils/instanceOf.js","../../../node_modules/@popperjs/core/lib/modifiers/applyStyles.js","../../../node_modules/@popperjs/core/lib/utils/getBasePlacement.js","../../../node_modules/@popperjs/core/lib/utils/math.js","../../../node_modules/@popperjs/core/lib/utils/userAgent.js","../../../node_modules/@popperjs/core/lib/dom-utils/isLayoutViewport.js","../../../node_modules/@popperjs/core/lib/dom-utils/getBoundingClientRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/getLayoutRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/contains.js","../../../node_modules/@popperjs/core/lib/dom-utils/getComputedStyle.js","../../../node_modules/@popperjs/core/lib/dom-utils/isTableElement.js","../../../node_modules/@popperjs/core/lib/dom-utils/getDocumentElement.js","../../../node_modules/@popperjs/core/lib/dom-utils/getParentNode.js","../../../node_modules/@popperjs/core/lib/dom-utils/getOffsetParent.js","../../../node_modules/@popperjs/core/lib/utils/getMainAxisFromPlacement.js","../../../node_modules/@popperjs/core/lib/utils/within.js","../../../node_modules/@popperjs/core/lib/utils/getFreshSideObject.js","../../../node_modules/@popperjs/core/lib/utils/mergePaddingObject.js","../../../node_modules/@popperjs/core/lib/utils/expandToHashMap.js","../../../node_modules/@popperjs/core/lib/modifiers/arrow.js","../../../node_modules/@popperjs/core/lib/utils/getVariation.js","../../../node_modules/@popperjs/core/lib/modifiers/computeStyles.js","../../../node_modules/@popperjs/core/lib/modifiers/eventListeners.js","../../../node_modules/@popperjs/core/lib/utils/getOppositePlacement.js","../../../node_modules/@popperjs/core/lib/utils/getOppositeVariationPlacement.js","../../../node_modules/@popperjs/core/lib/dom-utils/getWindowScroll.js","../../../node_modules/@popperjs/core/lib/dom-utils/getWindowScrollBarX.js","../../../node_modules/@popperjs/core/lib/dom-utils/getViewportRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/getDocumentRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/isScrollParent.js","../../../node_modules/@popperjs/core/lib/dom-utils/getScrollParent.js","../../../node_modules/@popperjs/core/lib/dom-utils/listScrollParents.js","../../../node_modules/@popperjs/core/lib/utils/rectToClientRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/getClippingRect.js","../../../node_modules/@popperjs/core/lib/utils/computeOffsets.js","../../../node_modules/@popperjs/core/lib/utils/detectOverflow.js","../../../node_modules/@popperjs/core/lib/utils/computeAutoPlacement.js","../../../node_modules/@popperjs/core/lib/modifiers/flip.js","../../../node_modules/@popperjs/core/lib/modifiers/hide.js","../../../node_modules/@popperjs/core/lib/modifiers/offset.js","../../../node_modules/@popperjs/core/lib/modifiers/popperOffsets.js","../../../node_modules/@popperjs/core/lib/utils/getAltAxis.js","../../../node_modules/@popperjs/core/lib/modifiers/preventOverflow.js","../../../node_modules/@popperjs/core/lib/dom-utils/getHTMLElementScroll.js","../../../node_modules/@popperjs/core/lib/dom-utils/getNodeScroll.js","../../../node_modules/@popperjs/core/lib/dom-utils/getCompositeRect.js","../../../node_modules/@popperjs/core/lib/utils/orderModifiers.js","../../../node_modules/@popperjs/core/lib/utils/debounce.js","../../../node_modules/@popperjs/core/lib/utils/mergeByName.js","../../../node_modules/@popperjs/core/lib/createPopper.js","../../../node_modules/@popperjs/core/lib/popper.js","../../../node_modules/@mui/base/Popper/popperClasses.js","../../../node_modules/@mui/base/Popper/Popper.js","../../../node_modules/@mui/material/styles/useTheme.js","../../../node_modules/@babel/runtime/helpers/esm/setPrototypeOf.js","../../../node_modules/@babel/runtime/helpers/esm/inheritsLoose.js","../../../node_modules/react-transition-group/esm/config.js","../../../node_modules/react-transition-group/esm/utils/PropTypes.js","../../../node_modules/react-transition-group/esm/TransitionGroupContext.js","../../../node_modules/react-transition-group/esm/utils/reflow.js","../../../node_modules/react-transition-group/esm/Transition.js","../../../node_modules/@mui/material/transitions/utils.js","../../../node_modules/@mui/material/Grow/Grow.js","../../../node_modules/@mui/material/Popper/Popper.js","../../../node_modules/@mui/material/Tooltip/tooltipClasses.js","../../../node_modules/@mui/material/Tooltip/Tooltip.js","../src/components/mui/menu-item.component.tsx","../src/components/mui/grouped-menu-item-list.component.tsx","../src/components/mui/top-level-menu.component.tsx","../src/components/mui/grid-menu.component.tsx","../src/hooks/use-promise.hook.ts","../../../node_modules/@mui/icons-material/esm/Menu.js","../src/components/mui/hamburger-menu-button.component.tsx","../src/components/mui/icon-button.component.tsx","../src/components/basics/spinner.component.tsx","../src/components/basics/text-field.component.tsx","../src/components/mui/toolbar.component.tsx","../src/components/shadcn-ui/alert.tsx","../src/components/shadcn-ui/card.tsx","../src/components/shadcn-ui/sonner.tsx","../src/components/shadcn-ui/slider.tsx","../src/components/shadcn-ui/switch.tsx","../src/components/shadcn-ui/tabs.tsx","../src/components/advanced/extension-marketplace/buttons/install-button.component.tsx","../src/components/advanced/extension-marketplace/buttons/enable-button.component.tsx","../src/components/advanced/extension-marketplace/buttons/disable-button.component.tsx","../src/components/advanced/extension-marketplace/buttons/update-button.component.tsx","../src/components/advanced/extension-marketplace/markdown-renderer.component.tsx","../src/components/advanced/extension-marketplace/buttons/filter-button.component.tsx","../src/components/advanced/extension-marketplace/filter-dropdown.component.tsx","../src/components/advanced/extension-marketplace/no-extensions-found.component.tsx","../src/components/advanced/extension-marketplace/more-info.component.tsx","../src/components/advanced/extension-marketplace/version-history.component.tsx","../src/components/advanced/extension-marketplace/footer.component.tsx","../src/hooks/use-event.hook.ts","../src/hooks/use-event-async.hook.ts"],"sourcesContent":["import { type ClassValue, clsx } from 'clsx';\nimport { extendTailwindMerge } from 'tailwind-merge';\n\nconst twMergeCustom = extendTailwindMerge({ prefix: 'tw-' });\n\n/**\n * Tailwind and CSS class application helper function. Uses\n * [`clsx`](https://www.npmjs.com/package/clsx) to make it easy to apply classes conditionally using\n * object syntax, and uses [`tailwind-merge`](https://www.npmjs.com/package/tailwind-merge) to make\n * it easy to merge/overwrite Tailwind classes in a programmer-logic-friendly way.\n *\n * Note: `tailwind-merge` is configured to use the prefix `tw-`, so you must use the same prefix\n * with any Tailwind classes you use with this function to successfully overwrite other Tailwind\n * classes. `platform-bible-react` is configured to use `tw-` as its Tailwind prefix, so any\n * Tailwind classes you pass into `platform-bible-react` components will be compared using the `tw-`\n * prefix.\n *\n * This function was popularized by\n * [shadcn/ui](https://ui.shadcn.com/docs/installation/manual#add-a-cn-helper). See [ByteGrad's\n * explanation video](https://www.youtube.com/watch?v=re2JFITR7TI) for more information.\n *\n * @example\n *\n * ```typescript\n * const borderShouldBeBlue = true;\n * const textShouldBeRed = true;\n * const heightShouldBe20 = false;\n * const classString = cn(\n * 'tw-bg-primary tw-h-10 tw-text-primary-foreground',\n * 'tw-bg-secondary',\n * {\n * 'tw-border-blue-500': borderShouldBeBlue,\n * 'tw-text-red-500': textShouldBeRed,\n * 'tw-h-20': heightShouldBe20,\n * },\n * 'some-class',\n * );\n * ```\n *\n * The resulting `classString` is `'tw-h-10 tw-bg-secondary tw-border-blue-500 tw-text-red-500\n * some-class'`\n *\n * - Notice that `'tw-bg-secondary'`, specified later, overwrote `'tw-bg-primary'`, specified earlier,\n * because they are Tailwind classes that affect the same css property\n * - Notice that `'tw-text-red-500'`, specified later, overwrote `'tw-text-primary-foreground'`,\n * specified earlier, because they are Tailwind classes that affect the same css property\n * - Notice that `'tw-h-20'`, specified later, did not overwrite `'tw-h-10'`, specified earlier,\n * because `'tw-h-20'` is part of a conditional class object and its value evaluated to `false`;\n * therefore it was not applied\n * - Notice that `'some-class'` was applied. This function is not limited only to Tailwind classes.\n *\n *\n * @param inputs Class strings or `clsx` conditional class objects to merge. Tailwind classes\n * specified later in the arguments overwrite similar Tailwind classes specified earlier in the\n * arguments\n * @returns Class string containing all applicable classes from the arguments based on the rules\n * described above\n */\n// shadcn/ui uses this export in its boilerplate code\n// eslint-disable-next-line import/prefer-default-export\nexport function cn(...inputs: ClassValue[]) {\n return twMergeCustom(clsx(inputs));\n}\n","import React from 'react';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport interface InputProps extends React.InputHTMLAttributes {}\n\nexport const Input = React.forwardRef(\n ({ className, type, ...props }, ref) => {\n return (\n \n );\n },\n);\nInput.displayName = 'Input';\n","import { FocusEventHandler, forwardRef, KeyboardEvent, MouseEventHandler } from 'react';\nimport { History } from 'lucide-react';\nimport { Input as ShadInput } from '@/components/shadcn-ui/input';\n\nexport type BookChapterInputProps = {\n handleSearch: (searchString: string) => void;\n handleKeyDown: (event: KeyboardEvent) => void;\n handleOnClick: MouseEventHandler;\n handleSubmit: () => void;\n onFocus?: FocusEventHandler;\n value: string;\n placeholder: string;\n};\n\n// Shadcn Input sets type to \"button\"- HAVE to prop spread before setting type\nconst BookChapterInput = forwardRef(\n (\n { handleSearch, handleKeyDown, handleOnClick, handleSubmit, ...props }: BookChapterInputProps,\n ref,\n ) => {\n return (\n
    \n handleSearch(event.target.value)}\n onKeyDown={(e) => {\n if (e.key === 'Enter') {\n handleSubmit();\n }\n handleKeyDown(e);\n }}\n onClick={handleOnClick}\n ref={ref}\n />\n {\n // eslint-disable-next-line no-console\n console.log('back in history');\n }}\n />\n
    \n );\n },\n);\n\nexport default BookChapterInput;\n","var P = Object.defineProperty;\nvar R = (t, e, s) => e in t ? P(t, e, { enumerable: !0, configurable: !0, writable: !0, value: s }) : t[e] = s;\nvar n = (t, e, s) => R(t, typeof e != \"symbol\" ? e + \"\" : e, s);\nclass _ {\n constructor() {\n n(this, \"books\");\n n(this, \"firstSelectedBookNum\");\n n(this, \"lastSelectedBookNum\");\n n(this, \"count\");\n n(this, \"selectedBookNumbers\");\n n(this, \"selectedBookIds\");\n }\n}\nconst N = [\n \"GEN\",\n \"EXO\",\n \"LEV\",\n \"NUM\",\n \"DEU\",\n \"JOS\",\n \"JDG\",\n \"RUT\",\n \"1SA\",\n \"2SA\",\n // 10\n \"1KI\",\n \"2KI\",\n \"1CH\",\n \"2CH\",\n \"EZR\",\n \"NEH\",\n \"EST\",\n \"JOB\",\n \"PSA\",\n \"PRO\",\n // 20\n \"ECC\",\n \"SNG\",\n \"ISA\",\n \"JER\",\n \"LAM\",\n \"EZK\",\n \"DAN\",\n \"HOS\",\n \"JOL\",\n \"AMO\",\n // 30\n \"OBA\",\n \"JON\",\n \"MIC\",\n \"NAM\",\n \"HAB\",\n \"ZEP\",\n \"HAG\",\n \"ZEC\",\n \"MAL\",\n \"MAT\",\n // 40\n \"MRK\",\n \"LUK\",\n \"JHN\",\n \"ACT\",\n \"ROM\",\n \"1CO\",\n \"2CO\",\n \"GAL\",\n \"EPH\",\n \"PHP\",\n // 50\n \"COL\",\n \"1TH\",\n \"2TH\",\n \"1TI\",\n \"2TI\",\n \"TIT\",\n \"PHM\",\n \"HEB\",\n \"JAS\",\n \"1PE\",\n // 60\n \"2PE\",\n \"1JN\",\n \"2JN\",\n \"3JN\",\n \"JUD\",\n \"REV\",\n \"TOB\",\n \"JDT\",\n \"ESG\",\n \"WIS\",\n // 70\n \"SIR\",\n \"BAR\",\n \"LJE\",\n \"S3Y\",\n \"SUS\",\n \"BEL\",\n \"1MA\",\n \"2MA\",\n \"3MA\",\n \"4MA\",\n // 80\n \"1ES\",\n \"2ES\",\n \"MAN\",\n \"PS2\",\n \"ODA\",\n \"PSS\",\n \"JSA\",\n // actual variant text for JOS, now in LXA text\n \"JDB\",\n // actual variant text for JDG, now in LXA text\n \"TBS\",\n // actual variant text for TOB, now in LXA text\n \"SST\",\n // actual variant text for SUS, now in LXA text // 90\n \"DNT\",\n // actual variant text for DAN, now in LXA text\n \"BLT\",\n // actual variant text for BEL, now in LXA text\n \"XXA\",\n \"XXB\",\n \"XXC\",\n \"XXD\",\n \"XXE\",\n \"XXF\",\n \"XXG\",\n \"FRT\",\n // 100\n \"BAK\",\n \"OTH\",\n \"3ES\",\n // Used previously but really should be 2ES\n \"EZA\",\n // Used to be called 4ES, but not actually in any known project\n \"5EZ\",\n // Used to be called 5ES, but not actually in any known project\n \"6EZ\",\n // Used to be called 6ES, but not actually in any known project\n \"INT\",\n \"CNC\",\n \"GLO\",\n \"TDX\",\n // 110\n \"NDX\",\n \"DAG\",\n \"PS3\",\n \"2BA\",\n \"LBA\",\n \"JUB\",\n \"ENO\",\n \"1MQ\",\n \"2MQ\",\n \"3MQ\",\n // 120\n \"REP\",\n \"4BA\",\n \"LAO\"\n], B = [\n \"XXA\",\n \"XXB\",\n \"XXC\",\n \"XXD\",\n \"XXE\",\n \"XXF\",\n \"XXG\",\n \"FRT\",\n \"BAK\",\n \"OTH\",\n \"INT\",\n \"CNC\",\n \"GLO\",\n \"TDX\",\n \"NDX\"\n], O = [\n \"Genesis\",\n \"Exodus\",\n \"Leviticus\",\n \"Numbers\",\n \"Deuteronomy\",\n \"Joshua\",\n \"Judges\",\n \"Ruth\",\n \"1 Samuel\",\n \"2 Samuel\",\n \"1 Kings\",\n \"2 Kings\",\n \"1 Chronicles\",\n \"2 Chronicles\",\n \"Ezra\",\n \"Nehemiah\",\n \"Esther (Hebrew)\",\n \"Job\",\n \"Psalms\",\n \"Proverbs\",\n \"Ecclesiastes\",\n \"Song of Songs\",\n \"Isaiah\",\n \"Jeremiah\",\n \"Lamentations\",\n \"Ezekiel\",\n \"Daniel (Hebrew)\",\n \"Hosea\",\n \"Joel\",\n \"Amos\",\n \"Obadiah\",\n \"Jonah\",\n \"Micah\",\n \"Nahum\",\n \"Habakkuk\",\n \"Zephaniah\",\n \"Haggai\",\n \"Zechariah\",\n \"Malachi\",\n \"Matthew\",\n \"Mark\",\n \"Luke\",\n \"John\",\n \"Acts\",\n \"Romans\",\n \"1 Corinthians\",\n \"2 Corinthians\",\n \"Galatians\",\n \"Ephesians\",\n \"Philippians\",\n \"Colossians\",\n \"1 Thessalonians\",\n \"2 Thessalonians\",\n \"1 Timothy\",\n \"2 Timothy\",\n \"Titus\",\n \"Philemon\",\n \"Hebrews\",\n \"James\",\n \"1 Peter\",\n \"2 Peter\",\n \"1 John\",\n \"2 John\",\n \"3 John\",\n \"Jude\",\n \"Revelation\",\n \"Tobit\",\n \"Judith\",\n \"Esther Greek\",\n \"Wisdom of Solomon\",\n \"Sirach (Ecclesiasticus)\",\n \"Baruch\",\n \"Letter of Jeremiah\",\n \"Song of 3 Young Men\",\n \"Susanna\",\n \"Bel and the Dragon\",\n \"1 Maccabees\",\n \"2 Maccabees\",\n \"3 Maccabees\",\n \"4 Maccabees\",\n \"1 Esdras (Greek)\",\n \"2 Esdras (Latin)\",\n \"Prayer of Manasseh\",\n \"Psalm 151\",\n \"Odes\",\n \"Psalms of Solomon\",\n // WARNING, if you change the spelling of the *obsolete* tag be sure to update\n // IsObsolete routine\n \"Joshua A. *obsolete*\",\n \"Judges B. *obsolete*\",\n \"Tobit S. *obsolete*\",\n \"Susanna Th. *obsolete*\",\n \"Daniel Th. *obsolete*\",\n \"Bel Th. *obsolete*\",\n \"Extra A\",\n \"Extra B\",\n \"Extra C\",\n \"Extra D\",\n \"Extra E\",\n \"Extra F\",\n \"Extra G\",\n \"Front Matter\",\n \"Back Matter\",\n \"Other Matter\",\n \"3 Ezra *obsolete*\",\n \"Apocalypse of Ezra\",\n \"5 Ezra (Latin Prologue)\",\n \"6 Ezra (Latin Epilogue)\",\n \"Introduction\",\n \"Concordance \",\n \"Glossary \",\n \"Topical Index\",\n \"Names Index\",\n \"Daniel Greek\",\n \"Psalms 152-155\",\n \"2 Baruch (Apocalypse)\",\n \"Letter of Baruch\",\n \"Jubilees\",\n \"Enoch\",\n \"1 Meqabyan\",\n \"2 Meqabyan\",\n \"3 Meqabyan\",\n \"Reproof (Proverbs 25-31)\",\n \"4 Baruch (Rest of Baruch)\",\n \"Laodiceans\"\n], S = K();\nfunction g(t, e = !0) {\n return e && (t = t.toUpperCase()), t in S ? S[t] : 0;\n}\nfunction k(t) {\n return g(t) > 0;\n}\nfunction x(t) {\n const e = typeof t == \"string\" ? g(t) : t;\n return e >= 40 && e <= 66;\n}\nfunction T(t) {\n return (typeof t == \"string\" ? g(t) : t) <= 39;\n}\nfunction X(t) {\n return t <= 66;\n}\nfunction V(t) {\n const e = typeof t == \"string\" ? g(t) : t;\n return w(e) && !X(e);\n}\nfunction* L() {\n for (let t = 1; t <= N.length; t++) yield t;\n}\nconst G = 1, A = N.length;\nfunction H() {\n return [\"XXA\", \"XXB\", \"XXC\", \"XXD\", \"XXE\", \"XXF\", \"XXG\"];\n}\nfunction C(t, e = \"***\") {\n const s = t - 1;\n return s < 0 || s >= N.length ? e : N[s];\n}\nfunction I(t) {\n return t <= 0 || t > A ? \"******\" : O[t - 1];\n}\nfunction y(t) {\n return I(g(t));\n}\nfunction w(t) {\n const e = typeof t == \"number\" ? C(t) : t;\n return k(e) && !B.includes(e);\n}\nfunction q(t) {\n const e = typeof t == \"number\" ? C(t) : t;\n return k(e) && B.includes(e);\n}\nfunction U(t) {\n return O[t - 1].includes(\"*obsolete*\");\n}\nfunction K() {\n const t = {};\n for (let e = 0; e < N.length; e++)\n t[N[e]] = e + 1;\n return t;\n}\nconst m = {\n allBookIds: N,\n nonCanonicalIds: B,\n bookIdToNumber: g,\n isBookIdValid: k,\n isBookNT: x,\n isBookOT: T,\n isBookOTNT: X,\n isBookDC: V,\n allBookNumbers: L,\n firstBook: G,\n lastBook: A,\n extraBooks: H,\n bookNumberToId: C,\n bookNumberToEnglishName: I,\n bookIdToEnglishName: y,\n isCanonical: w,\n isExtraMaterial: q,\n isObsolete: U\n};\nvar l = /* @__PURE__ */ ((t) => (t[t.Unknown = 0] = \"Unknown\", t[t.Original = 1] = \"Original\", t[t.Septuagint = 2] = \"Septuagint\", t[t.Vulgate = 3] = \"Vulgate\", t[t.English = 4] = \"English\", t[t.RussianProtestant = 5] = \"RussianProtestant\", t[t.RussianOrthodox = 6] = \"RussianOrthodox\", t))(l || {});\nconst h = class h {\n // private versInfo: Versification;\n constructor(e) {\n n(this, \"name\");\n n(this, \"fullPath\");\n n(this, \"isPresent\");\n n(this, \"hasVerseSegments\");\n n(this, \"isCustomized\");\n n(this, \"baseVersification\");\n n(this, \"scriptureBooks\");\n n(this, \"_type\");\n if (e == null)\n throw new Error(\"Argument undefined\");\n typeof e == \"string\" ? (this.name = e, this._type = l[e]) : (this._type = e, this.name = l[e]);\n }\n get type() {\n return this._type;\n }\n equals(e) {\n return !e.type || !this.type ? !1 : e.type === this.type;\n }\n};\nn(h, \"Original\", new h(l.Original)), n(h, \"Septuagint\", new h(l.Septuagint)), n(h, \"Vulgate\", new h(l.Vulgate)), n(h, \"English\", new h(l.English)), n(h, \"RussianProtestant\", new h(l.RussianProtestant)), n(h, \"RussianOrthodox\", new h(l.RussianOrthodox));\nlet c = h;\nfunction E(t, e) {\n const s = e[0];\n for (let r = 1; r < e.length; r++)\n t = t.split(e[r]).join(s);\n return t.split(s);\n}\nvar D = /* @__PURE__ */ ((t) => (t[t.Valid = 0] = \"Valid\", t[t.UnknownVersification = 1] = \"UnknownVersification\", t[t.OutOfRange = 2] = \"OutOfRange\", t[t.VerseOutOfOrder = 3] = \"VerseOutOfOrder\", t[t.VerseRepeated = 4] = \"VerseRepeated\", t))(D || {});\nconst i = class i {\n constructor(e, s, r, a) {\n /** Not yet implemented. */\n n(this, \"firstChapter\");\n /** Not yet implemented. */\n n(this, \"lastChapter\");\n /** Not yet implemented. */\n n(this, \"lastVerse\");\n /** Not yet implemented. */\n n(this, \"hasSegmentsDefined\");\n /** Not yet implemented. */\n n(this, \"text\");\n /** Not yet implemented. */\n n(this, \"BBBCCCVVVS\");\n /** Not yet implemented. */\n n(this, \"longHashCode\");\n /** The versification of the reference. */\n n(this, \"versification\");\n n(this, \"rtlMark\", \"‏\");\n n(this, \"_bookNum\", 0);\n n(this, \"_chapterNum\", 0);\n n(this, \"_verseNum\", 0);\n n(this, \"_verse\");\n if (r == null && a == null)\n if (e != null && typeof e == \"string\") {\n const o = e, u = s != null && s instanceof c ? s : void 0;\n this.setEmpty(u), this.parse(o);\n } else if (e != null && typeof e == \"number\") {\n const o = s != null && s instanceof c ? s : void 0;\n this.setEmpty(o), this._verseNum = e % i.chapterDigitShifter, this._chapterNum = Math.floor(\n e % i.bookDigitShifter / i.chapterDigitShifter\n ), this._bookNum = Math.floor(e / i.bookDigitShifter);\n } else if (s == null)\n if (e != null && e instanceof i) {\n const o = e;\n this._bookNum = o.bookNum, this._chapterNum = o.chapterNum, this._verseNum = o.verseNum, this._verse = o.verse, this.versification = o.versification;\n } else {\n if (e == null) return;\n const o = e instanceof c ? e : i.defaultVersification;\n this.setEmpty(o);\n }\n else\n throw new Error(\"VerseRef constructor not supported.\");\n else if (e != null && s != null && r != null)\n if (typeof e == \"string\" && typeof s == \"string\" && typeof r == \"string\")\n this.setEmpty(a), this.updateInternal(e, s, r);\n else if (typeof e == \"number\" && typeof s == \"number\" && typeof r == \"number\")\n this._bookNum = e, this._chapterNum = s, this._verseNum = r, this.versification = a ?? i.defaultVersification;\n else\n throw new Error(\"VerseRef constructor not supported.\");\n else\n throw new Error(\"VerseRef constructor not supported.\");\n }\n /**\n * Determines if the verse string is in a valid format (does not consider versification).\n */\n static isVerseParseable(e) {\n return e.length > 0 && \"0123456789\".includes(e[0]) && !e.endsWith(this.verseRangeSeparator) && !e.endsWith(this.verseSequenceIndicator);\n }\n /**\n * Tries to parse the specified string into a verse reference.\n * @param str - The string to attempt to parse.\n * @returns success: `true` if the specified string was successfully parsed, `false` otherwise.\n * @returns verseRef: The result of the parse if successful, or empty VerseRef if it failed\n */\n static tryParse(e) {\n let s;\n try {\n return s = new i(e), { success: !0, verseRef: s };\n } catch (r) {\n if (r instanceof v)\n return s = new i(), { success: !1, verseRef: s };\n throw r;\n }\n }\n /**\n * Gets the reference as a comparable integer where the book, chapter, and verse each occupy 3\n * digits.\n * @param bookNum - Book number (this is 1-based, not an index).\n * @param chapterNum - Chapter number.\n * @param verseNum - Verse number.\n * @returns The reference as a comparable integer where the book, chapter, and verse each occupy 3\n * digits.\n */\n static getBBBCCCVVV(e, s, r) {\n return e % i.bcvMaxValue * i.bookDigitShifter + (s >= 0 ? s % i.bcvMaxValue * i.chapterDigitShifter : 0) + (r >= 0 ? r % i.bcvMaxValue : 0);\n }\n /**\n * Deserializes a serialized VerseRef.\n * @param serializedVerseRef - Serialized VerseRef to create from.\n * @returns the deserialized VerseRef.\n */\n static fromJSON(e) {\n const { book: s, chapterNum: r, verseNum: a, verse: o, versificationStr: u } = e, f = o || a.toString();\n let d;\n return u && (d = new c(u)), s ? new i(s, r.toString(), f, d) : new i();\n }\n /**\n * Parses a verse string and gets the leading numeric portion as a number.\n * @param verseStr - verse string to parse\n * @returns true if the entire string could be parsed as a single, simple verse number (1-999);\n * false if the verse string represented a verse bridge, contained segment letters, or was invalid\n */\n static tryGetVerseNum(e) {\n let s;\n if (!e)\n return s = -1, { success: !0, vNum: s };\n s = 0;\n let r;\n for (let a = 0; a < e.length; a++) {\n if (r = e[a], r < \"0\" || r > \"9\")\n return a === 0 && (s = -1), { success: !1, vNum: s };\n if (s = s * 10 + +r - 0, s > i.bcvMaxValue)\n return s = -1, { success: !1, vNum: s };\n }\n return { success: !0, vNum: s };\n }\n /**\n * Checks to see if a VerseRef hasn't been set - all values are the default.\n */\n get isDefault() {\n return this.bookNum === 0 && this.chapterNum === 0 && this.verseNum === 0 && this.versification == null;\n }\n /**\n * Gets whether the verse contains multiple verses.\n */\n get hasMultiple() {\n return this._verse != null && (this._verse.includes(i.verseRangeSeparator) || this._verse.includes(i.verseSequenceIndicator));\n }\n /**\n * Gets or sets the book of the reference. Book is the 3-letter abbreviation in capital letters,\n * e.g. `'MAT'`.\n */\n get book() {\n return m.bookNumberToId(this.bookNum, \"\");\n }\n set book(e) {\n this.bookNum = m.bookIdToNumber(e);\n }\n /**\n * Gets or sets the chapter of the reference,. e.g. `'3'`.\n */\n get chapter() {\n return this.isDefault || this._chapterNum < 0 ? \"\" : this._chapterNum.toString();\n }\n set chapter(e) {\n const s = +e;\n this._chapterNum = Number.isInteger(s) ? s : -1;\n }\n /**\n * Gets or sets the verse of the reference, including range, segments, and sequences, e.g. `'4'`,\n * or `'4b-5a, 7'`.\n */\n get verse() {\n return this._verse != null ? this._verse : this.isDefault || this._verseNum < 0 ? \"\" : this._verseNum.toString();\n }\n set verse(e) {\n const { success: s, vNum: r } = i.tryGetVerseNum(e);\n this._verse = s ? void 0 : e.replace(this.rtlMark, \"\"), this._verseNum = r, !(this._verseNum >= 0) && ({ vNum: this._verseNum } = i.tryGetVerseNum(this._verse));\n }\n /**\n * Get or set Book based on book number, e.g. `42`.\n */\n get bookNum() {\n return this._bookNum;\n }\n set bookNum(e) {\n if (e <= 0 || e > m.lastBook)\n throw new v(\n \"BookNum must be greater than zero and less than or equal to last book\"\n );\n this._bookNum = e;\n }\n /**\n * Gets or sets the chapter number, e.g. `3`. `-1` if not valid.\n */\n get chapterNum() {\n return this._chapterNum;\n }\n set chapterNum(e) {\n this.chapterNum = e;\n }\n /**\n * Gets or sets verse start number, e.g. `4`. `-1` if not valid.\n */\n get verseNum() {\n return this._verseNum;\n }\n set verseNum(e) {\n this._verseNum = e;\n }\n /**\n * String representing the versification (should ONLY be used for serialization/deserialization).\n *\n * @remarks This is for backwards compatibility when ScrVers was an enumeration.\n */\n get versificationStr() {\n var e;\n return (e = this.versification) == null ? void 0 : e.name;\n }\n set versificationStr(e) {\n this.versification = this.versification != null ? new c(e) : void 0;\n }\n /**\n * Determines if the reference is valid.\n */\n get valid() {\n return this.validStatus === 0;\n }\n /**\n * Get the valid status for this reference.\n */\n get validStatus() {\n return this.validateVerse(i.verseRangeSeparators, i.verseSequenceIndicators);\n }\n /**\n * Gets the reference as a comparable integer where the book,\n * chapter, and verse each occupy three digits and the verse is 0.\n */\n get BBBCCC() {\n return i.getBBBCCCVVV(this._bookNum, this._chapterNum, 0);\n }\n /**\n * Gets the reference as a comparable integer where the book,\n * chapter, and verse each occupy three digits. If verse is not null\n * (i.e., this reference represents a complex reference with verse\n * segments or bridge) this cannot be used for an exact comparison.\n */\n get BBBCCCVVV() {\n return i.getBBBCCCVVV(this._bookNum, this._chapterNum, this._verseNum);\n }\n /**\n * Gets whether the verse is defined as an excluded verse in the versification.\n * Does not handle verse ranges.\n */\n // eslint-disable-next-line @typescript-eslint/class-literal-property-style\n get isExcluded() {\n return !1;\n }\n /**\n * Parses the reference in the specified string.\n * Optionally versification can follow reference as in GEN 3:11/4\n * Throw an exception if\n * - invalid book name\n * - chapter number is missing or not a number\n * - verse number is missing or does not start with a number\n * - versification is invalid\n * @param verseStr - string to parse e.g. 'MAT 3:11'\n */\n parse(e) {\n if (e = e.replace(this.rtlMark, \"\"), e.includes(\"/\")) {\n const o = e.split(\"/\");\n if (e = o[0], o.length > 1)\n try {\n const u = +o[1].trim();\n this.versification = new c(l[u]);\n } catch {\n throw new v(\"Invalid reference : \" + e);\n }\n }\n const s = e.trim().split(\" \");\n if (s.length !== 2)\n throw new v(\"Invalid reference : \" + e);\n const r = s[1].split(\":\"), a = +r[0];\n if (r.length !== 2 || m.bookIdToNumber(s[0]) === 0 || !Number.isInteger(a) || a < 0 || !i.isVerseParseable(r[1]))\n throw new v(\"Invalid reference : \" + e);\n this.updateInternal(s[0], r[0], r[1]);\n }\n /**\n * Simplifies this verse ref so that it has no bridging of verses or\n * verse segments like `'1a'`.\n */\n simplify() {\n this._verse = void 0;\n }\n /**\n * Makes a clone of the reference.\n *\n * @returns The cloned VerseRef.\n */\n clone() {\n return new i(this);\n }\n toString() {\n const e = this.book;\n return e === \"\" ? \"\" : `${e} ${this.chapter}:${this.verse}`;\n }\n toJSON() {\n let e = this.verse;\n (e === \"\" || e === this.verseNum.toString()) && (e = void 0);\n const s = {\n book: this.book,\n chapterNum: this.chapterNum,\n verseNum: this.verseNum,\n verse: e,\n versificationStr: this.versificationStr\n };\n return e || delete s.verse, s;\n }\n /**\n * Compares this `VerseRef` with supplied one.\n * @param verseRef - object to compare this one to.\n * @returns `true` if this `VerseRef` is equal to the supplied one, `false` otherwise.\n */\n equals(e) {\n return e instanceof i ? e._bookNum === this._bookNum && e._chapterNum === this._chapterNum && e._verseNum === this._verseNum && e.verse === this.verse && (e.versification == null && this.versification == null || e.versification != null && this.versification != null && e.versification.equals(this.versification)) : !1;\n }\n /**\n * Enumerate all individual verses contained in a VerseRef.\n * Verse ranges are indicated by \"-\" and consecutive verses by \",\"s.\n * Examples:\n * GEN 1:2 returns GEN 1:2\n * GEN 1:1a-3b,5 returns GEN 1:1a, GEN 1:2, GEN 1:3b, GEN 1:5\n * GEN 1:2a-2c returns //! ??????\n *\n * @param specifiedVersesOnly - if set to true return only verses that are\n * explicitly specified only, not verses within a range. Defaults to `false`.\n * @param verseRangeSeparators - Verse range separators.\n * Defaults to `VerseRef.verseRangeSeparators`.\n * @param verseSequenceSeparators - Verse sequence separators.\n * Defaults to `VerseRef.verseSequenceIndicators`.\n * @returns An array of all single verse references in this VerseRef.\n */\n allVerses(e = !1, s = i.verseRangeSeparators, r = i.verseSequenceIndicators) {\n if (this._verse == null || this.chapterNum <= 0)\n return [this.clone()];\n const a = [], o = E(this._verse, r);\n for (const u of o.map((f) => E(f, s))) {\n const f = this.clone();\n f.verse = u[0];\n const d = f.verseNum;\n if (a.push(f), u.length > 1) {\n const b = this.clone();\n if (b.verse = u[1], !e)\n for (let p = d + 1; p < b.verseNum; p++) {\n const J = new i(\n this._bookNum,\n this._chapterNum,\n p,\n this.versification\n );\n this.isExcluded || a.push(J);\n }\n a.push(b);\n }\n }\n return a;\n }\n /**\n * Validates a verse number using the supplied separators rather than the defaults.\n */\n validateVerse(e, s) {\n if (!this.verse)\n return this.internalValid;\n let r = 0;\n for (const a of this.allVerses(!0, e, s)) {\n const o = a.internalValid;\n if (o !== 0)\n return o;\n const u = a.BBBCCCVVV;\n if (r > u)\n return 3;\n if (r === u)\n return 4;\n r = u;\n }\n return 0;\n }\n /**\n * Gets whether a single verse reference is valid.\n */\n get internalValid() {\n return this.versification == null ? 1 : this._bookNum <= 0 || this._bookNum > m.lastBook ? 2 : (m.isCanonical(this._bookNum), 0);\n }\n setEmpty(e = i.defaultVersification) {\n this._bookNum = 0, this._chapterNum = -1, this._verse = void 0, this.versification = e;\n }\n updateInternal(e, s, r) {\n this.bookNum = m.bookIdToNumber(e), this.chapter = s, this.verse = r;\n }\n};\nn(i, \"defaultVersification\", c.English), n(i, \"verseRangeSeparator\", \"-\"), n(i, \"verseSequenceIndicator\", \",\"), n(i, \"verseRangeSeparators\", [i.verseRangeSeparator]), n(i, \"verseSequenceIndicators\", [i.verseSequenceIndicator]), n(i, \"chapterDigitShifter\", 1e3), n(i, \"bookDigitShifter\", i.chapterDigitShifter * i.chapterDigitShifter), n(i, \"bcvMaxValue\", i.chapterDigitShifter - 1), /**\n * The valid status of the VerseRef.\n */\nn(i, \"ValidStatusType\", D);\nlet M = i;\nclass v extends Error {\n}\nexport {\n _ as BookSet,\n m as Canon,\n c as ScrVers,\n l as ScrVersType,\n M as VerseRef,\n v as VerseRefException\n};\n//# sourceMappingURL=index.es.js.map\n","import React from 'react';\nimport * as DropdownMenuPrimitive from '@radix-ui/react-dropdown-menu';\nimport { Check, ChevronRight, Circle } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport const DropdownMenu = DropdownMenuPrimitive.Root;\n\nexport const DropdownMenuTrigger = DropdownMenuPrimitive.Trigger;\n\nexport const DropdownMenuGroup = DropdownMenuPrimitive.Group;\n\nexport const DropdownMenuPortal = DropdownMenuPrimitive.Portal;\n\nexport const DropdownMenuSub = DropdownMenuPrimitive.Sub;\n\nexport const DropdownMenuRadioGroup = DropdownMenuPrimitive.RadioGroup;\n\nexport type DropdownMenuSubTriggerProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.SubTrigger\n> & {\n className?: string;\n inset?: boolean;\n};\n\nexport type DropdownMenuSubContentProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.SubContent\n> & {\n className?: string;\n};\n\nexport type DropdownMenuContentProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Content\n> & {\n className?: string;\n sideOffset?: number;\n};\n\nexport type DropdownMenuItemProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Item\n> & {\n className?: string;\n inset?: boolean;\n};\n\nexport type DropdownMenuCheckboxItemProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.CheckboxItem\n> & {\n className?: string;\n checked?: boolean;\n};\n\nexport type DropdownMenuRadioItemProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.RadioItem\n> & {\n className?: string;\n};\n\nexport type DropdownMenuLabelProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Label\n> & {\n className?: string;\n inset?: boolean;\n};\n\nexport type DropdownMenuSeparatorProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Separator\n> & {\n className?: string;\n};\n\nexport type DropdownMenuShortcutProps = React.HTMLAttributes & {\n className?: string;\n};\n\nexport const DropdownMenuSubTrigger = React.forwardRef<\n React.ElementRef,\n DropdownMenuSubTriggerProps\n>(({ className, inset, children, ...props }, ref) => (\n \n {children}\n \n \n));\nDropdownMenuSubTrigger.displayName = DropdownMenuPrimitive.SubTrigger.displayName;\n\nexport const DropdownMenuSubContent = React.forwardRef<\n React.ElementRef,\n DropdownMenuSubContentProps\n>(({ className, ...props }, ref) => (\n \n));\nDropdownMenuSubContent.displayName = DropdownMenuPrimitive.SubContent.displayName;\n\nexport const DropdownMenuContent = React.forwardRef<\n React.ElementRef,\n DropdownMenuContentProps\n>(({ className, sideOffset = 4, ...props }, ref) => (\n \n \n \n));\nDropdownMenuContent.displayName = DropdownMenuPrimitive.Content.displayName;\n\n/**\n * TODO: fix: direction is not automatically handled by this component, so that shortcuts are\n * display always to the right\n */\nexport const DropdownMenuItem = React.forwardRef<\n React.ElementRef,\n DropdownMenuItemProps\n>(({ className, inset, ...props }, ref) => (\n \n));\nDropdownMenuItem.displayName = DropdownMenuPrimitive.Item.displayName;\n\nexport const DropdownMenuCheckboxItem = React.forwardRef<\n React.ElementRef,\n DropdownMenuCheckboxItemProps\n>(({ className, children, checked, ...props }, ref) => (\n \n \n \n \n \n \n {children}\n \n));\nDropdownMenuCheckboxItem.displayName = DropdownMenuPrimitive.CheckboxItem.displayName;\n\nexport const DropdownMenuRadioItem = React.forwardRef<\n React.ElementRef,\n DropdownMenuRadioItemProps\n>(({ className, children, ...props }, ref) => (\n \n \n \n \n \n \n {children}\n \n));\nDropdownMenuRadioItem.displayName = DropdownMenuPrimitive.RadioItem.displayName;\n\nexport const DropdownMenuLabel = React.forwardRef<\n React.ElementRef,\n DropdownMenuLabelProps\n>(({ className, inset, ...props }, ref) => (\n \n));\nDropdownMenuLabel.displayName = DropdownMenuPrimitive.Label.displayName;\n\nexport const DropdownMenuSeparator = React.forwardRef<\n React.ElementRef,\n DropdownMenuSeparatorProps\n>(({ className, ...props }, ref) => (\n \n));\nDropdownMenuSeparator.displayName = DropdownMenuPrimitive.Separator.displayName;\n\nexport function DropdownMenuShortcut({ className, ...props }: DropdownMenuShortcutProps) {\n return (\n \n );\n}\nDropdownMenuShortcut.displayName = 'DropdownMenuShortcut';\n","import { Canon } from '@sillsdev/scripture';\nimport { PropsWithChildren, KeyboardEvent, forwardRef } from 'react';\nimport { DropdownMenuItem as ShadDropdownMenuItem } from '@/components/shadcn-ui/dropdown-menu';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport type BookType = 'OT' | 'NT' | 'DC';\n\ntype BookMenuItemProps = PropsWithChildren<{\n /** String id of book */\n bookId: string;\n /** Callback to run when a book menu item is selected */\n handleSelectBook: () => void;\n /** Indicates if this menu item is currently selected */\n isSelected: boolean;\n /** Function that is called upon highlighting a book in the dropdown menu */\n handleHighlightBook: () => void;\n /**\n * Function that is called on pressing a key\n *\n * @param event Event that contains information about the key stroke\n */\n handleKeyDown: (event: KeyboardEvent) => void;\n /**\n * Type of book associated with this menu item, coordinates color labels ? Mock up has the labels\n * coordinated to genre\n */\n bookType: BookType;\n}>;\n\nconst BookMenuItem = forwardRef(\n (\n {\n bookId,\n handleSelectBook,\n isSelected,\n handleHighlightBook,\n handleKeyDown,\n bookType,\n children,\n }: BookMenuItemProps,\n ref,\n ) => {\n return (\n {\n // preventDefault() here prevents the entire dropdown menu from closing when selecting this item\n event.preventDefault();\n handleSelectBook();\n }}\n onKeyDown={(event: KeyboardEvent) => {\n handleKeyDown(event);\n }}\n onFocus={handleHighlightBook}\n onMouseMove={handleHighlightBook}\n >\n \n {Canon.bookIdToEnglishName(bookId)}\n \n {isSelected &&
    {children}
    }\n \n );\n },\n);\n\nexport default BookMenuItem;\n","import { cn } from '@/utils/shadcn-ui.util';\nimport { useCallback } from 'react';\n\nexport type ChapterSelectProps = {\n /**\n * Callback to run when a chapter div is selected\n *\n * @param chapterNumber Number of the chapter that has been selected\n */\n handleSelectChapter: (chapterNumber: number) => void;\n /** The highest chapter number in the book (of course equal to number of chapters in the book) */\n endChapter: number;\n /** The chapter number that is currently selected */\n activeChapter: number;\n /** The chapter number that is currently highlighted using keyboard or mouse navigation */\n highlightedChapter: number;\n /**\n * Callback to run when a chapter is highlighted by the user\n *\n * @param chapterNumber The chapter that is highlighted\n */\n handleHighlightedChapter: (chapterNumber: number) => void;\n};\n\nfunction ChapterSelect({\n handleSelectChapter,\n endChapter,\n activeChapter,\n highlightedChapter,\n handleHighlightedChapter,\n}: ChapterSelectProps) {\n const chapters = Array.from({ length: endChapter }, (_, i) => i + 1);\n\n const handleMouse = useCallback(\n (chapterNumber: number) => {\n handleHighlightedChapter(chapterNumber);\n },\n [handleHighlightedChapter],\n );\n\n return (\n
    \n {chapters.map((chapter) => (\n {\n event.preventDefault();\n event.stopPropagation();\n handleSelectChapter(chapter);\n }}\n role=\"button\"\n onKeyDown={(event) => {\n if (event.key === 'Enter') {\n handleSelectChapter(chapter);\n }\n }}\n tabIndex={0}\n onMouseMove={() => handleMouse(chapter)}\n >\n {chapter}\n
    \n ))}\n
    \n );\n}\n\nexport default ChapterSelect;\n","import { DropdownMenuLabel as ShadDropdownMenuLabel } from '@/components/shadcn-ui/dropdown-menu';\nimport { Bookmark, Clock, ArrowDownWideNarrow } from 'lucide-react';\n\nexport type GoToMenuItemProps = {\n handleSort: () => void;\n handleLocationHistory: () => void;\n handleBookmarks: () => void;\n};\n\nfunction GoToMenuItem({ handleSort, handleLocationHistory, handleBookmarks }: GoToMenuItemProps) {\n return (\n \n

    Go To

    \n
    \n \n \n \n
    \n
    \n );\n}\n\nexport default GoToMenuItem;\n","import BookChapterInput from '@/components/advanced/book-chapter-control/book-chapter-input.component';\nimport BookMenuItem, {\n BookType,\n} from '@/components/advanced/book-chapter-control/book-menu-item.component';\nimport ChapterSelect from '@/components/advanced/book-chapter-control/chapter-select.component';\nimport GoToMenuItem from '@/components/advanced/book-chapter-control/go-to-menu-item.component';\nimport {\n DropdownMenu as ShadDropdownMenu,\n DropdownMenuContent as ShadDropdownMenuContent,\n DropdownMenuLabel as ShadDropdownMenuLabel,\n DropdownMenuSeparator as ShadDropdownMenuSeparator,\n DropdownMenuTrigger as ShadDropdownMenuTrigger,\n} from '@/components/shadcn-ui/dropdown-menu';\nimport { Canon } from '@sillsdev/scripture';\nimport { ScriptureReference, getChaptersForBook } from 'platform-bible-utils';\nimport {\n KeyboardEvent as ReactKeyboardEvent,\n useCallback,\n useEffect,\n useLayoutEffect,\n useRef,\n useState,\n} from 'react';\n\ntype BookTypeLabels = {\n [bookType in BookType]: string;\n};\ntype BookChapterControlProps = {\n scrRef: ScriptureReference;\n handleSubmit: (scrRef: ScriptureReference) => void;\n};\n\nconst ALL_BOOK_IDS = Canon.allBookIds;\nconst BOOK_TYPE_LABELS: BookTypeLabels = {\n OT: 'Old Testament',\n NT: 'New Testament',\n DC: 'Deuterocanon',\n};\nconst BOOK_TYPE_ARRAY: BookType[] = ['OT', 'NT', 'DC'];\n// This is the height of three menu items to offset scrolling to the selected menu item\n// If you use menuItemRef.clientHeight- includes height of chapter div which is too big\nconst SCROLL_OFFSET = 32 + 32 + 32;\nconst SEARCH_QUERY_FORMATS = [\n /^(\\w+)$/i, // Matches a single word (book name or id)\n /^(\\w+)(?:\\s(\\d+))$/i, // Matches a word followed by a chapter number\n /^(\\w+)(?:\\s(\\d+):(\\d+))$/i, // Matches a word followed by a chapter and verse number\n];\nconst fetchGroupedBooks = (bookType: BookType) => {\n const groupedBooks = {\n OT: ALL_BOOK_IDS.filter((bookId) => Canon.isBookOT(bookId)),\n NT: ALL_BOOK_IDS.filter((bookId) => Canon.isBookNT(bookId)),\n DC: ALL_BOOK_IDS.filter((bookId) => Canon.isBookDC(bookId)),\n };\n return groupedBooks[bookType];\n};\nconst fetchEndChapter = (bookId: string) => {\n // getChaptersForBook returns -1 if not found in scrBookData\n // scrBookData only includes OT and NT, so all DC will return -1\n return getChaptersForBook(Canon.bookIdToNumber(bookId));\n};\n\n/**\n * Gets all of the English names from book ids\n *\n * @returns String[]\n */\nfunction getAllEnglishNames(): string[] {\n const allEnglishNames = ALL_BOOK_IDS.map((bookId) => {\n return Canon.bookIdToEnglishName(bookId);\n });\n return allEnglishNames;\n}\n\n/**\n * Determines if bookName is in allEnglishNames\n *\n * @param bookName Book English name\n * @returns True if bookName is included, false otherwise\n */\nfunction isValidBookEnglishName(bookName: string): boolean {\n return getAllEnglishNames().includes(bookName);\n}\n\n/**\n * Gets a bookId from given English name\n *\n * @param bookName Book English name\n * @returns BookId of provided bookName, undefined otherwise\n */\nfunction getBookIdFromEnglishName(bookName: string): string | undefined {\n // Convert bookName to lowercase and then capitalize the first letter\n const formattedBookName = bookName.toLowerCase().replace(/^\\w/, (c) => c.toUpperCase());\n\n if (isValidBookEnglishName(formattedBookName)) {\n const matchingBookId = ALL_BOOK_IDS.find((bookId) => {\n return Canon.bookIdToEnglishName(bookId) === formattedBookName;\n });\n return matchingBookId;\n }\n\n return undefined;\n}\n\nfunction BookChapterControl({ scrRef, handleSubmit }: BookChapterControlProps) {\n const [searchQuery, setSearchQuery] = useState('');\n const [selectedBookId, setSelectedBookId] = useState(\n Canon.bookNumberToId(scrRef.bookNum),\n );\n const [highlightedChapter, setHighlightedChapter] = useState(scrRef.chapterNum ?? 0);\n const [highlightedBookId, setHighlightedBookId] = useState(\n Canon.bookNumberToId(scrRef.bookNum),\n );\n const [isContentOpen, setIsContentOpen] = useState(false);\n const [isContentOpenDelayed, setIsContentOpenDelayed] = useState(isContentOpen);\n\n // This ref will always be defined\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const inputRef = useRef(undefined!);\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const contentRef = useRef(undefined!);\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const menuItemRef = useRef(undefined!);\n\n const fetchFilteredBooks = useCallback(\n (bookType: BookType) => {\n return fetchGroupedBooks(bookType).filter((bookId: string) => {\n const englishNameLowerCase = Canon.bookIdToEnglishName(bookId).toLowerCase();\n const normalizedQuery = searchQuery.replace(/[^a-zA-Z]/g, '').toLowerCase();\n return (\n englishNameLowerCase.includes(normalizedQuery) || // Match book name\n bookId.toLowerCase().includes(normalizedQuery) // Match book ID\n );\n });\n },\n [searchQuery],\n );\n\n const handleSearchInput = (searchString: string) => {\n setSearchQuery(searchString);\n };\n\n /**\n * Whether to prevent radix's logic from closing the dropdown. This is important because radix\n * tries to close the dropdown when the input first focuses, and we don't want it to do that. But\n * we don't want to prevent the dropdown from closing when we click away from the input, so we\n * don't want to just keep it open if the input is focused\n */\n const shouldPreventAutoClosing = useRef(false);\n\n const controlMenuState = useCallback((open: boolean) => {\n if (shouldPreventAutoClosing.current) {\n shouldPreventAutoClosing.current = false;\n return;\n }\n setIsContentOpen(open);\n }, []);\n\n const updateReference = useCallback(\n (bookId: string, shouldClose: boolean, chapter?: number, verse?: number) => {\n setHighlightedChapter(\n Canon.bookNumberToId(scrRef.bookNum) !== bookId ? 1 : scrRef.chapterNum,\n );\n\n if (shouldClose || fetchEndChapter(bookId) === -1) {\n handleSubmit({\n bookNum: Canon.bookIdToNumber(bookId),\n chapterNum: chapter || 1,\n verseNum: verse || 1,\n });\n\n setIsContentOpen(false);\n setSearchQuery('');\n return;\n }\n\n setSelectedBookId(selectedBookId !== bookId ? bookId : '');\n setIsContentOpen(!shouldClose);\n },\n [handleSubmit, scrRef.bookNum, scrRef.chapterNum, selectedBookId],\n );\n\n const handleSelectChapter = (chapterNumber: number) => {\n if (chapterNumber <= 0 || chapterNumber > fetchEndChapter(selectedBookId)) {\n return;\n }\n updateReference(selectedBookId, true, chapterNumber);\n };\n\n const handleInputSubmit = useCallback(() => {\n SEARCH_QUERY_FORMATS.forEach((format) => {\n const matches = searchQuery.match(format);\n if (matches) {\n // Book should be a bookId or an english name\n const [book, chapter = undefined, verse = undefined] = matches.slice(1);\n const englishName = getBookIdFromEnglishName(book);\n\n if (Canon.isBookIdValid(book) || englishName) {\n updateReference(\n englishName ?? book,\n true,\n chapter ? parseInt(chapter, 10) : 1,\n verse ? parseInt(verse, 10) : 1,\n );\n }\n }\n });\n }, [updateReference, searchQuery]);\n\n const handleKeyDownInput = useCallback(\n (event: ReactKeyboardEvent) => {\n if (!isContentOpen) {\n setIsContentOpen(true);\n } else if (event.key === 'ArrowDown' || event.key === 'ArrowUp') {\n if (\n typeof menuItemRef !== 'undefined' &&\n // Ref uses null\n // eslint-disable-next-line no-null/no-null\n menuItemRef.current !== null\n ) {\n menuItemRef.current.focus();\n } else if (\n typeof contentRef !== 'undefined' &&\n // Ref uses null\n // eslint-disable-next-line no-null/no-null\n contentRef.current !== null\n ) {\n contentRef.current.focus();\n }\n event.preventDefault();\n }\n },\n [isContentOpen],\n );\n\n const handleKeyDownContent = (event: ReactKeyboardEvent) => {\n // When the dropdown menu has focus, key strokes should give focus to the input component,\n // unless they're navigation keys (arrows and enter)\n const { key } = event;\n if (\n key === 'ArrowRight' ||\n key === 'ArrowLeft' ||\n key === 'ArrowDown' ||\n key === 'ArrowUp' ||\n key === 'Enter'\n ) {\n return;\n }\n\n inputRef.current.dispatchEvent(new KeyboardEvent('keydown', { key }));\n inputRef.current.focus();\n };\n\n const handleKeyDownMenuItem = (event: ReactKeyboardEvent) => {\n const { key } = event;\n if (highlightedBookId === selectedBookId) {\n if (key === 'Enter') {\n event.preventDefault();\n updateReference(selectedBookId, true, highlightedChapter);\n return;\n }\n\n let chapterOffSet = 0;\n if (key === 'ArrowRight') {\n if (highlightedChapter < fetchEndChapter(highlightedBookId)) {\n chapterOffSet = 1;\n } else {\n event.preventDefault();\n return;\n }\n } else if (key === 'ArrowLeft') {\n if (highlightedChapter > 1) {\n chapterOffSet = -1;\n } else {\n event.preventDefault();\n return;\n }\n } else if (key === 'ArrowDown') {\n chapterOffSet = 6;\n } else if (key === 'ArrowUp') {\n chapterOffSet = -6;\n }\n if (\n highlightedChapter + chapterOffSet <= 0 ||\n highlightedChapter + chapterOffSet > fetchEndChapter(highlightedBookId)\n ) {\n setHighlightedChapter(0);\n } else if (chapterOffSet !== 0) {\n setHighlightedChapter(highlightedChapter + chapterOffSet);\n event.preventDefault();\n }\n }\n };\n\n useEffect(() => {\n if (selectedBookId === highlightedBookId) {\n if (selectedBookId === Canon.bookNumberToId(scrRef.bookNum)) {\n setHighlightedChapter(scrRef.chapterNum);\n } else {\n setHighlightedChapter(1);\n }\n } else {\n setHighlightedChapter(0);\n }\n }, [highlightedBookId, scrRef.bookNum, scrRef.chapterNum, selectedBookId]);\n\n // The purpose of these useLayoutEffects and timeout is to delay the scroll just\n // enough so that the refs are defined and available when they are used after the timeout\n useLayoutEffect(() => {\n setIsContentOpenDelayed(isContentOpen);\n }, [isContentOpen]);\n\n useLayoutEffect(() => {\n const scrollTimeout = setTimeout(() => {\n if (isContentOpenDelayed && contentRef.current && menuItemRef.current) {\n const menuItemOffsetTop = menuItemRef.current.offsetTop;\n const scrollPosition = menuItemOffsetTop - SCROLL_OFFSET;\n contentRef.current.scrollTo({ top: scrollPosition, behavior: 'instant' });\n }\n }, 10);\n return () => {\n clearTimeout(scrollTimeout);\n };\n }, [isContentOpenDelayed]);\n\n return (\n
    \n \n \n {\n setSelectedBookId(Canon.bookNumberToId(scrRef.bookNum));\n setHighlightedBookId(Canon.bookNumberToId(scrRef.bookNum));\n setHighlightedChapter(scrRef.chapterNum > 0 ? scrRef.chapterNum : 0);\n setIsContentOpen(true);\n inputRef.current.focus();\n }}\n onFocus={() => {\n // Radix thinks we want to close because the input is being focused. Prevent that\n shouldPreventAutoClosing.current = true;\n }}\n handleSubmit={handleInputSubmit}\n placeholder={`${Canon.bookNumberToEnglishName(scrRef.bookNum)} ${scrRef.chapterNum}:${scrRef.verseNum}`}\n />\n \n \n console.log('sorting')}\n handleLocationHistory={() => console.log('location history')}\n handleBookmarks={() => console.log('bookmarks')}\n />\n {BOOK_TYPE_ARRAY.map(\n (bookType, bookTypeIndex) =>\n fetchFilteredBooks(bookType).length > 0 && (\n
    \n \n {BOOK_TYPE_LABELS[bookType]}\n \n\n {fetchFilteredBooks(bookType).map((bookId) => (\n
    \n updateReference(bookId, false)}\n isSelected={selectedBookId === bookId}\n handleHighlightBook={() => setHighlightedBookId(bookId)}\n handleKeyDown={handleKeyDownMenuItem}\n bookType={bookType}\n ref={(element: HTMLDivElement) => {\n if (selectedBookId === bookId) menuItemRef.current = element;\n }}\n >\n {\n setHighlightedChapter(chapterNumber);\n }}\n />\n \n
    \n ))}\n {BOOK_TYPE_ARRAY.length - 1 !== bookTypeIndex ? (\n \n ) : undefined}\n
    \n ),\n )}\n \n
    \n
    \n );\n}\n\nexport default BookChapterControl;\n","import React from 'react';\nimport { Slot } from '@radix-ui/react-slot';\nimport { cva, type VariantProps } from 'class-variance-authority';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport const buttonVariants = cva(\n 'pr-twp tw-inline-flex tw-items-center tw-justify-center tw-whitespace-nowrap tw-rounded-md tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-colors focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50',\n {\n variants: {\n variant: {\n default: 'tw-bg-primary tw-text-primary-foreground hover:tw-bg-primary/90',\n destructive: 'tw-bg-destructive tw-text-destructive-foreground hover:tw-bg-destructive/90',\n outline:\n 'tw-border tw-border-input tw-bg-background hover:tw-bg-accent hover:tw-text-accent-foreground',\n secondary: 'tw-bg-secondary tw-text-secondary-foreground hover:tw-bg-secondary/80',\n ghost: 'hover:tw-bg-accent hover:tw-text-accent-foreground',\n link: 'tw-text-primary tw-underline-offset-4 hover:tw-underline',\n },\n size: {\n default: 'tw-h-10 tw-px-4 tw-py-2',\n sm: 'tw-h-9 tw-rounded-md tw-px-3',\n lg: 'tw-h-11 tw-rounded-md tw-px-8',\n icon: 'tw-h-10 tw-w-10',\n },\n },\n defaultVariants: {\n variant: 'default',\n size: 'default',\n },\n },\n);\n\nexport interface ButtonProps\n extends React.ButtonHTMLAttributes,\n VariantProps {\n asChild?: boolean;\n}\n\nexport const Button = React.forwardRef(\n ({ className, variant, size, asChild = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'button';\n return (\n \n );\n },\n);\nButton.displayName = 'Button';\n","import React from 'react';\nimport * as LabelPrimitive from '@radix-ui/react-label';\nimport { cva, type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst labelVariants = cva(\n 'tw-text-sm tw-font-medium tw-leading-none peer-disabled:tw-cursor-not-allowed peer-disabled:tw-opacity-70',\n);\n\nexport const Label = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef & VariantProps\n>(({ className, ...props }, ref) => (\n \n));\nLabel.displayName = LabelPrimitive.Root.displayName;\n","import React from 'react';\nimport * as RadioGroupPrimitive from '@radix-ui/react-radio-group';\nimport { Circle } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst RadioGroup = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => {\n return (\n \n );\n});\nRadioGroup.displayName = RadioGroupPrimitive.Root.displayName;\n\nconst RadioGroupItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => {\n return (\n \n \n \n \n \n );\n});\nRadioGroupItem.displayName = RadioGroupPrimitive.Item.displayName;\n\nexport { RadioGroup, RadioGroupItem };\n","import React from 'react';\nimport * as PopoverPrimitive from '@radix-ui/react-popover';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Popover = PopoverPrimitive.Root;\n\nconst PopoverTrigger = PopoverPrimitive.Trigger;\n\nconst PopoverContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, align = 'center', sideOffset = 4, ...props }, ref) => (\n \n \n \n));\nPopoverContent.displayName = PopoverPrimitive.Content.displayName;\n\nexport { Popover, PopoverTrigger, PopoverContent };\n","import React from 'react';\nimport * as DialogPrimitive from '@radix-ui/react-dialog';\nimport { X } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Dialog = DialogPrimitive.Root;\n\nconst DialogTrigger = DialogPrimitive.Trigger;\n\nconst DialogPortal = DialogPrimitive.Portal;\n\nconst DialogClose = DialogPrimitive.Close;\n\nconst DialogOverlay = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nDialogOverlay.displayName = DialogPrimitive.Overlay.displayName;\n\nconst DialogContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, ...props }, ref) => (\n \n \n \n {children}\n \n \n Close\n \n \n \n));\nDialogContent.displayName = DialogPrimitive.Content.displayName;\n\nfunction DialogHeader({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nDialogHeader.displayName = 'DialogHeader';\n\nfunction DialogFooter({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nDialogFooter.displayName = 'DialogFooter';\n\nconst DialogTitle = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nDialogTitle.displayName = DialogPrimitive.Title.displayName;\n\nconst DialogDescription = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nDialogDescription.displayName = DialogPrimitive.Description.displayName;\n\nexport {\n Dialog,\n DialogPortal,\n DialogOverlay,\n DialogClose,\n DialogTrigger,\n DialogContent,\n DialogHeader,\n DialogFooter,\n DialogTitle,\n DialogDescription,\n};\n","import React from 'react';\nimport { type DialogProps } from '@radix-ui/react-dialog';\nimport { Command as CommandPrimitive } from 'cmdk';\nimport { Search } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Dialog, DialogContent } from '@/components/shadcn-ui/dialog';\n\nconst Command = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nCommand.displayName = CommandPrimitive.displayName;\n\ninterface CommandDialogProps extends DialogProps {}\n\nfunction CommandDialog({ children, ...props }: CommandDialogProps) {\n return (\n \n \n \n {children}\n \n \n \n );\n}\n\nconst CommandInput = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n
    \n \n \n
    \n));\n\nCommandInput.displayName = CommandPrimitive.Input.displayName;\n\nconst CommandList = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\n\nCommandList.displayName = CommandPrimitive.List.displayName;\n\nconst CommandEmpty = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>((props, ref) => (\n \n));\n\nCommandEmpty.displayName = CommandPrimitive.Empty.displayName;\n\nconst CommandGroup = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\n\nCommandGroup.displayName = CommandPrimitive.Group.displayName;\n\nconst CommandSeparator = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nCommandSeparator.displayName = CommandPrimitive.Separator.displayName;\n\nconst CommandItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\n\nCommandItem.displayName = CommandPrimitive.Item.displayName;\n\nfunction CommandShortcut({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nCommandShortcut.displayName = 'CommandShortcut';\n\nexport {\n Command,\n CommandDialog,\n CommandInput,\n CommandList,\n CommandEmpty,\n CommandGroup,\n CommandItem,\n CommandShortcut,\n CommandSeparator,\n};\n","import { useState } from 'react';\nimport { Check, ChevronsUpDown } from 'lucide-react';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport { Popover, PopoverContent, PopoverTrigger } from '@/components/shadcn-ui/popover';\nimport {\n Command,\n CommandEmpty,\n CommandInput,\n CommandItem,\n CommandList,\n} from '@/components/shadcn-ui/command';\nimport { PopoverProps } from '@radix-ui/react-popover';\n\nexport type ComboBoxLabelOption = { label: string };\nexport type ComboBoxOption = string | number | ComboBoxLabelOption;\n\nexport type ComboBoxProps = {\n /** Optional unique identifier */\n id?: string;\n /** Text label title for combobox */\n /** List of available options for the dropdown menu */\n options?: readonly T[];\n /** Additional css classes to help with unique styling of the combo box button */\n buttonClassName?: string;\n /** Additional css classes to help with unique styling of the combo box popover */\n popoverContentClassName?: string;\n /**\n * The selected value that the combo box currently holds. Must be shallow equal to one of the\n * options entries.\n */\n value?: T;\n /** Triggers when content of textfield is changed */\n onChange?: (newValue: T) => void;\n /** Used to determine the string value for a given option. */\n getOptionLabel?: (option: ComboBoxOption) => string;\n /** Text displayed on button if `value` is undefined */\n buttonPlaceholder?: string;\n /** Placeholder text for text field */\n textPlaceholder?: string;\n /** Text to display when no options match input */\n commandEmptyMessage?: string;\n /** Variant of button */\n buttonVariant?: ButtonProps['variant'];\n /** Text direction ltr or rtl */\n dir?: Direction;\n /** Optional boolean to set if trigger should be disabled */\n isDisabled?: boolean;\n} & PopoverProps;\n\ntype Direction = 'ltr' | 'rtl';\n\nfunction getOptionLabelDefault(option: ComboBoxOption): string {\n if (typeof option === 'string') {\n return option;\n }\n if (typeof option === 'number') {\n return option.toString();\n }\n return option.label;\n}\n\n/**\n * Autocomplete input and command palette with a list of suggestions.\n *\n * Thanks to Shadcn for heavy inspiration and documentation\n * https://ui.shadcn.com/docs/components/combobox\n */\nfunction ComboBox({\n id,\n options = [],\n buttonClassName,\n popoverContentClassName,\n value,\n onChange = () => {},\n getOptionLabel = getOptionLabelDefault,\n buttonPlaceholder = '',\n textPlaceholder = '',\n commandEmptyMessage = 'No option found',\n buttonVariant = 'outline',\n dir = 'ltr',\n isDisabled = false,\n ...props\n}: ComboBoxProps) {\n const [open, setOpen] = useState(false);\n\n return (\n \n \n \n \n {value ? getOptionLabel(value) : buttonPlaceholder}\n \n \n \n \n \n \n \n {commandEmptyMessage}\n \n {options.map((option) => (\n {\n onChange(option);\n setOpen(false);\n }}\n >\n \n {getOptionLabel(option)}\n \n ))}\n \n \n \n \n );\n}\n\nexport default ComboBox;\n","import { useMemo } from 'react';\nimport ComboBox from '@/components/basics/combo-box.component';\nimport { Label } from '@/components/shadcn-ui/label';\n\nexport type ChapterRangeSelectorProps = {\n startChapter: number;\n endChapter: number;\n handleSelectStartChapter: (chapter: number) => void;\n handleSelectEndChapter: (chapter: number) => void;\n isDisabled?: boolean;\n chapterCount: number;\n};\n\nexport default function ChapterRangeSelector({\n startChapter,\n endChapter,\n handleSelectStartChapter,\n handleSelectEndChapter,\n isDisabled = false,\n chapterCount,\n}: ChapterRangeSelectorProps) {\n const chapterOptions = useMemo(\n () => Array.from({ length: chapterCount }, (_, index) => index + 1),\n [chapterCount],\n );\n\n const onChangeStartChapter = (value: number) => {\n handleSelectStartChapter(value);\n if (value > endChapter) {\n handleSelectEndChapter(value);\n }\n };\n\n const onChangeEndChapter = (value: number) => {\n handleSelectEndChapter(value);\n if (value < startChapter) {\n handleSelectStartChapter(value);\n }\n };\n\n return (\n <>\n \n option.toString()}\n value={startChapter}\n />\n\n \n option.toString()}\n value={endChapter}\n />\n \n );\n}\n","import { Button } from '@/components/shadcn-ui/button';\nimport { Label } from '@/components/shadcn-ui/label';\nimport { RadioGroup, RadioGroupItem } from '@/components/shadcn-ui/radio-group';\nimport { Canon } from '@sillsdev/scripture';\nimport { LocalizedStringValue } from 'platform-bible-utils';\nimport { useState } from 'react';\nimport ChapterRangeSelector, {\n ChapterRangeSelectorProps,\n} from '../basics/chapter-range-selector.component';\n\nexport enum BookSelectionMode {\n CURRENT_BOOK = 'current book',\n CHOOSE_BOOKS = 'choose books',\n}\n\n/**\n * Object containing all keys used for localization in this component. If you're using this\n * component in an extension, you can pass it into the useLocalizedStrings hook to easily obtain the\n * localized strings and pass them into the localizedStrings prop of this component\n */\nexport const BOOK_SELECTOR_STRING_KEYS = Object.freeze([\n '%webView_bookSelector_currentBook%',\n '%webView_bookSelector_choose%',\n '%webView_bookSelector_chooseBooks%',\n] as const);\n\nexport type BookSelectorLocalizedStrings = {\n [localizedInventoryKey in (typeof BOOK_SELECTOR_STRING_KEYS)[number]]?: LocalizedStringValue;\n};\n\n/**\n * Gets the localized value for the provided key\n *\n * @param strings Object containing localized string\n * @param key Key for a localized string\n * @returns The localized value for the provided key, if available. Returns the key if no localized\n * value is available\n */\nconst localizeString = (\n strings: BookSelectorLocalizedStrings,\n key: keyof BookSelectorLocalizedStrings,\n) => {\n return strings[key] ?? key;\n};\n\ntype BookSelectorProps = ChapterRangeSelectorProps & {\n handleBookSelectionModeChange: (newMode: BookSelectionMode) => void;\n currentBookName: string;\n onSelectBooks: () => void;\n selectedBookIds: string[];\n localizedStrings: BookSelectorLocalizedStrings;\n};\n\nexport default function BookSelector({\n handleBookSelectionModeChange,\n currentBookName,\n onSelectBooks,\n selectedBookIds,\n chapterCount,\n endChapter,\n handleSelectEndChapter,\n startChapter,\n handleSelectStartChapter,\n localizedStrings,\n}: BookSelectorProps) {\n const currentBookText = localizeString(localizedStrings, '%webView_bookSelector_currentBook%');\n const chooseText = localizeString(localizedStrings, '%webView_bookSelector_choose%');\n const chooseBooksText = localizeString(localizedStrings, '%webView_bookSelector_chooseBooks%');\n\n const [bookSelectionMode, setBookSelectionMode] = useState(\n BookSelectionMode.CURRENT_BOOK,\n );\n\n const onSelectionModeChange = (newMode: BookSelectionMode) => {\n setBookSelectionMode(newMode);\n handleBookSelectionModeChange(newMode);\n };\n\n return (\n onSelectionModeChange(value as BookSelectionMode)}\n >\n
    \n
    \n
    \n \n \n
    \n \n
    \n \n
    \n
    \n
    \n
    \n \n \n
    \n \n onSelectBooks()}\n >\n {chooseText}\n \n
    \n
    \n \n );\n}\n","import { DropdownMenuTrigger } from '@radix-ui/react-dropdown-menu';\nimport { FilterIcon } from 'lucide-react';\nimport { Table } from '@tanstack/react-table';\n\nimport { Button } from '@/components/shadcn-ui/button';\nimport {\n DropdownMenu,\n DropdownMenuCheckboxItem,\n DropdownMenuContent,\n DropdownMenuLabel,\n DropdownMenuSeparator,\n} from '@/components/shadcn-ui/dropdown-menu';\n\ninterface DataTableViewOptionsProps {\n table: Table;\n}\n\nfunction DataTableViewOptions({ table }: DataTableViewOptionsProps) {\n return (\n \n \n \n \n \n Toggle columns\n \n {table\n .getAllColumns()\n .filter((column) => column.getCanHide())\n .map((column) => {\n return (\n column.toggleVisibility(!!value)}\n >\n {column.id}\n \n );\n })}\n \n \n );\n}\n\nexport default DataTableViewOptions;\n","import React from 'react';\nimport * as SelectPrimitive from '@radix-ui/react-select';\nimport { Check, ChevronDown, ChevronUp } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Select = SelectPrimitive.Root;\n\nconst SelectGroup = SelectPrimitive.Group;\n\nconst SelectValue = SelectPrimitive.Value;\n\nconst SelectTrigger = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, ...props }, ref) => (\n span]:tw-line-clamp-1',\n className,\n )}\n {...props}\n >\n {children}\n \n \n \n \n));\nSelectTrigger.displayName = SelectPrimitive.Trigger.displayName;\n\nconst SelectScrollUpButton = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n));\nSelectScrollUpButton.displayName = SelectPrimitive.ScrollUpButton.displayName;\n\nconst SelectScrollDownButton = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n));\nSelectScrollDownButton.displayName = SelectPrimitive.ScrollDownButton.displayName;\n\nconst SelectContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, position = 'popper', ...props }, ref) => (\n \n \n \n \n {children}\n \n \n \n \n));\nSelectContent.displayName = SelectPrimitive.Content.displayName;\n\nconst SelectLabel = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSelectLabel.displayName = SelectPrimitive.Label.displayName;\n\nconst SelectItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, ...props }, ref) => (\n \n \n \n \n \n \n\n {children}\n \n));\nSelectItem.displayName = SelectPrimitive.Item.displayName;\n\nconst SelectSeparator = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSelectSeparator.displayName = SelectPrimitive.Separator.displayName;\n\nexport {\n Select,\n SelectGroup,\n SelectValue,\n SelectTrigger,\n SelectContent,\n SelectLabel,\n SelectItem,\n SelectSeparator,\n SelectScrollUpButton,\n SelectScrollDownButton,\n};\n","import { ChevronLeftIcon, ChevronRightIcon, ArrowLeftIcon, ArrowRightIcon } from 'lucide-react';\nimport { Table } from '@tanstack/react-table';\n\nimport { Button } from '@/components/shadcn-ui/button';\nimport {\n Select,\n SelectContent,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\n\ninterface DataTablePaginationProps {\n table: Table;\n}\n\nfunction DataTablePagination({ table }: DataTablePaginationProps) {\n return (\n
    \n
    \n
    \n {table.getFilteredSelectedRowModel().rows.length} of{' '}\n {table.getFilteredRowModel().rows.length} row(s) selected\n
    \n
    \n

    Rows per page

    \n {\n table.setPageSize(Number(value));\n }}\n >\n \n \n \n \n {[10, 20, 30, 40, 50].map((pageSize) => (\n \n {pageSize}\n \n ))}\n \n \n
    \n
    \n Page {table.getState().pagination.pageIndex + 1} of {table.getPageCount()}\n
    \n
    \n table.setPageIndex(0)}\n disabled={!table.getCanPreviousPage()}\n >\n Go to first page\n \n \n table.previousPage()}\n disabled={!table.getCanPreviousPage()}\n >\n Go to previous page\n \n \n table.nextPage()}\n disabled={!table.getCanNextPage()}\n >\n Go to next page\n \n \n table.setPageIndex(table.getPageCount() - 1)}\n disabled={!table.getCanNextPage()}\n >\n Go to last page\n \n \n
    \n
    \n
    \n );\n}\n\nexport default DataTablePagination;\n","import React from 'react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Table = React.forwardRef<\n HTMLTableElement,\n React.HTMLAttributes & { stickyHeader?: boolean }\n>(({ className, stickyHeader, ...props }, ref) => (\n
    \n \n
    \n));\nTable.displayName = 'Table';\n\nconst TableHeader = React.forwardRef<\n HTMLTableSectionElement,\n React.HTMLAttributes & { stickyHeader?: boolean }\n>(({ className, stickyHeader, ...props }, ref) => (\n \n));\nTableHeader.displayName = 'TableHeader';\n\nconst TableBody = React.forwardRef<\n HTMLTableSectionElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableBody.displayName = 'TableBody';\n\nconst TableFooter = React.forwardRef<\n HTMLTableSectionElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n tr]:last:tw-border-b-0', className)}\n {...props}\n />\n));\nTableFooter.displayName = 'TableFooter';\n\nconst TableRow = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nTableRow.displayName = 'TableRow';\n\nconst TableHead = React.forwardRef<\n HTMLTableCellElement,\n React.ThHTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableHead.displayName = 'TableHead';\n\nconst TableCell = React.forwardRef<\n HTMLTableCellElement,\n React.TdHTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableCell.displayName = 'TableCell';\n\nconst TableCaption = React.forwardRef<\n HTMLTableCaptionElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableCaption.displayName = 'TableCaption';\n\nexport { Table, TableHeader, TableBody, TableFooter, TableHead, TableRow, TableCell, TableCaption };\n","import { useState } from 'react';\n\nimport {\n ColumnFiltersState,\n flexRender,\n getCoreRowModel,\n getFilteredRowModel,\n getPaginationRowModel,\n getSortedRowModel,\n SortingState,\n ColumnDef as TSColumnDef,\n Row as TSRow,\n RowSelectionState as TSRowSelectionState,\n SortDirection as TSSortDirection,\n Table as TSTable,\n useReactTable,\n VisibilityState,\n} from '@tanstack/react-table';\n\nimport DataTableViewOptions from '@/components/advanced/data-table/data-table-column-toggle.component';\nimport DataTablePagination from '@/components/advanced/data-table/data-table-pagination.component';\nimport { Button } from '@/components/shadcn-ui/button';\nimport {\n Table,\n TableBody,\n TableCell,\n TableHead,\n TableHeader,\n TableRow,\n} from '@/components/shadcn-ui/table';\n\nexport type ColumnDef = TSColumnDef;\nexport type RowContents = TSRow;\nexport type TableContents = TSTable;\nexport type SortDirection = TSSortDirection;\nexport type RowSelectionState = TSRowSelectionState;\n\ninterface DataTableProps {\n columns: ColumnDef[];\n data: TData[];\n enablePagination?: boolean;\n showPaginationControls?: boolean;\n showColumnVisibilityControls?: boolean;\n stickyHeader?: boolean;\n onRowClickHandler?: (row: RowContents, table: TableContents) => void;\n}\n\n/**\n * Feature-rich table component that infuses our basic shadcn-based Table component with features\n * from TanStack's React Table library\n */\nfunction DataTable({\n columns,\n data,\n enablePagination = false,\n showPaginationControls = false,\n showColumnVisibilityControls = false,\n stickyHeader = false,\n onRowClickHandler = () => {},\n}: DataTableProps) {\n const [sorting, setSorting] = useState([]);\n const [columnFilters, setColumnFilters] = useState([]);\n const [columnVisibility, setColumnVisibility] = useState({});\n const [rowSelection, setRowSelection] = useState({});\n\n const table = useReactTable({\n data,\n columns,\n getCoreRowModel: getCoreRowModel(),\n ...(enablePagination && { getPaginationRowModel: getPaginationRowModel() }),\n onSortingChange: setSorting,\n getSortedRowModel: getSortedRowModel(),\n onColumnFiltersChange: setColumnFilters,\n getFilteredRowModel: getFilteredRowModel(),\n onColumnVisibilityChange: setColumnVisibility,\n onRowSelectionChange: setRowSelection,\n state: {\n sorting,\n columnFilters,\n columnVisibility,\n rowSelection,\n },\n });\n\n return (\n
    \n {showColumnVisibilityControls && }\n \n \n {table.getHeaderGroups().map((headerGroup) => (\n \n {headerGroup.headers.map((header) => {\n return (\n \n {header.isPlaceholder\n ? undefined\n : flexRender(header.column.columnDef.header, header.getContext())}\n \n );\n })}\n \n ))}\n \n \n {table.getRowModel().rows?.length ? (\n table.getRowModel().rows.map((row) => (\n onRowClickHandler(row, table)}\n key={row.id}\n data-state={row.getIsSelected() && 'selected'}\n >\n {row.getVisibleCells().map((cell) => (\n \n {flexRender(cell.column.columnDef.cell, cell.getContext())}\n \n ))}\n \n ))\n ) : (\n \n \n No results.\n \n \n )}\n \n
    \n {enablePagination && (\n
    \n table.previousPage()}\n disabled={!table.getCanPreviousPage()}\n >\n Previous\n \n table.nextPage()}\n disabled={!table.getCanNextPage()}\n >\n Next\n \n
    \n )}\n {enablePagination && showPaginationControls && }\n
    \n );\n}\n\nexport default DataTable;\n","import {\n Table,\n TableBody,\n TableCell,\n TableHead,\n TableHeader,\n TableRow,\n} from '@/components/shadcn-ui/table';\nimport { Canon } from '@sillsdev/scripture';\nimport { deepEqual, LanguageStrings, ScriptureReference } from 'platform-bible-utils';\nimport { useMemo } from 'react';\nimport { InventoryItemOccurrence } from './inventory-utils';\n\n/** Props for the OccurrencesTable component */\ntype OccurrencesTableProps = {\n /** Data that contains scriptures references and snippets of scripture */\n occurrenceData: InventoryItemOccurrence[];\n /** Callback function that is executed when the scripture reference is changed */\n setScriptureReference: (scriptureReference: ScriptureReference) => void;\n /**\n * Object with all localized strings that the OccurrencesTable needs to work well across multiple\n * languages\n */\n localizedStrings: LanguageStrings;\n};\n\n/**\n * Table that shows occurrences of specified inventory item(s). The first column shows the related\n * scripture reference. The second column shows the snippet of scripture that contains the specified\n * inventory item\n */\nfunction OccurrencesTable({\n occurrenceData,\n setScriptureReference,\n localizedStrings,\n}: OccurrencesTableProps) {\n const referenceHeaderText =\n localizedStrings['%webView_inventory_occurrences_table_header_reference%'];\n const occurrenceHeaderText =\n localizedStrings['%webView_inventory_occurrences_table_header_occurrence%'];\n\n const occurrences: InventoryItemOccurrence[] = useMemo(() => {\n const uniqueOccurrences: InventoryItemOccurrence[] = [];\n\n occurrenceData.forEach((occurrence) => {\n if (!uniqueOccurrences.some((uniqueOccurrence) => deepEqual(uniqueOccurrence, occurrence))) {\n uniqueOccurrences.push(occurrence);\n }\n });\n\n return uniqueOccurrences;\n }, [occurrenceData]);\n\n return (\n \n \n \n {referenceHeaderText}\n {occurrenceHeaderText}\n \n \n \n {occurrences.length > 0 &&\n occurrences.map((occurrence) => (\n {\n setScriptureReference(occurrence.reference);\n }}\n >\n {`${Canon.bookNumberToEnglishName(occurrence.reference.bookNum)} ${occurrence.reference.chapterNum}:${occurrence.reference.verseNum}`}\n {occurrence.text}\n \n ))}\n \n
    \n );\n}\n\nexport default OccurrencesTable;\n","import React from 'react';\nimport * as CheckboxPrimitive from '@radix-ui/react-checkbox';\nimport { Check } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Checkbox = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n \n \n));\nCheckbox.displayName = CheckboxPrimitive.Root.displayName;\n\nexport default Checkbox;\n","import { Canon } from '@sillsdev/scripture';\nimport { ScriptureReference } from 'platform-bible-utils';\n\n/* #region Types */\n\n/**\n * Status of items that appear in inventories. 'approved' and 'unapproved' items are defined in the\n * project's `Settings.xml`. All other items are defined as 'unknown'\n */\nexport type Status = 'approved' | 'unapproved' | 'unknown';\n\n/** Occurrence of item in inventory. Primarily used by table that shows occurrences */\nexport type InventoryItemOccurrence = {\n /** Reference to scripture where the item appears */\n reference: ScriptureReference;\n /** Snippet of scripture that contains the occurrence */\n text: string;\n};\n\n/** Data structure that contains all information on an item that is shown in an inventory */\nexport type InventoryTableData = {\n /**\n * The item (e.g. a character in the characters inventory, a marker in the marker inventory) In\n * most cases the array will only have one element. In case of additional items (e.g. the\n * preceding marker in the markers check), the primary item should be stored in the first index.\n * To show additional items in the inventory, make sure to configure the `additionalItemsLabels`\n * prop for the Inventory component\n */\n items: string[];\n /** The number of times this item occurs in the selected scope */\n count: number;\n /** The status of this item (see documentation for `Status` type for more information) */\n status: Status;\n /** Occurrences of this item in the scripture text for the selected scope */\n occurrences: InventoryItemOccurrence[];\n};\n\n/* #endregion */\n\n/* #region Functions */\n\n/**\n * Splits USFM string into shorter line-like segments\n *\n * @param text A single (likely very large) USFM string\n * @returns An array containing the input text, split into shorter segments\n */\nexport const getLinesFromUSFM = (text: string) => {\n // Splits on (CR)LF, CR, \\v, \\c and \\id\n return text.split(/(?:\\r?\\n|\\r)|(?=(?:\\\\(?:v|c|id)))/g);\n};\n\n/**\n * Extracts chapter or verse number from USFM strings that start with a \\c or \\v marker\n *\n * @param text USFM string that is expected to start with \\c or \\v marker\n * @returns Chapter or verse number if one is found. Else returns 0.\n */\nexport const getNumberFromUSFM = (text: string): number | undefined => {\n // Captures all digits that follow \\v or \\c markers followed by whitespace located at the start of a string\n const regex = /^\\\\[vc]\\s+(\\d+)/;\n const match = text.match(regex);\n\n if (match) {\n return +match[1];\n }\n return undefined;\n};\n\n/**\n * Gets book ID from USFM string that starts with the \\id marker, and returns book number for it\n *\n * @param text USFM string that is expected to start with \\id marker\n * @returns Book number corresponding to the \\id marker in the input text. Returns 0 if no marker is\n * found or the marker is not valid\n */\nexport const getBookNumFromId = (text: string): number => {\n // Captures all digits that follow an \\id marker followed by whitespace located at the start of a string\n const match = text.match(/^\\\\id\\s+([A-Za-z]+)/);\n if (match) {\n return Canon.bookIdToNumber(match[1]);\n }\n return 0;\n};\n\n/**\n * Gets the status for an item, typically used in the Inventory component\n *\n * @param item The item for which the status is being requested\n * @param approvedItems Array of approved items, typically as defined in `Settings.xml`\n * @param unapprovedItems Array of unapproved items, typically as defined in `Settings.xml`\n * @returns The status for the specified item\n */\nexport const getStatusForItem = (\n item: string,\n approvedItems: string[],\n unapprovedItems: string[],\n): Status => {\n if (unapprovedItems.includes(item)) return 'unapproved';\n if (approvedItems.includes(item)) return 'approved';\n return 'unknown';\n};\n\n/* #endregion */\n","import React from 'react';\nimport * as TogglePrimitive from '@radix-ui/react-toggle';\nimport { cva, type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst toggleVariants = cva(\n 'pr-twp tw-inline-flex tw-items-center tw-justify-center tw-rounded-md tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-colors hover:tw-bg-muted hover:tw-text-muted-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50 data-[state=on]:tw-bg-accent data-[state=on]:tw-text-accent-foreground',\n {\n variants: {\n variant: {\n default: 'tw-bg-transparent',\n outline:\n 'tw-border tw-border-input tw-bg-transparent hover:tw-bg-accent hover:tw-text-accent-foreground',\n },\n size: {\n default: 'tw-h-10 tw-px-3',\n sm: 'tw-h-9 tw-px-2.5',\n lg: 'tw-h-11 tw-px-5',\n },\n },\n defaultVariants: {\n variant: 'default',\n size: 'default',\n },\n },\n);\n\nconst Toggle = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef & VariantProps\n>(({ className, variant, size, ...props }, ref) => (\n \n));\n\nToggle.displayName = TogglePrimitive.Root.displayName;\n\nexport { Toggle, toggleVariants };\n","import React from 'react';\nimport * as ToggleGroupPrimitive from '@radix-ui/react-toggle-group';\nimport { type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { toggleVariants } from '@/components/shadcn-ui/toggle';\n\nconst ToggleGroupContext = React.createContext>({\n size: 'default',\n variant: 'default',\n});\n\nconst ToggleGroup = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef &\n VariantProps\n>(({ className, variant, size, children, ...props }, ref) => (\n \n \n {children}\n \n \n));\n\nToggleGroup.displayName = ToggleGroupPrimitive.Root.displayName;\n\nconst ToggleGroupItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef &\n VariantProps\n>(({ className, children, variant, size, ...props }, ref) => {\n const context = React.useContext(ToggleGroupContext);\n\n return (\n \n {children}\n \n );\n});\n\nToggleGroupItem.displayName = ToggleGroupPrimitive.Item.displayName;\n\nexport { ToggleGroup, ToggleGroupItem };\n","import { ColumnDef, SortDirection } from '@/components/advanced/data-table/data-table.component';\nimport { Button } from '@/components/shadcn-ui/button';\nimport { ToggleGroup, ToggleGroupItem } from '@/components/shadcn-ui/toggle-group';\nimport {\n ArrowDownIcon,\n ArrowUpDownIcon,\n ArrowUpIcon,\n CircleCheckIcon,\n CircleHelpIcon,\n CircleXIcon,\n} from 'lucide-react';\nimport { ReactNode } from 'react';\nimport { InventoryTableData, Status } from './inventory-utils';\n\n/**\n * Gets an icon that indicates the current sorting direction based on the provided input\n *\n * @param sortDirection Sorting direction. Can be ascending ('asc'), descending ('desc') or false (\n * i.e. not sorted)\n * @returns The appropriate sorting icon for the provided sorting direction\n */\nconst getSortingIcon = (sortDirection: false | SortDirection): ReactNode => {\n if (sortDirection === 'asc') {\n return ;\n }\n if (sortDirection === 'desc') {\n return ;\n }\n return ;\n};\n\n/**\n * Function that creates the item column for inventories\n *\n * @param itemLabel Localized label for the item column (e.g. 'Character', 'Repeated Word', etc.)\n * @returns Column that shows the inventory items. Should be used with the DataTable component\n */\nexport const inventoryItemColumn = (itemLabel: string): ColumnDef => {\n return {\n accessorKey: 'item',\n accessorFn: (row: InventoryTableData) => row.items[0],\n header: ({ column }) => (\n \n ),\n };\n};\n\n/**\n * Function that creates the additional item columns for inventories\n *\n * @param additionalItemLabel Localized label for the additional item column (e.g. 'Preceding\n * Marker')\n * @param additionalItemIndex Index that locates the desired item in the items array of the\n * inventory\n * @returns Column that shows additional inventory items. Should be used with the DataTable\n * component\n */\nexport const inventoryAdditionalItemColumn = (\n additionalItemLabel: string,\n additionalItemIndex: number,\n): ColumnDef => {\n return {\n accessorKey: `item${additionalItemIndex}`,\n accessorFn: (row: InventoryTableData) => row.items[additionalItemIndex],\n header: ({ column }) => (\n \n ),\n };\n};\n\n/**\n * Function that creates the count column for inventories. Should be used with the DataTable\n * component.\n *\n * @param itemLabel Localized label for the count column\n * @returns Column that shows the number of occurrences of the related inventory items\n */\nexport const inventoryCountColumn = (countLabel: string): ColumnDef => {\n return {\n accessorKey: 'count',\n header: ({ column }) => (\n
    \n \n
    \n ),\n cell: ({ row }) =>
    {row.getValue('count')}
    ,\n };\n};\n\n/**\n * Function that updates project settings when status for item(s) changes\n *\n * @param changedItems Array of items for which the status is being updated\n * @param newStatus The status that the items are being given\n * @param approvedItems Array of currently approved items\n * @param onApprovedItemsChange Callback function that stores the updated list of approved items\n * @param unapprovedItems Array of currently unapproved items\n * @param onUnapprovedItemsChange Callback function that stores the updated list of unapproved items\n */\nconst statusChangeHandler = (\n changedItems: string[],\n newStatus: Status,\n approvedItems: string[],\n onApprovedItemsChange: (items: string[]) => void,\n unapprovedItems: string[],\n onUnapprovedItemsChange: (items: string[]) => void,\n) => {\n let newApprovedItems: string[] = [...approvedItems];\n changedItems.forEach((item) => {\n if (newStatus === 'approved') {\n if (!newApprovedItems.includes(item)) {\n newApprovedItems.push(item);\n }\n } else {\n newApprovedItems = newApprovedItems.filter((validItem) => validItem !== item);\n }\n });\n onApprovedItemsChange(newApprovedItems);\n\n let newUnapprovedItems: string[] = [...unapprovedItems];\n changedItems.forEach((item) => {\n if (newStatus === 'unapproved') {\n if (!newUnapprovedItems.includes(item)) {\n newUnapprovedItems.push(item);\n }\n } else {\n newUnapprovedItems = newUnapprovedItems.filter((unapprovedItem) => unapprovedItem !== item);\n }\n });\n onUnapprovedItemsChange(newUnapprovedItems);\n};\n\n/**\n * Function that creates the status column for inventories. Should be used with the DataTable\n * component.\n *\n * @param statusLabel Localized label for the status column\n * @param approvedItems Array of approved items, typically as defined in `Settings.xml`\n * @param onApprovedItemsChange Callback function that stores the updated list of approved items\n * @param unapprovedItems Array of unapproved items, typically as defined in `Settings.xml`\n * @param onUnapprovedItemsChange Callback function that stores the updated list of unapproved items\n * @returns Column that shows the status buttons for the related inventory item. The button for the\n * current status of the item is selected\n */\nexport const inventoryStatusColumn = (\n statusLabel: string,\n approvedItems: string[],\n onApprovedItemsChange: (items: string[]) => void,\n unapprovedItems: string[],\n onUnapprovedItemsChange: (items: string[]) => void,\n): ColumnDef => {\n return {\n accessorKey: 'status',\n header: ({ column }) => {\n return (\n
    \n \n
    \n );\n },\n cell: ({ row }) => {\n const status: Status = row.getValue('status');\n const item: string = row.getValue('item');\n return (\n \n \n statusChangeHandler(\n [item],\n 'approved',\n approvedItems,\n onApprovedItemsChange,\n unapprovedItems,\n onUnapprovedItemsChange,\n )\n }\n value=\"approved\"\n >\n \n \n \n statusChangeHandler(\n [item],\n 'unapproved',\n approvedItems,\n onApprovedItemsChange,\n unapprovedItems,\n onUnapprovedItemsChange,\n )\n }\n value=\"unapproved\"\n >\n \n \n \n statusChangeHandler(\n [item],\n 'unknown',\n approvedItems,\n onApprovedItemsChange,\n unapprovedItems,\n onUnapprovedItemsChange,\n )\n }\n value=\"unknown\"\n >\n \n \n \n );\n },\n };\n};\n","import DataTable, {\n ColumnDef,\n RowContents,\n RowSelectionState,\n TableContents,\n} from '@/components/advanced/data-table/data-table.component';\nimport OccurrencesTable from '@/components/advanced/inventory/occurrences-table.component';\nimport Checkbox from '@/components/shadcn-ui/checkbox';\nimport { Input } from '@/components/shadcn-ui/input';\nimport { Label } from '@/components/shadcn-ui/label';\nimport {\n Select,\n SelectContent,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\nimport {\n deepEqual,\n LocalizedStringValue,\n ScriptureReference,\n substring,\n} from 'platform-bible-utils';\nimport { useEffect, useMemo, useState } from 'react';\nimport {\n getBookNumFromId,\n getLinesFromUSFM,\n getNumberFromUSFM,\n getStatusForItem,\n InventoryItemOccurrence,\n InventoryTableData,\n Status,\n} from './inventory-utils';\nimport { inventoryAdditionalItemColumn } from './inventory-columns';\n\n/**\n * Object containing all keys used for localization in this component. If you're using this\n * component in an extension, you can pass it into the useLocalizedStrings hook to easily obtain the\n * localized strings and pass them into the localizedStrings prop of this component\n */\nexport const INVENTORY_STRING_KEYS = Object.freeze([\n '%webView_inventory_all%',\n '%webView_inventory_approved%',\n '%webView_inventory_unapproved%',\n '%webView_inventory_unknown%',\n '%webView_inventory_scope_currentBook%',\n '%webView_inventory_scope_chapter%',\n '%webView_inventory_scope_verse%',\n '%webView_inventory_filter_text%',\n '%webView_inventory_show_additional_items%',\n '%webView_inventory_occurrences_table_header_reference%',\n '%webView_inventory_occurrences_table_header_occurrence%',\n] as const);\n\nexport type InventoryLocalizedStrings = {\n [localizedInventoryKey in (typeof INVENTORY_STRING_KEYS)[number]]?: LocalizedStringValue;\n};\n\n/** Scope of scripture that the inventory can operate on */\nexport type Scope = 'book' | 'chapter' | 'verse';\n\n/** Status values that the status filter can select from */\ntype StatusFilter = Status | 'all';\n\n/** Text labels for the inventory columns and the control components of additional inventory items */\ntype AdditionalItemsLabels = {\n checkboxText?: string;\n tableHeaders?: string[];\n};\n\n/**\n * Filters data that is shown in the DataTable section of the Inventory\n *\n * @param itemData All inventory items and their related information\n * @param statusFilter Allows filtering by status (i.e. show all items, or only items that are\n * 'approved', 'unapproved' or 'unknown')\n * @param textFilter Allows filtering by text. All items that include the filter text will be\n * selected.\n * @returns Array of items and their related information that are matched by the specified filters\n */\nconst filterItemData = (\n itemData: InventoryTableData[],\n statusFilter: StatusFilter,\n textFilter: string,\n): InventoryTableData[] => {\n let filteredItemData: InventoryTableData[] = itemData;\n\n if (statusFilter !== 'all') {\n filteredItemData = filteredItemData.filter(\n (item) =>\n (statusFilter === 'approved' && item.status === 'approved') ||\n (statusFilter === 'unapproved' && item.status === 'unapproved') ||\n (statusFilter === 'unknown' && item.status === 'unknown'),\n );\n }\n\n if (textFilter !== '')\n filteredItemData = filteredItemData.filter((item) => item.items[0].includes(textFilter));\n\n return filteredItemData;\n};\n\n/**\n * Turns array of strings into array of inventory items, along with their count and status\n *\n * @param text The source scripture text that is searched for inventory items\n * @param scriptureRef The scripture reference that the application is currently set to\n * @param approvedItems Array of approved items, typically as defined in `Settings.xml`\n * @param unapprovedItems Array of unapproved items, typically as defined in `Settings.xml`\n * @param itemRegex Regular expression that describes what items this Inventory should extract from\n * the provided scripture text\n * @returns Array of inventory items, along with their count and status\n */\nconst createTableData = (\n text: string | undefined,\n scriptureRef: ScriptureReference,\n approvedItems: string[],\n unapprovedItems: string[],\n itemRegex: RegExp,\n): InventoryTableData[] => {\n if (!text) return [];\n\n const tableData: InventoryTableData[] = [];\n\n let currentBook: number | undefined = scriptureRef.bookNum;\n let currentChapter: number | undefined = scriptureRef.chapterNum;\n let currentVerse: number | undefined = scriptureRef.verseNum;\n\n const lines = getLinesFromUSFM(text);\n\n lines.forEach((line: string) => {\n if (line.startsWith('\\\\id')) {\n currentBook = getBookNumFromId(line);\n currentChapter = 0;\n currentVerse = 0;\n }\n if (line.startsWith('\\\\c')) {\n currentChapter = getNumberFromUSFM(line);\n currentVerse = 0;\n }\n if (line.startsWith('\\\\v')) {\n currentVerse = getNumberFromUSFM(line);\n if (currentChapter === 0) {\n currentChapter = scriptureRef.chapterNum;\n }\n }\n\n let match: RegExpExecArray | undefined = itemRegex.exec(line) ?? undefined;\n while (match) {\n const items: string[] = [];\n match.forEach((item) => items.push(item));\n const itemIndex = match.index;\n const existingItem = tableData.find((tableEntry) => deepEqual(tableEntry.items, items));\n const newReference: InventoryItemOccurrence = {\n reference: {\n bookNum: currentBook !== undefined ? currentBook : -1,\n chapterNum: currentChapter !== undefined ? currentChapter : -1,\n verseNum: currentVerse !== undefined ? currentVerse : -1,\n },\n text: substring(line, Math.max(0, itemIndex - 25), Math.min(itemIndex + 25, line.length)),\n };\n if (existingItem) {\n existingItem.count += 1;\n existingItem.occurrences.push(newReference);\n } else {\n const newItem: InventoryTableData = {\n items,\n count: 1,\n status: getStatusForItem(items[0], approvedItems, unapprovedItems),\n occurrences: [newReference],\n };\n tableData.push(newItem);\n }\n\n match = itemRegex.exec(line) ?? undefined;\n }\n });\n\n return tableData;\n};\n\n/**\n * Gets the localized value for the provided key\n *\n * @param strings Object containing localized string\n * @param key Key for a localized string\n * @returns The localized value for the provided key, if available. Returns the key if no localized\n * value is available\n */\nconst localizeString = (\n strings: InventoryLocalizedStrings,\n key: keyof InventoryLocalizedStrings,\n) => {\n return strings[key] ?? key;\n};\n\n/** Props for the Inventory component */\ntype InventoryProps = {\n /** The scripture reference that the application is currently set to */\n scriptureReference: ScriptureReference;\n /** Callback function that is executed when the scripture reference is changed */\n setScriptureReference: (scriptureReference: ScriptureReference) => void;\n /**\n * Object with all localized strings that the Inventory needs to work well across multiple\n * languages. When using this component with Platform.Bible, you can import\n * `INVENTORY_STRING_KEYS` from this library, pass it in to the Platform's localization hook, and\n * pass the localized keys that are returned by the hook into this prop.\n */\n localizedStrings: InventoryLocalizedStrings;\n /**\n * The logic that finds the desired items in the source text. This can either be a Regular\n * expression that captures one or multiple items (preferred), or a custom function that builds\n * and return an InventoryDataTable[] manually. Note: In case the logic captures more than one\n * item (i.e. InventoryTableData.items has a length greater than 1), you must provide text labels\n * for the related columns and control elements to show by setting the `additionalItemsLabels`\n * prop\n */\n extractItems:\n | RegExp\n | ((\n text: string | undefined,\n scriptureRef: ScriptureReference,\n approvedItems: string[],\n unapprovedItems: string[],\n ) => InventoryTableData[]);\n /**\n * Text labels for control elements and additional column headers in case your Inventory has more\n * than one item to show (e.g. The 'Preceding Marker' in the Markers Inventory)\n */\n additionalItemsLabels?: AdditionalItemsLabels;\n /** Array of approved items, typically as defined in `Settings.xml` */\n approvedItems: string[];\n /** Array of unapproved items, typically as defined in `Settings.xml` */\n unapprovedItems: string[];\n /** The source scripture text that is searched for in inventory items */\n text: string | undefined;\n /** Scope of scripture that the inventory will operate on */\n scope: Scope;\n /** Callback function that is executed when the scope is changed from the Inventory */\n onScopeChange: (scope: Scope) => void;\n /**\n * Column definitions for the Inventory data table. The most commonly used column definitions are\n * pre-configured for your convenience and can be imported (e.g. inventoryItemColumn,\n * inventoryAdditionalItemColumn inventoryCountColumn, and inventoryStatusColumn). If you need any\n * other columns you can add these yourself\n */\n columns: ColumnDef[];\n};\n\n/** Inventory component that is used to view and control the status of provided project settings */\nexport default function Inventory({\n scriptureReference,\n setScriptureReference,\n localizedStrings,\n extractItems,\n additionalItemsLabels,\n approvedItems,\n unapprovedItems,\n text,\n scope,\n onScopeChange,\n columns,\n}: InventoryProps) {\n const allItemsText = localizeString(localizedStrings, '%webView_inventory_all%');\n const approvedItemsText = localizeString(localizedStrings, '%webView_inventory_approved%');\n const unapprovedItemsText = localizeString(localizedStrings, '%webView_inventory_unapproved%');\n const unknownItemsText = localizeString(localizedStrings, '%webView_inventory_unknown%');\n const scopeBookText = localizeString(localizedStrings, '%webView_inventory_scope_currentBook%');\n const scopeChapterText = localizeString(localizedStrings, '%webView_inventory_scope_chapter%');\n const scopeVerseText = localizeString(localizedStrings, '%webView_inventory_scope_verse%');\n const filterText = localizeString(localizedStrings, '%webView_inventory_filter_text%');\n const showAdditionalItemsText = localizeString(\n localizedStrings,\n '%webView_inventory_show_additional_items%',\n );\n\n const [showAdditionalItems, setShowAdditionalItems] = useState(false);\n const [statusFilter, setStatusFilter] = useState('all');\n const [textFilter, setTextFilter] = useState('');\n const [selectedItem, setSelectedItem] = useState([]);\n\n const tableData: InventoryTableData[] = useMemo(() => {\n if (!text) return [];\n if (extractItems instanceof RegExp)\n return createTableData(\n text,\n scriptureReference,\n approvedItems,\n unapprovedItems,\n extractItems,\n );\n return extractItems(text, scriptureReference, approvedItems, unapprovedItems);\n }, [text, extractItems, scriptureReference, approvedItems, unapprovedItems]);\n\n const reducedTableData: InventoryTableData[] = useMemo(() => {\n if (showAdditionalItems) return tableData;\n\n const newTableData: InventoryTableData[] = [];\n\n tableData.forEach((tableEntry) => {\n const firstItem = tableEntry.items[0];\n\n const existingEntry = newTableData.find(\n (newTableEntry) => newTableEntry.items[0] === firstItem,\n );\n\n if (existingEntry) {\n existingEntry.count += tableEntry.count;\n existingEntry.occurrences = existingEntry.occurrences.concat(tableEntry.occurrences);\n } else {\n newTableData.push({\n items: [firstItem],\n count: tableEntry.count,\n occurrences: tableEntry.occurrences,\n status: tableEntry.status,\n });\n }\n });\n\n return newTableData;\n }, [showAdditionalItems, tableData]);\n\n const filteredTableData: InventoryTableData[] = useMemo(() => {\n return filterItemData(reducedTableData, statusFilter, textFilter);\n }, [reducedTableData, statusFilter, textFilter]);\n\n const allColumns: ColumnDef[] = useMemo(() => {\n if (!showAdditionalItems) return columns;\n\n const numberOfAdditionalItems = additionalItemsLabels?.tableHeaders?.length;\n if (!numberOfAdditionalItems) return columns;\n\n const additionalColumns: ColumnDef[] = [];\n\n for (let index = 0; index < numberOfAdditionalItems; index++) {\n additionalColumns.push(\n inventoryAdditionalItemColumn(\n additionalItemsLabels?.tableHeaders?.[index] || 'Additional Item',\n index + 1,\n ),\n );\n }\n\n return [...additionalColumns, ...columns];\n }, [additionalItemsLabels?.tableHeaders, columns, showAdditionalItems]);\n\n useEffect(() => {\n setSelectedItem([]);\n }, [filteredTableData]);\n\n const rowClickHandler = (\n row: RowContents,\n table: TableContents,\n ) => {\n table.setRowSelection(() => {\n const newSelection: RowSelectionState = {};\n newSelection[row.index] = true;\n return newSelection;\n });\n\n setSelectedItem(row.original.items);\n };\n\n const handleScopeChange = (value: string) => {\n if (value === 'book' || value === 'chapter' || value === 'verse') {\n onScopeChange(value);\n } else {\n throw new Error(`Invalid scope value: ${value}`);\n }\n };\n\n const handleStatusFilterChange = (value: string) => {\n if (value === 'all' || value === 'approved' || value === 'unapproved' || value === 'unknown') {\n setStatusFilter(value);\n } else {\n throw new Error(`Invalid status filter value: ${value}`);\n }\n };\n\n const occurrenceData: InventoryItemOccurrence[] = useMemo(() => {\n if (reducedTableData.length === 0 || selectedItem.length === 0) return [];\n const occurrence = reducedTableData.filter((tableEntry: InventoryTableData) => {\n return deepEqual(\n showAdditionalItems ? tableEntry.items : [tableEntry.items[0]],\n selectedItem,\n );\n });\n if (occurrence.length > 1) throw new Error('Selected item is not unique');\n return occurrence[0].occurrences;\n }, [selectedItem, showAdditionalItems, reducedTableData]);\n\n return (\n
    \n
    \n handleStatusFilterChange(value)}\n defaultValue={statusFilter}\n >\n \n \n \n \n {allItemsText}\n {approvedItemsText}\n {unapprovedItemsText}\n {unknownItemsText}\n \n \n \n {\n setTextFilter(event.target.value);\n }}\n />\n {additionalItemsLabels && (\n
    \n {\n setSelectedItem([]);\n setShowAdditionalItems(checked);\n }}\n />\n \n
    \n )}\n
    \n
    \n \n
    \n {occurrenceData.length > 0 && (\n
    \n \n
    \n )}\n
    \n );\n}\n","import { Input } from '@/components/shadcn-ui/input';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { useState } from 'react';\n\nexport type SearchBarProps = {\n className?: string;\n /**\n * Callback fired to handle the search query when button pressed\n *\n * @param searchQuery\n */\n onSearch: (searchQuery: string) => void;\n\n /** Optional string that appears in the search bar without a search string */\n placeholder?: string;\n\n /** Optional boolean to set the input base to full width */\n isFullWidth?: boolean;\n};\n\nexport default function SearchBar({\n className,\n onSearch,\n placeholder,\n isFullWidth,\n}: SearchBarProps) {\n const [searchQuery, setSearchQuery] = useState('');\n\n const handleInputChange = (searchString: string) => {\n setSearchQuery(searchString);\n onSearch(searchString);\n };\n\n return (\n handleInputChange(e.target.value)}\n />\n );\n}\n","// adapted from: https://github.com/shadcn-ui/ui/discussions/752\n\n'use client';\n\nimport { TabsContentProps, TabsListProps, TabsTriggerProps } from '@/components/shadcn-ui/tabs';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport * as TabsPrimitive from '@radix-ui/react-tabs';\nimport React from 'react';\n\nexport type VerticalTabsProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport type LeftTabsTriggerProps = TabsTriggerProps & {\n value: string;\n ref?: React.Ref;\n};\n\nexport const VerticalTabs = React.forwardRef<\n React.ElementRef,\n VerticalTabsProps\n>(({ className, ...props }, ref) => (\n \n));\n\nVerticalTabs.displayName = TabsPrimitive.List.displayName;\n\nexport const VerticalTabsList = React.forwardRef<\n React.ElementRef,\n TabsListProps\n>(({ className, ...props }, ref) => (\n \n));\nVerticalTabsList.displayName = TabsPrimitive.List.displayName;\n\nexport const VerticalTabsTrigger = React.forwardRef<\n React.ElementRef,\n LeftTabsTriggerProps\n>(({ className, ...props }, ref) => (\n \n));\n\nexport const VerticalTabsContent = React.forwardRef<\n React.ElementRef,\n TabsContentProps\n>(({ className, ...props }, ref) => (\n \n));\nVerticalTabsContent.displayName = TabsPrimitive.Content.displayName;\n","import SearchBar from '@/components/basics/search-bar.component';\nimport {\n VerticalTabs,\n VerticalTabsContent,\n VerticalTabsList,\n VerticalTabsTrigger,\n} from '@/components/basics/tabs-vertical';\nimport { ReactNode } from 'react';\n\nexport type TabKeyValueContent = {\n key: string;\n value: string;\n content: ReactNode;\n};\n\nexport type TabNavigationContentSearchProps = {\n /** List of values and keys for each tab this component should provide */\n tabList: TabKeyValueContent[];\n\n /** Handler to run when the value of the search bar changes */\n onSearch: (searchQuery: string) => void;\n\n /** Optional placeholder for the search bar */\n searchPlaceholder?: string;\n\n /** Optional title to include in the header */\n headerTitle?: string;\n\n /** Optional flag to make the search bar appear full width */\n isSearchBarFullWidth?: boolean;\n\n /** Text direction ltr or rtl */\n direction?: 'ltr' | 'rtl';\n};\n\nexport default function TabNavigationContentSearch({\n tabList,\n onSearch,\n searchPlaceholder,\n headerTitle,\n isSearchBarFullWidth = false,\n direction = 'ltr',\n}: TabNavigationContentSearchProps) {\n return (\n
    \n
    \n {headerTitle ?

    {headerTitle}

    : ''}\n \n
    \n \n \n {tabList.map((tab) => (\n \n {tab.value}\n \n ))}\n \n {tabList.map((tab) => (\n \n {tab.content}\n \n ))}\n \n
    \n );\n}\n","import React from 'react';\nimport * as SeparatorPrimitive from '@radix-ui/react-separator';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Separator = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, orientation = 'horizontal', decorative = true, ...props }, ref) => (\n \n));\nSeparator.displayName = SeparatorPrimitive.Root.displayName;\n\nexport { Separator };\n","'use client';\n\nimport * as React from 'react';\nimport * as SheetPrimitive from '@radix-ui/react-dialog';\nimport { cva, type VariantProps } from 'class-variance-authority';\nimport { X } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Sheet = SheetPrimitive.Root;\n\nconst SheetTrigger = SheetPrimitive.Trigger;\n\nconst SheetClose = SheetPrimitive.Close;\n\nconst SheetPortal = SheetPrimitive.Portal;\n\nconst SheetOverlay = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSheetOverlay.displayName = SheetPrimitive.Overlay.displayName;\n\nconst sheetVariants = cva(\n 'pr-twp tw-fixed tw-z-50 tw-gap-4 tw-bg-background tw-p-6 tw-shadow-lg tw-transition tw-ease-in-out data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-duration-300 data-[state=open]:tw-duration-500',\n {\n variants: {\n side: {\n top: 'tw-inset-x-0 tw-top-0 tw-border-b data-[state=closed]:tw-slide-out-to-top data-[state=open]:tw-slide-in-from-top',\n bottom:\n 'tw-inset-x-0 tw-bottom-0 tw-border-t data-[state=closed]:tw-slide-out-to-bottom data-[state=open]:tw-slide-in-from-bottom',\n left: 'tw-inset-y-0 tw-left-0 tw-h-full tw-w-3/4 tw-border-r data-[state=closed]:tw-slide-out-to-left data-[state=open]:tw-slide-in-from-left sm:tw-max-w-sm',\n right:\n 'tw-inset-y-0 tw-right-0 tw-h-full tw-w-3/4 tw- tw-border-l data-[state=closed]:tw-slide-out-to-right data-[state=open]:tw-slide-in-from-right sm:tw-max-w-sm',\n },\n },\n defaultVariants: {\n side: 'right',\n },\n },\n);\n\ninterface SheetContentProps\n extends React.ComponentPropsWithoutRef,\n VariantProps {}\n\nconst SheetContent = React.forwardRef<\n React.ElementRef,\n SheetContentProps\n>(({ side = 'right', className, children, ...props }, ref) => (\n \n \n \n {children}\n \n \n Close\n \n \n \n));\nSheetContent.displayName = SheetPrimitive.Content.displayName;\n\nfunction SheetHeader({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nSheetHeader.displayName = 'SheetHeader';\n\nfunction SheetFooter({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nSheetFooter.displayName = 'SheetFooter';\n\nconst SheetTitle = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSheetTitle.displayName = SheetPrimitive.Title.displayName;\n\nconst SheetDescription = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSheetDescription.displayName = SheetPrimitive.Description.displayName;\n\nexport {\n Sheet,\n SheetPortal,\n SheetOverlay,\n SheetTrigger,\n SheetClose,\n SheetContent,\n SheetHeader,\n SheetFooter,\n SheetTitle,\n SheetDescription,\n};\n","import React from 'react';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nfunction Skeleton({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\n\nexport { Skeleton };\n","import React from 'react';\nimport * as TooltipPrimitive from '@radix-ui/react-tooltip';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst TooltipProvider = TooltipPrimitive.Provider;\n\nconst Tooltip = TooltipPrimitive.Root;\n\nconst TooltipTrigger = TooltipPrimitive.Trigger;\n\nconst TooltipContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, sideOffset = 4, ...props }, ref) => (\n \n));\nTooltipContent.displayName = TooltipPrimitive.Content.displayName;\n\nexport { Tooltip, TooltipTrigger, TooltipContent, TooltipProvider };\n","import * as React from 'react';\n\nconst MOBILE_BREAKPOINT = 768;\n\nexport default function useIsMobile() {\n const [isMobile, setIsMobile] = React.useState(undefined);\n\n React.useEffect(() => {\n const mql = window.matchMedia(`(max-width: ${MOBILE_BREAKPOINT - 1}px)`);\n const onChange = () => {\n setIsMobile(window.innerWidth < MOBILE_BREAKPOINT);\n };\n mql.addEventListener('change', onChange);\n setIsMobile(window.innerWidth < MOBILE_BREAKPOINT);\n return () => mql.removeEventListener('change', onChange);\n }, []);\n\n return !!isMobile;\n}\n","import React from 'react';\nimport { Slot } from '@radix-ui/react-slot';\nimport { VariantProps, cva } from 'class-variance-authority';\nimport { PanelLeft } from 'lucide-react';\n\nimport { Button } from '@/components/shadcn-ui/button';\nimport { Input } from '@/components/shadcn-ui/input';\nimport { Separator } from '@/components/shadcn-ui/separator';\nimport { Sheet, SheetContent } from '@/components/shadcn-ui/sheet';\nimport { Skeleton } from '@/components/shadcn-ui/skeleton';\nimport {\n Tooltip,\n TooltipContent,\n TooltipProvider,\n TooltipTrigger,\n} from '@/components/shadcn-ui/tooltip';\nimport useIsMobile from '@/components/hooks/use-mobile';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst SIDEBAR_COOKIE_NAME = 'sidebar:state';\nconst SIDEBAR_COOKIE_MAX_AGE = 60 * 60 * 24 * 7;\nconst SIDEBAR_WIDTH = '16rem';\nconst SIDEBAR_WIDTH_MOBILE = '18rem';\nconst SIDEBAR_WIDTH_ICON = '3rem';\nconst SIDEBAR_KEYBOARD_SHORTCUT = 'b';\n\ntype SidebarContextProps = {\n state: 'expanded' | 'collapsed';\n open: boolean;\n setOpen: (open: boolean) => void;\n openMobile: boolean;\n setOpenMobile: (open: boolean) => void;\n isMobile: boolean;\n toggleSidebar: () => void;\n};\n\nconst SidebarContext = React.createContext(undefined);\n\nfunction useSidebar() {\n const context = React.useContext(SidebarContext);\n if (!context) {\n throw new Error('useSidebar must be used within a SidebarProvider.');\n }\n\n return context;\n}\n\nconst SidebarProvider = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & {\n defaultOpen?: boolean;\n open?: boolean;\n onOpenChange?: (open: boolean) => void;\n }\n>(\n (\n {\n defaultOpen = true,\n open: openProp,\n onOpenChange: setOpenProp,\n className,\n style,\n children,\n ...props\n },\n ref,\n ) => {\n const isMobile = useIsMobile();\n const [openMobile, setOpenMobile] = React.useState(false);\n\n // This is the internal state of the sidebar.\n // We use openProp and setOpenProp for control from outside the component.\n const [_open, _setOpen] = React.useState(defaultOpen);\n const isOpen = openProp ?? _open;\n const setOpen = React.useCallback(\n (value: boolean | ((value: boolean) => boolean)) => {\n const openState = typeof value === 'function' ? value(isOpen) : value;\n if (setOpenProp) {\n setOpenProp(openState);\n } else {\n _setOpen(openState);\n }\n\n // This sets the cookie to keep the sidebar state.\n document.cookie = `${SIDEBAR_COOKIE_NAME}=${openState}; path=/; max-age=${SIDEBAR_COOKIE_MAX_AGE}`;\n },\n [setOpenProp, isOpen],\n );\n\n // Helper to toggle the sidebar.\n const toggleSidebar = React.useCallback(() => {\n return isMobile ? setOpenMobile((open) => !open) : setOpen((open) => !open);\n }, [isMobile, setOpen, setOpenMobile]);\n\n // Adds a keyboard shortcut to toggle the sidebar.\n React.useEffect(() => {\n const handleKeyDown = (event: KeyboardEvent) => {\n if (event.key === SIDEBAR_KEYBOARD_SHORTCUT && (event.metaKey || event.ctrlKey)) {\n event.preventDefault();\n toggleSidebar();\n }\n };\n\n window.addEventListener('keydown', handleKeyDown);\n return () => window.removeEventListener('keydown', handleKeyDown);\n }, [toggleSidebar]);\n\n // We add a state so that we can do data-state=\"expanded\" or \"collapsed\".\n // This makes it easier to style the sidebar with Tailwind classes.\n const state = isOpen ? 'expanded' : 'collapsed';\n\n const contextValue = React.useMemo(\n () => ({\n state,\n open: isOpen,\n setOpen,\n isMobile,\n openMobile,\n setOpenMobile,\n toggleSidebar,\n }),\n [state, isOpen, setOpen, isMobile, openMobile, setOpenMobile, toggleSidebar],\n );\n\n return (\n \n \n \n {children}\n
    \n \n \n );\n },\n);\nSidebarProvider.displayName = 'SidebarProvider';\n\nconst Sidebar = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & {\n side?: 'left' | 'right';\n variant?: 'sidebar' | 'floating' | 'inset';\n collapsible?: 'offcanvas' | 'icon' | 'none';\n }\n>(\n (\n {\n side = 'left',\n variant = 'sidebar',\n collapsible = 'offcanvas',\n className,\n children,\n ...props\n },\n ref,\n ) => {\n const { isMobile, state, openMobile, setOpenMobile } = useSidebar();\n\n if (collapsible === 'none') {\n return (\n \n {children}\n
    \n );\n }\n\n if (isMobile) {\n return (\n \n button]:tw-hidden\"\n style={\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n {\n '--sidebar-width': SIDEBAR_WIDTH_MOBILE,\n } as React.CSSProperties\n }\n side={side}\n >\n
    {children}
    \n \n
    \n );\n }\n\n return (\n \n {/* This is what handles the sidebar gap on desktop */}\n \n \n \n {children}\n
    \n
    \n
    \n );\n },\n);\nSidebar.displayName = 'Sidebar';\n\nconst SidebarTrigger = React.forwardRef<\n React.ElementRef,\n React.ComponentProps\n>(({ className, onClick, ...props }, ref) => {\n const { toggleSidebar } = useSidebar();\n\n return (\n {\n onClick?.(event);\n toggleSidebar();\n }}\n {...props}\n >\n \n Toggle Sidebar\n \n );\n});\nSidebarTrigger.displayName = 'SidebarTrigger';\n\nconst SidebarRail = React.forwardRef>(\n ({ className, ...props }, ref) => {\n const { toggleSidebar } = useSidebar();\n\n return (\n \n );\n },\n);\nSidebarRail.displayName = 'SidebarRail';\n\nconst SidebarInset = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarInset.displayName = 'SidebarInset';\n\nconst SidebarInput = React.forwardRef<\n React.ElementRef,\n React.ComponentProps\n>(({ className, ...props }, ref) => {\n return (\n \n );\n});\nSidebarInput.displayName = 'SidebarInput';\n\nconst SidebarHeader = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarHeader.displayName = 'SidebarHeader';\n\nconst SidebarFooter = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarFooter.displayName = 'SidebarFooter';\n\nconst SidebarSeparator = React.forwardRef<\n React.ElementRef,\n React.ComponentProps\n>(({ className, ...props }, ref) => {\n return (\n \n );\n});\nSidebarSeparator.displayName = 'SidebarSeparator';\n\nconst SidebarContent = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarContent.displayName = 'SidebarContent';\n\nconst SidebarGroup = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarGroup.displayName = 'SidebarGroup';\n\nconst SidebarGroupLabel = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & { asChild?: boolean }\n>(({ className, asChild = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'div';\n\n return (\n svg]:tw-size-4 [&>svg]:tw-shrink-0',\n 'group-data-[collapsible=icon]:tw--mt-8 group-data-[collapsible=icon]:tw-opacity-0',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarGroupLabel.displayName = 'SidebarGroupLabel';\n\nconst SidebarGroupAction = React.forwardRef<\n HTMLButtonElement,\n React.ComponentProps<'button'> & { asChild?: boolean }\n>(({ className, asChild = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'button';\n\n return (\n svg]:tw-size-4 [&>svg]:tw-shrink-0',\n // Increases the hit area of the button on mobile.\n 'after:tw-absolute after:tw--inset-2 after:md:tw-hidden',\n 'group-data-[collapsible=icon]:tw-hidden',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarGroupAction.displayName = 'SidebarGroupAction';\n\nconst SidebarGroupContent = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarGroupContent.displayName = 'SidebarGroupContent';\n\nconst SidebarMenu = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenu.displayName = 'SidebarMenu';\n\nconst SidebarMenuItem = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenuItem.displayName = 'SidebarMenuItem';\n\nconst sidebarMenuButtonVariants = cva(\n // Removed data-[active=true]:tw-bg-sidebar-accent\n 'tw-peer/menu-button tw-flex tw-w-full tw-items-center tw-gap-2 tw-overflow-hidden tw-rounded-md tw-p-2 tw-text-left tw-text-sm tw-outline-none tw-ring-sidebar-ring tw-transition-[width,height,padding] hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground focus-visible:tw-ring-2 active:tw-bg-sidebar-accent active:tw-text-sidebar-accent-foreground disabled:tw-pointer-events-none disabled:tw-opacity-50 tw-group-has-[[data-sidebar=menu-action]]/menu-item:pr-8 aria-disabled:tw-pointer-events-none aria-disabled:tw-opacity-50 data-[active=true]:tw-font-medium data-[active=true]:tw-text-sidebar-accent-foreground data-[state=open]:hover:tw-bg-sidebar-accent data-[state=open]:hover:tw-text-sidebar-accent-foreground group-data-[collapsible=icon]:tw-!size-8 group-data-[collapsible=icon]:tw-!p-2 [&>span:last-child]:tw-truncate [&>svg]:tw-size-4 [&>svg]:tw-shrink-0',\n {\n variants: {\n variant: {\n default: 'hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground',\n outline:\n 'tw-bg-background tw-shadow-[0_0_0_1px_hsl(var(--sidebar-border))] hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground hover:tw-shadow-[0_0_0_1px_hsl(var(--sidebar-accent))]',\n },\n size: {\n default: 'tw-h-8 tw-text-sm',\n sm: 'tw-h-7 tw-text-xs',\n lg: 'tw-h-12 tw-text-sm group-data-[collapsible=icon]:tw-!p-0',\n },\n },\n defaultVariants: {\n variant: 'default',\n size: 'default',\n },\n },\n);\n\nconst SidebarMenuButton = React.forwardRef<\n HTMLButtonElement,\n React.ComponentProps<'button'> & {\n asChild?: boolean;\n isActive?: boolean;\n tooltip?: string | React.ComponentProps;\n } & VariantProps\n>(\n (\n {\n asChild = false,\n isActive = false,\n variant = 'default',\n size = 'default',\n tooltip,\n className,\n ...props\n },\n ref,\n ) => {\n const Comp = asChild ? Slot : 'button';\n const { isMobile, state } = useSidebar();\n\n const button = (\n \n );\n\n if (!tooltip) {\n return button;\n }\n\n if (typeof tooltip === 'string') {\n // eslint-disable-next-line no-param-reassign\n tooltip = {\n children: tooltip,\n };\n }\n\n return (\n \n {button}\n \n );\n },\n);\nSidebarMenuButton.displayName = 'SidebarMenuButton';\n\nconst SidebarMenuAction = React.forwardRef<\n HTMLButtonElement,\n React.ComponentProps<'button'> & {\n asChild?: boolean;\n showOnHover?: boolean;\n }\n>(({ className, asChild = false, showOnHover = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'button';\n\n return (\n svg]:tw-size-4 [&>svg]:tw-shrink-0',\n // Increases the hit area of the button on mobile.\n 'after:tw-absolute after:tw--inset-2 after:md:tw-hidden',\n 'tw-peer-data-[size=sm]/menu-button:top-1',\n 'tw-peer-data-[size=default]/menu-button:top-1.5',\n 'tw-peer-data-[size=lg]/menu-button:top-2.5',\n 'group-data-[collapsible=icon]:tw-hidden',\n showOnHover &&\n 'tw-group-focus-within/menu-item:opacity-100 tw-group-hover/menu-item:opacity-100 tw-peer-data-[active=true]/menu-button:text-sidebar-accent-foreground data-[state=open]:tw-opacity-100 md:tw-opacity-0',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarMenuAction.displayName = 'SidebarMenuAction';\n\nconst SidebarMenuBadge = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenuBadge.displayName = 'SidebarMenuBadge';\n\nconst SidebarMenuSkeleton = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & {\n showIcon?: boolean;\n }\n>(({ className, showIcon = false, ...props }, ref) => {\n // Random width between 50 to 90%.\n const width = React.useMemo(() => {\n return `${Math.floor(Math.random() * 40) + 50}%`;\n }, []);\n\n return (\n \n {showIcon && (\n \n )}\n \n
    \n );\n});\nSidebarMenuSkeleton.displayName = 'SidebarMenuSkeleton';\n\nconst SidebarMenuSub = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenuSub.displayName = 'SidebarMenuSub';\n\nconst SidebarMenuSubItem = React.forwardRef>(\n ({ ...props }, ref) =>
  • ,\n);\nSidebarMenuSubItem.displayName = 'SidebarMenuSubItem';\n\nconst SidebarMenuSubButton = React.forwardRef<\n HTMLAnchorElement,\n React.ComponentProps<'a'> & {\n asChild?: boolean;\n size?: 'sm' | 'md';\n isActive?: boolean;\n }\n>(({ asChild = false, size = 'md', isActive, className, ...props }, ref) => {\n const Comp = asChild ? Slot : 'a';\n\n return (\n span:last-child]:tw-truncate [&>svg]:tw-size-4 [&>svg]:tw-shrink-0 [&>svg]:tw-text-sidebar-accent-foreground',\n 'data-[active=true]:tw-bg-sidebar-accent data-[active=true]:tw-text-sidebar-accent-foreground',\n size === 'sm' && 'tw-text-xs',\n size === 'md' && 'tw-text-sm',\n 'group-data-[collapsible=icon]:tw-hidden',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarMenuSubButton.displayName = 'SidebarMenuSubButton';\n\nexport {\n Sidebar,\n SidebarContent,\n SidebarFooter,\n SidebarGroup,\n SidebarGroupAction,\n SidebarGroupContent,\n SidebarGroupLabel,\n SidebarHeader,\n SidebarInput,\n SidebarInset,\n SidebarMenu,\n SidebarMenuAction,\n SidebarMenuBadge,\n SidebarMenuButton,\n SidebarMenuItem,\n SidebarMenuSkeleton,\n SidebarMenuSub,\n SidebarMenuSubButton,\n SidebarMenuSubItem,\n SidebarProvider,\n SidebarRail,\n SidebarSeparator,\n SidebarTrigger,\n useSidebar,\n};\n","import ComboBox, { ComboBoxOption } from '@/components/basics/combo-box.component';\nimport {\n Sidebar,\n SidebarContent,\n SidebarGroup,\n SidebarGroupLabel,\n SidebarGroupContent,\n SidebarMenu,\n SidebarMenuItem,\n SidebarMenuButton,\n} from '@/components/shadcn-ui/sidebar';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { useCallback } from 'react';\n\nexport type SelectedSettingsSidebarItem = {\n label: string;\n projectId?: string;\n};\n\nexport type ProjectOptions = { projectId: string; projectName: string };\n\nexport type SettingsSidebarProps = {\n /** Optional id for testing */\n id?: string;\n\n /** Extension labels from contribution */\n extensionLabels: string[];\n\n /** Project names and ids */\n projectOptions: ProjectOptions[];\n\n /** Handler for selecting a sidebar item */\n handleSelectSidebarItem: (key: string, projectId?: string) => void;\n\n /** The current selected value in the sidebar */\n selectedSidebarItem: SelectedSettingsSidebarItem;\n};\n\nexport default function SettingsSidebar({\n id,\n extensionLabels,\n projectOptions,\n handleSelectSidebarItem,\n selectedSidebarItem,\n}: SettingsSidebarProps) {\n const handleSelectItem = useCallback(\n (item: string, projectId?: string) => {\n handleSelectSidebarItem(item, projectId);\n },\n [handleSelectSidebarItem],\n );\n\n const getProjectNameFromProjectId = useCallback(\n (projectId: string) => {\n const project = projectOptions.find((option) => option.projectId === projectId);\n return project ? project.projectName : projectId;\n },\n [projectOptions],\n );\n\n const getIsActive: (label: string) => boolean = useCallback(\n (label: string) => !selectedSidebarItem.projectId && label === selectedSidebarItem.label,\n [selectedSidebarItem],\n );\n\n return (\n \n \n \n Extensions\n \n \n {extensionLabels.map((label) => (\n \n handleSelectItem(label, undefined)}\n isActive={getIsActive(label)}\n >\n {label}\n \n \n ))}\n \n \n \n \n Projects\n \n option.projectId)}\n getOptionLabel={(projectId: ComboBoxOption) => {\n // This function expects a ComboBoxOption, but we know it is a string\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n return getProjectNameFromProjectId(projectId as string);\n }}\n buttonPlaceholder=\"Type or select project\"\n onChange={(projectId: string) => {\n const selectedProjectName = getProjectNameFromProjectId(projectId);\n handleSelectItem(selectedProjectName, projectId);\n }}\n value={selectedSidebarItem?.projectId ?? undefined}\n />\n \n \n \n \n );\n}\n","import { SidebarInset, SidebarProvider } from '@/components/shadcn-ui/sidebar';\nimport { PropsWithChildren } from 'react';\nimport SearchBar from '@/components/basics/search-bar.component';\nimport SettingsSidebar, { SettingsSidebarProps } from './settings-sidebar.component';\n\nexport type SettingsSidebarContentSearchProps = SettingsSidebarProps &\n PropsWithChildren & {\n /** Optional id for testing */\n id?: string;\n\n /** Text direction ltr or rtl */\n direction?: 'ltr' | 'rtl';\n\n /** Handler to run when the value of the search bar changes */\n onSearch: (searchQuery: string) => void;\n };\n\nexport default function SettingsSidebarContentSearch({\n id,\n direction = 'ltr',\n extensionLabels,\n projectOptions,\n children,\n handleSelectSidebarItem,\n selectedSidebarItem,\n onSearch,\n}: SettingsSidebarContentSearchProps) {\n return (\n
    \n
    \n \n
    \n \n \n {children}\n \n
    \n );\n}\n","import { Button } from '@/components/shadcn-ui/button';\nimport {\n Select,\n SelectContent,\n SelectGroup,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\nimport {\n Table,\n TableBody,\n TableCell,\n TableHead,\n TableHeader,\n TableRow,\n} from '@/components/shadcn-ui/table';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Canon } from '@sillsdev/scripture';\nimport {\n Cell,\n ColumnDef,\n flexRender,\n getCoreRowModel,\n getExpandedRowModel,\n getGroupedRowModel,\n getSortedRowModel,\n GroupingState,\n Row,\n RowSelectionState,\n SortingState,\n useReactTable,\n} from '@tanstack/react-table';\nimport '@/components/advanced/scripture-results-viewer/scripture-results-viewer.component.css';\nimport {\n compareScrRefs,\n formatScrRef,\n ScriptureSelection,\n scrRefToBBBCCCVVV,\n} from 'platform-bible-utils';\nimport { MouseEvent, useEffect, useMemo, useState } from 'react';\nimport { ChevronDown, ChevronLeft, ChevronRight } from 'lucide-react';\n\n/**\n * Information (e.g., a checking error or some other type of \"transient\" annotation) about something\n * noteworthy at a specific place in an instance of the Scriptures.\n */\nexport type ScriptureItemDetail = ScriptureSelection & {\n /**\n * Text of the error, note, etc. In the future, we might want to support something more than just\n * text so that a JSX element could be provided with a link or some other controls related to the\n * issue being reported.\n */\n detail: string;\n};\n\n/**\n * A uniquely identifiable source of results that can be displayed in the ScriptureResultsViewer.\n * Generally, the source will be a particular Scripture check, but there may be other types of\n * sources.\n */\nexport type ResultsSource = {\n /**\n * Uniquely identifies the source.\n *\n * @type {string}\n */\n id: string;\n\n /**\n * Name (potentially localized) of the source, suitable for display in the UI.\n *\n * @type {string}\n */\n displayName: string;\n};\n\nexport type ScriptureSrcItemDetail = ScriptureItemDetail & {\n /** Source/type of detail. Can be used for grouping. */\n source: ResultsSource;\n};\n\n/**\n * Represents a set of results keyed by Scripture reference. Generally, the source will be a\n * particular Scripture check, but this type also allows for other types of uniquely identifiable\n * sources.\n */\nexport type ResultsSet = {\n /**\n * The backing source associated with this set of results.\n *\n * @type {ResultsSource}\n */\n source: ResultsSource;\n\n /**\n * Array of Scripture item details (messages keyed by Scripture reference).\n *\n * @type {ScriptureItemDetail[]}\n */\n data: ScriptureItemDetail[];\n};\n\nconst scrBookColId = 'scrBook';\nconst scrRefColId = 'scrRef';\nconst typeColId = 'source';\nconst detailsColId = 'details';\n\nconst defaultScrRefColumnName = 'Scripture Reference';\nconst defaultScrBookGroupName = 'Scripture Book';\nconst defaultTypeColumnName = 'Type';\nconst defaultDetailsColumnName = 'Details';\n\nexport type ScriptureResultsViewerColumnInfo = {\n /** Optional header to display for the Reference column. Default value: 'Scripture Reference'. */\n scriptureReferenceColumnName?: string;\n\n /** Optional text to display to refer to the Scripture book group. Default value: 'Scripture Book'. */\n scriptureBookGroupName?: string;\n\n /** Optional header to display for the Type column. Default value: 'Type'. */\n typeColumnName?: string;\n\n /** Optional header to display for the Details column. Default value: 'Details' */\n detailsColumnName?: string;\n};\n\nexport type ScriptureResultsViewerProps = ScriptureResultsViewerColumnInfo & {\n /** Groups of ScriptureItemDetail objects from particular sources (e.g., Scripture checks) */\n sources: ResultsSet[];\n\n /** Flag indicating whether to display column headers. Default is false. */\n showColumnHeaders?: boolean;\n\n /** Flag indicating whether to display source column. Default is false. */\n showSourceColumn?: boolean;\n\n /** Callback function to notify when a row is selected */\n onRowSelected?: (selectedRow: ScriptureSrcItemDetail | undefined) => void;\n\n /** Text direction ltr or rtl */\n direction?: 'ltr' | 'rtl';\n};\n\nfunction getColumns(\n colInfo?: ScriptureResultsViewerColumnInfo,\n showSourceColumn?: boolean,\n): ColumnDef[] {\n const showSrcCol = showSourceColumn ?? false;\n return [\n {\n accessorFn: (row) =>\n `${Canon.bookNumberToId(row.start.bookNum)} ${row.start.chapterNum}:${row.start.verseNum}`,\n id: scrBookColId,\n header: colInfo?.scriptureReferenceColumnName ?? defaultScrRefColumnName,\n cell: (info) => {\n const row = info.row.original;\n if (info.row.getIsGrouped()) {\n return Canon.bookNumberToEnglishName(row.start.bookNum);\n }\n return info.row.groupingColumnId === scrBookColId ? formatScrRef(row.start) : undefined;\n },\n getGroupingValue: (row) => row.start.bookNum,\n sortingFn: (a, b) => {\n return compareScrRefs(a.original.start, b.original.start);\n },\n enableGrouping: true,\n },\n {\n accessorFn: (row) => formatScrRef(row.start),\n id: scrRefColId,\n header: undefined,\n cell: (info) => {\n const row = info.row.original;\n return info.row.getIsGrouped() ? undefined : formatScrRef(row.start);\n },\n sortingFn: (a, b) => {\n return compareScrRefs(a.original.start, b.original.start);\n },\n enableGrouping: false,\n },\n {\n accessorFn: (row) => row.source.displayName,\n id: typeColId,\n header: showSrcCol ? (colInfo?.typeColumnName ?? defaultTypeColumnName) : undefined,\n cell: (info) => (showSrcCol || info.row.getIsGrouped() ? info.getValue() : undefined),\n getGroupingValue: (row) => row.source.id,\n sortingFn: (a, b) =>\n a.original.source.displayName.localeCompare(b.original.source.displayName),\n enableGrouping: true,\n },\n {\n accessorFn: (row) => row.detail,\n id: detailsColId,\n header: colInfo?.detailsColumnName ?? defaultDetailsColumnName,\n cell: (info) => info.getValue(),\n enableGrouping: false,\n },\n ];\n}\n\nconst toRefOrRange = (scriptureSelection: ScriptureSelection) => {\n if (!('offset' in scriptureSelection.start))\n throw new Error('No offset available in range start');\n if (scriptureSelection.end && !('offset' in scriptureSelection.end))\n throw new Error('No offset available in range end');\n const { offset: offsetStart } = scriptureSelection.start;\n let offsetEnd: number = 0;\n if (scriptureSelection.end) ({ offset: offsetEnd } = scriptureSelection.end);\n if (\n !scriptureSelection.end ||\n compareScrRefs(scriptureSelection.start, scriptureSelection.end) === 0\n )\n return `${scrRefToBBBCCCVVV(scriptureSelection.start)}+${offsetStart}`;\n return `${scrRefToBBBCCCVVV(scriptureSelection.start)}+${offsetStart}-${scrRefToBBBCCCVVV(scriptureSelection.end)}+${offsetEnd}`;\n};\n\nconst getRowKey = (row: ScriptureSrcItemDetail) =>\n `${toRefOrRange({ start: row.start, end: row.end })} ${row.source.displayName} ${row.detail}`;\n\n/**\n * Component to display a combined list of detailed items from one or more sources, where the items\n * are keyed primarily by Scripture reference. This is particularly useful for displaying a list of\n * results from Scripture checks, but more generally could be used to display any \"results\" from any\n * source(s). The component allows for grouping by Scripture book, source, or both. By default, it\n * displays somewhat \"tree-like\" which allows it to be more horizontally compact and intuitive. But\n * it also has the option of displaying as a traditional table with column headings (with or without\n * the source column showing).\n */\nexport default function ScriptureResultsViewer({\n sources,\n showColumnHeaders = false,\n showSourceColumn = false,\n scriptureReferenceColumnName,\n scriptureBookGroupName,\n typeColumnName,\n detailsColumnName,\n onRowSelected,\n direction = 'ltr',\n}: ScriptureResultsViewerProps) {\n const [grouping, setGrouping] = useState([]);\n const [sorting, setSorting] = useState([{ id: scrBookColId, desc: false }]);\n const [rowSelection, setRowSelection] = useState({});\n\n const scriptureResults = useMemo(\n () =>\n sources.flatMap((source) => {\n return source.data.map((item) => ({\n ...item,\n source: source.source,\n }));\n }),\n [sources],\n );\n\n const columns = useMemo(\n () =>\n getColumns(\n {\n scriptureReferenceColumnName,\n typeColumnName,\n detailsColumnName,\n },\n showSourceColumn,\n ),\n [scriptureReferenceColumnName, typeColumnName, detailsColumnName, showSourceColumn],\n );\n\n useEffect(() => {\n // Ensure sorting is applied correctly when grouped by type\n if (grouping.includes(typeColId)) {\n setSorting([\n { id: typeColId, desc: false },\n { id: scrBookColId, desc: false },\n ]);\n } else {\n setSorting([{ id: scrBookColId, desc: false }]);\n }\n }, [grouping]);\n\n const table = useReactTable({\n data: scriptureResults,\n columns,\n state: {\n grouping,\n sorting,\n rowSelection,\n },\n onGroupingChange: setGrouping,\n onSortingChange: setSorting,\n onRowSelectionChange: setRowSelection,\n getExpandedRowModel: getExpandedRowModel(),\n getGroupedRowModel: getGroupedRowModel(),\n getCoreRowModel: getCoreRowModel(),\n getSortedRowModel: getSortedRowModel(),\n getRowId: getRowKey,\n autoResetExpanded: false,\n enableMultiRowSelection: false,\n enableSubRowSelection: false,\n });\n\n useEffect(() => {\n if (onRowSelected) {\n const selectedRows = table.getSelectedRowModel().rowsById;\n const keys = Object.keys(selectedRows);\n if (keys.length === 1) {\n const selectedRow = scriptureResults.find((row) => getRowKey(row) === keys[0]) || undefined;\n if (selectedRow) onRowSelected(selectedRow);\n }\n }\n }, [rowSelection, scriptureResults, onRowSelected, table]);\n\n // Define possible grouping options\n const scrBookGroupName = scriptureBookGroupName ?? defaultScrBookGroupName;\n const typeGroupName = typeColumnName ?? defaultTypeColumnName;\n\n const groupingOptions = [\n { label: 'No Grouping', value: [] },\n { label: `Group by ${scrBookGroupName}`, value: [scrBookColId] },\n { label: `Group by ${typeGroupName}`, value: [typeColId] },\n {\n label: `Group by ${scrBookGroupName} and ${typeGroupName}`,\n value: [scrBookColId, typeColId],\n },\n {\n label: `Group by ${typeGroupName} and ${scrBookGroupName}`,\n value: [typeColId, scrBookColId],\n },\n ];\n\n const handleSelectChange = (selectedGrouping: string) => {\n setGrouping(JSON.parse(selectedGrouping));\n };\n\n const handleRowClick = (row: Row, event: MouseEvent) => {\n if (!row.getIsGrouped() && !row.getIsSelected()) {\n row.getToggleSelectedHandler()(event);\n }\n };\n\n const getEvenOrOddBandingStyle = (row: Row, index: number) => {\n if (row.getIsGrouped()) return '';\n // UX has now said they don't think they want banding. I'm leaving in the code to\n // set even and odd styles, but there's nothing in the CSS to style them differently.\n // The \"even\" style used to also have tw-bg-neutral-300 (along with even) to create\n // a visual banding effect. That could be added back in if UX changes the decision.\n return cn('banded-row', index % 2 === 0 ? 'even' : 'odd');\n };\n\n const getIndent = (\n groupingState: GroupingState,\n row: Row,\n cell: Cell,\n ) => {\n if (groupingState?.length === 0 || row.depth < cell.column.getGroupedIndex()) return undefined;\n if (row.getIsGrouped()) {\n switch (row.depth) {\n case 1:\n return 'tw-ps-4';\n default:\n return undefined;\n }\n }\n switch (row.depth) {\n case 1:\n return 'tw-ps-8';\n case 2:\n return 'tw-ps-12';\n default:\n return undefined;\n }\n };\n\n return (\n
    \n {!showColumnHeaders && (\n {\n handleSelectChange(value);\n }}\n >\n \n \n \n \n \n {groupingOptions.map((option) => (\n \n {option.label}\n \n ))}\n \n \n \n )}\n \n {showColumnHeaders && (\n \n {table.getHeaderGroups().map((headerGroup) => (\n \n {headerGroup.headers\n .filter((h) => h.column.columnDef.header)\n .map((header) => (\n /* For sticky column headers to work, we probably need to change the default definition of the shadcn Table component. See https://github.com/shadcn-ui/ui/issues/1151 */\n \n {header.isPlaceholder ? undefined : (\n
    \n {header.column.getCanGroup() ? (\n \n {header.column.getIsGrouped() ? `🛑` : `👊 `}\n \n ) : undefined}{' '}\n {flexRender(header.column.columnDef.header, header.getContext())}\n
    \n )}\n
    \n ))}\n
    \n ))}\n
    \n )}\n \n {table.getRowModel().rows.map((row, rowIndex) => {\n return (\n handleRowClick(row, event)}\n >\n {row.getVisibleCells().map((cell) => {\n if (\n cell.getIsPlaceholder() ||\n (cell.column.columnDef.enableGrouping &&\n !cell.getIsGrouped() &&\n (cell.column.columnDef.id !== typeColId || !showSourceColumn))\n )\n return undefined;\n return (\n \n {(() => {\n if (cell.getIsGrouped()) {\n return (\n \n {row.getIsExpanded() && }\n {!row.getIsExpanded() &&\n (direction === 'ltr' ? : )}{' '}\n {flexRender(cell.column.columnDef.cell, cell.getContext())} (\n {row.subRows.length})\n \n );\n }\n\n // if (cell.getIsAggregated()) {\n // flexRender(\n // cell.column.columnDef.aggregatedCell ?? cell.column.columnDef.cell,\n // cell.getContext(),\n // );\n // }\n\n return flexRender(cell.column.columnDef.cell, cell.getContext());\n })()}\n \n );\n })}\n \n );\n })}\n \n
    \n
    \n );\n}\n","import {\n getLocalizeKeyForScrollGroupId,\n LanguageStrings,\n ScrollGroupId,\n} from 'platform-bible-utils';\nimport {\n Select,\n SelectContent,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\n\nconst DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS = {\n [getLocalizeKeyForScrollGroupId('undefined')]: 'Ø',\n [getLocalizeKeyForScrollGroupId(0)]: 'A',\n [getLocalizeKeyForScrollGroupId(1)]: 'B',\n [getLocalizeKeyForScrollGroupId(2)]: 'C',\n [getLocalizeKeyForScrollGroupId(3)]: 'D',\n [getLocalizeKeyForScrollGroupId(4)]: 'E',\n [getLocalizeKeyForScrollGroupId(5)]: 'F',\n [getLocalizeKeyForScrollGroupId(6)]: 'G',\n [getLocalizeKeyForScrollGroupId(7)]: 'H',\n [getLocalizeKeyForScrollGroupId(8)]: 'I',\n [getLocalizeKeyForScrollGroupId(9)]: 'J',\n [getLocalizeKeyForScrollGroupId(10)]: 'K',\n [getLocalizeKeyForScrollGroupId(11)]: 'L',\n [getLocalizeKeyForScrollGroupId(12)]: 'M',\n [getLocalizeKeyForScrollGroupId(13)]: 'N',\n [getLocalizeKeyForScrollGroupId(14)]: 'O',\n [getLocalizeKeyForScrollGroupId(15)]: 'P',\n [getLocalizeKeyForScrollGroupId(16)]: 'Q',\n [getLocalizeKeyForScrollGroupId(17)]: 'R',\n [getLocalizeKeyForScrollGroupId(18)]: 'S',\n [getLocalizeKeyForScrollGroupId(19)]: 'T',\n [getLocalizeKeyForScrollGroupId(20)]: 'U',\n [getLocalizeKeyForScrollGroupId(21)]: 'V',\n [getLocalizeKeyForScrollGroupId(22)]: 'W',\n [getLocalizeKeyForScrollGroupId(23)]: 'X',\n [getLocalizeKeyForScrollGroupId(24)]: 'Y',\n [getLocalizeKeyForScrollGroupId(25)]: 'Z',\n};\n\nexport type ScrollGroupSelectorProps = {\n /**\n * List of scroll group ids to show to the user. Either a {@link ScrollGroupId} or `undefined` for\n * no scroll group\n */\n availableScrollGroupIds: (ScrollGroupId | undefined)[];\n /** Currently selected scroll group id. `undefined` for no scroll group */\n scrollGroupId: ScrollGroupId | undefined;\n /** Callback function run when the user tries to change the scroll group id */\n onChangeScrollGroupId: (newScrollGroupId: ScrollGroupId | undefined) => void;\n /**\n * Localized strings to use for displaying scroll group ids. Must be an object whose keys are\n * `getLocalizeKeyForScrollGroupId(scrollGroupId)` for all scroll group ids (and `undefined` if\n * included) in {@link ScrollGroupSelectorProps.availableScrollGroupIds} and whose values are the\n * localized strings to use for those scroll group ids.\n *\n * Defaults to English localizations of English alphabet for scroll groups 0-25 (e.g. 0 is A) and\n * Ø for `undefined`. Will fill in any that are not provided with these English localizations.\n * Also, if any values match the keys, the English localization will be used. This is useful in\n * case you want to pass in a temporary version of the localized strings while your localized\n * strings load.\n *\n * @example\n *\n * ```typescript\n * const myScrollGroupIdLocalizedStrings = {\n * [getLocalizeKeyForScrollGroupId('undefined')]: 'Ø',\n * [getLocalizeKeyForScrollGroupId(0)]: 'A',\n * [getLocalizeKeyForScrollGroupId(1)]: 'B',\n * [getLocalizeKeyForScrollGroupId(2)]: 'C',\n * [getLocalizeKeyForScrollGroupId(3)]: 'D',\n * [getLocalizeKeyForScrollGroupId(4)]: 'E',\n * };\n * ```\n *\n * @example\n *\n * ```tsx\n * const availableScrollGroupIds = [undefined, 0, 1, 2, 3, 4];\n *\n * const localizeKeys = getLocalizeKeysForScrollGroupIds();\n *\n * const [localizedStrings] = useLocalizedStrings(localizeKeys);\n *\n * ...\n *\n * \n * ```\n */\n localizedStrings?: LanguageStrings;\n};\n\n/** Selector component for choosing a scroll group */\nexport default function ScrollGroupSelector({\n availableScrollGroupIds,\n scrollGroupId,\n onChangeScrollGroupId,\n localizedStrings = {},\n}: ScrollGroupSelectorProps) {\n const localizedStringsDefaulted = {\n ...DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS,\n ...Object.fromEntries(\n Object.entries(localizedStrings).map(\n ([localizedStringKey, localizedStringValue]: [string, string]) => [\n localizedStringKey,\n localizedStringKey === localizedStringValue &&\n localizedStringKey in DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS\n ? DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS[localizedStringKey]\n : localizedStringValue,\n ],\n ),\n ),\n };\n return (\n \n onChangeScrollGroupId(\n newScrollGroupString === 'undefined' ? undefined : parseInt(newScrollGroupString, 10),\n )\n }\n >\n \n \n \n \n {availableScrollGroupIds.map((scrollGroupOptionId) => (\n \n {localizedStringsDefaulted[getLocalizeKeyForScrollGroupId(scrollGroupOptionId)]}\n \n ))}\n \n \n );\n}\n","import { PropsWithChildren } from 'react';\nimport { Separator } from '@/components/shadcn-ui/separator';\n\n/** Props for the SettingsList component, currently just children */\ntype SettingsListProps = PropsWithChildren;\n\n/**\n * SettingsList component is a wrapper for list items. Rendered with a formatted div\n *\n * @param children To populate the list with\n * @returns Formatted div encompassing the children\n */\nexport function SettingsList({ children }: SettingsListProps) {\n return
    {children}
    ;\n}\n\n/** Props for SettingsListItem component */\ntype SettingsListItemProps = PropsWithChildren & {\n /** Primary text of the list item */\n primary: string;\n\n /** Optional text of the list item */\n secondary?: string | undefined;\n\n /** Optional boolean to display a message if the children aren't loaded yet. Defaults to false */\n isLoading?: boolean;\n\n /** Optional message to display if isLoading */\n loadingMessage?: string;\n};\n\n/**\n * SettingsListItem component is a common list item. Rendered with a formatted div\n *\n * @param primary Primary text of the list item\n * @param secondary Optional secondary text of the list item\n * @param isLoading Optional, to display a message if the action component isn't generated yet,\n * defaults to false\n * @param children The action component(s) to provide for this item\n * @param loadingMessage Optional, message to display if isLoading\n * @returns Formatted div encompassing the list item content\n */\nexport function SettingsListItem({\n primary,\n secondary,\n children,\n isLoading = false,\n loadingMessage,\n}: SettingsListItemProps) {\n return (\n
    \n
    \n

    {primary}

    \n

    \n {secondary}\n

    \n
    \n\n {isLoading ? (\n

    {loadingMessage}

    \n ) : (\n
    {children}
    \n )}\n
    \n );\n}\n\n/** Props for SettingsListHeader component */\ntype SettingsListHeaderProps = {\n /** The primary text of the list header */\n primary: string;\n\n /** Optional secondary text of the list header */\n secondary?: string | undefined;\n\n /** Optional boolean to include a separator underneath the secondary text. Defaults to false */\n includeSeparator?: boolean;\n};\n\n/**\n * SettingsListHeader component displays text above the list\n *\n * @param primary The primary text of the list header\n * @param secondary Optional secondary text of the list header\n * @param includeSeparator Optional boolean to include a separator underneath the secondary text.\n * Defaults to false\n * @returns Formatted div with list header content\n */\nexport function SettingsListHeader({\n primary,\n secondary,\n includeSeparator = false,\n}: SettingsListHeaderProps) {\n return (\n
    \n
    \n

    {primary}

    \n

    {secondary}

    \n
    \n {includeSeparator ? : ''}\n
    \n );\n}\n","import Checkbox from '@/components/shadcn-ui/checkbox';\nimport { Label } from '@/components/shadcn-ui/label';\n\nexport type ChecklistProps = {\n /** Optional string representing the id attribute of the Checklist */\n id?: string;\n /** Optional string representing CSS class name(s) for styling */\n className?: string;\n /** Array of strings representing the checkable items */\n listItems: string[];\n /** Array of strings representing the checked items */\n selectedListItems: string[];\n /**\n * Function that is called when a checkbox item is selected or deselected\n *\n * @param item The string description for this item\n * @param selected True if selected, false if not selected\n */\n handleSelectListItem: (item: string, selected: boolean) => void;\n\n /**\n * Optional function creates a label for a provided checkable item\n *\n * @param item The item for which a label is to be created\n * @returns A string representing the label text for the checkbox associated with that item\n */\n createLabel?: (item: string) => string;\n};\n\n/** Renders a list of checkboxes. Each checkbox corresponds to an item from the `listItems` array. */\nexport default function Checklist({\n id,\n className,\n listItems,\n selectedListItems,\n handleSelectListItem,\n createLabel,\n}: ChecklistProps) {\n return (\n
    \n {listItems.map((item) => (\n
    \n handleSelectListItem(item, value)}\n />\n \n
    \n ))}\n
    \n );\n}\n","function _interopRequireDefault(obj) {\n return obj && obj.__esModule ? obj : {\n \"default\": obj\n };\n}\nmodule.exports = _interopRequireDefault, module.exports.__esModule = true, module.exports[\"default\"] = module.exports;","export default function chainPropTypes(propType1, propType2) {\n if (process.env.NODE_ENV === 'production') {\n return () => null;\n }\n return function validate(...args) {\n return propType1(...args) || propType2(...args);\n };\n}","export default function _extends() {\n _extends = Object.assign ? Object.assign.bind() : function (target) {\n for (var i = 1; i < arguments.length; i++) {\n var source = arguments[i];\n for (var key in source) {\n if (Object.prototype.hasOwnProperty.call(source, key)) {\n target[key] = source[key];\n }\n }\n }\n return target;\n };\n return _extends.apply(this, arguments);\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\n// https://github.com/sindresorhus/is-plain-obj/blob/main/index.js\nexport function isPlainObject(item) {\n if (typeof item !== 'object' || item === null) {\n return false;\n }\n const prototype = Object.getPrototypeOf(item);\n return (prototype === null || prototype === Object.prototype || Object.getPrototypeOf(prototype) === null) && !(Symbol.toStringTag in item) && !(Symbol.iterator in item);\n}\nfunction deepClone(source) {\n if (!isPlainObject(source)) {\n return source;\n }\n const output = {};\n Object.keys(source).forEach(key => {\n output[key] = deepClone(source[key]);\n });\n return output;\n}\nexport default function deepmerge(target, source, options = {\n clone: true\n}) {\n const output = options.clone ? _extends({}, target) : target;\n if (isPlainObject(target) && isPlainObject(source)) {\n Object.keys(source).forEach(key => {\n // Avoid prototype pollution\n if (key === '__proto__') {\n return;\n }\n if (isPlainObject(source[key]) && key in target && isPlainObject(target[key])) {\n // Since `output` is a clone of `target` and we have narrowed `target` in this block we can cast to the same type.\n output[key] = deepmerge(target[key], source[key], options);\n } else if (options.clone) {\n output[key] = isPlainObject(source[key]) ? deepClone(source[key]) : source[key];\n } else {\n output[key] = source[key];\n }\n });\n }\n return output;\n}","/** @license React v16.13.1\n * react-is.production.min.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';var b=\"function\"===typeof Symbol&&Symbol.for,c=b?Symbol.for(\"react.element\"):60103,d=b?Symbol.for(\"react.portal\"):60106,e=b?Symbol.for(\"react.fragment\"):60107,f=b?Symbol.for(\"react.strict_mode\"):60108,g=b?Symbol.for(\"react.profiler\"):60114,h=b?Symbol.for(\"react.provider\"):60109,k=b?Symbol.for(\"react.context\"):60110,l=b?Symbol.for(\"react.async_mode\"):60111,m=b?Symbol.for(\"react.concurrent_mode\"):60111,n=b?Symbol.for(\"react.forward_ref\"):60112,p=b?Symbol.for(\"react.suspense\"):60113,q=b?\nSymbol.for(\"react.suspense_list\"):60120,r=b?Symbol.for(\"react.memo\"):60115,t=b?Symbol.for(\"react.lazy\"):60116,v=b?Symbol.for(\"react.block\"):60121,w=b?Symbol.for(\"react.fundamental\"):60117,x=b?Symbol.for(\"react.responder\"):60118,y=b?Symbol.for(\"react.scope\"):60119;\nfunction z(a){if(\"object\"===typeof a&&null!==a){var u=a.$$typeof;switch(u){case c:switch(a=a.type,a){case l:case m:case e:case g:case f:case p:return a;default:switch(a=a&&a.$$typeof,a){case k:case n:case t:case r:case h:return a;default:return u}}case d:return u}}}function A(a){return z(a)===m}exports.AsyncMode=l;exports.ConcurrentMode=m;exports.ContextConsumer=k;exports.ContextProvider=h;exports.Element=c;exports.ForwardRef=n;exports.Fragment=e;exports.Lazy=t;exports.Memo=r;exports.Portal=d;\nexports.Profiler=g;exports.StrictMode=f;exports.Suspense=p;exports.isAsyncMode=function(a){return A(a)||z(a)===l};exports.isConcurrentMode=A;exports.isContextConsumer=function(a){return z(a)===k};exports.isContextProvider=function(a){return z(a)===h};exports.isElement=function(a){return\"object\"===typeof a&&null!==a&&a.$$typeof===c};exports.isForwardRef=function(a){return z(a)===n};exports.isFragment=function(a){return z(a)===e};exports.isLazy=function(a){return z(a)===t};\nexports.isMemo=function(a){return z(a)===r};exports.isPortal=function(a){return z(a)===d};exports.isProfiler=function(a){return z(a)===g};exports.isStrictMode=function(a){return z(a)===f};exports.isSuspense=function(a){return z(a)===p};\nexports.isValidElementType=function(a){return\"string\"===typeof a||\"function\"===typeof a||a===e||a===m||a===g||a===f||a===p||a===q||\"object\"===typeof a&&null!==a&&(a.$$typeof===t||a.$$typeof===r||a.$$typeof===h||a.$$typeof===k||a.$$typeof===n||a.$$typeof===w||a.$$typeof===x||a.$$typeof===y||a.$$typeof===v)};exports.typeOf=z;\n","/** @license React v16.13.1\n * react-is.development.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\n\n\nif (process.env.NODE_ENV !== \"production\") {\n (function() {\n'use strict';\n\n// The Symbol used to tag the ReactElement-like types. If there is no native Symbol\n// nor polyfill, then a plain number is used for performance.\nvar hasSymbol = typeof Symbol === 'function' && Symbol.for;\nvar REACT_ELEMENT_TYPE = hasSymbol ? Symbol.for('react.element') : 0xeac7;\nvar REACT_PORTAL_TYPE = hasSymbol ? Symbol.for('react.portal') : 0xeaca;\nvar REACT_FRAGMENT_TYPE = hasSymbol ? Symbol.for('react.fragment') : 0xeacb;\nvar REACT_STRICT_MODE_TYPE = hasSymbol ? Symbol.for('react.strict_mode') : 0xeacc;\nvar REACT_PROFILER_TYPE = hasSymbol ? Symbol.for('react.profiler') : 0xead2;\nvar REACT_PROVIDER_TYPE = hasSymbol ? Symbol.for('react.provider') : 0xeacd;\nvar REACT_CONTEXT_TYPE = hasSymbol ? Symbol.for('react.context') : 0xeace; // TODO: We don't use AsyncMode or ConcurrentMode anymore. They were temporary\n// (unstable) APIs that have been removed. Can we remove the symbols?\n\nvar REACT_ASYNC_MODE_TYPE = hasSymbol ? Symbol.for('react.async_mode') : 0xeacf;\nvar REACT_CONCURRENT_MODE_TYPE = hasSymbol ? Symbol.for('react.concurrent_mode') : 0xeacf;\nvar REACT_FORWARD_REF_TYPE = hasSymbol ? Symbol.for('react.forward_ref') : 0xead0;\nvar REACT_SUSPENSE_TYPE = hasSymbol ? Symbol.for('react.suspense') : 0xead1;\nvar REACT_SUSPENSE_LIST_TYPE = hasSymbol ? Symbol.for('react.suspense_list') : 0xead8;\nvar REACT_MEMO_TYPE = hasSymbol ? Symbol.for('react.memo') : 0xead3;\nvar REACT_LAZY_TYPE = hasSymbol ? Symbol.for('react.lazy') : 0xead4;\nvar REACT_BLOCK_TYPE = hasSymbol ? Symbol.for('react.block') : 0xead9;\nvar REACT_FUNDAMENTAL_TYPE = hasSymbol ? Symbol.for('react.fundamental') : 0xead5;\nvar REACT_RESPONDER_TYPE = hasSymbol ? Symbol.for('react.responder') : 0xead6;\nvar REACT_SCOPE_TYPE = hasSymbol ? Symbol.for('react.scope') : 0xead7;\n\nfunction isValidElementType(type) {\n return typeof type === 'string' || typeof type === 'function' || // Note: its typeof might be other than 'symbol' or 'number' if it's a polyfill.\n type === REACT_FRAGMENT_TYPE || type === REACT_CONCURRENT_MODE_TYPE || type === REACT_PROFILER_TYPE || type === REACT_STRICT_MODE_TYPE || type === REACT_SUSPENSE_TYPE || type === REACT_SUSPENSE_LIST_TYPE || typeof type === 'object' && type !== null && (type.$$typeof === REACT_LAZY_TYPE || type.$$typeof === REACT_MEMO_TYPE || type.$$typeof === REACT_PROVIDER_TYPE || type.$$typeof === REACT_CONTEXT_TYPE || type.$$typeof === REACT_FORWARD_REF_TYPE || type.$$typeof === REACT_FUNDAMENTAL_TYPE || type.$$typeof === REACT_RESPONDER_TYPE || type.$$typeof === REACT_SCOPE_TYPE || type.$$typeof === REACT_BLOCK_TYPE);\n}\n\nfunction typeOf(object) {\n if (typeof object === 'object' && object !== null) {\n var $$typeof = object.$$typeof;\n\n switch ($$typeof) {\n case REACT_ELEMENT_TYPE:\n var type = object.type;\n\n switch (type) {\n case REACT_ASYNC_MODE_TYPE:\n case REACT_CONCURRENT_MODE_TYPE:\n case REACT_FRAGMENT_TYPE:\n case REACT_PROFILER_TYPE:\n case REACT_STRICT_MODE_TYPE:\n case REACT_SUSPENSE_TYPE:\n return type;\n\n default:\n var $$typeofType = type && type.$$typeof;\n\n switch ($$typeofType) {\n case REACT_CONTEXT_TYPE:\n case REACT_FORWARD_REF_TYPE:\n case REACT_LAZY_TYPE:\n case REACT_MEMO_TYPE:\n case REACT_PROVIDER_TYPE:\n return $$typeofType;\n\n default:\n return $$typeof;\n }\n\n }\n\n case REACT_PORTAL_TYPE:\n return $$typeof;\n }\n }\n\n return undefined;\n} // AsyncMode is deprecated along with isAsyncMode\n\nvar AsyncMode = REACT_ASYNC_MODE_TYPE;\nvar ConcurrentMode = REACT_CONCURRENT_MODE_TYPE;\nvar ContextConsumer = REACT_CONTEXT_TYPE;\nvar ContextProvider = REACT_PROVIDER_TYPE;\nvar Element = REACT_ELEMENT_TYPE;\nvar ForwardRef = REACT_FORWARD_REF_TYPE;\nvar Fragment = REACT_FRAGMENT_TYPE;\nvar Lazy = REACT_LAZY_TYPE;\nvar Memo = REACT_MEMO_TYPE;\nvar Portal = REACT_PORTAL_TYPE;\nvar Profiler = REACT_PROFILER_TYPE;\nvar StrictMode = REACT_STRICT_MODE_TYPE;\nvar Suspense = REACT_SUSPENSE_TYPE;\nvar hasWarnedAboutDeprecatedIsAsyncMode = false; // AsyncMode should be deprecated\n\nfunction isAsyncMode(object) {\n {\n if (!hasWarnedAboutDeprecatedIsAsyncMode) {\n hasWarnedAboutDeprecatedIsAsyncMode = true; // Using console['warn'] to evade Babel and ESLint\n\n console['warn']('The ReactIs.isAsyncMode() alias has been deprecated, ' + 'and will be removed in React 17+. Update your code to use ' + 'ReactIs.isConcurrentMode() instead. It has the exact same API.');\n }\n }\n\n return isConcurrentMode(object) || typeOf(object) === REACT_ASYNC_MODE_TYPE;\n}\nfunction isConcurrentMode(object) {\n return typeOf(object) === REACT_CONCURRENT_MODE_TYPE;\n}\nfunction isContextConsumer(object) {\n return typeOf(object) === REACT_CONTEXT_TYPE;\n}\nfunction isContextProvider(object) {\n return typeOf(object) === REACT_PROVIDER_TYPE;\n}\nfunction isElement(object) {\n return typeof object === 'object' && object !== null && object.$$typeof === REACT_ELEMENT_TYPE;\n}\nfunction isForwardRef(object) {\n return typeOf(object) === REACT_FORWARD_REF_TYPE;\n}\nfunction isFragment(object) {\n return typeOf(object) === REACT_FRAGMENT_TYPE;\n}\nfunction isLazy(object) {\n return typeOf(object) === REACT_LAZY_TYPE;\n}\nfunction isMemo(object) {\n return typeOf(object) === REACT_MEMO_TYPE;\n}\nfunction isPortal(object) {\n return typeOf(object) === REACT_PORTAL_TYPE;\n}\nfunction isProfiler(object) {\n return typeOf(object) === REACT_PROFILER_TYPE;\n}\nfunction isStrictMode(object) {\n return typeOf(object) === REACT_STRICT_MODE_TYPE;\n}\nfunction isSuspense(object) {\n return typeOf(object) === REACT_SUSPENSE_TYPE;\n}\n\nexports.AsyncMode = AsyncMode;\nexports.ConcurrentMode = ConcurrentMode;\nexports.ContextConsumer = ContextConsumer;\nexports.ContextProvider = ContextProvider;\nexports.Element = Element;\nexports.ForwardRef = ForwardRef;\nexports.Fragment = Fragment;\nexports.Lazy = Lazy;\nexports.Memo = Memo;\nexports.Portal = Portal;\nexports.Profiler = Profiler;\nexports.StrictMode = StrictMode;\nexports.Suspense = Suspense;\nexports.isAsyncMode = isAsyncMode;\nexports.isConcurrentMode = isConcurrentMode;\nexports.isContextConsumer = isContextConsumer;\nexports.isContextProvider = isContextProvider;\nexports.isElement = isElement;\nexports.isForwardRef = isForwardRef;\nexports.isFragment = isFragment;\nexports.isLazy = isLazy;\nexports.isMemo = isMemo;\nexports.isPortal = isPortal;\nexports.isProfiler = isProfiler;\nexports.isStrictMode = isStrictMode;\nexports.isSuspense = isSuspense;\nexports.isValidElementType = isValidElementType;\nexports.typeOf = typeOf;\n })();\n}\n","'use strict';\n\nif (process.env.NODE_ENV === 'production') {\n module.exports = require('./cjs/react-is.production.min.js');\n} else {\n module.exports = require('./cjs/react-is.development.js');\n}\n","/*\nobject-assign\n(c) Sindre Sorhus\n@license MIT\n*/\n\n'use strict';\n/* eslint-disable no-unused-vars */\nvar getOwnPropertySymbols = Object.getOwnPropertySymbols;\nvar hasOwnProperty = Object.prototype.hasOwnProperty;\nvar propIsEnumerable = Object.prototype.propertyIsEnumerable;\n\nfunction toObject(val) {\n\tif (val === null || val === undefined) {\n\t\tthrow new TypeError('Object.assign cannot be called with null or undefined');\n\t}\n\n\treturn Object(val);\n}\n\nfunction shouldUseNative() {\n\ttry {\n\t\tif (!Object.assign) {\n\t\t\treturn false;\n\t\t}\n\n\t\t// Detect buggy property enumeration order in older V8 versions.\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=4118\n\t\tvar test1 = new String('abc'); // eslint-disable-line no-new-wrappers\n\t\ttest1[5] = 'de';\n\t\tif (Object.getOwnPropertyNames(test1)[0] === '5') {\n\t\t\treturn false;\n\t\t}\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=3056\n\t\tvar test2 = {};\n\t\tfor (var i = 0; i < 10; i++) {\n\t\t\ttest2['_' + String.fromCharCode(i)] = i;\n\t\t}\n\t\tvar order2 = Object.getOwnPropertyNames(test2).map(function (n) {\n\t\t\treturn test2[n];\n\t\t});\n\t\tif (order2.join('') !== '0123456789') {\n\t\t\treturn false;\n\t\t}\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=3056\n\t\tvar test3 = {};\n\t\t'abcdefghijklmnopqrst'.split('').forEach(function (letter) {\n\t\t\ttest3[letter] = letter;\n\t\t});\n\t\tif (Object.keys(Object.assign({}, test3)).join('') !==\n\t\t\t\t'abcdefghijklmnopqrst') {\n\t\t\treturn false;\n\t\t}\n\n\t\treturn true;\n\t} catch (err) {\n\t\t// We don't expect any of the above to throw, but better to be safe.\n\t\treturn false;\n\t}\n}\n\nmodule.exports = shouldUseNative() ? Object.assign : function (target, source) {\n\tvar from;\n\tvar to = toObject(target);\n\tvar symbols;\n\n\tfor (var s = 1; s < arguments.length; s++) {\n\t\tfrom = Object(arguments[s]);\n\n\t\tfor (var key in from) {\n\t\t\tif (hasOwnProperty.call(from, key)) {\n\t\t\t\tto[key] = from[key];\n\t\t\t}\n\t\t}\n\n\t\tif (getOwnPropertySymbols) {\n\t\t\tsymbols = getOwnPropertySymbols(from);\n\t\t\tfor (var i = 0; i < symbols.length; i++) {\n\t\t\t\tif (propIsEnumerable.call(from, symbols[i])) {\n\t\t\t\t\tto[symbols[i]] = from[symbols[i]];\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\n\treturn to;\n};\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar ReactPropTypesSecret = 'SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED';\n\nmodule.exports = ReactPropTypesSecret;\n","module.exports = Function.call.bind(Object.prototype.hasOwnProperty);\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar printWarning = function() {};\n\nif (process.env.NODE_ENV !== 'production') {\n var ReactPropTypesSecret = require('./lib/ReactPropTypesSecret');\n var loggedTypeFailures = {};\n var has = require('./lib/has');\n\n printWarning = function(text) {\n var message = 'Warning: ' + text;\n if (typeof console !== 'undefined') {\n console.error(message);\n }\n try {\n // --- Welcome to debugging React ---\n // This error was thrown as a convenience so that you can use this stack\n // to find the callsite that caused this warning to fire.\n throw new Error(message);\n } catch (x) { /**/ }\n };\n}\n\n/**\n * Assert that the values match with the type specs.\n * Error messages are memorized and will only be shown once.\n *\n * @param {object} typeSpecs Map of name to a ReactPropType\n * @param {object} values Runtime values that need to be type-checked\n * @param {string} location e.g. \"prop\", \"context\", \"child context\"\n * @param {string} componentName Name of the component for error messages.\n * @param {?Function} getStack Returns the component stack.\n * @private\n */\nfunction checkPropTypes(typeSpecs, values, location, componentName, getStack) {\n if (process.env.NODE_ENV !== 'production') {\n for (var typeSpecName in typeSpecs) {\n if (has(typeSpecs, typeSpecName)) {\n var error;\n // Prop type validation may throw. In case they do, we don't want to\n // fail the render phase where it didn't fail before. So we log it.\n // After these have been cleaned up, we'll let them throw.\n try {\n // This is intentionally an invariant that gets caught. It's the same\n // behavior as without this statement except with a better message.\n if (typeof typeSpecs[typeSpecName] !== 'function') {\n var err = Error(\n (componentName || 'React class') + ': ' + location + ' type `' + typeSpecName + '` is invalid; ' +\n 'it must be a function, usually from the `prop-types` package, but received `' + typeof typeSpecs[typeSpecName] + '`.' +\n 'This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.'\n );\n err.name = 'Invariant Violation';\n throw err;\n }\n error = typeSpecs[typeSpecName](values, typeSpecName, componentName, location, null, ReactPropTypesSecret);\n } catch (ex) {\n error = ex;\n }\n if (error && !(error instanceof Error)) {\n printWarning(\n (componentName || 'React class') + ': type specification of ' +\n location + ' `' + typeSpecName + '` is invalid; the type checker ' +\n 'function must return `null` or an `Error` but returned a ' + typeof error + '. ' +\n 'You may have forgotten to pass an argument to the type checker ' +\n 'creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and ' +\n 'shape all require an argument).'\n );\n }\n if (error instanceof Error && !(error.message in loggedTypeFailures)) {\n // Only monitor this failure once because there tends to be a lot of the\n // same error.\n loggedTypeFailures[error.message] = true;\n\n var stack = getStack ? getStack() : '';\n\n printWarning(\n 'Failed ' + location + ' type: ' + error.message + (stack != null ? stack : '')\n );\n }\n }\n }\n }\n}\n\n/**\n * Resets warning cache when testing.\n *\n * @private\n */\ncheckPropTypes.resetWarningCache = function() {\n if (process.env.NODE_ENV !== 'production') {\n loggedTypeFailures = {};\n }\n}\n\nmodule.exports = checkPropTypes;\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar ReactIs = require('react-is');\nvar assign = require('object-assign');\n\nvar ReactPropTypesSecret = require('./lib/ReactPropTypesSecret');\nvar has = require('./lib/has');\nvar checkPropTypes = require('./checkPropTypes');\n\nvar printWarning = function() {};\n\nif (process.env.NODE_ENV !== 'production') {\n printWarning = function(text) {\n var message = 'Warning: ' + text;\n if (typeof console !== 'undefined') {\n console.error(message);\n }\n try {\n // --- Welcome to debugging React ---\n // This error was thrown as a convenience so that you can use this stack\n // to find the callsite that caused this warning to fire.\n throw new Error(message);\n } catch (x) {}\n };\n}\n\nfunction emptyFunctionThatReturnsNull() {\n return null;\n}\n\nmodule.exports = function(isValidElement, throwOnDirectAccess) {\n /* global Symbol */\n var ITERATOR_SYMBOL = typeof Symbol === 'function' && Symbol.iterator;\n var FAUX_ITERATOR_SYMBOL = '@@iterator'; // Before Symbol spec.\n\n /**\n * Returns the iterator method function contained on the iterable object.\n *\n * Be sure to invoke the function with the iterable as context:\n *\n * var iteratorFn = getIteratorFn(myIterable);\n * if (iteratorFn) {\n * var iterator = iteratorFn.call(myIterable);\n * ...\n * }\n *\n * @param {?object} maybeIterable\n * @return {?function}\n */\n function getIteratorFn(maybeIterable) {\n var iteratorFn = maybeIterable && (ITERATOR_SYMBOL && maybeIterable[ITERATOR_SYMBOL] || maybeIterable[FAUX_ITERATOR_SYMBOL]);\n if (typeof iteratorFn === 'function') {\n return iteratorFn;\n }\n }\n\n /**\n * Collection of methods that allow declaration and validation of props that are\n * supplied to React components. Example usage:\n *\n * var Props = require('ReactPropTypes');\n * var MyArticle = React.createClass({\n * propTypes: {\n * // An optional string prop named \"description\".\n * description: Props.string,\n *\n * // A required enum prop named \"category\".\n * category: Props.oneOf(['News','Photos']).isRequired,\n *\n * // A prop named \"dialog\" that requires an instance of Dialog.\n * dialog: Props.instanceOf(Dialog).isRequired\n * },\n * render: function() { ... }\n * });\n *\n * A more formal specification of how these methods are used:\n *\n * type := array|bool|func|object|number|string|oneOf([...])|instanceOf(...)\n * decl := ReactPropTypes.{type}(.isRequired)?\n *\n * Each and every declaration produces a function with the same signature. This\n * allows the creation of custom validation functions. For example:\n *\n * var MyLink = React.createClass({\n * propTypes: {\n * // An optional string or URI prop named \"href\".\n * href: function(props, propName, componentName) {\n * var propValue = props[propName];\n * if (propValue != null && typeof propValue !== 'string' &&\n * !(propValue instanceof URI)) {\n * return new Error(\n * 'Expected a string or an URI for ' + propName + ' in ' +\n * componentName\n * );\n * }\n * }\n * },\n * render: function() {...}\n * });\n *\n * @internal\n */\n\n var ANONYMOUS = '<>';\n\n // Important!\n // Keep this list in sync with production version in `./factoryWithThrowingShims.js`.\n var ReactPropTypes = {\n array: createPrimitiveTypeChecker('array'),\n bigint: createPrimitiveTypeChecker('bigint'),\n bool: createPrimitiveTypeChecker('boolean'),\n func: createPrimitiveTypeChecker('function'),\n number: createPrimitiveTypeChecker('number'),\n object: createPrimitiveTypeChecker('object'),\n string: createPrimitiveTypeChecker('string'),\n symbol: createPrimitiveTypeChecker('symbol'),\n\n any: createAnyTypeChecker(),\n arrayOf: createArrayOfTypeChecker,\n element: createElementTypeChecker(),\n elementType: createElementTypeTypeChecker(),\n instanceOf: createInstanceTypeChecker,\n node: createNodeChecker(),\n objectOf: createObjectOfTypeChecker,\n oneOf: createEnumTypeChecker,\n oneOfType: createUnionTypeChecker,\n shape: createShapeTypeChecker,\n exact: createStrictShapeTypeChecker,\n };\n\n /**\n * inlined Object.is polyfill to avoid requiring consumers ship their own\n * https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object/is\n */\n /*eslint-disable no-self-compare*/\n function is(x, y) {\n // SameValue algorithm\n if (x === y) {\n // Steps 1-5, 7-10\n // Steps 6.b-6.e: +0 != -0\n return x !== 0 || 1 / x === 1 / y;\n } else {\n // Step 6.a: NaN == NaN\n return x !== x && y !== y;\n }\n }\n /*eslint-enable no-self-compare*/\n\n /**\n * We use an Error-like object for backward compatibility as people may call\n * PropTypes directly and inspect their output. However, we don't use real\n * Errors anymore. We don't inspect their stack anyway, and creating them\n * is prohibitively expensive if they are created too often, such as what\n * happens in oneOfType() for any type before the one that matched.\n */\n function PropTypeError(message, data) {\n this.message = message;\n this.data = data && typeof data === 'object' ? data: {};\n this.stack = '';\n }\n // Make `instanceof Error` still work for returned errors.\n PropTypeError.prototype = Error.prototype;\n\n function createChainableTypeChecker(validate) {\n if (process.env.NODE_ENV !== 'production') {\n var manualPropTypeCallCache = {};\n var manualPropTypeWarningCount = 0;\n }\n function checkType(isRequired, props, propName, componentName, location, propFullName, secret) {\n componentName = componentName || ANONYMOUS;\n propFullName = propFullName || propName;\n\n if (secret !== ReactPropTypesSecret) {\n if (throwOnDirectAccess) {\n // New behavior only for users of `prop-types` package\n var err = new Error(\n 'Calling PropTypes validators directly is not supported by the `prop-types` package. ' +\n 'Use `PropTypes.checkPropTypes()` to call them. ' +\n 'Read more at http://fb.me/use-check-prop-types'\n );\n err.name = 'Invariant Violation';\n throw err;\n } else if (process.env.NODE_ENV !== 'production' && typeof console !== 'undefined') {\n // Old behavior for people using React.PropTypes\n var cacheKey = componentName + ':' + propName;\n if (\n !manualPropTypeCallCache[cacheKey] &&\n // Avoid spamming the console because they are often not actionable except for lib authors\n manualPropTypeWarningCount < 3\n ) {\n printWarning(\n 'You are manually calling a React.PropTypes validation ' +\n 'function for the `' + propFullName + '` prop on `' + componentName + '`. This is deprecated ' +\n 'and will throw in the standalone `prop-types` package. ' +\n 'You may be seeing this warning due to a third-party PropTypes ' +\n 'library. See https://fb.me/react-warning-dont-call-proptypes ' + 'for details.'\n );\n manualPropTypeCallCache[cacheKey] = true;\n manualPropTypeWarningCount++;\n }\n }\n }\n if (props[propName] == null) {\n if (isRequired) {\n if (props[propName] === null) {\n return new PropTypeError('The ' + location + ' `' + propFullName + '` is marked as required ' + ('in `' + componentName + '`, but its value is `null`.'));\n }\n return new PropTypeError('The ' + location + ' `' + propFullName + '` is marked as required in ' + ('`' + componentName + '`, but its value is `undefined`.'));\n }\n return null;\n } else {\n return validate(props, propName, componentName, location, propFullName);\n }\n }\n\n var chainedCheckType = checkType.bind(null, false);\n chainedCheckType.isRequired = checkType.bind(null, true);\n\n return chainedCheckType;\n }\n\n function createPrimitiveTypeChecker(expectedType) {\n function validate(props, propName, componentName, location, propFullName, secret) {\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== expectedType) {\n // `propValue` being instance of, say, date/regexp, pass the 'object'\n // check, but we can offer a more precise error message here rather than\n // 'of type `object`'.\n var preciseType = getPreciseType(propValue);\n\n return new PropTypeError(\n 'Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + preciseType + '` supplied to `' + componentName + '`, expected ') + ('`' + expectedType + '`.'),\n {expectedType: expectedType}\n );\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createAnyTypeChecker() {\n return createChainableTypeChecker(emptyFunctionThatReturnsNull);\n }\n\n function createArrayOfTypeChecker(typeChecker) {\n function validate(props, propName, componentName, location, propFullName) {\n if (typeof typeChecker !== 'function') {\n return new PropTypeError('Property `' + propFullName + '` of component `' + componentName + '` has invalid PropType notation inside arrayOf.');\n }\n var propValue = props[propName];\n if (!Array.isArray(propValue)) {\n var propType = getPropType(propValue);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected an array.'));\n }\n for (var i = 0; i < propValue.length; i++) {\n var error = typeChecker(propValue, i, componentName, location, propFullName + '[' + i + ']', ReactPropTypesSecret);\n if (error instanceof Error) {\n return error;\n }\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createElementTypeChecker() {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n if (!isValidElement(propValue)) {\n var propType = getPropType(propValue);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected a single ReactElement.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createElementTypeTypeChecker() {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n if (!ReactIs.isValidElementType(propValue)) {\n var propType = getPropType(propValue);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected a single ReactElement type.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createInstanceTypeChecker(expectedClass) {\n function validate(props, propName, componentName, location, propFullName) {\n if (!(props[propName] instanceof expectedClass)) {\n var expectedClassName = expectedClass.name || ANONYMOUS;\n var actualClassName = getClassName(props[propName]);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + actualClassName + '` supplied to `' + componentName + '`, expected ') + ('instance of `' + expectedClassName + '`.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createEnumTypeChecker(expectedValues) {\n if (!Array.isArray(expectedValues)) {\n if (process.env.NODE_ENV !== 'production') {\n if (arguments.length > 1) {\n printWarning(\n 'Invalid arguments supplied to oneOf, expected an array, got ' + arguments.length + ' arguments. ' +\n 'A common mistake is to write oneOf(x, y, z) instead of oneOf([x, y, z]).'\n );\n } else {\n printWarning('Invalid argument supplied to oneOf, expected an array.');\n }\n }\n return emptyFunctionThatReturnsNull;\n }\n\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n for (var i = 0; i < expectedValues.length; i++) {\n if (is(propValue, expectedValues[i])) {\n return null;\n }\n }\n\n var valuesString = JSON.stringify(expectedValues, function replacer(key, value) {\n var type = getPreciseType(value);\n if (type === 'symbol') {\n return String(value);\n }\n return value;\n });\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of value `' + String(propValue) + '` ' + ('supplied to `' + componentName + '`, expected one of ' + valuesString + '.'));\n }\n return createChainableTypeChecker(validate);\n }\n\n function createObjectOfTypeChecker(typeChecker) {\n function validate(props, propName, componentName, location, propFullName) {\n if (typeof typeChecker !== 'function') {\n return new PropTypeError('Property `' + propFullName + '` of component `' + componentName + '` has invalid PropType notation inside objectOf.');\n }\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== 'object') {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected an object.'));\n }\n for (var key in propValue) {\n if (has(propValue, key)) {\n var error = typeChecker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret);\n if (error instanceof Error) {\n return error;\n }\n }\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createUnionTypeChecker(arrayOfTypeCheckers) {\n if (!Array.isArray(arrayOfTypeCheckers)) {\n process.env.NODE_ENV !== 'production' ? printWarning('Invalid argument supplied to oneOfType, expected an instance of array.') : void 0;\n return emptyFunctionThatReturnsNull;\n }\n\n for (var i = 0; i < arrayOfTypeCheckers.length; i++) {\n var checker = arrayOfTypeCheckers[i];\n if (typeof checker !== 'function') {\n printWarning(\n 'Invalid argument supplied to oneOfType. Expected an array of check functions, but ' +\n 'received ' + getPostfixForTypeWarning(checker) + ' at index ' + i + '.'\n );\n return emptyFunctionThatReturnsNull;\n }\n }\n\n function validate(props, propName, componentName, location, propFullName) {\n var expectedTypes = [];\n for (var i = 0; i < arrayOfTypeCheckers.length; i++) {\n var checker = arrayOfTypeCheckers[i];\n var checkerResult = checker(props, propName, componentName, location, propFullName, ReactPropTypesSecret);\n if (checkerResult == null) {\n return null;\n }\n if (checkerResult.data && has(checkerResult.data, 'expectedType')) {\n expectedTypes.push(checkerResult.data.expectedType);\n }\n }\n var expectedTypesMessage = (expectedTypes.length > 0) ? ', expected one of type [' + expectedTypes.join(', ') + ']': '';\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` supplied to ' + ('`' + componentName + '`' + expectedTypesMessage + '.'));\n }\n return createChainableTypeChecker(validate);\n }\n\n function createNodeChecker() {\n function validate(props, propName, componentName, location, propFullName) {\n if (!isNode(props[propName])) {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` supplied to ' + ('`' + componentName + '`, expected a ReactNode.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function invalidValidatorError(componentName, location, propFullName, key, type) {\n return new PropTypeError(\n (componentName || 'React class') + ': ' + location + ' type `' + propFullName + '.' + key + '` is invalid; ' +\n 'it must be a function, usually from the `prop-types` package, but received `' + type + '`.'\n );\n }\n\n function createShapeTypeChecker(shapeTypes) {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== 'object') {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type `' + propType + '` ' + ('supplied to `' + componentName + '`, expected `object`.'));\n }\n for (var key in shapeTypes) {\n var checker = shapeTypes[key];\n if (typeof checker !== 'function') {\n return invalidValidatorError(componentName, location, propFullName, key, getPreciseType(checker));\n }\n var error = checker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret);\n if (error) {\n return error;\n }\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createStrictShapeTypeChecker(shapeTypes) {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== 'object') {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type `' + propType + '` ' + ('supplied to `' + componentName + '`, expected `object`.'));\n }\n // We need to check all keys in case some are required but missing from props.\n var allKeys = assign({}, props[propName], shapeTypes);\n for (var key in allKeys) {\n var checker = shapeTypes[key];\n if (has(shapeTypes, key) && typeof checker !== 'function') {\n return invalidValidatorError(componentName, location, propFullName, key, getPreciseType(checker));\n }\n if (!checker) {\n return new PropTypeError(\n 'Invalid ' + location + ' `' + propFullName + '` key `' + key + '` supplied to `' + componentName + '`.' +\n '\\nBad object: ' + JSON.stringify(props[propName], null, ' ') +\n '\\nValid keys: ' + JSON.stringify(Object.keys(shapeTypes), null, ' ')\n );\n }\n var error = checker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret);\n if (error) {\n return error;\n }\n }\n return null;\n }\n\n return createChainableTypeChecker(validate);\n }\n\n function isNode(propValue) {\n switch (typeof propValue) {\n case 'number':\n case 'string':\n case 'undefined':\n return true;\n case 'boolean':\n return !propValue;\n case 'object':\n if (Array.isArray(propValue)) {\n return propValue.every(isNode);\n }\n if (propValue === null || isValidElement(propValue)) {\n return true;\n }\n\n var iteratorFn = getIteratorFn(propValue);\n if (iteratorFn) {\n var iterator = iteratorFn.call(propValue);\n var step;\n if (iteratorFn !== propValue.entries) {\n while (!(step = iterator.next()).done) {\n if (!isNode(step.value)) {\n return false;\n }\n }\n } else {\n // Iterator will provide entry [k,v] tuples rather than values.\n while (!(step = iterator.next()).done) {\n var entry = step.value;\n if (entry) {\n if (!isNode(entry[1])) {\n return false;\n }\n }\n }\n }\n } else {\n return false;\n }\n\n return true;\n default:\n return false;\n }\n }\n\n function isSymbol(propType, propValue) {\n // Native Symbol.\n if (propType === 'symbol') {\n return true;\n }\n\n // falsy value can't be a Symbol\n if (!propValue) {\n return false;\n }\n\n // 19.4.3.5 Symbol.prototype[@@toStringTag] === 'Symbol'\n if (propValue['@@toStringTag'] === 'Symbol') {\n return true;\n }\n\n // Fallback for non-spec compliant Symbols which are polyfilled.\n if (typeof Symbol === 'function' && propValue instanceof Symbol) {\n return true;\n }\n\n return false;\n }\n\n // Equivalent of `typeof` but with special handling for array and regexp.\n function getPropType(propValue) {\n var propType = typeof propValue;\n if (Array.isArray(propValue)) {\n return 'array';\n }\n if (propValue instanceof RegExp) {\n // Old webkits (at least until Android 4.0) return 'function' rather than\n // 'object' for typeof a RegExp. We'll normalize this here so that /bla/\n // passes PropTypes.object.\n return 'object';\n }\n if (isSymbol(propType, propValue)) {\n return 'symbol';\n }\n return propType;\n }\n\n // This handles more types than `getPropType`. Only used for error messages.\n // See `createPrimitiveTypeChecker`.\n function getPreciseType(propValue) {\n if (typeof propValue === 'undefined' || propValue === null) {\n return '' + propValue;\n }\n var propType = getPropType(propValue);\n if (propType === 'object') {\n if (propValue instanceof Date) {\n return 'date';\n } else if (propValue instanceof RegExp) {\n return 'regexp';\n }\n }\n return propType;\n }\n\n // Returns a string that is postfixed to a warning about an invalid type.\n // For example, \"undefined\" or \"of type array\"\n function getPostfixForTypeWarning(value) {\n var type = getPreciseType(value);\n switch (type) {\n case 'array':\n case 'object':\n return 'an ' + type;\n case 'boolean':\n case 'date':\n case 'regexp':\n return 'a ' + type;\n default:\n return type;\n }\n }\n\n // Returns class name of the object, if any.\n function getClassName(propValue) {\n if (!propValue.constructor || !propValue.constructor.name) {\n return ANONYMOUS;\n }\n return propValue.constructor.name;\n }\n\n ReactPropTypes.checkPropTypes = checkPropTypes;\n ReactPropTypes.resetWarningCache = checkPropTypes.resetWarningCache;\n ReactPropTypes.PropTypes = ReactPropTypes;\n\n return ReactPropTypes;\n};\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar ReactPropTypesSecret = require('./lib/ReactPropTypesSecret');\n\nfunction emptyFunction() {}\nfunction emptyFunctionWithReset() {}\nemptyFunctionWithReset.resetWarningCache = emptyFunction;\n\nmodule.exports = function() {\n function shim(props, propName, componentName, location, propFullName, secret) {\n if (secret === ReactPropTypesSecret) {\n // It is still safe when called from React.\n return;\n }\n var err = new Error(\n 'Calling PropTypes validators directly is not supported by the `prop-types` package. ' +\n 'Use PropTypes.checkPropTypes() to call them. ' +\n 'Read more at http://fb.me/use-check-prop-types'\n );\n err.name = 'Invariant Violation';\n throw err;\n };\n shim.isRequired = shim;\n function getShim() {\n return shim;\n };\n // Important!\n // Keep this list in sync with production version in `./factoryWithTypeCheckers.js`.\n var ReactPropTypes = {\n array: shim,\n bigint: shim,\n bool: shim,\n func: shim,\n number: shim,\n object: shim,\n string: shim,\n symbol: shim,\n\n any: shim,\n arrayOf: getShim,\n element: shim,\n elementType: shim,\n instanceOf: getShim,\n node: shim,\n objectOf: getShim,\n oneOf: getShim,\n oneOfType: getShim,\n shape: getShim,\n exact: getShim,\n\n checkPropTypes: emptyFunctionWithReset,\n resetWarningCache: emptyFunction\n };\n\n ReactPropTypes.PropTypes = ReactPropTypes;\n\n return ReactPropTypes;\n};\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\nif (process.env.NODE_ENV !== 'production') {\n var ReactIs = require('react-is');\n\n // By explicitly using `prop-types` you are opting into new development behavior.\n // http://fb.me/prop-types-in-prod\n var throwOnDirectAccess = true;\n module.exports = require('./factoryWithTypeCheckers')(ReactIs.isElement, throwOnDirectAccess);\n} else {\n // By explicitly using `prop-types` you are opting into new production behavior.\n // http://fb.me/prop-types-in-prod\n module.exports = require('./factoryWithThrowingShims')();\n}\n","import PropTypes from 'prop-types';\nimport chainPropTypes from '../chainPropTypes';\nfunction isClassComponent(elementType) {\n // elementType.prototype?.isReactComponent\n const {\n prototype = {}\n } = elementType;\n return Boolean(prototype.isReactComponent);\n}\nfunction acceptingRef(props, propName, componentName, location, propFullName) {\n const element = props[propName];\n const safePropName = propFullName || propName;\n if (element == null ||\n // When server-side rendering React doesn't warn either.\n // This is not an accurate check for SSR.\n // This is only in place for Emotion compat.\n // TODO: Revisit once https://github.com/facebook/react/issues/20047 is resolved.\n typeof window === 'undefined') {\n return null;\n }\n let warningHint;\n const elementType = element.type;\n /**\n * Blacklisting instead of whitelisting\n *\n * Blacklisting will miss some components, such as React.Fragment. Those will at least\n * trigger a warning in React.\n * We can't whitelist because there is no safe way to detect React.forwardRef\n * or class components. \"Safe\" means there's no public API.\n *\n */\n if (typeof elementType === 'function' && !isClassComponent(elementType)) {\n warningHint = 'Did you accidentally use a plain function component for an element instead?';\n }\n if (warningHint !== undefined) {\n return new Error(`Invalid ${location} \\`${safePropName}\\` supplied to \\`${componentName}\\`. ` + `Expected an element that can hold a ref. ${warningHint} ` + 'For more information see https://mui.com/r/caveat-with-refs-guide');\n }\n return null;\n}\nconst elementAcceptingRef = chainPropTypes(PropTypes.element, acceptingRef);\nelementAcceptingRef.isRequired = chainPropTypes(PropTypes.element.isRequired, acceptingRef);\nexport default elementAcceptingRef;","import _extends from \"@babel/runtime/helpers/esm/extends\";\n// This module is based on https://github.com/airbnb/prop-types-exact repository.\n// However, in order to reduce the number of dependencies and to remove some extra safe checks\n// the module was forked.\n\nconst specialProperty = 'exact-prop: \\u200b';\nexport default function exactProp(propTypes) {\n if (process.env.NODE_ENV === 'production') {\n return propTypes;\n }\n return _extends({}, propTypes, {\n [specialProperty]: props => {\n const unsupportedProps = Object.keys(props).filter(prop => !propTypes.hasOwnProperty(prop));\n if (unsupportedProps.length > 0) {\n return new Error(`The following props are not supported: ${unsupportedProps.map(prop => `\\`${prop}\\``).join(', ')}. Please remove them.`);\n }\n return null;\n }\n });\n}","/**\n * WARNING: Don't import this directly.\n * Use `MuiError` from `@mui/internal-babel-macros/MuiError.macro` instead.\n * @param {number} code\n */\nexport default function formatMuiErrorMessage(code) {\n // Apply babel-plugin-transform-template-literals in loose mode\n // loose mode is safe if we're concatenating primitives\n // see https://babeljs.io/docs/en/babel-plugin-transform-template-literals#loose\n /* eslint-disable prefer-template */\n let url = 'https://mui.com/production-error/?code=' + code;\n for (let i = 1; i < arguments.length; i += 1) {\n // rest params over-transpile for this case\n // eslint-disable-next-line prefer-rest-params\n url += '&args[]=' + encodeURIComponent(arguments[i]);\n }\n return 'Minified MUI error #' + code + '; visit ' + url + ' for the full message.';\n /* eslint-enable prefer-template */\n}","/**\n * @license React\n * react-is.production.min.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n'use strict';var b=Symbol.for(\"react.element\"),c=Symbol.for(\"react.portal\"),d=Symbol.for(\"react.fragment\"),e=Symbol.for(\"react.strict_mode\"),f=Symbol.for(\"react.profiler\"),g=Symbol.for(\"react.provider\"),h=Symbol.for(\"react.context\"),k=Symbol.for(\"react.server_context\"),l=Symbol.for(\"react.forward_ref\"),m=Symbol.for(\"react.suspense\"),n=Symbol.for(\"react.suspense_list\"),p=Symbol.for(\"react.memo\"),q=Symbol.for(\"react.lazy\"),t=Symbol.for(\"react.offscreen\"),u;u=Symbol.for(\"react.module.reference\");\nfunction v(a){if(\"object\"===typeof a&&null!==a){var r=a.$$typeof;switch(r){case b:switch(a=a.type,a){case d:case f:case e:case m:case n:return a;default:switch(a=a&&a.$$typeof,a){case k:case h:case l:case q:case p:case g:return a;default:return r}}case c:return r}}}exports.ContextConsumer=h;exports.ContextProvider=g;exports.Element=b;exports.ForwardRef=l;exports.Fragment=d;exports.Lazy=q;exports.Memo=p;exports.Portal=c;exports.Profiler=f;exports.StrictMode=e;exports.Suspense=m;\nexports.SuspenseList=n;exports.isAsyncMode=function(){return!1};exports.isConcurrentMode=function(){return!1};exports.isContextConsumer=function(a){return v(a)===h};exports.isContextProvider=function(a){return v(a)===g};exports.isElement=function(a){return\"object\"===typeof a&&null!==a&&a.$$typeof===b};exports.isForwardRef=function(a){return v(a)===l};exports.isFragment=function(a){return v(a)===d};exports.isLazy=function(a){return v(a)===q};exports.isMemo=function(a){return v(a)===p};\nexports.isPortal=function(a){return v(a)===c};exports.isProfiler=function(a){return v(a)===f};exports.isStrictMode=function(a){return v(a)===e};exports.isSuspense=function(a){return v(a)===m};exports.isSuspenseList=function(a){return v(a)===n};\nexports.isValidElementType=function(a){return\"string\"===typeof a||\"function\"===typeof a||a===d||a===f||a===e||a===m||a===n||a===t||\"object\"===typeof a&&null!==a&&(a.$$typeof===q||a.$$typeof===p||a.$$typeof===g||a.$$typeof===h||a.$$typeof===l||a.$$typeof===u||void 0!==a.getModuleId)?!0:!1};exports.typeOf=v;\n","/**\n * @license React\n * react-is.development.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nif (process.env.NODE_ENV !== \"production\") {\n (function() {\n'use strict';\n\n// ATTENTION\n// When adding new symbols to this file,\n// Please consider also adding to 'react-devtools-shared/src/backend/ReactSymbols'\n// The Symbol used to tag the ReactElement-like types.\nvar REACT_ELEMENT_TYPE = Symbol.for('react.element');\nvar REACT_PORTAL_TYPE = Symbol.for('react.portal');\nvar REACT_FRAGMENT_TYPE = Symbol.for('react.fragment');\nvar REACT_STRICT_MODE_TYPE = Symbol.for('react.strict_mode');\nvar REACT_PROFILER_TYPE = Symbol.for('react.profiler');\nvar REACT_PROVIDER_TYPE = Symbol.for('react.provider');\nvar REACT_CONTEXT_TYPE = Symbol.for('react.context');\nvar REACT_SERVER_CONTEXT_TYPE = Symbol.for('react.server_context');\nvar REACT_FORWARD_REF_TYPE = Symbol.for('react.forward_ref');\nvar REACT_SUSPENSE_TYPE = Symbol.for('react.suspense');\nvar REACT_SUSPENSE_LIST_TYPE = Symbol.for('react.suspense_list');\nvar REACT_MEMO_TYPE = Symbol.for('react.memo');\nvar REACT_LAZY_TYPE = Symbol.for('react.lazy');\nvar REACT_OFFSCREEN_TYPE = Symbol.for('react.offscreen');\n\n// -----------------------------------------------------------------------------\n\nvar enableScopeAPI = false; // Experimental Create Event Handle API.\nvar enableCacheElement = false;\nvar enableTransitionTracing = false; // No known bugs, but needs performance testing\n\nvar enableLegacyHidden = false; // Enables unstable_avoidThisFallback feature in Fiber\n// stuff. Intended to enable React core members to more easily debug scheduling\n// issues in DEV builds.\n\nvar enableDebugTracing = false; // Track which Fiber(s) schedule render work.\n\nvar REACT_MODULE_REFERENCE;\n\n{\n REACT_MODULE_REFERENCE = Symbol.for('react.module.reference');\n}\n\nfunction isValidElementType(type) {\n if (typeof type === 'string' || typeof type === 'function') {\n return true;\n } // Note: typeof might be other than 'symbol' or 'number' (e.g. if it's a polyfill).\n\n\n if (type === REACT_FRAGMENT_TYPE || type === REACT_PROFILER_TYPE || enableDebugTracing || type === REACT_STRICT_MODE_TYPE || type === REACT_SUSPENSE_TYPE || type === REACT_SUSPENSE_LIST_TYPE || enableLegacyHidden || type === REACT_OFFSCREEN_TYPE || enableScopeAPI || enableCacheElement || enableTransitionTracing ) {\n return true;\n }\n\n if (typeof type === 'object' && type !== null) {\n if (type.$$typeof === REACT_LAZY_TYPE || type.$$typeof === REACT_MEMO_TYPE || type.$$typeof === REACT_PROVIDER_TYPE || type.$$typeof === REACT_CONTEXT_TYPE || type.$$typeof === REACT_FORWARD_REF_TYPE || // This needs to include all possible module reference object\n // types supported by any Flight configuration anywhere since\n // we don't know which Flight build this will end up being used\n // with.\n type.$$typeof === REACT_MODULE_REFERENCE || type.getModuleId !== undefined) {\n return true;\n }\n }\n\n return false;\n}\n\nfunction typeOf(object) {\n if (typeof object === 'object' && object !== null) {\n var $$typeof = object.$$typeof;\n\n switch ($$typeof) {\n case REACT_ELEMENT_TYPE:\n var type = object.type;\n\n switch (type) {\n case REACT_FRAGMENT_TYPE:\n case REACT_PROFILER_TYPE:\n case REACT_STRICT_MODE_TYPE:\n case REACT_SUSPENSE_TYPE:\n case REACT_SUSPENSE_LIST_TYPE:\n return type;\n\n default:\n var $$typeofType = type && type.$$typeof;\n\n switch ($$typeofType) {\n case REACT_SERVER_CONTEXT_TYPE:\n case REACT_CONTEXT_TYPE:\n case REACT_FORWARD_REF_TYPE:\n case REACT_LAZY_TYPE:\n case REACT_MEMO_TYPE:\n case REACT_PROVIDER_TYPE:\n return $$typeofType;\n\n default:\n return $$typeof;\n }\n\n }\n\n case REACT_PORTAL_TYPE:\n return $$typeof;\n }\n }\n\n return undefined;\n}\nvar ContextConsumer = REACT_CONTEXT_TYPE;\nvar ContextProvider = REACT_PROVIDER_TYPE;\nvar Element = REACT_ELEMENT_TYPE;\nvar ForwardRef = REACT_FORWARD_REF_TYPE;\nvar Fragment = REACT_FRAGMENT_TYPE;\nvar Lazy = REACT_LAZY_TYPE;\nvar Memo = REACT_MEMO_TYPE;\nvar Portal = REACT_PORTAL_TYPE;\nvar Profiler = REACT_PROFILER_TYPE;\nvar StrictMode = REACT_STRICT_MODE_TYPE;\nvar Suspense = REACT_SUSPENSE_TYPE;\nvar SuspenseList = REACT_SUSPENSE_LIST_TYPE;\nvar hasWarnedAboutDeprecatedIsAsyncMode = false;\nvar hasWarnedAboutDeprecatedIsConcurrentMode = false; // AsyncMode should be deprecated\n\nfunction isAsyncMode(object) {\n {\n if (!hasWarnedAboutDeprecatedIsAsyncMode) {\n hasWarnedAboutDeprecatedIsAsyncMode = true; // Using console['warn'] to evade Babel and ESLint\n\n console['warn']('The ReactIs.isAsyncMode() alias has been deprecated, ' + 'and will be removed in React 18+.');\n }\n }\n\n return false;\n}\nfunction isConcurrentMode(object) {\n {\n if (!hasWarnedAboutDeprecatedIsConcurrentMode) {\n hasWarnedAboutDeprecatedIsConcurrentMode = true; // Using console['warn'] to evade Babel and ESLint\n\n console['warn']('The ReactIs.isConcurrentMode() alias has been deprecated, ' + 'and will be removed in React 18+.');\n }\n }\n\n return false;\n}\nfunction isContextConsumer(object) {\n return typeOf(object) === REACT_CONTEXT_TYPE;\n}\nfunction isContextProvider(object) {\n return typeOf(object) === REACT_PROVIDER_TYPE;\n}\nfunction isElement(object) {\n return typeof object === 'object' && object !== null && object.$$typeof === REACT_ELEMENT_TYPE;\n}\nfunction isForwardRef(object) {\n return typeOf(object) === REACT_FORWARD_REF_TYPE;\n}\nfunction isFragment(object) {\n return typeOf(object) === REACT_FRAGMENT_TYPE;\n}\nfunction isLazy(object) {\n return typeOf(object) === REACT_LAZY_TYPE;\n}\nfunction isMemo(object) {\n return typeOf(object) === REACT_MEMO_TYPE;\n}\nfunction isPortal(object) {\n return typeOf(object) === REACT_PORTAL_TYPE;\n}\nfunction isProfiler(object) {\n return typeOf(object) === REACT_PROFILER_TYPE;\n}\nfunction isStrictMode(object) {\n return typeOf(object) === REACT_STRICT_MODE_TYPE;\n}\nfunction isSuspense(object) {\n return typeOf(object) === REACT_SUSPENSE_TYPE;\n}\nfunction isSuspenseList(object) {\n return typeOf(object) === REACT_SUSPENSE_LIST_TYPE;\n}\n\nexports.ContextConsumer = ContextConsumer;\nexports.ContextProvider = ContextProvider;\nexports.Element = Element;\nexports.ForwardRef = ForwardRef;\nexports.Fragment = Fragment;\nexports.Lazy = Lazy;\nexports.Memo = Memo;\nexports.Portal = Portal;\nexports.Profiler = Profiler;\nexports.StrictMode = StrictMode;\nexports.Suspense = Suspense;\nexports.SuspenseList = SuspenseList;\nexports.isAsyncMode = isAsyncMode;\nexports.isConcurrentMode = isConcurrentMode;\nexports.isContextConsumer = isContextConsumer;\nexports.isContextProvider = isContextProvider;\nexports.isElement = isElement;\nexports.isForwardRef = isForwardRef;\nexports.isFragment = isFragment;\nexports.isLazy = isLazy;\nexports.isMemo = isMemo;\nexports.isPortal = isPortal;\nexports.isProfiler = isProfiler;\nexports.isStrictMode = isStrictMode;\nexports.isSuspense = isSuspense;\nexports.isSuspenseList = isSuspenseList;\nexports.isValidElementType = isValidElementType;\nexports.typeOf = typeOf;\n })();\n}\n","'use strict';\n\nif (process.env.NODE_ENV === 'production') {\n module.exports = require('./cjs/react-is.production.min.js');\n} else {\n module.exports = require('./cjs/react-is.development.js');\n}\n","import { ForwardRef, Memo } from 'react-is';\n\n// Simplified polyfill for IE11 support\n// https://github.com/JamesMGreene/Function.name/blob/58b314d4a983110c3682f1228f845d39ccca1817/Function.name.js#L3\nconst fnNameMatchRegex = /^\\s*function(?:\\s|\\s*\\/\\*.*\\*\\/\\s*)+([^(\\s/]*)\\s*/;\nexport function getFunctionName(fn) {\n const match = `${fn}`.match(fnNameMatchRegex);\n const name = match && match[1];\n return name || '';\n}\nfunction getFunctionComponentName(Component, fallback = '') {\n return Component.displayName || Component.name || getFunctionName(Component) || fallback;\n}\nfunction getWrappedName(outerType, innerType, wrapperName) {\n const functionName = getFunctionComponentName(innerType);\n return outerType.displayName || (functionName !== '' ? `${wrapperName}(${functionName})` : wrapperName);\n}\n\n/**\n * cherry-pick from\n * https://github.com/facebook/react/blob/769b1f270e1251d9dbdce0fcbd9e92e502d059b8/packages/shared/getComponentName.js\n * originally forked from recompose/getDisplayName with added IE11 support\n */\nexport default function getDisplayName(Component) {\n if (Component == null) {\n return undefined;\n }\n if (typeof Component === 'string') {\n return Component;\n }\n if (typeof Component === 'function') {\n return getFunctionComponentName(Component, 'Component');\n }\n\n // TypeScript can't have components as objects but they exist in the form of `memo` or `Suspense`\n if (typeof Component === 'object') {\n switch (Component.$$typeof) {\n case ForwardRef:\n return getWrappedName(Component, Component.render, 'ForwardRef');\n case Memo:\n return getWrappedName(Component, Component.type, 'memo');\n default:\n return undefined;\n }\n }\n return undefined;\n}","export default function HTMLElementType(props, propName, componentName, location, propFullName) {\n if (process.env.NODE_ENV === 'production') {\n return null;\n }\n const propValue = props[propName];\n const safePropName = propFullName || propName;\n if (propValue == null) {\n return null;\n }\n if (propValue && propValue.nodeType !== 1) {\n return new Error(`Invalid ${location} \\`${safePropName}\\` supplied to \\`${componentName}\\`. ` + `Expected an HTMLElement.`);\n }\n return null;\n}","import PropTypes from 'prop-types';\nconst refType = PropTypes.oneOfType([PropTypes.func, PropTypes.object]);\nexport default refType;","import _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\n// It should to be noted that this function isn't equivalent to `text-transform: capitalize`.\n//\n// A strict capitalization should uppercase the first letter of each word in the sentence.\n// We only handle the first word.\nexport default function capitalize(string) {\n if (typeof string !== 'string') {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: \\`capitalize(string)\\` expects a string argument.` : _formatMuiErrorMessage(7));\n }\n return string.charAt(0).toUpperCase() + string.slice(1);\n}","/**\n * Safe chained function.\n *\n * Will only create a new function if needed,\n * otherwise will pass back existing functions or null.\n */\nexport default function createChainedFunction(...funcs) {\n return funcs.reduce((acc, func) => {\n if (func == null) {\n return acc;\n }\n return function chainedFunction(...args) {\n acc.apply(this, args);\n func.apply(this, args);\n };\n }, () => {});\n}","// Corresponds to 10 frames at 60 Hz.\n// A few bytes payload overhead when lodash/debounce is ~3 kB and debounce ~300 B.\nexport default function debounce(func, wait = 166) {\n let timeout;\n function debounced(...args) {\n const later = () => {\n // @ts-ignore\n func.apply(this, args);\n };\n clearTimeout(timeout);\n timeout = setTimeout(later, wait);\n }\n debounced.clear = () => {\n clearTimeout(timeout);\n };\n return debounced;\n}","export default function deprecatedPropType(validator, reason) {\n if (process.env.NODE_ENV === 'production') {\n return () => null;\n }\n return (props, propName, componentName, location, propFullName) => {\n const componentNameSafe = componentName || '<>';\n const propFullNameSafe = propFullName || propName;\n if (typeof props[propName] !== 'undefined') {\n return new Error(`The ${location} \\`${propFullNameSafe}\\` of ` + `\\`${componentNameSafe}\\` is deprecated. ${reason}`);\n }\n return null;\n };\n}","import * as React from 'react';\nexport default function isMuiElement(element, muiNames) {\n var _muiName, _element$type;\n return /*#__PURE__*/React.isValidElement(element) && muiNames.indexOf( // For server components `muiName` is avaialble in element.type._payload.value.muiName\n // relevant info - https://github.com/facebook/react/blob/2807d781a08db8e9873687fccc25c0f12b4fb3d4/packages/react/src/ReactLazy.js#L45\n // eslint-disable-next-line no-underscore-dangle\n (_muiName = element.type.muiName) != null ? _muiName : (_element$type = element.type) == null || (_element$type = _element$type._payload) == null || (_element$type = _element$type.value) == null ? void 0 : _element$type.muiName) !== -1;\n}","export default function ownerDocument(node) {\n return node && node.ownerDocument || document;\n}","import ownerDocument from '../ownerDocument';\nexport default function ownerWindow(node) {\n const doc = ownerDocument(node);\n return doc.defaultView || window;\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nexport default function requirePropFactory(componentNameInError, Component) {\n if (process.env.NODE_ENV === 'production') {\n return () => null;\n }\n\n // eslint-disable-next-line react/forbid-foreign-prop-types\n const prevPropTypes = Component ? _extends({}, Component.propTypes) : null;\n const requireProp = requiredProp => (props, propName, componentName, location, propFullName, ...args) => {\n const propFullNameSafe = propFullName || propName;\n const defaultTypeChecker = prevPropTypes == null ? void 0 : prevPropTypes[propFullNameSafe];\n if (defaultTypeChecker) {\n const typeCheckerResult = defaultTypeChecker(props, propName, componentName, location, propFullName, ...args);\n if (typeCheckerResult) {\n return typeCheckerResult;\n }\n }\n if (typeof props[propName] !== 'undefined' && !props[requiredProp]) {\n return new Error(`The prop \\`${propFullNameSafe}\\` of ` + `\\`${componentNameInError}\\` can only be used together with the \\`${requiredProp}\\` prop.`);\n }\n return null;\n };\n return requireProp;\n}","/**\n * TODO v5: consider making it private\n *\n * passes {value} to {ref}\n *\n * WARNING: Be sure to only call this inside a callback that is passed as a ref.\n * Otherwise, make sure to cleanup the previous {ref} if it changes. See\n * https://github.com/mui/material-ui/issues/13539\n *\n * Useful if you want to expose the ref of an inner component to the public API\n * while still using it inside the component.\n * @param ref A ref callback or ref object. If anything falsy, this is a no-op.\n */\nexport default function setRef(ref, value) {\n if (typeof ref === 'function') {\n ref(value);\n } else if (ref) {\n ref.current = value;\n }\n}","'use client';\n\nimport * as React from 'react';\n\n/**\n * A version of `React.useLayoutEffect` that does not show a warning when server-side rendering.\n * This is useful for effects that are only needed for client-side rendering but not for SSR.\n *\n * Before you use this hook, make sure to read https://gist.github.com/gaearon/e7d97cdf38a2907924ea12e4ebdf3c85\n * and confirm it doesn't apply to your use-case.\n */\nconst useEnhancedEffect = typeof window !== 'undefined' ? React.useLayoutEffect : React.useEffect;\nexport default useEnhancedEffect;","'use client';\n\nimport * as React from 'react';\nlet globalId = 0;\nfunction useGlobalId(idOverride) {\n const [defaultId, setDefaultId] = React.useState(idOverride);\n const id = idOverride || defaultId;\n React.useEffect(() => {\n if (defaultId == null) {\n // Fallback to this default id when possible.\n // Use the incrementing value for client-side rendering only.\n // We can't use it server-side.\n // If you want to use random values please consider the Birthday Problem: https://en.wikipedia.org/wiki/Birthday_problem\n globalId += 1;\n setDefaultId(`mui-${globalId}`);\n }\n }, [defaultId]);\n return id;\n}\n\n// downstream bundlers may remove unnecessary concatenation, but won't remove toString call -- Workaround for https://github.com/webpack/webpack/issues/14814\nconst maybeReactUseId = React['useId'.toString()];\n/**\n *\n * @example
    \n * @param idOverride\n * @returns {string}\n */\nexport default function useId(idOverride) {\n if (maybeReactUseId !== undefined) {\n const reactId = maybeReactUseId();\n return idOverride != null ? idOverride : reactId;\n }\n // eslint-disable-next-line react-hooks/rules-of-hooks -- `React.useId` is invariant at runtime.\n return useGlobalId(idOverride);\n}","export default function unsupportedProp(props, propName, componentName, location, propFullName) {\n if (process.env.NODE_ENV === 'production') {\n return null;\n }\n const propFullNameSafe = propFullName || propName;\n if (typeof props[propName] !== 'undefined') {\n return new Error(`The prop \\`${propFullNameSafe}\\` is not supported. Please remove it.`);\n }\n return null;\n}","'use client';\n\n/* eslint-disable react-hooks/rules-of-hooks, react-hooks/exhaustive-deps */\nimport * as React from 'react';\nexport default function useControlled({\n controlled,\n default: defaultProp,\n name,\n state = 'value'\n}) {\n // isControlled is ignored in the hook dependency lists as it should never change.\n const {\n current: isControlled\n } = React.useRef(controlled !== undefined);\n const [valueState, setValue] = React.useState(defaultProp);\n const value = isControlled ? controlled : valueState;\n if (process.env.NODE_ENV !== 'production') {\n React.useEffect(() => {\n if (isControlled !== (controlled !== undefined)) {\n console.error([`MUI: A component is changing the ${isControlled ? '' : 'un'}controlled ${state} state of ${name} to be ${isControlled ? 'un' : ''}controlled.`, 'Elements should not switch from uncontrolled to controlled (or vice versa).', `Decide between using a controlled or uncontrolled ${name} ` + 'element for the lifetime of the component.', \"The nature of the state is determined during the first render. It's considered controlled if the value is not `undefined`.\", 'More info: https://fb.me/react-controlled-components'].join('\\n'));\n }\n }, [state, name, controlled]);\n const {\n current: defaultValue\n } = React.useRef(defaultProp);\n React.useEffect(() => {\n if (!isControlled && defaultValue !== defaultProp) {\n console.error([`MUI: A component is changing the default ${state} state of an uncontrolled ${name} after being initialized. ` + `To suppress this warning opt to use a controlled ${name}.`].join('\\n'));\n }\n }, [JSON.stringify(defaultProp)]);\n }\n const setValueIfUncontrolled = React.useCallback(newValue => {\n if (!isControlled) {\n setValue(newValue);\n }\n }, []);\n return [value, setValueIfUncontrolled];\n}","'use client';\n\nimport * as React from 'react';\nimport useEnhancedEffect from '../useEnhancedEffect';\n\n/**\n * Inspired by https://github.com/facebook/react/issues/14099#issuecomment-440013892\n * See RFC in https://github.com/reactjs/rfcs/pull/220\n */\n\nfunction useEventCallback(fn) {\n const ref = React.useRef(fn);\n useEnhancedEffect(() => {\n ref.current = fn;\n });\n return React.useRef((...args) =>\n // @ts-expect-error hide `this`\n (0, ref.current)(...args)).current;\n}\nexport default useEventCallback;","'use client';\n\nimport * as React from 'react';\nimport setRef from '../setRef';\nexport default function useForkRef(...refs) {\n /**\n * This will create a new function if the refs passed to this hook change and are all defined.\n * This means react will call the old forkRef with `null` and the new forkRef\n * with the ref. Cleanup naturally emerges from this behavior.\n */\n return React.useMemo(() => {\n if (refs.every(ref => ref == null)) {\n return null;\n }\n return instance => {\n refs.forEach(ref => {\n setRef(ref, instance);\n });\n };\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, refs);\n}","'use client';\n\nimport * as React from 'react';\nconst UNINITIALIZED = {};\n\n/**\n * A React.useRef() that is initialized lazily with a function. Note that it accepts an optional\n * initialization argument, so the initialization function doesn't need to be an inline closure.\n *\n * @usage\n * const ref = useLazyRef(sortColumns, columns)\n */\nexport default function useLazyRef(init, initArg) {\n const ref = React.useRef(UNINITIALIZED);\n if (ref.current === UNINITIALIZED) {\n ref.current = init(initArg);\n }\n return ref;\n}","'use client';\n\nimport * as React from 'react';\nconst EMPTY = [];\n\n/**\n * A React.useEffect equivalent that runs once, when the component is mounted.\n */\nexport default function useOnMount(fn) {\n /* eslint-disable react-hooks/exhaustive-deps */\n React.useEffect(fn, EMPTY);\n /* eslint-enable react-hooks/exhaustive-deps */\n}","'use client';\n\nimport useLazyRef from '../useLazyRef/useLazyRef';\nimport useOnMount from '../useOnMount/useOnMount';\nexport class Timeout {\n constructor() {\n this.currentId = null;\n this.clear = () => {\n if (this.currentId !== null) {\n clearTimeout(this.currentId);\n this.currentId = null;\n }\n };\n this.disposeEffect = () => {\n return this.clear;\n };\n }\n static create() {\n return new Timeout();\n }\n /**\n * Executes `fn` after `delay`, clearing any previously scheduled call.\n */\n start(delay, fn) {\n this.clear();\n this.currentId = setTimeout(() => {\n this.currentId = null;\n fn();\n }, delay);\n }\n}\nexport default function useTimeout() {\n const timeout = useLazyRef(Timeout.create).current;\n useOnMount(timeout.disposeEffect);\n return timeout;\n}","'use client';\n\n// based on https://github.com/WICG/focus-visible/blob/v4.1.5/src/focus-visible.js\nimport * as React from 'react';\nimport { Timeout } from '../useTimeout/useTimeout';\nlet hadKeyboardEvent = true;\nlet hadFocusVisibleRecently = false;\nconst hadFocusVisibleRecentlyTimeout = new Timeout();\nconst inputTypesWhitelist = {\n text: true,\n search: true,\n url: true,\n tel: true,\n email: true,\n password: true,\n number: true,\n date: true,\n month: true,\n week: true,\n time: true,\n datetime: true,\n 'datetime-local': true\n};\n\n/**\n * Computes whether the given element should automatically trigger the\n * `focus-visible` class being added, i.e. whether it should always match\n * `:focus-visible` when focused.\n * @param {Element} node\n * @returns {boolean}\n */\nfunction focusTriggersKeyboardModality(node) {\n const {\n type,\n tagName\n } = node;\n if (tagName === 'INPUT' && inputTypesWhitelist[type] && !node.readOnly) {\n return true;\n }\n if (tagName === 'TEXTAREA' && !node.readOnly) {\n return true;\n }\n if (node.isContentEditable) {\n return true;\n }\n return false;\n}\n\n/**\n * Keep track of our keyboard modality state with `hadKeyboardEvent`.\n * If the most recent user interaction was via the keyboard;\n * and the key press did not include a meta, alt/option, or control key;\n * then the modality is keyboard. Otherwise, the modality is not keyboard.\n * @param {KeyboardEvent} event\n */\nfunction handleKeyDown(event) {\n if (event.metaKey || event.altKey || event.ctrlKey) {\n return;\n }\n hadKeyboardEvent = true;\n}\n\n/**\n * If at any point a user clicks with a pointing device, ensure that we change\n * the modality away from keyboard.\n * This avoids the situation where a user presses a key on an already focused\n * element, and then clicks on a different element, focusing it with a\n * pointing device, while we still think we're in keyboard modality.\n */\nfunction handlePointerDown() {\n hadKeyboardEvent = false;\n}\nfunction handleVisibilityChange() {\n if (this.visibilityState === 'hidden') {\n // If the tab becomes active again, the browser will handle calling focus\n // on the element (Safari actually calls it twice).\n // If this tab change caused a blur on an element with focus-visible,\n // re-apply the class when the user switches back to the tab.\n if (hadFocusVisibleRecently) {\n hadKeyboardEvent = true;\n }\n }\n}\nfunction prepare(doc) {\n doc.addEventListener('keydown', handleKeyDown, true);\n doc.addEventListener('mousedown', handlePointerDown, true);\n doc.addEventListener('pointerdown', handlePointerDown, true);\n doc.addEventListener('touchstart', handlePointerDown, true);\n doc.addEventListener('visibilitychange', handleVisibilityChange, true);\n}\nexport function teardown(doc) {\n doc.removeEventListener('keydown', handleKeyDown, true);\n doc.removeEventListener('mousedown', handlePointerDown, true);\n doc.removeEventListener('pointerdown', handlePointerDown, true);\n doc.removeEventListener('touchstart', handlePointerDown, true);\n doc.removeEventListener('visibilitychange', handleVisibilityChange, true);\n}\nfunction isFocusVisible(event) {\n const {\n target\n } = event;\n try {\n return target.matches(':focus-visible');\n } catch (error) {\n // Browsers not implementing :focus-visible will throw a SyntaxError.\n // We use our own heuristic for those browsers.\n // Rethrow might be better if it's not the expected error but do we really\n // want to crash if focus-visible malfunctioned?\n }\n\n // No need for validFocusTarget check. The user does that by attaching it to\n // focusable events only.\n return hadKeyboardEvent || focusTriggersKeyboardModality(target);\n}\nexport default function useIsFocusVisible() {\n const ref = React.useCallback(node => {\n if (node != null) {\n prepare(node.ownerDocument);\n }\n }, []);\n const isFocusVisibleRef = React.useRef(false);\n\n /**\n * Should be called if a blur event is fired\n */\n function handleBlurVisible() {\n // checking against potential state variable does not suffice if we focus and blur synchronously.\n // React wouldn't have time to trigger a re-render so `focusVisible` would be stale.\n // Ideally we would adjust `isFocusVisible(event)` to look at `relatedTarget` for blur events.\n // This doesn't work in IE11 due to https://github.com/facebook/react/issues/3751\n // TODO: check again if React releases their internal changes to focus event handling (https://github.com/facebook/react/pull/19186).\n if (isFocusVisibleRef.current) {\n // To detect a tab/window switch, we look for a blur event followed\n // rapidly by a visibility change.\n // If we don't see a visibility change within 100ms, it's probably a\n // regular focus change.\n hadFocusVisibleRecently = true;\n hadFocusVisibleRecentlyTimeout.start(100, () => {\n hadFocusVisibleRecently = false;\n });\n isFocusVisibleRef.current = false;\n return true;\n }\n return false;\n }\n\n /**\n * Should be called if a blur event is fired\n */\n function handleFocusVisible(event) {\n if (isFocusVisible(event)) {\n isFocusVisibleRef.current = true;\n return true;\n }\n return false;\n }\n return {\n isFocusVisibleRef,\n onFocus: handleFocusVisible,\n onBlur: handleBlurVisible,\n ref\n };\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\n/**\n * Add keys, values of `defaultProps` that does not exist in `props`\n * @param {object} defaultProps\n * @param {object} props\n * @returns {object} resolved props\n */\nexport default function resolveProps(defaultProps, props) {\n const output = _extends({}, props);\n Object.keys(defaultProps).forEach(propName => {\n if (propName.toString().match(/^(components|slots)$/)) {\n output[propName] = _extends({}, defaultProps[propName], output[propName]);\n } else if (propName.toString().match(/^(componentsProps|slotProps)$/)) {\n const defaultSlotProps = defaultProps[propName] || {};\n const slotProps = props[propName];\n output[propName] = {};\n if (!slotProps || !Object.keys(slotProps)) {\n // Reduce the iteration if the slot props is empty\n output[propName] = defaultSlotProps;\n } else if (!defaultSlotProps || !Object.keys(defaultSlotProps)) {\n // Reduce the iteration if the default slot props is empty\n output[propName] = slotProps;\n } else {\n output[propName] = _extends({}, slotProps);\n Object.keys(defaultSlotProps).forEach(slotPropName => {\n output[propName][slotPropName] = resolveProps(defaultSlotProps[slotPropName], slotProps[slotPropName]);\n });\n }\n } else if (output[propName] === undefined) {\n output[propName] = defaultProps[propName];\n }\n });\n return output;\n}","export default function composeClasses(slots, getUtilityClass, classes = undefined) {\n const output = {};\n Object.keys(slots).forEach(\n // `Object.keys(slots)` can't be wider than `T` because we infer `T` from `slots`.\n // @ts-expect-error https://github.com/microsoft/TypeScript/pull/12253#issuecomment-263132208\n slot => {\n output[slot] = slots[slot].reduce((acc, key) => {\n if (key) {\n const utilityClass = getUtilityClass(key);\n if (utilityClass !== '') {\n acc.push(utilityClass);\n }\n if (classes && classes[key]) {\n acc.push(classes[key]);\n }\n }\n return acc;\n }, []).join(' ');\n });\n return output;\n}","const defaultGenerator = componentName => componentName;\nconst createClassNameGenerator = () => {\n let generate = defaultGenerator;\n return {\n configure(generator) {\n generate = generator;\n },\n generate(componentName) {\n return generate(componentName);\n },\n reset() {\n generate = defaultGenerator;\n }\n };\n};\nconst ClassNameGenerator = createClassNameGenerator();\nexport default ClassNameGenerator;","import ClassNameGenerator from '../ClassNameGenerator';\nexport const globalStateClasses = {\n active: 'active',\n checked: 'checked',\n completed: 'completed',\n disabled: 'disabled',\n error: 'error',\n expanded: 'expanded',\n focused: 'focused',\n focusVisible: 'focusVisible',\n open: 'open',\n readOnly: 'readOnly',\n required: 'required',\n selected: 'selected'\n};\nexport default function generateUtilityClass(componentName, slot, globalStatePrefix = 'Mui') {\n const globalStateClass = globalStateClasses[slot];\n return globalStateClass ? `${globalStatePrefix}-${globalStateClass}` : `${ClassNameGenerator.generate(componentName)}-${slot}`;\n}\nexport function isGlobalState(slot) {\n return globalStateClasses[slot] !== undefined;\n}","import generateUtilityClass from '../generateUtilityClass';\nexport default function generateUtilityClasses(componentName, slots, globalStatePrefix = 'Mui') {\n const result = {};\n slots.forEach(slot => {\n result[slot] = generateUtilityClass(componentName, slot, globalStatePrefix);\n });\n return result;\n}","function clamp(val, min = Number.MIN_SAFE_INTEGER, max = Number.MAX_SAFE_INTEGER) {\n return Math.max(min, Math.min(val, max));\n}\nexport default clamp;","export default function _objectWithoutPropertiesLoose(source, excluded) {\n if (source == null) return {};\n var target = {};\n var sourceKeys = Object.keys(source);\n var key, i;\n for (i = 0; i < sourceKeys.length; i++) {\n key = sourceKeys[i];\n if (excluded.indexOf(key) >= 0) continue;\n target[key] = source[key];\n }\n return target;\n}","import _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nconst _excluded = [\"values\", \"unit\", \"step\"];\n// Sorted ASC by size. That's important.\n// It can't be configured as it's used statically for propTypes.\nexport const breakpointKeys = ['xs', 'sm', 'md', 'lg', 'xl'];\nconst sortBreakpointsValues = values => {\n const breakpointsAsArray = Object.keys(values).map(key => ({\n key,\n val: values[key]\n })) || [];\n // Sort in ascending order\n breakpointsAsArray.sort((breakpoint1, breakpoint2) => breakpoint1.val - breakpoint2.val);\n return breakpointsAsArray.reduce((acc, obj) => {\n return _extends({}, acc, {\n [obj.key]: obj.val\n });\n }, {});\n};\n\n// Keep in mind that @media is inclusive by the CSS specification.\nexport default function createBreakpoints(breakpoints) {\n const {\n // The breakpoint **start** at this value.\n // For instance with the first breakpoint xs: [xs, sm).\n values = {\n xs: 0,\n // phone\n sm: 600,\n // tablet\n md: 900,\n // small laptop\n lg: 1200,\n // desktop\n xl: 1536 // large screen\n },\n unit = 'px',\n step = 5\n } = breakpoints,\n other = _objectWithoutPropertiesLoose(breakpoints, _excluded);\n const sortedValues = sortBreakpointsValues(values);\n const keys = Object.keys(sortedValues);\n function up(key) {\n const value = typeof values[key] === 'number' ? values[key] : key;\n return `@media (min-width:${value}${unit})`;\n }\n function down(key) {\n const value = typeof values[key] === 'number' ? values[key] : key;\n return `@media (max-width:${value - step / 100}${unit})`;\n }\n function between(start, end) {\n const endIndex = keys.indexOf(end);\n return `@media (min-width:${typeof values[start] === 'number' ? values[start] : start}${unit}) and ` + `(max-width:${(endIndex !== -1 && typeof values[keys[endIndex]] === 'number' ? values[keys[endIndex]] : end) - step / 100}${unit})`;\n }\n function only(key) {\n if (keys.indexOf(key) + 1 < keys.length) {\n return between(key, keys[keys.indexOf(key) + 1]);\n }\n return up(key);\n }\n function not(key) {\n // handle first and last key separately, for better readability\n const keyIndex = keys.indexOf(key);\n if (keyIndex === 0) {\n return up(keys[1]);\n }\n if (keyIndex === keys.length - 1) {\n return down(keys[keyIndex]);\n }\n return between(key, keys[keys.indexOf(key) + 1]).replace('@media', '@media not all and');\n }\n return _extends({\n keys,\n values: sortedValues,\n up,\n down,\n between,\n only,\n not,\n unit\n }, other);\n}","const shape = {\n borderRadius: 4\n};\nexport default shape;","import PropTypes from 'prop-types';\nconst responsivePropType = process.env.NODE_ENV !== 'production' ? PropTypes.oneOfType([PropTypes.number, PropTypes.string, PropTypes.object, PropTypes.array]) : {};\nexport default responsivePropType;","import deepmerge from '@mui/utils/deepmerge';\nfunction merge(acc, item) {\n if (!item) {\n return acc;\n }\n return deepmerge(acc, item, {\n clone: false // No need to clone deep, it's way faster.\n });\n}\nexport default merge;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport PropTypes from 'prop-types';\nimport deepmerge from '@mui/utils/deepmerge';\nimport merge from './merge';\n\n// The breakpoint **start** at this value.\n// For instance with the first breakpoint xs: [xs, sm[.\nexport const values = {\n xs: 0,\n // phone\n sm: 600,\n // tablet\n md: 900,\n // small laptop\n lg: 1200,\n // desktop\n xl: 1536 // large screen\n};\nconst defaultBreakpoints = {\n // Sorted ASC by size. That's important.\n // It can't be configured as it's used statically for propTypes.\n keys: ['xs', 'sm', 'md', 'lg', 'xl'],\n up: key => `@media (min-width:${values[key]}px)`\n};\nexport function handleBreakpoints(props, propValue, styleFromPropValue) {\n const theme = props.theme || {};\n if (Array.isArray(propValue)) {\n const themeBreakpoints = theme.breakpoints || defaultBreakpoints;\n return propValue.reduce((acc, item, index) => {\n acc[themeBreakpoints.up(themeBreakpoints.keys[index])] = styleFromPropValue(propValue[index]);\n return acc;\n }, {});\n }\n if (typeof propValue === 'object') {\n const themeBreakpoints = theme.breakpoints || defaultBreakpoints;\n return Object.keys(propValue).reduce((acc, breakpoint) => {\n // key is breakpoint\n if (Object.keys(themeBreakpoints.values || values).indexOf(breakpoint) !== -1) {\n const mediaKey = themeBreakpoints.up(breakpoint);\n acc[mediaKey] = styleFromPropValue(propValue[breakpoint], breakpoint);\n } else {\n const cssKey = breakpoint;\n acc[cssKey] = propValue[cssKey];\n }\n return acc;\n }, {});\n }\n const output = styleFromPropValue(propValue);\n return output;\n}\nfunction breakpoints(styleFunction) {\n // false positive\n // eslint-disable-next-line react/function-component-definition\n const newStyleFunction = props => {\n const theme = props.theme || {};\n const base = styleFunction(props);\n const themeBreakpoints = theme.breakpoints || defaultBreakpoints;\n const extended = themeBreakpoints.keys.reduce((acc, key) => {\n if (props[key]) {\n acc = acc || {};\n acc[themeBreakpoints.up(key)] = styleFunction(_extends({\n theme\n }, props[key]));\n }\n return acc;\n }, null);\n return merge(base, extended);\n };\n newStyleFunction.propTypes = process.env.NODE_ENV !== 'production' ? _extends({}, styleFunction.propTypes, {\n xs: PropTypes.object,\n sm: PropTypes.object,\n md: PropTypes.object,\n lg: PropTypes.object,\n xl: PropTypes.object\n }) : {};\n newStyleFunction.filterProps = ['xs', 'sm', 'md', 'lg', 'xl', ...styleFunction.filterProps];\n return newStyleFunction;\n}\nexport function createEmptyBreakpointObject(breakpointsInput = {}) {\n var _breakpointsInput$key;\n const breakpointsInOrder = (_breakpointsInput$key = breakpointsInput.keys) == null ? void 0 : _breakpointsInput$key.reduce((acc, key) => {\n const breakpointStyleKey = breakpointsInput.up(key);\n acc[breakpointStyleKey] = {};\n return acc;\n }, {});\n return breakpointsInOrder || {};\n}\nexport function removeUnusedBreakpoints(breakpointKeys, style) {\n return breakpointKeys.reduce((acc, key) => {\n const breakpointOutput = acc[key];\n const isBreakpointUnused = !breakpointOutput || Object.keys(breakpointOutput).length === 0;\n if (isBreakpointUnused) {\n delete acc[key];\n }\n return acc;\n }, style);\n}\nexport function mergeBreakpointsInOrder(breakpointsInput, ...styles) {\n const emptyBreakpoints = createEmptyBreakpointObject(breakpointsInput);\n const mergedOutput = [emptyBreakpoints, ...styles].reduce((prev, next) => deepmerge(prev, next), {});\n return removeUnusedBreakpoints(Object.keys(emptyBreakpoints), mergedOutput);\n}\n\n// compute base for responsive values; e.g.,\n// [1,2,3] => {xs: true, sm: true, md: true}\n// {xs: 1, sm: 2, md: 3} => {xs: true, sm: true, md: true}\nexport function computeBreakpointsBase(breakpointValues, themeBreakpoints) {\n // fixed value\n if (typeof breakpointValues !== 'object') {\n return {};\n }\n const base = {};\n const breakpointsKeys = Object.keys(themeBreakpoints);\n if (Array.isArray(breakpointValues)) {\n breakpointsKeys.forEach((breakpoint, i) => {\n if (i < breakpointValues.length) {\n base[breakpoint] = true;\n }\n });\n } else {\n breakpointsKeys.forEach(breakpoint => {\n if (breakpointValues[breakpoint] != null) {\n base[breakpoint] = true;\n }\n });\n }\n return base;\n}\nexport function resolveBreakpointValues({\n values: breakpointValues,\n breakpoints: themeBreakpoints,\n base: customBase\n}) {\n const base = customBase || computeBreakpointsBase(breakpointValues, themeBreakpoints);\n const keys = Object.keys(base);\n if (keys.length === 0) {\n return breakpointValues;\n }\n let previous;\n return keys.reduce((acc, breakpoint, i) => {\n if (Array.isArray(breakpointValues)) {\n acc[breakpoint] = breakpointValues[i] != null ? breakpointValues[i] : breakpointValues[previous];\n previous = i;\n } else if (typeof breakpointValues === 'object') {\n acc[breakpoint] = breakpointValues[breakpoint] != null ? breakpointValues[breakpoint] : breakpointValues[previous];\n previous = breakpoint;\n } else {\n acc[breakpoint] = breakpointValues;\n }\n return acc;\n }, {});\n}\nexport default breakpoints;","import capitalize from '@mui/utils/capitalize';\nimport responsivePropType from './responsivePropType';\nimport { handleBreakpoints } from './breakpoints';\nexport function getPath(obj, path, checkVars = true) {\n if (!path || typeof path !== 'string') {\n return null;\n }\n\n // Check if CSS variables are used\n if (obj && obj.vars && checkVars) {\n const val = `vars.${path}`.split('.').reduce((acc, item) => acc && acc[item] ? acc[item] : null, obj);\n if (val != null) {\n return val;\n }\n }\n return path.split('.').reduce((acc, item) => {\n if (acc && acc[item] != null) {\n return acc[item];\n }\n return null;\n }, obj);\n}\nexport function getStyleValue(themeMapping, transform, propValueFinal, userValue = propValueFinal) {\n let value;\n if (typeof themeMapping === 'function') {\n value = themeMapping(propValueFinal);\n } else if (Array.isArray(themeMapping)) {\n value = themeMapping[propValueFinal] || userValue;\n } else {\n value = getPath(themeMapping, propValueFinal) || userValue;\n }\n if (transform) {\n value = transform(value, userValue, themeMapping);\n }\n return value;\n}\nfunction style(options) {\n const {\n prop,\n cssProperty = options.prop,\n themeKey,\n transform\n } = options;\n\n // false positive\n // eslint-disable-next-line react/function-component-definition\n const fn = props => {\n if (props[prop] == null) {\n return null;\n }\n const propValue = props[prop];\n const theme = props.theme;\n const themeMapping = getPath(theme, themeKey) || {};\n const styleFromPropValue = propValueFinal => {\n let value = getStyleValue(themeMapping, transform, propValueFinal);\n if (propValueFinal === value && typeof propValueFinal === 'string') {\n // Haven't found value\n value = getStyleValue(themeMapping, transform, `${prop}${propValueFinal === 'default' ? '' : capitalize(propValueFinal)}`, propValueFinal);\n }\n if (cssProperty === false) {\n return value;\n }\n return {\n [cssProperty]: value\n };\n };\n return handleBreakpoints(props, propValue, styleFromPropValue);\n };\n fn.propTypes = process.env.NODE_ENV !== 'production' ? {\n [prop]: responsivePropType\n } : {};\n fn.filterProps = [prop];\n return fn;\n}\nexport default style;","export default function memoize(fn) {\n const cache = {};\n return arg => {\n if (cache[arg] === undefined) {\n cache[arg] = fn(arg);\n }\n return cache[arg];\n };\n}","import responsivePropType from './responsivePropType';\nimport { handleBreakpoints } from './breakpoints';\nimport { getPath } from './style';\nimport merge from './merge';\nimport memoize from './memoize';\nconst properties = {\n m: 'margin',\n p: 'padding'\n};\nconst directions = {\n t: 'Top',\n r: 'Right',\n b: 'Bottom',\n l: 'Left',\n x: ['Left', 'Right'],\n y: ['Top', 'Bottom']\n};\nconst aliases = {\n marginX: 'mx',\n marginY: 'my',\n paddingX: 'px',\n paddingY: 'py'\n};\n\n// memoize() impact:\n// From 300,000 ops/sec\n// To 350,000 ops/sec\nconst getCssProperties = memoize(prop => {\n // It's not a shorthand notation.\n if (prop.length > 2) {\n if (aliases[prop]) {\n prop = aliases[prop];\n } else {\n return [prop];\n }\n }\n const [a, b] = prop.split('');\n const property = properties[a];\n const direction = directions[b] || '';\n return Array.isArray(direction) ? direction.map(dir => property + dir) : [property + direction];\n});\nexport const marginKeys = ['m', 'mt', 'mr', 'mb', 'ml', 'mx', 'my', 'margin', 'marginTop', 'marginRight', 'marginBottom', 'marginLeft', 'marginX', 'marginY', 'marginInline', 'marginInlineStart', 'marginInlineEnd', 'marginBlock', 'marginBlockStart', 'marginBlockEnd'];\nexport const paddingKeys = ['p', 'pt', 'pr', 'pb', 'pl', 'px', 'py', 'padding', 'paddingTop', 'paddingRight', 'paddingBottom', 'paddingLeft', 'paddingX', 'paddingY', 'paddingInline', 'paddingInlineStart', 'paddingInlineEnd', 'paddingBlock', 'paddingBlockStart', 'paddingBlockEnd'];\nconst spacingKeys = [...marginKeys, ...paddingKeys];\nexport function createUnaryUnit(theme, themeKey, defaultValue, propName) {\n var _getPath;\n const themeSpacing = (_getPath = getPath(theme, themeKey, false)) != null ? _getPath : defaultValue;\n if (typeof themeSpacing === 'number') {\n return abs => {\n if (typeof abs === 'string') {\n return abs;\n }\n if (process.env.NODE_ENV !== 'production') {\n if (typeof abs !== 'number') {\n console.error(`MUI: Expected ${propName} argument to be a number or a string, got ${abs}.`);\n }\n }\n return themeSpacing * abs;\n };\n }\n if (Array.isArray(themeSpacing)) {\n return abs => {\n if (typeof abs === 'string') {\n return abs;\n }\n if (process.env.NODE_ENV !== 'production') {\n if (!Number.isInteger(abs)) {\n console.error([`MUI: The \\`theme.${themeKey}\\` array type cannot be combined with non integer values.` + `You should either use an integer value that can be used as index, or define the \\`theme.${themeKey}\\` as a number.`].join('\\n'));\n } else if (abs > themeSpacing.length - 1) {\n console.error([`MUI: The value provided (${abs}) overflows.`, `The supported values are: ${JSON.stringify(themeSpacing)}.`, `${abs} > ${themeSpacing.length - 1}, you need to add the missing values.`].join('\\n'));\n }\n }\n return themeSpacing[abs];\n };\n }\n if (typeof themeSpacing === 'function') {\n return themeSpacing;\n }\n if (process.env.NODE_ENV !== 'production') {\n console.error([`MUI: The \\`theme.${themeKey}\\` value (${themeSpacing}) is invalid.`, 'It should be a number, an array or a function.'].join('\\n'));\n }\n return () => undefined;\n}\nexport function createUnarySpacing(theme) {\n return createUnaryUnit(theme, 'spacing', 8, 'spacing');\n}\nexport function getValue(transformer, propValue) {\n if (typeof propValue === 'string' || propValue == null) {\n return propValue;\n }\n const abs = Math.abs(propValue);\n const transformed = transformer(abs);\n if (propValue >= 0) {\n return transformed;\n }\n if (typeof transformed === 'number') {\n return -transformed;\n }\n return `-${transformed}`;\n}\nexport function getStyleFromPropValue(cssProperties, transformer) {\n return propValue => cssProperties.reduce((acc, cssProperty) => {\n acc[cssProperty] = getValue(transformer, propValue);\n return acc;\n }, {});\n}\nfunction resolveCssProperty(props, keys, prop, transformer) {\n // Using a hash computation over an array iteration could be faster, but with only 28 items,\n // it's doesn't worth the bundle size.\n if (keys.indexOf(prop) === -1) {\n return null;\n }\n const cssProperties = getCssProperties(prop);\n const styleFromPropValue = getStyleFromPropValue(cssProperties, transformer);\n const propValue = props[prop];\n return handleBreakpoints(props, propValue, styleFromPropValue);\n}\nfunction style(props, keys) {\n const transformer = createUnarySpacing(props.theme);\n return Object.keys(props).map(prop => resolveCssProperty(props, keys, prop, transformer)).reduce(merge, {});\n}\nexport function margin(props) {\n return style(props, marginKeys);\n}\nmargin.propTypes = process.env.NODE_ENV !== 'production' ? marginKeys.reduce((obj, key) => {\n obj[key] = responsivePropType;\n return obj;\n}, {}) : {};\nmargin.filterProps = marginKeys;\nexport function padding(props) {\n return style(props, paddingKeys);\n}\npadding.propTypes = process.env.NODE_ENV !== 'production' ? paddingKeys.reduce((obj, key) => {\n obj[key] = responsivePropType;\n return obj;\n}, {}) : {};\npadding.filterProps = paddingKeys;\nfunction spacing(props) {\n return style(props, spacingKeys);\n}\nspacing.propTypes = process.env.NODE_ENV !== 'production' ? spacingKeys.reduce((obj, key) => {\n obj[key] = responsivePropType;\n return obj;\n}, {}) : {};\nspacing.filterProps = spacingKeys;\nexport default spacing;","import { createUnarySpacing } from '../spacing';\n\n// The different signatures imply different meaning for their arguments that can't be expressed structurally.\n// We express the difference with variable names.\n\nexport default function createSpacing(spacingInput = 8) {\n // Already transformed.\n if (spacingInput.mui) {\n return spacingInput;\n }\n\n // Material Design layouts are visually balanced. Most measurements align to an 8dp grid, which aligns both spacing and the overall layout.\n // Smaller components, such as icons, can align to a 4dp grid.\n // https://m2.material.io/design/layout/understanding-layout.html\n const transform = createUnarySpacing({\n spacing: spacingInput\n });\n const spacing = (...argsInput) => {\n if (process.env.NODE_ENV !== 'production') {\n if (!(argsInput.length <= 4)) {\n console.error(`MUI: Too many arguments provided, expected between 0 and 4, got ${argsInput.length}`);\n }\n }\n const args = argsInput.length === 0 ? [1] : argsInput;\n return args.map(argument => {\n const output = transform(argument);\n return typeof output === 'number' ? `${output}px` : output;\n }).join(' ');\n };\n spacing.mui = true;\n return spacing;\n}","import merge from './merge';\nfunction compose(...styles) {\n const handlers = styles.reduce((acc, style) => {\n style.filterProps.forEach(prop => {\n acc[prop] = style;\n });\n return acc;\n }, {});\n\n // false positive\n // eslint-disable-next-line react/function-component-definition\n const fn = props => {\n return Object.keys(props).reduce((acc, prop) => {\n if (handlers[prop]) {\n return merge(acc, handlers[prop](props));\n }\n return acc;\n }, {});\n };\n fn.propTypes = process.env.NODE_ENV !== 'production' ? styles.reduce((acc, style) => Object.assign(acc, style.propTypes), {}) : {};\n fn.filterProps = styles.reduce((acc, style) => acc.concat(style.filterProps), []);\n return fn;\n}\nexport default compose;","import responsivePropType from './responsivePropType';\nimport style from './style';\nimport compose from './compose';\nimport { createUnaryUnit, getValue } from './spacing';\nimport { handleBreakpoints } from './breakpoints';\nexport function borderTransform(value) {\n if (typeof value !== 'number') {\n return value;\n }\n return `${value}px solid`;\n}\nfunction createBorderStyle(prop, transform) {\n return style({\n prop,\n themeKey: 'borders',\n transform\n });\n}\nexport const border = createBorderStyle('border', borderTransform);\nexport const borderTop = createBorderStyle('borderTop', borderTransform);\nexport const borderRight = createBorderStyle('borderRight', borderTransform);\nexport const borderBottom = createBorderStyle('borderBottom', borderTransform);\nexport const borderLeft = createBorderStyle('borderLeft', borderTransform);\nexport const borderColor = createBorderStyle('borderColor');\nexport const borderTopColor = createBorderStyle('borderTopColor');\nexport const borderRightColor = createBorderStyle('borderRightColor');\nexport const borderBottomColor = createBorderStyle('borderBottomColor');\nexport const borderLeftColor = createBorderStyle('borderLeftColor');\nexport const outline = createBorderStyle('outline', borderTransform);\nexport const outlineColor = createBorderStyle('outlineColor');\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const borderRadius = props => {\n if (props.borderRadius !== undefined && props.borderRadius !== null) {\n const transformer = createUnaryUnit(props.theme, 'shape.borderRadius', 4, 'borderRadius');\n const styleFromPropValue = propValue => ({\n borderRadius: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.borderRadius, styleFromPropValue);\n }\n return null;\n};\nborderRadius.propTypes = process.env.NODE_ENV !== 'production' ? {\n borderRadius: responsivePropType\n} : {};\nborderRadius.filterProps = ['borderRadius'];\nconst borders = compose(border, borderTop, borderRight, borderBottom, borderLeft, borderColor, borderTopColor, borderRightColor, borderBottomColor, borderLeftColor, borderRadius, outline, outlineColor);\nexport default borders;","import style from './style';\nimport compose from './compose';\nimport { createUnaryUnit, getValue } from './spacing';\nimport { handleBreakpoints } from './breakpoints';\nimport responsivePropType from './responsivePropType';\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const gap = props => {\n if (props.gap !== undefined && props.gap !== null) {\n const transformer = createUnaryUnit(props.theme, 'spacing', 8, 'gap');\n const styleFromPropValue = propValue => ({\n gap: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.gap, styleFromPropValue);\n }\n return null;\n};\ngap.propTypes = process.env.NODE_ENV !== 'production' ? {\n gap: responsivePropType\n} : {};\ngap.filterProps = ['gap'];\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const columnGap = props => {\n if (props.columnGap !== undefined && props.columnGap !== null) {\n const transformer = createUnaryUnit(props.theme, 'spacing', 8, 'columnGap');\n const styleFromPropValue = propValue => ({\n columnGap: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.columnGap, styleFromPropValue);\n }\n return null;\n};\ncolumnGap.propTypes = process.env.NODE_ENV !== 'production' ? {\n columnGap: responsivePropType\n} : {};\ncolumnGap.filterProps = ['columnGap'];\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const rowGap = props => {\n if (props.rowGap !== undefined && props.rowGap !== null) {\n const transformer = createUnaryUnit(props.theme, 'spacing', 8, 'rowGap');\n const styleFromPropValue = propValue => ({\n rowGap: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.rowGap, styleFromPropValue);\n }\n return null;\n};\nrowGap.propTypes = process.env.NODE_ENV !== 'production' ? {\n rowGap: responsivePropType\n} : {};\nrowGap.filterProps = ['rowGap'];\nexport const gridColumn = style({\n prop: 'gridColumn'\n});\nexport const gridRow = style({\n prop: 'gridRow'\n});\nexport const gridAutoFlow = style({\n prop: 'gridAutoFlow'\n});\nexport const gridAutoColumns = style({\n prop: 'gridAutoColumns'\n});\nexport const gridAutoRows = style({\n prop: 'gridAutoRows'\n});\nexport const gridTemplateColumns = style({\n prop: 'gridTemplateColumns'\n});\nexport const gridTemplateRows = style({\n prop: 'gridTemplateRows'\n});\nexport const gridTemplateAreas = style({\n prop: 'gridTemplateAreas'\n});\nexport const gridArea = style({\n prop: 'gridArea'\n});\nconst grid = compose(gap, columnGap, rowGap, gridColumn, gridRow, gridAutoFlow, gridAutoColumns, gridAutoRows, gridTemplateColumns, gridTemplateRows, gridTemplateAreas, gridArea);\nexport default grid;","import style from './style';\nimport compose from './compose';\nexport function paletteTransform(value, userValue) {\n if (userValue === 'grey') {\n return userValue;\n }\n return value;\n}\nexport const color = style({\n prop: 'color',\n themeKey: 'palette',\n transform: paletteTransform\n});\nexport const bgcolor = style({\n prop: 'bgcolor',\n cssProperty: 'backgroundColor',\n themeKey: 'palette',\n transform: paletteTransform\n});\nexport const backgroundColor = style({\n prop: 'backgroundColor',\n themeKey: 'palette',\n transform: paletteTransform\n});\nconst palette = compose(color, bgcolor, backgroundColor);\nexport default palette;","import style from './style';\nimport compose from './compose';\nimport { handleBreakpoints, values as breakpointsValues } from './breakpoints';\nexport function sizingTransform(value) {\n return value <= 1 && value !== 0 ? `${value * 100}%` : value;\n}\nexport const width = style({\n prop: 'width',\n transform: sizingTransform\n});\nexport const maxWidth = props => {\n if (props.maxWidth !== undefined && props.maxWidth !== null) {\n const styleFromPropValue = propValue => {\n var _props$theme, _props$theme2;\n const breakpoint = ((_props$theme = props.theme) == null || (_props$theme = _props$theme.breakpoints) == null || (_props$theme = _props$theme.values) == null ? void 0 : _props$theme[propValue]) || breakpointsValues[propValue];\n if (!breakpoint) {\n return {\n maxWidth: sizingTransform(propValue)\n };\n }\n if (((_props$theme2 = props.theme) == null || (_props$theme2 = _props$theme2.breakpoints) == null ? void 0 : _props$theme2.unit) !== 'px') {\n return {\n maxWidth: `${breakpoint}${props.theme.breakpoints.unit}`\n };\n }\n return {\n maxWidth: breakpoint\n };\n };\n return handleBreakpoints(props, props.maxWidth, styleFromPropValue);\n }\n return null;\n};\nmaxWidth.filterProps = ['maxWidth'];\nexport const minWidth = style({\n prop: 'minWidth',\n transform: sizingTransform\n});\nexport const height = style({\n prop: 'height',\n transform: sizingTransform\n});\nexport const maxHeight = style({\n prop: 'maxHeight',\n transform: sizingTransform\n});\nexport const minHeight = style({\n prop: 'minHeight',\n transform: sizingTransform\n});\nexport const sizeWidth = style({\n prop: 'size',\n cssProperty: 'width',\n transform: sizingTransform\n});\nexport const sizeHeight = style({\n prop: 'size',\n cssProperty: 'height',\n transform: sizingTransform\n});\nexport const boxSizing = style({\n prop: 'boxSizing'\n});\nconst sizing = compose(width, maxWidth, minWidth, height, maxHeight, minHeight, boxSizing);\nexport default sizing;","import { padding, margin } from '../spacing';\nimport { borderRadius, borderTransform } from '../borders';\nimport { gap, rowGap, columnGap } from '../cssGrid';\nimport { paletteTransform } from '../palette';\nimport { maxWidth, sizingTransform } from '../sizing';\nconst defaultSxConfig = {\n // borders\n border: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderTop: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderRight: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderBottom: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderLeft: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderColor: {\n themeKey: 'palette'\n },\n borderTopColor: {\n themeKey: 'palette'\n },\n borderRightColor: {\n themeKey: 'palette'\n },\n borderBottomColor: {\n themeKey: 'palette'\n },\n borderLeftColor: {\n themeKey: 'palette'\n },\n outline: {\n themeKey: 'borders',\n transform: borderTransform\n },\n outlineColor: {\n themeKey: 'palette'\n },\n borderRadius: {\n themeKey: 'shape.borderRadius',\n style: borderRadius\n },\n // palette\n color: {\n themeKey: 'palette',\n transform: paletteTransform\n },\n bgcolor: {\n themeKey: 'palette',\n cssProperty: 'backgroundColor',\n transform: paletteTransform\n },\n backgroundColor: {\n themeKey: 'palette',\n transform: paletteTransform\n },\n // spacing\n p: {\n style: padding\n },\n pt: {\n style: padding\n },\n pr: {\n style: padding\n },\n pb: {\n style: padding\n },\n pl: {\n style: padding\n },\n px: {\n style: padding\n },\n py: {\n style: padding\n },\n padding: {\n style: padding\n },\n paddingTop: {\n style: padding\n },\n paddingRight: {\n style: padding\n },\n paddingBottom: {\n style: padding\n },\n paddingLeft: {\n style: padding\n },\n paddingX: {\n style: padding\n },\n paddingY: {\n style: padding\n },\n paddingInline: {\n style: padding\n },\n paddingInlineStart: {\n style: padding\n },\n paddingInlineEnd: {\n style: padding\n },\n paddingBlock: {\n style: padding\n },\n paddingBlockStart: {\n style: padding\n },\n paddingBlockEnd: {\n style: padding\n },\n m: {\n style: margin\n },\n mt: {\n style: margin\n },\n mr: {\n style: margin\n },\n mb: {\n style: margin\n },\n ml: {\n style: margin\n },\n mx: {\n style: margin\n },\n my: {\n style: margin\n },\n margin: {\n style: margin\n },\n marginTop: {\n style: margin\n },\n marginRight: {\n style: margin\n },\n marginBottom: {\n style: margin\n },\n marginLeft: {\n style: margin\n },\n marginX: {\n style: margin\n },\n marginY: {\n style: margin\n },\n marginInline: {\n style: margin\n },\n marginInlineStart: {\n style: margin\n },\n marginInlineEnd: {\n style: margin\n },\n marginBlock: {\n style: margin\n },\n marginBlockStart: {\n style: margin\n },\n marginBlockEnd: {\n style: margin\n },\n // display\n displayPrint: {\n cssProperty: false,\n transform: value => ({\n '@media print': {\n display: value\n }\n })\n },\n display: {},\n overflow: {},\n textOverflow: {},\n visibility: {},\n whiteSpace: {},\n // flexbox\n flexBasis: {},\n flexDirection: {},\n flexWrap: {},\n justifyContent: {},\n alignItems: {},\n alignContent: {},\n order: {},\n flex: {},\n flexGrow: {},\n flexShrink: {},\n alignSelf: {},\n justifyItems: {},\n justifySelf: {},\n // grid\n gap: {\n style: gap\n },\n rowGap: {\n style: rowGap\n },\n columnGap: {\n style: columnGap\n },\n gridColumn: {},\n gridRow: {},\n gridAutoFlow: {},\n gridAutoColumns: {},\n gridAutoRows: {},\n gridTemplateColumns: {},\n gridTemplateRows: {},\n gridTemplateAreas: {},\n gridArea: {},\n // positions\n position: {},\n zIndex: {\n themeKey: 'zIndex'\n },\n top: {},\n right: {},\n bottom: {},\n left: {},\n // shadows\n boxShadow: {\n themeKey: 'shadows'\n },\n // sizing\n width: {\n transform: sizingTransform\n },\n maxWidth: {\n style: maxWidth\n },\n minWidth: {\n transform: sizingTransform\n },\n height: {\n transform: sizingTransform\n },\n maxHeight: {\n transform: sizingTransform\n },\n minHeight: {\n transform: sizingTransform\n },\n boxSizing: {},\n // typography\n fontFamily: {\n themeKey: 'typography'\n },\n fontSize: {\n themeKey: 'typography'\n },\n fontStyle: {\n themeKey: 'typography'\n },\n fontWeight: {\n themeKey: 'typography'\n },\n letterSpacing: {},\n textTransform: {},\n lineHeight: {},\n textAlign: {},\n typography: {\n cssProperty: false,\n themeKey: 'typography'\n }\n};\nexport default defaultSxConfig;","import capitalize from '@mui/utils/capitalize';\nimport merge from '../merge';\nimport { getPath, getStyleValue as getValue } from '../style';\nimport { handleBreakpoints, createEmptyBreakpointObject, removeUnusedBreakpoints } from '../breakpoints';\nimport defaultSxConfig from './defaultSxConfig';\nfunction objectsHaveSameKeys(...objects) {\n const allKeys = objects.reduce((keys, object) => keys.concat(Object.keys(object)), []);\n const union = new Set(allKeys);\n return objects.every(object => union.size === Object.keys(object).length);\n}\nfunction callIfFn(maybeFn, arg) {\n return typeof maybeFn === 'function' ? maybeFn(arg) : maybeFn;\n}\n\n// eslint-disable-next-line @typescript-eslint/naming-convention\nexport function unstable_createStyleFunctionSx() {\n function getThemeValue(prop, val, theme, config) {\n const props = {\n [prop]: val,\n theme\n };\n const options = config[prop];\n if (!options) {\n return {\n [prop]: val\n };\n }\n const {\n cssProperty = prop,\n themeKey,\n transform,\n style\n } = options;\n if (val == null) {\n return null;\n }\n\n // TODO v6: remove, see https://github.com/mui/material-ui/pull/38123\n if (themeKey === 'typography' && val === 'inherit') {\n return {\n [prop]: val\n };\n }\n const themeMapping = getPath(theme, themeKey) || {};\n if (style) {\n return style(props);\n }\n const styleFromPropValue = propValueFinal => {\n let value = getValue(themeMapping, transform, propValueFinal);\n if (propValueFinal === value && typeof propValueFinal === 'string') {\n // Haven't found value\n value = getValue(themeMapping, transform, `${prop}${propValueFinal === 'default' ? '' : capitalize(propValueFinal)}`, propValueFinal);\n }\n if (cssProperty === false) {\n return value;\n }\n return {\n [cssProperty]: value\n };\n };\n return handleBreakpoints(props, val, styleFromPropValue);\n }\n function styleFunctionSx(props) {\n var _theme$unstable_sxCon;\n const {\n sx,\n theme = {}\n } = props || {};\n if (!sx) {\n return null; // Emotion & styled-components will neglect null\n }\n const config = (_theme$unstable_sxCon = theme.unstable_sxConfig) != null ? _theme$unstable_sxCon : defaultSxConfig;\n\n /*\n * Receive `sxInput` as object or callback\n * and then recursively check keys & values to create media query object styles.\n * (the result will be used in `styled`)\n */\n function traverse(sxInput) {\n let sxObject = sxInput;\n if (typeof sxInput === 'function') {\n sxObject = sxInput(theme);\n } else if (typeof sxInput !== 'object') {\n // value\n return sxInput;\n }\n if (!sxObject) {\n return null;\n }\n const emptyBreakpoints = createEmptyBreakpointObject(theme.breakpoints);\n const breakpointsKeys = Object.keys(emptyBreakpoints);\n let css = emptyBreakpoints;\n Object.keys(sxObject).forEach(styleKey => {\n const value = callIfFn(sxObject[styleKey], theme);\n if (value !== null && value !== undefined) {\n if (typeof value === 'object') {\n if (config[styleKey]) {\n css = merge(css, getThemeValue(styleKey, value, theme, config));\n } else {\n const breakpointsValues = handleBreakpoints({\n theme\n }, value, x => ({\n [styleKey]: x\n }));\n if (objectsHaveSameKeys(breakpointsValues, value)) {\n css[styleKey] = styleFunctionSx({\n sx: value,\n theme\n });\n } else {\n css = merge(css, breakpointsValues);\n }\n }\n } else {\n css = merge(css, getThemeValue(styleKey, value, theme, config));\n }\n }\n });\n return removeUnusedBreakpoints(breakpointsKeys, css);\n }\n return Array.isArray(sx) ? sx.map(traverse) : traverse(sx);\n }\n return styleFunctionSx;\n}\nconst styleFunctionSx = unstable_createStyleFunctionSx();\nstyleFunctionSx.filterProps = ['sx'];\nexport default styleFunctionSx;","/**\n * A universal utility to style components with multiple color modes. Always use it from the theme object.\n * It works with:\n * - [Basic theme](https://mui.com/material-ui/customization/dark-mode/)\n * - [CSS theme variables](https://mui.com/material-ui/experimental-api/css-theme-variables/overview/)\n * - Zero-runtime engine\n *\n * Tips: Use an array over object spread and place `theme.applyStyles()` last.\n *\n * ✅ [{ background: '#e5e5e5' }, theme.applyStyles('dark', { background: '#1c1c1c' })]\n *\n * 🚫 { background: '#e5e5e5', ...theme.applyStyles('dark', { background: '#1c1c1c' })}\n *\n * @example\n * 1. using with `styled`:\n * ```jsx\n * const Component = styled('div')(({ theme }) => [\n * { background: '#e5e5e5' },\n * theme.applyStyles('dark', {\n * background: '#1c1c1c',\n * color: '#fff',\n * }),\n * ]);\n * ```\n *\n * @example\n * 2. using with `sx` prop:\n * ```jsx\n * [\n * { background: '#e5e5e5' },\n * theme.applyStyles('dark', {\n * background: '#1c1c1c',\n * color: '#fff',\n * }),\n * ]}\n * />\n * ```\n *\n * @example\n * 3. theming a component:\n * ```jsx\n * extendTheme({\n * components: {\n * MuiButton: {\n * styleOverrides: {\n * root: ({ theme }) => [\n * { background: '#e5e5e5' },\n * theme.applyStyles('dark', {\n * background: '#1c1c1c',\n * color: '#fff',\n * }),\n * ],\n * },\n * }\n * }\n * })\n *```\n */\nexport default function applyStyles(key, styles) {\n // @ts-expect-error this is 'any' type\n const theme = this;\n if (theme.vars && typeof theme.getColorSchemeSelector === 'function') {\n // If CssVarsProvider is used as a provider,\n // returns '* :where([data-mui-color-scheme=\"light|dark\"]) &'\n const selector = theme.getColorSchemeSelector(key).replace(/(\\[[^\\]]+\\])/, '*:where($1)');\n return {\n [selector]: styles\n };\n }\n if (theme.palette.mode === key) {\n return styles;\n }\n return {};\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"breakpoints\", \"palette\", \"spacing\", \"shape\"];\nimport deepmerge from '@mui/utils/deepmerge';\nimport createBreakpoints from './createBreakpoints';\nimport shape from './shape';\nimport createSpacing from './createSpacing';\nimport styleFunctionSx from '../styleFunctionSx/styleFunctionSx';\nimport defaultSxConfig from '../styleFunctionSx/defaultSxConfig';\nimport applyStyles from './applyStyles';\nfunction createTheme(options = {}, ...args) {\n const {\n breakpoints: breakpointsInput = {},\n palette: paletteInput = {},\n spacing: spacingInput,\n shape: shapeInput = {}\n } = options,\n other = _objectWithoutPropertiesLoose(options, _excluded);\n const breakpoints = createBreakpoints(breakpointsInput);\n const spacing = createSpacing(spacingInput);\n let muiTheme = deepmerge({\n breakpoints,\n direction: 'ltr',\n components: {},\n // Inject component definitions.\n palette: _extends({\n mode: 'light'\n }, paletteInput),\n spacing,\n shape: _extends({}, shape, shapeInput)\n }, other);\n muiTheme.applyStyles = applyStyles;\n muiTheme = args.reduce((acc, argument) => deepmerge(acc, argument), muiTheme);\n muiTheme.unstable_sxConfig = _extends({}, defaultSxConfig, other == null ? void 0 : other.unstable_sxConfig);\n muiTheme.unstable_sx = function sx(props) {\n return styleFunctionSx({\n sx: props,\n theme: this\n });\n };\n return muiTheme;\n}\nexport default createTheme;","'use client';\n\nimport * as React from 'react';\nimport { ThemeContext } from '@mui/styled-engine';\nfunction isObjectEmpty(obj) {\n return Object.keys(obj).length === 0;\n}\nfunction useTheme(defaultTheme = null) {\n const contextTheme = React.useContext(ThemeContext);\n return !contextTheme || isObjectEmpty(contextTheme) ? defaultTheme : contextTheme;\n}\nexport default useTheme;","'use client';\n\nimport createTheme from './createTheme';\nimport useThemeWithoutDefault from './useThemeWithoutDefault';\nexport const systemDefaultTheme = createTheme();\nfunction useTheme(defaultTheme = systemDefaultTheme) {\n return useThemeWithoutDefault(defaultTheme);\n}\nexport default useTheme;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"ownerState\"],\n _excluded2 = [\"variants\"],\n _excluded3 = [\"name\", \"slot\", \"skipVariantsResolver\", \"skipSx\", \"overridesResolver\"];\n/* eslint-disable no-underscore-dangle */\nimport styledEngineStyled, { internal_processStyles as processStyles } from '@mui/styled-engine';\nimport { isPlainObject } from '@mui/utils/deepmerge';\nimport capitalize from '@mui/utils/capitalize';\nimport getDisplayName from '@mui/utils/getDisplayName';\nimport createTheme from './createTheme';\nimport styleFunctionSx from './styleFunctionSx';\nfunction isEmpty(obj) {\n return Object.keys(obj).length === 0;\n}\n\n// https://github.com/emotion-js/emotion/blob/26ded6109fcd8ca9875cc2ce4564fee678a3f3c5/packages/styled/src/utils.js#L40\nfunction isStringTag(tag) {\n return typeof tag === 'string' &&\n // 96 is one less than the char code\n // for \"a\" so this is checking that\n // it's a lowercase character\n tag.charCodeAt(0) > 96;\n}\n\n// Update /system/styled/#api in case if this changes\nexport function shouldForwardProp(prop) {\n return prop !== 'ownerState' && prop !== 'theme' && prop !== 'sx' && prop !== 'as';\n}\nexport const systemDefaultTheme = createTheme();\nconst lowercaseFirstLetter = string => {\n if (!string) {\n return string;\n }\n return string.charAt(0).toLowerCase() + string.slice(1);\n};\nfunction resolveTheme({\n defaultTheme,\n theme,\n themeId\n}) {\n return isEmpty(theme) ? defaultTheme : theme[themeId] || theme;\n}\nfunction defaultOverridesResolver(slot) {\n if (!slot) {\n return null;\n }\n return (props, styles) => styles[slot];\n}\nfunction processStyleArg(callableStyle, _ref) {\n let {\n ownerState\n } = _ref,\n props = _objectWithoutPropertiesLoose(_ref, _excluded);\n const resolvedStylesArg = typeof callableStyle === 'function' ? callableStyle(_extends({\n ownerState\n }, props)) : callableStyle;\n if (Array.isArray(resolvedStylesArg)) {\n return resolvedStylesArg.flatMap(resolvedStyle => processStyleArg(resolvedStyle, _extends({\n ownerState\n }, props)));\n }\n if (!!resolvedStylesArg && typeof resolvedStylesArg === 'object' && Array.isArray(resolvedStylesArg.variants)) {\n const {\n variants = []\n } = resolvedStylesArg,\n otherStyles = _objectWithoutPropertiesLoose(resolvedStylesArg, _excluded2);\n let result = otherStyles;\n variants.forEach(variant => {\n let isMatch = true;\n if (typeof variant.props === 'function') {\n isMatch = variant.props(_extends({\n ownerState\n }, props, ownerState));\n } else {\n Object.keys(variant.props).forEach(key => {\n if ((ownerState == null ? void 0 : ownerState[key]) !== variant.props[key] && props[key] !== variant.props[key]) {\n isMatch = false;\n }\n });\n }\n if (isMatch) {\n if (!Array.isArray(result)) {\n result = [result];\n }\n result.push(typeof variant.style === 'function' ? variant.style(_extends({\n ownerState\n }, props, ownerState)) : variant.style);\n }\n });\n return result;\n }\n return resolvedStylesArg;\n}\nexport default function createStyled(input = {}) {\n const {\n themeId,\n defaultTheme = systemDefaultTheme,\n rootShouldForwardProp = shouldForwardProp,\n slotShouldForwardProp = shouldForwardProp\n } = input;\n const systemSx = props => {\n return styleFunctionSx(_extends({}, props, {\n theme: resolveTheme(_extends({}, props, {\n defaultTheme,\n themeId\n }))\n }));\n };\n systemSx.__mui_systemSx = true;\n return (tag, inputOptions = {}) => {\n // Filter out the `sx` style function from the previous styled component to prevent unnecessary styles generated by the composite components.\n processStyles(tag, styles => styles.filter(style => !(style != null && style.__mui_systemSx)));\n const {\n name: componentName,\n slot: componentSlot,\n skipVariantsResolver: inputSkipVariantsResolver,\n skipSx: inputSkipSx,\n // TODO v6: remove `lowercaseFirstLetter()` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n overridesResolver = defaultOverridesResolver(lowercaseFirstLetter(componentSlot))\n } = inputOptions,\n options = _objectWithoutPropertiesLoose(inputOptions, _excluded3);\n\n // if skipVariantsResolver option is defined, take the value, otherwise, true for root and false for other slots.\n const skipVariantsResolver = inputSkipVariantsResolver !== undefined ? inputSkipVariantsResolver :\n // TODO v6: remove `Root` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n componentSlot && componentSlot !== 'Root' && componentSlot !== 'root' || false;\n const skipSx = inputSkipSx || false;\n let label;\n if (process.env.NODE_ENV !== 'production') {\n if (componentName) {\n // TODO v6: remove `lowercaseFirstLetter()` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n label = `${componentName}-${lowercaseFirstLetter(componentSlot || 'Root')}`;\n }\n }\n let shouldForwardPropOption = shouldForwardProp;\n\n // TODO v6: remove `Root` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n if (componentSlot === 'Root' || componentSlot === 'root') {\n shouldForwardPropOption = rootShouldForwardProp;\n } else if (componentSlot) {\n // any other slot specified\n shouldForwardPropOption = slotShouldForwardProp;\n } else if (isStringTag(tag)) {\n // for string (html) tag, preserve the behavior in emotion & styled-components.\n shouldForwardPropOption = undefined;\n }\n const defaultStyledResolver = styledEngineStyled(tag, _extends({\n shouldForwardProp: shouldForwardPropOption,\n label\n }, options));\n const transformStyleArg = stylesArg => {\n // On the server Emotion doesn't use React.forwardRef for creating components, so the created\n // component stays as a function. This condition makes sure that we do not interpolate functions\n // which are basically components used as a selectors.\n if (typeof stylesArg === 'function' && stylesArg.__emotion_real !== stylesArg || isPlainObject(stylesArg)) {\n return props => processStyleArg(stylesArg, _extends({}, props, {\n theme: resolveTheme({\n theme: props.theme,\n defaultTheme,\n themeId\n })\n }));\n }\n return stylesArg;\n };\n const muiStyledResolver = (styleArg, ...expressions) => {\n let transformedStyleArg = transformStyleArg(styleArg);\n const expressionsWithDefaultTheme = expressions ? expressions.map(transformStyleArg) : [];\n if (componentName && overridesResolver) {\n expressionsWithDefaultTheme.push(props => {\n const theme = resolveTheme(_extends({}, props, {\n defaultTheme,\n themeId\n }));\n if (!theme.components || !theme.components[componentName] || !theme.components[componentName].styleOverrides) {\n return null;\n }\n const styleOverrides = theme.components[componentName].styleOverrides;\n const resolvedStyleOverrides = {};\n // TODO: v7 remove iteration and use `resolveStyleArg(styleOverrides[slot])` directly\n Object.entries(styleOverrides).forEach(([slotKey, slotStyle]) => {\n resolvedStyleOverrides[slotKey] = processStyleArg(slotStyle, _extends({}, props, {\n theme\n }));\n });\n return overridesResolver(props, resolvedStyleOverrides);\n });\n }\n if (componentName && !skipVariantsResolver) {\n expressionsWithDefaultTheme.push(props => {\n var _theme$components;\n const theme = resolveTheme(_extends({}, props, {\n defaultTheme,\n themeId\n }));\n const themeVariants = theme == null || (_theme$components = theme.components) == null || (_theme$components = _theme$components[componentName]) == null ? void 0 : _theme$components.variants;\n return processStyleArg({\n variants: themeVariants\n }, _extends({}, props, {\n theme\n }));\n });\n }\n if (!skipSx) {\n expressionsWithDefaultTheme.push(systemSx);\n }\n const numOfCustomFnsApplied = expressionsWithDefaultTheme.length - expressions.length;\n if (Array.isArray(styleArg) && numOfCustomFnsApplied > 0) {\n const placeholders = new Array(numOfCustomFnsApplied).fill('');\n // If the type is array, than we need to add placeholders in the template for the overrides, variants and the sx styles.\n transformedStyleArg = [...styleArg, ...placeholders];\n transformedStyleArg.raw = [...styleArg.raw, ...placeholders];\n }\n const Component = defaultStyledResolver(transformedStyleArg, ...expressionsWithDefaultTheme);\n if (process.env.NODE_ENV !== 'production') {\n let displayName;\n if (componentName) {\n displayName = `${componentName}${capitalize(componentSlot || '')}`;\n }\n if (displayName === undefined) {\n displayName = `Styled(${getDisplayName(tag)})`;\n }\n Component.displayName = displayName;\n }\n if (tag.muiName) {\n Component.muiName = tag.muiName;\n }\n return Component;\n };\n if (defaultStyledResolver.withConfig) {\n muiStyledResolver.withConfig = defaultStyledResolver.withConfig;\n }\n return muiStyledResolver;\n };\n}","import resolveProps from '@mui/utils/resolveProps';\nexport default function getThemeProps(params) {\n const {\n theme,\n name,\n props\n } = params;\n if (!theme || !theme.components || !theme.components[name] || !theme.components[name].defaultProps) {\n return props;\n }\n return resolveProps(theme.components[name].defaultProps, props);\n}","'use client';\n\nimport getThemeProps from './getThemeProps';\nimport useTheme from '../useTheme';\nexport default function useThemeProps({\n props,\n name,\n defaultTheme,\n themeId\n}) {\n let theme = useTheme(defaultTheme);\n if (themeId) {\n theme = theme[themeId] || theme;\n }\n const mergedProps = getThemeProps({\n theme,\n name,\n props\n });\n return mergedProps;\n}","import _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\n/* eslint-disable @typescript-eslint/naming-convention */\nimport clamp from '@mui/utils/clamp';\n/**\n * Returns a number whose value is limited to the given range.\n * @param {number} value The value to be clamped\n * @param {number} min The lower boundary of the output range\n * @param {number} max The upper boundary of the output range\n * @returns {number} A number in the range [min, max]\n */\nfunction clampWrapper(value, min = 0, max = 1) {\n if (process.env.NODE_ENV !== 'production') {\n if (value < min || value > max) {\n console.error(`MUI: The value provided ${value} is out of range [${min}, ${max}].`);\n }\n }\n return clamp(value, min, max);\n}\n\n/**\n * Converts a color from CSS hex format to CSS rgb format.\n * @param {string} color - Hex color, i.e. #nnn or #nnnnnn\n * @returns {string} A CSS rgb color string\n */\nexport function hexToRgb(color) {\n color = color.slice(1);\n const re = new RegExp(`.{1,${color.length >= 6 ? 2 : 1}}`, 'g');\n let colors = color.match(re);\n if (colors && colors[0].length === 1) {\n colors = colors.map(n => n + n);\n }\n return colors ? `rgb${colors.length === 4 ? 'a' : ''}(${colors.map((n, index) => {\n return index < 3 ? parseInt(n, 16) : Math.round(parseInt(n, 16) / 255 * 1000) / 1000;\n }).join(', ')})` : '';\n}\nfunction intToHex(int) {\n const hex = int.toString(16);\n return hex.length === 1 ? `0${hex}` : hex;\n}\n\n/**\n * Returns an object with the type and values of a color.\n *\n * Note: Does not support rgb % values.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @returns {object} - A MUI color object: {type: string, values: number[]}\n */\nexport function decomposeColor(color) {\n // Idempotent\n if (color.type) {\n return color;\n }\n if (color.charAt(0) === '#') {\n return decomposeColor(hexToRgb(color));\n }\n const marker = color.indexOf('(');\n const type = color.substring(0, marker);\n if (['rgb', 'rgba', 'hsl', 'hsla', 'color'].indexOf(type) === -1) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: Unsupported \\`${color}\\` color.\nThe following formats are supported: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color().` : _formatMuiErrorMessage(9, color));\n }\n let values = color.substring(marker + 1, color.length - 1);\n let colorSpace;\n if (type === 'color') {\n values = values.split(' ');\n colorSpace = values.shift();\n if (values.length === 4 && values[3].charAt(0) === '/') {\n values[3] = values[3].slice(1);\n }\n if (['srgb', 'display-p3', 'a98-rgb', 'prophoto-rgb', 'rec-2020'].indexOf(colorSpace) === -1) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: unsupported \\`${colorSpace}\\` color space.\nThe following color spaces are supported: srgb, display-p3, a98-rgb, prophoto-rgb, rec-2020.` : _formatMuiErrorMessage(10, colorSpace));\n }\n } else {\n values = values.split(',');\n }\n values = values.map(value => parseFloat(value));\n return {\n type,\n values,\n colorSpace\n };\n}\n\n/**\n * Returns a channel created from the input color.\n *\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @returns {string} - The channel for the color, that can be used in rgba or hsla colors\n */\nexport const colorChannel = color => {\n const decomposedColor = decomposeColor(color);\n return decomposedColor.values.slice(0, 3).map((val, idx) => decomposedColor.type.indexOf('hsl') !== -1 && idx !== 0 ? `${val}%` : val).join(' ');\n};\nexport const private_safeColorChannel = (color, warning) => {\n try {\n return colorChannel(color);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n};\n\n/**\n * Converts a color object with type and values to a string.\n * @param {object} color - Decomposed color\n * @param {string} color.type - One of: 'rgb', 'rgba', 'hsl', 'hsla', 'color'\n * @param {array} color.values - [n,n,n] or [n,n,n,n]\n * @returns {string} A CSS color string\n */\nexport function recomposeColor(color) {\n const {\n type,\n colorSpace\n } = color;\n let {\n values\n } = color;\n if (type.indexOf('rgb') !== -1) {\n // Only convert the first 3 values to int (i.e. not alpha)\n values = values.map((n, i) => i < 3 ? parseInt(n, 10) : n);\n } else if (type.indexOf('hsl') !== -1) {\n values[1] = `${values[1]}%`;\n values[2] = `${values[2]}%`;\n }\n if (type.indexOf('color') !== -1) {\n values = `${colorSpace} ${values.join(' ')}`;\n } else {\n values = `${values.join(', ')}`;\n }\n return `${type}(${values})`;\n}\n\n/**\n * Converts a color from CSS rgb format to CSS hex format.\n * @param {string} color - RGB color, i.e. rgb(n, n, n)\n * @returns {string} A CSS rgb color string, i.e. #nnnnnn\n */\nexport function rgbToHex(color) {\n // Idempotent\n if (color.indexOf('#') === 0) {\n return color;\n }\n const {\n values\n } = decomposeColor(color);\n return `#${values.map((n, i) => intToHex(i === 3 ? Math.round(255 * n) : n)).join('')}`;\n}\n\n/**\n * Converts a color from hsl format to rgb format.\n * @param {string} color - HSL color values\n * @returns {string} rgb color values\n */\nexport function hslToRgb(color) {\n color = decomposeColor(color);\n const {\n values\n } = color;\n const h = values[0];\n const s = values[1] / 100;\n const l = values[2] / 100;\n const a = s * Math.min(l, 1 - l);\n const f = (n, k = (n + h / 30) % 12) => l - a * Math.max(Math.min(k - 3, 9 - k, 1), -1);\n let type = 'rgb';\n const rgb = [Math.round(f(0) * 255), Math.round(f(8) * 255), Math.round(f(4) * 255)];\n if (color.type === 'hsla') {\n type += 'a';\n rgb.push(values[3]);\n }\n return recomposeColor({\n type,\n values: rgb\n });\n}\n/**\n * The relative brightness of any point in a color space,\n * normalized to 0 for darkest black and 1 for lightest white.\n *\n * Formula: https://www.w3.org/TR/WCAG20-TECHS/G17.html#G17-tests\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @returns {number} The relative brightness of the color in the range 0 - 1\n */\nexport function getLuminance(color) {\n color = decomposeColor(color);\n let rgb = color.type === 'hsl' || color.type === 'hsla' ? decomposeColor(hslToRgb(color)).values : color.values;\n rgb = rgb.map(val => {\n if (color.type !== 'color') {\n val /= 255; // normalized\n }\n return val <= 0.03928 ? val / 12.92 : ((val + 0.055) / 1.055) ** 2.4;\n });\n\n // Truncate at 3 digits\n return Number((0.2126 * rgb[0] + 0.7152 * rgb[1] + 0.0722 * rgb[2]).toFixed(3));\n}\n\n/**\n * Calculates the contrast ratio between two colors.\n *\n * Formula: https://www.w3.org/TR/WCAG20-TECHS/G17.html#G17-tests\n * @param {string} foreground - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla()\n * @param {string} background - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla()\n * @returns {number} A contrast ratio value in the range 0 - 21.\n */\nexport function getContrastRatio(foreground, background) {\n const lumA = getLuminance(foreground);\n const lumB = getLuminance(background);\n return (Math.max(lumA, lumB) + 0.05) / (Math.min(lumA, lumB) + 0.05);\n}\n\n/**\n * Sets the absolute transparency of a color.\n * Any existing alpha values are overwritten.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} value - value to set the alpha channel to in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function alpha(color, value) {\n color = decomposeColor(color);\n value = clampWrapper(value);\n if (color.type === 'rgb' || color.type === 'hsl') {\n color.type += 'a';\n }\n if (color.type === 'color') {\n color.values[3] = `/${value}`;\n } else {\n color.values[3] = value;\n }\n return recomposeColor(color);\n}\nexport function private_safeAlpha(color, value, warning) {\n try {\n return alpha(color, value);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Darkens a color.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} coefficient - multiplier in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function darken(color, coefficient) {\n color = decomposeColor(color);\n coefficient = clampWrapper(coefficient);\n if (color.type.indexOf('hsl') !== -1) {\n color.values[2] *= 1 - coefficient;\n } else if (color.type.indexOf('rgb') !== -1 || color.type.indexOf('color') !== -1) {\n for (let i = 0; i < 3; i += 1) {\n color.values[i] *= 1 - coefficient;\n }\n }\n return recomposeColor(color);\n}\nexport function private_safeDarken(color, coefficient, warning) {\n try {\n return darken(color, coefficient);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Lightens a color.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} coefficient - multiplier in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function lighten(color, coefficient) {\n color = decomposeColor(color);\n coefficient = clampWrapper(coefficient);\n if (color.type.indexOf('hsl') !== -1) {\n color.values[2] += (100 - color.values[2]) * coefficient;\n } else if (color.type.indexOf('rgb') !== -1) {\n for (let i = 0; i < 3; i += 1) {\n color.values[i] += (255 - color.values[i]) * coefficient;\n }\n } else if (color.type.indexOf('color') !== -1) {\n for (let i = 0; i < 3; i += 1) {\n color.values[i] += (1 - color.values[i]) * coefficient;\n }\n }\n return recomposeColor(color);\n}\nexport function private_safeLighten(color, coefficient, warning) {\n try {\n return lighten(color, coefficient);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Darken or lighten a color, depending on its luminance.\n * Light colors are darkened, dark colors are lightened.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} coefficient=0.15 - multiplier in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function emphasize(color, coefficient = 0.15) {\n return getLuminance(color) > 0.5 ? darken(color, coefficient) : lighten(color, coefficient);\n}\nexport function private_safeEmphasize(color, coefficient, warning) {\n try {\n return emphasize(color, coefficient);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Blend a transparent overlay color with a background color, resulting in a single\n * RGB color.\n * @param {string} background - CSS color\n * @param {string} overlay - CSS color\n * @param {number} opacity - Opacity multiplier in the range 0 - 1\n * @param {number} [gamma=1.0] - Gamma correction factor. For gamma-correct blending, 2.2 is usual.\n */\nexport function blend(background, overlay, opacity, gamma = 1.0) {\n const blendChannel = (b, o) => Math.round((b ** (1 / gamma) * (1 - opacity) + o ** (1 / gamma) * opacity) ** gamma);\n const backgroundColor = decomposeColor(background);\n const overlayColor = decomposeColor(overlay);\n const rgb = [blendChannel(backgroundColor.values[0], overlayColor.values[0]), blendChannel(backgroundColor.values[1], overlayColor.values[1]), blendChannel(backgroundColor.values[2], overlayColor.values[2])];\n return recomposeColor({\n type: 'rgb',\n values: rgb\n });\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nexport default function createMixins(breakpoints, mixins) {\n return _extends({\n toolbar: {\n minHeight: 56,\n [breakpoints.up('xs')]: {\n '@media (orientation: landscape)': {\n minHeight: 48\n }\n },\n [breakpoints.up('sm')]: {\n minHeight: 64\n }\n }\n }, mixins);\n}","const common = {\n black: '#000',\n white: '#fff'\n};\nexport default common;","const grey = {\n 50: '#fafafa',\n 100: '#f5f5f5',\n 200: '#eeeeee',\n 300: '#e0e0e0',\n 400: '#bdbdbd',\n 500: '#9e9e9e',\n 600: '#757575',\n 700: '#616161',\n 800: '#424242',\n 900: '#212121',\n A100: '#f5f5f5',\n A200: '#eeeeee',\n A400: '#bdbdbd',\n A700: '#616161'\n};\nexport default grey;","const purple = {\n 50: '#f3e5f5',\n 100: '#e1bee7',\n 200: '#ce93d8',\n 300: '#ba68c8',\n 400: '#ab47bc',\n 500: '#9c27b0',\n 600: '#8e24aa',\n 700: '#7b1fa2',\n 800: '#6a1b9a',\n 900: '#4a148c',\n A100: '#ea80fc',\n A200: '#e040fb',\n A400: '#d500f9',\n A700: '#aa00ff'\n};\nexport default purple;","const red = {\n 50: '#ffebee',\n 100: '#ffcdd2',\n 200: '#ef9a9a',\n 300: '#e57373',\n 400: '#ef5350',\n 500: '#f44336',\n 600: '#e53935',\n 700: '#d32f2f',\n 800: '#c62828',\n 900: '#b71c1c',\n A100: '#ff8a80',\n A200: '#ff5252',\n A400: '#ff1744',\n A700: '#d50000'\n};\nexport default red;","const orange = {\n 50: '#fff3e0',\n 100: '#ffe0b2',\n 200: '#ffcc80',\n 300: '#ffb74d',\n 400: '#ffa726',\n 500: '#ff9800',\n 600: '#fb8c00',\n 700: '#f57c00',\n 800: '#ef6c00',\n 900: '#e65100',\n A100: '#ffd180',\n A200: '#ffab40',\n A400: '#ff9100',\n A700: '#ff6d00'\n};\nexport default orange;","const blue = {\n 50: '#e3f2fd',\n 100: '#bbdefb',\n 200: '#90caf9',\n 300: '#64b5f6',\n 400: '#42a5f5',\n 500: '#2196f3',\n 600: '#1e88e5',\n 700: '#1976d2',\n 800: '#1565c0',\n 900: '#0d47a1',\n A100: '#82b1ff',\n A200: '#448aff',\n A400: '#2979ff',\n A700: '#2962ff'\n};\nexport default blue;","const lightBlue = {\n 50: '#e1f5fe',\n 100: '#b3e5fc',\n 200: '#81d4fa',\n 300: '#4fc3f7',\n 400: '#29b6f6',\n 500: '#03a9f4',\n 600: '#039be5',\n 700: '#0288d1',\n 800: '#0277bd',\n 900: '#01579b',\n A100: '#80d8ff',\n A200: '#40c4ff',\n A400: '#00b0ff',\n A700: '#0091ea'\n};\nexport default lightBlue;","const green = {\n 50: '#e8f5e9',\n 100: '#c8e6c9',\n 200: '#a5d6a7',\n 300: '#81c784',\n 400: '#66bb6a',\n 500: '#4caf50',\n 600: '#43a047',\n 700: '#388e3c',\n 800: '#2e7d32',\n 900: '#1b5e20',\n A100: '#b9f6ca',\n A200: '#69f0ae',\n A400: '#00e676',\n A700: '#00c853'\n};\nexport default green;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\nconst _excluded = [\"mode\", \"contrastThreshold\", \"tonalOffset\"];\nimport { deepmerge } from '@mui/utils';\nimport { darken, getContrastRatio, lighten } from '@mui/system';\nimport common from '../colors/common';\nimport grey from '../colors/grey';\nimport purple from '../colors/purple';\nimport red from '../colors/red';\nimport orange from '../colors/orange';\nimport blue from '../colors/blue';\nimport lightBlue from '../colors/lightBlue';\nimport green from '../colors/green';\nexport const light = {\n // The colors used to style the text.\n text: {\n // The most important text.\n primary: 'rgba(0, 0, 0, 0.87)',\n // Secondary text.\n secondary: 'rgba(0, 0, 0, 0.6)',\n // Disabled text have even lower visual prominence.\n disabled: 'rgba(0, 0, 0, 0.38)'\n },\n // The color used to divide different elements.\n divider: 'rgba(0, 0, 0, 0.12)',\n // The background colors used to style the surfaces.\n // Consistency between these values is important.\n background: {\n paper: common.white,\n default: common.white\n },\n // The colors used to style the action elements.\n action: {\n // The color of an active action like an icon button.\n active: 'rgba(0, 0, 0, 0.54)',\n // The color of an hovered action.\n hover: 'rgba(0, 0, 0, 0.04)',\n hoverOpacity: 0.04,\n // The color of a selected action.\n selected: 'rgba(0, 0, 0, 0.08)',\n selectedOpacity: 0.08,\n // The color of a disabled action.\n disabled: 'rgba(0, 0, 0, 0.26)',\n // The background color of a disabled action.\n disabledBackground: 'rgba(0, 0, 0, 0.12)',\n disabledOpacity: 0.38,\n focus: 'rgba(0, 0, 0, 0.12)',\n focusOpacity: 0.12,\n activatedOpacity: 0.12\n }\n};\nexport const dark = {\n text: {\n primary: common.white,\n secondary: 'rgba(255, 255, 255, 0.7)',\n disabled: 'rgba(255, 255, 255, 0.5)',\n icon: 'rgba(255, 255, 255, 0.5)'\n },\n divider: 'rgba(255, 255, 255, 0.12)',\n background: {\n paper: '#121212',\n default: '#121212'\n },\n action: {\n active: common.white,\n hover: 'rgba(255, 255, 255, 0.08)',\n hoverOpacity: 0.08,\n selected: 'rgba(255, 255, 255, 0.16)',\n selectedOpacity: 0.16,\n disabled: 'rgba(255, 255, 255, 0.3)',\n disabledBackground: 'rgba(255, 255, 255, 0.12)',\n disabledOpacity: 0.38,\n focus: 'rgba(255, 255, 255, 0.12)',\n focusOpacity: 0.12,\n activatedOpacity: 0.24\n }\n};\nfunction addLightOrDark(intent, direction, shade, tonalOffset) {\n const tonalOffsetLight = tonalOffset.light || tonalOffset;\n const tonalOffsetDark = tonalOffset.dark || tonalOffset * 1.5;\n if (!intent[direction]) {\n if (intent.hasOwnProperty(shade)) {\n intent[direction] = intent[shade];\n } else if (direction === 'light') {\n intent.light = lighten(intent.main, tonalOffsetLight);\n } else if (direction === 'dark') {\n intent.dark = darken(intent.main, tonalOffsetDark);\n }\n }\n}\nfunction getDefaultPrimary(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: blue[200],\n light: blue[50],\n dark: blue[400]\n };\n }\n return {\n main: blue[700],\n light: blue[400],\n dark: blue[800]\n };\n}\nfunction getDefaultSecondary(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: purple[200],\n light: purple[50],\n dark: purple[400]\n };\n }\n return {\n main: purple[500],\n light: purple[300],\n dark: purple[700]\n };\n}\nfunction getDefaultError(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: red[500],\n light: red[300],\n dark: red[700]\n };\n }\n return {\n main: red[700],\n light: red[400],\n dark: red[800]\n };\n}\nfunction getDefaultInfo(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: lightBlue[400],\n light: lightBlue[300],\n dark: lightBlue[700]\n };\n }\n return {\n main: lightBlue[700],\n light: lightBlue[500],\n dark: lightBlue[900]\n };\n}\nfunction getDefaultSuccess(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: green[400],\n light: green[300],\n dark: green[700]\n };\n }\n return {\n main: green[800],\n light: green[500],\n dark: green[900]\n };\n}\nfunction getDefaultWarning(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: orange[400],\n light: orange[300],\n dark: orange[700]\n };\n }\n return {\n main: '#ed6c02',\n // closest to orange[800] that pass 3:1.\n light: orange[500],\n dark: orange[900]\n };\n}\nexport default function createPalette(palette) {\n const {\n mode = 'light',\n contrastThreshold = 3,\n tonalOffset = 0.2\n } = palette,\n other = _objectWithoutPropertiesLoose(palette, _excluded);\n const primary = palette.primary || getDefaultPrimary(mode);\n const secondary = palette.secondary || getDefaultSecondary(mode);\n const error = palette.error || getDefaultError(mode);\n const info = palette.info || getDefaultInfo(mode);\n const success = palette.success || getDefaultSuccess(mode);\n const warning = palette.warning || getDefaultWarning(mode);\n\n // Use the same logic as\n // Bootstrap: https://github.com/twbs/bootstrap/blob/1d6e3710dd447de1a200f29e8fa521f8a0908f70/scss/_functions.scss#L59\n // and material-components-web https://github.com/material-components/material-components-web/blob/ac46b8863c4dab9fc22c4c662dc6bd1b65dd652f/packages/mdc-theme/_functions.scss#L54\n function getContrastText(background) {\n const contrastText = getContrastRatio(background, dark.text.primary) >= contrastThreshold ? dark.text.primary : light.text.primary;\n if (process.env.NODE_ENV !== 'production') {\n const contrast = getContrastRatio(background, contrastText);\n if (contrast < 3) {\n console.error([`MUI: The contrast ratio of ${contrast}:1 for ${contrastText} on ${background}`, 'falls below the WCAG recommended absolute minimum contrast ratio of 3:1.', 'https://www.w3.org/TR/2008/REC-WCAG20-20081211/#visual-audio-contrast-contrast'].join('\\n'));\n }\n }\n return contrastText;\n }\n const augmentColor = ({\n color,\n name,\n mainShade = 500,\n lightShade = 300,\n darkShade = 700\n }) => {\n color = _extends({}, color);\n if (!color.main && color[mainShade]) {\n color.main = color[mainShade];\n }\n if (!color.hasOwnProperty('main')) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: The color${name ? ` (${name})` : ''} provided to augmentColor(color) is invalid.\nThe color object needs to have a \\`main\\` property or a \\`${mainShade}\\` property.` : _formatMuiErrorMessage(11, name ? ` (${name})` : '', mainShade));\n }\n if (typeof color.main !== 'string') {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: The color${name ? ` (${name})` : ''} provided to augmentColor(color) is invalid.\n\\`color.main\\` should be a string, but \\`${JSON.stringify(color.main)}\\` was provided instead.\n\nDid you intend to use one of the following approaches?\n\nimport { green } from \"@mui/material/colors\";\n\nconst theme1 = createTheme({ palette: {\n primary: green,\n} });\n\nconst theme2 = createTheme({ palette: {\n primary: { main: green[500] },\n} });` : _formatMuiErrorMessage(12, name ? ` (${name})` : '', JSON.stringify(color.main)));\n }\n addLightOrDark(color, 'light', lightShade, tonalOffset);\n addLightOrDark(color, 'dark', darkShade, tonalOffset);\n if (!color.contrastText) {\n color.contrastText = getContrastText(color.main);\n }\n return color;\n };\n const modes = {\n dark,\n light\n };\n if (process.env.NODE_ENV !== 'production') {\n if (!modes[mode]) {\n console.error(`MUI: The palette mode \\`${mode}\\` is not supported.`);\n }\n }\n const paletteOutput = deepmerge(_extends({\n // A collection of common colors.\n common: _extends({}, common),\n // prevent mutable object.\n // The palette mode, can be light or dark.\n mode,\n // The colors used to represent primary interface elements for a user.\n primary: augmentColor({\n color: primary,\n name: 'primary'\n }),\n // The colors used to represent secondary interface elements for a user.\n secondary: augmentColor({\n color: secondary,\n name: 'secondary',\n mainShade: 'A400',\n lightShade: 'A200',\n darkShade: 'A700'\n }),\n // The colors used to represent interface elements that the user should be made aware of.\n error: augmentColor({\n color: error,\n name: 'error'\n }),\n // The colors used to represent potentially dangerous actions or important messages.\n warning: augmentColor({\n color: warning,\n name: 'warning'\n }),\n // The colors used to present information to the user that is neutral and not necessarily important.\n info: augmentColor({\n color: info,\n name: 'info'\n }),\n // The colors used to indicate the successful completion of an action that user triggered.\n success: augmentColor({\n color: success,\n name: 'success'\n }),\n // The grey colors.\n grey,\n // Used by `getContrastText()` to maximize the contrast between\n // the background and the text.\n contrastThreshold,\n // Takes a background color and returns the text color that maximizes the contrast.\n getContrastText,\n // Generate a rich color object.\n augmentColor,\n // Used by the functions below to shift a color's luminance by approximately\n // two indexes within its tonal palette.\n // E.g., shift from Red 500 to Red 300 or Red 700.\n tonalOffset\n }, modes[mode]), other);\n return paletteOutput;\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"fontFamily\", \"fontSize\", \"fontWeightLight\", \"fontWeightRegular\", \"fontWeightMedium\", \"fontWeightBold\", \"htmlFontSize\", \"allVariants\", \"pxToRem\"];\nimport { deepmerge } from '@mui/utils';\nfunction round(value) {\n return Math.round(value * 1e5) / 1e5;\n}\nconst caseAllCaps = {\n textTransform: 'uppercase'\n};\nconst defaultFontFamily = '\"Roboto\", \"Helvetica\", \"Arial\", sans-serif';\n\n/**\n * @see @link{https://m2.material.io/design/typography/the-type-system.html}\n * @see @link{https://m2.material.io/design/typography/understanding-typography.html}\n */\nexport default function createTypography(palette, typography) {\n const _ref = typeof typography === 'function' ? typography(palette) : typography,\n {\n fontFamily = defaultFontFamily,\n // The default font size of the Material Specification.\n fontSize = 14,\n // px\n fontWeightLight = 300,\n fontWeightRegular = 400,\n fontWeightMedium = 500,\n fontWeightBold = 700,\n // Tell MUI what's the font-size on the html element.\n // 16px is the default font-size used by browsers.\n htmlFontSize = 16,\n // Apply the CSS properties to all the variants.\n allVariants,\n pxToRem: pxToRem2\n } = _ref,\n other = _objectWithoutPropertiesLoose(_ref, _excluded);\n if (process.env.NODE_ENV !== 'production') {\n if (typeof fontSize !== 'number') {\n console.error('MUI: `fontSize` is required to be a number.');\n }\n if (typeof htmlFontSize !== 'number') {\n console.error('MUI: `htmlFontSize` is required to be a number.');\n }\n }\n const coef = fontSize / 14;\n const pxToRem = pxToRem2 || (size => `${size / htmlFontSize * coef}rem`);\n const buildVariant = (fontWeight, size, lineHeight, letterSpacing, casing) => _extends({\n fontFamily,\n fontWeight,\n fontSize: pxToRem(size),\n // Unitless following https://meyerweb.com/eric/thoughts/2006/02/08/unitless-line-heights/\n lineHeight\n }, fontFamily === defaultFontFamily ? {\n letterSpacing: `${round(letterSpacing / size)}em`\n } : {}, casing, allVariants);\n const variants = {\n h1: buildVariant(fontWeightLight, 96, 1.167, -1.5),\n h2: buildVariant(fontWeightLight, 60, 1.2, -0.5),\n h3: buildVariant(fontWeightRegular, 48, 1.167, 0),\n h4: buildVariant(fontWeightRegular, 34, 1.235, 0.25),\n h5: buildVariant(fontWeightRegular, 24, 1.334, 0),\n h6: buildVariant(fontWeightMedium, 20, 1.6, 0.15),\n subtitle1: buildVariant(fontWeightRegular, 16, 1.75, 0.15),\n subtitle2: buildVariant(fontWeightMedium, 14, 1.57, 0.1),\n body1: buildVariant(fontWeightRegular, 16, 1.5, 0.15),\n body2: buildVariant(fontWeightRegular, 14, 1.43, 0.15),\n button: buildVariant(fontWeightMedium, 14, 1.75, 0.4, caseAllCaps),\n caption: buildVariant(fontWeightRegular, 12, 1.66, 0.4),\n overline: buildVariant(fontWeightRegular, 12, 2.66, 1, caseAllCaps),\n // TODO v6: Remove handling of 'inherit' variant from the theme as it is already handled in Material UI's Typography component. Also, remember to remove the associated types.\n inherit: {\n fontFamily: 'inherit',\n fontWeight: 'inherit',\n fontSize: 'inherit',\n lineHeight: 'inherit',\n letterSpacing: 'inherit'\n }\n };\n return deepmerge(_extends({\n htmlFontSize,\n pxToRem,\n fontFamily,\n fontSize,\n fontWeightLight,\n fontWeightRegular,\n fontWeightMedium,\n fontWeightBold\n }, variants), other, {\n clone: false // No need to clone deep\n });\n}","const shadowKeyUmbraOpacity = 0.2;\nconst shadowKeyPenumbraOpacity = 0.14;\nconst shadowAmbientShadowOpacity = 0.12;\nfunction createShadow(...px) {\n return [`${px[0]}px ${px[1]}px ${px[2]}px ${px[3]}px rgba(0,0,0,${shadowKeyUmbraOpacity})`, `${px[4]}px ${px[5]}px ${px[6]}px ${px[7]}px rgba(0,0,0,${shadowKeyPenumbraOpacity})`, `${px[8]}px ${px[9]}px ${px[10]}px ${px[11]}px rgba(0,0,0,${shadowAmbientShadowOpacity})`].join(',');\n}\n\n// Values from https://github.com/material-components/material-components-web/blob/be8747f94574669cb5e7add1a7c54fa41a89cec7/packages/mdc-elevation/_variables.scss\nconst shadows = ['none', createShadow(0, 2, 1, -1, 0, 1, 1, 0, 0, 1, 3, 0), createShadow(0, 3, 1, -2, 0, 2, 2, 0, 0, 1, 5, 0), createShadow(0, 3, 3, -2, 0, 3, 4, 0, 0, 1, 8, 0), createShadow(0, 2, 4, -1, 0, 4, 5, 0, 0, 1, 10, 0), createShadow(0, 3, 5, -1, 0, 5, 8, 0, 0, 1, 14, 0), createShadow(0, 3, 5, -1, 0, 6, 10, 0, 0, 1, 18, 0), createShadow(0, 4, 5, -2, 0, 7, 10, 1, 0, 2, 16, 1), createShadow(0, 5, 5, -3, 0, 8, 10, 1, 0, 3, 14, 2), createShadow(0, 5, 6, -3, 0, 9, 12, 1, 0, 3, 16, 2), createShadow(0, 6, 6, -3, 0, 10, 14, 1, 0, 4, 18, 3), createShadow(0, 6, 7, -4, 0, 11, 15, 1, 0, 4, 20, 3), createShadow(0, 7, 8, -4, 0, 12, 17, 2, 0, 5, 22, 4), createShadow(0, 7, 8, -4, 0, 13, 19, 2, 0, 5, 24, 4), createShadow(0, 7, 9, -4, 0, 14, 21, 2, 0, 5, 26, 4), createShadow(0, 8, 9, -5, 0, 15, 22, 2, 0, 6, 28, 5), createShadow(0, 8, 10, -5, 0, 16, 24, 2, 0, 6, 30, 5), createShadow(0, 8, 11, -5, 0, 17, 26, 2, 0, 6, 32, 5), createShadow(0, 9, 11, -5, 0, 18, 28, 2, 0, 7, 34, 6), createShadow(0, 9, 12, -6, 0, 19, 29, 2, 0, 7, 36, 6), createShadow(0, 10, 13, -6, 0, 20, 31, 3, 0, 8, 38, 7), createShadow(0, 10, 13, -6, 0, 21, 33, 3, 0, 8, 40, 7), createShadow(0, 10, 14, -6, 0, 22, 35, 3, 0, 8, 42, 7), createShadow(0, 11, 14, -7, 0, 23, 36, 3, 0, 9, 44, 8), createShadow(0, 11, 15, -7, 0, 24, 38, 3, 0, 9, 46, 8)];\nexport default shadows;","import _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nconst _excluded = [\"duration\", \"easing\", \"delay\"];\n// Follow https://material.google.com/motion/duration-easing.html#duration-easing-natural-easing-curves\n// to learn the context in which each easing should be used.\nexport const easing = {\n // This is the most common easing curve.\n easeInOut: 'cubic-bezier(0.4, 0, 0.2, 1)',\n // Objects enter the screen at full velocity from off-screen and\n // slowly decelerate to a resting point.\n easeOut: 'cubic-bezier(0.0, 0, 0.2, 1)',\n // Objects leave the screen at full velocity. They do not decelerate when off-screen.\n easeIn: 'cubic-bezier(0.4, 0, 1, 1)',\n // The sharp curve is used by objects that may return to the screen at any time.\n sharp: 'cubic-bezier(0.4, 0, 0.6, 1)'\n};\n\n// Follow https://m2.material.io/guidelines/motion/duration-easing.html#duration-easing-common-durations\n// to learn when use what timing\nexport const duration = {\n shortest: 150,\n shorter: 200,\n short: 250,\n // most basic recommended timing\n standard: 300,\n // this is to be used in complex animations\n complex: 375,\n // recommended when something is entering screen\n enteringScreen: 225,\n // recommended when something is leaving screen\n leavingScreen: 195\n};\nfunction formatMs(milliseconds) {\n return `${Math.round(milliseconds)}ms`;\n}\nfunction getAutoHeightDuration(height) {\n if (!height) {\n return 0;\n }\n const constant = height / 36;\n\n // https://www.wolframalpha.com/input/?i=(4+%2B+15+*+(x+%2F+36+)+**+0.25+%2B+(x+%2F+36)+%2F+5)+*+10\n return Math.round((4 + 15 * constant ** 0.25 + constant / 5) * 10);\n}\nexport default function createTransitions(inputTransitions) {\n const mergedEasing = _extends({}, easing, inputTransitions.easing);\n const mergedDuration = _extends({}, duration, inputTransitions.duration);\n const create = (props = ['all'], options = {}) => {\n const {\n duration: durationOption = mergedDuration.standard,\n easing: easingOption = mergedEasing.easeInOut,\n delay = 0\n } = options,\n other = _objectWithoutPropertiesLoose(options, _excluded);\n if (process.env.NODE_ENV !== 'production') {\n const isString = value => typeof value === 'string';\n // IE11 support, replace with Number.isNaN\n // eslint-disable-next-line no-restricted-globals\n const isNumber = value => !isNaN(parseFloat(value));\n if (!isString(props) && !Array.isArray(props)) {\n console.error('MUI: Argument \"props\" must be a string or Array.');\n }\n if (!isNumber(durationOption) && !isString(durationOption)) {\n console.error(`MUI: Argument \"duration\" must be a number or a string but found ${durationOption}.`);\n }\n if (!isString(easingOption)) {\n console.error('MUI: Argument \"easing\" must be a string.');\n }\n if (!isNumber(delay) && !isString(delay)) {\n console.error('MUI: Argument \"delay\" must be a number or a string.');\n }\n if (typeof options !== 'object') {\n console.error(['MUI: Secong argument of transition.create must be an object.', \"Arguments should be either `create('prop1', options)` or `create(['prop1', 'prop2'], options)`\"].join('\\n'));\n }\n if (Object.keys(other).length !== 0) {\n console.error(`MUI: Unrecognized argument(s) [${Object.keys(other).join(',')}].`);\n }\n }\n return (Array.isArray(props) ? props : [props]).map(animatedProp => `${animatedProp} ${typeof durationOption === 'string' ? durationOption : formatMs(durationOption)} ${easingOption} ${typeof delay === 'string' ? delay : formatMs(delay)}`).join(',');\n };\n return _extends({\n getAutoHeightDuration,\n create\n }, inputTransitions, {\n easing: mergedEasing,\n duration: mergedDuration\n });\n}","// We need to centralize the zIndex definitions as they work\n// like global values in the browser.\nconst zIndex = {\n mobileStepper: 1000,\n fab: 1050,\n speedDial: 1050,\n appBar: 1100,\n drawer: 1200,\n modal: 1300,\n snackbar: 1400,\n tooltip: 1500\n};\nexport default zIndex;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\nconst _excluded = [\"breakpoints\", \"mixins\", \"spacing\", \"palette\", \"transitions\", \"typography\", \"shape\"];\nimport { deepmerge } from '@mui/utils';\nimport { createTheme as systemCreateTheme, unstable_defaultSxConfig as defaultSxConfig, unstable_styleFunctionSx as styleFunctionSx } from '@mui/system';\nimport generateUtilityClass from '@mui/utils/generateUtilityClass';\nimport createMixins from './createMixins';\nimport createPalette from './createPalette';\nimport createTypography from './createTypography';\nimport shadows from './shadows';\nimport createTransitions from './createTransitions';\nimport zIndex from './zIndex';\nfunction createTheme(options = {}, ...args) {\n const {\n mixins: mixinsInput = {},\n palette: paletteInput = {},\n transitions: transitionsInput = {},\n typography: typographyInput = {}\n } = options,\n other = _objectWithoutPropertiesLoose(options, _excluded);\n if (options.vars) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: \\`vars\\` is a private field used for CSS variables support.\nPlease use another name.` : _formatMuiErrorMessage(18));\n }\n const palette = createPalette(paletteInput);\n const systemTheme = systemCreateTheme(options);\n let muiTheme = deepmerge(systemTheme, {\n mixins: createMixins(systemTheme.breakpoints, mixinsInput),\n palette,\n // Don't use [...shadows] until you've verified its transpiled code is not invoking the iterator protocol.\n shadows: shadows.slice(),\n typography: createTypography(palette, typographyInput),\n transitions: createTransitions(transitionsInput),\n zIndex: _extends({}, zIndex)\n });\n muiTheme = deepmerge(muiTheme, other);\n muiTheme = args.reduce((acc, argument) => deepmerge(acc, argument), muiTheme);\n if (process.env.NODE_ENV !== 'production') {\n // TODO v6: Refactor to use globalStateClassesMapping from @mui/utils once `readOnly` state class is used in Rating component.\n const stateClasses = ['active', 'checked', 'completed', 'disabled', 'error', 'expanded', 'focused', 'focusVisible', 'required', 'selected'];\n const traverse = (node, component) => {\n let key;\n\n // eslint-disable-next-line guard-for-in, no-restricted-syntax\n for (key in node) {\n const child = node[key];\n if (stateClasses.indexOf(key) !== -1 && Object.keys(child).length > 0) {\n if (process.env.NODE_ENV !== 'production') {\n const stateClass = generateUtilityClass('', key);\n console.error([`MUI: The \\`${component}\\` component increases ` + `the CSS specificity of the \\`${key}\\` internal state.`, 'You can not override it like this: ', JSON.stringify(node, null, 2), '', `Instead, you need to use the '&.${stateClass}' syntax:`, JSON.stringify({\n root: {\n [`&.${stateClass}`]: child\n }\n }, null, 2), '', 'https://mui.com/r/state-classes-guide'].join('\\n'));\n }\n // Remove the style to prevent global conflicts.\n node[key] = {};\n }\n }\n };\n Object.keys(muiTheme.components).forEach(component => {\n const styleOverrides = muiTheme.components[component].styleOverrides;\n if (styleOverrides && component.indexOf('Mui') === 0) {\n traverse(styleOverrides, component);\n }\n });\n }\n muiTheme.unstable_sxConfig = _extends({}, defaultSxConfig, other == null ? void 0 : other.unstable_sxConfig);\n muiTheme.unstable_sx = function sx(props) {\n return styleFunctionSx({\n sx: props,\n theme: this\n });\n };\n return muiTheme;\n}\nlet warnedOnce = false;\nexport function createMuiTheme(...args) {\n if (process.env.NODE_ENV !== 'production') {\n if (!warnedOnce) {\n warnedOnce = true;\n console.error(['MUI: the createMuiTheme function was renamed to createTheme.', '', \"You should use `import { createTheme } from '@mui/material/styles'`\"].join('\\n'));\n }\n }\n return createTheme(...args);\n}\nexport default createTheme;","'use client';\n\nimport createTheme from './createTheme';\nconst defaultTheme = createTheme();\nexport default defaultTheme;","export default '$$material';","'use client';\n\nimport { useThemeProps as systemUseThemeProps } from '@mui/system';\nimport defaultTheme from './defaultTheme';\nimport THEME_ID from './identifier';\nexport default function useThemeProps({\n props,\n name\n}) {\n return systemUseThemeProps({\n props,\n name,\n defaultTheme,\n themeId: THEME_ID\n });\n}","'use client';\n\nimport { createStyled, shouldForwardProp } from '@mui/system';\nimport defaultTheme from './defaultTheme';\nimport THEME_ID from './identifier';\nexport const rootShouldForwardProp = prop => shouldForwardProp(prop) && prop !== 'classes';\nexport const slotShouldForwardProp = shouldForwardProp;\nconst styled = createStyled({\n themeId: THEME_ID,\n defaultTheme,\n rootShouldForwardProp\n});\nexport default styled;","import generateUtilityClasses from '@mui/utils/generateUtilityClasses';\nimport generateUtilityClass from '@mui/utils/generateUtilityClass';\nexport function getSvgIconUtilityClass(slot) {\n return generateUtilityClass('MuiSvgIcon', slot);\n}\nconst svgIconClasses = generateUtilityClasses('MuiSvgIcon', ['root', 'colorPrimary', 'colorSecondary', 'colorAction', 'colorError', 'colorDisabled', 'fontSizeInherit', 'fontSizeSmall', 'fontSizeMedium', 'fontSizeLarge']);\nexport default svgIconClasses;","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"children\", \"className\", \"color\", \"component\", \"fontSize\", \"htmlColor\", \"inheritViewBox\", \"titleAccess\", \"viewBox\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport clsx from 'clsx';\nimport { unstable_composeClasses as composeClasses } from '@mui/base/composeClasses';\nimport capitalize from '../utils/capitalize';\nimport useThemeProps from '../styles/useThemeProps';\nimport styled from '../styles/styled';\nimport { getSvgIconUtilityClass } from './svgIconClasses';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nimport { jsxs as _jsxs } from \"react/jsx-runtime\";\nconst useUtilityClasses = ownerState => {\n const {\n color,\n fontSize,\n classes\n } = ownerState;\n const slots = {\n root: ['root', color !== 'inherit' && `color${capitalize(color)}`, `fontSize${capitalize(fontSize)}`]\n };\n return composeClasses(slots, getSvgIconUtilityClass, classes);\n};\nconst SvgIconRoot = styled('svg', {\n name: 'MuiSvgIcon',\n slot: 'Root',\n overridesResolver: (props, styles) => {\n const {\n ownerState\n } = props;\n return [styles.root, ownerState.color !== 'inherit' && styles[`color${capitalize(ownerState.color)}`], styles[`fontSize${capitalize(ownerState.fontSize)}`]];\n }\n})(({\n theme,\n ownerState\n}) => {\n var _theme$transitions, _theme$transitions$cr, _theme$transitions2, _theme$typography, _theme$typography$pxT, _theme$typography2, _theme$typography2$px, _theme$typography3, _theme$typography3$px, _palette$ownerState$c, _palette, _palette2, _palette3;\n return {\n userSelect: 'none',\n width: '1em',\n height: '1em',\n display: 'inline-block',\n // the will define the property that has `currentColor`\n // e.g. heroicons uses fill=\"none\" and stroke=\"currentColor\"\n fill: ownerState.hasSvgAsChild ? undefined : 'currentColor',\n flexShrink: 0,\n transition: (_theme$transitions = theme.transitions) == null || (_theme$transitions$cr = _theme$transitions.create) == null ? void 0 : _theme$transitions$cr.call(_theme$transitions, 'fill', {\n duration: (_theme$transitions2 = theme.transitions) == null || (_theme$transitions2 = _theme$transitions2.duration) == null ? void 0 : _theme$transitions2.shorter\n }),\n fontSize: {\n inherit: 'inherit',\n small: ((_theme$typography = theme.typography) == null || (_theme$typography$pxT = _theme$typography.pxToRem) == null ? void 0 : _theme$typography$pxT.call(_theme$typography, 20)) || '1.25rem',\n medium: ((_theme$typography2 = theme.typography) == null || (_theme$typography2$px = _theme$typography2.pxToRem) == null ? void 0 : _theme$typography2$px.call(_theme$typography2, 24)) || '1.5rem',\n large: ((_theme$typography3 = theme.typography) == null || (_theme$typography3$px = _theme$typography3.pxToRem) == null ? void 0 : _theme$typography3$px.call(_theme$typography3, 35)) || '2.1875rem'\n }[ownerState.fontSize],\n // TODO v5 deprecate, v6 remove for sx\n color: (_palette$ownerState$c = (_palette = (theme.vars || theme).palette) == null || (_palette = _palette[ownerState.color]) == null ? void 0 : _palette.main) != null ? _palette$ownerState$c : {\n action: (_palette2 = (theme.vars || theme).palette) == null || (_palette2 = _palette2.action) == null ? void 0 : _palette2.active,\n disabled: (_palette3 = (theme.vars || theme).palette) == null || (_palette3 = _palette3.action) == null ? void 0 : _palette3.disabled,\n inherit: undefined\n }[ownerState.color]\n };\n});\nconst SvgIcon = /*#__PURE__*/React.forwardRef(function SvgIcon(inProps, ref) {\n const props = useThemeProps({\n props: inProps,\n name: 'MuiSvgIcon'\n });\n const {\n children,\n className,\n color = 'inherit',\n component = 'svg',\n fontSize = 'medium',\n htmlColor,\n inheritViewBox = false,\n titleAccess,\n viewBox = '0 0 24 24'\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const hasSvgAsChild = /*#__PURE__*/React.isValidElement(children) && children.type === 'svg';\n const ownerState = _extends({}, props, {\n color,\n component,\n fontSize,\n instanceFontSize: inProps.fontSize,\n inheritViewBox,\n viewBox,\n hasSvgAsChild\n });\n const more = {};\n if (!inheritViewBox) {\n more.viewBox = viewBox;\n }\n const classes = useUtilityClasses(ownerState);\n return /*#__PURE__*/_jsxs(SvgIconRoot, _extends({\n as: component,\n className: clsx(classes.root, className),\n focusable: \"false\",\n color: htmlColor,\n \"aria-hidden\": titleAccess ? undefined : true,\n role: titleAccess ? 'img' : undefined,\n ref: ref\n }, more, other, hasSvgAsChild && children.props, {\n ownerState: ownerState,\n children: [hasSvgAsChild ? children.props.children : children, titleAccess ? /*#__PURE__*/_jsx(\"title\", {\n children: titleAccess\n }) : null]\n }));\n});\nprocess.env.NODE_ENV !== \"production\" ? SvgIcon.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the d.ts file and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * Node passed into the SVG element.\n */\n children: PropTypes.node,\n /**\n * Override or extend the styles applied to the component.\n */\n classes: PropTypes.object,\n /**\n * @ignore\n */\n className: PropTypes.string,\n /**\n * The color of the component.\n * It supports both default and custom theme colors, which can be added as shown in the\n * [palette customization guide](https://mui.com/material-ui/customization/palette/#custom-colors).\n * You can use the `htmlColor` prop to apply a color attribute to the SVG element.\n * @default 'inherit'\n */\n color: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.oneOf(['inherit', 'action', 'disabled', 'primary', 'secondary', 'error', 'info', 'success', 'warning']), PropTypes.string]),\n /**\n * The component used for the root node.\n * Either a string to use a HTML element or a component.\n */\n component: PropTypes.elementType,\n /**\n * The fontSize applied to the icon. Defaults to 24px, but can be configure to inherit font size.\n * @default 'medium'\n */\n fontSize: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.oneOf(['inherit', 'large', 'medium', 'small']), PropTypes.string]),\n /**\n * Applies a color attribute to the SVG element.\n */\n htmlColor: PropTypes.string,\n /**\n * If `true`, the root node will inherit the custom `component`'s viewBox and the `viewBox`\n * prop will be ignored.\n * Useful when you want to reference a custom `component` and have `SvgIcon` pass that\n * `component`'s viewBox to the root node.\n * @default false\n */\n inheritViewBox: PropTypes.bool,\n /**\n * The shape-rendering attribute. The behavior of the different options is described on the\n * [MDN Web Docs](https://developer.mozilla.org/en-US/docs/Web/SVG/Attribute/shape-rendering).\n * If you are having issues with blurry icons you should investigate this prop.\n */\n shapeRendering: PropTypes.string,\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Provides a human-readable title for the element that contains it.\n * https://www.w3.org/TR/SVG-access/#Equivalent\n */\n titleAccess: PropTypes.string,\n /**\n * Allows you to redefine what the coordinates without units mean inside an SVG element.\n * For example, if the SVG element is 500 (width) by 200 (height),\n * and you pass viewBox=\"0 0 50 20\",\n * this means that the coordinates inside the SVG will go from the top left corner (0,0)\n * to bottom right (50,20) and each unit will be worth 10px.\n * @default '0 0 24 24'\n */\n viewBox: PropTypes.string\n} : void 0;\nSvgIcon.muiName = 'SvgIcon';\nexport default SvgIcon;","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport * as React from 'react';\nimport SvgIcon from '../SvgIcon';\n\n/**\n * Private module reserved for @mui packages.\n */\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nexport default function createSvgIcon(path, displayName) {\n function Component(props, ref) {\n return /*#__PURE__*/_jsx(SvgIcon, _extends({\n \"data-testid\": `${displayName}Icon`,\n ref: ref\n }, props, {\n children: path\n }));\n }\n if (process.env.NODE_ENV !== 'production') {\n // Need to set `displayName` on the inner component for React.memo.\n // React prior to 16.14 ignores `displayName` on the wrapper.\n Component.displayName = `${displayName}Icon`;\n }\n Component.muiName = SvgIcon.muiName;\n return /*#__PURE__*/React.memo( /*#__PURE__*/React.forwardRef(Component));\n}","'use client';\n\nimport { unstable_ClassNameGenerator as ClassNameGenerator } from '@mui/base/ClassNameGenerator';\nexport { default as capitalize } from './capitalize';\nexport { default as createChainedFunction } from './createChainedFunction';\nexport { default as createSvgIcon } from './createSvgIcon';\nexport { default as debounce } from './debounce';\nexport { default as deprecatedPropType } from './deprecatedPropType';\nexport { default as isMuiElement } from './isMuiElement';\nexport { default as ownerDocument } from './ownerDocument';\nexport { default as ownerWindow } from './ownerWindow';\nexport { default as requirePropFactory } from './requirePropFactory';\nexport { default as setRef } from './setRef';\nexport { default as unstable_useEnhancedEffect } from './useEnhancedEffect';\nexport { default as unstable_useId } from './useId';\nexport { default as unsupportedProp } from './unsupportedProp';\nexport { default as useControlled } from './useControlled';\nexport { default as useEventCallback } from './useEventCallback';\nexport { default as useForkRef } from './useForkRef';\nexport { default as useIsFocusVisible } from './useIsFocusVisible';\n// TODO: remove this export once ClassNameGenerator is stable\n// eslint-disable-next-line @typescript-eslint/naming-convention\nexport const unstable_ClassNameGenerator = {\n configure: generator => {\n if (process.env.NODE_ENV !== 'production') {\n console.warn(['MUI: `ClassNameGenerator` import from `@mui/material/utils` is outdated and might cause unexpected issues.', '', \"You should use `import { unstable_ClassNameGenerator } from '@mui/material/className'` instead\", '', 'The detail of the issue: https://github.com/mui/material-ui/issues/30011#issuecomment-1024993401', '', 'The updated documentation: https://mui.com/guides/classname-generator/'].join('\\n'));\n }\n ClassNameGenerator.configure(generator);\n }\n};","\"use strict\";\n'use client';\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nObject.defineProperty(exports, \"default\", {\n enumerable: true,\n get: function () {\n return _utils.createSvgIcon;\n }\n});\nvar _utils = require(\"@mui/material/utils\");","\"use strict\";\n\"use client\";\n\nvar _interopRequireDefault = require(\"@babel/runtime/helpers/interopRequireDefault\");\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = void 0;\nvar _createSvgIcon = _interopRequireDefault(require(\"./utils/createSvgIcon\"));\nvar _jsxRuntime = require(\"react/jsx-runtime\");\nvar _default = exports.default = (0, _createSvgIcon.default)( /*#__PURE__*/(0, _jsxRuntime.jsx)(\"path\", {\n d: \"m10 17 5-5-5-5z\"\n}), 'ArrowRight');","/**\n * Determines if a given element is a DOM element name (i.e. not a React component).\n */\nexport function isHostComponent(element) {\n return typeof element === 'string';\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport { isHostComponent } from './isHostComponent';\n\n/**\n * Type of the ownerState based on the type of an element it applies to.\n * This resolves to the provided OwnerState for React components and `undefined` for host components.\n * Falls back to `OwnerState | undefined` when the exact type can't be determined in development time.\n */\n\n/**\n * Appends the ownerState object to the props, merging with the existing one if necessary.\n *\n * @param elementType Type of the element that owns the `existingProps`. If the element is a DOM node or undefined, `ownerState` is not applied.\n * @param otherProps Props of the element.\n * @param ownerState\n */\nexport function appendOwnerState(elementType, otherProps, ownerState) {\n if (elementType === undefined || isHostComponent(elementType)) {\n return otherProps;\n }\n return _extends({}, otherProps, {\n ownerState: _extends({}, otherProps.ownerState, ownerState)\n });\n}","'use client';\n\nimport * as React from 'react';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nconst defaultContextValue = {\n disableDefaultClasses: false\n};\nconst ClassNameConfiguratorContext = /*#__PURE__*/React.createContext(defaultContextValue);\n/**\n * @ignore - internal hook.\n *\n * Wraps the `generateUtilityClass` function and controls how the classes are generated.\n * Currently it only affects whether the classes are applied or not.\n *\n * @returns Function to be called with the `generateUtilityClass` function specific to a component to generate the classes.\n */\nexport function useClassNamesOverride(generateUtilityClass) {\n const {\n disableDefaultClasses\n } = React.useContext(ClassNameConfiguratorContext);\n return slot => {\n if (disableDefaultClasses) {\n return '';\n }\n return generateUtilityClass(slot);\n };\n}\n\n/**\n * Allows to configure the components within to not apply any built-in classes.\n */\nexport function ClassNameConfigurator(props) {\n const {\n disableDefaultClasses,\n children\n } = props;\n const contextValue = React.useMemo(() => ({\n disableDefaultClasses: disableDefaultClasses != null ? disableDefaultClasses : false\n }), [disableDefaultClasses]);\n return /*#__PURE__*/_jsx(ClassNameConfiguratorContext.Provider, {\n value: contextValue,\n children: children\n });\n}","/**\n * Extracts event handlers from a given object.\n * A prop is considered an event handler if it is a function and its name starts with `on`.\n *\n * @param object An object to extract event handlers from.\n * @param excludeKeys An array of keys to exclude from the returned object.\n */\nexport function extractEventHandlers(object, excludeKeys = []) {\n if (object === undefined) {\n return {};\n }\n const result = {};\n Object.keys(object).filter(prop => prop.match(/^on[A-Z]/) && typeof object[prop] === 'function' && !excludeKeys.includes(prop)).forEach(prop => {\n result[prop] = object[prop];\n });\n return result;\n}","/**\n * If `componentProps` is a function, calls it with the provided `ownerState`.\n * Otherwise, just returns `componentProps`.\n */\nexport function resolveComponentProps(componentProps, ownerState, slotState) {\n if (typeof componentProps === 'function') {\n return componentProps(ownerState, slotState);\n }\n return componentProps;\n}","/**\n * Removes event handlers from the given object.\n * A field is considered an event handler if it is a function with a name beginning with `on`.\n *\n * @param object Object to remove event handlers from.\n * @returns Object with event handlers removed.\n */\nexport function omitEventHandlers(object) {\n if (object === undefined) {\n return {};\n }\n const result = {};\n Object.keys(object).filter(prop => !(prop.match(/^on[A-Z]/) && typeof object[prop] === 'function')).forEach(prop => {\n result[prop] = object[prop];\n });\n return result;\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport clsx from 'clsx';\nimport { extractEventHandlers } from './extractEventHandlers';\nimport { omitEventHandlers } from './omitEventHandlers';\n/**\n * Merges the slot component internal props (usually coming from a hook)\n * with the externally provided ones.\n *\n * The merge order is (the latter overrides the former):\n * 1. The internal props (specified as a getter function to work with get*Props hook result)\n * 2. Additional props (specified internally on a Base UI component)\n * 3. External props specified on the owner component. These should only be used on a root slot.\n * 4. External props specified in the `slotProps.*` prop.\n * 5. The `className` prop - combined from all the above.\n * @param parameters\n * @returns\n */\nexport function mergeSlotProps(parameters) {\n const {\n getSlotProps,\n additionalProps,\n externalSlotProps,\n externalForwardedProps,\n className\n } = parameters;\n if (!getSlotProps) {\n // The simpler case - getSlotProps is not defined, so no internal event handlers are defined,\n // so we can simply merge all the props without having to worry about extracting event handlers.\n const joinedClasses = clsx(additionalProps == null ? void 0 : additionalProps.className, className, externalForwardedProps == null ? void 0 : externalForwardedProps.className, externalSlotProps == null ? void 0 : externalSlotProps.className);\n const mergedStyle = _extends({}, additionalProps == null ? void 0 : additionalProps.style, externalForwardedProps == null ? void 0 : externalForwardedProps.style, externalSlotProps == null ? void 0 : externalSlotProps.style);\n const props = _extends({}, additionalProps, externalForwardedProps, externalSlotProps);\n if (joinedClasses.length > 0) {\n props.className = joinedClasses;\n }\n if (Object.keys(mergedStyle).length > 0) {\n props.style = mergedStyle;\n }\n return {\n props,\n internalRef: undefined\n };\n }\n\n // In this case, getSlotProps is responsible for calling the external event handlers.\n // We don't need to include them in the merged props because of this.\n\n const eventHandlers = extractEventHandlers(_extends({}, externalForwardedProps, externalSlotProps));\n const componentsPropsWithoutEventHandlers = omitEventHandlers(externalSlotProps);\n const otherPropsWithoutEventHandlers = omitEventHandlers(externalForwardedProps);\n const internalSlotProps = getSlotProps(eventHandlers);\n\n // The order of classes is important here.\n // Emotion (that we use in libraries consuming Base UI) depends on this order\n // to properly override style. It requires the most important classes to be last\n // (see https://github.com/mui/material-ui/pull/33205) for the related discussion.\n const joinedClasses = clsx(internalSlotProps == null ? void 0 : internalSlotProps.className, additionalProps == null ? void 0 : additionalProps.className, className, externalForwardedProps == null ? void 0 : externalForwardedProps.className, externalSlotProps == null ? void 0 : externalSlotProps.className);\n const mergedStyle = _extends({}, internalSlotProps == null ? void 0 : internalSlotProps.style, additionalProps == null ? void 0 : additionalProps.style, externalForwardedProps == null ? void 0 : externalForwardedProps.style, externalSlotProps == null ? void 0 : externalSlotProps.style);\n const props = _extends({}, internalSlotProps, additionalProps, otherPropsWithoutEventHandlers, componentsPropsWithoutEventHandlers);\n if (joinedClasses.length > 0) {\n props.className = joinedClasses;\n }\n if (Object.keys(mergedStyle).length > 0) {\n props.style = mergedStyle;\n }\n return {\n props,\n internalRef: internalSlotProps.ref\n };\n}","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"elementType\", \"externalSlotProps\", \"ownerState\", \"skipResolvingSlotProps\"];\nimport { unstable_useForkRef as useForkRef } from '@mui/utils';\nimport { appendOwnerState } from './appendOwnerState';\nimport { mergeSlotProps } from './mergeSlotProps';\nimport { resolveComponentProps } from './resolveComponentProps';\n/**\n * @ignore - do not document.\n * Builds the props to be passed into the slot of an unstyled component.\n * It merges the internal props of the component with the ones supplied by the user, allowing to customize the behavior.\n * If the slot component is not a host component, it also merges in the `ownerState`.\n *\n * @param parameters.getSlotProps - A function that returns the props to be passed to the slot component.\n */\nexport function useSlotProps(parameters) {\n var _parameters$additiona;\n const {\n elementType,\n externalSlotProps,\n ownerState,\n skipResolvingSlotProps = false\n } = parameters,\n rest = _objectWithoutPropertiesLoose(parameters, _excluded);\n const resolvedComponentsProps = skipResolvingSlotProps ? {} : resolveComponentProps(externalSlotProps, ownerState);\n const {\n props: mergedProps,\n internalRef\n } = mergeSlotProps(_extends({}, rest, {\n externalSlotProps: resolvedComponentsProps\n }));\n const ref = useForkRef(internalRef, resolvedComponentsProps == null ? void 0 : resolvedComponentsProps.ref, (_parameters$additiona = parameters.additionalProps) == null ? void 0 : _parameters$additiona.ref);\n const props = appendOwnerState(elementType, _extends({}, mergedProps, {\n ref\n }), ownerState);\n return props;\n}","import { globalStateClasses } from '@mui/utils/generateUtilityClass';\nconst GLOBAL_CLASS_PREFIX = 'base';\nfunction buildStateClass(state) {\n return `${GLOBAL_CLASS_PREFIX}--${state}`;\n}\nfunction buildSlotClass(componentName, slot) {\n return `${GLOBAL_CLASS_PREFIX}-${componentName}-${slot}`;\n}\nexport function generateUtilityClass(componentName, slot) {\n const globalStateClass = globalStateClasses[slot];\n return globalStateClass ? buildStateClass(globalStateClass) : buildSlotClass(componentName, slot);\n}\nexport function isGlobalState(slot) {\n return globalStateClasses[slot] !== undefined;\n}","import { generateUtilityClass } from '../generateUtilityClass';\nexport function generateUtilityClasses(componentName, slots) {\n const result = {};\n slots.forEach(slot => {\n result[slot] = generateUtilityClass(componentName, slot);\n });\n return result;\n}","'use client';\n\nimport * as React from 'react';\nimport * as ReactDOM from 'react-dom';\nimport PropTypes from 'prop-types';\nimport { exactProp, HTMLElementType, unstable_useEnhancedEffect as useEnhancedEffect, unstable_useForkRef as useForkRef, unstable_setRef as setRef } from '@mui/utils';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nfunction getContainer(container) {\n return typeof container === 'function' ? container() : container;\n}\n\n/**\n * Portals provide a first-class way to render children into a DOM node\n * that exists outside the DOM hierarchy of the parent component.\n *\n * Demos:\n *\n * - [Portal](https://mui.com/base-ui/react-portal/)\n *\n * API:\n *\n * - [Portal API](https://mui.com/base-ui/react-portal/components-api/#portal)\n */\nconst Portal = /*#__PURE__*/React.forwardRef(function Portal(props, forwardedRef) {\n const {\n children,\n container,\n disablePortal = false\n } = props;\n const [mountNode, setMountNode] = React.useState(null);\n // @ts-expect-error TODO upstream fix\n const handleRef = useForkRef( /*#__PURE__*/React.isValidElement(children) ? children.ref : null, forwardedRef);\n useEnhancedEffect(() => {\n if (!disablePortal) {\n setMountNode(getContainer(container) || document.body);\n }\n }, [container, disablePortal]);\n useEnhancedEffect(() => {\n if (mountNode && !disablePortal) {\n setRef(forwardedRef, mountNode);\n return () => {\n setRef(forwardedRef, null);\n };\n }\n return undefined;\n }, [forwardedRef, mountNode, disablePortal]);\n if (disablePortal) {\n if ( /*#__PURE__*/React.isValidElement(children)) {\n const newProps = {\n ref: handleRef\n };\n return /*#__PURE__*/React.cloneElement(children, newProps);\n }\n return /*#__PURE__*/_jsx(React.Fragment, {\n children: children\n });\n }\n return /*#__PURE__*/_jsx(React.Fragment, {\n children: mountNode ? /*#__PURE__*/ReactDOM.createPortal(children, mountNode) : mountNode\n });\n});\nprocess.env.NODE_ENV !== \"production\" ? Portal.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * The children to render into the `container`.\n */\n children: PropTypes.node,\n /**\n * An HTML element or function that returns one.\n * The `container` will have the portal children appended to it.\n *\n * You can also provide a callback, which is called in a React layout effect.\n * This lets you set the container from a ref, and also makes server-side rendering possible.\n *\n * By default, it uses the body of the top-level document object,\n * so it's simply `document.body` most of the time.\n */\n container: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.func]),\n /**\n * The `children` will be under the DOM hierarchy of the parent component.\n * @default false\n */\n disablePortal: PropTypes.bool\n} : void 0;\nif (process.env.NODE_ENV !== 'production') {\n // eslint-disable-next-line\n Portal['propTypes' + ''] = exactProp(Portal.propTypes);\n}\nexport { Portal };","export var top = 'top';\nexport var bottom = 'bottom';\nexport var right = 'right';\nexport var left = 'left';\nexport var auto = 'auto';\nexport var basePlacements = [top, bottom, right, left];\nexport var start = 'start';\nexport var end = 'end';\nexport var clippingParents = 'clippingParents';\nexport var viewport = 'viewport';\nexport var popper = 'popper';\nexport var reference = 'reference';\nexport var variationPlacements = /*#__PURE__*/basePlacements.reduce(function (acc, placement) {\n return acc.concat([placement + \"-\" + start, placement + \"-\" + end]);\n}, []);\nexport var placements = /*#__PURE__*/[].concat(basePlacements, [auto]).reduce(function (acc, placement) {\n return acc.concat([placement, placement + \"-\" + start, placement + \"-\" + end]);\n}, []); // modifiers that need to read the DOM\n\nexport var beforeRead = 'beforeRead';\nexport var read = 'read';\nexport var afterRead = 'afterRead'; // pure-logic modifiers\n\nexport var beforeMain = 'beforeMain';\nexport var main = 'main';\nexport var afterMain = 'afterMain'; // modifier with the purpose to write to the DOM (or write into a framework state)\n\nexport var beforeWrite = 'beforeWrite';\nexport var write = 'write';\nexport var afterWrite = 'afterWrite';\nexport var modifierPhases = [beforeRead, read, afterRead, beforeMain, main, afterMain, beforeWrite, write, afterWrite];","export default function getNodeName(element) {\n return element ? (element.nodeName || '').toLowerCase() : null;\n}","export default function getWindow(node) {\n if (node == null) {\n return window;\n }\n\n if (node.toString() !== '[object Window]') {\n var ownerDocument = node.ownerDocument;\n return ownerDocument ? ownerDocument.defaultView || window : window;\n }\n\n return node;\n}","import getWindow from \"./getWindow.js\";\n\nfunction isElement(node) {\n var OwnElement = getWindow(node).Element;\n return node instanceof OwnElement || node instanceof Element;\n}\n\nfunction isHTMLElement(node) {\n var OwnElement = getWindow(node).HTMLElement;\n return node instanceof OwnElement || node instanceof HTMLElement;\n}\n\nfunction isShadowRoot(node) {\n // IE 11 has no ShadowRoot\n if (typeof ShadowRoot === 'undefined') {\n return false;\n }\n\n var OwnElement = getWindow(node).ShadowRoot;\n return node instanceof OwnElement || node instanceof ShadowRoot;\n}\n\nexport { isElement, isHTMLElement, isShadowRoot };","import getNodeName from \"../dom-utils/getNodeName.js\";\nimport { isHTMLElement } from \"../dom-utils/instanceOf.js\"; // This modifier takes the styles prepared by the `computeStyles` modifier\n// and applies them to the HTMLElements such as popper and arrow\n\nfunction applyStyles(_ref) {\n var state = _ref.state;\n Object.keys(state.elements).forEach(function (name) {\n var style = state.styles[name] || {};\n var attributes = state.attributes[name] || {};\n var element = state.elements[name]; // arrow is optional + virtual elements\n\n if (!isHTMLElement(element) || !getNodeName(element)) {\n return;\n } // Flow doesn't support to extend this property, but it's the most\n // effective way to apply styles to an HTMLElement\n // $FlowFixMe[cannot-write]\n\n\n Object.assign(element.style, style);\n Object.keys(attributes).forEach(function (name) {\n var value = attributes[name];\n\n if (value === false) {\n element.removeAttribute(name);\n } else {\n element.setAttribute(name, value === true ? '' : value);\n }\n });\n });\n}\n\nfunction effect(_ref2) {\n var state = _ref2.state;\n var initialStyles = {\n popper: {\n position: state.options.strategy,\n left: '0',\n top: '0',\n margin: '0'\n },\n arrow: {\n position: 'absolute'\n },\n reference: {}\n };\n Object.assign(state.elements.popper.style, initialStyles.popper);\n state.styles = initialStyles;\n\n if (state.elements.arrow) {\n Object.assign(state.elements.arrow.style, initialStyles.arrow);\n }\n\n return function () {\n Object.keys(state.elements).forEach(function (name) {\n var element = state.elements[name];\n var attributes = state.attributes[name] || {};\n var styleProperties = Object.keys(state.styles.hasOwnProperty(name) ? state.styles[name] : initialStyles[name]); // Set all values to an empty string to unset them\n\n var style = styleProperties.reduce(function (style, property) {\n style[property] = '';\n return style;\n }, {}); // arrow is optional + virtual elements\n\n if (!isHTMLElement(element) || !getNodeName(element)) {\n return;\n }\n\n Object.assign(element.style, style);\n Object.keys(attributes).forEach(function (attribute) {\n element.removeAttribute(attribute);\n });\n });\n };\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'applyStyles',\n enabled: true,\n phase: 'write',\n fn: applyStyles,\n effect: effect,\n requires: ['computeStyles']\n};","import { auto } from \"../enums.js\";\nexport default function getBasePlacement(placement) {\n return placement.split('-')[0];\n}","export var max = Math.max;\nexport var min = Math.min;\nexport var round = Math.round;","export default function getUAString() {\n var uaData = navigator.userAgentData;\n\n if (uaData != null && uaData.brands && Array.isArray(uaData.brands)) {\n return uaData.brands.map(function (item) {\n return item.brand + \"/\" + item.version;\n }).join(' ');\n }\n\n return navigator.userAgent;\n}","import getUAString from \"../utils/userAgent.js\";\nexport default function isLayoutViewport() {\n return !/^((?!chrome|android).)*safari/i.test(getUAString());\n}","import { isElement, isHTMLElement } from \"./instanceOf.js\";\nimport { round } from \"../utils/math.js\";\nimport getWindow from \"./getWindow.js\";\nimport isLayoutViewport from \"./isLayoutViewport.js\";\nexport default function getBoundingClientRect(element, includeScale, isFixedStrategy) {\n if (includeScale === void 0) {\n includeScale = false;\n }\n\n if (isFixedStrategy === void 0) {\n isFixedStrategy = false;\n }\n\n var clientRect = element.getBoundingClientRect();\n var scaleX = 1;\n var scaleY = 1;\n\n if (includeScale && isHTMLElement(element)) {\n scaleX = element.offsetWidth > 0 ? round(clientRect.width) / element.offsetWidth || 1 : 1;\n scaleY = element.offsetHeight > 0 ? round(clientRect.height) / element.offsetHeight || 1 : 1;\n }\n\n var _ref = isElement(element) ? getWindow(element) : window,\n visualViewport = _ref.visualViewport;\n\n var addVisualOffsets = !isLayoutViewport() && isFixedStrategy;\n var x = (clientRect.left + (addVisualOffsets && visualViewport ? visualViewport.offsetLeft : 0)) / scaleX;\n var y = (clientRect.top + (addVisualOffsets && visualViewport ? visualViewport.offsetTop : 0)) / scaleY;\n var width = clientRect.width / scaleX;\n var height = clientRect.height / scaleY;\n return {\n width: width,\n height: height,\n top: y,\n right: x + width,\n bottom: y + height,\n left: x,\n x: x,\n y: y\n };\n}","import getBoundingClientRect from \"./getBoundingClientRect.js\"; // Returns the layout rect of an element relative to its offsetParent. Layout\n// means it doesn't take into account transforms.\n\nexport default function getLayoutRect(element) {\n var clientRect = getBoundingClientRect(element); // Use the clientRect sizes if it's not been transformed.\n // Fixes https://github.com/popperjs/popper-core/issues/1223\n\n var width = element.offsetWidth;\n var height = element.offsetHeight;\n\n if (Math.abs(clientRect.width - width) <= 1) {\n width = clientRect.width;\n }\n\n if (Math.abs(clientRect.height - height) <= 1) {\n height = clientRect.height;\n }\n\n return {\n x: element.offsetLeft,\n y: element.offsetTop,\n width: width,\n height: height\n };\n}","import { isShadowRoot } from \"./instanceOf.js\";\nexport default function contains(parent, child) {\n var rootNode = child.getRootNode && child.getRootNode(); // First, attempt with faster native method\n\n if (parent.contains(child)) {\n return true;\n } // then fallback to custom implementation with Shadow DOM support\n else if (rootNode && isShadowRoot(rootNode)) {\n var next = child;\n\n do {\n if (next && parent.isSameNode(next)) {\n return true;\n } // $FlowFixMe[prop-missing]: need a better way to handle this...\n\n\n next = next.parentNode || next.host;\n } while (next);\n } // Give up, the result is false\n\n\n return false;\n}","import getWindow from \"./getWindow.js\";\nexport default function getComputedStyle(element) {\n return getWindow(element).getComputedStyle(element);\n}","import getNodeName from \"./getNodeName.js\";\nexport default function isTableElement(element) {\n return ['table', 'td', 'th'].indexOf(getNodeName(element)) >= 0;\n}","import { isElement } from \"./instanceOf.js\";\nexport default function getDocumentElement(element) {\n // $FlowFixMe[incompatible-return]: assume body is always available\n return ((isElement(element) ? element.ownerDocument : // $FlowFixMe[prop-missing]\n element.document) || window.document).documentElement;\n}","import getNodeName from \"./getNodeName.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport { isShadowRoot } from \"./instanceOf.js\";\nexport default function getParentNode(element) {\n if (getNodeName(element) === 'html') {\n return element;\n }\n\n return (// this is a quicker (but less type safe) way to save quite some bytes from the bundle\n // $FlowFixMe[incompatible-return]\n // $FlowFixMe[prop-missing]\n element.assignedSlot || // step into the shadow DOM of the parent of a slotted node\n element.parentNode || ( // DOM Element detected\n isShadowRoot(element) ? element.host : null) || // ShadowRoot detected\n // $FlowFixMe[incompatible-call]: HTMLElement is a Node\n getDocumentElement(element) // fallback\n\n );\n}","import getWindow from \"./getWindow.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport getComputedStyle from \"./getComputedStyle.js\";\nimport { isHTMLElement, isShadowRoot } from \"./instanceOf.js\";\nimport isTableElement from \"./isTableElement.js\";\nimport getParentNode from \"./getParentNode.js\";\nimport getUAString from \"../utils/userAgent.js\";\n\nfunction getTrueOffsetParent(element) {\n if (!isHTMLElement(element) || // https://github.com/popperjs/popper-core/issues/837\n getComputedStyle(element).position === 'fixed') {\n return null;\n }\n\n return element.offsetParent;\n} // `.offsetParent` reports `null` for fixed elements, while absolute elements\n// return the containing block\n\n\nfunction getContainingBlock(element) {\n var isFirefox = /firefox/i.test(getUAString());\n var isIE = /Trident/i.test(getUAString());\n\n if (isIE && isHTMLElement(element)) {\n // In IE 9, 10 and 11 fixed elements containing block is always established by the viewport\n var elementCss = getComputedStyle(element);\n\n if (elementCss.position === 'fixed') {\n return null;\n }\n }\n\n var currentNode = getParentNode(element);\n\n if (isShadowRoot(currentNode)) {\n currentNode = currentNode.host;\n }\n\n while (isHTMLElement(currentNode) && ['html', 'body'].indexOf(getNodeName(currentNode)) < 0) {\n var css = getComputedStyle(currentNode); // This is non-exhaustive but covers the most common CSS properties that\n // create a containing block.\n // https://developer.mozilla.org/en-US/docs/Web/CSS/Containing_block#identifying_the_containing_block\n\n if (css.transform !== 'none' || css.perspective !== 'none' || css.contain === 'paint' || ['transform', 'perspective'].indexOf(css.willChange) !== -1 || isFirefox && css.willChange === 'filter' || isFirefox && css.filter && css.filter !== 'none') {\n return currentNode;\n } else {\n currentNode = currentNode.parentNode;\n }\n }\n\n return null;\n} // Gets the closest ancestor positioned element. Handles some edge cases,\n// such as table ancestors and cross browser bugs.\n\n\nexport default function getOffsetParent(element) {\n var window = getWindow(element);\n var offsetParent = getTrueOffsetParent(element);\n\n while (offsetParent && isTableElement(offsetParent) && getComputedStyle(offsetParent).position === 'static') {\n offsetParent = getTrueOffsetParent(offsetParent);\n }\n\n if (offsetParent && (getNodeName(offsetParent) === 'html' || getNodeName(offsetParent) === 'body' && getComputedStyle(offsetParent).position === 'static')) {\n return window;\n }\n\n return offsetParent || getContainingBlock(element) || window;\n}","export default function getMainAxisFromPlacement(placement) {\n return ['top', 'bottom'].indexOf(placement) >= 0 ? 'x' : 'y';\n}","import { max as mathMax, min as mathMin } from \"./math.js\";\nexport function within(min, value, max) {\n return mathMax(min, mathMin(value, max));\n}\nexport function withinMaxClamp(min, value, max) {\n var v = within(min, value, max);\n return v > max ? max : v;\n}","export default function getFreshSideObject() {\n return {\n top: 0,\n right: 0,\n bottom: 0,\n left: 0\n };\n}","import getFreshSideObject from \"./getFreshSideObject.js\";\nexport default function mergePaddingObject(paddingObject) {\n return Object.assign({}, getFreshSideObject(), paddingObject);\n}","export default function expandToHashMap(value, keys) {\n return keys.reduce(function (hashMap, key) {\n hashMap[key] = value;\n return hashMap;\n }, {});\n}","import getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getLayoutRect from \"../dom-utils/getLayoutRect.js\";\nimport contains from \"../dom-utils/contains.js\";\nimport getOffsetParent from \"../dom-utils/getOffsetParent.js\";\nimport getMainAxisFromPlacement from \"../utils/getMainAxisFromPlacement.js\";\nimport { within } from \"../utils/within.js\";\nimport mergePaddingObject from \"../utils/mergePaddingObject.js\";\nimport expandToHashMap from \"../utils/expandToHashMap.js\";\nimport { left, right, basePlacements, top, bottom } from \"../enums.js\"; // eslint-disable-next-line import/no-unused-modules\n\nvar toPaddingObject = function toPaddingObject(padding, state) {\n padding = typeof padding === 'function' ? padding(Object.assign({}, state.rects, {\n placement: state.placement\n })) : padding;\n return mergePaddingObject(typeof padding !== 'number' ? padding : expandToHashMap(padding, basePlacements));\n};\n\nfunction arrow(_ref) {\n var _state$modifiersData$;\n\n var state = _ref.state,\n name = _ref.name,\n options = _ref.options;\n var arrowElement = state.elements.arrow;\n var popperOffsets = state.modifiersData.popperOffsets;\n var basePlacement = getBasePlacement(state.placement);\n var axis = getMainAxisFromPlacement(basePlacement);\n var isVertical = [left, right].indexOf(basePlacement) >= 0;\n var len = isVertical ? 'height' : 'width';\n\n if (!arrowElement || !popperOffsets) {\n return;\n }\n\n var paddingObject = toPaddingObject(options.padding, state);\n var arrowRect = getLayoutRect(arrowElement);\n var minProp = axis === 'y' ? top : left;\n var maxProp = axis === 'y' ? bottom : right;\n var endDiff = state.rects.reference[len] + state.rects.reference[axis] - popperOffsets[axis] - state.rects.popper[len];\n var startDiff = popperOffsets[axis] - state.rects.reference[axis];\n var arrowOffsetParent = getOffsetParent(arrowElement);\n var clientSize = arrowOffsetParent ? axis === 'y' ? arrowOffsetParent.clientHeight || 0 : arrowOffsetParent.clientWidth || 0 : 0;\n var centerToReference = endDiff / 2 - startDiff / 2; // Make sure the arrow doesn't overflow the popper if the center point is\n // outside of the popper bounds\n\n var min = paddingObject[minProp];\n var max = clientSize - arrowRect[len] - paddingObject[maxProp];\n var center = clientSize / 2 - arrowRect[len] / 2 + centerToReference;\n var offset = within(min, center, max); // Prevents breaking syntax highlighting...\n\n var axisProp = axis;\n state.modifiersData[name] = (_state$modifiersData$ = {}, _state$modifiersData$[axisProp] = offset, _state$modifiersData$.centerOffset = offset - center, _state$modifiersData$);\n}\n\nfunction effect(_ref2) {\n var state = _ref2.state,\n options = _ref2.options;\n var _options$element = options.element,\n arrowElement = _options$element === void 0 ? '[data-popper-arrow]' : _options$element;\n\n if (arrowElement == null) {\n return;\n } // CSS selector\n\n\n if (typeof arrowElement === 'string') {\n arrowElement = state.elements.popper.querySelector(arrowElement);\n\n if (!arrowElement) {\n return;\n }\n }\n\n if (!contains(state.elements.popper, arrowElement)) {\n return;\n }\n\n state.elements.arrow = arrowElement;\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'arrow',\n enabled: true,\n phase: 'main',\n fn: arrow,\n effect: effect,\n requires: ['popperOffsets'],\n requiresIfExists: ['preventOverflow']\n};","export default function getVariation(placement) {\n return placement.split('-')[1];\n}","import { top, left, right, bottom, end } from \"../enums.js\";\nimport getOffsetParent from \"../dom-utils/getOffsetParent.js\";\nimport getWindow from \"../dom-utils/getWindow.js\";\nimport getDocumentElement from \"../dom-utils/getDocumentElement.js\";\nimport getComputedStyle from \"../dom-utils/getComputedStyle.js\";\nimport getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getVariation from \"../utils/getVariation.js\";\nimport { round } from \"../utils/math.js\"; // eslint-disable-next-line import/no-unused-modules\n\nvar unsetSides = {\n top: 'auto',\n right: 'auto',\n bottom: 'auto',\n left: 'auto'\n}; // Round the offsets to the nearest suitable subpixel based on the DPR.\n// Zooming can change the DPR, but it seems to report a value that will\n// cleanly divide the values into the appropriate subpixels.\n\nfunction roundOffsetsByDPR(_ref, win) {\n var x = _ref.x,\n y = _ref.y;\n var dpr = win.devicePixelRatio || 1;\n return {\n x: round(x * dpr) / dpr || 0,\n y: round(y * dpr) / dpr || 0\n };\n}\n\nexport function mapToStyles(_ref2) {\n var _Object$assign2;\n\n var popper = _ref2.popper,\n popperRect = _ref2.popperRect,\n placement = _ref2.placement,\n variation = _ref2.variation,\n offsets = _ref2.offsets,\n position = _ref2.position,\n gpuAcceleration = _ref2.gpuAcceleration,\n adaptive = _ref2.adaptive,\n roundOffsets = _ref2.roundOffsets,\n isFixed = _ref2.isFixed;\n var _offsets$x = offsets.x,\n x = _offsets$x === void 0 ? 0 : _offsets$x,\n _offsets$y = offsets.y,\n y = _offsets$y === void 0 ? 0 : _offsets$y;\n\n var _ref3 = typeof roundOffsets === 'function' ? roundOffsets({\n x: x,\n y: y\n }) : {\n x: x,\n y: y\n };\n\n x = _ref3.x;\n y = _ref3.y;\n var hasX = offsets.hasOwnProperty('x');\n var hasY = offsets.hasOwnProperty('y');\n var sideX = left;\n var sideY = top;\n var win = window;\n\n if (adaptive) {\n var offsetParent = getOffsetParent(popper);\n var heightProp = 'clientHeight';\n var widthProp = 'clientWidth';\n\n if (offsetParent === getWindow(popper)) {\n offsetParent = getDocumentElement(popper);\n\n if (getComputedStyle(offsetParent).position !== 'static' && position === 'absolute') {\n heightProp = 'scrollHeight';\n widthProp = 'scrollWidth';\n }\n } // $FlowFixMe[incompatible-cast]: force type refinement, we compare offsetParent with window above, but Flow doesn't detect it\n\n\n offsetParent = offsetParent;\n\n if (placement === top || (placement === left || placement === right) && variation === end) {\n sideY = bottom;\n var offsetY = isFixed && offsetParent === win && win.visualViewport ? win.visualViewport.height : // $FlowFixMe[prop-missing]\n offsetParent[heightProp];\n y -= offsetY - popperRect.height;\n y *= gpuAcceleration ? 1 : -1;\n }\n\n if (placement === left || (placement === top || placement === bottom) && variation === end) {\n sideX = right;\n var offsetX = isFixed && offsetParent === win && win.visualViewport ? win.visualViewport.width : // $FlowFixMe[prop-missing]\n offsetParent[widthProp];\n x -= offsetX - popperRect.width;\n x *= gpuAcceleration ? 1 : -1;\n }\n }\n\n var commonStyles = Object.assign({\n position: position\n }, adaptive && unsetSides);\n\n var _ref4 = roundOffsets === true ? roundOffsetsByDPR({\n x: x,\n y: y\n }, getWindow(popper)) : {\n x: x,\n y: y\n };\n\n x = _ref4.x;\n y = _ref4.y;\n\n if (gpuAcceleration) {\n var _Object$assign;\n\n return Object.assign({}, commonStyles, (_Object$assign = {}, _Object$assign[sideY] = hasY ? '0' : '', _Object$assign[sideX] = hasX ? '0' : '', _Object$assign.transform = (win.devicePixelRatio || 1) <= 1 ? \"translate(\" + x + \"px, \" + y + \"px)\" : \"translate3d(\" + x + \"px, \" + y + \"px, 0)\", _Object$assign));\n }\n\n return Object.assign({}, commonStyles, (_Object$assign2 = {}, _Object$assign2[sideY] = hasY ? y + \"px\" : '', _Object$assign2[sideX] = hasX ? x + \"px\" : '', _Object$assign2.transform = '', _Object$assign2));\n}\n\nfunction computeStyles(_ref5) {\n var state = _ref5.state,\n options = _ref5.options;\n var _options$gpuAccelerat = options.gpuAcceleration,\n gpuAcceleration = _options$gpuAccelerat === void 0 ? true : _options$gpuAccelerat,\n _options$adaptive = options.adaptive,\n adaptive = _options$adaptive === void 0 ? true : _options$adaptive,\n _options$roundOffsets = options.roundOffsets,\n roundOffsets = _options$roundOffsets === void 0 ? true : _options$roundOffsets;\n var commonStyles = {\n placement: getBasePlacement(state.placement),\n variation: getVariation(state.placement),\n popper: state.elements.popper,\n popperRect: state.rects.popper,\n gpuAcceleration: gpuAcceleration,\n isFixed: state.options.strategy === 'fixed'\n };\n\n if (state.modifiersData.popperOffsets != null) {\n state.styles.popper = Object.assign({}, state.styles.popper, mapToStyles(Object.assign({}, commonStyles, {\n offsets: state.modifiersData.popperOffsets,\n position: state.options.strategy,\n adaptive: adaptive,\n roundOffsets: roundOffsets\n })));\n }\n\n if (state.modifiersData.arrow != null) {\n state.styles.arrow = Object.assign({}, state.styles.arrow, mapToStyles(Object.assign({}, commonStyles, {\n offsets: state.modifiersData.arrow,\n position: 'absolute',\n adaptive: false,\n roundOffsets: roundOffsets\n })));\n }\n\n state.attributes.popper = Object.assign({}, state.attributes.popper, {\n 'data-popper-placement': state.placement\n });\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'computeStyles',\n enabled: true,\n phase: 'beforeWrite',\n fn: computeStyles,\n data: {}\n};","import getWindow from \"../dom-utils/getWindow.js\"; // eslint-disable-next-line import/no-unused-modules\n\nvar passive = {\n passive: true\n};\n\nfunction effect(_ref) {\n var state = _ref.state,\n instance = _ref.instance,\n options = _ref.options;\n var _options$scroll = options.scroll,\n scroll = _options$scroll === void 0 ? true : _options$scroll,\n _options$resize = options.resize,\n resize = _options$resize === void 0 ? true : _options$resize;\n var window = getWindow(state.elements.popper);\n var scrollParents = [].concat(state.scrollParents.reference, state.scrollParents.popper);\n\n if (scroll) {\n scrollParents.forEach(function (scrollParent) {\n scrollParent.addEventListener('scroll', instance.update, passive);\n });\n }\n\n if (resize) {\n window.addEventListener('resize', instance.update, passive);\n }\n\n return function () {\n if (scroll) {\n scrollParents.forEach(function (scrollParent) {\n scrollParent.removeEventListener('scroll', instance.update, passive);\n });\n }\n\n if (resize) {\n window.removeEventListener('resize', instance.update, passive);\n }\n };\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'eventListeners',\n enabled: true,\n phase: 'write',\n fn: function fn() {},\n effect: effect,\n data: {}\n};","var hash = {\n left: 'right',\n right: 'left',\n bottom: 'top',\n top: 'bottom'\n};\nexport default function getOppositePlacement(placement) {\n return placement.replace(/left|right|bottom|top/g, function (matched) {\n return hash[matched];\n });\n}","var hash = {\n start: 'end',\n end: 'start'\n};\nexport default function getOppositeVariationPlacement(placement) {\n return placement.replace(/start|end/g, function (matched) {\n return hash[matched];\n });\n}","import getWindow from \"./getWindow.js\";\nexport default function getWindowScroll(node) {\n var win = getWindow(node);\n var scrollLeft = win.pageXOffset;\n var scrollTop = win.pageYOffset;\n return {\n scrollLeft: scrollLeft,\n scrollTop: scrollTop\n };\n}","import getBoundingClientRect from \"./getBoundingClientRect.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport getWindowScroll from \"./getWindowScroll.js\";\nexport default function getWindowScrollBarX(element) {\n // If has a CSS width greater than the viewport, then this will be\n // incorrect for RTL.\n // Popper 1 is broken in this case and never had a bug report so let's assume\n // it's not an issue. I don't think anyone ever specifies width on \n // anyway.\n // Browsers where the left scrollbar doesn't cause an issue report `0` for\n // this (e.g. Edge 2019, IE11, Safari)\n return getBoundingClientRect(getDocumentElement(element)).left + getWindowScroll(element).scrollLeft;\n}","import getWindow from \"./getWindow.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport getWindowScrollBarX from \"./getWindowScrollBarX.js\";\nimport isLayoutViewport from \"./isLayoutViewport.js\";\nexport default function getViewportRect(element, strategy) {\n var win = getWindow(element);\n var html = getDocumentElement(element);\n var visualViewport = win.visualViewport;\n var width = html.clientWidth;\n var height = html.clientHeight;\n var x = 0;\n var y = 0;\n\n if (visualViewport) {\n width = visualViewport.width;\n height = visualViewport.height;\n var layoutViewport = isLayoutViewport();\n\n if (layoutViewport || !layoutViewport && strategy === 'fixed') {\n x = visualViewport.offsetLeft;\n y = visualViewport.offsetTop;\n }\n }\n\n return {\n width: width,\n height: height,\n x: x + getWindowScrollBarX(element),\n y: y\n };\n}","import getDocumentElement from \"./getDocumentElement.js\";\nimport getComputedStyle from \"./getComputedStyle.js\";\nimport getWindowScrollBarX from \"./getWindowScrollBarX.js\";\nimport getWindowScroll from \"./getWindowScroll.js\";\nimport { max } from \"../utils/math.js\"; // Gets the entire size of the scrollable document area, even extending outside\n// of the `` and `` rect bounds if horizontally scrollable\n\nexport default function getDocumentRect(element) {\n var _element$ownerDocumen;\n\n var html = getDocumentElement(element);\n var winScroll = getWindowScroll(element);\n var body = (_element$ownerDocumen = element.ownerDocument) == null ? void 0 : _element$ownerDocumen.body;\n var width = max(html.scrollWidth, html.clientWidth, body ? body.scrollWidth : 0, body ? body.clientWidth : 0);\n var height = max(html.scrollHeight, html.clientHeight, body ? body.scrollHeight : 0, body ? body.clientHeight : 0);\n var x = -winScroll.scrollLeft + getWindowScrollBarX(element);\n var y = -winScroll.scrollTop;\n\n if (getComputedStyle(body || html).direction === 'rtl') {\n x += max(html.clientWidth, body ? body.clientWidth : 0) - width;\n }\n\n return {\n width: width,\n height: height,\n x: x,\n y: y\n };\n}","import getComputedStyle from \"./getComputedStyle.js\";\nexport default function isScrollParent(element) {\n // Firefox wants us to check `-x` and `-y` variations as well\n var _getComputedStyle = getComputedStyle(element),\n overflow = _getComputedStyle.overflow,\n overflowX = _getComputedStyle.overflowX,\n overflowY = _getComputedStyle.overflowY;\n\n return /auto|scroll|overlay|hidden/.test(overflow + overflowY + overflowX);\n}","import getParentNode from \"./getParentNode.js\";\nimport isScrollParent from \"./isScrollParent.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport { isHTMLElement } from \"./instanceOf.js\";\nexport default function getScrollParent(node) {\n if (['html', 'body', '#document'].indexOf(getNodeName(node)) >= 0) {\n // $FlowFixMe[incompatible-return]: assume body is always available\n return node.ownerDocument.body;\n }\n\n if (isHTMLElement(node) && isScrollParent(node)) {\n return node;\n }\n\n return getScrollParent(getParentNode(node));\n}","import getScrollParent from \"./getScrollParent.js\";\nimport getParentNode from \"./getParentNode.js\";\nimport getWindow from \"./getWindow.js\";\nimport isScrollParent from \"./isScrollParent.js\";\n/*\ngiven a DOM element, return the list of all scroll parents, up the list of ancesors\nuntil we get to the top window object. This list is what we attach scroll listeners\nto, because if any of these parent elements scroll, we'll need to re-calculate the\nreference element's position.\n*/\n\nexport default function listScrollParents(element, list) {\n var _element$ownerDocumen;\n\n if (list === void 0) {\n list = [];\n }\n\n var scrollParent = getScrollParent(element);\n var isBody = scrollParent === ((_element$ownerDocumen = element.ownerDocument) == null ? void 0 : _element$ownerDocumen.body);\n var win = getWindow(scrollParent);\n var target = isBody ? [win].concat(win.visualViewport || [], isScrollParent(scrollParent) ? scrollParent : []) : scrollParent;\n var updatedList = list.concat(target);\n return isBody ? updatedList : // $FlowFixMe[incompatible-call]: isBody tells us target will be an HTMLElement here\n updatedList.concat(listScrollParents(getParentNode(target)));\n}","export default function rectToClientRect(rect) {\n return Object.assign({}, rect, {\n left: rect.x,\n top: rect.y,\n right: rect.x + rect.width,\n bottom: rect.y + rect.height\n });\n}","import { viewport } from \"../enums.js\";\nimport getViewportRect from \"./getViewportRect.js\";\nimport getDocumentRect from \"./getDocumentRect.js\";\nimport listScrollParents from \"./listScrollParents.js\";\nimport getOffsetParent from \"./getOffsetParent.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport getComputedStyle from \"./getComputedStyle.js\";\nimport { isElement, isHTMLElement } from \"./instanceOf.js\";\nimport getBoundingClientRect from \"./getBoundingClientRect.js\";\nimport getParentNode from \"./getParentNode.js\";\nimport contains from \"./contains.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport rectToClientRect from \"../utils/rectToClientRect.js\";\nimport { max, min } from \"../utils/math.js\";\n\nfunction getInnerBoundingClientRect(element, strategy) {\n var rect = getBoundingClientRect(element, false, strategy === 'fixed');\n rect.top = rect.top + element.clientTop;\n rect.left = rect.left + element.clientLeft;\n rect.bottom = rect.top + element.clientHeight;\n rect.right = rect.left + element.clientWidth;\n rect.width = element.clientWidth;\n rect.height = element.clientHeight;\n rect.x = rect.left;\n rect.y = rect.top;\n return rect;\n}\n\nfunction getClientRectFromMixedType(element, clippingParent, strategy) {\n return clippingParent === viewport ? rectToClientRect(getViewportRect(element, strategy)) : isElement(clippingParent) ? getInnerBoundingClientRect(clippingParent, strategy) : rectToClientRect(getDocumentRect(getDocumentElement(element)));\n} // A \"clipping parent\" is an overflowable container with the characteristic of\n// clipping (or hiding) overflowing elements with a position different from\n// `initial`\n\n\nfunction getClippingParents(element) {\n var clippingParents = listScrollParents(getParentNode(element));\n var canEscapeClipping = ['absolute', 'fixed'].indexOf(getComputedStyle(element).position) >= 0;\n var clipperElement = canEscapeClipping && isHTMLElement(element) ? getOffsetParent(element) : element;\n\n if (!isElement(clipperElement)) {\n return [];\n } // $FlowFixMe[incompatible-return]: https://github.com/facebook/flow/issues/1414\n\n\n return clippingParents.filter(function (clippingParent) {\n return isElement(clippingParent) && contains(clippingParent, clipperElement) && getNodeName(clippingParent) !== 'body';\n });\n} // Gets the maximum area that the element is visible in due to any number of\n// clipping parents\n\n\nexport default function getClippingRect(element, boundary, rootBoundary, strategy) {\n var mainClippingParents = boundary === 'clippingParents' ? getClippingParents(element) : [].concat(boundary);\n var clippingParents = [].concat(mainClippingParents, [rootBoundary]);\n var firstClippingParent = clippingParents[0];\n var clippingRect = clippingParents.reduce(function (accRect, clippingParent) {\n var rect = getClientRectFromMixedType(element, clippingParent, strategy);\n accRect.top = max(rect.top, accRect.top);\n accRect.right = min(rect.right, accRect.right);\n accRect.bottom = min(rect.bottom, accRect.bottom);\n accRect.left = max(rect.left, accRect.left);\n return accRect;\n }, getClientRectFromMixedType(element, firstClippingParent, strategy));\n clippingRect.width = clippingRect.right - clippingRect.left;\n clippingRect.height = clippingRect.bottom - clippingRect.top;\n clippingRect.x = clippingRect.left;\n clippingRect.y = clippingRect.top;\n return clippingRect;\n}","import getBasePlacement from \"./getBasePlacement.js\";\nimport getVariation from \"./getVariation.js\";\nimport getMainAxisFromPlacement from \"./getMainAxisFromPlacement.js\";\nimport { top, right, bottom, left, start, end } from \"../enums.js\";\nexport default function computeOffsets(_ref) {\n var reference = _ref.reference,\n element = _ref.element,\n placement = _ref.placement;\n var basePlacement = placement ? getBasePlacement(placement) : null;\n var variation = placement ? getVariation(placement) : null;\n var commonX = reference.x + reference.width / 2 - element.width / 2;\n var commonY = reference.y + reference.height / 2 - element.height / 2;\n var offsets;\n\n switch (basePlacement) {\n case top:\n offsets = {\n x: commonX,\n y: reference.y - element.height\n };\n break;\n\n case bottom:\n offsets = {\n x: commonX,\n y: reference.y + reference.height\n };\n break;\n\n case right:\n offsets = {\n x: reference.x + reference.width,\n y: commonY\n };\n break;\n\n case left:\n offsets = {\n x: reference.x - element.width,\n y: commonY\n };\n break;\n\n default:\n offsets = {\n x: reference.x,\n y: reference.y\n };\n }\n\n var mainAxis = basePlacement ? getMainAxisFromPlacement(basePlacement) : null;\n\n if (mainAxis != null) {\n var len = mainAxis === 'y' ? 'height' : 'width';\n\n switch (variation) {\n case start:\n offsets[mainAxis] = offsets[mainAxis] - (reference[len] / 2 - element[len] / 2);\n break;\n\n case end:\n offsets[mainAxis] = offsets[mainAxis] + (reference[len] / 2 - element[len] / 2);\n break;\n\n default:\n }\n }\n\n return offsets;\n}","import getClippingRect from \"../dom-utils/getClippingRect.js\";\nimport getDocumentElement from \"../dom-utils/getDocumentElement.js\";\nimport getBoundingClientRect from \"../dom-utils/getBoundingClientRect.js\";\nimport computeOffsets from \"./computeOffsets.js\";\nimport rectToClientRect from \"./rectToClientRect.js\";\nimport { clippingParents, reference, popper, bottom, top, right, basePlacements, viewport } from \"../enums.js\";\nimport { isElement } from \"../dom-utils/instanceOf.js\";\nimport mergePaddingObject from \"./mergePaddingObject.js\";\nimport expandToHashMap from \"./expandToHashMap.js\"; // eslint-disable-next-line import/no-unused-modules\n\nexport default function detectOverflow(state, options) {\n if (options === void 0) {\n options = {};\n }\n\n var _options = options,\n _options$placement = _options.placement,\n placement = _options$placement === void 0 ? state.placement : _options$placement,\n _options$strategy = _options.strategy,\n strategy = _options$strategy === void 0 ? state.strategy : _options$strategy,\n _options$boundary = _options.boundary,\n boundary = _options$boundary === void 0 ? clippingParents : _options$boundary,\n _options$rootBoundary = _options.rootBoundary,\n rootBoundary = _options$rootBoundary === void 0 ? viewport : _options$rootBoundary,\n _options$elementConte = _options.elementContext,\n elementContext = _options$elementConte === void 0 ? popper : _options$elementConte,\n _options$altBoundary = _options.altBoundary,\n altBoundary = _options$altBoundary === void 0 ? false : _options$altBoundary,\n _options$padding = _options.padding,\n padding = _options$padding === void 0 ? 0 : _options$padding;\n var paddingObject = mergePaddingObject(typeof padding !== 'number' ? padding : expandToHashMap(padding, basePlacements));\n var altContext = elementContext === popper ? reference : popper;\n var popperRect = state.rects.popper;\n var element = state.elements[altBoundary ? altContext : elementContext];\n var clippingClientRect = getClippingRect(isElement(element) ? element : element.contextElement || getDocumentElement(state.elements.popper), boundary, rootBoundary, strategy);\n var referenceClientRect = getBoundingClientRect(state.elements.reference);\n var popperOffsets = computeOffsets({\n reference: referenceClientRect,\n element: popperRect,\n strategy: 'absolute',\n placement: placement\n });\n var popperClientRect = rectToClientRect(Object.assign({}, popperRect, popperOffsets));\n var elementClientRect = elementContext === popper ? popperClientRect : referenceClientRect; // positive = overflowing the clipping rect\n // 0 or negative = within the clipping rect\n\n var overflowOffsets = {\n top: clippingClientRect.top - elementClientRect.top + paddingObject.top,\n bottom: elementClientRect.bottom - clippingClientRect.bottom + paddingObject.bottom,\n left: clippingClientRect.left - elementClientRect.left + paddingObject.left,\n right: elementClientRect.right - clippingClientRect.right + paddingObject.right\n };\n var offsetData = state.modifiersData.offset; // Offsets can be applied only to the popper element\n\n if (elementContext === popper && offsetData) {\n var offset = offsetData[placement];\n Object.keys(overflowOffsets).forEach(function (key) {\n var multiply = [right, bottom].indexOf(key) >= 0 ? 1 : -1;\n var axis = [top, bottom].indexOf(key) >= 0 ? 'y' : 'x';\n overflowOffsets[key] += offset[axis] * multiply;\n });\n }\n\n return overflowOffsets;\n}","import getVariation from \"./getVariation.js\";\nimport { variationPlacements, basePlacements, placements as allPlacements } from \"../enums.js\";\nimport detectOverflow from \"./detectOverflow.js\";\nimport getBasePlacement from \"./getBasePlacement.js\";\nexport default function computeAutoPlacement(state, options) {\n if (options === void 0) {\n options = {};\n }\n\n var _options = options,\n placement = _options.placement,\n boundary = _options.boundary,\n rootBoundary = _options.rootBoundary,\n padding = _options.padding,\n flipVariations = _options.flipVariations,\n _options$allowedAutoP = _options.allowedAutoPlacements,\n allowedAutoPlacements = _options$allowedAutoP === void 0 ? allPlacements : _options$allowedAutoP;\n var variation = getVariation(placement);\n var placements = variation ? flipVariations ? variationPlacements : variationPlacements.filter(function (placement) {\n return getVariation(placement) === variation;\n }) : basePlacements;\n var allowedPlacements = placements.filter(function (placement) {\n return allowedAutoPlacements.indexOf(placement) >= 0;\n });\n\n if (allowedPlacements.length === 0) {\n allowedPlacements = placements;\n } // $FlowFixMe[incompatible-type]: Flow seems to have problems with two array unions...\n\n\n var overflows = allowedPlacements.reduce(function (acc, placement) {\n acc[placement] = detectOverflow(state, {\n placement: placement,\n boundary: boundary,\n rootBoundary: rootBoundary,\n padding: padding\n })[getBasePlacement(placement)];\n return acc;\n }, {});\n return Object.keys(overflows).sort(function (a, b) {\n return overflows[a] - overflows[b];\n });\n}","import getOppositePlacement from \"../utils/getOppositePlacement.js\";\nimport getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getOppositeVariationPlacement from \"../utils/getOppositeVariationPlacement.js\";\nimport detectOverflow from \"../utils/detectOverflow.js\";\nimport computeAutoPlacement from \"../utils/computeAutoPlacement.js\";\nimport { bottom, top, start, right, left, auto } from \"../enums.js\";\nimport getVariation from \"../utils/getVariation.js\"; // eslint-disable-next-line import/no-unused-modules\n\nfunction getExpandedFallbackPlacements(placement) {\n if (getBasePlacement(placement) === auto) {\n return [];\n }\n\n var oppositePlacement = getOppositePlacement(placement);\n return [getOppositeVariationPlacement(placement), oppositePlacement, getOppositeVariationPlacement(oppositePlacement)];\n}\n\nfunction flip(_ref) {\n var state = _ref.state,\n options = _ref.options,\n name = _ref.name;\n\n if (state.modifiersData[name]._skip) {\n return;\n }\n\n var _options$mainAxis = options.mainAxis,\n checkMainAxis = _options$mainAxis === void 0 ? true : _options$mainAxis,\n _options$altAxis = options.altAxis,\n checkAltAxis = _options$altAxis === void 0 ? true : _options$altAxis,\n specifiedFallbackPlacements = options.fallbackPlacements,\n padding = options.padding,\n boundary = options.boundary,\n rootBoundary = options.rootBoundary,\n altBoundary = options.altBoundary,\n _options$flipVariatio = options.flipVariations,\n flipVariations = _options$flipVariatio === void 0 ? true : _options$flipVariatio,\n allowedAutoPlacements = options.allowedAutoPlacements;\n var preferredPlacement = state.options.placement;\n var basePlacement = getBasePlacement(preferredPlacement);\n var isBasePlacement = basePlacement === preferredPlacement;\n var fallbackPlacements = specifiedFallbackPlacements || (isBasePlacement || !flipVariations ? [getOppositePlacement(preferredPlacement)] : getExpandedFallbackPlacements(preferredPlacement));\n var placements = [preferredPlacement].concat(fallbackPlacements).reduce(function (acc, placement) {\n return acc.concat(getBasePlacement(placement) === auto ? computeAutoPlacement(state, {\n placement: placement,\n boundary: boundary,\n rootBoundary: rootBoundary,\n padding: padding,\n flipVariations: flipVariations,\n allowedAutoPlacements: allowedAutoPlacements\n }) : placement);\n }, []);\n var referenceRect = state.rects.reference;\n var popperRect = state.rects.popper;\n var checksMap = new Map();\n var makeFallbackChecks = true;\n var firstFittingPlacement = placements[0];\n\n for (var i = 0; i < placements.length; i++) {\n var placement = placements[i];\n\n var _basePlacement = getBasePlacement(placement);\n\n var isStartVariation = getVariation(placement) === start;\n var isVertical = [top, bottom].indexOf(_basePlacement) >= 0;\n var len = isVertical ? 'width' : 'height';\n var overflow = detectOverflow(state, {\n placement: placement,\n boundary: boundary,\n rootBoundary: rootBoundary,\n altBoundary: altBoundary,\n padding: padding\n });\n var mainVariationSide = isVertical ? isStartVariation ? right : left : isStartVariation ? bottom : top;\n\n if (referenceRect[len] > popperRect[len]) {\n mainVariationSide = getOppositePlacement(mainVariationSide);\n }\n\n var altVariationSide = getOppositePlacement(mainVariationSide);\n var checks = [];\n\n if (checkMainAxis) {\n checks.push(overflow[_basePlacement] <= 0);\n }\n\n if (checkAltAxis) {\n checks.push(overflow[mainVariationSide] <= 0, overflow[altVariationSide] <= 0);\n }\n\n if (checks.every(function (check) {\n return check;\n })) {\n firstFittingPlacement = placement;\n makeFallbackChecks = false;\n break;\n }\n\n checksMap.set(placement, checks);\n }\n\n if (makeFallbackChecks) {\n // `2` may be desired in some cases – research later\n var numberOfChecks = flipVariations ? 3 : 1;\n\n var _loop = function _loop(_i) {\n var fittingPlacement = placements.find(function (placement) {\n var checks = checksMap.get(placement);\n\n if (checks) {\n return checks.slice(0, _i).every(function (check) {\n return check;\n });\n }\n });\n\n if (fittingPlacement) {\n firstFittingPlacement = fittingPlacement;\n return \"break\";\n }\n };\n\n for (var _i = numberOfChecks; _i > 0; _i--) {\n var _ret = _loop(_i);\n\n if (_ret === \"break\") break;\n }\n }\n\n if (state.placement !== firstFittingPlacement) {\n state.modifiersData[name]._skip = true;\n state.placement = firstFittingPlacement;\n state.reset = true;\n }\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'flip',\n enabled: true,\n phase: 'main',\n fn: flip,\n requiresIfExists: ['offset'],\n data: {\n _skip: false\n }\n};","import { top, bottom, left, right } from \"../enums.js\";\nimport detectOverflow from \"../utils/detectOverflow.js\";\n\nfunction getSideOffsets(overflow, rect, preventedOffsets) {\n if (preventedOffsets === void 0) {\n preventedOffsets = {\n x: 0,\n y: 0\n };\n }\n\n return {\n top: overflow.top - rect.height - preventedOffsets.y,\n right: overflow.right - rect.width + preventedOffsets.x,\n bottom: overflow.bottom - rect.height + preventedOffsets.y,\n left: overflow.left - rect.width - preventedOffsets.x\n };\n}\n\nfunction isAnySideFullyClipped(overflow) {\n return [top, right, bottom, left].some(function (side) {\n return overflow[side] >= 0;\n });\n}\n\nfunction hide(_ref) {\n var state = _ref.state,\n name = _ref.name;\n var referenceRect = state.rects.reference;\n var popperRect = state.rects.popper;\n var preventedOffsets = state.modifiersData.preventOverflow;\n var referenceOverflow = detectOverflow(state, {\n elementContext: 'reference'\n });\n var popperAltOverflow = detectOverflow(state, {\n altBoundary: true\n });\n var referenceClippingOffsets = getSideOffsets(referenceOverflow, referenceRect);\n var popperEscapeOffsets = getSideOffsets(popperAltOverflow, popperRect, preventedOffsets);\n var isReferenceHidden = isAnySideFullyClipped(referenceClippingOffsets);\n var hasPopperEscaped = isAnySideFullyClipped(popperEscapeOffsets);\n state.modifiersData[name] = {\n referenceClippingOffsets: referenceClippingOffsets,\n popperEscapeOffsets: popperEscapeOffsets,\n isReferenceHidden: isReferenceHidden,\n hasPopperEscaped: hasPopperEscaped\n };\n state.attributes.popper = Object.assign({}, state.attributes.popper, {\n 'data-popper-reference-hidden': isReferenceHidden,\n 'data-popper-escaped': hasPopperEscaped\n });\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'hide',\n enabled: true,\n phase: 'main',\n requiresIfExists: ['preventOverflow'],\n fn: hide\n};","import getBasePlacement from \"../utils/getBasePlacement.js\";\nimport { top, left, right, placements } from \"../enums.js\"; // eslint-disable-next-line import/no-unused-modules\n\nexport function distanceAndSkiddingToXY(placement, rects, offset) {\n var basePlacement = getBasePlacement(placement);\n var invertDistance = [left, top].indexOf(basePlacement) >= 0 ? -1 : 1;\n\n var _ref = typeof offset === 'function' ? offset(Object.assign({}, rects, {\n placement: placement\n })) : offset,\n skidding = _ref[0],\n distance = _ref[1];\n\n skidding = skidding || 0;\n distance = (distance || 0) * invertDistance;\n return [left, right].indexOf(basePlacement) >= 0 ? {\n x: distance,\n y: skidding\n } : {\n x: skidding,\n y: distance\n };\n}\n\nfunction offset(_ref2) {\n var state = _ref2.state,\n options = _ref2.options,\n name = _ref2.name;\n var _options$offset = options.offset,\n offset = _options$offset === void 0 ? [0, 0] : _options$offset;\n var data = placements.reduce(function (acc, placement) {\n acc[placement] = distanceAndSkiddingToXY(placement, state.rects, offset);\n return acc;\n }, {});\n var _data$state$placement = data[state.placement],\n x = _data$state$placement.x,\n y = _data$state$placement.y;\n\n if (state.modifiersData.popperOffsets != null) {\n state.modifiersData.popperOffsets.x += x;\n state.modifiersData.popperOffsets.y += y;\n }\n\n state.modifiersData[name] = data;\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'offset',\n enabled: true,\n phase: 'main',\n requires: ['popperOffsets'],\n fn: offset\n};","import computeOffsets from \"../utils/computeOffsets.js\";\n\nfunction popperOffsets(_ref) {\n var state = _ref.state,\n name = _ref.name;\n // Offsets are the actual position the popper needs to have to be\n // properly positioned near its reference element\n // This is the most basic placement, and will be adjusted by\n // the modifiers in the next step\n state.modifiersData[name] = computeOffsets({\n reference: state.rects.reference,\n element: state.rects.popper,\n strategy: 'absolute',\n placement: state.placement\n });\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'popperOffsets',\n enabled: true,\n phase: 'read',\n fn: popperOffsets,\n data: {}\n};","export default function getAltAxis(axis) {\n return axis === 'x' ? 'y' : 'x';\n}","import { top, left, right, bottom, start } from \"../enums.js\";\nimport getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getMainAxisFromPlacement from \"../utils/getMainAxisFromPlacement.js\";\nimport getAltAxis from \"../utils/getAltAxis.js\";\nimport { within, withinMaxClamp } from \"../utils/within.js\";\nimport getLayoutRect from \"../dom-utils/getLayoutRect.js\";\nimport getOffsetParent from \"../dom-utils/getOffsetParent.js\";\nimport detectOverflow from \"../utils/detectOverflow.js\";\nimport getVariation from \"../utils/getVariation.js\";\nimport getFreshSideObject from \"../utils/getFreshSideObject.js\";\nimport { min as mathMin, max as mathMax } from \"../utils/math.js\";\n\nfunction preventOverflow(_ref) {\n var state = _ref.state,\n options = _ref.options,\n name = _ref.name;\n var _options$mainAxis = options.mainAxis,\n checkMainAxis = _options$mainAxis === void 0 ? true : _options$mainAxis,\n _options$altAxis = options.altAxis,\n checkAltAxis = _options$altAxis === void 0 ? false : _options$altAxis,\n boundary = options.boundary,\n rootBoundary = options.rootBoundary,\n altBoundary = options.altBoundary,\n padding = options.padding,\n _options$tether = options.tether,\n tether = _options$tether === void 0 ? true : _options$tether,\n _options$tetherOffset = options.tetherOffset,\n tetherOffset = _options$tetherOffset === void 0 ? 0 : _options$tetherOffset;\n var overflow = detectOverflow(state, {\n boundary: boundary,\n rootBoundary: rootBoundary,\n padding: padding,\n altBoundary: altBoundary\n });\n var basePlacement = getBasePlacement(state.placement);\n var variation = getVariation(state.placement);\n var isBasePlacement = !variation;\n var mainAxis = getMainAxisFromPlacement(basePlacement);\n var altAxis = getAltAxis(mainAxis);\n var popperOffsets = state.modifiersData.popperOffsets;\n var referenceRect = state.rects.reference;\n var popperRect = state.rects.popper;\n var tetherOffsetValue = typeof tetherOffset === 'function' ? tetherOffset(Object.assign({}, state.rects, {\n placement: state.placement\n })) : tetherOffset;\n var normalizedTetherOffsetValue = typeof tetherOffsetValue === 'number' ? {\n mainAxis: tetherOffsetValue,\n altAxis: tetherOffsetValue\n } : Object.assign({\n mainAxis: 0,\n altAxis: 0\n }, tetherOffsetValue);\n var offsetModifierState = state.modifiersData.offset ? state.modifiersData.offset[state.placement] : null;\n var data = {\n x: 0,\n y: 0\n };\n\n if (!popperOffsets) {\n return;\n }\n\n if (checkMainAxis) {\n var _offsetModifierState$;\n\n var mainSide = mainAxis === 'y' ? top : left;\n var altSide = mainAxis === 'y' ? bottom : right;\n var len = mainAxis === 'y' ? 'height' : 'width';\n var offset = popperOffsets[mainAxis];\n var min = offset + overflow[mainSide];\n var max = offset - overflow[altSide];\n var additive = tether ? -popperRect[len] / 2 : 0;\n var minLen = variation === start ? referenceRect[len] : popperRect[len];\n var maxLen = variation === start ? -popperRect[len] : -referenceRect[len]; // We need to include the arrow in the calculation so the arrow doesn't go\n // outside the reference bounds\n\n var arrowElement = state.elements.arrow;\n var arrowRect = tether && arrowElement ? getLayoutRect(arrowElement) : {\n width: 0,\n height: 0\n };\n var arrowPaddingObject = state.modifiersData['arrow#persistent'] ? state.modifiersData['arrow#persistent'].padding : getFreshSideObject();\n var arrowPaddingMin = arrowPaddingObject[mainSide];\n var arrowPaddingMax = arrowPaddingObject[altSide]; // If the reference length is smaller than the arrow length, we don't want\n // to include its full size in the calculation. If the reference is small\n // and near the edge of a boundary, the popper can overflow even if the\n // reference is not overflowing as well (e.g. virtual elements with no\n // width or height)\n\n var arrowLen = within(0, referenceRect[len], arrowRect[len]);\n var minOffset = isBasePlacement ? referenceRect[len] / 2 - additive - arrowLen - arrowPaddingMin - normalizedTetherOffsetValue.mainAxis : minLen - arrowLen - arrowPaddingMin - normalizedTetherOffsetValue.mainAxis;\n var maxOffset = isBasePlacement ? -referenceRect[len] / 2 + additive + arrowLen + arrowPaddingMax + normalizedTetherOffsetValue.mainAxis : maxLen + arrowLen + arrowPaddingMax + normalizedTetherOffsetValue.mainAxis;\n var arrowOffsetParent = state.elements.arrow && getOffsetParent(state.elements.arrow);\n var clientOffset = arrowOffsetParent ? mainAxis === 'y' ? arrowOffsetParent.clientTop || 0 : arrowOffsetParent.clientLeft || 0 : 0;\n var offsetModifierValue = (_offsetModifierState$ = offsetModifierState == null ? void 0 : offsetModifierState[mainAxis]) != null ? _offsetModifierState$ : 0;\n var tetherMin = offset + minOffset - offsetModifierValue - clientOffset;\n var tetherMax = offset + maxOffset - offsetModifierValue;\n var preventedOffset = within(tether ? mathMin(min, tetherMin) : min, offset, tether ? mathMax(max, tetherMax) : max);\n popperOffsets[mainAxis] = preventedOffset;\n data[mainAxis] = preventedOffset - offset;\n }\n\n if (checkAltAxis) {\n var _offsetModifierState$2;\n\n var _mainSide = mainAxis === 'x' ? top : left;\n\n var _altSide = mainAxis === 'x' ? bottom : right;\n\n var _offset = popperOffsets[altAxis];\n\n var _len = altAxis === 'y' ? 'height' : 'width';\n\n var _min = _offset + overflow[_mainSide];\n\n var _max = _offset - overflow[_altSide];\n\n var isOriginSide = [top, left].indexOf(basePlacement) !== -1;\n\n var _offsetModifierValue = (_offsetModifierState$2 = offsetModifierState == null ? void 0 : offsetModifierState[altAxis]) != null ? _offsetModifierState$2 : 0;\n\n var _tetherMin = isOriginSide ? _min : _offset - referenceRect[_len] - popperRect[_len] - _offsetModifierValue + normalizedTetherOffsetValue.altAxis;\n\n var _tetherMax = isOriginSide ? _offset + referenceRect[_len] + popperRect[_len] - _offsetModifierValue - normalizedTetherOffsetValue.altAxis : _max;\n\n var _preventedOffset = tether && isOriginSide ? withinMaxClamp(_tetherMin, _offset, _tetherMax) : within(tether ? _tetherMin : _min, _offset, tether ? _tetherMax : _max);\n\n popperOffsets[altAxis] = _preventedOffset;\n data[altAxis] = _preventedOffset - _offset;\n }\n\n state.modifiersData[name] = data;\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'preventOverflow',\n enabled: true,\n phase: 'main',\n fn: preventOverflow,\n requiresIfExists: ['offset']\n};","export default function getHTMLElementScroll(element) {\n return {\n scrollLeft: element.scrollLeft,\n scrollTop: element.scrollTop\n };\n}","import getWindowScroll from \"./getWindowScroll.js\";\nimport getWindow from \"./getWindow.js\";\nimport { isHTMLElement } from \"./instanceOf.js\";\nimport getHTMLElementScroll from \"./getHTMLElementScroll.js\";\nexport default function getNodeScroll(node) {\n if (node === getWindow(node) || !isHTMLElement(node)) {\n return getWindowScroll(node);\n } else {\n return getHTMLElementScroll(node);\n }\n}","import getBoundingClientRect from \"./getBoundingClientRect.js\";\nimport getNodeScroll from \"./getNodeScroll.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport { isHTMLElement } from \"./instanceOf.js\";\nimport getWindowScrollBarX from \"./getWindowScrollBarX.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport isScrollParent from \"./isScrollParent.js\";\nimport { round } from \"../utils/math.js\";\n\nfunction isElementScaled(element) {\n var rect = element.getBoundingClientRect();\n var scaleX = round(rect.width) / element.offsetWidth || 1;\n var scaleY = round(rect.height) / element.offsetHeight || 1;\n return scaleX !== 1 || scaleY !== 1;\n} // Returns the composite rect of an element relative to its offsetParent.\n// Composite means it takes into account transforms as well as layout.\n\n\nexport default function getCompositeRect(elementOrVirtualElement, offsetParent, isFixed) {\n if (isFixed === void 0) {\n isFixed = false;\n }\n\n var isOffsetParentAnElement = isHTMLElement(offsetParent);\n var offsetParentIsScaled = isHTMLElement(offsetParent) && isElementScaled(offsetParent);\n var documentElement = getDocumentElement(offsetParent);\n var rect = getBoundingClientRect(elementOrVirtualElement, offsetParentIsScaled, isFixed);\n var scroll = {\n scrollLeft: 0,\n scrollTop: 0\n };\n var offsets = {\n x: 0,\n y: 0\n };\n\n if (isOffsetParentAnElement || !isOffsetParentAnElement && !isFixed) {\n if (getNodeName(offsetParent) !== 'body' || // https://github.com/popperjs/popper-core/issues/1078\n isScrollParent(documentElement)) {\n scroll = getNodeScroll(offsetParent);\n }\n\n if (isHTMLElement(offsetParent)) {\n offsets = getBoundingClientRect(offsetParent, true);\n offsets.x += offsetParent.clientLeft;\n offsets.y += offsetParent.clientTop;\n } else if (documentElement) {\n offsets.x = getWindowScrollBarX(documentElement);\n }\n }\n\n return {\n x: rect.left + scroll.scrollLeft - offsets.x,\n y: rect.top + scroll.scrollTop - offsets.y,\n width: rect.width,\n height: rect.height\n };\n}","import { modifierPhases } from \"../enums.js\"; // source: https://stackoverflow.com/questions/49875255\n\nfunction order(modifiers) {\n var map = new Map();\n var visited = new Set();\n var result = [];\n modifiers.forEach(function (modifier) {\n map.set(modifier.name, modifier);\n }); // On visiting object, check for its dependencies and visit them recursively\n\n function sort(modifier) {\n visited.add(modifier.name);\n var requires = [].concat(modifier.requires || [], modifier.requiresIfExists || []);\n requires.forEach(function (dep) {\n if (!visited.has(dep)) {\n var depModifier = map.get(dep);\n\n if (depModifier) {\n sort(depModifier);\n }\n }\n });\n result.push(modifier);\n }\n\n modifiers.forEach(function (modifier) {\n if (!visited.has(modifier.name)) {\n // check for visited object\n sort(modifier);\n }\n });\n return result;\n}\n\nexport default function orderModifiers(modifiers) {\n // order based on dependencies\n var orderedModifiers = order(modifiers); // order based on phase\n\n return modifierPhases.reduce(function (acc, phase) {\n return acc.concat(orderedModifiers.filter(function (modifier) {\n return modifier.phase === phase;\n }));\n }, []);\n}","export default function debounce(fn) {\n var pending;\n return function () {\n if (!pending) {\n pending = new Promise(function (resolve) {\n Promise.resolve().then(function () {\n pending = undefined;\n resolve(fn());\n });\n });\n }\n\n return pending;\n };\n}","export default function mergeByName(modifiers) {\n var merged = modifiers.reduce(function (merged, current) {\n var existing = merged[current.name];\n merged[current.name] = existing ? Object.assign({}, existing, current, {\n options: Object.assign({}, existing.options, current.options),\n data: Object.assign({}, existing.data, current.data)\n }) : current;\n return merged;\n }, {}); // IE11 does not support Object.values\n\n return Object.keys(merged).map(function (key) {\n return merged[key];\n });\n}","import getCompositeRect from \"./dom-utils/getCompositeRect.js\";\nimport getLayoutRect from \"./dom-utils/getLayoutRect.js\";\nimport listScrollParents from \"./dom-utils/listScrollParents.js\";\nimport getOffsetParent from \"./dom-utils/getOffsetParent.js\";\nimport orderModifiers from \"./utils/orderModifiers.js\";\nimport debounce from \"./utils/debounce.js\";\nimport mergeByName from \"./utils/mergeByName.js\";\nimport detectOverflow from \"./utils/detectOverflow.js\";\nimport { isElement } from \"./dom-utils/instanceOf.js\";\nvar DEFAULT_OPTIONS = {\n placement: 'bottom',\n modifiers: [],\n strategy: 'absolute'\n};\n\nfunction areValidElements() {\n for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {\n args[_key] = arguments[_key];\n }\n\n return !args.some(function (element) {\n return !(element && typeof element.getBoundingClientRect === 'function');\n });\n}\n\nexport function popperGenerator(generatorOptions) {\n if (generatorOptions === void 0) {\n generatorOptions = {};\n }\n\n var _generatorOptions = generatorOptions,\n _generatorOptions$def = _generatorOptions.defaultModifiers,\n defaultModifiers = _generatorOptions$def === void 0 ? [] : _generatorOptions$def,\n _generatorOptions$def2 = _generatorOptions.defaultOptions,\n defaultOptions = _generatorOptions$def2 === void 0 ? DEFAULT_OPTIONS : _generatorOptions$def2;\n return function createPopper(reference, popper, options) {\n if (options === void 0) {\n options = defaultOptions;\n }\n\n var state = {\n placement: 'bottom',\n orderedModifiers: [],\n options: Object.assign({}, DEFAULT_OPTIONS, defaultOptions),\n modifiersData: {},\n elements: {\n reference: reference,\n popper: popper\n },\n attributes: {},\n styles: {}\n };\n var effectCleanupFns = [];\n var isDestroyed = false;\n var instance = {\n state: state,\n setOptions: function setOptions(setOptionsAction) {\n var options = typeof setOptionsAction === 'function' ? setOptionsAction(state.options) : setOptionsAction;\n cleanupModifierEffects();\n state.options = Object.assign({}, defaultOptions, state.options, options);\n state.scrollParents = {\n reference: isElement(reference) ? listScrollParents(reference) : reference.contextElement ? listScrollParents(reference.contextElement) : [],\n popper: listScrollParents(popper)\n }; // Orders the modifiers based on their dependencies and `phase`\n // properties\n\n var orderedModifiers = orderModifiers(mergeByName([].concat(defaultModifiers, state.options.modifiers))); // Strip out disabled modifiers\n\n state.orderedModifiers = orderedModifiers.filter(function (m) {\n return m.enabled;\n });\n runModifierEffects();\n return instance.update();\n },\n // Sync update – it will always be executed, even if not necessary. This\n // is useful for low frequency updates where sync behavior simplifies the\n // logic.\n // For high frequency updates (e.g. `resize` and `scroll` events), always\n // prefer the async Popper#update method\n forceUpdate: function forceUpdate() {\n if (isDestroyed) {\n return;\n }\n\n var _state$elements = state.elements,\n reference = _state$elements.reference,\n popper = _state$elements.popper; // Don't proceed if `reference` or `popper` are not valid elements\n // anymore\n\n if (!areValidElements(reference, popper)) {\n return;\n } // Store the reference and popper rects to be read by modifiers\n\n\n state.rects = {\n reference: getCompositeRect(reference, getOffsetParent(popper), state.options.strategy === 'fixed'),\n popper: getLayoutRect(popper)\n }; // Modifiers have the ability to reset the current update cycle. The\n // most common use case for this is the `flip` modifier changing the\n // placement, which then needs to re-run all the modifiers, because the\n // logic was previously ran for the previous placement and is therefore\n // stale/incorrect\n\n state.reset = false;\n state.placement = state.options.placement; // On each update cycle, the `modifiersData` property for each modifier\n // is filled with the initial data specified by the modifier. This means\n // it doesn't persist and is fresh on each update.\n // To ensure persistent data, use `${name}#persistent`\n\n state.orderedModifiers.forEach(function (modifier) {\n return state.modifiersData[modifier.name] = Object.assign({}, modifier.data);\n });\n\n for (var index = 0; index < state.orderedModifiers.length; index++) {\n if (state.reset === true) {\n state.reset = false;\n index = -1;\n continue;\n }\n\n var _state$orderedModifie = state.orderedModifiers[index],\n fn = _state$orderedModifie.fn,\n _state$orderedModifie2 = _state$orderedModifie.options,\n _options = _state$orderedModifie2 === void 0 ? {} : _state$orderedModifie2,\n name = _state$orderedModifie.name;\n\n if (typeof fn === 'function') {\n state = fn({\n state: state,\n options: _options,\n name: name,\n instance: instance\n }) || state;\n }\n }\n },\n // Async and optimistically optimized update – it will not be executed if\n // not necessary (debounced to run at most once-per-tick)\n update: debounce(function () {\n return new Promise(function (resolve) {\n instance.forceUpdate();\n resolve(state);\n });\n }),\n destroy: function destroy() {\n cleanupModifierEffects();\n isDestroyed = true;\n }\n };\n\n if (!areValidElements(reference, popper)) {\n return instance;\n }\n\n instance.setOptions(options).then(function (state) {\n if (!isDestroyed && options.onFirstUpdate) {\n options.onFirstUpdate(state);\n }\n }); // Modifiers have the ability to execute arbitrary code before the first\n // update cycle runs. They will be executed in the same order as the update\n // cycle. This is useful when a modifier adds some persistent data that\n // other modifiers need to use, but the modifier is run after the dependent\n // one.\n\n function runModifierEffects() {\n state.orderedModifiers.forEach(function (_ref) {\n var name = _ref.name,\n _ref$options = _ref.options,\n options = _ref$options === void 0 ? {} : _ref$options,\n effect = _ref.effect;\n\n if (typeof effect === 'function') {\n var cleanupFn = effect({\n state: state,\n name: name,\n instance: instance,\n options: options\n });\n\n var noopFn = function noopFn() {};\n\n effectCleanupFns.push(cleanupFn || noopFn);\n }\n });\n }\n\n function cleanupModifierEffects() {\n effectCleanupFns.forEach(function (fn) {\n return fn();\n });\n effectCleanupFns = [];\n }\n\n return instance;\n };\n}\nexport var createPopper = /*#__PURE__*/popperGenerator(); // eslint-disable-next-line import/no-unused-modules\n\nexport { detectOverflow };","import { popperGenerator, detectOverflow } from \"./createPopper.js\";\nimport eventListeners from \"./modifiers/eventListeners.js\";\nimport popperOffsets from \"./modifiers/popperOffsets.js\";\nimport computeStyles from \"./modifiers/computeStyles.js\";\nimport applyStyles from \"./modifiers/applyStyles.js\";\nimport offset from \"./modifiers/offset.js\";\nimport flip from \"./modifiers/flip.js\";\nimport preventOverflow from \"./modifiers/preventOverflow.js\";\nimport arrow from \"./modifiers/arrow.js\";\nimport hide from \"./modifiers/hide.js\";\nvar defaultModifiers = [eventListeners, popperOffsets, computeStyles, applyStyles, offset, flip, preventOverflow, arrow, hide];\nvar createPopper = /*#__PURE__*/popperGenerator({\n defaultModifiers: defaultModifiers\n}); // eslint-disable-next-line import/no-unused-modules\n\nexport { createPopper, popperGenerator, defaultModifiers, detectOverflow }; // eslint-disable-next-line import/no-unused-modules\n\nexport { createPopper as createPopperLite } from \"./popper-lite.js\"; // eslint-disable-next-line import/no-unused-modules\n\nexport * from \"./modifiers/index.js\";","import { generateUtilityClass } from '../generateUtilityClass';\nimport { generateUtilityClasses } from '../generateUtilityClasses';\nconst COMPONENT_NAME = 'Popper';\nexport function getPopperUtilityClass(slot) {\n return generateUtilityClass(COMPONENT_NAME, slot);\n}\nexport const popperClasses = generateUtilityClasses(COMPONENT_NAME, ['root']);","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"anchorEl\", \"children\", \"direction\", \"disablePortal\", \"modifiers\", \"open\", \"placement\", \"popperOptions\", \"popperRef\", \"slotProps\", \"slots\", \"TransitionProps\", \"ownerState\"],\n _excluded2 = [\"anchorEl\", \"children\", \"container\", \"direction\", \"disablePortal\", \"keepMounted\", \"modifiers\", \"open\", \"placement\", \"popperOptions\", \"popperRef\", \"style\", \"transition\", \"slotProps\", \"slots\"];\nimport * as React from 'react';\nimport { chainPropTypes, HTMLElementType, refType, unstable_ownerDocument as ownerDocument, unstable_useEnhancedEffect as useEnhancedEffect, unstable_useForkRef as useForkRef } from '@mui/utils';\nimport { createPopper } from '@popperjs/core';\nimport PropTypes from 'prop-types';\nimport { unstable_composeClasses as composeClasses } from '../composeClasses';\nimport { Portal } from '../Portal';\nimport { getPopperUtilityClass } from './popperClasses';\nimport { useSlotProps } from '../utils';\nimport { useClassNamesOverride } from '../utils/ClassNameConfigurator';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nfunction flipPlacement(placement, direction) {\n if (direction === 'ltr') {\n return placement;\n }\n switch (placement) {\n case 'bottom-end':\n return 'bottom-start';\n case 'bottom-start':\n return 'bottom-end';\n case 'top-end':\n return 'top-start';\n case 'top-start':\n return 'top-end';\n default:\n return placement;\n }\n}\nfunction resolveAnchorEl(anchorEl) {\n return typeof anchorEl === 'function' ? anchorEl() : anchorEl;\n}\nfunction isHTMLElement(element) {\n return element.nodeType !== undefined;\n}\nfunction isVirtualElement(element) {\n return !isHTMLElement(element);\n}\nconst useUtilityClasses = () => {\n const slots = {\n root: ['root']\n };\n return composeClasses(slots, useClassNamesOverride(getPopperUtilityClass));\n};\nconst defaultPopperOptions = {};\nconst PopperTooltip = /*#__PURE__*/React.forwardRef(function PopperTooltip(props, forwardedRef) {\n var _slots$root;\n const {\n anchorEl,\n children,\n direction,\n disablePortal,\n modifiers,\n open,\n placement: initialPlacement,\n popperOptions,\n popperRef: popperRefProp,\n slotProps = {},\n slots = {},\n TransitionProps\n // @ts-ignore internal logic\n // prevent from spreading to DOM, it can come from the parent component e.g. Select.\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const tooltipRef = React.useRef(null);\n const ownRef = useForkRef(tooltipRef, forwardedRef);\n const popperRef = React.useRef(null);\n const handlePopperRef = useForkRef(popperRef, popperRefProp);\n const handlePopperRefRef = React.useRef(handlePopperRef);\n useEnhancedEffect(() => {\n handlePopperRefRef.current = handlePopperRef;\n }, [handlePopperRef]);\n React.useImperativeHandle(popperRefProp, () => popperRef.current, []);\n const rtlPlacement = flipPlacement(initialPlacement, direction);\n /**\n * placement initialized from prop but can change during lifetime if modifiers.flip.\n * modifiers.flip is essentially a flip for controlled/uncontrolled behavior\n */\n const [placement, setPlacement] = React.useState(rtlPlacement);\n const [resolvedAnchorElement, setResolvedAnchorElement] = React.useState(resolveAnchorEl(anchorEl));\n React.useEffect(() => {\n if (popperRef.current) {\n popperRef.current.forceUpdate();\n }\n });\n React.useEffect(() => {\n if (anchorEl) {\n setResolvedAnchorElement(resolveAnchorEl(anchorEl));\n }\n }, [anchorEl]);\n useEnhancedEffect(() => {\n if (!resolvedAnchorElement || !open) {\n return undefined;\n }\n const handlePopperUpdate = data => {\n setPlacement(data.placement);\n };\n if (process.env.NODE_ENV !== 'production') {\n if (resolvedAnchorElement && isHTMLElement(resolvedAnchorElement) && resolvedAnchorElement.nodeType === 1) {\n const box = resolvedAnchorElement.getBoundingClientRect();\n if (process.env.NODE_ENV !== 'test' && box.top === 0 && box.left === 0 && box.right === 0 && box.bottom === 0) {\n console.warn(['MUI: The `anchorEl` prop provided to the component is invalid.', 'The anchor element should be part of the document layout.', \"Make sure the element is present in the document or that it's not display none.\"].join('\\n'));\n }\n }\n }\n let popperModifiers = [{\n name: 'preventOverflow',\n options: {\n altBoundary: disablePortal\n }\n }, {\n name: 'flip',\n options: {\n altBoundary: disablePortal\n }\n }, {\n name: 'onUpdate',\n enabled: true,\n phase: 'afterWrite',\n fn: ({\n state\n }) => {\n handlePopperUpdate(state);\n }\n }];\n if (modifiers != null) {\n popperModifiers = popperModifiers.concat(modifiers);\n }\n if (popperOptions && popperOptions.modifiers != null) {\n popperModifiers = popperModifiers.concat(popperOptions.modifiers);\n }\n const popper = createPopper(resolvedAnchorElement, tooltipRef.current, _extends({\n placement: rtlPlacement\n }, popperOptions, {\n modifiers: popperModifiers\n }));\n handlePopperRefRef.current(popper);\n return () => {\n popper.destroy();\n handlePopperRefRef.current(null);\n };\n }, [resolvedAnchorElement, disablePortal, modifiers, open, popperOptions, rtlPlacement]);\n const childProps = {\n placement: placement\n };\n if (TransitionProps !== null) {\n childProps.TransitionProps = TransitionProps;\n }\n const classes = useUtilityClasses();\n const Root = (_slots$root = slots.root) != null ? _slots$root : 'div';\n const rootProps = useSlotProps({\n elementType: Root,\n externalSlotProps: slotProps.root,\n externalForwardedProps: other,\n additionalProps: {\n role: 'tooltip',\n ref: ownRef\n },\n ownerState: props,\n className: classes.root\n });\n return /*#__PURE__*/_jsx(Root, _extends({}, rootProps, {\n children: typeof children === 'function' ? children(childProps) : children\n }));\n});\n\n/**\n * Poppers rely on the 3rd party library [Popper.js](https://popper.js.org/docs/v2/) for positioning.\n *\n * Demos:\n *\n * - [Popper](https://mui.com/base-ui/react-popper/)\n *\n * API:\n *\n * - [Popper API](https://mui.com/base-ui/react-popper/components-api/#popper)\n */\nconst Popper = /*#__PURE__*/React.forwardRef(function Popper(props, forwardedRef) {\n const {\n anchorEl,\n children,\n container: containerProp,\n direction = 'ltr',\n disablePortal = false,\n keepMounted = false,\n modifiers,\n open,\n placement = 'bottom',\n popperOptions = defaultPopperOptions,\n popperRef,\n style,\n transition = false,\n slotProps = {},\n slots = {}\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded2);\n const [exited, setExited] = React.useState(true);\n const handleEnter = () => {\n setExited(false);\n };\n const handleExited = () => {\n setExited(true);\n };\n if (!keepMounted && !open && (!transition || exited)) {\n return null;\n }\n\n // If the container prop is provided, use that\n // If the anchorEl prop is provided, use its parent body element as the container\n // If neither are provided let the Modal take care of choosing the container\n let container;\n if (containerProp) {\n container = containerProp;\n } else if (anchorEl) {\n const resolvedAnchorEl = resolveAnchorEl(anchorEl);\n container = resolvedAnchorEl && isHTMLElement(resolvedAnchorEl) ? ownerDocument(resolvedAnchorEl).body : ownerDocument(null).body;\n }\n const display = !open && keepMounted && (!transition || exited) ? 'none' : undefined;\n const transitionProps = transition ? {\n in: open,\n onEnter: handleEnter,\n onExited: handleExited\n } : undefined;\n return /*#__PURE__*/_jsx(Portal, {\n disablePortal: disablePortal,\n container: container,\n children: /*#__PURE__*/_jsx(PopperTooltip, _extends({\n anchorEl: anchorEl,\n direction: direction,\n disablePortal: disablePortal,\n modifiers: modifiers,\n ref: forwardedRef,\n open: transition ? !exited : open,\n placement: placement,\n popperOptions: popperOptions,\n popperRef: popperRef,\n slotProps: slotProps,\n slots: slots\n }, other, {\n style: _extends({\n // Prevents scroll issue, waiting for Popper.js to add this style once initiated.\n position: 'fixed',\n // Fix Popper.js display issue\n top: 0,\n left: 0,\n display\n }, style),\n TransitionProps: transitionProps,\n children: children\n }))\n });\n});\nprocess.env.NODE_ENV !== \"production\" ? Popper.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * An HTML element, [virtualElement](https://popper.js.org/docs/v2/virtual-elements/),\n * or a function that returns either.\n * It's used to set the position of the popper.\n * The return value will passed as the reference object of the Popper instance.\n */\n anchorEl: chainPropTypes(PropTypes.oneOfType([HTMLElementType, PropTypes.object, PropTypes.func]), props => {\n if (props.open) {\n const resolvedAnchorEl = resolveAnchorEl(props.anchorEl);\n if (resolvedAnchorEl && isHTMLElement(resolvedAnchorEl) && resolvedAnchorEl.nodeType === 1) {\n const box = resolvedAnchorEl.getBoundingClientRect();\n if (process.env.NODE_ENV !== 'test' && box.top === 0 && box.left === 0 && box.right === 0 && box.bottom === 0) {\n return new Error(['MUI: The `anchorEl` prop provided to the component is invalid.', 'The anchor element should be part of the document layout.', \"Make sure the element is present in the document or that it's not display none.\"].join('\\n'));\n }\n } else if (!resolvedAnchorEl || typeof resolvedAnchorEl.getBoundingClientRect !== 'function' || isVirtualElement(resolvedAnchorEl) && resolvedAnchorEl.contextElement != null && resolvedAnchorEl.contextElement.nodeType !== 1) {\n return new Error(['MUI: The `anchorEl` prop provided to the component is invalid.', 'It should be an HTML element instance or a virtualElement ', '(https://popper.js.org/docs/v2/virtual-elements/).'].join('\\n'));\n }\n }\n return null;\n }),\n /**\n * Popper render function or node.\n */\n children: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.node, PropTypes.func]),\n /**\n * An HTML element or function that returns one.\n * The `container` will have the portal children appended to it.\n *\n * You can also provide a callback, which is called in a React layout effect.\n * This lets you set the container from a ref, and also makes server-side rendering possible.\n *\n * By default, it uses the body of the top-level document object,\n * so it's simply `document.body` most of the time.\n */\n container: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.func]),\n /**\n * Direction of the text.\n * @default 'ltr'\n */\n direction: PropTypes.oneOf(['ltr', 'rtl']),\n /**\n * The `children` will be under the DOM hierarchy of the parent component.\n * @default false\n */\n disablePortal: PropTypes.bool,\n /**\n * Always keep the children in the DOM.\n * This prop can be useful in SEO situation or\n * when you want to maximize the responsiveness of the Popper.\n * @default false\n */\n keepMounted: PropTypes.bool,\n /**\n * Popper.js is based on a \"plugin-like\" architecture,\n * most of its features are fully encapsulated \"modifiers\".\n *\n * A modifier is a function that is called each time Popper.js needs to\n * compute the position of the popper.\n * For this reason, modifiers should be very performant to avoid bottlenecks.\n * To learn how to create a modifier, [read the modifiers documentation](https://popper.js.org/docs/v2/modifiers/).\n */\n modifiers: PropTypes.arrayOf(PropTypes.shape({\n data: PropTypes.object,\n effect: PropTypes.func,\n enabled: PropTypes.bool,\n fn: PropTypes.func,\n name: PropTypes.any,\n options: PropTypes.object,\n phase: PropTypes.oneOf(['afterMain', 'afterRead', 'afterWrite', 'beforeMain', 'beforeRead', 'beforeWrite', 'main', 'read', 'write']),\n requires: PropTypes.arrayOf(PropTypes.string),\n requiresIfExists: PropTypes.arrayOf(PropTypes.string)\n })),\n /**\n * If `true`, the component is shown.\n */\n open: PropTypes.bool.isRequired,\n /**\n * Popper placement.\n * @default 'bottom'\n */\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n /**\n * Options provided to the [`Popper.js`](https://popper.js.org/docs/v2/constructors/#options) instance.\n * @default {}\n */\n popperOptions: PropTypes.shape({\n modifiers: PropTypes.array,\n onFirstUpdate: PropTypes.func,\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n strategy: PropTypes.oneOf(['absolute', 'fixed'])\n }),\n /**\n * A ref that points to the used popper instance.\n */\n popperRef: refType,\n /**\n * The props used for each slot inside the Popper.\n * @default {}\n */\n slotProps: PropTypes.shape({\n root: PropTypes.oneOfType([PropTypes.func, PropTypes.object])\n }),\n /**\n * The components used for each slot inside the Popper.\n * Either a string to use a HTML element or a component.\n * @default {}\n */\n slots: PropTypes.shape({\n root: PropTypes.elementType\n }),\n /**\n * Help supporting a react-transition-group/Transition component.\n * @default false\n */\n transition: PropTypes.bool\n} : void 0;\nexport { Popper };","'use client';\n\nimport * as React from 'react';\nimport { useTheme as useThemeSystem } from '@mui/system';\nimport defaultTheme from './defaultTheme';\nimport THEME_ID from './identifier';\nexport default function useTheme() {\n const theme = useThemeSystem(defaultTheme);\n if (process.env.NODE_ENV !== 'production') {\n // eslint-disable-next-line react-hooks/rules-of-hooks\n React.useDebugValue(theme);\n }\n return theme[THEME_ID] || theme;\n}","export default function _setPrototypeOf(o, p) {\n _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function _setPrototypeOf(o, p) {\n o.__proto__ = p;\n return o;\n };\n return _setPrototypeOf(o, p);\n}","import setPrototypeOf from \"./setPrototypeOf.js\";\nexport default function _inheritsLoose(subClass, superClass) {\n subClass.prototype = Object.create(superClass.prototype);\n subClass.prototype.constructor = subClass;\n setPrototypeOf(subClass, superClass);\n}","export default {\n disabled: false\n};","import PropTypes from 'prop-types';\nexport var timeoutsShape = process.env.NODE_ENV !== 'production' ? PropTypes.oneOfType([PropTypes.number, PropTypes.shape({\n enter: PropTypes.number,\n exit: PropTypes.number,\n appear: PropTypes.number\n}).isRequired]) : null;\nexport var classNamesShape = process.env.NODE_ENV !== 'production' ? PropTypes.oneOfType([PropTypes.string, PropTypes.shape({\n enter: PropTypes.string,\n exit: PropTypes.string,\n active: PropTypes.string\n}), PropTypes.shape({\n enter: PropTypes.string,\n enterDone: PropTypes.string,\n enterActive: PropTypes.string,\n exit: PropTypes.string,\n exitDone: PropTypes.string,\n exitActive: PropTypes.string\n})]) : null;","import React from 'react';\nexport default React.createContext(null);","export var forceReflow = function forceReflow(node) {\n return node.scrollTop;\n};","import _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _inheritsLoose from \"@babel/runtime/helpers/esm/inheritsLoose\";\nimport PropTypes from 'prop-types';\nimport React from 'react';\nimport ReactDOM from 'react-dom';\nimport config from './config';\nimport { timeoutsShape } from './utils/PropTypes';\nimport TransitionGroupContext from './TransitionGroupContext';\nimport { forceReflow } from './utils/reflow';\nexport var UNMOUNTED = 'unmounted';\nexport var EXITED = 'exited';\nexport var ENTERING = 'entering';\nexport var ENTERED = 'entered';\nexport var EXITING = 'exiting';\n/**\n * The Transition component lets you describe a transition from one component\n * state to another _over time_ with a simple declarative API. Most commonly\n * it's used to animate the mounting and unmounting of a component, but can also\n * be used to describe in-place transition states as well.\n *\n * ---\n *\n * **Note**: `Transition` is a platform-agnostic base component. If you're using\n * transitions in CSS, you'll probably want to use\n * [`CSSTransition`](https://reactcommunity.org/react-transition-group/css-transition)\n * instead. It inherits all the features of `Transition`, but contains\n * additional features necessary to play nice with CSS transitions (hence the\n * name of the component).\n *\n * ---\n *\n * By default the `Transition` component does not alter the behavior of the\n * component it renders, it only tracks \"enter\" and \"exit\" states for the\n * components. It's up to you to give meaning and effect to those states. For\n * example we can add styles to a component when it enters or exits:\n *\n * ```jsx\n * import { Transition } from 'react-transition-group';\n *\n * const duration = 300;\n *\n * const defaultStyle = {\n * transition: `opacity ${duration}ms ease-in-out`,\n * opacity: 0,\n * }\n *\n * const transitionStyles = {\n * entering: { opacity: 1 },\n * entered: { opacity: 1 },\n * exiting: { opacity: 0 },\n * exited: { opacity: 0 },\n * };\n *\n * const Fade = ({ in: inProp }) => (\n * \n * {state => (\n *
    \n * I'm a fade Transition!\n *
    \n * )}\n *
    \n * );\n * ```\n *\n * There are 4 main states a Transition can be in:\n * - `'entering'`\n * - `'entered'`\n * - `'exiting'`\n * - `'exited'`\n *\n * Transition state is toggled via the `in` prop. When `true` the component\n * begins the \"Enter\" stage. During this stage, the component will shift from\n * its current transition state, to `'entering'` for the duration of the\n * transition and then to the `'entered'` stage once it's complete. Let's take\n * the following example (we'll use the\n * [useState](https://reactjs.org/docs/hooks-reference.html#usestate) hook):\n *\n * ```jsx\n * function App() {\n * const [inProp, setInProp] = useState(false);\n * return (\n *
    \n * \n * {state => (\n * // ...\n * )}\n * \n * \n *
    \n * );\n * }\n * ```\n *\n * When the button is clicked the component will shift to the `'entering'` state\n * and stay there for 500ms (the value of `timeout`) before it finally switches\n * to `'entered'`.\n *\n * When `in` is `false` the same thing happens except the state moves from\n * `'exiting'` to `'exited'`.\n */\n\nvar Transition = /*#__PURE__*/function (_React$Component) {\n _inheritsLoose(Transition, _React$Component);\n\n function Transition(props, context) {\n var _this;\n\n _this = _React$Component.call(this, props, context) || this;\n var parentGroup = context; // In the context of a TransitionGroup all enters are really appears\n\n var appear = parentGroup && !parentGroup.isMounting ? props.enter : props.appear;\n var initialStatus;\n _this.appearStatus = null;\n\n if (props.in) {\n if (appear) {\n initialStatus = EXITED;\n _this.appearStatus = ENTERING;\n } else {\n initialStatus = ENTERED;\n }\n } else {\n if (props.unmountOnExit || props.mountOnEnter) {\n initialStatus = UNMOUNTED;\n } else {\n initialStatus = EXITED;\n }\n }\n\n _this.state = {\n status: initialStatus\n };\n _this.nextCallback = null;\n return _this;\n }\n\n Transition.getDerivedStateFromProps = function getDerivedStateFromProps(_ref, prevState) {\n var nextIn = _ref.in;\n\n if (nextIn && prevState.status === UNMOUNTED) {\n return {\n status: EXITED\n };\n }\n\n return null;\n } // getSnapshotBeforeUpdate(prevProps) {\n // let nextStatus = null\n // if (prevProps !== this.props) {\n // const { status } = this.state\n // if (this.props.in) {\n // if (status !== ENTERING && status !== ENTERED) {\n // nextStatus = ENTERING\n // }\n // } else {\n // if (status === ENTERING || status === ENTERED) {\n // nextStatus = EXITING\n // }\n // }\n // }\n // return { nextStatus }\n // }\n ;\n\n var _proto = Transition.prototype;\n\n _proto.componentDidMount = function componentDidMount() {\n this.updateStatus(true, this.appearStatus);\n };\n\n _proto.componentDidUpdate = function componentDidUpdate(prevProps) {\n var nextStatus = null;\n\n if (prevProps !== this.props) {\n var status = this.state.status;\n\n if (this.props.in) {\n if (status !== ENTERING && status !== ENTERED) {\n nextStatus = ENTERING;\n }\n } else {\n if (status === ENTERING || status === ENTERED) {\n nextStatus = EXITING;\n }\n }\n }\n\n this.updateStatus(false, nextStatus);\n };\n\n _proto.componentWillUnmount = function componentWillUnmount() {\n this.cancelNextCallback();\n };\n\n _proto.getTimeouts = function getTimeouts() {\n var timeout = this.props.timeout;\n var exit, enter, appear;\n exit = enter = appear = timeout;\n\n if (timeout != null && typeof timeout !== 'number') {\n exit = timeout.exit;\n enter = timeout.enter; // TODO: remove fallback for next major\n\n appear = timeout.appear !== undefined ? timeout.appear : enter;\n }\n\n return {\n exit: exit,\n enter: enter,\n appear: appear\n };\n };\n\n _proto.updateStatus = function updateStatus(mounting, nextStatus) {\n if (mounting === void 0) {\n mounting = false;\n }\n\n if (nextStatus !== null) {\n // nextStatus will always be ENTERING or EXITING.\n this.cancelNextCallback();\n\n if (nextStatus === ENTERING) {\n if (this.props.unmountOnExit || this.props.mountOnEnter) {\n var node = this.props.nodeRef ? this.props.nodeRef.current : ReactDOM.findDOMNode(this); // https://github.com/reactjs/react-transition-group/pull/749\n // With unmountOnExit or mountOnEnter, the enter animation should happen at the transition between `exited` and `entering`.\n // To make the animation happen, we have to separate each rendering and avoid being processed as batched.\n\n if (node) forceReflow(node);\n }\n\n this.performEnter(mounting);\n } else {\n this.performExit();\n }\n } else if (this.props.unmountOnExit && this.state.status === EXITED) {\n this.setState({\n status: UNMOUNTED\n });\n }\n };\n\n _proto.performEnter = function performEnter(mounting) {\n var _this2 = this;\n\n var enter = this.props.enter;\n var appearing = this.context ? this.context.isMounting : mounting;\n\n var _ref2 = this.props.nodeRef ? [appearing] : [ReactDOM.findDOMNode(this), appearing],\n maybeNode = _ref2[0],\n maybeAppearing = _ref2[1];\n\n var timeouts = this.getTimeouts();\n var enterTimeout = appearing ? timeouts.appear : timeouts.enter; // no enter animation skip right to ENTERED\n // if we are mounting and running this it means appear _must_ be set\n\n if (!mounting && !enter || config.disabled) {\n this.safeSetState({\n status: ENTERED\n }, function () {\n _this2.props.onEntered(maybeNode);\n });\n return;\n }\n\n this.props.onEnter(maybeNode, maybeAppearing);\n this.safeSetState({\n status: ENTERING\n }, function () {\n _this2.props.onEntering(maybeNode, maybeAppearing);\n\n _this2.onTransitionEnd(enterTimeout, function () {\n _this2.safeSetState({\n status: ENTERED\n }, function () {\n _this2.props.onEntered(maybeNode, maybeAppearing);\n });\n });\n });\n };\n\n _proto.performExit = function performExit() {\n var _this3 = this;\n\n var exit = this.props.exit;\n var timeouts = this.getTimeouts();\n var maybeNode = this.props.nodeRef ? undefined : ReactDOM.findDOMNode(this); // no exit animation skip right to EXITED\n\n if (!exit || config.disabled) {\n this.safeSetState({\n status: EXITED\n }, function () {\n _this3.props.onExited(maybeNode);\n });\n return;\n }\n\n this.props.onExit(maybeNode);\n this.safeSetState({\n status: EXITING\n }, function () {\n _this3.props.onExiting(maybeNode);\n\n _this3.onTransitionEnd(timeouts.exit, function () {\n _this3.safeSetState({\n status: EXITED\n }, function () {\n _this3.props.onExited(maybeNode);\n });\n });\n });\n };\n\n _proto.cancelNextCallback = function cancelNextCallback() {\n if (this.nextCallback !== null) {\n this.nextCallback.cancel();\n this.nextCallback = null;\n }\n };\n\n _proto.safeSetState = function safeSetState(nextState, callback) {\n // This shouldn't be necessary, but there are weird race conditions with\n // setState callbacks and unmounting in testing, so always make sure that\n // we can cancel any pending setState callbacks after we unmount.\n callback = this.setNextCallback(callback);\n this.setState(nextState, callback);\n };\n\n _proto.setNextCallback = function setNextCallback(callback) {\n var _this4 = this;\n\n var active = true;\n\n this.nextCallback = function (event) {\n if (active) {\n active = false;\n _this4.nextCallback = null;\n callback(event);\n }\n };\n\n this.nextCallback.cancel = function () {\n active = false;\n };\n\n return this.nextCallback;\n };\n\n _proto.onTransitionEnd = function onTransitionEnd(timeout, handler) {\n this.setNextCallback(handler);\n var node = this.props.nodeRef ? this.props.nodeRef.current : ReactDOM.findDOMNode(this);\n var doesNotHaveTimeoutOrListener = timeout == null && !this.props.addEndListener;\n\n if (!node || doesNotHaveTimeoutOrListener) {\n setTimeout(this.nextCallback, 0);\n return;\n }\n\n if (this.props.addEndListener) {\n var _ref3 = this.props.nodeRef ? [this.nextCallback] : [node, this.nextCallback],\n maybeNode = _ref3[0],\n maybeNextCallback = _ref3[1];\n\n this.props.addEndListener(maybeNode, maybeNextCallback);\n }\n\n if (timeout != null) {\n setTimeout(this.nextCallback, timeout);\n }\n };\n\n _proto.render = function render() {\n var status = this.state.status;\n\n if (status === UNMOUNTED) {\n return null;\n }\n\n var _this$props = this.props,\n children = _this$props.children,\n _in = _this$props.in,\n _mountOnEnter = _this$props.mountOnEnter,\n _unmountOnExit = _this$props.unmountOnExit,\n _appear = _this$props.appear,\n _enter = _this$props.enter,\n _exit = _this$props.exit,\n _timeout = _this$props.timeout,\n _addEndListener = _this$props.addEndListener,\n _onEnter = _this$props.onEnter,\n _onEntering = _this$props.onEntering,\n _onEntered = _this$props.onEntered,\n _onExit = _this$props.onExit,\n _onExiting = _this$props.onExiting,\n _onExited = _this$props.onExited,\n _nodeRef = _this$props.nodeRef,\n childProps = _objectWithoutPropertiesLoose(_this$props, [\"children\", \"in\", \"mountOnEnter\", \"unmountOnExit\", \"appear\", \"enter\", \"exit\", \"timeout\", \"addEndListener\", \"onEnter\", \"onEntering\", \"onEntered\", \"onExit\", \"onExiting\", \"onExited\", \"nodeRef\"]);\n\n return (\n /*#__PURE__*/\n // allows for nested Transitions\n React.createElement(TransitionGroupContext.Provider, {\n value: null\n }, typeof children === 'function' ? children(status, childProps) : React.cloneElement(React.Children.only(children), childProps))\n );\n };\n\n return Transition;\n}(React.Component);\n\nTransition.contextType = TransitionGroupContext;\nTransition.propTypes = process.env.NODE_ENV !== \"production\" ? {\n /**\n * A React reference to DOM element that need to transition:\n * https://stackoverflow.com/a/51127130/4671932\n *\n * - When `nodeRef` prop is used, `node` is not passed to callback functions\n * (e.g. `onEnter`) because user already has direct access to the node.\n * - When changing `key` prop of `Transition` in a `TransitionGroup` a new\n * `nodeRef` need to be provided to `Transition` with changed `key` prop\n * (see\n * [test/CSSTransition-test.js](https://github.com/reactjs/react-transition-group/blob/13435f897b3ab71f6e19d724f145596f5910581c/test/CSSTransition-test.js#L362-L437)).\n */\n nodeRef: PropTypes.shape({\n current: typeof Element === 'undefined' ? PropTypes.any : function (propValue, key, componentName, location, propFullName, secret) {\n var value = propValue[key];\n return PropTypes.instanceOf(value && 'ownerDocument' in value ? value.ownerDocument.defaultView.Element : Element)(propValue, key, componentName, location, propFullName, secret);\n }\n }),\n\n /**\n * A `function` child can be used instead of a React element. This function is\n * called with the current transition status (`'entering'`, `'entered'`,\n * `'exiting'`, `'exited'`), which can be used to apply context\n * specific props to a component.\n *\n * ```jsx\n * \n * {state => (\n * \n * )}\n * \n * ```\n */\n children: PropTypes.oneOfType([PropTypes.func.isRequired, PropTypes.element.isRequired]).isRequired,\n\n /**\n * Show the component; triggers the enter or exit states\n */\n in: PropTypes.bool,\n\n /**\n * By default the child component is mounted immediately along with\n * the parent `Transition` component. If you want to \"lazy mount\" the component on the\n * first `in={true}` you can set `mountOnEnter`. After the first enter transition the component will stay\n * mounted, even on \"exited\", unless you also specify `unmountOnExit`.\n */\n mountOnEnter: PropTypes.bool,\n\n /**\n * By default the child component stays mounted after it reaches the `'exited'` state.\n * Set `unmountOnExit` if you'd prefer to unmount the component after it finishes exiting.\n */\n unmountOnExit: PropTypes.bool,\n\n /**\n * By default the child component does not perform the enter transition when\n * it first mounts, regardless of the value of `in`. If you want this\n * behavior, set both `appear` and `in` to `true`.\n *\n * > **Note**: there are no special appear states like `appearing`/`appeared`, this prop\n * > only adds an additional enter transition. However, in the\n * > `` component that first enter transition does result in\n * > additional `.appear-*` classes, that way you can choose to style it\n * > differently.\n */\n appear: PropTypes.bool,\n\n /**\n * Enable or disable enter transitions.\n */\n enter: PropTypes.bool,\n\n /**\n * Enable or disable exit transitions.\n */\n exit: PropTypes.bool,\n\n /**\n * The duration of the transition, in milliseconds.\n * Required unless `addEndListener` is provided.\n *\n * You may specify a single timeout for all transitions:\n *\n * ```jsx\n * timeout={500}\n * ```\n *\n * or individually:\n *\n * ```jsx\n * timeout={{\n * appear: 500,\n * enter: 300,\n * exit: 500,\n * }}\n * ```\n *\n * - `appear` defaults to the value of `enter`\n * - `enter` defaults to `0`\n * - `exit` defaults to `0`\n *\n * @type {number | { enter?: number, exit?: number, appear?: number }}\n */\n timeout: function timeout(props) {\n var pt = timeoutsShape;\n if (!props.addEndListener) pt = pt.isRequired;\n\n for (var _len = arguments.length, args = new Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) {\n args[_key - 1] = arguments[_key];\n }\n\n return pt.apply(void 0, [props].concat(args));\n },\n\n /**\n * Add a custom transition end trigger. Called with the transitioning\n * DOM node and a `done` callback. Allows for more fine grained transition end\n * logic. Timeouts are still used as a fallback if provided.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * ```jsx\n * addEndListener={(node, done) => {\n * // use the css transitionend event to mark the finish of a transition\n * node.addEventListener('transitionend', done, false);\n * }}\n * ```\n */\n addEndListener: PropTypes.func,\n\n /**\n * Callback fired before the \"entering\" status is applied. An extra parameter\n * `isAppearing` is supplied to indicate if the enter stage is occurring on the initial mount\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement, isAppearing: bool) -> void\n */\n onEnter: PropTypes.func,\n\n /**\n * Callback fired after the \"entering\" status is applied. An extra parameter\n * `isAppearing` is supplied to indicate if the enter stage is occurring on the initial mount\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement, isAppearing: bool)\n */\n onEntering: PropTypes.func,\n\n /**\n * Callback fired after the \"entered\" status is applied. An extra parameter\n * `isAppearing` is supplied to indicate if the enter stage is occurring on the initial mount\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement, isAppearing: bool) -> void\n */\n onEntered: PropTypes.func,\n\n /**\n * Callback fired before the \"exiting\" status is applied.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement) -> void\n */\n onExit: PropTypes.func,\n\n /**\n * Callback fired after the \"exiting\" status is applied.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement) -> void\n */\n onExiting: PropTypes.func,\n\n /**\n * Callback fired after the \"exited\" status is applied.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed\n *\n * @type Function(node: HtmlElement) -> void\n */\n onExited: PropTypes.func\n} : {}; // Name the function so it is clearer in the documentation\n\nfunction noop() {}\n\nTransition.defaultProps = {\n in: false,\n mountOnEnter: false,\n unmountOnExit: false,\n appear: false,\n enter: true,\n exit: true,\n onEnter: noop,\n onEntering: noop,\n onEntered: noop,\n onExit: noop,\n onExiting: noop,\n onExited: noop\n};\nTransition.UNMOUNTED = UNMOUNTED;\nTransition.EXITED = EXITED;\nTransition.ENTERING = ENTERING;\nTransition.ENTERED = ENTERED;\nTransition.EXITING = EXITING;\nexport default Transition;","export const reflow = node => node.scrollTop;\nexport function getTransitionProps(props, options) {\n var _style$transitionDura, _style$transitionTimi;\n const {\n timeout,\n easing,\n style = {}\n } = props;\n return {\n duration: (_style$transitionDura = style.transitionDuration) != null ? _style$transitionDura : typeof timeout === 'number' ? timeout : timeout[options.mode] || 0,\n easing: (_style$transitionTimi = style.transitionTimingFunction) != null ? _style$transitionTimi : typeof easing === 'object' ? easing[options.mode] : easing,\n delay: style.transitionDelay\n };\n}","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"addEndListener\", \"appear\", \"children\", \"easing\", \"in\", \"onEnter\", \"onEntered\", \"onEntering\", \"onExit\", \"onExited\", \"onExiting\", \"style\", \"timeout\", \"TransitionComponent\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport { elementAcceptingRef, unstable_useTimeout as useTimeout } from '@mui/utils';\nimport { Transition } from 'react-transition-group';\nimport useTheme from '../styles/useTheme';\nimport { getTransitionProps, reflow } from '../transitions/utils';\nimport useForkRef from '../utils/useForkRef';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nfunction getScale(value) {\n return `scale(${value}, ${value ** 2})`;\n}\nconst styles = {\n entering: {\n opacity: 1,\n transform: getScale(1)\n },\n entered: {\n opacity: 1,\n transform: 'none'\n }\n};\n\n/*\n TODO v6: remove\n Conditionally apply a workaround for the CSS transition bug in Safari 15.4 / WebKit browsers.\n */\nconst isWebKit154 = typeof navigator !== 'undefined' && /^((?!chrome|android).)*(safari|mobile)/i.test(navigator.userAgent) && /(os |version\\/)15(.|_)4/i.test(navigator.userAgent);\n\n/**\n * The Grow transition is used by the [Tooltip](/material-ui/react-tooltip/) and\n * [Popover](/material-ui/react-popover/) components.\n * It uses [react-transition-group](https://github.com/reactjs/react-transition-group) internally.\n */\nconst Grow = /*#__PURE__*/React.forwardRef(function Grow(props, ref) {\n const {\n addEndListener,\n appear = true,\n children,\n easing,\n in: inProp,\n onEnter,\n onEntered,\n onEntering,\n onExit,\n onExited,\n onExiting,\n style,\n timeout = 'auto',\n // eslint-disable-next-line react/prop-types\n TransitionComponent = Transition\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const timer = useTimeout();\n const autoTimeout = React.useRef();\n const theme = useTheme();\n const nodeRef = React.useRef(null);\n const handleRef = useForkRef(nodeRef, children.ref, ref);\n const normalizedTransitionCallback = callback => maybeIsAppearing => {\n if (callback) {\n const node = nodeRef.current;\n\n // onEnterXxx and onExitXxx callbacks have a different arguments.length value.\n if (maybeIsAppearing === undefined) {\n callback(node);\n } else {\n callback(node, maybeIsAppearing);\n }\n }\n };\n const handleEntering = normalizedTransitionCallback(onEntering);\n const handleEnter = normalizedTransitionCallback((node, isAppearing) => {\n reflow(node); // So the animation always start from the start.\n\n const {\n duration: transitionDuration,\n delay,\n easing: transitionTimingFunction\n } = getTransitionProps({\n style,\n timeout,\n easing\n }, {\n mode: 'enter'\n });\n let duration;\n if (timeout === 'auto') {\n duration = theme.transitions.getAutoHeightDuration(node.clientHeight);\n autoTimeout.current = duration;\n } else {\n duration = transitionDuration;\n }\n node.style.transition = [theme.transitions.create('opacity', {\n duration,\n delay\n }), theme.transitions.create('transform', {\n duration: isWebKit154 ? duration : duration * 0.666,\n delay,\n easing: transitionTimingFunction\n })].join(',');\n if (onEnter) {\n onEnter(node, isAppearing);\n }\n });\n const handleEntered = normalizedTransitionCallback(onEntered);\n const handleExiting = normalizedTransitionCallback(onExiting);\n const handleExit = normalizedTransitionCallback(node => {\n const {\n duration: transitionDuration,\n delay,\n easing: transitionTimingFunction\n } = getTransitionProps({\n style,\n timeout,\n easing\n }, {\n mode: 'exit'\n });\n let duration;\n if (timeout === 'auto') {\n duration = theme.transitions.getAutoHeightDuration(node.clientHeight);\n autoTimeout.current = duration;\n } else {\n duration = transitionDuration;\n }\n node.style.transition = [theme.transitions.create('opacity', {\n duration,\n delay\n }), theme.transitions.create('transform', {\n duration: isWebKit154 ? duration : duration * 0.666,\n delay: isWebKit154 ? delay : delay || duration * 0.333,\n easing: transitionTimingFunction\n })].join(',');\n node.style.opacity = 0;\n node.style.transform = getScale(0.75);\n if (onExit) {\n onExit(node);\n }\n });\n const handleExited = normalizedTransitionCallback(onExited);\n const handleAddEndListener = next => {\n if (timeout === 'auto') {\n timer.start(autoTimeout.current || 0, next);\n }\n if (addEndListener) {\n // Old call signature before `react-transition-group` implemented `nodeRef`\n addEndListener(nodeRef.current, next);\n }\n };\n return /*#__PURE__*/_jsx(TransitionComponent, _extends({\n appear: appear,\n in: inProp,\n nodeRef: nodeRef,\n onEnter: handleEnter,\n onEntered: handleEntered,\n onEntering: handleEntering,\n onExit: handleExit,\n onExited: handleExited,\n onExiting: handleExiting,\n addEndListener: handleAddEndListener,\n timeout: timeout === 'auto' ? null : timeout\n }, other, {\n children: (state, childProps) => {\n return /*#__PURE__*/React.cloneElement(children, _extends({\n style: _extends({\n opacity: 0,\n transform: getScale(0.75),\n visibility: state === 'exited' && !inProp ? 'hidden' : undefined\n }, styles[state], style, children.props.style),\n ref: handleRef\n }, childProps));\n }\n }));\n});\nprocess.env.NODE_ENV !== \"production\" ? Grow.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the d.ts file and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * Add a custom transition end trigger. Called with the transitioning DOM\n * node and a done callback. Allows for more fine grained transition end\n * logic. Note: Timeouts are still used as a fallback if provided.\n */\n addEndListener: PropTypes.func,\n /**\n * Perform the enter transition when it first mounts if `in` is also `true`.\n * Set this to `false` to disable this behavior.\n * @default true\n */\n appear: PropTypes.bool,\n /**\n * A single child content element.\n */\n children: elementAcceptingRef.isRequired,\n /**\n * The transition timing function.\n * You may specify a single easing or a object containing enter and exit values.\n */\n easing: PropTypes.oneOfType([PropTypes.shape({\n enter: PropTypes.string,\n exit: PropTypes.string\n }), PropTypes.string]),\n /**\n * If `true`, the component will transition in.\n */\n in: PropTypes.bool,\n /**\n * @ignore\n */\n onEnter: PropTypes.func,\n /**\n * @ignore\n */\n onEntered: PropTypes.func,\n /**\n * @ignore\n */\n onEntering: PropTypes.func,\n /**\n * @ignore\n */\n onExit: PropTypes.func,\n /**\n * @ignore\n */\n onExited: PropTypes.func,\n /**\n * @ignore\n */\n onExiting: PropTypes.func,\n /**\n * @ignore\n */\n style: PropTypes.object,\n /**\n * The duration for the transition, in milliseconds.\n * You may specify a single timeout for all transitions, or individually with an object.\n *\n * Set to 'auto' to automatically calculate transition time based on height.\n * @default 'auto'\n */\n timeout: PropTypes.oneOfType([PropTypes.oneOf(['auto']), PropTypes.number, PropTypes.shape({\n appear: PropTypes.number,\n enter: PropTypes.number,\n exit: PropTypes.number\n })])\n} : void 0;\nGrow.muiSupportAuto = true;\nexport default Grow;","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"anchorEl\", \"component\", \"components\", \"componentsProps\", \"container\", \"disablePortal\", \"keepMounted\", \"modifiers\", \"open\", \"placement\", \"popperOptions\", \"popperRef\", \"transition\", \"slots\", \"slotProps\"];\nimport { Popper as BasePopper } from '@mui/base/Popper';\nimport { useThemeWithoutDefault as useTheme } from '@mui/system';\nimport { HTMLElementType, refType } from '@mui/utils';\nimport PropTypes from 'prop-types';\nimport * as React from 'react';\nimport { styled, useThemeProps } from '../styles';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nconst PopperRoot = styled(BasePopper, {\n name: 'MuiPopper',\n slot: 'Root',\n overridesResolver: (props, styles) => styles.root\n})({});\n\n/**\n *\n * Demos:\n *\n * - [Autocomplete](https://mui.com/material-ui/react-autocomplete/)\n * - [Menu](https://mui.com/material-ui/react-menu/)\n * - [Popper](https://mui.com/material-ui/react-popper/)\n *\n * API:\n *\n * - [Popper API](https://mui.com/material-ui/api/popper/)\n */\nconst Popper = /*#__PURE__*/React.forwardRef(function Popper(inProps, ref) {\n var _slots$root;\n const theme = useTheme();\n const props = useThemeProps({\n props: inProps,\n name: 'MuiPopper'\n });\n const {\n anchorEl,\n component,\n components,\n componentsProps,\n container,\n disablePortal,\n keepMounted,\n modifiers,\n open,\n placement,\n popperOptions,\n popperRef,\n transition,\n slots,\n slotProps\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const RootComponent = (_slots$root = slots == null ? void 0 : slots.root) != null ? _slots$root : components == null ? void 0 : components.Root;\n const otherProps = _extends({\n anchorEl,\n container,\n disablePortal,\n keepMounted,\n modifiers,\n open,\n placement,\n popperOptions,\n popperRef,\n transition\n }, other);\n return /*#__PURE__*/_jsx(PopperRoot, _extends({\n as: component,\n direction: theme == null ? void 0 : theme.direction,\n slots: {\n root: RootComponent\n },\n slotProps: slotProps != null ? slotProps : componentsProps\n }, otherProps, {\n ref: ref\n }));\n});\nprocess.env.NODE_ENV !== \"production\" ? Popper.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * An HTML element, [virtualElement](https://popper.js.org/docs/v2/virtual-elements/),\n * or a function that returns either.\n * It's used to set the position of the popper.\n * The return value will passed as the reference object of the Popper instance.\n */\n anchorEl: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.object, PropTypes.func]),\n /**\n * Popper render function or node.\n */\n children: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.node, PropTypes.func]),\n /**\n * The component used for the root node.\n * Either a string to use a HTML element or a component.\n */\n component: PropTypes.elementType,\n /**\n * The components used for each slot inside the Popper.\n * Either a string to use a HTML element or a component.\n * @default {}\n */\n components: PropTypes.shape({\n Root: PropTypes.elementType\n }),\n /**\n * The props used for each slot inside the Popper.\n * @default {}\n */\n componentsProps: PropTypes.shape({\n root: PropTypes.oneOfType([PropTypes.func, PropTypes.object])\n }),\n /**\n * An HTML element or function that returns one.\n * The `container` will have the portal children appended to it.\n *\n * You can also provide a callback, which is called in a React layout effect.\n * This lets you set the container from a ref, and also makes server-side rendering possible.\n *\n * By default, it uses the body of the top-level document object,\n * so it's simply `document.body` most of the time.\n */\n container: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.func]),\n /**\n * The `children` will be under the DOM hierarchy of the parent component.\n * @default false\n */\n disablePortal: PropTypes.bool,\n /**\n * Always keep the children in the DOM.\n * This prop can be useful in SEO situation or\n * when you want to maximize the responsiveness of the Popper.\n * @default false\n */\n keepMounted: PropTypes.bool,\n /**\n * Popper.js is based on a \"plugin-like\" architecture,\n * most of its features are fully encapsulated \"modifiers\".\n *\n * A modifier is a function that is called each time Popper.js needs to\n * compute the position of the popper.\n * For this reason, modifiers should be very performant to avoid bottlenecks.\n * To learn how to create a modifier, [read the modifiers documentation](https://popper.js.org/docs/v2/modifiers/).\n */\n modifiers: PropTypes.arrayOf(PropTypes.shape({\n data: PropTypes.object,\n effect: PropTypes.func,\n enabled: PropTypes.bool,\n fn: PropTypes.func,\n name: PropTypes.any,\n options: PropTypes.object,\n phase: PropTypes.oneOf(['afterMain', 'afterRead', 'afterWrite', 'beforeMain', 'beforeRead', 'beforeWrite', 'main', 'read', 'write']),\n requires: PropTypes.arrayOf(PropTypes.string),\n requiresIfExists: PropTypes.arrayOf(PropTypes.string)\n })),\n /**\n * If `true`, the component is shown.\n */\n open: PropTypes.bool.isRequired,\n /**\n * Popper placement.\n * @default 'bottom'\n */\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n /**\n * Options provided to the [`Popper.js`](https://popper.js.org/docs/v2/constructors/#options) instance.\n * @default {}\n */\n popperOptions: PropTypes.shape({\n modifiers: PropTypes.array,\n onFirstUpdate: PropTypes.func,\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n strategy: PropTypes.oneOf(['absolute', 'fixed'])\n }),\n /**\n * A ref that points to the used popper instance.\n */\n popperRef: refType,\n /**\n * The props used for each slot inside the Popper.\n * @default {}\n */\n slotProps: PropTypes.shape({\n root: PropTypes.oneOfType([PropTypes.func, PropTypes.object])\n }),\n /**\n * The components used for each slot inside the Popper.\n * Either a string to use a HTML element or a component.\n * @default {}\n */\n slots: PropTypes.shape({\n root: PropTypes.elementType\n }),\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Help supporting a react-transition-group/Transition component.\n * @default false\n */\n transition: PropTypes.bool\n} : void 0;\nexport default Popper;","import generateUtilityClasses from '@mui/utils/generateUtilityClasses';\nimport generateUtilityClass from '@mui/utils/generateUtilityClass';\nexport function getTooltipUtilityClass(slot) {\n return generateUtilityClass('MuiTooltip', slot);\n}\nconst tooltipClasses = generateUtilityClasses('MuiTooltip', ['popper', 'popperInteractive', 'popperArrow', 'popperClose', 'tooltip', 'tooltipArrow', 'touch', 'tooltipPlacementLeft', 'tooltipPlacementRight', 'tooltipPlacementTop', 'tooltipPlacementBottom', 'arrow']);\nexport default tooltipClasses;","'use client';\n\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nconst _excluded = [\"arrow\", \"children\", \"classes\", \"components\", \"componentsProps\", \"describeChild\", \"disableFocusListener\", \"disableHoverListener\", \"disableInteractive\", \"disableTouchListener\", \"enterDelay\", \"enterNextDelay\", \"enterTouchDelay\", \"followCursor\", \"id\", \"leaveDelay\", \"leaveTouchDelay\", \"onClose\", \"onOpen\", \"open\", \"placement\", \"PopperComponent\", \"PopperProps\", \"slotProps\", \"slots\", \"title\", \"TransitionComponent\", \"TransitionProps\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport clsx from 'clsx';\nimport { elementAcceptingRef, unstable_useTimeout as useTimeout, unstable_Timeout as Timeout } from '@mui/utils';\nimport { unstable_composeClasses as composeClasses, appendOwnerState } from '@mui/base';\nimport { alpha } from '@mui/system';\nimport styled from '../styles/styled';\nimport useTheme from '../styles/useTheme';\nimport useThemeProps from '../styles/useThemeProps';\nimport capitalize from '../utils/capitalize';\nimport Grow from '../Grow';\nimport Popper from '../Popper';\nimport useEventCallback from '../utils/useEventCallback';\nimport useForkRef from '../utils/useForkRef';\nimport useId from '../utils/useId';\nimport useIsFocusVisible from '../utils/useIsFocusVisible';\nimport useControlled from '../utils/useControlled';\nimport tooltipClasses, { getTooltipUtilityClass } from './tooltipClasses';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nimport { jsxs as _jsxs } from \"react/jsx-runtime\";\nfunction round(value) {\n return Math.round(value * 1e5) / 1e5;\n}\nconst useUtilityClasses = ownerState => {\n const {\n classes,\n disableInteractive,\n arrow,\n touch,\n placement\n } = ownerState;\n const slots = {\n popper: ['popper', !disableInteractive && 'popperInteractive', arrow && 'popperArrow'],\n tooltip: ['tooltip', arrow && 'tooltipArrow', touch && 'touch', `tooltipPlacement${capitalize(placement.split('-')[0])}`],\n arrow: ['arrow']\n };\n return composeClasses(slots, getTooltipUtilityClass, classes);\n};\nconst TooltipPopper = styled(Popper, {\n name: 'MuiTooltip',\n slot: 'Popper',\n overridesResolver: (props, styles) => {\n const {\n ownerState\n } = props;\n return [styles.popper, !ownerState.disableInteractive && styles.popperInteractive, ownerState.arrow && styles.popperArrow, !ownerState.open && styles.popperClose];\n }\n})(({\n theme,\n ownerState,\n open\n}) => _extends({\n zIndex: (theme.vars || theme).zIndex.tooltip,\n pointerEvents: 'none'\n}, !ownerState.disableInteractive && {\n pointerEvents: 'auto'\n}, !open && {\n pointerEvents: 'none'\n}, ownerState.arrow && {\n [`&[data-popper-placement*=\"bottom\"] .${tooltipClasses.arrow}`]: {\n top: 0,\n marginTop: '-0.71em',\n '&::before': {\n transformOrigin: '0 100%'\n }\n },\n [`&[data-popper-placement*=\"top\"] .${tooltipClasses.arrow}`]: {\n bottom: 0,\n marginBottom: '-0.71em',\n '&::before': {\n transformOrigin: '100% 0'\n }\n },\n [`&[data-popper-placement*=\"right\"] .${tooltipClasses.arrow}`]: _extends({}, !ownerState.isRtl ? {\n left: 0,\n marginLeft: '-0.71em'\n } : {\n right: 0,\n marginRight: '-0.71em'\n }, {\n height: '1em',\n width: '0.71em',\n '&::before': {\n transformOrigin: '100% 100%'\n }\n }),\n [`&[data-popper-placement*=\"left\"] .${tooltipClasses.arrow}`]: _extends({}, !ownerState.isRtl ? {\n right: 0,\n marginRight: '-0.71em'\n } : {\n left: 0,\n marginLeft: '-0.71em'\n }, {\n height: '1em',\n width: '0.71em',\n '&::before': {\n transformOrigin: '0 0'\n }\n })\n}));\nconst TooltipTooltip = styled('div', {\n name: 'MuiTooltip',\n slot: 'Tooltip',\n overridesResolver: (props, styles) => {\n const {\n ownerState\n } = props;\n return [styles.tooltip, ownerState.touch && styles.touch, ownerState.arrow && styles.tooltipArrow, styles[`tooltipPlacement${capitalize(ownerState.placement.split('-')[0])}`]];\n }\n})(({\n theme,\n ownerState\n}) => _extends({\n backgroundColor: theme.vars ? theme.vars.palette.Tooltip.bg : alpha(theme.palette.grey[700], 0.92),\n borderRadius: (theme.vars || theme).shape.borderRadius,\n color: (theme.vars || theme).palette.common.white,\n fontFamily: theme.typography.fontFamily,\n padding: '4px 8px',\n fontSize: theme.typography.pxToRem(11),\n maxWidth: 300,\n margin: 2,\n wordWrap: 'break-word',\n fontWeight: theme.typography.fontWeightMedium\n}, ownerState.arrow && {\n position: 'relative',\n margin: 0\n}, ownerState.touch && {\n padding: '8px 16px',\n fontSize: theme.typography.pxToRem(14),\n lineHeight: `${round(16 / 14)}em`,\n fontWeight: theme.typography.fontWeightRegular\n}, {\n [`.${tooltipClasses.popper}[data-popper-placement*=\"left\"] &`]: _extends({\n transformOrigin: 'right center'\n }, !ownerState.isRtl ? _extends({\n marginRight: '14px'\n }, ownerState.touch && {\n marginRight: '24px'\n }) : _extends({\n marginLeft: '14px'\n }, ownerState.touch && {\n marginLeft: '24px'\n })),\n [`.${tooltipClasses.popper}[data-popper-placement*=\"right\"] &`]: _extends({\n transformOrigin: 'left center'\n }, !ownerState.isRtl ? _extends({\n marginLeft: '14px'\n }, ownerState.touch && {\n marginLeft: '24px'\n }) : _extends({\n marginRight: '14px'\n }, ownerState.touch && {\n marginRight: '24px'\n })),\n [`.${tooltipClasses.popper}[data-popper-placement*=\"top\"] &`]: _extends({\n transformOrigin: 'center bottom',\n marginBottom: '14px'\n }, ownerState.touch && {\n marginBottom: '24px'\n }),\n [`.${tooltipClasses.popper}[data-popper-placement*=\"bottom\"] &`]: _extends({\n transformOrigin: 'center top',\n marginTop: '14px'\n }, ownerState.touch && {\n marginTop: '24px'\n })\n}));\nconst TooltipArrow = styled('span', {\n name: 'MuiTooltip',\n slot: 'Arrow',\n overridesResolver: (props, styles) => styles.arrow\n})(({\n theme\n}) => ({\n overflow: 'hidden',\n position: 'absolute',\n width: '1em',\n height: '0.71em' /* = width / sqrt(2) = (length of the hypotenuse) */,\n boxSizing: 'border-box',\n color: theme.vars ? theme.vars.palette.Tooltip.bg : alpha(theme.palette.grey[700], 0.9),\n '&::before': {\n content: '\"\"',\n margin: 'auto',\n display: 'block',\n width: '100%',\n height: '100%',\n backgroundColor: 'currentColor',\n transform: 'rotate(45deg)'\n }\n}));\nlet hystersisOpen = false;\nconst hystersisTimer = new Timeout();\nlet cursorPosition = {\n x: 0,\n y: 0\n};\nexport function testReset() {\n hystersisOpen = false;\n hystersisTimer.clear();\n}\nfunction composeEventHandler(handler, eventHandler) {\n return event => {\n if (eventHandler) {\n eventHandler(event);\n }\n handler(event);\n };\n}\n\n// TODO v6: Remove PopperComponent, PopperProps, TransitionComponent and TransitionProps.\nconst Tooltip = /*#__PURE__*/React.forwardRef(function Tooltip(inProps, ref) {\n var _ref, _slots$popper, _ref2, _ref3, _slots$transition, _ref4, _slots$tooltip, _ref5, _slots$arrow, _slotProps$popper, _ref6, _slotProps$popper2, _slotProps$transition, _slotProps$tooltip, _ref7, _slotProps$tooltip2, _slotProps$arrow, _ref8, _slotProps$arrow2;\n const props = useThemeProps({\n props: inProps,\n name: 'MuiTooltip'\n });\n const {\n arrow = false,\n children: childrenProp,\n components = {},\n componentsProps = {},\n describeChild = false,\n disableFocusListener = false,\n disableHoverListener = false,\n disableInteractive: disableInteractiveProp = false,\n disableTouchListener = false,\n enterDelay = 100,\n enterNextDelay = 0,\n enterTouchDelay = 700,\n followCursor = false,\n id: idProp,\n leaveDelay = 0,\n leaveTouchDelay = 1500,\n onClose,\n onOpen,\n open: openProp,\n placement = 'bottom',\n PopperComponent: PopperComponentProp,\n PopperProps = {},\n slotProps = {},\n slots = {},\n title,\n TransitionComponent: TransitionComponentProp = Grow,\n TransitionProps\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n\n // to prevent runtime errors, developers will need to provide a child as a React element anyway.\n const children = /*#__PURE__*/React.isValidElement(childrenProp) ? childrenProp : /*#__PURE__*/_jsx(\"span\", {\n children: childrenProp\n });\n const theme = useTheme();\n const isRtl = theme.direction === 'rtl';\n const [childNode, setChildNode] = React.useState();\n const [arrowRef, setArrowRef] = React.useState(null);\n const ignoreNonTouchEvents = React.useRef(false);\n const disableInteractive = disableInteractiveProp || followCursor;\n const closeTimer = useTimeout();\n const enterTimer = useTimeout();\n const leaveTimer = useTimeout();\n const touchTimer = useTimeout();\n const [openState, setOpenState] = useControlled({\n controlled: openProp,\n default: false,\n name: 'Tooltip',\n state: 'open'\n });\n let open = openState;\n if (process.env.NODE_ENV !== 'production') {\n // eslint-disable-next-line react-hooks/rules-of-hooks\n const {\n current: isControlled\n } = React.useRef(openProp !== undefined);\n\n // eslint-disable-next-line react-hooks/rules-of-hooks\n React.useEffect(() => {\n if (childNode && childNode.disabled && !isControlled && title !== '' && childNode.tagName.toLowerCase() === 'button') {\n console.error(['MUI: You are providing a disabled `button` child to the Tooltip component.', 'A disabled element does not fire events.', \"Tooltip needs to listen to the child element's events to display the title.\", '', 'Add a simple wrapper element, such as a `span`.'].join('\\n'));\n }\n }, [title, childNode, isControlled]);\n }\n const id = useId(idProp);\n const prevUserSelect = React.useRef();\n const stopTouchInteraction = useEventCallback(() => {\n if (prevUserSelect.current !== undefined) {\n document.body.style.WebkitUserSelect = prevUserSelect.current;\n prevUserSelect.current = undefined;\n }\n touchTimer.clear();\n });\n React.useEffect(() => stopTouchInteraction, [stopTouchInteraction]);\n const handleOpen = event => {\n hystersisTimer.clear();\n hystersisOpen = true;\n\n // The mouseover event will trigger for every nested element in the tooltip.\n // We can skip rerendering when the tooltip is already open.\n // We are using the mouseover event instead of the mouseenter event to fix a hide/show issue.\n setOpenState(true);\n if (onOpen && !open) {\n onOpen(event);\n }\n };\n const handleClose = useEventCallback(\n /**\n * @param {React.SyntheticEvent | Event} event\n */\n event => {\n hystersisTimer.start(800 + leaveDelay, () => {\n hystersisOpen = false;\n });\n setOpenState(false);\n if (onClose && open) {\n onClose(event);\n }\n closeTimer.start(theme.transitions.duration.shortest, () => {\n ignoreNonTouchEvents.current = false;\n });\n });\n const handleEnter = event => {\n if (ignoreNonTouchEvents.current && event.type !== 'touchstart') {\n return;\n }\n\n // Remove the title ahead of time.\n // We don't want to wait for the next render commit.\n // We would risk displaying two tooltips at the same time (native + this one).\n if (childNode) {\n childNode.removeAttribute('title');\n }\n enterTimer.clear();\n leaveTimer.clear();\n if (enterDelay || hystersisOpen && enterNextDelay) {\n enterTimer.start(hystersisOpen ? enterNextDelay : enterDelay, () => {\n handleOpen(event);\n });\n } else {\n handleOpen(event);\n }\n };\n const handleLeave = event => {\n enterTimer.clear();\n leaveTimer.start(leaveDelay, () => {\n handleClose(event);\n });\n };\n const {\n isFocusVisibleRef,\n onBlur: handleBlurVisible,\n onFocus: handleFocusVisible,\n ref: focusVisibleRef\n } = useIsFocusVisible();\n // We don't necessarily care about the focusVisible state (which is safe to access via ref anyway).\n // We just need to re-render the Tooltip if the focus-visible state changes.\n const [, setChildIsFocusVisible] = React.useState(false);\n const handleBlur = event => {\n handleBlurVisible(event);\n if (isFocusVisibleRef.current === false) {\n setChildIsFocusVisible(false);\n handleLeave(event);\n }\n };\n const handleFocus = event => {\n // Workaround for https://github.com/facebook/react/issues/7769\n // The autoFocus of React might trigger the event before the componentDidMount.\n // We need to account for this eventuality.\n if (!childNode) {\n setChildNode(event.currentTarget);\n }\n handleFocusVisible(event);\n if (isFocusVisibleRef.current === true) {\n setChildIsFocusVisible(true);\n handleEnter(event);\n }\n };\n const detectTouchStart = event => {\n ignoreNonTouchEvents.current = true;\n const childrenProps = children.props;\n if (childrenProps.onTouchStart) {\n childrenProps.onTouchStart(event);\n }\n };\n const handleMouseOver = handleEnter;\n const handleMouseLeave = handleLeave;\n const handleTouchStart = event => {\n detectTouchStart(event);\n leaveTimer.clear();\n closeTimer.clear();\n stopTouchInteraction();\n prevUserSelect.current = document.body.style.WebkitUserSelect;\n // Prevent iOS text selection on long-tap.\n document.body.style.WebkitUserSelect = 'none';\n touchTimer.start(enterTouchDelay, () => {\n document.body.style.WebkitUserSelect = prevUserSelect.current;\n handleEnter(event);\n });\n };\n const handleTouchEnd = event => {\n if (children.props.onTouchEnd) {\n children.props.onTouchEnd(event);\n }\n stopTouchInteraction();\n leaveTimer.start(leaveTouchDelay, () => {\n handleClose(event);\n });\n };\n React.useEffect(() => {\n if (!open) {\n return undefined;\n }\n\n /**\n * @param {KeyboardEvent} nativeEvent\n */\n function handleKeyDown(nativeEvent) {\n // IE11, Edge (prior to using Bink?) use 'Esc'\n if (nativeEvent.key === 'Escape' || nativeEvent.key === 'Esc') {\n handleClose(nativeEvent);\n }\n }\n document.addEventListener('keydown', handleKeyDown);\n return () => {\n document.removeEventListener('keydown', handleKeyDown);\n };\n }, [handleClose, open]);\n const handleRef = useForkRef(children.ref, focusVisibleRef, setChildNode, ref);\n\n // There is no point in displaying an empty tooltip.\n // So we exclude all falsy values, except 0, which is valid.\n if (!title && title !== 0) {\n open = false;\n }\n const popperRef = React.useRef();\n const handleMouseMove = event => {\n const childrenProps = children.props;\n if (childrenProps.onMouseMove) {\n childrenProps.onMouseMove(event);\n }\n cursorPosition = {\n x: event.clientX,\n y: event.clientY\n };\n if (popperRef.current) {\n popperRef.current.update();\n }\n };\n const nameOrDescProps = {};\n const titleIsString = typeof title === 'string';\n if (describeChild) {\n nameOrDescProps.title = !open && titleIsString && !disableHoverListener ? title : null;\n nameOrDescProps['aria-describedby'] = open ? id : null;\n } else {\n nameOrDescProps['aria-label'] = titleIsString ? title : null;\n nameOrDescProps['aria-labelledby'] = open && !titleIsString ? id : null;\n }\n const childrenProps = _extends({}, nameOrDescProps, other, children.props, {\n className: clsx(other.className, children.props.className),\n onTouchStart: detectTouchStart,\n ref: handleRef\n }, followCursor ? {\n onMouseMove: handleMouseMove\n } : {});\n if (process.env.NODE_ENV !== 'production') {\n childrenProps['data-mui-internal-clone-element'] = true;\n\n // eslint-disable-next-line react-hooks/rules-of-hooks\n React.useEffect(() => {\n if (childNode && !childNode.getAttribute('data-mui-internal-clone-element')) {\n console.error(['MUI: The `children` component of the Tooltip is not forwarding its props correctly.', 'Please make sure that props are spread on the same element that the ref is applied to.'].join('\\n'));\n }\n }, [childNode]);\n }\n const interactiveWrapperListeners = {};\n if (!disableTouchListener) {\n childrenProps.onTouchStart = handleTouchStart;\n childrenProps.onTouchEnd = handleTouchEnd;\n }\n if (!disableHoverListener) {\n childrenProps.onMouseOver = composeEventHandler(handleMouseOver, childrenProps.onMouseOver);\n childrenProps.onMouseLeave = composeEventHandler(handleMouseLeave, childrenProps.onMouseLeave);\n if (!disableInteractive) {\n interactiveWrapperListeners.onMouseOver = handleMouseOver;\n interactiveWrapperListeners.onMouseLeave = handleMouseLeave;\n }\n }\n if (!disableFocusListener) {\n childrenProps.onFocus = composeEventHandler(handleFocus, childrenProps.onFocus);\n childrenProps.onBlur = composeEventHandler(handleBlur, childrenProps.onBlur);\n if (!disableInteractive) {\n interactiveWrapperListeners.onFocus = handleFocus;\n interactiveWrapperListeners.onBlur = handleBlur;\n }\n }\n if (process.env.NODE_ENV !== 'production') {\n if (children.props.title) {\n console.error(['MUI: You have provided a `title` prop to the child of .', `Remove this title prop \\`${children.props.title}\\` or the Tooltip component.`].join('\\n'));\n }\n }\n const popperOptions = React.useMemo(() => {\n var _PopperProps$popperOp;\n let tooltipModifiers = [{\n name: 'arrow',\n enabled: Boolean(arrowRef),\n options: {\n element: arrowRef,\n padding: 4\n }\n }];\n if ((_PopperProps$popperOp = PopperProps.popperOptions) != null && _PopperProps$popperOp.modifiers) {\n tooltipModifiers = tooltipModifiers.concat(PopperProps.popperOptions.modifiers);\n }\n return _extends({}, PopperProps.popperOptions, {\n modifiers: tooltipModifiers\n });\n }, [arrowRef, PopperProps]);\n const ownerState = _extends({}, props, {\n isRtl,\n arrow,\n disableInteractive,\n placement,\n PopperComponentProp,\n touch: ignoreNonTouchEvents.current\n });\n const classes = useUtilityClasses(ownerState);\n const PopperComponent = (_ref = (_slots$popper = slots.popper) != null ? _slots$popper : components.Popper) != null ? _ref : TooltipPopper;\n const TransitionComponent = (_ref2 = (_ref3 = (_slots$transition = slots.transition) != null ? _slots$transition : components.Transition) != null ? _ref3 : TransitionComponentProp) != null ? _ref2 : Grow;\n const TooltipComponent = (_ref4 = (_slots$tooltip = slots.tooltip) != null ? _slots$tooltip : components.Tooltip) != null ? _ref4 : TooltipTooltip;\n const ArrowComponent = (_ref5 = (_slots$arrow = slots.arrow) != null ? _slots$arrow : components.Arrow) != null ? _ref5 : TooltipArrow;\n const popperProps = appendOwnerState(PopperComponent, _extends({}, PopperProps, (_slotProps$popper = slotProps.popper) != null ? _slotProps$popper : componentsProps.popper, {\n className: clsx(classes.popper, PopperProps == null ? void 0 : PopperProps.className, (_ref6 = (_slotProps$popper2 = slotProps.popper) != null ? _slotProps$popper2 : componentsProps.popper) == null ? void 0 : _ref6.className)\n }), ownerState);\n const transitionProps = appendOwnerState(TransitionComponent, _extends({}, TransitionProps, (_slotProps$transition = slotProps.transition) != null ? _slotProps$transition : componentsProps.transition), ownerState);\n const tooltipProps = appendOwnerState(TooltipComponent, _extends({}, (_slotProps$tooltip = slotProps.tooltip) != null ? _slotProps$tooltip : componentsProps.tooltip, {\n className: clsx(classes.tooltip, (_ref7 = (_slotProps$tooltip2 = slotProps.tooltip) != null ? _slotProps$tooltip2 : componentsProps.tooltip) == null ? void 0 : _ref7.className)\n }), ownerState);\n const tooltipArrowProps = appendOwnerState(ArrowComponent, _extends({}, (_slotProps$arrow = slotProps.arrow) != null ? _slotProps$arrow : componentsProps.arrow, {\n className: clsx(classes.arrow, (_ref8 = (_slotProps$arrow2 = slotProps.arrow) != null ? _slotProps$arrow2 : componentsProps.arrow) == null ? void 0 : _ref8.className)\n }), ownerState);\n return /*#__PURE__*/_jsxs(React.Fragment, {\n children: [/*#__PURE__*/React.cloneElement(children, childrenProps), /*#__PURE__*/_jsx(PopperComponent, _extends({\n as: PopperComponentProp != null ? PopperComponentProp : Popper,\n placement: placement,\n anchorEl: followCursor ? {\n getBoundingClientRect: () => ({\n top: cursorPosition.y,\n left: cursorPosition.x,\n right: cursorPosition.x,\n bottom: cursorPosition.y,\n width: 0,\n height: 0\n })\n } : childNode,\n popperRef: popperRef,\n open: childNode ? open : false,\n id: id,\n transition: true\n }, interactiveWrapperListeners, popperProps, {\n popperOptions: popperOptions,\n children: ({\n TransitionProps: TransitionPropsInner\n }) => /*#__PURE__*/_jsx(TransitionComponent, _extends({\n timeout: theme.transitions.duration.shorter\n }, TransitionPropsInner, transitionProps, {\n children: /*#__PURE__*/_jsxs(TooltipComponent, _extends({}, tooltipProps, {\n children: [title, arrow ? /*#__PURE__*/_jsx(ArrowComponent, _extends({}, tooltipArrowProps, {\n ref: setArrowRef\n })) : null]\n }))\n }))\n }))]\n });\n});\nprocess.env.NODE_ENV !== \"production\" ? Tooltip.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the d.ts file and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * If `true`, adds an arrow to the tooltip.\n * @default false\n */\n arrow: PropTypes.bool,\n /**\n * Tooltip reference element.\n */\n children: elementAcceptingRef.isRequired,\n /**\n * Override or extend the styles applied to the component.\n */\n classes: PropTypes.object,\n /**\n * @ignore\n */\n className: PropTypes.string,\n /**\n * The components used for each slot inside.\n *\n * This prop is an alias for the `slots` prop.\n * It's recommended to use the `slots` prop instead.\n *\n * @default {}\n */\n components: PropTypes.shape({\n Arrow: PropTypes.elementType,\n Popper: PropTypes.elementType,\n Tooltip: PropTypes.elementType,\n Transition: PropTypes.elementType\n }),\n /**\n * The extra props for the slot components.\n * You can override the existing props or add new ones.\n *\n * This prop is an alias for the `slotProps` prop.\n * It's recommended to use the `slotProps` prop instead, as `componentsProps` will be deprecated in the future.\n *\n * @default {}\n */\n componentsProps: PropTypes.shape({\n arrow: PropTypes.object,\n popper: PropTypes.object,\n tooltip: PropTypes.object,\n transition: PropTypes.object\n }),\n /**\n * Set to `true` if the `title` acts as an accessible description.\n * By default the `title` acts as an accessible label for the child.\n * @default false\n */\n describeChild: PropTypes.bool,\n /**\n * Do not respond to focus-visible events.\n * @default false\n */\n disableFocusListener: PropTypes.bool,\n /**\n * Do not respond to hover events.\n * @default false\n */\n disableHoverListener: PropTypes.bool,\n /**\n * Makes a tooltip not interactive, i.e. it will close when the user\n * hovers over the tooltip before the `leaveDelay` is expired.\n * @default false\n */\n disableInteractive: PropTypes.bool,\n /**\n * Do not respond to long press touch events.\n * @default false\n */\n disableTouchListener: PropTypes.bool,\n /**\n * The number of milliseconds to wait before showing the tooltip.\n * This prop won't impact the enter touch delay (`enterTouchDelay`).\n * @default 100\n */\n enterDelay: PropTypes.number,\n /**\n * The number of milliseconds to wait before showing the tooltip when one was already recently opened.\n * @default 0\n */\n enterNextDelay: PropTypes.number,\n /**\n * The number of milliseconds a user must touch the element before showing the tooltip.\n * @default 700\n */\n enterTouchDelay: PropTypes.number,\n /**\n * If `true`, the tooltip follow the cursor over the wrapped element.\n * @default false\n */\n followCursor: PropTypes.bool,\n /**\n * This prop is used to help implement the accessibility logic.\n * If you don't provide this prop. It falls back to a randomly generated id.\n */\n id: PropTypes.string,\n /**\n * The number of milliseconds to wait before hiding the tooltip.\n * This prop won't impact the leave touch delay (`leaveTouchDelay`).\n * @default 0\n */\n leaveDelay: PropTypes.number,\n /**\n * The number of milliseconds after the user stops touching an element before hiding the tooltip.\n * @default 1500\n */\n leaveTouchDelay: PropTypes.number,\n /**\n * Callback fired when the component requests to be closed.\n *\n * @param {React.SyntheticEvent} event The event source of the callback.\n */\n onClose: PropTypes.func,\n /**\n * Callback fired when the component requests to be open.\n *\n * @param {React.SyntheticEvent} event The event source of the callback.\n */\n onOpen: PropTypes.func,\n /**\n * If `true`, the component is shown.\n */\n open: PropTypes.bool,\n /**\n * Tooltip placement.\n * @default 'bottom'\n */\n placement: PropTypes.oneOf(['bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n /**\n * The component used for the popper.\n * @default Popper\n */\n PopperComponent: PropTypes.elementType,\n /**\n * Props applied to the [`Popper`](/material-ui/api/popper/) element.\n * @default {}\n */\n PopperProps: PropTypes.object,\n /**\n * The extra props for the slot components.\n * You can override the existing props or add new ones.\n *\n * This prop is an alias for the `componentsProps` prop, which will be deprecated in the future.\n *\n * @default {}\n */\n slotProps: PropTypes.shape({\n arrow: PropTypes.object,\n popper: PropTypes.object,\n tooltip: PropTypes.object,\n transition: PropTypes.object\n }),\n /**\n * The components used for each slot inside.\n *\n * This prop is an alias for the `components` prop, which will be deprecated in the future.\n *\n * @default {}\n */\n slots: PropTypes.shape({\n arrow: PropTypes.elementType,\n popper: PropTypes.elementType,\n tooltip: PropTypes.elementType,\n transition: PropTypes.elementType\n }),\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Tooltip title. Zero-length titles string, undefined, null and false are never displayed.\n */\n title: PropTypes.node,\n /**\n * The component used for the transition.\n * [Follow this guide](/material-ui/transitions/#transitioncomponent-prop) to learn more about the requirements for this component.\n * @default Grow\n */\n TransitionComponent: PropTypes.elementType,\n /**\n * Props applied to the transition element.\n * By default, the element is based on this [`Transition`](http://reactcommunity.org/react-transition-group/transition/) component.\n */\n TransitionProps: PropTypes.object\n} : void 0;\nexport default Tooltip;","import '@/components/mui/menu-item.component.css';\nimport ArrowRightIcon from '@mui/icons-material/ArrowRight';\nimport {\n ListItemIcon as MuiListItemIcon,\n ListItemText as MuiListItemText,\n MenuItem as MuiMenuItem,\n} from '@mui/material';\nimport Tooltip from '@mui/material/Tooltip';\nimport { Localized, ReferencedItem, SingleColumnMenu } from 'platform-bible-utils';\nimport { MouseEvent, PropsWithChildren } from 'react';\n\ntype MenuItemInfoBase = {\n /** Text (displayable in the UI) as the name of the menu item */\n label: string;\n /** Text to display when the mouse hovers over the menu item */\n tooltip?: string;\n};\n\nexport type Command = MenuItemInfoBase & {\n /** Command to execute (string.string) */\n command: string;\n};\n\ntype SubMenu = MenuItemInfoBase & {\n /** Command to execute (string.string) */\n items: MenuItemInfo[];\n};\n\nexport interface CommandHandler {\n (command: Command): void;\n}\n\nexport type MenuPropsBase = {\n /*\n * The JSON defining the menu whose items are to be rendered. This will typically be one of the\n * menus in the \"defs\" in a Platform.Bible menu (see PlatformMenus). The schema for this is\n * menuDocumentSchema (at the end of menus.model.ts). Note that while this is a\n * \"SingleColumnMenu\", somewhat bizarrely, a MultiColumnMenu is a SingleColumnMenu, so it really\n * could be a MultiColumnMenu, in which case, column had better be defined so it can be used\n * to filter out the actual groups and items to display on the column.\n */\n menuDefinition: Localized;\n\n commandHandler: CommandHandler;\n\n /**\n * Additional action to perform when any menu item is clicked. Allows the caller to handle event\n * (e.g., to close the menu).\n */\n onClick?: (event: MouseEvent) => void;\n};\n\nexport type MenuItemListProps = MenuPropsBase & {\n /** Optional unique (column) identifier */\n columnId?: ReferencedItem;\n};\n\nexport type MenuItemProps = Omit &\n PropsWithChildren<{\n /** Optional unique identifier */\n id?: string;\n\n onClick: (event: MouseEvent) => void;\n }>;\n\ntype MenuItemInfo = (Command | SubMenu) & {\n /**\n * If specified, menu item will be inset if it does not have a leading icon.\n *\n * @default true\n */\n allowForLeadingIcons?: boolean;\n /**\n * If specified, the path to the icon image to display on the leading side of the menu text.\n *\n * @default undefined (no leading icon will be shown)\n */\n iconPathBefore?: string;\n /**\n * If specified, the path to the icon image to display on the trailing side of the menu text.\n *\n * @default undefined (no trailing icon will be shown)\n */\n iconPathAfter?: string;\n /**\n * If true, list item is focused during the first mount\n *\n * @default false\n */\n hasAutoFocus?: boolean;\n\n /** Additional css classes to help with unique styling of the menu item */\n className?: string;\n\n /**\n * If true, the menu item will appear disabled and it will not respond to clicks or mouse hovers.\n *\n * @default false\n */\n isDisabled?: boolean;\n\n /**\n * If true, compact vertical padding designed for keyboard and mouse input is used.\n *\n * @default true\n */\n isDense?: boolean;\n\n /**\n * If true, a right-arrow icon will be displayed (iconPathAfter, if specified, will be ignored).\n *\n * @default false\n */\n isSubMenuParent?: boolean;\n\n /**\n * If true, the left and right padding is removed\n *\n * @default false\n */\n hasDisabledGutters?: boolean;\n\n /**\n * If true, a 1px light border is added to bottom of menu item\n *\n * @default false\n */\n hasDivider?: boolean;\n\n /** Help identify which element has keyboard focus */\n focusVisibleClassName?: string;\n\n /** If it's a submenu, it should have the items property */\n items?: MenuItemInfo[];\n};\n\nfunction getIcon(icon: string | undefined, menuLabel: string, leading: boolean) {\n return icon ? (\n \n {`${leading\n \n ) : undefined;\n}\n\nexport default function MenuItem(props: MenuItemProps) {\n const {\n onClick,\n label,\n tooltip,\n allowForLeadingIcons = true,\n iconPathBefore = undefined,\n iconPathAfter = undefined,\n hasAutoFocus = false,\n className,\n isDisabled = false,\n isDense = true,\n isSubMenuParent = false,\n hasDisabledGutters = false,\n hasDivider = false,\n focusVisibleClassName,\n id,\n children,\n } = props;\n\n const menuItem = (\n \n {label ? (\n <>\n {getIcon(iconPathBefore, label, true)}\n \n {isSubMenuParent ? (\n \n \n \n ) : (\n getIcon(iconPathAfter, label, false)\n )}\n \n ) : (\n children\n )}\n \n );\n\n return tooltip ? (\n \n
    {menuItem}
    \n
    \n ) : (\n menuItem\n );\n}\n","import MenuItem, {\n MenuItemListProps,\n MenuItemProps,\n MenuPropsBase,\n} from '@/components/mui/menu-item.component';\nimport { Menu } from '@mui/material';\nimport {\n Localized,\n MenuGroupDetailsInSubMenu,\n MenuItemContainingCommand,\n MenuItemContainingSubmenu,\n OrderedExtensibleContainer,\n ReferencedItem,\n SingleColumnMenu,\n} from 'platform-bible-utils';\nimport { MouseEvent, useMemo, useState } from 'react';\n\n/**\n * All the exported types in this file should be regarded as \"internal\" (i.e., they should not be\n * exposed via index.ts).\n */\n\nexport type GroupedMenuPropsBase = MenuPropsBase & {\n /** Optional unique (column) identifier */\n columnId?: ReferencedItem;\n};\n\nexport type GroupedMenuItemListProps = MenuItemListProps & {\n /**\n * If the menuDefinition includes \"top-level\" groups (i.e., those that belong to a column as\n * opposed to those that belong to a submenu) that should not be included in the list, then this\n * array specifies which groups to include. Likewise, for a submenu, this list indicates which\n * groups are pertinent for that submenu. So then for a context menu this property need not be\n * specified since it is a top-level menu based on a \"true\" SingleColumnMenu (i.e., one that is\n * not a MultiColumnMenu).\n */\n includedGroups?: {\n id: string;\n group: Localized;\n }[];\n};\n\ninterface ItemInfo {\n item: Localized;\n isLastItemInGroup: boolean;\n}\n\ntype SubMenuProps = MenuPropsBase & {\n parentMenuItem: Localized;\n parentItemProps: Omit, 'iconPathAfter'>;\n};\n\nfunction getAllGroups(menuDefinition: Localized) {\n const groupEntries = Object.entries(menuDefinition.groups);\n // Convert array of entries to array of objects with id and group properties\n return groupEntries.map(([key, value]) => ({ id: key, group: value }));\n}\n\nfunction SubMenu(props: SubMenuProps) {\n const [anchorEl, setAnchorEl] = useState(undefined);\n\n const { parentMenuItem, parentItemProps, menuDefinition } = props;\n\n const handleParentMenuItemClick = (event: MouseEvent) => {\n setAnchorEl(event.currentTarget);\n };\n\n const handleClose = () => {\n setAnchorEl(undefined);\n };\n\n const renderSubMenuItems = () => {\n let includedGroups = getAllGroups(menuDefinition).filter((g) => 'menuItem' in g.group);\n\n // Ensure valid parent menu was provided. (If not, submenu will contain all groups!)\n if (!parentMenuItem?.id) throw new Error('A valid parent menu item is required for submenus.');\n\n // When laying out a submenu, only include groups associated with the provided parent menu.\n // Note: without the (annoying) redundant check that the included groups\n // have the menuItem field, TS doesn't think it exists.\n includedGroups = includedGroups.filter(\n (group) => 'menuItem' in group.group && group.group.menuItem === parentMenuItem.id,\n );\n\n return ;\n };\n\n return (\n <>\n \n \n {renderSubMenuItems()}\n \n \n );\n}\n\nconst getOrderedGroupItems = (\n groupId: string,\n allItems: Localized[],\n) => {\n // Filter items that belong to the specified group\n const itemsForGroup = allItems.filter((item) => item.group === groupId);\n // Sort items based on order\n const sortedItems = itemsForGroup.sort((a, b) => (a.order || 0) - (b.order || 0));\n return sortedItems;\n};\n\n/**\n * This component is internal; it does not need to be exposed to the outside world since it is not\n * useful on its own. It is used to generate and lay out the MenuItems that appear either on a\n * top-level menu (in a GridMenu or ContextMenu) or in a submenu.\n */\nexport default function GroupedMenuItemList(menuProps: GroupedMenuItemListProps) {\n const { menuDefinition, onClick, commandHandler, includedGroups } = menuProps;\n\n const { items, allowForLeadingIcons } = useMemo(() => {\n const groupsToInclude =\n includedGroups && includedGroups.length > 0\n ? includedGroups\n : // We're apparently laying out a single-column menu (presumably a context menu). In this\n // case, all groups should be included except ones that belong to a submenu.\n getAllGroups(menuDefinition).filter((g) => !('menuItem' in g.group));\n\n const sortedGroups = Object.values(groupsToInclude).sort(\n (a, b) => (a.group.order || 0) - (b.group.order || 0),\n );\n\n const itemArray: ItemInfo[] = [];\n\n sortedGroups.forEach((group) => {\n getOrderedGroupItems(group.id, menuDefinition.items).forEach((item) =>\n itemArray.push({ item, isLastItemInGroup: false }),\n );\n if (itemArray.length > 0) itemArray[itemArray.length - 1].isLastItemInGroup = true;\n });\n\n // No divider after last item in final group.\n if (itemArray.length > 0) itemArray[itemArray.length - 1].isLastItemInGroup = false;\n\n const allowSpaceForLeadingIcons = itemArray.some(\n (i) => 'iconPathBefore' in i.item && i.item.iconPathBefore,\n );\n\n return { items: itemArray, allowForLeadingIcons: allowSpaceForLeadingIcons };\n }, [includedGroups, menuDefinition]);\n\n // Create props for MenuItem component including setting hasDivider for the last item in a group\n const createMenuItemProps = ({ item, isLastItemInGroup }: ItemInfo) => {\n const menuItemProps = {\n className: 'papi-menu-item',\n label: item.label,\n tooltip: item.tooltip,\n iconPathBefore: 'iconPathBefore' in item ? item.iconPathBefore : undefined,\n iconPathAfter: 'iconPathAfter' in item ? item.iconPathAfter : undefined,\n hasDivider: isLastItemInGroup, // Set hasDivider to true for the last item in a group\n allowForLeadingIcons,\n };\n\n return menuItemProps;\n };\n\n const [firstItem] = items;\n\n if (!firstItem) return
    ;\n\n const divKey = firstItem.item.group;\n\n return (\n
    \n {items.map((itemInfo, index) => {\n const { item } = itemInfo;\n const menuItemProps = createMenuItemProps(itemInfo);\n if ('command' in item) {\n const key = item.group + index;\n return (\n ) => {\n onClick?.(event);\n commandHandler(item);\n }}\n {...menuItemProps}\n />\n );\n }\n return (\n \n );\n })}\n
    \n );\n}\n","import GroupedMenuItemList from '@/components/mui/grouped-menu-item-list.component';\nimport { MenuItemListProps } from '@/components/mui/menu-item.component';\nimport { MultiColumnMenu } from 'platform-bible-utils';\n\n/**\n * This component is internal; it does not need to be exposed to the outside world since it is not\n * useful on its own. Use either GridMenu or ContextMenu.\n */\nexport default function TopLevelMenu(props: MenuItemListProps) {\n const { menuDefinition, columnId } = props;\n\n const groupEntries = Object.entries(menuDefinition.groups);\n // Convert array of entries to array of objects with id and group properties\n const groups = groupEntries.map(([key, value]) => ({ id: key, group: value }));\n let includedGroups = groups.filter((g) => 'column' in g.group);\n\n // Check if column is provided and menuDefinition is a MultiColumnMenu\n if (\n columnId &&\n 'columns' in menuDefinition &&\n // Without this type assertion, TS doesn't know what columns is.\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n (menuDefinition as MultiColumnMenu).columns[columnId]\n ) {\n // When laying out a single column in a MultiColumnMenu, only include groups associated with\n // the provided column. Note: without the (annoying) redundant check that the included groups\n // have the colum field, TS doesn't think it exists.\n includedGroups = includedGroups.filter(\n (g) => 'column' in g.group && g.group.column === columnId,\n );\n }\n\n return ;\n}\n","import '@/components/mui/grid-menu.component.css';\nimport { GroupedMenuPropsBase } from '@/components/mui/grouped-menu-item-list.component';\nimport { CommandHandler } from '@/components/mui/menu-item.component';\nimport TopLevelMenu from '@/components/mui/top-level-menu.component';\nimport { Grid, List } from '@mui/material';\nimport {\n Localized,\n MenuColumnWithHeader,\n MultiColumnMenu,\n ReferencedItem,\n} from 'platform-bible-utils';\nimport { useMemo } from 'react';\n\ntype ColumnInfo = {\n /*\n * The ID (`${string}.${string}`) of a specific menu column.\n */\n id: ReferencedItem;\n\n /*\n * Metadata (label, order, etc.) for a specific menu column.\n */\n metadata: Localized;\n};\n\ntype MenuColumnProps = ColumnInfo &\n GroupedMenuPropsBase & {\n /** Additional css classes to help with unique styling of the menu column */\n className?: string;\n };\n\nexport type GridMenuInfo = {\n /** The menu object containing information about the columns, groups, and items to display. */\n multiColumnMenu: Localized;\n};\n\nexport type GridMenuProps = GridMenuInfo & {\n /** Optional unique identifier */\n id?: string;\n\n commandHandler: CommandHandler;\n\n /** Additional css classes to help with unique styling of the grid menu */\n className?: string;\n};\n\nfunction MenuColumn({\n commandHandler,\n menuDefinition,\n id,\n metadata,\n onClick,\n className,\n}: MenuColumnProps) {\n return (\n \n

    \n {metadata.label}\n

    \n {/* It would seem as though this List component were unnecessary, since it only contains one\n thing, but the \"dense\" property does affect the layout of the items (in a way I don't fully\n understand). There might be a better way. */}\n \n \n \n \n );\n}\n\nexport default function GridMenu({\n commandHandler,\n className,\n multiColumnMenu,\n id,\n}: GridMenuProps) {\n const { columns } = multiColumnMenu;\n\n const sortedColumns = useMemo(() => {\n const columnNumbers = new Map();\n Object.getOwnPropertyNames(columns).forEach((columnName: string) => {\n // We know for sure there is a (boolean) property 'isExtensible' that we are not interested in.\n if (columnName === 'isExtensible') return;\n // TS doesn't allow `columnName` above to be a ReferencedItem even though the type says it is\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const columnId = columnName as ReferencedItem;\n const column = columns[columnId];\n // As of right now (and hopefully forever after), all remaining properties of the\n // ColumnsWithHeaders object are columns whose property names are the IDs of the columns.\n // This is an additional (redundant) sanity check. Specifically we're interested in\n // MenuColumnWithHeader objects, which TypeScript now \"knows\" we have, but at runtime all we\n // can check for is that it's an object with a valid numeric order field. That's likely good\n // enough.\n if (\n typeof column === 'object' &&\n typeof column.order === 'number' &&\n !Number.isNaN(column.order)\n )\n columnNumbers.set(column.order, { id: columnId, metadata: column });\n else\n console.warn(\n `Property ${columnName} (${typeof column}) on menu ${id} is not a valid column and is being ignored. This might indicate data corruption`,\n );\n });\n\n // Extract values and sort them based on the 'order' property\n return Array.from(columnNumbers.values()).sort((a, b) => {\n return (a.metadata.order || 0) - (b.metadata.order || 0);\n });\n }, [columns, id]);\n\n // We might need something like this if we need to be able to prevent empty columns\n // sortedColumns.filter((c) => multiColumnMenu.groups.some((g) => 'column' in g && (g as .column)...\n\n return (\n \n {sortedColumns.map((col, index) => (\n \n ))}\n \n );\n}\n","import { useEffect, useRef, useState } from 'react';\n\nexport type UsePromiseOptions = {\n /**\n * Whether to leave the value as the most recent resolved promise value or set it back to\n * defaultValue while running the promise again. Defaults to true\n */\n preserveValue?: boolean;\n};\n\n/** Set up defaults for options for usePromise hook */\nfunction getUsePromiseOptionsDefaults(options: UsePromiseOptions): UsePromiseOptions {\n return {\n preserveValue: true,\n ...options,\n };\n}\n\n/**\n * Awaits a promise and returns a loading value while the promise is unresolved\n *\n * @param promiseFactoryCallback A function that returns the promise to await. If this callback is\n * undefined, the current value will be returned (defaultValue unless it was previously changed\n * and `options.preserveValue` is true), and there will be no loading.\n *\n * WARNING: MUST BE STABLE - const or wrapped in useCallback. The reference must not be updated\n * every render\n * @param defaultValue The initial value to return while first awaiting the promise. If\n * `options.preserveValue` is false, this value is also shown while awaiting the promise on\n * subsequent calls.\n *\n * Note: this parameter is internally assigned to a `ref`, so changing it will not cause any hooks\n * to re-run with its new value. This means that, if the `promiseFactoryCallback` changes and\n * `options.preserveValue` is `false`, the returned value will be set to the current\n * `defaultValue`. However, the returned value will not be updated if`defaultValue` changes.\n * @param options Various options for adjusting how this hook runs the `promiseFactoryCallback`\n *\n * Note: this parameter is internally assigned to a `ref`, so changing it will not cause any hooks\n * to re-run with its new value. However, the latest `options.preserveValue` will always be used\n * appropriately to determine whether to preserve the returned value when changing the\n * `promiseFactoryCallback`\n * @returns `[value, isLoading]`\n *\n * - `value`: the current value for the promise, either the defaultValue or the resolved promise value\n * - `isLoading`: whether the promise is waiting to be resolved\n */\nconst usePromise = (\n promiseFactoryCallback: (() => Promise) | undefined,\n defaultValue: T,\n options: UsePromiseOptions = {},\n): [value: T, isLoading: boolean] => {\n // Use defaultValue as a ref so it doesn't update dependency arrays\n const defaultValueRef = useRef(defaultValue);\n defaultValueRef.current = defaultValue;\n // Use options as a ref so it doesn't update dependency arrays\n const optionsDefaultedRef = useRef(options);\n optionsDefaultedRef.current = getUsePromiseOptionsDefaults(optionsDefaultedRef.current);\n\n const [value, setValue] = useState(() => defaultValueRef.current);\n const [isLoading, setIsLoading] = useState(true);\n useEffect(() => {\n let promiseIsCurrent = true;\n // If a promiseFactoryCallback was provided, we are loading. Otherwise, there is no loading to do\n setIsLoading(!!promiseFactoryCallback);\n (async () => {\n // If there is a callback to run, run it\n if (promiseFactoryCallback) {\n const result = await promiseFactoryCallback();\n // If the promise was not already replaced, update the value\n if (promiseIsCurrent) {\n setValue(() => result);\n setIsLoading(false);\n }\n }\n })();\n\n return () => {\n // Mark this promise as old and not to be used\n promiseIsCurrent = false;\n if (!optionsDefaultedRef.current.preserveValue) setValue(() => defaultValueRef.current);\n };\n }, [promiseFactoryCallback]);\n\n return [value, isLoading];\n};\nexport default usePromise;\n","\"use client\";\n\nimport createSvgIcon from './utils/createSvgIcon';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nexport default createSvgIcon( /*#__PURE__*/_jsx(\"path\", {\n d: \"M3 18h18v-2H3zm0-5h18v-2H3zm0-7v2h18V6z\"\n}), 'Menu');","import GridMenu from '@/components/mui/grid-menu.component';\nimport { Command, CommandHandler } from '@/components/mui/menu-item.component';\nimport usePromise from '@/hooks/use-promise.hook';\nimport { Menu as MenuIcon } from '@mui/icons-material';\nimport { Drawer, IconButton } from '@mui/material';\nimport { Localized, MultiColumnMenu } from 'platform-bible-utils';\nimport {\n MouseEvent,\n MutableRefObject,\n PropsWithChildren,\n useCallback,\n useEffect,\n useState,\n} from 'react';\n\nexport interface MultiColumnMenuProvider {\n (isSupportAndDevelopment: boolean): Promise>;\n}\n\nexport type HamburgerMenuButtonProps = PropsWithChildren & {\n /** The handler to use for menu commands (and eventually toolbar commands). */\n commandHandler: CommandHandler;\n\n /**\n * Optional reference to the \"div\" container that determines the where the menu should appear. If\n * not defined, then (1,1) used.\n */\n containerRef?: MutableRefObject;\n\n /**\n * The delegate to use to get the menu data. If not specified or if it returns undefined, the data\n * in normalMenu or fullMenu property will be used.\n */\n menuProvider?: MultiColumnMenuProvider;\n\n /**\n * The menu data to show when the menu is opened if the menuProvider property is not defined.\n * (This allows for a default or test-only static menu to be used.)\n */\n normalMenu?: Localized;\n\n /**\n * The menu data to show for \"full\" menu (when opened with the SHIFT key pressed) if the\n * menuProvider property is not defined. (This allows for a default or test-only static menu to be\n * used.)\n */\n fullMenu?: Localized;\n\n /** Additional css class(es) to help with unique styling of the sub-components */\n className?: string;\n\n /** Value to use as prefix for ARIA labels on interactive sub-components */\n ariaLabelPrefix?: string;\n};\n\nexport default function HamburgerMenuButton({\n menuProvider,\n normalMenu,\n fullMenu,\n commandHandler,\n containerRef,\n className,\n ariaLabelPrefix,\n children,\n}: HamburgerMenuButtonProps) {\n const [isMenuOpen, setMenuOpen] = useState(false);\n const [showFullMenu, setShowFullMenu] = useState(false);\n\n const handleMenuItemClick = useCallback(() => {\n if (isMenuOpen) setMenuOpen(false);\n setShowFullMenu(false);\n }, [isMenuOpen]);\n\n const handleMenuButtonClick = useCallback((e: MouseEvent) => {\n e.stopPropagation();\n setMenuOpen((prevIsOpen) => {\n const isOpening = !prevIsOpen;\n if (isOpening && e.shiftKey) setShowFullMenu(true);\n else if (!isOpening) setShowFullMenu(false);\n return isOpening;\n });\n }, []);\n\n const menuCommandHandler = useCallback(\n (command: Command) => {\n handleMenuItemClick();\n return commandHandler(command);\n },\n [commandHandler, handleMenuItemClick],\n );\n\n const [offset, setOffset] = useState({ top: 1, left: 1 });\n\n useEffect(() => {\n if (isMenuOpen) {\n const node = containerRef?.current;\n if (node) {\n const rect = node.getBoundingClientRect();\n const scrollTop = window.scrollY;\n const scrollLeft = window.scrollX;\n const top = rect.top + scrollTop + node.clientHeight;\n const left = rect.left + scrollLeft;\n setOffset({ top, left });\n }\n }\n }, [isMenuOpen, containerRef]);\n\n const [normalMenuData] = usePromise(\n useCallback(async () => {\n return menuProvider?.(false) ?? normalMenu;\n // isMenuOpen needs to be included for the menu contents to reevaluate when reopened\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [menuProvider, normalMenu, isMenuOpen]),\n normalMenu,\n );\n\n const [fullMenuData] = usePromise(\n useCallback(async () => {\n return menuProvider?.(true) ?? fullMenu ?? normalMenuData;\n // isMenuOpen needs to be included for the menu contents to reevaluate when reopened\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [menuProvider, fullMenu, normalMenuData, isMenuOpen]),\n fullMenu ?? normalMenuData,\n );\n\n const menu = showFullMenu && fullMenuData ? fullMenuData : normalMenuData;\n\n return (\n <>\n \n {children ?? }\n \n \n {menu ? (\n \n ) : undefined}\n \n \n );\n}\n","import '@/components/mui/icon-button.component.css';\nimport { IconButton as MuiIconButton } from '@mui/material';\nimport { MouseEventHandler, PropsWithChildren } from 'react';\n\nexport type IconButtonProps = PropsWithChildren<{\n /** Optional unique identifier */\n id?: string;\n /**\n * Required. Used as both the tooltip (aka, title) and the aria-label (used for accessibility,\n * testing, etc.), unless a distinct tooltip is supplied.\n */\n label: string;\n /**\n * Enabled status of button\n *\n * @default false\n */\n isDisabled?: boolean;\n /** Optional tooltip to display if different from the aria-label. */\n tooltip?: string;\n /** If true, no tooltip will be displayed. */\n isTooltipSuppressed?: boolean;\n /**\n * If given, uses a negative margin to counteract the padding on one side (this is often helpful\n * for aligning the left or right side of the icon with content above or below, without ruining\n * the border size and shape).\n *\n * @default false\n */\n adjustMarginToAlignToEdge?: 'end' | 'start' | false;\n /**\n * The size of the component. small is equivalent to the dense button styling.\n *\n * @default false\n */\n size: 'small' | 'medium' | 'large';\n /** Additional css classes to help with unique styling of the button */\n className?: string;\n /** Optional click handler */\n onClick?: MouseEventHandler;\n}>;\n\n/**\n * Iconic button a user can click to do something\n *\n * Thanks to MUI for heavy inspiration and documentation\n * https://mui.com/material-ui/getting-started/overview/\n */\nfunction IconButton({\n id,\n label,\n isDisabled = false,\n tooltip,\n isTooltipSuppressed = false,\n adjustMarginToAlignToEdge = false,\n size = 'medium',\n className,\n onClick,\n children,\n}: IconButtonProps) {\n return (\n \n {children /* the icon to display */}\n \n );\n}\n\nexport default IconButton;\n","import { cn } from '@/utils/shadcn-ui.util';\nimport { LoaderCircle, LucideProps } from 'lucide-react';\nimport { forwardRef } from 'react';\n\nexport type SpinnerProps = LucideProps;\n\nconst Spinner = forwardRef(({ className, ...props }, ref) => {\n return (\n \n );\n});\n\nSpinner.displayName = 'Spinner';\n\nexport default Spinner;\n","import { Input as ShadInput } from '@/components/shadcn-ui/input';\nimport { Label as ShadLabel } from '@/components/shadcn-ui/label';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { ChangeEventHandler, FocusEventHandler } from 'react';\n\nexport type TextFieldProps = {\n /** Optional unique identifier */\n id?: string;\n /**\n * If `true`, the component is disabled.\n *\n * @default false\n */\n isDisabled?: boolean;\n /**\n * If `true`, the label is displayed in an error state.\n *\n * @default false\n */\n hasError?: boolean;\n /**\n * If `true`, the input will take up the full width of its container.\n *\n * @default false\n */\n isFullWidth?: boolean;\n /** Text that gives the user instructions on what contents the TextField expects */\n helperText?: string;\n /** The title of the TextField */\n label?: string;\n /** The short hint displayed in the `input` before the user enters a value. */\n placeholder?: string;\n /**\n * If `true`, the label is displayed as required and the `input` element is required.\n *\n * @default false\n */\n isRequired?: boolean;\n /** Additional css classes to help with unique styling of the text field */\n className?: string;\n /** Starting value for the text field if it is not controlled */\n defaultValue?: string | number;\n /** Value of the text field if controlled */\n value?: string | number;\n /** Triggers when content of textfield is changed */\n onChange?: ChangeEventHandler;\n /** Triggers when textfield gets focus */\n onFocus?: FocusEventHandler;\n /** Triggers when textfield loses focus */\n onBlur?: FocusEventHandler;\n};\n\n/**\n * Text input field\n *\n * Thanks to Shadcn for heavy inspiration and documentation\n * https://ui.shadcn.com/docs/components/input#with-label\n */\nfunction TextField({\n id,\n isDisabled = false,\n hasError = false,\n isFullWidth = false,\n helperText,\n label,\n placeholder,\n isRequired = false,\n className,\n defaultValue,\n value,\n onChange,\n onFocus,\n onBlur,\n}: TextFieldProps) {\n return (\n
    \n {`${label}${isRequired ? '*' : ''}`}\n \n

    {helperText}

    \n
    \n );\n}\n\nexport default TextField;\n","import HamburgerMenuButton, {\n MultiColumnMenuProvider,\n} from '@/components/mui/hamburger-menu-button.component';\nimport { CommandHandler } from '@/components/mui/menu-item.component';\nimport '@/components/mui/toolbar.component.css';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { AppBar, Toolbar as MuiToolbar } from '@mui/material';\nimport { PropsWithChildren, useRef } from 'react';\n\nexport type ToolbarProps = PropsWithChildren<{\n /** The handler to use for menu commands (and eventually toolbar commands). */\n commandHandler: CommandHandler;\n\n /**\n * The optional delegate to use to get the menu data. If not specified, the \"hamburger\" menu will\n * not display.\n */\n menuProvider?: MultiColumnMenuProvider;\n\n /** Optional unique identifier */\n id?: string;\n\n /** Additional css classes to help with unique styling of the toolbar */\n className?: string;\n}>;\n\nexport default function Toolbar({\n menuProvider,\n commandHandler,\n className,\n id,\n children,\n}: ToolbarProps) {\n // This ref will always be defined\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const containerRef = useRef(undefined!);\n\n return (\n
    \n \n \n {menuProvider ? (\n \n ) : undefined}\n {children ?
    {children}
    : undefined}\n \n
    \n
    \n );\n}\n","import React from 'react';\nimport { cva, type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst alertVariants = cva(\n 'tw-relative tw-w-full tw-rounded-lg tw-border tw-p-4 [&>svg~*]:tw-pl-7 [&>svg+div]:tw-translate-y-[-3px] [&>svg]:tw-absolute [&>svg]:tw-left-4 [&>svg]:tw-top-4 [&>svg]:tw-text-foreground',\n {\n variants: {\n variant: {\n default: 'tw-bg-background tw-text-foreground',\n destructive:\n 'tw-border-destructive/50 tw-text-destructive dark:tw-border-destructive [&>svg]:tw-text-destructive',\n },\n },\n defaultVariants: {\n variant: 'default',\n },\n },\n);\n\nconst Alert = React.forwardRef<\n HTMLDivElement,\n React.HTMLAttributes & VariantProps\n>(({ className, variant, ...props }, ref) => (\n
    \n));\nAlert.displayName = 'Alert';\n\nconst AlertTitle = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n {/* added because of https://github.com/jsx-eslint/eslint-plugin-jsx-a11y/blob/main/docs/rules/heading-has-content.md */}\n {props.children}{' '}\n \n ),\n);\nAlertTitle.displayName = 'AlertTitle';\n\nconst AlertDescription = React.forwardRef<\n HTMLParagraphElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n
    \n));\nAlertDescription.displayName = 'AlertDescription';\n\nexport { Alert, AlertTitle, AlertDescription };\n","import React from 'react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Card = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nCard.displayName = 'Card';\n\nconst CardHeader = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nCardHeader.displayName = 'CardHeader';\n\nconst CardTitle = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n {/* added because of https://github.com/jsx-eslint/eslint-plugin-jsx-a11y/blob/main/docs/rules/heading-has-content.md */}\n {props.children}\n \n ),\n);\nCardTitle.displayName = 'CardTitle';\n\nconst CardDescription = React.forwardRef<\n HTMLParagraphElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n

    \n));\nCardDescription.displayName = 'CardDescription';\n\nconst CardContent = React.forwardRef>(\n ({ className, ...props }, ref) => (\n

    \n ),\n);\nCardContent.displayName = 'CardContent';\n\nconst CardFooter = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nCardFooter.displayName = 'CardFooter';\n\nexport { Card, CardHeader, CardFooter, CardTitle, CardDescription, CardContent };\n","import { ComponentProps } from 'react';\nimport { toast as sonner, Toaster } from 'sonner';\n\ntype SonnerProps = ComponentProps;\n\nfunction Sonner({ ...props }: SonnerProps) {\n return (\n \n );\n}\n\n// The re-export of the sonner function was added manually\nexport { Sonner, sonner };\n","import React from 'react';\nimport * as SliderPrimitive from '@radix-ui/react-slider';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Slider = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n \n \n \n));\nSlider.displayName = SliderPrimitive.Root.displayName;\n\nexport { Slider };\n","import React from 'react';\nimport * as SwitchPrimitives from '@radix-ui/react-switch';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Switch = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n));\nSwitch.displayName = SwitchPrimitives.Root.displayName;\n\nexport { Switch };\n","import React from 'react';\nimport * as TabsPrimitive from '@radix-ui/react-tabs';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport const Tabs = TabsPrimitive.Root;\n\nexport type TabsListProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport type TabsTriggerProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport type TabsContentProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport const TabsList = React.forwardRef<\n React.ElementRef,\n TabsListProps\n>(({ className, ...props }, ref) => (\n \n));\nTabsList.displayName = TabsPrimitive.List.displayName;\n\nexport const TabsTrigger = React.forwardRef<\n React.ElementRef,\n TabsTriggerProps\n>(({ className, ...props }, ref) => (\n \n));\nTabsTrigger.displayName = TabsPrimitive.Trigger.displayName;\n\nexport const TabsContent = React.forwardRef<\n React.ElementRef,\n TabsContentProps\n>(({ className, ...props }, ref) => (\n \n));\nTabsContent.displayName = TabsPrimitive.Content.displayName;\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Download } from 'lucide-react';\n\ntype InstallButtonProps = {\n /** The installing boolean value determines the state of the button. */\n isInstalling: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n /** Optional text for the button. */\n buttonText?: string;\n} & ButtonProps;\n\n/**\n * The InstallButton component is a button designed for initiating installs. It includes visuals for\n * active installing and idle states.\n *\n * @param isInstalling The installing boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @param buttonText Optional text for the button.\n * @returns A install button.\n */\nexport default function InstallButton({\n isInstalling,\n handleClick,\n buttonText,\n className,\n ...props\n}: InstallButtonProps) {\n return (\n \n {isInstalling ? (\n \n ) : (\n <>\n \n {buttonText}\n \n )}\n \n );\n}\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\n\ntype EnableButtonProps = {\n /** The enabling boolean value determines the state of the button. */\n isEnabling: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n} & ButtonProps;\n\n/**\n * The EnableButton component is a button designed for initiating enabling of downloads. It includes\n * visuals for active enabling and idle states.\n *\n * @param isEnabling The enabling boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @returns A button that can be used to enable.\n */\nexport default function EnableButton({\n isEnabling,\n handleClick,\n className,\n ...props\n}: EnableButtonProps) {\n return (\n \n {isEnabling ? (\n <>\n \n Enabling...\n \n ) : (\n 'Enable'\n )}\n \n );\n}\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\n\ntype DisableButtonProps = {\n /** The disabling boolean value determines the state of the button. */\n isDisabling: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n} & ButtonProps;\n\n/**\n * The DisableButton component is a button designed for initiating disabling of downloads. It\n * includes visuals for active disabling and idle states.\n *\n * @param isDisabling The disabling boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @returns A button that can be used to disable.\n */\nexport default function DisableButton({\n isDisabling,\n handleClick,\n className,\n ...props\n}: DisableButtonProps) {\n return (\n \n {isDisabling ? (\n <>\n \n Disabling...\n \n ) : (\n 'Disable'\n )}\n \n );\n}\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\n\ntype UpdateButtonProps = {\n /** The updating boolean value determines the state of the button. */\n isUpdating: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n} & ButtonProps;\n\n/**\n * The UpdateButton component is a button designed for initiating updates for downloaded extensions.\n * It includes visuals for active updating and idle states.\n *\n * @param isUpdating The updating boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @returns A button that can be used to update.\n */\nexport default function UpdateButton({\n isUpdating,\n handleClick,\n className,\n ...props\n}: UpdateButtonProps) {\n return (\n \n {isUpdating ? (\n <>\n \n Updating...\n \n ) : (\n 'Update'\n )}\n \n );\n}\n","import { cn } from '@/utils/shadcn-ui.util';\nimport Markdown, { MarkdownToJSX } from 'markdown-to-jsx';\nimport { useMemo } from 'react';\n\ninterface MarkdownRendererProps {\n /** Optional unique identifier */\n id?: string;\n /** The markdown string to render */\n markdown: string;\n className?: string;\n /**\n * The [`target` attribute for `a` html\n * tags](https://developer.mozilla.org/en-US/docs/Web/HTML/Element/a#target). Defaults to not\n * adding a `target` to `a` tags\n */\n anchorTarget?: string;\n}\n\n/**\n * This component renders markdown content given a markdown string. It uses typography styles from\n * the platform.\n *\n * @param markdown The markdown string to render.\n * @param id Optional unique identifier\n * @returns A div containing the rendered markdown content.\n */\nexport default function MarkdownRenderer({\n id,\n markdown,\n className,\n anchorTarget,\n}: MarkdownRendererProps) {\n const options: MarkdownToJSX.Options = useMemo(\n () => ({\n overrides: {\n a: {\n props: {\n target: anchorTarget,\n },\n },\n },\n }),\n [anchorTarget],\n );\n return (\n
    \n {markdown}\n
    \n );\n}\n","import { Filter, ChevronDown } from 'lucide-react';\nimport { forwardRef } from 'react';\nimport { Button } from '@/components/shadcn-ui/button';\n\n/**\n * The FilterButton component is a button designed for initiating filtering of data. It is designed\n * to be used with the dropdown menu. It uses forwardRef to pass the button to the dropdown trigger\n * asChild.\n *\n * @returns A button that can be used to filter.\n */\nconst FilterButton = forwardRef((props, ref) => {\n return (\n \n \n Filter\n \n \n );\n});\n\nexport default FilterButton;\n","import {\n DropdownMenu,\n DropdownMenuTrigger,\n DropdownMenuContent,\n DropdownMenuLabel,\n DropdownMenuGroup,\n DropdownMenuCheckboxItem,\n DropdownMenuRadioItem,\n DropdownMenuSeparator,\n} from '@/components/shadcn-ui/dropdown-menu';\nimport FilterButton from './buttons/filter-button.component';\n\nexport enum DropdownMenuItemType {\n Check,\n Radio,\n}\n\nexport type DropdownItem = {\n /** The label is the text that will be displayed on the dropdown item. */\n label: string;\n /** The itemType determines the DropdownMenuItemType type as either Check or Radio. */\n itemType: DropdownMenuItemType;\n /** The onClick function is called when the item is clicked. */\n onClick: () => void;\n};\n\nexport type DropdownGroup = {\n /**\n * The label is the text that will be displayed on the dropdown group. It is used to categorize\n * the items in the group.\n */\n label: string;\n /** The items array contains the items that will be displayed in the dropdown group */\n items: DropdownItem[];\n};\n\nexport type FilterDropdownProps = {\n /** Object unique identifier */\n id?: string;\n /** The groups array contains the groups that will be displayed in the dropdown */\n groups: DropdownGroup[];\n}; // TODO: extend the props later\n\n/**\n * The FilterDropdown component is a dropdown designed for filtering content. It includes groups of\n * items that can be checkboxes or radio items.\n *\n * @param id Optional unique identifier\n * @param groups The groups array contains the groups that will be displayed in the dropdown\n * @returns A filter dropdown.\n */\nexport default function FilterDropdown({ id, groups }: FilterDropdownProps) {\n return (\n
    \n {/* TODO: remove this once the DropDown Menu shadcn has an id prop */}\n \n \n \n \n \n {groups.map((group) => (\n
    \n {group.label}\n \n {group.items.map((item) => (\n
    \n {item.itemType === DropdownMenuItemType.Check ? (\n \n {item.label}\n \n ) : (\n \n {item.label}\n \n )}\n
    \n ))}\n
    \n \n
    \n ))}\n
    \n
    \n
    \n );\n}\n","interface NoExtensionsFoundProps {\n /** Optional unique identifier */\n id?: string;\n /** The message to display */\n message: string;\n}\n/**\n * This component displays a message to the user when no extensions are found in the marketplace.\n *\n * @param id Optional unique identifier\n * @param message The message to display.\n * @returns {JSX.Element} - Returns the message component that displays the message to the user.\n */\nexport default function NoExtensionsFound({ id, message }: NoExtensionsFoundProps) {\n return (\n
    \n
    \n

    {message}

    \n
    \n
    \n );\n}\n","import { CircleHelp, Link as LucideLink, User } from 'lucide-react';\nimport { NumberFormat } from 'platform-bible-utils';\n\n/** Interface that stores the parameters passed to the More Info component */\ninterface MoreInfoProps {\n /** Optional unique identifier */\n id?: string;\n /** The category of the extension */\n category: string;\n /** The number of downloads for the extension */\n downloads: Record;\n /** The languages supported by the extension */\n languages: string[];\n /** The URL to the more info page of the extension */\n moreInfoUrl: string;\n}\n/**\n * This component displays the more info section of the extension which includes the category,\n * number of downloads, languages, and links to the website and support\n *\n * @param id Optional unique identifier\n * @param category The category of the extension\n * @param downloads The number of downloads for the extension\n * @param languages The languages supported by the extension\n * @param moreInfoUrl The URL to the more info page of the extension\n * @returns {JSX.Element} - Returns the more info component that displays the category, number of\n * downloads, languages, and links to the website and support\n */\nexport default function MoreInfo({\n id,\n category,\n downloads,\n languages,\n moreInfoUrl,\n}: MoreInfoProps) {\n /**\n * This constant formats the number of downloads into a more readable format.\n *\n * @example 1000 -> 1K\n *\n * @example 1000000 -> 1M\n *\n * @returns The formatted number of downloads\n */\n const numberFormatted = new NumberFormat('en', {\n notation: 'compact',\n compactDisplay: 'short',\n }).format(Object.values(downloads).reduce((a: number, b: number) => a + b, 0));\n\n /** This function scrolls the window to the bottom of the page. */\n const handleScrollToBottom = () => {\n window.scrollTo(0, document.body.scrollHeight);\n };\n\n return (\n \n
    \n
    \n {category}\n
    \n CATEGORY\n
    \n
    \n
    \n
    \n \n {numberFormatted}\n
    \n USERS\n
    \n
    \n
    \n
    \n {languages.slice(0, 3).map((locale) => (\n \n {locale.toUpperCase()}\n \n ))}\n
    \n {languages.length > 3 && (\n handleScrollToBottom()}\n className=\"tw-text-xs tw-text-gray-500 tw-underline\"\n >\n +{languages.length - 3} more languages\n \n )}\n
    \n
    \n
    \n \n Website\n \n \n \n Support\n \n \n
    \n
    \n );\n}\n","import { useState } from 'react';\n\nexport type VersionInformation = {\n /** Date the version was published */\n date: string;\n /** Description of the changes in the version */\n description: string;\n};\n\n/** Type to store the version history information */\nexport type VersionHistoryType = Record;\n\n/** Interface that stores the parameters passed to the Version History component */\ninterface VersionHistoryProps {\n /** Optional unique identifier */\n id?: string;\n /** Object containing the versions mapped with their information */\n versionHistory: VersionHistoryType;\n}\n\n/**\n * Component to render the version history information shown in the footer component. Lists the 5\n * most recent versions, with the options to show all versions by pressing a button.\n *\n * @param versionHistory Object containing the versions mapped with their information\n * @param id Optional unique identifier\n * @returns Rendered version history for the Footer component\n */\nexport default function VersionHistory({ id, versionHistory }: VersionHistoryProps) {\n const [showAllVersions, setShowAllVersions] = useState(false);\n const currentDate = new Date();\n\n /**\n * Function to format the time string for the version history in the form of 'X year(s) ago'.\n *\n * @param dateString ISO Date string to determine the time string from\n * @returns Formatted time string\n */\n function formatTimeString(dateString: string) {\n const date = new Date(dateString);\n const dateDiff = new Date(currentDate.getTime() - date.getTime());\n const yearDiff = dateDiff.getUTCFullYear() - 1970;\n const monthDiff = dateDiff.getUTCMonth();\n const dayDiff = dateDiff.getUTCDate() - 1;\n\n // Determines how long ago the version was published\n let timeString = '';\n if (yearDiff > 0) {\n timeString = `${yearDiff.toString()} year${yearDiff === 1 ? '' : 's'} ago`;\n } else if (monthDiff > 0) {\n timeString = `${monthDiff.toString()} month${monthDiff === 1 ? '' : 's'} ago`;\n } else if (dayDiff === 0) {\n timeString = 'today';\n } else {\n timeString = `${dayDiff.toString()} day${dayDiff === 1 ? '' : 's'} ago`;\n }\n\n return timeString;\n }\n\n // Sorts the version history by version number\n const sortedEntries = Object.entries(versionHistory).sort((a, b) => b[0].localeCompare(a[0]));\n\n return (\n
    \n

    What`s New

    \n
      \n {(showAllVersions ? sortedEntries : sortedEntries.slice(0, 5)).map((entry) => (\n
      \n
      \n
    • \n {entry[1].description}\n
    • \n
      \n
      \n
      Version {entry[0]}
      \n
      {formatTimeString(entry[1].date)}
      \n
      \n
      \n ))}\n
    \n {sortedEntries.length > 5 && (\n setShowAllVersions(!showAllVersions)}\n className=\"tw-text-xs tw-text-gray-500 tw-underline\"\n >\n {showAllVersions ? 'Show Less Version History' : 'Show All Version History'}\n \n )}\n
    \n );\n}\n","import { useMemo } from 'react';\nimport { formatBytes } from 'platform-bible-utils';\nimport VersionHistory, { VersionHistoryType } from './version-history.component';\n\n/** Interface to store the parameters passed to the Footer component */\ninterface FooterProps {\n /** Optional unique identifier */\n id?: string;\n /** Name of the publisher */\n publisherDisplayName: string;\n /** Size of the extension file in bytes */\n fileSize: number;\n /** List of language codes supported by the extension */\n locales: string[];\n /** Object containing the version history mapped with their information */\n versionHistory: VersionHistoryType;\n}\n\n/**\n * Component to render the footer for the extension details which contains information on the\n * publisher, version history, languages, and file size.\n *\n * @param id Optional unique identifier\n * @param publisherDisplayName Name of the publisher\n * @param fileSize Size of the extension file in bytes\n * @param locales List of language codes supported by the extension\n * @param versionHistory Object containing the version history mapped with their information\n * @returns The rendered Footer component\n */\nexport default function Footer({\n id,\n publisherDisplayName,\n fileSize,\n locales,\n versionHistory,\n}: FooterProps) {\n /** Formats the file size into a human-readable format */\n const formattedFileSize = useMemo(() => formatBytes(fileSize), [fileSize]);\n\n /**\n * This function gets the display names of the languages based on the language codes.\n *\n * @param codes The list of language codes\n * @returns The list of language names\n */\n const getLanguageNames = (codes: string[]) => {\n const displayNames = new Intl.DisplayNames(navigator.language, { type: 'language' });\n return codes.map((code) => displayNames.of(code));\n };\n\n const languageNames = getLanguageNames(locales);\n\n return (\n
    \n
    \n \n
    \n
    \n

    Information

    \n
    \n

    \n Publisher\n {publisherDisplayName}\n Size\n {formattedFileSize}\n

    \n
    \n

    \n Languages\n {languageNames.join(', ')}\n

    \n
    \n
    \n
    \n
    \n
    \n );\n}\n","import { PlatformEvent, PlatformEventHandler } from 'platform-bible-utils';\nimport { useEffect } from 'react';\n\n/**\n * Adds an event handler to an event so the event handler runs when the event is emitted. Use\n * `papi.network.getNetworkEvent` to use a networked event with this hook.\n *\n * @param event The event to subscribe to.\n *\n * - If event is a `PlatformEvent`, that event will be used\n * - If event is undefined, the callback will not be subscribed. Useful if the event is not yet\n * available for example\n *\n * @param eventHandler The callback to run when the event is emitted\n *\n * WARNING: MUST BE STABLE - const or wrapped in useCallback. The reference must not be updated\n * every render\n */\nconst useEvent = (\n event: PlatformEvent | undefined,\n eventHandler: PlatformEventHandler,\n) => {\n useEffect(() => {\n // Do nothing if the event is not provided (in case the event is not yet available, for example)\n if (!event) return () => {};\n\n const unsubscriber = event(eventHandler);\n return () => {\n unsubscriber();\n };\n }, [event, eventHandler]);\n};\nexport default useEvent;\n","import { useCallback, useEffect } from 'react';\nimport { PlatformEvent, PlatformEventAsync, PlatformEventHandler } from 'platform-bible-utils';\nimport usePromise from './use-promise.hook';\n\nconst noopUnsubscriber = () => false;\n\n/**\n * Adds an event handler to an asynchronously subscribing/unsubscribing event so the event handler\n * runs when the event is emitted. Use `papi.network.getNetworkEvent` to use a networked event with\n * this hook.\n *\n * @param event The asynchronously (un)subscribing event to subscribe to.\n *\n * - If event is a `PlatformEvent` or `PlatformEventAsync`, that event will be used\n * - If event is undefined, the callback will not be subscribed. Useful if the event is not yet\n * available for example\n *\n * @param eventHandler The callback to run when the event is emitted\n *\n * WARNING: MUST BE STABLE - const or wrapped in useCallback. The reference must not be updated\n * every render\n */\nconst useEventAsync = (\n event: PlatformEvent | PlatformEventAsync | undefined,\n eventHandler: PlatformEventHandler,\n) => {\n // Subscribe to the event asynchronously\n const [unsubscribe] = usePromise(\n useCallback(async () => {\n // Do nothing if the event is not provided (in case the event is not yet available, for example)\n if (!event) return noopUnsubscriber;\n\n // Wrap subscribe and unsubscribe in promises to allow normal events to be used as well\n const unsub = await Promise.resolve(event(eventHandler));\n return async () => unsub();\n }, [eventHandler, event]),\n noopUnsubscriber,\n // We want the unsubscriber to return to default value immediately upon changing subscription\n // So the useEffect below will unsubscribe asap\n { preserveValue: false },\n );\n\n // Unsubscribe from the event asynchronously (but we aren't awaiting the unsub)\n useEffect(() => {\n return () => {\n if (unsubscribe !== noopUnsubscriber) {\n unsubscribe();\n }\n };\n }, [unsubscribe]);\n};\n\nexport default useEventAsync;\n"],"names":["twMergeCustom","extendTailwindMerge","cn","inputs","clsx","Input","React","className","type","props","ref","jsx","BookChapterInput","forwardRef","handleSearch","handleKeyDown","handleOnClick","handleSubmit","jsxs","ShadInput","event","e","History","P","R","t","s","n","N","B","O","S","K","g","k","x","T","X","V","w","L","G","A","H","C","I","y","q","U","m","l","h","c","E","D","i","a","o","u","v","f","d","b","p","J","DropdownMenu","DropdownMenuPrimitive","DropdownMenuTrigger","DropdownMenuGroup","DropdownMenuPortal","DropdownMenuSub","DropdownMenuRadioGroup","DropdownMenuSubTrigger","inset","children","ChevronRight","DropdownMenuSubContent","DropdownMenuContent","sideOffset","DropdownMenuItem","DropdownMenuCheckboxItem","checked","Check","DropdownMenuRadioItem","Circle","DropdownMenuLabel","DropdownMenuSeparator","DropdownMenuShortcut","BookMenuItem","bookId","handleSelectBook","isSelected","handleHighlightBook","bookType","ShadDropdownMenuItem","Canon","ChapterSelect","handleSelectChapter","endChapter","activeChapter","highlightedChapter","handleHighlightedChapter","chapters","_","handleMouse","useCallback","chapterNumber","chapter","GoToMenuItem","handleSort","handleLocationHistory","handleBookmarks","ShadDropdownMenuLabel","ArrowDownWideNarrow","Clock","Bookmark","ALL_BOOK_IDS","BOOK_TYPE_LABELS","BOOK_TYPE_ARRAY","SCROLL_OFFSET","SEARCH_QUERY_FORMATS","fetchGroupedBooks","fetchEndChapter","getChaptersForBook","getAllEnglishNames","isValidBookEnglishName","bookName","getBookIdFromEnglishName","formattedBookName","BookChapterControl","scrRef","searchQuery","setSearchQuery","useState","selectedBookId","setSelectedBookId","setHighlightedChapter","highlightedBookId","setHighlightedBookId","isContentOpen","setIsContentOpen","isContentOpenDelayed","setIsContentOpenDelayed","inputRef","useRef","contentRef","menuItemRef","fetchFilteredBooks","englishNameLowerCase","normalizedQuery","handleSearchInput","searchString","shouldPreventAutoClosing","controlMenuState","open","updateReference","shouldClose","verse","handleInputSubmit","format","matches","book","englishName","handleKeyDownInput","handleKeyDownContent","key","handleKeyDownMenuItem","chapterOffSet","useEffect","useLayoutEffect","scrollTimeout","scrollPosition","ShadDropdownMenu","ShadDropdownMenuTrigger","ShadDropdownMenuContent","bookTypeIndex","element","ShadDropdownMenuSeparator","buttonVariants","cva","Button","variant","size","asChild","Comp","Slot","labelVariants","Label","LabelPrimitive","RadioGroup","RadioGroupPrimitive","RadioGroupItem","Popover","PopoverPrimitive","PopoverTrigger","PopoverContent","align","DialogPortal","DialogPrimitive","DialogOverlay","DialogContent","DialogTitle","DialogDescription","Command","CommandPrimitive","CommandInput","Search","CommandList","CommandEmpty","CommandGroup","CommandSeparator","CommandItem","getOptionLabelDefault","option","ComboBox","id","options","buttonClassName","popoverContentClassName","value","onChange","getOptionLabel","buttonPlaceholder","textPlaceholder","commandEmptyMessage","buttonVariant","dir","isDisabled","setOpen","ChevronsUpDown","ChapterRangeSelector","startChapter","handleSelectStartChapter","handleSelectEndChapter","chapterCount","chapterOptions","useMemo","index","onChangeStartChapter","onChangeEndChapter","Fragment","BookSelectionMode","BOOK_SELECTOR_STRING_KEYS","localizeString","strings","BookSelector","handleBookSelectionModeChange","currentBookName","onSelectBooks","selectedBookIds","localizedStrings","currentBookText","chooseText","chooseBooksText","bookSelectionMode","setBookSelectionMode","onSelectionModeChange","newMode","DataTableViewOptions","table","FilterIcon","column","Select","SelectPrimitive","SelectGroup","SelectValue","SelectTrigger","ChevronDown","SelectScrollUpButton","ChevronUp","SelectScrollDownButton","SelectContent","position","SelectLabel","SelectItem","SelectSeparator","DataTablePagination","pageSize","ArrowLeftIcon","ChevronLeftIcon","ChevronRightIcon","ArrowRightIcon","Table","stickyHeader","TableHeader","TableBody","TableFooter","TableRow","TableHead","TableCell","TableCaption","DataTable","columns","data","enablePagination","showPaginationControls","showColumnVisibilityControls","onRowClickHandler","sorting","setSorting","columnFilters","setColumnFilters","columnVisibility","setColumnVisibility","rowSelection","setRowSelection","useReactTable","getCoreRowModel","getPaginationRowModel","getSortedRowModel","getFilteredRowModel","headerGroup","header","flexRender","_a","row","cell","OccurrencesTable","occurrenceData","setScriptureReference","referenceHeaderText","occurrenceHeaderText","occurrences","uniqueOccurrences","occurrence","uniqueOccurrence","deepEqual","Checkbox","CheckboxPrimitive","getLinesFromUSFM","text","getNumberFromUSFM","regex","match","getBookNumFromId","getStatusForItem","item","approvedItems","unapprovedItems","toggleVariants","Toggle","TogglePrimitive","ToggleGroupContext","ToggleGroup","ToggleGroupPrimitive","ToggleGroupItem","context","getSortingIcon","sortDirection","ArrowUpIcon","ArrowDownIcon","ArrowUpDownIcon","inventoryItemColumn","itemLabel","inventoryAdditionalItemColumn","additionalItemLabel","additionalItemIndex","inventoryCountColumn","countLabel","statusChangeHandler","changedItems","newStatus","onApprovedItemsChange","onUnapprovedItemsChange","newApprovedItems","validItem","newUnapprovedItems","unapprovedItem","inventoryStatusColumn","statusLabel","status","CircleCheckIcon","CircleXIcon","CircleHelpIcon","INVENTORY_STRING_KEYS","filterItemData","itemData","statusFilter","textFilter","filteredItemData","createTableData","scriptureRef","itemRegex","tableData","currentBook","currentChapter","currentVerse","line","items","itemIndex","existingItem","tableEntry","newReference","substring","newItem","Inventory","scriptureReference","extractItems","additionalItemsLabels","scope","onScopeChange","allItemsText","approvedItemsText","unapprovedItemsText","unknownItemsText","scopeBookText","scopeChapterText","scopeVerseText","filterText","showAdditionalItemsText","showAdditionalItems","setShowAdditionalItems","setStatusFilter","setTextFilter","selectedItem","setSelectedItem","reducedTableData","newTableData","firstItem","existingEntry","newTableEntry","filteredTableData","allColumns","numberOfAdditionalItems","additionalColumns","_b","rowClickHandler","newSelection","handleScopeChange","handleStatusFilterChange","SearchBar","onSearch","placeholder","isFullWidth","handleInputChange","VerticalTabs","TabsPrimitive","VerticalTabsList","VerticalTabsTrigger","VerticalTabsContent","TabNavigationContentSearch","tabList","searchPlaceholder","headerTitle","isSearchBarFullWidth","direction","tab","Separator","orientation","decorative","SeparatorPrimitive","Sheet","SheetPrimitive","SheetPortal","SheetOverlay","sheetVariants","SheetContent","side","SheetTitle","SheetDescription","Skeleton","TooltipProvider","TooltipPrimitive","Tooltip","TooltipTrigger","TooltipContent","MOBILE_BREAKPOINT","useIsMobile","isMobile","setIsMobile","mql","SIDEBAR_COOKIE_NAME","SIDEBAR_COOKIE_MAX_AGE","SIDEBAR_WIDTH","SIDEBAR_WIDTH_MOBILE","SIDEBAR_WIDTH_ICON","SIDEBAR_KEYBOARD_SHORTCUT","SidebarContext","useSidebar","SidebarProvider","defaultOpen","openProp","setOpenProp","style","openMobile","setOpenMobile","_open","_setOpen","isOpen","openState","toggleSidebar","state","contextValue","Sidebar","collapsible","SidebarTrigger","onClick","PanelLeft","SidebarRail","SidebarInset","SidebarInput","SidebarHeader","SidebarFooter","SidebarSeparator","SidebarContent","SidebarGroup","SidebarGroupLabel","SidebarGroupAction","SidebarGroupContent","SidebarMenu","SidebarMenuItem","sidebarMenuButtonVariants","SidebarMenuButton","isActive","tooltip","button","SidebarMenuAction","showOnHover","SidebarMenuBadge","SidebarMenuSkeleton","showIcon","width","SidebarMenuSub","SidebarMenuSubItem","SidebarMenuSubButton","SettingsSidebar","extensionLabels","projectOptions","handleSelectSidebarItem","selectedSidebarItem","handleSelectItem","projectId","getProjectNameFromProjectId","project","getIsActive","label","selectedProjectName","SettingsSidebarContentSearch","scrBookColId","scrRefColId","typeColId","detailsColId","defaultScrRefColumnName","defaultScrBookGroupName","defaultTypeColumnName","defaultDetailsColumnName","getColumns","colInfo","showSourceColumn","showSrcCol","info","formatScrRef","compareScrRefs","toRefOrRange","scriptureSelection","offsetStart","offsetEnd","scrRefToBBBCCCVVV","getRowKey","ScriptureResultsViewer","sources","showColumnHeaders","scriptureReferenceColumnName","scriptureBookGroupName","typeColumnName","detailsColumnName","onRowSelected","grouping","setGrouping","scriptureResults","source","getExpandedRowModel","getGroupedRowModel","selectedRows","keys","selectedRow","scrBookGroupName","typeGroupName","groupingOptions","handleSelectChange","selectedGrouping","handleRowClick","getEvenOrOddBandingStyle","getIndent","groupingState","rowIndex","ChevronLeft","DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS","getLocalizeKeyForScrollGroupId","ScrollGroupSelector","availableScrollGroupIds","scrollGroupId","onChangeScrollGroupId","localizedStringsDefaulted","localizedStringKey","localizedStringValue","newScrollGroupString","scrollGroupOptionId","SettingsList","SettingsListItem","primary","secondary","isLoading","loadingMessage","SettingsListHeader","includeSeparator","Checklist","listItems","selectedListItems","handleSelectListItem","createLabel","_interopRequireDefault","obj","module","chainPropTypes","propType1","propType2","args","_extends","target","isPlainObject","prototype","deepClone","output","deepmerge","r","z","reactIs_production_min","hasSymbol","REACT_ELEMENT_TYPE","REACT_PORTAL_TYPE","REACT_FRAGMENT_TYPE","REACT_STRICT_MODE_TYPE","REACT_PROFILER_TYPE","REACT_PROVIDER_TYPE","REACT_CONTEXT_TYPE","REACT_ASYNC_MODE_TYPE","REACT_CONCURRENT_MODE_TYPE","REACT_FORWARD_REF_TYPE","REACT_SUSPENSE_TYPE","REACT_SUSPENSE_LIST_TYPE","REACT_MEMO_TYPE","REACT_LAZY_TYPE","REACT_BLOCK_TYPE","REACT_FUNDAMENTAL_TYPE","REACT_RESPONDER_TYPE","REACT_SCOPE_TYPE","isValidElementType","typeOf","object","$$typeof","$$typeofType","AsyncMode","ConcurrentMode","ContextConsumer","ContextProvider","Element","ForwardRef","Lazy","Memo","Portal","Profiler","StrictMode","Suspense","hasWarnedAboutDeprecatedIsAsyncMode","isAsyncMode","isConcurrentMode","isContextConsumer","isContextProvider","isElement","isForwardRef","isFragment","isLazy","isMemo","isPortal","isProfiler","isStrictMode","isSuspense","reactIs_development","reactIsModule","require$$0","require$$1","getOwnPropertySymbols","hasOwnProperty","propIsEnumerable","toObject","val","shouldUseNative","test1","test2","order2","test3","letter","objectAssign","from","to","symbols","ReactPropTypesSecret","ReactPropTypesSecret_1","has","printWarning","loggedTypeFailures","message","checkPropTypes","typeSpecs","values","location","componentName","getStack","typeSpecName","error","err","ex","stack","checkPropTypes_1","ReactIs","assign","require$$2","require$$3","require$$4","emptyFunctionThatReturnsNull","factoryWithTypeCheckers","isValidElement","throwOnDirectAccess","ITERATOR_SYMBOL","FAUX_ITERATOR_SYMBOL","getIteratorFn","maybeIterable","iteratorFn","ANONYMOUS","ReactPropTypes","createPrimitiveTypeChecker","createAnyTypeChecker","createArrayOfTypeChecker","createElementTypeChecker","createElementTypeTypeChecker","createInstanceTypeChecker","createNodeChecker","createObjectOfTypeChecker","createEnumTypeChecker","createUnionTypeChecker","createShapeTypeChecker","createStrictShapeTypeChecker","is","PropTypeError","createChainableTypeChecker","validate","manualPropTypeCallCache","manualPropTypeWarningCount","checkType","isRequired","propName","propFullName","secret","cacheKey","chainedCheckType","expectedType","propValue","propType","getPropType","preciseType","getPreciseType","typeChecker","expectedClass","expectedClassName","actualClassName","getClassName","expectedValues","valuesString","arrayOfTypeCheckers","checker","getPostfixForTypeWarning","expectedTypes","checkerResult","expectedTypesMessage","isNode","invalidValidatorError","shapeTypes","allKeys","iterator","step","entry","isSymbol","emptyFunction","emptyFunctionWithReset","factoryWithThrowingShims","shim","getShim","propTypesModule","isClassComponent","elementType","acceptingRef","safePropName","warningHint","elementAcceptingRef","PropTypes","elementAcceptingRef$1","specialProperty","exactProp","propTypes","unsupportedProps","prop","formatMuiErrorMessage","code","url","REACT_SERVER_CONTEXT_TYPE","REACT_OFFSCREEN_TYPE","enableScopeAPI","enableCacheElement","enableTransitionTracing","enableLegacyHidden","enableDebugTracing","REACT_MODULE_REFERENCE","SuspenseList","hasWarnedAboutDeprecatedIsConcurrentMode","isSuspenseList","fnNameMatchRegex","getFunctionName","fn","getFunctionComponentName","Component","fallback","getWrappedName","outerType","innerType","wrapperName","functionName","getDisplayName","HTMLElementType","refType","refType$1","capitalize","string","_formatMuiErrorMessage","createChainedFunction","funcs","acc","func","debounce","wait","timeout","debounced","later","deprecatedPropType","validator","reason","componentNameSafe","propFullNameSafe","isMuiElement","muiNames","_muiName","_element$type","ownerDocument","node","ownerWindow","requirePropFactory","componentNameInError","prevPropTypes","requiredProp","defaultTypeChecker","typeCheckerResult","setRef","useEnhancedEffect","useEnhancedEffect$1","globalId","useGlobalId","idOverride","defaultId","setDefaultId","maybeReactUseId","useId","reactId","unsupportedProp","useControlled","controlled","defaultProp","name","isControlled","valueState","setValue","defaultValue","setValueIfUncontrolled","newValue","useEventCallback","useForkRef","refs","instance","UNINITIALIZED","useLazyRef","init","initArg","EMPTY","useOnMount","Timeout","delay","useTimeout","hadKeyboardEvent","hadFocusVisibleRecently","hadFocusVisibleRecentlyTimeout","inputTypesWhitelist","focusTriggersKeyboardModality","tagName","handlePointerDown","handleVisibilityChange","prepare","doc","isFocusVisible","useIsFocusVisible","isFocusVisibleRef","handleBlurVisible","handleFocusVisible","resolveProps","defaultProps","defaultSlotProps","slotProps","slotPropName","composeClasses","slots","getUtilityClass","classes","slot","utilityClass","defaultGenerator","createClassNameGenerator","generate","generator","ClassNameGenerator","ClassNameGenerator$1","globalStateClasses","generateUtilityClass","globalStatePrefix","globalStateClass","generateUtilityClasses","result","clamp","min","max","_objectWithoutPropertiesLoose","excluded","sourceKeys","_excluded","sortBreakpointsValues","breakpointsAsArray","breakpoint1","breakpoint2","createBreakpoints","breakpoints","unit","other","sortedValues","up","down","between","start","end","endIndex","only","not","keyIndex","shape","shape$1","responsivePropType","responsivePropType$1","merge","defaultBreakpoints","handleBreakpoints","styleFromPropValue","theme","themeBreakpoints","breakpoint","mediaKey","cssKey","createEmptyBreakpointObject","breakpointsInput","_breakpointsInput$key","breakpointStyleKey","removeUnusedBreakpoints","breakpointKeys","breakpointOutput","getPath","path","checkVars","getStyleValue","themeMapping","transform","propValueFinal","userValue","cssProperty","themeKey","memoize","cache","arg","properties","directions","aliases","getCssProperties","property","marginKeys","paddingKeys","spacingKeys","createUnaryUnit","_getPath","themeSpacing","abs","createUnarySpacing","getValue","transformer","transformed","getStyleFromPropValue","cssProperties","resolveCssProperty","margin","padding","createSpacing","spacingInput","spacing","argsInput","argument","compose","styles","handlers","borderTransform","createBorderStyle","border","borderTop","borderRight","borderBottom","borderLeft","borderColor","borderTopColor","borderRightColor","borderBottomColor","borderLeftColor","outline","outlineColor","borderRadius","gap","columnGap","rowGap","gridColumn","gridRow","gridAutoFlow","gridAutoColumns","gridAutoRows","gridTemplateColumns","gridTemplateRows","gridTemplateAreas","gridArea","paletteTransform","color","bgcolor","backgroundColor","sizingTransform","maxWidth","_props$theme","_props$theme2","breakpointsValues","minWidth","height","maxHeight","minHeight","boxSizing","defaultSxConfig","defaultSxConfig$1","objectsHaveSameKeys","objects","union","callIfFn","maybeFn","unstable_createStyleFunctionSx","getThemeValue","config","styleFunctionSx","_theme$unstable_sxCon","sx","traverse","sxInput","sxObject","emptyBreakpoints","breakpointsKeys","css","styleKey","styleFunctionSx$1","applyStyles","createTheme","paletteInput","shapeInput","muiTheme","isObjectEmpty","useTheme","defaultTheme","contextTheme","ThemeContext","systemDefaultTheme","useThemeWithoutDefault","_excluded2","_excluded3","isEmpty","isStringTag","tag","shouldForwardProp","lowercaseFirstLetter","resolveTheme","themeId","defaultOverridesResolver","processStyleArg","callableStyle","_ref","ownerState","resolvedStylesArg","resolvedStyle","variants","isMatch","createStyled","input","rootShouldForwardProp","slotShouldForwardProp","systemSx","inputOptions","processStyles","componentSlot","inputSkipVariantsResolver","inputSkipSx","overridesResolver","skipVariantsResolver","skipSx","shouldForwardPropOption","defaultStyledResolver","styledEngineStyled","transformStyleArg","stylesArg","muiStyledResolver","styleArg","expressions","transformedStyleArg","expressionsWithDefaultTheme","styleOverrides","resolvedStyleOverrides","slotKey","slotStyle","_theme$components","themeVariants","numOfCustomFnsApplied","placeholders","displayName","getThemeProps","params","useThemeProps","clampWrapper","hexToRgb","re","colors","decomposeColor","marker","colorSpace","recomposeColor","hslToRgb","rgb","getLuminance","getContrastRatio","foreground","background","lumA","lumB","alpha","darken","coefficient","lighten","createMixins","mixins","common","common$1","grey","grey$1","purple","purple$1","red","red$1","orange","orange$1","blue","blue$1","lightBlue","lightBlue$1","green","green$1","light","dark","addLightOrDark","intent","shade","tonalOffset","tonalOffsetLight","tonalOffsetDark","getDefaultPrimary","mode","getDefaultSecondary","getDefaultError","getDefaultInfo","getDefaultSuccess","getDefaultWarning","createPalette","palette","contrastThreshold","success","warning","getContrastText","contrastText","contrast","augmentColor","mainShade","lightShade","darkShade","modes","round","caseAllCaps","defaultFontFamily","createTypography","typography","fontFamily","fontSize","fontWeightLight","fontWeightRegular","fontWeightMedium","fontWeightBold","htmlFontSize","allVariants","pxToRem2","coef","pxToRem","buildVariant","fontWeight","lineHeight","letterSpacing","casing","shadowKeyUmbraOpacity","shadowKeyPenumbraOpacity","shadowAmbientShadowOpacity","createShadow","px","shadows","shadows$1","easing","duration","formatMs","milliseconds","getAutoHeightDuration","constant","createTransitions","inputTransitions","mergedEasing","mergedDuration","durationOption","easingOption","isString","isNumber","animatedProp","zIndex","zIndex$1","mixinsInput","transitionsInput","typographyInput","systemTheme","systemCreateTheme","stateClasses","component","child","stateClass","defaultTheme$1","THEME_ID","systemUseThemeProps","styled","styled$1","getSvgIconUtilityClass","useUtilityClasses","SvgIconRoot","_theme$transitions","_theme$transitions$cr","_theme$transitions2","_theme$typography","_theme$typography$pxT","_theme$typography2","_theme$typography2$px","_theme$typography3","_theme$typography3$px","_palette$ownerState$c","_palette","_palette2","_palette3","SvgIcon","inProps","htmlColor","inheritViewBox","titleAccess","viewBox","hasSvgAsChild","more","_jsxs","_jsx","SvgIcon$1","createSvgIcon","unstable_ClassNameGenerator","exports","_utils","ArrowRight","default_1","_createSvgIcon","_jsxRuntime","isHostComponent","appendOwnerState","otherProps","defaultContextValue","ClassNameConfiguratorContext","useClassNamesOverride","disableDefaultClasses","extractEventHandlers","excludeKeys","resolveComponentProps","componentProps","slotState","omitEventHandlers","mergeSlotProps","parameters","getSlotProps","additionalProps","externalSlotProps","externalForwardedProps","joinedClasses","mergedStyle","eventHandlers","componentsPropsWithoutEventHandlers","otherPropsWithoutEventHandlers","internalSlotProps","useSlotProps","_parameters$additiona","skipResolvingSlotProps","rest","resolvedComponentsProps","mergedProps","internalRef","GLOBAL_CLASS_PREFIX","buildStateClass","buildSlotClass","getContainer","container","forwardedRef","disablePortal","mountNode","setMountNode","handleRef","newProps","ReactDOM","top","bottom","right","left","auto","basePlacements","clippingParents","viewport","popper","reference","variationPlacements","placement","placements","beforeRead","read","afterRead","beforeMain","main","afterMain","beforeWrite","write","afterWrite","modifierPhases","getNodeName","getWindow","OwnElement","isHTMLElement","isShadowRoot","attributes","effect","_ref2","initialStyles","styleProperties","attribute","applyStyles$1","getBasePlacement","getUAString","uaData","isLayoutViewport","getBoundingClientRect","includeScale","isFixedStrategy","clientRect","scaleX","scaleY","visualViewport","addVisualOffsets","getLayoutRect","contains","parent","rootNode","next","getComputedStyle","isTableElement","getDocumentElement","getParentNode","getTrueOffsetParent","getContainingBlock","isFirefox","isIE","elementCss","currentNode","getOffsetParent","window","offsetParent","getMainAxisFromPlacement","within","mathMax","mathMin","withinMaxClamp","getFreshSideObject","mergePaddingObject","paddingObject","expandToHashMap","hashMap","toPaddingObject","arrow","_state$modifiersData$","arrowElement","popperOffsets","basePlacement","axis","isVertical","len","arrowRect","minProp","maxProp","endDiff","startDiff","arrowOffsetParent","clientSize","centerToReference","center","offset","axisProp","_options$element","arrow$1","getVariation","unsetSides","roundOffsetsByDPR","win","dpr","mapToStyles","_Object$assign2","popperRect","variation","offsets","gpuAcceleration","adaptive","roundOffsets","isFixed","_offsets$x","_offsets$y","_ref3","hasX","hasY","sideX","sideY","heightProp","widthProp","offsetY","offsetX","commonStyles","_ref4","_Object$assign","computeStyles","_ref5","_options$gpuAccelerat","_options$adaptive","_options$roundOffsets","computeStyles$1","passive","_options$scroll","scroll","_options$resize","resize","scrollParents","scrollParent","eventListeners","hash","getOppositePlacement","matched","getOppositeVariationPlacement","getWindowScroll","scrollLeft","scrollTop","getWindowScrollBarX","getViewportRect","strategy","html","layoutViewport","getDocumentRect","_element$ownerDocumen","winScroll","body","isScrollParent","_getComputedStyle","overflow","overflowX","overflowY","getScrollParent","listScrollParents","list","isBody","updatedList","rectToClientRect","rect","getInnerBoundingClientRect","getClientRectFromMixedType","clippingParent","getClippingParents","canEscapeClipping","clipperElement","getClippingRect","boundary","rootBoundary","mainClippingParents","firstClippingParent","clippingRect","accRect","computeOffsets","commonX","commonY","mainAxis","detectOverflow","_options","_options$placement","_options$strategy","_options$boundary","_options$rootBoundary","_options$elementConte","elementContext","_options$altBoundary","altBoundary","_options$padding","altContext","clippingClientRect","referenceClientRect","popperClientRect","elementClientRect","overflowOffsets","offsetData","multiply","computeAutoPlacement","flipVariations","_options$allowedAutoP","allowedAutoPlacements","allPlacements","allowedPlacements","overflows","getExpandedFallbackPlacements","oppositePlacement","flip","_options$mainAxis","checkMainAxis","_options$altAxis","checkAltAxis","specifiedFallbackPlacements","_options$flipVariatio","preferredPlacement","isBasePlacement","fallbackPlacements","referenceRect","checksMap","makeFallbackChecks","firstFittingPlacement","_basePlacement","isStartVariation","mainVariationSide","altVariationSide","checks","check","numberOfChecks","_loop","_i","fittingPlacement","_ret","flip$1","getSideOffsets","preventedOffsets","isAnySideFullyClipped","hide","referenceOverflow","popperAltOverflow","referenceClippingOffsets","popperEscapeOffsets","isReferenceHidden","hasPopperEscaped","hide$1","distanceAndSkiddingToXY","rects","invertDistance","skidding","distance","_options$offset","_data$state$placement","offset$1","popperOffsets$1","getAltAxis","preventOverflow","_options$tether","tether","_options$tetherOffset","tetherOffset","altAxis","tetherOffsetValue","normalizedTetherOffsetValue","offsetModifierState","_offsetModifierState$","mainSide","altSide","additive","minLen","maxLen","arrowPaddingObject","arrowPaddingMin","arrowPaddingMax","arrowLen","minOffset","maxOffset","clientOffset","offsetModifierValue","tetherMin","tetherMax","preventedOffset","_offsetModifierState$2","_mainSide","_altSide","_offset","_len","_min","_max","isOriginSide","_offsetModifierValue","_tetherMin","_tetherMax","_preventedOffset","preventOverflow$1","getHTMLElementScroll","getNodeScroll","isElementScaled","getCompositeRect","elementOrVirtualElement","isOffsetParentAnElement","offsetParentIsScaled","documentElement","order","modifiers","map","visited","modifier","sort","requires","dep","depModifier","orderModifiers","orderedModifiers","phase","pending","resolve","mergeByName","merged","current","existing","DEFAULT_OPTIONS","areValidElements","_key","popperGenerator","generatorOptions","_generatorOptions","_generatorOptions$def","defaultModifiers","_generatorOptions$def2","defaultOptions","effectCleanupFns","isDestroyed","setOptionsAction","cleanupModifierEffects","runModifierEffects","_state$elements","_state$orderedModifie","_state$orderedModifie2","_ref$options","cleanupFn","noopFn","createPopper","COMPONENT_NAME","getPopperUtilityClass","flipPlacement","resolveAnchorEl","anchorEl","isVirtualElement","defaultPopperOptions","PopperTooltip","_slots$root","initialPlacement","popperOptions","popperRefProp","TransitionProps","tooltipRef","ownRef","popperRef","handlePopperRef","handlePopperRefRef","rtlPlacement","setPlacement","resolvedAnchorElement","setResolvedAnchorElement","handlePopperUpdate","box","popperModifiers","childProps","Root","rootProps","Popper","containerProp","keepMounted","transition","exited","setExited","handleEnter","handleExited","resolvedAnchorEl","display","transitionProps","useThemeSystem","_setPrototypeOf","_inheritsLoose","subClass","superClass","setPrototypeOf","timeoutsShape","TransitionGroupContext","forceReflow","UNMOUNTED","EXITED","ENTERING","ENTERED","EXITING","Transition","_React$Component","_this","parentGroup","appear","initialStatus","prevState","nextIn","_proto","prevProps","nextStatus","exit","enter","mounting","_this2","appearing","maybeNode","maybeAppearing","timeouts","enterTimeout","_this3","nextState","callback","_this4","active","handler","doesNotHaveTimeoutOrListener","maybeNextCallback","_this$props","pt","noop","Transition$1","reflow","getTransitionProps","_style$transitionDura","_style$transitionTimi","getScale","isWebKit154","Grow","addEndListener","inProp","onEnter","onEntered","onEntering","onExit","onExited","onExiting","TransitionComponent","timer","autoTimeout","nodeRef","normalizedTransitionCallback","maybeIsAppearing","handleEntering","isAppearing","transitionDuration","transitionTimingFunction","handleEntered","handleExiting","handleExit","handleAddEndListener","Grow$1","PopperRoot","BasePopper","components","componentsProps","RootComponent","Popper$1","getTooltipUtilityClass","tooltipClasses","tooltipClasses$1","disableInteractive","touch","TooltipPopper","TooltipTooltip","TooltipArrow","hystersisOpen","hystersisTimer","cursorPosition","composeEventHandler","eventHandler","_slots$popper","_slots$transition","_slots$tooltip","_slots$arrow","_slotProps$popper","_ref6","_slotProps$popper2","_slotProps$transition","_slotProps$tooltip","_ref7","_slotProps$tooltip2","_slotProps$arrow","_ref8","_slotProps$arrow2","childrenProp","describeChild","disableFocusListener","disableHoverListener","disableInteractiveProp","disableTouchListener","enterDelay","enterNextDelay","enterTouchDelay","followCursor","idProp","leaveDelay","leaveTouchDelay","onClose","onOpen","PopperComponentProp","PopperProps","title","TransitionComponentProp","isRtl","childNode","setChildNode","arrowRef","setArrowRef","ignoreNonTouchEvents","closeTimer","enterTimer","leaveTimer","touchTimer","setOpenState","prevUserSelect","stopTouchInteraction","handleOpen","handleClose","handleLeave","focusVisibleRef","setChildIsFocusVisible","handleBlur","handleFocus","detectTouchStart","childrenProps","handleMouseOver","handleMouseLeave","handleTouchStart","handleTouchEnd","nativeEvent","handleMouseMove","nameOrDescProps","titleIsString","interactiveWrapperListeners","_PopperProps$popperOp","tooltipModifiers","PopperComponent","TooltipComponent","ArrowComponent","popperProps","tooltipProps","tooltipArrowProps","TransitionPropsInner","Tooltip$1","getIcon","icon","menuLabel","leading","MuiListItemIcon","MenuItem","allowForLeadingIcons","iconPathBefore","iconPathAfter","hasAutoFocus","isDense","isSubMenuParent","hasDisabledGutters","hasDivider","focusVisibleClassName","menuItem","MuiMenuItem","MuiListItemText","getAllGroups","menuDefinition","SubMenu","setAnchorEl","parentMenuItem","parentItemProps","handleParentMenuItemClick","renderSubMenuItems","includedGroups","group","GroupedMenuItemList","Menu","getOrderedGroupItems","groupId","allItems","menuProps","commandHandler","groupsToInclude","sortedGroups","itemArray","allowSpaceForLeadingIcons","createMenuItemProps","isLastItemInGroup","divKey","itemInfo","menuItemProps","TopLevelMenu","columnId","MenuColumn","metadata","Grid","List","GridMenu","multiColumnMenu","sortedColumns","columnNumbers","columnName","col","getUsePromiseOptionsDefaults","usePromise","promiseFactoryCallback","defaultValueRef","optionsDefaultedRef","setIsLoading","promiseIsCurrent","MenuIcon","HamburgerMenuButton","menuProvider","normalMenu","fullMenu","containerRef","ariaLabelPrefix","isMenuOpen","setMenuOpen","showFullMenu","setShowFullMenu","handleMenuItemClick","handleMenuButtonClick","prevIsOpen","isOpening","menuCommandHandler","command","setOffset","normalMenuData","fullMenuData","menu","IconButton","Drawer","isTooltipSuppressed","adjustMarginToAlignToEdge","MuiIconButton","Spinner","LoaderCircle","TextField","hasError","helperText","onFocus","onBlur","ShadLabel","Toolbar","AppBar","MuiToolbar","alertVariants","Alert","AlertTitle","AlertDescription","Card","CardHeader","CardTitle","CardDescription","CardContent","CardFooter","Sonner","Toaster","Slider","SliderPrimitive","Switch","SwitchPrimitives","Tabs","TabsList","TabsTrigger","TabsContent","InstallButton","isInstalling","handleClick","buttonText","Download","EnableButton","isEnabling","DisableButton","isDisabling","UpdateButton","isUpdating","MarkdownRenderer","markdown","anchorTarget","Markdown","FilterButton","Filter","DropdownMenuItemType","DropdownMenuItemType2","FilterDropdown","groups","NoExtensionsFound","MoreInfo","category","downloads","languages","moreInfoUrl","numberFormatted","NumberFormat","handleScrollToBottom","User","locale","LucideLink","CircleHelp","VersionHistory","versionHistory","showAllVersions","setShowAllVersions","currentDate","formatTimeString","dateString","date","dateDiff","yearDiff","monthDiff","dayDiff","timeString","sortedEntries","Footer","publisherDisplayName","fileSize","locales","formattedFileSize","formatBytes","languageNames","codes","displayNames","useEvent","unsubscriber","noopUnsubscriber","useEventAsync","unsubscribe","unsub"],"mappings":"28CAGA,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AEA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MAEA,MAEA,MAEA,MAEA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,MAEA,MAEA,MAEA,MAEA,MACA,MACA,MACA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,KACF,EAAGC,GAAI,CACL,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,KACF,EAAGC,GAAI,CACL,UACA,SACA,YACA,UACA,cACA,SACA,SACA,OACA,WACA,WACA,UACA,UACA,eACA,eACA,OACA,WACA,kBACA,MACA,SACA,WACA,eACA,gBACA,SACA,WACA,eACA,UACA,kBACA,QACA,OACA,OACA,UACA,QACA,QACA,QACA,WACA,YACA,SACA,YACA,UACA,UACA,OACA,OACA,OACA,OACA,SACA,gBACA,gBACA,YACA,YACA,cACA,aACA,kBACA,kBACA,YACA,YACA,QACA,WACA,UACA,QACA,UACA,UACA,SACA,SACA,SACA,OACA,aACA,QACA,SACA,eACA,oBACA,0BACA,SACA,qBACA,sBACA,UACA,qBACA,cACA,cACA,cACA,cACA,mBACA,mBACA,qBACA,YACA,OACA,oBAGA,uBACA,uBACA,sBACA,yBACA,wBACA,qBACA,UACA,UACA,UACA,UACA,UACA,UACA,UACA,eACA,cACA,eACA,oBACA,qBACA,0BACA,0BACA,eACA,eACA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Z,EACD,WAAY,CACV,SAAU,UACV,UAAWA,EACZ,EACD,YAAa,CACX,SAAU,SACX,EACD,eAAgB,CACd,SAAU,SACX,EACD,iBAAkB,CAChB,SAAU,SACX,EACD,kBAAmB,CACjB,SAAU,SACX,EACD,gBAAiB,CACf,SAAU,SACX,EACD,QAAS,CACP,SAAU,UACV,UAAWA,EACZ,EACD,aAAc,CACZ,SAAU,SACX,EACD,aAAc,CACZ,SAAU,qBACV,MAAOc,EACR,EAED,MAAO,CACL,SAAU,UACV,UAAWa,EACZ,EACD,QAAS,CACP,SAAU,UACV,YAAa,kBACb,UAAWA,EACZ,EACD,gBAAiB,CACf,SAAU,UACV,UAAWA,EACZ,EAED,EAAG,CACD,MAAOpC,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,QAAS,CACP,MAAOA,EACR,EACD,WAAY,CACV,MAAOA,EACR,EACD,aAAc,CACZ,MAAOA,EACR,EACD,cAAe,CACb,MAAOA,EACR,EACD,YAAa,CACX,MAAOA,EACR,EACD,SAAU,CACR,MAAOA,EACR,EACD,SAAU,CACR,MAAOA,EACR,EACD,cAAe,CACb,MAAOA,EACR,EACD,mBAAoB,CAClB,MAAOA,EACR,EACD,iBAAkB,CAChB,MAAOA,EACR,EACD,aAAc,CACZ,MAAOA,EACR,EACD,kBAAmB,CACjB,MAAOA,EACR,EACD,gBAAiB,CACf,MAAOA,EACR,EACD,EAAG,CACD,MAAOD,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,OAAQ,CACN,MAAOA,EACR,EACD,UAAW,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;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","x_google_ignoreList":[3,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,83,84,85,86,87,88,89,90,91,92,93,94,95,96,97,98,99,100,101,102,103,104,105,106,107,108,109,110,111,112,113,114,115,116,117,118,119,120,121,122,123,124,125,126,127,128,129,130,131,132,133,134,135,136,137,138,139,140,141,142,143,144,145,146,147,148,149,150,151,152,153,154,155,156,157,158,159,160,161,162,163,164,165,166,167,168,169,170,171,172,173,174,175,176,177,178,179,180,181,182,183,184,185,186,187,188,189,190,191,192,193,194,195,196,197,198,199,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,228]} \ No newline at end of file diff --git a/lib/platform-bible-react/dist/index.d.ts b/lib/platform-bible-react/dist/index.d.ts index 039501145d..b041f6653d 100644 --- a/lib/platform-bible-react/dist/index.d.ts +++ b/lib/platform-bible-react/dist/index.d.ts @@ -652,15 +652,6 @@ export type SettingsListHeaderProps = { * @returns Formatted div with list header content */ export declare function SettingsListHeader({ primary, secondary, includeSeparator, }: SettingsListHeaderProps): import("react/jsx-runtime").JSX.Element; -export type SettingsCardProps = React$1.PropsWithChildren & { - /** Optional id for testing */ - id?: string; - /** Label of the settings group */ - settingsGroupLabel: string; - /** Optional description of the settings group */ - settingsGroupDescription?: string; -}; -export function SettingsCard({ id, settingsGroupLabel, settingsGroupDescription, children, }: SettingsCardProps): import("react/jsx-runtime").JSX.Element; export type ChecklistProps = { /** Optional string representing the id attribute of the Checklist */ id?: string; diff --git a/lib/platform-bible-react/dist/index.js b/lib/platform-bible-react/dist/index.js index 37bfa8aa66..8edfed1139 100644 --- a/lib/platform-bible-react/dist/index.js +++ b/lib/platform-bible-react/dist/index.js @@ -1,12 +1,12 @@ -import el, { jsx as s, jsxs as x, Fragment as ie } from "react/jsx-runtime"; +import Ks, { jsx as s, jsxs as N, Fragment as ie } from "react/jsx-runtime"; import * as M from "react"; import T, { forwardRef as Qn, useCallback as Et, useState as ut, useRef as ge, useEffect as ae, useLayoutEffect as ta, useMemo as It } from "react"; -import { History as nl, ChevronRight as Ja, Check as tr, Circle as Za, ArrowDownWideNarrow as rl, Clock as ol, Bookmark as al, X as Qa, Search as il, ChevronsUpDown as sl, FilterIcon as ll, ChevronDown as er, ChevronUp as cl, ArrowLeftIcon as dl, ChevronLeftIcon as pl, ChevronRightIcon as ul, ArrowRightIcon as wl, CircleCheckIcon as fl, CircleXIcon as ml, CircleHelpIcon as hl, ArrowUpIcon as gl, ArrowDownIcon as bl, ArrowUpDownIcon as vl, PanelLeft as yl, ChevronLeft as xl, LoaderCircle as Nl, Download as kl, Filter as El, User as Sl, Link as Tl, CircleHelp as Cl } from "lucide-react"; -import be, { clsx as Ol } from "clsx"; -import { extendTailwindMerge as Rl } from "tailwind-merge"; +import { History as Js, ChevronRight as Ja, Check as tr, Circle as Za, ArrowDownWideNarrow as Zs, Clock as Qs, Bookmark as tl, X as Qa, Search as el, ChevronsUpDown as nl, FilterIcon as rl, ChevronDown as er, ChevronUp as ol, ArrowLeftIcon as al, ChevronLeftIcon as il, ChevronRightIcon as sl, ArrowRightIcon as ll, CircleCheckIcon as cl, CircleXIcon as dl, CircleHelpIcon as pl, ArrowUpIcon as ul, ArrowDownIcon as wl, ArrowUpDownIcon as fl, PanelLeft as ml, ChevronLeft as hl, LoaderCircle as gl, Download as bl, Filter as vl, User as yl, Link as xl, CircleHelp as Nl } from "lucide-react"; +import be, { clsx as kl } from "clsx"; +import { extendTailwindMerge as El } from "tailwind-merge"; import * as wt from "@radix-ui/react-dropdown-menu"; -import { DropdownMenuTrigger as _l } from "@radix-ui/react-dropdown-menu"; -import { getChaptersForBook as Pl, deepEqual as co, substring as $l, formatScrRef as Or, compareScrRefs as Hr, scrRefToBBBCCCVVV as Rr, getLocalizeKeyForScrollGroupId as pt, NumberFormat as Il, formatBytes as Al } from "platform-bible-utils"; +import { DropdownMenuTrigger as Sl } from "@radix-ui/react-dropdown-menu"; +import { getChaptersForBook as Tl, deepEqual as co, substring as Cl, formatScrRef as Or, compareScrRefs as Hr, scrRefToBBBCCCVVV as Rr, getLocalizeKeyForScrollGroupId as pt, NumberFormat as Ol, formatBytes as Rl } from "platform-bible-utils"; import { Slot as He } from "@radix-ui/react-slot"; import { cva as Xe } from "class-variance-authority"; import * as ti from "@radix-ui/react-label"; @@ -14,7 +14,7 @@ import * as mn from "@radix-ui/react-radio-group"; import * as hn from "@radix-ui/react-popover"; import { Command as Rt } from "cmdk"; import * as vt from "@radix-ui/react-dialog"; -import { useReactTable as ei, getCoreRowModel as ni, getPaginationRowModel as Ml, getSortedRowModel as ri, getFilteredRowModel as Dl, flexRender as dn, getExpandedRowModel as Bl, getGroupedRowModel as jl } from "@tanstack/react-table"; +import { useReactTable as ei, getCoreRowModel as ni, getPaginationRowModel as _l, getSortedRowModel as ri, getFilteredRowModel as Pl, flexRender as dn, getExpandedRowModel as $l, getGroupedRowModel as Il } from "@tanstack/react-table"; import * as bt from "@radix-ui/react-select"; import * as Xr from "@radix-ui/react-checkbox"; import * as nr from "@radix-ui/react-toggle-group"; @@ -22,25 +22,25 @@ import * as oi from "@radix-ui/react-toggle"; import * as _t from "@radix-ui/react-tabs"; import * as ai from "@radix-ui/react-separator"; import * as En from "@radix-ui/react-tooltip"; -import Vl, { ThemeContext as zl, internal_processStyles as Ll } from "@mui/styled-engine"; -import { MenuItem as Fl, ListItemText as Ul, ListItemIcon as ii, Menu as Gl, Grid as si, List as Hl, IconButton as li, Drawer as Xl, AppBar as Yl, Toolbar as Wl } from "@mui/material"; -import * as ql from "react-dom"; +import Al, { ThemeContext as Ml, internal_processStyles as Dl } from "@mui/styled-engine"; +import { MenuItem as Bl, ListItemText as jl, ListItemIcon as ii, Menu as Vl, Grid as si, List as zl, IconButton as li, Drawer as Ll, AppBar as Fl, Toolbar as Ul } from "@mui/material"; +import * as Gl from "react-dom"; import Bn from "react-dom"; -import { Toaster as Kl } from "sonner"; -import { toast as Zh } from "sonner"; +import { Toaster as Hl } from "sonner"; +import { toast as Jh } from "sonner"; import * as an from "@radix-ui/react-slider"; import * as Yr from "@radix-ui/react-switch"; -import Jl from "markdown-to-jsx"; -const Zl = Rl({ prefix: "tw-" }); -function N(...t) { - return Zl(Ol(t)); +import Xl from "markdown-to-jsx"; +const Yl = El({ prefix: "tw-" }); +function x(...t) { + return Yl(kl(t)); } const Ye = T.forwardRef( ({ className: t, type: e, ...n }, r) => /* @__PURE__ */ s( "input", { type: e, - className: N( + className: x( "pr-twp tw-flex tw-h-10 tw-rounded-md tw-border tw-border-input tw-bg-background tw-px-3 tw-py-2 tw-text-sm tw-ring-offset-background file:tw-border-0 file:tw-bg-transparent file:tw-text-sm file:tw-font-medium file:tw-text-foreground placeholder:tw-text-muted-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-cursor-not-allowed disabled:tw-opacity-50", t ), @@ -50,8 +50,8 @@ const Ye = T.forwardRef( ) ); Ye.displayName = "Input"; -const Ql = Qn( - ({ handleSearch: t, handleKeyDown: e, handleOnClick: n, handleSubmit: r, ...o }, a) => /* @__PURE__ */ x("div", { className: "tw-relative", children: [ +const Wl = Qn( + ({ handleSearch: t, handleKeyDown: e, handleOnClick: n, handleSubmit: r, ...o }, a) => /* @__PURE__ */ N("div", { className: "tw-relative", children: [ /* @__PURE__ */ s( Ye, { @@ -67,7 +67,7 @@ const Ql = Qn( } ), /* @__PURE__ */ s( - nl, + Js, { className: "tw-absolute tw-right-3 tw-top-1/2 tw-h-4 tw-w-4 tw--translate-y-1/2 tw-transform tw-cursor-pointer tw-text-muted-foreground", onClick: () => { @@ -77,7 +77,7 @@ const Ql = Qn( ) ] }) ); -var tc = Object.defineProperty, ec = (t, e, n) => e in t ? tc(t, e, { enumerable: !0, configurable: !0, writable: !0, value: n }) : t[e] = n, et = (t, e, n) => ec(t, typeof e != "symbol" ? e + "" : e, n); +var ql = Object.defineProperty, Kl = (t, e, n) => e in t ? ql(t, e, { enumerable: !0, configurable: !0, writable: !0, value: n }) : t[e] = n, et = (t, e, n) => Kl(t, typeof e != "symbol" ? e + "" : e, n); const ye = [ "GEN", "EXO", @@ -365,33 +365,33 @@ const ye = [ "Reproof (Proverbs 25-31)", "4 Baruch (Rest of Baruch)", "Laodiceans" -], ea = pc(); +], ea = ic(); function We(t, e = !0) { return e && (t = t.toUpperCase()), t in ea ? ea[t] : 0; } function uo(t) { return We(t) > 0; } -function nc(t) { +function Jl(t) { const e = typeof t == "string" ? We(t) : t; return e >= 40 && e <= 66; } -function rc(t) { +function Zl(t) { return (typeof t == "string" ? We(t) : t) <= 39; } function di(t) { return t <= 66; } -function oc(t) { +function Ql(t) { const e = typeof t == "string" ? We(t) : t; return wi(e) && !di(e); } -function* ac() { +function* tc() { for (let t = 1; t <= ye.length; t++) yield t; } -const ic = 1, pi = ye.length; -function sc() { +const ec = 1, pi = ye.length; +function nc() { return ["XXA", "XXB", "XXC", "XXD", "XXE", "XXF", "XXG"]; } function wo(t, e = "***") { @@ -401,21 +401,21 @@ function wo(t, e = "***") { function ui(t) { return t <= 0 || t > pi ? "******" : ci[t - 1]; } -function lc(t) { +function rc(t) { return ui(We(t)); } function wi(t) { const e = typeof t == "number" ? wo(t) : t; return uo(e) && !po.includes(e); } -function cc(t) { +function oc(t) { const e = typeof t == "number" ? wo(t) : t; return uo(e) && po.includes(e); } -function dc(t) { +function ac(t) { return ci[t - 1].includes("*obsolete*"); } -function pc() { +function ic() { const t = {}; for (let e = 0; e < ye.length; e++) t[ye[e]] = e + 1; @@ -426,20 +426,20 @@ const ot = { nonCanonicalIds: po, bookIdToNumber: We, isBookIdValid: uo, - isBookNT: nc, - isBookOT: rc, + isBookNT: Jl, + isBookOT: Zl, isBookOTNT: di, - isBookDC: oc, - allBookNumbers: ac, - firstBook: ic, + isBookDC: Ql, + allBookNumbers: tc, + firstBook: ec, lastBook: pi, - extraBooks: sc, + extraBooks: nc, bookNumberToId: wo, bookNumberToEnglishName: ui, - bookIdToEnglishName: lc, + bookIdToEnglishName: rc, isCanonical: wi, - isExtraMaterial: cc, - isObsolete: dc + isExtraMaterial: oc, + isObsolete: ac }; var Ht = /* @__PURE__ */ ((t) => (t[t.Unknown = 0] = "Unknown", t[t.Original = 1] = "Original", t[t.Septuagint = 2] = "Septuagint", t[t.Vulgate = 3] = "Vulgate", t[t.English = 4] = "English", t[t.RussianProtestant = 5] = "RussianProtestant", t[t.RussianOrthodox = 6] = "RussianOrthodox", t))(Ht || {}); const $t = class { @@ -832,11 +832,11 @@ et(Tt, "defaultVersification", ue.English), et(Tt, "verseRangeSeparator", "-"), et(Tt, "ValidStatusType", fi); class tn extends Error { } -const fo = wt.Root, mi = wt.Trigger, uc = wt.Group, fh = wt.Portal, mh = wt.Sub, hh = wt.RadioGroup, wc = T.forwardRef(({ className: t, inset: e, children: n, ...r }, o) => /* @__PURE__ */ x( +const fo = wt.Root, mi = wt.Trigger, sc = wt.Group, fh = wt.Portal, mh = wt.Sub, hh = wt.RadioGroup, lc = T.forwardRef(({ className: t, inset: e, children: n, ...r }, o) => /* @__PURE__ */ N( wt.SubTrigger, { ref: o, - className: N( + className: x( "tw-flex tw-cursor-default tw-select-none tw-items-center tw-rounded-sm tw-px-2 tw-py-1.5 tw-text-sm tw-outline-none focus:tw-bg-accent data-[state=open]:tw-bg-accent", e && "tw-pl-8", t @@ -848,25 +848,25 @@ const fo = wt.Root, mi = wt.Trigger, uc = wt.Group, fh = wt.Portal, mh = wt.Sub, ] } )); -wc.displayName = wt.SubTrigger.displayName; -const fc = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( +lc.displayName = wt.SubTrigger.displayName; +const cc = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( wt.SubContent, { ref: n, - className: N( + className: x( "tw-z-50 tw-min-w-[8rem] tw-overflow-hidden tw-rounded-md tw-border tw-bg-popover tw-p-1 tw-text-popover-foreground tw-shadow-lg data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0 data-[state=closed]:tw-zoom-out-95 data-[state=open]:tw-zoom-in-95 data-[side=bottom]:tw-slide-in-from-top-2 data-[side=left]:tw-slide-in-from-right-2 data-[side=right]:tw-slide-in-from-left-2 data-[side=top]:tw-slide-in-from-bottom-2", t ), ...e } )); -fc.displayName = wt.SubContent.displayName; +cc.displayName = wt.SubContent.displayName; const rr = T.forwardRef(({ className: t, sideOffset: e = 4, ...n }, r) => /* @__PURE__ */ s(wt.Portal, { children: /* @__PURE__ */ s( wt.Content, { ref: r, sideOffset: e, - className: N( + className: x( /* adding pr-twp because the dropdown content is added to the dom as a sibling to the app root */ "pr-twp tw-z-50 tw-min-w-[8rem] tw-overflow-hidden tw-rounded-md tw-border tw-bg-popover tw-p-1 tw-text-popover-foreground tw-shadow-md data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0 data-[state=closed]:tw-zoom-out-95 data-[state=open]:tw-zoom-in-95 data-[side=bottom]:tw-slide-in-from-top-2 data-[side=left]:tw-slide-in-from-right-2 data-[side=right]:tw-slide-in-from-left-2 data-[side=top]:tw-slide-in-from-bottom-2", t @@ -879,7 +879,7 @@ const hi = T.forwardRef(({ className: t, inset: e, ...n }, r) => /* @__PURE__ */ wt.Item, { ref: r, - className: N( + className: x( // removed: tw-relative tw-flex focus:tw-text-accent-foreground "tw-cursor-default tw-select-none tw-items-center tw-rounded-sm tw-px-2 tw-py-1.5 tw-text-sm tw-outline-none tw-transition-colors focus:tw-bg-accent data-[disabled]:tw-pointer-events-none data-[disabled]:tw-opacity-50", e && "tw-pl-8", @@ -889,11 +889,11 @@ const hi = T.forwardRef(({ className: t, inset: e, ...n }, r) => /* @__PURE__ */ } )); hi.displayName = wt.Item.displayName; -const mo = T.forwardRef(({ className: t, children: e, checked: n, ...r }, o) => /* @__PURE__ */ x( +const mo = T.forwardRef(({ className: t, children: e, checked: n, ...r }, o) => /* @__PURE__ */ N( wt.CheckboxItem, { ref: o, - className: N( + className: x( "tw-relative tw-flex tw-cursor-default tw-select-none tw-items-center tw-rounded-sm tw-py-1.5 tw-pl-8 tw-pr-2 tw-text-sm tw-outline-none tw-transition-colors focus:tw-bg-accent focus:tw-text-accent-foreground data-[disabled]:tw-pointer-events-none data-[disabled]:tw-opacity-50", t ), @@ -906,11 +906,11 @@ const mo = T.forwardRef(({ className: t, children: e, checked: n, ...r }, o) => } )); mo.displayName = wt.CheckboxItem.displayName; -const gi = T.forwardRef(({ className: t, children: e, ...n }, r) => /* @__PURE__ */ x( +const gi = T.forwardRef(({ className: t, children: e, ...n }, r) => /* @__PURE__ */ N( wt.RadioItem, { ref: r, - className: N( + className: x( "tw-relative tw-flex tw-cursor-default tw-select-none tw-items-center tw-rounded-sm tw-py-1.5 tw-pl-8 tw-pr-2 tw-text-sm tw-outline-none tw-transition-colors focus:tw-bg-accent focus:tw-text-accent-foreground data-[disabled]:tw-pointer-events-none data-[disabled]:tw-opacity-50", t ), @@ -926,7 +926,7 @@ const Sn = T.forwardRef(({ className: t, inset: e, ...n }, r) => /* @__PURE__ */ wt.Label, { ref: r, - className: N("tw-px-2 tw-py-1.5 tw-text-sm tw-font-semibold", e && "tw-pl-8", t), + className: x("tw-px-2 tw-py-1.5 tw-text-sm tw-font-semibold", e && "tw-pl-8", t), ...n } )); @@ -935,22 +935,22 @@ const or = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( wt.Separator, { ref: n, - className: N("tw--mx-1 tw-my-1 tw-h-px tw-bg-muted", t), + className: x("tw--mx-1 tw-my-1 tw-h-px tw-bg-muted", t), ...e } )); or.displayName = wt.Separator.displayName; -function mc({ className: t, ...e }) { +function dc({ className: t, ...e }) { return /* @__PURE__ */ s( "span", { - className: N("tw-ml-auto tw-text-xs tw-tracking-widest tw-opacity-60", t), + className: x("tw-ml-auto tw-text-xs tw-tracking-widest tw-opacity-60", t), ...e } ); } -mc.displayName = "DropdownMenuShortcut"; -const hc = Qn( +dc.displayName = "DropdownMenuShortcut"; +const pc = Qn( ({ bookId: t, handleSelectBook: e, @@ -959,12 +959,12 @@ const hc = Qn( handleKeyDown: o, bookType: a, children: i - }, l) => /* @__PURE__ */ x( + }, l) => /* @__PURE__ */ N( hi, { ref: l, textValue: t, - className: N("tw-mx-1 tw-px-1 tw-font-normal tw-text-foreground/80", { + className: x("tw-mx-1 tw-px-1 tw-font-normal tw-text-foreground/80", { // Overriding `data-[highlighted]` changes the default gray background that is normally shown on hover "tw-bg-amber-50 tw-text-yellow-900 data-[highlighted]:tw-bg-amber-100": n }), @@ -980,7 +980,7 @@ const hc = Qn( /* @__PURE__ */ s( "span", { - className: N( + className: x( "tw-border-b-0 tw-border-l-2 tw-border-r-0 tw-border-t-0 tw-border-solid tw-px-2", { "tw-font-bold": n, @@ -998,7 +998,7 @@ const hc = Qn( t ) ); -function gc({ +function uc({ handleSelectChapter: t, endChapter: e, activeChapter: n, @@ -1011,10 +1011,10 @@ function gc({ }, [o] ); - return /* @__PURE__ */ s("div", { className: N("tw-flex tw-flex-wrap tw-items-start tw-justify-start tw-self-stretch"), children: a.map((l) => /* @__PURE__ */ s( + return /* @__PURE__ */ s("div", { className: x("tw-flex tw-flex-wrap tw-items-start tw-justify-start tw-self-stretch"), children: a.map((l) => /* @__PURE__ */ s( "div", { - className: N( + className: x( "tw-box-content tw-flex tw-h-4 tw-w-4 tw-cursor-pointer tw-items-center tw-justify-end tw-rounded-md tw-p-2 tw-text-amber-800", { "tw-font-semibold tw-text-amber-900": l === n, @@ -1035,26 +1035,26 @@ function gc({ l )) }); } -function bc({ handleSort: t, handleLocationHistory: e, handleBookmarks: n }) { - return /* @__PURE__ */ x(Sn, { className: "tw-flex tw-justify-between", children: [ +function wc({ handleSort: t, handleLocationHistory: e, handleBookmarks: n }) { + return /* @__PURE__ */ N(Sn, { className: "tw-flex tw-justify-between", children: [ /* @__PURE__ */ s("p", { className: "tw-inline-block tw-align-middle", children: "Go To" }), - /* @__PURE__ */ x("div", { className: "tw-flex tw-items-center", children: [ + /* @__PURE__ */ N("div", { className: "tw-flex tw-items-center", children: [ /* @__PURE__ */ s( - rl, + Zs, { onClick: t, className: "tw-m-2 tw-h-4 tw-w-4 tw-cursor-pointer tw-gap-2" } ), /* @__PURE__ */ s( - ol, + Qs, { onClick: e, className: "tw-m-2 tw-h-4 tw-w-4 tw-cursor-pointer tw-gap-2" } ), /* @__PURE__ */ s( - al, + tl, { onClick: n, className: "tw-m-2 tw-h-4 tw-w-4 tw-cursor-pointer tw-gap-2" @@ -1063,31 +1063,31 @@ function bc({ handleSort: t, handleLocationHistory: e, handleBookmarks: n }) { ] }) ] }); } -const pn = ot.allBookIds, vc = { +const pn = ot.allBookIds, fc = { OT: "Old Testament", NT: "New Testament", DC: "Deuterocanon" -}, ra = ["OT", "NT", "DC"], yc = 32 + 32 + 32, xc = [ +}, ra = ["OT", "NT", "DC"], mc = 32 + 32 + 32, hc = [ /^(\w+)$/i, // Matches a single word (book name or id) /^(\w+)(?:\s(\d+))$/i, // Matches a word followed by a chapter number /^(\w+)(?:\s(\d+):(\d+))$/i // Matches a word followed by a chapter and verse number -], Nc = (t) => ({ +], gc = (t) => ({ OT: pn.filter((n) => ot.isBookOT(n)), NT: pn.filter((n) => ot.isBookNT(n)), DC: pn.filter((n) => ot.isBookDC(n)) -})[t], en = (t) => Pl(ot.bookIdToNumber(t)); -function kc() { +})[t], en = (t) => Tl(ot.bookIdToNumber(t)); +function bc() { return pn.map((e) => ot.bookIdToEnglishName(e)); } -function Ec(t) { - return kc().includes(t); +function vc(t) { + return bc().includes(t); } -function Sc(t) { +function yc(t) { const e = t.toLowerCase().replace(/^\w/, (n) => n.toUpperCase()); - if (Ec(e)) + if (vc(e)) return pn.find((r) => ot.bookIdToEnglishName(r) === e); } function gh({ scrRef: t, handleSubmit: e }) { @@ -1096,7 +1096,7 @@ function gh({ scrRef: t, handleSubmit: e }) { ), [i, l] = ut(t.chapterNum ?? 0), [c, d] = ut( ot.bookNumberToId(t.bookNum) ), [p, h] = ut(!1), [w, g] = ut(p), v = ge(void 0), f = ge(void 0), m = ge(void 0), E = Et( - (k) => Nc(k).filter((B) => { + (k) => gc(k).filter((B) => { const D = ot.bookIdToEnglishName(B).toLowerCase(), J = n.replace(/[^a-zA-Z]/g, "").toLowerCase(); return D.includes(J) || // Match book name B.toLowerCase().includes(J); @@ -1128,10 +1128,10 @@ function gh({ scrRef: t, handleSubmit: e }) { ), I = (k) => { k <= 0 || k > en(o) || b(o, !0, k); }, z = Et(() => { - xc.forEach((k) => { + hc.forEach((k) => { const B = n.match(k); if (B) { - const [D, J = void 0, q = void 0] = B.slice(1), U = Sc(D); + const [D, J = void 0, q = void 0] = B.slice(1), U = yc(D); (ot.isBookIdValid(D) || U) && b( U ?? D, !0, @@ -1186,16 +1186,16 @@ function gh({ scrRef: t, handleSubmit: e }) { }, [p]), ta(() => { const k = setTimeout(() => { if (w && f.current && m.current) { - const D = m.current.offsetTop - yc; + const D = m.current.offsetTop - mc; f.current.scrollTo({ top: D, behavior: "instant" }); } }, 10); return () => { clearTimeout(k); }; - }, [w]), /* @__PURE__ */ s("div", { className: "pr-twp tw-flex", children: /* @__PURE__ */ x(fo, { modal: !1, open: p, onOpenChange: S, children: [ + }, [w]), /* @__PURE__ */ s("div", { className: "pr-twp tw-flex", children: /* @__PURE__ */ N(fo, { modal: !1, open: p, onOpenChange: S, children: [ /* @__PURE__ */ s(mi, { asChild: !0, children: /* @__PURE__ */ s( - Ql, + Wl, { ref: v, value: n, @@ -1211,7 +1211,7 @@ function gh({ scrRef: t, handleSubmit: e }) { placeholder: `${ot.bookNumberToEnglishName(t.bookNum)} ${t.chapterNum}:${t.verseNum}` } ) }), - /* @__PURE__ */ x( + /* @__PURE__ */ N( rr, { className: "tw-m-1 tw-overflow-y-auto tw-p-0 tw-font-normal tw-text-foreground/80", @@ -1221,7 +1221,7 @@ function gh({ scrRef: t, handleSubmit: e }) { ref: f, children: [ /* @__PURE__ */ s( - bc, + wc, { handleSort: () => console.log("sorting"), handleLocationHistory: () => console.log("location history"), @@ -1229,10 +1229,10 @@ function gh({ scrRef: t, handleSubmit: e }) { } ), ra.map( - (k, B) => E(k).length > 0 && /* @__PURE__ */ x("div", { children: [ - /* @__PURE__ */ s(Sn, { className: "tw-font-semibold tw-text-foreground/80", children: vc[k] }), + (k, B) => E(k).length > 0 && /* @__PURE__ */ N("div", { children: [ + /* @__PURE__ */ s(Sn, { className: "tw-font-semibold tw-text-foreground/80", children: fc[k] }), E(k).map((D) => /* @__PURE__ */ s("div", { children: /* @__PURE__ */ s( - hc, + pc, { bookId: D, handleSelectBook: () => b(D, !1), @@ -1244,7 +1244,7 @@ function gh({ scrRef: t, handleSubmit: e }) { o === D && (m.current = J); }, children: /* @__PURE__ */ s( - gc, + uc, { handleSelectChapter: I, endChapter: en(D), @@ -1265,7 +1265,7 @@ function gh({ scrRef: t, handleSubmit: e }) { ) ] }) }); } -const Tc = Xe( +const xc = Xe( "pr-twp tw-inline-flex tw-items-center tw-justify-center tw-whitespace-nowrap tw-rounded-md tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-colors focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50", { variants: { @@ -1290,17 +1290,17 @@ const Tc = Xe( } } ), gt = T.forwardRef( - ({ className: t, variant: e, size: n, asChild: r = !1, ...o }, a) => /* @__PURE__ */ s(r ? He : "button", { className: N(Tc({ variant: e, size: n, className: t })), ref: a, ...o }) + ({ className: t, variant: e, size: n, asChild: r = !1, ...o }, a) => /* @__PURE__ */ s(r ? He : "button", { className: x(xc({ variant: e, size: n, className: t })), ref: a, ...o }) ); gt.displayName = "Button"; -const Cc = Xe( +const Nc = Xe( "tw-text-sm tw-font-medium tw-leading-none peer-disabled:tw-cursor-not-allowed peer-disabled:tw-opacity-70" -), Xt = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s(ti.Root, { ref: n, className: N("pr-twp", Cc(), t), ...e })); +), Xt = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s(ti.Root, { ref: n, className: x("pr-twp", Nc(), t), ...e })); Xt.displayName = ti.Root.displayName; const bi = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( mn.Root, { - className: N("pr-twp tw-grid tw-gap-2", t), + className: x("pr-twp tw-grid tw-gap-2", t), ...e, ref: n } @@ -1310,7 +1310,7 @@ const Wr = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( mn.Item, { ref: n, - className: N( + className: x( "pr-twp tw-aspect-square tw-h-4 tw-w-4 tw-rounded-full tw-border tw-border-primary tw-text-primary tw-ring-offset-background focus:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-cursor-not-allowed disabled:tw-opacity-50", t ), @@ -1319,13 +1319,13 @@ const Wr = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( } )); Wr.displayName = mn.Item.displayName; -const Oc = hn.Root, Rc = hn.Trigger, vi = T.forwardRef(({ className: t, align: e = "center", sideOffset: n = 4, ...r }, o) => /* @__PURE__ */ s(hn.Portal, { children: /* @__PURE__ */ s( +const kc = hn.Root, Ec = hn.Trigger, vi = T.forwardRef(({ className: t, align: e = "center", sideOffset: n = 4, ...r }, o) => /* @__PURE__ */ s(hn.Portal, { children: /* @__PURE__ */ s( hn.Content, { ref: o, align: e, sideOffset: n, - className: N( + className: x( "pr-twp tw-z-50 tw-w-72 tw-rounded-md tw-border tw-bg-popover tw-p-4 tw-text-popover-foreground tw-shadow-md tw-outline-none data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0 data-[state=closed]:tw-zoom-out-95 data-[state=open]:tw-zoom-in-95 data-[side=bottom]:tw-slide-in-from-top-2 data-[side=left]:tw-slide-in-from-right-2 data-[side=right]:tw-slide-in-from-left-2 data-[side=top]:tw-slide-in-from-bottom-2", t ), @@ -1333,11 +1333,11 @@ const Oc = hn.Root, Rc = hn.Trigger, vi = T.forwardRef(({ className: t, align: e } ) })); vi.displayName = hn.Content.displayName; -const _c = vt.Portal, yi = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( +const Sc = vt.Portal, yi = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( vt.Overlay, { ref: n, - className: N( + className: x( "tw-fixed tw-inset-0 tw-z-50 tw-bg-black/80 data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0", t ), @@ -1345,20 +1345,20 @@ const _c = vt.Portal, yi = T.forwardRef(({ className: t, ...e }, n) => /* @__PUR } )); yi.displayName = vt.Overlay.displayName; -const Pc = T.forwardRef(({ className: t, children: e, ...n }, r) => /* @__PURE__ */ x(_c, { children: [ +const Tc = T.forwardRef(({ className: t, children: e, ...n }, r) => /* @__PURE__ */ N(Sc, { children: [ /* @__PURE__ */ s(yi, {}), - /* @__PURE__ */ x( + /* @__PURE__ */ N( vt.Content, { ref: r, - className: N( + className: x( "tw-fixed tw-left-[50%] tw-top-[50%] tw-z-50 tw-grid tw-w-full tw-max-w-lg tw-translate-x-[-50%] tw-translate-y-[-50%] tw-gap-4 tw-border tw-bg-background tw-p-6 tw-shadow-lg tw-duration-200 data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0 data-[state=closed]:tw-zoom-out-95 data-[state=open]:tw-zoom-in-95 data-[state=closed]:tw-slide-out-to-left-1/2 data-[state=closed]:tw-slide-out-to-top-[48%] data-[state=open]:tw-slide-in-from-left-1/2 data-[state=open]:tw-slide-in-from-top-[48%] sm:tw-rounded-lg", t ), ...n, children: [ e, - /* @__PURE__ */ x(vt.Close, { className: "tw-absolute tw-right-4 tw-top-4 tw-rounded-sm tw-opacity-70 tw-ring-offset-background tw-transition-opacity hover:tw-opacity-100 focus:tw-outline-none focus:tw-ring-2 focus:tw-ring-ring focus:tw-ring-offset-2 disabled:tw-pointer-events-none data-[state=open]:tw-bg-accent data-[state=open]:tw-text-muted-foreground", children: [ + /* @__PURE__ */ N(vt.Close, { className: "tw-absolute tw-right-4 tw-top-4 tw-rounded-sm tw-opacity-70 tw-ring-offset-background tw-transition-opacity hover:tw-opacity-100 focus:tw-outline-none focus:tw-ring-2 focus:tw-ring-ring focus:tw-ring-offset-2 disabled:tw-pointer-events-none data-[state=open]:tw-bg-accent data-[state=open]:tw-text-muted-foreground", children: [ /* @__PURE__ */ s(Qa, { className: "tw-h-4 tw-w-4" }), /* @__PURE__ */ s("span", { className: "tw-sr-only", children: "Close" }) ] }) @@ -1366,30 +1366,30 @@ const Pc = T.forwardRef(({ className: t, children: e, ...n }, r) => /* @__PURE__ } ) ] })); -Pc.displayName = vt.Content.displayName; -const $c = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( +Tc.displayName = vt.Content.displayName; +const Cc = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( vt.Title, { ref: n, - className: N("tw-text-lg tw-font-semibold tw-leading-none tw-tracking-tight", t), + className: x("tw-text-lg tw-font-semibold tw-leading-none tw-tracking-tight", t), ...e } )); -$c.displayName = vt.Title.displayName; -const Ic = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( +Cc.displayName = vt.Title.displayName; +const Oc = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( vt.Description, { ref: n, - className: N("tw-text-sm tw-text-muted-foreground", t), + className: x("tw-text-sm tw-text-muted-foreground", t), ...e } )); -Ic.displayName = vt.Description.displayName; +Oc.displayName = vt.Description.displayName; const xi = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( Rt, { ref: n, - className: N( + className: x( "tw-flex tw-h-full tw-w-full tw-flex-col tw-overflow-hidden tw-rounded-md tw-bg-popover tw-text-popover-foreground", t ), @@ -1397,13 +1397,13 @@ const xi = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( } )); xi.displayName = Rt.displayName; -const Ni = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ x("div", { className: "tw-flex tw-items-center tw-border-b tw-px-3", children: [ - /* @__PURE__ */ s(il, { className: "tw-me-2 tw-h-4 tw-w-4 tw-shrink-0 tw-opacity-50" }), +const Ni = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ N("div", { className: "tw-flex tw-items-center tw-border-b tw-px-3", children: [ + /* @__PURE__ */ s(el, { className: "tw-me-2 tw-h-4 tw-w-4 tw-shrink-0 tw-opacity-50" }), /* @__PURE__ */ s( Rt.Input, { ref: n, - className: N( + className: x( "tw-flex tw-h-11 tw-w-full tw-rounded-md tw-bg-transparent tw-py-3 tw-text-sm tw-outline-none placeholder:tw-text-muted-foreground disabled:tw-cursor-not-allowed disabled:tw-opacity-50", t ), @@ -1416,39 +1416,39 @@ const ki = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( Rt.List, { ref: n, - className: N("tw-max-h-[300px] tw-overflow-y-auto tw-overflow-x-hidden", t), + className: x("tw-max-h-[300px] tw-overflow-y-auto tw-overflow-x-hidden", t), ...e } )); ki.displayName = Rt.List.displayName; const Ei = T.forwardRef((t, e) => /* @__PURE__ */ s(Rt.Empty, { ref: e, className: "tw-py-6 tw-text-center tw-text-sm", ...t })); Ei.displayName = Rt.Empty.displayName; -const Ac = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( +const Rc = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( Rt.Group, { ref: n, - className: N( + className: x( "tw-overflow-hidden tw-p-1 tw-text-foreground [&_[cmdk-group-heading]]:tw-px-2 [&_[cmdk-group-heading]]:tw-py-1.5 [&_[cmdk-group-heading]]:tw-text-xs [&_[cmdk-group-heading]]:tw-font-medium [&_[cmdk-group-heading]]:tw-text-muted-foreground", t ), ...e } )); -Ac.displayName = Rt.Group.displayName; -const Mc = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( +Rc.displayName = Rt.Group.displayName; +const _c = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( Rt.Separator, { ref: n, - className: N("tw--mx-1 tw-h-px tw-bg-border", t), + className: x("tw--mx-1 tw-h-px tw-bg-border", t), ...e } )); -Mc.displayName = Rt.Separator.displayName; +_c.displayName = Rt.Separator.displayName; const Si = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( Rt.Item, { ref: n, - className: N( + className: x( "tw-relative tw-flex tw-cursor-default tw-select-none tw-items-center tw-rounded-sm tw-px-2 tw-py-1.5 tw-text-sm tw-outline-none data-[disabled=true]:tw-pointer-events-none data-[selected=true]:tw-bg-accent data-[selected=true]:tw-text-accent-foreground data-[disabled=true]:tw-opacity-50", t ), @@ -1456,7 +1456,7 @@ const Si = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( } )); Si.displayName = Rt.Item.displayName; -function Dc(t) { +function Pc(t) { return typeof t == "string" ? t : typeof t == "number" ? t.toString() : t.label; } function qr({ @@ -1467,7 +1467,7 @@ function qr({ value: o, onChange: a = () => { }, - getOptionLabel: i = Dc, + getOptionLabel: i = Pc, buttonPlaceholder: l = "", textPlaceholder: c = "", commandEmptyMessage: d = "No option found", @@ -1477,26 +1477,26 @@ function qr({ ...g }) { const [v, f] = ut(!1); - return /* @__PURE__ */ x(Oc, { open: v, onOpenChange: f, ...g, children: [ - /* @__PURE__ */ s(Rc, { asChild: !0, children: /* @__PURE__ */ x( + return /* @__PURE__ */ N(kc, { open: v, onOpenChange: f, ...g, children: [ + /* @__PURE__ */ s(Ec, { asChild: !0, children: /* @__PURE__ */ N( gt, { variant: p, role: "combobox", "aria-expanded": v, id: t, - className: N("tw-w-[200px] tw-justify-between", n), + className: x("tw-w-[200px] tw-justify-between", n), disabled: w, children: [ /* @__PURE__ */ s("span", { className: "tw-overflow-hidden tw-text-ellipsis tw-whitespace-nowrap", children: o ? i(o) : l }), - /* @__PURE__ */ s(sl, { className: "tw-ms-2 tw-h-4 tw-w-4 tw-shrink-0 tw-opacity-50" }) + /* @__PURE__ */ s(nl, { className: "tw-ms-2 tw-h-4 tw-w-4 tw-shrink-0 tw-opacity-50" }) ] } ) }), - /* @__PURE__ */ s(vi, { className: N("tw-w-[200px] tw-p-0", r), dir: h, children: /* @__PURE__ */ x(xi, { children: [ + /* @__PURE__ */ s(vi, { className: x("tw-w-[200px] tw-p-0", r), dir: h, children: /* @__PURE__ */ N(xi, { children: [ /* @__PURE__ */ s(Ni, { dir: h, placeholder: c, className: "tw-text-inherit" }), /* @__PURE__ */ s(Ei, { children: d }), - /* @__PURE__ */ s(ki, { children: e.map((m) => /* @__PURE__ */ x( + /* @__PURE__ */ s(ki, { children: e.map((m) => /* @__PURE__ */ N( Si, { value: i(m), @@ -1507,7 +1507,7 @@ function qr({ /* @__PURE__ */ s( tr, { - className: N("tw-me-2 tw-h-4 tw-w-4", { + className: x("tw-me-2 tw-h-4 tw-w-4", { "tw-opacity-0": !o || i(o) !== i(m) }) } @@ -1520,7 +1520,7 @@ function qr({ ] }) }) ] }); } -function Bc({ +function $c({ startChapter: t, endChapter: e, handleSelectStartChapter: n, @@ -1532,7 +1532,7 @@ function Bc({ () => Array.from({ length: a }, (d, p) => p + 1), [a] ); - return /* @__PURE__ */ x(ie, { children: [ + return /* @__PURE__ */ N(ie, { children: [ /* @__PURE__ */ s(Xt, { htmlFor: "start-chapters-combobox", children: "Chapters" }), /* @__PURE__ */ s( qr, @@ -1565,7 +1565,7 @@ function Bc({ ) ] }); } -var jc = /* @__PURE__ */ ((t) => (t.CURRENT_BOOK = "current book", t.CHOOSE_BOOKS = "choose books", t))(jc || {}); +var Ic = /* @__PURE__ */ ((t) => (t.CURRENT_BOOK = "current book", t.CHOOSE_BOOKS = "choose books", t))(Ic || {}); const bh = Object.freeze([ "%webView_bookSelector_currentBook%", "%webView_bookSelector_choose%", @@ -1595,9 +1595,9 @@ function vh({ className: "pr-twp tw-flex", value: g, onValueChange: (m) => f(m), - children: /* @__PURE__ */ x("div", { className: "tw-flex tw-w-full tw-flex-col tw-gap-4", children: [ - /* @__PURE__ */ x("div", { className: "tw-grid tw-grid-cols-[25%,25%,50%]", children: [ - /* @__PURE__ */ x("div", { className: "tw-flex tw-items-center", children: [ + children: /* @__PURE__ */ N("div", { className: "tw-flex tw-w-full tw-flex-col tw-gap-4", children: [ + /* @__PURE__ */ N("div", { className: "tw-grid tw-grid-cols-[25%,25%,50%]", children: [ + /* @__PURE__ */ N("div", { className: "tw-flex tw-items-center", children: [ /* @__PURE__ */ s(Wr, { value: "current book" /* CURRENT_BOOK */ @@ -1606,7 +1606,7 @@ function vh({ ] }), /* @__PURE__ */ s(Xt, { className: "tw-flex tw-items-center", children: e }), /* @__PURE__ */ s("div", { className: "tw-flex tw-items-center tw-justify-end", children: /* @__PURE__ */ s( - Bc, + $c, { isDisabled: g === "choose books", handleSelectStartChapter: c, @@ -1617,8 +1617,8 @@ function vh({ } ) }) ] }), - /* @__PURE__ */ x("div", { className: "tw-grid tw-grid-cols-[25%,50%,25%]", children: [ - /* @__PURE__ */ x("div", { className: "tw-flex tw-items-center", children: [ + /* @__PURE__ */ N("div", { className: "tw-grid tw-grid-cols-[25%,50%,25%]", children: [ + /* @__PURE__ */ N("div", { className: "tw-flex tw-items-center", children: [ /* @__PURE__ */ s(Wr, { value: "choose books" /* CHOOSE_BOOKS */ @@ -1639,13 +1639,13 @@ function vh({ } ); } -function Vc({ table: t }) { - return /* @__PURE__ */ x(fo, { children: [ - /* @__PURE__ */ s(_l, { asChild: !0, children: /* @__PURE__ */ x(gt, { variant: "outline", size: "sm", className: "tw-ml-auto tw-hidden tw-h-8 lg:tw-flex", children: [ - /* @__PURE__ */ s(ll, { className: "tw-mr-2 tw-h-4 tw-w-4" }), +function Ac({ table: t }) { + return /* @__PURE__ */ N(fo, { children: [ + /* @__PURE__ */ s(Sl, { asChild: !0, children: /* @__PURE__ */ N(gt, { variant: "outline", size: "sm", className: "tw-ml-auto tw-hidden tw-h-8 lg:tw-flex", children: [ + /* @__PURE__ */ s(rl, { className: "tw-mr-2 tw-h-4 tw-w-4" }), "View" ] }) }), - /* @__PURE__ */ x(rr, { align: "end", className: "tw-w-[150px]", children: [ + /* @__PURE__ */ N(rr, { align: "end", className: "tw-w-[150px]", children: [ /* @__PURE__ */ s(Sn, { children: "Toggle columns" }), /* @__PURE__ */ s(or, {}), t.getAllColumns().filter((e) => e.getCanHide()).map((e) => /* @__PURE__ */ s( @@ -1661,11 +1661,11 @@ function Vc({ table: t }) { ] }) ] }); } -const gn = bt.Root, zc = bt.Group, bn = bt.Value, De = T.forwardRef(({ className: t, children: e, ...n }, r) => /* @__PURE__ */ x( +const gn = bt.Root, Mc = bt.Group, bn = bt.Value, De = T.forwardRef(({ className: t, children: e, ...n }, r) => /* @__PURE__ */ N( bt.Trigger, { ref: r, - className: N( + className: x( "tw-flex tw-h-10 tw-w-full tw-items-center tw-justify-between tw-rounded-md tw-border tw-border-input tw-bg-background tw-px-3 tw-py-2 tw-text-sm tw-ring-offset-background placeholder:tw-text-muted-foreground focus:tw-outline-none focus:tw-ring-2 focus:tw-ring-ring focus:tw-ring-offset-2 disabled:tw-cursor-not-allowed disabled:tw-opacity-50 [&>span]:tw-line-clamp-1", t ), @@ -1681,9 +1681,9 @@ const Ti = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( bt.ScrollUpButton, { ref: n, - className: N("tw-flex tw-cursor-default tw-items-center tw-justify-center tw-py-1", t), + className: x("tw-flex tw-cursor-default tw-items-center tw-justify-center tw-py-1", t), ...e, - children: /* @__PURE__ */ s(cl, { className: "tw-h-4 tw-w-4" }) + children: /* @__PURE__ */ s(ol, { className: "tw-h-4 tw-w-4" }) } )); Ti.displayName = bt.ScrollUpButton.displayName; @@ -1691,17 +1691,17 @@ const Ci = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( bt.ScrollDownButton, { ref: n, - className: N("tw-flex tw-cursor-default tw-items-center tw-justify-center tw-py-1", t), + className: x("tw-flex tw-cursor-default tw-items-center tw-justify-center tw-py-1", t), ...e, children: /* @__PURE__ */ s(er, { className: "tw-h-4 tw-w-4" }) } )); Ci.displayName = bt.ScrollDownButton.displayName; -const Be = T.forwardRef(({ className: t, children: e, position: n = "popper", ...r }, o) => /* @__PURE__ */ s(bt.Portal, { children: /* @__PURE__ */ x( +const Be = T.forwardRef(({ className: t, children: e, position: n = "popper", ...r }, o) => /* @__PURE__ */ s(bt.Portal, { children: /* @__PURE__ */ N( bt.Content, { ref: o, - className: N( + className: x( "pr-twp tw-relative tw-z-50 tw-max-h-96 tw-min-w-[8rem] tw-overflow-hidden tw-rounded-md tw-border tw-bg-popover tw-text-popover-foreground tw-shadow-md data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0 data-[state=closed]:tw-zoom-out-95 data-[state=open]:tw-zoom-in-95 data-[side=bottom]:tw-slide-in-from-top-2 data-[side=left]:tw-slide-in-from-right-2 data-[side=right]:tw-slide-in-from-left-2 data-[side=top]:tw-slide-in-from-bottom-2", n === "popper" && "data-[side=bottom]:tw-translate-y-1 data-[side=left]:tw--translate-x-1 data-[side=right]:tw-translate-x-1 data-[side=top]:tw--translate-y-1", t @@ -1713,7 +1713,7 @@ const Be = T.forwardRef(({ className: t, children: e, position: n = "popper", .. /* @__PURE__ */ s( bt.Viewport, { - className: N( + className: x( "tw-p-1", n === "popper" && "tw-h-[var(--radix-select-trigger-height)] tw-w-full tw-min-w-[var(--radix-select-trigger-width)]" ), @@ -1725,20 +1725,20 @@ const Be = T.forwardRef(({ className: t, children: e, position: n = "popper", .. } ) })); Be.displayName = bt.Content.displayName; -const Lc = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( +const Dc = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( bt.Label, { ref: n, - className: N("tw-py-1.5 tw-pl-8 tw-pr-2 tw-text-sm tw-font-semibold", t), + className: x("tw-py-1.5 tw-pl-8 tw-pr-2 tw-text-sm tw-font-semibold", t), ...e } )); -Lc.displayName = bt.Label.displayName; -const Gt = T.forwardRef(({ className: t, children: e, ...n }, r) => /* @__PURE__ */ x( +Dc.displayName = bt.Label.displayName; +const Gt = T.forwardRef(({ className: t, children: e, ...n }, r) => /* @__PURE__ */ N( bt.Item, { ref: r, - className: N( + className: x( "tw-relative tw-flex tw-w-full tw-cursor-default tw-select-none tw-items-center tw-rounded-sm tw-py-1.5 tw-pl-8 tw-pr-2 tw-text-sm tw-outline-none focus:tw-bg-accent focus:tw-text-accent-foreground data-[disabled]:tw-pointer-events-none data-[disabled]:tw-opacity-50", t ), @@ -1750,27 +1750,27 @@ const Gt = T.forwardRef(({ className: t, children: e, ...n }, r) => /* @__PURE__ } )); Gt.displayName = bt.Item.displayName; -const Fc = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( +const Bc = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( bt.Separator, { ref: n, - className: N("tw--mx-1 tw-my-1 tw-h-px tw-bg-muted", t), + className: x("tw--mx-1 tw-my-1 tw-h-px tw-bg-muted", t), ...e } )); -Fc.displayName = bt.Separator.displayName; -function Uc({ table: t }) { - return /* @__PURE__ */ s("div", { className: "tw-flex tw-items-center tw-justify-between tw-px-2 tw-pb-3 tw-pt-3", children: /* @__PURE__ */ x("div", { className: "tw-flex tw-items-center tw-space-x-6 lg:tw-space-x-8", children: [ - /* @__PURE__ */ x("div", { className: "tw-flex-1 tw-text-sm tw-text-muted-foreground", children: [ +Bc.displayName = bt.Separator.displayName; +function jc({ table: t }) { + return /* @__PURE__ */ s("div", { className: "tw-flex tw-items-center tw-justify-between tw-px-2 tw-pb-3 tw-pt-3", children: /* @__PURE__ */ N("div", { className: "tw-flex tw-items-center tw-space-x-6 lg:tw-space-x-8", children: [ + /* @__PURE__ */ N("div", { className: "tw-flex-1 tw-text-sm tw-text-muted-foreground", children: [ t.getFilteredSelectedRowModel().rows.length, " of", " ", t.getFilteredRowModel().rows.length, " row(s) selected" ] }), - /* @__PURE__ */ x("div", { className: "tw-flex tw-items-center tw-space-x-2", children: [ + /* @__PURE__ */ N("div", { className: "tw-flex tw-items-center tw-space-x-2", children: [ /* @__PURE__ */ s("p", { className: "tw-text-nowrap tw-text-sm tw-font-medium", children: "Rows per page" }), - /* @__PURE__ */ x( + /* @__PURE__ */ N( gn, { value: `${t.getState().pagination.pageSize}`, @@ -1784,14 +1784,14 @@ function Uc({ table: t }) { } ) ] }), - /* @__PURE__ */ x("div", { className: "tw-flex tw-w-[100px] tw-items-center tw-justify-center tw-text-sm tw-font-medium", children: [ + /* @__PURE__ */ N("div", { className: "tw-flex tw-w-[100px] tw-items-center tw-justify-center tw-text-sm tw-font-medium", children: [ "Page ", t.getState().pagination.pageIndex + 1, " of ", t.getPageCount() ] }), - /* @__PURE__ */ x("div", { className: "tw-flex tw-items-center tw-space-x-2", children: [ - /* @__PURE__ */ x( + /* @__PURE__ */ N("div", { className: "tw-flex tw-items-center tw-space-x-2", children: [ + /* @__PURE__ */ N( gt, { variant: "outline", @@ -1801,11 +1801,11 @@ function Uc({ table: t }) { disabled: !t.getCanPreviousPage(), children: [ /* @__PURE__ */ s("span", { className: "tw-sr-only", children: "Go to first page" }), - /* @__PURE__ */ s(dl, { className: "tw-h-4 tw-w-4" }) + /* @__PURE__ */ s(al, { className: "tw-h-4 tw-w-4" }) ] } ), - /* @__PURE__ */ x( + /* @__PURE__ */ N( gt, { variant: "outline", @@ -1815,11 +1815,11 @@ function Uc({ table: t }) { disabled: !t.getCanPreviousPage(), children: [ /* @__PURE__ */ s("span", { className: "tw-sr-only", children: "Go to previous page" }), - /* @__PURE__ */ s(pl, { className: "tw-h-4 tw-w-4" }) + /* @__PURE__ */ s(il, { className: "tw-h-4 tw-w-4" }) ] } ), - /* @__PURE__ */ x( + /* @__PURE__ */ N( gt, { variant: "outline", @@ -1829,11 +1829,11 @@ function Uc({ table: t }) { disabled: !t.getCanNextPage(), children: [ /* @__PURE__ */ s("span", { className: "tw-sr-only", children: "Go to next page" }), - /* @__PURE__ */ s(ul, { className: "tw-h-4 tw-w-4" }) + /* @__PURE__ */ s(sl, { className: "tw-h-4 tw-w-4" }) ] } ), - /* @__PURE__ */ x( + /* @__PURE__ */ N( gt, { variant: "outline", @@ -1843,18 +1843,18 @@ function Uc({ table: t }) { disabled: !t.getCanNextPage(), children: [ /* @__PURE__ */ s("span", { className: "tw-sr-only", children: "Go to last page" }), - /* @__PURE__ */ s(wl, { className: "tw-h-4 tw-w-4" }) + /* @__PURE__ */ s(ll, { className: "tw-h-4 tw-w-4" }) ] } ) ] }) ] }) }); } -const ar = T.forwardRef(({ className: t, stickyHeader: e, ...n }, r) => /* @__PURE__ */ s("div", { className: N("pr-twp tw-relative tw-w-full", { "tw-overflow-auto": !e }), children: /* @__PURE__ */ s( +const ar = T.forwardRef(({ className: t, stickyHeader: e, ...n }, r) => /* @__PURE__ */ s("div", { className: x("pr-twp tw-relative tw-w-full", { "tw-overflow-auto": !e }), children: /* @__PURE__ */ s( "table", { ref: r, - className: N("tw-w-full tw-caption-bottom tw-text-sm", t), + className: x("tw-w-full tw-caption-bottom tw-text-sm", t), ...n } ) })); @@ -1863,7 +1863,7 @@ const ir = T.forwardRef(({ className: t, stickyHeader: e, ...n }, r) => /* @__PU "thead", { ref: r, - className: N( + className: x( { "tw-sticky tw-top-[-1px] tw-bg-background tw-drop-shadow-sm": e }, "[&_tr]:tw-border-b", t @@ -1872,23 +1872,23 @@ const ir = T.forwardRef(({ className: t, stickyHeader: e, ...n }, r) => /* @__PU } )); ir.displayName = "TableHeader"; -const sr = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s("tbody", { ref: n, className: N("[&_tr:last-child]:tw-border-0", t), ...e })); +const sr = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s("tbody", { ref: n, className: x("[&_tr:last-child]:tw-border-0", t), ...e })); sr.displayName = "TableBody"; -const Gc = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( +const Vc = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( "tfoot", { ref: n, - className: N("tw-border-t tw-bg-muted/50 tw-font-medium [&>tr]:last:tw-border-b-0", t), + className: x("tw-border-t tw-bg-muted/50 tw-font-medium [&>tr]:last:tw-border-b-0", t), ...e } )); -Gc.displayName = "TableFooter"; +Vc.displayName = "TableFooter"; const oe = T.forwardRef( ({ className: t, ...e }, n) => /* @__PURE__ */ s( "tr", { ref: n, - className: N( + className: x( "tw-border-b tw-transition-colors hover:tw-bg-muted/50 data-[state=selected]:tw-bg-muted", t ), @@ -1901,7 +1901,7 @@ const vn = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( "th", { ref: n, - className: N( + className: x( "tw-h-12 tw-px-4 tw-text-start tw-align-middle tw-font-medium tw-text-muted-foreground [&:has([role=checkbox])]:tw-pe-0", t ), @@ -1913,21 +1913,21 @@ const je = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( "td", { ref: n, - className: N("tw-p-4 tw-align-middle [&:has([role=checkbox])]:tw-pe-0", t), + className: x("tw-p-4 tw-align-middle [&:has([role=checkbox])]:tw-pe-0", t), ...e } )); je.displayName = "TableCell"; -const Hc = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( +const zc = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( "caption", { ref: n, - className: N("tw-mt-4 tw-text-sm tw-text-muted-foreground", t), + className: x("tw-mt-4 tw-text-sm tw-text-muted-foreground", t), ...e } )); -Hc.displayName = "TableCaption"; -function Xc({ +zc.displayName = "TableCaption"; +function Lc({ columns: t, data: e, enablePagination: n = !1, @@ -1942,11 +1942,11 @@ function Xc({ data: e, columns: t, getCoreRowModel: ni(), - ...n && { getPaginationRowModel: Ml() }, + ...n && { getPaginationRowModel: _l() }, onSortingChange: c, getSortedRowModel: ri(), onColumnFiltersChange: p, - getFilteredRowModel: Dl(), + getFilteredRowModel: Pl(), onColumnVisibilityChange: w, onRowSelectionChange: v, state: { @@ -1956,9 +1956,9 @@ function Xc({ rowSelection: g } }); - return /* @__PURE__ */ x("div", { className: "pr-twp", children: [ - o && /* @__PURE__ */ s(Vc, { table: f }), - /* @__PURE__ */ x(ar, { stickyHeader: a, children: [ + return /* @__PURE__ */ N("div", { className: "pr-twp", children: [ + o && /* @__PURE__ */ s(Ac, { table: f }), + /* @__PURE__ */ N(ar, { stickyHeader: a, children: [ /* @__PURE__ */ s(ir, { stickyHeader: a, children: f.getHeaderGroups().map((E) => /* @__PURE__ */ s(oe, { children: E.headers.map((_) => /* @__PURE__ */ s(vn, { children: _.isPlaceholder ? void 0 : dn(_.column.columnDef.header, _.getContext()) }, _.id)) }, E.id)) }), /* @__PURE__ */ s(sr, { children: (m = f.getRowModel().rows) != null && m.length ? f.getRowModel().rows.map((E) => /* @__PURE__ */ s( oe, @@ -1970,7 +1970,7 @@ function Xc({ E.id )) : /* @__PURE__ */ s(oe, { children: /* @__PURE__ */ s(je, { colSpan: t.length, className: "tw-h-24 tw-text-center", children: "No results." }) }) }) ] }), - n && /* @__PURE__ */ x("div", { className: "tw-flex tw-items-center tw-justify-end tw-space-x-2 tw-py-4", children: [ + n && /* @__PURE__ */ N("div", { className: "tw-flex tw-items-center tw-justify-end tw-space-x-2 tw-py-4", children: [ /* @__PURE__ */ s( gt, { @@ -1992,10 +1992,10 @@ function Xc({ } ) ] }), - n && r && /* @__PURE__ */ s(Uc, { table: f }) + n && r && /* @__PURE__ */ s(jc, { table: f }) ] }); } -function Yc({ +function Fc({ occurrenceData: t, setScriptureReference: e, localizedStrings: n @@ -2006,12 +2006,12 @@ function Yc({ i.some((c) => co(c, l)) || i.push(l); }), i; }, [t]); - return /* @__PURE__ */ x(ar, { stickyHeader: !0, children: [ - /* @__PURE__ */ s(ir, { stickyHeader: !0, children: /* @__PURE__ */ x(oe, { children: [ + return /* @__PURE__ */ N(ar, { stickyHeader: !0, children: [ + /* @__PURE__ */ s(ir, { stickyHeader: !0, children: /* @__PURE__ */ N(oe, { children: [ /* @__PURE__ */ s(vn, { children: r }), /* @__PURE__ */ s(vn, { children: o }) ] }) }), - /* @__PURE__ */ s(sr, { children: a.length > 0 && a.map((i) => /* @__PURE__ */ x( + /* @__PURE__ */ s(sr, { children: a.length > 0 && a.map((i) => /* @__PURE__ */ N( oe, { onClick: () => { @@ -2030,7 +2030,7 @@ const ho = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( Xr.Root, { ref: n, - className: N( + className: x( "tw-peer pr-twp tw-h-4 tw-w-4 tw-shrink-0 tw-rounded-sm tw-border tw-border-primary tw-ring-offset-background focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-cursor-not-allowed disabled:tw-opacity-50 data-[state=checked]:tw-bg-primary data-[state=checked]:tw-text-primary-foreground", t ), @@ -2038,21 +2038,21 @@ const ho = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( children: /* @__PURE__ */ s( Xr.Indicator, { - className: N("tw-flex tw-items-center tw-justify-center tw-text-current"), + className: x("tw-flex tw-items-center tw-justify-center tw-text-current"), children: /* @__PURE__ */ s(tr, { className: "tw-h-4 tw-w-4" }) } ) } )); ho.displayName = Xr.Root.displayName; -const Wc = (t) => t.split(/(?:\r?\n|\r)|(?=(?:\\(?:v|c|id)))/g), oa = (t) => { +const Uc = (t) => t.split(/(?:\r?\n|\r)|(?=(?:\\(?:v|c|id)))/g), oa = (t) => { const e = /^\\[vc]\s+(\d+)/, n = t.match(e); if (n) return +n[1]; -}, qc = (t) => { +}, Gc = (t) => { const e = t.match(/^\\id\s+([A-Za-z]+)/); return e ? ot.bookIdToNumber(e[1]) : 0; -}, Kc = (t, e, n) => n.includes(t) ? "unapproved" : e.includes(t) ? "approved" : "unknown", Oi = Xe( +}, Hc = (t, e, n) => n.includes(t) ? "unapproved" : e.includes(t) ? "approved" : "unknown", Oi = Xe( "pr-twp tw-inline-flex tw-items-center tw-justify-center tw-rounded-md tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-colors hover:tw-bg-muted hover:tw-text-muted-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50 data-[state=on]:tw-bg-accent data-[state=on]:tw-text-accent-foreground", { variants: { @@ -2071,15 +2071,15 @@ const Wc = (t) => t.split(/(?:\r?\n|\r)|(?=(?:\\(?:v|c|id)))/g), oa = (t) => { size: "default" } } -), Jc = T.forwardRef(({ className: t, variant: e, size: n, ...r }, o) => /* @__PURE__ */ s( +), Xc = T.forwardRef(({ className: t, variant: e, size: n, ...r }, o) => /* @__PURE__ */ s( oi.Root, { ref: o, - className: N(Oi({ variant: e, size: n, className: t })), + className: x(Oi({ variant: e, size: n, className: t })), ...r } )); -Jc.displayName = oi.Root.displayName; +Xc.displayName = oi.Root.displayName; const Ri = T.createContext({ size: "default", variant: "default" @@ -2087,7 +2087,7 @@ const Ri = T.createContext({ nr.Root, { ref: a, - className: N("pr-twp tw-flex tw-items-center tw-justify-center tw-gap-1", t), + className: x("pr-twp tw-flex tw-items-center tw-justify-center tw-gap-1", t), ...o, children: /* @__PURE__ */ s( Ri.Provider, @@ -2105,7 +2105,7 @@ const Un = T.forwardRef(({ className: t, children: e, variant: n, size: r, ...o nr.Item, { ref: a, - className: N( + className: x( Oi({ variant: i.variant || n, size: i.size || r @@ -2118,23 +2118,23 @@ const Un = T.forwardRef(({ className: t, children: e, variant: n, size: r, ...o ); }); Un.displayName = nr.Item.displayName; -const lr = (t) => t === "asc" ? /* @__PURE__ */ s(gl, { className: "tw-ms-2 tw-h-4 tw-w-4" }) : t === "desc" ? /* @__PURE__ */ s(bl, { className: "tw-ms-2 tw-h-4 tw-w-4" }) : /* @__PURE__ */ s(vl, { className: "tw-ms-2 tw-h-4 tw-w-4" }), yh = (t) => ({ +const lr = (t) => t === "asc" ? /* @__PURE__ */ s(ul, { className: "tw-ms-2 tw-h-4 tw-w-4" }) : t === "desc" ? /* @__PURE__ */ s(wl, { className: "tw-ms-2 tw-h-4 tw-w-4" }) : /* @__PURE__ */ s(fl, { className: "tw-ms-2 tw-h-4 tw-w-4" }), yh = (t) => ({ accessorKey: "item", accessorFn: (e) => e.items[0], - header: ({ column: e }) => /* @__PURE__ */ x(gt, { variant: "ghost", onClick: () => e.toggleSorting(void 0), children: [ + header: ({ column: e }) => /* @__PURE__ */ N(gt, { variant: "ghost", onClick: () => e.toggleSorting(void 0), children: [ t, lr(e.getIsSorted()) ] }) -}), Zc = (t, e) => ({ +}), Yc = (t, e) => ({ accessorKey: `item${e}`, accessorFn: (n) => n.items[e], - header: ({ column: n }) => /* @__PURE__ */ x(gt, { variant: "ghost", onClick: () => n.toggleSorting(void 0), children: [ + header: ({ column: n }) => /* @__PURE__ */ N(gt, { variant: "ghost", onClick: () => n.toggleSorting(void 0), children: [ t, lr(n.getIsSorted()) ] }) }), xh = (t) => ({ accessorKey: "count", - header: ({ column: e }) => /* @__PURE__ */ s("div", { className: "tw-flex tw-justify-end tw-tabular-nums", children: /* @__PURE__ */ x(gt, { variant: "ghost", onClick: () => e.toggleSorting(void 0), children: [ + header: ({ column: e }) => /* @__PURE__ */ s("div", { className: "tw-flex tw-justify-end tw-tabular-nums", children: /* @__PURE__ */ N(gt, { variant: "ghost", onClick: () => e.toggleSorting(void 0), children: [ t, lr(e.getIsSorted()) ] }) }), @@ -2150,13 +2150,13 @@ const lr = (t) => t === "asc" ? /* @__PURE__ */ s(gl, { className: "tw-ms-2 tw-h }), a(l); }, Nh = (t, e, n, r, o) => ({ accessorKey: "status", - header: ({ column: a }) => /* @__PURE__ */ s("div", { className: "tw-flex tw-justify-center", children: /* @__PURE__ */ x(gt, { variant: "ghost", onClick: () => a.toggleSorting(void 0), children: [ + header: ({ column: a }) => /* @__PURE__ */ s("div", { className: "tw-flex tw-justify-center", children: /* @__PURE__ */ N(gt, { variant: "ghost", onClick: () => a.toggleSorting(void 0), children: [ t, lr(a.getIsSorted()) ] }) }), cell: ({ row: a }) => { const i = a.getValue("status"), l = a.getValue("item"); - return /* @__PURE__ */ x(_i, { value: i, variant: "outline", type: "single", children: [ + return /* @__PURE__ */ N(_i, { value: i, variant: "outline", type: "single", children: [ /* @__PURE__ */ s( Un, { @@ -2169,7 +2169,7 @@ const lr = (t) => t === "asc" ? /* @__PURE__ */ s(gl, { className: "tw-ms-2 tw-h o ), value: "approved", - children: /* @__PURE__ */ s(fl, {}) + children: /* @__PURE__ */ s(cl, {}) } ), /* @__PURE__ */ s( @@ -2184,7 +2184,7 @@ const lr = (t) => t === "asc" ? /* @__PURE__ */ s(gl, { className: "tw-ms-2 tw-h o ), value: "unapproved", - children: /* @__PURE__ */ s(ml, {}) + children: /* @__PURE__ */ s(dl, {}) } ), /* @__PURE__ */ s( @@ -2199,7 +2199,7 @@ const lr = (t) => t === "asc" ? /* @__PURE__ */ s(gl, { className: "tw-ms-2 tw-h o ), value: "unknown", - children: /* @__PURE__ */ s(hl, {}) + children: /* @__PURE__ */ s(pl, {}) } ) ] }); @@ -2216,18 +2216,18 @@ const lr = (t) => t === "asc" ? /* @__PURE__ */ s(gl, { className: "tw-ms-2 tw-h "%webView_inventory_show_additional_items%", "%webView_inventory_occurrences_table_header_reference%", "%webView_inventory_occurrences_table_header_occurrence%" -]), Qc = (t, e, n) => { +]), Wc = (t, e, n) => { let r = t; return e !== "all" && (r = r.filter( (o) => e === "approved" && o.status === "approved" || e === "unapproved" && o.status === "unapproved" || e === "unknown" && o.status === "unknown" )), n !== "" && (r = r.filter((o) => o.items[0].includes(n))), r; -}, td = (t, e, n, r, o) => { +}, qc = (t, e, n, r, o) => { if (!t) return []; const a = []; let i = e.bookNum, l = e.chapterNum, c = e.verseNum; - return Wc(t).forEach((p) => { - p.startsWith("\\id") && (i = qc(p), l = 0, c = 0), p.startsWith("\\c") && (l = oa(p), c = 0), p.startsWith("\\v") && (c = oa(p), l === 0 && (l = e.chapterNum)); + return Uc(t).forEach((p) => { + p.startsWith("\\id") && (i = Gc(p), l = 0, c = 0), p.startsWith("\\c") && (l = oa(p), c = 0), p.startsWith("\\v") && (c = oa(p), l === 0 && (l = e.chapterNum)); let h = o.exec(p) ?? void 0; for (; h; ) { const w = []; @@ -2238,7 +2238,7 @@ const lr = (t) => t === "asc" ? /* @__PURE__ */ s(gl, { className: "tw-ms-2 tw-h chapterNum: l !== void 0 ? l : -1, verseNum: c !== void 0 ? c : -1 }, - text: $l(p, Math.max(0, g - 25), Math.min(g + 25, p.length)) + text: Cl(p, Math.max(0, g - 25), Math.min(g + 25, p.length)) }; if (v) v.count += 1, v.occurrences.push(f); @@ -2246,7 +2246,7 @@ const lr = (t) => t === "asc" ? /* @__PURE__ */ s(gl, { className: "tw-ms-2 tw-h const m = { items: w, count: 1, - status: Kc(w[0], n, r), + status: Hc(w[0], n, r), occurrences: [f] }; a.push(m); @@ -2271,7 +2271,7 @@ function Eh({ const h = Jt(n, "%webView_inventory_all%"), w = Jt(n, "%webView_inventory_approved%"), g = Jt(n, "%webView_inventory_unapproved%"), v = Jt(n, "%webView_inventory_unknown%"), f = Jt(n, "%webView_inventory_scope_currentBook%"), m = Jt(n, "%webView_inventory_scope_chapter%"), E = Jt(n, "%webView_inventory_scope_verse%"), _ = Jt(n, "%webView_inventory_filter_text%"), C = Jt( n, "%webView_inventory_show_additional_items%" - ), [S, b] = ut(!1), [I, z] = ut("all"), [H, O] = ut(""), [$, k] = ut([]), B = It(() => l ? r instanceof RegExp ? td( + ), [S, b] = ut(!1), [I, z] = ut("all"), [H, O] = ut(""), [$, k] = ut([]), B = It(() => l ? r instanceof RegExp ? qc( l, t, a, @@ -2292,7 +2292,7 @@ function Eh({ status: R.status }); }), y; - }, [S, B]), J = It(() => Qc(D, I, H), [D, I, H]), q = It(() => { + }, [S, B]), J = It(() => Wc(D, I, H), [D, I, H]), q = It(() => { var L, F; if (!S) return p; @@ -2302,7 +2302,7 @@ function Eh({ const R = []; for (let V = 0; V < y; V++) R.push( - Zc( + Yc( ((F = o == null ? void 0 : o.tableHeaders) == null ? void 0 : F[V]) || "Additional Item", V + 1 ) @@ -2338,16 +2338,16 @@ function Eh({ throw new Error("Selected item is not unique"); return y[0].occurrences; }, [$, S, D]); - return /* @__PURE__ */ x("div", { className: "pr-twp tw-flex tw-h-full tw-flex-col", children: [ - /* @__PURE__ */ x("div", { className: "tw-flex tw-items-stretch", children: [ - /* @__PURE__ */ x( + return /* @__PURE__ */ N("div", { className: "pr-twp tw-flex tw-h-full tw-flex-col", children: [ + /* @__PURE__ */ N("div", { className: "tw-flex tw-items-stretch", children: [ + /* @__PURE__ */ N( gn, { onValueChange: (y) => at(y), defaultValue: I, children: [ /* @__PURE__ */ s(De, { className: "tw-m-1", children: /* @__PURE__ */ s(bn, { placeholder: "Select filter" }) }), - /* @__PURE__ */ x(Be, { children: [ + /* @__PURE__ */ N(Be, { children: [ /* @__PURE__ */ s(Gt, { value: "all", children: h }), /* @__PURE__ */ s(Gt, { value: "approved", children: w }), /* @__PURE__ */ s(Gt, { value: "unapproved", children: g }), @@ -2356,9 +2356,9 @@ function Eh({ ] } ), - /* @__PURE__ */ x(gn, { onValueChange: (y) => tt(y), defaultValue: c, children: [ + /* @__PURE__ */ N(gn, { onValueChange: (y) => tt(y), defaultValue: c, children: [ /* @__PURE__ */ s(De, { className: "tw-m-1", children: /* @__PURE__ */ s(bn, { placeholder: "Select scope" }) }), - /* @__PURE__ */ x(Be, { children: [ + /* @__PURE__ */ N(Be, { children: [ /* @__PURE__ */ s(Gt, { value: "book", children: f }), /* @__PURE__ */ s(Gt, { value: "chapter", children: m }), /* @__PURE__ */ s(Gt, { value: "verse", children: E }) @@ -2375,7 +2375,7 @@ function Eh({ } } ), - o && /* @__PURE__ */ x("div", { className: "tw-m-1 tw-flex tw-items-center tw-rounded-md tw-border", children: [ + o && /* @__PURE__ */ N("div", { className: "tw-m-1 tw-flex tw-items-center tw-rounded-md tw-border", children: [ /* @__PURE__ */ s( ho, { @@ -2390,7 +2390,7 @@ function Eh({ ] }) ] }), /* @__PURE__ */ s("div", { className: "tw-m-1 tw-flex-1 tw-overflow-auto tw-rounded-md tw-border", children: /* @__PURE__ */ s( - Xc, + Lc, { columns: q, data: J, @@ -2399,7 +2399,7 @@ function Eh({ } ) }), rt.length > 0 && /* @__PURE__ */ s("div", { className: "tw-m-1 tw-flex-1 tw-overflow-auto tw-rounded-md tw-border", children: /* @__PURE__ */ s( - Yc, + Fc, { occurrenceData: rt, setScriptureReference: e, @@ -2420,7 +2420,7 @@ function Pi({ return /* @__PURE__ */ s( Ye, { - className: N( + className: x( "tw-flex tw-h-10 tw-rounded-md tw-border tw-border-input tw-bg-background tw-px-3 tw-py-2 tw-text-sm tw-ring-offset-background file:tw-border-0 file:tw-bg-transparent file:tw-text-sm file:tw-font-medium placeholder:tw-text-muted-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-[color:hsl(240,5%,64.9%)] focus-visible:tw-ring-offset-2 disabled:tw-cursor-not-allowed disabled:tw-opacity-50", { "tw-w-full": r }, t @@ -2436,7 +2436,7 @@ const $i = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( { orientation: "vertical", ref: n, - className: N("tw-flex tw-gap-1 tw-rounded-md tw-text-muted-foreground", t), + className: x("tw-flex tw-gap-1 tw-rounded-md tw-text-muted-foreground", t), ...e } )); @@ -2445,7 +2445,7 @@ const Ii = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( _t.List, { ref: n, - className: N( + className: x( "tw-flex-fit tw-mlk-items-center tw-w-[124px] tw-justify-center tw-rounded-md tw-bg-muted tw-p-1 tw-text-muted-foreground", t ), @@ -2453,12 +2453,12 @@ const Ii = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( } )); Ii.displayName = _t.List.displayName; -const ed = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( +const Kc = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( _t.Trigger, { ref: n, ...e, - className: N( + className: x( "overflow-clip tw-inline-flex tw-w-[116px] tw-cursor-pointer tw-items-center tw-justify-center tw-break-words tw-rounded-sm tw-border-0 tw-bg-muted tw-px-3 tw-py-1.5 tw-text-sm tw-font-medium tw-text-inherit tw-ring-offset-background tw-transition-all hover:tw-text-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50 data-[state=active]:tw-bg-background data-[state=active]:tw-text-foreground data-[state=active]:tw-shadow-sm", t ) @@ -2467,7 +2467,7 @@ const ed = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( _t.Content, { ref: n, - className: N( + className: x( // Removed tw-mt-2 because Sebastian said so "tw-ms-5 tw-flex-grow tw-text-foreground tw-ring-offset-background focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2", t @@ -2484,8 +2484,8 @@ function Sh({ isSearchBarFullWidth: o = !1, direction: a = "ltr" }) { - return /* @__PURE__ */ x("div", { className: "pr-twp", children: [ - /* @__PURE__ */ x("div", { className: "tw-sticky tw-top-0 tw-space-y-2 tw-pb-2", children: [ + return /* @__PURE__ */ N("div", { className: "pr-twp", children: [ + /* @__PURE__ */ N("div", { className: "tw-sticky tw-top-0 tw-space-y-2 tw-pb-2", children: [ r ? /* @__PURE__ */ s("h1", { children: r }) : "", /* @__PURE__ */ s( Pi, @@ -2496,8 +2496,8 @@ function Sh({ } ) ] }), - /* @__PURE__ */ x($i, { dir: a, children: [ - /* @__PURE__ */ s(Ii, { children: t.map((i) => /* @__PURE__ */ s(ed, { value: i.value, children: i.value }, i.key)) }), + /* @__PURE__ */ N($i, { dir: a, children: [ + /* @__PURE__ */ s(Ii, { children: t.map((i) => /* @__PURE__ */ s(Kc, { value: i.value, children: i.value }, i.key)) }), t.map((i) => /* @__PURE__ */ s(Ai, { value: i.value, children: i.content }, i.key)) ] }) ] }); @@ -2508,7 +2508,7 @@ const go = T.forwardRef(({ className: t, orientation: e = "horizontal", decorati ref: o, decorative: n, orientation: e, - className: N( + className: x( "pr-twp tw-shrink-0 tw-bg-border", e === "horizontal" ? "tw-h-[1px] tw-w-full" : "tw-h-full tw-w-[1px]", t @@ -2517,10 +2517,10 @@ const go = T.forwardRef(({ className: t, orientation: e = "horizontal", decorati } )); go.displayName = ai.Root.displayName; -const nd = vt.Root, rd = vt.Portal, Mi = M.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( +const Jc = vt.Root, Zc = vt.Portal, Mi = M.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( vt.Overlay, { - className: N( + className: x( "tw-fixed tw-inset-0 tw-z-50 tw-bg-black/80 data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0", t ), @@ -2529,7 +2529,7 @@ const nd = vt.Root, rd = vt.Portal, Mi = M.forwardRef(({ className: t, ...e }, n } )); Mi.displayName = vt.Overlay.displayName; -const od = Xe( +const Qc = Xe( "pr-twp tw-fixed tw-z-50 tw-gap-4 tw-bg-background tw-p-6 tw-shadow-lg tw-transition tw-ease-in-out data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-duration-300 data-[state=open]:tw-duration-500", { variants: { @@ -2544,50 +2544,50 @@ const od = Xe( side: "right" } } -), Di = M.forwardRef(({ side: t = "right", className: e, children: n, ...r }, o) => /* @__PURE__ */ x(rd, { children: [ +), Di = M.forwardRef(({ side: t = "right", className: e, children: n, ...r }, o) => /* @__PURE__ */ N(Zc, { children: [ /* @__PURE__ */ s(Mi, {}), - /* @__PURE__ */ x(vt.Content, { ref: o, className: N(od({ side: t }), e), ...r, children: [ + /* @__PURE__ */ N(vt.Content, { ref: o, className: x(Qc({ side: t }), e), ...r, children: [ n, - /* @__PURE__ */ x(vt.Close, { className: "tw-absolute tw-right-4 tw-top-4 tw-rounded-sm tw-opacity-70 tw-ring-offset-background tw-transition-opacity hover:tw-opacity-100 focus:tw-outline-none focus:tw-ring-2 focus:tw-ring-ring focus:tw-ring-offset-2 disabled:tw-pointer-events-none data-[state=open]:tw-bg-secondary", children: [ + /* @__PURE__ */ N(vt.Close, { className: "tw-absolute tw-right-4 tw-top-4 tw-rounded-sm tw-opacity-70 tw-ring-offset-background tw-transition-opacity hover:tw-opacity-100 focus:tw-outline-none focus:tw-ring-2 focus:tw-ring-ring focus:tw-ring-offset-2 disabled:tw-pointer-events-none data-[state=open]:tw-bg-secondary", children: [ /* @__PURE__ */ s(Qa, { className: "tw-h-4 tw-w-4" }), /* @__PURE__ */ s("span", { className: "tw-sr-only", children: "Close" }) ] }) ] }) ] })); Di.displayName = vt.Content.displayName; -const ad = M.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( +const td = M.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( vt.Title, { ref: n, - className: N("tw-text-lg tw-font-semibold tw-text-foreground", t), + className: x("tw-text-lg tw-font-semibold tw-text-foreground", t), ...e } )); -ad.displayName = vt.Title.displayName; -const id = M.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( +td.displayName = vt.Title.displayName; +const ed = M.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( vt.Description, { ref: n, - className: N("tw-text-sm tw-text-muted-foreground", t), + className: x("tw-text-sm tw-text-muted-foreground", t), ...e } )); -id.displayName = vt.Description.displayName; +ed.displayName = vt.Description.displayName; function aa({ className: t, ...e }) { return /* @__PURE__ */ s( "div", { - className: N("pr-twp tw-animate-pulse tw-rounded-md tw-bg-muted", t), + className: x("pr-twp tw-animate-pulse tw-rounded-md tw-bg-muted", t), ...e } ); } -const sd = En.Provider, ld = En.Root, cd = En.Trigger, Bi = T.forwardRef(({ className: t, sideOffset: e = 4, ...n }, r) => /* @__PURE__ */ s( +const nd = En.Provider, rd = En.Root, od = En.Trigger, Bi = T.forwardRef(({ className: t, sideOffset: e = 4, ...n }, r) => /* @__PURE__ */ s( En.Content, { ref: r, sideOffset: e, - className: N( + className: x( "pr-twp tw-z-50 tw-overflow-hidden tw-rounded-md tw-border tw-bg-popover tw-px-3 tw-py-1.5 tw-text-sm tw-text-popover-foreground tw-shadow-md tw-animate-in tw-fade-in-0 tw-zoom-in-95 data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=closed]:tw-zoom-out-95 data-[side=bottom]:tw-slide-in-from-top-2 data-[side=left]:tw-slide-in-from-right-2 data-[side=right]:tw-slide-in-from-left-2 data-[side=top]:tw-slide-in-from-bottom-2", t ), @@ -2596,7 +2596,7 @@ const sd = En.Provider, ld = En.Root, cd = En.Trigger, Bi = T.forwardRef(({ clas )); Bi.displayName = En.Content.displayName; const $r = 768; -function dd() { +function ad() { const [t, e] = M.useState(void 0); return M.useEffect(() => { const n = window.matchMedia(`(max-width: ${$r - 1}px)`), r = () => { @@ -2605,7 +2605,7 @@ function dd() { return n.addEventListener("change", r), e(window.innerWidth < $r), () => n.removeEventListener("change", r); }, []), !!t; } -const pd = "sidebar:state", ud = 60 * 60 * 24 * 7, wd = "16rem", fd = "18rem", md = "3rem", hd = "b", ji = T.createContext(void 0); +const id = "sidebar:state", sd = 60 * 60 * 24 * 7, ld = "16rem", cd = "18rem", dd = "3rem", pd = "b", ji = T.createContext(void 0); function cr() { const t = T.useContext(ji); if (!t) @@ -2622,16 +2622,16 @@ const Vi = T.forwardRef( children: a, ...i }, l) => { - const c = dd(), [d, p] = T.useState(!1), [h, w] = T.useState(t), g = e ?? h, v = T.useCallback( + const c = ad(), [d, p] = T.useState(!1), [h, w] = T.useState(t), g = e ?? h, v = T.useCallback( (_) => { const C = typeof _ == "function" ? _(g) : _; - n ? n(C) : w(C), document.cookie = `${pd}=${C}; path=/; max-age=${ud}`; + n ? n(C) : w(C), document.cookie = `${id}=${C}; path=/; max-age=${sd}`; }, [n, g] ), f = T.useCallback(() => c ? p((_) => !_) : v((_) => !_), [c, v, p]); T.useEffect(() => { const _ = (C) => { - C.key === hd && (C.metaKey || C.ctrlKey) && (C.preventDefault(), f()); + C.key === pd && (C.metaKey || C.ctrlKey) && (C.preventDefault(), f()); }; return window.addEventListener("keydown", _), () => window.removeEventListener("keydown", _); }, [f]); @@ -2647,18 +2647,18 @@ const Vi = T.forwardRef( }), [m, g, v, c, d, p, f] ); - return /* @__PURE__ */ s(ji.Provider, { value: E, children: /* @__PURE__ */ s(sd, { delayDuration: 0, children: /* @__PURE__ */ s( + return /* @__PURE__ */ s(ji.Provider, { value: E, children: /* @__PURE__ */ s(nd, { delayDuration: 0, children: /* @__PURE__ */ s( "div", { style: ( // eslint-disable-next-line no-type-assertion/no-type-assertion { - "--sidebar-width": wd, - "--sidebar-width-icon": md, + "--sidebar-width": ld, + "--sidebar-width-icon": dd, ...o } ), - className: N( + className: x( // Removed tw-min-h-svh "tw-group/sidebar-wrapper pr-twp tw-flex tw-w-full has-[[data-variant=inset]]:tw-bg-sidebar", r @@ -2684,7 +2684,7 @@ const zi = T.forwardRef( return n === "none" ? /* @__PURE__ */ s( "div", { - className: N( + className: x( "tw-flex tw-h-full tw-w-[--sidebar-width] tw-flex-col tw-bg-sidebar tw-text-sidebar-foreground", r ), @@ -2692,7 +2692,7 @@ const zi = T.forwardRef( ...a, children: o } - ) : l ? /* @__PURE__ */ s(nd, { open: d, onOpenChange: p, ...a, children: /* @__PURE__ */ s( + ) : l ? /* @__PURE__ */ s(Jc, { open: d, onOpenChange: p, ...a, children: /* @__PURE__ */ s( Di, { "data-sidebar": "sidebar", @@ -2701,13 +2701,13 @@ const zi = T.forwardRef( style: ( // eslint-disable-next-line no-type-assertion/no-type-assertion { - "--sidebar-width": fd + "--sidebar-width": cd } ), side: t, children: /* @__PURE__ */ s("div", { className: "tw-flex tw-h-full tw-w-full tw-flex-col", children: o }) } - ) }) : /* @__PURE__ */ x( + ) }) : /* @__PURE__ */ N( "div", { ref: i, @@ -2720,7 +2720,7 @@ const zi = T.forwardRef( /* @__PURE__ */ s( "div", { - className: N( + className: x( "tw-relative tw-h-svh tw-w-[--sidebar-width] tw-bg-transparent tw-transition-[width] tw-duration-200 tw-ease-linear", "group-data-[collapsible=offcanvas]:tw-w-0", "group-data-[side=right]:tw-rotate-180", @@ -2731,7 +2731,7 @@ const zi = T.forwardRef( /* @__PURE__ */ s( "div", { - className: N( + className: x( // Switched tw-fixed to tw-absolute here to scope the sidebar inside of it's container "tw-absolute tw-inset-y-0 tw-z-10 tw-hidden tw-h-svh tw-w-[--sidebar-width] tw-transition-[left,right,width] tw-duration-200 tw-ease-linear md:tw-flex", t === "left" ? "tw-left-0 group-data-[collapsible=offcanvas]:tw-left-[calc(var(--sidebar-width)*-1)]" : "tw-right-0 group-data-[collapsible=offcanvas]:tw-right-[calc(var(--sidebar-width)*-1)]", @@ -2756,29 +2756,29 @@ const zi = T.forwardRef( } ); zi.displayName = "Sidebar"; -const gd = T.forwardRef(({ className: t, onClick: e, ...n }, r) => { +const ud = T.forwardRef(({ className: t, onClick: e, ...n }, r) => { const { toggleSidebar: o } = cr(); - return /* @__PURE__ */ x( + return /* @__PURE__ */ N( gt, { ref: r, "data-sidebar": "trigger", variant: "ghost", size: "icon", - className: N("tw-h-7 tw-w-7", t), + className: x("tw-h-7 tw-w-7", t), onClick: (a) => { e == null || e(a), o(); }, ...n, children: [ - /* @__PURE__ */ s(yl, {}), + /* @__PURE__ */ s(ml, {}), /* @__PURE__ */ s("span", { className: "tw-sr-only", children: "Toggle Sidebar" }) ] } ); }); -gd.displayName = "SidebarTrigger"; -const bd = T.forwardRef( +ud.displayName = "SidebarTrigger"; +const wd = T.forwardRef( ({ className: t, ...e }, n) => { const { toggleSidebar: r } = cr(); return /* @__PURE__ */ s( @@ -2791,7 +2791,7 @@ const bd = T.forwardRef( tabIndex: -1, onClick: r, title: "Toggle Sidebar", - className: N( + className: x( "tw-absolute tw-inset-y-0 tw-z-20 tw-hidden tw-w-4 tw--translate-x-1/2 tw-transition-all tw-ease-linear after:tw-absolute after:tw-inset-y-0 after:tw-left-1/2 after:tw-w-[2px] hover:after:tw-bg-sidebar-border group-data-[side=left]:tw--right-4 group-data-[side=right]:tw-left-0 sm:tw-flex", "[[data-side=left]_&]:tw-cursor-w-resize [[data-side=right]_&]:tw-cursor-e-resize", "[[data-side=left][data-state=collapsed]_&]:tw-cursor-e-resize [[data-side=right][data-state=collapsed]_&]:tw-cursor-w-resize", @@ -2805,13 +2805,13 @@ const bd = T.forwardRef( ); } ); -bd.displayName = "SidebarRail"; +wd.displayName = "SidebarRail"; const Li = T.forwardRef( ({ className: t, ...e }, n) => /* @__PURE__ */ s( "main", { ref: n, - className: N( + className: x( // Removed tw-min-h-svh "tw-relative tw-flex tw-flex-1 tw-flex-col tw-bg-background", "peer-data-[variant=inset]:tw-min-h-[calc(100svh-theme(spacing.4))] md:peer-data-[variant=inset]:tw-m-2 md:peer-data-[state=collapsed]:peer-data-[variant=inset]:tw-ml-2 md:peer-data-[variant=inset]:tw-ml-0 md:peer-data-[variant=inset]:tw-rounded-xl md:peer-data-[variant=inset]:tw-shadow", @@ -2822,60 +2822,60 @@ const Li = T.forwardRef( ) ); Li.displayName = "SidebarInset"; -const vd = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( +const fd = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( Ye, { ref: n, "data-sidebar": "input", - className: N( + className: x( "tw-h-8 tw-w-full tw-bg-background tw-shadow-none focus-visible:tw-ring-2 focus-visible:tw-ring-sidebar-ring", t ), ...e } )); -vd.displayName = "SidebarInput"; -const yd = T.forwardRef( +fd.displayName = "SidebarInput"; +const md = T.forwardRef( ({ className: t, ...e }, n) => /* @__PURE__ */ s( "div", { ref: n, "data-sidebar": "header", - className: N("tw-flex tw-flex-col tw-gap-2 tw-p-2", t), + className: x("tw-flex tw-flex-col tw-gap-2 tw-p-2", t), ...e } ) ); -yd.displayName = "SidebarHeader"; -const xd = T.forwardRef( +md.displayName = "SidebarHeader"; +const hd = T.forwardRef( ({ className: t, ...e }, n) => /* @__PURE__ */ s( "div", { ref: n, "data-sidebar": "footer", - className: N("tw-flex tw-flex-col tw-gap-2 tw-p-2", t), + className: x("tw-flex tw-flex-col tw-gap-2 tw-p-2", t), ...e } ) ); -xd.displayName = "SidebarFooter"; -const Nd = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( +hd.displayName = "SidebarFooter"; +const gd = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( go, { ref: n, "data-sidebar": "separator", - className: N("tw-mx-2 tw-w-auto tw-bg-sidebar-border", t), + className: x("tw-mx-2 tw-w-auto tw-bg-sidebar-border", t), ...e } )); -Nd.displayName = "SidebarSeparator"; +gd.displayName = "SidebarSeparator"; const Fi = T.forwardRef( ({ className: t, ...e }, n) => /* @__PURE__ */ s( "div", { ref: n, "data-sidebar": "content", - className: N( + className: x( "tw-flex tw-min-h-0 tw-flex-1 tw-flex-col tw-gap-2 tw-overflow-auto group-data-[collapsible=icon]:tw-overflow-hidden", t ), @@ -2890,7 +2890,7 @@ const Kr = T.forwardRef( { ref: n, "data-sidebar": "group", - className: N("tw-relative tw-flex tw-w-full tw-min-w-0 tw-flex-col tw-p-2", t), + className: x("tw-relative tw-flex tw-w-full tw-min-w-0 tw-flex-col tw-p-2", t), ...e } ) @@ -2901,7 +2901,7 @@ const Jr = T.forwardRef(({ className: t, asChild: e = !1, ...n }, r) => /* @__PU { ref: r, "data-sidebar": "group-label", - className: N( + className: x( "tw-flex tw-h-8 tw-shrink-0 tw-items-center tw-rounded-md tw-px-2 tw-text-xs tw-font-medium tw-text-sidebar-foreground/70 tw-outline-none tw-ring-sidebar-ring tw-transition-[margin,opa] tw-duration-200 tw-ease-linear focus-visible:tw-ring-2 [&>svg]:tw-size-4 [&>svg]:tw-shrink-0", "group-data-[collapsible=icon]:tw--mt-8 group-data-[collapsible=icon]:tw-opacity-0", t @@ -2910,12 +2910,12 @@ const Jr = T.forwardRef(({ className: t, asChild: e = !1, ...n }, r) => /* @__PU } )); Jr.displayName = "SidebarGroupLabel"; -const kd = T.forwardRef(({ className: t, asChild: e = !1, ...n }, r) => /* @__PURE__ */ s( +const bd = T.forwardRef(({ className: t, asChild: e = !1, ...n }, r) => /* @__PURE__ */ s( e ? He : "button", { ref: r, "data-sidebar": "group-action", - className: N( + className: x( "tw-absolute tw-right-3 tw-top-3.5 tw-flex tw-aspect-square tw-w-5 tw-items-center tw-justify-center tw-rounded-md tw-p-0 tw-text-sidebar-foreground tw-outline-none tw-ring-sidebar-ring tw-transition-transform hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground focus-visible:tw-ring-2 [&>svg]:tw-size-4 [&>svg]:tw-shrink-0", // Increases the hit area of the button on mobile. "after:tw-absolute after:tw--inset-2 after:md:tw-hidden", @@ -2925,14 +2925,14 @@ const kd = T.forwardRef(({ className: t, asChild: e = !1, ...n }, r) => /* @__PU ...n } )); -kd.displayName = "SidebarGroupAction"; +bd.displayName = "SidebarGroupAction"; const Zr = T.forwardRef( ({ className: t, ...e }, n) => /* @__PURE__ */ s( "div", { ref: n, "data-sidebar": "group-content", - className: N("tw-w-full tw-text-sm", t), + className: x("tw-w-full tw-text-sm", t), ...e } ) @@ -2944,7 +2944,7 @@ const Ui = T.forwardRef( { ref: n, "data-sidebar": "menu", - className: N("tw-flex tw-w-full tw-min-w-0 tw-flex-col tw-gap-1", t), + className: x("tw-flex tw-w-full tw-min-w-0 tw-flex-col tw-gap-1", t), ...e } ) @@ -2956,13 +2956,13 @@ const Gi = T.forwardRef( { ref: n, "data-sidebar": "menu-item", - className: N("tw-group/menu-item tw-relative", t), + className: x("tw-group/menu-item tw-relative", t), ...e } ) ); Gi.displayName = "SidebarMenuItem"; -const Ed = Xe( +const vd = Xe( // Removed data-[active=true]:tw-bg-sidebar-accent "tw-peer/menu-button tw-flex tw-w-full tw-items-center tw-gap-2 tw-overflow-hidden tw-rounded-md tw-p-2 tw-text-left tw-text-sm tw-outline-none tw-ring-sidebar-ring tw-transition-[width,height,padding] hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground focus-visible:tw-ring-2 active:tw-bg-sidebar-accent active:tw-text-sidebar-accent-foreground disabled:tw-pointer-events-none disabled:tw-opacity-50 tw-group-has-[[data-sidebar=menu-action]]/menu-item:pr-8 aria-disabled:tw-pointer-events-none aria-disabled:tw-opacity-50 data-[active=true]:tw-font-medium data-[active=true]:tw-text-sidebar-accent-foreground data-[state=open]:hover:tw-bg-sidebar-accent data-[state=open]:hover:tw-text-sidebar-accent-foreground group-data-[collapsible=icon]:tw-!size-8 group-data-[collapsible=icon]:tw-!p-2 [&>span:last-child]:tw-truncate [&>svg]:tw-size-4 [&>svg]:tw-shrink-0", { @@ -2999,14 +2999,14 @@ const Ed = Xe( "data-sidebar": "menu-button", "data-size": r, "data-active": e, - className: N(Ed({ variant: n, size: r }), a), + className: x(vd({ variant: n, size: r }), a), ...i } ); return o ? (typeof o == "string" && (o = { children: o - }), /* @__PURE__ */ x(ld, { children: [ - /* @__PURE__ */ s(cd, { asChild: !0, children: h }), + }), /* @__PURE__ */ N(rd, { children: [ + /* @__PURE__ */ s(od, { asChild: !0, children: h }), /* @__PURE__ */ s( Bi, { @@ -3020,12 +3020,12 @@ const Ed = Xe( } ); Hi.displayName = "SidebarMenuButton"; -const Sd = T.forwardRef(({ className: t, asChild: e = !1, showOnHover: n = !1, ...r }, o) => /* @__PURE__ */ s( +const yd = T.forwardRef(({ className: t, asChild: e = !1, showOnHover: n = !1, ...r }, o) => /* @__PURE__ */ s( e ? He : "button", { ref: o, "data-sidebar": "menu-action", - className: N( + className: x( "tw-peer-hover/menu-button:text-sidebar-accent-foreground tw-absolute tw-right-1 tw-top-1.5 tw-flex tw-aspect-square tw-w-5 tw-items-center tw-justify-center tw-rounded-md tw-p-0 tw-text-sidebar-foreground tw-outline-none tw-ring-sidebar-ring tw-transition-transform hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground focus-visible:tw-ring-2 [&>svg]:tw-size-4 [&>svg]:tw-shrink-0", // Increases the hit area of the button on mobile. "after:tw-absolute after:tw--inset-2 after:md:tw-hidden", @@ -3039,14 +3039,14 @@ const Sd = T.forwardRef(({ className: t, asChild: e = !1, showOnHover: n = !1, . ...r } )); -Sd.displayName = "SidebarMenuAction"; -const Td = T.forwardRef( +yd.displayName = "SidebarMenuAction"; +const xd = T.forwardRef( ({ className: t, ...e }, n) => /* @__PURE__ */ s( "div", { ref: n, "data-sidebar": "menu-badge", - className: N( + className: x( "tw-pointer-events-none tw-absolute tw-right-1 tw-flex tw-h-5 tw-min-w-5 tw-select-none tw-items-center tw-justify-center tw-rounded-md tw-px-1 tw-text-xs tw-font-medium tw-tabular-nums tw-text-sidebar-foreground", "tw-peer-hover/menu-button:text-sidebar-accent-foreground tw-peer-data-[active=true]/menu-button:text-sidebar-accent-foreground", "tw-peer-data-[size=sm]/menu-button:top-1", @@ -3059,15 +3059,15 @@ const Td = T.forwardRef( } ) ); -Td.displayName = "SidebarMenuBadge"; -const Cd = T.forwardRef(({ className: t, showIcon: e = !1, ...n }, r) => { +xd.displayName = "SidebarMenuBadge"; +const Nd = T.forwardRef(({ className: t, showIcon: e = !1, ...n }, r) => { const o = T.useMemo(() => `${Math.floor(Math.random() * 40) + 50}%`, []); - return /* @__PURE__ */ x( + return /* @__PURE__ */ N( "div", { ref: r, "data-sidebar": "menu-skeleton", - className: N("tw-flex tw-h-8 tw-items-center tw-gap-2 tw-rounded-md tw-px-2", t), + className: x("tw-flex tw-h-8 tw-items-center tw-gap-2 tw-rounded-md tw-px-2", t), ...n, children: [ e && /* @__PURE__ */ s(aa, { className: "tw-size-4 tw-rounded-md", "data-sidebar": "menu-skeleton-icon" }), @@ -3088,14 +3088,14 @@ const Cd = T.forwardRef(({ className: t, showIcon: e = !1, ...n }, r) => { } ); }); -Cd.displayName = "SidebarMenuSkeleton"; -const Od = T.forwardRef( +Nd.displayName = "SidebarMenuSkeleton"; +const kd = T.forwardRef( ({ className: t, ...e }, n) => /* @__PURE__ */ s( "ul", { ref: n, "data-sidebar": "menu-sub", - className: N( + className: x( "tw-mx-3.5 tw-flex tw-min-w-0 tw-translate-x-px tw-flex-col tw-gap-1 tw-border-l tw-border-sidebar-border tw-px-2.5 tw-py-0.5", "group-data-[collapsible=icon]:tw-hidden", t @@ -3104,19 +3104,19 @@ const Od = T.forwardRef( } ) ); -Od.displayName = "SidebarMenuSub"; -const Rd = T.forwardRef( +kd.displayName = "SidebarMenuSub"; +const Ed = T.forwardRef( ({ ...t }, e) => /* @__PURE__ */ s("li", { ref: e, ...t }) ); -Rd.displayName = "SidebarMenuSubItem"; -const _d = T.forwardRef(({ asChild: t = !1, size: e = "md", isActive: n, className: r, ...o }, a) => /* @__PURE__ */ s( +Ed.displayName = "SidebarMenuSubItem"; +const Sd = T.forwardRef(({ asChild: t = !1, size: e = "md", isActive: n, className: r, ...o }, a) => /* @__PURE__ */ s( t ? He : "a", { ref: a, "data-sidebar": "menu-sub-button", "data-size": e, "data-active": n, - className: N( + className: x( "tw-flex tw-h-7 tw-min-w-0 tw--translate-x-px tw-items-center tw-gap-2 tw-overflow-hidden tw-rounded-md tw-px-2 tw-text-sidebar-foreground tw-outline-none tw-ring-sidebar-ring hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground focus-visible:tw-ring-2 active:tw-bg-sidebar-accent active:tw-text-sidebar-accent-foreground disabled:tw-pointer-events-none disabled:tw-opacity-50 aria-disabled:tw-pointer-events-none aria-disabled:tw-opacity-50 [&>span:last-child]:tw-truncate [&>svg]:tw-size-4 [&>svg]:tw-shrink-0 [&>svg]:tw-text-sidebar-accent-foreground", "data-[active=true]:tw-bg-sidebar-accent data-[active=true]:tw-text-sidebar-accent-foreground", e === "sm" && "tw-text-xs", @@ -3127,8 +3127,8 @@ const _d = T.forwardRef(({ asChild: t = !1, size: e = "md", isActive: n, classNa ...o } )); -_d.displayName = "SidebarMenuSubButton"; -function Pd({ +Sd.displayName = "SidebarMenuSubButton"; +function Td({ id: t, extensionLabels: e, projectOptions: n, @@ -3157,13 +3157,13 @@ function Pd({ collapsible: "none", variant: "inset", className: "tw-w-96 tw-gap-2 tw-overflow-y-auto tw-rounded tw-bg-slate-100", - children: /* @__PURE__ */ x(Fi, { children: [ - /* @__PURE__ */ x(Kr, { children: [ + children: /* @__PURE__ */ N(Fi, { children: [ + /* @__PURE__ */ N(Kr, { children: [ /* @__PURE__ */ s(Jr, { className: "tw-text-sm tw-text-gray-400", children: "Extensions" }), /* @__PURE__ */ s(Zr, { children: /* @__PURE__ */ s(Ui, { children: e.map((c) => /* @__PURE__ */ s(Gi, { children: /* @__PURE__ */ s( Hi, { - className: N( + className: x( "tw-rounded tw-py-2 tw-text-sm tw-text-gray-500 hover:tw-bg-white hover:tw-text-gray-900 hover:tw-shadow-sm active:tw-bg-white", { "tw-bg-white tw-text-gray-900 tw-shadow-sm": l(c) } ), @@ -3173,7 +3173,7 @@ function Pd({ } ) }, c)) }) }) ] }), - /* @__PURE__ */ x(Kr, { children: [ + /* @__PURE__ */ N(Kr, { children: [ /* @__PURE__ */ s(Jr, { className: "tw-text-sm tw-text-gray-400", children: "Projects" }), /* @__PURE__ */ s(Zr, { className: "tw-pl-3", children: /* @__PURE__ */ s( qr, @@ -3204,7 +3204,7 @@ function Th({ selectedSidebarItem: i, onSearch: l }) { - return /* @__PURE__ */ x("div", { className: "tw-h-full tw-p-3", children: [ + return /* @__PURE__ */ N("div", { className: "tw-flex tw-h-full tw-flex-col tw-p-3 tw-pb-2", children: [ /* @__PURE__ */ s("div", { className: "tw-flex tw-items-center tw-justify-center tw-py-4", children: /* @__PURE__ */ s( Pi, { @@ -3213,9 +3213,9 @@ function Th({ placeholder: "Search app settings, extension settings, and project settings" } ) }), - /* @__PURE__ */ x(Vi, { dir: e, id: t, className: "tw-gap-4", children: [ + /* @__PURE__ */ N(Vi, { dir: e, id: t, className: "tw-h-full tw-flex-1 tw-gap-4", children: [ /* @__PURE__ */ s( - Pd, + Td, { extensionLabels: n, projectOptions: r, @@ -3227,14 +3227,14 @@ function Th({ ] }) ] }); } -const ne = "scrBook", $d = "scrRef", we = "source", Id = "details", Ad = "Scripture Reference", Md = "Scripture Book", Xi = "Type", Dd = "Details"; -function Bd(t, e) { +const ne = "scrBook", Cd = "scrRef", we = "source", Od = "details", Rd = "Scripture Reference", _d = "Scripture Book", Xi = "Type", Pd = "Details"; +function $d(t, e) { const n = e ?? !1; return [ { accessorFn: (r) => `${ot.bookNumberToId(r.start.bookNum)} ${r.start.chapterNum}:${r.start.verseNum}`, id: ne, - header: (t == null ? void 0 : t.scriptureReferenceColumnName) ?? Ad, + header: (t == null ? void 0 : t.scriptureReferenceColumnName) ?? Rd, cell: (r) => { const o = r.row.original; return r.row.getIsGrouped() ? ot.bookNumberToEnglishName(o.start.bookNum) : r.row.groupingColumnId === ne ? Or(o.start) : void 0; @@ -3245,7 +3245,7 @@ function Bd(t, e) { }, { accessorFn: (r) => Or(r.start), - id: $d, + id: Cd, header: void 0, cell: (r) => { const o = r.row.original; @@ -3265,14 +3265,14 @@ function Bd(t, e) { }, { accessorFn: (r) => r.detail, - id: Id, - header: (t == null ? void 0 : t.detailsColumnName) ?? Dd, + id: Od, + header: (t == null ? void 0 : t.detailsColumnName) ?? Pd, cell: (r) => r.getValue(), enableGrouping: !1 } ]; } -const jd = (t) => { +const Id = (t) => { if (!("offset" in t.start)) throw new Error("No offset available in range start"); if (t.end && !("offset" in t.end)) @@ -3280,7 +3280,7 @@ const jd = (t) => { const { offset: e } = t.start; let n = 0; return t.end && ({ offset: n } = t.end), !t.end || Hr(t.start, t.end) === 0 ? `${Rr(t.start)}+${e}` : `${Rr(t.start)}+${e}-${Rr(t.end)}+${n}`; -}, ia = (t) => `${jd({ start: t.start, end: t.end })} ${t.source.displayName} ${t.detail}`; +}, ia = (t) => `${Id({ start: t.start, end: t.end })} ${t.source.displayName} ${t.detail}`; function Ch({ sources: t, showColumnHeaders: e = !1, @@ -3299,7 +3299,7 @@ function Ch({ }))), [t] ), m = It( - () => Bd( + () => $d( { scriptureReferenceColumnName: r, typeColumnName: a, @@ -3326,8 +3326,8 @@ function Ch({ onGroupingChange: p, onSortingChange: w, onRowSelectionChange: v, - getExpandedRowModel: Bl(), - getGroupedRowModel: jl(), + getExpandedRowModel: $l(), + getGroupedRowModel: Il(), getCoreRowModel: ni(), getSortedRowModel: ri(), getRowId: ia, @@ -3344,7 +3344,7 @@ function Ch({ } } }, [g, f, l, E]); - const _ = o ?? Md, C = a ?? Xi, S = [ + const _ = o ?? _d, C = a ?? Xi, S = [ { label: "No Grouping", value: [] }, { label: `Group by ${_}`, value: [ne] }, { label: `Group by ${C}`, value: [we] }, @@ -3360,7 +3360,7 @@ function Ch({ p(JSON.parse(O)); }, I = (O, $) => { !O.getIsGrouped() && !O.getIsSelected() && O.getToggleSelectedHandler()($); - }, z = (O, $) => O.getIsGrouped() ? "" : N("banded-row", $ % 2 === 0 ? "even" : "odd"), H = (O, $, k) => { + }, z = (O, $) => O.getIsGrouped() ? "" : x("banded-row", $ % 2 === 0 ? "even" : "odd"), H = (O, $, k) => { if (!((O == null ? void 0 : O.length) === 0 || $.depth < k.column.getGroupedIndex())) { if ($.getIsGrouped()) switch ($.depth) { @@ -3379,8 +3379,8 @@ function Ch({ } } }; - return /* @__PURE__ */ x("div", { className: "pr-twp tw-flex tw-h-full tw-w-full tw-flex-col", children: [ - !e && /* @__PURE__ */ x( + return /* @__PURE__ */ N("div", { className: "pr-twp tw-flex tw-h-full tw-w-full tw-flex-col", children: [ + !e && /* @__PURE__ */ N( gn, { value: JSON.stringify(d), @@ -3389,14 +3389,14 @@ function Ch({ }, children: [ /* @__PURE__ */ s(De, { className: "tw-mb-1 tw-mt-2", children: /* @__PURE__ */ s(bn, {}) }), - /* @__PURE__ */ s(Be, { position: "item-aligned", children: /* @__PURE__ */ s(zc, { children: S.map((O) => /* @__PURE__ */ s(Gt, { value: JSON.stringify(O.value), children: O.label }, O.label)) }) }) + /* @__PURE__ */ s(Be, { position: "item-aligned", children: /* @__PURE__ */ s(Mc, { children: S.map((O) => /* @__PURE__ */ s(Gt, { value: JSON.stringify(O.value), children: O.label }, O.label)) }) }) ] } ), - /* @__PURE__ */ x(ar, { className: "tw-relative tw-flex tw-flex-col tw-overflow-y-auto tw-p-0", children: [ + /* @__PURE__ */ N(ar, { className: "tw-relative tw-flex tw-flex-col tw-overflow-y-auto tw-p-0", children: [ e && /* @__PURE__ */ s(ir, { children: E.getHeaderGroups().map((O) => /* @__PURE__ */ s(oe, { children: O.headers.filter(($) => $.column.columnDef.header).map(($) => ( /* For sticky column headers to work, we probably need to change the default definition of the shadcn Table component. See https://github.com/shadcn-ui/ui/issues/1151 */ - /* @__PURE__ */ s(vn, { colSpan: $.colSpan, className: "top-0 tw-sticky", children: $.isPlaceholder ? void 0 : /* @__PURE__ */ x("div", { children: [ + /* @__PURE__ */ s(vn, { colSpan: $.colSpan, className: "top-0 tw-sticky", children: $.isPlaceholder ? void 0 : /* @__PURE__ */ N("div", { children: [ $.column.getCanGroup() ? /* @__PURE__ */ s( gt, { @@ -3415,19 +3415,19 @@ function Ch({ oe, { "data-state": O.getIsSelected() ? "selected" : "", - className: N(z(O, $)), + className: x(z(O, $)), onClick: (k) => I(O, k), children: O.getVisibleCells().map((k) => { if (!(k.getIsPlaceholder() || k.column.columnDef.enableGrouping && !k.getIsGrouped() && (k.column.columnDef.id !== we || !n))) return /* @__PURE__ */ s( je, { - className: N( + className: x( k.column.columnDef.id, "tw-p-[1px]", H(d, O, k) ), - children: (() => k.getIsGrouped() ? /* @__PURE__ */ x( + children: (() => k.getIsGrouped() ? /* @__PURE__ */ N( gt, { variant: "link", @@ -3435,7 +3435,7 @@ function Ch({ type: "button", children: [ O.getIsExpanded() && /* @__PURE__ */ s(er, {}), - !O.getIsExpanded() && (c === "ltr" ? /* @__PURE__ */ s(Ja, {}) : /* @__PURE__ */ s(xl, {})), + !O.getIsExpanded() && (c === "ltr" ? /* @__PURE__ */ s(Ja, {}) : /* @__PURE__ */ s(hl, {})), " ", dn(k.column.columnDef.cell, k.getContext()), " (", @@ -3500,7 +3500,7 @@ function Oh({ ) ) }; - return /* @__PURE__ */ x( + return /* @__PURE__ */ N( gn, { value: `${e}`, @@ -3535,8 +3535,8 @@ function _h({ isLoading: r = !1, loadingMessage: o }) { - return /* @__PURE__ */ x("div", { className: "tw-flex tw-items-center tw-justify-between tw-space-x-4 tw-py-2", children: [ - /* @__PURE__ */ x("div", { children: [ + return /* @__PURE__ */ N("div", { className: "tw-flex tw-items-center tw-justify-between tw-space-x-4 tw-py-2", children: [ + /* @__PURE__ */ N("div", { children: [ /* @__PURE__ */ s("p", { className: "tw-text-sm tw-font-medium tw-leading-none", children: t }), /* @__PURE__ */ s("p", { className: "tw-whitespace-normal tw-break-words tw-text-sm tw-text-muted-foreground", children: e }) ] }), @@ -3548,86 +3548,15 @@ function Ph({ secondary: e, includeSeparator: n = !1 }) { - return /* @__PURE__ */ x("div", { className: "tw-space-y-4 tw-py-2", children: [ - /* @__PURE__ */ x("div", { children: [ + return /* @__PURE__ */ N("div", { className: "tw-space-y-4 tw-py-2", children: [ + /* @__PURE__ */ N("div", { children: [ /* @__PURE__ */ s("h3", { className: "tw-text-lg tw-font-medium", children: t }), /* @__PURE__ */ s("p", { className: "tw-text-sm tw-text-muted-foreground", children: e }) ] }), n ? /* @__PURE__ */ s(go, {}) : "" ] }); } -const Yi = T.forwardRef( - ({ className: t, ...e }, n) => /* @__PURE__ */ s( - "div", - { - ref: n, - className: N( - "pr-twp tw-rounded-lg tw-border tw-bg-card tw-text-card-foreground tw-shadow-sm", - t - ), - ...e - } - ) -); -Yi.displayName = "Card"; -const Wi = T.forwardRef( - ({ className: t, ...e }, n) => /* @__PURE__ */ s( - "div", - { - ref: n, - className: N("pr-twp tw-flex tw-flex-col tw-space-y-1.5 tw-p-6", t), - ...e - } - ) -); -Wi.displayName = "CardHeader"; -const qi = T.forwardRef( - ({ className: t, ...e }, n) => /* @__PURE__ */ s( - "h3", - { - ref: n, - className: N( - "pr-twp tw-text-2xl tw-font-semibold tw-leading-none tw-tracking-tight", - t - ), - ...e, - children: e.children - } - ) -); -qi.displayName = "CardTitle"; -const Ki = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s("p", { ref: n, className: N("pr-twp tw-text-sm tw-text-muted-foreground", t), ...e })); -Ki.displayName = "CardDescription"; -const Ji = T.forwardRef( - ({ className: t, ...e }, n) => /* @__PURE__ */ s("div", { ref: n, className: N("pr-twp tw-p-6 tw-pt-0", t), ...e }) -); -Ji.displayName = "CardContent"; -const Vd = T.forwardRef( - ({ className: t, ...e }, n) => /* @__PURE__ */ s( - "div", - { - ref: n, - className: N("pr-twp tw-flex tw-items-center tw-p-6 tw-pt-0", t), - ...e - } - ) -); -Vd.displayName = "CardFooter"; function $h({ - id: t, - settingsGroupLabel: e, - settingsGroupDescription: n, - children: r -}) { - return /* @__PURE__ */ x(Yi, { id: t, children: [ - /* @__PURE__ */ x(Wi, { children: [ - /* @__PURE__ */ s(qi, { children: e }), - n && /* @__PURE__ */ s(Ki, { children: n }) - ] }), - /* @__PURE__ */ s(Ji, { children: r }) - ] }); -} -function Ih({ id: t, className: e, listItems: n, @@ -3635,7 +3564,7 @@ function Ih({ handleSelectListItem: o, createLabel: a }) { - return /* @__PURE__ */ s("div", { id: t, className: e, children: n.map((i) => /* @__PURE__ */ x("div", { className: "tw-m-2 tw-flex tw-items-center", children: [ + return /* @__PURE__ */ s("div", { id: t, className: e, children: n.map((i) => /* @__PURE__ */ N("div", { className: "tw-m-2 tw-flex tw-items-center", children: [ /* @__PURE__ */ s( ho, { @@ -3647,10 +3576,10 @@ function Ih({ /* @__PURE__ */ s(Xt, { children: a ? a(i) : i }) ] }, i)) }); } -function zd(t) { +function Ad(t) { return t && t.__esModule && Object.prototype.hasOwnProperty.call(t, "default") ? t.default : t; } -function Ld(t) { +function Md(t) { if (t.__esModule) return t; var e = t.default; @@ -3671,7 +3600,7 @@ function Ld(t) { }); }), n; } -var bo = {}, Zi = { exports: {} }; +var bo = {}, Yi = { exports: {} }; (function(t) { function e(n) { return n && n.__esModule ? n : { @@ -3679,8 +3608,8 @@ var bo = {}, Zi = { exports: {} }; }; } t.exports = e, t.exports.__esModule = !0, t.exports.default = t.exports; -})(Zi); -var Fd = Zi.exports, Ar = {}; +})(Yi); +var Dd = Yi.exports, Ar = {}; function vo(t, e) { return process.env.NODE_ENV === "production" ? () => null : function(...r) { return t(...r) || e(...r); @@ -3702,12 +3631,12 @@ function he(t) { const e = Object.getPrototypeOf(t); return (e === null || e === Object.prototype || Object.getPrototypeOf(e) === null) && !(Symbol.toStringTag in t) && !(Symbol.iterator in t); } -function Qi(t) { +function Wi(t) { if (!he(t)) return t; const e = {}; return Object.keys(t).forEach((n) => { - e[n] = Qi(t[n]); + e[n] = Wi(t[n]); }), e; } function Zt(t, e, n = { @@ -3715,7 +3644,7 @@ function Zt(t, e, n = { }) { const r = n.clone ? P({}, t) : t; return he(t) && he(e) && Object.keys(e).forEach((o) => { - o !== "__proto__" && (he(e[o]) && o in t && he(t[o]) ? r[o] = Zt(t[o], e[o], n) : n.clone ? r[o] = he(e[o]) ? Qi(e[o]) : e[o] : r[o] = e[o]); + o !== "__proto__" && (he(e[o]) && o in t && he(t[o]) ? r[o] = Zt(t[o], e[o], n) : n.clone ? r[o] = he(e[o]) ? Wi(e[o]) : e[o] : r[o] = e[o]); }), r; } var Qr = { exports: {} }, jn = { exports: {} }, it = {}; @@ -3728,7 +3657,7 @@ var Qr = { exports: {} }, jn = { exports: {} }, it = {}; * LICENSE file in the root directory of this source tree. */ var sa; -function Ud() { +function Bd() { if (sa) return it; sa = 1; @@ -3804,7 +3733,7 @@ var st = {}; * LICENSE file in the root directory of this source tree. */ var la; -function Gd() { +function jd() { return la || (la = 1, process.env.NODE_ENV !== "production" && function() { var t = typeof Symbol == "function" && Symbol.for, e = t ? Symbol.for("react.element") : 60103, n = t ? Symbol.for("react.portal") : 60106, r = t ? Symbol.for("react.fragment") : 60107, o = t ? Symbol.for("react.strict_mode") : 60108, a = t ? Symbol.for("react.profiler") : 60114, i = t ? Symbol.for("react.provider") : 60109, l = t ? Symbol.for("react.context") : 60110, c = t ? Symbol.for("react.async_mode") : 60111, d = t ? Symbol.for("react.concurrent_mode") : 60111, p = t ? Symbol.for("react.forward_ref") : 60112, h = t ? Symbol.for("react.suspense") : 60113, w = t ? Symbol.for("react.suspense_list") : 60120, g = t ? Symbol.for("react.memo") : 60115, v = t ? Symbol.for("react.lazy") : 60116, f = t ? Symbol.for("react.block") : 60121, m = t ? Symbol.for("react.fundamental") : 60117, E = t ? Symbol.for("react.responder") : 60118, _ = t ? Symbol.for("react.scope") : 60119; function C(A) { @@ -3887,8 +3816,8 @@ function Gd() { }()), st; } var ca; -function ts() { - return ca || (ca = 1, process.env.NODE_ENV === "production" ? jn.exports = Ud() : jn.exports = Gd()), jn.exports; +function qi() { + return ca || (ca = 1, process.env.NODE_ENV === "production" ? jn.exports = Bd() : jn.exports = jd()), jn.exports; } /* object-assign @@ -3896,7 +3825,7 @@ object-assign @license MIT */ var Mr, da; -function Hd() { +function Vd() { if (da) return Mr; da = 1; @@ -3951,18 +3880,18 @@ function yo() { return Dr = t, Dr; } var Br, ua; -function es() { +function Ki() { return ua || (ua = 1, Br = Function.call.bind(Object.prototype.hasOwnProperty)), Br; } var jr, wa; -function Xd() { +function zd() { if (wa) return jr; wa = 1; var t = function() { }; if (process.env.NODE_ENV !== "production") { - var e = yo(), n = {}, r = es(); + var e = yo(), n = {}, r = Ki(); t = function(a) { var i = "Warning: " + a; typeof console < "u" && console.error(i); @@ -4005,11 +3934,11 @@ function Xd() { }, jr = o, jr; } var Vr, fa; -function Yd() { +function Ld() { if (fa) return Vr; fa = 1; - var t = ts(), e = Hd(), n = yo(), r = es(), o = Xd(), a = function() { + var t = qi(), e = Vd(), n = yo(), r = Ki(), o = zd(), a = function() { }; process.env.NODE_ENV !== "production" && (a = function(l) { var c = "Warning: " + l; @@ -4327,7 +4256,7 @@ Valid keys: ` + JSON.stringify(Object.keys(y), null, " ") }, Vr; } var zr, ma; -function Wd() { +function Fd() { if (ma) return zr; ma = 1; @@ -4376,19 +4305,19 @@ function Wd() { }, zr; } if (process.env.NODE_ENV !== "production") { - var qd = ts(), Kd = !0; - Qr.exports = Yd()(qd.isElement, Kd); + var Ud = qi(), Gd = !0; + Qr.exports = Ld()(Ud.isElement, Gd); } else - Qr.exports = Wd()(); -var Jd = Qr.exports; -const u = /* @__PURE__ */ zd(Jd); -function Zd(t) { + Qr.exports = Fd()(); +var Hd = Qr.exports; +const u = /* @__PURE__ */ Ad(Hd); +function Xd(t) { const { prototype: e = {} } = t; return !!e.isReactComponent; } -function ns(t, e, n, r, o) { +function Ji(t, e, n, r, o) { const a = t[e], i = o || e; if (a == null || // When server-side rendering React doesn't warn either. // This is not an accurate check for SSR. @@ -4398,14 +4327,14 @@ function ns(t, e, n, r, o) { return null; let l; const c = a.type; - return typeof c == "function" && !Zd(c) && (l = "Did you accidentally use a plain function component for an element instead?"), l !== void 0 ? new Error(`Invalid ${r} \`${i}\` supplied to \`${n}\`. Expected an element that can hold a ref. ${l} For more information see https://mui.com/r/caveat-with-refs-guide`) : null; + return typeof c == "function" && !Xd(c) && (l = "Did you accidentally use a plain function component for an element instead?"), l !== void 0 ? new Error(`Invalid ${r} \`${i}\` supplied to \`${n}\`. Expected an element that can hold a ref. ${l} For more information see https://mui.com/r/caveat-with-refs-guide`) : null; } -const rs = vo(u.element, ns); -rs.isRequired = vo(u.element.isRequired, ns); -const os = rs, Qd = "exact-prop: ​"; -function tp(t) { +const Zi = vo(u.element, Ji); +Zi.isRequired = vo(u.element.isRequired, Ji); +const Qi = Zi, Yd = "exact-prop: ​"; +function Wd(t) { return process.env.NODE_ENV === "production" ? t : P({}, t, { - [Qd]: (e) => { + [Yd]: (e) => { const n = Object.keys(e).filter((r) => !t.hasOwnProperty(r)); return n.length > 0 ? new Error(`The following props are not supported: ${n.map((r) => `\`${r}\``).join(", ")}. Please remove them.`) : null; } @@ -4428,7 +4357,7 @@ var to = { exports: {} }, lt = {}; * LICENSE file in the root directory of this source tree. */ var ha; -function ep() { +function qd() { if (ha) return lt; ha = 1; @@ -4507,7 +4436,7 @@ var ct = {}; * LICENSE file in the root directory of this source tree. */ var ga; -function np() { +function Kd() { return ga || (ga = 1, process.env.NODE_ENV !== "production" && function() { var t = Symbol.for("react.element"), e = Symbol.for("react.portal"), n = Symbol.for("react.fragment"), r = Symbol.for("react.strict_mode"), o = Symbol.for("react.profiler"), a = Symbol.for("react.provider"), i = Symbol.for("react.context"), l = Symbol.for("react.server_context"), c = Symbol.for("react.forward_ref"), d = Symbol.for("react.suspense"), p = Symbol.for("react.suspense_list"), h = Symbol.for("react.memo"), w = Symbol.for("react.lazy"), g = Symbol.for("react.offscreen"), v = !1, f = !1, m = !1, E = !1, _ = !1, C; C = Symbol.for("react.module.reference"); @@ -4596,26 +4525,26 @@ function np() { ct.ContextConsumer = I, ct.ContextProvider = z, ct.Element = H, ct.ForwardRef = O, ct.Fragment = $, ct.Lazy = k, ct.Memo = B, ct.Portal = D, ct.Profiler = J, ct.StrictMode = q, ct.Suspense = U, ct.SuspenseList = tt, ct.isAsyncMode = y, ct.isConcurrentMode = R, ct.isContextConsumer = L, ct.isContextProvider = F, ct.isElement = V, ct.isForwardRef = W, ct.isFragment = X, ct.isLazy = Y, ct.isMemo = G, ct.isPortal = K, ct.isProfiler = Z, ct.isStrictMode = dt, ct.isSuspense = A, ct.isSuspenseList = Nt, ct.isValidElementType = S, ct.typeOf = b; }()), ct; } -process.env.NODE_ENV === "production" ? to.exports = ep() : to.exports = np(); +process.env.NODE_ENV === "production" ? to.exports = qd() : to.exports = Kd(); var ba = to.exports; -const rp = /^\s*function(?:\s|\s*\/\*.*\*\/\s*)+([^(\s/]*)\s*/; -function op(t) { - const e = `${t}`.match(rp); +const Jd = /^\s*function(?:\s|\s*\/\*.*\*\/\s*)+([^(\s/]*)\s*/; +function Zd(t) { + const e = `${t}`.match(Jd); return e && e[1] || ""; } -function as(t, e = "") { - return t.displayName || t.name || op(t) || e; +function ts(t, e = "") { + return t.displayName || t.name || Zd(t) || e; } function va(t, e, n) { - const r = as(e); + const r = ts(e); return t.displayName || (r !== "" ? `${n}(${r})` : n); } -function ap(t) { +function Qd(t) { if (t != null) { if (typeof t == "string") return t; if (typeof t == "function") - return as(t, "Component"); + return ts(t, "Component"); if (typeof t == "object") switch (t.$$typeof) { case ba.ForwardRef: @@ -4633,19 +4562,19 @@ function yn(t, e, n, r, o) { const a = t[e], i = o || e; return a == null ? null : a && a.nodeType !== 1 ? new Error(`Invalid ${r} \`${i}\` supplied to \`${n}\`. Expected an HTMLElement.`) : null; } -const ip = u.oneOfType([u.func, u.object]), is = ip; +const tp = u.oneOfType([u.func, u.object]), es = tp; function Wt(t) { if (typeof t != "string") throw new Error(process.env.NODE_ENV !== "production" ? "MUI: `capitalize(string)` expects a string argument." : Ve(7)); return t.charAt(0).toUpperCase() + t.slice(1); } -function sp(...t) { +function ep(...t) { return t.reduce((e, n) => n == null ? e : function(...o) { e.apply(this, o), n.apply(this, o); }, () => { }); } -function lp(t, e = 166) { +function np(t, e = 166) { let n; function r(...o) { const a = () => { @@ -4657,13 +4586,13 @@ function lp(t, e = 166) { clearTimeout(n); }, r; } -function cp(t, e) { +function rp(t, e) { return process.env.NODE_ENV === "production" ? () => null : (n, r, o, a, i) => { const l = o || "<>", c = i || r; return typeof n[r] < "u" ? new Error(`The ${a} \`${c}\` of \`${l}\` is deprecated. ${e}`) : null; }; } -function dp(t, e) { +function op(t, e) { var n, r; return /* @__PURE__ */ M.isValidElement(t) && e.indexOf( // For server components `muiName` is avaialble in element.type._payload.value.muiName @@ -4675,10 +4604,10 @@ function dp(t, e) { function Yn(t) { return t && t.ownerDocument || document; } -function pp(t) { +function ap(t) { return Yn(t).defaultView || window; } -function up(t, e) { +function ip(t, e) { if (process.env.NODE_ENV === "production") return () => null; const n = e ? P({}, e.propTypes) : null; @@ -4695,29 +4624,29 @@ function up(t, e) { function Wn(t, e) { typeof t == "function" ? t(e) : t && (t.current = e); } -const wp = typeof window < "u" ? M.useLayoutEffect : M.useEffect, ze = wp; +const sp = typeof window < "u" ? M.useLayoutEffect : M.useEffect, ze = sp; let ya = 0; -function fp(t) { +function lp(t) { const [e, n] = M.useState(t), r = t || e; return M.useEffect(() => { e == null && (ya += 1, n(`mui-${ya}`)); }, [e]), r; } const xa = M["useId".toString()]; -function ss(t) { +function ns(t) { if (xa !== void 0) { const e = xa(); return t ?? e; } - return fp(t); + return lp(t); } -function mp(t, e, n, r, o) { +function cp(t, e, n, r, o) { if (process.env.NODE_ENV === "production") return null; const a = o || e; return typeof t[e] < "u" ? new Error(`The prop \`${a}\` is not supported. Please remove it.`) : null; } -function ls({ +function rs({ controlled: t, default: e, name: n, @@ -4761,13 +4690,13 @@ function xe(...t) { }, t); } const Na = {}; -function hp(t, e) { +function dp(t, e) { const n = M.useRef(Na); return n.current === Na && (n.current = t(e)), n; } -const gp = []; -function bp(t) { - M.useEffect(t, gp); +const pp = []; +function up(t) { + M.useEffect(t, pp); } class Tn { constructor() { @@ -4788,11 +4717,11 @@ class Tn { } } function sn() { - const t = hp(Tn.create).current; - return bp(t.disposeEffect), t; + const t = dp(Tn.create).current; + return up(t.disposeEffect), t; } let dr = !0, no = !1; -const vp = new Tn(), yp = { +const wp = new Tn(), fp = { text: !0, search: !0, url: !0, @@ -4807,26 +4736,26 @@ const vp = new Tn(), yp = { datetime: !0, "datetime-local": !0 }; -function xp(t) { +function mp(t) { const { type: e, tagName: n } = t; - return !!(n === "INPUT" && yp[e] && !t.readOnly || n === "TEXTAREA" && !t.readOnly || t.isContentEditable); + return !!(n === "INPUT" && fp[e] && !t.readOnly || n === "TEXTAREA" && !t.readOnly || t.isContentEditable); } -function Np(t) { +function hp(t) { t.metaKey || t.altKey || t.ctrlKey || (dr = !0); } function Lr() { dr = !1; } -function kp() { +function gp() { this.visibilityState === "hidden" && no && (dr = !0); } -function Ep(t) { - t.addEventListener("keydown", Np, !0), t.addEventListener("mousedown", Lr, !0), t.addEventListener("pointerdown", Lr, !0), t.addEventListener("touchstart", Lr, !0), t.addEventListener("visibilitychange", kp, !0); +function bp(t) { + t.addEventListener("keydown", hp, !0), t.addEventListener("mousedown", Lr, !0), t.addEventListener("pointerdown", Lr, !0), t.addEventListener("touchstart", Lr, !0), t.addEventListener("visibilitychange", gp, !0); } -function Sp(t) { +function vp(t) { const { target: e } = t; @@ -4834,19 +4763,19 @@ function Sp(t) { return e.matches(":focus-visible"); } catch { } - return dr || xp(e); + return dr || mp(e); } -function cs() { +function os() { const t = M.useCallback((o) => { - o != null && Ep(o.ownerDocument); + o != null && bp(o.ownerDocument); }, []), e = M.useRef(!1); function n() { - return e.current ? (no = !0, vp.start(100, () => { + return e.current ? (no = !0, wp.start(100, () => { no = !1; }), e.current = !1, !0) : !1; } function r(o) { - return Sp(o) ? (e.current = !0, !0) : !1; + return vp(o) ? (e.current = !0, !0) : !1; } return { isFocusVisibleRef: e, @@ -4855,7 +4784,7 @@ function cs() { ref: t }; } -function ds(t, e) { +function as(t, e) { const n = P({}, e); return Object.keys(t).forEach((r) => { if (r.toString().match(/^(components|slots)$/)) @@ -4863,7 +4792,7 @@ function ds(t, e) { else if (r.toString().match(/^(componentsProps|slotProps)$/)) { const o = t[r] || {}, a = e[r]; n[r] = {}, !a || !Object.keys(a) ? n[r] = o : !o || !Object.keys(o) ? n[r] = a : (n[r] = P({}, a), Object.keys(o).forEach((i) => { - n[r][i] = ds(o[i], a[i]); + n[r][i] = as(o[i], a[i]); })); } else n[r] === void 0 && (n[r] = t[r]); @@ -4885,7 +4814,7 @@ function xo(t, e, n = void 0) { } ), r; } -const ka = (t) => t, Tp = () => { +const ka = (t) => t, yp = () => { let t = ka; return { configure(e) { @@ -4898,7 +4827,7 @@ const ka = (t) => t, Tp = () => { t = ka; } }; -}, Cp = Tp(), ps = Cp, us = { +}, xp = yp(), is = xp, ss = { active: "active", checked: "checked", completed: "completed", @@ -4913,16 +4842,16 @@ const ka = (t) => t, Tp = () => { selected: "selected" }; function pr(t, e, n = "Mui") { - const r = us[e]; - return r ? `${n}-${r}` : `${ps.generate(t)}-${e}`; + const r = ss[e]; + return r ? `${n}-${r}` : `${is.generate(t)}-${e}`; } -function ws(t, e, n = "Mui") { +function ls(t, e, n = "Mui") { const r = {}; return e.forEach((o) => { r[o] = pr(t, o, n); }), r; } -function Op(t, e = Number.MIN_SAFE_INTEGER, n = Number.MAX_SAFE_INTEGER) { +function Np(t, e = Number.MIN_SAFE_INTEGER, n = Number.MAX_SAFE_INTEGER) { return Math.max(e, Math.min(t, n)); } function kt(t, e) { @@ -4933,7 +4862,7 @@ function kt(t, e) { o = r[a], !(e.indexOf(o) >= 0) && (n[o] = t[o]); return n; } -const Rp = ["values", "unit", "step"], _p = (t) => { +const kp = ["values", "unit", "step"], Ep = (t) => { const e = Object.keys(t).map((n) => ({ key: n, val: t[n] @@ -4942,7 +4871,7 @@ const Rp = ["values", "unit", "step"], _p = (t) => { [r.key]: r.val }), {}); }; -function Pp(t) { +function Sp(t) { const { // The breakpoint **start** at this value. // For instance with the first breakpoint xs: [xs, sm). @@ -4960,7 +4889,7 @@ function Pp(t) { }, unit: n = "px", step: r = 5 - } = t, o = kt(t, Rp), a = _p(e), i = Object.keys(a); + } = t, o = kt(t, kp), a = Ep(e), i = Object.keys(a); function l(w) { return `@media (min-width:${typeof e[w] == "number" ? e[w] : w}${n})`; } @@ -4989,9 +4918,9 @@ function Pp(t) { unit: n }, o); } -const $p = { +const Tp = { borderRadius: 4 -}, Ip = $p, Ap = process.env.NODE_ENV !== "production" ? u.oneOfType([u.number, u.string, u.object, u.array]) : {}, se = Ap; +}, Cp = Tp, Op = process.env.NODE_ENV !== "production" ? u.oneOfType([u.number, u.string, u.object, u.array]) : {}, se = Op; function un(t, e) { return e ? Zt(t, e, { clone: !1 @@ -5036,14 +4965,14 @@ function Qt(t, e, n) { } return n(e); } -function Mp(t = {}) { +function Rp(t = {}) { var e; return ((e = t.keys) == null ? void 0 : e.reduce((r, o) => { const a = t.up(o); return r[a] = {}, r; }, {})) || {}; } -function Dp(t, e) { +function _p(t, e) { return t.reduce((n, r) => { const o = n[r]; return (!o || Object.keys(o).length === 0) && delete n[r], n; @@ -5084,14 +5013,14 @@ function yt(t) { [e]: se } : {}, a.filterProps = [e], a; } -function Bp(t) { +function Pp(t) { const e = {}; return (n) => (e[n] === void 0 && (e[n] = t(n)), e[n]); } -const jp = { +const $p = { m: "margin", p: "padding" -}, Vp = { +}, Ip = { t: "Top", r: "Right", b: "Bottom", @@ -5103,15 +5032,15 @@ const jp = { marginY: "my", paddingX: "px", paddingY: "py" -}, zp = Bp((t) => { +}, Ap = Pp((t) => { if (t.length > 2) if (Sa[t]) t = Sa[t]; else return [t]; - const [e, n] = t.split(""), r = jp[e], o = Vp[n] || ""; + const [e, n] = t.split(""), r = $p[e], o = Ip[n] || ""; return Array.isArray(o) ? o.map((a) => r + a) : [r + o]; -}), wr = ["m", "mt", "mr", "mb", "ml", "mx", "my", "margin", "marginTop", "marginRight", "marginBottom", "marginLeft", "marginX", "marginY", "marginInline", "marginInlineStart", "marginInlineEnd", "marginBlock", "marginBlockStart", "marginBlockEnd"], fr = ["p", "pt", "pr", "pb", "pl", "px", "py", "padding", "paddingTop", "paddingRight", "paddingBottom", "paddingLeft", "paddingX", "paddingY", "paddingInline", "paddingInlineStart", "paddingInlineEnd", "paddingBlock", "paddingBlockStart", "paddingBlockEnd"], Lp = [...wr, ...fr]; +}), wr = ["m", "mt", "mr", "mb", "ml", "mx", "my", "margin", "marginTop", "marginRight", "marginBottom", "marginLeft", "marginX", "marginY", "marginInline", "marginInlineStart", "marginInlineEnd", "marginBlock", "marginBlockStart", "marginBlockEnd"], fr = ["p", "pt", "pr", "pb", "pl", "px", "py", "padding", "paddingTop", "paddingRight", "paddingBottom", "paddingLeft", "paddingX", "paddingY", "paddingInline", "paddingInlineStart", "paddingInlineEnd", "paddingBlock", "paddingBlockStart", "paddingBlockEnd"], Mp = [...wr, ...fr]; function Cn(t, e, n, r) { var o; const a = (o = ur(t, e, !1)) != null ? o : n; @@ -5121,7 +5050,7 @@ function Cn(t, e, n, r) { `)), () => { }); } -function fs(t) { +function cs(t) { return Cn(t, "spacing", 8, "spacing"); } function On(t, e) { @@ -5130,34 +5059,34 @@ function On(t, e) { const n = Math.abs(e), r = t(n); return e >= 0 ? r : typeof r == "number" ? -r : `-${r}`; } -function Fp(t, e) { +function Dp(t, e) { return (n) => t.reduce((r, o) => (r[o] = On(e, n), r), {}); } -function Up(t, e, n, r) { +function Bp(t, e, n, r) { if (e.indexOf(n) === -1) return null; - const o = zp(n), a = Fp(o, r), i = t[n]; + const o = Ap(n), a = Dp(o, r), i = t[n]; return Qt(t, i, a); } -function ms(t, e) { - const n = fs(t.theme); - return Object.keys(t).map((r) => Up(t, e, r, n)).reduce(un, {}); +function ds(t, e) { + const n = cs(t.theme); + return Object.keys(t).map((r) => Bp(t, e, r, n)).reduce(un, {}); } function mt(t) { - return ms(t, wr); + return ds(t, wr); } mt.propTypes = process.env.NODE_ENV !== "production" ? wr.reduce((t, e) => (t[e] = se, t), {}) : {}; mt.filterProps = wr; function ht(t) { - return ms(t, fr); + return ds(t, fr); } ht.propTypes = process.env.NODE_ENV !== "production" ? fr.reduce((t, e) => (t[e] = se, t), {}) : {}; ht.filterProps = fr; -process.env.NODE_ENV !== "production" && Lp.reduce((t, e) => (t[e] = se, t), {}); -function Gp(t = 8) { +process.env.NODE_ENV !== "production" && Mp.reduce((t, e) => (t[e] = se, t), {}); +function jp(t = 8) { if (t.mui) return t; - const e = fs({ + const e = cs({ spacing: t }), n = (...r) => (process.env.NODE_ENV !== "production" && (r.length <= 4 || console.error(`MUI: Too many arguments provided, expected between 0 and 4, got ${r.length}`)), (r.length === 0 ? [1] : r).map((a) => { const i = e(a); @@ -5181,7 +5110,7 @@ function Lt(t, e) { transform: e }); } -const Hp = Lt("border", Bt), Xp = Lt("borderTop", Bt), Yp = Lt("borderRight", Bt), Wp = Lt("borderBottom", Bt), qp = Lt("borderLeft", Bt), Kp = Lt("borderColor"), Jp = Lt("borderTopColor"), Zp = Lt("borderRightColor"), Qp = Lt("borderBottomColor"), tu = Lt("borderLeftColor"), eu = Lt("outline", Bt), nu = Lt("outlineColor"), hr = (t) => { +const Vp = Lt("border", Bt), zp = Lt("borderTop", Bt), Lp = Lt("borderRight", Bt), Fp = Lt("borderBottom", Bt), Up = Lt("borderLeft", Bt), Gp = Lt("borderColor"), Hp = Lt("borderTopColor"), Xp = Lt("borderRightColor"), Yp = Lt("borderBottomColor"), Wp = Lt("borderLeftColor"), qp = Lt("outline", Bt), Kp = Lt("outlineColor"), hr = (t) => { if (t.borderRadius !== void 0 && t.borderRadius !== null) { const e = Cn(t.theme, "shape.borderRadius", 4, "borderRadius"), n = (r) => ({ borderRadius: On(e, r) @@ -5194,7 +5123,7 @@ hr.propTypes = process.env.NODE_ENV !== "production" ? { borderRadius: se } : {}; hr.filterProps = ["borderRadius"]; -mr(Hp, Xp, Yp, Wp, qp, Kp, Jp, Zp, Qp, tu, hr, eu, nu); +mr(Vp, zp, Lp, Fp, Up, Gp, Hp, Xp, Yp, Wp, hr, qp, Kp); const gr = (t) => { if (t.gap !== void 0 && t.gap !== null) { const e = Cn(t.theme, "spacing", 8, "gap"), n = (r) => ({ @@ -5234,48 +5163,48 @@ vr.propTypes = process.env.NODE_ENV !== "production" ? { rowGap: se } : {}; vr.filterProps = ["rowGap"]; -const ru = yt({ +const Jp = yt({ prop: "gridColumn" -}), ou = yt({ +}), Zp = yt({ prop: "gridRow" -}), au = yt({ +}), Qp = yt({ prop: "gridAutoFlow" -}), iu = yt({ +}), tu = yt({ prop: "gridAutoColumns" -}), su = yt({ +}), eu = yt({ prop: "gridAutoRows" -}), lu = yt({ +}), nu = yt({ prop: "gridTemplateColumns" -}), cu = yt({ +}), ru = yt({ prop: "gridTemplateRows" -}), du = yt({ +}), ou = yt({ prop: "gridTemplateAreas" -}), pu = yt({ +}), au = yt({ prop: "gridArea" }); -mr(gr, br, vr, ru, ou, au, iu, su, lu, cu, du, pu); +mr(gr, br, vr, Jp, Zp, Qp, tu, eu, nu, ru, ou, au); function Me(t, e) { return e === "grey" ? e : t; } -const uu = yt({ +const iu = yt({ prop: "color", themeKey: "palette", transform: Me -}), wu = yt({ +}), su = yt({ prop: "bgcolor", cssProperty: "backgroundColor", themeKey: "palette", transform: Me -}), fu = yt({ +}), lu = yt({ prop: "backgroundColor", themeKey: "palette", transform: Me }); -mr(uu, wu, fu); +mr(iu, su, lu); function At(t) { return t <= 1 && t !== 0 ? `${t * 100}%` : t; } -const mu = yt({ +const cu = yt({ prop: "width", transform: At }), ko = (t) => { @@ -5296,16 +5225,16 @@ const mu = yt({ return null; }; ko.filterProps = ["maxWidth"]; -const hu = yt({ +const du = yt({ prop: "minWidth", transform: At -}), gu = yt({ +}), pu = yt({ prop: "height", transform: At -}), bu = yt({ +}), uu = yt({ prop: "maxHeight", transform: At -}), vu = yt({ +}), wu = yt({ prop: "minHeight", transform: At }); @@ -5319,11 +5248,11 @@ yt({ cssProperty: "height", transform: At }); -const yu = yt({ +const fu = yt({ prop: "boxSizing" }); -mr(mu, ko, hu, gu, bu, vu, yu); -const xu = { +mr(cu, ko, du, pu, uu, wu, fu); +const mu = { // borders border: { themeKey: "borders", @@ -5607,15 +5536,15 @@ const xu = { cssProperty: !1, themeKey: "typography" } -}, Eo = xu; -function Nu(...t) { +}, Eo = mu; +function hu(...t) { const e = t.reduce((r, o) => r.concat(Object.keys(o)), []), n = new Set(e); return t.every((r) => n.size === Object.keys(r).length); } -function ku(t, e) { +function gu(t, e) { return typeof t == "function" ? t(e) : t; } -function Eu() { +function bu() { function t(n, r, o, a) { const i = { [n]: r, @@ -5662,10 +5591,10 @@ function Eu() { return c; if (!d) return null; - const p = Mp(a.breakpoints), h = Object.keys(p); + const p = Rp(a.breakpoints), h = Object.keys(p); let w = p; return Object.keys(d).forEach((g) => { - const v = ku(d[g], a); + const v = gu(d[g], a); if (v != null) if (typeof v == "object") if (i[g]) @@ -5676,36 +5605,36 @@ function Eu() { }, v, (m) => ({ [g]: m })); - Nu(f, v) ? w[g] = e({ + hu(f, v) ? w[g] = e({ sx: v, theme: a }) : w = un(w, f); } else w = un(w, t(g, v, a, i)); - }), Dp(h, w); + }), _p(h, w); } return Array.isArray(o) ? o.map(l) : l(o); } return e; } -const hs = Eu(); -hs.filterProps = ["sx"]; -const So = hs; -function Su(t, e) { +const ps = bu(); +ps.filterProps = ["sx"]; +const So = ps; +function vu(t, e) { const n = this; return n.vars && typeof n.getColorSchemeSelector == "function" ? { [n.getColorSchemeSelector(t).replace(/(\[[^\]]+\])/, "*:where($1)")]: e } : n.palette.mode === t ? e : {}; } -const Tu = ["breakpoints", "palette", "spacing", "shape"]; +const yu = ["breakpoints", "palette", "spacing", "shape"]; function To(t = {}, ...e) { const { breakpoints: n = {}, palette: r = {}, spacing: o, shape: a = {} - } = t, i = kt(t, Tu), l = Pp(n), c = Gp(o); + } = t, i = kt(t, yu), l = Sp(n), c = jp(o); let d = Zt({ breakpoints: l, direction: "ltr", @@ -5715,31 +5644,31 @@ function To(t = {}, ...e) { mode: "light" }, r), spacing: c, - shape: P({}, Ip, a) + shape: P({}, Cp, a) }, i); - return d.applyStyles = Su, d = e.reduce((p, h) => Zt(p, h), d), d.unstable_sxConfig = P({}, Eo, i == null ? void 0 : i.unstable_sxConfig), d.unstable_sx = function(h) { + return d.applyStyles = vu, d = e.reduce((p, h) => Zt(p, h), d), d.unstable_sxConfig = P({}, Eo, i == null ? void 0 : i.unstable_sxConfig), d.unstable_sx = function(h) { return So({ sx: h, theme: this }); }, d; } -function Cu(t) { +function xu(t) { return Object.keys(t).length === 0; } -function gs(t = null) { - const e = M.useContext(zl); - return !e || Cu(e) ? t : e; +function us(t = null) { + const e = M.useContext(Ml); + return !e || xu(e) ? t : e; } -const Ou = To(); -function bs(t = Ou) { - return gs(t); +const Nu = To(); +function ws(t = Nu) { + return us(t); } -const Ru = ["ownerState"], _u = ["variants"], Pu = ["name", "slot", "skipVariantsResolver", "skipSx", "overridesResolver"]; -function $u(t) { +const ku = ["ownerState"], Eu = ["variants"], Su = ["name", "slot", "skipVariantsResolver", "skipSx", "overridesResolver"]; +function Tu(t) { return Object.keys(t).length === 0; } -function Iu(t) { +function Cu(t) { return typeof t == "string" && // 96 is one less than the char code // for "a" so this is checking that // it's a lowercase character @@ -5748,21 +5677,21 @@ function Iu(t) { function Gn(t) { return t !== "ownerState" && t !== "theme" && t !== "sx" && t !== "as"; } -const Au = To(), Ta = (t) => t && t.charAt(0).toLowerCase() + t.slice(1); +const Ou = To(), Ta = (t) => t && t.charAt(0).toLowerCase() + t.slice(1); function Vn({ defaultTheme: t, theme: e, themeId: n }) { - return $u(e) ? t : e[n] || e; + return Tu(e) ? t : e[n] || e; } -function Mu(t) { +function Ru(t) { return t ? (e, n) => n[t] : null; } function Hn(t, e) { let { ownerState: n - } = e, r = kt(e, Ru); + } = e, r = kt(e, ku); const o = typeof t == "function" ? t(P({ ownerState: n }, r)) : t; @@ -5774,7 +5703,7 @@ function Hn(t, e) { const { variants: a = [] } = o; - let l = kt(o, _u); + let l = kt(o, Eu); return a.forEach((c) => { let d = !0; typeof c.props == "function" ? d = c.props(P({ @@ -5788,10 +5717,10 @@ function Hn(t, e) { } return o; } -function Du(t = {}) { +function _u(t = {}) { const { themeId: e, - defaultTheme: n = Au, + defaultTheme: n = Ou, rootShouldForwardProp: r = Gn, slotShouldForwardProp: o = Gn } = t, a = (i) => So(P({}, i, { @@ -5801,7 +5730,7 @@ function Du(t = {}) { })) })); return a.__mui_systemSx = !0, (i, l = {}) => { - Ll(i, (b) => b.filter((I) => !(I != null && I.__mui_systemSx))); + Dl(i, (b) => b.filter((I) => !(I != null && I.__mui_systemSx))); const { name: c, slot: d, @@ -5809,8 +5738,8 @@ function Du(t = {}) { skipSx: h, // TODO v6: remove `lowercaseFirstLetter()` in the next major release // For more details: https://github.com/mui/material-ui/pull/37908 - overridesResolver: w = Mu(Ta(d)) - } = l, g = kt(l, Pu), v = p !== void 0 ? p : ( + overridesResolver: w = Ru(Ta(d)) + } = l, g = kt(l, Su), v = p !== void 0 ? p : ( // TODO v6: remove `Root` in the next major release // For more details: https://github.com/mui/material-ui/pull/37908 d && d !== "Root" && d !== "root" || !1 @@ -5818,8 +5747,8 @@ function Du(t = {}) { let m; process.env.NODE_ENV !== "production" && c && (m = `${c}-${Ta(d || "Root")}`); let E = Gn; - d === "Root" || d === "root" ? E = r : d ? E = o : Iu(i) && (E = void 0); - const _ = Vl(i, P({ + d === "Root" || d === "root" ? E = r : d ? E = o : Cu(i) && (E = void 0); + const _ = Al(i, P({ shouldForwardProp: E, label: m }, g)), C = (b) => typeof b == "function" && b.__emotion_real !== b || he(b) ? (I) => Hn(b, P({}, I, { @@ -5864,38 +5793,38 @@ function Du(t = {}) { const $ = _(z, ...H); if (process.env.NODE_ENV !== "production") { let k; - c && (k = `${c}${Wt(d || "")}`), k === void 0 && (k = `Styled(${ap(i)})`), $.displayName = k; + c && (k = `${c}${Wt(d || "")}`), k === void 0 && (k = `Styled(${Qd(i)})`), $.displayName = k; } return i.muiName && ($.muiName = i.muiName), $; }; return _.withConfig && (S.withConfig = _.withConfig), S; }; } -function Bu(t) { +function Pu(t) { const { theme: e, name: n, props: r } = t; - return !e || !e.components || !e.components[n] || !e.components[n].defaultProps ? r : ds(e.components[n].defaultProps, r); + return !e || !e.components || !e.components[n] || !e.components[n].defaultProps ? r : as(e.components[n].defaultProps, r); } -function ju({ +function $u({ props: t, name: e, defaultTheme: n, themeId: r }) { - let o = bs(n); - return r && (o = o[r] || o), Bu({ + let o = ws(n); + return r && (o = o[r] || o), Pu({ theme: o, name: e, props: t }); } function Co(t, e = 0, n = 1) { - return process.env.NODE_ENV !== "production" && (t < e || t > n) && console.error(`MUI: The value provided ${t} is out of range [${e}, ${n}].`), Op(t, e, n); + return process.env.NODE_ENV !== "production" && (t < e || t > n) && console.error(`MUI: The value provided ${t} is out of range [${e}, ${n}].`), Np(t, e, n); } -function Vu(t) { +function Iu(t) { t = t.slice(1); const e = new RegExp(`.{1,${t.length >= 6 ? 2 : 1}}`, "g"); let n = t.match(e); @@ -5905,7 +5834,7 @@ function Ne(t) { if (t.type) return t; if (t.charAt(0) === "#") - return Ne(Vu(t)); + return Ne(Iu(t)); const e = t.indexOf("("), n = t.substring(0, e); if (["rgb", "rgba", "hsl", "hsla", "color"].indexOf(n) === -1) throw new Error(process.env.NODE_ENV !== "production" ? `MUI: Unsupported \`${t}\` color. @@ -5933,7 +5862,7 @@ function yr(t) { } = t; return e.indexOf("rgb") !== -1 ? r = r.map((o, a) => a < 3 ? parseInt(o, 10) : o) : e.indexOf("hsl") !== -1 && (r[1] = `${r[1]}%`, r[2] = `${r[2]}%`), e.indexOf("color") !== -1 ? r = `${n} ${r.join(" ")}` : r = `${r.join(", ")}`, `${e}(${r})`; } -function zu(t) { +function Au(t) { t = Ne(t); const { values: e @@ -5947,17 +5876,17 @@ function zu(t) { } function Ca(t) { t = Ne(t); - let e = t.type === "hsl" || t.type === "hsla" ? Ne(zu(t)).values : t.values; + let e = t.type === "hsl" || t.type === "hsla" ? Ne(Au(t)).values : t.values; return e = e.map((n) => (t.type !== "color" && (n /= 255), n <= 0.03928 ? n / 12.92 : ((n + 0.055) / 1.055) ** 2.4)), Number((0.2126 * e[0] + 0.7152 * e[1] + 0.0722 * e[2]).toFixed(3)); } function Oa(t, e) { const n = Ca(t), r = Ca(e); return (Math.max(n, r) + 0.05) / (Math.min(n, r) + 0.05); } -function vs(t, e) { +function fs(t, e) { return t = Ne(t), e = Co(e), (t.type === "rgb" || t.type === "hsl") && (t.type += "a"), t.type === "color" ? t.values[3] = `/${e}` : t.values[3] = e, yr(t); } -function Lu(t, e) { +function Mu(t, e) { if (t = Ne(t), e = Co(e), t.type.indexOf("hsl") !== -1) t.values[2] *= 1 - e; else if (t.type.indexOf("rgb") !== -1 || t.type.indexOf("color") !== -1) @@ -5965,7 +5894,7 @@ function Lu(t, e) { t.values[n] *= 1 - e; return yr(t); } -function Fu(t, e) { +function Du(t, e) { if (t = Ne(t), e = Co(e), t.type.indexOf("hsl") !== -1) t.values[2] += (100 - t.values[2]) * e; else if (t.type.indexOf("rgb") !== -1) @@ -5976,7 +5905,7 @@ function Fu(t, e) { t.values[n] += (1 - t.values[n]) * e; return yr(t); } -function Uu(t, e) { +function Bu(t, e) { return P({ toolbar: { minHeight: 56, @@ -5991,10 +5920,10 @@ function Uu(t, e) { } }, e); } -const Gu = { +const ju = { black: "#000", white: "#fff" -}, xn = Gu, Hu = { +}, xn = ju, Vu = { 50: "#fafafa", 100: "#f5f5f5", 200: "#eeeeee", @@ -6009,7 +5938,7 @@ const Gu = { A200: "#eeeeee", A400: "#bdbdbd", A700: "#616161" -}, Xu = Hu, Yu = { +}, zu = Vu, Lu = { 50: "#f3e5f5", 100: "#e1bee7", 200: "#ce93d8", @@ -6024,7 +5953,7 @@ const Gu = { A200: "#e040fb", A400: "#d500f9", A700: "#aa00ff" -}, Oe = Yu, Wu = { +}, Oe = Lu, Fu = { 50: "#ffebee", 100: "#ffcdd2", 200: "#ef9a9a", @@ -6039,7 +5968,7 @@ const Gu = { A200: "#ff5252", A400: "#ff1744", A700: "#d50000" -}, Re = Wu, qu = { +}, Re = Fu, Uu = { 50: "#fff3e0", 100: "#ffe0b2", 200: "#ffcc80", @@ -6054,7 +5983,7 @@ const Gu = { A200: "#ffab40", A400: "#ff9100", A700: "#ff6d00" -}, nn = qu, Ku = { +}, nn = Uu, Gu = { 50: "#e3f2fd", 100: "#bbdefb", 200: "#90caf9", @@ -6069,7 +5998,7 @@ const Gu = { A200: "#448aff", A400: "#2979ff", A700: "#2962ff" -}, _e = Ku, Ju = { +}, _e = Gu, Hu = { 50: "#e1f5fe", 100: "#b3e5fc", 200: "#81d4fa", @@ -6084,7 +6013,7 @@ const Gu = { A200: "#40c4ff", A400: "#00b0ff", A700: "#0091ea" -}, Pe = Ju, Zu = { +}, Pe = Hu, Xu = { 50: "#e8f5e9", 100: "#c8e6c9", 200: "#a5d6a7", @@ -6099,7 +6028,7 @@ const Gu = { A200: "#69f0ae", A400: "#00e676", A700: "#00c853" -}, $e = Zu, Qu = ["mode", "contrastThreshold", "tonalOffset"], Ra = { +}, $e = Xu, Yu = ["mode", "contrastThreshold", "tonalOffset"], Ra = { // The colors used to style the text. text: { // The most important text. @@ -6164,9 +6093,9 @@ const Gu = { }; function _a(t, e, n, r) { const o = r.light || r, a = r.dark || r * 1.5; - t[e] || (t.hasOwnProperty(n) ? t[e] = t[n] : e === "light" ? t.light = Fu(t.main, o) : e === "dark" && (t.dark = Lu(t.main, a))); + t[e] || (t.hasOwnProperty(n) ? t[e] = t[n] : e === "light" ? t.light = Du(t.main, o) : e === "dark" && (t.dark = Mu(t.main, a))); } -function tw(t = "light") { +function Wu(t = "light") { return t === "dark" ? { main: _e[200], light: _e[50], @@ -6177,7 +6106,7 @@ function tw(t = "light") { dark: _e[800] }; } -function ew(t = "light") { +function qu(t = "light") { return t === "dark" ? { main: Oe[200], light: Oe[50], @@ -6188,7 +6117,7 @@ function ew(t = "light") { dark: Oe[700] }; } -function nw(t = "light") { +function Ku(t = "light") { return t === "dark" ? { main: Re[500], light: Re[300], @@ -6199,7 +6128,7 @@ function nw(t = "light") { dark: Re[800] }; } -function rw(t = "light") { +function Ju(t = "light") { return t === "dark" ? { main: Pe[400], light: Pe[300], @@ -6210,7 +6139,7 @@ function rw(t = "light") { dark: Pe[900] }; } -function ow(t = "light") { +function Zu(t = "light") { return t === "dark" ? { main: $e[400], light: $e[300], @@ -6221,7 +6150,7 @@ function ow(t = "light") { dark: $e[900] }; } -function aw(t = "light") { +function Qu(t = "light") { return t === "dark" ? { main: nn[400], light: nn[300], @@ -6233,12 +6162,12 @@ function aw(t = "light") { dark: nn[900] }; } -function iw(t) { +function tw(t) { const { mode: e = "light", contrastThreshold: n = 3, tonalOffset: r = 0.2 - } = t, o = kt(t, Qu), a = t.primary || tw(e), i = t.secondary || ew(e), l = t.error || nw(e), c = t.info || rw(e), d = t.success || ow(e), p = t.warning || aw(e); + } = t, o = kt(t, Yu), a = t.primary || Wu(e), i = t.secondary || qu(e), l = t.error || Ku(e), c = t.info || Ju(e), d = t.success || Zu(e), p = t.warning || Qu(e); function h(f) { const m = Oa(f, Fr.text.primary) >= n ? Fr.text.primary : Ra.text.primary; if (process.env.NODE_ENV !== "production") { @@ -6318,7 +6247,7 @@ const theme2 = createTheme({ palette: { name: "success" }), // The grey colors. - grey: Xu, + grey: zu, // Used by `getContrastText()` to maximize the contrast between // the background and the text. contrastThreshold: n, @@ -6332,14 +6261,14 @@ const theme2 = createTheme({ palette: { tonalOffset: r }, g[e]), o); } -const sw = ["fontFamily", "fontSize", "fontWeightLight", "fontWeightRegular", "fontWeightMedium", "fontWeightBold", "htmlFontSize", "allVariants", "pxToRem"]; -function lw(t) { +const ew = ["fontFamily", "fontSize", "fontWeightLight", "fontWeightRegular", "fontWeightMedium", "fontWeightBold", "htmlFontSize", "allVariants", "pxToRem"]; +function nw(t) { return Math.round(t * 1e5) / 1e5; } const Pa = { textTransform: "uppercase" }, $a = '"Roboto", "Helvetica", "Arial", sans-serif'; -function cw(t, e) { +function rw(t, e) { const n = typeof e == "function" ? e(t) : e, { fontFamily: r = $a, // The default font size of the Material Specification. @@ -6355,7 +6284,7 @@ function cw(t, e) { // Apply the CSS properties to all the variants. allVariants: p, pxToRem: h - } = n, w = kt(n, sw); + } = n, w = kt(n, ew); process.env.NODE_ENV !== "production" && (typeof o != "number" && console.error("MUI: `fontSize` is required to be a number."), typeof d != "number" && console.error("MUI: `htmlFontSize` is required to be a number.")); const g = o / 14, v = h || ((E) => `${E / d * g}rem`), f = (E, _, C, S, b) => P({ fontFamily: r, @@ -6364,7 +6293,7 @@ function cw(t, e) { // Unitless following https://meyerweb.com/eric/thoughts/2006/02/08/unitless-line-heights/ lineHeight: C }, r === $a ? { - letterSpacing: `${lw(S / _)}em` + letterSpacing: `${nw(S / _)}em` } : {}, b, p), m = { h1: f(a, 96, 1.167, -1.5), h2: f(a, 60, 1.2, -0.5), @@ -6402,11 +6331,11 @@ function cw(t, e) { // No need to clone deep }); } -const dw = 0.2, pw = 0.14, uw = 0.12; +const ow = 0.2, aw = 0.14, iw = 0.12; function ft(...t) { - return [`${t[0]}px ${t[1]}px ${t[2]}px ${t[3]}px rgba(0,0,0,${dw})`, `${t[4]}px ${t[5]}px ${t[6]}px ${t[7]}px rgba(0,0,0,${pw})`, `${t[8]}px ${t[9]}px ${t[10]}px ${t[11]}px rgba(0,0,0,${uw})`].join(","); + return [`${t[0]}px ${t[1]}px ${t[2]}px ${t[3]}px rgba(0,0,0,${ow})`, `${t[4]}px ${t[5]}px ${t[6]}px ${t[7]}px rgba(0,0,0,${aw})`, `${t[8]}px ${t[9]}px ${t[10]}px ${t[11]}px rgba(0,0,0,${iw})`].join(","); } -const ww = ["none", ft(0, 2, 1, -1, 0, 1, 1, 0, 0, 1, 3, 0), ft(0, 3, 1, -2, 0, 2, 2, 0, 0, 1, 5, 0), ft(0, 3, 3, -2, 0, 3, 4, 0, 0, 1, 8, 0), ft(0, 2, 4, -1, 0, 4, 5, 0, 0, 1, 10, 0), ft(0, 3, 5, -1, 0, 5, 8, 0, 0, 1, 14, 0), ft(0, 3, 5, -1, 0, 6, 10, 0, 0, 1, 18, 0), ft(0, 4, 5, -2, 0, 7, 10, 1, 0, 2, 16, 1), ft(0, 5, 5, -3, 0, 8, 10, 1, 0, 3, 14, 2), ft(0, 5, 6, -3, 0, 9, 12, 1, 0, 3, 16, 2), ft(0, 6, 6, -3, 0, 10, 14, 1, 0, 4, 18, 3), ft(0, 6, 7, -4, 0, 11, 15, 1, 0, 4, 20, 3), ft(0, 7, 8, -4, 0, 12, 17, 2, 0, 5, 22, 4), ft(0, 7, 8, -4, 0, 13, 19, 2, 0, 5, 24, 4), ft(0, 7, 9, -4, 0, 14, 21, 2, 0, 5, 26, 4), ft(0, 8, 9, -5, 0, 15, 22, 2, 0, 6, 28, 5), ft(0, 8, 10, -5, 0, 16, 24, 2, 0, 6, 30, 5), ft(0, 8, 11, -5, 0, 17, 26, 2, 0, 6, 32, 5), ft(0, 9, 11, -5, 0, 18, 28, 2, 0, 7, 34, 6), ft(0, 9, 12, -6, 0, 19, 29, 2, 0, 7, 36, 6), ft(0, 10, 13, -6, 0, 20, 31, 3, 0, 8, 38, 7), ft(0, 10, 13, -6, 0, 21, 33, 3, 0, 8, 40, 7), ft(0, 10, 14, -6, 0, 22, 35, 3, 0, 8, 42, 7), ft(0, 11, 14, -7, 0, 23, 36, 3, 0, 9, 44, 8), ft(0, 11, 15, -7, 0, 24, 38, 3, 0, 9, 46, 8)], fw = ww, mw = ["duration", "easing", "delay"], hw = { +const sw = ["none", ft(0, 2, 1, -1, 0, 1, 1, 0, 0, 1, 3, 0), ft(0, 3, 1, -2, 0, 2, 2, 0, 0, 1, 5, 0), ft(0, 3, 3, -2, 0, 3, 4, 0, 0, 1, 8, 0), ft(0, 2, 4, -1, 0, 4, 5, 0, 0, 1, 10, 0), ft(0, 3, 5, -1, 0, 5, 8, 0, 0, 1, 14, 0), ft(0, 3, 5, -1, 0, 6, 10, 0, 0, 1, 18, 0), ft(0, 4, 5, -2, 0, 7, 10, 1, 0, 2, 16, 1), ft(0, 5, 5, -3, 0, 8, 10, 1, 0, 3, 14, 2), ft(0, 5, 6, -3, 0, 9, 12, 1, 0, 3, 16, 2), ft(0, 6, 6, -3, 0, 10, 14, 1, 0, 4, 18, 3), ft(0, 6, 7, -4, 0, 11, 15, 1, 0, 4, 20, 3), ft(0, 7, 8, -4, 0, 12, 17, 2, 0, 5, 22, 4), ft(0, 7, 8, -4, 0, 13, 19, 2, 0, 5, 24, 4), ft(0, 7, 9, -4, 0, 14, 21, 2, 0, 5, 26, 4), ft(0, 8, 9, -5, 0, 15, 22, 2, 0, 6, 28, 5), ft(0, 8, 10, -5, 0, 16, 24, 2, 0, 6, 30, 5), ft(0, 8, 11, -5, 0, 17, 26, 2, 0, 6, 32, 5), ft(0, 9, 11, -5, 0, 18, 28, 2, 0, 7, 34, 6), ft(0, 9, 12, -6, 0, 19, 29, 2, 0, 7, 36, 6), ft(0, 10, 13, -6, 0, 20, 31, 3, 0, 8, 38, 7), ft(0, 10, 13, -6, 0, 21, 33, 3, 0, 8, 40, 7), ft(0, 10, 14, -6, 0, 22, 35, 3, 0, 8, 42, 7), ft(0, 11, 14, -7, 0, 23, 36, 3, 0, 9, 44, 8), ft(0, 11, 15, -7, 0, 24, 38, 3, 0, 9, 46, 8)], lw = sw, cw = ["duration", "easing", "delay"], dw = { // This is the most common easing curve. easeInOut: "cubic-bezier(0.4, 0, 0.2, 1)", // Objects enter the screen at full velocity from off-screen and @@ -6416,7 +6345,7 @@ const ww = ["none", ft(0, 2, 1, -1, 0, 1, 1, 0, 0, 1, 3, 0), ft(0, 3, 1, -2, 0, easeIn: "cubic-bezier(0.4, 0, 1, 1)", // The sharp curve is used by objects that may return to the screen at any time. sharp: "cubic-bezier(0.4, 0, 0.6, 1)" -}, gw = { +}, pw = { shortest: 150, shorter: 200, short: 250, @@ -6432,22 +6361,22 @@ const ww = ["none", ft(0, 2, 1, -1, 0, 1, 1, 0, 0, 1, 3, 0), ft(0, 3, 1, -2, 0, function Ia(t) { return `${Math.round(t)}ms`; } -function bw(t) { +function uw(t) { if (!t) return 0; const e = t / 36; return Math.round((4 + 15 * e ** 0.25 + e / 5) * 10); } -function vw(t) { - const e = P({}, hw, t.easing), n = P({}, gw, t.duration); +function ww(t) { + const e = P({}, dw, t.easing), n = P({}, pw, t.duration); return P({ - getAutoHeightDuration: bw, + getAutoHeightDuration: uw, create: (o = ["all"], a = {}) => { const { duration: i = n.standard, easing: l = e.easeInOut, delay: c = 0 - } = a, d = kt(a, mw); + } = a, d = kt(a, cw); if (process.env.NODE_ENV !== "production") { const p = (w) => typeof w == "string", h = (w) => !isNaN(parseFloat(w)); !p(o) && !Array.isArray(o) && console.error('MUI: Argument "props" must be a string or Array.'), !h(i) && !p(i) && console.error(`MUI: Argument "duration" must be a number or a string but found ${i}.`), p(l) || console.error('MUI: Argument "easing" must be a string.'), !h(c) && !p(c) && console.error('MUI: Argument "delay" must be a number or a string.'), typeof a != "object" && console.error(["MUI: Secong argument of transition.create must be an object.", "Arguments should be either `create('prop1', options)` or `create(['prop1', 'prop2'], options)`"].join(` @@ -6460,7 +6389,7 @@ function vw(t) { duration: n }); } -const yw = { +const fw = { mobileStepper: 1e3, fab: 1050, speedDial: 1050, @@ -6469,25 +6398,25 @@ const yw = { modal: 1300, snackbar: 1400, tooltip: 1500 -}, xw = yw, Nw = ["breakpoints", "mixins", "spacing", "palette", "transitions", "typography", "shape"]; -function kw(t = {}, ...e) { +}, mw = fw, hw = ["breakpoints", "mixins", "spacing", "palette", "transitions", "typography", "shape"]; +function gw(t = {}, ...e) { const { mixins: n = {}, palette: r = {}, transitions: o = {}, typography: a = {} - } = t, i = kt(t, Nw); + } = t, i = kt(t, hw); if (t.vars) throw new Error(process.env.NODE_ENV !== "production" ? "MUI: `vars` is a private field used for CSS variables support.\nPlease use another name." : Ve(18)); - const l = iw(r), c = To(t); + const l = tw(r), c = To(t); let d = Zt(c, { - mixins: Uu(c.breakpoints, n), + mixins: Bu(c.breakpoints, n), palette: l, // Don't use [...shadows] until you've verified its transpiled code is not invoking the iterator protocol. - shadows: fw.slice(), - typography: cw(l, a), - transitions: vw(o), - zIndex: P({}, xw) + shadows: lw.slice(), + typography: rw(l, a), + transitions: ww(o), + zIndex: P({}, mw) }); if (d = Zt(d, i), d = e.reduce((p, h) => Zt(p, h), d), process.env.NODE_ENV !== "production") { const p = ["active", "checked", "completed", "disabled", "error", "expanded", "focused", "focusVisible", "required", "selected"], h = (w, g) => { @@ -6520,28 +6449,28 @@ function kw(t = {}, ...e) { }); }, d; } -const Ew = kw(), Oo = Ew, Ro = "$$material"; +const bw = gw(), Oo = bw, Ro = "$$material"; function _o({ props: t, name: e }) { - return ju({ + return $u({ props: t, name: e, defaultTheme: Oo, themeId: Ro }); } -const Sw = (t) => Gn(t) && t !== "classes", Tw = Du({ +const vw = (t) => Gn(t) && t !== "classes", yw = _u({ themeId: Ro, defaultTheme: Oo, - rootShouldForwardProp: Sw -}), Rn = Tw; -function Cw(t) { + rootShouldForwardProp: vw +}), Rn = yw; +function xw(t) { return pr("MuiSvgIcon", t); } -ws("MuiSvgIcon", ["root", "colorPrimary", "colorSecondary", "colorAction", "colorError", "colorDisabled", "fontSizeInherit", "fontSizeSmall", "fontSizeMedium", "fontSizeLarge"]); -const Ow = ["children", "className", "color", "component", "fontSize", "htmlColor", "inheritViewBox", "titleAccess", "viewBox"], Rw = (t) => { +ls("MuiSvgIcon", ["root", "colorPrimary", "colorSecondary", "colorAction", "colorError", "colorDisabled", "fontSizeInherit", "fontSizeSmall", "fontSizeMedium", "fontSizeLarge"]); +const Nw = ["children", "className", "color", "component", "fontSize", "htmlColor", "inheritViewBox", "titleAccess", "viewBox"], kw = (t) => { const { color: e, fontSize: n, @@ -6549,8 +6478,8 @@ const Ow = ["children", "className", "color", "component", "fontSize", "htmlColo } = t, o = { root: ["root", e !== "inherit" && `color${Wt(e)}`, `fontSize${Wt(n)}`] }; - return xo(o, Cw, r); -}, _w = Rn("svg", { + return xo(o, xw, r); +}, Ew = Rn("svg", { name: "MuiSvgIcon", slot: "Root", overridesResolver: (t, e) => { @@ -6603,7 +6532,7 @@ const Ow = ["children", "className", "color", "component", "fontSize", "htmlColo inheritViewBox: p = !1, titleAccess: h, viewBox: w = "0 0 24 24" - } = r, g = kt(r, Ow), v = /* @__PURE__ */ M.isValidElement(o) && o.type === "svg", f = P({}, r, { + } = r, g = kt(r, Nw), v = /* @__PURE__ */ M.isValidElement(o) && o.type === "svg", f = P({}, r, { color: i, component: l, fontSize: c, @@ -6613,8 +6542,8 @@ const Ow = ["children", "className", "color", "component", "fontSize", "htmlColo hasSvgAsChild: v }), m = {}; p || (m.viewBox = w); - const E = Rw(f); - return /* @__PURE__ */ x(_w, P({ + const E = kw(f); + return /* @__PURE__ */ N(Ew, P({ as: l, className: be(E.root, a), focusable: "false", @@ -6703,7 +6632,7 @@ process.env.NODE_ENV !== "production" && (Po.propTypes = { }); Po.muiName = "SvgIcon"; const Aa = Po; -function ys(t, e) { +function ms(t, e) { function n(r, o) { return /* @__PURE__ */ s(Aa, P({ "data-testid": `${e}Icon`, @@ -6714,34 +6643,34 @@ function ys(t, e) { } return process.env.NODE_ENV !== "production" && (n.displayName = `${e}Icon`), n.muiName = Aa.muiName, /* @__PURE__ */ M.memo(/* @__PURE__ */ M.forwardRef(n)); } -const Pw = { +const Sw = { configure: (t) => { process.env.NODE_ENV !== "production" && console.warn(["MUI: `ClassNameGenerator` import from `@mui/material/utils` is outdated and might cause unexpected issues.", "", "You should use `import { unstable_ClassNameGenerator } from '@mui/material/className'` instead", "", "The detail of the issue: https://github.com/mui/material-ui/issues/30011#issuecomment-1024993401", "", "The updated documentation: https://mui.com/guides/classname-generator/"].join(` -`)), ps.configure(t); +`)), is.configure(t); } -}, $w = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({ +}, Tw = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({ __proto__: null, capitalize: Wt, - createChainedFunction: sp, - createSvgIcon: ys, - debounce: lp, - deprecatedPropType: cp, - isMuiElement: dp, + createChainedFunction: ep, + createSvgIcon: ms, + debounce: np, + deprecatedPropType: rp, + isMuiElement: op, ownerDocument: Yn, - ownerWindow: pp, - requirePropFactory: up, + ownerWindow: ap, + requirePropFactory: ip, setRef: Wn, - unstable_ClassNameGenerator: Pw, + unstable_ClassNameGenerator: Sw, unstable_useEnhancedEffect: ze, - unstable_useId: ss, - unsupportedProp: mp, - useControlled: ls, + unstable_useId: ns, + unsupportedProp: cp, + useControlled: rs, useEventCallback: eo, useForkRef: xe, - useIsFocusVisible: cs -}, Symbol.toStringTag, { value: "Module" })), Iw = /* @__PURE__ */ Ld($w); + useIsFocusVisible: os +}, Symbol.toStringTag, { value: "Module" })), Cw = /* @__PURE__ */ Md(Tw); var Ma; -function Aw() { +function Ow() { return Ma || (Ma = 1, function(t) { "use client"; Object.defineProperty(t, "__esModule", { @@ -6752,35 +6681,35 @@ function Aw() { return e.createSvgIcon; } }); - var e = Iw; + var e = Cw; }(Ar)), Ar; } -var Mw = Fd; +var Rw = Dd; Object.defineProperty(bo, "__esModule", { value: !0 }); -var xs = bo.default = void 0, Dw = Mw(Aw()), Bw = el; -xs = bo.default = (0, Dw.default)(/* @__PURE__ */ (0, Bw.jsx)("path", { +var hs = bo.default = void 0, _w = Rw(Ow()), Pw = Ks; +hs = bo.default = (0, _w.default)(/* @__PURE__ */ (0, Pw.jsx)("path", { d: "m10 17 5-5-5-5z" }), "ArrowRight"); -function jw(t) { +function $w(t) { return typeof t == "string"; } function ln(t, e, n) { - return t === void 0 || jw(t) ? e : P({}, e, { + return t === void 0 || $w(t) ? e : P({}, e, { ownerState: P({}, e.ownerState, n) }); } -const Vw = { +const Iw = { disableDefaultClasses: !1 -}, zw = /* @__PURE__ */ M.createContext(Vw); -function Lw(t) { +}, Aw = /* @__PURE__ */ M.createContext(Iw); +function Mw(t) { const { disableDefaultClasses: e - } = M.useContext(zw); + } = M.useContext(Aw); return (n) => e ? "" : t(n); } -function Fw(t, e = []) { +function Dw(t, e = []) { if (t === void 0) return {}; const n = {}; @@ -6788,7 +6717,7 @@ function Fw(t, e = []) { n[r] = t[r]; }), n; } -function Uw(t, e, n) { +function Bw(t, e, n) { return typeof t == "function" ? t(e, n) : t; } function Da(t) { @@ -6799,7 +6728,7 @@ function Da(t) { e[n] = t[n]; }), e; } -function Gw(t) { +function jw(t) { const { getSlotProps: e, additionalProps: n, @@ -6814,48 +6743,48 @@ function Gw(t) { internalRef: void 0 }; } - const i = Fw(P({}, o, r)), l = Da(r), c = Da(o), d = e(i), p = be(d == null ? void 0 : d.className, n == null ? void 0 : n.className, a, o == null ? void 0 : o.className, r == null ? void 0 : r.className), h = P({}, d == null ? void 0 : d.style, n == null ? void 0 : n.style, o == null ? void 0 : o.style, r == null ? void 0 : r.style), w = P({}, d, n, c, l); + const i = Dw(P({}, o, r)), l = Da(r), c = Da(o), d = e(i), p = be(d == null ? void 0 : d.className, n == null ? void 0 : n.className, a, o == null ? void 0 : o.className, r == null ? void 0 : r.className), h = P({}, d == null ? void 0 : d.style, n == null ? void 0 : n.style, o == null ? void 0 : o.style, r == null ? void 0 : r.style), w = P({}, d, n, c, l); return p.length > 0 && (w.className = p), Object.keys(h).length > 0 && (w.style = h), { props: w, internalRef: d.ref }; } -const Hw = ["elementType", "externalSlotProps", "ownerState", "skipResolvingSlotProps"]; -function Xw(t) { +const Vw = ["elementType", "externalSlotProps", "ownerState", "skipResolvingSlotProps"]; +function zw(t) { var e; const { elementType: n, externalSlotProps: r, ownerState: o, skipResolvingSlotProps: a = !1 - } = t, i = kt(t, Hw), l = a ? {} : Uw(r, o), { + } = t, i = kt(t, Vw), l = a ? {} : Bw(r, o), { props: c, internalRef: d - } = Gw(P({}, i, { + } = jw(P({}, i, { externalSlotProps: l })), p = xe(d, l == null ? void 0 : l.ref, (e = t.additionalProps) == null ? void 0 : e.ref); return ln(n, P({}, c, { ref: p }), o); } -const Ns = "base"; -function Yw(t) { - return `${Ns}--${t}`; +const gs = "base"; +function Lw(t) { + return `${gs}--${t}`; } -function Ww(t, e) { - return `${Ns}-${t}-${e}`; +function Fw(t, e) { + return `${gs}-${t}-${e}`; } -function ks(t, e) { - const n = us[e]; - return n ? Yw(n) : Ww(t, e); +function bs(t, e) { + const n = ss[e]; + return n ? Lw(n) : Fw(t, e); } -function qw(t, e) { +function Uw(t, e) { const n = {}; return e.forEach((r) => { - n[r] = ks(t, r); + n[r] = bs(t, r); }), n; } -function Kw(t) { +function Gw(t) { return typeof t == "function" ? t() : t; } const Kn = /* @__PURE__ */ M.forwardRef(function(e, n) { @@ -6865,7 +6794,7 @@ const Kn = /* @__PURE__ */ M.forwardRef(function(e, n) { disablePortal: a = !1 } = e, [i, l] = M.useState(null), c = xe(/* @__PURE__ */ M.isValidElement(r) ? r.ref : null, n); if (ze(() => { - a || l(Kw(o) || document.body); + a || l(Gw(o) || document.body); }, [o, a]), ze(() => { if (i && !a) return Wn(n, i), () => { @@ -6883,7 +6812,7 @@ const Kn = /* @__PURE__ */ M.forwardRef(function(e, n) { }); } return /* @__PURE__ */ s(M.Fragment, { - children: i && /* @__PURE__ */ ql.createPortal(r, i) + children: i && /* @__PURE__ */ Gl.createPortal(r, i) }); }); process.env.NODE_ENV !== "production" && (Kn.propTypes = { @@ -6912,12 +6841,12 @@ process.env.NODE_ENV !== "production" && (Kn.propTypes = { */ disablePortal: u.bool }); -process.env.NODE_ENV !== "production" && (Kn["propTypes"] = tp(Kn.propTypes)); -var Ct = "top", Vt = "bottom", zt = "right", Ot = "left", $o = "auto", _n = [Ct, Vt, zt, Ot], Le = "start", Nn = "end", Jw = "clippingParents", Es = "viewport", rn = "popper", Zw = "reference", Ba = /* @__PURE__ */ _n.reduce(function(t, e) { +process.env.NODE_ENV !== "production" && (Kn["propTypes"] = Wd(Kn.propTypes)); +var Ct = "top", Vt = "bottom", zt = "right", Ot = "left", $o = "auto", _n = [Ct, Vt, zt, Ot], Le = "start", Nn = "end", Hw = "clippingParents", vs = "viewport", rn = "popper", Xw = "reference", Ba = /* @__PURE__ */ _n.reduce(function(t, e) { return t.concat([e + "-" + Le, e + "-" + Nn]); -}, []), Ss = /* @__PURE__ */ [].concat(_n, [$o]).reduce(function(t, e) { +}, []), ys = /* @__PURE__ */ [].concat(_n, [$o]).reduce(function(t, e) { return t.concat([e, e + "-" + Le, e + "-" + Nn]); -}, []), Qw = "beforeRead", tf = "read", ef = "afterRead", nf = "beforeMain", rf = "main", of = "afterMain", af = "beforeWrite", sf = "write", lf = "afterWrite", cf = [Qw, tf, ef, nf, rf, of, af, sf, lf]; +}, []), Yw = "beforeRead", Ww = "read", qw = "afterRead", Kw = "beforeMain", Jw = "main", Zw = "afterMain", Qw = "beforeWrite", tf = "write", ef = "afterWrite", nf = [Yw, Ww, qw, Kw, Jw, Zw, Qw, tf, ef]; function qt(t) { return t ? (t.nodeName || "").toLowerCase() : null; } @@ -6944,7 +6873,7 @@ function Io(t) { var e = Mt(t).ShadowRoot; return t instanceof e || t instanceof ShadowRoot; } -function df(t) { +function rf(t) { var e = t.state; Object.keys(e.elements).forEach(function(n) { var r = e.styles[n] || {}, o = e.attributes[n] || {}, a = e.elements[n]; @@ -6954,7 +6883,7 @@ function df(t) { })); }); } -function pf(t) { +function of(t) { var e = t.state, n = { popper: { position: e.options.strategy, @@ -6978,12 +6907,12 @@ function pf(t) { }); }; } -const uf = { +const af = { name: "applyStyles", enabled: !0, phase: "write", - fn: df, - effect: pf, + fn: rf, + effect: of, requires: ["computeStyles"] }; function Yt(t) { @@ -6996,14 +6925,14 @@ function ro() { return e.brand + "/" + e.version; }).join(" ") : navigator.userAgent; } -function Ts() { +function xs() { return !/^((?!chrome|android).)*safari/i.test(ro()); } function Ue(t, e, n) { e === void 0 && (e = !1), n === void 0 && (n = !1); var r = t.getBoundingClientRect(), o = 1, a = 1; e && jt(t) && (o = t.offsetWidth > 0 && Fe(r.width) / t.offsetWidth || 1, a = t.offsetHeight > 0 && Fe(r.height) / t.offsetHeight || 1); - var i = ke(t) ? Mt(t) : window, l = i.visualViewport, c = !Ts() && n, d = (r.left + (c && l ? l.offsetLeft : 0)) / o, p = (r.top + (c && l ? l.offsetTop : 0)) / a, h = r.width / o, w = r.height / a; + var i = ke(t) ? Mt(t) : window, l = i.visualViewport, c = !xs() && n, d = (r.left + (c && l ? l.offsetLeft : 0)) / o, p = (r.top + (c && l ? l.offsetTop : 0)) / a, h = r.width / o, w = r.height / a; return { width: h, height: w, @@ -7024,7 +6953,7 @@ function Ao(t) { height: r }; } -function Cs(t, e) { +function Ns(t, e) { var n = e.getRootNode && e.getRootNode(); if (t.contains(e)) return !0; @@ -7041,7 +6970,7 @@ function Cs(t, e) { function te(t) { return Mt(t).getComputedStyle(t); } -function wf(t) { +function sf(t) { return ["table", "td", "th"].indexOf(qt(t)) >= 0; } function le(t) { @@ -7066,7 +6995,7 @@ function ja(t) { return !jt(t) || // https://github.com/popperjs/popper-core/issues/837 te(t).position === "fixed" ? null : t.offsetParent; } -function ff(t) { +function lf(t) { var e = /firefox/i.test(ro()), n = /Trident/i.test(ro()); if (n && jt(t)) { var r = te(t); @@ -7083,9 +7012,9 @@ function ff(t) { return null; } function Pn(t) { - for (var e = Mt(t), n = ja(t); n && wf(n) && te(n).position === "static"; ) + for (var e = Mt(t), n = ja(t); n && sf(n) && te(n).position === "static"; ) n = ja(n); - return n && (qt(n) === "html" || qt(n) === "body" && te(n).position === "static") ? e : n || ff(t) || e; + return n && (qt(n) === "html" || qt(n) === "body" && te(n).position === "static") ? e : n || lf(t) || e; } function Mo(t) { return ["top", "bottom"].indexOf(t) >= 0 ? "x" : "y"; @@ -7093,11 +7022,11 @@ function Mo(t) { function wn(t, e, n) { return ve(t, Jn(e, n)); } -function mf(t, e, n) { +function cf(t, e, n) { var r = wn(t, e, n); return r > n ? n : r; } -function Os() { +function ks() { return { top: 0, right: 0, @@ -7105,49 +7034,49 @@ function Os() { left: 0 }; } -function Rs(t) { - return Object.assign({}, Os(), t); +function Es(t) { + return Object.assign({}, ks(), t); } -function _s(t, e) { +function Ss(t, e) { return e.reduce(function(n, r) { return n[r] = t, n; }, {}); } -var hf = function(e, n) { +var df = function(e, n) { return e = typeof e == "function" ? e(Object.assign({}, n.rects, { placement: n.placement - })) : e, Rs(typeof e != "number" ? e : _s(e, _n)); + })) : e, Es(typeof e != "number" ? e : Ss(e, _n)); }; -function gf(t) { +function pf(t) { var e, n = t.state, r = t.name, o = t.options, a = n.elements.arrow, i = n.modifiersData.popperOffsets, l = Yt(n.placement), c = Mo(l), d = [Ot, zt].indexOf(l) >= 0, p = d ? "height" : "width"; if (!(!a || !i)) { - var h = hf(o.padding, n), w = Ao(a), g = c === "y" ? Ct : Ot, v = c === "y" ? Vt : zt, f = n.rects.reference[p] + n.rects.reference[c] - i[c] - n.rects.popper[p], m = i[c] - n.rects.reference[c], E = Pn(a), _ = E ? c === "y" ? E.clientHeight || 0 : E.clientWidth || 0 : 0, C = f / 2 - m / 2, S = h[g], b = _ - w[p] - h[v], I = _ / 2 - w[p] / 2 + C, z = wn(S, I, b), H = c; + var h = df(o.padding, n), w = Ao(a), g = c === "y" ? Ct : Ot, v = c === "y" ? Vt : zt, f = n.rects.reference[p] + n.rects.reference[c] - i[c] - n.rects.popper[p], m = i[c] - n.rects.reference[c], E = Pn(a), _ = E ? c === "y" ? E.clientHeight || 0 : E.clientWidth || 0 : 0, C = f / 2 - m / 2, S = h[g], b = _ - w[p] - h[v], I = _ / 2 - w[p] / 2 + C, z = wn(S, I, b), H = c; n.modifiersData[r] = (e = {}, e[H] = z, e.centerOffset = z - I, e); } } -function bf(t) { +function uf(t) { var e = t.state, n = t.options, r = n.element, o = r === void 0 ? "[data-popper-arrow]" : r; - o != null && (typeof o == "string" && (o = e.elements.popper.querySelector(o), !o) || Cs(e.elements.popper, o) && (e.elements.arrow = o)); + o != null && (typeof o == "string" && (o = e.elements.popper.querySelector(o), !o) || Ns(e.elements.popper, o) && (e.elements.arrow = o)); } -const vf = { +const wf = { name: "arrow", enabled: !0, phase: "main", - fn: gf, - effect: bf, + fn: pf, + effect: uf, requires: ["popperOffsets"], requiresIfExists: ["preventOverflow"] }; function Ge(t) { return t.split("-")[1]; } -var yf = { +var ff = { top: "auto", right: "auto", bottom: "auto", left: "auto" }; -function xf(t, e) { +function mf(t, e) { var n = t.x, r = t.y, o = e.devicePixelRatio || 1; return { x: Fe(n * o) / o || 0, @@ -7185,7 +7114,7 @@ function Va(t) { } var k = Object.assign({ position: l - }, d && yf), B = p === !0 ? xf({ + }, d && ff), B = p === !0 ? mf({ x: g, y: f }, Mt(n)) : { @@ -7198,7 +7127,7 @@ function Va(t) { } return Object.assign({}, k, (e = {}, e[S] = _ ? f + "px" : "", e[C] = E ? g + "px" : "", e.transform = "", e)); } -function Nf(t) { +function hf(t) { var e = t.state, n = t.options, r = n.gpuAcceleration, o = r === void 0 ? !0 : r, a = n.adaptive, i = a === void 0 ? !0 : a, l = n.roundOffsets, c = l === void 0 ? !0 : l, d = { placement: Yt(e.placement), variation: Ge(e.placement), @@ -7221,17 +7150,17 @@ function Nf(t) { "data-popper-placement": e.placement }); } -const kf = { +const gf = { name: "computeStyles", enabled: !0, phase: "beforeWrite", - fn: Nf, + fn: hf, data: {} }; var zn = { passive: !0 }; -function Ef(t) { +function bf(t) { var e = t.state, n = t.instance, r = t.options, o = r.scroll, a = o === void 0 ? !0 : o, i = r.resize, l = i === void 0 ? !0 : i, c = Mt(e.elements.popper), d = [].concat(e.scrollParents.reference, e.scrollParents.popper); return a && d.forEach(function(p) { p.addEventListener("scroll", n.update, zn); @@ -7241,16 +7170,16 @@ function Ef(t) { }), l && c.removeEventListener("resize", n.update, zn); }; } -const Sf = { +const vf = { name: "eventListeners", enabled: !0, phase: "write", fn: function() { }, - effect: Ef, + effect: bf, data: {} }; -var Tf = { +var yf = { left: "right", right: "left", bottom: "top", @@ -7258,16 +7187,16 @@ var Tf = { }; function Xn(t) { return t.replace(/left|right|bottom|top/g, function(e) { - return Tf[e]; + return yf[e]; }); } -var Cf = { +var xf = { start: "end", end: "start" }; function za(t) { return t.replace(/start|end/g, function(e) { - return Cf[e]; + return xf[e]; }); } function Do(t) { @@ -7280,11 +7209,11 @@ function Do(t) { function Bo(t) { return Ue(le(t)).left + Do(t).scrollLeft; } -function Of(t, e) { +function Nf(t, e) { var n = Mt(t), r = le(t), o = n.visualViewport, a = r.clientWidth, i = r.clientHeight, l = 0, c = 0; if (o) { a = o.width, i = o.height; - var d = Ts(); + var d = xs(); (d || !d && e === "fixed") && (l = o.offsetLeft, c = o.offsetTop); } return { @@ -7294,7 +7223,7 @@ function Of(t, e) { y: c }; } -function Rf(t) { +function kf(t) { var e, n = le(t), r = Do(t), o = (e = t.ownerDocument) == null ? void 0 : e.body, a = ve(n.scrollWidth, n.clientWidth, o ? o.scrollWidth : 0, o ? o.clientWidth : 0), i = ve(n.scrollHeight, n.clientHeight, o ? o.scrollHeight : 0, o ? o.clientHeight : 0), l = -r.scrollLeft + Bo(t), c = -r.scrollTop; return te(o || n).direction === "rtl" && (l += ve(n.clientWidth, o ? o.clientWidth : 0) - a), { width: a, @@ -7307,13 +7236,13 @@ function jo(t) { var e = te(t), n = e.overflow, r = e.overflowX, o = e.overflowY; return /auto|scroll|overlay|hidden/.test(n + o + r); } -function Ps(t) { - return ["html", "body", "#document"].indexOf(qt(t)) >= 0 ? t.ownerDocument.body : jt(t) && jo(t) ? t : Ps(xr(t)); +function Ts(t) { + return ["html", "body", "#document"].indexOf(qt(t)) >= 0 ? t.ownerDocument.body : jt(t) && jo(t) ? t : Ts(xr(t)); } function fn(t, e) { var n; e === void 0 && (e = []); - var r = Ps(t), o = r === ((n = t.ownerDocument) == null ? void 0 : n.body), a = Mt(r), i = o ? [a].concat(a.visualViewport || [], jo(r) ? r : []) : r, l = e.concat(i); + var r = Ts(t), o = r === ((n = t.ownerDocument) == null ? void 0 : n.body), a = Mt(r), i = o ? [a].concat(a.visualViewport || [], jo(r) ? r : []) : r, l = e.concat(i); return o ? l : ( // $FlowFixMe[incompatible-call]: isBody tells us target will be an HTMLElement here l.concat(fn(xr(i))) @@ -7327,27 +7256,27 @@ function oo(t) { bottom: t.y + t.height }); } -function _f(t, e) { +function Ef(t, e) { var n = Ue(t, !1, e === "fixed"); return n.top = n.top + t.clientTop, n.left = n.left + t.clientLeft, n.bottom = n.top + t.clientHeight, n.right = n.left + t.clientWidth, n.width = t.clientWidth, n.height = t.clientHeight, n.x = n.left, n.y = n.top, n; } function La(t, e, n) { - return e === Es ? oo(Of(t, n)) : ke(e) ? _f(e, n) : oo(Rf(le(t))); + return e === vs ? oo(Nf(t, n)) : ke(e) ? Ef(e, n) : oo(kf(le(t))); } -function Pf(t) { +function Sf(t) { var e = fn(xr(t)), n = ["absolute", "fixed"].indexOf(te(t).position) >= 0, r = n && jt(t) ? Pn(t) : t; return ke(r) ? e.filter(function(o) { - return ke(o) && Cs(o, r) && qt(o) !== "body"; + return ke(o) && Ns(o, r) && qt(o) !== "body"; }) : []; } -function $f(t, e, n, r) { - var o = e === "clippingParents" ? Pf(t) : [].concat(e), a = [].concat(o, [n]), i = a[0], l = a.reduce(function(c, d) { +function Tf(t, e, n, r) { + var o = e === "clippingParents" ? Sf(t) : [].concat(e), a = [].concat(o, [n]), i = a[0], l = a.reduce(function(c, d) { var p = La(t, d, r); return c.top = ve(p.top, c.top), c.right = Jn(p.right, c.right), c.bottom = Jn(p.bottom, c.bottom), c.left = ve(p.left, c.left), c; }, La(t, i, r)); return l.width = l.right - l.left, l.height = l.bottom - l.top, l.x = l.left, l.y = l.top, l; } -function $s(t) { +function Cs(t) { var e = t.reference, n = t.element, r = t.placement, o = r ? Yt(r) : null, a = r ? Ge(r) : null, i = e.x + e.width / 2 - n.width / 2, l = e.y + e.height / 2 - n.height / 2, c; switch (o) { case Ct: @@ -7396,7 +7325,7 @@ function $s(t) { } function kn(t, e) { e === void 0 && (e = {}); - var n = e, r = n.placement, o = r === void 0 ? t.placement : r, a = n.strategy, i = a === void 0 ? t.strategy : a, l = n.boundary, c = l === void 0 ? Jw : l, d = n.rootBoundary, p = d === void 0 ? Es : d, h = n.elementContext, w = h === void 0 ? rn : h, g = n.altBoundary, v = g === void 0 ? !1 : g, f = n.padding, m = f === void 0 ? 0 : f, E = Rs(typeof m != "number" ? m : _s(m, _n)), _ = w === rn ? Zw : rn, C = t.rects.popper, S = t.elements[v ? _ : w], b = $f(ke(S) ? S : S.contextElement || le(t.elements.popper), c, p, i), I = Ue(t.elements.reference), z = $s({ + var n = e, r = n.placement, o = r === void 0 ? t.placement : r, a = n.strategy, i = a === void 0 ? t.strategy : a, l = n.boundary, c = l === void 0 ? Hw : l, d = n.rootBoundary, p = d === void 0 ? vs : d, h = n.elementContext, w = h === void 0 ? rn : h, g = n.altBoundary, v = g === void 0 ? !1 : g, f = n.padding, m = f === void 0 ? 0 : f, E = Es(typeof m != "number" ? m : Ss(m, _n)), _ = w === rn ? Xw : rn, C = t.rects.popper, S = t.elements[v ? _ : w], b = Tf(ke(S) ? S : S.contextElement || le(t.elements.popper), c, p, i), I = Ue(t.elements.reference), z = Cs({ reference: I, element: C, strategy: "absolute", @@ -7416,9 +7345,9 @@ function kn(t, e) { } return $; } -function If(t, e) { +function Cf(t, e) { e === void 0 && (e = {}); - var n = e, r = n.placement, o = n.boundary, a = n.rootBoundary, i = n.padding, l = n.flipVariations, c = n.allowedAutoPlacements, d = c === void 0 ? Ss : c, p = Ge(r), h = p ? l ? Ba : Ba.filter(function(v) { + var n = e, r = n.placement, o = n.boundary, a = n.rootBoundary, i = n.padding, l = n.flipVariations, c = n.allowedAutoPlacements, d = c === void 0 ? ys : c, p = Ge(r), h = p ? l ? Ba : Ba.filter(function(v) { return Ge(v) === p; }) : _n, w = h.filter(function(v) { return d.indexOf(v) >= 0; @@ -7436,17 +7365,17 @@ function If(t, e) { return g[v] - g[f]; }); } -function Af(t) { +function Of(t) { if (Yt(t) === $o) return []; var e = Xn(t); return [za(t), e, za(e)]; } -function Mf(t) { +function Rf(t) { var e = t.state, n = t.options, r = t.name; if (!e.modifiersData[r]._skip) { - for (var o = n.mainAxis, a = o === void 0 ? !0 : o, i = n.altAxis, l = i === void 0 ? !0 : i, c = n.fallbackPlacements, d = n.padding, p = n.boundary, h = n.rootBoundary, w = n.altBoundary, g = n.flipVariations, v = g === void 0 ? !0 : g, f = n.allowedAutoPlacements, m = e.options.placement, E = Yt(m), _ = E === m, C = c || (_ || !v ? [Xn(m)] : Af(m)), S = [m].concat(C).reduce(function(V, W) { - return V.concat(Yt(W) === $o ? If(e, { + for (var o = n.mainAxis, a = o === void 0 ? !0 : o, i = n.altAxis, l = i === void 0 ? !0 : i, c = n.fallbackPlacements, d = n.padding, p = n.boundary, h = n.rootBoundary, w = n.altBoundary, g = n.flipVariations, v = g === void 0 ? !0 : g, f = n.allowedAutoPlacements, m = e.options.placement, E = Yt(m), _ = E === m, C = c || (_ || !v ? [Xn(m)] : Of(m)), S = [m].concat(C).reduce(function(V, W) { + return V.concat(Yt(W) === $o ? Cf(e, { placement: W, boundary: p, rootBoundary: h, @@ -7491,11 +7420,11 @@ function Mf(t) { e.placement !== O && (e.modifiersData[r]._skip = !0, e.placement = O, e.reset = !0); } } -const Df = { +const _f = { name: "flip", enabled: !0, phase: "main", - fn: Mf, + fn: Rf, requiresIfExists: ["offset"], data: { _skip: !1 @@ -7517,7 +7446,7 @@ function Ua(t) { return t[e] >= 0; }); } -function Bf(t) { +function Pf(t) { var e = t.state, n = t.name, r = e.rects.reference, o = e.rects.popper, a = e.modifiersData.preventOverflow, i = kn(e, { elementContext: "reference" }), l = kn(e, { @@ -7533,14 +7462,14 @@ function Bf(t) { "data-popper-escaped": h }); } -const jf = { +const $f = { name: "hide", enabled: !0, phase: "main", requiresIfExists: ["preventOverflow"], - fn: Bf + fn: Pf }; -function Vf(t, e, n) { +function If(t, e, n) { var r = Yt(t), o = [Ot, Ct].indexOf(r) >= 0 ? -1 : 1, a = typeof n == "function" ? n(Object.assign({}, e, { placement: t })) : n, i = a[0], l = a[1]; @@ -7552,45 +7481,45 @@ function Vf(t, e, n) { y: l }; } -function zf(t) { - var e = t.state, n = t.options, r = t.name, o = n.offset, a = o === void 0 ? [0, 0] : o, i = Ss.reduce(function(p, h) { - return p[h] = Vf(h, e.rects, a), p; +function Af(t) { + var e = t.state, n = t.options, r = t.name, o = n.offset, a = o === void 0 ? [0, 0] : o, i = ys.reduce(function(p, h) { + return p[h] = If(h, e.rects, a), p; }, {}), l = i[e.placement], c = l.x, d = l.y; e.modifiersData.popperOffsets != null && (e.modifiersData.popperOffsets.x += c, e.modifiersData.popperOffsets.y += d), e.modifiersData[r] = i; } -const Lf = { +const Mf = { name: "offset", enabled: !0, phase: "main", requires: ["popperOffsets"], - fn: zf + fn: Af }; -function Ff(t) { +function Df(t) { var e = t.state, n = t.name; - e.modifiersData[n] = $s({ + e.modifiersData[n] = Cs({ reference: e.rects.reference, element: e.rects.popper, strategy: "absolute", placement: e.placement }); } -const Uf = { +const Bf = { name: "popperOffsets", enabled: !0, phase: "read", - fn: Ff, + fn: Df, data: {} }; -function Gf(t) { +function jf(t) { return t === "x" ? "y" : "x"; } -function Hf(t) { +function Vf(t) { var e = t.state, n = t.options, r = t.name, o = n.mainAxis, a = o === void 0 ? !0 : o, i = n.altAxis, l = i === void 0 ? !1 : i, c = n.boundary, d = n.rootBoundary, p = n.altBoundary, h = n.padding, w = n.tether, g = w === void 0 ? !0 : w, v = n.tetherOffset, f = v === void 0 ? 0 : v, m = kn(e, { boundary: c, rootBoundary: d, padding: h, altBoundary: p - }), E = Yt(e.placement), _ = Ge(e.placement), C = !_, S = Mo(E), b = Gf(S), I = e.modifiersData.popperOffsets, z = e.rects.reference, H = e.rects.popper, O = typeof f == "function" ? f(Object.assign({}, e.rects, { + }), E = Yt(e.placement), _ = Ge(e.placement), C = !_, S = Mo(E), b = jf(S), I = e.modifiersData.popperOffsets, z = e.rects.reference, H = e.rects.popper, O = typeof f == "function" ? f(Object.assign({}, e.rects, { placement: e.placement })) : f, $ = typeof O == "number" ? { mainAxis: O, @@ -7607,39 +7536,39 @@ function Hf(t) { var D, J = S === "y" ? Ct : Ot, q = S === "y" ? Vt : zt, U = S === "y" ? "height" : "width", tt = I[S], at = tt + m[J], rt = tt - m[q], y = g ? -H[U] / 2 : 0, R = _ === Le ? z[U] : H[U], L = _ === Le ? -H[U] : -z[U], F = e.elements.arrow, V = g && F ? Ao(F) : { width: 0, height: 0 - }, W = e.modifiersData["arrow#persistent"] ? e.modifiersData["arrow#persistent"].padding : Os(), X = W[J], Y = W[q], G = wn(0, z[U], V[U]), K = C ? z[U] / 2 - y - G - X - $.mainAxis : R - G - X - $.mainAxis, Z = C ? -z[U] / 2 + y + G + Y + $.mainAxis : L + G + Y + $.mainAxis, dt = e.elements.arrow && Pn(e.elements.arrow), A = dt ? S === "y" ? dt.clientTop || 0 : dt.clientLeft || 0 : 0, Nt = (D = k == null ? void 0 : k[S]) != null ? D : 0, j = tt + K - Nt - A, xt = tt + Z - Nt, Ft = wn(g ? Jn(at, j) : at, tt, g ? ve(rt, xt) : rt); + }, W = e.modifiersData["arrow#persistent"] ? e.modifiersData["arrow#persistent"].padding : ks(), X = W[J], Y = W[q], G = wn(0, z[U], V[U]), K = C ? z[U] / 2 - y - G - X - $.mainAxis : R - G - X - $.mainAxis, Z = C ? -z[U] / 2 + y + G + Y + $.mainAxis : L + G + Y + $.mainAxis, dt = e.elements.arrow && Pn(e.elements.arrow), A = dt ? S === "y" ? dt.clientTop || 0 : dt.clientLeft || 0 : 0, Nt = (D = k == null ? void 0 : k[S]) != null ? D : 0, j = tt + K - Nt - A, xt = tt + Z - Nt, Ft = wn(g ? Jn(at, j) : at, tt, g ? ve(rt, xt) : rt); I[S] = Ft, B[S] = Ft - tt; } if (l) { - var ce, St = S === "x" ? Ct : Ot, In = S === "x" ? Vt : zt, Ut = I[b], Ee = b === "y" ? "height" : "width", de = Ut + m[St], Se = Ut - m[In], Te = [Ct, Ot].indexOf(E) !== -1, Ce = (ce = k == null ? void 0 : k[b]) != null ? ce : 0, pe = Te ? de : Ut - z[Ee] - H[Ee] - Ce + $.altAxis, qe = Te ? Ut + z[Ee] + H[Ee] - Ce - $.altAxis : Se, An = g && Te ? mf(pe, Ut, qe) : wn(g ? pe : de, Ut, g ? qe : Se); + var ce, St = S === "x" ? Ct : Ot, In = S === "x" ? Vt : zt, Ut = I[b], Ee = b === "y" ? "height" : "width", de = Ut + m[St], Se = Ut - m[In], Te = [Ct, Ot].indexOf(E) !== -1, Ce = (ce = k == null ? void 0 : k[b]) != null ? ce : 0, pe = Te ? de : Ut - z[Ee] - H[Ee] - Ce + $.altAxis, qe = Te ? Ut + z[Ee] + H[Ee] - Ce - $.altAxis : Se, An = g && Te ? cf(pe, Ut, qe) : wn(g ? pe : de, Ut, g ? qe : Se); I[b] = An, B[b] = An - Ut; } e.modifiersData[r] = B; } } -const Xf = { +const zf = { name: "preventOverflow", enabled: !0, phase: "main", - fn: Hf, + fn: Vf, requiresIfExists: ["offset"] }; -function Yf(t) { +function Lf(t) { return { scrollLeft: t.scrollLeft, scrollTop: t.scrollTop }; } -function Wf(t) { - return t === Mt(t) || !jt(t) ? Do(t) : Yf(t); +function Ff(t) { + return t === Mt(t) || !jt(t) ? Do(t) : Lf(t); } -function qf(t) { +function Uf(t) { var e = t.getBoundingClientRect(), n = Fe(e.width) / t.offsetWidth || 1, r = Fe(e.height) / t.offsetHeight || 1; return n !== 1 || r !== 1; } -function Kf(t, e, n) { +function Gf(t, e, n) { n === void 0 && (n = !1); - var r = jt(e), o = jt(e) && qf(e), a = le(e), i = Ue(t, o, n), l = { + var r = jt(e), o = jt(e) && Uf(e), a = le(e), i = Ue(t, o, n), l = { scrollLeft: 0, scrollTop: 0 }, c = { @@ -7647,14 +7576,14 @@ function Kf(t, e, n) { y: 0 }; return (r || !r && !n) && ((qt(e) !== "body" || // https://github.com/popperjs/popper-core/issues/1078 - jo(a)) && (l = Wf(e)), jt(e) ? (c = Ue(e, !0), c.x += e.clientLeft, c.y += e.clientTop) : a && (c.x = Bo(a))), { + jo(a)) && (l = Ff(e)), jt(e) ? (c = Ue(e, !0), c.x += e.clientLeft, c.y += e.clientTop) : a && (c.x = Bo(a))), { x: i.left + l.scrollLeft - c.x, y: i.top + l.scrollTop - c.y, width: i.width, height: i.height }; } -function Jf(t) { +function Hf(t) { var e = /* @__PURE__ */ new Map(), n = /* @__PURE__ */ new Set(), r = []; t.forEach(function(a) { e.set(a.name, a); @@ -7673,15 +7602,15 @@ function Jf(t) { n.has(a.name) || o(a); }), r; } -function Zf(t) { - var e = Jf(t); - return cf.reduce(function(n, r) { +function Xf(t) { + var e = Hf(t); + return nf.reduce(function(n, r) { return n.concat(e.filter(function(o) { return o.phase === r; })); }, []); } -function Qf(t) { +function Yf(t) { var e; return function() { return e || (e = new Promise(function(n) { @@ -7691,7 +7620,7 @@ function Qf(t) { })), e; }; } -function tm(t) { +function Wf(t) { var e = t.reduce(function(n, r) { var o = n[r.name]; return n[r.name] = o ? Object.assign({}, o, r, { @@ -7715,7 +7644,7 @@ function Ha() { return !(r && typeof r.getBoundingClientRect == "function"); }); } -function em(t) { +function qf(t) { t === void 0 && (t = {}); var e = t, n = e.defaultModifiers, r = n === void 0 ? [] : n, o = e.defaultOptions, a = o === void 0 ? Ga : o; return function(l, c, d) { @@ -7739,7 +7668,7 @@ function em(t) { reference: ke(l) ? fn(l) : l.contextElement ? fn(l.contextElement) : [], popper: fn(c) }; - var C = Zf(tm([].concat(r, p.options.modifiers))); + var C = Xf(Wf([].concat(r, p.options.modifiers))); return p.orderedModifiers = C.filter(function(S) { return S.enabled; }), v(), g.update(); @@ -7754,7 +7683,7 @@ function em(t) { var E = p.elements, _ = E.reference, C = E.popper; if (Ha(_, C)) { p.rects = { - reference: Kf(_, Pn(C), p.options.strategy === "fixed"), + reference: Gf(_, Pn(C), p.options.strategy === "fixed"), popper: Ao(C) }, p.reset = !1, p.placement = p.options.placement, p.orderedModifiers.forEach(function($) { return p.modifiersData[$.name] = Object.assign({}, $.data); @@ -7777,7 +7706,7 @@ function em(t) { }, // Async and optimistically optimized update – it will not be executed if // not necessary (debounced to run at most once-per-tick) - update: Qf(function() { + update: Yf(function() { return new Promise(function(m) { g.forceUpdate(), m(p); }); @@ -7814,16 +7743,16 @@ function em(t) { return g; }; } -var nm = [Sf, Uf, kf, uf, Lf, Df, Xf, vf, jf], rm = /* @__PURE__ */ em({ - defaultModifiers: nm +var Kf = [vf, Bf, gf, af, Mf, _f, zf, wf, $f], Jf = /* @__PURE__ */ qf({ + defaultModifiers: Kf }); -const Is = "Popper"; -function om(t) { - return ks(Is, t); +const Os = "Popper"; +function Zf(t) { + return bs(Os, t); } -qw(Is, ["root"]); -const am = ["anchorEl", "children", "direction", "disablePortal", "modifiers", "open", "placement", "popperOptions", "popperRef", "slotProps", "slots", "TransitionProps", "ownerState"], im = ["anchorEl", "children", "container", "direction", "disablePortal", "keepMounted", "modifiers", "open", "placement", "popperOptions", "popperRef", "style", "transition", "slotProps", "slots"]; -function sm(t, e) { +Uw(Os, ["root"]); +const Qf = ["anchorEl", "children", "direction", "disablePortal", "modifiers", "open", "placement", "popperOptions", "popperRef", "slotProps", "slots", "TransitionProps", "ownerState"], tm = ["anchorEl", "children", "container", "direction", "disablePortal", "keepMounted", "modifiers", "open", "placement", "popperOptions", "popperRef", "style", "transition", "slotProps", "slots"]; +function em(t, e) { if (e === "ltr") return t; switch (t) { @@ -7845,12 +7774,12 @@ function Zn(t) { function Nr(t) { return t.nodeType !== void 0; } -function lm(t) { +function nm(t) { return !Nr(t); } -const cm = () => xo({ +const rm = () => xo({ root: ["root"] -}, Lw(om)), dm = {}, pm = /* @__PURE__ */ M.forwardRef(function(e, n) { +}, Mw(Zf)), om = {}, am = /* @__PURE__ */ M.forwardRef(function(e, n) { var r; const { anchorEl: o, @@ -7867,11 +7796,11 @@ const cm = () => xo({ TransitionProps: f // @ts-ignore internal logic // prevent from spreading to DOM, it can come from the parent component e.g. Select. - } = e, m = kt(e, am), E = M.useRef(null), _ = xe(E, n), C = M.useRef(null), S = xe(C, w), b = M.useRef(S); + } = e, m = kt(e, Qf), E = M.useRef(null), _ = xe(E, n), C = M.useRef(null), S = xe(C, w), b = M.useRef(S); ze(() => { b.current = S; }, [S]), M.useImperativeHandle(w, () => C.current, []); - const I = sm(p, i), [z, H] = M.useState(I), [O, $] = M.useState(Zn(o)); + const I = em(p, i), [z, H] = M.useState(I), [O, $] = M.useState(Zn(o)); M.useEffect(() => { C.current && C.current.forceUpdate(); }), M.useEffect(() => { @@ -7908,7 +7837,7 @@ const cm = () => xo({ } }]; c != null && (U = U.concat(c)), h && h.modifiers != null && (U = U.concat(h.modifiers)); - const tt = rm(O, E.current, P({ + const tt = Jf(O, E.current, P({ placement: I }, h, { modifiers: U @@ -7921,7 +7850,7 @@ const cm = () => xo({ placement: z }; f !== null && (k.TransitionProps = f); - const B = cm(), D = (r = v.root) != null ? r : "div", J = Xw({ + const B = rm(), D = (r = v.root) != null ? r : "div", J = zw({ elementType: D, externalSlotProps: g.root, externalForwardedProps: m, @@ -7935,7 +7864,7 @@ const cm = () => xo({ return /* @__PURE__ */ s(D, P({}, J, { children: typeof a == "function" ? a(k) : a })); -}), As = /* @__PURE__ */ M.forwardRef(function(e, n) { +}), Rs = /* @__PURE__ */ M.forwardRef(function(e, n) { const { anchorEl: r, children: o, @@ -7946,13 +7875,13 @@ const cm = () => xo({ modifiers: d, open: p, placement: h = "bottom", - popperOptions: w = dm, + popperOptions: w = om, popperRef: g, style: v, transition: f = !1, slotProps: m = {}, slots: E = {} - } = e, _ = kt(e, im), [C, S] = M.useState(!0), b = () => { + } = e, _ = kt(e, tm), [C, S] = M.useState(!0), b = () => { S(!1); }, I = () => { S(!0); @@ -7974,7 +7903,7 @@ const cm = () => xo({ return /* @__PURE__ */ s(Kn, { disablePortal: l, container: z, - children: /* @__PURE__ */ s(pm, P({ + children: /* @__PURE__ */ s(am, P({ anchorEl: r, direction: i, disablePortal: l, @@ -8000,7 +7929,7 @@ const cm = () => xo({ })) }); }); -process.env.NODE_ENV !== "production" && (As.propTypes = { +process.env.NODE_ENV !== "production" && (Rs.propTypes = { // ┌────────────────────────────── Warning ──────────────────────────────┐ // │ These PropTypes are generated from the TypeScript type definitions. │ // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │ @@ -8019,7 +7948,7 @@ process.env.NODE_ENV !== "production" && (As.propTypes = { if (process.env.NODE_ENV !== "test" && n.top === 0 && n.left === 0 && n.right === 0 && n.bottom === 0) return new Error(["MUI: The `anchorEl` prop provided to the component is invalid.", "The anchor element should be part of the document layout.", "Make sure the element is present in the document or that it's not display none."].join(` `)); - } else if (!e || typeof e.getBoundingClientRect != "function" || lm(e) && e.contextElement != null && e.contextElement.nodeType !== 1) + } else if (!e || typeof e.getBoundingClientRect != "function" || nm(e) && e.contextElement != null && e.contextElement.nodeType !== 1) return new Error(["MUI: The `anchorEl` prop provided to the component is invalid.", "It should be an HTML element instance or a virtualElement ", "(https://popper.js.org/docs/v2/virtual-elements/)."].join(` `)); } @@ -8099,7 +8028,7 @@ process.env.NODE_ENV !== "production" && (As.propTypes = { /** * A ref that points to the used popper instance. */ - popperRef: is, + popperRef: es, /** * The props used for each slot inside the Popper. * @default {} @@ -8121,8 +8050,8 @@ process.env.NODE_ENV !== "production" && (As.propTypes = { */ transition: u.bool }); -function Ms() { - const t = bs(Oo); +function _s() { + const t = ws(Oo); return process.env.NODE_ENV !== "production" && M.useDebugValue(t), t[Ro] || t; } function ao(t, e) { @@ -8130,13 +8059,13 @@ function ao(t, e) { return r.__proto__ = o, r; }, ao(t, e); } -function um(t, e) { +function im(t, e) { t.prototype = Object.create(e.prototype), t.prototype.constructor = t, ao(t, e); } const Xa = { disabled: !1 }; -var wm = process.env.NODE_ENV !== "production" ? u.oneOfType([u.number, u.shape({ +var sm = process.env.NODE_ENV !== "production" ? u.oneOfType([u.number, u.shape({ enter: u.number, exit: u.number, appear: u.number @@ -8153,11 +8082,11 @@ process.env.NODE_ENV !== "production" && u.oneOfType([u.string, u.shape({ exitDone: u.string, exitActive: u.string })]); -const Ds = T.createContext(null); -var fm = function(e) { +const Ps = T.createContext(null); +var lm = function(e) { return e.scrollTop; }, cn = "unmounted", fe = "exited", me = "entering", Ae = "entered", io = "exiting", ee = /* @__PURE__ */ function(t) { - um(e, t); + im(e, t); function e(r, o) { var a; a = t.call(this, r, o) || this; @@ -8196,7 +8125,7 @@ var fm = function(e) { if (this.cancelNextCallback(), a === me) { if (this.props.unmountOnExit || this.props.mountOnEnter) { var i = this.props.nodeRef ? this.props.nodeRef.current : Bn.findDOMNode(this); - i && fm(i); + i && lm(i); } this.performEnter(o); } else @@ -8279,13 +8208,13 @@ var fm = function(e) { var l = kt(a, ["children", "in", "mountOnEnter", "unmountOnExit", "appear", "enter", "exit", "timeout", "addEndListener", "onEnter", "onEntering", "onEntered", "onExit", "onExiting", "onExited", "nodeRef"]); return ( // allows for nested Transitions - /* @__PURE__ */ T.createElement(Ds.Provider, { + /* @__PURE__ */ T.createElement(Ps.Provider, { value: null }, typeof i == "function" ? i(o, l) : T.cloneElement(T.Children.only(i), l)) ); }, e; }(T.Component); -ee.contextType = Ds; +ee.contextType = Ps; ee.propTypes = process.env.NODE_ENV !== "production" ? { /** * A React reference to DOM element that need to transition: @@ -8382,7 +8311,7 @@ ee.propTypes = process.env.NODE_ENV !== "production" ? { * @type {number | { enter?: number, exit?: number, appear?: number }} */ timeout: function(e) { - var n = wm; + var n = sm; e.addEndListener || (n = n.isRequired); for (var r = arguments.length, o = new Array(r > 1 ? r - 1 : 0), a = 1; a < r; a++) o[a - 1] = arguments[a]; @@ -8476,7 +8405,7 @@ ee.EXITED = fe; ee.ENTERING = me; ee.ENTERED = Ae; ee.EXITING = io; -const mm = ee, hm = (t) => t.scrollTop; +const cm = ee, dm = (t) => t.scrollTop; function Ya(t, e) { var n, r; const { @@ -8490,11 +8419,11 @@ function Ya(t, e) { delay: i.transitionDelay }; } -const gm = ["addEndListener", "appear", "children", "easing", "in", "onEnter", "onEntered", "onEntering", "onExit", "onExited", "onExiting", "style", "timeout", "TransitionComponent"]; +const pm = ["addEndListener", "appear", "children", "easing", "in", "onEnter", "onEntered", "onEntering", "onExit", "onExited", "onExiting", "style", "timeout", "TransitionComponent"]; function so(t) { return `scale(${t}, ${t ** 2})`; } -const bm = { +const um = { entering: { opacity: 1, transform: so(1) @@ -8519,14 +8448,14 @@ const bm = { style: v, timeout: f = "auto", // eslint-disable-next-line react/prop-types - TransitionComponent: m = mm - } = e, E = kt(e, gm), _ = sn(), C = M.useRef(), S = Ms(), b = M.useRef(null), I = xe(b, a.ref, n), z = (q) => (U) => { + TransitionComponent: m = cm + } = e, E = kt(e, pm), _ = sn(), C = M.useRef(), S = _s(), b = M.useRef(null), I = xe(b, a.ref, n), z = (q) => (U) => { if (q) { const tt = b.current; U === void 0 ? q(tt) : q(tt, U); } }, H = z(p), O = z((q, U) => { - hm(q); + dm(q); const { duration: tt, delay: at, @@ -8589,7 +8518,7 @@ const bm = { opacity: 0, transform: so(0.75), visibility: q === "exited" && !l ? "hidden" : void 0 - }, bm[q], v, a.props.style), + }, um[q], v, a.props.style), ref: I }, U)) })); @@ -8614,7 +8543,7 @@ process.env.NODE_ENV !== "production" && (Vo.propTypes = { /** * A single child content element. */ - children: os.isRequired, + children: Qi.isRequired, /** * The transition timing function. * You may specify a single easing or a object containing enter and exit values. @@ -8669,13 +8598,13 @@ process.env.NODE_ENV !== "production" && (Vo.propTypes = { })]) }); Vo.muiSupportAuto = !0; -const Wa = Vo, vm = ["anchorEl", "component", "components", "componentsProps", "container", "disablePortal", "keepMounted", "modifiers", "open", "placement", "popperOptions", "popperRef", "transition", "slots", "slotProps"], ym = Rn(As, { +const Wa = Vo, wm = ["anchorEl", "component", "components", "componentsProps", "container", "disablePortal", "keepMounted", "modifiers", "open", "placement", "popperOptions", "popperRef", "transition", "slots", "slotProps"], fm = Rn(Rs, { name: "MuiPopper", slot: "Root", overridesResolver: (t, e) => e.root -})({}), Bs = /* @__PURE__ */ M.forwardRef(function(e, n) { +})({}), $s = /* @__PURE__ */ M.forwardRef(function(e, n) { var r; - const o = gs(), a = _o({ + const o = us(), a = _o({ props: e, name: "MuiPopper" }), { @@ -8694,7 +8623,7 @@ const Wa = Vo, vm = ["anchorEl", "component", "components", "componentsProps", " transition: _, slots: C, slotProps: S - } = a, b = kt(a, vm), I = (r = C == null ? void 0 : C.root) != null ? r : c == null ? void 0 : c.Root, z = P({ + } = a, b = kt(a, wm), I = (r = C == null ? void 0 : C.root) != null ? r : c == null ? void 0 : c.Root, z = P({ anchorEl: i, container: p, disablePortal: h, @@ -8706,7 +8635,7 @@ const Wa = Vo, vm = ["anchorEl", "component", "components", "componentsProps", " popperRef: E, transition: _ }, b); - return /* @__PURE__ */ s(ym, P({ + return /* @__PURE__ */ s(fm, P({ as: l, direction: o == null ? void 0 : o.direction, slots: { @@ -8717,7 +8646,7 @@ const Wa = Vo, vm = ["anchorEl", "component", "components", "componentsProps", " ref: n })); }); -process.env.NODE_ENV !== "production" && (Bs.propTypes = { +process.env.NODE_ENV !== "production" && ($s.propTypes = { // ┌────────────────────────────── Warning ──────────────────────────────┐ // │ These PropTypes are generated from the TypeScript type definitions. │ // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │ @@ -8818,7 +8747,7 @@ process.env.NODE_ENV !== "production" && (Bs.propTypes = { /** * A ref that points to the used popper instance. */ - popperRef: is, + popperRef: es, /** * The props used for each slot inside the Popper. * @default {} @@ -8844,15 +8773,15 @@ process.env.NODE_ENV !== "production" && (Bs.propTypes = { */ transition: u.bool }); -const js = Bs; -function xm(t) { +const Is = $s; +function mm(t) { return pr("MuiTooltip", t); } -const Nm = ws("MuiTooltip", ["popper", "popperInteractive", "popperArrow", "popperClose", "tooltip", "tooltipArrow", "touch", "tooltipPlacementLeft", "tooltipPlacementRight", "tooltipPlacementTop", "tooltipPlacementBottom", "arrow"]), re = Nm, km = ["arrow", "children", "classes", "components", "componentsProps", "describeChild", "disableFocusListener", "disableHoverListener", "disableInteractive", "disableTouchListener", "enterDelay", "enterNextDelay", "enterTouchDelay", "followCursor", "id", "leaveDelay", "leaveTouchDelay", "onClose", "onOpen", "open", "placement", "PopperComponent", "PopperProps", "slotProps", "slots", "title", "TransitionComponent", "TransitionProps"]; -function Em(t) { +const hm = ls("MuiTooltip", ["popper", "popperInteractive", "popperArrow", "popperClose", "tooltip", "tooltipArrow", "touch", "tooltipPlacementLeft", "tooltipPlacementRight", "tooltipPlacementTop", "tooltipPlacementBottom", "arrow"]), re = hm, gm = ["arrow", "children", "classes", "components", "componentsProps", "describeChild", "disableFocusListener", "disableHoverListener", "disableInteractive", "disableTouchListener", "enterDelay", "enterNextDelay", "enterTouchDelay", "followCursor", "id", "leaveDelay", "leaveTouchDelay", "onClose", "onOpen", "open", "placement", "PopperComponent", "PopperProps", "slotProps", "slots", "title", "TransitionComponent", "TransitionProps"]; +function bm(t) { return Math.round(t * 1e5) / 1e5; } -const Sm = (t) => { +const vm = (t) => { const { classes: e, disableInteractive: n, @@ -8864,8 +8793,8 @@ const Sm = (t) => { tooltip: ["tooltip", r && "tooltipArrow", o && "touch", `tooltipPlacement${Wt(a.split("-")[0])}`], arrow: ["arrow"] }; - return xo(i, xm, e); -}, Tm = Rn(js, { + return xo(i, mm, e); +}, ym = Rn(Is, { name: "MuiTooltip", slot: "Popper", overridesResolver: (t, e) => { @@ -8926,7 +8855,7 @@ const Sm = (t) => { transformOrigin: "0 0" } }) -})), Cm = Rn("div", { +})), xm = Rn("div", { name: "MuiTooltip", slot: "Tooltip", overridesResolver: (t, e) => { @@ -8939,7 +8868,7 @@ const Sm = (t) => { theme: t, ownerState: e }) => P({ - backgroundColor: t.vars ? t.vars.palette.Tooltip.bg : vs(t.palette.grey[700], 0.92), + backgroundColor: t.vars ? t.vars.palette.Tooltip.bg : fs(t.palette.grey[700], 0.92), borderRadius: (t.vars || t).shape.borderRadius, color: (t.vars || t).palette.common.white, fontFamily: t.typography.fontFamily, @@ -8955,7 +8884,7 @@ const Sm = (t) => { }, e.touch && { padding: "8px 16px", fontSize: t.typography.pxToRem(14), - lineHeight: `${Em(16 / 14)}em`, + lineHeight: `${bm(16 / 14)}em`, fontWeight: t.typography.fontWeightRegular }, { [`.${re.popper}[data-popper-placement*="left"] &`]: P({ @@ -8992,7 +8921,7 @@ const Sm = (t) => { }, e.touch && { marginTop: "24px" }) -})), Om = Rn("span", { +})), Nm = Rn("span", { name: "MuiTooltip", slot: "Arrow", overridesResolver: (t, e) => e.arrow @@ -9004,7 +8933,7 @@ const Sm = (t) => { width: "1em", height: "0.71em", boxSizing: "border-box", - color: t.vars ? t.vars.palette.Tooltip.bg : vs(t.palette.grey[700], 0.9), + color: t.vars ? t.vars.palette.Tooltip.bg : fs(t.palette.grey[700], 0.9), "&::before": { content: '""', margin: "auto", @@ -9026,7 +8955,7 @@ function Fn(t, e) { e && e(n), t(n); }; } -const Vs = /* @__PURE__ */ M.forwardRef(function(e, n) { +const As = /* @__PURE__ */ M.forwardRef(function(e, n) { var r, o, a, i, l, c, d, p, h, w, g, v, f, m, E, _, C, S, b; const I = _o({ props: e, @@ -9059,9 +8988,9 @@ const Vs = /* @__PURE__ */ M.forwardRef(function(e, n) { title: dt, TransitionComponent: A = Wa, TransitionProps: Nt - } = I, j = kt(I, km), xt = /* @__PURE__ */ M.isValidElement(H) ? H : /* @__PURE__ */ s("span", { + } = I, j = kt(I, gm), xt = /* @__PURE__ */ M.isValidElement(H) ? H : /* @__PURE__ */ s("span", { children: H - }), Ft = Ms(), ce = Ft.direction === "rtl", [St, In] = M.useState(), [Ut, Ee] = M.useState(null), de = M.useRef(!1), Se = J || rt, Te = sn(), Ce = sn(), pe = sn(), qe = sn(), [An, zo] = ls({ + }), Ft = _s(), ce = Ft.direction === "rtl", [St, In] = M.useState(), [Ut, Ee] = M.useState(null), de = M.useRef(!1), Se = J || rt, Te = sn(), Ce = sn(), pe = sn(), qe = sn(), [An, zo] = rs({ controlled: W, default: !1, name: "Tooltip", @@ -9077,7 +9006,7 @@ const Vs = /* @__PURE__ */ M.forwardRef(function(e, n) { `)); }, [dt, St, Q]); } - const kr = ss(y), Ke = M.useRef(), Mn = eo(() => { + const kr = ns(y), Ke = M.useRef(), Mn = eo(() => { Ke.current !== void 0 && (document.body.style.WebkitUserSelect = Ke.current, Ke.current = void 0), qe.clear(); }); M.useEffect(() => Mn, [Mn]); @@ -9104,22 +9033,22 @@ const Vs = /* @__PURE__ */ M.forwardRef(function(e, n) { }); }, { isFocusVisibleRef: Uo, - onBlur: Us, - onFocus: Gs, - ref: Hs - } = cs(), [, Go] = M.useState(!1), Ho = (Q) => { - Us(Q), Uo.current === !1 && (Go(!1), Fo(Q)); + onBlur: js, + onFocus: Vs, + ref: zs + } = os(), [, Go] = M.useState(!1), Ho = (Q) => { + js(Q), Uo.current === !1 && (Go(!1), Fo(Q)); }, Xo = (Q) => { - St || In(Q.currentTarget), Gs(Q), Uo.current === !0 && (Go(!0), Er(Q)); + St || In(Q.currentTarget), Vs(Q), Uo.current === !0 && (Go(!0), Er(Q)); }, Yo = (Q) => { de.current = !0; const Pt = xt.props; Pt.onTouchStart && Pt.onTouchStart(Q); - }, Wo = Er, qo = Fo, Xs = (Q) => { + }, Wo = Er, qo = Fo, Ls = (Q) => { Yo(Q), pe.clear(), Te.clear(), Mn(), Ke.current = document.body.style.WebkitUserSelect, document.body.style.WebkitUserSelect = "none", qe.start(at, () => { document.body.style.WebkitUserSelect = Ke.current, Er(Q); }); - }, Ys = (Q) => { + }, Fs = (Q) => { xt.props.onTouchEnd && xt.props.onTouchEnd(Q), Mn(), pe.start(L, () => { Dn(Q); }); @@ -9134,9 +9063,9 @@ const Vs = /* @__PURE__ */ M.forwardRef(function(e, n) { document.removeEventListener("keydown", Q); }; }, [Dn, Kt]); - const Ws = xe(xt.ref, Hs, In, n); + const Us = xe(xt.ref, zs, In, n); !dt && dt !== 0 && (Kt = !1); - const Sr = M.useRef(), qs = (Q) => { + const Sr = M.useRef(), Gs = (Q) => { const Pt = xt.props; Pt.onMouseMove && Pt.onMouseMove(Q), on = { x: Q.clientX, @@ -9147,18 +9076,18 @@ const Vs = /* @__PURE__ */ M.forwardRef(function(e, n) { const Dt = P({}, Je, j, xt.props, { className: be(j.className, xt.props.className), onTouchStart: Yo, - ref: Ws + ref: Us }, rt ? { - onMouseMove: qs + onMouseMove: Gs } : {}); process.env.NODE_ENV !== "production" && (Dt["data-mui-internal-clone-element"] = !0, M.useEffect(() => { St && !St.getAttribute("data-mui-internal-clone-element") && console.error(["MUI: The `children` component of the Tooltip is not forwarding its props correctly.", "Please make sure that props are spread on the same element that the ref is applied to."].join(` `)); }, [St])); const Ze = {}; - q || (Dt.onTouchStart = Xs, Dt.onTouchEnd = Ys), D || (Dt.onMouseOver = Fn(Wo, Dt.onMouseOver), Dt.onMouseLeave = Fn(qo, Dt.onMouseLeave), Se || (Ze.onMouseOver = Wo, Ze.onMouseLeave = qo)), B || (Dt.onFocus = Fn(Xo, Dt.onFocus), Dt.onBlur = Fn(Ho, Dt.onBlur), Se || (Ze.onFocus = Xo, Ze.onBlur = Ho)), process.env.NODE_ENV !== "production" && xt.props.title && console.error(["MUI: You have provided a `title` prop to the child of .", `Remove this title prop \`${xt.props.title}\` or the Tooltip component.`].join(` + q || (Dt.onTouchStart = Ls, Dt.onTouchEnd = Fs), D || (Dt.onMouseOver = Fn(Wo, Dt.onMouseOver), Dt.onMouseLeave = Fn(qo, Dt.onMouseLeave), Se || (Ze.onMouseOver = Wo, Ze.onMouseLeave = qo)), B || (Dt.onFocus = Fn(Xo, Dt.onFocus), Dt.onBlur = Fn(Ho, Dt.onBlur), Se || (Ze.onFocus = Xo, Ze.onBlur = Ho)), process.env.NODE_ENV !== "production" && xt.props.title && console.error(["MUI: You have provided a `title` prop to the child of .", `Remove this title prop \`${xt.props.title}\` or the Tooltip component.`].join(` `)); - const Ks = M.useMemo(() => { + const Hs = M.useMemo(() => { var Q; let Pt = [{ name: "arrow", @@ -9178,16 +9107,16 @@ const Vs = /* @__PURE__ */ M.forwardRef(function(e, n) { placement: X, PopperComponentProp: Y, touch: de.current - }), Cr = Sm(Qe), Ko = (r = (o = Z.popper) != null ? o : O.Popper) != null ? r : Tm, Jo = (a = (i = (l = Z.transition) != null ? l : O.Transition) != null ? i : A) != null ? a : Wa, Zo = (c = (d = Z.tooltip) != null ? d : O.Tooltip) != null ? c : Cm, Qo = (p = (h = Z.arrow) != null ? h : O.Arrow) != null ? p : Om, Js = ln(Ko, P({}, G, (w = K.popper) != null ? w : $.popper, { + }), Cr = vm(Qe), Ko = (r = (o = Z.popper) != null ? o : O.Popper) != null ? r : ym, Jo = (a = (i = (l = Z.transition) != null ? l : O.Transition) != null ? i : A) != null ? a : Wa, Zo = (c = (d = Z.tooltip) != null ? d : O.Tooltip) != null ? c : xm, Qo = (p = (h = Z.arrow) != null ? h : O.Arrow) != null ? p : Nm, Xs = ln(Ko, P({}, G, (w = K.popper) != null ? w : $.popper, { className: be(Cr.popper, G == null ? void 0 : G.className, (g = (v = K.popper) != null ? v : $.popper) == null ? void 0 : g.className) - }), Qe), Zs = ln(Jo, P({}, Nt, (f = K.transition) != null ? f : $.transition), Qe), Qs = ln(Zo, P({}, (m = K.tooltip) != null ? m : $.tooltip, { + }), Qe), Ys = ln(Jo, P({}, Nt, (f = K.transition) != null ? f : $.transition), Qe), Ws = ln(Zo, P({}, (m = K.tooltip) != null ? m : $.tooltip, { className: be(Cr.tooltip, (E = (_ = K.tooltip) != null ? _ : $.tooltip) == null ? void 0 : E.className) - }), Qe), tl = ln(Qo, P({}, (C = K.arrow) != null ? C : $.arrow, { + }), Qe), qs = ln(Qo, P({}, (C = K.arrow) != null ? C : $.arrow, { className: be(Cr.arrow, (S = (b = K.arrow) != null ? b : $.arrow) == null ? void 0 : S.className) }), Qe); - return /* @__PURE__ */ x(M.Fragment, { + return /* @__PURE__ */ N(M.Fragment, { children: [/* @__PURE__ */ M.cloneElement(xt, Dt), /* @__PURE__ */ s(Ko, P({ - as: Y ?? js, + as: Y ?? Is, placement: X, anchorEl: rt ? { getBoundingClientRect: () => ({ @@ -9203,15 +9132,15 @@ const Vs = /* @__PURE__ */ M.forwardRef(function(e, n) { open: St ? Kt : !1, id: kr, transition: !0 - }, Ze, Js, { - popperOptions: Ks, + }, Ze, Xs, { + popperOptions: Hs, children: ({ TransitionProps: Q }) => /* @__PURE__ */ s(Jo, P({ timeout: Ft.transitions.duration.shorter - }, Q, Zs, { - children: /* @__PURE__ */ x(Zo, P({}, Qs, { - children: [dt, z ? /* @__PURE__ */ s(Qo, P({}, tl, { + }, Q, Ys, { + children: /* @__PURE__ */ N(Zo, P({}, Ws, { + children: [dt, z ? /* @__PURE__ */ s(Qo, P({}, qs, { ref: Ee })) : null] })) @@ -9219,7 +9148,7 @@ const Vs = /* @__PURE__ */ M.forwardRef(function(e, n) { }))] }); }); -process.env.NODE_ENV !== "production" && (Vs.propTypes = { +process.env.NODE_ENV !== "production" && (As.propTypes = { // ┌────────────────────────────── Warning ──────────────────────────────┐ // │ These PropTypes are generated from the TypeScript type definitions. │ // │ To update them, edit the d.ts file and run `pnpm proptypes`. │ @@ -9232,7 +9161,7 @@ process.env.NODE_ENV !== "production" && (Vs.propTypes = { /** * Tooltip reference element. */ - children: os.isRequired, + children: Qi.isRequired, /** * Override or extend the styles applied to the component. */ @@ -9412,11 +9341,11 @@ process.env.NODE_ENV !== "production" && (Vs.propTypes = { */ TransitionProps: u.object }); -const Rm = Vs; +const km = As; function Ka(t, e, n) { return t ? /* @__PURE__ */ s(ii, { className: `papi-menu-icon-${n ? "leading" : "trailing"}`, children: /* @__PURE__ */ s("img", { src: t, alt: `${n ? "Leading" : "Trailing"} icon for ${e}` }) }) : void 0; } -function zs(t) { +function Ms(t) { const { onClick: e, label: n, @@ -9435,7 +9364,7 @@ function zs(t) { id: f, children: m } = t, E = /* @__PURE__ */ s( - Fl, + Bl, { sx: { lineHeight: 0.8 }, autoFocus: l, @@ -9447,35 +9376,35 @@ function zs(t) { focusVisibleClassName: v, onClick: e, id: f, - children: n ? /* @__PURE__ */ x(ie, { children: [ + children: n ? /* @__PURE__ */ N(ie, { children: [ Ka(a, n, !0), - /* @__PURE__ */ s(Ul, { primary: n, inset: !a && o }), - h ? /* @__PURE__ */ s(ii, { className: "papi-menu-icon-trailing", children: /* @__PURE__ */ s(xs, {}) }) : Ka(i, n, !1) + /* @__PURE__ */ s(jl, { primary: n, inset: !a && o }), + h ? /* @__PURE__ */ s(ii, { className: "papi-menu-icon-trailing", children: /* @__PURE__ */ s(hs, {}) }) : Ka(i, n, !1) ] }) : m } ); - return r ? /* @__PURE__ */ s(Rm, { title: r, placement: "right", children: /* @__PURE__ */ s("div", { children: E }) }) : E; + return r ? /* @__PURE__ */ s(km, { title: r, placement: "right", children: /* @__PURE__ */ s("div", { children: E }) }) : E; } -function Ls(t) { +function Ds(t) { return Object.entries(t.groups).map(([n, r]) => ({ id: n, group: r })); } -function _m(t) { +function Em(t) { const [e, n] = ut(void 0), { parentMenuItem: r, parentItemProps: o, menuDefinition: a } = t, i = (d) => { n(d.currentTarget); }, l = () => { n(void 0); }, c = () => { - let d = Ls(a).filter((p) => "menuItem" in p.group); + let d = Ds(a).filter((p) => "menuItem" in p.group); if (!(r != null && r.id)) throw new Error("A valid parent menu item is required for submenus."); return d = d.filter( (p) => "menuItem" in p.group && p.group.menuItem === r.id - ), /* @__PURE__ */ s(Fs, { ...t, includedGroups: d }); + ), /* @__PURE__ */ s(Bs, { ...t, includedGroups: d }); }; - return /* @__PURE__ */ x(ie, { children: [ - /* @__PURE__ */ s(zs, { onClick: i, ...o, isSubMenuParent: !0 }), + return /* @__PURE__ */ N(ie, { children: [ + /* @__PURE__ */ s(Ms, { onClick: i, ...o, isSubMenuParent: !0 }), /* @__PURE__ */ s( - Gl, + Vl, { anchorEl: e, open: !!e, @@ -9494,18 +9423,18 @@ function _m(t) { ) ] }); } -const Pm = (t, e) => e.filter((o) => o.group === t).sort((o, a) => (o.order || 0) - (a.order || 0)); -function Fs(t) { +const Sm = (t, e) => e.filter((o) => o.group === t).sort((o, a) => (o.order || 0) - (a.order || 0)); +function Bs(t) { const { menuDefinition: e, onClick: n, commandHandler: r, includedGroups: o } = t, { items: a, allowForLeadingIcons: i } = It(() => { const p = o && o.length > 0 ? o : ( // We're apparently laying out a single-column menu (presumably a context menu). In this // case, all groups should be included except ones that belong to a submenu. - Ls(e).filter((v) => !("menuItem" in v.group)) + Ds(e).filter((v) => !("menuItem" in v.group)) ), h = Object.values(p).sort( (v, f) => (v.group.order || 0) - (f.group.order || 0) ), w = []; h.forEach((v) => { - Pm(v.id, e.items).forEach( + Sm(v.id, e.items).forEach( (f) => w.push({ item: f, isLastItemInGroup: !1 }) ), w.length > 0 && (w[w.length - 1].isLastItemInGroup = !0); }), w.length > 0 && (w[w.length - 1].isLastItemInGroup = !1); @@ -9531,7 +9460,7 @@ function Fs(t) { if ("command" in w) { const v = w.group + h; return /* @__PURE__ */ s( - zs, + Ms, { onClick: (f) => { n == null || n(f), r(w); @@ -9542,7 +9471,7 @@ function Fs(t) { ); } return /* @__PURE__ */ s( - _m, + Em, { parentMenuItem: w, parentItemProps: g, @@ -9552,16 +9481,16 @@ function Fs(t) { ); }) }, d); } -function $m(t) { +function Tm(t) { const { menuDefinition: e, columnId: n } = t; let a = Object.entries(e.groups).map(([i, l]) => ({ id: i, group: l })).filter((i) => "column" in i.group); return n && "columns" in e && // Without this type assertion, TS doesn't know what columns is. // eslint-disable-next-line no-type-assertion/no-type-assertion e.columns[n] && (a = a.filter( (i) => "column" in i.group && i.group.column === n - )), /* @__PURE__ */ s(Fs, { ...t, includedGroups: a }); + )), /* @__PURE__ */ s(Bs, { ...t, includedGroups: a }); } -function Im({ +function Cm({ commandHandler: t, menuDefinition: e, id: n, @@ -9569,7 +9498,7 @@ function Im({ onClick: o, className: a }) { - return /* @__PURE__ */ x( + return /* @__PURE__ */ N( si, { id: n, @@ -9580,8 +9509,8 @@ function Im({ className: `papi-menu-column ${a ?? ""}`, children: [ /* @__PURE__ */ s("h3", { "aria-label": r.label, className: `papi-menu-column-header ${a ?? ""}`, children: r.label }), - /* @__PURE__ */ s(Hl, { id: n, dense: !0, className: a ?? "", children: /* @__PURE__ */ s( - $m, + /* @__PURE__ */ s(zl, { id: n, dense: !0, className: a ?? "", children: /* @__PURE__ */ s( + Tm, { commandHandler: t, menuDefinition: e, @@ -9593,7 +9522,7 @@ function Im({ } ); } -function Am({ +function Om({ commandHandler: t, className: e, multiColumnMenu: n, @@ -9621,7 +9550,7 @@ function Am({ "aria-label": "GridMenu", id: r, children: a.map((i, l) => /* @__PURE__ */ s( - Im, + Cm, { commandHandler: t, menuDefinition: n, @@ -9633,7 +9562,7 @@ function Am({ } ); } -function Mm(t) { +function Rm(t) { return { preserveValue: !0, ...t @@ -9643,7 +9572,7 @@ const lo = (t, e, n = {}) => { const r = ge(e); r.current = e; const o = ge(n); - o.current = Mm(o.current); + o.current = Rm(o.current); const [a, i] = ut(() => r.current), [l, c] = ut(!0); return ae(() => { let d = !0; @@ -9656,10 +9585,10 @@ const lo = (t, e, n = {}) => { d = !1, o.current.preserveValue || i(() => r.current); }; }, [t]), [a, l]; -}, Dm = ys(/* @__PURE__ */ s("path", { +}, _m = ms(/* @__PURE__ */ s("path", { d: "M3 18h18v-2H3zm0-5h18v-2H3zm0-7v2h18V6z" }), "Menu"); -function Bm({ +function Pm({ menuProvider: t, normalMenu: e, fullMenu: n, @@ -9696,7 +9625,7 @@ function Bm({ Et(async () => (t == null ? void 0 : t(!0)) ?? n ?? E, [t, n, E, c]), n ?? E ), C = p && _ ? _ : E; - return /* @__PURE__ */ x(ie, { children: [ + return /* @__PURE__ */ N(ie, { children: [ /* @__PURE__ */ s( li, { @@ -9709,11 +9638,11 @@ function Bm({ color: "inherit", "aria-label": `${i ?? ""} menu button`, onClick: g, - children: l ?? /* @__PURE__ */ s(Dm, {}) + children: l ?? /* @__PURE__ */ s(_m, {}) } ), /* @__PURE__ */ s( - Xl, + Ll, { className: `papi-menu-drawer ${a ?? ""}`, anchor: "left", @@ -9728,7 +9657,7 @@ function Bm({ } }, children: C ? /* @__PURE__ */ s( - Am, + Om, { className: a, id: `${i ?? ""} main menu`, @@ -9740,7 +9669,7 @@ function Bm({ ) ] }); } -function Ah({ +function Ih({ id: t, label: e, isDisabled: n = !1, @@ -9767,9 +9696,9 @@ function Ah({ } ); } -const $n = Qn(({ className: t, ...e }, n) => /* @__PURE__ */ s(Nl, { size: 35, className: N("tw-animate-spin", t), ...e, ref: n })); +const $n = Qn(({ className: t, ...e }, n) => /* @__PURE__ */ s(gl, { size: 35, className: x("tw-animate-spin", t), ...e, ref: n })); $n.displayName = "Spinner"; -function Mh({ +function Ah({ id: t, isDisabled: e = !1, hasError: n = !1, @@ -9785,12 +9714,12 @@ function Mh({ onFocus: w, onBlur: g }) { - return /* @__PURE__ */ x("div", { className: N("tw-inline-grid tw-items-center tw-gap-1.5", { "tw-w-full": r }), children: [ + return /* @__PURE__ */ N("div", { className: x("tw-inline-grid tw-items-center tw-gap-1.5", { "tw-w-full": r }), children: [ /* @__PURE__ */ s( Xt, { htmlFor: t, - className: N({ + className: x({ "tw-text-red-600": n, "tw-hidden": !a }), @@ -9804,7 +9733,7 @@ function Mh({ disabled: e, placeholder: i, required: l, - className: N(c, { "tw-border-red-600": n }), + className: x(c, { "tw-border-red-600": n }), defaultValue: d, value: p, onChange: h, @@ -9812,10 +9741,10 @@ function Mh({ onBlur: g } ), - /* @__PURE__ */ s("p", { className: N({ "tw-hidden": !o }), children: o }) + /* @__PURE__ */ s("p", { className: x({ "tw-hidden": !o }), children: o }) ] }); } -function Dh({ +function Mh({ menuProvider: t, commandHandler: e, className: n, @@ -9823,14 +9752,14 @@ function Dh({ children: o }) { const a = ge(void 0); - return /* @__PURE__ */ s("div", { ref: a, style: { position: "relative" }, children: /* @__PURE__ */ s(Yl, { position: "static", id: r, children: /* @__PURE__ */ x( - Wl, + return /* @__PURE__ */ s("div", { ref: a, style: { position: "relative" }, children: /* @__PURE__ */ s(Fl, { position: "static", id: r, children: /* @__PURE__ */ N( + Ul, { - className: N("tw-bg-muted tw-text-muted-foreground", n), + className: x("tw-bg-muted tw-text-muted-foreground", n), variant: "dense", children: [ t ? /* @__PURE__ */ s( - Bm, + Pm, { commandHandler: e, containerRef: a, @@ -9842,7 +9771,7 @@ function Dh({ } ) }) }); } -const jm = Xe( +const $m = Xe( "tw-relative tw-w-full tw-rounded-lg tw-border tw-p-4 [&>svg~*]:tw-pl-7 [&>svg+div]:tw-translate-y-[-3px] [&>svg]:tw-absolute [&>svg]:tw-left-4 [&>svg]:tw-top-4 [&>svg]:tw-text-foreground", { variants: { @@ -9855,14 +9784,14 @@ const jm = Xe( variant: "default" } } -), Vm = T.forwardRef(({ className: t, variant: e, ...n }, r) => /* @__PURE__ */ s("div", { ref: r, role: "alert", className: N(jm({ variant: e }), t), ...n })); -Vm.displayName = "Alert"; -const zm = T.forwardRef( - ({ className: t, ...e }, n) => /* @__PURE__ */ x( +), Im = T.forwardRef(({ className: t, variant: e, ...n }, r) => /* @__PURE__ */ s("div", { ref: r, role: "alert", className: x($m({ variant: e }), t), ...n })); +Im.displayName = "Alert"; +const Am = T.forwardRef( + ({ className: t, ...e }, n) => /* @__PURE__ */ N( "h5", { ref: n, - className: N("tw-mb-1 tw-font-medium tw-leading-none tw-tracking-tight", t), + className: x("tw-mb-1 tw-font-medium tw-leading-none tw-tracking-tight", t), ...e, children: [ e.children, @@ -9871,12 +9800,69 @@ const zm = T.forwardRef( } ) ); -zm.displayName = "AlertTitle"; -const Lm = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s("div", { ref: n, className: N("tw-text-sm [&_p]:tw-leading-relaxed", t), ...e })); -Lm.displayName = "AlertDescription"; -function Bh({ ...t }) { +Am.displayName = "AlertTitle"; +const Mm = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s("div", { ref: n, className: x("tw-text-sm [&_p]:tw-leading-relaxed", t), ...e })); +Mm.displayName = "AlertDescription"; +const Dm = T.forwardRef( + ({ className: t, ...e }, n) => /* @__PURE__ */ s( + "div", + { + ref: n, + className: x( + "pr-twp tw-rounded-lg tw-border tw-bg-card tw-text-card-foreground tw-shadow-sm", + t + ), + ...e + } + ) +); +Dm.displayName = "Card"; +const Bm = T.forwardRef( + ({ className: t, ...e }, n) => /* @__PURE__ */ s( + "div", + { + ref: n, + className: x("pr-twp tw-flex tw-flex-col tw-space-y-1.5 tw-p-6", t), + ...e + } + ) +); +Bm.displayName = "CardHeader"; +const jm = T.forwardRef( + ({ className: t, ...e }, n) => /* @__PURE__ */ s( + "h3", + { + ref: n, + className: x( + "pr-twp tw-text-2xl tw-font-semibold tw-leading-none tw-tracking-tight", + t + ), + ...e, + children: e.children + } + ) +); +jm.displayName = "CardTitle"; +const Vm = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s("p", { ref: n, className: x("pr-twp tw-text-sm tw-text-muted-foreground", t), ...e })); +Vm.displayName = "CardDescription"; +const zm = T.forwardRef( + ({ className: t, ...e }, n) => /* @__PURE__ */ s("div", { ref: n, className: x("pr-twp tw-p-6 tw-pt-0", t), ...e }) +); +zm.displayName = "CardContent"; +const Lm = T.forwardRef( + ({ className: t, ...e }, n) => /* @__PURE__ */ s( + "div", + { + ref: n, + className: x("pr-twp tw-flex tw-items-center tw-p-6 tw-pt-0", t), + ...e + } + ) +); +Lm.displayName = "CardFooter"; +function Dh({ ...t }) { return /* @__PURE__ */ s( - Kl, + Hl, { className: "tw-toaster tw-group", toastOptions: { @@ -9891,11 +9877,11 @@ function Bh({ ...t }) { } ); } -const Fm = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ x( +const Fm = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ N( an.Root, { ref: n, - className: N( + className: x( "pr-twp tw-relative tw-flex tw-w-full tw-touch-none tw-select-none tw-items-center", t ), @@ -9910,7 +9896,7 @@ Fm.displayName = an.Root.displayName; const Um = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( Yr.Root, { - className: N( + className: x( "tw-peer pr-twp tw-inline-flex tw-h-6 tw-w-11 tw-shrink-0 tw-cursor-pointer tw-items-center tw-rounded-full tw-border-2 tw-border-transparent tw-transition-colors focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 focus-visible:tw-ring-offset-background disabled:tw-cursor-not-allowed disabled:tw-opacity-50 data-[state=checked]:tw-bg-primary data-[state=unchecked]:tw-bg-input", t ), @@ -9919,7 +9905,7 @@ const Um = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( children: /* @__PURE__ */ s( Yr.Thumb, { - className: N( + className: x( "pr-twp tw-pointer-events-none tw-block tw-h-5 tw-w-5 tw-rounded-full tw-bg-background tw-shadow-lg tw-ring-0 tw-transition-transform data-[state=checked]:tw-translate-x-5 data-[state=unchecked]:tw-translate-x-0" ) } @@ -9927,11 +9913,11 @@ const Um = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( } )); Um.displayName = Yr.Root.displayName; -const jh = _t.Root, Gm = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( +const Bh = _t.Root, Gm = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( _t.List, { ref: n, - className: N( + className: x( "tw-inline-flex tw-h-10 tw-items-center tw-justify-center tw-rounded-md tw-bg-muted tw-p-1 tw-text-muted-foreground", t ), @@ -9943,7 +9929,7 @@ const Hm = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( _t.Trigger, { ref: n, - className: N( + className: x( "tw-inline-flex tw-items-center tw-justify-center tw-whitespace-nowrap tw-rounded-sm tw-px-3 tw-py-1.5 tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-all hover:tw-text-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50 data-[state=active]:tw-bg-background data-[state=active]:tw-text-foreground data-[state=active]:tw-shadow-sm", t ), @@ -9955,7 +9941,7 @@ const Xm = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( _t.Content, { ref: n, - className: N( + className: x( "tw-mt-2 tw-ring-offset-background focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2", t ), @@ -9963,7 +9949,7 @@ const Xm = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( } )); Xm.displayName = _t.Content.displayName; -function Vh({ +function jh({ isInstalling: t, handleClick: e, buttonText: n, @@ -9973,7 +9959,7 @@ function Vh({ return /* @__PURE__ */ s( gt, { - className: N( + className: x( "tw-h-8 tw-rounded-md tw-text-white tw-transition tw-duration-300 tw-ease-in-out hover:tw-bg-blue-700", { "tw-cursor-not-allowed tw-bg-blue-700": t, @@ -9985,14 +9971,14 @@ function Vh({ ), onClick: e, ...o, - children: t ? /* @__PURE__ */ s($n, { size: 15 }) : /* @__PURE__ */ x(ie, { children: [ - /* @__PURE__ */ s(kl, { size: 25, className: N("tw-h-4 tw-w-4", { "tw-mr-1": n }) }), + children: t ? /* @__PURE__ */ s($n, { size: 15 }) : /* @__PURE__ */ N(ie, { children: [ + /* @__PURE__ */ s(bl, { size: 25, className: x("tw-h-4 tw-w-4", { "tw-mr-1": n }) }), n ] }) } ); } -function zh({ +function Vh({ isEnabling: t, handleClick: e, className: n, @@ -10001,7 +9987,7 @@ function zh({ return /* @__PURE__ */ s( gt, { - className: N( + className: x( "tw-h-8 tw-rounded-md tw-bg-blue-600 tw-px-4 tw-text-white tw-transition tw-duration-300 tw-ease-in-out hover:tw-bg-blue-700", { "tw-cursor-not-allowed tw-bg-blue-700": t @@ -10010,14 +9996,14 @@ function zh({ ), onClick: e, ...r, - children: t ? /* @__PURE__ */ x(ie, { children: [ + children: t ? /* @__PURE__ */ N(ie, { children: [ /* @__PURE__ */ s($n, { size: 15, className: "tw-mr-1 tw-text-white" }), "Enabling..." ] }) : "Enable" } ); } -function Lh({ +function zh({ isDisabling: t, handleClick: e, className: n, @@ -10026,7 +10012,7 @@ function Lh({ return /* @__PURE__ */ s( gt, { - className: N( + className: x( "tw-h-8 tw-rounded-md tw-bg-gray-300 tw-text-black tw-transition tw-duration-300 tw-ease-in-out hover:tw-bg-gray-400", { "tw-cursor-not-allowed tw-bg-gray-400": t @@ -10035,14 +10021,14 @@ function Lh({ ), onClick: e, ...r, - children: t ? /* @__PURE__ */ x(ie, { children: [ + children: t ? /* @__PURE__ */ N(ie, { children: [ /* @__PURE__ */ s($n, { size: 15, className: "tw-mr-1 tw-text-black" }), "Disabling..." ] }) : "Disable" } ); } -function Fh({ +function Lh({ isUpdating: t, handleClick: e, className: n, @@ -10051,7 +10037,7 @@ function Fh({ return /* @__PURE__ */ s( gt, { - className: N( + className: x( "tw-h-8 tw-rounded-md tw-bg-blue-600 tw-px-4 tw-text-white tw-transition tw-duration-300 tw-ease-in-out hover:tw-bg-blue-700 hover:tw-text-white", { "tw-cursor-not-allowed tw-bg-blue-700": t @@ -10060,14 +10046,14 @@ function Fh({ ), onClick: e, ...r, - children: t ? /* @__PURE__ */ x(ie, { children: [ + children: t ? /* @__PURE__ */ N(ie, { children: [ /* @__PURE__ */ s($n, { size: 15, className: "tw-mr-1 tw-text-white" }), "Updating..." ] }) : "Update" } ); } -function Uh({ +function Fh({ id: t, markdown: e, className: n, @@ -10085,16 +10071,16 @@ function Uh({ }), [r] ); - return /* @__PURE__ */ s("div", { id: t, className: N("pr-twp tw-prose", n), children: /* @__PURE__ */ s(Jl, { options: o, children: e }) }); + return /* @__PURE__ */ s("div", { id: t, className: x("pr-twp tw-prose", n), children: /* @__PURE__ */ s(Xl, { options: o, children: e }) }); } -const Ym = Qn((t, e) => /* @__PURE__ */ x( +const Ym = Qn((t, e) => /* @__PURE__ */ N( gt, { ref: e, className: "tw-rounded-md tw-border tw-border-dashed tw-border-gray-400 tw-bg-white tw-px-4 tw-py-2 tw-text-black tw-transition tw-duration-300 tw-ease-in-out hover:tw-border-blue-600 hover:tw-bg-white hover:tw-text-blue-600", ...t, children: [ - /* @__PURE__ */ s(El, { size: 16, className: "tw-mr-2 tw-h-4 tw-w-4 tw-text-gray-700 hover:tw-text-blue-600" }), + /* @__PURE__ */ s(vl, { size: 16, className: "tw-mr-2 tw-h-4 tw-w-4 tw-text-gray-700 hover:tw-text-blue-600" }), "Filter", /* @__PURE__ */ s( er, @@ -10107,52 +10093,52 @@ const Ym = Qn((t, e) => /* @__PURE__ */ x( } )); var Wm = /* @__PURE__ */ ((t) => (t[t.Check = 0] = "Check", t[t.Radio = 1] = "Radio", t))(Wm || {}); -function Gh({ id: t, groups: e }) { - return /* @__PURE__ */ s("div", { id: t, children: /* @__PURE__ */ x(fo, { children: [ +function Uh({ id: t, groups: e }) { + return /* @__PURE__ */ s("div", { id: t, children: /* @__PURE__ */ N(fo, { children: [ /* @__PURE__ */ s(mi, { asChild: !0, children: /* @__PURE__ */ s(Ym, {}) }), - /* @__PURE__ */ s(rr, { children: e.map((n) => /* @__PURE__ */ x("div", { children: [ + /* @__PURE__ */ s(rr, { children: e.map((n) => /* @__PURE__ */ N("div", { children: [ /* @__PURE__ */ s(Sn, { children: n.label }), - /* @__PURE__ */ s(uc, { children: n.items.map((r) => /* @__PURE__ */ s("div", { children: r.itemType === 0 ? /* @__PURE__ */ s(mo, { onClick: r.onClick, children: r.label }) : /* @__PURE__ */ s(gi, { onClick: r.onClick, value: r.label, children: r.label }) }, r.label)) }), + /* @__PURE__ */ s(sc, { children: n.items.map((r) => /* @__PURE__ */ s("div", { children: r.itemType === 0 ? /* @__PURE__ */ s(mo, { onClick: r.onClick, children: r.label }) : /* @__PURE__ */ s(gi, { onClick: r.onClick, value: r.label, children: r.label }) }, r.label)) }), /* @__PURE__ */ s(or, {}) ] }, n.label)) }) ] }) }); } -function Hh({ id: t, message: e }) { +function Gh({ id: t, message: e }) { return /* @__PURE__ */ s("div", { id: t, className: "tw-mb-20 tw-mt-20 tw-flex tw-items-center tw-justify-center", children: /* @__PURE__ */ s("div", { className: "tw-w-3/4 tw-rounded-lg tw-bg-gray-100 tw-p-8 tw-text-center", children: /* @__PURE__ */ s("p", { className: "tw-text-lg tw-text-gray-800", children: e }) }) }); } -function Xh({ +function Hh({ id: t, category: e, downloads: n, languages: r, moreInfoUrl: o }) { - const a = new Il("en", { + const a = new Ol("en", { notation: "compact", compactDisplay: "short" }).format(Object.values(n).reduce((l, c) => l + c, 0)), i = () => { window.scrollTo(0, document.body.scrollHeight); }; - return /* @__PURE__ */ x( + return /* @__PURE__ */ N( "div", { id: t, className: "tw-flex tw-flex-wrap tw-items-start tw-space-x-4 tw-border-b tw-border-t tw-bg-white tw-pb-4 tw-pt-4", children: [ - /* @__PURE__ */ x("div", { className: "tw-flex tw-flex-col tw-items-center", children: [ + /* @__PURE__ */ N("div", { className: "tw-flex tw-flex-col tw-items-center", children: [ /* @__PURE__ */ s("div", { className: "tw-flex tw-items-center tw-rounded-md tw-bg-gray-100 tw-px-2 tw-py-1", children: /* @__PURE__ */ s("span", { className: "tw-text-xs tw-font-semibold tw-text-gray-700", children: e }) }), /* @__PURE__ */ s("span", { className: "tw-text-xs tw-text-gray-500", children: "CATEGORY" }) ] }), /* @__PURE__ */ s("div", { className: "tw-mx-2 tw-h-10 tw-border-l tw-border-gray-300" }), - /* @__PURE__ */ x("div", { className: "tw-flex tw-flex-col tw-items-center", children: [ - /* @__PURE__ */ x("div", { className: "tw-flex tw-items-center tw-rounded-md tw-bg-gray-100 tw-px-2 tw-py-1", children: [ - /* @__PURE__ */ s(Sl, { className: "tw-mr-1 tw-h-4 tw-w-4" }), + /* @__PURE__ */ N("div", { className: "tw-flex tw-flex-col tw-items-center", children: [ + /* @__PURE__ */ N("div", { className: "tw-flex tw-items-center tw-rounded-md tw-bg-gray-100 tw-px-2 tw-py-1", children: [ + /* @__PURE__ */ s(yl, { className: "tw-mr-1 tw-h-4 tw-w-4" }), /* @__PURE__ */ s("span", { className: "tw-text-xs tw-font-semibold tw-text-gray-700", children: a }) ] }), /* @__PURE__ */ s("span", { className: "tw-text-xs tw-text-gray-500", children: "USERS" }) ] }), /* @__PURE__ */ s("div", { className: "tw-mx-2 tw-h-10 tw-border-l tw-border-gray-300" }), - /* @__PURE__ */ x("div", { className: "tw-flex tw-flex-col tw-items-center", children: [ + /* @__PURE__ */ N("div", { className: "tw-flex tw-flex-col tw-items-center", children: [ /* @__PURE__ */ s("div", { className: "tw-flex tw-items-center", children: r.slice(0, 3).map((l) => /* @__PURE__ */ s( "span", { @@ -10161,7 +10147,7 @@ function Xh({ }, l )) }), - r.length > 3 && /* @__PURE__ */ x( + r.length > 3 && /* @__PURE__ */ N( "button", { type: "button", @@ -10176,8 +10162,8 @@ function Xh({ ) ] }), /* @__PURE__ */ s("div", { className: "tw-mx-2 tw-h-10 tw-border-l tw-border-gray-300" }), - /* @__PURE__ */ x("div", { className: "tw-ml-auto tw-flex tw-flex-col tw-space-y-2", children: [ - /* @__PURE__ */ x( + /* @__PURE__ */ N("div", { className: "tw-ml-auto tw-flex tw-flex-col tw-space-y-2", children: [ + /* @__PURE__ */ N( "a", { href: o, @@ -10186,11 +10172,11 @@ function Xh({ className: "tw-flex tw-items-center tw-text-xs tw-font-semibold tw-text-gray-500 tw-underline", children: [ "Website", - /* @__PURE__ */ s(Tl, { className: "tw-ml-1 tw-inline tw-h-4 tw-w-4" }) + /* @__PURE__ */ s(xl, { className: "tw-ml-1 tw-inline tw-h-4 tw-w-4" }) ] } ), - /* @__PURE__ */ x( + /* @__PURE__ */ N( "a", { href: "https://example.com", @@ -10199,7 +10185,7 @@ function Xh({ className: "tw-flex tw-items-center tw-text-xs tw-font-semibold tw-text-gray-500 tw-underline", children: [ "Support", - /* @__PURE__ */ s(Cl, { className: "tw-ml-1 tw-inline tw-h-4 tw-w-4" }) + /* @__PURE__ */ s(Nl, { className: "tw-ml-1 tw-inline tw-h-4 tw-w-4" }) ] } ) @@ -10216,12 +10202,12 @@ function qm({ id: t, versionHistory: e }) { return p > 0 ? g = `${p.toString()} year${p === 1 ? "" : "s"} ago` : h > 0 ? g = `${h.toString()} month${h === 1 ? "" : "s"} ago` : w === 0 ? g = "today" : g = `${w.toString()} day${w === 1 ? "" : "s"} ago`, g; } const i = Object.entries(e).sort((l, c) => c[0].localeCompare(l[0])); - return /* @__PURE__ */ x("div", { id: t, children: [ + return /* @__PURE__ */ N("div", { id: t, children: [ /* @__PURE__ */ s("h3", { className: "tw-text-md tw-font-semibold", children: "What`s New" }), - /* @__PURE__ */ s("ul", { className: "tw-list-disc tw-pl-5 tw-pr-4 tw-text-xs tw-text-gray-600", children: (n ? i : i.slice(0, 5)).map((l) => /* @__PURE__ */ x("div", { className: "tw-mt-3 tw-flex tw-justify-between", children: [ + /* @__PURE__ */ s("ul", { className: "tw-list-disc tw-pl-5 tw-pr-4 tw-text-xs tw-text-gray-600", children: (n ? i : i.slice(0, 5)).map((l) => /* @__PURE__ */ N("div", { className: "tw-mt-3 tw-flex tw-justify-between", children: [ /* @__PURE__ */ s("div", { className: "tw-text-gray-600", children: /* @__PURE__ */ s("li", { className: "tw-prose tw-text-xs", children: /* @__PURE__ */ s("span", { children: l[1].description }) }) }), - /* @__PURE__ */ x("div", { className: "tw-justify-end tw-text-right", children: [ - /* @__PURE__ */ x("div", { children: [ + /* @__PURE__ */ N("div", { className: "tw-justify-end tw-text-right", children: [ + /* @__PURE__ */ N("div", { children: [ "Version ", l[0] ] }), @@ -10239,30 +10225,30 @@ function qm({ id: t, versionHistory: e }) { ) ] }); } -function Yh({ +function Xh({ id: t, publisherDisplayName: e, fileSize: n, locales: r, versionHistory: o }) { - const a = It(() => Al(n), [n]), l = ((c) => { + const a = It(() => Rl(n), [n]), l = ((c) => { const d = new Intl.DisplayNames(navigator.language, { type: "language" }); return c.map((p) => d.of(p)); })(r); - return /* @__PURE__ */ s("div", { id: t, className: "tw-border-t tw-pb-4 tw-pt-4", children: /* @__PURE__ */ x("div", { className: "tw-md:flex-row tw-md:space-x-8 tw-flex tw-flex-col tw-space-x-0", children: [ + return /* @__PURE__ */ s("div", { id: t, className: "tw-border-t tw-pb-4 tw-pt-4", children: /* @__PURE__ */ N("div", { className: "tw-md:flex-row tw-md:space-x-8 tw-flex tw-flex-col tw-space-x-0", children: [ /* @__PURE__ */ s(qm, { versionHistory: o }), /* @__PURE__ */ s("div", { className: "tw-md:border-t-0 tw-md:border-l tw-md-h-auto tw-md-ml-8 tw-mt-4 tw-border-t tw-border-gray-300" }), - /* @__PURE__ */ x("div", { className: "tw-md:mt-0 tw-mt-4 tw-flex-1 tw-space-y-3", children: [ + /* @__PURE__ */ N("div", { className: "tw-md:mt-0 tw-mt-4 tw-flex-1 tw-space-y-3", children: [ /* @__PURE__ */ s("h2", { className: "tw-text-md tw-font-semibold", children: "Information" }), - /* @__PURE__ */ x("div", { className: "tw-flex tw-items-start tw-justify-between tw-pr-4 tw-text-xs tw-text-gray-600", children: [ - /* @__PURE__ */ x("p", { className: "tw-flex tw-flex-col tw-justify-start", children: [ + /* @__PURE__ */ N("div", { className: "tw-flex tw-items-start tw-justify-between tw-pr-4 tw-text-xs tw-text-gray-600", children: [ + /* @__PURE__ */ N("p", { className: "tw-flex tw-flex-col tw-justify-start", children: [ /* @__PURE__ */ s("span", { className: "tw-mb-2", children: "Publisher" }), /* @__PURE__ */ s("span", { className: "tw-font-semibold", children: e }), /* @__PURE__ */ s("span", { className: "tw-mb-2 tw-mt-4", children: "Size" }), /* @__PURE__ */ s("span", { className: "tw-font-semibold", children: a }) ] }), - /* @__PURE__ */ s("div", { className: "tw-flex tw-w-3/4 tw-items-center tw-justify-between tw-text-xs tw-text-gray-600", children: /* @__PURE__ */ x("p", { className: "tw-flex tw-flex-col tw-justify-start", children: [ + /* @__PURE__ */ s("div", { className: "tw-flex tw-w-3/4 tw-items-center tw-justify-between tw-text-xs tw-text-gray-600", children: /* @__PURE__ */ N("p", { className: "tw-flex tw-flex-col tw-justify-start", children: [ /* @__PURE__ */ s("span", { className: "tw-mb-2", children: "Languages" }), /* @__PURE__ */ s("span", { className: "tw-font-semibold", children: l.join(", ") }) ] }) }) @@ -10270,7 +10256,7 @@ function Yh({ ] }) ] }) }); } -const Wh = (t, e) => { +const Yh = (t, e) => { ae(() => { if (!t) return () => { @@ -10280,7 +10266,7 @@ const Wh = (t, e) => { n(); }; }, [t, e]); -}, Gr = () => !1, qh = (t, e) => { +}, Gr = () => !1, Wh = (t, e) => { const [n] = lo( Et(async () => { if (!t) @@ -13866,6 +13852,19 @@ video:where(.pr-twp,.pr-twp *) { color: rgb(76, 106, 76); background-color: rgb(214, 255, 152); } +.papi-menu-item { + background-color: transparent; +} + +.papi-menu-icon-trailing { + margin-left: 10px; + place-content: flex-end; +} + +.papi-menu-item img { + max-width: 24px; + max-height: 24px; +} .papi-icon-button { border: 0; border-radius: 3em; @@ -13902,45 +13901,32 @@ video:where(.pr-twp,.pr-twp *) { display: flex; gap: 8px; } -.papi-menu-item { - background-color: transparent; -} - -.papi-menu-icon-trailing { - margin-left: 10px; - place-content: flex-end; -} - -.papi-menu-item img { - max-width: 24px; - max-height: 24px; -} `, "top"); export { - Vm as Alert, - Lm as AlertDescription, - zm as AlertTitle, + Im as Alert, + Mm as AlertDescription, + Am as AlertTitle, bh as BOOK_SELECTOR_STRING_KEYS, gh as BookChapterControl, - jc as BookSelectionMode, + Ic as BookSelectionMode, vh as BookSelector, gt as Button, - Yi as Card, - Ji as CardContent, - Ki as CardDescription, - Vd as CardFooter, - Wi as CardHeader, - qi as CardTitle, - Bc as ChapterRangeSelector, + Dm as Card, + zm as CardContent, + Vm as CardDescription, + Lm as CardFooter, + Bm as CardHeader, + jm as CardTitle, + $c as ChapterRangeSelector, ho as Checkbox, - Ih as Checklist, + $h as Checklist, qr as ComboBox, - Xc as DataTable, - Lh as DisableButton, + Lc as DataTable, + zh as DisableButton, fo as DropdownMenu, mo as DropdownMenuCheckboxItem, rr as DropdownMenuContent, - uc as DropdownMenuGroup, + sc as DropdownMenuGroup, hi as DropdownMenuItem, Wm as DropdownMenuItemType, Sn as DropdownMenuLabel, @@ -13948,28 +13934,28 @@ export { hh as DropdownMenuRadioGroup, gi as DropdownMenuRadioItem, or as DropdownMenuSeparator, - mc as DropdownMenuShortcut, + dc as DropdownMenuShortcut, mh as DropdownMenuSub, - fc as DropdownMenuSubContent, - wc as DropdownMenuSubTrigger, + cc as DropdownMenuSubContent, + lc as DropdownMenuSubTrigger, mi as DropdownMenuTrigger, - zh as EnableButton, + Vh as EnableButton, Ym as FilterButton, - Gh as FilterDropdown, - Yh as Footer, - Am as GridMenu, - Bm as HamburgerMenuButton, + Uh as FilterDropdown, + Xh as Footer, + Om as GridMenu, + Pm as HamburgerMenuButton, kh as INVENTORY_STRING_KEYS, - Ah as IconButton, + Ih as IconButton, Ye as Input, - Vh as InstallButton, + jh as InstallButton, Eh as Inventory, Xt as Label, - Uh as MarkdownRenderer, - zs as MenuItem, - Xh as MoreInfo, + Fh as MarkdownRenderer, + Ms as MenuItem, + Hh as MoreInfo, Sh as NavigationContentSearch, - Hh as NoExtensionsFound, + Gh as NoExtensionsFound, bi as RadioGroup, Wr as RadioGroupItem, Ch as ScriptureResultsViewer, @@ -13977,59 +13963,58 @@ export { Pi as SearchBar, gn as Select, Be as SelectContent, - zc as SelectGroup, + Mc as SelectGroup, Gt as SelectItem, - Lc as SelectLabel, + Dc as SelectLabel, Ci as SelectScrollDownButton, Ti as SelectScrollUpButton, - Fc as SelectSeparator, + Bc as SelectSeparator, De as SelectTrigger, bn as SelectValue, go as Separator, - $h as SettingsCard, Rh as SettingsList, Ph as SettingsListHeader, _h as SettingsListItem, - Pd as SettingsSidebar, + Td as SettingsSidebar, Th as SettingsSidebarContentSearch, Fm as Slider, - Bh as Sonner, + Dh as Sonner, $n as Spinner, Um as Switch, ar as Table, sr as TableBody, - Hc as TableCaption, + zc as TableCaption, je as TableCell, - Gc as TableFooter, + Vc as TableFooter, vn as TableHead, ir as TableHeader, oe as TableRow, - jh as Tabs, + Bh as Tabs, Xm as TabsContent, Gm as TabsList, Hm as TabsTrigger, - Mh as TextField, + Ah as TextField, _i as ToggleGroup, Un as ToggleGroupItem, - Dh as Toolbar, - Fh as UpdateButton, + Mh as Toolbar, + Lh as UpdateButton, qm as VersionHistory, $i as VerticalTabs, Ai as VerticalTabsContent, Ii as VerticalTabsList, - ed as VerticalTabsTrigger, - Tc as buttonVariants, - N as cn, - qc as getBookNumFromId, - Wc as getLinesFromUSFM, + Kc as VerticalTabsTrigger, + xc as buttonVariants, + x as cn, + Gc as getBookNumFromId, + Uc as getLinesFromUSFM, oa as getNumberFromUSFM, - Kc as getStatusForItem, + Hc as getStatusForItem, xh as inventoryCountColumn, yh as inventoryItemColumn, Nh as inventoryStatusColumn, - Zh as sonner, - Wh as useEvent, - qh as useEventAsync, + Jh as sonner, + Yh as useEvent, + Wh as useEventAsync, lo as usePromise }; //# sourceMappingURL=index.js.map diff --git a/lib/platform-bible-react/dist/index.js.map b/lib/platform-bible-react/dist/index.js.map index 0acfd36a54..ac9b9185b7 100644 --- a/lib/platform-bible-react/dist/index.js.map +++ b/lib/platform-bible-react/dist/index.js.map @@ -1 +1 @@ -{"version":3,"file":"index.js","sources":["../src/utils/shadcn-ui.util.ts","../src/components/shadcn-ui/input.tsx","../src/components/advanced/book-chapter-control/book-chapter-input.component.tsx","../../../node_modules/@sillsdev/scripture/dist/index.es.js","../src/components/shadcn-ui/dropdown-menu.tsx","../src/components/advanced/book-chapter-control/book-menu-item.component.tsx","../src/components/advanced/book-chapter-control/chapter-select.component.tsx","../src/components/advanced/book-chapter-control/go-to-menu-item.component.tsx","../src/components/advanced/book-chapter-control/book-chapter-control.component.tsx","../src/components/shadcn-ui/button.tsx","../src/components/shadcn-ui/label.tsx","../src/components/shadcn-ui/radio-group.tsx","../src/components/shadcn-ui/popover.tsx","../src/components/shadcn-ui/dialog.tsx","../src/components/shadcn-ui/command.tsx","../src/components/basics/combo-box.component.tsx","../src/components/basics/chapter-range-selector.component.tsx","../src/components/advanced/book-selector.component.tsx","../src/components/advanced/data-table/data-table-column-toggle.component.tsx","../src/components/shadcn-ui/select.tsx","../src/components/advanced/data-table/data-table-pagination.component.tsx","../src/components/shadcn-ui/table.tsx","../src/components/advanced/data-table/data-table.component.tsx","../src/components/advanced/inventory/occurrences-table.component.tsx","../src/components/shadcn-ui/checkbox.tsx","../src/components/advanced/inventory/inventory-utils.ts","../src/components/shadcn-ui/toggle.tsx","../src/components/shadcn-ui/toggle-group.tsx","../src/components/advanced/inventory/inventory-columns.tsx","../src/components/advanced/inventory/inventory.component.tsx","../src/components/basics/search-bar.component.tsx","../src/components/basics/tabs-vertical.tsx","../src/components/advanced/tab-navigation-content-search.component.tsx","../src/components/shadcn-ui/separator.tsx","../src/components/shadcn-ui/sheet.tsx","../src/components/shadcn-ui/skeleton.tsx","../src/components/shadcn-ui/tooltip.tsx","../src/components/hooks/use-mobile.tsx","../src/components/shadcn-ui/sidebar.tsx","../src/components/advanced/settings-components/settings-sidebar.component.tsx","../src/components/advanced/settings-components/settings-sidebar-content-search.component.tsx","../src/components/advanced/scripture-results-viewer/scripture-results-viewer.component.tsx","../src/components/advanced/scroll-group-selector.component.tsx","../src/components/advanced/settings-components/settings-list.component.tsx","../src/components/shadcn-ui/card.tsx","../src/components/advanced/settings-components/settings-card.component.tsx","../src/components/basics/checklist.component.tsx","../../../node_modules/@babel/runtime/helpers/interopRequireDefault.js","../../../node_modules/@mui/utils/chainPropTypes/chainPropTypes.js","../../../node_modules/@babel/runtime/helpers/esm/extends.js","../../../node_modules/@mui/utils/deepmerge/deepmerge.js","../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.production.min.js","../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.development.js","../../../node_modules/prop-types/node_modules/react-is/index.js","../../../node_modules/object-assign/index.js","../../../node_modules/prop-types/lib/ReactPropTypesSecret.js","../../../node_modules/prop-types/lib/has.js","../../../node_modules/prop-types/checkPropTypes.js","../../../node_modules/prop-types/factoryWithTypeCheckers.js","../../../node_modules/prop-types/factoryWithThrowingShims.js","../../../node_modules/prop-types/index.js","../../../node_modules/@mui/utils/elementAcceptingRef/elementAcceptingRef.js","../../../node_modules/@mui/utils/exactProp/exactProp.js","../../../node_modules/@mui/utils/formatMuiErrorMessage/formatMuiErrorMessage.js","../../../node_modules/react-is/cjs/react-is.production.min.js","../../../node_modules/react-is/cjs/react-is.development.js","../../../node_modules/react-is/index.js","../../../node_modules/@mui/utils/getDisplayName/getDisplayName.js","../../../node_modules/@mui/utils/HTMLElementType/HTMLElementType.js","../../../node_modules/@mui/utils/refType/refType.js","../../../node_modules/@mui/utils/capitalize/capitalize.js","../../../node_modules/@mui/utils/createChainedFunction/createChainedFunction.js","../../../node_modules/@mui/utils/debounce/debounce.js","../../../node_modules/@mui/utils/deprecatedPropType/deprecatedPropType.js","../../../node_modules/@mui/utils/isMuiElement/isMuiElement.js","../../../node_modules/@mui/utils/ownerDocument/ownerDocument.js","../../../node_modules/@mui/utils/ownerWindow/ownerWindow.js","../../../node_modules/@mui/utils/requirePropFactory/requirePropFactory.js","../../../node_modules/@mui/utils/setRef/setRef.js","../../../node_modules/@mui/utils/useEnhancedEffect/useEnhancedEffect.js","../../../node_modules/@mui/utils/useId/useId.js","../../../node_modules/@mui/utils/unsupportedProp/unsupportedProp.js","../../../node_modules/@mui/utils/useControlled/useControlled.js","../../../node_modules/@mui/utils/useEventCallback/useEventCallback.js","../../../node_modules/@mui/utils/useForkRef/useForkRef.js","../../../node_modules/@mui/utils/useLazyRef/useLazyRef.js","../../../node_modules/@mui/utils/useOnMount/useOnMount.js","../../../node_modules/@mui/utils/useTimeout/useTimeout.js","../../../node_modules/@mui/utils/useIsFocusVisible/useIsFocusVisible.js","../../../node_modules/@mui/utils/resolveProps/resolveProps.js","../../../node_modules/@mui/utils/composeClasses/composeClasses.js","../../../node_modules/@mui/utils/ClassNameGenerator/ClassNameGenerator.js","../../../node_modules/@mui/utils/generateUtilityClass/generateUtilityClass.js","../../../node_modules/@mui/utils/generateUtilityClasses/generateUtilityClasses.js","../../../node_modules/@mui/utils/clamp/clamp.js","../../../node_modules/@babel/runtime/helpers/esm/objectWithoutPropertiesLoose.js","../../../node_modules/@mui/system/esm/createTheme/createBreakpoints.js","../../../node_modules/@mui/system/esm/createTheme/shape.js","../../../node_modules/@mui/system/esm/responsivePropType.js","../../../node_modules/@mui/system/esm/merge.js","../../../node_modules/@mui/system/esm/breakpoints.js","../../../node_modules/@mui/system/esm/style.js","../../../node_modules/@mui/system/esm/memoize.js","../../../node_modules/@mui/system/esm/spacing.js","../../../node_modules/@mui/system/esm/createTheme/createSpacing.js","../../../node_modules/@mui/system/esm/compose.js","../../../node_modules/@mui/system/esm/borders.js","../../../node_modules/@mui/system/esm/cssGrid.js","../../../node_modules/@mui/system/esm/palette.js","../../../node_modules/@mui/system/esm/sizing.js","../../../node_modules/@mui/system/esm/styleFunctionSx/defaultSxConfig.js","../../../node_modules/@mui/system/esm/styleFunctionSx/styleFunctionSx.js","../../../node_modules/@mui/system/esm/createTheme/applyStyles.js","../../../node_modules/@mui/system/esm/createTheme/createTheme.js","../../../node_modules/@mui/system/esm/useThemeWithoutDefault.js","../../../node_modules/@mui/system/esm/useTheme.js","../../../node_modules/@mui/system/esm/createStyled.js","../../../node_modules/@mui/system/esm/useThemeProps/getThemeProps.js","../../../node_modules/@mui/system/esm/useThemeProps/useThemeProps.js","../../../node_modules/@mui/system/esm/colorManipulator.js","../../../node_modules/@mui/material/styles/createMixins.js","../../../node_modules/@mui/material/colors/common.js","../../../node_modules/@mui/material/colors/grey.js","../../../node_modules/@mui/material/colors/purple.js","../../../node_modules/@mui/material/colors/red.js","../../../node_modules/@mui/material/colors/orange.js","../../../node_modules/@mui/material/colors/blue.js","../../../node_modules/@mui/material/colors/lightBlue.js","../../../node_modules/@mui/material/colors/green.js","../../../node_modules/@mui/material/styles/createPalette.js","../../../node_modules/@mui/material/styles/createTypography.js","../../../node_modules/@mui/material/styles/shadows.js","../../../node_modules/@mui/material/styles/createTransitions.js","../../../node_modules/@mui/material/styles/zIndex.js","../../../node_modules/@mui/material/styles/createTheme.js","../../../node_modules/@mui/material/styles/defaultTheme.js","../../../node_modules/@mui/material/styles/identifier.js","../../../node_modules/@mui/material/styles/useThemeProps.js","../../../node_modules/@mui/material/styles/styled.js","../../../node_modules/@mui/material/SvgIcon/svgIconClasses.js","../../../node_modules/@mui/material/SvgIcon/SvgIcon.js","../../../node_modules/@mui/material/utils/createSvgIcon.js","../../../node_modules/@mui/material/utils/index.js","../../../node_modules/@mui/icons-material/utils/createSvgIcon.js","../../../node_modules/@mui/icons-material/ArrowRight.js","../../../node_modules/@mui/base/utils/isHostComponent.js","../../../node_modules/@mui/base/utils/appendOwnerState.js","../../../node_modules/@mui/base/utils/ClassNameConfigurator.js","../../../node_modules/@mui/base/utils/extractEventHandlers.js","../../../node_modules/@mui/base/utils/resolveComponentProps.js","../../../node_modules/@mui/base/utils/omitEventHandlers.js","../../../node_modules/@mui/base/utils/mergeSlotProps.js","../../../node_modules/@mui/base/utils/useSlotProps.js","../../../node_modules/@mui/base/generateUtilityClass/index.js","../../../node_modules/@mui/base/generateUtilityClasses/index.js","../../../node_modules/@mui/base/Portal/Portal.js","../../../node_modules/@popperjs/core/lib/enums.js","../../../node_modules/@popperjs/core/lib/dom-utils/getNodeName.js","../../../node_modules/@popperjs/core/lib/dom-utils/getWindow.js","../../../node_modules/@popperjs/core/lib/dom-utils/instanceOf.js","../../../node_modules/@popperjs/core/lib/modifiers/applyStyles.js","../../../node_modules/@popperjs/core/lib/utils/getBasePlacement.js","../../../node_modules/@popperjs/core/lib/utils/math.js","../../../node_modules/@popperjs/core/lib/utils/userAgent.js","../../../node_modules/@popperjs/core/lib/dom-utils/isLayoutViewport.js","../../../node_modules/@popperjs/core/lib/dom-utils/getBoundingClientRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/getLayoutRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/contains.js","../../../node_modules/@popperjs/core/lib/dom-utils/getComputedStyle.js","../../../node_modules/@popperjs/core/lib/dom-utils/isTableElement.js","../../../node_modules/@popperjs/core/lib/dom-utils/getDocumentElement.js","../../../node_modules/@popperjs/core/lib/dom-utils/getParentNode.js","../../../node_modules/@popperjs/core/lib/dom-utils/getOffsetParent.js","../../../node_modules/@popperjs/core/lib/utils/getMainAxisFromPlacement.js","../../../node_modules/@popperjs/core/lib/utils/within.js","../../../node_modules/@popperjs/core/lib/utils/getFreshSideObject.js","../../../node_modules/@popperjs/core/lib/utils/mergePaddingObject.js","../../../node_modules/@popperjs/core/lib/utils/expandToHashMap.js","../../../node_modules/@popperjs/core/lib/modifiers/arrow.js","../../../node_modules/@popperjs/core/lib/utils/getVariation.js","../../../node_modules/@popperjs/core/lib/modifiers/computeStyles.js","../../../node_modules/@popperjs/core/lib/modifiers/eventListeners.js","../../../node_modules/@popperjs/core/lib/utils/getOppositePlacement.js","../../../node_modules/@popperjs/core/lib/utils/getOppositeVariationPlacement.js","../../../node_modules/@popperjs/core/lib/dom-utils/getWindowScroll.js","../../../node_modules/@popperjs/core/lib/dom-utils/getWindowScrollBarX.js","../../../node_modules/@popperjs/core/lib/dom-utils/getViewportRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/getDocumentRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/isScrollParent.js","../../../node_modules/@popperjs/core/lib/dom-utils/getScrollParent.js","../../../node_modules/@popperjs/core/lib/dom-utils/listScrollParents.js","../../../node_modules/@popperjs/core/lib/utils/rectToClientRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/getClippingRect.js","../../../node_modules/@popperjs/core/lib/utils/computeOffsets.js","../../../node_modules/@popperjs/core/lib/utils/detectOverflow.js","../../../node_modules/@popperjs/core/lib/utils/computeAutoPlacement.js","../../../node_modules/@popperjs/core/lib/modifiers/flip.js","../../../node_modules/@popperjs/core/lib/modifiers/hide.js","../../../node_modules/@popperjs/core/lib/modifiers/offset.js","../../../node_modules/@popperjs/core/lib/modifiers/popperOffsets.js","../../../node_modules/@popperjs/core/lib/utils/getAltAxis.js","../../../node_modules/@popperjs/core/lib/modifiers/preventOverflow.js","../../../node_modules/@popperjs/core/lib/dom-utils/getHTMLElementScroll.js","../../../node_modules/@popperjs/core/lib/dom-utils/getNodeScroll.js","../../../node_modules/@popperjs/core/lib/dom-utils/getCompositeRect.js","../../../node_modules/@popperjs/core/lib/utils/orderModifiers.js","../../../node_modules/@popperjs/core/lib/utils/debounce.js","../../../node_modules/@popperjs/core/lib/utils/mergeByName.js","../../../node_modules/@popperjs/core/lib/createPopper.js","../../../node_modules/@popperjs/core/lib/popper.js","../../../node_modules/@mui/base/Popper/popperClasses.js","../../../node_modules/@mui/base/Popper/Popper.js","../../../node_modules/@mui/material/styles/useTheme.js","../../../node_modules/@babel/runtime/helpers/esm/setPrototypeOf.js","../../../node_modules/@babel/runtime/helpers/esm/inheritsLoose.js","../../../node_modules/react-transition-group/esm/config.js","../../../node_modules/react-transition-group/esm/utils/PropTypes.js","../../../node_modules/react-transition-group/esm/TransitionGroupContext.js","../../../node_modules/react-transition-group/esm/utils/reflow.js","../../../node_modules/react-transition-group/esm/Transition.js","../../../node_modules/@mui/material/transitions/utils.js","../../../node_modules/@mui/material/Grow/Grow.js","../../../node_modules/@mui/material/Popper/Popper.js","../../../node_modules/@mui/material/Tooltip/tooltipClasses.js","../../../node_modules/@mui/material/Tooltip/Tooltip.js","../src/components/mui/menu-item.component.tsx","../src/components/mui/grouped-menu-item-list.component.tsx","../src/components/mui/top-level-menu.component.tsx","../src/components/mui/grid-menu.component.tsx","../src/hooks/use-promise.hook.ts","../../../node_modules/@mui/icons-material/esm/Menu.js","../src/components/mui/hamburger-menu-button.component.tsx","../src/components/mui/icon-button.component.tsx","../src/components/basics/spinner.component.tsx","../src/components/basics/text-field.component.tsx","../src/components/mui/toolbar.component.tsx","../src/components/shadcn-ui/alert.tsx","../src/components/shadcn-ui/sonner.tsx","../src/components/shadcn-ui/slider.tsx","../src/components/shadcn-ui/switch.tsx","../src/components/shadcn-ui/tabs.tsx","../src/components/advanced/extension-marketplace/buttons/install-button.component.tsx","../src/components/advanced/extension-marketplace/buttons/enable-button.component.tsx","../src/components/advanced/extension-marketplace/buttons/disable-button.component.tsx","../src/components/advanced/extension-marketplace/buttons/update-button.component.tsx","../src/components/advanced/extension-marketplace/markdown-renderer.component.tsx","../src/components/advanced/extension-marketplace/buttons/filter-button.component.tsx","../src/components/advanced/extension-marketplace/filter-dropdown.component.tsx","../src/components/advanced/extension-marketplace/no-extensions-found.component.tsx","../src/components/advanced/extension-marketplace/more-info.component.tsx","../src/components/advanced/extension-marketplace/version-history.component.tsx","../src/components/advanced/extension-marketplace/footer.component.tsx","../src/hooks/use-event.hook.ts","../src/hooks/use-event-async.hook.ts"],"sourcesContent":["import { type ClassValue, clsx } from 'clsx';\nimport { extendTailwindMerge } from 'tailwind-merge';\n\nconst twMergeCustom = extendTailwindMerge({ prefix: 'tw-' });\n\n/**\n * Tailwind and CSS class application helper function. Uses\n * [`clsx`](https://www.npmjs.com/package/clsx) to make it easy to apply classes conditionally using\n * object syntax, and uses [`tailwind-merge`](https://www.npmjs.com/package/tailwind-merge) to make\n * it easy to merge/overwrite Tailwind classes in a programmer-logic-friendly way.\n *\n * Note: `tailwind-merge` is configured to use the prefix `tw-`, so you must use the same prefix\n * with any Tailwind classes you use with this function to successfully overwrite other Tailwind\n * classes. `platform-bible-react` is configured to use `tw-` as its Tailwind prefix, so any\n * Tailwind classes you pass into `platform-bible-react` components will be compared using the `tw-`\n * prefix.\n *\n * This function was popularized by\n * [shadcn/ui](https://ui.shadcn.com/docs/installation/manual#add-a-cn-helper). See [ByteGrad's\n * explanation video](https://www.youtube.com/watch?v=re2JFITR7TI) for more information.\n *\n * @example\n *\n * ```typescript\n * const borderShouldBeBlue = true;\n * const textShouldBeRed = true;\n * const heightShouldBe20 = false;\n * const classString = cn(\n * 'tw-bg-primary tw-h-10 tw-text-primary-foreground',\n * 'tw-bg-secondary',\n * {\n * 'tw-border-blue-500': borderShouldBeBlue,\n * 'tw-text-red-500': textShouldBeRed,\n * 'tw-h-20': heightShouldBe20,\n * },\n * 'some-class',\n * );\n * ```\n *\n * The resulting `classString` is `'tw-h-10 tw-bg-secondary tw-border-blue-500 tw-text-red-500\n * some-class'`\n *\n * - Notice that `'tw-bg-secondary'`, specified later, overwrote `'tw-bg-primary'`, specified earlier,\n * because they are Tailwind classes that affect the same css property\n * - Notice that `'tw-text-red-500'`, specified later, overwrote `'tw-text-primary-foreground'`,\n * specified earlier, because they are Tailwind classes that affect the same css property\n * - Notice that `'tw-h-20'`, specified later, did not overwrite `'tw-h-10'`, specified earlier,\n * because `'tw-h-20'` is part of a conditional class object and its value evaluated to `false`;\n * therefore it was not applied\n * - Notice that `'some-class'` was applied. This function is not limited only to Tailwind classes.\n *\n *\n * @param inputs Class strings or `clsx` conditional class objects to merge. Tailwind classes\n * specified later in the arguments overwrite similar Tailwind classes specified earlier in the\n * arguments\n * @returns Class string containing all applicable classes from the arguments based on the rules\n * described above\n */\n// shadcn/ui uses this export in its boilerplate code\n// eslint-disable-next-line import/prefer-default-export\nexport function cn(...inputs: ClassValue[]) {\n return twMergeCustom(clsx(inputs));\n}\n","import React from 'react';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport interface InputProps extends React.InputHTMLAttributes {}\n\nexport const Input = React.forwardRef(\n ({ className, type, ...props }, ref) => {\n return (\n \n );\n },\n);\nInput.displayName = 'Input';\n","import { FocusEventHandler, forwardRef, KeyboardEvent, MouseEventHandler } from 'react';\nimport { History } from 'lucide-react';\nimport { Input as ShadInput } from '@/components/shadcn-ui/input';\n\nexport type BookChapterInputProps = {\n handleSearch: (searchString: string) => void;\n handleKeyDown: (event: KeyboardEvent) => void;\n handleOnClick: MouseEventHandler;\n handleSubmit: () => void;\n onFocus?: FocusEventHandler;\n value: string;\n placeholder: string;\n};\n\n// Shadcn Input sets type to \"button\"- HAVE to prop spread before setting type\nconst BookChapterInput = forwardRef(\n (\n { handleSearch, handleKeyDown, handleOnClick, handleSubmit, ...props }: BookChapterInputProps,\n ref,\n ) => {\n return (\n
    \n handleSearch(event.target.value)}\n onKeyDown={(e) => {\n if (e.key === 'Enter') {\n handleSubmit();\n }\n handleKeyDown(e);\n }}\n onClick={handleOnClick}\n ref={ref}\n />\n {\n // eslint-disable-next-line no-console\n console.log('back in history');\n }}\n />\n
    \n );\n },\n);\n\nexport default BookChapterInput;\n","var P = Object.defineProperty;\nvar R = (t, e, s) => e in t ? P(t, e, { enumerable: !0, configurable: !0, writable: !0, value: s }) : t[e] = s;\nvar n = (t, e, s) => R(t, typeof e != \"symbol\" ? e + \"\" : e, s);\nclass _ {\n constructor() {\n n(this, \"books\");\n n(this, \"firstSelectedBookNum\");\n n(this, \"lastSelectedBookNum\");\n n(this, \"count\");\n n(this, \"selectedBookNumbers\");\n n(this, \"selectedBookIds\");\n }\n}\nconst N = [\n \"GEN\",\n \"EXO\",\n \"LEV\",\n \"NUM\",\n \"DEU\",\n \"JOS\",\n \"JDG\",\n \"RUT\",\n \"1SA\",\n \"2SA\",\n // 10\n \"1KI\",\n \"2KI\",\n \"1CH\",\n \"2CH\",\n \"EZR\",\n \"NEH\",\n \"EST\",\n \"JOB\",\n \"PSA\",\n \"PRO\",\n // 20\n \"ECC\",\n \"SNG\",\n \"ISA\",\n \"JER\",\n \"LAM\",\n \"EZK\",\n \"DAN\",\n \"HOS\",\n \"JOL\",\n \"AMO\",\n // 30\n \"OBA\",\n \"JON\",\n \"MIC\",\n \"NAM\",\n \"HAB\",\n \"ZEP\",\n \"HAG\",\n \"ZEC\",\n \"MAL\",\n \"MAT\",\n // 40\n \"MRK\",\n \"LUK\",\n \"JHN\",\n \"ACT\",\n \"ROM\",\n \"1CO\",\n \"2CO\",\n \"GAL\",\n \"EPH\",\n \"PHP\",\n // 50\n \"COL\",\n \"1TH\",\n \"2TH\",\n \"1TI\",\n \"2TI\",\n \"TIT\",\n \"PHM\",\n \"HEB\",\n \"JAS\",\n \"1PE\",\n // 60\n \"2PE\",\n \"1JN\",\n \"2JN\",\n \"3JN\",\n \"JUD\",\n \"REV\",\n \"TOB\",\n \"JDT\",\n \"ESG\",\n \"WIS\",\n // 70\n \"SIR\",\n \"BAR\",\n \"LJE\",\n \"S3Y\",\n \"SUS\",\n \"BEL\",\n \"1MA\",\n \"2MA\",\n \"3MA\",\n \"4MA\",\n // 80\n \"1ES\",\n \"2ES\",\n \"MAN\",\n \"PS2\",\n \"ODA\",\n \"PSS\",\n \"JSA\",\n // actual variant text for JOS, now in LXA text\n \"JDB\",\n // actual variant text for JDG, now in LXA text\n \"TBS\",\n // actual variant text for TOB, now in LXA text\n \"SST\",\n // actual variant text for SUS, now in LXA text // 90\n \"DNT\",\n // actual variant text for DAN, now in LXA text\n \"BLT\",\n // actual variant text for BEL, now in LXA text\n \"XXA\",\n \"XXB\",\n \"XXC\",\n \"XXD\",\n \"XXE\",\n \"XXF\",\n \"XXG\",\n \"FRT\",\n // 100\n \"BAK\",\n \"OTH\",\n \"3ES\",\n // Used previously but really should be 2ES\n \"EZA\",\n // Used to be called 4ES, but not actually in any known project\n \"5EZ\",\n // Used to be called 5ES, but not actually in any known project\n \"6EZ\",\n // Used to be called 6ES, but not actually in any known project\n \"INT\",\n \"CNC\",\n \"GLO\",\n \"TDX\",\n // 110\n \"NDX\",\n \"DAG\",\n \"PS3\",\n \"2BA\",\n \"LBA\",\n \"JUB\",\n \"ENO\",\n \"1MQ\",\n \"2MQ\",\n \"3MQ\",\n // 120\n \"REP\",\n \"4BA\",\n \"LAO\"\n], B = [\n \"XXA\",\n \"XXB\",\n \"XXC\",\n \"XXD\",\n \"XXE\",\n \"XXF\",\n \"XXG\",\n \"FRT\",\n \"BAK\",\n \"OTH\",\n \"INT\",\n \"CNC\",\n \"GLO\",\n \"TDX\",\n \"NDX\"\n], O = [\n \"Genesis\",\n \"Exodus\",\n \"Leviticus\",\n \"Numbers\",\n \"Deuteronomy\",\n \"Joshua\",\n \"Judges\",\n \"Ruth\",\n \"1 Samuel\",\n \"2 Samuel\",\n \"1 Kings\",\n \"2 Kings\",\n \"1 Chronicles\",\n \"2 Chronicles\",\n \"Ezra\",\n \"Nehemiah\",\n \"Esther (Hebrew)\",\n \"Job\",\n \"Psalms\",\n \"Proverbs\",\n \"Ecclesiastes\",\n \"Song of Songs\",\n \"Isaiah\",\n \"Jeremiah\",\n \"Lamentations\",\n \"Ezekiel\",\n \"Daniel (Hebrew)\",\n \"Hosea\",\n \"Joel\",\n \"Amos\",\n \"Obadiah\",\n \"Jonah\",\n \"Micah\",\n \"Nahum\",\n \"Habakkuk\",\n \"Zephaniah\",\n \"Haggai\",\n \"Zechariah\",\n \"Malachi\",\n \"Matthew\",\n \"Mark\",\n \"Luke\",\n \"John\",\n \"Acts\",\n \"Romans\",\n \"1 Corinthians\",\n \"2 Corinthians\",\n \"Galatians\",\n \"Ephesians\",\n \"Philippians\",\n \"Colossians\",\n \"1 Thessalonians\",\n \"2 Thessalonians\",\n \"1 Timothy\",\n \"2 Timothy\",\n \"Titus\",\n \"Philemon\",\n \"Hebrews\",\n \"James\",\n \"1 Peter\",\n \"2 Peter\",\n \"1 John\",\n \"2 John\",\n \"3 John\",\n \"Jude\",\n \"Revelation\",\n \"Tobit\",\n \"Judith\",\n \"Esther Greek\",\n \"Wisdom of Solomon\",\n \"Sirach (Ecclesiasticus)\",\n \"Baruch\",\n \"Letter of Jeremiah\",\n \"Song of 3 Young Men\",\n \"Susanna\",\n \"Bel and the Dragon\",\n \"1 Maccabees\",\n \"2 Maccabees\",\n \"3 Maccabees\",\n \"4 Maccabees\",\n \"1 Esdras (Greek)\",\n \"2 Esdras (Latin)\",\n \"Prayer of Manasseh\",\n \"Psalm 151\",\n \"Odes\",\n \"Psalms of Solomon\",\n // WARNING, if you change the spelling of the *obsolete* tag be sure to update\n // IsObsolete routine\n \"Joshua A. *obsolete*\",\n \"Judges B. *obsolete*\",\n \"Tobit S. *obsolete*\",\n \"Susanna Th. *obsolete*\",\n \"Daniel Th. *obsolete*\",\n \"Bel Th. *obsolete*\",\n \"Extra A\",\n \"Extra B\",\n \"Extra C\",\n \"Extra D\",\n \"Extra E\",\n \"Extra F\",\n \"Extra G\",\n \"Front Matter\",\n \"Back Matter\",\n \"Other Matter\",\n \"3 Ezra *obsolete*\",\n \"Apocalypse of Ezra\",\n \"5 Ezra (Latin Prologue)\",\n \"6 Ezra (Latin Epilogue)\",\n \"Introduction\",\n \"Concordance \",\n \"Glossary \",\n \"Topical Index\",\n \"Names Index\",\n \"Daniel Greek\",\n \"Psalms 152-155\",\n \"2 Baruch (Apocalypse)\",\n \"Letter of Baruch\",\n \"Jubilees\",\n \"Enoch\",\n \"1 Meqabyan\",\n \"2 Meqabyan\",\n \"3 Meqabyan\",\n \"Reproof (Proverbs 25-31)\",\n \"4 Baruch (Rest of Baruch)\",\n \"Laodiceans\"\n], S = K();\nfunction g(t, e = !0) {\n return e && (t = t.toUpperCase()), t in S ? S[t] : 0;\n}\nfunction k(t) {\n return g(t) > 0;\n}\nfunction x(t) {\n const e = typeof t == \"string\" ? g(t) : t;\n return e >= 40 && e <= 66;\n}\nfunction T(t) {\n return (typeof t == \"string\" ? g(t) : t) <= 39;\n}\nfunction X(t) {\n return t <= 66;\n}\nfunction V(t) {\n const e = typeof t == \"string\" ? g(t) : t;\n return w(e) && !X(e);\n}\nfunction* L() {\n for (let t = 1; t <= N.length; t++) yield t;\n}\nconst G = 1, A = N.length;\nfunction H() {\n return [\"XXA\", \"XXB\", \"XXC\", \"XXD\", \"XXE\", \"XXF\", \"XXG\"];\n}\nfunction C(t, e = \"***\") {\n const s = t - 1;\n return s < 0 || s >= N.length ? e : N[s];\n}\nfunction I(t) {\n return t <= 0 || t > A ? \"******\" : O[t - 1];\n}\nfunction y(t) {\n return I(g(t));\n}\nfunction w(t) {\n const e = typeof t == \"number\" ? C(t) : t;\n return k(e) && !B.includes(e);\n}\nfunction q(t) {\n const e = typeof t == \"number\" ? C(t) : t;\n return k(e) && B.includes(e);\n}\nfunction U(t) {\n return O[t - 1].includes(\"*obsolete*\");\n}\nfunction K() {\n const t = {};\n for (let e = 0; e < N.length; e++)\n t[N[e]] = e + 1;\n return t;\n}\nconst m = {\n allBookIds: N,\n nonCanonicalIds: B,\n bookIdToNumber: g,\n isBookIdValid: k,\n isBookNT: x,\n isBookOT: T,\n isBookOTNT: X,\n isBookDC: V,\n allBookNumbers: L,\n firstBook: G,\n lastBook: A,\n extraBooks: H,\n bookNumberToId: C,\n bookNumberToEnglishName: I,\n bookIdToEnglishName: y,\n isCanonical: w,\n isExtraMaterial: q,\n isObsolete: U\n};\nvar l = /* @__PURE__ */ ((t) => (t[t.Unknown = 0] = \"Unknown\", t[t.Original = 1] = \"Original\", t[t.Septuagint = 2] = \"Septuagint\", t[t.Vulgate = 3] = \"Vulgate\", t[t.English = 4] = \"English\", t[t.RussianProtestant = 5] = \"RussianProtestant\", t[t.RussianOrthodox = 6] = \"RussianOrthodox\", t))(l || {});\nconst h = class h {\n // private versInfo: Versification;\n constructor(e) {\n n(this, \"name\");\n n(this, \"fullPath\");\n n(this, \"isPresent\");\n n(this, \"hasVerseSegments\");\n n(this, \"isCustomized\");\n n(this, \"baseVersification\");\n n(this, \"scriptureBooks\");\n n(this, \"_type\");\n if (e == null)\n throw new Error(\"Argument undefined\");\n typeof e == \"string\" ? (this.name = e, this._type = l[e]) : (this._type = e, this.name = l[e]);\n }\n get type() {\n return this._type;\n }\n equals(e) {\n return !e.type || !this.type ? !1 : e.type === this.type;\n }\n};\nn(h, \"Original\", new h(l.Original)), n(h, \"Septuagint\", new h(l.Septuagint)), n(h, \"Vulgate\", new h(l.Vulgate)), n(h, \"English\", new h(l.English)), n(h, \"RussianProtestant\", new h(l.RussianProtestant)), n(h, \"RussianOrthodox\", new h(l.RussianOrthodox));\nlet c = h;\nfunction E(t, e) {\n const s = e[0];\n for (let r = 1; r < e.length; r++)\n t = t.split(e[r]).join(s);\n return t.split(s);\n}\nvar D = /* @__PURE__ */ ((t) => (t[t.Valid = 0] = \"Valid\", t[t.UnknownVersification = 1] = \"UnknownVersification\", t[t.OutOfRange = 2] = \"OutOfRange\", t[t.VerseOutOfOrder = 3] = \"VerseOutOfOrder\", t[t.VerseRepeated = 4] = \"VerseRepeated\", t))(D || {});\nconst i = class i {\n constructor(e, s, r, a) {\n /** Not yet implemented. */\n n(this, \"firstChapter\");\n /** Not yet implemented. */\n n(this, \"lastChapter\");\n /** Not yet implemented. */\n n(this, \"lastVerse\");\n /** Not yet implemented. */\n n(this, \"hasSegmentsDefined\");\n /** Not yet implemented. */\n n(this, \"text\");\n /** Not yet implemented. */\n n(this, \"BBBCCCVVVS\");\n /** Not yet implemented. */\n n(this, \"longHashCode\");\n /** The versification of the reference. */\n n(this, \"versification\");\n n(this, \"rtlMark\", \"‏\");\n n(this, \"_bookNum\", 0);\n n(this, \"_chapterNum\", 0);\n n(this, \"_verseNum\", 0);\n n(this, \"_verse\");\n if (r == null && a == null)\n if (e != null && typeof e == \"string\") {\n const o = e, u = s != null && s instanceof c ? s : void 0;\n this.setEmpty(u), this.parse(o);\n } else if (e != null && typeof e == \"number\") {\n const o = s != null && s instanceof c ? s : void 0;\n this.setEmpty(o), this._verseNum = e % i.chapterDigitShifter, this._chapterNum = Math.floor(\n e % i.bookDigitShifter / i.chapterDigitShifter\n ), this._bookNum = Math.floor(e / i.bookDigitShifter);\n } else if (s == null)\n if (e != null && e instanceof i) {\n const o = e;\n this._bookNum = o.bookNum, this._chapterNum = o.chapterNum, this._verseNum = o.verseNum, this._verse = o.verse, this.versification = o.versification;\n } else {\n if (e == null) return;\n const o = e instanceof c ? e : i.defaultVersification;\n this.setEmpty(o);\n }\n else\n throw new Error(\"VerseRef constructor not supported.\");\n else if (e != null && s != null && r != null)\n if (typeof e == \"string\" && typeof s == \"string\" && typeof r == \"string\")\n this.setEmpty(a), this.updateInternal(e, s, r);\n else if (typeof e == \"number\" && typeof s == \"number\" && typeof r == \"number\")\n this._bookNum = e, this._chapterNum = s, this._verseNum = r, this.versification = a ?? i.defaultVersification;\n else\n throw new Error(\"VerseRef constructor not supported.\");\n else\n throw new Error(\"VerseRef constructor not supported.\");\n }\n /**\n * Determines if the verse string is in a valid format (does not consider versification).\n */\n static isVerseParseable(e) {\n return e.length > 0 && \"0123456789\".includes(e[0]) && !e.endsWith(this.verseRangeSeparator) && !e.endsWith(this.verseSequenceIndicator);\n }\n /**\n * Tries to parse the specified string into a verse reference.\n * @param str - The string to attempt to parse.\n * @returns success: `true` if the specified string was successfully parsed, `false` otherwise.\n * @returns verseRef: The result of the parse if successful, or empty VerseRef if it failed\n */\n static tryParse(e) {\n let s;\n try {\n return s = new i(e), { success: !0, verseRef: s };\n } catch (r) {\n if (r instanceof v)\n return s = new i(), { success: !1, verseRef: s };\n throw r;\n }\n }\n /**\n * Gets the reference as a comparable integer where the book, chapter, and verse each occupy 3\n * digits.\n * @param bookNum - Book number (this is 1-based, not an index).\n * @param chapterNum - Chapter number.\n * @param verseNum - Verse number.\n * @returns The reference as a comparable integer where the book, chapter, and verse each occupy 3\n * digits.\n */\n static getBBBCCCVVV(e, s, r) {\n return e % i.bcvMaxValue * i.bookDigitShifter + (s >= 0 ? s % i.bcvMaxValue * i.chapterDigitShifter : 0) + (r >= 0 ? r % i.bcvMaxValue : 0);\n }\n /**\n * Deserializes a serialized VerseRef.\n * @param serializedVerseRef - Serialized VerseRef to create from.\n * @returns the deserialized VerseRef.\n */\n static fromJSON(e) {\n const { book: s, chapterNum: r, verseNum: a, verse: o, versificationStr: u } = e, f = o || a.toString();\n let d;\n return u && (d = new c(u)), s ? new i(s, r.toString(), f, d) : new i();\n }\n /**\n * Parses a verse string and gets the leading numeric portion as a number.\n * @param verseStr - verse string to parse\n * @returns true if the entire string could be parsed as a single, simple verse number (1-999);\n * false if the verse string represented a verse bridge, contained segment letters, or was invalid\n */\n static tryGetVerseNum(e) {\n let s;\n if (!e)\n return s = -1, { success: !0, vNum: s };\n s = 0;\n let r;\n for (let a = 0; a < e.length; a++) {\n if (r = e[a], r < \"0\" || r > \"9\")\n return a === 0 && (s = -1), { success: !1, vNum: s };\n if (s = s * 10 + +r - 0, s > i.bcvMaxValue)\n return s = -1, { success: !1, vNum: s };\n }\n return { success: !0, vNum: s };\n }\n /**\n * Checks to see if a VerseRef hasn't been set - all values are the default.\n */\n get isDefault() {\n return this.bookNum === 0 && this.chapterNum === 0 && this.verseNum === 0 && this.versification == null;\n }\n /**\n * Gets whether the verse contains multiple verses.\n */\n get hasMultiple() {\n return this._verse != null && (this._verse.includes(i.verseRangeSeparator) || this._verse.includes(i.verseSequenceIndicator));\n }\n /**\n * Gets or sets the book of the reference. Book is the 3-letter abbreviation in capital letters,\n * e.g. `'MAT'`.\n */\n get book() {\n return m.bookNumberToId(this.bookNum, \"\");\n }\n set book(e) {\n this.bookNum = m.bookIdToNumber(e);\n }\n /**\n * Gets or sets the chapter of the reference,. e.g. `'3'`.\n */\n get chapter() {\n return this.isDefault || this._chapterNum < 0 ? \"\" : this._chapterNum.toString();\n }\n set chapter(e) {\n const s = +e;\n this._chapterNum = Number.isInteger(s) ? s : -1;\n }\n /**\n * Gets or sets the verse of the reference, including range, segments, and sequences, e.g. `'4'`,\n * or `'4b-5a, 7'`.\n */\n get verse() {\n return this._verse != null ? this._verse : this.isDefault || this._verseNum < 0 ? \"\" : this._verseNum.toString();\n }\n set verse(e) {\n const { success: s, vNum: r } = i.tryGetVerseNum(e);\n this._verse = s ? void 0 : e.replace(this.rtlMark, \"\"), this._verseNum = r, !(this._verseNum >= 0) && ({ vNum: this._verseNum } = i.tryGetVerseNum(this._verse));\n }\n /**\n * Get or set Book based on book number, e.g. `42`.\n */\n get bookNum() {\n return this._bookNum;\n }\n set bookNum(e) {\n if (e <= 0 || e > m.lastBook)\n throw new v(\n \"BookNum must be greater than zero and less than or equal to last book\"\n );\n this._bookNum = e;\n }\n /**\n * Gets or sets the chapter number, e.g. `3`. `-1` if not valid.\n */\n get chapterNum() {\n return this._chapterNum;\n }\n set chapterNum(e) {\n this.chapterNum = e;\n }\n /**\n * Gets or sets verse start number, e.g. `4`. `-1` if not valid.\n */\n get verseNum() {\n return this._verseNum;\n }\n set verseNum(e) {\n this._verseNum = e;\n }\n /**\n * String representing the versification (should ONLY be used for serialization/deserialization).\n *\n * @remarks This is for backwards compatibility when ScrVers was an enumeration.\n */\n get versificationStr() {\n var e;\n return (e = this.versification) == null ? void 0 : e.name;\n }\n set versificationStr(e) {\n this.versification = this.versification != null ? new c(e) : void 0;\n }\n /**\n * Determines if the reference is valid.\n */\n get valid() {\n return this.validStatus === 0;\n }\n /**\n * Get the valid status for this reference.\n */\n get validStatus() {\n return this.validateVerse(i.verseRangeSeparators, i.verseSequenceIndicators);\n }\n /**\n * Gets the reference as a comparable integer where the book,\n * chapter, and verse each occupy three digits and the verse is 0.\n */\n get BBBCCC() {\n return i.getBBBCCCVVV(this._bookNum, this._chapterNum, 0);\n }\n /**\n * Gets the reference as a comparable integer where the book,\n * chapter, and verse each occupy three digits. If verse is not null\n * (i.e., this reference represents a complex reference with verse\n * segments or bridge) this cannot be used for an exact comparison.\n */\n get BBBCCCVVV() {\n return i.getBBBCCCVVV(this._bookNum, this._chapterNum, this._verseNum);\n }\n /**\n * Gets whether the verse is defined as an excluded verse in the versification.\n * Does not handle verse ranges.\n */\n // eslint-disable-next-line @typescript-eslint/class-literal-property-style\n get isExcluded() {\n return !1;\n }\n /**\n * Parses the reference in the specified string.\n * Optionally versification can follow reference as in GEN 3:11/4\n * Throw an exception if\n * - invalid book name\n * - chapter number is missing or not a number\n * - verse number is missing or does not start with a number\n * - versification is invalid\n * @param verseStr - string to parse e.g. 'MAT 3:11'\n */\n parse(e) {\n if (e = e.replace(this.rtlMark, \"\"), e.includes(\"/\")) {\n const o = e.split(\"/\");\n if (e = o[0], o.length > 1)\n try {\n const u = +o[1].trim();\n this.versification = new c(l[u]);\n } catch {\n throw new v(\"Invalid reference : \" + e);\n }\n }\n const s = e.trim().split(\" \");\n if (s.length !== 2)\n throw new v(\"Invalid reference : \" + e);\n const r = s[1].split(\":\"), a = +r[0];\n if (r.length !== 2 || m.bookIdToNumber(s[0]) === 0 || !Number.isInteger(a) || a < 0 || !i.isVerseParseable(r[1]))\n throw new v(\"Invalid reference : \" + e);\n this.updateInternal(s[0], r[0], r[1]);\n }\n /**\n * Simplifies this verse ref so that it has no bridging of verses or\n * verse segments like `'1a'`.\n */\n simplify() {\n this._verse = void 0;\n }\n /**\n * Makes a clone of the reference.\n *\n * @returns The cloned VerseRef.\n */\n clone() {\n return new i(this);\n }\n toString() {\n const e = this.book;\n return e === \"\" ? \"\" : `${e} ${this.chapter}:${this.verse}`;\n }\n toJSON() {\n let e = this.verse;\n (e === \"\" || e === this.verseNum.toString()) && (e = void 0);\n const s = {\n book: this.book,\n chapterNum: this.chapterNum,\n verseNum: this.verseNum,\n verse: e,\n versificationStr: this.versificationStr\n };\n return e || delete s.verse, s;\n }\n /**\n * Compares this `VerseRef` with supplied one.\n * @param verseRef - object to compare this one to.\n * @returns `true` if this `VerseRef` is equal to the supplied one, `false` otherwise.\n */\n equals(e) {\n return e instanceof i ? e._bookNum === this._bookNum && e._chapterNum === this._chapterNum && e._verseNum === this._verseNum && e.verse === this.verse && (e.versification == null && this.versification == null || e.versification != null && this.versification != null && e.versification.equals(this.versification)) : !1;\n }\n /**\n * Enumerate all individual verses contained in a VerseRef.\n * Verse ranges are indicated by \"-\" and consecutive verses by \",\"s.\n * Examples:\n * GEN 1:2 returns GEN 1:2\n * GEN 1:1a-3b,5 returns GEN 1:1a, GEN 1:2, GEN 1:3b, GEN 1:5\n * GEN 1:2a-2c returns //! ??????\n *\n * @param specifiedVersesOnly - if set to true return only verses that are\n * explicitly specified only, not verses within a range. Defaults to `false`.\n * @param verseRangeSeparators - Verse range separators.\n * Defaults to `VerseRef.verseRangeSeparators`.\n * @param verseSequenceSeparators - Verse sequence separators.\n * Defaults to `VerseRef.verseSequenceIndicators`.\n * @returns An array of all single verse references in this VerseRef.\n */\n allVerses(e = !1, s = i.verseRangeSeparators, r = i.verseSequenceIndicators) {\n if (this._verse == null || this.chapterNum <= 0)\n return [this.clone()];\n const a = [], o = E(this._verse, r);\n for (const u of o.map((f) => E(f, s))) {\n const f = this.clone();\n f.verse = u[0];\n const d = f.verseNum;\n if (a.push(f), u.length > 1) {\n const b = this.clone();\n if (b.verse = u[1], !e)\n for (let p = d + 1; p < b.verseNum; p++) {\n const J = new i(\n this._bookNum,\n this._chapterNum,\n p,\n this.versification\n );\n this.isExcluded || a.push(J);\n }\n a.push(b);\n }\n }\n return a;\n }\n /**\n * Validates a verse number using the supplied separators rather than the defaults.\n */\n validateVerse(e, s) {\n if (!this.verse)\n return this.internalValid;\n let r = 0;\n for (const a of this.allVerses(!0, e, s)) {\n const o = a.internalValid;\n if (o !== 0)\n return o;\n const u = a.BBBCCCVVV;\n if (r > u)\n return 3;\n if (r === u)\n return 4;\n r = u;\n }\n return 0;\n }\n /**\n * Gets whether a single verse reference is valid.\n */\n get internalValid() {\n return this.versification == null ? 1 : this._bookNum <= 0 || this._bookNum > m.lastBook ? 2 : (m.isCanonical(this._bookNum), 0);\n }\n setEmpty(e = i.defaultVersification) {\n this._bookNum = 0, this._chapterNum = -1, this._verse = void 0, this.versification = e;\n }\n updateInternal(e, s, r) {\n this.bookNum = m.bookIdToNumber(e), this.chapter = s, this.verse = r;\n }\n};\nn(i, \"defaultVersification\", c.English), n(i, \"verseRangeSeparator\", \"-\"), n(i, \"verseSequenceIndicator\", \",\"), n(i, \"verseRangeSeparators\", [i.verseRangeSeparator]), n(i, \"verseSequenceIndicators\", [i.verseSequenceIndicator]), n(i, \"chapterDigitShifter\", 1e3), n(i, \"bookDigitShifter\", i.chapterDigitShifter * i.chapterDigitShifter), n(i, \"bcvMaxValue\", i.chapterDigitShifter - 1), /**\n * The valid status of the VerseRef.\n */\nn(i, \"ValidStatusType\", D);\nlet M = i;\nclass v extends Error {\n}\nexport {\n _ as BookSet,\n m as Canon,\n c as ScrVers,\n l as ScrVersType,\n M as VerseRef,\n v as VerseRefException\n};\n//# sourceMappingURL=index.es.js.map\n","import React from 'react';\nimport * as DropdownMenuPrimitive from '@radix-ui/react-dropdown-menu';\nimport { Check, ChevronRight, Circle } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport const DropdownMenu = DropdownMenuPrimitive.Root;\n\nexport const DropdownMenuTrigger = DropdownMenuPrimitive.Trigger;\n\nexport const DropdownMenuGroup = DropdownMenuPrimitive.Group;\n\nexport const DropdownMenuPortal = DropdownMenuPrimitive.Portal;\n\nexport const DropdownMenuSub = DropdownMenuPrimitive.Sub;\n\nexport const DropdownMenuRadioGroup = DropdownMenuPrimitive.RadioGroup;\n\nexport type DropdownMenuSubTriggerProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.SubTrigger\n> & {\n className?: string;\n inset?: boolean;\n};\n\nexport type DropdownMenuSubContentProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.SubContent\n> & {\n className?: string;\n};\n\nexport type DropdownMenuContentProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Content\n> & {\n className?: string;\n sideOffset?: number;\n};\n\nexport type DropdownMenuItemProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Item\n> & {\n className?: string;\n inset?: boolean;\n};\n\nexport type DropdownMenuCheckboxItemProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.CheckboxItem\n> & {\n className?: string;\n checked?: boolean;\n};\n\nexport type DropdownMenuRadioItemProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.RadioItem\n> & {\n className?: string;\n};\n\nexport type DropdownMenuLabelProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Label\n> & {\n className?: string;\n inset?: boolean;\n};\n\nexport type DropdownMenuSeparatorProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Separator\n> & {\n className?: string;\n};\n\nexport type DropdownMenuShortcutProps = React.HTMLAttributes & {\n className?: string;\n};\n\nexport const DropdownMenuSubTrigger = React.forwardRef<\n React.ElementRef,\n DropdownMenuSubTriggerProps\n>(({ className, inset, children, ...props }, ref) => (\n \n {children}\n \n \n));\nDropdownMenuSubTrigger.displayName = DropdownMenuPrimitive.SubTrigger.displayName;\n\nexport const DropdownMenuSubContent = React.forwardRef<\n React.ElementRef,\n DropdownMenuSubContentProps\n>(({ className, ...props }, ref) => (\n \n));\nDropdownMenuSubContent.displayName = DropdownMenuPrimitive.SubContent.displayName;\n\nexport const DropdownMenuContent = React.forwardRef<\n React.ElementRef,\n DropdownMenuContentProps\n>(({ className, sideOffset = 4, ...props }, ref) => (\n \n \n \n));\nDropdownMenuContent.displayName = DropdownMenuPrimitive.Content.displayName;\n\n/**\n * TODO: fix: direction is not automatically handled by this component, so that shortcuts are\n * display always to the right\n */\nexport const DropdownMenuItem = React.forwardRef<\n React.ElementRef,\n DropdownMenuItemProps\n>(({ className, inset, ...props }, ref) => (\n \n));\nDropdownMenuItem.displayName = DropdownMenuPrimitive.Item.displayName;\n\nexport const DropdownMenuCheckboxItem = React.forwardRef<\n React.ElementRef,\n DropdownMenuCheckboxItemProps\n>(({ className, children, checked, ...props }, ref) => (\n \n \n \n \n \n \n {children}\n \n));\nDropdownMenuCheckboxItem.displayName = DropdownMenuPrimitive.CheckboxItem.displayName;\n\nexport const DropdownMenuRadioItem = React.forwardRef<\n React.ElementRef,\n DropdownMenuRadioItemProps\n>(({ className, children, ...props }, ref) => (\n \n \n \n \n \n \n {children}\n \n));\nDropdownMenuRadioItem.displayName = DropdownMenuPrimitive.RadioItem.displayName;\n\nexport const DropdownMenuLabel = React.forwardRef<\n React.ElementRef,\n DropdownMenuLabelProps\n>(({ className, inset, ...props }, ref) => (\n \n));\nDropdownMenuLabel.displayName = DropdownMenuPrimitive.Label.displayName;\n\nexport const DropdownMenuSeparator = React.forwardRef<\n React.ElementRef,\n DropdownMenuSeparatorProps\n>(({ className, ...props }, ref) => (\n \n));\nDropdownMenuSeparator.displayName = DropdownMenuPrimitive.Separator.displayName;\n\nexport function DropdownMenuShortcut({ className, ...props }: DropdownMenuShortcutProps) {\n return (\n \n );\n}\nDropdownMenuShortcut.displayName = 'DropdownMenuShortcut';\n","import { Canon } from '@sillsdev/scripture';\nimport { PropsWithChildren, KeyboardEvent, forwardRef } from 'react';\nimport { DropdownMenuItem as ShadDropdownMenuItem } from '@/components/shadcn-ui/dropdown-menu';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport type BookType = 'OT' | 'NT' | 'DC';\n\ntype BookMenuItemProps = PropsWithChildren<{\n /** String id of book */\n bookId: string;\n /** Callback to run when a book menu item is selected */\n handleSelectBook: () => void;\n /** Indicates if this menu item is currently selected */\n isSelected: boolean;\n /** Function that is called upon highlighting a book in the dropdown menu */\n handleHighlightBook: () => void;\n /**\n * Function that is called on pressing a key\n *\n * @param event Event that contains information about the key stroke\n */\n handleKeyDown: (event: KeyboardEvent) => void;\n /**\n * Type of book associated with this menu item, coordinates color labels ? Mock up has the labels\n * coordinated to genre\n */\n bookType: BookType;\n}>;\n\nconst BookMenuItem = forwardRef(\n (\n {\n bookId,\n handleSelectBook,\n isSelected,\n handleHighlightBook,\n handleKeyDown,\n bookType,\n children,\n }: BookMenuItemProps,\n ref,\n ) => {\n return (\n {\n // preventDefault() here prevents the entire dropdown menu from closing when selecting this item\n event.preventDefault();\n handleSelectBook();\n }}\n onKeyDown={(event: KeyboardEvent) => {\n handleKeyDown(event);\n }}\n onFocus={handleHighlightBook}\n onMouseMove={handleHighlightBook}\n >\n \n {Canon.bookIdToEnglishName(bookId)}\n \n {isSelected &&
    {children}
    }\n \n );\n },\n);\n\nexport default BookMenuItem;\n","import { cn } from '@/utils/shadcn-ui.util';\nimport { useCallback } from 'react';\n\nexport type ChapterSelectProps = {\n /**\n * Callback to run when a chapter div is selected\n *\n * @param chapterNumber Number of the chapter that has been selected\n */\n handleSelectChapter: (chapterNumber: number) => void;\n /** The highest chapter number in the book (of course equal to number of chapters in the book) */\n endChapter: number;\n /** The chapter number that is currently selected */\n activeChapter: number;\n /** The chapter number that is currently highlighted using keyboard or mouse navigation */\n highlightedChapter: number;\n /**\n * Callback to run when a chapter is highlighted by the user\n *\n * @param chapterNumber The chapter that is highlighted\n */\n handleHighlightedChapter: (chapterNumber: number) => void;\n};\n\nfunction ChapterSelect({\n handleSelectChapter,\n endChapter,\n activeChapter,\n highlightedChapter,\n handleHighlightedChapter,\n}: ChapterSelectProps) {\n const chapters = Array.from({ length: endChapter }, (_, i) => i + 1);\n\n const handleMouse = useCallback(\n (chapterNumber: number) => {\n handleHighlightedChapter(chapterNumber);\n },\n [handleHighlightedChapter],\n );\n\n return (\n
    \n {chapters.map((chapter) => (\n {\n event.preventDefault();\n event.stopPropagation();\n handleSelectChapter(chapter);\n }}\n role=\"button\"\n onKeyDown={(event) => {\n if (event.key === 'Enter') {\n handleSelectChapter(chapter);\n }\n }}\n tabIndex={0}\n onMouseMove={() => handleMouse(chapter)}\n >\n {chapter}\n
    \n ))}\n
    \n );\n}\n\nexport default ChapterSelect;\n","import { DropdownMenuLabel as ShadDropdownMenuLabel } from '@/components/shadcn-ui/dropdown-menu';\nimport { Bookmark, Clock, ArrowDownWideNarrow } from 'lucide-react';\n\nexport type GoToMenuItemProps = {\n handleSort: () => void;\n handleLocationHistory: () => void;\n handleBookmarks: () => void;\n};\n\nfunction GoToMenuItem({ handleSort, handleLocationHistory, handleBookmarks }: GoToMenuItemProps) {\n return (\n \n

    Go To

    \n
    \n \n \n \n
    \n
    \n );\n}\n\nexport default GoToMenuItem;\n","import BookChapterInput from '@/components/advanced/book-chapter-control/book-chapter-input.component';\nimport BookMenuItem, {\n BookType,\n} from '@/components/advanced/book-chapter-control/book-menu-item.component';\nimport ChapterSelect from '@/components/advanced/book-chapter-control/chapter-select.component';\nimport GoToMenuItem from '@/components/advanced/book-chapter-control/go-to-menu-item.component';\nimport {\n DropdownMenu as ShadDropdownMenu,\n DropdownMenuContent as ShadDropdownMenuContent,\n DropdownMenuLabel as ShadDropdownMenuLabel,\n DropdownMenuSeparator as ShadDropdownMenuSeparator,\n DropdownMenuTrigger as ShadDropdownMenuTrigger,\n} from '@/components/shadcn-ui/dropdown-menu';\nimport { Canon } from '@sillsdev/scripture';\nimport { ScriptureReference, getChaptersForBook } from 'platform-bible-utils';\nimport {\n KeyboardEvent as ReactKeyboardEvent,\n useCallback,\n useEffect,\n useLayoutEffect,\n useRef,\n useState,\n} from 'react';\n\ntype BookTypeLabels = {\n [bookType in BookType]: string;\n};\ntype BookChapterControlProps = {\n scrRef: ScriptureReference;\n handleSubmit: (scrRef: ScriptureReference) => void;\n};\n\nconst ALL_BOOK_IDS = Canon.allBookIds;\nconst BOOK_TYPE_LABELS: BookTypeLabels = {\n OT: 'Old Testament',\n NT: 'New Testament',\n DC: 'Deuterocanon',\n};\nconst BOOK_TYPE_ARRAY: BookType[] = ['OT', 'NT', 'DC'];\n// This is the height of three menu items to offset scrolling to the selected menu item\n// If you use menuItemRef.clientHeight- includes height of chapter div which is too big\nconst SCROLL_OFFSET = 32 + 32 + 32;\nconst SEARCH_QUERY_FORMATS = [\n /^(\\w+)$/i, // Matches a single word (book name or id)\n /^(\\w+)(?:\\s(\\d+))$/i, // Matches a word followed by a chapter number\n /^(\\w+)(?:\\s(\\d+):(\\d+))$/i, // Matches a word followed by a chapter and verse number\n];\nconst fetchGroupedBooks = (bookType: BookType) => {\n const groupedBooks = {\n OT: ALL_BOOK_IDS.filter((bookId) => Canon.isBookOT(bookId)),\n NT: ALL_BOOK_IDS.filter((bookId) => Canon.isBookNT(bookId)),\n DC: ALL_BOOK_IDS.filter((bookId) => Canon.isBookDC(bookId)),\n };\n return groupedBooks[bookType];\n};\nconst fetchEndChapter = (bookId: string) => {\n // getChaptersForBook returns -1 if not found in scrBookData\n // scrBookData only includes OT and NT, so all DC will return -1\n return getChaptersForBook(Canon.bookIdToNumber(bookId));\n};\n\n/**\n * Gets all of the English names from book ids\n *\n * @returns String[]\n */\nfunction getAllEnglishNames(): string[] {\n const allEnglishNames = ALL_BOOK_IDS.map((bookId) => {\n return Canon.bookIdToEnglishName(bookId);\n });\n return allEnglishNames;\n}\n\n/**\n * Determines if bookName is in allEnglishNames\n *\n * @param bookName Book English name\n * @returns True if bookName is included, false otherwise\n */\nfunction isValidBookEnglishName(bookName: string): boolean {\n return getAllEnglishNames().includes(bookName);\n}\n\n/**\n * Gets a bookId from given English name\n *\n * @param bookName Book English name\n * @returns BookId of provided bookName, undefined otherwise\n */\nfunction getBookIdFromEnglishName(bookName: string): string | undefined {\n // Convert bookName to lowercase and then capitalize the first letter\n const formattedBookName = bookName.toLowerCase().replace(/^\\w/, (c) => c.toUpperCase());\n\n if (isValidBookEnglishName(formattedBookName)) {\n const matchingBookId = ALL_BOOK_IDS.find((bookId) => {\n return Canon.bookIdToEnglishName(bookId) === formattedBookName;\n });\n return matchingBookId;\n }\n\n return undefined;\n}\n\nfunction BookChapterControl({ scrRef, handleSubmit }: BookChapterControlProps) {\n const [searchQuery, setSearchQuery] = useState('');\n const [selectedBookId, setSelectedBookId] = useState(\n Canon.bookNumberToId(scrRef.bookNum),\n );\n const [highlightedChapter, setHighlightedChapter] = useState(scrRef.chapterNum ?? 0);\n const [highlightedBookId, setHighlightedBookId] = useState(\n Canon.bookNumberToId(scrRef.bookNum),\n );\n const [isContentOpen, setIsContentOpen] = useState(false);\n const [isContentOpenDelayed, setIsContentOpenDelayed] = useState(isContentOpen);\n\n // This ref will always be defined\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const inputRef = useRef(undefined!);\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const contentRef = useRef(undefined!);\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const menuItemRef = useRef(undefined!);\n\n const fetchFilteredBooks = useCallback(\n (bookType: BookType) => {\n return fetchGroupedBooks(bookType).filter((bookId: string) => {\n const englishNameLowerCase = Canon.bookIdToEnglishName(bookId).toLowerCase();\n const normalizedQuery = searchQuery.replace(/[^a-zA-Z]/g, '').toLowerCase();\n return (\n englishNameLowerCase.includes(normalizedQuery) || // Match book name\n bookId.toLowerCase().includes(normalizedQuery) // Match book ID\n );\n });\n },\n [searchQuery],\n );\n\n const handleSearchInput = (searchString: string) => {\n setSearchQuery(searchString);\n };\n\n /**\n * Whether to prevent radix's logic from closing the dropdown. This is important because radix\n * tries to close the dropdown when the input first focuses, and we don't want it to do that. But\n * we don't want to prevent the dropdown from closing when we click away from the input, so we\n * don't want to just keep it open if the input is focused\n */\n const shouldPreventAutoClosing = useRef(false);\n\n const controlMenuState = useCallback((open: boolean) => {\n if (shouldPreventAutoClosing.current) {\n shouldPreventAutoClosing.current = false;\n return;\n }\n setIsContentOpen(open);\n }, []);\n\n const updateReference = useCallback(\n (bookId: string, shouldClose: boolean, chapter?: number, verse?: number) => {\n setHighlightedChapter(\n Canon.bookNumberToId(scrRef.bookNum) !== bookId ? 1 : scrRef.chapterNum,\n );\n\n if (shouldClose || fetchEndChapter(bookId) === -1) {\n handleSubmit({\n bookNum: Canon.bookIdToNumber(bookId),\n chapterNum: chapter || 1,\n verseNum: verse || 1,\n });\n\n setIsContentOpen(false);\n setSearchQuery('');\n return;\n }\n\n setSelectedBookId(selectedBookId !== bookId ? bookId : '');\n setIsContentOpen(!shouldClose);\n },\n [handleSubmit, scrRef.bookNum, scrRef.chapterNum, selectedBookId],\n );\n\n const handleSelectChapter = (chapterNumber: number) => {\n if (chapterNumber <= 0 || chapterNumber > fetchEndChapter(selectedBookId)) {\n return;\n }\n updateReference(selectedBookId, true, chapterNumber);\n };\n\n const handleInputSubmit = useCallback(() => {\n SEARCH_QUERY_FORMATS.forEach((format) => {\n const matches = searchQuery.match(format);\n if (matches) {\n // Book should be a bookId or an english name\n const [book, chapter = undefined, verse = undefined] = matches.slice(1);\n const englishName = getBookIdFromEnglishName(book);\n\n if (Canon.isBookIdValid(book) || englishName) {\n updateReference(\n englishName ?? book,\n true,\n chapter ? parseInt(chapter, 10) : 1,\n verse ? parseInt(verse, 10) : 1,\n );\n }\n }\n });\n }, [updateReference, searchQuery]);\n\n const handleKeyDownInput = useCallback(\n (event: ReactKeyboardEvent) => {\n if (!isContentOpen) {\n setIsContentOpen(true);\n } else if (event.key === 'ArrowDown' || event.key === 'ArrowUp') {\n if (\n typeof menuItemRef !== 'undefined' &&\n // Ref uses null\n // eslint-disable-next-line no-null/no-null\n menuItemRef.current !== null\n ) {\n menuItemRef.current.focus();\n } else if (\n typeof contentRef !== 'undefined' &&\n // Ref uses null\n // eslint-disable-next-line no-null/no-null\n contentRef.current !== null\n ) {\n contentRef.current.focus();\n }\n event.preventDefault();\n }\n },\n [isContentOpen],\n );\n\n const handleKeyDownContent = (event: ReactKeyboardEvent) => {\n // When the dropdown menu has focus, key strokes should give focus to the input component,\n // unless they're navigation keys (arrows and enter)\n const { key } = event;\n if (\n key === 'ArrowRight' ||\n key === 'ArrowLeft' ||\n key === 'ArrowDown' ||\n key === 'ArrowUp' ||\n key === 'Enter'\n ) {\n return;\n }\n\n inputRef.current.dispatchEvent(new KeyboardEvent('keydown', { key }));\n inputRef.current.focus();\n };\n\n const handleKeyDownMenuItem = (event: ReactKeyboardEvent) => {\n const { key } = event;\n if (highlightedBookId === selectedBookId) {\n if (key === 'Enter') {\n event.preventDefault();\n updateReference(selectedBookId, true, highlightedChapter);\n return;\n }\n\n let chapterOffSet = 0;\n if (key === 'ArrowRight') {\n if (highlightedChapter < fetchEndChapter(highlightedBookId)) {\n chapterOffSet = 1;\n } else {\n event.preventDefault();\n return;\n }\n } else if (key === 'ArrowLeft') {\n if (highlightedChapter > 1) {\n chapterOffSet = -1;\n } else {\n event.preventDefault();\n return;\n }\n } else if (key === 'ArrowDown') {\n chapterOffSet = 6;\n } else if (key === 'ArrowUp') {\n chapterOffSet = -6;\n }\n if (\n highlightedChapter + chapterOffSet <= 0 ||\n highlightedChapter + chapterOffSet > fetchEndChapter(highlightedBookId)\n ) {\n setHighlightedChapter(0);\n } else if (chapterOffSet !== 0) {\n setHighlightedChapter(highlightedChapter + chapterOffSet);\n event.preventDefault();\n }\n }\n };\n\n useEffect(() => {\n if (selectedBookId === highlightedBookId) {\n if (selectedBookId === Canon.bookNumberToId(scrRef.bookNum)) {\n setHighlightedChapter(scrRef.chapterNum);\n } else {\n setHighlightedChapter(1);\n }\n } else {\n setHighlightedChapter(0);\n }\n }, [highlightedBookId, scrRef.bookNum, scrRef.chapterNum, selectedBookId]);\n\n // The purpose of these useLayoutEffects and timeout is to delay the scroll just\n // enough so that the refs are defined and available when they are used after the timeout\n useLayoutEffect(() => {\n setIsContentOpenDelayed(isContentOpen);\n }, [isContentOpen]);\n\n useLayoutEffect(() => {\n const scrollTimeout = setTimeout(() => {\n if (isContentOpenDelayed && contentRef.current && menuItemRef.current) {\n const menuItemOffsetTop = menuItemRef.current.offsetTop;\n const scrollPosition = menuItemOffsetTop - SCROLL_OFFSET;\n contentRef.current.scrollTo({ top: scrollPosition, behavior: 'instant' });\n }\n }, 10);\n return () => {\n clearTimeout(scrollTimeout);\n };\n }, [isContentOpenDelayed]);\n\n return (\n
    \n \n \n {\n setSelectedBookId(Canon.bookNumberToId(scrRef.bookNum));\n setHighlightedBookId(Canon.bookNumberToId(scrRef.bookNum));\n setHighlightedChapter(scrRef.chapterNum > 0 ? scrRef.chapterNum : 0);\n setIsContentOpen(true);\n inputRef.current.focus();\n }}\n onFocus={() => {\n // Radix thinks we want to close because the input is being focused. Prevent that\n shouldPreventAutoClosing.current = true;\n }}\n handleSubmit={handleInputSubmit}\n placeholder={`${Canon.bookNumberToEnglishName(scrRef.bookNum)} ${scrRef.chapterNum}:${scrRef.verseNum}`}\n />\n \n \n console.log('sorting')}\n handleLocationHistory={() => console.log('location history')}\n handleBookmarks={() => console.log('bookmarks')}\n />\n {BOOK_TYPE_ARRAY.map(\n (bookType, bookTypeIndex) =>\n fetchFilteredBooks(bookType).length > 0 && (\n
    \n \n {BOOK_TYPE_LABELS[bookType]}\n \n\n {fetchFilteredBooks(bookType).map((bookId) => (\n
    \n updateReference(bookId, false)}\n isSelected={selectedBookId === bookId}\n handleHighlightBook={() => setHighlightedBookId(bookId)}\n handleKeyDown={handleKeyDownMenuItem}\n bookType={bookType}\n ref={(element: HTMLDivElement) => {\n if (selectedBookId === bookId) menuItemRef.current = element;\n }}\n >\n {\n setHighlightedChapter(chapterNumber);\n }}\n />\n \n
    \n ))}\n {BOOK_TYPE_ARRAY.length - 1 !== bookTypeIndex ? (\n \n ) : undefined}\n
    \n ),\n )}\n \n
    \n
    \n );\n}\n\nexport default BookChapterControl;\n","import React from 'react';\nimport { Slot } from '@radix-ui/react-slot';\nimport { cva, type VariantProps } from 'class-variance-authority';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport const buttonVariants = cva(\n 'pr-twp tw-inline-flex tw-items-center tw-justify-center tw-whitespace-nowrap tw-rounded-md tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-colors focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50',\n {\n variants: {\n variant: {\n default: 'tw-bg-primary tw-text-primary-foreground hover:tw-bg-primary/90',\n destructive: 'tw-bg-destructive tw-text-destructive-foreground hover:tw-bg-destructive/90',\n outline:\n 'tw-border tw-border-input tw-bg-background hover:tw-bg-accent hover:tw-text-accent-foreground',\n secondary: 'tw-bg-secondary tw-text-secondary-foreground hover:tw-bg-secondary/80',\n ghost: 'hover:tw-bg-accent hover:tw-text-accent-foreground',\n link: 'tw-text-primary tw-underline-offset-4 hover:tw-underline',\n },\n size: {\n default: 'tw-h-10 tw-px-4 tw-py-2',\n sm: 'tw-h-9 tw-rounded-md tw-px-3',\n lg: 'tw-h-11 tw-rounded-md tw-px-8',\n icon: 'tw-h-10 tw-w-10',\n },\n },\n defaultVariants: {\n variant: 'default',\n size: 'default',\n },\n },\n);\n\nexport interface ButtonProps\n extends React.ButtonHTMLAttributes,\n VariantProps {\n asChild?: boolean;\n}\n\nexport const Button = React.forwardRef(\n ({ className, variant, size, asChild = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'button';\n return (\n \n );\n },\n);\nButton.displayName = 'Button';\n","import React from 'react';\nimport * as LabelPrimitive from '@radix-ui/react-label';\nimport { cva, type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst labelVariants = cva(\n 'tw-text-sm tw-font-medium tw-leading-none peer-disabled:tw-cursor-not-allowed peer-disabled:tw-opacity-70',\n);\n\nexport const Label = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef & VariantProps\n>(({ className, ...props }, ref) => (\n \n));\nLabel.displayName = LabelPrimitive.Root.displayName;\n","import React from 'react';\nimport * as RadioGroupPrimitive from '@radix-ui/react-radio-group';\nimport { Circle } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst RadioGroup = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => {\n return (\n \n );\n});\nRadioGroup.displayName = RadioGroupPrimitive.Root.displayName;\n\nconst RadioGroupItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => {\n return (\n \n \n \n \n \n );\n});\nRadioGroupItem.displayName = RadioGroupPrimitive.Item.displayName;\n\nexport { RadioGroup, RadioGroupItem };\n","import React from 'react';\nimport * as PopoverPrimitive from '@radix-ui/react-popover';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Popover = PopoverPrimitive.Root;\n\nconst PopoverTrigger = PopoverPrimitive.Trigger;\n\nconst PopoverContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, align = 'center', sideOffset = 4, ...props }, ref) => (\n \n \n \n));\nPopoverContent.displayName = PopoverPrimitive.Content.displayName;\n\nexport { Popover, PopoverTrigger, PopoverContent };\n","import React from 'react';\nimport * as DialogPrimitive from '@radix-ui/react-dialog';\nimport { X } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Dialog = DialogPrimitive.Root;\n\nconst DialogTrigger = DialogPrimitive.Trigger;\n\nconst DialogPortal = DialogPrimitive.Portal;\n\nconst DialogClose = DialogPrimitive.Close;\n\nconst DialogOverlay = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nDialogOverlay.displayName = DialogPrimitive.Overlay.displayName;\n\nconst DialogContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, ...props }, ref) => (\n \n \n \n {children}\n \n \n Close\n \n \n \n));\nDialogContent.displayName = DialogPrimitive.Content.displayName;\n\nfunction DialogHeader({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nDialogHeader.displayName = 'DialogHeader';\n\nfunction DialogFooter({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nDialogFooter.displayName = 'DialogFooter';\n\nconst DialogTitle = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nDialogTitle.displayName = DialogPrimitive.Title.displayName;\n\nconst DialogDescription = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nDialogDescription.displayName = DialogPrimitive.Description.displayName;\n\nexport {\n Dialog,\n DialogPortal,\n DialogOverlay,\n DialogClose,\n DialogTrigger,\n DialogContent,\n DialogHeader,\n DialogFooter,\n DialogTitle,\n DialogDescription,\n};\n","import React from 'react';\nimport { type DialogProps } from '@radix-ui/react-dialog';\nimport { Command as CommandPrimitive } from 'cmdk';\nimport { Search } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Dialog, DialogContent } from '@/components/shadcn-ui/dialog';\n\nconst Command = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nCommand.displayName = CommandPrimitive.displayName;\n\ninterface CommandDialogProps extends DialogProps {}\n\nfunction CommandDialog({ children, ...props }: CommandDialogProps) {\n return (\n \n \n \n {children}\n \n \n \n );\n}\n\nconst CommandInput = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n
    \n \n \n
    \n));\n\nCommandInput.displayName = CommandPrimitive.Input.displayName;\n\nconst CommandList = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\n\nCommandList.displayName = CommandPrimitive.List.displayName;\n\nconst CommandEmpty = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>((props, ref) => (\n \n));\n\nCommandEmpty.displayName = CommandPrimitive.Empty.displayName;\n\nconst CommandGroup = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\n\nCommandGroup.displayName = CommandPrimitive.Group.displayName;\n\nconst CommandSeparator = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nCommandSeparator.displayName = CommandPrimitive.Separator.displayName;\n\nconst CommandItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\n\nCommandItem.displayName = CommandPrimitive.Item.displayName;\n\nfunction CommandShortcut({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nCommandShortcut.displayName = 'CommandShortcut';\n\nexport {\n Command,\n CommandDialog,\n CommandInput,\n CommandList,\n CommandEmpty,\n CommandGroup,\n CommandItem,\n CommandShortcut,\n CommandSeparator,\n};\n","import { useState } from 'react';\nimport { Check, ChevronsUpDown } from 'lucide-react';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport { Popover, PopoverContent, PopoverTrigger } from '@/components/shadcn-ui/popover';\nimport {\n Command,\n CommandEmpty,\n CommandInput,\n CommandItem,\n CommandList,\n} from '@/components/shadcn-ui/command';\nimport { PopoverProps } from '@radix-ui/react-popover';\n\nexport type ComboBoxLabelOption = { label: string };\nexport type ComboBoxOption = string | number | ComboBoxLabelOption;\n\nexport type ComboBoxProps = {\n /** Optional unique identifier */\n id?: string;\n /** Text label title for combobox */\n /** List of available options for the dropdown menu */\n options?: readonly T[];\n /** Additional css classes to help with unique styling of the combo box button */\n buttonClassName?: string;\n /** Additional css classes to help with unique styling of the combo box popover */\n popoverContentClassName?: string;\n /**\n * The selected value that the combo box currently holds. Must be shallow equal to one of the\n * options entries.\n */\n value?: T;\n /** Triggers when content of textfield is changed */\n onChange?: (newValue: T) => void;\n /** Used to determine the string value for a given option. */\n getOptionLabel?: (option: ComboBoxOption) => string;\n /** Text displayed on button if `value` is undefined */\n buttonPlaceholder?: string;\n /** Placeholder text for text field */\n textPlaceholder?: string;\n /** Text to display when no options match input */\n commandEmptyMessage?: string;\n /** Variant of button */\n buttonVariant?: ButtonProps['variant'];\n /** Text direction ltr or rtl */\n dir?: Direction;\n /** Optional boolean to set if trigger should be disabled */\n isDisabled?: boolean;\n} & PopoverProps;\n\ntype Direction = 'ltr' | 'rtl';\n\nfunction getOptionLabelDefault(option: ComboBoxOption): string {\n if (typeof option === 'string') {\n return option;\n }\n if (typeof option === 'number') {\n return option.toString();\n }\n return option.label;\n}\n\n/**\n * Autocomplete input and command palette with a list of suggestions.\n *\n * Thanks to Shadcn for heavy inspiration and documentation\n * https://ui.shadcn.com/docs/components/combobox\n */\nfunction ComboBox({\n id,\n options = [],\n buttonClassName,\n popoverContentClassName,\n value,\n onChange = () => {},\n getOptionLabel = getOptionLabelDefault,\n buttonPlaceholder = '',\n textPlaceholder = '',\n commandEmptyMessage = 'No option found',\n buttonVariant = 'outline',\n dir = 'ltr',\n isDisabled = false,\n ...props\n}: ComboBoxProps) {\n const [open, setOpen] = useState(false);\n\n return (\n \n \n \n \n {value ? getOptionLabel(value) : buttonPlaceholder}\n \n \n \n \n \n \n \n {commandEmptyMessage}\n \n {options.map((option) => (\n {\n onChange(option);\n setOpen(false);\n }}\n >\n \n {getOptionLabel(option)}\n \n ))}\n \n \n \n \n );\n}\n\nexport default ComboBox;\n","import { useMemo } from 'react';\nimport ComboBox from '@/components/basics/combo-box.component';\nimport { Label } from '@/components/shadcn-ui/label';\n\nexport type ChapterRangeSelectorProps = {\n startChapter: number;\n endChapter: number;\n handleSelectStartChapter: (chapter: number) => void;\n handleSelectEndChapter: (chapter: number) => void;\n isDisabled?: boolean;\n chapterCount: number;\n};\n\nexport default function ChapterRangeSelector({\n startChapter,\n endChapter,\n handleSelectStartChapter,\n handleSelectEndChapter,\n isDisabled = false,\n chapterCount,\n}: ChapterRangeSelectorProps) {\n const chapterOptions = useMemo(\n () => Array.from({ length: chapterCount }, (_, index) => index + 1),\n [chapterCount],\n );\n\n const onChangeStartChapter = (value: number) => {\n handleSelectStartChapter(value);\n if (value > endChapter) {\n handleSelectEndChapter(value);\n }\n };\n\n const onChangeEndChapter = (value: number) => {\n handleSelectEndChapter(value);\n if (value < startChapter) {\n handleSelectStartChapter(value);\n }\n };\n\n return (\n <>\n \n option.toString()}\n value={startChapter}\n />\n\n \n option.toString()}\n value={endChapter}\n />\n \n );\n}\n","import { Button } from '@/components/shadcn-ui/button';\nimport { Label } from '@/components/shadcn-ui/label';\nimport { RadioGroup, RadioGroupItem } from '@/components/shadcn-ui/radio-group';\nimport { Canon } from '@sillsdev/scripture';\nimport { LocalizedStringValue } from 'platform-bible-utils';\nimport { useState } from 'react';\nimport ChapterRangeSelector, {\n ChapterRangeSelectorProps,\n} from '../basics/chapter-range-selector.component';\n\nexport enum BookSelectionMode {\n CURRENT_BOOK = 'current book',\n CHOOSE_BOOKS = 'choose books',\n}\n\n/**\n * Object containing all keys used for localization in this component. If you're using this\n * component in an extension, you can pass it into the useLocalizedStrings hook to easily obtain the\n * localized strings and pass them into the localizedStrings prop of this component\n */\nexport const BOOK_SELECTOR_STRING_KEYS = Object.freeze([\n '%webView_bookSelector_currentBook%',\n '%webView_bookSelector_choose%',\n '%webView_bookSelector_chooseBooks%',\n] as const);\n\nexport type BookSelectorLocalizedStrings = {\n [localizedInventoryKey in (typeof BOOK_SELECTOR_STRING_KEYS)[number]]?: LocalizedStringValue;\n};\n\n/**\n * Gets the localized value for the provided key\n *\n * @param strings Object containing localized string\n * @param key Key for a localized string\n * @returns The localized value for the provided key, if available. Returns the key if no localized\n * value is available\n */\nconst localizeString = (\n strings: BookSelectorLocalizedStrings,\n key: keyof BookSelectorLocalizedStrings,\n) => {\n return strings[key] ?? key;\n};\n\ntype BookSelectorProps = ChapterRangeSelectorProps & {\n handleBookSelectionModeChange: (newMode: BookSelectionMode) => void;\n currentBookName: string;\n onSelectBooks: () => void;\n selectedBookIds: string[];\n localizedStrings: BookSelectorLocalizedStrings;\n};\n\nexport default function BookSelector({\n handleBookSelectionModeChange,\n currentBookName,\n onSelectBooks,\n selectedBookIds,\n chapterCount,\n endChapter,\n handleSelectEndChapter,\n startChapter,\n handleSelectStartChapter,\n localizedStrings,\n}: BookSelectorProps) {\n const currentBookText = localizeString(localizedStrings, '%webView_bookSelector_currentBook%');\n const chooseText = localizeString(localizedStrings, '%webView_bookSelector_choose%');\n const chooseBooksText = localizeString(localizedStrings, '%webView_bookSelector_chooseBooks%');\n\n const [bookSelectionMode, setBookSelectionMode] = useState(\n BookSelectionMode.CURRENT_BOOK,\n );\n\n const onSelectionModeChange = (newMode: BookSelectionMode) => {\n setBookSelectionMode(newMode);\n handleBookSelectionModeChange(newMode);\n };\n\n return (\n onSelectionModeChange(value as BookSelectionMode)}\n >\n
    \n
    \n
    \n \n \n
    \n \n
    \n \n
    \n
    \n
    \n
    \n \n \n
    \n \n onSelectBooks()}\n >\n {chooseText}\n \n
    \n
    \n \n );\n}\n","import { DropdownMenuTrigger } from '@radix-ui/react-dropdown-menu';\nimport { FilterIcon } from 'lucide-react';\nimport { Table } from '@tanstack/react-table';\n\nimport { Button } from '@/components/shadcn-ui/button';\nimport {\n DropdownMenu,\n DropdownMenuCheckboxItem,\n DropdownMenuContent,\n DropdownMenuLabel,\n DropdownMenuSeparator,\n} from '@/components/shadcn-ui/dropdown-menu';\n\ninterface DataTableViewOptionsProps {\n table: Table;\n}\n\nfunction DataTableViewOptions({ table }: DataTableViewOptionsProps) {\n return (\n \n \n \n \n \n Toggle columns\n \n {table\n .getAllColumns()\n .filter((column) => column.getCanHide())\n .map((column) => {\n return (\n column.toggleVisibility(!!value)}\n >\n {column.id}\n \n );\n })}\n \n \n );\n}\n\nexport default DataTableViewOptions;\n","import React from 'react';\nimport * as SelectPrimitive from '@radix-ui/react-select';\nimport { Check, ChevronDown, ChevronUp } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Select = SelectPrimitive.Root;\n\nconst SelectGroup = SelectPrimitive.Group;\n\nconst SelectValue = SelectPrimitive.Value;\n\nconst SelectTrigger = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, ...props }, ref) => (\n span]:tw-line-clamp-1',\n className,\n )}\n {...props}\n >\n {children}\n \n \n \n \n));\nSelectTrigger.displayName = SelectPrimitive.Trigger.displayName;\n\nconst SelectScrollUpButton = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n));\nSelectScrollUpButton.displayName = SelectPrimitive.ScrollUpButton.displayName;\n\nconst SelectScrollDownButton = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n));\nSelectScrollDownButton.displayName = SelectPrimitive.ScrollDownButton.displayName;\n\nconst SelectContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, position = 'popper', ...props }, ref) => (\n \n \n \n \n {children}\n \n \n \n \n));\nSelectContent.displayName = SelectPrimitive.Content.displayName;\n\nconst SelectLabel = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSelectLabel.displayName = SelectPrimitive.Label.displayName;\n\nconst SelectItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, ...props }, ref) => (\n \n \n \n \n \n \n\n {children}\n \n));\nSelectItem.displayName = SelectPrimitive.Item.displayName;\n\nconst SelectSeparator = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSelectSeparator.displayName = SelectPrimitive.Separator.displayName;\n\nexport {\n Select,\n SelectGroup,\n SelectValue,\n SelectTrigger,\n SelectContent,\n SelectLabel,\n SelectItem,\n SelectSeparator,\n SelectScrollUpButton,\n SelectScrollDownButton,\n};\n","import { ChevronLeftIcon, ChevronRightIcon, ArrowLeftIcon, ArrowRightIcon } from 'lucide-react';\nimport { Table } from '@tanstack/react-table';\n\nimport { Button } from '@/components/shadcn-ui/button';\nimport {\n Select,\n SelectContent,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\n\ninterface DataTablePaginationProps {\n table: Table;\n}\n\nfunction DataTablePagination({ table }: DataTablePaginationProps) {\n return (\n
    \n
    \n
    \n {table.getFilteredSelectedRowModel().rows.length} of{' '}\n {table.getFilteredRowModel().rows.length} row(s) selected\n
    \n
    \n

    Rows per page

    \n {\n table.setPageSize(Number(value));\n }}\n >\n \n \n \n \n {[10, 20, 30, 40, 50].map((pageSize) => (\n \n {pageSize}\n \n ))}\n \n \n
    \n
    \n Page {table.getState().pagination.pageIndex + 1} of {table.getPageCount()}\n
    \n
    \n table.setPageIndex(0)}\n disabled={!table.getCanPreviousPage()}\n >\n Go to first page\n \n \n table.previousPage()}\n disabled={!table.getCanPreviousPage()}\n >\n Go to previous page\n \n \n table.nextPage()}\n disabled={!table.getCanNextPage()}\n >\n Go to next page\n \n \n table.setPageIndex(table.getPageCount() - 1)}\n disabled={!table.getCanNextPage()}\n >\n Go to last page\n \n \n
    \n
    \n
    \n );\n}\n\nexport default DataTablePagination;\n","import React from 'react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Table = React.forwardRef<\n HTMLTableElement,\n React.HTMLAttributes & { stickyHeader?: boolean }\n>(({ className, stickyHeader, ...props }, ref) => (\n
    \n \n
    \n));\nTable.displayName = 'Table';\n\nconst TableHeader = React.forwardRef<\n HTMLTableSectionElement,\n React.HTMLAttributes & { stickyHeader?: boolean }\n>(({ className, stickyHeader, ...props }, ref) => (\n \n));\nTableHeader.displayName = 'TableHeader';\n\nconst TableBody = React.forwardRef<\n HTMLTableSectionElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableBody.displayName = 'TableBody';\n\nconst TableFooter = React.forwardRef<\n HTMLTableSectionElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n tr]:last:tw-border-b-0', className)}\n {...props}\n />\n));\nTableFooter.displayName = 'TableFooter';\n\nconst TableRow = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nTableRow.displayName = 'TableRow';\n\nconst TableHead = React.forwardRef<\n HTMLTableCellElement,\n React.ThHTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableHead.displayName = 'TableHead';\n\nconst TableCell = React.forwardRef<\n HTMLTableCellElement,\n React.TdHTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableCell.displayName = 'TableCell';\n\nconst TableCaption = React.forwardRef<\n HTMLTableCaptionElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableCaption.displayName = 'TableCaption';\n\nexport { Table, TableHeader, TableBody, TableFooter, TableHead, TableRow, TableCell, TableCaption };\n","import { useState } from 'react';\n\nimport {\n ColumnFiltersState,\n flexRender,\n getCoreRowModel,\n getFilteredRowModel,\n getPaginationRowModel,\n getSortedRowModel,\n SortingState,\n ColumnDef as TSColumnDef,\n Row as TSRow,\n RowSelectionState as TSRowSelectionState,\n SortDirection as TSSortDirection,\n Table as TSTable,\n useReactTable,\n VisibilityState,\n} from '@tanstack/react-table';\n\nimport DataTableViewOptions from '@/components/advanced/data-table/data-table-column-toggle.component';\nimport DataTablePagination from '@/components/advanced/data-table/data-table-pagination.component';\nimport { Button } from '@/components/shadcn-ui/button';\nimport {\n Table,\n TableBody,\n TableCell,\n TableHead,\n TableHeader,\n TableRow,\n} from '@/components/shadcn-ui/table';\n\nexport type ColumnDef = TSColumnDef;\nexport type RowContents = TSRow;\nexport type TableContents = TSTable;\nexport type SortDirection = TSSortDirection;\nexport type RowSelectionState = TSRowSelectionState;\n\ninterface DataTableProps {\n columns: ColumnDef[];\n data: TData[];\n enablePagination?: boolean;\n showPaginationControls?: boolean;\n showColumnVisibilityControls?: boolean;\n stickyHeader?: boolean;\n onRowClickHandler?: (row: RowContents, table: TableContents) => void;\n}\n\n/**\n * Feature-rich table component that infuses our basic shadcn-based Table component with features\n * from TanStack's React Table library\n */\nfunction DataTable({\n columns,\n data,\n enablePagination = false,\n showPaginationControls = false,\n showColumnVisibilityControls = false,\n stickyHeader = false,\n onRowClickHandler = () => {},\n}: DataTableProps) {\n const [sorting, setSorting] = useState([]);\n const [columnFilters, setColumnFilters] = useState([]);\n const [columnVisibility, setColumnVisibility] = useState({});\n const [rowSelection, setRowSelection] = useState({});\n\n const table = useReactTable({\n data,\n columns,\n getCoreRowModel: getCoreRowModel(),\n ...(enablePagination && { getPaginationRowModel: getPaginationRowModel() }),\n onSortingChange: setSorting,\n getSortedRowModel: getSortedRowModel(),\n onColumnFiltersChange: setColumnFilters,\n getFilteredRowModel: getFilteredRowModel(),\n onColumnVisibilityChange: setColumnVisibility,\n onRowSelectionChange: setRowSelection,\n state: {\n sorting,\n columnFilters,\n columnVisibility,\n rowSelection,\n },\n });\n\n return (\n
    \n {showColumnVisibilityControls && }\n \n \n {table.getHeaderGroups().map((headerGroup) => (\n \n {headerGroup.headers.map((header) => {\n return (\n \n {header.isPlaceholder\n ? undefined\n : flexRender(header.column.columnDef.header, header.getContext())}\n \n );\n })}\n \n ))}\n \n \n {table.getRowModel().rows?.length ? (\n table.getRowModel().rows.map((row) => (\n onRowClickHandler(row, table)}\n key={row.id}\n data-state={row.getIsSelected() && 'selected'}\n >\n {row.getVisibleCells().map((cell) => (\n \n {flexRender(cell.column.columnDef.cell, cell.getContext())}\n \n ))}\n \n ))\n ) : (\n \n \n No results.\n \n \n )}\n \n
    \n {enablePagination && (\n
    \n table.previousPage()}\n disabled={!table.getCanPreviousPage()}\n >\n Previous\n \n table.nextPage()}\n disabled={!table.getCanNextPage()}\n >\n Next\n \n
    \n )}\n {enablePagination && showPaginationControls && }\n
    \n );\n}\n\nexport default DataTable;\n","import {\n Table,\n TableBody,\n TableCell,\n TableHead,\n TableHeader,\n TableRow,\n} from '@/components/shadcn-ui/table';\nimport { Canon } from '@sillsdev/scripture';\nimport { deepEqual, LanguageStrings, ScriptureReference } from 'platform-bible-utils';\nimport { useMemo } from 'react';\nimport { InventoryItemOccurrence } from './inventory-utils';\n\n/** Props for the OccurrencesTable component */\ntype OccurrencesTableProps = {\n /** Data that contains scriptures references and snippets of scripture */\n occurrenceData: InventoryItemOccurrence[];\n /** Callback function that is executed when the scripture reference is changed */\n setScriptureReference: (scriptureReference: ScriptureReference) => void;\n /**\n * Object with all localized strings that the OccurrencesTable needs to work well across multiple\n * languages\n */\n localizedStrings: LanguageStrings;\n};\n\n/**\n * Table that shows occurrences of specified inventory item(s). The first column shows the related\n * scripture reference. The second column shows the snippet of scripture that contains the specified\n * inventory item\n */\nfunction OccurrencesTable({\n occurrenceData,\n setScriptureReference,\n localizedStrings,\n}: OccurrencesTableProps) {\n const referenceHeaderText =\n localizedStrings['%webView_inventory_occurrences_table_header_reference%'];\n const occurrenceHeaderText =\n localizedStrings['%webView_inventory_occurrences_table_header_occurrence%'];\n\n const occurrences: InventoryItemOccurrence[] = useMemo(() => {\n const uniqueOccurrences: InventoryItemOccurrence[] = [];\n\n occurrenceData.forEach((occurrence) => {\n if (!uniqueOccurrences.some((uniqueOccurrence) => deepEqual(uniqueOccurrence, occurrence))) {\n uniqueOccurrences.push(occurrence);\n }\n });\n\n return uniqueOccurrences;\n }, [occurrenceData]);\n\n return (\n \n \n \n {referenceHeaderText}\n {occurrenceHeaderText}\n \n \n \n {occurrences.length > 0 &&\n occurrences.map((occurrence) => (\n {\n setScriptureReference(occurrence.reference);\n }}\n >\n {`${Canon.bookNumberToEnglishName(occurrence.reference.bookNum)} ${occurrence.reference.chapterNum}:${occurrence.reference.verseNum}`}\n {occurrence.text}\n \n ))}\n \n
    \n );\n}\n\nexport default OccurrencesTable;\n","import React from 'react';\nimport * as CheckboxPrimitive from '@radix-ui/react-checkbox';\nimport { Check } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Checkbox = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n \n \n));\nCheckbox.displayName = CheckboxPrimitive.Root.displayName;\n\nexport default Checkbox;\n","import { Canon } from '@sillsdev/scripture';\nimport { ScriptureReference } from 'platform-bible-utils';\n\n/* #region Types */\n\n/**\n * Status of items that appear in inventories. 'approved' and 'unapproved' items are defined in the\n * project's `Settings.xml`. All other items are defined as 'unknown'\n */\nexport type Status = 'approved' | 'unapproved' | 'unknown';\n\n/** Occurrence of item in inventory. Primarily used by table that shows occurrences */\nexport type InventoryItemOccurrence = {\n /** Reference to scripture where the item appears */\n reference: ScriptureReference;\n /** Snippet of scripture that contains the occurrence */\n text: string;\n};\n\n/** Data structure that contains all information on an item that is shown in an inventory */\nexport type InventoryTableData = {\n /**\n * The item (e.g. a character in the characters inventory, a marker in the marker inventory) In\n * most cases the array will only have one element. In case of additional items (e.g. the\n * preceding marker in the markers check), the primary item should be stored in the first index.\n * To show additional items in the inventory, make sure to configure the `additionalItemsLabels`\n * prop for the Inventory component\n */\n items: string[];\n /** The number of times this item occurs in the selected scope */\n count: number;\n /** The status of this item (see documentation for `Status` type for more information) */\n status: Status;\n /** Occurrences of this item in the scripture text for the selected scope */\n occurrences: InventoryItemOccurrence[];\n};\n\n/* #endregion */\n\n/* #region Functions */\n\n/**\n * Splits USFM string into shorter line-like segments\n *\n * @param text A single (likely very large) USFM string\n * @returns An array containing the input text, split into shorter segments\n */\nexport const getLinesFromUSFM = (text: string) => {\n // Splits on (CR)LF, CR, \\v, \\c and \\id\n return text.split(/(?:\\r?\\n|\\r)|(?=(?:\\\\(?:v|c|id)))/g);\n};\n\n/**\n * Extracts chapter or verse number from USFM strings that start with a \\c or \\v marker\n *\n * @param text USFM string that is expected to start with \\c or \\v marker\n * @returns Chapter or verse number if one is found. Else returns 0.\n */\nexport const getNumberFromUSFM = (text: string): number | undefined => {\n // Captures all digits that follow \\v or \\c markers followed by whitespace located at the start of a string\n const regex = /^\\\\[vc]\\s+(\\d+)/;\n const match = text.match(regex);\n\n if (match) {\n return +match[1];\n }\n return undefined;\n};\n\n/**\n * Gets book ID from USFM string that starts with the \\id marker, and returns book number for it\n *\n * @param text USFM string that is expected to start with \\id marker\n * @returns Book number corresponding to the \\id marker in the input text. Returns 0 if no marker is\n * found or the marker is not valid\n */\nexport const getBookNumFromId = (text: string): number => {\n // Captures all digits that follow an \\id marker followed by whitespace located at the start of a string\n const match = text.match(/^\\\\id\\s+([A-Za-z]+)/);\n if (match) {\n return Canon.bookIdToNumber(match[1]);\n }\n return 0;\n};\n\n/**\n * Gets the status for an item, typically used in the Inventory component\n *\n * @param item The item for which the status is being requested\n * @param approvedItems Array of approved items, typically as defined in `Settings.xml`\n * @param unapprovedItems Array of unapproved items, typically as defined in `Settings.xml`\n * @returns The status for the specified item\n */\nexport const getStatusForItem = (\n item: string,\n approvedItems: string[],\n unapprovedItems: string[],\n): Status => {\n if (unapprovedItems.includes(item)) return 'unapproved';\n if (approvedItems.includes(item)) return 'approved';\n return 'unknown';\n};\n\n/* #endregion */\n","import React from 'react';\nimport * as TogglePrimitive from '@radix-ui/react-toggle';\nimport { cva, type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst toggleVariants = cva(\n 'pr-twp tw-inline-flex tw-items-center tw-justify-center tw-rounded-md tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-colors hover:tw-bg-muted hover:tw-text-muted-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50 data-[state=on]:tw-bg-accent data-[state=on]:tw-text-accent-foreground',\n {\n variants: {\n variant: {\n default: 'tw-bg-transparent',\n outline:\n 'tw-border tw-border-input tw-bg-transparent hover:tw-bg-accent hover:tw-text-accent-foreground',\n },\n size: {\n default: 'tw-h-10 tw-px-3',\n sm: 'tw-h-9 tw-px-2.5',\n lg: 'tw-h-11 tw-px-5',\n },\n },\n defaultVariants: {\n variant: 'default',\n size: 'default',\n },\n },\n);\n\nconst Toggle = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef & VariantProps\n>(({ className, variant, size, ...props }, ref) => (\n \n));\n\nToggle.displayName = TogglePrimitive.Root.displayName;\n\nexport { Toggle, toggleVariants };\n","import React from 'react';\nimport * as ToggleGroupPrimitive from '@radix-ui/react-toggle-group';\nimport { type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { toggleVariants } from '@/components/shadcn-ui/toggle';\n\nconst ToggleGroupContext = React.createContext>({\n size: 'default',\n variant: 'default',\n});\n\nconst ToggleGroup = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef &\n VariantProps\n>(({ className, variant, size, children, ...props }, ref) => (\n \n \n {children}\n \n \n));\n\nToggleGroup.displayName = ToggleGroupPrimitive.Root.displayName;\n\nconst ToggleGroupItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef &\n VariantProps\n>(({ className, children, variant, size, ...props }, ref) => {\n const context = React.useContext(ToggleGroupContext);\n\n return (\n \n {children}\n \n );\n});\n\nToggleGroupItem.displayName = ToggleGroupPrimitive.Item.displayName;\n\nexport { ToggleGroup, ToggleGroupItem };\n","import { ColumnDef, SortDirection } from '@/components/advanced/data-table/data-table.component';\nimport { Button } from '@/components/shadcn-ui/button';\nimport { ToggleGroup, ToggleGroupItem } from '@/components/shadcn-ui/toggle-group';\nimport {\n ArrowDownIcon,\n ArrowUpDownIcon,\n ArrowUpIcon,\n CircleCheckIcon,\n CircleHelpIcon,\n CircleXIcon,\n} from 'lucide-react';\nimport { ReactNode } from 'react';\nimport { InventoryTableData, Status } from './inventory-utils';\n\n/**\n * Gets an icon that indicates the current sorting direction based on the provided input\n *\n * @param sortDirection Sorting direction. Can be ascending ('asc'), descending ('desc') or false (\n * i.e. not sorted)\n * @returns The appropriate sorting icon for the provided sorting direction\n */\nconst getSortingIcon = (sortDirection: false | SortDirection): ReactNode => {\n if (sortDirection === 'asc') {\n return ;\n }\n if (sortDirection === 'desc') {\n return ;\n }\n return ;\n};\n\n/**\n * Function that creates the item column for inventories\n *\n * @param itemLabel Localized label for the item column (e.g. 'Character', 'Repeated Word', etc.)\n * @returns Column that shows the inventory items. Should be used with the DataTable component\n */\nexport const inventoryItemColumn = (itemLabel: string): ColumnDef => {\n return {\n accessorKey: 'item',\n accessorFn: (row: InventoryTableData) => row.items[0],\n header: ({ column }) => (\n \n ),\n };\n};\n\n/**\n * Function that creates the additional item columns for inventories\n *\n * @param additionalItemLabel Localized label for the additional item column (e.g. 'Preceding\n * Marker')\n * @param additionalItemIndex Index that locates the desired item in the items array of the\n * inventory\n * @returns Column that shows additional inventory items. Should be used with the DataTable\n * component\n */\nexport const inventoryAdditionalItemColumn = (\n additionalItemLabel: string,\n additionalItemIndex: number,\n): ColumnDef => {\n return {\n accessorKey: `item${additionalItemIndex}`,\n accessorFn: (row: InventoryTableData) => row.items[additionalItemIndex],\n header: ({ column }) => (\n \n ),\n };\n};\n\n/**\n * Function that creates the count column for inventories. Should be used with the DataTable\n * component.\n *\n * @param itemLabel Localized label for the count column\n * @returns Column that shows the number of occurrences of the related inventory items\n */\nexport const inventoryCountColumn = (countLabel: string): ColumnDef => {\n return {\n accessorKey: 'count',\n header: ({ column }) => (\n
    \n \n
    \n ),\n cell: ({ row }) =>
    {row.getValue('count')}
    ,\n };\n};\n\n/**\n * Function that updates project settings when status for item(s) changes\n *\n * @param changedItems Array of items for which the status is being updated\n * @param newStatus The status that the items are being given\n * @param approvedItems Array of currently approved items\n * @param onApprovedItemsChange Callback function that stores the updated list of approved items\n * @param unapprovedItems Array of currently unapproved items\n * @param onUnapprovedItemsChange Callback function that stores the updated list of unapproved items\n */\nconst statusChangeHandler = (\n changedItems: string[],\n newStatus: Status,\n approvedItems: string[],\n onApprovedItemsChange: (items: string[]) => void,\n unapprovedItems: string[],\n onUnapprovedItemsChange: (items: string[]) => void,\n) => {\n let newApprovedItems: string[] = [...approvedItems];\n changedItems.forEach((item) => {\n if (newStatus === 'approved') {\n if (!newApprovedItems.includes(item)) {\n newApprovedItems.push(item);\n }\n } else {\n newApprovedItems = newApprovedItems.filter((validItem) => validItem !== item);\n }\n });\n onApprovedItemsChange(newApprovedItems);\n\n let newUnapprovedItems: string[] = [...unapprovedItems];\n changedItems.forEach((item) => {\n if (newStatus === 'unapproved') {\n if (!newUnapprovedItems.includes(item)) {\n newUnapprovedItems.push(item);\n }\n } else {\n newUnapprovedItems = newUnapprovedItems.filter((unapprovedItem) => unapprovedItem !== item);\n }\n });\n onUnapprovedItemsChange(newUnapprovedItems);\n};\n\n/**\n * Function that creates the status column for inventories. Should be used with the DataTable\n * component.\n *\n * @param statusLabel Localized label for the status column\n * @param approvedItems Array of approved items, typically as defined in `Settings.xml`\n * @param onApprovedItemsChange Callback function that stores the updated list of approved items\n * @param unapprovedItems Array of unapproved items, typically as defined in `Settings.xml`\n * @param onUnapprovedItemsChange Callback function that stores the updated list of unapproved items\n * @returns Column that shows the status buttons for the related inventory item. The button for the\n * current status of the item is selected\n */\nexport const inventoryStatusColumn = (\n statusLabel: string,\n approvedItems: string[],\n onApprovedItemsChange: (items: string[]) => void,\n unapprovedItems: string[],\n onUnapprovedItemsChange: (items: string[]) => void,\n): ColumnDef => {\n return {\n accessorKey: 'status',\n header: ({ column }) => {\n return (\n
    \n \n
    \n );\n },\n cell: ({ row }) => {\n const status: Status = row.getValue('status');\n const item: string = row.getValue('item');\n return (\n \n \n statusChangeHandler(\n [item],\n 'approved',\n approvedItems,\n onApprovedItemsChange,\n unapprovedItems,\n onUnapprovedItemsChange,\n )\n }\n value=\"approved\"\n >\n \n \n \n statusChangeHandler(\n [item],\n 'unapproved',\n approvedItems,\n onApprovedItemsChange,\n unapprovedItems,\n onUnapprovedItemsChange,\n )\n }\n value=\"unapproved\"\n >\n \n \n \n statusChangeHandler(\n [item],\n 'unknown',\n approvedItems,\n onApprovedItemsChange,\n unapprovedItems,\n onUnapprovedItemsChange,\n )\n }\n value=\"unknown\"\n >\n \n \n \n );\n },\n };\n};\n","import DataTable, {\n ColumnDef,\n RowContents,\n RowSelectionState,\n TableContents,\n} from '@/components/advanced/data-table/data-table.component';\nimport OccurrencesTable from '@/components/advanced/inventory/occurrences-table.component';\nimport Checkbox from '@/components/shadcn-ui/checkbox';\nimport { Input } from '@/components/shadcn-ui/input';\nimport { Label } from '@/components/shadcn-ui/label';\nimport {\n Select,\n SelectContent,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\nimport {\n deepEqual,\n LocalizedStringValue,\n ScriptureReference,\n substring,\n} from 'platform-bible-utils';\nimport { useEffect, useMemo, useState } from 'react';\nimport {\n getBookNumFromId,\n getLinesFromUSFM,\n getNumberFromUSFM,\n getStatusForItem,\n InventoryItemOccurrence,\n InventoryTableData,\n Status,\n} from './inventory-utils';\nimport { inventoryAdditionalItemColumn } from './inventory-columns';\n\n/**\n * Object containing all keys used for localization in this component. If you're using this\n * component in an extension, you can pass it into the useLocalizedStrings hook to easily obtain the\n * localized strings and pass them into the localizedStrings prop of this component\n */\nexport const INVENTORY_STRING_KEYS = Object.freeze([\n '%webView_inventory_all%',\n '%webView_inventory_approved%',\n '%webView_inventory_unapproved%',\n '%webView_inventory_unknown%',\n '%webView_inventory_scope_currentBook%',\n '%webView_inventory_scope_chapter%',\n '%webView_inventory_scope_verse%',\n '%webView_inventory_filter_text%',\n '%webView_inventory_show_additional_items%',\n '%webView_inventory_occurrences_table_header_reference%',\n '%webView_inventory_occurrences_table_header_occurrence%',\n] as const);\n\nexport type InventoryLocalizedStrings = {\n [localizedInventoryKey in (typeof INVENTORY_STRING_KEYS)[number]]?: LocalizedStringValue;\n};\n\n/** Scope of scripture that the inventory can operate on */\nexport type Scope = 'book' | 'chapter' | 'verse';\n\n/** Status values that the status filter can select from */\ntype StatusFilter = Status | 'all';\n\n/** Text labels for the inventory columns and the control components of additional inventory items */\ntype AdditionalItemsLabels = {\n checkboxText?: string;\n tableHeaders?: string[];\n};\n\n/**\n * Filters data that is shown in the DataTable section of the Inventory\n *\n * @param itemData All inventory items and their related information\n * @param statusFilter Allows filtering by status (i.e. show all items, or only items that are\n * 'approved', 'unapproved' or 'unknown')\n * @param textFilter Allows filtering by text. All items that include the filter text will be\n * selected.\n * @returns Array of items and their related information that are matched by the specified filters\n */\nconst filterItemData = (\n itemData: InventoryTableData[],\n statusFilter: StatusFilter,\n textFilter: string,\n): InventoryTableData[] => {\n let filteredItemData: InventoryTableData[] = itemData;\n\n if (statusFilter !== 'all') {\n filteredItemData = filteredItemData.filter(\n (item) =>\n (statusFilter === 'approved' && item.status === 'approved') ||\n (statusFilter === 'unapproved' && item.status === 'unapproved') ||\n (statusFilter === 'unknown' && item.status === 'unknown'),\n );\n }\n\n if (textFilter !== '')\n filteredItemData = filteredItemData.filter((item) => item.items[0].includes(textFilter));\n\n return filteredItemData;\n};\n\n/**\n * Turns array of strings into array of inventory items, along with their count and status\n *\n * @param text The source scripture text that is searched for inventory items\n * @param scriptureRef The scripture reference that the application is currently set to\n * @param approvedItems Array of approved items, typically as defined in `Settings.xml`\n * @param unapprovedItems Array of unapproved items, typically as defined in `Settings.xml`\n * @param itemRegex Regular expression that describes what items this Inventory should extract from\n * the provided scripture text\n * @returns Array of inventory items, along with their count and status\n */\nconst createTableData = (\n text: string | undefined,\n scriptureRef: ScriptureReference,\n approvedItems: string[],\n unapprovedItems: string[],\n itemRegex: RegExp,\n): InventoryTableData[] => {\n if (!text) return [];\n\n const tableData: InventoryTableData[] = [];\n\n let currentBook: number | undefined = scriptureRef.bookNum;\n let currentChapter: number | undefined = scriptureRef.chapterNum;\n let currentVerse: number | undefined = scriptureRef.verseNum;\n\n const lines = getLinesFromUSFM(text);\n\n lines.forEach((line: string) => {\n if (line.startsWith('\\\\id')) {\n currentBook = getBookNumFromId(line);\n currentChapter = 0;\n currentVerse = 0;\n }\n if (line.startsWith('\\\\c')) {\n currentChapter = getNumberFromUSFM(line);\n currentVerse = 0;\n }\n if (line.startsWith('\\\\v')) {\n currentVerse = getNumberFromUSFM(line);\n if (currentChapter === 0) {\n currentChapter = scriptureRef.chapterNum;\n }\n }\n\n let match: RegExpExecArray | undefined = itemRegex.exec(line) ?? undefined;\n while (match) {\n const items: string[] = [];\n match.forEach((item) => items.push(item));\n const itemIndex = match.index;\n const existingItem = tableData.find((tableEntry) => deepEqual(tableEntry.items, items));\n const newReference: InventoryItemOccurrence = {\n reference: {\n bookNum: currentBook !== undefined ? currentBook : -1,\n chapterNum: currentChapter !== undefined ? currentChapter : -1,\n verseNum: currentVerse !== undefined ? currentVerse : -1,\n },\n text: substring(line, Math.max(0, itemIndex - 25), Math.min(itemIndex + 25, line.length)),\n };\n if (existingItem) {\n existingItem.count += 1;\n existingItem.occurrences.push(newReference);\n } else {\n const newItem: InventoryTableData = {\n items,\n count: 1,\n status: getStatusForItem(items[0], approvedItems, unapprovedItems),\n occurrences: [newReference],\n };\n tableData.push(newItem);\n }\n\n match = itemRegex.exec(line) ?? undefined;\n }\n });\n\n return tableData;\n};\n\n/**\n * Gets the localized value for the provided key\n *\n * @param strings Object containing localized string\n * @param key Key for a localized string\n * @returns The localized value for the provided key, if available. Returns the key if no localized\n * value is available\n */\nconst localizeString = (\n strings: InventoryLocalizedStrings,\n key: keyof InventoryLocalizedStrings,\n) => {\n return strings[key] ?? key;\n};\n\n/** Props for the Inventory component */\ntype InventoryProps = {\n /** The scripture reference that the application is currently set to */\n scriptureReference: ScriptureReference;\n /** Callback function that is executed when the scripture reference is changed */\n setScriptureReference: (scriptureReference: ScriptureReference) => void;\n /**\n * Object with all localized strings that the Inventory needs to work well across multiple\n * languages. When using this component with Platform.Bible, you can import\n * `INVENTORY_STRING_KEYS` from this library, pass it in to the Platform's localization hook, and\n * pass the localized keys that are returned by the hook into this prop.\n */\n localizedStrings: InventoryLocalizedStrings;\n /**\n * The logic that finds the desired items in the source text. This can either be a Regular\n * expression that captures one or multiple items (preferred), or a custom function that builds\n * and return an InventoryDataTable[] manually. Note: In case the logic captures more than one\n * item (i.e. InventoryTableData.items has a length greater than 1), you must provide text labels\n * for the related columns and control elements to show by setting the `additionalItemsLabels`\n * prop\n */\n extractItems:\n | RegExp\n | ((\n text: string | undefined,\n scriptureRef: ScriptureReference,\n approvedItems: string[],\n unapprovedItems: string[],\n ) => InventoryTableData[]);\n /**\n * Text labels for control elements and additional column headers in case your Inventory has more\n * than one item to show (e.g. The 'Preceding Marker' in the Markers Inventory)\n */\n additionalItemsLabels?: AdditionalItemsLabels;\n /** Array of approved items, typically as defined in `Settings.xml` */\n approvedItems: string[];\n /** Array of unapproved items, typically as defined in `Settings.xml` */\n unapprovedItems: string[];\n /** The source scripture text that is searched for in inventory items */\n text: string | undefined;\n /** Scope of scripture that the inventory will operate on */\n scope: Scope;\n /** Callback function that is executed when the scope is changed from the Inventory */\n onScopeChange: (scope: Scope) => void;\n /**\n * Column definitions for the Inventory data table. The most commonly used column definitions are\n * pre-configured for your convenience and can be imported (e.g. inventoryItemColumn,\n * inventoryAdditionalItemColumn inventoryCountColumn, and inventoryStatusColumn). If you need any\n * other columns you can add these yourself\n */\n columns: ColumnDef[];\n};\n\n/** Inventory component that is used to view and control the status of provided project settings */\nexport default function Inventory({\n scriptureReference,\n setScriptureReference,\n localizedStrings,\n extractItems,\n additionalItemsLabels,\n approvedItems,\n unapprovedItems,\n text,\n scope,\n onScopeChange,\n columns,\n}: InventoryProps) {\n const allItemsText = localizeString(localizedStrings, '%webView_inventory_all%');\n const approvedItemsText = localizeString(localizedStrings, '%webView_inventory_approved%');\n const unapprovedItemsText = localizeString(localizedStrings, '%webView_inventory_unapproved%');\n const unknownItemsText = localizeString(localizedStrings, '%webView_inventory_unknown%');\n const scopeBookText = localizeString(localizedStrings, '%webView_inventory_scope_currentBook%');\n const scopeChapterText = localizeString(localizedStrings, '%webView_inventory_scope_chapter%');\n const scopeVerseText = localizeString(localizedStrings, '%webView_inventory_scope_verse%');\n const filterText = localizeString(localizedStrings, '%webView_inventory_filter_text%');\n const showAdditionalItemsText = localizeString(\n localizedStrings,\n '%webView_inventory_show_additional_items%',\n );\n\n const [showAdditionalItems, setShowAdditionalItems] = useState(false);\n const [statusFilter, setStatusFilter] = useState('all');\n const [textFilter, setTextFilter] = useState('');\n const [selectedItem, setSelectedItem] = useState([]);\n\n const tableData: InventoryTableData[] = useMemo(() => {\n if (!text) return [];\n if (extractItems instanceof RegExp)\n return createTableData(\n text,\n scriptureReference,\n approvedItems,\n unapprovedItems,\n extractItems,\n );\n return extractItems(text, scriptureReference, approvedItems, unapprovedItems);\n }, [text, extractItems, scriptureReference, approvedItems, unapprovedItems]);\n\n const reducedTableData: InventoryTableData[] = useMemo(() => {\n if (showAdditionalItems) return tableData;\n\n const newTableData: InventoryTableData[] = [];\n\n tableData.forEach((tableEntry) => {\n const firstItem = tableEntry.items[0];\n\n const existingEntry = newTableData.find(\n (newTableEntry) => newTableEntry.items[0] === firstItem,\n );\n\n if (existingEntry) {\n existingEntry.count += tableEntry.count;\n existingEntry.occurrences = existingEntry.occurrences.concat(tableEntry.occurrences);\n } else {\n newTableData.push({\n items: [firstItem],\n count: tableEntry.count,\n occurrences: tableEntry.occurrences,\n status: tableEntry.status,\n });\n }\n });\n\n return newTableData;\n }, [showAdditionalItems, tableData]);\n\n const filteredTableData: InventoryTableData[] = useMemo(() => {\n return filterItemData(reducedTableData, statusFilter, textFilter);\n }, [reducedTableData, statusFilter, textFilter]);\n\n const allColumns: ColumnDef[] = useMemo(() => {\n if (!showAdditionalItems) return columns;\n\n const numberOfAdditionalItems = additionalItemsLabels?.tableHeaders?.length;\n if (!numberOfAdditionalItems) return columns;\n\n const additionalColumns: ColumnDef[] = [];\n\n for (let index = 0; index < numberOfAdditionalItems; index++) {\n additionalColumns.push(\n inventoryAdditionalItemColumn(\n additionalItemsLabels?.tableHeaders?.[index] || 'Additional Item',\n index + 1,\n ),\n );\n }\n\n return [...additionalColumns, ...columns];\n }, [additionalItemsLabels?.tableHeaders, columns, showAdditionalItems]);\n\n useEffect(() => {\n setSelectedItem([]);\n }, [filteredTableData]);\n\n const rowClickHandler = (\n row: RowContents,\n table: TableContents,\n ) => {\n table.setRowSelection(() => {\n const newSelection: RowSelectionState = {};\n newSelection[row.index] = true;\n return newSelection;\n });\n\n setSelectedItem(row.original.items);\n };\n\n const handleScopeChange = (value: string) => {\n if (value === 'book' || value === 'chapter' || value === 'verse') {\n onScopeChange(value);\n } else {\n throw new Error(`Invalid scope value: ${value}`);\n }\n };\n\n const handleStatusFilterChange = (value: string) => {\n if (value === 'all' || value === 'approved' || value === 'unapproved' || value === 'unknown') {\n setStatusFilter(value);\n } else {\n throw new Error(`Invalid status filter value: ${value}`);\n }\n };\n\n const occurrenceData: InventoryItemOccurrence[] = useMemo(() => {\n if (reducedTableData.length === 0 || selectedItem.length === 0) return [];\n const occurrence = reducedTableData.filter((tableEntry: InventoryTableData) => {\n return deepEqual(\n showAdditionalItems ? tableEntry.items : [tableEntry.items[0]],\n selectedItem,\n );\n });\n if (occurrence.length > 1) throw new Error('Selected item is not unique');\n return occurrence[0].occurrences;\n }, [selectedItem, showAdditionalItems, reducedTableData]);\n\n return (\n
    \n
    \n handleStatusFilterChange(value)}\n defaultValue={statusFilter}\n >\n \n \n \n \n {allItemsText}\n {approvedItemsText}\n {unapprovedItemsText}\n {unknownItemsText}\n \n \n \n {\n setTextFilter(event.target.value);\n }}\n />\n {additionalItemsLabels && (\n
    \n {\n setSelectedItem([]);\n setShowAdditionalItems(checked);\n }}\n />\n \n
    \n )}\n
    \n
    \n \n
    \n {occurrenceData.length > 0 && (\n
    \n \n
    \n )}\n
    \n );\n}\n","import { Input } from '@/components/shadcn-ui/input';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { useState } from 'react';\n\nexport type SearchBarProps = {\n className?: string;\n /**\n * Callback fired to handle the search query when button pressed\n *\n * @param searchQuery\n */\n onSearch: (searchQuery: string) => void;\n\n /** Optional string that appears in the search bar without a search string */\n placeholder?: string;\n\n /** Optional boolean to set the input base to full width */\n isFullWidth?: boolean;\n};\n\nexport default function SearchBar({\n className,\n onSearch,\n placeholder,\n isFullWidth,\n}: SearchBarProps) {\n const [searchQuery, setSearchQuery] = useState('');\n\n const handleInputChange = (searchString: string) => {\n setSearchQuery(searchString);\n onSearch(searchString);\n };\n\n return (\n handleInputChange(e.target.value)}\n />\n );\n}\n","// adapted from: https://github.com/shadcn-ui/ui/discussions/752\n\n'use client';\n\nimport { TabsContentProps, TabsListProps, TabsTriggerProps } from '@/components/shadcn-ui/tabs';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport * as TabsPrimitive from '@radix-ui/react-tabs';\nimport React from 'react';\n\nexport type VerticalTabsProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport type LeftTabsTriggerProps = TabsTriggerProps & {\n value: string;\n ref?: React.Ref;\n};\n\nexport const VerticalTabs = React.forwardRef<\n React.ElementRef,\n VerticalTabsProps\n>(({ className, ...props }, ref) => (\n \n));\n\nVerticalTabs.displayName = TabsPrimitive.List.displayName;\n\nexport const VerticalTabsList = React.forwardRef<\n React.ElementRef,\n TabsListProps\n>(({ className, ...props }, ref) => (\n \n));\nVerticalTabsList.displayName = TabsPrimitive.List.displayName;\n\nexport const VerticalTabsTrigger = React.forwardRef<\n React.ElementRef,\n LeftTabsTriggerProps\n>(({ className, ...props }, ref) => (\n \n));\n\nexport const VerticalTabsContent = React.forwardRef<\n React.ElementRef,\n TabsContentProps\n>(({ className, ...props }, ref) => (\n \n));\nVerticalTabsContent.displayName = TabsPrimitive.Content.displayName;\n","import SearchBar from '@/components/basics/search-bar.component';\nimport {\n VerticalTabs,\n VerticalTabsContent,\n VerticalTabsList,\n VerticalTabsTrigger,\n} from '@/components/basics/tabs-vertical';\nimport { ReactNode } from 'react';\n\nexport type TabKeyValueContent = {\n key: string;\n value: string;\n content: ReactNode;\n};\n\nexport type TabNavigationContentSearchProps = {\n /** List of values and keys for each tab this component should provide */\n tabList: TabKeyValueContent[];\n\n /** Handler to run when the value of the search bar changes */\n onSearch: (searchQuery: string) => void;\n\n /** Optional placeholder for the search bar */\n searchPlaceholder?: string;\n\n /** Optional title to include in the header */\n headerTitle?: string;\n\n /** Optional flag to make the search bar appear full width */\n isSearchBarFullWidth?: boolean;\n\n /** Text direction ltr or rtl */\n direction?: 'ltr' | 'rtl';\n};\n\nexport default function TabNavigationContentSearch({\n tabList,\n onSearch,\n searchPlaceholder,\n headerTitle,\n isSearchBarFullWidth = false,\n direction = 'ltr',\n}: TabNavigationContentSearchProps) {\n return (\n
    \n
    \n {headerTitle ?

    {headerTitle}

    : ''}\n \n
    \n \n \n {tabList.map((tab) => (\n \n {tab.value}\n \n ))}\n \n {tabList.map((tab) => (\n \n {tab.content}\n \n ))}\n \n
    \n );\n}\n","import React from 'react';\nimport * as SeparatorPrimitive from '@radix-ui/react-separator';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Separator = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, orientation = 'horizontal', decorative = true, ...props }, ref) => (\n \n));\nSeparator.displayName = SeparatorPrimitive.Root.displayName;\n\nexport { Separator };\n","'use client';\n\nimport * as React from 'react';\nimport * as SheetPrimitive from '@radix-ui/react-dialog';\nimport { cva, type VariantProps } from 'class-variance-authority';\nimport { X } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Sheet = SheetPrimitive.Root;\n\nconst SheetTrigger = SheetPrimitive.Trigger;\n\nconst SheetClose = SheetPrimitive.Close;\n\nconst SheetPortal = SheetPrimitive.Portal;\n\nconst SheetOverlay = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSheetOverlay.displayName = SheetPrimitive.Overlay.displayName;\n\nconst sheetVariants = cva(\n 'pr-twp tw-fixed tw-z-50 tw-gap-4 tw-bg-background tw-p-6 tw-shadow-lg tw-transition tw-ease-in-out data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-duration-300 data-[state=open]:tw-duration-500',\n {\n variants: {\n side: {\n top: 'tw-inset-x-0 tw-top-0 tw-border-b data-[state=closed]:tw-slide-out-to-top data-[state=open]:tw-slide-in-from-top',\n bottom:\n 'tw-inset-x-0 tw-bottom-0 tw-border-t data-[state=closed]:tw-slide-out-to-bottom data-[state=open]:tw-slide-in-from-bottom',\n left: 'tw-inset-y-0 tw-left-0 tw-h-full tw-w-3/4 tw-border-r data-[state=closed]:tw-slide-out-to-left data-[state=open]:tw-slide-in-from-left sm:tw-max-w-sm',\n right:\n 'tw-inset-y-0 tw-right-0 tw-h-full tw-w-3/4 tw- tw-border-l data-[state=closed]:tw-slide-out-to-right data-[state=open]:tw-slide-in-from-right sm:tw-max-w-sm',\n },\n },\n defaultVariants: {\n side: 'right',\n },\n },\n);\n\ninterface SheetContentProps\n extends React.ComponentPropsWithoutRef,\n VariantProps {}\n\nconst SheetContent = React.forwardRef<\n React.ElementRef,\n SheetContentProps\n>(({ side = 'right', className, children, ...props }, ref) => (\n \n \n \n {children}\n \n \n Close\n \n \n \n));\nSheetContent.displayName = SheetPrimitive.Content.displayName;\n\nfunction SheetHeader({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nSheetHeader.displayName = 'SheetHeader';\n\nfunction SheetFooter({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nSheetFooter.displayName = 'SheetFooter';\n\nconst SheetTitle = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSheetTitle.displayName = SheetPrimitive.Title.displayName;\n\nconst SheetDescription = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSheetDescription.displayName = SheetPrimitive.Description.displayName;\n\nexport {\n Sheet,\n SheetPortal,\n SheetOverlay,\n SheetTrigger,\n SheetClose,\n SheetContent,\n SheetHeader,\n SheetFooter,\n SheetTitle,\n SheetDescription,\n};\n","import React from 'react';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nfunction Skeleton({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\n\nexport { Skeleton };\n","import React from 'react';\nimport * as TooltipPrimitive from '@radix-ui/react-tooltip';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst TooltipProvider = TooltipPrimitive.Provider;\n\nconst Tooltip = TooltipPrimitive.Root;\n\nconst TooltipTrigger = TooltipPrimitive.Trigger;\n\nconst TooltipContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, sideOffset = 4, ...props }, ref) => (\n \n));\nTooltipContent.displayName = TooltipPrimitive.Content.displayName;\n\nexport { Tooltip, TooltipTrigger, TooltipContent, TooltipProvider };\n","import * as React from 'react';\n\nconst MOBILE_BREAKPOINT = 768;\n\nexport default function useIsMobile() {\n const [isMobile, setIsMobile] = React.useState(undefined);\n\n React.useEffect(() => {\n const mql = window.matchMedia(`(max-width: ${MOBILE_BREAKPOINT - 1}px)`);\n const onChange = () => {\n setIsMobile(window.innerWidth < MOBILE_BREAKPOINT);\n };\n mql.addEventListener('change', onChange);\n setIsMobile(window.innerWidth < MOBILE_BREAKPOINT);\n return () => mql.removeEventListener('change', onChange);\n }, []);\n\n return !!isMobile;\n}\n","import React from 'react';\nimport { Slot } from '@radix-ui/react-slot';\nimport { VariantProps, cva } from 'class-variance-authority';\nimport { PanelLeft } from 'lucide-react';\n\nimport { Button } from '@/components/shadcn-ui/button';\nimport { Input } from '@/components/shadcn-ui/input';\nimport { Separator } from '@/components/shadcn-ui/separator';\nimport { Sheet, SheetContent } from '@/components/shadcn-ui/sheet';\nimport { Skeleton } from '@/components/shadcn-ui/skeleton';\nimport {\n Tooltip,\n TooltipContent,\n TooltipProvider,\n TooltipTrigger,\n} from '@/components/shadcn-ui/tooltip';\nimport useIsMobile from '@/components/hooks/use-mobile';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst SIDEBAR_COOKIE_NAME = 'sidebar:state';\nconst SIDEBAR_COOKIE_MAX_AGE = 60 * 60 * 24 * 7;\nconst SIDEBAR_WIDTH = '16rem';\nconst SIDEBAR_WIDTH_MOBILE = '18rem';\nconst SIDEBAR_WIDTH_ICON = '3rem';\nconst SIDEBAR_KEYBOARD_SHORTCUT = 'b';\n\ntype SidebarContextProps = {\n state: 'expanded' | 'collapsed';\n open: boolean;\n setOpen: (open: boolean) => void;\n openMobile: boolean;\n setOpenMobile: (open: boolean) => void;\n isMobile: boolean;\n toggleSidebar: () => void;\n};\n\nconst SidebarContext = React.createContext(undefined);\n\nfunction useSidebar() {\n const context = React.useContext(SidebarContext);\n if (!context) {\n throw new Error('useSidebar must be used within a SidebarProvider.');\n }\n\n return context;\n}\n\nconst SidebarProvider = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & {\n defaultOpen?: boolean;\n open?: boolean;\n onOpenChange?: (open: boolean) => void;\n }\n>(\n (\n {\n defaultOpen = true,\n open: openProp,\n onOpenChange: setOpenProp,\n className,\n style,\n children,\n ...props\n },\n ref,\n ) => {\n const isMobile = useIsMobile();\n const [openMobile, setOpenMobile] = React.useState(false);\n\n // This is the internal state of the sidebar.\n // We use openProp and setOpenProp for control from outside the component.\n const [_open, _setOpen] = React.useState(defaultOpen);\n const isOpen = openProp ?? _open;\n const setOpen = React.useCallback(\n (value: boolean | ((value: boolean) => boolean)) => {\n const openState = typeof value === 'function' ? value(isOpen) : value;\n if (setOpenProp) {\n setOpenProp(openState);\n } else {\n _setOpen(openState);\n }\n\n // This sets the cookie to keep the sidebar state.\n document.cookie = `${SIDEBAR_COOKIE_NAME}=${openState}; path=/; max-age=${SIDEBAR_COOKIE_MAX_AGE}`;\n },\n [setOpenProp, isOpen],\n );\n\n // Helper to toggle the sidebar.\n const toggleSidebar = React.useCallback(() => {\n return isMobile ? setOpenMobile((open) => !open) : setOpen((open) => !open);\n }, [isMobile, setOpen, setOpenMobile]);\n\n // Adds a keyboard shortcut to toggle the sidebar.\n React.useEffect(() => {\n const handleKeyDown = (event: KeyboardEvent) => {\n if (event.key === SIDEBAR_KEYBOARD_SHORTCUT && (event.metaKey || event.ctrlKey)) {\n event.preventDefault();\n toggleSidebar();\n }\n };\n\n window.addEventListener('keydown', handleKeyDown);\n return () => window.removeEventListener('keydown', handleKeyDown);\n }, [toggleSidebar]);\n\n // We add a state so that we can do data-state=\"expanded\" or \"collapsed\".\n // This makes it easier to style the sidebar with Tailwind classes.\n const state = isOpen ? 'expanded' : 'collapsed';\n\n const contextValue = React.useMemo(\n () => ({\n state,\n open: isOpen,\n setOpen,\n isMobile,\n openMobile,\n setOpenMobile,\n toggleSidebar,\n }),\n [state, isOpen, setOpen, isMobile, openMobile, setOpenMobile, toggleSidebar],\n );\n\n return (\n \n \n \n {children}\n
    \n \n \n );\n },\n);\nSidebarProvider.displayName = 'SidebarProvider';\n\nconst Sidebar = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & {\n side?: 'left' | 'right';\n variant?: 'sidebar' | 'floating' | 'inset';\n collapsible?: 'offcanvas' | 'icon' | 'none';\n }\n>(\n (\n {\n side = 'left',\n variant = 'sidebar',\n collapsible = 'offcanvas',\n className,\n children,\n ...props\n },\n ref,\n ) => {\n const { isMobile, state, openMobile, setOpenMobile } = useSidebar();\n\n if (collapsible === 'none') {\n return (\n \n {children}\n
    \n );\n }\n\n if (isMobile) {\n return (\n \n button]:tw-hidden\"\n style={\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n {\n '--sidebar-width': SIDEBAR_WIDTH_MOBILE,\n } as React.CSSProperties\n }\n side={side}\n >\n
    {children}
    \n \n
    \n );\n }\n\n return (\n \n {/* This is what handles the sidebar gap on desktop */}\n \n \n \n {children}\n
    \n
    \n
    \n );\n },\n);\nSidebar.displayName = 'Sidebar';\n\nconst SidebarTrigger = React.forwardRef<\n React.ElementRef,\n React.ComponentProps\n>(({ className, onClick, ...props }, ref) => {\n const { toggleSidebar } = useSidebar();\n\n return (\n {\n onClick?.(event);\n toggleSidebar();\n }}\n {...props}\n >\n \n Toggle Sidebar\n \n );\n});\nSidebarTrigger.displayName = 'SidebarTrigger';\n\nconst SidebarRail = React.forwardRef>(\n ({ className, ...props }, ref) => {\n const { toggleSidebar } = useSidebar();\n\n return (\n \n );\n },\n);\nSidebarRail.displayName = 'SidebarRail';\n\nconst SidebarInset = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarInset.displayName = 'SidebarInset';\n\nconst SidebarInput = React.forwardRef<\n React.ElementRef,\n React.ComponentProps\n>(({ className, ...props }, ref) => {\n return (\n \n );\n});\nSidebarInput.displayName = 'SidebarInput';\n\nconst SidebarHeader = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarHeader.displayName = 'SidebarHeader';\n\nconst SidebarFooter = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarFooter.displayName = 'SidebarFooter';\n\nconst SidebarSeparator = React.forwardRef<\n React.ElementRef,\n React.ComponentProps\n>(({ className, ...props }, ref) => {\n return (\n \n );\n});\nSidebarSeparator.displayName = 'SidebarSeparator';\n\nconst SidebarContent = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarContent.displayName = 'SidebarContent';\n\nconst SidebarGroup = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarGroup.displayName = 'SidebarGroup';\n\nconst SidebarGroupLabel = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & { asChild?: boolean }\n>(({ className, asChild = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'div';\n\n return (\n svg]:tw-size-4 [&>svg]:tw-shrink-0',\n 'group-data-[collapsible=icon]:tw--mt-8 group-data-[collapsible=icon]:tw-opacity-0',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarGroupLabel.displayName = 'SidebarGroupLabel';\n\nconst SidebarGroupAction = React.forwardRef<\n HTMLButtonElement,\n React.ComponentProps<'button'> & { asChild?: boolean }\n>(({ className, asChild = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'button';\n\n return (\n svg]:tw-size-4 [&>svg]:tw-shrink-0',\n // Increases the hit area of the button on mobile.\n 'after:tw-absolute after:tw--inset-2 after:md:tw-hidden',\n 'group-data-[collapsible=icon]:tw-hidden',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarGroupAction.displayName = 'SidebarGroupAction';\n\nconst SidebarGroupContent = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarGroupContent.displayName = 'SidebarGroupContent';\n\nconst SidebarMenu = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenu.displayName = 'SidebarMenu';\n\nconst SidebarMenuItem = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenuItem.displayName = 'SidebarMenuItem';\n\nconst sidebarMenuButtonVariants = cva(\n // Removed data-[active=true]:tw-bg-sidebar-accent\n 'tw-peer/menu-button tw-flex tw-w-full tw-items-center tw-gap-2 tw-overflow-hidden tw-rounded-md tw-p-2 tw-text-left tw-text-sm tw-outline-none tw-ring-sidebar-ring tw-transition-[width,height,padding] hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground focus-visible:tw-ring-2 active:tw-bg-sidebar-accent active:tw-text-sidebar-accent-foreground disabled:tw-pointer-events-none disabled:tw-opacity-50 tw-group-has-[[data-sidebar=menu-action]]/menu-item:pr-8 aria-disabled:tw-pointer-events-none aria-disabled:tw-opacity-50 data-[active=true]:tw-font-medium data-[active=true]:tw-text-sidebar-accent-foreground data-[state=open]:hover:tw-bg-sidebar-accent data-[state=open]:hover:tw-text-sidebar-accent-foreground group-data-[collapsible=icon]:tw-!size-8 group-data-[collapsible=icon]:tw-!p-2 [&>span:last-child]:tw-truncate [&>svg]:tw-size-4 [&>svg]:tw-shrink-0',\n {\n variants: {\n variant: {\n default: 'hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground',\n outline:\n 'tw-bg-background tw-shadow-[0_0_0_1px_hsl(var(--sidebar-border))] hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground hover:tw-shadow-[0_0_0_1px_hsl(var(--sidebar-accent))]',\n },\n size: {\n default: 'tw-h-8 tw-text-sm',\n sm: 'tw-h-7 tw-text-xs',\n lg: 'tw-h-12 tw-text-sm group-data-[collapsible=icon]:tw-!p-0',\n },\n },\n defaultVariants: {\n variant: 'default',\n size: 'default',\n },\n },\n);\n\nconst SidebarMenuButton = React.forwardRef<\n HTMLButtonElement,\n React.ComponentProps<'button'> & {\n asChild?: boolean;\n isActive?: boolean;\n tooltip?: string | React.ComponentProps;\n } & VariantProps\n>(\n (\n {\n asChild = false,\n isActive = false,\n variant = 'default',\n size = 'default',\n tooltip,\n className,\n ...props\n },\n ref,\n ) => {\n const Comp = asChild ? Slot : 'button';\n const { isMobile, state } = useSidebar();\n\n const button = (\n \n );\n\n if (!tooltip) {\n return button;\n }\n\n if (typeof tooltip === 'string') {\n // eslint-disable-next-line no-param-reassign\n tooltip = {\n children: tooltip,\n };\n }\n\n return (\n \n {button}\n \n );\n },\n);\nSidebarMenuButton.displayName = 'SidebarMenuButton';\n\nconst SidebarMenuAction = React.forwardRef<\n HTMLButtonElement,\n React.ComponentProps<'button'> & {\n asChild?: boolean;\n showOnHover?: boolean;\n }\n>(({ className, asChild = false, showOnHover = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'button';\n\n return (\n svg]:tw-size-4 [&>svg]:tw-shrink-0',\n // Increases the hit area of the button on mobile.\n 'after:tw-absolute after:tw--inset-2 after:md:tw-hidden',\n 'tw-peer-data-[size=sm]/menu-button:top-1',\n 'tw-peer-data-[size=default]/menu-button:top-1.5',\n 'tw-peer-data-[size=lg]/menu-button:top-2.5',\n 'group-data-[collapsible=icon]:tw-hidden',\n showOnHover &&\n 'tw-group-focus-within/menu-item:opacity-100 tw-group-hover/menu-item:opacity-100 tw-peer-data-[active=true]/menu-button:text-sidebar-accent-foreground data-[state=open]:tw-opacity-100 md:tw-opacity-0',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarMenuAction.displayName = 'SidebarMenuAction';\n\nconst SidebarMenuBadge = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenuBadge.displayName = 'SidebarMenuBadge';\n\nconst SidebarMenuSkeleton = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & {\n showIcon?: boolean;\n }\n>(({ className, showIcon = false, ...props }, ref) => {\n // Random width between 50 to 90%.\n const width = React.useMemo(() => {\n return `${Math.floor(Math.random() * 40) + 50}%`;\n }, []);\n\n return (\n \n {showIcon && (\n \n )}\n \n
    \n );\n});\nSidebarMenuSkeleton.displayName = 'SidebarMenuSkeleton';\n\nconst SidebarMenuSub = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenuSub.displayName = 'SidebarMenuSub';\n\nconst SidebarMenuSubItem = React.forwardRef>(\n ({ ...props }, ref) =>
  • ,\n);\nSidebarMenuSubItem.displayName = 'SidebarMenuSubItem';\n\nconst SidebarMenuSubButton = React.forwardRef<\n HTMLAnchorElement,\n React.ComponentProps<'a'> & {\n asChild?: boolean;\n size?: 'sm' | 'md';\n isActive?: boolean;\n }\n>(({ asChild = false, size = 'md', isActive, className, ...props }, ref) => {\n const Comp = asChild ? Slot : 'a';\n\n return (\n span:last-child]:tw-truncate [&>svg]:tw-size-4 [&>svg]:tw-shrink-0 [&>svg]:tw-text-sidebar-accent-foreground',\n 'data-[active=true]:tw-bg-sidebar-accent data-[active=true]:tw-text-sidebar-accent-foreground',\n size === 'sm' && 'tw-text-xs',\n size === 'md' && 'tw-text-sm',\n 'group-data-[collapsible=icon]:tw-hidden',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarMenuSubButton.displayName = 'SidebarMenuSubButton';\n\nexport {\n Sidebar,\n SidebarContent,\n SidebarFooter,\n SidebarGroup,\n SidebarGroupAction,\n SidebarGroupContent,\n SidebarGroupLabel,\n SidebarHeader,\n SidebarInput,\n SidebarInset,\n SidebarMenu,\n SidebarMenuAction,\n SidebarMenuBadge,\n SidebarMenuButton,\n SidebarMenuItem,\n SidebarMenuSkeleton,\n SidebarMenuSub,\n SidebarMenuSubButton,\n SidebarMenuSubItem,\n SidebarProvider,\n SidebarRail,\n SidebarSeparator,\n SidebarTrigger,\n useSidebar,\n};\n","import ComboBox, { ComboBoxOption } from '@/components/basics/combo-box.component';\nimport {\n Sidebar,\n SidebarContent,\n SidebarGroup,\n SidebarGroupLabel,\n SidebarGroupContent,\n SidebarMenu,\n SidebarMenuItem,\n SidebarMenuButton,\n} from '@/components/shadcn-ui/sidebar';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { useCallback } from 'react';\n\nexport type SelectedSettingsSidebarItem = {\n label: string;\n projectId?: string;\n};\n\nexport type ProjectOptions = { projectId: string; projectName: string };\n\nexport type SettingsSidebarProps = {\n /** Optional id for testing */\n id?: string;\n\n /** Extension labels from contribution */\n extensionLabels: string[];\n\n /** Project names and ids */\n projectOptions: ProjectOptions[];\n\n /** Handler for selecting a sidebar item */\n handleSelectSidebarItem: (key: string, projectId?: string) => void;\n\n /** The current selected value in the sidebar */\n selectedSidebarItem: SelectedSettingsSidebarItem;\n};\n\nexport default function SettingsSidebar({\n id,\n extensionLabels,\n projectOptions,\n handleSelectSidebarItem,\n selectedSidebarItem,\n}: SettingsSidebarProps) {\n const handleSelectItem = useCallback(\n (item: string, projectId?: string) => {\n handleSelectSidebarItem(item, projectId);\n },\n [handleSelectSidebarItem],\n );\n\n const getProjectNameFromProjectId = useCallback(\n (projectId: string) => {\n const project = projectOptions.find((option) => option.projectId === projectId);\n return project ? project.projectName : projectId;\n },\n [projectOptions],\n );\n\n const getIsActive: (label: string) => boolean = useCallback(\n (label: string) => !selectedSidebarItem.projectId && label === selectedSidebarItem.label,\n [selectedSidebarItem],\n );\n\n return (\n \n \n \n Extensions\n \n \n {extensionLabels.map((label) => (\n \n handleSelectItem(label, undefined)}\n isActive={getIsActive(label)}\n >\n {label}\n \n \n ))}\n \n \n \n \n Projects\n \n option.projectId)}\n getOptionLabel={(projectId: ComboBoxOption) => {\n // This function expects a ComboBoxOption, but we know it is a string\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n return getProjectNameFromProjectId(projectId as string);\n }}\n buttonPlaceholder=\"Type or select project\"\n onChange={(projectId: string) => {\n const selectedProjectName = getProjectNameFromProjectId(projectId);\n handleSelectItem(selectedProjectName, projectId);\n }}\n value={selectedSidebarItem?.projectId ?? undefined}\n />\n \n \n \n \n );\n}\n","import { SidebarInset, SidebarProvider } from '@/components/shadcn-ui/sidebar';\nimport { PropsWithChildren } from 'react';\nimport SearchBar from '@/components/basics/search-bar.component';\nimport SettingsSidebar, { SettingsSidebarProps } from './settings-sidebar.component';\n\nexport type SettingsSidebarContentSearchProps = SettingsSidebarProps &\n PropsWithChildren & {\n /** Optional id for testing */\n id?: string;\n\n /** Text direction ltr or rtl */\n direction?: 'ltr' | 'rtl';\n\n /** Handler to run when the value of the search bar changes */\n onSearch: (searchQuery: string) => void;\n };\n\nexport default function SettingsSidebarContentSearch({\n id,\n direction = 'ltr',\n extensionLabels,\n projectOptions,\n children,\n handleSelectSidebarItem,\n selectedSidebarItem,\n onSearch,\n}: SettingsSidebarContentSearchProps) {\n return (\n
    \n
    \n \n
    \n \n \n {children}\n \n
    \n );\n}\n","import { Button } from '@/components/shadcn-ui/button';\nimport {\n Select,\n SelectContent,\n SelectGroup,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\nimport {\n Table,\n TableBody,\n TableCell,\n TableHead,\n TableHeader,\n TableRow,\n} from '@/components/shadcn-ui/table';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Canon } from '@sillsdev/scripture';\nimport {\n Cell,\n ColumnDef,\n flexRender,\n getCoreRowModel,\n getExpandedRowModel,\n getGroupedRowModel,\n getSortedRowModel,\n GroupingState,\n Row,\n RowSelectionState,\n SortingState,\n useReactTable,\n} from '@tanstack/react-table';\nimport '@/components/advanced/scripture-results-viewer/scripture-results-viewer.component.css';\nimport {\n compareScrRefs,\n formatScrRef,\n ScriptureSelection,\n scrRefToBBBCCCVVV,\n} from 'platform-bible-utils';\nimport { MouseEvent, useEffect, useMemo, useState } from 'react';\nimport { ChevronDown, ChevronLeft, ChevronRight } from 'lucide-react';\n\n/**\n * Information (e.g., a checking error or some other type of \"transient\" annotation) about something\n * noteworthy at a specific place in an instance of the Scriptures.\n */\nexport type ScriptureItemDetail = ScriptureSelection & {\n /**\n * Text of the error, note, etc. In the future, we might want to support something more than just\n * text so that a JSX element could be provided with a link or some other controls related to the\n * issue being reported.\n */\n detail: string;\n};\n\n/**\n * A uniquely identifiable source of results that can be displayed in the ScriptureResultsViewer.\n * Generally, the source will be a particular Scripture check, but there may be other types of\n * sources.\n */\nexport type ResultsSource = {\n /**\n * Uniquely identifies the source.\n *\n * @type {string}\n */\n id: string;\n\n /**\n * Name (potentially localized) of the source, suitable for display in the UI.\n *\n * @type {string}\n */\n displayName: string;\n};\n\nexport type ScriptureSrcItemDetail = ScriptureItemDetail & {\n /** Source/type of detail. Can be used for grouping. */\n source: ResultsSource;\n};\n\n/**\n * Represents a set of results keyed by Scripture reference. Generally, the source will be a\n * particular Scripture check, but this type also allows for other types of uniquely identifiable\n * sources.\n */\nexport type ResultsSet = {\n /**\n * The backing source associated with this set of results.\n *\n * @type {ResultsSource}\n */\n source: ResultsSource;\n\n /**\n * Array of Scripture item details (messages keyed by Scripture reference).\n *\n * @type {ScriptureItemDetail[]}\n */\n data: ScriptureItemDetail[];\n};\n\nconst scrBookColId = 'scrBook';\nconst scrRefColId = 'scrRef';\nconst typeColId = 'source';\nconst detailsColId = 'details';\n\nconst defaultScrRefColumnName = 'Scripture Reference';\nconst defaultScrBookGroupName = 'Scripture Book';\nconst defaultTypeColumnName = 'Type';\nconst defaultDetailsColumnName = 'Details';\n\nexport type ScriptureResultsViewerColumnInfo = {\n /** Optional header to display for the Reference column. Default value: 'Scripture Reference'. */\n scriptureReferenceColumnName?: string;\n\n /** Optional text to display to refer to the Scripture book group. Default value: 'Scripture Book'. */\n scriptureBookGroupName?: string;\n\n /** Optional header to display for the Type column. Default value: 'Type'. */\n typeColumnName?: string;\n\n /** Optional header to display for the Details column. Default value: 'Details' */\n detailsColumnName?: string;\n};\n\nexport type ScriptureResultsViewerProps = ScriptureResultsViewerColumnInfo & {\n /** Groups of ScriptureItemDetail objects from particular sources (e.g., Scripture checks) */\n sources: ResultsSet[];\n\n /** Flag indicating whether to display column headers. Default is false. */\n showColumnHeaders?: boolean;\n\n /** Flag indicating whether to display source column. Default is false. */\n showSourceColumn?: boolean;\n\n /** Callback function to notify when a row is selected */\n onRowSelected?: (selectedRow: ScriptureSrcItemDetail | undefined) => void;\n\n /** Text direction ltr or rtl */\n direction?: 'ltr' | 'rtl';\n};\n\nfunction getColumns(\n colInfo?: ScriptureResultsViewerColumnInfo,\n showSourceColumn?: boolean,\n): ColumnDef[] {\n const showSrcCol = showSourceColumn ?? false;\n return [\n {\n accessorFn: (row) =>\n `${Canon.bookNumberToId(row.start.bookNum)} ${row.start.chapterNum}:${row.start.verseNum}`,\n id: scrBookColId,\n header: colInfo?.scriptureReferenceColumnName ?? defaultScrRefColumnName,\n cell: (info) => {\n const row = info.row.original;\n if (info.row.getIsGrouped()) {\n return Canon.bookNumberToEnglishName(row.start.bookNum);\n }\n return info.row.groupingColumnId === scrBookColId ? formatScrRef(row.start) : undefined;\n },\n getGroupingValue: (row) => row.start.bookNum,\n sortingFn: (a, b) => {\n return compareScrRefs(a.original.start, b.original.start);\n },\n enableGrouping: true,\n },\n {\n accessorFn: (row) => formatScrRef(row.start),\n id: scrRefColId,\n header: undefined,\n cell: (info) => {\n const row = info.row.original;\n return info.row.getIsGrouped() ? undefined : formatScrRef(row.start);\n },\n sortingFn: (a, b) => {\n return compareScrRefs(a.original.start, b.original.start);\n },\n enableGrouping: false,\n },\n {\n accessorFn: (row) => row.source.displayName,\n id: typeColId,\n header: showSrcCol ? (colInfo?.typeColumnName ?? defaultTypeColumnName) : undefined,\n cell: (info) => (showSrcCol || info.row.getIsGrouped() ? info.getValue() : undefined),\n getGroupingValue: (row) => row.source.id,\n sortingFn: (a, b) =>\n a.original.source.displayName.localeCompare(b.original.source.displayName),\n enableGrouping: true,\n },\n {\n accessorFn: (row) => row.detail,\n id: detailsColId,\n header: colInfo?.detailsColumnName ?? defaultDetailsColumnName,\n cell: (info) => info.getValue(),\n enableGrouping: false,\n },\n ];\n}\n\nconst toRefOrRange = (scriptureSelection: ScriptureSelection) => {\n if (!('offset' in scriptureSelection.start))\n throw new Error('No offset available in range start');\n if (scriptureSelection.end && !('offset' in scriptureSelection.end))\n throw new Error('No offset available in range end');\n const { offset: offsetStart } = scriptureSelection.start;\n let offsetEnd: number = 0;\n if (scriptureSelection.end) ({ offset: offsetEnd } = scriptureSelection.end);\n if (\n !scriptureSelection.end ||\n compareScrRefs(scriptureSelection.start, scriptureSelection.end) === 0\n )\n return `${scrRefToBBBCCCVVV(scriptureSelection.start)}+${offsetStart}`;\n return `${scrRefToBBBCCCVVV(scriptureSelection.start)}+${offsetStart}-${scrRefToBBBCCCVVV(scriptureSelection.end)}+${offsetEnd}`;\n};\n\nconst getRowKey = (row: ScriptureSrcItemDetail) =>\n `${toRefOrRange({ start: row.start, end: row.end })} ${row.source.displayName} ${row.detail}`;\n\n/**\n * Component to display a combined list of detailed items from one or more sources, where the items\n * are keyed primarily by Scripture reference. This is particularly useful for displaying a list of\n * results from Scripture checks, but more generally could be used to display any \"results\" from any\n * source(s). The component allows for grouping by Scripture book, source, or both. By default, it\n * displays somewhat \"tree-like\" which allows it to be more horizontally compact and intuitive. But\n * it also has the option of displaying as a traditional table with column headings (with or without\n * the source column showing).\n */\nexport default function ScriptureResultsViewer({\n sources,\n showColumnHeaders = false,\n showSourceColumn = false,\n scriptureReferenceColumnName,\n scriptureBookGroupName,\n typeColumnName,\n detailsColumnName,\n onRowSelected,\n direction = 'ltr',\n}: ScriptureResultsViewerProps) {\n const [grouping, setGrouping] = useState([]);\n const [sorting, setSorting] = useState([{ id: scrBookColId, desc: false }]);\n const [rowSelection, setRowSelection] = useState({});\n\n const scriptureResults = useMemo(\n () =>\n sources.flatMap((source) => {\n return source.data.map((item) => ({\n ...item,\n source: source.source,\n }));\n }),\n [sources],\n );\n\n const columns = useMemo(\n () =>\n getColumns(\n {\n scriptureReferenceColumnName,\n typeColumnName,\n detailsColumnName,\n },\n showSourceColumn,\n ),\n [scriptureReferenceColumnName, typeColumnName, detailsColumnName, showSourceColumn],\n );\n\n useEffect(() => {\n // Ensure sorting is applied correctly when grouped by type\n if (grouping.includes(typeColId)) {\n setSorting([\n { id: typeColId, desc: false },\n { id: scrBookColId, desc: false },\n ]);\n } else {\n setSorting([{ id: scrBookColId, desc: false }]);\n }\n }, [grouping]);\n\n const table = useReactTable({\n data: scriptureResults,\n columns,\n state: {\n grouping,\n sorting,\n rowSelection,\n },\n onGroupingChange: setGrouping,\n onSortingChange: setSorting,\n onRowSelectionChange: setRowSelection,\n getExpandedRowModel: getExpandedRowModel(),\n getGroupedRowModel: getGroupedRowModel(),\n getCoreRowModel: getCoreRowModel(),\n getSortedRowModel: getSortedRowModel(),\n getRowId: getRowKey,\n autoResetExpanded: false,\n enableMultiRowSelection: false,\n enableSubRowSelection: false,\n });\n\n useEffect(() => {\n if (onRowSelected) {\n const selectedRows = table.getSelectedRowModel().rowsById;\n const keys = Object.keys(selectedRows);\n if (keys.length === 1) {\n const selectedRow = scriptureResults.find((row) => getRowKey(row) === keys[0]) || undefined;\n if (selectedRow) onRowSelected(selectedRow);\n }\n }\n }, [rowSelection, scriptureResults, onRowSelected, table]);\n\n // Define possible grouping options\n const scrBookGroupName = scriptureBookGroupName ?? defaultScrBookGroupName;\n const typeGroupName = typeColumnName ?? defaultTypeColumnName;\n\n const groupingOptions = [\n { label: 'No Grouping', value: [] },\n { label: `Group by ${scrBookGroupName}`, value: [scrBookColId] },\n { label: `Group by ${typeGroupName}`, value: [typeColId] },\n {\n label: `Group by ${scrBookGroupName} and ${typeGroupName}`,\n value: [scrBookColId, typeColId],\n },\n {\n label: `Group by ${typeGroupName} and ${scrBookGroupName}`,\n value: [typeColId, scrBookColId],\n },\n ];\n\n const handleSelectChange = (selectedGrouping: string) => {\n setGrouping(JSON.parse(selectedGrouping));\n };\n\n const handleRowClick = (row: Row, event: MouseEvent) => {\n if (!row.getIsGrouped() && !row.getIsSelected()) {\n row.getToggleSelectedHandler()(event);\n }\n };\n\n const getEvenOrOddBandingStyle = (row: Row, index: number) => {\n if (row.getIsGrouped()) return '';\n // UX has now said they don't think they want banding. I'm leaving in the code to\n // set even and odd styles, but there's nothing in the CSS to style them differently.\n // The \"even\" style used to also have tw-bg-neutral-300 (along with even) to create\n // a visual banding effect. That could be added back in if UX changes the decision.\n return cn('banded-row', index % 2 === 0 ? 'even' : 'odd');\n };\n\n const getIndent = (\n groupingState: GroupingState,\n row: Row,\n cell: Cell,\n ) => {\n if (groupingState?.length === 0 || row.depth < cell.column.getGroupedIndex()) return undefined;\n if (row.getIsGrouped()) {\n switch (row.depth) {\n case 1:\n return 'tw-ps-4';\n default:\n return undefined;\n }\n }\n switch (row.depth) {\n case 1:\n return 'tw-ps-8';\n case 2:\n return 'tw-ps-12';\n default:\n return undefined;\n }\n };\n\n return (\n
    \n {!showColumnHeaders && (\n {\n handleSelectChange(value);\n }}\n >\n \n \n \n \n \n {groupingOptions.map((option) => (\n \n {option.label}\n \n ))}\n \n \n \n )}\n \n {showColumnHeaders && (\n \n {table.getHeaderGroups().map((headerGroup) => (\n \n {headerGroup.headers\n .filter((h) => h.column.columnDef.header)\n .map((header) => (\n /* For sticky column headers to work, we probably need to change the default definition of the shadcn Table component. See https://github.com/shadcn-ui/ui/issues/1151 */\n \n {header.isPlaceholder ? undefined : (\n
    \n {header.column.getCanGroup() ? (\n \n {header.column.getIsGrouped() ? `🛑` : `👊 `}\n \n ) : undefined}{' '}\n {flexRender(header.column.columnDef.header, header.getContext())}\n
    \n )}\n
    \n ))}\n
    \n ))}\n
    \n )}\n \n {table.getRowModel().rows.map((row, rowIndex) => {\n return (\n handleRowClick(row, event)}\n >\n {row.getVisibleCells().map((cell) => {\n if (\n cell.getIsPlaceholder() ||\n (cell.column.columnDef.enableGrouping &&\n !cell.getIsGrouped() &&\n (cell.column.columnDef.id !== typeColId || !showSourceColumn))\n )\n return undefined;\n return (\n \n {(() => {\n if (cell.getIsGrouped()) {\n return (\n \n {row.getIsExpanded() && }\n {!row.getIsExpanded() &&\n (direction === 'ltr' ? : )}{' '}\n {flexRender(cell.column.columnDef.cell, cell.getContext())} (\n {row.subRows.length})\n \n );\n }\n\n // if (cell.getIsAggregated()) {\n // flexRender(\n // cell.column.columnDef.aggregatedCell ?? cell.column.columnDef.cell,\n // cell.getContext(),\n // );\n // }\n\n return flexRender(cell.column.columnDef.cell, cell.getContext());\n })()}\n \n );\n })}\n \n );\n })}\n \n
    \n
    \n );\n}\n","import {\n getLocalizeKeyForScrollGroupId,\n LanguageStrings,\n ScrollGroupId,\n} from 'platform-bible-utils';\nimport {\n Select,\n SelectContent,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\n\nconst DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS = {\n [getLocalizeKeyForScrollGroupId('undefined')]: 'Ø',\n [getLocalizeKeyForScrollGroupId(0)]: 'A',\n [getLocalizeKeyForScrollGroupId(1)]: 'B',\n [getLocalizeKeyForScrollGroupId(2)]: 'C',\n [getLocalizeKeyForScrollGroupId(3)]: 'D',\n [getLocalizeKeyForScrollGroupId(4)]: 'E',\n [getLocalizeKeyForScrollGroupId(5)]: 'F',\n [getLocalizeKeyForScrollGroupId(6)]: 'G',\n [getLocalizeKeyForScrollGroupId(7)]: 'H',\n [getLocalizeKeyForScrollGroupId(8)]: 'I',\n [getLocalizeKeyForScrollGroupId(9)]: 'J',\n [getLocalizeKeyForScrollGroupId(10)]: 'K',\n [getLocalizeKeyForScrollGroupId(11)]: 'L',\n [getLocalizeKeyForScrollGroupId(12)]: 'M',\n [getLocalizeKeyForScrollGroupId(13)]: 'N',\n [getLocalizeKeyForScrollGroupId(14)]: 'O',\n [getLocalizeKeyForScrollGroupId(15)]: 'P',\n [getLocalizeKeyForScrollGroupId(16)]: 'Q',\n [getLocalizeKeyForScrollGroupId(17)]: 'R',\n [getLocalizeKeyForScrollGroupId(18)]: 'S',\n [getLocalizeKeyForScrollGroupId(19)]: 'T',\n [getLocalizeKeyForScrollGroupId(20)]: 'U',\n [getLocalizeKeyForScrollGroupId(21)]: 'V',\n [getLocalizeKeyForScrollGroupId(22)]: 'W',\n [getLocalizeKeyForScrollGroupId(23)]: 'X',\n [getLocalizeKeyForScrollGroupId(24)]: 'Y',\n [getLocalizeKeyForScrollGroupId(25)]: 'Z',\n};\n\nexport type ScrollGroupSelectorProps = {\n /**\n * List of scroll group ids to show to the user. Either a {@link ScrollGroupId} or `undefined` for\n * no scroll group\n */\n availableScrollGroupIds: (ScrollGroupId | undefined)[];\n /** Currently selected scroll group id. `undefined` for no scroll group */\n scrollGroupId: ScrollGroupId | undefined;\n /** Callback function run when the user tries to change the scroll group id */\n onChangeScrollGroupId: (newScrollGroupId: ScrollGroupId | undefined) => void;\n /**\n * Localized strings to use for displaying scroll group ids. Must be an object whose keys are\n * `getLocalizeKeyForScrollGroupId(scrollGroupId)` for all scroll group ids (and `undefined` if\n * included) in {@link ScrollGroupSelectorProps.availableScrollGroupIds} and whose values are the\n * localized strings to use for those scroll group ids.\n *\n * Defaults to English localizations of English alphabet for scroll groups 0-25 (e.g. 0 is A) and\n * Ø for `undefined`. Will fill in any that are not provided with these English localizations.\n * Also, if any values match the keys, the English localization will be used. This is useful in\n * case you want to pass in a temporary version of the localized strings while your localized\n * strings load.\n *\n * @example\n *\n * ```typescript\n * const myScrollGroupIdLocalizedStrings = {\n * [getLocalizeKeyForScrollGroupId('undefined')]: 'Ø',\n * [getLocalizeKeyForScrollGroupId(0)]: 'A',\n * [getLocalizeKeyForScrollGroupId(1)]: 'B',\n * [getLocalizeKeyForScrollGroupId(2)]: 'C',\n * [getLocalizeKeyForScrollGroupId(3)]: 'D',\n * [getLocalizeKeyForScrollGroupId(4)]: 'E',\n * };\n * ```\n *\n * @example\n *\n * ```tsx\n * const availableScrollGroupIds = [undefined, 0, 1, 2, 3, 4];\n *\n * const localizeKeys = getLocalizeKeysForScrollGroupIds();\n *\n * const [localizedStrings] = useLocalizedStrings(localizeKeys);\n *\n * ...\n *\n * \n * ```\n */\n localizedStrings?: LanguageStrings;\n};\n\n/** Selector component for choosing a scroll group */\nexport default function ScrollGroupSelector({\n availableScrollGroupIds,\n scrollGroupId,\n onChangeScrollGroupId,\n localizedStrings = {},\n}: ScrollGroupSelectorProps) {\n const localizedStringsDefaulted = {\n ...DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS,\n ...Object.fromEntries(\n Object.entries(localizedStrings).map(\n ([localizedStringKey, localizedStringValue]: [string, string]) => [\n localizedStringKey,\n localizedStringKey === localizedStringValue &&\n localizedStringKey in DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS\n ? DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS[localizedStringKey]\n : localizedStringValue,\n ],\n ),\n ),\n };\n return (\n \n onChangeScrollGroupId(\n newScrollGroupString === 'undefined' ? undefined : parseInt(newScrollGroupString, 10),\n )\n }\n >\n \n \n \n \n {availableScrollGroupIds.map((scrollGroupOptionId) => (\n \n {localizedStringsDefaulted[getLocalizeKeyForScrollGroupId(scrollGroupOptionId)]}\n \n ))}\n \n \n );\n}\n","import { PropsWithChildren } from 'react';\nimport { Separator } from '@/components/shadcn-ui/separator';\n\n/** Props for the SettingsList component, currently just children */\ntype SettingsListProps = PropsWithChildren;\n\n/**\n * SettingsList component is a wrapper for list items. Rendered with a formatted div\n *\n * @param children To populate the list with\n * @returns Formatted div encompassing the children\n */\nexport function SettingsList({ children }: SettingsListProps) {\n return
    {children}
    ;\n}\n\n/** Props for SettingsListItem component */\ntype SettingsListItemProps = PropsWithChildren & {\n /** Primary text of the list item */\n primary: string;\n\n /** Optional text of the list item */\n secondary?: string | undefined;\n\n /** Optional boolean to display a message if the children aren't loaded yet. Defaults to false */\n isLoading?: boolean;\n\n /** Optional message to display if isLoading */\n loadingMessage?: string;\n};\n\n/**\n * SettingsListItem component is a common list item. Rendered with a formatted div\n *\n * @param primary Primary text of the list item\n * @param secondary Optional secondary text of the list item\n * @param isLoading Optional, to display a message if the action component isn't generated yet,\n * defaults to false\n * @param children The action component(s) to provide for this item\n * @param loadingMessage Optional, message to display if isLoading\n * @returns Formatted div encompassing the list item content\n */\nexport function SettingsListItem({\n primary,\n secondary,\n children,\n isLoading = false,\n loadingMessage,\n}: SettingsListItemProps) {\n return (\n
    \n
    \n

    {primary}

    \n

    \n {secondary}\n

    \n
    \n\n {isLoading ? (\n

    {loadingMessage}

    \n ) : (\n
    {children}
    \n )}\n
    \n );\n}\n\n/** Props for SettingsListHeader component */\ntype SettingsListHeaderProps = {\n /** The primary text of the list header */\n primary: string;\n\n /** Optional secondary text of the list header */\n secondary?: string | undefined;\n\n /** Optional boolean to include a separator underneath the secondary text. Defaults to false */\n includeSeparator?: boolean;\n};\n\n/**\n * SettingsListHeader component displays text above the list\n *\n * @param primary The primary text of the list header\n * @param secondary Optional secondary text of the list header\n * @param includeSeparator Optional boolean to include a separator underneath the secondary text.\n * Defaults to false\n * @returns Formatted div with list header content\n */\nexport function SettingsListHeader({\n primary,\n secondary,\n includeSeparator = false,\n}: SettingsListHeaderProps) {\n return (\n
    \n
    \n

    {primary}

    \n

    {secondary}

    \n
    \n {includeSeparator ? : ''}\n
    \n );\n}\n","import React from 'react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Card = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nCard.displayName = 'Card';\n\nconst CardHeader = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nCardHeader.displayName = 'CardHeader';\n\nconst CardTitle = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n {/* added because of https://github.com/jsx-eslint/eslint-plugin-jsx-a11y/blob/main/docs/rules/heading-has-content.md */}\n {props.children}\n \n ),\n);\nCardTitle.displayName = 'CardTitle';\n\nconst CardDescription = React.forwardRef<\n HTMLParagraphElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n

    \n));\nCardDescription.displayName = 'CardDescription';\n\nconst CardContent = React.forwardRef>(\n ({ className, ...props }, ref) => (\n

    \n ),\n);\nCardContent.displayName = 'CardContent';\n\nconst CardFooter = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nCardFooter.displayName = 'CardFooter';\n\nexport { Card, CardHeader, CardFooter, CardTitle, CardDescription, CardContent };\n","import {\n Card,\n CardDescription,\n CardHeader,\n CardTitle,\n CardContent,\n} from '@/components/shadcn-ui/card';\nimport { PropsWithChildren } from 'react';\n\ntype SettingsCardProps = PropsWithChildren & {\n /** Optional id for testing */\n id?: string;\n\n /** Label of the settings group */\n settingsGroupLabel: string;\n\n /** Optional description of the settings group */\n settingsGroupDescription?: string;\n};\n\nexport default function SettingsCard({\n id,\n settingsGroupLabel,\n settingsGroupDescription,\n children,\n}: SettingsCardProps) {\n return (\n \n \n {settingsGroupLabel}\n {settingsGroupDescription && {settingsGroupDescription}}\n \n {children}\n \n );\n}\n","import Checkbox from '@/components/shadcn-ui/checkbox';\nimport { Label } from '@/components/shadcn-ui/label';\n\nexport type ChecklistProps = {\n /** Optional string representing the id attribute of the Checklist */\n id?: string;\n /** Optional string representing CSS class name(s) for styling */\n className?: string;\n /** Array of strings representing the checkable items */\n listItems: string[];\n /** Array of strings representing the checked items */\n selectedListItems: string[];\n /**\n * Function that is called when a checkbox item is selected or deselected\n *\n * @param item The string description for this item\n * @param selected True if selected, false if not selected\n */\n handleSelectListItem: (item: string, selected: boolean) => void;\n\n /**\n * Optional function creates a label for a provided checkable item\n *\n * @param item The item for which a label is to be created\n * @returns A string representing the label text for the checkbox associated with that item\n */\n createLabel?: (item: string) => string;\n};\n\n/** Renders a list of checkboxes. Each checkbox corresponds to an item from the `listItems` array. */\nexport default function Checklist({\n id,\n className,\n listItems,\n selectedListItems,\n handleSelectListItem,\n createLabel,\n}: ChecklistProps) {\n return (\n
    \n {listItems.map((item) => (\n
    \n handleSelectListItem(item, value)}\n />\n \n
    \n ))}\n
    \n );\n}\n","function _interopRequireDefault(obj) {\n return obj && obj.__esModule ? obj : {\n \"default\": obj\n };\n}\nmodule.exports = _interopRequireDefault, module.exports.__esModule = true, module.exports[\"default\"] = module.exports;","export default function chainPropTypes(propType1, propType2) {\n if (process.env.NODE_ENV === 'production') {\n return () => null;\n }\n return function validate(...args) {\n return propType1(...args) || propType2(...args);\n };\n}","export default function _extends() {\n _extends = Object.assign ? Object.assign.bind() : function (target) {\n for (var i = 1; i < arguments.length; i++) {\n var source = arguments[i];\n for (var key in source) {\n if (Object.prototype.hasOwnProperty.call(source, key)) {\n target[key] = source[key];\n }\n }\n }\n return target;\n };\n return _extends.apply(this, arguments);\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\n// https://github.com/sindresorhus/is-plain-obj/blob/main/index.js\nexport function isPlainObject(item) {\n if (typeof item !== 'object' || item === null) {\n return false;\n }\n const prototype = Object.getPrototypeOf(item);\n return (prototype === null || prototype === Object.prototype || Object.getPrototypeOf(prototype) === null) && !(Symbol.toStringTag in item) && !(Symbol.iterator in item);\n}\nfunction deepClone(source) {\n if (!isPlainObject(source)) {\n return source;\n }\n const output = {};\n Object.keys(source).forEach(key => {\n output[key] = deepClone(source[key]);\n });\n return output;\n}\nexport default function deepmerge(target, source, options = {\n clone: true\n}) {\n const output = options.clone ? _extends({}, target) : target;\n if (isPlainObject(target) && isPlainObject(source)) {\n Object.keys(source).forEach(key => {\n // Avoid prototype pollution\n if (key === '__proto__') {\n return;\n }\n if (isPlainObject(source[key]) && key in target && isPlainObject(target[key])) {\n // Since `output` is a clone of `target` and we have narrowed `target` in this block we can cast to the same type.\n output[key] = deepmerge(target[key], source[key], options);\n } else if (options.clone) {\n output[key] = isPlainObject(source[key]) ? deepClone(source[key]) : source[key];\n } else {\n output[key] = source[key];\n }\n });\n }\n return output;\n}","/** @license React v16.13.1\n * react-is.production.min.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';var b=\"function\"===typeof Symbol&&Symbol.for,c=b?Symbol.for(\"react.element\"):60103,d=b?Symbol.for(\"react.portal\"):60106,e=b?Symbol.for(\"react.fragment\"):60107,f=b?Symbol.for(\"react.strict_mode\"):60108,g=b?Symbol.for(\"react.profiler\"):60114,h=b?Symbol.for(\"react.provider\"):60109,k=b?Symbol.for(\"react.context\"):60110,l=b?Symbol.for(\"react.async_mode\"):60111,m=b?Symbol.for(\"react.concurrent_mode\"):60111,n=b?Symbol.for(\"react.forward_ref\"):60112,p=b?Symbol.for(\"react.suspense\"):60113,q=b?\nSymbol.for(\"react.suspense_list\"):60120,r=b?Symbol.for(\"react.memo\"):60115,t=b?Symbol.for(\"react.lazy\"):60116,v=b?Symbol.for(\"react.block\"):60121,w=b?Symbol.for(\"react.fundamental\"):60117,x=b?Symbol.for(\"react.responder\"):60118,y=b?Symbol.for(\"react.scope\"):60119;\nfunction z(a){if(\"object\"===typeof a&&null!==a){var u=a.$$typeof;switch(u){case c:switch(a=a.type,a){case l:case m:case e:case g:case f:case p:return a;default:switch(a=a&&a.$$typeof,a){case k:case n:case t:case r:case h:return a;default:return u}}case d:return u}}}function A(a){return z(a)===m}exports.AsyncMode=l;exports.ConcurrentMode=m;exports.ContextConsumer=k;exports.ContextProvider=h;exports.Element=c;exports.ForwardRef=n;exports.Fragment=e;exports.Lazy=t;exports.Memo=r;exports.Portal=d;\nexports.Profiler=g;exports.StrictMode=f;exports.Suspense=p;exports.isAsyncMode=function(a){return A(a)||z(a)===l};exports.isConcurrentMode=A;exports.isContextConsumer=function(a){return z(a)===k};exports.isContextProvider=function(a){return z(a)===h};exports.isElement=function(a){return\"object\"===typeof a&&null!==a&&a.$$typeof===c};exports.isForwardRef=function(a){return z(a)===n};exports.isFragment=function(a){return z(a)===e};exports.isLazy=function(a){return z(a)===t};\nexports.isMemo=function(a){return z(a)===r};exports.isPortal=function(a){return z(a)===d};exports.isProfiler=function(a){return z(a)===g};exports.isStrictMode=function(a){return z(a)===f};exports.isSuspense=function(a){return z(a)===p};\nexports.isValidElementType=function(a){return\"string\"===typeof a||\"function\"===typeof a||a===e||a===m||a===g||a===f||a===p||a===q||\"object\"===typeof a&&null!==a&&(a.$$typeof===t||a.$$typeof===r||a.$$typeof===h||a.$$typeof===k||a.$$typeof===n||a.$$typeof===w||a.$$typeof===x||a.$$typeof===y||a.$$typeof===v)};exports.typeOf=z;\n","/** @license React v16.13.1\n * react-is.development.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\n\n\nif (process.env.NODE_ENV !== \"production\") {\n (function() {\n'use strict';\n\n// The Symbol used to tag the ReactElement-like types. If there is no native Symbol\n// nor polyfill, then a plain number is used for performance.\nvar hasSymbol = typeof Symbol === 'function' && Symbol.for;\nvar REACT_ELEMENT_TYPE = hasSymbol ? Symbol.for('react.element') : 0xeac7;\nvar REACT_PORTAL_TYPE = hasSymbol ? Symbol.for('react.portal') : 0xeaca;\nvar REACT_FRAGMENT_TYPE = hasSymbol ? Symbol.for('react.fragment') : 0xeacb;\nvar REACT_STRICT_MODE_TYPE = hasSymbol ? Symbol.for('react.strict_mode') : 0xeacc;\nvar REACT_PROFILER_TYPE = hasSymbol ? Symbol.for('react.profiler') : 0xead2;\nvar REACT_PROVIDER_TYPE = hasSymbol ? Symbol.for('react.provider') : 0xeacd;\nvar REACT_CONTEXT_TYPE = hasSymbol ? Symbol.for('react.context') : 0xeace; // TODO: We don't use AsyncMode or ConcurrentMode anymore. They were temporary\n// (unstable) APIs that have been removed. Can we remove the symbols?\n\nvar REACT_ASYNC_MODE_TYPE = hasSymbol ? Symbol.for('react.async_mode') : 0xeacf;\nvar REACT_CONCURRENT_MODE_TYPE = hasSymbol ? Symbol.for('react.concurrent_mode') : 0xeacf;\nvar REACT_FORWARD_REF_TYPE = hasSymbol ? Symbol.for('react.forward_ref') : 0xead0;\nvar REACT_SUSPENSE_TYPE = hasSymbol ? Symbol.for('react.suspense') : 0xead1;\nvar REACT_SUSPENSE_LIST_TYPE = hasSymbol ? Symbol.for('react.suspense_list') : 0xead8;\nvar REACT_MEMO_TYPE = hasSymbol ? Symbol.for('react.memo') : 0xead3;\nvar REACT_LAZY_TYPE = hasSymbol ? Symbol.for('react.lazy') : 0xead4;\nvar REACT_BLOCK_TYPE = hasSymbol ? Symbol.for('react.block') : 0xead9;\nvar REACT_FUNDAMENTAL_TYPE = hasSymbol ? Symbol.for('react.fundamental') : 0xead5;\nvar REACT_RESPONDER_TYPE = hasSymbol ? Symbol.for('react.responder') : 0xead6;\nvar REACT_SCOPE_TYPE = hasSymbol ? Symbol.for('react.scope') : 0xead7;\n\nfunction isValidElementType(type) {\n return typeof type === 'string' || typeof type === 'function' || // Note: its typeof might be other than 'symbol' or 'number' if it's a polyfill.\n type === REACT_FRAGMENT_TYPE || type === REACT_CONCURRENT_MODE_TYPE || type === REACT_PROFILER_TYPE || type === REACT_STRICT_MODE_TYPE || type === REACT_SUSPENSE_TYPE || type === REACT_SUSPENSE_LIST_TYPE || typeof type === 'object' && type !== null && (type.$$typeof === REACT_LAZY_TYPE || type.$$typeof === REACT_MEMO_TYPE || type.$$typeof === REACT_PROVIDER_TYPE || type.$$typeof === REACT_CONTEXT_TYPE || type.$$typeof === REACT_FORWARD_REF_TYPE || type.$$typeof === REACT_FUNDAMENTAL_TYPE || type.$$typeof === REACT_RESPONDER_TYPE || type.$$typeof === REACT_SCOPE_TYPE || type.$$typeof === REACT_BLOCK_TYPE);\n}\n\nfunction typeOf(object) {\n if (typeof object === 'object' && object !== null) {\n var $$typeof = object.$$typeof;\n\n switch ($$typeof) {\n case REACT_ELEMENT_TYPE:\n var type = object.type;\n\n switch (type) {\n case REACT_ASYNC_MODE_TYPE:\n case REACT_CONCURRENT_MODE_TYPE:\n case REACT_FRAGMENT_TYPE:\n case REACT_PROFILER_TYPE:\n case REACT_STRICT_MODE_TYPE:\n case REACT_SUSPENSE_TYPE:\n return type;\n\n default:\n var $$typeofType = type && type.$$typeof;\n\n switch ($$typeofType) {\n case REACT_CONTEXT_TYPE:\n case REACT_FORWARD_REF_TYPE:\n case REACT_LAZY_TYPE:\n case REACT_MEMO_TYPE:\n case REACT_PROVIDER_TYPE:\n return $$typeofType;\n\n default:\n return $$typeof;\n }\n\n }\n\n case REACT_PORTAL_TYPE:\n return $$typeof;\n }\n }\n\n return undefined;\n} // AsyncMode is deprecated along with isAsyncMode\n\nvar AsyncMode = REACT_ASYNC_MODE_TYPE;\nvar ConcurrentMode = REACT_CONCURRENT_MODE_TYPE;\nvar ContextConsumer = REACT_CONTEXT_TYPE;\nvar ContextProvider = REACT_PROVIDER_TYPE;\nvar Element = REACT_ELEMENT_TYPE;\nvar ForwardRef = REACT_FORWARD_REF_TYPE;\nvar Fragment = REACT_FRAGMENT_TYPE;\nvar Lazy = REACT_LAZY_TYPE;\nvar Memo = REACT_MEMO_TYPE;\nvar Portal = REACT_PORTAL_TYPE;\nvar Profiler = REACT_PROFILER_TYPE;\nvar StrictMode = REACT_STRICT_MODE_TYPE;\nvar Suspense = REACT_SUSPENSE_TYPE;\nvar hasWarnedAboutDeprecatedIsAsyncMode = false; // AsyncMode should be deprecated\n\nfunction isAsyncMode(object) {\n {\n if (!hasWarnedAboutDeprecatedIsAsyncMode) {\n hasWarnedAboutDeprecatedIsAsyncMode = true; // Using console['warn'] to evade Babel and ESLint\n\n console['warn']('The ReactIs.isAsyncMode() alias has been deprecated, ' + 'and will be removed in React 17+. Update your code to use ' + 'ReactIs.isConcurrentMode() instead. It has the exact same API.');\n }\n }\n\n return isConcurrentMode(object) || typeOf(object) === REACT_ASYNC_MODE_TYPE;\n}\nfunction isConcurrentMode(object) {\n return typeOf(object) === REACT_CONCURRENT_MODE_TYPE;\n}\nfunction isContextConsumer(object) {\n return typeOf(object) === REACT_CONTEXT_TYPE;\n}\nfunction isContextProvider(object) {\n return typeOf(object) === REACT_PROVIDER_TYPE;\n}\nfunction isElement(object) {\n return typeof object === 'object' && object !== null && object.$$typeof === REACT_ELEMENT_TYPE;\n}\nfunction isForwardRef(object) {\n return typeOf(object) === REACT_FORWARD_REF_TYPE;\n}\nfunction isFragment(object) {\n return typeOf(object) === REACT_FRAGMENT_TYPE;\n}\nfunction isLazy(object) {\n return typeOf(object) === REACT_LAZY_TYPE;\n}\nfunction isMemo(object) {\n return typeOf(object) === REACT_MEMO_TYPE;\n}\nfunction isPortal(object) {\n return typeOf(object) === REACT_PORTAL_TYPE;\n}\nfunction isProfiler(object) {\n return typeOf(object) === REACT_PROFILER_TYPE;\n}\nfunction isStrictMode(object) {\n return typeOf(object) === REACT_STRICT_MODE_TYPE;\n}\nfunction isSuspense(object) {\n return typeOf(object) === REACT_SUSPENSE_TYPE;\n}\n\nexports.AsyncMode = AsyncMode;\nexports.ConcurrentMode = ConcurrentMode;\nexports.ContextConsumer = ContextConsumer;\nexports.ContextProvider = ContextProvider;\nexports.Element = Element;\nexports.ForwardRef = ForwardRef;\nexports.Fragment = Fragment;\nexports.Lazy = Lazy;\nexports.Memo = Memo;\nexports.Portal = Portal;\nexports.Profiler = Profiler;\nexports.StrictMode = StrictMode;\nexports.Suspense = Suspense;\nexports.isAsyncMode = isAsyncMode;\nexports.isConcurrentMode = isConcurrentMode;\nexports.isContextConsumer = isContextConsumer;\nexports.isContextProvider = isContextProvider;\nexports.isElement = isElement;\nexports.isForwardRef = isForwardRef;\nexports.isFragment = isFragment;\nexports.isLazy = isLazy;\nexports.isMemo = isMemo;\nexports.isPortal = isPortal;\nexports.isProfiler = isProfiler;\nexports.isStrictMode = isStrictMode;\nexports.isSuspense = isSuspense;\nexports.isValidElementType = isValidElementType;\nexports.typeOf = typeOf;\n })();\n}\n","'use strict';\n\nif (process.env.NODE_ENV === 'production') {\n module.exports = require('./cjs/react-is.production.min.js');\n} else {\n module.exports = require('./cjs/react-is.development.js');\n}\n","/*\nobject-assign\n(c) Sindre Sorhus\n@license MIT\n*/\n\n'use strict';\n/* eslint-disable no-unused-vars */\nvar getOwnPropertySymbols = Object.getOwnPropertySymbols;\nvar hasOwnProperty = Object.prototype.hasOwnProperty;\nvar propIsEnumerable = Object.prototype.propertyIsEnumerable;\n\nfunction toObject(val) {\n\tif (val === null || val === undefined) {\n\t\tthrow new TypeError('Object.assign cannot be called with null or undefined');\n\t}\n\n\treturn Object(val);\n}\n\nfunction shouldUseNative() {\n\ttry {\n\t\tif (!Object.assign) {\n\t\t\treturn false;\n\t\t}\n\n\t\t// Detect buggy property enumeration order in older V8 versions.\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=4118\n\t\tvar test1 = new String('abc'); // eslint-disable-line no-new-wrappers\n\t\ttest1[5] = 'de';\n\t\tif (Object.getOwnPropertyNames(test1)[0] === '5') {\n\t\t\treturn false;\n\t\t}\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=3056\n\t\tvar test2 = {};\n\t\tfor (var i = 0; i < 10; i++) {\n\t\t\ttest2['_' + String.fromCharCode(i)] = i;\n\t\t}\n\t\tvar order2 = Object.getOwnPropertyNames(test2).map(function (n) {\n\t\t\treturn test2[n];\n\t\t});\n\t\tif (order2.join('') !== '0123456789') {\n\t\t\treturn false;\n\t\t}\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=3056\n\t\tvar test3 = {};\n\t\t'abcdefghijklmnopqrst'.split('').forEach(function (letter) {\n\t\t\ttest3[letter] = letter;\n\t\t});\n\t\tif (Object.keys(Object.assign({}, test3)).join('') !==\n\t\t\t\t'abcdefghijklmnopqrst') {\n\t\t\treturn false;\n\t\t}\n\n\t\treturn true;\n\t} catch (err) {\n\t\t// We don't expect any of the above to throw, but better to be safe.\n\t\treturn false;\n\t}\n}\n\nmodule.exports = shouldUseNative() ? Object.assign : function (target, source) {\n\tvar from;\n\tvar to = toObject(target);\n\tvar symbols;\n\n\tfor (var s = 1; s < arguments.length; s++) {\n\t\tfrom = Object(arguments[s]);\n\n\t\tfor (var key in from) {\n\t\t\tif (hasOwnProperty.call(from, key)) {\n\t\t\t\tto[key] = from[key];\n\t\t\t}\n\t\t}\n\n\t\tif (getOwnPropertySymbols) {\n\t\t\tsymbols = getOwnPropertySymbols(from);\n\t\t\tfor (var i = 0; i < symbols.length; i++) {\n\t\t\t\tif (propIsEnumerable.call(from, symbols[i])) {\n\t\t\t\t\tto[symbols[i]] = from[symbols[i]];\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\n\treturn to;\n};\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar ReactPropTypesSecret = 'SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED';\n\nmodule.exports = ReactPropTypesSecret;\n","module.exports = Function.call.bind(Object.prototype.hasOwnProperty);\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar printWarning = function() {};\n\nif (process.env.NODE_ENV !== 'production') {\n var ReactPropTypesSecret = require('./lib/ReactPropTypesSecret');\n var loggedTypeFailures = {};\n var has = require('./lib/has');\n\n printWarning = function(text) {\n var message = 'Warning: ' + text;\n if (typeof console !== 'undefined') {\n console.error(message);\n }\n try {\n // --- Welcome to debugging React ---\n // This error was thrown as a convenience so that you can use this stack\n // to find the callsite that caused this warning to fire.\n throw new Error(message);\n } catch (x) { /**/ }\n };\n}\n\n/**\n * Assert that the values match with the type specs.\n * Error messages are memorized and will only be shown once.\n *\n * @param {object} typeSpecs Map of name to a ReactPropType\n * @param {object} values Runtime values that need to be type-checked\n * @param {string} location e.g. \"prop\", \"context\", \"child context\"\n * @param {string} componentName Name of the component for error messages.\n * @param {?Function} getStack Returns the component stack.\n * @private\n */\nfunction checkPropTypes(typeSpecs, values, location, componentName, getStack) {\n if (process.env.NODE_ENV !== 'production') {\n for (var typeSpecName in typeSpecs) {\n if (has(typeSpecs, typeSpecName)) {\n var error;\n // Prop type validation may throw. In case they do, we don't want to\n // fail the render phase where it didn't fail before. So we log it.\n // After these have been cleaned up, we'll let them throw.\n try {\n // This is intentionally an invariant that gets caught. It's the same\n // behavior as without this statement except with a better message.\n if (typeof typeSpecs[typeSpecName] !== 'function') {\n var err = Error(\n (componentName || 'React class') + ': ' + location + ' type `' + typeSpecName + '` is invalid; ' +\n 'it must be a function, usually from the `prop-types` package, but received `' + typeof typeSpecs[typeSpecName] + '`.' +\n 'This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.'\n );\n err.name = 'Invariant Violation';\n throw err;\n }\n error = typeSpecs[typeSpecName](values, typeSpecName, componentName, location, null, ReactPropTypesSecret);\n } catch (ex) {\n error = ex;\n }\n if (error && !(error instanceof Error)) {\n printWarning(\n (componentName || 'React class') + ': type specification of ' +\n location + ' `' + typeSpecName + '` is invalid; the type checker ' +\n 'function must return `null` or an `Error` but returned a ' + typeof error + '. ' +\n 'You may have forgotten to pass an argument to the type checker ' +\n 'creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and ' +\n 'shape all require an argument).'\n );\n }\n if (error instanceof Error && !(error.message in loggedTypeFailures)) {\n // Only monitor this failure once because there tends to be a lot of the\n // same error.\n loggedTypeFailures[error.message] = true;\n\n var stack = getStack ? getStack() : '';\n\n printWarning(\n 'Failed ' + location + ' type: ' + error.message + (stack != null ? stack : '')\n );\n }\n }\n }\n }\n}\n\n/**\n * Resets warning cache when testing.\n *\n * @private\n */\ncheckPropTypes.resetWarningCache = function() {\n if (process.env.NODE_ENV !== 'production') {\n loggedTypeFailures = {};\n }\n}\n\nmodule.exports = checkPropTypes;\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar ReactIs = require('react-is');\nvar assign = require('object-assign');\n\nvar ReactPropTypesSecret = require('./lib/ReactPropTypesSecret');\nvar has = require('./lib/has');\nvar checkPropTypes = require('./checkPropTypes');\n\nvar printWarning = function() {};\n\nif (process.env.NODE_ENV !== 'production') {\n printWarning = function(text) {\n var message = 'Warning: ' + text;\n if (typeof console !== 'undefined') {\n console.error(message);\n }\n try {\n // --- Welcome to debugging React ---\n // This error was thrown as a convenience so that you can use this stack\n // to find the callsite that caused this warning to fire.\n throw new Error(message);\n } catch (x) {}\n };\n}\n\nfunction emptyFunctionThatReturnsNull() {\n return null;\n}\n\nmodule.exports = function(isValidElement, throwOnDirectAccess) {\n /* global Symbol */\n var ITERATOR_SYMBOL = typeof Symbol === 'function' && Symbol.iterator;\n var FAUX_ITERATOR_SYMBOL = '@@iterator'; // Before Symbol spec.\n\n /**\n * Returns the iterator method function contained on the iterable object.\n *\n * Be sure to invoke the function with the iterable as context:\n *\n * var iteratorFn = getIteratorFn(myIterable);\n * if (iteratorFn) {\n * var iterator = iteratorFn.call(myIterable);\n * ...\n * }\n *\n * @param {?object} maybeIterable\n * @return {?function}\n */\n function getIteratorFn(maybeIterable) {\n var iteratorFn = maybeIterable && (ITERATOR_SYMBOL && maybeIterable[ITERATOR_SYMBOL] || maybeIterable[FAUX_ITERATOR_SYMBOL]);\n if (typeof iteratorFn === 'function') {\n return iteratorFn;\n }\n }\n\n /**\n * Collection of methods that allow declaration and validation of props that are\n * supplied to React components. Example usage:\n *\n * var Props = require('ReactPropTypes');\n * var MyArticle = React.createClass({\n * propTypes: {\n * // An optional string prop named \"description\".\n * description: Props.string,\n *\n * // A required enum prop named \"category\".\n * category: Props.oneOf(['News','Photos']).isRequired,\n *\n * // A prop named \"dialog\" that requires an instance of Dialog.\n * dialog: Props.instanceOf(Dialog).isRequired\n * },\n * render: function() { ... }\n * });\n *\n * A more formal specification of how these methods are used:\n *\n * type := array|bool|func|object|number|string|oneOf([...])|instanceOf(...)\n * decl := ReactPropTypes.{type}(.isRequired)?\n *\n * Each and every declaration produces a function with the same signature. This\n * allows the creation of custom validation functions. For example:\n *\n * var MyLink = React.createClass({\n * propTypes: {\n * // An optional string or URI prop named \"href\".\n * href: function(props, propName, componentName) {\n * var propValue = props[propName];\n * if (propValue != null && typeof propValue !== 'string' &&\n * !(propValue instanceof URI)) {\n * return new Error(\n * 'Expected a string or an URI for ' + propName + ' in ' +\n * componentName\n * );\n * }\n * }\n * },\n * render: function() {...}\n * });\n *\n * @internal\n */\n\n var ANONYMOUS = '<>';\n\n // Important!\n // Keep this list in sync with production version in `./factoryWithThrowingShims.js`.\n var ReactPropTypes = {\n array: createPrimitiveTypeChecker('array'),\n bigint: createPrimitiveTypeChecker('bigint'),\n bool: createPrimitiveTypeChecker('boolean'),\n func: createPrimitiveTypeChecker('function'),\n number: createPrimitiveTypeChecker('number'),\n object: createPrimitiveTypeChecker('object'),\n string: createPrimitiveTypeChecker('string'),\n symbol: createPrimitiveTypeChecker('symbol'),\n\n any: createAnyTypeChecker(),\n arrayOf: createArrayOfTypeChecker,\n element: createElementTypeChecker(),\n elementType: createElementTypeTypeChecker(),\n instanceOf: createInstanceTypeChecker,\n node: createNodeChecker(),\n objectOf: createObjectOfTypeChecker,\n oneOf: createEnumTypeChecker,\n oneOfType: createUnionTypeChecker,\n shape: createShapeTypeChecker,\n exact: createStrictShapeTypeChecker,\n };\n\n /**\n * inlined Object.is polyfill to avoid requiring consumers ship their own\n * https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object/is\n */\n /*eslint-disable no-self-compare*/\n function is(x, y) {\n // SameValue algorithm\n if (x === y) {\n // Steps 1-5, 7-10\n // Steps 6.b-6.e: +0 != -0\n return x !== 0 || 1 / x === 1 / y;\n } else {\n // Step 6.a: NaN == NaN\n return x !== x && y !== y;\n }\n }\n /*eslint-enable no-self-compare*/\n\n /**\n * We use an Error-like object for backward compatibility as people may call\n * PropTypes directly and inspect their output. However, we don't use real\n * Errors anymore. We don't inspect their stack anyway, and creating them\n * is prohibitively expensive if they are created too often, such as what\n * happens in oneOfType() for any type before the one that matched.\n */\n function PropTypeError(message, data) {\n this.message = message;\n this.data = data && typeof data === 'object' ? data: {};\n this.stack = '';\n }\n // Make `instanceof Error` still work for returned errors.\n PropTypeError.prototype = Error.prototype;\n\n function createChainableTypeChecker(validate) {\n if (process.env.NODE_ENV !== 'production') {\n var manualPropTypeCallCache = {};\n var manualPropTypeWarningCount = 0;\n }\n function checkType(isRequired, props, propName, componentName, location, propFullName, secret) {\n componentName = componentName || ANONYMOUS;\n propFullName = propFullName || propName;\n\n if (secret !== ReactPropTypesSecret) {\n if (throwOnDirectAccess) {\n // New behavior only for users of `prop-types` package\n var err = new Error(\n 'Calling PropTypes validators directly is not supported by the `prop-types` package. ' +\n 'Use `PropTypes.checkPropTypes()` to call them. ' +\n 'Read more at http://fb.me/use-check-prop-types'\n );\n err.name = 'Invariant Violation';\n throw err;\n } else if (process.env.NODE_ENV !== 'production' && typeof console !== 'undefined') {\n // Old behavior for people using React.PropTypes\n var cacheKey = componentName + ':' + propName;\n if (\n !manualPropTypeCallCache[cacheKey] &&\n // Avoid spamming the console because they are often not actionable except for lib authors\n manualPropTypeWarningCount < 3\n ) {\n printWarning(\n 'You are manually calling a React.PropTypes validation ' +\n 'function for the `' + propFullName + '` prop on `' + componentName + '`. This is deprecated ' +\n 'and will throw in the standalone `prop-types` package. ' +\n 'You may be seeing this warning due to a third-party PropTypes ' +\n 'library. See https://fb.me/react-warning-dont-call-proptypes ' + 'for details.'\n );\n manualPropTypeCallCache[cacheKey] = true;\n manualPropTypeWarningCount++;\n }\n }\n }\n if (props[propName] == null) {\n if (isRequired) {\n if (props[propName] === null) {\n return new PropTypeError('The ' + location + ' `' + propFullName + '` is marked as required ' + ('in `' + componentName + '`, but its value is `null`.'));\n }\n return new PropTypeError('The ' + location + ' `' + propFullName + '` is marked as required in ' + ('`' + componentName + '`, but its value is `undefined`.'));\n }\n return null;\n } else {\n return validate(props, propName, componentName, location, propFullName);\n }\n }\n\n var chainedCheckType = checkType.bind(null, false);\n chainedCheckType.isRequired = checkType.bind(null, true);\n\n return chainedCheckType;\n }\n\n function createPrimitiveTypeChecker(expectedType) {\n function validate(props, propName, componentName, location, propFullName, secret) {\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== expectedType) {\n // `propValue` being instance of, say, date/regexp, pass the 'object'\n // check, but we can offer a more precise error message here rather than\n // 'of type `object`'.\n var preciseType = getPreciseType(propValue);\n\n return new PropTypeError(\n 'Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + preciseType + '` supplied to `' + componentName + '`, expected ') + ('`' + expectedType + '`.'),\n {expectedType: expectedType}\n );\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createAnyTypeChecker() {\n return createChainableTypeChecker(emptyFunctionThatReturnsNull);\n }\n\n function createArrayOfTypeChecker(typeChecker) {\n function validate(props, propName, componentName, location, propFullName) {\n if (typeof typeChecker !== 'function') {\n return new PropTypeError('Property `' + propFullName + '` of component `' + componentName + '` has invalid PropType notation inside arrayOf.');\n }\n var propValue = props[propName];\n if (!Array.isArray(propValue)) {\n var propType = getPropType(propValue);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected an array.'));\n }\n for (var i = 0; i < propValue.length; i++) {\n var error = typeChecker(propValue, i, componentName, location, propFullName + '[' + i + ']', ReactPropTypesSecret);\n if (error instanceof Error) {\n return error;\n }\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createElementTypeChecker() {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n if (!isValidElement(propValue)) {\n var propType = getPropType(propValue);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected a single ReactElement.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createElementTypeTypeChecker() {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n if (!ReactIs.isValidElementType(propValue)) {\n var propType = getPropType(propValue);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected a single ReactElement type.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createInstanceTypeChecker(expectedClass) {\n function validate(props, propName, componentName, location, propFullName) {\n if (!(props[propName] instanceof expectedClass)) {\n var expectedClassName = expectedClass.name || ANONYMOUS;\n var actualClassName = getClassName(props[propName]);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + actualClassName + '` supplied to `' + componentName + '`, expected ') + ('instance of `' + expectedClassName + '`.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createEnumTypeChecker(expectedValues) {\n if (!Array.isArray(expectedValues)) {\n if (process.env.NODE_ENV !== 'production') {\n if (arguments.length > 1) {\n printWarning(\n 'Invalid arguments supplied to oneOf, expected an array, got ' + arguments.length + ' arguments. ' +\n 'A common mistake is to write oneOf(x, y, z) instead of oneOf([x, y, z]).'\n );\n } else {\n printWarning('Invalid argument supplied to oneOf, expected an array.');\n }\n }\n return emptyFunctionThatReturnsNull;\n }\n\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n for (var i = 0; i < expectedValues.length; i++) {\n if (is(propValue, expectedValues[i])) {\n return null;\n }\n }\n\n var valuesString = JSON.stringify(expectedValues, function replacer(key, value) {\n var type = getPreciseType(value);\n if (type === 'symbol') {\n return String(value);\n }\n return value;\n });\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of value `' + String(propValue) + '` ' + ('supplied to `' + componentName + '`, expected one of ' + valuesString + '.'));\n }\n return createChainableTypeChecker(validate);\n }\n\n function createObjectOfTypeChecker(typeChecker) {\n function validate(props, propName, componentName, location, propFullName) {\n if (typeof typeChecker !== 'function') {\n return new PropTypeError('Property `' + propFullName + '` of component `' + componentName + '` has invalid PropType notation inside objectOf.');\n }\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== 'object') {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected an object.'));\n }\n for (var key in propValue) {\n if (has(propValue, key)) {\n var error = typeChecker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret);\n if (error instanceof Error) {\n return error;\n }\n }\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createUnionTypeChecker(arrayOfTypeCheckers) {\n if (!Array.isArray(arrayOfTypeCheckers)) {\n process.env.NODE_ENV !== 'production' ? printWarning('Invalid argument supplied to oneOfType, expected an instance of array.') : void 0;\n return emptyFunctionThatReturnsNull;\n }\n\n for (var i = 0; i < arrayOfTypeCheckers.length; i++) {\n var checker = arrayOfTypeCheckers[i];\n if (typeof checker !== 'function') {\n printWarning(\n 'Invalid argument supplied to oneOfType. Expected an array of check functions, but ' +\n 'received ' + getPostfixForTypeWarning(checker) + ' at index ' + i + '.'\n );\n return emptyFunctionThatReturnsNull;\n }\n }\n\n function validate(props, propName, componentName, location, propFullName) {\n var expectedTypes = [];\n for (var i = 0; i < arrayOfTypeCheckers.length; i++) {\n var checker = arrayOfTypeCheckers[i];\n var checkerResult = checker(props, propName, componentName, location, propFullName, ReactPropTypesSecret);\n if (checkerResult == null) {\n return null;\n }\n if (checkerResult.data && has(checkerResult.data, 'expectedType')) {\n expectedTypes.push(checkerResult.data.expectedType);\n }\n }\n var expectedTypesMessage = (expectedTypes.length > 0) ? ', expected one of type [' + expectedTypes.join(', ') + ']': '';\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` supplied to ' + ('`' + componentName + '`' + expectedTypesMessage + '.'));\n }\n return createChainableTypeChecker(validate);\n }\n\n function createNodeChecker() {\n function validate(props, propName, componentName, location, propFullName) {\n if (!isNode(props[propName])) {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` supplied to ' + ('`' + componentName + '`, expected a ReactNode.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function invalidValidatorError(componentName, location, propFullName, key, type) {\n return new PropTypeError(\n (componentName || 'React class') + ': ' + location + ' type `' + propFullName + '.' + key + '` is invalid; ' +\n 'it must be a function, usually from the `prop-types` package, but received `' + type + '`.'\n );\n }\n\n function createShapeTypeChecker(shapeTypes) {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== 'object') {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type `' + propType + '` ' + ('supplied to `' + componentName + '`, expected `object`.'));\n }\n for (var key in shapeTypes) {\n var checker = shapeTypes[key];\n if (typeof checker !== 'function') {\n return invalidValidatorError(componentName, location, propFullName, key, getPreciseType(checker));\n }\n var error = checker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret);\n if (error) {\n return error;\n }\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createStrictShapeTypeChecker(shapeTypes) {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== 'object') {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type `' + propType + '` ' + ('supplied to `' + componentName + '`, expected `object`.'));\n }\n // We need to check all keys in case some are required but missing from props.\n var allKeys = assign({}, props[propName], shapeTypes);\n for (var key in allKeys) {\n var checker = shapeTypes[key];\n if (has(shapeTypes, key) && typeof checker !== 'function') {\n return invalidValidatorError(componentName, location, propFullName, key, getPreciseType(checker));\n }\n if (!checker) {\n return new PropTypeError(\n 'Invalid ' + location + ' `' + propFullName + '` key `' + key + '` supplied to `' + componentName + '`.' +\n '\\nBad object: ' + JSON.stringify(props[propName], null, ' ') +\n '\\nValid keys: ' + JSON.stringify(Object.keys(shapeTypes), null, ' ')\n );\n }\n var error = checker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret);\n if (error) {\n return error;\n }\n }\n return null;\n }\n\n return createChainableTypeChecker(validate);\n }\n\n function isNode(propValue) {\n switch (typeof propValue) {\n case 'number':\n case 'string':\n case 'undefined':\n return true;\n case 'boolean':\n return !propValue;\n case 'object':\n if (Array.isArray(propValue)) {\n return propValue.every(isNode);\n }\n if (propValue === null || isValidElement(propValue)) {\n return true;\n }\n\n var iteratorFn = getIteratorFn(propValue);\n if (iteratorFn) {\n var iterator = iteratorFn.call(propValue);\n var step;\n if (iteratorFn !== propValue.entries) {\n while (!(step = iterator.next()).done) {\n if (!isNode(step.value)) {\n return false;\n }\n }\n } else {\n // Iterator will provide entry [k,v] tuples rather than values.\n while (!(step = iterator.next()).done) {\n var entry = step.value;\n if (entry) {\n if (!isNode(entry[1])) {\n return false;\n }\n }\n }\n }\n } else {\n return false;\n }\n\n return true;\n default:\n return false;\n }\n }\n\n function isSymbol(propType, propValue) {\n // Native Symbol.\n if (propType === 'symbol') {\n return true;\n }\n\n // falsy value can't be a Symbol\n if (!propValue) {\n return false;\n }\n\n // 19.4.3.5 Symbol.prototype[@@toStringTag] === 'Symbol'\n if (propValue['@@toStringTag'] === 'Symbol') {\n return true;\n }\n\n // Fallback for non-spec compliant Symbols which are polyfilled.\n if (typeof Symbol === 'function' && propValue instanceof Symbol) {\n return true;\n }\n\n return false;\n }\n\n // Equivalent of `typeof` but with special handling for array and regexp.\n function getPropType(propValue) {\n var propType = typeof propValue;\n if (Array.isArray(propValue)) {\n return 'array';\n }\n if (propValue instanceof RegExp) {\n // Old webkits (at least until Android 4.0) return 'function' rather than\n // 'object' for typeof a RegExp. We'll normalize this here so that /bla/\n // passes PropTypes.object.\n return 'object';\n }\n if (isSymbol(propType, propValue)) {\n return 'symbol';\n }\n return propType;\n }\n\n // This handles more types than `getPropType`. Only used for error messages.\n // See `createPrimitiveTypeChecker`.\n function getPreciseType(propValue) {\n if (typeof propValue === 'undefined' || propValue === null) {\n return '' + propValue;\n }\n var propType = getPropType(propValue);\n if (propType === 'object') {\n if (propValue instanceof Date) {\n return 'date';\n } else if (propValue instanceof RegExp) {\n return 'regexp';\n }\n }\n return propType;\n }\n\n // Returns a string that is postfixed to a warning about an invalid type.\n // For example, \"undefined\" or \"of type array\"\n function getPostfixForTypeWarning(value) {\n var type = getPreciseType(value);\n switch (type) {\n case 'array':\n case 'object':\n return 'an ' + type;\n case 'boolean':\n case 'date':\n case 'regexp':\n return 'a ' + type;\n default:\n return type;\n }\n }\n\n // Returns class name of the object, if any.\n function getClassName(propValue) {\n if (!propValue.constructor || !propValue.constructor.name) {\n return ANONYMOUS;\n }\n return propValue.constructor.name;\n }\n\n ReactPropTypes.checkPropTypes = checkPropTypes;\n ReactPropTypes.resetWarningCache = checkPropTypes.resetWarningCache;\n ReactPropTypes.PropTypes = ReactPropTypes;\n\n return ReactPropTypes;\n};\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar ReactPropTypesSecret = require('./lib/ReactPropTypesSecret');\n\nfunction emptyFunction() {}\nfunction emptyFunctionWithReset() {}\nemptyFunctionWithReset.resetWarningCache = emptyFunction;\n\nmodule.exports = function() {\n function shim(props, propName, componentName, location, propFullName, secret) {\n if (secret === ReactPropTypesSecret) {\n // It is still safe when called from React.\n return;\n }\n var err = new Error(\n 'Calling PropTypes validators directly is not supported by the `prop-types` package. ' +\n 'Use PropTypes.checkPropTypes() to call them. ' +\n 'Read more at http://fb.me/use-check-prop-types'\n );\n err.name = 'Invariant Violation';\n throw err;\n };\n shim.isRequired = shim;\n function getShim() {\n return shim;\n };\n // Important!\n // Keep this list in sync with production version in `./factoryWithTypeCheckers.js`.\n var ReactPropTypes = {\n array: shim,\n bigint: shim,\n bool: shim,\n func: shim,\n number: shim,\n object: shim,\n string: shim,\n symbol: shim,\n\n any: shim,\n arrayOf: getShim,\n element: shim,\n elementType: shim,\n instanceOf: getShim,\n node: shim,\n objectOf: getShim,\n oneOf: getShim,\n oneOfType: getShim,\n shape: getShim,\n exact: getShim,\n\n checkPropTypes: emptyFunctionWithReset,\n resetWarningCache: emptyFunction\n };\n\n ReactPropTypes.PropTypes = ReactPropTypes;\n\n return ReactPropTypes;\n};\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\nif (process.env.NODE_ENV !== 'production') {\n var ReactIs = require('react-is');\n\n // By explicitly using `prop-types` you are opting into new development behavior.\n // http://fb.me/prop-types-in-prod\n var throwOnDirectAccess = true;\n module.exports = require('./factoryWithTypeCheckers')(ReactIs.isElement, throwOnDirectAccess);\n} else {\n // By explicitly using `prop-types` you are opting into new production behavior.\n // http://fb.me/prop-types-in-prod\n module.exports = require('./factoryWithThrowingShims')();\n}\n","import PropTypes from 'prop-types';\nimport chainPropTypes from '../chainPropTypes';\nfunction isClassComponent(elementType) {\n // elementType.prototype?.isReactComponent\n const {\n prototype = {}\n } = elementType;\n return Boolean(prototype.isReactComponent);\n}\nfunction acceptingRef(props, propName, componentName, location, propFullName) {\n const element = props[propName];\n const safePropName = propFullName || propName;\n if (element == null ||\n // When server-side rendering React doesn't warn either.\n // This is not an accurate check for SSR.\n // This is only in place for Emotion compat.\n // TODO: Revisit once https://github.com/facebook/react/issues/20047 is resolved.\n typeof window === 'undefined') {\n return null;\n }\n let warningHint;\n const elementType = element.type;\n /**\n * Blacklisting instead of whitelisting\n *\n * Blacklisting will miss some components, such as React.Fragment. Those will at least\n * trigger a warning in React.\n * We can't whitelist because there is no safe way to detect React.forwardRef\n * or class components. \"Safe\" means there's no public API.\n *\n */\n if (typeof elementType === 'function' && !isClassComponent(elementType)) {\n warningHint = 'Did you accidentally use a plain function component for an element instead?';\n }\n if (warningHint !== undefined) {\n return new Error(`Invalid ${location} \\`${safePropName}\\` supplied to \\`${componentName}\\`. ` + `Expected an element that can hold a ref. ${warningHint} ` + 'For more information see https://mui.com/r/caveat-with-refs-guide');\n }\n return null;\n}\nconst elementAcceptingRef = chainPropTypes(PropTypes.element, acceptingRef);\nelementAcceptingRef.isRequired = chainPropTypes(PropTypes.element.isRequired, acceptingRef);\nexport default elementAcceptingRef;","import _extends from \"@babel/runtime/helpers/esm/extends\";\n// This module is based on https://github.com/airbnb/prop-types-exact repository.\n// However, in order to reduce the number of dependencies and to remove some extra safe checks\n// the module was forked.\n\nconst specialProperty = 'exact-prop: \\u200b';\nexport default function exactProp(propTypes) {\n if (process.env.NODE_ENV === 'production') {\n return propTypes;\n }\n return _extends({}, propTypes, {\n [specialProperty]: props => {\n const unsupportedProps = Object.keys(props).filter(prop => !propTypes.hasOwnProperty(prop));\n if (unsupportedProps.length > 0) {\n return new Error(`The following props are not supported: ${unsupportedProps.map(prop => `\\`${prop}\\``).join(', ')}. Please remove them.`);\n }\n return null;\n }\n });\n}","/**\n * WARNING: Don't import this directly.\n * Use `MuiError` from `@mui/internal-babel-macros/MuiError.macro` instead.\n * @param {number} code\n */\nexport default function formatMuiErrorMessage(code) {\n // Apply babel-plugin-transform-template-literals in loose mode\n // loose mode is safe if we're concatenating primitives\n // see https://babeljs.io/docs/en/babel-plugin-transform-template-literals#loose\n /* eslint-disable prefer-template */\n let url = 'https://mui.com/production-error/?code=' + code;\n for (let i = 1; i < arguments.length; i += 1) {\n // rest params over-transpile for this case\n // eslint-disable-next-line prefer-rest-params\n url += '&args[]=' + encodeURIComponent(arguments[i]);\n }\n return 'Minified MUI error #' + code + '; visit ' + url + ' for the full message.';\n /* eslint-enable prefer-template */\n}","/**\n * @license React\n * react-is.production.min.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n'use strict';var b=Symbol.for(\"react.element\"),c=Symbol.for(\"react.portal\"),d=Symbol.for(\"react.fragment\"),e=Symbol.for(\"react.strict_mode\"),f=Symbol.for(\"react.profiler\"),g=Symbol.for(\"react.provider\"),h=Symbol.for(\"react.context\"),k=Symbol.for(\"react.server_context\"),l=Symbol.for(\"react.forward_ref\"),m=Symbol.for(\"react.suspense\"),n=Symbol.for(\"react.suspense_list\"),p=Symbol.for(\"react.memo\"),q=Symbol.for(\"react.lazy\"),t=Symbol.for(\"react.offscreen\"),u;u=Symbol.for(\"react.module.reference\");\nfunction v(a){if(\"object\"===typeof a&&null!==a){var r=a.$$typeof;switch(r){case b:switch(a=a.type,a){case d:case f:case e:case m:case n:return a;default:switch(a=a&&a.$$typeof,a){case k:case h:case l:case q:case p:case g:return a;default:return r}}case c:return r}}}exports.ContextConsumer=h;exports.ContextProvider=g;exports.Element=b;exports.ForwardRef=l;exports.Fragment=d;exports.Lazy=q;exports.Memo=p;exports.Portal=c;exports.Profiler=f;exports.StrictMode=e;exports.Suspense=m;\nexports.SuspenseList=n;exports.isAsyncMode=function(){return!1};exports.isConcurrentMode=function(){return!1};exports.isContextConsumer=function(a){return v(a)===h};exports.isContextProvider=function(a){return v(a)===g};exports.isElement=function(a){return\"object\"===typeof a&&null!==a&&a.$$typeof===b};exports.isForwardRef=function(a){return v(a)===l};exports.isFragment=function(a){return v(a)===d};exports.isLazy=function(a){return v(a)===q};exports.isMemo=function(a){return v(a)===p};\nexports.isPortal=function(a){return v(a)===c};exports.isProfiler=function(a){return v(a)===f};exports.isStrictMode=function(a){return v(a)===e};exports.isSuspense=function(a){return v(a)===m};exports.isSuspenseList=function(a){return v(a)===n};\nexports.isValidElementType=function(a){return\"string\"===typeof a||\"function\"===typeof a||a===d||a===f||a===e||a===m||a===n||a===t||\"object\"===typeof a&&null!==a&&(a.$$typeof===q||a.$$typeof===p||a.$$typeof===g||a.$$typeof===h||a.$$typeof===l||a.$$typeof===u||void 0!==a.getModuleId)?!0:!1};exports.typeOf=v;\n","/**\n * @license React\n * react-is.development.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nif (process.env.NODE_ENV !== \"production\") {\n (function() {\n'use strict';\n\n// ATTENTION\n// When adding new symbols to this file,\n// Please consider also adding to 'react-devtools-shared/src/backend/ReactSymbols'\n// The Symbol used to tag the ReactElement-like types.\nvar REACT_ELEMENT_TYPE = Symbol.for('react.element');\nvar REACT_PORTAL_TYPE = Symbol.for('react.portal');\nvar REACT_FRAGMENT_TYPE = Symbol.for('react.fragment');\nvar REACT_STRICT_MODE_TYPE = Symbol.for('react.strict_mode');\nvar REACT_PROFILER_TYPE = Symbol.for('react.profiler');\nvar REACT_PROVIDER_TYPE = Symbol.for('react.provider');\nvar REACT_CONTEXT_TYPE = Symbol.for('react.context');\nvar REACT_SERVER_CONTEXT_TYPE = Symbol.for('react.server_context');\nvar REACT_FORWARD_REF_TYPE = Symbol.for('react.forward_ref');\nvar REACT_SUSPENSE_TYPE = Symbol.for('react.suspense');\nvar REACT_SUSPENSE_LIST_TYPE = Symbol.for('react.suspense_list');\nvar REACT_MEMO_TYPE = Symbol.for('react.memo');\nvar REACT_LAZY_TYPE = Symbol.for('react.lazy');\nvar REACT_OFFSCREEN_TYPE = Symbol.for('react.offscreen');\n\n// -----------------------------------------------------------------------------\n\nvar enableScopeAPI = false; // Experimental Create Event Handle API.\nvar enableCacheElement = false;\nvar enableTransitionTracing = false; // No known bugs, but needs performance testing\n\nvar enableLegacyHidden = false; // Enables unstable_avoidThisFallback feature in Fiber\n// stuff. Intended to enable React core members to more easily debug scheduling\n// issues in DEV builds.\n\nvar enableDebugTracing = false; // Track which Fiber(s) schedule render work.\n\nvar REACT_MODULE_REFERENCE;\n\n{\n REACT_MODULE_REFERENCE = Symbol.for('react.module.reference');\n}\n\nfunction isValidElementType(type) {\n if (typeof type === 'string' || typeof type === 'function') {\n return true;\n } // Note: typeof might be other than 'symbol' or 'number' (e.g. if it's a polyfill).\n\n\n if (type === REACT_FRAGMENT_TYPE || type === REACT_PROFILER_TYPE || enableDebugTracing || type === REACT_STRICT_MODE_TYPE || type === REACT_SUSPENSE_TYPE || type === REACT_SUSPENSE_LIST_TYPE || enableLegacyHidden || type === REACT_OFFSCREEN_TYPE || enableScopeAPI || enableCacheElement || enableTransitionTracing ) {\n return true;\n }\n\n if (typeof type === 'object' && type !== null) {\n if (type.$$typeof === REACT_LAZY_TYPE || type.$$typeof === REACT_MEMO_TYPE || type.$$typeof === REACT_PROVIDER_TYPE || type.$$typeof === REACT_CONTEXT_TYPE || type.$$typeof === REACT_FORWARD_REF_TYPE || // This needs to include all possible module reference object\n // types supported by any Flight configuration anywhere since\n // we don't know which Flight build this will end up being used\n // with.\n type.$$typeof === REACT_MODULE_REFERENCE || type.getModuleId !== undefined) {\n return true;\n }\n }\n\n return false;\n}\n\nfunction typeOf(object) {\n if (typeof object === 'object' && object !== null) {\n var $$typeof = object.$$typeof;\n\n switch ($$typeof) {\n case REACT_ELEMENT_TYPE:\n var type = object.type;\n\n switch (type) {\n case REACT_FRAGMENT_TYPE:\n case REACT_PROFILER_TYPE:\n case REACT_STRICT_MODE_TYPE:\n case REACT_SUSPENSE_TYPE:\n case REACT_SUSPENSE_LIST_TYPE:\n return type;\n\n default:\n var $$typeofType = type && type.$$typeof;\n\n switch ($$typeofType) {\n case REACT_SERVER_CONTEXT_TYPE:\n case REACT_CONTEXT_TYPE:\n case REACT_FORWARD_REF_TYPE:\n case REACT_LAZY_TYPE:\n case REACT_MEMO_TYPE:\n case REACT_PROVIDER_TYPE:\n return $$typeofType;\n\n default:\n return $$typeof;\n }\n\n }\n\n case REACT_PORTAL_TYPE:\n return $$typeof;\n }\n }\n\n return undefined;\n}\nvar ContextConsumer = REACT_CONTEXT_TYPE;\nvar ContextProvider = REACT_PROVIDER_TYPE;\nvar Element = REACT_ELEMENT_TYPE;\nvar ForwardRef = REACT_FORWARD_REF_TYPE;\nvar Fragment = REACT_FRAGMENT_TYPE;\nvar Lazy = REACT_LAZY_TYPE;\nvar Memo = REACT_MEMO_TYPE;\nvar Portal = REACT_PORTAL_TYPE;\nvar Profiler = REACT_PROFILER_TYPE;\nvar StrictMode = REACT_STRICT_MODE_TYPE;\nvar Suspense = REACT_SUSPENSE_TYPE;\nvar SuspenseList = REACT_SUSPENSE_LIST_TYPE;\nvar hasWarnedAboutDeprecatedIsAsyncMode = false;\nvar hasWarnedAboutDeprecatedIsConcurrentMode = false; // AsyncMode should be deprecated\n\nfunction isAsyncMode(object) {\n {\n if (!hasWarnedAboutDeprecatedIsAsyncMode) {\n hasWarnedAboutDeprecatedIsAsyncMode = true; // Using console['warn'] to evade Babel and ESLint\n\n console['warn']('The ReactIs.isAsyncMode() alias has been deprecated, ' + 'and will be removed in React 18+.');\n }\n }\n\n return false;\n}\nfunction isConcurrentMode(object) {\n {\n if (!hasWarnedAboutDeprecatedIsConcurrentMode) {\n hasWarnedAboutDeprecatedIsConcurrentMode = true; // Using console['warn'] to evade Babel and ESLint\n\n console['warn']('The ReactIs.isConcurrentMode() alias has been deprecated, ' + 'and will be removed in React 18+.');\n }\n }\n\n return false;\n}\nfunction isContextConsumer(object) {\n return typeOf(object) === REACT_CONTEXT_TYPE;\n}\nfunction isContextProvider(object) {\n return typeOf(object) === REACT_PROVIDER_TYPE;\n}\nfunction isElement(object) {\n return typeof object === 'object' && object !== null && object.$$typeof === REACT_ELEMENT_TYPE;\n}\nfunction isForwardRef(object) {\n return typeOf(object) === REACT_FORWARD_REF_TYPE;\n}\nfunction isFragment(object) {\n return typeOf(object) === REACT_FRAGMENT_TYPE;\n}\nfunction isLazy(object) {\n return typeOf(object) === REACT_LAZY_TYPE;\n}\nfunction isMemo(object) {\n return typeOf(object) === REACT_MEMO_TYPE;\n}\nfunction isPortal(object) {\n return typeOf(object) === REACT_PORTAL_TYPE;\n}\nfunction isProfiler(object) {\n return typeOf(object) === REACT_PROFILER_TYPE;\n}\nfunction isStrictMode(object) {\n return typeOf(object) === REACT_STRICT_MODE_TYPE;\n}\nfunction isSuspense(object) {\n return typeOf(object) === REACT_SUSPENSE_TYPE;\n}\nfunction isSuspenseList(object) {\n return typeOf(object) === REACT_SUSPENSE_LIST_TYPE;\n}\n\nexports.ContextConsumer = ContextConsumer;\nexports.ContextProvider = ContextProvider;\nexports.Element = Element;\nexports.ForwardRef = ForwardRef;\nexports.Fragment = Fragment;\nexports.Lazy = Lazy;\nexports.Memo = Memo;\nexports.Portal = Portal;\nexports.Profiler = Profiler;\nexports.StrictMode = StrictMode;\nexports.Suspense = Suspense;\nexports.SuspenseList = SuspenseList;\nexports.isAsyncMode = isAsyncMode;\nexports.isConcurrentMode = isConcurrentMode;\nexports.isContextConsumer = isContextConsumer;\nexports.isContextProvider = isContextProvider;\nexports.isElement = isElement;\nexports.isForwardRef = isForwardRef;\nexports.isFragment = isFragment;\nexports.isLazy = isLazy;\nexports.isMemo = isMemo;\nexports.isPortal = isPortal;\nexports.isProfiler = isProfiler;\nexports.isStrictMode = isStrictMode;\nexports.isSuspense = isSuspense;\nexports.isSuspenseList = isSuspenseList;\nexports.isValidElementType = isValidElementType;\nexports.typeOf = typeOf;\n })();\n}\n","'use strict';\n\nif (process.env.NODE_ENV === 'production') {\n module.exports = require('./cjs/react-is.production.min.js');\n} else {\n module.exports = require('./cjs/react-is.development.js');\n}\n","import { ForwardRef, Memo } from 'react-is';\n\n// Simplified polyfill for IE11 support\n// https://github.com/JamesMGreene/Function.name/blob/58b314d4a983110c3682f1228f845d39ccca1817/Function.name.js#L3\nconst fnNameMatchRegex = /^\\s*function(?:\\s|\\s*\\/\\*.*\\*\\/\\s*)+([^(\\s/]*)\\s*/;\nexport function getFunctionName(fn) {\n const match = `${fn}`.match(fnNameMatchRegex);\n const name = match && match[1];\n return name || '';\n}\nfunction getFunctionComponentName(Component, fallback = '') {\n return Component.displayName || Component.name || getFunctionName(Component) || fallback;\n}\nfunction getWrappedName(outerType, innerType, wrapperName) {\n const functionName = getFunctionComponentName(innerType);\n return outerType.displayName || (functionName !== '' ? `${wrapperName}(${functionName})` : wrapperName);\n}\n\n/**\n * cherry-pick from\n * https://github.com/facebook/react/blob/769b1f270e1251d9dbdce0fcbd9e92e502d059b8/packages/shared/getComponentName.js\n * originally forked from recompose/getDisplayName with added IE11 support\n */\nexport default function getDisplayName(Component) {\n if (Component == null) {\n return undefined;\n }\n if (typeof Component === 'string') {\n return Component;\n }\n if (typeof Component === 'function') {\n return getFunctionComponentName(Component, 'Component');\n }\n\n // TypeScript can't have components as objects but they exist in the form of `memo` or `Suspense`\n if (typeof Component === 'object') {\n switch (Component.$$typeof) {\n case ForwardRef:\n return getWrappedName(Component, Component.render, 'ForwardRef');\n case Memo:\n return getWrappedName(Component, Component.type, 'memo');\n default:\n return undefined;\n }\n }\n return undefined;\n}","export default function HTMLElementType(props, propName, componentName, location, propFullName) {\n if (process.env.NODE_ENV === 'production') {\n return null;\n }\n const propValue = props[propName];\n const safePropName = propFullName || propName;\n if (propValue == null) {\n return null;\n }\n if (propValue && propValue.nodeType !== 1) {\n return new Error(`Invalid ${location} \\`${safePropName}\\` supplied to \\`${componentName}\\`. ` + `Expected an HTMLElement.`);\n }\n return null;\n}","import PropTypes from 'prop-types';\nconst refType = PropTypes.oneOfType([PropTypes.func, PropTypes.object]);\nexport default refType;","import _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\n// It should to be noted that this function isn't equivalent to `text-transform: capitalize`.\n//\n// A strict capitalization should uppercase the first letter of each word in the sentence.\n// We only handle the first word.\nexport default function capitalize(string) {\n if (typeof string !== 'string') {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: \\`capitalize(string)\\` expects a string argument.` : _formatMuiErrorMessage(7));\n }\n return string.charAt(0).toUpperCase() + string.slice(1);\n}","/**\n * Safe chained function.\n *\n * Will only create a new function if needed,\n * otherwise will pass back existing functions or null.\n */\nexport default function createChainedFunction(...funcs) {\n return funcs.reduce((acc, func) => {\n if (func == null) {\n return acc;\n }\n return function chainedFunction(...args) {\n acc.apply(this, args);\n func.apply(this, args);\n };\n }, () => {});\n}","// Corresponds to 10 frames at 60 Hz.\n// A few bytes payload overhead when lodash/debounce is ~3 kB and debounce ~300 B.\nexport default function debounce(func, wait = 166) {\n let timeout;\n function debounced(...args) {\n const later = () => {\n // @ts-ignore\n func.apply(this, args);\n };\n clearTimeout(timeout);\n timeout = setTimeout(later, wait);\n }\n debounced.clear = () => {\n clearTimeout(timeout);\n };\n return debounced;\n}","export default function deprecatedPropType(validator, reason) {\n if (process.env.NODE_ENV === 'production') {\n return () => null;\n }\n return (props, propName, componentName, location, propFullName) => {\n const componentNameSafe = componentName || '<>';\n const propFullNameSafe = propFullName || propName;\n if (typeof props[propName] !== 'undefined') {\n return new Error(`The ${location} \\`${propFullNameSafe}\\` of ` + `\\`${componentNameSafe}\\` is deprecated. ${reason}`);\n }\n return null;\n };\n}","import * as React from 'react';\nexport default function isMuiElement(element, muiNames) {\n var _muiName, _element$type;\n return /*#__PURE__*/React.isValidElement(element) && muiNames.indexOf( // For server components `muiName` is avaialble in element.type._payload.value.muiName\n // relevant info - https://github.com/facebook/react/blob/2807d781a08db8e9873687fccc25c0f12b4fb3d4/packages/react/src/ReactLazy.js#L45\n // eslint-disable-next-line no-underscore-dangle\n (_muiName = element.type.muiName) != null ? _muiName : (_element$type = element.type) == null || (_element$type = _element$type._payload) == null || (_element$type = _element$type.value) == null ? void 0 : _element$type.muiName) !== -1;\n}","export default function ownerDocument(node) {\n return node && node.ownerDocument || document;\n}","import ownerDocument from '../ownerDocument';\nexport default function ownerWindow(node) {\n const doc = ownerDocument(node);\n return doc.defaultView || window;\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nexport default function requirePropFactory(componentNameInError, Component) {\n if (process.env.NODE_ENV === 'production') {\n return () => null;\n }\n\n // eslint-disable-next-line react/forbid-foreign-prop-types\n const prevPropTypes = Component ? _extends({}, Component.propTypes) : null;\n const requireProp = requiredProp => (props, propName, componentName, location, propFullName, ...args) => {\n const propFullNameSafe = propFullName || propName;\n const defaultTypeChecker = prevPropTypes == null ? void 0 : prevPropTypes[propFullNameSafe];\n if (defaultTypeChecker) {\n const typeCheckerResult = defaultTypeChecker(props, propName, componentName, location, propFullName, ...args);\n if (typeCheckerResult) {\n return typeCheckerResult;\n }\n }\n if (typeof props[propName] !== 'undefined' && !props[requiredProp]) {\n return new Error(`The prop \\`${propFullNameSafe}\\` of ` + `\\`${componentNameInError}\\` can only be used together with the \\`${requiredProp}\\` prop.`);\n }\n return null;\n };\n return requireProp;\n}","/**\n * TODO v5: consider making it private\n *\n * passes {value} to {ref}\n *\n * WARNING: Be sure to only call this inside a callback that is passed as a ref.\n * Otherwise, make sure to cleanup the previous {ref} if it changes. See\n * https://github.com/mui/material-ui/issues/13539\n *\n * Useful if you want to expose the ref of an inner component to the public API\n * while still using it inside the component.\n * @param ref A ref callback or ref object. If anything falsy, this is a no-op.\n */\nexport default function setRef(ref, value) {\n if (typeof ref === 'function') {\n ref(value);\n } else if (ref) {\n ref.current = value;\n }\n}","'use client';\n\nimport * as React from 'react';\n\n/**\n * A version of `React.useLayoutEffect` that does not show a warning when server-side rendering.\n * This is useful for effects that are only needed for client-side rendering but not for SSR.\n *\n * Before you use this hook, make sure to read https://gist.github.com/gaearon/e7d97cdf38a2907924ea12e4ebdf3c85\n * and confirm it doesn't apply to your use-case.\n */\nconst useEnhancedEffect = typeof window !== 'undefined' ? React.useLayoutEffect : React.useEffect;\nexport default useEnhancedEffect;","'use client';\n\nimport * as React from 'react';\nlet globalId = 0;\nfunction useGlobalId(idOverride) {\n const [defaultId, setDefaultId] = React.useState(idOverride);\n const id = idOverride || defaultId;\n React.useEffect(() => {\n if (defaultId == null) {\n // Fallback to this default id when possible.\n // Use the incrementing value for client-side rendering only.\n // We can't use it server-side.\n // If you want to use random values please consider the Birthday Problem: https://en.wikipedia.org/wiki/Birthday_problem\n globalId += 1;\n setDefaultId(`mui-${globalId}`);\n }\n }, [defaultId]);\n return id;\n}\n\n// downstream bundlers may remove unnecessary concatenation, but won't remove toString call -- Workaround for https://github.com/webpack/webpack/issues/14814\nconst maybeReactUseId = React['useId'.toString()];\n/**\n *\n * @example
    \n * @param idOverride\n * @returns {string}\n */\nexport default function useId(idOverride) {\n if (maybeReactUseId !== undefined) {\n const reactId = maybeReactUseId();\n return idOverride != null ? idOverride : reactId;\n }\n // eslint-disable-next-line react-hooks/rules-of-hooks -- `React.useId` is invariant at runtime.\n return useGlobalId(idOverride);\n}","export default function unsupportedProp(props, propName, componentName, location, propFullName) {\n if (process.env.NODE_ENV === 'production') {\n return null;\n }\n const propFullNameSafe = propFullName || propName;\n if (typeof props[propName] !== 'undefined') {\n return new Error(`The prop \\`${propFullNameSafe}\\` is not supported. Please remove it.`);\n }\n return null;\n}","'use client';\n\n/* eslint-disable react-hooks/rules-of-hooks, react-hooks/exhaustive-deps */\nimport * as React from 'react';\nexport default function useControlled({\n controlled,\n default: defaultProp,\n name,\n state = 'value'\n}) {\n // isControlled is ignored in the hook dependency lists as it should never change.\n const {\n current: isControlled\n } = React.useRef(controlled !== undefined);\n const [valueState, setValue] = React.useState(defaultProp);\n const value = isControlled ? controlled : valueState;\n if (process.env.NODE_ENV !== 'production') {\n React.useEffect(() => {\n if (isControlled !== (controlled !== undefined)) {\n console.error([`MUI: A component is changing the ${isControlled ? '' : 'un'}controlled ${state} state of ${name} to be ${isControlled ? 'un' : ''}controlled.`, 'Elements should not switch from uncontrolled to controlled (or vice versa).', `Decide between using a controlled or uncontrolled ${name} ` + 'element for the lifetime of the component.', \"The nature of the state is determined during the first render. It's considered controlled if the value is not `undefined`.\", 'More info: https://fb.me/react-controlled-components'].join('\\n'));\n }\n }, [state, name, controlled]);\n const {\n current: defaultValue\n } = React.useRef(defaultProp);\n React.useEffect(() => {\n if (!isControlled && defaultValue !== defaultProp) {\n console.error([`MUI: A component is changing the default ${state} state of an uncontrolled ${name} after being initialized. ` + `To suppress this warning opt to use a controlled ${name}.`].join('\\n'));\n }\n }, [JSON.stringify(defaultProp)]);\n }\n const setValueIfUncontrolled = React.useCallback(newValue => {\n if (!isControlled) {\n setValue(newValue);\n }\n }, []);\n return [value, setValueIfUncontrolled];\n}","'use client';\n\nimport * as React from 'react';\nimport useEnhancedEffect from '../useEnhancedEffect';\n\n/**\n * Inspired by https://github.com/facebook/react/issues/14099#issuecomment-440013892\n * See RFC in https://github.com/reactjs/rfcs/pull/220\n */\n\nfunction useEventCallback(fn) {\n const ref = React.useRef(fn);\n useEnhancedEffect(() => {\n ref.current = fn;\n });\n return React.useRef((...args) =>\n // @ts-expect-error hide `this`\n (0, ref.current)(...args)).current;\n}\nexport default useEventCallback;","'use client';\n\nimport * as React from 'react';\nimport setRef from '../setRef';\nexport default function useForkRef(...refs) {\n /**\n * This will create a new function if the refs passed to this hook change and are all defined.\n * This means react will call the old forkRef with `null` and the new forkRef\n * with the ref. Cleanup naturally emerges from this behavior.\n */\n return React.useMemo(() => {\n if (refs.every(ref => ref == null)) {\n return null;\n }\n return instance => {\n refs.forEach(ref => {\n setRef(ref, instance);\n });\n };\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, refs);\n}","'use client';\n\nimport * as React from 'react';\nconst UNINITIALIZED = {};\n\n/**\n * A React.useRef() that is initialized lazily with a function. Note that it accepts an optional\n * initialization argument, so the initialization function doesn't need to be an inline closure.\n *\n * @usage\n * const ref = useLazyRef(sortColumns, columns)\n */\nexport default function useLazyRef(init, initArg) {\n const ref = React.useRef(UNINITIALIZED);\n if (ref.current === UNINITIALIZED) {\n ref.current = init(initArg);\n }\n return ref;\n}","'use client';\n\nimport * as React from 'react';\nconst EMPTY = [];\n\n/**\n * A React.useEffect equivalent that runs once, when the component is mounted.\n */\nexport default function useOnMount(fn) {\n /* eslint-disable react-hooks/exhaustive-deps */\n React.useEffect(fn, EMPTY);\n /* eslint-enable react-hooks/exhaustive-deps */\n}","'use client';\n\nimport useLazyRef from '../useLazyRef/useLazyRef';\nimport useOnMount from '../useOnMount/useOnMount';\nexport class Timeout {\n constructor() {\n this.currentId = null;\n this.clear = () => {\n if (this.currentId !== null) {\n clearTimeout(this.currentId);\n this.currentId = null;\n }\n };\n this.disposeEffect = () => {\n return this.clear;\n };\n }\n static create() {\n return new Timeout();\n }\n /**\n * Executes `fn` after `delay`, clearing any previously scheduled call.\n */\n start(delay, fn) {\n this.clear();\n this.currentId = setTimeout(() => {\n this.currentId = null;\n fn();\n }, delay);\n }\n}\nexport default function useTimeout() {\n const timeout = useLazyRef(Timeout.create).current;\n useOnMount(timeout.disposeEffect);\n return timeout;\n}","'use client';\n\n// based on https://github.com/WICG/focus-visible/blob/v4.1.5/src/focus-visible.js\nimport * as React from 'react';\nimport { Timeout } from '../useTimeout/useTimeout';\nlet hadKeyboardEvent = true;\nlet hadFocusVisibleRecently = false;\nconst hadFocusVisibleRecentlyTimeout = new Timeout();\nconst inputTypesWhitelist = {\n text: true,\n search: true,\n url: true,\n tel: true,\n email: true,\n password: true,\n number: true,\n date: true,\n month: true,\n week: true,\n time: true,\n datetime: true,\n 'datetime-local': true\n};\n\n/**\n * Computes whether the given element should automatically trigger the\n * `focus-visible` class being added, i.e. whether it should always match\n * `:focus-visible` when focused.\n * @param {Element} node\n * @returns {boolean}\n */\nfunction focusTriggersKeyboardModality(node) {\n const {\n type,\n tagName\n } = node;\n if (tagName === 'INPUT' && inputTypesWhitelist[type] && !node.readOnly) {\n return true;\n }\n if (tagName === 'TEXTAREA' && !node.readOnly) {\n return true;\n }\n if (node.isContentEditable) {\n return true;\n }\n return false;\n}\n\n/**\n * Keep track of our keyboard modality state with `hadKeyboardEvent`.\n * If the most recent user interaction was via the keyboard;\n * and the key press did not include a meta, alt/option, or control key;\n * then the modality is keyboard. Otherwise, the modality is not keyboard.\n * @param {KeyboardEvent} event\n */\nfunction handleKeyDown(event) {\n if (event.metaKey || event.altKey || event.ctrlKey) {\n return;\n }\n hadKeyboardEvent = true;\n}\n\n/**\n * If at any point a user clicks with a pointing device, ensure that we change\n * the modality away from keyboard.\n * This avoids the situation where a user presses a key on an already focused\n * element, and then clicks on a different element, focusing it with a\n * pointing device, while we still think we're in keyboard modality.\n */\nfunction handlePointerDown() {\n hadKeyboardEvent = false;\n}\nfunction handleVisibilityChange() {\n if (this.visibilityState === 'hidden') {\n // If the tab becomes active again, the browser will handle calling focus\n // on the element (Safari actually calls it twice).\n // If this tab change caused a blur on an element with focus-visible,\n // re-apply the class when the user switches back to the tab.\n if (hadFocusVisibleRecently) {\n hadKeyboardEvent = true;\n }\n }\n}\nfunction prepare(doc) {\n doc.addEventListener('keydown', handleKeyDown, true);\n doc.addEventListener('mousedown', handlePointerDown, true);\n doc.addEventListener('pointerdown', handlePointerDown, true);\n doc.addEventListener('touchstart', handlePointerDown, true);\n doc.addEventListener('visibilitychange', handleVisibilityChange, true);\n}\nexport function teardown(doc) {\n doc.removeEventListener('keydown', handleKeyDown, true);\n doc.removeEventListener('mousedown', handlePointerDown, true);\n doc.removeEventListener('pointerdown', handlePointerDown, true);\n doc.removeEventListener('touchstart', handlePointerDown, true);\n doc.removeEventListener('visibilitychange', handleVisibilityChange, true);\n}\nfunction isFocusVisible(event) {\n const {\n target\n } = event;\n try {\n return target.matches(':focus-visible');\n } catch (error) {\n // Browsers not implementing :focus-visible will throw a SyntaxError.\n // We use our own heuristic for those browsers.\n // Rethrow might be better if it's not the expected error but do we really\n // want to crash if focus-visible malfunctioned?\n }\n\n // No need for validFocusTarget check. The user does that by attaching it to\n // focusable events only.\n return hadKeyboardEvent || focusTriggersKeyboardModality(target);\n}\nexport default function useIsFocusVisible() {\n const ref = React.useCallback(node => {\n if (node != null) {\n prepare(node.ownerDocument);\n }\n }, []);\n const isFocusVisibleRef = React.useRef(false);\n\n /**\n * Should be called if a blur event is fired\n */\n function handleBlurVisible() {\n // checking against potential state variable does not suffice if we focus and blur synchronously.\n // React wouldn't have time to trigger a re-render so `focusVisible` would be stale.\n // Ideally we would adjust `isFocusVisible(event)` to look at `relatedTarget` for blur events.\n // This doesn't work in IE11 due to https://github.com/facebook/react/issues/3751\n // TODO: check again if React releases their internal changes to focus event handling (https://github.com/facebook/react/pull/19186).\n if (isFocusVisibleRef.current) {\n // To detect a tab/window switch, we look for a blur event followed\n // rapidly by a visibility change.\n // If we don't see a visibility change within 100ms, it's probably a\n // regular focus change.\n hadFocusVisibleRecently = true;\n hadFocusVisibleRecentlyTimeout.start(100, () => {\n hadFocusVisibleRecently = false;\n });\n isFocusVisibleRef.current = false;\n return true;\n }\n return false;\n }\n\n /**\n * Should be called if a blur event is fired\n */\n function handleFocusVisible(event) {\n if (isFocusVisible(event)) {\n isFocusVisibleRef.current = true;\n return true;\n }\n return false;\n }\n return {\n isFocusVisibleRef,\n onFocus: handleFocusVisible,\n onBlur: handleBlurVisible,\n ref\n };\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\n/**\n * Add keys, values of `defaultProps` that does not exist in `props`\n * @param {object} defaultProps\n * @param {object} props\n * @returns {object} resolved props\n */\nexport default function resolveProps(defaultProps, props) {\n const output = _extends({}, props);\n Object.keys(defaultProps).forEach(propName => {\n if (propName.toString().match(/^(components|slots)$/)) {\n output[propName] = _extends({}, defaultProps[propName], output[propName]);\n } else if (propName.toString().match(/^(componentsProps|slotProps)$/)) {\n const defaultSlotProps = defaultProps[propName] || {};\n const slotProps = props[propName];\n output[propName] = {};\n if (!slotProps || !Object.keys(slotProps)) {\n // Reduce the iteration if the slot props is empty\n output[propName] = defaultSlotProps;\n } else if (!defaultSlotProps || !Object.keys(defaultSlotProps)) {\n // Reduce the iteration if the default slot props is empty\n output[propName] = slotProps;\n } else {\n output[propName] = _extends({}, slotProps);\n Object.keys(defaultSlotProps).forEach(slotPropName => {\n output[propName][slotPropName] = resolveProps(defaultSlotProps[slotPropName], slotProps[slotPropName]);\n });\n }\n } else if (output[propName] === undefined) {\n output[propName] = defaultProps[propName];\n }\n });\n return output;\n}","export default function composeClasses(slots, getUtilityClass, classes = undefined) {\n const output = {};\n Object.keys(slots).forEach(\n // `Object.keys(slots)` can't be wider than `T` because we infer `T` from `slots`.\n // @ts-expect-error https://github.com/microsoft/TypeScript/pull/12253#issuecomment-263132208\n slot => {\n output[slot] = slots[slot].reduce((acc, key) => {\n if (key) {\n const utilityClass = getUtilityClass(key);\n if (utilityClass !== '') {\n acc.push(utilityClass);\n }\n if (classes && classes[key]) {\n acc.push(classes[key]);\n }\n }\n return acc;\n }, []).join(' ');\n });\n return output;\n}","const defaultGenerator = componentName => componentName;\nconst createClassNameGenerator = () => {\n let generate = defaultGenerator;\n return {\n configure(generator) {\n generate = generator;\n },\n generate(componentName) {\n return generate(componentName);\n },\n reset() {\n generate = defaultGenerator;\n }\n };\n};\nconst ClassNameGenerator = createClassNameGenerator();\nexport default ClassNameGenerator;","import ClassNameGenerator from '../ClassNameGenerator';\nexport const globalStateClasses = {\n active: 'active',\n checked: 'checked',\n completed: 'completed',\n disabled: 'disabled',\n error: 'error',\n expanded: 'expanded',\n focused: 'focused',\n focusVisible: 'focusVisible',\n open: 'open',\n readOnly: 'readOnly',\n required: 'required',\n selected: 'selected'\n};\nexport default function generateUtilityClass(componentName, slot, globalStatePrefix = 'Mui') {\n const globalStateClass = globalStateClasses[slot];\n return globalStateClass ? `${globalStatePrefix}-${globalStateClass}` : `${ClassNameGenerator.generate(componentName)}-${slot}`;\n}\nexport function isGlobalState(slot) {\n return globalStateClasses[slot] !== undefined;\n}","import generateUtilityClass from '../generateUtilityClass';\nexport default function generateUtilityClasses(componentName, slots, globalStatePrefix = 'Mui') {\n const result = {};\n slots.forEach(slot => {\n result[slot] = generateUtilityClass(componentName, slot, globalStatePrefix);\n });\n return result;\n}","function clamp(val, min = Number.MIN_SAFE_INTEGER, max = Number.MAX_SAFE_INTEGER) {\n return Math.max(min, Math.min(val, max));\n}\nexport default clamp;","export default function _objectWithoutPropertiesLoose(source, excluded) {\n if (source == null) return {};\n var target = {};\n var sourceKeys = Object.keys(source);\n var key, i;\n for (i = 0; i < sourceKeys.length; i++) {\n key = sourceKeys[i];\n if (excluded.indexOf(key) >= 0) continue;\n target[key] = source[key];\n }\n return target;\n}","import _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nconst _excluded = [\"values\", \"unit\", \"step\"];\n// Sorted ASC by size. That's important.\n// It can't be configured as it's used statically for propTypes.\nexport const breakpointKeys = ['xs', 'sm', 'md', 'lg', 'xl'];\nconst sortBreakpointsValues = values => {\n const breakpointsAsArray = Object.keys(values).map(key => ({\n key,\n val: values[key]\n })) || [];\n // Sort in ascending order\n breakpointsAsArray.sort((breakpoint1, breakpoint2) => breakpoint1.val - breakpoint2.val);\n return breakpointsAsArray.reduce((acc, obj) => {\n return _extends({}, acc, {\n [obj.key]: obj.val\n });\n }, {});\n};\n\n// Keep in mind that @media is inclusive by the CSS specification.\nexport default function createBreakpoints(breakpoints) {\n const {\n // The breakpoint **start** at this value.\n // For instance with the first breakpoint xs: [xs, sm).\n values = {\n xs: 0,\n // phone\n sm: 600,\n // tablet\n md: 900,\n // small laptop\n lg: 1200,\n // desktop\n xl: 1536 // large screen\n },\n unit = 'px',\n step = 5\n } = breakpoints,\n other = _objectWithoutPropertiesLoose(breakpoints, _excluded);\n const sortedValues = sortBreakpointsValues(values);\n const keys = Object.keys(sortedValues);\n function up(key) {\n const value = typeof values[key] === 'number' ? values[key] : key;\n return `@media (min-width:${value}${unit})`;\n }\n function down(key) {\n const value = typeof values[key] === 'number' ? values[key] : key;\n return `@media (max-width:${value - step / 100}${unit})`;\n }\n function between(start, end) {\n const endIndex = keys.indexOf(end);\n return `@media (min-width:${typeof values[start] === 'number' ? values[start] : start}${unit}) and ` + `(max-width:${(endIndex !== -1 && typeof values[keys[endIndex]] === 'number' ? values[keys[endIndex]] : end) - step / 100}${unit})`;\n }\n function only(key) {\n if (keys.indexOf(key) + 1 < keys.length) {\n return between(key, keys[keys.indexOf(key) + 1]);\n }\n return up(key);\n }\n function not(key) {\n // handle first and last key separately, for better readability\n const keyIndex = keys.indexOf(key);\n if (keyIndex === 0) {\n return up(keys[1]);\n }\n if (keyIndex === keys.length - 1) {\n return down(keys[keyIndex]);\n }\n return between(key, keys[keys.indexOf(key) + 1]).replace('@media', '@media not all and');\n }\n return _extends({\n keys,\n values: sortedValues,\n up,\n down,\n between,\n only,\n not,\n unit\n }, other);\n}","const shape = {\n borderRadius: 4\n};\nexport default shape;","import PropTypes from 'prop-types';\nconst responsivePropType = process.env.NODE_ENV !== 'production' ? PropTypes.oneOfType([PropTypes.number, PropTypes.string, PropTypes.object, PropTypes.array]) : {};\nexport default responsivePropType;","import deepmerge from '@mui/utils/deepmerge';\nfunction merge(acc, item) {\n if (!item) {\n return acc;\n }\n return deepmerge(acc, item, {\n clone: false // No need to clone deep, it's way faster.\n });\n}\nexport default merge;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport PropTypes from 'prop-types';\nimport deepmerge from '@mui/utils/deepmerge';\nimport merge from './merge';\n\n// The breakpoint **start** at this value.\n// For instance with the first breakpoint xs: [xs, sm[.\nexport const values = {\n xs: 0,\n // phone\n sm: 600,\n // tablet\n md: 900,\n // small laptop\n lg: 1200,\n // desktop\n xl: 1536 // large screen\n};\nconst defaultBreakpoints = {\n // Sorted ASC by size. That's important.\n // It can't be configured as it's used statically for propTypes.\n keys: ['xs', 'sm', 'md', 'lg', 'xl'],\n up: key => `@media (min-width:${values[key]}px)`\n};\nexport function handleBreakpoints(props, propValue, styleFromPropValue) {\n const theme = props.theme || {};\n if (Array.isArray(propValue)) {\n const themeBreakpoints = theme.breakpoints || defaultBreakpoints;\n return propValue.reduce((acc, item, index) => {\n acc[themeBreakpoints.up(themeBreakpoints.keys[index])] = styleFromPropValue(propValue[index]);\n return acc;\n }, {});\n }\n if (typeof propValue === 'object') {\n const themeBreakpoints = theme.breakpoints || defaultBreakpoints;\n return Object.keys(propValue).reduce((acc, breakpoint) => {\n // key is breakpoint\n if (Object.keys(themeBreakpoints.values || values).indexOf(breakpoint) !== -1) {\n const mediaKey = themeBreakpoints.up(breakpoint);\n acc[mediaKey] = styleFromPropValue(propValue[breakpoint], breakpoint);\n } else {\n const cssKey = breakpoint;\n acc[cssKey] = propValue[cssKey];\n }\n return acc;\n }, {});\n }\n const output = styleFromPropValue(propValue);\n return output;\n}\nfunction breakpoints(styleFunction) {\n // false positive\n // eslint-disable-next-line react/function-component-definition\n const newStyleFunction = props => {\n const theme = props.theme || {};\n const base = styleFunction(props);\n const themeBreakpoints = theme.breakpoints || defaultBreakpoints;\n const extended = themeBreakpoints.keys.reduce((acc, key) => {\n if (props[key]) {\n acc = acc || {};\n acc[themeBreakpoints.up(key)] = styleFunction(_extends({\n theme\n }, props[key]));\n }\n return acc;\n }, null);\n return merge(base, extended);\n };\n newStyleFunction.propTypes = process.env.NODE_ENV !== 'production' ? _extends({}, styleFunction.propTypes, {\n xs: PropTypes.object,\n sm: PropTypes.object,\n md: PropTypes.object,\n lg: PropTypes.object,\n xl: PropTypes.object\n }) : {};\n newStyleFunction.filterProps = ['xs', 'sm', 'md', 'lg', 'xl', ...styleFunction.filterProps];\n return newStyleFunction;\n}\nexport function createEmptyBreakpointObject(breakpointsInput = {}) {\n var _breakpointsInput$key;\n const breakpointsInOrder = (_breakpointsInput$key = breakpointsInput.keys) == null ? void 0 : _breakpointsInput$key.reduce((acc, key) => {\n const breakpointStyleKey = breakpointsInput.up(key);\n acc[breakpointStyleKey] = {};\n return acc;\n }, {});\n return breakpointsInOrder || {};\n}\nexport function removeUnusedBreakpoints(breakpointKeys, style) {\n return breakpointKeys.reduce((acc, key) => {\n const breakpointOutput = acc[key];\n const isBreakpointUnused = !breakpointOutput || Object.keys(breakpointOutput).length === 0;\n if (isBreakpointUnused) {\n delete acc[key];\n }\n return acc;\n }, style);\n}\nexport function mergeBreakpointsInOrder(breakpointsInput, ...styles) {\n const emptyBreakpoints = createEmptyBreakpointObject(breakpointsInput);\n const mergedOutput = [emptyBreakpoints, ...styles].reduce((prev, next) => deepmerge(prev, next), {});\n return removeUnusedBreakpoints(Object.keys(emptyBreakpoints), mergedOutput);\n}\n\n// compute base for responsive values; e.g.,\n// [1,2,3] => {xs: true, sm: true, md: true}\n// {xs: 1, sm: 2, md: 3} => {xs: true, sm: true, md: true}\nexport function computeBreakpointsBase(breakpointValues, themeBreakpoints) {\n // fixed value\n if (typeof breakpointValues !== 'object') {\n return {};\n }\n const base = {};\n const breakpointsKeys = Object.keys(themeBreakpoints);\n if (Array.isArray(breakpointValues)) {\n breakpointsKeys.forEach((breakpoint, i) => {\n if (i < breakpointValues.length) {\n base[breakpoint] = true;\n }\n });\n } else {\n breakpointsKeys.forEach(breakpoint => {\n if (breakpointValues[breakpoint] != null) {\n base[breakpoint] = true;\n }\n });\n }\n return base;\n}\nexport function resolveBreakpointValues({\n values: breakpointValues,\n breakpoints: themeBreakpoints,\n base: customBase\n}) {\n const base = customBase || computeBreakpointsBase(breakpointValues, themeBreakpoints);\n const keys = Object.keys(base);\n if (keys.length === 0) {\n return breakpointValues;\n }\n let previous;\n return keys.reduce((acc, breakpoint, i) => {\n if (Array.isArray(breakpointValues)) {\n acc[breakpoint] = breakpointValues[i] != null ? breakpointValues[i] : breakpointValues[previous];\n previous = i;\n } else if (typeof breakpointValues === 'object') {\n acc[breakpoint] = breakpointValues[breakpoint] != null ? breakpointValues[breakpoint] : breakpointValues[previous];\n previous = breakpoint;\n } else {\n acc[breakpoint] = breakpointValues;\n }\n return acc;\n }, {});\n}\nexport default breakpoints;","import capitalize from '@mui/utils/capitalize';\nimport responsivePropType from './responsivePropType';\nimport { handleBreakpoints } from './breakpoints';\nexport function getPath(obj, path, checkVars = true) {\n if (!path || typeof path !== 'string') {\n return null;\n }\n\n // Check if CSS variables are used\n if (obj && obj.vars && checkVars) {\n const val = `vars.${path}`.split('.').reduce((acc, item) => acc && acc[item] ? acc[item] : null, obj);\n if (val != null) {\n return val;\n }\n }\n return path.split('.').reduce((acc, item) => {\n if (acc && acc[item] != null) {\n return acc[item];\n }\n return null;\n }, obj);\n}\nexport function getStyleValue(themeMapping, transform, propValueFinal, userValue = propValueFinal) {\n let value;\n if (typeof themeMapping === 'function') {\n value = themeMapping(propValueFinal);\n } else if (Array.isArray(themeMapping)) {\n value = themeMapping[propValueFinal] || userValue;\n } else {\n value = getPath(themeMapping, propValueFinal) || userValue;\n }\n if (transform) {\n value = transform(value, userValue, themeMapping);\n }\n return value;\n}\nfunction style(options) {\n const {\n prop,\n cssProperty = options.prop,\n themeKey,\n transform\n } = options;\n\n // false positive\n // eslint-disable-next-line react/function-component-definition\n const fn = props => {\n if (props[prop] == null) {\n return null;\n }\n const propValue = props[prop];\n const theme = props.theme;\n const themeMapping = getPath(theme, themeKey) || {};\n const styleFromPropValue = propValueFinal => {\n let value = getStyleValue(themeMapping, transform, propValueFinal);\n if (propValueFinal === value && typeof propValueFinal === 'string') {\n // Haven't found value\n value = getStyleValue(themeMapping, transform, `${prop}${propValueFinal === 'default' ? '' : capitalize(propValueFinal)}`, propValueFinal);\n }\n if (cssProperty === false) {\n return value;\n }\n return {\n [cssProperty]: value\n };\n };\n return handleBreakpoints(props, propValue, styleFromPropValue);\n };\n fn.propTypes = process.env.NODE_ENV !== 'production' ? {\n [prop]: responsivePropType\n } : {};\n fn.filterProps = [prop];\n return fn;\n}\nexport default style;","export default function memoize(fn) {\n const cache = {};\n return arg => {\n if (cache[arg] === undefined) {\n cache[arg] = fn(arg);\n }\n return cache[arg];\n };\n}","import responsivePropType from './responsivePropType';\nimport { handleBreakpoints } from './breakpoints';\nimport { getPath } from './style';\nimport merge from './merge';\nimport memoize from './memoize';\nconst properties = {\n m: 'margin',\n p: 'padding'\n};\nconst directions = {\n t: 'Top',\n r: 'Right',\n b: 'Bottom',\n l: 'Left',\n x: ['Left', 'Right'],\n y: ['Top', 'Bottom']\n};\nconst aliases = {\n marginX: 'mx',\n marginY: 'my',\n paddingX: 'px',\n paddingY: 'py'\n};\n\n// memoize() impact:\n// From 300,000 ops/sec\n// To 350,000 ops/sec\nconst getCssProperties = memoize(prop => {\n // It's not a shorthand notation.\n if (prop.length > 2) {\n if (aliases[prop]) {\n prop = aliases[prop];\n } else {\n return [prop];\n }\n }\n const [a, b] = prop.split('');\n const property = properties[a];\n const direction = directions[b] || '';\n return Array.isArray(direction) ? direction.map(dir => property + dir) : [property + direction];\n});\nexport const marginKeys = ['m', 'mt', 'mr', 'mb', 'ml', 'mx', 'my', 'margin', 'marginTop', 'marginRight', 'marginBottom', 'marginLeft', 'marginX', 'marginY', 'marginInline', 'marginInlineStart', 'marginInlineEnd', 'marginBlock', 'marginBlockStart', 'marginBlockEnd'];\nexport const paddingKeys = ['p', 'pt', 'pr', 'pb', 'pl', 'px', 'py', 'padding', 'paddingTop', 'paddingRight', 'paddingBottom', 'paddingLeft', 'paddingX', 'paddingY', 'paddingInline', 'paddingInlineStart', 'paddingInlineEnd', 'paddingBlock', 'paddingBlockStart', 'paddingBlockEnd'];\nconst spacingKeys = [...marginKeys, ...paddingKeys];\nexport function createUnaryUnit(theme, themeKey, defaultValue, propName) {\n var _getPath;\n const themeSpacing = (_getPath = getPath(theme, themeKey, false)) != null ? _getPath : defaultValue;\n if (typeof themeSpacing === 'number') {\n return abs => {\n if (typeof abs === 'string') {\n return abs;\n }\n if (process.env.NODE_ENV !== 'production') {\n if (typeof abs !== 'number') {\n console.error(`MUI: Expected ${propName} argument to be a number or a string, got ${abs}.`);\n }\n }\n return themeSpacing * abs;\n };\n }\n if (Array.isArray(themeSpacing)) {\n return abs => {\n if (typeof abs === 'string') {\n return abs;\n }\n if (process.env.NODE_ENV !== 'production') {\n if (!Number.isInteger(abs)) {\n console.error([`MUI: The \\`theme.${themeKey}\\` array type cannot be combined with non integer values.` + `You should either use an integer value that can be used as index, or define the \\`theme.${themeKey}\\` as a number.`].join('\\n'));\n } else if (abs > themeSpacing.length - 1) {\n console.error([`MUI: The value provided (${abs}) overflows.`, `The supported values are: ${JSON.stringify(themeSpacing)}.`, `${abs} > ${themeSpacing.length - 1}, you need to add the missing values.`].join('\\n'));\n }\n }\n return themeSpacing[abs];\n };\n }\n if (typeof themeSpacing === 'function') {\n return themeSpacing;\n }\n if (process.env.NODE_ENV !== 'production') {\n console.error([`MUI: The \\`theme.${themeKey}\\` value (${themeSpacing}) is invalid.`, 'It should be a number, an array or a function.'].join('\\n'));\n }\n return () => undefined;\n}\nexport function createUnarySpacing(theme) {\n return createUnaryUnit(theme, 'spacing', 8, 'spacing');\n}\nexport function getValue(transformer, propValue) {\n if (typeof propValue === 'string' || propValue == null) {\n return propValue;\n }\n const abs = Math.abs(propValue);\n const transformed = transformer(abs);\n if (propValue >= 0) {\n return transformed;\n }\n if (typeof transformed === 'number') {\n return -transformed;\n }\n return `-${transformed}`;\n}\nexport function getStyleFromPropValue(cssProperties, transformer) {\n return propValue => cssProperties.reduce((acc, cssProperty) => {\n acc[cssProperty] = getValue(transformer, propValue);\n return acc;\n }, {});\n}\nfunction resolveCssProperty(props, keys, prop, transformer) {\n // Using a hash computation over an array iteration could be faster, but with only 28 items,\n // it's doesn't worth the bundle size.\n if (keys.indexOf(prop) === -1) {\n return null;\n }\n const cssProperties = getCssProperties(prop);\n const styleFromPropValue = getStyleFromPropValue(cssProperties, transformer);\n const propValue = props[prop];\n return handleBreakpoints(props, propValue, styleFromPropValue);\n}\nfunction style(props, keys) {\n const transformer = createUnarySpacing(props.theme);\n return Object.keys(props).map(prop => resolveCssProperty(props, keys, prop, transformer)).reduce(merge, {});\n}\nexport function margin(props) {\n return style(props, marginKeys);\n}\nmargin.propTypes = process.env.NODE_ENV !== 'production' ? marginKeys.reduce((obj, key) => {\n obj[key] = responsivePropType;\n return obj;\n}, {}) : {};\nmargin.filterProps = marginKeys;\nexport function padding(props) {\n return style(props, paddingKeys);\n}\npadding.propTypes = process.env.NODE_ENV !== 'production' ? paddingKeys.reduce((obj, key) => {\n obj[key] = responsivePropType;\n return obj;\n}, {}) : {};\npadding.filterProps = paddingKeys;\nfunction spacing(props) {\n return style(props, spacingKeys);\n}\nspacing.propTypes = process.env.NODE_ENV !== 'production' ? spacingKeys.reduce((obj, key) => {\n obj[key] = responsivePropType;\n return obj;\n}, {}) : {};\nspacing.filterProps = spacingKeys;\nexport default spacing;","import { createUnarySpacing } from '../spacing';\n\n// The different signatures imply different meaning for their arguments that can't be expressed structurally.\n// We express the difference with variable names.\n\nexport default function createSpacing(spacingInput = 8) {\n // Already transformed.\n if (spacingInput.mui) {\n return spacingInput;\n }\n\n // Material Design layouts are visually balanced. Most measurements align to an 8dp grid, which aligns both spacing and the overall layout.\n // Smaller components, such as icons, can align to a 4dp grid.\n // https://m2.material.io/design/layout/understanding-layout.html\n const transform = createUnarySpacing({\n spacing: spacingInput\n });\n const spacing = (...argsInput) => {\n if (process.env.NODE_ENV !== 'production') {\n if (!(argsInput.length <= 4)) {\n console.error(`MUI: Too many arguments provided, expected between 0 and 4, got ${argsInput.length}`);\n }\n }\n const args = argsInput.length === 0 ? [1] : argsInput;\n return args.map(argument => {\n const output = transform(argument);\n return typeof output === 'number' ? `${output}px` : output;\n }).join(' ');\n };\n spacing.mui = true;\n return spacing;\n}","import merge from './merge';\nfunction compose(...styles) {\n const handlers = styles.reduce((acc, style) => {\n style.filterProps.forEach(prop => {\n acc[prop] = style;\n });\n return acc;\n }, {});\n\n // false positive\n // eslint-disable-next-line react/function-component-definition\n const fn = props => {\n return Object.keys(props).reduce((acc, prop) => {\n if (handlers[prop]) {\n return merge(acc, handlers[prop](props));\n }\n return acc;\n }, {});\n };\n fn.propTypes = process.env.NODE_ENV !== 'production' ? styles.reduce((acc, style) => Object.assign(acc, style.propTypes), {}) : {};\n fn.filterProps = styles.reduce((acc, style) => acc.concat(style.filterProps), []);\n return fn;\n}\nexport default compose;","import responsivePropType from './responsivePropType';\nimport style from './style';\nimport compose from './compose';\nimport { createUnaryUnit, getValue } from './spacing';\nimport { handleBreakpoints } from './breakpoints';\nexport function borderTransform(value) {\n if (typeof value !== 'number') {\n return value;\n }\n return `${value}px solid`;\n}\nfunction createBorderStyle(prop, transform) {\n return style({\n prop,\n themeKey: 'borders',\n transform\n });\n}\nexport const border = createBorderStyle('border', borderTransform);\nexport const borderTop = createBorderStyle('borderTop', borderTransform);\nexport const borderRight = createBorderStyle('borderRight', borderTransform);\nexport const borderBottom = createBorderStyle('borderBottom', borderTransform);\nexport const borderLeft = createBorderStyle('borderLeft', borderTransform);\nexport const borderColor = createBorderStyle('borderColor');\nexport const borderTopColor = createBorderStyle('borderTopColor');\nexport const borderRightColor = createBorderStyle('borderRightColor');\nexport const borderBottomColor = createBorderStyle('borderBottomColor');\nexport const borderLeftColor = createBorderStyle('borderLeftColor');\nexport const outline = createBorderStyle('outline', borderTransform);\nexport const outlineColor = createBorderStyle('outlineColor');\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const borderRadius = props => {\n if (props.borderRadius !== undefined && props.borderRadius !== null) {\n const transformer = createUnaryUnit(props.theme, 'shape.borderRadius', 4, 'borderRadius');\n const styleFromPropValue = propValue => ({\n borderRadius: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.borderRadius, styleFromPropValue);\n }\n return null;\n};\nborderRadius.propTypes = process.env.NODE_ENV !== 'production' ? {\n borderRadius: responsivePropType\n} : {};\nborderRadius.filterProps = ['borderRadius'];\nconst borders = compose(border, borderTop, borderRight, borderBottom, borderLeft, borderColor, borderTopColor, borderRightColor, borderBottomColor, borderLeftColor, borderRadius, outline, outlineColor);\nexport default borders;","import style from './style';\nimport compose from './compose';\nimport { createUnaryUnit, getValue } from './spacing';\nimport { handleBreakpoints } from './breakpoints';\nimport responsivePropType from './responsivePropType';\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const gap = props => {\n if (props.gap !== undefined && props.gap !== null) {\n const transformer = createUnaryUnit(props.theme, 'spacing', 8, 'gap');\n const styleFromPropValue = propValue => ({\n gap: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.gap, styleFromPropValue);\n }\n return null;\n};\ngap.propTypes = process.env.NODE_ENV !== 'production' ? {\n gap: responsivePropType\n} : {};\ngap.filterProps = ['gap'];\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const columnGap = props => {\n if (props.columnGap !== undefined && props.columnGap !== null) {\n const transformer = createUnaryUnit(props.theme, 'spacing', 8, 'columnGap');\n const styleFromPropValue = propValue => ({\n columnGap: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.columnGap, styleFromPropValue);\n }\n return null;\n};\ncolumnGap.propTypes = process.env.NODE_ENV !== 'production' ? {\n columnGap: responsivePropType\n} : {};\ncolumnGap.filterProps = ['columnGap'];\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const rowGap = props => {\n if (props.rowGap !== undefined && props.rowGap !== null) {\n const transformer = createUnaryUnit(props.theme, 'spacing', 8, 'rowGap');\n const styleFromPropValue = propValue => ({\n rowGap: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.rowGap, styleFromPropValue);\n }\n return null;\n};\nrowGap.propTypes = process.env.NODE_ENV !== 'production' ? {\n rowGap: responsivePropType\n} : {};\nrowGap.filterProps = ['rowGap'];\nexport const gridColumn = style({\n prop: 'gridColumn'\n});\nexport const gridRow = style({\n prop: 'gridRow'\n});\nexport const gridAutoFlow = style({\n prop: 'gridAutoFlow'\n});\nexport const gridAutoColumns = style({\n prop: 'gridAutoColumns'\n});\nexport const gridAutoRows = style({\n prop: 'gridAutoRows'\n});\nexport const gridTemplateColumns = style({\n prop: 'gridTemplateColumns'\n});\nexport const gridTemplateRows = style({\n prop: 'gridTemplateRows'\n});\nexport const gridTemplateAreas = style({\n prop: 'gridTemplateAreas'\n});\nexport const gridArea = style({\n prop: 'gridArea'\n});\nconst grid = compose(gap, columnGap, rowGap, gridColumn, gridRow, gridAutoFlow, gridAutoColumns, gridAutoRows, gridTemplateColumns, gridTemplateRows, gridTemplateAreas, gridArea);\nexport default grid;","import style from './style';\nimport compose from './compose';\nexport function paletteTransform(value, userValue) {\n if (userValue === 'grey') {\n return userValue;\n }\n return value;\n}\nexport const color = style({\n prop: 'color',\n themeKey: 'palette',\n transform: paletteTransform\n});\nexport const bgcolor = style({\n prop: 'bgcolor',\n cssProperty: 'backgroundColor',\n themeKey: 'palette',\n transform: paletteTransform\n});\nexport const backgroundColor = style({\n prop: 'backgroundColor',\n themeKey: 'palette',\n transform: paletteTransform\n});\nconst palette = compose(color, bgcolor, backgroundColor);\nexport default palette;","import style from './style';\nimport compose from './compose';\nimport { handleBreakpoints, values as breakpointsValues } from './breakpoints';\nexport function sizingTransform(value) {\n return value <= 1 && value !== 0 ? `${value * 100}%` : value;\n}\nexport const width = style({\n prop: 'width',\n transform: sizingTransform\n});\nexport const maxWidth = props => {\n if (props.maxWidth !== undefined && props.maxWidth !== null) {\n const styleFromPropValue = propValue => {\n var _props$theme, _props$theme2;\n const breakpoint = ((_props$theme = props.theme) == null || (_props$theme = _props$theme.breakpoints) == null || (_props$theme = _props$theme.values) == null ? void 0 : _props$theme[propValue]) || breakpointsValues[propValue];\n if (!breakpoint) {\n return {\n maxWidth: sizingTransform(propValue)\n };\n }\n if (((_props$theme2 = props.theme) == null || (_props$theme2 = _props$theme2.breakpoints) == null ? void 0 : _props$theme2.unit) !== 'px') {\n return {\n maxWidth: `${breakpoint}${props.theme.breakpoints.unit}`\n };\n }\n return {\n maxWidth: breakpoint\n };\n };\n return handleBreakpoints(props, props.maxWidth, styleFromPropValue);\n }\n return null;\n};\nmaxWidth.filterProps = ['maxWidth'];\nexport const minWidth = style({\n prop: 'minWidth',\n transform: sizingTransform\n});\nexport const height = style({\n prop: 'height',\n transform: sizingTransform\n});\nexport const maxHeight = style({\n prop: 'maxHeight',\n transform: sizingTransform\n});\nexport const minHeight = style({\n prop: 'minHeight',\n transform: sizingTransform\n});\nexport const sizeWidth = style({\n prop: 'size',\n cssProperty: 'width',\n transform: sizingTransform\n});\nexport const sizeHeight = style({\n prop: 'size',\n cssProperty: 'height',\n transform: sizingTransform\n});\nexport const boxSizing = style({\n prop: 'boxSizing'\n});\nconst sizing = compose(width, maxWidth, minWidth, height, maxHeight, minHeight, boxSizing);\nexport default sizing;","import { padding, margin } from '../spacing';\nimport { borderRadius, borderTransform } from '../borders';\nimport { gap, rowGap, columnGap } from '../cssGrid';\nimport { paletteTransform } from '../palette';\nimport { maxWidth, sizingTransform } from '../sizing';\nconst defaultSxConfig = {\n // borders\n border: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderTop: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderRight: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderBottom: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderLeft: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderColor: {\n themeKey: 'palette'\n },\n borderTopColor: {\n themeKey: 'palette'\n },\n borderRightColor: {\n themeKey: 'palette'\n },\n borderBottomColor: {\n themeKey: 'palette'\n },\n borderLeftColor: {\n themeKey: 'palette'\n },\n outline: {\n themeKey: 'borders',\n transform: borderTransform\n },\n outlineColor: {\n themeKey: 'palette'\n },\n borderRadius: {\n themeKey: 'shape.borderRadius',\n style: borderRadius\n },\n // palette\n color: {\n themeKey: 'palette',\n transform: paletteTransform\n },\n bgcolor: {\n themeKey: 'palette',\n cssProperty: 'backgroundColor',\n transform: paletteTransform\n },\n backgroundColor: {\n themeKey: 'palette',\n transform: paletteTransform\n },\n // spacing\n p: {\n style: padding\n },\n pt: {\n style: padding\n },\n pr: {\n style: padding\n },\n pb: {\n style: padding\n },\n pl: {\n style: padding\n },\n px: {\n style: padding\n },\n py: {\n style: padding\n },\n padding: {\n style: padding\n },\n paddingTop: {\n style: padding\n },\n paddingRight: {\n style: padding\n },\n paddingBottom: {\n style: padding\n },\n paddingLeft: {\n style: padding\n },\n paddingX: {\n style: padding\n },\n paddingY: {\n style: padding\n },\n paddingInline: {\n style: padding\n },\n paddingInlineStart: {\n style: padding\n },\n paddingInlineEnd: {\n style: padding\n },\n paddingBlock: {\n style: padding\n },\n paddingBlockStart: {\n style: padding\n },\n paddingBlockEnd: {\n style: padding\n },\n m: {\n style: margin\n },\n mt: {\n style: margin\n },\n mr: {\n style: margin\n },\n mb: {\n style: margin\n },\n ml: {\n style: margin\n },\n mx: {\n style: margin\n },\n my: {\n style: margin\n },\n margin: {\n style: margin\n },\n marginTop: {\n style: margin\n },\n marginRight: {\n style: margin\n },\n marginBottom: {\n style: margin\n },\n marginLeft: {\n style: margin\n },\n marginX: {\n style: margin\n },\n marginY: {\n style: margin\n },\n marginInline: {\n style: margin\n },\n marginInlineStart: {\n style: margin\n },\n marginInlineEnd: {\n style: margin\n },\n marginBlock: {\n style: margin\n },\n marginBlockStart: {\n style: margin\n },\n marginBlockEnd: {\n style: margin\n },\n // display\n displayPrint: {\n cssProperty: false,\n transform: value => ({\n '@media print': {\n display: value\n }\n })\n },\n display: {},\n overflow: {},\n textOverflow: {},\n visibility: {},\n whiteSpace: {},\n // flexbox\n flexBasis: {},\n flexDirection: {},\n flexWrap: {},\n justifyContent: {},\n alignItems: {},\n alignContent: {},\n order: {},\n flex: {},\n flexGrow: {},\n flexShrink: {},\n alignSelf: {},\n justifyItems: {},\n justifySelf: {},\n // grid\n gap: {\n style: gap\n },\n rowGap: {\n style: rowGap\n },\n columnGap: {\n style: columnGap\n },\n gridColumn: {},\n gridRow: {},\n gridAutoFlow: {},\n gridAutoColumns: {},\n gridAutoRows: {},\n gridTemplateColumns: {},\n gridTemplateRows: {},\n gridTemplateAreas: {},\n gridArea: {},\n // positions\n position: {},\n zIndex: {\n themeKey: 'zIndex'\n },\n top: {},\n right: {},\n bottom: {},\n left: {},\n // shadows\n boxShadow: {\n themeKey: 'shadows'\n },\n // sizing\n width: {\n transform: sizingTransform\n },\n maxWidth: {\n style: maxWidth\n },\n minWidth: {\n transform: sizingTransform\n },\n height: {\n transform: sizingTransform\n },\n maxHeight: {\n transform: sizingTransform\n },\n minHeight: {\n transform: sizingTransform\n },\n boxSizing: {},\n // typography\n fontFamily: {\n themeKey: 'typography'\n },\n fontSize: {\n themeKey: 'typography'\n },\n fontStyle: {\n themeKey: 'typography'\n },\n fontWeight: {\n themeKey: 'typography'\n },\n letterSpacing: {},\n textTransform: {},\n lineHeight: {},\n textAlign: {},\n typography: {\n cssProperty: false,\n themeKey: 'typography'\n }\n};\nexport default defaultSxConfig;","import capitalize from '@mui/utils/capitalize';\nimport merge from '../merge';\nimport { getPath, getStyleValue as getValue } from '../style';\nimport { handleBreakpoints, createEmptyBreakpointObject, removeUnusedBreakpoints } from '../breakpoints';\nimport defaultSxConfig from './defaultSxConfig';\nfunction objectsHaveSameKeys(...objects) {\n const allKeys = objects.reduce((keys, object) => keys.concat(Object.keys(object)), []);\n const union = new Set(allKeys);\n return objects.every(object => union.size === Object.keys(object).length);\n}\nfunction callIfFn(maybeFn, arg) {\n return typeof maybeFn === 'function' ? maybeFn(arg) : maybeFn;\n}\n\n// eslint-disable-next-line @typescript-eslint/naming-convention\nexport function unstable_createStyleFunctionSx() {\n function getThemeValue(prop, val, theme, config) {\n const props = {\n [prop]: val,\n theme\n };\n const options = config[prop];\n if (!options) {\n return {\n [prop]: val\n };\n }\n const {\n cssProperty = prop,\n themeKey,\n transform,\n style\n } = options;\n if (val == null) {\n return null;\n }\n\n // TODO v6: remove, see https://github.com/mui/material-ui/pull/38123\n if (themeKey === 'typography' && val === 'inherit') {\n return {\n [prop]: val\n };\n }\n const themeMapping = getPath(theme, themeKey) || {};\n if (style) {\n return style(props);\n }\n const styleFromPropValue = propValueFinal => {\n let value = getValue(themeMapping, transform, propValueFinal);\n if (propValueFinal === value && typeof propValueFinal === 'string') {\n // Haven't found value\n value = getValue(themeMapping, transform, `${prop}${propValueFinal === 'default' ? '' : capitalize(propValueFinal)}`, propValueFinal);\n }\n if (cssProperty === false) {\n return value;\n }\n return {\n [cssProperty]: value\n };\n };\n return handleBreakpoints(props, val, styleFromPropValue);\n }\n function styleFunctionSx(props) {\n var _theme$unstable_sxCon;\n const {\n sx,\n theme = {}\n } = props || {};\n if (!sx) {\n return null; // Emotion & styled-components will neglect null\n }\n const config = (_theme$unstable_sxCon = theme.unstable_sxConfig) != null ? _theme$unstable_sxCon : defaultSxConfig;\n\n /*\n * Receive `sxInput` as object or callback\n * and then recursively check keys & values to create media query object styles.\n * (the result will be used in `styled`)\n */\n function traverse(sxInput) {\n let sxObject = sxInput;\n if (typeof sxInput === 'function') {\n sxObject = sxInput(theme);\n } else if (typeof sxInput !== 'object') {\n // value\n return sxInput;\n }\n if (!sxObject) {\n return null;\n }\n const emptyBreakpoints = createEmptyBreakpointObject(theme.breakpoints);\n const breakpointsKeys = Object.keys(emptyBreakpoints);\n let css = emptyBreakpoints;\n Object.keys(sxObject).forEach(styleKey => {\n const value = callIfFn(sxObject[styleKey], theme);\n if (value !== null && value !== undefined) {\n if (typeof value === 'object') {\n if (config[styleKey]) {\n css = merge(css, getThemeValue(styleKey, value, theme, config));\n } else {\n const breakpointsValues = handleBreakpoints({\n theme\n }, value, x => ({\n [styleKey]: x\n }));\n if (objectsHaveSameKeys(breakpointsValues, value)) {\n css[styleKey] = styleFunctionSx({\n sx: value,\n theme\n });\n } else {\n css = merge(css, breakpointsValues);\n }\n }\n } else {\n css = merge(css, getThemeValue(styleKey, value, theme, config));\n }\n }\n });\n return removeUnusedBreakpoints(breakpointsKeys, css);\n }\n return Array.isArray(sx) ? sx.map(traverse) : traverse(sx);\n }\n return styleFunctionSx;\n}\nconst styleFunctionSx = unstable_createStyleFunctionSx();\nstyleFunctionSx.filterProps = ['sx'];\nexport default styleFunctionSx;","/**\n * A universal utility to style components with multiple color modes. Always use it from the theme object.\n * It works with:\n * - [Basic theme](https://mui.com/material-ui/customization/dark-mode/)\n * - [CSS theme variables](https://mui.com/material-ui/experimental-api/css-theme-variables/overview/)\n * - Zero-runtime engine\n *\n * Tips: Use an array over object spread and place `theme.applyStyles()` last.\n *\n * ✅ [{ background: '#e5e5e5' }, theme.applyStyles('dark', { background: '#1c1c1c' })]\n *\n * 🚫 { background: '#e5e5e5', ...theme.applyStyles('dark', { background: '#1c1c1c' })}\n *\n * @example\n * 1. using with `styled`:\n * ```jsx\n * const Component = styled('div')(({ theme }) => [\n * { background: '#e5e5e5' },\n * theme.applyStyles('dark', {\n * background: '#1c1c1c',\n * color: '#fff',\n * }),\n * ]);\n * ```\n *\n * @example\n * 2. using with `sx` prop:\n * ```jsx\n * [\n * { background: '#e5e5e5' },\n * theme.applyStyles('dark', {\n * background: '#1c1c1c',\n * color: '#fff',\n * }),\n * ]}\n * />\n * ```\n *\n * @example\n * 3. theming a component:\n * ```jsx\n * extendTheme({\n * components: {\n * MuiButton: {\n * styleOverrides: {\n * root: ({ theme }) => [\n * { background: '#e5e5e5' },\n * theme.applyStyles('dark', {\n * background: '#1c1c1c',\n * color: '#fff',\n * }),\n * ],\n * },\n * }\n * }\n * })\n *```\n */\nexport default function applyStyles(key, styles) {\n // @ts-expect-error this is 'any' type\n const theme = this;\n if (theme.vars && typeof theme.getColorSchemeSelector === 'function') {\n // If CssVarsProvider is used as a provider,\n // returns '* :where([data-mui-color-scheme=\"light|dark\"]) &'\n const selector = theme.getColorSchemeSelector(key).replace(/(\\[[^\\]]+\\])/, '*:where($1)');\n return {\n [selector]: styles\n };\n }\n if (theme.palette.mode === key) {\n return styles;\n }\n return {};\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"breakpoints\", \"palette\", \"spacing\", \"shape\"];\nimport deepmerge from '@mui/utils/deepmerge';\nimport createBreakpoints from './createBreakpoints';\nimport shape from './shape';\nimport createSpacing from './createSpacing';\nimport styleFunctionSx from '../styleFunctionSx/styleFunctionSx';\nimport defaultSxConfig from '../styleFunctionSx/defaultSxConfig';\nimport applyStyles from './applyStyles';\nfunction createTheme(options = {}, ...args) {\n const {\n breakpoints: breakpointsInput = {},\n palette: paletteInput = {},\n spacing: spacingInput,\n shape: shapeInput = {}\n } = options,\n other = _objectWithoutPropertiesLoose(options, _excluded);\n const breakpoints = createBreakpoints(breakpointsInput);\n const spacing = createSpacing(spacingInput);\n let muiTheme = deepmerge({\n breakpoints,\n direction: 'ltr',\n components: {},\n // Inject component definitions.\n palette: _extends({\n mode: 'light'\n }, paletteInput),\n spacing,\n shape: _extends({}, shape, shapeInput)\n }, other);\n muiTheme.applyStyles = applyStyles;\n muiTheme = args.reduce((acc, argument) => deepmerge(acc, argument), muiTheme);\n muiTheme.unstable_sxConfig = _extends({}, defaultSxConfig, other == null ? void 0 : other.unstable_sxConfig);\n muiTheme.unstable_sx = function sx(props) {\n return styleFunctionSx({\n sx: props,\n theme: this\n });\n };\n return muiTheme;\n}\nexport default createTheme;","'use client';\n\nimport * as React from 'react';\nimport { ThemeContext } from '@mui/styled-engine';\nfunction isObjectEmpty(obj) {\n return Object.keys(obj).length === 0;\n}\nfunction useTheme(defaultTheme = null) {\n const contextTheme = React.useContext(ThemeContext);\n return !contextTheme || isObjectEmpty(contextTheme) ? defaultTheme : contextTheme;\n}\nexport default useTheme;","'use client';\n\nimport createTheme from './createTheme';\nimport useThemeWithoutDefault from './useThemeWithoutDefault';\nexport const systemDefaultTheme = createTheme();\nfunction useTheme(defaultTheme = systemDefaultTheme) {\n return useThemeWithoutDefault(defaultTheme);\n}\nexport default useTheme;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"ownerState\"],\n _excluded2 = [\"variants\"],\n _excluded3 = [\"name\", \"slot\", \"skipVariantsResolver\", \"skipSx\", \"overridesResolver\"];\n/* eslint-disable no-underscore-dangle */\nimport styledEngineStyled, { internal_processStyles as processStyles } from '@mui/styled-engine';\nimport { isPlainObject } from '@mui/utils/deepmerge';\nimport capitalize from '@mui/utils/capitalize';\nimport getDisplayName from '@mui/utils/getDisplayName';\nimport createTheme from './createTheme';\nimport styleFunctionSx from './styleFunctionSx';\nfunction isEmpty(obj) {\n return Object.keys(obj).length === 0;\n}\n\n// https://github.com/emotion-js/emotion/blob/26ded6109fcd8ca9875cc2ce4564fee678a3f3c5/packages/styled/src/utils.js#L40\nfunction isStringTag(tag) {\n return typeof tag === 'string' &&\n // 96 is one less than the char code\n // for \"a\" so this is checking that\n // it's a lowercase character\n tag.charCodeAt(0) > 96;\n}\n\n// Update /system/styled/#api in case if this changes\nexport function shouldForwardProp(prop) {\n return prop !== 'ownerState' && prop !== 'theme' && prop !== 'sx' && prop !== 'as';\n}\nexport const systemDefaultTheme = createTheme();\nconst lowercaseFirstLetter = string => {\n if (!string) {\n return string;\n }\n return string.charAt(0).toLowerCase() + string.slice(1);\n};\nfunction resolveTheme({\n defaultTheme,\n theme,\n themeId\n}) {\n return isEmpty(theme) ? defaultTheme : theme[themeId] || theme;\n}\nfunction defaultOverridesResolver(slot) {\n if (!slot) {\n return null;\n }\n return (props, styles) => styles[slot];\n}\nfunction processStyleArg(callableStyle, _ref) {\n let {\n ownerState\n } = _ref,\n props = _objectWithoutPropertiesLoose(_ref, _excluded);\n const resolvedStylesArg = typeof callableStyle === 'function' ? callableStyle(_extends({\n ownerState\n }, props)) : callableStyle;\n if (Array.isArray(resolvedStylesArg)) {\n return resolvedStylesArg.flatMap(resolvedStyle => processStyleArg(resolvedStyle, _extends({\n ownerState\n }, props)));\n }\n if (!!resolvedStylesArg && typeof resolvedStylesArg === 'object' && Array.isArray(resolvedStylesArg.variants)) {\n const {\n variants = []\n } = resolvedStylesArg,\n otherStyles = _objectWithoutPropertiesLoose(resolvedStylesArg, _excluded2);\n let result = otherStyles;\n variants.forEach(variant => {\n let isMatch = true;\n if (typeof variant.props === 'function') {\n isMatch = variant.props(_extends({\n ownerState\n }, props, ownerState));\n } else {\n Object.keys(variant.props).forEach(key => {\n if ((ownerState == null ? void 0 : ownerState[key]) !== variant.props[key] && props[key] !== variant.props[key]) {\n isMatch = false;\n }\n });\n }\n if (isMatch) {\n if (!Array.isArray(result)) {\n result = [result];\n }\n result.push(typeof variant.style === 'function' ? variant.style(_extends({\n ownerState\n }, props, ownerState)) : variant.style);\n }\n });\n return result;\n }\n return resolvedStylesArg;\n}\nexport default function createStyled(input = {}) {\n const {\n themeId,\n defaultTheme = systemDefaultTheme,\n rootShouldForwardProp = shouldForwardProp,\n slotShouldForwardProp = shouldForwardProp\n } = input;\n const systemSx = props => {\n return styleFunctionSx(_extends({}, props, {\n theme: resolveTheme(_extends({}, props, {\n defaultTheme,\n themeId\n }))\n }));\n };\n systemSx.__mui_systemSx = true;\n return (tag, inputOptions = {}) => {\n // Filter out the `sx` style function from the previous styled component to prevent unnecessary styles generated by the composite components.\n processStyles(tag, styles => styles.filter(style => !(style != null && style.__mui_systemSx)));\n const {\n name: componentName,\n slot: componentSlot,\n skipVariantsResolver: inputSkipVariantsResolver,\n skipSx: inputSkipSx,\n // TODO v6: remove `lowercaseFirstLetter()` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n overridesResolver = defaultOverridesResolver(lowercaseFirstLetter(componentSlot))\n } = inputOptions,\n options = _objectWithoutPropertiesLoose(inputOptions, _excluded3);\n\n // if skipVariantsResolver option is defined, take the value, otherwise, true for root and false for other slots.\n const skipVariantsResolver = inputSkipVariantsResolver !== undefined ? inputSkipVariantsResolver :\n // TODO v6: remove `Root` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n componentSlot && componentSlot !== 'Root' && componentSlot !== 'root' || false;\n const skipSx = inputSkipSx || false;\n let label;\n if (process.env.NODE_ENV !== 'production') {\n if (componentName) {\n // TODO v6: remove `lowercaseFirstLetter()` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n label = `${componentName}-${lowercaseFirstLetter(componentSlot || 'Root')}`;\n }\n }\n let shouldForwardPropOption = shouldForwardProp;\n\n // TODO v6: remove `Root` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n if (componentSlot === 'Root' || componentSlot === 'root') {\n shouldForwardPropOption = rootShouldForwardProp;\n } else if (componentSlot) {\n // any other slot specified\n shouldForwardPropOption = slotShouldForwardProp;\n } else if (isStringTag(tag)) {\n // for string (html) tag, preserve the behavior in emotion & styled-components.\n shouldForwardPropOption = undefined;\n }\n const defaultStyledResolver = styledEngineStyled(tag, _extends({\n shouldForwardProp: shouldForwardPropOption,\n label\n }, options));\n const transformStyleArg = stylesArg => {\n // On the server Emotion doesn't use React.forwardRef for creating components, so the created\n // component stays as a function. This condition makes sure that we do not interpolate functions\n // which are basically components used as a selectors.\n if (typeof stylesArg === 'function' && stylesArg.__emotion_real !== stylesArg || isPlainObject(stylesArg)) {\n return props => processStyleArg(stylesArg, _extends({}, props, {\n theme: resolveTheme({\n theme: props.theme,\n defaultTheme,\n themeId\n })\n }));\n }\n return stylesArg;\n };\n const muiStyledResolver = (styleArg, ...expressions) => {\n let transformedStyleArg = transformStyleArg(styleArg);\n const expressionsWithDefaultTheme = expressions ? expressions.map(transformStyleArg) : [];\n if (componentName && overridesResolver) {\n expressionsWithDefaultTheme.push(props => {\n const theme = resolveTheme(_extends({}, props, {\n defaultTheme,\n themeId\n }));\n if (!theme.components || !theme.components[componentName] || !theme.components[componentName].styleOverrides) {\n return null;\n }\n const styleOverrides = theme.components[componentName].styleOverrides;\n const resolvedStyleOverrides = {};\n // TODO: v7 remove iteration and use `resolveStyleArg(styleOverrides[slot])` directly\n Object.entries(styleOverrides).forEach(([slotKey, slotStyle]) => {\n resolvedStyleOverrides[slotKey] = processStyleArg(slotStyle, _extends({}, props, {\n theme\n }));\n });\n return overridesResolver(props, resolvedStyleOverrides);\n });\n }\n if (componentName && !skipVariantsResolver) {\n expressionsWithDefaultTheme.push(props => {\n var _theme$components;\n const theme = resolveTheme(_extends({}, props, {\n defaultTheme,\n themeId\n }));\n const themeVariants = theme == null || (_theme$components = theme.components) == null || (_theme$components = _theme$components[componentName]) == null ? void 0 : _theme$components.variants;\n return processStyleArg({\n variants: themeVariants\n }, _extends({}, props, {\n theme\n }));\n });\n }\n if (!skipSx) {\n expressionsWithDefaultTheme.push(systemSx);\n }\n const numOfCustomFnsApplied = expressionsWithDefaultTheme.length - expressions.length;\n if (Array.isArray(styleArg) && numOfCustomFnsApplied > 0) {\n const placeholders = new Array(numOfCustomFnsApplied).fill('');\n // If the type is array, than we need to add placeholders in the template for the overrides, variants and the sx styles.\n transformedStyleArg = [...styleArg, ...placeholders];\n transformedStyleArg.raw = [...styleArg.raw, ...placeholders];\n }\n const Component = defaultStyledResolver(transformedStyleArg, ...expressionsWithDefaultTheme);\n if (process.env.NODE_ENV !== 'production') {\n let displayName;\n if (componentName) {\n displayName = `${componentName}${capitalize(componentSlot || '')}`;\n }\n if (displayName === undefined) {\n displayName = `Styled(${getDisplayName(tag)})`;\n }\n Component.displayName = displayName;\n }\n if (tag.muiName) {\n Component.muiName = tag.muiName;\n }\n return Component;\n };\n if (defaultStyledResolver.withConfig) {\n muiStyledResolver.withConfig = defaultStyledResolver.withConfig;\n }\n return muiStyledResolver;\n };\n}","import resolveProps from '@mui/utils/resolveProps';\nexport default function getThemeProps(params) {\n const {\n theme,\n name,\n props\n } = params;\n if (!theme || !theme.components || !theme.components[name] || !theme.components[name].defaultProps) {\n return props;\n }\n return resolveProps(theme.components[name].defaultProps, props);\n}","'use client';\n\nimport getThemeProps from './getThemeProps';\nimport useTheme from '../useTheme';\nexport default function useThemeProps({\n props,\n name,\n defaultTheme,\n themeId\n}) {\n let theme = useTheme(defaultTheme);\n if (themeId) {\n theme = theme[themeId] || theme;\n }\n const mergedProps = getThemeProps({\n theme,\n name,\n props\n });\n return mergedProps;\n}","import _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\n/* eslint-disable @typescript-eslint/naming-convention */\nimport clamp from '@mui/utils/clamp';\n/**\n * Returns a number whose value is limited to the given range.\n * @param {number} value The value to be clamped\n * @param {number} min The lower boundary of the output range\n * @param {number} max The upper boundary of the output range\n * @returns {number} A number in the range [min, max]\n */\nfunction clampWrapper(value, min = 0, max = 1) {\n if (process.env.NODE_ENV !== 'production') {\n if (value < min || value > max) {\n console.error(`MUI: The value provided ${value} is out of range [${min}, ${max}].`);\n }\n }\n return clamp(value, min, max);\n}\n\n/**\n * Converts a color from CSS hex format to CSS rgb format.\n * @param {string} color - Hex color, i.e. #nnn or #nnnnnn\n * @returns {string} A CSS rgb color string\n */\nexport function hexToRgb(color) {\n color = color.slice(1);\n const re = new RegExp(`.{1,${color.length >= 6 ? 2 : 1}}`, 'g');\n let colors = color.match(re);\n if (colors && colors[0].length === 1) {\n colors = colors.map(n => n + n);\n }\n return colors ? `rgb${colors.length === 4 ? 'a' : ''}(${colors.map((n, index) => {\n return index < 3 ? parseInt(n, 16) : Math.round(parseInt(n, 16) / 255 * 1000) / 1000;\n }).join(', ')})` : '';\n}\nfunction intToHex(int) {\n const hex = int.toString(16);\n return hex.length === 1 ? `0${hex}` : hex;\n}\n\n/**\n * Returns an object with the type and values of a color.\n *\n * Note: Does not support rgb % values.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @returns {object} - A MUI color object: {type: string, values: number[]}\n */\nexport function decomposeColor(color) {\n // Idempotent\n if (color.type) {\n return color;\n }\n if (color.charAt(0) === '#') {\n return decomposeColor(hexToRgb(color));\n }\n const marker = color.indexOf('(');\n const type = color.substring(0, marker);\n if (['rgb', 'rgba', 'hsl', 'hsla', 'color'].indexOf(type) === -1) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: Unsupported \\`${color}\\` color.\nThe following formats are supported: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color().` : _formatMuiErrorMessage(9, color));\n }\n let values = color.substring(marker + 1, color.length - 1);\n let colorSpace;\n if (type === 'color') {\n values = values.split(' ');\n colorSpace = values.shift();\n if (values.length === 4 && values[3].charAt(0) === '/') {\n values[3] = values[3].slice(1);\n }\n if (['srgb', 'display-p3', 'a98-rgb', 'prophoto-rgb', 'rec-2020'].indexOf(colorSpace) === -1) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: unsupported \\`${colorSpace}\\` color space.\nThe following color spaces are supported: srgb, display-p3, a98-rgb, prophoto-rgb, rec-2020.` : _formatMuiErrorMessage(10, colorSpace));\n }\n } else {\n values = values.split(',');\n }\n values = values.map(value => parseFloat(value));\n return {\n type,\n values,\n colorSpace\n };\n}\n\n/**\n * Returns a channel created from the input color.\n *\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @returns {string} - The channel for the color, that can be used in rgba or hsla colors\n */\nexport const colorChannel = color => {\n const decomposedColor = decomposeColor(color);\n return decomposedColor.values.slice(0, 3).map((val, idx) => decomposedColor.type.indexOf('hsl') !== -1 && idx !== 0 ? `${val}%` : val).join(' ');\n};\nexport const private_safeColorChannel = (color, warning) => {\n try {\n return colorChannel(color);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n};\n\n/**\n * Converts a color object with type and values to a string.\n * @param {object} color - Decomposed color\n * @param {string} color.type - One of: 'rgb', 'rgba', 'hsl', 'hsla', 'color'\n * @param {array} color.values - [n,n,n] or [n,n,n,n]\n * @returns {string} A CSS color string\n */\nexport function recomposeColor(color) {\n const {\n type,\n colorSpace\n } = color;\n let {\n values\n } = color;\n if (type.indexOf('rgb') !== -1) {\n // Only convert the first 3 values to int (i.e. not alpha)\n values = values.map((n, i) => i < 3 ? parseInt(n, 10) : n);\n } else if (type.indexOf('hsl') !== -1) {\n values[1] = `${values[1]}%`;\n values[2] = `${values[2]}%`;\n }\n if (type.indexOf('color') !== -1) {\n values = `${colorSpace} ${values.join(' ')}`;\n } else {\n values = `${values.join(', ')}`;\n }\n return `${type}(${values})`;\n}\n\n/**\n * Converts a color from CSS rgb format to CSS hex format.\n * @param {string} color - RGB color, i.e. rgb(n, n, n)\n * @returns {string} A CSS rgb color string, i.e. #nnnnnn\n */\nexport function rgbToHex(color) {\n // Idempotent\n if (color.indexOf('#') === 0) {\n return color;\n }\n const {\n values\n } = decomposeColor(color);\n return `#${values.map((n, i) => intToHex(i === 3 ? Math.round(255 * n) : n)).join('')}`;\n}\n\n/**\n * Converts a color from hsl format to rgb format.\n * @param {string} color - HSL color values\n * @returns {string} rgb color values\n */\nexport function hslToRgb(color) {\n color = decomposeColor(color);\n const {\n values\n } = color;\n const h = values[0];\n const s = values[1] / 100;\n const l = values[2] / 100;\n const a = s * Math.min(l, 1 - l);\n const f = (n, k = (n + h / 30) % 12) => l - a * Math.max(Math.min(k - 3, 9 - k, 1), -1);\n let type = 'rgb';\n const rgb = [Math.round(f(0) * 255), Math.round(f(8) * 255), Math.round(f(4) * 255)];\n if (color.type === 'hsla') {\n type += 'a';\n rgb.push(values[3]);\n }\n return recomposeColor({\n type,\n values: rgb\n });\n}\n/**\n * The relative brightness of any point in a color space,\n * normalized to 0 for darkest black and 1 for lightest white.\n *\n * Formula: https://www.w3.org/TR/WCAG20-TECHS/G17.html#G17-tests\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @returns {number} The relative brightness of the color in the range 0 - 1\n */\nexport function getLuminance(color) {\n color = decomposeColor(color);\n let rgb = color.type === 'hsl' || color.type === 'hsla' ? decomposeColor(hslToRgb(color)).values : color.values;\n rgb = rgb.map(val => {\n if (color.type !== 'color') {\n val /= 255; // normalized\n }\n return val <= 0.03928 ? val / 12.92 : ((val + 0.055) / 1.055) ** 2.4;\n });\n\n // Truncate at 3 digits\n return Number((0.2126 * rgb[0] + 0.7152 * rgb[1] + 0.0722 * rgb[2]).toFixed(3));\n}\n\n/**\n * Calculates the contrast ratio between two colors.\n *\n * Formula: https://www.w3.org/TR/WCAG20-TECHS/G17.html#G17-tests\n * @param {string} foreground - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla()\n * @param {string} background - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla()\n * @returns {number} A contrast ratio value in the range 0 - 21.\n */\nexport function getContrastRatio(foreground, background) {\n const lumA = getLuminance(foreground);\n const lumB = getLuminance(background);\n return (Math.max(lumA, lumB) + 0.05) / (Math.min(lumA, lumB) + 0.05);\n}\n\n/**\n * Sets the absolute transparency of a color.\n * Any existing alpha values are overwritten.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} value - value to set the alpha channel to in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function alpha(color, value) {\n color = decomposeColor(color);\n value = clampWrapper(value);\n if (color.type === 'rgb' || color.type === 'hsl') {\n color.type += 'a';\n }\n if (color.type === 'color') {\n color.values[3] = `/${value}`;\n } else {\n color.values[3] = value;\n }\n return recomposeColor(color);\n}\nexport function private_safeAlpha(color, value, warning) {\n try {\n return alpha(color, value);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Darkens a color.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} coefficient - multiplier in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function darken(color, coefficient) {\n color = decomposeColor(color);\n coefficient = clampWrapper(coefficient);\n if (color.type.indexOf('hsl') !== -1) {\n color.values[2] *= 1 - coefficient;\n } else if (color.type.indexOf('rgb') !== -1 || color.type.indexOf('color') !== -1) {\n for (let i = 0; i < 3; i += 1) {\n color.values[i] *= 1 - coefficient;\n }\n }\n return recomposeColor(color);\n}\nexport function private_safeDarken(color, coefficient, warning) {\n try {\n return darken(color, coefficient);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Lightens a color.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} coefficient - multiplier in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function lighten(color, coefficient) {\n color = decomposeColor(color);\n coefficient = clampWrapper(coefficient);\n if (color.type.indexOf('hsl') !== -1) {\n color.values[2] += (100 - color.values[2]) * coefficient;\n } else if (color.type.indexOf('rgb') !== -1) {\n for (let i = 0; i < 3; i += 1) {\n color.values[i] += (255 - color.values[i]) * coefficient;\n }\n } else if (color.type.indexOf('color') !== -1) {\n for (let i = 0; i < 3; i += 1) {\n color.values[i] += (1 - color.values[i]) * coefficient;\n }\n }\n return recomposeColor(color);\n}\nexport function private_safeLighten(color, coefficient, warning) {\n try {\n return lighten(color, coefficient);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Darken or lighten a color, depending on its luminance.\n * Light colors are darkened, dark colors are lightened.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} coefficient=0.15 - multiplier in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function emphasize(color, coefficient = 0.15) {\n return getLuminance(color) > 0.5 ? darken(color, coefficient) : lighten(color, coefficient);\n}\nexport function private_safeEmphasize(color, coefficient, warning) {\n try {\n return emphasize(color, coefficient);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Blend a transparent overlay color with a background color, resulting in a single\n * RGB color.\n * @param {string} background - CSS color\n * @param {string} overlay - CSS color\n * @param {number} opacity - Opacity multiplier in the range 0 - 1\n * @param {number} [gamma=1.0] - Gamma correction factor. For gamma-correct blending, 2.2 is usual.\n */\nexport function blend(background, overlay, opacity, gamma = 1.0) {\n const blendChannel = (b, o) => Math.round((b ** (1 / gamma) * (1 - opacity) + o ** (1 / gamma) * opacity) ** gamma);\n const backgroundColor = decomposeColor(background);\n const overlayColor = decomposeColor(overlay);\n const rgb = [blendChannel(backgroundColor.values[0], overlayColor.values[0]), blendChannel(backgroundColor.values[1], overlayColor.values[1]), blendChannel(backgroundColor.values[2], overlayColor.values[2])];\n return recomposeColor({\n type: 'rgb',\n values: rgb\n });\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nexport default function createMixins(breakpoints, mixins) {\n return _extends({\n toolbar: {\n minHeight: 56,\n [breakpoints.up('xs')]: {\n '@media (orientation: landscape)': {\n minHeight: 48\n }\n },\n [breakpoints.up('sm')]: {\n minHeight: 64\n }\n }\n }, mixins);\n}","const common = {\n black: '#000',\n white: '#fff'\n};\nexport default common;","const grey = {\n 50: '#fafafa',\n 100: '#f5f5f5',\n 200: '#eeeeee',\n 300: '#e0e0e0',\n 400: '#bdbdbd',\n 500: '#9e9e9e',\n 600: '#757575',\n 700: '#616161',\n 800: '#424242',\n 900: '#212121',\n A100: '#f5f5f5',\n A200: '#eeeeee',\n A400: '#bdbdbd',\n A700: '#616161'\n};\nexport default grey;","const purple = {\n 50: '#f3e5f5',\n 100: '#e1bee7',\n 200: '#ce93d8',\n 300: '#ba68c8',\n 400: '#ab47bc',\n 500: '#9c27b0',\n 600: '#8e24aa',\n 700: '#7b1fa2',\n 800: '#6a1b9a',\n 900: '#4a148c',\n A100: '#ea80fc',\n A200: '#e040fb',\n A400: '#d500f9',\n A700: '#aa00ff'\n};\nexport default purple;","const red = {\n 50: '#ffebee',\n 100: '#ffcdd2',\n 200: '#ef9a9a',\n 300: '#e57373',\n 400: '#ef5350',\n 500: '#f44336',\n 600: '#e53935',\n 700: '#d32f2f',\n 800: '#c62828',\n 900: '#b71c1c',\n A100: '#ff8a80',\n A200: '#ff5252',\n A400: '#ff1744',\n A700: '#d50000'\n};\nexport default red;","const orange = {\n 50: '#fff3e0',\n 100: '#ffe0b2',\n 200: '#ffcc80',\n 300: '#ffb74d',\n 400: '#ffa726',\n 500: '#ff9800',\n 600: '#fb8c00',\n 700: '#f57c00',\n 800: '#ef6c00',\n 900: '#e65100',\n A100: '#ffd180',\n A200: '#ffab40',\n A400: '#ff9100',\n A700: '#ff6d00'\n};\nexport default orange;","const blue = {\n 50: '#e3f2fd',\n 100: '#bbdefb',\n 200: '#90caf9',\n 300: '#64b5f6',\n 400: '#42a5f5',\n 500: '#2196f3',\n 600: '#1e88e5',\n 700: '#1976d2',\n 800: '#1565c0',\n 900: '#0d47a1',\n A100: '#82b1ff',\n A200: '#448aff',\n A400: '#2979ff',\n A700: '#2962ff'\n};\nexport default blue;","const lightBlue = {\n 50: '#e1f5fe',\n 100: '#b3e5fc',\n 200: '#81d4fa',\n 300: '#4fc3f7',\n 400: '#29b6f6',\n 500: '#03a9f4',\n 600: '#039be5',\n 700: '#0288d1',\n 800: '#0277bd',\n 900: '#01579b',\n A100: '#80d8ff',\n A200: '#40c4ff',\n A400: '#00b0ff',\n A700: '#0091ea'\n};\nexport default lightBlue;","const green = {\n 50: '#e8f5e9',\n 100: '#c8e6c9',\n 200: '#a5d6a7',\n 300: '#81c784',\n 400: '#66bb6a',\n 500: '#4caf50',\n 600: '#43a047',\n 700: '#388e3c',\n 800: '#2e7d32',\n 900: '#1b5e20',\n A100: '#b9f6ca',\n A200: '#69f0ae',\n A400: '#00e676',\n A700: '#00c853'\n};\nexport default green;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\nconst _excluded = [\"mode\", \"contrastThreshold\", \"tonalOffset\"];\nimport { deepmerge } from '@mui/utils';\nimport { darken, getContrastRatio, lighten } from '@mui/system';\nimport common from '../colors/common';\nimport grey from '../colors/grey';\nimport purple from '../colors/purple';\nimport red from '../colors/red';\nimport orange from '../colors/orange';\nimport blue from '../colors/blue';\nimport lightBlue from '../colors/lightBlue';\nimport green from '../colors/green';\nexport const light = {\n // The colors used to style the text.\n text: {\n // The most important text.\n primary: 'rgba(0, 0, 0, 0.87)',\n // Secondary text.\n secondary: 'rgba(0, 0, 0, 0.6)',\n // Disabled text have even lower visual prominence.\n disabled: 'rgba(0, 0, 0, 0.38)'\n },\n // The color used to divide different elements.\n divider: 'rgba(0, 0, 0, 0.12)',\n // The background colors used to style the surfaces.\n // Consistency between these values is important.\n background: {\n paper: common.white,\n default: common.white\n },\n // The colors used to style the action elements.\n action: {\n // The color of an active action like an icon button.\n active: 'rgba(0, 0, 0, 0.54)',\n // The color of an hovered action.\n hover: 'rgba(0, 0, 0, 0.04)',\n hoverOpacity: 0.04,\n // The color of a selected action.\n selected: 'rgba(0, 0, 0, 0.08)',\n selectedOpacity: 0.08,\n // The color of a disabled action.\n disabled: 'rgba(0, 0, 0, 0.26)',\n // The background color of a disabled action.\n disabledBackground: 'rgba(0, 0, 0, 0.12)',\n disabledOpacity: 0.38,\n focus: 'rgba(0, 0, 0, 0.12)',\n focusOpacity: 0.12,\n activatedOpacity: 0.12\n }\n};\nexport const dark = {\n text: {\n primary: common.white,\n secondary: 'rgba(255, 255, 255, 0.7)',\n disabled: 'rgba(255, 255, 255, 0.5)',\n icon: 'rgba(255, 255, 255, 0.5)'\n },\n divider: 'rgba(255, 255, 255, 0.12)',\n background: {\n paper: '#121212',\n default: '#121212'\n },\n action: {\n active: common.white,\n hover: 'rgba(255, 255, 255, 0.08)',\n hoverOpacity: 0.08,\n selected: 'rgba(255, 255, 255, 0.16)',\n selectedOpacity: 0.16,\n disabled: 'rgba(255, 255, 255, 0.3)',\n disabledBackground: 'rgba(255, 255, 255, 0.12)',\n disabledOpacity: 0.38,\n focus: 'rgba(255, 255, 255, 0.12)',\n focusOpacity: 0.12,\n activatedOpacity: 0.24\n }\n};\nfunction addLightOrDark(intent, direction, shade, tonalOffset) {\n const tonalOffsetLight = tonalOffset.light || tonalOffset;\n const tonalOffsetDark = tonalOffset.dark || tonalOffset * 1.5;\n if (!intent[direction]) {\n if (intent.hasOwnProperty(shade)) {\n intent[direction] = intent[shade];\n } else if (direction === 'light') {\n intent.light = lighten(intent.main, tonalOffsetLight);\n } else if (direction === 'dark') {\n intent.dark = darken(intent.main, tonalOffsetDark);\n }\n }\n}\nfunction getDefaultPrimary(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: blue[200],\n light: blue[50],\n dark: blue[400]\n };\n }\n return {\n main: blue[700],\n light: blue[400],\n dark: blue[800]\n };\n}\nfunction getDefaultSecondary(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: purple[200],\n light: purple[50],\n dark: purple[400]\n };\n }\n return {\n main: purple[500],\n light: purple[300],\n dark: purple[700]\n };\n}\nfunction getDefaultError(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: red[500],\n light: red[300],\n dark: red[700]\n };\n }\n return {\n main: red[700],\n light: red[400],\n dark: red[800]\n };\n}\nfunction getDefaultInfo(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: lightBlue[400],\n light: lightBlue[300],\n dark: lightBlue[700]\n };\n }\n return {\n main: lightBlue[700],\n light: lightBlue[500],\n dark: lightBlue[900]\n };\n}\nfunction getDefaultSuccess(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: green[400],\n light: green[300],\n dark: green[700]\n };\n }\n return {\n main: green[800],\n light: green[500],\n dark: green[900]\n };\n}\nfunction getDefaultWarning(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: orange[400],\n light: orange[300],\n dark: orange[700]\n };\n }\n return {\n main: '#ed6c02',\n // closest to orange[800] that pass 3:1.\n light: orange[500],\n dark: orange[900]\n };\n}\nexport default function createPalette(palette) {\n const {\n mode = 'light',\n contrastThreshold = 3,\n tonalOffset = 0.2\n } = palette,\n other = _objectWithoutPropertiesLoose(palette, _excluded);\n const primary = palette.primary || getDefaultPrimary(mode);\n const secondary = palette.secondary || getDefaultSecondary(mode);\n const error = palette.error || getDefaultError(mode);\n const info = palette.info || getDefaultInfo(mode);\n const success = palette.success || getDefaultSuccess(mode);\n const warning = palette.warning || getDefaultWarning(mode);\n\n // Use the same logic as\n // Bootstrap: https://github.com/twbs/bootstrap/blob/1d6e3710dd447de1a200f29e8fa521f8a0908f70/scss/_functions.scss#L59\n // and material-components-web https://github.com/material-components/material-components-web/blob/ac46b8863c4dab9fc22c4c662dc6bd1b65dd652f/packages/mdc-theme/_functions.scss#L54\n function getContrastText(background) {\n const contrastText = getContrastRatio(background, dark.text.primary) >= contrastThreshold ? dark.text.primary : light.text.primary;\n if (process.env.NODE_ENV !== 'production') {\n const contrast = getContrastRatio(background, contrastText);\n if (contrast < 3) {\n console.error([`MUI: The contrast ratio of ${contrast}:1 for ${contrastText} on ${background}`, 'falls below the WCAG recommended absolute minimum contrast ratio of 3:1.', 'https://www.w3.org/TR/2008/REC-WCAG20-20081211/#visual-audio-contrast-contrast'].join('\\n'));\n }\n }\n return contrastText;\n }\n const augmentColor = ({\n color,\n name,\n mainShade = 500,\n lightShade = 300,\n darkShade = 700\n }) => {\n color = _extends({}, color);\n if (!color.main && color[mainShade]) {\n color.main = color[mainShade];\n }\n if (!color.hasOwnProperty('main')) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: The color${name ? ` (${name})` : ''} provided to augmentColor(color) is invalid.\nThe color object needs to have a \\`main\\` property or a \\`${mainShade}\\` property.` : _formatMuiErrorMessage(11, name ? ` (${name})` : '', mainShade));\n }\n if (typeof color.main !== 'string') {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: The color${name ? ` (${name})` : ''} provided to augmentColor(color) is invalid.\n\\`color.main\\` should be a string, but \\`${JSON.stringify(color.main)}\\` was provided instead.\n\nDid you intend to use one of the following approaches?\n\nimport { green } from \"@mui/material/colors\";\n\nconst theme1 = createTheme({ palette: {\n primary: green,\n} });\n\nconst theme2 = createTheme({ palette: {\n primary: { main: green[500] },\n} });` : _formatMuiErrorMessage(12, name ? ` (${name})` : '', JSON.stringify(color.main)));\n }\n addLightOrDark(color, 'light', lightShade, tonalOffset);\n addLightOrDark(color, 'dark', darkShade, tonalOffset);\n if (!color.contrastText) {\n color.contrastText = getContrastText(color.main);\n }\n return color;\n };\n const modes = {\n dark,\n light\n };\n if (process.env.NODE_ENV !== 'production') {\n if (!modes[mode]) {\n console.error(`MUI: The palette mode \\`${mode}\\` is not supported.`);\n }\n }\n const paletteOutput = deepmerge(_extends({\n // A collection of common colors.\n common: _extends({}, common),\n // prevent mutable object.\n // The palette mode, can be light or dark.\n mode,\n // The colors used to represent primary interface elements for a user.\n primary: augmentColor({\n color: primary,\n name: 'primary'\n }),\n // The colors used to represent secondary interface elements for a user.\n secondary: augmentColor({\n color: secondary,\n name: 'secondary',\n mainShade: 'A400',\n lightShade: 'A200',\n darkShade: 'A700'\n }),\n // The colors used to represent interface elements that the user should be made aware of.\n error: augmentColor({\n color: error,\n name: 'error'\n }),\n // The colors used to represent potentially dangerous actions or important messages.\n warning: augmentColor({\n color: warning,\n name: 'warning'\n }),\n // The colors used to present information to the user that is neutral and not necessarily important.\n info: augmentColor({\n color: info,\n name: 'info'\n }),\n // The colors used to indicate the successful completion of an action that user triggered.\n success: augmentColor({\n color: success,\n name: 'success'\n }),\n // The grey colors.\n grey,\n // Used by `getContrastText()` to maximize the contrast between\n // the background and the text.\n contrastThreshold,\n // Takes a background color and returns the text color that maximizes the contrast.\n getContrastText,\n // Generate a rich color object.\n augmentColor,\n // Used by the functions below to shift a color's luminance by approximately\n // two indexes within its tonal palette.\n // E.g., shift from Red 500 to Red 300 or Red 700.\n tonalOffset\n }, modes[mode]), other);\n return paletteOutput;\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"fontFamily\", \"fontSize\", \"fontWeightLight\", \"fontWeightRegular\", \"fontWeightMedium\", \"fontWeightBold\", \"htmlFontSize\", \"allVariants\", \"pxToRem\"];\nimport { deepmerge } from '@mui/utils';\nfunction round(value) {\n return Math.round(value * 1e5) / 1e5;\n}\nconst caseAllCaps = {\n textTransform: 'uppercase'\n};\nconst defaultFontFamily = '\"Roboto\", \"Helvetica\", \"Arial\", sans-serif';\n\n/**\n * @see @link{https://m2.material.io/design/typography/the-type-system.html}\n * @see @link{https://m2.material.io/design/typography/understanding-typography.html}\n */\nexport default function createTypography(palette, typography) {\n const _ref = typeof typography === 'function' ? typography(palette) : typography,\n {\n fontFamily = defaultFontFamily,\n // The default font size of the Material Specification.\n fontSize = 14,\n // px\n fontWeightLight = 300,\n fontWeightRegular = 400,\n fontWeightMedium = 500,\n fontWeightBold = 700,\n // Tell MUI what's the font-size on the html element.\n // 16px is the default font-size used by browsers.\n htmlFontSize = 16,\n // Apply the CSS properties to all the variants.\n allVariants,\n pxToRem: pxToRem2\n } = _ref,\n other = _objectWithoutPropertiesLoose(_ref, _excluded);\n if (process.env.NODE_ENV !== 'production') {\n if (typeof fontSize !== 'number') {\n console.error('MUI: `fontSize` is required to be a number.');\n }\n if (typeof htmlFontSize !== 'number') {\n console.error('MUI: `htmlFontSize` is required to be a number.');\n }\n }\n const coef = fontSize / 14;\n const pxToRem = pxToRem2 || (size => `${size / htmlFontSize * coef}rem`);\n const buildVariant = (fontWeight, size, lineHeight, letterSpacing, casing) => _extends({\n fontFamily,\n fontWeight,\n fontSize: pxToRem(size),\n // Unitless following https://meyerweb.com/eric/thoughts/2006/02/08/unitless-line-heights/\n lineHeight\n }, fontFamily === defaultFontFamily ? {\n letterSpacing: `${round(letterSpacing / size)}em`\n } : {}, casing, allVariants);\n const variants = {\n h1: buildVariant(fontWeightLight, 96, 1.167, -1.5),\n h2: buildVariant(fontWeightLight, 60, 1.2, -0.5),\n h3: buildVariant(fontWeightRegular, 48, 1.167, 0),\n h4: buildVariant(fontWeightRegular, 34, 1.235, 0.25),\n h5: buildVariant(fontWeightRegular, 24, 1.334, 0),\n h6: buildVariant(fontWeightMedium, 20, 1.6, 0.15),\n subtitle1: buildVariant(fontWeightRegular, 16, 1.75, 0.15),\n subtitle2: buildVariant(fontWeightMedium, 14, 1.57, 0.1),\n body1: buildVariant(fontWeightRegular, 16, 1.5, 0.15),\n body2: buildVariant(fontWeightRegular, 14, 1.43, 0.15),\n button: buildVariant(fontWeightMedium, 14, 1.75, 0.4, caseAllCaps),\n caption: buildVariant(fontWeightRegular, 12, 1.66, 0.4),\n overline: buildVariant(fontWeightRegular, 12, 2.66, 1, caseAllCaps),\n // TODO v6: Remove handling of 'inherit' variant from the theme as it is already handled in Material UI's Typography component. Also, remember to remove the associated types.\n inherit: {\n fontFamily: 'inherit',\n fontWeight: 'inherit',\n fontSize: 'inherit',\n lineHeight: 'inherit',\n letterSpacing: 'inherit'\n }\n };\n return deepmerge(_extends({\n htmlFontSize,\n pxToRem,\n fontFamily,\n fontSize,\n fontWeightLight,\n fontWeightRegular,\n fontWeightMedium,\n fontWeightBold\n }, variants), other, {\n clone: false // No need to clone deep\n });\n}","const shadowKeyUmbraOpacity = 0.2;\nconst shadowKeyPenumbraOpacity = 0.14;\nconst shadowAmbientShadowOpacity = 0.12;\nfunction createShadow(...px) {\n return [`${px[0]}px ${px[1]}px ${px[2]}px ${px[3]}px rgba(0,0,0,${shadowKeyUmbraOpacity})`, `${px[4]}px ${px[5]}px ${px[6]}px ${px[7]}px rgba(0,0,0,${shadowKeyPenumbraOpacity})`, `${px[8]}px ${px[9]}px ${px[10]}px ${px[11]}px rgba(0,0,0,${shadowAmbientShadowOpacity})`].join(',');\n}\n\n// Values from https://github.com/material-components/material-components-web/blob/be8747f94574669cb5e7add1a7c54fa41a89cec7/packages/mdc-elevation/_variables.scss\nconst shadows = ['none', createShadow(0, 2, 1, -1, 0, 1, 1, 0, 0, 1, 3, 0), createShadow(0, 3, 1, -2, 0, 2, 2, 0, 0, 1, 5, 0), createShadow(0, 3, 3, -2, 0, 3, 4, 0, 0, 1, 8, 0), createShadow(0, 2, 4, -1, 0, 4, 5, 0, 0, 1, 10, 0), createShadow(0, 3, 5, -1, 0, 5, 8, 0, 0, 1, 14, 0), createShadow(0, 3, 5, -1, 0, 6, 10, 0, 0, 1, 18, 0), createShadow(0, 4, 5, -2, 0, 7, 10, 1, 0, 2, 16, 1), createShadow(0, 5, 5, -3, 0, 8, 10, 1, 0, 3, 14, 2), createShadow(0, 5, 6, -3, 0, 9, 12, 1, 0, 3, 16, 2), createShadow(0, 6, 6, -3, 0, 10, 14, 1, 0, 4, 18, 3), createShadow(0, 6, 7, -4, 0, 11, 15, 1, 0, 4, 20, 3), createShadow(0, 7, 8, -4, 0, 12, 17, 2, 0, 5, 22, 4), createShadow(0, 7, 8, -4, 0, 13, 19, 2, 0, 5, 24, 4), createShadow(0, 7, 9, -4, 0, 14, 21, 2, 0, 5, 26, 4), createShadow(0, 8, 9, -5, 0, 15, 22, 2, 0, 6, 28, 5), createShadow(0, 8, 10, -5, 0, 16, 24, 2, 0, 6, 30, 5), createShadow(0, 8, 11, -5, 0, 17, 26, 2, 0, 6, 32, 5), createShadow(0, 9, 11, -5, 0, 18, 28, 2, 0, 7, 34, 6), createShadow(0, 9, 12, -6, 0, 19, 29, 2, 0, 7, 36, 6), createShadow(0, 10, 13, -6, 0, 20, 31, 3, 0, 8, 38, 7), createShadow(0, 10, 13, -6, 0, 21, 33, 3, 0, 8, 40, 7), createShadow(0, 10, 14, -6, 0, 22, 35, 3, 0, 8, 42, 7), createShadow(0, 11, 14, -7, 0, 23, 36, 3, 0, 9, 44, 8), createShadow(0, 11, 15, -7, 0, 24, 38, 3, 0, 9, 46, 8)];\nexport default shadows;","import _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nconst _excluded = [\"duration\", \"easing\", \"delay\"];\n// Follow https://material.google.com/motion/duration-easing.html#duration-easing-natural-easing-curves\n// to learn the context in which each easing should be used.\nexport const easing = {\n // This is the most common easing curve.\n easeInOut: 'cubic-bezier(0.4, 0, 0.2, 1)',\n // Objects enter the screen at full velocity from off-screen and\n // slowly decelerate to a resting point.\n easeOut: 'cubic-bezier(0.0, 0, 0.2, 1)',\n // Objects leave the screen at full velocity. They do not decelerate when off-screen.\n easeIn: 'cubic-bezier(0.4, 0, 1, 1)',\n // The sharp curve is used by objects that may return to the screen at any time.\n sharp: 'cubic-bezier(0.4, 0, 0.6, 1)'\n};\n\n// Follow https://m2.material.io/guidelines/motion/duration-easing.html#duration-easing-common-durations\n// to learn when use what timing\nexport const duration = {\n shortest: 150,\n shorter: 200,\n short: 250,\n // most basic recommended timing\n standard: 300,\n // this is to be used in complex animations\n complex: 375,\n // recommended when something is entering screen\n enteringScreen: 225,\n // recommended when something is leaving screen\n leavingScreen: 195\n};\nfunction formatMs(milliseconds) {\n return `${Math.round(milliseconds)}ms`;\n}\nfunction getAutoHeightDuration(height) {\n if (!height) {\n return 0;\n }\n const constant = height / 36;\n\n // https://www.wolframalpha.com/input/?i=(4+%2B+15+*+(x+%2F+36+)+**+0.25+%2B+(x+%2F+36)+%2F+5)+*+10\n return Math.round((4 + 15 * constant ** 0.25 + constant / 5) * 10);\n}\nexport default function createTransitions(inputTransitions) {\n const mergedEasing = _extends({}, easing, inputTransitions.easing);\n const mergedDuration = _extends({}, duration, inputTransitions.duration);\n const create = (props = ['all'], options = {}) => {\n const {\n duration: durationOption = mergedDuration.standard,\n easing: easingOption = mergedEasing.easeInOut,\n delay = 0\n } = options,\n other = _objectWithoutPropertiesLoose(options, _excluded);\n if (process.env.NODE_ENV !== 'production') {\n const isString = value => typeof value === 'string';\n // IE11 support, replace with Number.isNaN\n // eslint-disable-next-line no-restricted-globals\n const isNumber = value => !isNaN(parseFloat(value));\n if (!isString(props) && !Array.isArray(props)) {\n console.error('MUI: Argument \"props\" must be a string or Array.');\n }\n if (!isNumber(durationOption) && !isString(durationOption)) {\n console.error(`MUI: Argument \"duration\" must be a number or a string but found ${durationOption}.`);\n }\n if (!isString(easingOption)) {\n console.error('MUI: Argument \"easing\" must be a string.');\n }\n if (!isNumber(delay) && !isString(delay)) {\n console.error('MUI: Argument \"delay\" must be a number or a string.');\n }\n if (typeof options !== 'object') {\n console.error(['MUI: Secong argument of transition.create must be an object.', \"Arguments should be either `create('prop1', options)` or `create(['prop1', 'prop2'], options)`\"].join('\\n'));\n }\n if (Object.keys(other).length !== 0) {\n console.error(`MUI: Unrecognized argument(s) [${Object.keys(other).join(',')}].`);\n }\n }\n return (Array.isArray(props) ? props : [props]).map(animatedProp => `${animatedProp} ${typeof durationOption === 'string' ? durationOption : formatMs(durationOption)} ${easingOption} ${typeof delay === 'string' ? delay : formatMs(delay)}`).join(',');\n };\n return _extends({\n getAutoHeightDuration,\n create\n }, inputTransitions, {\n easing: mergedEasing,\n duration: mergedDuration\n });\n}","// We need to centralize the zIndex definitions as they work\n// like global values in the browser.\nconst zIndex = {\n mobileStepper: 1000,\n fab: 1050,\n speedDial: 1050,\n appBar: 1100,\n drawer: 1200,\n modal: 1300,\n snackbar: 1400,\n tooltip: 1500\n};\nexport default zIndex;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\nconst _excluded = [\"breakpoints\", \"mixins\", \"spacing\", \"palette\", \"transitions\", \"typography\", \"shape\"];\nimport { deepmerge } from '@mui/utils';\nimport { createTheme as systemCreateTheme, unstable_defaultSxConfig as defaultSxConfig, unstable_styleFunctionSx as styleFunctionSx } from '@mui/system';\nimport generateUtilityClass from '@mui/utils/generateUtilityClass';\nimport createMixins from './createMixins';\nimport createPalette from './createPalette';\nimport createTypography from './createTypography';\nimport shadows from './shadows';\nimport createTransitions from './createTransitions';\nimport zIndex from './zIndex';\nfunction createTheme(options = {}, ...args) {\n const {\n mixins: mixinsInput = {},\n palette: paletteInput = {},\n transitions: transitionsInput = {},\n typography: typographyInput = {}\n } = options,\n other = _objectWithoutPropertiesLoose(options, _excluded);\n if (options.vars) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: \\`vars\\` is a private field used for CSS variables support.\nPlease use another name.` : _formatMuiErrorMessage(18));\n }\n const palette = createPalette(paletteInput);\n const systemTheme = systemCreateTheme(options);\n let muiTheme = deepmerge(systemTheme, {\n mixins: createMixins(systemTheme.breakpoints, mixinsInput),\n palette,\n // Don't use [...shadows] until you've verified its transpiled code is not invoking the iterator protocol.\n shadows: shadows.slice(),\n typography: createTypography(palette, typographyInput),\n transitions: createTransitions(transitionsInput),\n zIndex: _extends({}, zIndex)\n });\n muiTheme = deepmerge(muiTheme, other);\n muiTheme = args.reduce((acc, argument) => deepmerge(acc, argument), muiTheme);\n if (process.env.NODE_ENV !== 'production') {\n // TODO v6: Refactor to use globalStateClassesMapping from @mui/utils once `readOnly` state class is used in Rating component.\n const stateClasses = ['active', 'checked', 'completed', 'disabled', 'error', 'expanded', 'focused', 'focusVisible', 'required', 'selected'];\n const traverse = (node, component) => {\n let key;\n\n // eslint-disable-next-line guard-for-in, no-restricted-syntax\n for (key in node) {\n const child = node[key];\n if (stateClasses.indexOf(key) !== -1 && Object.keys(child).length > 0) {\n if (process.env.NODE_ENV !== 'production') {\n const stateClass = generateUtilityClass('', key);\n console.error([`MUI: The \\`${component}\\` component increases ` + `the CSS specificity of the \\`${key}\\` internal state.`, 'You can not override it like this: ', JSON.stringify(node, null, 2), '', `Instead, you need to use the '&.${stateClass}' syntax:`, JSON.stringify({\n root: {\n [`&.${stateClass}`]: child\n }\n }, null, 2), '', 'https://mui.com/r/state-classes-guide'].join('\\n'));\n }\n // Remove the style to prevent global conflicts.\n node[key] = {};\n }\n }\n };\n Object.keys(muiTheme.components).forEach(component => {\n const styleOverrides = muiTheme.components[component].styleOverrides;\n if (styleOverrides && component.indexOf('Mui') === 0) {\n traverse(styleOverrides, component);\n }\n });\n }\n muiTheme.unstable_sxConfig = _extends({}, defaultSxConfig, other == null ? void 0 : other.unstable_sxConfig);\n muiTheme.unstable_sx = function sx(props) {\n return styleFunctionSx({\n sx: props,\n theme: this\n });\n };\n return muiTheme;\n}\nlet warnedOnce = false;\nexport function createMuiTheme(...args) {\n if (process.env.NODE_ENV !== 'production') {\n if (!warnedOnce) {\n warnedOnce = true;\n console.error(['MUI: the createMuiTheme function was renamed to createTheme.', '', \"You should use `import { createTheme } from '@mui/material/styles'`\"].join('\\n'));\n }\n }\n return createTheme(...args);\n}\nexport default createTheme;","'use client';\n\nimport createTheme from './createTheme';\nconst defaultTheme = createTheme();\nexport default defaultTheme;","export default '$$material';","'use client';\n\nimport { useThemeProps as systemUseThemeProps } from '@mui/system';\nimport defaultTheme from './defaultTheme';\nimport THEME_ID from './identifier';\nexport default function useThemeProps({\n props,\n name\n}) {\n return systemUseThemeProps({\n props,\n name,\n defaultTheme,\n themeId: THEME_ID\n });\n}","'use client';\n\nimport { createStyled, shouldForwardProp } from '@mui/system';\nimport defaultTheme from './defaultTheme';\nimport THEME_ID from './identifier';\nexport const rootShouldForwardProp = prop => shouldForwardProp(prop) && prop !== 'classes';\nexport const slotShouldForwardProp = shouldForwardProp;\nconst styled = createStyled({\n themeId: THEME_ID,\n defaultTheme,\n rootShouldForwardProp\n});\nexport default styled;","import generateUtilityClasses from '@mui/utils/generateUtilityClasses';\nimport generateUtilityClass from '@mui/utils/generateUtilityClass';\nexport function getSvgIconUtilityClass(slot) {\n return generateUtilityClass('MuiSvgIcon', slot);\n}\nconst svgIconClasses = generateUtilityClasses('MuiSvgIcon', ['root', 'colorPrimary', 'colorSecondary', 'colorAction', 'colorError', 'colorDisabled', 'fontSizeInherit', 'fontSizeSmall', 'fontSizeMedium', 'fontSizeLarge']);\nexport default svgIconClasses;","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"children\", \"className\", \"color\", \"component\", \"fontSize\", \"htmlColor\", \"inheritViewBox\", \"titleAccess\", \"viewBox\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport clsx from 'clsx';\nimport { unstable_composeClasses as composeClasses } from '@mui/base/composeClasses';\nimport capitalize from '../utils/capitalize';\nimport useThemeProps from '../styles/useThemeProps';\nimport styled from '../styles/styled';\nimport { getSvgIconUtilityClass } from './svgIconClasses';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nimport { jsxs as _jsxs } from \"react/jsx-runtime\";\nconst useUtilityClasses = ownerState => {\n const {\n color,\n fontSize,\n classes\n } = ownerState;\n const slots = {\n root: ['root', color !== 'inherit' && `color${capitalize(color)}`, `fontSize${capitalize(fontSize)}`]\n };\n return composeClasses(slots, getSvgIconUtilityClass, classes);\n};\nconst SvgIconRoot = styled('svg', {\n name: 'MuiSvgIcon',\n slot: 'Root',\n overridesResolver: (props, styles) => {\n const {\n ownerState\n } = props;\n return [styles.root, ownerState.color !== 'inherit' && styles[`color${capitalize(ownerState.color)}`], styles[`fontSize${capitalize(ownerState.fontSize)}`]];\n }\n})(({\n theme,\n ownerState\n}) => {\n var _theme$transitions, _theme$transitions$cr, _theme$transitions2, _theme$typography, _theme$typography$pxT, _theme$typography2, _theme$typography2$px, _theme$typography3, _theme$typography3$px, _palette$ownerState$c, _palette, _palette2, _palette3;\n return {\n userSelect: 'none',\n width: '1em',\n height: '1em',\n display: 'inline-block',\n // the will define the property that has `currentColor`\n // e.g. heroicons uses fill=\"none\" and stroke=\"currentColor\"\n fill: ownerState.hasSvgAsChild ? undefined : 'currentColor',\n flexShrink: 0,\n transition: (_theme$transitions = theme.transitions) == null || (_theme$transitions$cr = _theme$transitions.create) == null ? void 0 : _theme$transitions$cr.call(_theme$transitions, 'fill', {\n duration: (_theme$transitions2 = theme.transitions) == null || (_theme$transitions2 = _theme$transitions2.duration) == null ? void 0 : _theme$transitions2.shorter\n }),\n fontSize: {\n inherit: 'inherit',\n small: ((_theme$typography = theme.typography) == null || (_theme$typography$pxT = _theme$typography.pxToRem) == null ? void 0 : _theme$typography$pxT.call(_theme$typography, 20)) || '1.25rem',\n medium: ((_theme$typography2 = theme.typography) == null || (_theme$typography2$px = _theme$typography2.pxToRem) == null ? void 0 : _theme$typography2$px.call(_theme$typography2, 24)) || '1.5rem',\n large: ((_theme$typography3 = theme.typography) == null || (_theme$typography3$px = _theme$typography3.pxToRem) == null ? void 0 : _theme$typography3$px.call(_theme$typography3, 35)) || '2.1875rem'\n }[ownerState.fontSize],\n // TODO v5 deprecate, v6 remove for sx\n color: (_palette$ownerState$c = (_palette = (theme.vars || theme).palette) == null || (_palette = _palette[ownerState.color]) == null ? void 0 : _palette.main) != null ? _palette$ownerState$c : {\n action: (_palette2 = (theme.vars || theme).palette) == null || (_palette2 = _palette2.action) == null ? void 0 : _palette2.active,\n disabled: (_palette3 = (theme.vars || theme).palette) == null || (_palette3 = _palette3.action) == null ? void 0 : _palette3.disabled,\n inherit: undefined\n }[ownerState.color]\n };\n});\nconst SvgIcon = /*#__PURE__*/React.forwardRef(function SvgIcon(inProps, ref) {\n const props = useThemeProps({\n props: inProps,\n name: 'MuiSvgIcon'\n });\n const {\n children,\n className,\n color = 'inherit',\n component = 'svg',\n fontSize = 'medium',\n htmlColor,\n inheritViewBox = false,\n titleAccess,\n viewBox = '0 0 24 24'\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const hasSvgAsChild = /*#__PURE__*/React.isValidElement(children) && children.type === 'svg';\n const ownerState = _extends({}, props, {\n color,\n component,\n fontSize,\n instanceFontSize: inProps.fontSize,\n inheritViewBox,\n viewBox,\n hasSvgAsChild\n });\n const more = {};\n if (!inheritViewBox) {\n more.viewBox = viewBox;\n }\n const classes = useUtilityClasses(ownerState);\n return /*#__PURE__*/_jsxs(SvgIconRoot, _extends({\n as: component,\n className: clsx(classes.root, className),\n focusable: \"false\",\n color: htmlColor,\n \"aria-hidden\": titleAccess ? undefined : true,\n role: titleAccess ? 'img' : undefined,\n ref: ref\n }, more, other, hasSvgAsChild && children.props, {\n ownerState: ownerState,\n children: [hasSvgAsChild ? children.props.children : children, titleAccess ? /*#__PURE__*/_jsx(\"title\", {\n children: titleAccess\n }) : null]\n }));\n});\nprocess.env.NODE_ENV !== \"production\" ? SvgIcon.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the d.ts file and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * Node passed into the SVG element.\n */\n children: PropTypes.node,\n /**\n * Override or extend the styles applied to the component.\n */\n classes: PropTypes.object,\n /**\n * @ignore\n */\n className: PropTypes.string,\n /**\n * The color of the component.\n * It supports both default and custom theme colors, which can be added as shown in the\n * [palette customization guide](https://mui.com/material-ui/customization/palette/#custom-colors).\n * You can use the `htmlColor` prop to apply a color attribute to the SVG element.\n * @default 'inherit'\n */\n color: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.oneOf(['inherit', 'action', 'disabled', 'primary', 'secondary', 'error', 'info', 'success', 'warning']), PropTypes.string]),\n /**\n * The component used for the root node.\n * Either a string to use a HTML element or a component.\n */\n component: PropTypes.elementType,\n /**\n * The fontSize applied to the icon. Defaults to 24px, but can be configure to inherit font size.\n * @default 'medium'\n */\n fontSize: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.oneOf(['inherit', 'large', 'medium', 'small']), PropTypes.string]),\n /**\n * Applies a color attribute to the SVG element.\n */\n htmlColor: PropTypes.string,\n /**\n * If `true`, the root node will inherit the custom `component`'s viewBox and the `viewBox`\n * prop will be ignored.\n * Useful when you want to reference a custom `component` and have `SvgIcon` pass that\n * `component`'s viewBox to the root node.\n * @default false\n */\n inheritViewBox: PropTypes.bool,\n /**\n * The shape-rendering attribute. The behavior of the different options is described on the\n * [MDN Web Docs](https://developer.mozilla.org/en-US/docs/Web/SVG/Attribute/shape-rendering).\n * If you are having issues with blurry icons you should investigate this prop.\n */\n shapeRendering: PropTypes.string,\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Provides a human-readable title for the element that contains it.\n * https://www.w3.org/TR/SVG-access/#Equivalent\n */\n titleAccess: PropTypes.string,\n /**\n * Allows you to redefine what the coordinates without units mean inside an SVG element.\n * For example, if the SVG element is 500 (width) by 200 (height),\n * and you pass viewBox=\"0 0 50 20\",\n * this means that the coordinates inside the SVG will go from the top left corner (0,0)\n * to bottom right (50,20) and each unit will be worth 10px.\n * @default '0 0 24 24'\n */\n viewBox: PropTypes.string\n} : void 0;\nSvgIcon.muiName = 'SvgIcon';\nexport default SvgIcon;","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport * as React from 'react';\nimport SvgIcon from '../SvgIcon';\n\n/**\n * Private module reserved for @mui packages.\n */\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nexport default function createSvgIcon(path, displayName) {\n function Component(props, ref) {\n return /*#__PURE__*/_jsx(SvgIcon, _extends({\n \"data-testid\": `${displayName}Icon`,\n ref: ref\n }, props, {\n children: path\n }));\n }\n if (process.env.NODE_ENV !== 'production') {\n // Need to set `displayName` on the inner component for React.memo.\n // React prior to 16.14 ignores `displayName` on the wrapper.\n Component.displayName = `${displayName}Icon`;\n }\n Component.muiName = SvgIcon.muiName;\n return /*#__PURE__*/React.memo( /*#__PURE__*/React.forwardRef(Component));\n}","'use client';\n\nimport { unstable_ClassNameGenerator as ClassNameGenerator } from '@mui/base/ClassNameGenerator';\nexport { default as capitalize } from './capitalize';\nexport { default as createChainedFunction } from './createChainedFunction';\nexport { default as createSvgIcon } from './createSvgIcon';\nexport { default as debounce } from './debounce';\nexport { default as deprecatedPropType } from './deprecatedPropType';\nexport { default as isMuiElement } from './isMuiElement';\nexport { default as ownerDocument } from './ownerDocument';\nexport { default as ownerWindow } from './ownerWindow';\nexport { default as requirePropFactory } from './requirePropFactory';\nexport { default as setRef } from './setRef';\nexport { default as unstable_useEnhancedEffect } from './useEnhancedEffect';\nexport { default as unstable_useId } from './useId';\nexport { default as unsupportedProp } from './unsupportedProp';\nexport { default as useControlled } from './useControlled';\nexport { default as useEventCallback } from './useEventCallback';\nexport { default as useForkRef } from './useForkRef';\nexport { default as useIsFocusVisible } from './useIsFocusVisible';\n// TODO: remove this export once ClassNameGenerator is stable\n// eslint-disable-next-line @typescript-eslint/naming-convention\nexport const unstable_ClassNameGenerator = {\n configure: generator => {\n if (process.env.NODE_ENV !== 'production') {\n console.warn(['MUI: `ClassNameGenerator` import from `@mui/material/utils` is outdated and might cause unexpected issues.', '', \"You should use `import { unstable_ClassNameGenerator } from '@mui/material/className'` instead\", '', 'The detail of the issue: https://github.com/mui/material-ui/issues/30011#issuecomment-1024993401', '', 'The updated documentation: https://mui.com/guides/classname-generator/'].join('\\n'));\n }\n ClassNameGenerator.configure(generator);\n }\n};","\"use strict\";\n'use client';\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nObject.defineProperty(exports, \"default\", {\n enumerable: true,\n get: function () {\n return _utils.createSvgIcon;\n }\n});\nvar _utils = require(\"@mui/material/utils\");","\"use strict\";\n\"use client\";\n\nvar _interopRequireDefault = require(\"@babel/runtime/helpers/interopRequireDefault\");\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = void 0;\nvar _createSvgIcon = _interopRequireDefault(require(\"./utils/createSvgIcon\"));\nvar _jsxRuntime = require(\"react/jsx-runtime\");\nvar _default = exports.default = (0, _createSvgIcon.default)( /*#__PURE__*/(0, _jsxRuntime.jsx)(\"path\", {\n d: \"m10 17 5-5-5-5z\"\n}), 'ArrowRight');","/**\n * Determines if a given element is a DOM element name (i.e. not a React component).\n */\nexport function isHostComponent(element) {\n return typeof element === 'string';\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport { isHostComponent } from './isHostComponent';\n\n/**\n * Type of the ownerState based on the type of an element it applies to.\n * This resolves to the provided OwnerState for React components and `undefined` for host components.\n * Falls back to `OwnerState | undefined` when the exact type can't be determined in development time.\n */\n\n/**\n * Appends the ownerState object to the props, merging with the existing one if necessary.\n *\n * @param elementType Type of the element that owns the `existingProps`. If the element is a DOM node or undefined, `ownerState` is not applied.\n * @param otherProps Props of the element.\n * @param ownerState\n */\nexport function appendOwnerState(elementType, otherProps, ownerState) {\n if (elementType === undefined || isHostComponent(elementType)) {\n return otherProps;\n }\n return _extends({}, otherProps, {\n ownerState: _extends({}, otherProps.ownerState, ownerState)\n });\n}","'use client';\n\nimport * as React from 'react';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nconst defaultContextValue = {\n disableDefaultClasses: false\n};\nconst ClassNameConfiguratorContext = /*#__PURE__*/React.createContext(defaultContextValue);\n/**\n * @ignore - internal hook.\n *\n * Wraps the `generateUtilityClass` function and controls how the classes are generated.\n * Currently it only affects whether the classes are applied or not.\n *\n * @returns Function to be called with the `generateUtilityClass` function specific to a component to generate the classes.\n */\nexport function useClassNamesOverride(generateUtilityClass) {\n const {\n disableDefaultClasses\n } = React.useContext(ClassNameConfiguratorContext);\n return slot => {\n if (disableDefaultClasses) {\n return '';\n }\n return generateUtilityClass(slot);\n };\n}\n\n/**\n * Allows to configure the components within to not apply any built-in classes.\n */\nexport function ClassNameConfigurator(props) {\n const {\n disableDefaultClasses,\n children\n } = props;\n const contextValue = React.useMemo(() => ({\n disableDefaultClasses: disableDefaultClasses != null ? disableDefaultClasses : false\n }), [disableDefaultClasses]);\n return /*#__PURE__*/_jsx(ClassNameConfiguratorContext.Provider, {\n value: contextValue,\n children: children\n });\n}","/**\n * Extracts event handlers from a given object.\n * A prop is considered an event handler if it is a function and its name starts with `on`.\n *\n * @param object An object to extract event handlers from.\n * @param excludeKeys An array of keys to exclude from the returned object.\n */\nexport function extractEventHandlers(object, excludeKeys = []) {\n if (object === undefined) {\n return {};\n }\n const result = {};\n Object.keys(object).filter(prop => prop.match(/^on[A-Z]/) && typeof object[prop] === 'function' && !excludeKeys.includes(prop)).forEach(prop => {\n result[prop] = object[prop];\n });\n return result;\n}","/**\n * If `componentProps` is a function, calls it with the provided `ownerState`.\n * Otherwise, just returns `componentProps`.\n */\nexport function resolveComponentProps(componentProps, ownerState, slotState) {\n if (typeof componentProps === 'function') {\n return componentProps(ownerState, slotState);\n }\n return componentProps;\n}","/**\n * Removes event handlers from the given object.\n * A field is considered an event handler if it is a function with a name beginning with `on`.\n *\n * @param object Object to remove event handlers from.\n * @returns Object with event handlers removed.\n */\nexport function omitEventHandlers(object) {\n if (object === undefined) {\n return {};\n }\n const result = {};\n Object.keys(object).filter(prop => !(prop.match(/^on[A-Z]/) && typeof object[prop] === 'function')).forEach(prop => {\n result[prop] = object[prop];\n });\n return result;\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport clsx from 'clsx';\nimport { extractEventHandlers } from './extractEventHandlers';\nimport { omitEventHandlers } from './omitEventHandlers';\n/**\n * Merges the slot component internal props (usually coming from a hook)\n * with the externally provided ones.\n *\n * The merge order is (the latter overrides the former):\n * 1. The internal props (specified as a getter function to work with get*Props hook result)\n * 2. Additional props (specified internally on a Base UI component)\n * 3. External props specified on the owner component. These should only be used on a root slot.\n * 4. External props specified in the `slotProps.*` prop.\n * 5. The `className` prop - combined from all the above.\n * @param parameters\n * @returns\n */\nexport function mergeSlotProps(parameters) {\n const {\n getSlotProps,\n additionalProps,\n externalSlotProps,\n externalForwardedProps,\n className\n } = parameters;\n if (!getSlotProps) {\n // The simpler case - getSlotProps is not defined, so no internal event handlers are defined,\n // so we can simply merge all the props without having to worry about extracting event handlers.\n const joinedClasses = clsx(additionalProps == null ? void 0 : additionalProps.className, className, externalForwardedProps == null ? void 0 : externalForwardedProps.className, externalSlotProps == null ? void 0 : externalSlotProps.className);\n const mergedStyle = _extends({}, additionalProps == null ? void 0 : additionalProps.style, externalForwardedProps == null ? void 0 : externalForwardedProps.style, externalSlotProps == null ? void 0 : externalSlotProps.style);\n const props = _extends({}, additionalProps, externalForwardedProps, externalSlotProps);\n if (joinedClasses.length > 0) {\n props.className = joinedClasses;\n }\n if (Object.keys(mergedStyle).length > 0) {\n props.style = mergedStyle;\n }\n return {\n props,\n internalRef: undefined\n };\n }\n\n // In this case, getSlotProps is responsible for calling the external event handlers.\n // We don't need to include them in the merged props because of this.\n\n const eventHandlers = extractEventHandlers(_extends({}, externalForwardedProps, externalSlotProps));\n const componentsPropsWithoutEventHandlers = omitEventHandlers(externalSlotProps);\n const otherPropsWithoutEventHandlers = omitEventHandlers(externalForwardedProps);\n const internalSlotProps = getSlotProps(eventHandlers);\n\n // The order of classes is important here.\n // Emotion (that we use in libraries consuming Base UI) depends on this order\n // to properly override style. It requires the most important classes to be last\n // (see https://github.com/mui/material-ui/pull/33205) for the related discussion.\n const joinedClasses = clsx(internalSlotProps == null ? void 0 : internalSlotProps.className, additionalProps == null ? void 0 : additionalProps.className, className, externalForwardedProps == null ? void 0 : externalForwardedProps.className, externalSlotProps == null ? void 0 : externalSlotProps.className);\n const mergedStyle = _extends({}, internalSlotProps == null ? void 0 : internalSlotProps.style, additionalProps == null ? void 0 : additionalProps.style, externalForwardedProps == null ? void 0 : externalForwardedProps.style, externalSlotProps == null ? void 0 : externalSlotProps.style);\n const props = _extends({}, internalSlotProps, additionalProps, otherPropsWithoutEventHandlers, componentsPropsWithoutEventHandlers);\n if (joinedClasses.length > 0) {\n props.className = joinedClasses;\n }\n if (Object.keys(mergedStyle).length > 0) {\n props.style = mergedStyle;\n }\n return {\n props,\n internalRef: internalSlotProps.ref\n };\n}","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"elementType\", \"externalSlotProps\", \"ownerState\", \"skipResolvingSlotProps\"];\nimport { unstable_useForkRef as useForkRef } from '@mui/utils';\nimport { appendOwnerState } from './appendOwnerState';\nimport { mergeSlotProps } from './mergeSlotProps';\nimport { resolveComponentProps } from './resolveComponentProps';\n/**\n * @ignore - do not document.\n * Builds the props to be passed into the slot of an unstyled component.\n * It merges the internal props of the component with the ones supplied by the user, allowing to customize the behavior.\n * If the slot component is not a host component, it also merges in the `ownerState`.\n *\n * @param parameters.getSlotProps - A function that returns the props to be passed to the slot component.\n */\nexport function useSlotProps(parameters) {\n var _parameters$additiona;\n const {\n elementType,\n externalSlotProps,\n ownerState,\n skipResolvingSlotProps = false\n } = parameters,\n rest = _objectWithoutPropertiesLoose(parameters, _excluded);\n const resolvedComponentsProps = skipResolvingSlotProps ? {} : resolveComponentProps(externalSlotProps, ownerState);\n const {\n props: mergedProps,\n internalRef\n } = mergeSlotProps(_extends({}, rest, {\n externalSlotProps: resolvedComponentsProps\n }));\n const ref = useForkRef(internalRef, resolvedComponentsProps == null ? void 0 : resolvedComponentsProps.ref, (_parameters$additiona = parameters.additionalProps) == null ? void 0 : _parameters$additiona.ref);\n const props = appendOwnerState(elementType, _extends({}, mergedProps, {\n ref\n }), ownerState);\n return props;\n}","import { globalStateClasses } from '@mui/utils/generateUtilityClass';\nconst GLOBAL_CLASS_PREFIX = 'base';\nfunction buildStateClass(state) {\n return `${GLOBAL_CLASS_PREFIX}--${state}`;\n}\nfunction buildSlotClass(componentName, slot) {\n return `${GLOBAL_CLASS_PREFIX}-${componentName}-${slot}`;\n}\nexport function generateUtilityClass(componentName, slot) {\n const globalStateClass = globalStateClasses[slot];\n return globalStateClass ? buildStateClass(globalStateClass) : buildSlotClass(componentName, slot);\n}\nexport function isGlobalState(slot) {\n return globalStateClasses[slot] !== undefined;\n}","import { generateUtilityClass } from '../generateUtilityClass';\nexport function generateUtilityClasses(componentName, slots) {\n const result = {};\n slots.forEach(slot => {\n result[slot] = generateUtilityClass(componentName, slot);\n });\n return result;\n}","'use client';\n\nimport * as React from 'react';\nimport * as ReactDOM from 'react-dom';\nimport PropTypes from 'prop-types';\nimport { exactProp, HTMLElementType, unstable_useEnhancedEffect as useEnhancedEffect, unstable_useForkRef as useForkRef, unstable_setRef as setRef } from '@mui/utils';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nfunction getContainer(container) {\n return typeof container === 'function' ? container() : container;\n}\n\n/**\n * Portals provide a first-class way to render children into a DOM node\n * that exists outside the DOM hierarchy of the parent component.\n *\n * Demos:\n *\n * - [Portal](https://mui.com/base-ui/react-portal/)\n *\n * API:\n *\n * - [Portal API](https://mui.com/base-ui/react-portal/components-api/#portal)\n */\nconst Portal = /*#__PURE__*/React.forwardRef(function Portal(props, forwardedRef) {\n const {\n children,\n container,\n disablePortal = false\n } = props;\n const [mountNode, setMountNode] = React.useState(null);\n // @ts-expect-error TODO upstream fix\n const handleRef = useForkRef( /*#__PURE__*/React.isValidElement(children) ? children.ref : null, forwardedRef);\n useEnhancedEffect(() => {\n if (!disablePortal) {\n setMountNode(getContainer(container) || document.body);\n }\n }, [container, disablePortal]);\n useEnhancedEffect(() => {\n if (mountNode && !disablePortal) {\n setRef(forwardedRef, mountNode);\n return () => {\n setRef(forwardedRef, null);\n };\n }\n return undefined;\n }, [forwardedRef, mountNode, disablePortal]);\n if (disablePortal) {\n if ( /*#__PURE__*/React.isValidElement(children)) {\n const newProps = {\n ref: handleRef\n };\n return /*#__PURE__*/React.cloneElement(children, newProps);\n }\n return /*#__PURE__*/_jsx(React.Fragment, {\n children: children\n });\n }\n return /*#__PURE__*/_jsx(React.Fragment, {\n children: mountNode ? /*#__PURE__*/ReactDOM.createPortal(children, mountNode) : mountNode\n });\n});\nprocess.env.NODE_ENV !== \"production\" ? Portal.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * The children to render into the `container`.\n */\n children: PropTypes.node,\n /**\n * An HTML element or function that returns one.\n * The `container` will have the portal children appended to it.\n *\n * You can also provide a callback, which is called in a React layout effect.\n * This lets you set the container from a ref, and also makes server-side rendering possible.\n *\n * By default, it uses the body of the top-level document object,\n * so it's simply `document.body` most of the time.\n */\n container: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.func]),\n /**\n * The `children` will be under the DOM hierarchy of the parent component.\n * @default false\n */\n disablePortal: PropTypes.bool\n} : void 0;\nif (process.env.NODE_ENV !== 'production') {\n // eslint-disable-next-line\n Portal['propTypes' + ''] = exactProp(Portal.propTypes);\n}\nexport { Portal };","export var top = 'top';\nexport var bottom = 'bottom';\nexport var right = 'right';\nexport var left = 'left';\nexport var auto = 'auto';\nexport var basePlacements = [top, bottom, right, left];\nexport var start = 'start';\nexport var end = 'end';\nexport var clippingParents = 'clippingParents';\nexport var viewport = 'viewport';\nexport var popper = 'popper';\nexport var reference = 'reference';\nexport var variationPlacements = /*#__PURE__*/basePlacements.reduce(function (acc, placement) {\n return acc.concat([placement + \"-\" + start, placement + \"-\" + end]);\n}, []);\nexport var placements = /*#__PURE__*/[].concat(basePlacements, [auto]).reduce(function (acc, placement) {\n return acc.concat([placement, placement + \"-\" + start, placement + \"-\" + end]);\n}, []); // modifiers that need to read the DOM\n\nexport var beforeRead = 'beforeRead';\nexport var read = 'read';\nexport var afterRead = 'afterRead'; // pure-logic modifiers\n\nexport var beforeMain = 'beforeMain';\nexport var main = 'main';\nexport var afterMain = 'afterMain'; // modifier with the purpose to write to the DOM (or write into a framework state)\n\nexport var beforeWrite = 'beforeWrite';\nexport var write = 'write';\nexport var afterWrite = 'afterWrite';\nexport var modifierPhases = [beforeRead, read, afterRead, beforeMain, main, afterMain, beforeWrite, write, afterWrite];","export default function getNodeName(element) {\n return element ? (element.nodeName || '').toLowerCase() : null;\n}","export default function getWindow(node) {\n if (node == null) {\n return window;\n }\n\n if (node.toString() !== '[object Window]') {\n var ownerDocument = node.ownerDocument;\n return ownerDocument ? ownerDocument.defaultView || window : window;\n }\n\n return node;\n}","import getWindow from \"./getWindow.js\";\n\nfunction isElement(node) {\n var OwnElement = getWindow(node).Element;\n return node instanceof OwnElement || node instanceof Element;\n}\n\nfunction isHTMLElement(node) {\n var OwnElement = getWindow(node).HTMLElement;\n return node instanceof OwnElement || node instanceof HTMLElement;\n}\n\nfunction isShadowRoot(node) {\n // IE 11 has no ShadowRoot\n if (typeof ShadowRoot === 'undefined') {\n return false;\n }\n\n var OwnElement = getWindow(node).ShadowRoot;\n return node instanceof OwnElement || node instanceof ShadowRoot;\n}\n\nexport { isElement, isHTMLElement, isShadowRoot };","import getNodeName from \"../dom-utils/getNodeName.js\";\nimport { isHTMLElement } from \"../dom-utils/instanceOf.js\"; // This modifier takes the styles prepared by the `computeStyles` modifier\n// and applies them to the HTMLElements such as popper and arrow\n\nfunction applyStyles(_ref) {\n var state = _ref.state;\n Object.keys(state.elements).forEach(function (name) {\n var style = state.styles[name] || {};\n var attributes = state.attributes[name] || {};\n var element = state.elements[name]; // arrow is optional + virtual elements\n\n if (!isHTMLElement(element) || !getNodeName(element)) {\n return;\n } // Flow doesn't support to extend this property, but it's the most\n // effective way to apply styles to an HTMLElement\n // $FlowFixMe[cannot-write]\n\n\n Object.assign(element.style, style);\n Object.keys(attributes).forEach(function (name) {\n var value = attributes[name];\n\n if (value === false) {\n element.removeAttribute(name);\n } else {\n element.setAttribute(name, value === true ? '' : value);\n }\n });\n });\n}\n\nfunction effect(_ref2) {\n var state = _ref2.state;\n var initialStyles = {\n popper: {\n position: state.options.strategy,\n left: '0',\n top: '0',\n margin: '0'\n },\n arrow: {\n position: 'absolute'\n },\n reference: {}\n };\n Object.assign(state.elements.popper.style, initialStyles.popper);\n state.styles = initialStyles;\n\n if (state.elements.arrow) {\n Object.assign(state.elements.arrow.style, initialStyles.arrow);\n }\n\n return function () {\n Object.keys(state.elements).forEach(function (name) {\n var element = state.elements[name];\n var attributes = state.attributes[name] || {};\n var styleProperties = Object.keys(state.styles.hasOwnProperty(name) ? state.styles[name] : initialStyles[name]); // Set all values to an empty string to unset them\n\n var style = styleProperties.reduce(function (style, property) {\n style[property] = '';\n return style;\n }, {}); // arrow is optional + virtual elements\n\n if (!isHTMLElement(element) || !getNodeName(element)) {\n return;\n }\n\n Object.assign(element.style, style);\n Object.keys(attributes).forEach(function (attribute) {\n element.removeAttribute(attribute);\n });\n });\n };\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'applyStyles',\n enabled: true,\n phase: 'write',\n fn: applyStyles,\n effect: effect,\n requires: ['computeStyles']\n};","import { auto } from \"../enums.js\";\nexport default function getBasePlacement(placement) {\n return placement.split('-')[0];\n}","export var max = Math.max;\nexport var min = Math.min;\nexport var round = Math.round;","export default function getUAString() {\n var uaData = navigator.userAgentData;\n\n if (uaData != null && uaData.brands && Array.isArray(uaData.brands)) {\n return uaData.brands.map(function (item) {\n return item.brand + \"/\" + item.version;\n }).join(' ');\n }\n\n return navigator.userAgent;\n}","import getUAString from \"../utils/userAgent.js\";\nexport default function isLayoutViewport() {\n return !/^((?!chrome|android).)*safari/i.test(getUAString());\n}","import { isElement, isHTMLElement } from \"./instanceOf.js\";\nimport { round } from \"../utils/math.js\";\nimport getWindow from \"./getWindow.js\";\nimport isLayoutViewport from \"./isLayoutViewport.js\";\nexport default function getBoundingClientRect(element, includeScale, isFixedStrategy) {\n if (includeScale === void 0) {\n includeScale = false;\n }\n\n if (isFixedStrategy === void 0) {\n isFixedStrategy = false;\n }\n\n var clientRect = element.getBoundingClientRect();\n var scaleX = 1;\n var scaleY = 1;\n\n if (includeScale && isHTMLElement(element)) {\n scaleX = element.offsetWidth > 0 ? round(clientRect.width) / element.offsetWidth || 1 : 1;\n scaleY = element.offsetHeight > 0 ? round(clientRect.height) / element.offsetHeight || 1 : 1;\n }\n\n var _ref = isElement(element) ? getWindow(element) : window,\n visualViewport = _ref.visualViewport;\n\n var addVisualOffsets = !isLayoutViewport() && isFixedStrategy;\n var x = (clientRect.left + (addVisualOffsets && visualViewport ? visualViewport.offsetLeft : 0)) / scaleX;\n var y = (clientRect.top + (addVisualOffsets && visualViewport ? visualViewport.offsetTop : 0)) / scaleY;\n var width = clientRect.width / scaleX;\n var height = clientRect.height / scaleY;\n return {\n width: width,\n height: height,\n top: y,\n right: x + width,\n bottom: y + height,\n left: x,\n x: x,\n y: y\n };\n}","import getBoundingClientRect from \"./getBoundingClientRect.js\"; // Returns the layout rect of an element relative to its offsetParent. Layout\n// means it doesn't take into account transforms.\n\nexport default function getLayoutRect(element) {\n var clientRect = getBoundingClientRect(element); // Use the clientRect sizes if it's not been transformed.\n // Fixes https://github.com/popperjs/popper-core/issues/1223\n\n var width = element.offsetWidth;\n var height = element.offsetHeight;\n\n if (Math.abs(clientRect.width - width) <= 1) {\n width = clientRect.width;\n }\n\n if (Math.abs(clientRect.height - height) <= 1) {\n height = clientRect.height;\n }\n\n return {\n x: element.offsetLeft,\n y: element.offsetTop,\n width: width,\n height: height\n };\n}","import { isShadowRoot } from \"./instanceOf.js\";\nexport default function contains(parent, child) {\n var rootNode = child.getRootNode && child.getRootNode(); // First, attempt with faster native method\n\n if (parent.contains(child)) {\n return true;\n } // then fallback to custom implementation with Shadow DOM support\n else if (rootNode && isShadowRoot(rootNode)) {\n var next = child;\n\n do {\n if (next && parent.isSameNode(next)) {\n return true;\n } // $FlowFixMe[prop-missing]: need a better way to handle this...\n\n\n next = next.parentNode || next.host;\n } while (next);\n } // Give up, the result is false\n\n\n return false;\n}","import getWindow from \"./getWindow.js\";\nexport default function getComputedStyle(element) {\n return getWindow(element).getComputedStyle(element);\n}","import getNodeName from \"./getNodeName.js\";\nexport default function isTableElement(element) {\n return ['table', 'td', 'th'].indexOf(getNodeName(element)) >= 0;\n}","import { isElement } from \"./instanceOf.js\";\nexport default function getDocumentElement(element) {\n // $FlowFixMe[incompatible-return]: assume body is always available\n return ((isElement(element) ? element.ownerDocument : // $FlowFixMe[prop-missing]\n element.document) || window.document).documentElement;\n}","import getNodeName from \"./getNodeName.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport { isShadowRoot } from \"./instanceOf.js\";\nexport default function getParentNode(element) {\n if (getNodeName(element) === 'html') {\n return element;\n }\n\n return (// this is a quicker (but less type safe) way to save quite some bytes from the bundle\n // $FlowFixMe[incompatible-return]\n // $FlowFixMe[prop-missing]\n element.assignedSlot || // step into the shadow DOM of the parent of a slotted node\n element.parentNode || ( // DOM Element detected\n isShadowRoot(element) ? element.host : null) || // ShadowRoot detected\n // $FlowFixMe[incompatible-call]: HTMLElement is a Node\n getDocumentElement(element) // fallback\n\n );\n}","import getWindow from \"./getWindow.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport getComputedStyle from \"./getComputedStyle.js\";\nimport { isHTMLElement, isShadowRoot } from \"./instanceOf.js\";\nimport isTableElement from \"./isTableElement.js\";\nimport getParentNode from \"./getParentNode.js\";\nimport getUAString from \"../utils/userAgent.js\";\n\nfunction getTrueOffsetParent(element) {\n if (!isHTMLElement(element) || // https://github.com/popperjs/popper-core/issues/837\n getComputedStyle(element).position === 'fixed') {\n return null;\n }\n\n return element.offsetParent;\n} // `.offsetParent` reports `null` for fixed elements, while absolute elements\n// return the containing block\n\n\nfunction getContainingBlock(element) {\n var isFirefox = /firefox/i.test(getUAString());\n var isIE = /Trident/i.test(getUAString());\n\n if (isIE && isHTMLElement(element)) {\n // In IE 9, 10 and 11 fixed elements containing block is always established by the viewport\n var elementCss = getComputedStyle(element);\n\n if (elementCss.position === 'fixed') {\n return null;\n }\n }\n\n var currentNode = getParentNode(element);\n\n if (isShadowRoot(currentNode)) {\n currentNode = currentNode.host;\n }\n\n while (isHTMLElement(currentNode) && ['html', 'body'].indexOf(getNodeName(currentNode)) < 0) {\n var css = getComputedStyle(currentNode); // This is non-exhaustive but covers the most common CSS properties that\n // create a containing block.\n // https://developer.mozilla.org/en-US/docs/Web/CSS/Containing_block#identifying_the_containing_block\n\n if (css.transform !== 'none' || css.perspective !== 'none' || css.contain === 'paint' || ['transform', 'perspective'].indexOf(css.willChange) !== -1 || isFirefox && css.willChange === 'filter' || isFirefox && css.filter && css.filter !== 'none') {\n return currentNode;\n } else {\n currentNode = currentNode.parentNode;\n }\n }\n\n return null;\n} // Gets the closest ancestor positioned element. Handles some edge cases,\n// such as table ancestors and cross browser bugs.\n\n\nexport default function getOffsetParent(element) {\n var window = getWindow(element);\n var offsetParent = getTrueOffsetParent(element);\n\n while (offsetParent && isTableElement(offsetParent) && getComputedStyle(offsetParent).position === 'static') {\n offsetParent = getTrueOffsetParent(offsetParent);\n }\n\n if (offsetParent && (getNodeName(offsetParent) === 'html' || getNodeName(offsetParent) === 'body' && getComputedStyle(offsetParent).position === 'static')) {\n return window;\n }\n\n return offsetParent || getContainingBlock(element) || window;\n}","export default function getMainAxisFromPlacement(placement) {\n return ['top', 'bottom'].indexOf(placement) >= 0 ? 'x' : 'y';\n}","import { max as mathMax, min as mathMin } from \"./math.js\";\nexport function within(min, value, max) {\n return mathMax(min, mathMin(value, max));\n}\nexport function withinMaxClamp(min, value, max) {\n var v = within(min, value, max);\n return v > max ? max : v;\n}","export default function getFreshSideObject() {\n return {\n top: 0,\n right: 0,\n bottom: 0,\n left: 0\n };\n}","import getFreshSideObject from \"./getFreshSideObject.js\";\nexport default function mergePaddingObject(paddingObject) {\n return Object.assign({}, getFreshSideObject(), paddingObject);\n}","export default function expandToHashMap(value, keys) {\n return keys.reduce(function (hashMap, key) {\n hashMap[key] = value;\n return hashMap;\n }, {});\n}","import getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getLayoutRect from \"../dom-utils/getLayoutRect.js\";\nimport contains from \"../dom-utils/contains.js\";\nimport getOffsetParent from \"../dom-utils/getOffsetParent.js\";\nimport getMainAxisFromPlacement from \"../utils/getMainAxisFromPlacement.js\";\nimport { within } from \"../utils/within.js\";\nimport mergePaddingObject from \"../utils/mergePaddingObject.js\";\nimport expandToHashMap from \"../utils/expandToHashMap.js\";\nimport { left, right, basePlacements, top, bottom } from \"../enums.js\"; // eslint-disable-next-line import/no-unused-modules\n\nvar toPaddingObject = function toPaddingObject(padding, state) {\n padding = typeof padding === 'function' ? padding(Object.assign({}, state.rects, {\n placement: state.placement\n })) : padding;\n return mergePaddingObject(typeof padding !== 'number' ? padding : expandToHashMap(padding, basePlacements));\n};\n\nfunction arrow(_ref) {\n var _state$modifiersData$;\n\n var state = _ref.state,\n name = _ref.name,\n options = _ref.options;\n var arrowElement = state.elements.arrow;\n var popperOffsets = state.modifiersData.popperOffsets;\n var basePlacement = getBasePlacement(state.placement);\n var axis = getMainAxisFromPlacement(basePlacement);\n var isVertical = [left, right].indexOf(basePlacement) >= 0;\n var len = isVertical ? 'height' : 'width';\n\n if (!arrowElement || !popperOffsets) {\n return;\n }\n\n var paddingObject = toPaddingObject(options.padding, state);\n var arrowRect = getLayoutRect(arrowElement);\n var minProp = axis === 'y' ? top : left;\n var maxProp = axis === 'y' ? bottom : right;\n var endDiff = state.rects.reference[len] + state.rects.reference[axis] - popperOffsets[axis] - state.rects.popper[len];\n var startDiff = popperOffsets[axis] - state.rects.reference[axis];\n var arrowOffsetParent = getOffsetParent(arrowElement);\n var clientSize = arrowOffsetParent ? axis === 'y' ? arrowOffsetParent.clientHeight || 0 : arrowOffsetParent.clientWidth || 0 : 0;\n var centerToReference = endDiff / 2 - startDiff / 2; // Make sure the arrow doesn't overflow the popper if the center point is\n // outside of the popper bounds\n\n var min = paddingObject[minProp];\n var max = clientSize - arrowRect[len] - paddingObject[maxProp];\n var center = clientSize / 2 - arrowRect[len] / 2 + centerToReference;\n var offset = within(min, center, max); // Prevents breaking syntax highlighting...\n\n var axisProp = axis;\n state.modifiersData[name] = (_state$modifiersData$ = {}, _state$modifiersData$[axisProp] = offset, _state$modifiersData$.centerOffset = offset - center, _state$modifiersData$);\n}\n\nfunction effect(_ref2) {\n var state = _ref2.state,\n options = _ref2.options;\n var _options$element = options.element,\n arrowElement = _options$element === void 0 ? '[data-popper-arrow]' : _options$element;\n\n if (arrowElement == null) {\n return;\n } // CSS selector\n\n\n if (typeof arrowElement === 'string') {\n arrowElement = state.elements.popper.querySelector(arrowElement);\n\n if (!arrowElement) {\n return;\n }\n }\n\n if (!contains(state.elements.popper, arrowElement)) {\n return;\n }\n\n state.elements.arrow = arrowElement;\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'arrow',\n enabled: true,\n phase: 'main',\n fn: arrow,\n effect: effect,\n requires: ['popperOffsets'],\n requiresIfExists: ['preventOverflow']\n};","export default function getVariation(placement) {\n return placement.split('-')[1];\n}","import { top, left, right, bottom, end } from \"../enums.js\";\nimport getOffsetParent from \"../dom-utils/getOffsetParent.js\";\nimport getWindow from \"../dom-utils/getWindow.js\";\nimport getDocumentElement from \"../dom-utils/getDocumentElement.js\";\nimport getComputedStyle from \"../dom-utils/getComputedStyle.js\";\nimport getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getVariation from \"../utils/getVariation.js\";\nimport { round } from \"../utils/math.js\"; // eslint-disable-next-line import/no-unused-modules\n\nvar unsetSides = {\n top: 'auto',\n right: 'auto',\n bottom: 'auto',\n left: 'auto'\n}; // Round the offsets to the nearest suitable subpixel based on the DPR.\n// Zooming can change the DPR, but it seems to report a value that will\n// cleanly divide the values into the appropriate subpixels.\n\nfunction roundOffsetsByDPR(_ref, win) {\n var x = _ref.x,\n y = _ref.y;\n var dpr = win.devicePixelRatio || 1;\n return {\n x: round(x * dpr) / dpr || 0,\n y: round(y * dpr) / dpr || 0\n };\n}\n\nexport function mapToStyles(_ref2) {\n var _Object$assign2;\n\n var popper = _ref2.popper,\n popperRect = _ref2.popperRect,\n placement = _ref2.placement,\n variation = _ref2.variation,\n offsets = _ref2.offsets,\n position = _ref2.position,\n gpuAcceleration = _ref2.gpuAcceleration,\n adaptive = _ref2.adaptive,\n roundOffsets = _ref2.roundOffsets,\n isFixed = _ref2.isFixed;\n var _offsets$x = offsets.x,\n x = _offsets$x === void 0 ? 0 : _offsets$x,\n _offsets$y = offsets.y,\n y = _offsets$y === void 0 ? 0 : _offsets$y;\n\n var _ref3 = typeof roundOffsets === 'function' ? roundOffsets({\n x: x,\n y: y\n }) : {\n x: x,\n y: y\n };\n\n x = _ref3.x;\n y = _ref3.y;\n var hasX = offsets.hasOwnProperty('x');\n var hasY = offsets.hasOwnProperty('y');\n var sideX = left;\n var sideY = top;\n var win = window;\n\n if (adaptive) {\n var offsetParent = getOffsetParent(popper);\n var heightProp = 'clientHeight';\n var widthProp = 'clientWidth';\n\n if (offsetParent === getWindow(popper)) {\n offsetParent = getDocumentElement(popper);\n\n if (getComputedStyle(offsetParent).position !== 'static' && position === 'absolute') {\n heightProp = 'scrollHeight';\n widthProp = 'scrollWidth';\n }\n } // $FlowFixMe[incompatible-cast]: force type refinement, we compare offsetParent with window above, but Flow doesn't detect it\n\n\n offsetParent = offsetParent;\n\n if (placement === top || (placement === left || placement === right) && variation === end) {\n sideY = bottom;\n var offsetY = isFixed && offsetParent === win && win.visualViewport ? win.visualViewport.height : // $FlowFixMe[prop-missing]\n offsetParent[heightProp];\n y -= offsetY - popperRect.height;\n y *= gpuAcceleration ? 1 : -1;\n }\n\n if (placement === left || (placement === top || placement === bottom) && variation === end) {\n sideX = right;\n var offsetX = isFixed && offsetParent === win && win.visualViewport ? win.visualViewport.width : // $FlowFixMe[prop-missing]\n offsetParent[widthProp];\n x -= offsetX - popperRect.width;\n x *= gpuAcceleration ? 1 : -1;\n }\n }\n\n var commonStyles = Object.assign({\n position: position\n }, adaptive && unsetSides);\n\n var _ref4 = roundOffsets === true ? roundOffsetsByDPR({\n x: x,\n y: y\n }, getWindow(popper)) : {\n x: x,\n y: y\n };\n\n x = _ref4.x;\n y = _ref4.y;\n\n if (gpuAcceleration) {\n var _Object$assign;\n\n return Object.assign({}, commonStyles, (_Object$assign = {}, _Object$assign[sideY] = hasY ? '0' : '', _Object$assign[sideX] = hasX ? '0' : '', _Object$assign.transform = (win.devicePixelRatio || 1) <= 1 ? \"translate(\" + x + \"px, \" + y + \"px)\" : \"translate3d(\" + x + \"px, \" + y + \"px, 0)\", _Object$assign));\n }\n\n return Object.assign({}, commonStyles, (_Object$assign2 = {}, _Object$assign2[sideY] = hasY ? y + \"px\" : '', _Object$assign2[sideX] = hasX ? x + \"px\" : '', _Object$assign2.transform = '', _Object$assign2));\n}\n\nfunction computeStyles(_ref5) {\n var state = _ref5.state,\n options = _ref5.options;\n var _options$gpuAccelerat = options.gpuAcceleration,\n gpuAcceleration = _options$gpuAccelerat === void 0 ? true : _options$gpuAccelerat,\n _options$adaptive = options.adaptive,\n adaptive = _options$adaptive === void 0 ? true : _options$adaptive,\n _options$roundOffsets = options.roundOffsets,\n roundOffsets = _options$roundOffsets === void 0 ? true : _options$roundOffsets;\n var commonStyles = {\n placement: getBasePlacement(state.placement),\n variation: getVariation(state.placement),\n popper: state.elements.popper,\n popperRect: state.rects.popper,\n gpuAcceleration: gpuAcceleration,\n isFixed: state.options.strategy === 'fixed'\n };\n\n if (state.modifiersData.popperOffsets != null) {\n state.styles.popper = Object.assign({}, state.styles.popper, mapToStyles(Object.assign({}, commonStyles, {\n offsets: state.modifiersData.popperOffsets,\n position: state.options.strategy,\n adaptive: adaptive,\n roundOffsets: roundOffsets\n })));\n }\n\n if (state.modifiersData.arrow != null) {\n state.styles.arrow = Object.assign({}, state.styles.arrow, mapToStyles(Object.assign({}, commonStyles, {\n offsets: state.modifiersData.arrow,\n position: 'absolute',\n adaptive: false,\n roundOffsets: roundOffsets\n })));\n }\n\n state.attributes.popper = Object.assign({}, state.attributes.popper, {\n 'data-popper-placement': state.placement\n });\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'computeStyles',\n enabled: true,\n phase: 'beforeWrite',\n fn: computeStyles,\n data: {}\n};","import getWindow from \"../dom-utils/getWindow.js\"; // eslint-disable-next-line import/no-unused-modules\n\nvar passive = {\n passive: true\n};\n\nfunction effect(_ref) {\n var state = _ref.state,\n instance = _ref.instance,\n options = _ref.options;\n var _options$scroll = options.scroll,\n scroll = _options$scroll === void 0 ? true : _options$scroll,\n _options$resize = options.resize,\n resize = _options$resize === void 0 ? true : _options$resize;\n var window = getWindow(state.elements.popper);\n var scrollParents = [].concat(state.scrollParents.reference, state.scrollParents.popper);\n\n if (scroll) {\n scrollParents.forEach(function (scrollParent) {\n scrollParent.addEventListener('scroll', instance.update, passive);\n });\n }\n\n if (resize) {\n window.addEventListener('resize', instance.update, passive);\n }\n\n return function () {\n if (scroll) {\n scrollParents.forEach(function (scrollParent) {\n scrollParent.removeEventListener('scroll', instance.update, passive);\n });\n }\n\n if (resize) {\n window.removeEventListener('resize', instance.update, passive);\n }\n };\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'eventListeners',\n enabled: true,\n phase: 'write',\n fn: function fn() {},\n effect: effect,\n data: {}\n};","var hash = {\n left: 'right',\n right: 'left',\n bottom: 'top',\n top: 'bottom'\n};\nexport default function getOppositePlacement(placement) {\n return placement.replace(/left|right|bottom|top/g, function (matched) {\n return hash[matched];\n });\n}","var hash = {\n start: 'end',\n end: 'start'\n};\nexport default function getOppositeVariationPlacement(placement) {\n return placement.replace(/start|end/g, function (matched) {\n return hash[matched];\n });\n}","import getWindow from \"./getWindow.js\";\nexport default function getWindowScroll(node) {\n var win = getWindow(node);\n var scrollLeft = win.pageXOffset;\n var scrollTop = win.pageYOffset;\n return {\n scrollLeft: scrollLeft,\n scrollTop: scrollTop\n };\n}","import getBoundingClientRect from \"./getBoundingClientRect.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport getWindowScroll from \"./getWindowScroll.js\";\nexport default function getWindowScrollBarX(element) {\n // If has a CSS width greater than the viewport, then this will be\n // incorrect for RTL.\n // Popper 1 is broken in this case and never had a bug report so let's assume\n // it's not an issue. I don't think anyone ever specifies width on \n // anyway.\n // Browsers where the left scrollbar doesn't cause an issue report `0` for\n // this (e.g. Edge 2019, IE11, Safari)\n return getBoundingClientRect(getDocumentElement(element)).left + getWindowScroll(element).scrollLeft;\n}","import getWindow from \"./getWindow.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport getWindowScrollBarX from \"./getWindowScrollBarX.js\";\nimport isLayoutViewport from \"./isLayoutViewport.js\";\nexport default function getViewportRect(element, strategy) {\n var win = getWindow(element);\n var html = getDocumentElement(element);\n var visualViewport = win.visualViewport;\n var width = html.clientWidth;\n var height = html.clientHeight;\n var x = 0;\n var y = 0;\n\n if (visualViewport) {\n width = visualViewport.width;\n height = visualViewport.height;\n var layoutViewport = isLayoutViewport();\n\n if (layoutViewport || !layoutViewport && strategy === 'fixed') {\n x = visualViewport.offsetLeft;\n y = visualViewport.offsetTop;\n }\n }\n\n return {\n width: width,\n height: height,\n x: x + getWindowScrollBarX(element),\n y: y\n };\n}","import getDocumentElement from \"./getDocumentElement.js\";\nimport getComputedStyle from \"./getComputedStyle.js\";\nimport getWindowScrollBarX from \"./getWindowScrollBarX.js\";\nimport getWindowScroll from \"./getWindowScroll.js\";\nimport { max } from \"../utils/math.js\"; // Gets the entire size of the scrollable document area, even extending outside\n// of the `` and `` rect bounds if horizontally scrollable\n\nexport default function getDocumentRect(element) {\n var _element$ownerDocumen;\n\n var html = getDocumentElement(element);\n var winScroll = getWindowScroll(element);\n var body = (_element$ownerDocumen = element.ownerDocument) == null ? void 0 : _element$ownerDocumen.body;\n var width = max(html.scrollWidth, html.clientWidth, body ? body.scrollWidth : 0, body ? body.clientWidth : 0);\n var height = max(html.scrollHeight, html.clientHeight, body ? body.scrollHeight : 0, body ? body.clientHeight : 0);\n var x = -winScroll.scrollLeft + getWindowScrollBarX(element);\n var y = -winScroll.scrollTop;\n\n if (getComputedStyle(body || html).direction === 'rtl') {\n x += max(html.clientWidth, body ? body.clientWidth : 0) - width;\n }\n\n return {\n width: width,\n height: height,\n x: x,\n y: y\n };\n}","import getComputedStyle from \"./getComputedStyle.js\";\nexport default function isScrollParent(element) {\n // Firefox wants us to check `-x` and `-y` variations as well\n var _getComputedStyle = getComputedStyle(element),\n overflow = _getComputedStyle.overflow,\n overflowX = _getComputedStyle.overflowX,\n overflowY = _getComputedStyle.overflowY;\n\n return /auto|scroll|overlay|hidden/.test(overflow + overflowY + overflowX);\n}","import getParentNode from \"./getParentNode.js\";\nimport isScrollParent from \"./isScrollParent.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport { isHTMLElement } from \"./instanceOf.js\";\nexport default function getScrollParent(node) {\n if (['html', 'body', '#document'].indexOf(getNodeName(node)) >= 0) {\n // $FlowFixMe[incompatible-return]: assume body is always available\n return node.ownerDocument.body;\n }\n\n if (isHTMLElement(node) && isScrollParent(node)) {\n return node;\n }\n\n return getScrollParent(getParentNode(node));\n}","import getScrollParent from \"./getScrollParent.js\";\nimport getParentNode from \"./getParentNode.js\";\nimport getWindow from \"./getWindow.js\";\nimport isScrollParent from \"./isScrollParent.js\";\n/*\ngiven a DOM element, return the list of all scroll parents, up the list of ancesors\nuntil we get to the top window object. This list is what we attach scroll listeners\nto, because if any of these parent elements scroll, we'll need to re-calculate the\nreference element's position.\n*/\n\nexport default function listScrollParents(element, list) {\n var _element$ownerDocumen;\n\n if (list === void 0) {\n list = [];\n }\n\n var scrollParent = getScrollParent(element);\n var isBody = scrollParent === ((_element$ownerDocumen = element.ownerDocument) == null ? void 0 : _element$ownerDocumen.body);\n var win = getWindow(scrollParent);\n var target = isBody ? [win].concat(win.visualViewport || [], isScrollParent(scrollParent) ? scrollParent : []) : scrollParent;\n var updatedList = list.concat(target);\n return isBody ? updatedList : // $FlowFixMe[incompatible-call]: isBody tells us target will be an HTMLElement here\n updatedList.concat(listScrollParents(getParentNode(target)));\n}","export default function rectToClientRect(rect) {\n return Object.assign({}, rect, {\n left: rect.x,\n top: rect.y,\n right: rect.x + rect.width,\n bottom: rect.y + rect.height\n });\n}","import { viewport } from \"../enums.js\";\nimport getViewportRect from \"./getViewportRect.js\";\nimport getDocumentRect from \"./getDocumentRect.js\";\nimport listScrollParents from \"./listScrollParents.js\";\nimport getOffsetParent from \"./getOffsetParent.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport getComputedStyle from \"./getComputedStyle.js\";\nimport { isElement, isHTMLElement } from \"./instanceOf.js\";\nimport getBoundingClientRect from \"./getBoundingClientRect.js\";\nimport getParentNode from \"./getParentNode.js\";\nimport contains from \"./contains.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport rectToClientRect from \"../utils/rectToClientRect.js\";\nimport { max, min } from \"../utils/math.js\";\n\nfunction getInnerBoundingClientRect(element, strategy) {\n var rect = getBoundingClientRect(element, false, strategy === 'fixed');\n rect.top = rect.top + element.clientTop;\n rect.left = rect.left + element.clientLeft;\n rect.bottom = rect.top + element.clientHeight;\n rect.right = rect.left + element.clientWidth;\n rect.width = element.clientWidth;\n rect.height = element.clientHeight;\n rect.x = rect.left;\n rect.y = rect.top;\n return rect;\n}\n\nfunction getClientRectFromMixedType(element, clippingParent, strategy) {\n return clippingParent === viewport ? rectToClientRect(getViewportRect(element, strategy)) : isElement(clippingParent) ? getInnerBoundingClientRect(clippingParent, strategy) : rectToClientRect(getDocumentRect(getDocumentElement(element)));\n} // A \"clipping parent\" is an overflowable container with the characteristic of\n// clipping (or hiding) overflowing elements with a position different from\n// `initial`\n\n\nfunction getClippingParents(element) {\n var clippingParents = listScrollParents(getParentNode(element));\n var canEscapeClipping = ['absolute', 'fixed'].indexOf(getComputedStyle(element).position) >= 0;\n var clipperElement = canEscapeClipping && isHTMLElement(element) ? getOffsetParent(element) : element;\n\n if (!isElement(clipperElement)) {\n return [];\n } // $FlowFixMe[incompatible-return]: https://github.com/facebook/flow/issues/1414\n\n\n return clippingParents.filter(function (clippingParent) {\n return isElement(clippingParent) && contains(clippingParent, clipperElement) && getNodeName(clippingParent) !== 'body';\n });\n} // Gets the maximum area that the element is visible in due to any number of\n// clipping parents\n\n\nexport default function getClippingRect(element, boundary, rootBoundary, strategy) {\n var mainClippingParents = boundary === 'clippingParents' ? getClippingParents(element) : [].concat(boundary);\n var clippingParents = [].concat(mainClippingParents, [rootBoundary]);\n var firstClippingParent = clippingParents[0];\n var clippingRect = clippingParents.reduce(function (accRect, clippingParent) {\n var rect = getClientRectFromMixedType(element, clippingParent, strategy);\n accRect.top = max(rect.top, accRect.top);\n accRect.right = min(rect.right, accRect.right);\n accRect.bottom = min(rect.bottom, accRect.bottom);\n accRect.left = max(rect.left, accRect.left);\n return accRect;\n }, getClientRectFromMixedType(element, firstClippingParent, strategy));\n clippingRect.width = clippingRect.right - clippingRect.left;\n clippingRect.height = clippingRect.bottom - clippingRect.top;\n clippingRect.x = clippingRect.left;\n clippingRect.y = clippingRect.top;\n return clippingRect;\n}","import getBasePlacement from \"./getBasePlacement.js\";\nimport getVariation from \"./getVariation.js\";\nimport getMainAxisFromPlacement from \"./getMainAxisFromPlacement.js\";\nimport { top, right, bottom, left, start, end } from \"../enums.js\";\nexport default function computeOffsets(_ref) {\n var reference = _ref.reference,\n element = _ref.element,\n placement = _ref.placement;\n var basePlacement = placement ? getBasePlacement(placement) : null;\n var variation = placement ? getVariation(placement) : null;\n var commonX = reference.x + reference.width / 2 - element.width / 2;\n var commonY = reference.y + reference.height / 2 - element.height / 2;\n var offsets;\n\n switch (basePlacement) {\n case top:\n offsets = {\n x: commonX,\n y: reference.y - element.height\n };\n break;\n\n case bottom:\n offsets = {\n x: commonX,\n y: reference.y + reference.height\n };\n break;\n\n case right:\n offsets = {\n x: reference.x + reference.width,\n y: commonY\n };\n break;\n\n case left:\n offsets = {\n x: reference.x - element.width,\n y: commonY\n };\n break;\n\n default:\n offsets = {\n x: reference.x,\n y: reference.y\n };\n }\n\n var mainAxis = basePlacement ? getMainAxisFromPlacement(basePlacement) : null;\n\n if (mainAxis != null) {\n var len = mainAxis === 'y' ? 'height' : 'width';\n\n switch (variation) {\n case start:\n offsets[mainAxis] = offsets[mainAxis] - (reference[len] / 2 - element[len] / 2);\n break;\n\n case end:\n offsets[mainAxis] = offsets[mainAxis] + (reference[len] / 2 - element[len] / 2);\n break;\n\n default:\n }\n }\n\n return offsets;\n}","import getClippingRect from \"../dom-utils/getClippingRect.js\";\nimport getDocumentElement from \"../dom-utils/getDocumentElement.js\";\nimport getBoundingClientRect from \"../dom-utils/getBoundingClientRect.js\";\nimport computeOffsets from \"./computeOffsets.js\";\nimport rectToClientRect from \"./rectToClientRect.js\";\nimport { clippingParents, reference, popper, bottom, top, right, basePlacements, viewport } from \"../enums.js\";\nimport { isElement } from \"../dom-utils/instanceOf.js\";\nimport mergePaddingObject from \"./mergePaddingObject.js\";\nimport expandToHashMap from \"./expandToHashMap.js\"; // eslint-disable-next-line import/no-unused-modules\n\nexport default function detectOverflow(state, options) {\n if (options === void 0) {\n options = {};\n }\n\n var _options = options,\n _options$placement = _options.placement,\n placement = _options$placement === void 0 ? state.placement : _options$placement,\n _options$strategy = _options.strategy,\n strategy = _options$strategy === void 0 ? state.strategy : _options$strategy,\n _options$boundary = _options.boundary,\n boundary = _options$boundary === void 0 ? clippingParents : _options$boundary,\n _options$rootBoundary = _options.rootBoundary,\n rootBoundary = _options$rootBoundary === void 0 ? viewport : _options$rootBoundary,\n _options$elementConte = _options.elementContext,\n elementContext = _options$elementConte === void 0 ? popper : _options$elementConte,\n _options$altBoundary = _options.altBoundary,\n altBoundary = _options$altBoundary === void 0 ? false : _options$altBoundary,\n _options$padding = _options.padding,\n padding = _options$padding === void 0 ? 0 : _options$padding;\n var paddingObject = mergePaddingObject(typeof padding !== 'number' ? padding : expandToHashMap(padding, basePlacements));\n var altContext = elementContext === popper ? reference : popper;\n var popperRect = state.rects.popper;\n var element = state.elements[altBoundary ? altContext : elementContext];\n var clippingClientRect = getClippingRect(isElement(element) ? element : element.contextElement || getDocumentElement(state.elements.popper), boundary, rootBoundary, strategy);\n var referenceClientRect = getBoundingClientRect(state.elements.reference);\n var popperOffsets = computeOffsets({\n reference: referenceClientRect,\n element: popperRect,\n strategy: 'absolute',\n placement: placement\n });\n var popperClientRect = rectToClientRect(Object.assign({}, popperRect, popperOffsets));\n var elementClientRect = elementContext === popper ? popperClientRect : referenceClientRect; // positive = overflowing the clipping rect\n // 0 or negative = within the clipping rect\n\n var overflowOffsets = {\n top: clippingClientRect.top - elementClientRect.top + paddingObject.top,\n bottom: elementClientRect.bottom - clippingClientRect.bottom + paddingObject.bottom,\n left: clippingClientRect.left - elementClientRect.left + paddingObject.left,\n right: elementClientRect.right - clippingClientRect.right + paddingObject.right\n };\n var offsetData = state.modifiersData.offset; // Offsets can be applied only to the popper element\n\n if (elementContext === popper && offsetData) {\n var offset = offsetData[placement];\n Object.keys(overflowOffsets).forEach(function (key) {\n var multiply = [right, bottom].indexOf(key) >= 0 ? 1 : -1;\n var axis = [top, bottom].indexOf(key) >= 0 ? 'y' : 'x';\n overflowOffsets[key] += offset[axis] * multiply;\n });\n }\n\n return overflowOffsets;\n}","import getVariation from \"./getVariation.js\";\nimport { variationPlacements, basePlacements, placements as allPlacements } from \"../enums.js\";\nimport detectOverflow from \"./detectOverflow.js\";\nimport getBasePlacement from \"./getBasePlacement.js\";\nexport default function computeAutoPlacement(state, options) {\n if (options === void 0) {\n options = {};\n }\n\n var _options = options,\n placement = _options.placement,\n boundary = _options.boundary,\n rootBoundary = _options.rootBoundary,\n padding = _options.padding,\n flipVariations = _options.flipVariations,\n _options$allowedAutoP = _options.allowedAutoPlacements,\n allowedAutoPlacements = _options$allowedAutoP === void 0 ? allPlacements : _options$allowedAutoP;\n var variation = getVariation(placement);\n var placements = variation ? flipVariations ? variationPlacements : variationPlacements.filter(function (placement) {\n return getVariation(placement) === variation;\n }) : basePlacements;\n var allowedPlacements = placements.filter(function (placement) {\n return allowedAutoPlacements.indexOf(placement) >= 0;\n });\n\n if (allowedPlacements.length === 0) {\n allowedPlacements = placements;\n } // $FlowFixMe[incompatible-type]: Flow seems to have problems with two array unions...\n\n\n var overflows = allowedPlacements.reduce(function (acc, placement) {\n acc[placement] = detectOverflow(state, {\n placement: placement,\n boundary: boundary,\n rootBoundary: rootBoundary,\n padding: padding\n })[getBasePlacement(placement)];\n return acc;\n }, {});\n return Object.keys(overflows).sort(function (a, b) {\n return overflows[a] - overflows[b];\n });\n}","import getOppositePlacement from \"../utils/getOppositePlacement.js\";\nimport getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getOppositeVariationPlacement from \"../utils/getOppositeVariationPlacement.js\";\nimport detectOverflow from \"../utils/detectOverflow.js\";\nimport computeAutoPlacement from \"../utils/computeAutoPlacement.js\";\nimport { bottom, top, start, right, left, auto } from \"../enums.js\";\nimport getVariation from \"../utils/getVariation.js\"; // eslint-disable-next-line import/no-unused-modules\n\nfunction getExpandedFallbackPlacements(placement) {\n if (getBasePlacement(placement) === auto) {\n return [];\n }\n\n var oppositePlacement = getOppositePlacement(placement);\n return [getOppositeVariationPlacement(placement), oppositePlacement, getOppositeVariationPlacement(oppositePlacement)];\n}\n\nfunction flip(_ref) {\n var state = _ref.state,\n options = _ref.options,\n name = _ref.name;\n\n if (state.modifiersData[name]._skip) {\n return;\n }\n\n var _options$mainAxis = options.mainAxis,\n checkMainAxis = _options$mainAxis === void 0 ? true : _options$mainAxis,\n _options$altAxis = options.altAxis,\n checkAltAxis = _options$altAxis === void 0 ? true : _options$altAxis,\n specifiedFallbackPlacements = options.fallbackPlacements,\n padding = options.padding,\n boundary = options.boundary,\n rootBoundary = options.rootBoundary,\n altBoundary = options.altBoundary,\n _options$flipVariatio = options.flipVariations,\n flipVariations = _options$flipVariatio === void 0 ? true : _options$flipVariatio,\n allowedAutoPlacements = options.allowedAutoPlacements;\n var preferredPlacement = state.options.placement;\n var basePlacement = getBasePlacement(preferredPlacement);\n var isBasePlacement = basePlacement === preferredPlacement;\n var fallbackPlacements = specifiedFallbackPlacements || (isBasePlacement || !flipVariations ? [getOppositePlacement(preferredPlacement)] : getExpandedFallbackPlacements(preferredPlacement));\n var placements = [preferredPlacement].concat(fallbackPlacements).reduce(function (acc, placement) {\n return acc.concat(getBasePlacement(placement) === auto ? computeAutoPlacement(state, {\n placement: placement,\n boundary: boundary,\n rootBoundary: rootBoundary,\n padding: padding,\n flipVariations: flipVariations,\n allowedAutoPlacements: allowedAutoPlacements\n }) : placement);\n }, []);\n var referenceRect = state.rects.reference;\n var popperRect = state.rects.popper;\n var checksMap = new Map();\n var makeFallbackChecks = true;\n var firstFittingPlacement = placements[0];\n\n for (var i = 0; i < placements.length; i++) {\n var placement = placements[i];\n\n var _basePlacement = getBasePlacement(placement);\n\n var isStartVariation = getVariation(placement) === start;\n var isVertical = [top, bottom].indexOf(_basePlacement) >= 0;\n var len = isVertical ? 'width' : 'height';\n var overflow = detectOverflow(state, {\n placement: placement,\n boundary: boundary,\n rootBoundary: rootBoundary,\n altBoundary: altBoundary,\n padding: padding\n });\n var mainVariationSide = isVertical ? isStartVariation ? right : left : isStartVariation ? bottom : top;\n\n if (referenceRect[len] > popperRect[len]) {\n mainVariationSide = getOppositePlacement(mainVariationSide);\n }\n\n var altVariationSide = getOppositePlacement(mainVariationSide);\n var checks = [];\n\n if (checkMainAxis) {\n checks.push(overflow[_basePlacement] <= 0);\n }\n\n if (checkAltAxis) {\n checks.push(overflow[mainVariationSide] <= 0, overflow[altVariationSide] <= 0);\n }\n\n if (checks.every(function (check) {\n return check;\n })) {\n firstFittingPlacement = placement;\n makeFallbackChecks = false;\n break;\n }\n\n checksMap.set(placement, checks);\n }\n\n if (makeFallbackChecks) {\n // `2` may be desired in some cases – research later\n var numberOfChecks = flipVariations ? 3 : 1;\n\n var _loop = function _loop(_i) {\n var fittingPlacement = placements.find(function (placement) {\n var checks = checksMap.get(placement);\n\n if (checks) {\n return checks.slice(0, _i).every(function (check) {\n return check;\n });\n }\n });\n\n if (fittingPlacement) {\n firstFittingPlacement = fittingPlacement;\n return \"break\";\n }\n };\n\n for (var _i = numberOfChecks; _i > 0; _i--) {\n var _ret = _loop(_i);\n\n if (_ret === \"break\") break;\n }\n }\n\n if (state.placement !== firstFittingPlacement) {\n state.modifiersData[name]._skip = true;\n state.placement = firstFittingPlacement;\n state.reset = true;\n }\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'flip',\n enabled: true,\n phase: 'main',\n fn: flip,\n requiresIfExists: ['offset'],\n data: {\n _skip: false\n }\n};","import { top, bottom, left, right } from \"../enums.js\";\nimport detectOverflow from \"../utils/detectOverflow.js\";\n\nfunction getSideOffsets(overflow, rect, preventedOffsets) {\n if (preventedOffsets === void 0) {\n preventedOffsets = {\n x: 0,\n y: 0\n };\n }\n\n return {\n top: overflow.top - rect.height - preventedOffsets.y,\n right: overflow.right - rect.width + preventedOffsets.x,\n bottom: overflow.bottom - rect.height + preventedOffsets.y,\n left: overflow.left - rect.width - preventedOffsets.x\n };\n}\n\nfunction isAnySideFullyClipped(overflow) {\n return [top, right, bottom, left].some(function (side) {\n return overflow[side] >= 0;\n });\n}\n\nfunction hide(_ref) {\n var state = _ref.state,\n name = _ref.name;\n var referenceRect = state.rects.reference;\n var popperRect = state.rects.popper;\n var preventedOffsets = state.modifiersData.preventOverflow;\n var referenceOverflow = detectOverflow(state, {\n elementContext: 'reference'\n });\n var popperAltOverflow = detectOverflow(state, {\n altBoundary: true\n });\n var referenceClippingOffsets = getSideOffsets(referenceOverflow, referenceRect);\n var popperEscapeOffsets = getSideOffsets(popperAltOverflow, popperRect, preventedOffsets);\n var isReferenceHidden = isAnySideFullyClipped(referenceClippingOffsets);\n var hasPopperEscaped = isAnySideFullyClipped(popperEscapeOffsets);\n state.modifiersData[name] = {\n referenceClippingOffsets: referenceClippingOffsets,\n popperEscapeOffsets: popperEscapeOffsets,\n isReferenceHidden: isReferenceHidden,\n hasPopperEscaped: hasPopperEscaped\n };\n state.attributes.popper = Object.assign({}, state.attributes.popper, {\n 'data-popper-reference-hidden': isReferenceHidden,\n 'data-popper-escaped': hasPopperEscaped\n });\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'hide',\n enabled: true,\n phase: 'main',\n requiresIfExists: ['preventOverflow'],\n fn: hide\n};","import getBasePlacement from \"../utils/getBasePlacement.js\";\nimport { top, left, right, placements } from \"../enums.js\"; // eslint-disable-next-line import/no-unused-modules\n\nexport function distanceAndSkiddingToXY(placement, rects, offset) {\n var basePlacement = getBasePlacement(placement);\n var invertDistance = [left, top].indexOf(basePlacement) >= 0 ? -1 : 1;\n\n var _ref = typeof offset === 'function' ? offset(Object.assign({}, rects, {\n placement: placement\n })) : offset,\n skidding = _ref[0],\n distance = _ref[1];\n\n skidding = skidding || 0;\n distance = (distance || 0) * invertDistance;\n return [left, right].indexOf(basePlacement) >= 0 ? {\n x: distance,\n y: skidding\n } : {\n x: skidding,\n y: distance\n };\n}\n\nfunction offset(_ref2) {\n var state = _ref2.state,\n options = _ref2.options,\n name = _ref2.name;\n var _options$offset = options.offset,\n offset = _options$offset === void 0 ? [0, 0] : _options$offset;\n var data = placements.reduce(function (acc, placement) {\n acc[placement] = distanceAndSkiddingToXY(placement, state.rects, offset);\n return acc;\n }, {});\n var _data$state$placement = data[state.placement],\n x = _data$state$placement.x,\n y = _data$state$placement.y;\n\n if (state.modifiersData.popperOffsets != null) {\n state.modifiersData.popperOffsets.x += x;\n state.modifiersData.popperOffsets.y += y;\n }\n\n state.modifiersData[name] = data;\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'offset',\n enabled: true,\n phase: 'main',\n requires: ['popperOffsets'],\n fn: offset\n};","import computeOffsets from \"../utils/computeOffsets.js\";\n\nfunction popperOffsets(_ref) {\n var state = _ref.state,\n name = _ref.name;\n // Offsets are the actual position the popper needs to have to be\n // properly positioned near its reference element\n // This is the most basic placement, and will be adjusted by\n // the modifiers in the next step\n state.modifiersData[name] = computeOffsets({\n reference: state.rects.reference,\n element: state.rects.popper,\n strategy: 'absolute',\n placement: state.placement\n });\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'popperOffsets',\n enabled: true,\n phase: 'read',\n fn: popperOffsets,\n data: {}\n};","export default function getAltAxis(axis) {\n return axis === 'x' ? 'y' : 'x';\n}","import { top, left, right, bottom, start } from \"../enums.js\";\nimport getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getMainAxisFromPlacement from \"../utils/getMainAxisFromPlacement.js\";\nimport getAltAxis from \"../utils/getAltAxis.js\";\nimport { within, withinMaxClamp } from \"../utils/within.js\";\nimport getLayoutRect from \"../dom-utils/getLayoutRect.js\";\nimport getOffsetParent from \"../dom-utils/getOffsetParent.js\";\nimport detectOverflow from \"../utils/detectOverflow.js\";\nimport getVariation from \"../utils/getVariation.js\";\nimport getFreshSideObject from \"../utils/getFreshSideObject.js\";\nimport { min as mathMin, max as mathMax } from \"../utils/math.js\";\n\nfunction preventOverflow(_ref) {\n var state = _ref.state,\n options = _ref.options,\n name = _ref.name;\n var _options$mainAxis = options.mainAxis,\n checkMainAxis = _options$mainAxis === void 0 ? true : _options$mainAxis,\n _options$altAxis = options.altAxis,\n checkAltAxis = _options$altAxis === void 0 ? false : _options$altAxis,\n boundary = options.boundary,\n rootBoundary = options.rootBoundary,\n altBoundary = options.altBoundary,\n padding = options.padding,\n _options$tether = options.tether,\n tether = _options$tether === void 0 ? true : _options$tether,\n _options$tetherOffset = options.tetherOffset,\n tetherOffset = _options$tetherOffset === void 0 ? 0 : _options$tetherOffset;\n var overflow = detectOverflow(state, {\n boundary: boundary,\n rootBoundary: rootBoundary,\n padding: padding,\n altBoundary: altBoundary\n });\n var basePlacement = getBasePlacement(state.placement);\n var variation = getVariation(state.placement);\n var isBasePlacement = !variation;\n var mainAxis = getMainAxisFromPlacement(basePlacement);\n var altAxis = getAltAxis(mainAxis);\n var popperOffsets = state.modifiersData.popperOffsets;\n var referenceRect = state.rects.reference;\n var popperRect = state.rects.popper;\n var tetherOffsetValue = typeof tetherOffset === 'function' ? tetherOffset(Object.assign({}, state.rects, {\n placement: state.placement\n })) : tetherOffset;\n var normalizedTetherOffsetValue = typeof tetherOffsetValue === 'number' ? {\n mainAxis: tetherOffsetValue,\n altAxis: tetherOffsetValue\n } : Object.assign({\n mainAxis: 0,\n altAxis: 0\n }, tetherOffsetValue);\n var offsetModifierState = state.modifiersData.offset ? state.modifiersData.offset[state.placement] : null;\n var data = {\n x: 0,\n y: 0\n };\n\n if (!popperOffsets) {\n return;\n }\n\n if (checkMainAxis) {\n var _offsetModifierState$;\n\n var mainSide = mainAxis === 'y' ? top : left;\n var altSide = mainAxis === 'y' ? bottom : right;\n var len = mainAxis === 'y' ? 'height' : 'width';\n var offset = popperOffsets[mainAxis];\n var min = offset + overflow[mainSide];\n var max = offset - overflow[altSide];\n var additive = tether ? -popperRect[len] / 2 : 0;\n var minLen = variation === start ? referenceRect[len] : popperRect[len];\n var maxLen = variation === start ? -popperRect[len] : -referenceRect[len]; // We need to include the arrow in the calculation so the arrow doesn't go\n // outside the reference bounds\n\n var arrowElement = state.elements.arrow;\n var arrowRect = tether && arrowElement ? getLayoutRect(arrowElement) : {\n width: 0,\n height: 0\n };\n var arrowPaddingObject = state.modifiersData['arrow#persistent'] ? state.modifiersData['arrow#persistent'].padding : getFreshSideObject();\n var arrowPaddingMin = arrowPaddingObject[mainSide];\n var arrowPaddingMax = arrowPaddingObject[altSide]; // If the reference length is smaller than the arrow length, we don't want\n // to include its full size in the calculation. If the reference is small\n // and near the edge of a boundary, the popper can overflow even if the\n // reference is not overflowing as well (e.g. virtual elements with no\n // width or height)\n\n var arrowLen = within(0, referenceRect[len], arrowRect[len]);\n var minOffset = isBasePlacement ? referenceRect[len] / 2 - additive - arrowLen - arrowPaddingMin - normalizedTetherOffsetValue.mainAxis : minLen - arrowLen - arrowPaddingMin - normalizedTetherOffsetValue.mainAxis;\n var maxOffset = isBasePlacement ? -referenceRect[len] / 2 + additive + arrowLen + arrowPaddingMax + normalizedTetherOffsetValue.mainAxis : maxLen + arrowLen + arrowPaddingMax + normalizedTetherOffsetValue.mainAxis;\n var arrowOffsetParent = state.elements.arrow && getOffsetParent(state.elements.arrow);\n var clientOffset = arrowOffsetParent ? mainAxis === 'y' ? arrowOffsetParent.clientTop || 0 : arrowOffsetParent.clientLeft || 0 : 0;\n var offsetModifierValue = (_offsetModifierState$ = offsetModifierState == null ? void 0 : offsetModifierState[mainAxis]) != null ? _offsetModifierState$ : 0;\n var tetherMin = offset + minOffset - offsetModifierValue - clientOffset;\n var tetherMax = offset + maxOffset - offsetModifierValue;\n var preventedOffset = within(tether ? mathMin(min, tetherMin) : min, offset, tether ? mathMax(max, tetherMax) : max);\n popperOffsets[mainAxis] = preventedOffset;\n data[mainAxis] = preventedOffset - offset;\n }\n\n if (checkAltAxis) {\n var _offsetModifierState$2;\n\n var _mainSide = mainAxis === 'x' ? top : left;\n\n var _altSide = mainAxis === 'x' ? bottom : right;\n\n var _offset = popperOffsets[altAxis];\n\n var _len = altAxis === 'y' ? 'height' : 'width';\n\n var _min = _offset + overflow[_mainSide];\n\n var _max = _offset - overflow[_altSide];\n\n var isOriginSide = [top, left].indexOf(basePlacement) !== -1;\n\n var _offsetModifierValue = (_offsetModifierState$2 = offsetModifierState == null ? void 0 : offsetModifierState[altAxis]) != null ? _offsetModifierState$2 : 0;\n\n var _tetherMin = isOriginSide ? _min : _offset - referenceRect[_len] - popperRect[_len] - _offsetModifierValue + normalizedTetherOffsetValue.altAxis;\n\n var _tetherMax = isOriginSide ? _offset + referenceRect[_len] + popperRect[_len] - _offsetModifierValue - normalizedTetherOffsetValue.altAxis : _max;\n\n var _preventedOffset = tether && isOriginSide ? withinMaxClamp(_tetherMin, _offset, _tetherMax) : within(tether ? _tetherMin : _min, _offset, tether ? _tetherMax : _max);\n\n popperOffsets[altAxis] = _preventedOffset;\n data[altAxis] = _preventedOffset - _offset;\n }\n\n state.modifiersData[name] = data;\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'preventOverflow',\n enabled: true,\n phase: 'main',\n fn: preventOverflow,\n requiresIfExists: ['offset']\n};","export default function getHTMLElementScroll(element) {\n return {\n scrollLeft: element.scrollLeft,\n scrollTop: element.scrollTop\n };\n}","import getWindowScroll from \"./getWindowScroll.js\";\nimport getWindow from \"./getWindow.js\";\nimport { isHTMLElement } from \"./instanceOf.js\";\nimport getHTMLElementScroll from \"./getHTMLElementScroll.js\";\nexport default function getNodeScroll(node) {\n if (node === getWindow(node) || !isHTMLElement(node)) {\n return getWindowScroll(node);\n } else {\n return getHTMLElementScroll(node);\n }\n}","import getBoundingClientRect from \"./getBoundingClientRect.js\";\nimport getNodeScroll from \"./getNodeScroll.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport { isHTMLElement } from \"./instanceOf.js\";\nimport getWindowScrollBarX from \"./getWindowScrollBarX.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport isScrollParent from \"./isScrollParent.js\";\nimport { round } from \"../utils/math.js\";\n\nfunction isElementScaled(element) {\n var rect = element.getBoundingClientRect();\n var scaleX = round(rect.width) / element.offsetWidth || 1;\n var scaleY = round(rect.height) / element.offsetHeight || 1;\n return scaleX !== 1 || scaleY !== 1;\n} // Returns the composite rect of an element relative to its offsetParent.\n// Composite means it takes into account transforms as well as layout.\n\n\nexport default function getCompositeRect(elementOrVirtualElement, offsetParent, isFixed) {\n if (isFixed === void 0) {\n isFixed = false;\n }\n\n var isOffsetParentAnElement = isHTMLElement(offsetParent);\n var offsetParentIsScaled = isHTMLElement(offsetParent) && isElementScaled(offsetParent);\n var documentElement = getDocumentElement(offsetParent);\n var rect = getBoundingClientRect(elementOrVirtualElement, offsetParentIsScaled, isFixed);\n var scroll = {\n scrollLeft: 0,\n scrollTop: 0\n };\n var offsets = {\n x: 0,\n y: 0\n };\n\n if (isOffsetParentAnElement || !isOffsetParentAnElement && !isFixed) {\n if (getNodeName(offsetParent) !== 'body' || // https://github.com/popperjs/popper-core/issues/1078\n isScrollParent(documentElement)) {\n scroll = getNodeScroll(offsetParent);\n }\n\n if (isHTMLElement(offsetParent)) {\n offsets = getBoundingClientRect(offsetParent, true);\n offsets.x += offsetParent.clientLeft;\n offsets.y += offsetParent.clientTop;\n } else if (documentElement) {\n offsets.x = getWindowScrollBarX(documentElement);\n }\n }\n\n return {\n x: rect.left + scroll.scrollLeft - offsets.x,\n y: rect.top + scroll.scrollTop - offsets.y,\n width: rect.width,\n height: rect.height\n };\n}","import { modifierPhases } from \"../enums.js\"; // source: https://stackoverflow.com/questions/49875255\n\nfunction order(modifiers) {\n var map = new Map();\n var visited = new Set();\n var result = [];\n modifiers.forEach(function (modifier) {\n map.set(modifier.name, modifier);\n }); // On visiting object, check for its dependencies and visit them recursively\n\n function sort(modifier) {\n visited.add(modifier.name);\n var requires = [].concat(modifier.requires || [], modifier.requiresIfExists || []);\n requires.forEach(function (dep) {\n if (!visited.has(dep)) {\n var depModifier = map.get(dep);\n\n if (depModifier) {\n sort(depModifier);\n }\n }\n });\n result.push(modifier);\n }\n\n modifiers.forEach(function (modifier) {\n if (!visited.has(modifier.name)) {\n // check for visited object\n sort(modifier);\n }\n });\n return result;\n}\n\nexport default function orderModifiers(modifiers) {\n // order based on dependencies\n var orderedModifiers = order(modifiers); // order based on phase\n\n return modifierPhases.reduce(function (acc, phase) {\n return acc.concat(orderedModifiers.filter(function (modifier) {\n return modifier.phase === phase;\n }));\n }, []);\n}","export default function debounce(fn) {\n var pending;\n return function () {\n if (!pending) {\n pending = new Promise(function (resolve) {\n Promise.resolve().then(function () {\n pending = undefined;\n resolve(fn());\n });\n });\n }\n\n return pending;\n };\n}","export default function mergeByName(modifiers) {\n var merged = modifiers.reduce(function (merged, current) {\n var existing = merged[current.name];\n merged[current.name] = existing ? Object.assign({}, existing, current, {\n options: Object.assign({}, existing.options, current.options),\n data: Object.assign({}, existing.data, current.data)\n }) : current;\n return merged;\n }, {}); // IE11 does not support Object.values\n\n return Object.keys(merged).map(function (key) {\n return merged[key];\n });\n}","import getCompositeRect from \"./dom-utils/getCompositeRect.js\";\nimport getLayoutRect from \"./dom-utils/getLayoutRect.js\";\nimport listScrollParents from \"./dom-utils/listScrollParents.js\";\nimport getOffsetParent from \"./dom-utils/getOffsetParent.js\";\nimport orderModifiers from \"./utils/orderModifiers.js\";\nimport debounce from \"./utils/debounce.js\";\nimport mergeByName from \"./utils/mergeByName.js\";\nimport detectOverflow from \"./utils/detectOverflow.js\";\nimport { isElement } from \"./dom-utils/instanceOf.js\";\nvar DEFAULT_OPTIONS = {\n placement: 'bottom',\n modifiers: [],\n strategy: 'absolute'\n};\n\nfunction areValidElements() {\n for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {\n args[_key] = arguments[_key];\n }\n\n return !args.some(function (element) {\n return !(element && typeof element.getBoundingClientRect === 'function');\n });\n}\n\nexport function popperGenerator(generatorOptions) {\n if (generatorOptions === void 0) {\n generatorOptions = {};\n }\n\n var _generatorOptions = generatorOptions,\n _generatorOptions$def = _generatorOptions.defaultModifiers,\n defaultModifiers = _generatorOptions$def === void 0 ? [] : _generatorOptions$def,\n _generatorOptions$def2 = _generatorOptions.defaultOptions,\n defaultOptions = _generatorOptions$def2 === void 0 ? DEFAULT_OPTIONS : _generatorOptions$def2;\n return function createPopper(reference, popper, options) {\n if (options === void 0) {\n options = defaultOptions;\n }\n\n var state = {\n placement: 'bottom',\n orderedModifiers: [],\n options: Object.assign({}, DEFAULT_OPTIONS, defaultOptions),\n modifiersData: {},\n elements: {\n reference: reference,\n popper: popper\n },\n attributes: {},\n styles: {}\n };\n var effectCleanupFns = [];\n var isDestroyed = false;\n var instance = {\n state: state,\n setOptions: function setOptions(setOptionsAction) {\n var options = typeof setOptionsAction === 'function' ? setOptionsAction(state.options) : setOptionsAction;\n cleanupModifierEffects();\n state.options = Object.assign({}, defaultOptions, state.options, options);\n state.scrollParents = {\n reference: isElement(reference) ? listScrollParents(reference) : reference.contextElement ? listScrollParents(reference.contextElement) : [],\n popper: listScrollParents(popper)\n }; // Orders the modifiers based on their dependencies and `phase`\n // properties\n\n var orderedModifiers = orderModifiers(mergeByName([].concat(defaultModifiers, state.options.modifiers))); // Strip out disabled modifiers\n\n state.orderedModifiers = orderedModifiers.filter(function (m) {\n return m.enabled;\n });\n runModifierEffects();\n return instance.update();\n },\n // Sync update – it will always be executed, even if not necessary. This\n // is useful for low frequency updates where sync behavior simplifies the\n // logic.\n // For high frequency updates (e.g. `resize` and `scroll` events), always\n // prefer the async Popper#update method\n forceUpdate: function forceUpdate() {\n if (isDestroyed) {\n return;\n }\n\n var _state$elements = state.elements,\n reference = _state$elements.reference,\n popper = _state$elements.popper; // Don't proceed if `reference` or `popper` are not valid elements\n // anymore\n\n if (!areValidElements(reference, popper)) {\n return;\n } // Store the reference and popper rects to be read by modifiers\n\n\n state.rects = {\n reference: getCompositeRect(reference, getOffsetParent(popper), state.options.strategy === 'fixed'),\n popper: getLayoutRect(popper)\n }; // Modifiers have the ability to reset the current update cycle. The\n // most common use case for this is the `flip` modifier changing the\n // placement, which then needs to re-run all the modifiers, because the\n // logic was previously ran for the previous placement and is therefore\n // stale/incorrect\n\n state.reset = false;\n state.placement = state.options.placement; // On each update cycle, the `modifiersData` property for each modifier\n // is filled with the initial data specified by the modifier. This means\n // it doesn't persist and is fresh on each update.\n // To ensure persistent data, use `${name}#persistent`\n\n state.orderedModifiers.forEach(function (modifier) {\n return state.modifiersData[modifier.name] = Object.assign({}, modifier.data);\n });\n\n for (var index = 0; index < state.orderedModifiers.length; index++) {\n if (state.reset === true) {\n state.reset = false;\n index = -1;\n continue;\n }\n\n var _state$orderedModifie = state.orderedModifiers[index],\n fn = _state$orderedModifie.fn,\n _state$orderedModifie2 = _state$orderedModifie.options,\n _options = _state$orderedModifie2 === void 0 ? {} : _state$orderedModifie2,\n name = _state$orderedModifie.name;\n\n if (typeof fn === 'function') {\n state = fn({\n state: state,\n options: _options,\n name: name,\n instance: instance\n }) || state;\n }\n }\n },\n // Async and optimistically optimized update – it will not be executed if\n // not necessary (debounced to run at most once-per-tick)\n update: debounce(function () {\n return new Promise(function (resolve) {\n instance.forceUpdate();\n resolve(state);\n });\n }),\n destroy: function destroy() {\n cleanupModifierEffects();\n isDestroyed = true;\n }\n };\n\n if (!areValidElements(reference, popper)) {\n return instance;\n }\n\n instance.setOptions(options).then(function (state) {\n if (!isDestroyed && options.onFirstUpdate) {\n options.onFirstUpdate(state);\n }\n }); // Modifiers have the ability to execute arbitrary code before the first\n // update cycle runs. They will be executed in the same order as the update\n // cycle. This is useful when a modifier adds some persistent data that\n // other modifiers need to use, but the modifier is run after the dependent\n // one.\n\n function runModifierEffects() {\n state.orderedModifiers.forEach(function (_ref) {\n var name = _ref.name,\n _ref$options = _ref.options,\n options = _ref$options === void 0 ? {} : _ref$options,\n effect = _ref.effect;\n\n if (typeof effect === 'function') {\n var cleanupFn = effect({\n state: state,\n name: name,\n instance: instance,\n options: options\n });\n\n var noopFn = function noopFn() {};\n\n effectCleanupFns.push(cleanupFn || noopFn);\n }\n });\n }\n\n function cleanupModifierEffects() {\n effectCleanupFns.forEach(function (fn) {\n return fn();\n });\n effectCleanupFns = [];\n }\n\n return instance;\n };\n}\nexport var createPopper = /*#__PURE__*/popperGenerator(); // eslint-disable-next-line import/no-unused-modules\n\nexport { detectOverflow };","import { popperGenerator, detectOverflow } from \"./createPopper.js\";\nimport eventListeners from \"./modifiers/eventListeners.js\";\nimport popperOffsets from \"./modifiers/popperOffsets.js\";\nimport computeStyles from \"./modifiers/computeStyles.js\";\nimport applyStyles from \"./modifiers/applyStyles.js\";\nimport offset from \"./modifiers/offset.js\";\nimport flip from \"./modifiers/flip.js\";\nimport preventOverflow from \"./modifiers/preventOverflow.js\";\nimport arrow from \"./modifiers/arrow.js\";\nimport hide from \"./modifiers/hide.js\";\nvar defaultModifiers = [eventListeners, popperOffsets, computeStyles, applyStyles, offset, flip, preventOverflow, arrow, hide];\nvar createPopper = /*#__PURE__*/popperGenerator({\n defaultModifiers: defaultModifiers\n}); // eslint-disable-next-line import/no-unused-modules\n\nexport { createPopper, popperGenerator, defaultModifiers, detectOverflow }; // eslint-disable-next-line import/no-unused-modules\n\nexport { createPopper as createPopperLite } from \"./popper-lite.js\"; // eslint-disable-next-line import/no-unused-modules\n\nexport * from \"./modifiers/index.js\";","import { generateUtilityClass } from '../generateUtilityClass';\nimport { generateUtilityClasses } from '../generateUtilityClasses';\nconst COMPONENT_NAME = 'Popper';\nexport function getPopperUtilityClass(slot) {\n return generateUtilityClass(COMPONENT_NAME, slot);\n}\nexport const popperClasses = generateUtilityClasses(COMPONENT_NAME, ['root']);","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"anchorEl\", \"children\", \"direction\", \"disablePortal\", \"modifiers\", \"open\", \"placement\", \"popperOptions\", \"popperRef\", \"slotProps\", \"slots\", \"TransitionProps\", \"ownerState\"],\n _excluded2 = [\"anchorEl\", \"children\", \"container\", \"direction\", \"disablePortal\", \"keepMounted\", \"modifiers\", \"open\", \"placement\", \"popperOptions\", \"popperRef\", \"style\", \"transition\", \"slotProps\", \"slots\"];\nimport * as React from 'react';\nimport { chainPropTypes, HTMLElementType, refType, unstable_ownerDocument as ownerDocument, unstable_useEnhancedEffect as useEnhancedEffect, unstable_useForkRef as useForkRef } from '@mui/utils';\nimport { createPopper } from '@popperjs/core';\nimport PropTypes from 'prop-types';\nimport { unstable_composeClasses as composeClasses } from '../composeClasses';\nimport { Portal } from '../Portal';\nimport { getPopperUtilityClass } from './popperClasses';\nimport { useSlotProps } from '../utils';\nimport { useClassNamesOverride } from '../utils/ClassNameConfigurator';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nfunction flipPlacement(placement, direction) {\n if (direction === 'ltr') {\n return placement;\n }\n switch (placement) {\n case 'bottom-end':\n return 'bottom-start';\n case 'bottom-start':\n return 'bottom-end';\n case 'top-end':\n return 'top-start';\n case 'top-start':\n return 'top-end';\n default:\n return placement;\n }\n}\nfunction resolveAnchorEl(anchorEl) {\n return typeof anchorEl === 'function' ? anchorEl() : anchorEl;\n}\nfunction isHTMLElement(element) {\n return element.nodeType !== undefined;\n}\nfunction isVirtualElement(element) {\n return !isHTMLElement(element);\n}\nconst useUtilityClasses = () => {\n const slots = {\n root: ['root']\n };\n return composeClasses(slots, useClassNamesOverride(getPopperUtilityClass));\n};\nconst defaultPopperOptions = {};\nconst PopperTooltip = /*#__PURE__*/React.forwardRef(function PopperTooltip(props, forwardedRef) {\n var _slots$root;\n const {\n anchorEl,\n children,\n direction,\n disablePortal,\n modifiers,\n open,\n placement: initialPlacement,\n popperOptions,\n popperRef: popperRefProp,\n slotProps = {},\n slots = {},\n TransitionProps\n // @ts-ignore internal logic\n // prevent from spreading to DOM, it can come from the parent component e.g. Select.\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const tooltipRef = React.useRef(null);\n const ownRef = useForkRef(tooltipRef, forwardedRef);\n const popperRef = React.useRef(null);\n const handlePopperRef = useForkRef(popperRef, popperRefProp);\n const handlePopperRefRef = React.useRef(handlePopperRef);\n useEnhancedEffect(() => {\n handlePopperRefRef.current = handlePopperRef;\n }, [handlePopperRef]);\n React.useImperativeHandle(popperRefProp, () => popperRef.current, []);\n const rtlPlacement = flipPlacement(initialPlacement, direction);\n /**\n * placement initialized from prop but can change during lifetime if modifiers.flip.\n * modifiers.flip is essentially a flip for controlled/uncontrolled behavior\n */\n const [placement, setPlacement] = React.useState(rtlPlacement);\n const [resolvedAnchorElement, setResolvedAnchorElement] = React.useState(resolveAnchorEl(anchorEl));\n React.useEffect(() => {\n if (popperRef.current) {\n popperRef.current.forceUpdate();\n }\n });\n React.useEffect(() => {\n if (anchorEl) {\n setResolvedAnchorElement(resolveAnchorEl(anchorEl));\n }\n }, [anchorEl]);\n useEnhancedEffect(() => {\n if (!resolvedAnchorElement || !open) {\n return undefined;\n }\n const handlePopperUpdate = data => {\n setPlacement(data.placement);\n };\n if (process.env.NODE_ENV !== 'production') {\n if (resolvedAnchorElement && isHTMLElement(resolvedAnchorElement) && resolvedAnchorElement.nodeType === 1) {\n const box = resolvedAnchorElement.getBoundingClientRect();\n if (process.env.NODE_ENV !== 'test' && box.top === 0 && box.left === 0 && box.right === 0 && box.bottom === 0) {\n console.warn(['MUI: The `anchorEl` prop provided to the component is invalid.', 'The anchor element should be part of the document layout.', \"Make sure the element is present in the document or that it's not display none.\"].join('\\n'));\n }\n }\n }\n let popperModifiers = [{\n name: 'preventOverflow',\n options: {\n altBoundary: disablePortal\n }\n }, {\n name: 'flip',\n options: {\n altBoundary: disablePortal\n }\n }, {\n name: 'onUpdate',\n enabled: true,\n phase: 'afterWrite',\n fn: ({\n state\n }) => {\n handlePopperUpdate(state);\n }\n }];\n if (modifiers != null) {\n popperModifiers = popperModifiers.concat(modifiers);\n }\n if (popperOptions && popperOptions.modifiers != null) {\n popperModifiers = popperModifiers.concat(popperOptions.modifiers);\n }\n const popper = createPopper(resolvedAnchorElement, tooltipRef.current, _extends({\n placement: rtlPlacement\n }, popperOptions, {\n modifiers: popperModifiers\n }));\n handlePopperRefRef.current(popper);\n return () => {\n popper.destroy();\n handlePopperRefRef.current(null);\n };\n }, [resolvedAnchorElement, disablePortal, modifiers, open, popperOptions, rtlPlacement]);\n const childProps = {\n placement: placement\n };\n if (TransitionProps !== null) {\n childProps.TransitionProps = TransitionProps;\n }\n const classes = useUtilityClasses();\n const Root = (_slots$root = slots.root) != null ? _slots$root : 'div';\n const rootProps = useSlotProps({\n elementType: Root,\n externalSlotProps: slotProps.root,\n externalForwardedProps: other,\n additionalProps: {\n role: 'tooltip',\n ref: ownRef\n },\n ownerState: props,\n className: classes.root\n });\n return /*#__PURE__*/_jsx(Root, _extends({}, rootProps, {\n children: typeof children === 'function' ? children(childProps) : children\n }));\n});\n\n/**\n * Poppers rely on the 3rd party library [Popper.js](https://popper.js.org/docs/v2/) for positioning.\n *\n * Demos:\n *\n * - [Popper](https://mui.com/base-ui/react-popper/)\n *\n * API:\n *\n * - [Popper API](https://mui.com/base-ui/react-popper/components-api/#popper)\n */\nconst Popper = /*#__PURE__*/React.forwardRef(function Popper(props, forwardedRef) {\n const {\n anchorEl,\n children,\n container: containerProp,\n direction = 'ltr',\n disablePortal = false,\n keepMounted = false,\n modifiers,\n open,\n placement = 'bottom',\n popperOptions = defaultPopperOptions,\n popperRef,\n style,\n transition = false,\n slotProps = {},\n slots = {}\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded2);\n const [exited, setExited] = React.useState(true);\n const handleEnter = () => {\n setExited(false);\n };\n const handleExited = () => {\n setExited(true);\n };\n if (!keepMounted && !open && (!transition || exited)) {\n return null;\n }\n\n // If the container prop is provided, use that\n // If the anchorEl prop is provided, use its parent body element as the container\n // If neither are provided let the Modal take care of choosing the container\n let container;\n if (containerProp) {\n container = containerProp;\n } else if (anchorEl) {\n const resolvedAnchorEl = resolveAnchorEl(anchorEl);\n container = resolvedAnchorEl && isHTMLElement(resolvedAnchorEl) ? ownerDocument(resolvedAnchorEl).body : ownerDocument(null).body;\n }\n const display = !open && keepMounted && (!transition || exited) ? 'none' : undefined;\n const transitionProps = transition ? {\n in: open,\n onEnter: handleEnter,\n onExited: handleExited\n } : undefined;\n return /*#__PURE__*/_jsx(Portal, {\n disablePortal: disablePortal,\n container: container,\n children: /*#__PURE__*/_jsx(PopperTooltip, _extends({\n anchorEl: anchorEl,\n direction: direction,\n disablePortal: disablePortal,\n modifiers: modifiers,\n ref: forwardedRef,\n open: transition ? !exited : open,\n placement: placement,\n popperOptions: popperOptions,\n popperRef: popperRef,\n slotProps: slotProps,\n slots: slots\n }, other, {\n style: _extends({\n // Prevents scroll issue, waiting for Popper.js to add this style once initiated.\n position: 'fixed',\n // Fix Popper.js display issue\n top: 0,\n left: 0,\n display\n }, style),\n TransitionProps: transitionProps,\n children: children\n }))\n });\n});\nprocess.env.NODE_ENV !== \"production\" ? Popper.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * An HTML element, [virtualElement](https://popper.js.org/docs/v2/virtual-elements/),\n * or a function that returns either.\n * It's used to set the position of the popper.\n * The return value will passed as the reference object of the Popper instance.\n */\n anchorEl: chainPropTypes(PropTypes.oneOfType([HTMLElementType, PropTypes.object, PropTypes.func]), props => {\n if (props.open) {\n const resolvedAnchorEl = resolveAnchorEl(props.anchorEl);\n if (resolvedAnchorEl && isHTMLElement(resolvedAnchorEl) && resolvedAnchorEl.nodeType === 1) {\n const box = resolvedAnchorEl.getBoundingClientRect();\n if (process.env.NODE_ENV !== 'test' && box.top === 0 && box.left === 0 && box.right === 0 && box.bottom === 0) {\n return new Error(['MUI: The `anchorEl` prop provided to the component is invalid.', 'The anchor element should be part of the document layout.', \"Make sure the element is present in the document or that it's not display none.\"].join('\\n'));\n }\n } else if (!resolvedAnchorEl || typeof resolvedAnchorEl.getBoundingClientRect !== 'function' || isVirtualElement(resolvedAnchorEl) && resolvedAnchorEl.contextElement != null && resolvedAnchorEl.contextElement.nodeType !== 1) {\n return new Error(['MUI: The `anchorEl` prop provided to the component is invalid.', 'It should be an HTML element instance or a virtualElement ', '(https://popper.js.org/docs/v2/virtual-elements/).'].join('\\n'));\n }\n }\n return null;\n }),\n /**\n * Popper render function or node.\n */\n children: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.node, PropTypes.func]),\n /**\n * An HTML element or function that returns one.\n * The `container` will have the portal children appended to it.\n *\n * You can also provide a callback, which is called in a React layout effect.\n * This lets you set the container from a ref, and also makes server-side rendering possible.\n *\n * By default, it uses the body of the top-level document object,\n * so it's simply `document.body` most of the time.\n */\n container: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.func]),\n /**\n * Direction of the text.\n * @default 'ltr'\n */\n direction: PropTypes.oneOf(['ltr', 'rtl']),\n /**\n * The `children` will be under the DOM hierarchy of the parent component.\n * @default false\n */\n disablePortal: PropTypes.bool,\n /**\n * Always keep the children in the DOM.\n * This prop can be useful in SEO situation or\n * when you want to maximize the responsiveness of the Popper.\n * @default false\n */\n keepMounted: PropTypes.bool,\n /**\n * Popper.js is based on a \"plugin-like\" architecture,\n * most of its features are fully encapsulated \"modifiers\".\n *\n * A modifier is a function that is called each time Popper.js needs to\n * compute the position of the popper.\n * For this reason, modifiers should be very performant to avoid bottlenecks.\n * To learn how to create a modifier, [read the modifiers documentation](https://popper.js.org/docs/v2/modifiers/).\n */\n modifiers: PropTypes.arrayOf(PropTypes.shape({\n data: PropTypes.object,\n effect: PropTypes.func,\n enabled: PropTypes.bool,\n fn: PropTypes.func,\n name: PropTypes.any,\n options: PropTypes.object,\n phase: PropTypes.oneOf(['afterMain', 'afterRead', 'afterWrite', 'beforeMain', 'beforeRead', 'beforeWrite', 'main', 'read', 'write']),\n requires: PropTypes.arrayOf(PropTypes.string),\n requiresIfExists: PropTypes.arrayOf(PropTypes.string)\n })),\n /**\n * If `true`, the component is shown.\n */\n open: PropTypes.bool.isRequired,\n /**\n * Popper placement.\n * @default 'bottom'\n */\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n /**\n * Options provided to the [`Popper.js`](https://popper.js.org/docs/v2/constructors/#options) instance.\n * @default {}\n */\n popperOptions: PropTypes.shape({\n modifiers: PropTypes.array,\n onFirstUpdate: PropTypes.func,\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n strategy: PropTypes.oneOf(['absolute', 'fixed'])\n }),\n /**\n * A ref that points to the used popper instance.\n */\n popperRef: refType,\n /**\n * The props used for each slot inside the Popper.\n * @default {}\n */\n slotProps: PropTypes.shape({\n root: PropTypes.oneOfType([PropTypes.func, PropTypes.object])\n }),\n /**\n * The components used for each slot inside the Popper.\n * Either a string to use a HTML element or a component.\n * @default {}\n */\n slots: PropTypes.shape({\n root: PropTypes.elementType\n }),\n /**\n * Help supporting a react-transition-group/Transition component.\n * @default false\n */\n transition: PropTypes.bool\n} : void 0;\nexport { Popper };","'use client';\n\nimport * as React from 'react';\nimport { useTheme as useThemeSystem } from '@mui/system';\nimport defaultTheme from './defaultTheme';\nimport THEME_ID from './identifier';\nexport default function useTheme() {\n const theme = useThemeSystem(defaultTheme);\n if (process.env.NODE_ENV !== 'production') {\n // eslint-disable-next-line react-hooks/rules-of-hooks\n React.useDebugValue(theme);\n }\n return theme[THEME_ID] || theme;\n}","export default function _setPrototypeOf(o, p) {\n _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function _setPrototypeOf(o, p) {\n o.__proto__ = p;\n return o;\n };\n return _setPrototypeOf(o, p);\n}","import setPrototypeOf from \"./setPrototypeOf.js\";\nexport default function _inheritsLoose(subClass, superClass) {\n subClass.prototype = Object.create(superClass.prototype);\n subClass.prototype.constructor = subClass;\n setPrototypeOf(subClass, superClass);\n}","export default {\n disabled: false\n};","import PropTypes from 'prop-types';\nexport var timeoutsShape = process.env.NODE_ENV !== 'production' ? PropTypes.oneOfType([PropTypes.number, PropTypes.shape({\n enter: PropTypes.number,\n exit: PropTypes.number,\n appear: PropTypes.number\n}).isRequired]) : null;\nexport var classNamesShape = process.env.NODE_ENV !== 'production' ? PropTypes.oneOfType([PropTypes.string, PropTypes.shape({\n enter: PropTypes.string,\n exit: PropTypes.string,\n active: PropTypes.string\n}), PropTypes.shape({\n enter: PropTypes.string,\n enterDone: PropTypes.string,\n enterActive: PropTypes.string,\n exit: PropTypes.string,\n exitDone: PropTypes.string,\n exitActive: PropTypes.string\n})]) : null;","import React from 'react';\nexport default React.createContext(null);","export var forceReflow = function forceReflow(node) {\n return node.scrollTop;\n};","import _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _inheritsLoose from \"@babel/runtime/helpers/esm/inheritsLoose\";\nimport PropTypes from 'prop-types';\nimport React from 'react';\nimport ReactDOM from 'react-dom';\nimport config from './config';\nimport { timeoutsShape } from './utils/PropTypes';\nimport TransitionGroupContext from './TransitionGroupContext';\nimport { forceReflow } from './utils/reflow';\nexport var UNMOUNTED = 'unmounted';\nexport var EXITED = 'exited';\nexport var ENTERING = 'entering';\nexport var ENTERED = 'entered';\nexport var EXITING = 'exiting';\n/**\n * The Transition component lets you describe a transition from one component\n * state to another _over time_ with a simple declarative API. Most commonly\n * it's used to animate the mounting and unmounting of a component, but can also\n * be used to describe in-place transition states as well.\n *\n * ---\n *\n * **Note**: `Transition` is a platform-agnostic base component. If you're using\n * transitions in CSS, you'll probably want to use\n * [`CSSTransition`](https://reactcommunity.org/react-transition-group/css-transition)\n * instead. It inherits all the features of `Transition`, but contains\n * additional features necessary to play nice with CSS transitions (hence the\n * name of the component).\n *\n * ---\n *\n * By default the `Transition` component does not alter the behavior of the\n * component it renders, it only tracks \"enter\" and \"exit\" states for the\n * components. It's up to you to give meaning and effect to those states. For\n * example we can add styles to a component when it enters or exits:\n *\n * ```jsx\n * import { Transition } from 'react-transition-group';\n *\n * const duration = 300;\n *\n * const defaultStyle = {\n * transition: `opacity ${duration}ms ease-in-out`,\n * opacity: 0,\n * }\n *\n * const transitionStyles = {\n * entering: { opacity: 1 },\n * entered: { opacity: 1 },\n * exiting: { opacity: 0 },\n * exited: { opacity: 0 },\n * };\n *\n * const Fade = ({ in: inProp }) => (\n * \n * {state => (\n *
    \n * I'm a fade Transition!\n *
    \n * )}\n *
    \n * );\n * ```\n *\n * There are 4 main states a Transition can be in:\n * - `'entering'`\n * - `'entered'`\n * - `'exiting'`\n * - `'exited'`\n *\n * Transition state is toggled via the `in` prop. When `true` the component\n * begins the \"Enter\" stage. During this stage, the component will shift from\n * its current transition state, to `'entering'` for the duration of the\n * transition and then to the `'entered'` stage once it's complete. Let's take\n * the following example (we'll use the\n * [useState](https://reactjs.org/docs/hooks-reference.html#usestate) hook):\n *\n * ```jsx\n * function App() {\n * const [inProp, setInProp] = useState(false);\n * return (\n *
    \n * \n * {state => (\n * // ...\n * )}\n * \n * \n *
    \n * );\n * }\n * ```\n *\n * When the button is clicked the component will shift to the `'entering'` state\n * and stay there for 500ms (the value of `timeout`) before it finally switches\n * to `'entered'`.\n *\n * When `in` is `false` the same thing happens except the state moves from\n * `'exiting'` to `'exited'`.\n */\n\nvar Transition = /*#__PURE__*/function (_React$Component) {\n _inheritsLoose(Transition, _React$Component);\n\n function Transition(props, context) {\n var _this;\n\n _this = _React$Component.call(this, props, context) || this;\n var parentGroup = context; // In the context of a TransitionGroup all enters are really appears\n\n var appear = parentGroup && !parentGroup.isMounting ? props.enter : props.appear;\n var initialStatus;\n _this.appearStatus = null;\n\n if (props.in) {\n if (appear) {\n initialStatus = EXITED;\n _this.appearStatus = ENTERING;\n } else {\n initialStatus = ENTERED;\n }\n } else {\n if (props.unmountOnExit || props.mountOnEnter) {\n initialStatus = UNMOUNTED;\n } else {\n initialStatus = EXITED;\n }\n }\n\n _this.state = {\n status: initialStatus\n };\n _this.nextCallback = null;\n return _this;\n }\n\n Transition.getDerivedStateFromProps = function getDerivedStateFromProps(_ref, prevState) {\n var nextIn = _ref.in;\n\n if (nextIn && prevState.status === UNMOUNTED) {\n return {\n status: EXITED\n };\n }\n\n return null;\n } // getSnapshotBeforeUpdate(prevProps) {\n // let nextStatus = null\n // if (prevProps !== this.props) {\n // const { status } = this.state\n // if (this.props.in) {\n // if (status !== ENTERING && status !== ENTERED) {\n // nextStatus = ENTERING\n // }\n // } else {\n // if (status === ENTERING || status === ENTERED) {\n // nextStatus = EXITING\n // }\n // }\n // }\n // return { nextStatus }\n // }\n ;\n\n var _proto = Transition.prototype;\n\n _proto.componentDidMount = function componentDidMount() {\n this.updateStatus(true, this.appearStatus);\n };\n\n _proto.componentDidUpdate = function componentDidUpdate(prevProps) {\n var nextStatus = null;\n\n if (prevProps !== this.props) {\n var status = this.state.status;\n\n if (this.props.in) {\n if (status !== ENTERING && status !== ENTERED) {\n nextStatus = ENTERING;\n }\n } else {\n if (status === ENTERING || status === ENTERED) {\n nextStatus = EXITING;\n }\n }\n }\n\n this.updateStatus(false, nextStatus);\n };\n\n _proto.componentWillUnmount = function componentWillUnmount() {\n this.cancelNextCallback();\n };\n\n _proto.getTimeouts = function getTimeouts() {\n var timeout = this.props.timeout;\n var exit, enter, appear;\n exit = enter = appear = timeout;\n\n if (timeout != null && typeof timeout !== 'number') {\n exit = timeout.exit;\n enter = timeout.enter; // TODO: remove fallback for next major\n\n appear = timeout.appear !== undefined ? timeout.appear : enter;\n }\n\n return {\n exit: exit,\n enter: enter,\n appear: appear\n };\n };\n\n _proto.updateStatus = function updateStatus(mounting, nextStatus) {\n if (mounting === void 0) {\n mounting = false;\n }\n\n if (nextStatus !== null) {\n // nextStatus will always be ENTERING or EXITING.\n this.cancelNextCallback();\n\n if (nextStatus === ENTERING) {\n if (this.props.unmountOnExit || this.props.mountOnEnter) {\n var node = this.props.nodeRef ? this.props.nodeRef.current : ReactDOM.findDOMNode(this); // https://github.com/reactjs/react-transition-group/pull/749\n // With unmountOnExit or mountOnEnter, the enter animation should happen at the transition between `exited` and `entering`.\n // To make the animation happen, we have to separate each rendering and avoid being processed as batched.\n\n if (node) forceReflow(node);\n }\n\n this.performEnter(mounting);\n } else {\n this.performExit();\n }\n } else if (this.props.unmountOnExit && this.state.status === EXITED) {\n this.setState({\n status: UNMOUNTED\n });\n }\n };\n\n _proto.performEnter = function performEnter(mounting) {\n var _this2 = this;\n\n var enter = this.props.enter;\n var appearing = this.context ? this.context.isMounting : mounting;\n\n var _ref2 = this.props.nodeRef ? [appearing] : [ReactDOM.findDOMNode(this), appearing],\n maybeNode = _ref2[0],\n maybeAppearing = _ref2[1];\n\n var timeouts = this.getTimeouts();\n var enterTimeout = appearing ? timeouts.appear : timeouts.enter; // no enter animation skip right to ENTERED\n // if we are mounting and running this it means appear _must_ be set\n\n if (!mounting && !enter || config.disabled) {\n this.safeSetState({\n status: ENTERED\n }, function () {\n _this2.props.onEntered(maybeNode);\n });\n return;\n }\n\n this.props.onEnter(maybeNode, maybeAppearing);\n this.safeSetState({\n status: ENTERING\n }, function () {\n _this2.props.onEntering(maybeNode, maybeAppearing);\n\n _this2.onTransitionEnd(enterTimeout, function () {\n _this2.safeSetState({\n status: ENTERED\n }, function () {\n _this2.props.onEntered(maybeNode, maybeAppearing);\n });\n });\n });\n };\n\n _proto.performExit = function performExit() {\n var _this3 = this;\n\n var exit = this.props.exit;\n var timeouts = this.getTimeouts();\n var maybeNode = this.props.nodeRef ? undefined : ReactDOM.findDOMNode(this); // no exit animation skip right to EXITED\n\n if (!exit || config.disabled) {\n this.safeSetState({\n status: EXITED\n }, function () {\n _this3.props.onExited(maybeNode);\n });\n return;\n }\n\n this.props.onExit(maybeNode);\n this.safeSetState({\n status: EXITING\n }, function () {\n _this3.props.onExiting(maybeNode);\n\n _this3.onTransitionEnd(timeouts.exit, function () {\n _this3.safeSetState({\n status: EXITED\n }, function () {\n _this3.props.onExited(maybeNode);\n });\n });\n });\n };\n\n _proto.cancelNextCallback = function cancelNextCallback() {\n if (this.nextCallback !== null) {\n this.nextCallback.cancel();\n this.nextCallback = null;\n }\n };\n\n _proto.safeSetState = function safeSetState(nextState, callback) {\n // This shouldn't be necessary, but there are weird race conditions with\n // setState callbacks and unmounting in testing, so always make sure that\n // we can cancel any pending setState callbacks after we unmount.\n callback = this.setNextCallback(callback);\n this.setState(nextState, callback);\n };\n\n _proto.setNextCallback = function setNextCallback(callback) {\n var _this4 = this;\n\n var active = true;\n\n this.nextCallback = function (event) {\n if (active) {\n active = false;\n _this4.nextCallback = null;\n callback(event);\n }\n };\n\n this.nextCallback.cancel = function () {\n active = false;\n };\n\n return this.nextCallback;\n };\n\n _proto.onTransitionEnd = function onTransitionEnd(timeout, handler) {\n this.setNextCallback(handler);\n var node = this.props.nodeRef ? this.props.nodeRef.current : ReactDOM.findDOMNode(this);\n var doesNotHaveTimeoutOrListener = timeout == null && !this.props.addEndListener;\n\n if (!node || doesNotHaveTimeoutOrListener) {\n setTimeout(this.nextCallback, 0);\n return;\n }\n\n if (this.props.addEndListener) {\n var _ref3 = this.props.nodeRef ? [this.nextCallback] : [node, this.nextCallback],\n maybeNode = _ref3[0],\n maybeNextCallback = _ref3[1];\n\n this.props.addEndListener(maybeNode, maybeNextCallback);\n }\n\n if (timeout != null) {\n setTimeout(this.nextCallback, timeout);\n }\n };\n\n _proto.render = function render() {\n var status = this.state.status;\n\n if (status === UNMOUNTED) {\n return null;\n }\n\n var _this$props = this.props,\n children = _this$props.children,\n _in = _this$props.in,\n _mountOnEnter = _this$props.mountOnEnter,\n _unmountOnExit = _this$props.unmountOnExit,\n _appear = _this$props.appear,\n _enter = _this$props.enter,\n _exit = _this$props.exit,\n _timeout = _this$props.timeout,\n _addEndListener = _this$props.addEndListener,\n _onEnter = _this$props.onEnter,\n _onEntering = _this$props.onEntering,\n _onEntered = _this$props.onEntered,\n _onExit = _this$props.onExit,\n _onExiting = _this$props.onExiting,\n _onExited = _this$props.onExited,\n _nodeRef = _this$props.nodeRef,\n childProps = _objectWithoutPropertiesLoose(_this$props, [\"children\", \"in\", \"mountOnEnter\", \"unmountOnExit\", \"appear\", \"enter\", \"exit\", \"timeout\", \"addEndListener\", \"onEnter\", \"onEntering\", \"onEntered\", \"onExit\", \"onExiting\", \"onExited\", \"nodeRef\"]);\n\n return (\n /*#__PURE__*/\n // allows for nested Transitions\n React.createElement(TransitionGroupContext.Provider, {\n value: null\n }, typeof children === 'function' ? children(status, childProps) : React.cloneElement(React.Children.only(children), childProps))\n );\n };\n\n return Transition;\n}(React.Component);\n\nTransition.contextType = TransitionGroupContext;\nTransition.propTypes = process.env.NODE_ENV !== \"production\" ? {\n /**\n * A React reference to DOM element that need to transition:\n * https://stackoverflow.com/a/51127130/4671932\n *\n * - When `nodeRef` prop is used, `node` is not passed to callback functions\n * (e.g. `onEnter`) because user already has direct access to the node.\n * - When changing `key` prop of `Transition` in a `TransitionGroup` a new\n * `nodeRef` need to be provided to `Transition` with changed `key` prop\n * (see\n * [test/CSSTransition-test.js](https://github.com/reactjs/react-transition-group/blob/13435f897b3ab71f6e19d724f145596f5910581c/test/CSSTransition-test.js#L362-L437)).\n */\n nodeRef: PropTypes.shape({\n current: typeof Element === 'undefined' ? PropTypes.any : function (propValue, key, componentName, location, propFullName, secret) {\n var value = propValue[key];\n return PropTypes.instanceOf(value && 'ownerDocument' in value ? value.ownerDocument.defaultView.Element : Element)(propValue, key, componentName, location, propFullName, secret);\n }\n }),\n\n /**\n * A `function` child can be used instead of a React element. This function is\n * called with the current transition status (`'entering'`, `'entered'`,\n * `'exiting'`, `'exited'`), which can be used to apply context\n * specific props to a component.\n *\n * ```jsx\n * \n * {state => (\n * \n * )}\n * \n * ```\n */\n children: PropTypes.oneOfType([PropTypes.func.isRequired, PropTypes.element.isRequired]).isRequired,\n\n /**\n * Show the component; triggers the enter or exit states\n */\n in: PropTypes.bool,\n\n /**\n * By default the child component is mounted immediately along with\n * the parent `Transition` component. If you want to \"lazy mount\" the component on the\n * first `in={true}` you can set `mountOnEnter`. After the first enter transition the component will stay\n * mounted, even on \"exited\", unless you also specify `unmountOnExit`.\n */\n mountOnEnter: PropTypes.bool,\n\n /**\n * By default the child component stays mounted after it reaches the `'exited'` state.\n * Set `unmountOnExit` if you'd prefer to unmount the component after it finishes exiting.\n */\n unmountOnExit: PropTypes.bool,\n\n /**\n * By default the child component does not perform the enter transition when\n * it first mounts, regardless of the value of `in`. If you want this\n * behavior, set both `appear` and `in` to `true`.\n *\n * > **Note**: there are no special appear states like `appearing`/`appeared`, this prop\n * > only adds an additional enter transition. However, in the\n * > `` component that first enter transition does result in\n * > additional `.appear-*` classes, that way you can choose to style it\n * > differently.\n */\n appear: PropTypes.bool,\n\n /**\n * Enable or disable enter transitions.\n */\n enter: PropTypes.bool,\n\n /**\n * Enable or disable exit transitions.\n */\n exit: PropTypes.bool,\n\n /**\n * The duration of the transition, in milliseconds.\n * Required unless `addEndListener` is provided.\n *\n * You may specify a single timeout for all transitions:\n *\n * ```jsx\n * timeout={500}\n * ```\n *\n * or individually:\n *\n * ```jsx\n * timeout={{\n * appear: 500,\n * enter: 300,\n * exit: 500,\n * }}\n * ```\n *\n * - `appear` defaults to the value of `enter`\n * - `enter` defaults to `0`\n * - `exit` defaults to `0`\n *\n * @type {number | { enter?: number, exit?: number, appear?: number }}\n */\n timeout: function timeout(props) {\n var pt = timeoutsShape;\n if (!props.addEndListener) pt = pt.isRequired;\n\n for (var _len = arguments.length, args = new Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) {\n args[_key - 1] = arguments[_key];\n }\n\n return pt.apply(void 0, [props].concat(args));\n },\n\n /**\n * Add a custom transition end trigger. Called with the transitioning\n * DOM node and a `done` callback. Allows for more fine grained transition end\n * logic. Timeouts are still used as a fallback if provided.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * ```jsx\n * addEndListener={(node, done) => {\n * // use the css transitionend event to mark the finish of a transition\n * node.addEventListener('transitionend', done, false);\n * }}\n * ```\n */\n addEndListener: PropTypes.func,\n\n /**\n * Callback fired before the \"entering\" status is applied. An extra parameter\n * `isAppearing` is supplied to indicate if the enter stage is occurring on the initial mount\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement, isAppearing: bool) -> void\n */\n onEnter: PropTypes.func,\n\n /**\n * Callback fired after the \"entering\" status is applied. An extra parameter\n * `isAppearing` is supplied to indicate if the enter stage is occurring on the initial mount\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement, isAppearing: bool)\n */\n onEntering: PropTypes.func,\n\n /**\n * Callback fired after the \"entered\" status is applied. An extra parameter\n * `isAppearing` is supplied to indicate if the enter stage is occurring on the initial mount\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement, isAppearing: bool) -> void\n */\n onEntered: PropTypes.func,\n\n /**\n * Callback fired before the \"exiting\" status is applied.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement) -> void\n */\n onExit: PropTypes.func,\n\n /**\n * Callback fired after the \"exiting\" status is applied.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement) -> void\n */\n onExiting: PropTypes.func,\n\n /**\n * Callback fired after the \"exited\" status is applied.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed\n *\n * @type Function(node: HtmlElement) -> void\n */\n onExited: PropTypes.func\n} : {}; // Name the function so it is clearer in the documentation\n\nfunction noop() {}\n\nTransition.defaultProps = {\n in: false,\n mountOnEnter: false,\n unmountOnExit: false,\n appear: false,\n enter: true,\n exit: true,\n onEnter: noop,\n onEntering: noop,\n onEntered: noop,\n onExit: noop,\n onExiting: noop,\n onExited: noop\n};\nTransition.UNMOUNTED = UNMOUNTED;\nTransition.EXITED = EXITED;\nTransition.ENTERING = ENTERING;\nTransition.ENTERED = ENTERED;\nTransition.EXITING = EXITING;\nexport default Transition;","export const reflow = node => node.scrollTop;\nexport function getTransitionProps(props, options) {\n var _style$transitionDura, _style$transitionTimi;\n const {\n timeout,\n easing,\n style = {}\n } = props;\n return {\n duration: (_style$transitionDura = style.transitionDuration) != null ? _style$transitionDura : typeof timeout === 'number' ? timeout : timeout[options.mode] || 0,\n easing: (_style$transitionTimi = style.transitionTimingFunction) != null ? _style$transitionTimi : typeof easing === 'object' ? easing[options.mode] : easing,\n delay: style.transitionDelay\n };\n}","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"addEndListener\", \"appear\", \"children\", \"easing\", \"in\", \"onEnter\", \"onEntered\", \"onEntering\", \"onExit\", \"onExited\", \"onExiting\", \"style\", \"timeout\", \"TransitionComponent\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport { elementAcceptingRef, unstable_useTimeout as useTimeout } from '@mui/utils';\nimport { Transition } from 'react-transition-group';\nimport useTheme from '../styles/useTheme';\nimport { getTransitionProps, reflow } from '../transitions/utils';\nimport useForkRef from '../utils/useForkRef';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nfunction getScale(value) {\n return `scale(${value}, ${value ** 2})`;\n}\nconst styles = {\n entering: {\n opacity: 1,\n transform: getScale(1)\n },\n entered: {\n opacity: 1,\n transform: 'none'\n }\n};\n\n/*\n TODO v6: remove\n Conditionally apply a workaround for the CSS transition bug in Safari 15.4 / WebKit browsers.\n */\nconst isWebKit154 = typeof navigator !== 'undefined' && /^((?!chrome|android).)*(safari|mobile)/i.test(navigator.userAgent) && /(os |version\\/)15(.|_)4/i.test(navigator.userAgent);\n\n/**\n * The Grow transition is used by the [Tooltip](/material-ui/react-tooltip/) and\n * [Popover](/material-ui/react-popover/) components.\n * It uses [react-transition-group](https://github.com/reactjs/react-transition-group) internally.\n */\nconst Grow = /*#__PURE__*/React.forwardRef(function Grow(props, ref) {\n const {\n addEndListener,\n appear = true,\n children,\n easing,\n in: inProp,\n onEnter,\n onEntered,\n onEntering,\n onExit,\n onExited,\n onExiting,\n style,\n timeout = 'auto',\n // eslint-disable-next-line react/prop-types\n TransitionComponent = Transition\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const timer = useTimeout();\n const autoTimeout = React.useRef();\n const theme = useTheme();\n const nodeRef = React.useRef(null);\n const handleRef = useForkRef(nodeRef, children.ref, ref);\n const normalizedTransitionCallback = callback => maybeIsAppearing => {\n if (callback) {\n const node = nodeRef.current;\n\n // onEnterXxx and onExitXxx callbacks have a different arguments.length value.\n if (maybeIsAppearing === undefined) {\n callback(node);\n } else {\n callback(node, maybeIsAppearing);\n }\n }\n };\n const handleEntering = normalizedTransitionCallback(onEntering);\n const handleEnter = normalizedTransitionCallback((node, isAppearing) => {\n reflow(node); // So the animation always start from the start.\n\n const {\n duration: transitionDuration,\n delay,\n easing: transitionTimingFunction\n } = getTransitionProps({\n style,\n timeout,\n easing\n }, {\n mode: 'enter'\n });\n let duration;\n if (timeout === 'auto') {\n duration = theme.transitions.getAutoHeightDuration(node.clientHeight);\n autoTimeout.current = duration;\n } else {\n duration = transitionDuration;\n }\n node.style.transition = [theme.transitions.create('opacity', {\n duration,\n delay\n }), theme.transitions.create('transform', {\n duration: isWebKit154 ? duration : duration * 0.666,\n delay,\n easing: transitionTimingFunction\n })].join(',');\n if (onEnter) {\n onEnter(node, isAppearing);\n }\n });\n const handleEntered = normalizedTransitionCallback(onEntered);\n const handleExiting = normalizedTransitionCallback(onExiting);\n const handleExit = normalizedTransitionCallback(node => {\n const {\n duration: transitionDuration,\n delay,\n easing: transitionTimingFunction\n } = getTransitionProps({\n style,\n timeout,\n easing\n }, {\n mode: 'exit'\n });\n let duration;\n if (timeout === 'auto') {\n duration = theme.transitions.getAutoHeightDuration(node.clientHeight);\n autoTimeout.current = duration;\n } else {\n duration = transitionDuration;\n }\n node.style.transition = [theme.transitions.create('opacity', {\n duration,\n delay\n }), theme.transitions.create('transform', {\n duration: isWebKit154 ? duration : duration * 0.666,\n delay: isWebKit154 ? delay : delay || duration * 0.333,\n easing: transitionTimingFunction\n })].join(',');\n node.style.opacity = 0;\n node.style.transform = getScale(0.75);\n if (onExit) {\n onExit(node);\n }\n });\n const handleExited = normalizedTransitionCallback(onExited);\n const handleAddEndListener = next => {\n if (timeout === 'auto') {\n timer.start(autoTimeout.current || 0, next);\n }\n if (addEndListener) {\n // Old call signature before `react-transition-group` implemented `nodeRef`\n addEndListener(nodeRef.current, next);\n }\n };\n return /*#__PURE__*/_jsx(TransitionComponent, _extends({\n appear: appear,\n in: inProp,\n nodeRef: nodeRef,\n onEnter: handleEnter,\n onEntered: handleEntered,\n onEntering: handleEntering,\n onExit: handleExit,\n onExited: handleExited,\n onExiting: handleExiting,\n addEndListener: handleAddEndListener,\n timeout: timeout === 'auto' ? null : timeout\n }, other, {\n children: (state, childProps) => {\n return /*#__PURE__*/React.cloneElement(children, _extends({\n style: _extends({\n opacity: 0,\n transform: getScale(0.75),\n visibility: state === 'exited' && !inProp ? 'hidden' : undefined\n }, styles[state], style, children.props.style),\n ref: handleRef\n }, childProps));\n }\n }));\n});\nprocess.env.NODE_ENV !== \"production\" ? Grow.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the d.ts file and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * Add a custom transition end trigger. Called with the transitioning DOM\n * node and a done callback. Allows for more fine grained transition end\n * logic. Note: Timeouts are still used as a fallback if provided.\n */\n addEndListener: PropTypes.func,\n /**\n * Perform the enter transition when it first mounts if `in` is also `true`.\n * Set this to `false` to disable this behavior.\n * @default true\n */\n appear: PropTypes.bool,\n /**\n * A single child content element.\n */\n children: elementAcceptingRef.isRequired,\n /**\n * The transition timing function.\n * You may specify a single easing or a object containing enter and exit values.\n */\n easing: PropTypes.oneOfType([PropTypes.shape({\n enter: PropTypes.string,\n exit: PropTypes.string\n }), PropTypes.string]),\n /**\n * If `true`, the component will transition in.\n */\n in: PropTypes.bool,\n /**\n * @ignore\n */\n onEnter: PropTypes.func,\n /**\n * @ignore\n */\n onEntered: PropTypes.func,\n /**\n * @ignore\n */\n onEntering: PropTypes.func,\n /**\n * @ignore\n */\n onExit: PropTypes.func,\n /**\n * @ignore\n */\n onExited: PropTypes.func,\n /**\n * @ignore\n */\n onExiting: PropTypes.func,\n /**\n * @ignore\n */\n style: PropTypes.object,\n /**\n * The duration for the transition, in milliseconds.\n * You may specify a single timeout for all transitions, or individually with an object.\n *\n * Set to 'auto' to automatically calculate transition time based on height.\n * @default 'auto'\n */\n timeout: PropTypes.oneOfType([PropTypes.oneOf(['auto']), PropTypes.number, PropTypes.shape({\n appear: PropTypes.number,\n enter: PropTypes.number,\n exit: PropTypes.number\n })])\n} : void 0;\nGrow.muiSupportAuto = true;\nexport default Grow;","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"anchorEl\", \"component\", \"components\", \"componentsProps\", \"container\", \"disablePortal\", \"keepMounted\", \"modifiers\", \"open\", \"placement\", \"popperOptions\", \"popperRef\", \"transition\", \"slots\", \"slotProps\"];\nimport { Popper as BasePopper } from '@mui/base/Popper';\nimport { useThemeWithoutDefault as useTheme } from '@mui/system';\nimport { HTMLElementType, refType } from '@mui/utils';\nimport PropTypes from 'prop-types';\nimport * as React from 'react';\nimport { styled, useThemeProps } from '../styles';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nconst PopperRoot = styled(BasePopper, {\n name: 'MuiPopper',\n slot: 'Root',\n overridesResolver: (props, styles) => styles.root\n})({});\n\n/**\n *\n * Demos:\n *\n * - [Autocomplete](https://mui.com/material-ui/react-autocomplete/)\n * - [Menu](https://mui.com/material-ui/react-menu/)\n * - [Popper](https://mui.com/material-ui/react-popper/)\n *\n * API:\n *\n * - [Popper API](https://mui.com/material-ui/api/popper/)\n */\nconst Popper = /*#__PURE__*/React.forwardRef(function Popper(inProps, ref) {\n var _slots$root;\n const theme = useTheme();\n const props = useThemeProps({\n props: inProps,\n name: 'MuiPopper'\n });\n const {\n anchorEl,\n component,\n components,\n componentsProps,\n container,\n disablePortal,\n keepMounted,\n modifiers,\n open,\n placement,\n popperOptions,\n popperRef,\n transition,\n slots,\n slotProps\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const RootComponent = (_slots$root = slots == null ? void 0 : slots.root) != null ? _slots$root : components == null ? void 0 : components.Root;\n const otherProps = _extends({\n anchorEl,\n container,\n disablePortal,\n keepMounted,\n modifiers,\n open,\n placement,\n popperOptions,\n popperRef,\n transition\n }, other);\n return /*#__PURE__*/_jsx(PopperRoot, _extends({\n as: component,\n direction: theme == null ? void 0 : theme.direction,\n slots: {\n root: RootComponent\n },\n slotProps: slotProps != null ? slotProps : componentsProps\n }, otherProps, {\n ref: ref\n }));\n});\nprocess.env.NODE_ENV !== \"production\" ? Popper.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * An HTML element, [virtualElement](https://popper.js.org/docs/v2/virtual-elements/),\n * or a function that returns either.\n * It's used to set the position of the popper.\n * The return value will passed as the reference object of the Popper instance.\n */\n anchorEl: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.object, PropTypes.func]),\n /**\n * Popper render function or node.\n */\n children: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.node, PropTypes.func]),\n /**\n * The component used for the root node.\n * Either a string to use a HTML element or a component.\n */\n component: PropTypes.elementType,\n /**\n * The components used for each slot inside the Popper.\n * Either a string to use a HTML element or a component.\n * @default {}\n */\n components: PropTypes.shape({\n Root: PropTypes.elementType\n }),\n /**\n * The props used for each slot inside the Popper.\n * @default {}\n */\n componentsProps: PropTypes.shape({\n root: PropTypes.oneOfType([PropTypes.func, PropTypes.object])\n }),\n /**\n * An HTML element or function that returns one.\n * The `container` will have the portal children appended to it.\n *\n * You can also provide a callback, which is called in a React layout effect.\n * This lets you set the container from a ref, and also makes server-side rendering possible.\n *\n * By default, it uses the body of the top-level document object,\n * so it's simply `document.body` most of the time.\n */\n container: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.func]),\n /**\n * The `children` will be under the DOM hierarchy of the parent component.\n * @default false\n */\n disablePortal: PropTypes.bool,\n /**\n * Always keep the children in the DOM.\n * This prop can be useful in SEO situation or\n * when you want to maximize the responsiveness of the Popper.\n * @default false\n */\n keepMounted: PropTypes.bool,\n /**\n * Popper.js is based on a \"plugin-like\" architecture,\n * most of its features are fully encapsulated \"modifiers\".\n *\n * A modifier is a function that is called each time Popper.js needs to\n * compute the position of the popper.\n * For this reason, modifiers should be very performant to avoid bottlenecks.\n * To learn how to create a modifier, [read the modifiers documentation](https://popper.js.org/docs/v2/modifiers/).\n */\n modifiers: PropTypes.arrayOf(PropTypes.shape({\n data: PropTypes.object,\n effect: PropTypes.func,\n enabled: PropTypes.bool,\n fn: PropTypes.func,\n name: PropTypes.any,\n options: PropTypes.object,\n phase: PropTypes.oneOf(['afterMain', 'afterRead', 'afterWrite', 'beforeMain', 'beforeRead', 'beforeWrite', 'main', 'read', 'write']),\n requires: PropTypes.arrayOf(PropTypes.string),\n requiresIfExists: PropTypes.arrayOf(PropTypes.string)\n })),\n /**\n * If `true`, the component is shown.\n */\n open: PropTypes.bool.isRequired,\n /**\n * Popper placement.\n * @default 'bottom'\n */\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n /**\n * Options provided to the [`Popper.js`](https://popper.js.org/docs/v2/constructors/#options) instance.\n * @default {}\n */\n popperOptions: PropTypes.shape({\n modifiers: PropTypes.array,\n onFirstUpdate: PropTypes.func,\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n strategy: PropTypes.oneOf(['absolute', 'fixed'])\n }),\n /**\n * A ref that points to the used popper instance.\n */\n popperRef: refType,\n /**\n * The props used for each slot inside the Popper.\n * @default {}\n */\n slotProps: PropTypes.shape({\n root: PropTypes.oneOfType([PropTypes.func, PropTypes.object])\n }),\n /**\n * The components used for each slot inside the Popper.\n * Either a string to use a HTML element or a component.\n * @default {}\n */\n slots: PropTypes.shape({\n root: PropTypes.elementType\n }),\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Help supporting a react-transition-group/Transition component.\n * @default false\n */\n transition: PropTypes.bool\n} : void 0;\nexport default Popper;","import generateUtilityClasses from '@mui/utils/generateUtilityClasses';\nimport generateUtilityClass from '@mui/utils/generateUtilityClass';\nexport function getTooltipUtilityClass(slot) {\n return generateUtilityClass('MuiTooltip', slot);\n}\nconst tooltipClasses = generateUtilityClasses('MuiTooltip', ['popper', 'popperInteractive', 'popperArrow', 'popperClose', 'tooltip', 'tooltipArrow', 'touch', 'tooltipPlacementLeft', 'tooltipPlacementRight', 'tooltipPlacementTop', 'tooltipPlacementBottom', 'arrow']);\nexport default tooltipClasses;","'use client';\n\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nconst _excluded = [\"arrow\", \"children\", \"classes\", \"components\", \"componentsProps\", \"describeChild\", \"disableFocusListener\", \"disableHoverListener\", \"disableInteractive\", \"disableTouchListener\", \"enterDelay\", \"enterNextDelay\", \"enterTouchDelay\", \"followCursor\", \"id\", \"leaveDelay\", \"leaveTouchDelay\", \"onClose\", \"onOpen\", \"open\", \"placement\", \"PopperComponent\", \"PopperProps\", \"slotProps\", \"slots\", \"title\", \"TransitionComponent\", \"TransitionProps\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport clsx from 'clsx';\nimport { elementAcceptingRef, unstable_useTimeout as useTimeout, unstable_Timeout as Timeout } from '@mui/utils';\nimport { unstable_composeClasses as composeClasses, appendOwnerState } from '@mui/base';\nimport { alpha } from '@mui/system';\nimport styled from '../styles/styled';\nimport useTheme from '../styles/useTheme';\nimport useThemeProps from '../styles/useThemeProps';\nimport capitalize from '../utils/capitalize';\nimport Grow from '../Grow';\nimport Popper from '../Popper';\nimport useEventCallback from '../utils/useEventCallback';\nimport useForkRef from '../utils/useForkRef';\nimport useId from '../utils/useId';\nimport useIsFocusVisible from '../utils/useIsFocusVisible';\nimport useControlled from '../utils/useControlled';\nimport tooltipClasses, { getTooltipUtilityClass } from './tooltipClasses';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nimport { jsxs as _jsxs } from \"react/jsx-runtime\";\nfunction round(value) {\n return Math.round(value * 1e5) / 1e5;\n}\nconst useUtilityClasses = ownerState => {\n const {\n classes,\n disableInteractive,\n arrow,\n touch,\n placement\n } = ownerState;\n const slots = {\n popper: ['popper', !disableInteractive && 'popperInteractive', arrow && 'popperArrow'],\n tooltip: ['tooltip', arrow && 'tooltipArrow', touch && 'touch', `tooltipPlacement${capitalize(placement.split('-')[0])}`],\n arrow: ['arrow']\n };\n return composeClasses(slots, getTooltipUtilityClass, classes);\n};\nconst TooltipPopper = styled(Popper, {\n name: 'MuiTooltip',\n slot: 'Popper',\n overridesResolver: (props, styles) => {\n const {\n ownerState\n } = props;\n return [styles.popper, !ownerState.disableInteractive && styles.popperInteractive, ownerState.arrow && styles.popperArrow, !ownerState.open && styles.popperClose];\n }\n})(({\n theme,\n ownerState,\n open\n}) => _extends({\n zIndex: (theme.vars || theme).zIndex.tooltip,\n pointerEvents: 'none'\n}, !ownerState.disableInteractive && {\n pointerEvents: 'auto'\n}, !open && {\n pointerEvents: 'none'\n}, ownerState.arrow && {\n [`&[data-popper-placement*=\"bottom\"] .${tooltipClasses.arrow}`]: {\n top: 0,\n marginTop: '-0.71em',\n '&::before': {\n transformOrigin: '0 100%'\n }\n },\n [`&[data-popper-placement*=\"top\"] .${tooltipClasses.arrow}`]: {\n bottom: 0,\n marginBottom: '-0.71em',\n '&::before': {\n transformOrigin: '100% 0'\n }\n },\n [`&[data-popper-placement*=\"right\"] .${tooltipClasses.arrow}`]: _extends({}, !ownerState.isRtl ? {\n left: 0,\n marginLeft: '-0.71em'\n } : {\n right: 0,\n marginRight: '-0.71em'\n }, {\n height: '1em',\n width: '0.71em',\n '&::before': {\n transformOrigin: '100% 100%'\n }\n }),\n [`&[data-popper-placement*=\"left\"] .${tooltipClasses.arrow}`]: _extends({}, !ownerState.isRtl ? {\n right: 0,\n marginRight: '-0.71em'\n } : {\n left: 0,\n marginLeft: '-0.71em'\n }, {\n height: '1em',\n width: '0.71em',\n '&::before': {\n transformOrigin: '0 0'\n }\n })\n}));\nconst TooltipTooltip = styled('div', {\n name: 'MuiTooltip',\n slot: 'Tooltip',\n overridesResolver: (props, styles) => {\n const {\n ownerState\n } = props;\n return [styles.tooltip, ownerState.touch && styles.touch, ownerState.arrow && styles.tooltipArrow, styles[`tooltipPlacement${capitalize(ownerState.placement.split('-')[0])}`]];\n }\n})(({\n theme,\n ownerState\n}) => _extends({\n backgroundColor: theme.vars ? theme.vars.palette.Tooltip.bg : alpha(theme.palette.grey[700], 0.92),\n borderRadius: (theme.vars || theme).shape.borderRadius,\n color: (theme.vars || theme).palette.common.white,\n fontFamily: theme.typography.fontFamily,\n padding: '4px 8px',\n fontSize: theme.typography.pxToRem(11),\n maxWidth: 300,\n margin: 2,\n wordWrap: 'break-word',\n fontWeight: theme.typography.fontWeightMedium\n}, ownerState.arrow && {\n position: 'relative',\n margin: 0\n}, ownerState.touch && {\n padding: '8px 16px',\n fontSize: theme.typography.pxToRem(14),\n lineHeight: `${round(16 / 14)}em`,\n fontWeight: theme.typography.fontWeightRegular\n}, {\n [`.${tooltipClasses.popper}[data-popper-placement*=\"left\"] &`]: _extends({\n transformOrigin: 'right center'\n }, !ownerState.isRtl ? _extends({\n marginRight: '14px'\n }, ownerState.touch && {\n marginRight: '24px'\n }) : _extends({\n marginLeft: '14px'\n }, ownerState.touch && {\n marginLeft: '24px'\n })),\n [`.${tooltipClasses.popper}[data-popper-placement*=\"right\"] &`]: _extends({\n transformOrigin: 'left center'\n }, !ownerState.isRtl ? _extends({\n marginLeft: '14px'\n }, ownerState.touch && {\n marginLeft: '24px'\n }) : _extends({\n marginRight: '14px'\n }, ownerState.touch && {\n marginRight: '24px'\n })),\n [`.${tooltipClasses.popper}[data-popper-placement*=\"top\"] &`]: _extends({\n transformOrigin: 'center bottom',\n marginBottom: '14px'\n }, ownerState.touch && {\n marginBottom: '24px'\n }),\n [`.${tooltipClasses.popper}[data-popper-placement*=\"bottom\"] &`]: _extends({\n transformOrigin: 'center top',\n marginTop: '14px'\n }, ownerState.touch && {\n marginTop: '24px'\n })\n}));\nconst TooltipArrow = styled('span', {\n name: 'MuiTooltip',\n slot: 'Arrow',\n overridesResolver: (props, styles) => styles.arrow\n})(({\n theme\n}) => ({\n overflow: 'hidden',\n position: 'absolute',\n width: '1em',\n height: '0.71em' /* = width / sqrt(2) = (length of the hypotenuse) */,\n boxSizing: 'border-box',\n color: theme.vars ? theme.vars.palette.Tooltip.bg : alpha(theme.palette.grey[700], 0.9),\n '&::before': {\n content: '\"\"',\n margin: 'auto',\n display: 'block',\n width: '100%',\n height: '100%',\n backgroundColor: 'currentColor',\n transform: 'rotate(45deg)'\n }\n}));\nlet hystersisOpen = false;\nconst hystersisTimer = new Timeout();\nlet cursorPosition = {\n x: 0,\n y: 0\n};\nexport function testReset() {\n hystersisOpen = false;\n hystersisTimer.clear();\n}\nfunction composeEventHandler(handler, eventHandler) {\n return event => {\n if (eventHandler) {\n eventHandler(event);\n }\n handler(event);\n };\n}\n\n// TODO v6: Remove PopperComponent, PopperProps, TransitionComponent and TransitionProps.\nconst Tooltip = /*#__PURE__*/React.forwardRef(function Tooltip(inProps, ref) {\n var _ref, _slots$popper, _ref2, _ref3, _slots$transition, _ref4, _slots$tooltip, _ref5, _slots$arrow, _slotProps$popper, _ref6, _slotProps$popper2, _slotProps$transition, _slotProps$tooltip, _ref7, _slotProps$tooltip2, _slotProps$arrow, _ref8, _slotProps$arrow2;\n const props = useThemeProps({\n props: inProps,\n name: 'MuiTooltip'\n });\n const {\n arrow = false,\n children: childrenProp,\n components = {},\n componentsProps = {},\n describeChild = false,\n disableFocusListener = false,\n disableHoverListener = false,\n disableInteractive: disableInteractiveProp = false,\n disableTouchListener = false,\n enterDelay = 100,\n enterNextDelay = 0,\n enterTouchDelay = 700,\n followCursor = false,\n id: idProp,\n leaveDelay = 0,\n leaveTouchDelay = 1500,\n onClose,\n onOpen,\n open: openProp,\n placement = 'bottom',\n PopperComponent: PopperComponentProp,\n PopperProps = {},\n slotProps = {},\n slots = {},\n title,\n TransitionComponent: TransitionComponentProp = Grow,\n TransitionProps\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n\n // to prevent runtime errors, developers will need to provide a child as a React element anyway.\n const children = /*#__PURE__*/React.isValidElement(childrenProp) ? childrenProp : /*#__PURE__*/_jsx(\"span\", {\n children: childrenProp\n });\n const theme = useTheme();\n const isRtl = theme.direction === 'rtl';\n const [childNode, setChildNode] = React.useState();\n const [arrowRef, setArrowRef] = React.useState(null);\n const ignoreNonTouchEvents = React.useRef(false);\n const disableInteractive = disableInteractiveProp || followCursor;\n const closeTimer = useTimeout();\n const enterTimer = useTimeout();\n const leaveTimer = useTimeout();\n const touchTimer = useTimeout();\n const [openState, setOpenState] = useControlled({\n controlled: openProp,\n default: false,\n name: 'Tooltip',\n state: 'open'\n });\n let open = openState;\n if (process.env.NODE_ENV !== 'production') {\n // eslint-disable-next-line react-hooks/rules-of-hooks\n const {\n current: isControlled\n } = React.useRef(openProp !== undefined);\n\n // eslint-disable-next-line react-hooks/rules-of-hooks\n React.useEffect(() => {\n if (childNode && childNode.disabled && !isControlled && title !== '' && childNode.tagName.toLowerCase() === 'button') {\n console.error(['MUI: You are providing a disabled `button` child to the Tooltip component.', 'A disabled element does not fire events.', \"Tooltip needs to listen to the child element's events to display the title.\", '', 'Add a simple wrapper element, such as a `span`.'].join('\\n'));\n }\n }, [title, childNode, isControlled]);\n }\n const id = useId(idProp);\n const prevUserSelect = React.useRef();\n const stopTouchInteraction = useEventCallback(() => {\n if (prevUserSelect.current !== undefined) {\n document.body.style.WebkitUserSelect = prevUserSelect.current;\n prevUserSelect.current = undefined;\n }\n touchTimer.clear();\n });\n React.useEffect(() => stopTouchInteraction, [stopTouchInteraction]);\n const handleOpen = event => {\n hystersisTimer.clear();\n hystersisOpen = true;\n\n // The mouseover event will trigger for every nested element in the tooltip.\n // We can skip rerendering when the tooltip is already open.\n // We are using the mouseover event instead of the mouseenter event to fix a hide/show issue.\n setOpenState(true);\n if (onOpen && !open) {\n onOpen(event);\n }\n };\n const handleClose = useEventCallback(\n /**\n * @param {React.SyntheticEvent | Event} event\n */\n event => {\n hystersisTimer.start(800 + leaveDelay, () => {\n hystersisOpen = false;\n });\n setOpenState(false);\n if (onClose && open) {\n onClose(event);\n }\n closeTimer.start(theme.transitions.duration.shortest, () => {\n ignoreNonTouchEvents.current = false;\n });\n });\n const handleEnter = event => {\n if (ignoreNonTouchEvents.current && event.type !== 'touchstart') {\n return;\n }\n\n // Remove the title ahead of time.\n // We don't want to wait for the next render commit.\n // We would risk displaying two tooltips at the same time (native + this one).\n if (childNode) {\n childNode.removeAttribute('title');\n }\n enterTimer.clear();\n leaveTimer.clear();\n if (enterDelay || hystersisOpen && enterNextDelay) {\n enterTimer.start(hystersisOpen ? enterNextDelay : enterDelay, () => {\n handleOpen(event);\n });\n } else {\n handleOpen(event);\n }\n };\n const handleLeave = event => {\n enterTimer.clear();\n leaveTimer.start(leaveDelay, () => {\n handleClose(event);\n });\n };\n const {\n isFocusVisibleRef,\n onBlur: handleBlurVisible,\n onFocus: handleFocusVisible,\n ref: focusVisibleRef\n } = useIsFocusVisible();\n // We don't necessarily care about the focusVisible state (which is safe to access via ref anyway).\n // We just need to re-render the Tooltip if the focus-visible state changes.\n const [, setChildIsFocusVisible] = React.useState(false);\n const handleBlur = event => {\n handleBlurVisible(event);\n if (isFocusVisibleRef.current === false) {\n setChildIsFocusVisible(false);\n handleLeave(event);\n }\n };\n const handleFocus = event => {\n // Workaround for https://github.com/facebook/react/issues/7769\n // The autoFocus of React might trigger the event before the componentDidMount.\n // We need to account for this eventuality.\n if (!childNode) {\n setChildNode(event.currentTarget);\n }\n handleFocusVisible(event);\n if (isFocusVisibleRef.current === true) {\n setChildIsFocusVisible(true);\n handleEnter(event);\n }\n };\n const detectTouchStart = event => {\n ignoreNonTouchEvents.current = true;\n const childrenProps = children.props;\n if (childrenProps.onTouchStart) {\n childrenProps.onTouchStart(event);\n }\n };\n const handleMouseOver = handleEnter;\n const handleMouseLeave = handleLeave;\n const handleTouchStart = event => {\n detectTouchStart(event);\n leaveTimer.clear();\n closeTimer.clear();\n stopTouchInteraction();\n prevUserSelect.current = document.body.style.WebkitUserSelect;\n // Prevent iOS text selection on long-tap.\n document.body.style.WebkitUserSelect = 'none';\n touchTimer.start(enterTouchDelay, () => {\n document.body.style.WebkitUserSelect = prevUserSelect.current;\n handleEnter(event);\n });\n };\n const handleTouchEnd = event => {\n if (children.props.onTouchEnd) {\n children.props.onTouchEnd(event);\n }\n stopTouchInteraction();\n leaveTimer.start(leaveTouchDelay, () => {\n handleClose(event);\n });\n };\n React.useEffect(() => {\n if (!open) {\n return undefined;\n }\n\n /**\n * @param {KeyboardEvent} nativeEvent\n */\n function handleKeyDown(nativeEvent) {\n // IE11, Edge (prior to using Bink?) use 'Esc'\n if (nativeEvent.key === 'Escape' || nativeEvent.key === 'Esc') {\n handleClose(nativeEvent);\n }\n }\n document.addEventListener('keydown', handleKeyDown);\n return () => {\n document.removeEventListener('keydown', handleKeyDown);\n };\n }, [handleClose, open]);\n const handleRef = useForkRef(children.ref, focusVisibleRef, setChildNode, ref);\n\n // There is no point in displaying an empty tooltip.\n // So we exclude all falsy values, except 0, which is valid.\n if (!title && title !== 0) {\n open = false;\n }\n const popperRef = React.useRef();\n const handleMouseMove = event => {\n const childrenProps = children.props;\n if (childrenProps.onMouseMove) {\n childrenProps.onMouseMove(event);\n }\n cursorPosition = {\n x: event.clientX,\n y: event.clientY\n };\n if (popperRef.current) {\n popperRef.current.update();\n }\n };\n const nameOrDescProps = {};\n const titleIsString = typeof title === 'string';\n if (describeChild) {\n nameOrDescProps.title = !open && titleIsString && !disableHoverListener ? title : null;\n nameOrDescProps['aria-describedby'] = open ? id : null;\n } else {\n nameOrDescProps['aria-label'] = titleIsString ? title : null;\n nameOrDescProps['aria-labelledby'] = open && !titleIsString ? id : null;\n }\n const childrenProps = _extends({}, nameOrDescProps, other, children.props, {\n className: clsx(other.className, children.props.className),\n onTouchStart: detectTouchStart,\n ref: handleRef\n }, followCursor ? {\n onMouseMove: handleMouseMove\n } : {});\n if (process.env.NODE_ENV !== 'production') {\n childrenProps['data-mui-internal-clone-element'] = true;\n\n // eslint-disable-next-line react-hooks/rules-of-hooks\n React.useEffect(() => {\n if (childNode && !childNode.getAttribute('data-mui-internal-clone-element')) {\n console.error(['MUI: The `children` component of the Tooltip is not forwarding its props correctly.', 'Please make sure that props are spread on the same element that the ref is applied to.'].join('\\n'));\n }\n }, [childNode]);\n }\n const interactiveWrapperListeners = {};\n if (!disableTouchListener) {\n childrenProps.onTouchStart = handleTouchStart;\n childrenProps.onTouchEnd = handleTouchEnd;\n }\n if (!disableHoverListener) {\n childrenProps.onMouseOver = composeEventHandler(handleMouseOver, childrenProps.onMouseOver);\n childrenProps.onMouseLeave = composeEventHandler(handleMouseLeave, childrenProps.onMouseLeave);\n if (!disableInteractive) {\n interactiveWrapperListeners.onMouseOver = handleMouseOver;\n interactiveWrapperListeners.onMouseLeave = handleMouseLeave;\n }\n }\n if (!disableFocusListener) {\n childrenProps.onFocus = composeEventHandler(handleFocus, childrenProps.onFocus);\n childrenProps.onBlur = composeEventHandler(handleBlur, childrenProps.onBlur);\n if (!disableInteractive) {\n interactiveWrapperListeners.onFocus = handleFocus;\n interactiveWrapperListeners.onBlur = handleBlur;\n }\n }\n if (process.env.NODE_ENV !== 'production') {\n if (children.props.title) {\n console.error(['MUI: You have provided a `title` prop to the child of .', `Remove this title prop \\`${children.props.title}\\` or the Tooltip component.`].join('\\n'));\n }\n }\n const popperOptions = React.useMemo(() => {\n var _PopperProps$popperOp;\n let tooltipModifiers = [{\n name: 'arrow',\n enabled: Boolean(arrowRef),\n options: {\n element: arrowRef,\n padding: 4\n }\n }];\n if ((_PopperProps$popperOp = PopperProps.popperOptions) != null && _PopperProps$popperOp.modifiers) {\n tooltipModifiers = tooltipModifiers.concat(PopperProps.popperOptions.modifiers);\n }\n return _extends({}, PopperProps.popperOptions, {\n modifiers: tooltipModifiers\n });\n }, [arrowRef, PopperProps]);\n const ownerState = _extends({}, props, {\n isRtl,\n arrow,\n disableInteractive,\n placement,\n PopperComponentProp,\n touch: ignoreNonTouchEvents.current\n });\n const classes = useUtilityClasses(ownerState);\n const PopperComponent = (_ref = (_slots$popper = slots.popper) != null ? _slots$popper : components.Popper) != null ? _ref : TooltipPopper;\n const TransitionComponent = (_ref2 = (_ref3 = (_slots$transition = slots.transition) != null ? _slots$transition : components.Transition) != null ? _ref3 : TransitionComponentProp) != null ? _ref2 : Grow;\n const TooltipComponent = (_ref4 = (_slots$tooltip = slots.tooltip) != null ? _slots$tooltip : components.Tooltip) != null ? _ref4 : TooltipTooltip;\n const ArrowComponent = (_ref5 = (_slots$arrow = slots.arrow) != null ? _slots$arrow : components.Arrow) != null ? _ref5 : TooltipArrow;\n const popperProps = appendOwnerState(PopperComponent, _extends({}, PopperProps, (_slotProps$popper = slotProps.popper) != null ? _slotProps$popper : componentsProps.popper, {\n className: clsx(classes.popper, PopperProps == null ? void 0 : PopperProps.className, (_ref6 = (_slotProps$popper2 = slotProps.popper) != null ? _slotProps$popper2 : componentsProps.popper) == null ? void 0 : _ref6.className)\n }), ownerState);\n const transitionProps = appendOwnerState(TransitionComponent, _extends({}, TransitionProps, (_slotProps$transition = slotProps.transition) != null ? _slotProps$transition : componentsProps.transition), ownerState);\n const tooltipProps = appendOwnerState(TooltipComponent, _extends({}, (_slotProps$tooltip = slotProps.tooltip) != null ? _slotProps$tooltip : componentsProps.tooltip, {\n className: clsx(classes.tooltip, (_ref7 = (_slotProps$tooltip2 = slotProps.tooltip) != null ? _slotProps$tooltip2 : componentsProps.tooltip) == null ? void 0 : _ref7.className)\n }), ownerState);\n const tooltipArrowProps = appendOwnerState(ArrowComponent, _extends({}, (_slotProps$arrow = slotProps.arrow) != null ? _slotProps$arrow : componentsProps.arrow, {\n className: clsx(classes.arrow, (_ref8 = (_slotProps$arrow2 = slotProps.arrow) != null ? _slotProps$arrow2 : componentsProps.arrow) == null ? void 0 : _ref8.className)\n }), ownerState);\n return /*#__PURE__*/_jsxs(React.Fragment, {\n children: [/*#__PURE__*/React.cloneElement(children, childrenProps), /*#__PURE__*/_jsx(PopperComponent, _extends({\n as: PopperComponentProp != null ? PopperComponentProp : Popper,\n placement: placement,\n anchorEl: followCursor ? {\n getBoundingClientRect: () => ({\n top: cursorPosition.y,\n left: cursorPosition.x,\n right: cursorPosition.x,\n bottom: cursorPosition.y,\n width: 0,\n height: 0\n })\n } : childNode,\n popperRef: popperRef,\n open: childNode ? open : false,\n id: id,\n transition: true\n }, interactiveWrapperListeners, popperProps, {\n popperOptions: popperOptions,\n children: ({\n TransitionProps: TransitionPropsInner\n }) => /*#__PURE__*/_jsx(TransitionComponent, _extends({\n timeout: theme.transitions.duration.shorter\n }, TransitionPropsInner, transitionProps, {\n children: /*#__PURE__*/_jsxs(TooltipComponent, _extends({}, tooltipProps, {\n children: [title, arrow ? /*#__PURE__*/_jsx(ArrowComponent, _extends({}, tooltipArrowProps, {\n ref: setArrowRef\n })) : null]\n }))\n }))\n }))]\n });\n});\nprocess.env.NODE_ENV !== \"production\" ? Tooltip.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the d.ts file and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * If `true`, adds an arrow to the tooltip.\n * @default false\n */\n arrow: PropTypes.bool,\n /**\n * Tooltip reference element.\n */\n children: elementAcceptingRef.isRequired,\n /**\n * Override or extend the styles applied to the component.\n */\n classes: PropTypes.object,\n /**\n * @ignore\n */\n className: PropTypes.string,\n /**\n * The components used for each slot inside.\n *\n * This prop is an alias for the `slots` prop.\n * It's recommended to use the `slots` prop instead.\n *\n * @default {}\n */\n components: PropTypes.shape({\n Arrow: PropTypes.elementType,\n Popper: PropTypes.elementType,\n Tooltip: PropTypes.elementType,\n Transition: PropTypes.elementType\n }),\n /**\n * The extra props for the slot components.\n * You can override the existing props or add new ones.\n *\n * This prop is an alias for the `slotProps` prop.\n * It's recommended to use the `slotProps` prop instead, as `componentsProps` will be deprecated in the future.\n *\n * @default {}\n */\n componentsProps: PropTypes.shape({\n arrow: PropTypes.object,\n popper: PropTypes.object,\n tooltip: PropTypes.object,\n transition: PropTypes.object\n }),\n /**\n * Set to `true` if the `title` acts as an accessible description.\n * By default the `title` acts as an accessible label for the child.\n * @default false\n */\n describeChild: PropTypes.bool,\n /**\n * Do not respond to focus-visible events.\n * @default false\n */\n disableFocusListener: PropTypes.bool,\n /**\n * Do not respond to hover events.\n * @default false\n */\n disableHoverListener: PropTypes.bool,\n /**\n * Makes a tooltip not interactive, i.e. it will close when the user\n * hovers over the tooltip before the `leaveDelay` is expired.\n * @default false\n */\n disableInteractive: PropTypes.bool,\n /**\n * Do not respond to long press touch events.\n * @default false\n */\n disableTouchListener: PropTypes.bool,\n /**\n * The number of milliseconds to wait before showing the tooltip.\n * This prop won't impact the enter touch delay (`enterTouchDelay`).\n * @default 100\n */\n enterDelay: PropTypes.number,\n /**\n * The number of milliseconds to wait before showing the tooltip when one was already recently opened.\n * @default 0\n */\n enterNextDelay: PropTypes.number,\n /**\n * The number of milliseconds a user must touch the element before showing the tooltip.\n * @default 700\n */\n enterTouchDelay: PropTypes.number,\n /**\n * If `true`, the tooltip follow the cursor over the wrapped element.\n * @default false\n */\n followCursor: PropTypes.bool,\n /**\n * This prop is used to help implement the accessibility logic.\n * If you don't provide this prop. It falls back to a randomly generated id.\n */\n id: PropTypes.string,\n /**\n * The number of milliseconds to wait before hiding the tooltip.\n * This prop won't impact the leave touch delay (`leaveTouchDelay`).\n * @default 0\n */\n leaveDelay: PropTypes.number,\n /**\n * The number of milliseconds after the user stops touching an element before hiding the tooltip.\n * @default 1500\n */\n leaveTouchDelay: PropTypes.number,\n /**\n * Callback fired when the component requests to be closed.\n *\n * @param {React.SyntheticEvent} event The event source of the callback.\n */\n onClose: PropTypes.func,\n /**\n * Callback fired when the component requests to be open.\n *\n * @param {React.SyntheticEvent} event The event source of the callback.\n */\n onOpen: PropTypes.func,\n /**\n * If `true`, the component is shown.\n */\n open: PropTypes.bool,\n /**\n * Tooltip placement.\n * @default 'bottom'\n */\n placement: PropTypes.oneOf(['bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n /**\n * The component used for the popper.\n * @default Popper\n */\n PopperComponent: PropTypes.elementType,\n /**\n * Props applied to the [`Popper`](/material-ui/api/popper/) element.\n * @default {}\n */\n PopperProps: PropTypes.object,\n /**\n * The extra props for the slot components.\n * You can override the existing props or add new ones.\n *\n * This prop is an alias for the `componentsProps` prop, which will be deprecated in the future.\n *\n * @default {}\n */\n slotProps: PropTypes.shape({\n arrow: PropTypes.object,\n popper: PropTypes.object,\n tooltip: PropTypes.object,\n transition: PropTypes.object\n }),\n /**\n * The components used for each slot inside.\n *\n * This prop is an alias for the `components` prop, which will be deprecated in the future.\n *\n * @default {}\n */\n slots: PropTypes.shape({\n arrow: PropTypes.elementType,\n popper: PropTypes.elementType,\n tooltip: PropTypes.elementType,\n transition: PropTypes.elementType\n }),\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Tooltip title. Zero-length titles string, undefined, null and false are never displayed.\n */\n title: PropTypes.node,\n /**\n * The component used for the transition.\n * [Follow this guide](/material-ui/transitions/#transitioncomponent-prop) to learn more about the requirements for this component.\n * @default Grow\n */\n TransitionComponent: PropTypes.elementType,\n /**\n * Props applied to the transition element.\n * By default, the element is based on this [`Transition`](http://reactcommunity.org/react-transition-group/transition/) component.\n */\n TransitionProps: PropTypes.object\n} : void 0;\nexport default Tooltip;","import '@/components/mui/menu-item.component.css';\nimport ArrowRightIcon from '@mui/icons-material/ArrowRight';\nimport {\n ListItemIcon as MuiListItemIcon,\n ListItemText as MuiListItemText,\n MenuItem as MuiMenuItem,\n} from '@mui/material';\nimport Tooltip from '@mui/material/Tooltip';\nimport { Localized, ReferencedItem, SingleColumnMenu } from 'platform-bible-utils';\nimport { MouseEvent, PropsWithChildren } from 'react';\n\ntype MenuItemInfoBase = {\n /** Text (displayable in the UI) as the name of the menu item */\n label: string;\n /** Text to display when the mouse hovers over the menu item */\n tooltip?: string;\n};\n\nexport type Command = MenuItemInfoBase & {\n /** Command to execute (string.string) */\n command: string;\n};\n\ntype SubMenu = MenuItemInfoBase & {\n /** Command to execute (string.string) */\n items: MenuItemInfo[];\n};\n\nexport interface CommandHandler {\n (command: Command): void;\n}\n\nexport type MenuPropsBase = {\n /*\n * The JSON defining the menu whose items are to be rendered. This will typically be one of the\n * menus in the \"defs\" in a Platform.Bible menu (see PlatformMenus). The schema for this is\n * menuDocumentSchema (at the end of menus.model.ts). Note that while this is a\n * \"SingleColumnMenu\", somewhat bizarrely, a MultiColumnMenu is a SingleColumnMenu, so it really\n * could be a MultiColumnMenu, in which case, column had better be defined so it can be used\n * to filter out the actual groups and items to display on the column.\n */\n menuDefinition: Localized;\n\n commandHandler: CommandHandler;\n\n /**\n * Additional action to perform when any menu item is clicked. Allows the caller to handle event\n * (e.g., to close the menu).\n */\n onClick?: (event: MouseEvent) => void;\n};\n\nexport type MenuItemListProps = MenuPropsBase & {\n /** Optional unique (column) identifier */\n columnId?: ReferencedItem;\n};\n\nexport type MenuItemProps = Omit &\n PropsWithChildren<{\n /** Optional unique identifier */\n id?: string;\n\n onClick: (event: MouseEvent) => void;\n }>;\n\ntype MenuItemInfo = (Command | SubMenu) & {\n /**\n * If specified, menu item will be inset if it does not have a leading icon.\n *\n * @default true\n */\n allowForLeadingIcons?: boolean;\n /**\n * If specified, the path to the icon image to display on the leading side of the menu text.\n *\n * @default undefined (no leading icon will be shown)\n */\n iconPathBefore?: string;\n /**\n * If specified, the path to the icon image to display on the trailing side of the menu text.\n *\n * @default undefined (no trailing icon will be shown)\n */\n iconPathAfter?: string;\n /**\n * If true, list item is focused during the first mount\n *\n * @default false\n */\n hasAutoFocus?: boolean;\n\n /** Additional css classes to help with unique styling of the menu item */\n className?: string;\n\n /**\n * If true, the menu item will appear disabled and it will not respond to clicks or mouse hovers.\n *\n * @default false\n */\n isDisabled?: boolean;\n\n /**\n * If true, compact vertical padding designed for keyboard and mouse input is used.\n *\n * @default true\n */\n isDense?: boolean;\n\n /**\n * If true, a right-arrow icon will be displayed (iconPathAfter, if specified, will be ignored).\n *\n * @default false\n */\n isSubMenuParent?: boolean;\n\n /**\n * If true, the left and right padding is removed\n *\n * @default false\n */\n hasDisabledGutters?: boolean;\n\n /**\n * If true, a 1px light border is added to bottom of menu item\n *\n * @default false\n */\n hasDivider?: boolean;\n\n /** Help identify which element has keyboard focus */\n focusVisibleClassName?: string;\n\n /** If it's a submenu, it should have the items property */\n items?: MenuItemInfo[];\n};\n\nfunction getIcon(icon: string | undefined, menuLabel: string, leading: boolean) {\n return icon ? (\n \n {`${leading\n \n ) : undefined;\n}\n\nexport default function MenuItem(props: MenuItemProps) {\n const {\n onClick,\n label,\n tooltip,\n allowForLeadingIcons = true,\n iconPathBefore = undefined,\n iconPathAfter = undefined,\n hasAutoFocus = false,\n className,\n isDisabled = false,\n isDense = true,\n isSubMenuParent = false,\n hasDisabledGutters = false,\n hasDivider = false,\n focusVisibleClassName,\n id,\n children,\n } = props;\n\n const menuItem = (\n \n {label ? (\n <>\n {getIcon(iconPathBefore, label, true)}\n \n {isSubMenuParent ? (\n \n \n \n ) : (\n getIcon(iconPathAfter, label, false)\n )}\n \n ) : (\n children\n )}\n \n );\n\n return tooltip ? (\n \n
    {menuItem}
    \n
    \n ) : (\n menuItem\n );\n}\n","import MenuItem, {\n MenuItemListProps,\n MenuItemProps,\n MenuPropsBase,\n} from '@/components/mui/menu-item.component';\nimport { Menu } from '@mui/material';\nimport {\n Localized,\n MenuGroupDetailsInSubMenu,\n MenuItemContainingCommand,\n MenuItemContainingSubmenu,\n OrderedExtensibleContainer,\n ReferencedItem,\n SingleColumnMenu,\n} from 'platform-bible-utils';\nimport { MouseEvent, useMemo, useState } from 'react';\n\n/**\n * All the exported types in this file should be regarded as \"internal\" (i.e., they should not be\n * exposed via index.ts).\n */\n\nexport type GroupedMenuPropsBase = MenuPropsBase & {\n /** Optional unique (column) identifier */\n columnId?: ReferencedItem;\n};\n\nexport type GroupedMenuItemListProps = MenuItemListProps & {\n /**\n * If the menuDefinition includes \"top-level\" groups (i.e., those that belong to a column as\n * opposed to those that belong to a submenu) that should not be included in the list, then this\n * array specifies which groups to include. Likewise, for a submenu, this list indicates which\n * groups are pertinent for that submenu. So then for a context menu this property need not be\n * specified since it is a top-level menu based on a \"true\" SingleColumnMenu (i.e., one that is\n * not a MultiColumnMenu).\n */\n includedGroups?: {\n id: string;\n group: Localized;\n }[];\n};\n\ninterface ItemInfo {\n item: Localized;\n isLastItemInGroup: boolean;\n}\n\ntype SubMenuProps = MenuPropsBase & {\n parentMenuItem: Localized;\n parentItemProps: Omit, 'iconPathAfter'>;\n};\n\nfunction getAllGroups(menuDefinition: Localized) {\n const groupEntries = Object.entries(menuDefinition.groups);\n // Convert array of entries to array of objects with id and group properties\n return groupEntries.map(([key, value]) => ({ id: key, group: value }));\n}\n\nfunction SubMenu(props: SubMenuProps) {\n const [anchorEl, setAnchorEl] = useState(undefined);\n\n const { parentMenuItem, parentItemProps, menuDefinition } = props;\n\n const handleParentMenuItemClick = (event: MouseEvent) => {\n setAnchorEl(event.currentTarget);\n };\n\n const handleClose = () => {\n setAnchorEl(undefined);\n };\n\n const renderSubMenuItems = () => {\n let includedGroups = getAllGroups(menuDefinition).filter((g) => 'menuItem' in g.group);\n\n // Ensure valid parent menu was provided. (If not, submenu will contain all groups!)\n if (!parentMenuItem?.id) throw new Error('A valid parent menu item is required for submenus.');\n\n // When laying out a submenu, only include groups associated with the provided parent menu.\n // Note: without the (annoying) redundant check that the included groups\n // have the menuItem field, TS doesn't think it exists.\n includedGroups = includedGroups.filter(\n (group) => 'menuItem' in group.group && group.group.menuItem === parentMenuItem.id,\n );\n\n return ;\n };\n\n return (\n <>\n \n \n {renderSubMenuItems()}\n \n \n );\n}\n\nconst getOrderedGroupItems = (\n groupId: string,\n allItems: Localized[],\n) => {\n // Filter items that belong to the specified group\n const itemsForGroup = allItems.filter((item) => item.group === groupId);\n // Sort items based on order\n const sortedItems = itemsForGroup.sort((a, b) => (a.order || 0) - (b.order || 0));\n return sortedItems;\n};\n\n/**\n * This component is internal; it does not need to be exposed to the outside world since it is not\n * useful on its own. It is used to generate and lay out the MenuItems that appear either on a\n * top-level menu (in a GridMenu or ContextMenu) or in a submenu.\n */\nexport default function GroupedMenuItemList(menuProps: GroupedMenuItemListProps) {\n const { menuDefinition, onClick, commandHandler, includedGroups } = menuProps;\n\n const { items, allowForLeadingIcons } = useMemo(() => {\n const groupsToInclude =\n includedGroups && includedGroups.length > 0\n ? includedGroups\n : // We're apparently laying out a single-column menu (presumably a context menu). In this\n // case, all groups should be included except ones that belong to a submenu.\n getAllGroups(menuDefinition).filter((g) => !('menuItem' in g.group));\n\n const sortedGroups = Object.values(groupsToInclude).sort(\n (a, b) => (a.group.order || 0) - (b.group.order || 0),\n );\n\n const itemArray: ItemInfo[] = [];\n\n sortedGroups.forEach((group) => {\n getOrderedGroupItems(group.id, menuDefinition.items).forEach((item) =>\n itemArray.push({ item, isLastItemInGroup: false }),\n );\n if (itemArray.length > 0) itemArray[itemArray.length - 1].isLastItemInGroup = true;\n });\n\n // No divider after last item in final group.\n if (itemArray.length > 0) itemArray[itemArray.length - 1].isLastItemInGroup = false;\n\n const allowSpaceForLeadingIcons = itemArray.some(\n (i) => 'iconPathBefore' in i.item && i.item.iconPathBefore,\n );\n\n return { items: itemArray, allowForLeadingIcons: allowSpaceForLeadingIcons };\n }, [includedGroups, menuDefinition]);\n\n // Create props for MenuItem component including setting hasDivider for the last item in a group\n const createMenuItemProps = ({ item, isLastItemInGroup }: ItemInfo) => {\n const menuItemProps = {\n className: 'papi-menu-item',\n label: item.label,\n tooltip: item.tooltip,\n iconPathBefore: 'iconPathBefore' in item ? item.iconPathBefore : undefined,\n iconPathAfter: 'iconPathAfter' in item ? item.iconPathAfter : undefined,\n hasDivider: isLastItemInGroup, // Set hasDivider to true for the last item in a group\n allowForLeadingIcons,\n };\n\n return menuItemProps;\n };\n\n const [firstItem] = items;\n\n if (!firstItem) return
    ;\n\n const divKey = firstItem.item.group;\n\n return (\n
    \n {items.map((itemInfo, index) => {\n const { item } = itemInfo;\n const menuItemProps = createMenuItemProps(itemInfo);\n if ('command' in item) {\n const key = item.group + index;\n return (\n ) => {\n onClick?.(event);\n commandHandler(item);\n }}\n {...menuItemProps}\n />\n );\n }\n return (\n \n );\n })}\n
    \n );\n}\n","import GroupedMenuItemList from '@/components/mui/grouped-menu-item-list.component';\nimport { MenuItemListProps } from '@/components/mui/menu-item.component';\nimport { MultiColumnMenu } from 'platform-bible-utils';\n\n/**\n * This component is internal; it does not need to be exposed to the outside world since it is not\n * useful on its own. Use either GridMenu or ContextMenu.\n */\nexport default function TopLevelMenu(props: MenuItemListProps) {\n const { menuDefinition, columnId } = props;\n\n const groupEntries = Object.entries(menuDefinition.groups);\n // Convert array of entries to array of objects with id and group properties\n const groups = groupEntries.map(([key, value]) => ({ id: key, group: value }));\n let includedGroups = groups.filter((g) => 'column' in g.group);\n\n // Check if column is provided and menuDefinition is a MultiColumnMenu\n if (\n columnId &&\n 'columns' in menuDefinition &&\n // Without this type assertion, TS doesn't know what columns is.\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n (menuDefinition as MultiColumnMenu).columns[columnId]\n ) {\n // When laying out a single column in a MultiColumnMenu, only include groups associated with\n // the provided column. Note: without the (annoying) redundant check that the included groups\n // have the colum field, TS doesn't think it exists.\n includedGroups = includedGroups.filter(\n (g) => 'column' in g.group && g.group.column === columnId,\n );\n }\n\n return ;\n}\n","import '@/components/mui/grid-menu.component.css';\nimport { GroupedMenuPropsBase } from '@/components/mui/grouped-menu-item-list.component';\nimport { CommandHandler } from '@/components/mui/menu-item.component';\nimport TopLevelMenu from '@/components/mui/top-level-menu.component';\nimport { Grid, List } from '@mui/material';\nimport {\n Localized,\n MenuColumnWithHeader,\n MultiColumnMenu,\n ReferencedItem,\n} from 'platform-bible-utils';\nimport { useMemo } from 'react';\n\ntype ColumnInfo = {\n /*\n * The ID (`${string}.${string}`) of a specific menu column.\n */\n id: ReferencedItem;\n\n /*\n * Metadata (label, order, etc.) for a specific menu column.\n */\n metadata: Localized;\n};\n\ntype MenuColumnProps = ColumnInfo &\n GroupedMenuPropsBase & {\n /** Additional css classes to help with unique styling of the menu column */\n className?: string;\n };\n\nexport type GridMenuInfo = {\n /** The menu object containing information about the columns, groups, and items to display. */\n multiColumnMenu: Localized;\n};\n\nexport type GridMenuProps = GridMenuInfo & {\n /** Optional unique identifier */\n id?: string;\n\n commandHandler: CommandHandler;\n\n /** Additional css classes to help with unique styling of the grid menu */\n className?: string;\n};\n\nfunction MenuColumn({\n commandHandler,\n menuDefinition,\n id,\n metadata,\n onClick,\n className,\n}: MenuColumnProps) {\n return (\n \n

    \n {metadata.label}\n

    \n {/* It would seem as though this List component were unnecessary, since it only contains one\n thing, but the \"dense\" property does affect the layout of the items (in a way I don't fully\n understand). There might be a better way. */}\n \n \n \n \n );\n}\n\nexport default function GridMenu({\n commandHandler,\n className,\n multiColumnMenu,\n id,\n}: GridMenuProps) {\n const { columns } = multiColumnMenu;\n\n const sortedColumns = useMemo(() => {\n const columnNumbers = new Map();\n Object.getOwnPropertyNames(columns).forEach((columnName: string) => {\n // We know for sure there is a (boolean) property 'isExtensible' that we are not interested in.\n if (columnName === 'isExtensible') return;\n // TS doesn't allow `columnName` above to be a ReferencedItem even though the type says it is\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const columnId = columnName as ReferencedItem;\n const column = columns[columnId];\n // As of right now (and hopefully forever after), all remaining properties of the\n // ColumnsWithHeaders object are columns whose property names are the IDs of the columns.\n // This is an additional (redundant) sanity check. Specifically we're interested in\n // MenuColumnWithHeader objects, which TypeScript now \"knows\" we have, but at runtime all we\n // can check for is that it's an object with a valid numeric order field. That's likely good\n // enough.\n if (\n typeof column === 'object' &&\n typeof column.order === 'number' &&\n !Number.isNaN(column.order)\n )\n columnNumbers.set(column.order, { id: columnId, metadata: column });\n else\n console.warn(\n `Property ${columnName} (${typeof column}) on menu ${id} is not a valid column and is being ignored. This might indicate data corruption`,\n );\n });\n\n // Extract values and sort them based on the 'order' property\n return Array.from(columnNumbers.values()).sort((a, b) => {\n return (a.metadata.order || 0) - (b.metadata.order || 0);\n });\n }, [columns, id]);\n\n // We might need something like this if we need to be able to prevent empty columns\n // sortedColumns.filter((c) => multiColumnMenu.groups.some((g) => 'column' in g && (g as .column)...\n\n return (\n \n {sortedColumns.map((col, index) => (\n \n ))}\n \n );\n}\n","import { useEffect, useRef, useState } from 'react';\n\nexport type UsePromiseOptions = {\n /**\n * Whether to leave the value as the most recent resolved promise value or set it back to\n * defaultValue while running the promise again. Defaults to true\n */\n preserveValue?: boolean;\n};\n\n/** Set up defaults for options for usePromise hook */\nfunction getUsePromiseOptionsDefaults(options: UsePromiseOptions): UsePromiseOptions {\n return {\n preserveValue: true,\n ...options,\n };\n}\n\n/**\n * Awaits a promise and returns a loading value while the promise is unresolved\n *\n * @param promiseFactoryCallback A function that returns the promise to await. If this callback is\n * undefined, the current value will be returned (defaultValue unless it was previously changed\n * and `options.preserveValue` is true), and there will be no loading.\n *\n * WARNING: MUST BE STABLE - const or wrapped in useCallback. The reference must not be updated\n * every render\n * @param defaultValue The initial value to return while first awaiting the promise. If\n * `options.preserveValue` is false, this value is also shown while awaiting the promise on\n * subsequent calls.\n *\n * Note: this parameter is internally assigned to a `ref`, so changing it will not cause any hooks\n * to re-run with its new value. This means that, if the `promiseFactoryCallback` changes and\n * `options.preserveValue` is `false`, the returned value will be set to the current\n * `defaultValue`. However, the returned value will not be updated if`defaultValue` changes.\n * @param options Various options for adjusting how this hook runs the `promiseFactoryCallback`\n *\n * Note: this parameter is internally assigned to a `ref`, so changing it will not cause any hooks\n * to re-run with its new value. However, the latest `options.preserveValue` will always be used\n * appropriately to determine whether to preserve the returned value when changing the\n * `promiseFactoryCallback`\n * @returns `[value, isLoading]`\n *\n * - `value`: the current value for the promise, either the defaultValue or the resolved promise value\n * - `isLoading`: whether the promise is waiting to be resolved\n */\nconst usePromise = (\n promiseFactoryCallback: (() => Promise) | undefined,\n defaultValue: T,\n options: UsePromiseOptions = {},\n): [value: T, isLoading: boolean] => {\n // Use defaultValue as a ref so it doesn't update dependency arrays\n const defaultValueRef = useRef(defaultValue);\n defaultValueRef.current = defaultValue;\n // Use options as a ref so it doesn't update dependency arrays\n const optionsDefaultedRef = useRef(options);\n optionsDefaultedRef.current = getUsePromiseOptionsDefaults(optionsDefaultedRef.current);\n\n const [value, setValue] = useState(() => defaultValueRef.current);\n const [isLoading, setIsLoading] = useState(true);\n useEffect(() => {\n let promiseIsCurrent = true;\n // If a promiseFactoryCallback was provided, we are loading. Otherwise, there is no loading to do\n setIsLoading(!!promiseFactoryCallback);\n (async () => {\n // If there is a callback to run, run it\n if (promiseFactoryCallback) {\n const result = await promiseFactoryCallback();\n // If the promise was not already replaced, update the value\n if (promiseIsCurrent) {\n setValue(() => result);\n setIsLoading(false);\n }\n }\n })();\n\n return () => {\n // Mark this promise as old and not to be used\n promiseIsCurrent = false;\n if (!optionsDefaultedRef.current.preserveValue) setValue(() => defaultValueRef.current);\n };\n }, [promiseFactoryCallback]);\n\n return [value, isLoading];\n};\nexport default usePromise;\n","\"use client\";\n\nimport createSvgIcon from './utils/createSvgIcon';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nexport default createSvgIcon( /*#__PURE__*/_jsx(\"path\", {\n d: \"M3 18h18v-2H3zm0-5h18v-2H3zm0-7v2h18V6z\"\n}), 'Menu');","import GridMenu from '@/components/mui/grid-menu.component';\nimport { Command, CommandHandler } from '@/components/mui/menu-item.component';\nimport usePromise from '@/hooks/use-promise.hook';\nimport { Menu as MenuIcon } from '@mui/icons-material';\nimport { Drawer, IconButton } from '@mui/material';\nimport { Localized, MultiColumnMenu } from 'platform-bible-utils';\nimport {\n MouseEvent,\n MutableRefObject,\n PropsWithChildren,\n useCallback,\n useEffect,\n useState,\n} from 'react';\n\nexport interface MultiColumnMenuProvider {\n (isSupportAndDevelopment: boolean): Promise>;\n}\n\nexport type HamburgerMenuButtonProps = PropsWithChildren & {\n /** The handler to use for menu commands (and eventually toolbar commands). */\n commandHandler: CommandHandler;\n\n /**\n * Optional reference to the \"div\" container that determines the where the menu should appear. If\n * not defined, then (1,1) used.\n */\n containerRef?: MutableRefObject;\n\n /**\n * The delegate to use to get the menu data. If not specified or if it returns undefined, the data\n * in normalMenu or fullMenu property will be used.\n */\n menuProvider?: MultiColumnMenuProvider;\n\n /**\n * The menu data to show when the menu is opened if the menuProvider property is not defined.\n * (This allows for a default or test-only static menu to be used.)\n */\n normalMenu?: Localized;\n\n /**\n * The menu data to show for \"full\" menu (when opened with the SHIFT key pressed) if the\n * menuProvider property is not defined. (This allows for a default or test-only static menu to be\n * used.)\n */\n fullMenu?: Localized;\n\n /** Additional css class(es) to help with unique styling of the sub-components */\n className?: string;\n\n /** Value to use as prefix for ARIA labels on interactive sub-components */\n ariaLabelPrefix?: string;\n};\n\nexport default function HamburgerMenuButton({\n menuProvider,\n normalMenu,\n fullMenu,\n commandHandler,\n containerRef,\n className,\n ariaLabelPrefix,\n children,\n}: HamburgerMenuButtonProps) {\n const [isMenuOpen, setMenuOpen] = useState(false);\n const [showFullMenu, setShowFullMenu] = useState(false);\n\n const handleMenuItemClick = useCallback(() => {\n if (isMenuOpen) setMenuOpen(false);\n setShowFullMenu(false);\n }, [isMenuOpen]);\n\n const handleMenuButtonClick = useCallback((e: MouseEvent) => {\n e.stopPropagation();\n setMenuOpen((prevIsOpen) => {\n const isOpening = !prevIsOpen;\n if (isOpening && e.shiftKey) setShowFullMenu(true);\n else if (!isOpening) setShowFullMenu(false);\n return isOpening;\n });\n }, []);\n\n const menuCommandHandler = useCallback(\n (command: Command) => {\n handleMenuItemClick();\n return commandHandler(command);\n },\n [commandHandler, handleMenuItemClick],\n );\n\n const [offset, setOffset] = useState({ top: 1, left: 1 });\n\n useEffect(() => {\n if (isMenuOpen) {\n const node = containerRef?.current;\n if (node) {\n const rect = node.getBoundingClientRect();\n const scrollTop = window.scrollY;\n const scrollLeft = window.scrollX;\n const top = rect.top + scrollTop + node.clientHeight;\n const left = rect.left + scrollLeft;\n setOffset({ top, left });\n }\n }\n }, [isMenuOpen, containerRef]);\n\n const [normalMenuData] = usePromise(\n useCallback(async () => {\n return menuProvider?.(false) ?? normalMenu;\n // isMenuOpen needs to be included for the menu contents to reevaluate when reopened\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [menuProvider, normalMenu, isMenuOpen]),\n normalMenu,\n );\n\n const [fullMenuData] = usePromise(\n useCallback(async () => {\n return menuProvider?.(true) ?? fullMenu ?? normalMenuData;\n // isMenuOpen needs to be included for the menu contents to reevaluate when reopened\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [menuProvider, fullMenu, normalMenuData, isMenuOpen]),\n fullMenu ?? normalMenuData,\n );\n\n const menu = showFullMenu && fullMenuData ? fullMenuData : normalMenuData;\n\n return (\n <>\n \n {children ?? }\n \n \n {menu ? (\n \n ) : undefined}\n \n \n );\n}\n","import '@/components/mui/icon-button.component.css';\nimport { IconButton as MuiIconButton } from '@mui/material';\nimport { MouseEventHandler, PropsWithChildren } from 'react';\n\nexport type IconButtonProps = PropsWithChildren<{\n /** Optional unique identifier */\n id?: string;\n /**\n * Required. Used as both the tooltip (aka, title) and the aria-label (used for accessibility,\n * testing, etc.), unless a distinct tooltip is supplied.\n */\n label: string;\n /**\n * Enabled status of button\n *\n * @default false\n */\n isDisabled?: boolean;\n /** Optional tooltip to display if different from the aria-label. */\n tooltip?: string;\n /** If true, no tooltip will be displayed. */\n isTooltipSuppressed?: boolean;\n /**\n * If given, uses a negative margin to counteract the padding on one side (this is often helpful\n * for aligning the left or right side of the icon with content above or below, without ruining\n * the border size and shape).\n *\n * @default false\n */\n adjustMarginToAlignToEdge?: 'end' | 'start' | false;\n /**\n * The size of the component. small is equivalent to the dense button styling.\n *\n * @default false\n */\n size: 'small' | 'medium' | 'large';\n /** Additional css classes to help with unique styling of the button */\n className?: string;\n /** Optional click handler */\n onClick?: MouseEventHandler;\n}>;\n\n/**\n * Iconic button a user can click to do something\n *\n * Thanks to MUI for heavy inspiration and documentation\n * https://mui.com/material-ui/getting-started/overview/\n */\nfunction IconButton({\n id,\n label,\n isDisabled = false,\n tooltip,\n isTooltipSuppressed = false,\n adjustMarginToAlignToEdge = false,\n size = 'medium',\n className,\n onClick,\n children,\n}: IconButtonProps) {\n return (\n \n {children /* the icon to display */}\n \n );\n}\n\nexport default IconButton;\n","import { cn } from '@/utils/shadcn-ui.util';\nimport { LoaderCircle, LucideProps } from 'lucide-react';\nimport { forwardRef } from 'react';\n\nexport type SpinnerProps = LucideProps;\n\nconst Spinner = forwardRef(({ className, ...props }, ref) => {\n return (\n \n );\n});\n\nSpinner.displayName = 'Spinner';\n\nexport default Spinner;\n","import { Input as ShadInput } from '@/components/shadcn-ui/input';\nimport { Label as ShadLabel } from '@/components/shadcn-ui/label';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { ChangeEventHandler, FocusEventHandler } from 'react';\n\nexport type TextFieldProps = {\n /** Optional unique identifier */\n id?: string;\n /**\n * If `true`, the component is disabled.\n *\n * @default false\n */\n isDisabled?: boolean;\n /**\n * If `true`, the label is displayed in an error state.\n *\n * @default false\n */\n hasError?: boolean;\n /**\n * If `true`, the input will take up the full width of its container.\n *\n * @default false\n */\n isFullWidth?: boolean;\n /** Text that gives the user instructions on what contents the TextField expects */\n helperText?: string;\n /** The title of the TextField */\n label?: string;\n /** The short hint displayed in the `input` before the user enters a value. */\n placeholder?: string;\n /**\n * If `true`, the label is displayed as required and the `input` element is required.\n *\n * @default false\n */\n isRequired?: boolean;\n /** Additional css classes to help with unique styling of the text field */\n className?: string;\n /** Starting value for the text field if it is not controlled */\n defaultValue?: string | number;\n /** Value of the text field if controlled */\n value?: string | number;\n /** Triggers when content of textfield is changed */\n onChange?: ChangeEventHandler;\n /** Triggers when textfield gets focus */\n onFocus?: FocusEventHandler;\n /** Triggers when textfield loses focus */\n onBlur?: FocusEventHandler;\n};\n\n/**\n * Text input field\n *\n * Thanks to Shadcn for heavy inspiration and documentation\n * https://ui.shadcn.com/docs/components/input#with-label\n */\nfunction TextField({\n id,\n isDisabled = false,\n hasError = false,\n isFullWidth = false,\n helperText,\n label,\n placeholder,\n isRequired = false,\n className,\n defaultValue,\n value,\n onChange,\n onFocus,\n onBlur,\n}: TextFieldProps) {\n return (\n
    \n {`${label}${isRequired ? '*' : ''}`}\n \n

    {helperText}

    \n
    \n );\n}\n\nexport default TextField;\n","import HamburgerMenuButton, {\n MultiColumnMenuProvider,\n} from '@/components/mui/hamburger-menu-button.component';\nimport { CommandHandler } from '@/components/mui/menu-item.component';\nimport '@/components/mui/toolbar.component.css';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { AppBar, Toolbar as MuiToolbar } from '@mui/material';\nimport { PropsWithChildren, useRef } from 'react';\n\nexport type ToolbarProps = PropsWithChildren<{\n /** The handler to use for menu commands (and eventually toolbar commands). */\n commandHandler: CommandHandler;\n\n /**\n * The optional delegate to use to get the menu data. If not specified, the \"hamburger\" menu will\n * not display.\n */\n menuProvider?: MultiColumnMenuProvider;\n\n /** Optional unique identifier */\n id?: string;\n\n /** Additional css classes to help with unique styling of the toolbar */\n className?: string;\n}>;\n\nexport default function Toolbar({\n menuProvider,\n commandHandler,\n className,\n id,\n children,\n}: ToolbarProps) {\n // This ref will always be defined\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const containerRef = useRef(undefined!);\n\n return (\n
    \n \n \n {menuProvider ? (\n \n ) : undefined}\n {children ?
    {children}
    : undefined}\n \n
    \n
    \n );\n}\n","import React from 'react';\nimport { cva, type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst alertVariants = cva(\n 'tw-relative tw-w-full tw-rounded-lg tw-border tw-p-4 [&>svg~*]:tw-pl-7 [&>svg+div]:tw-translate-y-[-3px] [&>svg]:tw-absolute [&>svg]:tw-left-4 [&>svg]:tw-top-4 [&>svg]:tw-text-foreground',\n {\n variants: {\n variant: {\n default: 'tw-bg-background tw-text-foreground',\n destructive:\n 'tw-border-destructive/50 tw-text-destructive dark:tw-border-destructive [&>svg]:tw-text-destructive',\n },\n },\n defaultVariants: {\n variant: 'default',\n },\n },\n);\n\nconst Alert = React.forwardRef<\n HTMLDivElement,\n React.HTMLAttributes & VariantProps\n>(({ className, variant, ...props }, ref) => (\n
    \n));\nAlert.displayName = 'Alert';\n\nconst AlertTitle = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n {/* added because of https://github.com/jsx-eslint/eslint-plugin-jsx-a11y/blob/main/docs/rules/heading-has-content.md */}\n {props.children}{' '}\n \n ),\n);\nAlertTitle.displayName = 'AlertTitle';\n\nconst AlertDescription = React.forwardRef<\n HTMLParagraphElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n
    \n));\nAlertDescription.displayName = 'AlertDescription';\n\nexport { Alert, AlertTitle, AlertDescription };\n","import { ComponentProps } from 'react';\nimport { toast as sonner, Toaster } from 'sonner';\n\ntype SonnerProps = ComponentProps;\n\nfunction Sonner({ ...props }: SonnerProps) {\n return (\n \n );\n}\n\n// The re-export of the sonner function was added manually\nexport { Sonner, sonner };\n","import React from 'react';\nimport * as SliderPrimitive from '@radix-ui/react-slider';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Slider = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n \n \n \n));\nSlider.displayName = SliderPrimitive.Root.displayName;\n\nexport { Slider };\n","import React from 'react';\nimport * as SwitchPrimitives from '@radix-ui/react-switch';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Switch = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n));\nSwitch.displayName = SwitchPrimitives.Root.displayName;\n\nexport { Switch };\n","import React from 'react';\nimport * as TabsPrimitive from '@radix-ui/react-tabs';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport const Tabs = TabsPrimitive.Root;\n\nexport type TabsListProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport type TabsTriggerProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport type TabsContentProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport const TabsList = React.forwardRef<\n React.ElementRef,\n TabsListProps\n>(({ className, ...props }, ref) => (\n \n));\nTabsList.displayName = TabsPrimitive.List.displayName;\n\nexport const TabsTrigger = React.forwardRef<\n React.ElementRef,\n TabsTriggerProps\n>(({ className, ...props }, ref) => (\n \n));\nTabsTrigger.displayName = TabsPrimitive.Trigger.displayName;\n\nexport const TabsContent = React.forwardRef<\n React.ElementRef,\n TabsContentProps\n>(({ className, ...props }, ref) => (\n \n));\nTabsContent.displayName = TabsPrimitive.Content.displayName;\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Download } from 'lucide-react';\n\ntype InstallButtonProps = {\n /** The installing boolean value determines the state of the button. */\n isInstalling: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n /** Optional text for the button. */\n buttonText?: string;\n} & ButtonProps;\n\n/**\n * The InstallButton component is a button designed for initiating installs. It includes visuals for\n * active installing and idle states.\n *\n * @param isInstalling The installing boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @param buttonText Optional text for the button.\n * @returns A install button.\n */\nexport default function InstallButton({\n isInstalling,\n handleClick,\n buttonText,\n className,\n ...props\n}: InstallButtonProps) {\n return (\n \n {isInstalling ? (\n \n ) : (\n <>\n \n {buttonText}\n \n )}\n \n );\n}\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\n\ntype EnableButtonProps = {\n /** The enabling boolean value determines the state of the button. */\n isEnabling: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n} & ButtonProps;\n\n/**\n * The EnableButton component is a button designed for initiating enabling of downloads. It includes\n * visuals for active enabling and idle states.\n *\n * @param isEnabling The enabling boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @returns A button that can be used to enable.\n */\nexport default function EnableButton({\n isEnabling,\n handleClick,\n className,\n ...props\n}: EnableButtonProps) {\n return (\n \n {isEnabling ? (\n <>\n \n Enabling...\n \n ) : (\n 'Enable'\n )}\n \n );\n}\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\n\ntype DisableButtonProps = {\n /** The disabling boolean value determines the state of the button. */\n isDisabling: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n} & ButtonProps;\n\n/**\n * The DisableButton component is a button designed for initiating disabling of downloads. It\n * includes visuals for active disabling and idle states.\n *\n * @param isDisabling The disabling boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @returns A button that can be used to disable.\n */\nexport default function DisableButton({\n isDisabling,\n handleClick,\n className,\n ...props\n}: DisableButtonProps) {\n return (\n \n {isDisabling ? (\n <>\n \n Disabling...\n \n ) : (\n 'Disable'\n )}\n \n );\n}\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\n\ntype UpdateButtonProps = {\n /** The updating boolean value determines the state of the button. */\n isUpdating: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n} & ButtonProps;\n\n/**\n * The UpdateButton component is a button designed for initiating updates for downloaded extensions.\n * It includes visuals for active updating and idle states.\n *\n * @param isUpdating The updating boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @returns A button that can be used to update.\n */\nexport default function UpdateButton({\n isUpdating,\n handleClick,\n className,\n ...props\n}: UpdateButtonProps) {\n return (\n \n {isUpdating ? (\n <>\n \n Updating...\n \n ) : (\n 'Update'\n )}\n \n );\n}\n","import { cn } from '@/utils/shadcn-ui.util';\nimport Markdown, { MarkdownToJSX } from 'markdown-to-jsx';\nimport { useMemo } from 'react';\n\ninterface MarkdownRendererProps {\n /** Optional unique identifier */\n id?: string;\n /** The markdown string to render */\n markdown: string;\n className?: string;\n /**\n * The [`target` attribute for `a` html\n * tags](https://developer.mozilla.org/en-US/docs/Web/HTML/Element/a#target). Defaults to not\n * adding a `target` to `a` tags\n */\n anchorTarget?: string;\n}\n\n/**\n * This component renders markdown content given a markdown string. It uses typography styles from\n * the platform.\n *\n * @param markdown The markdown string to render.\n * @param id Optional unique identifier\n * @returns A div containing the rendered markdown content.\n */\nexport default function MarkdownRenderer({\n id,\n markdown,\n className,\n anchorTarget,\n}: MarkdownRendererProps) {\n const options: MarkdownToJSX.Options = useMemo(\n () => ({\n overrides: {\n a: {\n props: {\n target: anchorTarget,\n },\n },\n },\n }),\n [anchorTarget],\n );\n return (\n
    \n {markdown}\n
    \n );\n}\n","import { Filter, ChevronDown } from 'lucide-react';\nimport { forwardRef } from 'react';\nimport { Button } from '@/components/shadcn-ui/button';\n\n/**\n * The FilterButton component is a button designed for initiating filtering of data. It is designed\n * to be used with the dropdown menu. It uses forwardRef to pass the button to the dropdown trigger\n * asChild.\n *\n * @returns A button that can be used to filter.\n */\nconst FilterButton = forwardRef((props, ref) => {\n return (\n \n \n Filter\n \n \n );\n});\n\nexport default FilterButton;\n","import {\n DropdownMenu,\n DropdownMenuTrigger,\n DropdownMenuContent,\n DropdownMenuLabel,\n DropdownMenuGroup,\n DropdownMenuCheckboxItem,\n DropdownMenuRadioItem,\n DropdownMenuSeparator,\n} from '@/components/shadcn-ui/dropdown-menu';\nimport FilterButton from './buttons/filter-button.component';\n\nexport enum DropdownMenuItemType {\n Check,\n Radio,\n}\n\nexport type DropdownItem = {\n /** The label is the text that will be displayed on the dropdown item. */\n label: string;\n /** The itemType determines the DropdownMenuItemType type as either Check or Radio. */\n itemType: DropdownMenuItemType;\n /** The onClick function is called when the item is clicked. */\n onClick: () => void;\n};\n\nexport type DropdownGroup = {\n /**\n * The label is the text that will be displayed on the dropdown group. It is used to categorize\n * the items in the group.\n */\n label: string;\n /** The items array contains the items that will be displayed in the dropdown group */\n items: DropdownItem[];\n};\n\nexport type FilterDropdownProps = {\n /** Object unique identifier */\n id?: string;\n /** The groups array contains the groups that will be displayed in the dropdown */\n groups: DropdownGroup[];\n}; // TODO: extend the props later\n\n/**\n * The FilterDropdown component is a dropdown designed for filtering content. It includes groups of\n * items that can be checkboxes or radio items.\n *\n * @param id Optional unique identifier\n * @param groups The groups array contains the groups that will be displayed in the dropdown\n * @returns A filter dropdown.\n */\nexport default function FilterDropdown({ id, groups }: FilterDropdownProps) {\n return (\n
    \n {/* TODO: remove this once the DropDown Menu shadcn has an id prop */}\n \n \n \n \n \n {groups.map((group) => (\n
    \n {group.label}\n \n {group.items.map((item) => (\n
    \n {item.itemType === DropdownMenuItemType.Check ? (\n \n {item.label}\n \n ) : (\n \n {item.label}\n \n )}\n
    \n ))}\n
    \n \n
    \n ))}\n
    \n
    \n
    \n );\n}\n","interface NoExtensionsFoundProps {\n /** Optional unique identifier */\n id?: string;\n /** The message to display */\n message: string;\n}\n/**\n * This component displays a message to the user when no extensions are found in the marketplace.\n *\n * @param id Optional unique identifier\n * @param message The message to display.\n * @returns {JSX.Element} - Returns the message component that displays the message to the user.\n */\nexport default function NoExtensionsFound({ id, message }: NoExtensionsFoundProps) {\n return (\n
    \n
    \n

    {message}

    \n
    \n
    \n );\n}\n","import { CircleHelp, Link as LucideLink, User } from 'lucide-react';\nimport { NumberFormat } from 'platform-bible-utils';\n\n/** Interface that stores the parameters passed to the More Info component */\ninterface MoreInfoProps {\n /** Optional unique identifier */\n id?: string;\n /** The category of the extension */\n category: string;\n /** The number of downloads for the extension */\n downloads: Record;\n /** The languages supported by the extension */\n languages: string[];\n /** The URL to the more info page of the extension */\n moreInfoUrl: string;\n}\n/**\n * This component displays the more info section of the extension which includes the category,\n * number of downloads, languages, and links to the website and support\n *\n * @param id Optional unique identifier\n * @param category The category of the extension\n * @param downloads The number of downloads for the extension\n * @param languages The languages supported by the extension\n * @param moreInfoUrl The URL to the more info page of the extension\n * @returns {JSX.Element} - Returns the more info component that displays the category, number of\n * downloads, languages, and links to the website and support\n */\nexport default function MoreInfo({\n id,\n category,\n downloads,\n languages,\n moreInfoUrl,\n}: MoreInfoProps) {\n /**\n * This constant formats the number of downloads into a more readable format.\n *\n * @example 1000 -> 1K\n *\n * @example 1000000 -> 1M\n *\n * @returns The formatted number of downloads\n */\n const numberFormatted = new NumberFormat('en', {\n notation: 'compact',\n compactDisplay: 'short',\n }).format(Object.values(downloads).reduce((a: number, b: number) => a + b, 0));\n\n /** This function scrolls the window to the bottom of the page. */\n const handleScrollToBottom = () => {\n window.scrollTo(0, document.body.scrollHeight);\n };\n\n return (\n \n
    \n
    \n {category}\n
    \n CATEGORY\n
    \n
    \n
    \n
    \n \n {numberFormatted}\n
    \n USERS\n
    \n
    \n
    \n
    \n {languages.slice(0, 3).map((locale) => (\n \n {locale.toUpperCase()}\n \n ))}\n
    \n {languages.length > 3 && (\n handleScrollToBottom()}\n className=\"tw-text-xs tw-text-gray-500 tw-underline\"\n >\n +{languages.length - 3} more languages\n \n )}\n
    \n
    \n
    \n \n Website\n \n \n \n Support\n \n \n
    \n
    \n );\n}\n","import { useState } from 'react';\n\nexport type VersionInformation = {\n /** Date the version was published */\n date: string;\n /** Description of the changes in the version */\n description: string;\n};\n\n/** Type to store the version history information */\nexport type VersionHistoryType = Record;\n\n/** Interface that stores the parameters passed to the Version History component */\ninterface VersionHistoryProps {\n /** Optional unique identifier */\n id?: string;\n /** Object containing the versions mapped with their information */\n versionHistory: VersionHistoryType;\n}\n\n/**\n * Component to render the version history information shown in the footer component. Lists the 5\n * most recent versions, with the options to show all versions by pressing a button.\n *\n * @param versionHistory Object containing the versions mapped with their information\n * @param id Optional unique identifier\n * @returns Rendered version history for the Footer component\n */\nexport default function VersionHistory({ id, versionHistory }: VersionHistoryProps) {\n const [showAllVersions, setShowAllVersions] = useState(false);\n const currentDate = new Date();\n\n /**\n * Function to format the time string for the version history in the form of 'X year(s) ago'.\n *\n * @param dateString ISO Date string to determine the time string from\n * @returns Formatted time string\n */\n function formatTimeString(dateString: string) {\n const date = new Date(dateString);\n const dateDiff = new Date(currentDate.getTime() - date.getTime());\n const yearDiff = dateDiff.getUTCFullYear() - 1970;\n const monthDiff = dateDiff.getUTCMonth();\n const dayDiff = dateDiff.getUTCDate() - 1;\n\n // Determines how long ago the version was published\n let timeString = '';\n if (yearDiff > 0) {\n timeString = `${yearDiff.toString()} year${yearDiff === 1 ? '' : 's'} ago`;\n } else if (monthDiff > 0) {\n timeString = `${monthDiff.toString()} month${monthDiff === 1 ? '' : 's'} ago`;\n } else if (dayDiff === 0) {\n timeString = 'today';\n } else {\n timeString = `${dayDiff.toString()} day${dayDiff === 1 ? '' : 's'} ago`;\n }\n\n return timeString;\n }\n\n // Sorts the version history by version number\n const sortedEntries = Object.entries(versionHistory).sort((a, b) => b[0].localeCompare(a[0]));\n\n return (\n
    \n

    What`s New

    \n
      \n {(showAllVersions ? sortedEntries : sortedEntries.slice(0, 5)).map((entry) => (\n
      \n
      \n
    • \n {entry[1].description}\n
    • \n
      \n
      \n
      Version {entry[0]}
      \n
      {formatTimeString(entry[1].date)}
      \n
      \n
      \n ))}\n
    \n {sortedEntries.length > 5 && (\n setShowAllVersions(!showAllVersions)}\n className=\"tw-text-xs tw-text-gray-500 tw-underline\"\n >\n {showAllVersions ? 'Show Less Version History' : 'Show All Version History'}\n \n )}\n
    \n );\n}\n","import { useMemo } from 'react';\nimport { formatBytes } from 'platform-bible-utils';\nimport VersionHistory, { VersionHistoryType } from './version-history.component';\n\n/** Interface to store the parameters passed to the Footer component */\ninterface FooterProps {\n /** Optional unique identifier */\n id?: string;\n /** Name of the publisher */\n publisherDisplayName: string;\n /** Size of the extension file in bytes */\n fileSize: number;\n /** List of language codes supported by the extension */\n locales: string[];\n /** Object containing the version history mapped with their information */\n versionHistory: VersionHistoryType;\n}\n\n/**\n * Component to render the footer for the extension details which contains information on the\n * publisher, version history, languages, and file size.\n *\n * @param id Optional unique identifier\n * @param publisherDisplayName Name of the publisher\n * @param fileSize Size of the extension file in bytes\n * @param locales List of language codes supported by the extension\n * @param versionHistory Object containing the version history mapped with their information\n * @returns The rendered Footer component\n */\nexport default function Footer({\n id,\n publisherDisplayName,\n fileSize,\n locales,\n versionHistory,\n}: FooterProps) {\n /** Formats the file size into a human-readable format */\n const formattedFileSize = useMemo(() => formatBytes(fileSize), [fileSize]);\n\n /**\n * This function gets the display names of the languages based on the language codes.\n *\n * @param codes The list of language codes\n * @returns The list of language names\n */\n const getLanguageNames = (codes: string[]) => {\n const displayNames = new Intl.DisplayNames(navigator.language, { type: 'language' });\n return codes.map((code) => displayNames.of(code));\n };\n\n const languageNames = getLanguageNames(locales);\n\n return (\n
    \n
    \n \n
    \n
    \n

    Information

    \n
    \n

    \n Publisher\n {publisherDisplayName}\n Size\n {formattedFileSize}\n

    \n
    \n

    \n Languages\n {languageNames.join(', ')}\n

    \n
    \n
    \n
    \n
    \n
    \n );\n}\n","import { PlatformEvent, PlatformEventHandler } from 'platform-bible-utils';\nimport { useEffect } from 'react';\n\n/**\n * Adds an event handler to an event so the event handler runs when the event is emitted. Use\n * `papi.network.getNetworkEvent` to use a networked event with this hook.\n *\n * @param event The event to subscribe to.\n *\n * - If event is a `PlatformEvent`, that event will be used\n * - If event is undefined, the callback will not be subscribed. Useful if the event is not yet\n * available for example\n *\n * @param eventHandler The callback to run when the event is emitted\n *\n * WARNING: MUST BE STABLE - const or wrapped in useCallback. The reference must not be updated\n * every render\n */\nconst useEvent = (\n event: PlatformEvent | undefined,\n eventHandler: PlatformEventHandler,\n) => {\n useEffect(() => {\n // Do nothing if the event is not provided (in case the event is not yet available, for example)\n if (!event) return () => {};\n\n const unsubscriber = event(eventHandler);\n return () => {\n unsubscriber();\n };\n }, [event, eventHandler]);\n};\nexport default useEvent;\n","import { useCallback, useEffect } from 'react';\nimport { PlatformEvent, PlatformEventAsync, PlatformEventHandler } from 'platform-bible-utils';\nimport usePromise from './use-promise.hook';\n\nconst noopUnsubscriber = () => false;\n\n/**\n * Adds an event handler to an asynchronously subscribing/unsubscribing event so the event handler\n * runs when the event is emitted. Use `papi.network.getNetworkEvent` to use a networked event with\n * this hook.\n *\n * @param event The asynchronously (un)subscribing event to subscribe to.\n *\n * - If event is a `PlatformEvent` or `PlatformEventAsync`, that event will be used\n * - If event is undefined, the callback will not be subscribed. Useful if the event is not yet\n * available for example\n *\n * @param eventHandler The callback to run when the event is emitted\n *\n * WARNING: MUST BE STABLE - const or wrapped in useCallback. The reference must not be updated\n * every render\n */\nconst useEventAsync = (\n event: PlatformEvent | PlatformEventAsync | undefined,\n eventHandler: PlatformEventHandler,\n) => {\n // Subscribe to the event asynchronously\n const [unsubscribe] = usePromise(\n useCallback(async () => {\n // Do nothing if the event is not provided (in case the event is not yet available, for example)\n if (!event) return noopUnsubscriber;\n\n // Wrap subscribe and unsubscribe in promises to allow normal events to be used as well\n const unsub = await Promise.resolve(event(eventHandler));\n return async () => unsub();\n }, [eventHandler, event]),\n noopUnsubscriber,\n // We want the unsubscriber to return to default value immediately upon changing subscription\n // So the useEffect below will unsubscribe asap\n { preserveValue: false },\n );\n\n // Unsubscribe from the event asynchronously (but we aren't awaiting the unsub)\n useEffect(() => {\n return () => {\n if (unsubscribe !== noopUnsubscriber) {\n unsubscribe();\n }\n };\n }, [unsubscribe]);\n};\n\nexport default useEventAsync;\n"],"names":["twMergeCustom","extendTailwindMerge","cn","inputs","clsx","Input","React","className","type","props","ref","jsx","BookChapterInput","forwardRef","handleSearch","handleKeyDown","handleOnClick","handleSubmit","jsxs","ShadInput","event","e","History","P","R","s","n","N","B","O","S","K","g","k","x","T","X","V","w","L","G","A","H","C","I","y","q","U","m","l","h","c","E","D","i","a","o","u","v","f","d","b","J","DropdownMenu","DropdownMenuPrimitive","DropdownMenuTrigger","DropdownMenuGroup","DropdownMenuPortal","DropdownMenuSub","DropdownMenuRadioGroup","DropdownMenuSubTrigger","inset","children","ChevronRight","DropdownMenuSubContent","DropdownMenuContent","sideOffset","DropdownMenuItem","DropdownMenuCheckboxItem","checked","Check","DropdownMenuRadioItem","Circle","DropdownMenuLabel","DropdownMenuSeparator","DropdownMenuShortcut","BookMenuItem","bookId","handleSelectBook","isSelected","handleHighlightBook","bookType","ShadDropdownMenuItem","Canon","ChapterSelect","handleSelectChapter","endChapter","activeChapter","highlightedChapter","handleHighlightedChapter","chapters","_","handleMouse","useCallback","chapterNumber","chapter","GoToMenuItem","handleSort","handleLocationHistory","handleBookmarks","ShadDropdownMenuLabel","ArrowDownWideNarrow","Clock","Bookmark","ALL_BOOK_IDS","BOOK_TYPE_LABELS","BOOK_TYPE_ARRAY","SCROLL_OFFSET","SEARCH_QUERY_FORMATS","fetchGroupedBooks","fetchEndChapter","getChaptersForBook","getAllEnglishNames","isValidBookEnglishName","bookName","getBookIdFromEnglishName","formattedBookName","BookChapterControl","scrRef","searchQuery","setSearchQuery","useState","selectedBookId","setSelectedBookId","setHighlightedChapter","highlightedBookId","setHighlightedBookId","isContentOpen","setIsContentOpen","isContentOpenDelayed","setIsContentOpenDelayed","inputRef","useRef","contentRef","menuItemRef","fetchFilteredBooks","englishNameLowerCase","normalizedQuery","handleSearchInput","searchString","shouldPreventAutoClosing","controlMenuState","open","updateReference","shouldClose","verse","handleInputSubmit","format","matches","book","englishName","handleKeyDownInput","handleKeyDownContent","key","handleKeyDownMenuItem","chapterOffSet","useEffect","useLayoutEffect","scrollTimeout","scrollPosition","ShadDropdownMenu","ShadDropdownMenuTrigger","ShadDropdownMenuContent","bookTypeIndex","element","ShadDropdownMenuSeparator","buttonVariants","cva","Button","variant","size","asChild","Slot","labelVariants","Label","LabelPrimitive","RadioGroup","RadioGroupPrimitive","RadioGroupItem","Popover","PopoverPrimitive","PopoverTrigger","PopoverContent","align","DialogPortal","DialogPrimitive","DialogOverlay","DialogContent","DialogTitle","DialogDescription","Command","CommandPrimitive","CommandInput","Search","CommandList","CommandEmpty","CommandGroup","CommandSeparator","CommandItem","getOptionLabelDefault","option","ComboBox","id","options","buttonClassName","popoverContentClassName","value","onChange","getOptionLabel","buttonPlaceholder","textPlaceholder","commandEmptyMessage","buttonVariant","dir","isDisabled","setOpen","ChevronsUpDown","ChapterRangeSelector","startChapter","handleSelectStartChapter","handleSelectEndChapter","chapterCount","chapterOptions","useMemo","index","Fragment","BookSelectionMode","BOOK_SELECTOR_STRING_KEYS","localizeString","strings","BookSelector","handleBookSelectionModeChange","currentBookName","onSelectBooks","selectedBookIds","localizedStrings","currentBookText","chooseText","chooseBooksText","bookSelectionMode","setBookSelectionMode","onSelectionModeChange","newMode","DataTableViewOptions","table","FilterIcon","column","Select","SelectPrimitive","SelectGroup","SelectValue","SelectTrigger","ChevronDown","SelectScrollUpButton","ChevronUp","SelectScrollDownButton","SelectContent","position","SelectLabel","SelectItem","SelectSeparator","DataTablePagination","pageSize","ArrowLeftIcon","ChevronLeftIcon","ChevronRightIcon","ArrowRightIcon","Table","stickyHeader","TableHeader","TableBody","TableFooter","TableRow","TableHead","TableCell","TableCaption","DataTable","columns","data","enablePagination","showPaginationControls","showColumnVisibilityControls","onRowClickHandler","sorting","setSorting","columnFilters","setColumnFilters","columnVisibility","setColumnVisibility","rowSelection","setRowSelection","useReactTable","getCoreRowModel","getPaginationRowModel","getSortedRowModel","getFilteredRowModel","headerGroup","header","flexRender","_a","row","cell","OccurrencesTable","occurrenceData","setScriptureReference","referenceHeaderText","occurrenceHeaderText","occurrences","uniqueOccurrences","occurrence","uniqueOccurrence","deepEqual","Checkbox","CheckboxPrimitive","getLinesFromUSFM","text","getNumberFromUSFM","regex","match","getBookNumFromId","getStatusForItem","item","approvedItems","unapprovedItems","toggleVariants","Toggle","TogglePrimitive","ToggleGroupContext","ToggleGroup","ToggleGroupPrimitive","ToggleGroupItem","context","getSortingIcon","sortDirection","ArrowUpIcon","ArrowDownIcon","ArrowUpDownIcon","inventoryItemColumn","itemLabel","inventoryAdditionalItemColumn","additionalItemLabel","additionalItemIndex","inventoryCountColumn","countLabel","statusChangeHandler","changedItems","newStatus","onApprovedItemsChange","onUnapprovedItemsChange","newApprovedItems","validItem","newUnapprovedItems","unapprovedItem","inventoryStatusColumn","statusLabel","status","CircleCheckIcon","CircleXIcon","CircleHelpIcon","INVENTORY_STRING_KEYS","filterItemData","itemData","statusFilter","textFilter","filteredItemData","createTableData","scriptureRef","itemRegex","tableData","currentBook","currentChapter","currentVerse","line","items","itemIndex","existingItem","tableEntry","newReference","substring","newItem","Inventory","scriptureReference","extractItems","additionalItemsLabels","scope","onScopeChange","allItemsText","approvedItemsText","unapprovedItemsText","unknownItemsText","scopeBookText","scopeChapterText","scopeVerseText","filterText","showAdditionalItemsText","showAdditionalItems","setShowAdditionalItems","setStatusFilter","setTextFilter","selectedItem","setSelectedItem","reducedTableData","newTableData","firstItem","existingEntry","newTableEntry","filteredTableData","allColumns","numberOfAdditionalItems","additionalColumns","_b","rowClickHandler","newSelection","handleScopeChange","handleStatusFilterChange","SearchBar","onSearch","placeholder","isFullWidth","handleInputChange","VerticalTabs","TabsPrimitive","VerticalTabsList","VerticalTabsTrigger","VerticalTabsContent","TabNavigationContentSearch","tabList","searchPlaceholder","headerTitle","isSearchBarFullWidth","direction","tab","Separator","orientation","decorative","SeparatorPrimitive","Sheet","SheetPrimitive","SheetPortal","SheetOverlay","sheetVariants","SheetContent","side","SheetTitle","SheetDescription","Skeleton","TooltipProvider","TooltipPrimitive","Tooltip","TooltipTrigger","TooltipContent","MOBILE_BREAKPOINT","useIsMobile","isMobile","setIsMobile","mql","SIDEBAR_COOKIE_NAME","SIDEBAR_COOKIE_MAX_AGE","SIDEBAR_WIDTH","SIDEBAR_WIDTH_MOBILE","SIDEBAR_WIDTH_ICON","SIDEBAR_KEYBOARD_SHORTCUT","SidebarContext","useSidebar","SidebarProvider","defaultOpen","openProp","setOpenProp","style","openMobile","setOpenMobile","_open","_setOpen","isOpen","openState","toggleSidebar","state","contextValue","Sidebar","collapsible","SidebarTrigger","onClick","PanelLeft","SidebarRail","SidebarInset","SidebarInput","SidebarHeader","SidebarFooter","SidebarSeparator","SidebarContent","SidebarGroup","SidebarGroupLabel","SidebarGroupAction","SidebarGroupContent","SidebarMenu","SidebarMenuItem","sidebarMenuButtonVariants","SidebarMenuButton","isActive","tooltip","Comp","button","SidebarMenuAction","showOnHover","SidebarMenuBadge","SidebarMenuSkeleton","showIcon","width","SidebarMenuSub","SidebarMenuSubItem","SidebarMenuSubButton","SettingsSidebar","extensionLabels","projectOptions","handleSelectSidebarItem","selectedSidebarItem","handleSelectItem","projectId","getProjectNameFromProjectId","project","getIsActive","label","selectedProjectName","SettingsSidebarContentSearch","scrBookColId","scrRefColId","typeColId","detailsColId","defaultScrRefColumnName","defaultScrBookGroupName","defaultTypeColumnName","defaultDetailsColumnName","getColumns","colInfo","showSourceColumn","showSrcCol","info","formatScrRef","compareScrRefs","toRefOrRange","scriptureSelection","offsetStart","offsetEnd","scrRefToBBBCCCVVV","getRowKey","ScriptureResultsViewer","sources","showColumnHeaders","scriptureReferenceColumnName","scriptureBookGroupName","typeColumnName","detailsColumnName","onRowSelected","grouping","setGrouping","scriptureResults","source","getExpandedRowModel","getGroupedRowModel","selectedRows","keys","selectedRow","scrBookGroupName","typeGroupName","groupingOptions","handleSelectChange","selectedGrouping","handleRowClick","getEvenOrOddBandingStyle","getIndent","groupingState","rowIndex","ChevronLeft","DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS","getLocalizeKeyForScrollGroupId","ScrollGroupSelector","availableScrollGroupIds","scrollGroupId","onChangeScrollGroupId","localizedStringsDefaulted","localizedStringKey","localizedStringValue","newScrollGroupString","scrollGroupOptionId","SettingsList","SettingsListItem","primary","secondary","isLoading","loadingMessage","SettingsListHeader","includeSeparator","Card","CardHeader","CardTitle","CardDescription","CardContent","CardFooter","SettingsCard","settingsGroupLabel","settingsGroupDescription","Checklist","listItems","selectedListItems","handleSelectListItem","createLabel","_interopRequireDefault","obj","module","chainPropTypes","propType1","propType2","args","_extends","target","isPlainObject","prototype","deepClone","output","deepmerge","p","r","t","z","reactIs_production_min","hasSymbol","REACT_ELEMENT_TYPE","REACT_PORTAL_TYPE","REACT_FRAGMENT_TYPE","REACT_STRICT_MODE_TYPE","REACT_PROFILER_TYPE","REACT_PROVIDER_TYPE","REACT_CONTEXT_TYPE","REACT_ASYNC_MODE_TYPE","REACT_CONCURRENT_MODE_TYPE","REACT_FORWARD_REF_TYPE","REACT_SUSPENSE_TYPE","REACT_SUSPENSE_LIST_TYPE","REACT_MEMO_TYPE","REACT_LAZY_TYPE","REACT_BLOCK_TYPE","REACT_FUNDAMENTAL_TYPE","REACT_RESPONDER_TYPE","REACT_SCOPE_TYPE","isValidElementType","typeOf","object","$$typeof","$$typeofType","AsyncMode","ConcurrentMode","ContextConsumer","ContextProvider","Element","ForwardRef","Lazy","Memo","Portal","Profiler","StrictMode","Suspense","hasWarnedAboutDeprecatedIsAsyncMode","isAsyncMode","isConcurrentMode","isContextConsumer","isContextProvider","isElement","isForwardRef","isFragment","isLazy","isMemo","isPortal","isProfiler","isStrictMode","isSuspense","reactIs_development","reactIsModule","require$$0","require$$1","getOwnPropertySymbols","hasOwnProperty","propIsEnumerable","toObject","val","shouldUseNative","test1","test2","order2","test3","letter","objectAssign","from","to","symbols","ReactPropTypesSecret","ReactPropTypesSecret_1","has","printWarning","loggedTypeFailures","message","checkPropTypes","typeSpecs","values","location","componentName","getStack","typeSpecName","error","err","ex","stack","checkPropTypes_1","ReactIs","assign","require$$2","require$$3","require$$4","emptyFunctionThatReturnsNull","factoryWithTypeCheckers","isValidElement","throwOnDirectAccess","ITERATOR_SYMBOL","FAUX_ITERATOR_SYMBOL","getIteratorFn","maybeIterable","iteratorFn","ANONYMOUS","ReactPropTypes","createPrimitiveTypeChecker","createAnyTypeChecker","createArrayOfTypeChecker","createElementTypeChecker","createElementTypeTypeChecker","createInstanceTypeChecker","createNodeChecker","createObjectOfTypeChecker","createEnumTypeChecker","createUnionTypeChecker","createShapeTypeChecker","createStrictShapeTypeChecker","is","PropTypeError","createChainableTypeChecker","validate","manualPropTypeCallCache","manualPropTypeWarningCount","checkType","isRequired","propName","propFullName","secret","cacheKey","chainedCheckType","expectedType","propValue","propType","getPropType","preciseType","getPreciseType","typeChecker","expectedClass","expectedClassName","actualClassName","getClassName","expectedValues","valuesString","arrayOfTypeCheckers","checker","getPostfixForTypeWarning","expectedTypes","checkerResult","expectedTypesMessage","isNode","invalidValidatorError","shapeTypes","allKeys","iterator","step","entry","isSymbol","emptyFunction","emptyFunctionWithReset","factoryWithThrowingShims","shim","getShim","propTypesModule","isClassComponent","elementType","acceptingRef","safePropName","warningHint","elementAcceptingRef","PropTypes","elementAcceptingRef$1","specialProperty","exactProp","propTypes","unsupportedProps","prop","formatMuiErrorMessage","code","url","REACT_SERVER_CONTEXT_TYPE","REACT_OFFSCREEN_TYPE","enableScopeAPI","enableCacheElement","enableTransitionTracing","enableLegacyHidden","enableDebugTracing","REACT_MODULE_REFERENCE","SuspenseList","hasWarnedAboutDeprecatedIsConcurrentMode","isSuspenseList","fnNameMatchRegex","getFunctionName","fn","getFunctionComponentName","Component","fallback","getWrappedName","outerType","innerType","wrapperName","functionName","getDisplayName","HTMLElementType","refType","refType$1","capitalize","string","_formatMuiErrorMessage","createChainedFunction","funcs","acc","func","debounce","wait","timeout","debounced","later","deprecatedPropType","validator","reason","componentNameSafe","propFullNameSafe","isMuiElement","muiNames","_muiName","_element$type","ownerDocument","node","ownerWindow","requirePropFactory","componentNameInError","prevPropTypes","requiredProp","defaultTypeChecker","typeCheckerResult","setRef","useEnhancedEffect","useEnhancedEffect$1","globalId","useGlobalId","idOverride","defaultId","setDefaultId","maybeReactUseId","useId","reactId","unsupportedProp","useControlled","controlled","defaultProp","name","isControlled","valueState","setValue","defaultValue","setValueIfUncontrolled","newValue","useEventCallback","useForkRef","refs","instance","UNINITIALIZED","useLazyRef","init","initArg","EMPTY","useOnMount","Timeout","delay","useTimeout","hadKeyboardEvent","hadFocusVisibleRecently","hadFocusVisibleRecentlyTimeout","inputTypesWhitelist","focusTriggersKeyboardModality","tagName","handlePointerDown","handleVisibilityChange","prepare","doc","isFocusVisible","useIsFocusVisible","isFocusVisibleRef","handleBlurVisible","handleFocusVisible","resolveProps","defaultProps","defaultSlotProps","slotProps","slotPropName","composeClasses","slots","getUtilityClass","classes","slot","utilityClass","defaultGenerator","createClassNameGenerator","generate","generator","ClassNameGenerator","ClassNameGenerator$1","globalStateClasses","generateUtilityClass","globalStatePrefix","globalStateClass","generateUtilityClasses","result","clamp","min","max","_objectWithoutPropertiesLoose","excluded","sourceKeys","_excluded","sortBreakpointsValues","breakpointsAsArray","breakpoint1","breakpoint2","createBreakpoints","breakpoints","unit","other","sortedValues","up","down","between","start","end","endIndex","only","not","keyIndex","shape","shape$1","responsivePropType","responsivePropType$1","merge","defaultBreakpoints","handleBreakpoints","styleFromPropValue","theme","themeBreakpoints","breakpoint","mediaKey","cssKey","createEmptyBreakpointObject","breakpointsInput","_breakpointsInput$key","breakpointStyleKey","removeUnusedBreakpoints","breakpointKeys","breakpointOutput","getPath","path","checkVars","getStyleValue","themeMapping","transform","propValueFinal","userValue","cssProperty","themeKey","memoize","cache","arg","properties","directions","aliases","getCssProperties","property","marginKeys","paddingKeys","spacingKeys","createUnaryUnit","_getPath","themeSpacing","abs","createUnarySpacing","getValue","transformer","transformed","getStyleFromPropValue","cssProperties","resolveCssProperty","margin","padding","createSpacing","spacingInput","spacing","argsInput","argument","compose","styles","handlers","borderTransform","createBorderStyle","border","borderTop","borderRight","borderBottom","borderLeft","borderColor","borderTopColor","borderRightColor","borderBottomColor","borderLeftColor","outline","outlineColor","borderRadius","gap","columnGap","rowGap","gridColumn","gridRow","gridAutoFlow","gridAutoColumns","gridAutoRows","gridTemplateColumns","gridTemplateRows","gridTemplateAreas","gridArea","paletteTransform","color","bgcolor","backgroundColor","sizingTransform","maxWidth","_props$theme","_props$theme2","breakpointsValues","minWidth","height","maxHeight","minHeight","boxSizing","defaultSxConfig","defaultSxConfig$1","objectsHaveSameKeys","objects","union","callIfFn","maybeFn","unstable_createStyleFunctionSx","getThemeValue","config","styleFunctionSx","_theme$unstable_sxCon","sx","traverse","sxInput","sxObject","emptyBreakpoints","breakpointsKeys","css","styleKey","styleFunctionSx$1","applyStyles","createTheme","paletteInput","shapeInput","muiTheme","isObjectEmpty","useTheme","defaultTheme","contextTheme","ThemeContext","systemDefaultTheme","useThemeWithoutDefault","_excluded2","_excluded3","isEmpty","isStringTag","tag","shouldForwardProp","lowercaseFirstLetter","resolveTheme","themeId","defaultOverridesResolver","processStyleArg","callableStyle","_ref","ownerState","resolvedStylesArg","resolvedStyle","variants","isMatch","createStyled","input","rootShouldForwardProp","slotShouldForwardProp","systemSx","inputOptions","processStyles","componentSlot","inputSkipVariantsResolver","inputSkipSx","overridesResolver","skipVariantsResolver","skipSx","shouldForwardPropOption","defaultStyledResolver","styledEngineStyled","transformStyleArg","stylesArg","muiStyledResolver","styleArg","expressions","transformedStyleArg","expressionsWithDefaultTheme","styleOverrides","resolvedStyleOverrides","slotKey","slotStyle","_theme$components","themeVariants","numOfCustomFnsApplied","placeholders","displayName","getThemeProps","params","useThemeProps","clampWrapper","hexToRgb","re","colors","decomposeColor","marker","colorSpace","recomposeColor","hslToRgb","rgb","getLuminance","getContrastRatio","foreground","background","lumA","lumB","alpha","darken","coefficient","lighten","createMixins","mixins","common","common$1","grey","grey$1","purple","purple$1","red","red$1","orange","orange$1","blue","blue$1","lightBlue","lightBlue$1","green","green$1","light","dark","addLightOrDark","intent","shade","tonalOffset","tonalOffsetLight","tonalOffsetDark","getDefaultPrimary","mode","getDefaultSecondary","getDefaultError","getDefaultInfo","getDefaultSuccess","getDefaultWarning","createPalette","palette","contrastThreshold","success","warning","getContrastText","contrastText","contrast","augmentColor","mainShade","lightShade","darkShade","modes","round","caseAllCaps","defaultFontFamily","createTypography","typography","fontFamily","fontSize","fontWeightLight","fontWeightRegular","fontWeightMedium","fontWeightBold","htmlFontSize","allVariants","pxToRem2","coef","pxToRem","buildVariant","fontWeight","lineHeight","letterSpacing","casing","shadowKeyUmbraOpacity","shadowKeyPenumbraOpacity","shadowAmbientShadowOpacity","createShadow","px","shadows","shadows$1","easing","duration","formatMs","milliseconds","getAutoHeightDuration","constant","createTransitions","inputTransitions","mergedEasing","mergedDuration","durationOption","easingOption","isString","isNumber","animatedProp","zIndex","zIndex$1","mixinsInput","transitionsInput","typographyInput","systemTheme","systemCreateTheme","stateClasses","component","child","stateClass","defaultTheme$1","THEME_ID","systemUseThemeProps","styled","styled$1","getSvgIconUtilityClass","useUtilityClasses","SvgIconRoot","_theme$transitions","_theme$transitions$cr","_theme$transitions2","_theme$typography","_theme$typography$pxT","_theme$typography2","_theme$typography2$px","_theme$typography3","_theme$typography3$px","_palette$ownerState$c","_palette","_palette2","_palette3","SvgIcon","inProps","htmlColor","inheritViewBox","titleAccess","viewBox","hasSvgAsChild","more","_jsxs","_jsx","SvgIcon$1","createSvgIcon","unstable_ClassNameGenerator","exports","_utils","ArrowRight","default_1","_createSvgIcon","_jsxRuntime","isHostComponent","appendOwnerState","otherProps","defaultContextValue","ClassNameConfiguratorContext","useClassNamesOverride","disableDefaultClasses","extractEventHandlers","excludeKeys","resolveComponentProps","componentProps","slotState","omitEventHandlers","mergeSlotProps","parameters","getSlotProps","additionalProps","externalSlotProps","externalForwardedProps","joinedClasses","mergedStyle","eventHandlers","componentsPropsWithoutEventHandlers","otherPropsWithoutEventHandlers","internalSlotProps","useSlotProps","_parameters$additiona","skipResolvingSlotProps","rest","resolvedComponentsProps","mergedProps","internalRef","GLOBAL_CLASS_PREFIX","buildStateClass","buildSlotClass","getContainer","container","forwardedRef","disablePortal","mountNode","setMountNode","handleRef","newProps","ReactDOM","top","bottom","right","left","auto","basePlacements","clippingParents","viewport","popper","reference","variationPlacements","placement","placements","beforeRead","read","afterRead","beforeMain","main","afterMain","beforeWrite","write","afterWrite","modifierPhases","getNodeName","getWindow","OwnElement","isHTMLElement","isShadowRoot","attributes","effect","_ref2","initialStyles","styleProperties","attribute","applyStyles$1","getBasePlacement","getUAString","uaData","isLayoutViewport","getBoundingClientRect","includeScale","isFixedStrategy","clientRect","scaleX","scaleY","visualViewport","addVisualOffsets","getLayoutRect","contains","parent","rootNode","next","getComputedStyle","isTableElement","getDocumentElement","getParentNode","getTrueOffsetParent","getContainingBlock","isFirefox","isIE","elementCss","currentNode","getOffsetParent","window","offsetParent","getMainAxisFromPlacement","within","mathMax","mathMin","withinMaxClamp","getFreshSideObject","mergePaddingObject","paddingObject","expandToHashMap","hashMap","toPaddingObject","arrow","_state$modifiersData$","arrowElement","popperOffsets","basePlacement","axis","isVertical","len","arrowRect","minProp","maxProp","endDiff","startDiff","arrowOffsetParent","clientSize","centerToReference","center","offset","axisProp","_options$element","arrow$1","getVariation","unsetSides","roundOffsetsByDPR","win","dpr","mapToStyles","_Object$assign2","popperRect","variation","offsets","gpuAcceleration","adaptive","roundOffsets","isFixed","_offsets$x","_offsets$y","_ref3","hasX","hasY","sideX","sideY","heightProp","widthProp","offsetY","offsetX","commonStyles","_ref4","_Object$assign","computeStyles","_ref5","_options$gpuAccelerat","_options$adaptive","_options$roundOffsets","computeStyles$1","passive","_options$scroll","scroll","_options$resize","resize","scrollParents","scrollParent","eventListeners","hash","getOppositePlacement","matched","getOppositeVariationPlacement","getWindowScroll","scrollLeft","scrollTop","getWindowScrollBarX","getViewportRect","strategy","html","layoutViewport","getDocumentRect","_element$ownerDocumen","winScroll","body","isScrollParent","_getComputedStyle","overflow","overflowX","overflowY","getScrollParent","listScrollParents","list","isBody","updatedList","rectToClientRect","rect","getInnerBoundingClientRect","getClientRectFromMixedType","clippingParent","getClippingParents","canEscapeClipping","clipperElement","getClippingRect","boundary","rootBoundary","mainClippingParents","firstClippingParent","clippingRect","accRect","computeOffsets","commonX","commonY","mainAxis","detectOverflow","_options","_options$placement","_options$strategy","_options$boundary","_options$rootBoundary","_options$elementConte","elementContext","_options$altBoundary","altBoundary","_options$padding","altContext","clippingClientRect","referenceClientRect","popperClientRect","elementClientRect","overflowOffsets","offsetData","multiply","computeAutoPlacement","flipVariations","_options$allowedAutoP","allowedAutoPlacements","allPlacements","allowedPlacements","overflows","getExpandedFallbackPlacements","oppositePlacement","flip","_options$mainAxis","checkMainAxis","_options$altAxis","checkAltAxis","specifiedFallbackPlacements","_options$flipVariatio","preferredPlacement","isBasePlacement","fallbackPlacements","referenceRect","checksMap","makeFallbackChecks","firstFittingPlacement","_basePlacement","isStartVariation","mainVariationSide","altVariationSide","checks","check","numberOfChecks","_loop","_i","fittingPlacement","_ret","flip$1","getSideOffsets","preventedOffsets","isAnySideFullyClipped","hide","referenceOverflow","popperAltOverflow","referenceClippingOffsets","popperEscapeOffsets","isReferenceHidden","hasPopperEscaped","hide$1","distanceAndSkiddingToXY","rects","invertDistance","skidding","distance","_options$offset","_data$state$placement","offset$1","popperOffsets$1","getAltAxis","preventOverflow","_options$tether","tether","_options$tetherOffset","tetherOffset","altAxis","tetherOffsetValue","normalizedTetherOffsetValue","offsetModifierState","_offsetModifierState$","mainSide","altSide","additive","minLen","maxLen","arrowPaddingObject","arrowPaddingMin","arrowPaddingMax","arrowLen","minOffset","maxOffset","clientOffset","offsetModifierValue","tetherMin","tetherMax","preventedOffset","_offsetModifierState$2","_mainSide","_altSide","_offset","_len","_min","_max","isOriginSide","_offsetModifierValue","_tetherMin","_tetherMax","_preventedOffset","preventOverflow$1","getHTMLElementScroll","getNodeScroll","isElementScaled","getCompositeRect","elementOrVirtualElement","isOffsetParentAnElement","offsetParentIsScaled","documentElement","order","modifiers","map","visited","modifier","sort","requires","dep","depModifier","orderModifiers","orderedModifiers","phase","pending","resolve","mergeByName","merged","current","existing","DEFAULT_OPTIONS","areValidElements","_key","popperGenerator","generatorOptions","_generatorOptions","_generatorOptions$def","defaultModifiers","_generatorOptions$def2","defaultOptions","effectCleanupFns","isDestroyed","setOptionsAction","cleanupModifierEffects","runModifierEffects","_state$elements","_state$orderedModifie","_state$orderedModifie2","_ref$options","cleanupFn","noopFn","createPopper","COMPONENT_NAME","getPopperUtilityClass","flipPlacement","resolveAnchorEl","anchorEl","isVirtualElement","defaultPopperOptions","PopperTooltip","_slots$root","initialPlacement","popperOptions","popperRefProp","TransitionProps","tooltipRef","ownRef","popperRef","handlePopperRef","handlePopperRefRef","rtlPlacement","setPlacement","resolvedAnchorElement","setResolvedAnchorElement","handlePopperUpdate","box","popperModifiers","childProps","Root","rootProps","Popper","containerProp","keepMounted","transition","exited","setExited","handleEnter","handleExited","resolvedAnchorEl","display","transitionProps","useThemeSystem","_setPrototypeOf","_inheritsLoose","subClass","superClass","setPrototypeOf","timeoutsShape","TransitionGroupContext","forceReflow","UNMOUNTED","EXITED","ENTERING","ENTERED","EXITING","Transition","_React$Component","_this","parentGroup","appear","initialStatus","prevState","nextIn","_proto","prevProps","nextStatus","exit","enter","mounting","_this2","appearing","maybeNode","maybeAppearing","timeouts","enterTimeout","_this3","nextState","callback","_this4","active","handler","doesNotHaveTimeoutOrListener","maybeNextCallback","_this$props","pt","noop","Transition$1","reflow","getTransitionProps","_style$transitionDura","_style$transitionTimi","getScale","isWebKit154","Grow","addEndListener","inProp","onEnter","onEntered","onEntering","onExit","onExited","onExiting","TransitionComponent","timer","autoTimeout","nodeRef","normalizedTransitionCallback","maybeIsAppearing","handleEntering","isAppearing","transitionDuration","transitionTimingFunction","handleEntered","handleExiting","handleExit","Grow$1","PopperRoot","BasePopper","components","componentsProps","RootComponent","Popper$1","getTooltipUtilityClass","tooltipClasses","tooltipClasses$1","disableInteractive","touch","TooltipPopper","TooltipTooltip","TooltipArrow","hystersisOpen","hystersisTimer","cursorPosition","composeEventHandler","eventHandler","_slots$popper","_slots$transition","_slots$tooltip","_slots$arrow","_slotProps$popper","_ref6","_slotProps$popper2","_slotProps$transition","_slotProps$tooltip","_ref7","_slotProps$tooltip2","_slotProps$arrow","_ref8","_slotProps$arrow2","childrenProp","describeChild","disableFocusListener","disableHoverListener","disableInteractiveProp","disableTouchListener","enterDelay","enterNextDelay","enterTouchDelay","followCursor","idProp","leaveDelay","leaveTouchDelay","onClose","onOpen","PopperComponentProp","PopperProps","title","TransitionComponentProp","isRtl","childNode","setChildNode","arrowRef","setArrowRef","ignoreNonTouchEvents","closeTimer","enterTimer","leaveTimer","touchTimer","setOpenState","prevUserSelect","stopTouchInteraction","handleOpen","handleClose","handleLeave","focusVisibleRef","setChildIsFocusVisible","handleBlur","handleFocus","detectTouchStart","childrenProps","handleMouseOver","handleMouseLeave","handleTouchStart","handleTouchEnd","nativeEvent","handleMouseMove","nameOrDescProps","titleIsString","interactiveWrapperListeners","_PopperProps$popperOp","tooltipModifiers","PopperComponent","TooltipComponent","ArrowComponent","popperProps","tooltipProps","tooltipArrowProps","TransitionPropsInner","Tooltip$1","getIcon","icon","menuLabel","leading","MuiListItemIcon","MenuItem","allowForLeadingIcons","iconPathBefore","iconPathAfter","hasAutoFocus","isDense","isSubMenuParent","hasDisabledGutters","hasDivider","focusVisibleClassName","menuItem","MuiMenuItem","MuiListItemText","getAllGroups","menuDefinition","SubMenu","setAnchorEl","parentMenuItem","parentItemProps","handleParentMenuItemClick","renderSubMenuItems","includedGroups","group","GroupedMenuItemList","Menu","getOrderedGroupItems","groupId","allItems","menuProps","commandHandler","groupsToInclude","sortedGroups","itemArray","allowSpaceForLeadingIcons","createMenuItemProps","isLastItemInGroup","divKey","itemInfo","menuItemProps","TopLevelMenu","columnId","MenuColumn","metadata","Grid","List","GridMenu","multiColumnMenu","sortedColumns","columnNumbers","columnName","col","getUsePromiseOptionsDefaults","usePromise","promiseFactoryCallback","defaultValueRef","optionsDefaultedRef","setIsLoading","promiseIsCurrent","MenuIcon","HamburgerMenuButton","menuProvider","normalMenu","fullMenu","containerRef","ariaLabelPrefix","isMenuOpen","setMenuOpen","showFullMenu","setShowFullMenu","handleMenuItemClick","handleMenuButtonClick","prevIsOpen","isOpening","menuCommandHandler","command","setOffset","normalMenuData","fullMenuData","menu","IconButton","Drawer","isTooltipSuppressed","adjustMarginToAlignToEdge","MuiIconButton","Spinner","LoaderCircle","TextField","hasError","helperText","onFocus","onBlur","ShadLabel","Toolbar","AppBar","MuiToolbar","alertVariants","Alert","AlertTitle","AlertDescription","Sonner","Toaster","Slider","SliderPrimitive","Switch","SwitchPrimitives","Tabs","TabsList","TabsTrigger","TabsContent","InstallButton","isInstalling","handleClick","buttonText","Download","EnableButton","isEnabling","DisableButton","isDisabling","UpdateButton","isUpdating","MarkdownRenderer","markdown","anchorTarget","Markdown","FilterButton","Filter","DropdownMenuItemType","DropdownMenuItemType2","FilterDropdown","groups","NoExtensionsFound","MoreInfo","category","downloads","languages","moreInfoUrl","numberFormatted","NumberFormat","handleScrollToBottom","User","locale","LucideLink","CircleHelp","VersionHistory","versionHistory","showAllVersions","setShowAllVersions","currentDate","formatTimeString","dateString","date","dateDiff","yearDiff","monthDiff","dayDiff","timeString","sortedEntries","Footer","publisherDisplayName","fileSize","locales","formattedFileSize","formatBytes","languageNames","codes","displayNames","useEvent","unsubscriber","noopUnsubscriber","useEventAsync","unsubscribe","unsub"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAGA,MAAMA,KAAgBC,GAAoB,EAAE,QAAQ,MAAO,CAAA;AAyDpD,SAASC,KAAMC,GAAsB;AACnC,SAAAH,GAAcI,GAAKD,CAAM,CAAC;AACnC;ACzDO,MAAME,KAAQC,EAAM;AAAA,EACzB,CAAC,EAAE,WAAAC,GAAW,MAAAC,GAAM,GAAGC,EAAA,GAASC,MAE5B,gBAAAC;AAAA,IAAC;AAAA,IAAA;AAAA,MACC,MAAAH;AAAA,MACA,WAAWN;AAAA,QACT;AAAA,QACAK;AAAA,MACF;AAAA,MACA,KAAAG;AAAA,MAEC,GAAGD;AAAA,IAAA;AAAA,EAAA;AAIZ;AACAJ,GAAM,cAAc;ACNpB,MAAMO,KAAmBC;AAAA,EACvB,CACE,EAAE,cAAAC,GAAc,eAAAC,GAAe,eAAAC,GAAe,cAAAC,GAAc,GAAGR,EAAM,GACrEC,MAGE,gBAAAQ,EAAC,OAAI,EAAA,WAAU,eACb,UAAA;AAAA,IAAA,gBAAAP;AAAA,MAACQ;AAAAA,MAAA;AAAA,QACE,GAAGV;AAAA,QACJ,MAAK;AAAA,QACL,WAAU;AAAA,QACV,UAAU,CAACW,MAAUN,EAAaM,EAAM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AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA;AAAA;AAAA,EAGA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AACF,GAAGC,KAAIC;AACP,SAAS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;;;;;;;","x_google_ignoreList":[3,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,83,84,85,86,87,88,89,90,91,92,93,94,95,96,97,98,99,100,101,102,103,104,105,106,107,108,109,110,111,112,113,114,115,116,117,118,119,120,121,122,123,124,125,126,127,128,129,130,131,132,133,134,135,136,137,138,139,140,141,142,143,144,145,146,147,148,149,150,151,152,153,154,155,156,157,158,159,160,161,162,163,164,165,166,167,168,169,170,171,172,173,174,175,176,177,178,179,180,181,182,183,184,185,186,187,188,189,190,191,192,193,194,195,196,197,198,199,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,230]} \ No newline at end of file +{"version":3,"file":"index.js","sources":["../src/utils/shadcn-ui.util.ts","../src/components/shadcn-ui/input.tsx","../src/components/advanced/book-chapter-control/book-chapter-input.component.tsx","../../../node_modules/@sillsdev/scripture/dist/index.es.js","../src/components/shadcn-ui/dropdown-menu.tsx","../src/components/advanced/book-chapter-control/book-menu-item.component.tsx","../src/components/advanced/book-chapter-control/chapter-select.component.tsx","../src/components/advanced/book-chapter-control/go-to-menu-item.component.tsx","../src/components/advanced/book-chapter-control/book-chapter-control.component.tsx","../src/components/shadcn-ui/button.tsx","../src/components/shadcn-ui/label.tsx","../src/components/shadcn-ui/radio-group.tsx","../src/components/shadcn-ui/popover.tsx","../src/components/shadcn-ui/dialog.tsx","../src/components/shadcn-ui/command.tsx","../src/components/basics/combo-box.component.tsx","../src/components/basics/chapter-range-selector.component.tsx","../src/components/advanced/book-selector.component.tsx","../src/components/advanced/data-table/data-table-column-toggle.component.tsx","../src/components/shadcn-ui/select.tsx","../src/components/advanced/data-table/data-table-pagination.component.tsx","../src/components/shadcn-ui/table.tsx","../src/components/advanced/data-table/data-table.component.tsx","../src/components/advanced/inventory/occurrences-table.component.tsx","../src/components/shadcn-ui/checkbox.tsx","../src/components/advanced/inventory/inventory-utils.ts","../src/components/shadcn-ui/toggle.tsx","../src/components/shadcn-ui/toggle-group.tsx","../src/components/advanced/inventory/inventory-columns.tsx","../src/components/advanced/inventory/inventory.component.tsx","../src/components/basics/search-bar.component.tsx","../src/components/basics/tabs-vertical.tsx","../src/components/advanced/tab-navigation-content-search.component.tsx","../src/components/shadcn-ui/separator.tsx","../src/components/shadcn-ui/sheet.tsx","../src/components/shadcn-ui/skeleton.tsx","../src/components/shadcn-ui/tooltip.tsx","../src/components/hooks/use-mobile.tsx","../src/components/shadcn-ui/sidebar.tsx","../src/components/advanced/settings-components/settings-sidebar.component.tsx","../src/components/advanced/settings-components/settings-sidebar-content-search.component.tsx","../src/components/advanced/scripture-results-viewer/scripture-results-viewer.component.tsx","../src/components/advanced/scroll-group-selector.component.tsx","../src/components/advanced/settings-components/settings-list.component.tsx","../src/components/basics/checklist.component.tsx","../../../node_modules/@babel/runtime/helpers/interopRequireDefault.js","../../../node_modules/@mui/utils/chainPropTypes/chainPropTypes.js","../../../node_modules/@babel/runtime/helpers/esm/extends.js","../../../node_modules/@mui/utils/deepmerge/deepmerge.js","../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.production.min.js","../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.development.js","../../../node_modules/prop-types/node_modules/react-is/index.js","../../../node_modules/object-assign/index.js","../../../node_modules/prop-types/lib/ReactPropTypesSecret.js","../../../node_modules/prop-types/lib/has.js","../../../node_modules/prop-types/checkPropTypes.js","../../../node_modules/prop-types/factoryWithTypeCheckers.js","../../../node_modules/prop-types/factoryWithThrowingShims.js","../../../node_modules/prop-types/index.js","../../../node_modules/@mui/utils/elementAcceptingRef/elementAcceptingRef.js","../../../node_modules/@mui/utils/exactProp/exactProp.js","../../../node_modules/@mui/utils/formatMuiErrorMessage/formatMuiErrorMessage.js","../../../node_modules/react-is/cjs/react-is.production.min.js","../../../node_modules/react-is/cjs/react-is.development.js","../../../node_modules/react-is/index.js","../../../node_modules/@mui/utils/getDisplayName/getDisplayName.js","../../../node_modules/@mui/utils/HTMLElementType/HTMLElementType.js","../../../node_modules/@mui/utils/refType/refType.js","../../../node_modules/@mui/utils/capitalize/capitalize.js","../../../node_modules/@mui/utils/createChainedFunction/createChainedFunction.js","../../../node_modules/@mui/utils/debounce/debounce.js","../../../node_modules/@mui/utils/deprecatedPropType/deprecatedPropType.js","../../../node_modules/@mui/utils/isMuiElement/isMuiElement.js","../../../node_modules/@mui/utils/ownerDocument/ownerDocument.js","../../../node_modules/@mui/utils/ownerWindow/ownerWindow.js","../../../node_modules/@mui/utils/requirePropFactory/requirePropFactory.js","../../../node_modules/@mui/utils/setRef/setRef.js","../../../node_modules/@mui/utils/useEnhancedEffect/useEnhancedEffect.js","../../../node_modules/@mui/utils/useId/useId.js","../../../node_modules/@mui/utils/unsupportedProp/unsupportedProp.js","../../../node_modules/@mui/utils/useControlled/useControlled.js","../../../node_modules/@mui/utils/useEventCallback/useEventCallback.js","../../../node_modules/@mui/utils/useForkRef/useForkRef.js","../../../node_modules/@mui/utils/useLazyRef/useLazyRef.js","../../../node_modules/@mui/utils/useOnMount/useOnMount.js","../../../node_modules/@mui/utils/useTimeout/useTimeout.js","../../../node_modules/@mui/utils/useIsFocusVisible/useIsFocusVisible.js","../../../node_modules/@mui/utils/resolveProps/resolveProps.js","../../../node_modules/@mui/utils/composeClasses/composeClasses.js","../../../node_modules/@mui/utils/ClassNameGenerator/ClassNameGenerator.js","../../../node_modules/@mui/utils/generateUtilityClass/generateUtilityClass.js","../../../node_modules/@mui/utils/generateUtilityClasses/generateUtilityClasses.js","../../../node_modules/@mui/utils/clamp/clamp.js","../../../node_modules/@babel/runtime/helpers/esm/objectWithoutPropertiesLoose.js","../../../node_modules/@mui/system/esm/createTheme/createBreakpoints.js","../../../node_modules/@mui/system/esm/createTheme/shape.js","../../../node_modules/@mui/system/esm/responsivePropType.js","../../../node_modules/@mui/system/esm/merge.js","../../../node_modules/@mui/system/esm/breakpoints.js","../../../node_modules/@mui/system/esm/style.js","../../../node_modules/@mui/system/esm/memoize.js","../../../node_modules/@mui/system/esm/spacing.js","../../../node_modules/@mui/system/esm/createTheme/createSpacing.js","../../../node_modules/@mui/system/esm/compose.js","../../../node_modules/@mui/system/esm/borders.js","../../../node_modules/@mui/system/esm/cssGrid.js","../../../node_modules/@mui/system/esm/palette.js","../../../node_modules/@mui/system/esm/sizing.js","../../../node_modules/@mui/system/esm/styleFunctionSx/defaultSxConfig.js","../../../node_modules/@mui/system/esm/styleFunctionSx/styleFunctionSx.js","../../../node_modules/@mui/system/esm/createTheme/applyStyles.js","../../../node_modules/@mui/system/esm/createTheme/createTheme.js","../../../node_modules/@mui/system/esm/useThemeWithoutDefault.js","../../../node_modules/@mui/system/esm/useTheme.js","../../../node_modules/@mui/system/esm/createStyled.js","../../../node_modules/@mui/system/esm/useThemeProps/getThemeProps.js","../../../node_modules/@mui/system/esm/useThemeProps/useThemeProps.js","../../../node_modules/@mui/system/esm/colorManipulator.js","../../../node_modules/@mui/material/styles/createMixins.js","../../../node_modules/@mui/material/colors/common.js","../../../node_modules/@mui/material/colors/grey.js","../../../node_modules/@mui/material/colors/purple.js","../../../node_modules/@mui/material/colors/red.js","../../../node_modules/@mui/material/colors/orange.js","../../../node_modules/@mui/material/colors/blue.js","../../../node_modules/@mui/material/colors/lightBlue.js","../../../node_modules/@mui/material/colors/green.js","../../../node_modules/@mui/material/styles/createPalette.js","../../../node_modules/@mui/material/styles/createTypography.js","../../../node_modules/@mui/material/styles/shadows.js","../../../node_modules/@mui/material/styles/createTransitions.js","../../../node_modules/@mui/material/styles/zIndex.js","../../../node_modules/@mui/material/styles/createTheme.js","../../../node_modules/@mui/material/styles/defaultTheme.js","../../../node_modules/@mui/material/styles/identifier.js","../../../node_modules/@mui/material/styles/useThemeProps.js","../../../node_modules/@mui/material/styles/styled.js","../../../node_modules/@mui/material/SvgIcon/svgIconClasses.js","../../../node_modules/@mui/material/SvgIcon/SvgIcon.js","../../../node_modules/@mui/material/utils/createSvgIcon.js","../../../node_modules/@mui/material/utils/index.js","../../../node_modules/@mui/icons-material/utils/createSvgIcon.js","../../../node_modules/@mui/icons-material/ArrowRight.js","../../../node_modules/@mui/base/utils/isHostComponent.js","../../../node_modules/@mui/base/utils/appendOwnerState.js","../../../node_modules/@mui/base/utils/ClassNameConfigurator.js","../../../node_modules/@mui/base/utils/extractEventHandlers.js","../../../node_modules/@mui/base/utils/resolveComponentProps.js","../../../node_modules/@mui/base/utils/omitEventHandlers.js","../../../node_modules/@mui/base/utils/mergeSlotProps.js","../../../node_modules/@mui/base/utils/useSlotProps.js","../../../node_modules/@mui/base/generateUtilityClass/index.js","../../../node_modules/@mui/base/generateUtilityClasses/index.js","../../../node_modules/@mui/base/Portal/Portal.js","../../../node_modules/@popperjs/core/lib/enums.js","../../../node_modules/@popperjs/core/lib/dom-utils/getNodeName.js","../../../node_modules/@popperjs/core/lib/dom-utils/getWindow.js","../../../node_modules/@popperjs/core/lib/dom-utils/instanceOf.js","../../../node_modules/@popperjs/core/lib/modifiers/applyStyles.js","../../../node_modules/@popperjs/core/lib/utils/getBasePlacement.js","../../../node_modules/@popperjs/core/lib/utils/math.js","../../../node_modules/@popperjs/core/lib/utils/userAgent.js","../../../node_modules/@popperjs/core/lib/dom-utils/isLayoutViewport.js","../../../node_modules/@popperjs/core/lib/dom-utils/getBoundingClientRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/getLayoutRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/contains.js","../../../node_modules/@popperjs/core/lib/dom-utils/getComputedStyle.js","../../../node_modules/@popperjs/core/lib/dom-utils/isTableElement.js","../../../node_modules/@popperjs/core/lib/dom-utils/getDocumentElement.js","../../../node_modules/@popperjs/core/lib/dom-utils/getParentNode.js","../../../node_modules/@popperjs/core/lib/dom-utils/getOffsetParent.js","../../../node_modules/@popperjs/core/lib/utils/getMainAxisFromPlacement.js","../../../node_modules/@popperjs/core/lib/utils/within.js","../../../node_modules/@popperjs/core/lib/utils/getFreshSideObject.js","../../../node_modules/@popperjs/core/lib/utils/mergePaddingObject.js","../../../node_modules/@popperjs/core/lib/utils/expandToHashMap.js","../../../node_modules/@popperjs/core/lib/modifiers/arrow.js","../../../node_modules/@popperjs/core/lib/utils/getVariation.js","../../../node_modules/@popperjs/core/lib/modifiers/computeStyles.js","../../../node_modules/@popperjs/core/lib/modifiers/eventListeners.js","../../../node_modules/@popperjs/core/lib/utils/getOppositePlacement.js","../../../node_modules/@popperjs/core/lib/utils/getOppositeVariationPlacement.js","../../../node_modules/@popperjs/core/lib/dom-utils/getWindowScroll.js","../../../node_modules/@popperjs/core/lib/dom-utils/getWindowScrollBarX.js","../../../node_modules/@popperjs/core/lib/dom-utils/getViewportRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/getDocumentRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/isScrollParent.js","../../../node_modules/@popperjs/core/lib/dom-utils/getScrollParent.js","../../../node_modules/@popperjs/core/lib/dom-utils/listScrollParents.js","../../../node_modules/@popperjs/core/lib/utils/rectToClientRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/getClippingRect.js","../../../node_modules/@popperjs/core/lib/utils/computeOffsets.js","../../../node_modules/@popperjs/core/lib/utils/detectOverflow.js","../../../node_modules/@popperjs/core/lib/utils/computeAutoPlacement.js","../../../node_modules/@popperjs/core/lib/modifiers/flip.js","../../../node_modules/@popperjs/core/lib/modifiers/hide.js","../../../node_modules/@popperjs/core/lib/modifiers/offset.js","../../../node_modules/@popperjs/core/lib/modifiers/popperOffsets.js","../../../node_modules/@popperjs/core/lib/utils/getAltAxis.js","../../../node_modules/@popperjs/core/lib/modifiers/preventOverflow.js","../../../node_modules/@popperjs/core/lib/dom-utils/getHTMLElementScroll.js","../../../node_modules/@popperjs/core/lib/dom-utils/getNodeScroll.js","../../../node_modules/@popperjs/core/lib/dom-utils/getCompositeRect.js","../../../node_modules/@popperjs/core/lib/utils/orderModifiers.js","../../../node_modules/@popperjs/core/lib/utils/debounce.js","../../../node_modules/@popperjs/core/lib/utils/mergeByName.js","../../../node_modules/@popperjs/core/lib/createPopper.js","../../../node_modules/@popperjs/core/lib/popper.js","../../../node_modules/@mui/base/Popper/popperClasses.js","../../../node_modules/@mui/base/Popper/Popper.js","../../../node_modules/@mui/material/styles/useTheme.js","../../../node_modules/@babel/runtime/helpers/esm/setPrototypeOf.js","../../../node_modules/@babel/runtime/helpers/esm/inheritsLoose.js","../../../node_modules/react-transition-group/esm/config.js","../../../node_modules/react-transition-group/esm/utils/PropTypes.js","../../../node_modules/react-transition-group/esm/TransitionGroupContext.js","../../../node_modules/react-transition-group/esm/utils/reflow.js","../../../node_modules/react-transition-group/esm/Transition.js","../../../node_modules/@mui/material/transitions/utils.js","../../../node_modules/@mui/material/Grow/Grow.js","../../../node_modules/@mui/material/Popper/Popper.js","../../../node_modules/@mui/material/Tooltip/tooltipClasses.js","../../../node_modules/@mui/material/Tooltip/Tooltip.js","../src/components/mui/menu-item.component.tsx","../src/components/mui/grouped-menu-item-list.component.tsx","../src/components/mui/top-level-menu.component.tsx","../src/components/mui/grid-menu.component.tsx","../src/hooks/use-promise.hook.ts","../../../node_modules/@mui/icons-material/esm/Menu.js","../src/components/mui/hamburger-menu-button.component.tsx","../src/components/mui/icon-button.component.tsx","../src/components/basics/spinner.component.tsx","../src/components/basics/text-field.component.tsx","../src/components/mui/toolbar.component.tsx","../src/components/shadcn-ui/alert.tsx","../src/components/shadcn-ui/card.tsx","../src/components/shadcn-ui/sonner.tsx","../src/components/shadcn-ui/slider.tsx","../src/components/shadcn-ui/switch.tsx","../src/components/shadcn-ui/tabs.tsx","../src/components/advanced/extension-marketplace/buttons/install-button.component.tsx","../src/components/advanced/extension-marketplace/buttons/enable-button.component.tsx","../src/components/advanced/extension-marketplace/buttons/disable-button.component.tsx","../src/components/advanced/extension-marketplace/buttons/update-button.component.tsx","../src/components/advanced/extension-marketplace/markdown-renderer.component.tsx","../src/components/advanced/extension-marketplace/buttons/filter-button.component.tsx","../src/components/advanced/extension-marketplace/filter-dropdown.component.tsx","../src/components/advanced/extension-marketplace/no-extensions-found.component.tsx","../src/components/advanced/extension-marketplace/more-info.component.tsx","../src/components/advanced/extension-marketplace/version-history.component.tsx","../src/components/advanced/extension-marketplace/footer.component.tsx","../src/hooks/use-event.hook.ts","../src/hooks/use-event-async.hook.ts"],"sourcesContent":["import { type ClassValue, clsx } from 'clsx';\nimport { extendTailwindMerge } from 'tailwind-merge';\n\nconst twMergeCustom = extendTailwindMerge({ prefix: 'tw-' });\n\n/**\n * Tailwind and CSS class application helper function. Uses\n * [`clsx`](https://www.npmjs.com/package/clsx) to make it easy to apply classes conditionally using\n * object syntax, and uses [`tailwind-merge`](https://www.npmjs.com/package/tailwind-merge) to make\n * it easy to merge/overwrite Tailwind classes in a programmer-logic-friendly way.\n *\n * Note: `tailwind-merge` is configured to use the prefix `tw-`, so you must use the same prefix\n * with any Tailwind classes you use with this function to successfully overwrite other Tailwind\n * classes. `platform-bible-react` is configured to use `tw-` as its Tailwind prefix, so any\n * Tailwind classes you pass into `platform-bible-react` components will be compared using the `tw-`\n * prefix.\n *\n * This function was popularized by\n * [shadcn/ui](https://ui.shadcn.com/docs/installation/manual#add-a-cn-helper). See [ByteGrad's\n * explanation video](https://www.youtube.com/watch?v=re2JFITR7TI) for more information.\n *\n * @example\n *\n * ```typescript\n * const borderShouldBeBlue = true;\n * const textShouldBeRed = true;\n * const heightShouldBe20 = false;\n * const classString = cn(\n * 'tw-bg-primary tw-h-10 tw-text-primary-foreground',\n * 'tw-bg-secondary',\n * {\n * 'tw-border-blue-500': borderShouldBeBlue,\n * 'tw-text-red-500': textShouldBeRed,\n * 'tw-h-20': heightShouldBe20,\n * },\n * 'some-class',\n * );\n * ```\n *\n * The resulting `classString` is `'tw-h-10 tw-bg-secondary tw-border-blue-500 tw-text-red-500\n * some-class'`\n *\n * - Notice that `'tw-bg-secondary'`, specified later, overwrote `'tw-bg-primary'`, specified earlier,\n * because they are Tailwind classes that affect the same css property\n * - Notice that `'tw-text-red-500'`, specified later, overwrote `'tw-text-primary-foreground'`,\n * specified earlier, because they are Tailwind classes that affect the same css property\n * - Notice that `'tw-h-20'`, specified later, did not overwrite `'tw-h-10'`, specified earlier,\n * because `'tw-h-20'` is part of a conditional class object and its value evaluated to `false`;\n * therefore it was not applied\n * - Notice that `'some-class'` was applied. This function is not limited only to Tailwind classes.\n *\n *\n * @param inputs Class strings or `clsx` conditional class objects to merge. Tailwind classes\n * specified later in the arguments overwrite similar Tailwind classes specified earlier in the\n * arguments\n * @returns Class string containing all applicable classes from the arguments based on the rules\n * described above\n */\n// shadcn/ui uses this export in its boilerplate code\n// eslint-disable-next-line import/prefer-default-export\nexport function cn(...inputs: ClassValue[]) {\n return twMergeCustom(clsx(inputs));\n}\n","import React from 'react';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport interface InputProps extends React.InputHTMLAttributes {}\n\nexport const Input = React.forwardRef(\n ({ className, type, ...props }, ref) => {\n return (\n \n );\n },\n);\nInput.displayName = 'Input';\n","import { FocusEventHandler, forwardRef, KeyboardEvent, MouseEventHandler } from 'react';\nimport { History } from 'lucide-react';\nimport { Input as ShadInput } from '@/components/shadcn-ui/input';\n\nexport type BookChapterInputProps = {\n handleSearch: (searchString: string) => void;\n handleKeyDown: (event: KeyboardEvent) => void;\n handleOnClick: MouseEventHandler;\n handleSubmit: () => void;\n onFocus?: FocusEventHandler;\n value: string;\n placeholder: string;\n};\n\n// Shadcn Input sets type to \"button\"- HAVE to prop spread before setting type\nconst BookChapterInput = forwardRef(\n (\n { handleSearch, handleKeyDown, handleOnClick, handleSubmit, ...props }: BookChapterInputProps,\n ref,\n ) => {\n return (\n
    \n handleSearch(event.target.value)}\n onKeyDown={(e) => {\n if (e.key === 'Enter') {\n handleSubmit();\n }\n handleKeyDown(e);\n }}\n onClick={handleOnClick}\n ref={ref}\n />\n {\n // eslint-disable-next-line no-console\n console.log('back in history');\n }}\n />\n
    \n );\n },\n);\n\nexport default BookChapterInput;\n","var P = Object.defineProperty;\nvar R = (t, e, s) => e in t ? P(t, e, { enumerable: !0, configurable: !0, writable: !0, value: s }) : t[e] = s;\nvar n = (t, e, s) => R(t, typeof e != \"symbol\" ? e + \"\" : e, s);\nclass _ {\n constructor() {\n n(this, \"books\");\n n(this, \"firstSelectedBookNum\");\n n(this, \"lastSelectedBookNum\");\n n(this, \"count\");\n n(this, \"selectedBookNumbers\");\n n(this, \"selectedBookIds\");\n }\n}\nconst N = [\n \"GEN\",\n \"EXO\",\n \"LEV\",\n \"NUM\",\n \"DEU\",\n \"JOS\",\n \"JDG\",\n \"RUT\",\n \"1SA\",\n \"2SA\",\n // 10\n \"1KI\",\n \"2KI\",\n \"1CH\",\n \"2CH\",\n \"EZR\",\n \"NEH\",\n \"EST\",\n \"JOB\",\n \"PSA\",\n \"PRO\",\n // 20\n \"ECC\",\n \"SNG\",\n \"ISA\",\n \"JER\",\n \"LAM\",\n \"EZK\",\n \"DAN\",\n \"HOS\",\n \"JOL\",\n \"AMO\",\n // 30\n \"OBA\",\n \"JON\",\n \"MIC\",\n \"NAM\",\n \"HAB\",\n \"ZEP\",\n \"HAG\",\n \"ZEC\",\n \"MAL\",\n \"MAT\",\n // 40\n \"MRK\",\n \"LUK\",\n \"JHN\",\n \"ACT\",\n \"ROM\",\n \"1CO\",\n \"2CO\",\n \"GAL\",\n \"EPH\",\n \"PHP\",\n // 50\n \"COL\",\n \"1TH\",\n \"2TH\",\n \"1TI\",\n \"2TI\",\n \"TIT\",\n \"PHM\",\n \"HEB\",\n \"JAS\",\n \"1PE\",\n // 60\n \"2PE\",\n \"1JN\",\n \"2JN\",\n \"3JN\",\n \"JUD\",\n \"REV\",\n \"TOB\",\n \"JDT\",\n \"ESG\",\n \"WIS\",\n // 70\n \"SIR\",\n \"BAR\",\n \"LJE\",\n \"S3Y\",\n \"SUS\",\n \"BEL\",\n \"1MA\",\n \"2MA\",\n \"3MA\",\n \"4MA\",\n // 80\n \"1ES\",\n \"2ES\",\n \"MAN\",\n \"PS2\",\n \"ODA\",\n \"PSS\",\n \"JSA\",\n // actual variant text for JOS, now in LXA text\n \"JDB\",\n // actual variant text for JDG, now in LXA text\n \"TBS\",\n // actual variant text for TOB, now in LXA text\n \"SST\",\n // actual variant text for SUS, now in LXA text // 90\n \"DNT\",\n // actual variant text for DAN, now in LXA text\n \"BLT\",\n // actual variant text for BEL, now in LXA text\n \"XXA\",\n \"XXB\",\n \"XXC\",\n \"XXD\",\n \"XXE\",\n \"XXF\",\n \"XXG\",\n \"FRT\",\n // 100\n \"BAK\",\n \"OTH\",\n \"3ES\",\n // Used previously but really should be 2ES\n \"EZA\",\n // Used to be called 4ES, but not actually in any known project\n \"5EZ\",\n // Used to be called 5ES, but not actually in any known project\n \"6EZ\",\n // Used to be called 6ES, but not actually in any known project\n \"INT\",\n \"CNC\",\n \"GLO\",\n \"TDX\",\n // 110\n \"NDX\",\n \"DAG\",\n \"PS3\",\n \"2BA\",\n \"LBA\",\n \"JUB\",\n \"ENO\",\n \"1MQ\",\n \"2MQ\",\n \"3MQ\",\n // 120\n \"REP\",\n \"4BA\",\n \"LAO\"\n], B = [\n \"XXA\",\n \"XXB\",\n \"XXC\",\n \"XXD\",\n \"XXE\",\n \"XXF\",\n \"XXG\",\n \"FRT\",\n \"BAK\",\n \"OTH\",\n \"INT\",\n \"CNC\",\n \"GLO\",\n \"TDX\",\n \"NDX\"\n], O = [\n \"Genesis\",\n \"Exodus\",\n \"Leviticus\",\n \"Numbers\",\n \"Deuteronomy\",\n \"Joshua\",\n \"Judges\",\n \"Ruth\",\n \"1 Samuel\",\n \"2 Samuel\",\n \"1 Kings\",\n \"2 Kings\",\n \"1 Chronicles\",\n \"2 Chronicles\",\n \"Ezra\",\n \"Nehemiah\",\n \"Esther (Hebrew)\",\n \"Job\",\n \"Psalms\",\n \"Proverbs\",\n \"Ecclesiastes\",\n \"Song of Songs\",\n \"Isaiah\",\n \"Jeremiah\",\n \"Lamentations\",\n \"Ezekiel\",\n \"Daniel (Hebrew)\",\n \"Hosea\",\n \"Joel\",\n \"Amos\",\n \"Obadiah\",\n \"Jonah\",\n \"Micah\",\n \"Nahum\",\n \"Habakkuk\",\n \"Zephaniah\",\n \"Haggai\",\n \"Zechariah\",\n \"Malachi\",\n \"Matthew\",\n \"Mark\",\n \"Luke\",\n \"John\",\n \"Acts\",\n \"Romans\",\n \"1 Corinthians\",\n \"2 Corinthians\",\n \"Galatians\",\n \"Ephesians\",\n \"Philippians\",\n \"Colossians\",\n \"1 Thessalonians\",\n \"2 Thessalonians\",\n \"1 Timothy\",\n \"2 Timothy\",\n \"Titus\",\n \"Philemon\",\n \"Hebrews\",\n \"James\",\n \"1 Peter\",\n \"2 Peter\",\n \"1 John\",\n \"2 John\",\n \"3 John\",\n \"Jude\",\n \"Revelation\",\n \"Tobit\",\n \"Judith\",\n \"Esther Greek\",\n \"Wisdom of Solomon\",\n \"Sirach (Ecclesiasticus)\",\n \"Baruch\",\n \"Letter of Jeremiah\",\n \"Song of 3 Young Men\",\n \"Susanna\",\n \"Bel and the Dragon\",\n \"1 Maccabees\",\n \"2 Maccabees\",\n \"3 Maccabees\",\n \"4 Maccabees\",\n \"1 Esdras (Greek)\",\n \"2 Esdras (Latin)\",\n \"Prayer of Manasseh\",\n \"Psalm 151\",\n \"Odes\",\n \"Psalms of Solomon\",\n // WARNING, if you change the spelling of the *obsolete* tag be sure to update\n // IsObsolete routine\n \"Joshua A. *obsolete*\",\n \"Judges B. *obsolete*\",\n \"Tobit S. *obsolete*\",\n \"Susanna Th. *obsolete*\",\n \"Daniel Th. *obsolete*\",\n \"Bel Th. *obsolete*\",\n \"Extra A\",\n \"Extra B\",\n \"Extra C\",\n \"Extra D\",\n \"Extra E\",\n \"Extra F\",\n \"Extra G\",\n \"Front Matter\",\n \"Back Matter\",\n \"Other Matter\",\n \"3 Ezra *obsolete*\",\n \"Apocalypse of Ezra\",\n \"5 Ezra (Latin Prologue)\",\n \"6 Ezra (Latin Epilogue)\",\n \"Introduction\",\n \"Concordance \",\n \"Glossary \",\n \"Topical Index\",\n \"Names Index\",\n \"Daniel Greek\",\n \"Psalms 152-155\",\n \"2 Baruch (Apocalypse)\",\n \"Letter of Baruch\",\n \"Jubilees\",\n \"Enoch\",\n \"1 Meqabyan\",\n \"2 Meqabyan\",\n \"3 Meqabyan\",\n \"Reproof (Proverbs 25-31)\",\n \"4 Baruch (Rest of Baruch)\",\n \"Laodiceans\"\n], S = K();\nfunction g(t, e = !0) {\n return e && (t = t.toUpperCase()), t in S ? S[t] : 0;\n}\nfunction k(t) {\n return g(t) > 0;\n}\nfunction x(t) {\n const e = typeof t == \"string\" ? g(t) : t;\n return e >= 40 && e <= 66;\n}\nfunction T(t) {\n return (typeof t == \"string\" ? g(t) : t) <= 39;\n}\nfunction X(t) {\n return t <= 66;\n}\nfunction V(t) {\n const e = typeof t == \"string\" ? g(t) : t;\n return w(e) && !X(e);\n}\nfunction* L() {\n for (let t = 1; t <= N.length; t++) yield t;\n}\nconst G = 1, A = N.length;\nfunction H() {\n return [\"XXA\", \"XXB\", \"XXC\", \"XXD\", \"XXE\", \"XXF\", \"XXG\"];\n}\nfunction C(t, e = \"***\") {\n const s = t - 1;\n return s < 0 || s >= N.length ? e : N[s];\n}\nfunction I(t) {\n return t <= 0 || t > A ? \"******\" : O[t - 1];\n}\nfunction y(t) {\n return I(g(t));\n}\nfunction w(t) {\n const e = typeof t == \"number\" ? C(t) : t;\n return k(e) && !B.includes(e);\n}\nfunction q(t) {\n const e = typeof t == \"number\" ? C(t) : t;\n return k(e) && B.includes(e);\n}\nfunction U(t) {\n return O[t - 1].includes(\"*obsolete*\");\n}\nfunction K() {\n const t = {};\n for (let e = 0; e < N.length; e++)\n t[N[e]] = e + 1;\n return t;\n}\nconst m = {\n allBookIds: N,\n nonCanonicalIds: B,\n bookIdToNumber: g,\n isBookIdValid: k,\n isBookNT: x,\n isBookOT: T,\n isBookOTNT: X,\n isBookDC: V,\n allBookNumbers: L,\n firstBook: G,\n lastBook: A,\n extraBooks: H,\n bookNumberToId: C,\n bookNumberToEnglishName: I,\n bookIdToEnglishName: y,\n isCanonical: w,\n isExtraMaterial: q,\n isObsolete: U\n};\nvar l = /* @__PURE__ */ ((t) => (t[t.Unknown = 0] = \"Unknown\", t[t.Original = 1] = \"Original\", t[t.Septuagint = 2] = \"Septuagint\", t[t.Vulgate = 3] = \"Vulgate\", t[t.English = 4] = \"English\", t[t.RussianProtestant = 5] = \"RussianProtestant\", t[t.RussianOrthodox = 6] = \"RussianOrthodox\", t))(l || {});\nconst h = class h {\n // private versInfo: Versification;\n constructor(e) {\n n(this, \"name\");\n n(this, \"fullPath\");\n n(this, \"isPresent\");\n n(this, \"hasVerseSegments\");\n n(this, \"isCustomized\");\n n(this, \"baseVersification\");\n n(this, \"scriptureBooks\");\n n(this, \"_type\");\n if (e == null)\n throw new Error(\"Argument undefined\");\n typeof e == \"string\" ? (this.name = e, this._type = l[e]) : (this._type = e, this.name = l[e]);\n }\n get type() {\n return this._type;\n }\n equals(e) {\n return !e.type || !this.type ? !1 : e.type === this.type;\n }\n};\nn(h, \"Original\", new h(l.Original)), n(h, \"Septuagint\", new h(l.Septuagint)), n(h, \"Vulgate\", new h(l.Vulgate)), n(h, \"English\", new h(l.English)), n(h, \"RussianProtestant\", new h(l.RussianProtestant)), n(h, \"RussianOrthodox\", new h(l.RussianOrthodox));\nlet c = h;\nfunction E(t, e) {\n const s = e[0];\n for (let r = 1; r < e.length; r++)\n t = t.split(e[r]).join(s);\n return t.split(s);\n}\nvar D = /* @__PURE__ */ ((t) => (t[t.Valid = 0] = \"Valid\", t[t.UnknownVersification = 1] = \"UnknownVersification\", t[t.OutOfRange = 2] = \"OutOfRange\", t[t.VerseOutOfOrder = 3] = \"VerseOutOfOrder\", t[t.VerseRepeated = 4] = \"VerseRepeated\", t))(D || {});\nconst i = class i {\n constructor(e, s, r, a) {\n /** Not yet implemented. */\n n(this, \"firstChapter\");\n /** Not yet implemented. */\n n(this, \"lastChapter\");\n /** Not yet implemented. */\n n(this, \"lastVerse\");\n /** Not yet implemented. */\n n(this, \"hasSegmentsDefined\");\n /** Not yet implemented. */\n n(this, \"text\");\n /** Not yet implemented. */\n n(this, \"BBBCCCVVVS\");\n /** Not yet implemented. */\n n(this, \"longHashCode\");\n /** The versification of the reference. */\n n(this, \"versification\");\n n(this, \"rtlMark\", \"‏\");\n n(this, \"_bookNum\", 0);\n n(this, \"_chapterNum\", 0);\n n(this, \"_verseNum\", 0);\n n(this, \"_verse\");\n if (r == null && a == null)\n if (e != null && typeof e == \"string\") {\n const o = e, u = s != null && s instanceof c ? s : void 0;\n this.setEmpty(u), this.parse(o);\n } else if (e != null && typeof e == \"number\") {\n const o = s != null && s instanceof c ? s : void 0;\n this.setEmpty(o), this._verseNum = e % i.chapterDigitShifter, this._chapterNum = Math.floor(\n e % i.bookDigitShifter / i.chapterDigitShifter\n ), this._bookNum = Math.floor(e / i.bookDigitShifter);\n } else if (s == null)\n if (e != null && e instanceof i) {\n const o = e;\n this._bookNum = o.bookNum, this._chapterNum = o.chapterNum, this._verseNum = o.verseNum, this._verse = o.verse, this.versification = o.versification;\n } else {\n if (e == null) return;\n const o = e instanceof c ? e : i.defaultVersification;\n this.setEmpty(o);\n }\n else\n throw new Error(\"VerseRef constructor not supported.\");\n else if (e != null && s != null && r != null)\n if (typeof e == \"string\" && typeof s == \"string\" && typeof r == \"string\")\n this.setEmpty(a), this.updateInternal(e, s, r);\n else if (typeof e == \"number\" && typeof s == \"number\" && typeof r == \"number\")\n this._bookNum = e, this._chapterNum = s, this._verseNum = r, this.versification = a ?? i.defaultVersification;\n else\n throw new Error(\"VerseRef constructor not supported.\");\n else\n throw new Error(\"VerseRef constructor not supported.\");\n }\n /**\n * Determines if the verse string is in a valid format (does not consider versification).\n */\n static isVerseParseable(e) {\n return e.length > 0 && \"0123456789\".includes(e[0]) && !e.endsWith(this.verseRangeSeparator) && !e.endsWith(this.verseSequenceIndicator);\n }\n /**\n * Tries to parse the specified string into a verse reference.\n * @param str - The string to attempt to parse.\n * @returns success: `true` if the specified string was successfully parsed, `false` otherwise.\n * @returns verseRef: The result of the parse if successful, or empty VerseRef if it failed\n */\n static tryParse(e) {\n let s;\n try {\n return s = new i(e), { success: !0, verseRef: s };\n } catch (r) {\n if (r instanceof v)\n return s = new i(), { success: !1, verseRef: s };\n throw r;\n }\n }\n /**\n * Gets the reference as a comparable integer where the book, chapter, and verse each occupy 3\n * digits.\n * @param bookNum - Book number (this is 1-based, not an index).\n * @param chapterNum - Chapter number.\n * @param verseNum - Verse number.\n * @returns The reference as a comparable integer where the book, chapter, and verse each occupy 3\n * digits.\n */\n static getBBBCCCVVV(e, s, r) {\n return e % i.bcvMaxValue * i.bookDigitShifter + (s >= 0 ? s % i.bcvMaxValue * i.chapterDigitShifter : 0) + (r >= 0 ? r % i.bcvMaxValue : 0);\n }\n /**\n * Deserializes a serialized VerseRef.\n * @param serializedVerseRef - Serialized VerseRef to create from.\n * @returns the deserialized VerseRef.\n */\n static fromJSON(e) {\n const { book: s, chapterNum: r, verseNum: a, verse: o, versificationStr: u } = e, f = o || a.toString();\n let d;\n return u && (d = new c(u)), s ? new i(s, r.toString(), f, d) : new i();\n }\n /**\n * Parses a verse string and gets the leading numeric portion as a number.\n * @param verseStr - verse string to parse\n * @returns true if the entire string could be parsed as a single, simple verse number (1-999);\n * false if the verse string represented a verse bridge, contained segment letters, or was invalid\n */\n static tryGetVerseNum(e) {\n let s;\n if (!e)\n return s = -1, { success: !0, vNum: s };\n s = 0;\n let r;\n for (let a = 0; a < e.length; a++) {\n if (r = e[a], r < \"0\" || r > \"9\")\n return a === 0 && (s = -1), { success: !1, vNum: s };\n if (s = s * 10 + +r - 0, s > i.bcvMaxValue)\n return s = -1, { success: !1, vNum: s };\n }\n return { success: !0, vNum: s };\n }\n /**\n * Checks to see if a VerseRef hasn't been set - all values are the default.\n */\n get isDefault() {\n return this.bookNum === 0 && this.chapterNum === 0 && this.verseNum === 0 && this.versification == null;\n }\n /**\n * Gets whether the verse contains multiple verses.\n */\n get hasMultiple() {\n return this._verse != null && (this._verse.includes(i.verseRangeSeparator) || this._verse.includes(i.verseSequenceIndicator));\n }\n /**\n * Gets or sets the book of the reference. Book is the 3-letter abbreviation in capital letters,\n * e.g. `'MAT'`.\n */\n get book() {\n return m.bookNumberToId(this.bookNum, \"\");\n }\n set book(e) {\n this.bookNum = m.bookIdToNumber(e);\n }\n /**\n * Gets or sets the chapter of the reference,. e.g. `'3'`.\n */\n get chapter() {\n return this.isDefault || this._chapterNum < 0 ? \"\" : this._chapterNum.toString();\n }\n set chapter(e) {\n const s = +e;\n this._chapterNum = Number.isInteger(s) ? s : -1;\n }\n /**\n * Gets or sets the verse of the reference, including range, segments, and sequences, e.g. `'4'`,\n * or `'4b-5a, 7'`.\n */\n get verse() {\n return this._verse != null ? this._verse : this.isDefault || this._verseNum < 0 ? \"\" : this._verseNum.toString();\n }\n set verse(e) {\n const { success: s, vNum: r } = i.tryGetVerseNum(e);\n this._verse = s ? void 0 : e.replace(this.rtlMark, \"\"), this._verseNum = r, !(this._verseNum >= 0) && ({ vNum: this._verseNum } = i.tryGetVerseNum(this._verse));\n }\n /**\n * Get or set Book based on book number, e.g. `42`.\n */\n get bookNum() {\n return this._bookNum;\n }\n set bookNum(e) {\n if (e <= 0 || e > m.lastBook)\n throw new v(\n \"BookNum must be greater than zero and less than or equal to last book\"\n );\n this._bookNum = e;\n }\n /**\n * Gets or sets the chapter number, e.g. `3`. `-1` if not valid.\n */\n get chapterNum() {\n return this._chapterNum;\n }\n set chapterNum(e) {\n this.chapterNum = e;\n }\n /**\n * Gets or sets verse start number, e.g. `4`. `-1` if not valid.\n */\n get verseNum() {\n return this._verseNum;\n }\n set verseNum(e) {\n this._verseNum = e;\n }\n /**\n * String representing the versification (should ONLY be used for serialization/deserialization).\n *\n * @remarks This is for backwards compatibility when ScrVers was an enumeration.\n */\n get versificationStr() {\n var e;\n return (e = this.versification) == null ? void 0 : e.name;\n }\n set versificationStr(e) {\n this.versification = this.versification != null ? new c(e) : void 0;\n }\n /**\n * Determines if the reference is valid.\n */\n get valid() {\n return this.validStatus === 0;\n }\n /**\n * Get the valid status for this reference.\n */\n get validStatus() {\n return this.validateVerse(i.verseRangeSeparators, i.verseSequenceIndicators);\n }\n /**\n * Gets the reference as a comparable integer where the book,\n * chapter, and verse each occupy three digits and the verse is 0.\n */\n get BBBCCC() {\n return i.getBBBCCCVVV(this._bookNum, this._chapterNum, 0);\n }\n /**\n * Gets the reference as a comparable integer where the book,\n * chapter, and verse each occupy three digits. If verse is not null\n * (i.e., this reference represents a complex reference with verse\n * segments or bridge) this cannot be used for an exact comparison.\n */\n get BBBCCCVVV() {\n return i.getBBBCCCVVV(this._bookNum, this._chapterNum, this._verseNum);\n }\n /**\n * Gets whether the verse is defined as an excluded verse in the versification.\n * Does not handle verse ranges.\n */\n // eslint-disable-next-line @typescript-eslint/class-literal-property-style\n get isExcluded() {\n return !1;\n }\n /**\n * Parses the reference in the specified string.\n * Optionally versification can follow reference as in GEN 3:11/4\n * Throw an exception if\n * - invalid book name\n * - chapter number is missing or not a number\n * - verse number is missing or does not start with a number\n * - versification is invalid\n * @param verseStr - string to parse e.g. 'MAT 3:11'\n */\n parse(e) {\n if (e = e.replace(this.rtlMark, \"\"), e.includes(\"/\")) {\n const o = e.split(\"/\");\n if (e = o[0], o.length > 1)\n try {\n const u = +o[1].trim();\n this.versification = new c(l[u]);\n } catch {\n throw new v(\"Invalid reference : \" + e);\n }\n }\n const s = e.trim().split(\" \");\n if (s.length !== 2)\n throw new v(\"Invalid reference : \" + e);\n const r = s[1].split(\":\"), a = +r[0];\n if (r.length !== 2 || m.bookIdToNumber(s[0]) === 0 || !Number.isInteger(a) || a < 0 || !i.isVerseParseable(r[1]))\n throw new v(\"Invalid reference : \" + e);\n this.updateInternal(s[0], r[0], r[1]);\n }\n /**\n * Simplifies this verse ref so that it has no bridging of verses or\n * verse segments like `'1a'`.\n */\n simplify() {\n this._verse = void 0;\n }\n /**\n * Makes a clone of the reference.\n *\n * @returns The cloned VerseRef.\n */\n clone() {\n return new i(this);\n }\n toString() {\n const e = this.book;\n return e === \"\" ? \"\" : `${e} ${this.chapter}:${this.verse}`;\n }\n toJSON() {\n let e = this.verse;\n (e === \"\" || e === this.verseNum.toString()) && (e = void 0);\n const s = {\n book: this.book,\n chapterNum: this.chapterNum,\n verseNum: this.verseNum,\n verse: e,\n versificationStr: this.versificationStr\n };\n return e || delete s.verse, s;\n }\n /**\n * Compares this `VerseRef` with supplied one.\n * @param verseRef - object to compare this one to.\n * @returns `true` if this `VerseRef` is equal to the supplied one, `false` otherwise.\n */\n equals(e) {\n return e instanceof i ? e._bookNum === this._bookNum && e._chapterNum === this._chapterNum && e._verseNum === this._verseNum && e.verse === this.verse && (e.versification == null && this.versification == null || e.versification != null && this.versification != null && e.versification.equals(this.versification)) : !1;\n }\n /**\n * Enumerate all individual verses contained in a VerseRef.\n * Verse ranges are indicated by \"-\" and consecutive verses by \",\"s.\n * Examples:\n * GEN 1:2 returns GEN 1:2\n * GEN 1:1a-3b,5 returns GEN 1:1a, GEN 1:2, GEN 1:3b, GEN 1:5\n * GEN 1:2a-2c returns //! ??????\n *\n * @param specifiedVersesOnly - if set to true return only verses that are\n * explicitly specified only, not verses within a range. Defaults to `false`.\n * @param verseRangeSeparators - Verse range separators.\n * Defaults to `VerseRef.verseRangeSeparators`.\n * @param verseSequenceSeparators - Verse sequence separators.\n * Defaults to `VerseRef.verseSequenceIndicators`.\n * @returns An array of all single verse references in this VerseRef.\n */\n allVerses(e = !1, s = i.verseRangeSeparators, r = i.verseSequenceIndicators) {\n if (this._verse == null || this.chapterNum <= 0)\n return [this.clone()];\n const a = [], o = E(this._verse, r);\n for (const u of o.map((f) => E(f, s))) {\n const f = this.clone();\n f.verse = u[0];\n const d = f.verseNum;\n if (a.push(f), u.length > 1) {\n const b = this.clone();\n if (b.verse = u[1], !e)\n for (let p = d + 1; p < b.verseNum; p++) {\n const J = new i(\n this._bookNum,\n this._chapterNum,\n p,\n this.versification\n );\n this.isExcluded || a.push(J);\n }\n a.push(b);\n }\n }\n return a;\n }\n /**\n * Validates a verse number using the supplied separators rather than the defaults.\n */\n validateVerse(e, s) {\n if (!this.verse)\n return this.internalValid;\n let r = 0;\n for (const a of this.allVerses(!0, e, s)) {\n const o = a.internalValid;\n if (o !== 0)\n return o;\n const u = a.BBBCCCVVV;\n if (r > u)\n return 3;\n if (r === u)\n return 4;\n r = u;\n }\n return 0;\n }\n /**\n * Gets whether a single verse reference is valid.\n */\n get internalValid() {\n return this.versification == null ? 1 : this._bookNum <= 0 || this._bookNum > m.lastBook ? 2 : (m.isCanonical(this._bookNum), 0);\n }\n setEmpty(e = i.defaultVersification) {\n this._bookNum = 0, this._chapterNum = -1, this._verse = void 0, this.versification = e;\n }\n updateInternal(e, s, r) {\n this.bookNum = m.bookIdToNumber(e), this.chapter = s, this.verse = r;\n }\n};\nn(i, \"defaultVersification\", c.English), n(i, \"verseRangeSeparator\", \"-\"), n(i, \"verseSequenceIndicator\", \",\"), n(i, \"verseRangeSeparators\", [i.verseRangeSeparator]), n(i, \"verseSequenceIndicators\", [i.verseSequenceIndicator]), n(i, \"chapterDigitShifter\", 1e3), n(i, \"bookDigitShifter\", i.chapterDigitShifter * i.chapterDigitShifter), n(i, \"bcvMaxValue\", i.chapterDigitShifter - 1), /**\n * The valid status of the VerseRef.\n */\nn(i, \"ValidStatusType\", D);\nlet M = i;\nclass v extends Error {\n}\nexport {\n _ as BookSet,\n m as Canon,\n c as ScrVers,\n l as ScrVersType,\n M as VerseRef,\n v as VerseRefException\n};\n//# sourceMappingURL=index.es.js.map\n","import React from 'react';\nimport * as DropdownMenuPrimitive from '@radix-ui/react-dropdown-menu';\nimport { Check, ChevronRight, Circle } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport const DropdownMenu = DropdownMenuPrimitive.Root;\n\nexport const DropdownMenuTrigger = DropdownMenuPrimitive.Trigger;\n\nexport const DropdownMenuGroup = DropdownMenuPrimitive.Group;\n\nexport const DropdownMenuPortal = DropdownMenuPrimitive.Portal;\n\nexport const DropdownMenuSub = DropdownMenuPrimitive.Sub;\n\nexport const DropdownMenuRadioGroup = DropdownMenuPrimitive.RadioGroup;\n\nexport type DropdownMenuSubTriggerProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.SubTrigger\n> & {\n className?: string;\n inset?: boolean;\n};\n\nexport type DropdownMenuSubContentProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.SubContent\n> & {\n className?: string;\n};\n\nexport type DropdownMenuContentProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Content\n> & {\n className?: string;\n sideOffset?: number;\n};\n\nexport type DropdownMenuItemProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Item\n> & {\n className?: string;\n inset?: boolean;\n};\n\nexport type DropdownMenuCheckboxItemProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.CheckboxItem\n> & {\n className?: string;\n checked?: boolean;\n};\n\nexport type DropdownMenuRadioItemProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.RadioItem\n> & {\n className?: string;\n};\n\nexport type DropdownMenuLabelProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Label\n> & {\n className?: string;\n inset?: boolean;\n};\n\nexport type DropdownMenuSeparatorProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Separator\n> & {\n className?: string;\n};\n\nexport type DropdownMenuShortcutProps = React.HTMLAttributes & {\n className?: string;\n};\n\nexport const DropdownMenuSubTrigger = React.forwardRef<\n React.ElementRef,\n DropdownMenuSubTriggerProps\n>(({ className, inset, children, ...props }, ref) => (\n \n {children}\n \n \n));\nDropdownMenuSubTrigger.displayName = DropdownMenuPrimitive.SubTrigger.displayName;\n\nexport const DropdownMenuSubContent = React.forwardRef<\n React.ElementRef,\n DropdownMenuSubContentProps\n>(({ className, ...props }, ref) => (\n \n));\nDropdownMenuSubContent.displayName = DropdownMenuPrimitive.SubContent.displayName;\n\nexport const DropdownMenuContent = React.forwardRef<\n React.ElementRef,\n DropdownMenuContentProps\n>(({ className, sideOffset = 4, ...props }, ref) => (\n \n \n \n));\nDropdownMenuContent.displayName = DropdownMenuPrimitive.Content.displayName;\n\n/**\n * TODO: fix: direction is not automatically handled by this component, so that shortcuts are\n * display always to the right\n */\nexport const DropdownMenuItem = React.forwardRef<\n React.ElementRef,\n DropdownMenuItemProps\n>(({ className, inset, ...props }, ref) => (\n \n));\nDropdownMenuItem.displayName = DropdownMenuPrimitive.Item.displayName;\n\nexport const DropdownMenuCheckboxItem = React.forwardRef<\n React.ElementRef,\n DropdownMenuCheckboxItemProps\n>(({ className, children, checked, ...props }, ref) => (\n \n \n \n \n \n \n {children}\n \n));\nDropdownMenuCheckboxItem.displayName = DropdownMenuPrimitive.CheckboxItem.displayName;\n\nexport const DropdownMenuRadioItem = React.forwardRef<\n React.ElementRef,\n DropdownMenuRadioItemProps\n>(({ className, children, ...props }, ref) => (\n \n \n \n \n \n \n {children}\n \n));\nDropdownMenuRadioItem.displayName = DropdownMenuPrimitive.RadioItem.displayName;\n\nexport const DropdownMenuLabel = React.forwardRef<\n React.ElementRef,\n DropdownMenuLabelProps\n>(({ className, inset, ...props }, ref) => (\n \n));\nDropdownMenuLabel.displayName = DropdownMenuPrimitive.Label.displayName;\n\nexport const DropdownMenuSeparator = React.forwardRef<\n React.ElementRef,\n DropdownMenuSeparatorProps\n>(({ className, ...props }, ref) => (\n \n));\nDropdownMenuSeparator.displayName = DropdownMenuPrimitive.Separator.displayName;\n\nexport function DropdownMenuShortcut({ className, ...props }: DropdownMenuShortcutProps) {\n return (\n \n );\n}\nDropdownMenuShortcut.displayName = 'DropdownMenuShortcut';\n","import { Canon } from '@sillsdev/scripture';\nimport { PropsWithChildren, KeyboardEvent, forwardRef } from 'react';\nimport { DropdownMenuItem as ShadDropdownMenuItem } from '@/components/shadcn-ui/dropdown-menu';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport type BookType = 'OT' | 'NT' | 'DC';\n\ntype BookMenuItemProps = PropsWithChildren<{\n /** String id of book */\n bookId: string;\n /** Callback to run when a book menu item is selected */\n handleSelectBook: () => void;\n /** Indicates if this menu item is currently selected */\n isSelected: boolean;\n /** Function that is called upon highlighting a book in the dropdown menu */\n handleHighlightBook: () => void;\n /**\n * Function that is called on pressing a key\n *\n * @param event Event that contains information about the key stroke\n */\n handleKeyDown: (event: KeyboardEvent) => void;\n /**\n * Type of book associated with this menu item, coordinates color labels ? Mock up has the labels\n * coordinated to genre\n */\n bookType: BookType;\n}>;\n\nconst BookMenuItem = forwardRef(\n (\n {\n bookId,\n handleSelectBook,\n isSelected,\n handleHighlightBook,\n handleKeyDown,\n bookType,\n children,\n }: BookMenuItemProps,\n ref,\n ) => {\n return (\n {\n // preventDefault() here prevents the entire dropdown menu from closing when selecting this item\n event.preventDefault();\n handleSelectBook();\n }}\n onKeyDown={(event: KeyboardEvent) => {\n handleKeyDown(event);\n }}\n onFocus={handleHighlightBook}\n onMouseMove={handleHighlightBook}\n >\n \n {Canon.bookIdToEnglishName(bookId)}\n \n {isSelected &&
    {children}
    }\n \n );\n },\n);\n\nexport default BookMenuItem;\n","import { cn } from '@/utils/shadcn-ui.util';\nimport { useCallback } from 'react';\n\nexport type ChapterSelectProps = {\n /**\n * Callback to run when a chapter div is selected\n *\n * @param chapterNumber Number of the chapter that has been selected\n */\n handleSelectChapter: (chapterNumber: number) => void;\n /** The highest chapter number in the book (of course equal to number of chapters in the book) */\n endChapter: number;\n /** The chapter number that is currently selected */\n activeChapter: number;\n /** The chapter number that is currently highlighted using keyboard or mouse navigation */\n highlightedChapter: number;\n /**\n * Callback to run when a chapter is highlighted by the user\n *\n * @param chapterNumber The chapter that is highlighted\n */\n handleHighlightedChapter: (chapterNumber: number) => void;\n};\n\nfunction ChapterSelect({\n handleSelectChapter,\n endChapter,\n activeChapter,\n highlightedChapter,\n handleHighlightedChapter,\n}: ChapterSelectProps) {\n const chapters = Array.from({ length: endChapter }, (_, i) => i + 1);\n\n const handleMouse = useCallback(\n (chapterNumber: number) => {\n handleHighlightedChapter(chapterNumber);\n },\n [handleHighlightedChapter],\n );\n\n return (\n
    \n {chapters.map((chapter) => (\n {\n event.preventDefault();\n event.stopPropagation();\n handleSelectChapter(chapter);\n }}\n role=\"button\"\n onKeyDown={(event) => {\n if (event.key === 'Enter') {\n handleSelectChapter(chapter);\n }\n }}\n tabIndex={0}\n onMouseMove={() => handleMouse(chapter)}\n >\n {chapter}\n
    \n ))}\n
    \n );\n}\n\nexport default ChapterSelect;\n","import { DropdownMenuLabel as ShadDropdownMenuLabel } from '@/components/shadcn-ui/dropdown-menu';\nimport { Bookmark, Clock, ArrowDownWideNarrow } from 'lucide-react';\n\nexport type GoToMenuItemProps = {\n handleSort: () => void;\n handleLocationHistory: () => void;\n handleBookmarks: () => void;\n};\n\nfunction GoToMenuItem({ handleSort, handleLocationHistory, handleBookmarks }: GoToMenuItemProps) {\n return (\n \n

    Go To

    \n
    \n \n \n \n
    \n
    \n );\n}\n\nexport default GoToMenuItem;\n","import BookChapterInput from '@/components/advanced/book-chapter-control/book-chapter-input.component';\nimport BookMenuItem, {\n BookType,\n} from '@/components/advanced/book-chapter-control/book-menu-item.component';\nimport ChapterSelect from '@/components/advanced/book-chapter-control/chapter-select.component';\nimport GoToMenuItem from '@/components/advanced/book-chapter-control/go-to-menu-item.component';\nimport {\n DropdownMenu as ShadDropdownMenu,\n DropdownMenuContent as ShadDropdownMenuContent,\n DropdownMenuLabel as ShadDropdownMenuLabel,\n DropdownMenuSeparator as ShadDropdownMenuSeparator,\n DropdownMenuTrigger as ShadDropdownMenuTrigger,\n} from '@/components/shadcn-ui/dropdown-menu';\nimport { Canon } from '@sillsdev/scripture';\nimport { ScriptureReference, getChaptersForBook } from 'platform-bible-utils';\nimport {\n KeyboardEvent as ReactKeyboardEvent,\n useCallback,\n useEffect,\n useLayoutEffect,\n useRef,\n useState,\n} from 'react';\n\ntype BookTypeLabels = {\n [bookType in BookType]: string;\n};\ntype BookChapterControlProps = {\n scrRef: ScriptureReference;\n handleSubmit: (scrRef: ScriptureReference) => void;\n};\n\nconst ALL_BOOK_IDS = Canon.allBookIds;\nconst BOOK_TYPE_LABELS: BookTypeLabels = {\n OT: 'Old Testament',\n NT: 'New Testament',\n DC: 'Deuterocanon',\n};\nconst BOOK_TYPE_ARRAY: BookType[] = ['OT', 'NT', 'DC'];\n// This is the height of three menu items to offset scrolling to the selected menu item\n// If you use menuItemRef.clientHeight- includes height of chapter div which is too big\nconst SCROLL_OFFSET = 32 + 32 + 32;\nconst SEARCH_QUERY_FORMATS = [\n /^(\\w+)$/i, // Matches a single word (book name or id)\n /^(\\w+)(?:\\s(\\d+))$/i, // Matches a word followed by a chapter number\n /^(\\w+)(?:\\s(\\d+):(\\d+))$/i, // Matches a word followed by a chapter and verse number\n];\nconst fetchGroupedBooks = (bookType: BookType) => {\n const groupedBooks = {\n OT: ALL_BOOK_IDS.filter((bookId) => Canon.isBookOT(bookId)),\n NT: ALL_BOOK_IDS.filter((bookId) => Canon.isBookNT(bookId)),\n DC: ALL_BOOK_IDS.filter((bookId) => Canon.isBookDC(bookId)),\n };\n return groupedBooks[bookType];\n};\nconst fetchEndChapter = (bookId: string) => {\n // getChaptersForBook returns -1 if not found in scrBookData\n // scrBookData only includes OT and NT, so all DC will return -1\n return getChaptersForBook(Canon.bookIdToNumber(bookId));\n};\n\n/**\n * Gets all of the English names from book ids\n *\n * @returns String[]\n */\nfunction getAllEnglishNames(): string[] {\n const allEnglishNames = ALL_BOOK_IDS.map((bookId) => {\n return Canon.bookIdToEnglishName(bookId);\n });\n return allEnglishNames;\n}\n\n/**\n * Determines if bookName is in allEnglishNames\n *\n * @param bookName Book English name\n * @returns True if bookName is included, false otherwise\n */\nfunction isValidBookEnglishName(bookName: string): boolean {\n return getAllEnglishNames().includes(bookName);\n}\n\n/**\n * Gets a bookId from given English name\n *\n * @param bookName Book English name\n * @returns BookId of provided bookName, undefined otherwise\n */\nfunction getBookIdFromEnglishName(bookName: string): string | undefined {\n // Convert bookName to lowercase and then capitalize the first letter\n const formattedBookName = bookName.toLowerCase().replace(/^\\w/, (c) => c.toUpperCase());\n\n if (isValidBookEnglishName(formattedBookName)) {\n const matchingBookId = ALL_BOOK_IDS.find((bookId) => {\n return Canon.bookIdToEnglishName(bookId) === formattedBookName;\n });\n return matchingBookId;\n }\n\n return undefined;\n}\n\nfunction BookChapterControl({ scrRef, handleSubmit }: BookChapterControlProps) {\n const [searchQuery, setSearchQuery] = useState('');\n const [selectedBookId, setSelectedBookId] = useState(\n Canon.bookNumberToId(scrRef.bookNum),\n );\n const [highlightedChapter, setHighlightedChapter] = useState(scrRef.chapterNum ?? 0);\n const [highlightedBookId, setHighlightedBookId] = useState(\n Canon.bookNumberToId(scrRef.bookNum),\n );\n const [isContentOpen, setIsContentOpen] = useState(false);\n const [isContentOpenDelayed, setIsContentOpenDelayed] = useState(isContentOpen);\n\n // This ref will always be defined\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const inputRef = useRef(undefined!);\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const contentRef = useRef(undefined!);\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const menuItemRef = useRef(undefined!);\n\n const fetchFilteredBooks = useCallback(\n (bookType: BookType) => {\n return fetchGroupedBooks(bookType).filter((bookId: string) => {\n const englishNameLowerCase = Canon.bookIdToEnglishName(bookId).toLowerCase();\n const normalizedQuery = searchQuery.replace(/[^a-zA-Z]/g, '').toLowerCase();\n return (\n englishNameLowerCase.includes(normalizedQuery) || // Match book name\n bookId.toLowerCase().includes(normalizedQuery) // Match book ID\n );\n });\n },\n [searchQuery],\n );\n\n const handleSearchInput = (searchString: string) => {\n setSearchQuery(searchString);\n };\n\n /**\n * Whether to prevent radix's logic from closing the dropdown. This is important because radix\n * tries to close the dropdown when the input first focuses, and we don't want it to do that. But\n * we don't want to prevent the dropdown from closing when we click away from the input, so we\n * don't want to just keep it open if the input is focused\n */\n const shouldPreventAutoClosing = useRef(false);\n\n const controlMenuState = useCallback((open: boolean) => {\n if (shouldPreventAutoClosing.current) {\n shouldPreventAutoClosing.current = false;\n return;\n }\n setIsContentOpen(open);\n }, []);\n\n const updateReference = useCallback(\n (bookId: string, shouldClose: boolean, chapter?: number, verse?: number) => {\n setHighlightedChapter(\n Canon.bookNumberToId(scrRef.bookNum) !== bookId ? 1 : scrRef.chapterNum,\n );\n\n if (shouldClose || fetchEndChapter(bookId) === -1) {\n handleSubmit({\n bookNum: Canon.bookIdToNumber(bookId),\n chapterNum: chapter || 1,\n verseNum: verse || 1,\n });\n\n setIsContentOpen(false);\n setSearchQuery('');\n return;\n }\n\n setSelectedBookId(selectedBookId !== bookId ? bookId : '');\n setIsContentOpen(!shouldClose);\n },\n [handleSubmit, scrRef.bookNum, scrRef.chapterNum, selectedBookId],\n );\n\n const handleSelectChapter = (chapterNumber: number) => {\n if (chapterNumber <= 0 || chapterNumber > fetchEndChapter(selectedBookId)) {\n return;\n }\n updateReference(selectedBookId, true, chapterNumber);\n };\n\n const handleInputSubmit = useCallback(() => {\n SEARCH_QUERY_FORMATS.forEach((format) => {\n const matches = searchQuery.match(format);\n if (matches) {\n // Book should be a bookId or an english name\n const [book, chapter = undefined, verse = undefined] = matches.slice(1);\n const englishName = getBookIdFromEnglishName(book);\n\n if (Canon.isBookIdValid(book) || englishName) {\n updateReference(\n englishName ?? book,\n true,\n chapter ? parseInt(chapter, 10) : 1,\n verse ? parseInt(verse, 10) : 1,\n );\n }\n }\n });\n }, [updateReference, searchQuery]);\n\n const handleKeyDownInput = useCallback(\n (event: ReactKeyboardEvent) => {\n if (!isContentOpen) {\n setIsContentOpen(true);\n } else if (event.key === 'ArrowDown' || event.key === 'ArrowUp') {\n if (\n typeof menuItemRef !== 'undefined' &&\n // Ref uses null\n // eslint-disable-next-line no-null/no-null\n menuItemRef.current !== null\n ) {\n menuItemRef.current.focus();\n } else if (\n typeof contentRef !== 'undefined' &&\n // Ref uses null\n // eslint-disable-next-line no-null/no-null\n contentRef.current !== null\n ) {\n contentRef.current.focus();\n }\n event.preventDefault();\n }\n },\n [isContentOpen],\n );\n\n const handleKeyDownContent = (event: ReactKeyboardEvent) => {\n // When the dropdown menu has focus, key strokes should give focus to the input component,\n // unless they're navigation keys (arrows and enter)\n const { key } = event;\n if (\n key === 'ArrowRight' ||\n key === 'ArrowLeft' ||\n key === 'ArrowDown' ||\n key === 'ArrowUp' ||\n key === 'Enter'\n ) {\n return;\n }\n\n inputRef.current.dispatchEvent(new KeyboardEvent('keydown', { key }));\n inputRef.current.focus();\n };\n\n const handleKeyDownMenuItem = (event: ReactKeyboardEvent) => {\n const { key } = event;\n if (highlightedBookId === selectedBookId) {\n if (key === 'Enter') {\n event.preventDefault();\n updateReference(selectedBookId, true, highlightedChapter);\n return;\n }\n\n let chapterOffSet = 0;\n if (key === 'ArrowRight') {\n if (highlightedChapter < fetchEndChapter(highlightedBookId)) {\n chapterOffSet = 1;\n } else {\n event.preventDefault();\n return;\n }\n } else if (key === 'ArrowLeft') {\n if (highlightedChapter > 1) {\n chapterOffSet = -1;\n } else {\n event.preventDefault();\n return;\n }\n } else if (key === 'ArrowDown') {\n chapterOffSet = 6;\n } else if (key === 'ArrowUp') {\n chapterOffSet = -6;\n }\n if (\n highlightedChapter + chapterOffSet <= 0 ||\n highlightedChapter + chapterOffSet > fetchEndChapter(highlightedBookId)\n ) {\n setHighlightedChapter(0);\n } else if (chapterOffSet !== 0) {\n setHighlightedChapter(highlightedChapter + chapterOffSet);\n event.preventDefault();\n }\n }\n };\n\n useEffect(() => {\n if (selectedBookId === highlightedBookId) {\n if (selectedBookId === Canon.bookNumberToId(scrRef.bookNum)) {\n setHighlightedChapter(scrRef.chapterNum);\n } else {\n setHighlightedChapter(1);\n }\n } else {\n setHighlightedChapter(0);\n }\n }, [highlightedBookId, scrRef.bookNum, scrRef.chapterNum, selectedBookId]);\n\n // The purpose of these useLayoutEffects and timeout is to delay the scroll just\n // enough so that the refs are defined and available when they are used after the timeout\n useLayoutEffect(() => {\n setIsContentOpenDelayed(isContentOpen);\n }, [isContentOpen]);\n\n useLayoutEffect(() => {\n const scrollTimeout = setTimeout(() => {\n if (isContentOpenDelayed && contentRef.current && menuItemRef.current) {\n const menuItemOffsetTop = menuItemRef.current.offsetTop;\n const scrollPosition = menuItemOffsetTop - SCROLL_OFFSET;\n contentRef.current.scrollTo({ top: scrollPosition, behavior: 'instant' });\n }\n }, 10);\n return () => {\n clearTimeout(scrollTimeout);\n };\n }, [isContentOpenDelayed]);\n\n return (\n
    \n \n \n {\n setSelectedBookId(Canon.bookNumberToId(scrRef.bookNum));\n setHighlightedBookId(Canon.bookNumberToId(scrRef.bookNum));\n setHighlightedChapter(scrRef.chapterNum > 0 ? scrRef.chapterNum : 0);\n setIsContentOpen(true);\n inputRef.current.focus();\n }}\n onFocus={() => {\n // Radix thinks we want to close because the input is being focused. Prevent that\n shouldPreventAutoClosing.current = true;\n }}\n handleSubmit={handleInputSubmit}\n placeholder={`${Canon.bookNumberToEnglishName(scrRef.bookNum)} ${scrRef.chapterNum}:${scrRef.verseNum}`}\n />\n \n \n console.log('sorting')}\n handleLocationHistory={() => console.log('location history')}\n handleBookmarks={() => console.log('bookmarks')}\n />\n {BOOK_TYPE_ARRAY.map(\n (bookType, bookTypeIndex) =>\n fetchFilteredBooks(bookType).length > 0 && (\n
    \n \n {BOOK_TYPE_LABELS[bookType]}\n \n\n {fetchFilteredBooks(bookType).map((bookId) => (\n
    \n updateReference(bookId, false)}\n isSelected={selectedBookId === bookId}\n handleHighlightBook={() => setHighlightedBookId(bookId)}\n handleKeyDown={handleKeyDownMenuItem}\n bookType={bookType}\n ref={(element: HTMLDivElement) => {\n if (selectedBookId === bookId) menuItemRef.current = element;\n }}\n >\n {\n setHighlightedChapter(chapterNumber);\n }}\n />\n \n
    \n ))}\n {BOOK_TYPE_ARRAY.length - 1 !== bookTypeIndex ? (\n \n ) : undefined}\n
    \n ),\n )}\n \n
    \n
    \n );\n}\n\nexport default BookChapterControl;\n","import React from 'react';\nimport { Slot } from '@radix-ui/react-slot';\nimport { cva, type VariantProps } from 'class-variance-authority';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport const buttonVariants = cva(\n 'pr-twp tw-inline-flex tw-items-center tw-justify-center tw-whitespace-nowrap tw-rounded-md tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-colors focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50',\n {\n variants: {\n variant: {\n default: 'tw-bg-primary tw-text-primary-foreground hover:tw-bg-primary/90',\n destructive: 'tw-bg-destructive tw-text-destructive-foreground hover:tw-bg-destructive/90',\n outline:\n 'tw-border tw-border-input tw-bg-background hover:tw-bg-accent hover:tw-text-accent-foreground',\n secondary: 'tw-bg-secondary tw-text-secondary-foreground hover:tw-bg-secondary/80',\n ghost: 'hover:tw-bg-accent hover:tw-text-accent-foreground',\n link: 'tw-text-primary tw-underline-offset-4 hover:tw-underline',\n },\n size: {\n default: 'tw-h-10 tw-px-4 tw-py-2',\n sm: 'tw-h-9 tw-rounded-md tw-px-3',\n lg: 'tw-h-11 tw-rounded-md tw-px-8',\n icon: 'tw-h-10 tw-w-10',\n },\n },\n defaultVariants: {\n variant: 'default',\n size: 'default',\n },\n },\n);\n\nexport interface ButtonProps\n extends React.ButtonHTMLAttributes,\n VariantProps {\n asChild?: boolean;\n}\n\nexport const Button = React.forwardRef(\n ({ className, variant, size, asChild = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'button';\n return (\n \n );\n },\n);\nButton.displayName = 'Button';\n","import React from 'react';\nimport * as LabelPrimitive from '@radix-ui/react-label';\nimport { cva, type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst labelVariants = cva(\n 'tw-text-sm tw-font-medium tw-leading-none peer-disabled:tw-cursor-not-allowed peer-disabled:tw-opacity-70',\n);\n\nexport const Label = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef & VariantProps\n>(({ className, ...props }, ref) => (\n \n));\nLabel.displayName = LabelPrimitive.Root.displayName;\n","import React from 'react';\nimport * as RadioGroupPrimitive from '@radix-ui/react-radio-group';\nimport { Circle } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst RadioGroup = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => {\n return (\n \n );\n});\nRadioGroup.displayName = RadioGroupPrimitive.Root.displayName;\n\nconst RadioGroupItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => {\n return (\n \n \n \n \n \n );\n});\nRadioGroupItem.displayName = RadioGroupPrimitive.Item.displayName;\n\nexport { RadioGroup, RadioGroupItem };\n","import React from 'react';\nimport * as PopoverPrimitive from '@radix-ui/react-popover';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Popover = PopoverPrimitive.Root;\n\nconst PopoverTrigger = PopoverPrimitive.Trigger;\n\nconst PopoverContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, align = 'center', sideOffset = 4, ...props }, ref) => (\n \n \n \n));\nPopoverContent.displayName = PopoverPrimitive.Content.displayName;\n\nexport { Popover, PopoverTrigger, PopoverContent };\n","import React from 'react';\nimport * as DialogPrimitive from '@radix-ui/react-dialog';\nimport { X } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Dialog = DialogPrimitive.Root;\n\nconst DialogTrigger = DialogPrimitive.Trigger;\n\nconst DialogPortal = DialogPrimitive.Portal;\n\nconst DialogClose = DialogPrimitive.Close;\n\nconst DialogOverlay = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nDialogOverlay.displayName = DialogPrimitive.Overlay.displayName;\n\nconst DialogContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, ...props }, ref) => (\n \n \n \n {children}\n \n \n Close\n \n \n \n));\nDialogContent.displayName = DialogPrimitive.Content.displayName;\n\nfunction DialogHeader({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nDialogHeader.displayName = 'DialogHeader';\n\nfunction DialogFooter({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nDialogFooter.displayName = 'DialogFooter';\n\nconst DialogTitle = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nDialogTitle.displayName = DialogPrimitive.Title.displayName;\n\nconst DialogDescription = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nDialogDescription.displayName = DialogPrimitive.Description.displayName;\n\nexport {\n Dialog,\n DialogPortal,\n DialogOverlay,\n DialogClose,\n DialogTrigger,\n DialogContent,\n DialogHeader,\n DialogFooter,\n DialogTitle,\n DialogDescription,\n};\n","import React from 'react';\nimport { type DialogProps } from '@radix-ui/react-dialog';\nimport { Command as CommandPrimitive } from 'cmdk';\nimport { Search } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Dialog, DialogContent } from '@/components/shadcn-ui/dialog';\n\nconst Command = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nCommand.displayName = CommandPrimitive.displayName;\n\ninterface CommandDialogProps extends DialogProps {}\n\nfunction CommandDialog({ children, ...props }: CommandDialogProps) {\n return (\n \n \n \n {children}\n \n \n \n );\n}\n\nconst CommandInput = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n
    \n \n \n
    \n));\n\nCommandInput.displayName = CommandPrimitive.Input.displayName;\n\nconst CommandList = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\n\nCommandList.displayName = CommandPrimitive.List.displayName;\n\nconst CommandEmpty = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>((props, ref) => (\n \n));\n\nCommandEmpty.displayName = CommandPrimitive.Empty.displayName;\n\nconst CommandGroup = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\n\nCommandGroup.displayName = CommandPrimitive.Group.displayName;\n\nconst CommandSeparator = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nCommandSeparator.displayName = CommandPrimitive.Separator.displayName;\n\nconst CommandItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\n\nCommandItem.displayName = CommandPrimitive.Item.displayName;\n\nfunction CommandShortcut({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nCommandShortcut.displayName = 'CommandShortcut';\n\nexport {\n Command,\n CommandDialog,\n CommandInput,\n CommandList,\n CommandEmpty,\n CommandGroup,\n CommandItem,\n CommandShortcut,\n CommandSeparator,\n};\n","import { useState } from 'react';\nimport { Check, ChevronsUpDown } from 'lucide-react';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport { Popover, PopoverContent, PopoverTrigger } from '@/components/shadcn-ui/popover';\nimport {\n Command,\n CommandEmpty,\n CommandInput,\n CommandItem,\n CommandList,\n} from '@/components/shadcn-ui/command';\nimport { PopoverProps } from '@radix-ui/react-popover';\n\nexport type ComboBoxLabelOption = { label: string };\nexport type ComboBoxOption = string | number | ComboBoxLabelOption;\n\nexport type ComboBoxProps = {\n /** Optional unique identifier */\n id?: string;\n /** Text label title for combobox */\n /** List of available options for the dropdown menu */\n options?: readonly T[];\n /** Additional css classes to help with unique styling of the combo box button */\n buttonClassName?: string;\n /** Additional css classes to help with unique styling of the combo box popover */\n popoverContentClassName?: string;\n /**\n * The selected value that the combo box currently holds. Must be shallow equal to one of the\n * options entries.\n */\n value?: T;\n /** Triggers when content of textfield is changed */\n onChange?: (newValue: T) => void;\n /** Used to determine the string value for a given option. */\n getOptionLabel?: (option: ComboBoxOption) => string;\n /** Text displayed on button if `value` is undefined */\n buttonPlaceholder?: string;\n /** Placeholder text for text field */\n textPlaceholder?: string;\n /** Text to display when no options match input */\n commandEmptyMessage?: string;\n /** Variant of button */\n buttonVariant?: ButtonProps['variant'];\n /** Text direction ltr or rtl */\n dir?: Direction;\n /** Optional boolean to set if trigger should be disabled */\n isDisabled?: boolean;\n} & PopoverProps;\n\ntype Direction = 'ltr' | 'rtl';\n\nfunction getOptionLabelDefault(option: ComboBoxOption): string {\n if (typeof option === 'string') {\n return option;\n }\n if (typeof option === 'number') {\n return option.toString();\n }\n return option.label;\n}\n\n/**\n * Autocomplete input and command palette with a list of suggestions.\n *\n * Thanks to Shadcn for heavy inspiration and documentation\n * https://ui.shadcn.com/docs/components/combobox\n */\nfunction ComboBox({\n id,\n options = [],\n buttonClassName,\n popoverContentClassName,\n value,\n onChange = () => {},\n getOptionLabel = getOptionLabelDefault,\n buttonPlaceholder = '',\n textPlaceholder = '',\n commandEmptyMessage = 'No option found',\n buttonVariant = 'outline',\n dir = 'ltr',\n isDisabled = false,\n ...props\n}: ComboBoxProps) {\n const [open, setOpen] = useState(false);\n\n return (\n \n \n \n \n {value ? getOptionLabel(value) : buttonPlaceholder}\n \n \n \n \n \n \n \n {commandEmptyMessage}\n \n {options.map((option) => (\n {\n onChange(option);\n setOpen(false);\n }}\n >\n \n {getOptionLabel(option)}\n \n ))}\n \n \n \n \n );\n}\n\nexport default ComboBox;\n","import { useMemo } from 'react';\nimport ComboBox from '@/components/basics/combo-box.component';\nimport { Label } from '@/components/shadcn-ui/label';\n\nexport type ChapterRangeSelectorProps = {\n startChapter: number;\n endChapter: number;\n handleSelectStartChapter: (chapter: number) => void;\n handleSelectEndChapter: (chapter: number) => void;\n isDisabled?: boolean;\n chapterCount: number;\n};\n\nexport default function ChapterRangeSelector({\n startChapter,\n endChapter,\n handleSelectStartChapter,\n handleSelectEndChapter,\n isDisabled = false,\n chapterCount,\n}: ChapterRangeSelectorProps) {\n const chapterOptions = useMemo(\n () => Array.from({ length: chapterCount }, (_, index) => index + 1),\n [chapterCount],\n );\n\n const onChangeStartChapter = (value: number) => {\n handleSelectStartChapter(value);\n if (value > endChapter) {\n handleSelectEndChapter(value);\n }\n };\n\n const onChangeEndChapter = (value: number) => {\n handleSelectEndChapter(value);\n if (value < startChapter) {\n handleSelectStartChapter(value);\n }\n };\n\n return (\n <>\n \n option.toString()}\n value={startChapter}\n />\n\n \n option.toString()}\n value={endChapter}\n />\n \n );\n}\n","import { Button } from '@/components/shadcn-ui/button';\nimport { Label } from '@/components/shadcn-ui/label';\nimport { RadioGroup, RadioGroupItem } from '@/components/shadcn-ui/radio-group';\nimport { Canon } from '@sillsdev/scripture';\nimport { LocalizedStringValue } from 'platform-bible-utils';\nimport { useState } from 'react';\nimport ChapterRangeSelector, {\n ChapterRangeSelectorProps,\n} from '../basics/chapter-range-selector.component';\n\nexport enum BookSelectionMode {\n CURRENT_BOOK = 'current book',\n CHOOSE_BOOKS = 'choose books',\n}\n\n/**\n * Object containing all keys used for localization in this component. If you're using this\n * component in an extension, you can pass it into the useLocalizedStrings hook to easily obtain the\n * localized strings and pass them into the localizedStrings prop of this component\n */\nexport const BOOK_SELECTOR_STRING_KEYS = Object.freeze([\n '%webView_bookSelector_currentBook%',\n '%webView_bookSelector_choose%',\n '%webView_bookSelector_chooseBooks%',\n] as const);\n\nexport type BookSelectorLocalizedStrings = {\n [localizedInventoryKey in (typeof BOOK_SELECTOR_STRING_KEYS)[number]]?: LocalizedStringValue;\n};\n\n/**\n * Gets the localized value for the provided key\n *\n * @param strings Object containing localized string\n * @param key Key for a localized string\n * @returns The localized value for the provided key, if available. Returns the key if no localized\n * value is available\n */\nconst localizeString = (\n strings: BookSelectorLocalizedStrings,\n key: keyof BookSelectorLocalizedStrings,\n) => {\n return strings[key] ?? key;\n};\n\ntype BookSelectorProps = ChapterRangeSelectorProps & {\n handleBookSelectionModeChange: (newMode: BookSelectionMode) => void;\n currentBookName: string;\n onSelectBooks: () => void;\n selectedBookIds: string[];\n localizedStrings: BookSelectorLocalizedStrings;\n};\n\nexport default function BookSelector({\n handleBookSelectionModeChange,\n currentBookName,\n onSelectBooks,\n selectedBookIds,\n chapterCount,\n endChapter,\n handleSelectEndChapter,\n startChapter,\n handleSelectStartChapter,\n localizedStrings,\n}: BookSelectorProps) {\n const currentBookText = localizeString(localizedStrings, '%webView_bookSelector_currentBook%');\n const chooseText = localizeString(localizedStrings, '%webView_bookSelector_choose%');\n const chooseBooksText = localizeString(localizedStrings, '%webView_bookSelector_chooseBooks%');\n\n const [bookSelectionMode, setBookSelectionMode] = useState(\n BookSelectionMode.CURRENT_BOOK,\n );\n\n const onSelectionModeChange = (newMode: BookSelectionMode) => {\n setBookSelectionMode(newMode);\n handleBookSelectionModeChange(newMode);\n };\n\n return (\n onSelectionModeChange(value as BookSelectionMode)}\n >\n
    \n
    \n
    \n \n \n
    \n \n
    \n \n
    \n
    \n
    \n
    \n \n \n
    \n \n onSelectBooks()}\n >\n {chooseText}\n \n
    \n
    \n \n );\n}\n","import { DropdownMenuTrigger } from '@radix-ui/react-dropdown-menu';\nimport { FilterIcon } from 'lucide-react';\nimport { Table } from '@tanstack/react-table';\n\nimport { Button } from '@/components/shadcn-ui/button';\nimport {\n DropdownMenu,\n DropdownMenuCheckboxItem,\n DropdownMenuContent,\n DropdownMenuLabel,\n DropdownMenuSeparator,\n} from '@/components/shadcn-ui/dropdown-menu';\n\ninterface DataTableViewOptionsProps {\n table: Table;\n}\n\nfunction DataTableViewOptions({ table }: DataTableViewOptionsProps) {\n return (\n \n \n \n \n \n Toggle columns\n \n {table\n .getAllColumns()\n .filter((column) => column.getCanHide())\n .map((column) => {\n return (\n column.toggleVisibility(!!value)}\n >\n {column.id}\n \n );\n })}\n \n \n );\n}\n\nexport default DataTableViewOptions;\n","import React from 'react';\nimport * as SelectPrimitive from '@radix-ui/react-select';\nimport { Check, ChevronDown, ChevronUp } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Select = SelectPrimitive.Root;\n\nconst SelectGroup = SelectPrimitive.Group;\n\nconst SelectValue = SelectPrimitive.Value;\n\nconst SelectTrigger = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, ...props }, ref) => (\n span]:tw-line-clamp-1',\n className,\n )}\n {...props}\n >\n {children}\n \n \n \n \n));\nSelectTrigger.displayName = SelectPrimitive.Trigger.displayName;\n\nconst SelectScrollUpButton = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n));\nSelectScrollUpButton.displayName = SelectPrimitive.ScrollUpButton.displayName;\n\nconst SelectScrollDownButton = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n));\nSelectScrollDownButton.displayName = SelectPrimitive.ScrollDownButton.displayName;\n\nconst SelectContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, position = 'popper', ...props }, ref) => (\n \n \n \n \n {children}\n \n \n \n \n));\nSelectContent.displayName = SelectPrimitive.Content.displayName;\n\nconst SelectLabel = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSelectLabel.displayName = SelectPrimitive.Label.displayName;\n\nconst SelectItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, ...props }, ref) => (\n \n \n \n \n \n \n\n {children}\n \n));\nSelectItem.displayName = SelectPrimitive.Item.displayName;\n\nconst SelectSeparator = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSelectSeparator.displayName = SelectPrimitive.Separator.displayName;\n\nexport {\n Select,\n SelectGroup,\n SelectValue,\n SelectTrigger,\n SelectContent,\n SelectLabel,\n SelectItem,\n SelectSeparator,\n SelectScrollUpButton,\n SelectScrollDownButton,\n};\n","import { ChevronLeftIcon, ChevronRightIcon, ArrowLeftIcon, ArrowRightIcon } from 'lucide-react';\nimport { Table } from '@tanstack/react-table';\n\nimport { Button } from '@/components/shadcn-ui/button';\nimport {\n Select,\n SelectContent,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\n\ninterface DataTablePaginationProps {\n table: Table;\n}\n\nfunction DataTablePagination({ table }: DataTablePaginationProps) {\n return (\n
    \n
    \n
    \n {table.getFilteredSelectedRowModel().rows.length} of{' '}\n {table.getFilteredRowModel().rows.length} row(s) selected\n
    \n
    \n

    Rows per page

    \n {\n table.setPageSize(Number(value));\n }}\n >\n \n \n \n \n {[10, 20, 30, 40, 50].map((pageSize) => (\n \n {pageSize}\n \n ))}\n \n \n
    \n
    \n Page {table.getState().pagination.pageIndex + 1} of {table.getPageCount()}\n
    \n
    \n table.setPageIndex(0)}\n disabled={!table.getCanPreviousPage()}\n >\n Go to first page\n \n \n table.previousPage()}\n disabled={!table.getCanPreviousPage()}\n >\n Go to previous page\n \n \n table.nextPage()}\n disabled={!table.getCanNextPage()}\n >\n Go to next page\n \n \n table.setPageIndex(table.getPageCount() - 1)}\n disabled={!table.getCanNextPage()}\n >\n Go to last page\n \n \n
    \n
    \n
    \n );\n}\n\nexport default DataTablePagination;\n","import React from 'react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Table = React.forwardRef<\n HTMLTableElement,\n React.HTMLAttributes & { stickyHeader?: boolean }\n>(({ className, stickyHeader, ...props }, ref) => (\n
    \n \n
    \n));\nTable.displayName = 'Table';\n\nconst TableHeader = React.forwardRef<\n HTMLTableSectionElement,\n React.HTMLAttributes & { stickyHeader?: boolean }\n>(({ className, stickyHeader, ...props }, ref) => (\n \n));\nTableHeader.displayName = 'TableHeader';\n\nconst TableBody = React.forwardRef<\n HTMLTableSectionElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableBody.displayName = 'TableBody';\n\nconst TableFooter = React.forwardRef<\n HTMLTableSectionElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n tr]:last:tw-border-b-0', className)}\n {...props}\n />\n));\nTableFooter.displayName = 'TableFooter';\n\nconst TableRow = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nTableRow.displayName = 'TableRow';\n\nconst TableHead = React.forwardRef<\n HTMLTableCellElement,\n React.ThHTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableHead.displayName = 'TableHead';\n\nconst TableCell = React.forwardRef<\n HTMLTableCellElement,\n React.TdHTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableCell.displayName = 'TableCell';\n\nconst TableCaption = React.forwardRef<\n HTMLTableCaptionElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableCaption.displayName = 'TableCaption';\n\nexport { Table, TableHeader, TableBody, TableFooter, TableHead, TableRow, TableCell, TableCaption };\n","import { useState } from 'react';\n\nimport {\n ColumnFiltersState,\n flexRender,\n getCoreRowModel,\n getFilteredRowModel,\n getPaginationRowModel,\n getSortedRowModel,\n SortingState,\n ColumnDef as TSColumnDef,\n Row as TSRow,\n RowSelectionState as TSRowSelectionState,\n SortDirection as TSSortDirection,\n Table as TSTable,\n useReactTable,\n VisibilityState,\n} from '@tanstack/react-table';\n\nimport DataTableViewOptions from '@/components/advanced/data-table/data-table-column-toggle.component';\nimport DataTablePagination from '@/components/advanced/data-table/data-table-pagination.component';\nimport { Button } from '@/components/shadcn-ui/button';\nimport {\n Table,\n TableBody,\n TableCell,\n TableHead,\n TableHeader,\n TableRow,\n} from '@/components/shadcn-ui/table';\n\nexport type ColumnDef = TSColumnDef;\nexport type RowContents = TSRow;\nexport type TableContents = TSTable;\nexport type SortDirection = TSSortDirection;\nexport type RowSelectionState = TSRowSelectionState;\n\ninterface DataTableProps {\n columns: ColumnDef[];\n data: TData[];\n enablePagination?: boolean;\n showPaginationControls?: boolean;\n showColumnVisibilityControls?: boolean;\n stickyHeader?: boolean;\n onRowClickHandler?: (row: RowContents, table: TableContents) => void;\n}\n\n/**\n * Feature-rich table component that infuses our basic shadcn-based Table component with features\n * from TanStack's React Table library\n */\nfunction DataTable({\n columns,\n data,\n enablePagination = false,\n showPaginationControls = false,\n showColumnVisibilityControls = false,\n stickyHeader = false,\n onRowClickHandler = () => {},\n}: DataTableProps) {\n const [sorting, setSorting] = useState([]);\n const [columnFilters, setColumnFilters] = useState([]);\n const [columnVisibility, setColumnVisibility] = useState({});\n const [rowSelection, setRowSelection] = useState({});\n\n const table = useReactTable({\n data,\n columns,\n getCoreRowModel: getCoreRowModel(),\n ...(enablePagination && { getPaginationRowModel: getPaginationRowModel() }),\n onSortingChange: setSorting,\n getSortedRowModel: getSortedRowModel(),\n onColumnFiltersChange: setColumnFilters,\n getFilteredRowModel: getFilteredRowModel(),\n onColumnVisibilityChange: setColumnVisibility,\n onRowSelectionChange: setRowSelection,\n state: {\n sorting,\n columnFilters,\n columnVisibility,\n rowSelection,\n },\n });\n\n return (\n
    \n {showColumnVisibilityControls && }\n \n \n {table.getHeaderGroups().map((headerGroup) => (\n \n {headerGroup.headers.map((header) => {\n return (\n \n {header.isPlaceholder\n ? undefined\n : flexRender(header.column.columnDef.header, header.getContext())}\n \n );\n })}\n \n ))}\n \n \n {table.getRowModel().rows?.length ? (\n table.getRowModel().rows.map((row) => (\n onRowClickHandler(row, table)}\n key={row.id}\n data-state={row.getIsSelected() && 'selected'}\n >\n {row.getVisibleCells().map((cell) => (\n \n {flexRender(cell.column.columnDef.cell, cell.getContext())}\n \n ))}\n \n ))\n ) : (\n \n \n No results.\n \n \n )}\n \n
    \n {enablePagination && (\n
    \n table.previousPage()}\n disabled={!table.getCanPreviousPage()}\n >\n Previous\n \n table.nextPage()}\n disabled={!table.getCanNextPage()}\n >\n Next\n \n
    \n )}\n {enablePagination && showPaginationControls && }\n
    \n );\n}\n\nexport default DataTable;\n","import {\n Table,\n TableBody,\n TableCell,\n TableHead,\n TableHeader,\n TableRow,\n} from '@/components/shadcn-ui/table';\nimport { Canon } from '@sillsdev/scripture';\nimport { deepEqual, LanguageStrings, ScriptureReference } from 'platform-bible-utils';\nimport { useMemo } from 'react';\nimport { InventoryItemOccurrence } from './inventory-utils';\n\n/** Props for the OccurrencesTable component */\ntype OccurrencesTableProps = {\n /** Data that contains scriptures references and snippets of scripture */\n occurrenceData: InventoryItemOccurrence[];\n /** Callback function that is executed when the scripture reference is changed */\n setScriptureReference: (scriptureReference: ScriptureReference) => void;\n /**\n * Object with all localized strings that the OccurrencesTable needs to work well across multiple\n * languages\n */\n localizedStrings: LanguageStrings;\n};\n\n/**\n * Table that shows occurrences of specified inventory item(s). The first column shows the related\n * scripture reference. The second column shows the snippet of scripture that contains the specified\n * inventory item\n */\nfunction OccurrencesTable({\n occurrenceData,\n setScriptureReference,\n localizedStrings,\n}: OccurrencesTableProps) {\n const referenceHeaderText =\n localizedStrings['%webView_inventory_occurrences_table_header_reference%'];\n const occurrenceHeaderText =\n localizedStrings['%webView_inventory_occurrences_table_header_occurrence%'];\n\n const occurrences: InventoryItemOccurrence[] = useMemo(() => {\n const uniqueOccurrences: InventoryItemOccurrence[] = [];\n\n occurrenceData.forEach((occurrence) => {\n if (!uniqueOccurrences.some((uniqueOccurrence) => deepEqual(uniqueOccurrence, occurrence))) {\n uniqueOccurrences.push(occurrence);\n }\n });\n\n return uniqueOccurrences;\n }, [occurrenceData]);\n\n return (\n \n \n \n {referenceHeaderText}\n {occurrenceHeaderText}\n \n \n \n {occurrences.length > 0 &&\n occurrences.map((occurrence) => (\n {\n setScriptureReference(occurrence.reference);\n }}\n >\n {`${Canon.bookNumberToEnglishName(occurrence.reference.bookNum)} ${occurrence.reference.chapterNum}:${occurrence.reference.verseNum}`}\n {occurrence.text}\n \n ))}\n \n
    \n );\n}\n\nexport default OccurrencesTable;\n","import React from 'react';\nimport * as CheckboxPrimitive from '@radix-ui/react-checkbox';\nimport { Check } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Checkbox = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n \n \n));\nCheckbox.displayName = CheckboxPrimitive.Root.displayName;\n\nexport default Checkbox;\n","import { Canon } from '@sillsdev/scripture';\nimport { ScriptureReference } from 'platform-bible-utils';\n\n/* #region Types */\n\n/**\n * Status of items that appear in inventories. 'approved' and 'unapproved' items are defined in the\n * project's `Settings.xml`. All other items are defined as 'unknown'\n */\nexport type Status = 'approved' | 'unapproved' | 'unknown';\n\n/** Occurrence of item in inventory. Primarily used by table that shows occurrences */\nexport type InventoryItemOccurrence = {\n /** Reference to scripture where the item appears */\n reference: ScriptureReference;\n /** Snippet of scripture that contains the occurrence */\n text: string;\n};\n\n/** Data structure that contains all information on an item that is shown in an inventory */\nexport type InventoryTableData = {\n /**\n * The item (e.g. a character in the characters inventory, a marker in the marker inventory) In\n * most cases the array will only have one element. In case of additional items (e.g. the\n * preceding marker in the markers check), the primary item should be stored in the first index.\n * To show additional items in the inventory, make sure to configure the `additionalItemsLabels`\n * prop for the Inventory component\n */\n items: string[];\n /** The number of times this item occurs in the selected scope */\n count: number;\n /** The status of this item (see documentation for `Status` type for more information) */\n status: Status;\n /** Occurrences of this item in the scripture text for the selected scope */\n occurrences: InventoryItemOccurrence[];\n};\n\n/* #endregion */\n\n/* #region Functions */\n\n/**\n * Splits USFM string into shorter line-like segments\n *\n * @param text A single (likely very large) USFM string\n * @returns An array containing the input text, split into shorter segments\n */\nexport const getLinesFromUSFM = (text: string) => {\n // Splits on (CR)LF, CR, \\v, \\c and \\id\n return text.split(/(?:\\r?\\n|\\r)|(?=(?:\\\\(?:v|c|id)))/g);\n};\n\n/**\n * Extracts chapter or verse number from USFM strings that start with a \\c or \\v marker\n *\n * @param text USFM string that is expected to start with \\c or \\v marker\n * @returns Chapter or verse number if one is found. Else returns 0.\n */\nexport const getNumberFromUSFM = (text: string): number | undefined => {\n // Captures all digits that follow \\v or \\c markers followed by whitespace located at the start of a string\n const regex = /^\\\\[vc]\\s+(\\d+)/;\n const match = text.match(regex);\n\n if (match) {\n return +match[1];\n }\n return undefined;\n};\n\n/**\n * Gets book ID from USFM string that starts with the \\id marker, and returns book number for it\n *\n * @param text USFM string that is expected to start with \\id marker\n * @returns Book number corresponding to the \\id marker in the input text. Returns 0 if no marker is\n * found or the marker is not valid\n */\nexport const getBookNumFromId = (text: string): number => {\n // Captures all digits that follow an \\id marker followed by whitespace located at the start of a string\n const match = text.match(/^\\\\id\\s+([A-Za-z]+)/);\n if (match) {\n return Canon.bookIdToNumber(match[1]);\n }\n return 0;\n};\n\n/**\n * Gets the status for an item, typically used in the Inventory component\n *\n * @param item The item for which the status is being requested\n * @param approvedItems Array of approved items, typically as defined in `Settings.xml`\n * @param unapprovedItems Array of unapproved items, typically as defined in `Settings.xml`\n * @returns The status for the specified item\n */\nexport const getStatusForItem = (\n item: string,\n approvedItems: string[],\n unapprovedItems: string[],\n): Status => {\n if (unapprovedItems.includes(item)) return 'unapproved';\n if (approvedItems.includes(item)) return 'approved';\n return 'unknown';\n};\n\n/* #endregion */\n","import React from 'react';\nimport * as TogglePrimitive from '@radix-ui/react-toggle';\nimport { cva, type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst toggleVariants = cva(\n 'pr-twp tw-inline-flex tw-items-center tw-justify-center tw-rounded-md tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-colors hover:tw-bg-muted hover:tw-text-muted-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50 data-[state=on]:tw-bg-accent data-[state=on]:tw-text-accent-foreground',\n {\n variants: {\n variant: {\n default: 'tw-bg-transparent',\n outline:\n 'tw-border tw-border-input tw-bg-transparent hover:tw-bg-accent hover:tw-text-accent-foreground',\n },\n size: {\n default: 'tw-h-10 tw-px-3',\n sm: 'tw-h-9 tw-px-2.5',\n lg: 'tw-h-11 tw-px-5',\n },\n },\n defaultVariants: {\n variant: 'default',\n size: 'default',\n },\n },\n);\n\nconst Toggle = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef & VariantProps\n>(({ className, variant, size, ...props }, ref) => (\n \n));\n\nToggle.displayName = TogglePrimitive.Root.displayName;\n\nexport { Toggle, toggleVariants };\n","import React from 'react';\nimport * as ToggleGroupPrimitive from '@radix-ui/react-toggle-group';\nimport { type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { toggleVariants } from '@/components/shadcn-ui/toggle';\n\nconst ToggleGroupContext = React.createContext>({\n size: 'default',\n variant: 'default',\n});\n\nconst ToggleGroup = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef &\n VariantProps\n>(({ className, variant, size, children, ...props }, ref) => (\n \n \n {children}\n \n \n));\n\nToggleGroup.displayName = ToggleGroupPrimitive.Root.displayName;\n\nconst ToggleGroupItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef &\n VariantProps\n>(({ className, children, variant, size, ...props }, ref) => {\n const context = React.useContext(ToggleGroupContext);\n\n return (\n \n {children}\n \n );\n});\n\nToggleGroupItem.displayName = ToggleGroupPrimitive.Item.displayName;\n\nexport { ToggleGroup, ToggleGroupItem };\n","import { ColumnDef, SortDirection } from '@/components/advanced/data-table/data-table.component';\nimport { Button } from '@/components/shadcn-ui/button';\nimport { ToggleGroup, ToggleGroupItem } from '@/components/shadcn-ui/toggle-group';\nimport {\n ArrowDownIcon,\n ArrowUpDownIcon,\n ArrowUpIcon,\n CircleCheckIcon,\n CircleHelpIcon,\n CircleXIcon,\n} from 'lucide-react';\nimport { ReactNode } from 'react';\nimport { InventoryTableData, Status } from './inventory-utils';\n\n/**\n * Gets an icon that indicates the current sorting direction based on the provided input\n *\n * @param sortDirection Sorting direction. Can be ascending ('asc'), descending ('desc') or false (\n * i.e. not sorted)\n * @returns The appropriate sorting icon for the provided sorting direction\n */\nconst getSortingIcon = (sortDirection: false | SortDirection): ReactNode => {\n if (sortDirection === 'asc') {\n return ;\n }\n if (sortDirection === 'desc') {\n return ;\n }\n return ;\n};\n\n/**\n * Function that creates the item column for inventories\n *\n * @param itemLabel Localized label for the item column (e.g. 'Character', 'Repeated Word', etc.)\n * @returns Column that shows the inventory items. Should be used with the DataTable component\n */\nexport const inventoryItemColumn = (itemLabel: string): ColumnDef => {\n return {\n accessorKey: 'item',\n accessorFn: (row: InventoryTableData) => row.items[0],\n header: ({ column }) => (\n \n ),\n };\n};\n\n/**\n * Function that creates the additional item columns for inventories\n *\n * @param additionalItemLabel Localized label for the additional item column (e.g. 'Preceding\n * Marker')\n * @param additionalItemIndex Index that locates the desired item in the items array of the\n * inventory\n * @returns Column that shows additional inventory items. Should be used with the DataTable\n * component\n */\nexport const inventoryAdditionalItemColumn = (\n additionalItemLabel: string,\n additionalItemIndex: number,\n): ColumnDef => {\n return {\n accessorKey: `item${additionalItemIndex}`,\n accessorFn: (row: InventoryTableData) => row.items[additionalItemIndex],\n header: ({ column }) => (\n \n ),\n };\n};\n\n/**\n * Function that creates the count column for inventories. Should be used with the DataTable\n * component.\n *\n * @param itemLabel Localized label for the count column\n * @returns Column that shows the number of occurrences of the related inventory items\n */\nexport const inventoryCountColumn = (countLabel: string): ColumnDef => {\n return {\n accessorKey: 'count',\n header: ({ column }) => (\n
    \n \n
    \n ),\n cell: ({ row }) =>
    {row.getValue('count')}
    ,\n };\n};\n\n/**\n * Function that updates project settings when status for item(s) changes\n *\n * @param changedItems Array of items for which the status is being updated\n * @param newStatus The status that the items are being given\n * @param approvedItems Array of currently approved items\n * @param onApprovedItemsChange Callback function that stores the updated list of approved items\n * @param unapprovedItems Array of currently unapproved items\n * @param onUnapprovedItemsChange Callback function that stores the updated list of unapproved items\n */\nconst statusChangeHandler = (\n changedItems: string[],\n newStatus: Status,\n approvedItems: string[],\n onApprovedItemsChange: (items: string[]) => void,\n unapprovedItems: string[],\n onUnapprovedItemsChange: (items: string[]) => void,\n) => {\n let newApprovedItems: string[] = [...approvedItems];\n changedItems.forEach((item) => {\n if (newStatus === 'approved') {\n if (!newApprovedItems.includes(item)) {\n newApprovedItems.push(item);\n }\n } else {\n newApprovedItems = newApprovedItems.filter((validItem) => validItem !== item);\n }\n });\n onApprovedItemsChange(newApprovedItems);\n\n let newUnapprovedItems: string[] = [...unapprovedItems];\n changedItems.forEach((item) => {\n if (newStatus === 'unapproved') {\n if (!newUnapprovedItems.includes(item)) {\n newUnapprovedItems.push(item);\n }\n } else {\n newUnapprovedItems = newUnapprovedItems.filter((unapprovedItem) => unapprovedItem !== item);\n }\n });\n onUnapprovedItemsChange(newUnapprovedItems);\n};\n\n/**\n * Function that creates the status column for inventories. Should be used with the DataTable\n * component.\n *\n * @param statusLabel Localized label for the status column\n * @param approvedItems Array of approved items, typically as defined in `Settings.xml`\n * @param onApprovedItemsChange Callback function that stores the updated list of approved items\n * @param unapprovedItems Array of unapproved items, typically as defined in `Settings.xml`\n * @param onUnapprovedItemsChange Callback function that stores the updated list of unapproved items\n * @returns Column that shows the status buttons for the related inventory item. The button for the\n * current status of the item is selected\n */\nexport const inventoryStatusColumn = (\n statusLabel: string,\n approvedItems: string[],\n onApprovedItemsChange: (items: string[]) => void,\n unapprovedItems: string[],\n onUnapprovedItemsChange: (items: string[]) => void,\n): ColumnDef => {\n return {\n accessorKey: 'status',\n header: ({ column }) => {\n return (\n
    \n \n
    \n );\n },\n cell: ({ row }) => {\n const status: Status = row.getValue('status');\n const item: string = row.getValue('item');\n return (\n \n \n statusChangeHandler(\n [item],\n 'approved',\n approvedItems,\n onApprovedItemsChange,\n unapprovedItems,\n onUnapprovedItemsChange,\n )\n }\n value=\"approved\"\n >\n \n \n \n statusChangeHandler(\n [item],\n 'unapproved',\n approvedItems,\n onApprovedItemsChange,\n unapprovedItems,\n onUnapprovedItemsChange,\n )\n }\n value=\"unapproved\"\n >\n \n \n \n statusChangeHandler(\n [item],\n 'unknown',\n approvedItems,\n onApprovedItemsChange,\n unapprovedItems,\n onUnapprovedItemsChange,\n )\n }\n value=\"unknown\"\n >\n \n \n \n );\n },\n };\n};\n","import DataTable, {\n ColumnDef,\n RowContents,\n RowSelectionState,\n TableContents,\n} from '@/components/advanced/data-table/data-table.component';\nimport OccurrencesTable from '@/components/advanced/inventory/occurrences-table.component';\nimport Checkbox from '@/components/shadcn-ui/checkbox';\nimport { Input } from '@/components/shadcn-ui/input';\nimport { Label } from '@/components/shadcn-ui/label';\nimport {\n Select,\n SelectContent,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\nimport {\n deepEqual,\n LocalizedStringValue,\n ScriptureReference,\n substring,\n} from 'platform-bible-utils';\nimport { useEffect, useMemo, useState } from 'react';\nimport {\n getBookNumFromId,\n getLinesFromUSFM,\n getNumberFromUSFM,\n getStatusForItem,\n InventoryItemOccurrence,\n InventoryTableData,\n Status,\n} from './inventory-utils';\nimport { inventoryAdditionalItemColumn } from './inventory-columns';\n\n/**\n * Object containing all keys used for localization in this component. If you're using this\n * component in an extension, you can pass it into the useLocalizedStrings hook to easily obtain the\n * localized strings and pass them into the localizedStrings prop of this component\n */\nexport const INVENTORY_STRING_KEYS = Object.freeze([\n '%webView_inventory_all%',\n '%webView_inventory_approved%',\n '%webView_inventory_unapproved%',\n '%webView_inventory_unknown%',\n '%webView_inventory_scope_currentBook%',\n '%webView_inventory_scope_chapter%',\n '%webView_inventory_scope_verse%',\n '%webView_inventory_filter_text%',\n '%webView_inventory_show_additional_items%',\n '%webView_inventory_occurrences_table_header_reference%',\n '%webView_inventory_occurrences_table_header_occurrence%',\n] as const);\n\nexport type InventoryLocalizedStrings = {\n [localizedInventoryKey in (typeof INVENTORY_STRING_KEYS)[number]]?: LocalizedStringValue;\n};\n\n/** Scope of scripture that the inventory can operate on */\nexport type Scope = 'book' | 'chapter' | 'verse';\n\n/** Status values that the status filter can select from */\ntype StatusFilter = Status | 'all';\n\n/** Text labels for the inventory columns and the control components of additional inventory items */\ntype AdditionalItemsLabels = {\n checkboxText?: string;\n tableHeaders?: string[];\n};\n\n/**\n * Filters data that is shown in the DataTable section of the Inventory\n *\n * @param itemData All inventory items and their related information\n * @param statusFilter Allows filtering by status (i.e. show all items, or only items that are\n * 'approved', 'unapproved' or 'unknown')\n * @param textFilter Allows filtering by text. All items that include the filter text will be\n * selected.\n * @returns Array of items and their related information that are matched by the specified filters\n */\nconst filterItemData = (\n itemData: InventoryTableData[],\n statusFilter: StatusFilter,\n textFilter: string,\n): InventoryTableData[] => {\n let filteredItemData: InventoryTableData[] = itemData;\n\n if (statusFilter !== 'all') {\n filteredItemData = filteredItemData.filter(\n (item) =>\n (statusFilter === 'approved' && item.status === 'approved') ||\n (statusFilter === 'unapproved' && item.status === 'unapproved') ||\n (statusFilter === 'unknown' && item.status === 'unknown'),\n );\n }\n\n if (textFilter !== '')\n filteredItemData = filteredItemData.filter((item) => item.items[0].includes(textFilter));\n\n return filteredItemData;\n};\n\n/**\n * Turns array of strings into array of inventory items, along with their count and status\n *\n * @param text The source scripture text that is searched for inventory items\n * @param scriptureRef The scripture reference that the application is currently set to\n * @param approvedItems Array of approved items, typically as defined in `Settings.xml`\n * @param unapprovedItems Array of unapproved items, typically as defined in `Settings.xml`\n * @param itemRegex Regular expression that describes what items this Inventory should extract from\n * the provided scripture text\n * @returns Array of inventory items, along with their count and status\n */\nconst createTableData = (\n text: string | undefined,\n scriptureRef: ScriptureReference,\n approvedItems: string[],\n unapprovedItems: string[],\n itemRegex: RegExp,\n): InventoryTableData[] => {\n if (!text) return [];\n\n const tableData: InventoryTableData[] = [];\n\n let currentBook: number | undefined = scriptureRef.bookNum;\n let currentChapter: number | undefined = scriptureRef.chapterNum;\n let currentVerse: number | undefined = scriptureRef.verseNum;\n\n const lines = getLinesFromUSFM(text);\n\n lines.forEach((line: string) => {\n if (line.startsWith('\\\\id')) {\n currentBook = getBookNumFromId(line);\n currentChapter = 0;\n currentVerse = 0;\n }\n if (line.startsWith('\\\\c')) {\n currentChapter = getNumberFromUSFM(line);\n currentVerse = 0;\n }\n if (line.startsWith('\\\\v')) {\n currentVerse = getNumberFromUSFM(line);\n if (currentChapter === 0) {\n currentChapter = scriptureRef.chapterNum;\n }\n }\n\n let match: RegExpExecArray | undefined = itemRegex.exec(line) ?? undefined;\n while (match) {\n const items: string[] = [];\n match.forEach((item) => items.push(item));\n const itemIndex = match.index;\n const existingItem = tableData.find((tableEntry) => deepEqual(tableEntry.items, items));\n const newReference: InventoryItemOccurrence = {\n reference: {\n bookNum: currentBook !== undefined ? currentBook : -1,\n chapterNum: currentChapter !== undefined ? currentChapter : -1,\n verseNum: currentVerse !== undefined ? currentVerse : -1,\n },\n text: substring(line, Math.max(0, itemIndex - 25), Math.min(itemIndex + 25, line.length)),\n };\n if (existingItem) {\n existingItem.count += 1;\n existingItem.occurrences.push(newReference);\n } else {\n const newItem: InventoryTableData = {\n items,\n count: 1,\n status: getStatusForItem(items[0], approvedItems, unapprovedItems),\n occurrences: [newReference],\n };\n tableData.push(newItem);\n }\n\n match = itemRegex.exec(line) ?? undefined;\n }\n });\n\n return tableData;\n};\n\n/**\n * Gets the localized value for the provided key\n *\n * @param strings Object containing localized string\n * @param key Key for a localized string\n * @returns The localized value for the provided key, if available. Returns the key if no localized\n * value is available\n */\nconst localizeString = (\n strings: InventoryLocalizedStrings,\n key: keyof InventoryLocalizedStrings,\n) => {\n return strings[key] ?? key;\n};\n\n/** Props for the Inventory component */\ntype InventoryProps = {\n /** The scripture reference that the application is currently set to */\n scriptureReference: ScriptureReference;\n /** Callback function that is executed when the scripture reference is changed */\n setScriptureReference: (scriptureReference: ScriptureReference) => void;\n /**\n * Object with all localized strings that the Inventory needs to work well across multiple\n * languages. When using this component with Platform.Bible, you can import\n * `INVENTORY_STRING_KEYS` from this library, pass it in to the Platform's localization hook, and\n * pass the localized keys that are returned by the hook into this prop.\n */\n localizedStrings: InventoryLocalizedStrings;\n /**\n * The logic that finds the desired items in the source text. This can either be a Regular\n * expression that captures one or multiple items (preferred), or a custom function that builds\n * and return an InventoryDataTable[] manually. Note: In case the logic captures more than one\n * item (i.e. InventoryTableData.items has a length greater than 1), you must provide text labels\n * for the related columns and control elements to show by setting the `additionalItemsLabels`\n * prop\n */\n extractItems:\n | RegExp\n | ((\n text: string | undefined,\n scriptureRef: ScriptureReference,\n approvedItems: string[],\n unapprovedItems: string[],\n ) => InventoryTableData[]);\n /**\n * Text labels for control elements and additional column headers in case your Inventory has more\n * than one item to show (e.g. The 'Preceding Marker' in the Markers Inventory)\n */\n additionalItemsLabels?: AdditionalItemsLabels;\n /** Array of approved items, typically as defined in `Settings.xml` */\n approvedItems: string[];\n /** Array of unapproved items, typically as defined in `Settings.xml` */\n unapprovedItems: string[];\n /** The source scripture text that is searched for in inventory items */\n text: string | undefined;\n /** Scope of scripture that the inventory will operate on */\n scope: Scope;\n /** Callback function that is executed when the scope is changed from the Inventory */\n onScopeChange: (scope: Scope) => void;\n /**\n * Column definitions for the Inventory data table. The most commonly used column definitions are\n * pre-configured for your convenience and can be imported (e.g. inventoryItemColumn,\n * inventoryAdditionalItemColumn inventoryCountColumn, and inventoryStatusColumn). If you need any\n * other columns you can add these yourself\n */\n columns: ColumnDef[];\n};\n\n/** Inventory component that is used to view and control the status of provided project settings */\nexport default function Inventory({\n scriptureReference,\n setScriptureReference,\n localizedStrings,\n extractItems,\n additionalItemsLabels,\n approvedItems,\n unapprovedItems,\n text,\n scope,\n onScopeChange,\n columns,\n}: InventoryProps) {\n const allItemsText = localizeString(localizedStrings, '%webView_inventory_all%');\n const approvedItemsText = localizeString(localizedStrings, '%webView_inventory_approved%');\n const unapprovedItemsText = localizeString(localizedStrings, '%webView_inventory_unapproved%');\n const unknownItemsText = localizeString(localizedStrings, '%webView_inventory_unknown%');\n const scopeBookText = localizeString(localizedStrings, '%webView_inventory_scope_currentBook%');\n const scopeChapterText = localizeString(localizedStrings, '%webView_inventory_scope_chapter%');\n const scopeVerseText = localizeString(localizedStrings, '%webView_inventory_scope_verse%');\n const filterText = localizeString(localizedStrings, '%webView_inventory_filter_text%');\n const showAdditionalItemsText = localizeString(\n localizedStrings,\n '%webView_inventory_show_additional_items%',\n );\n\n const [showAdditionalItems, setShowAdditionalItems] = useState(false);\n const [statusFilter, setStatusFilter] = useState('all');\n const [textFilter, setTextFilter] = useState('');\n const [selectedItem, setSelectedItem] = useState([]);\n\n const tableData: InventoryTableData[] = useMemo(() => {\n if (!text) return [];\n if (extractItems instanceof RegExp)\n return createTableData(\n text,\n scriptureReference,\n approvedItems,\n unapprovedItems,\n extractItems,\n );\n return extractItems(text, scriptureReference, approvedItems, unapprovedItems);\n }, [text, extractItems, scriptureReference, approvedItems, unapprovedItems]);\n\n const reducedTableData: InventoryTableData[] = useMemo(() => {\n if (showAdditionalItems) return tableData;\n\n const newTableData: InventoryTableData[] = [];\n\n tableData.forEach((tableEntry) => {\n const firstItem = tableEntry.items[0];\n\n const existingEntry = newTableData.find(\n (newTableEntry) => newTableEntry.items[0] === firstItem,\n );\n\n if (existingEntry) {\n existingEntry.count += tableEntry.count;\n existingEntry.occurrences = existingEntry.occurrences.concat(tableEntry.occurrences);\n } else {\n newTableData.push({\n items: [firstItem],\n count: tableEntry.count,\n occurrences: tableEntry.occurrences,\n status: tableEntry.status,\n });\n }\n });\n\n return newTableData;\n }, [showAdditionalItems, tableData]);\n\n const filteredTableData: InventoryTableData[] = useMemo(() => {\n return filterItemData(reducedTableData, statusFilter, textFilter);\n }, [reducedTableData, statusFilter, textFilter]);\n\n const allColumns: ColumnDef[] = useMemo(() => {\n if (!showAdditionalItems) return columns;\n\n const numberOfAdditionalItems = additionalItemsLabels?.tableHeaders?.length;\n if (!numberOfAdditionalItems) return columns;\n\n const additionalColumns: ColumnDef[] = [];\n\n for (let index = 0; index < numberOfAdditionalItems; index++) {\n additionalColumns.push(\n inventoryAdditionalItemColumn(\n additionalItemsLabels?.tableHeaders?.[index] || 'Additional Item',\n index + 1,\n ),\n );\n }\n\n return [...additionalColumns, ...columns];\n }, [additionalItemsLabels?.tableHeaders, columns, showAdditionalItems]);\n\n useEffect(() => {\n setSelectedItem([]);\n }, [filteredTableData]);\n\n const rowClickHandler = (\n row: RowContents,\n table: TableContents,\n ) => {\n table.setRowSelection(() => {\n const newSelection: RowSelectionState = {};\n newSelection[row.index] = true;\n return newSelection;\n });\n\n setSelectedItem(row.original.items);\n };\n\n const handleScopeChange = (value: string) => {\n if (value === 'book' || value === 'chapter' || value === 'verse') {\n onScopeChange(value);\n } else {\n throw new Error(`Invalid scope value: ${value}`);\n }\n };\n\n const handleStatusFilterChange = (value: string) => {\n if (value === 'all' || value === 'approved' || value === 'unapproved' || value === 'unknown') {\n setStatusFilter(value);\n } else {\n throw new Error(`Invalid status filter value: ${value}`);\n }\n };\n\n const occurrenceData: InventoryItemOccurrence[] = useMemo(() => {\n if (reducedTableData.length === 0 || selectedItem.length === 0) return [];\n const occurrence = reducedTableData.filter((tableEntry: InventoryTableData) => {\n return deepEqual(\n showAdditionalItems ? tableEntry.items : [tableEntry.items[0]],\n selectedItem,\n );\n });\n if (occurrence.length > 1) throw new Error('Selected item is not unique');\n return occurrence[0].occurrences;\n }, [selectedItem, showAdditionalItems, reducedTableData]);\n\n return (\n
    \n
    \n handleStatusFilterChange(value)}\n defaultValue={statusFilter}\n >\n \n \n \n \n {allItemsText}\n {approvedItemsText}\n {unapprovedItemsText}\n {unknownItemsText}\n \n \n \n {\n setTextFilter(event.target.value);\n }}\n />\n {additionalItemsLabels && (\n
    \n {\n setSelectedItem([]);\n setShowAdditionalItems(checked);\n }}\n />\n \n
    \n )}\n
    \n
    \n \n
    \n {occurrenceData.length > 0 && (\n
    \n \n
    \n )}\n
    \n );\n}\n","import { Input } from '@/components/shadcn-ui/input';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { useState } from 'react';\n\nexport type SearchBarProps = {\n className?: string;\n /**\n * Callback fired to handle the search query when button pressed\n *\n * @param searchQuery\n */\n onSearch: (searchQuery: string) => void;\n\n /** Optional string that appears in the search bar without a search string */\n placeholder?: string;\n\n /** Optional boolean to set the input base to full width */\n isFullWidth?: boolean;\n};\n\nexport default function SearchBar({\n className,\n onSearch,\n placeholder,\n isFullWidth,\n}: SearchBarProps) {\n const [searchQuery, setSearchQuery] = useState('');\n\n const handleInputChange = (searchString: string) => {\n setSearchQuery(searchString);\n onSearch(searchString);\n };\n\n return (\n handleInputChange(e.target.value)}\n />\n );\n}\n","// adapted from: https://github.com/shadcn-ui/ui/discussions/752\n\n'use client';\n\nimport { TabsContentProps, TabsListProps, TabsTriggerProps } from '@/components/shadcn-ui/tabs';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport * as TabsPrimitive from '@radix-ui/react-tabs';\nimport React from 'react';\n\nexport type VerticalTabsProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport type LeftTabsTriggerProps = TabsTriggerProps & {\n value: string;\n ref?: React.Ref;\n};\n\nexport const VerticalTabs = React.forwardRef<\n React.ElementRef,\n VerticalTabsProps\n>(({ className, ...props }, ref) => (\n \n));\n\nVerticalTabs.displayName = TabsPrimitive.List.displayName;\n\nexport const VerticalTabsList = React.forwardRef<\n React.ElementRef,\n TabsListProps\n>(({ className, ...props }, ref) => (\n \n));\nVerticalTabsList.displayName = TabsPrimitive.List.displayName;\n\nexport const VerticalTabsTrigger = React.forwardRef<\n React.ElementRef,\n LeftTabsTriggerProps\n>(({ className, ...props }, ref) => (\n \n));\n\nexport const VerticalTabsContent = React.forwardRef<\n React.ElementRef,\n TabsContentProps\n>(({ className, ...props }, ref) => (\n \n));\nVerticalTabsContent.displayName = TabsPrimitive.Content.displayName;\n","import SearchBar from '@/components/basics/search-bar.component';\nimport {\n VerticalTabs,\n VerticalTabsContent,\n VerticalTabsList,\n VerticalTabsTrigger,\n} from '@/components/basics/tabs-vertical';\nimport { ReactNode } from 'react';\n\nexport type TabKeyValueContent = {\n key: string;\n value: string;\n content: ReactNode;\n};\n\nexport type TabNavigationContentSearchProps = {\n /** List of values and keys for each tab this component should provide */\n tabList: TabKeyValueContent[];\n\n /** Handler to run when the value of the search bar changes */\n onSearch: (searchQuery: string) => void;\n\n /** Optional placeholder for the search bar */\n searchPlaceholder?: string;\n\n /** Optional title to include in the header */\n headerTitle?: string;\n\n /** Optional flag to make the search bar appear full width */\n isSearchBarFullWidth?: boolean;\n\n /** Text direction ltr or rtl */\n direction?: 'ltr' | 'rtl';\n};\n\nexport default function TabNavigationContentSearch({\n tabList,\n onSearch,\n searchPlaceholder,\n headerTitle,\n isSearchBarFullWidth = false,\n direction = 'ltr',\n}: TabNavigationContentSearchProps) {\n return (\n
    \n
    \n {headerTitle ?

    {headerTitle}

    : ''}\n \n
    \n \n \n {tabList.map((tab) => (\n \n {tab.value}\n \n ))}\n \n {tabList.map((tab) => (\n \n {tab.content}\n \n ))}\n \n
    \n );\n}\n","import React from 'react';\nimport * as SeparatorPrimitive from '@radix-ui/react-separator';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Separator = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, orientation = 'horizontal', decorative = true, ...props }, ref) => (\n \n));\nSeparator.displayName = SeparatorPrimitive.Root.displayName;\n\nexport { Separator };\n","'use client';\n\nimport * as React from 'react';\nimport * as SheetPrimitive from '@radix-ui/react-dialog';\nimport { cva, type VariantProps } from 'class-variance-authority';\nimport { X } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Sheet = SheetPrimitive.Root;\n\nconst SheetTrigger = SheetPrimitive.Trigger;\n\nconst SheetClose = SheetPrimitive.Close;\n\nconst SheetPortal = SheetPrimitive.Portal;\n\nconst SheetOverlay = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSheetOverlay.displayName = SheetPrimitive.Overlay.displayName;\n\nconst sheetVariants = cva(\n 'pr-twp tw-fixed tw-z-50 tw-gap-4 tw-bg-background tw-p-6 tw-shadow-lg tw-transition tw-ease-in-out data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-duration-300 data-[state=open]:tw-duration-500',\n {\n variants: {\n side: {\n top: 'tw-inset-x-0 tw-top-0 tw-border-b data-[state=closed]:tw-slide-out-to-top data-[state=open]:tw-slide-in-from-top',\n bottom:\n 'tw-inset-x-0 tw-bottom-0 tw-border-t data-[state=closed]:tw-slide-out-to-bottom data-[state=open]:tw-slide-in-from-bottom',\n left: 'tw-inset-y-0 tw-left-0 tw-h-full tw-w-3/4 tw-border-r data-[state=closed]:tw-slide-out-to-left data-[state=open]:tw-slide-in-from-left sm:tw-max-w-sm',\n right:\n 'tw-inset-y-0 tw-right-0 tw-h-full tw-w-3/4 tw- tw-border-l data-[state=closed]:tw-slide-out-to-right data-[state=open]:tw-slide-in-from-right sm:tw-max-w-sm',\n },\n },\n defaultVariants: {\n side: 'right',\n },\n },\n);\n\ninterface SheetContentProps\n extends React.ComponentPropsWithoutRef,\n VariantProps {}\n\nconst SheetContent = React.forwardRef<\n React.ElementRef,\n SheetContentProps\n>(({ side = 'right', className, children, ...props }, ref) => (\n \n \n \n {children}\n \n \n Close\n \n \n \n));\nSheetContent.displayName = SheetPrimitive.Content.displayName;\n\nfunction SheetHeader({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nSheetHeader.displayName = 'SheetHeader';\n\nfunction SheetFooter({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nSheetFooter.displayName = 'SheetFooter';\n\nconst SheetTitle = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSheetTitle.displayName = SheetPrimitive.Title.displayName;\n\nconst SheetDescription = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSheetDescription.displayName = SheetPrimitive.Description.displayName;\n\nexport {\n Sheet,\n SheetPortal,\n SheetOverlay,\n SheetTrigger,\n SheetClose,\n SheetContent,\n SheetHeader,\n SheetFooter,\n SheetTitle,\n SheetDescription,\n};\n","import React from 'react';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nfunction Skeleton({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\n\nexport { Skeleton };\n","import React from 'react';\nimport * as TooltipPrimitive from '@radix-ui/react-tooltip';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst TooltipProvider = TooltipPrimitive.Provider;\n\nconst Tooltip = TooltipPrimitive.Root;\n\nconst TooltipTrigger = TooltipPrimitive.Trigger;\n\nconst TooltipContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, sideOffset = 4, ...props }, ref) => (\n \n));\nTooltipContent.displayName = TooltipPrimitive.Content.displayName;\n\nexport { Tooltip, TooltipTrigger, TooltipContent, TooltipProvider };\n","import * as React from 'react';\n\nconst MOBILE_BREAKPOINT = 768;\n\nexport default function useIsMobile() {\n const [isMobile, setIsMobile] = React.useState(undefined);\n\n React.useEffect(() => {\n const mql = window.matchMedia(`(max-width: ${MOBILE_BREAKPOINT - 1}px)`);\n const onChange = () => {\n setIsMobile(window.innerWidth < MOBILE_BREAKPOINT);\n };\n mql.addEventListener('change', onChange);\n setIsMobile(window.innerWidth < MOBILE_BREAKPOINT);\n return () => mql.removeEventListener('change', onChange);\n }, []);\n\n return !!isMobile;\n}\n","import React from 'react';\nimport { Slot } from '@radix-ui/react-slot';\nimport { VariantProps, cva } from 'class-variance-authority';\nimport { PanelLeft } from 'lucide-react';\n\nimport { Button } from '@/components/shadcn-ui/button';\nimport { Input } from '@/components/shadcn-ui/input';\nimport { Separator } from '@/components/shadcn-ui/separator';\nimport { Sheet, SheetContent } from '@/components/shadcn-ui/sheet';\nimport { Skeleton } from '@/components/shadcn-ui/skeleton';\nimport {\n Tooltip,\n TooltipContent,\n TooltipProvider,\n TooltipTrigger,\n} from '@/components/shadcn-ui/tooltip';\nimport useIsMobile from '@/components/hooks/use-mobile';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst SIDEBAR_COOKIE_NAME = 'sidebar:state';\nconst SIDEBAR_COOKIE_MAX_AGE = 60 * 60 * 24 * 7;\nconst SIDEBAR_WIDTH = '16rem';\nconst SIDEBAR_WIDTH_MOBILE = '18rem';\nconst SIDEBAR_WIDTH_ICON = '3rem';\nconst SIDEBAR_KEYBOARD_SHORTCUT = 'b';\n\ntype SidebarContextProps = {\n state: 'expanded' | 'collapsed';\n open: boolean;\n setOpen: (open: boolean) => void;\n openMobile: boolean;\n setOpenMobile: (open: boolean) => void;\n isMobile: boolean;\n toggleSidebar: () => void;\n};\n\nconst SidebarContext = React.createContext(undefined);\n\nfunction useSidebar() {\n const context = React.useContext(SidebarContext);\n if (!context) {\n throw new Error('useSidebar must be used within a SidebarProvider.');\n }\n\n return context;\n}\n\nconst SidebarProvider = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & {\n defaultOpen?: boolean;\n open?: boolean;\n onOpenChange?: (open: boolean) => void;\n }\n>(\n (\n {\n defaultOpen = true,\n open: openProp,\n onOpenChange: setOpenProp,\n className,\n style,\n children,\n ...props\n },\n ref,\n ) => {\n const isMobile = useIsMobile();\n const [openMobile, setOpenMobile] = React.useState(false);\n\n // This is the internal state of the sidebar.\n // We use openProp and setOpenProp for control from outside the component.\n const [_open, _setOpen] = React.useState(defaultOpen);\n const isOpen = openProp ?? _open;\n const setOpen = React.useCallback(\n (value: boolean | ((value: boolean) => boolean)) => {\n const openState = typeof value === 'function' ? value(isOpen) : value;\n if (setOpenProp) {\n setOpenProp(openState);\n } else {\n _setOpen(openState);\n }\n\n // This sets the cookie to keep the sidebar state.\n document.cookie = `${SIDEBAR_COOKIE_NAME}=${openState}; path=/; max-age=${SIDEBAR_COOKIE_MAX_AGE}`;\n },\n [setOpenProp, isOpen],\n );\n\n // Helper to toggle the sidebar.\n const toggleSidebar = React.useCallback(() => {\n return isMobile ? setOpenMobile((open) => !open) : setOpen((open) => !open);\n }, [isMobile, setOpen, setOpenMobile]);\n\n // Adds a keyboard shortcut to toggle the sidebar.\n React.useEffect(() => {\n const handleKeyDown = (event: KeyboardEvent) => {\n if (event.key === SIDEBAR_KEYBOARD_SHORTCUT && (event.metaKey || event.ctrlKey)) {\n event.preventDefault();\n toggleSidebar();\n }\n };\n\n window.addEventListener('keydown', handleKeyDown);\n return () => window.removeEventListener('keydown', handleKeyDown);\n }, [toggleSidebar]);\n\n // We add a state so that we can do data-state=\"expanded\" or \"collapsed\".\n // This makes it easier to style the sidebar with Tailwind classes.\n const state = isOpen ? 'expanded' : 'collapsed';\n\n const contextValue = React.useMemo(\n () => ({\n state,\n open: isOpen,\n setOpen,\n isMobile,\n openMobile,\n setOpenMobile,\n toggleSidebar,\n }),\n [state, isOpen, setOpen, isMobile, openMobile, setOpenMobile, toggleSidebar],\n );\n\n return (\n \n \n \n {children}\n
    \n \n \n );\n },\n);\nSidebarProvider.displayName = 'SidebarProvider';\n\nconst Sidebar = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & {\n side?: 'left' | 'right';\n variant?: 'sidebar' | 'floating' | 'inset';\n collapsible?: 'offcanvas' | 'icon' | 'none';\n }\n>(\n (\n {\n side = 'left',\n variant = 'sidebar',\n collapsible = 'offcanvas',\n className,\n children,\n ...props\n },\n ref,\n ) => {\n const { isMobile, state, openMobile, setOpenMobile } = useSidebar();\n\n if (collapsible === 'none') {\n return (\n \n {children}\n
    \n );\n }\n\n if (isMobile) {\n return (\n \n button]:tw-hidden\"\n style={\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n {\n '--sidebar-width': SIDEBAR_WIDTH_MOBILE,\n } as React.CSSProperties\n }\n side={side}\n >\n
    {children}
    \n \n
    \n );\n }\n\n return (\n \n {/* This is what handles the sidebar gap on desktop */}\n \n \n \n {children}\n
    \n
    \n
    \n );\n },\n);\nSidebar.displayName = 'Sidebar';\n\nconst SidebarTrigger = React.forwardRef<\n React.ElementRef,\n React.ComponentProps\n>(({ className, onClick, ...props }, ref) => {\n const { toggleSidebar } = useSidebar();\n\n return (\n {\n onClick?.(event);\n toggleSidebar();\n }}\n {...props}\n >\n \n Toggle Sidebar\n \n );\n});\nSidebarTrigger.displayName = 'SidebarTrigger';\n\nconst SidebarRail = React.forwardRef>(\n ({ className, ...props }, ref) => {\n const { toggleSidebar } = useSidebar();\n\n return (\n \n );\n },\n);\nSidebarRail.displayName = 'SidebarRail';\n\nconst SidebarInset = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarInset.displayName = 'SidebarInset';\n\nconst SidebarInput = React.forwardRef<\n React.ElementRef,\n React.ComponentProps\n>(({ className, ...props }, ref) => {\n return (\n \n );\n});\nSidebarInput.displayName = 'SidebarInput';\n\nconst SidebarHeader = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarHeader.displayName = 'SidebarHeader';\n\nconst SidebarFooter = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarFooter.displayName = 'SidebarFooter';\n\nconst SidebarSeparator = React.forwardRef<\n React.ElementRef,\n React.ComponentProps\n>(({ className, ...props }, ref) => {\n return (\n \n );\n});\nSidebarSeparator.displayName = 'SidebarSeparator';\n\nconst SidebarContent = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarContent.displayName = 'SidebarContent';\n\nconst SidebarGroup = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarGroup.displayName = 'SidebarGroup';\n\nconst SidebarGroupLabel = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & { asChild?: boolean }\n>(({ className, asChild = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'div';\n\n return (\n svg]:tw-size-4 [&>svg]:tw-shrink-0',\n 'group-data-[collapsible=icon]:tw--mt-8 group-data-[collapsible=icon]:tw-opacity-0',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarGroupLabel.displayName = 'SidebarGroupLabel';\n\nconst SidebarGroupAction = React.forwardRef<\n HTMLButtonElement,\n React.ComponentProps<'button'> & { asChild?: boolean }\n>(({ className, asChild = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'button';\n\n return (\n svg]:tw-size-4 [&>svg]:tw-shrink-0',\n // Increases the hit area of the button on mobile.\n 'after:tw-absolute after:tw--inset-2 after:md:tw-hidden',\n 'group-data-[collapsible=icon]:tw-hidden',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarGroupAction.displayName = 'SidebarGroupAction';\n\nconst SidebarGroupContent = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarGroupContent.displayName = 'SidebarGroupContent';\n\nconst SidebarMenu = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenu.displayName = 'SidebarMenu';\n\nconst SidebarMenuItem = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenuItem.displayName = 'SidebarMenuItem';\n\nconst sidebarMenuButtonVariants = cva(\n // Removed data-[active=true]:tw-bg-sidebar-accent\n 'tw-peer/menu-button tw-flex tw-w-full tw-items-center tw-gap-2 tw-overflow-hidden tw-rounded-md tw-p-2 tw-text-left tw-text-sm tw-outline-none tw-ring-sidebar-ring tw-transition-[width,height,padding] hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground focus-visible:tw-ring-2 active:tw-bg-sidebar-accent active:tw-text-sidebar-accent-foreground disabled:tw-pointer-events-none disabled:tw-opacity-50 tw-group-has-[[data-sidebar=menu-action]]/menu-item:pr-8 aria-disabled:tw-pointer-events-none aria-disabled:tw-opacity-50 data-[active=true]:tw-font-medium data-[active=true]:tw-text-sidebar-accent-foreground data-[state=open]:hover:tw-bg-sidebar-accent data-[state=open]:hover:tw-text-sidebar-accent-foreground group-data-[collapsible=icon]:tw-!size-8 group-data-[collapsible=icon]:tw-!p-2 [&>span:last-child]:tw-truncate [&>svg]:tw-size-4 [&>svg]:tw-shrink-0',\n {\n variants: {\n variant: {\n default: 'hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground',\n outline:\n 'tw-bg-background tw-shadow-[0_0_0_1px_hsl(var(--sidebar-border))] hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground hover:tw-shadow-[0_0_0_1px_hsl(var(--sidebar-accent))]',\n },\n size: {\n default: 'tw-h-8 tw-text-sm',\n sm: 'tw-h-7 tw-text-xs',\n lg: 'tw-h-12 tw-text-sm group-data-[collapsible=icon]:tw-!p-0',\n },\n },\n defaultVariants: {\n variant: 'default',\n size: 'default',\n },\n },\n);\n\nconst SidebarMenuButton = React.forwardRef<\n HTMLButtonElement,\n React.ComponentProps<'button'> & {\n asChild?: boolean;\n isActive?: boolean;\n tooltip?: string | React.ComponentProps;\n } & VariantProps\n>(\n (\n {\n asChild = false,\n isActive = false,\n variant = 'default',\n size = 'default',\n tooltip,\n className,\n ...props\n },\n ref,\n ) => {\n const Comp = asChild ? Slot : 'button';\n const { isMobile, state } = useSidebar();\n\n const button = (\n \n );\n\n if (!tooltip) {\n return button;\n }\n\n if (typeof tooltip === 'string') {\n // eslint-disable-next-line no-param-reassign\n tooltip = {\n children: tooltip,\n };\n }\n\n return (\n \n {button}\n \n );\n },\n);\nSidebarMenuButton.displayName = 'SidebarMenuButton';\n\nconst SidebarMenuAction = React.forwardRef<\n HTMLButtonElement,\n React.ComponentProps<'button'> & {\n asChild?: boolean;\n showOnHover?: boolean;\n }\n>(({ className, asChild = false, showOnHover = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'button';\n\n return (\n svg]:tw-size-4 [&>svg]:tw-shrink-0',\n // Increases the hit area of the button on mobile.\n 'after:tw-absolute after:tw--inset-2 after:md:tw-hidden',\n 'tw-peer-data-[size=sm]/menu-button:top-1',\n 'tw-peer-data-[size=default]/menu-button:top-1.5',\n 'tw-peer-data-[size=lg]/menu-button:top-2.5',\n 'group-data-[collapsible=icon]:tw-hidden',\n showOnHover &&\n 'tw-group-focus-within/menu-item:opacity-100 tw-group-hover/menu-item:opacity-100 tw-peer-data-[active=true]/menu-button:text-sidebar-accent-foreground data-[state=open]:tw-opacity-100 md:tw-opacity-0',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarMenuAction.displayName = 'SidebarMenuAction';\n\nconst SidebarMenuBadge = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenuBadge.displayName = 'SidebarMenuBadge';\n\nconst SidebarMenuSkeleton = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & {\n showIcon?: boolean;\n }\n>(({ className, showIcon = false, ...props }, ref) => {\n // Random width between 50 to 90%.\n const width = React.useMemo(() => {\n return `${Math.floor(Math.random() * 40) + 50}%`;\n }, []);\n\n return (\n \n {showIcon && (\n \n )}\n \n
    \n );\n});\nSidebarMenuSkeleton.displayName = 'SidebarMenuSkeleton';\n\nconst SidebarMenuSub = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenuSub.displayName = 'SidebarMenuSub';\n\nconst SidebarMenuSubItem = React.forwardRef>(\n ({ ...props }, ref) =>
  • ,\n);\nSidebarMenuSubItem.displayName = 'SidebarMenuSubItem';\n\nconst SidebarMenuSubButton = React.forwardRef<\n HTMLAnchorElement,\n React.ComponentProps<'a'> & {\n asChild?: boolean;\n size?: 'sm' | 'md';\n isActive?: boolean;\n }\n>(({ asChild = false, size = 'md', isActive, className, ...props }, ref) => {\n const Comp = asChild ? Slot : 'a';\n\n return (\n span:last-child]:tw-truncate [&>svg]:tw-size-4 [&>svg]:tw-shrink-0 [&>svg]:tw-text-sidebar-accent-foreground',\n 'data-[active=true]:tw-bg-sidebar-accent data-[active=true]:tw-text-sidebar-accent-foreground',\n size === 'sm' && 'tw-text-xs',\n size === 'md' && 'tw-text-sm',\n 'group-data-[collapsible=icon]:tw-hidden',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarMenuSubButton.displayName = 'SidebarMenuSubButton';\n\nexport {\n Sidebar,\n SidebarContent,\n SidebarFooter,\n SidebarGroup,\n SidebarGroupAction,\n SidebarGroupContent,\n SidebarGroupLabel,\n SidebarHeader,\n SidebarInput,\n SidebarInset,\n SidebarMenu,\n SidebarMenuAction,\n SidebarMenuBadge,\n SidebarMenuButton,\n SidebarMenuItem,\n SidebarMenuSkeleton,\n SidebarMenuSub,\n SidebarMenuSubButton,\n SidebarMenuSubItem,\n SidebarProvider,\n SidebarRail,\n SidebarSeparator,\n SidebarTrigger,\n useSidebar,\n};\n","import ComboBox, { ComboBoxOption } from '@/components/basics/combo-box.component';\nimport {\n Sidebar,\n SidebarContent,\n SidebarGroup,\n SidebarGroupLabel,\n SidebarGroupContent,\n SidebarMenu,\n SidebarMenuItem,\n SidebarMenuButton,\n} from '@/components/shadcn-ui/sidebar';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { useCallback } from 'react';\n\nexport type SelectedSettingsSidebarItem = {\n label: string;\n projectId?: string;\n};\n\nexport type ProjectOptions = { projectId: string; projectName: string };\n\nexport type SettingsSidebarProps = {\n /** Optional id for testing */\n id?: string;\n\n /** Extension labels from contribution */\n extensionLabels: string[];\n\n /** Project names and ids */\n projectOptions: ProjectOptions[];\n\n /** Handler for selecting a sidebar item */\n handleSelectSidebarItem: (key: string, projectId?: string) => void;\n\n /** The current selected value in the sidebar */\n selectedSidebarItem: SelectedSettingsSidebarItem;\n};\n\nexport default function SettingsSidebar({\n id,\n extensionLabels,\n projectOptions,\n handleSelectSidebarItem,\n selectedSidebarItem,\n}: SettingsSidebarProps) {\n const handleSelectItem = useCallback(\n (item: string, projectId?: string) => {\n handleSelectSidebarItem(item, projectId);\n },\n [handleSelectSidebarItem],\n );\n\n const getProjectNameFromProjectId = useCallback(\n (projectId: string) => {\n const project = projectOptions.find((option) => option.projectId === projectId);\n return project ? project.projectName : projectId;\n },\n [projectOptions],\n );\n\n const getIsActive: (label: string) => boolean = useCallback(\n (label: string) => !selectedSidebarItem.projectId && label === selectedSidebarItem.label,\n [selectedSidebarItem],\n );\n\n return (\n \n \n \n Extensions\n \n \n {extensionLabels.map((label) => (\n \n handleSelectItem(label, undefined)}\n isActive={getIsActive(label)}\n >\n {label}\n \n \n ))}\n \n \n \n \n Projects\n \n option.projectId)}\n getOptionLabel={(projectId: ComboBoxOption) => {\n // This function expects a ComboBoxOption, but we know it is a string\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n return getProjectNameFromProjectId(projectId as string);\n }}\n buttonPlaceholder=\"Type or select project\"\n onChange={(projectId: string) => {\n const selectedProjectName = getProjectNameFromProjectId(projectId);\n handleSelectItem(selectedProjectName, projectId);\n }}\n value={selectedSidebarItem?.projectId ?? undefined}\n />\n \n \n \n \n );\n}\n","import { SidebarInset, SidebarProvider } from '@/components/shadcn-ui/sidebar';\nimport { PropsWithChildren } from 'react';\nimport SearchBar from '@/components/basics/search-bar.component';\nimport SettingsSidebar, { SettingsSidebarProps } from './settings-sidebar.component';\n\nexport type SettingsSidebarContentSearchProps = SettingsSidebarProps &\n PropsWithChildren & {\n /** Optional id for testing */\n id?: string;\n\n /** Text direction ltr or rtl */\n direction?: 'ltr' | 'rtl';\n\n /** Handler to run when the value of the search bar changes */\n onSearch: (searchQuery: string) => void;\n };\n\nexport default function SettingsSidebarContentSearch({\n id,\n direction = 'ltr',\n extensionLabels,\n projectOptions,\n children,\n handleSelectSidebarItem,\n selectedSidebarItem,\n onSearch,\n}: SettingsSidebarContentSearchProps) {\n return (\n
    \n
    \n \n
    \n \n \n {children}\n \n
    \n );\n}\n","import { Button } from '@/components/shadcn-ui/button';\nimport {\n Select,\n SelectContent,\n SelectGroup,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\nimport {\n Table,\n TableBody,\n TableCell,\n TableHead,\n TableHeader,\n TableRow,\n} from '@/components/shadcn-ui/table';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Canon } from '@sillsdev/scripture';\nimport {\n Cell,\n ColumnDef,\n flexRender,\n getCoreRowModel,\n getExpandedRowModel,\n getGroupedRowModel,\n getSortedRowModel,\n GroupingState,\n Row,\n RowSelectionState,\n SortingState,\n useReactTable,\n} from '@tanstack/react-table';\nimport '@/components/advanced/scripture-results-viewer/scripture-results-viewer.component.css';\nimport {\n compareScrRefs,\n formatScrRef,\n ScriptureSelection,\n scrRefToBBBCCCVVV,\n} from 'platform-bible-utils';\nimport { MouseEvent, useEffect, useMemo, useState } from 'react';\nimport { ChevronDown, ChevronLeft, ChevronRight } from 'lucide-react';\n\n/**\n * Information (e.g., a checking error or some other type of \"transient\" annotation) about something\n * noteworthy at a specific place in an instance of the Scriptures.\n */\nexport type ScriptureItemDetail = ScriptureSelection & {\n /**\n * Text of the error, note, etc. In the future, we might want to support something more than just\n * text so that a JSX element could be provided with a link or some other controls related to the\n * issue being reported.\n */\n detail: string;\n};\n\n/**\n * A uniquely identifiable source of results that can be displayed in the ScriptureResultsViewer.\n * Generally, the source will be a particular Scripture check, but there may be other types of\n * sources.\n */\nexport type ResultsSource = {\n /**\n * Uniquely identifies the source.\n *\n * @type {string}\n */\n id: string;\n\n /**\n * Name (potentially localized) of the source, suitable for display in the UI.\n *\n * @type {string}\n */\n displayName: string;\n};\n\nexport type ScriptureSrcItemDetail = ScriptureItemDetail & {\n /** Source/type of detail. Can be used for grouping. */\n source: ResultsSource;\n};\n\n/**\n * Represents a set of results keyed by Scripture reference. Generally, the source will be a\n * particular Scripture check, but this type also allows for other types of uniquely identifiable\n * sources.\n */\nexport type ResultsSet = {\n /**\n * The backing source associated with this set of results.\n *\n * @type {ResultsSource}\n */\n source: ResultsSource;\n\n /**\n * Array of Scripture item details (messages keyed by Scripture reference).\n *\n * @type {ScriptureItemDetail[]}\n */\n data: ScriptureItemDetail[];\n};\n\nconst scrBookColId = 'scrBook';\nconst scrRefColId = 'scrRef';\nconst typeColId = 'source';\nconst detailsColId = 'details';\n\nconst defaultScrRefColumnName = 'Scripture Reference';\nconst defaultScrBookGroupName = 'Scripture Book';\nconst defaultTypeColumnName = 'Type';\nconst defaultDetailsColumnName = 'Details';\n\nexport type ScriptureResultsViewerColumnInfo = {\n /** Optional header to display for the Reference column. Default value: 'Scripture Reference'. */\n scriptureReferenceColumnName?: string;\n\n /** Optional text to display to refer to the Scripture book group. Default value: 'Scripture Book'. */\n scriptureBookGroupName?: string;\n\n /** Optional header to display for the Type column. Default value: 'Type'. */\n typeColumnName?: string;\n\n /** Optional header to display for the Details column. Default value: 'Details' */\n detailsColumnName?: string;\n};\n\nexport type ScriptureResultsViewerProps = ScriptureResultsViewerColumnInfo & {\n /** Groups of ScriptureItemDetail objects from particular sources (e.g., Scripture checks) */\n sources: ResultsSet[];\n\n /** Flag indicating whether to display column headers. Default is false. */\n showColumnHeaders?: boolean;\n\n /** Flag indicating whether to display source column. Default is false. */\n showSourceColumn?: boolean;\n\n /** Callback function to notify when a row is selected */\n onRowSelected?: (selectedRow: ScriptureSrcItemDetail | undefined) => void;\n\n /** Text direction ltr or rtl */\n direction?: 'ltr' | 'rtl';\n};\n\nfunction getColumns(\n colInfo?: ScriptureResultsViewerColumnInfo,\n showSourceColumn?: boolean,\n): ColumnDef[] {\n const showSrcCol = showSourceColumn ?? false;\n return [\n {\n accessorFn: (row) =>\n `${Canon.bookNumberToId(row.start.bookNum)} ${row.start.chapterNum}:${row.start.verseNum}`,\n id: scrBookColId,\n header: colInfo?.scriptureReferenceColumnName ?? defaultScrRefColumnName,\n cell: (info) => {\n const row = info.row.original;\n if (info.row.getIsGrouped()) {\n return Canon.bookNumberToEnglishName(row.start.bookNum);\n }\n return info.row.groupingColumnId === scrBookColId ? formatScrRef(row.start) : undefined;\n },\n getGroupingValue: (row) => row.start.bookNum,\n sortingFn: (a, b) => {\n return compareScrRefs(a.original.start, b.original.start);\n },\n enableGrouping: true,\n },\n {\n accessorFn: (row) => formatScrRef(row.start),\n id: scrRefColId,\n header: undefined,\n cell: (info) => {\n const row = info.row.original;\n return info.row.getIsGrouped() ? undefined : formatScrRef(row.start);\n },\n sortingFn: (a, b) => {\n return compareScrRefs(a.original.start, b.original.start);\n },\n enableGrouping: false,\n },\n {\n accessorFn: (row) => row.source.displayName,\n id: typeColId,\n header: showSrcCol ? (colInfo?.typeColumnName ?? defaultTypeColumnName) : undefined,\n cell: (info) => (showSrcCol || info.row.getIsGrouped() ? info.getValue() : undefined),\n getGroupingValue: (row) => row.source.id,\n sortingFn: (a, b) =>\n a.original.source.displayName.localeCompare(b.original.source.displayName),\n enableGrouping: true,\n },\n {\n accessorFn: (row) => row.detail,\n id: detailsColId,\n header: colInfo?.detailsColumnName ?? defaultDetailsColumnName,\n cell: (info) => info.getValue(),\n enableGrouping: false,\n },\n ];\n}\n\nconst toRefOrRange = (scriptureSelection: ScriptureSelection) => {\n if (!('offset' in scriptureSelection.start))\n throw new Error('No offset available in range start');\n if (scriptureSelection.end && !('offset' in scriptureSelection.end))\n throw new Error('No offset available in range end');\n const { offset: offsetStart } = scriptureSelection.start;\n let offsetEnd: number = 0;\n if (scriptureSelection.end) ({ offset: offsetEnd } = scriptureSelection.end);\n if (\n !scriptureSelection.end ||\n compareScrRefs(scriptureSelection.start, scriptureSelection.end) === 0\n )\n return `${scrRefToBBBCCCVVV(scriptureSelection.start)}+${offsetStart}`;\n return `${scrRefToBBBCCCVVV(scriptureSelection.start)}+${offsetStart}-${scrRefToBBBCCCVVV(scriptureSelection.end)}+${offsetEnd}`;\n};\n\nconst getRowKey = (row: ScriptureSrcItemDetail) =>\n `${toRefOrRange({ start: row.start, end: row.end })} ${row.source.displayName} ${row.detail}`;\n\n/**\n * Component to display a combined list of detailed items from one or more sources, where the items\n * are keyed primarily by Scripture reference. This is particularly useful for displaying a list of\n * results from Scripture checks, but more generally could be used to display any \"results\" from any\n * source(s). The component allows for grouping by Scripture book, source, or both. By default, it\n * displays somewhat \"tree-like\" which allows it to be more horizontally compact and intuitive. But\n * it also has the option of displaying as a traditional table with column headings (with or without\n * the source column showing).\n */\nexport default function ScriptureResultsViewer({\n sources,\n showColumnHeaders = false,\n showSourceColumn = false,\n scriptureReferenceColumnName,\n scriptureBookGroupName,\n typeColumnName,\n detailsColumnName,\n onRowSelected,\n direction = 'ltr',\n}: ScriptureResultsViewerProps) {\n const [grouping, setGrouping] = useState([]);\n const [sorting, setSorting] = useState([{ id: scrBookColId, desc: false }]);\n const [rowSelection, setRowSelection] = useState({});\n\n const scriptureResults = useMemo(\n () =>\n sources.flatMap((source) => {\n return source.data.map((item) => ({\n ...item,\n source: source.source,\n }));\n }),\n [sources],\n );\n\n const columns = useMemo(\n () =>\n getColumns(\n {\n scriptureReferenceColumnName,\n typeColumnName,\n detailsColumnName,\n },\n showSourceColumn,\n ),\n [scriptureReferenceColumnName, typeColumnName, detailsColumnName, showSourceColumn],\n );\n\n useEffect(() => {\n // Ensure sorting is applied correctly when grouped by type\n if (grouping.includes(typeColId)) {\n setSorting([\n { id: typeColId, desc: false },\n { id: scrBookColId, desc: false },\n ]);\n } else {\n setSorting([{ id: scrBookColId, desc: false }]);\n }\n }, [grouping]);\n\n const table = useReactTable({\n data: scriptureResults,\n columns,\n state: {\n grouping,\n sorting,\n rowSelection,\n },\n onGroupingChange: setGrouping,\n onSortingChange: setSorting,\n onRowSelectionChange: setRowSelection,\n getExpandedRowModel: getExpandedRowModel(),\n getGroupedRowModel: getGroupedRowModel(),\n getCoreRowModel: getCoreRowModel(),\n getSortedRowModel: getSortedRowModel(),\n getRowId: getRowKey,\n autoResetExpanded: false,\n enableMultiRowSelection: false,\n enableSubRowSelection: false,\n });\n\n useEffect(() => {\n if (onRowSelected) {\n const selectedRows = table.getSelectedRowModel().rowsById;\n const keys = Object.keys(selectedRows);\n if (keys.length === 1) {\n const selectedRow = scriptureResults.find((row) => getRowKey(row) === keys[0]) || undefined;\n if (selectedRow) onRowSelected(selectedRow);\n }\n }\n }, [rowSelection, scriptureResults, onRowSelected, table]);\n\n // Define possible grouping options\n const scrBookGroupName = scriptureBookGroupName ?? defaultScrBookGroupName;\n const typeGroupName = typeColumnName ?? defaultTypeColumnName;\n\n const groupingOptions = [\n { label: 'No Grouping', value: [] },\n { label: `Group by ${scrBookGroupName}`, value: [scrBookColId] },\n { label: `Group by ${typeGroupName}`, value: [typeColId] },\n {\n label: `Group by ${scrBookGroupName} and ${typeGroupName}`,\n value: [scrBookColId, typeColId],\n },\n {\n label: `Group by ${typeGroupName} and ${scrBookGroupName}`,\n value: [typeColId, scrBookColId],\n },\n ];\n\n const handleSelectChange = (selectedGrouping: string) => {\n setGrouping(JSON.parse(selectedGrouping));\n };\n\n const handleRowClick = (row: Row, event: MouseEvent) => {\n if (!row.getIsGrouped() && !row.getIsSelected()) {\n row.getToggleSelectedHandler()(event);\n }\n };\n\n const getEvenOrOddBandingStyle = (row: Row, index: number) => {\n if (row.getIsGrouped()) return '';\n // UX has now said they don't think they want banding. I'm leaving in the code to\n // set even and odd styles, but there's nothing in the CSS to style them differently.\n // The \"even\" style used to also have tw-bg-neutral-300 (along with even) to create\n // a visual banding effect. That could be added back in if UX changes the decision.\n return cn('banded-row', index % 2 === 0 ? 'even' : 'odd');\n };\n\n const getIndent = (\n groupingState: GroupingState,\n row: Row,\n cell: Cell,\n ) => {\n if (groupingState?.length === 0 || row.depth < cell.column.getGroupedIndex()) return undefined;\n if (row.getIsGrouped()) {\n switch (row.depth) {\n case 1:\n return 'tw-ps-4';\n default:\n return undefined;\n }\n }\n switch (row.depth) {\n case 1:\n return 'tw-ps-8';\n case 2:\n return 'tw-ps-12';\n default:\n return undefined;\n }\n };\n\n return (\n
    \n {!showColumnHeaders && (\n {\n handleSelectChange(value);\n }}\n >\n \n \n \n \n \n {groupingOptions.map((option) => (\n \n {option.label}\n \n ))}\n \n \n \n )}\n \n {showColumnHeaders && (\n \n {table.getHeaderGroups().map((headerGroup) => (\n \n {headerGroup.headers\n .filter((h) => h.column.columnDef.header)\n .map((header) => (\n /* For sticky column headers to work, we probably need to change the default definition of the shadcn Table component. See https://github.com/shadcn-ui/ui/issues/1151 */\n \n {header.isPlaceholder ? undefined : (\n
    \n {header.column.getCanGroup() ? (\n \n {header.column.getIsGrouped() ? `🛑` : `👊 `}\n \n ) : undefined}{' '}\n {flexRender(header.column.columnDef.header, header.getContext())}\n
    \n )}\n
    \n ))}\n
    \n ))}\n
    \n )}\n \n {table.getRowModel().rows.map((row, rowIndex) => {\n return (\n handleRowClick(row, event)}\n >\n {row.getVisibleCells().map((cell) => {\n if (\n cell.getIsPlaceholder() ||\n (cell.column.columnDef.enableGrouping &&\n !cell.getIsGrouped() &&\n (cell.column.columnDef.id !== typeColId || !showSourceColumn))\n )\n return undefined;\n return (\n \n {(() => {\n if (cell.getIsGrouped()) {\n return (\n \n {row.getIsExpanded() && }\n {!row.getIsExpanded() &&\n (direction === 'ltr' ? : )}{' '}\n {flexRender(cell.column.columnDef.cell, cell.getContext())} (\n {row.subRows.length})\n \n );\n }\n\n // if (cell.getIsAggregated()) {\n // flexRender(\n // cell.column.columnDef.aggregatedCell ?? cell.column.columnDef.cell,\n // cell.getContext(),\n // );\n // }\n\n return flexRender(cell.column.columnDef.cell, cell.getContext());\n })()}\n \n );\n })}\n \n );\n })}\n \n
    \n
    \n );\n}\n","import {\n getLocalizeKeyForScrollGroupId,\n LanguageStrings,\n ScrollGroupId,\n} from 'platform-bible-utils';\nimport {\n Select,\n SelectContent,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\n\nconst DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS = {\n [getLocalizeKeyForScrollGroupId('undefined')]: 'Ø',\n [getLocalizeKeyForScrollGroupId(0)]: 'A',\n [getLocalizeKeyForScrollGroupId(1)]: 'B',\n [getLocalizeKeyForScrollGroupId(2)]: 'C',\n [getLocalizeKeyForScrollGroupId(3)]: 'D',\n [getLocalizeKeyForScrollGroupId(4)]: 'E',\n [getLocalizeKeyForScrollGroupId(5)]: 'F',\n [getLocalizeKeyForScrollGroupId(6)]: 'G',\n [getLocalizeKeyForScrollGroupId(7)]: 'H',\n [getLocalizeKeyForScrollGroupId(8)]: 'I',\n [getLocalizeKeyForScrollGroupId(9)]: 'J',\n [getLocalizeKeyForScrollGroupId(10)]: 'K',\n [getLocalizeKeyForScrollGroupId(11)]: 'L',\n [getLocalizeKeyForScrollGroupId(12)]: 'M',\n [getLocalizeKeyForScrollGroupId(13)]: 'N',\n [getLocalizeKeyForScrollGroupId(14)]: 'O',\n [getLocalizeKeyForScrollGroupId(15)]: 'P',\n [getLocalizeKeyForScrollGroupId(16)]: 'Q',\n [getLocalizeKeyForScrollGroupId(17)]: 'R',\n [getLocalizeKeyForScrollGroupId(18)]: 'S',\n [getLocalizeKeyForScrollGroupId(19)]: 'T',\n [getLocalizeKeyForScrollGroupId(20)]: 'U',\n [getLocalizeKeyForScrollGroupId(21)]: 'V',\n [getLocalizeKeyForScrollGroupId(22)]: 'W',\n [getLocalizeKeyForScrollGroupId(23)]: 'X',\n [getLocalizeKeyForScrollGroupId(24)]: 'Y',\n [getLocalizeKeyForScrollGroupId(25)]: 'Z',\n};\n\nexport type ScrollGroupSelectorProps = {\n /**\n * List of scroll group ids to show to the user. Either a {@link ScrollGroupId} or `undefined` for\n * no scroll group\n */\n availableScrollGroupIds: (ScrollGroupId | undefined)[];\n /** Currently selected scroll group id. `undefined` for no scroll group */\n scrollGroupId: ScrollGroupId | undefined;\n /** Callback function run when the user tries to change the scroll group id */\n onChangeScrollGroupId: (newScrollGroupId: ScrollGroupId | undefined) => void;\n /**\n * Localized strings to use for displaying scroll group ids. Must be an object whose keys are\n * `getLocalizeKeyForScrollGroupId(scrollGroupId)` for all scroll group ids (and `undefined` if\n * included) in {@link ScrollGroupSelectorProps.availableScrollGroupIds} and whose values are the\n * localized strings to use for those scroll group ids.\n *\n * Defaults to English localizations of English alphabet for scroll groups 0-25 (e.g. 0 is A) and\n * Ø for `undefined`. Will fill in any that are not provided with these English localizations.\n * Also, if any values match the keys, the English localization will be used. This is useful in\n * case you want to pass in a temporary version of the localized strings while your localized\n * strings load.\n *\n * @example\n *\n * ```typescript\n * const myScrollGroupIdLocalizedStrings = {\n * [getLocalizeKeyForScrollGroupId('undefined')]: 'Ø',\n * [getLocalizeKeyForScrollGroupId(0)]: 'A',\n * [getLocalizeKeyForScrollGroupId(1)]: 'B',\n * [getLocalizeKeyForScrollGroupId(2)]: 'C',\n * [getLocalizeKeyForScrollGroupId(3)]: 'D',\n * [getLocalizeKeyForScrollGroupId(4)]: 'E',\n * };\n * ```\n *\n * @example\n *\n * ```tsx\n * const availableScrollGroupIds = [undefined, 0, 1, 2, 3, 4];\n *\n * const localizeKeys = getLocalizeKeysForScrollGroupIds();\n *\n * const [localizedStrings] = useLocalizedStrings(localizeKeys);\n *\n * ...\n *\n * \n * ```\n */\n localizedStrings?: LanguageStrings;\n};\n\n/** Selector component for choosing a scroll group */\nexport default function ScrollGroupSelector({\n availableScrollGroupIds,\n scrollGroupId,\n onChangeScrollGroupId,\n localizedStrings = {},\n}: ScrollGroupSelectorProps) {\n const localizedStringsDefaulted = {\n ...DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS,\n ...Object.fromEntries(\n Object.entries(localizedStrings).map(\n ([localizedStringKey, localizedStringValue]: [string, string]) => [\n localizedStringKey,\n localizedStringKey === localizedStringValue &&\n localizedStringKey in DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS\n ? DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS[localizedStringKey]\n : localizedStringValue,\n ],\n ),\n ),\n };\n return (\n \n onChangeScrollGroupId(\n newScrollGroupString === 'undefined' ? undefined : parseInt(newScrollGroupString, 10),\n )\n }\n >\n \n \n \n \n {availableScrollGroupIds.map((scrollGroupOptionId) => (\n \n {localizedStringsDefaulted[getLocalizeKeyForScrollGroupId(scrollGroupOptionId)]}\n \n ))}\n \n \n );\n}\n","import { PropsWithChildren } from 'react';\nimport { Separator } from '@/components/shadcn-ui/separator';\n\n/** Props for the SettingsList component, currently just children */\ntype SettingsListProps = PropsWithChildren;\n\n/**\n * SettingsList component is a wrapper for list items. Rendered with a formatted div\n *\n * @param children To populate the list with\n * @returns Formatted div encompassing the children\n */\nexport function SettingsList({ children }: SettingsListProps) {\n return
    {children}
    ;\n}\n\n/** Props for SettingsListItem component */\ntype SettingsListItemProps = PropsWithChildren & {\n /** Primary text of the list item */\n primary: string;\n\n /** Optional text of the list item */\n secondary?: string | undefined;\n\n /** Optional boolean to display a message if the children aren't loaded yet. Defaults to false */\n isLoading?: boolean;\n\n /** Optional message to display if isLoading */\n loadingMessage?: string;\n};\n\n/**\n * SettingsListItem component is a common list item. Rendered with a formatted div\n *\n * @param primary Primary text of the list item\n * @param secondary Optional secondary text of the list item\n * @param isLoading Optional, to display a message if the action component isn't generated yet,\n * defaults to false\n * @param children The action component(s) to provide for this item\n * @param loadingMessage Optional, message to display if isLoading\n * @returns Formatted div encompassing the list item content\n */\nexport function SettingsListItem({\n primary,\n secondary,\n children,\n isLoading = false,\n loadingMessage,\n}: SettingsListItemProps) {\n return (\n
    \n
    \n

    {primary}

    \n

    \n {secondary}\n

    \n
    \n\n {isLoading ? (\n

    {loadingMessage}

    \n ) : (\n
    {children}
    \n )}\n
    \n );\n}\n\n/** Props for SettingsListHeader component */\ntype SettingsListHeaderProps = {\n /** The primary text of the list header */\n primary: string;\n\n /** Optional secondary text of the list header */\n secondary?: string | undefined;\n\n /** Optional boolean to include a separator underneath the secondary text. Defaults to false */\n includeSeparator?: boolean;\n};\n\n/**\n * SettingsListHeader component displays text above the list\n *\n * @param primary The primary text of the list header\n * @param secondary Optional secondary text of the list header\n * @param includeSeparator Optional boolean to include a separator underneath the secondary text.\n * Defaults to false\n * @returns Formatted div with list header content\n */\nexport function SettingsListHeader({\n primary,\n secondary,\n includeSeparator = false,\n}: SettingsListHeaderProps) {\n return (\n
    \n
    \n

    {primary}

    \n

    {secondary}

    \n
    \n {includeSeparator ? : ''}\n
    \n );\n}\n","import Checkbox from '@/components/shadcn-ui/checkbox';\nimport { Label } from '@/components/shadcn-ui/label';\n\nexport type ChecklistProps = {\n /** Optional string representing the id attribute of the Checklist */\n id?: string;\n /** Optional string representing CSS class name(s) for styling */\n className?: string;\n /** Array of strings representing the checkable items */\n listItems: string[];\n /** Array of strings representing the checked items */\n selectedListItems: string[];\n /**\n * Function that is called when a checkbox item is selected or deselected\n *\n * @param item The string description for this item\n * @param selected True if selected, false if not selected\n */\n handleSelectListItem: (item: string, selected: boolean) => void;\n\n /**\n * Optional function creates a label for a provided checkable item\n *\n * @param item The item for which a label is to be created\n * @returns A string representing the label text for the checkbox associated with that item\n */\n createLabel?: (item: string) => string;\n};\n\n/** Renders a list of checkboxes. Each checkbox corresponds to an item from the `listItems` array. */\nexport default function Checklist({\n id,\n className,\n listItems,\n selectedListItems,\n handleSelectListItem,\n createLabel,\n}: ChecklistProps) {\n return (\n
    \n {listItems.map((item) => (\n
    \n handleSelectListItem(item, value)}\n />\n \n
    \n ))}\n
    \n );\n}\n","function _interopRequireDefault(obj) {\n return obj && obj.__esModule ? obj : {\n \"default\": obj\n };\n}\nmodule.exports = _interopRequireDefault, module.exports.__esModule = true, module.exports[\"default\"] = module.exports;","export default function chainPropTypes(propType1, propType2) {\n if (process.env.NODE_ENV === 'production') {\n return () => null;\n }\n return function validate(...args) {\n return propType1(...args) || propType2(...args);\n };\n}","export default function _extends() {\n _extends = Object.assign ? Object.assign.bind() : function (target) {\n for (var i = 1; i < arguments.length; i++) {\n var source = arguments[i];\n for (var key in source) {\n if (Object.prototype.hasOwnProperty.call(source, key)) {\n target[key] = source[key];\n }\n }\n }\n return target;\n };\n return _extends.apply(this, arguments);\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\n// https://github.com/sindresorhus/is-plain-obj/blob/main/index.js\nexport function isPlainObject(item) {\n if (typeof item !== 'object' || item === null) {\n return false;\n }\n const prototype = Object.getPrototypeOf(item);\n return (prototype === null || prototype === Object.prototype || Object.getPrototypeOf(prototype) === null) && !(Symbol.toStringTag in item) && !(Symbol.iterator in item);\n}\nfunction deepClone(source) {\n if (!isPlainObject(source)) {\n return source;\n }\n const output = {};\n Object.keys(source).forEach(key => {\n output[key] = deepClone(source[key]);\n });\n return output;\n}\nexport default function deepmerge(target, source, options = {\n clone: true\n}) {\n const output = options.clone ? _extends({}, target) : target;\n if (isPlainObject(target) && isPlainObject(source)) {\n Object.keys(source).forEach(key => {\n // Avoid prototype pollution\n if (key === '__proto__') {\n return;\n }\n if (isPlainObject(source[key]) && key in target && isPlainObject(target[key])) {\n // Since `output` is a clone of `target` and we have narrowed `target` in this block we can cast to the same type.\n output[key] = deepmerge(target[key], source[key], options);\n } else if (options.clone) {\n output[key] = isPlainObject(source[key]) ? deepClone(source[key]) : source[key];\n } else {\n output[key] = source[key];\n }\n });\n }\n return output;\n}","/** @license React v16.13.1\n * react-is.production.min.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';var b=\"function\"===typeof Symbol&&Symbol.for,c=b?Symbol.for(\"react.element\"):60103,d=b?Symbol.for(\"react.portal\"):60106,e=b?Symbol.for(\"react.fragment\"):60107,f=b?Symbol.for(\"react.strict_mode\"):60108,g=b?Symbol.for(\"react.profiler\"):60114,h=b?Symbol.for(\"react.provider\"):60109,k=b?Symbol.for(\"react.context\"):60110,l=b?Symbol.for(\"react.async_mode\"):60111,m=b?Symbol.for(\"react.concurrent_mode\"):60111,n=b?Symbol.for(\"react.forward_ref\"):60112,p=b?Symbol.for(\"react.suspense\"):60113,q=b?\nSymbol.for(\"react.suspense_list\"):60120,r=b?Symbol.for(\"react.memo\"):60115,t=b?Symbol.for(\"react.lazy\"):60116,v=b?Symbol.for(\"react.block\"):60121,w=b?Symbol.for(\"react.fundamental\"):60117,x=b?Symbol.for(\"react.responder\"):60118,y=b?Symbol.for(\"react.scope\"):60119;\nfunction z(a){if(\"object\"===typeof a&&null!==a){var u=a.$$typeof;switch(u){case c:switch(a=a.type,a){case l:case m:case e:case g:case f:case p:return a;default:switch(a=a&&a.$$typeof,a){case k:case n:case t:case r:case h:return a;default:return u}}case d:return u}}}function A(a){return z(a)===m}exports.AsyncMode=l;exports.ConcurrentMode=m;exports.ContextConsumer=k;exports.ContextProvider=h;exports.Element=c;exports.ForwardRef=n;exports.Fragment=e;exports.Lazy=t;exports.Memo=r;exports.Portal=d;\nexports.Profiler=g;exports.StrictMode=f;exports.Suspense=p;exports.isAsyncMode=function(a){return A(a)||z(a)===l};exports.isConcurrentMode=A;exports.isContextConsumer=function(a){return z(a)===k};exports.isContextProvider=function(a){return z(a)===h};exports.isElement=function(a){return\"object\"===typeof a&&null!==a&&a.$$typeof===c};exports.isForwardRef=function(a){return z(a)===n};exports.isFragment=function(a){return z(a)===e};exports.isLazy=function(a){return z(a)===t};\nexports.isMemo=function(a){return z(a)===r};exports.isPortal=function(a){return z(a)===d};exports.isProfiler=function(a){return z(a)===g};exports.isStrictMode=function(a){return z(a)===f};exports.isSuspense=function(a){return z(a)===p};\nexports.isValidElementType=function(a){return\"string\"===typeof a||\"function\"===typeof a||a===e||a===m||a===g||a===f||a===p||a===q||\"object\"===typeof a&&null!==a&&(a.$$typeof===t||a.$$typeof===r||a.$$typeof===h||a.$$typeof===k||a.$$typeof===n||a.$$typeof===w||a.$$typeof===x||a.$$typeof===y||a.$$typeof===v)};exports.typeOf=z;\n","/** @license React v16.13.1\n * react-is.development.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\n\n\nif (process.env.NODE_ENV !== \"production\") {\n (function() {\n'use strict';\n\n// The Symbol used to tag the ReactElement-like types. If there is no native Symbol\n// nor polyfill, then a plain number is used for performance.\nvar hasSymbol = typeof Symbol === 'function' && Symbol.for;\nvar REACT_ELEMENT_TYPE = hasSymbol ? Symbol.for('react.element') : 0xeac7;\nvar REACT_PORTAL_TYPE = hasSymbol ? Symbol.for('react.portal') : 0xeaca;\nvar REACT_FRAGMENT_TYPE = hasSymbol ? Symbol.for('react.fragment') : 0xeacb;\nvar REACT_STRICT_MODE_TYPE = hasSymbol ? Symbol.for('react.strict_mode') : 0xeacc;\nvar REACT_PROFILER_TYPE = hasSymbol ? Symbol.for('react.profiler') : 0xead2;\nvar REACT_PROVIDER_TYPE = hasSymbol ? Symbol.for('react.provider') : 0xeacd;\nvar REACT_CONTEXT_TYPE = hasSymbol ? Symbol.for('react.context') : 0xeace; // TODO: We don't use AsyncMode or ConcurrentMode anymore. They were temporary\n// (unstable) APIs that have been removed. Can we remove the symbols?\n\nvar REACT_ASYNC_MODE_TYPE = hasSymbol ? Symbol.for('react.async_mode') : 0xeacf;\nvar REACT_CONCURRENT_MODE_TYPE = hasSymbol ? Symbol.for('react.concurrent_mode') : 0xeacf;\nvar REACT_FORWARD_REF_TYPE = hasSymbol ? Symbol.for('react.forward_ref') : 0xead0;\nvar REACT_SUSPENSE_TYPE = hasSymbol ? Symbol.for('react.suspense') : 0xead1;\nvar REACT_SUSPENSE_LIST_TYPE = hasSymbol ? Symbol.for('react.suspense_list') : 0xead8;\nvar REACT_MEMO_TYPE = hasSymbol ? Symbol.for('react.memo') : 0xead3;\nvar REACT_LAZY_TYPE = hasSymbol ? Symbol.for('react.lazy') : 0xead4;\nvar REACT_BLOCK_TYPE = hasSymbol ? Symbol.for('react.block') : 0xead9;\nvar REACT_FUNDAMENTAL_TYPE = hasSymbol ? Symbol.for('react.fundamental') : 0xead5;\nvar REACT_RESPONDER_TYPE = hasSymbol ? Symbol.for('react.responder') : 0xead6;\nvar REACT_SCOPE_TYPE = hasSymbol ? Symbol.for('react.scope') : 0xead7;\n\nfunction isValidElementType(type) {\n return typeof type === 'string' || typeof type === 'function' || // Note: its typeof might be other than 'symbol' or 'number' if it's a polyfill.\n type === REACT_FRAGMENT_TYPE || type === REACT_CONCURRENT_MODE_TYPE || type === REACT_PROFILER_TYPE || type === REACT_STRICT_MODE_TYPE || type === REACT_SUSPENSE_TYPE || type === REACT_SUSPENSE_LIST_TYPE || typeof type === 'object' && type !== null && (type.$$typeof === REACT_LAZY_TYPE || type.$$typeof === REACT_MEMO_TYPE || type.$$typeof === REACT_PROVIDER_TYPE || type.$$typeof === REACT_CONTEXT_TYPE || type.$$typeof === REACT_FORWARD_REF_TYPE || type.$$typeof === REACT_FUNDAMENTAL_TYPE || type.$$typeof === REACT_RESPONDER_TYPE || type.$$typeof === REACT_SCOPE_TYPE || type.$$typeof === REACT_BLOCK_TYPE);\n}\n\nfunction typeOf(object) {\n if (typeof object === 'object' && object !== null) {\n var $$typeof = object.$$typeof;\n\n switch ($$typeof) {\n case REACT_ELEMENT_TYPE:\n var type = object.type;\n\n switch (type) {\n case REACT_ASYNC_MODE_TYPE:\n case REACT_CONCURRENT_MODE_TYPE:\n case REACT_FRAGMENT_TYPE:\n case REACT_PROFILER_TYPE:\n case REACT_STRICT_MODE_TYPE:\n case REACT_SUSPENSE_TYPE:\n return type;\n\n default:\n var $$typeofType = type && type.$$typeof;\n\n switch ($$typeofType) {\n case REACT_CONTEXT_TYPE:\n case REACT_FORWARD_REF_TYPE:\n case REACT_LAZY_TYPE:\n case REACT_MEMO_TYPE:\n case REACT_PROVIDER_TYPE:\n return $$typeofType;\n\n default:\n return $$typeof;\n }\n\n }\n\n case REACT_PORTAL_TYPE:\n return $$typeof;\n }\n }\n\n return undefined;\n} // AsyncMode is deprecated along with isAsyncMode\n\nvar AsyncMode = REACT_ASYNC_MODE_TYPE;\nvar ConcurrentMode = REACT_CONCURRENT_MODE_TYPE;\nvar ContextConsumer = REACT_CONTEXT_TYPE;\nvar ContextProvider = REACT_PROVIDER_TYPE;\nvar Element = REACT_ELEMENT_TYPE;\nvar ForwardRef = REACT_FORWARD_REF_TYPE;\nvar Fragment = REACT_FRAGMENT_TYPE;\nvar Lazy = REACT_LAZY_TYPE;\nvar Memo = REACT_MEMO_TYPE;\nvar Portal = REACT_PORTAL_TYPE;\nvar Profiler = REACT_PROFILER_TYPE;\nvar StrictMode = REACT_STRICT_MODE_TYPE;\nvar Suspense = REACT_SUSPENSE_TYPE;\nvar hasWarnedAboutDeprecatedIsAsyncMode = false; // AsyncMode should be deprecated\n\nfunction isAsyncMode(object) {\n {\n if (!hasWarnedAboutDeprecatedIsAsyncMode) {\n hasWarnedAboutDeprecatedIsAsyncMode = true; // Using console['warn'] to evade Babel and ESLint\n\n console['warn']('The ReactIs.isAsyncMode() alias has been deprecated, ' + 'and will be removed in React 17+. Update your code to use ' + 'ReactIs.isConcurrentMode() instead. It has the exact same API.');\n }\n }\n\n return isConcurrentMode(object) || typeOf(object) === REACT_ASYNC_MODE_TYPE;\n}\nfunction isConcurrentMode(object) {\n return typeOf(object) === REACT_CONCURRENT_MODE_TYPE;\n}\nfunction isContextConsumer(object) {\n return typeOf(object) === REACT_CONTEXT_TYPE;\n}\nfunction isContextProvider(object) {\n return typeOf(object) === REACT_PROVIDER_TYPE;\n}\nfunction isElement(object) {\n return typeof object === 'object' && object !== null && object.$$typeof === REACT_ELEMENT_TYPE;\n}\nfunction isForwardRef(object) {\n return typeOf(object) === REACT_FORWARD_REF_TYPE;\n}\nfunction isFragment(object) {\n return typeOf(object) === REACT_FRAGMENT_TYPE;\n}\nfunction isLazy(object) {\n return typeOf(object) === REACT_LAZY_TYPE;\n}\nfunction isMemo(object) {\n return typeOf(object) === REACT_MEMO_TYPE;\n}\nfunction isPortal(object) {\n return typeOf(object) === REACT_PORTAL_TYPE;\n}\nfunction isProfiler(object) {\n return typeOf(object) === REACT_PROFILER_TYPE;\n}\nfunction isStrictMode(object) {\n return typeOf(object) === REACT_STRICT_MODE_TYPE;\n}\nfunction isSuspense(object) {\n return typeOf(object) === REACT_SUSPENSE_TYPE;\n}\n\nexports.AsyncMode = AsyncMode;\nexports.ConcurrentMode = ConcurrentMode;\nexports.ContextConsumer = ContextConsumer;\nexports.ContextProvider = ContextProvider;\nexports.Element = Element;\nexports.ForwardRef = ForwardRef;\nexports.Fragment = Fragment;\nexports.Lazy = Lazy;\nexports.Memo = Memo;\nexports.Portal = Portal;\nexports.Profiler = Profiler;\nexports.StrictMode = StrictMode;\nexports.Suspense = Suspense;\nexports.isAsyncMode = isAsyncMode;\nexports.isConcurrentMode = isConcurrentMode;\nexports.isContextConsumer = isContextConsumer;\nexports.isContextProvider = isContextProvider;\nexports.isElement = isElement;\nexports.isForwardRef = isForwardRef;\nexports.isFragment = isFragment;\nexports.isLazy = isLazy;\nexports.isMemo = isMemo;\nexports.isPortal = isPortal;\nexports.isProfiler = isProfiler;\nexports.isStrictMode = isStrictMode;\nexports.isSuspense = isSuspense;\nexports.isValidElementType = isValidElementType;\nexports.typeOf = typeOf;\n })();\n}\n","'use strict';\n\nif (process.env.NODE_ENV === 'production') {\n module.exports = require('./cjs/react-is.production.min.js');\n} else {\n module.exports = require('./cjs/react-is.development.js');\n}\n","/*\nobject-assign\n(c) Sindre Sorhus\n@license MIT\n*/\n\n'use strict';\n/* eslint-disable no-unused-vars */\nvar getOwnPropertySymbols = Object.getOwnPropertySymbols;\nvar hasOwnProperty = Object.prototype.hasOwnProperty;\nvar propIsEnumerable = Object.prototype.propertyIsEnumerable;\n\nfunction toObject(val) {\n\tif (val === null || val === undefined) {\n\t\tthrow new TypeError('Object.assign cannot be called with null or undefined');\n\t}\n\n\treturn Object(val);\n}\n\nfunction shouldUseNative() {\n\ttry {\n\t\tif (!Object.assign) {\n\t\t\treturn false;\n\t\t}\n\n\t\t// Detect buggy property enumeration order in older V8 versions.\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=4118\n\t\tvar test1 = new String('abc'); // eslint-disable-line no-new-wrappers\n\t\ttest1[5] = 'de';\n\t\tif (Object.getOwnPropertyNames(test1)[0] === '5') {\n\t\t\treturn false;\n\t\t}\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=3056\n\t\tvar test2 = {};\n\t\tfor (var i = 0; i < 10; i++) {\n\t\t\ttest2['_' + String.fromCharCode(i)] = i;\n\t\t}\n\t\tvar order2 = Object.getOwnPropertyNames(test2).map(function (n) {\n\t\t\treturn test2[n];\n\t\t});\n\t\tif (order2.join('') !== '0123456789') {\n\t\t\treturn false;\n\t\t}\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=3056\n\t\tvar test3 = {};\n\t\t'abcdefghijklmnopqrst'.split('').forEach(function (letter) {\n\t\t\ttest3[letter] = letter;\n\t\t});\n\t\tif (Object.keys(Object.assign({}, test3)).join('') !==\n\t\t\t\t'abcdefghijklmnopqrst') {\n\t\t\treturn false;\n\t\t}\n\n\t\treturn true;\n\t} catch (err) {\n\t\t// We don't expect any of the above to throw, but better to be safe.\n\t\treturn false;\n\t}\n}\n\nmodule.exports = shouldUseNative() ? Object.assign : function (target, source) {\n\tvar from;\n\tvar to = toObject(target);\n\tvar symbols;\n\n\tfor (var s = 1; s < arguments.length; s++) {\n\t\tfrom = Object(arguments[s]);\n\n\t\tfor (var key in from) {\n\t\t\tif (hasOwnProperty.call(from, key)) {\n\t\t\t\tto[key] = from[key];\n\t\t\t}\n\t\t}\n\n\t\tif (getOwnPropertySymbols) {\n\t\t\tsymbols = getOwnPropertySymbols(from);\n\t\t\tfor (var i = 0; i < symbols.length; i++) {\n\t\t\t\tif (propIsEnumerable.call(from, symbols[i])) {\n\t\t\t\t\tto[symbols[i]] = from[symbols[i]];\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\n\treturn to;\n};\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar ReactPropTypesSecret = 'SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED';\n\nmodule.exports = ReactPropTypesSecret;\n","module.exports = Function.call.bind(Object.prototype.hasOwnProperty);\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar printWarning = function() {};\n\nif (process.env.NODE_ENV !== 'production') {\n var ReactPropTypesSecret = require('./lib/ReactPropTypesSecret');\n var loggedTypeFailures = {};\n var has = require('./lib/has');\n\n printWarning = function(text) {\n var message = 'Warning: ' + text;\n if (typeof console !== 'undefined') {\n console.error(message);\n }\n try {\n // --- Welcome to debugging React ---\n // This error was thrown as a convenience so that you can use this stack\n // to find the callsite that caused this warning to fire.\n throw new Error(message);\n } catch (x) { /**/ }\n };\n}\n\n/**\n * Assert that the values match with the type specs.\n * Error messages are memorized and will only be shown once.\n *\n * @param {object} typeSpecs Map of name to a ReactPropType\n * @param {object} values Runtime values that need to be type-checked\n * @param {string} location e.g. \"prop\", \"context\", \"child context\"\n * @param {string} componentName Name of the component for error messages.\n * @param {?Function} getStack Returns the component stack.\n * @private\n */\nfunction checkPropTypes(typeSpecs, values, location, componentName, getStack) {\n if (process.env.NODE_ENV !== 'production') {\n for (var typeSpecName in typeSpecs) {\n if (has(typeSpecs, typeSpecName)) {\n var error;\n // Prop type validation may throw. In case they do, we don't want to\n // fail the render phase where it didn't fail before. So we log it.\n // After these have been cleaned up, we'll let them throw.\n try {\n // This is intentionally an invariant that gets caught. It's the same\n // behavior as without this statement except with a better message.\n if (typeof typeSpecs[typeSpecName] !== 'function') {\n var err = Error(\n (componentName || 'React class') + ': ' + location + ' type `' + typeSpecName + '` is invalid; ' +\n 'it must be a function, usually from the `prop-types` package, but received `' + typeof typeSpecs[typeSpecName] + '`.' +\n 'This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.'\n );\n err.name = 'Invariant Violation';\n throw err;\n }\n error = typeSpecs[typeSpecName](values, typeSpecName, componentName, location, null, ReactPropTypesSecret);\n } catch (ex) {\n error = ex;\n }\n if (error && !(error instanceof Error)) {\n printWarning(\n (componentName || 'React class') + ': type specification of ' +\n location + ' `' + typeSpecName + '` is invalid; the type checker ' +\n 'function must return `null` or an `Error` but returned a ' + typeof error + '. ' +\n 'You may have forgotten to pass an argument to the type checker ' +\n 'creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and ' +\n 'shape all require an argument).'\n );\n }\n if (error instanceof Error && !(error.message in loggedTypeFailures)) {\n // Only monitor this failure once because there tends to be a lot of the\n // same error.\n loggedTypeFailures[error.message] = true;\n\n var stack = getStack ? getStack() : '';\n\n printWarning(\n 'Failed ' + location + ' type: ' + error.message + (stack != null ? stack : '')\n );\n }\n }\n }\n }\n}\n\n/**\n * Resets warning cache when testing.\n *\n * @private\n */\ncheckPropTypes.resetWarningCache = function() {\n if (process.env.NODE_ENV !== 'production') {\n loggedTypeFailures = {};\n }\n}\n\nmodule.exports = checkPropTypes;\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar ReactIs = require('react-is');\nvar assign = require('object-assign');\n\nvar ReactPropTypesSecret = require('./lib/ReactPropTypesSecret');\nvar has = require('./lib/has');\nvar checkPropTypes = require('./checkPropTypes');\n\nvar printWarning = function() {};\n\nif (process.env.NODE_ENV !== 'production') {\n printWarning = function(text) {\n var message = 'Warning: ' + text;\n if (typeof console !== 'undefined') {\n console.error(message);\n }\n try {\n // --- Welcome to debugging React ---\n // This error was thrown as a convenience so that you can use this stack\n // to find the callsite that caused this warning to fire.\n throw new Error(message);\n } catch (x) {}\n };\n}\n\nfunction emptyFunctionThatReturnsNull() {\n return null;\n}\n\nmodule.exports = function(isValidElement, throwOnDirectAccess) {\n /* global Symbol */\n var ITERATOR_SYMBOL = typeof Symbol === 'function' && Symbol.iterator;\n var FAUX_ITERATOR_SYMBOL = '@@iterator'; // Before Symbol spec.\n\n /**\n * Returns the iterator method function contained on the iterable object.\n *\n * Be sure to invoke the function with the iterable as context:\n *\n * var iteratorFn = getIteratorFn(myIterable);\n * if (iteratorFn) {\n * var iterator = iteratorFn.call(myIterable);\n * ...\n * }\n *\n * @param {?object} maybeIterable\n * @return {?function}\n */\n function getIteratorFn(maybeIterable) {\n var iteratorFn = maybeIterable && (ITERATOR_SYMBOL && maybeIterable[ITERATOR_SYMBOL] || maybeIterable[FAUX_ITERATOR_SYMBOL]);\n if (typeof iteratorFn === 'function') {\n return iteratorFn;\n }\n }\n\n /**\n * Collection of methods that allow declaration and validation of props that are\n * supplied to React components. Example usage:\n *\n * var Props = require('ReactPropTypes');\n * var MyArticle = React.createClass({\n * propTypes: {\n * // An optional string prop named \"description\".\n * description: Props.string,\n *\n * // A required enum prop named \"category\".\n * category: Props.oneOf(['News','Photos']).isRequired,\n *\n * // A prop named \"dialog\" that requires an instance of Dialog.\n * dialog: Props.instanceOf(Dialog).isRequired\n * },\n * render: function() { ... }\n * });\n *\n * A more formal specification of how these methods are used:\n *\n * type := array|bool|func|object|number|string|oneOf([...])|instanceOf(...)\n * decl := ReactPropTypes.{type}(.isRequired)?\n *\n * Each and every declaration produces a function with the same signature. This\n * allows the creation of custom validation functions. For example:\n *\n * var MyLink = React.createClass({\n * propTypes: {\n * // An optional string or URI prop named \"href\".\n * href: function(props, propName, componentName) {\n * var propValue = props[propName];\n * if (propValue != null && typeof propValue !== 'string' &&\n * !(propValue instanceof URI)) {\n * return new Error(\n * 'Expected a string or an URI for ' + propName + ' in ' +\n * componentName\n * );\n * }\n * }\n * },\n * render: function() {...}\n * });\n *\n * @internal\n */\n\n var ANONYMOUS = '<>';\n\n // Important!\n // Keep this list in sync with production version in `./factoryWithThrowingShims.js`.\n var ReactPropTypes = {\n array: createPrimitiveTypeChecker('array'),\n bigint: createPrimitiveTypeChecker('bigint'),\n bool: createPrimitiveTypeChecker('boolean'),\n func: createPrimitiveTypeChecker('function'),\n number: createPrimitiveTypeChecker('number'),\n object: createPrimitiveTypeChecker('object'),\n string: createPrimitiveTypeChecker('string'),\n symbol: createPrimitiveTypeChecker('symbol'),\n\n any: createAnyTypeChecker(),\n arrayOf: createArrayOfTypeChecker,\n element: createElementTypeChecker(),\n elementType: createElementTypeTypeChecker(),\n instanceOf: createInstanceTypeChecker,\n node: createNodeChecker(),\n objectOf: createObjectOfTypeChecker,\n oneOf: createEnumTypeChecker,\n oneOfType: createUnionTypeChecker,\n shape: createShapeTypeChecker,\n exact: createStrictShapeTypeChecker,\n };\n\n /**\n * inlined Object.is polyfill to avoid requiring consumers ship their own\n * https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object/is\n */\n /*eslint-disable no-self-compare*/\n function is(x, y) {\n // SameValue algorithm\n if (x === y) {\n // Steps 1-5, 7-10\n // Steps 6.b-6.e: +0 != -0\n return x !== 0 || 1 / x === 1 / y;\n } else {\n // Step 6.a: NaN == NaN\n return x !== x && y !== y;\n }\n }\n /*eslint-enable no-self-compare*/\n\n /**\n * We use an Error-like object for backward compatibility as people may call\n * PropTypes directly and inspect their output. However, we don't use real\n * Errors anymore. We don't inspect their stack anyway, and creating them\n * is prohibitively expensive if they are created too often, such as what\n * happens in oneOfType() for any type before the one that matched.\n */\n function PropTypeError(message, data) {\n this.message = message;\n this.data = data && typeof data === 'object' ? data: {};\n this.stack = '';\n }\n // Make `instanceof Error` still work for returned errors.\n PropTypeError.prototype = Error.prototype;\n\n function createChainableTypeChecker(validate) {\n if (process.env.NODE_ENV !== 'production') {\n var manualPropTypeCallCache = {};\n var manualPropTypeWarningCount = 0;\n }\n function checkType(isRequired, props, propName, componentName, location, propFullName, secret) {\n componentName = componentName || ANONYMOUS;\n propFullName = propFullName || propName;\n\n if (secret !== ReactPropTypesSecret) {\n if (throwOnDirectAccess) {\n // New behavior only for users of `prop-types` package\n var err = new Error(\n 'Calling PropTypes validators directly is not supported by the `prop-types` package. ' +\n 'Use `PropTypes.checkPropTypes()` to call them. ' +\n 'Read more at http://fb.me/use-check-prop-types'\n );\n err.name = 'Invariant Violation';\n throw err;\n } else if (process.env.NODE_ENV !== 'production' && typeof console !== 'undefined') {\n // Old behavior for people using React.PropTypes\n var cacheKey = componentName + ':' + propName;\n if (\n !manualPropTypeCallCache[cacheKey] &&\n // Avoid spamming the console because they are often not actionable except for lib authors\n manualPropTypeWarningCount < 3\n ) {\n printWarning(\n 'You are manually calling a React.PropTypes validation ' +\n 'function for the `' + propFullName + '` prop on `' + componentName + '`. This is deprecated ' +\n 'and will throw in the standalone `prop-types` package. ' +\n 'You may be seeing this warning due to a third-party PropTypes ' +\n 'library. See https://fb.me/react-warning-dont-call-proptypes ' + 'for details.'\n );\n manualPropTypeCallCache[cacheKey] = true;\n manualPropTypeWarningCount++;\n }\n }\n }\n if (props[propName] == null) {\n if (isRequired) {\n if (props[propName] === null) {\n return new PropTypeError('The ' + location + ' `' + propFullName + '` is marked as required ' + ('in `' + componentName + '`, but its value is `null`.'));\n }\n return new PropTypeError('The ' + location + ' `' + propFullName + '` is marked as required in ' + ('`' + componentName + '`, but its value is `undefined`.'));\n }\n return null;\n } else {\n return validate(props, propName, componentName, location, propFullName);\n }\n }\n\n var chainedCheckType = checkType.bind(null, false);\n chainedCheckType.isRequired = checkType.bind(null, true);\n\n return chainedCheckType;\n }\n\n function createPrimitiveTypeChecker(expectedType) {\n function validate(props, propName, componentName, location, propFullName, secret) {\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== expectedType) {\n // `propValue` being instance of, say, date/regexp, pass the 'object'\n // check, but we can offer a more precise error message here rather than\n // 'of type `object`'.\n var preciseType = getPreciseType(propValue);\n\n return new PropTypeError(\n 'Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + preciseType + '` supplied to `' + componentName + '`, expected ') + ('`' + expectedType + '`.'),\n {expectedType: expectedType}\n );\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createAnyTypeChecker() {\n return createChainableTypeChecker(emptyFunctionThatReturnsNull);\n }\n\n function createArrayOfTypeChecker(typeChecker) {\n function validate(props, propName, componentName, location, propFullName) {\n if (typeof typeChecker !== 'function') {\n return new PropTypeError('Property `' + propFullName + '` of component `' + componentName + '` has invalid PropType notation inside arrayOf.');\n }\n var propValue = props[propName];\n if (!Array.isArray(propValue)) {\n var propType = getPropType(propValue);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected an array.'));\n }\n for (var i = 0; i < propValue.length; i++) {\n var error = typeChecker(propValue, i, componentName, location, propFullName + '[' + i + ']', ReactPropTypesSecret);\n if (error instanceof Error) {\n return error;\n }\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createElementTypeChecker() {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n if (!isValidElement(propValue)) {\n var propType = getPropType(propValue);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected a single ReactElement.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createElementTypeTypeChecker() {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n if (!ReactIs.isValidElementType(propValue)) {\n var propType = getPropType(propValue);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected a single ReactElement type.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createInstanceTypeChecker(expectedClass) {\n function validate(props, propName, componentName, location, propFullName) {\n if (!(props[propName] instanceof expectedClass)) {\n var expectedClassName = expectedClass.name || ANONYMOUS;\n var actualClassName = getClassName(props[propName]);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + actualClassName + '` supplied to `' + componentName + '`, expected ') + ('instance of `' + expectedClassName + '`.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createEnumTypeChecker(expectedValues) {\n if (!Array.isArray(expectedValues)) {\n if (process.env.NODE_ENV !== 'production') {\n if (arguments.length > 1) {\n printWarning(\n 'Invalid arguments supplied to oneOf, expected an array, got ' + arguments.length + ' arguments. ' +\n 'A common mistake is to write oneOf(x, y, z) instead of oneOf([x, y, z]).'\n );\n } else {\n printWarning('Invalid argument supplied to oneOf, expected an array.');\n }\n }\n return emptyFunctionThatReturnsNull;\n }\n\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n for (var i = 0; i < expectedValues.length; i++) {\n if (is(propValue, expectedValues[i])) {\n return null;\n }\n }\n\n var valuesString = JSON.stringify(expectedValues, function replacer(key, value) {\n var type = getPreciseType(value);\n if (type === 'symbol') {\n return String(value);\n }\n return value;\n });\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of value `' + String(propValue) + '` ' + ('supplied to `' + componentName + '`, expected one of ' + valuesString + '.'));\n }\n return createChainableTypeChecker(validate);\n }\n\n function createObjectOfTypeChecker(typeChecker) {\n function validate(props, propName, componentName, location, propFullName) {\n if (typeof typeChecker !== 'function') {\n return new PropTypeError('Property `' + propFullName + '` of component `' + componentName + '` has invalid PropType notation inside objectOf.');\n }\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== 'object') {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected an object.'));\n }\n for (var key in propValue) {\n if (has(propValue, key)) {\n var error = typeChecker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret);\n if (error instanceof Error) {\n return error;\n }\n }\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createUnionTypeChecker(arrayOfTypeCheckers) {\n if (!Array.isArray(arrayOfTypeCheckers)) {\n process.env.NODE_ENV !== 'production' ? printWarning('Invalid argument supplied to oneOfType, expected an instance of array.') : void 0;\n return emptyFunctionThatReturnsNull;\n }\n\n for (var i = 0; i < arrayOfTypeCheckers.length; i++) {\n var checker = arrayOfTypeCheckers[i];\n if (typeof checker !== 'function') {\n printWarning(\n 'Invalid argument supplied to oneOfType. Expected an array of check functions, but ' +\n 'received ' + getPostfixForTypeWarning(checker) + ' at index ' + i + '.'\n );\n return emptyFunctionThatReturnsNull;\n }\n }\n\n function validate(props, propName, componentName, location, propFullName) {\n var expectedTypes = [];\n for (var i = 0; i < arrayOfTypeCheckers.length; i++) {\n var checker = arrayOfTypeCheckers[i];\n var checkerResult = checker(props, propName, componentName, location, propFullName, ReactPropTypesSecret);\n if (checkerResult == null) {\n return null;\n }\n if (checkerResult.data && has(checkerResult.data, 'expectedType')) {\n expectedTypes.push(checkerResult.data.expectedType);\n }\n }\n var expectedTypesMessage = (expectedTypes.length > 0) ? ', expected one of type [' + expectedTypes.join(', ') + ']': '';\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` supplied to ' + ('`' + componentName + '`' + expectedTypesMessage + '.'));\n }\n return createChainableTypeChecker(validate);\n }\n\n function createNodeChecker() {\n function validate(props, propName, componentName, location, propFullName) {\n if (!isNode(props[propName])) {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` supplied to ' + ('`' + componentName + '`, expected a ReactNode.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function invalidValidatorError(componentName, location, propFullName, key, type) {\n return new PropTypeError(\n (componentName || 'React class') + ': ' + location + ' type `' + propFullName + '.' + key + '` is invalid; ' +\n 'it must be a function, usually from the `prop-types` package, but received `' + type + '`.'\n );\n }\n\n function createShapeTypeChecker(shapeTypes) {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== 'object') {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type `' + propType + '` ' + ('supplied to `' + componentName + '`, expected `object`.'));\n }\n for (var key in shapeTypes) {\n var checker = shapeTypes[key];\n if (typeof checker !== 'function') {\n return invalidValidatorError(componentName, location, propFullName, key, getPreciseType(checker));\n }\n var error = checker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret);\n if (error) {\n return error;\n }\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createStrictShapeTypeChecker(shapeTypes) {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== 'object') {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type `' + propType + '` ' + ('supplied to `' + componentName + '`, expected `object`.'));\n }\n // We need to check all keys in case some are required but missing from props.\n var allKeys = assign({}, props[propName], shapeTypes);\n for (var key in allKeys) {\n var checker = shapeTypes[key];\n if (has(shapeTypes, key) && typeof checker !== 'function') {\n return invalidValidatorError(componentName, location, propFullName, key, getPreciseType(checker));\n }\n if (!checker) {\n return new PropTypeError(\n 'Invalid ' + location + ' `' + propFullName + '` key `' + key + '` supplied to `' + componentName + '`.' +\n '\\nBad object: ' + JSON.stringify(props[propName], null, ' ') +\n '\\nValid keys: ' + JSON.stringify(Object.keys(shapeTypes), null, ' ')\n );\n }\n var error = checker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret);\n if (error) {\n return error;\n }\n }\n return null;\n }\n\n return createChainableTypeChecker(validate);\n }\n\n function isNode(propValue) {\n switch (typeof propValue) {\n case 'number':\n case 'string':\n case 'undefined':\n return true;\n case 'boolean':\n return !propValue;\n case 'object':\n if (Array.isArray(propValue)) {\n return propValue.every(isNode);\n }\n if (propValue === null || isValidElement(propValue)) {\n return true;\n }\n\n var iteratorFn = getIteratorFn(propValue);\n if (iteratorFn) {\n var iterator = iteratorFn.call(propValue);\n var step;\n if (iteratorFn !== propValue.entries) {\n while (!(step = iterator.next()).done) {\n if (!isNode(step.value)) {\n return false;\n }\n }\n } else {\n // Iterator will provide entry [k,v] tuples rather than values.\n while (!(step = iterator.next()).done) {\n var entry = step.value;\n if (entry) {\n if (!isNode(entry[1])) {\n return false;\n }\n }\n }\n }\n } else {\n return false;\n }\n\n return true;\n default:\n return false;\n }\n }\n\n function isSymbol(propType, propValue) {\n // Native Symbol.\n if (propType === 'symbol') {\n return true;\n }\n\n // falsy value can't be a Symbol\n if (!propValue) {\n return false;\n }\n\n // 19.4.3.5 Symbol.prototype[@@toStringTag] === 'Symbol'\n if (propValue['@@toStringTag'] === 'Symbol') {\n return true;\n }\n\n // Fallback for non-spec compliant Symbols which are polyfilled.\n if (typeof Symbol === 'function' && propValue instanceof Symbol) {\n return true;\n }\n\n return false;\n }\n\n // Equivalent of `typeof` but with special handling for array and regexp.\n function getPropType(propValue) {\n var propType = typeof propValue;\n if (Array.isArray(propValue)) {\n return 'array';\n }\n if (propValue instanceof RegExp) {\n // Old webkits (at least until Android 4.0) return 'function' rather than\n // 'object' for typeof a RegExp. We'll normalize this here so that /bla/\n // passes PropTypes.object.\n return 'object';\n }\n if (isSymbol(propType, propValue)) {\n return 'symbol';\n }\n return propType;\n }\n\n // This handles more types than `getPropType`. Only used for error messages.\n // See `createPrimitiveTypeChecker`.\n function getPreciseType(propValue) {\n if (typeof propValue === 'undefined' || propValue === null) {\n return '' + propValue;\n }\n var propType = getPropType(propValue);\n if (propType === 'object') {\n if (propValue instanceof Date) {\n return 'date';\n } else if (propValue instanceof RegExp) {\n return 'regexp';\n }\n }\n return propType;\n }\n\n // Returns a string that is postfixed to a warning about an invalid type.\n // For example, \"undefined\" or \"of type array\"\n function getPostfixForTypeWarning(value) {\n var type = getPreciseType(value);\n switch (type) {\n case 'array':\n case 'object':\n return 'an ' + type;\n case 'boolean':\n case 'date':\n case 'regexp':\n return 'a ' + type;\n default:\n return type;\n }\n }\n\n // Returns class name of the object, if any.\n function getClassName(propValue) {\n if (!propValue.constructor || !propValue.constructor.name) {\n return ANONYMOUS;\n }\n return propValue.constructor.name;\n }\n\n ReactPropTypes.checkPropTypes = checkPropTypes;\n ReactPropTypes.resetWarningCache = checkPropTypes.resetWarningCache;\n ReactPropTypes.PropTypes = ReactPropTypes;\n\n return ReactPropTypes;\n};\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar ReactPropTypesSecret = require('./lib/ReactPropTypesSecret');\n\nfunction emptyFunction() {}\nfunction emptyFunctionWithReset() {}\nemptyFunctionWithReset.resetWarningCache = emptyFunction;\n\nmodule.exports = function() {\n function shim(props, propName, componentName, location, propFullName, secret) {\n if (secret === ReactPropTypesSecret) {\n // It is still safe when called from React.\n return;\n }\n var err = new Error(\n 'Calling PropTypes validators directly is not supported by the `prop-types` package. ' +\n 'Use PropTypes.checkPropTypes() to call them. ' +\n 'Read more at http://fb.me/use-check-prop-types'\n );\n err.name = 'Invariant Violation';\n throw err;\n };\n shim.isRequired = shim;\n function getShim() {\n return shim;\n };\n // Important!\n // Keep this list in sync with production version in `./factoryWithTypeCheckers.js`.\n var ReactPropTypes = {\n array: shim,\n bigint: shim,\n bool: shim,\n func: shim,\n number: shim,\n object: shim,\n string: shim,\n symbol: shim,\n\n any: shim,\n arrayOf: getShim,\n element: shim,\n elementType: shim,\n instanceOf: getShim,\n node: shim,\n objectOf: getShim,\n oneOf: getShim,\n oneOfType: getShim,\n shape: getShim,\n exact: getShim,\n\n checkPropTypes: emptyFunctionWithReset,\n resetWarningCache: emptyFunction\n };\n\n ReactPropTypes.PropTypes = ReactPropTypes;\n\n return ReactPropTypes;\n};\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\nif (process.env.NODE_ENV !== 'production') {\n var ReactIs = require('react-is');\n\n // By explicitly using `prop-types` you are opting into new development behavior.\n // http://fb.me/prop-types-in-prod\n var throwOnDirectAccess = true;\n module.exports = require('./factoryWithTypeCheckers')(ReactIs.isElement, throwOnDirectAccess);\n} else {\n // By explicitly using `prop-types` you are opting into new production behavior.\n // http://fb.me/prop-types-in-prod\n module.exports = require('./factoryWithThrowingShims')();\n}\n","import PropTypes from 'prop-types';\nimport chainPropTypes from '../chainPropTypes';\nfunction isClassComponent(elementType) {\n // elementType.prototype?.isReactComponent\n const {\n prototype = {}\n } = elementType;\n return Boolean(prototype.isReactComponent);\n}\nfunction acceptingRef(props, propName, componentName, location, propFullName) {\n const element = props[propName];\n const safePropName = propFullName || propName;\n if (element == null ||\n // When server-side rendering React doesn't warn either.\n // This is not an accurate check for SSR.\n // This is only in place for Emotion compat.\n // TODO: Revisit once https://github.com/facebook/react/issues/20047 is resolved.\n typeof window === 'undefined') {\n return null;\n }\n let warningHint;\n const elementType = element.type;\n /**\n * Blacklisting instead of whitelisting\n *\n * Blacklisting will miss some components, such as React.Fragment. Those will at least\n * trigger a warning in React.\n * We can't whitelist because there is no safe way to detect React.forwardRef\n * or class components. \"Safe\" means there's no public API.\n *\n */\n if (typeof elementType === 'function' && !isClassComponent(elementType)) {\n warningHint = 'Did you accidentally use a plain function component for an element instead?';\n }\n if (warningHint !== undefined) {\n return new Error(`Invalid ${location} \\`${safePropName}\\` supplied to \\`${componentName}\\`. ` + `Expected an element that can hold a ref. ${warningHint} ` + 'For more information see https://mui.com/r/caveat-with-refs-guide');\n }\n return null;\n}\nconst elementAcceptingRef = chainPropTypes(PropTypes.element, acceptingRef);\nelementAcceptingRef.isRequired = chainPropTypes(PropTypes.element.isRequired, acceptingRef);\nexport default elementAcceptingRef;","import _extends from \"@babel/runtime/helpers/esm/extends\";\n// This module is based on https://github.com/airbnb/prop-types-exact repository.\n// However, in order to reduce the number of dependencies and to remove some extra safe checks\n// the module was forked.\n\nconst specialProperty = 'exact-prop: \\u200b';\nexport default function exactProp(propTypes) {\n if (process.env.NODE_ENV === 'production') {\n return propTypes;\n }\n return _extends({}, propTypes, {\n [specialProperty]: props => {\n const unsupportedProps = Object.keys(props).filter(prop => !propTypes.hasOwnProperty(prop));\n if (unsupportedProps.length > 0) {\n return new Error(`The following props are not supported: ${unsupportedProps.map(prop => `\\`${prop}\\``).join(', ')}. Please remove them.`);\n }\n return null;\n }\n });\n}","/**\n * WARNING: Don't import this directly.\n * Use `MuiError` from `@mui/internal-babel-macros/MuiError.macro` instead.\n * @param {number} code\n */\nexport default function formatMuiErrorMessage(code) {\n // Apply babel-plugin-transform-template-literals in loose mode\n // loose mode is safe if we're concatenating primitives\n // see https://babeljs.io/docs/en/babel-plugin-transform-template-literals#loose\n /* eslint-disable prefer-template */\n let url = 'https://mui.com/production-error/?code=' + code;\n for (let i = 1; i < arguments.length; i += 1) {\n // rest params over-transpile for this case\n // eslint-disable-next-line prefer-rest-params\n url += '&args[]=' + encodeURIComponent(arguments[i]);\n }\n return 'Minified MUI error #' + code + '; visit ' + url + ' for the full message.';\n /* eslint-enable prefer-template */\n}","/**\n * @license React\n * react-is.production.min.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n'use strict';var b=Symbol.for(\"react.element\"),c=Symbol.for(\"react.portal\"),d=Symbol.for(\"react.fragment\"),e=Symbol.for(\"react.strict_mode\"),f=Symbol.for(\"react.profiler\"),g=Symbol.for(\"react.provider\"),h=Symbol.for(\"react.context\"),k=Symbol.for(\"react.server_context\"),l=Symbol.for(\"react.forward_ref\"),m=Symbol.for(\"react.suspense\"),n=Symbol.for(\"react.suspense_list\"),p=Symbol.for(\"react.memo\"),q=Symbol.for(\"react.lazy\"),t=Symbol.for(\"react.offscreen\"),u;u=Symbol.for(\"react.module.reference\");\nfunction v(a){if(\"object\"===typeof a&&null!==a){var r=a.$$typeof;switch(r){case b:switch(a=a.type,a){case d:case f:case e:case m:case n:return a;default:switch(a=a&&a.$$typeof,a){case k:case h:case l:case q:case p:case g:return a;default:return r}}case c:return r}}}exports.ContextConsumer=h;exports.ContextProvider=g;exports.Element=b;exports.ForwardRef=l;exports.Fragment=d;exports.Lazy=q;exports.Memo=p;exports.Portal=c;exports.Profiler=f;exports.StrictMode=e;exports.Suspense=m;\nexports.SuspenseList=n;exports.isAsyncMode=function(){return!1};exports.isConcurrentMode=function(){return!1};exports.isContextConsumer=function(a){return v(a)===h};exports.isContextProvider=function(a){return v(a)===g};exports.isElement=function(a){return\"object\"===typeof a&&null!==a&&a.$$typeof===b};exports.isForwardRef=function(a){return v(a)===l};exports.isFragment=function(a){return v(a)===d};exports.isLazy=function(a){return v(a)===q};exports.isMemo=function(a){return v(a)===p};\nexports.isPortal=function(a){return v(a)===c};exports.isProfiler=function(a){return v(a)===f};exports.isStrictMode=function(a){return v(a)===e};exports.isSuspense=function(a){return v(a)===m};exports.isSuspenseList=function(a){return v(a)===n};\nexports.isValidElementType=function(a){return\"string\"===typeof a||\"function\"===typeof a||a===d||a===f||a===e||a===m||a===n||a===t||\"object\"===typeof a&&null!==a&&(a.$$typeof===q||a.$$typeof===p||a.$$typeof===g||a.$$typeof===h||a.$$typeof===l||a.$$typeof===u||void 0!==a.getModuleId)?!0:!1};exports.typeOf=v;\n","/**\n * @license React\n * react-is.development.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nif (process.env.NODE_ENV !== \"production\") {\n (function() {\n'use strict';\n\n// ATTENTION\n// When adding new symbols to this file,\n// Please consider also adding to 'react-devtools-shared/src/backend/ReactSymbols'\n// The Symbol used to tag the ReactElement-like types.\nvar REACT_ELEMENT_TYPE = Symbol.for('react.element');\nvar REACT_PORTAL_TYPE = Symbol.for('react.portal');\nvar REACT_FRAGMENT_TYPE = Symbol.for('react.fragment');\nvar REACT_STRICT_MODE_TYPE = Symbol.for('react.strict_mode');\nvar REACT_PROFILER_TYPE = Symbol.for('react.profiler');\nvar REACT_PROVIDER_TYPE = Symbol.for('react.provider');\nvar REACT_CONTEXT_TYPE = Symbol.for('react.context');\nvar REACT_SERVER_CONTEXT_TYPE = Symbol.for('react.server_context');\nvar REACT_FORWARD_REF_TYPE = Symbol.for('react.forward_ref');\nvar REACT_SUSPENSE_TYPE = Symbol.for('react.suspense');\nvar REACT_SUSPENSE_LIST_TYPE = Symbol.for('react.suspense_list');\nvar REACT_MEMO_TYPE = Symbol.for('react.memo');\nvar REACT_LAZY_TYPE = Symbol.for('react.lazy');\nvar REACT_OFFSCREEN_TYPE = Symbol.for('react.offscreen');\n\n// -----------------------------------------------------------------------------\n\nvar enableScopeAPI = false; // Experimental Create Event Handle API.\nvar enableCacheElement = false;\nvar enableTransitionTracing = false; // No known bugs, but needs performance testing\n\nvar enableLegacyHidden = false; // Enables unstable_avoidThisFallback feature in Fiber\n// stuff. Intended to enable React core members to more easily debug scheduling\n// issues in DEV builds.\n\nvar enableDebugTracing = false; // Track which Fiber(s) schedule render work.\n\nvar REACT_MODULE_REFERENCE;\n\n{\n REACT_MODULE_REFERENCE = Symbol.for('react.module.reference');\n}\n\nfunction isValidElementType(type) {\n if (typeof type === 'string' || typeof type === 'function') {\n return true;\n } // Note: typeof might be other than 'symbol' or 'number' (e.g. if it's a polyfill).\n\n\n if (type === REACT_FRAGMENT_TYPE || type === REACT_PROFILER_TYPE || enableDebugTracing || type === REACT_STRICT_MODE_TYPE || type === REACT_SUSPENSE_TYPE || type === REACT_SUSPENSE_LIST_TYPE || enableLegacyHidden || type === REACT_OFFSCREEN_TYPE || enableScopeAPI || enableCacheElement || enableTransitionTracing ) {\n return true;\n }\n\n if (typeof type === 'object' && type !== null) {\n if (type.$$typeof === REACT_LAZY_TYPE || type.$$typeof === REACT_MEMO_TYPE || type.$$typeof === REACT_PROVIDER_TYPE || type.$$typeof === REACT_CONTEXT_TYPE || type.$$typeof === REACT_FORWARD_REF_TYPE || // This needs to include all possible module reference object\n // types supported by any Flight configuration anywhere since\n // we don't know which Flight build this will end up being used\n // with.\n type.$$typeof === REACT_MODULE_REFERENCE || type.getModuleId !== undefined) {\n return true;\n }\n }\n\n return false;\n}\n\nfunction typeOf(object) {\n if (typeof object === 'object' && object !== null) {\n var $$typeof = object.$$typeof;\n\n switch ($$typeof) {\n case REACT_ELEMENT_TYPE:\n var type = object.type;\n\n switch (type) {\n case REACT_FRAGMENT_TYPE:\n case REACT_PROFILER_TYPE:\n case REACT_STRICT_MODE_TYPE:\n case REACT_SUSPENSE_TYPE:\n case REACT_SUSPENSE_LIST_TYPE:\n return type;\n\n default:\n var $$typeofType = type && type.$$typeof;\n\n switch ($$typeofType) {\n case REACT_SERVER_CONTEXT_TYPE:\n case REACT_CONTEXT_TYPE:\n case REACT_FORWARD_REF_TYPE:\n case REACT_LAZY_TYPE:\n case REACT_MEMO_TYPE:\n case REACT_PROVIDER_TYPE:\n return $$typeofType;\n\n default:\n return $$typeof;\n }\n\n }\n\n case REACT_PORTAL_TYPE:\n return $$typeof;\n }\n }\n\n return undefined;\n}\nvar ContextConsumer = REACT_CONTEXT_TYPE;\nvar ContextProvider = REACT_PROVIDER_TYPE;\nvar Element = REACT_ELEMENT_TYPE;\nvar ForwardRef = REACT_FORWARD_REF_TYPE;\nvar Fragment = REACT_FRAGMENT_TYPE;\nvar Lazy = REACT_LAZY_TYPE;\nvar Memo = REACT_MEMO_TYPE;\nvar Portal = REACT_PORTAL_TYPE;\nvar Profiler = REACT_PROFILER_TYPE;\nvar StrictMode = REACT_STRICT_MODE_TYPE;\nvar Suspense = REACT_SUSPENSE_TYPE;\nvar SuspenseList = REACT_SUSPENSE_LIST_TYPE;\nvar hasWarnedAboutDeprecatedIsAsyncMode = false;\nvar hasWarnedAboutDeprecatedIsConcurrentMode = false; // AsyncMode should be deprecated\n\nfunction isAsyncMode(object) {\n {\n if (!hasWarnedAboutDeprecatedIsAsyncMode) {\n hasWarnedAboutDeprecatedIsAsyncMode = true; // Using console['warn'] to evade Babel and ESLint\n\n console['warn']('The ReactIs.isAsyncMode() alias has been deprecated, ' + 'and will be removed in React 18+.');\n }\n }\n\n return false;\n}\nfunction isConcurrentMode(object) {\n {\n if (!hasWarnedAboutDeprecatedIsConcurrentMode) {\n hasWarnedAboutDeprecatedIsConcurrentMode = true; // Using console['warn'] to evade Babel and ESLint\n\n console['warn']('The ReactIs.isConcurrentMode() alias has been deprecated, ' + 'and will be removed in React 18+.');\n }\n }\n\n return false;\n}\nfunction isContextConsumer(object) {\n return typeOf(object) === REACT_CONTEXT_TYPE;\n}\nfunction isContextProvider(object) {\n return typeOf(object) === REACT_PROVIDER_TYPE;\n}\nfunction isElement(object) {\n return typeof object === 'object' && object !== null && object.$$typeof === REACT_ELEMENT_TYPE;\n}\nfunction isForwardRef(object) {\n return typeOf(object) === REACT_FORWARD_REF_TYPE;\n}\nfunction isFragment(object) {\n return typeOf(object) === REACT_FRAGMENT_TYPE;\n}\nfunction isLazy(object) {\n return typeOf(object) === REACT_LAZY_TYPE;\n}\nfunction isMemo(object) {\n return typeOf(object) === REACT_MEMO_TYPE;\n}\nfunction isPortal(object) {\n return typeOf(object) === REACT_PORTAL_TYPE;\n}\nfunction isProfiler(object) {\n return typeOf(object) === REACT_PROFILER_TYPE;\n}\nfunction isStrictMode(object) {\n return typeOf(object) === REACT_STRICT_MODE_TYPE;\n}\nfunction isSuspense(object) {\n return typeOf(object) === REACT_SUSPENSE_TYPE;\n}\nfunction isSuspenseList(object) {\n return typeOf(object) === REACT_SUSPENSE_LIST_TYPE;\n}\n\nexports.ContextConsumer = ContextConsumer;\nexports.ContextProvider = ContextProvider;\nexports.Element = Element;\nexports.ForwardRef = ForwardRef;\nexports.Fragment = Fragment;\nexports.Lazy = Lazy;\nexports.Memo = Memo;\nexports.Portal = Portal;\nexports.Profiler = Profiler;\nexports.StrictMode = StrictMode;\nexports.Suspense = Suspense;\nexports.SuspenseList = SuspenseList;\nexports.isAsyncMode = isAsyncMode;\nexports.isConcurrentMode = isConcurrentMode;\nexports.isContextConsumer = isContextConsumer;\nexports.isContextProvider = isContextProvider;\nexports.isElement = isElement;\nexports.isForwardRef = isForwardRef;\nexports.isFragment = isFragment;\nexports.isLazy = isLazy;\nexports.isMemo = isMemo;\nexports.isPortal = isPortal;\nexports.isProfiler = isProfiler;\nexports.isStrictMode = isStrictMode;\nexports.isSuspense = isSuspense;\nexports.isSuspenseList = isSuspenseList;\nexports.isValidElementType = isValidElementType;\nexports.typeOf = typeOf;\n })();\n}\n","'use strict';\n\nif (process.env.NODE_ENV === 'production') {\n module.exports = require('./cjs/react-is.production.min.js');\n} else {\n module.exports = require('./cjs/react-is.development.js');\n}\n","import { ForwardRef, Memo } from 'react-is';\n\n// Simplified polyfill for IE11 support\n// https://github.com/JamesMGreene/Function.name/blob/58b314d4a983110c3682f1228f845d39ccca1817/Function.name.js#L3\nconst fnNameMatchRegex = /^\\s*function(?:\\s|\\s*\\/\\*.*\\*\\/\\s*)+([^(\\s/]*)\\s*/;\nexport function getFunctionName(fn) {\n const match = `${fn}`.match(fnNameMatchRegex);\n const name = match && match[1];\n return name || '';\n}\nfunction getFunctionComponentName(Component, fallback = '') {\n return Component.displayName || Component.name || getFunctionName(Component) || fallback;\n}\nfunction getWrappedName(outerType, innerType, wrapperName) {\n const functionName = getFunctionComponentName(innerType);\n return outerType.displayName || (functionName !== '' ? `${wrapperName}(${functionName})` : wrapperName);\n}\n\n/**\n * cherry-pick from\n * https://github.com/facebook/react/blob/769b1f270e1251d9dbdce0fcbd9e92e502d059b8/packages/shared/getComponentName.js\n * originally forked from recompose/getDisplayName with added IE11 support\n */\nexport default function getDisplayName(Component) {\n if (Component == null) {\n return undefined;\n }\n if (typeof Component === 'string') {\n return Component;\n }\n if (typeof Component === 'function') {\n return getFunctionComponentName(Component, 'Component');\n }\n\n // TypeScript can't have components as objects but they exist in the form of `memo` or `Suspense`\n if (typeof Component === 'object') {\n switch (Component.$$typeof) {\n case ForwardRef:\n return getWrappedName(Component, Component.render, 'ForwardRef');\n case Memo:\n return getWrappedName(Component, Component.type, 'memo');\n default:\n return undefined;\n }\n }\n return undefined;\n}","export default function HTMLElementType(props, propName, componentName, location, propFullName) {\n if (process.env.NODE_ENV === 'production') {\n return null;\n }\n const propValue = props[propName];\n const safePropName = propFullName || propName;\n if (propValue == null) {\n return null;\n }\n if (propValue && propValue.nodeType !== 1) {\n return new Error(`Invalid ${location} \\`${safePropName}\\` supplied to \\`${componentName}\\`. ` + `Expected an HTMLElement.`);\n }\n return null;\n}","import PropTypes from 'prop-types';\nconst refType = PropTypes.oneOfType([PropTypes.func, PropTypes.object]);\nexport default refType;","import _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\n// It should to be noted that this function isn't equivalent to `text-transform: capitalize`.\n//\n// A strict capitalization should uppercase the first letter of each word in the sentence.\n// We only handle the first word.\nexport default function capitalize(string) {\n if (typeof string !== 'string') {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: \\`capitalize(string)\\` expects a string argument.` : _formatMuiErrorMessage(7));\n }\n return string.charAt(0).toUpperCase() + string.slice(1);\n}","/**\n * Safe chained function.\n *\n * Will only create a new function if needed,\n * otherwise will pass back existing functions or null.\n */\nexport default function createChainedFunction(...funcs) {\n return funcs.reduce((acc, func) => {\n if (func == null) {\n return acc;\n }\n return function chainedFunction(...args) {\n acc.apply(this, args);\n func.apply(this, args);\n };\n }, () => {});\n}","// Corresponds to 10 frames at 60 Hz.\n// A few bytes payload overhead when lodash/debounce is ~3 kB and debounce ~300 B.\nexport default function debounce(func, wait = 166) {\n let timeout;\n function debounced(...args) {\n const later = () => {\n // @ts-ignore\n func.apply(this, args);\n };\n clearTimeout(timeout);\n timeout = setTimeout(later, wait);\n }\n debounced.clear = () => {\n clearTimeout(timeout);\n };\n return debounced;\n}","export default function deprecatedPropType(validator, reason) {\n if (process.env.NODE_ENV === 'production') {\n return () => null;\n }\n return (props, propName, componentName, location, propFullName) => {\n const componentNameSafe = componentName || '<>';\n const propFullNameSafe = propFullName || propName;\n if (typeof props[propName] !== 'undefined') {\n return new Error(`The ${location} \\`${propFullNameSafe}\\` of ` + `\\`${componentNameSafe}\\` is deprecated. ${reason}`);\n }\n return null;\n };\n}","import * as React from 'react';\nexport default function isMuiElement(element, muiNames) {\n var _muiName, _element$type;\n return /*#__PURE__*/React.isValidElement(element) && muiNames.indexOf( // For server components `muiName` is avaialble in element.type._payload.value.muiName\n // relevant info - https://github.com/facebook/react/blob/2807d781a08db8e9873687fccc25c0f12b4fb3d4/packages/react/src/ReactLazy.js#L45\n // eslint-disable-next-line no-underscore-dangle\n (_muiName = element.type.muiName) != null ? _muiName : (_element$type = element.type) == null || (_element$type = _element$type._payload) == null || (_element$type = _element$type.value) == null ? void 0 : _element$type.muiName) !== -1;\n}","export default function ownerDocument(node) {\n return node && node.ownerDocument || document;\n}","import ownerDocument from '../ownerDocument';\nexport default function ownerWindow(node) {\n const doc = ownerDocument(node);\n return doc.defaultView || window;\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nexport default function requirePropFactory(componentNameInError, Component) {\n if (process.env.NODE_ENV === 'production') {\n return () => null;\n }\n\n // eslint-disable-next-line react/forbid-foreign-prop-types\n const prevPropTypes = Component ? _extends({}, Component.propTypes) : null;\n const requireProp = requiredProp => (props, propName, componentName, location, propFullName, ...args) => {\n const propFullNameSafe = propFullName || propName;\n const defaultTypeChecker = prevPropTypes == null ? void 0 : prevPropTypes[propFullNameSafe];\n if (defaultTypeChecker) {\n const typeCheckerResult = defaultTypeChecker(props, propName, componentName, location, propFullName, ...args);\n if (typeCheckerResult) {\n return typeCheckerResult;\n }\n }\n if (typeof props[propName] !== 'undefined' && !props[requiredProp]) {\n return new Error(`The prop \\`${propFullNameSafe}\\` of ` + `\\`${componentNameInError}\\` can only be used together with the \\`${requiredProp}\\` prop.`);\n }\n return null;\n };\n return requireProp;\n}","/**\n * TODO v5: consider making it private\n *\n * passes {value} to {ref}\n *\n * WARNING: Be sure to only call this inside a callback that is passed as a ref.\n * Otherwise, make sure to cleanup the previous {ref} if it changes. See\n * https://github.com/mui/material-ui/issues/13539\n *\n * Useful if you want to expose the ref of an inner component to the public API\n * while still using it inside the component.\n * @param ref A ref callback or ref object. If anything falsy, this is a no-op.\n */\nexport default function setRef(ref, value) {\n if (typeof ref === 'function') {\n ref(value);\n } else if (ref) {\n ref.current = value;\n }\n}","'use client';\n\nimport * as React from 'react';\n\n/**\n * A version of `React.useLayoutEffect` that does not show a warning when server-side rendering.\n * This is useful for effects that are only needed for client-side rendering but not for SSR.\n *\n * Before you use this hook, make sure to read https://gist.github.com/gaearon/e7d97cdf38a2907924ea12e4ebdf3c85\n * and confirm it doesn't apply to your use-case.\n */\nconst useEnhancedEffect = typeof window !== 'undefined' ? React.useLayoutEffect : React.useEffect;\nexport default useEnhancedEffect;","'use client';\n\nimport * as React from 'react';\nlet globalId = 0;\nfunction useGlobalId(idOverride) {\n const [defaultId, setDefaultId] = React.useState(idOverride);\n const id = idOverride || defaultId;\n React.useEffect(() => {\n if (defaultId == null) {\n // Fallback to this default id when possible.\n // Use the incrementing value for client-side rendering only.\n // We can't use it server-side.\n // If you want to use random values please consider the Birthday Problem: https://en.wikipedia.org/wiki/Birthday_problem\n globalId += 1;\n setDefaultId(`mui-${globalId}`);\n }\n }, [defaultId]);\n return id;\n}\n\n// downstream bundlers may remove unnecessary concatenation, but won't remove toString call -- Workaround for https://github.com/webpack/webpack/issues/14814\nconst maybeReactUseId = React['useId'.toString()];\n/**\n *\n * @example
    \n * @param idOverride\n * @returns {string}\n */\nexport default function useId(idOverride) {\n if (maybeReactUseId !== undefined) {\n const reactId = maybeReactUseId();\n return idOverride != null ? idOverride : reactId;\n }\n // eslint-disable-next-line react-hooks/rules-of-hooks -- `React.useId` is invariant at runtime.\n return useGlobalId(idOverride);\n}","export default function unsupportedProp(props, propName, componentName, location, propFullName) {\n if (process.env.NODE_ENV === 'production') {\n return null;\n }\n const propFullNameSafe = propFullName || propName;\n if (typeof props[propName] !== 'undefined') {\n return new Error(`The prop \\`${propFullNameSafe}\\` is not supported. Please remove it.`);\n }\n return null;\n}","'use client';\n\n/* eslint-disable react-hooks/rules-of-hooks, react-hooks/exhaustive-deps */\nimport * as React from 'react';\nexport default function useControlled({\n controlled,\n default: defaultProp,\n name,\n state = 'value'\n}) {\n // isControlled is ignored in the hook dependency lists as it should never change.\n const {\n current: isControlled\n } = React.useRef(controlled !== undefined);\n const [valueState, setValue] = React.useState(defaultProp);\n const value = isControlled ? controlled : valueState;\n if (process.env.NODE_ENV !== 'production') {\n React.useEffect(() => {\n if (isControlled !== (controlled !== undefined)) {\n console.error([`MUI: A component is changing the ${isControlled ? '' : 'un'}controlled ${state} state of ${name} to be ${isControlled ? 'un' : ''}controlled.`, 'Elements should not switch from uncontrolled to controlled (or vice versa).', `Decide between using a controlled or uncontrolled ${name} ` + 'element for the lifetime of the component.', \"The nature of the state is determined during the first render. It's considered controlled if the value is not `undefined`.\", 'More info: https://fb.me/react-controlled-components'].join('\\n'));\n }\n }, [state, name, controlled]);\n const {\n current: defaultValue\n } = React.useRef(defaultProp);\n React.useEffect(() => {\n if (!isControlled && defaultValue !== defaultProp) {\n console.error([`MUI: A component is changing the default ${state} state of an uncontrolled ${name} after being initialized. ` + `To suppress this warning opt to use a controlled ${name}.`].join('\\n'));\n }\n }, [JSON.stringify(defaultProp)]);\n }\n const setValueIfUncontrolled = React.useCallback(newValue => {\n if (!isControlled) {\n setValue(newValue);\n }\n }, []);\n return [value, setValueIfUncontrolled];\n}","'use client';\n\nimport * as React from 'react';\nimport useEnhancedEffect from '../useEnhancedEffect';\n\n/**\n * Inspired by https://github.com/facebook/react/issues/14099#issuecomment-440013892\n * See RFC in https://github.com/reactjs/rfcs/pull/220\n */\n\nfunction useEventCallback(fn) {\n const ref = React.useRef(fn);\n useEnhancedEffect(() => {\n ref.current = fn;\n });\n return React.useRef((...args) =>\n // @ts-expect-error hide `this`\n (0, ref.current)(...args)).current;\n}\nexport default useEventCallback;","'use client';\n\nimport * as React from 'react';\nimport setRef from '../setRef';\nexport default function useForkRef(...refs) {\n /**\n * This will create a new function if the refs passed to this hook change and are all defined.\n * This means react will call the old forkRef with `null` and the new forkRef\n * with the ref. Cleanup naturally emerges from this behavior.\n */\n return React.useMemo(() => {\n if (refs.every(ref => ref == null)) {\n return null;\n }\n return instance => {\n refs.forEach(ref => {\n setRef(ref, instance);\n });\n };\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, refs);\n}","'use client';\n\nimport * as React from 'react';\nconst UNINITIALIZED = {};\n\n/**\n * A React.useRef() that is initialized lazily with a function. Note that it accepts an optional\n * initialization argument, so the initialization function doesn't need to be an inline closure.\n *\n * @usage\n * const ref = useLazyRef(sortColumns, columns)\n */\nexport default function useLazyRef(init, initArg) {\n const ref = React.useRef(UNINITIALIZED);\n if (ref.current === UNINITIALIZED) {\n ref.current = init(initArg);\n }\n return ref;\n}","'use client';\n\nimport * as React from 'react';\nconst EMPTY = [];\n\n/**\n * A React.useEffect equivalent that runs once, when the component is mounted.\n */\nexport default function useOnMount(fn) {\n /* eslint-disable react-hooks/exhaustive-deps */\n React.useEffect(fn, EMPTY);\n /* eslint-enable react-hooks/exhaustive-deps */\n}","'use client';\n\nimport useLazyRef from '../useLazyRef/useLazyRef';\nimport useOnMount from '../useOnMount/useOnMount';\nexport class Timeout {\n constructor() {\n this.currentId = null;\n this.clear = () => {\n if (this.currentId !== null) {\n clearTimeout(this.currentId);\n this.currentId = null;\n }\n };\n this.disposeEffect = () => {\n return this.clear;\n };\n }\n static create() {\n return new Timeout();\n }\n /**\n * Executes `fn` after `delay`, clearing any previously scheduled call.\n */\n start(delay, fn) {\n this.clear();\n this.currentId = setTimeout(() => {\n this.currentId = null;\n fn();\n }, delay);\n }\n}\nexport default function useTimeout() {\n const timeout = useLazyRef(Timeout.create).current;\n useOnMount(timeout.disposeEffect);\n return timeout;\n}","'use client';\n\n// based on https://github.com/WICG/focus-visible/blob/v4.1.5/src/focus-visible.js\nimport * as React from 'react';\nimport { Timeout } from '../useTimeout/useTimeout';\nlet hadKeyboardEvent = true;\nlet hadFocusVisibleRecently = false;\nconst hadFocusVisibleRecentlyTimeout = new Timeout();\nconst inputTypesWhitelist = {\n text: true,\n search: true,\n url: true,\n tel: true,\n email: true,\n password: true,\n number: true,\n date: true,\n month: true,\n week: true,\n time: true,\n datetime: true,\n 'datetime-local': true\n};\n\n/**\n * Computes whether the given element should automatically trigger the\n * `focus-visible` class being added, i.e. whether it should always match\n * `:focus-visible` when focused.\n * @param {Element} node\n * @returns {boolean}\n */\nfunction focusTriggersKeyboardModality(node) {\n const {\n type,\n tagName\n } = node;\n if (tagName === 'INPUT' && inputTypesWhitelist[type] && !node.readOnly) {\n return true;\n }\n if (tagName === 'TEXTAREA' && !node.readOnly) {\n return true;\n }\n if (node.isContentEditable) {\n return true;\n }\n return false;\n}\n\n/**\n * Keep track of our keyboard modality state with `hadKeyboardEvent`.\n * If the most recent user interaction was via the keyboard;\n * and the key press did not include a meta, alt/option, or control key;\n * then the modality is keyboard. Otherwise, the modality is not keyboard.\n * @param {KeyboardEvent} event\n */\nfunction handleKeyDown(event) {\n if (event.metaKey || event.altKey || event.ctrlKey) {\n return;\n }\n hadKeyboardEvent = true;\n}\n\n/**\n * If at any point a user clicks with a pointing device, ensure that we change\n * the modality away from keyboard.\n * This avoids the situation where a user presses a key on an already focused\n * element, and then clicks on a different element, focusing it with a\n * pointing device, while we still think we're in keyboard modality.\n */\nfunction handlePointerDown() {\n hadKeyboardEvent = false;\n}\nfunction handleVisibilityChange() {\n if (this.visibilityState === 'hidden') {\n // If the tab becomes active again, the browser will handle calling focus\n // on the element (Safari actually calls it twice).\n // If this tab change caused a blur on an element with focus-visible,\n // re-apply the class when the user switches back to the tab.\n if (hadFocusVisibleRecently) {\n hadKeyboardEvent = true;\n }\n }\n}\nfunction prepare(doc) {\n doc.addEventListener('keydown', handleKeyDown, true);\n doc.addEventListener('mousedown', handlePointerDown, true);\n doc.addEventListener('pointerdown', handlePointerDown, true);\n doc.addEventListener('touchstart', handlePointerDown, true);\n doc.addEventListener('visibilitychange', handleVisibilityChange, true);\n}\nexport function teardown(doc) {\n doc.removeEventListener('keydown', handleKeyDown, true);\n doc.removeEventListener('mousedown', handlePointerDown, true);\n doc.removeEventListener('pointerdown', handlePointerDown, true);\n doc.removeEventListener('touchstart', handlePointerDown, true);\n doc.removeEventListener('visibilitychange', handleVisibilityChange, true);\n}\nfunction isFocusVisible(event) {\n const {\n target\n } = event;\n try {\n return target.matches(':focus-visible');\n } catch (error) {\n // Browsers not implementing :focus-visible will throw a SyntaxError.\n // We use our own heuristic for those browsers.\n // Rethrow might be better if it's not the expected error but do we really\n // want to crash if focus-visible malfunctioned?\n }\n\n // No need for validFocusTarget check. The user does that by attaching it to\n // focusable events only.\n return hadKeyboardEvent || focusTriggersKeyboardModality(target);\n}\nexport default function useIsFocusVisible() {\n const ref = React.useCallback(node => {\n if (node != null) {\n prepare(node.ownerDocument);\n }\n }, []);\n const isFocusVisibleRef = React.useRef(false);\n\n /**\n * Should be called if a blur event is fired\n */\n function handleBlurVisible() {\n // checking against potential state variable does not suffice if we focus and blur synchronously.\n // React wouldn't have time to trigger a re-render so `focusVisible` would be stale.\n // Ideally we would adjust `isFocusVisible(event)` to look at `relatedTarget` for blur events.\n // This doesn't work in IE11 due to https://github.com/facebook/react/issues/3751\n // TODO: check again if React releases their internal changes to focus event handling (https://github.com/facebook/react/pull/19186).\n if (isFocusVisibleRef.current) {\n // To detect a tab/window switch, we look for a blur event followed\n // rapidly by a visibility change.\n // If we don't see a visibility change within 100ms, it's probably a\n // regular focus change.\n hadFocusVisibleRecently = true;\n hadFocusVisibleRecentlyTimeout.start(100, () => {\n hadFocusVisibleRecently = false;\n });\n isFocusVisibleRef.current = false;\n return true;\n }\n return false;\n }\n\n /**\n * Should be called if a blur event is fired\n */\n function handleFocusVisible(event) {\n if (isFocusVisible(event)) {\n isFocusVisibleRef.current = true;\n return true;\n }\n return false;\n }\n return {\n isFocusVisibleRef,\n onFocus: handleFocusVisible,\n onBlur: handleBlurVisible,\n ref\n };\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\n/**\n * Add keys, values of `defaultProps` that does not exist in `props`\n * @param {object} defaultProps\n * @param {object} props\n * @returns {object} resolved props\n */\nexport default function resolveProps(defaultProps, props) {\n const output = _extends({}, props);\n Object.keys(defaultProps).forEach(propName => {\n if (propName.toString().match(/^(components|slots)$/)) {\n output[propName] = _extends({}, defaultProps[propName], output[propName]);\n } else if (propName.toString().match(/^(componentsProps|slotProps)$/)) {\n const defaultSlotProps = defaultProps[propName] || {};\n const slotProps = props[propName];\n output[propName] = {};\n if (!slotProps || !Object.keys(slotProps)) {\n // Reduce the iteration if the slot props is empty\n output[propName] = defaultSlotProps;\n } else if (!defaultSlotProps || !Object.keys(defaultSlotProps)) {\n // Reduce the iteration if the default slot props is empty\n output[propName] = slotProps;\n } else {\n output[propName] = _extends({}, slotProps);\n Object.keys(defaultSlotProps).forEach(slotPropName => {\n output[propName][slotPropName] = resolveProps(defaultSlotProps[slotPropName], slotProps[slotPropName]);\n });\n }\n } else if (output[propName] === undefined) {\n output[propName] = defaultProps[propName];\n }\n });\n return output;\n}","export default function composeClasses(slots, getUtilityClass, classes = undefined) {\n const output = {};\n Object.keys(slots).forEach(\n // `Object.keys(slots)` can't be wider than `T` because we infer `T` from `slots`.\n // @ts-expect-error https://github.com/microsoft/TypeScript/pull/12253#issuecomment-263132208\n slot => {\n output[slot] = slots[slot].reduce((acc, key) => {\n if (key) {\n const utilityClass = getUtilityClass(key);\n if (utilityClass !== '') {\n acc.push(utilityClass);\n }\n if (classes && classes[key]) {\n acc.push(classes[key]);\n }\n }\n return acc;\n }, []).join(' ');\n });\n return output;\n}","const defaultGenerator = componentName => componentName;\nconst createClassNameGenerator = () => {\n let generate = defaultGenerator;\n return {\n configure(generator) {\n generate = generator;\n },\n generate(componentName) {\n return generate(componentName);\n },\n reset() {\n generate = defaultGenerator;\n }\n };\n};\nconst ClassNameGenerator = createClassNameGenerator();\nexport default ClassNameGenerator;","import ClassNameGenerator from '../ClassNameGenerator';\nexport const globalStateClasses = {\n active: 'active',\n checked: 'checked',\n completed: 'completed',\n disabled: 'disabled',\n error: 'error',\n expanded: 'expanded',\n focused: 'focused',\n focusVisible: 'focusVisible',\n open: 'open',\n readOnly: 'readOnly',\n required: 'required',\n selected: 'selected'\n};\nexport default function generateUtilityClass(componentName, slot, globalStatePrefix = 'Mui') {\n const globalStateClass = globalStateClasses[slot];\n return globalStateClass ? `${globalStatePrefix}-${globalStateClass}` : `${ClassNameGenerator.generate(componentName)}-${slot}`;\n}\nexport function isGlobalState(slot) {\n return globalStateClasses[slot] !== undefined;\n}","import generateUtilityClass from '../generateUtilityClass';\nexport default function generateUtilityClasses(componentName, slots, globalStatePrefix = 'Mui') {\n const result = {};\n slots.forEach(slot => {\n result[slot] = generateUtilityClass(componentName, slot, globalStatePrefix);\n });\n return result;\n}","function clamp(val, min = Number.MIN_SAFE_INTEGER, max = Number.MAX_SAFE_INTEGER) {\n return Math.max(min, Math.min(val, max));\n}\nexport default clamp;","export default function _objectWithoutPropertiesLoose(source, excluded) {\n if (source == null) return {};\n var target = {};\n var sourceKeys = Object.keys(source);\n var key, i;\n for (i = 0; i < sourceKeys.length; i++) {\n key = sourceKeys[i];\n if (excluded.indexOf(key) >= 0) continue;\n target[key] = source[key];\n }\n return target;\n}","import _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nconst _excluded = [\"values\", \"unit\", \"step\"];\n// Sorted ASC by size. That's important.\n// It can't be configured as it's used statically for propTypes.\nexport const breakpointKeys = ['xs', 'sm', 'md', 'lg', 'xl'];\nconst sortBreakpointsValues = values => {\n const breakpointsAsArray = Object.keys(values).map(key => ({\n key,\n val: values[key]\n })) || [];\n // Sort in ascending order\n breakpointsAsArray.sort((breakpoint1, breakpoint2) => breakpoint1.val - breakpoint2.val);\n return breakpointsAsArray.reduce((acc, obj) => {\n return _extends({}, acc, {\n [obj.key]: obj.val\n });\n }, {});\n};\n\n// Keep in mind that @media is inclusive by the CSS specification.\nexport default function createBreakpoints(breakpoints) {\n const {\n // The breakpoint **start** at this value.\n // For instance with the first breakpoint xs: [xs, sm).\n values = {\n xs: 0,\n // phone\n sm: 600,\n // tablet\n md: 900,\n // small laptop\n lg: 1200,\n // desktop\n xl: 1536 // large screen\n },\n unit = 'px',\n step = 5\n } = breakpoints,\n other = _objectWithoutPropertiesLoose(breakpoints, _excluded);\n const sortedValues = sortBreakpointsValues(values);\n const keys = Object.keys(sortedValues);\n function up(key) {\n const value = typeof values[key] === 'number' ? values[key] : key;\n return `@media (min-width:${value}${unit})`;\n }\n function down(key) {\n const value = typeof values[key] === 'number' ? values[key] : key;\n return `@media (max-width:${value - step / 100}${unit})`;\n }\n function between(start, end) {\n const endIndex = keys.indexOf(end);\n return `@media (min-width:${typeof values[start] === 'number' ? values[start] : start}${unit}) and ` + `(max-width:${(endIndex !== -1 && typeof values[keys[endIndex]] === 'number' ? values[keys[endIndex]] : end) - step / 100}${unit})`;\n }\n function only(key) {\n if (keys.indexOf(key) + 1 < keys.length) {\n return between(key, keys[keys.indexOf(key) + 1]);\n }\n return up(key);\n }\n function not(key) {\n // handle first and last key separately, for better readability\n const keyIndex = keys.indexOf(key);\n if (keyIndex === 0) {\n return up(keys[1]);\n }\n if (keyIndex === keys.length - 1) {\n return down(keys[keyIndex]);\n }\n return between(key, keys[keys.indexOf(key) + 1]).replace('@media', '@media not all and');\n }\n return _extends({\n keys,\n values: sortedValues,\n up,\n down,\n between,\n only,\n not,\n unit\n }, other);\n}","const shape = {\n borderRadius: 4\n};\nexport default shape;","import PropTypes from 'prop-types';\nconst responsivePropType = process.env.NODE_ENV !== 'production' ? PropTypes.oneOfType([PropTypes.number, PropTypes.string, PropTypes.object, PropTypes.array]) : {};\nexport default responsivePropType;","import deepmerge from '@mui/utils/deepmerge';\nfunction merge(acc, item) {\n if (!item) {\n return acc;\n }\n return deepmerge(acc, item, {\n clone: false // No need to clone deep, it's way faster.\n });\n}\nexport default merge;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport PropTypes from 'prop-types';\nimport deepmerge from '@mui/utils/deepmerge';\nimport merge from './merge';\n\n// The breakpoint **start** at this value.\n// For instance with the first breakpoint xs: [xs, sm[.\nexport const values = {\n xs: 0,\n // phone\n sm: 600,\n // tablet\n md: 900,\n // small laptop\n lg: 1200,\n // desktop\n xl: 1536 // large screen\n};\nconst defaultBreakpoints = {\n // Sorted ASC by size. That's important.\n // It can't be configured as it's used statically for propTypes.\n keys: ['xs', 'sm', 'md', 'lg', 'xl'],\n up: key => `@media (min-width:${values[key]}px)`\n};\nexport function handleBreakpoints(props, propValue, styleFromPropValue) {\n const theme = props.theme || {};\n if (Array.isArray(propValue)) {\n const themeBreakpoints = theme.breakpoints || defaultBreakpoints;\n return propValue.reduce((acc, item, index) => {\n acc[themeBreakpoints.up(themeBreakpoints.keys[index])] = styleFromPropValue(propValue[index]);\n return acc;\n }, {});\n }\n if (typeof propValue === 'object') {\n const themeBreakpoints = theme.breakpoints || defaultBreakpoints;\n return Object.keys(propValue).reduce((acc, breakpoint) => {\n // key is breakpoint\n if (Object.keys(themeBreakpoints.values || values).indexOf(breakpoint) !== -1) {\n const mediaKey = themeBreakpoints.up(breakpoint);\n acc[mediaKey] = styleFromPropValue(propValue[breakpoint], breakpoint);\n } else {\n const cssKey = breakpoint;\n acc[cssKey] = propValue[cssKey];\n }\n return acc;\n }, {});\n }\n const output = styleFromPropValue(propValue);\n return output;\n}\nfunction breakpoints(styleFunction) {\n // false positive\n // eslint-disable-next-line react/function-component-definition\n const newStyleFunction = props => {\n const theme = props.theme || {};\n const base = styleFunction(props);\n const themeBreakpoints = theme.breakpoints || defaultBreakpoints;\n const extended = themeBreakpoints.keys.reduce((acc, key) => {\n if (props[key]) {\n acc = acc || {};\n acc[themeBreakpoints.up(key)] = styleFunction(_extends({\n theme\n }, props[key]));\n }\n return acc;\n }, null);\n return merge(base, extended);\n };\n newStyleFunction.propTypes = process.env.NODE_ENV !== 'production' ? _extends({}, styleFunction.propTypes, {\n xs: PropTypes.object,\n sm: PropTypes.object,\n md: PropTypes.object,\n lg: PropTypes.object,\n xl: PropTypes.object\n }) : {};\n newStyleFunction.filterProps = ['xs', 'sm', 'md', 'lg', 'xl', ...styleFunction.filterProps];\n return newStyleFunction;\n}\nexport function createEmptyBreakpointObject(breakpointsInput = {}) {\n var _breakpointsInput$key;\n const breakpointsInOrder = (_breakpointsInput$key = breakpointsInput.keys) == null ? void 0 : _breakpointsInput$key.reduce((acc, key) => {\n const breakpointStyleKey = breakpointsInput.up(key);\n acc[breakpointStyleKey] = {};\n return acc;\n }, {});\n return breakpointsInOrder || {};\n}\nexport function removeUnusedBreakpoints(breakpointKeys, style) {\n return breakpointKeys.reduce((acc, key) => {\n const breakpointOutput = acc[key];\n const isBreakpointUnused = !breakpointOutput || Object.keys(breakpointOutput).length === 0;\n if (isBreakpointUnused) {\n delete acc[key];\n }\n return acc;\n }, style);\n}\nexport function mergeBreakpointsInOrder(breakpointsInput, ...styles) {\n const emptyBreakpoints = createEmptyBreakpointObject(breakpointsInput);\n const mergedOutput = [emptyBreakpoints, ...styles].reduce((prev, next) => deepmerge(prev, next), {});\n return removeUnusedBreakpoints(Object.keys(emptyBreakpoints), mergedOutput);\n}\n\n// compute base for responsive values; e.g.,\n// [1,2,3] => {xs: true, sm: true, md: true}\n// {xs: 1, sm: 2, md: 3} => {xs: true, sm: true, md: true}\nexport function computeBreakpointsBase(breakpointValues, themeBreakpoints) {\n // fixed value\n if (typeof breakpointValues !== 'object') {\n return {};\n }\n const base = {};\n const breakpointsKeys = Object.keys(themeBreakpoints);\n if (Array.isArray(breakpointValues)) {\n breakpointsKeys.forEach((breakpoint, i) => {\n if (i < breakpointValues.length) {\n base[breakpoint] = true;\n }\n });\n } else {\n breakpointsKeys.forEach(breakpoint => {\n if (breakpointValues[breakpoint] != null) {\n base[breakpoint] = true;\n }\n });\n }\n return base;\n}\nexport function resolveBreakpointValues({\n values: breakpointValues,\n breakpoints: themeBreakpoints,\n base: customBase\n}) {\n const base = customBase || computeBreakpointsBase(breakpointValues, themeBreakpoints);\n const keys = Object.keys(base);\n if (keys.length === 0) {\n return breakpointValues;\n }\n let previous;\n return keys.reduce((acc, breakpoint, i) => {\n if (Array.isArray(breakpointValues)) {\n acc[breakpoint] = breakpointValues[i] != null ? breakpointValues[i] : breakpointValues[previous];\n previous = i;\n } else if (typeof breakpointValues === 'object') {\n acc[breakpoint] = breakpointValues[breakpoint] != null ? breakpointValues[breakpoint] : breakpointValues[previous];\n previous = breakpoint;\n } else {\n acc[breakpoint] = breakpointValues;\n }\n return acc;\n }, {});\n}\nexport default breakpoints;","import capitalize from '@mui/utils/capitalize';\nimport responsivePropType from './responsivePropType';\nimport { handleBreakpoints } from './breakpoints';\nexport function getPath(obj, path, checkVars = true) {\n if (!path || typeof path !== 'string') {\n return null;\n }\n\n // Check if CSS variables are used\n if (obj && obj.vars && checkVars) {\n const val = `vars.${path}`.split('.').reduce((acc, item) => acc && acc[item] ? acc[item] : null, obj);\n if (val != null) {\n return val;\n }\n }\n return path.split('.').reduce((acc, item) => {\n if (acc && acc[item] != null) {\n return acc[item];\n }\n return null;\n }, obj);\n}\nexport function getStyleValue(themeMapping, transform, propValueFinal, userValue = propValueFinal) {\n let value;\n if (typeof themeMapping === 'function') {\n value = themeMapping(propValueFinal);\n } else if (Array.isArray(themeMapping)) {\n value = themeMapping[propValueFinal] || userValue;\n } else {\n value = getPath(themeMapping, propValueFinal) || userValue;\n }\n if (transform) {\n value = transform(value, userValue, themeMapping);\n }\n return value;\n}\nfunction style(options) {\n const {\n prop,\n cssProperty = options.prop,\n themeKey,\n transform\n } = options;\n\n // false positive\n // eslint-disable-next-line react/function-component-definition\n const fn = props => {\n if (props[prop] == null) {\n return null;\n }\n const propValue = props[prop];\n const theme = props.theme;\n const themeMapping = getPath(theme, themeKey) || {};\n const styleFromPropValue = propValueFinal => {\n let value = getStyleValue(themeMapping, transform, propValueFinal);\n if (propValueFinal === value && typeof propValueFinal === 'string') {\n // Haven't found value\n value = getStyleValue(themeMapping, transform, `${prop}${propValueFinal === 'default' ? '' : capitalize(propValueFinal)}`, propValueFinal);\n }\n if (cssProperty === false) {\n return value;\n }\n return {\n [cssProperty]: value\n };\n };\n return handleBreakpoints(props, propValue, styleFromPropValue);\n };\n fn.propTypes = process.env.NODE_ENV !== 'production' ? {\n [prop]: responsivePropType\n } : {};\n fn.filterProps = [prop];\n return fn;\n}\nexport default style;","export default function memoize(fn) {\n const cache = {};\n return arg => {\n if (cache[arg] === undefined) {\n cache[arg] = fn(arg);\n }\n return cache[arg];\n };\n}","import responsivePropType from './responsivePropType';\nimport { handleBreakpoints } from './breakpoints';\nimport { getPath } from './style';\nimport merge from './merge';\nimport memoize from './memoize';\nconst properties = {\n m: 'margin',\n p: 'padding'\n};\nconst directions = {\n t: 'Top',\n r: 'Right',\n b: 'Bottom',\n l: 'Left',\n x: ['Left', 'Right'],\n y: ['Top', 'Bottom']\n};\nconst aliases = {\n marginX: 'mx',\n marginY: 'my',\n paddingX: 'px',\n paddingY: 'py'\n};\n\n// memoize() impact:\n// From 300,000 ops/sec\n// To 350,000 ops/sec\nconst getCssProperties = memoize(prop => {\n // It's not a shorthand notation.\n if (prop.length > 2) {\n if (aliases[prop]) {\n prop = aliases[prop];\n } else {\n return [prop];\n }\n }\n const [a, b] = prop.split('');\n const property = properties[a];\n const direction = directions[b] || '';\n return Array.isArray(direction) ? direction.map(dir => property + dir) : [property + direction];\n});\nexport const marginKeys = ['m', 'mt', 'mr', 'mb', 'ml', 'mx', 'my', 'margin', 'marginTop', 'marginRight', 'marginBottom', 'marginLeft', 'marginX', 'marginY', 'marginInline', 'marginInlineStart', 'marginInlineEnd', 'marginBlock', 'marginBlockStart', 'marginBlockEnd'];\nexport const paddingKeys = ['p', 'pt', 'pr', 'pb', 'pl', 'px', 'py', 'padding', 'paddingTop', 'paddingRight', 'paddingBottom', 'paddingLeft', 'paddingX', 'paddingY', 'paddingInline', 'paddingInlineStart', 'paddingInlineEnd', 'paddingBlock', 'paddingBlockStart', 'paddingBlockEnd'];\nconst spacingKeys = [...marginKeys, ...paddingKeys];\nexport function createUnaryUnit(theme, themeKey, defaultValue, propName) {\n var _getPath;\n const themeSpacing = (_getPath = getPath(theme, themeKey, false)) != null ? _getPath : defaultValue;\n if (typeof themeSpacing === 'number') {\n return abs => {\n if (typeof abs === 'string') {\n return abs;\n }\n if (process.env.NODE_ENV !== 'production') {\n if (typeof abs !== 'number') {\n console.error(`MUI: Expected ${propName} argument to be a number or a string, got ${abs}.`);\n }\n }\n return themeSpacing * abs;\n };\n }\n if (Array.isArray(themeSpacing)) {\n return abs => {\n if (typeof abs === 'string') {\n return abs;\n }\n if (process.env.NODE_ENV !== 'production') {\n if (!Number.isInteger(abs)) {\n console.error([`MUI: The \\`theme.${themeKey}\\` array type cannot be combined with non integer values.` + `You should either use an integer value that can be used as index, or define the \\`theme.${themeKey}\\` as a number.`].join('\\n'));\n } else if (abs > themeSpacing.length - 1) {\n console.error([`MUI: The value provided (${abs}) overflows.`, `The supported values are: ${JSON.stringify(themeSpacing)}.`, `${abs} > ${themeSpacing.length - 1}, you need to add the missing values.`].join('\\n'));\n }\n }\n return themeSpacing[abs];\n };\n }\n if (typeof themeSpacing === 'function') {\n return themeSpacing;\n }\n if (process.env.NODE_ENV !== 'production') {\n console.error([`MUI: The \\`theme.${themeKey}\\` value (${themeSpacing}) is invalid.`, 'It should be a number, an array or a function.'].join('\\n'));\n }\n return () => undefined;\n}\nexport function createUnarySpacing(theme) {\n return createUnaryUnit(theme, 'spacing', 8, 'spacing');\n}\nexport function getValue(transformer, propValue) {\n if (typeof propValue === 'string' || propValue == null) {\n return propValue;\n }\n const abs = Math.abs(propValue);\n const transformed = transformer(abs);\n if (propValue >= 0) {\n return transformed;\n }\n if (typeof transformed === 'number') {\n return -transformed;\n }\n return `-${transformed}`;\n}\nexport function getStyleFromPropValue(cssProperties, transformer) {\n return propValue => cssProperties.reduce((acc, cssProperty) => {\n acc[cssProperty] = getValue(transformer, propValue);\n return acc;\n }, {});\n}\nfunction resolveCssProperty(props, keys, prop, transformer) {\n // Using a hash computation over an array iteration could be faster, but with only 28 items,\n // it's doesn't worth the bundle size.\n if (keys.indexOf(prop) === -1) {\n return null;\n }\n const cssProperties = getCssProperties(prop);\n const styleFromPropValue = getStyleFromPropValue(cssProperties, transformer);\n const propValue = props[prop];\n return handleBreakpoints(props, propValue, styleFromPropValue);\n}\nfunction style(props, keys) {\n const transformer = createUnarySpacing(props.theme);\n return Object.keys(props).map(prop => resolveCssProperty(props, keys, prop, transformer)).reduce(merge, {});\n}\nexport function margin(props) {\n return style(props, marginKeys);\n}\nmargin.propTypes = process.env.NODE_ENV !== 'production' ? marginKeys.reduce((obj, key) => {\n obj[key] = responsivePropType;\n return obj;\n}, {}) : {};\nmargin.filterProps = marginKeys;\nexport function padding(props) {\n return style(props, paddingKeys);\n}\npadding.propTypes = process.env.NODE_ENV !== 'production' ? paddingKeys.reduce((obj, key) => {\n obj[key] = responsivePropType;\n return obj;\n}, {}) : {};\npadding.filterProps = paddingKeys;\nfunction spacing(props) {\n return style(props, spacingKeys);\n}\nspacing.propTypes = process.env.NODE_ENV !== 'production' ? spacingKeys.reduce((obj, key) => {\n obj[key] = responsivePropType;\n return obj;\n}, {}) : {};\nspacing.filterProps = spacingKeys;\nexport default spacing;","import { createUnarySpacing } from '../spacing';\n\n// The different signatures imply different meaning for their arguments that can't be expressed structurally.\n// We express the difference with variable names.\n\nexport default function createSpacing(spacingInput = 8) {\n // Already transformed.\n if (spacingInput.mui) {\n return spacingInput;\n }\n\n // Material Design layouts are visually balanced. Most measurements align to an 8dp grid, which aligns both spacing and the overall layout.\n // Smaller components, such as icons, can align to a 4dp grid.\n // https://m2.material.io/design/layout/understanding-layout.html\n const transform = createUnarySpacing({\n spacing: spacingInput\n });\n const spacing = (...argsInput) => {\n if (process.env.NODE_ENV !== 'production') {\n if (!(argsInput.length <= 4)) {\n console.error(`MUI: Too many arguments provided, expected between 0 and 4, got ${argsInput.length}`);\n }\n }\n const args = argsInput.length === 0 ? [1] : argsInput;\n return args.map(argument => {\n const output = transform(argument);\n return typeof output === 'number' ? `${output}px` : output;\n }).join(' ');\n };\n spacing.mui = true;\n return spacing;\n}","import merge from './merge';\nfunction compose(...styles) {\n const handlers = styles.reduce((acc, style) => {\n style.filterProps.forEach(prop => {\n acc[prop] = style;\n });\n return acc;\n }, {});\n\n // false positive\n // eslint-disable-next-line react/function-component-definition\n const fn = props => {\n return Object.keys(props).reduce((acc, prop) => {\n if (handlers[prop]) {\n return merge(acc, handlers[prop](props));\n }\n return acc;\n }, {});\n };\n fn.propTypes = process.env.NODE_ENV !== 'production' ? styles.reduce((acc, style) => Object.assign(acc, style.propTypes), {}) : {};\n fn.filterProps = styles.reduce((acc, style) => acc.concat(style.filterProps), []);\n return fn;\n}\nexport default compose;","import responsivePropType from './responsivePropType';\nimport style from './style';\nimport compose from './compose';\nimport { createUnaryUnit, getValue } from './spacing';\nimport { handleBreakpoints } from './breakpoints';\nexport function borderTransform(value) {\n if (typeof value !== 'number') {\n return value;\n }\n return `${value}px solid`;\n}\nfunction createBorderStyle(prop, transform) {\n return style({\n prop,\n themeKey: 'borders',\n transform\n });\n}\nexport const border = createBorderStyle('border', borderTransform);\nexport const borderTop = createBorderStyle('borderTop', borderTransform);\nexport const borderRight = createBorderStyle('borderRight', borderTransform);\nexport const borderBottom = createBorderStyle('borderBottom', borderTransform);\nexport const borderLeft = createBorderStyle('borderLeft', borderTransform);\nexport const borderColor = createBorderStyle('borderColor');\nexport const borderTopColor = createBorderStyle('borderTopColor');\nexport const borderRightColor = createBorderStyle('borderRightColor');\nexport const borderBottomColor = createBorderStyle('borderBottomColor');\nexport const borderLeftColor = createBorderStyle('borderLeftColor');\nexport const outline = createBorderStyle('outline', borderTransform);\nexport const outlineColor = createBorderStyle('outlineColor');\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const borderRadius = props => {\n if (props.borderRadius !== undefined && props.borderRadius !== null) {\n const transformer = createUnaryUnit(props.theme, 'shape.borderRadius', 4, 'borderRadius');\n const styleFromPropValue = propValue => ({\n borderRadius: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.borderRadius, styleFromPropValue);\n }\n return null;\n};\nborderRadius.propTypes = process.env.NODE_ENV !== 'production' ? {\n borderRadius: responsivePropType\n} : {};\nborderRadius.filterProps = ['borderRadius'];\nconst borders = compose(border, borderTop, borderRight, borderBottom, borderLeft, borderColor, borderTopColor, borderRightColor, borderBottomColor, borderLeftColor, borderRadius, outline, outlineColor);\nexport default borders;","import style from './style';\nimport compose from './compose';\nimport { createUnaryUnit, getValue } from './spacing';\nimport { handleBreakpoints } from './breakpoints';\nimport responsivePropType from './responsivePropType';\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const gap = props => {\n if (props.gap !== undefined && props.gap !== null) {\n const transformer = createUnaryUnit(props.theme, 'spacing', 8, 'gap');\n const styleFromPropValue = propValue => ({\n gap: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.gap, styleFromPropValue);\n }\n return null;\n};\ngap.propTypes = process.env.NODE_ENV !== 'production' ? {\n gap: responsivePropType\n} : {};\ngap.filterProps = ['gap'];\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const columnGap = props => {\n if (props.columnGap !== undefined && props.columnGap !== null) {\n const transformer = createUnaryUnit(props.theme, 'spacing', 8, 'columnGap');\n const styleFromPropValue = propValue => ({\n columnGap: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.columnGap, styleFromPropValue);\n }\n return null;\n};\ncolumnGap.propTypes = process.env.NODE_ENV !== 'production' ? {\n columnGap: responsivePropType\n} : {};\ncolumnGap.filterProps = ['columnGap'];\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const rowGap = props => {\n if (props.rowGap !== undefined && props.rowGap !== null) {\n const transformer = createUnaryUnit(props.theme, 'spacing', 8, 'rowGap');\n const styleFromPropValue = propValue => ({\n rowGap: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.rowGap, styleFromPropValue);\n }\n return null;\n};\nrowGap.propTypes = process.env.NODE_ENV !== 'production' ? {\n rowGap: responsivePropType\n} : {};\nrowGap.filterProps = ['rowGap'];\nexport const gridColumn = style({\n prop: 'gridColumn'\n});\nexport const gridRow = style({\n prop: 'gridRow'\n});\nexport const gridAutoFlow = style({\n prop: 'gridAutoFlow'\n});\nexport const gridAutoColumns = style({\n prop: 'gridAutoColumns'\n});\nexport const gridAutoRows = style({\n prop: 'gridAutoRows'\n});\nexport const gridTemplateColumns = style({\n prop: 'gridTemplateColumns'\n});\nexport const gridTemplateRows = style({\n prop: 'gridTemplateRows'\n});\nexport const gridTemplateAreas = style({\n prop: 'gridTemplateAreas'\n});\nexport const gridArea = style({\n prop: 'gridArea'\n});\nconst grid = compose(gap, columnGap, rowGap, gridColumn, gridRow, gridAutoFlow, gridAutoColumns, gridAutoRows, gridTemplateColumns, gridTemplateRows, gridTemplateAreas, gridArea);\nexport default grid;","import style from './style';\nimport compose from './compose';\nexport function paletteTransform(value, userValue) {\n if (userValue === 'grey') {\n return userValue;\n }\n return value;\n}\nexport const color = style({\n prop: 'color',\n themeKey: 'palette',\n transform: paletteTransform\n});\nexport const bgcolor = style({\n prop: 'bgcolor',\n cssProperty: 'backgroundColor',\n themeKey: 'palette',\n transform: paletteTransform\n});\nexport const backgroundColor = style({\n prop: 'backgroundColor',\n themeKey: 'palette',\n transform: paletteTransform\n});\nconst palette = compose(color, bgcolor, backgroundColor);\nexport default palette;","import style from './style';\nimport compose from './compose';\nimport { handleBreakpoints, values as breakpointsValues } from './breakpoints';\nexport function sizingTransform(value) {\n return value <= 1 && value !== 0 ? `${value * 100}%` : value;\n}\nexport const width = style({\n prop: 'width',\n transform: sizingTransform\n});\nexport const maxWidth = props => {\n if (props.maxWidth !== undefined && props.maxWidth !== null) {\n const styleFromPropValue = propValue => {\n var _props$theme, _props$theme2;\n const breakpoint = ((_props$theme = props.theme) == null || (_props$theme = _props$theme.breakpoints) == null || (_props$theme = _props$theme.values) == null ? void 0 : _props$theme[propValue]) || breakpointsValues[propValue];\n if (!breakpoint) {\n return {\n maxWidth: sizingTransform(propValue)\n };\n }\n if (((_props$theme2 = props.theme) == null || (_props$theme2 = _props$theme2.breakpoints) == null ? void 0 : _props$theme2.unit) !== 'px') {\n return {\n maxWidth: `${breakpoint}${props.theme.breakpoints.unit}`\n };\n }\n return {\n maxWidth: breakpoint\n };\n };\n return handleBreakpoints(props, props.maxWidth, styleFromPropValue);\n }\n return null;\n};\nmaxWidth.filterProps = ['maxWidth'];\nexport const minWidth = style({\n prop: 'minWidth',\n transform: sizingTransform\n});\nexport const height = style({\n prop: 'height',\n transform: sizingTransform\n});\nexport const maxHeight = style({\n prop: 'maxHeight',\n transform: sizingTransform\n});\nexport const minHeight = style({\n prop: 'minHeight',\n transform: sizingTransform\n});\nexport const sizeWidth = style({\n prop: 'size',\n cssProperty: 'width',\n transform: sizingTransform\n});\nexport const sizeHeight = style({\n prop: 'size',\n cssProperty: 'height',\n transform: sizingTransform\n});\nexport const boxSizing = style({\n prop: 'boxSizing'\n});\nconst sizing = compose(width, maxWidth, minWidth, height, maxHeight, minHeight, boxSizing);\nexport default sizing;","import { padding, margin } from '../spacing';\nimport { borderRadius, borderTransform } from '../borders';\nimport { gap, rowGap, columnGap } from '../cssGrid';\nimport { paletteTransform } from '../palette';\nimport { maxWidth, sizingTransform } from '../sizing';\nconst defaultSxConfig = {\n // borders\n border: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderTop: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderRight: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderBottom: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderLeft: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderColor: {\n themeKey: 'palette'\n },\n borderTopColor: {\n themeKey: 'palette'\n },\n borderRightColor: {\n themeKey: 'palette'\n },\n borderBottomColor: {\n themeKey: 'palette'\n },\n borderLeftColor: {\n themeKey: 'palette'\n },\n outline: {\n themeKey: 'borders',\n transform: borderTransform\n },\n outlineColor: {\n themeKey: 'palette'\n },\n borderRadius: {\n themeKey: 'shape.borderRadius',\n style: borderRadius\n },\n // palette\n color: {\n themeKey: 'palette',\n transform: paletteTransform\n },\n bgcolor: {\n themeKey: 'palette',\n cssProperty: 'backgroundColor',\n transform: paletteTransform\n },\n backgroundColor: {\n themeKey: 'palette',\n transform: paletteTransform\n },\n // spacing\n p: {\n style: padding\n },\n pt: {\n style: padding\n },\n pr: {\n style: padding\n },\n pb: {\n style: padding\n },\n pl: {\n style: padding\n },\n px: {\n style: padding\n },\n py: {\n style: padding\n },\n padding: {\n style: padding\n },\n paddingTop: {\n style: padding\n },\n paddingRight: {\n style: padding\n },\n paddingBottom: {\n style: padding\n },\n paddingLeft: {\n style: padding\n },\n paddingX: {\n style: padding\n },\n paddingY: {\n style: padding\n },\n paddingInline: {\n style: padding\n },\n paddingInlineStart: {\n style: padding\n },\n paddingInlineEnd: {\n style: padding\n },\n paddingBlock: {\n style: padding\n },\n paddingBlockStart: {\n style: padding\n },\n paddingBlockEnd: {\n style: padding\n },\n m: {\n style: margin\n },\n mt: {\n style: margin\n },\n mr: {\n style: margin\n },\n mb: {\n style: margin\n },\n ml: {\n style: margin\n },\n mx: {\n style: margin\n },\n my: {\n style: margin\n },\n margin: {\n style: margin\n },\n marginTop: {\n style: margin\n },\n marginRight: {\n style: margin\n },\n marginBottom: {\n style: margin\n },\n marginLeft: {\n style: margin\n },\n marginX: {\n style: margin\n },\n marginY: {\n style: margin\n },\n marginInline: {\n style: margin\n },\n marginInlineStart: {\n style: margin\n },\n marginInlineEnd: {\n style: margin\n },\n marginBlock: {\n style: margin\n },\n marginBlockStart: {\n style: margin\n },\n marginBlockEnd: {\n style: margin\n },\n // display\n displayPrint: {\n cssProperty: false,\n transform: value => ({\n '@media print': {\n display: value\n }\n })\n },\n display: {},\n overflow: {},\n textOverflow: {},\n visibility: {},\n whiteSpace: {},\n // flexbox\n flexBasis: {},\n flexDirection: {},\n flexWrap: {},\n justifyContent: {},\n alignItems: {},\n alignContent: {},\n order: {},\n flex: {},\n flexGrow: {},\n flexShrink: {},\n alignSelf: {},\n justifyItems: {},\n justifySelf: {},\n // grid\n gap: {\n style: gap\n },\n rowGap: {\n style: rowGap\n },\n columnGap: {\n style: columnGap\n },\n gridColumn: {},\n gridRow: {},\n gridAutoFlow: {},\n gridAutoColumns: {},\n gridAutoRows: {},\n gridTemplateColumns: {},\n gridTemplateRows: {},\n gridTemplateAreas: {},\n gridArea: {},\n // positions\n position: {},\n zIndex: {\n themeKey: 'zIndex'\n },\n top: {},\n right: {},\n bottom: {},\n left: {},\n // shadows\n boxShadow: {\n themeKey: 'shadows'\n },\n // sizing\n width: {\n transform: sizingTransform\n },\n maxWidth: {\n style: maxWidth\n },\n minWidth: {\n transform: sizingTransform\n },\n height: {\n transform: sizingTransform\n },\n maxHeight: {\n transform: sizingTransform\n },\n minHeight: {\n transform: sizingTransform\n },\n boxSizing: {},\n // typography\n fontFamily: {\n themeKey: 'typography'\n },\n fontSize: {\n themeKey: 'typography'\n },\n fontStyle: {\n themeKey: 'typography'\n },\n fontWeight: {\n themeKey: 'typography'\n },\n letterSpacing: {},\n textTransform: {},\n lineHeight: {},\n textAlign: {},\n typography: {\n cssProperty: false,\n themeKey: 'typography'\n }\n};\nexport default defaultSxConfig;","import capitalize from '@mui/utils/capitalize';\nimport merge from '../merge';\nimport { getPath, getStyleValue as getValue } from '../style';\nimport { handleBreakpoints, createEmptyBreakpointObject, removeUnusedBreakpoints } from '../breakpoints';\nimport defaultSxConfig from './defaultSxConfig';\nfunction objectsHaveSameKeys(...objects) {\n const allKeys = objects.reduce((keys, object) => keys.concat(Object.keys(object)), []);\n const union = new Set(allKeys);\n return objects.every(object => union.size === Object.keys(object).length);\n}\nfunction callIfFn(maybeFn, arg) {\n return typeof maybeFn === 'function' ? maybeFn(arg) : maybeFn;\n}\n\n// eslint-disable-next-line @typescript-eslint/naming-convention\nexport function unstable_createStyleFunctionSx() {\n function getThemeValue(prop, val, theme, config) {\n const props = {\n [prop]: val,\n theme\n };\n const options = config[prop];\n if (!options) {\n return {\n [prop]: val\n };\n }\n const {\n cssProperty = prop,\n themeKey,\n transform,\n style\n } = options;\n if (val == null) {\n return null;\n }\n\n // TODO v6: remove, see https://github.com/mui/material-ui/pull/38123\n if (themeKey === 'typography' && val === 'inherit') {\n return {\n [prop]: val\n };\n }\n const themeMapping = getPath(theme, themeKey) || {};\n if (style) {\n return style(props);\n }\n const styleFromPropValue = propValueFinal => {\n let value = getValue(themeMapping, transform, propValueFinal);\n if (propValueFinal === value && typeof propValueFinal === 'string') {\n // Haven't found value\n value = getValue(themeMapping, transform, `${prop}${propValueFinal === 'default' ? '' : capitalize(propValueFinal)}`, propValueFinal);\n }\n if (cssProperty === false) {\n return value;\n }\n return {\n [cssProperty]: value\n };\n };\n return handleBreakpoints(props, val, styleFromPropValue);\n }\n function styleFunctionSx(props) {\n var _theme$unstable_sxCon;\n const {\n sx,\n theme = {}\n } = props || {};\n if (!sx) {\n return null; // Emotion & styled-components will neglect null\n }\n const config = (_theme$unstable_sxCon = theme.unstable_sxConfig) != null ? _theme$unstable_sxCon : defaultSxConfig;\n\n /*\n * Receive `sxInput` as object or callback\n * and then recursively check keys & values to create media query object styles.\n * (the result will be used in `styled`)\n */\n function traverse(sxInput) {\n let sxObject = sxInput;\n if (typeof sxInput === 'function') {\n sxObject = sxInput(theme);\n } else if (typeof sxInput !== 'object') {\n // value\n return sxInput;\n }\n if (!sxObject) {\n return null;\n }\n const emptyBreakpoints = createEmptyBreakpointObject(theme.breakpoints);\n const breakpointsKeys = Object.keys(emptyBreakpoints);\n let css = emptyBreakpoints;\n Object.keys(sxObject).forEach(styleKey => {\n const value = callIfFn(sxObject[styleKey], theme);\n if (value !== null && value !== undefined) {\n if (typeof value === 'object') {\n if (config[styleKey]) {\n css = merge(css, getThemeValue(styleKey, value, theme, config));\n } else {\n const breakpointsValues = handleBreakpoints({\n theme\n }, value, x => ({\n [styleKey]: x\n }));\n if (objectsHaveSameKeys(breakpointsValues, value)) {\n css[styleKey] = styleFunctionSx({\n sx: value,\n theme\n });\n } else {\n css = merge(css, breakpointsValues);\n }\n }\n } else {\n css = merge(css, getThemeValue(styleKey, value, theme, config));\n }\n }\n });\n return removeUnusedBreakpoints(breakpointsKeys, css);\n }\n return Array.isArray(sx) ? sx.map(traverse) : traverse(sx);\n }\n return styleFunctionSx;\n}\nconst styleFunctionSx = unstable_createStyleFunctionSx();\nstyleFunctionSx.filterProps = ['sx'];\nexport default styleFunctionSx;","/**\n * A universal utility to style components with multiple color modes. Always use it from the theme object.\n * It works with:\n * - [Basic theme](https://mui.com/material-ui/customization/dark-mode/)\n * - [CSS theme variables](https://mui.com/material-ui/experimental-api/css-theme-variables/overview/)\n * - Zero-runtime engine\n *\n * Tips: Use an array over object spread and place `theme.applyStyles()` last.\n *\n * ✅ [{ background: '#e5e5e5' }, theme.applyStyles('dark', { background: '#1c1c1c' })]\n *\n * 🚫 { background: '#e5e5e5', ...theme.applyStyles('dark', { background: '#1c1c1c' })}\n *\n * @example\n * 1. using with `styled`:\n * ```jsx\n * const Component = styled('div')(({ theme }) => [\n * { background: '#e5e5e5' },\n * theme.applyStyles('dark', {\n * background: '#1c1c1c',\n * color: '#fff',\n * }),\n * ]);\n * ```\n *\n * @example\n * 2. using with `sx` prop:\n * ```jsx\n * [\n * { background: '#e5e5e5' },\n * theme.applyStyles('dark', {\n * background: '#1c1c1c',\n * color: '#fff',\n * }),\n * ]}\n * />\n * ```\n *\n * @example\n * 3. theming a component:\n * ```jsx\n * extendTheme({\n * components: {\n * MuiButton: {\n * styleOverrides: {\n * root: ({ theme }) => [\n * { background: '#e5e5e5' },\n * theme.applyStyles('dark', {\n * background: '#1c1c1c',\n * color: '#fff',\n * }),\n * ],\n * },\n * }\n * }\n * })\n *```\n */\nexport default function applyStyles(key, styles) {\n // @ts-expect-error this is 'any' type\n const theme = this;\n if (theme.vars && typeof theme.getColorSchemeSelector === 'function') {\n // If CssVarsProvider is used as a provider,\n // returns '* :where([data-mui-color-scheme=\"light|dark\"]) &'\n const selector = theme.getColorSchemeSelector(key).replace(/(\\[[^\\]]+\\])/, '*:where($1)');\n return {\n [selector]: styles\n };\n }\n if (theme.palette.mode === key) {\n return styles;\n }\n return {};\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"breakpoints\", \"palette\", \"spacing\", \"shape\"];\nimport deepmerge from '@mui/utils/deepmerge';\nimport createBreakpoints from './createBreakpoints';\nimport shape from './shape';\nimport createSpacing from './createSpacing';\nimport styleFunctionSx from '../styleFunctionSx/styleFunctionSx';\nimport defaultSxConfig from '../styleFunctionSx/defaultSxConfig';\nimport applyStyles from './applyStyles';\nfunction createTheme(options = {}, ...args) {\n const {\n breakpoints: breakpointsInput = {},\n palette: paletteInput = {},\n spacing: spacingInput,\n shape: shapeInput = {}\n } = options,\n other = _objectWithoutPropertiesLoose(options, _excluded);\n const breakpoints = createBreakpoints(breakpointsInput);\n const spacing = createSpacing(spacingInput);\n let muiTheme = deepmerge({\n breakpoints,\n direction: 'ltr',\n components: {},\n // Inject component definitions.\n palette: _extends({\n mode: 'light'\n }, paletteInput),\n spacing,\n shape: _extends({}, shape, shapeInput)\n }, other);\n muiTheme.applyStyles = applyStyles;\n muiTheme = args.reduce((acc, argument) => deepmerge(acc, argument), muiTheme);\n muiTheme.unstable_sxConfig = _extends({}, defaultSxConfig, other == null ? void 0 : other.unstable_sxConfig);\n muiTheme.unstable_sx = function sx(props) {\n return styleFunctionSx({\n sx: props,\n theme: this\n });\n };\n return muiTheme;\n}\nexport default createTheme;","'use client';\n\nimport * as React from 'react';\nimport { ThemeContext } from '@mui/styled-engine';\nfunction isObjectEmpty(obj) {\n return Object.keys(obj).length === 0;\n}\nfunction useTheme(defaultTheme = null) {\n const contextTheme = React.useContext(ThemeContext);\n return !contextTheme || isObjectEmpty(contextTheme) ? defaultTheme : contextTheme;\n}\nexport default useTheme;","'use client';\n\nimport createTheme from './createTheme';\nimport useThemeWithoutDefault from './useThemeWithoutDefault';\nexport const systemDefaultTheme = createTheme();\nfunction useTheme(defaultTheme = systemDefaultTheme) {\n return useThemeWithoutDefault(defaultTheme);\n}\nexport default useTheme;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"ownerState\"],\n _excluded2 = [\"variants\"],\n _excluded3 = [\"name\", \"slot\", \"skipVariantsResolver\", \"skipSx\", \"overridesResolver\"];\n/* eslint-disable no-underscore-dangle */\nimport styledEngineStyled, { internal_processStyles as processStyles } from '@mui/styled-engine';\nimport { isPlainObject } from '@mui/utils/deepmerge';\nimport capitalize from '@mui/utils/capitalize';\nimport getDisplayName from '@mui/utils/getDisplayName';\nimport createTheme from './createTheme';\nimport styleFunctionSx from './styleFunctionSx';\nfunction isEmpty(obj) {\n return Object.keys(obj).length === 0;\n}\n\n// https://github.com/emotion-js/emotion/blob/26ded6109fcd8ca9875cc2ce4564fee678a3f3c5/packages/styled/src/utils.js#L40\nfunction isStringTag(tag) {\n return typeof tag === 'string' &&\n // 96 is one less than the char code\n // for \"a\" so this is checking that\n // it's a lowercase character\n tag.charCodeAt(0) > 96;\n}\n\n// Update /system/styled/#api in case if this changes\nexport function shouldForwardProp(prop) {\n return prop !== 'ownerState' && prop !== 'theme' && prop !== 'sx' && prop !== 'as';\n}\nexport const systemDefaultTheme = createTheme();\nconst lowercaseFirstLetter = string => {\n if (!string) {\n return string;\n }\n return string.charAt(0).toLowerCase() + string.slice(1);\n};\nfunction resolveTheme({\n defaultTheme,\n theme,\n themeId\n}) {\n return isEmpty(theme) ? defaultTheme : theme[themeId] || theme;\n}\nfunction defaultOverridesResolver(slot) {\n if (!slot) {\n return null;\n }\n return (props, styles) => styles[slot];\n}\nfunction processStyleArg(callableStyle, _ref) {\n let {\n ownerState\n } = _ref,\n props = _objectWithoutPropertiesLoose(_ref, _excluded);\n const resolvedStylesArg = typeof callableStyle === 'function' ? callableStyle(_extends({\n ownerState\n }, props)) : callableStyle;\n if (Array.isArray(resolvedStylesArg)) {\n return resolvedStylesArg.flatMap(resolvedStyle => processStyleArg(resolvedStyle, _extends({\n ownerState\n }, props)));\n }\n if (!!resolvedStylesArg && typeof resolvedStylesArg === 'object' && Array.isArray(resolvedStylesArg.variants)) {\n const {\n variants = []\n } = resolvedStylesArg,\n otherStyles = _objectWithoutPropertiesLoose(resolvedStylesArg, _excluded2);\n let result = otherStyles;\n variants.forEach(variant => {\n let isMatch = true;\n if (typeof variant.props === 'function') {\n isMatch = variant.props(_extends({\n ownerState\n }, props, ownerState));\n } else {\n Object.keys(variant.props).forEach(key => {\n if ((ownerState == null ? void 0 : ownerState[key]) !== variant.props[key] && props[key] !== variant.props[key]) {\n isMatch = false;\n }\n });\n }\n if (isMatch) {\n if (!Array.isArray(result)) {\n result = [result];\n }\n result.push(typeof variant.style === 'function' ? variant.style(_extends({\n ownerState\n }, props, ownerState)) : variant.style);\n }\n });\n return result;\n }\n return resolvedStylesArg;\n}\nexport default function createStyled(input = {}) {\n const {\n themeId,\n defaultTheme = systemDefaultTheme,\n rootShouldForwardProp = shouldForwardProp,\n slotShouldForwardProp = shouldForwardProp\n } = input;\n const systemSx = props => {\n return styleFunctionSx(_extends({}, props, {\n theme: resolveTheme(_extends({}, props, {\n defaultTheme,\n themeId\n }))\n }));\n };\n systemSx.__mui_systemSx = true;\n return (tag, inputOptions = {}) => {\n // Filter out the `sx` style function from the previous styled component to prevent unnecessary styles generated by the composite components.\n processStyles(tag, styles => styles.filter(style => !(style != null && style.__mui_systemSx)));\n const {\n name: componentName,\n slot: componentSlot,\n skipVariantsResolver: inputSkipVariantsResolver,\n skipSx: inputSkipSx,\n // TODO v6: remove `lowercaseFirstLetter()` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n overridesResolver = defaultOverridesResolver(lowercaseFirstLetter(componentSlot))\n } = inputOptions,\n options = _objectWithoutPropertiesLoose(inputOptions, _excluded3);\n\n // if skipVariantsResolver option is defined, take the value, otherwise, true for root and false for other slots.\n const skipVariantsResolver = inputSkipVariantsResolver !== undefined ? inputSkipVariantsResolver :\n // TODO v6: remove `Root` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n componentSlot && componentSlot !== 'Root' && componentSlot !== 'root' || false;\n const skipSx = inputSkipSx || false;\n let label;\n if (process.env.NODE_ENV !== 'production') {\n if (componentName) {\n // TODO v6: remove `lowercaseFirstLetter()` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n label = `${componentName}-${lowercaseFirstLetter(componentSlot || 'Root')}`;\n }\n }\n let shouldForwardPropOption = shouldForwardProp;\n\n // TODO v6: remove `Root` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n if (componentSlot === 'Root' || componentSlot === 'root') {\n shouldForwardPropOption = rootShouldForwardProp;\n } else if (componentSlot) {\n // any other slot specified\n shouldForwardPropOption = slotShouldForwardProp;\n } else if (isStringTag(tag)) {\n // for string (html) tag, preserve the behavior in emotion & styled-components.\n shouldForwardPropOption = undefined;\n }\n const defaultStyledResolver = styledEngineStyled(tag, _extends({\n shouldForwardProp: shouldForwardPropOption,\n label\n }, options));\n const transformStyleArg = stylesArg => {\n // On the server Emotion doesn't use React.forwardRef for creating components, so the created\n // component stays as a function. This condition makes sure that we do not interpolate functions\n // which are basically components used as a selectors.\n if (typeof stylesArg === 'function' && stylesArg.__emotion_real !== stylesArg || isPlainObject(stylesArg)) {\n return props => processStyleArg(stylesArg, _extends({}, props, {\n theme: resolveTheme({\n theme: props.theme,\n defaultTheme,\n themeId\n })\n }));\n }\n return stylesArg;\n };\n const muiStyledResolver = (styleArg, ...expressions) => {\n let transformedStyleArg = transformStyleArg(styleArg);\n const expressionsWithDefaultTheme = expressions ? expressions.map(transformStyleArg) : [];\n if (componentName && overridesResolver) {\n expressionsWithDefaultTheme.push(props => {\n const theme = resolveTheme(_extends({}, props, {\n defaultTheme,\n themeId\n }));\n if (!theme.components || !theme.components[componentName] || !theme.components[componentName].styleOverrides) {\n return null;\n }\n const styleOverrides = theme.components[componentName].styleOverrides;\n const resolvedStyleOverrides = {};\n // TODO: v7 remove iteration and use `resolveStyleArg(styleOverrides[slot])` directly\n Object.entries(styleOverrides).forEach(([slotKey, slotStyle]) => {\n resolvedStyleOverrides[slotKey] = processStyleArg(slotStyle, _extends({}, props, {\n theme\n }));\n });\n return overridesResolver(props, resolvedStyleOverrides);\n });\n }\n if (componentName && !skipVariantsResolver) {\n expressionsWithDefaultTheme.push(props => {\n var _theme$components;\n const theme = resolveTheme(_extends({}, props, {\n defaultTheme,\n themeId\n }));\n const themeVariants = theme == null || (_theme$components = theme.components) == null || (_theme$components = _theme$components[componentName]) == null ? void 0 : _theme$components.variants;\n return processStyleArg({\n variants: themeVariants\n }, _extends({}, props, {\n theme\n }));\n });\n }\n if (!skipSx) {\n expressionsWithDefaultTheme.push(systemSx);\n }\n const numOfCustomFnsApplied = expressionsWithDefaultTheme.length - expressions.length;\n if (Array.isArray(styleArg) && numOfCustomFnsApplied > 0) {\n const placeholders = new Array(numOfCustomFnsApplied).fill('');\n // If the type is array, than we need to add placeholders in the template for the overrides, variants and the sx styles.\n transformedStyleArg = [...styleArg, ...placeholders];\n transformedStyleArg.raw = [...styleArg.raw, ...placeholders];\n }\n const Component = defaultStyledResolver(transformedStyleArg, ...expressionsWithDefaultTheme);\n if (process.env.NODE_ENV !== 'production') {\n let displayName;\n if (componentName) {\n displayName = `${componentName}${capitalize(componentSlot || '')}`;\n }\n if (displayName === undefined) {\n displayName = `Styled(${getDisplayName(tag)})`;\n }\n Component.displayName = displayName;\n }\n if (tag.muiName) {\n Component.muiName = tag.muiName;\n }\n return Component;\n };\n if (defaultStyledResolver.withConfig) {\n muiStyledResolver.withConfig = defaultStyledResolver.withConfig;\n }\n return muiStyledResolver;\n };\n}","import resolveProps from '@mui/utils/resolveProps';\nexport default function getThemeProps(params) {\n const {\n theme,\n name,\n props\n } = params;\n if (!theme || !theme.components || !theme.components[name] || !theme.components[name].defaultProps) {\n return props;\n }\n return resolveProps(theme.components[name].defaultProps, props);\n}","'use client';\n\nimport getThemeProps from './getThemeProps';\nimport useTheme from '../useTheme';\nexport default function useThemeProps({\n props,\n name,\n defaultTheme,\n themeId\n}) {\n let theme = useTheme(defaultTheme);\n if (themeId) {\n theme = theme[themeId] || theme;\n }\n const mergedProps = getThemeProps({\n theme,\n name,\n props\n });\n return mergedProps;\n}","import _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\n/* eslint-disable @typescript-eslint/naming-convention */\nimport clamp from '@mui/utils/clamp';\n/**\n * Returns a number whose value is limited to the given range.\n * @param {number} value The value to be clamped\n * @param {number} min The lower boundary of the output range\n * @param {number} max The upper boundary of the output range\n * @returns {number} A number in the range [min, max]\n */\nfunction clampWrapper(value, min = 0, max = 1) {\n if (process.env.NODE_ENV !== 'production') {\n if (value < min || value > max) {\n console.error(`MUI: The value provided ${value} is out of range [${min}, ${max}].`);\n }\n }\n return clamp(value, min, max);\n}\n\n/**\n * Converts a color from CSS hex format to CSS rgb format.\n * @param {string} color - Hex color, i.e. #nnn or #nnnnnn\n * @returns {string} A CSS rgb color string\n */\nexport function hexToRgb(color) {\n color = color.slice(1);\n const re = new RegExp(`.{1,${color.length >= 6 ? 2 : 1}}`, 'g');\n let colors = color.match(re);\n if (colors && colors[0].length === 1) {\n colors = colors.map(n => n + n);\n }\n return colors ? `rgb${colors.length === 4 ? 'a' : ''}(${colors.map((n, index) => {\n return index < 3 ? parseInt(n, 16) : Math.round(parseInt(n, 16) / 255 * 1000) / 1000;\n }).join(', ')})` : '';\n}\nfunction intToHex(int) {\n const hex = int.toString(16);\n return hex.length === 1 ? `0${hex}` : hex;\n}\n\n/**\n * Returns an object with the type and values of a color.\n *\n * Note: Does not support rgb % values.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @returns {object} - A MUI color object: {type: string, values: number[]}\n */\nexport function decomposeColor(color) {\n // Idempotent\n if (color.type) {\n return color;\n }\n if (color.charAt(0) === '#') {\n return decomposeColor(hexToRgb(color));\n }\n const marker = color.indexOf('(');\n const type = color.substring(0, marker);\n if (['rgb', 'rgba', 'hsl', 'hsla', 'color'].indexOf(type) === -1) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: Unsupported \\`${color}\\` color.\nThe following formats are supported: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color().` : _formatMuiErrorMessage(9, color));\n }\n let values = color.substring(marker + 1, color.length - 1);\n let colorSpace;\n if (type === 'color') {\n values = values.split(' ');\n colorSpace = values.shift();\n if (values.length === 4 && values[3].charAt(0) === '/') {\n values[3] = values[3].slice(1);\n }\n if (['srgb', 'display-p3', 'a98-rgb', 'prophoto-rgb', 'rec-2020'].indexOf(colorSpace) === -1) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: unsupported \\`${colorSpace}\\` color space.\nThe following color spaces are supported: srgb, display-p3, a98-rgb, prophoto-rgb, rec-2020.` : _formatMuiErrorMessage(10, colorSpace));\n }\n } else {\n values = values.split(',');\n }\n values = values.map(value => parseFloat(value));\n return {\n type,\n values,\n colorSpace\n };\n}\n\n/**\n * Returns a channel created from the input color.\n *\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @returns {string} - The channel for the color, that can be used in rgba or hsla colors\n */\nexport const colorChannel = color => {\n const decomposedColor = decomposeColor(color);\n return decomposedColor.values.slice(0, 3).map((val, idx) => decomposedColor.type.indexOf('hsl') !== -1 && idx !== 0 ? `${val}%` : val).join(' ');\n};\nexport const private_safeColorChannel = (color, warning) => {\n try {\n return colorChannel(color);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n};\n\n/**\n * Converts a color object with type and values to a string.\n * @param {object} color - Decomposed color\n * @param {string} color.type - One of: 'rgb', 'rgba', 'hsl', 'hsla', 'color'\n * @param {array} color.values - [n,n,n] or [n,n,n,n]\n * @returns {string} A CSS color string\n */\nexport function recomposeColor(color) {\n const {\n type,\n colorSpace\n } = color;\n let {\n values\n } = color;\n if (type.indexOf('rgb') !== -1) {\n // Only convert the first 3 values to int (i.e. not alpha)\n values = values.map((n, i) => i < 3 ? parseInt(n, 10) : n);\n } else if (type.indexOf('hsl') !== -1) {\n values[1] = `${values[1]}%`;\n values[2] = `${values[2]}%`;\n }\n if (type.indexOf('color') !== -1) {\n values = `${colorSpace} ${values.join(' ')}`;\n } else {\n values = `${values.join(', ')}`;\n }\n return `${type}(${values})`;\n}\n\n/**\n * Converts a color from CSS rgb format to CSS hex format.\n * @param {string} color - RGB color, i.e. rgb(n, n, n)\n * @returns {string} A CSS rgb color string, i.e. #nnnnnn\n */\nexport function rgbToHex(color) {\n // Idempotent\n if (color.indexOf('#') === 0) {\n return color;\n }\n const {\n values\n } = decomposeColor(color);\n return `#${values.map((n, i) => intToHex(i === 3 ? Math.round(255 * n) : n)).join('')}`;\n}\n\n/**\n * Converts a color from hsl format to rgb format.\n * @param {string} color - HSL color values\n * @returns {string} rgb color values\n */\nexport function hslToRgb(color) {\n color = decomposeColor(color);\n const {\n values\n } = color;\n const h = values[0];\n const s = values[1] / 100;\n const l = values[2] / 100;\n const a = s * Math.min(l, 1 - l);\n const f = (n, k = (n + h / 30) % 12) => l - a * Math.max(Math.min(k - 3, 9 - k, 1), -1);\n let type = 'rgb';\n const rgb = [Math.round(f(0) * 255), Math.round(f(8) * 255), Math.round(f(4) * 255)];\n if (color.type === 'hsla') {\n type += 'a';\n rgb.push(values[3]);\n }\n return recomposeColor({\n type,\n values: rgb\n });\n}\n/**\n * The relative brightness of any point in a color space,\n * normalized to 0 for darkest black and 1 for lightest white.\n *\n * Formula: https://www.w3.org/TR/WCAG20-TECHS/G17.html#G17-tests\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @returns {number} The relative brightness of the color in the range 0 - 1\n */\nexport function getLuminance(color) {\n color = decomposeColor(color);\n let rgb = color.type === 'hsl' || color.type === 'hsla' ? decomposeColor(hslToRgb(color)).values : color.values;\n rgb = rgb.map(val => {\n if (color.type !== 'color') {\n val /= 255; // normalized\n }\n return val <= 0.03928 ? val / 12.92 : ((val + 0.055) / 1.055) ** 2.4;\n });\n\n // Truncate at 3 digits\n return Number((0.2126 * rgb[0] + 0.7152 * rgb[1] + 0.0722 * rgb[2]).toFixed(3));\n}\n\n/**\n * Calculates the contrast ratio between two colors.\n *\n * Formula: https://www.w3.org/TR/WCAG20-TECHS/G17.html#G17-tests\n * @param {string} foreground - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla()\n * @param {string} background - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla()\n * @returns {number} A contrast ratio value in the range 0 - 21.\n */\nexport function getContrastRatio(foreground, background) {\n const lumA = getLuminance(foreground);\n const lumB = getLuminance(background);\n return (Math.max(lumA, lumB) + 0.05) / (Math.min(lumA, lumB) + 0.05);\n}\n\n/**\n * Sets the absolute transparency of a color.\n * Any existing alpha values are overwritten.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} value - value to set the alpha channel to in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function alpha(color, value) {\n color = decomposeColor(color);\n value = clampWrapper(value);\n if (color.type === 'rgb' || color.type === 'hsl') {\n color.type += 'a';\n }\n if (color.type === 'color') {\n color.values[3] = `/${value}`;\n } else {\n color.values[3] = value;\n }\n return recomposeColor(color);\n}\nexport function private_safeAlpha(color, value, warning) {\n try {\n return alpha(color, value);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Darkens a color.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} coefficient - multiplier in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function darken(color, coefficient) {\n color = decomposeColor(color);\n coefficient = clampWrapper(coefficient);\n if (color.type.indexOf('hsl') !== -1) {\n color.values[2] *= 1 - coefficient;\n } else if (color.type.indexOf('rgb') !== -1 || color.type.indexOf('color') !== -1) {\n for (let i = 0; i < 3; i += 1) {\n color.values[i] *= 1 - coefficient;\n }\n }\n return recomposeColor(color);\n}\nexport function private_safeDarken(color, coefficient, warning) {\n try {\n return darken(color, coefficient);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Lightens a color.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} coefficient - multiplier in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function lighten(color, coefficient) {\n color = decomposeColor(color);\n coefficient = clampWrapper(coefficient);\n if (color.type.indexOf('hsl') !== -1) {\n color.values[2] += (100 - color.values[2]) * coefficient;\n } else if (color.type.indexOf('rgb') !== -1) {\n for (let i = 0; i < 3; i += 1) {\n color.values[i] += (255 - color.values[i]) * coefficient;\n }\n } else if (color.type.indexOf('color') !== -1) {\n for (let i = 0; i < 3; i += 1) {\n color.values[i] += (1 - color.values[i]) * coefficient;\n }\n }\n return recomposeColor(color);\n}\nexport function private_safeLighten(color, coefficient, warning) {\n try {\n return lighten(color, coefficient);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Darken or lighten a color, depending on its luminance.\n * Light colors are darkened, dark colors are lightened.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} coefficient=0.15 - multiplier in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function emphasize(color, coefficient = 0.15) {\n return getLuminance(color) > 0.5 ? darken(color, coefficient) : lighten(color, coefficient);\n}\nexport function private_safeEmphasize(color, coefficient, warning) {\n try {\n return emphasize(color, coefficient);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Blend a transparent overlay color with a background color, resulting in a single\n * RGB color.\n * @param {string} background - CSS color\n * @param {string} overlay - CSS color\n * @param {number} opacity - Opacity multiplier in the range 0 - 1\n * @param {number} [gamma=1.0] - Gamma correction factor. For gamma-correct blending, 2.2 is usual.\n */\nexport function blend(background, overlay, opacity, gamma = 1.0) {\n const blendChannel = (b, o) => Math.round((b ** (1 / gamma) * (1 - opacity) + o ** (1 / gamma) * opacity) ** gamma);\n const backgroundColor = decomposeColor(background);\n const overlayColor = decomposeColor(overlay);\n const rgb = [blendChannel(backgroundColor.values[0], overlayColor.values[0]), blendChannel(backgroundColor.values[1], overlayColor.values[1]), blendChannel(backgroundColor.values[2], overlayColor.values[2])];\n return recomposeColor({\n type: 'rgb',\n values: rgb\n });\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nexport default function createMixins(breakpoints, mixins) {\n return _extends({\n toolbar: {\n minHeight: 56,\n [breakpoints.up('xs')]: {\n '@media (orientation: landscape)': {\n minHeight: 48\n }\n },\n [breakpoints.up('sm')]: {\n minHeight: 64\n }\n }\n }, mixins);\n}","const common = {\n black: '#000',\n white: '#fff'\n};\nexport default common;","const grey = {\n 50: '#fafafa',\n 100: '#f5f5f5',\n 200: '#eeeeee',\n 300: '#e0e0e0',\n 400: '#bdbdbd',\n 500: '#9e9e9e',\n 600: '#757575',\n 700: '#616161',\n 800: '#424242',\n 900: '#212121',\n A100: '#f5f5f5',\n A200: '#eeeeee',\n A400: '#bdbdbd',\n A700: '#616161'\n};\nexport default grey;","const purple = {\n 50: '#f3e5f5',\n 100: '#e1bee7',\n 200: '#ce93d8',\n 300: '#ba68c8',\n 400: '#ab47bc',\n 500: '#9c27b0',\n 600: '#8e24aa',\n 700: '#7b1fa2',\n 800: '#6a1b9a',\n 900: '#4a148c',\n A100: '#ea80fc',\n A200: '#e040fb',\n A400: '#d500f9',\n A700: '#aa00ff'\n};\nexport default purple;","const red = {\n 50: '#ffebee',\n 100: '#ffcdd2',\n 200: '#ef9a9a',\n 300: '#e57373',\n 400: '#ef5350',\n 500: '#f44336',\n 600: '#e53935',\n 700: '#d32f2f',\n 800: '#c62828',\n 900: '#b71c1c',\n A100: '#ff8a80',\n A200: '#ff5252',\n A400: '#ff1744',\n A700: '#d50000'\n};\nexport default red;","const orange = {\n 50: '#fff3e0',\n 100: '#ffe0b2',\n 200: '#ffcc80',\n 300: '#ffb74d',\n 400: '#ffa726',\n 500: '#ff9800',\n 600: '#fb8c00',\n 700: '#f57c00',\n 800: '#ef6c00',\n 900: '#e65100',\n A100: '#ffd180',\n A200: '#ffab40',\n A400: '#ff9100',\n A700: '#ff6d00'\n};\nexport default orange;","const blue = {\n 50: '#e3f2fd',\n 100: '#bbdefb',\n 200: '#90caf9',\n 300: '#64b5f6',\n 400: '#42a5f5',\n 500: '#2196f3',\n 600: '#1e88e5',\n 700: '#1976d2',\n 800: '#1565c0',\n 900: '#0d47a1',\n A100: '#82b1ff',\n A200: '#448aff',\n A400: '#2979ff',\n A700: '#2962ff'\n};\nexport default blue;","const lightBlue = {\n 50: '#e1f5fe',\n 100: '#b3e5fc',\n 200: '#81d4fa',\n 300: '#4fc3f7',\n 400: '#29b6f6',\n 500: '#03a9f4',\n 600: '#039be5',\n 700: '#0288d1',\n 800: '#0277bd',\n 900: '#01579b',\n A100: '#80d8ff',\n A200: '#40c4ff',\n A400: '#00b0ff',\n A700: '#0091ea'\n};\nexport default lightBlue;","const green = {\n 50: '#e8f5e9',\n 100: '#c8e6c9',\n 200: '#a5d6a7',\n 300: '#81c784',\n 400: '#66bb6a',\n 500: '#4caf50',\n 600: '#43a047',\n 700: '#388e3c',\n 800: '#2e7d32',\n 900: '#1b5e20',\n A100: '#b9f6ca',\n A200: '#69f0ae',\n A400: '#00e676',\n A700: '#00c853'\n};\nexport default green;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\nconst _excluded = [\"mode\", \"contrastThreshold\", \"tonalOffset\"];\nimport { deepmerge } from '@mui/utils';\nimport { darken, getContrastRatio, lighten } from '@mui/system';\nimport common from '../colors/common';\nimport grey from '../colors/grey';\nimport purple from '../colors/purple';\nimport red from '../colors/red';\nimport orange from '../colors/orange';\nimport blue from '../colors/blue';\nimport lightBlue from '../colors/lightBlue';\nimport green from '../colors/green';\nexport const light = {\n // The colors used to style the text.\n text: {\n // The most important text.\n primary: 'rgba(0, 0, 0, 0.87)',\n // Secondary text.\n secondary: 'rgba(0, 0, 0, 0.6)',\n // Disabled text have even lower visual prominence.\n disabled: 'rgba(0, 0, 0, 0.38)'\n },\n // The color used to divide different elements.\n divider: 'rgba(0, 0, 0, 0.12)',\n // The background colors used to style the surfaces.\n // Consistency between these values is important.\n background: {\n paper: common.white,\n default: common.white\n },\n // The colors used to style the action elements.\n action: {\n // The color of an active action like an icon button.\n active: 'rgba(0, 0, 0, 0.54)',\n // The color of an hovered action.\n hover: 'rgba(0, 0, 0, 0.04)',\n hoverOpacity: 0.04,\n // The color of a selected action.\n selected: 'rgba(0, 0, 0, 0.08)',\n selectedOpacity: 0.08,\n // The color of a disabled action.\n disabled: 'rgba(0, 0, 0, 0.26)',\n // The background color of a disabled action.\n disabledBackground: 'rgba(0, 0, 0, 0.12)',\n disabledOpacity: 0.38,\n focus: 'rgba(0, 0, 0, 0.12)',\n focusOpacity: 0.12,\n activatedOpacity: 0.12\n }\n};\nexport const dark = {\n text: {\n primary: common.white,\n secondary: 'rgba(255, 255, 255, 0.7)',\n disabled: 'rgba(255, 255, 255, 0.5)',\n icon: 'rgba(255, 255, 255, 0.5)'\n },\n divider: 'rgba(255, 255, 255, 0.12)',\n background: {\n paper: '#121212',\n default: '#121212'\n },\n action: {\n active: common.white,\n hover: 'rgba(255, 255, 255, 0.08)',\n hoverOpacity: 0.08,\n selected: 'rgba(255, 255, 255, 0.16)',\n selectedOpacity: 0.16,\n disabled: 'rgba(255, 255, 255, 0.3)',\n disabledBackground: 'rgba(255, 255, 255, 0.12)',\n disabledOpacity: 0.38,\n focus: 'rgba(255, 255, 255, 0.12)',\n focusOpacity: 0.12,\n activatedOpacity: 0.24\n }\n};\nfunction addLightOrDark(intent, direction, shade, tonalOffset) {\n const tonalOffsetLight = tonalOffset.light || tonalOffset;\n const tonalOffsetDark = tonalOffset.dark || tonalOffset * 1.5;\n if (!intent[direction]) {\n if (intent.hasOwnProperty(shade)) {\n intent[direction] = intent[shade];\n } else if (direction === 'light') {\n intent.light = lighten(intent.main, tonalOffsetLight);\n } else if (direction === 'dark') {\n intent.dark = darken(intent.main, tonalOffsetDark);\n }\n }\n}\nfunction getDefaultPrimary(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: blue[200],\n light: blue[50],\n dark: blue[400]\n };\n }\n return {\n main: blue[700],\n light: blue[400],\n dark: blue[800]\n };\n}\nfunction getDefaultSecondary(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: purple[200],\n light: purple[50],\n dark: purple[400]\n };\n }\n return {\n main: purple[500],\n light: purple[300],\n dark: purple[700]\n };\n}\nfunction getDefaultError(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: red[500],\n light: red[300],\n dark: red[700]\n };\n }\n return {\n main: red[700],\n light: red[400],\n dark: red[800]\n };\n}\nfunction getDefaultInfo(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: lightBlue[400],\n light: lightBlue[300],\n dark: lightBlue[700]\n };\n }\n return {\n main: lightBlue[700],\n light: lightBlue[500],\n dark: lightBlue[900]\n };\n}\nfunction getDefaultSuccess(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: green[400],\n light: green[300],\n dark: green[700]\n };\n }\n return {\n main: green[800],\n light: green[500],\n dark: green[900]\n };\n}\nfunction getDefaultWarning(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: orange[400],\n light: orange[300],\n dark: orange[700]\n };\n }\n return {\n main: '#ed6c02',\n // closest to orange[800] that pass 3:1.\n light: orange[500],\n dark: orange[900]\n };\n}\nexport default function createPalette(palette) {\n const {\n mode = 'light',\n contrastThreshold = 3,\n tonalOffset = 0.2\n } = palette,\n other = _objectWithoutPropertiesLoose(palette, _excluded);\n const primary = palette.primary || getDefaultPrimary(mode);\n const secondary = palette.secondary || getDefaultSecondary(mode);\n const error = palette.error || getDefaultError(mode);\n const info = palette.info || getDefaultInfo(mode);\n const success = palette.success || getDefaultSuccess(mode);\n const warning = palette.warning || getDefaultWarning(mode);\n\n // Use the same logic as\n // Bootstrap: https://github.com/twbs/bootstrap/blob/1d6e3710dd447de1a200f29e8fa521f8a0908f70/scss/_functions.scss#L59\n // and material-components-web https://github.com/material-components/material-components-web/blob/ac46b8863c4dab9fc22c4c662dc6bd1b65dd652f/packages/mdc-theme/_functions.scss#L54\n function getContrastText(background) {\n const contrastText = getContrastRatio(background, dark.text.primary) >= contrastThreshold ? dark.text.primary : light.text.primary;\n if (process.env.NODE_ENV !== 'production') {\n const contrast = getContrastRatio(background, contrastText);\n if (contrast < 3) {\n console.error([`MUI: The contrast ratio of ${contrast}:1 for ${contrastText} on ${background}`, 'falls below the WCAG recommended absolute minimum contrast ratio of 3:1.', 'https://www.w3.org/TR/2008/REC-WCAG20-20081211/#visual-audio-contrast-contrast'].join('\\n'));\n }\n }\n return contrastText;\n }\n const augmentColor = ({\n color,\n name,\n mainShade = 500,\n lightShade = 300,\n darkShade = 700\n }) => {\n color = _extends({}, color);\n if (!color.main && color[mainShade]) {\n color.main = color[mainShade];\n }\n if (!color.hasOwnProperty('main')) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: The color${name ? ` (${name})` : ''} provided to augmentColor(color) is invalid.\nThe color object needs to have a \\`main\\` property or a \\`${mainShade}\\` property.` : _formatMuiErrorMessage(11, name ? ` (${name})` : '', mainShade));\n }\n if (typeof color.main !== 'string') {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: The color${name ? ` (${name})` : ''} provided to augmentColor(color) is invalid.\n\\`color.main\\` should be a string, but \\`${JSON.stringify(color.main)}\\` was provided instead.\n\nDid you intend to use one of the following approaches?\n\nimport { green } from \"@mui/material/colors\";\n\nconst theme1 = createTheme({ palette: {\n primary: green,\n} });\n\nconst theme2 = createTheme({ palette: {\n primary: { main: green[500] },\n} });` : _formatMuiErrorMessage(12, name ? ` (${name})` : '', JSON.stringify(color.main)));\n }\n addLightOrDark(color, 'light', lightShade, tonalOffset);\n addLightOrDark(color, 'dark', darkShade, tonalOffset);\n if (!color.contrastText) {\n color.contrastText = getContrastText(color.main);\n }\n return color;\n };\n const modes = {\n dark,\n light\n };\n if (process.env.NODE_ENV !== 'production') {\n if (!modes[mode]) {\n console.error(`MUI: The palette mode \\`${mode}\\` is not supported.`);\n }\n }\n const paletteOutput = deepmerge(_extends({\n // A collection of common colors.\n common: _extends({}, common),\n // prevent mutable object.\n // The palette mode, can be light or dark.\n mode,\n // The colors used to represent primary interface elements for a user.\n primary: augmentColor({\n color: primary,\n name: 'primary'\n }),\n // The colors used to represent secondary interface elements for a user.\n secondary: augmentColor({\n color: secondary,\n name: 'secondary',\n mainShade: 'A400',\n lightShade: 'A200',\n darkShade: 'A700'\n }),\n // The colors used to represent interface elements that the user should be made aware of.\n error: augmentColor({\n color: error,\n name: 'error'\n }),\n // The colors used to represent potentially dangerous actions or important messages.\n warning: augmentColor({\n color: warning,\n name: 'warning'\n }),\n // The colors used to present information to the user that is neutral and not necessarily important.\n info: augmentColor({\n color: info,\n name: 'info'\n }),\n // The colors used to indicate the successful completion of an action that user triggered.\n success: augmentColor({\n color: success,\n name: 'success'\n }),\n // The grey colors.\n grey,\n // Used by `getContrastText()` to maximize the contrast between\n // the background and the text.\n contrastThreshold,\n // Takes a background color and returns the text color that maximizes the contrast.\n getContrastText,\n // Generate a rich color object.\n augmentColor,\n // Used by the functions below to shift a color's luminance by approximately\n // two indexes within its tonal palette.\n // E.g., shift from Red 500 to Red 300 or Red 700.\n tonalOffset\n }, modes[mode]), other);\n return paletteOutput;\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"fontFamily\", \"fontSize\", \"fontWeightLight\", \"fontWeightRegular\", \"fontWeightMedium\", \"fontWeightBold\", \"htmlFontSize\", \"allVariants\", \"pxToRem\"];\nimport { deepmerge } from '@mui/utils';\nfunction round(value) {\n return Math.round(value * 1e5) / 1e5;\n}\nconst caseAllCaps = {\n textTransform: 'uppercase'\n};\nconst defaultFontFamily = '\"Roboto\", \"Helvetica\", \"Arial\", sans-serif';\n\n/**\n * @see @link{https://m2.material.io/design/typography/the-type-system.html}\n * @see @link{https://m2.material.io/design/typography/understanding-typography.html}\n */\nexport default function createTypography(palette, typography) {\n const _ref = typeof typography === 'function' ? typography(palette) : typography,\n {\n fontFamily = defaultFontFamily,\n // The default font size of the Material Specification.\n fontSize = 14,\n // px\n fontWeightLight = 300,\n fontWeightRegular = 400,\n fontWeightMedium = 500,\n fontWeightBold = 700,\n // Tell MUI what's the font-size on the html element.\n // 16px is the default font-size used by browsers.\n htmlFontSize = 16,\n // Apply the CSS properties to all the variants.\n allVariants,\n pxToRem: pxToRem2\n } = _ref,\n other = _objectWithoutPropertiesLoose(_ref, _excluded);\n if (process.env.NODE_ENV !== 'production') {\n if (typeof fontSize !== 'number') {\n console.error('MUI: `fontSize` is required to be a number.');\n }\n if (typeof htmlFontSize !== 'number') {\n console.error('MUI: `htmlFontSize` is required to be a number.');\n }\n }\n const coef = fontSize / 14;\n const pxToRem = pxToRem2 || (size => `${size / htmlFontSize * coef}rem`);\n const buildVariant = (fontWeight, size, lineHeight, letterSpacing, casing) => _extends({\n fontFamily,\n fontWeight,\n fontSize: pxToRem(size),\n // Unitless following https://meyerweb.com/eric/thoughts/2006/02/08/unitless-line-heights/\n lineHeight\n }, fontFamily === defaultFontFamily ? {\n letterSpacing: `${round(letterSpacing / size)}em`\n } : {}, casing, allVariants);\n const variants = {\n h1: buildVariant(fontWeightLight, 96, 1.167, -1.5),\n h2: buildVariant(fontWeightLight, 60, 1.2, -0.5),\n h3: buildVariant(fontWeightRegular, 48, 1.167, 0),\n h4: buildVariant(fontWeightRegular, 34, 1.235, 0.25),\n h5: buildVariant(fontWeightRegular, 24, 1.334, 0),\n h6: buildVariant(fontWeightMedium, 20, 1.6, 0.15),\n subtitle1: buildVariant(fontWeightRegular, 16, 1.75, 0.15),\n subtitle2: buildVariant(fontWeightMedium, 14, 1.57, 0.1),\n body1: buildVariant(fontWeightRegular, 16, 1.5, 0.15),\n body2: buildVariant(fontWeightRegular, 14, 1.43, 0.15),\n button: buildVariant(fontWeightMedium, 14, 1.75, 0.4, caseAllCaps),\n caption: buildVariant(fontWeightRegular, 12, 1.66, 0.4),\n overline: buildVariant(fontWeightRegular, 12, 2.66, 1, caseAllCaps),\n // TODO v6: Remove handling of 'inherit' variant from the theme as it is already handled in Material UI's Typography component. Also, remember to remove the associated types.\n inherit: {\n fontFamily: 'inherit',\n fontWeight: 'inherit',\n fontSize: 'inherit',\n lineHeight: 'inherit',\n letterSpacing: 'inherit'\n }\n };\n return deepmerge(_extends({\n htmlFontSize,\n pxToRem,\n fontFamily,\n fontSize,\n fontWeightLight,\n fontWeightRegular,\n fontWeightMedium,\n fontWeightBold\n }, variants), other, {\n clone: false // No need to clone deep\n });\n}","const shadowKeyUmbraOpacity = 0.2;\nconst shadowKeyPenumbraOpacity = 0.14;\nconst shadowAmbientShadowOpacity = 0.12;\nfunction createShadow(...px) {\n return [`${px[0]}px ${px[1]}px ${px[2]}px ${px[3]}px rgba(0,0,0,${shadowKeyUmbraOpacity})`, `${px[4]}px ${px[5]}px ${px[6]}px ${px[7]}px rgba(0,0,0,${shadowKeyPenumbraOpacity})`, `${px[8]}px ${px[9]}px ${px[10]}px ${px[11]}px rgba(0,0,0,${shadowAmbientShadowOpacity})`].join(',');\n}\n\n// Values from https://github.com/material-components/material-components-web/blob/be8747f94574669cb5e7add1a7c54fa41a89cec7/packages/mdc-elevation/_variables.scss\nconst shadows = ['none', createShadow(0, 2, 1, -1, 0, 1, 1, 0, 0, 1, 3, 0), createShadow(0, 3, 1, -2, 0, 2, 2, 0, 0, 1, 5, 0), createShadow(0, 3, 3, -2, 0, 3, 4, 0, 0, 1, 8, 0), createShadow(0, 2, 4, -1, 0, 4, 5, 0, 0, 1, 10, 0), createShadow(0, 3, 5, -1, 0, 5, 8, 0, 0, 1, 14, 0), createShadow(0, 3, 5, -1, 0, 6, 10, 0, 0, 1, 18, 0), createShadow(0, 4, 5, -2, 0, 7, 10, 1, 0, 2, 16, 1), createShadow(0, 5, 5, -3, 0, 8, 10, 1, 0, 3, 14, 2), createShadow(0, 5, 6, -3, 0, 9, 12, 1, 0, 3, 16, 2), createShadow(0, 6, 6, -3, 0, 10, 14, 1, 0, 4, 18, 3), createShadow(0, 6, 7, -4, 0, 11, 15, 1, 0, 4, 20, 3), createShadow(0, 7, 8, -4, 0, 12, 17, 2, 0, 5, 22, 4), createShadow(0, 7, 8, -4, 0, 13, 19, 2, 0, 5, 24, 4), createShadow(0, 7, 9, -4, 0, 14, 21, 2, 0, 5, 26, 4), createShadow(0, 8, 9, -5, 0, 15, 22, 2, 0, 6, 28, 5), createShadow(0, 8, 10, -5, 0, 16, 24, 2, 0, 6, 30, 5), createShadow(0, 8, 11, -5, 0, 17, 26, 2, 0, 6, 32, 5), createShadow(0, 9, 11, -5, 0, 18, 28, 2, 0, 7, 34, 6), createShadow(0, 9, 12, -6, 0, 19, 29, 2, 0, 7, 36, 6), createShadow(0, 10, 13, -6, 0, 20, 31, 3, 0, 8, 38, 7), createShadow(0, 10, 13, -6, 0, 21, 33, 3, 0, 8, 40, 7), createShadow(0, 10, 14, -6, 0, 22, 35, 3, 0, 8, 42, 7), createShadow(0, 11, 14, -7, 0, 23, 36, 3, 0, 9, 44, 8), createShadow(0, 11, 15, -7, 0, 24, 38, 3, 0, 9, 46, 8)];\nexport default shadows;","import _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nconst _excluded = [\"duration\", \"easing\", \"delay\"];\n// Follow https://material.google.com/motion/duration-easing.html#duration-easing-natural-easing-curves\n// to learn the context in which each easing should be used.\nexport const easing = {\n // This is the most common easing curve.\n easeInOut: 'cubic-bezier(0.4, 0, 0.2, 1)',\n // Objects enter the screen at full velocity from off-screen and\n // slowly decelerate to a resting point.\n easeOut: 'cubic-bezier(0.0, 0, 0.2, 1)',\n // Objects leave the screen at full velocity. They do not decelerate when off-screen.\n easeIn: 'cubic-bezier(0.4, 0, 1, 1)',\n // The sharp curve is used by objects that may return to the screen at any time.\n sharp: 'cubic-bezier(0.4, 0, 0.6, 1)'\n};\n\n// Follow https://m2.material.io/guidelines/motion/duration-easing.html#duration-easing-common-durations\n// to learn when use what timing\nexport const duration = {\n shortest: 150,\n shorter: 200,\n short: 250,\n // most basic recommended timing\n standard: 300,\n // this is to be used in complex animations\n complex: 375,\n // recommended when something is entering screen\n enteringScreen: 225,\n // recommended when something is leaving screen\n leavingScreen: 195\n};\nfunction formatMs(milliseconds) {\n return `${Math.round(milliseconds)}ms`;\n}\nfunction getAutoHeightDuration(height) {\n if (!height) {\n return 0;\n }\n const constant = height / 36;\n\n // https://www.wolframalpha.com/input/?i=(4+%2B+15+*+(x+%2F+36+)+**+0.25+%2B+(x+%2F+36)+%2F+5)+*+10\n return Math.round((4 + 15 * constant ** 0.25 + constant / 5) * 10);\n}\nexport default function createTransitions(inputTransitions) {\n const mergedEasing = _extends({}, easing, inputTransitions.easing);\n const mergedDuration = _extends({}, duration, inputTransitions.duration);\n const create = (props = ['all'], options = {}) => {\n const {\n duration: durationOption = mergedDuration.standard,\n easing: easingOption = mergedEasing.easeInOut,\n delay = 0\n } = options,\n other = _objectWithoutPropertiesLoose(options, _excluded);\n if (process.env.NODE_ENV !== 'production') {\n const isString = value => typeof value === 'string';\n // IE11 support, replace with Number.isNaN\n // eslint-disable-next-line no-restricted-globals\n const isNumber = value => !isNaN(parseFloat(value));\n if (!isString(props) && !Array.isArray(props)) {\n console.error('MUI: Argument \"props\" must be a string or Array.');\n }\n if (!isNumber(durationOption) && !isString(durationOption)) {\n console.error(`MUI: Argument \"duration\" must be a number or a string but found ${durationOption}.`);\n }\n if (!isString(easingOption)) {\n console.error('MUI: Argument \"easing\" must be a string.');\n }\n if (!isNumber(delay) && !isString(delay)) {\n console.error('MUI: Argument \"delay\" must be a number or a string.');\n }\n if (typeof options !== 'object') {\n console.error(['MUI: Secong argument of transition.create must be an object.', \"Arguments should be either `create('prop1', options)` or `create(['prop1', 'prop2'], options)`\"].join('\\n'));\n }\n if (Object.keys(other).length !== 0) {\n console.error(`MUI: Unrecognized argument(s) [${Object.keys(other).join(',')}].`);\n }\n }\n return (Array.isArray(props) ? props : [props]).map(animatedProp => `${animatedProp} ${typeof durationOption === 'string' ? durationOption : formatMs(durationOption)} ${easingOption} ${typeof delay === 'string' ? delay : formatMs(delay)}`).join(',');\n };\n return _extends({\n getAutoHeightDuration,\n create\n }, inputTransitions, {\n easing: mergedEasing,\n duration: mergedDuration\n });\n}","// We need to centralize the zIndex definitions as they work\n// like global values in the browser.\nconst zIndex = {\n mobileStepper: 1000,\n fab: 1050,\n speedDial: 1050,\n appBar: 1100,\n drawer: 1200,\n modal: 1300,\n snackbar: 1400,\n tooltip: 1500\n};\nexport default zIndex;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\nconst _excluded = [\"breakpoints\", \"mixins\", \"spacing\", \"palette\", \"transitions\", \"typography\", \"shape\"];\nimport { deepmerge } from '@mui/utils';\nimport { createTheme as systemCreateTheme, unstable_defaultSxConfig as defaultSxConfig, unstable_styleFunctionSx as styleFunctionSx } from '@mui/system';\nimport generateUtilityClass from '@mui/utils/generateUtilityClass';\nimport createMixins from './createMixins';\nimport createPalette from './createPalette';\nimport createTypography from './createTypography';\nimport shadows from './shadows';\nimport createTransitions from './createTransitions';\nimport zIndex from './zIndex';\nfunction createTheme(options = {}, ...args) {\n const {\n mixins: mixinsInput = {},\n palette: paletteInput = {},\n transitions: transitionsInput = {},\n typography: typographyInput = {}\n } = options,\n other = _objectWithoutPropertiesLoose(options, _excluded);\n if (options.vars) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: \\`vars\\` is a private field used for CSS variables support.\nPlease use another name.` : _formatMuiErrorMessage(18));\n }\n const palette = createPalette(paletteInput);\n const systemTheme = systemCreateTheme(options);\n let muiTheme = deepmerge(systemTheme, {\n mixins: createMixins(systemTheme.breakpoints, mixinsInput),\n palette,\n // Don't use [...shadows] until you've verified its transpiled code is not invoking the iterator protocol.\n shadows: shadows.slice(),\n typography: createTypography(palette, typographyInput),\n transitions: createTransitions(transitionsInput),\n zIndex: _extends({}, zIndex)\n });\n muiTheme = deepmerge(muiTheme, other);\n muiTheme = args.reduce((acc, argument) => deepmerge(acc, argument), muiTheme);\n if (process.env.NODE_ENV !== 'production') {\n // TODO v6: Refactor to use globalStateClassesMapping from @mui/utils once `readOnly` state class is used in Rating component.\n const stateClasses = ['active', 'checked', 'completed', 'disabled', 'error', 'expanded', 'focused', 'focusVisible', 'required', 'selected'];\n const traverse = (node, component) => {\n let key;\n\n // eslint-disable-next-line guard-for-in, no-restricted-syntax\n for (key in node) {\n const child = node[key];\n if (stateClasses.indexOf(key) !== -1 && Object.keys(child).length > 0) {\n if (process.env.NODE_ENV !== 'production') {\n const stateClass = generateUtilityClass('', key);\n console.error([`MUI: The \\`${component}\\` component increases ` + `the CSS specificity of the \\`${key}\\` internal state.`, 'You can not override it like this: ', JSON.stringify(node, null, 2), '', `Instead, you need to use the '&.${stateClass}' syntax:`, JSON.stringify({\n root: {\n [`&.${stateClass}`]: child\n }\n }, null, 2), '', 'https://mui.com/r/state-classes-guide'].join('\\n'));\n }\n // Remove the style to prevent global conflicts.\n node[key] = {};\n }\n }\n };\n Object.keys(muiTheme.components).forEach(component => {\n const styleOverrides = muiTheme.components[component].styleOverrides;\n if (styleOverrides && component.indexOf('Mui') === 0) {\n traverse(styleOverrides, component);\n }\n });\n }\n muiTheme.unstable_sxConfig = _extends({}, defaultSxConfig, other == null ? void 0 : other.unstable_sxConfig);\n muiTheme.unstable_sx = function sx(props) {\n return styleFunctionSx({\n sx: props,\n theme: this\n });\n };\n return muiTheme;\n}\nlet warnedOnce = false;\nexport function createMuiTheme(...args) {\n if (process.env.NODE_ENV !== 'production') {\n if (!warnedOnce) {\n warnedOnce = true;\n console.error(['MUI: the createMuiTheme function was renamed to createTheme.', '', \"You should use `import { createTheme } from '@mui/material/styles'`\"].join('\\n'));\n }\n }\n return createTheme(...args);\n}\nexport default createTheme;","'use client';\n\nimport createTheme from './createTheme';\nconst defaultTheme = createTheme();\nexport default defaultTheme;","export default '$$material';","'use client';\n\nimport { useThemeProps as systemUseThemeProps } from '@mui/system';\nimport defaultTheme from './defaultTheme';\nimport THEME_ID from './identifier';\nexport default function useThemeProps({\n props,\n name\n}) {\n return systemUseThemeProps({\n props,\n name,\n defaultTheme,\n themeId: THEME_ID\n });\n}","'use client';\n\nimport { createStyled, shouldForwardProp } from '@mui/system';\nimport defaultTheme from './defaultTheme';\nimport THEME_ID from './identifier';\nexport const rootShouldForwardProp = prop => shouldForwardProp(prop) && prop !== 'classes';\nexport const slotShouldForwardProp = shouldForwardProp;\nconst styled = createStyled({\n themeId: THEME_ID,\n defaultTheme,\n rootShouldForwardProp\n});\nexport default styled;","import generateUtilityClasses from '@mui/utils/generateUtilityClasses';\nimport generateUtilityClass from '@mui/utils/generateUtilityClass';\nexport function getSvgIconUtilityClass(slot) {\n return generateUtilityClass('MuiSvgIcon', slot);\n}\nconst svgIconClasses = generateUtilityClasses('MuiSvgIcon', ['root', 'colorPrimary', 'colorSecondary', 'colorAction', 'colorError', 'colorDisabled', 'fontSizeInherit', 'fontSizeSmall', 'fontSizeMedium', 'fontSizeLarge']);\nexport default svgIconClasses;","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"children\", \"className\", \"color\", \"component\", \"fontSize\", \"htmlColor\", \"inheritViewBox\", \"titleAccess\", \"viewBox\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport clsx from 'clsx';\nimport { unstable_composeClasses as composeClasses } from '@mui/base/composeClasses';\nimport capitalize from '../utils/capitalize';\nimport useThemeProps from '../styles/useThemeProps';\nimport styled from '../styles/styled';\nimport { getSvgIconUtilityClass } from './svgIconClasses';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nimport { jsxs as _jsxs } from \"react/jsx-runtime\";\nconst useUtilityClasses = ownerState => {\n const {\n color,\n fontSize,\n classes\n } = ownerState;\n const slots = {\n root: ['root', color !== 'inherit' && `color${capitalize(color)}`, `fontSize${capitalize(fontSize)}`]\n };\n return composeClasses(slots, getSvgIconUtilityClass, classes);\n};\nconst SvgIconRoot = styled('svg', {\n name: 'MuiSvgIcon',\n slot: 'Root',\n overridesResolver: (props, styles) => {\n const {\n ownerState\n } = props;\n return [styles.root, ownerState.color !== 'inherit' && styles[`color${capitalize(ownerState.color)}`], styles[`fontSize${capitalize(ownerState.fontSize)}`]];\n }\n})(({\n theme,\n ownerState\n}) => {\n var _theme$transitions, _theme$transitions$cr, _theme$transitions2, _theme$typography, _theme$typography$pxT, _theme$typography2, _theme$typography2$px, _theme$typography3, _theme$typography3$px, _palette$ownerState$c, _palette, _palette2, _palette3;\n return {\n userSelect: 'none',\n width: '1em',\n height: '1em',\n display: 'inline-block',\n // the will define the property that has `currentColor`\n // e.g. heroicons uses fill=\"none\" and stroke=\"currentColor\"\n fill: ownerState.hasSvgAsChild ? undefined : 'currentColor',\n flexShrink: 0,\n transition: (_theme$transitions = theme.transitions) == null || (_theme$transitions$cr = _theme$transitions.create) == null ? void 0 : _theme$transitions$cr.call(_theme$transitions, 'fill', {\n duration: (_theme$transitions2 = theme.transitions) == null || (_theme$transitions2 = _theme$transitions2.duration) == null ? void 0 : _theme$transitions2.shorter\n }),\n fontSize: {\n inherit: 'inherit',\n small: ((_theme$typography = theme.typography) == null || (_theme$typography$pxT = _theme$typography.pxToRem) == null ? void 0 : _theme$typography$pxT.call(_theme$typography, 20)) || '1.25rem',\n medium: ((_theme$typography2 = theme.typography) == null || (_theme$typography2$px = _theme$typography2.pxToRem) == null ? void 0 : _theme$typography2$px.call(_theme$typography2, 24)) || '1.5rem',\n large: ((_theme$typography3 = theme.typography) == null || (_theme$typography3$px = _theme$typography3.pxToRem) == null ? void 0 : _theme$typography3$px.call(_theme$typography3, 35)) || '2.1875rem'\n }[ownerState.fontSize],\n // TODO v5 deprecate, v6 remove for sx\n color: (_palette$ownerState$c = (_palette = (theme.vars || theme).palette) == null || (_palette = _palette[ownerState.color]) == null ? void 0 : _palette.main) != null ? _palette$ownerState$c : {\n action: (_palette2 = (theme.vars || theme).palette) == null || (_palette2 = _palette2.action) == null ? void 0 : _palette2.active,\n disabled: (_palette3 = (theme.vars || theme).palette) == null || (_palette3 = _palette3.action) == null ? void 0 : _palette3.disabled,\n inherit: undefined\n }[ownerState.color]\n };\n});\nconst SvgIcon = /*#__PURE__*/React.forwardRef(function SvgIcon(inProps, ref) {\n const props = useThemeProps({\n props: inProps,\n name: 'MuiSvgIcon'\n });\n const {\n children,\n className,\n color = 'inherit',\n component = 'svg',\n fontSize = 'medium',\n htmlColor,\n inheritViewBox = false,\n titleAccess,\n viewBox = '0 0 24 24'\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const hasSvgAsChild = /*#__PURE__*/React.isValidElement(children) && children.type === 'svg';\n const ownerState = _extends({}, props, {\n color,\n component,\n fontSize,\n instanceFontSize: inProps.fontSize,\n inheritViewBox,\n viewBox,\n hasSvgAsChild\n });\n const more = {};\n if (!inheritViewBox) {\n more.viewBox = viewBox;\n }\n const classes = useUtilityClasses(ownerState);\n return /*#__PURE__*/_jsxs(SvgIconRoot, _extends({\n as: component,\n className: clsx(classes.root, className),\n focusable: \"false\",\n color: htmlColor,\n \"aria-hidden\": titleAccess ? undefined : true,\n role: titleAccess ? 'img' : undefined,\n ref: ref\n }, more, other, hasSvgAsChild && children.props, {\n ownerState: ownerState,\n children: [hasSvgAsChild ? children.props.children : children, titleAccess ? /*#__PURE__*/_jsx(\"title\", {\n children: titleAccess\n }) : null]\n }));\n});\nprocess.env.NODE_ENV !== \"production\" ? SvgIcon.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the d.ts file and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * Node passed into the SVG element.\n */\n children: PropTypes.node,\n /**\n * Override or extend the styles applied to the component.\n */\n classes: PropTypes.object,\n /**\n * @ignore\n */\n className: PropTypes.string,\n /**\n * The color of the component.\n * It supports both default and custom theme colors, which can be added as shown in the\n * [palette customization guide](https://mui.com/material-ui/customization/palette/#custom-colors).\n * You can use the `htmlColor` prop to apply a color attribute to the SVG element.\n * @default 'inherit'\n */\n color: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.oneOf(['inherit', 'action', 'disabled', 'primary', 'secondary', 'error', 'info', 'success', 'warning']), PropTypes.string]),\n /**\n * The component used for the root node.\n * Either a string to use a HTML element or a component.\n */\n component: PropTypes.elementType,\n /**\n * The fontSize applied to the icon. Defaults to 24px, but can be configure to inherit font size.\n * @default 'medium'\n */\n fontSize: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.oneOf(['inherit', 'large', 'medium', 'small']), PropTypes.string]),\n /**\n * Applies a color attribute to the SVG element.\n */\n htmlColor: PropTypes.string,\n /**\n * If `true`, the root node will inherit the custom `component`'s viewBox and the `viewBox`\n * prop will be ignored.\n * Useful when you want to reference a custom `component` and have `SvgIcon` pass that\n * `component`'s viewBox to the root node.\n * @default false\n */\n inheritViewBox: PropTypes.bool,\n /**\n * The shape-rendering attribute. The behavior of the different options is described on the\n * [MDN Web Docs](https://developer.mozilla.org/en-US/docs/Web/SVG/Attribute/shape-rendering).\n * If you are having issues with blurry icons you should investigate this prop.\n */\n shapeRendering: PropTypes.string,\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Provides a human-readable title for the element that contains it.\n * https://www.w3.org/TR/SVG-access/#Equivalent\n */\n titleAccess: PropTypes.string,\n /**\n * Allows you to redefine what the coordinates without units mean inside an SVG element.\n * For example, if the SVG element is 500 (width) by 200 (height),\n * and you pass viewBox=\"0 0 50 20\",\n * this means that the coordinates inside the SVG will go from the top left corner (0,0)\n * to bottom right (50,20) and each unit will be worth 10px.\n * @default '0 0 24 24'\n */\n viewBox: PropTypes.string\n} : void 0;\nSvgIcon.muiName = 'SvgIcon';\nexport default SvgIcon;","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport * as React from 'react';\nimport SvgIcon from '../SvgIcon';\n\n/**\n * Private module reserved for @mui packages.\n */\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nexport default function createSvgIcon(path, displayName) {\n function Component(props, ref) {\n return /*#__PURE__*/_jsx(SvgIcon, _extends({\n \"data-testid\": `${displayName}Icon`,\n ref: ref\n }, props, {\n children: path\n }));\n }\n if (process.env.NODE_ENV !== 'production') {\n // Need to set `displayName` on the inner component for React.memo.\n // React prior to 16.14 ignores `displayName` on the wrapper.\n Component.displayName = `${displayName}Icon`;\n }\n Component.muiName = SvgIcon.muiName;\n return /*#__PURE__*/React.memo( /*#__PURE__*/React.forwardRef(Component));\n}","'use client';\n\nimport { unstable_ClassNameGenerator as ClassNameGenerator } from '@mui/base/ClassNameGenerator';\nexport { default as capitalize } from './capitalize';\nexport { default as createChainedFunction } from './createChainedFunction';\nexport { default as createSvgIcon } from './createSvgIcon';\nexport { default as debounce } from './debounce';\nexport { default as deprecatedPropType } from './deprecatedPropType';\nexport { default as isMuiElement } from './isMuiElement';\nexport { default as ownerDocument } from './ownerDocument';\nexport { default as ownerWindow } from './ownerWindow';\nexport { default as requirePropFactory } from './requirePropFactory';\nexport { default as setRef } from './setRef';\nexport { default as unstable_useEnhancedEffect } from './useEnhancedEffect';\nexport { default as unstable_useId } from './useId';\nexport { default as unsupportedProp } from './unsupportedProp';\nexport { default as useControlled } from './useControlled';\nexport { default as useEventCallback } from './useEventCallback';\nexport { default as useForkRef } from './useForkRef';\nexport { default as useIsFocusVisible } from './useIsFocusVisible';\n// TODO: remove this export once ClassNameGenerator is stable\n// eslint-disable-next-line @typescript-eslint/naming-convention\nexport const unstable_ClassNameGenerator = {\n configure: generator => {\n if (process.env.NODE_ENV !== 'production') {\n console.warn(['MUI: `ClassNameGenerator` import from `@mui/material/utils` is outdated and might cause unexpected issues.', '', \"You should use `import { unstable_ClassNameGenerator } from '@mui/material/className'` instead\", '', 'The detail of the issue: https://github.com/mui/material-ui/issues/30011#issuecomment-1024993401', '', 'The updated documentation: https://mui.com/guides/classname-generator/'].join('\\n'));\n }\n ClassNameGenerator.configure(generator);\n }\n};","\"use strict\";\n'use client';\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nObject.defineProperty(exports, \"default\", {\n enumerable: true,\n get: function () {\n return _utils.createSvgIcon;\n }\n});\nvar _utils = require(\"@mui/material/utils\");","\"use strict\";\n\"use client\";\n\nvar _interopRequireDefault = require(\"@babel/runtime/helpers/interopRequireDefault\");\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = void 0;\nvar _createSvgIcon = _interopRequireDefault(require(\"./utils/createSvgIcon\"));\nvar _jsxRuntime = require(\"react/jsx-runtime\");\nvar _default = exports.default = (0, _createSvgIcon.default)( /*#__PURE__*/(0, _jsxRuntime.jsx)(\"path\", {\n d: \"m10 17 5-5-5-5z\"\n}), 'ArrowRight');","/**\n * Determines if a given element is a DOM element name (i.e. not a React component).\n */\nexport function isHostComponent(element) {\n return typeof element === 'string';\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport { isHostComponent } from './isHostComponent';\n\n/**\n * Type of the ownerState based on the type of an element it applies to.\n * This resolves to the provided OwnerState for React components and `undefined` for host components.\n * Falls back to `OwnerState | undefined` when the exact type can't be determined in development time.\n */\n\n/**\n * Appends the ownerState object to the props, merging with the existing one if necessary.\n *\n * @param elementType Type of the element that owns the `existingProps`. If the element is a DOM node or undefined, `ownerState` is not applied.\n * @param otherProps Props of the element.\n * @param ownerState\n */\nexport function appendOwnerState(elementType, otherProps, ownerState) {\n if (elementType === undefined || isHostComponent(elementType)) {\n return otherProps;\n }\n return _extends({}, otherProps, {\n ownerState: _extends({}, otherProps.ownerState, ownerState)\n });\n}","'use client';\n\nimport * as React from 'react';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nconst defaultContextValue = {\n disableDefaultClasses: false\n};\nconst ClassNameConfiguratorContext = /*#__PURE__*/React.createContext(defaultContextValue);\n/**\n * @ignore - internal hook.\n *\n * Wraps the `generateUtilityClass` function and controls how the classes are generated.\n * Currently it only affects whether the classes are applied or not.\n *\n * @returns Function to be called with the `generateUtilityClass` function specific to a component to generate the classes.\n */\nexport function useClassNamesOverride(generateUtilityClass) {\n const {\n disableDefaultClasses\n } = React.useContext(ClassNameConfiguratorContext);\n return slot => {\n if (disableDefaultClasses) {\n return '';\n }\n return generateUtilityClass(slot);\n };\n}\n\n/**\n * Allows to configure the components within to not apply any built-in classes.\n */\nexport function ClassNameConfigurator(props) {\n const {\n disableDefaultClasses,\n children\n } = props;\n const contextValue = React.useMemo(() => ({\n disableDefaultClasses: disableDefaultClasses != null ? disableDefaultClasses : false\n }), [disableDefaultClasses]);\n return /*#__PURE__*/_jsx(ClassNameConfiguratorContext.Provider, {\n value: contextValue,\n children: children\n });\n}","/**\n * Extracts event handlers from a given object.\n * A prop is considered an event handler if it is a function and its name starts with `on`.\n *\n * @param object An object to extract event handlers from.\n * @param excludeKeys An array of keys to exclude from the returned object.\n */\nexport function extractEventHandlers(object, excludeKeys = []) {\n if (object === undefined) {\n return {};\n }\n const result = {};\n Object.keys(object).filter(prop => prop.match(/^on[A-Z]/) && typeof object[prop] === 'function' && !excludeKeys.includes(prop)).forEach(prop => {\n result[prop] = object[prop];\n });\n return result;\n}","/**\n * If `componentProps` is a function, calls it with the provided `ownerState`.\n * Otherwise, just returns `componentProps`.\n */\nexport function resolveComponentProps(componentProps, ownerState, slotState) {\n if (typeof componentProps === 'function') {\n return componentProps(ownerState, slotState);\n }\n return componentProps;\n}","/**\n * Removes event handlers from the given object.\n * A field is considered an event handler if it is a function with a name beginning with `on`.\n *\n * @param object Object to remove event handlers from.\n * @returns Object with event handlers removed.\n */\nexport function omitEventHandlers(object) {\n if (object === undefined) {\n return {};\n }\n const result = {};\n Object.keys(object).filter(prop => !(prop.match(/^on[A-Z]/) && typeof object[prop] === 'function')).forEach(prop => {\n result[prop] = object[prop];\n });\n return result;\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport clsx from 'clsx';\nimport { extractEventHandlers } from './extractEventHandlers';\nimport { omitEventHandlers } from './omitEventHandlers';\n/**\n * Merges the slot component internal props (usually coming from a hook)\n * with the externally provided ones.\n *\n * The merge order is (the latter overrides the former):\n * 1. The internal props (specified as a getter function to work with get*Props hook result)\n * 2. Additional props (specified internally on a Base UI component)\n * 3. External props specified on the owner component. These should only be used on a root slot.\n * 4. External props specified in the `slotProps.*` prop.\n * 5. The `className` prop - combined from all the above.\n * @param parameters\n * @returns\n */\nexport function mergeSlotProps(parameters) {\n const {\n getSlotProps,\n additionalProps,\n externalSlotProps,\n externalForwardedProps,\n className\n } = parameters;\n if (!getSlotProps) {\n // The simpler case - getSlotProps is not defined, so no internal event handlers are defined,\n // so we can simply merge all the props without having to worry about extracting event handlers.\n const joinedClasses = clsx(additionalProps == null ? void 0 : additionalProps.className, className, externalForwardedProps == null ? void 0 : externalForwardedProps.className, externalSlotProps == null ? void 0 : externalSlotProps.className);\n const mergedStyle = _extends({}, additionalProps == null ? void 0 : additionalProps.style, externalForwardedProps == null ? void 0 : externalForwardedProps.style, externalSlotProps == null ? void 0 : externalSlotProps.style);\n const props = _extends({}, additionalProps, externalForwardedProps, externalSlotProps);\n if (joinedClasses.length > 0) {\n props.className = joinedClasses;\n }\n if (Object.keys(mergedStyle).length > 0) {\n props.style = mergedStyle;\n }\n return {\n props,\n internalRef: undefined\n };\n }\n\n // In this case, getSlotProps is responsible for calling the external event handlers.\n // We don't need to include them in the merged props because of this.\n\n const eventHandlers = extractEventHandlers(_extends({}, externalForwardedProps, externalSlotProps));\n const componentsPropsWithoutEventHandlers = omitEventHandlers(externalSlotProps);\n const otherPropsWithoutEventHandlers = omitEventHandlers(externalForwardedProps);\n const internalSlotProps = getSlotProps(eventHandlers);\n\n // The order of classes is important here.\n // Emotion (that we use in libraries consuming Base UI) depends on this order\n // to properly override style. It requires the most important classes to be last\n // (see https://github.com/mui/material-ui/pull/33205) for the related discussion.\n const joinedClasses = clsx(internalSlotProps == null ? void 0 : internalSlotProps.className, additionalProps == null ? void 0 : additionalProps.className, className, externalForwardedProps == null ? void 0 : externalForwardedProps.className, externalSlotProps == null ? void 0 : externalSlotProps.className);\n const mergedStyle = _extends({}, internalSlotProps == null ? void 0 : internalSlotProps.style, additionalProps == null ? void 0 : additionalProps.style, externalForwardedProps == null ? void 0 : externalForwardedProps.style, externalSlotProps == null ? void 0 : externalSlotProps.style);\n const props = _extends({}, internalSlotProps, additionalProps, otherPropsWithoutEventHandlers, componentsPropsWithoutEventHandlers);\n if (joinedClasses.length > 0) {\n props.className = joinedClasses;\n }\n if (Object.keys(mergedStyle).length > 0) {\n props.style = mergedStyle;\n }\n return {\n props,\n internalRef: internalSlotProps.ref\n };\n}","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"elementType\", \"externalSlotProps\", \"ownerState\", \"skipResolvingSlotProps\"];\nimport { unstable_useForkRef as useForkRef } from '@mui/utils';\nimport { appendOwnerState } from './appendOwnerState';\nimport { mergeSlotProps } from './mergeSlotProps';\nimport { resolveComponentProps } from './resolveComponentProps';\n/**\n * @ignore - do not document.\n * Builds the props to be passed into the slot of an unstyled component.\n * It merges the internal props of the component with the ones supplied by the user, allowing to customize the behavior.\n * If the slot component is not a host component, it also merges in the `ownerState`.\n *\n * @param parameters.getSlotProps - A function that returns the props to be passed to the slot component.\n */\nexport function useSlotProps(parameters) {\n var _parameters$additiona;\n const {\n elementType,\n externalSlotProps,\n ownerState,\n skipResolvingSlotProps = false\n } = parameters,\n rest = _objectWithoutPropertiesLoose(parameters, _excluded);\n const resolvedComponentsProps = skipResolvingSlotProps ? {} : resolveComponentProps(externalSlotProps, ownerState);\n const {\n props: mergedProps,\n internalRef\n } = mergeSlotProps(_extends({}, rest, {\n externalSlotProps: resolvedComponentsProps\n }));\n const ref = useForkRef(internalRef, resolvedComponentsProps == null ? void 0 : resolvedComponentsProps.ref, (_parameters$additiona = parameters.additionalProps) == null ? void 0 : _parameters$additiona.ref);\n const props = appendOwnerState(elementType, _extends({}, mergedProps, {\n ref\n }), ownerState);\n return props;\n}","import { globalStateClasses } from '@mui/utils/generateUtilityClass';\nconst GLOBAL_CLASS_PREFIX = 'base';\nfunction buildStateClass(state) {\n return `${GLOBAL_CLASS_PREFIX}--${state}`;\n}\nfunction buildSlotClass(componentName, slot) {\n return `${GLOBAL_CLASS_PREFIX}-${componentName}-${slot}`;\n}\nexport function generateUtilityClass(componentName, slot) {\n const globalStateClass = globalStateClasses[slot];\n return globalStateClass ? buildStateClass(globalStateClass) : buildSlotClass(componentName, slot);\n}\nexport function isGlobalState(slot) {\n return globalStateClasses[slot] !== undefined;\n}","import { generateUtilityClass } from '../generateUtilityClass';\nexport function generateUtilityClasses(componentName, slots) {\n const result = {};\n slots.forEach(slot => {\n result[slot] = generateUtilityClass(componentName, slot);\n });\n return result;\n}","'use client';\n\nimport * as React from 'react';\nimport * as ReactDOM from 'react-dom';\nimport PropTypes from 'prop-types';\nimport { exactProp, HTMLElementType, unstable_useEnhancedEffect as useEnhancedEffect, unstable_useForkRef as useForkRef, unstable_setRef as setRef } from '@mui/utils';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nfunction getContainer(container) {\n return typeof container === 'function' ? container() : container;\n}\n\n/**\n * Portals provide a first-class way to render children into a DOM node\n * that exists outside the DOM hierarchy of the parent component.\n *\n * Demos:\n *\n * - [Portal](https://mui.com/base-ui/react-portal/)\n *\n * API:\n *\n * - [Portal API](https://mui.com/base-ui/react-portal/components-api/#portal)\n */\nconst Portal = /*#__PURE__*/React.forwardRef(function Portal(props, forwardedRef) {\n const {\n children,\n container,\n disablePortal = false\n } = props;\n const [mountNode, setMountNode] = React.useState(null);\n // @ts-expect-error TODO upstream fix\n const handleRef = useForkRef( /*#__PURE__*/React.isValidElement(children) ? children.ref : null, forwardedRef);\n useEnhancedEffect(() => {\n if (!disablePortal) {\n setMountNode(getContainer(container) || document.body);\n }\n }, [container, disablePortal]);\n useEnhancedEffect(() => {\n if (mountNode && !disablePortal) {\n setRef(forwardedRef, mountNode);\n return () => {\n setRef(forwardedRef, null);\n };\n }\n return undefined;\n }, [forwardedRef, mountNode, disablePortal]);\n if (disablePortal) {\n if ( /*#__PURE__*/React.isValidElement(children)) {\n const newProps = {\n ref: handleRef\n };\n return /*#__PURE__*/React.cloneElement(children, newProps);\n }\n return /*#__PURE__*/_jsx(React.Fragment, {\n children: children\n });\n }\n return /*#__PURE__*/_jsx(React.Fragment, {\n children: mountNode ? /*#__PURE__*/ReactDOM.createPortal(children, mountNode) : mountNode\n });\n});\nprocess.env.NODE_ENV !== \"production\" ? Portal.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * The children to render into the `container`.\n */\n children: PropTypes.node,\n /**\n * An HTML element or function that returns one.\n * The `container` will have the portal children appended to it.\n *\n * You can also provide a callback, which is called in a React layout effect.\n * This lets you set the container from a ref, and also makes server-side rendering possible.\n *\n * By default, it uses the body of the top-level document object,\n * so it's simply `document.body` most of the time.\n */\n container: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.func]),\n /**\n * The `children` will be under the DOM hierarchy of the parent component.\n * @default false\n */\n disablePortal: PropTypes.bool\n} : void 0;\nif (process.env.NODE_ENV !== 'production') {\n // eslint-disable-next-line\n Portal['propTypes' + ''] = exactProp(Portal.propTypes);\n}\nexport { Portal };","export var top = 'top';\nexport var bottom = 'bottom';\nexport var right = 'right';\nexport var left = 'left';\nexport var auto = 'auto';\nexport var basePlacements = [top, bottom, right, left];\nexport var start = 'start';\nexport var end = 'end';\nexport var clippingParents = 'clippingParents';\nexport var viewport = 'viewport';\nexport var popper = 'popper';\nexport var reference = 'reference';\nexport var variationPlacements = /*#__PURE__*/basePlacements.reduce(function (acc, placement) {\n return acc.concat([placement + \"-\" + start, placement + \"-\" + end]);\n}, []);\nexport var placements = /*#__PURE__*/[].concat(basePlacements, [auto]).reduce(function (acc, placement) {\n return acc.concat([placement, placement + \"-\" + start, placement + \"-\" + end]);\n}, []); // modifiers that need to read the DOM\n\nexport var beforeRead = 'beforeRead';\nexport var read = 'read';\nexport var afterRead = 'afterRead'; // pure-logic modifiers\n\nexport var beforeMain = 'beforeMain';\nexport var main = 'main';\nexport var afterMain = 'afterMain'; // modifier with the purpose to write to the DOM (or write into a framework state)\n\nexport var beforeWrite = 'beforeWrite';\nexport var write = 'write';\nexport var afterWrite = 'afterWrite';\nexport var modifierPhases = [beforeRead, read, afterRead, beforeMain, main, afterMain, beforeWrite, write, afterWrite];","export default function getNodeName(element) {\n return element ? (element.nodeName || '').toLowerCase() : null;\n}","export default function getWindow(node) {\n if (node == null) {\n return window;\n }\n\n if (node.toString() !== '[object Window]') {\n var ownerDocument = node.ownerDocument;\n return ownerDocument ? ownerDocument.defaultView || window : window;\n }\n\n return node;\n}","import getWindow from \"./getWindow.js\";\n\nfunction isElement(node) {\n var OwnElement = getWindow(node).Element;\n return node instanceof OwnElement || node instanceof Element;\n}\n\nfunction isHTMLElement(node) {\n var OwnElement = getWindow(node).HTMLElement;\n return node instanceof OwnElement || node instanceof HTMLElement;\n}\n\nfunction isShadowRoot(node) {\n // IE 11 has no ShadowRoot\n if (typeof ShadowRoot === 'undefined') {\n return false;\n }\n\n var OwnElement = getWindow(node).ShadowRoot;\n return node instanceof OwnElement || node instanceof ShadowRoot;\n}\n\nexport { isElement, isHTMLElement, isShadowRoot };","import getNodeName from \"../dom-utils/getNodeName.js\";\nimport { isHTMLElement } from \"../dom-utils/instanceOf.js\"; // This modifier takes the styles prepared by the `computeStyles` modifier\n// and applies them to the HTMLElements such as popper and arrow\n\nfunction applyStyles(_ref) {\n var state = _ref.state;\n Object.keys(state.elements).forEach(function (name) {\n var style = state.styles[name] || {};\n var attributes = state.attributes[name] || {};\n var element = state.elements[name]; // arrow is optional + virtual elements\n\n if (!isHTMLElement(element) || !getNodeName(element)) {\n return;\n } // Flow doesn't support to extend this property, but it's the most\n // effective way to apply styles to an HTMLElement\n // $FlowFixMe[cannot-write]\n\n\n Object.assign(element.style, style);\n Object.keys(attributes).forEach(function (name) {\n var value = attributes[name];\n\n if (value === false) {\n element.removeAttribute(name);\n } else {\n element.setAttribute(name, value === true ? '' : value);\n }\n });\n });\n}\n\nfunction effect(_ref2) {\n var state = _ref2.state;\n var initialStyles = {\n popper: {\n position: state.options.strategy,\n left: '0',\n top: '0',\n margin: '0'\n },\n arrow: {\n position: 'absolute'\n },\n reference: {}\n };\n Object.assign(state.elements.popper.style, initialStyles.popper);\n state.styles = initialStyles;\n\n if (state.elements.arrow) {\n Object.assign(state.elements.arrow.style, initialStyles.arrow);\n }\n\n return function () {\n Object.keys(state.elements).forEach(function (name) {\n var element = state.elements[name];\n var attributes = state.attributes[name] || {};\n var styleProperties = Object.keys(state.styles.hasOwnProperty(name) ? state.styles[name] : initialStyles[name]); // Set all values to an empty string to unset them\n\n var style = styleProperties.reduce(function (style, property) {\n style[property] = '';\n return style;\n }, {}); // arrow is optional + virtual elements\n\n if (!isHTMLElement(element) || !getNodeName(element)) {\n return;\n }\n\n Object.assign(element.style, style);\n Object.keys(attributes).forEach(function (attribute) {\n element.removeAttribute(attribute);\n });\n });\n };\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'applyStyles',\n enabled: true,\n phase: 'write',\n fn: applyStyles,\n effect: effect,\n requires: ['computeStyles']\n};","import { auto } from \"../enums.js\";\nexport default function getBasePlacement(placement) {\n return placement.split('-')[0];\n}","export var max = Math.max;\nexport var min = Math.min;\nexport var round = Math.round;","export default function getUAString() {\n var uaData = navigator.userAgentData;\n\n if (uaData != null && uaData.brands && Array.isArray(uaData.brands)) {\n return uaData.brands.map(function (item) {\n return item.brand + \"/\" + item.version;\n }).join(' ');\n }\n\n return navigator.userAgent;\n}","import getUAString from \"../utils/userAgent.js\";\nexport default function isLayoutViewport() {\n return !/^((?!chrome|android).)*safari/i.test(getUAString());\n}","import { isElement, isHTMLElement } from \"./instanceOf.js\";\nimport { round } from \"../utils/math.js\";\nimport getWindow from \"./getWindow.js\";\nimport isLayoutViewport from \"./isLayoutViewport.js\";\nexport default function getBoundingClientRect(element, includeScale, isFixedStrategy) {\n if (includeScale === void 0) {\n includeScale = false;\n }\n\n if (isFixedStrategy === void 0) {\n isFixedStrategy = false;\n }\n\n var clientRect = element.getBoundingClientRect();\n var scaleX = 1;\n var scaleY = 1;\n\n if (includeScale && isHTMLElement(element)) {\n scaleX = element.offsetWidth > 0 ? round(clientRect.width) / element.offsetWidth || 1 : 1;\n scaleY = element.offsetHeight > 0 ? round(clientRect.height) / element.offsetHeight || 1 : 1;\n }\n\n var _ref = isElement(element) ? getWindow(element) : window,\n visualViewport = _ref.visualViewport;\n\n var addVisualOffsets = !isLayoutViewport() && isFixedStrategy;\n var x = (clientRect.left + (addVisualOffsets && visualViewport ? visualViewport.offsetLeft : 0)) / scaleX;\n var y = (clientRect.top + (addVisualOffsets && visualViewport ? visualViewport.offsetTop : 0)) / scaleY;\n var width = clientRect.width / scaleX;\n var height = clientRect.height / scaleY;\n return {\n width: width,\n height: height,\n top: y,\n right: x + width,\n bottom: y + height,\n left: x,\n x: x,\n y: y\n };\n}","import getBoundingClientRect from \"./getBoundingClientRect.js\"; // Returns the layout rect of an element relative to its offsetParent. Layout\n// means it doesn't take into account transforms.\n\nexport default function getLayoutRect(element) {\n var clientRect = getBoundingClientRect(element); // Use the clientRect sizes if it's not been transformed.\n // Fixes https://github.com/popperjs/popper-core/issues/1223\n\n var width = element.offsetWidth;\n var height = element.offsetHeight;\n\n if (Math.abs(clientRect.width - width) <= 1) {\n width = clientRect.width;\n }\n\n if (Math.abs(clientRect.height - height) <= 1) {\n height = clientRect.height;\n }\n\n return {\n x: element.offsetLeft,\n y: element.offsetTop,\n width: width,\n height: height\n };\n}","import { isShadowRoot } from \"./instanceOf.js\";\nexport default function contains(parent, child) {\n var rootNode = child.getRootNode && child.getRootNode(); // First, attempt with faster native method\n\n if (parent.contains(child)) {\n return true;\n } // then fallback to custom implementation with Shadow DOM support\n else if (rootNode && isShadowRoot(rootNode)) {\n var next = child;\n\n do {\n if (next && parent.isSameNode(next)) {\n return true;\n } // $FlowFixMe[prop-missing]: need a better way to handle this...\n\n\n next = next.parentNode || next.host;\n } while (next);\n } // Give up, the result is false\n\n\n return false;\n}","import getWindow from \"./getWindow.js\";\nexport default function getComputedStyle(element) {\n return getWindow(element).getComputedStyle(element);\n}","import getNodeName from \"./getNodeName.js\";\nexport default function isTableElement(element) {\n return ['table', 'td', 'th'].indexOf(getNodeName(element)) >= 0;\n}","import { isElement } from \"./instanceOf.js\";\nexport default function getDocumentElement(element) {\n // $FlowFixMe[incompatible-return]: assume body is always available\n return ((isElement(element) ? element.ownerDocument : // $FlowFixMe[prop-missing]\n element.document) || window.document).documentElement;\n}","import getNodeName from \"./getNodeName.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport { isShadowRoot } from \"./instanceOf.js\";\nexport default function getParentNode(element) {\n if (getNodeName(element) === 'html') {\n return element;\n }\n\n return (// this is a quicker (but less type safe) way to save quite some bytes from the bundle\n // $FlowFixMe[incompatible-return]\n // $FlowFixMe[prop-missing]\n element.assignedSlot || // step into the shadow DOM of the parent of a slotted node\n element.parentNode || ( // DOM Element detected\n isShadowRoot(element) ? element.host : null) || // ShadowRoot detected\n // $FlowFixMe[incompatible-call]: HTMLElement is a Node\n getDocumentElement(element) // fallback\n\n );\n}","import getWindow from \"./getWindow.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport getComputedStyle from \"./getComputedStyle.js\";\nimport { isHTMLElement, isShadowRoot } from \"./instanceOf.js\";\nimport isTableElement from \"./isTableElement.js\";\nimport getParentNode from \"./getParentNode.js\";\nimport getUAString from \"../utils/userAgent.js\";\n\nfunction getTrueOffsetParent(element) {\n if (!isHTMLElement(element) || // https://github.com/popperjs/popper-core/issues/837\n getComputedStyle(element).position === 'fixed') {\n return null;\n }\n\n return element.offsetParent;\n} // `.offsetParent` reports `null` for fixed elements, while absolute elements\n// return the containing block\n\n\nfunction getContainingBlock(element) {\n var isFirefox = /firefox/i.test(getUAString());\n var isIE = /Trident/i.test(getUAString());\n\n if (isIE && isHTMLElement(element)) {\n // In IE 9, 10 and 11 fixed elements containing block is always established by the viewport\n var elementCss = getComputedStyle(element);\n\n if (elementCss.position === 'fixed') {\n return null;\n }\n }\n\n var currentNode = getParentNode(element);\n\n if (isShadowRoot(currentNode)) {\n currentNode = currentNode.host;\n }\n\n while (isHTMLElement(currentNode) && ['html', 'body'].indexOf(getNodeName(currentNode)) < 0) {\n var css = getComputedStyle(currentNode); // This is non-exhaustive but covers the most common CSS properties that\n // create a containing block.\n // https://developer.mozilla.org/en-US/docs/Web/CSS/Containing_block#identifying_the_containing_block\n\n if (css.transform !== 'none' || css.perspective !== 'none' || css.contain === 'paint' || ['transform', 'perspective'].indexOf(css.willChange) !== -1 || isFirefox && css.willChange === 'filter' || isFirefox && css.filter && css.filter !== 'none') {\n return currentNode;\n } else {\n currentNode = currentNode.parentNode;\n }\n }\n\n return null;\n} // Gets the closest ancestor positioned element. Handles some edge cases,\n// such as table ancestors and cross browser bugs.\n\n\nexport default function getOffsetParent(element) {\n var window = getWindow(element);\n var offsetParent = getTrueOffsetParent(element);\n\n while (offsetParent && isTableElement(offsetParent) && getComputedStyle(offsetParent).position === 'static') {\n offsetParent = getTrueOffsetParent(offsetParent);\n }\n\n if (offsetParent && (getNodeName(offsetParent) === 'html' || getNodeName(offsetParent) === 'body' && getComputedStyle(offsetParent).position === 'static')) {\n return window;\n }\n\n return offsetParent || getContainingBlock(element) || window;\n}","export default function getMainAxisFromPlacement(placement) {\n return ['top', 'bottom'].indexOf(placement) >= 0 ? 'x' : 'y';\n}","import { max as mathMax, min as mathMin } from \"./math.js\";\nexport function within(min, value, max) {\n return mathMax(min, mathMin(value, max));\n}\nexport function withinMaxClamp(min, value, max) {\n var v = within(min, value, max);\n return v > max ? max : v;\n}","export default function getFreshSideObject() {\n return {\n top: 0,\n right: 0,\n bottom: 0,\n left: 0\n };\n}","import getFreshSideObject from \"./getFreshSideObject.js\";\nexport default function mergePaddingObject(paddingObject) {\n return Object.assign({}, getFreshSideObject(), paddingObject);\n}","export default function expandToHashMap(value, keys) {\n return keys.reduce(function (hashMap, key) {\n hashMap[key] = value;\n return hashMap;\n }, {});\n}","import getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getLayoutRect from \"../dom-utils/getLayoutRect.js\";\nimport contains from \"../dom-utils/contains.js\";\nimport getOffsetParent from \"../dom-utils/getOffsetParent.js\";\nimport getMainAxisFromPlacement from \"../utils/getMainAxisFromPlacement.js\";\nimport { within } from \"../utils/within.js\";\nimport mergePaddingObject from \"../utils/mergePaddingObject.js\";\nimport expandToHashMap from \"../utils/expandToHashMap.js\";\nimport { left, right, basePlacements, top, bottom } from \"../enums.js\"; // eslint-disable-next-line import/no-unused-modules\n\nvar toPaddingObject = function toPaddingObject(padding, state) {\n padding = typeof padding === 'function' ? padding(Object.assign({}, state.rects, {\n placement: state.placement\n })) : padding;\n return mergePaddingObject(typeof padding !== 'number' ? padding : expandToHashMap(padding, basePlacements));\n};\n\nfunction arrow(_ref) {\n var _state$modifiersData$;\n\n var state = _ref.state,\n name = _ref.name,\n options = _ref.options;\n var arrowElement = state.elements.arrow;\n var popperOffsets = state.modifiersData.popperOffsets;\n var basePlacement = getBasePlacement(state.placement);\n var axis = getMainAxisFromPlacement(basePlacement);\n var isVertical = [left, right].indexOf(basePlacement) >= 0;\n var len = isVertical ? 'height' : 'width';\n\n if (!arrowElement || !popperOffsets) {\n return;\n }\n\n var paddingObject = toPaddingObject(options.padding, state);\n var arrowRect = getLayoutRect(arrowElement);\n var minProp = axis === 'y' ? top : left;\n var maxProp = axis === 'y' ? bottom : right;\n var endDiff = state.rects.reference[len] + state.rects.reference[axis] - popperOffsets[axis] - state.rects.popper[len];\n var startDiff = popperOffsets[axis] - state.rects.reference[axis];\n var arrowOffsetParent = getOffsetParent(arrowElement);\n var clientSize = arrowOffsetParent ? axis === 'y' ? arrowOffsetParent.clientHeight || 0 : arrowOffsetParent.clientWidth || 0 : 0;\n var centerToReference = endDiff / 2 - startDiff / 2; // Make sure the arrow doesn't overflow the popper if the center point is\n // outside of the popper bounds\n\n var min = paddingObject[minProp];\n var max = clientSize - arrowRect[len] - paddingObject[maxProp];\n var center = clientSize / 2 - arrowRect[len] / 2 + centerToReference;\n var offset = within(min, center, max); // Prevents breaking syntax highlighting...\n\n var axisProp = axis;\n state.modifiersData[name] = (_state$modifiersData$ = {}, _state$modifiersData$[axisProp] = offset, _state$modifiersData$.centerOffset = offset - center, _state$modifiersData$);\n}\n\nfunction effect(_ref2) {\n var state = _ref2.state,\n options = _ref2.options;\n var _options$element = options.element,\n arrowElement = _options$element === void 0 ? '[data-popper-arrow]' : _options$element;\n\n if (arrowElement == null) {\n return;\n } // CSS selector\n\n\n if (typeof arrowElement === 'string') {\n arrowElement = state.elements.popper.querySelector(arrowElement);\n\n if (!arrowElement) {\n return;\n }\n }\n\n if (!contains(state.elements.popper, arrowElement)) {\n return;\n }\n\n state.elements.arrow = arrowElement;\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'arrow',\n enabled: true,\n phase: 'main',\n fn: arrow,\n effect: effect,\n requires: ['popperOffsets'],\n requiresIfExists: ['preventOverflow']\n};","export default function getVariation(placement) {\n return placement.split('-')[1];\n}","import { top, left, right, bottom, end } from \"../enums.js\";\nimport getOffsetParent from \"../dom-utils/getOffsetParent.js\";\nimport getWindow from \"../dom-utils/getWindow.js\";\nimport getDocumentElement from \"../dom-utils/getDocumentElement.js\";\nimport getComputedStyle from \"../dom-utils/getComputedStyle.js\";\nimport getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getVariation from \"../utils/getVariation.js\";\nimport { round } from \"../utils/math.js\"; // eslint-disable-next-line import/no-unused-modules\n\nvar unsetSides = {\n top: 'auto',\n right: 'auto',\n bottom: 'auto',\n left: 'auto'\n}; // Round the offsets to the nearest suitable subpixel based on the DPR.\n// Zooming can change the DPR, but it seems to report a value that will\n// cleanly divide the values into the appropriate subpixels.\n\nfunction roundOffsetsByDPR(_ref, win) {\n var x = _ref.x,\n y = _ref.y;\n var dpr = win.devicePixelRatio || 1;\n return {\n x: round(x * dpr) / dpr || 0,\n y: round(y * dpr) / dpr || 0\n };\n}\n\nexport function mapToStyles(_ref2) {\n var _Object$assign2;\n\n var popper = _ref2.popper,\n popperRect = _ref2.popperRect,\n placement = _ref2.placement,\n variation = _ref2.variation,\n offsets = _ref2.offsets,\n position = _ref2.position,\n gpuAcceleration = _ref2.gpuAcceleration,\n adaptive = _ref2.adaptive,\n roundOffsets = _ref2.roundOffsets,\n isFixed = _ref2.isFixed;\n var _offsets$x = offsets.x,\n x = _offsets$x === void 0 ? 0 : _offsets$x,\n _offsets$y = offsets.y,\n y = _offsets$y === void 0 ? 0 : _offsets$y;\n\n var _ref3 = typeof roundOffsets === 'function' ? roundOffsets({\n x: x,\n y: y\n }) : {\n x: x,\n y: y\n };\n\n x = _ref3.x;\n y = _ref3.y;\n var hasX = offsets.hasOwnProperty('x');\n var hasY = offsets.hasOwnProperty('y');\n var sideX = left;\n var sideY = top;\n var win = window;\n\n if (adaptive) {\n var offsetParent = getOffsetParent(popper);\n var heightProp = 'clientHeight';\n var widthProp = 'clientWidth';\n\n if (offsetParent === getWindow(popper)) {\n offsetParent = getDocumentElement(popper);\n\n if (getComputedStyle(offsetParent).position !== 'static' && position === 'absolute') {\n heightProp = 'scrollHeight';\n widthProp = 'scrollWidth';\n }\n } // $FlowFixMe[incompatible-cast]: force type refinement, we compare offsetParent with window above, but Flow doesn't detect it\n\n\n offsetParent = offsetParent;\n\n if (placement === top || (placement === left || placement === right) && variation === end) {\n sideY = bottom;\n var offsetY = isFixed && offsetParent === win && win.visualViewport ? win.visualViewport.height : // $FlowFixMe[prop-missing]\n offsetParent[heightProp];\n y -= offsetY - popperRect.height;\n y *= gpuAcceleration ? 1 : -1;\n }\n\n if (placement === left || (placement === top || placement === bottom) && variation === end) {\n sideX = right;\n var offsetX = isFixed && offsetParent === win && win.visualViewport ? win.visualViewport.width : // $FlowFixMe[prop-missing]\n offsetParent[widthProp];\n x -= offsetX - popperRect.width;\n x *= gpuAcceleration ? 1 : -1;\n }\n }\n\n var commonStyles = Object.assign({\n position: position\n }, adaptive && unsetSides);\n\n var _ref4 = roundOffsets === true ? roundOffsetsByDPR({\n x: x,\n y: y\n }, getWindow(popper)) : {\n x: x,\n y: y\n };\n\n x = _ref4.x;\n y = _ref4.y;\n\n if (gpuAcceleration) {\n var _Object$assign;\n\n return Object.assign({}, commonStyles, (_Object$assign = {}, _Object$assign[sideY] = hasY ? '0' : '', _Object$assign[sideX] = hasX ? '0' : '', _Object$assign.transform = (win.devicePixelRatio || 1) <= 1 ? \"translate(\" + x + \"px, \" + y + \"px)\" : \"translate3d(\" + x + \"px, \" + y + \"px, 0)\", _Object$assign));\n }\n\n return Object.assign({}, commonStyles, (_Object$assign2 = {}, _Object$assign2[sideY] = hasY ? y + \"px\" : '', _Object$assign2[sideX] = hasX ? x + \"px\" : '', _Object$assign2.transform = '', _Object$assign2));\n}\n\nfunction computeStyles(_ref5) {\n var state = _ref5.state,\n options = _ref5.options;\n var _options$gpuAccelerat = options.gpuAcceleration,\n gpuAcceleration = _options$gpuAccelerat === void 0 ? true : _options$gpuAccelerat,\n _options$adaptive = options.adaptive,\n adaptive = _options$adaptive === void 0 ? true : _options$adaptive,\n _options$roundOffsets = options.roundOffsets,\n roundOffsets = _options$roundOffsets === void 0 ? true : _options$roundOffsets;\n var commonStyles = {\n placement: getBasePlacement(state.placement),\n variation: getVariation(state.placement),\n popper: state.elements.popper,\n popperRect: state.rects.popper,\n gpuAcceleration: gpuAcceleration,\n isFixed: state.options.strategy === 'fixed'\n };\n\n if (state.modifiersData.popperOffsets != null) {\n state.styles.popper = Object.assign({}, state.styles.popper, mapToStyles(Object.assign({}, commonStyles, {\n offsets: state.modifiersData.popperOffsets,\n position: state.options.strategy,\n adaptive: adaptive,\n roundOffsets: roundOffsets\n })));\n }\n\n if (state.modifiersData.arrow != null) {\n state.styles.arrow = Object.assign({}, state.styles.arrow, mapToStyles(Object.assign({}, commonStyles, {\n offsets: state.modifiersData.arrow,\n position: 'absolute',\n adaptive: false,\n roundOffsets: roundOffsets\n })));\n }\n\n state.attributes.popper = Object.assign({}, state.attributes.popper, {\n 'data-popper-placement': state.placement\n });\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'computeStyles',\n enabled: true,\n phase: 'beforeWrite',\n fn: computeStyles,\n data: {}\n};","import getWindow from \"../dom-utils/getWindow.js\"; // eslint-disable-next-line import/no-unused-modules\n\nvar passive = {\n passive: true\n};\n\nfunction effect(_ref) {\n var state = _ref.state,\n instance = _ref.instance,\n options = _ref.options;\n var _options$scroll = options.scroll,\n scroll = _options$scroll === void 0 ? true : _options$scroll,\n _options$resize = options.resize,\n resize = _options$resize === void 0 ? true : _options$resize;\n var window = getWindow(state.elements.popper);\n var scrollParents = [].concat(state.scrollParents.reference, state.scrollParents.popper);\n\n if (scroll) {\n scrollParents.forEach(function (scrollParent) {\n scrollParent.addEventListener('scroll', instance.update, passive);\n });\n }\n\n if (resize) {\n window.addEventListener('resize', instance.update, passive);\n }\n\n return function () {\n if (scroll) {\n scrollParents.forEach(function (scrollParent) {\n scrollParent.removeEventListener('scroll', instance.update, passive);\n });\n }\n\n if (resize) {\n window.removeEventListener('resize', instance.update, passive);\n }\n };\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'eventListeners',\n enabled: true,\n phase: 'write',\n fn: function fn() {},\n effect: effect,\n data: {}\n};","var hash = {\n left: 'right',\n right: 'left',\n bottom: 'top',\n top: 'bottom'\n};\nexport default function getOppositePlacement(placement) {\n return placement.replace(/left|right|bottom|top/g, function (matched) {\n return hash[matched];\n });\n}","var hash = {\n start: 'end',\n end: 'start'\n};\nexport default function getOppositeVariationPlacement(placement) {\n return placement.replace(/start|end/g, function (matched) {\n return hash[matched];\n });\n}","import getWindow from \"./getWindow.js\";\nexport default function getWindowScroll(node) {\n var win = getWindow(node);\n var scrollLeft = win.pageXOffset;\n var scrollTop = win.pageYOffset;\n return {\n scrollLeft: scrollLeft,\n scrollTop: scrollTop\n };\n}","import getBoundingClientRect from \"./getBoundingClientRect.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport getWindowScroll from \"./getWindowScroll.js\";\nexport default function getWindowScrollBarX(element) {\n // If has a CSS width greater than the viewport, then this will be\n // incorrect for RTL.\n // Popper 1 is broken in this case and never had a bug report so let's assume\n // it's not an issue. I don't think anyone ever specifies width on \n // anyway.\n // Browsers where the left scrollbar doesn't cause an issue report `0` for\n // this (e.g. Edge 2019, IE11, Safari)\n return getBoundingClientRect(getDocumentElement(element)).left + getWindowScroll(element).scrollLeft;\n}","import getWindow from \"./getWindow.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport getWindowScrollBarX from \"./getWindowScrollBarX.js\";\nimport isLayoutViewport from \"./isLayoutViewport.js\";\nexport default function getViewportRect(element, strategy) {\n var win = getWindow(element);\n var html = getDocumentElement(element);\n var visualViewport = win.visualViewport;\n var width = html.clientWidth;\n var height = html.clientHeight;\n var x = 0;\n var y = 0;\n\n if (visualViewport) {\n width = visualViewport.width;\n height = visualViewport.height;\n var layoutViewport = isLayoutViewport();\n\n if (layoutViewport || !layoutViewport && strategy === 'fixed') {\n x = visualViewport.offsetLeft;\n y = visualViewport.offsetTop;\n }\n }\n\n return {\n width: width,\n height: height,\n x: x + getWindowScrollBarX(element),\n y: y\n };\n}","import getDocumentElement from \"./getDocumentElement.js\";\nimport getComputedStyle from \"./getComputedStyle.js\";\nimport getWindowScrollBarX from \"./getWindowScrollBarX.js\";\nimport getWindowScroll from \"./getWindowScroll.js\";\nimport { max } from \"../utils/math.js\"; // Gets the entire size of the scrollable document area, even extending outside\n// of the `` and `` rect bounds if horizontally scrollable\n\nexport default function getDocumentRect(element) {\n var _element$ownerDocumen;\n\n var html = getDocumentElement(element);\n var winScroll = getWindowScroll(element);\n var body = (_element$ownerDocumen = element.ownerDocument) == null ? void 0 : _element$ownerDocumen.body;\n var width = max(html.scrollWidth, html.clientWidth, body ? body.scrollWidth : 0, body ? body.clientWidth : 0);\n var height = max(html.scrollHeight, html.clientHeight, body ? body.scrollHeight : 0, body ? body.clientHeight : 0);\n var x = -winScroll.scrollLeft + getWindowScrollBarX(element);\n var y = -winScroll.scrollTop;\n\n if (getComputedStyle(body || html).direction === 'rtl') {\n x += max(html.clientWidth, body ? body.clientWidth : 0) - width;\n }\n\n return {\n width: width,\n height: height,\n x: x,\n y: y\n };\n}","import getComputedStyle from \"./getComputedStyle.js\";\nexport default function isScrollParent(element) {\n // Firefox wants us to check `-x` and `-y` variations as well\n var _getComputedStyle = getComputedStyle(element),\n overflow = _getComputedStyle.overflow,\n overflowX = _getComputedStyle.overflowX,\n overflowY = _getComputedStyle.overflowY;\n\n return /auto|scroll|overlay|hidden/.test(overflow + overflowY + overflowX);\n}","import getParentNode from \"./getParentNode.js\";\nimport isScrollParent from \"./isScrollParent.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport { isHTMLElement } from \"./instanceOf.js\";\nexport default function getScrollParent(node) {\n if (['html', 'body', '#document'].indexOf(getNodeName(node)) >= 0) {\n // $FlowFixMe[incompatible-return]: assume body is always available\n return node.ownerDocument.body;\n }\n\n if (isHTMLElement(node) && isScrollParent(node)) {\n return node;\n }\n\n return getScrollParent(getParentNode(node));\n}","import getScrollParent from \"./getScrollParent.js\";\nimport getParentNode from \"./getParentNode.js\";\nimport getWindow from \"./getWindow.js\";\nimport isScrollParent from \"./isScrollParent.js\";\n/*\ngiven a DOM element, return the list of all scroll parents, up the list of ancesors\nuntil we get to the top window object. This list is what we attach scroll listeners\nto, because if any of these parent elements scroll, we'll need to re-calculate the\nreference element's position.\n*/\n\nexport default function listScrollParents(element, list) {\n var _element$ownerDocumen;\n\n if (list === void 0) {\n list = [];\n }\n\n var scrollParent = getScrollParent(element);\n var isBody = scrollParent === ((_element$ownerDocumen = element.ownerDocument) == null ? void 0 : _element$ownerDocumen.body);\n var win = getWindow(scrollParent);\n var target = isBody ? [win].concat(win.visualViewport || [], isScrollParent(scrollParent) ? scrollParent : []) : scrollParent;\n var updatedList = list.concat(target);\n return isBody ? updatedList : // $FlowFixMe[incompatible-call]: isBody tells us target will be an HTMLElement here\n updatedList.concat(listScrollParents(getParentNode(target)));\n}","export default function rectToClientRect(rect) {\n return Object.assign({}, rect, {\n left: rect.x,\n top: rect.y,\n right: rect.x + rect.width,\n bottom: rect.y + rect.height\n });\n}","import { viewport } from \"../enums.js\";\nimport getViewportRect from \"./getViewportRect.js\";\nimport getDocumentRect from \"./getDocumentRect.js\";\nimport listScrollParents from \"./listScrollParents.js\";\nimport getOffsetParent from \"./getOffsetParent.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport getComputedStyle from \"./getComputedStyle.js\";\nimport { isElement, isHTMLElement } from \"./instanceOf.js\";\nimport getBoundingClientRect from \"./getBoundingClientRect.js\";\nimport getParentNode from \"./getParentNode.js\";\nimport contains from \"./contains.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport rectToClientRect from \"../utils/rectToClientRect.js\";\nimport { max, min } from \"../utils/math.js\";\n\nfunction getInnerBoundingClientRect(element, strategy) {\n var rect = getBoundingClientRect(element, false, strategy === 'fixed');\n rect.top = rect.top + element.clientTop;\n rect.left = rect.left + element.clientLeft;\n rect.bottom = rect.top + element.clientHeight;\n rect.right = rect.left + element.clientWidth;\n rect.width = element.clientWidth;\n rect.height = element.clientHeight;\n rect.x = rect.left;\n rect.y = rect.top;\n return rect;\n}\n\nfunction getClientRectFromMixedType(element, clippingParent, strategy) {\n return clippingParent === viewport ? rectToClientRect(getViewportRect(element, strategy)) : isElement(clippingParent) ? getInnerBoundingClientRect(clippingParent, strategy) : rectToClientRect(getDocumentRect(getDocumentElement(element)));\n} // A \"clipping parent\" is an overflowable container with the characteristic of\n// clipping (or hiding) overflowing elements with a position different from\n// `initial`\n\n\nfunction getClippingParents(element) {\n var clippingParents = listScrollParents(getParentNode(element));\n var canEscapeClipping = ['absolute', 'fixed'].indexOf(getComputedStyle(element).position) >= 0;\n var clipperElement = canEscapeClipping && isHTMLElement(element) ? getOffsetParent(element) : element;\n\n if (!isElement(clipperElement)) {\n return [];\n } // $FlowFixMe[incompatible-return]: https://github.com/facebook/flow/issues/1414\n\n\n return clippingParents.filter(function (clippingParent) {\n return isElement(clippingParent) && contains(clippingParent, clipperElement) && getNodeName(clippingParent) !== 'body';\n });\n} // Gets the maximum area that the element is visible in due to any number of\n// clipping parents\n\n\nexport default function getClippingRect(element, boundary, rootBoundary, strategy) {\n var mainClippingParents = boundary === 'clippingParents' ? getClippingParents(element) : [].concat(boundary);\n var clippingParents = [].concat(mainClippingParents, [rootBoundary]);\n var firstClippingParent = clippingParents[0];\n var clippingRect = clippingParents.reduce(function (accRect, clippingParent) {\n var rect = getClientRectFromMixedType(element, clippingParent, strategy);\n accRect.top = max(rect.top, accRect.top);\n accRect.right = min(rect.right, accRect.right);\n accRect.bottom = min(rect.bottom, accRect.bottom);\n accRect.left = max(rect.left, accRect.left);\n return accRect;\n }, getClientRectFromMixedType(element, firstClippingParent, strategy));\n clippingRect.width = clippingRect.right - clippingRect.left;\n clippingRect.height = clippingRect.bottom - clippingRect.top;\n clippingRect.x = clippingRect.left;\n clippingRect.y = clippingRect.top;\n return clippingRect;\n}","import getBasePlacement from \"./getBasePlacement.js\";\nimport getVariation from \"./getVariation.js\";\nimport getMainAxisFromPlacement from \"./getMainAxisFromPlacement.js\";\nimport { top, right, bottom, left, start, end } from \"../enums.js\";\nexport default function computeOffsets(_ref) {\n var reference = _ref.reference,\n element = _ref.element,\n placement = _ref.placement;\n var basePlacement = placement ? getBasePlacement(placement) : null;\n var variation = placement ? getVariation(placement) : null;\n var commonX = reference.x + reference.width / 2 - element.width / 2;\n var commonY = reference.y + reference.height / 2 - element.height / 2;\n var offsets;\n\n switch (basePlacement) {\n case top:\n offsets = {\n x: commonX,\n y: reference.y - element.height\n };\n break;\n\n case bottom:\n offsets = {\n x: commonX,\n y: reference.y + reference.height\n };\n break;\n\n case right:\n offsets = {\n x: reference.x + reference.width,\n y: commonY\n };\n break;\n\n case left:\n offsets = {\n x: reference.x - element.width,\n y: commonY\n };\n break;\n\n default:\n offsets = {\n x: reference.x,\n y: reference.y\n };\n }\n\n var mainAxis = basePlacement ? getMainAxisFromPlacement(basePlacement) : null;\n\n if (mainAxis != null) {\n var len = mainAxis === 'y' ? 'height' : 'width';\n\n switch (variation) {\n case start:\n offsets[mainAxis] = offsets[mainAxis] - (reference[len] / 2 - element[len] / 2);\n break;\n\n case end:\n offsets[mainAxis] = offsets[mainAxis] + (reference[len] / 2 - element[len] / 2);\n break;\n\n default:\n }\n }\n\n return offsets;\n}","import getClippingRect from \"../dom-utils/getClippingRect.js\";\nimport getDocumentElement from \"../dom-utils/getDocumentElement.js\";\nimport getBoundingClientRect from \"../dom-utils/getBoundingClientRect.js\";\nimport computeOffsets from \"./computeOffsets.js\";\nimport rectToClientRect from \"./rectToClientRect.js\";\nimport { clippingParents, reference, popper, bottom, top, right, basePlacements, viewport } from \"../enums.js\";\nimport { isElement } from \"../dom-utils/instanceOf.js\";\nimport mergePaddingObject from \"./mergePaddingObject.js\";\nimport expandToHashMap from \"./expandToHashMap.js\"; // eslint-disable-next-line import/no-unused-modules\n\nexport default function detectOverflow(state, options) {\n if (options === void 0) {\n options = {};\n }\n\n var _options = options,\n _options$placement = _options.placement,\n placement = _options$placement === void 0 ? state.placement : _options$placement,\n _options$strategy = _options.strategy,\n strategy = _options$strategy === void 0 ? state.strategy : _options$strategy,\n _options$boundary = _options.boundary,\n boundary = _options$boundary === void 0 ? clippingParents : _options$boundary,\n _options$rootBoundary = _options.rootBoundary,\n rootBoundary = _options$rootBoundary === void 0 ? viewport : _options$rootBoundary,\n _options$elementConte = _options.elementContext,\n elementContext = _options$elementConte === void 0 ? popper : _options$elementConte,\n _options$altBoundary = _options.altBoundary,\n altBoundary = _options$altBoundary === void 0 ? false : _options$altBoundary,\n _options$padding = _options.padding,\n padding = _options$padding === void 0 ? 0 : _options$padding;\n var paddingObject = mergePaddingObject(typeof padding !== 'number' ? padding : expandToHashMap(padding, basePlacements));\n var altContext = elementContext === popper ? reference : popper;\n var popperRect = state.rects.popper;\n var element = state.elements[altBoundary ? altContext : elementContext];\n var clippingClientRect = getClippingRect(isElement(element) ? element : element.contextElement || getDocumentElement(state.elements.popper), boundary, rootBoundary, strategy);\n var referenceClientRect = getBoundingClientRect(state.elements.reference);\n var popperOffsets = computeOffsets({\n reference: referenceClientRect,\n element: popperRect,\n strategy: 'absolute',\n placement: placement\n });\n var popperClientRect = rectToClientRect(Object.assign({}, popperRect, popperOffsets));\n var elementClientRect = elementContext === popper ? popperClientRect : referenceClientRect; // positive = overflowing the clipping rect\n // 0 or negative = within the clipping rect\n\n var overflowOffsets = {\n top: clippingClientRect.top - elementClientRect.top + paddingObject.top,\n bottom: elementClientRect.bottom - clippingClientRect.bottom + paddingObject.bottom,\n left: clippingClientRect.left - elementClientRect.left + paddingObject.left,\n right: elementClientRect.right - clippingClientRect.right + paddingObject.right\n };\n var offsetData = state.modifiersData.offset; // Offsets can be applied only to the popper element\n\n if (elementContext === popper && offsetData) {\n var offset = offsetData[placement];\n Object.keys(overflowOffsets).forEach(function (key) {\n var multiply = [right, bottom].indexOf(key) >= 0 ? 1 : -1;\n var axis = [top, bottom].indexOf(key) >= 0 ? 'y' : 'x';\n overflowOffsets[key] += offset[axis] * multiply;\n });\n }\n\n return overflowOffsets;\n}","import getVariation from \"./getVariation.js\";\nimport { variationPlacements, basePlacements, placements as allPlacements } from \"../enums.js\";\nimport detectOverflow from \"./detectOverflow.js\";\nimport getBasePlacement from \"./getBasePlacement.js\";\nexport default function computeAutoPlacement(state, options) {\n if (options === void 0) {\n options = {};\n }\n\n var _options = options,\n placement = _options.placement,\n boundary = _options.boundary,\n rootBoundary = _options.rootBoundary,\n padding = _options.padding,\n flipVariations = _options.flipVariations,\n _options$allowedAutoP = _options.allowedAutoPlacements,\n allowedAutoPlacements = _options$allowedAutoP === void 0 ? allPlacements : _options$allowedAutoP;\n var variation = getVariation(placement);\n var placements = variation ? flipVariations ? variationPlacements : variationPlacements.filter(function (placement) {\n return getVariation(placement) === variation;\n }) : basePlacements;\n var allowedPlacements = placements.filter(function (placement) {\n return allowedAutoPlacements.indexOf(placement) >= 0;\n });\n\n if (allowedPlacements.length === 0) {\n allowedPlacements = placements;\n } // $FlowFixMe[incompatible-type]: Flow seems to have problems with two array unions...\n\n\n var overflows = allowedPlacements.reduce(function (acc, placement) {\n acc[placement] = detectOverflow(state, {\n placement: placement,\n boundary: boundary,\n rootBoundary: rootBoundary,\n padding: padding\n })[getBasePlacement(placement)];\n return acc;\n }, {});\n return Object.keys(overflows).sort(function (a, b) {\n return overflows[a] - overflows[b];\n });\n}","import getOppositePlacement from \"../utils/getOppositePlacement.js\";\nimport getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getOppositeVariationPlacement from \"../utils/getOppositeVariationPlacement.js\";\nimport detectOverflow from \"../utils/detectOverflow.js\";\nimport computeAutoPlacement from \"../utils/computeAutoPlacement.js\";\nimport { bottom, top, start, right, left, auto } from \"../enums.js\";\nimport getVariation from \"../utils/getVariation.js\"; // eslint-disable-next-line import/no-unused-modules\n\nfunction getExpandedFallbackPlacements(placement) {\n if (getBasePlacement(placement) === auto) {\n return [];\n }\n\n var oppositePlacement = getOppositePlacement(placement);\n return [getOppositeVariationPlacement(placement), oppositePlacement, getOppositeVariationPlacement(oppositePlacement)];\n}\n\nfunction flip(_ref) {\n var state = _ref.state,\n options = _ref.options,\n name = _ref.name;\n\n if (state.modifiersData[name]._skip) {\n return;\n }\n\n var _options$mainAxis = options.mainAxis,\n checkMainAxis = _options$mainAxis === void 0 ? true : _options$mainAxis,\n _options$altAxis = options.altAxis,\n checkAltAxis = _options$altAxis === void 0 ? true : _options$altAxis,\n specifiedFallbackPlacements = options.fallbackPlacements,\n padding = options.padding,\n boundary = options.boundary,\n rootBoundary = options.rootBoundary,\n altBoundary = options.altBoundary,\n _options$flipVariatio = options.flipVariations,\n flipVariations = _options$flipVariatio === void 0 ? true : _options$flipVariatio,\n allowedAutoPlacements = options.allowedAutoPlacements;\n var preferredPlacement = state.options.placement;\n var basePlacement = getBasePlacement(preferredPlacement);\n var isBasePlacement = basePlacement === preferredPlacement;\n var fallbackPlacements = specifiedFallbackPlacements || (isBasePlacement || !flipVariations ? [getOppositePlacement(preferredPlacement)] : getExpandedFallbackPlacements(preferredPlacement));\n var placements = [preferredPlacement].concat(fallbackPlacements).reduce(function (acc, placement) {\n return acc.concat(getBasePlacement(placement) === auto ? computeAutoPlacement(state, {\n placement: placement,\n boundary: boundary,\n rootBoundary: rootBoundary,\n padding: padding,\n flipVariations: flipVariations,\n allowedAutoPlacements: allowedAutoPlacements\n }) : placement);\n }, []);\n var referenceRect = state.rects.reference;\n var popperRect = state.rects.popper;\n var checksMap = new Map();\n var makeFallbackChecks = true;\n var firstFittingPlacement = placements[0];\n\n for (var i = 0; i < placements.length; i++) {\n var placement = placements[i];\n\n var _basePlacement = getBasePlacement(placement);\n\n var isStartVariation = getVariation(placement) === start;\n var isVertical = [top, bottom].indexOf(_basePlacement) >= 0;\n var len = isVertical ? 'width' : 'height';\n var overflow = detectOverflow(state, {\n placement: placement,\n boundary: boundary,\n rootBoundary: rootBoundary,\n altBoundary: altBoundary,\n padding: padding\n });\n var mainVariationSide = isVertical ? isStartVariation ? right : left : isStartVariation ? bottom : top;\n\n if (referenceRect[len] > popperRect[len]) {\n mainVariationSide = getOppositePlacement(mainVariationSide);\n }\n\n var altVariationSide = getOppositePlacement(mainVariationSide);\n var checks = [];\n\n if (checkMainAxis) {\n checks.push(overflow[_basePlacement] <= 0);\n }\n\n if (checkAltAxis) {\n checks.push(overflow[mainVariationSide] <= 0, overflow[altVariationSide] <= 0);\n }\n\n if (checks.every(function (check) {\n return check;\n })) {\n firstFittingPlacement = placement;\n makeFallbackChecks = false;\n break;\n }\n\n checksMap.set(placement, checks);\n }\n\n if (makeFallbackChecks) {\n // `2` may be desired in some cases – research later\n var numberOfChecks = flipVariations ? 3 : 1;\n\n var _loop = function _loop(_i) {\n var fittingPlacement = placements.find(function (placement) {\n var checks = checksMap.get(placement);\n\n if (checks) {\n return checks.slice(0, _i).every(function (check) {\n return check;\n });\n }\n });\n\n if (fittingPlacement) {\n firstFittingPlacement = fittingPlacement;\n return \"break\";\n }\n };\n\n for (var _i = numberOfChecks; _i > 0; _i--) {\n var _ret = _loop(_i);\n\n if (_ret === \"break\") break;\n }\n }\n\n if (state.placement !== firstFittingPlacement) {\n state.modifiersData[name]._skip = true;\n state.placement = firstFittingPlacement;\n state.reset = true;\n }\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'flip',\n enabled: true,\n phase: 'main',\n fn: flip,\n requiresIfExists: ['offset'],\n data: {\n _skip: false\n }\n};","import { top, bottom, left, right } from \"../enums.js\";\nimport detectOverflow from \"../utils/detectOverflow.js\";\n\nfunction getSideOffsets(overflow, rect, preventedOffsets) {\n if (preventedOffsets === void 0) {\n preventedOffsets = {\n x: 0,\n y: 0\n };\n }\n\n return {\n top: overflow.top - rect.height - preventedOffsets.y,\n right: overflow.right - rect.width + preventedOffsets.x,\n bottom: overflow.bottom - rect.height + preventedOffsets.y,\n left: overflow.left - rect.width - preventedOffsets.x\n };\n}\n\nfunction isAnySideFullyClipped(overflow) {\n return [top, right, bottom, left].some(function (side) {\n return overflow[side] >= 0;\n });\n}\n\nfunction hide(_ref) {\n var state = _ref.state,\n name = _ref.name;\n var referenceRect = state.rects.reference;\n var popperRect = state.rects.popper;\n var preventedOffsets = state.modifiersData.preventOverflow;\n var referenceOverflow = detectOverflow(state, {\n elementContext: 'reference'\n });\n var popperAltOverflow = detectOverflow(state, {\n altBoundary: true\n });\n var referenceClippingOffsets = getSideOffsets(referenceOverflow, referenceRect);\n var popperEscapeOffsets = getSideOffsets(popperAltOverflow, popperRect, preventedOffsets);\n var isReferenceHidden = isAnySideFullyClipped(referenceClippingOffsets);\n var hasPopperEscaped = isAnySideFullyClipped(popperEscapeOffsets);\n state.modifiersData[name] = {\n referenceClippingOffsets: referenceClippingOffsets,\n popperEscapeOffsets: popperEscapeOffsets,\n isReferenceHidden: isReferenceHidden,\n hasPopperEscaped: hasPopperEscaped\n };\n state.attributes.popper = Object.assign({}, state.attributes.popper, {\n 'data-popper-reference-hidden': isReferenceHidden,\n 'data-popper-escaped': hasPopperEscaped\n });\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'hide',\n enabled: true,\n phase: 'main',\n requiresIfExists: ['preventOverflow'],\n fn: hide\n};","import getBasePlacement from \"../utils/getBasePlacement.js\";\nimport { top, left, right, placements } from \"../enums.js\"; // eslint-disable-next-line import/no-unused-modules\n\nexport function distanceAndSkiddingToXY(placement, rects, offset) {\n var basePlacement = getBasePlacement(placement);\n var invertDistance = [left, top].indexOf(basePlacement) >= 0 ? -1 : 1;\n\n var _ref = typeof offset === 'function' ? offset(Object.assign({}, rects, {\n placement: placement\n })) : offset,\n skidding = _ref[0],\n distance = _ref[1];\n\n skidding = skidding || 0;\n distance = (distance || 0) * invertDistance;\n return [left, right].indexOf(basePlacement) >= 0 ? {\n x: distance,\n y: skidding\n } : {\n x: skidding,\n y: distance\n };\n}\n\nfunction offset(_ref2) {\n var state = _ref2.state,\n options = _ref2.options,\n name = _ref2.name;\n var _options$offset = options.offset,\n offset = _options$offset === void 0 ? [0, 0] : _options$offset;\n var data = placements.reduce(function (acc, placement) {\n acc[placement] = distanceAndSkiddingToXY(placement, state.rects, offset);\n return acc;\n }, {});\n var _data$state$placement = data[state.placement],\n x = _data$state$placement.x,\n y = _data$state$placement.y;\n\n if (state.modifiersData.popperOffsets != null) {\n state.modifiersData.popperOffsets.x += x;\n state.modifiersData.popperOffsets.y += y;\n }\n\n state.modifiersData[name] = data;\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'offset',\n enabled: true,\n phase: 'main',\n requires: ['popperOffsets'],\n fn: offset\n};","import computeOffsets from \"../utils/computeOffsets.js\";\n\nfunction popperOffsets(_ref) {\n var state = _ref.state,\n name = _ref.name;\n // Offsets are the actual position the popper needs to have to be\n // properly positioned near its reference element\n // This is the most basic placement, and will be adjusted by\n // the modifiers in the next step\n state.modifiersData[name] = computeOffsets({\n reference: state.rects.reference,\n element: state.rects.popper,\n strategy: 'absolute',\n placement: state.placement\n });\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'popperOffsets',\n enabled: true,\n phase: 'read',\n fn: popperOffsets,\n data: {}\n};","export default function getAltAxis(axis) {\n return axis === 'x' ? 'y' : 'x';\n}","import { top, left, right, bottom, start } from \"../enums.js\";\nimport getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getMainAxisFromPlacement from \"../utils/getMainAxisFromPlacement.js\";\nimport getAltAxis from \"../utils/getAltAxis.js\";\nimport { within, withinMaxClamp } from \"../utils/within.js\";\nimport getLayoutRect from \"../dom-utils/getLayoutRect.js\";\nimport getOffsetParent from \"../dom-utils/getOffsetParent.js\";\nimport detectOverflow from \"../utils/detectOverflow.js\";\nimport getVariation from \"../utils/getVariation.js\";\nimport getFreshSideObject from \"../utils/getFreshSideObject.js\";\nimport { min as mathMin, max as mathMax } from \"../utils/math.js\";\n\nfunction preventOverflow(_ref) {\n var state = _ref.state,\n options = _ref.options,\n name = _ref.name;\n var _options$mainAxis = options.mainAxis,\n checkMainAxis = _options$mainAxis === void 0 ? true : _options$mainAxis,\n _options$altAxis = options.altAxis,\n checkAltAxis = _options$altAxis === void 0 ? false : _options$altAxis,\n boundary = options.boundary,\n rootBoundary = options.rootBoundary,\n altBoundary = options.altBoundary,\n padding = options.padding,\n _options$tether = options.tether,\n tether = _options$tether === void 0 ? true : _options$tether,\n _options$tetherOffset = options.tetherOffset,\n tetherOffset = _options$tetherOffset === void 0 ? 0 : _options$tetherOffset;\n var overflow = detectOverflow(state, {\n boundary: boundary,\n rootBoundary: rootBoundary,\n padding: padding,\n altBoundary: altBoundary\n });\n var basePlacement = getBasePlacement(state.placement);\n var variation = getVariation(state.placement);\n var isBasePlacement = !variation;\n var mainAxis = getMainAxisFromPlacement(basePlacement);\n var altAxis = getAltAxis(mainAxis);\n var popperOffsets = state.modifiersData.popperOffsets;\n var referenceRect = state.rects.reference;\n var popperRect = state.rects.popper;\n var tetherOffsetValue = typeof tetherOffset === 'function' ? tetherOffset(Object.assign({}, state.rects, {\n placement: state.placement\n })) : tetherOffset;\n var normalizedTetherOffsetValue = typeof tetherOffsetValue === 'number' ? {\n mainAxis: tetherOffsetValue,\n altAxis: tetherOffsetValue\n } : Object.assign({\n mainAxis: 0,\n altAxis: 0\n }, tetherOffsetValue);\n var offsetModifierState = state.modifiersData.offset ? state.modifiersData.offset[state.placement] : null;\n var data = {\n x: 0,\n y: 0\n };\n\n if (!popperOffsets) {\n return;\n }\n\n if (checkMainAxis) {\n var _offsetModifierState$;\n\n var mainSide = mainAxis === 'y' ? top : left;\n var altSide = mainAxis === 'y' ? bottom : right;\n var len = mainAxis === 'y' ? 'height' : 'width';\n var offset = popperOffsets[mainAxis];\n var min = offset + overflow[mainSide];\n var max = offset - overflow[altSide];\n var additive = tether ? -popperRect[len] / 2 : 0;\n var minLen = variation === start ? referenceRect[len] : popperRect[len];\n var maxLen = variation === start ? -popperRect[len] : -referenceRect[len]; // We need to include the arrow in the calculation so the arrow doesn't go\n // outside the reference bounds\n\n var arrowElement = state.elements.arrow;\n var arrowRect = tether && arrowElement ? getLayoutRect(arrowElement) : {\n width: 0,\n height: 0\n };\n var arrowPaddingObject = state.modifiersData['arrow#persistent'] ? state.modifiersData['arrow#persistent'].padding : getFreshSideObject();\n var arrowPaddingMin = arrowPaddingObject[mainSide];\n var arrowPaddingMax = arrowPaddingObject[altSide]; // If the reference length is smaller than the arrow length, we don't want\n // to include its full size in the calculation. If the reference is small\n // and near the edge of a boundary, the popper can overflow even if the\n // reference is not overflowing as well (e.g. virtual elements with no\n // width or height)\n\n var arrowLen = within(0, referenceRect[len], arrowRect[len]);\n var minOffset = isBasePlacement ? referenceRect[len] / 2 - additive - arrowLen - arrowPaddingMin - normalizedTetherOffsetValue.mainAxis : minLen - arrowLen - arrowPaddingMin - normalizedTetherOffsetValue.mainAxis;\n var maxOffset = isBasePlacement ? -referenceRect[len] / 2 + additive + arrowLen + arrowPaddingMax + normalizedTetherOffsetValue.mainAxis : maxLen + arrowLen + arrowPaddingMax + normalizedTetherOffsetValue.mainAxis;\n var arrowOffsetParent = state.elements.arrow && getOffsetParent(state.elements.arrow);\n var clientOffset = arrowOffsetParent ? mainAxis === 'y' ? arrowOffsetParent.clientTop || 0 : arrowOffsetParent.clientLeft || 0 : 0;\n var offsetModifierValue = (_offsetModifierState$ = offsetModifierState == null ? void 0 : offsetModifierState[mainAxis]) != null ? _offsetModifierState$ : 0;\n var tetherMin = offset + minOffset - offsetModifierValue - clientOffset;\n var tetherMax = offset + maxOffset - offsetModifierValue;\n var preventedOffset = within(tether ? mathMin(min, tetherMin) : min, offset, tether ? mathMax(max, tetherMax) : max);\n popperOffsets[mainAxis] = preventedOffset;\n data[mainAxis] = preventedOffset - offset;\n }\n\n if (checkAltAxis) {\n var _offsetModifierState$2;\n\n var _mainSide = mainAxis === 'x' ? top : left;\n\n var _altSide = mainAxis === 'x' ? bottom : right;\n\n var _offset = popperOffsets[altAxis];\n\n var _len = altAxis === 'y' ? 'height' : 'width';\n\n var _min = _offset + overflow[_mainSide];\n\n var _max = _offset - overflow[_altSide];\n\n var isOriginSide = [top, left].indexOf(basePlacement) !== -1;\n\n var _offsetModifierValue = (_offsetModifierState$2 = offsetModifierState == null ? void 0 : offsetModifierState[altAxis]) != null ? _offsetModifierState$2 : 0;\n\n var _tetherMin = isOriginSide ? _min : _offset - referenceRect[_len] - popperRect[_len] - _offsetModifierValue + normalizedTetherOffsetValue.altAxis;\n\n var _tetherMax = isOriginSide ? _offset + referenceRect[_len] + popperRect[_len] - _offsetModifierValue - normalizedTetherOffsetValue.altAxis : _max;\n\n var _preventedOffset = tether && isOriginSide ? withinMaxClamp(_tetherMin, _offset, _tetherMax) : within(tether ? _tetherMin : _min, _offset, tether ? _tetherMax : _max);\n\n popperOffsets[altAxis] = _preventedOffset;\n data[altAxis] = _preventedOffset - _offset;\n }\n\n state.modifiersData[name] = data;\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'preventOverflow',\n enabled: true,\n phase: 'main',\n fn: preventOverflow,\n requiresIfExists: ['offset']\n};","export default function getHTMLElementScroll(element) {\n return {\n scrollLeft: element.scrollLeft,\n scrollTop: element.scrollTop\n };\n}","import getWindowScroll from \"./getWindowScroll.js\";\nimport getWindow from \"./getWindow.js\";\nimport { isHTMLElement } from \"./instanceOf.js\";\nimport getHTMLElementScroll from \"./getHTMLElementScroll.js\";\nexport default function getNodeScroll(node) {\n if (node === getWindow(node) || !isHTMLElement(node)) {\n return getWindowScroll(node);\n } else {\n return getHTMLElementScroll(node);\n }\n}","import getBoundingClientRect from \"./getBoundingClientRect.js\";\nimport getNodeScroll from \"./getNodeScroll.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport { isHTMLElement } from \"./instanceOf.js\";\nimport getWindowScrollBarX from \"./getWindowScrollBarX.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport isScrollParent from \"./isScrollParent.js\";\nimport { round } from \"../utils/math.js\";\n\nfunction isElementScaled(element) {\n var rect = element.getBoundingClientRect();\n var scaleX = round(rect.width) / element.offsetWidth || 1;\n var scaleY = round(rect.height) / element.offsetHeight || 1;\n return scaleX !== 1 || scaleY !== 1;\n} // Returns the composite rect of an element relative to its offsetParent.\n// Composite means it takes into account transforms as well as layout.\n\n\nexport default function getCompositeRect(elementOrVirtualElement, offsetParent, isFixed) {\n if (isFixed === void 0) {\n isFixed = false;\n }\n\n var isOffsetParentAnElement = isHTMLElement(offsetParent);\n var offsetParentIsScaled = isHTMLElement(offsetParent) && isElementScaled(offsetParent);\n var documentElement = getDocumentElement(offsetParent);\n var rect = getBoundingClientRect(elementOrVirtualElement, offsetParentIsScaled, isFixed);\n var scroll = {\n scrollLeft: 0,\n scrollTop: 0\n };\n var offsets = {\n x: 0,\n y: 0\n };\n\n if (isOffsetParentAnElement || !isOffsetParentAnElement && !isFixed) {\n if (getNodeName(offsetParent) !== 'body' || // https://github.com/popperjs/popper-core/issues/1078\n isScrollParent(documentElement)) {\n scroll = getNodeScroll(offsetParent);\n }\n\n if (isHTMLElement(offsetParent)) {\n offsets = getBoundingClientRect(offsetParent, true);\n offsets.x += offsetParent.clientLeft;\n offsets.y += offsetParent.clientTop;\n } else if (documentElement) {\n offsets.x = getWindowScrollBarX(documentElement);\n }\n }\n\n return {\n x: rect.left + scroll.scrollLeft - offsets.x,\n y: rect.top + scroll.scrollTop - offsets.y,\n width: rect.width,\n height: rect.height\n };\n}","import { modifierPhases } from \"../enums.js\"; // source: https://stackoverflow.com/questions/49875255\n\nfunction order(modifiers) {\n var map = new Map();\n var visited = new Set();\n var result = [];\n modifiers.forEach(function (modifier) {\n map.set(modifier.name, modifier);\n }); // On visiting object, check for its dependencies and visit them recursively\n\n function sort(modifier) {\n visited.add(modifier.name);\n var requires = [].concat(modifier.requires || [], modifier.requiresIfExists || []);\n requires.forEach(function (dep) {\n if (!visited.has(dep)) {\n var depModifier = map.get(dep);\n\n if (depModifier) {\n sort(depModifier);\n }\n }\n });\n result.push(modifier);\n }\n\n modifiers.forEach(function (modifier) {\n if (!visited.has(modifier.name)) {\n // check for visited object\n sort(modifier);\n }\n });\n return result;\n}\n\nexport default function orderModifiers(modifiers) {\n // order based on dependencies\n var orderedModifiers = order(modifiers); // order based on phase\n\n return modifierPhases.reduce(function (acc, phase) {\n return acc.concat(orderedModifiers.filter(function (modifier) {\n return modifier.phase === phase;\n }));\n }, []);\n}","export default function debounce(fn) {\n var pending;\n return function () {\n if (!pending) {\n pending = new Promise(function (resolve) {\n Promise.resolve().then(function () {\n pending = undefined;\n resolve(fn());\n });\n });\n }\n\n return pending;\n };\n}","export default function mergeByName(modifiers) {\n var merged = modifiers.reduce(function (merged, current) {\n var existing = merged[current.name];\n merged[current.name] = existing ? Object.assign({}, existing, current, {\n options: Object.assign({}, existing.options, current.options),\n data: Object.assign({}, existing.data, current.data)\n }) : current;\n return merged;\n }, {}); // IE11 does not support Object.values\n\n return Object.keys(merged).map(function (key) {\n return merged[key];\n });\n}","import getCompositeRect from \"./dom-utils/getCompositeRect.js\";\nimport getLayoutRect from \"./dom-utils/getLayoutRect.js\";\nimport listScrollParents from \"./dom-utils/listScrollParents.js\";\nimport getOffsetParent from \"./dom-utils/getOffsetParent.js\";\nimport orderModifiers from \"./utils/orderModifiers.js\";\nimport debounce from \"./utils/debounce.js\";\nimport mergeByName from \"./utils/mergeByName.js\";\nimport detectOverflow from \"./utils/detectOverflow.js\";\nimport { isElement } from \"./dom-utils/instanceOf.js\";\nvar DEFAULT_OPTIONS = {\n placement: 'bottom',\n modifiers: [],\n strategy: 'absolute'\n};\n\nfunction areValidElements() {\n for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {\n args[_key] = arguments[_key];\n }\n\n return !args.some(function (element) {\n return !(element && typeof element.getBoundingClientRect === 'function');\n });\n}\n\nexport function popperGenerator(generatorOptions) {\n if (generatorOptions === void 0) {\n generatorOptions = {};\n }\n\n var _generatorOptions = generatorOptions,\n _generatorOptions$def = _generatorOptions.defaultModifiers,\n defaultModifiers = _generatorOptions$def === void 0 ? [] : _generatorOptions$def,\n _generatorOptions$def2 = _generatorOptions.defaultOptions,\n defaultOptions = _generatorOptions$def2 === void 0 ? DEFAULT_OPTIONS : _generatorOptions$def2;\n return function createPopper(reference, popper, options) {\n if (options === void 0) {\n options = defaultOptions;\n }\n\n var state = {\n placement: 'bottom',\n orderedModifiers: [],\n options: Object.assign({}, DEFAULT_OPTIONS, defaultOptions),\n modifiersData: {},\n elements: {\n reference: reference,\n popper: popper\n },\n attributes: {},\n styles: {}\n };\n var effectCleanupFns = [];\n var isDestroyed = false;\n var instance = {\n state: state,\n setOptions: function setOptions(setOptionsAction) {\n var options = typeof setOptionsAction === 'function' ? setOptionsAction(state.options) : setOptionsAction;\n cleanupModifierEffects();\n state.options = Object.assign({}, defaultOptions, state.options, options);\n state.scrollParents = {\n reference: isElement(reference) ? listScrollParents(reference) : reference.contextElement ? listScrollParents(reference.contextElement) : [],\n popper: listScrollParents(popper)\n }; // Orders the modifiers based on their dependencies and `phase`\n // properties\n\n var orderedModifiers = orderModifiers(mergeByName([].concat(defaultModifiers, state.options.modifiers))); // Strip out disabled modifiers\n\n state.orderedModifiers = orderedModifiers.filter(function (m) {\n return m.enabled;\n });\n runModifierEffects();\n return instance.update();\n },\n // Sync update – it will always be executed, even if not necessary. This\n // is useful for low frequency updates where sync behavior simplifies the\n // logic.\n // For high frequency updates (e.g. `resize` and `scroll` events), always\n // prefer the async Popper#update method\n forceUpdate: function forceUpdate() {\n if (isDestroyed) {\n return;\n }\n\n var _state$elements = state.elements,\n reference = _state$elements.reference,\n popper = _state$elements.popper; // Don't proceed if `reference` or `popper` are not valid elements\n // anymore\n\n if (!areValidElements(reference, popper)) {\n return;\n } // Store the reference and popper rects to be read by modifiers\n\n\n state.rects = {\n reference: getCompositeRect(reference, getOffsetParent(popper), state.options.strategy === 'fixed'),\n popper: getLayoutRect(popper)\n }; // Modifiers have the ability to reset the current update cycle. The\n // most common use case for this is the `flip` modifier changing the\n // placement, which then needs to re-run all the modifiers, because the\n // logic was previously ran for the previous placement and is therefore\n // stale/incorrect\n\n state.reset = false;\n state.placement = state.options.placement; // On each update cycle, the `modifiersData` property for each modifier\n // is filled with the initial data specified by the modifier. This means\n // it doesn't persist and is fresh on each update.\n // To ensure persistent data, use `${name}#persistent`\n\n state.orderedModifiers.forEach(function (modifier) {\n return state.modifiersData[modifier.name] = Object.assign({}, modifier.data);\n });\n\n for (var index = 0; index < state.orderedModifiers.length; index++) {\n if (state.reset === true) {\n state.reset = false;\n index = -1;\n continue;\n }\n\n var _state$orderedModifie = state.orderedModifiers[index],\n fn = _state$orderedModifie.fn,\n _state$orderedModifie2 = _state$orderedModifie.options,\n _options = _state$orderedModifie2 === void 0 ? {} : _state$orderedModifie2,\n name = _state$orderedModifie.name;\n\n if (typeof fn === 'function') {\n state = fn({\n state: state,\n options: _options,\n name: name,\n instance: instance\n }) || state;\n }\n }\n },\n // Async and optimistically optimized update – it will not be executed if\n // not necessary (debounced to run at most once-per-tick)\n update: debounce(function () {\n return new Promise(function (resolve) {\n instance.forceUpdate();\n resolve(state);\n });\n }),\n destroy: function destroy() {\n cleanupModifierEffects();\n isDestroyed = true;\n }\n };\n\n if (!areValidElements(reference, popper)) {\n return instance;\n }\n\n instance.setOptions(options).then(function (state) {\n if (!isDestroyed && options.onFirstUpdate) {\n options.onFirstUpdate(state);\n }\n }); // Modifiers have the ability to execute arbitrary code before the first\n // update cycle runs. They will be executed in the same order as the update\n // cycle. This is useful when a modifier adds some persistent data that\n // other modifiers need to use, but the modifier is run after the dependent\n // one.\n\n function runModifierEffects() {\n state.orderedModifiers.forEach(function (_ref) {\n var name = _ref.name,\n _ref$options = _ref.options,\n options = _ref$options === void 0 ? {} : _ref$options,\n effect = _ref.effect;\n\n if (typeof effect === 'function') {\n var cleanupFn = effect({\n state: state,\n name: name,\n instance: instance,\n options: options\n });\n\n var noopFn = function noopFn() {};\n\n effectCleanupFns.push(cleanupFn || noopFn);\n }\n });\n }\n\n function cleanupModifierEffects() {\n effectCleanupFns.forEach(function (fn) {\n return fn();\n });\n effectCleanupFns = [];\n }\n\n return instance;\n };\n}\nexport var createPopper = /*#__PURE__*/popperGenerator(); // eslint-disable-next-line import/no-unused-modules\n\nexport { detectOverflow };","import { popperGenerator, detectOverflow } from \"./createPopper.js\";\nimport eventListeners from \"./modifiers/eventListeners.js\";\nimport popperOffsets from \"./modifiers/popperOffsets.js\";\nimport computeStyles from \"./modifiers/computeStyles.js\";\nimport applyStyles from \"./modifiers/applyStyles.js\";\nimport offset from \"./modifiers/offset.js\";\nimport flip from \"./modifiers/flip.js\";\nimport preventOverflow from \"./modifiers/preventOverflow.js\";\nimport arrow from \"./modifiers/arrow.js\";\nimport hide from \"./modifiers/hide.js\";\nvar defaultModifiers = [eventListeners, popperOffsets, computeStyles, applyStyles, offset, flip, preventOverflow, arrow, hide];\nvar createPopper = /*#__PURE__*/popperGenerator({\n defaultModifiers: defaultModifiers\n}); // eslint-disable-next-line import/no-unused-modules\n\nexport { createPopper, popperGenerator, defaultModifiers, detectOverflow }; // eslint-disable-next-line import/no-unused-modules\n\nexport { createPopper as createPopperLite } from \"./popper-lite.js\"; // eslint-disable-next-line import/no-unused-modules\n\nexport * from \"./modifiers/index.js\";","import { generateUtilityClass } from '../generateUtilityClass';\nimport { generateUtilityClasses } from '../generateUtilityClasses';\nconst COMPONENT_NAME = 'Popper';\nexport function getPopperUtilityClass(slot) {\n return generateUtilityClass(COMPONENT_NAME, slot);\n}\nexport const popperClasses = generateUtilityClasses(COMPONENT_NAME, ['root']);","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"anchorEl\", \"children\", \"direction\", \"disablePortal\", \"modifiers\", \"open\", \"placement\", \"popperOptions\", \"popperRef\", \"slotProps\", \"slots\", \"TransitionProps\", \"ownerState\"],\n _excluded2 = [\"anchorEl\", \"children\", \"container\", \"direction\", \"disablePortal\", \"keepMounted\", \"modifiers\", \"open\", \"placement\", \"popperOptions\", \"popperRef\", \"style\", \"transition\", \"slotProps\", \"slots\"];\nimport * as React from 'react';\nimport { chainPropTypes, HTMLElementType, refType, unstable_ownerDocument as ownerDocument, unstable_useEnhancedEffect as useEnhancedEffect, unstable_useForkRef as useForkRef } from '@mui/utils';\nimport { createPopper } from '@popperjs/core';\nimport PropTypes from 'prop-types';\nimport { unstable_composeClasses as composeClasses } from '../composeClasses';\nimport { Portal } from '../Portal';\nimport { getPopperUtilityClass } from './popperClasses';\nimport { useSlotProps } from '../utils';\nimport { useClassNamesOverride } from '../utils/ClassNameConfigurator';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nfunction flipPlacement(placement, direction) {\n if (direction === 'ltr') {\n return placement;\n }\n switch (placement) {\n case 'bottom-end':\n return 'bottom-start';\n case 'bottom-start':\n return 'bottom-end';\n case 'top-end':\n return 'top-start';\n case 'top-start':\n return 'top-end';\n default:\n return placement;\n }\n}\nfunction resolveAnchorEl(anchorEl) {\n return typeof anchorEl === 'function' ? anchorEl() : anchorEl;\n}\nfunction isHTMLElement(element) {\n return element.nodeType !== undefined;\n}\nfunction isVirtualElement(element) {\n return !isHTMLElement(element);\n}\nconst useUtilityClasses = () => {\n const slots = {\n root: ['root']\n };\n return composeClasses(slots, useClassNamesOverride(getPopperUtilityClass));\n};\nconst defaultPopperOptions = {};\nconst PopperTooltip = /*#__PURE__*/React.forwardRef(function PopperTooltip(props, forwardedRef) {\n var _slots$root;\n const {\n anchorEl,\n children,\n direction,\n disablePortal,\n modifiers,\n open,\n placement: initialPlacement,\n popperOptions,\n popperRef: popperRefProp,\n slotProps = {},\n slots = {},\n TransitionProps\n // @ts-ignore internal logic\n // prevent from spreading to DOM, it can come from the parent component e.g. Select.\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const tooltipRef = React.useRef(null);\n const ownRef = useForkRef(tooltipRef, forwardedRef);\n const popperRef = React.useRef(null);\n const handlePopperRef = useForkRef(popperRef, popperRefProp);\n const handlePopperRefRef = React.useRef(handlePopperRef);\n useEnhancedEffect(() => {\n handlePopperRefRef.current = handlePopperRef;\n }, [handlePopperRef]);\n React.useImperativeHandle(popperRefProp, () => popperRef.current, []);\n const rtlPlacement = flipPlacement(initialPlacement, direction);\n /**\n * placement initialized from prop but can change during lifetime if modifiers.flip.\n * modifiers.flip is essentially a flip for controlled/uncontrolled behavior\n */\n const [placement, setPlacement] = React.useState(rtlPlacement);\n const [resolvedAnchorElement, setResolvedAnchorElement] = React.useState(resolveAnchorEl(anchorEl));\n React.useEffect(() => {\n if (popperRef.current) {\n popperRef.current.forceUpdate();\n }\n });\n React.useEffect(() => {\n if (anchorEl) {\n setResolvedAnchorElement(resolveAnchorEl(anchorEl));\n }\n }, [anchorEl]);\n useEnhancedEffect(() => {\n if (!resolvedAnchorElement || !open) {\n return undefined;\n }\n const handlePopperUpdate = data => {\n setPlacement(data.placement);\n };\n if (process.env.NODE_ENV !== 'production') {\n if (resolvedAnchorElement && isHTMLElement(resolvedAnchorElement) && resolvedAnchorElement.nodeType === 1) {\n const box = resolvedAnchorElement.getBoundingClientRect();\n if (process.env.NODE_ENV !== 'test' && box.top === 0 && box.left === 0 && box.right === 0 && box.bottom === 0) {\n console.warn(['MUI: The `anchorEl` prop provided to the component is invalid.', 'The anchor element should be part of the document layout.', \"Make sure the element is present in the document or that it's not display none.\"].join('\\n'));\n }\n }\n }\n let popperModifiers = [{\n name: 'preventOverflow',\n options: {\n altBoundary: disablePortal\n }\n }, {\n name: 'flip',\n options: {\n altBoundary: disablePortal\n }\n }, {\n name: 'onUpdate',\n enabled: true,\n phase: 'afterWrite',\n fn: ({\n state\n }) => {\n handlePopperUpdate(state);\n }\n }];\n if (modifiers != null) {\n popperModifiers = popperModifiers.concat(modifiers);\n }\n if (popperOptions && popperOptions.modifiers != null) {\n popperModifiers = popperModifiers.concat(popperOptions.modifiers);\n }\n const popper = createPopper(resolvedAnchorElement, tooltipRef.current, _extends({\n placement: rtlPlacement\n }, popperOptions, {\n modifiers: popperModifiers\n }));\n handlePopperRefRef.current(popper);\n return () => {\n popper.destroy();\n handlePopperRefRef.current(null);\n };\n }, [resolvedAnchorElement, disablePortal, modifiers, open, popperOptions, rtlPlacement]);\n const childProps = {\n placement: placement\n };\n if (TransitionProps !== null) {\n childProps.TransitionProps = TransitionProps;\n }\n const classes = useUtilityClasses();\n const Root = (_slots$root = slots.root) != null ? _slots$root : 'div';\n const rootProps = useSlotProps({\n elementType: Root,\n externalSlotProps: slotProps.root,\n externalForwardedProps: other,\n additionalProps: {\n role: 'tooltip',\n ref: ownRef\n },\n ownerState: props,\n className: classes.root\n });\n return /*#__PURE__*/_jsx(Root, _extends({}, rootProps, {\n children: typeof children === 'function' ? children(childProps) : children\n }));\n});\n\n/**\n * Poppers rely on the 3rd party library [Popper.js](https://popper.js.org/docs/v2/) for positioning.\n *\n * Demos:\n *\n * - [Popper](https://mui.com/base-ui/react-popper/)\n *\n * API:\n *\n * - [Popper API](https://mui.com/base-ui/react-popper/components-api/#popper)\n */\nconst Popper = /*#__PURE__*/React.forwardRef(function Popper(props, forwardedRef) {\n const {\n anchorEl,\n children,\n container: containerProp,\n direction = 'ltr',\n disablePortal = false,\n keepMounted = false,\n modifiers,\n open,\n placement = 'bottom',\n popperOptions = defaultPopperOptions,\n popperRef,\n style,\n transition = false,\n slotProps = {},\n slots = {}\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded2);\n const [exited, setExited] = React.useState(true);\n const handleEnter = () => {\n setExited(false);\n };\n const handleExited = () => {\n setExited(true);\n };\n if (!keepMounted && !open && (!transition || exited)) {\n return null;\n }\n\n // If the container prop is provided, use that\n // If the anchorEl prop is provided, use its parent body element as the container\n // If neither are provided let the Modal take care of choosing the container\n let container;\n if (containerProp) {\n container = containerProp;\n } else if (anchorEl) {\n const resolvedAnchorEl = resolveAnchorEl(anchorEl);\n container = resolvedAnchorEl && isHTMLElement(resolvedAnchorEl) ? ownerDocument(resolvedAnchorEl).body : ownerDocument(null).body;\n }\n const display = !open && keepMounted && (!transition || exited) ? 'none' : undefined;\n const transitionProps = transition ? {\n in: open,\n onEnter: handleEnter,\n onExited: handleExited\n } : undefined;\n return /*#__PURE__*/_jsx(Portal, {\n disablePortal: disablePortal,\n container: container,\n children: /*#__PURE__*/_jsx(PopperTooltip, _extends({\n anchorEl: anchorEl,\n direction: direction,\n disablePortal: disablePortal,\n modifiers: modifiers,\n ref: forwardedRef,\n open: transition ? !exited : open,\n placement: placement,\n popperOptions: popperOptions,\n popperRef: popperRef,\n slotProps: slotProps,\n slots: slots\n }, other, {\n style: _extends({\n // Prevents scroll issue, waiting for Popper.js to add this style once initiated.\n position: 'fixed',\n // Fix Popper.js display issue\n top: 0,\n left: 0,\n display\n }, style),\n TransitionProps: transitionProps,\n children: children\n }))\n });\n});\nprocess.env.NODE_ENV !== \"production\" ? Popper.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * An HTML element, [virtualElement](https://popper.js.org/docs/v2/virtual-elements/),\n * or a function that returns either.\n * It's used to set the position of the popper.\n * The return value will passed as the reference object of the Popper instance.\n */\n anchorEl: chainPropTypes(PropTypes.oneOfType([HTMLElementType, PropTypes.object, PropTypes.func]), props => {\n if (props.open) {\n const resolvedAnchorEl = resolveAnchorEl(props.anchorEl);\n if (resolvedAnchorEl && isHTMLElement(resolvedAnchorEl) && resolvedAnchorEl.nodeType === 1) {\n const box = resolvedAnchorEl.getBoundingClientRect();\n if (process.env.NODE_ENV !== 'test' && box.top === 0 && box.left === 0 && box.right === 0 && box.bottom === 0) {\n return new Error(['MUI: The `anchorEl` prop provided to the component is invalid.', 'The anchor element should be part of the document layout.', \"Make sure the element is present in the document or that it's not display none.\"].join('\\n'));\n }\n } else if (!resolvedAnchorEl || typeof resolvedAnchorEl.getBoundingClientRect !== 'function' || isVirtualElement(resolvedAnchorEl) && resolvedAnchorEl.contextElement != null && resolvedAnchorEl.contextElement.nodeType !== 1) {\n return new Error(['MUI: The `anchorEl` prop provided to the component is invalid.', 'It should be an HTML element instance or a virtualElement ', '(https://popper.js.org/docs/v2/virtual-elements/).'].join('\\n'));\n }\n }\n return null;\n }),\n /**\n * Popper render function or node.\n */\n children: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.node, PropTypes.func]),\n /**\n * An HTML element or function that returns one.\n * The `container` will have the portal children appended to it.\n *\n * You can also provide a callback, which is called in a React layout effect.\n * This lets you set the container from a ref, and also makes server-side rendering possible.\n *\n * By default, it uses the body of the top-level document object,\n * so it's simply `document.body` most of the time.\n */\n container: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.func]),\n /**\n * Direction of the text.\n * @default 'ltr'\n */\n direction: PropTypes.oneOf(['ltr', 'rtl']),\n /**\n * The `children` will be under the DOM hierarchy of the parent component.\n * @default false\n */\n disablePortal: PropTypes.bool,\n /**\n * Always keep the children in the DOM.\n * This prop can be useful in SEO situation or\n * when you want to maximize the responsiveness of the Popper.\n * @default false\n */\n keepMounted: PropTypes.bool,\n /**\n * Popper.js is based on a \"plugin-like\" architecture,\n * most of its features are fully encapsulated \"modifiers\".\n *\n * A modifier is a function that is called each time Popper.js needs to\n * compute the position of the popper.\n * For this reason, modifiers should be very performant to avoid bottlenecks.\n * To learn how to create a modifier, [read the modifiers documentation](https://popper.js.org/docs/v2/modifiers/).\n */\n modifiers: PropTypes.arrayOf(PropTypes.shape({\n data: PropTypes.object,\n effect: PropTypes.func,\n enabled: PropTypes.bool,\n fn: PropTypes.func,\n name: PropTypes.any,\n options: PropTypes.object,\n phase: PropTypes.oneOf(['afterMain', 'afterRead', 'afterWrite', 'beforeMain', 'beforeRead', 'beforeWrite', 'main', 'read', 'write']),\n requires: PropTypes.arrayOf(PropTypes.string),\n requiresIfExists: PropTypes.arrayOf(PropTypes.string)\n })),\n /**\n * If `true`, the component is shown.\n */\n open: PropTypes.bool.isRequired,\n /**\n * Popper placement.\n * @default 'bottom'\n */\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n /**\n * Options provided to the [`Popper.js`](https://popper.js.org/docs/v2/constructors/#options) instance.\n * @default {}\n */\n popperOptions: PropTypes.shape({\n modifiers: PropTypes.array,\n onFirstUpdate: PropTypes.func,\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n strategy: PropTypes.oneOf(['absolute', 'fixed'])\n }),\n /**\n * A ref that points to the used popper instance.\n */\n popperRef: refType,\n /**\n * The props used for each slot inside the Popper.\n * @default {}\n */\n slotProps: PropTypes.shape({\n root: PropTypes.oneOfType([PropTypes.func, PropTypes.object])\n }),\n /**\n * The components used for each slot inside the Popper.\n * Either a string to use a HTML element or a component.\n * @default {}\n */\n slots: PropTypes.shape({\n root: PropTypes.elementType\n }),\n /**\n * Help supporting a react-transition-group/Transition component.\n * @default false\n */\n transition: PropTypes.bool\n} : void 0;\nexport { Popper };","'use client';\n\nimport * as React from 'react';\nimport { useTheme as useThemeSystem } from '@mui/system';\nimport defaultTheme from './defaultTheme';\nimport THEME_ID from './identifier';\nexport default function useTheme() {\n const theme = useThemeSystem(defaultTheme);\n if (process.env.NODE_ENV !== 'production') {\n // eslint-disable-next-line react-hooks/rules-of-hooks\n React.useDebugValue(theme);\n }\n return theme[THEME_ID] || theme;\n}","export default function _setPrototypeOf(o, p) {\n _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function _setPrototypeOf(o, p) {\n o.__proto__ = p;\n return o;\n };\n return _setPrototypeOf(o, p);\n}","import setPrototypeOf from \"./setPrototypeOf.js\";\nexport default function _inheritsLoose(subClass, superClass) {\n subClass.prototype = Object.create(superClass.prototype);\n subClass.prototype.constructor = subClass;\n setPrototypeOf(subClass, superClass);\n}","export default {\n disabled: false\n};","import PropTypes from 'prop-types';\nexport var timeoutsShape = process.env.NODE_ENV !== 'production' ? PropTypes.oneOfType([PropTypes.number, PropTypes.shape({\n enter: PropTypes.number,\n exit: PropTypes.number,\n appear: PropTypes.number\n}).isRequired]) : null;\nexport var classNamesShape = process.env.NODE_ENV !== 'production' ? PropTypes.oneOfType([PropTypes.string, PropTypes.shape({\n enter: PropTypes.string,\n exit: PropTypes.string,\n active: PropTypes.string\n}), PropTypes.shape({\n enter: PropTypes.string,\n enterDone: PropTypes.string,\n enterActive: PropTypes.string,\n exit: PropTypes.string,\n exitDone: PropTypes.string,\n exitActive: PropTypes.string\n})]) : null;","import React from 'react';\nexport default React.createContext(null);","export var forceReflow = function forceReflow(node) {\n return node.scrollTop;\n};","import _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _inheritsLoose from \"@babel/runtime/helpers/esm/inheritsLoose\";\nimport PropTypes from 'prop-types';\nimport React from 'react';\nimport ReactDOM from 'react-dom';\nimport config from './config';\nimport { timeoutsShape } from './utils/PropTypes';\nimport TransitionGroupContext from './TransitionGroupContext';\nimport { forceReflow } from './utils/reflow';\nexport var UNMOUNTED = 'unmounted';\nexport var EXITED = 'exited';\nexport var ENTERING = 'entering';\nexport var ENTERED = 'entered';\nexport var EXITING = 'exiting';\n/**\n * The Transition component lets you describe a transition from one component\n * state to another _over time_ with a simple declarative API. Most commonly\n * it's used to animate the mounting and unmounting of a component, but can also\n * be used to describe in-place transition states as well.\n *\n * ---\n *\n * **Note**: `Transition` is a platform-agnostic base component. If you're using\n * transitions in CSS, you'll probably want to use\n * [`CSSTransition`](https://reactcommunity.org/react-transition-group/css-transition)\n * instead. It inherits all the features of `Transition`, but contains\n * additional features necessary to play nice with CSS transitions (hence the\n * name of the component).\n *\n * ---\n *\n * By default the `Transition` component does not alter the behavior of the\n * component it renders, it only tracks \"enter\" and \"exit\" states for the\n * components. It's up to you to give meaning and effect to those states. For\n * example we can add styles to a component when it enters or exits:\n *\n * ```jsx\n * import { Transition } from 'react-transition-group';\n *\n * const duration = 300;\n *\n * const defaultStyle = {\n * transition: `opacity ${duration}ms ease-in-out`,\n * opacity: 0,\n * }\n *\n * const transitionStyles = {\n * entering: { opacity: 1 },\n * entered: { opacity: 1 },\n * exiting: { opacity: 0 },\n * exited: { opacity: 0 },\n * };\n *\n * const Fade = ({ in: inProp }) => (\n * \n * {state => (\n *
    \n * I'm a fade Transition!\n *
    \n * )}\n *
    \n * );\n * ```\n *\n * There are 4 main states a Transition can be in:\n * - `'entering'`\n * - `'entered'`\n * - `'exiting'`\n * - `'exited'`\n *\n * Transition state is toggled via the `in` prop. When `true` the component\n * begins the \"Enter\" stage. During this stage, the component will shift from\n * its current transition state, to `'entering'` for the duration of the\n * transition and then to the `'entered'` stage once it's complete. Let's take\n * the following example (we'll use the\n * [useState](https://reactjs.org/docs/hooks-reference.html#usestate) hook):\n *\n * ```jsx\n * function App() {\n * const [inProp, setInProp] = useState(false);\n * return (\n *
    \n * \n * {state => (\n * // ...\n * )}\n * \n * \n *
    \n * );\n * }\n * ```\n *\n * When the button is clicked the component will shift to the `'entering'` state\n * and stay there for 500ms (the value of `timeout`) before it finally switches\n * to `'entered'`.\n *\n * When `in` is `false` the same thing happens except the state moves from\n * `'exiting'` to `'exited'`.\n */\n\nvar Transition = /*#__PURE__*/function (_React$Component) {\n _inheritsLoose(Transition, _React$Component);\n\n function Transition(props, context) {\n var _this;\n\n _this = _React$Component.call(this, props, context) || this;\n var parentGroup = context; // In the context of a TransitionGroup all enters are really appears\n\n var appear = parentGroup && !parentGroup.isMounting ? props.enter : props.appear;\n var initialStatus;\n _this.appearStatus = null;\n\n if (props.in) {\n if (appear) {\n initialStatus = EXITED;\n _this.appearStatus = ENTERING;\n } else {\n initialStatus = ENTERED;\n }\n } else {\n if (props.unmountOnExit || props.mountOnEnter) {\n initialStatus = UNMOUNTED;\n } else {\n initialStatus = EXITED;\n }\n }\n\n _this.state = {\n status: initialStatus\n };\n _this.nextCallback = null;\n return _this;\n }\n\n Transition.getDerivedStateFromProps = function getDerivedStateFromProps(_ref, prevState) {\n var nextIn = _ref.in;\n\n if (nextIn && prevState.status === UNMOUNTED) {\n return {\n status: EXITED\n };\n }\n\n return null;\n } // getSnapshotBeforeUpdate(prevProps) {\n // let nextStatus = null\n // if (prevProps !== this.props) {\n // const { status } = this.state\n // if (this.props.in) {\n // if (status !== ENTERING && status !== ENTERED) {\n // nextStatus = ENTERING\n // }\n // } else {\n // if (status === ENTERING || status === ENTERED) {\n // nextStatus = EXITING\n // }\n // }\n // }\n // return { nextStatus }\n // }\n ;\n\n var _proto = Transition.prototype;\n\n _proto.componentDidMount = function componentDidMount() {\n this.updateStatus(true, this.appearStatus);\n };\n\n _proto.componentDidUpdate = function componentDidUpdate(prevProps) {\n var nextStatus = null;\n\n if (prevProps !== this.props) {\n var status = this.state.status;\n\n if (this.props.in) {\n if (status !== ENTERING && status !== ENTERED) {\n nextStatus = ENTERING;\n }\n } else {\n if (status === ENTERING || status === ENTERED) {\n nextStatus = EXITING;\n }\n }\n }\n\n this.updateStatus(false, nextStatus);\n };\n\n _proto.componentWillUnmount = function componentWillUnmount() {\n this.cancelNextCallback();\n };\n\n _proto.getTimeouts = function getTimeouts() {\n var timeout = this.props.timeout;\n var exit, enter, appear;\n exit = enter = appear = timeout;\n\n if (timeout != null && typeof timeout !== 'number') {\n exit = timeout.exit;\n enter = timeout.enter; // TODO: remove fallback for next major\n\n appear = timeout.appear !== undefined ? timeout.appear : enter;\n }\n\n return {\n exit: exit,\n enter: enter,\n appear: appear\n };\n };\n\n _proto.updateStatus = function updateStatus(mounting, nextStatus) {\n if (mounting === void 0) {\n mounting = false;\n }\n\n if (nextStatus !== null) {\n // nextStatus will always be ENTERING or EXITING.\n this.cancelNextCallback();\n\n if (nextStatus === ENTERING) {\n if (this.props.unmountOnExit || this.props.mountOnEnter) {\n var node = this.props.nodeRef ? this.props.nodeRef.current : ReactDOM.findDOMNode(this); // https://github.com/reactjs/react-transition-group/pull/749\n // With unmountOnExit or mountOnEnter, the enter animation should happen at the transition between `exited` and `entering`.\n // To make the animation happen, we have to separate each rendering and avoid being processed as batched.\n\n if (node) forceReflow(node);\n }\n\n this.performEnter(mounting);\n } else {\n this.performExit();\n }\n } else if (this.props.unmountOnExit && this.state.status === EXITED) {\n this.setState({\n status: UNMOUNTED\n });\n }\n };\n\n _proto.performEnter = function performEnter(mounting) {\n var _this2 = this;\n\n var enter = this.props.enter;\n var appearing = this.context ? this.context.isMounting : mounting;\n\n var _ref2 = this.props.nodeRef ? [appearing] : [ReactDOM.findDOMNode(this), appearing],\n maybeNode = _ref2[0],\n maybeAppearing = _ref2[1];\n\n var timeouts = this.getTimeouts();\n var enterTimeout = appearing ? timeouts.appear : timeouts.enter; // no enter animation skip right to ENTERED\n // if we are mounting and running this it means appear _must_ be set\n\n if (!mounting && !enter || config.disabled) {\n this.safeSetState({\n status: ENTERED\n }, function () {\n _this2.props.onEntered(maybeNode);\n });\n return;\n }\n\n this.props.onEnter(maybeNode, maybeAppearing);\n this.safeSetState({\n status: ENTERING\n }, function () {\n _this2.props.onEntering(maybeNode, maybeAppearing);\n\n _this2.onTransitionEnd(enterTimeout, function () {\n _this2.safeSetState({\n status: ENTERED\n }, function () {\n _this2.props.onEntered(maybeNode, maybeAppearing);\n });\n });\n });\n };\n\n _proto.performExit = function performExit() {\n var _this3 = this;\n\n var exit = this.props.exit;\n var timeouts = this.getTimeouts();\n var maybeNode = this.props.nodeRef ? undefined : ReactDOM.findDOMNode(this); // no exit animation skip right to EXITED\n\n if (!exit || config.disabled) {\n this.safeSetState({\n status: EXITED\n }, function () {\n _this3.props.onExited(maybeNode);\n });\n return;\n }\n\n this.props.onExit(maybeNode);\n this.safeSetState({\n status: EXITING\n }, function () {\n _this3.props.onExiting(maybeNode);\n\n _this3.onTransitionEnd(timeouts.exit, function () {\n _this3.safeSetState({\n status: EXITED\n }, function () {\n _this3.props.onExited(maybeNode);\n });\n });\n });\n };\n\n _proto.cancelNextCallback = function cancelNextCallback() {\n if (this.nextCallback !== null) {\n this.nextCallback.cancel();\n this.nextCallback = null;\n }\n };\n\n _proto.safeSetState = function safeSetState(nextState, callback) {\n // This shouldn't be necessary, but there are weird race conditions with\n // setState callbacks and unmounting in testing, so always make sure that\n // we can cancel any pending setState callbacks after we unmount.\n callback = this.setNextCallback(callback);\n this.setState(nextState, callback);\n };\n\n _proto.setNextCallback = function setNextCallback(callback) {\n var _this4 = this;\n\n var active = true;\n\n this.nextCallback = function (event) {\n if (active) {\n active = false;\n _this4.nextCallback = null;\n callback(event);\n }\n };\n\n this.nextCallback.cancel = function () {\n active = false;\n };\n\n return this.nextCallback;\n };\n\n _proto.onTransitionEnd = function onTransitionEnd(timeout, handler) {\n this.setNextCallback(handler);\n var node = this.props.nodeRef ? this.props.nodeRef.current : ReactDOM.findDOMNode(this);\n var doesNotHaveTimeoutOrListener = timeout == null && !this.props.addEndListener;\n\n if (!node || doesNotHaveTimeoutOrListener) {\n setTimeout(this.nextCallback, 0);\n return;\n }\n\n if (this.props.addEndListener) {\n var _ref3 = this.props.nodeRef ? [this.nextCallback] : [node, this.nextCallback],\n maybeNode = _ref3[0],\n maybeNextCallback = _ref3[1];\n\n this.props.addEndListener(maybeNode, maybeNextCallback);\n }\n\n if (timeout != null) {\n setTimeout(this.nextCallback, timeout);\n }\n };\n\n _proto.render = function render() {\n var status = this.state.status;\n\n if (status === UNMOUNTED) {\n return null;\n }\n\n var _this$props = this.props,\n children = _this$props.children,\n _in = _this$props.in,\n _mountOnEnter = _this$props.mountOnEnter,\n _unmountOnExit = _this$props.unmountOnExit,\n _appear = _this$props.appear,\n _enter = _this$props.enter,\n _exit = _this$props.exit,\n _timeout = _this$props.timeout,\n _addEndListener = _this$props.addEndListener,\n _onEnter = _this$props.onEnter,\n _onEntering = _this$props.onEntering,\n _onEntered = _this$props.onEntered,\n _onExit = _this$props.onExit,\n _onExiting = _this$props.onExiting,\n _onExited = _this$props.onExited,\n _nodeRef = _this$props.nodeRef,\n childProps = _objectWithoutPropertiesLoose(_this$props, [\"children\", \"in\", \"mountOnEnter\", \"unmountOnExit\", \"appear\", \"enter\", \"exit\", \"timeout\", \"addEndListener\", \"onEnter\", \"onEntering\", \"onEntered\", \"onExit\", \"onExiting\", \"onExited\", \"nodeRef\"]);\n\n return (\n /*#__PURE__*/\n // allows for nested Transitions\n React.createElement(TransitionGroupContext.Provider, {\n value: null\n }, typeof children === 'function' ? children(status, childProps) : React.cloneElement(React.Children.only(children), childProps))\n );\n };\n\n return Transition;\n}(React.Component);\n\nTransition.contextType = TransitionGroupContext;\nTransition.propTypes = process.env.NODE_ENV !== \"production\" ? {\n /**\n * A React reference to DOM element that need to transition:\n * https://stackoverflow.com/a/51127130/4671932\n *\n * - When `nodeRef` prop is used, `node` is not passed to callback functions\n * (e.g. `onEnter`) because user already has direct access to the node.\n * - When changing `key` prop of `Transition` in a `TransitionGroup` a new\n * `nodeRef` need to be provided to `Transition` with changed `key` prop\n * (see\n * [test/CSSTransition-test.js](https://github.com/reactjs/react-transition-group/blob/13435f897b3ab71f6e19d724f145596f5910581c/test/CSSTransition-test.js#L362-L437)).\n */\n nodeRef: PropTypes.shape({\n current: typeof Element === 'undefined' ? PropTypes.any : function (propValue, key, componentName, location, propFullName, secret) {\n var value = propValue[key];\n return PropTypes.instanceOf(value && 'ownerDocument' in value ? value.ownerDocument.defaultView.Element : Element)(propValue, key, componentName, location, propFullName, secret);\n }\n }),\n\n /**\n * A `function` child can be used instead of a React element. This function is\n * called with the current transition status (`'entering'`, `'entered'`,\n * `'exiting'`, `'exited'`), which can be used to apply context\n * specific props to a component.\n *\n * ```jsx\n * \n * {state => (\n * \n * )}\n * \n * ```\n */\n children: PropTypes.oneOfType([PropTypes.func.isRequired, PropTypes.element.isRequired]).isRequired,\n\n /**\n * Show the component; triggers the enter or exit states\n */\n in: PropTypes.bool,\n\n /**\n * By default the child component is mounted immediately along with\n * the parent `Transition` component. If you want to \"lazy mount\" the component on the\n * first `in={true}` you can set `mountOnEnter`. After the first enter transition the component will stay\n * mounted, even on \"exited\", unless you also specify `unmountOnExit`.\n */\n mountOnEnter: PropTypes.bool,\n\n /**\n * By default the child component stays mounted after it reaches the `'exited'` state.\n * Set `unmountOnExit` if you'd prefer to unmount the component after it finishes exiting.\n */\n unmountOnExit: PropTypes.bool,\n\n /**\n * By default the child component does not perform the enter transition when\n * it first mounts, regardless of the value of `in`. If you want this\n * behavior, set both `appear` and `in` to `true`.\n *\n * > **Note**: there are no special appear states like `appearing`/`appeared`, this prop\n * > only adds an additional enter transition. However, in the\n * > `` component that first enter transition does result in\n * > additional `.appear-*` classes, that way you can choose to style it\n * > differently.\n */\n appear: PropTypes.bool,\n\n /**\n * Enable or disable enter transitions.\n */\n enter: PropTypes.bool,\n\n /**\n * Enable or disable exit transitions.\n */\n exit: PropTypes.bool,\n\n /**\n * The duration of the transition, in milliseconds.\n * Required unless `addEndListener` is provided.\n *\n * You may specify a single timeout for all transitions:\n *\n * ```jsx\n * timeout={500}\n * ```\n *\n * or individually:\n *\n * ```jsx\n * timeout={{\n * appear: 500,\n * enter: 300,\n * exit: 500,\n * }}\n * ```\n *\n * - `appear` defaults to the value of `enter`\n * - `enter` defaults to `0`\n * - `exit` defaults to `0`\n *\n * @type {number | { enter?: number, exit?: number, appear?: number }}\n */\n timeout: function timeout(props) {\n var pt = timeoutsShape;\n if (!props.addEndListener) pt = pt.isRequired;\n\n for (var _len = arguments.length, args = new Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) {\n args[_key - 1] = arguments[_key];\n }\n\n return pt.apply(void 0, [props].concat(args));\n },\n\n /**\n * Add a custom transition end trigger. Called with the transitioning\n * DOM node and a `done` callback. Allows for more fine grained transition end\n * logic. Timeouts are still used as a fallback if provided.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * ```jsx\n * addEndListener={(node, done) => {\n * // use the css transitionend event to mark the finish of a transition\n * node.addEventListener('transitionend', done, false);\n * }}\n * ```\n */\n addEndListener: PropTypes.func,\n\n /**\n * Callback fired before the \"entering\" status is applied. An extra parameter\n * `isAppearing` is supplied to indicate if the enter stage is occurring on the initial mount\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement, isAppearing: bool) -> void\n */\n onEnter: PropTypes.func,\n\n /**\n * Callback fired after the \"entering\" status is applied. An extra parameter\n * `isAppearing` is supplied to indicate if the enter stage is occurring on the initial mount\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement, isAppearing: bool)\n */\n onEntering: PropTypes.func,\n\n /**\n * Callback fired after the \"entered\" status is applied. An extra parameter\n * `isAppearing` is supplied to indicate if the enter stage is occurring on the initial mount\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement, isAppearing: bool) -> void\n */\n onEntered: PropTypes.func,\n\n /**\n * Callback fired before the \"exiting\" status is applied.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement) -> void\n */\n onExit: PropTypes.func,\n\n /**\n * Callback fired after the \"exiting\" status is applied.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement) -> void\n */\n onExiting: PropTypes.func,\n\n /**\n * Callback fired after the \"exited\" status is applied.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed\n *\n * @type Function(node: HtmlElement) -> void\n */\n onExited: PropTypes.func\n} : {}; // Name the function so it is clearer in the documentation\n\nfunction noop() {}\n\nTransition.defaultProps = {\n in: false,\n mountOnEnter: false,\n unmountOnExit: false,\n appear: false,\n enter: true,\n exit: true,\n onEnter: noop,\n onEntering: noop,\n onEntered: noop,\n onExit: noop,\n onExiting: noop,\n onExited: noop\n};\nTransition.UNMOUNTED = UNMOUNTED;\nTransition.EXITED = EXITED;\nTransition.ENTERING = ENTERING;\nTransition.ENTERED = ENTERED;\nTransition.EXITING = EXITING;\nexport default Transition;","export const reflow = node => node.scrollTop;\nexport function getTransitionProps(props, options) {\n var _style$transitionDura, _style$transitionTimi;\n const {\n timeout,\n easing,\n style = {}\n } = props;\n return {\n duration: (_style$transitionDura = style.transitionDuration) != null ? _style$transitionDura : typeof timeout === 'number' ? timeout : timeout[options.mode] || 0,\n easing: (_style$transitionTimi = style.transitionTimingFunction) != null ? _style$transitionTimi : typeof easing === 'object' ? easing[options.mode] : easing,\n delay: style.transitionDelay\n };\n}","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"addEndListener\", \"appear\", \"children\", \"easing\", \"in\", \"onEnter\", \"onEntered\", \"onEntering\", \"onExit\", \"onExited\", \"onExiting\", \"style\", \"timeout\", \"TransitionComponent\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport { elementAcceptingRef, unstable_useTimeout as useTimeout } from '@mui/utils';\nimport { Transition } from 'react-transition-group';\nimport useTheme from '../styles/useTheme';\nimport { getTransitionProps, reflow } from '../transitions/utils';\nimport useForkRef from '../utils/useForkRef';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nfunction getScale(value) {\n return `scale(${value}, ${value ** 2})`;\n}\nconst styles = {\n entering: {\n opacity: 1,\n transform: getScale(1)\n },\n entered: {\n opacity: 1,\n transform: 'none'\n }\n};\n\n/*\n TODO v6: remove\n Conditionally apply a workaround for the CSS transition bug in Safari 15.4 / WebKit browsers.\n */\nconst isWebKit154 = typeof navigator !== 'undefined' && /^((?!chrome|android).)*(safari|mobile)/i.test(navigator.userAgent) && /(os |version\\/)15(.|_)4/i.test(navigator.userAgent);\n\n/**\n * The Grow transition is used by the [Tooltip](/material-ui/react-tooltip/) and\n * [Popover](/material-ui/react-popover/) components.\n * It uses [react-transition-group](https://github.com/reactjs/react-transition-group) internally.\n */\nconst Grow = /*#__PURE__*/React.forwardRef(function Grow(props, ref) {\n const {\n addEndListener,\n appear = true,\n children,\n easing,\n in: inProp,\n onEnter,\n onEntered,\n onEntering,\n onExit,\n onExited,\n onExiting,\n style,\n timeout = 'auto',\n // eslint-disable-next-line react/prop-types\n TransitionComponent = Transition\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const timer = useTimeout();\n const autoTimeout = React.useRef();\n const theme = useTheme();\n const nodeRef = React.useRef(null);\n const handleRef = useForkRef(nodeRef, children.ref, ref);\n const normalizedTransitionCallback = callback => maybeIsAppearing => {\n if (callback) {\n const node = nodeRef.current;\n\n // onEnterXxx and onExitXxx callbacks have a different arguments.length value.\n if (maybeIsAppearing === undefined) {\n callback(node);\n } else {\n callback(node, maybeIsAppearing);\n }\n }\n };\n const handleEntering = normalizedTransitionCallback(onEntering);\n const handleEnter = normalizedTransitionCallback((node, isAppearing) => {\n reflow(node); // So the animation always start from the start.\n\n const {\n duration: transitionDuration,\n delay,\n easing: transitionTimingFunction\n } = getTransitionProps({\n style,\n timeout,\n easing\n }, {\n mode: 'enter'\n });\n let duration;\n if (timeout === 'auto') {\n duration = theme.transitions.getAutoHeightDuration(node.clientHeight);\n autoTimeout.current = duration;\n } else {\n duration = transitionDuration;\n }\n node.style.transition = [theme.transitions.create('opacity', {\n duration,\n delay\n }), theme.transitions.create('transform', {\n duration: isWebKit154 ? duration : duration * 0.666,\n delay,\n easing: transitionTimingFunction\n })].join(',');\n if (onEnter) {\n onEnter(node, isAppearing);\n }\n });\n const handleEntered = normalizedTransitionCallback(onEntered);\n const handleExiting = normalizedTransitionCallback(onExiting);\n const handleExit = normalizedTransitionCallback(node => {\n const {\n duration: transitionDuration,\n delay,\n easing: transitionTimingFunction\n } = getTransitionProps({\n style,\n timeout,\n easing\n }, {\n mode: 'exit'\n });\n let duration;\n if (timeout === 'auto') {\n duration = theme.transitions.getAutoHeightDuration(node.clientHeight);\n autoTimeout.current = duration;\n } else {\n duration = transitionDuration;\n }\n node.style.transition = [theme.transitions.create('opacity', {\n duration,\n delay\n }), theme.transitions.create('transform', {\n duration: isWebKit154 ? duration : duration * 0.666,\n delay: isWebKit154 ? delay : delay || duration * 0.333,\n easing: transitionTimingFunction\n })].join(',');\n node.style.opacity = 0;\n node.style.transform = getScale(0.75);\n if (onExit) {\n onExit(node);\n }\n });\n const handleExited = normalizedTransitionCallback(onExited);\n const handleAddEndListener = next => {\n if (timeout === 'auto') {\n timer.start(autoTimeout.current || 0, next);\n }\n if (addEndListener) {\n // Old call signature before `react-transition-group` implemented `nodeRef`\n addEndListener(nodeRef.current, next);\n }\n };\n return /*#__PURE__*/_jsx(TransitionComponent, _extends({\n appear: appear,\n in: inProp,\n nodeRef: nodeRef,\n onEnter: handleEnter,\n onEntered: handleEntered,\n onEntering: handleEntering,\n onExit: handleExit,\n onExited: handleExited,\n onExiting: handleExiting,\n addEndListener: handleAddEndListener,\n timeout: timeout === 'auto' ? null : timeout\n }, other, {\n children: (state, childProps) => {\n return /*#__PURE__*/React.cloneElement(children, _extends({\n style: _extends({\n opacity: 0,\n transform: getScale(0.75),\n visibility: state === 'exited' && !inProp ? 'hidden' : undefined\n }, styles[state], style, children.props.style),\n ref: handleRef\n }, childProps));\n }\n }));\n});\nprocess.env.NODE_ENV !== \"production\" ? Grow.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the d.ts file and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * Add a custom transition end trigger. Called with the transitioning DOM\n * node and a done callback. Allows for more fine grained transition end\n * logic. Note: Timeouts are still used as a fallback if provided.\n */\n addEndListener: PropTypes.func,\n /**\n * Perform the enter transition when it first mounts if `in` is also `true`.\n * Set this to `false` to disable this behavior.\n * @default true\n */\n appear: PropTypes.bool,\n /**\n * A single child content element.\n */\n children: elementAcceptingRef.isRequired,\n /**\n * The transition timing function.\n * You may specify a single easing or a object containing enter and exit values.\n */\n easing: PropTypes.oneOfType([PropTypes.shape({\n enter: PropTypes.string,\n exit: PropTypes.string\n }), PropTypes.string]),\n /**\n * If `true`, the component will transition in.\n */\n in: PropTypes.bool,\n /**\n * @ignore\n */\n onEnter: PropTypes.func,\n /**\n * @ignore\n */\n onEntered: PropTypes.func,\n /**\n * @ignore\n */\n onEntering: PropTypes.func,\n /**\n * @ignore\n */\n onExit: PropTypes.func,\n /**\n * @ignore\n */\n onExited: PropTypes.func,\n /**\n * @ignore\n */\n onExiting: PropTypes.func,\n /**\n * @ignore\n */\n style: PropTypes.object,\n /**\n * The duration for the transition, in milliseconds.\n * You may specify a single timeout for all transitions, or individually with an object.\n *\n * Set to 'auto' to automatically calculate transition time based on height.\n * @default 'auto'\n */\n timeout: PropTypes.oneOfType([PropTypes.oneOf(['auto']), PropTypes.number, PropTypes.shape({\n appear: PropTypes.number,\n enter: PropTypes.number,\n exit: PropTypes.number\n })])\n} : void 0;\nGrow.muiSupportAuto = true;\nexport default Grow;","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"anchorEl\", \"component\", \"components\", \"componentsProps\", \"container\", \"disablePortal\", \"keepMounted\", \"modifiers\", \"open\", \"placement\", \"popperOptions\", \"popperRef\", \"transition\", \"slots\", \"slotProps\"];\nimport { Popper as BasePopper } from '@mui/base/Popper';\nimport { useThemeWithoutDefault as useTheme } from '@mui/system';\nimport { HTMLElementType, refType } from '@mui/utils';\nimport PropTypes from 'prop-types';\nimport * as React from 'react';\nimport { styled, useThemeProps } from '../styles';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nconst PopperRoot = styled(BasePopper, {\n name: 'MuiPopper',\n slot: 'Root',\n overridesResolver: (props, styles) => styles.root\n})({});\n\n/**\n *\n * Demos:\n *\n * - [Autocomplete](https://mui.com/material-ui/react-autocomplete/)\n * - [Menu](https://mui.com/material-ui/react-menu/)\n * - [Popper](https://mui.com/material-ui/react-popper/)\n *\n * API:\n *\n * - [Popper API](https://mui.com/material-ui/api/popper/)\n */\nconst Popper = /*#__PURE__*/React.forwardRef(function Popper(inProps, ref) {\n var _slots$root;\n const theme = useTheme();\n const props = useThemeProps({\n props: inProps,\n name: 'MuiPopper'\n });\n const {\n anchorEl,\n component,\n components,\n componentsProps,\n container,\n disablePortal,\n keepMounted,\n modifiers,\n open,\n placement,\n popperOptions,\n popperRef,\n transition,\n slots,\n slotProps\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const RootComponent = (_slots$root = slots == null ? void 0 : slots.root) != null ? _slots$root : components == null ? void 0 : components.Root;\n const otherProps = _extends({\n anchorEl,\n container,\n disablePortal,\n keepMounted,\n modifiers,\n open,\n placement,\n popperOptions,\n popperRef,\n transition\n }, other);\n return /*#__PURE__*/_jsx(PopperRoot, _extends({\n as: component,\n direction: theme == null ? void 0 : theme.direction,\n slots: {\n root: RootComponent\n },\n slotProps: slotProps != null ? slotProps : componentsProps\n }, otherProps, {\n ref: ref\n }));\n});\nprocess.env.NODE_ENV !== \"production\" ? Popper.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * An HTML element, [virtualElement](https://popper.js.org/docs/v2/virtual-elements/),\n * or a function that returns either.\n * It's used to set the position of the popper.\n * The return value will passed as the reference object of the Popper instance.\n */\n anchorEl: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.object, PropTypes.func]),\n /**\n * Popper render function or node.\n */\n children: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.node, PropTypes.func]),\n /**\n * The component used for the root node.\n * Either a string to use a HTML element or a component.\n */\n component: PropTypes.elementType,\n /**\n * The components used for each slot inside the Popper.\n * Either a string to use a HTML element or a component.\n * @default {}\n */\n components: PropTypes.shape({\n Root: PropTypes.elementType\n }),\n /**\n * The props used for each slot inside the Popper.\n * @default {}\n */\n componentsProps: PropTypes.shape({\n root: PropTypes.oneOfType([PropTypes.func, PropTypes.object])\n }),\n /**\n * An HTML element or function that returns one.\n * The `container` will have the portal children appended to it.\n *\n * You can also provide a callback, which is called in a React layout effect.\n * This lets you set the container from a ref, and also makes server-side rendering possible.\n *\n * By default, it uses the body of the top-level document object,\n * so it's simply `document.body` most of the time.\n */\n container: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.func]),\n /**\n * The `children` will be under the DOM hierarchy of the parent component.\n * @default false\n */\n disablePortal: PropTypes.bool,\n /**\n * Always keep the children in the DOM.\n * This prop can be useful in SEO situation or\n * when you want to maximize the responsiveness of the Popper.\n * @default false\n */\n keepMounted: PropTypes.bool,\n /**\n * Popper.js is based on a \"plugin-like\" architecture,\n * most of its features are fully encapsulated \"modifiers\".\n *\n * A modifier is a function that is called each time Popper.js needs to\n * compute the position of the popper.\n * For this reason, modifiers should be very performant to avoid bottlenecks.\n * To learn how to create a modifier, [read the modifiers documentation](https://popper.js.org/docs/v2/modifiers/).\n */\n modifiers: PropTypes.arrayOf(PropTypes.shape({\n data: PropTypes.object,\n effect: PropTypes.func,\n enabled: PropTypes.bool,\n fn: PropTypes.func,\n name: PropTypes.any,\n options: PropTypes.object,\n phase: PropTypes.oneOf(['afterMain', 'afterRead', 'afterWrite', 'beforeMain', 'beforeRead', 'beforeWrite', 'main', 'read', 'write']),\n requires: PropTypes.arrayOf(PropTypes.string),\n requiresIfExists: PropTypes.arrayOf(PropTypes.string)\n })),\n /**\n * If `true`, the component is shown.\n */\n open: PropTypes.bool.isRequired,\n /**\n * Popper placement.\n * @default 'bottom'\n */\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n /**\n * Options provided to the [`Popper.js`](https://popper.js.org/docs/v2/constructors/#options) instance.\n * @default {}\n */\n popperOptions: PropTypes.shape({\n modifiers: PropTypes.array,\n onFirstUpdate: PropTypes.func,\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n strategy: PropTypes.oneOf(['absolute', 'fixed'])\n }),\n /**\n * A ref that points to the used popper instance.\n */\n popperRef: refType,\n /**\n * The props used for each slot inside the Popper.\n * @default {}\n */\n slotProps: PropTypes.shape({\n root: PropTypes.oneOfType([PropTypes.func, PropTypes.object])\n }),\n /**\n * The components used for each slot inside the Popper.\n * Either a string to use a HTML element or a component.\n * @default {}\n */\n slots: PropTypes.shape({\n root: PropTypes.elementType\n }),\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Help supporting a react-transition-group/Transition component.\n * @default false\n */\n transition: PropTypes.bool\n} : void 0;\nexport default Popper;","import generateUtilityClasses from '@mui/utils/generateUtilityClasses';\nimport generateUtilityClass from '@mui/utils/generateUtilityClass';\nexport function getTooltipUtilityClass(slot) {\n return generateUtilityClass('MuiTooltip', slot);\n}\nconst tooltipClasses = generateUtilityClasses('MuiTooltip', ['popper', 'popperInteractive', 'popperArrow', 'popperClose', 'tooltip', 'tooltipArrow', 'touch', 'tooltipPlacementLeft', 'tooltipPlacementRight', 'tooltipPlacementTop', 'tooltipPlacementBottom', 'arrow']);\nexport default tooltipClasses;","'use client';\n\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nconst _excluded = [\"arrow\", \"children\", \"classes\", \"components\", \"componentsProps\", \"describeChild\", \"disableFocusListener\", \"disableHoverListener\", \"disableInteractive\", \"disableTouchListener\", \"enterDelay\", \"enterNextDelay\", \"enterTouchDelay\", \"followCursor\", \"id\", \"leaveDelay\", \"leaveTouchDelay\", \"onClose\", \"onOpen\", \"open\", \"placement\", \"PopperComponent\", \"PopperProps\", \"slotProps\", \"slots\", \"title\", \"TransitionComponent\", \"TransitionProps\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport clsx from 'clsx';\nimport { elementAcceptingRef, unstable_useTimeout as useTimeout, unstable_Timeout as Timeout } from '@mui/utils';\nimport { unstable_composeClasses as composeClasses, appendOwnerState } from '@mui/base';\nimport { alpha } from '@mui/system';\nimport styled from '../styles/styled';\nimport useTheme from '../styles/useTheme';\nimport useThemeProps from '../styles/useThemeProps';\nimport capitalize from '../utils/capitalize';\nimport Grow from '../Grow';\nimport Popper from '../Popper';\nimport useEventCallback from '../utils/useEventCallback';\nimport useForkRef from '../utils/useForkRef';\nimport useId from '../utils/useId';\nimport useIsFocusVisible from '../utils/useIsFocusVisible';\nimport useControlled from '../utils/useControlled';\nimport tooltipClasses, { getTooltipUtilityClass } from './tooltipClasses';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nimport { jsxs as _jsxs } from \"react/jsx-runtime\";\nfunction round(value) {\n return Math.round(value * 1e5) / 1e5;\n}\nconst useUtilityClasses = ownerState => {\n const {\n classes,\n disableInteractive,\n arrow,\n touch,\n placement\n } = ownerState;\n const slots = {\n popper: ['popper', !disableInteractive && 'popperInteractive', arrow && 'popperArrow'],\n tooltip: ['tooltip', arrow && 'tooltipArrow', touch && 'touch', `tooltipPlacement${capitalize(placement.split('-')[0])}`],\n arrow: ['arrow']\n };\n return composeClasses(slots, getTooltipUtilityClass, classes);\n};\nconst TooltipPopper = styled(Popper, {\n name: 'MuiTooltip',\n slot: 'Popper',\n overridesResolver: (props, styles) => {\n const {\n ownerState\n } = props;\n return [styles.popper, !ownerState.disableInteractive && styles.popperInteractive, ownerState.arrow && styles.popperArrow, !ownerState.open && styles.popperClose];\n }\n})(({\n theme,\n ownerState,\n open\n}) => _extends({\n zIndex: (theme.vars || theme).zIndex.tooltip,\n pointerEvents: 'none'\n}, !ownerState.disableInteractive && {\n pointerEvents: 'auto'\n}, !open && {\n pointerEvents: 'none'\n}, ownerState.arrow && {\n [`&[data-popper-placement*=\"bottom\"] .${tooltipClasses.arrow}`]: {\n top: 0,\n marginTop: '-0.71em',\n '&::before': {\n transformOrigin: '0 100%'\n }\n },\n [`&[data-popper-placement*=\"top\"] .${tooltipClasses.arrow}`]: {\n bottom: 0,\n marginBottom: '-0.71em',\n '&::before': {\n transformOrigin: '100% 0'\n }\n },\n [`&[data-popper-placement*=\"right\"] .${tooltipClasses.arrow}`]: _extends({}, !ownerState.isRtl ? {\n left: 0,\n marginLeft: '-0.71em'\n } : {\n right: 0,\n marginRight: '-0.71em'\n }, {\n height: '1em',\n width: '0.71em',\n '&::before': {\n transformOrigin: '100% 100%'\n }\n }),\n [`&[data-popper-placement*=\"left\"] .${tooltipClasses.arrow}`]: _extends({}, !ownerState.isRtl ? {\n right: 0,\n marginRight: '-0.71em'\n } : {\n left: 0,\n marginLeft: '-0.71em'\n }, {\n height: '1em',\n width: '0.71em',\n '&::before': {\n transformOrigin: '0 0'\n }\n })\n}));\nconst TooltipTooltip = styled('div', {\n name: 'MuiTooltip',\n slot: 'Tooltip',\n overridesResolver: (props, styles) => {\n const {\n ownerState\n } = props;\n return [styles.tooltip, ownerState.touch && styles.touch, ownerState.arrow && styles.tooltipArrow, styles[`tooltipPlacement${capitalize(ownerState.placement.split('-')[0])}`]];\n }\n})(({\n theme,\n ownerState\n}) => _extends({\n backgroundColor: theme.vars ? theme.vars.palette.Tooltip.bg : alpha(theme.palette.grey[700], 0.92),\n borderRadius: (theme.vars || theme).shape.borderRadius,\n color: (theme.vars || theme).palette.common.white,\n fontFamily: theme.typography.fontFamily,\n padding: '4px 8px',\n fontSize: theme.typography.pxToRem(11),\n maxWidth: 300,\n margin: 2,\n wordWrap: 'break-word',\n fontWeight: theme.typography.fontWeightMedium\n}, ownerState.arrow && {\n position: 'relative',\n margin: 0\n}, ownerState.touch && {\n padding: '8px 16px',\n fontSize: theme.typography.pxToRem(14),\n lineHeight: `${round(16 / 14)}em`,\n fontWeight: theme.typography.fontWeightRegular\n}, {\n [`.${tooltipClasses.popper}[data-popper-placement*=\"left\"] &`]: _extends({\n transformOrigin: 'right center'\n }, !ownerState.isRtl ? _extends({\n marginRight: '14px'\n }, ownerState.touch && {\n marginRight: '24px'\n }) : _extends({\n marginLeft: '14px'\n }, ownerState.touch && {\n marginLeft: '24px'\n })),\n [`.${tooltipClasses.popper}[data-popper-placement*=\"right\"] &`]: _extends({\n transformOrigin: 'left center'\n }, !ownerState.isRtl ? _extends({\n marginLeft: '14px'\n }, ownerState.touch && {\n marginLeft: '24px'\n }) : _extends({\n marginRight: '14px'\n }, ownerState.touch && {\n marginRight: '24px'\n })),\n [`.${tooltipClasses.popper}[data-popper-placement*=\"top\"] &`]: _extends({\n transformOrigin: 'center bottom',\n marginBottom: '14px'\n }, ownerState.touch && {\n marginBottom: '24px'\n }),\n [`.${tooltipClasses.popper}[data-popper-placement*=\"bottom\"] &`]: _extends({\n transformOrigin: 'center top',\n marginTop: '14px'\n }, ownerState.touch && {\n marginTop: '24px'\n })\n}));\nconst TooltipArrow = styled('span', {\n name: 'MuiTooltip',\n slot: 'Arrow',\n overridesResolver: (props, styles) => styles.arrow\n})(({\n theme\n}) => ({\n overflow: 'hidden',\n position: 'absolute',\n width: '1em',\n height: '0.71em' /* = width / sqrt(2) = (length of the hypotenuse) */,\n boxSizing: 'border-box',\n color: theme.vars ? theme.vars.palette.Tooltip.bg : alpha(theme.palette.grey[700], 0.9),\n '&::before': {\n content: '\"\"',\n margin: 'auto',\n display: 'block',\n width: '100%',\n height: '100%',\n backgroundColor: 'currentColor',\n transform: 'rotate(45deg)'\n }\n}));\nlet hystersisOpen = false;\nconst hystersisTimer = new Timeout();\nlet cursorPosition = {\n x: 0,\n y: 0\n};\nexport function testReset() {\n hystersisOpen = false;\n hystersisTimer.clear();\n}\nfunction composeEventHandler(handler, eventHandler) {\n return event => {\n if (eventHandler) {\n eventHandler(event);\n }\n handler(event);\n };\n}\n\n// TODO v6: Remove PopperComponent, PopperProps, TransitionComponent and TransitionProps.\nconst Tooltip = /*#__PURE__*/React.forwardRef(function Tooltip(inProps, ref) {\n var _ref, _slots$popper, _ref2, _ref3, _slots$transition, _ref4, _slots$tooltip, _ref5, _slots$arrow, _slotProps$popper, _ref6, _slotProps$popper2, _slotProps$transition, _slotProps$tooltip, _ref7, _slotProps$tooltip2, _slotProps$arrow, _ref8, _slotProps$arrow2;\n const props = useThemeProps({\n props: inProps,\n name: 'MuiTooltip'\n });\n const {\n arrow = false,\n children: childrenProp,\n components = {},\n componentsProps = {},\n describeChild = false,\n disableFocusListener = false,\n disableHoverListener = false,\n disableInteractive: disableInteractiveProp = false,\n disableTouchListener = false,\n enterDelay = 100,\n enterNextDelay = 0,\n enterTouchDelay = 700,\n followCursor = false,\n id: idProp,\n leaveDelay = 0,\n leaveTouchDelay = 1500,\n onClose,\n onOpen,\n open: openProp,\n placement = 'bottom',\n PopperComponent: PopperComponentProp,\n PopperProps = {},\n slotProps = {},\n slots = {},\n title,\n TransitionComponent: TransitionComponentProp = Grow,\n TransitionProps\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n\n // to prevent runtime errors, developers will need to provide a child as a React element anyway.\n const children = /*#__PURE__*/React.isValidElement(childrenProp) ? childrenProp : /*#__PURE__*/_jsx(\"span\", {\n children: childrenProp\n });\n const theme = useTheme();\n const isRtl = theme.direction === 'rtl';\n const [childNode, setChildNode] = React.useState();\n const [arrowRef, setArrowRef] = React.useState(null);\n const ignoreNonTouchEvents = React.useRef(false);\n const disableInteractive = disableInteractiveProp || followCursor;\n const closeTimer = useTimeout();\n const enterTimer = useTimeout();\n const leaveTimer = useTimeout();\n const touchTimer = useTimeout();\n const [openState, setOpenState] = useControlled({\n controlled: openProp,\n default: false,\n name: 'Tooltip',\n state: 'open'\n });\n let open = openState;\n if (process.env.NODE_ENV !== 'production') {\n // eslint-disable-next-line react-hooks/rules-of-hooks\n const {\n current: isControlled\n } = React.useRef(openProp !== undefined);\n\n // eslint-disable-next-line react-hooks/rules-of-hooks\n React.useEffect(() => {\n if (childNode && childNode.disabled && !isControlled && title !== '' && childNode.tagName.toLowerCase() === 'button') {\n console.error(['MUI: You are providing a disabled `button` child to the Tooltip component.', 'A disabled element does not fire events.', \"Tooltip needs to listen to the child element's events to display the title.\", '', 'Add a simple wrapper element, such as a `span`.'].join('\\n'));\n }\n }, [title, childNode, isControlled]);\n }\n const id = useId(idProp);\n const prevUserSelect = React.useRef();\n const stopTouchInteraction = useEventCallback(() => {\n if (prevUserSelect.current !== undefined) {\n document.body.style.WebkitUserSelect = prevUserSelect.current;\n prevUserSelect.current = undefined;\n }\n touchTimer.clear();\n });\n React.useEffect(() => stopTouchInteraction, [stopTouchInteraction]);\n const handleOpen = event => {\n hystersisTimer.clear();\n hystersisOpen = true;\n\n // The mouseover event will trigger for every nested element in the tooltip.\n // We can skip rerendering when the tooltip is already open.\n // We are using the mouseover event instead of the mouseenter event to fix a hide/show issue.\n setOpenState(true);\n if (onOpen && !open) {\n onOpen(event);\n }\n };\n const handleClose = useEventCallback(\n /**\n * @param {React.SyntheticEvent | Event} event\n */\n event => {\n hystersisTimer.start(800 + leaveDelay, () => {\n hystersisOpen = false;\n });\n setOpenState(false);\n if (onClose && open) {\n onClose(event);\n }\n closeTimer.start(theme.transitions.duration.shortest, () => {\n ignoreNonTouchEvents.current = false;\n });\n });\n const handleEnter = event => {\n if (ignoreNonTouchEvents.current && event.type !== 'touchstart') {\n return;\n }\n\n // Remove the title ahead of time.\n // We don't want to wait for the next render commit.\n // We would risk displaying two tooltips at the same time (native + this one).\n if (childNode) {\n childNode.removeAttribute('title');\n }\n enterTimer.clear();\n leaveTimer.clear();\n if (enterDelay || hystersisOpen && enterNextDelay) {\n enterTimer.start(hystersisOpen ? enterNextDelay : enterDelay, () => {\n handleOpen(event);\n });\n } else {\n handleOpen(event);\n }\n };\n const handleLeave = event => {\n enterTimer.clear();\n leaveTimer.start(leaveDelay, () => {\n handleClose(event);\n });\n };\n const {\n isFocusVisibleRef,\n onBlur: handleBlurVisible,\n onFocus: handleFocusVisible,\n ref: focusVisibleRef\n } = useIsFocusVisible();\n // We don't necessarily care about the focusVisible state (which is safe to access via ref anyway).\n // We just need to re-render the Tooltip if the focus-visible state changes.\n const [, setChildIsFocusVisible] = React.useState(false);\n const handleBlur = event => {\n handleBlurVisible(event);\n if (isFocusVisibleRef.current === false) {\n setChildIsFocusVisible(false);\n handleLeave(event);\n }\n };\n const handleFocus = event => {\n // Workaround for https://github.com/facebook/react/issues/7769\n // The autoFocus of React might trigger the event before the componentDidMount.\n // We need to account for this eventuality.\n if (!childNode) {\n setChildNode(event.currentTarget);\n }\n handleFocusVisible(event);\n if (isFocusVisibleRef.current === true) {\n setChildIsFocusVisible(true);\n handleEnter(event);\n }\n };\n const detectTouchStart = event => {\n ignoreNonTouchEvents.current = true;\n const childrenProps = children.props;\n if (childrenProps.onTouchStart) {\n childrenProps.onTouchStart(event);\n }\n };\n const handleMouseOver = handleEnter;\n const handleMouseLeave = handleLeave;\n const handleTouchStart = event => {\n detectTouchStart(event);\n leaveTimer.clear();\n closeTimer.clear();\n stopTouchInteraction();\n prevUserSelect.current = document.body.style.WebkitUserSelect;\n // Prevent iOS text selection on long-tap.\n document.body.style.WebkitUserSelect = 'none';\n touchTimer.start(enterTouchDelay, () => {\n document.body.style.WebkitUserSelect = prevUserSelect.current;\n handleEnter(event);\n });\n };\n const handleTouchEnd = event => {\n if (children.props.onTouchEnd) {\n children.props.onTouchEnd(event);\n }\n stopTouchInteraction();\n leaveTimer.start(leaveTouchDelay, () => {\n handleClose(event);\n });\n };\n React.useEffect(() => {\n if (!open) {\n return undefined;\n }\n\n /**\n * @param {KeyboardEvent} nativeEvent\n */\n function handleKeyDown(nativeEvent) {\n // IE11, Edge (prior to using Bink?) use 'Esc'\n if (nativeEvent.key === 'Escape' || nativeEvent.key === 'Esc') {\n handleClose(nativeEvent);\n }\n }\n document.addEventListener('keydown', handleKeyDown);\n return () => {\n document.removeEventListener('keydown', handleKeyDown);\n };\n }, [handleClose, open]);\n const handleRef = useForkRef(children.ref, focusVisibleRef, setChildNode, ref);\n\n // There is no point in displaying an empty tooltip.\n // So we exclude all falsy values, except 0, which is valid.\n if (!title && title !== 0) {\n open = false;\n }\n const popperRef = React.useRef();\n const handleMouseMove = event => {\n const childrenProps = children.props;\n if (childrenProps.onMouseMove) {\n childrenProps.onMouseMove(event);\n }\n cursorPosition = {\n x: event.clientX,\n y: event.clientY\n };\n if (popperRef.current) {\n popperRef.current.update();\n }\n };\n const nameOrDescProps = {};\n const titleIsString = typeof title === 'string';\n if (describeChild) {\n nameOrDescProps.title = !open && titleIsString && !disableHoverListener ? title : null;\n nameOrDescProps['aria-describedby'] = open ? id : null;\n } else {\n nameOrDescProps['aria-label'] = titleIsString ? title : null;\n nameOrDescProps['aria-labelledby'] = open && !titleIsString ? id : null;\n }\n const childrenProps = _extends({}, nameOrDescProps, other, children.props, {\n className: clsx(other.className, children.props.className),\n onTouchStart: detectTouchStart,\n ref: handleRef\n }, followCursor ? {\n onMouseMove: handleMouseMove\n } : {});\n if (process.env.NODE_ENV !== 'production') {\n childrenProps['data-mui-internal-clone-element'] = true;\n\n // eslint-disable-next-line react-hooks/rules-of-hooks\n React.useEffect(() => {\n if (childNode && !childNode.getAttribute('data-mui-internal-clone-element')) {\n console.error(['MUI: The `children` component of the Tooltip is not forwarding its props correctly.', 'Please make sure that props are spread on the same element that the ref is applied to.'].join('\\n'));\n }\n }, [childNode]);\n }\n const interactiveWrapperListeners = {};\n if (!disableTouchListener) {\n childrenProps.onTouchStart = handleTouchStart;\n childrenProps.onTouchEnd = handleTouchEnd;\n }\n if (!disableHoverListener) {\n childrenProps.onMouseOver = composeEventHandler(handleMouseOver, childrenProps.onMouseOver);\n childrenProps.onMouseLeave = composeEventHandler(handleMouseLeave, childrenProps.onMouseLeave);\n if (!disableInteractive) {\n interactiveWrapperListeners.onMouseOver = handleMouseOver;\n interactiveWrapperListeners.onMouseLeave = handleMouseLeave;\n }\n }\n if (!disableFocusListener) {\n childrenProps.onFocus = composeEventHandler(handleFocus, childrenProps.onFocus);\n childrenProps.onBlur = composeEventHandler(handleBlur, childrenProps.onBlur);\n if (!disableInteractive) {\n interactiveWrapperListeners.onFocus = handleFocus;\n interactiveWrapperListeners.onBlur = handleBlur;\n }\n }\n if (process.env.NODE_ENV !== 'production') {\n if (children.props.title) {\n console.error(['MUI: You have provided a `title` prop to the child of .', `Remove this title prop \\`${children.props.title}\\` or the Tooltip component.`].join('\\n'));\n }\n }\n const popperOptions = React.useMemo(() => {\n var _PopperProps$popperOp;\n let tooltipModifiers = [{\n name: 'arrow',\n enabled: Boolean(arrowRef),\n options: {\n element: arrowRef,\n padding: 4\n }\n }];\n if ((_PopperProps$popperOp = PopperProps.popperOptions) != null && _PopperProps$popperOp.modifiers) {\n tooltipModifiers = tooltipModifiers.concat(PopperProps.popperOptions.modifiers);\n }\n return _extends({}, PopperProps.popperOptions, {\n modifiers: tooltipModifiers\n });\n }, [arrowRef, PopperProps]);\n const ownerState = _extends({}, props, {\n isRtl,\n arrow,\n disableInteractive,\n placement,\n PopperComponentProp,\n touch: ignoreNonTouchEvents.current\n });\n const classes = useUtilityClasses(ownerState);\n const PopperComponent = (_ref = (_slots$popper = slots.popper) != null ? _slots$popper : components.Popper) != null ? _ref : TooltipPopper;\n const TransitionComponent = (_ref2 = (_ref3 = (_slots$transition = slots.transition) != null ? _slots$transition : components.Transition) != null ? _ref3 : TransitionComponentProp) != null ? _ref2 : Grow;\n const TooltipComponent = (_ref4 = (_slots$tooltip = slots.tooltip) != null ? _slots$tooltip : components.Tooltip) != null ? _ref4 : TooltipTooltip;\n const ArrowComponent = (_ref5 = (_slots$arrow = slots.arrow) != null ? _slots$arrow : components.Arrow) != null ? _ref5 : TooltipArrow;\n const popperProps = appendOwnerState(PopperComponent, _extends({}, PopperProps, (_slotProps$popper = slotProps.popper) != null ? _slotProps$popper : componentsProps.popper, {\n className: clsx(classes.popper, PopperProps == null ? void 0 : PopperProps.className, (_ref6 = (_slotProps$popper2 = slotProps.popper) != null ? _slotProps$popper2 : componentsProps.popper) == null ? void 0 : _ref6.className)\n }), ownerState);\n const transitionProps = appendOwnerState(TransitionComponent, _extends({}, TransitionProps, (_slotProps$transition = slotProps.transition) != null ? _slotProps$transition : componentsProps.transition), ownerState);\n const tooltipProps = appendOwnerState(TooltipComponent, _extends({}, (_slotProps$tooltip = slotProps.tooltip) != null ? _slotProps$tooltip : componentsProps.tooltip, {\n className: clsx(classes.tooltip, (_ref7 = (_slotProps$tooltip2 = slotProps.tooltip) != null ? _slotProps$tooltip2 : componentsProps.tooltip) == null ? void 0 : _ref7.className)\n }), ownerState);\n const tooltipArrowProps = appendOwnerState(ArrowComponent, _extends({}, (_slotProps$arrow = slotProps.arrow) != null ? _slotProps$arrow : componentsProps.arrow, {\n className: clsx(classes.arrow, (_ref8 = (_slotProps$arrow2 = slotProps.arrow) != null ? _slotProps$arrow2 : componentsProps.arrow) == null ? void 0 : _ref8.className)\n }), ownerState);\n return /*#__PURE__*/_jsxs(React.Fragment, {\n children: [/*#__PURE__*/React.cloneElement(children, childrenProps), /*#__PURE__*/_jsx(PopperComponent, _extends({\n as: PopperComponentProp != null ? PopperComponentProp : Popper,\n placement: placement,\n anchorEl: followCursor ? {\n getBoundingClientRect: () => ({\n top: cursorPosition.y,\n left: cursorPosition.x,\n right: cursorPosition.x,\n bottom: cursorPosition.y,\n width: 0,\n height: 0\n })\n } : childNode,\n popperRef: popperRef,\n open: childNode ? open : false,\n id: id,\n transition: true\n }, interactiveWrapperListeners, popperProps, {\n popperOptions: popperOptions,\n children: ({\n TransitionProps: TransitionPropsInner\n }) => /*#__PURE__*/_jsx(TransitionComponent, _extends({\n timeout: theme.transitions.duration.shorter\n }, TransitionPropsInner, transitionProps, {\n children: /*#__PURE__*/_jsxs(TooltipComponent, _extends({}, tooltipProps, {\n children: [title, arrow ? /*#__PURE__*/_jsx(ArrowComponent, _extends({}, tooltipArrowProps, {\n ref: setArrowRef\n })) : null]\n }))\n }))\n }))]\n });\n});\nprocess.env.NODE_ENV !== \"production\" ? Tooltip.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the d.ts file and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * If `true`, adds an arrow to the tooltip.\n * @default false\n */\n arrow: PropTypes.bool,\n /**\n * Tooltip reference element.\n */\n children: elementAcceptingRef.isRequired,\n /**\n * Override or extend the styles applied to the component.\n */\n classes: PropTypes.object,\n /**\n * @ignore\n */\n className: PropTypes.string,\n /**\n * The components used for each slot inside.\n *\n * This prop is an alias for the `slots` prop.\n * It's recommended to use the `slots` prop instead.\n *\n * @default {}\n */\n components: PropTypes.shape({\n Arrow: PropTypes.elementType,\n Popper: PropTypes.elementType,\n Tooltip: PropTypes.elementType,\n Transition: PropTypes.elementType\n }),\n /**\n * The extra props for the slot components.\n * You can override the existing props or add new ones.\n *\n * This prop is an alias for the `slotProps` prop.\n * It's recommended to use the `slotProps` prop instead, as `componentsProps` will be deprecated in the future.\n *\n * @default {}\n */\n componentsProps: PropTypes.shape({\n arrow: PropTypes.object,\n popper: PropTypes.object,\n tooltip: PropTypes.object,\n transition: PropTypes.object\n }),\n /**\n * Set to `true` if the `title` acts as an accessible description.\n * By default the `title` acts as an accessible label for the child.\n * @default false\n */\n describeChild: PropTypes.bool,\n /**\n * Do not respond to focus-visible events.\n * @default false\n */\n disableFocusListener: PropTypes.bool,\n /**\n * Do not respond to hover events.\n * @default false\n */\n disableHoverListener: PropTypes.bool,\n /**\n * Makes a tooltip not interactive, i.e. it will close when the user\n * hovers over the tooltip before the `leaveDelay` is expired.\n * @default false\n */\n disableInteractive: PropTypes.bool,\n /**\n * Do not respond to long press touch events.\n * @default false\n */\n disableTouchListener: PropTypes.bool,\n /**\n * The number of milliseconds to wait before showing the tooltip.\n * This prop won't impact the enter touch delay (`enterTouchDelay`).\n * @default 100\n */\n enterDelay: PropTypes.number,\n /**\n * The number of milliseconds to wait before showing the tooltip when one was already recently opened.\n * @default 0\n */\n enterNextDelay: PropTypes.number,\n /**\n * The number of milliseconds a user must touch the element before showing the tooltip.\n * @default 700\n */\n enterTouchDelay: PropTypes.number,\n /**\n * If `true`, the tooltip follow the cursor over the wrapped element.\n * @default false\n */\n followCursor: PropTypes.bool,\n /**\n * This prop is used to help implement the accessibility logic.\n * If you don't provide this prop. It falls back to a randomly generated id.\n */\n id: PropTypes.string,\n /**\n * The number of milliseconds to wait before hiding the tooltip.\n * This prop won't impact the leave touch delay (`leaveTouchDelay`).\n * @default 0\n */\n leaveDelay: PropTypes.number,\n /**\n * The number of milliseconds after the user stops touching an element before hiding the tooltip.\n * @default 1500\n */\n leaveTouchDelay: PropTypes.number,\n /**\n * Callback fired when the component requests to be closed.\n *\n * @param {React.SyntheticEvent} event The event source of the callback.\n */\n onClose: PropTypes.func,\n /**\n * Callback fired when the component requests to be open.\n *\n * @param {React.SyntheticEvent} event The event source of the callback.\n */\n onOpen: PropTypes.func,\n /**\n * If `true`, the component is shown.\n */\n open: PropTypes.bool,\n /**\n * Tooltip placement.\n * @default 'bottom'\n */\n placement: PropTypes.oneOf(['bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n /**\n * The component used for the popper.\n * @default Popper\n */\n PopperComponent: PropTypes.elementType,\n /**\n * Props applied to the [`Popper`](/material-ui/api/popper/) element.\n * @default {}\n */\n PopperProps: PropTypes.object,\n /**\n * The extra props for the slot components.\n * You can override the existing props or add new ones.\n *\n * This prop is an alias for the `componentsProps` prop, which will be deprecated in the future.\n *\n * @default {}\n */\n slotProps: PropTypes.shape({\n arrow: PropTypes.object,\n popper: PropTypes.object,\n tooltip: PropTypes.object,\n transition: PropTypes.object\n }),\n /**\n * The components used for each slot inside.\n *\n * This prop is an alias for the `components` prop, which will be deprecated in the future.\n *\n * @default {}\n */\n slots: PropTypes.shape({\n arrow: PropTypes.elementType,\n popper: PropTypes.elementType,\n tooltip: PropTypes.elementType,\n transition: PropTypes.elementType\n }),\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Tooltip title. Zero-length titles string, undefined, null and false are never displayed.\n */\n title: PropTypes.node,\n /**\n * The component used for the transition.\n * [Follow this guide](/material-ui/transitions/#transitioncomponent-prop) to learn more about the requirements for this component.\n * @default Grow\n */\n TransitionComponent: PropTypes.elementType,\n /**\n * Props applied to the transition element.\n * By default, the element is based on this [`Transition`](http://reactcommunity.org/react-transition-group/transition/) component.\n */\n TransitionProps: PropTypes.object\n} : void 0;\nexport default Tooltip;","import '@/components/mui/menu-item.component.css';\nimport ArrowRightIcon from '@mui/icons-material/ArrowRight';\nimport {\n ListItemIcon as MuiListItemIcon,\n ListItemText as MuiListItemText,\n MenuItem as MuiMenuItem,\n} from '@mui/material';\nimport Tooltip from '@mui/material/Tooltip';\nimport { Localized, ReferencedItem, SingleColumnMenu } from 'platform-bible-utils';\nimport { MouseEvent, PropsWithChildren } from 'react';\n\ntype MenuItemInfoBase = {\n /** Text (displayable in the UI) as the name of the menu item */\n label: string;\n /** Text to display when the mouse hovers over the menu item */\n tooltip?: string;\n};\n\nexport type Command = MenuItemInfoBase & {\n /** Command to execute (string.string) */\n command: string;\n};\n\ntype SubMenu = MenuItemInfoBase & {\n /** Command to execute (string.string) */\n items: MenuItemInfo[];\n};\n\nexport interface CommandHandler {\n (command: Command): void;\n}\n\nexport type MenuPropsBase = {\n /*\n * The JSON defining the menu whose items are to be rendered. This will typically be one of the\n * menus in the \"defs\" in a Platform.Bible menu (see PlatformMenus). The schema for this is\n * menuDocumentSchema (at the end of menus.model.ts). Note that while this is a\n * \"SingleColumnMenu\", somewhat bizarrely, a MultiColumnMenu is a SingleColumnMenu, so it really\n * could be a MultiColumnMenu, in which case, column had better be defined so it can be used\n * to filter out the actual groups and items to display on the column.\n */\n menuDefinition: Localized;\n\n commandHandler: CommandHandler;\n\n /**\n * Additional action to perform when any menu item is clicked. Allows the caller to handle event\n * (e.g., to close the menu).\n */\n onClick?: (event: MouseEvent) => void;\n};\n\nexport type MenuItemListProps = MenuPropsBase & {\n /** Optional unique (column) identifier */\n columnId?: ReferencedItem;\n};\n\nexport type MenuItemProps = Omit &\n PropsWithChildren<{\n /** Optional unique identifier */\n id?: string;\n\n onClick: (event: MouseEvent) => void;\n }>;\n\ntype MenuItemInfo = (Command | SubMenu) & {\n /**\n * If specified, menu item will be inset if it does not have a leading icon.\n *\n * @default true\n */\n allowForLeadingIcons?: boolean;\n /**\n * If specified, the path to the icon image to display on the leading side of the menu text.\n *\n * @default undefined (no leading icon will be shown)\n */\n iconPathBefore?: string;\n /**\n * If specified, the path to the icon image to display on the trailing side of the menu text.\n *\n * @default undefined (no trailing icon will be shown)\n */\n iconPathAfter?: string;\n /**\n * If true, list item is focused during the first mount\n *\n * @default false\n */\n hasAutoFocus?: boolean;\n\n /** Additional css classes to help with unique styling of the menu item */\n className?: string;\n\n /**\n * If true, the menu item will appear disabled and it will not respond to clicks or mouse hovers.\n *\n * @default false\n */\n isDisabled?: boolean;\n\n /**\n * If true, compact vertical padding designed for keyboard and mouse input is used.\n *\n * @default true\n */\n isDense?: boolean;\n\n /**\n * If true, a right-arrow icon will be displayed (iconPathAfter, if specified, will be ignored).\n *\n * @default false\n */\n isSubMenuParent?: boolean;\n\n /**\n * If true, the left and right padding is removed\n *\n * @default false\n */\n hasDisabledGutters?: boolean;\n\n /**\n * If true, a 1px light border is added to bottom of menu item\n *\n * @default false\n */\n hasDivider?: boolean;\n\n /** Help identify which element has keyboard focus */\n focusVisibleClassName?: string;\n\n /** If it's a submenu, it should have the items property */\n items?: MenuItemInfo[];\n};\n\nfunction getIcon(icon: string | undefined, menuLabel: string, leading: boolean) {\n return icon ? (\n \n {`${leading\n \n ) : undefined;\n}\n\nexport default function MenuItem(props: MenuItemProps) {\n const {\n onClick,\n label,\n tooltip,\n allowForLeadingIcons = true,\n iconPathBefore = undefined,\n iconPathAfter = undefined,\n hasAutoFocus = false,\n className,\n isDisabled = false,\n isDense = true,\n isSubMenuParent = false,\n hasDisabledGutters = false,\n hasDivider = false,\n focusVisibleClassName,\n id,\n children,\n } = props;\n\n const menuItem = (\n \n {label ? (\n <>\n {getIcon(iconPathBefore, label, true)}\n \n {isSubMenuParent ? (\n \n \n \n ) : (\n getIcon(iconPathAfter, label, false)\n )}\n \n ) : (\n children\n )}\n \n );\n\n return tooltip ? (\n \n
    {menuItem}
    \n
    \n ) : (\n menuItem\n );\n}\n","import MenuItem, {\n MenuItemListProps,\n MenuItemProps,\n MenuPropsBase,\n} from '@/components/mui/menu-item.component';\nimport { Menu } from '@mui/material';\nimport {\n Localized,\n MenuGroupDetailsInSubMenu,\n MenuItemContainingCommand,\n MenuItemContainingSubmenu,\n OrderedExtensibleContainer,\n ReferencedItem,\n SingleColumnMenu,\n} from 'platform-bible-utils';\nimport { MouseEvent, useMemo, useState } from 'react';\n\n/**\n * All the exported types in this file should be regarded as \"internal\" (i.e., they should not be\n * exposed via index.ts).\n */\n\nexport type GroupedMenuPropsBase = MenuPropsBase & {\n /** Optional unique (column) identifier */\n columnId?: ReferencedItem;\n};\n\nexport type GroupedMenuItemListProps = MenuItemListProps & {\n /**\n * If the menuDefinition includes \"top-level\" groups (i.e., those that belong to a column as\n * opposed to those that belong to a submenu) that should not be included in the list, then this\n * array specifies which groups to include. Likewise, for a submenu, this list indicates which\n * groups are pertinent for that submenu. So then for a context menu this property need not be\n * specified since it is a top-level menu based on a \"true\" SingleColumnMenu (i.e., one that is\n * not a MultiColumnMenu).\n */\n includedGroups?: {\n id: string;\n group: Localized;\n }[];\n};\n\ninterface ItemInfo {\n item: Localized;\n isLastItemInGroup: boolean;\n}\n\ntype SubMenuProps = MenuPropsBase & {\n parentMenuItem: Localized;\n parentItemProps: Omit, 'iconPathAfter'>;\n};\n\nfunction getAllGroups(menuDefinition: Localized) {\n const groupEntries = Object.entries(menuDefinition.groups);\n // Convert array of entries to array of objects with id and group properties\n return groupEntries.map(([key, value]) => ({ id: key, group: value }));\n}\n\nfunction SubMenu(props: SubMenuProps) {\n const [anchorEl, setAnchorEl] = useState(undefined);\n\n const { parentMenuItem, parentItemProps, menuDefinition } = props;\n\n const handleParentMenuItemClick = (event: MouseEvent) => {\n setAnchorEl(event.currentTarget);\n };\n\n const handleClose = () => {\n setAnchorEl(undefined);\n };\n\n const renderSubMenuItems = () => {\n let includedGroups = getAllGroups(menuDefinition).filter((g) => 'menuItem' in g.group);\n\n // Ensure valid parent menu was provided. (If not, submenu will contain all groups!)\n if (!parentMenuItem?.id) throw new Error('A valid parent menu item is required for submenus.');\n\n // When laying out a submenu, only include groups associated with the provided parent menu.\n // Note: without the (annoying) redundant check that the included groups\n // have the menuItem field, TS doesn't think it exists.\n includedGroups = includedGroups.filter(\n (group) => 'menuItem' in group.group && group.group.menuItem === parentMenuItem.id,\n );\n\n return ;\n };\n\n return (\n <>\n \n \n {renderSubMenuItems()}\n \n \n );\n}\n\nconst getOrderedGroupItems = (\n groupId: string,\n allItems: Localized[],\n) => {\n // Filter items that belong to the specified group\n const itemsForGroup = allItems.filter((item) => item.group === groupId);\n // Sort items based on order\n const sortedItems = itemsForGroup.sort((a, b) => (a.order || 0) - (b.order || 0));\n return sortedItems;\n};\n\n/**\n * This component is internal; it does not need to be exposed to the outside world since it is not\n * useful on its own. It is used to generate and lay out the MenuItems that appear either on a\n * top-level menu (in a GridMenu or ContextMenu) or in a submenu.\n */\nexport default function GroupedMenuItemList(menuProps: GroupedMenuItemListProps) {\n const { menuDefinition, onClick, commandHandler, includedGroups } = menuProps;\n\n const { items, allowForLeadingIcons } = useMemo(() => {\n const groupsToInclude =\n includedGroups && includedGroups.length > 0\n ? includedGroups\n : // We're apparently laying out a single-column menu (presumably a context menu). In this\n // case, all groups should be included except ones that belong to a submenu.\n getAllGroups(menuDefinition).filter((g) => !('menuItem' in g.group));\n\n const sortedGroups = Object.values(groupsToInclude).sort(\n (a, b) => (a.group.order || 0) - (b.group.order || 0),\n );\n\n const itemArray: ItemInfo[] = [];\n\n sortedGroups.forEach((group) => {\n getOrderedGroupItems(group.id, menuDefinition.items).forEach((item) =>\n itemArray.push({ item, isLastItemInGroup: false }),\n );\n if (itemArray.length > 0) itemArray[itemArray.length - 1].isLastItemInGroup = true;\n });\n\n // No divider after last item in final group.\n if (itemArray.length > 0) itemArray[itemArray.length - 1].isLastItemInGroup = false;\n\n const allowSpaceForLeadingIcons = itemArray.some(\n (i) => 'iconPathBefore' in i.item && i.item.iconPathBefore,\n );\n\n return { items: itemArray, allowForLeadingIcons: allowSpaceForLeadingIcons };\n }, [includedGroups, menuDefinition]);\n\n // Create props for MenuItem component including setting hasDivider for the last item in a group\n const createMenuItemProps = ({ item, isLastItemInGroup }: ItemInfo) => {\n const menuItemProps = {\n className: 'papi-menu-item',\n label: item.label,\n tooltip: item.tooltip,\n iconPathBefore: 'iconPathBefore' in item ? item.iconPathBefore : undefined,\n iconPathAfter: 'iconPathAfter' in item ? item.iconPathAfter : undefined,\n hasDivider: isLastItemInGroup, // Set hasDivider to true for the last item in a group\n allowForLeadingIcons,\n };\n\n return menuItemProps;\n };\n\n const [firstItem] = items;\n\n if (!firstItem) return
    ;\n\n const divKey = firstItem.item.group;\n\n return (\n
    \n {items.map((itemInfo, index) => {\n const { item } = itemInfo;\n const menuItemProps = createMenuItemProps(itemInfo);\n if ('command' in item) {\n const key = item.group + index;\n return (\n ) => {\n onClick?.(event);\n commandHandler(item);\n }}\n {...menuItemProps}\n />\n );\n }\n return (\n \n );\n })}\n
    \n );\n}\n","import GroupedMenuItemList from '@/components/mui/grouped-menu-item-list.component';\nimport { MenuItemListProps } from '@/components/mui/menu-item.component';\nimport { MultiColumnMenu } from 'platform-bible-utils';\n\n/**\n * This component is internal; it does not need to be exposed to the outside world since it is not\n * useful on its own. Use either GridMenu or ContextMenu.\n */\nexport default function TopLevelMenu(props: MenuItemListProps) {\n const { menuDefinition, columnId } = props;\n\n const groupEntries = Object.entries(menuDefinition.groups);\n // Convert array of entries to array of objects with id and group properties\n const groups = groupEntries.map(([key, value]) => ({ id: key, group: value }));\n let includedGroups = groups.filter((g) => 'column' in g.group);\n\n // Check if column is provided and menuDefinition is a MultiColumnMenu\n if (\n columnId &&\n 'columns' in menuDefinition &&\n // Without this type assertion, TS doesn't know what columns is.\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n (menuDefinition as MultiColumnMenu).columns[columnId]\n ) {\n // When laying out a single column in a MultiColumnMenu, only include groups associated with\n // the provided column. Note: without the (annoying) redundant check that the included groups\n // have the colum field, TS doesn't think it exists.\n includedGroups = includedGroups.filter(\n (g) => 'column' in g.group && g.group.column === columnId,\n );\n }\n\n return ;\n}\n","import '@/components/mui/grid-menu.component.css';\nimport { GroupedMenuPropsBase } from '@/components/mui/grouped-menu-item-list.component';\nimport { CommandHandler } from '@/components/mui/menu-item.component';\nimport TopLevelMenu from '@/components/mui/top-level-menu.component';\nimport { Grid, List } from '@mui/material';\nimport {\n Localized,\n MenuColumnWithHeader,\n MultiColumnMenu,\n ReferencedItem,\n} from 'platform-bible-utils';\nimport { useMemo } from 'react';\n\ntype ColumnInfo = {\n /*\n * The ID (`${string}.${string}`) of a specific menu column.\n */\n id: ReferencedItem;\n\n /*\n * Metadata (label, order, etc.) for a specific menu column.\n */\n metadata: Localized;\n};\n\ntype MenuColumnProps = ColumnInfo &\n GroupedMenuPropsBase & {\n /** Additional css classes to help with unique styling of the menu column */\n className?: string;\n };\n\nexport type GridMenuInfo = {\n /** The menu object containing information about the columns, groups, and items to display. */\n multiColumnMenu: Localized;\n};\n\nexport type GridMenuProps = GridMenuInfo & {\n /** Optional unique identifier */\n id?: string;\n\n commandHandler: CommandHandler;\n\n /** Additional css classes to help with unique styling of the grid menu */\n className?: string;\n};\n\nfunction MenuColumn({\n commandHandler,\n menuDefinition,\n id,\n metadata,\n onClick,\n className,\n}: MenuColumnProps) {\n return (\n \n

    \n {metadata.label}\n

    \n {/* It would seem as though this List component were unnecessary, since it only contains one\n thing, but the \"dense\" property does affect the layout of the items (in a way I don't fully\n understand). There might be a better way. */}\n \n \n \n \n );\n}\n\nexport default function GridMenu({\n commandHandler,\n className,\n multiColumnMenu,\n id,\n}: GridMenuProps) {\n const { columns } = multiColumnMenu;\n\n const sortedColumns = useMemo(() => {\n const columnNumbers = new Map();\n Object.getOwnPropertyNames(columns).forEach((columnName: string) => {\n // We know for sure there is a (boolean) property 'isExtensible' that we are not interested in.\n if (columnName === 'isExtensible') return;\n // TS doesn't allow `columnName` above to be a ReferencedItem even though the type says it is\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const columnId = columnName as ReferencedItem;\n const column = columns[columnId];\n // As of right now (and hopefully forever after), all remaining properties of the\n // ColumnsWithHeaders object are columns whose property names are the IDs of the columns.\n // This is an additional (redundant) sanity check. Specifically we're interested in\n // MenuColumnWithHeader objects, which TypeScript now \"knows\" we have, but at runtime all we\n // can check for is that it's an object with a valid numeric order field. That's likely good\n // enough.\n if (\n typeof column === 'object' &&\n typeof column.order === 'number' &&\n !Number.isNaN(column.order)\n )\n columnNumbers.set(column.order, { id: columnId, metadata: column });\n else\n console.warn(\n `Property ${columnName} (${typeof column}) on menu ${id} is not a valid column and is being ignored. This might indicate data corruption`,\n );\n });\n\n // Extract values and sort them based on the 'order' property\n return Array.from(columnNumbers.values()).sort((a, b) => {\n return (a.metadata.order || 0) - (b.metadata.order || 0);\n });\n }, [columns, id]);\n\n // We might need something like this if we need to be able to prevent empty columns\n // sortedColumns.filter((c) => multiColumnMenu.groups.some((g) => 'column' in g && (g as .column)...\n\n return (\n \n {sortedColumns.map((col, index) => (\n \n ))}\n \n );\n}\n","import { useEffect, useRef, useState } from 'react';\n\nexport type UsePromiseOptions = {\n /**\n * Whether to leave the value as the most recent resolved promise value or set it back to\n * defaultValue while running the promise again. Defaults to true\n */\n preserveValue?: boolean;\n};\n\n/** Set up defaults for options for usePromise hook */\nfunction getUsePromiseOptionsDefaults(options: UsePromiseOptions): UsePromiseOptions {\n return {\n preserveValue: true,\n ...options,\n };\n}\n\n/**\n * Awaits a promise and returns a loading value while the promise is unresolved\n *\n * @param promiseFactoryCallback A function that returns the promise to await. If this callback is\n * undefined, the current value will be returned (defaultValue unless it was previously changed\n * and `options.preserveValue` is true), and there will be no loading.\n *\n * WARNING: MUST BE STABLE - const or wrapped in useCallback. The reference must not be updated\n * every render\n * @param defaultValue The initial value to return while first awaiting the promise. If\n * `options.preserveValue` is false, this value is also shown while awaiting the promise on\n * subsequent calls.\n *\n * Note: this parameter is internally assigned to a `ref`, so changing it will not cause any hooks\n * to re-run with its new value. This means that, if the `promiseFactoryCallback` changes and\n * `options.preserveValue` is `false`, the returned value will be set to the current\n * `defaultValue`. However, the returned value will not be updated if`defaultValue` changes.\n * @param options Various options for adjusting how this hook runs the `promiseFactoryCallback`\n *\n * Note: this parameter is internally assigned to a `ref`, so changing it will not cause any hooks\n * to re-run with its new value. However, the latest `options.preserveValue` will always be used\n * appropriately to determine whether to preserve the returned value when changing the\n * `promiseFactoryCallback`\n * @returns `[value, isLoading]`\n *\n * - `value`: the current value for the promise, either the defaultValue or the resolved promise value\n * - `isLoading`: whether the promise is waiting to be resolved\n */\nconst usePromise = (\n promiseFactoryCallback: (() => Promise) | undefined,\n defaultValue: T,\n options: UsePromiseOptions = {},\n): [value: T, isLoading: boolean] => {\n // Use defaultValue as a ref so it doesn't update dependency arrays\n const defaultValueRef = useRef(defaultValue);\n defaultValueRef.current = defaultValue;\n // Use options as a ref so it doesn't update dependency arrays\n const optionsDefaultedRef = useRef(options);\n optionsDefaultedRef.current = getUsePromiseOptionsDefaults(optionsDefaultedRef.current);\n\n const [value, setValue] = useState(() => defaultValueRef.current);\n const [isLoading, setIsLoading] = useState(true);\n useEffect(() => {\n let promiseIsCurrent = true;\n // If a promiseFactoryCallback was provided, we are loading. Otherwise, there is no loading to do\n setIsLoading(!!promiseFactoryCallback);\n (async () => {\n // If there is a callback to run, run it\n if (promiseFactoryCallback) {\n const result = await promiseFactoryCallback();\n // If the promise was not already replaced, update the value\n if (promiseIsCurrent) {\n setValue(() => result);\n setIsLoading(false);\n }\n }\n })();\n\n return () => {\n // Mark this promise as old and not to be used\n promiseIsCurrent = false;\n if (!optionsDefaultedRef.current.preserveValue) setValue(() => defaultValueRef.current);\n };\n }, [promiseFactoryCallback]);\n\n return [value, isLoading];\n};\nexport default usePromise;\n","\"use client\";\n\nimport createSvgIcon from './utils/createSvgIcon';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nexport default createSvgIcon( /*#__PURE__*/_jsx(\"path\", {\n d: \"M3 18h18v-2H3zm0-5h18v-2H3zm0-7v2h18V6z\"\n}), 'Menu');","import GridMenu from '@/components/mui/grid-menu.component';\nimport { Command, CommandHandler } from '@/components/mui/menu-item.component';\nimport usePromise from '@/hooks/use-promise.hook';\nimport { Menu as MenuIcon } from '@mui/icons-material';\nimport { Drawer, IconButton } from '@mui/material';\nimport { Localized, MultiColumnMenu } from 'platform-bible-utils';\nimport {\n MouseEvent,\n MutableRefObject,\n PropsWithChildren,\n useCallback,\n useEffect,\n useState,\n} from 'react';\n\nexport interface MultiColumnMenuProvider {\n (isSupportAndDevelopment: boolean): Promise>;\n}\n\nexport type HamburgerMenuButtonProps = PropsWithChildren & {\n /** The handler to use for menu commands (and eventually toolbar commands). */\n commandHandler: CommandHandler;\n\n /**\n * Optional reference to the \"div\" container that determines the where the menu should appear. If\n * not defined, then (1,1) used.\n */\n containerRef?: MutableRefObject;\n\n /**\n * The delegate to use to get the menu data. If not specified or if it returns undefined, the data\n * in normalMenu or fullMenu property will be used.\n */\n menuProvider?: MultiColumnMenuProvider;\n\n /**\n * The menu data to show when the menu is opened if the menuProvider property is not defined.\n * (This allows for a default or test-only static menu to be used.)\n */\n normalMenu?: Localized;\n\n /**\n * The menu data to show for \"full\" menu (when opened with the SHIFT key pressed) if the\n * menuProvider property is not defined. (This allows for a default or test-only static menu to be\n * used.)\n */\n fullMenu?: Localized;\n\n /** Additional css class(es) to help with unique styling of the sub-components */\n className?: string;\n\n /** Value to use as prefix for ARIA labels on interactive sub-components */\n ariaLabelPrefix?: string;\n};\n\nexport default function HamburgerMenuButton({\n menuProvider,\n normalMenu,\n fullMenu,\n commandHandler,\n containerRef,\n className,\n ariaLabelPrefix,\n children,\n}: HamburgerMenuButtonProps) {\n const [isMenuOpen, setMenuOpen] = useState(false);\n const [showFullMenu, setShowFullMenu] = useState(false);\n\n const handleMenuItemClick = useCallback(() => {\n if (isMenuOpen) setMenuOpen(false);\n setShowFullMenu(false);\n }, [isMenuOpen]);\n\n const handleMenuButtonClick = useCallback((e: MouseEvent) => {\n e.stopPropagation();\n setMenuOpen((prevIsOpen) => {\n const isOpening = !prevIsOpen;\n if (isOpening && e.shiftKey) setShowFullMenu(true);\n else if (!isOpening) setShowFullMenu(false);\n return isOpening;\n });\n }, []);\n\n const menuCommandHandler = useCallback(\n (command: Command) => {\n handleMenuItemClick();\n return commandHandler(command);\n },\n [commandHandler, handleMenuItemClick],\n );\n\n const [offset, setOffset] = useState({ top: 1, left: 1 });\n\n useEffect(() => {\n if (isMenuOpen) {\n const node = containerRef?.current;\n if (node) {\n const rect = node.getBoundingClientRect();\n const scrollTop = window.scrollY;\n const scrollLeft = window.scrollX;\n const top = rect.top + scrollTop + node.clientHeight;\n const left = rect.left + scrollLeft;\n setOffset({ top, left });\n }\n }\n }, [isMenuOpen, containerRef]);\n\n const [normalMenuData] = usePromise(\n useCallback(async () => {\n return menuProvider?.(false) ?? normalMenu;\n // isMenuOpen needs to be included for the menu contents to reevaluate when reopened\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [menuProvider, normalMenu, isMenuOpen]),\n normalMenu,\n );\n\n const [fullMenuData] = usePromise(\n useCallback(async () => {\n return menuProvider?.(true) ?? fullMenu ?? normalMenuData;\n // isMenuOpen needs to be included for the menu contents to reevaluate when reopened\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [menuProvider, fullMenu, normalMenuData, isMenuOpen]),\n fullMenu ?? normalMenuData,\n );\n\n const menu = showFullMenu && fullMenuData ? fullMenuData : normalMenuData;\n\n return (\n <>\n \n {children ?? }\n \n \n {menu ? (\n \n ) : undefined}\n \n \n );\n}\n","import '@/components/mui/icon-button.component.css';\nimport { IconButton as MuiIconButton } from '@mui/material';\nimport { MouseEventHandler, PropsWithChildren } from 'react';\n\nexport type IconButtonProps = PropsWithChildren<{\n /** Optional unique identifier */\n id?: string;\n /**\n * Required. Used as both the tooltip (aka, title) and the aria-label (used for accessibility,\n * testing, etc.), unless a distinct tooltip is supplied.\n */\n label: string;\n /**\n * Enabled status of button\n *\n * @default false\n */\n isDisabled?: boolean;\n /** Optional tooltip to display if different from the aria-label. */\n tooltip?: string;\n /** If true, no tooltip will be displayed. */\n isTooltipSuppressed?: boolean;\n /**\n * If given, uses a negative margin to counteract the padding on one side (this is often helpful\n * for aligning the left or right side of the icon with content above or below, without ruining\n * the border size and shape).\n *\n * @default false\n */\n adjustMarginToAlignToEdge?: 'end' | 'start' | false;\n /**\n * The size of the component. small is equivalent to the dense button styling.\n *\n * @default false\n */\n size: 'small' | 'medium' | 'large';\n /** Additional css classes to help with unique styling of the button */\n className?: string;\n /** Optional click handler */\n onClick?: MouseEventHandler;\n}>;\n\n/**\n * Iconic button a user can click to do something\n *\n * Thanks to MUI for heavy inspiration and documentation\n * https://mui.com/material-ui/getting-started/overview/\n */\nfunction IconButton({\n id,\n label,\n isDisabled = false,\n tooltip,\n isTooltipSuppressed = false,\n adjustMarginToAlignToEdge = false,\n size = 'medium',\n className,\n onClick,\n children,\n}: IconButtonProps) {\n return (\n \n {children /* the icon to display */}\n \n );\n}\n\nexport default IconButton;\n","import { cn } from '@/utils/shadcn-ui.util';\nimport { LoaderCircle, LucideProps } from 'lucide-react';\nimport { forwardRef } from 'react';\n\nexport type SpinnerProps = LucideProps;\n\nconst Spinner = forwardRef(({ className, ...props }, ref) => {\n return (\n \n );\n});\n\nSpinner.displayName = 'Spinner';\n\nexport default Spinner;\n","import { Input as ShadInput } from '@/components/shadcn-ui/input';\nimport { Label as ShadLabel } from '@/components/shadcn-ui/label';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { ChangeEventHandler, FocusEventHandler } from 'react';\n\nexport type TextFieldProps = {\n /** Optional unique identifier */\n id?: string;\n /**\n * If `true`, the component is disabled.\n *\n * @default false\n */\n isDisabled?: boolean;\n /**\n * If `true`, the label is displayed in an error state.\n *\n * @default false\n */\n hasError?: boolean;\n /**\n * If `true`, the input will take up the full width of its container.\n *\n * @default false\n */\n isFullWidth?: boolean;\n /** Text that gives the user instructions on what contents the TextField expects */\n helperText?: string;\n /** The title of the TextField */\n label?: string;\n /** The short hint displayed in the `input` before the user enters a value. */\n placeholder?: string;\n /**\n * If `true`, the label is displayed as required and the `input` element is required.\n *\n * @default false\n */\n isRequired?: boolean;\n /** Additional css classes to help with unique styling of the text field */\n className?: string;\n /** Starting value for the text field if it is not controlled */\n defaultValue?: string | number;\n /** Value of the text field if controlled */\n value?: string | number;\n /** Triggers when content of textfield is changed */\n onChange?: ChangeEventHandler;\n /** Triggers when textfield gets focus */\n onFocus?: FocusEventHandler;\n /** Triggers when textfield loses focus */\n onBlur?: FocusEventHandler;\n};\n\n/**\n * Text input field\n *\n * Thanks to Shadcn for heavy inspiration and documentation\n * https://ui.shadcn.com/docs/components/input#with-label\n */\nfunction TextField({\n id,\n isDisabled = false,\n hasError = false,\n isFullWidth = false,\n helperText,\n label,\n placeholder,\n isRequired = false,\n className,\n defaultValue,\n value,\n onChange,\n onFocus,\n onBlur,\n}: TextFieldProps) {\n return (\n
    \n {`${label}${isRequired ? '*' : ''}`}\n \n

    {helperText}

    \n
    \n );\n}\n\nexport default TextField;\n","import HamburgerMenuButton, {\n MultiColumnMenuProvider,\n} from '@/components/mui/hamburger-menu-button.component';\nimport { CommandHandler } from '@/components/mui/menu-item.component';\nimport '@/components/mui/toolbar.component.css';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { AppBar, Toolbar as MuiToolbar } from '@mui/material';\nimport { PropsWithChildren, useRef } from 'react';\n\nexport type ToolbarProps = PropsWithChildren<{\n /** The handler to use for menu commands (and eventually toolbar commands). */\n commandHandler: CommandHandler;\n\n /**\n * The optional delegate to use to get the menu data. If not specified, the \"hamburger\" menu will\n * not display.\n */\n menuProvider?: MultiColumnMenuProvider;\n\n /** Optional unique identifier */\n id?: string;\n\n /** Additional css classes to help with unique styling of the toolbar */\n className?: string;\n}>;\n\nexport default function Toolbar({\n menuProvider,\n commandHandler,\n className,\n id,\n children,\n}: ToolbarProps) {\n // This ref will always be defined\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const containerRef = useRef(undefined!);\n\n return (\n
    \n \n \n {menuProvider ? (\n \n ) : undefined}\n {children ?
    {children}
    : undefined}\n \n
    \n
    \n );\n}\n","import React from 'react';\nimport { cva, type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst alertVariants = cva(\n 'tw-relative tw-w-full tw-rounded-lg tw-border tw-p-4 [&>svg~*]:tw-pl-7 [&>svg+div]:tw-translate-y-[-3px] [&>svg]:tw-absolute [&>svg]:tw-left-4 [&>svg]:tw-top-4 [&>svg]:tw-text-foreground',\n {\n variants: {\n variant: {\n default: 'tw-bg-background tw-text-foreground',\n destructive:\n 'tw-border-destructive/50 tw-text-destructive dark:tw-border-destructive [&>svg]:tw-text-destructive',\n },\n },\n defaultVariants: {\n variant: 'default',\n },\n },\n);\n\nconst Alert = React.forwardRef<\n HTMLDivElement,\n React.HTMLAttributes & VariantProps\n>(({ className, variant, ...props }, ref) => (\n
    \n));\nAlert.displayName = 'Alert';\n\nconst AlertTitle = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n {/* added because of https://github.com/jsx-eslint/eslint-plugin-jsx-a11y/blob/main/docs/rules/heading-has-content.md */}\n {props.children}{' '}\n \n ),\n);\nAlertTitle.displayName = 'AlertTitle';\n\nconst AlertDescription = React.forwardRef<\n HTMLParagraphElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n
    \n));\nAlertDescription.displayName = 'AlertDescription';\n\nexport { Alert, AlertTitle, AlertDescription };\n","import React from 'react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Card = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nCard.displayName = 'Card';\n\nconst CardHeader = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nCardHeader.displayName = 'CardHeader';\n\nconst CardTitle = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n {/* added because of https://github.com/jsx-eslint/eslint-plugin-jsx-a11y/blob/main/docs/rules/heading-has-content.md */}\n {props.children}\n \n ),\n);\nCardTitle.displayName = 'CardTitle';\n\nconst CardDescription = React.forwardRef<\n HTMLParagraphElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n

    \n));\nCardDescription.displayName = 'CardDescription';\n\nconst CardContent = React.forwardRef>(\n ({ className, ...props }, ref) => (\n

    \n ),\n);\nCardContent.displayName = 'CardContent';\n\nconst CardFooter = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nCardFooter.displayName = 'CardFooter';\n\nexport { Card, CardHeader, CardFooter, CardTitle, CardDescription, CardContent };\n","import { ComponentProps } from 'react';\nimport { toast as sonner, Toaster } from 'sonner';\n\ntype SonnerProps = ComponentProps;\n\nfunction Sonner({ ...props }: SonnerProps) {\n return (\n \n );\n}\n\n// The re-export of the sonner function was added manually\nexport { Sonner, sonner };\n","import React from 'react';\nimport * as SliderPrimitive from '@radix-ui/react-slider';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Slider = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n \n \n \n));\nSlider.displayName = SliderPrimitive.Root.displayName;\n\nexport { Slider };\n","import React from 'react';\nimport * as SwitchPrimitives from '@radix-ui/react-switch';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Switch = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n));\nSwitch.displayName = SwitchPrimitives.Root.displayName;\n\nexport { Switch };\n","import React from 'react';\nimport * as TabsPrimitive from '@radix-ui/react-tabs';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport const Tabs = TabsPrimitive.Root;\n\nexport type TabsListProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport type TabsTriggerProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport type TabsContentProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport const TabsList = React.forwardRef<\n React.ElementRef,\n TabsListProps\n>(({ className, ...props }, ref) => (\n \n));\nTabsList.displayName = TabsPrimitive.List.displayName;\n\nexport const TabsTrigger = React.forwardRef<\n React.ElementRef,\n TabsTriggerProps\n>(({ className, ...props }, ref) => (\n \n));\nTabsTrigger.displayName = TabsPrimitive.Trigger.displayName;\n\nexport const TabsContent = React.forwardRef<\n React.ElementRef,\n TabsContentProps\n>(({ className, ...props }, ref) => (\n \n));\nTabsContent.displayName = TabsPrimitive.Content.displayName;\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Download } from 'lucide-react';\n\ntype InstallButtonProps = {\n /** The installing boolean value determines the state of the button. */\n isInstalling: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n /** Optional text for the button. */\n buttonText?: string;\n} & ButtonProps;\n\n/**\n * The InstallButton component is a button designed for initiating installs. It includes visuals for\n * active installing and idle states.\n *\n * @param isInstalling The installing boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @param buttonText Optional text for the button.\n * @returns A install button.\n */\nexport default function InstallButton({\n isInstalling,\n handleClick,\n buttonText,\n className,\n ...props\n}: InstallButtonProps) {\n return (\n \n {isInstalling ? (\n \n ) : (\n <>\n \n {buttonText}\n \n )}\n \n );\n}\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\n\ntype EnableButtonProps = {\n /** The enabling boolean value determines the state of the button. */\n isEnabling: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n} & ButtonProps;\n\n/**\n * The EnableButton component is a button designed for initiating enabling of downloads. It includes\n * visuals for active enabling and idle states.\n *\n * @param isEnabling The enabling boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @returns A button that can be used to enable.\n */\nexport default function EnableButton({\n isEnabling,\n handleClick,\n className,\n ...props\n}: EnableButtonProps) {\n return (\n \n {isEnabling ? (\n <>\n \n Enabling...\n \n ) : (\n 'Enable'\n )}\n \n );\n}\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\n\ntype DisableButtonProps = {\n /** The disabling boolean value determines the state of the button. */\n isDisabling: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n} & ButtonProps;\n\n/**\n * The DisableButton component is a button designed for initiating disabling of downloads. It\n * includes visuals for active disabling and idle states.\n *\n * @param isDisabling The disabling boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @returns A button that can be used to disable.\n */\nexport default function DisableButton({\n isDisabling,\n handleClick,\n className,\n ...props\n}: DisableButtonProps) {\n return (\n \n {isDisabling ? (\n <>\n \n Disabling...\n \n ) : (\n 'Disable'\n )}\n \n );\n}\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\n\ntype UpdateButtonProps = {\n /** The updating boolean value determines the state of the button. */\n isUpdating: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n} & ButtonProps;\n\n/**\n * The UpdateButton component is a button designed for initiating updates for downloaded extensions.\n * It includes visuals for active updating and idle states.\n *\n * @param isUpdating The updating boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @returns A button that can be used to update.\n */\nexport default function UpdateButton({\n isUpdating,\n handleClick,\n className,\n ...props\n}: UpdateButtonProps) {\n return (\n \n {isUpdating ? (\n <>\n \n Updating...\n \n ) : (\n 'Update'\n )}\n \n );\n}\n","import { cn } from '@/utils/shadcn-ui.util';\nimport Markdown, { MarkdownToJSX } from 'markdown-to-jsx';\nimport { useMemo } from 'react';\n\ninterface MarkdownRendererProps {\n /** Optional unique identifier */\n id?: string;\n /** The markdown string to render */\n markdown: string;\n className?: string;\n /**\n * The [`target` attribute for `a` html\n * tags](https://developer.mozilla.org/en-US/docs/Web/HTML/Element/a#target). Defaults to not\n * adding a `target` to `a` tags\n */\n anchorTarget?: string;\n}\n\n/**\n * This component renders markdown content given a markdown string. It uses typography styles from\n * the platform.\n *\n * @param markdown The markdown string to render.\n * @param id Optional unique identifier\n * @returns A div containing the rendered markdown content.\n */\nexport default function MarkdownRenderer({\n id,\n markdown,\n className,\n anchorTarget,\n}: MarkdownRendererProps) {\n const options: MarkdownToJSX.Options = useMemo(\n () => ({\n overrides: {\n a: {\n props: {\n target: anchorTarget,\n },\n },\n },\n }),\n [anchorTarget],\n );\n return (\n
    \n {markdown}\n
    \n );\n}\n","import { Filter, ChevronDown } from 'lucide-react';\nimport { forwardRef } from 'react';\nimport { Button } from '@/components/shadcn-ui/button';\n\n/**\n * The FilterButton component is a button designed for initiating filtering of data. It is designed\n * to be used with the dropdown menu. It uses forwardRef to pass the button to the dropdown trigger\n * asChild.\n *\n * @returns A button that can be used to filter.\n */\nconst FilterButton = forwardRef((props, ref) => {\n return (\n \n \n Filter\n \n \n );\n});\n\nexport default FilterButton;\n","import {\n DropdownMenu,\n DropdownMenuTrigger,\n DropdownMenuContent,\n DropdownMenuLabel,\n DropdownMenuGroup,\n DropdownMenuCheckboxItem,\n DropdownMenuRadioItem,\n DropdownMenuSeparator,\n} from '@/components/shadcn-ui/dropdown-menu';\nimport FilterButton from './buttons/filter-button.component';\n\nexport enum DropdownMenuItemType {\n Check,\n Radio,\n}\n\nexport type DropdownItem = {\n /** The label is the text that will be displayed on the dropdown item. */\n label: string;\n /** The itemType determines the DropdownMenuItemType type as either Check or Radio. */\n itemType: DropdownMenuItemType;\n /** The onClick function is called when the item is clicked. */\n onClick: () => void;\n};\n\nexport type DropdownGroup = {\n /**\n * The label is the text that will be displayed on the dropdown group. It is used to categorize\n * the items in the group.\n */\n label: string;\n /** The items array contains the items that will be displayed in the dropdown group */\n items: DropdownItem[];\n};\n\nexport type FilterDropdownProps = {\n /** Object unique identifier */\n id?: string;\n /** The groups array contains the groups that will be displayed in the dropdown */\n groups: DropdownGroup[];\n}; // TODO: extend the props later\n\n/**\n * The FilterDropdown component is a dropdown designed for filtering content. It includes groups of\n * items that can be checkboxes or radio items.\n *\n * @param id Optional unique identifier\n * @param groups The groups array contains the groups that will be displayed in the dropdown\n * @returns A filter dropdown.\n */\nexport default function FilterDropdown({ id, groups }: FilterDropdownProps) {\n return (\n
    \n {/* TODO: remove this once the DropDown Menu shadcn has an id prop */}\n \n \n \n \n \n {groups.map((group) => (\n
    \n {group.label}\n \n {group.items.map((item) => (\n
    \n {item.itemType === DropdownMenuItemType.Check ? (\n \n {item.label}\n \n ) : (\n \n {item.label}\n \n )}\n
    \n ))}\n
    \n \n
    \n ))}\n
    \n
    \n
    \n );\n}\n","interface NoExtensionsFoundProps {\n /** Optional unique identifier */\n id?: string;\n /** The message to display */\n message: string;\n}\n/**\n * This component displays a message to the user when no extensions are found in the marketplace.\n *\n * @param id Optional unique identifier\n * @param message The message to display.\n * @returns {JSX.Element} - Returns the message component that displays the message to the user.\n */\nexport default function NoExtensionsFound({ id, message }: NoExtensionsFoundProps) {\n return (\n
    \n
    \n

    {message}

    \n
    \n
    \n );\n}\n","import { CircleHelp, Link as LucideLink, User } from 'lucide-react';\nimport { NumberFormat } from 'platform-bible-utils';\n\n/** Interface that stores the parameters passed to the More Info component */\ninterface MoreInfoProps {\n /** Optional unique identifier */\n id?: string;\n /** The category of the extension */\n category: string;\n /** The number of downloads for the extension */\n downloads: Record;\n /** The languages supported by the extension */\n languages: string[];\n /** The URL to the more info page of the extension */\n moreInfoUrl: string;\n}\n/**\n * This component displays the more info section of the extension which includes the category,\n * number of downloads, languages, and links to the website and support\n *\n * @param id Optional unique identifier\n * @param category The category of the extension\n * @param downloads The number of downloads for the extension\n * @param languages The languages supported by the extension\n * @param moreInfoUrl The URL to the more info page of the extension\n * @returns {JSX.Element} - Returns the more info component that displays the category, number of\n * downloads, languages, and links to the website and support\n */\nexport default function MoreInfo({\n id,\n category,\n downloads,\n languages,\n moreInfoUrl,\n}: MoreInfoProps) {\n /**\n * This constant formats the number of downloads into a more readable format.\n *\n * @example 1000 -> 1K\n *\n * @example 1000000 -> 1M\n *\n * @returns The formatted number of downloads\n */\n const numberFormatted = new NumberFormat('en', {\n notation: 'compact',\n compactDisplay: 'short',\n }).format(Object.values(downloads).reduce((a: number, b: number) => a + b, 0));\n\n /** This function scrolls the window to the bottom of the page. */\n const handleScrollToBottom = () => {\n window.scrollTo(0, document.body.scrollHeight);\n };\n\n return (\n \n
    \n
    \n {category}\n
    \n CATEGORY\n
    \n
    \n
    \n
    \n \n {numberFormatted}\n
    \n USERS\n
    \n
    \n
    \n
    \n {languages.slice(0, 3).map((locale) => (\n \n {locale.toUpperCase()}\n \n ))}\n
    \n {languages.length > 3 && (\n handleScrollToBottom()}\n className=\"tw-text-xs tw-text-gray-500 tw-underline\"\n >\n +{languages.length - 3} more languages\n \n )}\n
    \n
    \n
    \n \n Website\n \n \n \n Support\n \n \n
    \n
    \n );\n}\n","import { useState } from 'react';\n\nexport type VersionInformation = {\n /** Date the version was published */\n date: string;\n /** Description of the changes in the version */\n description: string;\n};\n\n/** Type to store the version history information */\nexport type VersionHistoryType = Record;\n\n/** Interface that stores the parameters passed to the Version History component */\ninterface VersionHistoryProps {\n /** Optional unique identifier */\n id?: string;\n /** Object containing the versions mapped with their information */\n versionHistory: VersionHistoryType;\n}\n\n/**\n * Component to render the version history information shown in the footer component. Lists the 5\n * most recent versions, with the options to show all versions by pressing a button.\n *\n * @param versionHistory Object containing the versions mapped with their information\n * @param id Optional unique identifier\n * @returns Rendered version history for the Footer component\n */\nexport default function VersionHistory({ id, versionHistory }: VersionHistoryProps) {\n const [showAllVersions, setShowAllVersions] = useState(false);\n const currentDate = new Date();\n\n /**\n * Function to format the time string for the version history in the form of 'X year(s) ago'.\n *\n * @param dateString ISO Date string to determine the time string from\n * @returns Formatted time string\n */\n function formatTimeString(dateString: string) {\n const date = new Date(dateString);\n const dateDiff = new Date(currentDate.getTime() - date.getTime());\n const yearDiff = dateDiff.getUTCFullYear() - 1970;\n const monthDiff = dateDiff.getUTCMonth();\n const dayDiff = dateDiff.getUTCDate() - 1;\n\n // Determines how long ago the version was published\n let timeString = '';\n if (yearDiff > 0) {\n timeString = `${yearDiff.toString()} year${yearDiff === 1 ? '' : 's'} ago`;\n } else if (monthDiff > 0) {\n timeString = `${monthDiff.toString()} month${monthDiff === 1 ? '' : 's'} ago`;\n } else if (dayDiff === 0) {\n timeString = 'today';\n } else {\n timeString = `${dayDiff.toString()} day${dayDiff === 1 ? '' : 's'} ago`;\n }\n\n return timeString;\n }\n\n // Sorts the version history by version number\n const sortedEntries = Object.entries(versionHistory).sort((a, b) => b[0].localeCompare(a[0]));\n\n return (\n
    \n

    What`s New

    \n
      \n {(showAllVersions ? sortedEntries : sortedEntries.slice(0, 5)).map((entry) => (\n
      \n
      \n
    • \n {entry[1].description}\n
    • \n
      \n
      \n
      Version {entry[0]}
      \n
      {formatTimeString(entry[1].date)}
      \n
      \n
      \n ))}\n
    \n {sortedEntries.length > 5 && (\n setShowAllVersions(!showAllVersions)}\n className=\"tw-text-xs tw-text-gray-500 tw-underline\"\n >\n {showAllVersions ? 'Show Less Version History' : 'Show All Version History'}\n \n )}\n
    \n );\n}\n","import { useMemo } from 'react';\nimport { formatBytes } from 'platform-bible-utils';\nimport VersionHistory, { VersionHistoryType } from './version-history.component';\n\n/** Interface to store the parameters passed to the Footer component */\ninterface FooterProps {\n /** Optional unique identifier */\n id?: string;\n /** Name of the publisher */\n publisherDisplayName: string;\n /** Size of the extension file in bytes */\n fileSize: number;\n /** List of language codes supported by the extension */\n locales: string[];\n /** Object containing the version history mapped with their information */\n versionHistory: VersionHistoryType;\n}\n\n/**\n * Component to render the footer for the extension details which contains information on the\n * publisher, version history, languages, and file size.\n *\n * @param id Optional unique identifier\n * @param publisherDisplayName Name of the publisher\n * @param fileSize Size of the extension file in bytes\n * @param locales List of language codes supported by the extension\n * @param versionHistory Object containing the version history mapped with their information\n * @returns The rendered Footer component\n */\nexport default function Footer({\n id,\n publisherDisplayName,\n fileSize,\n locales,\n versionHistory,\n}: FooterProps) {\n /** Formats the file size into a human-readable format */\n const formattedFileSize = useMemo(() => formatBytes(fileSize), [fileSize]);\n\n /**\n * This function gets the display names of the languages based on the language codes.\n *\n * @param codes The list of language codes\n * @returns The list of language names\n */\n const getLanguageNames = (codes: string[]) => {\n const displayNames = new Intl.DisplayNames(navigator.language, { type: 'language' });\n return codes.map((code) => displayNames.of(code));\n };\n\n const languageNames = getLanguageNames(locales);\n\n return (\n
    \n
    \n \n
    \n
    \n

    Information

    \n
    \n

    \n Publisher\n {publisherDisplayName}\n Size\n {formattedFileSize}\n

    \n
    \n

    \n Languages\n {languageNames.join(', ')}\n

    \n
    \n
    \n
    \n
    \n
    \n );\n}\n","import { PlatformEvent, PlatformEventHandler } from 'platform-bible-utils';\nimport { useEffect } from 'react';\n\n/**\n * Adds an event handler to an event so the event handler runs when the event is emitted. Use\n * `papi.network.getNetworkEvent` to use a networked event with this hook.\n *\n * @param event The event to subscribe to.\n *\n * - If event is a `PlatformEvent`, that event will be used\n * - If event is undefined, the callback will not be subscribed. Useful if the event is not yet\n * available for example\n *\n * @param eventHandler The callback to run when the event is emitted\n *\n * WARNING: MUST BE STABLE - const or wrapped in useCallback. The reference must not be updated\n * every render\n */\nconst useEvent = (\n event: PlatformEvent | undefined,\n eventHandler: PlatformEventHandler,\n) => {\n useEffect(() => {\n // Do nothing if the event is not provided (in case the event is not yet available, for example)\n if (!event) return () => {};\n\n const unsubscriber = event(eventHandler);\n return () => {\n unsubscriber();\n };\n }, [event, eventHandler]);\n};\nexport default useEvent;\n","import { useCallback, useEffect } from 'react';\nimport { PlatformEvent, PlatformEventAsync, PlatformEventHandler } from 'platform-bible-utils';\nimport usePromise from './use-promise.hook';\n\nconst noopUnsubscriber = () => false;\n\n/**\n * Adds an event handler to an asynchronously subscribing/unsubscribing event so the event handler\n * runs when the event is emitted. Use `papi.network.getNetworkEvent` to use a networked event with\n * this hook.\n *\n * @param event The asynchronously (un)subscribing event to subscribe to.\n *\n * - If event is a `PlatformEvent` or `PlatformEventAsync`, that event will be used\n * - If event is undefined, the callback will not be subscribed. Useful if the event is not yet\n * available for example\n *\n * @param eventHandler The callback to run when the event is emitted\n *\n * WARNING: MUST BE STABLE - const or wrapped in useCallback. The reference must not be updated\n * every render\n */\nconst useEventAsync = (\n event: PlatformEvent | PlatformEventAsync | undefined,\n eventHandler: PlatformEventHandler,\n) => {\n // Subscribe to the event asynchronously\n const [unsubscribe] = usePromise(\n useCallback(async () => {\n // Do nothing if the event is not provided (in case the event is not yet available, for example)\n if (!event) return noopUnsubscriber;\n\n // Wrap subscribe and unsubscribe in promises to allow normal events to be used as well\n const unsub = await Promise.resolve(event(eventHandler));\n return async () => unsub();\n }, [eventHandler, event]),\n noopUnsubscriber,\n // We want the unsubscriber to return to default value immediately upon changing subscription\n // So the useEffect below will unsubscribe asap\n { preserveValue: false },\n );\n\n // Unsubscribe from the event asynchronously (but we aren't awaiting the unsub)\n useEffect(() => {\n return () => {\n if (unsubscribe !== noopUnsubscriber) {\n unsubscribe();\n }\n };\n }, [unsubscribe]);\n};\n\nexport default useEventAsync;\n"],"names":["twMergeCustom","extendTailwindMerge","cn","inputs","clsx","Input","React","className","type","props","ref","jsx","BookChapterInput","forwardRef","handleSearch","handleKeyDown","handleOnClick","handleSubmit","jsxs","ShadInput","event","e","History","P","R","s","n","N","B","O","S","K","g","k","x","T","X","V","w","L","G","A","H","C","I","y","q","U","m","l","h","c","E","D","i","a","o","u","v","f","d","b","J","DropdownMenu","DropdownMenuPrimitive","DropdownMenuTrigger","DropdownMenuGroup","DropdownMenuPortal","DropdownMenuSub","DropdownMenuRadioGroup","DropdownMenuSubTrigger","inset","children","ChevronRight","DropdownMenuSubContent","DropdownMenuContent","sideOffset","DropdownMenuItem","DropdownMenuCheckboxItem","checked","Check","DropdownMenuRadioItem","Circle","DropdownMenuLabel","DropdownMenuSeparator","DropdownMenuShortcut","BookMenuItem","bookId","handleSelectBook","isSelected","handleHighlightBook","bookType","ShadDropdownMenuItem","Canon","ChapterSelect","handleSelectChapter","endChapter","activeChapter","highlightedChapter","handleHighlightedChapter","chapters","_","handleMouse","useCallback","chapterNumber","chapter","GoToMenuItem","handleSort","handleLocationHistory","handleBookmarks","ShadDropdownMenuLabel","ArrowDownWideNarrow","Clock","Bookmark","ALL_BOOK_IDS","BOOK_TYPE_LABELS","BOOK_TYPE_ARRAY","SCROLL_OFFSET","SEARCH_QUERY_FORMATS","fetchGroupedBooks","fetchEndChapter","getChaptersForBook","getAllEnglishNames","isValidBookEnglishName","bookName","getBookIdFromEnglishName","formattedBookName","BookChapterControl","scrRef","searchQuery","setSearchQuery","useState","selectedBookId","setSelectedBookId","setHighlightedChapter","highlightedBookId","setHighlightedBookId","isContentOpen","setIsContentOpen","isContentOpenDelayed","setIsContentOpenDelayed","inputRef","useRef","contentRef","menuItemRef","fetchFilteredBooks","englishNameLowerCase","normalizedQuery","handleSearchInput","searchString","shouldPreventAutoClosing","controlMenuState","open","updateReference","shouldClose","verse","handleInputSubmit","format","matches","book","englishName","handleKeyDownInput","handleKeyDownContent","key","handleKeyDownMenuItem","chapterOffSet","useEffect","useLayoutEffect","scrollTimeout","scrollPosition","ShadDropdownMenu","ShadDropdownMenuTrigger","ShadDropdownMenuContent","bookTypeIndex","element","ShadDropdownMenuSeparator","buttonVariants","cva","Button","variant","size","asChild","Slot","labelVariants","Label","LabelPrimitive","RadioGroup","RadioGroupPrimitive","RadioGroupItem","Popover","PopoverPrimitive","PopoverTrigger","PopoverContent","align","DialogPortal","DialogPrimitive","DialogOverlay","DialogContent","DialogTitle","DialogDescription","Command","CommandPrimitive","CommandInput","Search","CommandList","CommandEmpty","CommandGroup","CommandSeparator","CommandItem","getOptionLabelDefault","option","ComboBox","id","options","buttonClassName","popoverContentClassName","value","onChange","getOptionLabel","buttonPlaceholder","textPlaceholder","commandEmptyMessage","buttonVariant","dir","isDisabled","setOpen","ChevronsUpDown","ChapterRangeSelector","startChapter","handleSelectStartChapter","handleSelectEndChapter","chapterCount","chapterOptions","useMemo","index","Fragment","BookSelectionMode","BOOK_SELECTOR_STRING_KEYS","localizeString","strings","BookSelector","handleBookSelectionModeChange","currentBookName","onSelectBooks","selectedBookIds","localizedStrings","currentBookText","chooseText","chooseBooksText","bookSelectionMode","setBookSelectionMode","onSelectionModeChange","newMode","DataTableViewOptions","table","FilterIcon","column","Select","SelectPrimitive","SelectGroup","SelectValue","SelectTrigger","ChevronDown","SelectScrollUpButton","ChevronUp","SelectScrollDownButton","SelectContent","position","SelectLabel","SelectItem","SelectSeparator","DataTablePagination","pageSize","ArrowLeftIcon","ChevronLeftIcon","ChevronRightIcon","ArrowRightIcon","Table","stickyHeader","TableHeader","TableBody","TableFooter","TableRow","TableHead","TableCell","TableCaption","DataTable","columns","data","enablePagination","showPaginationControls","showColumnVisibilityControls","onRowClickHandler","sorting","setSorting","columnFilters","setColumnFilters","columnVisibility","setColumnVisibility","rowSelection","setRowSelection","useReactTable","getCoreRowModel","getPaginationRowModel","getSortedRowModel","getFilteredRowModel","headerGroup","header","flexRender","_a","row","cell","OccurrencesTable","occurrenceData","setScriptureReference","referenceHeaderText","occurrenceHeaderText","occurrences","uniqueOccurrences","occurrence","uniqueOccurrence","deepEqual","Checkbox","CheckboxPrimitive","getLinesFromUSFM","text","getNumberFromUSFM","regex","match","getBookNumFromId","getStatusForItem","item","approvedItems","unapprovedItems","toggleVariants","Toggle","TogglePrimitive","ToggleGroupContext","ToggleGroup","ToggleGroupPrimitive","ToggleGroupItem","context","getSortingIcon","sortDirection","ArrowUpIcon","ArrowDownIcon","ArrowUpDownIcon","inventoryItemColumn","itemLabel","inventoryAdditionalItemColumn","additionalItemLabel","additionalItemIndex","inventoryCountColumn","countLabel","statusChangeHandler","changedItems","newStatus","onApprovedItemsChange","onUnapprovedItemsChange","newApprovedItems","validItem","newUnapprovedItems","unapprovedItem","inventoryStatusColumn","statusLabel","status","CircleCheckIcon","CircleXIcon","CircleHelpIcon","INVENTORY_STRING_KEYS","filterItemData","itemData","statusFilter","textFilter","filteredItemData","createTableData","scriptureRef","itemRegex","tableData","currentBook","currentChapter","currentVerse","line","items","itemIndex","existingItem","tableEntry","newReference","substring","newItem","Inventory","scriptureReference","extractItems","additionalItemsLabels","scope","onScopeChange","allItemsText","approvedItemsText","unapprovedItemsText","unknownItemsText","scopeBookText","scopeChapterText","scopeVerseText","filterText","showAdditionalItemsText","showAdditionalItems","setShowAdditionalItems","setStatusFilter","setTextFilter","selectedItem","setSelectedItem","reducedTableData","newTableData","firstItem","existingEntry","newTableEntry","filteredTableData","allColumns","numberOfAdditionalItems","additionalColumns","_b","rowClickHandler","newSelection","handleScopeChange","handleStatusFilterChange","SearchBar","onSearch","placeholder","isFullWidth","handleInputChange","VerticalTabs","TabsPrimitive","VerticalTabsList","VerticalTabsTrigger","VerticalTabsContent","TabNavigationContentSearch","tabList","searchPlaceholder","headerTitle","isSearchBarFullWidth","direction","tab","Separator","orientation","decorative","SeparatorPrimitive","Sheet","SheetPrimitive","SheetPortal","SheetOverlay","sheetVariants","SheetContent","side","SheetTitle","SheetDescription","Skeleton","TooltipProvider","TooltipPrimitive","Tooltip","TooltipTrigger","TooltipContent","MOBILE_BREAKPOINT","useIsMobile","isMobile","setIsMobile","mql","SIDEBAR_COOKIE_NAME","SIDEBAR_COOKIE_MAX_AGE","SIDEBAR_WIDTH","SIDEBAR_WIDTH_MOBILE","SIDEBAR_WIDTH_ICON","SIDEBAR_KEYBOARD_SHORTCUT","SidebarContext","useSidebar","SidebarProvider","defaultOpen","openProp","setOpenProp","style","openMobile","setOpenMobile","_open","_setOpen","isOpen","openState","toggleSidebar","state","contextValue","Sidebar","collapsible","SidebarTrigger","onClick","PanelLeft","SidebarRail","SidebarInset","SidebarInput","SidebarHeader","SidebarFooter","SidebarSeparator","SidebarContent","SidebarGroup","SidebarGroupLabel","SidebarGroupAction","SidebarGroupContent","SidebarMenu","SidebarMenuItem","sidebarMenuButtonVariants","SidebarMenuButton","isActive","tooltip","Comp","button","SidebarMenuAction","showOnHover","SidebarMenuBadge","SidebarMenuSkeleton","showIcon","width","SidebarMenuSub","SidebarMenuSubItem","SidebarMenuSubButton","SettingsSidebar","extensionLabels","projectOptions","handleSelectSidebarItem","selectedSidebarItem","handleSelectItem","projectId","getProjectNameFromProjectId","project","getIsActive","label","selectedProjectName","SettingsSidebarContentSearch","scrBookColId","scrRefColId","typeColId","detailsColId","defaultScrRefColumnName","defaultScrBookGroupName","defaultTypeColumnName","defaultDetailsColumnName","getColumns","colInfo","showSourceColumn","showSrcCol","info","formatScrRef","compareScrRefs","toRefOrRange","scriptureSelection","offsetStart","offsetEnd","scrRefToBBBCCCVVV","getRowKey","ScriptureResultsViewer","sources","showColumnHeaders","scriptureReferenceColumnName","scriptureBookGroupName","typeColumnName","detailsColumnName","onRowSelected","grouping","setGrouping","scriptureResults","source","getExpandedRowModel","getGroupedRowModel","selectedRows","keys","selectedRow","scrBookGroupName","typeGroupName","groupingOptions","handleSelectChange","selectedGrouping","handleRowClick","getEvenOrOddBandingStyle","getIndent","groupingState","rowIndex","ChevronLeft","DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS","getLocalizeKeyForScrollGroupId","ScrollGroupSelector","availableScrollGroupIds","scrollGroupId","onChangeScrollGroupId","localizedStringsDefaulted","localizedStringKey","localizedStringValue","newScrollGroupString","scrollGroupOptionId","SettingsList","SettingsListItem","primary","secondary","isLoading","loadingMessage","SettingsListHeader","includeSeparator","Checklist","listItems","selectedListItems","handleSelectListItem","createLabel","_interopRequireDefault","obj","module","chainPropTypes","propType1","propType2","args","_extends","target","isPlainObject","prototype","deepClone","output","deepmerge","p","r","t","z","reactIs_production_min","hasSymbol","REACT_ELEMENT_TYPE","REACT_PORTAL_TYPE","REACT_FRAGMENT_TYPE","REACT_STRICT_MODE_TYPE","REACT_PROFILER_TYPE","REACT_PROVIDER_TYPE","REACT_CONTEXT_TYPE","REACT_ASYNC_MODE_TYPE","REACT_CONCURRENT_MODE_TYPE","REACT_FORWARD_REF_TYPE","REACT_SUSPENSE_TYPE","REACT_SUSPENSE_LIST_TYPE","REACT_MEMO_TYPE","REACT_LAZY_TYPE","REACT_BLOCK_TYPE","REACT_FUNDAMENTAL_TYPE","REACT_RESPONDER_TYPE","REACT_SCOPE_TYPE","isValidElementType","typeOf","object","$$typeof","$$typeofType","AsyncMode","ConcurrentMode","ContextConsumer","ContextProvider","Element","ForwardRef","Lazy","Memo","Portal","Profiler","StrictMode","Suspense","hasWarnedAboutDeprecatedIsAsyncMode","isAsyncMode","isConcurrentMode","isContextConsumer","isContextProvider","isElement","isForwardRef","isFragment","isLazy","isMemo","isPortal","isProfiler","isStrictMode","isSuspense","reactIs_development","reactIsModule","require$$0","require$$1","getOwnPropertySymbols","hasOwnProperty","propIsEnumerable","toObject","val","shouldUseNative","test1","test2","order2","test3","letter","objectAssign","from","to","symbols","ReactPropTypesSecret","ReactPropTypesSecret_1","has","printWarning","loggedTypeFailures","message","checkPropTypes","typeSpecs","values","location","componentName","getStack","typeSpecName","error","err","ex","stack","checkPropTypes_1","ReactIs","assign","require$$2","require$$3","require$$4","emptyFunctionThatReturnsNull","factoryWithTypeCheckers","isValidElement","throwOnDirectAccess","ITERATOR_SYMBOL","FAUX_ITERATOR_SYMBOL","getIteratorFn","maybeIterable","iteratorFn","ANONYMOUS","ReactPropTypes","createPrimitiveTypeChecker","createAnyTypeChecker","createArrayOfTypeChecker","createElementTypeChecker","createElementTypeTypeChecker","createInstanceTypeChecker","createNodeChecker","createObjectOfTypeChecker","createEnumTypeChecker","createUnionTypeChecker","createShapeTypeChecker","createStrictShapeTypeChecker","is","PropTypeError","createChainableTypeChecker","validate","manualPropTypeCallCache","manualPropTypeWarningCount","checkType","isRequired","propName","propFullName","secret","cacheKey","chainedCheckType","expectedType","propValue","propType","getPropType","preciseType","getPreciseType","typeChecker","expectedClass","expectedClassName","actualClassName","getClassName","expectedValues","valuesString","arrayOfTypeCheckers","checker","getPostfixForTypeWarning","expectedTypes","checkerResult","expectedTypesMessage","isNode","invalidValidatorError","shapeTypes","allKeys","iterator","step","entry","isSymbol","emptyFunction","emptyFunctionWithReset","factoryWithThrowingShims","shim","getShim","propTypesModule","isClassComponent","elementType","acceptingRef","safePropName","warningHint","elementAcceptingRef","PropTypes","elementAcceptingRef$1","specialProperty","exactProp","propTypes","unsupportedProps","prop","formatMuiErrorMessage","code","url","REACT_SERVER_CONTEXT_TYPE","REACT_OFFSCREEN_TYPE","enableScopeAPI","enableCacheElement","enableTransitionTracing","enableLegacyHidden","enableDebugTracing","REACT_MODULE_REFERENCE","SuspenseList","hasWarnedAboutDeprecatedIsConcurrentMode","isSuspenseList","fnNameMatchRegex","getFunctionName","fn","getFunctionComponentName","Component","fallback","getWrappedName","outerType","innerType","wrapperName","functionName","getDisplayName","HTMLElementType","refType","refType$1","capitalize","string","_formatMuiErrorMessage","createChainedFunction","funcs","acc","func","debounce","wait","timeout","debounced","later","deprecatedPropType","validator","reason","componentNameSafe","propFullNameSafe","isMuiElement","muiNames","_muiName","_element$type","ownerDocument","node","ownerWindow","requirePropFactory","componentNameInError","prevPropTypes","requiredProp","defaultTypeChecker","typeCheckerResult","setRef","useEnhancedEffect","useEnhancedEffect$1","globalId","useGlobalId","idOverride","defaultId","setDefaultId","maybeReactUseId","useId","reactId","unsupportedProp","useControlled","controlled","defaultProp","name","isControlled","valueState","setValue","defaultValue","setValueIfUncontrolled","newValue","useEventCallback","useForkRef","refs","instance","UNINITIALIZED","useLazyRef","init","initArg","EMPTY","useOnMount","Timeout","delay","useTimeout","hadKeyboardEvent","hadFocusVisibleRecently","hadFocusVisibleRecentlyTimeout","inputTypesWhitelist","focusTriggersKeyboardModality","tagName","handlePointerDown","handleVisibilityChange","prepare","doc","isFocusVisible","useIsFocusVisible","isFocusVisibleRef","handleBlurVisible","handleFocusVisible","resolveProps","defaultProps","defaultSlotProps","slotProps","slotPropName","composeClasses","slots","getUtilityClass","classes","slot","utilityClass","defaultGenerator","createClassNameGenerator","generate","generator","ClassNameGenerator","ClassNameGenerator$1","globalStateClasses","generateUtilityClass","globalStatePrefix","globalStateClass","generateUtilityClasses","result","clamp","min","max","_objectWithoutPropertiesLoose","excluded","sourceKeys","_excluded","sortBreakpointsValues","breakpointsAsArray","breakpoint1","breakpoint2","createBreakpoints","breakpoints","unit","other","sortedValues","up","down","between","start","end","endIndex","only","not","keyIndex","shape","shape$1","responsivePropType","responsivePropType$1","merge","defaultBreakpoints","handleBreakpoints","styleFromPropValue","theme","themeBreakpoints","breakpoint","mediaKey","cssKey","createEmptyBreakpointObject","breakpointsInput","_breakpointsInput$key","breakpointStyleKey","removeUnusedBreakpoints","breakpointKeys","breakpointOutput","getPath","path","checkVars","getStyleValue","themeMapping","transform","propValueFinal","userValue","cssProperty","themeKey","memoize","cache","arg","properties","directions","aliases","getCssProperties","property","marginKeys","paddingKeys","spacingKeys","createUnaryUnit","_getPath","themeSpacing","abs","createUnarySpacing","getValue","transformer","transformed","getStyleFromPropValue","cssProperties","resolveCssProperty","margin","padding","createSpacing","spacingInput","spacing","argsInput","argument","compose","styles","handlers","borderTransform","createBorderStyle","border","borderTop","borderRight","borderBottom","borderLeft","borderColor","borderTopColor","borderRightColor","borderBottomColor","borderLeftColor","outline","outlineColor","borderRadius","gap","columnGap","rowGap","gridColumn","gridRow","gridAutoFlow","gridAutoColumns","gridAutoRows","gridTemplateColumns","gridTemplateRows","gridTemplateAreas","gridArea","paletteTransform","color","bgcolor","backgroundColor","sizingTransform","maxWidth","_props$theme","_props$theme2","breakpointsValues","minWidth","height","maxHeight","minHeight","boxSizing","defaultSxConfig","defaultSxConfig$1","objectsHaveSameKeys","objects","union","callIfFn","maybeFn","unstable_createStyleFunctionSx","getThemeValue","config","styleFunctionSx","_theme$unstable_sxCon","sx","traverse","sxInput","sxObject","emptyBreakpoints","breakpointsKeys","css","styleKey","styleFunctionSx$1","applyStyles","createTheme","paletteInput","shapeInput","muiTheme","isObjectEmpty","useTheme","defaultTheme","contextTheme","ThemeContext","systemDefaultTheme","useThemeWithoutDefault","_excluded2","_excluded3","isEmpty","isStringTag","tag","shouldForwardProp","lowercaseFirstLetter","resolveTheme","themeId","defaultOverridesResolver","processStyleArg","callableStyle","_ref","ownerState","resolvedStylesArg","resolvedStyle","variants","isMatch","createStyled","input","rootShouldForwardProp","slotShouldForwardProp","systemSx","inputOptions","processStyles","componentSlot","inputSkipVariantsResolver","inputSkipSx","overridesResolver","skipVariantsResolver","skipSx","shouldForwardPropOption","defaultStyledResolver","styledEngineStyled","transformStyleArg","stylesArg","muiStyledResolver","styleArg","expressions","transformedStyleArg","expressionsWithDefaultTheme","styleOverrides","resolvedStyleOverrides","slotKey","slotStyle","_theme$components","themeVariants","numOfCustomFnsApplied","placeholders","displayName","getThemeProps","params","useThemeProps","clampWrapper","hexToRgb","re","colors","decomposeColor","marker","colorSpace","recomposeColor","hslToRgb","rgb","getLuminance","getContrastRatio","foreground","background","lumA","lumB","alpha","darken","coefficient","lighten","createMixins","mixins","common","common$1","grey","grey$1","purple","purple$1","red","red$1","orange","orange$1","blue","blue$1","lightBlue","lightBlue$1","green","green$1","light","dark","addLightOrDark","intent","shade","tonalOffset","tonalOffsetLight","tonalOffsetDark","getDefaultPrimary","mode","getDefaultSecondary","getDefaultError","getDefaultInfo","getDefaultSuccess","getDefaultWarning","createPalette","palette","contrastThreshold","success","warning","getContrastText","contrastText","contrast","augmentColor","mainShade","lightShade","darkShade","modes","round","caseAllCaps","defaultFontFamily","createTypography","typography","fontFamily","fontSize","fontWeightLight","fontWeightRegular","fontWeightMedium","fontWeightBold","htmlFontSize","allVariants","pxToRem2","coef","pxToRem","buildVariant","fontWeight","lineHeight","letterSpacing","casing","shadowKeyUmbraOpacity","shadowKeyPenumbraOpacity","shadowAmbientShadowOpacity","createShadow","px","shadows","shadows$1","easing","duration","formatMs","milliseconds","getAutoHeightDuration","constant","createTransitions","inputTransitions","mergedEasing","mergedDuration","durationOption","easingOption","isString","isNumber","animatedProp","zIndex","zIndex$1","mixinsInput","transitionsInput","typographyInput","systemTheme","systemCreateTheme","stateClasses","component","child","stateClass","defaultTheme$1","THEME_ID","systemUseThemeProps","styled","styled$1","getSvgIconUtilityClass","useUtilityClasses","SvgIconRoot","_theme$transitions","_theme$transitions$cr","_theme$transitions2","_theme$typography","_theme$typography$pxT","_theme$typography2","_theme$typography2$px","_theme$typography3","_theme$typography3$px","_palette$ownerState$c","_palette","_palette2","_palette3","SvgIcon","inProps","htmlColor","inheritViewBox","titleAccess","viewBox","hasSvgAsChild","more","_jsxs","_jsx","SvgIcon$1","createSvgIcon","unstable_ClassNameGenerator","exports","_utils","ArrowRight","default_1","_createSvgIcon","_jsxRuntime","isHostComponent","appendOwnerState","otherProps","defaultContextValue","ClassNameConfiguratorContext","useClassNamesOverride","disableDefaultClasses","extractEventHandlers","excludeKeys","resolveComponentProps","componentProps","slotState","omitEventHandlers","mergeSlotProps","parameters","getSlotProps","additionalProps","externalSlotProps","externalForwardedProps","joinedClasses","mergedStyle","eventHandlers","componentsPropsWithoutEventHandlers","otherPropsWithoutEventHandlers","internalSlotProps","useSlotProps","_parameters$additiona","skipResolvingSlotProps","rest","resolvedComponentsProps","mergedProps","internalRef","GLOBAL_CLASS_PREFIX","buildStateClass","buildSlotClass","getContainer","container","forwardedRef","disablePortal","mountNode","setMountNode","handleRef","newProps","ReactDOM","top","bottom","right","left","auto","basePlacements","clippingParents","viewport","popper","reference","variationPlacements","placement","placements","beforeRead","read","afterRead","beforeMain","main","afterMain","beforeWrite","write","afterWrite","modifierPhases","getNodeName","getWindow","OwnElement","isHTMLElement","isShadowRoot","attributes","effect","_ref2","initialStyles","styleProperties","attribute","applyStyles$1","getBasePlacement","getUAString","uaData","isLayoutViewport","getBoundingClientRect","includeScale","isFixedStrategy","clientRect","scaleX","scaleY","visualViewport","addVisualOffsets","getLayoutRect","contains","parent","rootNode","next","getComputedStyle","isTableElement","getDocumentElement","getParentNode","getTrueOffsetParent","getContainingBlock","isFirefox","isIE","elementCss","currentNode","getOffsetParent","window","offsetParent","getMainAxisFromPlacement","within","mathMax","mathMin","withinMaxClamp","getFreshSideObject","mergePaddingObject","paddingObject","expandToHashMap","hashMap","toPaddingObject","arrow","_state$modifiersData$","arrowElement","popperOffsets","basePlacement","axis","isVertical","len","arrowRect","minProp","maxProp","endDiff","startDiff","arrowOffsetParent","clientSize","centerToReference","center","offset","axisProp","_options$element","arrow$1","getVariation","unsetSides","roundOffsetsByDPR","win","dpr","mapToStyles","_Object$assign2","popperRect","variation","offsets","gpuAcceleration","adaptive","roundOffsets","isFixed","_offsets$x","_offsets$y","_ref3","hasX","hasY","sideX","sideY","heightProp","widthProp","offsetY","offsetX","commonStyles","_ref4","_Object$assign","computeStyles","_ref5","_options$gpuAccelerat","_options$adaptive","_options$roundOffsets","computeStyles$1","passive","_options$scroll","scroll","_options$resize","resize","scrollParents","scrollParent","eventListeners","hash","getOppositePlacement","matched","getOppositeVariationPlacement","getWindowScroll","scrollLeft","scrollTop","getWindowScrollBarX","getViewportRect","strategy","html","layoutViewport","getDocumentRect","_element$ownerDocumen","winScroll","body","isScrollParent","_getComputedStyle","overflow","overflowX","overflowY","getScrollParent","listScrollParents","list","isBody","updatedList","rectToClientRect","rect","getInnerBoundingClientRect","getClientRectFromMixedType","clippingParent","getClippingParents","canEscapeClipping","clipperElement","getClippingRect","boundary","rootBoundary","mainClippingParents","firstClippingParent","clippingRect","accRect","computeOffsets","commonX","commonY","mainAxis","detectOverflow","_options","_options$placement","_options$strategy","_options$boundary","_options$rootBoundary","_options$elementConte","elementContext","_options$altBoundary","altBoundary","_options$padding","altContext","clippingClientRect","referenceClientRect","popperClientRect","elementClientRect","overflowOffsets","offsetData","multiply","computeAutoPlacement","flipVariations","_options$allowedAutoP","allowedAutoPlacements","allPlacements","allowedPlacements","overflows","getExpandedFallbackPlacements","oppositePlacement","flip","_options$mainAxis","checkMainAxis","_options$altAxis","checkAltAxis","specifiedFallbackPlacements","_options$flipVariatio","preferredPlacement","isBasePlacement","fallbackPlacements","referenceRect","checksMap","makeFallbackChecks","firstFittingPlacement","_basePlacement","isStartVariation","mainVariationSide","altVariationSide","checks","check","numberOfChecks","_loop","_i","fittingPlacement","_ret","flip$1","getSideOffsets","preventedOffsets","isAnySideFullyClipped","hide","referenceOverflow","popperAltOverflow","referenceClippingOffsets","popperEscapeOffsets","isReferenceHidden","hasPopperEscaped","hide$1","distanceAndSkiddingToXY","rects","invertDistance","skidding","distance","_options$offset","_data$state$placement","offset$1","popperOffsets$1","getAltAxis","preventOverflow","_options$tether","tether","_options$tetherOffset","tetherOffset","altAxis","tetherOffsetValue","normalizedTetherOffsetValue","offsetModifierState","_offsetModifierState$","mainSide","altSide","additive","minLen","maxLen","arrowPaddingObject","arrowPaddingMin","arrowPaddingMax","arrowLen","minOffset","maxOffset","clientOffset","offsetModifierValue","tetherMin","tetherMax","preventedOffset","_offsetModifierState$2","_mainSide","_altSide","_offset","_len","_min","_max","isOriginSide","_offsetModifierValue","_tetherMin","_tetherMax","_preventedOffset","preventOverflow$1","getHTMLElementScroll","getNodeScroll","isElementScaled","getCompositeRect","elementOrVirtualElement","isOffsetParentAnElement","offsetParentIsScaled","documentElement","order","modifiers","map","visited","modifier","sort","requires","dep","depModifier","orderModifiers","orderedModifiers","phase","pending","resolve","mergeByName","merged","current","existing","DEFAULT_OPTIONS","areValidElements","_key","popperGenerator","generatorOptions","_generatorOptions","_generatorOptions$def","defaultModifiers","_generatorOptions$def2","defaultOptions","effectCleanupFns","isDestroyed","setOptionsAction","cleanupModifierEffects","runModifierEffects","_state$elements","_state$orderedModifie","_state$orderedModifie2","_ref$options","cleanupFn","noopFn","createPopper","COMPONENT_NAME","getPopperUtilityClass","flipPlacement","resolveAnchorEl","anchorEl","isVirtualElement","defaultPopperOptions","PopperTooltip","_slots$root","initialPlacement","popperOptions","popperRefProp","TransitionProps","tooltipRef","ownRef","popperRef","handlePopperRef","handlePopperRefRef","rtlPlacement","setPlacement","resolvedAnchorElement","setResolvedAnchorElement","handlePopperUpdate","box","popperModifiers","childProps","Root","rootProps","Popper","containerProp","keepMounted","transition","exited","setExited","handleEnter","handleExited","resolvedAnchorEl","display","transitionProps","useThemeSystem","_setPrototypeOf","_inheritsLoose","subClass","superClass","setPrototypeOf","timeoutsShape","TransitionGroupContext","forceReflow","UNMOUNTED","EXITED","ENTERING","ENTERED","EXITING","Transition","_React$Component","_this","parentGroup","appear","initialStatus","prevState","nextIn","_proto","prevProps","nextStatus","exit","enter","mounting","_this2","appearing","maybeNode","maybeAppearing","timeouts","enterTimeout","_this3","nextState","callback","_this4","active","handler","doesNotHaveTimeoutOrListener","maybeNextCallback","_this$props","pt","noop","Transition$1","reflow","getTransitionProps","_style$transitionDura","_style$transitionTimi","getScale","isWebKit154","Grow","addEndListener","inProp","onEnter","onEntered","onEntering","onExit","onExited","onExiting","TransitionComponent","timer","autoTimeout","nodeRef","normalizedTransitionCallback","maybeIsAppearing","handleEntering","isAppearing","transitionDuration","transitionTimingFunction","handleEntered","handleExiting","handleExit","Grow$1","PopperRoot","BasePopper","components","componentsProps","RootComponent","Popper$1","getTooltipUtilityClass","tooltipClasses","tooltipClasses$1","disableInteractive","touch","TooltipPopper","TooltipTooltip","TooltipArrow","hystersisOpen","hystersisTimer","cursorPosition","composeEventHandler","eventHandler","_slots$popper","_slots$transition","_slots$tooltip","_slots$arrow","_slotProps$popper","_ref6","_slotProps$popper2","_slotProps$transition","_slotProps$tooltip","_ref7","_slotProps$tooltip2","_slotProps$arrow","_ref8","_slotProps$arrow2","childrenProp","describeChild","disableFocusListener","disableHoverListener","disableInteractiveProp","disableTouchListener","enterDelay","enterNextDelay","enterTouchDelay","followCursor","idProp","leaveDelay","leaveTouchDelay","onClose","onOpen","PopperComponentProp","PopperProps","title","TransitionComponentProp","isRtl","childNode","setChildNode","arrowRef","setArrowRef","ignoreNonTouchEvents","closeTimer","enterTimer","leaveTimer","touchTimer","setOpenState","prevUserSelect","stopTouchInteraction","handleOpen","handleClose","handleLeave","focusVisibleRef","setChildIsFocusVisible","handleBlur","handleFocus","detectTouchStart","childrenProps","handleMouseOver","handleMouseLeave","handleTouchStart","handleTouchEnd","nativeEvent","handleMouseMove","nameOrDescProps","titleIsString","interactiveWrapperListeners","_PopperProps$popperOp","tooltipModifiers","PopperComponent","TooltipComponent","ArrowComponent","popperProps","tooltipProps","tooltipArrowProps","TransitionPropsInner","Tooltip$1","getIcon","icon","menuLabel","leading","MuiListItemIcon","MenuItem","allowForLeadingIcons","iconPathBefore","iconPathAfter","hasAutoFocus","isDense","isSubMenuParent","hasDisabledGutters","hasDivider","focusVisibleClassName","menuItem","MuiMenuItem","MuiListItemText","getAllGroups","menuDefinition","SubMenu","setAnchorEl","parentMenuItem","parentItemProps","handleParentMenuItemClick","renderSubMenuItems","includedGroups","group","GroupedMenuItemList","Menu","getOrderedGroupItems","groupId","allItems","menuProps","commandHandler","groupsToInclude","sortedGroups","itemArray","allowSpaceForLeadingIcons","createMenuItemProps","isLastItemInGroup","divKey","itemInfo","menuItemProps","TopLevelMenu","columnId","MenuColumn","metadata","Grid","List","GridMenu","multiColumnMenu","sortedColumns","columnNumbers","columnName","col","getUsePromiseOptionsDefaults","usePromise","promiseFactoryCallback","defaultValueRef","optionsDefaultedRef","setIsLoading","promiseIsCurrent","MenuIcon","HamburgerMenuButton","menuProvider","normalMenu","fullMenu","containerRef","ariaLabelPrefix","isMenuOpen","setMenuOpen","showFullMenu","setShowFullMenu","handleMenuItemClick","handleMenuButtonClick","prevIsOpen","isOpening","menuCommandHandler","command","setOffset","normalMenuData","fullMenuData","menu","IconButton","Drawer","isTooltipSuppressed","adjustMarginToAlignToEdge","MuiIconButton","Spinner","LoaderCircle","TextField","hasError","helperText","onFocus","onBlur","ShadLabel","Toolbar","AppBar","MuiToolbar","alertVariants","Alert","AlertTitle","AlertDescription","Card","CardHeader","CardTitle","CardDescription","CardContent","CardFooter","Sonner","Toaster","Slider","SliderPrimitive","Switch","SwitchPrimitives","Tabs","TabsList","TabsTrigger","TabsContent","InstallButton","isInstalling","handleClick","buttonText","Download","EnableButton","isEnabling","DisableButton","isDisabling","UpdateButton","isUpdating","MarkdownRenderer","markdown","anchorTarget","Markdown","FilterButton","Filter","DropdownMenuItemType","DropdownMenuItemType2","FilterDropdown","groups","NoExtensionsFound","MoreInfo","category","downloads","languages","moreInfoUrl","numberFormatted","NumberFormat","handleScrollToBottom","User","locale","LucideLink","CircleHelp","VersionHistory","versionHistory","showAllVersions","setShowAllVersions","currentDate","formatTimeString","dateString","date","dateDiff","yearDiff","monthDiff","dayDiff","timeString","sortedEntries","Footer","publisherDisplayName","fileSize","locales","formattedFileSize","formatBytes","languageNames","codes","displayNames","useEvent","unsubscriber","noopUnsubscriber","useEventAsync","unsubscribe","unsub"],"mappings":";;;;;;;;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;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","x_google_ignoreList":[3,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,83,84,85,86,87,88,89,90,91,92,93,94,95,96,97,98,99,100,101,102,103,104,105,106,107,108,109,110,111,112,113,114,115,116,117,118,119,120,121,122,123,124,125,126,127,128,129,130,131,132,133,134,135,136,137,138,139,140,141,142,143,144,145,146,147,148,149,150,151,152,153,154,155,156,157,158,159,160,161,162,163,164,165,166,167,168,169,170,171,172,173,174,175,176,177,178,179,180,181,182,183,184,185,186,187,188,189,190,191,192,193,194,195,196,197,198,199,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,228]} \ No newline at end of file diff --git a/lib/platform-bible-react/src/components/advanced/settings-components/settings-card.component.tsx b/lib/platform-bible-react/src/components/advanced/settings-components/settings-card.component.tsx deleted file mode 100644 index dbc66ffc72..0000000000 --- a/lib/platform-bible-react/src/components/advanced/settings-components/settings-card.component.tsx +++ /dev/null @@ -1,36 +0,0 @@ -import { - Card, - CardDescription, - CardHeader, - CardTitle, - CardContent, -} from '@/components/shadcn-ui/card'; -import { PropsWithChildren } from 'react'; - -type SettingsCardProps = PropsWithChildren & { - /** Optional id for testing */ - id?: string; - - /** Label of the settings group */ - settingsGroupLabel: string; - - /** Optional description of the settings group */ - settingsGroupDescription?: string; -}; - -export default function SettingsCard({ - id, - settingsGroupLabel, - settingsGroupDescription, - children, -}: SettingsCardProps) { - return ( - - - {settingsGroupLabel} - {settingsGroupDescription && {settingsGroupDescription}} - - {children} - - ); -} diff --git a/lib/platform-bible-react/src/components/advanced/settings-components/settings-sidebar-content-search.component.tsx b/lib/platform-bible-react/src/components/advanced/settings-components/settings-sidebar-content-search.component.tsx index e418d3af1c..2f3da42869 100644 --- a/lib/platform-bible-react/src/components/advanced/settings-components/settings-sidebar-content-search.component.tsx +++ b/lib/platform-bible-react/src/components/advanced/settings-components/settings-sidebar-content-search.component.tsx @@ -26,7 +26,7 @@ export default function SettingsSidebarContentSearch({ onSearch, }: SettingsSidebarContentSearchProps) { return ( -
    +
    - + Promise; /** Restart the application */ 'platform.restart': () => Promise; - 'platform.openSettings': (webViewId?: string) => Promise; + 'platform.openSettings': (webViewId?: WebViewId) => Promise; // These commands are provided in `extension-host.ts`. They are only here because I needed them to // use in other places, but building `papi-dts` wasn't working because it didn't see // `extension-host.ts` diff --git a/src/extension-host/data/menu.data.json b/src/extension-host/data/menu.data.json index b1d883cadc..6657d47d5e 100644 --- a/src/extension-host/data/menu.data.json +++ b/src/extension-host/data/menu.data.json @@ -76,6 +76,13 @@ "group": "platform.projectTop", "order": 2, "command": "platform.assignments" + }, + { + "label": "%webview_openProjectSettings%", + "localizeNotes": "Web view main menu > Project > Open Project Settings...", + "group": "platform.projectTop", + "order": 3, + "command": "platform.openSettings" } ] }, diff --git a/src/renderer/components/settings-tabs/settings-components/project-or-other-settings-list.component.tsx b/src/renderer/components/settings-tabs/settings-components/project-or-other-settings-list.component.tsx index e121a29550..38f498a0f3 100644 --- a/src/renderer/components/settings-tabs/settings-components/project-or-other-settings-list.component.tsx +++ b/src/renderer/components/settings-tabs/settings-components/project-or-other-settings-list.component.tsx @@ -1,5 +1,5 @@ import { Localized, ProjectSettingProperties, SettingProperties } from 'platform-bible-utils'; -import { SettingsCard } from 'platform-bible-react'; +import { Card, CardContent, CardDescription, CardHeader, CardTitle } from 'platform-bible-react'; import { useMemo } from 'react'; import { ProjectSettingNames, SettingNames } from 'papi-shared-types'; import OtherSetting from './other-setting.component'; @@ -47,37 +47,43 @@ export default function ProjectOrOtherSettingsList({ }, [searchQuery, settingProperties]); return ( - -
    - {Object.entries(filteredSettingsProperties).map(([key, property]) => - projectId ? ( - - ) : ( - - ), - )} -
    -
    + + + {groupLabel} + {groupDescription && {groupDescription}} + + +
    + {Object.entries(filteredSettingsProperties).map(([key, property]) => + projectId ? ( + + ) : ( + + ), + )} +
    +
    +
    ); } diff --git a/src/renderer/components/settings-tabs/settings-tab.component.scss b/src/renderer/components/settings-tabs/settings-tab.component.scss index 4a6b06f3de..1264c138f1 100644 --- a/src/renderer/components/settings-tabs/settings-tab.component.scss +++ b/src/renderer/components/settings-tabs/settings-tab.component.scss @@ -3,7 +3,19 @@ height: inherit; } +.project-settings-tab { + padding: 2%; + display: flex; + flex-direction: column; + gap: 5%; + overflow-y: auto; +} + .sidebar { position: relative; overflow: hidden; } + +.sidebar-container { + height: 100%; +} diff --git a/src/renderer/components/settings-tabs/settings-tab.component.tsx b/src/renderer/components/settings-tabs/settings-tab.component.tsx index e8020195eb..e8acf6ad82 100644 --- a/src/renderer/components/settings-tabs/settings-tab.component.tsx +++ b/src/renderer/components/settings-tabs/settings-tab.component.tsx @@ -24,6 +24,13 @@ type SettingsTabProps = { projectIdToLimitSettings?: string; }; +async function getProjectName(projectIdToGetName: string) { + const pdp = await projectDataProviders.get('platform.base', projectIdToGetName); + const projectName = await pdp.getSetting('platform.name'); + + return projectName; +} + export default function SettingsTab({ projectIdToLimitSettings }: SettingsTabProps) { const [selectedSidebarItem, setSelectedSidebarItem] = useState({ label: '', @@ -72,29 +79,24 @@ export default function SettingsTab({ projectIdToLimitSettings }: SettingsTabPro ), ); }, []), - useMemo(() => { - return undefined; - }, []), + useMemo(() => undefined, []), ); - const [filteredProjectSettingsContributions]: [ - Localized | undefined, - boolean, - ] = usePromise( + const [filteredProjectSettingsContributions] = usePromise( useCallback(async () => { - if (!selectedSidebarItem.projectId) return undefined; + if (!projectIdToLimitSettings && !selectedSidebarItem.projectId) return undefined; + + const projectId = projectIdToLimitSettings || selectedSidebarItem.projectId; - const projectInterfacesFromProjectId = ( - await projectLookupService.getMetadataForProject(selectedSidebarItem.projectId) - ).projectInterfaces; + const projectInterfacesFromProjectId = + // eslint-disable-next-line no-type-assertion/no-type-assertion + (await projectLookupService.getMetadataForProject(projectId!)).projectInterfaces; - return ( - filterProjectSettingsContributionsByProjectInterfaces( - projectSettingsContributions, - projectInterfacesFromProjectId, - ) || {} + return filterProjectSettingsContributionsByProjectInterfaces( + projectSettingsContributions, + projectInterfacesFromProjectId, ); - }, [projectSettingsContributions, selectedSidebarItem]), + }, [projectIdToLimitSettings, selectedSidebarItem.projectId, projectSettingsContributions]), useMemo(() => undefined, []), ); @@ -106,26 +108,6 @@ export default function SettingsTab({ projectIdToLimitSettings }: SettingsTabPro useMemo(() => [], []), ); - const projectNameCache: { [projectId: string]: string } = useMemo(() => { - return {}; - }, []); - - const getProjectName = useCallback( - async (projectIdToGetName: string) => { - if (projectNameCache[projectIdToGetName]) { - return projectNameCache[projectIdToGetName]; - } - - const pdp = await projectDataProviders.get('platform.base', projectIdToGetName); - const projectName = await pdp.getSetting('platform.name'); - - projectNameCache[projectIdToGetName] = projectName; - - return projectName; - }, - [projectNameCache], - ); - const [allProjectOptions]: [ProjectOptions[], boolean] = usePromise( useCallback(async () => { const projectOptions = await Promise.all( @@ -135,25 +117,21 @@ export default function SettingsTab({ projectIdToLimitSettings }: SettingsTabPro })), ); return projectOptions; - }, [allProjectIdsFromMetadata, getProjectName]), + }, [allProjectIdsFromMetadata]), useMemo(() => [], []), ); - if (!settingsContributions) return
    No Settings
    ; - if (isLoadingSettingsContributions || isLoadingProjectSettingsContributions) - return
    Loading Settings
    ; - const renderProjectSettingsList = ( - contributions: Localized, + contributions: Localized | undefined, projectId: string, ) => { - if (!contributions) return undefined; + if (!contributions) return
    No settings available for this project.
    ; - return Object.entries(contributions).map(([, settingsGroups]) => + return Object.entries(contributions).flatMap(([, settingsGroups]) => settingsGroups ? Object.entries(settingsGroups).map(([, settingsGroup]) => ( )) - : undefined, + : [], ); }; if (projectIdToLimitSettings) { - // setSelectedSidebarItem({ label: '', projectId: projectIdToLimitSettings }); - return ( -
    - {filteredProjectSettingsContributions - ? renderProjectSettingsList( - filteredProjectSettingsContributions, - projectIdToLimitSettings, - ) - : 'No settings'} +
    + {filteredProjectSettingsContributions ? ( + renderProjectSettingsList(filteredProjectSettingsContributions, projectIdToLimitSettings) + ) : ( +
    Loading settings...
    + )}
    ); } + if (isLoadingSettingsContributions || isLoadingProjectSettingsContributions) + return
    Loading Settings
    ; + + if (!settingsContributions) return
    No Settings
    ; + return (
    @@ -221,7 +201,6 @@ export const loadSettingsTab = (savedTabInfo: SavedTabInfo): TabInfo => { // eslint-disable-next-line no-type-assertion/no-type-assertion const tabData: SettingsTabData = savedTabInfo.data as SettingsTabData; - // TODO project name in title ? const title = tabData.projectIdToLimitSettings ? 'Project Settings' : 'Settings'; return { diff --git a/src/renderer/services/web-view.service-host.ts b/src/renderer/services/web-view.service-host.ts index 241b314b2b..6bf47ce0e6 100644 --- a/src/renderer/services/web-view.service-host.ts +++ b/src/renderer/services/web-view.service-host.ts @@ -1430,13 +1430,13 @@ async function openSettingsTab(webViewId: WebViewId): Promise Date: Tue, 26 Nov 2024 11:01:42 -0500 Subject: [PATCH 05/18] Fix proj settings values not loading bug --- .../settings-components/setting.component.tsx | 27 +++-- .../settings-tabs/settings-tab.component.tsx | 104 +++++++++++------- 2 files changed, 81 insertions(+), 50 deletions(-) diff --git a/src/renderer/components/settings-tabs/settings-components/setting.component.tsx b/src/renderer/components/settings-tabs/settings-components/setting.component.tsx index c4a396424e..51e0889039 100644 --- a/src/renderer/components/settings-tabs/settings-components/setting.component.tsx +++ b/src/renderer/components/settings-tabs/settings-components/setting.component.tsx @@ -1,4 +1,4 @@ -import { ChangeEvent, useCallback, useState } from 'react'; +import { ChangeEvent, useCallback, useMemo, useState } from 'react'; import { ProjectSettingNames, ProjectSettingTypes, @@ -10,7 +10,7 @@ import { debounce, getErrorMessage } from 'platform-bible-utils'; import { DataProviderUpdateInstructions } from '@shared/models/data-provider.model'; import { SettingDataTypes } from '@shared/services/settings.service-model'; import logger from '@shared/services/logger.service'; -// import { useLocalizedStrings } from '@renderer/hooks/papi-hooks'; +import { useLocalizedStrings } from '@renderer/hooks/papi-hooks'; /** Props shared between the user and project setting components */ type BaseSettingProps = { @@ -100,6 +100,7 @@ export default function Setting({ settingKey, setting, setSetting, + isLoading, validateOtherSetting, validateProjectSetting, label, @@ -191,16 +192,22 @@ export default function Setting({ ); }, [setting, settingKey, debouncedHandleChange, errorMessage]); - // const loadingSettingKey = '%settings_defaultMessage_loadingSetting%'; - // const [localizedStrings] = useLocalizedStrings(useMemo(() => [loadingSettingKey], [])); - // const localizedLoadingSetting = localizedStrings[loadingSettingKey]; + const loadingSettingKey = '%settings_defaultMessage_loadingSetting%'; + const [localizedStrings] = useLocalizedStrings(useMemo(() => [loadingSettingKey], [])); + const localizedLoadingSetting = localizedStrings[loadingSettingKey]; return ( -
    - - {generateComponent()} +
    + {isLoading ? ( + + ) : ( +
    + + {generateComponent()} +
    + )}
    ); } diff --git a/src/renderer/components/settings-tabs/settings-tab.component.tsx b/src/renderer/components/settings-tabs/settings-tab.component.tsx index e8acf6ad82..49251b33e5 100644 --- a/src/renderer/components/settings-tabs/settings-tab.component.tsx +++ b/src/renderer/components/settings-tabs/settings-tab.component.tsx @@ -13,8 +13,8 @@ import settingsService from '@shared/services/settings.service'; import './settings-tab.component.scss'; import projectLookupService from '@shared/services/project-lookup.service'; import { projectDataProviders } from '@renderer/services/papi-frontend.service'; -import { ProjectSettingsContributionInfo } from '@shared/utils/project-settings-document-combiner'; -import { Localized } from 'platform-bible-utils'; +// import { ProjectSettingsContributionInfo } from '@shared/utils/project-settings-document-combiner'; +// import { Localized } from 'platform-bible-utils'; import ProjectOrOtherSettingsList from './settings-components/project-or-other-settings-list.component'; export const TAB_TYPE_SETTINGS_TAB = 'settings-tab'; @@ -24,6 +24,11 @@ type SettingsTabProps = { projectIdToLimitSettings?: string; }; +async function getAllProjectIdsFromMetadata() { + const allMetadata = await projectLookupService.getMetadataForAllProjects(); + return allMetadata.flatMap((metadata) => metadata.id); +} + async function getProjectName(projectIdToGetName: string) { const pdp = await projectDataProviders.get('platform.base', projectIdToGetName); const projectName = await pdp.getSetting('platform.name'); @@ -89,6 +94,7 @@ export default function SettingsTab({ projectIdToLimitSettings }: SettingsTabPro const projectId = projectIdToLimitSettings || selectedSidebarItem.projectId; const projectInterfacesFromProjectId = + // We check for a valid projectId above // eslint-disable-next-line no-type-assertion/no-type-assertion (await projectLookupService.getMetadataForProject(projectId!)).projectInterfaces; @@ -100,16 +106,14 @@ export default function SettingsTab({ projectIdToLimitSettings }: SettingsTabPro useMemo(() => undefined, []), ); - const [allProjectIdsFromMetadata] = usePromise( - useCallback(async () => { - const allMetadata = await projectLookupService.getMetadataForAllProjects(); - return allMetadata.flatMap((metadata) => metadata.id); - }, []), - useMemo(() => [], []), - ); - const [allProjectOptions]: [ProjectOptions[], boolean] = usePromise( useCallback(async () => { + const allProjectIdsFromMetadata = await getAllProjectIdsFromMetadata(); + + if (allProjectIdsFromMetadata.length === 0) { + return []; + } + const projectOptions = await Promise.all( allProjectIdsFromMetadata.map(async (id) => ({ projectId: id, @@ -117,37 +121,60 @@ export default function SettingsTab({ projectIdToLimitSettings }: SettingsTabPro })), ); return projectOptions; - }, [allProjectIdsFromMetadata]), - useMemo(() => [], []), + }, []), + [], ); - const renderProjectSettingsList = ( - contributions: Localized | undefined, - projectId: string, - ) => { - if (!contributions) return
    No settings available for this project.
    ; - - return Object.entries(contributions).flatMap(([, settingsGroups]) => - settingsGroups - ? Object.entries(settingsGroups).map(([, settingsGroup]) => ( - - )) - : [], - ); - }; + // const renderProjectSettingsList = ( + // contributions: Localized | undefined, + // projectId: string, + // ) => { + // if (!contributions) return
    No settings available for this project.
    ; + + // return Object.entries(contributions).flatMap(([, settingsGroups]) => + // settingsGroups + // ? Object.entries(settingsGroups).map(([, settingsGroup]) => ( + // + // )) + // : [], + // ); + // }; + + const renderProjectSettingsList = useCallback( + (projectId: string) => { + if (!filteredProjectSettingsContributions) + return
    No settings available for this project.
    ; + + return Object.entries(filteredProjectSettingsContributions).flatMap(([, settingsGroups]) => + settingsGroups + ? Object.entries(settingsGroups).map(([, settingsGroup]) => ( + + )) + : [], + ); + }, + [filteredProjectSettingsContributions, searchQuery], + ); if (projectIdToLimitSettings) { return (
    {filteredProjectSettingsContributions ? ( - renderProjectSettingsList(filteredProjectSettingsContributions, projectIdToLimitSettings) + renderProjectSettingsList(projectIdToLimitSettings) ) : (
    Loading settings...
    )} @@ -173,18 +200,15 @@ export default function SettingsTab({ projectIdToLimitSettings }: SettingsTabPro onSearch={handleSearchInput} >
    - {selectedSidebarItem.projectId && filteredProjectSettingsContributions - ? renderProjectSettingsList( - filteredProjectSettingsContributions, - selectedSidebarItem.projectId, - ) + {selectedSidebarItem.projectId + ? renderProjectSettingsList(selectedSidebarItem.projectId) : settingsContributions[selectedSidebarItem.label]?.map((group) => ( ))}
    From 2ce92233b73ea8bb4e12fa671159f97815beec6c Mon Sep 17 00:00:00 2001 From: Jolie Rabideau Date: Tue, 26 Nov 2024 11:44:24 -0500 Subject: [PATCH 06/18] Remove comments, add localized strings --- assets/localization/en.json | 12 +- assets/localization/es.json | 2 +- lib/platform-bible-react/dist/index.cjs | 92 +- lib/platform-bible-react/dist/index.cjs.map | 2 +- lib/platform-bible-react/dist/index.d.ts | 8 +- lib/platform-bible-react/dist/index.js | 1180 +++++++++-------- lib/platform-bible-react/dist/index.js.map | 2 +- ...tings-sidebar-content-search.component.tsx | 4 + .../settings-sidebar.component.tsx | 16 +- .../components/platform-bible-menu.data.ts | 2 +- .../settings-components/setting.component.tsx | 30 +- .../settings-tabs/settings-tab.component.tsx | 53 +- 12 files changed, 720 insertions(+), 683 deletions(-) diff --git a/assets/localization/en.json b/assets/localization/en.json index e59a8415c1..06fe9f5b75 100644 --- a/assets/localization/en.json +++ b/assets/localization/en.json @@ -49,11 +49,19 @@ "%selectBooks_title_selectBooks%": "Select Books", "%selectMultipleProjects_title_selectProjects%": "Select Projects", "%selectProject_title%": "Select Project", - "%settings_defaultMessage_loadingSetting%": "Loading setting", + "%settings_defaultMessage_loadingOneSetting%": "Loading setting", + "%settings_defaultMessage_loadingSettings%": "Loading settings...", + "%settings_defaultMessage_noSettingComponent%": "No setting component", + "%settings_defaultMessage_noSettingsForThisProject%": "No settings available for this project.", "%settings_defaultSearchText_searchProject%": "Search Project Settings...", "%settings_defaultSearchText_searchUserSettings%": "Search User Settings...", + "%settings_errorMessages_invalidNumber%": "Invalid number", + "%settings_errorMessages_invalidJSON%": "Invalid JSON", + "%settings_errorMessages_invalidValue%": "Invalid value", + "%settings_sidebar_extensionsLabel%": "Extensions", + "%settings_sidebar_projectsLabel%": "Projects", "%settings_title_projectSettings%": "Project Settings", - "%settings_title_userSettings%": "User Settings", + "%settings_title%": "Settings", "%submitButton%": "Submit", "%scrollGroup_undefined%": "Ø", "%scrollGroup_0%": "A", diff --git a/assets/localization/es.json b/assets/localization/es.json index 4c4180c6cd..46bf7f5455 100644 --- a/assets/localization/es.json +++ b/assets/localization/es.json @@ -182,7 +182,7 @@ "%settings_platform_verseRef_description%": "Referencia de Verso Actual para el Grupo de Desplazamiento A. Obsoleto - Por favor use `papi.scrollGroups` y `useWebViewScrollGroupScrRef`", "%settings_platform_verseRef_label%": "Referencia de Verso Actual para el Grupo de Desplazamiento A (Obsoleto)", "%settings_title_projectSettings%": "Configuración del Proyecto", - "%settings_title_userSettings%": "Configuración del Usuario", + "%settings_title%": "Configuración", "%some_localization_key%": "Esto es el texto en español para %some_localization_key%.", "%submitButton%": "Enviar", "%tab_aria_tab%": "Pestaña", diff --git a/lib/platform-bible-react/dist/index.cjs b/lib/platform-bible-react/dist/index.cjs index d7659007e5..2221a01654 100644 --- a/lib/platform-bible-react/dist/index.cjs +++ b/lib/platform-bible-react/dist/index.cjs @@ -1,23 +1,23 @@ -"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const a=require("react/jsx-runtime"),g=require("react"),Q=require("lucide-react"),ot=require("clsx"),ml=require("tailwind-merge"),Za=require("@radix-ui/react-dropdown-menu"),W=require("platform-bible-utils"),Ht=require("@radix-ui/react-slot"),Xt=require("class-variance-authority"),hl=require("@radix-ui/react-label"),gl=require("@radix-ui/react-radio-group"),bl=require("@radix-ui/react-popover"),Re=require("cmdk"),vl=require("@radix-ui/react-dialog"),Se=require("@tanstack/react-table"),xl=require("@radix-ui/react-select"),yl=require("@radix-ui/react-checkbox"),Nl=require("@radix-ui/react-toggle-group"),kl=require("@radix-ui/react-toggle"),Sl=require("@radix-ui/react-tabs"),El=require("@radix-ui/react-separator"),jl=require("@radix-ui/react-tooltip"),Gr=require("@mui/styled-engine"),Me=require("@mui/material"),ln=require("react-dom"),Qa=require("sonner"),Cl=require("@radix-ui/react-slider"),Tl=require("@radix-ui/react-switch"),Rl=require("markdown-to-jsx");function ke(e){const t=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(e){for(const n in e)if(n!=="default"){const r=Object.getOwnPropertyDescriptor(e,n);Object.defineProperty(t,n,r.get?r:{enumerable:!0,get:()=>e[n]})}}return t.default=e,Object.freeze(t)}const M=ke(g),pe=ke(Za),es=ke(hl),bn=ke(gl),vn=ke(bl),be=ke(vl),ge=ke(xl),Ur=ke(yl),rr=ke(Nl),ts=ke(kl),Oe=ke(Sl),ns=ke(El),Sn=ke(jl),Ol=ke(ln),cn=ke(Cl),qr=ke(Tl);const _l=ml.extendTailwindMerge({prefix:"tw-"});function N(...e){return _l(ot.clsx(e))}const St=g.forwardRef(({className:e,type:t,...n},r)=>a.jsx("input",{type:t,className:N("pr-twp tw-flex tw-h-10 tw-rounded-md tw-border tw-border-input tw-bg-background tw-px-3 tw-py-2 tw-text-sm tw-ring-offset-background file:tw-border-0 file:tw-bg-transparent file:tw-text-sm file:tw-font-medium file:tw-text-foreground placeholder:tw-text-muted-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-cursor-not-allowed disabled:tw-opacity-50",e),ref:r,...n}));St.displayName="Input";const Pl=g.forwardRef(({handleSearch:e,handleKeyDown:t,handleOnClick:n,handleSubmit:r,...o},s)=>a.jsxs("div",{className:"tw-relative",children:[a.jsx(St,{...o,type:"text",className:"tw-box-border tw-gap-2.5 tw-rounded-lg tw-border tw-border-solid tw-bg-background tw-py-2 tw-pl-4 tw-pr-3 tw-font-medium tw-shadow-none tw-outline-none",onChange:i=>e(i.target.value),onKeyDown:i=>{i.key==="Enter"&&r(),t(i)},onClick:n,ref:s}),a.jsx(Q.History,{className:"tw-absolute tw-right-3 tw-top-1/2 tw-h-4 tw-w-4 tw--translate-y-1/2 tw-transform tw-cursor-pointer tw-text-muted-foreground",onClick:()=>{console.log("back in history")}})]}));var Il=Object.defineProperty,Ml=(e,t,n)=>t in e?Il(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,ne=(e,t,n)=>Ml(e,typeof t!="symbol"?t+"":t,n);const gt=["GEN","EXO","LEV","NUM","DEU","JOS","JDG","RUT","1SA","2SA","1KI","2KI","1CH","2CH","EZR","NEH","EST","JOB","PSA","PRO","ECC","SNG","ISA","JER","LAM","EZK","DAN","HOS","JOL","AMO","OBA","JON","MIC","NAM","HAB","ZEP","HAG","ZEC","MAL","MAT","MRK","LUK","JHN","ACT","ROM","1CO","2CO","GAL","EPH","PHP","COL","1TH","2TH","1TI","2TI","TIT","PHM","HEB","JAS","1PE","2PE","1JN","2JN","3JN","JUD","REV","TOB","JDT","ESG","WIS","SIR","BAR","LJE","S3Y","SUS","BEL","1MA","2MA","3MA","4MA","1ES","2ES","MAN","PS2","ODA","PSS","JSA","JDB","TBS","SST","DNT","BLT","XXA","XXB","XXC","XXD","XXE","XXF","XXG","FRT","BAK","OTH","3ES","EZA","5EZ","6EZ","INT","CNC","GLO","TDX","NDX","DAG","PS3","2BA","LBA","JUB","ENO","1MQ","2MQ","3MQ","REP","4BA","LAO"],ao=["XXA","XXB","XXC","XXD","XXE","XXF","XXG","FRT","BAK","OTH","INT","CNC","GLO","TDX","NDX"],rs=["Genesis","Exodus","Leviticus","Numbers","Deuteronomy","Joshua","Judges","Ruth","1 Samuel","2 Samuel","1 Kings","2 Kings","1 Chronicles","2 Chronicles","Ezra","Nehemiah","Esther (Hebrew)","Job","Psalms","Proverbs","Ecclesiastes","Song of Songs","Isaiah","Jeremiah","Lamentations","Ezekiel","Daniel (Hebrew)","Hosea","Joel","Amos","Obadiah","Jonah","Micah","Nahum","Habakkuk","Zephaniah","Haggai","Zechariah","Malachi","Matthew","Mark","Luke","John","Acts","Romans","1 Corinthians","2 Corinthians","Galatians","Ephesians","Philippians","Colossians","1 Thessalonians","2 Thessalonians","1 Timothy","2 Timothy","Titus","Philemon","Hebrews","James","1 Peter","2 Peter","1 John","2 John","3 John","Jude","Revelation","Tobit","Judith","Esther Greek","Wisdom of Solomon","Sirach (Ecclesiasticus)","Baruch","Letter of Jeremiah","Song of 3 Young Men","Susanna","Bel and the Dragon","1 Maccabees","2 Maccabees","3 Maccabees","4 Maccabees","1 Esdras (Greek)","2 Esdras (Latin)","Prayer of Manasseh","Psalm 151","Odes","Psalms of Solomon","Joshua A. *obsolete*","Judges B. *obsolete*","Tobit S. *obsolete*","Susanna Th. *obsolete*","Daniel Th. *obsolete*","Bel Th. *obsolete*","Extra A","Extra B","Extra C","Extra D","Extra E","Extra F","Extra G","Front Matter","Back Matter","Other Matter","3 Ezra *obsolete*","Apocalypse of Ezra","5 Ezra (Latin Prologue)","6 Ezra (Latin Epilogue)","Introduction","Concordance ","Glossary ","Topical Index","Names Index","Daniel Greek","Psalms 152-155","2 Baruch (Apocalypse)","Letter of Baruch","Jubilees","Enoch","1 Meqabyan","2 Meqabyan","3 Meqabyan","Reproof (Proverbs 25-31)","4 Baruch (Rest of Baruch)","Laodiceans"],ra=Ul();function Yt(e,t=!0){return t&&(e=e.toUpperCase()),e in ra?ra[e]:0}function so(e){return Yt(e)>0}function $l(e){const t=typeof e=="string"?Yt(e):e;return t>=40&&t<=66}function Dl(e){return(typeof e=="string"?Yt(e):e)<=39}function os(e){return e<=66}function Al(e){const t=typeof e=="string"?Yt(e):e;return is(t)&&!os(t)}function*Bl(){for(let e=1;e<=gt.length;e++)yield e}const Vl=1,as=gt.length;function zl(){return["XXA","XXB","XXC","XXD","XXE","XXF","XXG"]}function io(e,t="***"){const n=e-1;return n<0||n>=gt.length?t:gt[n]}function ss(e){return e<=0||e>as?"******":rs[e-1]}function Ll(e){return ss(Yt(e))}function is(e){const t=typeof e=="number"?io(e):e;return so(t)&&!ao.includes(t)}function Fl(e){const t=typeof e=="number"?io(e):e;return so(t)&&ao.includes(t)}function Gl(e){return rs[e-1].includes("*obsolete*")}function Ul(){const e={};for(let t=0;t(e[e.Unknown=0]="Unknown",e[e.Original=1]="Original",e[e.Septuagint=2]="Septuagint",e[e.Vulgate=3]="Vulgate",e[e.English=4]="English",e[e.RussianProtestant=5]="RussianProtestant",e[e.RussianOrthodox=6]="RussianOrthodox",e))(He||{});const Pe=class{constructor(t){if(ne(this,"name"),ne(this,"fullPath"),ne(this,"isPresent"),ne(this,"hasVerseSegments"),ne(this,"isCustomized"),ne(this,"baseVersification"),ne(this,"scriptureBooks"),ne(this,"_type"),t==null)throw new Error("Argument undefined");typeof t=="string"?(this.name=t,this._type=He[t]):(this._type=t,this.name=He[t])}get type(){return this._type}equals(t){return!t.type||!this.type?!1:t.type===this.type}};ne(Pe,"Original",new Pe(He.Original)),ne(Pe,"Septuagint",new Pe(He.Septuagint)),ne(Pe,"Vulgate",new Pe(He.Vulgate)),ne(Pe,"English",new Pe(He.English)),ne(Pe,"RussianProtestant",new Pe(He.RussianProtestant)),ne(Pe,"RussianOrthodox",new Pe(He.RussianOrthodox));let ut=Pe;function oa(e,t){const n=t[0];for(let r=1;r(e[e.Valid=0]="Valid",e[e.UnknownVersification=1]="UnknownVersification",e[e.OutOfRange=2]="OutOfRange",e[e.VerseOutOfOrder=3]="VerseOutOfOrder",e[e.VerseRepeated=4]="VerseRepeated",e))(ls||{});const je=class re{constructor(t,n,r,o){if(ne(this,"firstChapter"),ne(this,"lastChapter"),ne(this,"lastVerse"),ne(this,"hasSegmentsDefined"),ne(this,"text"),ne(this,"BBBCCCVVVS"),ne(this,"longHashCode"),ne(this,"versification"),ne(this,"rtlMark","‏"),ne(this,"_bookNum",0),ne(this,"_chapterNum",0),ne(this,"_verseNum",0),ne(this,"_verse"),r==null&&o==null)if(t!=null&&typeof t=="string"){const s=t,i=n!=null&&n instanceof ut?n:void 0;this.setEmpty(i),this.parse(s)}else if(t!=null&&typeof t=="number"){const s=n!=null&&n instanceof ut?n:void 0;this.setEmpty(s),this._verseNum=t%re.chapterDigitShifter,this._chapterNum=Math.floor(t%re.bookDigitShifter/re.chapterDigitShifter),this._bookNum=Math.floor(t/re.bookDigitShifter)}else if(n==null)if(t!=null&&t instanceof re){const s=t;this._bookNum=s.bookNum,this._chapterNum=s.chapterNum,this._verseNum=s.verseNum,this._verse=s.verse,this.versification=s.versification}else{if(t==null)return;const s=t instanceof ut?t:re.defaultVersification;this.setEmpty(s)}else throw new Error("VerseRef constructor not supported.");else if(t!=null&&n!=null&&r!=null)if(typeof t=="string"&&typeof n=="string"&&typeof r=="string")this.setEmpty(o),this.updateInternal(t,n,r);else if(typeof t=="number"&&typeof n=="number"&&typeof r=="number")this._bookNum=t,this._chapterNum=n,this._verseNum=r,this.versification=o??re.defaultVersification;else throw new Error("VerseRef constructor not supported.");else throw new Error("VerseRef constructor not supported.")}static isVerseParseable(t){return t.length>0&&"0123456789".includes(t[0])&&!t.endsWith(this.verseRangeSeparator)&&!t.endsWith(this.verseSequenceIndicator)}static tryParse(t){let n;try{return n=new re(t),{success:!0,verseRef:n}}catch(r){if(r instanceof nn)return n=new re,{success:!1,verseRef:n};throw r}}static getBBBCCCVVV(t,n,r){return t%re.bcvMaxValue*re.bookDigitShifter+(n>=0?n%re.bcvMaxValue*re.chapterDigitShifter:0)+(r>=0?r%re.bcvMaxValue:0)}static fromJSON(t){const{book:n,chapterNum:r,verseNum:o,verse:s,versificationStr:i}=t,l=s||o.toString();let c;return i&&(c=new ut(i)),n?new re(n,r.toString(),l,c):new re}static tryGetVerseNum(t){let n;if(!t)return n=-1,{success:!0,vNum:n};n=0;let r;for(let o=0;o"9")return o===0&&(n=-1),{success:!1,vNum:n};if(n=n*10+ +r-0,n>re.bcvMaxValue)return n=-1,{success:!1,vNum:n}}return{success:!0,vNum:n}}get isDefault(){return this.bookNum===0&&this.chapterNum===0&&this.verseNum===0&&this.versification==null}get hasMultiple(){return this._verse!=null&&(this._verse.includes(re.verseRangeSeparator)||this._verse.includes(re.verseSequenceIndicator))}get book(){return ae.bookNumberToId(this.bookNum,"")}set book(t){this.bookNum=ae.bookIdToNumber(t)}get chapter(){return this.isDefault||this._chapterNum<0?"":this._chapterNum.toString()}set chapter(t){const n=+t;this._chapterNum=Number.isInteger(n)?n:-1}get verse(){return this._verse!=null?this._verse:this.isDefault||this._verseNum<0?"":this._verseNum.toString()}set verse(t){const{success:n,vNum:r}=re.tryGetVerseNum(t);this._verse=n?void 0:t.replace(this.rtlMark,""),this._verseNum=r,!(this._verseNum>=0)&&({vNum:this._verseNum}=re.tryGetVerseNum(this._verse))}get bookNum(){return this._bookNum}set bookNum(t){if(t<=0||t>ae.lastBook)throw new nn("BookNum must be greater than zero and less than or equal to last book");this._bookNum=t}get chapterNum(){return this._chapterNum}set chapterNum(t){this.chapterNum=t}get verseNum(){return this._verseNum}set verseNum(t){this._verseNum=t}get versificationStr(){var t;return(t=this.versification)==null?void 0:t.name}set versificationStr(t){this.versification=this.versification!=null?new ut(t):void 0}get valid(){return this.validStatus===0}get validStatus(){return this.validateVerse(re.verseRangeSeparators,re.verseSequenceIndicators)}get BBBCCC(){return re.getBBBCCCVVV(this._bookNum,this._chapterNum,0)}get BBBCCCVVV(){return re.getBBBCCCVVV(this._bookNum,this._chapterNum,this._verseNum)}get isExcluded(){return!1}parse(t){if(t=t.replace(this.rtlMark,""),t.includes("/")){const s=t.split("/");if(t=s[0],s.length>1)try{const i=+s[1].trim();this.versification=new ut(He[i])}catch{throw new nn("Invalid reference : "+t)}}const n=t.trim().split(" ");if(n.length!==2)throw new nn("Invalid reference : "+t);const r=n[1].split(":"),o=+r[0];if(r.length!==2||ae.bookIdToNumber(n[0])===0||!Number.isInteger(o)||o<0||!re.isVerseParseable(r[1]))throw new nn("Invalid reference : "+t);this.updateInternal(n[0],r[0],r[1])}simplify(){this._verse=void 0}clone(){return new re(this)}toString(){const t=this.book;return t===""?"":`${t} ${this.chapter}:${this.verse}`}toJSON(){let t=this.verse;(t===""||t===this.verseNum.toString())&&(t=void 0);const n={book:this.book,chapterNum:this.chapterNum,verseNum:this.verseNum,verse:t,versificationStr:this.versificationStr};return t||delete n.verse,n}equals(t){return t instanceof re?t._bookNum===this._bookNum&&t._chapterNum===this._chapterNum&&t._verseNum===this._verseNum&&t.verse===this.verse&&(t.versification==null&&this.versification==null||t.versification!=null&&this.versification!=null&&t.versification.equals(this.versification)):!1}allVerses(t=!1,n=re.verseRangeSeparators,r=re.verseSequenceIndicators){if(this._verse==null||this.chapterNum<=0)return[this.clone()];const o=[],s=oa(this._verse,r);for(const i of s.map(l=>oa(l,n))){const l=this.clone();l.verse=i[0];const c=l.verseNum;if(o.push(l),i.length>1){const d=this.clone();if(d.verse=i[1],!t)for(let u=c+1;ui)return 3;if(r===i)return 4;r=i}return 0}get internalValid(){return this.versification==null?1:this._bookNum<=0||this._bookNum>ae.lastBook?2:(ae.isCanonical(this._bookNum),0)}setEmpty(t=re.defaultVersification){this._bookNum=0,this._chapterNum=-1,this._verse=void 0,this.versification=t}updateInternal(t,n,r){this.bookNum=ae.bookIdToNumber(t),this.chapter=n,this.verse=r}};ne(je,"defaultVersification",ut.English),ne(je,"verseRangeSeparator","-"),ne(je,"verseSequenceIndicator",","),ne(je,"verseRangeSeparators",[je.verseRangeSeparator]),ne(je,"verseSequenceIndicators",[je.verseSequenceIndicator]),ne(je,"chapterDigitShifter",1e3),ne(je,"bookDigitShifter",je.chapterDigitShifter*je.chapterDigitShifter),ne(je,"bcvMaxValue",je.chapterDigitShifter-1),ne(je,"ValidStatusType",ls);class nn extends Error{}const or=pe.Root,lo=pe.Trigger,cs=pe.Group,ql=pe.Portal,Hl=pe.Sub,Xl=pe.RadioGroup,ds=g.forwardRef(({className:e,inset:t,children:n,...r},o)=>a.jsxs(pe.SubTrigger,{ref:o,className:N("tw-flex tw-cursor-default tw-select-none tw-items-center tw-rounded-sm tw-px-2 tw-py-1.5 tw-text-sm tw-outline-none focus:tw-bg-accent data-[state=open]:tw-bg-accent",t&&"tw-pl-8",e),...r,children:[n,a.jsx(Q.ChevronRight,{className:"tw-ml-auto tw-h-4 tw-w-4"})]}));ds.displayName=pe.SubTrigger.displayName;const us=g.forwardRef(({className:e,...t},n)=>a.jsx(pe.SubContent,{ref:n,className:N("tw-z-50 tw-min-w-[8rem] tw-overflow-hidden tw-rounded-md tw-border tw-bg-popover tw-p-1 tw-text-popover-foreground tw-shadow-lg data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0 data-[state=closed]:tw-zoom-out-95 data-[state=open]:tw-zoom-in-95 data-[side=bottom]:tw-slide-in-from-top-2 data-[side=left]:tw-slide-in-from-right-2 data-[side=right]:tw-slide-in-from-left-2 data-[side=top]:tw-slide-in-from-bottom-2",e),...t}));us.displayName=pe.SubContent.displayName;const En=g.forwardRef(({className:e,sideOffset:t=4,...n},r)=>a.jsx(pe.Portal,{children:a.jsx(pe.Content,{ref:r,sideOffset:t,className:N("pr-twp tw-z-50 tw-min-w-[8rem] tw-overflow-hidden tw-rounded-md tw-border tw-bg-popover tw-p-1 tw-text-popover-foreground tw-shadow-md data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0 data-[state=closed]:tw-zoom-out-95 data-[state=open]:tw-zoom-in-95 data-[side=bottom]:tw-slide-in-from-top-2 data-[side=left]:tw-slide-in-from-right-2 data-[side=right]:tw-slide-in-from-left-2 data-[side=top]:tw-slide-in-from-bottom-2",e),...n})}));En.displayName=pe.Content.displayName;const co=g.forwardRef(({className:e,inset:t,...n},r)=>a.jsx(pe.Item,{ref:r,className:N("tw-cursor-default tw-select-none tw-items-center tw-rounded-sm tw-px-2 tw-py-1.5 tw-text-sm tw-outline-none tw-transition-colors focus:tw-bg-accent data-[disabled]:tw-pointer-events-none data-[disabled]:tw-opacity-50",t&&"tw-pl-8",e),...n}));co.displayName=pe.Item.displayName;const ar=g.forwardRef(({className:e,children:t,checked:n,...r},o)=>a.jsxs(pe.CheckboxItem,{ref:o,className:N("tw-relative tw-flex tw-cursor-default tw-select-none tw-items-center tw-rounded-sm tw-py-1.5 tw-pl-8 tw-pr-2 tw-text-sm tw-outline-none tw-transition-colors focus:tw-bg-accent focus:tw-text-accent-foreground data-[disabled]:tw-pointer-events-none data-[disabled]:tw-opacity-50",e),checked:n,...r,children:[a.jsx("span",{className:"tw-absolute tw-left-2 tw-flex tw-h-3.5 tw-w-3.5 tw-items-center tw-justify-center",children:a.jsx(pe.ItemIndicator,{children:a.jsx(Q.Check,{className:"tw-h-4 tw-w-4"})})}),t]}));ar.displayName=pe.CheckboxItem.displayName;const uo=g.forwardRef(({className:e,children:t,...n},r)=>a.jsxs(pe.RadioItem,{ref:r,className:N("tw-relative tw-flex tw-cursor-default tw-select-none tw-items-center tw-rounded-sm tw-py-1.5 tw-pl-8 tw-pr-2 tw-text-sm tw-outline-none tw-transition-colors focus:tw-bg-accent focus:tw-text-accent-foreground data-[disabled]:tw-pointer-events-none data-[disabled]:tw-opacity-50",e),...n,children:[a.jsx("span",{className:"tw-absolute tw-left-2 tw-flex tw-h-3.5 tw-w-3.5 tw-items-center tw-justify-center",children:a.jsx(pe.ItemIndicator,{children:a.jsx(Q.Circle,{className:"tw-h-2 tw-w-2 tw-fill-current"})})}),t]}));uo.displayName=pe.RadioItem.displayName;const Wt=g.forwardRef(({className:e,inset:t,...n},r)=>a.jsx(pe.Label,{ref:r,className:N("tw-px-2 tw-py-1.5 tw-text-sm tw-font-semibold",t&&"tw-pl-8",e),...n}));Wt.displayName=pe.Label.displayName;const jn=g.forwardRef(({className:e,...t},n)=>a.jsx(pe.Separator,{ref:n,className:N("tw--mx-1 tw-my-1 tw-h-px tw-bg-muted",e),...t}));jn.displayName=pe.Separator.displayName;function ps({className:e,...t}){return a.jsx("span",{className:N("tw-ml-auto tw-text-xs tw-tracking-widest tw-opacity-60",e),...t})}ps.displayName="DropdownMenuShortcut";const Yl=g.forwardRef(({bookId:e,handleSelectBook:t,isSelected:n,handleHighlightBook:r,handleKeyDown:o,bookType:s,children:i},l)=>a.jsxs(co,{ref:l,textValue:e,className:N("tw-mx-1 tw-px-1 tw-font-normal tw-text-foreground/80",{"tw-bg-amber-50 tw-text-yellow-900 data-[highlighted]:tw-bg-amber-100":n}),onSelect:c=>{c.preventDefault(),t()},onKeyDown:c=>{o(c)},onFocus:r,onMouseMove:r,children:[a.jsx("span",{className:N("tw-border-b-0 tw-border-l-2 tw-border-r-0 tw-border-t-0 tw-border-solid tw-px-2",{"tw-font-bold":n,"tw-border-l-red-200":s.toLowerCase()==="ot","tw-border-l-purple-200":s.toLowerCase()==="nt","tw-border-l-indigo-200":s.toLowerCase()==="dc"}),children:ae.bookIdToEnglishName(e)}),n&&a.jsx("div",{children:i})]},e));function Wl({handleSelectChapter:e,endChapter:t,activeChapter:n,highlightedChapter:r,handleHighlightedChapter:o}){const s=Array.from({length:t},(l,c)=>c+1),i=g.useCallback(l=>{o(l)},[o]);return a.jsx("div",{className:N("tw-flex tw-flex-wrap tw-items-start tw-justify-start tw-self-stretch"),children:s.map(l=>a.jsx("div",{className:N("tw-box-content tw-flex tw-h-4 tw-w-4 tw-cursor-pointer tw-items-center tw-justify-end tw-rounded-md tw-p-2 tw-text-amber-800",{"tw-font-semibold tw-text-amber-900":l===n,"tw-bg-amber-200":l===r}),onClick:c=>{c.preventDefault(),c.stopPropagation(),e(l)},role:"button",onKeyDown:c=>{c.key==="Enter"&&e(l)},tabIndex:0,onMouseMove:()=>i(l),children:l},l))})}function Kl({handleSort:e,handleLocationHistory:t,handleBookmarks:n}){return a.jsxs(Wt,{className:"tw-flex tw-justify-between",children:[a.jsx("p",{className:"tw-inline-block tw-align-middle",children:"Go To"}),a.jsxs("div",{className:"tw-flex tw-items-center",children:[a.jsx(Q.ArrowDownWideNarrow,{onClick:e,className:"tw-m-2 tw-h-4 tw-w-4 tw-cursor-pointer tw-gap-2"}),a.jsx(Q.Clock,{onClick:t,className:"tw-m-2 tw-h-4 tw-w-4 tw-cursor-pointer tw-gap-2"}),a.jsx(Q.Bookmark,{onClick:n,className:"tw-m-2 tw-h-4 tw-w-4 tw-cursor-pointer tw-gap-2"})]})]})}const wn=ae.allBookIds,Jl={OT:"Old Testament",NT:"New Testament",DC:"Deuterocanon"},aa=["OT","NT","DC"],Zl=32+32+32,Ql=[/^(\w+)$/i,/^(\w+)(?:\s(\d+))$/i,/^(\w+)(?:\s(\d+):(\d+))$/i],ec=e=>({OT:wn.filter(n=>ae.isBookOT(n)),NT:wn.filter(n=>ae.isBookNT(n)),DC:wn.filter(n=>ae.isBookDC(n))})[e],rn=e=>W.getChaptersForBook(ae.bookIdToNumber(e));function tc(){return wn.map(t=>ae.bookIdToEnglishName(t))}function nc(e){return tc().includes(e)}function rc(e){const t=e.toLowerCase().replace(/^\w/,n=>n.toUpperCase());if(nc(t))return wn.find(r=>ae.bookIdToEnglishName(r)===t)}function oc({scrRef:e,handleSubmit:t}){const[n,r]=g.useState(""),[o,s]=g.useState(ae.bookNumberToId(e.bookNum)),[i,l]=g.useState(e.chapterNum??0),[c,d]=g.useState(ae.bookNumberToId(e.bookNum)),[u,h]=g.useState(!1),[w,b]=g.useState(u),x=g.useRef(void 0),f=g.useRef(void 0),m=g.useRef(void 0),S=g.useCallback(k=>ec(k).filter(D=>{const $=ae.bookIdToEnglishName(D).toLowerCase(),J=n.replace(/[^a-zA-Z]/g,"").toLowerCase();return $.includes(J)||D.toLowerCase().includes(J)}),[n]),R=k=>{r(k)},j=g.useRef(!1),E=g.useCallback(k=>{if(j.current){j.current=!1;return}h(k)},[]),v=g.useCallback((k,D,$,J)=>{if(l(ae.bookNumberToId(e.bookNum)!==k?1:e.chapterNum),D||rn(k)===-1){t({bookNum:ae.bookIdToNumber(k),chapterNum:$||1,verseNum:J||1}),h(!1),r("");return}s(o!==k?k:""),h(!D)},[t,e.bookNum,e.chapterNum,o]),P=k=>{k<=0||k>rn(o)||v(o,!0,k)},V=g.useCallback(()=>{Ql.forEach(k=>{const D=n.match(k);if(D){const[$,J=void 0,Y=void 0]=D.slice(1),F=rc($);(ae.isBookIdValid($)||F)&&v(F??$,!0,J?parseInt(J,10):1,Y?parseInt(Y,10):1)}})},[v,n]),U=g.useCallback(k=>{u?(k.key==="ArrowDown"||k.key==="ArrowUp")&&(typeof m<"u"&&m.current!==null?m.current.focus():typeof f<"u"&&f.current!==null&&f.current.focus(),k.preventDefault()):h(!0)},[u]),C=k=>{const{key:D}=k;D==="ArrowRight"||D==="ArrowLeft"||D==="ArrowDown"||D==="ArrowUp"||D==="Enter"||(x.current.dispatchEvent(new KeyboardEvent("keydown",{key:D})),x.current.focus())},_=k=>{const{key:D}=k;if(c===o){if(D==="Enter"){k.preventDefault(),v(o,!0,i);return}let $=0;if(D==="ArrowRight")if(i1)$=-1;else{k.preventDefault();return}else D==="ArrowDown"?$=6:D==="ArrowUp"&&($=-6);i+$<=0||i+$>rn(c)?l(0):$!==0&&(l(i+$),k.preventDefault())}};return g.useEffect(()=>{o===c?o===ae.bookNumberToId(e.bookNum)?l(e.chapterNum):l(1):l(0)},[c,e.bookNum,e.chapterNum,o]),g.useLayoutEffect(()=>{b(u)},[u]),g.useLayoutEffect(()=>{const k=setTimeout(()=>{if(w&&f.current&&m.current){const $=m.current.offsetTop-Zl;f.current.scrollTo({top:$,behavior:"instant"})}},10);return()=>{clearTimeout(k)}},[w]),a.jsx("div",{className:"pr-twp tw-flex",children:a.jsxs(or,{modal:!1,open:u,onOpenChange:E,children:[a.jsx(lo,{asChild:!0,children:a.jsx(Pl,{ref:x,value:n,handleSearch:R,handleKeyDown:U,handleOnClick:()=>{s(ae.bookNumberToId(e.bookNum)),d(ae.bookNumberToId(e.bookNum)),l(e.chapterNum>0?e.chapterNum:0),h(!0),x.current.focus()},onFocus:()=>{j.current=!0},handleSubmit:V,placeholder:`${ae.bookNumberToEnglishName(e.bookNum)} ${e.chapterNum}:${e.verseNum}`})}),a.jsxs(En,{className:"tw-m-1 tw-overflow-y-auto tw-p-0 tw-font-normal tw-text-foreground/80",style:{width:"233px",maxHeight:"500px",zIndex:"250"},onKeyDown:C,align:"start",ref:f,children:[a.jsx(Kl,{handleSort:()=>console.log("sorting"),handleLocationHistory:()=>console.log("location history"),handleBookmarks:()=>console.log("bookmarks")}),aa.map((k,D)=>S(k).length>0&&a.jsxs("div",{children:[a.jsx(Wt,{className:"tw-font-semibold tw-text-foreground/80",children:Jl[k]}),S(k).map($=>a.jsx("div",{children:a.jsx(Yl,{bookId:$,handleSelectBook:()=>v($,!1),isSelected:o===$,handleHighlightBook:()=>d($),handleKeyDown:_,bookType:k,ref:J=>{o===$&&(m.current=J)},children:a.jsx(Wl,{handleSelectChapter:P,endChapter:rn($),activeChapter:e.bookNum===ae.bookIdToNumber($)?e.chapterNum:0,highlightedChapter:i,handleHighlightedChapter:J=>{l(J)}})})},$)),aa.length-1!==D?a.jsx(jn,{}):void 0]},k))]})]})})}const ws=Xt.cva("pr-twp tw-inline-flex tw-items-center tw-justify-center tw-whitespace-nowrap tw-rounded-md tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-colors focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50",{variants:{variant:{default:"tw-bg-primary tw-text-primary-foreground hover:tw-bg-primary/90",destructive:"tw-bg-destructive tw-text-destructive-foreground hover:tw-bg-destructive/90",outline:"tw-border tw-border-input tw-bg-background hover:tw-bg-accent hover:tw-text-accent-foreground",secondary:"tw-bg-secondary tw-text-secondary-foreground hover:tw-bg-secondary/80",ghost:"hover:tw-bg-accent hover:tw-text-accent-foreground",link:"tw-text-primary tw-underline-offset-4 hover:tw-underline"},size:{default:"tw-h-10 tw-px-4 tw-py-2",sm:"tw-h-9 tw-rounded-md tw-px-3",lg:"tw-h-11 tw-rounded-md tw-px-8",icon:"tw-h-10 tw-w-10"}},defaultVariants:{variant:"default",size:"default"}}),fe=g.forwardRef(({className:e,variant:t,size:n,asChild:r=!1,...o},s)=>{const i=r?Ht.Slot:"button";return a.jsx(i,{className:N(ws({variant:t,size:n,className:e})),ref:s,...o})});fe.displayName="Button";const ac=Xt.cva("tw-text-sm tw-font-medium tw-leading-none peer-disabled:tw-cursor-not-allowed peer-disabled:tw-opacity-70"),qe=g.forwardRef(({className:e,...t},n)=>a.jsx(es.Root,{ref:n,className:N("pr-twp",ac(),e),...t}));qe.displayName=es.Root.displayName;const po=g.forwardRef(({className:e,...t},n)=>a.jsx(bn.Root,{className:N("pr-twp tw-grid tw-gap-2",e),...t,ref:n}));po.displayName=bn.Root.displayName;const Yn=g.forwardRef(({className:e,...t},n)=>a.jsx(bn.Item,{ref:n,className:N("pr-twp tw-aspect-square tw-h-4 tw-w-4 tw-rounded-full tw-border tw-border-primary tw-text-primary tw-ring-offset-background focus:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-cursor-not-allowed disabled:tw-opacity-50",e),...t,children:a.jsx(bn.Indicator,{className:"tw-flex tw-items-center tw-justify-center",children:a.jsx(Q.Circle,{className:"tw-h-2.5 tw-w-2.5 tw-fill-current tw-text-current"})})}));Yn.displayName=bn.Item.displayName;const sc=vn.Root,ic=vn.Trigger,fs=g.forwardRef(({className:e,align:t="center",sideOffset:n=4,...r},o)=>a.jsx(vn.Portal,{children:a.jsx(vn.Content,{ref:o,align:t,sideOffset:n,className:N("pr-twp tw-z-50 tw-w-72 tw-rounded-md tw-border tw-bg-popover tw-p-4 tw-text-popover-foreground tw-shadow-md tw-outline-none data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0 data-[state=closed]:tw-zoom-out-95 data-[state=open]:tw-zoom-in-95 data-[side=bottom]:tw-slide-in-from-top-2 data-[side=left]:tw-slide-in-from-right-2 data-[side=right]:tw-slide-in-from-left-2 data-[side=top]:tw-slide-in-from-bottom-2",e),...r})}));fs.displayName=vn.Content.displayName;const lc=be.Portal,ms=g.forwardRef(({className:e,...t},n)=>a.jsx(be.Overlay,{ref:n,className:N("tw-fixed tw-inset-0 tw-z-50 tw-bg-black/80 data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0",e),...t}));ms.displayName=be.Overlay.displayName;const cc=g.forwardRef(({className:e,children:t,...n},r)=>a.jsxs(lc,{children:[a.jsx(ms,{}),a.jsxs(be.Content,{ref:r,className:N("tw-fixed tw-left-[50%] tw-top-[50%] tw-z-50 tw-grid tw-w-full tw-max-w-lg tw-translate-x-[-50%] tw-translate-y-[-50%] tw-gap-4 tw-border tw-bg-background tw-p-6 tw-shadow-lg tw-duration-200 data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0 data-[state=closed]:tw-zoom-out-95 data-[state=open]:tw-zoom-in-95 data-[state=closed]:tw-slide-out-to-left-1/2 data-[state=closed]:tw-slide-out-to-top-[48%] data-[state=open]:tw-slide-in-from-left-1/2 data-[state=open]:tw-slide-in-from-top-[48%] sm:tw-rounded-lg",e),...n,children:[t,a.jsxs(be.Close,{className:"tw-absolute tw-right-4 tw-top-4 tw-rounded-sm tw-opacity-70 tw-ring-offset-background tw-transition-opacity hover:tw-opacity-100 focus:tw-outline-none focus:tw-ring-2 focus:tw-ring-ring focus:tw-ring-offset-2 disabled:tw-pointer-events-none data-[state=open]:tw-bg-accent data-[state=open]:tw-text-muted-foreground",children:[a.jsx(Q.X,{className:"tw-h-4 tw-w-4"}),a.jsx("span",{className:"tw-sr-only",children:"Close"})]})]})]}));cc.displayName=be.Content.displayName;const dc=g.forwardRef(({className:e,...t},n)=>a.jsx(be.Title,{ref:n,className:N("tw-text-lg tw-font-semibold tw-leading-none tw-tracking-tight",e),...t}));dc.displayName=be.Title.displayName;const uc=g.forwardRef(({className:e,...t},n)=>a.jsx(be.Description,{ref:n,className:N("tw-text-sm tw-text-muted-foreground",e),...t}));uc.displayName=be.Description.displayName;const hs=g.forwardRef(({className:e,...t},n)=>a.jsx(Re.Command,{ref:n,className:N("tw-flex tw-h-full tw-w-full tw-flex-col tw-overflow-hidden tw-rounded-md tw-bg-popover tw-text-popover-foreground",e),...t}));hs.displayName=Re.Command.displayName;const gs=g.forwardRef(({className:e,...t},n)=>a.jsxs("div",{className:"tw-flex tw-items-center tw-border-b tw-px-3",children:[a.jsx(Q.Search,{className:"tw-me-2 tw-h-4 tw-w-4 tw-shrink-0 tw-opacity-50"}),a.jsx(Re.Command.Input,{ref:n,className:N("tw-flex tw-h-11 tw-w-full tw-rounded-md tw-bg-transparent tw-py-3 tw-text-sm tw-outline-none placeholder:tw-text-muted-foreground disabled:tw-cursor-not-allowed disabled:tw-opacity-50",e),...t})]}));gs.displayName=Re.Command.Input.displayName;const bs=g.forwardRef(({className:e,...t},n)=>a.jsx(Re.Command.List,{ref:n,className:N("tw-max-h-[300px] tw-overflow-y-auto tw-overflow-x-hidden",e),...t}));bs.displayName=Re.Command.List.displayName;const vs=g.forwardRef((e,t)=>a.jsx(Re.Command.Empty,{ref:t,className:"tw-py-6 tw-text-center tw-text-sm",...e}));vs.displayName=Re.Command.Empty.displayName;const pc=g.forwardRef(({className:e,...t},n)=>a.jsx(Re.Command.Group,{ref:n,className:N("tw-overflow-hidden tw-p-1 tw-text-foreground [&_[cmdk-group-heading]]:tw-px-2 [&_[cmdk-group-heading]]:tw-py-1.5 [&_[cmdk-group-heading]]:tw-text-xs [&_[cmdk-group-heading]]:tw-font-medium [&_[cmdk-group-heading]]:tw-text-muted-foreground",e),...t}));pc.displayName=Re.Command.Group.displayName;const wc=g.forwardRef(({className:e,...t},n)=>a.jsx(Re.Command.Separator,{ref:n,className:N("tw--mx-1 tw-h-px tw-bg-border",e),...t}));wc.displayName=Re.Command.Separator.displayName;const xs=g.forwardRef(({className:e,...t},n)=>a.jsx(Re.Command.Item,{ref:n,className:N("tw-relative tw-flex tw-cursor-default tw-select-none tw-items-center tw-rounded-sm tw-px-2 tw-py-1.5 tw-text-sm tw-outline-none data-[disabled=true]:tw-pointer-events-none data-[selected=true]:tw-bg-accent data-[selected=true]:tw-text-accent-foreground data-[disabled=true]:tw-opacity-50",e),...t}));xs.displayName=Re.Command.Item.displayName;function fc(e){return typeof e=="string"?e:typeof e=="number"?e.toString():e.label}function Wn({id:e,options:t=[],buttonClassName:n,popoverContentClassName:r,value:o,onChange:s=()=>{},getOptionLabel:i=fc,buttonPlaceholder:l="",textPlaceholder:c="",commandEmptyMessage:d="No option found",buttonVariant:u="outline",dir:h="ltr",isDisabled:w=!1,...b}){const[x,f]=g.useState(!1);return a.jsxs(sc,{open:x,onOpenChange:f,...b,children:[a.jsx(ic,{asChild:!0,children:a.jsxs(fe,{variant:u,role:"combobox","aria-expanded":x,id:e,className:N("tw-w-[200px] tw-justify-between",n),disabled:w,children:[a.jsx("span",{className:"tw-overflow-hidden tw-text-ellipsis tw-whitespace-nowrap",children:o?i(o):l}),a.jsx(Q.ChevronsUpDown,{className:"tw-ms-2 tw-h-4 tw-w-4 tw-shrink-0 tw-opacity-50"})]})}),a.jsx(fs,{className:N("tw-w-[200px] tw-p-0",r),dir:h,children:a.jsxs(hs,{children:[a.jsx(gs,{dir:h,placeholder:c,className:"tw-text-inherit"}),a.jsx(vs,{children:d}),a.jsx(bs,{children:t.map(m=>a.jsxs(xs,{value:i(m),onSelect:()=>{s(m),f(!1)},children:[a.jsx(Q.Check,{className:N("tw-me-2 tw-h-4 tw-w-4",{"tw-opacity-0":!o||i(o)!==i(m)})}),i(m)]},i(m)))})]})})]})}function ys({startChapter:e,endChapter:t,handleSelectStartChapter:n,handleSelectEndChapter:r,isDisabled:o=!1,chapterCount:s}){const i=g.useMemo(()=>Array.from({length:s},(d,u)=>u+1),[s]),l=d=>{n(d),d>t&&r(d)},c=d=>{r(d),dd.toString(),value:e},"start chapter"),a.jsx(qe,{htmlFor:"end-chapters-combobox",children:"to"}),a.jsx(Wn,{isDisabled:o,onChange:c,buttonClassName:"tw-ml-2 tw-w-20",options:i,getOptionLabel:d=>d.toString(),value:t},"end chapter")]})}var Ns=(e=>(e.CURRENT_BOOK="current book",e.CHOOSE_BOOKS="choose books",e))(Ns||{});const mc=Object.freeze(["%webView_bookSelector_currentBook%","%webView_bookSelector_choose%","%webView_bookSelector_chooseBooks%"]),Tr=(e,t)=>e[t]??t;function hc({handleBookSelectionModeChange:e,currentBookName:t,onSelectBooks:n,selectedBookIds:r,chapterCount:o,endChapter:s,handleSelectEndChapter:i,startChapter:l,handleSelectStartChapter:c,localizedStrings:d}){const u=Tr(d,"%webView_bookSelector_currentBook%"),h=Tr(d,"%webView_bookSelector_choose%"),w=Tr(d,"%webView_bookSelector_chooseBooks%"),[b,x]=g.useState("current book"),f=m=>{x(m),e(m)};return a.jsx(po,{className:"pr-twp tw-flex",value:b,onValueChange:m=>f(m),children:a.jsxs("div",{className:"tw-flex tw-w-full tw-flex-col tw-gap-4",children:[a.jsxs("div",{className:"tw-grid tw-grid-cols-[25%,25%,50%]",children:[a.jsxs("div",{className:"tw-flex tw-items-center",children:[a.jsx(Yn,{value:"current book"}),a.jsx(qe,{className:"tw-ml-1",children:u})]}),a.jsx(qe,{className:"tw-flex tw-items-center",children:t}),a.jsx("div",{className:"tw-flex tw-items-center tw-justify-end",children:a.jsx(ys,{isDisabled:b==="choose books",handleSelectStartChapter:c,handleSelectEndChapter:i,chapterCount:o,startChapter:l,endChapter:s})})]}),a.jsxs("div",{className:"tw-grid tw-grid-cols-[25%,50%,25%]",children:[a.jsxs("div",{className:"tw-flex tw-items-center",children:[a.jsx(Yn,{value:"choose books"}),a.jsx(qe,{className:"tw-ml-1",children:w})]}),a.jsx(qe,{className:"tw-flex tw-items-center",children:r.map(m=>ae.bookIdToEnglishName(m)).join(", ")}),a.jsx(fe,{disabled:b==="current book",onClick:()=>n(),children:h})]})]})})}function gc({table:e}){return a.jsxs(or,{children:[a.jsx(Za.DropdownMenuTrigger,{asChild:!0,children:a.jsxs(fe,{variant:"outline",size:"sm",className:"tw-ml-auto tw-hidden tw-h-8 lg:tw-flex",children:[a.jsx(Q.FilterIcon,{className:"tw-mr-2 tw-h-4 tw-w-4"}),"View"]})}),a.jsxs(En,{align:"end",className:"tw-w-[150px]",children:[a.jsx(Wt,{children:"Toggle columns"}),a.jsx(jn,{}),e.getAllColumns().filter(t=>t.getCanHide()).map(t=>a.jsx(ar,{className:"tw-capitalize",checked:t.getIsVisible(),onCheckedChange:n=>t.toggleVisibility(!!n),children:t.id},t.id))]})]})}const At=ge.Root,ks=ge.Group,Bt=ge.Value,bt=g.forwardRef(({className:e,children:t,...n},r)=>a.jsxs(ge.Trigger,{ref:r,className:N("tw-flex tw-h-10 tw-w-full tw-items-center tw-justify-between tw-rounded-md tw-border tw-border-input tw-bg-background tw-px-3 tw-py-2 tw-text-sm tw-ring-offset-background placeholder:tw-text-muted-foreground focus:tw-outline-none focus:tw-ring-2 focus:tw-ring-ring focus:tw-ring-offset-2 disabled:tw-cursor-not-allowed disabled:tw-opacity-50 [&>span]:tw-line-clamp-1",e),...n,children:[t,a.jsx(ge.Icon,{asChild:!0,children:a.jsx(Q.ChevronDown,{className:"tw-h-4 tw-w-4 tw-opacity-50"})})]}));bt.displayName=ge.Trigger.displayName;const wo=g.forwardRef(({className:e,...t},n)=>a.jsx(ge.ScrollUpButton,{ref:n,className:N("tw-flex tw-cursor-default tw-items-center tw-justify-center tw-py-1",e),...t,children:a.jsx(Q.ChevronUp,{className:"tw-h-4 tw-w-4"})}));wo.displayName=ge.ScrollUpButton.displayName;const fo=g.forwardRef(({className:e,...t},n)=>a.jsx(ge.ScrollDownButton,{ref:n,className:N("tw-flex tw-cursor-default tw-items-center tw-justify-center tw-py-1",e),...t,children:a.jsx(Q.ChevronDown,{className:"tw-h-4 tw-w-4"})}));fo.displayName=ge.ScrollDownButton.displayName;const vt=g.forwardRef(({className:e,children:t,position:n="popper",...r},o)=>a.jsx(ge.Portal,{children:a.jsxs(ge.Content,{ref:o,className:N("pr-twp tw-relative tw-z-50 tw-max-h-96 tw-min-w-[8rem] tw-overflow-hidden tw-rounded-md tw-border tw-bg-popover tw-text-popover-foreground tw-shadow-md data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0 data-[state=closed]:tw-zoom-out-95 data-[state=open]:tw-zoom-in-95 data-[side=bottom]:tw-slide-in-from-top-2 data-[side=left]:tw-slide-in-from-right-2 data-[side=right]:tw-slide-in-from-left-2 data-[side=top]:tw-slide-in-from-bottom-2",n==="popper"&&"data-[side=bottom]:tw-translate-y-1 data-[side=left]:tw--translate-x-1 data-[side=right]:tw-translate-x-1 data-[side=top]:tw--translate-y-1",e),position:n,...r,children:[a.jsx(wo,{}),a.jsx(ge.Viewport,{className:N("tw-p-1",n==="popper"&&"tw-h-[var(--radix-select-trigger-height)] tw-w-full tw-min-w-[var(--radix-select-trigger-width)]"),children:t}),a.jsx(fo,{})]})}));vt.displayName=ge.Content.displayName;const Ss=g.forwardRef(({className:e,...t},n)=>a.jsx(ge.Label,{ref:n,className:N("tw-py-1.5 tw-pl-8 tw-pr-2 tw-text-sm tw-font-semibold",e),...t}));Ss.displayName=ge.Label.displayName;const Ae=g.forwardRef(({className:e,children:t,...n},r)=>a.jsxs(ge.Item,{ref:r,className:N("tw-relative tw-flex tw-w-full tw-cursor-default tw-select-none tw-items-center tw-rounded-sm tw-py-1.5 tw-pl-8 tw-pr-2 tw-text-sm tw-outline-none focus:tw-bg-accent focus:tw-text-accent-foreground data-[disabled]:tw-pointer-events-none data-[disabled]:tw-opacity-50",e),...n,children:[a.jsx("span",{className:"tw-absolute tw-left-2 tw-flex tw-h-3.5 tw-w-3.5 tw-items-center tw-justify-center",children:a.jsx(ge.ItemIndicator,{children:a.jsx(Q.Check,{className:"tw-h-4 tw-w-4"})})}),a.jsx(ge.ItemText,{children:t})]}));Ae.displayName=ge.Item.displayName;const Es=g.forwardRef(({className:e,...t},n)=>a.jsx(ge.Separator,{ref:n,className:N("tw--mx-1 tw-my-1 tw-h-px tw-bg-muted",e),...t}));Es.displayName=ge.Separator.displayName;function bc({table:e}){return a.jsx("div",{className:"tw-flex tw-items-center tw-justify-between tw-px-2 tw-pb-3 tw-pt-3",children:a.jsxs("div",{className:"tw-flex tw-items-center tw-space-x-6 lg:tw-space-x-8",children:[a.jsxs("div",{className:"tw-flex-1 tw-text-sm tw-text-muted-foreground",children:[e.getFilteredSelectedRowModel().rows.length," of"," ",e.getFilteredRowModel().rows.length," row(s) selected"]}),a.jsxs("div",{className:"tw-flex tw-items-center tw-space-x-2",children:[a.jsx("p",{className:"tw-text-nowrap tw-text-sm tw-font-medium",children:"Rows per page"}),a.jsxs(At,{value:`${e.getState().pagination.pageSize}`,onValueChange:t=>{e.setPageSize(Number(t))},children:[a.jsx(bt,{className:"tw-h-8 tw-w-[70px]",children:a.jsx(Bt,{placeholder:e.getState().pagination.pageSize})}),a.jsx(vt,{side:"top",children:[10,20,30,40,50].map(t=>a.jsx(Ae,{value:`${t}`,children:t},t))})]})]}),a.jsxs("div",{className:"tw-flex tw-w-[100px] tw-items-center tw-justify-center tw-text-sm tw-font-medium",children:["Page ",e.getState().pagination.pageIndex+1," of ",e.getPageCount()]}),a.jsxs("div",{className:"tw-flex tw-items-center tw-space-x-2",children:[a.jsxs(fe,{variant:"outline",size:"icon",className:"tw-hidden tw-h-8 tw-w-8 tw-p-0 lg:tw-flex",onClick:()=>e.setPageIndex(0),disabled:!e.getCanPreviousPage(),children:[a.jsx("span",{className:"tw-sr-only",children:"Go to first page"}),a.jsx(Q.ArrowLeftIcon,{className:"tw-h-4 tw-w-4"})]}),a.jsxs(fe,{variant:"outline",size:"icon",className:"tw-h-8 tw-w-8 tw-p-0",onClick:()=>e.previousPage(),disabled:!e.getCanPreviousPage(),children:[a.jsx("span",{className:"tw-sr-only",children:"Go to previous page"}),a.jsx(Q.ChevronLeftIcon,{className:"tw-h-4 tw-w-4"})]}),a.jsxs(fe,{variant:"outline",size:"icon",className:"tw-h-8 tw-w-8 tw-p-0",onClick:()=>e.nextPage(),disabled:!e.getCanNextPage(),children:[a.jsx("span",{className:"tw-sr-only",children:"Go to next page"}),a.jsx(Q.ChevronRightIcon,{className:"tw-h-4 tw-w-4"})]}),a.jsxs(fe,{variant:"outline",size:"icon",className:"tw-hidden tw-h-8 tw-w-8 tw-p-0 lg:tw-flex",onClick:()=>e.setPageIndex(e.getPageCount()-1),disabled:!e.getCanNextPage(),children:[a.jsx("span",{className:"tw-sr-only",children:"Go to last page"}),a.jsx(Q.ArrowRightIcon,{className:"tw-h-4 tw-w-4"})]})]})]})})}const Cn=g.forwardRef(({className:e,stickyHeader:t,...n},r)=>a.jsx("div",{className:N("pr-twp tw-relative tw-w-full",{"tw-overflow-auto":!t}),children:a.jsx("table",{ref:r,className:N("tw-w-full tw-caption-bottom tw-text-sm",e),...n})}));Cn.displayName="Table";const Tn=g.forwardRef(({className:e,stickyHeader:t,...n},r)=>a.jsx("thead",{ref:r,className:N({"tw-sticky tw-top-[-1px] tw-bg-background tw-drop-shadow-sm":t},"[&_tr]:tw-border-b",e),...n}));Tn.displayName="TableHeader";const Rn=g.forwardRef(({className:e,...t},n)=>a.jsx("tbody",{ref:n,className:N("[&_tr:last-child]:tw-border-0",e),...t}));Rn.displayName="TableBody";const js=g.forwardRef(({className:e,...t},n)=>a.jsx("tfoot",{ref:n,className:N("tw-border-t tw-bg-muted/50 tw-font-medium [&>tr]:last:tw-border-b-0",e),...t}));js.displayName="TableFooter";const Ze=g.forwardRef(({className:e,...t},n)=>a.jsx("tr",{ref:n,className:N("tw-border-b tw-transition-colors hover:tw-bg-muted/50 data-[state=selected]:tw-bg-muted",e),...t}));Ze.displayName="TableRow";const Vt=g.forwardRef(({className:e,...t},n)=>a.jsx("th",{ref:n,className:N("tw-h-12 tw-px-4 tw-text-start tw-align-middle tw-font-medium tw-text-muted-foreground [&:has([role=checkbox])]:tw-pe-0",e),...t}));Vt.displayName="TableHead";const xt=g.forwardRef(({className:e,...t},n)=>a.jsx("td",{ref:n,className:N("tw-p-4 tw-align-middle [&:has([role=checkbox])]:tw-pe-0",e),...t}));xt.displayName="TableCell";const Cs=g.forwardRef(({className:e,...t},n)=>a.jsx("caption",{ref:n,className:N("tw-mt-4 tw-text-sm tw-text-muted-foreground",e),...t}));Cs.displayName="TableCaption";function Ts({columns:e,data:t,enablePagination:n=!1,showPaginationControls:r=!1,showColumnVisibilityControls:o=!1,stickyHeader:s=!1,onRowClickHandler:i=()=>{}}){var m;const[l,c]=g.useState([]),[d,u]=g.useState([]),[h,w]=g.useState({}),[b,x]=g.useState({}),f=Se.useReactTable({data:t,columns:e,getCoreRowModel:Se.getCoreRowModel(),...n&&{getPaginationRowModel:Se.getPaginationRowModel()},onSortingChange:c,getSortedRowModel:Se.getSortedRowModel(),onColumnFiltersChange:u,getFilteredRowModel:Se.getFilteredRowModel(),onColumnVisibilityChange:w,onRowSelectionChange:x,state:{sorting:l,columnFilters:d,columnVisibility:h,rowSelection:b}});return a.jsxs("div",{className:"pr-twp",children:[o&&a.jsx(gc,{table:f}),a.jsxs(Cn,{stickyHeader:s,children:[a.jsx(Tn,{stickyHeader:s,children:f.getHeaderGroups().map(S=>a.jsx(Ze,{children:S.headers.map(R=>a.jsx(Vt,{children:R.isPlaceholder?void 0:Se.flexRender(R.column.columnDef.header,R.getContext())},R.id))},S.id))}),a.jsx(Rn,{children:(m=f.getRowModel().rows)!=null&&m.length?f.getRowModel().rows.map(S=>a.jsx(Ze,{onClick:()=>i(S,f),"data-state":S.getIsSelected()&&"selected",children:S.getVisibleCells().map(R=>a.jsx(xt,{children:Se.flexRender(R.column.columnDef.cell,R.getContext())},R.id))},S.id)):a.jsx(Ze,{children:a.jsx(xt,{colSpan:e.length,className:"tw-h-24 tw-text-center",children:"No results."})})})]}),n&&a.jsxs("div",{className:"tw-flex tw-items-center tw-justify-end tw-space-x-2 tw-py-4",children:[a.jsx(fe,{variant:"outline",size:"sm",onClick:()=>f.previousPage(),disabled:!f.getCanPreviousPage(),children:"Previous"}),a.jsx(fe,{variant:"outline",size:"sm",onClick:()=>f.nextPage(),disabled:!f.getCanNextPage(),children:"Next"})]}),n&&r&&a.jsx(bc,{table:f})]})}function vc({occurrenceData:e,setScriptureReference:t,localizedStrings:n}){const r=n["%webView_inventory_occurrences_table_header_reference%"],o=n["%webView_inventory_occurrences_table_header_occurrence%"],s=g.useMemo(()=>{const i=[];return e.forEach(l=>{i.some(c=>W.deepEqual(c,l))||i.push(l)}),i},[e]);return a.jsxs(Cn,{stickyHeader:!0,children:[a.jsx(Tn,{stickyHeader:!0,children:a.jsxs(Ze,{children:[a.jsx(Vt,{children:r}),a.jsx(Vt,{children:o})]})}),a.jsx(Rn,{children:s.length>0&&s.map(i=>a.jsxs(Ze,{onClick:()=>{t(i.reference)},children:[a.jsx(xt,{children:`${ae.bookNumberToEnglishName(i.reference.bookNum)} ${i.reference.chapterNum}:${i.reference.verseNum}`}),a.jsx(xt,{children:i.text})]},`${i.reference.bookNum} ${i.reference.chapterNum}:${i.reference.verseNum}-${i.text}`))})]})}const sr=g.forwardRef(({className:e,...t},n)=>a.jsx(Ur.Root,{ref:n,className:N("tw-peer pr-twp tw-h-4 tw-w-4 tw-shrink-0 tw-rounded-sm tw-border tw-border-primary tw-ring-offset-background focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-cursor-not-allowed disabled:tw-opacity-50 data-[state=checked]:tw-bg-primary data-[state=checked]:tw-text-primary-foreground",e),...t,children:a.jsx(Ur.Indicator,{className:N("tw-flex tw-items-center tw-justify-center tw-text-current"),children:a.jsx(Q.Check,{className:"tw-h-4 tw-w-4"})})}));sr.displayName=Ur.Root.displayName;const Rs=e=>e.split(/(?:\r?\n|\r)|(?=(?:\\(?:v|c|id)))/g),Hr=e=>{const t=/^\\[vc]\s+(\d+)/,n=e.match(t);if(n)return+n[1]},Os=e=>{const t=e.match(/^\\id\s+([A-Za-z]+)/);return t?ae.bookIdToNumber(t[1]):0},_s=(e,t,n)=>n.includes(e)?"unapproved":t.includes(e)?"approved":"unknown",Ps=Xt.cva("pr-twp tw-inline-flex tw-items-center tw-justify-center tw-rounded-md tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-colors hover:tw-bg-muted hover:tw-text-muted-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50 data-[state=on]:tw-bg-accent data-[state=on]:tw-text-accent-foreground",{variants:{variant:{default:"tw-bg-transparent",outline:"tw-border tw-border-input tw-bg-transparent hover:tw-bg-accent hover:tw-text-accent-foreground"},size:{default:"tw-h-10 tw-px-3",sm:"tw-h-9 tw-px-2.5",lg:"tw-h-11 tw-px-5"}},defaultVariants:{variant:"default",size:"default"}}),xc=g.forwardRef(({className:e,variant:t,size:n,...r},o)=>a.jsx(ts.Root,{ref:o,className:N(Ps({variant:t,size:n,className:e})),...r}));xc.displayName=ts.Root.displayName;const Is=g.createContext({size:"default",variant:"default"}),mo=g.forwardRef(({className:e,variant:t,size:n,children:r,...o},s)=>a.jsx(rr.Root,{ref:s,className:N("pr-twp tw-flex tw-items-center tw-justify-center tw-gap-1",e),...o,children:a.jsx(Is.Provider,{value:{variant:t,size:n},children:r})}));mo.displayName=rr.Root.displayName;const fn=g.forwardRef(({className:e,children:t,variant:n,size:r,...o},s)=>{const i=g.useContext(Is);return a.jsx(rr.Item,{ref:s,className:N(Ps({variant:i.variant||n,size:i.size||r}),e),...o,children:t})});fn.displayName=rr.Item.displayName;const ir=e=>e==="asc"?a.jsx(Q.ArrowUpIcon,{className:"tw-ms-2 tw-h-4 tw-w-4"}):e==="desc"?a.jsx(Q.ArrowDownIcon,{className:"tw-ms-2 tw-h-4 tw-w-4"}):a.jsx(Q.ArrowUpDownIcon,{className:"tw-ms-2 tw-h-4 tw-w-4"}),yc=e=>({accessorKey:"item",accessorFn:t=>t.items[0],header:({column:t})=>a.jsxs(fe,{variant:"ghost",onClick:()=>t.toggleSorting(void 0),children:[e,ir(t.getIsSorted())]})}),Nc=(e,t)=>({accessorKey:`item${t}`,accessorFn:n=>n.items[t],header:({column:n})=>a.jsxs(fe,{variant:"ghost",onClick:()=>n.toggleSorting(void 0),children:[e,ir(n.getIsSorted())]})}),kc=e=>({accessorKey:"count",header:({column:t})=>a.jsx("div",{className:"tw-flex tw-justify-end tw-tabular-nums",children:a.jsxs(fe,{variant:"ghost",onClick:()=>t.toggleSorting(void 0),children:[e,ir(t.getIsSorted())]})}),cell:({row:t})=>a.jsx("div",{className:"tw-flex tw-justify-end",children:t.getValue("count")})}),Rr=(e,t,n,r,o,s)=>{let i=[...n];e.forEach(c=>{t==="approved"?i.includes(c)||i.push(c):i=i.filter(d=>d!==c)}),r(i);let l=[...o];e.forEach(c=>{t==="unapproved"?l.includes(c)||l.push(c):l=l.filter(d=>d!==c)}),s(l)},Sc=(e,t,n,r,o)=>({accessorKey:"status",header:({column:s})=>a.jsx("div",{className:"tw-flex tw-justify-center",children:a.jsxs(fe,{variant:"ghost",onClick:()=>s.toggleSorting(void 0),children:[e,ir(s.getIsSorted())]})}),cell:({row:s})=>{const i=s.getValue("status"),l=s.getValue("item");return a.jsxs(mo,{value:i,variant:"outline",type:"single",children:[a.jsx(fn,{onClick:()=>Rr([l],"approved",t,n,r,o),value:"approved",children:a.jsx(Q.CircleCheckIcon,{})}),a.jsx(fn,{onClick:()=>Rr([l],"unapproved",t,n,r,o),value:"unapproved",children:a.jsx(Q.CircleXIcon,{})}),a.jsx(fn,{onClick:()=>Rr([l],"unknown",t,n,r,o),value:"unknown",children:a.jsx(Q.CircleHelpIcon,{})})]})}}),Ec=Object.freeze(["%webView_inventory_all%","%webView_inventory_approved%","%webView_inventory_unapproved%","%webView_inventory_unknown%","%webView_inventory_scope_currentBook%","%webView_inventory_scope_chapter%","%webView_inventory_scope_verse%","%webView_inventory_filter_text%","%webView_inventory_show_additional_items%","%webView_inventory_occurrences_table_header_reference%","%webView_inventory_occurrences_table_header_occurrence%"]),jc=(e,t,n)=>{let r=e;return t!=="all"&&(r=r.filter(o=>t==="approved"&&o.status==="approved"||t==="unapproved"&&o.status==="unapproved"||t==="unknown"&&o.status==="unknown")),n!==""&&(r=r.filter(o=>o.items[0].includes(n))),r},Cc=(e,t,n,r,o)=>{if(!e)return[];const s=[];let i=t.bookNum,l=t.chapterNum,c=t.verseNum;return Rs(e).forEach(u=>{u.startsWith("\\id")&&(i=Os(u),l=0,c=0),u.startsWith("\\c")&&(l=Hr(u),c=0),u.startsWith("\\v")&&(c=Hr(u),l===0&&(l=t.chapterNum));let h=o.exec(u)??void 0;for(;h;){const w=[];h.forEach(m=>w.push(m));const b=h.index,x=s.find(m=>W.deepEqual(m.items,w)),f={reference:{bookNum:i!==void 0?i:-1,chapterNum:l!==void 0?l:-1,verseNum:c!==void 0?c:-1},text:W.substring(u,Math.max(0,b-25),Math.min(b+25,u.length))};if(x)x.count+=1,x.occurrences.push(f);else{const m={items:w,count:1,status:_s(w[0],n,r),occurrences:[f]};s.push(m)}h=o.exec(u)??void 0}}),s},Je=(e,t)=>e[t]??t;function Tc({scriptureReference:e,setScriptureReference:t,localizedStrings:n,extractItems:r,additionalItemsLabels:o,approvedItems:s,unapprovedItems:i,text:l,scope:c,onScopeChange:d,columns:u}){const h=Je(n,"%webView_inventory_all%"),w=Je(n,"%webView_inventory_approved%"),b=Je(n,"%webView_inventory_unapproved%"),x=Je(n,"%webView_inventory_unknown%"),f=Je(n,"%webView_inventory_scope_currentBook%"),m=Je(n,"%webView_inventory_scope_chapter%"),S=Je(n,"%webView_inventory_scope_verse%"),R=Je(n,"%webView_inventory_filter_text%"),j=Je(n,"%webView_inventory_show_additional_items%"),[E,v]=g.useState(!1),[P,V]=g.useState("all"),[U,C]=g.useState(""),[_,k]=g.useState([]),D=g.useMemo(()=>l?r instanceof RegExp?Cc(l,e,s,i,r):r(l,e,s,i):[],[l,r,e,s,i]),$=g.useMemo(()=>{if(E)return D;const y=[];return D.forEach(T=>{const z=T.items[0],L=y.find(B=>B.items[0]===z);L?(L.count+=T.count,L.occurrences=L.occurrences.concat(T.occurrences)):y.push({items:[z],count:T.count,occurrences:T.occurrences,status:T.status})}),y},[E,D]),J=g.useMemo(()=>jc($,P,U),[$,P,U]),Y=g.useMemo(()=>{var z,L;if(!E)return u;const y=(z=o==null?void 0:o.tableHeaders)==null?void 0:z.length;if(!y)return u;const T=[];for(let B=0;B{k([])},[J]);const F=(y,T)=>{T.setRowSelection(()=>{const z={};return z[y.index]=!0,z}),k(y.original.items)},te=y=>{if(y==="book"||y==="chapter"||y==="verse")d(y);else throw new Error(`Invalid scope value: ${y}`)},se=y=>{if(y==="all"||y==="approved"||y==="unapproved"||y==="unknown")V(y);else throw new Error(`Invalid status filter value: ${y}`)},oe=g.useMemo(()=>{if($.length===0||_.length===0)return[];const y=$.filter(T=>W.deepEqual(E?T.items:[T.items[0]],_));if(y.length>1)throw new Error("Selected item is not unique");return y[0].occurrences},[_,E,$]);return a.jsxs("div",{className:"pr-twp tw-flex tw-h-full tw-flex-col",children:[a.jsxs("div",{className:"tw-flex tw-items-stretch",children:[a.jsxs(At,{onValueChange:y=>se(y),defaultValue:P,children:[a.jsx(bt,{className:"tw-m-1",children:a.jsx(Bt,{placeholder:"Select filter"})}),a.jsxs(vt,{children:[a.jsx(Ae,{value:"all",children:h}),a.jsx(Ae,{value:"approved",children:w}),a.jsx(Ae,{value:"unapproved",children:b}),a.jsx(Ae,{value:"unknown",children:x})]})]}),a.jsxs(At,{onValueChange:y=>te(y),defaultValue:c,children:[a.jsx(bt,{className:"tw-m-1",children:a.jsx(Bt,{placeholder:"Select scope"})}),a.jsxs(vt,{children:[a.jsx(Ae,{value:"book",children:f}),a.jsx(Ae,{value:"chapter",children:m}),a.jsx(Ae,{value:"verse",children:S})]})]}),a.jsx(St,{className:"tw-m-1 tw-rounded-md tw-border",placeholder:R,value:U,onChange:y=>{C(y.target.value)}}),o&&a.jsxs("div",{className:"tw-m-1 tw-flex tw-items-center tw-rounded-md tw-border",children:[a.jsx(sr,{className:"tw-m-1",checked:E,onCheckedChange:y=>{k([]),v(y)}}),a.jsx(qe,{className:"tw-m-1 tw-flex-shrink-0 tw-whitespace-nowrap",children:(o==null?void 0:o.checkboxText)??j})]})]}),a.jsx("div",{className:"tw-m-1 tw-flex-1 tw-overflow-auto tw-rounded-md tw-border",children:a.jsx(Ts,{columns:Y,data:J,onRowClickHandler:F,stickyHeader:!0})}),oe.length>0&&a.jsx("div",{className:"tw-m-1 tw-flex-1 tw-overflow-auto tw-rounded-md tw-border",children:a.jsx(vc,{occurrenceData:oe,setScriptureReference:t,localizedStrings:n})})]})}function ho({className:e,onSearch:t,placeholder:n,isFullWidth:r}){const[o,s]=g.useState(""),i=l=>{s(l),t(l)};return a.jsx(St,{className:N("tw-flex tw-h-10 tw-rounded-md tw-border tw-border-input tw-bg-background tw-px-3 tw-py-2 tw-text-sm tw-ring-offset-background file:tw-border-0 file:tw-bg-transparent file:tw-text-sm file:tw-font-medium placeholder:tw-text-muted-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-[color:hsl(240,5%,64.9%)] focus-visible:tw-ring-offset-2 disabled:tw-cursor-not-allowed disabled:tw-opacity-50",{"tw-w-full":r},e),placeholder:n,value:o,onChange:l=>i(l.target.value)})}const go=g.forwardRef(({className:e,...t},n)=>a.jsx(Oe.Root,{orientation:"vertical",ref:n,className:N("tw-flex tw-gap-1 tw-rounded-md tw-text-muted-foreground",e),...t}));go.displayName=Oe.List.displayName;const bo=g.forwardRef(({className:e,...t},n)=>a.jsx(Oe.List,{ref:n,className:N("tw-flex-fit tw-mlk-items-center tw-w-[124px] tw-justify-center tw-rounded-md tw-bg-muted tw-p-1 tw-text-muted-foreground",e),...t}));bo.displayName=Oe.List.displayName;const Ms=g.forwardRef(({className:e,...t},n)=>a.jsx(Oe.Trigger,{ref:n,...t,className:N("overflow-clip tw-inline-flex tw-w-[116px] tw-cursor-pointer tw-items-center tw-justify-center tw-break-words tw-rounded-sm tw-border-0 tw-bg-muted tw-px-3 tw-py-1.5 tw-text-sm tw-font-medium tw-text-inherit tw-ring-offset-background tw-transition-all hover:tw-text-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50 data-[state=active]:tw-bg-background data-[state=active]:tw-text-foreground data-[state=active]:tw-shadow-sm",e)})),vo=g.forwardRef(({className:e,...t},n)=>a.jsx(Oe.Content,{ref:n,className:N("tw-ms-5 tw-flex-grow tw-text-foreground tw-ring-offset-background focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2",e),...t}));vo.displayName=Oe.Content.displayName;function Rc({tabList:e,onSearch:t,searchPlaceholder:n,headerTitle:r,isSearchBarFullWidth:o=!1,direction:s="ltr"}){return a.jsxs("div",{className:"pr-twp",children:[a.jsxs("div",{className:"tw-sticky tw-top-0 tw-space-y-2 tw-pb-2",children:[r?a.jsx("h1",{children:r}):"",a.jsx(ho,{isFullWidth:o,onSearch:t,placeholder:n})]}),a.jsxs(go,{dir:s,children:[a.jsx(bo,{children:e.map(i=>a.jsx(Ms,{value:i.value,children:i.value},i.key))}),e.map(i=>a.jsx(vo,{value:i.value,children:i.content},i.key))]})]})}const lr=g.forwardRef(({className:e,orientation:t="horizontal",decorative:n=!0,...r},o)=>a.jsx(ns.Root,{ref:o,decorative:n,orientation:t,className:N("pr-twp tw-shrink-0 tw-bg-border",t==="horizontal"?"tw-h-[1px] tw-w-full":"tw-h-full tw-w-[1px]",e),...r}));lr.displayName=ns.Root.displayName;const Oc=be.Root,_c=be.Portal,$s=M.forwardRef(({className:e,...t},n)=>a.jsx(be.Overlay,{className:N("tw-fixed tw-inset-0 tw-z-50 tw-bg-black/80 data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0",e),...t,ref:n}));$s.displayName=be.Overlay.displayName;const Pc=Xt.cva("pr-twp tw-fixed tw-z-50 tw-gap-4 tw-bg-background tw-p-6 tw-shadow-lg tw-transition tw-ease-in-out data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-duration-300 data-[state=open]:tw-duration-500",{variants:{side:{top:"tw-inset-x-0 tw-top-0 tw-border-b data-[state=closed]:tw-slide-out-to-top data-[state=open]:tw-slide-in-from-top",bottom:"tw-inset-x-0 tw-bottom-0 tw-border-t data-[state=closed]:tw-slide-out-to-bottom data-[state=open]:tw-slide-in-from-bottom",left:"tw-inset-y-0 tw-left-0 tw-h-full tw-w-3/4 tw-border-r data-[state=closed]:tw-slide-out-to-left data-[state=open]:tw-slide-in-from-left sm:tw-max-w-sm",right:"tw-inset-y-0 tw-right-0 tw-h-full tw-w-3/4 tw- tw-border-l data-[state=closed]:tw-slide-out-to-right data-[state=open]:tw-slide-in-from-right sm:tw-max-w-sm"}},defaultVariants:{side:"right"}}),Ds=M.forwardRef(({side:e="right",className:t,children:n,...r},o)=>a.jsxs(_c,{children:[a.jsx($s,{}),a.jsxs(be.Content,{ref:o,className:N(Pc({side:e}),t),...r,children:[n,a.jsxs(be.Close,{className:"tw-absolute tw-right-4 tw-top-4 tw-rounded-sm tw-opacity-70 tw-ring-offset-background tw-transition-opacity hover:tw-opacity-100 focus:tw-outline-none focus:tw-ring-2 focus:tw-ring-ring focus:tw-ring-offset-2 disabled:tw-pointer-events-none data-[state=open]:tw-bg-secondary",children:[a.jsx(Q.X,{className:"tw-h-4 tw-w-4"}),a.jsx("span",{className:"tw-sr-only",children:"Close"})]})]})]}));Ds.displayName=be.Content.displayName;const Ic=M.forwardRef(({className:e,...t},n)=>a.jsx(be.Title,{ref:n,className:N("tw-text-lg tw-font-semibold tw-text-foreground",e),...t}));Ic.displayName=be.Title.displayName;const Mc=M.forwardRef(({className:e,...t},n)=>a.jsx(be.Description,{ref:n,className:N("tw-text-sm tw-text-muted-foreground",e),...t}));Mc.displayName=be.Description.displayName;function sa({className:e,...t}){return a.jsx("div",{className:N("pr-twp tw-animate-pulse tw-rounded-md tw-bg-muted",e),...t})}const $c=Sn.Provider,Dc=Sn.Root,Ac=Sn.Trigger,As=g.forwardRef(({className:e,sideOffset:t=4,...n},r)=>a.jsx(Sn.Content,{ref:r,sideOffset:t,className:N("pr-twp tw-z-50 tw-overflow-hidden tw-rounded-md tw-border tw-bg-popover tw-px-3 tw-py-1.5 tw-text-sm tw-text-popover-foreground tw-shadow-md tw-animate-in tw-fade-in-0 tw-zoom-in-95 data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=closed]:tw-zoom-out-95 data-[side=bottom]:tw-slide-in-from-top-2 data-[side=left]:tw-slide-in-from-right-2 data-[side=right]:tw-slide-in-from-left-2 data-[side=top]:tw-slide-in-from-bottom-2",e),...n}));As.displayName=Sn.Content.displayName;const Or=768;function Bc(){const[e,t]=M.useState(void 0);return M.useEffect(()=>{const n=window.matchMedia(`(max-width: ${Or-1}px)`),r=()=>{t(window.innerWidthn.removeEventListener("change",r)},[]),!!e}const Vc="sidebar:state",zc=60*60*24*7,Lc="16rem",Fc="18rem",Gc="3rem",Uc="b",Bs=g.createContext(void 0);function cr(){const e=g.useContext(Bs);if(!e)throw new Error("useSidebar must be used within a SidebarProvider.");return e}const Vs=g.forwardRef(({defaultOpen:e=!0,open:t,onOpenChange:n,className:r,style:o,children:s,...i},l)=>{const c=Bc(),[d,u]=g.useState(!1),[h,w]=g.useState(e),b=t??h,x=g.useCallback(R=>{const j=typeof R=="function"?R(b):R;n?n(j):w(j),document.cookie=`${Vc}=${j}; path=/; max-age=${zc}`},[n,b]),f=g.useCallback(()=>c?u(R=>!R):x(R=>!R),[c,x,u]);g.useEffect(()=>{const R=j=>{j.key===Uc&&(j.metaKey||j.ctrlKey)&&(j.preventDefault(),f())};return window.addEventListener("keydown",R),()=>window.removeEventListener("keydown",R)},[f]);const m=b?"expanded":"collapsed",S=g.useMemo(()=>({state:m,open:b,setOpen:x,isMobile:c,openMobile:d,setOpenMobile:u,toggleSidebar:f}),[m,b,x,c,d,u,f]);return a.jsx(Bs.Provider,{value:S,children:a.jsx($c,{delayDuration:0,children:a.jsx("div",{style:{"--sidebar-width":Lc,"--sidebar-width-icon":Gc,...o},className:N("tw-group/sidebar-wrapper pr-twp tw-flex tw-w-full has-[[data-variant=inset]]:tw-bg-sidebar",r),ref:l,...i,children:s})})})});Vs.displayName="SidebarProvider";const zs=g.forwardRef(({side:e="left",variant:t="sidebar",collapsible:n="offcanvas",className:r,children:o,...s},i)=>{const{isMobile:l,state:c,openMobile:d,setOpenMobile:u}=cr();return n==="none"?a.jsx("div",{className:N("tw-flex tw-h-full tw-w-[--sidebar-width] tw-flex-col tw-bg-sidebar tw-text-sidebar-foreground",r),ref:i,...s,children:o}):l?a.jsx(Oc,{open:d,onOpenChange:u,...s,children:a.jsx(Ds,{"data-sidebar":"sidebar","data-mobile":"true",className:"tw-w-[--sidebar-width] tw-bg-sidebar tw-p-0 tw-text-sidebar-foreground [&>button]:tw-hidden",style:{"--sidebar-width":Fc},side:e,children:a.jsx("div",{className:"tw-flex tw-h-full tw-w-full tw-flex-col",children:o})})}):a.jsxs("div",{ref:i,className:"tw-group tw-peer tw-hidden tw-text-sidebar-foreground md:tw-block","data-state":c,"data-collapsible":c==="collapsed"?n:"","data-variant":t,"data-side":e,children:[a.jsx("div",{className:N("tw-relative tw-h-svh tw-w-[--sidebar-width] tw-bg-transparent tw-transition-[width] tw-duration-200 tw-ease-linear","group-data-[collapsible=offcanvas]:tw-w-0","group-data-[side=right]:tw-rotate-180",t==="floating"||t==="inset"?"group-data-[collapsible=icon]:tw-w-[calc(var(--sidebar-width-icon)_+_theme(spacing.4))]":"group-data-[collapsible=icon]:tw-w-[--sidebar-width-icon]")}),a.jsx("div",{className:N("tw-absolute tw-inset-y-0 tw-z-10 tw-hidden tw-h-svh tw-w-[--sidebar-width] tw-transition-[left,right,width] tw-duration-200 tw-ease-linear md:tw-flex",e==="left"?"tw-left-0 group-data-[collapsible=offcanvas]:tw-left-[calc(var(--sidebar-width)*-1)]":"tw-right-0 group-data-[collapsible=offcanvas]:tw-right-[calc(var(--sidebar-width)*-1)]",t==="floating"||t==="inset"?"tw-p-2 group-data-[collapsible=icon]:tw-w-[calc(var(--sidebar-width-icon)_+_theme(spacing.4)_+2px)]":"group-data-[collapsible=icon]:tw-w-[--sidebar-width-icon] group-data-[side=left]:tw-border-r group-data-[side=right]:tw-border-l",r),...s,children:a.jsx("div",{"data-sidebar":"sidebar",className:"tw-flex tw-h-full tw-w-full tw-flex-col tw-bg-sidebar group-data-[variant=floating]:tw-rounded-lg group-data-[variant=floating]:tw-border group-data-[variant=floating]:tw-border-sidebar-border group-data-[variant=floating]:tw-shadow",children:o})})]})});zs.displayName="Sidebar";const qc=g.forwardRef(({className:e,onClick:t,...n},r)=>{const{toggleSidebar:o}=cr();return a.jsxs(fe,{ref:r,"data-sidebar":"trigger",variant:"ghost",size:"icon",className:N("tw-h-7 tw-w-7",e),onClick:s=>{t==null||t(s),o()},...n,children:[a.jsx(Q.PanelLeft,{}),a.jsx("span",{className:"tw-sr-only",children:"Toggle Sidebar"})]})});qc.displayName="SidebarTrigger";const Hc=g.forwardRef(({className:e,...t},n)=>{const{toggleSidebar:r}=cr();return a.jsx("button",{type:"button",ref:n,"data-sidebar":"rail","aria-label":"Toggle Sidebar",tabIndex:-1,onClick:r,title:"Toggle Sidebar",className:N("tw-absolute tw-inset-y-0 tw-z-20 tw-hidden tw-w-4 tw--translate-x-1/2 tw-transition-all tw-ease-linear after:tw-absolute after:tw-inset-y-0 after:tw-left-1/2 after:tw-w-[2px] hover:after:tw-bg-sidebar-border group-data-[side=left]:tw--right-4 group-data-[side=right]:tw-left-0 sm:tw-flex","[[data-side=left]_&]:tw-cursor-w-resize [[data-side=right]_&]:tw-cursor-e-resize","[[data-side=left][data-state=collapsed]_&]:tw-cursor-e-resize [[data-side=right][data-state=collapsed]_&]:tw-cursor-w-resize","group-data-[collapsible=offcanvas]:tw-translate-x-0 group-data-[collapsible=offcanvas]:after:tw-left-full group-data-[collapsible=offcanvas]:hover:tw-bg-sidebar","[[data-side=left][data-collapsible=offcanvas]_&]:tw--right-2","[[data-side=right][data-collapsible=offcanvas]_&]:tw--left-2",e),...t})});Hc.displayName="SidebarRail";const Ls=g.forwardRef(({className:e,...t},n)=>a.jsx("main",{ref:n,className:N("tw-relative tw-flex tw-flex-1 tw-flex-col tw-bg-background","peer-data-[variant=inset]:tw-min-h-[calc(100svh-theme(spacing.4))] md:peer-data-[variant=inset]:tw-m-2 md:peer-data-[state=collapsed]:peer-data-[variant=inset]:tw-ml-2 md:peer-data-[variant=inset]:tw-ml-0 md:peer-data-[variant=inset]:tw-rounded-xl md:peer-data-[variant=inset]:tw-shadow",e),...t}));Ls.displayName="SidebarInset";const Xc=g.forwardRef(({className:e,...t},n)=>a.jsx(St,{ref:n,"data-sidebar":"input",className:N("tw-h-8 tw-w-full tw-bg-background tw-shadow-none focus-visible:tw-ring-2 focus-visible:tw-ring-sidebar-ring",e),...t}));Xc.displayName="SidebarInput";const Yc=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,"data-sidebar":"header",className:N("tw-flex tw-flex-col tw-gap-2 tw-p-2",e),...t}));Yc.displayName="SidebarHeader";const Wc=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,"data-sidebar":"footer",className:N("tw-flex tw-flex-col tw-gap-2 tw-p-2",e),...t}));Wc.displayName="SidebarFooter";const Kc=g.forwardRef(({className:e,...t},n)=>a.jsx(lr,{ref:n,"data-sidebar":"separator",className:N("tw-mx-2 tw-w-auto tw-bg-sidebar-border",e),...t}));Kc.displayName="SidebarSeparator";const Fs=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,"data-sidebar":"content",className:N("tw-flex tw-min-h-0 tw-flex-1 tw-flex-col tw-gap-2 tw-overflow-auto group-data-[collapsible=icon]:tw-overflow-hidden",e),...t}));Fs.displayName="SidebarContent";const Xr=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,"data-sidebar":"group",className:N("tw-relative tw-flex tw-w-full tw-min-w-0 tw-flex-col tw-p-2",e),...t}));Xr.displayName="SidebarGroup";const Yr=g.forwardRef(({className:e,asChild:t=!1,...n},r)=>{const o=t?Ht.Slot:"div";return a.jsx(o,{ref:r,"data-sidebar":"group-label",className:N("tw-flex tw-h-8 tw-shrink-0 tw-items-center tw-rounded-md tw-px-2 tw-text-xs tw-font-medium tw-text-sidebar-foreground/70 tw-outline-none tw-ring-sidebar-ring tw-transition-[margin,opa] tw-duration-200 tw-ease-linear focus-visible:tw-ring-2 [&>svg]:tw-size-4 [&>svg]:tw-shrink-0","group-data-[collapsible=icon]:tw--mt-8 group-data-[collapsible=icon]:tw-opacity-0",e),...n})});Yr.displayName="SidebarGroupLabel";const Jc=g.forwardRef(({className:e,asChild:t=!1,...n},r)=>{const o=t?Ht.Slot:"button";return a.jsx(o,{ref:r,"data-sidebar":"group-action",className:N("tw-absolute tw-right-3 tw-top-3.5 tw-flex tw-aspect-square tw-w-5 tw-items-center tw-justify-center tw-rounded-md tw-p-0 tw-text-sidebar-foreground tw-outline-none tw-ring-sidebar-ring tw-transition-transform hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground focus-visible:tw-ring-2 [&>svg]:tw-size-4 [&>svg]:tw-shrink-0","after:tw-absolute after:tw--inset-2 after:md:tw-hidden","group-data-[collapsible=icon]:tw-hidden",e),...n})});Jc.displayName="SidebarGroupAction";const Wr=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,"data-sidebar":"group-content",className:N("tw-w-full tw-text-sm",e),...t}));Wr.displayName="SidebarGroupContent";const Gs=g.forwardRef(({className:e,...t},n)=>a.jsx("ul",{ref:n,"data-sidebar":"menu",className:N("tw-flex tw-w-full tw-min-w-0 tw-flex-col tw-gap-1",e),...t}));Gs.displayName="SidebarMenu";const Us=g.forwardRef(({className:e,...t},n)=>a.jsx("li",{ref:n,"data-sidebar":"menu-item",className:N("tw-group/menu-item tw-relative",e),...t}));Us.displayName="SidebarMenuItem";const Zc=Xt.cva("tw-peer/menu-button tw-flex tw-w-full tw-items-center tw-gap-2 tw-overflow-hidden tw-rounded-md tw-p-2 tw-text-left tw-text-sm tw-outline-none tw-ring-sidebar-ring tw-transition-[width,height,padding] hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground focus-visible:tw-ring-2 active:tw-bg-sidebar-accent active:tw-text-sidebar-accent-foreground disabled:tw-pointer-events-none disabled:tw-opacity-50 tw-group-has-[[data-sidebar=menu-action]]/menu-item:pr-8 aria-disabled:tw-pointer-events-none aria-disabled:tw-opacity-50 data-[active=true]:tw-font-medium data-[active=true]:tw-text-sidebar-accent-foreground data-[state=open]:hover:tw-bg-sidebar-accent data-[state=open]:hover:tw-text-sidebar-accent-foreground group-data-[collapsible=icon]:tw-!size-8 group-data-[collapsible=icon]:tw-!p-2 [&>span:last-child]:tw-truncate [&>svg]:tw-size-4 [&>svg]:tw-shrink-0",{variants:{variant:{default:"hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground",outline:"tw-bg-background tw-shadow-[0_0_0_1px_hsl(var(--sidebar-border))] hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground hover:tw-shadow-[0_0_0_1px_hsl(var(--sidebar-accent))]"},size:{default:"tw-h-8 tw-text-sm",sm:"tw-h-7 tw-text-xs",lg:"tw-h-12 tw-text-sm group-data-[collapsible=icon]:tw-!p-0"}},defaultVariants:{variant:"default",size:"default"}}),qs=g.forwardRef(({asChild:e=!1,isActive:t=!1,variant:n="default",size:r="default",tooltip:o,className:s,...i},l)=>{const c=e?Ht.Slot:"button",{isMobile:d,state:u}=cr(),h=a.jsx(c,{ref:l,"data-sidebar":"menu-button","data-size":r,"data-active":t,className:N(Zc({variant:n,size:r}),s),...i});return o?(typeof o=="string"&&(o={children:o}),a.jsxs(Dc,{children:[a.jsx(Ac,{asChild:!0,children:h}),a.jsx(As,{side:"right",align:"center",hidden:u!=="collapsed"||d,...o})]})):h});qs.displayName="SidebarMenuButton";const Qc=g.forwardRef(({className:e,asChild:t=!1,showOnHover:n=!1,...r},o)=>{const s=t?Ht.Slot:"button";return a.jsx(s,{ref:o,"data-sidebar":"menu-action",className:N("tw-peer-hover/menu-button:text-sidebar-accent-foreground tw-absolute tw-right-1 tw-top-1.5 tw-flex tw-aspect-square tw-w-5 tw-items-center tw-justify-center tw-rounded-md tw-p-0 tw-text-sidebar-foreground tw-outline-none tw-ring-sidebar-ring tw-transition-transform hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground focus-visible:tw-ring-2 [&>svg]:tw-size-4 [&>svg]:tw-shrink-0","after:tw-absolute after:tw--inset-2 after:md:tw-hidden","tw-peer-data-[size=sm]/menu-button:top-1","tw-peer-data-[size=default]/menu-button:top-1.5","tw-peer-data-[size=lg]/menu-button:top-2.5","group-data-[collapsible=icon]:tw-hidden",n&&"tw-group-focus-within/menu-item:opacity-100 tw-group-hover/menu-item:opacity-100 tw-peer-data-[active=true]/menu-button:text-sidebar-accent-foreground data-[state=open]:tw-opacity-100 md:tw-opacity-0",e),...r})});Qc.displayName="SidebarMenuAction";const ed=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,"data-sidebar":"menu-badge",className:N("tw-pointer-events-none tw-absolute tw-right-1 tw-flex tw-h-5 tw-min-w-5 tw-select-none tw-items-center tw-justify-center tw-rounded-md tw-px-1 tw-text-xs tw-font-medium tw-tabular-nums tw-text-sidebar-foreground","tw-peer-hover/menu-button:text-sidebar-accent-foreground tw-peer-data-[active=true]/menu-button:text-sidebar-accent-foreground","tw-peer-data-[size=sm]/menu-button:top-1","tw-peer-data-[size=default]/menu-button:top-1.5","tw-peer-data-[size=lg]/menu-button:top-2.5","group-data-[collapsible=icon]:tw-hidden",e),...t}));ed.displayName="SidebarMenuBadge";const td=g.forwardRef(({className:e,showIcon:t=!1,...n},r)=>{const o=g.useMemo(()=>`${Math.floor(Math.random()*40)+50}%`,[]);return a.jsxs("div",{ref:r,"data-sidebar":"menu-skeleton",className:N("tw-flex tw-h-8 tw-items-center tw-gap-2 tw-rounded-md tw-px-2",e),...n,children:[t&&a.jsx(sa,{className:"tw-size-4 tw-rounded-md","data-sidebar":"menu-skeleton-icon"}),a.jsx(sa,{className:"tw-h-4 tw-max-w-[--skeleton-width] tw-flex-1","data-sidebar":"menu-skeleton-text",style:{"--skeleton-width":o}})]})});td.displayName="SidebarMenuSkeleton";const nd=g.forwardRef(({className:e,...t},n)=>a.jsx("ul",{ref:n,"data-sidebar":"menu-sub",className:N("tw-mx-3.5 tw-flex tw-min-w-0 tw-translate-x-px tw-flex-col tw-gap-1 tw-border-l tw-border-sidebar-border tw-px-2.5 tw-py-0.5","group-data-[collapsible=icon]:tw-hidden",e),...t}));nd.displayName="SidebarMenuSub";const rd=g.forwardRef(({...e},t)=>a.jsx("li",{ref:t,...e}));rd.displayName="SidebarMenuSubItem";const od=g.forwardRef(({asChild:e=!1,size:t="md",isActive:n,className:r,...o},s)=>{const i=e?Ht.Slot:"a";return a.jsx(i,{ref:s,"data-sidebar":"menu-sub-button","data-size":t,"data-active":n,className:N("tw-flex tw-h-7 tw-min-w-0 tw--translate-x-px tw-items-center tw-gap-2 tw-overflow-hidden tw-rounded-md tw-px-2 tw-text-sidebar-foreground tw-outline-none tw-ring-sidebar-ring hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground focus-visible:tw-ring-2 active:tw-bg-sidebar-accent active:tw-text-sidebar-accent-foreground disabled:tw-pointer-events-none disabled:tw-opacity-50 aria-disabled:tw-pointer-events-none aria-disabled:tw-opacity-50 [&>span:last-child]:tw-truncate [&>svg]:tw-size-4 [&>svg]:tw-shrink-0 [&>svg]:tw-text-sidebar-accent-foreground","data-[active=true]:tw-bg-sidebar-accent data-[active=true]:tw-text-sidebar-accent-foreground",t==="sm"&&"tw-text-xs",t==="md"&&"tw-text-sm","group-data-[collapsible=icon]:tw-hidden",r),...o})});od.displayName="SidebarMenuSubButton";function Hs({id:e,extensionLabels:t,projectOptions:n,handleSelectSidebarItem:r,selectedSidebarItem:o}){const s=g.useCallback((c,d)=>{r(c,d)},[r]),i=g.useCallback(c=>{const d=n.find(u=>u.projectId===c);return d?d.projectName:c},[n]),l=g.useCallback(c=>!o.projectId&&c===o.label,[o]);return a.jsx(zs,{id:e,collapsible:"none",variant:"inset",className:"tw-w-96 tw-gap-2 tw-overflow-y-auto tw-rounded tw-bg-slate-100",children:a.jsxs(Fs,{children:[a.jsxs(Xr,{children:[a.jsx(Yr,{className:"tw-text-sm tw-text-gray-400",children:"Extensions"}),a.jsx(Wr,{children:a.jsx(Gs,{children:t.map(c=>a.jsx(Us,{children:a.jsx(qs,{className:N("tw-rounded tw-py-2 tw-text-sm tw-text-gray-500 hover:tw-bg-white hover:tw-text-gray-900 hover:tw-shadow-sm active:tw-bg-white",{"tw-bg-white tw-text-gray-900 tw-shadow-sm":l(c)}),onClick:()=>s(c,void 0),isActive:l(c),children:a.jsx("span",{className:"tw-pl-3",children:c})})},c))})})]}),a.jsxs(Xr,{children:[a.jsx(Yr,{className:"tw-text-sm tw-text-gray-400",children:"Projects"}),a.jsx(Wr,{className:"tw-pl-3",children:a.jsx(Wn,{popoverContentClassName:"tw-z-[1000]",options:n.flatMap(c=>c.projectId),getOptionLabel:c=>i(c),buttonPlaceholder:"Type or select project",onChange:c=>{const d=i(c);s(d,c)},value:(o==null?void 0:o.projectId)??void 0})})]})]})})}function ad({id:e,direction:t="ltr",extensionLabels:n,projectOptions:r,children:o,handleSelectSidebarItem:s,selectedSidebarItem:i,onSearch:l}){return a.jsxs("div",{className:"tw-flex tw-h-full tw-flex-col tw-p-3 tw-pb-2",children:[a.jsx("div",{className:"tw-flex tw-items-center tw-justify-center tw-py-4",children:a.jsx(ho,{className:"tw-w-9/12",onSearch:l,placeholder:"Search app settings, extension settings, and project settings"})}),a.jsxs(Vs,{dir:t,id:e,className:"tw-h-full tw-flex-1 tw-gap-4",children:[a.jsx(Hs,{extensionLabels:n,projectOptions:r,handleSelectSidebarItem:s,selectedSidebarItem:i}),a.jsx(Ls,{className:"tw-overflow-y-auto",children:o})]})]})}const rt="scrBook",sd="scrRef",pt="source",id="details",ld="Scripture Reference",cd="Scripture Book",Xs="Type",dd="Details";function ud(e,t){const n=t??!1;return[{accessorFn:r=>`${ae.bookNumberToId(r.start.bookNum)} ${r.start.chapterNum}:${r.start.verseNum}`,id:rt,header:(e==null?void 0:e.scriptureReferenceColumnName)??ld,cell:r=>{const o=r.row.original;return r.row.getIsGrouped()?ae.bookNumberToEnglishName(o.start.bookNum):r.row.groupingColumnId===rt?W.formatScrRef(o.start):void 0},getGroupingValue:r=>r.start.bookNum,sortingFn:(r,o)=>W.compareScrRefs(r.original.start,o.original.start),enableGrouping:!0},{accessorFn:r=>W.formatScrRef(r.start),id:sd,header:void 0,cell:r=>{const o=r.row.original;return r.row.getIsGrouped()?void 0:W.formatScrRef(o.start)},sortingFn:(r,o)=>W.compareScrRefs(r.original.start,o.original.start),enableGrouping:!1},{accessorFn:r=>r.source.displayName,id:pt,header:n?(e==null?void 0:e.typeColumnName)??Xs:void 0,cell:r=>n||r.row.getIsGrouped()?r.getValue():void 0,getGroupingValue:r=>r.source.id,sortingFn:(r,o)=>r.original.source.displayName.localeCompare(o.original.source.displayName),enableGrouping:!0},{accessorFn:r=>r.detail,id,header:(e==null?void 0:e.detailsColumnName)??dd,cell:r=>r.getValue(),enableGrouping:!1}]}const pd=e=>{if(!("offset"in e.start))throw new Error("No offset available in range start");if(e.end&&!("offset"in e.end))throw new Error("No offset available in range end");const{offset:t}=e.start;let n=0;return e.end&&({offset:n}=e.end),!e.end||W.compareScrRefs(e.start,e.end)===0?`${W.scrRefToBBBCCCVVV(e.start)}+${t}`:`${W.scrRefToBBBCCCVVV(e.start)}+${t}-${W.scrRefToBBBCCCVVV(e.end)}+${n}`},ia=e=>`${pd({start:e.start,end:e.end})} ${e.source.displayName} ${e.detail}`;function wd({sources:e,showColumnHeaders:t=!1,showSourceColumn:n=!1,scriptureReferenceColumnName:r,scriptureBookGroupName:o,typeColumnName:s,detailsColumnName:i,onRowSelected:l,direction:c="ltr"}){const[d,u]=g.useState([]),[h,w]=g.useState([{id:rt,desc:!1}]),[b,x]=g.useState({}),f=g.useMemo(()=>e.flatMap(C=>C.data.map(_=>({..._,source:C.source}))),[e]),m=g.useMemo(()=>ud({scriptureReferenceColumnName:r,typeColumnName:s,detailsColumnName:i},n),[r,s,i,n]);g.useEffect(()=>{d.includes(pt)?w([{id:pt,desc:!1},{id:rt,desc:!1}]):w([{id:rt,desc:!1}])},[d]);const S=Se.useReactTable({data:f,columns:m,state:{grouping:d,sorting:h,rowSelection:b},onGroupingChange:u,onSortingChange:w,onRowSelectionChange:x,getExpandedRowModel:Se.getExpandedRowModel(),getGroupedRowModel:Se.getGroupedRowModel(),getCoreRowModel:Se.getCoreRowModel(),getSortedRowModel:Se.getSortedRowModel(),getRowId:ia,autoResetExpanded:!1,enableMultiRowSelection:!1,enableSubRowSelection:!1});g.useEffect(()=>{if(l){const C=S.getSelectedRowModel().rowsById,_=Object.keys(C);if(_.length===1){const k=f.find(D=>ia(D)===_[0])||void 0;k&&l(k)}}},[b,f,l,S]);const R=o??cd,j=s??Xs,E=[{label:"No Grouping",value:[]},{label:`Group by ${R}`,value:[rt]},{label:`Group by ${j}`,value:[pt]},{label:`Group by ${R} and ${j}`,value:[rt,pt]},{label:`Group by ${j} and ${R}`,value:[pt,rt]}],v=C=>{u(JSON.parse(C))},P=(C,_)=>{!C.getIsGrouped()&&!C.getIsSelected()&&C.getToggleSelectedHandler()(_)},V=(C,_)=>C.getIsGrouped()?"":N("banded-row",_%2===0?"even":"odd"),U=(C,_,k)=>{if(!((C==null?void 0:C.length)===0||_.depth{v(C)},children:[a.jsx(bt,{className:"tw-mb-1 tw-mt-2",children:a.jsx(Bt,{})}),a.jsx(vt,{position:"item-aligned",children:a.jsx(ks,{children:E.map(C=>a.jsx(Ae,{value:JSON.stringify(C.value),children:C.label},C.label))})})]}),a.jsxs(Cn,{className:"tw-relative tw-flex tw-flex-col tw-overflow-y-auto tw-p-0",children:[t&&a.jsx(Tn,{children:S.getHeaderGroups().map(C=>a.jsx(Ze,{children:C.headers.filter(_=>_.column.columnDef.header).map(_=>a.jsx(Vt,{colSpan:_.colSpan,className:"top-0 tw-sticky",children:_.isPlaceholder?void 0:a.jsxs("div",{children:[_.column.getCanGroup()?a.jsx(fe,{variant:"ghost",title:`Toggle grouping by ${_.column.columnDef.header}`,onClick:_.column.getToggleGroupingHandler(),type:"button",children:_.column.getIsGrouped()?"🛑":"👊 "}):void 0," ",Se.flexRender(_.column.columnDef.header,_.getContext())]})},_.id))},C.id))}),a.jsx(Rn,{children:S.getRowModel().rows.map((C,_)=>a.jsx(Ze,{"data-state":C.getIsSelected()?"selected":"",className:N(V(C,_)),onClick:k=>P(C,k),children:C.getVisibleCells().map(k=>{if(!(k.getIsPlaceholder()||k.column.columnDef.enableGrouping&&!k.getIsGrouped()&&(k.column.columnDef.id!==pt||!n)))return a.jsx(xt,{className:N(k.column.columnDef.id,"tw-p-[1px]",U(d,C,k)),children:(()=>k.getIsGrouped()?a.jsxs(fe,{variant:"link",onClick:C.getToggleExpandedHandler(),type:"button",children:[C.getIsExpanded()&&a.jsx(Q.ChevronDown,{}),!C.getIsExpanded()&&(c==="ltr"?a.jsx(Q.ChevronRight,{}):a.jsx(Q.ChevronLeft,{}))," ",Se.flexRender(k.column.columnDef.cell,k.getContext())," (",C.subRows.length,")"]}):Se.flexRender(k.column.columnDef.cell,k.getContext()))()},k.id)})},C.id))})]})]})}const _r={[W.getLocalizeKeyForScrollGroupId("undefined")]:"Ø",[W.getLocalizeKeyForScrollGroupId(0)]:"A",[W.getLocalizeKeyForScrollGroupId(1)]:"B",[W.getLocalizeKeyForScrollGroupId(2)]:"C",[W.getLocalizeKeyForScrollGroupId(3)]:"D",[W.getLocalizeKeyForScrollGroupId(4)]:"E",[W.getLocalizeKeyForScrollGroupId(5)]:"F",[W.getLocalizeKeyForScrollGroupId(6)]:"G",[W.getLocalizeKeyForScrollGroupId(7)]:"H",[W.getLocalizeKeyForScrollGroupId(8)]:"I",[W.getLocalizeKeyForScrollGroupId(9)]:"J",[W.getLocalizeKeyForScrollGroupId(10)]:"K",[W.getLocalizeKeyForScrollGroupId(11)]:"L",[W.getLocalizeKeyForScrollGroupId(12)]:"M",[W.getLocalizeKeyForScrollGroupId(13)]:"N",[W.getLocalizeKeyForScrollGroupId(14)]:"O",[W.getLocalizeKeyForScrollGroupId(15)]:"P",[W.getLocalizeKeyForScrollGroupId(16)]:"Q",[W.getLocalizeKeyForScrollGroupId(17)]:"R",[W.getLocalizeKeyForScrollGroupId(18)]:"S",[W.getLocalizeKeyForScrollGroupId(19)]:"T",[W.getLocalizeKeyForScrollGroupId(20)]:"U",[W.getLocalizeKeyForScrollGroupId(21)]:"V",[W.getLocalizeKeyForScrollGroupId(22)]:"W",[W.getLocalizeKeyForScrollGroupId(23)]:"X",[W.getLocalizeKeyForScrollGroupId(24)]:"Y",[W.getLocalizeKeyForScrollGroupId(25)]:"Z"};function fd({availableScrollGroupIds:e,scrollGroupId:t,onChangeScrollGroupId:n,localizedStrings:r={}}){const o={..._r,...Object.fromEntries(Object.entries(r).map(([s,i])=>[s,s===i&&s in _r?_r[s]:i]))};return a.jsxs(At,{value:`${t}`,onValueChange:s=>n(s==="undefined"?void 0:parseInt(s,10)),children:[a.jsx(bt,{className:"pr-twp tw-w-auto",children:a.jsx(Bt,{placeholder:o[W.getLocalizeKeyForScrollGroupId(t)]??t})}),a.jsx(vt,{style:{zIndex:250},children:e.map(s=>a.jsx(Ae,{value:`${s}`,children:o[W.getLocalizeKeyForScrollGroupId(s)]},`${s}`))})]})}function md({children:e}){return a.jsx("div",{className:"pr-twp tw-grid",children:e})}function hd({primary:e,secondary:t,children:n,isLoading:r=!1,loadingMessage:o}){return a.jsxs("div",{className:"tw-flex tw-items-center tw-justify-between tw-space-x-4 tw-py-2",children:[a.jsxs("div",{children:[a.jsx("p",{className:"tw-text-sm tw-font-medium tw-leading-none",children:e}),a.jsx("p",{className:"tw-whitespace-normal tw-break-words tw-text-sm tw-text-muted-foreground",children:t})]}),r?a.jsx("p",{className:"tw-text-sm tw-text-muted-foreground",children:o}):a.jsx("div",{children:n})]})}function gd({primary:e,secondary:t,includeSeparator:n=!1}){return a.jsxs("div",{className:"tw-space-y-4 tw-py-2",children:[a.jsxs("div",{children:[a.jsx("h3",{className:"tw-text-lg tw-font-medium",children:e}),a.jsx("p",{className:"tw-text-sm tw-text-muted-foreground",children:t})]}),n?a.jsx(lr,{}):""]})}function bd({id:e,className:t,listItems:n,selectedListItems:r,handleSelectListItem:o,createLabel:s}){return a.jsx("div",{id:e,className:t,children:n.map(i=>a.jsxs("div",{className:"tw-m-2 tw-flex tw-items-center",children:[a.jsx(sr,{className:"tw-mr-2 tw-align-middle",checked:r.includes(i),onCheckedChange:l=>o(i,l)}),a.jsx(qe,{children:s?s(i):i})]},i))})}function vd(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}function xd(e){if(e.__esModule)return e;var t=e.default;if(typeof t=="function"){var n=function r(){return this instanceof r?Reflect.construct(t,arguments,this.constructor):t.apply(this,arguments)};n.prototype=t.prototype}else n={};return Object.defineProperty(n,"__esModule",{value:!0}),Object.keys(e).forEach(function(r){var o=Object.getOwnPropertyDescriptor(e,r);Object.defineProperty(n,r,o.get?o:{enumerable:!0,get:function(){return e[r]}})}),n}var xo={},Ys={exports:{}};(function(e){function t(n){return n&&n.__esModule?n:{default:n}}e.exports=t,e.exports.__esModule=!0,e.exports.default=e.exports})(Ys);var yd=Ys.exports,Pr={};function yo(e,t){return process.env.NODE_ENV==="production"?()=>null:function(...r){return e(...r)||t(...r)}}function O(){return O=Object.assign?Object.assign.bind():function(e){for(var t=1;t{t[n]=Ws(e[n])}),t}function Qe(e,t,n={clone:!0}){const r=n.clone?O({},e):e;return mt(e)&&mt(t)&&Object.keys(t).forEach(o=>{o!=="__proto__"&&(mt(t[o])&&o in e&&mt(e[o])?r[o]=Qe(e[o],t[o],n):n.clone?r[o]=mt(t[o])?Ws(t[o]):t[o]:r[o]=t[o])}),r}var Kr={exports:{}},zn={exports:{}},ie={};/** @license React v16.13.1 +"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const a=require("react/jsx-runtime"),g=require("react"),Q=require("lucide-react"),ot=require("clsx"),ml=require("tailwind-merge"),Za=require("@radix-ui/react-dropdown-menu"),W=require("platform-bible-utils"),Ht=require("@radix-ui/react-slot"),Xt=require("class-variance-authority"),hl=require("@radix-ui/react-label"),gl=require("@radix-ui/react-radio-group"),bl=require("@radix-ui/react-popover"),Re=require("cmdk"),vl=require("@radix-ui/react-dialog"),Se=require("@tanstack/react-table"),xl=require("@radix-ui/react-select"),yl=require("@radix-ui/react-checkbox"),Nl=require("@radix-ui/react-toggle-group"),kl=require("@radix-ui/react-toggle"),Sl=require("@radix-ui/react-tabs"),El=require("@radix-ui/react-separator"),jl=require("@radix-ui/react-tooltip"),Gr=require("@mui/styled-engine"),Me=require("@mui/material"),ln=require("react-dom"),Qa=require("sonner"),Cl=require("@radix-ui/react-slider"),Tl=require("@radix-ui/react-switch"),Rl=require("markdown-to-jsx");function ke(e){const t=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(e){for(const n in e)if(n!=="default"){const r=Object.getOwnPropertyDescriptor(e,n);Object.defineProperty(t,n,r.get?r:{enumerable:!0,get:()=>e[n]})}}return t.default=e,Object.freeze(t)}const M=ke(g),pe=ke(Za),es=ke(hl),bn=ke(gl),vn=ke(bl),be=ke(vl),ge=ke(xl),Ur=ke(yl),rr=ke(Nl),ts=ke(kl),Oe=ke(Sl),ns=ke(El),Sn=ke(jl),Ol=ke(ln),cn=ke(Cl),qr=ke(Tl);const _l=ml.extendTailwindMerge({prefix:"tw-"});function N(...e){return _l(ot.clsx(e))}const St=g.forwardRef(({className:e,type:t,...n},r)=>a.jsx("input",{type:t,className:N("pr-twp tw-flex tw-h-10 tw-rounded-md tw-border tw-border-input tw-bg-background tw-px-3 tw-py-2 tw-text-sm tw-ring-offset-background file:tw-border-0 file:tw-bg-transparent file:tw-text-sm file:tw-font-medium file:tw-text-foreground placeholder:tw-text-muted-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-cursor-not-allowed disabled:tw-opacity-50",e),ref:r,...n}));St.displayName="Input";const Pl=g.forwardRef(({handleSearch:e,handleKeyDown:t,handleOnClick:n,handleSubmit:r,...o},s)=>a.jsxs("div",{className:"tw-relative",children:[a.jsx(St,{...o,type:"text",className:"tw-box-border tw-gap-2.5 tw-rounded-lg tw-border tw-border-solid tw-bg-background tw-py-2 tw-pl-4 tw-pr-3 tw-font-medium tw-shadow-none tw-outline-none",onChange:i=>e(i.target.value),onKeyDown:i=>{i.key==="Enter"&&r(),t(i)},onClick:n,ref:s}),a.jsx(Q.History,{className:"tw-absolute tw-right-3 tw-top-1/2 tw-h-4 tw-w-4 tw--translate-y-1/2 tw-transform tw-cursor-pointer tw-text-muted-foreground",onClick:()=>{console.log("back in history")}})]}));var Il=Object.defineProperty,Ml=(e,t,n)=>t in e?Il(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,ne=(e,t,n)=>Ml(e,typeof t!="symbol"?t+"":t,n);const gt=["GEN","EXO","LEV","NUM","DEU","JOS","JDG","RUT","1SA","2SA","1KI","2KI","1CH","2CH","EZR","NEH","EST","JOB","PSA","PRO","ECC","SNG","ISA","JER","LAM","EZK","DAN","HOS","JOL","AMO","OBA","JON","MIC","NAM","HAB","ZEP","HAG","ZEC","MAL","MAT","MRK","LUK","JHN","ACT","ROM","1CO","2CO","GAL","EPH","PHP","COL","1TH","2TH","1TI","2TI","TIT","PHM","HEB","JAS","1PE","2PE","1JN","2JN","3JN","JUD","REV","TOB","JDT","ESG","WIS","SIR","BAR","LJE","S3Y","SUS","BEL","1MA","2MA","3MA","4MA","1ES","2ES","MAN","PS2","ODA","PSS","JSA","JDB","TBS","SST","DNT","BLT","XXA","XXB","XXC","XXD","XXE","XXF","XXG","FRT","BAK","OTH","3ES","EZA","5EZ","6EZ","INT","CNC","GLO","TDX","NDX","DAG","PS3","2BA","LBA","JUB","ENO","1MQ","2MQ","3MQ","REP","4BA","LAO"],ao=["XXA","XXB","XXC","XXD","XXE","XXF","XXG","FRT","BAK","OTH","INT","CNC","GLO","TDX","NDX"],rs=["Genesis","Exodus","Leviticus","Numbers","Deuteronomy","Joshua","Judges","Ruth","1 Samuel","2 Samuel","1 Kings","2 Kings","1 Chronicles","2 Chronicles","Ezra","Nehemiah","Esther (Hebrew)","Job","Psalms","Proverbs","Ecclesiastes","Song of Songs","Isaiah","Jeremiah","Lamentations","Ezekiel","Daniel (Hebrew)","Hosea","Joel","Amos","Obadiah","Jonah","Micah","Nahum","Habakkuk","Zephaniah","Haggai","Zechariah","Malachi","Matthew","Mark","Luke","John","Acts","Romans","1 Corinthians","2 Corinthians","Galatians","Ephesians","Philippians","Colossians","1 Thessalonians","2 Thessalonians","1 Timothy","2 Timothy","Titus","Philemon","Hebrews","James","1 Peter","2 Peter","1 John","2 John","3 John","Jude","Revelation","Tobit","Judith","Esther Greek","Wisdom of Solomon","Sirach (Ecclesiasticus)","Baruch","Letter of Jeremiah","Song of 3 Young Men","Susanna","Bel and the Dragon","1 Maccabees","2 Maccabees","3 Maccabees","4 Maccabees","1 Esdras (Greek)","2 Esdras (Latin)","Prayer of Manasseh","Psalm 151","Odes","Psalms of Solomon","Joshua A. *obsolete*","Judges B. *obsolete*","Tobit S. *obsolete*","Susanna Th. *obsolete*","Daniel Th. *obsolete*","Bel Th. *obsolete*","Extra A","Extra B","Extra C","Extra D","Extra E","Extra F","Extra G","Front Matter","Back Matter","Other Matter","3 Ezra *obsolete*","Apocalypse of Ezra","5 Ezra (Latin Prologue)","6 Ezra (Latin Epilogue)","Introduction","Concordance ","Glossary ","Topical Index","Names Index","Daniel Greek","Psalms 152-155","2 Baruch (Apocalypse)","Letter of Baruch","Jubilees","Enoch","1 Meqabyan","2 Meqabyan","3 Meqabyan","Reproof (Proverbs 25-31)","4 Baruch (Rest of Baruch)","Laodiceans"],ra=Ul();function Yt(e,t=!0){return t&&(e=e.toUpperCase()),e in ra?ra[e]:0}function so(e){return Yt(e)>0}function $l(e){const t=typeof e=="string"?Yt(e):e;return t>=40&&t<=66}function Dl(e){return(typeof e=="string"?Yt(e):e)<=39}function os(e){return e<=66}function Al(e){const t=typeof e=="string"?Yt(e):e;return is(t)&&!os(t)}function*Bl(){for(let e=1;e<=gt.length;e++)yield e}const Vl=1,as=gt.length;function zl(){return["XXA","XXB","XXC","XXD","XXE","XXF","XXG"]}function io(e,t="***"){const n=e-1;return n<0||n>=gt.length?t:gt[n]}function ss(e){return e<=0||e>as?"******":rs[e-1]}function Ll(e){return ss(Yt(e))}function is(e){const t=typeof e=="number"?io(e):e;return so(t)&&!ao.includes(t)}function Fl(e){const t=typeof e=="number"?io(e):e;return so(t)&&ao.includes(t)}function Gl(e){return rs[e-1].includes("*obsolete*")}function Ul(){const e={};for(let t=0;t(e[e.Unknown=0]="Unknown",e[e.Original=1]="Original",e[e.Septuagint=2]="Septuagint",e[e.Vulgate=3]="Vulgate",e[e.English=4]="English",e[e.RussianProtestant=5]="RussianProtestant",e[e.RussianOrthodox=6]="RussianOrthodox",e))(He||{});const Pe=class{constructor(t){if(ne(this,"name"),ne(this,"fullPath"),ne(this,"isPresent"),ne(this,"hasVerseSegments"),ne(this,"isCustomized"),ne(this,"baseVersification"),ne(this,"scriptureBooks"),ne(this,"_type"),t==null)throw new Error("Argument undefined");typeof t=="string"?(this.name=t,this._type=He[t]):(this._type=t,this.name=He[t])}get type(){return this._type}equals(t){return!t.type||!this.type?!1:t.type===this.type}};ne(Pe,"Original",new Pe(He.Original)),ne(Pe,"Septuagint",new Pe(He.Septuagint)),ne(Pe,"Vulgate",new Pe(He.Vulgate)),ne(Pe,"English",new Pe(He.English)),ne(Pe,"RussianProtestant",new Pe(He.RussianProtestant)),ne(Pe,"RussianOrthodox",new Pe(He.RussianOrthodox));let ut=Pe;function oa(e,t){const n=t[0];for(let r=1;r(e[e.Valid=0]="Valid",e[e.UnknownVersification=1]="UnknownVersification",e[e.OutOfRange=2]="OutOfRange",e[e.VerseOutOfOrder=3]="VerseOutOfOrder",e[e.VerseRepeated=4]="VerseRepeated",e))(ls||{});const je=class re{constructor(t,n,r,o){if(ne(this,"firstChapter"),ne(this,"lastChapter"),ne(this,"lastVerse"),ne(this,"hasSegmentsDefined"),ne(this,"text"),ne(this,"BBBCCCVVVS"),ne(this,"longHashCode"),ne(this,"versification"),ne(this,"rtlMark","‏"),ne(this,"_bookNum",0),ne(this,"_chapterNum",0),ne(this,"_verseNum",0),ne(this,"_verse"),r==null&&o==null)if(t!=null&&typeof t=="string"){const s=t,i=n!=null&&n instanceof ut?n:void 0;this.setEmpty(i),this.parse(s)}else if(t!=null&&typeof t=="number"){const s=n!=null&&n instanceof ut?n:void 0;this.setEmpty(s),this._verseNum=t%re.chapterDigitShifter,this._chapterNum=Math.floor(t%re.bookDigitShifter/re.chapterDigitShifter),this._bookNum=Math.floor(t/re.bookDigitShifter)}else if(n==null)if(t!=null&&t instanceof re){const s=t;this._bookNum=s.bookNum,this._chapterNum=s.chapterNum,this._verseNum=s.verseNum,this._verse=s.verse,this.versification=s.versification}else{if(t==null)return;const s=t instanceof ut?t:re.defaultVersification;this.setEmpty(s)}else throw new Error("VerseRef constructor not supported.");else if(t!=null&&n!=null&&r!=null)if(typeof t=="string"&&typeof n=="string"&&typeof r=="string")this.setEmpty(o),this.updateInternal(t,n,r);else if(typeof t=="number"&&typeof n=="number"&&typeof r=="number")this._bookNum=t,this._chapterNum=n,this._verseNum=r,this.versification=o??re.defaultVersification;else throw new Error("VerseRef constructor not supported.");else throw new Error("VerseRef constructor not supported.")}static isVerseParseable(t){return t.length>0&&"0123456789".includes(t[0])&&!t.endsWith(this.verseRangeSeparator)&&!t.endsWith(this.verseSequenceIndicator)}static tryParse(t){let n;try{return n=new re(t),{success:!0,verseRef:n}}catch(r){if(r instanceof nn)return n=new re,{success:!1,verseRef:n};throw r}}static getBBBCCCVVV(t,n,r){return t%re.bcvMaxValue*re.bookDigitShifter+(n>=0?n%re.bcvMaxValue*re.chapterDigitShifter:0)+(r>=0?r%re.bcvMaxValue:0)}static fromJSON(t){const{book:n,chapterNum:r,verseNum:o,verse:s,versificationStr:i}=t,l=s||o.toString();let c;return i&&(c=new ut(i)),n?new re(n,r.toString(),l,c):new re}static tryGetVerseNum(t){let n;if(!t)return n=-1,{success:!0,vNum:n};n=0;let r;for(let o=0;o"9")return o===0&&(n=-1),{success:!1,vNum:n};if(n=n*10+ +r-0,n>re.bcvMaxValue)return n=-1,{success:!1,vNum:n}}return{success:!0,vNum:n}}get isDefault(){return this.bookNum===0&&this.chapterNum===0&&this.verseNum===0&&this.versification==null}get hasMultiple(){return this._verse!=null&&(this._verse.includes(re.verseRangeSeparator)||this._verse.includes(re.verseSequenceIndicator))}get book(){return ae.bookNumberToId(this.bookNum,"")}set book(t){this.bookNum=ae.bookIdToNumber(t)}get chapter(){return this.isDefault||this._chapterNum<0?"":this._chapterNum.toString()}set chapter(t){const n=+t;this._chapterNum=Number.isInteger(n)?n:-1}get verse(){return this._verse!=null?this._verse:this.isDefault||this._verseNum<0?"":this._verseNum.toString()}set verse(t){const{success:n,vNum:r}=re.tryGetVerseNum(t);this._verse=n?void 0:t.replace(this.rtlMark,""),this._verseNum=r,!(this._verseNum>=0)&&({vNum:this._verseNum}=re.tryGetVerseNum(this._verse))}get bookNum(){return this._bookNum}set bookNum(t){if(t<=0||t>ae.lastBook)throw new nn("BookNum must be greater than zero and less than or equal to last book");this._bookNum=t}get chapterNum(){return this._chapterNum}set chapterNum(t){this.chapterNum=t}get verseNum(){return this._verseNum}set verseNum(t){this._verseNum=t}get versificationStr(){var t;return(t=this.versification)==null?void 0:t.name}set versificationStr(t){this.versification=this.versification!=null?new ut(t):void 0}get valid(){return this.validStatus===0}get validStatus(){return this.validateVerse(re.verseRangeSeparators,re.verseSequenceIndicators)}get BBBCCC(){return re.getBBBCCCVVV(this._bookNum,this._chapterNum,0)}get BBBCCCVVV(){return re.getBBBCCCVVV(this._bookNum,this._chapterNum,this._verseNum)}get isExcluded(){return!1}parse(t){if(t=t.replace(this.rtlMark,""),t.includes("/")){const s=t.split("/");if(t=s[0],s.length>1)try{const i=+s[1].trim();this.versification=new ut(He[i])}catch{throw new nn("Invalid reference : "+t)}}const n=t.trim().split(" ");if(n.length!==2)throw new nn("Invalid reference : "+t);const r=n[1].split(":"),o=+r[0];if(r.length!==2||ae.bookIdToNumber(n[0])===0||!Number.isInteger(o)||o<0||!re.isVerseParseable(r[1]))throw new nn("Invalid reference : "+t);this.updateInternal(n[0],r[0],r[1])}simplify(){this._verse=void 0}clone(){return new re(this)}toString(){const t=this.book;return t===""?"":`${t} ${this.chapter}:${this.verse}`}toJSON(){let t=this.verse;(t===""||t===this.verseNum.toString())&&(t=void 0);const n={book:this.book,chapterNum:this.chapterNum,verseNum:this.verseNum,verse:t,versificationStr:this.versificationStr};return t||delete n.verse,n}equals(t){return t instanceof re?t._bookNum===this._bookNum&&t._chapterNum===this._chapterNum&&t._verseNum===this._verseNum&&t.verse===this.verse&&(t.versification==null&&this.versification==null||t.versification!=null&&this.versification!=null&&t.versification.equals(this.versification)):!1}allVerses(t=!1,n=re.verseRangeSeparators,r=re.verseSequenceIndicators){if(this._verse==null||this.chapterNum<=0)return[this.clone()];const o=[],s=oa(this._verse,r);for(const i of s.map(l=>oa(l,n))){const l=this.clone();l.verse=i[0];const c=l.verseNum;if(o.push(l),i.length>1){const u=this.clone();if(u.verse=i[1],!t)for(let d=c+1;di)return 3;if(r===i)return 4;r=i}return 0}get internalValid(){return this.versification==null?1:this._bookNum<=0||this._bookNum>ae.lastBook?2:(ae.isCanonical(this._bookNum),0)}setEmpty(t=re.defaultVersification){this._bookNum=0,this._chapterNum=-1,this._verse=void 0,this.versification=t}updateInternal(t,n,r){this.bookNum=ae.bookIdToNumber(t),this.chapter=n,this.verse=r}};ne(je,"defaultVersification",ut.English),ne(je,"verseRangeSeparator","-"),ne(je,"verseSequenceIndicator",","),ne(je,"verseRangeSeparators",[je.verseRangeSeparator]),ne(je,"verseSequenceIndicators",[je.verseSequenceIndicator]),ne(je,"chapterDigitShifter",1e3),ne(je,"bookDigitShifter",je.chapterDigitShifter*je.chapterDigitShifter),ne(je,"bcvMaxValue",je.chapterDigitShifter-1),ne(je,"ValidStatusType",ls);class nn extends Error{}const or=pe.Root,lo=pe.Trigger,cs=pe.Group,ql=pe.Portal,Hl=pe.Sub,Xl=pe.RadioGroup,ds=g.forwardRef(({className:e,inset:t,children:n,...r},o)=>a.jsxs(pe.SubTrigger,{ref:o,className:N("tw-flex tw-cursor-default tw-select-none tw-items-center tw-rounded-sm tw-px-2 tw-py-1.5 tw-text-sm tw-outline-none focus:tw-bg-accent data-[state=open]:tw-bg-accent",t&&"tw-pl-8",e),...r,children:[n,a.jsx(Q.ChevronRight,{className:"tw-ml-auto tw-h-4 tw-w-4"})]}));ds.displayName=pe.SubTrigger.displayName;const us=g.forwardRef(({className:e,...t},n)=>a.jsx(pe.SubContent,{ref:n,className:N("tw-z-50 tw-min-w-[8rem] tw-overflow-hidden tw-rounded-md tw-border tw-bg-popover tw-p-1 tw-text-popover-foreground tw-shadow-lg data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0 data-[state=closed]:tw-zoom-out-95 data-[state=open]:tw-zoom-in-95 data-[side=bottom]:tw-slide-in-from-top-2 data-[side=left]:tw-slide-in-from-right-2 data-[side=right]:tw-slide-in-from-left-2 data-[side=top]:tw-slide-in-from-bottom-2",e),...t}));us.displayName=pe.SubContent.displayName;const En=g.forwardRef(({className:e,sideOffset:t=4,...n},r)=>a.jsx(pe.Portal,{children:a.jsx(pe.Content,{ref:r,sideOffset:t,className:N("pr-twp tw-z-50 tw-min-w-[8rem] tw-overflow-hidden tw-rounded-md tw-border tw-bg-popover tw-p-1 tw-text-popover-foreground tw-shadow-md data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0 data-[state=closed]:tw-zoom-out-95 data-[state=open]:tw-zoom-in-95 data-[side=bottom]:tw-slide-in-from-top-2 data-[side=left]:tw-slide-in-from-right-2 data-[side=right]:tw-slide-in-from-left-2 data-[side=top]:tw-slide-in-from-bottom-2",e),...n})}));En.displayName=pe.Content.displayName;const co=g.forwardRef(({className:e,inset:t,...n},r)=>a.jsx(pe.Item,{ref:r,className:N("tw-cursor-default tw-select-none tw-items-center tw-rounded-sm tw-px-2 tw-py-1.5 tw-text-sm tw-outline-none tw-transition-colors focus:tw-bg-accent data-[disabled]:tw-pointer-events-none data-[disabled]:tw-opacity-50",t&&"tw-pl-8",e),...n}));co.displayName=pe.Item.displayName;const ar=g.forwardRef(({className:e,children:t,checked:n,...r},o)=>a.jsxs(pe.CheckboxItem,{ref:o,className:N("tw-relative tw-flex tw-cursor-default tw-select-none tw-items-center tw-rounded-sm tw-py-1.5 tw-pl-8 tw-pr-2 tw-text-sm tw-outline-none tw-transition-colors focus:tw-bg-accent focus:tw-text-accent-foreground data-[disabled]:tw-pointer-events-none data-[disabled]:tw-opacity-50",e),checked:n,...r,children:[a.jsx("span",{className:"tw-absolute tw-left-2 tw-flex tw-h-3.5 tw-w-3.5 tw-items-center tw-justify-center",children:a.jsx(pe.ItemIndicator,{children:a.jsx(Q.Check,{className:"tw-h-4 tw-w-4"})})}),t]}));ar.displayName=pe.CheckboxItem.displayName;const uo=g.forwardRef(({className:e,children:t,...n},r)=>a.jsxs(pe.RadioItem,{ref:r,className:N("tw-relative tw-flex tw-cursor-default tw-select-none tw-items-center tw-rounded-sm tw-py-1.5 tw-pl-8 tw-pr-2 tw-text-sm tw-outline-none tw-transition-colors focus:tw-bg-accent focus:tw-text-accent-foreground data-[disabled]:tw-pointer-events-none data-[disabled]:tw-opacity-50",e),...n,children:[a.jsx("span",{className:"tw-absolute tw-left-2 tw-flex tw-h-3.5 tw-w-3.5 tw-items-center tw-justify-center",children:a.jsx(pe.ItemIndicator,{children:a.jsx(Q.Circle,{className:"tw-h-2 tw-w-2 tw-fill-current"})})}),t]}));uo.displayName=pe.RadioItem.displayName;const Wt=g.forwardRef(({className:e,inset:t,...n},r)=>a.jsx(pe.Label,{ref:r,className:N("tw-px-2 tw-py-1.5 tw-text-sm tw-font-semibold",t&&"tw-pl-8",e),...n}));Wt.displayName=pe.Label.displayName;const jn=g.forwardRef(({className:e,...t},n)=>a.jsx(pe.Separator,{ref:n,className:N("tw--mx-1 tw-my-1 tw-h-px tw-bg-muted",e),...t}));jn.displayName=pe.Separator.displayName;function ps({className:e,...t}){return a.jsx("span",{className:N("tw-ml-auto tw-text-xs tw-tracking-widest tw-opacity-60",e),...t})}ps.displayName="DropdownMenuShortcut";const Yl=g.forwardRef(({bookId:e,handleSelectBook:t,isSelected:n,handleHighlightBook:r,handleKeyDown:o,bookType:s,children:i},l)=>a.jsxs(co,{ref:l,textValue:e,className:N("tw-mx-1 tw-px-1 tw-font-normal tw-text-foreground/80",{"tw-bg-amber-50 tw-text-yellow-900 data-[highlighted]:tw-bg-amber-100":n}),onSelect:c=>{c.preventDefault(),t()},onKeyDown:c=>{o(c)},onFocus:r,onMouseMove:r,children:[a.jsx("span",{className:N("tw-border-b-0 tw-border-l-2 tw-border-r-0 tw-border-t-0 tw-border-solid tw-px-2",{"tw-font-bold":n,"tw-border-l-red-200":s.toLowerCase()==="ot","tw-border-l-purple-200":s.toLowerCase()==="nt","tw-border-l-indigo-200":s.toLowerCase()==="dc"}),children:ae.bookIdToEnglishName(e)}),n&&a.jsx("div",{children:i})]},e));function Wl({handleSelectChapter:e,endChapter:t,activeChapter:n,highlightedChapter:r,handleHighlightedChapter:o}){const s=Array.from({length:t},(l,c)=>c+1),i=g.useCallback(l=>{o(l)},[o]);return a.jsx("div",{className:N("tw-flex tw-flex-wrap tw-items-start tw-justify-start tw-self-stretch"),children:s.map(l=>a.jsx("div",{className:N("tw-box-content tw-flex tw-h-4 tw-w-4 tw-cursor-pointer tw-items-center tw-justify-end tw-rounded-md tw-p-2 tw-text-amber-800",{"tw-font-semibold tw-text-amber-900":l===n,"tw-bg-amber-200":l===r}),onClick:c=>{c.preventDefault(),c.stopPropagation(),e(l)},role:"button",onKeyDown:c=>{c.key==="Enter"&&e(l)},tabIndex:0,onMouseMove:()=>i(l),children:l},l))})}function Kl({handleSort:e,handleLocationHistory:t,handleBookmarks:n}){return a.jsxs(Wt,{className:"tw-flex tw-justify-between",children:[a.jsx("p",{className:"tw-inline-block tw-align-middle",children:"Go To"}),a.jsxs("div",{className:"tw-flex tw-items-center",children:[a.jsx(Q.ArrowDownWideNarrow,{onClick:e,className:"tw-m-2 tw-h-4 tw-w-4 tw-cursor-pointer tw-gap-2"}),a.jsx(Q.Clock,{onClick:t,className:"tw-m-2 tw-h-4 tw-w-4 tw-cursor-pointer tw-gap-2"}),a.jsx(Q.Bookmark,{onClick:n,className:"tw-m-2 tw-h-4 tw-w-4 tw-cursor-pointer tw-gap-2"})]})]})}const wn=ae.allBookIds,Jl={OT:"Old Testament",NT:"New Testament",DC:"Deuterocanon"},aa=["OT","NT","DC"],Zl=32+32+32,Ql=[/^(\w+)$/i,/^(\w+)(?:\s(\d+))$/i,/^(\w+)(?:\s(\d+):(\d+))$/i],ec=e=>({OT:wn.filter(n=>ae.isBookOT(n)),NT:wn.filter(n=>ae.isBookNT(n)),DC:wn.filter(n=>ae.isBookDC(n))})[e],rn=e=>W.getChaptersForBook(ae.bookIdToNumber(e));function tc(){return wn.map(t=>ae.bookIdToEnglishName(t))}function nc(e){return tc().includes(e)}function rc(e){const t=e.toLowerCase().replace(/^\w/,n=>n.toUpperCase());if(nc(t))return wn.find(r=>ae.bookIdToEnglishName(r)===t)}function oc({scrRef:e,handleSubmit:t}){const[n,r]=g.useState(""),[o,s]=g.useState(ae.bookNumberToId(e.bookNum)),[i,l]=g.useState(e.chapterNum??0),[c,u]=g.useState(ae.bookNumberToId(e.bookNum)),[d,m]=g.useState(!1),[w,b]=g.useState(d),x=g.useRef(void 0),f=g.useRef(void 0),h=g.useRef(void 0),S=g.useCallback(k=>ec(k).filter(D=>{const $=ae.bookIdToEnglishName(D).toLowerCase(),J=n.replace(/[^a-zA-Z]/g,"").toLowerCase();return $.includes(J)||D.toLowerCase().includes(J)}),[n]),R=k=>{r(k)},j=g.useRef(!1),E=g.useCallback(k=>{if(j.current){j.current=!1;return}m(k)},[]),v=g.useCallback((k,D,$,J)=>{if(l(ae.bookNumberToId(e.bookNum)!==k?1:e.chapterNum),D||rn(k)===-1){t({bookNum:ae.bookIdToNumber(k),chapterNum:$||1,verseNum:J||1}),m(!1),r("");return}s(o!==k?k:""),m(!D)},[t,e.bookNum,e.chapterNum,o]),P=k=>{k<=0||k>rn(o)||v(o,!0,k)},V=g.useCallback(()=>{Ql.forEach(k=>{const D=n.match(k);if(D){const[$,J=void 0,Y=void 0]=D.slice(1),F=rc($);(ae.isBookIdValid($)||F)&&v(F??$,!0,J?parseInt(J,10):1,Y?parseInt(Y,10):1)}})},[v,n]),U=g.useCallback(k=>{d?(k.key==="ArrowDown"||k.key==="ArrowUp")&&(typeof h<"u"&&h.current!==null?h.current.focus():typeof f<"u"&&f.current!==null&&f.current.focus(),k.preventDefault()):m(!0)},[d]),C=k=>{const{key:D}=k;D==="ArrowRight"||D==="ArrowLeft"||D==="ArrowDown"||D==="ArrowUp"||D==="Enter"||(x.current.dispatchEvent(new KeyboardEvent("keydown",{key:D})),x.current.focus())},_=k=>{const{key:D}=k;if(c===o){if(D==="Enter"){k.preventDefault(),v(o,!0,i);return}let $=0;if(D==="ArrowRight")if(i1)$=-1;else{k.preventDefault();return}else D==="ArrowDown"?$=6:D==="ArrowUp"&&($=-6);i+$<=0||i+$>rn(c)?l(0):$!==0&&(l(i+$),k.preventDefault())}};return g.useEffect(()=>{o===c?o===ae.bookNumberToId(e.bookNum)?l(e.chapterNum):l(1):l(0)},[c,e.bookNum,e.chapterNum,o]),g.useLayoutEffect(()=>{b(d)},[d]),g.useLayoutEffect(()=>{const k=setTimeout(()=>{if(w&&f.current&&h.current){const $=h.current.offsetTop-Zl;f.current.scrollTo({top:$,behavior:"instant"})}},10);return()=>{clearTimeout(k)}},[w]),a.jsx("div",{className:"pr-twp tw-flex",children:a.jsxs(or,{modal:!1,open:d,onOpenChange:E,children:[a.jsx(lo,{asChild:!0,children:a.jsx(Pl,{ref:x,value:n,handleSearch:R,handleKeyDown:U,handleOnClick:()=>{s(ae.bookNumberToId(e.bookNum)),u(ae.bookNumberToId(e.bookNum)),l(e.chapterNum>0?e.chapterNum:0),m(!0),x.current.focus()},onFocus:()=>{j.current=!0},handleSubmit:V,placeholder:`${ae.bookNumberToEnglishName(e.bookNum)} ${e.chapterNum}:${e.verseNum}`})}),a.jsxs(En,{className:"tw-m-1 tw-overflow-y-auto tw-p-0 tw-font-normal tw-text-foreground/80",style:{width:"233px",maxHeight:"500px",zIndex:"250"},onKeyDown:C,align:"start",ref:f,children:[a.jsx(Kl,{handleSort:()=>console.log("sorting"),handleLocationHistory:()=>console.log("location history"),handleBookmarks:()=>console.log("bookmarks")}),aa.map((k,D)=>S(k).length>0&&a.jsxs("div",{children:[a.jsx(Wt,{className:"tw-font-semibold tw-text-foreground/80",children:Jl[k]}),S(k).map($=>a.jsx("div",{children:a.jsx(Yl,{bookId:$,handleSelectBook:()=>v($,!1),isSelected:o===$,handleHighlightBook:()=>u($),handleKeyDown:_,bookType:k,ref:J=>{o===$&&(h.current=J)},children:a.jsx(Wl,{handleSelectChapter:P,endChapter:rn($),activeChapter:e.bookNum===ae.bookIdToNumber($)?e.chapterNum:0,highlightedChapter:i,handleHighlightedChapter:J=>{l(J)}})})},$)),aa.length-1!==D?a.jsx(jn,{}):void 0]},k))]})]})})}const ws=Xt.cva("pr-twp tw-inline-flex tw-items-center tw-justify-center tw-whitespace-nowrap tw-rounded-md tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-colors focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50",{variants:{variant:{default:"tw-bg-primary tw-text-primary-foreground hover:tw-bg-primary/90",destructive:"tw-bg-destructive tw-text-destructive-foreground hover:tw-bg-destructive/90",outline:"tw-border tw-border-input tw-bg-background hover:tw-bg-accent hover:tw-text-accent-foreground",secondary:"tw-bg-secondary tw-text-secondary-foreground hover:tw-bg-secondary/80",ghost:"hover:tw-bg-accent hover:tw-text-accent-foreground",link:"tw-text-primary tw-underline-offset-4 hover:tw-underline"},size:{default:"tw-h-10 tw-px-4 tw-py-2",sm:"tw-h-9 tw-rounded-md tw-px-3",lg:"tw-h-11 tw-rounded-md tw-px-8",icon:"tw-h-10 tw-w-10"}},defaultVariants:{variant:"default",size:"default"}}),fe=g.forwardRef(({className:e,variant:t,size:n,asChild:r=!1,...o},s)=>{const i=r?Ht.Slot:"button";return a.jsx(i,{className:N(ws({variant:t,size:n,className:e})),ref:s,...o})});fe.displayName="Button";const ac=Xt.cva("tw-text-sm tw-font-medium tw-leading-none peer-disabled:tw-cursor-not-allowed peer-disabled:tw-opacity-70"),qe=g.forwardRef(({className:e,...t},n)=>a.jsx(es.Root,{ref:n,className:N("pr-twp",ac(),e),...t}));qe.displayName=es.Root.displayName;const po=g.forwardRef(({className:e,...t},n)=>a.jsx(bn.Root,{className:N("pr-twp tw-grid tw-gap-2",e),...t,ref:n}));po.displayName=bn.Root.displayName;const Yn=g.forwardRef(({className:e,...t},n)=>a.jsx(bn.Item,{ref:n,className:N("pr-twp tw-aspect-square tw-h-4 tw-w-4 tw-rounded-full tw-border tw-border-primary tw-text-primary tw-ring-offset-background focus:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-cursor-not-allowed disabled:tw-opacity-50",e),...t,children:a.jsx(bn.Indicator,{className:"tw-flex tw-items-center tw-justify-center",children:a.jsx(Q.Circle,{className:"tw-h-2.5 tw-w-2.5 tw-fill-current tw-text-current"})})}));Yn.displayName=bn.Item.displayName;const sc=vn.Root,ic=vn.Trigger,fs=g.forwardRef(({className:e,align:t="center",sideOffset:n=4,...r},o)=>a.jsx(vn.Portal,{children:a.jsx(vn.Content,{ref:o,align:t,sideOffset:n,className:N("pr-twp tw-z-50 tw-w-72 tw-rounded-md tw-border tw-bg-popover tw-p-4 tw-text-popover-foreground tw-shadow-md tw-outline-none data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0 data-[state=closed]:tw-zoom-out-95 data-[state=open]:tw-zoom-in-95 data-[side=bottom]:tw-slide-in-from-top-2 data-[side=left]:tw-slide-in-from-right-2 data-[side=right]:tw-slide-in-from-left-2 data-[side=top]:tw-slide-in-from-bottom-2",e),...r})}));fs.displayName=vn.Content.displayName;const lc=be.Portal,ms=g.forwardRef(({className:e,...t},n)=>a.jsx(be.Overlay,{ref:n,className:N("tw-fixed tw-inset-0 tw-z-50 tw-bg-black/80 data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0",e),...t}));ms.displayName=be.Overlay.displayName;const cc=g.forwardRef(({className:e,children:t,...n},r)=>a.jsxs(lc,{children:[a.jsx(ms,{}),a.jsxs(be.Content,{ref:r,className:N("tw-fixed tw-left-[50%] tw-top-[50%] tw-z-50 tw-grid tw-w-full tw-max-w-lg tw-translate-x-[-50%] tw-translate-y-[-50%] tw-gap-4 tw-border tw-bg-background tw-p-6 tw-shadow-lg tw-duration-200 data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0 data-[state=closed]:tw-zoom-out-95 data-[state=open]:tw-zoom-in-95 data-[state=closed]:tw-slide-out-to-left-1/2 data-[state=closed]:tw-slide-out-to-top-[48%] data-[state=open]:tw-slide-in-from-left-1/2 data-[state=open]:tw-slide-in-from-top-[48%] sm:tw-rounded-lg",e),...n,children:[t,a.jsxs(be.Close,{className:"tw-absolute tw-right-4 tw-top-4 tw-rounded-sm tw-opacity-70 tw-ring-offset-background tw-transition-opacity hover:tw-opacity-100 focus:tw-outline-none focus:tw-ring-2 focus:tw-ring-ring focus:tw-ring-offset-2 disabled:tw-pointer-events-none data-[state=open]:tw-bg-accent data-[state=open]:tw-text-muted-foreground",children:[a.jsx(Q.X,{className:"tw-h-4 tw-w-4"}),a.jsx("span",{className:"tw-sr-only",children:"Close"})]})]})]}));cc.displayName=be.Content.displayName;const dc=g.forwardRef(({className:e,...t},n)=>a.jsx(be.Title,{ref:n,className:N("tw-text-lg tw-font-semibold tw-leading-none tw-tracking-tight",e),...t}));dc.displayName=be.Title.displayName;const uc=g.forwardRef(({className:e,...t},n)=>a.jsx(be.Description,{ref:n,className:N("tw-text-sm tw-text-muted-foreground",e),...t}));uc.displayName=be.Description.displayName;const hs=g.forwardRef(({className:e,...t},n)=>a.jsx(Re.Command,{ref:n,className:N("tw-flex tw-h-full tw-w-full tw-flex-col tw-overflow-hidden tw-rounded-md tw-bg-popover tw-text-popover-foreground",e),...t}));hs.displayName=Re.Command.displayName;const gs=g.forwardRef(({className:e,...t},n)=>a.jsxs("div",{className:"tw-flex tw-items-center tw-border-b tw-px-3",children:[a.jsx(Q.Search,{className:"tw-me-2 tw-h-4 tw-w-4 tw-shrink-0 tw-opacity-50"}),a.jsx(Re.Command.Input,{ref:n,className:N("tw-flex tw-h-11 tw-w-full tw-rounded-md tw-bg-transparent tw-py-3 tw-text-sm tw-outline-none placeholder:tw-text-muted-foreground disabled:tw-cursor-not-allowed disabled:tw-opacity-50",e),...t})]}));gs.displayName=Re.Command.Input.displayName;const bs=g.forwardRef(({className:e,...t},n)=>a.jsx(Re.Command.List,{ref:n,className:N("tw-max-h-[300px] tw-overflow-y-auto tw-overflow-x-hidden",e),...t}));bs.displayName=Re.Command.List.displayName;const vs=g.forwardRef((e,t)=>a.jsx(Re.Command.Empty,{ref:t,className:"tw-py-6 tw-text-center tw-text-sm",...e}));vs.displayName=Re.Command.Empty.displayName;const pc=g.forwardRef(({className:e,...t},n)=>a.jsx(Re.Command.Group,{ref:n,className:N("tw-overflow-hidden tw-p-1 tw-text-foreground [&_[cmdk-group-heading]]:tw-px-2 [&_[cmdk-group-heading]]:tw-py-1.5 [&_[cmdk-group-heading]]:tw-text-xs [&_[cmdk-group-heading]]:tw-font-medium [&_[cmdk-group-heading]]:tw-text-muted-foreground",e),...t}));pc.displayName=Re.Command.Group.displayName;const wc=g.forwardRef(({className:e,...t},n)=>a.jsx(Re.Command.Separator,{ref:n,className:N("tw--mx-1 tw-h-px tw-bg-border",e),...t}));wc.displayName=Re.Command.Separator.displayName;const xs=g.forwardRef(({className:e,...t},n)=>a.jsx(Re.Command.Item,{ref:n,className:N("tw-relative tw-flex tw-cursor-default tw-select-none tw-items-center tw-rounded-sm tw-px-2 tw-py-1.5 tw-text-sm tw-outline-none data-[disabled=true]:tw-pointer-events-none data-[selected=true]:tw-bg-accent data-[selected=true]:tw-text-accent-foreground data-[disabled=true]:tw-opacity-50",e),...t}));xs.displayName=Re.Command.Item.displayName;function fc(e){return typeof e=="string"?e:typeof e=="number"?e.toString():e.label}function Wn({id:e,options:t=[],buttonClassName:n,popoverContentClassName:r,value:o,onChange:s=()=>{},getOptionLabel:i=fc,buttonPlaceholder:l="",textPlaceholder:c="",commandEmptyMessage:u="No option found",buttonVariant:d="outline",dir:m="ltr",isDisabled:w=!1,...b}){const[x,f]=g.useState(!1);return a.jsxs(sc,{open:x,onOpenChange:f,...b,children:[a.jsx(ic,{asChild:!0,children:a.jsxs(fe,{variant:d,role:"combobox","aria-expanded":x,id:e,className:N("tw-w-[200px] tw-justify-between",n),disabled:w,children:[a.jsx("span",{className:"tw-overflow-hidden tw-text-ellipsis tw-whitespace-nowrap",children:o?i(o):l}),a.jsx(Q.ChevronsUpDown,{className:"tw-ms-2 tw-h-4 tw-w-4 tw-shrink-0 tw-opacity-50"})]})}),a.jsx(fs,{className:N("tw-w-[200px] tw-p-0",r),dir:m,children:a.jsxs(hs,{children:[a.jsx(gs,{dir:m,placeholder:c,className:"tw-text-inherit"}),a.jsx(vs,{children:u}),a.jsx(bs,{children:t.map(h=>a.jsxs(xs,{value:i(h),onSelect:()=>{s(h),f(!1)},children:[a.jsx(Q.Check,{className:N("tw-me-2 tw-h-4 tw-w-4",{"tw-opacity-0":!o||i(o)!==i(h)})}),i(h)]},i(h)))})]})})]})}function ys({startChapter:e,endChapter:t,handleSelectStartChapter:n,handleSelectEndChapter:r,isDisabled:o=!1,chapterCount:s}){const i=g.useMemo(()=>Array.from({length:s},(u,d)=>d+1),[s]),l=u=>{n(u),u>t&&r(u)},c=u=>{r(u),uu.toString(),value:e},"start chapter"),a.jsx(qe,{htmlFor:"end-chapters-combobox",children:"to"}),a.jsx(Wn,{isDisabled:o,onChange:c,buttonClassName:"tw-ml-2 tw-w-20",options:i,getOptionLabel:u=>u.toString(),value:t},"end chapter")]})}var Ns=(e=>(e.CURRENT_BOOK="current book",e.CHOOSE_BOOKS="choose books",e))(Ns||{});const mc=Object.freeze(["%webView_bookSelector_currentBook%","%webView_bookSelector_choose%","%webView_bookSelector_chooseBooks%"]),Tr=(e,t)=>e[t]??t;function hc({handleBookSelectionModeChange:e,currentBookName:t,onSelectBooks:n,selectedBookIds:r,chapterCount:o,endChapter:s,handleSelectEndChapter:i,startChapter:l,handleSelectStartChapter:c,localizedStrings:u}){const d=Tr(u,"%webView_bookSelector_currentBook%"),m=Tr(u,"%webView_bookSelector_choose%"),w=Tr(u,"%webView_bookSelector_chooseBooks%"),[b,x]=g.useState("current book"),f=h=>{x(h),e(h)};return a.jsx(po,{className:"pr-twp tw-flex",value:b,onValueChange:h=>f(h),children:a.jsxs("div",{className:"tw-flex tw-w-full tw-flex-col tw-gap-4",children:[a.jsxs("div",{className:"tw-grid tw-grid-cols-[25%,25%,50%]",children:[a.jsxs("div",{className:"tw-flex tw-items-center",children:[a.jsx(Yn,{value:"current book"}),a.jsx(qe,{className:"tw-ml-1",children:d})]}),a.jsx(qe,{className:"tw-flex tw-items-center",children:t}),a.jsx("div",{className:"tw-flex tw-items-center tw-justify-end",children:a.jsx(ys,{isDisabled:b==="choose books",handleSelectStartChapter:c,handleSelectEndChapter:i,chapterCount:o,startChapter:l,endChapter:s})})]}),a.jsxs("div",{className:"tw-grid tw-grid-cols-[25%,50%,25%]",children:[a.jsxs("div",{className:"tw-flex tw-items-center",children:[a.jsx(Yn,{value:"choose books"}),a.jsx(qe,{className:"tw-ml-1",children:w})]}),a.jsx(qe,{className:"tw-flex tw-items-center",children:r.map(h=>ae.bookIdToEnglishName(h)).join(", ")}),a.jsx(fe,{disabled:b==="current book",onClick:()=>n(),children:m})]})]})})}function gc({table:e}){return a.jsxs(or,{children:[a.jsx(Za.DropdownMenuTrigger,{asChild:!0,children:a.jsxs(fe,{variant:"outline",size:"sm",className:"tw-ml-auto tw-hidden tw-h-8 lg:tw-flex",children:[a.jsx(Q.FilterIcon,{className:"tw-mr-2 tw-h-4 tw-w-4"}),"View"]})}),a.jsxs(En,{align:"end",className:"tw-w-[150px]",children:[a.jsx(Wt,{children:"Toggle columns"}),a.jsx(jn,{}),e.getAllColumns().filter(t=>t.getCanHide()).map(t=>a.jsx(ar,{className:"tw-capitalize",checked:t.getIsVisible(),onCheckedChange:n=>t.toggleVisibility(!!n),children:t.id},t.id))]})]})}const At=ge.Root,ks=ge.Group,Bt=ge.Value,bt=g.forwardRef(({className:e,children:t,...n},r)=>a.jsxs(ge.Trigger,{ref:r,className:N("tw-flex tw-h-10 tw-w-full tw-items-center tw-justify-between tw-rounded-md tw-border tw-border-input tw-bg-background tw-px-3 tw-py-2 tw-text-sm tw-ring-offset-background placeholder:tw-text-muted-foreground focus:tw-outline-none focus:tw-ring-2 focus:tw-ring-ring focus:tw-ring-offset-2 disabled:tw-cursor-not-allowed disabled:tw-opacity-50 [&>span]:tw-line-clamp-1",e),...n,children:[t,a.jsx(ge.Icon,{asChild:!0,children:a.jsx(Q.ChevronDown,{className:"tw-h-4 tw-w-4 tw-opacity-50"})})]}));bt.displayName=ge.Trigger.displayName;const wo=g.forwardRef(({className:e,...t},n)=>a.jsx(ge.ScrollUpButton,{ref:n,className:N("tw-flex tw-cursor-default tw-items-center tw-justify-center tw-py-1",e),...t,children:a.jsx(Q.ChevronUp,{className:"tw-h-4 tw-w-4"})}));wo.displayName=ge.ScrollUpButton.displayName;const fo=g.forwardRef(({className:e,...t},n)=>a.jsx(ge.ScrollDownButton,{ref:n,className:N("tw-flex tw-cursor-default tw-items-center tw-justify-center tw-py-1",e),...t,children:a.jsx(Q.ChevronDown,{className:"tw-h-4 tw-w-4"})}));fo.displayName=ge.ScrollDownButton.displayName;const vt=g.forwardRef(({className:e,children:t,position:n="popper",...r},o)=>a.jsx(ge.Portal,{children:a.jsxs(ge.Content,{ref:o,className:N("pr-twp tw-relative tw-z-50 tw-max-h-96 tw-min-w-[8rem] tw-overflow-hidden tw-rounded-md tw-border tw-bg-popover tw-text-popover-foreground tw-shadow-md data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0 data-[state=closed]:tw-zoom-out-95 data-[state=open]:tw-zoom-in-95 data-[side=bottom]:tw-slide-in-from-top-2 data-[side=left]:tw-slide-in-from-right-2 data-[side=right]:tw-slide-in-from-left-2 data-[side=top]:tw-slide-in-from-bottom-2",n==="popper"&&"data-[side=bottom]:tw-translate-y-1 data-[side=left]:tw--translate-x-1 data-[side=right]:tw-translate-x-1 data-[side=top]:tw--translate-y-1",e),position:n,...r,children:[a.jsx(wo,{}),a.jsx(ge.Viewport,{className:N("tw-p-1",n==="popper"&&"tw-h-[var(--radix-select-trigger-height)] tw-w-full tw-min-w-[var(--radix-select-trigger-width)]"),children:t}),a.jsx(fo,{})]})}));vt.displayName=ge.Content.displayName;const Ss=g.forwardRef(({className:e,...t},n)=>a.jsx(ge.Label,{ref:n,className:N("tw-py-1.5 tw-pl-8 tw-pr-2 tw-text-sm tw-font-semibold",e),...t}));Ss.displayName=ge.Label.displayName;const Ae=g.forwardRef(({className:e,children:t,...n},r)=>a.jsxs(ge.Item,{ref:r,className:N("tw-relative tw-flex tw-w-full tw-cursor-default tw-select-none tw-items-center tw-rounded-sm tw-py-1.5 tw-pl-8 tw-pr-2 tw-text-sm tw-outline-none focus:tw-bg-accent focus:tw-text-accent-foreground data-[disabled]:tw-pointer-events-none data-[disabled]:tw-opacity-50",e),...n,children:[a.jsx("span",{className:"tw-absolute tw-left-2 tw-flex tw-h-3.5 tw-w-3.5 tw-items-center tw-justify-center",children:a.jsx(ge.ItemIndicator,{children:a.jsx(Q.Check,{className:"tw-h-4 tw-w-4"})})}),a.jsx(ge.ItemText,{children:t})]}));Ae.displayName=ge.Item.displayName;const Es=g.forwardRef(({className:e,...t},n)=>a.jsx(ge.Separator,{ref:n,className:N("tw--mx-1 tw-my-1 tw-h-px tw-bg-muted",e),...t}));Es.displayName=ge.Separator.displayName;function bc({table:e}){return a.jsx("div",{className:"tw-flex tw-items-center tw-justify-between tw-px-2 tw-pb-3 tw-pt-3",children:a.jsxs("div",{className:"tw-flex tw-items-center tw-space-x-6 lg:tw-space-x-8",children:[a.jsxs("div",{className:"tw-flex-1 tw-text-sm tw-text-muted-foreground",children:[e.getFilteredSelectedRowModel().rows.length," of"," ",e.getFilteredRowModel().rows.length," row(s) selected"]}),a.jsxs("div",{className:"tw-flex tw-items-center tw-space-x-2",children:[a.jsx("p",{className:"tw-text-nowrap tw-text-sm tw-font-medium",children:"Rows per page"}),a.jsxs(At,{value:`${e.getState().pagination.pageSize}`,onValueChange:t=>{e.setPageSize(Number(t))},children:[a.jsx(bt,{className:"tw-h-8 tw-w-[70px]",children:a.jsx(Bt,{placeholder:e.getState().pagination.pageSize})}),a.jsx(vt,{side:"top",children:[10,20,30,40,50].map(t=>a.jsx(Ae,{value:`${t}`,children:t},t))})]})]}),a.jsxs("div",{className:"tw-flex tw-w-[100px] tw-items-center tw-justify-center tw-text-sm tw-font-medium",children:["Page ",e.getState().pagination.pageIndex+1," of ",e.getPageCount()]}),a.jsxs("div",{className:"tw-flex tw-items-center tw-space-x-2",children:[a.jsxs(fe,{variant:"outline",size:"icon",className:"tw-hidden tw-h-8 tw-w-8 tw-p-0 lg:tw-flex",onClick:()=>e.setPageIndex(0),disabled:!e.getCanPreviousPage(),children:[a.jsx("span",{className:"tw-sr-only",children:"Go to first page"}),a.jsx(Q.ArrowLeftIcon,{className:"tw-h-4 tw-w-4"})]}),a.jsxs(fe,{variant:"outline",size:"icon",className:"tw-h-8 tw-w-8 tw-p-0",onClick:()=>e.previousPage(),disabled:!e.getCanPreviousPage(),children:[a.jsx("span",{className:"tw-sr-only",children:"Go to previous page"}),a.jsx(Q.ChevronLeftIcon,{className:"tw-h-4 tw-w-4"})]}),a.jsxs(fe,{variant:"outline",size:"icon",className:"tw-h-8 tw-w-8 tw-p-0",onClick:()=>e.nextPage(),disabled:!e.getCanNextPage(),children:[a.jsx("span",{className:"tw-sr-only",children:"Go to next page"}),a.jsx(Q.ChevronRightIcon,{className:"tw-h-4 tw-w-4"})]}),a.jsxs(fe,{variant:"outline",size:"icon",className:"tw-hidden tw-h-8 tw-w-8 tw-p-0 lg:tw-flex",onClick:()=>e.setPageIndex(e.getPageCount()-1),disabled:!e.getCanNextPage(),children:[a.jsx("span",{className:"tw-sr-only",children:"Go to last page"}),a.jsx(Q.ArrowRightIcon,{className:"tw-h-4 tw-w-4"})]})]})]})})}const Cn=g.forwardRef(({className:e,stickyHeader:t,...n},r)=>a.jsx("div",{className:N("pr-twp tw-relative tw-w-full",{"tw-overflow-auto":!t}),children:a.jsx("table",{ref:r,className:N("tw-w-full tw-caption-bottom tw-text-sm",e),...n})}));Cn.displayName="Table";const Tn=g.forwardRef(({className:e,stickyHeader:t,...n},r)=>a.jsx("thead",{ref:r,className:N({"tw-sticky tw-top-[-1px] tw-bg-background tw-drop-shadow-sm":t},"[&_tr]:tw-border-b",e),...n}));Tn.displayName="TableHeader";const Rn=g.forwardRef(({className:e,...t},n)=>a.jsx("tbody",{ref:n,className:N("[&_tr:last-child]:tw-border-0",e),...t}));Rn.displayName="TableBody";const js=g.forwardRef(({className:e,...t},n)=>a.jsx("tfoot",{ref:n,className:N("tw-border-t tw-bg-muted/50 tw-font-medium [&>tr]:last:tw-border-b-0",e),...t}));js.displayName="TableFooter";const Ze=g.forwardRef(({className:e,...t},n)=>a.jsx("tr",{ref:n,className:N("tw-border-b tw-transition-colors hover:tw-bg-muted/50 data-[state=selected]:tw-bg-muted",e),...t}));Ze.displayName="TableRow";const Vt=g.forwardRef(({className:e,...t},n)=>a.jsx("th",{ref:n,className:N("tw-h-12 tw-px-4 tw-text-start tw-align-middle tw-font-medium tw-text-muted-foreground [&:has([role=checkbox])]:tw-pe-0",e),...t}));Vt.displayName="TableHead";const xt=g.forwardRef(({className:e,...t},n)=>a.jsx("td",{ref:n,className:N("tw-p-4 tw-align-middle [&:has([role=checkbox])]:tw-pe-0",e),...t}));xt.displayName="TableCell";const Cs=g.forwardRef(({className:e,...t},n)=>a.jsx("caption",{ref:n,className:N("tw-mt-4 tw-text-sm tw-text-muted-foreground",e),...t}));Cs.displayName="TableCaption";function Ts({columns:e,data:t,enablePagination:n=!1,showPaginationControls:r=!1,showColumnVisibilityControls:o=!1,stickyHeader:s=!1,onRowClickHandler:i=()=>{}}){var h;const[l,c]=g.useState([]),[u,d]=g.useState([]),[m,w]=g.useState({}),[b,x]=g.useState({}),f=Se.useReactTable({data:t,columns:e,getCoreRowModel:Se.getCoreRowModel(),...n&&{getPaginationRowModel:Se.getPaginationRowModel()},onSortingChange:c,getSortedRowModel:Se.getSortedRowModel(),onColumnFiltersChange:d,getFilteredRowModel:Se.getFilteredRowModel(),onColumnVisibilityChange:w,onRowSelectionChange:x,state:{sorting:l,columnFilters:u,columnVisibility:m,rowSelection:b}});return a.jsxs("div",{className:"pr-twp",children:[o&&a.jsx(gc,{table:f}),a.jsxs(Cn,{stickyHeader:s,children:[a.jsx(Tn,{stickyHeader:s,children:f.getHeaderGroups().map(S=>a.jsx(Ze,{children:S.headers.map(R=>a.jsx(Vt,{children:R.isPlaceholder?void 0:Se.flexRender(R.column.columnDef.header,R.getContext())},R.id))},S.id))}),a.jsx(Rn,{children:(h=f.getRowModel().rows)!=null&&h.length?f.getRowModel().rows.map(S=>a.jsx(Ze,{onClick:()=>i(S,f),"data-state":S.getIsSelected()&&"selected",children:S.getVisibleCells().map(R=>a.jsx(xt,{children:Se.flexRender(R.column.columnDef.cell,R.getContext())},R.id))},S.id)):a.jsx(Ze,{children:a.jsx(xt,{colSpan:e.length,className:"tw-h-24 tw-text-center",children:"No results."})})})]}),n&&a.jsxs("div",{className:"tw-flex tw-items-center tw-justify-end tw-space-x-2 tw-py-4",children:[a.jsx(fe,{variant:"outline",size:"sm",onClick:()=>f.previousPage(),disabled:!f.getCanPreviousPage(),children:"Previous"}),a.jsx(fe,{variant:"outline",size:"sm",onClick:()=>f.nextPage(),disabled:!f.getCanNextPage(),children:"Next"})]}),n&&r&&a.jsx(bc,{table:f})]})}function vc({occurrenceData:e,setScriptureReference:t,localizedStrings:n}){const r=n["%webView_inventory_occurrences_table_header_reference%"],o=n["%webView_inventory_occurrences_table_header_occurrence%"],s=g.useMemo(()=>{const i=[];return e.forEach(l=>{i.some(c=>W.deepEqual(c,l))||i.push(l)}),i},[e]);return a.jsxs(Cn,{stickyHeader:!0,children:[a.jsx(Tn,{stickyHeader:!0,children:a.jsxs(Ze,{children:[a.jsx(Vt,{children:r}),a.jsx(Vt,{children:o})]})}),a.jsx(Rn,{children:s.length>0&&s.map(i=>a.jsxs(Ze,{onClick:()=>{t(i.reference)},children:[a.jsx(xt,{children:`${ae.bookNumberToEnglishName(i.reference.bookNum)} ${i.reference.chapterNum}:${i.reference.verseNum}`}),a.jsx(xt,{children:i.text})]},`${i.reference.bookNum} ${i.reference.chapterNum}:${i.reference.verseNum}-${i.text}`))})]})}const sr=g.forwardRef(({className:e,...t},n)=>a.jsx(Ur.Root,{ref:n,className:N("tw-peer pr-twp tw-h-4 tw-w-4 tw-shrink-0 tw-rounded-sm tw-border tw-border-primary tw-ring-offset-background focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-cursor-not-allowed disabled:tw-opacity-50 data-[state=checked]:tw-bg-primary data-[state=checked]:tw-text-primary-foreground",e),...t,children:a.jsx(Ur.Indicator,{className:N("tw-flex tw-items-center tw-justify-center tw-text-current"),children:a.jsx(Q.Check,{className:"tw-h-4 tw-w-4"})})}));sr.displayName=Ur.Root.displayName;const Rs=e=>e.split(/(?:\r?\n|\r)|(?=(?:\\(?:v|c|id)))/g),Hr=e=>{const t=/^\\[vc]\s+(\d+)/,n=e.match(t);if(n)return+n[1]},Os=e=>{const t=e.match(/^\\id\s+([A-Za-z]+)/);return t?ae.bookIdToNumber(t[1]):0},_s=(e,t,n)=>n.includes(e)?"unapproved":t.includes(e)?"approved":"unknown",Ps=Xt.cva("pr-twp tw-inline-flex tw-items-center tw-justify-center tw-rounded-md tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-colors hover:tw-bg-muted hover:tw-text-muted-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50 data-[state=on]:tw-bg-accent data-[state=on]:tw-text-accent-foreground",{variants:{variant:{default:"tw-bg-transparent",outline:"tw-border tw-border-input tw-bg-transparent hover:tw-bg-accent hover:tw-text-accent-foreground"},size:{default:"tw-h-10 tw-px-3",sm:"tw-h-9 tw-px-2.5",lg:"tw-h-11 tw-px-5"}},defaultVariants:{variant:"default",size:"default"}}),xc=g.forwardRef(({className:e,variant:t,size:n,...r},o)=>a.jsx(ts.Root,{ref:o,className:N(Ps({variant:t,size:n,className:e})),...r}));xc.displayName=ts.Root.displayName;const Is=g.createContext({size:"default",variant:"default"}),mo=g.forwardRef(({className:e,variant:t,size:n,children:r,...o},s)=>a.jsx(rr.Root,{ref:s,className:N("pr-twp tw-flex tw-items-center tw-justify-center tw-gap-1",e),...o,children:a.jsx(Is.Provider,{value:{variant:t,size:n},children:r})}));mo.displayName=rr.Root.displayName;const fn=g.forwardRef(({className:e,children:t,variant:n,size:r,...o},s)=>{const i=g.useContext(Is);return a.jsx(rr.Item,{ref:s,className:N(Ps({variant:i.variant||n,size:i.size||r}),e),...o,children:t})});fn.displayName=rr.Item.displayName;const ir=e=>e==="asc"?a.jsx(Q.ArrowUpIcon,{className:"tw-ms-2 tw-h-4 tw-w-4"}):e==="desc"?a.jsx(Q.ArrowDownIcon,{className:"tw-ms-2 tw-h-4 tw-w-4"}):a.jsx(Q.ArrowUpDownIcon,{className:"tw-ms-2 tw-h-4 tw-w-4"}),yc=e=>({accessorKey:"item",accessorFn:t=>t.items[0],header:({column:t})=>a.jsxs(fe,{variant:"ghost",onClick:()=>t.toggleSorting(void 0),children:[e,ir(t.getIsSorted())]})}),Nc=(e,t)=>({accessorKey:`item${t}`,accessorFn:n=>n.items[t],header:({column:n})=>a.jsxs(fe,{variant:"ghost",onClick:()=>n.toggleSorting(void 0),children:[e,ir(n.getIsSorted())]})}),kc=e=>({accessorKey:"count",header:({column:t})=>a.jsx("div",{className:"tw-flex tw-justify-end tw-tabular-nums",children:a.jsxs(fe,{variant:"ghost",onClick:()=>t.toggleSorting(void 0),children:[e,ir(t.getIsSorted())]})}),cell:({row:t})=>a.jsx("div",{className:"tw-flex tw-justify-end",children:t.getValue("count")})}),Rr=(e,t,n,r,o,s)=>{let i=[...n];e.forEach(c=>{t==="approved"?i.includes(c)||i.push(c):i=i.filter(u=>u!==c)}),r(i);let l=[...o];e.forEach(c=>{t==="unapproved"?l.includes(c)||l.push(c):l=l.filter(u=>u!==c)}),s(l)},Sc=(e,t,n,r,o)=>({accessorKey:"status",header:({column:s})=>a.jsx("div",{className:"tw-flex tw-justify-center",children:a.jsxs(fe,{variant:"ghost",onClick:()=>s.toggleSorting(void 0),children:[e,ir(s.getIsSorted())]})}),cell:({row:s})=>{const i=s.getValue("status"),l=s.getValue("item");return a.jsxs(mo,{value:i,variant:"outline",type:"single",children:[a.jsx(fn,{onClick:()=>Rr([l],"approved",t,n,r,o),value:"approved",children:a.jsx(Q.CircleCheckIcon,{})}),a.jsx(fn,{onClick:()=>Rr([l],"unapproved",t,n,r,o),value:"unapproved",children:a.jsx(Q.CircleXIcon,{})}),a.jsx(fn,{onClick:()=>Rr([l],"unknown",t,n,r,o),value:"unknown",children:a.jsx(Q.CircleHelpIcon,{})})]})}}),Ec=Object.freeze(["%webView_inventory_all%","%webView_inventory_approved%","%webView_inventory_unapproved%","%webView_inventory_unknown%","%webView_inventory_scope_currentBook%","%webView_inventory_scope_chapter%","%webView_inventory_scope_verse%","%webView_inventory_filter_text%","%webView_inventory_show_additional_items%","%webView_inventory_occurrences_table_header_reference%","%webView_inventory_occurrences_table_header_occurrence%"]),jc=(e,t,n)=>{let r=e;return t!=="all"&&(r=r.filter(o=>t==="approved"&&o.status==="approved"||t==="unapproved"&&o.status==="unapproved"||t==="unknown"&&o.status==="unknown")),n!==""&&(r=r.filter(o=>o.items[0].includes(n))),r},Cc=(e,t,n,r,o)=>{if(!e)return[];const s=[];let i=t.bookNum,l=t.chapterNum,c=t.verseNum;return Rs(e).forEach(d=>{d.startsWith("\\id")&&(i=Os(d),l=0,c=0),d.startsWith("\\c")&&(l=Hr(d),c=0),d.startsWith("\\v")&&(c=Hr(d),l===0&&(l=t.chapterNum));let m=o.exec(d)??void 0;for(;m;){const w=[];m.forEach(h=>w.push(h));const b=m.index,x=s.find(h=>W.deepEqual(h.items,w)),f={reference:{bookNum:i!==void 0?i:-1,chapterNum:l!==void 0?l:-1,verseNum:c!==void 0?c:-1},text:W.substring(d,Math.max(0,b-25),Math.min(b+25,d.length))};if(x)x.count+=1,x.occurrences.push(f);else{const h={items:w,count:1,status:_s(w[0],n,r),occurrences:[f]};s.push(h)}m=o.exec(d)??void 0}}),s},Je=(e,t)=>e[t]??t;function Tc({scriptureReference:e,setScriptureReference:t,localizedStrings:n,extractItems:r,additionalItemsLabels:o,approvedItems:s,unapprovedItems:i,text:l,scope:c,onScopeChange:u,columns:d}){const m=Je(n,"%webView_inventory_all%"),w=Je(n,"%webView_inventory_approved%"),b=Je(n,"%webView_inventory_unapproved%"),x=Je(n,"%webView_inventory_unknown%"),f=Je(n,"%webView_inventory_scope_currentBook%"),h=Je(n,"%webView_inventory_scope_chapter%"),S=Je(n,"%webView_inventory_scope_verse%"),R=Je(n,"%webView_inventory_filter_text%"),j=Je(n,"%webView_inventory_show_additional_items%"),[E,v]=g.useState(!1),[P,V]=g.useState("all"),[U,C]=g.useState(""),[_,k]=g.useState([]),D=g.useMemo(()=>l?r instanceof RegExp?Cc(l,e,s,i,r):r(l,e,s,i):[],[l,r,e,s,i]),$=g.useMemo(()=>{if(E)return D;const y=[];return D.forEach(T=>{const z=T.items[0],L=y.find(B=>B.items[0]===z);L?(L.count+=T.count,L.occurrences=L.occurrences.concat(T.occurrences)):y.push({items:[z],count:T.count,occurrences:T.occurrences,status:T.status})}),y},[E,D]),J=g.useMemo(()=>jc($,P,U),[$,P,U]),Y=g.useMemo(()=>{var z,L;if(!E)return d;const y=(z=o==null?void 0:o.tableHeaders)==null?void 0:z.length;if(!y)return d;const T=[];for(let B=0;B{k([])},[J]);const F=(y,T)=>{T.setRowSelection(()=>{const z={};return z[y.index]=!0,z}),k(y.original.items)},te=y=>{if(y==="book"||y==="chapter"||y==="verse")u(y);else throw new Error(`Invalid scope value: ${y}`)},se=y=>{if(y==="all"||y==="approved"||y==="unapproved"||y==="unknown")V(y);else throw new Error(`Invalid status filter value: ${y}`)},oe=g.useMemo(()=>{if($.length===0||_.length===0)return[];const y=$.filter(T=>W.deepEqual(E?T.items:[T.items[0]],_));if(y.length>1)throw new Error("Selected item is not unique");return y[0].occurrences},[_,E,$]);return a.jsxs("div",{className:"pr-twp tw-flex tw-h-full tw-flex-col",children:[a.jsxs("div",{className:"tw-flex tw-items-stretch",children:[a.jsxs(At,{onValueChange:y=>se(y),defaultValue:P,children:[a.jsx(bt,{className:"tw-m-1",children:a.jsx(Bt,{placeholder:"Select filter"})}),a.jsxs(vt,{children:[a.jsx(Ae,{value:"all",children:m}),a.jsx(Ae,{value:"approved",children:w}),a.jsx(Ae,{value:"unapproved",children:b}),a.jsx(Ae,{value:"unknown",children:x})]})]}),a.jsxs(At,{onValueChange:y=>te(y),defaultValue:c,children:[a.jsx(bt,{className:"tw-m-1",children:a.jsx(Bt,{placeholder:"Select scope"})}),a.jsxs(vt,{children:[a.jsx(Ae,{value:"book",children:f}),a.jsx(Ae,{value:"chapter",children:h}),a.jsx(Ae,{value:"verse",children:S})]})]}),a.jsx(St,{className:"tw-m-1 tw-rounded-md tw-border",placeholder:R,value:U,onChange:y=>{C(y.target.value)}}),o&&a.jsxs("div",{className:"tw-m-1 tw-flex tw-items-center tw-rounded-md tw-border",children:[a.jsx(sr,{className:"tw-m-1",checked:E,onCheckedChange:y=>{k([]),v(y)}}),a.jsx(qe,{className:"tw-m-1 tw-flex-shrink-0 tw-whitespace-nowrap",children:(o==null?void 0:o.checkboxText)??j})]})]}),a.jsx("div",{className:"tw-m-1 tw-flex-1 tw-overflow-auto tw-rounded-md tw-border",children:a.jsx(Ts,{columns:Y,data:J,onRowClickHandler:F,stickyHeader:!0})}),oe.length>0&&a.jsx("div",{className:"tw-m-1 tw-flex-1 tw-overflow-auto tw-rounded-md tw-border",children:a.jsx(vc,{occurrenceData:oe,setScriptureReference:t,localizedStrings:n})})]})}function ho({className:e,onSearch:t,placeholder:n,isFullWidth:r}){const[o,s]=g.useState(""),i=l=>{s(l),t(l)};return a.jsx(St,{className:N("tw-flex tw-h-10 tw-rounded-md tw-border tw-border-input tw-bg-background tw-px-3 tw-py-2 tw-text-sm tw-ring-offset-background file:tw-border-0 file:tw-bg-transparent file:tw-text-sm file:tw-font-medium placeholder:tw-text-muted-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-[color:hsl(240,5%,64.9%)] focus-visible:tw-ring-offset-2 disabled:tw-cursor-not-allowed disabled:tw-opacity-50",{"tw-w-full":r},e),placeholder:n,value:o,onChange:l=>i(l.target.value)})}const go=g.forwardRef(({className:e,...t},n)=>a.jsx(Oe.Root,{orientation:"vertical",ref:n,className:N("tw-flex tw-gap-1 tw-rounded-md tw-text-muted-foreground",e),...t}));go.displayName=Oe.List.displayName;const bo=g.forwardRef(({className:e,...t},n)=>a.jsx(Oe.List,{ref:n,className:N("tw-flex-fit tw-mlk-items-center tw-w-[124px] tw-justify-center tw-rounded-md tw-bg-muted tw-p-1 tw-text-muted-foreground",e),...t}));bo.displayName=Oe.List.displayName;const Ms=g.forwardRef(({className:e,...t},n)=>a.jsx(Oe.Trigger,{ref:n,...t,className:N("overflow-clip tw-inline-flex tw-w-[116px] tw-cursor-pointer tw-items-center tw-justify-center tw-break-words tw-rounded-sm tw-border-0 tw-bg-muted tw-px-3 tw-py-1.5 tw-text-sm tw-font-medium tw-text-inherit tw-ring-offset-background tw-transition-all hover:tw-text-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50 data-[state=active]:tw-bg-background data-[state=active]:tw-text-foreground data-[state=active]:tw-shadow-sm",e)})),vo=g.forwardRef(({className:e,...t},n)=>a.jsx(Oe.Content,{ref:n,className:N("tw-ms-5 tw-flex-grow tw-text-foreground tw-ring-offset-background focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2",e),...t}));vo.displayName=Oe.Content.displayName;function Rc({tabList:e,onSearch:t,searchPlaceholder:n,headerTitle:r,isSearchBarFullWidth:o=!1,direction:s="ltr"}){return a.jsxs("div",{className:"pr-twp",children:[a.jsxs("div",{className:"tw-sticky tw-top-0 tw-space-y-2 tw-pb-2",children:[r?a.jsx("h1",{children:r}):"",a.jsx(ho,{isFullWidth:o,onSearch:t,placeholder:n})]}),a.jsxs(go,{dir:s,children:[a.jsx(bo,{children:e.map(i=>a.jsx(Ms,{value:i.value,children:i.value},i.key))}),e.map(i=>a.jsx(vo,{value:i.value,children:i.content},i.key))]})]})}const lr=g.forwardRef(({className:e,orientation:t="horizontal",decorative:n=!0,...r},o)=>a.jsx(ns.Root,{ref:o,decorative:n,orientation:t,className:N("pr-twp tw-shrink-0 tw-bg-border",t==="horizontal"?"tw-h-[1px] tw-w-full":"tw-h-full tw-w-[1px]",e),...r}));lr.displayName=ns.Root.displayName;const Oc=be.Root,_c=be.Portal,$s=M.forwardRef(({className:e,...t},n)=>a.jsx(be.Overlay,{className:N("tw-fixed tw-inset-0 tw-z-50 tw-bg-black/80 data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0",e),...t,ref:n}));$s.displayName=be.Overlay.displayName;const Pc=Xt.cva("pr-twp tw-fixed tw-z-50 tw-gap-4 tw-bg-background tw-p-6 tw-shadow-lg tw-transition tw-ease-in-out data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-duration-300 data-[state=open]:tw-duration-500",{variants:{side:{top:"tw-inset-x-0 tw-top-0 tw-border-b data-[state=closed]:tw-slide-out-to-top data-[state=open]:tw-slide-in-from-top",bottom:"tw-inset-x-0 tw-bottom-0 tw-border-t data-[state=closed]:tw-slide-out-to-bottom data-[state=open]:tw-slide-in-from-bottom",left:"tw-inset-y-0 tw-left-0 tw-h-full tw-w-3/4 tw-border-r data-[state=closed]:tw-slide-out-to-left data-[state=open]:tw-slide-in-from-left sm:tw-max-w-sm",right:"tw-inset-y-0 tw-right-0 tw-h-full tw-w-3/4 tw- tw-border-l data-[state=closed]:tw-slide-out-to-right data-[state=open]:tw-slide-in-from-right sm:tw-max-w-sm"}},defaultVariants:{side:"right"}}),Ds=M.forwardRef(({side:e="right",className:t,children:n,...r},o)=>a.jsxs(_c,{children:[a.jsx($s,{}),a.jsxs(be.Content,{ref:o,className:N(Pc({side:e}),t),...r,children:[n,a.jsxs(be.Close,{className:"tw-absolute tw-right-4 tw-top-4 tw-rounded-sm tw-opacity-70 tw-ring-offset-background tw-transition-opacity hover:tw-opacity-100 focus:tw-outline-none focus:tw-ring-2 focus:tw-ring-ring focus:tw-ring-offset-2 disabled:tw-pointer-events-none data-[state=open]:tw-bg-secondary",children:[a.jsx(Q.X,{className:"tw-h-4 tw-w-4"}),a.jsx("span",{className:"tw-sr-only",children:"Close"})]})]})]}));Ds.displayName=be.Content.displayName;const Ic=M.forwardRef(({className:e,...t},n)=>a.jsx(be.Title,{ref:n,className:N("tw-text-lg tw-font-semibold tw-text-foreground",e),...t}));Ic.displayName=be.Title.displayName;const Mc=M.forwardRef(({className:e,...t},n)=>a.jsx(be.Description,{ref:n,className:N("tw-text-sm tw-text-muted-foreground",e),...t}));Mc.displayName=be.Description.displayName;function sa({className:e,...t}){return a.jsx("div",{className:N("pr-twp tw-animate-pulse tw-rounded-md tw-bg-muted",e),...t})}const $c=Sn.Provider,Dc=Sn.Root,Ac=Sn.Trigger,As=g.forwardRef(({className:e,sideOffset:t=4,...n},r)=>a.jsx(Sn.Content,{ref:r,sideOffset:t,className:N("pr-twp tw-z-50 tw-overflow-hidden tw-rounded-md tw-border tw-bg-popover tw-px-3 tw-py-1.5 tw-text-sm tw-text-popover-foreground tw-shadow-md tw-animate-in tw-fade-in-0 tw-zoom-in-95 data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=closed]:tw-zoom-out-95 data-[side=bottom]:tw-slide-in-from-top-2 data-[side=left]:tw-slide-in-from-right-2 data-[side=right]:tw-slide-in-from-left-2 data-[side=top]:tw-slide-in-from-bottom-2",e),...n}));As.displayName=Sn.Content.displayName;const Or=768;function Bc(){const[e,t]=M.useState(void 0);return M.useEffect(()=>{const n=window.matchMedia(`(max-width: ${Or-1}px)`),r=()=>{t(window.innerWidthn.removeEventListener("change",r)},[]),!!e}const Vc="sidebar:state",zc=60*60*24*7,Lc="16rem",Fc="18rem",Gc="3rem",Uc="b",Bs=g.createContext(void 0);function cr(){const e=g.useContext(Bs);if(!e)throw new Error("useSidebar must be used within a SidebarProvider.");return e}const Vs=g.forwardRef(({defaultOpen:e=!0,open:t,onOpenChange:n,className:r,style:o,children:s,...i},l)=>{const c=Bc(),[u,d]=g.useState(!1),[m,w]=g.useState(e),b=t??m,x=g.useCallback(R=>{const j=typeof R=="function"?R(b):R;n?n(j):w(j),document.cookie=`${Vc}=${j}; path=/; max-age=${zc}`},[n,b]),f=g.useCallback(()=>c?d(R=>!R):x(R=>!R),[c,x,d]);g.useEffect(()=>{const R=j=>{j.key===Uc&&(j.metaKey||j.ctrlKey)&&(j.preventDefault(),f())};return window.addEventListener("keydown",R),()=>window.removeEventListener("keydown",R)},[f]);const h=b?"expanded":"collapsed",S=g.useMemo(()=>({state:h,open:b,setOpen:x,isMobile:c,openMobile:u,setOpenMobile:d,toggleSidebar:f}),[h,b,x,c,u,d,f]);return a.jsx(Bs.Provider,{value:S,children:a.jsx($c,{delayDuration:0,children:a.jsx("div",{style:{"--sidebar-width":Lc,"--sidebar-width-icon":Gc,...o},className:N("tw-group/sidebar-wrapper pr-twp tw-flex tw-w-full has-[[data-variant=inset]]:tw-bg-sidebar",r),ref:l,...i,children:s})})})});Vs.displayName="SidebarProvider";const zs=g.forwardRef(({side:e="left",variant:t="sidebar",collapsible:n="offcanvas",className:r,children:o,...s},i)=>{const{isMobile:l,state:c,openMobile:u,setOpenMobile:d}=cr();return n==="none"?a.jsx("div",{className:N("tw-flex tw-h-full tw-w-[--sidebar-width] tw-flex-col tw-bg-sidebar tw-text-sidebar-foreground",r),ref:i,...s,children:o}):l?a.jsx(Oc,{open:u,onOpenChange:d,...s,children:a.jsx(Ds,{"data-sidebar":"sidebar","data-mobile":"true",className:"tw-w-[--sidebar-width] tw-bg-sidebar tw-p-0 tw-text-sidebar-foreground [&>button]:tw-hidden",style:{"--sidebar-width":Fc},side:e,children:a.jsx("div",{className:"tw-flex tw-h-full tw-w-full tw-flex-col",children:o})})}):a.jsxs("div",{ref:i,className:"tw-group tw-peer tw-hidden tw-text-sidebar-foreground md:tw-block","data-state":c,"data-collapsible":c==="collapsed"?n:"","data-variant":t,"data-side":e,children:[a.jsx("div",{className:N("tw-relative tw-h-svh tw-w-[--sidebar-width] tw-bg-transparent tw-transition-[width] tw-duration-200 tw-ease-linear","group-data-[collapsible=offcanvas]:tw-w-0","group-data-[side=right]:tw-rotate-180",t==="floating"||t==="inset"?"group-data-[collapsible=icon]:tw-w-[calc(var(--sidebar-width-icon)_+_theme(spacing.4))]":"group-data-[collapsible=icon]:tw-w-[--sidebar-width-icon]")}),a.jsx("div",{className:N("tw-absolute tw-inset-y-0 tw-z-10 tw-hidden tw-h-svh tw-w-[--sidebar-width] tw-transition-[left,right,width] tw-duration-200 tw-ease-linear md:tw-flex",e==="left"?"tw-left-0 group-data-[collapsible=offcanvas]:tw-left-[calc(var(--sidebar-width)*-1)]":"tw-right-0 group-data-[collapsible=offcanvas]:tw-right-[calc(var(--sidebar-width)*-1)]",t==="floating"||t==="inset"?"tw-p-2 group-data-[collapsible=icon]:tw-w-[calc(var(--sidebar-width-icon)_+_theme(spacing.4)_+2px)]":"group-data-[collapsible=icon]:tw-w-[--sidebar-width-icon] group-data-[side=left]:tw-border-r group-data-[side=right]:tw-border-l",r),...s,children:a.jsx("div",{"data-sidebar":"sidebar",className:"tw-flex tw-h-full tw-w-full tw-flex-col tw-bg-sidebar group-data-[variant=floating]:tw-rounded-lg group-data-[variant=floating]:tw-border group-data-[variant=floating]:tw-border-sidebar-border group-data-[variant=floating]:tw-shadow",children:o})})]})});zs.displayName="Sidebar";const qc=g.forwardRef(({className:e,onClick:t,...n},r)=>{const{toggleSidebar:o}=cr();return a.jsxs(fe,{ref:r,"data-sidebar":"trigger",variant:"ghost",size:"icon",className:N("tw-h-7 tw-w-7",e),onClick:s=>{t==null||t(s),o()},...n,children:[a.jsx(Q.PanelLeft,{}),a.jsx("span",{className:"tw-sr-only",children:"Toggle Sidebar"})]})});qc.displayName="SidebarTrigger";const Hc=g.forwardRef(({className:e,...t},n)=>{const{toggleSidebar:r}=cr();return a.jsx("button",{type:"button",ref:n,"data-sidebar":"rail","aria-label":"Toggle Sidebar",tabIndex:-1,onClick:r,title:"Toggle Sidebar",className:N("tw-absolute tw-inset-y-0 tw-z-20 tw-hidden tw-w-4 tw--translate-x-1/2 tw-transition-all tw-ease-linear after:tw-absolute after:tw-inset-y-0 after:tw-left-1/2 after:tw-w-[2px] hover:after:tw-bg-sidebar-border group-data-[side=left]:tw--right-4 group-data-[side=right]:tw-left-0 sm:tw-flex","[[data-side=left]_&]:tw-cursor-w-resize [[data-side=right]_&]:tw-cursor-e-resize","[[data-side=left][data-state=collapsed]_&]:tw-cursor-e-resize [[data-side=right][data-state=collapsed]_&]:tw-cursor-w-resize","group-data-[collapsible=offcanvas]:tw-translate-x-0 group-data-[collapsible=offcanvas]:after:tw-left-full group-data-[collapsible=offcanvas]:hover:tw-bg-sidebar","[[data-side=left][data-collapsible=offcanvas]_&]:tw--right-2","[[data-side=right][data-collapsible=offcanvas]_&]:tw--left-2",e),...t})});Hc.displayName="SidebarRail";const Ls=g.forwardRef(({className:e,...t},n)=>a.jsx("main",{ref:n,className:N("tw-relative tw-flex tw-flex-1 tw-flex-col tw-bg-background","peer-data-[variant=inset]:tw-min-h-[calc(100svh-theme(spacing.4))] md:peer-data-[variant=inset]:tw-m-2 md:peer-data-[state=collapsed]:peer-data-[variant=inset]:tw-ml-2 md:peer-data-[variant=inset]:tw-ml-0 md:peer-data-[variant=inset]:tw-rounded-xl md:peer-data-[variant=inset]:tw-shadow",e),...t}));Ls.displayName="SidebarInset";const Xc=g.forwardRef(({className:e,...t},n)=>a.jsx(St,{ref:n,"data-sidebar":"input",className:N("tw-h-8 tw-w-full tw-bg-background tw-shadow-none focus-visible:tw-ring-2 focus-visible:tw-ring-sidebar-ring",e),...t}));Xc.displayName="SidebarInput";const Yc=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,"data-sidebar":"header",className:N("tw-flex tw-flex-col tw-gap-2 tw-p-2",e),...t}));Yc.displayName="SidebarHeader";const Wc=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,"data-sidebar":"footer",className:N("tw-flex tw-flex-col tw-gap-2 tw-p-2",e),...t}));Wc.displayName="SidebarFooter";const Kc=g.forwardRef(({className:e,...t},n)=>a.jsx(lr,{ref:n,"data-sidebar":"separator",className:N("tw-mx-2 tw-w-auto tw-bg-sidebar-border",e),...t}));Kc.displayName="SidebarSeparator";const Fs=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,"data-sidebar":"content",className:N("tw-flex tw-min-h-0 tw-flex-1 tw-flex-col tw-gap-2 tw-overflow-auto group-data-[collapsible=icon]:tw-overflow-hidden",e),...t}));Fs.displayName="SidebarContent";const Xr=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,"data-sidebar":"group",className:N("tw-relative tw-flex tw-w-full tw-min-w-0 tw-flex-col tw-p-2",e),...t}));Xr.displayName="SidebarGroup";const Yr=g.forwardRef(({className:e,asChild:t=!1,...n},r)=>{const o=t?Ht.Slot:"div";return a.jsx(o,{ref:r,"data-sidebar":"group-label",className:N("tw-flex tw-h-8 tw-shrink-0 tw-items-center tw-rounded-md tw-px-2 tw-text-xs tw-font-medium tw-text-sidebar-foreground/70 tw-outline-none tw-ring-sidebar-ring tw-transition-[margin,opa] tw-duration-200 tw-ease-linear focus-visible:tw-ring-2 [&>svg]:tw-size-4 [&>svg]:tw-shrink-0","group-data-[collapsible=icon]:tw--mt-8 group-data-[collapsible=icon]:tw-opacity-0",e),...n})});Yr.displayName="SidebarGroupLabel";const Jc=g.forwardRef(({className:e,asChild:t=!1,...n},r)=>{const o=t?Ht.Slot:"button";return a.jsx(o,{ref:r,"data-sidebar":"group-action",className:N("tw-absolute tw-right-3 tw-top-3.5 tw-flex tw-aspect-square tw-w-5 tw-items-center tw-justify-center tw-rounded-md tw-p-0 tw-text-sidebar-foreground tw-outline-none tw-ring-sidebar-ring tw-transition-transform hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground focus-visible:tw-ring-2 [&>svg]:tw-size-4 [&>svg]:tw-shrink-0","after:tw-absolute after:tw--inset-2 after:md:tw-hidden","group-data-[collapsible=icon]:tw-hidden",e),...n})});Jc.displayName="SidebarGroupAction";const Wr=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,"data-sidebar":"group-content",className:N("tw-w-full tw-text-sm",e),...t}));Wr.displayName="SidebarGroupContent";const Gs=g.forwardRef(({className:e,...t},n)=>a.jsx("ul",{ref:n,"data-sidebar":"menu",className:N("tw-flex tw-w-full tw-min-w-0 tw-flex-col tw-gap-1",e),...t}));Gs.displayName="SidebarMenu";const Us=g.forwardRef(({className:e,...t},n)=>a.jsx("li",{ref:n,"data-sidebar":"menu-item",className:N("tw-group/menu-item tw-relative",e),...t}));Us.displayName="SidebarMenuItem";const Zc=Xt.cva("tw-peer/menu-button tw-flex tw-w-full tw-items-center tw-gap-2 tw-overflow-hidden tw-rounded-md tw-p-2 tw-text-left tw-text-sm tw-outline-none tw-ring-sidebar-ring tw-transition-[width,height,padding] hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground focus-visible:tw-ring-2 active:tw-bg-sidebar-accent active:tw-text-sidebar-accent-foreground disabled:tw-pointer-events-none disabled:tw-opacity-50 tw-group-has-[[data-sidebar=menu-action]]/menu-item:pr-8 aria-disabled:tw-pointer-events-none aria-disabled:tw-opacity-50 data-[active=true]:tw-font-medium data-[active=true]:tw-text-sidebar-accent-foreground data-[state=open]:hover:tw-bg-sidebar-accent data-[state=open]:hover:tw-text-sidebar-accent-foreground group-data-[collapsible=icon]:tw-!size-8 group-data-[collapsible=icon]:tw-!p-2 [&>span:last-child]:tw-truncate [&>svg]:tw-size-4 [&>svg]:tw-shrink-0",{variants:{variant:{default:"hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground",outline:"tw-bg-background tw-shadow-[0_0_0_1px_hsl(var(--sidebar-border))] hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground hover:tw-shadow-[0_0_0_1px_hsl(var(--sidebar-accent))]"},size:{default:"tw-h-8 tw-text-sm",sm:"tw-h-7 tw-text-xs",lg:"tw-h-12 tw-text-sm group-data-[collapsible=icon]:tw-!p-0"}},defaultVariants:{variant:"default",size:"default"}}),qs=g.forwardRef(({asChild:e=!1,isActive:t=!1,variant:n="default",size:r="default",tooltip:o,className:s,...i},l)=>{const c=e?Ht.Slot:"button",{isMobile:u,state:d}=cr(),m=a.jsx(c,{ref:l,"data-sidebar":"menu-button","data-size":r,"data-active":t,className:N(Zc({variant:n,size:r}),s),...i});return o?(typeof o=="string"&&(o={children:o}),a.jsxs(Dc,{children:[a.jsx(Ac,{asChild:!0,children:m}),a.jsx(As,{side:"right",align:"center",hidden:d!=="collapsed"||u,...o})]})):m});qs.displayName="SidebarMenuButton";const Qc=g.forwardRef(({className:e,asChild:t=!1,showOnHover:n=!1,...r},o)=>{const s=t?Ht.Slot:"button";return a.jsx(s,{ref:o,"data-sidebar":"menu-action",className:N("tw-peer-hover/menu-button:text-sidebar-accent-foreground tw-absolute tw-right-1 tw-top-1.5 tw-flex tw-aspect-square tw-w-5 tw-items-center tw-justify-center tw-rounded-md tw-p-0 tw-text-sidebar-foreground tw-outline-none tw-ring-sidebar-ring tw-transition-transform hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground focus-visible:tw-ring-2 [&>svg]:tw-size-4 [&>svg]:tw-shrink-0","after:tw-absolute after:tw--inset-2 after:md:tw-hidden","tw-peer-data-[size=sm]/menu-button:top-1","tw-peer-data-[size=default]/menu-button:top-1.5","tw-peer-data-[size=lg]/menu-button:top-2.5","group-data-[collapsible=icon]:tw-hidden",n&&"tw-group-focus-within/menu-item:opacity-100 tw-group-hover/menu-item:opacity-100 tw-peer-data-[active=true]/menu-button:text-sidebar-accent-foreground data-[state=open]:tw-opacity-100 md:tw-opacity-0",e),...r})});Qc.displayName="SidebarMenuAction";const ed=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,"data-sidebar":"menu-badge",className:N("tw-pointer-events-none tw-absolute tw-right-1 tw-flex tw-h-5 tw-min-w-5 tw-select-none tw-items-center tw-justify-center tw-rounded-md tw-px-1 tw-text-xs tw-font-medium tw-tabular-nums tw-text-sidebar-foreground","tw-peer-hover/menu-button:text-sidebar-accent-foreground tw-peer-data-[active=true]/menu-button:text-sidebar-accent-foreground","tw-peer-data-[size=sm]/menu-button:top-1","tw-peer-data-[size=default]/menu-button:top-1.5","tw-peer-data-[size=lg]/menu-button:top-2.5","group-data-[collapsible=icon]:tw-hidden",e),...t}));ed.displayName="SidebarMenuBadge";const td=g.forwardRef(({className:e,showIcon:t=!1,...n},r)=>{const o=g.useMemo(()=>`${Math.floor(Math.random()*40)+50}%`,[]);return a.jsxs("div",{ref:r,"data-sidebar":"menu-skeleton",className:N("tw-flex tw-h-8 tw-items-center tw-gap-2 tw-rounded-md tw-px-2",e),...n,children:[t&&a.jsx(sa,{className:"tw-size-4 tw-rounded-md","data-sidebar":"menu-skeleton-icon"}),a.jsx(sa,{className:"tw-h-4 tw-max-w-[--skeleton-width] tw-flex-1","data-sidebar":"menu-skeleton-text",style:{"--skeleton-width":o}})]})});td.displayName="SidebarMenuSkeleton";const nd=g.forwardRef(({className:e,...t},n)=>a.jsx("ul",{ref:n,"data-sidebar":"menu-sub",className:N("tw-mx-3.5 tw-flex tw-min-w-0 tw-translate-x-px tw-flex-col tw-gap-1 tw-border-l tw-border-sidebar-border tw-px-2.5 tw-py-0.5","group-data-[collapsible=icon]:tw-hidden",e),...t}));nd.displayName="SidebarMenuSub";const rd=g.forwardRef(({...e},t)=>a.jsx("li",{ref:t,...e}));rd.displayName="SidebarMenuSubItem";const od=g.forwardRef(({asChild:e=!1,size:t="md",isActive:n,className:r,...o},s)=>{const i=e?Ht.Slot:"a";return a.jsx(i,{ref:s,"data-sidebar":"menu-sub-button","data-size":t,"data-active":n,className:N("tw-flex tw-h-7 tw-min-w-0 tw--translate-x-px tw-items-center tw-gap-2 tw-overflow-hidden tw-rounded-md tw-px-2 tw-text-sidebar-foreground tw-outline-none tw-ring-sidebar-ring hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground focus-visible:tw-ring-2 active:tw-bg-sidebar-accent active:tw-text-sidebar-accent-foreground disabled:tw-pointer-events-none disabled:tw-opacity-50 aria-disabled:tw-pointer-events-none aria-disabled:tw-opacity-50 [&>span:last-child]:tw-truncate [&>svg]:tw-size-4 [&>svg]:tw-shrink-0 [&>svg]:tw-text-sidebar-accent-foreground","data-[active=true]:tw-bg-sidebar-accent data-[active=true]:tw-text-sidebar-accent-foreground",t==="sm"&&"tw-text-xs",t==="md"&&"tw-text-sm","group-data-[collapsible=icon]:tw-hidden",r),...o})});od.displayName="SidebarMenuSubButton";function Hs({id:e,extensionLabels:t,projectOptions:n,handleSelectSidebarItem:r,selectedSidebarItem:o,extensionsSidebarGroupLabel:s,projectsSidebarGroupLabel:i}){const l=g.useCallback((d,m)=>{r(d,m)},[r]),c=g.useCallback(d=>{const m=n.find(w=>w.projectId===d);return m?m.projectName:d},[n]),u=g.useCallback(d=>!o.projectId&&d===o.label,[o]);return a.jsx(zs,{id:e,collapsible:"none",variant:"inset",className:"tw-w-96 tw-gap-2 tw-overflow-y-auto tw-rounded tw-bg-slate-100",children:a.jsxs(Fs,{children:[a.jsxs(Xr,{children:[a.jsx(Yr,{className:"tw-text-sm tw-text-gray-400",children:s}),a.jsx(Wr,{children:a.jsx(Gs,{children:t.map(d=>a.jsx(Us,{children:a.jsx(qs,{className:N("tw-rounded tw-py-2 tw-text-sm tw-text-gray-500 hover:tw-bg-white hover:tw-text-gray-900 hover:tw-shadow-sm active:tw-bg-white",{"tw-bg-white tw-text-gray-900 tw-shadow-sm":u(d)}),onClick:()=>l(d,void 0),isActive:u(d),children:a.jsx("span",{className:"tw-pl-3",children:d})})},d))})})]}),a.jsxs(Xr,{children:[a.jsx(Yr,{className:"tw-text-sm tw-text-gray-400",children:i}),a.jsx(Wr,{className:"tw-pl-3",children:a.jsx(Wn,{popoverContentClassName:"tw-z-[1000]",options:n.flatMap(d=>d.projectId),getOptionLabel:d=>c(d),buttonPlaceholder:"Type or select project",onChange:d=>{const m=c(d);l(m,d)},value:(o==null?void 0:o.projectId)??void 0})})]})]})})}function ad({id:e,direction:t="ltr",extensionLabels:n,projectOptions:r,children:o,handleSelectSidebarItem:s,selectedSidebarItem:i,onSearch:l,extensionsSidebarGroupLabel:c,projectsSidebarGroupLabel:u}){return a.jsxs("div",{className:"tw-flex tw-h-full tw-flex-col tw-p-3 tw-pb-2",children:[a.jsx("div",{className:"tw-flex tw-items-center tw-justify-center tw-py-4",children:a.jsx(ho,{className:"tw-w-9/12",onSearch:l,placeholder:"Search app settings, extension settings, and project settings"})}),a.jsxs(Vs,{dir:t,id:e,className:"tw-h-full tw-flex-1 tw-gap-4",children:[a.jsx(Hs,{extensionLabels:n,projectOptions:r,handleSelectSidebarItem:s,selectedSidebarItem:i,extensionsSidebarGroupLabel:c,projectsSidebarGroupLabel:u}),a.jsx(Ls,{className:"tw-overflow-y-auto",children:o})]})]})}const rt="scrBook",sd="scrRef",pt="source",id="details",ld="Scripture Reference",cd="Scripture Book",Xs="Type",dd="Details";function ud(e,t){const n=t??!1;return[{accessorFn:r=>`${ae.bookNumberToId(r.start.bookNum)} ${r.start.chapterNum}:${r.start.verseNum}`,id:rt,header:(e==null?void 0:e.scriptureReferenceColumnName)??ld,cell:r=>{const o=r.row.original;return r.row.getIsGrouped()?ae.bookNumberToEnglishName(o.start.bookNum):r.row.groupingColumnId===rt?W.formatScrRef(o.start):void 0},getGroupingValue:r=>r.start.bookNum,sortingFn:(r,o)=>W.compareScrRefs(r.original.start,o.original.start),enableGrouping:!0},{accessorFn:r=>W.formatScrRef(r.start),id:sd,header:void 0,cell:r=>{const o=r.row.original;return r.row.getIsGrouped()?void 0:W.formatScrRef(o.start)},sortingFn:(r,o)=>W.compareScrRefs(r.original.start,o.original.start),enableGrouping:!1},{accessorFn:r=>r.source.displayName,id:pt,header:n?(e==null?void 0:e.typeColumnName)??Xs:void 0,cell:r=>n||r.row.getIsGrouped()?r.getValue():void 0,getGroupingValue:r=>r.source.id,sortingFn:(r,o)=>r.original.source.displayName.localeCompare(o.original.source.displayName),enableGrouping:!0},{accessorFn:r=>r.detail,id,header:(e==null?void 0:e.detailsColumnName)??dd,cell:r=>r.getValue(),enableGrouping:!1}]}const pd=e=>{if(!("offset"in e.start))throw new Error("No offset available in range start");if(e.end&&!("offset"in e.end))throw new Error("No offset available in range end");const{offset:t}=e.start;let n=0;return e.end&&({offset:n}=e.end),!e.end||W.compareScrRefs(e.start,e.end)===0?`${W.scrRefToBBBCCCVVV(e.start)}+${t}`:`${W.scrRefToBBBCCCVVV(e.start)}+${t}-${W.scrRefToBBBCCCVVV(e.end)}+${n}`},ia=e=>`${pd({start:e.start,end:e.end})} ${e.source.displayName} ${e.detail}`;function wd({sources:e,showColumnHeaders:t=!1,showSourceColumn:n=!1,scriptureReferenceColumnName:r,scriptureBookGroupName:o,typeColumnName:s,detailsColumnName:i,onRowSelected:l,direction:c="ltr"}){const[u,d]=g.useState([]),[m,w]=g.useState([{id:rt,desc:!1}]),[b,x]=g.useState({}),f=g.useMemo(()=>e.flatMap(C=>C.data.map(_=>({..._,source:C.source}))),[e]),h=g.useMemo(()=>ud({scriptureReferenceColumnName:r,typeColumnName:s,detailsColumnName:i},n),[r,s,i,n]);g.useEffect(()=>{u.includes(pt)?w([{id:pt,desc:!1},{id:rt,desc:!1}]):w([{id:rt,desc:!1}])},[u]);const S=Se.useReactTable({data:f,columns:h,state:{grouping:u,sorting:m,rowSelection:b},onGroupingChange:d,onSortingChange:w,onRowSelectionChange:x,getExpandedRowModel:Se.getExpandedRowModel(),getGroupedRowModel:Se.getGroupedRowModel(),getCoreRowModel:Se.getCoreRowModel(),getSortedRowModel:Se.getSortedRowModel(),getRowId:ia,autoResetExpanded:!1,enableMultiRowSelection:!1,enableSubRowSelection:!1});g.useEffect(()=>{if(l){const C=S.getSelectedRowModel().rowsById,_=Object.keys(C);if(_.length===1){const k=f.find(D=>ia(D)===_[0])||void 0;k&&l(k)}}},[b,f,l,S]);const R=o??cd,j=s??Xs,E=[{label:"No Grouping",value:[]},{label:`Group by ${R}`,value:[rt]},{label:`Group by ${j}`,value:[pt]},{label:`Group by ${R} and ${j}`,value:[rt,pt]},{label:`Group by ${j} and ${R}`,value:[pt,rt]}],v=C=>{d(JSON.parse(C))},P=(C,_)=>{!C.getIsGrouped()&&!C.getIsSelected()&&C.getToggleSelectedHandler()(_)},V=(C,_)=>C.getIsGrouped()?"":N("banded-row",_%2===0?"even":"odd"),U=(C,_,k)=>{if(!((C==null?void 0:C.length)===0||_.depth{v(C)},children:[a.jsx(bt,{className:"tw-mb-1 tw-mt-2",children:a.jsx(Bt,{})}),a.jsx(vt,{position:"item-aligned",children:a.jsx(ks,{children:E.map(C=>a.jsx(Ae,{value:JSON.stringify(C.value),children:C.label},C.label))})})]}),a.jsxs(Cn,{className:"tw-relative tw-flex tw-flex-col tw-overflow-y-auto tw-p-0",children:[t&&a.jsx(Tn,{children:S.getHeaderGroups().map(C=>a.jsx(Ze,{children:C.headers.filter(_=>_.column.columnDef.header).map(_=>a.jsx(Vt,{colSpan:_.colSpan,className:"top-0 tw-sticky",children:_.isPlaceholder?void 0:a.jsxs("div",{children:[_.column.getCanGroup()?a.jsx(fe,{variant:"ghost",title:`Toggle grouping by ${_.column.columnDef.header}`,onClick:_.column.getToggleGroupingHandler(),type:"button",children:_.column.getIsGrouped()?"🛑":"👊 "}):void 0," ",Se.flexRender(_.column.columnDef.header,_.getContext())]})},_.id))},C.id))}),a.jsx(Rn,{children:S.getRowModel().rows.map((C,_)=>a.jsx(Ze,{"data-state":C.getIsSelected()?"selected":"",className:N(V(C,_)),onClick:k=>P(C,k),children:C.getVisibleCells().map(k=>{if(!(k.getIsPlaceholder()||k.column.columnDef.enableGrouping&&!k.getIsGrouped()&&(k.column.columnDef.id!==pt||!n)))return a.jsx(xt,{className:N(k.column.columnDef.id,"tw-p-[1px]",U(u,C,k)),children:(()=>k.getIsGrouped()?a.jsxs(fe,{variant:"link",onClick:C.getToggleExpandedHandler(),type:"button",children:[C.getIsExpanded()&&a.jsx(Q.ChevronDown,{}),!C.getIsExpanded()&&(c==="ltr"?a.jsx(Q.ChevronRight,{}):a.jsx(Q.ChevronLeft,{}))," ",Se.flexRender(k.column.columnDef.cell,k.getContext())," (",C.subRows.length,")"]}):Se.flexRender(k.column.columnDef.cell,k.getContext()))()},k.id)})},C.id))})]})]})}const _r={[W.getLocalizeKeyForScrollGroupId("undefined")]:"Ø",[W.getLocalizeKeyForScrollGroupId(0)]:"A",[W.getLocalizeKeyForScrollGroupId(1)]:"B",[W.getLocalizeKeyForScrollGroupId(2)]:"C",[W.getLocalizeKeyForScrollGroupId(3)]:"D",[W.getLocalizeKeyForScrollGroupId(4)]:"E",[W.getLocalizeKeyForScrollGroupId(5)]:"F",[W.getLocalizeKeyForScrollGroupId(6)]:"G",[W.getLocalizeKeyForScrollGroupId(7)]:"H",[W.getLocalizeKeyForScrollGroupId(8)]:"I",[W.getLocalizeKeyForScrollGroupId(9)]:"J",[W.getLocalizeKeyForScrollGroupId(10)]:"K",[W.getLocalizeKeyForScrollGroupId(11)]:"L",[W.getLocalizeKeyForScrollGroupId(12)]:"M",[W.getLocalizeKeyForScrollGroupId(13)]:"N",[W.getLocalizeKeyForScrollGroupId(14)]:"O",[W.getLocalizeKeyForScrollGroupId(15)]:"P",[W.getLocalizeKeyForScrollGroupId(16)]:"Q",[W.getLocalizeKeyForScrollGroupId(17)]:"R",[W.getLocalizeKeyForScrollGroupId(18)]:"S",[W.getLocalizeKeyForScrollGroupId(19)]:"T",[W.getLocalizeKeyForScrollGroupId(20)]:"U",[W.getLocalizeKeyForScrollGroupId(21)]:"V",[W.getLocalizeKeyForScrollGroupId(22)]:"W",[W.getLocalizeKeyForScrollGroupId(23)]:"X",[W.getLocalizeKeyForScrollGroupId(24)]:"Y",[W.getLocalizeKeyForScrollGroupId(25)]:"Z"};function fd({availableScrollGroupIds:e,scrollGroupId:t,onChangeScrollGroupId:n,localizedStrings:r={}}){const o={..._r,...Object.fromEntries(Object.entries(r).map(([s,i])=>[s,s===i&&s in _r?_r[s]:i]))};return a.jsxs(At,{value:`${t}`,onValueChange:s=>n(s==="undefined"?void 0:parseInt(s,10)),children:[a.jsx(bt,{className:"pr-twp tw-w-auto",children:a.jsx(Bt,{placeholder:o[W.getLocalizeKeyForScrollGroupId(t)]??t})}),a.jsx(vt,{style:{zIndex:250},children:e.map(s=>a.jsx(Ae,{value:`${s}`,children:o[W.getLocalizeKeyForScrollGroupId(s)]},`${s}`))})]})}function md({children:e}){return a.jsx("div",{className:"pr-twp tw-grid",children:e})}function hd({primary:e,secondary:t,children:n,isLoading:r=!1,loadingMessage:o}){return a.jsxs("div",{className:"tw-flex tw-items-center tw-justify-between tw-space-x-4 tw-py-2",children:[a.jsxs("div",{children:[a.jsx("p",{className:"tw-text-sm tw-font-medium tw-leading-none",children:e}),a.jsx("p",{className:"tw-whitespace-normal tw-break-words tw-text-sm tw-text-muted-foreground",children:t})]}),r?a.jsx("p",{className:"tw-text-sm tw-text-muted-foreground",children:o}):a.jsx("div",{children:n})]})}function gd({primary:e,secondary:t,includeSeparator:n=!1}){return a.jsxs("div",{className:"tw-space-y-4 tw-py-2",children:[a.jsxs("div",{children:[a.jsx("h3",{className:"tw-text-lg tw-font-medium",children:e}),a.jsx("p",{className:"tw-text-sm tw-text-muted-foreground",children:t})]}),n?a.jsx(lr,{}):""]})}function bd({id:e,className:t,listItems:n,selectedListItems:r,handleSelectListItem:o,createLabel:s}){return a.jsx("div",{id:e,className:t,children:n.map(i=>a.jsxs("div",{className:"tw-m-2 tw-flex tw-items-center",children:[a.jsx(sr,{className:"tw-mr-2 tw-align-middle",checked:r.includes(i),onCheckedChange:l=>o(i,l)}),a.jsx(qe,{children:s?s(i):i})]},i))})}function vd(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}function xd(e){if(e.__esModule)return e;var t=e.default;if(typeof t=="function"){var n=function r(){return this instanceof r?Reflect.construct(t,arguments,this.constructor):t.apply(this,arguments)};n.prototype=t.prototype}else n={};return Object.defineProperty(n,"__esModule",{value:!0}),Object.keys(e).forEach(function(r){var o=Object.getOwnPropertyDescriptor(e,r);Object.defineProperty(n,r,o.get?o:{enumerable:!0,get:function(){return e[r]}})}),n}var xo={},Ys={exports:{}};(function(e){function t(n){return n&&n.__esModule?n:{default:n}}e.exports=t,e.exports.__esModule=!0,e.exports.default=e.exports})(Ys);var yd=Ys.exports,Pr={};function yo(e,t){return process.env.NODE_ENV==="production"?()=>null:function(...r){return e(...r)||t(...r)}}function O(){return O=Object.assign?Object.assign.bind():function(e){for(var t=1;t{t[n]=Ws(e[n])}),t}function Qe(e,t,n={clone:!0}){const r=n.clone?O({},e):e;return mt(e)&&mt(t)&&Object.keys(t).forEach(o=>{o!=="__proto__"&&(mt(t[o])&&o in e&&mt(e[o])?r[o]=Qe(e[o],t[o],n):n.clone?r[o]=mt(t[o])?Ws(t[o]):t[o]:r[o]=t[o])}),r}var Kr={exports:{}},zn={exports:{}},ie={};/** @license React v16.13.1 * react-is.production.min.js * * Copyright (c) Facebook, Inc. and its affiliates. * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. - */var la;function Nd(){if(la)return ie;la=1;var e=typeof Symbol=="function"&&Symbol.for,t=e?Symbol.for("react.element"):60103,n=e?Symbol.for("react.portal"):60106,r=e?Symbol.for("react.fragment"):60107,o=e?Symbol.for("react.strict_mode"):60108,s=e?Symbol.for("react.profiler"):60114,i=e?Symbol.for("react.provider"):60109,l=e?Symbol.for("react.context"):60110,c=e?Symbol.for("react.async_mode"):60111,d=e?Symbol.for("react.concurrent_mode"):60111,u=e?Symbol.for("react.forward_ref"):60112,h=e?Symbol.for("react.suspense"):60113,w=e?Symbol.for("react.suspense_list"):60120,b=e?Symbol.for("react.memo"):60115,x=e?Symbol.for("react.lazy"):60116,f=e?Symbol.for("react.block"):60121,m=e?Symbol.for("react.fundamental"):60117,S=e?Symbol.for("react.responder"):60118,R=e?Symbol.for("react.scope"):60119;function j(v){if(typeof v=="object"&&v!==null){var P=v.$$typeof;switch(P){case t:switch(v=v.type,v){case c:case d:case r:case s:case o:case h:return v;default:switch(v=v&&v.$$typeof,v){case l:case u:case x:case b:case i:return v;default:return P}}case n:return P}}}function E(v){return j(v)===d}return ie.AsyncMode=c,ie.ConcurrentMode=d,ie.ContextConsumer=l,ie.ContextProvider=i,ie.Element=t,ie.ForwardRef=u,ie.Fragment=r,ie.Lazy=x,ie.Memo=b,ie.Portal=n,ie.Profiler=s,ie.StrictMode=o,ie.Suspense=h,ie.isAsyncMode=function(v){return E(v)||j(v)===c},ie.isConcurrentMode=E,ie.isContextConsumer=function(v){return j(v)===l},ie.isContextProvider=function(v){return j(v)===i},ie.isElement=function(v){return typeof v=="object"&&v!==null&&v.$$typeof===t},ie.isForwardRef=function(v){return j(v)===u},ie.isFragment=function(v){return j(v)===r},ie.isLazy=function(v){return j(v)===x},ie.isMemo=function(v){return j(v)===b},ie.isPortal=function(v){return j(v)===n},ie.isProfiler=function(v){return j(v)===s},ie.isStrictMode=function(v){return j(v)===o},ie.isSuspense=function(v){return j(v)===h},ie.isValidElementType=function(v){return typeof v=="string"||typeof v=="function"||v===r||v===d||v===s||v===o||v===h||v===w||typeof v=="object"&&v!==null&&(v.$$typeof===x||v.$$typeof===b||v.$$typeof===i||v.$$typeof===l||v.$$typeof===u||v.$$typeof===m||v.$$typeof===S||v.$$typeof===R||v.$$typeof===f)},ie.typeOf=j,ie}var le={};/** @license React v16.13.1 + */var la;function Nd(){if(la)return ie;la=1;var e=typeof Symbol=="function"&&Symbol.for,t=e?Symbol.for("react.element"):60103,n=e?Symbol.for("react.portal"):60106,r=e?Symbol.for("react.fragment"):60107,o=e?Symbol.for("react.strict_mode"):60108,s=e?Symbol.for("react.profiler"):60114,i=e?Symbol.for("react.provider"):60109,l=e?Symbol.for("react.context"):60110,c=e?Symbol.for("react.async_mode"):60111,u=e?Symbol.for("react.concurrent_mode"):60111,d=e?Symbol.for("react.forward_ref"):60112,m=e?Symbol.for("react.suspense"):60113,w=e?Symbol.for("react.suspense_list"):60120,b=e?Symbol.for("react.memo"):60115,x=e?Symbol.for("react.lazy"):60116,f=e?Symbol.for("react.block"):60121,h=e?Symbol.for("react.fundamental"):60117,S=e?Symbol.for("react.responder"):60118,R=e?Symbol.for("react.scope"):60119;function j(v){if(typeof v=="object"&&v!==null){var P=v.$$typeof;switch(P){case t:switch(v=v.type,v){case c:case u:case r:case s:case o:case m:return v;default:switch(v=v&&v.$$typeof,v){case l:case d:case x:case b:case i:return v;default:return P}}case n:return P}}}function E(v){return j(v)===u}return ie.AsyncMode=c,ie.ConcurrentMode=u,ie.ContextConsumer=l,ie.ContextProvider=i,ie.Element=t,ie.ForwardRef=d,ie.Fragment=r,ie.Lazy=x,ie.Memo=b,ie.Portal=n,ie.Profiler=s,ie.StrictMode=o,ie.Suspense=m,ie.isAsyncMode=function(v){return E(v)||j(v)===c},ie.isConcurrentMode=E,ie.isContextConsumer=function(v){return j(v)===l},ie.isContextProvider=function(v){return j(v)===i},ie.isElement=function(v){return typeof v=="object"&&v!==null&&v.$$typeof===t},ie.isForwardRef=function(v){return j(v)===d},ie.isFragment=function(v){return j(v)===r},ie.isLazy=function(v){return j(v)===x},ie.isMemo=function(v){return j(v)===b},ie.isPortal=function(v){return j(v)===n},ie.isProfiler=function(v){return j(v)===s},ie.isStrictMode=function(v){return j(v)===o},ie.isSuspense=function(v){return j(v)===m},ie.isValidElementType=function(v){return typeof v=="string"||typeof v=="function"||v===r||v===u||v===s||v===o||v===m||v===w||typeof v=="object"&&v!==null&&(v.$$typeof===x||v.$$typeof===b||v.$$typeof===i||v.$$typeof===l||v.$$typeof===d||v.$$typeof===h||v.$$typeof===S||v.$$typeof===R||v.$$typeof===f)},ie.typeOf=j,ie}var le={};/** @license React v16.13.1 * react-is.development.js * * Copyright (c) Facebook, Inc. and its affiliates. * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. - */var ca;function kd(){return ca||(ca=1,process.env.NODE_ENV!=="production"&&function(){var e=typeof Symbol=="function"&&Symbol.for,t=e?Symbol.for("react.element"):60103,n=e?Symbol.for("react.portal"):60106,r=e?Symbol.for("react.fragment"):60107,o=e?Symbol.for("react.strict_mode"):60108,s=e?Symbol.for("react.profiler"):60114,i=e?Symbol.for("react.provider"):60109,l=e?Symbol.for("react.context"):60110,c=e?Symbol.for("react.async_mode"):60111,d=e?Symbol.for("react.concurrent_mode"):60111,u=e?Symbol.for("react.forward_ref"):60112,h=e?Symbol.for("react.suspense"):60113,w=e?Symbol.for("react.suspense_list"):60120,b=e?Symbol.for("react.memo"):60115,x=e?Symbol.for("react.lazy"):60116,f=e?Symbol.for("react.block"):60121,m=e?Symbol.for("react.fundamental"):60117,S=e?Symbol.for("react.responder"):60118,R=e?Symbol.for("react.scope"):60119;function j(I){return typeof I=="string"||typeof I=="function"||I===r||I===d||I===s||I===o||I===h||I===w||typeof I=="object"&&I!==null&&(I.$$typeof===x||I.$$typeof===b||I.$$typeof===i||I.$$typeof===l||I.$$typeof===u||I.$$typeof===m||I.$$typeof===S||I.$$typeof===R||I.$$typeof===f)}function E(I){if(typeof I=="object"&&I!==null){var ye=I.$$typeof;switch(ye){case t:var A=I.type;switch(A){case c:case d:case r:case s:case o:case h:return A;default:var xe=A&&A.$$typeof;switch(xe){case l:case u:case x:case b:case i:return xe;default:return ye}}case n:return ye}}}var v=c,P=d,V=l,U=i,C=t,_=u,k=r,D=x,$=b,J=n,Y=s,F=o,te=h,se=!1;function oe(I){return se||(se=!0,console.warn("The ReactIs.isAsyncMode() alias has been deprecated, and will be removed in React 17+. Update your code to use ReactIs.isConcurrentMode() instead. It has the exact same API.")),y(I)||E(I)===c}function y(I){return E(I)===d}function T(I){return E(I)===l}function z(I){return E(I)===i}function L(I){return typeof I=="object"&&I!==null&&I.$$typeof===t}function B(I){return E(I)===u}function X(I){return E(I)===r}function q(I){return E(I)===x}function H(I){return E(I)===b}function G(I){return E(I)===n}function K(I){return E(I)===s}function Z(I){return E(I)===o}function ue(I){return E(I)===h}le.AsyncMode=v,le.ConcurrentMode=P,le.ContextConsumer=V,le.ContextProvider=U,le.Element=C,le.ForwardRef=_,le.Fragment=k,le.Lazy=D,le.Memo=$,le.Portal=J,le.Profiler=Y,le.StrictMode=F,le.Suspense=te,le.isAsyncMode=oe,le.isConcurrentMode=y,le.isContextConsumer=T,le.isContextProvider=z,le.isElement=L,le.isForwardRef=B,le.isFragment=X,le.isLazy=q,le.isMemo=H,le.isPortal=G,le.isProfiler=K,le.isStrictMode=Z,le.isSuspense=ue,le.isValidElementType=j,le.typeOf=E}()),le}var da;function Ks(){return da||(da=1,process.env.NODE_ENV==="production"?zn.exports=Nd():zn.exports=kd()),zn.exports}/* + */var ca;function kd(){return ca||(ca=1,process.env.NODE_ENV!=="production"&&function(){var e=typeof Symbol=="function"&&Symbol.for,t=e?Symbol.for("react.element"):60103,n=e?Symbol.for("react.portal"):60106,r=e?Symbol.for("react.fragment"):60107,o=e?Symbol.for("react.strict_mode"):60108,s=e?Symbol.for("react.profiler"):60114,i=e?Symbol.for("react.provider"):60109,l=e?Symbol.for("react.context"):60110,c=e?Symbol.for("react.async_mode"):60111,u=e?Symbol.for("react.concurrent_mode"):60111,d=e?Symbol.for("react.forward_ref"):60112,m=e?Symbol.for("react.suspense"):60113,w=e?Symbol.for("react.suspense_list"):60120,b=e?Symbol.for("react.memo"):60115,x=e?Symbol.for("react.lazy"):60116,f=e?Symbol.for("react.block"):60121,h=e?Symbol.for("react.fundamental"):60117,S=e?Symbol.for("react.responder"):60118,R=e?Symbol.for("react.scope"):60119;function j(I){return typeof I=="string"||typeof I=="function"||I===r||I===u||I===s||I===o||I===m||I===w||typeof I=="object"&&I!==null&&(I.$$typeof===x||I.$$typeof===b||I.$$typeof===i||I.$$typeof===l||I.$$typeof===d||I.$$typeof===h||I.$$typeof===S||I.$$typeof===R||I.$$typeof===f)}function E(I){if(typeof I=="object"&&I!==null){var ye=I.$$typeof;switch(ye){case t:var A=I.type;switch(A){case c:case u:case r:case s:case o:case m:return A;default:var xe=A&&A.$$typeof;switch(xe){case l:case d:case x:case b:case i:return xe;default:return ye}}case n:return ye}}}var v=c,P=u,V=l,U=i,C=t,_=d,k=r,D=x,$=b,J=n,Y=s,F=o,te=m,se=!1;function oe(I){return se||(se=!0,console.warn("The ReactIs.isAsyncMode() alias has been deprecated, and will be removed in React 17+. Update your code to use ReactIs.isConcurrentMode() instead. It has the exact same API.")),y(I)||E(I)===c}function y(I){return E(I)===u}function T(I){return E(I)===l}function z(I){return E(I)===i}function L(I){return typeof I=="object"&&I!==null&&I.$$typeof===t}function B(I){return E(I)===d}function X(I){return E(I)===r}function q(I){return E(I)===x}function H(I){return E(I)===b}function G(I){return E(I)===n}function K(I){return E(I)===s}function Z(I){return E(I)===o}function ue(I){return E(I)===m}le.AsyncMode=v,le.ConcurrentMode=P,le.ContextConsumer=V,le.ContextProvider=U,le.Element=C,le.ForwardRef=_,le.Fragment=k,le.Lazy=D,le.Memo=$,le.Portal=J,le.Profiler=Y,le.StrictMode=F,le.Suspense=te,le.isAsyncMode=oe,le.isConcurrentMode=y,le.isContextConsumer=T,le.isContextProvider=z,le.isElement=L,le.isForwardRef=B,le.isFragment=X,le.isLazy=q,le.isMemo=H,le.isPortal=G,le.isProfiler=K,le.isStrictMode=Z,le.isSuspense=ue,le.isValidElementType=j,le.typeOf=E}()),le}var da;function Ks(){return da||(da=1,process.env.NODE_ENV==="production"?zn.exports=Nd():zn.exports=kd()),zn.exports}/* object-assign (c) Sindre Sorhus @license MIT -*/var Ir,ua;function Sd(){if(ua)return Ir;ua=1;var e=Object.getOwnPropertySymbols,t=Object.prototype.hasOwnProperty,n=Object.prototype.propertyIsEnumerable;function r(s){if(s==null)throw new TypeError("Object.assign cannot be called with null or undefined");return Object(s)}function o(){try{if(!Object.assign)return!1;var s=new String("abc");if(s[5]="de",Object.getOwnPropertyNames(s)[0]==="5")return!1;for(var i={},l=0;l<10;l++)i["_"+String.fromCharCode(l)]=l;var c=Object.getOwnPropertyNames(i).map(function(u){return i[u]});if(c.join("")!=="0123456789")return!1;var d={};return"abcdefghijklmnopqrst".split("").forEach(function(u){d[u]=u}),Object.keys(Object.assign({},d)).join("")==="abcdefghijklmnopqrst"}catch{return!1}}return Ir=o()?Object.assign:function(s,i){for(var l,c=r(s),d,u=1;u1?s("Invalid arguments supplied to oneOf, expected an array, got "+arguments.length+" arguments. A common mistake is to write oneOf(x, y, z) instead of oneOf([x, y, z])."):s("Invalid argument supplied to oneOf, expected an array.")),i;function T(z,L,B,X,q){for(var H=z[L],G=0;G0?", expected one of type ["+K.join(", ")+"]":"";return new f("Invalid "+H+" `"+G+"` supplied to "+("`"+q+"`"+ye+"."))}return m(L)}function _(){function y(T,z,L,B,X){return J(T[z])?null:new f("Invalid "+B+" `"+X+"` supplied to "+("`"+L+"`, expected a ReactNode."))}return m(y)}function k(y,T,z,L,B){return new f((y||"React class")+": "+T+" type `"+z+"."+L+"` is invalid; it must be a function, usually from the `prop-types` package, but received `"+B+"`.")}function D(y){function T(z,L,B,X,q){var H=z[L],G=F(H);if(G!=="object")return new f("Invalid "+X+" `"+q+"` of type `"+G+"` "+("supplied to `"+B+"`, expected `object`."));for(var K in y){var Z=y[K];if(typeof Z!="function")return k(B,X,q,K,te(Z));var ue=Z(H,K,B,X,q+"."+K,n);if(ue)return ue}return null}return m(T)}function $(y){function T(z,L,B,X,q){var H=z[L],G=F(H);if(G!=="object")return new f("Invalid "+X+" `"+q+"` of type `"+G+"` "+("supplied to `"+B+"`, expected `object`."));var K=t({},z[L],y);for(var Z in K){var ue=y[Z];if(r(y,Z)&&typeof ue!="function")return k(B,X,q,Z,te(ue));if(!ue)return new f("Invalid "+X+" `"+q+"` key `"+Z+"` supplied to `"+B+"`.\nBad object: "+JSON.stringify(z[L],null," ")+` -Valid keys: `+JSON.stringify(Object.keys(y),null," "));var I=ue(H,Z,B,X,q+"."+Z,n);if(I)return I}return null}return m(T)}function J(y){switch(typeof y){case"number":case"string":case"undefined":return!0;case"boolean":return!y;case"object":if(Array.isArray(y))return y.every(J);if(y===null||l(y))return!0;var T=h(y);if(T){var z=T.call(y),L;if(T!==y.entries){for(;!(L=z.next()).done;)if(!J(L.value))return!1}else for(;!(L=z.next()).done;){var B=L.value;if(B&&!J(B[1]))return!1}}else return!1;return!0;default:return!1}}function Y(y,T){return y==="symbol"?!0:T?T["@@toStringTag"]==="Symbol"||typeof Symbol=="function"&&T instanceof Symbol:!1}function F(y){var T=typeof y;return Array.isArray(y)?"array":y instanceof RegExp?"object":Y(T,y)?"symbol":T}function te(y){if(typeof y>"u"||y===null)return""+y;var T=F(y);if(T==="object"){if(y instanceof Date)return"date";if(y instanceof RegExp)return"regexp"}return T}function se(y){var T=te(y);switch(T){case"array":case"object":return"an "+T;case"boolean":case"date":case"regexp":return"a "+T;default:return T}}function oe(y){return!y.constructor||!y.constructor.name?w:y.constructor.name}return b.checkPropTypes=o,b.resetWarningCache=o.resetWarningCache,b.PropTypes=b,b},Ar}var Br,ha;function Cd(){if(ha)return Br;ha=1;var e=No();function t(){}function n(){}return n.resetWarningCache=t,Br=function(){function r(i,l,c,d,u,h){if(h!==e){var w=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types");throw w.name="Invariant Violation",w}}r.isRequired=r;function o(){return r}var s={array:r,bigint:r,bool:r,func:r,number:r,object:r,string:r,symbol:r,any:r,arrayOf:o,element:r,elementType:r,instanceOf:o,node:r,objectOf:o,oneOf:o,oneOfType:o,shape:o,exact:o,checkPropTypes:n,resetWarningCache:t};return s.PropTypes=s,s},Br}if(process.env.NODE_ENV!=="production"){var Td=Ks(),Rd=!0;Kr.exports=jd()(Td.isElement,Rd)}else Kr.exports=Cd()();var Od=Kr.exports;const p=vd(Od);function _d(e){const{prototype:t={}}=e;return!!t.isReactComponent}function Zs(e,t,n,r,o){const s=e[t],i=o||t;if(s==null||typeof window>"u")return null;let l;const c=s.type;return typeof c=="function"&&!_d(c)&&(l="Did you accidentally use a plain function component for an element instead?"),l!==void 0?new Error(`Invalid ${r} \`${i}\` supplied to \`${n}\`. Expected an element that can hold a ref. ${l} For more information see https://mui.com/r/caveat-with-refs-guide`):null}const Qs=yo(p.element,Zs);Qs.isRequired=yo(p.element.isRequired,Zs);const ei=Qs,Pd="exact-prop: ​";function Id(e){return process.env.NODE_ENV==="production"?e:O({},e,{[Pd]:t=>{const n=Object.keys(t).filter(r=>!e.hasOwnProperty(r));return n.length>0?new Error(`The following props are not supported: ${n.map(r=>`\`${r}\``).join(", ")}. Please remove them.`):null}})}function zt(e){let t="https://mui.com/production-error/?code="+e;for(let n=1;n1?s("Invalid arguments supplied to oneOf, expected an array, got "+arguments.length+" arguments. A common mistake is to write oneOf(x, y, z) instead of oneOf([x, y, z])."):s("Invalid argument supplied to oneOf, expected an array.")),i;function T(z,L,B,X,q){for(var H=z[L],G=0;G0?", expected one of type ["+K.join(", ")+"]":"";return new f("Invalid "+H+" `"+G+"` supplied to "+("`"+q+"`"+ye+"."))}return h(L)}function _(){function y(T,z,L,B,X){return J(T[z])?null:new f("Invalid "+B+" `"+X+"` supplied to "+("`"+L+"`, expected a ReactNode."))}return h(y)}function k(y,T,z,L,B){return new f((y||"React class")+": "+T+" type `"+z+"."+L+"` is invalid; it must be a function, usually from the `prop-types` package, but received `"+B+"`.")}function D(y){function T(z,L,B,X,q){var H=z[L],G=F(H);if(G!=="object")return new f("Invalid "+X+" `"+q+"` of type `"+G+"` "+("supplied to `"+B+"`, expected `object`."));for(var K in y){var Z=y[K];if(typeof Z!="function")return k(B,X,q,K,te(Z));var ue=Z(H,K,B,X,q+"."+K,n);if(ue)return ue}return null}return h(T)}function $(y){function T(z,L,B,X,q){var H=z[L],G=F(H);if(G!=="object")return new f("Invalid "+X+" `"+q+"` of type `"+G+"` "+("supplied to `"+B+"`, expected `object`."));var K=t({},z[L],y);for(var Z in K){var ue=y[Z];if(r(y,Z)&&typeof ue!="function")return k(B,X,q,Z,te(ue));if(!ue)return new f("Invalid "+X+" `"+q+"` key `"+Z+"` supplied to `"+B+"`.\nBad object: "+JSON.stringify(z[L],null," ")+` +Valid keys: `+JSON.stringify(Object.keys(y),null," "));var I=ue(H,Z,B,X,q+"."+Z,n);if(I)return I}return null}return h(T)}function J(y){switch(typeof y){case"number":case"string":case"undefined":return!0;case"boolean":return!y;case"object":if(Array.isArray(y))return y.every(J);if(y===null||l(y))return!0;var T=m(y);if(T){var z=T.call(y),L;if(T!==y.entries){for(;!(L=z.next()).done;)if(!J(L.value))return!1}else for(;!(L=z.next()).done;){var B=L.value;if(B&&!J(B[1]))return!1}}else return!1;return!0;default:return!1}}function Y(y,T){return y==="symbol"?!0:T?T["@@toStringTag"]==="Symbol"||typeof Symbol=="function"&&T instanceof Symbol:!1}function F(y){var T=typeof y;return Array.isArray(y)?"array":y instanceof RegExp?"object":Y(T,y)?"symbol":T}function te(y){if(typeof y>"u"||y===null)return""+y;var T=F(y);if(T==="object"){if(y instanceof Date)return"date";if(y instanceof RegExp)return"regexp"}return T}function se(y){var T=te(y);switch(T){case"array":case"object":return"an "+T;case"boolean":case"date":case"regexp":return"a "+T;default:return T}}function oe(y){return!y.constructor||!y.constructor.name?w:y.constructor.name}return b.checkPropTypes=o,b.resetWarningCache=o.resetWarningCache,b.PropTypes=b,b},Ar}var Br,ha;function Cd(){if(ha)return Br;ha=1;var e=No();function t(){}function n(){}return n.resetWarningCache=t,Br=function(){function r(i,l,c,u,d,m){if(m!==e){var w=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types");throw w.name="Invariant Violation",w}}r.isRequired=r;function o(){return r}var s={array:r,bigint:r,bool:r,func:r,number:r,object:r,string:r,symbol:r,any:r,arrayOf:o,element:r,elementType:r,instanceOf:o,node:r,objectOf:o,oneOf:o,oneOfType:o,shape:o,exact:o,checkPropTypes:n,resetWarningCache:t};return s.PropTypes=s,s},Br}if(process.env.NODE_ENV!=="production"){var Td=Ks(),Rd=!0;Kr.exports=jd()(Td.isElement,Rd)}else Kr.exports=Cd()();var Od=Kr.exports;const p=vd(Od);function _d(e){const{prototype:t={}}=e;return!!t.isReactComponent}function Zs(e,t,n,r,o){const s=e[t],i=o||t;if(s==null||typeof window>"u")return null;let l;const c=s.type;return typeof c=="function"&&!_d(c)&&(l="Did you accidentally use a plain function component for an element instead?"),l!==void 0?new Error(`Invalid ${r} \`${i}\` supplied to \`${n}\`. Expected an element that can hold a ref. ${l} For more information see https://mui.com/r/caveat-with-refs-guide`):null}const Qs=yo(p.element,Zs);Qs.isRequired=yo(p.element.isRequired,Zs);const ei=Qs,Pd="exact-prop: ​";function Id(e){return process.env.NODE_ENV==="production"?e:O({},e,{[Pd]:t=>{const n=Object.keys(t).filter(r=>!e.hasOwnProperty(r));return n.length>0?new Error(`The following props are not supported: ${n.map(r=>`\`${r}\``).join(", ")}. Please remove them.`):null}})}function zt(e){let t="https://mui.com/production-error/?code="+e;for(let n=1;nn==null?t:function(...o){t.apply(this,o),n.apply(this,o)},()=>{})}function Ld(e,t=166){let n;function r(...o){const s=()=>{e.apply(this,o)};clearTimeout(n),n=setTimeout(s,t)}return r.clear=()=>{clearTimeout(n)},r}function Fd(e,t){return process.env.NODE_ENV==="production"?()=>null:(n,r,o,s,i)=>{const l=o||"<>",c=i||r;return typeof n[r]<"u"?new Error(`The ${s} \`${c}\` of \`${l}\` is deprecated. ${t}`):null}}function Gd(e,t){var n,r;return M.isValidElement(e)&&t.indexOf((n=e.type.muiName)!=null?n:(r=e.type)==null||(r=r._payload)==null||(r=r.value)==null?void 0:r.muiName)!==-1}function Kn(e){return e&&e.ownerDocument||document}function Ud(e){return Kn(e).defaultView||window}function qd(e,t){if(process.env.NODE_ENV==="production")return()=>null;const n=t?O({},t.propTypes):null;return o=>(s,i,l,c,d,...u)=>{const h=d||i,w=n==null?void 0:n[h];if(w){const b=w(s,i,l,c,d,...u);if(b)return b}return typeof s[i]<"u"&&!s[o]?new Error(`The prop \`${h}\` of \`${e}\` can only be used together with the \`${o}\` prop.`):null}}function Jn(e,t){typeof e=="function"?e(t):e&&(e.current=t)}const Hd=typeof window<"u"?M.useLayoutEffect:M.useEffect,Lt=Hd;let ya=0;function Xd(e){const[t,n]=M.useState(e),r=e||t;return M.useEffect(()=>{t==null&&(ya+=1,n(`mui-${ya}`))},[t]),r}const Na=M["useId".toString()];function ri(e){if(Na!==void 0){const t=Na();return e??t}return Xd(e)}function Yd(e,t,n,r,o){if(process.env.NODE_ENV==="production")return null;const s=o||t;return typeof e[t]<"u"?new Error(`The prop \`${s}\` is not supported. Please remove it.`):null}function oi({controlled:e,default:t,name:n,state:r="value"}){const{current:o}=M.useRef(e!==void 0),[s,i]=M.useState(t),l=o?e:s;if(process.env.NODE_ENV!=="production"){M.useEffect(()=>{o!==(e!==void 0)&&console.error([`MUI: A component is changing the ${o?"":"un"}controlled ${r} state of ${n} to be ${o?"un":""}controlled.`,"Elements should not switch from uncontrolled to controlled (or vice versa).",`Decide between using a controlled or uncontrolled ${n} element for the lifetime of the component.`,"The nature of the state is determined during the first render. It's considered controlled if the value is not `undefined`.","More info: https://fb.me/react-controlled-components"].join(` -`))},[r,n,e]);const{current:d}=M.useRef(t);M.useEffect(()=>{!o&&d!==t&&console.error([`MUI: A component is changing the default ${r} state of an uncontrolled ${n} after being initialized. To suppress this warning opt to use a controlled ${n}.`].join(` -`))},[JSON.stringify(t)])}const c=M.useCallback(d=>{o||i(d)},[]);return[l,c]}function Zr(e){const t=M.useRef(e);return Lt(()=>{t.current=e}),M.useRef((...n)=>(0,t.current)(...n)).current}function yt(...e){return M.useMemo(()=>e.every(t=>t==null)?null:t=>{e.forEach(n=>{Jn(n,t)})},e)}const ka={};function Wd(e,t){const n=M.useRef(ka);return n.current===ka&&(n.current=e(t)),n}const Kd=[];function Jd(e){M.useEffect(e,Kd)}class On{constructor(){this.currentId=null,this.clear=()=>{this.currentId!==null&&(clearTimeout(this.currentId),this.currentId=null)},this.disposeEffect=()=>this.clear}static create(){return new On}start(t,n){this.clear(),this.currentId=setTimeout(()=>{this.currentId=null,n()},t)}}function dn(){const e=Wd(On.create).current;return Jd(e.disposeEffect),e}let dr=!0,Qr=!1;const Zd=new On,Qd={text:!0,search:!0,url:!0,tel:!0,email:!0,password:!0,number:!0,date:!0,month:!0,week:!0,time:!0,datetime:!0,"datetime-local":!0};function eu(e){const{type:t,tagName:n}=e;return!!(n==="INPUT"&&Qd[t]&&!e.readOnly||n==="TEXTAREA"&&!e.readOnly||e.isContentEditable)}function tu(e){e.metaKey||e.altKey||e.ctrlKey||(dr=!0)}function Vr(){dr=!1}function nu(){this.visibilityState==="hidden"&&Qr&&(dr=!0)}function ru(e){e.addEventListener("keydown",tu,!0),e.addEventListener("mousedown",Vr,!0),e.addEventListener("pointerdown",Vr,!0),e.addEventListener("touchstart",Vr,!0),e.addEventListener("visibilitychange",nu,!0)}function ou(e){const{target:t}=e;try{return t.matches(":focus-visible")}catch{}return dr||eu(t)}function ai(){const e=M.useCallback(o=>{o!=null&&ru(o.ownerDocument)},[]),t=M.useRef(!1);function n(){return t.current?(Qr=!0,Zd.start(100,()=>{Qr=!1}),t.current=!1,!0):!1}function r(o){return ou(o)?(t.current=!0,!0):!1}return{isFocusVisibleRef:t,onFocus:r,onBlur:n,ref:e}}function si(e,t){const n=O({},t);return Object.keys(e).forEach(r=>{if(r.toString().match(/^(components|slots)$/))n[r]=O({},e[r],n[r]);else if(r.toString().match(/^(componentsProps|slotProps)$/)){const o=e[r]||{},s=t[r];n[r]={},!s||!Object.keys(s)?n[r]=o:!o||!Object.keys(o)?n[r]=s:(n[r]=O({},s),Object.keys(o).forEach(i=>{n[r][i]=si(o[i],s[i])}))}else n[r]===void 0&&(n[r]=e[r])}),n}function ko(e,t,n=void 0){const r={};return Object.keys(e).forEach(o=>{r[o]=e[o].reduce((s,i)=>{if(i){const l=t(i);l!==""&&s.push(l),n&&n[i]&&s.push(n[i])}return s},[]).join(" ")}),r}const Sa=e=>e,au=()=>{let e=Sa;return{configure(t){e=t},generate(t){return e(t)},reset(){e=Sa}}},su=au(),ii=su,li={active:"active",checked:"checked",completed:"completed",disabled:"disabled",error:"error",expanded:"expanded",focused:"focused",focusVisible:"focusVisible",open:"open",readOnly:"readOnly",required:"required",selected:"selected"};function ur(e,t,n="Mui"){const r=li[t];return r?`${n}-${r}`:`${ii.generate(e)}-${t}`}function ci(e,t,n="Mui"){const r={};return t.forEach(o=>{r[o]=ur(e,o,n)}),r}function iu(e,t=Number.MIN_SAFE_INTEGER,n=Number.MAX_SAFE_INTEGER){return Math.max(t,Math.min(e,n))}function Ne(e,t){if(e==null)return{};var n={},r=Object.keys(e),o,s;for(s=0;s=0)&&(n[o]=e[o]);return n}const lu=["values","unit","step"],cu=e=>{const t=Object.keys(e).map(n=>({key:n,val:e[n]}))||[];return t.sort((n,r)=>n.val-r.val),t.reduce((n,r)=>O({},n,{[r.key]:r.val}),{})};function du(e){const{values:t={xs:0,sm:600,md:900,lg:1200,xl:1536},unit:n="px",step:r=5}=e,o=Ne(e,lu),s=cu(t),i=Object.keys(s);function l(w){return`@media (min-width:${typeof t[w]=="number"?t[w]:w}${n})`}function c(w){return`@media (max-width:${(typeof t[w]=="number"?t[w]:w)-r/100}${n})`}function d(w,b){const x=i.indexOf(b);return`@media (min-width:${typeof t[w]=="number"?t[w]:w}${n}) and (max-width:${(x!==-1&&typeof t[i[x]]=="number"?t[i[x]]:b)-r/100}${n})`}function u(w){return i.indexOf(w)+1`@media (min-width:${So[e]}px)`};function et(e,t,n){const r=e.theme||{};if(Array.isArray(t)){const s=r.breakpoints||Ea;return t.reduce((i,l,c)=>(i[s.up(s.keys[c])]=n(t[c]),i),{})}if(typeof t=="object"){const s=r.breakpoints||Ea;return Object.keys(t).reduce((i,l)=>{if(Object.keys(s.values||So).indexOf(l)!==-1){const c=s.up(l);i[c]=n(t[l],l)}else{const c=l;i[c]=t[c]}return i},{})}return n(t)}function fu(e={}){var t;return((t=e.keys)==null?void 0:t.reduce((r,o)=>{const s=e.up(o);return r[s]={},r},{}))||{}}function mu(e,t){return e.reduce((n,r)=>{const o=n[r];return(!o||Object.keys(o).length===0)&&delete n[r],n},t)}function pr(e,t,n=!0){if(!t||typeof t!="string")return null;if(e&&e.vars&&n){const r=`vars.${t}`.split(".").reduce((o,s)=>o&&o[s]?o[s]:null,e);if(r!=null)return r}return t.split(".").reduce((r,o)=>r&&r[o]!=null?r[o]:null,e)}function Zn(e,t,n,r=n){let o;return typeof e=="function"?o=e(n):Array.isArray(e)?o=e[n]||r:o=pr(e,n)||r,t&&(o=t(o,r,e)),o}function ve(e){const{prop:t,cssProperty:n=e.prop,themeKey:r,transform:o}=e,s=i=>{if(i[t]==null)return null;const l=i[t],c=i.theme,d=pr(c,r)||{};return et(i,l,h=>{let w=Zn(d,o,h);return h===w&&typeof h=="string"&&(w=Zn(d,o,`${t}${h==="default"?"":Ye(h)}`,h)),n===!1?w:{[n]:w}})};return s.propTypes=process.env.NODE_ENV!=="production"?{[t]:st}:{},s.filterProps=[t],s}function hu(e){const t={};return n=>(t[n]===void 0&&(t[n]=e(n)),t[n])}const gu={m:"margin",p:"padding"},bu={t:"Top",r:"Right",b:"Bottom",l:"Left",x:["Left","Right"],y:["Top","Bottom"]},ja={marginX:"mx",marginY:"my",paddingX:"px",paddingY:"py"},vu=hu(e=>{if(e.length>2)if(ja[e])e=ja[e];else return[e];const[t,n]=e.split(""),r=gu[t],o=bu[n]||"";return Array.isArray(o)?o.map(s=>r+s):[r+o]}),wr=["m","mt","mr","mb","ml","mx","my","margin","marginTop","marginRight","marginBottom","marginLeft","marginX","marginY","marginInline","marginInlineStart","marginInlineEnd","marginBlock","marginBlockStart","marginBlockEnd"],fr=["p","pt","pr","pb","pl","px","py","padding","paddingTop","paddingRight","paddingBottom","paddingLeft","paddingX","paddingY","paddingInline","paddingInlineStart","paddingInlineEnd","paddingBlock","paddingBlockStart","paddingBlockEnd"],xu=[...wr,...fr];function _n(e,t,n,r){var o;const s=(o=pr(e,t,!1))!=null?o:n;return typeof s=="number"?i=>typeof i=="string"?i:(process.env.NODE_ENV!=="production"&&typeof i!="number"&&console.error(`MUI: Expected ${r} argument to be a number or a string, got ${i}.`),s*i):Array.isArray(s)?i=>typeof i=="string"?i:(process.env.NODE_ENV!=="production"&&(Number.isInteger(i)?i>s.length-1&&console.error([`MUI: The value provided (${i}) overflows.`,`The supported values are: ${JSON.stringify(s)}.`,`${i} > ${s.length-1}, you need to add the missing values.`].join(` + */var ba;function $d(){return ba||(ba=1,process.env.NODE_ENV!=="production"&&function(){var e=Symbol.for("react.element"),t=Symbol.for("react.portal"),n=Symbol.for("react.fragment"),r=Symbol.for("react.strict_mode"),o=Symbol.for("react.profiler"),s=Symbol.for("react.provider"),i=Symbol.for("react.context"),l=Symbol.for("react.server_context"),c=Symbol.for("react.forward_ref"),u=Symbol.for("react.suspense"),d=Symbol.for("react.suspense_list"),m=Symbol.for("react.memo"),w=Symbol.for("react.lazy"),b=Symbol.for("react.offscreen"),x=!1,f=!1,h=!1,S=!1,R=!1,j;j=Symbol.for("react.module.reference");function E(A){return!!(typeof A=="string"||typeof A=="function"||A===n||A===o||R||A===r||A===u||A===d||S||A===b||x||f||h||typeof A=="object"&&A!==null&&(A.$$typeof===w||A.$$typeof===m||A.$$typeof===s||A.$$typeof===i||A.$$typeof===c||A.$$typeof===j||A.getModuleId!==void 0))}function v(A){if(typeof A=="object"&&A!==null){var xe=A.$$typeof;switch(xe){case e:var Ge=A.type;switch(Ge){case n:case o:case r:case u:case d:return Ge;default:var lt=Ge&&Ge.$$typeof;switch(lt){case l:case i:case c:case w:case m:case s:return lt;default:return xe}}case t:return xe}}}var P=i,V=s,U=e,C=c,_=n,k=w,D=m,$=t,J=o,Y=r,F=u,te=d,se=!1,oe=!1;function y(A){return se||(se=!0,console.warn("The ReactIs.isAsyncMode() alias has been deprecated, and will be removed in React 18+.")),!1}function T(A){return oe||(oe=!0,console.warn("The ReactIs.isConcurrentMode() alias has been deprecated, and will be removed in React 18+.")),!1}function z(A){return v(A)===i}function L(A){return v(A)===s}function B(A){return typeof A=="object"&&A!==null&&A.$$typeof===e}function X(A){return v(A)===c}function q(A){return v(A)===n}function H(A){return v(A)===w}function G(A){return v(A)===m}function K(A){return v(A)===t}function Z(A){return v(A)===o}function ue(A){return v(A)===r}function I(A){return v(A)===u}function ye(A){return v(A)===d}de.ContextConsumer=P,de.ContextProvider=V,de.Element=U,de.ForwardRef=C,de.Fragment=_,de.Lazy=k,de.Memo=D,de.Portal=$,de.Profiler=J,de.StrictMode=Y,de.Suspense=F,de.SuspenseList=te,de.isAsyncMode=y,de.isConcurrentMode=T,de.isContextConsumer=z,de.isContextProvider=L,de.isElement=B,de.isForwardRef=X,de.isFragment=q,de.isLazy=H,de.isMemo=G,de.isPortal=K,de.isProfiler=Z,de.isStrictMode=ue,de.isSuspense=I,de.isSuspenseList=ye,de.isValidElementType=E,de.typeOf=v}()),de}process.env.NODE_ENV==="production"?Jr.exports=Md():Jr.exports=$d();var va=Jr.exports;const Dd=/^\s*function(?:\s|\s*\/\*.*\*\/\s*)+([^(\s/]*)\s*/;function Ad(e){const t=`${e}`.match(Dd);return t&&t[1]||""}function ti(e,t=""){return e.displayName||e.name||Ad(e)||t}function xa(e,t,n){const r=ti(t);return e.displayName||(r!==""?`${n}(${r})`:n)}function Bd(e){if(e!=null){if(typeof e=="string")return e;if(typeof e=="function")return ti(e,"Component");if(typeof e=="object")switch(e.$$typeof){case va.ForwardRef:return xa(e,e.render,"ForwardRef");case va.Memo:return xa(e,e.type,"memo");default:return}}}function xn(e,t,n,r,o){if(process.env.NODE_ENV==="production")return null;const s=e[t],i=o||t;return s==null?null:s&&s.nodeType!==1?new Error(`Invalid ${r} \`${i}\` supplied to \`${n}\`. Expected an HTMLElement.`):null}const Vd=p.oneOfType([p.func,p.object]),ni=Vd;function Ye(e){if(typeof e!="string")throw new Error(process.env.NODE_ENV!=="production"?"MUI: `capitalize(string)` expects a string argument.":zt(7));return e.charAt(0).toUpperCase()+e.slice(1)}function zd(...e){return e.reduce((t,n)=>n==null?t:function(...o){t.apply(this,o),n.apply(this,o)},()=>{})}function Ld(e,t=166){let n;function r(...o){const s=()=>{e.apply(this,o)};clearTimeout(n),n=setTimeout(s,t)}return r.clear=()=>{clearTimeout(n)},r}function Fd(e,t){return process.env.NODE_ENV==="production"?()=>null:(n,r,o,s,i)=>{const l=o||"<>",c=i||r;return typeof n[r]<"u"?new Error(`The ${s} \`${c}\` of \`${l}\` is deprecated. ${t}`):null}}function Gd(e,t){var n,r;return M.isValidElement(e)&&t.indexOf((n=e.type.muiName)!=null?n:(r=e.type)==null||(r=r._payload)==null||(r=r.value)==null?void 0:r.muiName)!==-1}function Kn(e){return e&&e.ownerDocument||document}function Ud(e){return Kn(e).defaultView||window}function qd(e,t){if(process.env.NODE_ENV==="production")return()=>null;const n=t?O({},t.propTypes):null;return o=>(s,i,l,c,u,...d)=>{const m=u||i,w=n==null?void 0:n[m];if(w){const b=w(s,i,l,c,u,...d);if(b)return b}return typeof s[i]<"u"&&!s[o]?new Error(`The prop \`${m}\` of \`${e}\` can only be used together with the \`${o}\` prop.`):null}}function Jn(e,t){typeof e=="function"?e(t):e&&(e.current=t)}const Hd=typeof window<"u"?M.useLayoutEffect:M.useEffect,Lt=Hd;let ya=0;function Xd(e){const[t,n]=M.useState(e),r=e||t;return M.useEffect(()=>{t==null&&(ya+=1,n(`mui-${ya}`))},[t]),r}const Na=M["useId".toString()];function ri(e){if(Na!==void 0){const t=Na();return e??t}return Xd(e)}function Yd(e,t,n,r,o){if(process.env.NODE_ENV==="production")return null;const s=o||t;return typeof e[t]<"u"?new Error(`The prop \`${s}\` is not supported. Please remove it.`):null}function oi({controlled:e,default:t,name:n,state:r="value"}){const{current:o}=M.useRef(e!==void 0),[s,i]=M.useState(t),l=o?e:s;if(process.env.NODE_ENV!=="production"){M.useEffect(()=>{o!==(e!==void 0)&&console.error([`MUI: A component is changing the ${o?"":"un"}controlled ${r} state of ${n} to be ${o?"un":""}controlled.`,"Elements should not switch from uncontrolled to controlled (or vice versa).",`Decide between using a controlled or uncontrolled ${n} element for the lifetime of the component.`,"The nature of the state is determined during the first render. It's considered controlled if the value is not `undefined`.","More info: https://fb.me/react-controlled-components"].join(` +`))},[r,n,e]);const{current:u}=M.useRef(t);M.useEffect(()=>{!o&&u!==t&&console.error([`MUI: A component is changing the default ${r} state of an uncontrolled ${n} after being initialized. To suppress this warning opt to use a controlled ${n}.`].join(` +`))},[JSON.stringify(t)])}const c=M.useCallback(u=>{o||i(u)},[]);return[l,c]}function Zr(e){const t=M.useRef(e);return Lt(()=>{t.current=e}),M.useRef((...n)=>(0,t.current)(...n)).current}function yt(...e){return M.useMemo(()=>e.every(t=>t==null)?null:t=>{e.forEach(n=>{Jn(n,t)})},e)}const ka={};function Wd(e,t){const n=M.useRef(ka);return n.current===ka&&(n.current=e(t)),n}const Kd=[];function Jd(e){M.useEffect(e,Kd)}class On{constructor(){this.currentId=null,this.clear=()=>{this.currentId!==null&&(clearTimeout(this.currentId),this.currentId=null)},this.disposeEffect=()=>this.clear}static create(){return new On}start(t,n){this.clear(),this.currentId=setTimeout(()=>{this.currentId=null,n()},t)}}function dn(){const e=Wd(On.create).current;return Jd(e.disposeEffect),e}let dr=!0,Qr=!1;const Zd=new On,Qd={text:!0,search:!0,url:!0,tel:!0,email:!0,password:!0,number:!0,date:!0,month:!0,week:!0,time:!0,datetime:!0,"datetime-local":!0};function eu(e){const{type:t,tagName:n}=e;return!!(n==="INPUT"&&Qd[t]&&!e.readOnly||n==="TEXTAREA"&&!e.readOnly||e.isContentEditable)}function tu(e){e.metaKey||e.altKey||e.ctrlKey||(dr=!0)}function Vr(){dr=!1}function nu(){this.visibilityState==="hidden"&&Qr&&(dr=!0)}function ru(e){e.addEventListener("keydown",tu,!0),e.addEventListener("mousedown",Vr,!0),e.addEventListener("pointerdown",Vr,!0),e.addEventListener("touchstart",Vr,!0),e.addEventListener("visibilitychange",nu,!0)}function ou(e){const{target:t}=e;try{return t.matches(":focus-visible")}catch{}return dr||eu(t)}function ai(){const e=M.useCallback(o=>{o!=null&&ru(o.ownerDocument)},[]),t=M.useRef(!1);function n(){return t.current?(Qr=!0,Zd.start(100,()=>{Qr=!1}),t.current=!1,!0):!1}function r(o){return ou(o)?(t.current=!0,!0):!1}return{isFocusVisibleRef:t,onFocus:r,onBlur:n,ref:e}}function si(e,t){const n=O({},t);return Object.keys(e).forEach(r=>{if(r.toString().match(/^(components|slots)$/))n[r]=O({},e[r],n[r]);else if(r.toString().match(/^(componentsProps|slotProps)$/)){const o=e[r]||{},s=t[r];n[r]={},!s||!Object.keys(s)?n[r]=o:!o||!Object.keys(o)?n[r]=s:(n[r]=O({},s),Object.keys(o).forEach(i=>{n[r][i]=si(o[i],s[i])}))}else n[r]===void 0&&(n[r]=e[r])}),n}function ko(e,t,n=void 0){const r={};return Object.keys(e).forEach(o=>{r[o]=e[o].reduce((s,i)=>{if(i){const l=t(i);l!==""&&s.push(l),n&&n[i]&&s.push(n[i])}return s},[]).join(" ")}),r}const Sa=e=>e,au=()=>{let e=Sa;return{configure(t){e=t},generate(t){return e(t)},reset(){e=Sa}}},su=au(),ii=su,li={active:"active",checked:"checked",completed:"completed",disabled:"disabled",error:"error",expanded:"expanded",focused:"focused",focusVisible:"focusVisible",open:"open",readOnly:"readOnly",required:"required",selected:"selected"};function ur(e,t,n="Mui"){const r=li[t];return r?`${n}-${r}`:`${ii.generate(e)}-${t}`}function ci(e,t,n="Mui"){const r={};return t.forEach(o=>{r[o]=ur(e,o,n)}),r}function iu(e,t=Number.MIN_SAFE_INTEGER,n=Number.MAX_SAFE_INTEGER){return Math.max(t,Math.min(e,n))}function Ne(e,t){if(e==null)return{};var n={},r=Object.keys(e),o,s;for(s=0;s=0)&&(n[o]=e[o]);return n}const lu=["values","unit","step"],cu=e=>{const t=Object.keys(e).map(n=>({key:n,val:e[n]}))||[];return t.sort((n,r)=>n.val-r.val),t.reduce((n,r)=>O({},n,{[r.key]:r.val}),{})};function du(e){const{values:t={xs:0,sm:600,md:900,lg:1200,xl:1536},unit:n="px",step:r=5}=e,o=Ne(e,lu),s=cu(t),i=Object.keys(s);function l(w){return`@media (min-width:${typeof t[w]=="number"?t[w]:w}${n})`}function c(w){return`@media (max-width:${(typeof t[w]=="number"?t[w]:w)-r/100}${n})`}function u(w,b){const x=i.indexOf(b);return`@media (min-width:${typeof t[w]=="number"?t[w]:w}${n}) and (max-width:${(x!==-1&&typeof t[i[x]]=="number"?t[i[x]]:b)-r/100}${n})`}function d(w){return i.indexOf(w)+1`@media (min-width:${So[e]}px)`};function et(e,t,n){const r=e.theme||{};if(Array.isArray(t)){const s=r.breakpoints||Ea;return t.reduce((i,l,c)=>(i[s.up(s.keys[c])]=n(t[c]),i),{})}if(typeof t=="object"){const s=r.breakpoints||Ea;return Object.keys(t).reduce((i,l)=>{if(Object.keys(s.values||So).indexOf(l)!==-1){const c=s.up(l);i[c]=n(t[l],l)}else{const c=l;i[c]=t[c]}return i},{})}return n(t)}function fu(e={}){var t;return((t=e.keys)==null?void 0:t.reduce((r,o)=>{const s=e.up(o);return r[s]={},r},{}))||{}}function mu(e,t){return e.reduce((n,r)=>{const o=n[r];return(!o||Object.keys(o).length===0)&&delete n[r],n},t)}function pr(e,t,n=!0){if(!t||typeof t!="string")return null;if(e&&e.vars&&n){const r=`vars.${t}`.split(".").reduce((o,s)=>o&&o[s]?o[s]:null,e);if(r!=null)return r}return t.split(".").reduce((r,o)=>r&&r[o]!=null?r[o]:null,e)}function Zn(e,t,n,r=n){let o;return typeof e=="function"?o=e(n):Array.isArray(e)?o=e[n]||r:o=pr(e,n)||r,t&&(o=t(o,r,e)),o}function ve(e){const{prop:t,cssProperty:n=e.prop,themeKey:r,transform:o}=e,s=i=>{if(i[t]==null)return null;const l=i[t],c=i.theme,u=pr(c,r)||{};return et(i,l,m=>{let w=Zn(u,o,m);return m===w&&typeof m=="string"&&(w=Zn(u,o,`${t}${m==="default"?"":Ye(m)}`,m)),n===!1?w:{[n]:w}})};return s.propTypes=process.env.NODE_ENV!=="production"?{[t]:st}:{},s.filterProps=[t],s}function hu(e){const t={};return n=>(t[n]===void 0&&(t[n]=e(n)),t[n])}const gu={m:"margin",p:"padding"},bu={t:"Top",r:"Right",b:"Bottom",l:"Left",x:["Left","Right"],y:["Top","Bottom"]},ja={marginX:"mx",marginY:"my",paddingX:"px",paddingY:"py"},vu=hu(e=>{if(e.length>2)if(ja[e])e=ja[e];else return[e];const[t,n]=e.split(""),r=gu[t],o=bu[n]||"";return Array.isArray(o)?o.map(s=>r+s):[r+o]}),wr=["m","mt","mr","mb","ml","mx","my","margin","marginTop","marginRight","marginBottom","marginLeft","marginX","marginY","marginInline","marginInlineStart","marginInlineEnd","marginBlock","marginBlockStart","marginBlockEnd"],fr=["p","pt","pr","pb","pl","px","py","padding","paddingTop","paddingRight","paddingBottom","paddingLeft","paddingX","paddingY","paddingInline","paddingInlineStart","paddingInlineEnd","paddingBlock","paddingBlockStart","paddingBlockEnd"],xu=[...wr,...fr];function _n(e,t,n,r){var o;const s=(o=pr(e,t,!1))!=null?o:n;return typeof s=="number"?i=>typeof i=="string"?i:(process.env.NODE_ENV!=="production"&&typeof i!="number"&&console.error(`MUI: Expected ${r} argument to be a number or a string, got ${i}.`),s*i):Array.isArray(s)?i=>typeof i=="string"?i:(process.env.NODE_ENV!=="production"&&(Number.isInteger(i)?i>s.length-1&&console.error([`MUI: The value provided (${i}) overflows.`,`The supported values are: ${JSON.stringify(s)}.`,`${i} > ${s.length-1}, you need to add the missing values.`].join(` `)):console.error([`MUI: The \`theme.${t}\` array type cannot be combined with non integer values.You should either use an integer value that can be used as index, or define the \`theme.${t}\` as a number.`].join(` `))),s[i]):typeof s=="function"?s:(process.env.NODE_ENV!=="production"&&console.error([`MUI: The \`theme.${t}\` value (${s}) is invalid.`,"It should be a number, an array or a function."].join(` -`)),()=>{})}function di(e){return _n(e,"spacing",8,"spacing")}function Pn(e,t){if(typeof t=="string"||t==null)return t;const n=Math.abs(t),r=e(n);return t>=0?r:typeof r=="number"?-r:`-${r}`}function yu(e,t){return n=>e.reduce((r,o)=>(r[o]=Pn(t,n),r),{})}function Nu(e,t,n,r){if(t.indexOf(n)===-1)return null;const o=vu(n),s=yu(o,r),i=e[n];return et(e,i,s)}function ui(e,t){const n=di(e.theme);return Object.keys(e).map(r=>Nu(e,t,r,n)).reduce(mn,{})}function me(e){return ui(e,wr)}me.propTypes=process.env.NODE_ENV!=="production"?wr.reduce((e,t)=>(e[t]=st,e),{}):{};me.filterProps=wr;function he(e){return ui(e,fr)}he.propTypes=process.env.NODE_ENV!=="production"?fr.reduce((e,t)=>(e[t]=st,e),{}):{};he.filterProps=fr;process.env.NODE_ENV!=="production"&&xu.reduce((e,t)=>(e[t]=st,e),{});function ku(e=8){if(e.mui)return e;const t=di({spacing:e}),n=(...r)=>(process.env.NODE_ENV!=="production"&&(r.length<=4||console.error(`MUI: Too many arguments provided, expected between 0 and 4, got ${r.length}`)),(r.length===0?[1]:r).map(s=>{const i=t(s);return typeof i=="number"?`${i}px`:i}).join(" "));return n.mui=!0,n}function mr(...e){const t=e.reduce((r,o)=>(o.filterProps.forEach(s=>{r[s]=o}),r),{}),n=r=>Object.keys(r).reduce((o,s)=>t[s]?mn(o,t[s](r)):o,{});return n.propTypes=process.env.NODE_ENV!=="production"?e.reduce((r,o)=>Object.assign(r,o.propTypes),{}):{},n.filterProps=e.reduce((r,o)=>r.concat(o.filterProps),[]),n}function Be(e){return typeof e!="number"?e:`${e}px solid`}function Fe(e,t){return ve({prop:e,themeKey:"borders",transform:t})}const Su=Fe("border",Be),Eu=Fe("borderTop",Be),ju=Fe("borderRight",Be),Cu=Fe("borderBottom",Be),Tu=Fe("borderLeft",Be),Ru=Fe("borderColor"),Ou=Fe("borderTopColor"),_u=Fe("borderRightColor"),Pu=Fe("borderBottomColor"),Iu=Fe("borderLeftColor"),Mu=Fe("outline",Be),$u=Fe("outlineColor"),hr=e=>{if(e.borderRadius!==void 0&&e.borderRadius!==null){const t=_n(e.theme,"shape.borderRadius",4,"borderRadius"),n=r=>({borderRadius:Pn(t,r)});return et(e,e.borderRadius,n)}return null};hr.propTypes=process.env.NODE_ENV!=="production"?{borderRadius:st}:{};hr.filterProps=["borderRadius"];mr(Su,Eu,ju,Cu,Tu,Ru,Ou,_u,Pu,Iu,hr,Mu,$u);const gr=e=>{if(e.gap!==void 0&&e.gap!==null){const t=_n(e.theme,"spacing",8,"gap"),n=r=>({gap:Pn(t,r)});return et(e,e.gap,n)}return null};gr.propTypes=process.env.NODE_ENV!=="production"?{gap:st}:{};gr.filterProps=["gap"];const br=e=>{if(e.columnGap!==void 0&&e.columnGap!==null){const t=_n(e.theme,"spacing",8,"columnGap"),n=r=>({columnGap:Pn(t,r)});return et(e,e.columnGap,n)}return null};br.propTypes=process.env.NODE_ENV!=="production"?{columnGap:st}:{};br.filterProps=["columnGap"];const vr=e=>{if(e.rowGap!==void 0&&e.rowGap!==null){const t=_n(e.theme,"spacing",8,"rowGap"),n=r=>({rowGap:Pn(t,r)});return et(e,e.rowGap,n)}return null};vr.propTypes=process.env.NODE_ENV!=="production"?{rowGap:st}:{};vr.filterProps=["rowGap"];const Du=ve({prop:"gridColumn"}),Au=ve({prop:"gridRow"}),Bu=ve({prop:"gridAutoFlow"}),Vu=ve({prop:"gridAutoColumns"}),zu=ve({prop:"gridAutoRows"}),Lu=ve({prop:"gridTemplateColumns"}),Fu=ve({prop:"gridTemplateRows"}),Gu=ve({prop:"gridTemplateAreas"}),Uu=ve({prop:"gridArea"});mr(gr,br,vr,Du,Au,Bu,Vu,zu,Lu,Fu,Gu,Uu);function Dt(e,t){return t==="grey"?t:e}const qu=ve({prop:"color",themeKey:"palette",transform:Dt}),Hu=ve({prop:"bgcolor",cssProperty:"backgroundColor",themeKey:"palette",transform:Dt}),Xu=ve({prop:"backgroundColor",themeKey:"palette",transform:Dt});mr(qu,Hu,Xu);function Ie(e){return e<=1&&e!==0?`${e*100}%`:e}const Yu=ve({prop:"width",transform:Ie}),Eo=e=>{if(e.maxWidth!==void 0&&e.maxWidth!==null){const t=n=>{var r,o;const s=((r=e.theme)==null||(r=r.breakpoints)==null||(r=r.values)==null?void 0:r[n])||So[n];return s?((o=e.theme)==null||(o=o.breakpoints)==null?void 0:o.unit)!=="px"?{maxWidth:`${s}${e.theme.breakpoints.unit}`}:{maxWidth:s}:{maxWidth:Ie(n)}};return et(e,e.maxWidth,t)}return null};Eo.filterProps=["maxWidth"];const Wu=ve({prop:"minWidth",transform:Ie}),Ku=ve({prop:"height",transform:Ie}),Ju=ve({prop:"maxHeight",transform:Ie}),Zu=ve({prop:"minHeight",transform:Ie});ve({prop:"size",cssProperty:"width",transform:Ie});ve({prop:"size",cssProperty:"height",transform:Ie});const Qu=ve({prop:"boxSizing"});mr(Yu,Eo,Wu,Ku,Ju,Zu,Qu);const ep={border:{themeKey:"borders",transform:Be},borderTop:{themeKey:"borders",transform:Be},borderRight:{themeKey:"borders",transform:Be},borderBottom:{themeKey:"borders",transform:Be},borderLeft:{themeKey:"borders",transform:Be},borderColor:{themeKey:"palette"},borderTopColor:{themeKey:"palette"},borderRightColor:{themeKey:"palette"},borderBottomColor:{themeKey:"palette"},borderLeftColor:{themeKey:"palette"},outline:{themeKey:"borders",transform:Be},outlineColor:{themeKey:"palette"},borderRadius:{themeKey:"shape.borderRadius",style:hr},color:{themeKey:"palette",transform:Dt},bgcolor:{themeKey:"palette",cssProperty:"backgroundColor",transform:Dt},backgroundColor:{themeKey:"palette",transform:Dt},p:{style:he},pt:{style:he},pr:{style:he},pb:{style:he},pl:{style:he},px:{style:he},py:{style:he},padding:{style:he},paddingTop:{style:he},paddingRight:{style:he},paddingBottom:{style:he},paddingLeft:{style:he},paddingX:{style:he},paddingY:{style:he},paddingInline:{style:he},paddingInlineStart:{style:he},paddingInlineEnd:{style:he},paddingBlock:{style:he},paddingBlockStart:{style:he},paddingBlockEnd:{style:he},m:{style:me},mt:{style:me},mr:{style:me},mb:{style:me},ml:{style:me},mx:{style:me},my:{style:me},margin:{style:me},marginTop:{style:me},marginRight:{style:me},marginBottom:{style:me},marginLeft:{style:me},marginX:{style:me},marginY:{style:me},marginInline:{style:me},marginInlineStart:{style:me},marginInlineEnd:{style:me},marginBlock:{style:me},marginBlockStart:{style:me},marginBlockEnd:{style:me},displayPrint:{cssProperty:!1,transform:e=>({"@media print":{display:e}})},display:{},overflow:{},textOverflow:{},visibility:{},whiteSpace:{},flexBasis:{},flexDirection:{},flexWrap:{},justifyContent:{},alignItems:{},alignContent:{},order:{},flex:{},flexGrow:{},flexShrink:{},alignSelf:{},justifyItems:{},justifySelf:{},gap:{style:gr},rowGap:{style:vr},columnGap:{style:br},gridColumn:{},gridRow:{},gridAutoFlow:{},gridAutoColumns:{},gridAutoRows:{},gridTemplateColumns:{},gridTemplateRows:{},gridTemplateAreas:{},gridArea:{},position:{},zIndex:{themeKey:"zIndex"},top:{},right:{},bottom:{},left:{},boxShadow:{themeKey:"shadows"},width:{transform:Ie},maxWidth:{style:Eo},minWidth:{transform:Ie},height:{transform:Ie},maxHeight:{transform:Ie},minHeight:{transform:Ie},boxSizing:{},fontFamily:{themeKey:"typography"},fontSize:{themeKey:"typography"},fontStyle:{themeKey:"typography"},fontWeight:{themeKey:"typography"},letterSpacing:{},textTransform:{},lineHeight:{},textAlign:{},typography:{cssProperty:!1,themeKey:"typography"}},jo=ep;function tp(...e){const t=e.reduce((r,o)=>r.concat(Object.keys(o)),[]),n=new Set(t);return e.every(r=>n.size===Object.keys(r).length)}function np(e,t){return typeof e=="function"?e(t):e}function rp(){function e(n,r,o,s){const i={[n]:r,theme:o},l=s[n];if(!l)return{[n]:r};const{cssProperty:c=n,themeKey:d,transform:u,style:h}=l;if(r==null)return null;if(d==="typography"&&r==="inherit")return{[n]:r};const w=pr(o,d)||{};return h?h(i):et(i,r,x=>{let f=Zn(w,u,x);return x===f&&typeof x=="string"&&(f=Zn(w,u,`${n}${x==="default"?"":Ye(x)}`,x)),c===!1?f:{[c]:f}})}function t(n){var r;const{sx:o,theme:s={}}=n||{};if(!o)return null;const i=(r=s.unstable_sxConfig)!=null?r:jo;function l(c){let d=c;if(typeof c=="function")d=c(s);else if(typeof c!="object")return c;if(!d)return null;const u=fu(s.breakpoints),h=Object.keys(u);let w=u;return Object.keys(d).forEach(b=>{const x=np(d[b],s);if(x!=null)if(typeof x=="object")if(i[b])w=mn(w,e(b,x,s,i));else{const f=et({theme:s},x,m=>({[b]:m}));tp(f,x)?w[b]=t({sx:x,theme:s}):w=mn(w,f)}else w=mn(w,e(b,x,s,i))}),mu(h,w)}return Array.isArray(o)?o.map(l):l(o)}return t}const pi=rp();pi.filterProps=["sx"];const Co=pi;function op(e,t){const n=this;return n.vars&&typeof n.getColorSchemeSelector=="function"?{[n.getColorSchemeSelector(e).replace(/(\[[^\]]+\])/,"*:where($1)")]:t}:n.palette.mode===e?t:{}}const ap=["breakpoints","palette","spacing","shape"];function To(e={},...t){const{breakpoints:n={},palette:r={},spacing:o,shape:s={}}=e,i=Ne(e,ap),l=du(n),c=ku(o);let d=Qe({breakpoints:l,direction:"ltr",components:{},palette:O({mode:"light"},r),spacing:c,shape:O({},pu,s)},i);return d.applyStyles=op,d=t.reduce((u,h)=>Qe(u,h),d),d.unstable_sxConfig=O({},jo,i==null?void 0:i.unstable_sxConfig),d.unstable_sx=function(h){return Co({sx:h,theme:this})},d}function sp(e){return Object.keys(e).length===0}function wi(e=null){const t=M.useContext(Gr.ThemeContext);return!t||sp(t)?e:t}const ip=To();function fi(e=ip){return wi(e)}const lp=["ownerState"],cp=["variants"],dp=["name","slot","skipVariantsResolver","skipSx","overridesResolver"];function up(e){return Object.keys(e).length===0}function pp(e){return typeof e=="string"&&e.charCodeAt(0)>96}function qn(e){return e!=="ownerState"&&e!=="theme"&&e!=="sx"&&e!=="as"}const wp=To(),Ca=e=>e&&e.charAt(0).toLowerCase()+e.slice(1);function Ln({defaultTheme:e,theme:t,themeId:n}){return up(t)?e:t[n]||t}function fp(e){return e?(t,n)=>n[e]:null}function Hn(e,t){let{ownerState:n}=t,r=Ne(t,lp);const o=typeof e=="function"?e(O({ownerState:n},r)):e;if(Array.isArray(o))return o.flatMap(s=>Hn(s,O({ownerState:n},r)));if(o&&typeof o=="object"&&Array.isArray(o.variants)){const{variants:s=[]}=o;let l=Ne(o,cp);return s.forEach(c=>{let d=!0;typeof c.props=="function"?d=c.props(O({ownerState:n},r,n)):Object.keys(c.props).forEach(u=>{(n==null?void 0:n[u])!==c.props[u]&&r[u]!==c.props[u]&&(d=!1)}),d&&(Array.isArray(l)||(l=[l]),l.push(typeof c.style=="function"?c.style(O({ownerState:n},r,n)):c.style))}),l}return o}function mp(e={}){const{themeId:t,defaultTheme:n=wp,rootShouldForwardProp:r=qn,slotShouldForwardProp:o=qn}=e,s=i=>Co(O({},i,{theme:Ln(O({},i,{defaultTheme:n,themeId:t}))}));return s.__mui_systemSx=!0,(i,l={})=>{Gr.internal_processStyles(i,v=>v.filter(P=>!(P!=null&&P.__mui_systemSx)));const{name:c,slot:d,skipVariantsResolver:u,skipSx:h,overridesResolver:w=fp(Ca(d))}=l,b=Ne(l,dp),x=u!==void 0?u:d&&d!=="Root"&&d!=="root"||!1,f=h||!1;let m;process.env.NODE_ENV!=="production"&&c&&(m=`${c}-${Ca(d||"Root")}`);let S=qn;d==="Root"||d==="root"?S=r:d?S=o:pp(i)&&(S=void 0);const R=Gr(i,O({shouldForwardProp:S,label:m},b)),j=v=>typeof v=="function"&&v.__emotion_real!==v||mt(v)?P=>Hn(v,O({},P,{theme:Ln({theme:P.theme,defaultTheme:n,themeId:t})})):v,E=(v,...P)=>{let V=j(v);const U=P?P.map(j):[];c&&w&&U.push(k=>{const D=Ln(O({},k,{defaultTheme:n,themeId:t}));if(!D.components||!D.components[c]||!D.components[c].styleOverrides)return null;const $=D.components[c].styleOverrides,J={};return Object.entries($).forEach(([Y,F])=>{J[Y]=Hn(F,O({},k,{theme:D}))}),w(k,J)}),c&&!x&&U.push(k=>{var D;const $=Ln(O({},k,{defaultTheme:n,themeId:t})),J=$==null||(D=$.components)==null||(D=D[c])==null?void 0:D.variants;return Hn({variants:J},O({},k,{theme:$}))}),f||U.push(s);const C=U.length-P.length;if(Array.isArray(v)&&C>0){const k=new Array(C).fill("");V=[...v,...k],V.raw=[...v.raw,...k]}const _=R(V,...U);if(process.env.NODE_ENV!=="production"){let k;c&&(k=`${c}${Ye(d||"")}`),k===void 0&&(k=`Styled(${Bd(i)})`),_.displayName=k}return i.muiName&&(_.muiName=i.muiName),_};return R.withConfig&&(E.withConfig=R.withConfig),E}}function hp(e){const{theme:t,name:n,props:r}=e;return!t||!t.components||!t.components[n]||!t.components[n].defaultProps?r:si(t.components[n].defaultProps,r)}function gp({props:e,name:t,defaultTheme:n,themeId:r}){let o=fi(n);return r&&(o=o[r]||o),hp({theme:o,name:t,props:e})}function Ro(e,t=0,n=1){return process.env.NODE_ENV!=="production"&&(en)&&console.error(`MUI: The value provided ${e} is out of range [${t}, ${n}].`),iu(e,t,n)}function bp(e){e=e.slice(1);const t=new RegExp(`.{1,${e.length>=6?2:1}}`,"g");let n=e.match(t);return n&&n[0].length===1&&(n=n.map(r=>r+r)),n?`rgb${n.length===4?"a":""}(${n.map((r,o)=>o<3?parseInt(r,16):Math.round(parseInt(r,16)/255*1e3)/1e3).join(", ")})`:""}function Nt(e){if(e.type)return e;if(e.charAt(0)==="#")return Nt(bp(e));const t=e.indexOf("("),n=e.substring(0,t);if(["rgb","rgba","hsl","hsla","color"].indexOf(n)===-1)throw new Error(process.env.NODE_ENV!=="production"?`MUI: Unsupported \`${e}\` color. +`)),()=>{})}function di(e){return _n(e,"spacing",8,"spacing")}function Pn(e,t){if(typeof t=="string"||t==null)return t;const n=Math.abs(t),r=e(n);return t>=0?r:typeof r=="number"?-r:`-${r}`}function yu(e,t){return n=>e.reduce((r,o)=>(r[o]=Pn(t,n),r),{})}function Nu(e,t,n,r){if(t.indexOf(n)===-1)return null;const o=vu(n),s=yu(o,r),i=e[n];return et(e,i,s)}function ui(e,t){const n=di(e.theme);return Object.keys(e).map(r=>Nu(e,t,r,n)).reduce(mn,{})}function me(e){return ui(e,wr)}me.propTypes=process.env.NODE_ENV!=="production"?wr.reduce((e,t)=>(e[t]=st,e),{}):{};me.filterProps=wr;function he(e){return ui(e,fr)}he.propTypes=process.env.NODE_ENV!=="production"?fr.reduce((e,t)=>(e[t]=st,e),{}):{};he.filterProps=fr;process.env.NODE_ENV!=="production"&&xu.reduce((e,t)=>(e[t]=st,e),{});function ku(e=8){if(e.mui)return e;const t=di({spacing:e}),n=(...r)=>(process.env.NODE_ENV!=="production"&&(r.length<=4||console.error(`MUI: Too many arguments provided, expected between 0 and 4, got ${r.length}`)),(r.length===0?[1]:r).map(s=>{const i=t(s);return typeof i=="number"?`${i}px`:i}).join(" "));return n.mui=!0,n}function mr(...e){const t=e.reduce((r,o)=>(o.filterProps.forEach(s=>{r[s]=o}),r),{}),n=r=>Object.keys(r).reduce((o,s)=>t[s]?mn(o,t[s](r)):o,{});return n.propTypes=process.env.NODE_ENV!=="production"?e.reduce((r,o)=>Object.assign(r,o.propTypes),{}):{},n.filterProps=e.reduce((r,o)=>r.concat(o.filterProps),[]),n}function Be(e){return typeof e!="number"?e:`${e}px solid`}function Fe(e,t){return ve({prop:e,themeKey:"borders",transform:t})}const Su=Fe("border",Be),Eu=Fe("borderTop",Be),ju=Fe("borderRight",Be),Cu=Fe("borderBottom",Be),Tu=Fe("borderLeft",Be),Ru=Fe("borderColor"),Ou=Fe("borderTopColor"),_u=Fe("borderRightColor"),Pu=Fe("borderBottomColor"),Iu=Fe("borderLeftColor"),Mu=Fe("outline",Be),$u=Fe("outlineColor"),hr=e=>{if(e.borderRadius!==void 0&&e.borderRadius!==null){const t=_n(e.theme,"shape.borderRadius",4,"borderRadius"),n=r=>({borderRadius:Pn(t,r)});return et(e,e.borderRadius,n)}return null};hr.propTypes=process.env.NODE_ENV!=="production"?{borderRadius:st}:{};hr.filterProps=["borderRadius"];mr(Su,Eu,ju,Cu,Tu,Ru,Ou,_u,Pu,Iu,hr,Mu,$u);const gr=e=>{if(e.gap!==void 0&&e.gap!==null){const t=_n(e.theme,"spacing",8,"gap"),n=r=>({gap:Pn(t,r)});return et(e,e.gap,n)}return null};gr.propTypes=process.env.NODE_ENV!=="production"?{gap:st}:{};gr.filterProps=["gap"];const br=e=>{if(e.columnGap!==void 0&&e.columnGap!==null){const t=_n(e.theme,"spacing",8,"columnGap"),n=r=>({columnGap:Pn(t,r)});return et(e,e.columnGap,n)}return null};br.propTypes=process.env.NODE_ENV!=="production"?{columnGap:st}:{};br.filterProps=["columnGap"];const vr=e=>{if(e.rowGap!==void 0&&e.rowGap!==null){const t=_n(e.theme,"spacing",8,"rowGap"),n=r=>({rowGap:Pn(t,r)});return et(e,e.rowGap,n)}return null};vr.propTypes=process.env.NODE_ENV!=="production"?{rowGap:st}:{};vr.filterProps=["rowGap"];const Du=ve({prop:"gridColumn"}),Au=ve({prop:"gridRow"}),Bu=ve({prop:"gridAutoFlow"}),Vu=ve({prop:"gridAutoColumns"}),zu=ve({prop:"gridAutoRows"}),Lu=ve({prop:"gridTemplateColumns"}),Fu=ve({prop:"gridTemplateRows"}),Gu=ve({prop:"gridTemplateAreas"}),Uu=ve({prop:"gridArea"});mr(gr,br,vr,Du,Au,Bu,Vu,zu,Lu,Fu,Gu,Uu);function Dt(e,t){return t==="grey"?t:e}const qu=ve({prop:"color",themeKey:"palette",transform:Dt}),Hu=ve({prop:"bgcolor",cssProperty:"backgroundColor",themeKey:"palette",transform:Dt}),Xu=ve({prop:"backgroundColor",themeKey:"palette",transform:Dt});mr(qu,Hu,Xu);function Ie(e){return e<=1&&e!==0?`${e*100}%`:e}const Yu=ve({prop:"width",transform:Ie}),Eo=e=>{if(e.maxWidth!==void 0&&e.maxWidth!==null){const t=n=>{var r,o;const s=((r=e.theme)==null||(r=r.breakpoints)==null||(r=r.values)==null?void 0:r[n])||So[n];return s?((o=e.theme)==null||(o=o.breakpoints)==null?void 0:o.unit)!=="px"?{maxWidth:`${s}${e.theme.breakpoints.unit}`}:{maxWidth:s}:{maxWidth:Ie(n)}};return et(e,e.maxWidth,t)}return null};Eo.filterProps=["maxWidth"];const Wu=ve({prop:"minWidth",transform:Ie}),Ku=ve({prop:"height",transform:Ie}),Ju=ve({prop:"maxHeight",transform:Ie}),Zu=ve({prop:"minHeight",transform:Ie});ve({prop:"size",cssProperty:"width",transform:Ie});ve({prop:"size",cssProperty:"height",transform:Ie});const Qu=ve({prop:"boxSizing"});mr(Yu,Eo,Wu,Ku,Ju,Zu,Qu);const ep={border:{themeKey:"borders",transform:Be},borderTop:{themeKey:"borders",transform:Be},borderRight:{themeKey:"borders",transform:Be},borderBottom:{themeKey:"borders",transform:Be},borderLeft:{themeKey:"borders",transform:Be},borderColor:{themeKey:"palette"},borderTopColor:{themeKey:"palette"},borderRightColor:{themeKey:"palette"},borderBottomColor:{themeKey:"palette"},borderLeftColor:{themeKey:"palette"},outline:{themeKey:"borders",transform:Be},outlineColor:{themeKey:"palette"},borderRadius:{themeKey:"shape.borderRadius",style:hr},color:{themeKey:"palette",transform:Dt},bgcolor:{themeKey:"palette",cssProperty:"backgroundColor",transform:Dt},backgroundColor:{themeKey:"palette",transform:Dt},p:{style:he},pt:{style:he},pr:{style:he},pb:{style:he},pl:{style:he},px:{style:he},py:{style:he},padding:{style:he},paddingTop:{style:he},paddingRight:{style:he},paddingBottom:{style:he},paddingLeft:{style:he},paddingX:{style:he},paddingY:{style:he},paddingInline:{style:he},paddingInlineStart:{style:he},paddingInlineEnd:{style:he},paddingBlock:{style:he},paddingBlockStart:{style:he},paddingBlockEnd:{style:he},m:{style:me},mt:{style:me},mr:{style:me},mb:{style:me},ml:{style:me},mx:{style:me},my:{style:me},margin:{style:me},marginTop:{style:me},marginRight:{style:me},marginBottom:{style:me},marginLeft:{style:me},marginX:{style:me},marginY:{style:me},marginInline:{style:me},marginInlineStart:{style:me},marginInlineEnd:{style:me},marginBlock:{style:me},marginBlockStart:{style:me},marginBlockEnd:{style:me},displayPrint:{cssProperty:!1,transform:e=>({"@media print":{display:e}})},display:{},overflow:{},textOverflow:{},visibility:{},whiteSpace:{},flexBasis:{},flexDirection:{},flexWrap:{},justifyContent:{},alignItems:{},alignContent:{},order:{},flex:{},flexGrow:{},flexShrink:{},alignSelf:{},justifyItems:{},justifySelf:{},gap:{style:gr},rowGap:{style:vr},columnGap:{style:br},gridColumn:{},gridRow:{},gridAutoFlow:{},gridAutoColumns:{},gridAutoRows:{},gridTemplateColumns:{},gridTemplateRows:{},gridTemplateAreas:{},gridArea:{},position:{},zIndex:{themeKey:"zIndex"},top:{},right:{},bottom:{},left:{},boxShadow:{themeKey:"shadows"},width:{transform:Ie},maxWidth:{style:Eo},minWidth:{transform:Ie},height:{transform:Ie},maxHeight:{transform:Ie},minHeight:{transform:Ie},boxSizing:{},fontFamily:{themeKey:"typography"},fontSize:{themeKey:"typography"},fontStyle:{themeKey:"typography"},fontWeight:{themeKey:"typography"},letterSpacing:{},textTransform:{},lineHeight:{},textAlign:{},typography:{cssProperty:!1,themeKey:"typography"}},jo=ep;function tp(...e){const t=e.reduce((r,o)=>r.concat(Object.keys(o)),[]),n=new Set(t);return e.every(r=>n.size===Object.keys(r).length)}function np(e,t){return typeof e=="function"?e(t):e}function rp(){function e(n,r,o,s){const i={[n]:r,theme:o},l=s[n];if(!l)return{[n]:r};const{cssProperty:c=n,themeKey:u,transform:d,style:m}=l;if(r==null)return null;if(u==="typography"&&r==="inherit")return{[n]:r};const w=pr(o,u)||{};return m?m(i):et(i,r,x=>{let f=Zn(w,d,x);return x===f&&typeof x=="string"&&(f=Zn(w,d,`${n}${x==="default"?"":Ye(x)}`,x)),c===!1?f:{[c]:f}})}function t(n){var r;const{sx:o,theme:s={}}=n||{};if(!o)return null;const i=(r=s.unstable_sxConfig)!=null?r:jo;function l(c){let u=c;if(typeof c=="function")u=c(s);else if(typeof c!="object")return c;if(!u)return null;const d=fu(s.breakpoints),m=Object.keys(d);let w=d;return Object.keys(u).forEach(b=>{const x=np(u[b],s);if(x!=null)if(typeof x=="object")if(i[b])w=mn(w,e(b,x,s,i));else{const f=et({theme:s},x,h=>({[b]:h}));tp(f,x)?w[b]=t({sx:x,theme:s}):w=mn(w,f)}else w=mn(w,e(b,x,s,i))}),mu(m,w)}return Array.isArray(o)?o.map(l):l(o)}return t}const pi=rp();pi.filterProps=["sx"];const Co=pi;function op(e,t){const n=this;return n.vars&&typeof n.getColorSchemeSelector=="function"?{[n.getColorSchemeSelector(e).replace(/(\[[^\]]+\])/,"*:where($1)")]:t}:n.palette.mode===e?t:{}}const ap=["breakpoints","palette","spacing","shape"];function To(e={},...t){const{breakpoints:n={},palette:r={},spacing:o,shape:s={}}=e,i=Ne(e,ap),l=du(n),c=ku(o);let u=Qe({breakpoints:l,direction:"ltr",components:{},palette:O({mode:"light"},r),spacing:c,shape:O({},pu,s)},i);return u.applyStyles=op,u=t.reduce((d,m)=>Qe(d,m),u),u.unstable_sxConfig=O({},jo,i==null?void 0:i.unstable_sxConfig),u.unstable_sx=function(m){return Co({sx:m,theme:this})},u}function sp(e){return Object.keys(e).length===0}function wi(e=null){const t=M.useContext(Gr.ThemeContext);return!t||sp(t)?e:t}const ip=To();function fi(e=ip){return wi(e)}const lp=["ownerState"],cp=["variants"],dp=["name","slot","skipVariantsResolver","skipSx","overridesResolver"];function up(e){return Object.keys(e).length===0}function pp(e){return typeof e=="string"&&e.charCodeAt(0)>96}function qn(e){return e!=="ownerState"&&e!=="theme"&&e!=="sx"&&e!=="as"}const wp=To(),Ca=e=>e&&e.charAt(0).toLowerCase()+e.slice(1);function Ln({defaultTheme:e,theme:t,themeId:n}){return up(t)?e:t[n]||t}function fp(e){return e?(t,n)=>n[e]:null}function Hn(e,t){let{ownerState:n}=t,r=Ne(t,lp);const o=typeof e=="function"?e(O({ownerState:n},r)):e;if(Array.isArray(o))return o.flatMap(s=>Hn(s,O({ownerState:n},r)));if(o&&typeof o=="object"&&Array.isArray(o.variants)){const{variants:s=[]}=o;let l=Ne(o,cp);return s.forEach(c=>{let u=!0;typeof c.props=="function"?u=c.props(O({ownerState:n},r,n)):Object.keys(c.props).forEach(d=>{(n==null?void 0:n[d])!==c.props[d]&&r[d]!==c.props[d]&&(u=!1)}),u&&(Array.isArray(l)||(l=[l]),l.push(typeof c.style=="function"?c.style(O({ownerState:n},r,n)):c.style))}),l}return o}function mp(e={}){const{themeId:t,defaultTheme:n=wp,rootShouldForwardProp:r=qn,slotShouldForwardProp:o=qn}=e,s=i=>Co(O({},i,{theme:Ln(O({},i,{defaultTheme:n,themeId:t}))}));return s.__mui_systemSx=!0,(i,l={})=>{Gr.internal_processStyles(i,v=>v.filter(P=>!(P!=null&&P.__mui_systemSx)));const{name:c,slot:u,skipVariantsResolver:d,skipSx:m,overridesResolver:w=fp(Ca(u))}=l,b=Ne(l,dp),x=d!==void 0?d:u&&u!=="Root"&&u!=="root"||!1,f=m||!1;let h;process.env.NODE_ENV!=="production"&&c&&(h=`${c}-${Ca(u||"Root")}`);let S=qn;u==="Root"||u==="root"?S=r:u?S=o:pp(i)&&(S=void 0);const R=Gr(i,O({shouldForwardProp:S,label:h},b)),j=v=>typeof v=="function"&&v.__emotion_real!==v||mt(v)?P=>Hn(v,O({},P,{theme:Ln({theme:P.theme,defaultTheme:n,themeId:t})})):v,E=(v,...P)=>{let V=j(v);const U=P?P.map(j):[];c&&w&&U.push(k=>{const D=Ln(O({},k,{defaultTheme:n,themeId:t}));if(!D.components||!D.components[c]||!D.components[c].styleOverrides)return null;const $=D.components[c].styleOverrides,J={};return Object.entries($).forEach(([Y,F])=>{J[Y]=Hn(F,O({},k,{theme:D}))}),w(k,J)}),c&&!x&&U.push(k=>{var D;const $=Ln(O({},k,{defaultTheme:n,themeId:t})),J=$==null||(D=$.components)==null||(D=D[c])==null?void 0:D.variants;return Hn({variants:J},O({},k,{theme:$}))}),f||U.push(s);const C=U.length-P.length;if(Array.isArray(v)&&C>0){const k=new Array(C).fill("");V=[...v,...k],V.raw=[...v.raw,...k]}const _=R(V,...U);if(process.env.NODE_ENV!=="production"){let k;c&&(k=`${c}${Ye(u||"")}`),k===void 0&&(k=`Styled(${Bd(i)})`),_.displayName=k}return i.muiName&&(_.muiName=i.muiName),_};return R.withConfig&&(E.withConfig=R.withConfig),E}}function hp(e){const{theme:t,name:n,props:r}=e;return!t||!t.components||!t.components[n]||!t.components[n].defaultProps?r:si(t.components[n].defaultProps,r)}function gp({props:e,name:t,defaultTheme:n,themeId:r}){let o=fi(n);return r&&(o=o[r]||o),hp({theme:o,name:t,props:e})}function Ro(e,t=0,n=1){return process.env.NODE_ENV!=="production"&&(en)&&console.error(`MUI: The value provided ${e} is out of range [${t}, ${n}].`),iu(e,t,n)}function bp(e){e=e.slice(1);const t=new RegExp(`.{1,${e.length>=6?2:1}}`,"g");let n=e.match(t);return n&&n[0].length===1&&(n=n.map(r=>r+r)),n?`rgb${n.length===4?"a":""}(${n.map((r,o)=>o<3?parseInt(r,16):Math.round(parseInt(r,16)/255*1e3)/1e3).join(", ")})`:""}function Nt(e){if(e.type)return e;if(e.charAt(0)==="#")return Nt(bp(e));const t=e.indexOf("("),n=e.substring(0,t);if(["rgb","rgba","hsl","hsla","color"].indexOf(n)===-1)throw new Error(process.env.NODE_ENV!=="production"?`MUI: Unsupported \`${e}\` color. The following formats are supported: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color().`:zt(9,e));let r=e.substring(t+1,e.length-1),o;if(n==="color"){if(r=r.split(" "),o=r.shift(),r.length===4&&r[3].charAt(0)==="/"&&(r[3]=r[3].slice(1)),["srgb","display-p3","a98-rgb","prophoto-rgb","rec-2020"].indexOf(o)===-1)throw new Error(process.env.NODE_ENV!=="production"?`MUI: unsupported \`${o}\` color space. -The following color spaces are supported: srgb, display-p3, a98-rgb, prophoto-rgb, rec-2020.`:zt(10,o))}else r=r.split(",");return r=r.map(s=>parseFloat(s)),{type:n,values:r,colorSpace:o}}function xr(e){const{type:t,colorSpace:n}=e;let{values:r}=e;return t.indexOf("rgb")!==-1?r=r.map((o,s)=>s<3?parseInt(o,10):o):t.indexOf("hsl")!==-1&&(r[1]=`${r[1]}%`,r[2]=`${r[2]}%`),t.indexOf("color")!==-1?r=`${n} ${r.join(" ")}`:r=`${r.join(", ")}`,`${t}(${r})`}function vp(e){e=Nt(e);const{values:t}=e,n=t[0],r=t[1]/100,o=t[2]/100,s=r*Math.min(o,1-o),i=(d,u=(d+n/30)%12)=>o-s*Math.max(Math.min(u-3,9-u,1),-1);let l="rgb";const c=[Math.round(i(0)*255),Math.round(i(8)*255),Math.round(i(4)*255)];return e.type==="hsla"&&(l+="a",c.push(t[3])),xr({type:l,values:c})}function Ta(e){e=Nt(e);let t=e.type==="hsl"||e.type==="hsla"?Nt(vp(e)).values:e.values;return t=t.map(n=>(e.type!=="color"&&(n/=255),n<=.03928?n/12.92:((n+.055)/1.055)**2.4)),Number((.2126*t[0]+.7152*t[1]+.0722*t[2]).toFixed(3))}function Ra(e,t){const n=Ta(e),r=Ta(t);return(Math.max(n,r)+.05)/(Math.min(n,r)+.05)}function mi(e,t){return e=Nt(e),t=Ro(t),(e.type==="rgb"||e.type==="hsl")&&(e.type+="a"),e.type==="color"?e.values[3]=`/${t}`:e.values[3]=t,xr(e)}function xp(e,t){if(e=Nt(e),t=Ro(t),e.type.indexOf("hsl")!==-1)e.values[2]*=1-t;else if(e.type.indexOf("rgb")!==-1||e.type.indexOf("color")!==-1)for(let n=0;n<3;n+=1)e.values[n]*=1-t;return xr(e)}function yp(e,t){if(e=Nt(e),t=Ro(t),e.type.indexOf("hsl")!==-1)e.values[2]+=(100-e.values[2])*t;else if(e.type.indexOf("rgb")!==-1)for(let n=0;n<3;n+=1)e.values[n]+=(255-e.values[n])*t;else if(e.type.indexOf("color")!==-1)for(let n=0;n<3;n+=1)e.values[n]+=(1-e.values[n])*t;return xr(e)}function Np(e,t){return O({toolbar:{minHeight:56,[e.up("xs")]:{"@media (orientation: landscape)":{minHeight:48}},[e.up("sm")]:{minHeight:64}}},t)}const kp={black:"#000",white:"#fff"},yn=kp,Sp={50:"#fafafa",100:"#f5f5f5",200:"#eeeeee",300:"#e0e0e0",400:"#bdbdbd",500:"#9e9e9e",600:"#757575",700:"#616161",800:"#424242",900:"#212121",A100:"#f5f5f5",A200:"#eeeeee",A400:"#bdbdbd",A700:"#616161"},Ep=Sp,jp={50:"#f3e5f5",100:"#e1bee7",200:"#ce93d8",300:"#ba68c8",400:"#ab47bc",500:"#9c27b0",600:"#8e24aa",700:"#7b1fa2",800:"#6a1b9a",900:"#4a148c",A100:"#ea80fc",A200:"#e040fb",A400:"#d500f9",A700:"#aa00ff"},Rt=jp,Cp={50:"#ffebee",100:"#ffcdd2",200:"#ef9a9a",300:"#e57373",400:"#ef5350",500:"#f44336",600:"#e53935",700:"#d32f2f",800:"#c62828",900:"#b71c1c",A100:"#ff8a80",A200:"#ff5252",A400:"#ff1744",A700:"#d50000"},Ot=Cp,Tp={50:"#fff3e0",100:"#ffe0b2",200:"#ffcc80",300:"#ffb74d",400:"#ffa726",500:"#ff9800",600:"#fb8c00",700:"#f57c00",800:"#ef6c00",900:"#e65100",A100:"#ffd180",A200:"#ffab40",A400:"#ff9100",A700:"#ff6d00"},on=Tp,Rp={50:"#e3f2fd",100:"#bbdefb",200:"#90caf9",300:"#64b5f6",400:"#42a5f5",500:"#2196f3",600:"#1e88e5",700:"#1976d2",800:"#1565c0",900:"#0d47a1",A100:"#82b1ff",A200:"#448aff",A400:"#2979ff",A700:"#2962ff"},_t=Rp,Op={50:"#e1f5fe",100:"#b3e5fc",200:"#81d4fa",300:"#4fc3f7",400:"#29b6f6",500:"#03a9f4",600:"#039be5",700:"#0288d1",800:"#0277bd",900:"#01579b",A100:"#80d8ff",A200:"#40c4ff",A400:"#00b0ff",A700:"#0091ea"},Pt=Op,_p={50:"#e8f5e9",100:"#c8e6c9",200:"#a5d6a7",300:"#81c784",400:"#66bb6a",500:"#4caf50",600:"#43a047",700:"#388e3c",800:"#2e7d32",900:"#1b5e20",A100:"#b9f6ca",A200:"#69f0ae",A400:"#00e676",A700:"#00c853"},It=_p,Pp=["mode","contrastThreshold","tonalOffset"],Oa={text:{primary:"rgba(0, 0, 0, 0.87)",secondary:"rgba(0, 0, 0, 0.6)",disabled:"rgba(0, 0, 0, 0.38)"},divider:"rgba(0, 0, 0, 0.12)",background:{paper:yn.white,default:yn.white},action:{active:"rgba(0, 0, 0, 0.54)",hover:"rgba(0, 0, 0, 0.04)",hoverOpacity:.04,selected:"rgba(0, 0, 0, 0.08)",selectedOpacity:.08,disabled:"rgba(0, 0, 0, 0.26)",disabledBackground:"rgba(0, 0, 0, 0.12)",disabledOpacity:.38,focus:"rgba(0, 0, 0, 0.12)",focusOpacity:.12,activatedOpacity:.12}},zr={text:{primary:yn.white,secondary:"rgba(255, 255, 255, 0.7)",disabled:"rgba(255, 255, 255, 0.5)",icon:"rgba(255, 255, 255, 0.5)"},divider:"rgba(255, 255, 255, 0.12)",background:{paper:"#121212",default:"#121212"},action:{active:yn.white,hover:"rgba(255, 255, 255, 0.08)",hoverOpacity:.08,selected:"rgba(255, 255, 255, 0.16)",selectedOpacity:.16,disabled:"rgba(255, 255, 255, 0.3)",disabledBackground:"rgba(255, 255, 255, 0.12)",disabledOpacity:.38,focus:"rgba(255, 255, 255, 0.12)",focusOpacity:.12,activatedOpacity:.24}};function _a(e,t,n,r){const o=r.light||r,s=r.dark||r*1.5;e[t]||(e.hasOwnProperty(n)?e[t]=e[n]:t==="light"?e.light=yp(e.main,o):t==="dark"&&(e.dark=xp(e.main,s)))}function Ip(e="light"){return e==="dark"?{main:_t[200],light:_t[50],dark:_t[400]}:{main:_t[700],light:_t[400],dark:_t[800]}}function Mp(e="light"){return e==="dark"?{main:Rt[200],light:Rt[50],dark:Rt[400]}:{main:Rt[500],light:Rt[300],dark:Rt[700]}}function $p(e="light"){return e==="dark"?{main:Ot[500],light:Ot[300],dark:Ot[700]}:{main:Ot[700],light:Ot[400],dark:Ot[800]}}function Dp(e="light"){return e==="dark"?{main:Pt[400],light:Pt[300],dark:Pt[700]}:{main:Pt[700],light:Pt[500],dark:Pt[900]}}function Ap(e="light"){return e==="dark"?{main:It[400],light:It[300],dark:It[700]}:{main:It[800],light:It[500],dark:It[900]}}function Bp(e="light"){return e==="dark"?{main:on[400],light:on[300],dark:on[700]}:{main:"#ed6c02",light:on[500],dark:on[900]}}function Vp(e){const{mode:t="light",contrastThreshold:n=3,tonalOffset:r=.2}=e,o=Ne(e,Pp),s=e.primary||Ip(t),i=e.secondary||Mp(t),l=e.error||$p(t),c=e.info||Dp(t),d=e.success||Ap(t),u=e.warning||Bp(t);function h(f){const m=Ra(f,zr.text.primary)>=n?zr.text.primary:Oa.text.primary;if(process.env.NODE_ENV!=="production"){const S=Ra(f,m);S<3&&console.error([`MUI: The contrast ratio of ${S}:1 for ${m} on ${f}`,"falls below the WCAG recommended absolute minimum contrast ratio of 3:1.","https://www.w3.org/TR/2008/REC-WCAG20-20081211/#visual-audio-contrast-contrast"].join(` -`))}return m}const w=({color:f,name:m,mainShade:S=500,lightShade:R=300,darkShade:j=700})=>{if(f=O({},f),!f.main&&f[S]&&(f.main=f[S]),!f.hasOwnProperty("main"))throw new Error(process.env.NODE_ENV!=="production"?`MUI: The color${m?` (${m})`:""} provided to augmentColor(color) is invalid. -The color object needs to have a \`main\` property or a \`${S}\` property.`:zt(11,m?` (${m})`:"",S));if(typeof f.main!="string")throw new Error(process.env.NODE_ENV!=="production"?`MUI: The color${m?` (${m})`:""} provided to augmentColor(color) is invalid. +The following color spaces are supported: srgb, display-p3, a98-rgb, prophoto-rgb, rec-2020.`:zt(10,o))}else r=r.split(",");return r=r.map(s=>parseFloat(s)),{type:n,values:r,colorSpace:o}}function xr(e){const{type:t,colorSpace:n}=e;let{values:r}=e;return t.indexOf("rgb")!==-1?r=r.map((o,s)=>s<3?parseInt(o,10):o):t.indexOf("hsl")!==-1&&(r[1]=`${r[1]}%`,r[2]=`${r[2]}%`),t.indexOf("color")!==-1?r=`${n} ${r.join(" ")}`:r=`${r.join(", ")}`,`${t}(${r})`}function vp(e){e=Nt(e);const{values:t}=e,n=t[0],r=t[1]/100,o=t[2]/100,s=r*Math.min(o,1-o),i=(u,d=(u+n/30)%12)=>o-s*Math.max(Math.min(d-3,9-d,1),-1);let l="rgb";const c=[Math.round(i(0)*255),Math.round(i(8)*255),Math.round(i(4)*255)];return e.type==="hsla"&&(l+="a",c.push(t[3])),xr({type:l,values:c})}function Ta(e){e=Nt(e);let t=e.type==="hsl"||e.type==="hsla"?Nt(vp(e)).values:e.values;return t=t.map(n=>(e.type!=="color"&&(n/=255),n<=.03928?n/12.92:((n+.055)/1.055)**2.4)),Number((.2126*t[0]+.7152*t[1]+.0722*t[2]).toFixed(3))}function Ra(e,t){const n=Ta(e),r=Ta(t);return(Math.max(n,r)+.05)/(Math.min(n,r)+.05)}function mi(e,t){return e=Nt(e),t=Ro(t),(e.type==="rgb"||e.type==="hsl")&&(e.type+="a"),e.type==="color"?e.values[3]=`/${t}`:e.values[3]=t,xr(e)}function xp(e,t){if(e=Nt(e),t=Ro(t),e.type.indexOf("hsl")!==-1)e.values[2]*=1-t;else if(e.type.indexOf("rgb")!==-1||e.type.indexOf("color")!==-1)for(let n=0;n<3;n+=1)e.values[n]*=1-t;return xr(e)}function yp(e,t){if(e=Nt(e),t=Ro(t),e.type.indexOf("hsl")!==-1)e.values[2]+=(100-e.values[2])*t;else if(e.type.indexOf("rgb")!==-1)for(let n=0;n<3;n+=1)e.values[n]+=(255-e.values[n])*t;else if(e.type.indexOf("color")!==-1)for(let n=0;n<3;n+=1)e.values[n]+=(1-e.values[n])*t;return xr(e)}function Np(e,t){return O({toolbar:{minHeight:56,[e.up("xs")]:{"@media (orientation: landscape)":{minHeight:48}},[e.up("sm")]:{minHeight:64}}},t)}const kp={black:"#000",white:"#fff"},yn=kp,Sp={50:"#fafafa",100:"#f5f5f5",200:"#eeeeee",300:"#e0e0e0",400:"#bdbdbd",500:"#9e9e9e",600:"#757575",700:"#616161",800:"#424242",900:"#212121",A100:"#f5f5f5",A200:"#eeeeee",A400:"#bdbdbd",A700:"#616161"},Ep=Sp,jp={50:"#f3e5f5",100:"#e1bee7",200:"#ce93d8",300:"#ba68c8",400:"#ab47bc",500:"#9c27b0",600:"#8e24aa",700:"#7b1fa2",800:"#6a1b9a",900:"#4a148c",A100:"#ea80fc",A200:"#e040fb",A400:"#d500f9",A700:"#aa00ff"},Rt=jp,Cp={50:"#ffebee",100:"#ffcdd2",200:"#ef9a9a",300:"#e57373",400:"#ef5350",500:"#f44336",600:"#e53935",700:"#d32f2f",800:"#c62828",900:"#b71c1c",A100:"#ff8a80",A200:"#ff5252",A400:"#ff1744",A700:"#d50000"},Ot=Cp,Tp={50:"#fff3e0",100:"#ffe0b2",200:"#ffcc80",300:"#ffb74d",400:"#ffa726",500:"#ff9800",600:"#fb8c00",700:"#f57c00",800:"#ef6c00",900:"#e65100",A100:"#ffd180",A200:"#ffab40",A400:"#ff9100",A700:"#ff6d00"},on=Tp,Rp={50:"#e3f2fd",100:"#bbdefb",200:"#90caf9",300:"#64b5f6",400:"#42a5f5",500:"#2196f3",600:"#1e88e5",700:"#1976d2",800:"#1565c0",900:"#0d47a1",A100:"#82b1ff",A200:"#448aff",A400:"#2979ff",A700:"#2962ff"},_t=Rp,Op={50:"#e1f5fe",100:"#b3e5fc",200:"#81d4fa",300:"#4fc3f7",400:"#29b6f6",500:"#03a9f4",600:"#039be5",700:"#0288d1",800:"#0277bd",900:"#01579b",A100:"#80d8ff",A200:"#40c4ff",A400:"#00b0ff",A700:"#0091ea"},Pt=Op,_p={50:"#e8f5e9",100:"#c8e6c9",200:"#a5d6a7",300:"#81c784",400:"#66bb6a",500:"#4caf50",600:"#43a047",700:"#388e3c",800:"#2e7d32",900:"#1b5e20",A100:"#b9f6ca",A200:"#69f0ae",A400:"#00e676",A700:"#00c853"},It=_p,Pp=["mode","contrastThreshold","tonalOffset"],Oa={text:{primary:"rgba(0, 0, 0, 0.87)",secondary:"rgba(0, 0, 0, 0.6)",disabled:"rgba(0, 0, 0, 0.38)"},divider:"rgba(0, 0, 0, 0.12)",background:{paper:yn.white,default:yn.white},action:{active:"rgba(0, 0, 0, 0.54)",hover:"rgba(0, 0, 0, 0.04)",hoverOpacity:.04,selected:"rgba(0, 0, 0, 0.08)",selectedOpacity:.08,disabled:"rgba(0, 0, 0, 0.26)",disabledBackground:"rgba(0, 0, 0, 0.12)",disabledOpacity:.38,focus:"rgba(0, 0, 0, 0.12)",focusOpacity:.12,activatedOpacity:.12}},zr={text:{primary:yn.white,secondary:"rgba(255, 255, 255, 0.7)",disabled:"rgba(255, 255, 255, 0.5)",icon:"rgba(255, 255, 255, 0.5)"},divider:"rgba(255, 255, 255, 0.12)",background:{paper:"#121212",default:"#121212"},action:{active:yn.white,hover:"rgba(255, 255, 255, 0.08)",hoverOpacity:.08,selected:"rgba(255, 255, 255, 0.16)",selectedOpacity:.16,disabled:"rgba(255, 255, 255, 0.3)",disabledBackground:"rgba(255, 255, 255, 0.12)",disabledOpacity:.38,focus:"rgba(255, 255, 255, 0.12)",focusOpacity:.12,activatedOpacity:.24}};function _a(e,t,n,r){const o=r.light||r,s=r.dark||r*1.5;e[t]||(e.hasOwnProperty(n)?e[t]=e[n]:t==="light"?e.light=yp(e.main,o):t==="dark"&&(e.dark=xp(e.main,s)))}function Ip(e="light"){return e==="dark"?{main:_t[200],light:_t[50],dark:_t[400]}:{main:_t[700],light:_t[400],dark:_t[800]}}function Mp(e="light"){return e==="dark"?{main:Rt[200],light:Rt[50],dark:Rt[400]}:{main:Rt[500],light:Rt[300],dark:Rt[700]}}function $p(e="light"){return e==="dark"?{main:Ot[500],light:Ot[300],dark:Ot[700]}:{main:Ot[700],light:Ot[400],dark:Ot[800]}}function Dp(e="light"){return e==="dark"?{main:Pt[400],light:Pt[300],dark:Pt[700]}:{main:Pt[700],light:Pt[500],dark:Pt[900]}}function Ap(e="light"){return e==="dark"?{main:It[400],light:It[300],dark:It[700]}:{main:It[800],light:It[500],dark:It[900]}}function Bp(e="light"){return e==="dark"?{main:on[400],light:on[300],dark:on[700]}:{main:"#ed6c02",light:on[500],dark:on[900]}}function Vp(e){const{mode:t="light",contrastThreshold:n=3,tonalOffset:r=.2}=e,o=Ne(e,Pp),s=e.primary||Ip(t),i=e.secondary||Mp(t),l=e.error||$p(t),c=e.info||Dp(t),u=e.success||Ap(t),d=e.warning||Bp(t);function m(f){const h=Ra(f,zr.text.primary)>=n?zr.text.primary:Oa.text.primary;if(process.env.NODE_ENV!=="production"){const S=Ra(f,h);S<3&&console.error([`MUI: The contrast ratio of ${S}:1 for ${h} on ${f}`,"falls below the WCAG recommended absolute minimum contrast ratio of 3:1.","https://www.w3.org/TR/2008/REC-WCAG20-20081211/#visual-audio-contrast-contrast"].join(` +`))}return h}const w=({color:f,name:h,mainShade:S=500,lightShade:R=300,darkShade:j=700})=>{if(f=O({},f),!f.main&&f[S]&&(f.main=f[S]),!f.hasOwnProperty("main"))throw new Error(process.env.NODE_ENV!=="production"?`MUI: The color${h?` (${h})`:""} provided to augmentColor(color) is invalid. +The color object needs to have a \`main\` property or a \`${S}\` property.`:zt(11,h?` (${h})`:"",S));if(typeof f.main!="string")throw new Error(process.env.NODE_ENV!=="production"?`MUI: The color${h?` (${h})`:""} provided to augmentColor(color) is invalid. \`color.main\` should be a string, but \`${JSON.stringify(f.main)}\` was provided instead. Did you intend to use one of the following approaches? @@ -55,16 +55,16 @@ const theme1 = createTheme({ palette: { const theme2 = createTheme({ palette: { primary: { main: green[500] }, -} });`:zt(12,m?` (${m})`:"",JSON.stringify(f.main)));return _a(f,"light",R,r),_a(f,"dark",j,r),f.contrastText||(f.contrastText=h(f.main)),f},b={dark:zr,light:Oa};return process.env.NODE_ENV!=="production"&&(b[t]||console.error(`MUI: The palette mode \`${t}\` is not supported.`)),Qe(O({common:O({},yn),mode:t,primary:w({color:s,name:"primary"}),secondary:w({color:i,name:"secondary",mainShade:"A400",lightShade:"A200",darkShade:"A700"}),error:w({color:l,name:"error"}),warning:w({color:u,name:"warning"}),info:w({color:c,name:"info"}),success:w({color:d,name:"success"}),grey:Ep,contrastThreshold:n,getContrastText:h,augmentColor:w,tonalOffset:r},b[t]),o)}const zp=["fontFamily","fontSize","fontWeightLight","fontWeightRegular","fontWeightMedium","fontWeightBold","htmlFontSize","allVariants","pxToRem"];function Lp(e){return Math.round(e*1e5)/1e5}const Pa={textTransform:"uppercase"},Ia='"Roboto", "Helvetica", "Arial", sans-serif';function Fp(e,t){const n=typeof t=="function"?t(e):t,{fontFamily:r=Ia,fontSize:o=14,fontWeightLight:s=300,fontWeightRegular:i=400,fontWeightMedium:l=500,fontWeightBold:c=700,htmlFontSize:d=16,allVariants:u,pxToRem:h}=n,w=Ne(n,zp);process.env.NODE_ENV!=="production"&&(typeof o!="number"&&console.error("MUI: `fontSize` is required to be a number."),typeof d!="number"&&console.error("MUI: `htmlFontSize` is required to be a number."));const b=o/14,x=h||(S=>`${S/d*b}rem`),f=(S,R,j,E,v)=>O({fontFamily:r,fontWeight:S,fontSize:x(R),lineHeight:j},r===Ia?{letterSpacing:`${Lp(E/R)}em`}:{},v,u),m={h1:f(s,96,1.167,-1.5),h2:f(s,60,1.2,-.5),h3:f(i,48,1.167,0),h4:f(i,34,1.235,.25),h5:f(i,24,1.334,0),h6:f(l,20,1.6,.15),subtitle1:f(i,16,1.75,.15),subtitle2:f(l,14,1.57,.1),body1:f(i,16,1.5,.15),body2:f(i,14,1.43,.15),button:f(l,14,1.75,.4,Pa),caption:f(i,12,1.66,.4),overline:f(i,12,2.66,1,Pa),inherit:{fontFamily:"inherit",fontWeight:"inherit",fontSize:"inherit",lineHeight:"inherit",letterSpacing:"inherit"}};return Qe(O({htmlFontSize:d,pxToRem:x,fontFamily:r,fontSize:o,fontWeightLight:s,fontWeightRegular:i,fontWeightMedium:l,fontWeightBold:c},m),w,{clone:!1})}const Gp=.2,Up=.14,qp=.12;function we(...e){return[`${e[0]}px ${e[1]}px ${e[2]}px ${e[3]}px rgba(0,0,0,${Gp})`,`${e[4]}px ${e[5]}px ${e[6]}px ${e[7]}px rgba(0,0,0,${Up})`,`${e[8]}px ${e[9]}px ${e[10]}px ${e[11]}px rgba(0,0,0,${qp})`].join(",")}const Hp=["none",we(0,2,1,-1,0,1,1,0,0,1,3,0),we(0,3,1,-2,0,2,2,0,0,1,5,0),we(0,3,3,-2,0,3,4,0,0,1,8,0),we(0,2,4,-1,0,4,5,0,0,1,10,0),we(0,3,5,-1,0,5,8,0,0,1,14,0),we(0,3,5,-1,0,6,10,0,0,1,18,0),we(0,4,5,-2,0,7,10,1,0,2,16,1),we(0,5,5,-3,0,8,10,1,0,3,14,2),we(0,5,6,-3,0,9,12,1,0,3,16,2),we(0,6,6,-3,0,10,14,1,0,4,18,3),we(0,6,7,-4,0,11,15,1,0,4,20,3),we(0,7,8,-4,0,12,17,2,0,5,22,4),we(0,7,8,-4,0,13,19,2,0,5,24,4),we(0,7,9,-4,0,14,21,2,0,5,26,4),we(0,8,9,-5,0,15,22,2,0,6,28,5),we(0,8,10,-5,0,16,24,2,0,6,30,5),we(0,8,11,-5,0,17,26,2,0,6,32,5),we(0,9,11,-5,0,18,28,2,0,7,34,6),we(0,9,12,-6,0,19,29,2,0,7,36,6),we(0,10,13,-6,0,20,31,3,0,8,38,7),we(0,10,13,-6,0,21,33,3,0,8,40,7),we(0,10,14,-6,0,22,35,3,0,8,42,7),we(0,11,14,-7,0,23,36,3,0,9,44,8),we(0,11,15,-7,0,24,38,3,0,9,46,8)],Xp=Hp,Yp=["duration","easing","delay"],Wp={easeInOut:"cubic-bezier(0.4, 0, 0.2, 1)",easeOut:"cubic-bezier(0.0, 0, 0.2, 1)",easeIn:"cubic-bezier(0.4, 0, 1, 1)",sharp:"cubic-bezier(0.4, 0, 0.6, 1)"},Kp={shortest:150,shorter:200,short:250,standard:300,complex:375,enteringScreen:225,leavingScreen:195};function Ma(e){return`${Math.round(e)}ms`}function Jp(e){if(!e)return 0;const t=e/36;return Math.round((4+15*t**.25+t/5)*10)}function Zp(e){const t=O({},Wp,e.easing),n=O({},Kp,e.duration);return O({getAutoHeightDuration:Jp,create:(o=["all"],s={})=>{const{duration:i=n.standard,easing:l=t.easeInOut,delay:c=0}=s,d=Ne(s,Yp);if(process.env.NODE_ENV!=="production"){const u=w=>typeof w=="string",h=w=>!isNaN(parseFloat(w));!u(o)&&!Array.isArray(o)&&console.error('MUI: Argument "props" must be a string or Array.'),!h(i)&&!u(i)&&console.error(`MUI: Argument "duration" must be a number or a string but found ${i}.`),u(l)||console.error('MUI: Argument "easing" must be a string.'),!h(c)&&!u(c)&&console.error('MUI: Argument "delay" must be a number or a string.'),typeof s!="object"&&console.error(["MUI: Secong argument of transition.create must be an object.","Arguments should be either `create('prop1', options)` or `create(['prop1', 'prop2'], options)`"].join(` -`)),Object.keys(d).length!==0&&console.error(`MUI: Unrecognized argument(s) [${Object.keys(d).join(",")}].`)}return(Array.isArray(o)?o:[o]).map(u=>`${u} ${typeof i=="string"?i:Ma(i)} ${l} ${typeof c=="string"?c:Ma(c)}`).join(",")}},e,{easing:t,duration:n})}const Qp={mobileStepper:1e3,fab:1050,speedDial:1050,appBar:1100,drawer:1200,modal:1300,snackbar:1400,tooltip:1500},ew=Qp,tw=["breakpoints","mixins","spacing","palette","transitions","typography","shape"];function nw(e={},...t){const{mixins:n={},palette:r={},transitions:o={},typography:s={}}=e,i=Ne(e,tw);if(e.vars)throw new Error(process.env.NODE_ENV!=="production"?"MUI: `vars` is a private field used for CSS variables support.\nPlease use another name.":zt(18));const l=Vp(r),c=To(e);let d=Qe(c,{mixins:Np(c.breakpoints,n),palette:l,shadows:Xp.slice(),typography:Fp(l,s),transitions:Zp(o),zIndex:O({},ew)});if(d=Qe(d,i),d=t.reduce((u,h)=>Qe(u,h),d),process.env.NODE_ENV!=="production"){const u=["active","checked","completed","disabled","error","expanded","focused","focusVisible","required","selected"],h=(w,b)=>{let x;for(x in w){const f=w[x];if(u.indexOf(x)!==-1&&Object.keys(f).length>0){if(process.env.NODE_ENV!=="production"){const m=ur("",x);console.error([`MUI: The \`${b}\` component increases the CSS specificity of the \`${x}\` internal state.`,"You can not override it like this: ",JSON.stringify(w,null,2),"",`Instead, you need to use the '&.${m}' syntax:`,JSON.stringify({root:{[`&.${m}`]:f}},null,2),"","https://mui.com/r/state-classes-guide"].join(` -`))}w[x]={}}}};Object.keys(d.components).forEach(w=>{const b=d.components[w].styleOverrides;b&&w.indexOf("Mui")===0&&h(b,w)})}return d.unstable_sxConfig=O({},jo,i==null?void 0:i.unstable_sxConfig),d.unstable_sx=function(h){return Co({sx:h,theme:this})},d}const rw=nw(),Oo=rw,_o="$$material";function Po({props:e,name:t}){return gp({props:e,name:t,defaultTheme:Oo,themeId:_o})}const ow=e=>qn(e)&&e!=="classes",aw=mp({themeId:_o,defaultTheme:Oo,rootShouldForwardProp:ow}),In=aw;function sw(e){return ur("MuiSvgIcon",e)}ci("MuiSvgIcon",["root","colorPrimary","colorSecondary","colorAction","colorError","colorDisabled","fontSizeInherit","fontSizeSmall","fontSizeMedium","fontSizeLarge"]);const iw=["children","className","color","component","fontSize","htmlColor","inheritViewBox","titleAccess","viewBox"],lw=e=>{const{color:t,fontSize:n,classes:r}=e,o={root:["root",t!=="inherit"&&`color${Ye(t)}`,`fontSize${Ye(n)}`]};return ko(o,sw,r)},cw=In("svg",{name:"MuiSvgIcon",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.root,n.color!=="inherit"&&t[`color${Ye(n.color)}`],t[`fontSize${Ye(n.fontSize)}`]]}})(({theme:e,ownerState:t})=>{var n,r,o,s,i,l,c,d,u,h,w,b,x;return{userSelect:"none",width:"1em",height:"1em",display:"inline-block",fill:t.hasSvgAsChild?void 0:"currentColor",flexShrink:0,transition:(n=e.transitions)==null||(r=n.create)==null?void 0:r.call(n,"fill",{duration:(o=e.transitions)==null||(o=o.duration)==null?void 0:o.shorter}),fontSize:{inherit:"inherit",small:((s=e.typography)==null||(i=s.pxToRem)==null?void 0:i.call(s,20))||"1.25rem",medium:((l=e.typography)==null||(c=l.pxToRem)==null?void 0:c.call(l,24))||"1.5rem",large:((d=e.typography)==null||(u=d.pxToRem)==null?void 0:u.call(d,35))||"2.1875rem"}[t.fontSize],color:(h=(w=(e.vars||e).palette)==null||(w=w[t.color])==null?void 0:w.main)!=null?h:{action:(b=(e.vars||e).palette)==null||(b=b.action)==null?void 0:b.active,disabled:(x=(e.vars||e).palette)==null||(x=x.action)==null?void 0:x.disabled,inherit:void 0}[t.color]}}),Io=M.forwardRef(function(t,n){const r=Po({props:t,name:"MuiSvgIcon"}),{children:o,className:s,color:i="inherit",component:l="svg",fontSize:c="medium",htmlColor:d,inheritViewBox:u=!1,titleAccess:h,viewBox:w="0 0 24 24"}=r,b=Ne(r,iw),x=M.isValidElement(o)&&o.type==="svg",f=O({},r,{color:i,component:l,fontSize:c,instanceFontSize:t.fontSize,inheritViewBox:u,viewBox:w,hasSvgAsChild:x}),m={};u||(m.viewBox=w);const S=lw(f);return a.jsxs(cw,O({as:l,className:ot(S.root,s),focusable:"false",color:d,"aria-hidden":h?void 0:!0,role:h?"img":void 0,ref:n},m,b,x&&o.props,{ownerState:f,children:[x?o.props.children:o,h?a.jsx("title",{children:h}):null]}))});process.env.NODE_ENV!=="production"&&(Io.propTypes={children:p.node,classes:p.object,className:p.string,color:p.oneOfType([p.oneOf(["inherit","action","disabled","primary","secondary","error","info","success","warning"]),p.string]),component:p.elementType,fontSize:p.oneOfType([p.oneOf(["inherit","large","medium","small"]),p.string]),htmlColor:p.string,inheritViewBox:p.bool,shapeRendering:p.string,sx:p.oneOfType([p.arrayOf(p.oneOfType([p.func,p.object,p.bool])),p.func,p.object]),titleAccess:p.string,viewBox:p.string});Io.muiName="SvgIcon";const $a=Io;function hi(e,t){function n(r,o){return a.jsx($a,O({"data-testid":`${t}Icon`,ref:o},r,{children:e}))}return process.env.NODE_ENV!=="production"&&(n.displayName=`${t}Icon`),n.muiName=$a.muiName,M.memo(M.forwardRef(n))}const dw={configure:e=>{process.env.NODE_ENV!=="production"&&console.warn(["MUI: `ClassNameGenerator` import from `@mui/material/utils` is outdated and might cause unexpected issues.","","You should use `import { unstable_ClassNameGenerator } from '@mui/material/className'` instead","","The detail of the issue: https://github.com/mui/material-ui/issues/30011#issuecomment-1024993401","","The updated documentation: https://mui.com/guides/classname-generator/"].join(` -`)),ii.configure(e)}},uw=Object.freeze(Object.defineProperty({__proto__:null,capitalize:Ye,createChainedFunction:zd,createSvgIcon:hi,debounce:Ld,deprecatedPropType:Fd,isMuiElement:Gd,ownerDocument:Kn,ownerWindow:Ud,requirePropFactory:qd,setRef:Jn,unstable_ClassNameGenerator:dw,unstable_useEnhancedEffect:Lt,unstable_useId:ri,unsupportedProp:Yd,useControlled:oi,useEventCallback:Zr,useForkRef:yt,useIsFocusVisible:ai},Symbol.toStringTag,{value:"Module"})),pw=xd(uw);var Da;function ww(){return Da||(Da=1,function(e){"use client";Object.defineProperty(e,"__esModule",{value:!0}),Object.defineProperty(e,"default",{enumerable:!0,get:function(){return t.createSvgIcon}});var t=pw}(Pr)),Pr}var fw=yd;Object.defineProperty(xo,"__esModule",{value:!0});var gi=xo.default=void 0,mw=fw(ww()),hw=a;gi=xo.default=(0,mw.default)((0,hw.jsx)("path",{d:"m10 17 5-5-5-5z"}),"ArrowRight");function gw(e){return typeof e=="string"}function un(e,t,n){return e===void 0||gw(e)?t:O({},t,{ownerState:O({},t.ownerState,n)})}const bw={disableDefaultClasses:!1},vw=M.createContext(bw);function xw(e){const{disableDefaultClasses:t}=M.useContext(vw);return n=>t?"":e(n)}function yw(e,t=[]){if(e===void 0)return{};const n={};return Object.keys(e).filter(r=>r.match(/^on[A-Z]/)&&typeof e[r]=="function"&&!t.includes(r)).forEach(r=>{n[r]=e[r]}),n}function Nw(e,t,n){return typeof e=="function"?e(t,n):e}function Aa(e){if(e===void 0)return{};const t={};return Object.keys(e).filter(n=>!(n.match(/^on[A-Z]/)&&typeof e[n]=="function")).forEach(n=>{t[n]=e[n]}),t}function kw(e){const{getSlotProps:t,additionalProps:n,externalSlotProps:r,externalForwardedProps:o,className:s}=e;if(!t){const b=ot(n==null?void 0:n.className,s,o==null?void 0:o.className,r==null?void 0:r.className),x=O({},n==null?void 0:n.style,o==null?void 0:o.style,r==null?void 0:r.style),f=O({},n,o,r);return b.length>0&&(f.className=b),Object.keys(x).length>0&&(f.style=x),{props:f,internalRef:void 0}}const i=yw(O({},o,r)),l=Aa(r),c=Aa(o),d=t(i),u=ot(d==null?void 0:d.className,n==null?void 0:n.className,s,o==null?void 0:o.className,r==null?void 0:r.className),h=O({},d==null?void 0:d.style,n==null?void 0:n.style,o==null?void 0:o.style,r==null?void 0:r.style),w=O({},d,n,c,l);return u.length>0&&(w.className=u),Object.keys(h).length>0&&(w.style=h),{props:w,internalRef:d.ref}}const Sw=["elementType","externalSlotProps","ownerState","skipResolvingSlotProps"];function Ew(e){var t;const{elementType:n,externalSlotProps:r,ownerState:o,skipResolvingSlotProps:s=!1}=e,i=Ne(e,Sw),l=s?{}:Nw(r,o),{props:c,internalRef:d}=kw(O({},i,{externalSlotProps:l})),u=yt(d,l==null?void 0:l.ref,(t=e.additionalProps)==null?void 0:t.ref);return un(n,O({},c,{ref:u}),o)}const bi="base";function jw(e){return`${bi}--${e}`}function Cw(e,t){return`${bi}-${e}-${t}`}function vi(e,t){const n=li[t];return n?jw(n):Cw(e,t)}function Tw(e,t){const n={};return t.forEach(r=>{n[r]=vi(e,r)}),n}function Rw(e){return typeof e=="function"?e():e}const Qn=M.forwardRef(function(t,n){const{children:r,container:o,disablePortal:s=!1}=t,[i,l]=M.useState(null),c=yt(M.isValidElement(r)?r.ref:null,n);if(Lt(()=>{s||l(Rw(o)||document.body)},[o,s]),Lt(()=>{if(i&&!s)return Jn(n,i),()=>{Jn(n,null)}},[n,i,s]),s){if(M.isValidElement(r)){const d={ref:c};return M.cloneElement(r,d)}return a.jsx(M.Fragment,{children:r})}return a.jsx(M.Fragment,{children:i&&Ol.createPortal(r,i)})});process.env.NODE_ENV!=="production"&&(Qn.propTypes={children:p.node,container:p.oneOfType([xn,p.func]),disablePortal:p.bool});process.env.NODE_ENV!=="production"&&(Qn["propTypes"]=Id(Qn.propTypes));var Ce="top",ze="bottom",Le="right",Te="left",Mo="auto",Mn=[Ce,ze,Le,Te],Ft="start",Nn="end",Ow="clippingParents",xi="viewport",an="popper",_w="reference",Ba=Mn.reduce(function(e,t){return e.concat([t+"-"+Ft,t+"-"+Nn])},[]),yi=[].concat(Mn,[Mo]).reduce(function(e,t){return e.concat([t,t+"-"+Ft,t+"-"+Nn])},[]),Pw="beforeRead",Iw="read",Mw="afterRead",$w="beforeMain",Dw="main",Aw="afterMain",Bw="beforeWrite",Vw="write",zw="afterWrite",Lw=[Pw,Iw,Mw,$w,Dw,Aw,Bw,Vw,zw];function We(e){return e?(e.nodeName||"").toLowerCase():null}function $e(e){if(e==null)return window;if(e.toString()!=="[object Window]"){var t=e.ownerDocument;return t&&t.defaultView||window}return e}function kt(e){var t=$e(e).Element;return e instanceof t||e instanceof Element}function Ve(e){var t=$e(e).HTMLElement;return e instanceof t||e instanceof HTMLElement}function $o(e){if(typeof ShadowRoot>"u")return!1;var t=$e(e).ShadowRoot;return e instanceof t||e instanceof ShadowRoot}function Fw(e){var t=e.state;Object.keys(t.elements).forEach(function(n){var r=t.styles[n]||{},o=t.attributes[n]||{},s=t.elements[n];!Ve(s)||!We(s)||(Object.assign(s.style,r),Object.keys(o).forEach(function(i){var l=o[i];l===!1?s.removeAttribute(i):s.setAttribute(i,l===!0?"":l)}))})}function Gw(e){var t=e.state,n={popper:{position:t.options.strategy,left:"0",top:"0",margin:"0"},arrow:{position:"absolute"},reference:{}};return Object.assign(t.elements.popper.style,n.popper),t.styles=n,t.elements.arrow&&Object.assign(t.elements.arrow.style,n.arrow),function(){Object.keys(t.elements).forEach(function(r){var o=t.elements[r],s=t.attributes[r]||{},i=Object.keys(t.styles.hasOwnProperty(r)?t.styles[r]:n[r]),l=i.reduce(function(c,d){return c[d]="",c},{});!Ve(o)||!We(o)||(Object.assign(o.style,l),Object.keys(s).forEach(function(c){o.removeAttribute(c)}))})}}const Uw={name:"applyStyles",enabled:!0,phase:"write",fn:Fw,effect:Gw,requires:["computeStyles"]};function Xe(e){return e.split("-")[0]}var ht=Math.max,er=Math.min,Gt=Math.round;function eo(){var e=navigator.userAgentData;return e!=null&&e.brands&&Array.isArray(e.brands)?e.brands.map(function(t){return t.brand+"/"+t.version}).join(" "):navigator.userAgent}function Ni(){return!/^((?!chrome|android).)*safari/i.test(eo())}function Ut(e,t,n){t===void 0&&(t=!1),n===void 0&&(n=!1);var r=e.getBoundingClientRect(),o=1,s=1;t&&Ve(e)&&(o=e.offsetWidth>0&&Gt(r.width)/e.offsetWidth||1,s=e.offsetHeight>0&&Gt(r.height)/e.offsetHeight||1);var i=kt(e)?$e(e):window,l=i.visualViewport,c=!Ni()&&n,d=(r.left+(c&&l?l.offsetLeft:0))/o,u=(r.top+(c&&l?l.offsetTop:0))/s,h=r.width/o,w=r.height/s;return{width:h,height:w,top:u,right:d+h,bottom:u+w,left:d,x:d,y:u}}function Do(e){var t=Ut(e),n=e.offsetWidth,r=e.offsetHeight;return Math.abs(t.width-n)<=1&&(n=t.width),Math.abs(t.height-r)<=1&&(r=t.height),{x:e.offsetLeft,y:e.offsetTop,width:n,height:r}}function ki(e,t){var n=t.getRootNode&&t.getRootNode();if(e.contains(t))return!0;if(n&&$o(n)){var r=t;do{if(r&&e.isSameNode(r))return!0;r=r.parentNode||r.host}while(r)}return!1}function tt(e){return $e(e).getComputedStyle(e)}function qw(e){return["table","td","th"].indexOf(We(e))>=0}function it(e){return((kt(e)?e.ownerDocument:e.document)||window.document).documentElement}function yr(e){return We(e)==="html"?e:e.assignedSlot||e.parentNode||($o(e)?e.host:null)||it(e)}function Va(e){return!Ve(e)||tt(e).position==="fixed"?null:e.offsetParent}function Hw(e){var t=/firefox/i.test(eo()),n=/Trident/i.test(eo());if(n&&Ve(e)){var r=tt(e);if(r.position==="fixed")return null}var o=yr(e);for($o(o)&&(o=o.host);Ve(o)&&["html","body"].indexOf(We(o))<0;){var s=tt(o);if(s.transform!=="none"||s.perspective!=="none"||s.contain==="paint"||["transform","perspective"].indexOf(s.willChange)!==-1||t&&s.willChange==="filter"||t&&s.filter&&s.filter!=="none")return o;o=o.parentNode}return null}function $n(e){for(var t=$e(e),n=Va(e);n&&qw(n)&&tt(n).position==="static";)n=Va(n);return n&&(We(n)==="html"||We(n)==="body"&&tt(n).position==="static")?t:n||Hw(e)||t}function Ao(e){return["top","bottom"].indexOf(e)>=0?"x":"y"}function hn(e,t,n){return ht(e,er(t,n))}function Xw(e,t,n){var r=hn(e,t,n);return r>n?n:r}function Si(){return{top:0,right:0,bottom:0,left:0}}function Ei(e){return Object.assign({},Si(),e)}function ji(e,t){return t.reduce(function(n,r){return n[r]=e,n},{})}var Yw=function(t,n){return t=typeof t=="function"?t(Object.assign({},n.rects,{placement:n.placement})):t,Ei(typeof t!="number"?t:ji(t,Mn))};function Ww(e){var t,n=e.state,r=e.name,o=e.options,s=n.elements.arrow,i=n.modifiersData.popperOffsets,l=Xe(n.placement),c=Ao(l),d=[Te,Le].indexOf(l)>=0,u=d?"height":"width";if(!(!s||!i)){var h=Yw(o.padding,n),w=Do(s),b=c==="y"?Ce:Te,x=c==="y"?ze:Le,f=n.rects.reference[u]+n.rects.reference[c]-i[c]-n.rects.popper[u],m=i[c]-n.rects.reference[c],S=$n(s),R=S?c==="y"?S.clientHeight||0:S.clientWidth||0:0,j=f/2-m/2,E=h[b],v=R-w[u]-h[x],P=R/2-w[u]/2+j,V=hn(E,P,v),U=c;n.modifiersData[r]=(t={},t[U]=V,t.centerOffset=V-P,t)}}function Kw(e){var t=e.state,n=e.options,r=n.element,o=r===void 0?"[data-popper-arrow]":r;o!=null&&(typeof o=="string"&&(o=t.elements.popper.querySelector(o),!o)||ki(t.elements.popper,o)&&(t.elements.arrow=o))}const Jw={name:"arrow",enabled:!0,phase:"main",fn:Ww,effect:Kw,requires:["popperOffsets"],requiresIfExists:["preventOverflow"]};function qt(e){return e.split("-")[1]}var Zw={top:"auto",right:"auto",bottom:"auto",left:"auto"};function Qw(e,t){var n=e.x,r=e.y,o=t.devicePixelRatio||1;return{x:Gt(n*o)/o||0,y:Gt(r*o)/o||0}}function za(e){var t,n=e.popper,r=e.popperRect,o=e.placement,s=e.variation,i=e.offsets,l=e.position,c=e.gpuAcceleration,d=e.adaptive,u=e.roundOffsets,h=e.isFixed,w=i.x,b=w===void 0?0:w,x=i.y,f=x===void 0?0:x,m=typeof u=="function"?u({x:b,y:f}):{x:b,y:f};b=m.x,f=m.y;var S=i.hasOwnProperty("x"),R=i.hasOwnProperty("y"),j=Te,E=Ce,v=window;if(d){var P=$n(n),V="clientHeight",U="clientWidth";if(P===$e(n)&&(P=it(n),tt(P).position!=="static"&&l==="absolute"&&(V="scrollHeight",U="scrollWidth")),P=P,o===Ce||(o===Te||o===Le)&&s===Nn){E=ze;var C=h&&P===v&&v.visualViewport?v.visualViewport.height:P[V];f-=C-r.height,f*=c?1:-1}if(o===Te||(o===Ce||o===ze)&&s===Nn){j=Le;var _=h&&P===v&&v.visualViewport?v.visualViewport.width:P[U];b-=_-r.width,b*=c?1:-1}}var k=Object.assign({position:l},d&&Zw),D=u===!0?Qw({x:b,y:f},$e(n)):{x:b,y:f};if(b=D.x,f=D.y,c){var $;return Object.assign({},k,($={},$[E]=R?"0":"",$[j]=S?"0":"",$.transform=(v.devicePixelRatio||1)<=1?"translate("+b+"px, "+f+"px)":"translate3d("+b+"px, "+f+"px, 0)",$))}return Object.assign({},k,(t={},t[E]=R?f+"px":"",t[j]=S?b+"px":"",t.transform="",t))}function ef(e){var t=e.state,n=e.options,r=n.gpuAcceleration,o=r===void 0?!0:r,s=n.adaptive,i=s===void 0?!0:s,l=n.roundOffsets,c=l===void 0?!0:l,d={placement:Xe(t.placement),variation:qt(t.placement),popper:t.elements.popper,popperRect:t.rects.popper,gpuAcceleration:o,isFixed:t.options.strategy==="fixed"};t.modifiersData.popperOffsets!=null&&(t.styles.popper=Object.assign({},t.styles.popper,za(Object.assign({},d,{offsets:t.modifiersData.popperOffsets,position:t.options.strategy,adaptive:i,roundOffsets:c})))),t.modifiersData.arrow!=null&&(t.styles.arrow=Object.assign({},t.styles.arrow,za(Object.assign({},d,{offsets:t.modifiersData.arrow,position:"absolute",adaptive:!1,roundOffsets:c})))),t.attributes.popper=Object.assign({},t.attributes.popper,{"data-popper-placement":t.placement})}const tf={name:"computeStyles",enabled:!0,phase:"beforeWrite",fn:ef,data:{}};var Fn={passive:!0};function nf(e){var t=e.state,n=e.instance,r=e.options,o=r.scroll,s=o===void 0?!0:o,i=r.resize,l=i===void 0?!0:i,c=$e(t.elements.popper),d=[].concat(t.scrollParents.reference,t.scrollParents.popper);return s&&d.forEach(function(u){u.addEventListener("scroll",n.update,Fn)}),l&&c.addEventListener("resize",n.update,Fn),function(){s&&d.forEach(function(u){u.removeEventListener("scroll",n.update,Fn)}),l&&c.removeEventListener("resize",n.update,Fn)}}const rf={name:"eventListeners",enabled:!0,phase:"write",fn:function(){},effect:nf,data:{}};var of={left:"right",right:"left",bottom:"top",top:"bottom"};function Xn(e){return e.replace(/left|right|bottom|top/g,function(t){return of[t]})}var af={start:"end",end:"start"};function La(e){return e.replace(/start|end/g,function(t){return af[t]})}function Bo(e){var t=$e(e),n=t.pageXOffset,r=t.pageYOffset;return{scrollLeft:n,scrollTop:r}}function Vo(e){return Ut(it(e)).left+Bo(e).scrollLeft}function sf(e,t){var n=$e(e),r=it(e),o=n.visualViewport,s=r.clientWidth,i=r.clientHeight,l=0,c=0;if(o){s=o.width,i=o.height;var d=Ni();(d||!d&&t==="fixed")&&(l=o.offsetLeft,c=o.offsetTop)}return{width:s,height:i,x:l+Vo(e),y:c}}function lf(e){var t,n=it(e),r=Bo(e),o=(t=e.ownerDocument)==null?void 0:t.body,s=ht(n.scrollWidth,n.clientWidth,o?o.scrollWidth:0,o?o.clientWidth:0),i=ht(n.scrollHeight,n.clientHeight,o?o.scrollHeight:0,o?o.clientHeight:0),l=-r.scrollLeft+Vo(e),c=-r.scrollTop;return tt(o||n).direction==="rtl"&&(l+=ht(n.clientWidth,o?o.clientWidth:0)-s),{width:s,height:i,x:l,y:c}}function zo(e){var t=tt(e),n=t.overflow,r=t.overflowX,o=t.overflowY;return/auto|scroll|overlay|hidden/.test(n+o+r)}function Ci(e){return["html","body","#document"].indexOf(We(e))>=0?e.ownerDocument.body:Ve(e)&&zo(e)?e:Ci(yr(e))}function gn(e,t){var n;t===void 0&&(t=[]);var r=Ci(e),o=r===((n=e.ownerDocument)==null?void 0:n.body),s=$e(r),i=o?[s].concat(s.visualViewport||[],zo(r)?r:[]):r,l=t.concat(i);return o?l:l.concat(gn(yr(i)))}function to(e){return Object.assign({},e,{left:e.x,top:e.y,right:e.x+e.width,bottom:e.y+e.height})}function cf(e,t){var n=Ut(e,!1,t==="fixed");return n.top=n.top+e.clientTop,n.left=n.left+e.clientLeft,n.bottom=n.top+e.clientHeight,n.right=n.left+e.clientWidth,n.width=e.clientWidth,n.height=e.clientHeight,n.x=n.left,n.y=n.top,n}function Fa(e,t,n){return t===xi?to(sf(e,n)):kt(t)?cf(t,n):to(lf(it(e)))}function df(e){var t=gn(yr(e)),n=["absolute","fixed"].indexOf(tt(e).position)>=0,r=n&&Ve(e)?$n(e):e;return kt(r)?t.filter(function(o){return kt(o)&&ki(o,r)&&We(o)!=="body"}):[]}function uf(e,t,n,r){var o=t==="clippingParents"?df(e):[].concat(t),s=[].concat(o,[n]),i=s[0],l=s.reduce(function(c,d){var u=Fa(e,d,r);return c.top=ht(u.top,c.top),c.right=er(u.right,c.right),c.bottom=er(u.bottom,c.bottom),c.left=ht(u.left,c.left),c},Fa(e,i,r));return l.width=l.right-l.left,l.height=l.bottom-l.top,l.x=l.left,l.y=l.top,l}function Ti(e){var t=e.reference,n=e.element,r=e.placement,o=r?Xe(r):null,s=r?qt(r):null,i=t.x+t.width/2-n.width/2,l=t.y+t.height/2-n.height/2,c;switch(o){case Ce:c={x:i,y:t.y-n.height};break;case ze:c={x:i,y:t.y+t.height};break;case Le:c={x:t.x+t.width,y:l};break;case Te:c={x:t.x-n.width,y:l};break;default:c={x:t.x,y:t.y}}var d=o?Ao(o):null;if(d!=null){var u=d==="y"?"height":"width";switch(s){case Ft:c[d]=c[d]-(t[u]/2-n[u]/2);break;case Nn:c[d]=c[d]+(t[u]/2-n[u]/2);break}}return c}function kn(e,t){t===void 0&&(t={});var n=t,r=n.placement,o=r===void 0?e.placement:r,s=n.strategy,i=s===void 0?e.strategy:s,l=n.boundary,c=l===void 0?Ow:l,d=n.rootBoundary,u=d===void 0?xi:d,h=n.elementContext,w=h===void 0?an:h,b=n.altBoundary,x=b===void 0?!1:b,f=n.padding,m=f===void 0?0:f,S=Ei(typeof m!="number"?m:ji(m,Mn)),R=w===an?_w:an,j=e.rects.popper,E=e.elements[x?R:w],v=uf(kt(E)?E:E.contextElement||it(e.elements.popper),c,u,i),P=Ut(e.elements.reference),V=Ti({reference:P,element:j,strategy:"absolute",placement:o}),U=to(Object.assign({},j,V)),C=w===an?U:P,_={top:v.top-C.top+S.top,bottom:C.bottom-v.bottom+S.bottom,left:v.left-C.left+S.left,right:C.right-v.right+S.right},k=e.modifiersData.offset;if(w===an&&k){var D=k[o];Object.keys(_).forEach(function($){var J=[Le,ze].indexOf($)>=0?1:-1,Y=[Ce,ze].indexOf($)>=0?"y":"x";_[$]+=D[Y]*J})}return _}function pf(e,t){t===void 0&&(t={});var n=t,r=n.placement,o=n.boundary,s=n.rootBoundary,i=n.padding,l=n.flipVariations,c=n.allowedAutoPlacements,d=c===void 0?yi:c,u=qt(r),h=u?l?Ba:Ba.filter(function(x){return qt(x)===u}):Mn,w=h.filter(function(x){return d.indexOf(x)>=0});w.length===0&&(w=h);var b=w.reduce(function(x,f){return x[f]=kn(e,{placement:f,boundary:o,rootBoundary:s,padding:i})[Xe(f)],x},{});return Object.keys(b).sort(function(x,f){return b[x]-b[f]})}function wf(e){if(Xe(e)===Mo)return[];var t=Xn(e);return[La(e),t,La(t)]}function ff(e){var t=e.state,n=e.options,r=e.name;if(!t.modifiersData[r]._skip){for(var o=n.mainAxis,s=o===void 0?!0:o,i=n.altAxis,l=i===void 0?!0:i,c=n.fallbackPlacements,d=n.padding,u=n.boundary,h=n.rootBoundary,w=n.altBoundary,b=n.flipVariations,x=b===void 0?!0:b,f=n.allowedAutoPlacements,m=t.options.placement,S=Xe(m),R=S===m,j=c||(R||!x?[Xn(m)]:wf(m)),E=[m].concat(j).reduce(function(B,X){return B.concat(Xe(X)===Mo?pf(t,{placement:X,boundary:u,rootBoundary:h,padding:d,flipVariations:x,allowedAutoPlacements:f}):X)},[]),v=t.rects.reference,P=t.rects.popper,V=new Map,U=!0,C=E[0],_=0;_=0,Y=J?"width":"height",F=kn(t,{placement:k,boundary:u,rootBoundary:h,altBoundary:w,padding:d}),te=J?$?Le:Te:$?ze:Ce;v[Y]>P[Y]&&(te=Xn(te));var se=Xn(te),oe=[];if(s&&oe.push(F[D]<=0),l&&oe.push(F[te]<=0,F[se]<=0),oe.every(function(B){return B})){C=k,U=!1;break}V.set(k,oe)}if(U)for(var y=x?3:1,T=function(X){var q=E.find(function(H){var G=V.get(H);if(G)return G.slice(0,X).every(function(K){return K})});if(q)return C=q,"break"},z=y;z>0;z--){var L=T(z);if(L==="break")break}t.placement!==C&&(t.modifiersData[r]._skip=!0,t.placement=C,t.reset=!0)}}const mf={name:"flip",enabled:!0,phase:"main",fn:ff,requiresIfExists:["offset"],data:{_skip:!1}};function Ga(e,t,n){return n===void 0&&(n={x:0,y:0}),{top:e.top-t.height-n.y,right:e.right-t.width+n.x,bottom:e.bottom-t.height+n.y,left:e.left-t.width-n.x}}function Ua(e){return[Ce,Le,ze,Te].some(function(t){return e[t]>=0})}function hf(e){var t=e.state,n=e.name,r=t.rects.reference,o=t.rects.popper,s=t.modifiersData.preventOverflow,i=kn(t,{elementContext:"reference"}),l=kn(t,{altBoundary:!0}),c=Ga(i,r),d=Ga(l,o,s),u=Ua(c),h=Ua(d);t.modifiersData[n]={referenceClippingOffsets:c,popperEscapeOffsets:d,isReferenceHidden:u,hasPopperEscaped:h},t.attributes.popper=Object.assign({},t.attributes.popper,{"data-popper-reference-hidden":u,"data-popper-escaped":h})}const gf={name:"hide",enabled:!0,phase:"main",requiresIfExists:["preventOverflow"],fn:hf};function bf(e,t,n){var r=Xe(e),o=[Te,Ce].indexOf(r)>=0?-1:1,s=typeof n=="function"?n(Object.assign({},t,{placement:e})):n,i=s[0],l=s[1];return i=i||0,l=(l||0)*o,[Te,Le].indexOf(r)>=0?{x:l,y:i}:{x:i,y:l}}function vf(e){var t=e.state,n=e.options,r=e.name,o=n.offset,s=o===void 0?[0,0]:o,i=yi.reduce(function(u,h){return u[h]=bf(h,t.rects,s),u},{}),l=i[t.placement],c=l.x,d=l.y;t.modifiersData.popperOffsets!=null&&(t.modifiersData.popperOffsets.x+=c,t.modifiersData.popperOffsets.y+=d),t.modifiersData[r]=i}const xf={name:"offset",enabled:!0,phase:"main",requires:["popperOffsets"],fn:vf};function yf(e){var t=e.state,n=e.name;t.modifiersData[n]=Ti({reference:t.rects.reference,element:t.rects.popper,strategy:"absolute",placement:t.placement})}const Nf={name:"popperOffsets",enabled:!0,phase:"read",fn:yf,data:{}};function kf(e){return e==="x"?"y":"x"}function Sf(e){var t=e.state,n=e.options,r=e.name,o=n.mainAxis,s=o===void 0?!0:o,i=n.altAxis,l=i===void 0?!1:i,c=n.boundary,d=n.rootBoundary,u=n.altBoundary,h=n.padding,w=n.tether,b=w===void 0?!0:w,x=n.tetherOffset,f=x===void 0?0:x,m=kn(t,{boundary:c,rootBoundary:d,padding:h,altBoundary:u}),S=Xe(t.placement),R=qt(t.placement),j=!R,E=Ao(S),v=kf(E),P=t.modifiersData.popperOffsets,V=t.rects.reference,U=t.rects.popper,C=typeof f=="function"?f(Object.assign({},t.rects,{placement:t.placement})):f,_=typeof C=="number"?{mainAxis:C,altAxis:C}:Object.assign({mainAxis:0,altAxis:0},C),k=t.modifiersData.offset?t.modifiersData.offset[t.placement]:null,D={x:0,y:0};if(P){if(s){var $,J=E==="y"?Ce:Te,Y=E==="y"?ze:Le,F=E==="y"?"height":"width",te=P[E],se=te+m[J],oe=te-m[Y],y=b?-U[F]/2:0,T=R===Ft?V[F]:U[F],z=R===Ft?-U[F]:-V[F],L=t.elements.arrow,B=b&&L?Do(L):{width:0,height:0},X=t.modifiersData["arrow#persistent"]?t.modifiersData["arrow#persistent"].padding:Si(),q=X[J],H=X[Y],G=hn(0,V[F],B[F]),K=j?V[F]/2-y-G-q-_.mainAxis:T-G-q-_.mainAxis,Z=j?-V[F]/2+y+G+H+_.mainAxis:z+G+H+_.mainAxis,ue=t.elements.arrow&&$n(t.elements.arrow),I=ue?E==="y"?ue.clientTop||0:ue.clientLeft||0:0,ye=($=k==null?void 0:k[E])!=null?$:0,A=te+K-ye-I,xe=te+Z-ye,Ge=hn(b?er(se,A):se,te,b?ht(oe,xe):oe);P[E]=Ge,D[E]=Ge-te}if(l){var lt,Ee=E==="x"?Ce:Te,Dn=E==="x"?ze:Le,Ue=P[v],Et=v==="y"?"height":"width",ct=Ue+m[Ee],jt=Ue-m[Dn],Ct=[Ce,Te].indexOf(S)!==-1,Tt=(lt=k==null?void 0:k[v])!=null?lt:0,dt=Ct?ct:Ue-V[Et]-U[Et]-Tt+_.altAxis,Jt=Ct?Ue+V[Et]+U[Et]-Tt-_.altAxis:jt,An=b&&Ct?Xw(dt,Ue,Jt):hn(b?dt:ct,Ue,b?Jt:jt);P[v]=An,D[v]=An-Ue}t.modifiersData[r]=D}}const Ef={name:"preventOverflow",enabled:!0,phase:"main",fn:Sf,requiresIfExists:["offset"]};function jf(e){return{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}}function Cf(e){return e===$e(e)||!Ve(e)?Bo(e):jf(e)}function Tf(e){var t=e.getBoundingClientRect(),n=Gt(t.width)/e.offsetWidth||1,r=Gt(t.height)/e.offsetHeight||1;return n!==1||r!==1}function Rf(e,t,n){n===void 0&&(n=!1);var r=Ve(t),o=Ve(t)&&Tf(t),s=it(t),i=Ut(e,o,n),l={scrollLeft:0,scrollTop:0},c={x:0,y:0};return(r||!r&&!n)&&((We(t)!=="body"||zo(s))&&(l=Cf(t)),Ve(t)?(c=Ut(t,!0),c.x+=t.clientLeft,c.y+=t.clientTop):s&&(c.x=Vo(s))),{x:i.left+l.scrollLeft-c.x,y:i.top+l.scrollTop-c.y,width:i.width,height:i.height}}function Of(e){var t=new Map,n=new Set,r=[];e.forEach(function(s){t.set(s.name,s)});function o(s){n.add(s.name);var i=[].concat(s.requires||[],s.requiresIfExists||[]);i.forEach(function(l){if(!n.has(l)){var c=t.get(l);c&&o(c)}}),r.push(s)}return e.forEach(function(s){n.has(s.name)||o(s)}),r}function _f(e){var t=Of(e);return Lw.reduce(function(n,r){return n.concat(t.filter(function(o){return o.phase===r}))},[])}function Pf(e){var t;return function(){return t||(t=new Promise(function(n){Promise.resolve().then(function(){t=void 0,n(e())})})),t}}function If(e){var t=e.reduce(function(n,r){var o=n[r.name];return n[r.name]=o?Object.assign({},o,r,{options:Object.assign({},o.options,r.options),data:Object.assign({},o.data,r.data)}):r,n},{});return Object.keys(t).map(function(n){return t[n]})}var qa={placement:"bottom",modifiers:[],strategy:"absolute"};function Ha(){for(var e=arguments.length,t=new Array(e),n=0;nko({root:["root"]},xw(Af)),Gf={},Uf=M.forwardRef(function(t,n){var r;const{anchorEl:o,children:s,direction:i,disablePortal:l,modifiers:c,open:d,placement:u,popperOptions:h,popperRef:w,slotProps:b={},slots:x={},TransitionProps:f}=t,m=Ne(t,Bf),S=M.useRef(null),R=yt(S,n),j=M.useRef(null),E=yt(j,w),v=M.useRef(E);Lt(()=>{v.current=E},[E]),M.useImperativeHandle(w,()=>j.current,[]);const P=zf(u,i),[V,U]=M.useState(P),[C,_]=M.useState(tr(o));M.useEffect(()=>{j.current&&j.current.forceUpdate()}),M.useEffect(()=>{o&&_(tr(o))},[o]),Lt(()=>{if(!C||!d)return;const Y=se=>{U(se.placement)};if(process.env.NODE_ENV!=="production"&&C&&Nr(C)&&C.nodeType===1){const se=C.getBoundingClientRect();process.env.NODE_ENV!=="test"&&se.top===0&&se.left===0&&se.right===0&&se.bottom===0&&console.warn(["MUI: The `anchorEl` prop provided to the component is invalid.","The anchor element should be part of the document layout.","Make sure the element is present in the document or that it's not display none."].join(` -`))}let F=[{name:"preventOverflow",options:{altBoundary:l}},{name:"flip",options:{altBoundary:l}},{name:"onUpdate",enabled:!0,phase:"afterWrite",fn:({state:se})=>{Y(se)}}];c!=null&&(F=F.concat(c)),h&&h.modifiers!=null&&(F=F.concat(h.modifiers));const te=Df(C,S.current,O({placement:P},h,{modifiers:F}));return v.current(te),()=>{te.destroy(),v.current(null)}},[C,l,c,d,h,P]);const k={placement:V};f!==null&&(k.TransitionProps=f);const D=Ff(),$=(r=x.root)!=null?r:"div",J=Ew({elementType:$,externalSlotProps:b.root,externalForwardedProps:m,additionalProps:{role:"tooltip",ref:R},ownerState:t,className:D.root});return a.jsx($,O({},J,{children:typeof s=="function"?s(k):s}))}),Oi=M.forwardRef(function(t,n){const{anchorEl:r,children:o,container:s,direction:i="ltr",disablePortal:l=!1,keepMounted:c=!1,modifiers:d,open:u,placement:h="bottom",popperOptions:w=Gf,popperRef:b,style:x,transition:f=!1,slotProps:m={},slots:S={}}=t,R=Ne(t,Vf),[j,E]=M.useState(!0),v=()=>{E(!1)},P=()=>{E(!0)};if(!c&&!u&&(!f||j))return null;let V;if(s)V=s;else if(r){const _=tr(r);V=_&&Nr(_)?Kn(_).body:Kn(null).body}const U=!u&&c&&(!f||j)?"none":void 0,C=f?{in:u,onEnter:v,onExited:P}:void 0;return a.jsx(Qn,{disablePortal:l,container:V,children:a.jsx(Uf,O({anchorEl:r,direction:i,disablePortal:l,modifiers:d,ref:n,open:f?!j:u,placement:h,popperOptions:w,popperRef:b,slotProps:m,slots:S},R,{style:O({position:"fixed",top:0,left:0,display:U},x),TransitionProps:C,children:o}))})});process.env.NODE_ENV!=="production"&&(Oi.propTypes={anchorEl:yo(p.oneOfType([xn,p.object,p.func]),e=>{if(e.open){const t=tr(e.anchorEl);if(t&&Nr(t)&&t.nodeType===1){const n=t.getBoundingClientRect();if(process.env.NODE_ENV!=="test"&&n.top===0&&n.left===0&&n.right===0&&n.bottom===0)return new Error(["MUI: The `anchorEl` prop provided to the component is invalid.","The anchor element should be part of the document layout.","Make sure the element is present in the document or that it's not display none."].join(` +} });`:zt(12,h?` (${h})`:"",JSON.stringify(f.main)));return _a(f,"light",R,r),_a(f,"dark",j,r),f.contrastText||(f.contrastText=m(f.main)),f},b={dark:zr,light:Oa};return process.env.NODE_ENV!=="production"&&(b[t]||console.error(`MUI: The palette mode \`${t}\` is not supported.`)),Qe(O({common:O({},yn),mode:t,primary:w({color:s,name:"primary"}),secondary:w({color:i,name:"secondary",mainShade:"A400",lightShade:"A200",darkShade:"A700"}),error:w({color:l,name:"error"}),warning:w({color:d,name:"warning"}),info:w({color:c,name:"info"}),success:w({color:u,name:"success"}),grey:Ep,contrastThreshold:n,getContrastText:m,augmentColor:w,tonalOffset:r},b[t]),o)}const zp=["fontFamily","fontSize","fontWeightLight","fontWeightRegular","fontWeightMedium","fontWeightBold","htmlFontSize","allVariants","pxToRem"];function Lp(e){return Math.round(e*1e5)/1e5}const Pa={textTransform:"uppercase"},Ia='"Roboto", "Helvetica", "Arial", sans-serif';function Fp(e,t){const n=typeof t=="function"?t(e):t,{fontFamily:r=Ia,fontSize:o=14,fontWeightLight:s=300,fontWeightRegular:i=400,fontWeightMedium:l=500,fontWeightBold:c=700,htmlFontSize:u=16,allVariants:d,pxToRem:m}=n,w=Ne(n,zp);process.env.NODE_ENV!=="production"&&(typeof o!="number"&&console.error("MUI: `fontSize` is required to be a number."),typeof u!="number"&&console.error("MUI: `htmlFontSize` is required to be a number."));const b=o/14,x=m||(S=>`${S/u*b}rem`),f=(S,R,j,E,v)=>O({fontFamily:r,fontWeight:S,fontSize:x(R),lineHeight:j},r===Ia?{letterSpacing:`${Lp(E/R)}em`}:{},v,d),h={h1:f(s,96,1.167,-1.5),h2:f(s,60,1.2,-.5),h3:f(i,48,1.167,0),h4:f(i,34,1.235,.25),h5:f(i,24,1.334,0),h6:f(l,20,1.6,.15),subtitle1:f(i,16,1.75,.15),subtitle2:f(l,14,1.57,.1),body1:f(i,16,1.5,.15),body2:f(i,14,1.43,.15),button:f(l,14,1.75,.4,Pa),caption:f(i,12,1.66,.4),overline:f(i,12,2.66,1,Pa),inherit:{fontFamily:"inherit",fontWeight:"inherit",fontSize:"inherit",lineHeight:"inherit",letterSpacing:"inherit"}};return Qe(O({htmlFontSize:u,pxToRem:x,fontFamily:r,fontSize:o,fontWeightLight:s,fontWeightRegular:i,fontWeightMedium:l,fontWeightBold:c},h),w,{clone:!1})}const Gp=.2,Up=.14,qp=.12;function we(...e){return[`${e[0]}px ${e[1]}px ${e[2]}px ${e[3]}px rgba(0,0,0,${Gp})`,`${e[4]}px ${e[5]}px ${e[6]}px ${e[7]}px rgba(0,0,0,${Up})`,`${e[8]}px ${e[9]}px ${e[10]}px ${e[11]}px rgba(0,0,0,${qp})`].join(",")}const Hp=["none",we(0,2,1,-1,0,1,1,0,0,1,3,0),we(0,3,1,-2,0,2,2,0,0,1,5,0),we(0,3,3,-2,0,3,4,0,0,1,8,0),we(0,2,4,-1,0,4,5,0,0,1,10,0),we(0,3,5,-1,0,5,8,0,0,1,14,0),we(0,3,5,-1,0,6,10,0,0,1,18,0),we(0,4,5,-2,0,7,10,1,0,2,16,1),we(0,5,5,-3,0,8,10,1,0,3,14,2),we(0,5,6,-3,0,9,12,1,0,3,16,2),we(0,6,6,-3,0,10,14,1,0,4,18,3),we(0,6,7,-4,0,11,15,1,0,4,20,3),we(0,7,8,-4,0,12,17,2,0,5,22,4),we(0,7,8,-4,0,13,19,2,0,5,24,4),we(0,7,9,-4,0,14,21,2,0,5,26,4),we(0,8,9,-5,0,15,22,2,0,6,28,5),we(0,8,10,-5,0,16,24,2,0,6,30,5),we(0,8,11,-5,0,17,26,2,0,6,32,5),we(0,9,11,-5,0,18,28,2,0,7,34,6),we(0,9,12,-6,0,19,29,2,0,7,36,6),we(0,10,13,-6,0,20,31,3,0,8,38,7),we(0,10,13,-6,0,21,33,3,0,8,40,7),we(0,10,14,-6,0,22,35,3,0,8,42,7),we(0,11,14,-7,0,23,36,3,0,9,44,8),we(0,11,15,-7,0,24,38,3,0,9,46,8)],Xp=Hp,Yp=["duration","easing","delay"],Wp={easeInOut:"cubic-bezier(0.4, 0, 0.2, 1)",easeOut:"cubic-bezier(0.0, 0, 0.2, 1)",easeIn:"cubic-bezier(0.4, 0, 1, 1)",sharp:"cubic-bezier(0.4, 0, 0.6, 1)"},Kp={shortest:150,shorter:200,short:250,standard:300,complex:375,enteringScreen:225,leavingScreen:195};function Ma(e){return`${Math.round(e)}ms`}function Jp(e){if(!e)return 0;const t=e/36;return Math.round((4+15*t**.25+t/5)*10)}function Zp(e){const t=O({},Wp,e.easing),n=O({},Kp,e.duration);return O({getAutoHeightDuration:Jp,create:(o=["all"],s={})=>{const{duration:i=n.standard,easing:l=t.easeInOut,delay:c=0}=s,u=Ne(s,Yp);if(process.env.NODE_ENV!=="production"){const d=w=>typeof w=="string",m=w=>!isNaN(parseFloat(w));!d(o)&&!Array.isArray(o)&&console.error('MUI: Argument "props" must be a string or Array.'),!m(i)&&!d(i)&&console.error(`MUI: Argument "duration" must be a number or a string but found ${i}.`),d(l)||console.error('MUI: Argument "easing" must be a string.'),!m(c)&&!d(c)&&console.error('MUI: Argument "delay" must be a number or a string.'),typeof s!="object"&&console.error(["MUI: Secong argument of transition.create must be an object.","Arguments should be either `create('prop1', options)` or `create(['prop1', 'prop2'], options)`"].join(` +`)),Object.keys(u).length!==0&&console.error(`MUI: Unrecognized argument(s) [${Object.keys(u).join(",")}].`)}return(Array.isArray(o)?o:[o]).map(d=>`${d} ${typeof i=="string"?i:Ma(i)} ${l} ${typeof c=="string"?c:Ma(c)}`).join(",")}},e,{easing:t,duration:n})}const Qp={mobileStepper:1e3,fab:1050,speedDial:1050,appBar:1100,drawer:1200,modal:1300,snackbar:1400,tooltip:1500},ew=Qp,tw=["breakpoints","mixins","spacing","palette","transitions","typography","shape"];function nw(e={},...t){const{mixins:n={},palette:r={},transitions:o={},typography:s={}}=e,i=Ne(e,tw);if(e.vars)throw new Error(process.env.NODE_ENV!=="production"?"MUI: `vars` is a private field used for CSS variables support.\nPlease use another name.":zt(18));const l=Vp(r),c=To(e);let u=Qe(c,{mixins:Np(c.breakpoints,n),palette:l,shadows:Xp.slice(),typography:Fp(l,s),transitions:Zp(o),zIndex:O({},ew)});if(u=Qe(u,i),u=t.reduce((d,m)=>Qe(d,m),u),process.env.NODE_ENV!=="production"){const d=["active","checked","completed","disabled","error","expanded","focused","focusVisible","required","selected"],m=(w,b)=>{let x;for(x in w){const f=w[x];if(d.indexOf(x)!==-1&&Object.keys(f).length>0){if(process.env.NODE_ENV!=="production"){const h=ur("",x);console.error([`MUI: The \`${b}\` component increases the CSS specificity of the \`${x}\` internal state.`,"You can not override it like this: ",JSON.stringify(w,null,2),"",`Instead, you need to use the '&.${h}' syntax:`,JSON.stringify({root:{[`&.${h}`]:f}},null,2),"","https://mui.com/r/state-classes-guide"].join(` +`))}w[x]={}}}};Object.keys(u.components).forEach(w=>{const b=u.components[w].styleOverrides;b&&w.indexOf("Mui")===0&&m(b,w)})}return u.unstable_sxConfig=O({},jo,i==null?void 0:i.unstable_sxConfig),u.unstable_sx=function(m){return Co({sx:m,theme:this})},u}const rw=nw(),Oo=rw,_o="$$material";function Po({props:e,name:t}){return gp({props:e,name:t,defaultTheme:Oo,themeId:_o})}const ow=e=>qn(e)&&e!=="classes",aw=mp({themeId:_o,defaultTheme:Oo,rootShouldForwardProp:ow}),In=aw;function sw(e){return ur("MuiSvgIcon",e)}ci("MuiSvgIcon",["root","colorPrimary","colorSecondary","colorAction","colorError","colorDisabled","fontSizeInherit","fontSizeSmall","fontSizeMedium","fontSizeLarge"]);const iw=["children","className","color","component","fontSize","htmlColor","inheritViewBox","titleAccess","viewBox"],lw=e=>{const{color:t,fontSize:n,classes:r}=e,o={root:["root",t!=="inherit"&&`color${Ye(t)}`,`fontSize${Ye(n)}`]};return ko(o,sw,r)},cw=In("svg",{name:"MuiSvgIcon",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.root,n.color!=="inherit"&&t[`color${Ye(n.color)}`],t[`fontSize${Ye(n.fontSize)}`]]}})(({theme:e,ownerState:t})=>{var n,r,o,s,i,l,c,u,d,m,w,b,x;return{userSelect:"none",width:"1em",height:"1em",display:"inline-block",fill:t.hasSvgAsChild?void 0:"currentColor",flexShrink:0,transition:(n=e.transitions)==null||(r=n.create)==null?void 0:r.call(n,"fill",{duration:(o=e.transitions)==null||(o=o.duration)==null?void 0:o.shorter}),fontSize:{inherit:"inherit",small:((s=e.typography)==null||(i=s.pxToRem)==null?void 0:i.call(s,20))||"1.25rem",medium:((l=e.typography)==null||(c=l.pxToRem)==null?void 0:c.call(l,24))||"1.5rem",large:((u=e.typography)==null||(d=u.pxToRem)==null?void 0:d.call(u,35))||"2.1875rem"}[t.fontSize],color:(m=(w=(e.vars||e).palette)==null||(w=w[t.color])==null?void 0:w.main)!=null?m:{action:(b=(e.vars||e).palette)==null||(b=b.action)==null?void 0:b.active,disabled:(x=(e.vars||e).palette)==null||(x=x.action)==null?void 0:x.disabled,inherit:void 0}[t.color]}}),Io=M.forwardRef(function(t,n){const r=Po({props:t,name:"MuiSvgIcon"}),{children:o,className:s,color:i="inherit",component:l="svg",fontSize:c="medium",htmlColor:u,inheritViewBox:d=!1,titleAccess:m,viewBox:w="0 0 24 24"}=r,b=Ne(r,iw),x=M.isValidElement(o)&&o.type==="svg",f=O({},r,{color:i,component:l,fontSize:c,instanceFontSize:t.fontSize,inheritViewBox:d,viewBox:w,hasSvgAsChild:x}),h={};d||(h.viewBox=w);const S=lw(f);return a.jsxs(cw,O({as:l,className:ot(S.root,s),focusable:"false",color:u,"aria-hidden":m?void 0:!0,role:m?"img":void 0,ref:n},h,b,x&&o.props,{ownerState:f,children:[x?o.props.children:o,m?a.jsx("title",{children:m}):null]}))});process.env.NODE_ENV!=="production"&&(Io.propTypes={children:p.node,classes:p.object,className:p.string,color:p.oneOfType([p.oneOf(["inherit","action","disabled","primary","secondary","error","info","success","warning"]),p.string]),component:p.elementType,fontSize:p.oneOfType([p.oneOf(["inherit","large","medium","small"]),p.string]),htmlColor:p.string,inheritViewBox:p.bool,shapeRendering:p.string,sx:p.oneOfType([p.arrayOf(p.oneOfType([p.func,p.object,p.bool])),p.func,p.object]),titleAccess:p.string,viewBox:p.string});Io.muiName="SvgIcon";const $a=Io;function hi(e,t){function n(r,o){return a.jsx($a,O({"data-testid":`${t}Icon`,ref:o},r,{children:e}))}return process.env.NODE_ENV!=="production"&&(n.displayName=`${t}Icon`),n.muiName=$a.muiName,M.memo(M.forwardRef(n))}const dw={configure:e=>{process.env.NODE_ENV!=="production"&&console.warn(["MUI: `ClassNameGenerator` import from `@mui/material/utils` is outdated and might cause unexpected issues.","","You should use `import { unstable_ClassNameGenerator } from '@mui/material/className'` instead","","The detail of the issue: https://github.com/mui/material-ui/issues/30011#issuecomment-1024993401","","The updated documentation: https://mui.com/guides/classname-generator/"].join(` +`)),ii.configure(e)}},uw=Object.freeze(Object.defineProperty({__proto__:null,capitalize:Ye,createChainedFunction:zd,createSvgIcon:hi,debounce:Ld,deprecatedPropType:Fd,isMuiElement:Gd,ownerDocument:Kn,ownerWindow:Ud,requirePropFactory:qd,setRef:Jn,unstable_ClassNameGenerator:dw,unstable_useEnhancedEffect:Lt,unstable_useId:ri,unsupportedProp:Yd,useControlled:oi,useEventCallback:Zr,useForkRef:yt,useIsFocusVisible:ai},Symbol.toStringTag,{value:"Module"})),pw=xd(uw);var Da;function ww(){return Da||(Da=1,function(e){"use client";Object.defineProperty(e,"__esModule",{value:!0}),Object.defineProperty(e,"default",{enumerable:!0,get:function(){return t.createSvgIcon}});var t=pw}(Pr)),Pr}var fw=yd;Object.defineProperty(xo,"__esModule",{value:!0});var gi=xo.default=void 0,mw=fw(ww()),hw=a;gi=xo.default=(0,mw.default)((0,hw.jsx)("path",{d:"m10 17 5-5-5-5z"}),"ArrowRight");function gw(e){return typeof e=="string"}function un(e,t,n){return e===void 0||gw(e)?t:O({},t,{ownerState:O({},t.ownerState,n)})}const bw={disableDefaultClasses:!1},vw=M.createContext(bw);function xw(e){const{disableDefaultClasses:t}=M.useContext(vw);return n=>t?"":e(n)}function yw(e,t=[]){if(e===void 0)return{};const n={};return Object.keys(e).filter(r=>r.match(/^on[A-Z]/)&&typeof e[r]=="function"&&!t.includes(r)).forEach(r=>{n[r]=e[r]}),n}function Nw(e,t,n){return typeof e=="function"?e(t,n):e}function Aa(e){if(e===void 0)return{};const t={};return Object.keys(e).filter(n=>!(n.match(/^on[A-Z]/)&&typeof e[n]=="function")).forEach(n=>{t[n]=e[n]}),t}function kw(e){const{getSlotProps:t,additionalProps:n,externalSlotProps:r,externalForwardedProps:o,className:s}=e;if(!t){const b=ot(n==null?void 0:n.className,s,o==null?void 0:o.className,r==null?void 0:r.className),x=O({},n==null?void 0:n.style,o==null?void 0:o.style,r==null?void 0:r.style),f=O({},n,o,r);return b.length>0&&(f.className=b),Object.keys(x).length>0&&(f.style=x),{props:f,internalRef:void 0}}const i=yw(O({},o,r)),l=Aa(r),c=Aa(o),u=t(i),d=ot(u==null?void 0:u.className,n==null?void 0:n.className,s,o==null?void 0:o.className,r==null?void 0:r.className),m=O({},u==null?void 0:u.style,n==null?void 0:n.style,o==null?void 0:o.style,r==null?void 0:r.style),w=O({},u,n,c,l);return d.length>0&&(w.className=d),Object.keys(m).length>0&&(w.style=m),{props:w,internalRef:u.ref}}const Sw=["elementType","externalSlotProps","ownerState","skipResolvingSlotProps"];function Ew(e){var t;const{elementType:n,externalSlotProps:r,ownerState:o,skipResolvingSlotProps:s=!1}=e,i=Ne(e,Sw),l=s?{}:Nw(r,o),{props:c,internalRef:u}=kw(O({},i,{externalSlotProps:l})),d=yt(u,l==null?void 0:l.ref,(t=e.additionalProps)==null?void 0:t.ref);return un(n,O({},c,{ref:d}),o)}const bi="base";function jw(e){return`${bi}--${e}`}function Cw(e,t){return`${bi}-${e}-${t}`}function vi(e,t){const n=li[t];return n?jw(n):Cw(e,t)}function Tw(e,t){const n={};return t.forEach(r=>{n[r]=vi(e,r)}),n}function Rw(e){return typeof e=="function"?e():e}const Qn=M.forwardRef(function(t,n){const{children:r,container:o,disablePortal:s=!1}=t,[i,l]=M.useState(null),c=yt(M.isValidElement(r)?r.ref:null,n);if(Lt(()=>{s||l(Rw(o)||document.body)},[o,s]),Lt(()=>{if(i&&!s)return Jn(n,i),()=>{Jn(n,null)}},[n,i,s]),s){if(M.isValidElement(r)){const u={ref:c};return M.cloneElement(r,u)}return a.jsx(M.Fragment,{children:r})}return a.jsx(M.Fragment,{children:i&&Ol.createPortal(r,i)})});process.env.NODE_ENV!=="production"&&(Qn.propTypes={children:p.node,container:p.oneOfType([xn,p.func]),disablePortal:p.bool});process.env.NODE_ENV!=="production"&&(Qn["propTypes"]=Id(Qn.propTypes));var Ce="top",ze="bottom",Le="right",Te="left",Mo="auto",Mn=[Ce,ze,Le,Te],Ft="start",Nn="end",Ow="clippingParents",xi="viewport",an="popper",_w="reference",Ba=Mn.reduce(function(e,t){return e.concat([t+"-"+Ft,t+"-"+Nn])},[]),yi=[].concat(Mn,[Mo]).reduce(function(e,t){return e.concat([t,t+"-"+Ft,t+"-"+Nn])},[]),Pw="beforeRead",Iw="read",Mw="afterRead",$w="beforeMain",Dw="main",Aw="afterMain",Bw="beforeWrite",Vw="write",zw="afterWrite",Lw=[Pw,Iw,Mw,$w,Dw,Aw,Bw,Vw,zw];function We(e){return e?(e.nodeName||"").toLowerCase():null}function $e(e){if(e==null)return window;if(e.toString()!=="[object Window]"){var t=e.ownerDocument;return t&&t.defaultView||window}return e}function kt(e){var t=$e(e).Element;return e instanceof t||e instanceof Element}function Ve(e){var t=$e(e).HTMLElement;return e instanceof t||e instanceof HTMLElement}function $o(e){if(typeof ShadowRoot>"u")return!1;var t=$e(e).ShadowRoot;return e instanceof t||e instanceof ShadowRoot}function Fw(e){var t=e.state;Object.keys(t.elements).forEach(function(n){var r=t.styles[n]||{},o=t.attributes[n]||{},s=t.elements[n];!Ve(s)||!We(s)||(Object.assign(s.style,r),Object.keys(o).forEach(function(i){var l=o[i];l===!1?s.removeAttribute(i):s.setAttribute(i,l===!0?"":l)}))})}function Gw(e){var t=e.state,n={popper:{position:t.options.strategy,left:"0",top:"0",margin:"0"},arrow:{position:"absolute"},reference:{}};return Object.assign(t.elements.popper.style,n.popper),t.styles=n,t.elements.arrow&&Object.assign(t.elements.arrow.style,n.arrow),function(){Object.keys(t.elements).forEach(function(r){var o=t.elements[r],s=t.attributes[r]||{},i=Object.keys(t.styles.hasOwnProperty(r)?t.styles[r]:n[r]),l=i.reduce(function(c,u){return c[u]="",c},{});!Ve(o)||!We(o)||(Object.assign(o.style,l),Object.keys(s).forEach(function(c){o.removeAttribute(c)}))})}}const Uw={name:"applyStyles",enabled:!0,phase:"write",fn:Fw,effect:Gw,requires:["computeStyles"]};function Xe(e){return e.split("-")[0]}var ht=Math.max,er=Math.min,Gt=Math.round;function eo(){var e=navigator.userAgentData;return e!=null&&e.brands&&Array.isArray(e.brands)?e.brands.map(function(t){return t.brand+"/"+t.version}).join(" "):navigator.userAgent}function Ni(){return!/^((?!chrome|android).)*safari/i.test(eo())}function Ut(e,t,n){t===void 0&&(t=!1),n===void 0&&(n=!1);var r=e.getBoundingClientRect(),o=1,s=1;t&&Ve(e)&&(o=e.offsetWidth>0&&Gt(r.width)/e.offsetWidth||1,s=e.offsetHeight>0&&Gt(r.height)/e.offsetHeight||1);var i=kt(e)?$e(e):window,l=i.visualViewport,c=!Ni()&&n,u=(r.left+(c&&l?l.offsetLeft:0))/o,d=(r.top+(c&&l?l.offsetTop:0))/s,m=r.width/o,w=r.height/s;return{width:m,height:w,top:d,right:u+m,bottom:d+w,left:u,x:u,y:d}}function Do(e){var t=Ut(e),n=e.offsetWidth,r=e.offsetHeight;return Math.abs(t.width-n)<=1&&(n=t.width),Math.abs(t.height-r)<=1&&(r=t.height),{x:e.offsetLeft,y:e.offsetTop,width:n,height:r}}function ki(e,t){var n=t.getRootNode&&t.getRootNode();if(e.contains(t))return!0;if(n&&$o(n)){var r=t;do{if(r&&e.isSameNode(r))return!0;r=r.parentNode||r.host}while(r)}return!1}function tt(e){return $e(e).getComputedStyle(e)}function qw(e){return["table","td","th"].indexOf(We(e))>=0}function it(e){return((kt(e)?e.ownerDocument:e.document)||window.document).documentElement}function yr(e){return We(e)==="html"?e:e.assignedSlot||e.parentNode||($o(e)?e.host:null)||it(e)}function Va(e){return!Ve(e)||tt(e).position==="fixed"?null:e.offsetParent}function Hw(e){var t=/firefox/i.test(eo()),n=/Trident/i.test(eo());if(n&&Ve(e)){var r=tt(e);if(r.position==="fixed")return null}var o=yr(e);for($o(o)&&(o=o.host);Ve(o)&&["html","body"].indexOf(We(o))<0;){var s=tt(o);if(s.transform!=="none"||s.perspective!=="none"||s.contain==="paint"||["transform","perspective"].indexOf(s.willChange)!==-1||t&&s.willChange==="filter"||t&&s.filter&&s.filter!=="none")return o;o=o.parentNode}return null}function $n(e){for(var t=$e(e),n=Va(e);n&&qw(n)&&tt(n).position==="static";)n=Va(n);return n&&(We(n)==="html"||We(n)==="body"&&tt(n).position==="static")?t:n||Hw(e)||t}function Ao(e){return["top","bottom"].indexOf(e)>=0?"x":"y"}function hn(e,t,n){return ht(e,er(t,n))}function Xw(e,t,n){var r=hn(e,t,n);return r>n?n:r}function Si(){return{top:0,right:0,bottom:0,left:0}}function Ei(e){return Object.assign({},Si(),e)}function ji(e,t){return t.reduce(function(n,r){return n[r]=e,n},{})}var Yw=function(t,n){return t=typeof t=="function"?t(Object.assign({},n.rects,{placement:n.placement})):t,Ei(typeof t!="number"?t:ji(t,Mn))};function Ww(e){var t,n=e.state,r=e.name,o=e.options,s=n.elements.arrow,i=n.modifiersData.popperOffsets,l=Xe(n.placement),c=Ao(l),u=[Te,Le].indexOf(l)>=0,d=u?"height":"width";if(!(!s||!i)){var m=Yw(o.padding,n),w=Do(s),b=c==="y"?Ce:Te,x=c==="y"?ze:Le,f=n.rects.reference[d]+n.rects.reference[c]-i[c]-n.rects.popper[d],h=i[c]-n.rects.reference[c],S=$n(s),R=S?c==="y"?S.clientHeight||0:S.clientWidth||0:0,j=f/2-h/2,E=m[b],v=R-w[d]-m[x],P=R/2-w[d]/2+j,V=hn(E,P,v),U=c;n.modifiersData[r]=(t={},t[U]=V,t.centerOffset=V-P,t)}}function Kw(e){var t=e.state,n=e.options,r=n.element,o=r===void 0?"[data-popper-arrow]":r;o!=null&&(typeof o=="string"&&(o=t.elements.popper.querySelector(o),!o)||ki(t.elements.popper,o)&&(t.elements.arrow=o))}const Jw={name:"arrow",enabled:!0,phase:"main",fn:Ww,effect:Kw,requires:["popperOffsets"],requiresIfExists:["preventOverflow"]};function qt(e){return e.split("-")[1]}var Zw={top:"auto",right:"auto",bottom:"auto",left:"auto"};function Qw(e,t){var n=e.x,r=e.y,o=t.devicePixelRatio||1;return{x:Gt(n*o)/o||0,y:Gt(r*o)/o||0}}function za(e){var t,n=e.popper,r=e.popperRect,o=e.placement,s=e.variation,i=e.offsets,l=e.position,c=e.gpuAcceleration,u=e.adaptive,d=e.roundOffsets,m=e.isFixed,w=i.x,b=w===void 0?0:w,x=i.y,f=x===void 0?0:x,h=typeof d=="function"?d({x:b,y:f}):{x:b,y:f};b=h.x,f=h.y;var S=i.hasOwnProperty("x"),R=i.hasOwnProperty("y"),j=Te,E=Ce,v=window;if(u){var P=$n(n),V="clientHeight",U="clientWidth";if(P===$e(n)&&(P=it(n),tt(P).position!=="static"&&l==="absolute"&&(V="scrollHeight",U="scrollWidth")),P=P,o===Ce||(o===Te||o===Le)&&s===Nn){E=ze;var C=m&&P===v&&v.visualViewport?v.visualViewport.height:P[V];f-=C-r.height,f*=c?1:-1}if(o===Te||(o===Ce||o===ze)&&s===Nn){j=Le;var _=m&&P===v&&v.visualViewport?v.visualViewport.width:P[U];b-=_-r.width,b*=c?1:-1}}var k=Object.assign({position:l},u&&Zw),D=d===!0?Qw({x:b,y:f},$e(n)):{x:b,y:f};if(b=D.x,f=D.y,c){var $;return Object.assign({},k,($={},$[E]=R?"0":"",$[j]=S?"0":"",$.transform=(v.devicePixelRatio||1)<=1?"translate("+b+"px, "+f+"px)":"translate3d("+b+"px, "+f+"px, 0)",$))}return Object.assign({},k,(t={},t[E]=R?f+"px":"",t[j]=S?b+"px":"",t.transform="",t))}function ef(e){var t=e.state,n=e.options,r=n.gpuAcceleration,o=r===void 0?!0:r,s=n.adaptive,i=s===void 0?!0:s,l=n.roundOffsets,c=l===void 0?!0:l,u={placement:Xe(t.placement),variation:qt(t.placement),popper:t.elements.popper,popperRect:t.rects.popper,gpuAcceleration:o,isFixed:t.options.strategy==="fixed"};t.modifiersData.popperOffsets!=null&&(t.styles.popper=Object.assign({},t.styles.popper,za(Object.assign({},u,{offsets:t.modifiersData.popperOffsets,position:t.options.strategy,adaptive:i,roundOffsets:c})))),t.modifiersData.arrow!=null&&(t.styles.arrow=Object.assign({},t.styles.arrow,za(Object.assign({},u,{offsets:t.modifiersData.arrow,position:"absolute",adaptive:!1,roundOffsets:c})))),t.attributes.popper=Object.assign({},t.attributes.popper,{"data-popper-placement":t.placement})}const tf={name:"computeStyles",enabled:!0,phase:"beforeWrite",fn:ef,data:{}};var Fn={passive:!0};function nf(e){var t=e.state,n=e.instance,r=e.options,o=r.scroll,s=o===void 0?!0:o,i=r.resize,l=i===void 0?!0:i,c=$e(t.elements.popper),u=[].concat(t.scrollParents.reference,t.scrollParents.popper);return s&&u.forEach(function(d){d.addEventListener("scroll",n.update,Fn)}),l&&c.addEventListener("resize",n.update,Fn),function(){s&&u.forEach(function(d){d.removeEventListener("scroll",n.update,Fn)}),l&&c.removeEventListener("resize",n.update,Fn)}}const rf={name:"eventListeners",enabled:!0,phase:"write",fn:function(){},effect:nf,data:{}};var of={left:"right",right:"left",bottom:"top",top:"bottom"};function Xn(e){return e.replace(/left|right|bottom|top/g,function(t){return of[t]})}var af={start:"end",end:"start"};function La(e){return e.replace(/start|end/g,function(t){return af[t]})}function Bo(e){var t=$e(e),n=t.pageXOffset,r=t.pageYOffset;return{scrollLeft:n,scrollTop:r}}function Vo(e){return Ut(it(e)).left+Bo(e).scrollLeft}function sf(e,t){var n=$e(e),r=it(e),o=n.visualViewport,s=r.clientWidth,i=r.clientHeight,l=0,c=0;if(o){s=o.width,i=o.height;var u=Ni();(u||!u&&t==="fixed")&&(l=o.offsetLeft,c=o.offsetTop)}return{width:s,height:i,x:l+Vo(e),y:c}}function lf(e){var t,n=it(e),r=Bo(e),o=(t=e.ownerDocument)==null?void 0:t.body,s=ht(n.scrollWidth,n.clientWidth,o?o.scrollWidth:0,o?o.clientWidth:0),i=ht(n.scrollHeight,n.clientHeight,o?o.scrollHeight:0,o?o.clientHeight:0),l=-r.scrollLeft+Vo(e),c=-r.scrollTop;return tt(o||n).direction==="rtl"&&(l+=ht(n.clientWidth,o?o.clientWidth:0)-s),{width:s,height:i,x:l,y:c}}function zo(e){var t=tt(e),n=t.overflow,r=t.overflowX,o=t.overflowY;return/auto|scroll|overlay|hidden/.test(n+o+r)}function Ci(e){return["html","body","#document"].indexOf(We(e))>=0?e.ownerDocument.body:Ve(e)&&zo(e)?e:Ci(yr(e))}function gn(e,t){var n;t===void 0&&(t=[]);var r=Ci(e),o=r===((n=e.ownerDocument)==null?void 0:n.body),s=$e(r),i=o?[s].concat(s.visualViewport||[],zo(r)?r:[]):r,l=t.concat(i);return o?l:l.concat(gn(yr(i)))}function to(e){return Object.assign({},e,{left:e.x,top:e.y,right:e.x+e.width,bottom:e.y+e.height})}function cf(e,t){var n=Ut(e,!1,t==="fixed");return n.top=n.top+e.clientTop,n.left=n.left+e.clientLeft,n.bottom=n.top+e.clientHeight,n.right=n.left+e.clientWidth,n.width=e.clientWidth,n.height=e.clientHeight,n.x=n.left,n.y=n.top,n}function Fa(e,t,n){return t===xi?to(sf(e,n)):kt(t)?cf(t,n):to(lf(it(e)))}function df(e){var t=gn(yr(e)),n=["absolute","fixed"].indexOf(tt(e).position)>=0,r=n&&Ve(e)?$n(e):e;return kt(r)?t.filter(function(o){return kt(o)&&ki(o,r)&&We(o)!=="body"}):[]}function uf(e,t,n,r){var o=t==="clippingParents"?df(e):[].concat(t),s=[].concat(o,[n]),i=s[0],l=s.reduce(function(c,u){var d=Fa(e,u,r);return c.top=ht(d.top,c.top),c.right=er(d.right,c.right),c.bottom=er(d.bottom,c.bottom),c.left=ht(d.left,c.left),c},Fa(e,i,r));return l.width=l.right-l.left,l.height=l.bottom-l.top,l.x=l.left,l.y=l.top,l}function Ti(e){var t=e.reference,n=e.element,r=e.placement,o=r?Xe(r):null,s=r?qt(r):null,i=t.x+t.width/2-n.width/2,l=t.y+t.height/2-n.height/2,c;switch(o){case Ce:c={x:i,y:t.y-n.height};break;case ze:c={x:i,y:t.y+t.height};break;case Le:c={x:t.x+t.width,y:l};break;case Te:c={x:t.x-n.width,y:l};break;default:c={x:t.x,y:t.y}}var u=o?Ao(o):null;if(u!=null){var d=u==="y"?"height":"width";switch(s){case Ft:c[u]=c[u]-(t[d]/2-n[d]/2);break;case Nn:c[u]=c[u]+(t[d]/2-n[d]/2);break}}return c}function kn(e,t){t===void 0&&(t={});var n=t,r=n.placement,o=r===void 0?e.placement:r,s=n.strategy,i=s===void 0?e.strategy:s,l=n.boundary,c=l===void 0?Ow:l,u=n.rootBoundary,d=u===void 0?xi:u,m=n.elementContext,w=m===void 0?an:m,b=n.altBoundary,x=b===void 0?!1:b,f=n.padding,h=f===void 0?0:f,S=Ei(typeof h!="number"?h:ji(h,Mn)),R=w===an?_w:an,j=e.rects.popper,E=e.elements[x?R:w],v=uf(kt(E)?E:E.contextElement||it(e.elements.popper),c,d,i),P=Ut(e.elements.reference),V=Ti({reference:P,element:j,strategy:"absolute",placement:o}),U=to(Object.assign({},j,V)),C=w===an?U:P,_={top:v.top-C.top+S.top,bottom:C.bottom-v.bottom+S.bottom,left:v.left-C.left+S.left,right:C.right-v.right+S.right},k=e.modifiersData.offset;if(w===an&&k){var D=k[o];Object.keys(_).forEach(function($){var J=[Le,ze].indexOf($)>=0?1:-1,Y=[Ce,ze].indexOf($)>=0?"y":"x";_[$]+=D[Y]*J})}return _}function pf(e,t){t===void 0&&(t={});var n=t,r=n.placement,o=n.boundary,s=n.rootBoundary,i=n.padding,l=n.flipVariations,c=n.allowedAutoPlacements,u=c===void 0?yi:c,d=qt(r),m=d?l?Ba:Ba.filter(function(x){return qt(x)===d}):Mn,w=m.filter(function(x){return u.indexOf(x)>=0});w.length===0&&(w=m);var b=w.reduce(function(x,f){return x[f]=kn(e,{placement:f,boundary:o,rootBoundary:s,padding:i})[Xe(f)],x},{});return Object.keys(b).sort(function(x,f){return b[x]-b[f]})}function wf(e){if(Xe(e)===Mo)return[];var t=Xn(e);return[La(e),t,La(t)]}function ff(e){var t=e.state,n=e.options,r=e.name;if(!t.modifiersData[r]._skip){for(var o=n.mainAxis,s=o===void 0?!0:o,i=n.altAxis,l=i===void 0?!0:i,c=n.fallbackPlacements,u=n.padding,d=n.boundary,m=n.rootBoundary,w=n.altBoundary,b=n.flipVariations,x=b===void 0?!0:b,f=n.allowedAutoPlacements,h=t.options.placement,S=Xe(h),R=S===h,j=c||(R||!x?[Xn(h)]:wf(h)),E=[h].concat(j).reduce(function(B,X){return B.concat(Xe(X)===Mo?pf(t,{placement:X,boundary:d,rootBoundary:m,padding:u,flipVariations:x,allowedAutoPlacements:f}):X)},[]),v=t.rects.reference,P=t.rects.popper,V=new Map,U=!0,C=E[0],_=0;_=0,Y=J?"width":"height",F=kn(t,{placement:k,boundary:d,rootBoundary:m,altBoundary:w,padding:u}),te=J?$?Le:Te:$?ze:Ce;v[Y]>P[Y]&&(te=Xn(te));var se=Xn(te),oe=[];if(s&&oe.push(F[D]<=0),l&&oe.push(F[te]<=0,F[se]<=0),oe.every(function(B){return B})){C=k,U=!1;break}V.set(k,oe)}if(U)for(var y=x?3:1,T=function(X){var q=E.find(function(H){var G=V.get(H);if(G)return G.slice(0,X).every(function(K){return K})});if(q)return C=q,"break"},z=y;z>0;z--){var L=T(z);if(L==="break")break}t.placement!==C&&(t.modifiersData[r]._skip=!0,t.placement=C,t.reset=!0)}}const mf={name:"flip",enabled:!0,phase:"main",fn:ff,requiresIfExists:["offset"],data:{_skip:!1}};function Ga(e,t,n){return n===void 0&&(n={x:0,y:0}),{top:e.top-t.height-n.y,right:e.right-t.width+n.x,bottom:e.bottom-t.height+n.y,left:e.left-t.width-n.x}}function Ua(e){return[Ce,Le,ze,Te].some(function(t){return e[t]>=0})}function hf(e){var t=e.state,n=e.name,r=t.rects.reference,o=t.rects.popper,s=t.modifiersData.preventOverflow,i=kn(t,{elementContext:"reference"}),l=kn(t,{altBoundary:!0}),c=Ga(i,r),u=Ga(l,o,s),d=Ua(c),m=Ua(u);t.modifiersData[n]={referenceClippingOffsets:c,popperEscapeOffsets:u,isReferenceHidden:d,hasPopperEscaped:m},t.attributes.popper=Object.assign({},t.attributes.popper,{"data-popper-reference-hidden":d,"data-popper-escaped":m})}const gf={name:"hide",enabled:!0,phase:"main",requiresIfExists:["preventOverflow"],fn:hf};function bf(e,t,n){var r=Xe(e),o=[Te,Ce].indexOf(r)>=0?-1:1,s=typeof n=="function"?n(Object.assign({},t,{placement:e})):n,i=s[0],l=s[1];return i=i||0,l=(l||0)*o,[Te,Le].indexOf(r)>=0?{x:l,y:i}:{x:i,y:l}}function vf(e){var t=e.state,n=e.options,r=e.name,o=n.offset,s=o===void 0?[0,0]:o,i=yi.reduce(function(d,m){return d[m]=bf(m,t.rects,s),d},{}),l=i[t.placement],c=l.x,u=l.y;t.modifiersData.popperOffsets!=null&&(t.modifiersData.popperOffsets.x+=c,t.modifiersData.popperOffsets.y+=u),t.modifiersData[r]=i}const xf={name:"offset",enabled:!0,phase:"main",requires:["popperOffsets"],fn:vf};function yf(e){var t=e.state,n=e.name;t.modifiersData[n]=Ti({reference:t.rects.reference,element:t.rects.popper,strategy:"absolute",placement:t.placement})}const Nf={name:"popperOffsets",enabled:!0,phase:"read",fn:yf,data:{}};function kf(e){return e==="x"?"y":"x"}function Sf(e){var t=e.state,n=e.options,r=e.name,o=n.mainAxis,s=o===void 0?!0:o,i=n.altAxis,l=i===void 0?!1:i,c=n.boundary,u=n.rootBoundary,d=n.altBoundary,m=n.padding,w=n.tether,b=w===void 0?!0:w,x=n.tetherOffset,f=x===void 0?0:x,h=kn(t,{boundary:c,rootBoundary:u,padding:m,altBoundary:d}),S=Xe(t.placement),R=qt(t.placement),j=!R,E=Ao(S),v=kf(E),P=t.modifiersData.popperOffsets,V=t.rects.reference,U=t.rects.popper,C=typeof f=="function"?f(Object.assign({},t.rects,{placement:t.placement})):f,_=typeof C=="number"?{mainAxis:C,altAxis:C}:Object.assign({mainAxis:0,altAxis:0},C),k=t.modifiersData.offset?t.modifiersData.offset[t.placement]:null,D={x:0,y:0};if(P){if(s){var $,J=E==="y"?Ce:Te,Y=E==="y"?ze:Le,F=E==="y"?"height":"width",te=P[E],se=te+h[J],oe=te-h[Y],y=b?-U[F]/2:0,T=R===Ft?V[F]:U[F],z=R===Ft?-U[F]:-V[F],L=t.elements.arrow,B=b&&L?Do(L):{width:0,height:0},X=t.modifiersData["arrow#persistent"]?t.modifiersData["arrow#persistent"].padding:Si(),q=X[J],H=X[Y],G=hn(0,V[F],B[F]),K=j?V[F]/2-y-G-q-_.mainAxis:T-G-q-_.mainAxis,Z=j?-V[F]/2+y+G+H+_.mainAxis:z+G+H+_.mainAxis,ue=t.elements.arrow&&$n(t.elements.arrow),I=ue?E==="y"?ue.clientTop||0:ue.clientLeft||0:0,ye=($=k==null?void 0:k[E])!=null?$:0,A=te+K-ye-I,xe=te+Z-ye,Ge=hn(b?er(se,A):se,te,b?ht(oe,xe):oe);P[E]=Ge,D[E]=Ge-te}if(l){var lt,Ee=E==="x"?Ce:Te,Dn=E==="x"?ze:Le,Ue=P[v],Et=v==="y"?"height":"width",ct=Ue+h[Ee],jt=Ue-h[Dn],Ct=[Ce,Te].indexOf(S)!==-1,Tt=(lt=k==null?void 0:k[v])!=null?lt:0,dt=Ct?ct:Ue-V[Et]-U[Et]-Tt+_.altAxis,Jt=Ct?Ue+V[Et]+U[Et]-Tt-_.altAxis:jt,An=b&&Ct?Xw(dt,Ue,Jt):hn(b?dt:ct,Ue,b?Jt:jt);P[v]=An,D[v]=An-Ue}t.modifiersData[r]=D}}const Ef={name:"preventOverflow",enabled:!0,phase:"main",fn:Sf,requiresIfExists:["offset"]};function jf(e){return{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}}function Cf(e){return e===$e(e)||!Ve(e)?Bo(e):jf(e)}function Tf(e){var t=e.getBoundingClientRect(),n=Gt(t.width)/e.offsetWidth||1,r=Gt(t.height)/e.offsetHeight||1;return n!==1||r!==1}function Rf(e,t,n){n===void 0&&(n=!1);var r=Ve(t),o=Ve(t)&&Tf(t),s=it(t),i=Ut(e,o,n),l={scrollLeft:0,scrollTop:0},c={x:0,y:0};return(r||!r&&!n)&&((We(t)!=="body"||zo(s))&&(l=Cf(t)),Ve(t)?(c=Ut(t,!0),c.x+=t.clientLeft,c.y+=t.clientTop):s&&(c.x=Vo(s))),{x:i.left+l.scrollLeft-c.x,y:i.top+l.scrollTop-c.y,width:i.width,height:i.height}}function Of(e){var t=new Map,n=new Set,r=[];e.forEach(function(s){t.set(s.name,s)});function o(s){n.add(s.name);var i=[].concat(s.requires||[],s.requiresIfExists||[]);i.forEach(function(l){if(!n.has(l)){var c=t.get(l);c&&o(c)}}),r.push(s)}return e.forEach(function(s){n.has(s.name)||o(s)}),r}function _f(e){var t=Of(e);return Lw.reduce(function(n,r){return n.concat(t.filter(function(o){return o.phase===r}))},[])}function Pf(e){var t;return function(){return t||(t=new Promise(function(n){Promise.resolve().then(function(){t=void 0,n(e())})})),t}}function If(e){var t=e.reduce(function(n,r){var o=n[r.name];return n[r.name]=o?Object.assign({},o,r,{options:Object.assign({},o.options,r.options),data:Object.assign({},o.data,r.data)}):r,n},{});return Object.keys(t).map(function(n){return t[n]})}var qa={placement:"bottom",modifiers:[],strategy:"absolute"};function Ha(){for(var e=arguments.length,t=new Array(e),n=0;nko({root:["root"]},xw(Af)),Gf={},Uf=M.forwardRef(function(t,n){var r;const{anchorEl:o,children:s,direction:i,disablePortal:l,modifiers:c,open:u,placement:d,popperOptions:m,popperRef:w,slotProps:b={},slots:x={},TransitionProps:f}=t,h=Ne(t,Bf),S=M.useRef(null),R=yt(S,n),j=M.useRef(null),E=yt(j,w),v=M.useRef(E);Lt(()=>{v.current=E},[E]),M.useImperativeHandle(w,()=>j.current,[]);const P=zf(d,i),[V,U]=M.useState(P),[C,_]=M.useState(tr(o));M.useEffect(()=>{j.current&&j.current.forceUpdate()}),M.useEffect(()=>{o&&_(tr(o))},[o]),Lt(()=>{if(!C||!u)return;const Y=se=>{U(se.placement)};if(process.env.NODE_ENV!=="production"&&C&&Nr(C)&&C.nodeType===1){const se=C.getBoundingClientRect();process.env.NODE_ENV!=="test"&&se.top===0&&se.left===0&&se.right===0&&se.bottom===0&&console.warn(["MUI: The `anchorEl` prop provided to the component is invalid.","The anchor element should be part of the document layout.","Make sure the element is present in the document or that it's not display none."].join(` +`))}let F=[{name:"preventOverflow",options:{altBoundary:l}},{name:"flip",options:{altBoundary:l}},{name:"onUpdate",enabled:!0,phase:"afterWrite",fn:({state:se})=>{Y(se)}}];c!=null&&(F=F.concat(c)),m&&m.modifiers!=null&&(F=F.concat(m.modifiers));const te=Df(C,S.current,O({placement:P},m,{modifiers:F}));return v.current(te),()=>{te.destroy(),v.current(null)}},[C,l,c,u,m,P]);const k={placement:V};f!==null&&(k.TransitionProps=f);const D=Ff(),$=(r=x.root)!=null?r:"div",J=Ew({elementType:$,externalSlotProps:b.root,externalForwardedProps:h,additionalProps:{role:"tooltip",ref:R},ownerState:t,className:D.root});return a.jsx($,O({},J,{children:typeof s=="function"?s(k):s}))}),Oi=M.forwardRef(function(t,n){const{anchorEl:r,children:o,container:s,direction:i="ltr",disablePortal:l=!1,keepMounted:c=!1,modifiers:u,open:d,placement:m="bottom",popperOptions:w=Gf,popperRef:b,style:x,transition:f=!1,slotProps:h={},slots:S={}}=t,R=Ne(t,Vf),[j,E]=M.useState(!0),v=()=>{E(!1)},P=()=>{E(!0)};if(!c&&!d&&(!f||j))return null;let V;if(s)V=s;else if(r){const _=tr(r);V=_&&Nr(_)?Kn(_).body:Kn(null).body}const U=!d&&c&&(!f||j)?"none":void 0,C=f?{in:d,onEnter:v,onExited:P}:void 0;return a.jsx(Qn,{disablePortal:l,container:V,children:a.jsx(Uf,O({anchorEl:r,direction:i,disablePortal:l,modifiers:u,ref:n,open:f?!j:d,placement:m,popperOptions:w,popperRef:b,slotProps:h,slots:S},R,{style:O({position:"fixed",top:0,left:0,display:U},x),TransitionProps:C,children:o}))})});process.env.NODE_ENV!=="production"&&(Oi.propTypes={anchorEl:yo(p.oneOfType([xn,p.object,p.func]),e=>{if(e.open){const t=tr(e.anchorEl);if(t&&Nr(t)&&t.nodeType===1){const n=t.getBoundingClientRect();if(process.env.NODE_ENV!=="test"&&n.top===0&&n.left===0&&n.right===0&&n.bottom===0)return new Error(["MUI: The `anchorEl` prop provided to the component is invalid.","The anchor element should be part of the document layout.","Make sure the element is present in the document or that it's not display none."].join(` `))}else if(!t||typeof t.getBoundingClientRect!="function"||Lf(t)&&t.contextElement!=null&&t.contextElement.nodeType!==1)return new Error(["MUI: The `anchorEl` prop provided to the component is invalid.","It should be an HTML element instance or a virtualElement ","(https://popper.js.org/docs/v2/virtual-elements/)."].join(` -`))}return null}),children:p.oneOfType([p.node,p.func]),container:p.oneOfType([xn,p.func]),direction:p.oneOf(["ltr","rtl"]),disablePortal:p.bool,keepMounted:p.bool,modifiers:p.arrayOf(p.shape({data:p.object,effect:p.func,enabled:p.bool,fn:p.func,name:p.any,options:p.object,phase:p.oneOf(["afterMain","afterRead","afterWrite","beforeMain","beforeRead","beforeWrite","main","read","write"]),requires:p.arrayOf(p.string),requiresIfExists:p.arrayOf(p.string)})),open:p.bool.isRequired,placement:p.oneOf(["auto-end","auto-start","auto","bottom-end","bottom-start","bottom","left-end","left-start","left","right-end","right-start","right","top-end","top-start","top"]),popperOptions:p.shape({modifiers:p.array,onFirstUpdate:p.func,placement:p.oneOf(["auto-end","auto-start","auto","bottom-end","bottom-start","bottom","left-end","left-start","left","right-end","right-start","right","top-end","top-start","top"]),strategy:p.oneOf(["absolute","fixed"])}),popperRef:ni,slotProps:p.shape({root:p.oneOfType([p.func,p.object])}),slots:p.shape({root:p.elementType}),transition:p.bool});function _i(){const e=fi(Oo);return process.env.NODE_ENV!=="production"&&M.useDebugValue(e),e[_o]||e}function no(e,t){return no=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,o){return r.__proto__=o,r},no(e,t)}function qf(e,t){e.prototype=Object.create(t.prototype),e.prototype.constructor=e,no(e,t)}const Xa={disabled:!1};var Hf=process.env.NODE_ENV!=="production"?p.oneOfType([p.number,p.shape({enter:p.number,exit:p.number,appear:p.number}).isRequired]):null;process.env.NODE_ENV!=="production"&&p.oneOfType([p.string,p.shape({enter:p.string,exit:p.string,active:p.string}),p.shape({enter:p.string,enterDone:p.string,enterActive:p.string,exit:p.string,exitDone:p.string,exitActive:p.string})]);const Pi=g.createContext(null);var Xf=function(t){return t.scrollTop},pn="unmounted",wt="exited",ft="entering",$t="entered",ro="exiting",nt=function(e){qf(t,e);function t(r,o){var s;s=e.call(this,r,o)||this;var i=o,l=i&&!i.isMounting?r.enter:r.appear,c;return s.appearStatus=null,r.in?l?(c=wt,s.appearStatus=ft):c=$t:r.unmountOnExit||r.mountOnEnter?c=pn:c=wt,s.state={status:c},s.nextCallback=null,s}t.getDerivedStateFromProps=function(o,s){var i=o.in;return i&&s.status===pn?{status:wt}:null};var n=t.prototype;return n.componentDidMount=function(){this.updateStatus(!0,this.appearStatus)},n.componentDidUpdate=function(o){var s=null;if(o!==this.props){var i=this.state.status;this.props.in?i!==ft&&i!==$t&&(s=ft):(i===ft||i===$t)&&(s=ro)}this.updateStatus(!1,s)},n.componentWillUnmount=function(){this.cancelNextCallback()},n.getTimeouts=function(){var o=this.props.timeout,s,i,l;return s=i=l=o,o!=null&&typeof o!="number"&&(s=o.exit,i=o.enter,l=o.appear!==void 0?o.appear:i),{exit:s,enter:i,appear:l}},n.updateStatus=function(o,s){if(o===void 0&&(o=!1),s!==null)if(this.cancelNextCallback(),s===ft){if(this.props.unmountOnExit||this.props.mountOnEnter){var i=this.props.nodeRef?this.props.nodeRef.current:ln.findDOMNode(this);i&&Xf(i)}this.performEnter(o)}else this.performExit();else this.props.unmountOnExit&&this.state.status===wt&&this.setState({status:pn})},n.performEnter=function(o){var s=this,i=this.props.enter,l=this.context?this.context.isMounting:o,c=this.props.nodeRef?[l]:[ln.findDOMNode(this),l],d=c[0],u=c[1],h=this.getTimeouts(),w=l?h.appear:h.enter;if(!o&&!i||Xa.disabled){this.safeSetState({status:$t},function(){s.props.onEntered(d)});return}this.props.onEnter(d,u),this.safeSetState({status:ft},function(){s.props.onEntering(d,u),s.onTransitionEnd(w,function(){s.safeSetState({status:$t},function(){s.props.onEntered(d,u)})})})},n.performExit=function(){var o=this,s=this.props.exit,i=this.getTimeouts(),l=this.props.nodeRef?void 0:ln.findDOMNode(this);if(!s||Xa.disabled){this.safeSetState({status:wt},function(){o.props.onExited(l)});return}this.props.onExit(l),this.safeSetState({status:ro},function(){o.props.onExiting(l),o.onTransitionEnd(i.exit,function(){o.safeSetState({status:wt},function(){o.props.onExited(l)})})})},n.cancelNextCallback=function(){this.nextCallback!==null&&(this.nextCallback.cancel(),this.nextCallback=null)},n.safeSetState=function(o,s){s=this.setNextCallback(s),this.setState(o,s)},n.setNextCallback=function(o){var s=this,i=!0;return this.nextCallback=function(l){i&&(i=!1,s.nextCallback=null,o(l))},this.nextCallback.cancel=function(){i=!1},this.nextCallback},n.onTransitionEnd=function(o,s){this.setNextCallback(s);var i=this.props.nodeRef?this.props.nodeRef.current:ln.findDOMNode(this),l=o==null&&!this.props.addEndListener;if(!i||l){setTimeout(this.nextCallback,0);return}if(this.props.addEndListener){var c=this.props.nodeRef?[this.nextCallback]:[i,this.nextCallback],d=c[0],u=c[1];this.props.addEndListener(d,u)}o!=null&&setTimeout(this.nextCallback,o)},n.render=function(){var o=this.state.status;if(o===pn)return null;var s=this.props,i=s.children;s.in,s.mountOnEnter,s.unmountOnExit,s.appear,s.enter,s.exit,s.timeout,s.addEndListener,s.onEnter,s.onEntering,s.onEntered,s.onExit,s.onExiting,s.onExited,s.nodeRef;var l=Ne(s,["children","in","mountOnEnter","unmountOnExit","appear","enter","exit","timeout","addEndListener","onEnter","onEntering","onEntered","onExit","onExiting","onExited","nodeRef"]);return g.createElement(Pi.Provider,{value:null},typeof i=="function"?i(o,l):g.cloneElement(g.Children.only(i),l))},t}(g.Component);nt.contextType=Pi;nt.propTypes=process.env.NODE_ENV!=="production"?{nodeRef:p.shape({current:typeof Element>"u"?p.any:function(e,t,n,r,o,s){var i=e[t];return p.instanceOf(i&&"ownerDocument"in i?i.ownerDocument.defaultView.Element:Element)(e,t,n,r,o,s)}}),children:p.oneOfType([p.func.isRequired,p.element.isRequired]).isRequired,in:p.bool,mountOnEnter:p.bool,unmountOnExit:p.bool,appear:p.bool,enter:p.bool,exit:p.bool,timeout:function(t){var n=Hf;t.addEndListener||(n=n.isRequired);for(var r=arguments.length,o=new Array(r>1?r-1:0),s=1;se.scrollTop;function Ya(e,t){var n,r;const{timeout:o,easing:s,style:i={}}=e;return{duration:(n=i.transitionDuration)!=null?n:typeof o=="number"?o:o[t.mode]||0,easing:(r=i.transitionTimingFunction)!=null?r:typeof s=="object"?s[t.mode]:s,delay:i.transitionDelay}}const Kf=["addEndListener","appear","children","easing","in","onEnter","onEntered","onEntering","onExit","onExited","onExiting","style","timeout","TransitionComponent"];function oo(e){return`scale(${e}, ${e**2})`}const Jf={entering:{opacity:1,transform:oo(1)},entered:{opacity:1,transform:"none"}},Lr=typeof navigator<"u"&&/^((?!chrome|android).)*(safari|mobile)/i.test(navigator.userAgent)&&/(os |version\/)15(.|_)4/i.test(navigator.userAgent),Lo=M.forwardRef(function(t,n){const{addEndListener:r,appear:o=!0,children:s,easing:i,in:l,onEnter:c,onEntered:d,onEntering:u,onExit:h,onExited:w,onExiting:b,style:x,timeout:f="auto",TransitionComponent:m=Yf}=t,S=Ne(t,Kf),R=dn(),j=M.useRef(),E=_i(),v=M.useRef(null),P=yt(v,s.ref,n),V=Y=>F=>{if(Y){const te=v.current;F===void 0?Y(te):Y(te,F)}},U=V(u),C=V((Y,F)=>{Wf(Y);const{duration:te,delay:se,easing:oe}=Ya({style:x,timeout:f,easing:i},{mode:"enter"});let y;f==="auto"?(y=E.transitions.getAutoHeightDuration(Y.clientHeight),j.current=y):y=te,Y.style.transition=[E.transitions.create("opacity",{duration:y,delay:se}),E.transitions.create("transform",{duration:Lr?y:y*.666,delay:se,easing:oe})].join(","),c&&c(Y,F)}),_=V(d),k=V(b),D=V(Y=>{const{duration:F,delay:te,easing:se}=Ya({style:x,timeout:f,easing:i},{mode:"exit"});let oe;f==="auto"?(oe=E.transitions.getAutoHeightDuration(Y.clientHeight),j.current=oe):oe=F,Y.style.transition=[E.transitions.create("opacity",{duration:oe,delay:te}),E.transitions.create("transform",{duration:Lr?oe:oe*.666,delay:Lr?te:te||oe*.333,easing:se})].join(","),Y.style.opacity=0,Y.style.transform=oo(.75),h&&h(Y)}),$=V(w),J=Y=>{f==="auto"&&R.start(j.current||0,Y),r&&r(v.current,Y)};return a.jsx(m,O({appear:o,in:l,nodeRef:v,onEnter:C,onEntered:_,onEntering:U,onExit:D,onExited:$,onExiting:k,addEndListener:J,timeout:f==="auto"?null:f},S,{children:(Y,F)=>M.cloneElement(s,O({style:O({opacity:0,transform:oo(.75),visibility:Y==="exited"&&!l?"hidden":void 0},Jf[Y],x,s.props.style),ref:P},F))}))});process.env.NODE_ENV!=="production"&&(Lo.propTypes={addEndListener:p.func,appear:p.bool,children:ei.isRequired,easing:p.oneOfType([p.shape({enter:p.string,exit:p.string}),p.string]),in:p.bool,onEnter:p.func,onEntered:p.func,onEntering:p.func,onExit:p.func,onExited:p.func,onExiting:p.func,style:p.object,timeout:p.oneOfType([p.oneOf(["auto"]),p.number,p.shape({appear:p.number,enter:p.number,exit:p.number})])});Lo.muiSupportAuto=!0;const Wa=Lo,Zf=["anchorEl","component","components","componentsProps","container","disablePortal","keepMounted","modifiers","open","placement","popperOptions","popperRef","transition","slots","slotProps"],Qf=In(Oi,{name:"MuiPopper",slot:"Root",overridesResolver:(e,t)=>t.root})({}),Ii=M.forwardRef(function(t,n){var r;const o=wi(),s=Po({props:t,name:"MuiPopper"}),{anchorEl:i,component:l,components:c,componentsProps:d,container:u,disablePortal:h,keepMounted:w,modifiers:b,open:x,placement:f,popperOptions:m,popperRef:S,transition:R,slots:j,slotProps:E}=s,v=Ne(s,Zf),P=(r=j==null?void 0:j.root)!=null?r:c==null?void 0:c.Root,V=O({anchorEl:i,container:u,disablePortal:h,keepMounted:w,modifiers:b,open:x,placement:f,popperOptions:m,popperRef:S,transition:R},v);return a.jsx(Qf,O({as:l,direction:o==null?void 0:o.direction,slots:{root:P},slotProps:E??d},V,{ref:n}))});process.env.NODE_ENV!=="production"&&(Ii.propTypes={anchorEl:p.oneOfType([xn,p.object,p.func]),children:p.oneOfType([p.node,p.func]),component:p.elementType,components:p.shape({Root:p.elementType}),componentsProps:p.shape({root:p.oneOfType([p.func,p.object])}),container:p.oneOfType([xn,p.func]),disablePortal:p.bool,keepMounted:p.bool,modifiers:p.arrayOf(p.shape({data:p.object,effect:p.func,enabled:p.bool,fn:p.func,name:p.any,options:p.object,phase:p.oneOf(["afterMain","afterRead","afterWrite","beforeMain","beforeRead","beforeWrite","main","read","write"]),requires:p.arrayOf(p.string),requiresIfExists:p.arrayOf(p.string)})),open:p.bool.isRequired,placement:p.oneOf(["auto-end","auto-start","auto","bottom-end","bottom-start","bottom","left-end","left-start","left","right-end","right-start","right","top-end","top-start","top"]),popperOptions:p.shape({modifiers:p.array,onFirstUpdate:p.func,placement:p.oneOf(["auto-end","auto-start","auto","bottom-end","bottom-start","bottom","left-end","left-start","left","right-end","right-start","right","top-end","top-start","top"]),strategy:p.oneOf(["absolute","fixed"])}),popperRef:ni,slotProps:p.shape({root:p.oneOfType([p.func,p.object])}),slots:p.shape({root:p.elementType}),sx:p.oneOfType([p.arrayOf(p.oneOfType([p.func,p.object,p.bool])),p.func,p.object]),transition:p.bool});const Mi=Ii;function em(e){return ur("MuiTooltip",e)}const tm=ci("MuiTooltip",["popper","popperInteractive","popperArrow","popperClose","tooltip","tooltipArrow","touch","tooltipPlacementLeft","tooltipPlacementRight","tooltipPlacementTop","tooltipPlacementBottom","arrow"]),at=tm,nm=["arrow","children","classes","components","componentsProps","describeChild","disableFocusListener","disableHoverListener","disableInteractive","disableTouchListener","enterDelay","enterNextDelay","enterTouchDelay","followCursor","id","leaveDelay","leaveTouchDelay","onClose","onOpen","open","placement","PopperComponent","PopperProps","slotProps","slots","title","TransitionComponent","TransitionProps"];function rm(e){return Math.round(e*1e5)/1e5}const om=e=>{const{classes:t,disableInteractive:n,arrow:r,touch:o,placement:s}=e,i={popper:["popper",!n&&"popperInteractive",r&&"popperArrow"],tooltip:["tooltip",r&&"tooltipArrow",o&&"touch",`tooltipPlacement${Ye(s.split("-")[0])}`],arrow:["arrow"]};return ko(i,em,t)},am=In(Mi,{name:"MuiTooltip",slot:"Popper",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.popper,!n.disableInteractive&&t.popperInteractive,n.arrow&&t.popperArrow,!n.open&&t.popperClose]}})(({theme:e,ownerState:t,open:n})=>O({zIndex:(e.vars||e).zIndex.tooltip,pointerEvents:"none"},!t.disableInteractive&&{pointerEvents:"auto"},!n&&{pointerEvents:"none"},t.arrow&&{[`&[data-popper-placement*="bottom"] .${at.arrow}`]:{top:0,marginTop:"-0.71em","&::before":{transformOrigin:"0 100%"}},[`&[data-popper-placement*="top"] .${at.arrow}`]:{bottom:0,marginBottom:"-0.71em","&::before":{transformOrigin:"100% 0"}},[`&[data-popper-placement*="right"] .${at.arrow}`]:O({},t.isRtl?{right:0,marginRight:"-0.71em"}:{left:0,marginLeft:"-0.71em"},{height:"1em",width:"0.71em","&::before":{transformOrigin:"100% 100%"}}),[`&[data-popper-placement*="left"] .${at.arrow}`]:O({},t.isRtl?{left:0,marginLeft:"-0.71em"}:{right:0,marginRight:"-0.71em"},{height:"1em",width:"0.71em","&::before":{transformOrigin:"0 0"}})})),sm=In("div",{name:"MuiTooltip",slot:"Tooltip",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.tooltip,n.touch&&t.touch,n.arrow&&t.tooltipArrow,t[`tooltipPlacement${Ye(n.placement.split("-")[0])}`]]}})(({theme:e,ownerState:t})=>O({backgroundColor:e.vars?e.vars.palette.Tooltip.bg:mi(e.palette.grey[700],.92),borderRadius:(e.vars||e).shape.borderRadius,color:(e.vars||e).palette.common.white,fontFamily:e.typography.fontFamily,padding:"4px 8px",fontSize:e.typography.pxToRem(11),maxWidth:300,margin:2,wordWrap:"break-word",fontWeight:e.typography.fontWeightMedium},t.arrow&&{position:"relative",margin:0},t.touch&&{padding:"8px 16px",fontSize:e.typography.pxToRem(14),lineHeight:`${rm(16/14)}em`,fontWeight:e.typography.fontWeightRegular},{[`.${at.popper}[data-popper-placement*="left"] &`]:O({transformOrigin:"right center"},t.isRtl?O({marginLeft:"14px"},t.touch&&{marginLeft:"24px"}):O({marginRight:"14px"},t.touch&&{marginRight:"24px"})),[`.${at.popper}[data-popper-placement*="right"] &`]:O({transformOrigin:"left center"},t.isRtl?O({marginRight:"14px"},t.touch&&{marginRight:"24px"}):O({marginLeft:"14px"},t.touch&&{marginLeft:"24px"})),[`.${at.popper}[data-popper-placement*="top"] &`]:O({transformOrigin:"center bottom",marginBottom:"14px"},t.touch&&{marginBottom:"24px"}),[`.${at.popper}[data-popper-placement*="bottom"] &`]:O({transformOrigin:"center top",marginTop:"14px"},t.touch&&{marginTop:"24px"})})),im=In("span",{name:"MuiTooltip",slot:"Arrow",overridesResolver:(e,t)=>t.arrow})(({theme:e})=>({overflow:"hidden",position:"absolute",width:"1em",height:"0.71em",boxSizing:"border-box",color:e.vars?e.vars.palette.Tooltip.bg:mi(e.palette.grey[700],.9),"&::before":{content:'""',margin:"auto",display:"block",width:"100%",height:"100%",backgroundColor:"currentColor",transform:"rotate(45deg)"}}));let Gn=!1;const Ka=new On;let sn={x:0,y:0};function Un(e,t){return n=>{t&&t(n),e(n)}}const $i=M.forwardRef(function(t,n){var r,o,s,i,l,c,d,u,h,w,b,x,f,m,S,R,j,E,v;const P=Po({props:t,name:"MuiTooltip"}),{arrow:V=!1,children:U,components:C={},componentsProps:_={},describeChild:k=!1,disableFocusListener:D=!1,disableHoverListener:$=!1,disableInteractive:J=!1,disableTouchListener:Y=!1,enterDelay:F=100,enterNextDelay:te=0,enterTouchDelay:se=700,followCursor:oe=!1,id:y,leaveDelay:T=0,leaveTouchDelay:z=1500,onClose:L,onOpen:B,open:X,placement:q="bottom",PopperComponent:H,PopperProps:G={},slotProps:K={},slots:Z={},title:ue,TransitionComponent:I=Wa,TransitionProps:ye}=P,A=Ne(P,nm),xe=M.isValidElement(U)?U:a.jsx("span",{children:U}),Ge=_i(),lt=Ge.direction==="rtl",[Ee,Dn]=M.useState(),[Ue,Et]=M.useState(null),ct=M.useRef(!1),jt=J||oe,Ct=dn(),Tt=dn(),dt=dn(),Jt=dn(),[An,Go]=oi({controlled:X,default:!1,name:"Tooltip",state:"open"});let Ke=An;if(process.env.NODE_ENV!=="production"){const{current:ee}=M.useRef(X!==void 0);M.useEffect(()=>{Ee&&Ee.disabled&&!ee&&ue!==""&&Ee.tagName.toLowerCase()==="button"&&console.error(["MUI: You are providing a disabled `button` child to the Tooltip component.","A disabled element does not fire events.","Tooltip needs to listen to the child element's events to display the title.","","Add a simple wrapper element, such as a `span`."].join(` +`))}return null}),children:p.oneOfType([p.node,p.func]),container:p.oneOfType([xn,p.func]),direction:p.oneOf(["ltr","rtl"]),disablePortal:p.bool,keepMounted:p.bool,modifiers:p.arrayOf(p.shape({data:p.object,effect:p.func,enabled:p.bool,fn:p.func,name:p.any,options:p.object,phase:p.oneOf(["afterMain","afterRead","afterWrite","beforeMain","beforeRead","beforeWrite","main","read","write"]),requires:p.arrayOf(p.string),requiresIfExists:p.arrayOf(p.string)})),open:p.bool.isRequired,placement:p.oneOf(["auto-end","auto-start","auto","bottom-end","bottom-start","bottom","left-end","left-start","left","right-end","right-start","right","top-end","top-start","top"]),popperOptions:p.shape({modifiers:p.array,onFirstUpdate:p.func,placement:p.oneOf(["auto-end","auto-start","auto","bottom-end","bottom-start","bottom","left-end","left-start","left","right-end","right-start","right","top-end","top-start","top"]),strategy:p.oneOf(["absolute","fixed"])}),popperRef:ni,slotProps:p.shape({root:p.oneOfType([p.func,p.object])}),slots:p.shape({root:p.elementType}),transition:p.bool});function _i(){const e=fi(Oo);return process.env.NODE_ENV!=="production"&&M.useDebugValue(e),e[_o]||e}function no(e,t){return no=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,o){return r.__proto__=o,r},no(e,t)}function qf(e,t){e.prototype=Object.create(t.prototype),e.prototype.constructor=e,no(e,t)}const Xa={disabled:!1};var Hf=process.env.NODE_ENV!=="production"?p.oneOfType([p.number,p.shape({enter:p.number,exit:p.number,appear:p.number}).isRequired]):null;process.env.NODE_ENV!=="production"&&p.oneOfType([p.string,p.shape({enter:p.string,exit:p.string,active:p.string}),p.shape({enter:p.string,enterDone:p.string,enterActive:p.string,exit:p.string,exitDone:p.string,exitActive:p.string})]);const Pi=g.createContext(null);var Xf=function(t){return t.scrollTop},pn="unmounted",wt="exited",ft="entering",$t="entered",ro="exiting",nt=function(e){qf(t,e);function t(r,o){var s;s=e.call(this,r,o)||this;var i=o,l=i&&!i.isMounting?r.enter:r.appear,c;return s.appearStatus=null,r.in?l?(c=wt,s.appearStatus=ft):c=$t:r.unmountOnExit||r.mountOnEnter?c=pn:c=wt,s.state={status:c},s.nextCallback=null,s}t.getDerivedStateFromProps=function(o,s){var i=o.in;return i&&s.status===pn?{status:wt}:null};var n=t.prototype;return n.componentDidMount=function(){this.updateStatus(!0,this.appearStatus)},n.componentDidUpdate=function(o){var s=null;if(o!==this.props){var i=this.state.status;this.props.in?i!==ft&&i!==$t&&(s=ft):(i===ft||i===$t)&&(s=ro)}this.updateStatus(!1,s)},n.componentWillUnmount=function(){this.cancelNextCallback()},n.getTimeouts=function(){var o=this.props.timeout,s,i,l;return s=i=l=o,o!=null&&typeof o!="number"&&(s=o.exit,i=o.enter,l=o.appear!==void 0?o.appear:i),{exit:s,enter:i,appear:l}},n.updateStatus=function(o,s){if(o===void 0&&(o=!1),s!==null)if(this.cancelNextCallback(),s===ft){if(this.props.unmountOnExit||this.props.mountOnEnter){var i=this.props.nodeRef?this.props.nodeRef.current:ln.findDOMNode(this);i&&Xf(i)}this.performEnter(o)}else this.performExit();else this.props.unmountOnExit&&this.state.status===wt&&this.setState({status:pn})},n.performEnter=function(o){var s=this,i=this.props.enter,l=this.context?this.context.isMounting:o,c=this.props.nodeRef?[l]:[ln.findDOMNode(this),l],u=c[0],d=c[1],m=this.getTimeouts(),w=l?m.appear:m.enter;if(!o&&!i||Xa.disabled){this.safeSetState({status:$t},function(){s.props.onEntered(u)});return}this.props.onEnter(u,d),this.safeSetState({status:ft},function(){s.props.onEntering(u,d),s.onTransitionEnd(w,function(){s.safeSetState({status:$t},function(){s.props.onEntered(u,d)})})})},n.performExit=function(){var o=this,s=this.props.exit,i=this.getTimeouts(),l=this.props.nodeRef?void 0:ln.findDOMNode(this);if(!s||Xa.disabled){this.safeSetState({status:wt},function(){o.props.onExited(l)});return}this.props.onExit(l),this.safeSetState({status:ro},function(){o.props.onExiting(l),o.onTransitionEnd(i.exit,function(){o.safeSetState({status:wt},function(){o.props.onExited(l)})})})},n.cancelNextCallback=function(){this.nextCallback!==null&&(this.nextCallback.cancel(),this.nextCallback=null)},n.safeSetState=function(o,s){s=this.setNextCallback(s),this.setState(o,s)},n.setNextCallback=function(o){var s=this,i=!0;return this.nextCallback=function(l){i&&(i=!1,s.nextCallback=null,o(l))},this.nextCallback.cancel=function(){i=!1},this.nextCallback},n.onTransitionEnd=function(o,s){this.setNextCallback(s);var i=this.props.nodeRef?this.props.nodeRef.current:ln.findDOMNode(this),l=o==null&&!this.props.addEndListener;if(!i||l){setTimeout(this.nextCallback,0);return}if(this.props.addEndListener){var c=this.props.nodeRef?[this.nextCallback]:[i,this.nextCallback],u=c[0],d=c[1];this.props.addEndListener(u,d)}o!=null&&setTimeout(this.nextCallback,o)},n.render=function(){var o=this.state.status;if(o===pn)return null;var s=this.props,i=s.children;s.in,s.mountOnEnter,s.unmountOnExit,s.appear,s.enter,s.exit,s.timeout,s.addEndListener,s.onEnter,s.onEntering,s.onEntered,s.onExit,s.onExiting,s.onExited,s.nodeRef;var l=Ne(s,["children","in","mountOnEnter","unmountOnExit","appear","enter","exit","timeout","addEndListener","onEnter","onEntering","onEntered","onExit","onExiting","onExited","nodeRef"]);return g.createElement(Pi.Provider,{value:null},typeof i=="function"?i(o,l):g.cloneElement(g.Children.only(i),l))},t}(g.Component);nt.contextType=Pi;nt.propTypes=process.env.NODE_ENV!=="production"?{nodeRef:p.shape({current:typeof Element>"u"?p.any:function(e,t,n,r,o,s){var i=e[t];return p.instanceOf(i&&"ownerDocument"in i?i.ownerDocument.defaultView.Element:Element)(e,t,n,r,o,s)}}),children:p.oneOfType([p.func.isRequired,p.element.isRequired]).isRequired,in:p.bool,mountOnEnter:p.bool,unmountOnExit:p.bool,appear:p.bool,enter:p.bool,exit:p.bool,timeout:function(t){var n=Hf;t.addEndListener||(n=n.isRequired);for(var r=arguments.length,o=new Array(r>1?r-1:0),s=1;se.scrollTop;function Ya(e,t){var n,r;const{timeout:o,easing:s,style:i={}}=e;return{duration:(n=i.transitionDuration)!=null?n:typeof o=="number"?o:o[t.mode]||0,easing:(r=i.transitionTimingFunction)!=null?r:typeof s=="object"?s[t.mode]:s,delay:i.transitionDelay}}const Kf=["addEndListener","appear","children","easing","in","onEnter","onEntered","onEntering","onExit","onExited","onExiting","style","timeout","TransitionComponent"];function oo(e){return`scale(${e}, ${e**2})`}const Jf={entering:{opacity:1,transform:oo(1)},entered:{opacity:1,transform:"none"}},Lr=typeof navigator<"u"&&/^((?!chrome|android).)*(safari|mobile)/i.test(navigator.userAgent)&&/(os |version\/)15(.|_)4/i.test(navigator.userAgent),Lo=M.forwardRef(function(t,n){const{addEndListener:r,appear:o=!0,children:s,easing:i,in:l,onEnter:c,onEntered:u,onEntering:d,onExit:m,onExited:w,onExiting:b,style:x,timeout:f="auto",TransitionComponent:h=Yf}=t,S=Ne(t,Kf),R=dn(),j=M.useRef(),E=_i(),v=M.useRef(null),P=yt(v,s.ref,n),V=Y=>F=>{if(Y){const te=v.current;F===void 0?Y(te):Y(te,F)}},U=V(d),C=V((Y,F)=>{Wf(Y);const{duration:te,delay:se,easing:oe}=Ya({style:x,timeout:f,easing:i},{mode:"enter"});let y;f==="auto"?(y=E.transitions.getAutoHeightDuration(Y.clientHeight),j.current=y):y=te,Y.style.transition=[E.transitions.create("opacity",{duration:y,delay:se}),E.transitions.create("transform",{duration:Lr?y:y*.666,delay:se,easing:oe})].join(","),c&&c(Y,F)}),_=V(u),k=V(b),D=V(Y=>{const{duration:F,delay:te,easing:se}=Ya({style:x,timeout:f,easing:i},{mode:"exit"});let oe;f==="auto"?(oe=E.transitions.getAutoHeightDuration(Y.clientHeight),j.current=oe):oe=F,Y.style.transition=[E.transitions.create("opacity",{duration:oe,delay:te}),E.transitions.create("transform",{duration:Lr?oe:oe*.666,delay:Lr?te:te||oe*.333,easing:se})].join(","),Y.style.opacity=0,Y.style.transform=oo(.75),m&&m(Y)}),$=V(w),J=Y=>{f==="auto"&&R.start(j.current||0,Y),r&&r(v.current,Y)};return a.jsx(h,O({appear:o,in:l,nodeRef:v,onEnter:C,onEntered:_,onEntering:U,onExit:D,onExited:$,onExiting:k,addEndListener:J,timeout:f==="auto"?null:f},S,{children:(Y,F)=>M.cloneElement(s,O({style:O({opacity:0,transform:oo(.75),visibility:Y==="exited"&&!l?"hidden":void 0},Jf[Y],x,s.props.style),ref:P},F))}))});process.env.NODE_ENV!=="production"&&(Lo.propTypes={addEndListener:p.func,appear:p.bool,children:ei.isRequired,easing:p.oneOfType([p.shape({enter:p.string,exit:p.string}),p.string]),in:p.bool,onEnter:p.func,onEntered:p.func,onEntering:p.func,onExit:p.func,onExited:p.func,onExiting:p.func,style:p.object,timeout:p.oneOfType([p.oneOf(["auto"]),p.number,p.shape({appear:p.number,enter:p.number,exit:p.number})])});Lo.muiSupportAuto=!0;const Wa=Lo,Zf=["anchorEl","component","components","componentsProps","container","disablePortal","keepMounted","modifiers","open","placement","popperOptions","popperRef","transition","slots","slotProps"],Qf=In(Oi,{name:"MuiPopper",slot:"Root",overridesResolver:(e,t)=>t.root})({}),Ii=M.forwardRef(function(t,n){var r;const o=wi(),s=Po({props:t,name:"MuiPopper"}),{anchorEl:i,component:l,components:c,componentsProps:u,container:d,disablePortal:m,keepMounted:w,modifiers:b,open:x,placement:f,popperOptions:h,popperRef:S,transition:R,slots:j,slotProps:E}=s,v=Ne(s,Zf),P=(r=j==null?void 0:j.root)!=null?r:c==null?void 0:c.Root,V=O({anchorEl:i,container:d,disablePortal:m,keepMounted:w,modifiers:b,open:x,placement:f,popperOptions:h,popperRef:S,transition:R},v);return a.jsx(Qf,O({as:l,direction:o==null?void 0:o.direction,slots:{root:P},slotProps:E??u},V,{ref:n}))});process.env.NODE_ENV!=="production"&&(Ii.propTypes={anchorEl:p.oneOfType([xn,p.object,p.func]),children:p.oneOfType([p.node,p.func]),component:p.elementType,components:p.shape({Root:p.elementType}),componentsProps:p.shape({root:p.oneOfType([p.func,p.object])}),container:p.oneOfType([xn,p.func]),disablePortal:p.bool,keepMounted:p.bool,modifiers:p.arrayOf(p.shape({data:p.object,effect:p.func,enabled:p.bool,fn:p.func,name:p.any,options:p.object,phase:p.oneOf(["afterMain","afterRead","afterWrite","beforeMain","beforeRead","beforeWrite","main","read","write"]),requires:p.arrayOf(p.string),requiresIfExists:p.arrayOf(p.string)})),open:p.bool.isRequired,placement:p.oneOf(["auto-end","auto-start","auto","bottom-end","bottom-start","bottom","left-end","left-start","left","right-end","right-start","right","top-end","top-start","top"]),popperOptions:p.shape({modifiers:p.array,onFirstUpdate:p.func,placement:p.oneOf(["auto-end","auto-start","auto","bottom-end","bottom-start","bottom","left-end","left-start","left","right-end","right-start","right","top-end","top-start","top"]),strategy:p.oneOf(["absolute","fixed"])}),popperRef:ni,slotProps:p.shape({root:p.oneOfType([p.func,p.object])}),slots:p.shape({root:p.elementType}),sx:p.oneOfType([p.arrayOf(p.oneOfType([p.func,p.object,p.bool])),p.func,p.object]),transition:p.bool});const Mi=Ii;function em(e){return ur("MuiTooltip",e)}const tm=ci("MuiTooltip",["popper","popperInteractive","popperArrow","popperClose","tooltip","tooltipArrow","touch","tooltipPlacementLeft","tooltipPlacementRight","tooltipPlacementTop","tooltipPlacementBottom","arrow"]),at=tm,nm=["arrow","children","classes","components","componentsProps","describeChild","disableFocusListener","disableHoverListener","disableInteractive","disableTouchListener","enterDelay","enterNextDelay","enterTouchDelay","followCursor","id","leaveDelay","leaveTouchDelay","onClose","onOpen","open","placement","PopperComponent","PopperProps","slotProps","slots","title","TransitionComponent","TransitionProps"];function rm(e){return Math.round(e*1e5)/1e5}const om=e=>{const{classes:t,disableInteractive:n,arrow:r,touch:o,placement:s}=e,i={popper:["popper",!n&&"popperInteractive",r&&"popperArrow"],tooltip:["tooltip",r&&"tooltipArrow",o&&"touch",`tooltipPlacement${Ye(s.split("-")[0])}`],arrow:["arrow"]};return ko(i,em,t)},am=In(Mi,{name:"MuiTooltip",slot:"Popper",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.popper,!n.disableInteractive&&t.popperInteractive,n.arrow&&t.popperArrow,!n.open&&t.popperClose]}})(({theme:e,ownerState:t,open:n})=>O({zIndex:(e.vars||e).zIndex.tooltip,pointerEvents:"none"},!t.disableInteractive&&{pointerEvents:"auto"},!n&&{pointerEvents:"none"},t.arrow&&{[`&[data-popper-placement*="bottom"] .${at.arrow}`]:{top:0,marginTop:"-0.71em","&::before":{transformOrigin:"0 100%"}},[`&[data-popper-placement*="top"] .${at.arrow}`]:{bottom:0,marginBottom:"-0.71em","&::before":{transformOrigin:"100% 0"}},[`&[data-popper-placement*="right"] .${at.arrow}`]:O({},t.isRtl?{right:0,marginRight:"-0.71em"}:{left:0,marginLeft:"-0.71em"},{height:"1em",width:"0.71em","&::before":{transformOrigin:"100% 100%"}}),[`&[data-popper-placement*="left"] .${at.arrow}`]:O({},t.isRtl?{left:0,marginLeft:"-0.71em"}:{right:0,marginRight:"-0.71em"},{height:"1em",width:"0.71em","&::before":{transformOrigin:"0 0"}})})),sm=In("div",{name:"MuiTooltip",slot:"Tooltip",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.tooltip,n.touch&&t.touch,n.arrow&&t.tooltipArrow,t[`tooltipPlacement${Ye(n.placement.split("-")[0])}`]]}})(({theme:e,ownerState:t})=>O({backgroundColor:e.vars?e.vars.palette.Tooltip.bg:mi(e.palette.grey[700],.92),borderRadius:(e.vars||e).shape.borderRadius,color:(e.vars||e).palette.common.white,fontFamily:e.typography.fontFamily,padding:"4px 8px",fontSize:e.typography.pxToRem(11),maxWidth:300,margin:2,wordWrap:"break-word",fontWeight:e.typography.fontWeightMedium},t.arrow&&{position:"relative",margin:0},t.touch&&{padding:"8px 16px",fontSize:e.typography.pxToRem(14),lineHeight:`${rm(16/14)}em`,fontWeight:e.typography.fontWeightRegular},{[`.${at.popper}[data-popper-placement*="left"] &`]:O({transformOrigin:"right center"},t.isRtl?O({marginLeft:"14px"},t.touch&&{marginLeft:"24px"}):O({marginRight:"14px"},t.touch&&{marginRight:"24px"})),[`.${at.popper}[data-popper-placement*="right"] &`]:O({transformOrigin:"left center"},t.isRtl?O({marginRight:"14px"},t.touch&&{marginRight:"24px"}):O({marginLeft:"14px"},t.touch&&{marginLeft:"24px"})),[`.${at.popper}[data-popper-placement*="top"] &`]:O({transformOrigin:"center bottom",marginBottom:"14px"},t.touch&&{marginBottom:"24px"}),[`.${at.popper}[data-popper-placement*="bottom"] &`]:O({transformOrigin:"center top",marginTop:"14px"},t.touch&&{marginTop:"24px"})})),im=In("span",{name:"MuiTooltip",slot:"Arrow",overridesResolver:(e,t)=>t.arrow})(({theme:e})=>({overflow:"hidden",position:"absolute",width:"1em",height:"0.71em",boxSizing:"border-box",color:e.vars?e.vars.palette.Tooltip.bg:mi(e.palette.grey[700],.9),"&::before":{content:'""',margin:"auto",display:"block",width:"100%",height:"100%",backgroundColor:"currentColor",transform:"rotate(45deg)"}}));let Gn=!1;const Ka=new On;let sn={x:0,y:0};function Un(e,t){return n=>{t&&t(n),e(n)}}const $i=M.forwardRef(function(t,n){var r,o,s,i,l,c,u,d,m,w,b,x,f,h,S,R,j,E,v;const P=Po({props:t,name:"MuiTooltip"}),{arrow:V=!1,children:U,components:C={},componentsProps:_={},describeChild:k=!1,disableFocusListener:D=!1,disableHoverListener:$=!1,disableInteractive:J=!1,disableTouchListener:Y=!1,enterDelay:F=100,enterNextDelay:te=0,enterTouchDelay:se=700,followCursor:oe=!1,id:y,leaveDelay:T=0,leaveTouchDelay:z=1500,onClose:L,onOpen:B,open:X,placement:q="bottom",PopperComponent:H,PopperProps:G={},slotProps:K={},slots:Z={},title:ue,TransitionComponent:I=Wa,TransitionProps:ye}=P,A=Ne(P,nm),xe=M.isValidElement(U)?U:a.jsx("span",{children:U}),Ge=_i(),lt=Ge.direction==="rtl",[Ee,Dn]=M.useState(),[Ue,Et]=M.useState(null),ct=M.useRef(!1),jt=J||oe,Ct=dn(),Tt=dn(),dt=dn(),Jt=dn(),[An,Go]=oi({controlled:X,default:!1,name:"Tooltip",state:"open"});let Ke=An;if(process.env.NODE_ENV!=="production"){const{current:ee}=M.useRef(X!==void 0);M.useEffect(()=>{Ee&&Ee.disabled&&!ee&&ue!==""&&Ee.tagName.toLowerCase()==="button"&&console.error(["MUI: You are providing a disabled `button` child to the Tooltip component.","A disabled element does not fire events.","Tooltip needs to listen to the child element's events to display the title.","","Add a simple wrapper element, such as a `span`."].join(` `))},[ue,Ee,ee])}const kr=ri(y),Zt=M.useRef(),Bn=Zr(()=>{Zt.current!==void 0&&(document.body.style.WebkitUserSelect=Zt.current,Zt.current=void 0),Jt.clear()});M.useEffect(()=>Bn,[Bn]);const Uo=ee=>{Ka.clear(),Gn=!0,Go(!0),B&&!Ke&&B(ee)},Vn=Zr(ee=>{Ka.start(800+T,()=>{Gn=!1}),Go(!1),L&&Ke&&L(ee),Ct.start(Ge.transitions.duration.shortest,()=>{ct.current=!1})}),Sr=ee=>{ct.current&&ee.type!=="touchstart"||(Ee&&Ee.removeAttribute("title"),Tt.clear(),dt.clear(),F||Gn&&te?Tt.start(Gn?te:F,()=>{Uo(ee)}):Uo(ee))},qo=ee=>{Tt.clear(),dt.start(T,()=>{Vn(ee)})},{isFocusVisibleRef:Ho,onBlur:rl,onFocus:ol,ref:al}=ai(),[,Xo]=M.useState(!1),Yo=ee=>{rl(ee),Ho.current===!1&&(Xo(!1),qo(ee))},Wo=ee=>{Ee||Dn(ee.currentTarget),ol(ee),Ho.current===!0&&(Xo(!0),Sr(ee))},Ko=ee=>{ct.current=!0;const _e=xe.props;_e.onTouchStart&&_e.onTouchStart(ee)},Jo=Sr,Zo=qo,sl=ee=>{Ko(ee),dt.clear(),Ct.clear(),Bn(),Zt.current=document.body.style.WebkitUserSelect,document.body.style.WebkitUserSelect="none",Jt.start(se,()=>{document.body.style.WebkitUserSelect=Zt.current,Sr(ee)})},il=ee=>{xe.props.onTouchEnd&&xe.props.onTouchEnd(ee),Bn(),dt.start(z,()=>{Vn(ee)})};M.useEffect(()=>{if(!Ke)return;function ee(_e){(_e.key==="Escape"||_e.key==="Esc")&&Vn(_e)}return document.addEventListener("keydown",ee),()=>{document.removeEventListener("keydown",ee)}},[Vn,Ke]);const ll=yt(xe.ref,al,Dn,n);!ue&&ue!==0&&(Ke=!1);const Er=M.useRef(),cl=ee=>{const _e=xe.props;_e.onMouseMove&&_e.onMouseMove(ee),sn={x:ee.clientX,y:ee.clientY},Er.current&&Er.current.update()},Qt={},jr=typeof ue=="string";k?(Qt.title=!Ke&&jr&&!$?ue:null,Qt["aria-describedby"]=Ke?kr:null):(Qt["aria-label"]=jr?ue:null,Qt["aria-labelledby"]=Ke&&!jr?kr:null);const De=O({},Qt,A,xe.props,{className:ot(A.className,xe.props.className),onTouchStart:Ko,ref:ll},oe?{onMouseMove:cl}:{});process.env.NODE_ENV!=="production"&&(De["data-mui-internal-clone-element"]=!0,M.useEffect(()=>{Ee&&!Ee.getAttribute("data-mui-internal-clone-element")&&console.error(["MUI: The `children` component of the Tooltip is not forwarding its props correctly.","Please make sure that props are spread on the same element that the ref is applied to."].join(` `))},[Ee]));const en={};Y||(De.onTouchStart=sl,De.onTouchEnd=il),$||(De.onMouseOver=Un(Jo,De.onMouseOver),De.onMouseLeave=Un(Zo,De.onMouseLeave),jt||(en.onMouseOver=Jo,en.onMouseLeave=Zo)),D||(De.onFocus=Un(Wo,De.onFocus),De.onBlur=Un(Yo,De.onBlur),jt||(en.onFocus=Wo,en.onBlur=Yo)),process.env.NODE_ENV!=="production"&&xe.props.title&&console.error(["MUI: You have provided a `title` prop to the child of .",`Remove this title prop \`${xe.props.title}\` or the Tooltip component.`].join(` -`));const dl=M.useMemo(()=>{var ee;let _e=[{name:"arrow",enabled:!!Ue,options:{element:Ue,padding:4}}];return(ee=G.popperOptions)!=null&&ee.modifiers&&(_e=_e.concat(G.popperOptions.modifiers)),O({},G.popperOptions,{modifiers:_e})},[Ue,G]),tn=O({},P,{isRtl:lt,arrow:V,disableInteractive:jt,placement:q,PopperComponentProp:H,touch:ct.current}),Cr=om(tn),Qo=(r=(o=Z.popper)!=null?o:C.Popper)!=null?r:am,ea=(s=(i=(l=Z.transition)!=null?l:C.Transition)!=null?i:I)!=null?s:Wa,ta=(c=(d=Z.tooltip)!=null?d:C.Tooltip)!=null?c:sm,na=(u=(h=Z.arrow)!=null?h:C.Arrow)!=null?u:im,ul=un(Qo,O({},G,(w=K.popper)!=null?w:_.popper,{className:ot(Cr.popper,G==null?void 0:G.className,(b=(x=K.popper)!=null?x:_.popper)==null?void 0:b.className)}),tn),pl=un(ea,O({},ye,(f=K.transition)!=null?f:_.transition),tn),wl=un(ta,O({},(m=K.tooltip)!=null?m:_.tooltip,{className:ot(Cr.tooltip,(S=(R=K.tooltip)!=null?R:_.tooltip)==null?void 0:S.className)}),tn),fl=un(na,O({},(j=K.arrow)!=null?j:_.arrow,{className:ot(Cr.arrow,(E=(v=K.arrow)!=null?v:_.arrow)==null?void 0:E.className)}),tn);return a.jsxs(M.Fragment,{children:[M.cloneElement(xe,De),a.jsx(Qo,O({as:H??Mi,placement:q,anchorEl:oe?{getBoundingClientRect:()=>({top:sn.y,left:sn.x,right:sn.x,bottom:sn.y,width:0,height:0})}:Ee,popperRef:Er,open:Ee?Ke:!1,id:kr,transition:!0},en,ul,{popperOptions:dl,children:({TransitionProps:ee})=>a.jsx(ea,O({timeout:Ge.transitions.duration.shorter},ee,pl,{children:a.jsxs(ta,O({},wl,{children:[ue,V?a.jsx(na,O({},fl,{ref:Et})):null]}))}))}))]})});process.env.NODE_ENV!=="production"&&($i.propTypes={arrow:p.bool,children:ei.isRequired,classes:p.object,className:p.string,components:p.shape({Arrow:p.elementType,Popper:p.elementType,Tooltip:p.elementType,Transition:p.elementType}),componentsProps:p.shape({arrow:p.object,popper:p.object,tooltip:p.object,transition:p.object}),describeChild:p.bool,disableFocusListener:p.bool,disableHoverListener:p.bool,disableInteractive:p.bool,disableTouchListener:p.bool,enterDelay:p.number,enterNextDelay:p.number,enterTouchDelay:p.number,followCursor:p.bool,id:p.string,leaveDelay:p.number,leaveTouchDelay:p.number,onClose:p.func,onOpen:p.func,open:p.bool,placement:p.oneOf(["bottom-end","bottom-start","bottom","left-end","left-start","left","right-end","right-start","right","top-end","top-start","top"]),PopperComponent:p.elementType,PopperProps:p.object,slotProps:p.shape({arrow:p.object,popper:p.object,tooltip:p.object,transition:p.object}),slots:p.shape({arrow:p.elementType,popper:p.elementType,tooltip:p.elementType,transition:p.elementType}),sx:p.oneOfType([p.arrayOf(p.oneOfType([p.func,p.object,p.bool])),p.func,p.object]),title:p.node,TransitionComponent:p.elementType,TransitionProps:p.object});const lm=$i;function Ja(e,t,n){return e?a.jsx(Me.ListItemIcon,{className:`papi-menu-icon-${n?"leading":"trailing"}`,children:a.jsx("img",{src:e,alt:`${n?"Leading":"Trailing"} icon for ${t}`})}):void 0}function Fo(e){const{onClick:t,label:n,tooltip:r,allowForLeadingIcons:o=!0,iconPathBefore:s=void 0,iconPathAfter:i=void 0,hasAutoFocus:l=!1,className:c,isDisabled:d=!1,isDense:u=!0,isSubMenuParent:h=!1,hasDisabledGutters:w=!1,hasDivider:b=!1,focusVisibleClassName:x,id:f,children:m}=e,S=a.jsx(Me.MenuItem,{sx:{lineHeight:.8},autoFocus:l,className:c,disabled:d,dense:u,disableGutters:w,divider:b,focusVisibleClassName:x,onClick:t,id:f,children:n?a.jsxs(a.Fragment,{children:[Ja(s,n,!0),a.jsx(Me.ListItemText,{primary:n,inset:!s&&o}),h?a.jsx(Me.ListItemIcon,{className:"papi-menu-icon-trailing",children:a.jsx(gi,{})}):Ja(i,n,!1)]}):m});return r?a.jsx(lm,{title:r,placement:"right",children:a.jsx("div",{children:S})}):S}function Di(e){return Object.entries(e.groups).map(([n,r])=>({id:n,group:r}))}function cm(e){const[t,n]=g.useState(void 0),{parentMenuItem:r,parentItemProps:o,menuDefinition:s}=e,i=d=>{n(d.currentTarget)},l=()=>{n(void 0)},c=()=>{let d=Di(s).filter(u=>"menuItem"in u.group);if(!(r!=null&&r.id))throw new Error("A valid parent menu item is required for submenus.");return d=d.filter(u=>"menuItem"in u.group&&u.group.menuItem===r.id),a.jsx(Ai,{...e,includedGroups:d})};return a.jsxs(a.Fragment,{children:[a.jsx(Fo,{onClick:i,...o,isSubMenuParent:!0}),a.jsx(Me.Menu,{anchorEl:t,open:!!t,onClose:l,anchorOrigin:{vertical:"top",horizontal:"right"},transformOrigin:{vertical:"top",horizontal:"left"},children:c()},r.id)]})}const dm=(e,t)=>t.filter(o=>o.group===e).sort((o,s)=>(o.order||0)-(s.order||0));function Ai(e){const{menuDefinition:t,onClick:n,commandHandler:r,includedGroups:o}=e,{items:s,allowForLeadingIcons:i}=g.useMemo(()=>{const u=o&&o.length>0?o:Di(t).filter(x=>!("menuItem"in x.group)),h=Object.values(u).sort((x,f)=>(x.group.order||0)-(f.group.order||0)),w=[];h.forEach(x=>{dm(x.id,t.items).forEach(f=>w.push({item:f,isLastItemInGroup:!1})),w.length>0&&(w[w.length-1].isLastItemInGroup=!0)}),w.length>0&&(w[w.length-1].isLastItemInGroup=!1);const b=w.some(x=>"iconPathBefore"in x.item&&x.item.iconPathBefore);return{items:w,allowForLeadingIcons:b}},[o,t]),l=({item:u,isLastItemInGroup:h})=>({className:"papi-menu-item",label:u.label,tooltip:u.tooltip,iconPathBefore:"iconPathBefore"in u?u.iconPathBefore:void 0,iconPathAfter:"iconPathAfter"in u?u.iconPathAfter:void 0,hasDivider:h,allowForLeadingIcons:i}),[c]=s;if(!c)return a.jsx("div",{});const d=c.item.group;return a.jsx("div",{role:"menu","aria-label":d,children:s.map((u,h)=>{const{item:w}=u,b=l(u);if("command"in w){const x=w.group+h;return a.jsx(Fo,{onClick:f=>{n==null||n(f),r(w)},...b},x)}return a.jsx(cm,{parentMenuItem:w,parentItemProps:b,...e},d+w.id)})},d)}function um(e){const{menuDefinition:t,columnId:n}=e;let s=Object.entries(t.groups).map(([i,l])=>({id:i,group:l})).filter(i=>"column"in i.group);return n&&"columns"in t&&t.columns[n]&&(s=s.filter(i=>"column"in i.group&&i.group.column===n)),a.jsx(Ai,{...e,includedGroups:s})}function pm({commandHandler:e,menuDefinition:t,id:n,metadata:r,onClick:o,className:s}){return a.jsxs(Me.Grid,{id:n,item:!0,xs:"auto",role:"menu","aria-label":n,className:`papi-menu-column ${s??""}`,children:[a.jsx("h3",{"aria-label":r.label,className:`papi-menu-column-header ${s??""}`,children:r.label}),a.jsx(Me.List,{id:n,dense:!0,className:s??"",children:a.jsx(um,{commandHandler:e,menuDefinition:t,columnId:n,onClick:o})})]})}function Bi({commandHandler:e,className:t,multiColumnMenu:n,id:r}){const{columns:o}=n,s=g.useMemo(()=>{const i=new Map;return Object.getOwnPropertyNames(o).forEach(l=>{if(l==="isExtensible")return;const c=l,d=o[c];typeof d=="object"&&typeof d.order=="number"&&!Number.isNaN(d.order)?i.set(d.order,{id:c,metadata:d}):console.warn(`Property ${l} (${typeof d}) on menu ${r} is not a valid column and is being ignored. This might indicate data corruption`)}),Array.from(i.values()).sort((l,c)=>(l.metadata.order||0)-(c.metadata.order||0))},[o,r]);return a.jsx(Me.Grid,{container:!0,spacing:0,className:`papi-multi-column-menu ${t??""}`,columns:s.length,role:"menu","aria-label":"GridMenu",id:r,children:s.map((i,l)=>a.jsx(pm,{commandHandler:e,menuDefinition:n,...i,className:t},l))})}function wm(e){return{preserveValue:!0,...e}}const nr=(e,t,n={})=>{const r=g.useRef(t);r.current=t;const o=g.useRef(n);o.current=wm(o.current);const[s,i]=g.useState(()=>r.current),[l,c]=g.useState(!0);return g.useEffect(()=>{let d=!0;return c(!!e),(async()=>{if(e){const u=await e();d&&(i(()=>u),c(!1))}})(),()=>{d=!1,o.current.preserveValue||i(()=>r.current)}},[e]),[s,l]},fm=hi(a.jsx("path",{d:"M3 18h18v-2H3zm0-5h18v-2H3zm0-7v2h18V6z"}),"Menu");function Vi({menuProvider:e,normalMenu:t,fullMenu:n,commandHandler:r,containerRef:o,className:s,ariaLabelPrefix:i,children:l}){const[c,d]=g.useState(!1),[u,h]=g.useState(!1),w=g.useCallback(()=>{c&&d(!1),h(!1)},[c]),b=g.useCallback(E=>{E.stopPropagation(),d(v=>{const P=!v;return P&&E.shiftKey?h(!0):P||h(!1),P})},[]),x=g.useCallback(E=>(w(),r(E)),[r,w]),[f,m]=g.useState({top:1,left:1});g.useEffect(()=>{if(c){const E=o==null?void 0:o.current;if(E){const v=E.getBoundingClientRect(),P=window.scrollY,V=window.scrollX,U=v.top+P+E.clientHeight,C=v.left+V;m({top:U,left:C})}}},[c,o]);const[S]=nr(g.useCallback(async()=>(e==null?void 0:e(!1))??t,[e,t,c]),t),[R]=nr(g.useCallback(async()=>(e==null?void 0:e(!0))??n??S,[e,n,S,c]),n??S),j=u&&R?R:S;return a.jsxs(a.Fragment,{children:[a.jsx(Me.IconButton,{sx:{paddingTop:0,paddingBottom:0},edge:"start",className:`papi-menuButton ${s??""}`,color:"inherit","aria-label":`${i??""} menu button`,onClick:b,children:l??a.jsx(fm,{})}),a.jsx(Me.Drawer,{className:`papi-menu-drawer ${s??""}`,anchor:"left",variant:"temporary",open:c,onClose:w,PaperProps:{className:"papi-menu-drawer-paper",style:{top:f.top,left:f.left}},children:j?a.jsx(Bi,{className:s,id:`${i??""} main menu`,commandHandler:x,multiColumnMenu:j}):void 0})]})}function mm({id:e,label:t,isDisabled:n=!1,tooltip:r,isTooltipSuppressed:o=!1,adjustMarginToAlignToEdge:s=!1,size:i="medium",className:l,onClick:c,children:d}){return a.jsx(Me.IconButton,{id:e,disabled:n,edge:s,size:i,"aria-label":t,title:o?void 0:r??t,className:`papi-icon-button ${l??""}`,onClick:c,children:d})}const Kt=g.forwardRef(({className:e,...t},n)=>a.jsx(Q.LoaderCircle,{size:35,className:N("tw-animate-spin",e),...t,ref:n}));Kt.displayName="Spinner";function hm({id:e,isDisabled:t=!1,hasError:n=!1,isFullWidth:r=!1,helperText:o,label:s,placeholder:i,isRequired:l=!1,className:c,defaultValue:d,value:u,onChange:h,onFocus:w,onBlur:b}){return a.jsxs("div",{className:N("tw-inline-grid tw-items-center tw-gap-1.5",{"tw-w-full":r}),children:[a.jsx(qe,{htmlFor:e,className:N({"tw-text-red-600":n,"tw-hidden":!s}),children:`${s}${l?"*":""}`}),a.jsx(St,{id:e,disabled:t,placeholder:i,required:l,className:N(c,{"tw-border-red-600":n}),defaultValue:d,value:u,onChange:h,onFocus:w,onBlur:b}),a.jsx("p",{className:N({"tw-hidden":!o}),children:o})]})}function gm({menuProvider:e,commandHandler:t,className:n,id:r,children:o}){const s=g.useRef(void 0);return a.jsx("div",{ref:s,style:{position:"relative"},children:a.jsx(Me.AppBar,{position:"static",id:r,children:a.jsxs(Me.Toolbar,{className:N("tw-bg-muted tw-text-muted-foreground",n),variant:"dense",children:[e?a.jsx(Vi,{commandHandler:t,containerRef:s,menuProvider:e}):void 0,o?a.jsx("div",{className:"papi-toolbar-children",children:o}):void 0]})})})}const bm=Xt.cva("tw-relative tw-w-full tw-rounded-lg tw-border tw-p-4 [&>svg~*]:tw-pl-7 [&>svg+div]:tw-translate-y-[-3px] [&>svg]:tw-absolute [&>svg]:tw-left-4 [&>svg]:tw-top-4 [&>svg]:tw-text-foreground",{variants:{variant:{default:"tw-bg-background tw-text-foreground",destructive:"tw-border-destructive/50 tw-text-destructive dark:tw-border-destructive [&>svg]:tw-text-destructive"}},defaultVariants:{variant:"default"}}),zi=g.forwardRef(({className:e,variant:t,...n},r)=>a.jsx("div",{ref:r,role:"alert",className:N(bm({variant:t}),e),...n}));zi.displayName="Alert";const Li=g.forwardRef(({className:e,...t},n)=>a.jsxs("h5",{ref:n,className:N("tw-mb-1 tw-font-medium tw-leading-none tw-tracking-tight",e),...t,children:[t.children," "]}));Li.displayName="AlertTitle";const Fi=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,className:N("tw-text-sm [&_p]:tw-leading-relaxed",e),...t}));Fi.displayName="AlertDescription";const Gi=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,className:N("pr-twp tw-rounded-lg tw-border tw-bg-card tw-text-card-foreground tw-shadow-sm",e),...t}));Gi.displayName="Card";const Ui=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,className:N("pr-twp tw-flex tw-flex-col tw-space-y-1.5 tw-p-6",e),...t}));Ui.displayName="CardHeader";const qi=g.forwardRef(({className:e,...t},n)=>a.jsx("h3",{ref:n,className:N("pr-twp tw-text-2xl tw-font-semibold tw-leading-none tw-tracking-tight",e),...t,children:t.children}));qi.displayName="CardTitle";const Hi=g.forwardRef(({className:e,...t},n)=>a.jsx("p",{ref:n,className:N("pr-twp tw-text-sm tw-text-muted-foreground",e),...t}));Hi.displayName="CardDescription";const Xi=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,className:N("pr-twp tw-p-6 tw-pt-0",e),...t}));Xi.displayName="CardContent";const Yi=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,className:N("pr-twp tw-flex tw-items-center tw-p-6 tw-pt-0",e),...t}));Yi.displayName="CardFooter";function vm({...e}){return a.jsx(Qa.Toaster,{className:"tw-toaster tw-group",toastOptions:{classNames:{toast:"group toast group-[.toaster]:bg-background group-[.toaster]:text-foreground group-[.toaster]:border-border group-[.toaster]:shadow-lg",description:"group-[.toast]:text-muted-foreground",actionButton:"group-[.toast]:bg-primary group-[.toast]:text-primary-foreground",cancelButton:"group-[.toast]:bg-muted group-[.toast]:text-muted-foreground"}},...e})}const Wi=g.forwardRef(({className:e,...t},n)=>a.jsxs(cn.Root,{ref:n,className:N("pr-twp tw-relative tw-flex tw-w-full tw-touch-none tw-select-none tw-items-center",e),...t,children:[a.jsx(cn.Track,{className:"tw-relative tw-h-2 tw-w-full tw-grow tw-overflow-hidden tw-rounded-full tw-bg-secondary",children:a.jsx(cn.Range,{className:"tw-absolute tw-h-full tw-bg-primary"})}),a.jsx(cn.Thumb,{className:"tw-block tw-h-5 tw-w-5 tw-rounded-full tw-border-2 tw-border-primary tw-bg-background tw-ring-offset-background tw-transition-colors focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50"})]}));Wi.displayName=cn.Root.displayName;const Ki=g.forwardRef(({className:e,...t},n)=>a.jsx(qr.Root,{className:N("tw-peer pr-twp tw-inline-flex tw-h-6 tw-w-11 tw-shrink-0 tw-cursor-pointer tw-items-center tw-rounded-full tw-border-2 tw-border-transparent tw-transition-colors focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 focus-visible:tw-ring-offset-background disabled:tw-cursor-not-allowed disabled:tw-opacity-50 data-[state=checked]:tw-bg-primary data-[state=unchecked]:tw-bg-input",e),...t,ref:n,children:a.jsx(qr.Thumb,{className:N("pr-twp tw-pointer-events-none tw-block tw-h-5 tw-w-5 tw-rounded-full tw-bg-background tw-shadow-lg tw-ring-0 tw-transition-transform data-[state=checked]:tw-translate-x-5 data-[state=unchecked]:tw-translate-x-0")})}));Ki.displayName=qr.Root.displayName;const xm=Oe.Root,Ji=g.forwardRef(({className:e,...t},n)=>a.jsx(Oe.List,{ref:n,className:N("tw-inline-flex tw-h-10 tw-items-center tw-justify-center tw-rounded-md tw-bg-muted tw-p-1 tw-text-muted-foreground",e),...t}));Ji.displayName=Oe.List.displayName;const Zi=g.forwardRef(({className:e,...t},n)=>a.jsx(Oe.Trigger,{ref:n,className:N("tw-inline-flex tw-items-center tw-justify-center tw-whitespace-nowrap tw-rounded-sm tw-px-3 tw-py-1.5 tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-all hover:tw-text-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50 data-[state=active]:tw-bg-background data-[state=active]:tw-text-foreground data-[state=active]:tw-shadow-sm",e),...t}));Zi.displayName=Oe.Trigger.displayName;const Qi=g.forwardRef(({className:e,...t},n)=>a.jsx(Oe.Content,{ref:n,className:N("tw-mt-2 tw-ring-offset-background focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2",e),...t}));Qi.displayName=Oe.Content.displayName;function ym({isInstalling:e,handleClick:t,buttonText:n,className:r,...o}){return a.jsx(fe,{className:N("tw-h-8 tw-rounded-md tw-text-white tw-transition tw-duration-300 tw-ease-in-out hover:tw-bg-blue-700",{"tw-cursor-not-allowed tw-bg-blue-700":e,"tw-bg-blue-600":!e,"tw-bg-white tw-text-blue-600 hover:tw-text-white":!n,"tw-w-20":n},r),onClick:t,...o,children:e?a.jsx(Kt,{size:15}):a.jsxs(a.Fragment,{children:[a.jsx(Q.Download,{size:25,className:N("tw-h-4 tw-w-4",{"tw-mr-1":n})}),n]})})}function Nm({isEnabling:e,handleClick:t,className:n,...r}){return a.jsx(fe,{className:N("tw-h-8 tw-rounded-md tw-bg-blue-600 tw-px-4 tw-text-white tw-transition tw-duration-300 tw-ease-in-out hover:tw-bg-blue-700",{"tw-cursor-not-allowed tw-bg-blue-700":e},n),onClick:t,...r,children:e?a.jsxs(a.Fragment,{children:[a.jsx(Kt,{size:15,className:"tw-mr-1 tw-text-white"}),"Enabling..."]}):"Enable"})}function km({isDisabling:e,handleClick:t,className:n,...r}){return a.jsx(fe,{className:N("tw-h-8 tw-rounded-md tw-bg-gray-300 tw-text-black tw-transition tw-duration-300 tw-ease-in-out hover:tw-bg-gray-400",{"tw-cursor-not-allowed tw-bg-gray-400":e},n),onClick:t,...r,children:e?a.jsxs(a.Fragment,{children:[a.jsx(Kt,{size:15,className:"tw-mr-1 tw-text-black"}),"Disabling..."]}):"Disable"})}function Sm({isUpdating:e,handleClick:t,className:n,...r}){return a.jsx(fe,{className:N("tw-h-8 tw-rounded-md tw-bg-blue-600 tw-px-4 tw-text-white tw-transition tw-duration-300 tw-ease-in-out hover:tw-bg-blue-700 hover:tw-text-white",{"tw-cursor-not-allowed tw-bg-blue-700":e},n),onClick:t,...r,children:e?a.jsxs(a.Fragment,{children:[a.jsx(Kt,{size:15,className:"tw-mr-1 tw-text-white"}),"Updating..."]}):"Update"})}function Em({id:e,markdown:t,className:n,anchorTarget:r}){const o=g.useMemo(()=>({overrides:{a:{props:{target:r}}}}),[r]);return a.jsx("div",{id:e,className:N("pr-twp tw-prose",n),children:a.jsx(Rl,{options:o,children:t})})}const el=g.forwardRef((e,t)=>a.jsxs(fe,{ref:t,className:"tw-rounded-md tw-border tw-border-dashed tw-border-gray-400 tw-bg-white tw-px-4 tw-py-2 tw-text-black tw-transition tw-duration-300 tw-ease-in-out hover:tw-border-blue-600 hover:tw-bg-white hover:tw-text-blue-600",...e,children:[a.jsx(Q.Filter,{size:16,className:"tw-mr-2 tw-h-4 tw-w-4 tw-text-gray-700 hover:tw-text-blue-600"}),"Filter",a.jsx(Q.ChevronDown,{size:16,className:"tw-ml-2 tw-h-4 tw-w-4 tw-text-gray-700 hover:tw-text-blue-600"})]}));var tl=(e=>(e[e.Check=0]="Check",e[e.Radio=1]="Radio",e))(tl||{});function jm({id:e,groups:t}){return a.jsx("div",{id:e,children:a.jsxs(or,{children:[a.jsx(lo,{asChild:!0,children:a.jsx(el,{})}),a.jsx(En,{children:t.map(n=>a.jsxs("div",{children:[a.jsx(Wt,{children:n.label}),a.jsx(cs,{children:n.items.map(r=>a.jsx("div",{children:r.itemType===0?a.jsx(ar,{onClick:r.onClick,children:r.label}):a.jsx(uo,{onClick:r.onClick,value:r.label,children:r.label})},r.label))}),a.jsx(jn,{})]},n.label))})]})})}function Cm({id:e,message:t}){return a.jsx("div",{id:e,className:"tw-mb-20 tw-mt-20 tw-flex tw-items-center tw-justify-center",children:a.jsx("div",{className:"tw-w-3/4 tw-rounded-lg tw-bg-gray-100 tw-p-8 tw-text-center",children:a.jsx("p",{className:"tw-text-lg tw-text-gray-800",children:t})})})}function Tm({id:e,category:t,downloads:n,languages:r,moreInfoUrl:o}){const s=new W.NumberFormat("en",{notation:"compact",compactDisplay:"short"}).format(Object.values(n).reduce((l,c)=>l+c,0)),i=()=>{window.scrollTo(0,document.body.scrollHeight)};return a.jsxs("div",{id:e,className:"tw-flex tw-flex-wrap tw-items-start tw-space-x-4 tw-border-b tw-border-t tw-bg-white tw-pb-4 tw-pt-4",children:[a.jsxs("div",{className:"tw-flex tw-flex-col tw-items-center",children:[a.jsx("div",{className:"tw-flex tw-items-center tw-rounded-md tw-bg-gray-100 tw-px-2 tw-py-1",children:a.jsx("span",{className:"tw-text-xs tw-font-semibold tw-text-gray-700",children:t})}),a.jsx("span",{className:"tw-text-xs tw-text-gray-500",children:"CATEGORY"})]}),a.jsx("div",{className:"tw-mx-2 tw-h-10 tw-border-l tw-border-gray-300"}),a.jsxs("div",{className:"tw-flex tw-flex-col tw-items-center",children:[a.jsxs("div",{className:"tw-flex tw-items-center tw-rounded-md tw-bg-gray-100 tw-px-2 tw-py-1",children:[a.jsx(Q.User,{className:"tw-mr-1 tw-h-4 tw-w-4"}),a.jsx("span",{className:"tw-text-xs tw-font-semibold tw-text-gray-700",children:s})]}),a.jsx("span",{className:"tw-text-xs tw-text-gray-500",children:"USERS"})]}),a.jsx("div",{className:"tw-mx-2 tw-h-10 tw-border-l tw-border-gray-300"}),a.jsxs("div",{className:"tw-flex tw-flex-col tw-items-center",children:[a.jsx("div",{className:"tw-flex tw-items-center",children:r.slice(0,3).map(l=>a.jsx("span",{className:"tw-ml-1 tw-rounded-md tw-bg-gray-100 tw-px-2 tw-py-1 tw-text-xs tw-font-semibold tw-text-gray-700",children:l.toUpperCase()},l))}),r.length>3&&a.jsxs("button",{type:"button",onClick:()=>i(),className:"tw-text-xs tw-text-gray-500 tw-underline",children:["+",r.length-3," more languages"]})]}),a.jsx("div",{className:"tw-mx-2 tw-h-10 tw-border-l tw-border-gray-300"}),a.jsxs("div",{className:"tw-ml-auto tw-flex tw-flex-col tw-space-y-2",children:[a.jsxs("a",{href:o,target:"_blank",rel:"noreferrer",className:"tw-flex tw-items-center tw-text-xs tw-font-semibold tw-text-gray-500 tw-underline",children:["Website",a.jsx(Q.Link,{className:"tw-ml-1 tw-inline tw-h-4 tw-w-4"})]}),a.jsxs("a",{href:"https://example.com",target:"_blank",rel:"noreferrer",className:"tw-flex tw-items-center tw-text-xs tw-font-semibold tw-text-gray-500 tw-underline",children:["Support",a.jsx(Q.CircleHelp,{className:"tw-ml-1 tw-inline tw-h-4 tw-w-4"})]})]})]})}function nl({id:e,versionHistory:t}){const[n,r]=g.useState(!1),o=new Date;function s(l){const c=new Date(l),d=new Date(o.getTime()-c.getTime()),u=d.getUTCFullYear()-1970,h=d.getUTCMonth(),w=d.getUTCDate()-1;let b="";return u>0?b=`${u.toString()} year${u===1?"":"s"} ago`:h>0?b=`${h.toString()} month${h===1?"":"s"} ago`:w===0?b="today":b=`${w.toString()} day${w===1?"":"s"} ago`,b}const i=Object.entries(t).sort((l,c)=>c[0].localeCompare(l[0]));return a.jsxs("div",{id:e,children:[a.jsx("h3",{className:"tw-text-md tw-font-semibold",children:"What`s New"}),a.jsx("ul",{className:"tw-list-disc tw-pl-5 tw-pr-4 tw-text-xs tw-text-gray-600",children:(n?i:i.slice(0,5)).map(l=>a.jsxs("div",{className:"tw-mt-3 tw-flex tw-justify-between",children:[a.jsx("div",{className:"tw-text-gray-600",children:a.jsx("li",{className:"tw-prose tw-text-xs",children:a.jsx("span",{children:l[1].description})})}),a.jsxs("div",{className:"tw-justify-end tw-text-right",children:[a.jsxs("div",{children:["Version ",l[0]]}),a.jsx("div",{children:s(l[1].date)})]})]},l[0]))}),i.length>5&&a.jsx("button",{type:"button",onClick:()=>r(!n),className:"tw-text-xs tw-text-gray-500 tw-underline",children:n?"Show Less Version History":"Show All Version History"})]})}function Rm({id:e,publisherDisplayName:t,fileSize:n,locales:r,versionHistory:o}){const s=g.useMemo(()=>W.formatBytes(n),[n]),l=(c=>{const d=new Intl.DisplayNames(navigator.language,{type:"language"});return c.map(u=>d.of(u))})(r);return a.jsx("div",{id:e,className:"tw-border-t tw-pb-4 tw-pt-4",children:a.jsxs("div",{className:"tw-md:flex-row tw-md:space-x-8 tw-flex tw-flex-col tw-space-x-0",children:[a.jsx(nl,{versionHistory:o}),a.jsx("div",{className:"tw-md:border-t-0 tw-md:border-l tw-md-h-auto tw-md-ml-8 tw-mt-4 tw-border-t tw-border-gray-300"}),a.jsxs("div",{className:"tw-md:mt-0 tw-mt-4 tw-flex-1 tw-space-y-3",children:[a.jsx("h2",{className:"tw-text-md tw-font-semibold",children:"Information"}),a.jsxs("div",{className:"tw-flex tw-items-start tw-justify-between tw-pr-4 tw-text-xs tw-text-gray-600",children:[a.jsxs("p",{className:"tw-flex tw-flex-col tw-justify-start",children:[a.jsx("span",{className:"tw-mb-2",children:"Publisher"}),a.jsx("span",{className:"tw-font-semibold",children:t}),a.jsx("span",{className:"tw-mb-2 tw-mt-4",children:"Size"}),a.jsx("span",{className:"tw-font-semibold",children:s})]}),a.jsx("div",{className:"tw-flex tw-w-3/4 tw-items-center tw-justify-between tw-text-xs tw-text-gray-600",children:a.jsxs("p",{className:"tw-flex tw-flex-col tw-justify-start",children:[a.jsx("span",{className:"tw-mb-2",children:"Languages"}),a.jsx("span",{className:"tw-font-semibold",children:l.join(", ")})]})})]})]})]})})}const Om=(e,t)=>{g.useEffect(()=>{if(!e)return()=>{};const n=e(t);return()=>{n()}},[e,t])},Fr=()=>!1,_m=(e,t)=>{const[n]=nr(g.useCallback(async()=>{if(!e)return Fr;const r=await Promise.resolve(e(t));return async()=>r()},[t,e]),Fr,{preserveValue:!1});g.useEffect(()=>()=>{n!==Fr&&n()},[n])};Object.defineProperty(exports,"sonner",{enumerable:!0,get:()=>Qa.toast});exports.Alert=zi;exports.AlertDescription=Fi;exports.AlertTitle=Li;exports.BOOK_SELECTOR_STRING_KEYS=mc;exports.BookChapterControl=oc;exports.BookSelectionMode=Ns;exports.BookSelector=hc;exports.Button=fe;exports.Card=Gi;exports.CardContent=Xi;exports.CardDescription=Hi;exports.CardFooter=Yi;exports.CardHeader=Ui;exports.CardTitle=qi;exports.ChapterRangeSelector=ys;exports.Checkbox=sr;exports.Checklist=bd;exports.ComboBox=Wn;exports.DataTable=Ts;exports.DisableButton=km;exports.DropdownMenu=or;exports.DropdownMenuCheckboxItem=ar;exports.DropdownMenuContent=En;exports.DropdownMenuGroup=cs;exports.DropdownMenuItem=co;exports.DropdownMenuItemType=tl;exports.DropdownMenuLabel=Wt;exports.DropdownMenuPortal=ql;exports.DropdownMenuRadioGroup=Xl;exports.DropdownMenuRadioItem=uo;exports.DropdownMenuSeparator=jn;exports.DropdownMenuShortcut=ps;exports.DropdownMenuSub=Hl;exports.DropdownMenuSubContent=us;exports.DropdownMenuSubTrigger=ds;exports.DropdownMenuTrigger=lo;exports.EnableButton=Nm;exports.FilterButton=el;exports.FilterDropdown=jm;exports.Footer=Rm;exports.GridMenu=Bi;exports.HamburgerMenuButton=Vi;exports.INVENTORY_STRING_KEYS=Ec;exports.IconButton=mm;exports.Input=St;exports.InstallButton=ym;exports.Inventory=Tc;exports.Label=qe;exports.MarkdownRenderer=Em;exports.MenuItem=Fo;exports.MoreInfo=Tm;exports.NavigationContentSearch=Rc;exports.NoExtensionsFound=Cm;exports.RadioGroup=po;exports.RadioGroupItem=Yn;exports.ScriptureResultsViewer=wd;exports.ScrollGroupSelector=fd;exports.SearchBar=ho;exports.Select=At;exports.SelectContent=vt;exports.SelectGroup=ks;exports.SelectItem=Ae;exports.SelectLabel=Ss;exports.SelectScrollDownButton=fo;exports.SelectScrollUpButton=wo;exports.SelectSeparator=Es;exports.SelectTrigger=bt;exports.SelectValue=Bt;exports.Separator=lr;exports.SettingsList=md;exports.SettingsListHeader=gd;exports.SettingsListItem=hd;exports.SettingsSidebar=Hs;exports.SettingsSidebarContentSearch=ad;exports.Slider=Wi;exports.Sonner=vm;exports.Spinner=Kt;exports.Switch=Ki;exports.Table=Cn;exports.TableBody=Rn;exports.TableCaption=Cs;exports.TableCell=xt;exports.TableFooter=js;exports.TableHead=Vt;exports.TableHeader=Tn;exports.TableRow=Ze;exports.Tabs=xm;exports.TabsContent=Qi;exports.TabsList=Ji;exports.TabsTrigger=Zi;exports.TextField=hm;exports.ToggleGroup=mo;exports.ToggleGroupItem=fn;exports.Toolbar=gm;exports.UpdateButton=Sm;exports.VersionHistory=nl;exports.VerticalTabs=go;exports.VerticalTabsContent=vo;exports.VerticalTabsList=bo;exports.VerticalTabsTrigger=Ms;exports.buttonVariants=ws;exports.cn=N;exports.getBookNumFromId=Os;exports.getLinesFromUSFM=Rs;exports.getNumberFromUSFM=Hr;exports.getStatusForItem=_s;exports.inventoryCountColumn=kc;exports.inventoryItemColumn=yc;exports.inventoryStatusColumn=Sc;exports.useEvent=Om;exports.useEventAsync=_m;exports.usePromise=nr;function Pm(e,t="top"){if(!e||typeof document>"u")return;const n=document.head||document.querySelector("head"),r=n.querySelector(":first-child"),o=document.createElement("style");o.appendChild(document.createTextNode(e)),t==="top"&&r?n.insertBefore(o,r):n.appendChild(o)}Pm(`*, ::before, ::after { +`));const dl=M.useMemo(()=>{var ee;let _e=[{name:"arrow",enabled:!!Ue,options:{element:Ue,padding:4}}];return(ee=G.popperOptions)!=null&&ee.modifiers&&(_e=_e.concat(G.popperOptions.modifiers)),O({},G.popperOptions,{modifiers:_e})},[Ue,G]),tn=O({},P,{isRtl:lt,arrow:V,disableInteractive:jt,placement:q,PopperComponentProp:H,touch:ct.current}),Cr=om(tn),Qo=(r=(o=Z.popper)!=null?o:C.Popper)!=null?r:am,ea=(s=(i=(l=Z.transition)!=null?l:C.Transition)!=null?i:I)!=null?s:Wa,ta=(c=(u=Z.tooltip)!=null?u:C.Tooltip)!=null?c:sm,na=(d=(m=Z.arrow)!=null?m:C.Arrow)!=null?d:im,ul=un(Qo,O({},G,(w=K.popper)!=null?w:_.popper,{className:ot(Cr.popper,G==null?void 0:G.className,(b=(x=K.popper)!=null?x:_.popper)==null?void 0:b.className)}),tn),pl=un(ea,O({},ye,(f=K.transition)!=null?f:_.transition),tn),wl=un(ta,O({},(h=K.tooltip)!=null?h:_.tooltip,{className:ot(Cr.tooltip,(S=(R=K.tooltip)!=null?R:_.tooltip)==null?void 0:S.className)}),tn),fl=un(na,O({},(j=K.arrow)!=null?j:_.arrow,{className:ot(Cr.arrow,(E=(v=K.arrow)!=null?v:_.arrow)==null?void 0:E.className)}),tn);return a.jsxs(M.Fragment,{children:[M.cloneElement(xe,De),a.jsx(Qo,O({as:H??Mi,placement:q,anchorEl:oe?{getBoundingClientRect:()=>({top:sn.y,left:sn.x,right:sn.x,bottom:sn.y,width:0,height:0})}:Ee,popperRef:Er,open:Ee?Ke:!1,id:kr,transition:!0},en,ul,{popperOptions:dl,children:({TransitionProps:ee})=>a.jsx(ea,O({timeout:Ge.transitions.duration.shorter},ee,pl,{children:a.jsxs(ta,O({},wl,{children:[ue,V?a.jsx(na,O({},fl,{ref:Et})):null]}))}))}))]})});process.env.NODE_ENV!=="production"&&($i.propTypes={arrow:p.bool,children:ei.isRequired,classes:p.object,className:p.string,components:p.shape({Arrow:p.elementType,Popper:p.elementType,Tooltip:p.elementType,Transition:p.elementType}),componentsProps:p.shape({arrow:p.object,popper:p.object,tooltip:p.object,transition:p.object}),describeChild:p.bool,disableFocusListener:p.bool,disableHoverListener:p.bool,disableInteractive:p.bool,disableTouchListener:p.bool,enterDelay:p.number,enterNextDelay:p.number,enterTouchDelay:p.number,followCursor:p.bool,id:p.string,leaveDelay:p.number,leaveTouchDelay:p.number,onClose:p.func,onOpen:p.func,open:p.bool,placement:p.oneOf(["bottom-end","bottom-start","bottom","left-end","left-start","left","right-end","right-start","right","top-end","top-start","top"]),PopperComponent:p.elementType,PopperProps:p.object,slotProps:p.shape({arrow:p.object,popper:p.object,tooltip:p.object,transition:p.object}),slots:p.shape({arrow:p.elementType,popper:p.elementType,tooltip:p.elementType,transition:p.elementType}),sx:p.oneOfType([p.arrayOf(p.oneOfType([p.func,p.object,p.bool])),p.func,p.object]),title:p.node,TransitionComponent:p.elementType,TransitionProps:p.object});const lm=$i;function Ja(e,t,n){return e?a.jsx(Me.ListItemIcon,{className:`papi-menu-icon-${n?"leading":"trailing"}`,children:a.jsx("img",{src:e,alt:`${n?"Leading":"Trailing"} icon for ${t}`})}):void 0}function Fo(e){const{onClick:t,label:n,tooltip:r,allowForLeadingIcons:o=!0,iconPathBefore:s=void 0,iconPathAfter:i=void 0,hasAutoFocus:l=!1,className:c,isDisabled:u=!1,isDense:d=!0,isSubMenuParent:m=!1,hasDisabledGutters:w=!1,hasDivider:b=!1,focusVisibleClassName:x,id:f,children:h}=e,S=a.jsx(Me.MenuItem,{sx:{lineHeight:.8},autoFocus:l,className:c,disabled:u,dense:d,disableGutters:w,divider:b,focusVisibleClassName:x,onClick:t,id:f,children:n?a.jsxs(a.Fragment,{children:[Ja(s,n,!0),a.jsx(Me.ListItemText,{primary:n,inset:!s&&o}),m?a.jsx(Me.ListItemIcon,{className:"papi-menu-icon-trailing",children:a.jsx(gi,{})}):Ja(i,n,!1)]}):h});return r?a.jsx(lm,{title:r,placement:"right",children:a.jsx("div",{children:S})}):S}function Di(e){return Object.entries(e.groups).map(([n,r])=>({id:n,group:r}))}function cm(e){const[t,n]=g.useState(void 0),{parentMenuItem:r,parentItemProps:o,menuDefinition:s}=e,i=u=>{n(u.currentTarget)},l=()=>{n(void 0)},c=()=>{let u=Di(s).filter(d=>"menuItem"in d.group);if(!(r!=null&&r.id))throw new Error("A valid parent menu item is required for submenus.");return u=u.filter(d=>"menuItem"in d.group&&d.group.menuItem===r.id),a.jsx(Ai,{...e,includedGroups:u})};return a.jsxs(a.Fragment,{children:[a.jsx(Fo,{onClick:i,...o,isSubMenuParent:!0}),a.jsx(Me.Menu,{anchorEl:t,open:!!t,onClose:l,anchorOrigin:{vertical:"top",horizontal:"right"},transformOrigin:{vertical:"top",horizontal:"left"},children:c()},r.id)]})}const dm=(e,t)=>t.filter(o=>o.group===e).sort((o,s)=>(o.order||0)-(s.order||0));function Ai(e){const{menuDefinition:t,onClick:n,commandHandler:r,includedGroups:o}=e,{items:s,allowForLeadingIcons:i}=g.useMemo(()=>{const d=o&&o.length>0?o:Di(t).filter(x=>!("menuItem"in x.group)),m=Object.values(d).sort((x,f)=>(x.group.order||0)-(f.group.order||0)),w=[];m.forEach(x=>{dm(x.id,t.items).forEach(f=>w.push({item:f,isLastItemInGroup:!1})),w.length>0&&(w[w.length-1].isLastItemInGroup=!0)}),w.length>0&&(w[w.length-1].isLastItemInGroup=!1);const b=w.some(x=>"iconPathBefore"in x.item&&x.item.iconPathBefore);return{items:w,allowForLeadingIcons:b}},[o,t]),l=({item:d,isLastItemInGroup:m})=>({className:"papi-menu-item",label:d.label,tooltip:d.tooltip,iconPathBefore:"iconPathBefore"in d?d.iconPathBefore:void 0,iconPathAfter:"iconPathAfter"in d?d.iconPathAfter:void 0,hasDivider:m,allowForLeadingIcons:i}),[c]=s;if(!c)return a.jsx("div",{});const u=c.item.group;return a.jsx("div",{role:"menu","aria-label":u,children:s.map((d,m)=>{const{item:w}=d,b=l(d);if("command"in w){const x=w.group+m;return a.jsx(Fo,{onClick:f=>{n==null||n(f),r(w)},...b},x)}return a.jsx(cm,{parentMenuItem:w,parentItemProps:b,...e},u+w.id)})},u)}function um(e){const{menuDefinition:t,columnId:n}=e;let s=Object.entries(t.groups).map(([i,l])=>({id:i,group:l})).filter(i=>"column"in i.group);return n&&"columns"in t&&t.columns[n]&&(s=s.filter(i=>"column"in i.group&&i.group.column===n)),a.jsx(Ai,{...e,includedGroups:s})}function pm({commandHandler:e,menuDefinition:t,id:n,metadata:r,onClick:o,className:s}){return a.jsxs(Me.Grid,{id:n,item:!0,xs:"auto",role:"menu","aria-label":n,className:`papi-menu-column ${s??""}`,children:[a.jsx("h3",{"aria-label":r.label,className:`papi-menu-column-header ${s??""}`,children:r.label}),a.jsx(Me.List,{id:n,dense:!0,className:s??"",children:a.jsx(um,{commandHandler:e,menuDefinition:t,columnId:n,onClick:o})})]})}function Bi({commandHandler:e,className:t,multiColumnMenu:n,id:r}){const{columns:o}=n,s=g.useMemo(()=>{const i=new Map;return Object.getOwnPropertyNames(o).forEach(l=>{if(l==="isExtensible")return;const c=l,u=o[c];typeof u=="object"&&typeof u.order=="number"&&!Number.isNaN(u.order)?i.set(u.order,{id:c,metadata:u}):console.warn(`Property ${l} (${typeof u}) on menu ${r} is not a valid column and is being ignored. This might indicate data corruption`)}),Array.from(i.values()).sort((l,c)=>(l.metadata.order||0)-(c.metadata.order||0))},[o,r]);return a.jsx(Me.Grid,{container:!0,spacing:0,className:`papi-multi-column-menu ${t??""}`,columns:s.length,role:"menu","aria-label":"GridMenu",id:r,children:s.map((i,l)=>a.jsx(pm,{commandHandler:e,menuDefinition:n,...i,className:t},l))})}function wm(e){return{preserveValue:!0,...e}}const nr=(e,t,n={})=>{const r=g.useRef(t);r.current=t;const o=g.useRef(n);o.current=wm(o.current);const[s,i]=g.useState(()=>r.current),[l,c]=g.useState(!0);return g.useEffect(()=>{let u=!0;return c(!!e),(async()=>{if(e){const d=await e();u&&(i(()=>d),c(!1))}})(),()=>{u=!1,o.current.preserveValue||i(()=>r.current)}},[e]),[s,l]},fm=hi(a.jsx("path",{d:"M3 18h18v-2H3zm0-5h18v-2H3zm0-7v2h18V6z"}),"Menu");function Vi({menuProvider:e,normalMenu:t,fullMenu:n,commandHandler:r,containerRef:o,className:s,ariaLabelPrefix:i,children:l}){const[c,u]=g.useState(!1),[d,m]=g.useState(!1),w=g.useCallback(()=>{c&&u(!1),m(!1)},[c]),b=g.useCallback(E=>{E.stopPropagation(),u(v=>{const P=!v;return P&&E.shiftKey?m(!0):P||m(!1),P})},[]),x=g.useCallback(E=>(w(),r(E)),[r,w]),[f,h]=g.useState({top:1,left:1});g.useEffect(()=>{if(c){const E=o==null?void 0:o.current;if(E){const v=E.getBoundingClientRect(),P=window.scrollY,V=window.scrollX,U=v.top+P+E.clientHeight,C=v.left+V;h({top:U,left:C})}}},[c,o]);const[S]=nr(g.useCallback(async()=>(e==null?void 0:e(!1))??t,[e,t,c]),t),[R]=nr(g.useCallback(async()=>(e==null?void 0:e(!0))??n??S,[e,n,S,c]),n??S),j=d&&R?R:S;return a.jsxs(a.Fragment,{children:[a.jsx(Me.IconButton,{sx:{paddingTop:0,paddingBottom:0},edge:"start",className:`papi-menuButton ${s??""}`,color:"inherit","aria-label":`${i??""} menu button`,onClick:b,children:l??a.jsx(fm,{})}),a.jsx(Me.Drawer,{className:`papi-menu-drawer ${s??""}`,anchor:"left",variant:"temporary",open:c,onClose:w,PaperProps:{className:"papi-menu-drawer-paper",style:{top:f.top,left:f.left}},children:j?a.jsx(Bi,{className:s,id:`${i??""} main menu`,commandHandler:x,multiColumnMenu:j}):void 0})]})}function mm({id:e,label:t,isDisabled:n=!1,tooltip:r,isTooltipSuppressed:o=!1,adjustMarginToAlignToEdge:s=!1,size:i="medium",className:l,onClick:c,children:u}){return a.jsx(Me.IconButton,{id:e,disabled:n,edge:s,size:i,"aria-label":t,title:o?void 0:r??t,className:`papi-icon-button ${l??""}`,onClick:c,children:u})}const Kt=g.forwardRef(({className:e,...t},n)=>a.jsx(Q.LoaderCircle,{size:35,className:N("tw-animate-spin",e),...t,ref:n}));Kt.displayName="Spinner";function hm({id:e,isDisabled:t=!1,hasError:n=!1,isFullWidth:r=!1,helperText:o,label:s,placeholder:i,isRequired:l=!1,className:c,defaultValue:u,value:d,onChange:m,onFocus:w,onBlur:b}){return a.jsxs("div",{className:N("tw-inline-grid tw-items-center tw-gap-1.5",{"tw-w-full":r}),children:[a.jsx(qe,{htmlFor:e,className:N({"tw-text-red-600":n,"tw-hidden":!s}),children:`${s}${l?"*":""}`}),a.jsx(St,{id:e,disabled:t,placeholder:i,required:l,className:N(c,{"tw-border-red-600":n}),defaultValue:u,value:d,onChange:m,onFocus:w,onBlur:b}),a.jsx("p",{className:N({"tw-hidden":!o}),children:o})]})}function gm({menuProvider:e,commandHandler:t,className:n,id:r,children:o}){const s=g.useRef(void 0);return a.jsx("div",{ref:s,style:{position:"relative"},children:a.jsx(Me.AppBar,{position:"static",id:r,children:a.jsxs(Me.Toolbar,{className:N("tw-bg-muted tw-text-muted-foreground",n),variant:"dense",children:[e?a.jsx(Vi,{commandHandler:t,containerRef:s,menuProvider:e}):void 0,o?a.jsx("div",{className:"papi-toolbar-children",children:o}):void 0]})})})}const bm=Xt.cva("tw-relative tw-w-full tw-rounded-lg tw-border tw-p-4 [&>svg~*]:tw-pl-7 [&>svg+div]:tw-translate-y-[-3px] [&>svg]:tw-absolute [&>svg]:tw-left-4 [&>svg]:tw-top-4 [&>svg]:tw-text-foreground",{variants:{variant:{default:"tw-bg-background tw-text-foreground",destructive:"tw-border-destructive/50 tw-text-destructive dark:tw-border-destructive [&>svg]:tw-text-destructive"}},defaultVariants:{variant:"default"}}),zi=g.forwardRef(({className:e,variant:t,...n},r)=>a.jsx("div",{ref:r,role:"alert",className:N(bm({variant:t}),e),...n}));zi.displayName="Alert";const Li=g.forwardRef(({className:e,...t},n)=>a.jsxs("h5",{ref:n,className:N("tw-mb-1 tw-font-medium tw-leading-none tw-tracking-tight",e),...t,children:[t.children," "]}));Li.displayName="AlertTitle";const Fi=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,className:N("tw-text-sm [&_p]:tw-leading-relaxed",e),...t}));Fi.displayName="AlertDescription";const Gi=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,className:N("pr-twp tw-rounded-lg tw-border tw-bg-card tw-text-card-foreground tw-shadow-sm",e),...t}));Gi.displayName="Card";const Ui=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,className:N("pr-twp tw-flex tw-flex-col tw-space-y-1.5 tw-p-6",e),...t}));Ui.displayName="CardHeader";const qi=g.forwardRef(({className:e,...t},n)=>a.jsx("h3",{ref:n,className:N("pr-twp tw-text-2xl tw-font-semibold tw-leading-none tw-tracking-tight",e),...t,children:t.children}));qi.displayName="CardTitle";const Hi=g.forwardRef(({className:e,...t},n)=>a.jsx("p",{ref:n,className:N("pr-twp tw-text-sm tw-text-muted-foreground",e),...t}));Hi.displayName="CardDescription";const Xi=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,className:N("pr-twp tw-p-6 tw-pt-0",e),...t}));Xi.displayName="CardContent";const Yi=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,className:N("pr-twp tw-flex tw-items-center tw-p-6 tw-pt-0",e),...t}));Yi.displayName="CardFooter";function vm({...e}){return a.jsx(Qa.Toaster,{className:"tw-toaster tw-group",toastOptions:{classNames:{toast:"group toast group-[.toaster]:bg-background group-[.toaster]:text-foreground group-[.toaster]:border-border group-[.toaster]:shadow-lg",description:"group-[.toast]:text-muted-foreground",actionButton:"group-[.toast]:bg-primary group-[.toast]:text-primary-foreground",cancelButton:"group-[.toast]:bg-muted group-[.toast]:text-muted-foreground"}},...e})}const Wi=g.forwardRef(({className:e,...t},n)=>a.jsxs(cn.Root,{ref:n,className:N("pr-twp tw-relative tw-flex tw-w-full tw-touch-none tw-select-none tw-items-center",e),...t,children:[a.jsx(cn.Track,{className:"tw-relative tw-h-2 tw-w-full tw-grow tw-overflow-hidden tw-rounded-full tw-bg-secondary",children:a.jsx(cn.Range,{className:"tw-absolute tw-h-full tw-bg-primary"})}),a.jsx(cn.Thumb,{className:"tw-block tw-h-5 tw-w-5 tw-rounded-full tw-border-2 tw-border-primary tw-bg-background tw-ring-offset-background tw-transition-colors focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50"})]}));Wi.displayName=cn.Root.displayName;const Ki=g.forwardRef(({className:e,...t},n)=>a.jsx(qr.Root,{className:N("tw-peer pr-twp tw-inline-flex tw-h-6 tw-w-11 tw-shrink-0 tw-cursor-pointer tw-items-center tw-rounded-full tw-border-2 tw-border-transparent tw-transition-colors focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 focus-visible:tw-ring-offset-background disabled:tw-cursor-not-allowed disabled:tw-opacity-50 data-[state=checked]:tw-bg-primary data-[state=unchecked]:tw-bg-input",e),...t,ref:n,children:a.jsx(qr.Thumb,{className:N("pr-twp tw-pointer-events-none tw-block tw-h-5 tw-w-5 tw-rounded-full tw-bg-background tw-shadow-lg tw-ring-0 tw-transition-transform data-[state=checked]:tw-translate-x-5 data-[state=unchecked]:tw-translate-x-0")})}));Ki.displayName=qr.Root.displayName;const xm=Oe.Root,Ji=g.forwardRef(({className:e,...t},n)=>a.jsx(Oe.List,{ref:n,className:N("tw-inline-flex tw-h-10 tw-items-center tw-justify-center tw-rounded-md tw-bg-muted tw-p-1 tw-text-muted-foreground",e),...t}));Ji.displayName=Oe.List.displayName;const Zi=g.forwardRef(({className:e,...t},n)=>a.jsx(Oe.Trigger,{ref:n,className:N("tw-inline-flex tw-items-center tw-justify-center tw-whitespace-nowrap tw-rounded-sm tw-px-3 tw-py-1.5 tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-all hover:tw-text-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50 data-[state=active]:tw-bg-background data-[state=active]:tw-text-foreground data-[state=active]:tw-shadow-sm",e),...t}));Zi.displayName=Oe.Trigger.displayName;const Qi=g.forwardRef(({className:e,...t},n)=>a.jsx(Oe.Content,{ref:n,className:N("tw-mt-2 tw-ring-offset-background focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2",e),...t}));Qi.displayName=Oe.Content.displayName;function ym({isInstalling:e,handleClick:t,buttonText:n,className:r,...o}){return a.jsx(fe,{className:N("tw-h-8 tw-rounded-md tw-text-white tw-transition tw-duration-300 tw-ease-in-out hover:tw-bg-blue-700",{"tw-cursor-not-allowed tw-bg-blue-700":e,"tw-bg-blue-600":!e,"tw-bg-white tw-text-blue-600 hover:tw-text-white":!n,"tw-w-20":n},r),onClick:t,...o,children:e?a.jsx(Kt,{size:15}):a.jsxs(a.Fragment,{children:[a.jsx(Q.Download,{size:25,className:N("tw-h-4 tw-w-4",{"tw-mr-1":n})}),n]})})}function Nm({isEnabling:e,handleClick:t,className:n,...r}){return a.jsx(fe,{className:N("tw-h-8 tw-rounded-md tw-bg-blue-600 tw-px-4 tw-text-white tw-transition tw-duration-300 tw-ease-in-out hover:tw-bg-blue-700",{"tw-cursor-not-allowed tw-bg-blue-700":e},n),onClick:t,...r,children:e?a.jsxs(a.Fragment,{children:[a.jsx(Kt,{size:15,className:"tw-mr-1 tw-text-white"}),"Enabling..."]}):"Enable"})}function km({isDisabling:e,handleClick:t,className:n,...r}){return a.jsx(fe,{className:N("tw-h-8 tw-rounded-md tw-bg-gray-300 tw-text-black tw-transition tw-duration-300 tw-ease-in-out hover:tw-bg-gray-400",{"tw-cursor-not-allowed tw-bg-gray-400":e},n),onClick:t,...r,children:e?a.jsxs(a.Fragment,{children:[a.jsx(Kt,{size:15,className:"tw-mr-1 tw-text-black"}),"Disabling..."]}):"Disable"})}function Sm({isUpdating:e,handleClick:t,className:n,...r}){return a.jsx(fe,{className:N("tw-h-8 tw-rounded-md tw-bg-blue-600 tw-px-4 tw-text-white tw-transition tw-duration-300 tw-ease-in-out hover:tw-bg-blue-700 hover:tw-text-white",{"tw-cursor-not-allowed tw-bg-blue-700":e},n),onClick:t,...r,children:e?a.jsxs(a.Fragment,{children:[a.jsx(Kt,{size:15,className:"tw-mr-1 tw-text-white"}),"Updating..."]}):"Update"})}function Em({id:e,markdown:t,className:n,anchorTarget:r}){const o=g.useMemo(()=>({overrides:{a:{props:{target:r}}}}),[r]);return a.jsx("div",{id:e,className:N("pr-twp tw-prose",n),children:a.jsx(Rl,{options:o,children:t})})}const el=g.forwardRef((e,t)=>a.jsxs(fe,{ref:t,className:"tw-rounded-md tw-border tw-border-dashed tw-border-gray-400 tw-bg-white tw-px-4 tw-py-2 tw-text-black tw-transition tw-duration-300 tw-ease-in-out hover:tw-border-blue-600 hover:tw-bg-white hover:tw-text-blue-600",...e,children:[a.jsx(Q.Filter,{size:16,className:"tw-mr-2 tw-h-4 tw-w-4 tw-text-gray-700 hover:tw-text-blue-600"}),"Filter",a.jsx(Q.ChevronDown,{size:16,className:"tw-ml-2 tw-h-4 tw-w-4 tw-text-gray-700 hover:tw-text-blue-600"})]}));var tl=(e=>(e[e.Check=0]="Check",e[e.Radio=1]="Radio",e))(tl||{});function jm({id:e,groups:t}){return a.jsx("div",{id:e,children:a.jsxs(or,{children:[a.jsx(lo,{asChild:!0,children:a.jsx(el,{})}),a.jsx(En,{children:t.map(n=>a.jsxs("div",{children:[a.jsx(Wt,{children:n.label}),a.jsx(cs,{children:n.items.map(r=>a.jsx("div",{children:r.itemType===0?a.jsx(ar,{onClick:r.onClick,children:r.label}):a.jsx(uo,{onClick:r.onClick,value:r.label,children:r.label})},r.label))}),a.jsx(jn,{})]},n.label))})]})})}function Cm({id:e,message:t}){return a.jsx("div",{id:e,className:"tw-mb-20 tw-mt-20 tw-flex tw-items-center tw-justify-center",children:a.jsx("div",{className:"tw-w-3/4 tw-rounded-lg tw-bg-gray-100 tw-p-8 tw-text-center",children:a.jsx("p",{className:"tw-text-lg tw-text-gray-800",children:t})})})}function Tm({id:e,category:t,downloads:n,languages:r,moreInfoUrl:o}){const s=new W.NumberFormat("en",{notation:"compact",compactDisplay:"short"}).format(Object.values(n).reduce((l,c)=>l+c,0)),i=()=>{window.scrollTo(0,document.body.scrollHeight)};return a.jsxs("div",{id:e,className:"tw-flex tw-flex-wrap tw-items-start tw-space-x-4 tw-border-b tw-border-t tw-bg-white tw-pb-4 tw-pt-4",children:[a.jsxs("div",{className:"tw-flex tw-flex-col tw-items-center",children:[a.jsx("div",{className:"tw-flex tw-items-center tw-rounded-md tw-bg-gray-100 tw-px-2 tw-py-1",children:a.jsx("span",{className:"tw-text-xs tw-font-semibold tw-text-gray-700",children:t})}),a.jsx("span",{className:"tw-text-xs tw-text-gray-500",children:"CATEGORY"})]}),a.jsx("div",{className:"tw-mx-2 tw-h-10 tw-border-l tw-border-gray-300"}),a.jsxs("div",{className:"tw-flex tw-flex-col tw-items-center",children:[a.jsxs("div",{className:"tw-flex tw-items-center tw-rounded-md tw-bg-gray-100 tw-px-2 tw-py-1",children:[a.jsx(Q.User,{className:"tw-mr-1 tw-h-4 tw-w-4"}),a.jsx("span",{className:"tw-text-xs tw-font-semibold tw-text-gray-700",children:s})]}),a.jsx("span",{className:"tw-text-xs tw-text-gray-500",children:"USERS"})]}),a.jsx("div",{className:"tw-mx-2 tw-h-10 tw-border-l tw-border-gray-300"}),a.jsxs("div",{className:"tw-flex tw-flex-col tw-items-center",children:[a.jsx("div",{className:"tw-flex tw-items-center",children:r.slice(0,3).map(l=>a.jsx("span",{className:"tw-ml-1 tw-rounded-md tw-bg-gray-100 tw-px-2 tw-py-1 tw-text-xs tw-font-semibold tw-text-gray-700",children:l.toUpperCase()},l))}),r.length>3&&a.jsxs("button",{type:"button",onClick:()=>i(),className:"tw-text-xs tw-text-gray-500 tw-underline",children:["+",r.length-3," more languages"]})]}),a.jsx("div",{className:"tw-mx-2 tw-h-10 tw-border-l tw-border-gray-300"}),a.jsxs("div",{className:"tw-ml-auto tw-flex tw-flex-col tw-space-y-2",children:[a.jsxs("a",{href:o,target:"_blank",rel:"noreferrer",className:"tw-flex tw-items-center tw-text-xs tw-font-semibold tw-text-gray-500 tw-underline",children:["Website",a.jsx(Q.Link,{className:"tw-ml-1 tw-inline tw-h-4 tw-w-4"})]}),a.jsxs("a",{href:"https://example.com",target:"_blank",rel:"noreferrer",className:"tw-flex tw-items-center tw-text-xs tw-font-semibold tw-text-gray-500 tw-underline",children:["Support",a.jsx(Q.CircleHelp,{className:"tw-ml-1 tw-inline tw-h-4 tw-w-4"})]})]})]})}function nl({id:e,versionHistory:t}){const[n,r]=g.useState(!1),o=new Date;function s(l){const c=new Date(l),u=new Date(o.getTime()-c.getTime()),d=u.getUTCFullYear()-1970,m=u.getUTCMonth(),w=u.getUTCDate()-1;let b="";return d>0?b=`${d.toString()} year${d===1?"":"s"} ago`:m>0?b=`${m.toString()} month${m===1?"":"s"} ago`:w===0?b="today":b=`${w.toString()} day${w===1?"":"s"} ago`,b}const i=Object.entries(t).sort((l,c)=>c[0].localeCompare(l[0]));return a.jsxs("div",{id:e,children:[a.jsx("h3",{className:"tw-text-md tw-font-semibold",children:"What`s New"}),a.jsx("ul",{className:"tw-list-disc tw-pl-5 tw-pr-4 tw-text-xs tw-text-gray-600",children:(n?i:i.slice(0,5)).map(l=>a.jsxs("div",{className:"tw-mt-3 tw-flex tw-justify-between",children:[a.jsx("div",{className:"tw-text-gray-600",children:a.jsx("li",{className:"tw-prose tw-text-xs",children:a.jsx("span",{children:l[1].description})})}),a.jsxs("div",{className:"tw-justify-end tw-text-right",children:[a.jsxs("div",{children:["Version ",l[0]]}),a.jsx("div",{children:s(l[1].date)})]})]},l[0]))}),i.length>5&&a.jsx("button",{type:"button",onClick:()=>r(!n),className:"tw-text-xs tw-text-gray-500 tw-underline",children:n?"Show Less Version History":"Show All Version History"})]})}function Rm({id:e,publisherDisplayName:t,fileSize:n,locales:r,versionHistory:o}){const s=g.useMemo(()=>W.formatBytes(n),[n]),l=(c=>{const u=new Intl.DisplayNames(navigator.language,{type:"language"});return c.map(d=>u.of(d))})(r);return a.jsx("div",{id:e,className:"tw-border-t tw-pb-4 tw-pt-4",children:a.jsxs("div",{className:"tw-md:flex-row tw-md:space-x-8 tw-flex tw-flex-col tw-space-x-0",children:[a.jsx(nl,{versionHistory:o}),a.jsx("div",{className:"tw-md:border-t-0 tw-md:border-l tw-md-h-auto tw-md-ml-8 tw-mt-4 tw-border-t tw-border-gray-300"}),a.jsxs("div",{className:"tw-md:mt-0 tw-mt-4 tw-flex-1 tw-space-y-3",children:[a.jsx("h2",{className:"tw-text-md tw-font-semibold",children:"Information"}),a.jsxs("div",{className:"tw-flex tw-items-start tw-justify-between tw-pr-4 tw-text-xs tw-text-gray-600",children:[a.jsxs("p",{className:"tw-flex tw-flex-col tw-justify-start",children:[a.jsx("span",{className:"tw-mb-2",children:"Publisher"}),a.jsx("span",{className:"tw-font-semibold",children:t}),a.jsx("span",{className:"tw-mb-2 tw-mt-4",children:"Size"}),a.jsx("span",{className:"tw-font-semibold",children:s})]}),a.jsx("div",{className:"tw-flex tw-w-3/4 tw-items-center tw-justify-between tw-text-xs tw-text-gray-600",children:a.jsxs("p",{className:"tw-flex tw-flex-col tw-justify-start",children:[a.jsx("span",{className:"tw-mb-2",children:"Languages"}),a.jsx("span",{className:"tw-font-semibold",children:l.join(", ")})]})})]})]})]})})}const Om=(e,t)=>{g.useEffect(()=>{if(!e)return()=>{};const n=e(t);return()=>{n()}},[e,t])},Fr=()=>!1,_m=(e,t)=>{const[n]=nr(g.useCallback(async()=>{if(!e)return Fr;const r=await Promise.resolve(e(t));return async()=>r()},[t,e]),Fr,{preserveValue:!1});g.useEffect(()=>()=>{n!==Fr&&n()},[n])};Object.defineProperty(exports,"sonner",{enumerable:!0,get:()=>Qa.toast});exports.Alert=zi;exports.AlertDescription=Fi;exports.AlertTitle=Li;exports.BOOK_SELECTOR_STRING_KEYS=mc;exports.BookChapterControl=oc;exports.BookSelectionMode=Ns;exports.BookSelector=hc;exports.Button=fe;exports.Card=Gi;exports.CardContent=Xi;exports.CardDescription=Hi;exports.CardFooter=Yi;exports.CardHeader=Ui;exports.CardTitle=qi;exports.ChapterRangeSelector=ys;exports.Checkbox=sr;exports.Checklist=bd;exports.ComboBox=Wn;exports.DataTable=Ts;exports.DisableButton=km;exports.DropdownMenu=or;exports.DropdownMenuCheckboxItem=ar;exports.DropdownMenuContent=En;exports.DropdownMenuGroup=cs;exports.DropdownMenuItem=co;exports.DropdownMenuItemType=tl;exports.DropdownMenuLabel=Wt;exports.DropdownMenuPortal=ql;exports.DropdownMenuRadioGroup=Xl;exports.DropdownMenuRadioItem=uo;exports.DropdownMenuSeparator=jn;exports.DropdownMenuShortcut=ps;exports.DropdownMenuSub=Hl;exports.DropdownMenuSubContent=us;exports.DropdownMenuSubTrigger=ds;exports.DropdownMenuTrigger=lo;exports.EnableButton=Nm;exports.FilterButton=el;exports.FilterDropdown=jm;exports.Footer=Rm;exports.GridMenu=Bi;exports.HamburgerMenuButton=Vi;exports.INVENTORY_STRING_KEYS=Ec;exports.IconButton=mm;exports.Input=St;exports.InstallButton=ym;exports.Inventory=Tc;exports.Label=qe;exports.MarkdownRenderer=Em;exports.MenuItem=Fo;exports.MoreInfo=Tm;exports.NavigationContentSearch=Rc;exports.NoExtensionsFound=Cm;exports.RadioGroup=po;exports.RadioGroupItem=Yn;exports.ScriptureResultsViewer=wd;exports.ScrollGroupSelector=fd;exports.SearchBar=ho;exports.Select=At;exports.SelectContent=vt;exports.SelectGroup=ks;exports.SelectItem=Ae;exports.SelectLabel=Ss;exports.SelectScrollDownButton=fo;exports.SelectScrollUpButton=wo;exports.SelectSeparator=Es;exports.SelectTrigger=bt;exports.SelectValue=Bt;exports.Separator=lr;exports.SettingsList=md;exports.SettingsListHeader=gd;exports.SettingsListItem=hd;exports.SettingsSidebar=Hs;exports.SettingsSidebarContentSearch=ad;exports.Slider=Wi;exports.Sonner=vm;exports.Spinner=Kt;exports.Switch=Ki;exports.Table=Cn;exports.TableBody=Rn;exports.TableCaption=Cs;exports.TableCell=xt;exports.TableFooter=js;exports.TableHead=Vt;exports.TableHeader=Tn;exports.TableRow=Ze;exports.Tabs=xm;exports.TabsContent=Qi;exports.TabsList=Ji;exports.TabsTrigger=Zi;exports.TextField=hm;exports.ToggleGroup=mo;exports.ToggleGroupItem=fn;exports.Toolbar=gm;exports.UpdateButton=Sm;exports.VersionHistory=nl;exports.VerticalTabs=go;exports.VerticalTabsContent=vo;exports.VerticalTabsList=bo;exports.VerticalTabsTrigger=Ms;exports.buttonVariants=ws;exports.cn=N;exports.getBookNumFromId=Os;exports.getLinesFromUSFM=Rs;exports.getNumberFromUSFM=Hr;exports.getStatusForItem=_s;exports.inventoryCountColumn=kc;exports.inventoryItemColumn=yc;exports.inventoryStatusColumn=Sc;exports.useEvent=Om;exports.useEventAsync=_m;exports.usePromise=nr;function Pm(e,t="top"){if(!e||typeof document>"u")return;const n=document.head||document.querySelector("head"),r=n.querySelector(":first-child"),o=document.createElement("style");o.appendChild(document.createTextNode(e)),t==="top"&&r?n.insertBefore(o,r):n.appendChild(o)}Pm(`*, ::before, ::after { --tw-border-spacing-x: 0; --tw-border-spacing-y: 0; --tw-translate-x: 0; @@ -3593,6 +3593,32 @@ video:where(.pr-twp,.pr-twp *) { .banded-row[data-state='selected']:hover { cursor: default; } +.papi-icon-button { + border: 0; + border-radius: 3em; + cursor: pointer; + display: inline-block; +} + +.papi-icon-button.primary { + background-color: #1ea7fd; + color: white; +} + +.papi-icon-button.secondary { + background-color: transparent; + color: #333; +} + +.papi-icon-button.paratext { + background-color: darkgreen; + color: greenyellow; +} + +.papi-icon-button.paratext.bright { + background-color: greenyellow; + color: darkgreen; +} .papi-multi-column-menu { background-color: rgb(222, 222, 222); display: flex; @@ -3640,32 +3666,6 @@ video:where(.pr-twp,.pr-twp *) { max-width: 24px; max-height: 24px; } -.papi-icon-button { - border: 0; - border-radius: 3em; - cursor: pointer; - display: inline-block; -} - -.papi-icon-button.primary { - background-color: #1ea7fd; - color: white; -} - -.papi-icon-button.secondary { - background-color: transparent; - color: #333; -} - -.papi-icon-button.paratext { - background-color: darkgreen; - color: greenyellow; -} - -.papi-icon-button.paratext.bright { - background-color: greenyellow; - color: darkgreen; -} .papi-menu-drawer-paper { height: fit-content !important; position: absolute !important; diff --git a/lib/platform-bible-react/dist/index.cjs.map b/lib/platform-bible-react/dist/index.cjs.map index 75c874e8f7..dfd802cd06 100644 --- a/lib/platform-bible-react/dist/index.cjs.map +++ b/lib/platform-bible-react/dist/index.cjs.map @@ -1 +1 @@ -{"version":3,"file":"index.cjs","sources":["../src/utils/shadcn-ui.util.ts","../src/components/shadcn-ui/input.tsx","../src/components/advanced/book-chapter-control/book-chapter-input.component.tsx","../../../node_modules/@sillsdev/scripture/dist/index.es.js","../src/components/shadcn-ui/dropdown-menu.tsx","../src/components/advanced/book-chapter-control/book-menu-item.component.tsx","../src/components/advanced/book-chapter-control/chapter-select.component.tsx","../src/components/advanced/book-chapter-control/go-to-menu-item.component.tsx","../src/components/advanced/book-chapter-control/book-chapter-control.component.tsx","../src/components/shadcn-ui/button.tsx","../src/components/shadcn-ui/label.tsx","../src/components/shadcn-ui/radio-group.tsx","../src/components/shadcn-ui/popover.tsx","../src/components/shadcn-ui/dialog.tsx","../src/components/shadcn-ui/command.tsx","../src/components/basics/combo-box.component.tsx","../src/components/basics/chapter-range-selector.component.tsx","../src/components/advanced/book-selector.component.tsx","../src/components/advanced/data-table/data-table-column-toggle.component.tsx","../src/components/shadcn-ui/select.tsx","../src/components/advanced/data-table/data-table-pagination.component.tsx","../src/components/shadcn-ui/table.tsx","../src/components/advanced/data-table/data-table.component.tsx","../src/components/advanced/inventory/occurrences-table.component.tsx","../src/components/shadcn-ui/checkbox.tsx","../src/components/advanced/inventory/inventory-utils.ts","../src/components/shadcn-ui/toggle.tsx","../src/components/shadcn-ui/toggle-group.tsx","../src/components/advanced/inventory/inventory-columns.tsx","../src/components/advanced/inventory/inventory.component.tsx","../src/components/basics/search-bar.component.tsx","../src/components/basics/tabs-vertical.tsx","../src/components/advanced/tab-navigation-content-search.component.tsx","../src/components/shadcn-ui/separator.tsx","../src/components/shadcn-ui/sheet.tsx","../src/components/shadcn-ui/skeleton.tsx","../src/components/shadcn-ui/tooltip.tsx","../src/components/hooks/use-mobile.tsx","../src/components/shadcn-ui/sidebar.tsx","../src/components/advanced/settings-components/settings-sidebar.component.tsx","../src/components/advanced/settings-components/settings-sidebar-content-search.component.tsx","../src/components/advanced/scripture-results-viewer/scripture-results-viewer.component.tsx","../src/components/advanced/scroll-group-selector.component.tsx","../src/components/advanced/settings-components/settings-list.component.tsx","../src/components/basics/checklist.component.tsx","../../../node_modules/@babel/runtime/helpers/interopRequireDefault.js","../../../node_modules/@mui/utils/chainPropTypes/chainPropTypes.js","../../../node_modules/@babel/runtime/helpers/esm/extends.js","../../../node_modules/@mui/utils/deepmerge/deepmerge.js","../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.production.min.js","../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.development.js","../../../node_modules/prop-types/node_modules/react-is/index.js","../../../node_modules/object-assign/index.js","../../../node_modules/prop-types/lib/ReactPropTypesSecret.js","../../../node_modules/prop-types/lib/has.js","../../../node_modules/prop-types/checkPropTypes.js","../../../node_modules/prop-types/factoryWithTypeCheckers.js","../../../node_modules/prop-types/factoryWithThrowingShims.js","../../../node_modules/prop-types/index.js","../../../node_modules/@mui/utils/elementAcceptingRef/elementAcceptingRef.js","../../../node_modules/@mui/utils/exactProp/exactProp.js","../../../node_modules/@mui/utils/formatMuiErrorMessage/formatMuiErrorMessage.js","../../../node_modules/react-is/cjs/react-is.production.min.js","../../../node_modules/react-is/cjs/react-is.development.js","../../../node_modules/react-is/index.js","../../../node_modules/@mui/utils/getDisplayName/getDisplayName.js","../../../node_modules/@mui/utils/HTMLElementType/HTMLElementType.js","../../../node_modules/@mui/utils/refType/refType.js","../../../node_modules/@mui/utils/capitalize/capitalize.js","../../../node_modules/@mui/utils/createChainedFunction/createChainedFunction.js","../../../node_modules/@mui/utils/debounce/debounce.js","../../../node_modules/@mui/utils/deprecatedPropType/deprecatedPropType.js","../../../node_modules/@mui/utils/isMuiElement/isMuiElement.js","../../../node_modules/@mui/utils/ownerDocument/ownerDocument.js","../../../node_modules/@mui/utils/ownerWindow/ownerWindow.js","../../../node_modules/@mui/utils/requirePropFactory/requirePropFactory.js","../../../node_modules/@mui/utils/setRef/setRef.js","../../../node_modules/@mui/utils/useEnhancedEffect/useEnhancedEffect.js","../../../node_modules/@mui/utils/useId/useId.js","../../../node_modules/@mui/utils/unsupportedProp/unsupportedProp.js","../../../node_modules/@mui/utils/useControlled/useControlled.js","../../../node_modules/@mui/utils/useEventCallback/useEventCallback.js","../../../node_modules/@mui/utils/useForkRef/useForkRef.js","../../../node_modules/@mui/utils/useLazyRef/useLazyRef.js","../../../node_modules/@mui/utils/useOnMount/useOnMount.js","../../../node_modules/@mui/utils/useTimeout/useTimeout.js","../../../node_modules/@mui/utils/useIsFocusVisible/useIsFocusVisible.js","../../../node_modules/@mui/utils/resolveProps/resolveProps.js","../../../node_modules/@mui/utils/composeClasses/composeClasses.js","../../../node_modules/@mui/utils/ClassNameGenerator/ClassNameGenerator.js","../../../node_modules/@mui/utils/generateUtilityClass/generateUtilityClass.js","../../../node_modules/@mui/utils/generateUtilityClasses/generateUtilityClasses.js","../../../node_modules/@mui/utils/clamp/clamp.js","../../../node_modules/@babel/runtime/helpers/esm/objectWithoutPropertiesLoose.js","../../../node_modules/@mui/system/esm/createTheme/createBreakpoints.js","../../../node_modules/@mui/system/esm/createTheme/shape.js","../../../node_modules/@mui/system/esm/responsivePropType.js","../../../node_modules/@mui/system/esm/merge.js","../../../node_modules/@mui/system/esm/breakpoints.js","../../../node_modules/@mui/system/esm/style.js","../../../node_modules/@mui/system/esm/memoize.js","../../../node_modules/@mui/system/esm/spacing.js","../../../node_modules/@mui/system/esm/createTheme/createSpacing.js","../../../node_modules/@mui/system/esm/compose.js","../../../node_modules/@mui/system/esm/borders.js","../../../node_modules/@mui/system/esm/cssGrid.js","../../../node_modules/@mui/system/esm/palette.js","../../../node_modules/@mui/system/esm/sizing.js","../../../node_modules/@mui/system/esm/styleFunctionSx/defaultSxConfig.js","../../../node_modules/@mui/system/esm/styleFunctionSx/styleFunctionSx.js","../../../node_modules/@mui/system/esm/createTheme/applyStyles.js","../../../node_modules/@mui/system/esm/createTheme/createTheme.js","../../../node_modules/@mui/system/esm/useThemeWithoutDefault.js","../../../node_modules/@mui/system/esm/useTheme.js","../../../node_modules/@mui/system/esm/createStyled.js","../../../node_modules/@mui/system/esm/useThemeProps/getThemeProps.js","../../../node_modules/@mui/system/esm/useThemeProps/useThemeProps.js","../../../node_modules/@mui/system/esm/colorManipulator.js","../../../node_modules/@mui/material/styles/createMixins.js","../../../node_modules/@mui/material/colors/common.js","../../../node_modules/@mui/material/colors/grey.js","../../../node_modules/@mui/material/colors/purple.js","../../../node_modules/@mui/material/colors/red.js","../../../node_modules/@mui/material/colors/orange.js","../../../node_modules/@mui/material/colors/blue.js","../../../node_modules/@mui/material/colors/lightBlue.js","../../../node_modules/@mui/material/colors/green.js","../../../node_modules/@mui/material/styles/createPalette.js","../../../node_modules/@mui/material/styles/createTypography.js","../../../node_modules/@mui/material/styles/shadows.js","../../../node_modules/@mui/material/styles/createTransitions.js","../../../node_modules/@mui/material/styles/zIndex.js","../../../node_modules/@mui/material/styles/createTheme.js","../../../node_modules/@mui/material/styles/defaultTheme.js","../../../node_modules/@mui/material/styles/identifier.js","../../../node_modules/@mui/material/styles/useThemeProps.js","../../../node_modules/@mui/material/styles/styled.js","../../../node_modules/@mui/material/SvgIcon/svgIconClasses.js","../../../node_modules/@mui/material/SvgIcon/SvgIcon.js","../../../node_modules/@mui/material/utils/createSvgIcon.js","../../../node_modules/@mui/material/utils/index.js","../../../node_modules/@mui/icons-material/utils/createSvgIcon.js","../../../node_modules/@mui/icons-material/ArrowRight.js","../../../node_modules/@mui/base/utils/isHostComponent.js","../../../node_modules/@mui/base/utils/appendOwnerState.js","../../../node_modules/@mui/base/utils/ClassNameConfigurator.js","../../../node_modules/@mui/base/utils/extractEventHandlers.js","../../../node_modules/@mui/base/utils/resolveComponentProps.js","../../../node_modules/@mui/base/utils/omitEventHandlers.js","../../../node_modules/@mui/base/utils/mergeSlotProps.js","../../../node_modules/@mui/base/utils/useSlotProps.js","../../../node_modules/@mui/base/generateUtilityClass/index.js","../../../node_modules/@mui/base/generateUtilityClasses/index.js","../../../node_modules/@mui/base/Portal/Portal.js","../../../node_modules/@popperjs/core/lib/enums.js","../../../node_modules/@popperjs/core/lib/dom-utils/getNodeName.js","../../../node_modules/@popperjs/core/lib/dom-utils/getWindow.js","../../../node_modules/@popperjs/core/lib/dom-utils/instanceOf.js","../../../node_modules/@popperjs/core/lib/modifiers/applyStyles.js","../../../node_modules/@popperjs/core/lib/utils/getBasePlacement.js","../../../node_modules/@popperjs/core/lib/utils/math.js","../../../node_modules/@popperjs/core/lib/utils/userAgent.js","../../../node_modules/@popperjs/core/lib/dom-utils/isLayoutViewport.js","../../../node_modules/@popperjs/core/lib/dom-utils/getBoundingClientRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/getLayoutRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/contains.js","../../../node_modules/@popperjs/core/lib/dom-utils/getComputedStyle.js","../../../node_modules/@popperjs/core/lib/dom-utils/isTableElement.js","../../../node_modules/@popperjs/core/lib/dom-utils/getDocumentElement.js","../../../node_modules/@popperjs/core/lib/dom-utils/getParentNode.js","../../../node_modules/@popperjs/core/lib/dom-utils/getOffsetParent.js","../../../node_modules/@popperjs/core/lib/utils/getMainAxisFromPlacement.js","../../../node_modules/@popperjs/core/lib/utils/within.js","../../../node_modules/@popperjs/core/lib/utils/getFreshSideObject.js","../../../node_modules/@popperjs/core/lib/utils/mergePaddingObject.js","../../../node_modules/@popperjs/core/lib/utils/expandToHashMap.js","../../../node_modules/@popperjs/core/lib/modifiers/arrow.js","../../../node_modules/@popperjs/core/lib/utils/getVariation.js","../../../node_modules/@popperjs/core/lib/modifiers/computeStyles.js","../../../node_modules/@popperjs/core/lib/modifiers/eventListeners.js","../../../node_modules/@popperjs/core/lib/utils/getOppositePlacement.js","../../../node_modules/@popperjs/core/lib/utils/getOppositeVariationPlacement.js","../../../node_modules/@popperjs/core/lib/dom-utils/getWindowScroll.js","../../../node_modules/@popperjs/core/lib/dom-utils/getWindowScrollBarX.js","../../../node_modules/@popperjs/core/lib/dom-utils/getViewportRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/getDocumentRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/isScrollParent.js","../../../node_modules/@popperjs/core/lib/dom-utils/getScrollParent.js","../../../node_modules/@popperjs/core/lib/dom-utils/listScrollParents.js","../../../node_modules/@popperjs/core/lib/utils/rectToClientRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/getClippingRect.js","../../../node_modules/@popperjs/core/lib/utils/computeOffsets.js","../../../node_modules/@popperjs/core/lib/utils/detectOverflow.js","../../../node_modules/@popperjs/core/lib/utils/computeAutoPlacement.js","../../../node_modules/@popperjs/core/lib/modifiers/flip.js","../../../node_modules/@popperjs/core/lib/modifiers/hide.js","../../../node_modules/@popperjs/core/lib/modifiers/offset.js","../../../node_modules/@popperjs/core/lib/modifiers/popperOffsets.js","../../../node_modules/@popperjs/core/lib/utils/getAltAxis.js","../../../node_modules/@popperjs/core/lib/modifiers/preventOverflow.js","../../../node_modules/@popperjs/core/lib/dom-utils/getHTMLElementScroll.js","../../../node_modules/@popperjs/core/lib/dom-utils/getNodeScroll.js","../../../node_modules/@popperjs/core/lib/dom-utils/getCompositeRect.js","../../../node_modules/@popperjs/core/lib/utils/orderModifiers.js","../../../node_modules/@popperjs/core/lib/utils/debounce.js","../../../node_modules/@popperjs/core/lib/utils/mergeByName.js","../../../node_modules/@popperjs/core/lib/createPopper.js","../../../node_modules/@popperjs/core/lib/popper.js","../../../node_modules/@mui/base/Popper/popperClasses.js","../../../node_modules/@mui/base/Popper/Popper.js","../../../node_modules/@mui/material/styles/useTheme.js","../../../node_modules/@babel/runtime/helpers/esm/setPrototypeOf.js","../../../node_modules/@babel/runtime/helpers/esm/inheritsLoose.js","../../../node_modules/react-transition-group/esm/config.js","../../../node_modules/react-transition-group/esm/utils/PropTypes.js","../../../node_modules/react-transition-group/esm/TransitionGroupContext.js","../../../node_modules/react-transition-group/esm/utils/reflow.js","../../../node_modules/react-transition-group/esm/Transition.js","../../../node_modules/@mui/material/transitions/utils.js","../../../node_modules/@mui/material/Grow/Grow.js","../../../node_modules/@mui/material/Popper/Popper.js","../../../node_modules/@mui/material/Tooltip/tooltipClasses.js","../../../node_modules/@mui/material/Tooltip/Tooltip.js","../src/components/mui/menu-item.component.tsx","../src/components/mui/grouped-menu-item-list.component.tsx","../src/components/mui/top-level-menu.component.tsx","../src/components/mui/grid-menu.component.tsx","../src/hooks/use-promise.hook.ts","../../../node_modules/@mui/icons-material/esm/Menu.js","../src/components/mui/hamburger-menu-button.component.tsx","../src/components/mui/icon-button.component.tsx","../src/components/basics/spinner.component.tsx","../src/components/basics/text-field.component.tsx","../src/components/mui/toolbar.component.tsx","../src/components/shadcn-ui/alert.tsx","../src/components/shadcn-ui/card.tsx","../src/components/shadcn-ui/sonner.tsx","../src/components/shadcn-ui/slider.tsx","../src/components/shadcn-ui/switch.tsx","../src/components/shadcn-ui/tabs.tsx","../src/components/advanced/extension-marketplace/buttons/install-button.component.tsx","../src/components/advanced/extension-marketplace/buttons/enable-button.component.tsx","../src/components/advanced/extension-marketplace/buttons/disable-button.component.tsx","../src/components/advanced/extension-marketplace/buttons/update-button.component.tsx","../src/components/advanced/extension-marketplace/markdown-renderer.component.tsx","../src/components/advanced/extension-marketplace/buttons/filter-button.component.tsx","../src/components/advanced/extension-marketplace/filter-dropdown.component.tsx","../src/components/advanced/extension-marketplace/no-extensions-found.component.tsx","../src/components/advanced/extension-marketplace/more-info.component.tsx","../src/components/advanced/extension-marketplace/version-history.component.tsx","../src/components/advanced/extension-marketplace/footer.component.tsx","../src/hooks/use-event.hook.ts","../src/hooks/use-event-async.hook.ts"],"sourcesContent":["import { type ClassValue, clsx } from 'clsx';\nimport { extendTailwindMerge } from 'tailwind-merge';\n\nconst twMergeCustom = extendTailwindMerge({ prefix: 'tw-' });\n\n/**\n * Tailwind and CSS class application helper function. Uses\n * [`clsx`](https://www.npmjs.com/package/clsx) to make it easy to apply classes conditionally using\n * object syntax, and uses [`tailwind-merge`](https://www.npmjs.com/package/tailwind-merge) to make\n * it easy to merge/overwrite Tailwind classes in a programmer-logic-friendly way.\n *\n * Note: `tailwind-merge` is configured to use the prefix `tw-`, so you must use the same prefix\n * with any Tailwind classes you use with this function to successfully overwrite other Tailwind\n * classes. `platform-bible-react` is configured to use `tw-` as its Tailwind prefix, so any\n * Tailwind classes you pass into `platform-bible-react` components will be compared using the `tw-`\n * prefix.\n *\n * This function was popularized by\n * [shadcn/ui](https://ui.shadcn.com/docs/installation/manual#add-a-cn-helper). See [ByteGrad's\n * explanation video](https://www.youtube.com/watch?v=re2JFITR7TI) for more information.\n *\n * @example\n *\n * ```typescript\n * const borderShouldBeBlue = true;\n * const textShouldBeRed = true;\n * const heightShouldBe20 = false;\n * const classString = cn(\n * 'tw-bg-primary tw-h-10 tw-text-primary-foreground',\n * 'tw-bg-secondary',\n * {\n * 'tw-border-blue-500': borderShouldBeBlue,\n * 'tw-text-red-500': textShouldBeRed,\n * 'tw-h-20': heightShouldBe20,\n * },\n * 'some-class',\n * );\n * ```\n *\n * The resulting `classString` is `'tw-h-10 tw-bg-secondary tw-border-blue-500 tw-text-red-500\n * some-class'`\n *\n * - Notice that `'tw-bg-secondary'`, specified later, overwrote `'tw-bg-primary'`, specified earlier,\n * because they are Tailwind classes that affect the same css property\n * - Notice that `'tw-text-red-500'`, specified later, overwrote `'tw-text-primary-foreground'`,\n * specified earlier, because they are Tailwind classes that affect the same css property\n * - Notice that `'tw-h-20'`, specified later, did not overwrite `'tw-h-10'`, specified earlier,\n * because `'tw-h-20'` is part of a conditional class object and its value evaluated to `false`;\n * therefore it was not applied\n * - Notice that `'some-class'` was applied. This function is not limited only to Tailwind classes.\n *\n *\n * @param inputs Class strings or `clsx` conditional class objects to merge. Tailwind classes\n * specified later in the arguments overwrite similar Tailwind classes specified earlier in the\n * arguments\n * @returns Class string containing all applicable classes from the arguments based on the rules\n * described above\n */\n// shadcn/ui uses this export in its boilerplate code\n// eslint-disable-next-line import/prefer-default-export\nexport function cn(...inputs: ClassValue[]) {\n return twMergeCustom(clsx(inputs));\n}\n","import React from 'react';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport interface InputProps extends React.InputHTMLAttributes {}\n\nexport const Input = React.forwardRef(\n ({ className, type, ...props }, ref) => {\n return (\n \n );\n },\n);\nInput.displayName = 'Input';\n","import { FocusEventHandler, forwardRef, KeyboardEvent, MouseEventHandler } from 'react';\nimport { History } from 'lucide-react';\nimport { Input as ShadInput } from '@/components/shadcn-ui/input';\n\nexport type BookChapterInputProps = {\n handleSearch: (searchString: string) => void;\n handleKeyDown: (event: KeyboardEvent) => void;\n handleOnClick: MouseEventHandler;\n handleSubmit: () => void;\n onFocus?: FocusEventHandler;\n value: string;\n placeholder: string;\n};\n\n// Shadcn Input sets type to \"button\"- HAVE to prop spread before setting type\nconst BookChapterInput = forwardRef(\n (\n { handleSearch, handleKeyDown, handleOnClick, handleSubmit, ...props }: BookChapterInputProps,\n ref,\n ) => {\n return (\n
    \n handleSearch(event.target.value)}\n onKeyDown={(e) => {\n if (e.key === 'Enter') {\n handleSubmit();\n }\n handleKeyDown(e);\n }}\n onClick={handleOnClick}\n ref={ref}\n />\n {\n // eslint-disable-next-line no-console\n console.log('back in history');\n }}\n />\n
    \n );\n },\n);\n\nexport default BookChapterInput;\n","var P = Object.defineProperty;\nvar R = (t, e, s) => e in t ? P(t, e, { enumerable: !0, configurable: !0, writable: !0, value: s }) : t[e] = s;\nvar n = (t, e, s) => R(t, typeof e != \"symbol\" ? e + \"\" : e, s);\nclass _ {\n constructor() {\n n(this, \"books\");\n n(this, \"firstSelectedBookNum\");\n n(this, \"lastSelectedBookNum\");\n n(this, \"count\");\n n(this, \"selectedBookNumbers\");\n n(this, \"selectedBookIds\");\n }\n}\nconst N = [\n \"GEN\",\n \"EXO\",\n \"LEV\",\n \"NUM\",\n \"DEU\",\n \"JOS\",\n \"JDG\",\n \"RUT\",\n \"1SA\",\n \"2SA\",\n // 10\n \"1KI\",\n \"2KI\",\n \"1CH\",\n \"2CH\",\n \"EZR\",\n \"NEH\",\n \"EST\",\n \"JOB\",\n \"PSA\",\n \"PRO\",\n // 20\n \"ECC\",\n \"SNG\",\n \"ISA\",\n \"JER\",\n \"LAM\",\n \"EZK\",\n \"DAN\",\n \"HOS\",\n \"JOL\",\n \"AMO\",\n // 30\n \"OBA\",\n \"JON\",\n \"MIC\",\n \"NAM\",\n \"HAB\",\n \"ZEP\",\n \"HAG\",\n \"ZEC\",\n \"MAL\",\n \"MAT\",\n // 40\n \"MRK\",\n \"LUK\",\n \"JHN\",\n \"ACT\",\n \"ROM\",\n \"1CO\",\n \"2CO\",\n \"GAL\",\n \"EPH\",\n \"PHP\",\n // 50\n \"COL\",\n \"1TH\",\n \"2TH\",\n \"1TI\",\n \"2TI\",\n \"TIT\",\n \"PHM\",\n \"HEB\",\n \"JAS\",\n \"1PE\",\n // 60\n \"2PE\",\n \"1JN\",\n \"2JN\",\n \"3JN\",\n \"JUD\",\n \"REV\",\n \"TOB\",\n \"JDT\",\n \"ESG\",\n \"WIS\",\n // 70\n \"SIR\",\n \"BAR\",\n \"LJE\",\n \"S3Y\",\n \"SUS\",\n \"BEL\",\n \"1MA\",\n \"2MA\",\n \"3MA\",\n \"4MA\",\n // 80\n \"1ES\",\n \"2ES\",\n \"MAN\",\n \"PS2\",\n \"ODA\",\n \"PSS\",\n \"JSA\",\n // actual variant text for JOS, now in LXA text\n \"JDB\",\n // actual variant text for JDG, now in LXA text\n \"TBS\",\n // actual variant text for TOB, now in LXA text\n \"SST\",\n // actual variant text for SUS, now in LXA text // 90\n \"DNT\",\n // actual variant text for DAN, now in LXA text\n \"BLT\",\n // actual variant text for BEL, now in LXA text\n \"XXA\",\n \"XXB\",\n \"XXC\",\n \"XXD\",\n \"XXE\",\n \"XXF\",\n \"XXG\",\n \"FRT\",\n // 100\n \"BAK\",\n \"OTH\",\n \"3ES\",\n // Used previously but really should be 2ES\n \"EZA\",\n // Used to be called 4ES, but not actually in any known project\n \"5EZ\",\n // Used to be called 5ES, but not actually in any known project\n \"6EZ\",\n // Used to be called 6ES, but not actually in any known project\n \"INT\",\n \"CNC\",\n \"GLO\",\n \"TDX\",\n // 110\n \"NDX\",\n \"DAG\",\n \"PS3\",\n \"2BA\",\n \"LBA\",\n \"JUB\",\n \"ENO\",\n \"1MQ\",\n \"2MQ\",\n \"3MQ\",\n // 120\n \"REP\",\n \"4BA\",\n \"LAO\"\n], B = [\n \"XXA\",\n \"XXB\",\n \"XXC\",\n \"XXD\",\n \"XXE\",\n \"XXF\",\n \"XXG\",\n \"FRT\",\n \"BAK\",\n \"OTH\",\n \"INT\",\n \"CNC\",\n \"GLO\",\n \"TDX\",\n \"NDX\"\n], O = [\n \"Genesis\",\n \"Exodus\",\n \"Leviticus\",\n \"Numbers\",\n \"Deuteronomy\",\n \"Joshua\",\n \"Judges\",\n \"Ruth\",\n \"1 Samuel\",\n \"2 Samuel\",\n \"1 Kings\",\n \"2 Kings\",\n \"1 Chronicles\",\n \"2 Chronicles\",\n \"Ezra\",\n \"Nehemiah\",\n \"Esther (Hebrew)\",\n \"Job\",\n \"Psalms\",\n \"Proverbs\",\n \"Ecclesiastes\",\n \"Song of Songs\",\n \"Isaiah\",\n \"Jeremiah\",\n \"Lamentations\",\n \"Ezekiel\",\n \"Daniel (Hebrew)\",\n \"Hosea\",\n \"Joel\",\n \"Amos\",\n \"Obadiah\",\n \"Jonah\",\n \"Micah\",\n \"Nahum\",\n \"Habakkuk\",\n \"Zephaniah\",\n \"Haggai\",\n \"Zechariah\",\n \"Malachi\",\n \"Matthew\",\n \"Mark\",\n \"Luke\",\n \"John\",\n \"Acts\",\n \"Romans\",\n \"1 Corinthians\",\n \"2 Corinthians\",\n \"Galatians\",\n \"Ephesians\",\n \"Philippians\",\n \"Colossians\",\n \"1 Thessalonians\",\n \"2 Thessalonians\",\n \"1 Timothy\",\n \"2 Timothy\",\n \"Titus\",\n \"Philemon\",\n \"Hebrews\",\n \"James\",\n \"1 Peter\",\n \"2 Peter\",\n \"1 John\",\n \"2 John\",\n \"3 John\",\n \"Jude\",\n \"Revelation\",\n \"Tobit\",\n \"Judith\",\n \"Esther Greek\",\n \"Wisdom of Solomon\",\n \"Sirach (Ecclesiasticus)\",\n \"Baruch\",\n \"Letter of Jeremiah\",\n \"Song of 3 Young Men\",\n \"Susanna\",\n \"Bel and the Dragon\",\n \"1 Maccabees\",\n \"2 Maccabees\",\n \"3 Maccabees\",\n \"4 Maccabees\",\n \"1 Esdras (Greek)\",\n \"2 Esdras (Latin)\",\n \"Prayer of Manasseh\",\n \"Psalm 151\",\n \"Odes\",\n \"Psalms of Solomon\",\n // WARNING, if you change the spelling of the *obsolete* tag be sure to update\n // IsObsolete routine\n \"Joshua A. *obsolete*\",\n \"Judges B. *obsolete*\",\n \"Tobit S. *obsolete*\",\n \"Susanna Th. *obsolete*\",\n \"Daniel Th. *obsolete*\",\n \"Bel Th. *obsolete*\",\n \"Extra A\",\n \"Extra B\",\n \"Extra C\",\n \"Extra D\",\n \"Extra E\",\n \"Extra F\",\n \"Extra G\",\n \"Front Matter\",\n \"Back Matter\",\n \"Other Matter\",\n \"3 Ezra *obsolete*\",\n \"Apocalypse of Ezra\",\n \"5 Ezra (Latin Prologue)\",\n \"6 Ezra (Latin Epilogue)\",\n \"Introduction\",\n \"Concordance \",\n \"Glossary \",\n \"Topical Index\",\n \"Names Index\",\n \"Daniel Greek\",\n \"Psalms 152-155\",\n \"2 Baruch (Apocalypse)\",\n \"Letter of Baruch\",\n \"Jubilees\",\n \"Enoch\",\n \"1 Meqabyan\",\n \"2 Meqabyan\",\n \"3 Meqabyan\",\n \"Reproof (Proverbs 25-31)\",\n \"4 Baruch (Rest of Baruch)\",\n \"Laodiceans\"\n], S = K();\nfunction g(t, e = !0) {\n return e && (t = t.toUpperCase()), t in S ? S[t] : 0;\n}\nfunction k(t) {\n return g(t) > 0;\n}\nfunction x(t) {\n const e = typeof t == \"string\" ? g(t) : t;\n return e >= 40 && e <= 66;\n}\nfunction T(t) {\n return (typeof t == \"string\" ? g(t) : t) <= 39;\n}\nfunction X(t) {\n return t <= 66;\n}\nfunction V(t) {\n const e = typeof t == \"string\" ? g(t) : t;\n return w(e) && !X(e);\n}\nfunction* L() {\n for (let t = 1; t <= N.length; t++) yield t;\n}\nconst G = 1, A = N.length;\nfunction H() {\n return [\"XXA\", \"XXB\", \"XXC\", \"XXD\", \"XXE\", \"XXF\", \"XXG\"];\n}\nfunction C(t, e = \"***\") {\n const s = t - 1;\n return s < 0 || s >= N.length ? e : N[s];\n}\nfunction I(t) {\n return t <= 0 || t > A ? \"******\" : O[t - 1];\n}\nfunction y(t) {\n return I(g(t));\n}\nfunction w(t) {\n const e = typeof t == \"number\" ? C(t) : t;\n return k(e) && !B.includes(e);\n}\nfunction q(t) {\n const e = typeof t == \"number\" ? C(t) : t;\n return k(e) && B.includes(e);\n}\nfunction U(t) {\n return O[t - 1].includes(\"*obsolete*\");\n}\nfunction K() {\n const t = {};\n for (let e = 0; e < N.length; e++)\n t[N[e]] = e + 1;\n return t;\n}\nconst m = {\n allBookIds: N,\n nonCanonicalIds: B,\n bookIdToNumber: g,\n isBookIdValid: k,\n isBookNT: x,\n isBookOT: T,\n isBookOTNT: X,\n isBookDC: V,\n allBookNumbers: L,\n firstBook: G,\n lastBook: A,\n extraBooks: H,\n bookNumberToId: C,\n bookNumberToEnglishName: I,\n bookIdToEnglishName: y,\n isCanonical: w,\n isExtraMaterial: q,\n isObsolete: U\n};\nvar l = /* @__PURE__ */ ((t) => (t[t.Unknown = 0] = \"Unknown\", t[t.Original = 1] = \"Original\", t[t.Septuagint = 2] = \"Septuagint\", t[t.Vulgate = 3] = \"Vulgate\", t[t.English = 4] = \"English\", t[t.RussianProtestant = 5] = \"RussianProtestant\", t[t.RussianOrthodox = 6] = \"RussianOrthodox\", t))(l || {});\nconst h = class h {\n // private versInfo: Versification;\n constructor(e) {\n n(this, \"name\");\n n(this, \"fullPath\");\n n(this, \"isPresent\");\n n(this, \"hasVerseSegments\");\n n(this, \"isCustomized\");\n n(this, \"baseVersification\");\n n(this, \"scriptureBooks\");\n n(this, \"_type\");\n if (e == null)\n throw new Error(\"Argument undefined\");\n typeof e == \"string\" ? (this.name = e, this._type = l[e]) : (this._type = e, this.name = l[e]);\n }\n get type() {\n return this._type;\n }\n equals(e) {\n return !e.type || !this.type ? !1 : e.type === this.type;\n }\n};\nn(h, \"Original\", new h(l.Original)), n(h, \"Septuagint\", new h(l.Septuagint)), n(h, \"Vulgate\", new h(l.Vulgate)), n(h, \"English\", new h(l.English)), n(h, \"RussianProtestant\", new h(l.RussianProtestant)), n(h, \"RussianOrthodox\", new h(l.RussianOrthodox));\nlet c = h;\nfunction E(t, e) {\n const s = e[0];\n for (let r = 1; r < e.length; r++)\n t = t.split(e[r]).join(s);\n return t.split(s);\n}\nvar D = /* @__PURE__ */ ((t) => (t[t.Valid = 0] = \"Valid\", t[t.UnknownVersification = 1] = \"UnknownVersification\", t[t.OutOfRange = 2] = \"OutOfRange\", t[t.VerseOutOfOrder = 3] = \"VerseOutOfOrder\", t[t.VerseRepeated = 4] = \"VerseRepeated\", t))(D || {});\nconst i = class i {\n constructor(e, s, r, a) {\n /** Not yet implemented. */\n n(this, \"firstChapter\");\n /** Not yet implemented. */\n n(this, \"lastChapter\");\n /** Not yet implemented. */\n n(this, \"lastVerse\");\n /** Not yet implemented. */\n n(this, \"hasSegmentsDefined\");\n /** Not yet implemented. */\n n(this, \"text\");\n /** Not yet implemented. */\n n(this, \"BBBCCCVVVS\");\n /** Not yet implemented. */\n n(this, \"longHashCode\");\n /** The versification of the reference. */\n n(this, \"versification\");\n n(this, \"rtlMark\", \"‏\");\n n(this, \"_bookNum\", 0);\n n(this, \"_chapterNum\", 0);\n n(this, \"_verseNum\", 0);\n n(this, \"_verse\");\n if (r == null && a == null)\n if (e != null && typeof e == \"string\") {\n const o = e, u = s != null && s instanceof c ? s : void 0;\n this.setEmpty(u), this.parse(o);\n } else if (e != null && typeof e == \"number\") {\n const o = s != null && s instanceof c ? s : void 0;\n this.setEmpty(o), this._verseNum = e % i.chapterDigitShifter, this._chapterNum = Math.floor(\n e % i.bookDigitShifter / i.chapterDigitShifter\n ), this._bookNum = Math.floor(e / i.bookDigitShifter);\n } else if (s == null)\n if (e != null && e instanceof i) {\n const o = e;\n this._bookNum = o.bookNum, this._chapterNum = o.chapterNum, this._verseNum = o.verseNum, this._verse = o.verse, this.versification = o.versification;\n } else {\n if (e == null) return;\n const o = e instanceof c ? e : i.defaultVersification;\n this.setEmpty(o);\n }\n else\n throw new Error(\"VerseRef constructor not supported.\");\n else if (e != null && s != null && r != null)\n if (typeof e == \"string\" && typeof s == \"string\" && typeof r == \"string\")\n this.setEmpty(a), this.updateInternal(e, s, r);\n else if (typeof e == \"number\" && typeof s == \"number\" && typeof r == \"number\")\n this._bookNum = e, this._chapterNum = s, this._verseNum = r, this.versification = a ?? i.defaultVersification;\n else\n throw new Error(\"VerseRef constructor not supported.\");\n else\n throw new Error(\"VerseRef constructor not supported.\");\n }\n /**\n * Determines if the verse string is in a valid format (does not consider versification).\n */\n static isVerseParseable(e) {\n return e.length > 0 && \"0123456789\".includes(e[0]) && !e.endsWith(this.verseRangeSeparator) && !e.endsWith(this.verseSequenceIndicator);\n }\n /**\n * Tries to parse the specified string into a verse reference.\n * @param str - The string to attempt to parse.\n * @returns success: `true` if the specified string was successfully parsed, `false` otherwise.\n * @returns verseRef: The result of the parse if successful, or empty VerseRef if it failed\n */\n static tryParse(e) {\n let s;\n try {\n return s = new i(e), { success: !0, verseRef: s };\n } catch (r) {\n if (r instanceof v)\n return s = new i(), { success: !1, verseRef: s };\n throw r;\n }\n }\n /**\n * Gets the reference as a comparable integer where the book, chapter, and verse each occupy 3\n * digits.\n * @param bookNum - Book number (this is 1-based, not an index).\n * @param chapterNum - Chapter number.\n * @param verseNum - Verse number.\n * @returns The reference as a comparable integer where the book, chapter, and verse each occupy 3\n * digits.\n */\n static getBBBCCCVVV(e, s, r) {\n return e % i.bcvMaxValue * i.bookDigitShifter + (s >= 0 ? s % i.bcvMaxValue * i.chapterDigitShifter : 0) + (r >= 0 ? r % i.bcvMaxValue : 0);\n }\n /**\n * Deserializes a serialized VerseRef.\n * @param serializedVerseRef - Serialized VerseRef to create from.\n * @returns the deserialized VerseRef.\n */\n static fromJSON(e) {\n const { book: s, chapterNum: r, verseNum: a, verse: o, versificationStr: u } = e, f = o || a.toString();\n let d;\n return u && (d = new c(u)), s ? new i(s, r.toString(), f, d) : new i();\n }\n /**\n * Parses a verse string and gets the leading numeric portion as a number.\n * @param verseStr - verse string to parse\n * @returns true if the entire string could be parsed as a single, simple verse number (1-999);\n * false if the verse string represented a verse bridge, contained segment letters, or was invalid\n */\n static tryGetVerseNum(e) {\n let s;\n if (!e)\n return s = -1, { success: !0, vNum: s };\n s = 0;\n let r;\n for (let a = 0; a < e.length; a++) {\n if (r = e[a], r < \"0\" || r > \"9\")\n return a === 0 && (s = -1), { success: !1, vNum: s };\n if (s = s * 10 + +r - 0, s > i.bcvMaxValue)\n return s = -1, { success: !1, vNum: s };\n }\n return { success: !0, vNum: s };\n }\n /**\n * Checks to see if a VerseRef hasn't been set - all values are the default.\n */\n get isDefault() {\n return this.bookNum === 0 && this.chapterNum === 0 && this.verseNum === 0 && this.versification == null;\n }\n /**\n * Gets whether the verse contains multiple verses.\n */\n get hasMultiple() {\n return this._verse != null && (this._verse.includes(i.verseRangeSeparator) || this._verse.includes(i.verseSequenceIndicator));\n }\n /**\n * Gets or sets the book of the reference. Book is the 3-letter abbreviation in capital letters,\n * e.g. `'MAT'`.\n */\n get book() {\n return m.bookNumberToId(this.bookNum, \"\");\n }\n set book(e) {\n this.bookNum = m.bookIdToNumber(e);\n }\n /**\n * Gets or sets the chapter of the reference,. e.g. `'3'`.\n */\n get chapter() {\n return this.isDefault || this._chapterNum < 0 ? \"\" : this._chapterNum.toString();\n }\n set chapter(e) {\n const s = +e;\n this._chapterNum = Number.isInteger(s) ? s : -1;\n }\n /**\n * Gets or sets the verse of the reference, including range, segments, and sequences, e.g. `'4'`,\n * or `'4b-5a, 7'`.\n */\n get verse() {\n return this._verse != null ? this._verse : this.isDefault || this._verseNum < 0 ? \"\" : this._verseNum.toString();\n }\n set verse(e) {\n const { success: s, vNum: r } = i.tryGetVerseNum(e);\n this._verse = s ? void 0 : e.replace(this.rtlMark, \"\"), this._verseNum = r, !(this._verseNum >= 0) && ({ vNum: this._verseNum } = i.tryGetVerseNum(this._verse));\n }\n /**\n * Get or set Book based on book number, e.g. `42`.\n */\n get bookNum() {\n return this._bookNum;\n }\n set bookNum(e) {\n if (e <= 0 || e > m.lastBook)\n throw new v(\n \"BookNum must be greater than zero and less than or equal to last book\"\n );\n this._bookNum = e;\n }\n /**\n * Gets or sets the chapter number, e.g. `3`. `-1` if not valid.\n */\n get chapterNum() {\n return this._chapterNum;\n }\n set chapterNum(e) {\n this.chapterNum = e;\n }\n /**\n * Gets or sets verse start number, e.g. `4`. `-1` if not valid.\n */\n get verseNum() {\n return this._verseNum;\n }\n set verseNum(e) {\n this._verseNum = e;\n }\n /**\n * String representing the versification (should ONLY be used for serialization/deserialization).\n *\n * @remarks This is for backwards compatibility when ScrVers was an enumeration.\n */\n get versificationStr() {\n var e;\n return (e = this.versification) == null ? void 0 : e.name;\n }\n set versificationStr(e) {\n this.versification = this.versification != null ? new c(e) : void 0;\n }\n /**\n * Determines if the reference is valid.\n */\n get valid() {\n return this.validStatus === 0;\n }\n /**\n * Get the valid status for this reference.\n */\n get validStatus() {\n return this.validateVerse(i.verseRangeSeparators, i.verseSequenceIndicators);\n }\n /**\n * Gets the reference as a comparable integer where the book,\n * chapter, and verse each occupy three digits and the verse is 0.\n */\n get BBBCCC() {\n return i.getBBBCCCVVV(this._bookNum, this._chapterNum, 0);\n }\n /**\n * Gets the reference as a comparable integer where the book,\n * chapter, and verse each occupy three digits. If verse is not null\n * (i.e., this reference represents a complex reference with verse\n * segments or bridge) this cannot be used for an exact comparison.\n */\n get BBBCCCVVV() {\n return i.getBBBCCCVVV(this._bookNum, this._chapterNum, this._verseNum);\n }\n /**\n * Gets whether the verse is defined as an excluded verse in the versification.\n * Does not handle verse ranges.\n */\n // eslint-disable-next-line @typescript-eslint/class-literal-property-style\n get isExcluded() {\n return !1;\n }\n /**\n * Parses the reference in the specified string.\n * Optionally versification can follow reference as in GEN 3:11/4\n * Throw an exception if\n * - invalid book name\n * - chapter number is missing or not a number\n * - verse number is missing or does not start with a number\n * - versification is invalid\n * @param verseStr - string to parse e.g. 'MAT 3:11'\n */\n parse(e) {\n if (e = e.replace(this.rtlMark, \"\"), e.includes(\"/\")) {\n const o = e.split(\"/\");\n if (e = o[0], o.length > 1)\n try {\n const u = +o[1].trim();\n this.versification = new c(l[u]);\n } catch {\n throw new v(\"Invalid reference : \" + e);\n }\n }\n const s = e.trim().split(\" \");\n if (s.length !== 2)\n throw new v(\"Invalid reference : \" + e);\n const r = s[1].split(\":\"), a = +r[0];\n if (r.length !== 2 || m.bookIdToNumber(s[0]) === 0 || !Number.isInteger(a) || a < 0 || !i.isVerseParseable(r[1]))\n throw new v(\"Invalid reference : \" + e);\n this.updateInternal(s[0], r[0], r[1]);\n }\n /**\n * Simplifies this verse ref so that it has no bridging of verses or\n * verse segments like `'1a'`.\n */\n simplify() {\n this._verse = void 0;\n }\n /**\n * Makes a clone of the reference.\n *\n * @returns The cloned VerseRef.\n */\n clone() {\n return new i(this);\n }\n toString() {\n const e = this.book;\n return e === \"\" ? \"\" : `${e} ${this.chapter}:${this.verse}`;\n }\n toJSON() {\n let e = this.verse;\n (e === \"\" || e === this.verseNum.toString()) && (e = void 0);\n const s = {\n book: this.book,\n chapterNum: this.chapterNum,\n verseNum: this.verseNum,\n verse: e,\n versificationStr: this.versificationStr\n };\n return e || delete s.verse, s;\n }\n /**\n * Compares this `VerseRef` with supplied one.\n * @param verseRef - object to compare this one to.\n * @returns `true` if this `VerseRef` is equal to the supplied one, `false` otherwise.\n */\n equals(e) {\n return e instanceof i ? e._bookNum === this._bookNum && e._chapterNum === this._chapterNum && e._verseNum === this._verseNum && e.verse === this.verse && (e.versification == null && this.versification == null || e.versification != null && this.versification != null && e.versification.equals(this.versification)) : !1;\n }\n /**\n * Enumerate all individual verses contained in a VerseRef.\n * Verse ranges are indicated by \"-\" and consecutive verses by \",\"s.\n * Examples:\n * GEN 1:2 returns GEN 1:2\n * GEN 1:1a-3b,5 returns GEN 1:1a, GEN 1:2, GEN 1:3b, GEN 1:5\n * GEN 1:2a-2c returns //! ??????\n *\n * @param specifiedVersesOnly - if set to true return only verses that are\n * explicitly specified only, not verses within a range. Defaults to `false`.\n * @param verseRangeSeparators - Verse range separators.\n * Defaults to `VerseRef.verseRangeSeparators`.\n * @param verseSequenceSeparators - Verse sequence separators.\n * Defaults to `VerseRef.verseSequenceIndicators`.\n * @returns An array of all single verse references in this VerseRef.\n */\n allVerses(e = !1, s = i.verseRangeSeparators, r = i.verseSequenceIndicators) {\n if (this._verse == null || this.chapterNum <= 0)\n return [this.clone()];\n const a = [], o = E(this._verse, r);\n for (const u of o.map((f) => E(f, s))) {\n const f = this.clone();\n f.verse = u[0];\n const d = f.verseNum;\n if (a.push(f), u.length > 1) {\n const b = this.clone();\n if (b.verse = u[1], !e)\n for (let p = d + 1; p < b.verseNum; p++) {\n const J = new i(\n this._bookNum,\n this._chapterNum,\n p,\n this.versification\n );\n this.isExcluded || a.push(J);\n }\n a.push(b);\n }\n }\n return a;\n }\n /**\n * Validates a verse number using the supplied separators rather than the defaults.\n */\n validateVerse(e, s) {\n if (!this.verse)\n return this.internalValid;\n let r = 0;\n for (const a of this.allVerses(!0, e, s)) {\n const o = a.internalValid;\n if (o !== 0)\n return o;\n const u = a.BBBCCCVVV;\n if (r > u)\n return 3;\n if (r === u)\n return 4;\n r = u;\n }\n return 0;\n }\n /**\n * Gets whether a single verse reference is valid.\n */\n get internalValid() {\n return this.versification == null ? 1 : this._bookNum <= 0 || this._bookNum > m.lastBook ? 2 : (m.isCanonical(this._bookNum), 0);\n }\n setEmpty(e = i.defaultVersification) {\n this._bookNum = 0, this._chapterNum = -1, this._verse = void 0, this.versification = e;\n }\n updateInternal(e, s, r) {\n this.bookNum = m.bookIdToNumber(e), this.chapter = s, this.verse = r;\n }\n};\nn(i, \"defaultVersification\", c.English), n(i, \"verseRangeSeparator\", \"-\"), n(i, \"verseSequenceIndicator\", \",\"), n(i, \"verseRangeSeparators\", [i.verseRangeSeparator]), n(i, \"verseSequenceIndicators\", [i.verseSequenceIndicator]), n(i, \"chapterDigitShifter\", 1e3), n(i, \"bookDigitShifter\", i.chapterDigitShifter * i.chapterDigitShifter), n(i, \"bcvMaxValue\", i.chapterDigitShifter - 1), /**\n * The valid status of the VerseRef.\n */\nn(i, \"ValidStatusType\", D);\nlet M = i;\nclass v extends Error {\n}\nexport {\n _ as BookSet,\n m as Canon,\n c as ScrVers,\n l as ScrVersType,\n M as VerseRef,\n v as VerseRefException\n};\n//# sourceMappingURL=index.es.js.map\n","import React from 'react';\nimport * as DropdownMenuPrimitive from '@radix-ui/react-dropdown-menu';\nimport { Check, ChevronRight, Circle } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport const DropdownMenu = DropdownMenuPrimitive.Root;\n\nexport const DropdownMenuTrigger = DropdownMenuPrimitive.Trigger;\n\nexport const DropdownMenuGroup = DropdownMenuPrimitive.Group;\n\nexport const DropdownMenuPortal = DropdownMenuPrimitive.Portal;\n\nexport const DropdownMenuSub = DropdownMenuPrimitive.Sub;\n\nexport const DropdownMenuRadioGroup = DropdownMenuPrimitive.RadioGroup;\n\nexport type DropdownMenuSubTriggerProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.SubTrigger\n> & {\n className?: string;\n inset?: boolean;\n};\n\nexport type DropdownMenuSubContentProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.SubContent\n> & {\n className?: string;\n};\n\nexport type DropdownMenuContentProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Content\n> & {\n className?: string;\n sideOffset?: number;\n};\n\nexport type DropdownMenuItemProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Item\n> & {\n className?: string;\n inset?: boolean;\n};\n\nexport type DropdownMenuCheckboxItemProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.CheckboxItem\n> & {\n className?: string;\n checked?: boolean;\n};\n\nexport type DropdownMenuRadioItemProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.RadioItem\n> & {\n className?: string;\n};\n\nexport type DropdownMenuLabelProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Label\n> & {\n className?: string;\n inset?: boolean;\n};\n\nexport type DropdownMenuSeparatorProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Separator\n> & {\n className?: string;\n};\n\nexport type DropdownMenuShortcutProps = React.HTMLAttributes & {\n className?: string;\n};\n\nexport const DropdownMenuSubTrigger = React.forwardRef<\n React.ElementRef,\n DropdownMenuSubTriggerProps\n>(({ className, inset, children, ...props }, ref) => (\n \n {children}\n \n \n));\nDropdownMenuSubTrigger.displayName = DropdownMenuPrimitive.SubTrigger.displayName;\n\nexport const DropdownMenuSubContent = React.forwardRef<\n React.ElementRef,\n DropdownMenuSubContentProps\n>(({ className, ...props }, ref) => (\n \n));\nDropdownMenuSubContent.displayName = DropdownMenuPrimitive.SubContent.displayName;\n\nexport const DropdownMenuContent = React.forwardRef<\n React.ElementRef,\n DropdownMenuContentProps\n>(({ className, sideOffset = 4, ...props }, ref) => (\n \n \n \n));\nDropdownMenuContent.displayName = DropdownMenuPrimitive.Content.displayName;\n\n/**\n * TODO: fix: direction is not automatically handled by this component, so that shortcuts are\n * display always to the right\n */\nexport const DropdownMenuItem = React.forwardRef<\n React.ElementRef,\n DropdownMenuItemProps\n>(({ className, inset, ...props }, ref) => (\n \n));\nDropdownMenuItem.displayName = DropdownMenuPrimitive.Item.displayName;\n\nexport const DropdownMenuCheckboxItem = React.forwardRef<\n React.ElementRef,\n DropdownMenuCheckboxItemProps\n>(({ className, children, checked, ...props }, ref) => (\n \n \n \n \n \n \n {children}\n \n));\nDropdownMenuCheckboxItem.displayName = DropdownMenuPrimitive.CheckboxItem.displayName;\n\nexport const DropdownMenuRadioItem = React.forwardRef<\n React.ElementRef,\n DropdownMenuRadioItemProps\n>(({ className, children, ...props }, ref) => (\n \n \n \n \n \n \n {children}\n \n));\nDropdownMenuRadioItem.displayName = DropdownMenuPrimitive.RadioItem.displayName;\n\nexport const DropdownMenuLabel = React.forwardRef<\n React.ElementRef,\n DropdownMenuLabelProps\n>(({ className, inset, ...props }, ref) => (\n \n));\nDropdownMenuLabel.displayName = DropdownMenuPrimitive.Label.displayName;\n\nexport const DropdownMenuSeparator = React.forwardRef<\n React.ElementRef,\n DropdownMenuSeparatorProps\n>(({ className, ...props }, ref) => (\n \n));\nDropdownMenuSeparator.displayName = DropdownMenuPrimitive.Separator.displayName;\n\nexport function DropdownMenuShortcut({ className, ...props }: DropdownMenuShortcutProps) {\n return (\n \n );\n}\nDropdownMenuShortcut.displayName = 'DropdownMenuShortcut';\n","import { Canon } from '@sillsdev/scripture';\nimport { PropsWithChildren, KeyboardEvent, forwardRef } from 'react';\nimport { DropdownMenuItem as ShadDropdownMenuItem } from '@/components/shadcn-ui/dropdown-menu';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport type BookType = 'OT' | 'NT' | 'DC';\n\ntype BookMenuItemProps = PropsWithChildren<{\n /** String id of book */\n bookId: string;\n /** Callback to run when a book menu item is selected */\n handleSelectBook: () => void;\n /** Indicates if this menu item is currently selected */\n isSelected: boolean;\n /** Function that is called upon highlighting a book in the dropdown menu */\n handleHighlightBook: () => void;\n /**\n * Function that is called on pressing a key\n *\n * @param event Event that contains information about the key stroke\n */\n handleKeyDown: (event: KeyboardEvent) => void;\n /**\n * Type of book associated with this menu item, coordinates color labels ? Mock up has the labels\n * coordinated to genre\n */\n bookType: BookType;\n}>;\n\nconst BookMenuItem = forwardRef(\n (\n {\n bookId,\n handleSelectBook,\n isSelected,\n handleHighlightBook,\n handleKeyDown,\n bookType,\n children,\n }: BookMenuItemProps,\n ref,\n ) => {\n return (\n {\n // preventDefault() here prevents the entire dropdown menu from closing when selecting this item\n event.preventDefault();\n handleSelectBook();\n }}\n onKeyDown={(event: KeyboardEvent) => {\n handleKeyDown(event);\n }}\n onFocus={handleHighlightBook}\n onMouseMove={handleHighlightBook}\n >\n \n {Canon.bookIdToEnglishName(bookId)}\n \n {isSelected &&
    {children}
    }\n \n );\n },\n);\n\nexport default BookMenuItem;\n","import { cn } from '@/utils/shadcn-ui.util';\nimport { useCallback } from 'react';\n\nexport type ChapterSelectProps = {\n /**\n * Callback to run when a chapter div is selected\n *\n * @param chapterNumber Number of the chapter that has been selected\n */\n handleSelectChapter: (chapterNumber: number) => void;\n /** The highest chapter number in the book (of course equal to number of chapters in the book) */\n endChapter: number;\n /** The chapter number that is currently selected */\n activeChapter: number;\n /** The chapter number that is currently highlighted using keyboard or mouse navigation */\n highlightedChapter: number;\n /**\n * Callback to run when a chapter is highlighted by the user\n *\n * @param chapterNumber The chapter that is highlighted\n */\n handleHighlightedChapter: (chapterNumber: number) => void;\n};\n\nfunction ChapterSelect({\n handleSelectChapter,\n endChapter,\n activeChapter,\n highlightedChapter,\n handleHighlightedChapter,\n}: ChapterSelectProps) {\n const chapters = Array.from({ length: endChapter }, (_, i) => i + 1);\n\n const handleMouse = useCallback(\n (chapterNumber: number) => {\n handleHighlightedChapter(chapterNumber);\n },\n [handleHighlightedChapter],\n );\n\n return (\n
    \n {chapters.map((chapter) => (\n {\n event.preventDefault();\n event.stopPropagation();\n handleSelectChapter(chapter);\n }}\n role=\"button\"\n onKeyDown={(event) => {\n if (event.key === 'Enter') {\n handleSelectChapter(chapter);\n }\n }}\n tabIndex={0}\n onMouseMove={() => handleMouse(chapter)}\n >\n {chapter}\n
    \n ))}\n
    \n );\n}\n\nexport default ChapterSelect;\n","import { DropdownMenuLabel as ShadDropdownMenuLabel } from '@/components/shadcn-ui/dropdown-menu';\nimport { Bookmark, Clock, ArrowDownWideNarrow } from 'lucide-react';\n\nexport type GoToMenuItemProps = {\n handleSort: () => void;\n handleLocationHistory: () => void;\n handleBookmarks: () => void;\n};\n\nfunction GoToMenuItem({ handleSort, handleLocationHistory, handleBookmarks }: GoToMenuItemProps) {\n return (\n \n

    Go To

    \n
    \n \n \n \n
    \n
    \n );\n}\n\nexport default GoToMenuItem;\n","import BookChapterInput from '@/components/advanced/book-chapter-control/book-chapter-input.component';\nimport BookMenuItem, {\n BookType,\n} from '@/components/advanced/book-chapter-control/book-menu-item.component';\nimport ChapterSelect from '@/components/advanced/book-chapter-control/chapter-select.component';\nimport GoToMenuItem from '@/components/advanced/book-chapter-control/go-to-menu-item.component';\nimport {\n DropdownMenu as ShadDropdownMenu,\n DropdownMenuContent as ShadDropdownMenuContent,\n DropdownMenuLabel as ShadDropdownMenuLabel,\n DropdownMenuSeparator as ShadDropdownMenuSeparator,\n DropdownMenuTrigger as ShadDropdownMenuTrigger,\n} from '@/components/shadcn-ui/dropdown-menu';\nimport { Canon } from '@sillsdev/scripture';\nimport { ScriptureReference, getChaptersForBook } from 'platform-bible-utils';\nimport {\n KeyboardEvent as ReactKeyboardEvent,\n useCallback,\n useEffect,\n useLayoutEffect,\n useRef,\n useState,\n} from 'react';\n\ntype BookTypeLabels = {\n [bookType in BookType]: string;\n};\ntype BookChapterControlProps = {\n scrRef: ScriptureReference;\n handleSubmit: (scrRef: ScriptureReference) => void;\n};\n\nconst ALL_BOOK_IDS = Canon.allBookIds;\nconst BOOK_TYPE_LABELS: BookTypeLabels = {\n OT: 'Old Testament',\n NT: 'New Testament',\n DC: 'Deuterocanon',\n};\nconst BOOK_TYPE_ARRAY: BookType[] = ['OT', 'NT', 'DC'];\n// This is the height of three menu items to offset scrolling to the selected menu item\n// If you use menuItemRef.clientHeight- includes height of chapter div which is too big\nconst SCROLL_OFFSET = 32 + 32 + 32;\nconst SEARCH_QUERY_FORMATS = [\n /^(\\w+)$/i, // Matches a single word (book name or id)\n /^(\\w+)(?:\\s(\\d+))$/i, // Matches a word followed by a chapter number\n /^(\\w+)(?:\\s(\\d+):(\\d+))$/i, // Matches a word followed by a chapter and verse number\n];\nconst fetchGroupedBooks = (bookType: BookType) => {\n const groupedBooks = {\n OT: ALL_BOOK_IDS.filter((bookId) => Canon.isBookOT(bookId)),\n NT: ALL_BOOK_IDS.filter((bookId) => Canon.isBookNT(bookId)),\n DC: ALL_BOOK_IDS.filter((bookId) => Canon.isBookDC(bookId)),\n };\n return groupedBooks[bookType];\n};\nconst fetchEndChapter = (bookId: string) => {\n // getChaptersForBook returns -1 if not found in scrBookData\n // scrBookData only includes OT and NT, so all DC will return -1\n return getChaptersForBook(Canon.bookIdToNumber(bookId));\n};\n\n/**\n * Gets all of the English names from book ids\n *\n * @returns String[]\n */\nfunction getAllEnglishNames(): string[] {\n const allEnglishNames = ALL_BOOK_IDS.map((bookId) => {\n return Canon.bookIdToEnglishName(bookId);\n });\n return allEnglishNames;\n}\n\n/**\n * Determines if bookName is in allEnglishNames\n *\n * @param bookName Book English name\n * @returns True if bookName is included, false otherwise\n */\nfunction isValidBookEnglishName(bookName: string): boolean {\n return getAllEnglishNames().includes(bookName);\n}\n\n/**\n * Gets a bookId from given English name\n *\n * @param bookName Book English name\n * @returns BookId of provided bookName, undefined otherwise\n */\nfunction getBookIdFromEnglishName(bookName: string): string | undefined {\n // Convert bookName to lowercase and then capitalize the first letter\n const formattedBookName = bookName.toLowerCase().replace(/^\\w/, (c) => c.toUpperCase());\n\n if (isValidBookEnglishName(formattedBookName)) {\n const matchingBookId = ALL_BOOK_IDS.find((bookId) => {\n return Canon.bookIdToEnglishName(bookId) === formattedBookName;\n });\n return matchingBookId;\n }\n\n return undefined;\n}\n\nfunction BookChapterControl({ scrRef, handleSubmit }: BookChapterControlProps) {\n const [searchQuery, setSearchQuery] = useState('');\n const [selectedBookId, setSelectedBookId] = useState(\n Canon.bookNumberToId(scrRef.bookNum),\n );\n const [highlightedChapter, setHighlightedChapter] = useState(scrRef.chapterNum ?? 0);\n const [highlightedBookId, setHighlightedBookId] = useState(\n Canon.bookNumberToId(scrRef.bookNum),\n );\n const [isContentOpen, setIsContentOpen] = useState(false);\n const [isContentOpenDelayed, setIsContentOpenDelayed] = useState(isContentOpen);\n\n // This ref will always be defined\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const inputRef = useRef(undefined!);\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const contentRef = useRef(undefined!);\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const menuItemRef = useRef(undefined!);\n\n const fetchFilteredBooks = useCallback(\n (bookType: BookType) => {\n return fetchGroupedBooks(bookType).filter((bookId: string) => {\n const englishNameLowerCase = Canon.bookIdToEnglishName(bookId).toLowerCase();\n const normalizedQuery = searchQuery.replace(/[^a-zA-Z]/g, '').toLowerCase();\n return (\n englishNameLowerCase.includes(normalizedQuery) || // Match book name\n bookId.toLowerCase().includes(normalizedQuery) // Match book ID\n );\n });\n },\n [searchQuery],\n );\n\n const handleSearchInput = (searchString: string) => {\n setSearchQuery(searchString);\n };\n\n /**\n * Whether to prevent radix's logic from closing the dropdown. This is important because radix\n * tries to close the dropdown when the input first focuses, and we don't want it to do that. But\n * we don't want to prevent the dropdown from closing when we click away from the input, so we\n * don't want to just keep it open if the input is focused\n */\n const shouldPreventAutoClosing = useRef(false);\n\n const controlMenuState = useCallback((open: boolean) => {\n if (shouldPreventAutoClosing.current) {\n shouldPreventAutoClosing.current = false;\n return;\n }\n setIsContentOpen(open);\n }, []);\n\n const updateReference = useCallback(\n (bookId: string, shouldClose: boolean, chapter?: number, verse?: number) => {\n setHighlightedChapter(\n Canon.bookNumberToId(scrRef.bookNum) !== bookId ? 1 : scrRef.chapterNum,\n );\n\n if (shouldClose || fetchEndChapter(bookId) === -1) {\n handleSubmit({\n bookNum: Canon.bookIdToNumber(bookId),\n chapterNum: chapter || 1,\n verseNum: verse || 1,\n });\n\n setIsContentOpen(false);\n setSearchQuery('');\n return;\n }\n\n setSelectedBookId(selectedBookId !== bookId ? bookId : '');\n setIsContentOpen(!shouldClose);\n },\n [handleSubmit, scrRef.bookNum, scrRef.chapterNum, selectedBookId],\n );\n\n const handleSelectChapter = (chapterNumber: number) => {\n if (chapterNumber <= 0 || chapterNumber > fetchEndChapter(selectedBookId)) {\n return;\n }\n updateReference(selectedBookId, true, chapterNumber);\n };\n\n const handleInputSubmit = useCallback(() => {\n SEARCH_QUERY_FORMATS.forEach((format) => {\n const matches = searchQuery.match(format);\n if (matches) {\n // Book should be a bookId or an english name\n const [book, chapter = undefined, verse = undefined] = matches.slice(1);\n const englishName = getBookIdFromEnglishName(book);\n\n if (Canon.isBookIdValid(book) || englishName) {\n updateReference(\n englishName ?? book,\n true,\n chapter ? parseInt(chapter, 10) : 1,\n verse ? parseInt(verse, 10) : 1,\n );\n }\n }\n });\n }, [updateReference, searchQuery]);\n\n const handleKeyDownInput = useCallback(\n (event: ReactKeyboardEvent) => {\n if (!isContentOpen) {\n setIsContentOpen(true);\n } else if (event.key === 'ArrowDown' || event.key === 'ArrowUp') {\n if (\n typeof menuItemRef !== 'undefined' &&\n // Ref uses null\n // eslint-disable-next-line no-null/no-null\n menuItemRef.current !== null\n ) {\n menuItemRef.current.focus();\n } else if (\n typeof contentRef !== 'undefined' &&\n // Ref uses null\n // eslint-disable-next-line no-null/no-null\n contentRef.current !== null\n ) {\n contentRef.current.focus();\n }\n event.preventDefault();\n }\n },\n [isContentOpen],\n );\n\n const handleKeyDownContent = (event: ReactKeyboardEvent) => {\n // When the dropdown menu has focus, key strokes should give focus to the input component,\n // unless they're navigation keys (arrows and enter)\n const { key } = event;\n if (\n key === 'ArrowRight' ||\n key === 'ArrowLeft' ||\n key === 'ArrowDown' ||\n key === 'ArrowUp' ||\n key === 'Enter'\n ) {\n return;\n }\n\n inputRef.current.dispatchEvent(new KeyboardEvent('keydown', { key }));\n inputRef.current.focus();\n };\n\n const handleKeyDownMenuItem = (event: ReactKeyboardEvent) => {\n const { key } = event;\n if (highlightedBookId === selectedBookId) {\n if (key === 'Enter') {\n event.preventDefault();\n updateReference(selectedBookId, true, highlightedChapter);\n return;\n }\n\n let chapterOffSet = 0;\n if (key === 'ArrowRight') {\n if (highlightedChapter < fetchEndChapter(highlightedBookId)) {\n chapterOffSet = 1;\n } else {\n event.preventDefault();\n return;\n }\n } else if (key === 'ArrowLeft') {\n if (highlightedChapter > 1) {\n chapterOffSet = -1;\n } else {\n event.preventDefault();\n return;\n }\n } else if (key === 'ArrowDown') {\n chapterOffSet = 6;\n } else if (key === 'ArrowUp') {\n chapterOffSet = -6;\n }\n if (\n highlightedChapter + chapterOffSet <= 0 ||\n highlightedChapter + chapterOffSet > fetchEndChapter(highlightedBookId)\n ) {\n setHighlightedChapter(0);\n } else if (chapterOffSet !== 0) {\n setHighlightedChapter(highlightedChapter + chapterOffSet);\n event.preventDefault();\n }\n }\n };\n\n useEffect(() => {\n if (selectedBookId === highlightedBookId) {\n if (selectedBookId === Canon.bookNumberToId(scrRef.bookNum)) {\n setHighlightedChapter(scrRef.chapterNum);\n } else {\n setHighlightedChapter(1);\n }\n } else {\n setHighlightedChapter(0);\n }\n }, [highlightedBookId, scrRef.bookNum, scrRef.chapterNum, selectedBookId]);\n\n // The purpose of these useLayoutEffects and timeout is to delay the scroll just\n // enough so that the refs are defined and available when they are used after the timeout\n useLayoutEffect(() => {\n setIsContentOpenDelayed(isContentOpen);\n }, [isContentOpen]);\n\n useLayoutEffect(() => {\n const scrollTimeout = setTimeout(() => {\n if (isContentOpenDelayed && contentRef.current && menuItemRef.current) {\n const menuItemOffsetTop = menuItemRef.current.offsetTop;\n const scrollPosition = menuItemOffsetTop - SCROLL_OFFSET;\n contentRef.current.scrollTo({ top: scrollPosition, behavior: 'instant' });\n }\n }, 10);\n return () => {\n clearTimeout(scrollTimeout);\n };\n }, [isContentOpenDelayed]);\n\n return (\n
    \n \n \n {\n setSelectedBookId(Canon.bookNumberToId(scrRef.bookNum));\n setHighlightedBookId(Canon.bookNumberToId(scrRef.bookNum));\n setHighlightedChapter(scrRef.chapterNum > 0 ? scrRef.chapterNum : 0);\n setIsContentOpen(true);\n inputRef.current.focus();\n }}\n onFocus={() => {\n // Radix thinks we want to close because the input is being focused. Prevent that\n shouldPreventAutoClosing.current = true;\n }}\n handleSubmit={handleInputSubmit}\n placeholder={`${Canon.bookNumberToEnglishName(scrRef.bookNum)} ${scrRef.chapterNum}:${scrRef.verseNum}`}\n />\n \n \n console.log('sorting')}\n handleLocationHistory={() => console.log('location history')}\n handleBookmarks={() => console.log('bookmarks')}\n />\n {BOOK_TYPE_ARRAY.map(\n (bookType, bookTypeIndex) =>\n fetchFilteredBooks(bookType).length > 0 && (\n
    \n \n {BOOK_TYPE_LABELS[bookType]}\n \n\n {fetchFilteredBooks(bookType).map((bookId) => (\n
    \n updateReference(bookId, false)}\n isSelected={selectedBookId === bookId}\n handleHighlightBook={() => setHighlightedBookId(bookId)}\n handleKeyDown={handleKeyDownMenuItem}\n bookType={bookType}\n ref={(element: HTMLDivElement) => {\n if (selectedBookId === bookId) menuItemRef.current = element;\n }}\n >\n {\n setHighlightedChapter(chapterNumber);\n }}\n />\n \n
    \n ))}\n {BOOK_TYPE_ARRAY.length - 1 !== bookTypeIndex ? (\n \n ) : undefined}\n
    \n ),\n )}\n \n
    \n
    \n );\n}\n\nexport default BookChapterControl;\n","import React from 'react';\nimport { Slot } from '@radix-ui/react-slot';\nimport { cva, type VariantProps } from 'class-variance-authority';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport const buttonVariants = cva(\n 'pr-twp tw-inline-flex tw-items-center tw-justify-center tw-whitespace-nowrap tw-rounded-md tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-colors focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50',\n {\n variants: {\n variant: {\n default: 'tw-bg-primary tw-text-primary-foreground hover:tw-bg-primary/90',\n destructive: 'tw-bg-destructive tw-text-destructive-foreground hover:tw-bg-destructive/90',\n outline:\n 'tw-border tw-border-input tw-bg-background hover:tw-bg-accent hover:tw-text-accent-foreground',\n secondary: 'tw-bg-secondary tw-text-secondary-foreground hover:tw-bg-secondary/80',\n ghost: 'hover:tw-bg-accent hover:tw-text-accent-foreground',\n link: 'tw-text-primary tw-underline-offset-4 hover:tw-underline',\n },\n size: {\n default: 'tw-h-10 tw-px-4 tw-py-2',\n sm: 'tw-h-9 tw-rounded-md tw-px-3',\n lg: 'tw-h-11 tw-rounded-md tw-px-8',\n icon: 'tw-h-10 tw-w-10',\n },\n },\n defaultVariants: {\n variant: 'default',\n size: 'default',\n },\n },\n);\n\nexport interface ButtonProps\n extends React.ButtonHTMLAttributes,\n VariantProps {\n asChild?: boolean;\n}\n\nexport const Button = React.forwardRef(\n ({ className, variant, size, asChild = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'button';\n return (\n \n );\n },\n);\nButton.displayName = 'Button';\n","import React from 'react';\nimport * as LabelPrimitive from '@radix-ui/react-label';\nimport { cva, type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst labelVariants = cva(\n 'tw-text-sm tw-font-medium tw-leading-none peer-disabled:tw-cursor-not-allowed peer-disabled:tw-opacity-70',\n);\n\nexport const Label = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef & VariantProps\n>(({ className, ...props }, ref) => (\n \n));\nLabel.displayName = LabelPrimitive.Root.displayName;\n","import React from 'react';\nimport * as RadioGroupPrimitive from '@radix-ui/react-radio-group';\nimport { Circle } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst RadioGroup = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => {\n return (\n \n );\n});\nRadioGroup.displayName = RadioGroupPrimitive.Root.displayName;\n\nconst RadioGroupItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => {\n return (\n \n \n \n \n \n );\n});\nRadioGroupItem.displayName = RadioGroupPrimitive.Item.displayName;\n\nexport { RadioGroup, RadioGroupItem };\n","import React from 'react';\nimport * as PopoverPrimitive from '@radix-ui/react-popover';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Popover = PopoverPrimitive.Root;\n\nconst PopoverTrigger = PopoverPrimitive.Trigger;\n\nconst PopoverContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, align = 'center', sideOffset = 4, ...props }, ref) => (\n \n \n \n));\nPopoverContent.displayName = PopoverPrimitive.Content.displayName;\n\nexport { Popover, PopoverTrigger, PopoverContent };\n","import React from 'react';\nimport * as DialogPrimitive from '@radix-ui/react-dialog';\nimport { X } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Dialog = DialogPrimitive.Root;\n\nconst DialogTrigger = DialogPrimitive.Trigger;\n\nconst DialogPortal = DialogPrimitive.Portal;\n\nconst DialogClose = DialogPrimitive.Close;\n\nconst DialogOverlay = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nDialogOverlay.displayName = DialogPrimitive.Overlay.displayName;\n\nconst DialogContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, ...props }, ref) => (\n \n \n \n {children}\n \n \n Close\n \n \n \n));\nDialogContent.displayName = DialogPrimitive.Content.displayName;\n\nfunction DialogHeader({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nDialogHeader.displayName = 'DialogHeader';\n\nfunction DialogFooter({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nDialogFooter.displayName = 'DialogFooter';\n\nconst DialogTitle = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nDialogTitle.displayName = DialogPrimitive.Title.displayName;\n\nconst DialogDescription = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nDialogDescription.displayName = DialogPrimitive.Description.displayName;\n\nexport {\n Dialog,\n DialogPortal,\n DialogOverlay,\n DialogClose,\n DialogTrigger,\n DialogContent,\n DialogHeader,\n DialogFooter,\n DialogTitle,\n DialogDescription,\n};\n","import React from 'react';\nimport { type DialogProps } from '@radix-ui/react-dialog';\nimport { Command as CommandPrimitive } from 'cmdk';\nimport { Search } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Dialog, DialogContent } from '@/components/shadcn-ui/dialog';\n\nconst Command = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nCommand.displayName = CommandPrimitive.displayName;\n\ninterface CommandDialogProps extends DialogProps {}\n\nfunction CommandDialog({ children, ...props }: CommandDialogProps) {\n return (\n \n \n \n {children}\n \n \n \n );\n}\n\nconst CommandInput = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n
    \n \n \n
    \n));\n\nCommandInput.displayName = CommandPrimitive.Input.displayName;\n\nconst CommandList = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\n\nCommandList.displayName = CommandPrimitive.List.displayName;\n\nconst CommandEmpty = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>((props, ref) => (\n \n));\n\nCommandEmpty.displayName = CommandPrimitive.Empty.displayName;\n\nconst CommandGroup = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\n\nCommandGroup.displayName = CommandPrimitive.Group.displayName;\n\nconst CommandSeparator = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nCommandSeparator.displayName = CommandPrimitive.Separator.displayName;\n\nconst CommandItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\n\nCommandItem.displayName = CommandPrimitive.Item.displayName;\n\nfunction CommandShortcut({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nCommandShortcut.displayName = 'CommandShortcut';\n\nexport {\n Command,\n CommandDialog,\n CommandInput,\n CommandList,\n CommandEmpty,\n CommandGroup,\n CommandItem,\n CommandShortcut,\n CommandSeparator,\n};\n","import { useState } from 'react';\nimport { Check, ChevronsUpDown } from 'lucide-react';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport { Popover, PopoverContent, PopoverTrigger } from '@/components/shadcn-ui/popover';\nimport {\n Command,\n CommandEmpty,\n CommandInput,\n CommandItem,\n CommandList,\n} from '@/components/shadcn-ui/command';\nimport { PopoverProps } from '@radix-ui/react-popover';\n\nexport type ComboBoxLabelOption = { label: string };\nexport type ComboBoxOption = string | number | ComboBoxLabelOption;\n\nexport type ComboBoxProps = {\n /** Optional unique identifier */\n id?: string;\n /** Text label title for combobox */\n /** List of available options for the dropdown menu */\n options?: readonly T[];\n /** Additional css classes to help with unique styling of the combo box button */\n buttonClassName?: string;\n /** Additional css classes to help with unique styling of the combo box popover */\n popoverContentClassName?: string;\n /**\n * The selected value that the combo box currently holds. Must be shallow equal to one of the\n * options entries.\n */\n value?: T;\n /** Triggers when content of textfield is changed */\n onChange?: (newValue: T) => void;\n /** Used to determine the string value for a given option. */\n getOptionLabel?: (option: ComboBoxOption) => string;\n /** Text displayed on button if `value` is undefined */\n buttonPlaceholder?: string;\n /** Placeholder text for text field */\n textPlaceholder?: string;\n /** Text to display when no options match input */\n commandEmptyMessage?: string;\n /** Variant of button */\n buttonVariant?: ButtonProps['variant'];\n /** Text direction ltr or rtl */\n dir?: Direction;\n /** Optional boolean to set if trigger should be disabled */\n isDisabled?: boolean;\n} & PopoverProps;\n\ntype Direction = 'ltr' | 'rtl';\n\nfunction getOptionLabelDefault(option: ComboBoxOption): string {\n if (typeof option === 'string') {\n return option;\n }\n if (typeof option === 'number') {\n return option.toString();\n }\n return option.label;\n}\n\n/**\n * Autocomplete input and command palette with a list of suggestions.\n *\n * Thanks to Shadcn for heavy inspiration and documentation\n * https://ui.shadcn.com/docs/components/combobox\n */\nfunction ComboBox({\n id,\n options = [],\n buttonClassName,\n popoverContentClassName,\n value,\n onChange = () => {},\n getOptionLabel = getOptionLabelDefault,\n buttonPlaceholder = '',\n textPlaceholder = '',\n commandEmptyMessage = 'No option found',\n buttonVariant = 'outline',\n dir = 'ltr',\n isDisabled = false,\n ...props\n}: ComboBoxProps) {\n const [open, setOpen] = useState(false);\n\n return (\n \n \n \n \n {value ? getOptionLabel(value) : buttonPlaceholder}\n \n \n \n \n \n \n \n {commandEmptyMessage}\n \n {options.map((option) => (\n {\n onChange(option);\n setOpen(false);\n }}\n >\n \n {getOptionLabel(option)}\n \n ))}\n \n \n \n \n );\n}\n\nexport default ComboBox;\n","import { useMemo } from 'react';\nimport ComboBox from '@/components/basics/combo-box.component';\nimport { Label } from '@/components/shadcn-ui/label';\n\nexport type ChapterRangeSelectorProps = {\n startChapter: number;\n endChapter: number;\n handleSelectStartChapter: (chapter: number) => void;\n handleSelectEndChapter: (chapter: number) => void;\n isDisabled?: boolean;\n chapterCount: number;\n};\n\nexport default function ChapterRangeSelector({\n startChapter,\n endChapter,\n handleSelectStartChapter,\n handleSelectEndChapter,\n isDisabled = false,\n chapterCount,\n}: ChapterRangeSelectorProps) {\n const chapterOptions = useMemo(\n () => Array.from({ length: chapterCount }, (_, index) => index + 1),\n [chapterCount],\n );\n\n const onChangeStartChapter = (value: number) => {\n handleSelectStartChapter(value);\n if (value > endChapter) {\n handleSelectEndChapter(value);\n }\n };\n\n const onChangeEndChapter = (value: number) => {\n handleSelectEndChapter(value);\n if (value < startChapter) {\n handleSelectStartChapter(value);\n }\n };\n\n return (\n <>\n \n option.toString()}\n value={startChapter}\n />\n\n \n option.toString()}\n value={endChapter}\n />\n \n );\n}\n","import { Button } from '@/components/shadcn-ui/button';\nimport { Label } from '@/components/shadcn-ui/label';\nimport { RadioGroup, RadioGroupItem } from '@/components/shadcn-ui/radio-group';\nimport { Canon } from '@sillsdev/scripture';\nimport { LocalizedStringValue } from 'platform-bible-utils';\nimport { useState } from 'react';\nimport ChapterRangeSelector, {\n ChapterRangeSelectorProps,\n} from '../basics/chapter-range-selector.component';\n\nexport enum BookSelectionMode {\n CURRENT_BOOK = 'current book',\n CHOOSE_BOOKS = 'choose books',\n}\n\n/**\n * Object containing all keys used for localization in this component. If you're using this\n * component in an extension, you can pass it into the useLocalizedStrings hook to easily obtain the\n * localized strings and pass them into the localizedStrings prop of this component\n */\nexport const BOOK_SELECTOR_STRING_KEYS = Object.freeze([\n '%webView_bookSelector_currentBook%',\n '%webView_bookSelector_choose%',\n '%webView_bookSelector_chooseBooks%',\n] as const);\n\nexport type BookSelectorLocalizedStrings = {\n [localizedInventoryKey in (typeof BOOK_SELECTOR_STRING_KEYS)[number]]?: LocalizedStringValue;\n};\n\n/**\n * Gets the localized value for the provided key\n *\n * @param strings Object containing localized string\n * @param key Key for a localized string\n * @returns The localized value for the provided key, if available. Returns the key if no localized\n * value is available\n */\nconst localizeString = (\n strings: BookSelectorLocalizedStrings,\n key: keyof BookSelectorLocalizedStrings,\n) => {\n return strings[key] ?? key;\n};\n\ntype BookSelectorProps = ChapterRangeSelectorProps & {\n handleBookSelectionModeChange: (newMode: BookSelectionMode) => void;\n currentBookName: string;\n onSelectBooks: () => void;\n selectedBookIds: string[];\n localizedStrings: BookSelectorLocalizedStrings;\n};\n\nexport default function BookSelector({\n handleBookSelectionModeChange,\n currentBookName,\n onSelectBooks,\n selectedBookIds,\n chapterCount,\n endChapter,\n handleSelectEndChapter,\n startChapter,\n handleSelectStartChapter,\n localizedStrings,\n}: BookSelectorProps) {\n const currentBookText = localizeString(localizedStrings, '%webView_bookSelector_currentBook%');\n const chooseText = localizeString(localizedStrings, '%webView_bookSelector_choose%');\n const chooseBooksText = localizeString(localizedStrings, '%webView_bookSelector_chooseBooks%');\n\n const [bookSelectionMode, setBookSelectionMode] = useState(\n BookSelectionMode.CURRENT_BOOK,\n );\n\n const onSelectionModeChange = (newMode: BookSelectionMode) => {\n setBookSelectionMode(newMode);\n handleBookSelectionModeChange(newMode);\n };\n\n return (\n onSelectionModeChange(value as BookSelectionMode)}\n >\n
    \n
    \n
    \n \n \n
    \n \n
    \n \n
    \n
    \n
    \n
    \n \n \n
    \n \n onSelectBooks()}\n >\n {chooseText}\n \n
    \n
    \n \n );\n}\n","import { DropdownMenuTrigger } from '@radix-ui/react-dropdown-menu';\nimport { FilterIcon } from 'lucide-react';\nimport { Table } from '@tanstack/react-table';\n\nimport { Button } from '@/components/shadcn-ui/button';\nimport {\n DropdownMenu,\n DropdownMenuCheckboxItem,\n DropdownMenuContent,\n DropdownMenuLabel,\n DropdownMenuSeparator,\n} from '@/components/shadcn-ui/dropdown-menu';\n\ninterface DataTableViewOptionsProps {\n table: Table;\n}\n\nfunction DataTableViewOptions({ table }: DataTableViewOptionsProps) {\n return (\n \n \n \n \n \n Toggle columns\n \n {table\n .getAllColumns()\n .filter((column) => column.getCanHide())\n .map((column) => {\n return (\n column.toggleVisibility(!!value)}\n >\n {column.id}\n \n );\n })}\n \n \n );\n}\n\nexport default DataTableViewOptions;\n","import React from 'react';\nimport * as SelectPrimitive from '@radix-ui/react-select';\nimport { Check, ChevronDown, ChevronUp } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Select = SelectPrimitive.Root;\n\nconst SelectGroup = SelectPrimitive.Group;\n\nconst SelectValue = SelectPrimitive.Value;\n\nconst SelectTrigger = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, ...props }, ref) => (\n span]:tw-line-clamp-1',\n className,\n )}\n {...props}\n >\n {children}\n \n \n \n \n));\nSelectTrigger.displayName = SelectPrimitive.Trigger.displayName;\n\nconst SelectScrollUpButton = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n));\nSelectScrollUpButton.displayName = SelectPrimitive.ScrollUpButton.displayName;\n\nconst SelectScrollDownButton = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n));\nSelectScrollDownButton.displayName = SelectPrimitive.ScrollDownButton.displayName;\n\nconst SelectContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, position = 'popper', ...props }, ref) => (\n \n \n \n \n {children}\n \n \n \n \n));\nSelectContent.displayName = SelectPrimitive.Content.displayName;\n\nconst SelectLabel = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSelectLabel.displayName = SelectPrimitive.Label.displayName;\n\nconst SelectItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, ...props }, ref) => (\n \n \n \n \n \n \n\n {children}\n \n));\nSelectItem.displayName = SelectPrimitive.Item.displayName;\n\nconst SelectSeparator = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSelectSeparator.displayName = SelectPrimitive.Separator.displayName;\n\nexport {\n Select,\n SelectGroup,\n SelectValue,\n SelectTrigger,\n SelectContent,\n SelectLabel,\n SelectItem,\n SelectSeparator,\n SelectScrollUpButton,\n SelectScrollDownButton,\n};\n","import { ChevronLeftIcon, ChevronRightIcon, ArrowLeftIcon, ArrowRightIcon } from 'lucide-react';\nimport { Table } from '@tanstack/react-table';\n\nimport { Button } from '@/components/shadcn-ui/button';\nimport {\n Select,\n SelectContent,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\n\ninterface DataTablePaginationProps {\n table: Table;\n}\n\nfunction DataTablePagination({ table }: DataTablePaginationProps) {\n return (\n
    \n
    \n
    \n {table.getFilteredSelectedRowModel().rows.length} of{' '}\n {table.getFilteredRowModel().rows.length} row(s) selected\n
    \n
    \n

    Rows per page

    \n {\n table.setPageSize(Number(value));\n }}\n >\n \n \n \n \n {[10, 20, 30, 40, 50].map((pageSize) => (\n \n {pageSize}\n \n ))}\n \n \n
    \n
    \n Page {table.getState().pagination.pageIndex + 1} of {table.getPageCount()}\n
    \n
    \n table.setPageIndex(0)}\n disabled={!table.getCanPreviousPage()}\n >\n Go to first page\n \n \n table.previousPage()}\n disabled={!table.getCanPreviousPage()}\n >\n Go to previous page\n \n \n table.nextPage()}\n disabled={!table.getCanNextPage()}\n >\n Go to next page\n \n \n table.setPageIndex(table.getPageCount() - 1)}\n disabled={!table.getCanNextPage()}\n >\n Go to last page\n \n \n
    \n
    \n
    \n );\n}\n\nexport default DataTablePagination;\n","import React from 'react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Table = React.forwardRef<\n HTMLTableElement,\n React.HTMLAttributes & { stickyHeader?: boolean }\n>(({ className, stickyHeader, ...props }, ref) => (\n
    \n \n
    \n));\nTable.displayName = 'Table';\n\nconst TableHeader = React.forwardRef<\n HTMLTableSectionElement,\n React.HTMLAttributes & { stickyHeader?: boolean }\n>(({ className, stickyHeader, ...props }, ref) => (\n \n));\nTableHeader.displayName = 'TableHeader';\n\nconst TableBody = React.forwardRef<\n HTMLTableSectionElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableBody.displayName = 'TableBody';\n\nconst TableFooter = React.forwardRef<\n HTMLTableSectionElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n tr]:last:tw-border-b-0', className)}\n {...props}\n />\n));\nTableFooter.displayName = 'TableFooter';\n\nconst TableRow = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nTableRow.displayName = 'TableRow';\n\nconst TableHead = React.forwardRef<\n HTMLTableCellElement,\n React.ThHTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableHead.displayName = 'TableHead';\n\nconst TableCell = React.forwardRef<\n HTMLTableCellElement,\n React.TdHTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableCell.displayName = 'TableCell';\n\nconst TableCaption = React.forwardRef<\n HTMLTableCaptionElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableCaption.displayName = 'TableCaption';\n\nexport { Table, TableHeader, TableBody, TableFooter, TableHead, TableRow, TableCell, TableCaption };\n","import { useState } from 'react';\n\nimport {\n ColumnFiltersState,\n flexRender,\n getCoreRowModel,\n getFilteredRowModel,\n getPaginationRowModel,\n getSortedRowModel,\n SortingState,\n ColumnDef as TSColumnDef,\n Row as TSRow,\n RowSelectionState as TSRowSelectionState,\n SortDirection as TSSortDirection,\n Table as TSTable,\n useReactTable,\n VisibilityState,\n} from '@tanstack/react-table';\n\nimport DataTableViewOptions from '@/components/advanced/data-table/data-table-column-toggle.component';\nimport DataTablePagination from '@/components/advanced/data-table/data-table-pagination.component';\nimport { Button } from '@/components/shadcn-ui/button';\nimport {\n Table,\n TableBody,\n TableCell,\n TableHead,\n TableHeader,\n TableRow,\n} from '@/components/shadcn-ui/table';\n\nexport type ColumnDef = TSColumnDef;\nexport type RowContents = TSRow;\nexport type TableContents = TSTable;\nexport type SortDirection = TSSortDirection;\nexport type RowSelectionState = TSRowSelectionState;\n\ninterface DataTableProps {\n columns: ColumnDef[];\n data: TData[];\n enablePagination?: boolean;\n showPaginationControls?: boolean;\n showColumnVisibilityControls?: boolean;\n stickyHeader?: boolean;\n onRowClickHandler?: (row: RowContents, table: TableContents) => void;\n}\n\n/**\n * Feature-rich table component that infuses our basic shadcn-based Table component with features\n * from TanStack's React Table library\n */\nfunction DataTable({\n columns,\n data,\n enablePagination = false,\n showPaginationControls = false,\n showColumnVisibilityControls = false,\n stickyHeader = false,\n onRowClickHandler = () => {},\n}: DataTableProps) {\n const [sorting, setSorting] = useState([]);\n const [columnFilters, setColumnFilters] = useState([]);\n const [columnVisibility, setColumnVisibility] = useState({});\n const [rowSelection, setRowSelection] = useState({});\n\n const table = useReactTable({\n data,\n columns,\n getCoreRowModel: getCoreRowModel(),\n ...(enablePagination && { getPaginationRowModel: getPaginationRowModel() }),\n onSortingChange: setSorting,\n getSortedRowModel: getSortedRowModel(),\n onColumnFiltersChange: setColumnFilters,\n getFilteredRowModel: getFilteredRowModel(),\n onColumnVisibilityChange: setColumnVisibility,\n onRowSelectionChange: setRowSelection,\n state: {\n sorting,\n columnFilters,\n columnVisibility,\n rowSelection,\n },\n });\n\n return (\n
    \n {showColumnVisibilityControls && }\n \n \n {table.getHeaderGroups().map((headerGroup) => (\n \n {headerGroup.headers.map((header) => {\n return (\n \n {header.isPlaceholder\n ? undefined\n : flexRender(header.column.columnDef.header, header.getContext())}\n \n );\n })}\n \n ))}\n \n \n {table.getRowModel().rows?.length ? (\n table.getRowModel().rows.map((row) => (\n onRowClickHandler(row, table)}\n key={row.id}\n data-state={row.getIsSelected() && 'selected'}\n >\n {row.getVisibleCells().map((cell) => (\n \n {flexRender(cell.column.columnDef.cell, cell.getContext())}\n \n ))}\n \n ))\n ) : (\n \n \n No results.\n \n \n )}\n \n
    \n {enablePagination && (\n
    \n table.previousPage()}\n disabled={!table.getCanPreviousPage()}\n >\n Previous\n \n table.nextPage()}\n disabled={!table.getCanNextPage()}\n >\n Next\n \n
    \n )}\n {enablePagination && showPaginationControls && }\n
    \n );\n}\n\nexport default DataTable;\n","import {\n Table,\n TableBody,\n TableCell,\n TableHead,\n TableHeader,\n TableRow,\n} from '@/components/shadcn-ui/table';\nimport { Canon } from '@sillsdev/scripture';\nimport { deepEqual, LanguageStrings, ScriptureReference } from 'platform-bible-utils';\nimport { useMemo } from 'react';\nimport { InventoryItemOccurrence } from './inventory-utils';\n\n/** Props for the OccurrencesTable component */\ntype OccurrencesTableProps = {\n /** Data that contains scriptures references and snippets of scripture */\n occurrenceData: InventoryItemOccurrence[];\n /** Callback function that is executed when the scripture reference is changed */\n setScriptureReference: (scriptureReference: ScriptureReference) => void;\n /**\n * Object with all localized strings that the OccurrencesTable needs to work well across multiple\n * languages\n */\n localizedStrings: LanguageStrings;\n};\n\n/**\n * Table that shows occurrences of specified inventory item(s). The first column shows the related\n * scripture reference. The second column shows the snippet of scripture that contains the specified\n * inventory item\n */\nfunction OccurrencesTable({\n occurrenceData,\n setScriptureReference,\n localizedStrings,\n}: OccurrencesTableProps) {\n const referenceHeaderText =\n localizedStrings['%webView_inventory_occurrences_table_header_reference%'];\n const occurrenceHeaderText =\n localizedStrings['%webView_inventory_occurrences_table_header_occurrence%'];\n\n const occurrences: InventoryItemOccurrence[] = useMemo(() => {\n const uniqueOccurrences: InventoryItemOccurrence[] = [];\n\n occurrenceData.forEach((occurrence) => {\n if (!uniqueOccurrences.some((uniqueOccurrence) => deepEqual(uniqueOccurrence, occurrence))) {\n uniqueOccurrences.push(occurrence);\n }\n });\n\n return uniqueOccurrences;\n }, [occurrenceData]);\n\n return (\n \n \n \n {referenceHeaderText}\n {occurrenceHeaderText}\n \n \n \n {occurrences.length > 0 &&\n occurrences.map((occurrence) => (\n {\n setScriptureReference(occurrence.reference);\n }}\n >\n {`${Canon.bookNumberToEnglishName(occurrence.reference.bookNum)} ${occurrence.reference.chapterNum}:${occurrence.reference.verseNum}`}\n {occurrence.text}\n \n ))}\n \n
    \n );\n}\n\nexport default OccurrencesTable;\n","import React from 'react';\nimport * as CheckboxPrimitive from '@radix-ui/react-checkbox';\nimport { Check } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Checkbox = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n \n \n));\nCheckbox.displayName = CheckboxPrimitive.Root.displayName;\n\nexport default Checkbox;\n","import { Canon } from '@sillsdev/scripture';\nimport { ScriptureReference } from 'platform-bible-utils';\n\n/* #region Types */\n\n/**\n * Status of items that appear in inventories. 'approved' and 'unapproved' items are defined in the\n * project's `Settings.xml`. All other items are defined as 'unknown'\n */\nexport type Status = 'approved' | 'unapproved' | 'unknown';\n\n/** Occurrence of item in inventory. Primarily used by table that shows occurrences */\nexport type InventoryItemOccurrence = {\n /** Reference to scripture where the item appears */\n reference: ScriptureReference;\n /** Snippet of scripture that contains the occurrence */\n text: string;\n};\n\n/** Data structure that contains all information on an item that is shown in an inventory */\nexport type InventoryTableData = {\n /**\n * The item (e.g. a character in the characters inventory, a marker in the marker inventory) In\n * most cases the array will only have one element. In case of additional items (e.g. the\n * preceding marker in the markers check), the primary item should be stored in the first index.\n * To show additional items in the inventory, make sure to configure the `additionalItemsLabels`\n * prop for the Inventory component\n */\n items: string[];\n /** The number of times this item occurs in the selected scope */\n count: number;\n /** The status of this item (see documentation for `Status` type for more information) */\n status: Status;\n /** Occurrences of this item in the scripture text for the selected scope */\n occurrences: InventoryItemOccurrence[];\n};\n\n/* #endregion */\n\n/* #region Functions */\n\n/**\n * Splits USFM string into shorter line-like segments\n *\n * @param text A single (likely very large) USFM string\n * @returns An array containing the input text, split into shorter segments\n */\nexport const getLinesFromUSFM = (text: string) => {\n // Splits on (CR)LF, CR, \\v, \\c and \\id\n return text.split(/(?:\\r?\\n|\\r)|(?=(?:\\\\(?:v|c|id)))/g);\n};\n\n/**\n * Extracts chapter or verse number from USFM strings that start with a \\c or \\v marker\n *\n * @param text USFM string that is expected to start with \\c or \\v marker\n * @returns Chapter or verse number if one is found. Else returns 0.\n */\nexport const getNumberFromUSFM = (text: string): number | undefined => {\n // Captures all digits that follow \\v or \\c markers followed by whitespace located at the start of a string\n const regex = /^\\\\[vc]\\s+(\\d+)/;\n const match = text.match(regex);\n\n if (match) {\n return +match[1];\n }\n return undefined;\n};\n\n/**\n * Gets book ID from USFM string that starts with the \\id marker, and returns book number for it\n *\n * @param text USFM string that is expected to start with \\id marker\n * @returns Book number corresponding to the \\id marker in the input text. Returns 0 if no marker is\n * found or the marker is not valid\n */\nexport const getBookNumFromId = (text: string): number => {\n // Captures all digits that follow an \\id marker followed by whitespace located at the start of a string\n const match = text.match(/^\\\\id\\s+([A-Za-z]+)/);\n if (match) {\n return Canon.bookIdToNumber(match[1]);\n }\n return 0;\n};\n\n/**\n * Gets the status for an item, typically used in the Inventory component\n *\n * @param item The item for which the status is being requested\n * @param approvedItems Array of approved items, typically as defined in `Settings.xml`\n * @param unapprovedItems Array of unapproved items, typically as defined in `Settings.xml`\n * @returns The status for the specified item\n */\nexport const getStatusForItem = (\n item: string,\n approvedItems: string[],\n unapprovedItems: string[],\n): Status => {\n if (unapprovedItems.includes(item)) return 'unapproved';\n if (approvedItems.includes(item)) return 'approved';\n return 'unknown';\n};\n\n/* #endregion */\n","import React from 'react';\nimport * as TogglePrimitive from '@radix-ui/react-toggle';\nimport { cva, type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst toggleVariants = cva(\n 'pr-twp tw-inline-flex tw-items-center tw-justify-center tw-rounded-md tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-colors hover:tw-bg-muted hover:tw-text-muted-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50 data-[state=on]:tw-bg-accent data-[state=on]:tw-text-accent-foreground',\n {\n variants: {\n variant: {\n default: 'tw-bg-transparent',\n outline:\n 'tw-border tw-border-input tw-bg-transparent hover:tw-bg-accent hover:tw-text-accent-foreground',\n },\n size: {\n default: 'tw-h-10 tw-px-3',\n sm: 'tw-h-9 tw-px-2.5',\n lg: 'tw-h-11 tw-px-5',\n },\n },\n defaultVariants: {\n variant: 'default',\n size: 'default',\n },\n },\n);\n\nconst Toggle = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef & VariantProps\n>(({ className, variant, size, ...props }, ref) => (\n \n));\n\nToggle.displayName = TogglePrimitive.Root.displayName;\n\nexport { Toggle, toggleVariants };\n","import React from 'react';\nimport * as ToggleGroupPrimitive from '@radix-ui/react-toggle-group';\nimport { type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { toggleVariants } from '@/components/shadcn-ui/toggle';\n\nconst ToggleGroupContext = React.createContext>({\n size: 'default',\n variant: 'default',\n});\n\nconst ToggleGroup = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef &\n VariantProps\n>(({ className, variant, size, children, ...props }, ref) => (\n \n \n {children}\n \n \n));\n\nToggleGroup.displayName = ToggleGroupPrimitive.Root.displayName;\n\nconst ToggleGroupItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef &\n VariantProps\n>(({ className, children, variant, size, ...props }, ref) => {\n const context = React.useContext(ToggleGroupContext);\n\n return (\n \n {children}\n \n );\n});\n\nToggleGroupItem.displayName = ToggleGroupPrimitive.Item.displayName;\n\nexport { ToggleGroup, ToggleGroupItem };\n","import { ColumnDef, SortDirection } from '@/components/advanced/data-table/data-table.component';\nimport { Button } from '@/components/shadcn-ui/button';\nimport { ToggleGroup, ToggleGroupItem } from '@/components/shadcn-ui/toggle-group';\nimport {\n ArrowDownIcon,\n ArrowUpDownIcon,\n ArrowUpIcon,\n CircleCheckIcon,\n CircleHelpIcon,\n CircleXIcon,\n} from 'lucide-react';\nimport { ReactNode } from 'react';\nimport { InventoryTableData, Status } from './inventory-utils';\n\n/**\n * Gets an icon that indicates the current sorting direction based on the provided input\n *\n * @param sortDirection Sorting direction. Can be ascending ('asc'), descending ('desc') or false (\n * i.e. not sorted)\n * @returns The appropriate sorting icon for the provided sorting direction\n */\nconst getSortingIcon = (sortDirection: false | SortDirection): ReactNode => {\n if (sortDirection === 'asc') {\n return ;\n }\n if (sortDirection === 'desc') {\n return ;\n }\n return ;\n};\n\n/**\n * Function that creates the item column for inventories\n *\n * @param itemLabel Localized label for the item column (e.g. 'Character', 'Repeated Word', etc.)\n * @returns Column that shows the inventory items. Should be used with the DataTable component\n */\nexport const inventoryItemColumn = (itemLabel: string): ColumnDef => {\n return {\n accessorKey: 'item',\n accessorFn: (row: InventoryTableData) => row.items[0],\n header: ({ column }) => (\n \n ),\n };\n};\n\n/**\n * Function that creates the additional item columns for inventories\n *\n * @param additionalItemLabel Localized label for the additional item column (e.g. 'Preceding\n * Marker')\n * @param additionalItemIndex Index that locates the desired item in the items array of the\n * inventory\n * @returns Column that shows additional inventory items. Should be used with the DataTable\n * component\n */\nexport const inventoryAdditionalItemColumn = (\n additionalItemLabel: string,\n additionalItemIndex: number,\n): ColumnDef => {\n return {\n accessorKey: `item${additionalItemIndex}`,\n accessorFn: (row: InventoryTableData) => row.items[additionalItemIndex],\n header: ({ column }) => (\n \n ),\n };\n};\n\n/**\n * Function that creates the count column for inventories. Should be used with the DataTable\n * component.\n *\n * @param itemLabel Localized label for the count column\n * @returns Column that shows the number of occurrences of the related inventory items\n */\nexport const inventoryCountColumn = (countLabel: string): ColumnDef => {\n return {\n accessorKey: 'count',\n header: ({ column }) => (\n
    \n \n
    \n ),\n cell: ({ row }) =>
    {row.getValue('count')}
    ,\n };\n};\n\n/**\n * Function that updates project settings when status for item(s) changes\n *\n * @param changedItems Array of items for which the status is being updated\n * @param newStatus The status that the items are being given\n * @param approvedItems Array of currently approved items\n * @param onApprovedItemsChange Callback function that stores the updated list of approved items\n * @param unapprovedItems Array of currently unapproved items\n * @param onUnapprovedItemsChange Callback function that stores the updated list of unapproved items\n */\nconst statusChangeHandler = (\n changedItems: string[],\n newStatus: Status,\n approvedItems: string[],\n onApprovedItemsChange: (items: string[]) => void,\n unapprovedItems: string[],\n onUnapprovedItemsChange: (items: string[]) => void,\n) => {\n let newApprovedItems: string[] = [...approvedItems];\n changedItems.forEach((item) => {\n if (newStatus === 'approved') {\n if (!newApprovedItems.includes(item)) {\n newApprovedItems.push(item);\n }\n } else {\n newApprovedItems = newApprovedItems.filter((validItem) => validItem !== item);\n }\n });\n onApprovedItemsChange(newApprovedItems);\n\n let newUnapprovedItems: string[] = [...unapprovedItems];\n changedItems.forEach((item) => {\n if (newStatus === 'unapproved') {\n if (!newUnapprovedItems.includes(item)) {\n newUnapprovedItems.push(item);\n }\n } else {\n newUnapprovedItems = newUnapprovedItems.filter((unapprovedItem) => unapprovedItem !== item);\n }\n });\n onUnapprovedItemsChange(newUnapprovedItems);\n};\n\n/**\n * Function that creates the status column for inventories. Should be used with the DataTable\n * component.\n *\n * @param statusLabel Localized label for the status column\n * @param approvedItems Array of approved items, typically as defined in `Settings.xml`\n * @param onApprovedItemsChange Callback function that stores the updated list of approved items\n * @param unapprovedItems Array of unapproved items, typically as defined in `Settings.xml`\n * @param onUnapprovedItemsChange Callback function that stores the updated list of unapproved items\n * @returns Column that shows the status buttons for the related inventory item. The button for the\n * current status of the item is selected\n */\nexport const inventoryStatusColumn = (\n statusLabel: string,\n approvedItems: string[],\n onApprovedItemsChange: (items: string[]) => void,\n unapprovedItems: string[],\n onUnapprovedItemsChange: (items: string[]) => void,\n): ColumnDef => {\n return {\n accessorKey: 'status',\n header: ({ column }) => {\n return (\n
    \n \n
    \n );\n },\n cell: ({ row }) => {\n const status: Status = row.getValue('status');\n const item: string = row.getValue('item');\n return (\n \n \n statusChangeHandler(\n [item],\n 'approved',\n approvedItems,\n onApprovedItemsChange,\n unapprovedItems,\n onUnapprovedItemsChange,\n )\n }\n value=\"approved\"\n >\n \n \n \n statusChangeHandler(\n [item],\n 'unapproved',\n approvedItems,\n onApprovedItemsChange,\n unapprovedItems,\n onUnapprovedItemsChange,\n )\n }\n value=\"unapproved\"\n >\n \n \n \n statusChangeHandler(\n [item],\n 'unknown',\n approvedItems,\n onApprovedItemsChange,\n unapprovedItems,\n onUnapprovedItemsChange,\n )\n }\n value=\"unknown\"\n >\n \n \n \n );\n },\n };\n};\n","import DataTable, {\n ColumnDef,\n RowContents,\n RowSelectionState,\n TableContents,\n} from '@/components/advanced/data-table/data-table.component';\nimport OccurrencesTable from '@/components/advanced/inventory/occurrences-table.component';\nimport Checkbox from '@/components/shadcn-ui/checkbox';\nimport { Input } from '@/components/shadcn-ui/input';\nimport { Label } from '@/components/shadcn-ui/label';\nimport {\n Select,\n SelectContent,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\nimport {\n deepEqual,\n LocalizedStringValue,\n ScriptureReference,\n substring,\n} from 'platform-bible-utils';\nimport { useEffect, useMemo, useState } from 'react';\nimport {\n getBookNumFromId,\n getLinesFromUSFM,\n getNumberFromUSFM,\n getStatusForItem,\n InventoryItemOccurrence,\n InventoryTableData,\n Status,\n} from './inventory-utils';\nimport { inventoryAdditionalItemColumn } from './inventory-columns';\n\n/**\n * Object containing all keys used for localization in this component. If you're using this\n * component in an extension, you can pass it into the useLocalizedStrings hook to easily obtain the\n * localized strings and pass them into the localizedStrings prop of this component\n */\nexport const INVENTORY_STRING_KEYS = Object.freeze([\n '%webView_inventory_all%',\n '%webView_inventory_approved%',\n '%webView_inventory_unapproved%',\n '%webView_inventory_unknown%',\n '%webView_inventory_scope_currentBook%',\n '%webView_inventory_scope_chapter%',\n '%webView_inventory_scope_verse%',\n '%webView_inventory_filter_text%',\n '%webView_inventory_show_additional_items%',\n '%webView_inventory_occurrences_table_header_reference%',\n '%webView_inventory_occurrences_table_header_occurrence%',\n] as const);\n\nexport type InventoryLocalizedStrings = {\n [localizedInventoryKey in (typeof INVENTORY_STRING_KEYS)[number]]?: LocalizedStringValue;\n};\n\n/** Scope of scripture that the inventory can operate on */\nexport type Scope = 'book' | 'chapter' | 'verse';\n\n/** Status values that the status filter can select from */\ntype StatusFilter = Status | 'all';\n\n/** Text labels for the inventory columns and the control components of additional inventory items */\ntype AdditionalItemsLabels = {\n checkboxText?: string;\n tableHeaders?: string[];\n};\n\n/**\n * Filters data that is shown in the DataTable section of the Inventory\n *\n * @param itemData All inventory items and their related information\n * @param statusFilter Allows filtering by status (i.e. show all items, or only items that are\n * 'approved', 'unapproved' or 'unknown')\n * @param textFilter Allows filtering by text. All items that include the filter text will be\n * selected.\n * @returns Array of items and their related information that are matched by the specified filters\n */\nconst filterItemData = (\n itemData: InventoryTableData[],\n statusFilter: StatusFilter,\n textFilter: string,\n): InventoryTableData[] => {\n let filteredItemData: InventoryTableData[] = itemData;\n\n if (statusFilter !== 'all') {\n filteredItemData = filteredItemData.filter(\n (item) =>\n (statusFilter === 'approved' && item.status === 'approved') ||\n (statusFilter === 'unapproved' && item.status === 'unapproved') ||\n (statusFilter === 'unknown' && item.status === 'unknown'),\n );\n }\n\n if (textFilter !== '')\n filteredItemData = filteredItemData.filter((item) => item.items[0].includes(textFilter));\n\n return filteredItemData;\n};\n\n/**\n * Turns array of strings into array of inventory items, along with their count and status\n *\n * @param text The source scripture text that is searched for inventory items\n * @param scriptureRef The scripture reference that the application is currently set to\n * @param approvedItems Array of approved items, typically as defined in `Settings.xml`\n * @param unapprovedItems Array of unapproved items, typically as defined in `Settings.xml`\n * @param itemRegex Regular expression that describes what items this Inventory should extract from\n * the provided scripture text\n * @returns Array of inventory items, along with their count and status\n */\nconst createTableData = (\n text: string | undefined,\n scriptureRef: ScriptureReference,\n approvedItems: string[],\n unapprovedItems: string[],\n itemRegex: RegExp,\n): InventoryTableData[] => {\n if (!text) return [];\n\n const tableData: InventoryTableData[] = [];\n\n let currentBook: number | undefined = scriptureRef.bookNum;\n let currentChapter: number | undefined = scriptureRef.chapterNum;\n let currentVerse: number | undefined = scriptureRef.verseNum;\n\n const lines = getLinesFromUSFM(text);\n\n lines.forEach((line: string) => {\n if (line.startsWith('\\\\id')) {\n currentBook = getBookNumFromId(line);\n currentChapter = 0;\n currentVerse = 0;\n }\n if (line.startsWith('\\\\c')) {\n currentChapter = getNumberFromUSFM(line);\n currentVerse = 0;\n }\n if (line.startsWith('\\\\v')) {\n currentVerse = getNumberFromUSFM(line);\n if (currentChapter === 0) {\n currentChapter = scriptureRef.chapterNum;\n }\n }\n\n let match: RegExpExecArray | undefined = itemRegex.exec(line) ?? undefined;\n while (match) {\n const items: string[] = [];\n match.forEach((item) => items.push(item));\n const itemIndex = match.index;\n const existingItem = tableData.find((tableEntry) => deepEqual(tableEntry.items, items));\n const newReference: InventoryItemOccurrence = {\n reference: {\n bookNum: currentBook !== undefined ? currentBook : -1,\n chapterNum: currentChapter !== undefined ? currentChapter : -1,\n verseNum: currentVerse !== undefined ? currentVerse : -1,\n },\n text: substring(line, Math.max(0, itemIndex - 25), Math.min(itemIndex + 25, line.length)),\n };\n if (existingItem) {\n existingItem.count += 1;\n existingItem.occurrences.push(newReference);\n } else {\n const newItem: InventoryTableData = {\n items,\n count: 1,\n status: getStatusForItem(items[0], approvedItems, unapprovedItems),\n occurrences: [newReference],\n };\n tableData.push(newItem);\n }\n\n match = itemRegex.exec(line) ?? undefined;\n }\n });\n\n return tableData;\n};\n\n/**\n * Gets the localized value for the provided key\n *\n * @param strings Object containing localized string\n * @param key Key for a localized string\n * @returns The localized value for the provided key, if available. Returns the key if no localized\n * value is available\n */\nconst localizeString = (\n strings: InventoryLocalizedStrings,\n key: keyof InventoryLocalizedStrings,\n) => {\n return strings[key] ?? key;\n};\n\n/** Props for the Inventory component */\ntype InventoryProps = {\n /** The scripture reference that the application is currently set to */\n scriptureReference: ScriptureReference;\n /** Callback function that is executed when the scripture reference is changed */\n setScriptureReference: (scriptureReference: ScriptureReference) => void;\n /**\n * Object with all localized strings that the Inventory needs to work well across multiple\n * languages. When using this component with Platform.Bible, you can import\n * `INVENTORY_STRING_KEYS` from this library, pass it in to the Platform's localization hook, and\n * pass the localized keys that are returned by the hook into this prop.\n */\n localizedStrings: InventoryLocalizedStrings;\n /**\n * The logic that finds the desired items in the source text. This can either be a Regular\n * expression that captures one or multiple items (preferred), or a custom function that builds\n * and return an InventoryDataTable[] manually. Note: In case the logic captures more than one\n * item (i.e. InventoryTableData.items has a length greater than 1), you must provide text labels\n * for the related columns and control elements to show by setting the `additionalItemsLabels`\n * prop\n */\n extractItems:\n | RegExp\n | ((\n text: string | undefined,\n scriptureRef: ScriptureReference,\n approvedItems: string[],\n unapprovedItems: string[],\n ) => InventoryTableData[]);\n /**\n * Text labels for control elements and additional column headers in case your Inventory has more\n * than one item to show (e.g. The 'Preceding Marker' in the Markers Inventory)\n */\n additionalItemsLabels?: AdditionalItemsLabels;\n /** Array of approved items, typically as defined in `Settings.xml` */\n approvedItems: string[];\n /** Array of unapproved items, typically as defined in `Settings.xml` */\n unapprovedItems: string[];\n /** The source scripture text that is searched for in inventory items */\n text: string | undefined;\n /** Scope of scripture that the inventory will operate on */\n scope: Scope;\n /** Callback function that is executed when the scope is changed from the Inventory */\n onScopeChange: (scope: Scope) => void;\n /**\n * Column definitions for the Inventory data table. The most commonly used column definitions are\n * pre-configured for your convenience and can be imported (e.g. inventoryItemColumn,\n * inventoryAdditionalItemColumn inventoryCountColumn, and inventoryStatusColumn). If you need any\n * other columns you can add these yourself\n */\n columns: ColumnDef[];\n};\n\n/** Inventory component that is used to view and control the status of provided project settings */\nexport default function Inventory({\n scriptureReference,\n setScriptureReference,\n localizedStrings,\n extractItems,\n additionalItemsLabels,\n approvedItems,\n unapprovedItems,\n text,\n scope,\n onScopeChange,\n columns,\n}: InventoryProps) {\n const allItemsText = localizeString(localizedStrings, '%webView_inventory_all%');\n const approvedItemsText = localizeString(localizedStrings, '%webView_inventory_approved%');\n const unapprovedItemsText = localizeString(localizedStrings, '%webView_inventory_unapproved%');\n const unknownItemsText = localizeString(localizedStrings, '%webView_inventory_unknown%');\n const scopeBookText = localizeString(localizedStrings, '%webView_inventory_scope_currentBook%');\n const scopeChapterText = localizeString(localizedStrings, '%webView_inventory_scope_chapter%');\n const scopeVerseText = localizeString(localizedStrings, '%webView_inventory_scope_verse%');\n const filterText = localizeString(localizedStrings, '%webView_inventory_filter_text%');\n const showAdditionalItemsText = localizeString(\n localizedStrings,\n '%webView_inventory_show_additional_items%',\n );\n\n const [showAdditionalItems, setShowAdditionalItems] = useState(false);\n const [statusFilter, setStatusFilter] = useState('all');\n const [textFilter, setTextFilter] = useState('');\n const [selectedItem, setSelectedItem] = useState([]);\n\n const tableData: InventoryTableData[] = useMemo(() => {\n if (!text) return [];\n if (extractItems instanceof RegExp)\n return createTableData(\n text,\n scriptureReference,\n approvedItems,\n unapprovedItems,\n extractItems,\n );\n return extractItems(text, scriptureReference, approvedItems, unapprovedItems);\n }, [text, extractItems, scriptureReference, approvedItems, unapprovedItems]);\n\n const reducedTableData: InventoryTableData[] = useMemo(() => {\n if (showAdditionalItems) return tableData;\n\n const newTableData: InventoryTableData[] = [];\n\n tableData.forEach((tableEntry) => {\n const firstItem = tableEntry.items[0];\n\n const existingEntry = newTableData.find(\n (newTableEntry) => newTableEntry.items[0] === firstItem,\n );\n\n if (existingEntry) {\n existingEntry.count += tableEntry.count;\n existingEntry.occurrences = existingEntry.occurrences.concat(tableEntry.occurrences);\n } else {\n newTableData.push({\n items: [firstItem],\n count: tableEntry.count,\n occurrences: tableEntry.occurrences,\n status: tableEntry.status,\n });\n }\n });\n\n return newTableData;\n }, [showAdditionalItems, tableData]);\n\n const filteredTableData: InventoryTableData[] = useMemo(() => {\n return filterItemData(reducedTableData, statusFilter, textFilter);\n }, [reducedTableData, statusFilter, textFilter]);\n\n const allColumns: ColumnDef[] = useMemo(() => {\n if (!showAdditionalItems) return columns;\n\n const numberOfAdditionalItems = additionalItemsLabels?.tableHeaders?.length;\n if (!numberOfAdditionalItems) return columns;\n\n const additionalColumns: ColumnDef[] = [];\n\n for (let index = 0; index < numberOfAdditionalItems; index++) {\n additionalColumns.push(\n inventoryAdditionalItemColumn(\n additionalItemsLabels?.tableHeaders?.[index] || 'Additional Item',\n index + 1,\n ),\n );\n }\n\n return [...additionalColumns, ...columns];\n }, [additionalItemsLabels?.tableHeaders, columns, showAdditionalItems]);\n\n useEffect(() => {\n setSelectedItem([]);\n }, [filteredTableData]);\n\n const rowClickHandler = (\n row: RowContents,\n table: TableContents,\n ) => {\n table.setRowSelection(() => {\n const newSelection: RowSelectionState = {};\n newSelection[row.index] = true;\n return newSelection;\n });\n\n setSelectedItem(row.original.items);\n };\n\n const handleScopeChange = (value: string) => {\n if (value === 'book' || value === 'chapter' || value === 'verse') {\n onScopeChange(value);\n } else {\n throw new Error(`Invalid scope value: ${value}`);\n }\n };\n\n const handleStatusFilterChange = (value: string) => {\n if (value === 'all' || value === 'approved' || value === 'unapproved' || value === 'unknown') {\n setStatusFilter(value);\n } else {\n throw new Error(`Invalid status filter value: ${value}`);\n }\n };\n\n const occurrenceData: InventoryItemOccurrence[] = useMemo(() => {\n if (reducedTableData.length === 0 || selectedItem.length === 0) return [];\n const occurrence = reducedTableData.filter((tableEntry: InventoryTableData) => {\n return deepEqual(\n showAdditionalItems ? tableEntry.items : [tableEntry.items[0]],\n selectedItem,\n );\n });\n if (occurrence.length > 1) throw new Error('Selected item is not unique');\n return occurrence[0].occurrences;\n }, [selectedItem, showAdditionalItems, reducedTableData]);\n\n return (\n
    \n
    \n handleStatusFilterChange(value)}\n defaultValue={statusFilter}\n >\n \n \n \n \n {allItemsText}\n {approvedItemsText}\n {unapprovedItemsText}\n {unknownItemsText}\n \n \n \n {\n setTextFilter(event.target.value);\n }}\n />\n {additionalItemsLabels && (\n
    \n {\n setSelectedItem([]);\n setShowAdditionalItems(checked);\n }}\n />\n \n
    \n )}\n
    \n
    \n \n
    \n {occurrenceData.length > 0 && (\n
    \n \n
    \n )}\n
    \n );\n}\n","import { Input } from '@/components/shadcn-ui/input';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { useState } from 'react';\n\nexport type SearchBarProps = {\n className?: string;\n /**\n * Callback fired to handle the search query when button pressed\n *\n * @param searchQuery\n */\n onSearch: (searchQuery: string) => void;\n\n /** Optional string that appears in the search bar without a search string */\n placeholder?: string;\n\n /** Optional boolean to set the input base to full width */\n isFullWidth?: boolean;\n};\n\nexport default function SearchBar({\n className,\n onSearch,\n placeholder,\n isFullWidth,\n}: SearchBarProps) {\n const [searchQuery, setSearchQuery] = useState('');\n\n const handleInputChange = (searchString: string) => {\n setSearchQuery(searchString);\n onSearch(searchString);\n };\n\n return (\n handleInputChange(e.target.value)}\n />\n );\n}\n","// adapted from: https://github.com/shadcn-ui/ui/discussions/752\n\n'use client';\n\nimport { TabsContentProps, TabsListProps, TabsTriggerProps } from '@/components/shadcn-ui/tabs';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport * as TabsPrimitive from '@radix-ui/react-tabs';\nimport React from 'react';\n\nexport type VerticalTabsProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport type LeftTabsTriggerProps = TabsTriggerProps & {\n value: string;\n ref?: React.Ref;\n};\n\nexport const VerticalTabs = React.forwardRef<\n React.ElementRef,\n VerticalTabsProps\n>(({ className, ...props }, ref) => (\n \n));\n\nVerticalTabs.displayName = TabsPrimitive.List.displayName;\n\nexport const VerticalTabsList = React.forwardRef<\n React.ElementRef,\n TabsListProps\n>(({ className, ...props }, ref) => (\n \n));\nVerticalTabsList.displayName = TabsPrimitive.List.displayName;\n\nexport const VerticalTabsTrigger = React.forwardRef<\n React.ElementRef,\n LeftTabsTriggerProps\n>(({ className, ...props }, ref) => (\n \n));\n\nexport const VerticalTabsContent = React.forwardRef<\n React.ElementRef,\n TabsContentProps\n>(({ className, ...props }, ref) => (\n \n));\nVerticalTabsContent.displayName = TabsPrimitive.Content.displayName;\n","import SearchBar from '@/components/basics/search-bar.component';\nimport {\n VerticalTabs,\n VerticalTabsContent,\n VerticalTabsList,\n VerticalTabsTrigger,\n} from '@/components/basics/tabs-vertical';\nimport { ReactNode } from 'react';\n\nexport type TabKeyValueContent = {\n key: string;\n value: string;\n content: ReactNode;\n};\n\nexport type TabNavigationContentSearchProps = {\n /** List of values and keys for each tab this component should provide */\n tabList: TabKeyValueContent[];\n\n /** Handler to run when the value of the search bar changes */\n onSearch: (searchQuery: string) => void;\n\n /** Optional placeholder for the search bar */\n searchPlaceholder?: string;\n\n /** Optional title to include in the header */\n headerTitle?: string;\n\n /** Optional flag to make the search bar appear full width */\n isSearchBarFullWidth?: boolean;\n\n /** Text direction ltr or rtl */\n direction?: 'ltr' | 'rtl';\n};\n\nexport default function TabNavigationContentSearch({\n tabList,\n onSearch,\n searchPlaceholder,\n headerTitle,\n isSearchBarFullWidth = false,\n direction = 'ltr',\n}: TabNavigationContentSearchProps) {\n return (\n
    \n
    \n {headerTitle ?

    {headerTitle}

    : ''}\n \n
    \n \n \n {tabList.map((tab) => (\n \n {tab.value}\n \n ))}\n \n {tabList.map((tab) => (\n \n {tab.content}\n \n ))}\n \n
    \n );\n}\n","import React from 'react';\nimport * as SeparatorPrimitive from '@radix-ui/react-separator';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Separator = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, orientation = 'horizontal', decorative = true, ...props }, ref) => (\n \n));\nSeparator.displayName = SeparatorPrimitive.Root.displayName;\n\nexport { Separator };\n","'use client';\n\nimport * as React from 'react';\nimport * as SheetPrimitive from '@radix-ui/react-dialog';\nimport { cva, type VariantProps } from 'class-variance-authority';\nimport { X } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Sheet = SheetPrimitive.Root;\n\nconst SheetTrigger = SheetPrimitive.Trigger;\n\nconst SheetClose = SheetPrimitive.Close;\n\nconst SheetPortal = SheetPrimitive.Portal;\n\nconst SheetOverlay = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSheetOverlay.displayName = SheetPrimitive.Overlay.displayName;\n\nconst sheetVariants = cva(\n 'pr-twp tw-fixed tw-z-50 tw-gap-4 tw-bg-background tw-p-6 tw-shadow-lg tw-transition tw-ease-in-out data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-duration-300 data-[state=open]:tw-duration-500',\n {\n variants: {\n side: {\n top: 'tw-inset-x-0 tw-top-0 tw-border-b data-[state=closed]:tw-slide-out-to-top data-[state=open]:tw-slide-in-from-top',\n bottom:\n 'tw-inset-x-0 tw-bottom-0 tw-border-t data-[state=closed]:tw-slide-out-to-bottom data-[state=open]:tw-slide-in-from-bottom',\n left: 'tw-inset-y-0 tw-left-0 tw-h-full tw-w-3/4 tw-border-r data-[state=closed]:tw-slide-out-to-left data-[state=open]:tw-slide-in-from-left sm:tw-max-w-sm',\n right:\n 'tw-inset-y-0 tw-right-0 tw-h-full tw-w-3/4 tw- tw-border-l data-[state=closed]:tw-slide-out-to-right data-[state=open]:tw-slide-in-from-right sm:tw-max-w-sm',\n },\n },\n defaultVariants: {\n side: 'right',\n },\n },\n);\n\ninterface SheetContentProps\n extends React.ComponentPropsWithoutRef,\n VariantProps {}\n\nconst SheetContent = React.forwardRef<\n React.ElementRef,\n SheetContentProps\n>(({ side = 'right', className, children, ...props }, ref) => (\n \n \n \n {children}\n \n \n Close\n \n \n \n));\nSheetContent.displayName = SheetPrimitive.Content.displayName;\n\nfunction SheetHeader({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nSheetHeader.displayName = 'SheetHeader';\n\nfunction SheetFooter({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nSheetFooter.displayName = 'SheetFooter';\n\nconst SheetTitle = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSheetTitle.displayName = SheetPrimitive.Title.displayName;\n\nconst SheetDescription = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSheetDescription.displayName = SheetPrimitive.Description.displayName;\n\nexport {\n Sheet,\n SheetPortal,\n SheetOverlay,\n SheetTrigger,\n SheetClose,\n SheetContent,\n SheetHeader,\n SheetFooter,\n SheetTitle,\n SheetDescription,\n};\n","import React from 'react';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nfunction Skeleton({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\n\nexport { Skeleton };\n","import React from 'react';\nimport * as TooltipPrimitive from '@radix-ui/react-tooltip';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst TooltipProvider = TooltipPrimitive.Provider;\n\nconst Tooltip = TooltipPrimitive.Root;\n\nconst TooltipTrigger = TooltipPrimitive.Trigger;\n\nconst TooltipContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, sideOffset = 4, ...props }, ref) => (\n \n));\nTooltipContent.displayName = TooltipPrimitive.Content.displayName;\n\nexport { Tooltip, TooltipTrigger, TooltipContent, TooltipProvider };\n","import * as React from 'react';\n\nconst MOBILE_BREAKPOINT = 768;\n\nexport default function useIsMobile() {\n const [isMobile, setIsMobile] = React.useState(undefined);\n\n React.useEffect(() => {\n const mql = window.matchMedia(`(max-width: ${MOBILE_BREAKPOINT - 1}px)`);\n const onChange = () => {\n setIsMobile(window.innerWidth < MOBILE_BREAKPOINT);\n };\n mql.addEventListener('change', onChange);\n setIsMobile(window.innerWidth < MOBILE_BREAKPOINT);\n return () => mql.removeEventListener('change', onChange);\n }, []);\n\n return !!isMobile;\n}\n","import React from 'react';\nimport { Slot } from '@radix-ui/react-slot';\nimport { VariantProps, cva } from 'class-variance-authority';\nimport { PanelLeft } from 'lucide-react';\n\nimport { Button } from '@/components/shadcn-ui/button';\nimport { Input } from '@/components/shadcn-ui/input';\nimport { Separator } from '@/components/shadcn-ui/separator';\nimport { Sheet, SheetContent } from '@/components/shadcn-ui/sheet';\nimport { Skeleton } from '@/components/shadcn-ui/skeleton';\nimport {\n Tooltip,\n TooltipContent,\n TooltipProvider,\n TooltipTrigger,\n} from '@/components/shadcn-ui/tooltip';\nimport useIsMobile from '@/components/hooks/use-mobile';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst SIDEBAR_COOKIE_NAME = 'sidebar:state';\nconst SIDEBAR_COOKIE_MAX_AGE = 60 * 60 * 24 * 7;\nconst SIDEBAR_WIDTH = '16rem';\nconst SIDEBAR_WIDTH_MOBILE = '18rem';\nconst SIDEBAR_WIDTH_ICON = '3rem';\nconst SIDEBAR_KEYBOARD_SHORTCUT = 'b';\n\ntype SidebarContextProps = {\n state: 'expanded' | 'collapsed';\n open: boolean;\n setOpen: (open: boolean) => void;\n openMobile: boolean;\n setOpenMobile: (open: boolean) => void;\n isMobile: boolean;\n toggleSidebar: () => void;\n};\n\nconst SidebarContext = React.createContext(undefined);\n\nfunction useSidebar() {\n const context = React.useContext(SidebarContext);\n if (!context) {\n throw new Error('useSidebar must be used within a SidebarProvider.');\n }\n\n return context;\n}\n\nconst SidebarProvider = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & {\n defaultOpen?: boolean;\n open?: boolean;\n onOpenChange?: (open: boolean) => void;\n }\n>(\n (\n {\n defaultOpen = true,\n open: openProp,\n onOpenChange: setOpenProp,\n className,\n style,\n children,\n ...props\n },\n ref,\n ) => {\n const isMobile = useIsMobile();\n const [openMobile, setOpenMobile] = React.useState(false);\n\n // This is the internal state of the sidebar.\n // We use openProp and setOpenProp for control from outside the component.\n const [_open, _setOpen] = React.useState(defaultOpen);\n const isOpen = openProp ?? _open;\n const setOpen = React.useCallback(\n (value: boolean | ((value: boolean) => boolean)) => {\n const openState = typeof value === 'function' ? value(isOpen) : value;\n if (setOpenProp) {\n setOpenProp(openState);\n } else {\n _setOpen(openState);\n }\n\n // This sets the cookie to keep the sidebar state.\n document.cookie = `${SIDEBAR_COOKIE_NAME}=${openState}; path=/; max-age=${SIDEBAR_COOKIE_MAX_AGE}`;\n },\n [setOpenProp, isOpen],\n );\n\n // Helper to toggle the sidebar.\n const toggleSidebar = React.useCallback(() => {\n return isMobile ? setOpenMobile((open) => !open) : setOpen((open) => !open);\n }, [isMobile, setOpen, setOpenMobile]);\n\n // Adds a keyboard shortcut to toggle the sidebar.\n React.useEffect(() => {\n const handleKeyDown = (event: KeyboardEvent) => {\n if (event.key === SIDEBAR_KEYBOARD_SHORTCUT && (event.metaKey || event.ctrlKey)) {\n event.preventDefault();\n toggleSidebar();\n }\n };\n\n window.addEventListener('keydown', handleKeyDown);\n return () => window.removeEventListener('keydown', handleKeyDown);\n }, [toggleSidebar]);\n\n // We add a state so that we can do data-state=\"expanded\" or \"collapsed\".\n // This makes it easier to style the sidebar with Tailwind classes.\n const state = isOpen ? 'expanded' : 'collapsed';\n\n const contextValue = React.useMemo(\n () => ({\n state,\n open: isOpen,\n setOpen,\n isMobile,\n openMobile,\n setOpenMobile,\n toggleSidebar,\n }),\n [state, isOpen, setOpen, isMobile, openMobile, setOpenMobile, toggleSidebar],\n );\n\n return (\n \n \n \n {children}\n
    \n \n \n );\n },\n);\nSidebarProvider.displayName = 'SidebarProvider';\n\nconst Sidebar = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & {\n side?: 'left' | 'right';\n variant?: 'sidebar' | 'floating' | 'inset';\n collapsible?: 'offcanvas' | 'icon' | 'none';\n }\n>(\n (\n {\n side = 'left',\n variant = 'sidebar',\n collapsible = 'offcanvas',\n className,\n children,\n ...props\n },\n ref,\n ) => {\n const { isMobile, state, openMobile, setOpenMobile } = useSidebar();\n\n if (collapsible === 'none') {\n return (\n \n {children}\n
    \n );\n }\n\n if (isMobile) {\n return (\n \n button]:tw-hidden\"\n style={\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n {\n '--sidebar-width': SIDEBAR_WIDTH_MOBILE,\n } as React.CSSProperties\n }\n side={side}\n >\n
    {children}
    \n \n
    \n );\n }\n\n return (\n \n {/* This is what handles the sidebar gap on desktop */}\n \n \n \n {children}\n
    \n
    \n
    \n );\n },\n);\nSidebar.displayName = 'Sidebar';\n\nconst SidebarTrigger = React.forwardRef<\n React.ElementRef,\n React.ComponentProps\n>(({ className, onClick, ...props }, ref) => {\n const { toggleSidebar } = useSidebar();\n\n return (\n {\n onClick?.(event);\n toggleSidebar();\n }}\n {...props}\n >\n \n Toggle Sidebar\n \n );\n});\nSidebarTrigger.displayName = 'SidebarTrigger';\n\nconst SidebarRail = React.forwardRef>(\n ({ className, ...props }, ref) => {\n const { toggleSidebar } = useSidebar();\n\n return (\n \n );\n },\n);\nSidebarRail.displayName = 'SidebarRail';\n\nconst SidebarInset = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarInset.displayName = 'SidebarInset';\n\nconst SidebarInput = React.forwardRef<\n React.ElementRef,\n React.ComponentProps\n>(({ className, ...props }, ref) => {\n return (\n \n );\n});\nSidebarInput.displayName = 'SidebarInput';\n\nconst SidebarHeader = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarHeader.displayName = 'SidebarHeader';\n\nconst SidebarFooter = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarFooter.displayName = 'SidebarFooter';\n\nconst SidebarSeparator = React.forwardRef<\n React.ElementRef,\n React.ComponentProps\n>(({ className, ...props }, ref) => {\n return (\n \n );\n});\nSidebarSeparator.displayName = 'SidebarSeparator';\n\nconst SidebarContent = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarContent.displayName = 'SidebarContent';\n\nconst SidebarGroup = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarGroup.displayName = 'SidebarGroup';\n\nconst SidebarGroupLabel = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & { asChild?: boolean }\n>(({ className, asChild = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'div';\n\n return (\n svg]:tw-size-4 [&>svg]:tw-shrink-0',\n 'group-data-[collapsible=icon]:tw--mt-8 group-data-[collapsible=icon]:tw-opacity-0',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarGroupLabel.displayName = 'SidebarGroupLabel';\n\nconst SidebarGroupAction = React.forwardRef<\n HTMLButtonElement,\n React.ComponentProps<'button'> & { asChild?: boolean }\n>(({ className, asChild = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'button';\n\n return (\n svg]:tw-size-4 [&>svg]:tw-shrink-0',\n // Increases the hit area of the button on mobile.\n 'after:tw-absolute after:tw--inset-2 after:md:tw-hidden',\n 'group-data-[collapsible=icon]:tw-hidden',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarGroupAction.displayName = 'SidebarGroupAction';\n\nconst SidebarGroupContent = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarGroupContent.displayName = 'SidebarGroupContent';\n\nconst SidebarMenu = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenu.displayName = 'SidebarMenu';\n\nconst SidebarMenuItem = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenuItem.displayName = 'SidebarMenuItem';\n\nconst sidebarMenuButtonVariants = cva(\n // Removed data-[active=true]:tw-bg-sidebar-accent\n 'tw-peer/menu-button tw-flex tw-w-full tw-items-center tw-gap-2 tw-overflow-hidden tw-rounded-md tw-p-2 tw-text-left tw-text-sm tw-outline-none tw-ring-sidebar-ring tw-transition-[width,height,padding] hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground focus-visible:tw-ring-2 active:tw-bg-sidebar-accent active:tw-text-sidebar-accent-foreground disabled:tw-pointer-events-none disabled:tw-opacity-50 tw-group-has-[[data-sidebar=menu-action]]/menu-item:pr-8 aria-disabled:tw-pointer-events-none aria-disabled:tw-opacity-50 data-[active=true]:tw-font-medium data-[active=true]:tw-text-sidebar-accent-foreground data-[state=open]:hover:tw-bg-sidebar-accent data-[state=open]:hover:tw-text-sidebar-accent-foreground group-data-[collapsible=icon]:tw-!size-8 group-data-[collapsible=icon]:tw-!p-2 [&>span:last-child]:tw-truncate [&>svg]:tw-size-4 [&>svg]:tw-shrink-0',\n {\n variants: {\n variant: {\n default: 'hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground',\n outline:\n 'tw-bg-background tw-shadow-[0_0_0_1px_hsl(var(--sidebar-border))] hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground hover:tw-shadow-[0_0_0_1px_hsl(var(--sidebar-accent))]',\n },\n size: {\n default: 'tw-h-8 tw-text-sm',\n sm: 'tw-h-7 tw-text-xs',\n lg: 'tw-h-12 tw-text-sm group-data-[collapsible=icon]:tw-!p-0',\n },\n },\n defaultVariants: {\n variant: 'default',\n size: 'default',\n },\n },\n);\n\nconst SidebarMenuButton = React.forwardRef<\n HTMLButtonElement,\n React.ComponentProps<'button'> & {\n asChild?: boolean;\n isActive?: boolean;\n tooltip?: string | React.ComponentProps;\n } & VariantProps\n>(\n (\n {\n asChild = false,\n isActive = false,\n variant = 'default',\n size = 'default',\n tooltip,\n className,\n ...props\n },\n ref,\n ) => {\n const Comp = asChild ? Slot : 'button';\n const { isMobile, state } = useSidebar();\n\n const button = (\n \n );\n\n if (!tooltip) {\n return button;\n }\n\n if (typeof tooltip === 'string') {\n // eslint-disable-next-line no-param-reassign\n tooltip = {\n children: tooltip,\n };\n }\n\n return (\n \n {button}\n \n );\n },\n);\nSidebarMenuButton.displayName = 'SidebarMenuButton';\n\nconst SidebarMenuAction = React.forwardRef<\n HTMLButtonElement,\n React.ComponentProps<'button'> & {\n asChild?: boolean;\n showOnHover?: boolean;\n }\n>(({ className, asChild = false, showOnHover = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'button';\n\n return (\n svg]:tw-size-4 [&>svg]:tw-shrink-0',\n // Increases the hit area of the button on mobile.\n 'after:tw-absolute after:tw--inset-2 after:md:tw-hidden',\n 'tw-peer-data-[size=sm]/menu-button:top-1',\n 'tw-peer-data-[size=default]/menu-button:top-1.5',\n 'tw-peer-data-[size=lg]/menu-button:top-2.5',\n 'group-data-[collapsible=icon]:tw-hidden',\n showOnHover &&\n 'tw-group-focus-within/menu-item:opacity-100 tw-group-hover/menu-item:opacity-100 tw-peer-data-[active=true]/menu-button:text-sidebar-accent-foreground data-[state=open]:tw-opacity-100 md:tw-opacity-0',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarMenuAction.displayName = 'SidebarMenuAction';\n\nconst SidebarMenuBadge = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenuBadge.displayName = 'SidebarMenuBadge';\n\nconst SidebarMenuSkeleton = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & {\n showIcon?: boolean;\n }\n>(({ className, showIcon = false, ...props }, ref) => {\n // Random width between 50 to 90%.\n const width = React.useMemo(() => {\n return `${Math.floor(Math.random() * 40) + 50}%`;\n }, []);\n\n return (\n \n {showIcon && (\n \n )}\n \n
    \n );\n});\nSidebarMenuSkeleton.displayName = 'SidebarMenuSkeleton';\n\nconst SidebarMenuSub = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenuSub.displayName = 'SidebarMenuSub';\n\nconst SidebarMenuSubItem = React.forwardRef>(\n ({ ...props }, ref) =>
  • ,\n);\nSidebarMenuSubItem.displayName = 'SidebarMenuSubItem';\n\nconst SidebarMenuSubButton = React.forwardRef<\n HTMLAnchorElement,\n React.ComponentProps<'a'> & {\n asChild?: boolean;\n size?: 'sm' | 'md';\n isActive?: boolean;\n }\n>(({ asChild = false, size = 'md', isActive, className, ...props }, ref) => {\n const Comp = asChild ? Slot : 'a';\n\n return (\n span:last-child]:tw-truncate [&>svg]:tw-size-4 [&>svg]:tw-shrink-0 [&>svg]:tw-text-sidebar-accent-foreground',\n 'data-[active=true]:tw-bg-sidebar-accent data-[active=true]:tw-text-sidebar-accent-foreground',\n size === 'sm' && 'tw-text-xs',\n size === 'md' && 'tw-text-sm',\n 'group-data-[collapsible=icon]:tw-hidden',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarMenuSubButton.displayName = 'SidebarMenuSubButton';\n\nexport {\n Sidebar,\n SidebarContent,\n SidebarFooter,\n SidebarGroup,\n SidebarGroupAction,\n SidebarGroupContent,\n SidebarGroupLabel,\n SidebarHeader,\n SidebarInput,\n SidebarInset,\n SidebarMenu,\n SidebarMenuAction,\n SidebarMenuBadge,\n SidebarMenuButton,\n SidebarMenuItem,\n SidebarMenuSkeleton,\n SidebarMenuSub,\n SidebarMenuSubButton,\n SidebarMenuSubItem,\n SidebarProvider,\n SidebarRail,\n SidebarSeparator,\n SidebarTrigger,\n useSidebar,\n};\n","import ComboBox, { ComboBoxOption } from '@/components/basics/combo-box.component';\nimport {\n Sidebar,\n SidebarContent,\n SidebarGroup,\n SidebarGroupLabel,\n SidebarGroupContent,\n SidebarMenu,\n SidebarMenuItem,\n SidebarMenuButton,\n} from '@/components/shadcn-ui/sidebar';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { useCallback } from 'react';\n\nexport type SelectedSettingsSidebarItem = {\n label: string;\n projectId?: string;\n};\n\nexport type ProjectOptions = { projectId: string; projectName: string };\n\nexport type SettingsSidebarProps = {\n /** Optional id for testing */\n id?: string;\n\n /** Extension labels from contribution */\n extensionLabels: string[];\n\n /** Project names and ids */\n projectOptions: ProjectOptions[];\n\n /** Handler for selecting a sidebar item */\n handleSelectSidebarItem: (key: string, projectId?: string) => void;\n\n /** The current selected value in the sidebar */\n selectedSidebarItem: SelectedSettingsSidebarItem;\n};\n\nexport default function SettingsSidebar({\n id,\n extensionLabels,\n projectOptions,\n handleSelectSidebarItem,\n selectedSidebarItem,\n}: SettingsSidebarProps) {\n const handleSelectItem = useCallback(\n (item: string, projectId?: string) => {\n handleSelectSidebarItem(item, projectId);\n },\n [handleSelectSidebarItem],\n );\n\n const getProjectNameFromProjectId = useCallback(\n (projectId: string) => {\n const project = projectOptions.find((option) => option.projectId === projectId);\n return project ? project.projectName : projectId;\n },\n [projectOptions],\n );\n\n const getIsActive: (label: string) => boolean = useCallback(\n (label: string) => !selectedSidebarItem.projectId && label === selectedSidebarItem.label,\n [selectedSidebarItem],\n );\n\n return (\n \n \n \n Extensions\n \n \n {extensionLabels.map((label) => (\n \n handleSelectItem(label, undefined)}\n isActive={getIsActive(label)}\n >\n {label}\n \n \n ))}\n \n \n \n \n Projects\n \n option.projectId)}\n getOptionLabel={(projectId: ComboBoxOption) => {\n // This function expects a ComboBoxOption, but we know it is a string\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n return getProjectNameFromProjectId(projectId as string);\n }}\n buttonPlaceholder=\"Type or select project\"\n onChange={(projectId: string) => {\n const selectedProjectName = getProjectNameFromProjectId(projectId);\n handleSelectItem(selectedProjectName, projectId);\n }}\n value={selectedSidebarItem?.projectId ?? undefined}\n />\n \n \n \n \n );\n}\n","import { SidebarInset, SidebarProvider } from '@/components/shadcn-ui/sidebar';\nimport { PropsWithChildren } from 'react';\nimport SearchBar from '@/components/basics/search-bar.component';\nimport SettingsSidebar, { SettingsSidebarProps } from './settings-sidebar.component';\n\nexport type SettingsSidebarContentSearchProps = SettingsSidebarProps &\n PropsWithChildren & {\n /** Optional id for testing */\n id?: string;\n\n /** Text direction ltr or rtl */\n direction?: 'ltr' | 'rtl';\n\n /** Handler to run when the value of the search bar changes */\n onSearch: (searchQuery: string) => void;\n };\n\nexport default function SettingsSidebarContentSearch({\n id,\n direction = 'ltr',\n extensionLabels,\n projectOptions,\n children,\n handleSelectSidebarItem,\n selectedSidebarItem,\n onSearch,\n}: SettingsSidebarContentSearchProps) {\n return (\n
    \n
    \n \n
    \n \n \n {children}\n \n
    \n );\n}\n","import { Button } from '@/components/shadcn-ui/button';\nimport {\n Select,\n SelectContent,\n SelectGroup,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\nimport {\n Table,\n TableBody,\n TableCell,\n TableHead,\n TableHeader,\n TableRow,\n} from '@/components/shadcn-ui/table';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Canon } from '@sillsdev/scripture';\nimport {\n Cell,\n ColumnDef,\n flexRender,\n getCoreRowModel,\n getExpandedRowModel,\n getGroupedRowModel,\n getSortedRowModel,\n GroupingState,\n Row,\n RowSelectionState,\n SortingState,\n useReactTable,\n} from '@tanstack/react-table';\nimport '@/components/advanced/scripture-results-viewer/scripture-results-viewer.component.css';\nimport {\n compareScrRefs,\n formatScrRef,\n ScriptureSelection,\n scrRefToBBBCCCVVV,\n} from 'platform-bible-utils';\nimport { MouseEvent, useEffect, useMemo, useState } from 'react';\nimport { ChevronDown, ChevronLeft, ChevronRight } from 'lucide-react';\n\n/**\n * Information (e.g., a checking error or some other type of \"transient\" annotation) about something\n * noteworthy at a specific place in an instance of the Scriptures.\n */\nexport type ScriptureItemDetail = ScriptureSelection & {\n /**\n * Text of the error, note, etc. In the future, we might want to support something more than just\n * text so that a JSX element could be provided with a link or some other controls related to the\n * issue being reported.\n */\n detail: string;\n};\n\n/**\n * A uniquely identifiable source of results that can be displayed in the ScriptureResultsViewer.\n * Generally, the source will be a particular Scripture check, but there may be other types of\n * sources.\n */\nexport type ResultsSource = {\n /**\n * Uniquely identifies the source.\n *\n * @type {string}\n */\n id: string;\n\n /**\n * Name (potentially localized) of the source, suitable for display in the UI.\n *\n * @type {string}\n */\n displayName: string;\n};\n\nexport type ScriptureSrcItemDetail = ScriptureItemDetail & {\n /** Source/type of detail. Can be used for grouping. */\n source: ResultsSource;\n};\n\n/**\n * Represents a set of results keyed by Scripture reference. Generally, the source will be a\n * particular Scripture check, but this type also allows for other types of uniquely identifiable\n * sources.\n */\nexport type ResultsSet = {\n /**\n * The backing source associated with this set of results.\n *\n * @type {ResultsSource}\n */\n source: ResultsSource;\n\n /**\n * Array of Scripture item details (messages keyed by Scripture reference).\n *\n * @type {ScriptureItemDetail[]}\n */\n data: ScriptureItemDetail[];\n};\n\nconst scrBookColId = 'scrBook';\nconst scrRefColId = 'scrRef';\nconst typeColId = 'source';\nconst detailsColId = 'details';\n\nconst defaultScrRefColumnName = 'Scripture Reference';\nconst defaultScrBookGroupName = 'Scripture Book';\nconst defaultTypeColumnName = 'Type';\nconst defaultDetailsColumnName = 'Details';\n\nexport type ScriptureResultsViewerColumnInfo = {\n /** Optional header to display for the Reference column. Default value: 'Scripture Reference'. */\n scriptureReferenceColumnName?: string;\n\n /** Optional text to display to refer to the Scripture book group. Default value: 'Scripture Book'. */\n scriptureBookGroupName?: string;\n\n /** Optional header to display for the Type column. Default value: 'Type'. */\n typeColumnName?: string;\n\n /** Optional header to display for the Details column. Default value: 'Details' */\n detailsColumnName?: string;\n};\n\nexport type ScriptureResultsViewerProps = ScriptureResultsViewerColumnInfo & {\n /** Groups of ScriptureItemDetail objects from particular sources (e.g., Scripture checks) */\n sources: ResultsSet[];\n\n /** Flag indicating whether to display column headers. Default is false. */\n showColumnHeaders?: boolean;\n\n /** Flag indicating whether to display source column. Default is false. */\n showSourceColumn?: boolean;\n\n /** Callback function to notify when a row is selected */\n onRowSelected?: (selectedRow: ScriptureSrcItemDetail | undefined) => void;\n\n /** Text direction ltr or rtl */\n direction?: 'ltr' | 'rtl';\n};\n\nfunction getColumns(\n colInfo?: ScriptureResultsViewerColumnInfo,\n showSourceColumn?: boolean,\n): ColumnDef[] {\n const showSrcCol = showSourceColumn ?? false;\n return [\n {\n accessorFn: (row) =>\n `${Canon.bookNumberToId(row.start.bookNum)} ${row.start.chapterNum}:${row.start.verseNum}`,\n id: scrBookColId,\n header: colInfo?.scriptureReferenceColumnName ?? defaultScrRefColumnName,\n cell: (info) => {\n const row = info.row.original;\n if (info.row.getIsGrouped()) {\n return Canon.bookNumberToEnglishName(row.start.bookNum);\n }\n return info.row.groupingColumnId === scrBookColId ? formatScrRef(row.start) : undefined;\n },\n getGroupingValue: (row) => row.start.bookNum,\n sortingFn: (a, b) => {\n return compareScrRefs(a.original.start, b.original.start);\n },\n enableGrouping: true,\n },\n {\n accessorFn: (row) => formatScrRef(row.start),\n id: scrRefColId,\n header: undefined,\n cell: (info) => {\n const row = info.row.original;\n return info.row.getIsGrouped() ? undefined : formatScrRef(row.start);\n },\n sortingFn: (a, b) => {\n return compareScrRefs(a.original.start, b.original.start);\n },\n enableGrouping: false,\n },\n {\n accessorFn: (row) => row.source.displayName,\n id: typeColId,\n header: showSrcCol ? (colInfo?.typeColumnName ?? defaultTypeColumnName) : undefined,\n cell: (info) => (showSrcCol || info.row.getIsGrouped() ? info.getValue() : undefined),\n getGroupingValue: (row) => row.source.id,\n sortingFn: (a, b) =>\n a.original.source.displayName.localeCompare(b.original.source.displayName),\n enableGrouping: true,\n },\n {\n accessorFn: (row) => row.detail,\n id: detailsColId,\n header: colInfo?.detailsColumnName ?? defaultDetailsColumnName,\n cell: (info) => info.getValue(),\n enableGrouping: false,\n },\n ];\n}\n\nconst toRefOrRange = (scriptureSelection: ScriptureSelection) => {\n if (!('offset' in scriptureSelection.start))\n throw new Error('No offset available in range start');\n if (scriptureSelection.end && !('offset' in scriptureSelection.end))\n throw new Error('No offset available in range end');\n const { offset: offsetStart } = scriptureSelection.start;\n let offsetEnd: number = 0;\n if (scriptureSelection.end) ({ offset: offsetEnd } = scriptureSelection.end);\n if (\n !scriptureSelection.end ||\n compareScrRefs(scriptureSelection.start, scriptureSelection.end) === 0\n )\n return `${scrRefToBBBCCCVVV(scriptureSelection.start)}+${offsetStart}`;\n return `${scrRefToBBBCCCVVV(scriptureSelection.start)}+${offsetStart}-${scrRefToBBBCCCVVV(scriptureSelection.end)}+${offsetEnd}`;\n};\n\nconst getRowKey = (row: ScriptureSrcItemDetail) =>\n `${toRefOrRange({ start: row.start, end: row.end })} ${row.source.displayName} ${row.detail}`;\n\n/**\n * Component to display a combined list of detailed items from one or more sources, where the items\n * are keyed primarily by Scripture reference. This is particularly useful for displaying a list of\n * results from Scripture checks, but more generally could be used to display any \"results\" from any\n * source(s). The component allows for grouping by Scripture book, source, or both. By default, it\n * displays somewhat \"tree-like\" which allows it to be more horizontally compact and intuitive. But\n * it also has the option of displaying as a traditional table with column headings (with or without\n * the source column showing).\n */\nexport default function ScriptureResultsViewer({\n sources,\n showColumnHeaders = false,\n showSourceColumn = false,\n scriptureReferenceColumnName,\n scriptureBookGroupName,\n typeColumnName,\n detailsColumnName,\n onRowSelected,\n direction = 'ltr',\n}: ScriptureResultsViewerProps) {\n const [grouping, setGrouping] = useState([]);\n const [sorting, setSorting] = useState([{ id: scrBookColId, desc: false }]);\n const [rowSelection, setRowSelection] = useState({});\n\n const scriptureResults = useMemo(\n () =>\n sources.flatMap((source) => {\n return source.data.map((item) => ({\n ...item,\n source: source.source,\n }));\n }),\n [sources],\n );\n\n const columns = useMemo(\n () =>\n getColumns(\n {\n scriptureReferenceColumnName,\n typeColumnName,\n detailsColumnName,\n },\n showSourceColumn,\n ),\n [scriptureReferenceColumnName, typeColumnName, detailsColumnName, showSourceColumn],\n );\n\n useEffect(() => {\n // Ensure sorting is applied correctly when grouped by type\n if (grouping.includes(typeColId)) {\n setSorting([\n { id: typeColId, desc: false },\n { id: scrBookColId, desc: false },\n ]);\n } else {\n setSorting([{ id: scrBookColId, desc: false }]);\n }\n }, [grouping]);\n\n const table = useReactTable({\n data: scriptureResults,\n columns,\n state: {\n grouping,\n sorting,\n rowSelection,\n },\n onGroupingChange: setGrouping,\n onSortingChange: setSorting,\n onRowSelectionChange: setRowSelection,\n getExpandedRowModel: getExpandedRowModel(),\n getGroupedRowModel: getGroupedRowModel(),\n getCoreRowModel: getCoreRowModel(),\n getSortedRowModel: getSortedRowModel(),\n getRowId: getRowKey,\n autoResetExpanded: false,\n enableMultiRowSelection: false,\n enableSubRowSelection: false,\n });\n\n useEffect(() => {\n if (onRowSelected) {\n const selectedRows = table.getSelectedRowModel().rowsById;\n const keys = Object.keys(selectedRows);\n if (keys.length === 1) {\n const selectedRow = scriptureResults.find((row) => getRowKey(row) === keys[0]) || undefined;\n if (selectedRow) onRowSelected(selectedRow);\n }\n }\n }, [rowSelection, scriptureResults, onRowSelected, table]);\n\n // Define possible grouping options\n const scrBookGroupName = scriptureBookGroupName ?? defaultScrBookGroupName;\n const typeGroupName = typeColumnName ?? defaultTypeColumnName;\n\n const groupingOptions = [\n { label: 'No Grouping', value: [] },\n { label: `Group by ${scrBookGroupName}`, value: [scrBookColId] },\n { label: `Group by ${typeGroupName}`, value: [typeColId] },\n {\n label: `Group by ${scrBookGroupName} and ${typeGroupName}`,\n value: [scrBookColId, typeColId],\n },\n {\n label: `Group by ${typeGroupName} and ${scrBookGroupName}`,\n value: [typeColId, scrBookColId],\n },\n ];\n\n const handleSelectChange = (selectedGrouping: string) => {\n setGrouping(JSON.parse(selectedGrouping));\n };\n\n const handleRowClick = (row: Row, event: MouseEvent) => {\n if (!row.getIsGrouped() && !row.getIsSelected()) {\n row.getToggleSelectedHandler()(event);\n }\n };\n\n const getEvenOrOddBandingStyle = (row: Row, index: number) => {\n if (row.getIsGrouped()) return '';\n // UX has now said they don't think they want banding. I'm leaving in the code to\n // set even and odd styles, but there's nothing in the CSS to style them differently.\n // The \"even\" style used to also have tw-bg-neutral-300 (along with even) to create\n // a visual banding effect. That could be added back in if UX changes the decision.\n return cn('banded-row', index % 2 === 0 ? 'even' : 'odd');\n };\n\n const getIndent = (\n groupingState: GroupingState,\n row: Row,\n cell: Cell,\n ) => {\n if (groupingState?.length === 0 || row.depth < cell.column.getGroupedIndex()) return undefined;\n if (row.getIsGrouped()) {\n switch (row.depth) {\n case 1:\n return 'tw-ps-4';\n default:\n return undefined;\n }\n }\n switch (row.depth) {\n case 1:\n return 'tw-ps-8';\n case 2:\n return 'tw-ps-12';\n default:\n return undefined;\n }\n };\n\n return (\n
    \n {!showColumnHeaders && (\n {\n handleSelectChange(value);\n }}\n >\n \n \n \n \n \n {groupingOptions.map((option) => (\n \n {option.label}\n \n ))}\n \n \n \n )}\n \n {showColumnHeaders && (\n \n {table.getHeaderGroups().map((headerGroup) => (\n \n {headerGroup.headers\n .filter((h) => h.column.columnDef.header)\n .map((header) => (\n /* For sticky column headers to work, we probably need to change the default definition of the shadcn Table component. See https://github.com/shadcn-ui/ui/issues/1151 */\n \n {header.isPlaceholder ? undefined : (\n
    \n {header.column.getCanGroup() ? (\n \n {header.column.getIsGrouped() ? `🛑` : `👊 `}\n \n ) : undefined}{' '}\n {flexRender(header.column.columnDef.header, header.getContext())}\n
    \n )}\n
    \n ))}\n
    \n ))}\n
    \n )}\n \n {table.getRowModel().rows.map((row, rowIndex) => {\n return (\n handleRowClick(row, event)}\n >\n {row.getVisibleCells().map((cell) => {\n if (\n cell.getIsPlaceholder() ||\n (cell.column.columnDef.enableGrouping &&\n !cell.getIsGrouped() &&\n (cell.column.columnDef.id !== typeColId || !showSourceColumn))\n )\n return undefined;\n return (\n \n {(() => {\n if (cell.getIsGrouped()) {\n return (\n \n {row.getIsExpanded() && }\n {!row.getIsExpanded() &&\n (direction === 'ltr' ? : )}{' '}\n {flexRender(cell.column.columnDef.cell, cell.getContext())} (\n {row.subRows.length})\n \n );\n }\n\n // if (cell.getIsAggregated()) {\n // flexRender(\n // cell.column.columnDef.aggregatedCell ?? cell.column.columnDef.cell,\n // cell.getContext(),\n // );\n // }\n\n return flexRender(cell.column.columnDef.cell, cell.getContext());\n })()}\n \n );\n })}\n \n );\n })}\n \n
    \n
    \n );\n}\n","import {\n getLocalizeKeyForScrollGroupId,\n LanguageStrings,\n ScrollGroupId,\n} from 'platform-bible-utils';\nimport {\n Select,\n SelectContent,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\n\nconst DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS = {\n [getLocalizeKeyForScrollGroupId('undefined')]: 'Ø',\n [getLocalizeKeyForScrollGroupId(0)]: 'A',\n [getLocalizeKeyForScrollGroupId(1)]: 'B',\n [getLocalizeKeyForScrollGroupId(2)]: 'C',\n [getLocalizeKeyForScrollGroupId(3)]: 'D',\n [getLocalizeKeyForScrollGroupId(4)]: 'E',\n [getLocalizeKeyForScrollGroupId(5)]: 'F',\n [getLocalizeKeyForScrollGroupId(6)]: 'G',\n [getLocalizeKeyForScrollGroupId(7)]: 'H',\n [getLocalizeKeyForScrollGroupId(8)]: 'I',\n [getLocalizeKeyForScrollGroupId(9)]: 'J',\n [getLocalizeKeyForScrollGroupId(10)]: 'K',\n [getLocalizeKeyForScrollGroupId(11)]: 'L',\n [getLocalizeKeyForScrollGroupId(12)]: 'M',\n [getLocalizeKeyForScrollGroupId(13)]: 'N',\n [getLocalizeKeyForScrollGroupId(14)]: 'O',\n [getLocalizeKeyForScrollGroupId(15)]: 'P',\n [getLocalizeKeyForScrollGroupId(16)]: 'Q',\n [getLocalizeKeyForScrollGroupId(17)]: 'R',\n [getLocalizeKeyForScrollGroupId(18)]: 'S',\n [getLocalizeKeyForScrollGroupId(19)]: 'T',\n [getLocalizeKeyForScrollGroupId(20)]: 'U',\n [getLocalizeKeyForScrollGroupId(21)]: 'V',\n [getLocalizeKeyForScrollGroupId(22)]: 'W',\n [getLocalizeKeyForScrollGroupId(23)]: 'X',\n [getLocalizeKeyForScrollGroupId(24)]: 'Y',\n [getLocalizeKeyForScrollGroupId(25)]: 'Z',\n};\n\nexport type ScrollGroupSelectorProps = {\n /**\n * List of scroll group ids to show to the user. Either a {@link ScrollGroupId} or `undefined` for\n * no scroll group\n */\n availableScrollGroupIds: (ScrollGroupId | undefined)[];\n /** Currently selected scroll group id. `undefined` for no scroll group */\n scrollGroupId: ScrollGroupId | undefined;\n /** Callback function run when the user tries to change the scroll group id */\n onChangeScrollGroupId: (newScrollGroupId: ScrollGroupId | undefined) => void;\n /**\n * Localized strings to use for displaying scroll group ids. Must be an object whose keys are\n * `getLocalizeKeyForScrollGroupId(scrollGroupId)` for all scroll group ids (and `undefined` if\n * included) in {@link ScrollGroupSelectorProps.availableScrollGroupIds} and whose values are the\n * localized strings to use for those scroll group ids.\n *\n * Defaults to English localizations of English alphabet for scroll groups 0-25 (e.g. 0 is A) and\n * Ø for `undefined`. Will fill in any that are not provided with these English localizations.\n * Also, if any values match the keys, the English localization will be used. This is useful in\n * case you want to pass in a temporary version of the localized strings while your localized\n * strings load.\n *\n * @example\n *\n * ```typescript\n * const myScrollGroupIdLocalizedStrings = {\n * [getLocalizeKeyForScrollGroupId('undefined')]: 'Ø',\n * [getLocalizeKeyForScrollGroupId(0)]: 'A',\n * [getLocalizeKeyForScrollGroupId(1)]: 'B',\n * [getLocalizeKeyForScrollGroupId(2)]: 'C',\n * [getLocalizeKeyForScrollGroupId(3)]: 'D',\n * [getLocalizeKeyForScrollGroupId(4)]: 'E',\n * };\n * ```\n *\n * @example\n *\n * ```tsx\n * const availableScrollGroupIds = [undefined, 0, 1, 2, 3, 4];\n *\n * const localizeKeys = getLocalizeKeysForScrollGroupIds();\n *\n * const [localizedStrings] = useLocalizedStrings(localizeKeys);\n *\n * ...\n *\n * \n * ```\n */\n localizedStrings?: LanguageStrings;\n};\n\n/** Selector component for choosing a scroll group */\nexport default function ScrollGroupSelector({\n availableScrollGroupIds,\n scrollGroupId,\n onChangeScrollGroupId,\n localizedStrings = {},\n}: ScrollGroupSelectorProps) {\n const localizedStringsDefaulted = {\n ...DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS,\n ...Object.fromEntries(\n Object.entries(localizedStrings).map(\n ([localizedStringKey, localizedStringValue]: [string, string]) => [\n localizedStringKey,\n localizedStringKey === localizedStringValue &&\n localizedStringKey in DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS\n ? DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS[localizedStringKey]\n : localizedStringValue,\n ],\n ),\n ),\n };\n return (\n \n onChangeScrollGroupId(\n newScrollGroupString === 'undefined' ? undefined : parseInt(newScrollGroupString, 10),\n )\n }\n >\n \n \n \n \n {availableScrollGroupIds.map((scrollGroupOptionId) => (\n \n {localizedStringsDefaulted[getLocalizeKeyForScrollGroupId(scrollGroupOptionId)]}\n \n ))}\n \n \n );\n}\n","import { PropsWithChildren } from 'react';\nimport { Separator } from '@/components/shadcn-ui/separator';\n\n/** Props for the SettingsList component, currently just children */\ntype SettingsListProps = PropsWithChildren;\n\n/**\n * SettingsList component is a wrapper for list items. Rendered with a formatted div\n *\n * @param children To populate the list with\n * @returns Formatted div encompassing the children\n */\nexport function SettingsList({ children }: SettingsListProps) {\n return
    {children}
    ;\n}\n\n/** Props for SettingsListItem component */\ntype SettingsListItemProps = PropsWithChildren & {\n /** Primary text of the list item */\n primary: string;\n\n /** Optional text of the list item */\n secondary?: string | undefined;\n\n /** Optional boolean to display a message if the children aren't loaded yet. Defaults to false */\n isLoading?: boolean;\n\n /** Optional message to display if isLoading */\n loadingMessage?: string;\n};\n\n/**\n * SettingsListItem component is a common list item. Rendered with a formatted div\n *\n * @param primary Primary text of the list item\n * @param secondary Optional secondary text of the list item\n * @param isLoading Optional, to display a message if the action component isn't generated yet,\n * defaults to false\n * @param children The action component(s) to provide for this item\n * @param loadingMessage Optional, message to display if isLoading\n * @returns Formatted div encompassing the list item content\n */\nexport function SettingsListItem({\n primary,\n secondary,\n children,\n isLoading = false,\n loadingMessage,\n}: SettingsListItemProps) {\n return (\n
    \n
    \n

    {primary}

    \n

    \n {secondary}\n

    \n
    \n\n {isLoading ? (\n

    {loadingMessage}

    \n ) : (\n
    {children}
    \n )}\n
    \n );\n}\n\n/** Props for SettingsListHeader component */\ntype SettingsListHeaderProps = {\n /** The primary text of the list header */\n primary: string;\n\n /** Optional secondary text of the list header */\n secondary?: string | undefined;\n\n /** Optional boolean to include a separator underneath the secondary text. Defaults to false */\n includeSeparator?: boolean;\n};\n\n/**\n * SettingsListHeader component displays text above the list\n *\n * @param primary The primary text of the list header\n * @param secondary Optional secondary text of the list header\n * @param includeSeparator Optional boolean to include a separator underneath the secondary text.\n * Defaults to false\n * @returns Formatted div with list header content\n */\nexport function SettingsListHeader({\n primary,\n secondary,\n includeSeparator = false,\n}: SettingsListHeaderProps) {\n return (\n
    \n
    \n

    {primary}

    \n

    {secondary}

    \n
    \n {includeSeparator ? : ''}\n
    \n );\n}\n","import Checkbox from '@/components/shadcn-ui/checkbox';\nimport { Label } from '@/components/shadcn-ui/label';\n\nexport type ChecklistProps = {\n /** Optional string representing the id attribute of the Checklist */\n id?: string;\n /** Optional string representing CSS class name(s) for styling */\n className?: string;\n /** Array of strings representing the checkable items */\n listItems: string[];\n /** Array of strings representing the checked items */\n selectedListItems: string[];\n /**\n * Function that is called when a checkbox item is selected or deselected\n *\n * @param item The string description for this item\n * @param selected True if selected, false if not selected\n */\n handleSelectListItem: (item: string, selected: boolean) => void;\n\n /**\n * Optional function creates a label for a provided checkable item\n *\n * @param item The item for which a label is to be created\n * @returns A string representing the label text for the checkbox associated with that item\n */\n createLabel?: (item: string) => string;\n};\n\n/** Renders a list of checkboxes. Each checkbox corresponds to an item from the `listItems` array. */\nexport default function Checklist({\n id,\n className,\n listItems,\n selectedListItems,\n handleSelectListItem,\n createLabel,\n}: ChecklistProps) {\n return (\n
    \n {listItems.map((item) => (\n
    \n handleSelectListItem(item, value)}\n />\n \n
    \n ))}\n
    \n );\n}\n","function _interopRequireDefault(obj) {\n return obj && obj.__esModule ? obj : {\n \"default\": obj\n };\n}\nmodule.exports = _interopRequireDefault, module.exports.__esModule = true, module.exports[\"default\"] = module.exports;","export default function chainPropTypes(propType1, propType2) {\n if (process.env.NODE_ENV === 'production') {\n return () => null;\n }\n return function validate(...args) {\n return propType1(...args) || propType2(...args);\n };\n}","export default function _extends() {\n _extends = Object.assign ? Object.assign.bind() : function (target) {\n for (var i = 1; i < arguments.length; i++) {\n var source = arguments[i];\n for (var key in source) {\n if (Object.prototype.hasOwnProperty.call(source, key)) {\n target[key] = source[key];\n }\n }\n }\n return target;\n };\n return _extends.apply(this, arguments);\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\n// https://github.com/sindresorhus/is-plain-obj/blob/main/index.js\nexport function isPlainObject(item) {\n if (typeof item !== 'object' || item === null) {\n return false;\n }\n const prototype = Object.getPrototypeOf(item);\n return (prototype === null || prototype === Object.prototype || Object.getPrototypeOf(prototype) === null) && !(Symbol.toStringTag in item) && !(Symbol.iterator in item);\n}\nfunction deepClone(source) {\n if (!isPlainObject(source)) {\n return source;\n }\n const output = {};\n Object.keys(source).forEach(key => {\n output[key] = deepClone(source[key]);\n });\n return output;\n}\nexport default function deepmerge(target, source, options = {\n clone: true\n}) {\n const output = options.clone ? _extends({}, target) : target;\n if (isPlainObject(target) && isPlainObject(source)) {\n Object.keys(source).forEach(key => {\n // Avoid prototype pollution\n if (key === '__proto__') {\n return;\n }\n if (isPlainObject(source[key]) && key in target && isPlainObject(target[key])) {\n // Since `output` is a clone of `target` and we have narrowed `target` in this block we can cast to the same type.\n output[key] = deepmerge(target[key], source[key], options);\n } else if (options.clone) {\n output[key] = isPlainObject(source[key]) ? deepClone(source[key]) : source[key];\n } else {\n output[key] = source[key];\n }\n });\n }\n return output;\n}","/** @license React v16.13.1\n * react-is.production.min.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';var b=\"function\"===typeof Symbol&&Symbol.for,c=b?Symbol.for(\"react.element\"):60103,d=b?Symbol.for(\"react.portal\"):60106,e=b?Symbol.for(\"react.fragment\"):60107,f=b?Symbol.for(\"react.strict_mode\"):60108,g=b?Symbol.for(\"react.profiler\"):60114,h=b?Symbol.for(\"react.provider\"):60109,k=b?Symbol.for(\"react.context\"):60110,l=b?Symbol.for(\"react.async_mode\"):60111,m=b?Symbol.for(\"react.concurrent_mode\"):60111,n=b?Symbol.for(\"react.forward_ref\"):60112,p=b?Symbol.for(\"react.suspense\"):60113,q=b?\nSymbol.for(\"react.suspense_list\"):60120,r=b?Symbol.for(\"react.memo\"):60115,t=b?Symbol.for(\"react.lazy\"):60116,v=b?Symbol.for(\"react.block\"):60121,w=b?Symbol.for(\"react.fundamental\"):60117,x=b?Symbol.for(\"react.responder\"):60118,y=b?Symbol.for(\"react.scope\"):60119;\nfunction z(a){if(\"object\"===typeof a&&null!==a){var u=a.$$typeof;switch(u){case c:switch(a=a.type,a){case l:case m:case e:case g:case f:case p:return a;default:switch(a=a&&a.$$typeof,a){case k:case n:case t:case r:case h:return a;default:return u}}case d:return u}}}function A(a){return z(a)===m}exports.AsyncMode=l;exports.ConcurrentMode=m;exports.ContextConsumer=k;exports.ContextProvider=h;exports.Element=c;exports.ForwardRef=n;exports.Fragment=e;exports.Lazy=t;exports.Memo=r;exports.Portal=d;\nexports.Profiler=g;exports.StrictMode=f;exports.Suspense=p;exports.isAsyncMode=function(a){return A(a)||z(a)===l};exports.isConcurrentMode=A;exports.isContextConsumer=function(a){return z(a)===k};exports.isContextProvider=function(a){return z(a)===h};exports.isElement=function(a){return\"object\"===typeof a&&null!==a&&a.$$typeof===c};exports.isForwardRef=function(a){return z(a)===n};exports.isFragment=function(a){return z(a)===e};exports.isLazy=function(a){return z(a)===t};\nexports.isMemo=function(a){return z(a)===r};exports.isPortal=function(a){return z(a)===d};exports.isProfiler=function(a){return z(a)===g};exports.isStrictMode=function(a){return z(a)===f};exports.isSuspense=function(a){return z(a)===p};\nexports.isValidElementType=function(a){return\"string\"===typeof a||\"function\"===typeof a||a===e||a===m||a===g||a===f||a===p||a===q||\"object\"===typeof a&&null!==a&&(a.$$typeof===t||a.$$typeof===r||a.$$typeof===h||a.$$typeof===k||a.$$typeof===n||a.$$typeof===w||a.$$typeof===x||a.$$typeof===y||a.$$typeof===v)};exports.typeOf=z;\n","/** @license React v16.13.1\n * react-is.development.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\n\n\nif (process.env.NODE_ENV !== \"production\") {\n (function() {\n'use strict';\n\n// The Symbol used to tag the ReactElement-like types. If there is no native Symbol\n// nor polyfill, then a plain number is used for performance.\nvar hasSymbol = typeof Symbol === 'function' && Symbol.for;\nvar REACT_ELEMENT_TYPE = hasSymbol ? Symbol.for('react.element') : 0xeac7;\nvar REACT_PORTAL_TYPE = hasSymbol ? Symbol.for('react.portal') : 0xeaca;\nvar REACT_FRAGMENT_TYPE = hasSymbol ? Symbol.for('react.fragment') : 0xeacb;\nvar REACT_STRICT_MODE_TYPE = hasSymbol ? Symbol.for('react.strict_mode') : 0xeacc;\nvar REACT_PROFILER_TYPE = hasSymbol ? Symbol.for('react.profiler') : 0xead2;\nvar REACT_PROVIDER_TYPE = hasSymbol ? Symbol.for('react.provider') : 0xeacd;\nvar REACT_CONTEXT_TYPE = hasSymbol ? Symbol.for('react.context') : 0xeace; // TODO: We don't use AsyncMode or ConcurrentMode anymore. They were temporary\n// (unstable) APIs that have been removed. Can we remove the symbols?\n\nvar REACT_ASYNC_MODE_TYPE = hasSymbol ? Symbol.for('react.async_mode') : 0xeacf;\nvar REACT_CONCURRENT_MODE_TYPE = hasSymbol ? Symbol.for('react.concurrent_mode') : 0xeacf;\nvar REACT_FORWARD_REF_TYPE = hasSymbol ? Symbol.for('react.forward_ref') : 0xead0;\nvar REACT_SUSPENSE_TYPE = hasSymbol ? Symbol.for('react.suspense') : 0xead1;\nvar REACT_SUSPENSE_LIST_TYPE = hasSymbol ? Symbol.for('react.suspense_list') : 0xead8;\nvar REACT_MEMO_TYPE = hasSymbol ? Symbol.for('react.memo') : 0xead3;\nvar REACT_LAZY_TYPE = hasSymbol ? Symbol.for('react.lazy') : 0xead4;\nvar REACT_BLOCK_TYPE = hasSymbol ? Symbol.for('react.block') : 0xead9;\nvar REACT_FUNDAMENTAL_TYPE = hasSymbol ? Symbol.for('react.fundamental') : 0xead5;\nvar REACT_RESPONDER_TYPE = hasSymbol ? Symbol.for('react.responder') : 0xead6;\nvar REACT_SCOPE_TYPE = hasSymbol ? Symbol.for('react.scope') : 0xead7;\n\nfunction isValidElementType(type) {\n return typeof type === 'string' || typeof type === 'function' || // Note: its typeof might be other than 'symbol' or 'number' if it's a polyfill.\n type === REACT_FRAGMENT_TYPE || type === REACT_CONCURRENT_MODE_TYPE || type === REACT_PROFILER_TYPE || type === REACT_STRICT_MODE_TYPE || type === REACT_SUSPENSE_TYPE || type === REACT_SUSPENSE_LIST_TYPE || typeof type === 'object' && type !== null && (type.$$typeof === REACT_LAZY_TYPE || type.$$typeof === REACT_MEMO_TYPE || type.$$typeof === REACT_PROVIDER_TYPE || type.$$typeof === REACT_CONTEXT_TYPE || type.$$typeof === REACT_FORWARD_REF_TYPE || type.$$typeof === REACT_FUNDAMENTAL_TYPE || type.$$typeof === REACT_RESPONDER_TYPE || type.$$typeof === REACT_SCOPE_TYPE || type.$$typeof === REACT_BLOCK_TYPE);\n}\n\nfunction typeOf(object) {\n if (typeof object === 'object' && object !== null) {\n var $$typeof = object.$$typeof;\n\n switch ($$typeof) {\n case REACT_ELEMENT_TYPE:\n var type = object.type;\n\n switch (type) {\n case REACT_ASYNC_MODE_TYPE:\n case REACT_CONCURRENT_MODE_TYPE:\n case REACT_FRAGMENT_TYPE:\n case REACT_PROFILER_TYPE:\n case REACT_STRICT_MODE_TYPE:\n case REACT_SUSPENSE_TYPE:\n return type;\n\n default:\n var $$typeofType = type && type.$$typeof;\n\n switch ($$typeofType) {\n case REACT_CONTEXT_TYPE:\n case REACT_FORWARD_REF_TYPE:\n case REACT_LAZY_TYPE:\n case REACT_MEMO_TYPE:\n case REACT_PROVIDER_TYPE:\n return $$typeofType;\n\n default:\n return $$typeof;\n }\n\n }\n\n case REACT_PORTAL_TYPE:\n return $$typeof;\n }\n }\n\n return undefined;\n} // AsyncMode is deprecated along with isAsyncMode\n\nvar AsyncMode = REACT_ASYNC_MODE_TYPE;\nvar ConcurrentMode = REACT_CONCURRENT_MODE_TYPE;\nvar ContextConsumer = REACT_CONTEXT_TYPE;\nvar ContextProvider = REACT_PROVIDER_TYPE;\nvar Element = REACT_ELEMENT_TYPE;\nvar ForwardRef = REACT_FORWARD_REF_TYPE;\nvar Fragment = REACT_FRAGMENT_TYPE;\nvar Lazy = REACT_LAZY_TYPE;\nvar Memo = REACT_MEMO_TYPE;\nvar Portal = REACT_PORTAL_TYPE;\nvar Profiler = REACT_PROFILER_TYPE;\nvar StrictMode = REACT_STRICT_MODE_TYPE;\nvar Suspense = REACT_SUSPENSE_TYPE;\nvar hasWarnedAboutDeprecatedIsAsyncMode = false; // AsyncMode should be deprecated\n\nfunction isAsyncMode(object) {\n {\n if (!hasWarnedAboutDeprecatedIsAsyncMode) {\n hasWarnedAboutDeprecatedIsAsyncMode = true; // Using console['warn'] to evade Babel and ESLint\n\n console['warn']('The ReactIs.isAsyncMode() alias has been deprecated, ' + 'and will be removed in React 17+. Update your code to use ' + 'ReactIs.isConcurrentMode() instead. It has the exact same API.');\n }\n }\n\n return isConcurrentMode(object) || typeOf(object) === REACT_ASYNC_MODE_TYPE;\n}\nfunction isConcurrentMode(object) {\n return typeOf(object) === REACT_CONCURRENT_MODE_TYPE;\n}\nfunction isContextConsumer(object) {\n return typeOf(object) === REACT_CONTEXT_TYPE;\n}\nfunction isContextProvider(object) {\n return typeOf(object) === REACT_PROVIDER_TYPE;\n}\nfunction isElement(object) {\n return typeof object === 'object' && object !== null && object.$$typeof === REACT_ELEMENT_TYPE;\n}\nfunction isForwardRef(object) {\n return typeOf(object) === REACT_FORWARD_REF_TYPE;\n}\nfunction isFragment(object) {\n return typeOf(object) === REACT_FRAGMENT_TYPE;\n}\nfunction isLazy(object) {\n return typeOf(object) === REACT_LAZY_TYPE;\n}\nfunction isMemo(object) {\n return typeOf(object) === REACT_MEMO_TYPE;\n}\nfunction isPortal(object) {\n return typeOf(object) === REACT_PORTAL_TYPE;\n}\nfunction isProfiler(object) {\n return typeOf(object) === REACT_PROFILER_TYPE;\n}\nfunction isStrictMode(object) {\n return typeOf(object) === REACT_STRICT_MODE_TYPE;\n}\nfunction isSuspense(object) {\n return typeOf(object) === REACT_SUSPENSE_TYPE;\n}\n\nexports.AsyncMode = AsyncMode;\nexports.ConcurrentMode = ConcurrentMode;\nexports.ContextConsumer = ContextConsumer;\nexports.ContextProvider = ContextProvider;\nexports.Element = Element;\nexports.ForwardRef = ForwardRef;\nexports.Fragment = Fragment;\nexports.Lazy = Lazy;\nexports.Memo = Memo;\nexports.Portal = Portal;\nexports.Profiler = Profiler;\nexports.StrictMode = StrictMode;\nexports.Suspense = Suspense;\nexports.isAsyncMode = isAsyncMode;\nexports.isConcurrentMode = isConcurrentMode;\nexports.isContextConsumer = isContextConsumer;\nexports.isContextProvider = isContextProvider;\nexports.isElement = isElement;\nexports.isForwardRef = isForwardRef;\nexports.isFragment = isFragment;\nexports.isLazy = isLazy;\nexports.isMemo = isMemo;\nexports.isPortal = isPortal;\nexports.isProfiler = isProfiler;\nexports.isStrictMode = isStrictMode;\nexports.isSuspense = isSuspense;\nexports.isValidElementType = isValidElementType;\nexports.typeOf = typeOf;\n })();\n}\n","'use strict';\n\nif (process.env.NODE_ENV === 'production') {\n module.exports = require('./cjs/react-is.production.min.js');\n} else {\n module.exports = require('./cjs/react-is.development.js');\n}\n","/*\nobject-assign\n(c) Sindre Sorhus\n@license MIT\n*/\n\n'use strict';\n/* eslint-disable no-unused-vars */\nvar getOwnPropertySymbols = Object.getOwnPropertySymbols;\nvar hasOwnProperty = Object.prototype.hasOwnProperty;\nvar propIsEnumerable = Object.prototype.propertyIsEnumerable;\n\nfunction toObject(val) {\n\tif (val === null || val === undefined) {\n\t\tthrow new TypeError('Object.assign cannot be called with null or undefined');\n\t}\n\n\treturn Object(val);\n}\n\nfunction shouldUseNative() {\n\ttry {\n\t\tif (!Object.assign) {\n\t\t\treturn false;\n\t\t}\n\n\t\t// Detect buggy property enumeration order in older V8 versions.\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=4118\n\t\tvar test1 = new String('abc'); // eslint-disable-line no-new-wrappers\n\t\ttest1[5] = 'de';\n\t\tif (Object.getOwnPropertyNames(test1)[0] === '5') {\n\t\t\treturn false;\n\t\t}\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=3056\n\t\tvar test2 = {};\n\t\tfor (var i = 0; i < 10; i++) {\n\t\t\ttest2['_' + String.fromCharCode(i)] = i;\n\t\t}\n\t\tvar order2 = Object.getOwnPropertyNames(test2).map(function (n) {\n\t\t\treturn test2[n];\n\t\t});\n\t\tif (order2.join('') !== '0123456789') {\n\t\t\treturn false;\n\t\t}\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=3056\n\t\tvar test3 = {};\n\t\t'abcdefghijklmnopqrst'.split('').forEach(function (letter) {\n\t\t\ttest3[letter] = letter;\n\t\t});\n\t\tif (Object.keys(Object.assign({}, test3)).join('') !==\n\t\t\t\t'abcdefghijklmnopqrst') {\n\t\t\treturn false;\n\t\t}\n\n\t\treturn true;\n\t} catch (err) {\n\t\t// We don't expect any of the above to throw, but better to be safe.\n\t\treturn false;\n\t}\n}\n\nmodule.exports = shouldUseNative() ? Object.assign : function (target, source) {\n\tvar from;\n\tvar to = toObject(target);\n\tvar symbols;\n\n\tfor (var s = 1; s < arguments.length; s++) {\n\t\tfrom = Object(arguments[s]);\n\n\t\tfor (var key in from) {\n\t\t\tif (hasOwnProperty.call(from, key)) {\n\t\t\t\tto[key] = from[key];\n\t\t\t}\n\t\t}\n\n\t\tif (getOwnPropertySymbols) {\n\t\t\tsymbols = getOwnPropertySymbols(from);\n\t\t\tfor (var i = 0; i < symbols.length; i++) {\n\t\t\t\tif (propIsEnumerable.call(from, symbols[i])) {\n\t\t\t\t\tto[symbols[i]] = from[symbols[i]];\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\n\treturn to;\n};\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar ReactPropTypesSecret = 'SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED';\n\nmodule.exports = ReactPropTypesSecret;\n","module.exports = Function.call.bind(Object.prototype.hasOwnProperty);\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar printWarning = function() {};\n\nif (process.env.NODE_ENV !== 'production') {\n var ReactPropTypesSecret = require('./lib/ReactPropTypesSecret');\n var loggedTypeFailures = {};\n var has = require('./lib/has');\n\n printWarning = function(text) {\n var message = 'Warning: ' + text;\n if (typeof console !== 'undefined') {\n console.error(message);\n }\n try {\n // --- Welcome to debugging React ---\n // This error was thrown as a convenience so that you can use this stack\n // to find the callsite that caused this warning to fire.\n throw new Error(message);\n } catch (x) { /**/ }\n };\n}\n\n/**\n * Assert that the values match with the type specs.\n * Error messages are memorized and will only be shown once.\n *\n * @param {object} typeSpecs Map of name to a ReactPropType\n * @param {object} values Runtime values that need to be type-checked\n * @param {string} location e.g. \"prop\", \"context\", \"child context\"\n * @param {string} componentName Name of the component for error messages.\n * @param {?Function} getStack Returns the component stack.\n * @private\n */\nfunction checkPropTypes(typeSpecs, values, location, componentName, getStack) {\n if (process.env.NODE_ENV !== 'production') {\n for (var typeSpecName in typeSpecs) {\n if (has(typeSpecs, typeSpecName)) {\n var error;\n // Prop type validation may throw. In case they do, we don't want to\n // fail the render phase where it didn't fail before. So we log it.\n // After these have been cleaned up, we'll let them throw.\n try {\n // This is intentionally an invariant that gets caught. It's the same\n // behavior as without this statement except with a better message.\n if (typeof typeSpecs[typeSpecName] !== 'function') {\n var err = Error(\n (componentName || 'React class') + ': ' + location + ' type `' + typeSpecName + '` is invalid; ' +\n 'it must be a function, usually from the `prop-types` package, but received `' + typeof typeSpecs[typeSpecName] + '`.' +\n 'This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.'\n );\n err.name = 'Invariant Violation';\n throw err;\n }\n error = typeSpecs[typeSpecName](values, typeSpecName, componentName, location, null, ReactPropTypesSecret);\n } catch (ex) {\n error = ex;\n }\n if (error && !(error instanceof Error)) {\n printWarning(\n (componentName || 'React class') + ': type specification of ' +\n location + ' `' + typeSpecName + '` is invalid; the type checker ' +\n 'function must return `null` or an `Error` but returned a ' + typeof error + '. ' +\n 'You may have forgotten to pass an argument to the type checker ' +\n 'creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and ' +\n 'shape all require an argument).'\n );\n }\n if (error instanceof Error && !(error.message in loggedTypeFailures)) {\n // Only monitor this failure once because there tends to be a lot of the\n // same error.\n loggedTypeFailures[error.message] = true;\n\n var stack = getStack ? getStack() : '';\n\n printWarning(\n 'Failed ' + location + ' type: ' + error.message + (stack != null ? stack : '')\n );\n }\n }\n }\n }\n}\n\n/**\n * Resets warning cache when testing.\n *\n * @private\n */\ncheckPropTypes.resetWarningCache = function() {\n if (process.env.NODE_ENV !== 'production') {\n loggedTypeFailures = {};\n }\n}\n\nmodule.exports = checkPropTypes;\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar ReactIs = require('react-is');\nvar assign = require('object-assign');\n\nvar ReactPropTypesSecret = require('./lib/ReactPropTypesSecret');\nvar has = require('./lib/has');\nvar checkPropTypes = require('./checkPropTypes');\n\nvar printWarning = function() {};\n\nif (process.env.NODE_ENV !== 'production') {\n printWarning = function(text) {\n var message = 'Warning: ' + text;\n if (typeof console !== 'undefined') {\n console.error(message);\n }\n try {\n // --- Welcome to debugging React ---\n // This error was thrown as a convenience so that you can use this stack\n // to find the callsite that caused this warning to fire.\n throw new Error(message);\n } catch (x) {}\n };\n}\n\nfunction emptyFunctionThatReturnsNull() {\n return null;\n}\n\nmodule.exports = function(isValidElement, throwOnDirectAccess) {\n /* global Symbol */\n var ITERATOR_SYMBOL = typeof Symbol === 'function' && Symbol.iterator;\n var FAUX_ITERATOR_SYMBOL = '@@iterator'; // Before Symbol spec.\n\n /**\n * Returns the iterator method function contained on the iterable object.\n *\n * Be sure to invoke the function with the iterable as context:\n *\n * var iteratorFn = getIteratorFn(myIterable);\n * if (iteratorFn) {\n * var iterator = iteratorFn.call(myIterable);\n * ...\n * }\n *\n * @param {?object} maybeIterable\n * @return {?function}\n */\n function getIteratorFn(maybeIterable) {\n var iteratorFn = maybeIterable && (ITERATOR_SYMBOL && maybeIterable[ITERATOR_SYMBOL] || maybeIterable[FAUX_ITERATOR_SYMBOL]);\n if (typeof iteratorFn === 'function') {\n return iteratorFn;\n }\n }\n\n /**\n * Collection of methods that allow declaration and validation of props that are\n * supplied to React components. Example usage:\n *\n * var Props = require('ReactPropTypes');\n * var MyArticle = React.createClass({\n * propTypes: {\n * // An optional string prop named \"description\".\n * description: Props.string,\n *\n * // A required enum prop named \"category\".\n * category: Props.oneOf(['News','Photos']).isRequired,\n *\n * // A prop named \"dialog\" that requires an instance of Dialog.\n * dialog: Props.instanceOf(Dialog).isRequired\n * },\n * render: function() { ... }\n * });\n *\n * A more formal specification of how these methods are used:\n *\n * type := array|bool|func|object|number|string|oneOf([...])|instanceOf(...)\n * decl := ReactPropTypes.{type}(.isRequired)?\n *\n * Each and every declaration produces a function with the same signature. This\n * allows the creation of custom validation functions. For example:\n *\n * var MyLink = React.createClass({\n * propTypes: {\n * // An optional string or URI prop named \"href\".\n * href: function(props, propName, componentName) {\n * var propValue = props[propName];\n * if (propValue != null && typeof propValue !== 'string' &&\n * !(propValue instanceof URI)) {\n * return new Error(\n * 'Expected a string or an URI for ' + propName + ' in ' +\n * componentName\n * );\n * }\n * }\n * },\n * render: function() {...}\n * });\n *\n * @internal\n */\n\n var ANONYMOUS = '<>';\n\n // Important!\n // Keep this list in sync with production version in `./factoryWithThrowingShims.js`.\n var ReactPropTypes = {\n array: createPrimitiveTypeChecker('array'),\n bigint: createPrimitiveTypeChecker('bigint'),\n bool: createPrimitiveTypeChecker('boolean'),\n func: createPrimitiveTypeChecker('function'),\n number: createPrimitiveTypeChecker('number'),\n object: createPrimitiveTypeChecker('object'),\n string: createPrimitiveTypeChecker('string'),\n symbol: createPrimitiveTypeChecker('symbol'),\n\n any: createAnyTypeChecker(),\n arrayOf: createArrayOfTypeChecker,\n element: createElementTypeChecker(),\n elementType: createElementTypeTypeChecker(),\n instanceOf: createInstanceTypeChecker,\n node: createNodeChecker(),\n objectOf: createObjectOfTypeChecker,\n oneOf: createEnumTypeChecker,\n oneOfType: createUnionTypeChecker,\n shape: createShapeTypeChecker,\n exact: createStrictShapeTypeChecker,\n };\n\n /**\n * inlined Object.is polyfill to avoid requiring consumers ship their own\n * https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object/is\n */\n /*eslint-disable no-self-compare*/\n function is(x, y) {\n // SameValue algorithm\n if (x === y) {\n // Steps 1-5, 7-10\n // Steps 6.b-6.e: +0 != -0\n return x !== 0 || 1 / x === 1 / y;\n } else {\n // Step 6.a: NaN == NaN\n return x !== x && y !== y;\n }\n }\n /*eslint-enable no-self-compare*/\n\n /**\n * We use an Error-like object for backward compatibility as people may call\n * PropTypes directly and inspect their output. However, we don't use real\n * Errors anymore. We don't inspect their stack anyway, and creating them\n * is prohibitively expensive if they are created too often, such as what\n * happens in oneOfType() for any type before the one that matched.\n */\n function PropTypeError(message, data) {\n this.message = message;\n this.data = data && typeof data === 'object' ? data: {};\n this.stack = '';\n }\n // Make `instanceof Error` still work for returned errors.\n PropTypeError.prototype = Error.prototype;\n\n function createChainableTypeChecker(validate) {\n if (process.env.NODE_ENV !== 'production') {\n var manualPropTypeCallCache = {};\n var manualPropTypeWarningCount = 0;\n }\n function checkType(isRequired, props, propName, componentName, location, propFullName, secret) {\n componentName = componentName || ANONYMOUS;\n propFullName = propFullName || propName;\n\n if (secret !== ReactPropTypesSecret) {\n if (throwOnDirectAccess) {\n // New behavior only for users of `prop-types` package\n var err = new Error(\n 'Calling PropTypes validators directly is not supported by the `prop-types` package. ' +\n 'Use `PropTypes.checkPropTypes()` to call them. ' +\n 'Read more at http://fb.me/use-check-prop-types'\n );\n err.name = 'Invariant Violation';\n throw err;\n } else if (process.env.NODE_ENV !== 'production' && typeof console !== 'undefined') {\n // Old behavior for people using React.PropTypes\n var cacheKey = componentName + ':' + propName;\n if (\n !manualPropTypeCallCache[cacheKey] &&\n // Avoid spamming the console because they are often not actionable except for lib authors\n manualPropTypeWarningCount < 3\n ) {\n printWarning(\n 'You are manually calling a React.PropTypes validation ' +\n 'function for the `' + propFullName + '` prop on `' + componentName + '`. This is deprecated ' +\n 'and will throw in the standalone `prop-types` package. ' +\n 'You may be seeing this warning due to a third-party PropTypes ' +\n 'library. See https://fb.me/react-warning-dont-call-proptypes ' + 'for details.'\n );\n manualPropTypeCallCache[cacheKey] = true;\n manualPropTypeWarningCount++;\n }\n }\n }\n if (props[propName] == null) {\n if (isRequired) {\n if (props[propName] === null) {\n return new PropTypeError('The ' + location + ' `' + propFullName + '` is marked as required ' + ('in `' + componentName + '`, but its value is `null`.'));\n }\n return new PropTypeError('The ' + location + ' `' + propFullName + '` is marked as required in ' + ('`' + componentName + '`, but its value is `undefined`.'));\n }\n return null;\n } else {\n return validate(props, propName, componentName, location, propFullName);\n }\n }\n\n var chainedCheckType = checkType.bind(null, false);\n chainedCheckType.isRequired = checkType.bind(null, true);\n\n return chainedCheckType;\n }\n\n function createPrimitiveTypeChecker(expectedType) {\n function validate(props, propName, componentName, location, propFullName, secret) {\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== expectedType) {\n // `propValue` being instance of, say, date/regexp, pass the 'object'\n // check, but we can offer a more precise error message here rather than\n // 'of type `object`'.\n var preciseType = getPreciseType(propValue);\n\n return new PropTypeError(\n 'Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + preciseType + '` supplied to `' + componentName + '`, expected ') + ('`' + expectedType + '`.'),\n {expectedType: expectedType}\n );\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createAnyTypeChecker() {\n return createChainableTypeChecker(emptyFunctionThatReturnsNull);\n }\n\n function createArrayOfTypeChecker(typeChecker) {\n function validate(props, propName, componentName, location, propFullName) {\n if (typeof typeChecker !== 'function') {\n return new PropTypeError('Property `' + propFullName + '` of component `' + componentName + '` has invalid PropType notation inside arrayOf.');\n }\n var propValue = props[propName];\n if (!Array.isArray(propValue)) {\n var propType = getPropType(propValue);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected an array.'));\n }\n for (var i = 0; i < propValue.length; i++) {\n var error = typeChecker(propValue, i, componentName, location, propFullName + '[' + i + ']', ReactPropTypesSecret);\n if (error instanceof Error) {\n return error;\n }\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createElementTypeChecker() {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n if (!isValidElement(propValue)) {\n var propType = getPropType(propValue);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected a single ReactElement.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createElementTypeTypeChecker() {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n if (!ReactIs.isValidElementType(propValue)) {\n var propType = getPropType(propValue);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected a single ReactElement type.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createInstanceTypeChecker(expectedClass) {\n function validate(props, propName, componentName, location, propFullName) {\n if (!(props[propName] instanceof expectedClass)) {\n var expectedClassName = expectedClass.name || ANONYMOUS;\n var actualClassName = getClassName(props[propName]);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + actualClassName + '` supplied to `' + componentName + '`, expected ') + ('instance of `' + expectedClassName + '`.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createEnumTypeChecker(expectedValues) {\n if (!Array.isArray(expectedValues)) {\n if (process.env.NODE_ENV !== 'production') {\n if (arguments.length > 1) {\n printWarning(\n 'Invalid arguments supplied to oneOf, expected an array, got ' + arguments.length + ' arguments. ' +\n 'A common mistake is to write oneOf(x, y, z) instead of oneOf([x, y, z]).'\n );\n } else {\n printWarning('Invalid argument supplied to oneOf, expected an array.');\n }\n }\n return emptyFunctionThatReturnsNull;\n }\n\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n for (var i = 0; i < expectedValues.length; i++) {\n if (is(propValue, expectedValues[i])) {\n return null;\n }\n }\n\n var valuesString = JSON.stringify(expectedValues, function replacer(key, value) {\n var type = getPreciseType(value);\n if (type === 'symbol') {\n return String(value);\n }\n return value;\n });\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of value `' + String(propValue) + '` ' + ('supplied to `' + componentName + '`, expected one of ' + valuesString + '.'));\n }\n return createChainableTypeChecker(validate);\n }\n\n function createObjectOfTypeChecker(typeChecker) {\n function validate(props, propName, componentName, location, propFullName) {\n if (typeof typeChecker !== 'function') {\n return new PropTypeError('Property `' + propFullName + '` of component `' + componentName + '` has invalid PropType notation inside objectOf.');\n }\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== 'object') {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected an object.'));\n }\n for (var key in propValue) {\n if (has(propValue, key)) {\n var error = typeChecker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret);\n if (error instanceof Error) {\n return error;\n }\n }\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createUnionTypeChecker(arrayOfTypeCheckers) {\n if (!Array.isArray(arrayOfTypeCheckers)) {\n process.env.NODE_ENV !== 'production' ? printWarning('Invalid argument supplied to oneOfType, expected an instance of array.') : void 0;\n return emptyFunctionThatReturnsNull;\n }\n\n for (var i = 0; i < arrayOfTypeCheckers.length; i++) {\n var checker = arrayOfTypeCheckers[i];\n if (typeof checker !== 'function') {\n printWarning(\n 'Invalid argument supplied to oneOfType. Expected an array of check functions, but ' +\n 'received ' + getPostfixForTypeWarning(checker) + ' at index ' + i + '.'\n );\n return emptyFunctionThatReturnsNull;\n }\n }\n\n function validate(props, propName, componentName, location, propFullName) {\n var expectedTypes = [];\n for (var i = 0; i < arrayOfTypeCheckers.length; i++) {\n var checker = arrayOfTypeCheckers[i];\n var checkerResult = checker(props, propName, componentName, location, propFullName, ReactPropTypesSecret);\n if (checkerResult == null) {\n return null;\n }\n if (checkerResult.data && has(checkerResult.data, 'expectedType')) {\n expectedTypes.push(checkerResult.data.expectedType);\n }\n }\n var expectedTypesMessage = (expectedTypes.length > 0) ? ', expected one of type [' + expectedTypes.join(', ') + ']': '';\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` supplied to ' + ('`' + componentName + '`' + expectedTypesMessage + '.'));\n }\n return createChainableTypeChecker(validate);\n }\n\n function createNodeChecker() {\n function validate(props, propName, componentName, location, propFullName) {\n if (!isNode(props[propName])) {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` supplied to ' + ('`' + componentName + '`, expected a ReactNode.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function invalidValidatorError(componentName, location, propFullName, key, type) {\n return new PropTypeError(\n (componentName || 'React class') + ': ' + location + ' type `' + propFullName + '.' + key + '` is invalid; ' +\n 'it must be a function, usually from the `prop-types` package, but received `' + type + '`.'\n );\n }\n\n function createShapeTypeChecker(shapeTypes) {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== 'object') {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type `' + propType + '` ' + ('supplied to `' + componentName + '`, expected `object`.'));\n }\n for (var key in shapeTypes) {\n var checker = shapeTypes[key];\n if (typeof checker !== 'function') {\n return invalidValidatorError(componentName, location, propFullName, key, getPreciseType(checker));\n }\n var error = checker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret);\n if (error) {\n return error;\n }\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createStrictShapeTypeChecker(shapeTypes) {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== 'object') {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type `' + propType + '` ' + ('supplied to `' + componentName + '`, expected `object`.'));\n }\n // We need to check all keys in case some are required but missing from props.\n var allKeys = assign({}, props[propName], shapeTypes);\n for (var key in allKeys) {\n var checker = shapeTypes[key];\n if (has(shapeTypes, key) && typeof checker !== 'function') {\n return invalidValidatorError(componentName, location, propFullName, key, getPreciseType(checker));\n }\n if (!checker) {\n return new PropTypeError(\n 'Invalid ' + location + ' `' + propFullName + '` key `' + key + '` supplied to `' + componentName + '`.' +\n '\\nBad object: ' + JSON.stringify(props[propName], null, ' ') +\n '\\nValid keys: ' + JSON.stringify(Object.keys(shapeTypes), null, ' ')\n );\n }\n var error = checker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret);\n if (error) {\n return error;\n }\n }\n return null;\n }\n\n return createChainableTypeChecker(validate);\n }\n\n function isNode(propValue) {\n switch (typeof propValue) {\n case 'number':\n case 'string':\n case 'undefined':\n return true;\n case 'boolean':\n return !propValue;\n case 'object':\n if (Array.isArray(propValue)) {\n return propValue.every(isNode);\n }\n if (propValue === null || isValidElement(propValue)) {\n return true;\n }\n\n var iteratorFn = getIteratorFn(propValue);\n if (iteratorFn) {\n var iterator = iteratorFn.call(propValue);\n var step;\n if (iteratorFn !== propValue.entries) {\n while (!(step = iterator.next()).done) {\n if (!isNode(step.value)) {\n return false;\n }\n }\n } else {\n // Iterator will provide entry [k,v] tuples rather than values.\n while (!(step = iterator.next()).done) {\n var entry = step.value;\n if (entry) {\n if (!isNode(entry[1])) {\n return false;\n }\n }\n }\n }\n } else {\n return false;\n }\n\n return true;\n default:\n return false;\n }\n }\n\n function isSymbol(propType, propValue) {\n // Native Symbol.\n if (propType === 'symbol') {\n return true;\n }\n\n // falsy value can't be a Symbol\n if (!propValue) {\n return false;\n }\n\n // 19.4.3.5 Symbol.prototype[@@toStringTag] === 'Symbol'\n if (propValue['@@toStringTag'] === 'Symbol') {\n return true;\n }\n\n // Fallback for non-spec compliant Symbols which are polyfilled.\n if (typeof Symbol === 'function' && propValue instanceof Symbol) {\n return true;\n }\n\n return false;\n }\n\n // Equivalent of `typeof` but with special handling for array and regexp.\n function getPropType(propValue) {\n var propType = typeof propValue;\n if (Array.isArray(propValue)) {\n return 'array';\n }\n if (propValue instanceof RegExp) {\n // Old webkits (at least until Android 4.0) return 'function' rather than\n // 'object' for typeof a RegExp. We'll normalize this here so that /bla/\n // passes PropTypes.object.\n return 'object';\n }\n if (isSymbol(propType, propValue)) {\n return 'symbol';\n }\n return propType;\n }\n\n // This handles more types than `getPropType`. Only used for error messages.\n // See `createPrimitiveTypeChecker`.\n function getPreciseType(propValue) {\n if (typeof propValue === 'undefined' || propValue === null) {\n return '' + propValue;\n }\n var propType = getPropType(propValue);\n if (propType === 'object') {\n if (propValue instanceof Date) {\n return 'date';\n } else if (propValue instanceof RegExp) {\n return 'regexp';\n }\n }\n return propType;\n }\n\n // Returns a string that is postfixed to a warning about an invalid type.\n // For example, \"undefined\" or \"of type array\"\n function getPostfixForTypeWarning(value) {\n var type = getPreciseType(value);\n switch (type) {\n case 'array':\n case 'object':\n return 'an ' + type;\n case 'boolean':\n case 'date':\n case 'regexp':\n return 'a ' + type;\n default:\n return type;\n }\n }\n\n // Returns class name of the object, if any.\n function getClassName(propValue) {\n if (!propValue.constructor || !propValue.constructor.name) {\n return ANONYMOUS;\n }\n return propValue.constructor.name;\n }\n\n ReactPropTypes.checkPropTypes = checkPropTypes;\n ReactPropTypes.resetWarningCache = checkPropTypes.resetWarningCache;\n ReactPropTypes.PropTypes = ReactPropTypes;\n\n return ReactPropTypes;\n};\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar ReactPropTypesSecret = require('./lib/ReactPropTypesSecret');\n\nfunction emptyFunction() {}\nfunction emptyFunctionWithReset() {}\nemptyFunctionWithReset.resetWarningCache = emptyFunction;\n\nmodule.exports = function() {\n function shim(props, propName, componentName, location, propFullName, secret) {\n if (secret === ReactPropTypesSecret) {\n // It is still safe when called from React.\n return;\n }\n var err = new Error(\n 'Calling PropTypes validators directly is not supported by the `prop-types` package. ' +\n 'Use PropTypes.checkPropTypes() to call them. ' +\n 'Read more at http://fb.me/use-check-prop-types'\n );\n err.name = 'Invariant Violation';\n throw err;\n };\n shim.isRequired = shim;\n function getShim() {\n return shim;\n };\n // Important!\n // Keep this list in sync with production version in `./factoryWithTypeCheckers.js`.\n var ReactPropTypes = {\n array: shim,\n bigint: shim,\n bool: shim,\n func: shim,\n number: shim,\n object: shim,\n string: shim,\n symbol: shim,\n\n any: shim,\n arrayOf: getShim,\n element: shim,\n elementType: shim,\n instanceOf: getShim,\n node: shim,\n objectOf: getShim,\n oneOf: getShim,\n oneOfType: getShim,\n shape: getShim,\n exact: getShim,\n\n checkPropTypes: emptyFunctionWithReset,\n resetWarningCache: emptyFunction\n };\n\n ReactPropTypes.PropTypes = ReactPropTypes;\n\n return ReactPropTypes;\n};\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\nif (process.env.NODE_ENV !== 'production') {\n var ReactIs = require('react-is');\n\n // By explicitly using `prop-types` you are opting into new development behavior.\n // http://fb.me/prop-types-in-prod\n var throwOnDirectAccess = true;\n module.exports = require('./factoryWithTypeCheckers')(ReactIs.isElement, throwOnDirectAccess);\n} else {\n // By explicitly using `prop-types` you are opting into new production behavior.\n // http://fb.me/prop-types-in-prod\n module.exports = require('./factoryWithThrowingShims')();\n}\n","import PropTypes from 'prop-types';\nimport chainPropTypes from '../chainPropTypes';\nfunction isClassComponent(elementType) {\n // elementType.prototype?.isReactComponent\n const {\n prototype = {}\n } = elementType;\n return Boolean(prototype.isReactComponent);\n}\nfunction acceptingRef(props, propName, componentName, location, propFullName) {\n const element = props[propName];\n const safePropName = propFullName || propName;\n if (element == null ||\n // When server-side rendering React doesn't warn either.\n // This is not an accurate check for SSR.\n // This is only in place for Emotion compat.\n // TODO: Revisit once https://github.com/facebook/react/issues/20047 is resolved.\n typeof window === 'undefined') {\n return null;\n }\n let warningHint;\n const elementType = element.type;\n /**\n * Blacklisting instead of whitelisting\n *\n * Blacklisting will miss some components, such as React.Fragment. Those will at least\n * trigger a warning in React.\n * We can't whitelist because there is no safe way to detect React.forwardRef\n * or class components. \"Safe\" means there's no public API.\n *\n */\n if (typeof elementType === 'function' && !isClassComponent(elementType)) {\n warningHint = 'Did you accidentally use a plain function component for an element instead?';\n }\n if (warningHint !== undefined) {\n return new Error(`Invalid ${location} \\`${safePropName}\\` supplied to \\`${componentName}\\`. ` + `Expected an element that can hold a ref. ${warningHint} ` + 'For more information see https://mui.com/r/caveat-with-refs-guide');\n }\n return null;\n}\nconst elementAcceptingRef = chainPropTypes(PropTypes.element, acceptingRef);\nelementAcceptingRef.isRequired = chainPropTypes(PropTypes.element.isRequired, acceptingRef);\nexport default elementAcceptingRef;","import _extends from \"@babel/runtime/helpers/esm/extends\";\n// This module is based on https://github.com/airbnb/prop-types-exact repository.\n// However, in order to reduce the number of dependencies and to remove some extra safe checks\n// the module was forked.\n\nconst specialProperty = 'exact-prop: \\u200b';\nexport default function exactProp(propTypes) {\n if (process.env.NODE_ENV === 'production') {\n return propTypes;\n }\n return _extends({}, propTypes, {\n [specialProperty]: props => {\n const unsupportedProps = Object.keys(props).filter(prop => !propTypes.hasOwnProperty(prop));\n if (unsupportedProps.length > 0) {\n return new Error(`The following props are not supported: ${unsupportedProps.map(prop => `\\`${prop}\\``).join(', ')}. Please remove them.`);\n }\n return null;\n }\n });\n}","/**\n * WARNING: Don't import this directly.\n * Use `MuiError` from `@mui/internal-babel-macros/MuiError.macro` instead.\n * @param {number} code\n */\nexport default function formatMuiErrorMessage(code) {\n // Apply babel-plugin-transform-template-literals in loose mode\n // loose mode is safe if we're concatenating primitives\n // see https://babeljs.io/docs/en/babel-plugin-transform-template-literals#loose\n /* eslint-disable prefer-template */\n let url = 'https://mui.com/production-error/?code=' + code;\n for (let i = 1; i < arguments.length; i += 1) {\n // rest params over-transpile for this case\n // eslint-disable-next-line prefer-rest-params\n url += '&args[]=' + encodeURIComponent(arguments[i]);\n }\n return 'Minified MUI error #' + code + '; visit ' + url + ' for the full message.';\n /* eslint-enable prefer-template */\n}","/**\n * @license React\n * react-is.production.min.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n'use strict';var b=Symbol.for(\"react.element\"),c=Symbol.for(\"react.portal\"),d=Symbol.for(\"react.fragment\"),e=Symbol.for(\"react.strict_mode\"),f=Symbol.for(\"react.profiler\"),g=Symbol.for(\"react.provider\"),h=Symbol.for(\"react.context\"),k=Symbol.for(\"react.server_context\"),l=Symbol.for(\"react.forward_ref\"),m=Symbol.for(\"react.suspense\"),n=Symbol.for(\"react.suspense_list\"),p=Symbol.for(\"react.memo\"),q=Symbol.for(\"react.lazy\"),t=Symbol.for(\"react.offscreen\"),u;u=Symbol.for(\"react.module.reference\");\nfunction v(a){if(\"object\"===typeof a&&null!==a){var r=a.$$typeof;switch(r){case b:switch(a=a.type,a){case d:case f:case e:case m:case n:return a;default:switch(a=a&&a.$$typeof,a){case k:case h:case l:case q:case p:case g:return a;default:return r}}case c:return r}}}exports.ContextConsumer=h;exports.ContextProvider=g;exports.Element=b;exports.ForwardRef=l;exports.Fragment=d;exports.Lazy=q;exports.Memo=p;exports.Portal=c;exports.Profiler=f;exports.StrictMode=e;exports.Suspense=m;\nexports.SuspenseList=n;exports.isAsyncMode=function(){return!1};exports.isConcurrentMode=function(){return!1};exports.isContextConsumer=function(a){return v(a)===h};exports.isContextProvider=function(a){return v(a)===g};exports.isElement=function(a){return\"object\"===typeof a&&null!==a&&a.$$typeof===b};exports.isForwardRef=function(a){return v(a)===l};exports.isFragment=function(a){return v(a)===d};exports.isLazy=function(a){return v(a)===q};exports.isMemo=function(a){return v(a)===p};\nexports.isPortal=function(a){return v(a)===c};exports.isProfiler=function(a){return v(a)===f};exports.isStrictMode=function(a){return v(a)===e};exports.isSuspense=function(a){return v(a)===m};exports.isSuspenseList=function(a){return v(a)===n};\nexports.isValidElementType=function(a){return\"string\"===typeof a||\"function\"===typeof a||a===d||a===f||a===e||a===m||a===n||a===t||\"object\"===typeof a&&null!==a&&(a.$$typeof===q||a.$$typeof===p||a.$$typeof===g||a.$$typeof===h||a.$$typeof===l||a.$$typeof===u||void 0!==a.getModuleId)?!0:!1};exports.typeOf=v;\n","/**\n * @license React\n * react-is.development.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nif (process.env.NODE_ENV !== \"production\") {\n (function() {\n'use strict';\n\n// ATTENTION\n// When adding new symbols to this file,\n// Please consider also adding to 'react-devtools-shared/src/backend/ReactSymbols'\n// The Symbol used to tag the ReactElement-like types.\nvar REACT_ELEMENT_TYPE = Symbol.for('react.element');\nvar REACT_PORTAL_TYPE = Symbol.for('react.portal');\nvar REACT_FRAGMENT_TYPE = Symbol.for('react.fragment');\nvar REACT_STRICT_MODE_TYPE = Symbol.for('react.strict_mode');\nvar REACT_PROFILER_TYPE = Symbol.for('react.profiler');\nvar REACT_PROVIDER_TYPE = Symbol.for('react.provider');\nvar REACT_CONTEXT_TYPE = Symbol.for('react.context');\nvar REACT_SERVER_CONTEXT_TYPE = Symbol.for('react.server_context');\nvar REACT_FORWARD_REF_TYPE = Symbol.for('react.forward_ref');\nvar REACT_SUSPENSE_TYPE = Symbol.for('react.suspense');\nvar REACT_SUSPENSE_LIST_TYPE = Symbol.for('react.suspense_list');\nvar REACT_MEMO_TYPE = Symbol.for('react.memo');\nvar REACT_LAZY_TYPE = Symbol.for('react.lazy');\nvar REACT_OFFSCREEN_TYPE = Symbol.for('react.offscreen');\n\n// -----------------------------------------------------------------------------\n\nvar enableScopeAPI = false; // Experimental Create Event Handle API.\nvar enableCacheElement = false;\nvar enableTransitionTracing = false; // No known bugs, but needs performance testing\n\nvar enableLegacyHidden = false; // Enables unstable_avoidThisFallback feature in Fiber\n// stuff. Intended to enable React core members to more easily debug scheduling\n// issues in DEV builds.\n\nvar enableDebugTracing = false; // Track which Fiber(s) schedule render work.\n\nvar REACT_MODULE_REFERENCE;\n\n{\n REACT_MODULE_REFERENCE = Symbol.for('react.module.reference');\n}\n\nfunction isValidElementType(type) {\n if (typeof type === 'string' || typeof type === 'function') {\n return true;\n } // Note: typeof might be other than 'symbol' or 'number' (e.g. if it's a polyfill).\n\n\n if (type === REACT_FRAGMENT_TYPE || type === REACT_PROFILER_TYPE || enableDebugTracing || type === REACT_STRICT_MODE_TYPE || type === REACT_SUSPENSE_TYPE || type === REACT_SUSPENSE_LIST_TYPE || enableLegacyHidden || type === REACT_OFFSCREEN_TYPE || enableScopeAPI || enableCacheElement || enableTransitionTracing ) {\n return true;\n }\n\n if (typeof type === 'object' && type !== null) {\n if (type.$$typeof === REACT_LAZY_TYPE || type.$$typeof === REACT_MEMO_TYPE || type.$$typeof === REACT_PROVIDER_TYPE || type.$$typeof === REACT_CONTEXT_TYPE || type.$$typeof === REACT_FORWARD_REF_TYPE || // This needs to include all possible module reference object\n // types supported by any Flight configuration anywhere since\n // we don't know which Flight build this will end up being used\n // with.\n type.$$typeof === REACT_MODULE_REFERENCE || type.getModuleId !== undefined) {\n return true;\n }\n }\n\n return false;\n}\n\nfunction typeOf(object) {\n if (typeof object === 'object' && object !== null) {\n var $$typeof = object.$$typeof;\n\n switch ($$typeof) {\n case REACT_ELEMENT_TYPE:\n var type = object.type;\n\n switch (type) {\n case REACT_FRAGMENT_TYPE:\n case REACT_PROFILER_TYPE:\n case REACT_STRICT_MODE_TYPE:\n case REACT_SUSPENSE_TYPE:\n case REACT_SUSPENSE_LIST_TYPE:\n return type;\n\n default:\n var $$typeofType = type && type.$$typeof;\n\n switch ($$typeofType) {\n case REACT_SERVER_CONTEXT_TYPE:\n case REACT_CONTEXT_TYPE:\n case REACT_FORWARD_REF_TYPE:\n case REACT_LAZY_TYPE:\n case REACT_MEMO_TYPE:\n case REACT_PROVIDER_TYPE:\n return $$typeofType;\n\n default:\n return $$typeof;\n }\n\n }\n\n case REACT_PORTAL_TYPE:\n return $$typeof;\n }\n }\n\n return undefined;\n}\nvar ContextConsumer = REACT_CONTEXT_TYPE;\nvar ContextProvider = REACT_PROVIDER_TYPE;\nvar Element = REACT_ELEMENT_TYPE;\nvar ForwardRef = REACT_FORWARD_REF_TYPE;\nvar Fragment = REACT_FRAGMENT_TYPE;\nvar Lazy = REACT_LAZY_TYPE;\nvar Memo = REACT_MEMO_TYPE;\nvar Portal = REACT_PORTAL_TYPE;\nvar Profiler = REACT_PROFILER_TYPE;\nvar StrictMode = REACT_STRICT_MODE_TYPE;\nvar Suspense = REACT_SUSPENSE_TYPE;\nvar SuspenseList = REACT_SUSPENSE_LIST_TYPE;\nvar hasWarnedAboutDeprecatedIsAsyncMode = false;\nvar hasWarnedAboutDeprecatedIsConcurrentMode = false; // AsyncMode should be deprecated\n\nfunction isAsyncMode(object) {\n {\n if (!hasWarnedAboutDeprecatedIsAsyncMode) {\n hasWarnedAboutDeprecatedIsAsyncMode = true; // Using console['warn'] to evade Babel and ESLint\n\n console['warn']('The ReactIs.isAsyncMode() alias has been deprecated, ' + 'and will be removed in React 18+.');\n }\n }\n\n return false;\n}\nfunction isConcurrentMode(object) {\n {\n if (!hasWarnedAboutDeprecatedIsConcurrentMode) {\n hasWarnedAboutDeprecatedIsConcurrentMode = true; // Using console['warn'] to evade Babel and ESLint\n\n console['warn']('The ReactIs.isConcurrentMode() alias has been deprecated, ' + 'and will be removed in React 18+.');\n }\n }\n\n return false;\n}\nfunction isContextConsumer(object) {\n return typeOf(object) === REACT_CONTEXT_TYPE;\n}\nfunction isContextProvider(object) {\n return typeOf(object) === REACT_PROVIDER_TYPE;\n}\nfunction isElement(object) {\n return typeof object === 'object' && object !== null && object.$$typeof === REACT_ELEMENT_TYPE;\n}\nfunction isForwardRef(object) {\n return typeOf(object) === REACT_FORWARD_REF_TYPE;\n}\nfunction isFragment(object) {\n return typeOf(object) === REACT_FRAGMENT_TYPE;\n}\nfunction isLazy(object) {\n return typeOf(object) === REACT_LAZY_TYPE;\n}\nfunction isMemo(object) {\n return typeOf(object) === REACT_MEMO_TYPE;\n}\nfunction isPortal(object) {\n return typeOf(object) === REACT_PORTAL_TYPE;\n}\nfunction isProfiler(object) {\n return typeOf(object) === REACT_PROFILER_TYPE;\n}\nfunction isStrictMode(object) {\n return typeOf(object) === REACT_STRICT_MODE_TYPE;\n}\nfunction isSuspense(object) {\n return typeOf(object) === REACT_SUSPENSE_TYPE;\n}\nfunction isSuspenseList(object) {\n return typeOf(object) === REACT_SUSPENSE_LIST_TYPE;\n}\n\nexports.ContextConsumer = ContextConsumer;\nexports.ContextProvider = ContextProvider;\nexports.Element = Element;\nexports.ForwardRef = ForwardRef;\nexports.Fragment = Fragment;\nexports.Lazy = Lazy;\nexports.Memo = Memo;\nexports.Portal = Portal;\nexports.Profiler = Profiler;\nexports.StrictMode = StrictMode;\nexports.Suspense = Suspense;\nexports.SuspenseList = SuspenseList;\nexports.isAsyncMode = isAsyncMode;\nexports.isConcurrentMode = isConcurrentMode;\nexports.isContextConsumer = isContextConsumer;\nexports.isContextProvider = isContextProvider;\nexports.isElement = isElement;\nexports.isForwardRef = isForwardRef;\nexports.isFragment = isFragment;\nexports.isLazy = isLazy;\nexports.isMemo = isMemo;\nexports.isPortal = isPortal;\nexports.isProfiler = isProfiler;\nexports.isStrictMode = isStrictMode;\nexports.isSuspense = isSuspense;\nexports.isSuspenseList = isSuspenseList;\nexports.isValidElementType = isValidElementType;\nexports.typeOf = typeOf;\n })();\n}\n","'use strict';\n\nif (process.env.NODE_ENV === 'production') {\n module.exports = require('./cjs/react-is.production.min.js');\n} else {\n module.exports = require('./cjs/react-is.development.js');\n}\n","import { ForwardRef, Memo } from 'react-is';\n\n// Simplified polyfill for IE11 support\n// https://github.com/JamesMGreene/Function.name/blob/58b314d4a983110c3682f1228f845d39ccca1817/Function.name.js#L3\nconst fnNameMatchRegex = /^\\s*function(?:\\s|\\s*\\/\\*.*\\*\\/\\s*)+([^(\\s/]*)\\s*/;\nexport function getFunctionName(fn) {\n const match = `${fn}`.match(fnNameMatchRegex);\n const name = match && match[1];\n return name || '';\n}\nfunction getFunctionComponentName(Component, fallback = '') {\n return Component.displayName || Component.name || getFunctionName(Component) || fallback;\n}\nfunction getWrappedName(outerType, innerType, wrapperName) {\n const functionName = getFunctionComponentName(innerType);\n return outerType.displayName || (functionName !== '' ? `${wrapperName}(${functionName})` : wrapperName);\n}\n\n/**\n * cherry-pick from\n * https://github.com/facebook/react/blob/769b1f270e1251d9dbdce0fcbd9e92e502d059b8/packages/shared/getComponentName.js\n * originally forked from recompose/getDisplayName with added IE11 support\n */\nexport default function getDisplayName(Component) {\n if (Component == null) {\n return undefined;\n }\n if (typeof Component === 'string') {\n return Component;\n }\n if (typeof Component === 'function') {\n return getFunctionComponentName(Component, 'Component');\n }\n\n // TypeScript can't have components as objects but they exist in the form of `memo` or `Suspense`\n if (typeof Component === 'object') {\n switch (Component.$$typeof) {\n case ForwardRef:\n return getWrappedName(Component, Component.render, 'ForwardRef');\n case Memo:\n return getWrappedName(Component, Component.type, 'memo');\n default:\n return undefined;\n }\n }\n return undefined;\n}","export default function HTMLElementType(props, propName, componentName, location, propFullName) {\n if (process.env.NODE_ENV === 'production') {\n return null;\n }\n const propValue = props[propName];\n const safePropName = propFullName || propName;\n if (propValue == null) {\n return null;\n }\n if (propValue && propValue.nodeType !== 1) {\n return new Error(`Invalid ${location} \\`${safePropName}\\` supplied to \\`${componentName}\\`. ` + `Expected an HTMLElement.`);\n }\n return null;\n}","import PropTypes from 'prop-types';\nconst refType = PropTypes.oneOfType([PropTypes.func, PropTypes.object]);\nexport default refType;","import _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\n// It should to be noted that this function isn't equivalent to `text-transform: capitalize`.\n//\n// A strict capitalization should uppercase the first letter of each word in the sentence.\n// We only handle the first word.\nexport default function capitalize(string) {\n if (typeof string !== 'string') {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: \\`capitalize(string)\\` expects a string argument.` : _formatMuiErrorMessage(7));\n }\n return string.charAt(0).toUpperCase() + string.slice(1);\n}","/**\n * Safe chained function.\n *\n * Will only create a new function if needed,\n * otherwise will pass back existing functions or null.\n */\nexport default function createChainedFunction(...funcs) {\n return funcs.reduce((acc, func) => {\n if (func == null) {\n return acc;\n }\n return function chainedFunction(...args) {\n acc.apply(this, args);\n func.apply(this, args);\n };\n }, () => {});\n}","// Corresponds to 10 frames at 60 Hz.\n// A few bytes payload overhead when lodash/debounce is ~3 kB and debounce ~300 B.\nexport default function debounce(func, wait = 166) {\n let timeout;\n function debounced(...args) {\n const later = () => {\n // @ts-ignore\n func.apply(this, args);\n };\n clearTimeout(timeout);\n timeout = setTimeout(later, wait);\n }\n debounced.clear = () => {\n clearTimeout(timeout);\n };\n return debounced;\n}","export default function deprecatedPropType(validator, reason) {\n if (process.env.NODE_ENV === 'production') {\n return () => null;\n }\n return (props, propName, componentName, location, propFullName) => {\n const componentNameSafe = componentName || '<>';\n const propFullNameSafe = propFullName || propName;\n if (typeof props[propName] !== 'undefined') {\n return new Error(`The ${location} \\`${propFullNameSafe}\\` of ` + `\\`${componentNameSafe}\\` is deprecated. ${reason}`);\n }\n return null;\n };\n}","import * as React from 'react';\nexport default function isMuiElement(element, muiNames) {\n var _muiName, _element$type;\n return /*#__PURE__*/React.isValidElement(element) && muiNames.indexOf( // For server components `muiName` is avaialble in element.type._payload.value.muiName\n // relevant info - https://github.com/facebook/react/blob/2807d781a08db8e9873687fccc25c0f12b4fb3d4/packages/react/src/ReactLazy.js#L45\n // eslint-disable-next-line no-underscore-dangle\n (_muiName = element.type.muiName) != null ? _muiName : (_element$type = element.type) == null || (_element$type = _element$type._payload) == null || (_element$type = _element$type.value) == null ? void 0 : _element$type.muiName) !== -1;\n}","export default function ownerDocument(node) {\n return node && node.ownerDocument || document;\n}","import ownerDocument from '../ownerDocument';\nexport default function ownerWindow(node) {\n const doc = ownerDocument(node);\n return doc.defaultView || window;\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nexport default function requirePropFactory(componentNameInError, Component) {\n if (process.env.NODE_ENV === 'production') {\n return () => null;\n }\n\n // eslint-disable-next-line react/forbid-foreign-prop-types\n const prevPropTypes = Component ? _extends({}, Component.propTypes) : null;\n const requireProp = requiredProp => (props, propName, componentName, location, propFullName, ...args) => {\n const propFullNameSafe = propFullName || propName;\n const defaultTypeChecker = prevPropTypes == null ? void 0 : prevPropTypes[propFullNameSafe];\n if (defaultTypeChecker) {\n const typeCheckerResult = defaultTypeChecker(props, propName, componentName, location, propFullName, ...args);\n if (typeCheckerResult) {\n return typeCheckerResult;\n }\n }\n if (typeof props[propName] !== 'undefined' && !props[requiredProp]) {\n return new Error(`The prop \\`${propFullNameSafe}\\` of ` + `\\`${componentNameInError}\\` can only be used together with the \\`${requiredProp}\\` prop.`);\n }\n return null;\n };\n return requireProp;\n}","/**\n * TODO v5: consider making it private\n *\n * passes {value} to {ref}\n *\n * WARNING: Be sure to only call this inside a callback that is passed as a ref.\n * Otherwise, make sure to cleanup the previous {ref} if it changes. See\n * https://github.com/mui/material-ui/issues/13539\n *\n * Useful if you want to expose the ref of an inner component to the public API\n * while still using it inside the component.\n * @param ref A ref callback or ref object. If anything falsy, this is a no-op.\n */\nexport default function setRef(ref, value) {\n if (typeof ref === 'function') {\n ref(value);\n } else if (ref) {\n ref.current = value;\n }\n}","'use client';\n\nimport * as React from 'react';\n\n/**\n * A version of `React.useLayoutEffect` that does not show a warning when server-side rendering.\n * This is useful for effects that are only needed for client-side rendering but not for SSR.\n *\n * Before you use this hook, make sure to read https://gist.github.com/gaearon/e7d97cdf38a2907924ea12e4ebdf3c85\n * and confirm it doesn't apply to your use-case.\n */\nconst useEnhancedEffect = typeof window !== 'undefined' ? React.useLayoutEffect : React.useEffect;\nexport default useEnhancedEffect;","'use client';\n\nimport * as React from 'react';\nlet globalId = 0;\nfunction useGlobalId(idOverride) {\n const [defaultId, setDefaultId] = React.useState(idOverride);\n const id = idOverride || defaultId;\n React.useEffect(() => {\n if (defaultId == null) {\n // Fallback to this default id when possible.\n // Use the incrementing value for client-side rendering only.\n // We can't use it server-side.\n // If you want to use random values please consider the Birthday Problem: https://en.wikipedia.org/wiki/Birthday_problem\n globalId += 1;\n setDefaultId(`mui-${globalId}`);\n }\n }, [defaultId]);\n return id;\n}\n\n// downstream bundlers may remove unnecessary concatenation, but won't remove toString call -- Workaround for https://github.com/webpack/webpack/issues/14814\nconst maybeReactUseId = React['useId'.toString()];\n/**\n *\n * @example
    \n * @param idOverride\n * @returns {string}\n */\nexport default function useId(idOverride) {\n if (maybeReactUseId !== undefined) {\n const reactId = maybeReactUseId();\n return idOverride != null ? idOverride : reactId;\n }\n // eslint-disable-next-line react-hooks/rules-of-hooks -- `React.useId` is invariant at runtime.\n return useGlobalId(idOverride);\n}","export default function unsupportedProp(props, propName, componentName, location, propFullName) {\n if (process.env.NODE_ENV === 'production') {\n return null;\n }\n const propFullNameSafe = propFullName || propName;\n if (typeof props[propName] !== 'undefined') {\n return new Error(`The prop \\`${propFullNameSafe}\\` is not supported. Please remove it.`);\n }\n return null;\n}","'use client';\n\n/* eslint-disable react-hooks/rules-of-hooks, react-hooks/exhaustive-deps */\nimport * as React from 'react';\nexport default function useControlled({\n controlled,\n default: defaultProp,\n name,\n state = 'value'\n}) {\n // isControlled is ignored in the hook dependency lists as it should never change.\n const {\n current: isControlled\n } = React.useRef(controlled !== undefined);\n const [valueState, setValue] = React.useState(defaultProp);\n const value = isControlled ? controlled : valueState;\n if (process.env.NODE_ENV !== 'production') {\n React.useEffect(() => {\n if (isControlled !== (controlled !== undefined)) {\n console.error([`MUI: A component is changing the ${isControlled ? '' : 'un'}controlled ${state} state of ${name} to be ${isControlled ? 'un' : ''}controlled.`, 'Elements should not switch from uncontrolled to controlled (or vice versa).', `Decide between using a controlled or uncontrolled ${name} ` + 'element for the lifetime of the component.', \"The nature of the state is determined during the first render. It's considered controlled if the value is not `undefined`.\", 'More info: https://fb.me/react-controlled-components'].join('\\n'));\n }\n }, [state, name, controlled]);\n const {\n current: defaultValue\n } = React.useRef(defaultProp);\n React.useEffect(() => {\n if (!isControlled && defaultValue !== defaultProp) {\n console.error([`MUI: A component is changing the default ${state} state of an uncontrolled ${name} after being initialized. ` + `To suppress this warning opt to use a controlled ${name}.`].join('\\n'));\n }\n }, [JSON.stringify(defaultProp)]);\n }\n const setValueIfUncontrolled = React.useCallback(newValue => {\n if (!isControlled) {\n setValue(newValue);\n }\n }, []);\n return [value, setValueIfUncontrolled];\n}","'use client';\n\nimport * as React from 'react';\nimport useEnhancedEffect from '../useEnhancedEffect';\n\n/**\n * Inspired by https://github.com/facebook/react/issues/14099#issuecomment-440013892\n * See RFC in https://github.com/reactjs/rfcs/pull/220\n */\n\nfunction useEventCallback(fn) {\n const ref = React.useRef(fn);\n useEnhancedEffect(() => {\n ref.current = fn;\n });\n return React.useRef((...args) =>\n // @ts-expect-error hide `this`\n (0, ref.current)(...args)).current;\n}\nexport default useEventCallback;","'use client';\n\nimport * as React from 'react';\nimport setRef from '../setRef';\nexport default function useForkRef(...refs) {\n /**\n * This will create a new function if the refs passed to this hook change and are all defined.\n * This means react will call the old forkRef with `null` and the new forkRef\n * with the ref. Cleanup naturally emerges from this behavior.\n */\n return React.useMemo(() => {\n if (refs.every(ref => ref == null)) {\n return null;\n }\n return instance => {\n refs.forEach(ref => {\n setRef(ref, instance);\n });\n };\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, refs);\n}","'use client';\n\nimport * as React from 'react';\nconst UNINITIALIZED = {};\n\n/**\n * A React.useRef() that is initialized lazily with a function. Note that it accepts an optional\n * initialization argument, so the initialization function doesn't need to be an inline closure.\n *\n * @usage\n * const ref = useLazyRef(sortColumns, columns)\n */\nexport default function useLazyRef(init, initArg) {\n const ref = React.useRef(UNINITIALIZED);\n if (ref.current === UNINITIALIZED) {\n ref.current = init(initArg);\n }\n return ref;\n}","'use client';\n\nimport * as React from 'react';\nconst EMPTY = [];\n\n/**\n * A React.useEffect equivalent that runs once, when the component is mounted.\n */\nexport default function useOnMount(fn) {\n /* eslint-disable react-hooks/exhaustive-deps */\n React.useEffect(fn, EMPTY);\n /* eslint-enable react-hooks/exhaustive-deps */\n}","'use client';\n\nimport useLazyRef from '../useLazyRef/useLazyRef';\nimport useOnMount from '../useOnMount/useOnMount';\nexport class Timeout {\n constructor() {\n this.currentId = null;\n this.clear = () => {\n if (this.currentId !== null) {\n clearTimeout(this.currentId);\n this.currentId = null;\n }\n };\n this.disposeEffect = () => {\n return this.clear;\n };\n }\n static create() {\n return new Timeout();\n }\n /**\n * Executes `fn` after `delay`, clearing any previously scheduled call.\n */\n start(delay, fn) {\n this.clear();\n this.currentId = setTimeout(() => {\n this.currentId = null;\n fn();\n }, delay);\n }\n}\nexport default function useTimeout() {\n const timeout = useLazyRef(Timeout.create).current;\n useOnMount(timeout.disposeEffect);\n return timeout;\n}","'use client';\n\n// based on https://github.com/WICG/focus-visible/blob/v4.1.5/src/focus-visible.js\nimport * as React from 'react';\nimport { Timeout } from '../useTimeout/useTimeout';\nlet hadKeyboardEvent = true;\nlet hadFocusVisibleRecently = false;\nconst hadFocusVisibleRecentlyTimeout = new Timeout();\nconst inputTypesWhitelist = {\n text: true,\n search: true,\n url: true,\n tel: true,\n email: true,\n password: true,\n number: true,\n date: true,\n month: true,\n week: true,\n time: true,\n datetime: true,\n 'datetime-local': true\n};\n\n/**\n * Computes whether the given element should automatically trigger the\n * `focus-visible` class being added, i.e. whether it should always match\n * `:focus-visible` when focused.\n * @param {Element} node\n * @returns {boolean}\n */\nfunction focusTriggersKeyboardModality(node) {\n const {\n type,\n tagName\n } = node;\n if (tagName === 'INPUT' && inputTypesWhitelist[type] && !node.readOnly) {\n return true;\n }\n if (tagName === 'TEXTAREA' && !node.readOnly) {\n return true;\n }\n if (node.isContentEditable) {\n return true;\n }\n return false;\n}\n\n/**\n * Keep track of our keyboard modality state with `hadKeyboardEvent`.\n * If the most recent user interaction was via the keyboard;\n * and the key press did not include a meta, alt/option, or control key;\n * then the modality is keyboard. Otherwise, the modality is not keyboard.\n * @param {KeyboardEvent} event\n */\nfunction handleKeyDown(event) {\n if (event.metaKey || event.altKey || event.ctrlKey) {\n return;\n }\n hadKeyboardEvent = true;\n}\n\n/**\n * If at any point a user clicks with a pointing device, ensure that we change\n * the modality away from keyboard.\n * This avoids the situation where a user presses a key on an already focused\n * element, and then clicks on a different element, focusing it with a\n * pointing device, while we still think we're in keyboard modality.\n */\nfunction handlePointerDown() {\n hadKeyboardEvent = false;\n}\nfunction handleVisibilityChange() {\n if (this.visibilityState === 'hidden') {\n // If the tab becomes active again, the browser will handle calling focus\n // on the element (Safari actually calls it twice).\n // If this tab change caused a blur on an element with focus-visible,\n // re-apply the class when the user switches back to the tab.\n if (hadFocusVisibleRecently) {\n hadKeyboardEvent = true;\n }\n }\n}\nfunction prepare(doc) {\n doc.addEventListener('keydown', handleKeyDown, true);\n doc.addEventListener('mousedown', handlePointerDown, true);\n doc.addEventListener('pointerdown', handlePointerDown, true);\n doc.addEventListener('touchstart', handlePointerDown, true);\n doc.addEventListener('visibilitychange', handleVisibilityChange, true);\n}\nexport function teardown(doc) {\n doc.removeEventListener('keydown', handleKeyDown, true);\n doc.removeEventListener('mousedown', handlePointerDown, true);\n doc.removeEventListener('pointerdown', handlePointerDown, true);\n doc.removeEventListener('touchstart', handlePointerDown, true);\n doc.removeEventListener('visibilitychange', handleVisibilityChange, true);\n}\nfunction isFocusVisible(event) {\n const {\n target\n } = event;\n try {\n return target.matches(':focus-visible');\n } catch (error) {\n // Browsers not implementing :focus-visible will throw a SyntaxError.\n // We use our own heuristic for those browsers.\n // Rethrow might be better if it's not the expected error but do we really\n // want to crash if focus-visible malfunctioned?\n }\n\n // No need for validFocusTarget check. The user does that by attaching it to\n // focusable events only.\n return hadKeyboardEvent || focusTriggersKeyboardModality(target);\n}\nexport default function useIsFocusVisible() {\n const ref = React.useCallback(node => {\n if (node != null) {\n prepare(node.ownerDocument);\n }\n }, []);\n const isFocusVisibleRef = React.useRef(false);\n\n /**\n * Should be called if a blur event is fired\n */\n function handleBlurVisible() {\n // checking against potential state variable does not suffice if we focus and blur synchronously.\n // React wouldn't have time to trigger a re-render so `focusVisible` would be stale.\n // Ideally we would adjust `isFocusVisible(event)` to look at `relatedTarget` for blur events.\n // This doesn't work in IE11 due to https://github.com/facebook/react/issues/3751\n // TODO: check again if React releases their internal changes to focus event handling (https://github.com/facebook/react/pull/19186).\n if (isFocusVisibleRef.current) {\n // To detect a tab/window switch, we look for a blur event followed\n // rapidly by a visibility change.\n // If we don't see a visibility change within 100ms, it's probably a\n // regular focus change.\n hadFocusVisibleRecently = true;\n hadFocusVisibleRecentlyTimeout.start(100, () => {\n hadFocusVisibleRecently = false;\n });\n isFocusVisibleRef.current = false;\n return true;\n }\n return false;\n }\n\n /**\n * Should be called if a blur event is fired\n */\n function handleFocusVisible(event) {\n if (isFocusVisible(event)) {\n isFocusVisibleRef.current = true;\n return true;\n }\n return false;\n }\n return {\n isFocusVisibleRef,\n onFocus: handleFocusVisible,\n onBlur: handleBlurVisible,\n ref\n };\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\n/**\n * Add keys, values of `defaultProps` that does not exist in `props`\n * @param {object} defaultProps\n * @param {object} props\n * @returns {object} resolved props\n */\nexport default function resolveProps(defaultProps, props) {\n const output = _extends({}, props);\n Object.keys(defaultProps).forEach(propName => {\n if (propName.toString().match(/^(components|slots)$/)) {\n output[propName] = _extends({}, defaultProps[propName], output[propName]);\n } else if (propName.toString().match(/^(componentsProps|slotProps)$/)) {\n const defaultSlotProps = defaultProps[propName] || {};\n const slotProps = props[propName];\n output[propName] = {};\n if (!slotProps || !Object.keys(slotProps)) {\n // Reduce the iteration if the slot props is empty\n output[propName] = defaultSlotProps;\n } else if (!defaultSlotProps || !Object.keys(defaultSlotProps)) {\n // Reduce the iteration if the default slot props is empty\n output[propName] = slotProps;\n } else {\n output[propName] = _extends({}, slotProps);\n Object.keys(defaultSlotProps).forEach(slotPropName => {\n output[propName][slotPropName] = resolveProps(defaultSlotProps[slotPropName], slotProps[slotPropName]);\n });\n }\n } else if (output[propName] === undefined) {\n output[propName] = defaultProps[propName];\n }\n });\n return output;\n}","export default function composeClasses(slots, getUtilityClass, classes = undefined) {\n const output = {};\n Object.keys(slots).forEach(\n // `Object.keys(slots)` can't be wider than `T` because we infer `T` from `slots`.\n // @ts-expect-error https://github.com/microsoft/TypeScript/pull/12253#issuecomment-263132208\n slot => {\n output[slot] = slots[slot].reduce((acc, key) => {\n if (key) {\n const utilityClass = getUtilityClass(key);\n if (utilityClass !== '') {\n acc.push(utilityClass);\n }\n if (classes && classes[key]) {\n acc.push(classes[key]);\n }\n }\n return acc;\n }, []).join(' ');\n });\n return output;\n}","const defaultGenerator = componentName => componentName;\nconst createClassNameGenerator = () => {\n let generate = defaultGenerator;\n return {\n configure(generator) {\n generate = generator;\n },\n generate(componentName) {\n return generate(componentName);\n },\n reset() {\n generate = defaultGenerator;\n }\n };\n};\nconst ClassNameGenerator = createClassNameGenerator();\nexport default ClassNameGenerator;","import ClassNameGenerator from '../ClassNameGenerator';\nexport const globalStateClasses = {\n active: 'active',\n checked: 'checked',\n completed: 'completed',\n disabled: 'disabled',\n error: 'error',\n expanded: 'expanded',\n focused: 'focused',\n focusVisible: 'focusVisible',\n open: 'open',\n readOnly: 'readOnly',\n required: 'required',\n selected: 'selected'\n};\nexport default function generateUtilityClass(componentName, slot, globalStatePrefix = 'Mui') {\n const globalStateClass = globalStateClasses[slot];\n return globalStateClass ? `${globalStatePrefix}-${globalStateClass}` : `${ClassNameGenerator.generate(componentName)}-${slot}`;\n}\nexport function isGlobalState(slot) {\n return globalStateClasses[slot] !== undefined;\n}","import generateUtilityClass from '../generateUtilityClass';\nexport default function generateUtilityClasses(componentName, slots, globalStatePrefix = 'Mui') {\n const result = {};\n slots.forEach(slot => {\n result[slot] = generateUtilityClass(componentName, slot, globalStatePrefix);\n });\n return result;\n}","function clamp(val, min = Number.MIN_SAFE_INTEGER, max = Number.MAX_SAFE_INTEGER) {\n return Math.max(min, Math.min(val, max));\n}\nexport default clamp;","export default function _objectWithoutPropertiesLoose(source, excluded) {\n if (source == null) return {};\n var target = {};\n var sourceKeys = Object.keys(source);\n var key, i;\n for (i = 0; i < sourceKeys.length; i++) {\n key = sourceKeys[i];\n if (excluded.indexOf(key) >= 0) continue;\n target[key] = source[key];\n }\n return target;\n}","import _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nconst _excluded = [\"values\", \"unit\", \"step\"];\n// Sorted ASC by size. That's important.\n// It can't be configured as it's used statically for propTypes.\nexport const breakpointKeys = ['xs', 'sm', 'md', 'lg', 'xl'];\nconst sortBreakpointsValues = values => {\n const breakpointsAsArray = Object.keys(values).map(key => ({\n key,\n val: values[key]\n })) || [];\n // Sort in ascending order\n breakpointsAsArray.sort((breakpoint1, breakpoint2) => breakpoint1.val - breakpoint2.val);\n return breakpointsAsArray.reduce((acc, obj) => {\n return _extends({}, acc, {\n [obj.key]: obj.val\n });\n }, {});\n};\n\n// Keep in mind that @media is inclusive by the CSS specification.\nexport default function createBreakpoints(breakpoints) {\n const {\n // The breakpoint **start** at this value.\n // For instance with the first breakpoint xs: [xs, sm).\n values = {\n xs: 0,\n // phone\n sm: 600,\n // tablet\n md: 900,\n // small laptop\n lg: 1200,\n // desktop\n xl: 1536 // large screen\n },\n unit = 'px',\n step = 5\n } = breakpoints,\n other = _objectWithoutPropertiesLoose(breakpoints, _excluded);\n const sortedValues = sortBreakpointsValues(values);\n const keys = Object.keys(sortedValues);\n function up(key) {\n const value = typeof values[key] === 'number' ? values[key] : key;\n return `@media (min-width:${value}${unit})`;\n }\n function down(key) {\n const value = typeof values[key] === 'number' ? values[key] : key;\n return `@media (max-width:${value - step / 100}${unit})`;\n }\n function between(start, end) {\n const endIndex = keys.indexOf(end);\n return `@media (min-width:${typeof values[start] === 'number' ? values[start] : start}${unit}) and ` + `(max-width:${(endIndex !== -1 && typeof values[keys[endIndex]] === 'number' ? values[keys[endIndex]] : end) - step / 100}${unit})`;\n }\n function only(key) {\n if (keys.indexOf(key) + 1 < keys.length) {\n return between(key, keys[keys.indexOf(key) + 1]);\n }\n return up(key);\n }\n function not(key) {\n // handle first and last key separately, for better readability\n const keyIndex = keys.indexOf(key);\n if (keyIndex === 0) {\n return up(keys[1]);\n }\n if (keyIndex === keys.length - 1) {\n return down(keys[keyIndex]);\n }\n return between(key, keys[keys.indexOf(key) + 1]).replace('@media', '@media not all and');\n }\n return _extends({\n keys,\n values: sortedValues,\n up,\n down,\n between,\n only,\n not,\n unit\n }, other);\n}","const shape = {\n borderRadius: 4\n};\nexport default shape;","import PropTypes from 'prop-types';\nconst responsivePropType = process.env.NODE_ENV !== 'production' ? PropTypes.oneOfType([PropTypes.number, PropTypes.string, PropTypes.object, PropTypes.array]) : {};\nexport default responsivePropType;","import deepmerge from '@mui/utils/deepmerge';\nfunction merge(acc, item) {\n if (!item) {\n return acc;\n }\n return deepmerge(acc, item, {\n clone: false // No need to clone deep, it's way faster.\n });\n}\nexport default merge;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport PropTypes from 'prop-types';\nimport deepmerge from '@mui/utils/deepmerge';\nimport merge from './merge';\n\n// The breakpoint **start** at this value.\n// For instance with the first breakpoint xs: [xs, sm[.\nexport const values = {\n xs: 0,\n // phone\n sm: 600,\n // tablet\n md: 900,\n // small laptop\n lg: 1200,\n // desktop\n xl: 1536 // large screen\n};\nconst defaultBreakpoints = {\n // Sorted ASC by size. That's important.\n // It can't be configured as it's used statically for propTypes.\n keys: ['xs', 'sm', 'md', 'lg', 'xl'],\n up: key => `@media (min-width:${values[key]}px)`\n};\nexport function handleBreakpoints(props, propValue, styleFromPropValue) {\n const theme = props.theme || {};\n if (Array.isArray(propValue)) {\n const themeBreakpoints = theme.breakpoints || defaultBreakpoints;\n return propValue.reduce((acc, item, index) => {\n acc[themeBreakpoints.up(themeBreakpoints.keys[index])] = styleFromPropValue(propValue[index]);\n return acc;\n }, {});\n }\n if (typeof propValue === 'object') {\n const themeBreakpoints = theme.breakpoints || defaultBreakpoints;\n return Object.keys(propValue).reduce((acc, breakpoint) => {\n // key is breakpoint\n if (Object.keys(themeBreakpoints.values || values).indexOf(breakpoint) !== -1) {\n const mediaKey = themeBreakpoints.up(breakpoint);\n acc[mediaKey] = styleFromPropValue(propValue[breakpoint], breakpoint);\n } else {\n const cssKey = breakpoint;\n acc[cssKey] = propValue[cssKey];\n }\n return acc;\n }, {});\n }\n const output = styleFromPropValue(propValue);\n return output;\n}\nfunction breakpoints(styleFunction) {\n // false positive\n // eslint-disable-next-line react/function-component-definition\n const newStyleFunction = props => {\n const theme = props.theme || {};\n const base = styleFunction(props);\n const themeBreakpoints = theme.breakpoints || defaultBreakpoints;\n const extended = themeBreakpoints.keys.reduce((acc, key) => {\n if (props[key]) {\n acc = acc || {};\n acc[themeBreakpoints.up(key)] = styleFunction(_extends({\n theme\n }, props[key]));\n }\n return acc;\n }, null);\n return merge(base, extended);\n };\n newStyleFunction.propTypes = process.env.NODE_ENV !== 'production' ? _extends({}, styleFunction.propTypes, {\n xs: PropTypes.object,\n sm: PropTypes.object,\n md: PropTypes.object,\n lg: PropTypes.object,\n xl: PropTypes.object\n }) : {};\n newStyleFunction.filterProps = ['xs', 'sm', 'md', 'lg', 'xl', ...styleFunction.filterProps];\n return newStyleFunction;\n}\nexport function createEmptyBreakpointObject(breakpointsInput = {}) {\n var _breakpointsInput$key;\n const breakpointsInOrder = (_breakpointsInput$key = breakpointsInput.keys) == null ? void 0 : _breakpointsInput$key.reduce((acc, key) => {\n const breakpointStyleKey = breakpointsInput.up(key);\n acc[breakpointStyleKey] = {};\n return acc;\n }, {});\n return breakpointsInOrder || {};\n}\nexport function removeUnusedBreakpoints(breakpointKeys, style) {\n return breakpointKeys.reduce((acc, key) => {\n const breakpointOutput = acc[key];\n const isBreakpointUnused = !breakpointOutput || Object.keys(breakpointOutput).length === 0;\n if (isBreakpointUnused) {\n delete acc[key];\n }\n return acc;\n }, style);\n}\nexport function mergeBreakpointsInOrder(breakpointsInput, ...styles) {\n const emptyBreakpoints = createEmptyBreakpointObject(breakpointsInput);\n const mergedOutput = [emptyBreakpoints, ...styles].reduce((prev, next) => deepmerge(prev, next), {});\n return removeUnusedBreakpoints(Object.keys(emptyBreakpoints), mergedOutput);\n}\n\n// compute base for responsive values; e.g.,\n// [1,2,3] => {xs: true, sm: true, md: true}\n// {xs: 1, sm: 2, md: 3} => {xs: true, sm: true, md: true}\nexport function computeBreakpointsBase(breakpointValues, themeBreakpoints) {\n // fixed value\n if (typeof breakpointValues !== 'object') {\n return {};\n }\n const base = {};\n const breakpointsKeys = Object.keys(themeBreakpoints);\n if (Array.isArray(breakpointValues)) {\n breakpointsKeys.forEach((breakpoint, i) => {\n if (i < breakpointValues.length) {\n base[breakpoint] = true;\n }\n });\n } else {\n breakpointsKeys.forEach(breakpoint => {\n if (breakpointValues[breakpoint] != null) {\n base[breakpoint] = true;\n }\n });\n }\n return base;\n}\nexport function resolveBreakpointValues({\n values: breakpointValues,\n breakpoints: themeBreakpoints,\n base: customBase\n}) {\n const base = customBase || computeBreakpointsBase(breakpointValues, themeBreakpoints);\n const keys = Object.keys(base);\n if (keys.length === 0) {\n return breakpointValues;\n }\n let previous;\n return keys.reduce((acc, breakpoint, i) => {\n if (Array.isArray(breakpointValues)) {\n acc[breakpoint] = breakpointValues[i] != null ? breakpointValues[i] : breakpointValues[previous];\n previous = i;\n } else if (typeof breakpointValues === 'object') {\n acc[breakpoint] = breakpointValues[breakpoint] != null ? breakpointValues[breakpoint] : breakpointValues[previous];\n previous = breakpoint;\n } else {\n acc[breakpoint] = breakpointValues;\n }\n return acc;\n }, {});\n}\nexport default breakpoints;","import capitalize from '@mui/utils/capitalize';\nimport responsivePropType from './responsivePropType';\nimport { handleBreakpoints } from './breakpoints';\nexport function getPath(obj, path, checkVars = true) {\n if (!path || typeof path !== 'string') {\n return null;\n }\n\n // Check if CSS variables are used\n if (obj && obj.vars && checkVars) {\n const val = `vars.${path}`.split('.').reduce((acc, item) => acc && acc[item] ? acc[item] : null, obj);\n if (val != null) {\n return val;\n }\n }\n return path.split('.').reduce((acc, item) => {\n if (acc && acc[item] != null) {\n return acc[item];\n }\n return null;\n }, obj);\n}\nexport function getStyleValue(themeMapping, transform, propValueFinal, userValue = propValueFinal) {\n let value;\n if (typeof themeMapping === 'function') {\n value = themeMapping(propValueFinal);\n } else if (Array.isArray(themeMapping)) {\n value = themeMapping[propValueFinal] || userValue;\n } else {\n value = getPath(themeMapping, propValueFinal) || userValue;\n }\n if (transform) {\n value = transform(value, userValue, themeMapping);\n }\n return value;\n}\nfunction style(options) {\n const {\n prop,\n cssProperty = options.prop,\n themeKey,\n transform\n } = options;\n\n // false positive\n // eslint-disable-next-line react/function-component-definition\n const fn = props => {\n if (props[prop] == null) {\n return null;\n }\n const propValue = props[prop];\n const theme = props.theme;\n const themeMapping = getPath(theme, themeKey) || {};\n const styleFromPropValue = propValueFinal => {\n let value = getStyleValue(themeMapping, transform, propValueFinal);\n if (propValueFinal === value && typeof propValueFinal === 'string') {\n // Haven't found value\n value = getStyleValue(themeMapping, transform, `${prop}${propValueFinal === 'default' ? '' : capitalize(propValueFinal)}`, propValueFinal);\n }\n if (cssProperty === false) {\n return value;\n }\n return {\n [cssProperty]: value\n };\n };\n return handleBreakpoints(props, propValue, styleFromPropValue);\n };\n fn.propTypes = process.env.NODE_ENV !== 'production' ? {\n [prop]: responsivePropType\n } : {};\n fn.filterProps = [prop];\n return fn;\n}\nexport default style;","export default function memoize(fn) {\n const cache = {};\n return arg => {\n if (cache[arg] === undefined) {\n cache[arg] = fn(arg);\n }\n return cache[arg];\n };\n}","import responsivePropType from './responsivePropType';\nimport { handleBreakpoints } from './breakpoints';\nimport { getPath } from './style';\nimport merge from './merge';\nimport memoize from './memoize';\nconst properties = {\n m: 'margin',\n p: 'padding'\n};\nconst directions = {\n t: 'Top',\n r: 'Right',\n b: 'Bottom',\n l: 'Left',\n x: ['Left', 'Right'],\n y: ['Top', 'Bottom']\n};\nconst aliases = {\n marginX: 'mx',\n marginY: 'my',\n paddingX: 'px',\n paddingY: 'py'\n};\n\n// memoize() impact:\n// From 300,000 ops/sec\n// To 350,000 ops/sec\nconst getCssProperties = memoize(prop => {\n // It's not a shorthand notation.\n if (prop.length > 2) {\n if (aliases[prop]) {\n prop = aliases[prop];\n } else {\n return [prop];\n }\n }\n const [a, b] = prop.split('');\n const property = properties[a];\n const direction = directions[b] || '';\n return Array.isArray(direction) ? direction.map(dir => property + dir) : [property + direction];\n});\nexport const marginKeys = ['m', 'mt', 'mr', 'mb', 'ml', 'mx', 'my', 'margin', 'marginTop', 'marginRight', 'marginBottom', 'marginLeft', 'marginX', 'marginY', 'marginInline', 'marginInlineStart', 'marginInlineEnd', 'marginBlock', 'marginBlockStart', 'marginBlockEnd'];\nexport const paddingKeys = ['p', 'pt', 'pr', 'pb', 'pl', 'px', 'py', 'padding', 'paddingTop', 'paddingRight', 'paddingBottom', 'paddingLeft', 'paddingX', 'paddingY', 'paddingInline', 'paddingInlineStart', 'paddingInlineEnd', 'paddingBlock', 'paddingBlockStart', 'paddingBlockEnd'];\nconst spacingKeys = [...marginKeys, ...paddingKeys];\nexport function createUnaryUnit(theme, themeKey, defaultValue, propName) {\n var _getPath;\n const themeSpacing = (_getPath = getPath(theme, themeKey, false)) != null ? _getPath : defaultValue;\n if (typeof themeSpacing === 'number') {\n return abs => {\n if (typeof abs === 'string') {\n return abs;\n }\n if (process.env.NODE_ENV !== 'production') {\n if (typeof abs !== 'number') {\n console.error(`MUI: Expected ${propName} argument to be a number or a string, got ${abs}.`);\n }\n }\n return themeSpacing * abs;\n };\n }\n if (Array.isArray(themeSpacing)) {\n return abs => {\n if (typeof abs === 'string') {\n return abs;\n }\n if (process.env.NODE_ENV !== 'production') {\n if (!Number.isInteger(abs)) {\n console.error([`MUI: The \\`theme.${themeKey}\\` array type cannot be combined with non integer values.` + `You should either use an integer value that can be used as index, or define the \\`theme.${themeKey}\\` as a number.`].join('\\n'));\n } else if (abs > themeSpacing.length - 1) {\n console.error([`MUI: The value provided (${abs}) overflows.`, `The supported values are: ${JSON.stringify(themeSpacing)}.`, `${abs} > ${themeSpacing.length - 1}, you need to add the missing values.`].join('\\n'));\n }\n }\n return themeSpacing[abs];\n };\n }\n if (typeof themeSpacing === 'function') {\n return themeSpacing;\n }\n if (process.env.NODE_ENV !== 'production') {\n console.error([`MUI: The \\`theme.${themeKey}\\` value (${themeSpacing}) is invalid.`, 'It should be a number, an array or a function.'].join('\\n'));\n }\n return () => undefined;\n}\nexport function createUnarySpacing(theme) {\n return createUnaryUnit(theme, 'spacing', 8, 'spacing');\n}\nexport function getValue(transformer, propValue) {\n if (typeof propValue === 'string' || propValue == null) {\n return propValue;\n }\n const abs = Math.abs(propValue);\n const transformed = transformer(abs);\n if (propValue >= 0) {\n return transformed;\n }\n if (typeof transformed === 'number') {\n return -transformed;\n }\n return `-${transformed}`;\n}\nexport function getStyleFromPropValue(cssProperties, transformer) {\n return propValue => cssProperties.reduce((acc, cssProperty) => {\n acc[cssProperty] = getValue(transformer, propValue);\n return acc;\n }, {});\n}\nfunction resolveCssProperty(props, keys, prop, transformer) {\n // Using a hash computation over an array iteration could be faster, but with only 28 items,\n // it's doesn't worth the bundle size.\n if (keys.indexOf(prop) === -1) {\n return null;\n }\n const cssProperties = getCssProperties(prop);\n const styleFromPropValue = getStyleFromPropValue(cssProperties, transformer);\n const propValue = props[prop];\n return handleBreakpoints(props, propValue, styleFromPropValue);\n}\nfunction style(props, keys) {\n const transformer = createUnarySpacing(props.theme);\n return Object.keys(props).map(prop => resolveCssProperty(props, keys, prop, transformer)).reduce(merge, {});\n}\nexport function margin(props) {\n return style(props, marginKeys);\n}\nmargin.propTypes = process.env.NODE_ENV !== 'production' ? marginKeys.reduce((obj, key) => {\n obj[key] = responsivePropType;\n return obj;\n}, {}) : {};\nmargin.filterProps = marginKeys;\nexport function padding(props) {\n return style(props, paddingKeys);\n}\npadding.propTypes = process.env.NODE_ENV !== 'production' ? paddingKeys.reduce((obj, key) => {\n obj[key] = responsivePropType;\n return obj;\n}, {}) : {};\npadding.filterProps = paddingKeys;\nfunction spacing(props) {\n return style(props, spacingKeys);\n}\nspacing.propTypes = process.env.NODE_ENV !== 'production' ? spacingKeys.reduce((obj, key) => {\n obj[key] = responsivePropType;\n return obj;\n}, {}) : {};\nspacing.filterProps = spacingKeys;\nexport default spacing;","import { createUnarySpacing } from '../spacing';\n\n// The different signatures imply different meaning for their arguments that can't be expressed structurally.\n// We express the difference with variable names.\n\nexport default function createSpacing(spacingInput = 8) {\n // Already transformed.\n if (spacingInput.mui) {\n return spacingInput;\n }\n\n // Material Design layouts are visually balanced. Most measurements align to an 8dp grid, which aligns both spacing and the overall layout.\n // Smaller components, such as icons, can align to a 4dp grid.\n // https://m2.material.io/design/layout/understanding-layout.html\n const transform = createUnarySpacing({\n spacing: spacingInput\n });\n const spacing = (...argsInput) => {\n if (process.env.NODE_ENV !== 'production') {\n if (!(argsInput.length <= 4)) {\n console.error(`MUI: Too many arguments provided, expected between 0 and 4, got ${argsInput.length}`);\n }\n }\n const args = argsInput.length === 0 ? [1] : argsInput;\n return args.map(argument => {\n const output = transform(argument);\n return typeof output === 'number' ? `${output}px` : output;\n }).join(' ');\n };\n spacing.mui = true;\n return spacing;\n}","import merge from './merge';\nfunction compose(...styles) {\n const handlers = styles.reduce((acc, style) => {\n style.filterProps.forEach(prop => {\n acc[prop] = style;\n });\n return acc;\n }, {});\n\n // false positive\n // eslint-disable-next-line react/function-component-definition\n const fn = props => {\n return Object.keys(props).reduce((acc, prop) => {\n if (handlers[prop]) {\n return merge(acc, handlers[prop](props));\n }\n return acc;\n }, {});\n };\n fn.propTypes = process.env.NODE_ENV !== 'production' ? styles.reduce((acc, style) => Object.assign(acc, style.propTypes), {}) : {};\n fn.filterProps = styles.reduce((acc, style) => acc.concat(style.filterProps), []);\n return fn;\n}\nexport default compose;","import responsivePropType from './responsivePropType';\nimport style from './style';\nimport compose from './compose';\nimport { createUnaryUnit, getValue } from './spacing';\nimport { handleBreakpoints } from './breakpoints';\nexport function borderTransform(value) {\n if (typeof value !== 'number') {\n return value;\n }\n return `${value}px solid`;\n}\nfunction createBorderStyle(prop, transform) {\n return style({\n prop,\n themeKey: 'borders',\n transform\n });\n}\nexport const border = createBorderStyle('border', borderTransform);\nexport const borderTop = createBorderStyle('borderTop', borderTransform);\nexport const borderRight = createBorderStyle('borderRight', borderTransform);\nexport const borderBottom = createBorderStyle('borderBottom', borderTransform);\nexport const borderLeft = createBorderStyle('borderLeft', borderTransform);\nexport const borderColor = createBorderStyle('borderColor');\nexport const borderTopColor = createBorderStyle('borderTopColor');\nexport const borderRightColor = createBorderStyle('borderRightColor');\nexport const borderBottomColor = createBorderStyle('borderBottomColor');\nexport const borderLeftColor = createBorderStyle('borderLeftColor');\nexport const outline = createBorderStyle('outline', borderTransform);\nexport const outlineColor = createBorderStyle('outlineColor');\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const borderRadius = props => {\n if (props.borderRadius !== undefined && props.borderRadius !== null) {\n const transformer = createUnaryUnit(props.theme, 'shape.borderRadius', 4, 'borderRadius');\n const styleFromPropValue = propValue => ({\n borderRadius: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.borderRadius, styleFromPropValue);\n }\n return null;\n};\nborderRadius.propTypes = process.env.NODE_ENV !== 'production' ? {\n borderRadius: responsivePropType\n} : {};\nborderRadius.filterProps = ['borderRadius'];\nconst borders = compose(border, borderTop, borderRight, borderBottom, borderLeft, borderColor, borderTopColor, borderRightColor, borderBottomColor, borderLeftColor, borderRadius, outline, outlineColor);\nexport default borders;","import style from './style';\nimport compose from './compose';\nimport { createUnaryUnit, getValue } from './spacing';\nimport { handleBreakpoints } from './breakpoints';\nimport responsivePropType from './responsivePropType';\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const gap = props => {\n if (props.gap !== undefined && props.gap !== null) {\n const transformer = createUnaryUnit(props.theme, 'spacing', 8, 'gap');\n const styleFromPropValue = propValue => ({\n gap: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.gap, styleFromPropValue);\n }\n return null;\n};\ngap.propTypes = process.env.NODE_ENV !== 'production' ? {\n gap: responsivePropType\n} : {};\ngap.filterProps = ['gap'];\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const columnGap = props => {\n if (props.columnGap !== undefined && props.columnGap !== null) {\n const transformer = createUnaryUnit(props.theme, 'spacing', 8, 'columnGap');\n const styleFromPropValue = propValue => ({\n columnGap: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.columnGap, styleFromPropValue);\n }\n return null;\n};\ncolumnGap.propTypes = process.env.NODE_ENV !== 'production' ? {\n columnGap: responsivePropType\n} : {};\ncolumnGap.filterProps = ['columnGap'];\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const rowGap = props => {\n if (props.rowGap !== undefined && props.rowGap !== null) {\n const transformer = createUnaryUnit(props.theme, 'spacing', 8, 'rowGap');\n const styleFromPropValue = propValue => ({\n rowGap: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.rowGap, styleFromPropValue);\n }\n return null;\n};\nrowGap.propTypes = process.env.NODE_ENV !== 'production' ? {\n rowGap: responsivePropType\n} : {};\nrowGap.filterProps = ['rowGap'];\nexport const gridColumn = style({\n prop: 'gridColumn'\n});\nexport const gridRow = style({\n prop: 'gridRow'\n});\nexport const gridAutoFlow = style({\n prop: 'gridAutoFlow'\n});\nexport const gridAutoColumns = style({\n prop: 'gridAutoColumns'\n});\nexport const gridAutoRows = style({\n prop: 'gridAutoRows'\n});\nexport const gridTemplateColumns = style({\n prop: 'gridTemplateColumns'\n});\nexport const gridTemplateRows = style({\n prop: 'gridTemplateRows'\n});\nexport const gridTemplateAreas = style({\n prop: 'gridTemplateAreas'\n});\nexport const gridArea = style({\n prop: 'gridArea'\n});\nconst grid = compose(gap, columnGap, rowGap, gridColumn, gridRow, gridAutoFlow, gridAutoColumns, gridAutoRows, gridTemplateColumns, gridTemplateRows, gridTemplateAreas, gridArea);\nexport default grid;","import style from './style';\nimport compose from './compose';\nexport function paletteTransform(value, userValue) {\n if (userValue === 'grey') {\n return userValue;\n }\n return value;\n}\nexport const color = style({\n prop: 'color',\n themeKey: 'palette',\n transform: paletteTransform\n});\nexport const bgcolor = style({\n prop: 'bgcolor',\n cssProperty: 'backgroundColor',\n themeKey: 'palette',\n transform: paletteTransform\n});\nexport const backgroundColor = style({\n prop: 'backgroundColor',\n themeKey: 'palette',\n transform: paletteTransform\n});\nconst palette = compose(color, bgcolor, backgroundColor);\nexport default palette;","import style from './style';\nimport compose from './compose';\nimport { handleBreakpoints, values as breakpointsValues } from './breakpoints';\nexport function sizingTransform(value) {\n return value <= 1 && value !== 0 ? `${value * 100}%` : value;\n}\nexport const width = style({\n prop: 'width',\n transform: sizingTransform\n});\nexport const maxWidth = props => {\n if (props.maxWidth !== undefined && props.maxWidth !== null) {\n const styleFromPropValue = propValue => {\n var _props$theme, _props$theme2;\n const breakpoint = ((_props$theme = props.theme) == null || (_props$theme = _props$theme.breakpoints) == null || (_props$theme = _props$theme.values) == null ? void 0 : _props$theme[propValue]) || breakpointsValues[propValue];\n if (!breakpoint) {\n return {\n maxWidth: sizingTransform(propValue)\n };\n }\n if (((_props$theme2 = props.theme) == null || (_props$theme2 = _props$theme2.breakpoints) == null ? void 0 : _props$theme2.unit) !== 'px') {\n return {\n maxWidth: `${breakpoint}${props.theme.breakpoints.unit}`\n };\n }\n return {\n maxWidth: breakpoint\n };\n };\n return handleBreakpoints(props, props.maxWidth, styleFromPropValue);\n }\n return null;\n};\nmaxWidth.filterProps = ['maxWidth'];\nexport const minWidth = style({\n prop: 'minWidth',\n transform: sizingTransform\n});\nexport const height = style({\n prop: 'height',\n transform: sizingTransform\n});\nexport const maxHeight = style({\n prop: 'maxHeight',\n transform: sizingTransform\n});\nexport const minHeight = style({\n prop: 'minHeight',\n transform: sizingTransform\n});\nexport const sizeWidth = style({\n prop: 'size',\n cssProperty: 'width',\n transform: sizingTransform\n});\nexport const sizeHeight = style({\n prop: 'size',\n cssProperty: 'height',\n transform: sizingTransform\n});\nexport const boxSizing = style({\n prop: 'boxSizing'\n});\nconst sizing = compose(width, maxWidth, minWidth, height, maxHeight, minHeight, boxSizing);\nexport default sizing;","import { padding, margin } from '../spacing';\nimport { borderRadius, borderTransform } from '../borders';\nimport { gap, rowGap, columnGap } from '../cssGrid';\nimport { paletteTransform } from '../palette';\nimport { maxWidth, sizingTransform } from '../sizing';\nconst defaultSxConfig = {\n // borders\n border: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderTop: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderRight: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderBottom: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderLeft: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderColor: {\n themeKey: 'palette'\n },\n borderTopColor: {\n themeKey: 'palette'\n },\n borderRightColor: {\n themeKey: 'palette'\n },\n borderBottomColor: {\n themeKey: 'palette'\n },\n borderLeftColor: {\n themeKey: 'palette'\n },\n outline: {\n themeKey: 'borders',\n transform: borderTransform\n },\n outlineColor: {\n themeKey: 'palette'\n },\n borderRadius: {\n themeKey: 'shape.borderRadius',\n style: borderRadius\n },\n // palette\n color: {\n themeKey: 'palette',\n transform: paletteTransform\n },\n bgcolor: {\n themeKey: 'palette',\n cssProperty: 'backgroundColor',\n transform: paletteTransform\n },\n backgroundColor: {\n themeKey: 'palette',\n transform: paletteTransform\n },\n // spacing\n p: {\n style: padding\n },\n pt: {\n style: padding\n },\n pr: {\n style: padding\n },\n pb: {\n style: padding\n },\n pl: {\n style: padding\n },\n px: {\n style: padding\n },\n py: {\n style: padding\n },\n padding: {\n style: padding\n },\n paddingTop: {\n style: padding\n },\n paddingRight: {\n style: padding\n },\n paddingBottom: {\n style: padding\n },\n paddingLeft: {\n style: padding\n },\n paddingX: {\n style: padding\n },\n paddingY: {\n style: padding\n },\n paddingInline: {\n style: padding\n },\n paddingInlineStart: {\n style: padding\n },\n paddingInlineEnd: {\n style: padding\n },\n paddingBlock: {\n style: padding\n },\n paddingBlockStart: {\n style: padding\n },\n paddingBlockEnd: {\n style: padding\n },\n m: {\n style: margin\n },\n mt: {\n style: margin\n },\n mr: {\n style: margin\n },\n mb: {\n style: margin\n },\n ml: {\n style: margin\n },\n mx: {\n style: margin\n },\n my: {\n style: margin\n },\n margin: {\n style: margin\n },\n marginTop: {\n style: margin\n },\n marginRight: {\n style: margin\n },\n marginBottom: {\n style: margin\n },\n marginLeft: {\n style: margin\n },\n marginX: {\n style: margin\n },\n marginY: {\n style: margin\n },\n marginInline: {\n style: margin\n },\n marginInlineStart: {\n style: margin\n },\n marginInlineEnd: {\n style: margin\n },\n marginBlock: {\n style: margin\n },\n marginBlockStart: {\n style: margin\n },\n marginBlockEnd: {\n style: margin\n },\n // display\n displayPrint: {\n cssProperty: false,\n transform: value => ({\n '@media print': {\n display: value\n }\n })\n },\n display: {},\n overflow: {},\n textOverflow: {},\n visibility: {},\n whiteSpace: {},\n // flexbox\n flexBasis: {},\n flexDirection: {},\n flexWrap: {},\n justifyContent: {},\n alignItems: {},\n alignContent: {},\n order: {},\n flex: {},\n flexGrow: {},\n flexShrink: {},\n alignSelf: {},\n justifyItems: {},\n justifySelf: {},\n // grid\n gap: {\n style: gap\n },\n rowGap: {\n style: rowGap\n },\n columnGap: {\n style: columnGap\n },\n gridColumn: {},\n gridRow: {},\n gridAutoFlow: {},\n gridAutoColumns: {},\n gridAutoRows: {},\n gridTemplateColumns: {},\n gridTemplateRows: {},\n gridTemplateAreas: {},\n gridArea: {},\n // positions\n position: {},\n zIndex: {\n themeKey: 'zIndex'\n },\n top: {},\n right: {},\n bottom: {},\n left: {},\n // shadows\n boxShadow: {\n themeKey: 'shadows'\n },\n // sizing\n width: {\n transform: sizingTransform\n },\n maxWidth: {\n style: maxWidth\n },\n minWidth: {\n transform: sizingTransform\n },\n height: {\n transform: sizingTransform\n },\n maxHeight: {\n transform: sizingTransform\n },\n minHeight: {\n transform: sizingTransform\n },\n boxSizing: {},\n // typography\n fontFamily: {\n themeKey: 'typography'\n },\n fontSize: {\n themeKey: 'typography'\n },\n fontStyle: {\n themeKey: 'typography'\n },\n fontWeight: {\n themeKey: 'typography'\n },\n letterSpacing: {},\n textTransform: {},\n lineHeight: {},\n textAlign: {},\n typography: {\n cssProperty: false,\n themeKey: 'typography'\n }\n};\nexport default defaultSxConfig;","import capitalize from '@mui/utils/capitalize';\nimport merge from '../merge';\nimport { getPath, getStyleValue as getValue } from '../style';\nimport { handleBreakpoints, createEmptyBreakpointObject, removeUnusedBreakpoints } from '../breakpoints';\nimport defaultSxConfig from './defaultSxConfig';\nfunction objectsHaveSameKeys(...objects) {\n const allKeys = objects.reduce((keys, object) => keys.concat(Object.keys(object)), []);\n const union = new Set(allKeys);\n return objects.every(object => union.size === Object.keys(object).length);\n}\nfunction callIfFn(maybeFn, arg) {\n return typeof maybeFn === 'function' ? maybeFn(arg) : maybeFn;\n}\n\n// eslint-disable-next-line @typescript-eslint/naming-convention\nexport function unstable_createStyleFunctionSx() {\n function getThemeValue(prop, val, theme, config) {\n const props = {\n [prop]: val,\n theme\n };\n const options = config[prop];\n if (!options) {\n return {\n [prop]: val\n };\n }\n const {\n cssProperty = prop,\n themeKey,\n transform,\n style\n } = options;\n if (val == null) {\n return null;\n }\n\n // TODO v6: remove, see https://github.com/mui/material-ui/pull/38123\n if (themeKey === 'typography' && val === 'inherit') {\n return {\n [prop]: val\n };\n }\n const themeMapping = getPath(theme, themeKey) || {};\n if (style) {\n return style(props);\n }\n const styleFromPropValue = propValueFinal => {\n let value = getValue(themeMapping, transform, propValueFinal);\n if (propValueFinal === value && typeof propValueFinal === 'string') {\n // Haven't found value\n value = getValue(themeMapping, transform, `${prop}${propValueFinal === 'default' ? '' : capitalize(propValueFinal)}`, propValueFinal);\n }\n if (cssProperty === false) {\n return value;\n }\n return {\n [cssProperty]: value\n };\n };\n return handleBreakpoints(props, val, styleFromPropValue);\n }\n function styleFunctionSx(props) {\n var _theme$unstable_sxCon;\n const {\n sx,\n theme = {}\n } = props || {};\n if (!sx) {\n return null; // Emotion & styled-components will neglect null\n }\n const config = (_theme$unstable_sxCon = theme.unstable_sxConfig) != null ? _theme$unstable_sxCon : defaultSxConfig;\n\n /*\n * Receive `sxInput` as object or callback\n * and then recursively check keys & values to create media query object styles.\n * (the result will be used in `styled`)\n */\n function traverse(sxInput) {\n let sxObject = sxInput;\n if (typeof sxInput === 'function') {\n sxObject = sxInput(theme);\n } else if (typeof sxInput !== 'object') {\n // value\n return sxInput;\n }\n if (!sxObject) {\n return null;\n }\n const emptyBreakpoints = createEmptyBreakpointObject(theme.breakpoints);\n const breakpointsKeys = Object.keys(emptyBreakpoints);\n let css = emptyBreakpoints;\n Object.keys(sxObject).forEach(styleKey => {\n const value = callIfFn(sxObject[styleKey], theme);\n if (value !== null && value !== undefined) {\n if (typeof value === 'object') {\n if (config[styleKey]) {\n css = merge(css, getThemeValue(styleKey, value, theme, config));\n } else {\n const breakpointsValues = handleBreakpoints({\n theme\n }, value, x => ({\n [styleKey]: x\n }));\n if (objectsHaveSameKeys(breakpointsValues, value)) {\n css[styleKey] = styleFunctionSx({\n sx: value,\n theme\n });\n } else {\n css = merge(css, breakpointsValues);\n }\n }\n } else {\n css = merge(css, getThemeValue(styleKey, value, theme, config));\n }\n }\n });\n return removeUnusedBreakpoints(breakpointsKeys, css);\n }\n return Array.isArray(sx) ? sx.map(traverse) : traverse(sx);\n }\n return styleFunctionSx;\n}\nconst styleFunctionSx = unstable_createStyleFunctionSx();\nstyleFunctionSx.filterProps = ['sx'];\nexport default styleFunctionSx;","/**\n * A universal utility to style components with multiple color modes. Always use it from the theme object.\n * It works with:\n * - [Basic theme](https://mui.com/material-ui/customization/dark-mode/)\n * - [CSS theme variables](https://mui.com/material-ui/experimental-api/css-theme-variables/overview/)\n * - Zero-runtime engine\n *\n * Tips: Use an array over object spread and place `theme.applyStyles()` last.\n *\n * ✅ [{ background: '#e5e5e5' }, theme.applyStyles('dark', { background: '#1c1c1c' })]\n *\n * 🚫 { background: '#e5e5e5', ...theme.applyStyles('dark', { background: '#1c1c1c' })}\n *\n * @example\n * 1. using with `styled`:\n * ```jsx\n * const Component = styled('div')(({ theme }) => [\n * { background: '#e5e5e5' },\n * theme.applyStyles('dark', {\n * background: '#1c1c1c',\n * color: '#fff',\n * }),\n * ]);\n * ```\n *\n * @example\n * 2. using with `sx` prop:\n * ```jsx\n * [\n * { background: '#e5e5e5' },\n * theme.applyStyles('dark', {\n * background: '#1c1c1c',\n * color: '#fff',\n * }),\n * ]}\n * />\n * ```\n *\n * @example\n * 3. theming a component:\n * ```jsx\n * extendTheme({\n * components: {\n * MuiButton: {\n * styleOverrides: {\n * root: ({ theme }) => [\n * { background: '#e5e5e5' },\n * theme.applyStyles('dark', {\n * background: '#1c1c1c',\n * color: '#fff',\n * }),\n * ],\n * },\n * }\n * }\n * })\n *```\n */\nexport default function applyStyles(key, styles) {\n // @ts-expect-error this is 'any' type\n const theme = this;\n if (theme.vars && typeof theme.getColorSchemeSelector === 'function') {\n // If CssVarsProvider is used as a provider,\n // returns '* :where([data-mui-color-scheme=\"light|dark\"]) &'\n const selector = theme.getColorSchemeSelector(key).replace(/(\\[[^\\]]+\\])/, '*:where($1)');\n return {\n [selector]: styles\n };\n }\n if (theme.palette.mode === key) {\n return styles;\n }\n return {};\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"breakpoints\", \"palette\", \"spacing\", \"shape\"];\nimport deepmerge from '@mui/utils/deepmerge';\nimport createBreakpoints from './createBreakpoints';\nimport shape from './shape';\nimport createSpacing from './createSpacing';\nimport styleFunctionSx from '../styleFunctionSx/styleFunctionSx';\nimport defaultSxConfig from '../styleFunctionSx/defaultSxConfig';\nimport applyStyles from './applyStyles';\nfunction createTheme(options = {}, ...args) {\n const {\n breakpoints: breakpointsInput = {},\n palette: paletteInput = {},\n spacing: spacingInput,\n shape: shapeInput = {}\n } = options,\n other = _objectWithoutPropertiesLoose(options, _excluded);\n const breakpoints = createBreakpoints(breakpointsInput);\n const spacing = createSpacing(spacingInput);\n let muiTheme = deepmerge({\n breakpoints,\n direction: 'ltr',\n components: {},\n // Inject component definitions.\n palette: _extends({\n mode: 'light'\n }, paletteInput),\n spacing,\n shape: _extends({}, shape, shapeInput)\n }, other);\n muiTheme.applyStyles = applyStyles;\n muiTheme = args.reduce((acc, argument) => deepmerge(acc, argument), muiTheme);\n muiTheme.unstable_sxConfig = _extends({}, defaultSxConfig, other == null ? void 0 : other.unstable_sxConfig);\n muiTheme.unstable_sx = function sx(props) {\n return styleFunctionSx({\n sx: props,\n theme: this\n });\n };\n return muiTheme;\n}\nexport default createTheme;","'use client';\n\nimport * as React from 'react';\nimport { ThemeContext } from '@mui/styled-engine';\nfunction isObjectEmpty(obj) {\n return Object.keys(obj).length === 0;\n}\nfunction useTheme(defaultTheme = null) {\n const contextTheme = React.useContext(ThemeContext);\n return !contextTheme || isObjectEmpty(contextTheme) ? defaultTheme : contextTheme;\n}\nexport default useTheme;","'use client';\n\nimport createTheme from './createTheme';\nimport useThemeWithoutDefault from './useThemeWithoutDefault';\nexport const systemDefaultTheme = createTheme();\nfunction useTheme(defaultTheme = systemDefaultTheme) {\n return useThemeWithoutDefault(defaultTheme);\n}\nexport default useTheme;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"ownerState\"],\n _excluded2 = [\"variants\"],\n _excluded3 = [\"name\", \"slot\", \"skipVariantsResolver\", \"skipSx\", \"overridesResolver\"];\n/* eslint-disable no-underscore-dangle */\nimport styledEngineStyled, { internal_processStyles as processStyles } from '@mui/styled-engine';\nimport { isPlainObject } from '@mui/utils/deepmerge';\nimport capitalize from '@mui/utils/capitalize';\nimport getDisplayName from '@mui/utils/getDisplayName';\nimport createTheme from './createTheme';\nimport styleFunctionSx from './styleFunctionSx';\nfunction isEmpty(obj) {\n return Object.keys(obj).length === 0;\n}\n\n// https://github.com/emotion-js/emotion/blob/26ded6109fcd8ca9875cc2ce4564fee678a3f3c5/packages/styled/src/utils.js#L40\nfunction isStringTag(tag) {\n return typeof tag === 'string' &&\n // 96 is one less than the char code\n // for \"a\" so this is checking that\n // it's a lowercase character\n tag.charCodeAt(0) > 96;\n}\n\n// Update /system/styled/#api in case if this changes\nexport function shouldForwardProp(prop) {\n return prop !== 'ownerState' && prop !== 'theme' && prop !== 'sx' && prop !== 'as';\n}\nexport const systemDefaultTheme = createTheme();\nconst lowercaseFirstLetter = string => {\n if (!string) {\n return string;\n }\n return string.charAt(0).toLowerCase() + string.slice(1);\n};\nfunction resolveTheme({\n defaultTheme,\n theme,\n themeId\n}) {\n return isEmpty(theme) ? defaultTheme : theme[themeId] || theme;\n}\nfunction defaultOverridesResolver(slot) {\n if (!slot) {\n return null;\n }\n return (props, styles) => styles[slot];\n}\nfunction processStyleArg(callableStyle, _ref) {\n let {\n ownerState\n } = _ref,\n props = _objectWithoutPropertiesLoose(_ref, _excluded);\n const resolvedStylesArg = typeof callableStyle === 'function' ? callableStyle(_extends({\n ownerState\n }, props)) : callableStyle;\n if (Array.isArray(resolvedStylesArg)) {\n return resolvedStylesArg.flatMap(resolvedStyle => processStyleArg(resolvedStyle, _extends({\n ownerState\n }, props)));\n }\n if (!!resolvedStylesArg && typeof resolvedStylesArg === 'object' && Array.isArray(resolvedStylesArg.variants)) {\n const {\n variants = []\n } = resolvedStylesArg,\n otherStyles = _objectWithoutPropertiesLoose(resolvedStylesArg, _excluded2);\n let result = otherStyles;\n variants.forEach(variant => {\n let isMatch = true;\n if (typeof variant.props === 'function') {\n isMatch = variant.props(_extends({\n ownerState\n }, props, ownerState));\n } else {\n Object.keys(variant.props).forEach(key => {\n if ((ownerState == null ? void 0 : ownerState[key]) !== variant.props[key] && props[key] !== variant.props[key]) {\n isMatch = false;\n }\n });\n }\n if (isMatch) {\n if (!Array.isArray(result)) {\n result = [result];\n }\n result.push(typeof variant.style === 'function' ? variant.style(_extends({\n ownerState\n }, props, ownerState)) : variant.style);\n }\n });\n return result;\n }\n return resolvedStylesArg;\n}\nexport default function createStyled(input = {}) {\n const {\n themeId,\n defaultTheme = systemDefaultTheme,\n rootShouldForwardProp = shouldForwardProp,\n slotShouldForwardProp = shouldForwardProp\n } = input;\n const systemSx = props => {\n return styleFunctionSx(_extends({}, props, {\n theme: resolveTheme(_extends({}, props, {\n defaultTheme,\n themeId\n }))\n }));\n };\n systemSx.__mui_systemSx = true;\n return (tag, inputOptions = {}) => {\n // Filter out the `sx` style function from the previous styled component to prevent unnecessary styles generated by the composite components.\n processStyles(tag, styles => styles.filter(style => !(style != null && style.__mui_systemSx)));\n const {\n name: componentName,\n slot: componentSlot,\n skipVariantsResolver: inputSkipVariantsResolver,\n skipSx: inputSkipSx,\n // TODO v6: remove `lowercaseFirstLetter()` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n overridesResolver = defaultOverridesResolver(lowercaseFirstLetter(componentSlot))\n } = inputOptions,\n options = _objectWithoutPropertiesLoose(inputOptions, _excluded3);\n\n // if skipVariantsResolver option is defined, take the value, otherwise, true for root and false for other slots.\n const skipVariantsResolver = inputSkipVariantsResolver !== undefined ? inputSkipVariantsResolver :\n // TODO v6: remove `Root` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n componentSlot && componentSlot !== 'Root' && componentSlot !== 'root' || false;\n const skipSx = inputSkipSx || false;\n let label;\n if (process.env.NODE_ENV !== 'production') {\n if (componentName) {\n // TODO v6: remove `lowercaseFirstLetter()` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n label = `${componentName}-${lowercaseFirstLetter(componentSlot || 'Root')}`;\n }\n }\n let shouldForwardPropOption = shouldForwardProp;\n\n // TODO v6: remove `Root` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n if (componentSlot === 'Root' || componentSlot === 'root') {\n shouldForwardPropOption = rootShouldForwardProp;\n } else if (componentSlot) {\n // any other slot specified\n shouldForwardPropOption = slotShouldForwardProp;\n } else if (isStringTag(tag)) {\n // for string (html) tag, preserve the behavior in emotion & styled-components.\n shouldForwardPropOption = undefined;\n }\n const defaultStyledResolver = styledEngineStyled(tag, _extends({\n shouldForwardProp: shouldForwardPropOption,\n label\n }, options));\n const transformStyleArg = stylesArg => {\n // On the server Emotion doesn't use React.forwardRef for creating components, so the created\n // component stays as a function. This condition makes sure that we do not interpolate functions\n // which are basically components used as a selectors.\n if (typeof stylesArg === 'function' && stylesArg.__emotion_real !== stylesArg || isPlainObject(stylesArg)) {\n return props => processStyleArg(stylesArg, _extends({}, props, {\n theme: resolveTheme({\n theme: props.theme,\n defaultTheme,\n themeId\n })\n }));\n }\n return stylesArg;\n };\n const muiStyledResolver = (styleArg, ...expressions) => {\n let transformedStyleArg = transformStyleArg(styleArg);\n const expressionsWithDefaultTheme = expressions ? expressions.map(transformStyleArg) : [];\n if (componentName && overridesResolver) {\n expressionsWithDefaultTheme.push(props => {\n const theme = resolveTheme(_extends({}, props, {\n defaultTheme,\n themeId\n }));\n if (!theme.components || !theme.components[componentName] || !theme.components[componentName].styleOverrides) {\n return null;\n }\n const styleOverrides = theme.components[componentName].styleOverrides;\n const resolvedStyleOverrides = {};\n // TODO: v7 remove iteration and use `resolveStyleArg(styleOverrides[slot])` directly\n Object.entries(styleOverrides).forEach(([slotKey, slotStyle]) => {\n resolvedStyleOverrides[slotKey] = processStyleArg(slotStyle, _extends({}, props, {\n theme\n }));\n });\n return overridesResolver(props, resolvedStyleOverrides);\n });\n }\n if (componentName && !skipVariantsResolver) {\n expressionsWithDefaultTheme.push(props => {\n var _theme$components;\n const theme = resolveTheme(_extends({}, props, {\n defaultTheme,\n themeId\n }));\n const themeVariants = theme == null || (_theme$components = theme.components) == null || (_theme$components = _theme$components[componentName]) == null ? void 0 : _theme$components.variants;\n return processStyleArg({\n variants: themeVariants\n }, _extends({}, props, {\n theme\n }));\n });\n }\n if (!skipSx) {\n expressionsWithDefaultTheme.push(systemSx);\n }\n const numOfCustomFnsApplied = expressionsWithDefaultTheme.length - expressions.length;\n if (Array.isArray(styleArg) && numOfCustomFnsApplied > 0) {\n const placeholders = new Array(numOfCustomFnsApplied).fill('');\n // If the type is array, than we need to add placeholders in the template for the overrides, variants and the sx styles.\n transformedStyleArg = [...styleArg, ...placeholders];\n transformedStyleArg.raw = [...styleArg.raw, ...placeholders];\n }\n const Component = defaultStyledResolver(transformedStyleArg, ...expressionsWithDefaultTheme);\n if (process.env.NODE_ENV !== 'production') {\n let displayName;\n if (componentName) {\n displayName = `${componentName}${capitalize(componentSlot || '')}`;\n }\n if (displayName === undefined) {\n displayName = `Styled(${getDisplayName(tag)})`;\n }\n Component.displayName = displayName;\n }\n if (tag.muiName) {\n Component.muiName = tag.muiName;\n }\n return Component;\n };\n if (defaultStyledResolver.withConfig) {\n muiStyledResolver.withConfig = defaultStyledResolver.withConfig;\n }\n return muiStyledResolver;\n };\n}","import resolveProps from '@mui/utils/resolveProps';\nexport default function getThemeProps(params) {\n const {\n theme,\n name,\n props\n } = params;\n if (!theme || !theme.components || !theme.components[name] || !theme.components[name].defaultProps) {\n return props;\n }\n return resolveProps(theme.components[name].defaultProps, props);\n}","'use client';\n\nimport getThemeProps from './getThemeProps';\nimport useTheme from '../useTheme';\nexport default function useThemeProps({\n props,\n name,\n defaultTheme,\n themeId\n}) {\n let theme = useTheme(defaultTheme);\n if (themeId) {\n theme = theme[themeId] || theme;\n }\n const mergedProps = getThemeProps({\n theme,\n name,\n props\n });\n return mergedProps;\n}","import _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\n/* eslint-disable @typescript-eslint/naming-convention */\nimport clamp from '@mui/utils/clamp';\n/**\n * Returns a number whose value is limited to the given range.\n * @param {number} value The value to be clamped\n * @param {number} min The lower boundary of the output range\n * @param {number} max The upper boundary of the output range\n * @returns {number} A number in the range [min, max]\n */\nfunction clampWrapper(value, min = 0, max = 1) {\n if (process.env.NODE_ENV !== 'production') {\n if (value < min || value > max) {\n console.error(`MUI: The value provided ${value} is out of range [${min}, ${max}].`);\n }\n }\n return clamp(value, min, max);\n}\n\n/**\n * Converts a color from CSS hex format to CSS rgb format.\n * @param {string} color - Hex color, i.e. #nnn or #nnnnnn\n * @returns {string} A CSS rgb color string\n */\nexport function hexToRgb(color) {\n color = color.slice(1);\n const re = new RegExp(`.{1,${color.length >= 6 ? 2 : 1}}`, 'g');\n let colors = color.match(re);\n if (colors && colors[0].length === 1) {\n colors = colors.map(n => n + n);\n }\n return colors ? `rgb${colors.length === 4 ? 'a' : ''}(${colors.map((n, index) => {\n return index < 3 ? parseInt(n, 16) : Math.round(parseInt(n, 16) / 255 * 1000) / 1000;\n }).join(', ')})` : '';\n}\nfunction intToHex(int) {\n const hex = int.toString(16);\n return hex.length === 1 ? `0${hex}` : hex;\n}\n\n/**\n * Returns an object with the type and values of a color.\n *\n * Note: Does not support rgb % values.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @returns {object} - A MUI color object: {type: string, values: number[]}\n */\nexport function decomposeColor(color) {\n // Idempotent\n if (color.type) {\n return color;\n }\n if (color.charAt(0) === '#') {\n return decomposeColor(hexToRgb(color));\n }\n const marker = color.indexOf('(');\n const type = color.substring(0, marker);\n if (['rgb', 'rgba', 'hsl', 'hsla', 'color'].indexOf(type) === -1) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: Unsupported \\`${color}\\` color.\nThe following formats are supported: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color().` : _formatMuiErrorMessage(9, color));\n }\n let values = color.substring(marker + 1, color.length - 1);\n let colorSpace;\n if (type === 'color') {\n values = values.split(' ');\n colorSpace = values.shift();\n if (values.length === 4 && values[3].charAt(0) === '/') {\n values[3] = values[3].slice(1);\n }\n if (['srgb', 'display-p3', 'a98-rgb', 'prophoto-rgb', 'rec-2020'].indexOf(colorSpace) === -1) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: unsupported \\`${colorSpace}\\` color space.\nThe following color spaces are supported: srgb, display-p3, a98-rgb, prophoto-rgb, rec-2020.` : _formatMuiErrorMessage(10, colorSpace));\n }\n } else {\n values = values.split(',');\n }\n values = values.map(value => parseFloat(value));\n return {\n type,\n values,\n colorSpace\n };\n}\n\n/**\n * Returns a channel created from the input color.\n *\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @returns {string} - The channel for the color, that can be used in rgba or hsla colors\n */\nexport const colorChannel = color => {\n const decomposedColor = decomposeColor(color);\n return decomposedColor.values.slice(0, 3).map((val, idx) => decomposedColor.type.indexOf('hsl') !== -1 && idx !== 0 ? `${val}%` : val).join(' ');\n};\nexport const private_safeColorChannel = (color, warning) => {\n try {\n return colorChannel(color);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n};\n\n/**\n * Converts a color object with type and values to a string.\n * @param {object} color - Decomposed color\n * @param {string} color.type - One of: 'rgb', 'rgba', 'hsl', 'hsla', 'color'\n * @param {array} color.values - [n,n,n] or [n,n,n,n]\n * @returns {string} A CSS color string\n */\nexport function recomposeColor(color) {\n const {\n type,\n colorSpace\n } = color;\n let {\n values\n } = color;\n if (type.indexOf('rgb') !== -1) {\n // Only convert the first 3 values to int (i.e. not alpha)\n values = values.map((n, i) => i < 3 ? parseInt(n, 10) : n);\n } else if (type.indexOf('hsl') !== -1) {\n values[1] = `${values[1]}%`;\n values[2] = `${values[2]}%`;\n }\n if (type.indexOf('color') !== -1) {\n values = `${colorSpace} ${values.join(' ')}`;\n } else {\n values = `${values.join(', ')}`;\n }\n return `${type}(${values})`;\n}\n\n/**\n * Converts a color from CSS rgb format to CSS hex format.\n * @param {string} color - RGB color, i.e. rgb(n, n, n)\n * @returns {string} A CSS rgb color string, i.e. #nnnnnn\n */\nexport function rgbToHex(color) {\n // Idempotent\n if (color.indexOf('#') === 0) {\n return color;\n }\n const {\n values\n } = decomposeColor(color);\n return `#${values.map((n, i) => intToHex(i === 3 ? Math.round(255 * n) : n)).join('')}`;\n}\n\n/**\n * Converts a color from hsl format to rgb format.\n * @param {string} color - HSL color values\n * @returns {string} rgb color values\n */\nexport function hslToRgb(color) {\n color = decomposeColor(color);\n const {\n values\n } = color;\n const h = values[0];\n const s = values[1] / 100;\n const l = values[2] / 100;\n const a = s * Math.min(l, 1 - l);\n const f = (n, k = (n + h / 30) % 12) => l - a * Math.max(Math.min(k - 3, 9 - k, 1), -1);\n let type = 'rgb';\n const rgb = [Math.round(f(0) * 255), Math.round(f(8) * 255), Math.round(f(4) * 255)];\n if (color.type === 'hsla') {\n type += 'a';\n rgb.push(values[3]);\n }\n return recomposeColor({\n type,\n values: rgb\n });\n}\n/**\n * The relative brightness of any point in a color space,\n * normalized to 0 for darkest black and 1 for lightest white.\n *\n * Formula: https://www.w3.org/TR/WCAG20-TECHS/G17.html#G17-tests\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @returns {number} The relative brightness of the color in the range 0 - 1\n */\nexport function getLuminance(color) {\n color = decomposeColor(color);\n let rgb = color.type === 'hsl' || color.type === 'hsla' ? decomposeColor(hslToRgb(color)).values : color.values;\n rgb = rgb.map(val => {\n if (color.type !== 'color') {\n val /= 255; // normalized\n }\n return val <= 0.03928 ? val / 12.92 : ((val + 0.055) / 1.055) ** 2.4;\n });\n\n // Truncate at 3 digits\n return Number((0.2126 * rgb[0] + 0.7152 * rgb[1] + 0.0722 * rgb[2]).toFixed(3));\n}\n\n/**\n * Calculates the contrast ratio between two colors.\n *\n * Formula: https://www.w3.org/TR/WCAG20-TECHS/G17.html#G17-tests\n * @param {string} foreground - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla()\n * @param {string} background - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla()\n * @returns {number} A contrast ratio value in the range 0 - 21.\n */\nexport function getContrastRatio(foreground, background) {\n const lumA = getLuminance(foreground);\n const lumB = getLuminance(background);\n return (Math.max(lumA, lumB) + 0.05) / (Math.min(lumA, lumB) + 0.05);\n}\n\n/**\n * Sets the absolute transparency of a color.\n * Any existing alpha values are overwritten.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} value - value to set the alpha channel to in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function alpha(color, value) {\n color = decomposeColor(color);\n value = clampWrapper(value);\n if (color.type === 'rgb' || color.type === 'hsl') {\n color.type += 'a';\n }\n if (color.type === 'color') {\n color.values[3] = `/${value}`;\n } else {\n color.values[3] = value;\n }\n return recomposeColor(color);\n}\nexport function private_safeAlpha(color, value, warning) {\n try {\n return alpha(color, value);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Darkens a color.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} coefficient - multiplier in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function darken(color, coefficient) {\n color = decomposeColor(color);\n coefficient = clampWrapper(coefficient);\n if (color.type.indexOf('hsl') !== -1) {\n color.values[2] *= 1 - coefficient;\n } else if (color.type.indexOf('rgb') !== -1 || color.type.indexOf('color') !== -1) {\n for (let i = 0; i < 3; i += 1) {\n color.values[i] *= 1 - coefficient;\n }\n }\n return recomposeColor(color);\n}\nexport function private_safeDarken(color, coefficient, warning) {\n try {\n return darken(color, coefficient);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Lightens a color.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} coefficient - multiplier in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function lighten(color, coefficient) {\n color = decomposeColor(color);\n coefficient = clampWrapper(coefficient);\n if (color.type.indexOf('hsl') !== -1) {\n color.values[2] += (100 - color.values[2]) * coefficient;\n } else if (color.type.indexOf('rgb') !== -1) {\n for (let i = 0; i < 3; i += 1) {\n color.values[i] += (255 - color.values[i]) * coefficient;\n }\n } else if (color.type.indexOf('color') !== -1) {\n for (let i = 0; i < 3; i += 1) {\n color.values[i] += (1 - color.values[i]) * coefficient;\n }\n }\n return recomposeColor(color);\n}\nexport function private_safeLighten(color, coefficient, warning) {\n try {\n return lighten(color, coefficient);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Darken or lighten a color, depending on its luminance.\n * Light colors are darkened, dark colors are lightened.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} coefficient=0.15 - multiplier in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function emphasize(color, coefficient = 0.15) {\n return getLuminance(color) > 0.5 ? darken(color, coefficient) : lighten(color, coefficient);\n}\nexport function private_safeEmphasize(color, coefficient, warning) {\n try {\n return emphasize(color, coefficient);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Blend a transparent overlay color with a background color, resulting in a single\n * RGB color.\n * @param {string} background - CSS color\n * @param {string} overlay - CSS color\n * @param {number} opacity - Opacity multiplier in the range 0 - 1\n * @param {number} [gamma=1.0] - Gamma correction factor. For gamma-correct blending, 2.2 is usual.\n */\nexport function blend(background, overlay, opacity, gamma = 1.0) {\n const blendChannel = (b, o) => Math.round((b ** (1 / gamma) * (1 - opacity) + o ** (1 / gamma) * opacity) ** gamma);\n const backgroundColor = decomposeColor(background);\n const overlayColor = decomposeColor(overlay);\n const rgb = [blendChannel(backgroundColor.values[0], overlayColor.values[0]), blendChannel(backgroundColor.values[1], overlayColor.values[1]), blendChannel(backgroundColor.values[2], overlayColor.values[2])];\n return recomposeColor({\n type: 'rgb',\n values: rgb\n });\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nexport default function createMixins(breakpoints, mixins) {\n return _extends({\n toolbar: {\n minHeight: 56,\n [breakpoints.up('xs')]: {\n '@media (orientation: landscape)': {\n minHeight: 48\n }\n },\n [breakpoints.up('sm')]: {\n minHeight: 64\n }\n }\n }, mixins);\n}","const common = {\n black: '#000',\n white: '#fff'\n};\nexport default common;","const grey = {\n 50: '#fafafa',\n 100: '#f5f5f5',\n 200: '#eeeeee',\n 300: '#e0e0e0',\n 400: '#bdbdbd',\n 500: '#9e9e9e',\n 600: '#757575',\n 700: '#616161',\n 800: '#424242',\n 900: '#212121',\n A100: '#f5f5f5',\n A200: '#eeeeee',\n A400: '#bdbdbd',\n A700: '#616161'\n};\nexport default grey;","const purple = {\n 50: '#f3e5f5',\n 100: '#e1bee7',\n 200: '#ce93d8',\n 300: '#ba68c8',\n 400: '#ab47bc',\n 500: '#9c27b0',\n 600: '#8e24aa',\n 700: '#7b1fa2',\n 800: '#6a1b9a',\n 900: '#4a148c',\n A100: '#ea80fc',\n A200: '#e040fb',\n A400: '#d500f9',\n A700: '#aa00ff'\n};\nexport default purple;","const red = {\n 50: '#ffebee',\n 100: '#ffcdd2',\n 200: '#ef9a9a',\n 300: '#e57373',\n 400: '#ef5350',\n 500: '#f44336',\n 600: '#e53935',\n 700: '#d32f2f',\n 800: '#c62828',\n 900: '#b71c1c',\n A100: '#ff8a80',\n A200: '#ff5252',\n A400: '#ff1744',\n A700: '#d50000'\n};\nexport default red;","const orange = {\n 50: '#fff3e0',\n 100: '#ffe0b2',\n 200: '#ffcc80',\n 300: '#ffb74d',\n 400: '#ffa726',\n 500: '#ff9800',\n 600: '#fb8c00',\n 700: '#f57c00',\n 800: '#ef6c00',\n 900: '#e65100',\n A100: '#ffd180',\n A200: '#ffab40',\n A400: '#ff9100',\n A700: '#ff6d00'\n};\nexport default orange;","const blue = {\n 50: '#e3f2fd',\n 100: '#bbdefb',\n 200: '#90caf9',\n 300: '#64b5f6',\n 400: '#42a5f5',\n 500: '#2196f3',\n 600: '#1e88e5',\n 700: '#1976d2',\n 800: '#1565c0',\n 900: '#0d47a1',\n A100: '#82b1ff',\n A200: '#448aff',\n A400: '#2979ff',\n A700: '#2962ff'\n};\nexport default blue;","const lightBlue = {\n 50: '#e1f5fe',\n 100: '#b3e5fc',\n 200: '#81d4fa',\n 300: '#4fc3f7',\n 400: '#29b6f6',\n 500: '#03a9f4',\n 600: '#039be5',\n 700: '#0288d1',\n 800: '#0277bd',\n 900: '#01579b',\n A100: '#80d8ff',\n A200: '#40c4ff',\n A400: '#00b0ff',\n A700: '#0091ea'\n};\nexport default lightBlue;","const green = {\n 50: '#e8f5e9',\n 100: '#c8e6c9',\n 200: '#a5d6a7',\n 300: '#81c784',\n 400: '#66bb6a',\n 500: '#4caf50',\n 600: '#43a047',\n 700: '#388e3c',\n 800: '#2e7d32',\n 900: '#1b5e20',\n A100: '#b9f6ca',\n A200: '#69f0ae',\n A400: '#00e676',\n A700: '#00c853'\n};\nexport default green;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\nconst _excluded = [\"mode\", \"contrastThreshold\", \"tonalOffset\"];\nimport { deepmerge } from '@mui/utils';\nimport { darken, getContrastRatio, lighten } from '@mui/system';\nimport common from '../colors/common';\nimport grey from '../colors/grey';\nimport purple from '../colors/purple';\nimport red from '../colors/red';\nimport orange from '../colors/orange';\nimport blue from '../colors/blue';\nimport lightBlue from '../colors/lightBlue';\nimport green from '../colors/green';\nexport const light = {\n // The colors used to style the text.\n text: {\n // The most important text.\n primary: 'rgba(0, 0, 0, 0.87)',\n // Secondary text.\n secondary: 'rgba(0, 0, 0, 0.6)',\n // Disabled text have even lower visual prominence.\n disabled: 'rgba(0, 0, 0, 0.38)'\n },\n // The color used to divide different elements.\n divider: 'rgba(0, 0, 0, 0.12)',\n // The background colors used to style the surfaces.\n // Consistency between these values is important.\n background: {\n paper: common.white,\n default: common.white\n },\n // The colors used to style the action elements.\n action: {\n // The color of an active action like an icon button.\n active: 'rgba(0, 0, 0, 0.54)',\n // The color of an hovered action.\n hover: 'rgba(0, 0, 0, 0.04)',\n hoverOpacity: 0.04,\n // The color of a selected action.\n selected: 'rgba(0, 0, 0, 0.08)',\n selectedOpacity: 0.08,\n // The color of a disabled action.\n disabled: 'rgba(0, 0, 0, 0.26)',\n // The background color of a disabled action.\n disabledBackground: 'rgba(0, 0, 0, 0.12)',\n disabledOpacity: 0.38,\n focus: 'rgba(0, 0, 0, 0.12)',\n focusOpacity: 0.12,\n activatedOpacity: 0.12\n }\n};\nexport const dark = {\n text: {\n primary: common.white,\n secondary: 'rgba(255, 255, 255, 0.7)',\n disabled: 'rgba(255, 255, 255, 0.5)',\n icon: 'rgba(255, 255, 255, 0.5)'\n },\n divider: 'rgba(255, 255, 255, 0.12)',\n background: {\n paper: '#121212',\n default: '#121212'\n },\n action: {\n active: common.white,\n hover: 'rgba(255, 255, 255, 0.08)',\n hoverOpacity: 0.08,\n selected: 'rgba(255, 255, 255, 0.16)',\n selectedOpacity: 0.16,\n disabled: 'rgba(255, 255, 255, 0.3)',\n disabledBackground: 'rgba(255, 255, 255, 0.12)',\n disabledOpacity: 0.38,\n focus: 'rgba(255, 255, 255, 0.12)',\n focusOpacity: 0.12,\n activatedOpacity: 0.24\n }\n};\nfunction addLightOrDark(intent, direction, shade, tonalOffset) {\n const tonalOffsetLight = tonalOffset.light || tonalOffset;\n const tonalOffsetDark = tonalOffset.dark || tonalOffset * 1.5;\n if (!intent[direction]) {\n if (intent.hasOwnProperty(shade)) {\n intent[direction] = intent[shade];\n } else if (direction === 'light') {\n intent.light = lighten(intent.main, tonalOffsetLight);\n } else if (direction === 'dark') {\n intent.dark = darken(intent.main, tonalOffsetDark);\n }\n }\n}\nfunction getDefaultPrimary(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: blue[200],\n light: blue[50],\n dark: blue[400]\n };\n }\n return {\n main: blue[700],\n light: blue[400],\n dark: blue[800]\n };\n}\nfunction getDefaultSecondary(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: purple[200],\n light: purple[50],\n dark: purple[400]\n };\n }\n return {\n main: purple[500],\n light: purple[300],\n dark: purple[700]\n };\n}\nfunction getDefaultError(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: red[500],\n light: red[300],\n dark: red[700]\n };\n }\n return {\n main: red[700],\n light: red[400],\n dark: red[800]\n };\n}\nfunction getDefaultInfo(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: lightBlue[400],\n light: lightBlue[300],\n dark: lightBlue[700]\n };\n }\n return {\n main: lightBlue[700],\n light: lightBlue[500],\n dark: lightBlue[900]\n };\n}\nfunction getDefaultSuccess(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: green[400],\n light: green[300],\n dark: green[700]\n };\n }\n return {\n main: green[800],\n light: green[500],\n dark: green[900]\n };\n}\nfunction getDefaultWarning(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: orange[400],\n light: orange[300],\n dark: orange[700]\n };\n }\n return {\n main: '#ed6c02',\n // closest to orange[800] that pass 3:1.\n light: orange[500],\n dark: orange[900]\n };\n}\nexport default function createPalette(palette) {\n const {\n mode = 'light',\n contrastThreshold = 3,\n tonalOffset = 0.2\n } = palette,\n other = _objectWithoutPropertiesLoose(palette, _excluded);\n const primary = palette.primary || getDefaultPrimary(mode);\n const secondary = palette.secondary || getDefaultSecondary(mode);\n const error = palette.error || getDefaultError(mode);\n const info = palette.info || getDefaultInfo(mode);\n const success = palette.success || getDefaultSuccess(mode);\n const warning = palette.warning || getDefaultWarning(mode);\n\n // Use the same logic as\n // Bootstrap: https://github.com/twbs/bootstrap/blob/1d6e3710dd447de1a200f29e8fa521f8a0908f70/scss/_functions.scss#L59\n // and material-components-web https://github.com/material-components/material-components-web/blob/ac46b8863c4dab9fc22c4c662dc6bd1b65dd652f/packages/mdc-theme/_functions.scss#L54\n function getContrastText(background) {\n const contrastText = getContrastRatio(background, dark.text.primary) >= contrastThreshold ? dark.text.primary : light.text.primary;\n if (process.env.NODE_ENV !== 'production') {\n const contrast = getContrastRatio(background, contrastText);\n if (contrast < 3) {\n console.error([`MUI: The contrast ratio of ${contrast}:1 for ${contrastText} on ${background}`, 'falls below the WCAG recommended absolute minimum contrast ratio of 3:1.', 'https://www.w3.org/TR/2008/REC-WCAG20-20081211/#visual-audio-contrast-contrast'].join('\\n'));\n }\n }\n return contrastText;\n }\n const augmentColor = ({\n color,\n name,\n mainShade = 500,\n lightShade = 300,\n darkShade = 700\n }) => {\n color = _extends({}, color);\n if (!color.main && color[mainShade]) {\n color.main = color[mainShade];\n }\n if (!color.hasOwnProperty('main')) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: The color${name ? ` (${name})` : ''} provided to augmentColor(color) is invalid.\nThe color object needs to have a \\`main\\` property or a \\`${mainShade}\\` property.` : _formatMuiErrorMessage(11, name ? ` (${name})` : '', mainShade));\n }\n if (typeof color.main !== 'string') {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: The color${name ? ` (${name})` : ''} provided to augmentColor(color) is invalid.\n\\`color.main\\` should be a string, but \\`${JSON.stringify(color.main)}\\` was provided instead.\n\nDid you intend to use one of the following approaches?\n\nimport { green } from \"@mui/material/colors\";\n\nconst theme1 = createTheme({ palette: {\n primary: green,\n} });\n\nconst theme2 = createTheme({ palette: {\n primary: { main: green[500] },\n} });` : _formatMuiErrorMessage(12, name ? ` (${name})` : '', JSON.stringify(color.main)));\n }\n addLightOrDark(color, 'light', lightShade, tonalOffset);\n addLightOrDark(color, 'dark', darkShade, tonalOffset);\n if (!color.contrastText) {\n color.contrastText = getContrastText(color.main);\n }\n return color;\n };\n const modes = {\n dark,\n light\n };\n if (process.env.NODE_ENV !== 'production') {\n if (!modes[mode]) {\n console.error(`MUI: The palette mode \\`${mode}\\` is not supported.`);\n }\n }\n const paletteOutput = deepmerge(_extends({\n // A collection of common colors.\n common: _extends({}, common),\n // prevent mutable object.\n // The palette mode, can be light or dark.\n mode,\n // The colors used to represent primary interface elements for a user.\n primary: augmentColor({\n color: primary,\n name: 'primary'\n }),\n // The colors used to represent secondary interface elements for a user.\n secondary: augmentColor({\n color: secondary,\n name: 'secondary',\n mainShade: 'A400',\n lightShade: 'A200',\n darkShade: 'A700'\n }),\n // The colors used to represent interface elements that the user should be made aware of.\n error: augmentColor({\n color: error,\n name: 'error'\n }),\n // The colors used to represent potentially dangerous actions or important messages.\n warning: augmentColor({\n color: warning,\n name: 'warning'\n }),\n // The colors used to present information to the user that is neutral and not necessarily important.\n info: augmentColor({\n color: info,\n name: 'info'\n }),\n // The colors used to indicate the successful completion of an action that user triggered.\n success: augmentColor({\n color: success,\n name: 'success'\n }),\n // The grey colors.\n grey,\n // Used by `getContrastText()` to maximize the contrast between\n // the background and the text.\n contrastThreshold,\n // Takes a background color and returns the text color that maximizes the contrast.\n getContrastText,\n // Generate a rich color object.\n augmentColor,\n // Used by the functions below to shift a color's luminance by approximately\n // two indexes within its tonal palette.\n // E.g., shift from Red 500 to Red 300 or Red 700.\n tonalOffset\n }, modes[mode]), other);\n return paletteOutput;\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"fontFamily\", \"fontSize\", \"fontWeightLight\", \"fontWeightRegular\", \"fontWeightMedium\", \"fontWeightBold\", \"htmlFontSize\", \"allVariants\", \"pxToRem\"];\nimport { deepmerge } from '@mui/utils';\nfunction round(value) {\n return Math.round(value * 1e5) / 1e5;\n}\nconst caseAllCaps = {\n textTransform: 'uppercase'\n};\nconst defaultFontFamily = '\"Roboto\", \"Helvetica\", \"Arial\", sans-serif';\n\n/**\n * @see @link{https://m2.material.io/design/typography/the-type-system.html}\n * @see @link{https://m2.material.io/design/typography/understanding-typography.html}\n */\nexport default function createTypography(palette, typography) {\n const _ref = typeof typography === 'function' ? typography(palette) : typography,\n {\n fontFamily = defaultFontFamily,\n // The default font size of the Material Specification.\n fontSize = 14,\n // px\n fontWeightLight = 300,\n fontWeightRegular = 400,\n fontWeightMedium = 500,\n fontWeightBold = 700,\n // Tell MUI what's the font-size on the html element.\n // 16px is the default font-size used by browsers.\n htmlFontSize = 16,\n // Apply the CSS properties to all the variants.\n allVariants,\n pxToRem: pxToRem2\n } = _ref,\n other = _objectWithoutPropertiesLoose(_ref, _excluded);\n if (process.env.NODE_ENV !== 'production') {\n if (typeof fontSize !== 'number') {\n console.error('MUI: `fontSize` is required to be a number.');\n }\n if (typeof htmlFontSize !== 'number') {\n console.error('MUI: `htmlFontSize` is required to be a number.');\n }\n }\n const coef = fontSize / 14;\n const pxToRem = pxToRem2 || (size => `${size / htmlFontSize * coef}rem`);\n const buildVariant = (fontWeight, size, lineHeight, letterSpacing, casing) => _extends({\n fontFamily,\n fontWeight,\n fontSize: pxToRem(size),\n // Unitless following https://meyerweb.com/eric/thoughts/2006/02/08/unitless-line-heights/\n lineHeight\n }, fontFamily === defaultFontFamily ? {\n letterSpacing: `${round(letterSpacing / size)}em`\n } : {}, casing, allVariants);\n const variants = {\n h1: buildVariant(fontWeightLight, 96, 1.167, -1.5),\n h2: buildVariant(fontWeightLight, 60, 1.2, -0.5),\n h3: buildVariant(fontWeightRegular, 48, 1.167, 0),\n h4: buildVariant(fontWeightRegular, 34, 1.235, 0.25),\n h5: buildVariant(fontWeightRegular, 24, 1.334, 0),\n h6: buildVariant(fontWeightMedium, 20, 1.6, 0.15),\n subtitle1: buildVariant(fontWeightRegular, 16, 1.75, 0.15),\n subtitle2: buildVariant(fontWeightMedium, 14, 1.57, 0.1),\n body1: buildVariant(fontWeightRegular, 16, 1.5, 0.15),\n body2: buildVariant(fontWeightRegular, 14, 1.43, 0.15),\n button: buildVariant(fontWeightMedium, 14, 1.75, 0.4, caseAllCaps),\n caption: buildVariant(fontWeightRegular, 12, 1.66, 0.4),\n overline: buildVariant(fontWeightRegular, 12, 2.66, 1, caseAllCaps),\n // TODO v6: Remove handling of 'inherit' variant from the theme as it is already handled in Material UI's Typography component. Also, remember to remove the associated types.\n inherit: {\n fontFamily: 'inherit',\n fontWeight: 'inherit',\n fontSize: 'inherit',\n lineHeight: 'inherit',\n letterSpacing: 'inherit'\n }\n };\n return deepmerge(_extends({\n htmlFontSize,\n pxToRem,\n fontFamily,\n fontSize,\n fontWeightLight,\n fontWeightRegular,\n fontWeightMedium,\n fontWeightBold\n }, variants), other, {\n clone: false // No need to clone deep\n });\n}","const shadowKeyUmbraOpacity = 0.2;\nconst shadowKeyPenumbraOpacity = 0.14;\nconst shadowAmbientShadowOpacity = 0.12;\nfunction createShadow(...px) {\n return [`${px[0]}px ${px[1]}px ${px[2]}px ${px[3]}px rgba(0,0,0,${shadowKeyUmbraOpacity})`, `${px[4]}px ${px[5]}px ${px[6]}px ${px[7]}px rgba(0,0,0,${shadowKeyPenumbraOpacity})`, `${px[8]}px ${px[9]}px ${px[10]}px ${px[11]}px rgba(0,0,0,${shadowAmbientShadowOpacity})`].join(',');\n}\n\n// Values from https://github.com/material-components/material-components-web/blob/be8747f94574669cb5e7add1a7c54fa41a89cec7/packages/mdc-elevation/_variables.scss\nconst shadows = ['none', createShadow(0, 2, 1, -1, 0, 1, 1, 0, 0, 1, 3, 0), createShadow(0, 3, 1, -2, 0, 2, 2, 0, 0, 1, 5, 0), createShadow(0, 3, 3, -2, 0, 3, 4, 0, 0, 1, 8, 0), createShadow(0, 2, 4, -1, 0, 4, 5, 0, 0, 1, 10, 0), createShadow(0, 3, 5, -1, 0, 5, 8, 0, 0, 1, 14, 0), createShadow(0, 3, 5, -1, 0, 6, 10, 0, 0, 1, 18, 0), createShadow(0, 4, 5, -2, 0, 7, 10, 1, 0, 2, 16, 1), createShadow(0, 5, 5, -3, 0, 8, 10, 1, 0, 3, 14, 2), createShadow(0, 5, 6, -3, 0, 9, 12, 1, 0, 3, 16, 2), createShadow(0, 6, 6, -3, 0, 10, 14, 1, 0, 4, 18, 3), createShadow(0, 6, 7, -4, 0, 11, 15, 1, 0, 4, 20, 3), createShadow(0, 7, 8, -4, 0, 12, 17, 2, 0, 5, 22, 4), createShadow(0, 7, 8, -4, 0, 13, 19, 2, 0, 5, 24, 4), createShadow(0, 7, 9, -4, 0, 14, 21, 2, 0, 5, 26, 4), createShadow(0, 8, 9, -5, 0, 15, 22, 2, 0, 6, 28, 5), createShadow(0, 8, 10, -5, 0, 16, 24, 2, 0, 6, 30, 5), createShadow(0, 8, 11, -5, 0, 17, 26, 2, 0, 6, 32, 5), createShadow(0, 9, 11, -5, 0, 18, 28, 2, 0, 7, 34, 6), createShadow(0, 9, 12, -6, 0, 19, 29, 2, 0, 7, 36, 6), createShadow(0, 10, 13, -6, 0, 20, 31, 3, 0, 8, 38, 7), createShadow(0, 10, 13, -6, 0, 21, 33, 3, 0, 8, 40, 7), createShadow(0, 10, 14, -6, 0, 22, 35, 3, 0, 8, 42, 7), createShadow(0, 11, 14, -7, 0, 23, 36, 3, 0, 9, 44, 8), createShadow(0, 11, 15, -7, 0, 24, 38, 3, 0, 9, 46, 8)];\nexport default shadows;","import _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nconst _excluded = [\"duration\", \"easing\", \"delay\"];\n// Follow https://material.google.com/motion/duration-easing.html#duration-easing-natural-easing-curves\n// to learn the context in which each easing should be used.\nexport const easing = {\n // This is the most common easing curve.\n easeInOut: 'cubic-bezier(0.4, 0, 0.2, 1)',\n // Objects enter the screen at full velocity from off-screen and\n // slowly decelerate to a resting point.\n easeOut: 'cubic-bezier(0.0, 0, 0.2, 1)',\n // Objects leave the screen at full velocity. They do not decelerate when off-screen.\n easeIn: 'cubic-bezier(0.4, 0, 1, 1)',\n // The sharp curve is used by objects that may return to the screen at any time.\n sharp: 'cubic-bezier(0.4, 0, 0.6, 1)'\n};\n\n// Follow https://m2.material.io/guidelines/motion/duration-easing.html#duration-easing-common-durations\n// to learn when use what timing\nexport const duration = {\n shortest: 150,\n shorter: 200,\n short: 250,\n // most basic recommended timing\n standard: 300,\n // this is to be used in complex animations\n complex: 375,\n // recommended when something is entering screen\n enteringScreen: 225,\n // recommended when something is leaving screen\n leavingScreen: 195\n};\nfunction formatMs(milliseconds) {\n return `${Math.round(milliseconds)}ms`;\n}\nfunction getAutoHeightDuration(height) {\n if (!height) {\n return 0;\n }\n const constant = height / 36;\n\n // https://www.wolframalpha.com/input/?i=(4+%2B+15+*+(x+%2F+36+)+**+0.25+%2B+(x+%2F+36)+%2F+5)+*+10\n return Math.round((4 + 15 * constant ** 0.25 + constant / 5) * 10);\n}\nexport default function createTransitions(inputTransitions) {\n const mergedEasing = _extends({}, easing, inputTransitions.easing);\n const mergedDuration = _extends({}, duration, inputTransitions.duration);\n const create = (props = ['all'], options = {}) => {\n const {\n duration: durationOption = mergedDuration.standard,\n easing: easingOption = mergedEasing.easeInOut,\n delay = 0\n } = options,\n other = _objectWithoutPropertiesLoose(options, _excluded);\n if (process.env.NODE_ENV !== 'production') {\n const isString = value => typeof value === 'string';\n // IE11 support, replace with Number.isNaN\n // eslint-disable-next-line no-restricted-globals\n const isNumber = value => !isNaN(parseFloat(value));\n if (!isString(props) && !Array.isArray(props)) {\n console.error('MUI: Argument \"props\" must be a string or Array.');\n }\n if (!isNumber(durationOption) && !isString(durationOption)) {\n console.error(`MUI: Argument \"duration\" must be a number or a string but found ${durationOption}.`);\n }\n if (!isString(easingOption)) {\n console.error('MUI: Argument \"easing\" must be a string.');\n }\n if (!isNumber(delay) && !isString(delay)) {\n console.error('MUI: Argument \"delay\" must be a number or a string.');\n }\n if (typeof options !== 'object') {\n console.error(['MUI: Secong argument of transition.create must be an object.', \"Arguments should be either `create('prop1', options)` or `create(['prop1', 'prop2'], options)`\"].join('\\n'));\n }\n if (Object.keys(other).length !== 0) {\n console.error(`MUI: Unrecognized argument(s) [${Object.keys(other).join(',')}].`);\n }\n }\n return (Array.isArray(props) ? props : [props]).map(animatedProp => `${animatedProp} ${typeof durationOption === 'string' ? durationOption : formatMs(durationOption)} ${easingOption} ${typeof delay === 'string' ? delay : formatMs(delay)}`).join(',');\n };\n return _extends({\n getAutoHeightDuration,\n create\n }, inputTransitions, {\n easing: mergedEasing,\n duration: mergedDuration\n });\n}","// We need to centralize the zIndex definitions as they work\n// like global values in the browser.\nconst zIndex = {\n mobileStepper: 1000,\n fab: 1050,\n speedDial: 1050,\n appBar: 1100,\n drawer: 1200,\n modal: 1300,\n snackbar: 1400,\n tooltip: 1500\n};\nexport default zIndex;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\nconst _excluded = [\"breakpoints\", \"mixins\", \"spacing\", \"palette\", \"transitions\", \"typography\", \"shape\"];\nimport { deepmerge } from '@mui/utils';\nimport { createTheme as systemCreateTheme, unstable_defaultSxConfig as defaultSxConfig, unstable_styleFunctionSx as styleFunctionSx } from '@mui/system';\nimport generateUtilityClass from '@mui/utils/generateUtilityClass';\nimport createMixins from './createMixins';\nimport createPalette from './createPalette';\nimport createTypography from './createTypography';\nimport shadows from './shadows';\nimport createTransitions from './createTransitions';\nimport zIndex from './zIndex';\nfunction createTheme(options = {}, ...args) {\n const {\n mixins: mixinsInput = {},\n palette: paletteInput = {},\n transitions: transitionsInput = {},\n typography: typographyInput = {}\n } = options,\n other = _objectWithoutPropertiesLoose(options, _excluded);\n if (options.vars) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: \\`vars\\` is a private field used for CSS variables support.\nPlease use another name.` : _formatMuiErrorMessage(18));\n }\n const palette = createPalette(paletteInput);\n const systemTheme = systemCreateTheme(options);\n let muiTheme = deepmerge(systemTheme, {\n mixins: createMixins(systemTheme.breakpoints, mixinsInput),\n palette,\n // Don't use [...shadows] until you've verified its transpiled code is not invoking the iterator protocol.\n shadows: shadows.slice(),\n typography: createTypography(palette, typographyInput),\n transitions: createTransitions(transitionsInput),\n zIndex: _extends({}, zIndex)\n });\n muiTheme = deepmerge(muiTheme, other);\n muiTheme = args.reduce((acc, argument) => deepmerge(acc, argument), muiTheme);\n if (process.env.NODE_ENV !== 'production') {\n // TODO v6: Refactor to use globalStateClassesMapping from @mui/utils once `readOnly` state class is used in Rating component.\n const stateClasses = ['active', 'checked', 'completed', 'disabled', 'error', 'expanded', 'focused', 'focusVisible', 'required', 'selected'];\n const traverse = (node, component) => {\n let key;\n\n // eslint-disable-next-line guard-for-in, no-restricted-syntax\n for (key in node) {\n const child = node[key];\n if (stateClasses.indexOf(key) !== -1 && Object.keys(child).length > 0) {\n if (process.env.NODE_ENV !== 'production') {\n const stateClass = generateUtilityClass('', key);\n console.error([`MUI: The \\`${component}\\` component increases ` + `the CSS specificity of the \\`${key}\\` internal state.`, 'You can not override it like this: ', JSON.stringify(node, null, 2), '', `Instead, you need to use the '&.${stateClass}' syntax:`, JSON.stringify({\n root: {\n [`&.${stateClass}`]: child\n }\n }, null, 2), '', 'https://mui.com/r/state-classes-guide'].join('\\n'));\n }\n // Remove the style to prevent global conflicts.\n node[key] = {};\n }\n }\n };\n Object.keys(muiTheme.components).forEach(component => {\n const styleOverrides = muiTheme.components[component].styleOverrides;\n if (styleOverrides && component.indexOf('Mui') === 0) {\n traverse(styleOverrides, component);\n }\n });\n }\n muiTheme.unstable_sxConfig = _extends({}, defaultSxConfig, other == null ? void 0 : other.unstable_sxConfig);\n muiTheme.unstable_sx = function sx(props) {\n return styleFunctionSx({\n sx: props,\n theme: this\n });\n };\n return muiTheme;\n}\nlet warnedOnce = false;\nexport function createMuiTheme(...args) {\n if (process.env.NODE_ENV !== 'production') {\n if (!warnedOnce) {\n warnedOnce = true;\n console.error(['MUI: the createMuiTheme function was renamed to createTheme.', '', \"You should use `import { createTheme } from '@mui/material/styles'`\"].join('\\n'));\n }\n }\n return createTheme(...args);\n}\nexport default createTheme;","'use client';\n\nimport createTheme from './createTheme';\nconst defaultTheme = createTheme();\nexport default defaultTheme;","export default '$$material';","'use client';\n\nimport { useThemeProps as systemUseThemeProps } from '@mui/system';\nimport defaultTheme from './defaultTheme';\nimport THEME_ID from './identifier';\nexport default function useThemeProps({\n props,\n name\n}) {\n return systemUseThemeProps({\n props,\n name,\n defaultTheme,\n themeId: THEME_ID\n });\n}","'use client';\n\nimport { createStyled, shouldForwardProp } from '@mui/system';\nimport defaultTheme from './defaultTheme';\nimport THEME_ID from './identifier';\nexport const rootShouldForwardProp = prop => shouldForwardProp(prop) && prop !== 'classes';\nexport const slotShouldForwardProp = shouldForwardProp;\nconst styled = createStyled({\n themeId: THEME_ID,\n defaultTheme,\n rootShouldForwardProp\n});\nexport default styled;","import generateUtilityClasses from '@mui/utils/generateUtilityClasses';\nimport generateUtilityClass from '@mui/utils/generateUtilityClass';\nexport function getSvgIconUtilityClass(slot) {\n return generateUtilityClass('MuiSvgIcon', slot);\n}\nconst svgIconClasses = generateUtilityClasses('MuiSvgIcon', ['root', 'colorPrimary', 'colorSecondary', 'colorAction', 'colorError', 'colorDisabled', 'fontSizeInherit', 'fontSizeSmall', 'fontSizeMedium', 'fontSizeLarge']);\nexport default svgIconClasses;","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"children\", \"className\", \"color\", \"component\", \"fontSize\", \"htmlColor\", \"inheritViewBox\", \"titleAccess\", \"viewBox\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport clsx from 'clsx';\nimport { unstable_composeClasses as composeClasses } from '@mui/base/composeClasses';\nimport capitalize from '../utils/capitalize';\nimport useThemeProps from '../styles/useThemeProps';\nimport styled from '../styles/styled';\nimport { getSvgIconUtilityClass } from './svgIconClasses';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nimport { jsxs as _jsxs } from \"react/jsx-runtime\";\nconst useUtilityClasses = ownerState => {\n const {\n color,\n fontSize,\n classes\n } = ownerState;\n const slots = {\n root: ['root', color !== 'inherit' && `color${capitalize(color)}`, `fontSize${capitalize(fontSize)}`]\n };\n return composeClasses(slots, getSvgIconUtilityClass, classes);\n};\nconst SvgIconRoot = styled('svg', {\n name: 'MuiSvgIcon',\n slot: 'Root',\n overridesResolver: (props, styles) => {\n const {\n ownerState\n } = props;\n return [styles.root, ownerState.color !== 'inherit' && styles[`color${capitalize(ownerState.color)}`], styles[`fontSize${capitalize(ownerState.fontSize)}`]];\n }\n})(({\n theme,\n ownerState\n}) => {\n var _theme$transitions, _theme$transitions$cr, _theme$transitions2, _theme$typography, _theme$typography$pxT, _theme$typography2, _theme$typography2$px, _theme$typography3, _theme$typography3$px, _palette$ownerState$c, _palette, _palette2, _palette3;\n return {\n userSelect: 'none',\n width: '1em',\n height: '1em',\n display: 'inline-block',\n // the will define the property that has `currentColor`\n // e.g. heroicons uses fill=\"none\" and stroke=\"currentColor\"\n fill: ownerState.hasSvgAsChild ? undefined : 'currentColor',\n flexShrink: 0,\n transition: (_theme$transitions = theme.transitions) == null || (_theme$transitions$cr = _theme$transitions.create) == null ? void 0 : _theme$transitions$cr.call(_theme$transitions, 'fill', {\n duration: (_theme$transitions2 = theme.transitions) == null || (_theme$transitions2 = _theme$transitions2.duration) == null ? void 0 : _theme$transitions2.shorter\n }),\n fontSize: {\n inherit: 'inherit',\n small: ((_theme$typography = theme.typography) == null || (_theme$typography$pxT = _theme$typography.pxToRem) == null ? void 0 : _theme$typography$pxT.call(_theme$typography, 20)) || '1.25rem',\n medium: ((_theme$typography2 = theme.typography) == null || (_theme$typography2$px = _theme$typography2.pxToRem) == null ? void 0 : _theme$typography2$px.call(_theme$typography2, 24)) || '1.5rem',\n large: ((_theme$typography3 = theme.typography) == null || (_theme$typography3$px = _theme$typography3.pxToRem) == null ? void 0 : _theme$typography3$px.call(_theme$typography3, 35)) || '2.1875rem'\n }[ownerState.fontSize],\n // TODO v5 deprecate, v6 remove for sx\n color: (_palette$ownerState$c = (_palette = (theme.vars || theme).palette) == null || (_palette = _palette[ownerState.color]) == null ? void 0 : _palette.main) != null ? _palette$ownerState$c : {\n action: (_palette2 = (theme.vars || theme).palette) == null || (_palette2 = _palette2.action) == null ? void 0 : _palette2.active,\n disabled: (_palette3 = (theme.vars || theme).palette) == null || (_palette3 = _palette3.action) == null ? void 0 : _palette3.disabled,\n inherit: undefined\n }[ownerState.color]\n };\n});\nconst SvgIcon = /*#__PURE__*/React.forwardRef(function SvgIcon(inProps, ref) {\n const props = useThemeProps({\n props: inProps,\n name: 'MuiSvgIcon'\n });\n const {\n children,\n className,\n color = 'inherit',\n component = 'svg',\n fontSize = 'medium',\n htmlColor,\n inheritViewBox = false,\n titleAccess,\n viewBox = '0 0 24 24'\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const hasSvgAsChild = /*#__PURE__*/React.isValidElement(children) && children.type === 'svg';\n const ownerState = _extends({}, props, {\n color,\n component,\n fontSize,\n instanceFontSize: inProps.fontSize,\n inheritViewBox,\n viewBox,\n hasSvgAsChild\n });\n const more = {};\n if (!inheritViewBox) {\n more.viewBox = viewBox;\n }\n const classes = useUtilityClasses(ownerState);\n return /*#__PURE__*/_jsxs(SvgIconRoot, _extends({\n as: component,\n className: clsx(classes.root, className),\n focusable: \"false\",\n color: htmlColor,\n \"aria-hidden\": titleAccess ? undefined : true,\n role: titleAccess ? 'img' : undefined,\n ref: ref\n }, more, other, hasSvgAsChild && children.props, {\n ownerState: ownerState,\n children: [hasSvgAsChild ? children.props.children : children, titleAccess ? /*#__PURE__*/_jsx(\"title\", {\n children: titleAccess\n }) : null]\n }));\n});\nprocess.env.NODE_ENV !== \"production\" ? SvgIcon.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the d.ts file and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * Node passed into the SVG element.\n */\n children: PropTypes.node,\n /**\n * Override or extend the styles applied to the component.\n */\n classes: PropTypes.object,\n /**\n * @ignore\n */\n className: PropTypes.string,\n /**\n * The color of the component.\n * It supports both default and custom theme colors, which can be added as shown in the\n * [palette customization guide](https://mui.com/material-ui/customization/palette/#custom-colors).\n * You can use the `htmlColor` prop to apply a color attribute to the SVG element.\n * @default 'inherit'\n */\n color: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.oneOf(['inherit', 'action', 'disabled', 'primary', 'secondary', 'error', 'info', 'success', 'warning']), PropTypes.string]),\n /**\n * The component used for the root node.\n * Either a string to use a HTML element or a component.\n */\n component: PropTypes.elementType,\n /**\n * The fontSize applied to the icon. Defaults to 24px, but can be configure to inherit font size.\n * @default 'medium'\n */\n fontSize: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.oneOf(['inherit', 'large', 'medium', 'small']), PropTypes.string]),\n /**\n * Applies a color attribute to the SVG element.\n */\n htmlColor: PropTypes.string,\n /**\n * If `true`, the root node will inherit the custom `component`'s viewBox and the `viewBox`\n * prop will be ignored.\n * Useful when you want to reference a custom `component` and have `SvgIcon` pass that\n * `component`'s viewBox to the root node.\n * @default false\n */\n inheritViewBox: PropTypes.bool,\n /**\n * The shape-rendering attribute. The behavior of the different options is described on the\n * [MDN Web Docs](https://developer.mozilla.org/en-US/docs/Web/SVG/Attribute/shape-rendering).\n * If you are having issues with blurry icons you should investigate this prop.\n */\n shapeRendering: PropTypes.string,\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Provides a human-readable title for the element that contains it.\n * https://www.w3.org/TR/SVG-access/#Equivalent\n */\n titleAccess: PropTypes.string,\n /**\n * Allows you to redefine what the coordinates without units mean inside an SVG element.\n * For example, if the SVG element is 500 (width) by 200 (height),\n * and you pass viewBox=\"0 0 50 20\",\n * this means that the coordinates inside the SVG will go from the top left corner (0,0)\n * to bottom right (50,20) and each unit will be worth 10px.\n * @default '0 0 24 24'\n */\n viewBox: PropTypes.string\n} : void 0;\nSvgIcon.muiName = 'SvgIcon';\nexport default SvgIcon;","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport * as React from 'react';\nimport SvgIcon from '../SvgIcon';\n\n/**\n * Private module reserved for @mui packages.\n */\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nexport default function createSvgIcon(path, displayName) {\n function Component(props, ref) {\n return /*#__PURE__*/_jsx(SvgIcon, _extends({\n \"data-testid\": `${displayName}Icon`,\n ref: ref\n }, props, {\n children: path\n }));\n }\n if (process.env.NODE_ENV !== 'production') {\n // Need to set `displayName` on the inner component for React.memo.\n // React prior to 16.14 ignores `displayName` on the wrapper.\n Component.displayName = `${displayName}Icon`;\n }\n Component.muiName = SvgIcon.muiName;\n return /*#__PURE__*/React.memo( /*#__PURE__*/React.forwardRef(Component));\n}","'use client';\n\nimport { unstable_ClassNameGenerator as ClassNameGenerator } from '@mui/base/ClassNameGenerator';\nexport { default as capitalize } from './capitalize';\nexport { default as createChainedFunction } from './createChainedFunction';\nexport { default as createSvgIcon } from './createSvgIcon';\nexport { default as debounce } from './debounce';\nexport { default as deprecatedPropType } from './deprecatedPropType';\nexport { default as isMuiElement } from './isMuiElement';\nexport { default as ownerDocument } from './ownerDocument';\nexport { default as ownerWindow } from './ownerWindow';\nexport { default as requirePropFactory } from './requirePropFactory';\nexport { default as setRef } from './setRef';\nexport { default as unstable_useEnhancedEffect } from './useEnhancedEffect';\nexport { default as unstable_useId } from './useId';\nexport { default as unsupportedProp } from './unsupportedProp';\nexport { default as useControlled } from './useControlled';\nexport { default as useEventCallback } from './useEventCallback';\nexport { default as useForkRef } from './useForkRef';\nexport { default as useIsFocusVisible } from './useIsFocusVisible';\n// TODO: remove this export once ClassNameGenerator is stable\n// eslint-disable-next-line @typescript-eslint/naming-convention\nexport const unstable_ClassNameGenerator = {\n configure: generator => {\n if (process.env.NODE_ENV !== 'production') {\n console.warn(['MUI: `ClassNameGenerator` import from `@mui/material/utils` is outdated and might cause unexpected issues.', '', \"You should use `import { unstable_ClassNameGenerator } from '@mui/material/className'` instead\", '', 'The detail of the issue: https://github.com/mui/material-ui/issues/30011#issuecomment-1024993401', '', 'The updated documentation: https://mui.com/guides/classname-generator/'].join('\\n'));\n }\n ClassNameGenerator.configure(generator);\n }\n};","\"use strict\";\n'use client';\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nObject.defineProperty(exports, \"default\", {\n enumerable: true,\n get: function () {\n return _utils.createSvgIcon;\n }\n});\nvar _utils = require(\"@mui/material/utils\");","\"use strict\";\n\"use client\";\n\nvar _interopRequireDefault = require(\"@babel/runtime/helpers/interopRequireDefault\");\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = void 0;\nvar _createSvgIcon = _interopRequireDefault(require(\"./utils/createSvgIcon\"));\nvar _jsxRuntime = require(\"react/jsx-runtime\");\nvar _default = exports.default = (0, _createSvgIcon.default)( /*#__PURE__*/(0, _jsxRuntime.jsx)(\"path\", {\n d: \"m10 17 5-5-5-5z\"\n}), 'ArrowRight');","/**\n * Determines if a given element is a DOM element name (i.e. not a React component).\n */\nexport function isHostComponent(element) {\n return typeof element === 'string';\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport { isHostComponent } from './isHostComponent';\n\n/**\n * Type of the ownerState based on the type of an element it applies to.\n * This resolves to the provided OwnerState for React components and `undefined` for host components.\n * Falls back to `OwnerState | undefined` when the exact type can't be determined in development time.\n */\n\n/**\n * Appends the ownerState object to the props, merging with the existing one if necessary.\n *\n * @param elementType Type of the element that owns the `existingProps`. If the element is a DOM node or undefined, `ownerState` is not applied.\n * @param otherProps Props of the element.\n * @param ownerState\n */\nexport function appendOwnerState(elementType, otherProps, ownerState) {\n if (elementType === undefined || isHostComponent(elementType)) {\n return otherProps;\n }\n return _extends({}, otherProps, {\n ownerState: _extends({}, otherProps.ownerState, ownerState)\n });\n}","'use client';\n\nimport * as React from 'react';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nconst defaultContextValue = {\n disableDefaultClasses: false\n};\nconst ClassNameConfiguratorContext = /*#__PURE__*/React.createContext(defaultContextValue);\n/**\n * @ignore - internal hook.\n *\n * Wraps the `generateUtilityClass` function and controls how the classes are generated.\n * Currently it only affects whether the classes are applied or not.\n *\n * @returns Function to be called with the `generateUtilityClass` function specific to a component to generate the classes.\n */\nexport function useClassNamesOverride(generateUtilityClass) {\n const {\n disableDefaultClasses\n } = React.useContext(ClassNameConfiguratorContext);\n return slot => {\n if (disableDefaultClasses) {\n return '';\n }\n return generateUtilityClass(slot);\n };\n}\n\n/**\n * Allows to configure the components within to not apply any built-in classes.\n */\nexport function ClassNameConfigurator(props) {\n const {\n disableDefaultClasses,\n children\n } = props;\n const contextValue = React.useMemo(() => ({\n disableDefaultClasses: disableDefaultClasses != null ? disableDefaultClasses : false\n }), [disableDefaultClasses]);\n return /*#__PURE__*/_jsx(ClassNameConfiguratorContext.Provider, {\n value: contextValue,\n children: children\n });\n}","/**\n * Extracts event handlers from a given object.\n * A prop is considered an event handler if it is a function and its name starts with `on`.\n *\n * @param object An object to extract event handlers from.\n * @param excludeKeys An array of keys to exclude from the returned object.\n */\nexport function extractEventHandlers(object, excludeKeys = []) {\n if (object === undefined) {\n return {};\n }\n const result = {};\n Object.keys(object).filter(prop => prop.match(/^on[A-Z]/) && typeof object[prop] === 'function' && !excludeKeys.includes(prop)).forEach(prop => {\n result[prop] = object[prop];\n });\n return result;\n}","/**\n * If `componentProps` is a function, calls it with the provided `ownerState`.\n * Otherwise, just returns `componentProps`.\n */\nexport function resolveComponentProps(componentProps, ownerState, slotState) {\n if (typeof componentProps === 'function') {\n return componentProps(ownerState, slotState);\n }\n return componentProps;\n}","/**\n * Removes event handlers from the given object.\n * A field is considered an event handler if it is a function with a name beginning with `on`.\n *\n * @param object Object to remove event handlers from.\n * @returns Object with event handlers removed.\n */\nexport function omitEventHandlers(object) {\n if (object === undefined) {\n return {};\n }\n const result = {};\n Object.keys(object).filter(prop => !(prop.match(/^on[A-Z]/) && typeof object[prop] === 'function')).forEach(prop => {\n result[prop] = object[prop];\n });\n return result;\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport clsx from 'clsx';\nimport { extractEventHandlers } from './extractEventHandlers';\nimport { omitEventHandlers } from './omitEventHandlers';\n/**\n * Merges the slot component internal props (usually coming from a hook)\n * with the externally provided ones.\n *\n * The merge order is (the latter overrides the former):\n * 1. The internal props (specified as a getter function to work with get*Props hook result)\n * 2. Additional props (specified internally on a Base UI component)\n * 3. External props specified on the owner component. These should only be used on a root slot.\n * 4. External props specified in the `slotProps.*` prop.\n * 5. The `className` prop - combined from all the above.\n * @param parameters\n * @returns\n */\nexport function mergeSlotProps(parameters) {\n const {\n getSlotProps,\n additionalProps,\n externalSlotProps,\n externalForwardedProps,\n className\n } = parameters;\n if (!getSlotProps) {\n // The simpler case - getSlotProps is not defined, so no internal event handlers are defined,\n // so we can simply merge all the props without having to worry about extracting event handlers.\n const joinedClasses = clsx(additionalProps == null ? void 0 : additionalProps.className, className, externalForwardedProps == null ? void 0 : externalForwardedProps.className, externalSlotProps == null ? void 0 : externalSlotProps.className);\n const mergedStyle = _extends({}, additionalProps == null ? void 0 : additionalProps.style, externalForwardedProps == null ? void 0 : externalForwardedProps.style, externalSlotProps == null ? void 0 : externalSlotProps.style);\n const props = _extends({}, additionalProps, externalForwardedProps, externalSlotProps);\n if (joinedClasses.length > 0) {\n props.className = joinedClasses;\n }\n if (Object.keys(mergedStyle).length > 0) {\n props.style = mergedStyle;\n }\n return {\n props,\n internalRef: undefined\n };\n }\n\n // In this case, getSlotProps is responsible for calling the external event handlers.\n // We don't need to include them in the merged props because of this.\n\n const eventHandlers = extractEventHandlers(_extends({}, externalForwardedProps, externalSlotProps));\n const componentsPropsWithoutEventHandlers = omitEventHandlers(externalSlotProps);\n const otherPropsWithoutEventHandlers = omitEventHandlers(externalForwardedProps);\n const internalSlotProps = getSlotProps(eventHandlers);\n\n // The order of classes is important here.\n // Emotion (that we use in libraries consuming Base UI) depends on this order\n // to properly override style. It requires the most important classes to be last\n // (see https://github.com/mui/material-ui/pull/33205) for the related discussion.\n const joinedClasses = clsx(internalSlotProps == null ? void 0 : internalSlotProps.className, additionalProps == null ? void 0 : additionalProps.className, className, externalForwardedProps == null ? void 0 : externalForwardedProps.className, externalSlotProps == null ? void 0 : externalSlotProps.className);\n const mergedStyle = _extends({}, internalSlotProps == null ? void 0 : internalSlotProps.style, additionalProps == null ? void 0 : additionalProps.style, externalForwardedProps == null ? void 0 : externalForwardedProps.style, externalSlotProps == null ? void 0 : externalSlotProps.style);\n const props = _extends({}, internalSlotProps, additionalProps, otherPropsWithoutEventHandlers, componentsPropsWithoutEventHandlers);\n if (joinedClasses.length > 0) {\n props.className = joinedClasses;\n }\n if (Object.keys(mergedStyle).length > 0) {\n props.style = mergedStyle;\n }\n return {\n props,\n internalRef: internalSlotProps.ref\n };\n}","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"elementType\", \"externalSlotProps\", \"ownerState\", \"skipResolvingSlotProps\"];\nimport { unstable_useForkRef as useForkRef } from '@mui/utils';\nimport { appendOwnerState } from './appendOwnerState';\nimport { mergeSlotProps } from './mergeSlotProps';\nimport { resolveComponentProps } from './resolveComponentProps';\n/**\n * @ignore - do not document.\n * Builds the props to be passed into the slot of an unstyled component.\n * It merges the internal props of the component with the ones supplied by the user, allowing to customize the behavior.\n * If the slot component is not a host component, it also merges in the `ownerState`.\n *\n * @param parameters.getSlotProps - A function that returns the props to be passed to the slot component.\n */\nexport function useSlotProps(parameters) {\n var _parameters$additiona;\n const {\n elementType,\n externalSlotProps,\n ownerState,\n skipResolvingSlotProps = false\n } = parameters,\n rest = _objectWithoutPropertiesLoose(parameters, _excluded);\n const resolvedComponentsProps = skipResolvingSlotProps ? {} : resolveComponentProps(externalSlotProps, ownerState);\n const {\n props: mergedProps,\n internalRef\n } = mergeSlotProps(_extends({}, rest, {\n externalSlotProps: resolvedComponentsProps\n }));\n const ref = useForkRef(internalRef, resolvedComponentsProps == null ? void 0 : resolvedComponentsProps.ref, (_parameters$additiona = parameters.additionalProps) == null ? void 0 : _parameters$additiona.ref);\n const props = appendOwnerState(elementType, _extends({}, mergedProps, {\n ref\n }), ownerState);\n return props;\n}","import { globalStateClasses } from '@mui/utils/generateUtilityClass';\nconst GLOBAL_CLASS_PREFIX = 'base';\nfunction buildStateClass(state) {\n return `${GLOBAL_CLASS_PREFIX}--${state}`;\n}\nfunction buildSlotClass(componentName, slot) {\n return `${GLOBAL_CLASS_PREFIX}-${componentName}-${slot}`;\n}\nexport function generateUtilityClass(componentName, slot) {\n const globalStateClass = globalStateClasses[slot];\n return globalStateClass ? buildStateClass(globalStateClass) : buildSlotClass(componentName, slot);\n}\nexport function isGlobalState(slot) {\n return globalStateClasses[slot] !== undefined;\n}","import { generateUtilityClass } from '../generateUtilityClass';\nexport function generateUtilityClasses(componentName, slots) {\n const result = {};\n slots.forEach(slot => {\n result[slot] = generateUtilityClass(componentName, slot);\n });\n return result;\n}","'use client';\n\nimport * as React from 'react';\nimport * as ReactDOM from 'react-dom';\nimport PropTypes from 'prop-types';\nimport { exactProp, HTMLElementType, unstable_useEnhancedEffect as useEnhancedEffect, unstable_useForkRef as useForkRef, unstable_setRef as setRef } from '@mui/utils';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nfunction getContainer(container) {\n return typeof container === 'function' ? container() : container;\n}\n\n/**\n * Portals provide a first-class way to render children into a DOM node\n * that exists outside the DOM hierarchy of the parent component.\n *\n * Demos:\n *\n * - [Portal](https://mui.com/base-ui/react-portal/)\n *\n * API:\n *\n * - [Portal API](https://mui.com/base-ui/react-portal/components-api/#portal)\n */\nconst Portal = /*#__PURE__*/React.forwardRef(function Portal(props, forwardedRef) {\n const {\n children,\n container,\n disablePortal = false\n } = props;\n const [mountNode, setMountNode] = React.useState(null);\n // @ts-expect-error TODO upstream fix\n const handleRef = useForkRef( /*#__PURE__*/React.isValidElement(children) ? children.ref : null, forwardedRef);\n useEnhancedEffect(() => {\n if (!disablePortal) {\n setMountNode(getContainer(container) || document.body);\n }\n }, [container, disablePortal]);\n useEnhancedEffect(() => {\n if (mountNode && !disablePortal) {\n setRef(forwardedRef, mountNode);\n return () => {\n setRef(forwardedRef, null);\n };\n }\n return undefined;\n }, [forwardedRef, mountNode, disablePortal]);\n if (disablePortal) {\n if ( /*#__PURE__*/React.isValidElement(children)) {\n const newProps = {\n ref: handleRef\n };\n return /*#__PURE__*/React.cloneElement(children, newProps);\n }\n return /*#__PURE__*/_jsx(React.Fragment, {\n children: children\n });\n }\n return /*#__PURE__*/_jsx(React.Fragment, {\n children: mountNode ? /*#__PURE__*/ReactDOM.createPortal(children, mountNode) : mountNode\n });\n});\nprocess.env.NODE_ENV !== \"production\" ? Portal.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * The children to render into the `container`.\n */\n children: PropTypes.node,\n /**\n * An HTML element or function that returns one.\n * The `container` will have the portal children appended to it.\n *\n * You can also provide a callback, which is called in a React layout effect.\n * This lets you set the container from a ref, and also makes server-side rendering possible.\n *\n * By default, it uses the body of the top-level document object,\n * so it's simply `document.body` most of the time.\n */\n container: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.func]),\n /**\n * The `children` will be under the DOM hierarchy of the parent component.\n * @default false\n */\n disablePortal: PropTypes.bool\n} : void 0;\nif (process.env.NODE_ENV !== 'production') {\n // eslint-disable-next-line\n Portal['propTypes' + ''] = exactProp(Portal.propTypes);\n}\nexport { Portal };","export var top = 'top';\nexport var bottom = 'bottom';\nexport var right = 'right';\nexport var left = 'left';\nexport var auto = 'auto';\nexport var basePlacements = [top, bottom, right, left];\nexport var start = 'start';\nexport var end = 'end';\nexport var clippingParents = 'clippingParents';\nexport var viewport = 'viewport';\nexport var popper = 'popper';\nexport var reference = 'reference';\nexport var variationPlacements = /*#__PURE__*/basePlacements.reduce(function (acc, placement) {\n return acc.concat([placement + \"-\" + start, placement + \"-\" + end]);\n}, []);\nexport var placements = /*#__PURE__*/[].concat(basePlacements, [auto]).reduce(function (acc, placement) {\n return acc.concat([placement, placement + \"-\" + start, placement + \"-\" + end]);\n}, []); // modifiers that need to read the DOM\n\nexport var beforeRead = 'beforeRead';\nexport var read = 'read';\nexport var afterRead = 'afterRead'; // pure-logic modifiers\n\nexport var beforeMain = 'beforeMain';\nexport var main = 'main';\nexport var afterMain = 'afterMain'; // modifier with the purpose to write to the DOM (or write into a framework state)\n\nexport var beforeWrite = 'beforeWrite';\nexport var write = 'write';\nexport var afterWrite = 'afterWrite';\nexport var modifierPhases = [beforeRead, read, afterRead, beforeMain, main, afterMain, beforeWrite, write, afterWrite];","export default function getNodeName(element) {\n return element ? (element.nodeName || '').toLowerCase() : null;\n}","export default function getWindow(node) {\n if (node == null) {\n return window;\n }\n\n if (node.toString() !== '[object Window]') {\n var ownerDocument = node.ownerDocument;\n return ownerDocument ? ownerDocument.defaultView || window : window;\n }\n\n return node;\n}","import getWindow from \"./getWindow.js\";\n\nfunction isElement(node) {\n var OwnElement = getWindow(node).Element;\n return node instanceof OwnElement || node instanceof Element;\n}\n\nfunction isHTMLElement(node) {\n var OwnElement = getWindow(node).HTMLElement;\n return node instanceof OwnElement || node instanceof HTMLElement;\n}\n\nfunction isShadowRoot(node) {\n // IE 11 has no ShadowRoot\n if (typeof ShadowRoot === 'undefined') {\n return false;\n }\n\n var OwnElement = getWindow(node).ShadowRoot;\n return node instanceof OwnElement || node instanceof ShadowRoot;\n}\n\nexport { isElement, isHTMLElement, isShadowRoot };","import getNodeName from \"../dom-utils/getNodeName.js\";\nimport { isHTMLElement } from \"../dom-utils/instanceOf.js\"; // This modifier takes the styles prepared by the `computeStyles` modifier\n// and applies them to the HTMLElements such as popper and arrow\n\nfunction applyStyles(_ref) {\n var state = _ref.state;\n Object.keys(state.elements).forEach(function (name) {\n var style = state.styles[name] || {};\n var attributes = state.attributes[name] || {};\n var element = state.elements[name]; // arrow is optional + virtual elements\n\n if (!isHTMLElement(element) || !getNodeName(element)) {\n return;\n } // Flow doesn't support to extend this property, but it's the most\n // effective way to apply styles to an HTMLElement\n // $FlowFixMe[cannot-write]\n\n\n Object.assign(element.style, style);\n Object.keys(attributes).forEach(function (name) {\n var value = attributes[name];\n\n if (value === false) {\n element.removeAttribute(name);\n } else {\n element.setAttribute(name, value === true ? '' : value);\n }\n });\n });\n}\n\nfunction effect(_ref2) {\n var state = _ref2.state;\n var initialStyles = {\n popper: {\n position: state.options.strategy,\n left: '0',\n top: '0',\n margin: '0'\n },\n arrow: {\n position: 'absolute'\n },\n reference: {}\n };\n Object.assign(state.elements.popper.style, initialStyles.popper);\n state.styles = initialStyles;\n\n if (state.elements.arrow) {\n Object.assign(state.elements.arrow.style, initialStyles.arrow);\n }\n\n return function () {\n Object.keys(state.elements).forEach(function (name) {\n var element = state.elements[name];\n var attributes = state.attributes[name] || {};\n var styleProperties = Object.keys(state.styles.hasOwnProperty(name) ? state.styles[name] : initialStyles[name]); // Set all values to an empty string to unset them\n\n var style = styleProperties.reduce(function (style, property) {\n style[property] = '';\n return style;\n }, {}); // arrow is optional + virtual elements\n\n if (!isHTMLElement(element) || !getNodeName(element)) {\n return;\n }\n\n Object.assign(element.style, style);\n Object.keys(attributes).forEach(function (attribute) {\n element.removeAttribute(attribute);\n });\n });\n };\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'applyStyles',\n enabled: true,\n phase: 'write',\n fn: applyStyles,\n effect: effect,\n requires: ['computeStyles']\n};","import { auto } from \"../enums.js\";\nexport default function getBasePlacement(placement) {\n return placement.split('-')[0];\n}","export var max = Math.max;\nexport var min = Math.min;\nexport var round = Math.round;","export default function getUAString() {\n var uaData = navigator.userAgentData;\n\n if (uaData != null && uaData.brands && Array.isArray(uaData.brands)) {\n return uaData.brands.map(function (item) {\n return item.brand + \"/\" + item.version;\n }).join(' ');\n }\n\n return navigator.userAgent;\n}","import getUAString from \"../utils/userAgent.js\";\nexport default function isLayoutViewport() {\n return !/^((?!chrome|android).)*safari/i.test(getUAString());\n}","import { isElement, isHTMLElement } from \"./instanceOf.js\";\nimport { round } from \"../utils/math.js\";\nimport getWindow from \"./getWindow.js\";\nimport isLayoutViewport from \"./isLayoutViewport.js\";\nexport default function getBoundingClientRect(element, includeScale, isFixedStrategy) {\n if (includeScale === void 0) {\n includeScale = false;\n }\n\n if (isFixedStrategy === void 0) {\n isFixedStrategy = false;\n }\n\n var clientRect = element.getBoundingClientRect();\n var scaleX = 1;\n var scaleY = 1;\n\n if (includeScale && isHTMLElement(element)) {\n scaleX = element.offsetWidth > 0 ? round(clientRect.width) / element.offsetWidth || 1 : 1;\n scaleY = element.offsetHeight > 0 ? round(clientRect.height) / element.offsetHeight || 1 : 1;\n }\n\n var _ref = isElement(element) ? getWindow(element) : window,\n visualViewport = _ref.visualViewport;\n\n var addVisualOffsets = !isLayoutViewport() && isFixedStrategy;\n var x = (clientRect.left + (addVisualOffsets && visualViewport ? visualViewport.offsetLeft : 0)) / scaleX;\n var y = (clientRect.top + (addVisualOffsets && visualViewport ? visualViewport.offsetTop : 0)) / scaleY;\n var width = clientRect.width / scaleX;\n var height = clientRect.height / scaleY;\n return {\n width: width,\n height: height,\n top: y,\n right: x + width,\n bottom: y + height,\n left: x,\n x: x,\n y: y\n };\n}","import getBoundingClientRect from \"./getBoundingClientRect.js\"; // Returns the layout rect of an element relative to its offsetParent. Layout\n// means it doesn't take into account transforms.\n\nexport default function getLayoutRect(element) {\n var clientRect = getBoundingClientRect(element); // Use the clientRect sizes if it's not been transformed.\n // Fixes https://github.com/popperjs/popper-core/issues/1223\n\n var width = element.offsetWidth;\n var height = element.offsetHeight;\n\n if (Math.abs(clientRect.width - width) <= 1) {\n width = clientRect.width;\n }\n\n if (Math.abs(clientRect.height - height) <= 1) {\n height = clientRect.height;\n }\n\n return {\n x: element.offsetLeft,\n y: element.offsetTop,\n width: width,\n height: height\n };\n}","import { isShadowRoot } from \"./instanceOf.js\";\nexport default function contains(parent, child) {\n var rootNode = child.getRootNode && child.getRootNode(); // First, attempt with faster native method\n\n if (parent.contains(child)) {\n return true;\n } // then fallback to custom implementation with Shadow DOM support\n else if (rootNode && isShadowRoot(rootNode)) {\n var next = child;\n\n do {\n if (next && parent.isSameNode(next)) {\n return true;\n } // $FlowFixMe[prop-missing]: need a better way to handle this...\n\n\n next = next.parentNode || next.host;\n } while (next);\n } // Give up, the result is false\n\n\n return false;\n}","import getWindow from \"./getWindow.js\";\nexport default function getComputedStyle(element) {\n return getWindow(element).getComputedStyle(element);\n}","import getNodeName from \"./getNodeName.js\";\nexport default function isTableElement(element) {\n return ['table', 'td', 'th'].indexOf(getNodeName(element)) >= 0;\n}","import { isElement } from \"./instanceOf.js\";\nexport default function getDocumentElement(element) {\n // $FlowFixMe[incompatible-return]: assume body is always available\n return ((isElement(element) ? element.ownerDocument : // $FlowFixMe[prop-missing]\n element.document) || window.document).documentElement;\n}","import getNodeName from \"./getNodeName.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport { isShadowRoot } from \"./instanceOf.js\";\nexport default function getParentNode(element) {\n if (getNodeName(element) === 'html') {\n return element;\n }\n\n return (// this is a quicker (but less type safe) way to save quite some bytes from the bundle\n // $FlowFixMe[incompatible-return]\n // $FlowFixMe[prop-missing]\n element.assignedSlot || // step into the shadow DOM of the parent of a slotted node\n element.parentNode || ( // DOM Element detected\n isShadowRoot(element) ? element.host : null) || // ShadowRoot detected\n // $FlowFixMe[incompatible-call]: HTMLElement is a Node\n getDocumentElement(element) // fallback\n\n );\n}","import getWindow from \"./getWindow.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport getComputedStyle from \"./getComputedStyle.js\";\nimport { isHTMLElement, isShadowRoot } from \"./instanceOf.js\";\nimport isTableElement from \"./isTableElement.js\";\nimport getParentNode from \"./getParentNode.js\";\nimport getUAString from \"../utils/userAgent.js\";\n\nfunction getTrueOffsetParent(element) {\n if (!isHTMLElement(element) || // https://github.com/popperjs/popper-core/issues/837\n getComputedStyle(element).position === 'fixed') {\n return null;\n }\n\n return element.offsetParent;\n} // `.offsetParent` reports `null` for fixed elements, while absolute elements\n// return the containing block\n\n\nfunction getContainingBlock(element) {\n var isFirefox = /firefox/i.test(getUAString());\n var isIE = /Trident/i.test(getUAString());\n\n if (isIE && isHTMLElement(element)) {\n // In IE 9, 10 and 11 fixed elements containing block is always established by the viewport\n var elementCss = getComputedStyle(element);\n\n if (elementCss.position === 'fixed') {\n return null;\n }\n }\n\n var currentNode = getParentNode(element);\n\n if (isShadowRoot(currentNode)) {\n currentNode = currentNode.host;\n }\n\n while (isHTMLElement(currentNode) && ['html', 'body'].indexOf(getNodeName(currentNode)) < 0) {\n var css = getComputedStyle(currentNode); // This is non-exhaustive but covers the most common CSS properties that\n // create a containing block.\n // https://developer.mozilla.org/en-US/docs/Web/CSS/Containing_block#identifying_the_containing_block\n\n if (css.transform !== 'none' || css.perspective !== 'none' || css.contain === 'paint' || ['transform', 'perspective'].indexOf(css.willChange) !== -1 || isFirefox && css.willChange === 'filter' || isFirefox && css.filter && css.filter !== 'none') {\n return currentNode;\n } else {\n currentNode = currentNode.parentNode;\n }\n }\n\n return null;\n} // Gets the closest ancestor positioned element. Handles some edge cases,\n// such as table ancestors and cross browser bugs.\n\n\nexport default function getOffsetParent(element) {\n var window = getWindow(element);\n var offsetParent = getTrueOffsetParent(element);\n\n while (offsetParent && isTableElement(offsetParent) && getComputedStyle(offsetParent).position === 'static') {\n offsetParent = getTrueOffsetParent(offsetParent);\n }\n\n if (offsetParent && (getNodeName(offsetParent) === 'html' || getNodeName(offsetParent) === 'body' && getComputedStyle(offsetParent).position === 'static')) {\n return window;\n }\n\n return offsetParent || getContainingBlock(element) || window;\n}","export default function getMainAxisFromPlacement(placement) {\n return ['top', 'bottom'].indexOf(placement) >= 0 ? 'x' : 'y';\n}","import { max as mathMax, min as mathMin } from \"./math.js\";\nexport function within(min, value, max) {\n return mathMax(min, mathMin(value, max));\n}\nexport function withinMaxClamp(min, value, max) {\n var v = within(min, value, max);\n return v > max ? max : v;\n}","export default function getFreshSideObject() {\n return {\n top: 0,\n right: 0,\n bottom: 0,\n left: 0\n };\n}","import getFreshSideObject from \"./getFreshSideObject.js\";\nexport default function mergePaddingObject(paddingObject) {\n return Object.assign({}, getFreshSideObject(), paddingObject);\n}","export default function expandToHashMap(value, keys) {\n return keys.reduce(function (hashMap, key) {\n hashMap[key] = value;\n return hashMap;\n }, {});\n}","import getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getLayoutRect from \"../dom-utils/getLayoutRect.js\";\nimport contains from \"../dom-utils/contains.js\";\nimport getOffsetParent from \"../dom-utils/getOffsetParent.js\";\nimport getMainAxisFromPlacement from \"../utils/getMainAxisFromPlacement.js\";\nimport { within } from \"../utils/within.js\";\nimport mergePaddingObject from \"../utils/mergePaddingObject.js\";\nimport expandToHashMap from \"../utils/expandToHashMap.js\";\nimport { left, right, basePlacements, top, bottom } from \"../enums.js\"; // eslint-disable-next-line import/no-unused-modules\n\nvar toPaddingObject = function toPaddingObject(padding, state) {\n padding = typeof padding === 'function' ? padding(Object.assign({}, state.rects, {\n placement: state.placement\n })) : padding;\n return mergePaddingObject(typeof padding !== 'number' ? padding : expandToHashMap(padding, basePlacements));\n};\n\nfunction arrow(_ref) {\n var _state$modifiersData$;\n\n var state = _ref.state,\n name = _ref.name,\n options = _ref.options;\n var arrowElement = state.elements.arrow;\n var popperOffsets = state.modifiersData.popperOffsets;\n var basePlacement = getBasePlacement(state.placement);\n var axis = getMainAxisFromPlacement(basePlacement);\n var isVertical = [left, right].indexOf(basePlacement) >= 0;\n var len = isVertical ? 'height' : 'width';\n\n if (!arrowElement || !popperOffsets) {\n return;\n }\n\n var paddingObject = toPaddingObject(options.padding, state);\n var arrowRect = getLayoutRect(arrowElement);\n var minProp = axis === 'y' ? top : left;\n var maxProp = axis === 'y' ? bottom : right;\n var endDiff = state.rects.reference[len] + state.rects.reference[axis] - popperOffsets[axis] - state.rects.popper[len];\n var startDiff = popperOffsets[axis] - state.rects.reference[axis];\n var arrowOffsetParent = getOffsetParent(arrowElement);\n var clientSize = arrowOffsetParent ? axis === 'y' ? arrowOffsetParent.clientHeight || 0 : arrowOffsetParent.clientWidth || 0 : 0;\n var centerToReference = endDiff / 2 - startDiff / 2; // Make sure the arrow doesn't overflow the popper if the center point is\n // outside of the popper bounds\n\n var min = paddingObject[minProp];\n var max = clientSize - arrowRect[len] - paddingObject[maxProp];\n var center = clientSize / 2 - arrowRect[len] / 2 + centerToReference;\n var offset = within(min, center, max); // Prevents breaking syntax highlighting...\n\n var axisProp = axis;\n state.modifiersData[name] = (_state$modifiersData$ = {}, _state$modifiersData$[axisProp] = offset, _state$modifiersData$.centerOffset = offset - center, _state$modifiersData$);\n}\n\nfunction effect(_ref2) {\n var state = _ref2.state,\n options = _ref2.options;\n var _options$element = options.element,\n arrowElement = _options$element === void 0 ? '[data-popper-arrow]' : _options$element;\n\n if (arrowElement == null) {\n return;\n } // CSS selector\n\n\n if (typeof arrowElement === 'string') {\n arrowElement = state.elements.popper.querySelector(arrowElement);\n\n if (!arrowElement) {\n return;\n }\n }\n\n if (!contains(state.elements.popper, arrowElement)) {\n return;\n }\n\n state.elements.arrow = arrowElement;\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'arrow',\n enabled: true,\n phase: 'main',\n fn: arrow,\n effect: effect,\n requires: ['popperOffsets'],\n requiresIfExists: ['preventOverflow']\n};","export default function getVariation(placement) {\n return placement.split('-')[1];\n}","import { top, left, right, bottom, end } from \"../enums.js\";\nimport getOffsetParent from \"../dom-utils/getOffsetParent.js\";\nimport getWindow from \"../dom-utils/getWindow.js\";\nimport getDocumentElement from \"../dom-utils/getDocumentElement.js\";\nimport getComputedStyle from \"../dom-utils/getComputedStyle.js\";\nimport getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getVariation from \"../utils/getVariation.js\";\nimport { round } from \"../utils/math.js\"; // eslint-disable-next-line import/no-unused-modules\n\nvar unsetSides = {\n top: 'auto',\n right: 'auto',\n bottom: 'auto',\n left: 'auto'\n}; // Round the offsets to the nearest suitable subpixel based on the DPR.\n// Zooming can change the DPR, but it seems to report a value that will\n// cleanly divide the values into the appropriate subpixels.\n\nfunction roundOffsetsByDPR(_ref, win) {\n var x = _ref.x,\n y = _ref.y;\n var dpr = win.devicePixelRatio || 1;\n return {\n x: round(x * dpr) / dpr || 0,\n y: round(y * dpr) / dpr || 0\n };\n}\n\nexport function mapToStyles(_ref2) {\n var _Object$assign2;\n\n var popper = _ref2.popper,\n popperRect = _ref2.popperRect,\n placement = _ref2.placement,\n variation = _ref2.variation,\n offsets = _ref2.offsets,\n position = _ref2.position,\n gpuAcceleration = _ref2.gpuAcceleration,\n adaptive = _ref2.adaptive,\n roundOffsets = _ref2.roundOffsets,\n isFixed = _ref2.isFixed;\n var _offsets$x = offsets.x,\n x = _offsets$x === void 0 ? 0 : _offsets$x,\n _offsets$y = offsets.y,\n y = _offsets$y === void 0 ? 0 : _offsets$y;\n\n var _ref3 = typeof roundOffsets === 'function' ? roundOffsets({\n x: x,\n y: y\n }) : {\n x: x,\n y: y\n };\n\n x = _ref3.x;\n y = _ref3.y;\n var hasX = offsets.hasOwnProperty('x');\n var hasY = offsets.hasOwnProperty('y');\n var sideX = left;\n var sideY = top;\n var win = window;\n\n if (adaptive) {\n var offsetParent = getOffsetParent(popper);\n var heightProp = 'clientHeight';\n var widthProp = 'clientWidth';\n\n if (offsetParent === getWindow(popper)) {\n offsetParent = getDocumentElement(popper);\n\n if (getComputedStyle(offsetParent).position !== 'static' && position === 'absolute') {\n heightProp = 'scrollHeight';\n widthProp = 'scrollWidth';\n }\n } // $FlowFixMe[incompatible-cast]: force type refinement, we compare offsetParent with window above, but Flow doesn't detect it\n\n\n offsetParent = offsetParent;\n\n if (placement === top || (placement === left || placement === right) && variation === end) {\n sideY = bottom;\n var offsetY = isFixed && offsetParent === win && win.visualViewport ? win.visualViewport.height : // $FlowFixMe[prop-missing]\n offsetParent[heightProp];\n y -= offsetY - popperRect.height;\n y *= gpuAcceleration ? 1 : -1;\n }\n\n if (placement === left || (placement === top || placement === bottom) && variation === end) {\n sideX = right;\n var offsetX = isFixed && offsetParent === win && win.visualViewport ? win.visualViewport.width : // $FlowFixMe[prop-missing]\n offsetParent[widthProp];\n x -= offsetX - popperRect.width;\n x *= gpuAcceleration ? 1 : -1;\n }\n }\n\n var commonStyles = Object.assign({\n position: position\n }, adaptive && unsetSides);\n\n var _ref4 = roundOffsets === true ? roundOffsetsByDPR({\n x: x,\n y: y\n }, getWindow(popper)) : {\n x: x,\n y: y\n };\n\n x = _ref4.x;\n y = _ref4.y;\n\n if (gpuAcceleration) {\n var _Object$assign;\n\n return Object.assign({}, commonStyles, (_Object$assign = {}, _Object$assign[sideY] = hasY ? '0' : '', _Object$assign[sideX] = hasX ? '0' : '', _Object$assign.transform = (win.devicePixelRatio || 1) <= 1 ? \"translate(\" + x + \"px, \" + y + \"px)\" : \"translate3d(\" + x + \"px, \" + y + \"px, 0)\", _Object$assign));\n }\n\n return Object.assign({}, commonStyles, (_Object$assign2 = {}, _Object$assign2[sideY] = hasY ? y + \"px\" : '', _Object$assign2[sideX] = hasX ? x + \"px\" : '', _Object$assign2.transform = '', _Object$assign2));\n}\n\nfunction computeStyles(_ref5) {\n var state = _ref5.state,\n options = _ref5.options;\n var _options$gpuAccelerat = options.gpuAcceleration,\n gpuAcceleration = _options$gpuAccelerat === void 0 ? true : _options$gpuAccelerat,\n _options$adaptive = options.adaptive,\n adaptive = _options$adaptive === void 0 ? true : _options$adaptive,\n _options$roundOffsets = options.roundOffsets,\n roundOffsets = _options$roundOffsets === void 0 ? true : _options$roundOffsets;\n var commonStyles = {\n placement: getBasePlacement(state.placement),\n variation: getVariation(state.placement),\n popper: state.elements.popper,\n popperRect: state.rects.popper,\n gpuAcceleration: gpuAcceleration,\n isFixed: state.options.strategy === 'fixed'\n };\n\n if (state.modifiersData.popperOffsets != null) {\n state.styles.popper = Object.assign({}, state.styles.popper, mapToStyles(Object.assign({}, commonStyles, {\n offsets: state.modifiersData.popperOffsets,\n position: state.options.strategy,\n adaptive: adaptive,\n roundOffsets: roundOffsets\n })));\n }\n\n if (state.modifiersData.arrow != null) {\n state.styles.arrow = Object.assign({}, state.styles.arrow, mapToStyles(Object.assign({}, commonStyles, {\n offsets: state.modifiersData.arrow,\n position: 'absolute',\n adaptive: false,\n roundOffsets: roundOffsets\n })));\n }\n\n state.attributes.popper = Object.assign({}, state.attributes.popper, {\n 'data-popper-placement': state.placement\n });\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'computeStyles',\n enabled: true,\n phase: 'beforeWrite',\n fn: computeStyles,\n data: {}\n};","import getWindow from \"../dom-utils/getWindow.js\"; // eslint-disable-next-line import/no-unused-modules\n\nvar passive = {\n passive: true\n};\n\nfunction effect(_ref) {\n var state = _ref.state,\n instance = _ref.instance,\n options = _ref.options;\n var _options$scroll = options.scroll,\n scroll = _options$scroll === void 0 ? true : _options$scroll,\n _options$resize = options.resize,\n resize = _options$resize === void 0 ? true : _options$resize;\n var window = getWindow(state.elements.popper);\n var scrollParents = [].concat(state.scrollParents.reference, state.scrollParents.popper);\n\n if (scroll) {\n scrollParents.forEach(function (scrollParent) {\n scrollParent.addEventListener('scroll', instance.update, passive);\n });\n }\n\n if (resize) {\n window.addEventListener('resize', instance.update, passive);\n }\n\n return function () {\n if (scroll) {\n scrollParents.forEach(function (scrollParent) {\n scrollParent.removeEventListener('scroll', instance.update, passive);\n });\n }\n\n if (resize) {\n window.removeEventListener('resize', instance.update, passive);\n }\n };\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'eventListeners',\n enabled: true,\n phase: 'write',\n fn: function fn() {},\n effect: effect,\n data: {}\n};","var hash = {\n left: 'right',\n right: 'left',\n bottom: 'top',\n top: 'bottom'\n};\nexport default function getOppositePlacement(placement) {\n return placement.replace(/left|right|bottom|top/g, function (matched) {\n return hash[matched];\n });\n}","var hash = {\n start: 'end',\n end: 'start'\n};\nexport default function getOppositeVariationPlacement(placement) {\n return placement.replace(/start|end/g, function (matched) {\n return hash[matched];\n });\n}","import getWindow from \"./getWindow.js\";\nexport default function getWindowScroll(node) {\n var win = getWindow(node);\n var scrollLeft = win.pageXOffset;\n var scrollTop = win.pageYOffset;\n return {\n scrollLeft: scrollLeft,\n scrollTop: scrollTop\n };\n}","import getBoundingClientRect from \"./getBoundingClientRect.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport getWindowScroll from \"./getWindowScroll.js\";\nexport default function getWindowScrollBarX(element) {\n // If has a CSS width greater than the viewport, then this will be\n // incorrect for RTL.\n // Popper 1 is broken in this case and never had a bug report so let's assume\n // it's not an issue. I don't think anyone ever specifies width on \n // anyway.\n // Browsers where the left scrollbar doesn't cause an issue report `0` for\n // this (e.g. Edge 2019, IE11, Safari)\n return getBoundingClientRect(getDocumentElement(element)).left + getWindowScroll(element).scrollLeft;\n}","import getWindow from \"./getWindow.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport getWindowScrollBarX from \"./getWindowScrollBarX.js\";\nimport isLayoutViewport from \"./isLayoutViewport.js\";\nexport default function getViewportRect(element, strategy) {\n var win = getWindow(element);\n var html = getDocumentElement(element);\n var visualViewport = win.visualViewport;\n var width = html.clientWidth;\n var height = html.clientHeight;\n var x = 0;\n var y = 0;\n\n if (visualViewport) {\n width = visualViewport.width;\n height = visualViewport.height;\n var layoutViewport = isLayoutViewport();\n\n if (layoutViewport || !layoutViewport && strategy === 'fixed') {\n x = visualViewport.offsetLeft;\n y = visualViewport.offsetTop;\n }\n }\n\n return {\n width: width,\n height: height,\n x: x + getWindowScrollBarX(element),\n y: y\n };\n}","import getDocumentElement from \"./getDocumentElement.js\";\nimport getComputedStyle from \"./getComputedStyle.js\";\nimport getWindowScrollBarX from \"./getWindowScrollBarX.js\";\nimport getWindowScroll from \"./getWindowScroll.js\";\nimport { max } from \"../utils/math.js\"; // Gets the entire size of the scrollable document area, even extending outside\n// of the `` and `` rect bounds if horizontally scrollable\n\nexport default function getDocumentRect(element) {\n var _element$ownerDocumen;\n\n var html = getDocumentElement(element);\n var winScroll = getWindowScroll(element);\n var body = (_element$ownerDocumen = element.ownerDocument) == null ? void 0 : _element$ownerDocumen.body;\n var width = max(html.scrollWidth, html.clientWidth, body ? body.scrollWidth : 0, body ? body.clientWidth : 0);\n var height = max(html.scrollHeight, html.clientHeight, body ? body.scrollHeight : 0, body ? body.clientHeight : 0);\n var x = -winScroll.scrollLeft + getWindowScrollBarX(element);\n var y = -winScroll.scrollTop;\n\n if (getComputedStyle(body || html).direction === 'rtl') {\n x += max(html.clientWidth, body ? body.clientWidth : 0) - width;\n }\n\n return {\n width: width,\n height: height,\n x: x,\n y: y\n };\n}","import getComputedStyle from \"./getComputedStyle.js\";\nexport default function isScrollParent(element) {\n // Firefox wants us to check `-x` and `-y` variations as well\n var _getComputedStyle = getComputedStyle(element),\n overflow = _getComputedStyle.overflow,\n overflowX = _getComputedStyle.overflowX,\n overflowY = _getComputedStyle.overflowY;\n\n return /auto|scroll|overlay|hidden/.test(overflow + overflowY + overflowX);\n}","import getParentNode from \"./getParentNode.js\";\nimport isScrollParent from \"./isScrollParent.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport { isHTMLElement } from \"./instanceOf.js\";\nexport default function getScrollParent(node) {\n if (['html', 'body', '#document'].indexOf(getNodeName(node)) >= 0) {\n // $FlowFixMe[incompatible-return]: assume body is always available\n return node.ownerDocument.body;\n }\n\n if (isHTMLElement(node) && isScrollParent(node)) {\n return node;\n }\n\n return getScrollParent(getParentNode(node));\n}","import getScrollParent from \"./getScrollParent.js\";\nimport getParentNode from \"./getParentNode.js\";\nimport getWindow from \"./getWindow.js\";\nimport isScrollParent from \"./isScrollParent.js\";\n/*\ngiven a DOM element, return the list of all scroll parents, up the list of ancesors\nuntil we get to the top window object. This list is what we attach scroll listeners\nto, because if any of these parent elements scroll, we'll need to re-calculate the\nreference element's position.\n*/\n\nexport default function listScrollParents(element, list) {\n var _element$ownerDocumen;\n\n if (list === void 0) {\n list = [];\n }\n\n var scrollParent = getScrollParent(element);\n var isBody = scrollParent === ((_element$ownerDocumen = element.ownerDocument) == null ? void 0 : _element$ownerDocumen.body);\n var win = getWindow(scrollParent);\n var target = isBody ? [win].concat(win.visualViewport || [], isScrollParent(scrollParent) ? scrollParent : []) : scrollParent;\n var updatedList = list.concat(target);\n return isBody ? updatedList : // $FlowFixMe[incompatible-call]: isBody tells us target will be an HTMLElement here\n updatedList.concat(listScrollParents(getParentNode(target)));\n}","export default function rectToClientRect(rect) {\n return Object.assign({}, rect, {\n left: rect.x,\n top: rect.y,\n right: rect.x + rect.width,\n bottom: rect.y + rect.height\n });\n}","import { viewport } from \"../enums.js\";\nimport getViewportRect from \"./getViewportRect.js\";\nimport getDocumentRect from \"./getDocumentRect.js\";\nimport listScrollParents from \"./listScrollParents.js\";\nimport getOffsetParent from \"./getOffsetParent.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport getComputedStyle from \"./getComputedStyle.js\";\nimport { isElement, isHTMLElement } from \"./instanceOf.js\";\nimport getBoundingClientRect from \"./getBoundingClientRect.js\";\nimport getParentNode from \"./getParentNode.js\";\nimport contains from \"./contains.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport rectToClientRect from \"../utils/rectToClientRect.js\";\nimport { max, min } from \"../utils/math.js\";\n\nfunction getInnerBoundingClientRect(element, strategy) {\n var rect = getBoundingClientRect(element, false, strategy === 'fixed');\n rect.top = rect.top + element.clientTop;\n rect.left = rect.left + element.clientLeft;\n rect.bottom = rect.top + element.clientHeight;\n rect.right = rect.left + element.clientWidth;\n rect.width = element.clientWidth;\n rect.height = element.clientHeight;\n rect.x = rect.left;\n rect.y = rect.top;\n return rect;\n}\n\nfunction getClientRectFromMixedType(element, clippingParent, strategy) {\n return clippingParent === viewport ? rectToClientRect(getViewportRect(element, strategy)) : isElement(clippingParent) ? getInnerBoundingClientRect(clippingParent, strategy) : rectToClientRect(getDocumentRect(getDocumentElement(element)));\n} // A \"clipping parent\" is an overflowable container with the characteristic of\n// clipping (or hiding) overflowing elements with a position different from\n// `initial`\n\n\nfunction getClippingParents(element) {\n var clippingParents = listScrollParents(getParentNode(element));\n var canEscapeClipping = ['absolute', 'fixed'].indexOf(getComputedStyle(element).position) >= 0;\n var clipperElement = canEscapeClipping && isHTMLElement(element) ? getOffsetParent(element) : element;\n\n if (!isElement(clipperElement)) {\n return [];\n } // $FlowFixMe[incompatible-return]: https://github.com/facebook/flow/issues/1414\n\n\n return clippingParents.filter(function (clippingParent) {\n return isElement(clippingParent) && contains(clippingParent, clipperElement) && getNodeName(clippingParent) !== 'body';\n });\n} // Gets the maximum area that the element is visible in due to any number of\n// clipping parents\n\n\nexport default function getClippingRect(element, boundary, rootBoundary, strategy) {\n var mainClippingParents = boundary === 'clippingParents' ? getClippingParents(element) : [].concat(boundary);\n var clippingParents = [].concat(mainClippingParents, [rootBoundary]);\n var firstClippingParent = clippingParents[0];\n var clippingRect = clippingParents.reduce(function (accRect, clippingParent) {\n var rect = getClientRectFromMixedType(element, clippingParent, strategy);\n accRect.top = max(rect.top, accRect.top);\n accRect.right = min(rect.right, accRect.right);\n accRect.bottom = min(rect.bottom, accRect.bottom);\n accRect.left = max(rect.left, accRect.left);\n return accRect;\n }, getClientRectFromMixedType(element, firstClippingParent, strategy));\n clippingRect.width = clippingRect.right - clippingRect.left;\n clippingRect.height = clippingRect.bottom - clippingRect.top;\n clippingRect.x = clippingRect.left;\n clippingRect.y = clippingRect.top;\n return clippingRect;\n}","import getBasePlacement from \"./getBasePlacement.js\";\nimport getVariation from \"./getVariation.js\";\nimport getMainAxisFromPlacement from \"./getMainAxisFromPlacement.js\";\nimport { top, right, bottom, left, start, end } from \"../enums.js\";\nexport default function computeOffsets(_ref) {\n var reference = _ref.reference,\n element = _ref.element,\n placement = _ref.placement;\n var basePlacement = placement ? getBasePlacement(placement) : null;\n var variation = placement ? getVariation(placement) : null;\n var commonX = reference.x + reference.width / 2 - element.width / 2;\n var commonY = reference.y + reference.height / 2 - element.height / 2;\n var offsets;\n\n switch (basePlacement) {\n case top:\n offsets = {\n x: commonX,\n y: reference.y - element.height\n };\n break;\n\n case bottom:\n offsets = {\n x: commonX,\n y: reference.y + reference.height\n };\n break;\n\n case right:\n offsets = {\n x: reference.x + reference.width,\n y: commonY\n };\n break;\n\n case left:\n offsets = {\n x: reference.x - element.width,\n y: commonY\n };\n break;\n\n default:\n offsets = {\n x: reference.x,\n y: reference.y\n };\n }\n\n var mainAxis = basePlacement ? getMainAxisFromPlacement(basePlacement) : null;\n\n if (mainAxis != null) {\n var len = mainAxis === 'y' ? 'height' : 'width';\n\n switch (variation) {\n case start:\n offsets[mainAxis] = offsets[mainAxis] - (reference[len] / 2 - element[len] / 2);\n break;\n\n case end:\n offsets[mainAxis] = offsets[mainAxis] + (reference[len] / 2 - element[len] / 2);\n break;\n\n default:\n }\n }\n\n return offsets;\n}","import getClippingRect from \"../dom-utils/getClippingRect.js\";\nimport getDocumentElement from \"../dom-utils/getDocumentElement.js\";\nimport getBoundingClientRect from \"../dom-utils/getBoundingClientRect.js\";\nimport computeOffsets from \"./computeOffsets.js\";\nimport rectToClientRect from \"./rectToClientRect.js\";\nimport { clippingParents, reference, popper, bottom, top, right, basePlacements, viewport } from \"../enums.js\";\nimport { isElement } from \"../dom-utils/instanceOf.js\";\nimport mergePaddingObject from \"./mergePaddingObject.js\";\nimport expandToHashMap from \"./expandToHashMap.js\"; // eslint-disable-next-line import/no-unused-modules\n\nexport default function detectOverflow(state, options) {\n if (options === void 0) {\n options = {};\n }\n\n var _options = options,\n _options$placement = _options.placement,\n placement = _options$placement === void 0 ? state.placement : _options$placement,\n _options$strategy = _options.strategy,\n strategy = _options$strategy === void 0 ? state.strategy : _options$strategy,\n _options$boundary = _options.boundary,\n boundary = _options$boundary === void 0 ? clippingParents : _options$boundary,\n _options$rootBoundary = _options.rootBoundary,\n rootBoundary = _options$rootBoundary === void 0 ? viewport : _options$rootBoundary,\n _options$elementConte = _options.elementContext,\n elementContext = _options$elementConte === void 0 ? popper : _options$elementConte,\n _options$altBoundary = _options.altBoundary,\n altBoundary = _options$altBoundary === void 0 ? false : _options$altBoundary,\n _options$padding = _options.padding,\n padding = _options$padding === void 0 ? 0 : _options$padding;\n var paddingObject = mergePaddingObject(typeof padding !== 'number' ? padding : expandToHashMap(padding, basePlacements));\n var altContext = elementContext === popper ? reference : popper;\n var popperRect = state.rects.popper;\n var element = state.elements[altBoundary ? altContext : elementContext];\n var clippingClientRect = getClippingRect(isElement(element) ? element : element.contextElement || getDocumentElement(state.elements.popper), boundary, rootBoundary, strategy);\n var referenceClientRect = getBoundingClientRect(state.elements.reference);\n var popperOffsets = computeOffsets({\n reference: referenceClientRect,\n element: popperRect,\n strategy: 'absolute',\n placement: placement\n });\n var popperClientRect = rectToClientRect(Object.assign({}, popperRect, popperOffsets));\n var elementClientRect = elementContext === popper ? popperClientRect : referenceClientRect; // positive = overflowing the clipping rect\n // 0 or negative = within the clipping rect\n\n var overflowOffsets = {\n top: clippingClientRect.top - elementClientRect.top + paddingObject.top,\n bottom: elementClientRect.bottom - clippingClientRect.bottom + paddingObject.bottom,\n left: clippingClientRect.left - elementClientRect.left + paddingObject.left,\n right: elementClientRect.right - clippingClientRect.right + paddingObject.right\n };\n var offsetData = state.modifiersData.offset; // Offsets can be applied only to the popper element\n\n if (elementContext === popper && offsetData) {\n var offset = offsetData[placement];\n Object.keys(overflowOffsets).forEach(function (key) {\n var multiply = [right, bottom].indexOf(key) >= 0 ? 1 : -1;\n var axis = [top, bottom].indexOf(key) >= 0 ? 'y' : 'x';\n overflowOffsets[key] += offset[axis] * multiply;\n });\n }\n\n return overflowOffsets;\n}","import getVariation from \"./getVariation.js\";\nimport { variationPlacements, basePlacements, placements as allPlacements } from \"../enums.js\";\nimport detectOverflow from \"./detectOverflow.js\";\nimport getBasePlacement from \"./getBasePlacement.js\";\nexport default function computeAutoPlacement(state, options) {\n if (options === void 0) {\n options = {};\n }\n\n var _options = options,\n placement = _options.placement,\n boundary = _options.boundary,\n rootBoundary = _options.rootBoundary,\n padding = _options.padding,\n flipVariations = _options.flipVariations,\n _options$allowedAutoP = _options.allowedAutoPlacements,\n allowedAutoPlacements = _options$allowedAutoP === void 0 ? allPlacements : _options$allowedAutoP;\n var variation = getVariation(placement);\n var placements = variation ? flipVariations ? variationPlacements : variationPlacements.filter(function (placement) {\n return getVariation(placement) === variation;\n }) : basePlacements;\n var allowedPlacements = placements.filter(function (placement) {\n return allowedAutoPlacements.indexOf(placement) >= 0;\n });\n\n if (allowedPlacements.length === 0) {\n allowedPlacements = placements;\n } // $FlowFixMe[incompatible-type]: Flow seems to have problems with two array unions...\n\n\n var overflows = allowedPlacements.reduce(function (acc, placement) {\n acc[placement] = detectOverflow(state, {\n placement: placement,\n boundary: boundary,\n rootBoundary: rootBoundary,\n padding: padding\n })[getBasePlacement(placement)];\n return acc;\n }, {});\n return Object.keys(overflows).sort(function (a, b) {\n return overflows[a] - overflows[b];\n });\n}","import getOppositePlacement from \"../utils/getOppositePlacement.js\";\nimport getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getOppositeVariationPlacement from \"../utils/getOppositeVariationPlacement.js\";\nimport detectOverflow from \"../utils/detectOverflow.js\";\nimport computeAutoPlacement from \"../utils/computeAutoPlacement.js\";\nimport { bottom, top, start, right, left, auto } from \"../enums.js\";\nimport getVariation from \"../utils/getVariation.js\"; // eslint-disable-next-line import/no-unused-modules\n\nfunction getExpandedFallbackPlacements(placement) {\n if (getBasePlacement(placement) === auto) {\n return [];\n }\n\n var oppositePlacement = getOppositePlacement(placement);\n return [getOppositeVariationPlacement(placement), oppositePlacement, getOppositeVariationPlacement(oppositePlacement)];\n}\n\nfunction flip(_ref) {\n var state = _ref.state,\n options = _ref.options,\n name = _ref.name;\n\n if (state.modifiersData[name]._skip) {\n return;\n }\n\n var _options$mainAxis = options.mainAxis,\n checkMainAxis = _options$mainAxis === void 0 ? true : _options$mainAxis,\n _options$altAxis = options.altAxis,\n checkAltAxis = _options$altAxis === void 0 ? true : _options$altAxis,\n specifiedFallbackPlacements = options.fallbackPlacements,\n padding = options.padding,\n boundary = options.boundary,\n rootBoundary = options.rootBoundary,\n altBoundary = options.altBoundary,\n _options$flipVariatio = options.flipVariations,\n flipVariations = _options$flipVariatio === void 0 ? true : _options$flipVariatio,\n allowedAutoPlacements = options.allowedAutoPlacements;\n var preferredPlacement = state.options.placement;\n var basePlacement = getBasePlacement(preferredPlacement);\n var isBasePlacement = basePlacement === preferredPlacement;\n var fallbackPlacements = specifiedFallbackPlacements || (isBasePlacement || !flipVariations ? [getOppositePlacement(preferredPlacement)] : getExpandedFallbackPlacements(preferredPlacement));\n var placements = [preferredPlacement].concat(fallbackPlacements).reduce(function (acc, placement) {\n return acc.concat(getBasePlacement(placement) === auto ? computeAutoPlacement(state, {\n placement: placement,\n boundary: boundary,\n rootBoundary: rootBoundary,\n padding: padding,\n flipVariations: flipVariations,\n allowedAutoPlacements: allowedAutoPlacements\n }) : placement);\n }, []);\n var referenceRect = state.rects.reference;\n var popperRect = state.rects.popper;\n var checksMap = new Map();\n var makeFallbackChecks = true;\n var firstFittingPlacement = placements[0];\n\n for (var i = 0; i < placements.length; i++) {\n var placement = placements[i];\n\n var _basePlacement = getBasePlacement(placement);\n\n var isStartVariation = getVariation(placement) === start;\n var isVertical = [top, bottom].indexOf(_basePlacement) >= 0;\n var len = isVertical ? 'width' : 'height';\n var overflow = detectOverflow(state, {\n placement: placement,\n boundary: boundary,\n rootBoundary: rootBoundary,\n altBoundary: altBoundary,\n padding: padding\n });\n var mainVariationSide = isVertical ? isStartVariation ? right : left : isStartVariation ? bottom : top;\n\n if (referenceRect[len] > popperRect[len]) {\n mainVariationSide = getOppositePlacement(mainVariationSide);\n }\n\n var altVariationSide = getOppositePlacement(mainVariationSide);\n var checks = [];\n\n if (checkMainAxis) {\n checks.push(overflow[_basePlacement] <= 0);\n }\n\n if (checkAltAxis) {\n checks.push(overflow[mainVariationSide] <= 0, overflow[altVariationSide] <= 0);\n }\n\n if (checks.every(function (check) {\n return check;\n })) {\n firstFittingPlacement = placement;\n makeFallbackChecks = false;\n break;\n }\n\n checksMap.set(placement, checks);\n }\n\n if (makeFallbackChecks) {\n // `2` may be desired in some cases – research later\n var numberOfChecks = flipVariations ? 3 : 1;\n\n var _loop = function _loop(_i) {\n var fittingPlacement = placements.find(function (placement) {\n var checks = checksMap.get(placement);\n\n if (checks) {\n return checks.slice(0, _i).every(function (check) {\n return check;\n });\n }\n });\n\n if (fittingPlacement) {\n firstFittingPlacement = fittingPlacement;\n return \"break\";\n }\n };\n\n for (var _i = numberOfChecks; _i > 0; _i--) {\n var _ret = _loop(_i);\n\n if (_ret === \"break\") break;\n }\n }\n\n if (state.placement !== firstFittingPlacement) {\n state.modifiersData[name]._skip = true;\n state.placement = firstFittingPlacement;\n state.reset = true;\n }\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'flip',\n enabled: true,\n phase: 'main',\n fn: flip,\n requiresIfExists: ['offset'],\n data: {\n _skip: false\n }\n};","import { top, bottom, left, right } from \"../enums.js\";\nimport detectOverflow from \"../utils/detectOverflow.js\";\n\nfunction getSideOffsets(overflow, rect, preventedOffsets) {\n if (preventedOffsets === void 0) {\n preventedOffsets = {\n x: 0,\n y: 0\n };\n }\n\n return {\n top: overflow.top - rect.height - preventedOffsets.y,\n right: overflow.right - rect.width + preventedOffsets.x,\n bottom: overflow.bottom - rect.height + preventedOffsets.y,\n left: overflow.left - rect.width - preventedOffsets.x\n };\n}\n\nfunction isAnySideFullyClipped(overflow) {\n return [top, right, bottom, left].some(function (side) {\n return overflow[side] >= 0;\n });\n}\n\nfunction hide(_ref) {\n var state = _ref.state,\n name = _ref.name;\n var referenceRect = state.rects.reference;\n var popperRect = state.rects.popper;\n var preventedOffsets = state.modifiersData.preventOverflow;\n var referenceOverflow = detectOverflow(state, {\n elementContext: 'reference'\n });\n var popperAltOverflow = detectOverflow(state, {\n altBoundary: true\n });\n var referenceClippingOffsets = getSideOffsets(referenceOverflow, referenceRect);\n var popperEscapeOffsets = getSideOffsets(popperAltOverflow, popperRect, preventedOffsets);\n var isReferenceHidden = isAnySideFullyClipped(referenceClippingOffsets);\n var hasPopperEscaped = isAnySideFullyClipped(popperEscapeOffsets);\n state.modifiersData[name] = {\n referenceClippingOffsets: referenceClippingOffsets,\n popperEscapeOffsets: popperEscapeOffsets,\n isReferenceHidden: isReferenceHidden,\n hasPopperEscaped: hasPopperEscaped\n };\n state.attributes.popper = Object.assign({}, state.attributes.popper, {\n 'data-popper-reference-hidden': isReferenceHidden,\n 'data-popper-escaped': hasPopperEscaped\n });\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'hide',\n enabled: true,\n phase: 'main',\n requiresIfExists: ['preventOverflow'],\n fn: hide\n};","import getBasePlacement from \"../utils/getBasePlacement.js\";\nimport { top, left, right, placements } from \"../enums.js\"; // eslint-disable-next-line import/no-unused-modules\n\nexport function distanceAndSkiddingToXY(placement, rects, offset) {\n var basePlacement = getBasePlacement(placement);\n var invertDistance = [left, top].indexOf(basePlacement) >= 0 ? -1 : 1;\n\n var _ref = typeof offset === 'function' ? offset(Object.assign({}, rects, {\n placement: placement\n })) : offset,\n skidding = _ref[0],\n distance = _ref[1];\n\n skidding = skidding || 0;\n distance = (distance || 0) * invertDistance;\n return [left, right].indexOf(basePlacement) >= 0 ? {\n x: distance,\n y: skidding\n } : {\n x: skidding,\n y: distance\n };\n}\n\nfunction offset(_ref2) {\n var state = _ref2.state,\n options = _ref2.options,\n name = _ref2.name;\n var _options$offset = options.offset,\n offset = _options$offset === void 0 ? [0, 0] : _options$offset;\n var data = placements.reduce(function (acc, placement) {\n acc[placement] = distanceAndSkiddingToXY(placement, state.rects, offset);\n return acc;\n }, {});\n var _data$state$placement = data[state.placement],\n x = _data$state$placement.x,\n y = _data$state$placement.y;\n\n if (state.modifiersData.popperOffsets != null) {\n state.modifiersData.popperOffsets.x += x;\n state.modifiersData.popperOffsets.y += y;\n }\n\n state.modifiersData[name] = data;\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'offset',\n enabled: true,\n phase: 'main',\n requires: ['popperOffsets'],\n fn: offset\n};","import computeOffsets from \"../utils/computeOffsets.js\";\n\nfunction popperOffsets(_ref) {\n var state = _ref.state,\n name = _ref.name;\n // Offsets are the actual position the popper needs to have to be\n // properly positioned near its reference element\n // This is the most basic placement, and will be adjusted by\n // the modifiers in the next step\n state.modifiersData[name] = computeOffsets({\n reference: state.rects.reference,\n element: state.rects.popper,\n strategy: 'absolute',\n placement: state.placement\n });\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'popperOffsets',\n enabled: true,\n phase: 'read',\n fn: popperOffsets,\n data: {}\n};","export default function getAltAxis(axis) {\n return axis === 'x' ? 'y' : 'x';\n}","import { top, left, right, bottom, start } from \"../enums.js\";\nimport getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getMainAxisFromPlacement from \"../utils/getMainAxisFromPlacement.js\";\nimport getAltAxis from \"../utils/getAltAxis.js\";\nimport { within, withinMaxClamp } from \"../utils/within.js\";\nimport getLayoutRect from \"../dom-utils/getLayoutRect.js\";\nimport getOffsetParent from \"../dom-utils/getOffsetParent.js\";\nimport detectOverflow from \"../utils/detectOverflow.js\";\nimport getVariation from \"../utils/getVariation.js\";\nimport getFreshSideObject from \"../utils/getFreshSideObject.js\";\nimport { min as mathMin, max as mathMax } from \"../utils/math.js\";\n\nfunction preventOverflow(_ref) {\n var state = _ref.state,\n options = _ref.options,\n name = _ref.name;\n var _options$mainAxis = options.mainAxis,\n checkMainAxis = _options$mainAxis === void 0 ? true : _options$mainAxis,\n _options$altAxis = options.altAxis,\n checkAltAxis = _options$altAxis === void 0 ? false : _options$altAxis,\n boundary = options.boundary,\n rootBoundary = options.rootBoundary,\n altBoundary = options.altBoundary,\n padding = options.padding,\n _options$tether = options.tether,\n tether = _options$tether === void 0 ? true : _options$tether,\n _options$tetherOffset = options.tetherOffset,\n tetherOffset = _options$tetherOffset === void 0 ? 0 : _options$tetherOffset;\n var overflow = detectOverflow(state, {\n boundary: boundary,\n rootBoundary: rootBoundary,\n padding: padding,\n altBoundary: altBoundary\n });\n var basePlacement = getBasePlacement(state.placement);\n var variation = getVariation(state.placement);\n var isBasePlacement = !variation;\n var mainAxis = getMainAxisFromPlacement(basePlacement);\n var altAxis = getAltAxis(mainAxis);\n var popperOffsets = state.modifiersData.popperOffsets;\n var referenceRect = state.rects.reference;\n var popperRect = state.rects.popper;\n var tetherOffsetValue = typeof tetherOffset === 'function' ? tetherOffset(Object.assign({}, state.rects, {\n placement: state.placement\n })) : tetherOffset;\n var normalizedTetherOffsetValue = typeof tetherOffsetValue === 'number' ? {\n mainAxis: tetherOffsetValue,\n altAxis: tetherOffsetValue\n } : Object.assign({\n mainAxis: 0,\n altAxis: 0\n }, tetherOffsetValue);\n var offsetModifierState = state.modifiersData.offset ? state.modifiersData.offset[state.placement] : null;\n var data = {\n x: 0,\n y: 0\n };\n\n if (!popperOffsets) {\n return;\n }\n\n if (checkMainAxis) {\n var _offsetModifierState$;\n\n var mainSide = mainAxis === 'y' ? top : left;\n var altSide = mainAxis === 'y' ? bottom : right;\n var len = mainAxis === 'y' ? 'height' : 'width';\n var offset = popperOffsets[mainAxis];\n var min = offset + overflow[mainSide];\n var max = offset - overflow[altSide];\n var additive = tether ? -popperRect[len] / 2 : 0;\n var minLen = variation === start ? referenceRect[len] : popperRect[len];\n var maxLen = variation === start ? -popperRect[len] : -referenceRect[len]; // We need to include the arrow in the calculation so the arrow doesn't go\n // outside the reference bounds\n\n var arrowElement = state.elements.arrow;\n var arrowRect = tether && arrowElement ? getLayoutRect(arrowElement) : {\n width: 0,\n height: 0\n };\n var arrowPaddingObject = state.modifiersData['arrow#persistent'] ? state.modifiersData['arrow#persistent'].padding : getFreshSideObject();\n var arrowPaddingMin = arrowPaddingObject[mainSide];\n var arrowPaddingMax = arrowPaddingObject[altSide]; // If the reference length is smaller than the arrow length, we don't want\n // to include its full size in the calculation. If the reference is small\n // and near the edge of a boundary, the popper can overflow even if the\n // reference is not overflowing as well (e.g. virtual elements with no\n // width or height)\n\n var arrowLen = within(0, referenceRect[len], arrowRect[len]);\n var minOffset = isBasePlacement ? referenceRect[len] / 2 - additive - arrowLen - arrowPaddingMin - normalizedTetherOffsetValue.mainAxis : minLen - arrowLen - arrowPaddingMin - normalizedTetherOffsetValue.mainAxis;\n var maxOffset = isBasePlacement ? -referenceRect[len] / 2 + additive + arrowLen + arrowPaddingMax + normalizedTetherOffsetValue.mainAxis : maxLen + arrowLen + arrowPaddingMax + normalizedTetherOffsetValue.mainAxis;\n var arrowOffsetParent = state.elements.arrow && getOffsetParent(state.elements.arrow);\n var clientOffset = arrowOffsetParent ? mainAxis === 'y' ? arrowOffsetParent.clientTop || 0 : arrowOffsetParent.clientLeft || 0 : 0;\n var offsetModifierValue = (_offsetModifierState$ = offsetModifierState == null ? void 0 : offsetModifierState[mainAxis]) != null ? _offsetModifierState$ : 0;\n var tetherMin = offset + minOffset - offsetModifierValue - clientOffset;\n var tetherMax = offset + maxOffset - offsetModifierValue;\n var preventedOffset = within(tether ? mathMin(min, tetherMin) : min, offset, tether ? mathMax(max, tetherMax) : max);\n popperOffsets[mainAxis] = preventedOffset;\n data[mainAxis] = preventedOffset - offset;\n }\n\n if (checkAltAxis) {\n var _offsetModifierState$2;\n\n var _mainSide = mainAxis === 'x' ? top : left;\n\n var _altSide = mainAxis === 'x' ? bottom : right;\n\n var _offset = popperOffsets[altAxis];\n\n var _len = altAxis === 'y' ? 'height' : 'width';\n\n var _min = _offset + overflow[_mainSide];\n\n var _max = _offset - overflow[_altSide];\n\n var isOriginSide = [top, left].indexOf(basePlacement) !== -1;\n\n var _offsetModifierValue = (_offsetModifierState$2 = offsetModifierState == null ? void 0 : offsetModifierState[altAxis]) != null ? _offsetModifierState$2 : 0;\n\n var _tetherMin = isOriginSide ? _min : _offset - referenceRect[_len] - popperRect[_len] - _offsetModifierValue + normalizedTetherOffsetValue.altAxis;\n\n var _tetherMax = isOriginSide ? _offset + referenceRect[_len] + popperRect[_len] - _offsetModifierValue - normalizedTetherOffsetValue.altAxis : _max;\n\n var _preventedOffset = tether && isOriginSide ? withinMaxClamp(_tetherMin, _offset, _tetherMax) : within(tether ? _tetherMin : _min, _offset, tether ? _tetherMax : _max);\n\n popperOffsets[altAxis] = _preventedOffset;\n data[altAxis] = _preventedOffset - _offset;\n }\n\n state.modifiersData[name] = data;\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'preventOverflow',\n enabled: true,\n phase: 'main',\n fn: preventOverflow,\n requiresIfExists: ['offset']\n};","export default function getHTMLElementScroll(element) {\n return {\n scrollLeft: element.scrollLeft,\n scrollTop: element.scrollTop\n };\n}","import getWindowScroll from \"./getWindowScroll.js\";\nimport getWindow from \"./getWindow.js\";\nimport { isHTMLElement } from \"./instanceOf.js\";\nimport getHTMLElementScroll from \"./getHTMLElementScroll.js\";\nexport default function getNodeScroll(node) {\n if (node === getWindow(node) || !isHTMLElement(node)) {\n return getWindowScroll(node);\n } else {\n return getHTMLElementScroll(node);\n }\n}","import getBoundingClientRect from \"./getBoundingClientRect.js\";\nimport getNodeScroll from \"./getNodeScroll.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport { isHTMLElement } from \"./instanceOf.js\";\nimport getWindowScrollBarX from \"./getWindowScrollBarX.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport isScrollParent from \"./isScrollParent.js\";\nimport { round } from \"../utils/math.js\";\n\nfunction isElementScaled(element) {\n var rect = element.getBoundingClientRect();\n var scaleX = round(rect.width) / element.offsetWidth || 1;\n var scaleY = round(rect.height) / element.offsetHeight || 1;\n return scaleX !== 1 || scaleY !== 1;\n} // Returns the composite rect of an element relative to its offsetParent.\n// Composite means it takes into account transforms as well as layout.\n\n\nexport default function getCompositeRect(elementOrVirtualElement, offsetParent, isFixed) {\n if (isFixed === void 0) {\n isFixed = false;\n }\n\n var isOffsetParentAnElement = isHTMLElement(offsetParent);\n var offsetParentIsScaled = isHTMLElement(offsetParent) && isElementScaled(offsetParent);\n var documentElement = getDocumentElement(offsetParent);\n var rect = getBoundingClientRect(elementOrVirtualElement, offsetParentIsScaled, isFixed);\n var scroll = {\n scrollLeft: 0,\n scrollTop: 0\n };\n var offsets = {\n x: 0,\n y: 0\n };\n\n if (isOffsetParentAnElement || !isOffsetParentAnElement && !isFixed) {\n if (getNodeName(offsetParent) !== 'body' || // https://github.com/popperjs/popper-core/issues/1078\n isScrollParent(documentElement)) {\n scroll = getNodeScroll(offsetParent);\n }\n\n if (isHTMLElement(offsetParent)) {\n offsets = getBoundingClientRect(offsetParent, true);\n offsets.x += offsetParent.clientLeft;\n offsets.y += offsetParent.clientTop;\n } else if (documentElement) {\n offsets.x = getWindowScrollBarX(documentElement);\n }\n }\n\n return {\n x: rect.left + scroll.scrollLeft - offsets.x,\n y: rect.top + scroll.scrollTop - offsets.y,\n width: rect.width,\n height: rect.height\n };\n}","import { modifierPhases } from \"../enums.js\"; // source: https://stackoverflow.com/questions/49875255\n\nfunction order(modifiers) {\n var map = new Map();\n var visited = new Set();\n var result = [];\n modifiers.forEach(function (modifier) {\n map.set(modifier.name, modifier);\n }); // On visiting object, check for its dependencies and visit them recursively\n\n function sort(modifier) {\n visited.add(modifier.name);\n var requires = [].concat(modifier.requires || [], modifier.requiresIfExists || []);\n requires.forEach(function (dep) {\n if (!visited.has(dep)) {\n var depModifier = map.get(dep);\n\n if (depModifier) {\n sort(depModifier);\n }\n }\n });\n result.push(modifier);\n }\n\n modifiers.forEach(function (modifier) {\n if (!visited.has(modifier.name)) {\n // check for visited object\n sort(modifier);\n }\n });\n return result;\n}\n\nexport default function orderModifiers(modifiers) {\n // order based on dependencies\n var orderedModifiers = order(modifiers); // order based on phase\n\n return modifierPhases.reduce(function (acc, phase) {\n return acc.concat(orderedModifiers.filter(function (modifier) {\n return modifier.phase === phase;\n }));\n }, []);\n}","export default function debounce(fn) {\n var pending;\n return function () {\n if (!pending) {\n pending = new Promise(function (resolve) {\n Promise.resolve().then(function () {\n pending = undefined;\n resolve(fn());\n });\n });\n }\n\n return pending;\n };\n}","export default function mergeByName(modifiers) {\n var merged = modifiers.reduce(function (merged, current) {\n var existing = merged[current.name];\n merged[current.name] = existing ? Object.assign({}, existing, current, {\n options: Object.assign({}, existing.options, current.options),\n data: Object.assign({}, existing.data, current.data)\n }) : current;\n return merged;\n }, {}); // IE11 does not support Object.values\n\n return Object.keys(merged).map(function (key) {\n return merged[key];\n });\n}","import getCompositeRect from \"./dom-utils/getCompositeRect.js\";\nimport getLayoutRect from \"./dom-utils/getLayoutRect.js\";\nimport listScrollParents from \"./dom-utils/listScrollParents.js\";\nimport getOffsetParent from \"./dom-utils/getOffsetParent.js\";\nimport orderModifiers from \"./utils/orderModifiers.js\";\nimport debounce from \"./utils/debounce.js\";\nimport mergeByName from \"./utils/mergeByName.js\";\nimport detectOverflow from \"./utils/detectOverflow.js\";\nimport { isElement } from \"./dom-utils/instanceOf.js\";\nvar DEFAULT_OPTIONS = {\n placement: 'bottom',\n modifiers: [],\n strategy: 'absolute'\n};\n\nfunction areValidElements() {\n for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {\n args[_key] = arguments[_key];\n }\n\n return !args.some(function (element) {\n return !(element && typeof element.getBoundingClientRect === 'function');\n });\n}\n\nexport function popperGenerator(generatorOptions) {\n if (generatorOptions === void 0) {\n generatorOptions = {};\n }\n\n var _generatorOptions = generatorOptions,\n _generatorOptions$def = _generatorOptions.defaultModifiers,\n defaultModifiers = _generatorOptions$def === void 0 ? [] : _generatorOptions$def,\n _generatorOptions$def2 = _generatorOptions.defaultOptions,\n defaultOptions = _generatorOptions$def2 === void 0 ? DEFAULT_OPTIONS : _generatorOptions$def2;\n return function createPopper(reference, popper, options) {\n if (options === void 0) {\n options = defaultOptions;\n }\n\n var state = {\n placement: 'bottom',\n orderedModifiers: [],\n options: Object.assign({}, DEFAULT_OPTIONS, defaultOptions),\n modifiersData: {},\n elements: {\n reference: reference,\n popper: popper\n },\n attributes: {},\n styles: {}\n };\n var effectCleanupFns = [];\n var isDestroyed = false;\n var instance = {\n state: state,\n setOptions: function setOptions(setOptionsAction) {\n var options = typeof setOptionsAction === 'function' ? setOptionsAction(state.options) : setOptionsAction;\n cleanupModifierEffects();\n state.options = Object.assign({}, defaultOptions, state.options, options);\n state.scrollParents = {\n reference: isElement(reference) ? listScrollParents(reference) : reference.contextElement ? listScrollParents(reference.contextElement) : [],\n popper: listScrollParents(popper)\n }; // Orders the modifiers based on their dependencies and `phase`\n // properties\n\n var orderedModifiers = orderModifiers(mergeByName([].concat(defaultModifiers, state.options.modifiers))); // Strip out disabled modifiers\n\n state.orderedModifiers = orderedModifiers.filter(function (m) {\n return m.enabled;\n });\n runModifierEffects();\n return instance.update();\n },\n // Sync update – it will always be executed, even if not necessary. This\n // is useful for low frequency updates where sync behavior simplifies the\n // logic.\n // For high frequency updates (e.g. `resize` and `scroll` events), always\n // prefer the async Popper#update method\n forceUpdate: function forceUpdate() {\n if (isDestroyed) {\n return;\n }\n\n var _state$elements = state.elements,\n reference = _state$elements.reference,\n popper = _state$elements.popper; // Don't proceed if `reference` or `popper` are not valid elements\n // anymore\n\n if (!areValidElements(reference, popper)) {\n return;\n } // Store the reference and popper rects to be read by modifiers\n\n\n state.rects = {\n reference: getCompositeRect(reference, getOffsetParent(popper), state.options.strategy === 'fixed'),\n popper: getLayoutRect(popper)\n }; // Modifiers have the ability to reset the current update cycle. The\n // most common use case for this is the `flip` modifier changing the\n // placement, which then needs to re-run all the modifiers, because the\n // logic was previously ran for the previous placement and is therefore\n // stale/incorrect\n\n state.reset = false;\n state.placement = state.options.placement; // On each update cycle, the `modifiersData` property for each modifier\n // is filled with the initial data specified by the modifier. This means\n // it doesn't persist and is fresh on each update.\n // To ensure persistent data, use `${name}#persistent`\n\n state.orderedModifiers.forEach(function (modifier) {\n return state.modifiersData[modifier.name] = Object.assign({}, modifier.data);\n });\n\n for (var index = 0; index < state.orderedModifiers.length; index++) {\n if (state.reset === true) {\n state.reset = false;\n index = -1;\n continue;\n }\n\n var _state$orderedModifie = state.orderedModifiers[index],\n fn = _state$orderedModifie.fn,\n _state$orderedModifie2 = _state$orderedModifie.options,\n _options = _state$orderedModifie2 === void 0 ? {} : _state$orderedModifie2,\n name = _state$orderedModifie.name;\n\n if (typeof fn === 'function') {\n state = fn({\n state: state,\n options: _options,\n name: name,\n instance: instance\n }) || state;\n }\n }\n },\n // Async and optimistically optimized update – it will not be executed if\n // not necessary (debounced to run at most once-per-tick)\n update: debounce(function () {\n return new Promise(function (resolve) {\n instance.forceUpdate();\n resolve(state);\n });\n }),\n destroy: function destroy() {\n cleanupModifierEffects();\n isDestroyed = true;\n }\n };\n\n if (!areValidElements(reference, popper)) {\n return instance;\n }\n\n instance.setOptions(options).then(function (state) {\n if (!isDestroyed && options.onFirstUpdate) {\n options.onFirstUpdate(state);\n }\n }); // Modifiers have the ability to execute arbitrary code before the first\n // update cycle runs. They will be executed in the same order as the update\n // cycle. This is useful when a modifier adds some persistent data that\n // other modifiers need to use, but the modifier is run after the dependent\n // one.\n\n function runModifierEffects() {\n state.orderedModifiers.forEach(function (_ref) {\n var name = _ref.name,\n _ref$options = _ref.options,\n options = _ref$options === void 0 ? {} : _ref$options,\n effect = _ref.effect;\n\n if (typeof effect === 'function') {\n var cleanupFn = effect({\n state: state,\n name: name,\n instance: instance,\n options: options\n });\n\n var noopFn = function noopFn() {};\n\n effectCleanupFns.push(cleanupFn || noopFn);\n }\n });\n }\n\n function cleanupModifierEffects() {\n effectCleanupFns.forEach(function (fn) {\n return fn();\n });\n effectCleanupFns = [];\n }\n\n return instance;\n };\n}\nexport var createPopper = /*#__PURE__*/popperGenerator(); // eslint-disable-next-line import/no-unused-modules\n\nexport { detectOverflow };","import { popperGenerator, detectOverflow } from \"./createPopper.js\";\nimport eventListeners from \"./modifiers/eventListeners.js\";\nimport popperOffsets from \"./modifiers/popperOffsets.js\";\nimport computeStyles from \"./modifiers/computeStyles.js\";\nimport applyStyles from \"./modifiers/applyStyles.js\";\nimport offset from \"./modifiers/offset.js\";\nimport flip from \"./modifiers/flip.js\";\nimport preventOverflow from \"./modifiers/preventOverflow.js\";\nimport arrow from \"./modifiers/arrow.js\";\nimport hide from \"./modifiers/hide.js\";\nvar defaultModifiers = [eventListeners, popperOffsets, computeStyles, applyStyles, offset, flip, preventOverflow, arrow, hide];\nvar createPopper = /*#__PURE__*/popperGenerator({\n defaultModifiers: defaultModifiers\n}); // eslint-disable-next-line import/no-unused-modules\n\nexport { createPopper, popperGenerator, defaultModifiers, detectOverflow }; // eslint-disable-next-line import/no-unused-modules\n\nexport { createPopper as createPopperLite } from \"./popper-lite.js\"; // eslint-disable-next-line import/no-unused-modules\n\nexport * from \"./modifiers/index.js\";","import { generateUtilityClass } from '../generateUtilityClass';\nimport { generateUtilityClasses } from '../generateUtilityClasses';\nconst COMPONENT_NAME = 'Popper';\nexport function getPopperUtilityClass(slot) {\n return generateUtilityClass(COMPONENT_NAME, slot);\n}\nexport const popperClasses = generateUtilityClasses(COMPONENT_NAME, ['root']);","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"anchorEl\", \"children\", \"direction\", \"disablePortal\", \"modifiers\", \"open\", \"placement\", \"popperOptions\", \"popperRef\", \"slotProps\", \"slots\", \"TransitionProps\", \"ownerState\"],\n _excluded2 = [\"anchorEl\", \"children\", \"container\", \"direction\", \"disablePortal\", \"keepMounted\", \"modifiers\", \"open\", \"placement\", \"popperOptions\", \"popperRef\", \"style\", \"transition\", \"slotProps\", \"slots\"];\nimport * as React from 'react';\nimport { chainPropTypes, HTMLElementType, refType, unstable_ownerDocument as ownerDocument, unstable_useEnhancedEffect as useEnhancedEffect, unstable_useForkRef as useForkRef } from '@mui/utils';\nimport { createPopper } from '@popperjs/core';\nimport PropTypes from 'prop-types';\nimport { unstable_composeClasses as composeClasses } from '../composeClasses';\nimport { Portal } from '../Portal';\nimport { getPopperUtilityClass } from './popperClasses';\nimport { useSlotProps } from '../utils';\nimport { useClassNamesOverride } from '../utils/ClassNameConfigurator';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nfunction flipPlacement(placement, direction) {\n if (direction === 'ltr') {\n return placement;\n }\n switch (placement) {\n case 'bottom-end':\n return 'bottom-start';\n case 'bottom-start':\n return 'bottom-end';\n case 'top-end':\n return 'top-start';\n case 'top-start':\n return 'top-end';\n default:\n return placement;\n }\n}\nfunction resolveAnchorEl(anchorEl) {\n return typeof anchorEl === 'function' ? anchorEl() : anchorEl;\n}\nfunction isHTMLElement(element) {\n return element.nodeType !== undefined;\n}\nfunction isVirtualElement(element) {\n return !isHTMLElement(element);\n}\nconst useUtilityClasses = () => {\n const slots = {\n root: ['root']\n };\n return composeClasses(slots, useClassNamesOverride(getPopperUtilityClass));\n};\nconst defaultPopperOptions = {};\nconst PopperTooltip = /*#__PURE__*/React.forwardRef(function PopperTooltip(props, forwardedRef) {\n var _slots$root;\n const {\n anchorEl,\n children,\n direction,\n disablePortal,\n modifiers,\n open,\n placement: initialPlacement,\n popperOptions,\n popperRef: popperRefProp,\n slotProps = {},\n slots = {},\n TransitionProps\n // @ts-ignore internal logic\n // prevent from spreading to DOM, it can come from the parent component e.g. Select.\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const tooltipRef = React.useRef(null);\n const ownRef = useForkRef(tooltipRef, forwardedRef);\n const popperRef = React.useRef(null);\n const handlePopperRef = useForkRef(popperRef, popperRefProp);\n const handlePopperRefRef = React.useRef(handlePopperRef);\n useEnhancedEffect(() => {\n handlePopperRefRef.current = handlePopperRef;\n }, [handlePopperRef]);\n React.useImperativeHandle(popperRefProp, () => popperRef.current, []);\n const rtlPlacement = flipPlacement(initialPlacement, direction);\n /**\n * placement initialized from prop but can change during lifetime if modifiers.flip.\n * modifiers.flip is essentially a flip for controlled/uncontrolled behavior\n */\n const [placement, setPlacement] = React.useState(rtlPlacement);\n const [resolvedAnchorElement, setResolvedAnchorElement] = React.useState(resolveAnchorEl(anchorEl));\n React.useEffect(() => {\n if (popperRef.current) {\n popperRef.current.forceUpdate();\n }\n });\n React.useEffect(() => {\n if (anchorEl) {\n setResolvedAnchorElement(resolveAnchorEl(anchorEl));\n }\n }, [anchorEl]);\n useEnhancedEffect(() => {\n if (!resolvedAnchorElement || !open) {\n return undefined;\n }\n const handlePopperUpdate = data => {\n setPlacement(data.placement);\n };\n if (process.env.NODE_ENV !== 'production') {\n if (resolvedAnchorElement && isHTMLElement(resolvedAnchorElement) && resolvedAnchorElement.nodeType === 1) {\n const box = resolvedAnchorElement.getBoundingClientRect();\n if (process.env.NODE_ENV !== 'test' && box.top === 0 && box.left === 0 && box.right === 0 && box.bottom === 0) {\n console.warn(['MUI: The `anchorEl` prop provided to the component is invalid.', 'The anchor element should be part of the document layout.', \"Make sure the element is present in the document or that it's not display none.\"].join('\\n'));\n }\n }\n }\n let popperModifiers = [{\n name: 'preventOverflow',\n options: {\n altBoundary: disablePortal\n }\n }, {\n name: 'flip',\n options: {\n altBoundary: disablePortal\n }\n }, {\n name: 'onUpdate',\n enabled: true,\n phase: 'afterWrite',\n fn: ({\n state\n }) => {\n handlePopperUpdate(state);\n }\n }];\n if (modifiers != null) {\n popperModifiers = popperModifiers.concat(modifiers);\n }\n if (popperOptions && popperOptions.modifiers != null) {\n popperModifiers = popperModifiers.concat(popperOptions.modifiers);\n }\n const popper = createPopper(resolvedAnchorElement, tooltipRef.current, _extends({\n placement: rtlPlacement\n }, popperOptions, {\n modifiers: popperModifiers\n }));\n handlePopperRefRef.current(popper);\n return () => {\n popper.destroy();\n handlePopperRefRef.current(null);\n };\n }, [resolvedAnchorElement, disablePortal, modifiers, open, popperOptions, rtlPlacement]);\n const childProps = {\n placement: placement\n };\n if (TransitionProps !== null) {\n childProps.TransitionProps = TransitionProps;\n }\n const classes = useUtilityClasses();\n const Root = (_slots$root = slots.root) != null ? _slots$root : 'div';\n const rootProps = useSlotProps({\n elementType: Root,\n externalSlotProps: slotProps.root,\n externalForwardedProps: other,\n additionalProps: {\n role: 'tooltip',\n ref: ownRef\n },\n ownerState: props,\n className: classes.root\n });\n return /*#__PURE__*/_jsx(Root, _extends({}, rootProps, {\n children: typeof children === 'function' ? children(childProps) : children\n }));\n});\n\n/**\n * Poppers rely on the 3rd party library [Popper.js](https://popper.js.org/docs/v2/) for positioning.\n *\n * Demos:\n *\n * - [Popper](https://mui.com/base-ui/react-popper/)\n *\n * API:\n *\n * - [Popper API](https://mui.com/base-ui/react-popper/components-api/#popper)\n */\nconst Popper = /*#__PURE__*/React.forwardRef(function Popper(props, forwardedRef) {\n const {\n anchorEl,\n children,\n container: containerProp,\n direction = 'ltr',\n disablePortal = false,\n keepMounted = false,\n modifiers,\n open,\n placement = 'bottom',\n popperOptions = defaultPopperOptions,\n popperRef,\n style,\n transition = false,\n slotProps = {},\n slots = {}\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded2);\n const [exited, setExited] = React.useState(true);\n const handleEnter = () => {\n setExited(false);\n };\n const handleExited = () => {\n setExited(true);\n };\n if (!keepMounted && !open && (!transition || exited)) {\n return null;\n }\n\n // If the container prop is provided, use that\n // If the anchorEl prop is provided, use its parent body element as the container\n // If neither are provided let the Modal take care of choosing the container\n let container;\n if (containerProp) {\n container = containerProp;\n } else if (anchorEl) {\n const resolvedAnchorEl = resolveAnchorEl(anchorEl);\n container = resolvedAnchorEl && isHTMLElement(resolvedAnchorEl) ? ownerDocument(resolvedAnchorEl).body : ownerDocument(null).body;\n }\n const display = !open && keepMounted && (!transition || exited) ? 'none' : undefined;\n const transitionProps = transition ? {\n in: open,\n onEnter: handleEnter,\n onExited: handleExited\n } : undefined;\n return /*#__PURE__*/_jsx(Portal, {\n disablePortal: disablePortal,\n container: container,\n children: /*#__PURE__*/_jsx(PopperTooltip, _extends({\n anchorEl: anchorEl,\n direction: direction,\n disablePortal: disablePortal,\n modifiers: modifiers,\n ref: forwardedRef,\n open: transition ? !exited : open,\n placement: placement,\n popperOptions: popperOptions,\n popperRef: popperRef,\n slotProps: slotProps,\n slots: slots\n }, other, {\n style: _extends({\n // Prevents scroll issue, waiting for Popper.js to add this style once initiated.\n position: 'fixed',\n // Fix Popper.js display issue\n top: 0,\n left: 0,\n display\n }, style),\n TransitionProps: transitionProps,\n children: children\n }))\n });\n});\nprocess.env.NODE_ENV !== \"production\" ? Popper.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * An HTML element, [virtualElement](https://popper.js.org/docs/v2/virtual-elements/),\n * or a function that returns either.\n * It's used to set the position of the popper.\n * The return value will passed as the reference object of the Popper instance.\n */\n anchorEl: chainPropTypes(PropTypes.oneOfType([HTMLElementType, PropTypes.object, PropTypes.func]), props => {\n if (props.open) {\n const resolvedAnchorEl = resolveAnchorEl(props.anchorEl);\n if (resolvedAnchorEl && isHTMLElement(resolvedAnchorEl) && resolvedAnchorEl.nodeType === 1) {\n const box = resolvedAnchorEl.getBoundingClientRect();\n if (process.env.NODE_ENV !== 'test' && box.top === 0 && box.left === 0 && box.right === 0 && box.bottom === 0) {\n return new Error(['MUI: The `anchorEl` prop provided to the component is invalid.', 'The anchor element should be part of the document layout.', \"Make sure the element is present in the document or that it's not display none.\"].join('\\n'));\n }\n } else if (!resolvedAnchorEl || typeof resolvedAnchorEl.getBoundingClientRect !== 'function' || isVirtualElement(resolvedAnchorEl) && resolvedAnchorEl.contextElement != null && resolvedAnchorEl.contextElement.nodeType !== 1) {\n return new Error(['MUI: The `anchorEl` prop provided to the component is invalid.', 'It should be an HTML element instance or a virtualElement ', '(https://popper.js.org/docs/v2/virtual-elements/).'].join('\\n'));\n }\n }\n return null;\n }),\n /**\n * Popper render function or node.\n */\n children: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.node, PropTypes.func]),\n /**\n * An HTML element or function that returns one.\n * The `container` will have the portal children appended to it.\n *\n * You can also provide a callback, which is called in a React layout effect.\n * This lets you set the container from a ref, and also makes server-side rendering possible.\n *\n * By default, it uses the body of the top-level document object,\n * so it's simply `document.body` most of the time.\n */\n container: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.func]),\n /**\n * Direction of the text.\n * @default 'ltr'\n */\n direction: PropTypes.oneOf(['ltr', 'rtl']),\n /**\n * The `children` will be under the DOM hierarchy of the parent component.\n * @default false\n */\n disablePortal: PropTypes.bool,\n /**\n * Always keep the children in the DOM.\n * This prop can be useful in SEO situation or\n * when you want to maximize the responsiveness of the Popper.\n * @default false\n */\n keepMounted: PropTypes.bool,\n /**\n * Popper.js is based on a \"plugin-like\" architecture,\n * most of its features are fully encapsulated \"modifiers\".\n *\n * A modifier is a function that is called each time Popper.js needs to\n * compute the position of the popper.\n * For this reason, modifiers should be very performant to avoid bottlenecks.\n * To learn how to create a modifier, [read the modifiers documentation](https://popper.js.org/docs/v2/modifiers/).\n */\n modifiers: PropTypes.arrayOf(PropTypes.shape({\n data: PropTypes.object,\n effect: PropTypes.func,\n enabled: PropTypes.bool,\n fn: PropTypes.func,\n name: PropTypes.any,\n options: PropTypes.object,\n phase: PropTypes.oneOf(['afterMain', 'afterRead', 'afterWrite', 'beforeMain', 'beforeRead', 'beforeWrite', 'main', 'read', 'write']),\n requires: PropTypes.arrayOf(PropTypes.string),\n requiresIfExists: PropTypes.arrayOf(PropTypes.string)\n })),\n /**\n * If `true`, the component is shown.\n */\n open: PropTypes.bool.isRequired,\n /**\n * Popper placement.\n * @default 'bottom'\n */\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n /**\n * Options provided to the [`Popper.js`](https://popper.js.org/docs/v2/constructors/#options) instance.\n * @default {}\n */\n popperOptions: PropTypes.shape({\n modifiers: PropTypes.array,\n onFirstUpdate: PropTypes.func,\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n strategy: PropTypes.oneOf(['absolute', 'fixed'])\n }),\n /**\n * A ref that points to the used popper instance.\n */\n popperRef: refType,\n /**\n * The props used for each slot inside the Popper.\n * @default {}\n */\n slotProps: PropTypes.shape({\n root: PropTypes.oneOfType([PropTypes.func, PropTypes.object])\n }),\n /**\n * The components used for each slot inside the Popper.\n * Either a string to use a HTML element or a component.\n * @default {}\n */\n slots: PropTypes.shape({\n root: PropTypes.elementType\n }),\n /**\n * Help supporting a react-transition-group/Transition component.\n * @default false\n */\n transition: PropTypes.bool\n} : void 0;\nexport { Popper };","'use client';\n\nimport * as React from 'react';\nimport { useTheme as useThemeSystem } from '@mui/system';\nimport defaultTheme from './defaultTheme';\nimport THEME_ID from './identifier';\nexport default function useTheme() {\n const theme = useThemeSystem(defaultTheme);\n if (process.env.NODE_ENV !== 'production') {\n // eslint-disable-next-line react-hooks/rules-of-hooks\n React.useDebugValue(theme);\n }\n return theme[THEME_ID] || theme;\n}","export default function _setPrototypeOf(o, p) {\n _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function _setPrototypeOf(o, p) {\n o.__proto__ = p;\n return o;\n };\n return _setPrototypeOf(o, p);\n}","import setPrototypeOf from \"./setPrototypeOf.js\";\nexport default function _inheritsLoose(subClass, superClass) {\n subClass.prototype = Object.create(superClass.prototype);\n subClass.prototype.constructor = subClass;\n setPrototypeOf(subClass, superClass);\n}","export default {\n disabled: false\n};","import PropTypes from 'prop-types';\nexport var timeoutsShape = process.env.NODE_ENV !== 'production' ? PropTypes.oneOfType([PropTypes.number, PropTypes.shape({\n enter: PropTypes.number,\n exit: PropTypes.number,\n appear: PropTypes.number\n}).isRequired]) : null;\nexport var classNamesShape = process.env.NODE_ENV !== 'production' ? PropTypes.oneOfType([PropTypes.string, PropTypes.shape({\n enter: PropTypes.string,\n exit: PropTypes.string,\n active: PropTypes.string\n}), PropTypes.shape({\n enter: PropTypes.string,\n enterDone: PropTypes.string,\n enterActive: PropTypes.string,\n exit: PropTypes.string,\n exitDone: PropTypes.string,\n exitActive: PropTypes.string\n})]) : null;","import React from 'react';\nexport default React.createContext(null);","export var forceReflow = function forceReflow(node) {\n return node.scrollTop;\n};","import _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _inheritsLoose from \"@babel/runtime/helpers/esm/inheritsLoose\";\nimport PropTypes from 'prop-types';\nimport React from 'react';\nimport ReactDOM from 'react-dom';\nimport config from './config';\nimport { timeoutsShape } from './utils/PropTypes';\nimport TransitionGroupContext from './TransitionGroupContext';\nimport { forceReflow } from './utils/reflow';\nexport var UNMOUNTED = 'unmounted';\nexport var EXITED = 'exited';\nexport var ENTERING = 'entering';\nexport var ENTERED = 'entered';\nexport var EXITING = 'exiting';\n/**\n * The Transition component lets you describe a transition from one component\n * state to another _over time_ with a simple declarative API. Most commonly\n * it's used to animate the mounting and unmounting of a component, but can also\n * be used to describe in-place transition states as well.\n *\n * ---\n *\n * **Note**: `Transition` is a platform-agnostic base component. If you're using\n * transitions in CSS, you'll probably want to use\n * [`CSSTransition`](https://reactcommunity.org/react-transition-group/css-transition)\n * instead. It inherits all the features of `Transition`, but contains\n * additional features necessary to play nice with CSS transitions (hence the\n * name of the component).\n *\n * ---\n *\n * By default the `Transition` component does not alter the behavior of the\n * component it renders, it only tracks \"enter\" and \"exit\" states for the\n * components. It's up to you to give meaning and effect to those states. For\n * example we can add styles to a component when it enters or exits:\n *\n * ```jsx\n * import { Transition } from 'react-transition-group';\n *\n * const duration = 300;\n *\n * const defaultStyle = {\n * transition: `opacity ${duration}ms ease-in-out`,\n * opacity: 0,\n * }\n *\n * const transitionStyles = {\n * entering: { opacity: 1 },\n * entered: { opacity: 1 },\n * exiting: { opacity: 0 },\n * exited: { opacity: 0 },\n * };\n *\n * const Fade = ({ in: inProp }) => (\n * \n * {state => (\n *
    \n * I'm a fade Transition!\n *
    \n * )}\n *
    \n * );\n * ```\n *\n * There are 4 main states a Transition can be in:\n * - `'entering'`\n * - `'entered'`\n * - `'exiting'`\n * - `'exited'`\n *\n * Transition state is toggled via the `in` prop. When `true` the component\n * begins the \"Enter\" stage. During this stage, the component will shift from\n * its current transition state, to `'entering'` for the duration of the\n * transition and then to the `'entered'` stage once it's complete. Let's take\n * the following example (we'll use the\n * [useState](https://reactjs.org/docs/hooks-reference.html#usestate) hook):\n *\n * ```jsx\n * function App() {\n * const [inProp, setInProp] = useState(false);\n * return (\n *
    \n * \n * {state => (\n * // ...\n * )}\n * \n * \n *
    \n * );\n * }\n * ```\n *\n * When the button is clicked the component will shift to the `'entering'` state\n * and stay there for 500ms (the value of `timeout`) before it finally switches\n * to `'entered'`.\n *\n * When `in` is `false` the same thing happens except the state moves from\n * `'exiting'` to `'exited'`.\n */\n\nvar Transition = /*#__PURE__*/function (_React$Component) {\n _inheritsLoose(Transition, _React$Component);\n\n function Transition(props, context) {\n var _this;\n\n _this = _React$Component.call(this, props, context) || this;\n var parentGroup = context; // In the context of a TransitionGroup all enters are really appears\n\n var appear = parentGroup && !parentGroup.isMounting ? props.enter : props.appear;\n var initialStatus;\n _this.appearStatus = null;\n\n if (props.in) {\n if (appear) {\n initialStatus = EXITED;\n _this.appearStatus = ENTERING;\n } else {\n initialStatus = ENTERED;\n }\n } else {\n if (props.unmountOnExit || props.mountOnEnter) {\n initialStatus = UNMOUNTED;\n } else {\n initialStatus = EXITED;\n }\n }\n\n _this.state = {\n status: initialStatus\n };\n _this.nextCallback = null;\n return _this;\n }\n\n Transition.getDerivedStateFromProps = function getDerivedStateFromProps(_ref, prevState) {\n var nextIn = _ref.in;\n\n if (nextIn && prevState.status === UNMOUNTED) {\n return {\n status: EXITED\n };\n }\n\n return null;\n } // getSnapshotBeforeUpdate(prevProps) {\n // let nextStatus = null\n // if (prevProps !== this.props) {\n // const { status } = this.state\n // if (this.props.in) {\n // if (status !== ENTERING && status !== ENTERED) {\n // nextStatus = ENTERING\n // }\n // } else {\n // if (status === ENTERING || status === ENTERED) {\n // nextStatus = EXITING\n // }\n // }\n // }\n // return { nextStatus }\n // }\n ;\n\n var _proto = Transition.prototype;\n\n _proto.componentDidMount = function componentDidMount() {\n this.updateStatus(true, this.appearStatus);\n };\n\n _proto.componentDidUpdate = function componentDidUpdate(prevProps) {\n var nextStatus = null;\n\n if (prevProps !== this.props) {\n var status = this.state.status;\n\n if (this.props.in) {\n if (status !== ENTERING && status !== ENTERED) {\n nextStatus = ENTERING;\n }\n } else {\n if (status === ENTERING || status === ENTERED) {\n nextStatus = EXITING;\n }\n }\n }\n\n this.updateStatus(false, nextStatus);\n };\n\n _proto.componentWillUnmount = function componentWillUnmount() {\n this.cancelNextCallback();\n };\n\n _proto.getTimeouts = function getTimeouts() {\n var timeout = this.props.timeout;\n var exit, enter, appear;\n exit = enter = appear = timeout;\n\n if (timeout != null && typeof timeout !== 'number') {\n exit = timeout.exit;\n enter = timeout.enter; // TODO: remove fallback for next major\n\n appear = timeout.appear !== undefined ? timeout.appear : enter;\n }\n\n return {\n exit: exit,\n enter: enter,\n appear: appear\n };\n };\n\n _proto.updateStatus = function updateStatus(mounting, nextStatus) {\n if (mounting === void 0) {\n mounting = false;\n }\n\n if (nextStatus !== null) {\n // nextStatus will always be ENTERING or EXITING.\n this.cancelNextCallback();\n\n if (nextStatus === ENTERING) {\n if (this.props.unmountOnExit || this.props.mountOnEnter) {\n var node = this.props.nodeRef ? this.props.nodeRef.current : ReactDOM.findDOMNode(this); // https://github.com/reactjs/react-transition-group/pull/749\n // With unmountOnExit or mountOnEnter, the enter animation should happen at the transition between `exited` and `entering`.\n // To make the animation happen, we have to separate each rendering and avoid being processed as batched.\n\n if (node) forceReflow(node);\n }\n\n this.performEnter(mounting);\n } else {\n this.performExit();\n }\n } else if (this.props.unmountOnExit && this.state.status === EXITED) {\n this.setState({\n status: UNMOUNTED\n });\n }\n };\n\n _proto.performEnter = function performEnter(mounting) {\n var _this2 = this;\n\n var enter = this.props.enter;\n var appearing = this.context ? this.context.isMounting : mounting;\n\n var _ref2 = this.props.nodeRef ? [appearing] : [ReactDOM.findDOMNode(this), appearing],\n maybeNode = _ref2[0],\n maybeAppearing = _ref2[1];\n\n var timeouts = this.getTimeouts();\n var enterTimeout = appearing ? timeouts.appear : timeouts.enter; // no enter animation skip right to ENTERED\n // if we are mounting and running this it means appear _must_ be set\n\n if (!mounting && !enter || config.disabled) {\n this.safeSetState({\n status: ENTERED\n }, function () {\n _this2.props.onEntered(maybeNode);\n });\n return;\n }\n\n this.props.onEnter(maybeNode, maybeAppearing);\n this.safeSetState({\n status: ENTERING\n }, function () {\n _this2.props.onEntering(maybeNode, maybeAppearing);\n\n _this2.onTransitionEnd(enterTimeout, function () {\n _this2.safeSetState({\n status: ENTERED\n }, function () {\n _this2.props.onEntered(maybeNode, maybeAppearing);\n });\n });\n });\n };\n\n _proto.performExit = function performExit() {\n var _this3 = this;\n\n var exit = this.props.exit;\n var timeouts = this.getTimeouts();\n var maybeNode = this.props.nodeRef ? undefined : ReactDOM.findDOMNode(this); // no exit animation skip right to EXITED\n\n if (!exit || config.disabled) {\n this.safeSetState({\n status: EXITED\n }, function () {\n _this3.props.onExited(maybeNode);\n });\n return;\n }\n\n this.props.onExit(maybeNode);\n this.safeSetState({\n status: EXITING\n }, function () {\n _this3.props.onExiting(maybeNode);\n\n _this3.onTransitionEnd(timeouts.exit, function () {\n _this3.safeSetState({\n status: EXITED\n }, function () {\n _this3.props.onExited(maybeNode);\n });\n });\n });\n };\n\n _proto.cancelNextCallback = function cancelNextCallback() {\n if (this.nextCallback !== null) {\n this.nextCallback.cancel();\n this.nextCallback = null;\n }\n };\n\n _proto.safeSetState = function safeSetState(nextState, callback) {\n // This shouldn't be necessary, but there are weird race conditions with\n // setState callbacks and unmounting in testing, so always make sure that\n // we can cancel any pending setState callbacks after we unmount.\n callback = this.setNextCallback(callback);\n this.setState(nextState, callback);\n };\n\n _proto.setNextCallback = function setNextCallback(callback) {\n var _this4 = this;\n\n var active = true;\n\n this.nextCallback = function (event) {\n if (active) {\n active = false;\n _this4.nextCallback = null;\n callback(event);\n }\n };\n\n this.nextCallback.cancel = function () {\n active = false;\n };\n\n return this.nextCallback;\n };\n\n _proto.onTransitionEnd = function onTransitionEnd(timeout, handler) {\n this.setNextCallback(handler);\n var node = this.props.nodeRef ? this.props.nodeRef.current : ReactDOM.findDOMNode(this);\n var doesNotHaveTimeoutOrListener = timeout == null && !this.props.addEndListener;\n\n if (!node || doesNotHaveTimeoutOrListener) {\n setTimeout(this.nextCallback, 0);\n return;\n }\n\n if (this.props.addEndListener) {\n var _ref3 = this.props.nodeRef ? [this.nextCallback] : [node, this.nextCallback],\n maybeNode = _ref3[0],\n maybeNextCallback = _ref3[1];\n\n this.props.addEndListener(maybeNode, maybeNextCallback);\n }\n\n if (timeout != null) {\n setTimeout(this.nextCallback, timeout);\n }\n };\n\n _proto.render = function render() {\n var status = this.state.status;\n\n if (status === UNMOUNTED) {\n return null;\n }\n\n var _this$props = this.props,\n children = _this$props.children,\n _in = _this$props.in,\n _mountOnEnter = _this$props.mountOnEnter,\n _unmountOnExit = _this$props.unmountOnExit,\n _appear = _this$props.appear,\n _enter = _this$props.enter,\n _exit = _this$props.exit,\n _timeout = _this$props.timeout,\n _addEndListener = _this$props.addEndListener,\n _onEnter = _this$props.onEnter,\n _onEntering = _this$props.onEntering,\n _onEntered = _this$props.onEntered,\n _onExit = _this$props.onExit,\n _onExiting = _this$props.onExiting,\n _onExited = _this$props.onExited,\n _nodeRef = _this$props.nodeRef,\n childProps = _objectWithoutPropertiesLoose(_this$props, [\"children\", \"in\", \"mountOnEnter\", \"unmountOnExit\", \"appear\", \"enter\", \"exit\", \"timeout\", \"addEndListener\", \"onEnter\", \"onEntering\", \"onEntered\", \"onExit\", \"onExiting\", \"onExited\", \"nodeRef\"]);\n\n return (\n /*#__PURE__*/\n // allows for nested Transitions\n React.createElement(TransitionGroupContext.Provider, {\n value: null\n }, typeof children === 'function' ? children(status, childProps) : React.cloneElement(React.Children.only(children), childProps))\n );\n };\n\n return Transition;\n}(React.Component);\n\nTransition.contextType = TransitionGroupContext;\nTransition.propTypes = process.env.NODE_ENV !== \"production\" ? {\n /**\n * A React reference to DOM element that need to transition:\n * https://stackoverflow.com/a/51127130/4671932\n *\n * - When `nodeRef` prop is used, `node` is not passed to callback functions\n * (e.g. `onEnter`) because user already has direct access to the node.\n * - When changing `key` prop of `Transition` in a `TransitionGroup` a new\n * `nodeRef` need to be provided to `Transition` with changed `key` prop\n * (see\n * [test/CSSTransition-test.js](https://github.com/reactjs/react-transition-group/blob/13435f897b3ab71f6e19d724f145596f5910581c/test/CSSTransition-test.js#L362-L437)).\n */\n nodeRef: PropTypes.shape({\n current: typeof Element === 'undefined' ? PropTypes.any : function (propValue, key, componentName, location, propFullName, secret) {\n var value = propValue[key];\n return PropTypes.instanceOf(value && 'ownerDocument' in value ? value.ownerDocument.defaultView.Element : Element)(propValue, key, componentName, location, propFullName, secret);\n }\n }),\n\n /**\n * A `function` child can be used instead of a React element. This function is\n * called with the current transition status (`'entering'`, `'entered'`,\n * `'exiting'`, `'exited'`), which can be used to apply context\n * specific props to a component.\n *\n * ```jsx\n * \n * {state => (\n * \n * )}\n * \n * ```\n */\n children: PropTypes.oneOfType([PropTypes.func.isRequired, PropTypes.element.isRequired]).isRequired,\n\n /**\n * Show the component; triggers the enter or exit states\n */\n in: PropTypes.bool,\n\n /**\n * By default the child component is mounted immediately along with\n * the parent `Transition` component. If you want to \"lazy mount\" the component on the\n * first `in={true}` you can set `mountOnEnter`. After the first enter transition the component will stay\n * mounted, even on \"exited\", unless you also specify `unmountOnExit`.\n */\n mountOnEnter: PropTypes.bool,\n\n /**\n * By default the child component stays mounted after it reaches the `'exited'` state.\n * Set `unmountOnExit` if you'd prefer to unmount the component after it finishes exiting.\n */\n unmountOnExit: PropTypes.bool,\n\n /**\n * By default the child component does not perform the enter transition when\n * it first mounts, regardless of the value of `in`. If you want this\n * behavior, set both `appear` and `in` to `true`.\n *\n * > **Note**: there are no special appear states like `appearing`/`appeared`, this prop\n * > only adds an additional enter transition. However, in the\n * > `` component that first enter transition does result in\n * > additional `.appear-*` classes, that way you can choose to style it\n * > differently.\n */\n appear: PropTypes.bool,\n\n /**\n * Enable or disable enter transitions.\n */\n enter: PropTypes.bool,\n\n /**\n * Enable or disable exit transitions.\n */\n exit: PropTypes.bool,\n\n /**\n * The duration of the transition, in milliseconds.\n * Required unless `addEndListener` is provided.\n *\n * You may specify a single timeout for all transitions:\n *\n * ```jsx\n * timeout={500}\n * ```\n *\n * or individually:\n *\n * ```jsx\n * timeout={{\n * appear: 500,\n * enter: 300,\n * exit: 500,\n * }}\n * ```\n *\n * - `appear` defaults to the value of `enter`\n * - `enter` defaults to `0`\n * - `exit` defaults to `0`\n *\n * @type {number | { enter?: number, exit?: number, appear?: number }}\n */\n timeout: function timeout(props) {\n var pt = timeoutsShape;\n if (!props.addEndListener) pt = pt.isRequired;\n\n for (var _len = arguments.length, args = new Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) {\n args[_key - 1] = arguments[_key];\n }\n\n return pt.apply(void 0, [props].concat(args));\n },\n\n /**\n * Add a custom transition end trigger. Called with the transitioning\n * DOM node and a `done` callback. Allows for more fine grained transition end\n * logic. Timeouts are still used as a fallback if provided.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * ```jsx\n * addEndListener={(node, done) => {\n * // use the css transitionend event to mark the finish of a transition\n * node.addEventListener('transitionend', done, false);\n * }}\n * ```\n */\n addEndListener: PropTypes.func,\n\n /**\n * Callback fired before the \"entering\" status is applied. An extra parameter\n * `isAppearing` is supplied to indicate if the enter stage is occurring on the initial mount\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement, isAppearing: bool) -> void\n */\n onEnter: PropTypes.func,\n\n /**\n * Callback fired after the \"entering\" status is applied. An extra parameter\n * `isAppearing` is supplied to indicate if the enter stage is occurring on the initial mount\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement, isAppearing: bool)\n */\n onEntering: PropTypes.func,\n\n /**\n * Callback fired after the \"entered\" status is applied. An extra parameter\n * `isAppearing` is supplied to indicate if the enter stage is occurring on the initial mount\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement, isAppearing: bool) -> void\n */\n onEntered: PropTypes.func,\n\n /**\n * Callback fired before the \"exiting\" status is applied.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement) -> void\n */\n onExit: PropTypes.func,\n\n /**\n * Callback fired after the \"exiting\" status is applied.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement) -> void\n */\n onExiting: PropTypes.func,\n\n /**\n * Callback fired after the \"exited\" status is applied.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed\n *\n * @type Function(node: HtmlElement) -> void\n */\n onExited: PropTypes.func\n} : {}; // Name the function so it is clearer in the documentation\n\nfunction noop() {}\n\nTransition.defaultProps = {\n in: false,\n mountOnEnter: false,\n unmountOnExit: false,\n appear: false,\n enter: true,\n exit: true,\n onEnter: noop,\n onEntering: noop,\n onEntered: noop,\n onExit: noop,\n onExiting: noop,\n onExited: noop\n};\nTransition.UNMOUNTED = UNMOUNTED;\nTransition.EXITED = EXITED;\nTransition.ENTERING = ENTERING;\nTransition.ENTERED = ENTERED;\nTransition.EXITING = EXITING;\nexport default Transition;","export const reflow = node => node.scrollTop;\nexport function getTransitionProps(props, options) {\n var _style$transitionDura, _style$transitionTimi;\n const {\n timeout,\n easing,\n style = {}\n } = props;\n return {\n duration: (_style$transitionDura = style.transitionDuration) != null ? _style$transitionDura : typeof timeout === 'number' ? timeout : timeout[options.mode] || 0,\n easing: (_style$transitionTimi = style.transitionTimingFunction) != null ? _style$transitionTimi : typeof easing === 'object' ? easing[options.mode] : easing,\n delay: style.transitionDelay\n };\n}","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"addEndListener\", \"appear\", \"children\", \"easing\", \"in\", \"onEnter\", \"onEntered\", \"onEntering\", \"onExit\", \"onExited\", \"onExiting\", \"style\", \"timeout\", \"TransitionComponent\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport { elementAcceptingRef, unstable_useTimeout as useTimeout } from '@mui/utils';\nimport { Transition } from 'react-transition-group';\nimport useTheme from '../styles/useTheme';\nimport { getTransitionProps, reflow } from '../transitions/utils';\nimport useForkRef from '../utils/useForkRef';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nfunction getScale(value) {\n return `scale(${value}, ${value ** 2})`;\n}\nconst styles = {\n entering: {\n opacity: 1,\n transform: getScale(1)\n },\n entered: {\n opacity: 1,\n transform: 'none'\n }\n};\n\n/*\n TODO v6: remove\n Conditionally apply a workaround for the CSS transition bug in Safari 15.4 / WebKit browsers.\n */\nconst isWebKit154 = typeof navigator !== 'undefined' && /^((?!chrome|android).)*(safari|mobile)/i.test(navigator.userAgent) && /(os |version\\/)15(.|_)4/i.test(navigator.userAgent);\n\n/**\n * The Grow transition is used by the [Tooltip](/material-ui/react-tooltip/) and\n * [Popover](/material-ui/react-popover/) components.\n * It uses [react-transition-group](https://github.com/reactjs/react-transition-group) internally.\n */\nconst Grow = /*#__PURE__*/React.forwardRef(function Grow(props, ref) {\n const {\n addEndListener,\n appear = true,\n children,\n easing,\n in: inProp,\n onEnter,\n onEntered,\n onEntering,\n onExit,\n onExited,\n onExiting,\n style,\n timeout = 'auto',\n // eslint-disable-next-line react/prop-types\n TransitionComponent = Transition\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const timer = useTimeout();\n const autoTimeout = React.useRef();\n const theme = useTheme();\n const nodeRef = React.useRef(null);\n const handleRef = useForkRef(nodeRef, children.ref, ref);\n const normalizedTransitionCallback = callback => maybeIsAppearing => {\n if (callback) {\n const node = nodeRef.current;\n\n // onEnterXxx and onExitXxx callbacks have a different arguments.length value.\n if (maybeIsAppearing === undefined) {\n callback(node);\n } else {\n callback(node, maybeIsAppearing);\n }\n }\n };\n const handleEntering = normalizedTransitionCallback(onEntering);\n const handleEnter = normalizedTransitionCallback((node, isAppearing) => {\n reflow(node); // So the animation always start from the start.\n\n const {\n duration: transitionDuration,\n delay,\n easing: transitionTimingFunction\n } = getTransitionProps({\n style,\n timeout,\n easing\n }, {\n mode: 'enter'\n });\n let duration;\n if (timeout === 'auto') {\n duration = theme.transitions.getAutoHeightDuration(node.clientHeight);\n autoTimeout.current = duration;\n } else {\n duration = transitionDuration;\n }\n node.style.transition = [theme.transitions.create('opacity', {\n duration,\n delay\n }), theme.transitions.create('transform', {\n duration: isWebKit154 ? duration : duration * 0.666,\n delay,\n easing: transitionTimingFunction\n })].join(',');\n if (onEnter) {\n onEnter(node, isAppearing);\n }\n });\n const handleEntered = normalizedTransitionCallback(onEntered);\n const handleExiting = normalizedTransitionCallback(onExiting);\n const handleExit = normalizedTransitionCallback(node => {\n const {\n duration: transitionDuration,\n delay,\n easing: transitionTimingFunction\n } = getTransitionProps({\n style,\n timeout,\n easing\n }, {\n mode: 'exit'\n });\n let duration;\n if (timeout === 'auto') {\n duration = theme.transitions.getAutoHeightDuration(node.clientHeight);\n autoTimeout.current = duration;\n } else {\n duration = transitionDuration;\n }\n node.style.transition = [theme.transitions.create('opacity', {\n duration,\n delay\n }), theme.transitions.create('transform', {\n duration: isWebKit154 ? duration : duration * 0.666,\n delay: isWebKit154 ? delay : delay || duration * 0.333,\n easing: transitionTimingFunction\n })].join(',');\n node.style.opacity = 0;\n node.style.transform = getScale(0.75);\n if (onExit) {\n onExit(node);\n }\n });\n const handleExited = normalizedTransitionCallback(onExited);\n const handleAddEndListener = next => {\n if (timeout === 'auto') {\n timer.start(autoTimeout.current || 0, next);\n }\n if (addEndListener) {\n // Old call signature before `react-transition-group` implemented `nodeRef`\n addEndListener(nodeRef.current, next);\n }\n };\n return /*#__PURE__*/_jsx(TransitionComponent, _extends({\n appear: appear,\n in: inProp,\n nodeRef: nodeRef,\n onEnter: handleEnter,\n onEntered: handleEntered,\n onEntering: handleEntering,\n onExit: handleExit,\n onExited: handleExited,\n onExiting: handleExiting,\n addEndListener: handleAddEndListener,\n timeout: timeout === 'auto' ? null : timeout\n }, other, {\n children: (state, childProps) => {\n return /*#__PURE__*/React.cloneElement(children, _extends({\n style: _extends({\n opacity: 0,\n transform: getScale(0.75),\n visibility: state === 'exited' && !inProp ? 'hidden' : undefined\n }, styles[state], style, children.props.style),\n ref: handleRef\n }, childProps));\n }\n }));\n});\nprocess.env.NODE_ENV !== \"production\" ? Grow.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the d.ts file and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * Add a custom transition end trigger. Called with the transitioning DOM\n * node and a done callback. Allows for more fine grained transition end\n * logic. Note: Timeouts are still used as a fallback if provided.\n */\n addEndListener: PropTypes.func,\n /**\n * Perform the enter transition when it first mounts if `in` is also `true`.\n * Set this to `false` to disable this behavior.\n * @default true\n */\n appear: PropTypes.bool,\n /**\n * A single child content element.\n */\n children: elementAcceptingRef.isRequired,\n /**\n * The transition timing function.\n * You may specify a single easing or a object containing enter and exit values.\n */\n easing: PropTypes.oneOfType([PropTypes.shape({\n enter: PropTypes.string,\n exit: PropTypes.string\n }), PropTypes.string]),\n /**\n * If `true`, the component will transition in.\n */\n in: PropTypes.bool,\n /**\n * @ignore\n */\n onEnter: PropTypes.func,\n /**\n * @ignore\n */\n onEntered: PropTypes.func,\n /**\n * @ignore\n */\n onEntering: PropTypes.func,\n /**\n * @ignore\n */\n onExit: PropTypes.func,\n /**\n * @ignore\n */\n onExited: PropTypes.func,\n /**\n * @ignore\n */\n onExiting: PropTypes.func,\n /**\n * @ignore\n */\n style: PropTypes.object,\n /**\n * The duration for the transition, in milliseconds.\n * You may specify a single timeout for all transitions, or individually with an object.\n *\n * Set to 'auto' to automatically calculate transition time based on height.\n * @default 'auto'\n */\n timeout: PropTypes.oneOfType([PropTypes.oneOf(['auto']), PropTypes.number, PropTypes.shape({\n appear: PropTypes.number,\n enter: PropTypes.number,\n exit: PropTypes.number\n })])\n} : void 0;\nGrow.muiSupportAuto = true;\nexport default Grow;","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"anchorEl\", \"component\", \"components\", \"componentsProps\", \"container\", \"disablePortal\", \"keepMounted\", \"modifiers\", \"open\", \"placement\", \"popperOptions\", \"popperRef\", \"transition\", \"slots\", \"slotProps\"];\nimport { Popper as BasePopper } from '@mui/base/Popper';\nimport { useThemeWithoutDefault as useTheme } from '@mui/system';\nimport { HTMLElementType, refType } from '@mui/utils';\nimport PropTypes from 'prop-types';\nimport * as React from 'react';\nimport { styled, useThemeProps } from '../styles';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nconst PopperRoot = styled(BasePopper, {\n name: 'MuiPopper',\n slot: 'Root',\n overridesResolver: (props, styles) => styles.root\n})({});\n\n/**\n *\n * Demos:\n *\n * - [Autocomplete](https://mui.com/material-ui/react-autocomplete/)\n * - [Menu](https://mui.com/material-ui/react-menu/)\n * - [Popper](https://mui.com/material-ui/react-popper/)\n *\n * API:\n *\n * - [Popper API](https://mui.com/material-ui/api/popper/)\n */\nconst Popper = /*#__PURE__*/React.forwardRef(function Popper(inProps, ref) {\n var _slots$root;\n const theme = useTheme();\n const props = useThemeProps({\n props: inProps,\n name: 'MuiPopper'\n });\n const {\n anchorEl,\n component,\n components,\n componentsProps,\n container,\n disablePortal,\n keepMounted,\n modifiers,\n open,\n placement,\n popperOptions,\n popperRef,\n transition,\n slots,\n slotProps\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const RootComponent = (_slots$root = slots == null ? void 0 : slots.root) != null ? _slots$root : components == null ? void 0 : components.Root;\n const otherProps = _extends({\n anchorEl,\n container,\n disablePortal,\n keepMounted,\n modifiers,\n open,\n placement,\n popperOptions,\n popperRef,\n transition\n }, other);\n return /*#__PURE__*/_jsx(PopperRoot, _extends({\n as: component,\n direction: theme == null ? void 0 : theme.direction,\n slots: {\n root: RootComponent\n },\n slotProps: slotProps != null ? slotProps : componentsProps\n }, otherProps, {\n ref: ref\n }));\n});\nprocess.env.NODE_ENV !== \"production\" ? Popper.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * An HTML element, [virtualElement](https://popper.js.org/docs/v2/virtual-elements/),\n * or a function that returns either.\n * It's used to set the position of the popper.\n * The return value will passed as the reference object of the Popper instance.\n */\n anchorEl: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.object, PropTypes.func]),\n /**\n * Popper render function or node.\n */\n children: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.node, PropTypes.func]),\n /**\n * The component used for the root node.\n * Either a string to use a HTML element or a component.\n */\n component: PropTypes.elementType,\n /**\n * The components used for each slot inside the Popper.\n * Either a string to use a HTML element or a component.\n * @default {}\n */\n components: PropTypes.shape({\n Root: PropTypes.elementType\n }),\n /**\n * The props used for each slot inside the Popper.\n * @default {}\n */\n componentsProps: PropTypes.shape({\n root: PropTypes.oneOfType([PropTypes.func, PropTypes.object])\n }),\n /**\n * An HTML element or function that returns one.\n * The `container` will have the portal children appended to it.\n *\n * You can also provide a callback, which is called in a React layout effect.\n * This lets you set the container from a ref, and also makes server-side rendering possible.\n *\n * By default, it uses the body of the top-level document object,\n * so it's simply `document.body` most of the time.\n */\n container: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.func]),\n /**\n * The `children` will be under the DOM hierarchy of the parent component.\n * @default false\n */\n disablePortal: PropTypes.bool,\n /**\n * Always keep the children in the DOM.\n * This prop can be useful in SEO situation or\n * when you want to maximize the responsiveness of the Popper.\n * @default false\n */\n keepMounted: PropTypes.bool,\n /**\n * Popper.js is based on a \"plugin-like\" architecture,\n * most of its features are fully encapsulated \"modifiers\".\n *\n * A modifier is a function that is called each time Popper.js needs to\n * compute the position of the popper.\n * For this reason, modifiers should be very performant to avoid bottlenecks.\n * To learn how to create a modifier, [read the modifiers documentation](https://popper.js.org/docs/v2/modifiers/).\n */\n modifiers: PropTypes.arrayOf(PropTypes.shape({\n data: PropTypes.object,\n effect: PropTypes.func,\n enabled: PropTypes.bool,\n fn: PropTypes.func,\n name: PropTypes.any,\n options: PropTypes.object,\n phase: PropTypes.oneOf(['afterMain', 'afterRead', 'afterWrite', 'beforeMain', 'beforeRead', 'beforeWrite', 'main', 'read', 'write']),\n requires: PropTypes.arrayOf(PropTypes.string),\n requiresIfExists: PropTypes.arrayOf(PropTypes.string)\n })),\n /**\n * If `true`, the component is shown.\n */\n open: PropTypes.bool.isRequired,\n /**\n * Popper placement.\n * @default 'bottom'\n */\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n /**\n * Options provided to the [`Popper.js`](https://popper.js.org/docs/v2/constructors/#options) instance.\n * @default {}\n */\n popperOptions: PropTypes.shape({\n modifiers: PropTypes.array,\n onFirstUpdate: PropTypes.func,\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n strategy: PropTypes.oneOf(['absolute', 'fixed'])\n }),\n /**\n * A ref that points to the used popper instance.\n */\n popperRef: refType,\n /**\n * The props used for each slot inside the Popper.\n * @default {}\n */\n slotProps: PropTypes.shape({\n root: PropTypes.oneOfType([PropTypes.func, PropTypes.object])\n }),\n /**\n * The components used for each slot inside the Popper.\n * Either a string to use a HTML element or a component.\n * @default {}\n */\n slots: PropTypes.shape({\n root: PropTypes.elementType\n }),\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Help supporting a react-transition-group/Transition component.\n * @default false\n */\n transition: PropTypes.bool\n} : void 0;\nexport default Popper;","import generateUtilityClasses from '@mui/utils/generateUtilityClasses';\nimport generateUtilityClass from '@mui/utils/generateUtilityClass';\nexport function getTooltipUtilityClass(slot) {\n return generateUtilityClass('MuiTooltip', slot);\n}\nconst tooltipClasses = generateUtilityClasses('MuiTooltip', ['popper', 'popperInteractive', 'popperArrow', 'popperClose', 'tooltip', 'tooltipArrow', 'touch', 'tooltipPlacementLeft', 'tooltipPlacementRight', 'tooltipPlacementTop', 'tooltipPlacementBottom', 'arrow']);\nexport default tooltipClasses;","'use client';\n\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nconst _excluded = [\"arrow\", \"children\", \"classes\", \"components\", \"componentsProps\", \"describeChild\", \"disableFocusListener\", \"disableHoverListener\", \"disableInteractive\", \"disableTouchListener\", \"enterDelay\", \"enterNextDelay\", \"enterTouchDelay\", \"followCursor\", \"id\", \"leaveDelay\", \"leaveTouchDelay\", \"onClose\", \"onOpen\", \"open\", \"placement\", \"PopperComponent\", \"PopperProps\", \"slotProps\", \"slots\", \"title\", \"TransitionComponent\", \"TransitionProps\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport clsx from 'clsx';\nimport { elementAcceptingRef, unstable_useTimeout as useTimeout, unstable_Timeout as Timeout } from '@mui/utils';\nimport { unstable_composeClasses as composeClasses, appendOwnerState } from '@mui/base';\nimport { alpha } from '@mui/system';\nimport styled from '../styles/styled';\nimport useTheme from '../styles/useTheme';\nimport useThemeProps from '../styles/useThemeProps';\nimport capitalize from '../utils/capitalize';\nimport Grow from '../Grow';\nimport Popper from '../Popper';\nimport useEventCallback from '../utils/useEventCallback';\nimport useForkRef from '../utils/useForkRef';\nimport useId from '../utils/useId';\nimport useIsFocusVisible from '../utils/useIsFocusVisible';\nimport useControlled from '../utils/useControlled';\nimport tooltipClasses, { getTooltipUtilityClass } from './tooltipClasses';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nimport { jsxs as _jsxs } from \"react/jsx-runtime\";\nfunction round(value) {\n return Math.round(value * 1e5) / 1e5;\n}\nconst useUtilityClasses = ownerState => {\n const {\n classes,\n disableInteractive,\n arrow,\n touch,\n placement\n } = ownerState;\n const slots = {\n popper: ['popper', !disableInteractive && 'popperInteractive', arrow && 'popperArrow'],\n tooltip: ['tooltip', arrow && 'tooltipArrow', touch && 'touch', `tooltipPlacement${capitalize(placement.split('-')[0])}`],\n arrow: ['arrow']\n };\n return composeClasses(slots, getTooltipUtilityClass, classes);\n};\nconst TooltipPopper = styled(Popper, {\n name: 'MuiTooltip',\n slot: 'Popper',\n overridesResolver: (props, styles) => {\n const {\n ownerState\n } = props;\n return [styles.popper, !ownerState.disableInteractive && styles.popperInteractive, ownerState.arrow && styles.popperArrow, !ownerState.open && styles.popperClose];\n }\n})(({\n theme,\n ownerState,\n open\n}) => _extends({\n zIndex: (theme.vars || theme).zIndex.tooltip,\n pointerEvents: 'none'\n}, !ownerState.disableInteractive && {\n pointerEvents: 'auto'\n}, !open && {\n pointerEvents: 'none'\n}, ownerState.arrow && {\n [`&[data-popper-placement*=\"bottom\"] .${tooltipClasses.arrow}`]: {\n top: 0,\n marginTop: '-0.71em',\n '&::before': {\n transformOrigin: '0 100%'\n }\n },\n [`&[data-popper-placement*=\"top\"] .${tooltipClasses.arrow}`]: {\n bottom: 0,\n marginBottom: '-0.71em',\n '&::before': {\n transformOrigin: '100% 0'\n }\n },\n [`&[data-popper-placement*=\"right\"] .${tooltipClasses.arrow}`]: _extends({}, !ownerState.isRtl ? {\n left: 0,\n marginLeft: '-0.71em'\n } : {\n right: 0,\n marginRight: '-0.71em'\n }, {\n height: '1em',\n width: '0.71em',\n '&::before': {\n transformOrigin: '100% 100%'\n }\n }),\n [`&[data-popper-placement*=\"left\"] .${tooltipClasses.arrow}`]: _extends({}, !ownerState.isRtl ? {\n right: 0,\n marginRight: '-0.71em'\n } : {\n left: 0,\n marginLeft: '-0.71em'\n }, {\n height: '1em',\n width: '0.71em',\n '&::before': {\n transformOrigin: '0 0'\n }\n })\n}));\nconst TooltipTooltip = styled('div', {\n name: 'MuiTooltip',\n slot: 'Tooltip',\n overridesResolver: (props, styles) => {\n const {\n ownerState\n } = props;\n return [styles.tooltip, ownerState.touch && styles.touch, ownerState.arrow && styles.tooltipArrow, styles[`tooltipPlacement${capitalize(ownerState.placement.split('-')[0])}`]];\n }\n})(({\n theme,\n ownerState\n}) => _extends({\n backgroundColor: theme.vars ? theme.vars.palette.Tooltip.bg : alpha(theme.palette.grey[700], 0.92),\n borderRadius: (theme.vars || theme).shape.borderRadius,\n color: (theme.vars || theme).palette.common.white,\n fontFamily: theme.typography.fontFamily,\n padding: '4px 8px',\n fontSize: theme.typography.pxToRem(11),\n maxWidth: 300,\n margin: 2,\n wordWrap: 'break-word',\n fontWeight: theme.typography.fontWeightMedium\n}, ownerState.arrow && {\n position: 'relative',\n margin: 0\n}, ownerState.touch && {\n padding: '8px 16px',\n fontSize: theme.typography.pxToRem(14),\n lineHeight: `${round(16 / 14)}em`,\n fontWeight: theme.typography.fontWeightRegular\n}, {\n [`.${tooltipClasses.popper}[data-popper-placement*=\"left\"] &`]: _extends({\n transformOrigin: 'right center'\n }, !ownerState.isRtl ? _extends({\n marginRight: '14px'\n }, ownerState.touch && {\n marginRight: '24px'\n }) : _extends({\n marginLeft: '14px'\n }, ownerState.touch && {\n marginLeft: '24px'\n })),\n [`.${tooltipClasses.popper}[data-popper-placement*=\"right\"] &`]: _extends({\n transformOrigin: 'left center'\n }, !ownerState.isRtl ? _extends({\n marginLeft: '14px'\n }, ownerState.touch && {\n marginLeft: '24px'\n }) : _extends({\n marginRight: '14px'\n }, ownerState.touch && {\n marginRight: '24px'\n })),\n [`.${tooltipClasses.popper}[data-popper-placement*=\"top\"] &`]: _extends({\n transformOrigin: 'center bottom',\n marginBottom: '14px'\n }, ownerState.touch && {\n marginBottom: '24px'\n }),\n [`.${tooltipClasses.popper}[data-popper-placement*=\"bottom\"] &`]: _extends({\n transformOrigin: 'center top',\n marginTop: '14px'\n }, ownerState.touch && {\n marginTop: '24px'\n })\n}));\nconst TooltipArrow = styled('span', {\n name: 'MuiTooltip',\n slot: 'Arrow',\n overridesResolver: (props, styles) => styles.arrow\n})(({\n theme\n}) => ({\n overflow: 'hidden',\n position: 'absolute',\n width: '1em',\n height: '0.71em' /* = width / sqrt(2) = (length of the hypotenuse) */,\n boxSizing: 'border-box',\n color: theme.vars ? theme.vars.palette.Tooltip.bg : alpha(theme.palette.grey[700], 0.9),\n '&::before': {\n content: '\"\"',\n margin: 'auto',\n display: 'block',\n width: '100%',\n height: '100%',\n backgroundColor: 'currentColor',\n transform: 'rotate(45deg)'\n }\n}));\nlet hystersisOpen = false;\nconst hystersisTimer = new Timeout();\nlet cursorPosition = {\n x: 0,\n y: 0\n};\nexport function testReset() {\n hystersisOpen = false;\n hystersisTimer.clear();\n}\nfunction composeEventHandler(handler, eventHandler) {\n return event => {\n if (eventHandler) {\n eventHandler(event);\n }\n handler(event);\n };\n}\n\n// TODO v6: Remove PopperComponent, PopperProps, TransitionComponent and TransitionProps.\nconst Tooltip = /*#__PURE__*/React.forwardRef(function Tooltip(inProps, ref) {\n var _ref, _slots$popper, _ref2, _ref3, _slots$transition, _ref4, _slots$tooltip, _ref5, _slots$arrow, _slotProps$popper, _ref6, _slotProps$popper2, _slotProps$transition, _slotProps$tooltip, _ref7, _slotProps$tooltip2, _slotProps$arrow, _ref8, _slotProps$arrow2;\n const props = useThemeProps({\n props: inProps,\n name: 'MuiTooltip'\n });\n const {\n arrow = false,\n children: childrenProp,\n components = {},\n componentsProps = {},\n describeChild = false,\n disableFocusListener = false,\n disableHoverListener = false,\n disableInteractive: disableInteractiveProp = false,\n disableTouchListener = false,\n enterDelay = 100,\n enterNextDelay = 0,\n enterTouchDelay = 700,\n followCursor = false,\n id: idProp,\n leaveDelay = 0,\n leaveTouchDelay = 1500,\n onClose,\n onOpen,\n open: openProp,\n placement = 'bottom',\n PopperComponent: PopperComponentProp,\n PopperProps = {},\n slotProps = {},\n slots = {},\n title,\n TransitionComponent: TransitionComponentProp = Grow,\n TransitionProps\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n\n // to prevent runtime errors, developers will need to provide a child as a React element anyway.\n const children = /*#__PURE__*/React.isValidElement(childrenProp) ? childrenProp : /*#__PURE__*/_jsx(\"span\", {\n children: childrenProp\n });\n const theme = useTheme();\n const isRtl = theme.direction === 'rtl';\n const [childNode, setChildNode] = React.useState();\n const [arrowRef, setArrowRef] = React.useState(null);\n const ignoreNonTouchEvents = React.useRef(false);\n const disableInteractive = disableInteractiveProp || followCursor;\n const closeTimer = useTimeout();\n const enterTimer = useTimeout();\n const leaveTimer = useTimeout();\n const touchTimer = useTimeout();\n const [openState, setOpenState] = useControlled({\n controlled: openProp,\n default: false,\n name: 'Tooltip',\n state: 'open'\n });\n let open = openState;\n if (process.env.NODE_ENV !== 'production') {\n // eslint-disable-next-line react-hooks/rules-of-hooks\n const {\n current: isControlled\n } = React.useRef(openProp !== undefined);\n\n // eslint-disable-next-line react-hooks/rules-of-hooks\n React.useEffect(() => {\n if (childNode && childNode.disabled && !isControlled && title !== '' && childNode.tagName.toLowerCase() === 'button') {\n console.error(['MUI: You are providing a disabled `button` child to the Tooltip component.', 'A disabled element does not fire events.', \"Tooltip needs to listen to the child element's events to display the title.\", '', 'Add a simple wrapper element, such as a `span`.'].join('\\n'));\n }\n }, [title, childNode, isControlled]);\n }\n const id = useId(idProp);\n const prevUserSelect = React.useRef();\n const stopTouchInteraction = useEventCallback(() => {\n if (prevUserSelect.current !== undefined) {\n document.body.style.WebkitUserSelect = prevUserSelect.current;\n prevUserSelect.current = undefined;\n }\n touchTimer.clear();\n });\n React.useEffect(() => stopTouchInteraction, [stopTouchInteraction]);\n const handleOpen = event => {\n hystersisTimer.clear();\n hystersisOpen = true;\n\n // The mouseover event will trigger for every nested element in the tooltip.\n // We can skip rerendering when the tooltip is already open.\n // We are using the mouseover event instead of the mouseenter event to fix a hide/show issue.\n setOpenState(true);\n if (onOpen && !open) {\n onOpen(event);\n }\n };\n const handleClose = useEventCallback(\n /**\n * @param {React.SyntheticEvent | Event} event\n */\n event => {\n hystersisTimer.start(800 + leaveDelay, () => {\n hystersisOpen = false;\n });\n setOpenState(false);\n if (onClose && open) {\n onClose(event);\n }\n closeTimer.start(theme.transitions.duration.shortest, () => {\n ignoreNonTouchEvents.current = false;\n });\n });\n const handleEnter = event => {\n if (ignoreNonTouchEvents.current && event.type !== 'touchstart') {\n return;\n }\n\n // Remove the title ahead of time.\n // We don't want to wait for the next render commit.\n // We would risk displaying two tooltips at the same time (native + this one).\n if (childNode) {\n childNode.removeAttribute('title');\n }\n enterTimer.clear();\n leaveTimer.clear();\n if (enterDelay || hystersisOpen && enterNextDelay) {\n enterTimer.start(hystersisOpen ? enterNextDelay : enterDelay, () => {\n handleOpen(event);\n });\n } else {\n handleOpen(event);\n }\n };\n const handleLeave = event => {\n enterTimer.clear();\n leaveTimer.start(leaveDelay, () => {\n handleClose(event);\n });\n };\n const {\n isFocusVisibleRef,\n onBlur: handleBlurVisible,\n onFocus: handleFocusVisible,\n ref: focusVisibleRef\n } = useIsFocusVisible();\n // We don't necessarily care about the focusVisible state (which is safe to access via ref anyway).\n // We just need to re-render the Tooltip if the focus-visible state changes.\n const [, setChildIsFocusVisible] = React.useState(false);\n const handleBlur = event => {\n handleBlurVisible(event);\n if (isFocusVisibleRef.current === false) {\n setChildIsFocusVisible(false);\n handleLeave(event);\n }\n };\n const handleFocus = event => {\n // Workaround for https://github.com/facebook/react/issues/7769\n // The autoFocus of React might trigger the event before the componentDidMount.\n // We need to account for this eventuality.\n if (!childNode) {\n setChildNode(event.currentTarget);\n }\n handleFocusVisible(event);\n if (isFocusVisibleRef.current === true) {\n setChildIsFocusVisible(true);\n handleEnter(event);\n }\n };\n const detectTouchStart = event => {\n ignoreNonTouchEvents.current = true;\n const childrenProps = children.props;\n if (childrenProps.onTouchStart) {\n childrenProps.onTouchStart(event);\n }\n };\n const handleMouseOver = handleEnter;\n const handleMouseLeave = handleLeave;\n const handleTouchStart = event => {\n detectTouchStart(event);\n leaveTimer.clear();\n closeTimer.clear();\n stopTouchInteraction();\n prevUserSelect.current = document.body.style.WebkitUserSelect;\n // Prevent iOS text selection on long-tap.\n document.body.style.WebkitUserSelect = 'none';\n touchTimer.start(enterTouchDelay, () => {\n document.body.style.WebkitUserSelect = prevUserSelect.current;\n handleEnter(event);\n });\n };\n const handleTouchEnd = event => {\n if (children.props.onTouchEnd) {\n children.props.onTouchEnd(event);\n }\n stopTouchInteraction();\n leaveTimer.start(leaveTouchDelay, () => {\n handleClose(event);\n });\n };\n React.useEffect(() => {\n if (!open) {\n return undefined;\n }\n\n /**\n * @param {KeyboardEvent} nativeEvent\n */\n function handleKeyDown(nativeEvent) {\n // IE11, Edge (prior to using Bink?) use 'Esc'\n if (nativeEvent.key === 'Escape' || nativeEvent.key === 'Esc') {\n handleClose(nativeEvent);\n }\n }\n document.addEventListener('keydown', handleKeyDown);\n return () => {\n document.removeEventListener('keydown', handleKeyDown);\n };\n }, [handleClose, open]);\n const handleRef = useForkRef(children.ref, focusVisibleRef, setChildNode, ref);\n\n // There is no point in displaying an empty tooltip.\n // So we exclude all falsy values, except 0, which is valid.\n if (!title && title !== 0) {\n open = false;\n }\n const popperRef = React.useRef();\n const handleMouseMove = event => {\n const childrenProps = children.props;\n if (childrenProps.onMouseMove) {\n childrenProps.onMouseMove(event);\n }\n cursorPosition = {\n x: event.clientX,\n y: event.clientY\n };\n if (popperRef.current) {\n popperRef.current.update();\n }\n };\n const nameOrDescProps = {};\n const titleIsString = typeof title === 'string';\n if (describeChild) {\n nameOrDescProps.title = !open && titleIsString && !disableHoverListener ? title : null;\n nameOrDescProps['aria-describedby'] = open ? id : null;\n } else {\n nameOrDescProps['aria-label'] = titleIsString ? title : null;\n nameOrDescProps['aria-labelledby'] = open && !titleIsString ? id : null;\n }\n const childrenProps = _extends({}, nameOrDescProps, other, children.props, {\n className: clsx(other.className, children.props.className),\n onTouchStart: detectTouchStart,\n ref: handleRef\n }, followCursor ? {\n onMouseMove: handleMouseMove\n } : {});\n if (process.env.NODE_ENV !== 'production') {\n childrenProps['data-mui-internal-clone-element'] = true;\n\n // eslint-disable-next-line react-hooks/rules-of-hooks\n React.useEffect(() => {\n if (childNode && !childNode.getAttribute('data-mui-internal-clone-element')) {\n console.error(['MUI: The `children` component of the Tooltip is not forwarding its props correctly.', 'Please make sure that props are spread on the same element that the ref is applied to.'].join('\\n'));\n }\n }, [childNode]);\n }\n const interactiveWrapperListeners = {};\n if (!disableTouchListener) {\n childrenProps.onTouchStart = handleTouchStart;\n childrenProps.onTouchEnd = handleTouchEnd;\n }\n if (!disableHoverListener) {\n childrenProps.onMouseOver = composeEventHandler(handleMouseOver, childrenProps.onMouseOver);\n childrenProps.onMouseLeave = composeEventHandler(handleMouseLeave, childrenProps.onMouseLeave);\n if (!disableInteractive) {\n interactiveWrapperListeners.onMouseOver = handleMouseOver;\n interactiveWrapperListeners.onMouseLeave = handleMouseLeave;\n }\n }\n if (!disableFocusListener) {\n childrenProps.onFocus = composeEventHandler(handleFocus, childrenProps.onFocus);\n childrenProps.onBlur = composeEventHandler(handleBlur, childrenProps.onBlur);\n if (!disableInteractive) {\n interactiveWrapperListeners.onFocus = handleFocus;\n interactiveWrapperListeners.onBlur = handleBlur;\n }\n }\n if (process.env.NODE_ENV !== 'production') {\n if (children.props.title) {\n console.error(['MUI: You have provided a `title` prop to the child of .', `Remove this title prop \\`${children.props.title}\\` or the Tooltip component.`].join('\\n'));\n }\n }\n const popperOptions = React.useMemo(() => {\n var _PopperProps$popperOp;\n let tooltipModifiers = [{\n name: 'arrow',\n enabled: Boolean(arrowRef),\n options: {\n element: arrowRef,\n padding: 4\n }\n }];\n if ((_PopperProps$popperOp = PopperProps.popperOptions) != null && _PopperProps$popperOp.modifiers) {\n tooltipModifiers = tooltipModifiers.concat(PopperProps.popperOptions.modifiers);\n }\n return _extends({}, PopperProps.popperOptions, {\n modifiers: tooltipModifiers\n });\n }, [arrowRef, PopperProps]);\n const ownerState = _extends({}, props, {\n isRtl,\n arrow,\n disableInteractive,\n placement,\n PopperComponentProp,\n touch: ignoreNonTouchEvents.current\n });\n const classes = useUtilityClasses(ownerState);\n const PopperComponent = (_ref = (_slots$popper = slots.popper) != null ? _slots$popper : components.Popper) != null ? _ref : TooltipPopper;\n const TransitionComponent = (_ref2 = (_ref3 = (_slots$transition = slots.transition) != null ? _slots$transition : components.Transition) != null ? _ref3 : TransitionComponentProp) != null ? _ref2 : Grow;\n const TooltipComponent = (_ref4 = (_slots$tooltip = slots.tooltip) != null ? _slots$tooltip : components.Tooltip) != null ? _ref4 : TooltipTooltip;\n const ArrowComponent = (_ref5 = (_slots$arrow = slots.arrow) != null ? _slots$arrow : components.Arrow) != null ? _ref5 : TooltipArrow;\n const popperProps = appendOwnerState(PopperComponent, _extends({}, PopperProps, (_slotProps$popper = slotProps.popper) != null ? _slotProps$popper : componentsProps.popper, {\n className: clsx(classes.popper, PopperProps == null ? void 0 : PopperProps.className, (_ref6 = (_slotProps$popper2 = slotProps.popper) != null ? _slotProps$popper2 : componentsProps.popper) == null ? void 0 : _ref6.className)\n }), ownerState);\n const transitionProps = appendOwnerState(TransitionComponent, _extends({}, TransitionProps, (_slotProps$transition = slotProps.transition) != null ? _slotProps$transition : componentsProps.transition), ownerState);\n const tooltipProps = appendOwnerState(TooltipComponent, _extends({}, (_slotProps$tooltip = slotProps.tooltip) != null ? _slotProps$tooltip : componentsProps.tooltip, {\n className: clsx(classes.tooltip, (_ref7 = (_slotProps$tooltip2 = slotProps.tooltip) != null ? _slotProps$tooltip2 : componentsProps.tooltip) == null ? void 0 : _ref7.className)\n }), ownerState);\n const tooltipArrowProps = appendOwnerState(ArrowComponent, _extends({}, (_slotProps$arrow = slotProps.arrow) != null ? _slotProps$arrow : componentsProps.arrow, {\n className: clsx(classes.arrow, (_ref8 = (_slotProps$arrow2 = slotProps.arrow) != null ? _slotProps$arrow2 : componentsProps.arrow) == null ? void 0 : _ref8.className)\n }), ownerState);\n return /*#__PURE__*/_jsxs(React.Fragment, {\n children: [/*#__PURE__*/React.cloneElement(children, childrenProps), /*#__PURE__*/_jsx(PopperComponent, _extends({\n as: PopperComponentProp != null ? PopperComponentProp : Popper,\n placement: placement,\n anchorEl: followCursor ? {\n getBoundingClientRect: () => ({\n top: cursorPosition.y,\n left: cursorPosition.x,\n right: cursorPosition.x,\n bottom: cursorPosition.y,\n width: 0,\n height: 0\n })\n } : childNode,\n popperRef: popperRef,\n open: childNode ? open : false,\n id: id,\n transition: true\n }, interactiveWrapperListeners, popperProps, {\n popperOptions: popperOptions,\n children: ({\n TransitionProps: TransitionPropsInner\n }) => /*#__PURE__*/_jsx(TransitionComponent, _extends({\n timeout: theme.transitions.duration.shorter\n }, TransitionPropsInner, transitionProps, {\n children: /*#__PURE__*/_jsxs(TooltipComponent, _extends({}, tooltipProps, {\n children: [title, arrow ? /*#__PURE__*/_jsx(ArrowComponent, _extends({}, tooltipArrowProps, {\n ref: setArrowRef\n })) : null]\n }))\n }))\n }))]\n });\n});\nprocess.env.NODE_ENV !== \"production\" ? Tooltip.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the d.ts file and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * If `true`, adds an arrow to the tooltip.\n * @default false\n */\n arrow: PropTypes.bool,\n /**\n * Tooltip reference element.\n */\n children: elementAcceptingRef.isRequired,\n /**\n * Override or extend the styles applied to the component.\n */\n classes: PropTypes.object,\n /**\n * @ignore\n */\n className: PropTypes.string,\n /**\n * The components used for each slot inside.\n *\n * This prop is an alias for the `slots` prop.\n * It's recommended to use the `slots` prop instead.\n *\n * @default {}\n */\n components: PropTypes.shape({\n Arrow: PropTypes.elementType,\n Popper: PropTypes.elementType,\n Tooltip: PropTypes.elementType,\n Transition: PropTypes.elementType\n }),\n /**\n * The extra props for the slot components.\n * You can override the existing props or add new ones.\n *\n * This prop is an alias for the `slotProps` prop.\n * It's recommended to use the `slotProps` prop instead, as `componentsProps` will be deprecated in the future.\n *\n * @default {}\n */\n componentsProps: PropTypes.shape({\n arrow: PropTypes.object,\n popper: PropTypes.object,\n tooltip: PropTypes.object,\n transition: PropTypes.object\n }),\n /**\n * Set to `true` if the `title` acts as an accessible description.\n * By default the `title` acts as an accessible label for the child.\n * @default false\n */\n describeChild: PropTypes.bool,\n /**\n * Do not respond to focus-visible events.\n * @default false\n */\n disableFocusListener: PropTypes.bool,\n /**\n * Do not respond to hover events.\n * @default false\n */\n disableHoverListener: PropTypes.bool,\n /**\n * Makes a tooltip not interactive, i.e. it will close when the user\n * hovers over the tooltip before the `leaveDelay` is expired.\n * @default false\n */\n disableInteractive: PropTypes.bool,\n /**\n * Do not respond to long press touch events.\n * @default false\n */\n disableTouchListener: PropTypes.bool,\n /**\n * The number of milliseconds to wait before showing the tooltip.\n * This prop won't impact the enter touch delay (`enterTouchDelay`).\n * @default 100\n */\n enterDelay: PropTypes.number,\n /**\n * The number of milliseconds to wait before showing the tooltip when one was already recently opened.\n * @default 0\n */\n enterNextDelay: PropTypes.number,\n /**\n * The number of milliseconds a user must touch the element before showing the tooltip.\n * @default 700\n */\n enterTouchDelay: PropTypes.number,\n /**\n * If `true`, the tooltip follow the cursor over the wrapped element.\n * @default false\n */\n followCursor: PropTypes.bool,\n /**\n * This prop is used to help implement the accessibility logic.\n * If you don't provide this prop. It falls back to a randomly generated id.\n */\n id: PropTypes.string,\n /**\n * The number of milliseconds to wait before hiding the tooltip.\n * This prop won't impact the leave touch delay (`leaveTouchDelay`).\n * @default 0\n */\n leaveDelay: PropTypes.number,\n /**\n * The number of milliseconds after the user stops touching an element before hiding the tooltip.\n * @default 1500\n */\n leaveTouchDelay: PropTypes.number,\n /**\n * Callback fired when the component requests to be closed.\n *\n * @param {React.SyntheticEvent} event The event source of the callback.\n */\n onClose: PropTypes.func,\n /**\n * Callback fired when the component requests to be open.\n *\n * @param {React.SyntheticEvent} event The event source of the callback.\n */\n onOpen: PropTypes.func,\n /**\n * If `true`, the component is shown.\n */\n open: PropTypes.bool,\n /**\n * Tooltip placement.\n * @default 'bottom'\n */\n placement: PropTypes.oneOf(['bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n /**\n * The component used for the popper.\n * @default Popper\n */\n PopperComponent: PropTypes.elementType,\n /**\n * Props applied to the [`Popper`](/material-ui/api/popper/) element.\n * @default {}\n */\n PopperProps: PropTypes.object,\n /**\n * The extra props for the slot components.\n * You can override the existing props or add new ones.\n *\n * This prop is an alias for the `componentsProps` prop, which will be deprecated in the future.\n *\n * @default {}\n */\n slotProps: PropTypes.shape({\n arrow: PropTypes.object,\n popper: PropTypes.object,\n tooltip: PropTypes.object,\n transition: PropTypes.object\n }),\n /**\n * The components used for each slot inside.\n *\n * This prop is an alias for the `components` prop, which will be deprecated in the future.\n *\n * @default {}\n */\n slots: PropTypes.shape({\n arrow: PropTypes.elementType,\n popper: PropTypes.elementType,\n tooltip: PropTypes.elementType,\n transition: PropTypes.elementType\n }),\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Tooltip title. Zero-length titles string, undefined, null and false are never displayed.\n */\n title: PropTypes.node,\n /**\n * The component used for the transition.\n * [Follow this guide](/material-ui/transitions/#transitioncomponent-prop) to learn more about the requirements for this component.\n * @default Grow\n */\n TransitionComponent: PropTypes.elementType,\n /**\n * Props applied to the transition element.\n * By default, the element is based on this [`Transition`](http://reactcommunity.org/react-transition-group/transition/) component.\n */\n TransitionProps: PropTypes.object\n} : void 0;\nexport default Tooltip;","import '@/components/mui/menu-item.component.css';\nimport ArrowRightIcon from '@mui/icons-material/ArrowRight';\nimport {\n ListItemIcon as MuiListItemIcon,\n ListItemText as MuiListItemText,\n MenuItem as MuiMenuItem,\n} from '@mui/material';\nimport Tooltip from '@mui/material/Tooltip';\nimport { Localized, ReferencedItem, SingleColumnMenu } from 'platform-bible-utils';\nimport { MouseEvent, PropsWithChildren } from 'react';\n\ntype MenuItemInfoBase = {\n /** Text (displayable in the UI) as the name of the menu item */\n label: string;\n /** Text to display when the mouse hovers over the menu item */\n tooltip?: string;\n};\n\nexport type Command = MenuItemInfoBase & {\n /** Command to execute (string.string) */\n command: string;\n};\n\ntype SubMenu = MenuItemInfoBase & {\n /** Command to execute (string.string) */\n items: MenuItemInfo[];\n};\n\nexport interface CommandHandler {\n (command: Command): void;\n}\n\nexport type MenuPropsBase = {\n /*\n * The JSON defining the menu whose items are to be rendered. This will typically be one of the\n * menus in the \"defs\" in a Platform.Bible menu (see PlatformMenus). The schema for this is\n * menuDocumentSchema (at the end of menus.model.ts). Note that while this is a\n * \"SingleColumnMenu\", somewhat bizarrely, a MultiColumnMenu is a SingleColumnMenu, so it really\n * could be a MultiColumnMenu, in which case, column had better be defined so it can be used\n * to filter out the actual groups and items to display on the column.\n */\n menuDefinition: Localized;\n\n commandHandler: CommandHandler;\n\n /**\n * Additional action to perform when any menu item is clicked. Allows the caller to handle event\n * (e.g., to close the menu).\n */\n onClick?: (event: MouseEvent) => void;\n};\n\nexport type MenuItemListProps = MenuPropsBase & {\n /** Optional unique (column) identifier */\n columnId?: ReferencedItem;\n};\n\nexport type MenuItemProps = Omit &\n PropsWithChildren<{\n /** Optional unique identifier */\n id?: string;\n\n onClick: (event: MouseEvent) => void;\n }>;\n\ntype MenuItemInfo = (Command | SubMenu) & {\n /**\n * If specified, menu item will be inset if it does not have a leading icon.\n *\n * @default true\n */\n allowForLeadingIcons?: boolean;\n /**\n * If specified, the path to the icon image to display on the leading side of the menu text.\n *\n * @default undefined (no leading icon will be shown)\n */\n iconPathBefore?: string;\n /**\n * If specified, the path to the icon image to display on the trailing side of the menu text.\n *\n * @default undefined (no trailing icon will be shown)\n */\n iconPathAfter?: string;\n /**\n * If true, list item is focused during the first mount\n *\n * @default false\n */\n hasAutoFocus?: boolean;\n\n /** Additional css classes to help with unique styling of the menu item */\n className?: string;\n\n /**\n * If true, the menu item will appear disabled and it will not respond to clicks or mouse hovers.\n *\n * @default false\n */\n isDisabled?: boolean;\n\n /**\n * If true, compact vertical padding designed for keyboard and mouse input is used.\n *\n * @default true\n */\n isDense?: boolean;\n\n /**\n * If true, a right-arrow icon will be displayed (iconPathAfter, if specified, will be ignored).\n *\n * @default false\n */\n isSubMenuParent?: boolean;\n\n /**\n * If true, the left and right padding is removed\n *\n * @default false\n */\n hasDisabledGutters?: boolean;\n\n /**\n * If true, a 1px light border is added to bottom of menu item\n *\n * @default false\n */\n hasDivider?: boolean;\n\n /** Help identify which element has keyboard focus */\n focusVisibleClassName?: string;\n\n /** If it's a submenu, it should have the items property */\n items?: MenuItemInfo[];\n};\n\nfunction getIcon(icon: string | undefined, menuLabel: string, leading: boolean) {\n return icon ? (\n \n {`${leading\n \n ) : undefined;\n}\n\nexport default function MenuItem(props: MenuItemProps) {\n const {\n onClick,\n label,\n tooltip,\n allowForLeadingIcons = true,\n iconPathBefore = undefined,\n iconPathAfter = undefined,\n hasAutoFocus = false,\n className,\n isDisabled = false,\n isDense = true,\n isSubMenuParent = false,\n hasDisabledGutters = false,\n hasDivider = false,\n focusVisibleClassName,\n id,\n children,\n } = props;\n\n const menuItem = (\n \n {label ? (\n <>\n {getIcon(iconPathBefore, label, true)}\n \n {isSubMenuParent ? (\n \n \n \n ) : (\n getIcon(iconPathAfter, label, false)\n )}\n \n ) : (\n children\n )}\n \n );\n\n return tooltip ? (\n \n
    {menuItem}
    \n
    \n ) : (\n menuItem\n );\n}\n","import MenuItem, {\n MenuItemListProps,\n MenuItemProps,\n MenuPropsBase,\n} from '@/components/mui/menu-item.component';\nimport { Menu } from '@mui/material';\nimport {\n Localized,\n MenuGroupDetailsInSubMenu,\n MenuItemContainingCommand,\n MenuItemContainingSubmenu,\n OrderedExtensibleContainer,\n ReferencedItem,\n SingleColumnMenu,\n} from 'platform-bible-utils';\nimport { MouseEvent, useMemo, useState } from 'react';\n\n/**\n * All the exported types in this file should be regarded as \"internal\" (i.e., they should not be\n * exposed via index.ts).\n */\n\nexport type GroupedMenuPropsBase = MenuPropsBase & {\n /** Optional unique (column) identifier */\n columnId?: ReferencedItem;\n};\n\nexport type GroupedMenuItemListProps = MenuItemListProps & {\n /**\n * If the menuDefinition includes \"top-level\" groups (i.e., those that belong to a column as\n * opposed to those that belong to a submenu) that should not be included in the list, then this\n * array specifies which groups to include. Likewise, for a submenu, this list indicates which\n * groups are pertinent for that submenu. So then for a context menu this property need not be\n * specified since it is a top-level menu based on a \"true\" SingleColumnMenu (i.e., one that is\n * not a MultiColumnMenu).\n */\n includedGroups?: {\n id: string;\n group: Localized;\n }[];\n};\n\ninterface ItemInfo {\n item: Localized;\n isLastItemInGroup: boolean;\n}\n\ntype SubMenuProps = MenuPropsBase & {\n parentMenuItem: Localized;\n parentItemProps: Omit, 'iconPathAfter'>;\n};\n\nfunction getAllGroups(menuDefinition: Localized) {\n const groupEntries = Object.entries(menuDefinition.groups);\n // Convert array of entries to array of objects with id and group properties\n return groupEntries.map(([key, value]) => ({ id: key, group: value }));\n}\n\nfunction SubMenu(props: SubMenuProps) {\n const [anchorEl, setAnchorEl] = useState(undefined);\n\n const { parentMenuItem, parentItemProps, menuDefinition } = props;\n\n const handleParentMenuItemClick = (event: MouseEvent) => {\n setAnchorEl(event.currentTarget);\n };\n\n const handleClose = () => {\n setAnchorEl(undefined);\n };\n\n const renderSubMenuItems = () => {\n let includedGroups = getAllGroups(menuDefinition).filter((g) => 'menuItem' in g.group);\n\n // Ensure valid parent menu was provided. (If not, submenu will contain all groups!)\n if (!parentMenuItem?.id) throw new Error('A valid parent menu item is required for submenus.');\n\n // When laying out a submenu, only include groups associated with the provided parent menu.\n // Note: without the (annoying) redundant check that the included groups\n // have the menuItem field, TS doesn't think it exists.\n includedGroups = includedGroups.filter(\n (group) => 'menuItem' in group.group && group.group.menuItem === parentMenuItem.id,\n );\n\n return ;\n };\n\n return (\n <>\n \n \n {renderSubMenuItems()}\n \n \n );\n}\n\nconst getOrderedGroupItems = (\n groupId: string,\n allItems: Localized[],\n) => {\n // Filter items that belong to the specified group\n const itemsForGroup = allItems.filter((item) => item.group === groupId);\n // Sort items based on order\n const sortedItems = itemsForGroup.sort((a, b) => (a.order || 0) - (b.order || 0));\n return sortedItems;\n};\n\n/**\n * This component is internal; it does not need to be exposed to the outside world since it is not\n * useful on its own. It is used to generate and lay out the MenuItems that appear either on a\n * top-level menu (in a GridMenu or ContextMenu) or in a submenu.\n */\nexport default function GroupedMenuItemList(menuProps: GroupedMenuItemListProps) {\n const { menuDefinition, onClick, commandHandler, includedGroups } = menuProps;\n\n const { items, allowForLeadingIcons } = useMemo(() => {\n const groupsToInclude =\n includedGroups && includedGroups.length > 0\n ? includedGroups\n : // We're apparently laying out a single-column menu (presumably a context menu). In this\n // case, all groups should be included except ones that belong to a submenu.\n getAllGroups(menuDefinition).filter((g) => !('menuItem' in g.group));\n\n const sortedGroups = Object.values(groupsToInclude).sort(\n (a, b) => (a.group.order || 0) - (b.group.order || 0),\n );\n\n const itemArray: ItemInfo[] = [];\n\n sortedGroups.forEach((group) => {\n getOrderedGroupItems(group.id, menuDefinition.items).forEach((item) =>\n itemArray.push({ item, isLastItemInGroup: false }),\n );\n if (itemArray.length > 0) itemArray[itemArray.length - 1].isLastItemInGroup = true;\n });\n\n // No divider after last item in final group.\n if (itemArray.length > 0) itemArray[itemArray.length - 1].isLastItemInGroup = false;\n\n const allowSpaceForLeadingIcons = itemArray.some(\n (i) => 'iconPathBefore' in i.item && i.item.iconPathBefore,\n );\n\n return { items: itemArray, allowForLeadingIcons: allowSpaceForLeadingIcons };\n }, [includedGroups, menuDefinition]);\n\n // Create props for MenuItem component including setting hasDivider for the last item in a group\n const createMenuItemProps = ({ item, isLastItemInGroup }: ItemInfo) => {\n const menuItemProps = {\n className: 'papi-menu-item',\n label: item.label,\n tooltip: item.tooltip,\n iconPathBefore: 'iconPathBefore' in item ? item.iconPathBefore : undefined,\n iconPathAfter: 'iconPathAfter' in item ? item.iconPathAfter : undefined,\n hasDivider: isLastItemInGroup, // Set hasDivider to true for the last item in a group\n allowForLeadingIcons,\n };\n\n return menuItemProps;\n };\n\n const [firstItem] = items;\n\n if (!firstItem) return
    ;\n\n const divKey = firstItem.item.group;\n\n return (\n
    \n {items.map((itemInfo, index) => {\n const { item } = itemInfo;\n const menuItemProps = createMenuItemProps(itemInfo);\n if ('command' in item) {\n const key = item.group + index;\n return (\n ) => {\n onClick?.(event);\n commandHandler(item);\n }}\n {...menuItemProps}\n />\n );\n }\n return (\n \n );\n })}\n
    \n );\n}\n","import GroupedMenuItemList from '@/components/mui/grouped-menu-item-list.component';\nimport { MenuItemListProps } from '@/components/mui/menu-item.component';\nimport { MultiColumnMenu } from 'platform-bible-utils';\n\n/**\n * This component is internal; it does not need to be exposed to the outside world since it is not\n * useful on its own. Use either GridMenu or ContextMenu.\n */\nexport default function TopLevelMenu(props: MenuItemListProps) {\n const { menuDefinition, columnId } = props;\n\n const groupEntries = Object.entries(menuDefinition.groups);\n // Convert array of entries to array of objects with id and group properties\n const groups = groupEntries.map(([key, value]) => ({ id: key, group: value }));\n let includedGroups = groups.filter((g) => 'column' in g.group);\n\n // Check if column is provided and menuDefinition is a MultiColumnMenu\n if (\n columnId &&\n 'columns' in menuDefinition &&\n // Without this type assertion, TS doesn't know what columns is.\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n (menuDefinition as MultiColumnMenu).columns[columnId]\n ) {\n // When laying out a single column in a MultiColumnMenu, only include groups associated with\n // the provided column. Note: without the (annoying) redundant check that the included groups\n // have the colum field, TS doesn't think it exists.\n includedGroups = includedGroups.filter(\n (g) => 'column' in g.group && g.group.column === columnId,\n );\n }\n\n return ;\n}\n","import '@/components/mui/grid-menu.component.css';\nimport { GroupedMenuPropsBase } from '@/components/mui/grouped-menu-item-list.component';\nimport { CommandHandler } from '@/components/mui/menu-item.component';\nimport TopLevelMenu from '@/components/mui/top-level-menu.component';\nimport { Grid, List } from '@mui/material';\nimport {\n Localized,\n MenuColumnWithHeader,\n MultiColumnMenu,\n ReferencedItem,\n} from 'platform-bible-utils';\nimport { useMemo } from 'react';\n\ntype ColumnInfo = {\n /*\n * The ID (`${string}.${string}`) of a specific menu column.\n */\n id: ReferencedItem;\n\n /*\n * Metadata (label, order, etc.) for a specific menu column.\n */\n metadata: Localized;\n};\n\ntype MenuColumnProps = ColumnInfo &\n GroupedMenuPropsBase & {\n /** Additional css classes to help with unique styling of the menu column */\n className?: string;\n };\n\nexport type GridMenuInfo = {\n /** The menu object containing information about the columns, groups, and items to display. */\n multiColumnMenu: Localized;\n};\n\nexport type GridMenuProps = GridMenuInfo & {\n /** Optional unique identifier */\n id?: string;\n\n commandHandler: CommandHandler;\n\n /** Additional css classes to help with unique styling of the grid menu */\n className?: string;\n};\n\nfunction MenuColumn({\n commandHandler,\n menuDefinition,\n id,\n metadata,\n onClick,\n className,\n}: MenuColumnProps) {\n return (\n \n

    \n {metadata.label}\n

    \n {/* It would seem as though this List component were unnecessary, since it only contains one\n thing, but the \"dense\" property does affect the layout of the items (in a way I don't fully\n understand). There might be a better way. */}\n \n \n \n \n );\n}\n\nexport default function GridMenu({\n commandHandler,\n className,\n multiColumnMenu,\n id,\n}: GridMenuProps) {\n const { columns } = multiColumnMenu;\n\n const sortedColumns = useMemo(() => {\n const columnNumbers = new Map();\n Object.getOwnPropertyNames(columns).forEach((columnName: string) => {\n // We know for sure there is a (boolean) property 'isExtensible' that we are not interested in.\n if (columnName === 'isExtensible') return;\n // TS doesn't allow `columnName` above to be a ReferencedItem even though the type says it is\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const columnId = columnName as ReferencedItem;\n const column = columns[columnId];\n // As of right now (and hopefully forever after), all remaining properties of the\n // ColumnsWithHeaders object are columns whose property names are the IDs of the columns.\n // This is an additional (redundant) sanity check. Specifically we're interested in\n // MenuColumnWithHeader objects, which TypeScript now \"knows\" we have, but at runtime all we\n // can check for is that it's an object with a valid numeric order field. That's likely good\n // enough.\n if (\n typeof column === 'object' &&\n typeof column.order === 'number' &&\n !Number.isNaN(column.order)\n )\n columnNumbers.set(column.order, { id: columnId, metadata: column });\n else\n console.warn(\n `Property ${columnName} (${typeof column}) on menu ${id} is not a valid column and is being ignored. This might indicate data corruption`,\n );\n });\n\n // Extract values and sort them based on the 'order' property\n return Array.from(columnNumbers.values()).sort((a, b) => {\n return (a.metadata.order || 0) - (b.metadata.order || 0);\n });\n }, [columns, id]);\n\n // We might need something like this if we need to be able to prevent empty columns\n // sortedColumns.filter((c) => multiColumnMenu.groups.some((g) => 'column' in g && (g as .column)...\n\n return (\n \n {sortedColumns.map((col, index) => (\n \n ))}\n \n );\n}\n","import { useEffect, useRef, useState } from 'react';\n\nexport type UsePromiseOptions = {\n /**\n * Whether to leave the value as the most recent resolved promise value or set it back to\n * defaultValue while running the promise again. Defaults to true\n */\n preserveValue?: boolean;\n};\n\n/** Set up defaults for options for usePromise hook */\nfunction getUsePromiseOptionsDefaults(options: UsePromiseOptions): UsePromiseOptions {\n return {\n preserveValue: true,\n ...options,\n };\n}\n\n/**\n * Awaits a promise and returns a loading value while the promise is unresolved\n *\n * @param promiseFactoryCallback A function that returns the promise to await. If this callback is\n * undefined, the current value will be returned (defaultValue unless it was previously changed\n * and `options.preserveValue` is true), and there will be no loading.\n *\n * WARNING: MUST BE STABLE - const or wrapped in useCallback. The reference must not be updated\n * every render\n * @param defaultValue The initial value to return while first awaiting the promise. If\n * `options.preserveValue` is false, this value is also shown while awaiting the promise on\n * subsequent calls.\n *\n * Note: this parameter is internally assigned to a `ref`, so changing it will not cause any hooks\n * to re-run with its new value. This means that, if the `promiseFactoryCallback` changes and\n * `options.preserveValue` is `false`, the returned value will be set to the current\n * `defaultValue`. However, the returned value will not be updated if`defaultValue` changes.\n * @param options Various options for adjusting how this hook runs the `promiseFactoryCallback`\n *\n * Note: this parameter is internally assigned to a `ref`, so changing it will not cause any hooks\n * to re-run with its new value. However, the latest `options.preserveValue` will always be used\n * appropriately to determine whether to preserve the returned value when changing the\n * `promiseFactoryCallback`\n * @returns `[value, isLoading]`\n *\n * - `value`: the current value for the promise, either the defaultValue or the resolved promise value\n * - `isLoading`: whether the promise is waiting to be resolved\n */\nconst usePromise = (\n promiseFactoryCallback: (() => Promise) | undefined,\n defaultValue: T,\n options: UsePromiseOptions = {},\n): [value: T, isLoading: boolean] => {\n // Use defaultValue as a ref so it doesn't update dependency arrays\n const defaultValueRef = useRef(defaultValue);\n defaultValueRef.current = defaultValue;\n // Use options as a ref so it doesn't update dependency arrays\n const optionsDefaultedRef = useRef(options);\n optionsDefaultedRef.current = getUsePromiseOptionsDefaults(optionsDefaultedRef.current);\n\n const [value, setValue] = useState(() => defaultValueRef.current);\n const [isLoading, setIsLoading] = useState(true);\n useEffect(() => {\n let promiseIsCurrent = true;\n // If a promiseFactoryCallback was provided, we are loading. Otherwise, there is no loading to do\n setIsLoading(!!promiseFactoryCallback);\n (async () => {\n // If there is a callback to run, run it\n if (promiseFactoryCallback) {\n const result = await promiseFactoryCallback();\n // If the promise was not already replaced, update the value\n if (promiseIsCurrent) {\n setValue(() => result);\n setIsLoading(false);\n }\n }\n })();\n\n return () => {\n // Mark this promise as old and not to be used\n promiseIsCurrent = false;\n if (!optionsDefaultedRef.current.preserveValue) setValue(() => defaultValueRef.current);\n };\n }, [promiseFactoryCallback]);\n\n return [value, isLoading];\n};\nexport default usePromise;\n","\"use client\";\n\nimport createSvgIcon from './utils/createSvgIcon';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nexport default createSvgIcon( /*#__PURE__*/_jsx(\"path\", {\n d: \"M3 18h18v-2H3zm0-5h18v-2H3zm0-7v2h18V6z\"\n}), 'Menu');","import GridMenu from '@/components/mui/grid-menu.component';\nimport { Command, CommandHandler } from '@/components/mui/menu-item.component';\nimport usePromise from '@/hooks/use-promise.hook';\nimport { Menu as MenuIcon } from '@mui/icons-material';\nimport { Drawer, IconButton } from '@mui/material';\nimport { Localized, MultiColumnMenu } from 'platform-bible-utils';\nimport {\n MouseEvent,\n MutableRefObject,\n PropsWithChildren,\n useCallback,\n useEffect,\n useState,\n} from 'react';\n\nexport interface MultiColumnMenuProvider {\n (isSupportAndDevelopment: boolean): Promise>;\n}\n\nexport type HamburgerMenuButtonProps = PropsWithChildren & {\n /** The handler to use for menu commands (and eventually toolbar commands). */\n commandHandler: CommandHandler;\n\n /**\n * Optional reference to the \"div\" container that determines the where the menu should appear. If\n * not defined, then (1,1) used.\n */\n containerRef?: MutableRefObject;\n\n /**\n * The delegate to use to get the menu data. If not specified or if it returns undefined, the data\n * in normalMenu or fullMenu property will be used.\n */\n menuProvider?: MultiColumnMenuProvider;\n\n /**\n * The menu data to show when the menu is opened if the menuProvider property is not defined.\n * (This allows for a default or test-only static menu to be used.)\n */\n normalMenu?: Localized;\n\n /**\n * The menu data to show for \"full\" menu (when opened with the SHIFT key pressed) if the\n * menuProvider property is not defined. (This allows for a default or test-only static menu to be\n * used.)\n */\n fullMenu?: Localized;\n\n /** Additional css class(es) to help with unique styling of the sub-components */\n className?: string;\n\n /** Value to use as prefix for ARIA labels on interactive sub-components */\n ariaLabelPrefix?: string;\n};\n\nexport default function HamburgerMenuButton({\n menuProvider,\n normalMenu,\n fullMenu,\n commandHandler,\n containerRef,\n className,\n ariaLabelPrefix,\n children,\n}: HamburgerMenuButtonProps) {\n const [isMenuOpen, setMenuOpen] = useState(false);\n const [showFullMenu, setShowFullMenu] = useState(false);\n\n const handleMenuItemClick = useCallback(() => {\n if (isMenuOpen) setMenuOpen(false);\n setShowFullMenu(false);\n }, [isMenuOpen]);\n\n const handleMenuButtonClick = useCallback((e: MouseEvent) => {\n e.stopPropagation();\n setMenuOpen((prevIsOpen) => {\n const isOpening = !prevIsOpen;\n if (isOpening && e.shiftKey) setShowFullMenu(true);\n else if (!isOpening) setShowFullMenu(false);\n return isOpening;\n });\n }, []);\n\n const menuCommandHandler = useCallback(\n (command: Command) => {\n handleMenuItemClick();\n return commandHandler(command);\n },\n [commandHandler, handleMenuItemClick],\n );\n\n const [offset, setOffset] = useState({ top: 1, left: 1 });\n\n useEffect(() => {\n if (isMenuOpen) {\n const node = containerRef?.current;\n if (node) {\n const rect = node.getBoundingClientRect();\n const scrollTop = window.scrollY;\n const scrollLeft = window.scrollX;\n const top = rect.top + scrollTop + node.clientHeight;\n const left = rect.left + scrollLeft;\n setOffset({ top, left });\n }\n }\n }, [isMenuOpen, containerRef]);\n\n const [normalMenuData] = usePromise(\n useCallback(async () => {\n return menuProvider?.(false) ?? normalMenu;\n // isMenuOpen needs to be included for the menu contents to reevaluate when reopened\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [menuProvider, normalMenu, isMenuOpen]),\n normalMenu,\n );\n\n const [fullMenuData] = usePromise(\n useCallback(async () => {\n return menuProvider?.(true) ?? fullMenu ?? normalMenuData;\n // isMenuOpen needs to be included for the menu contents to reevaluate when reopened\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [menuProvider, fullMenu, normalMenuData, isMenuOpen]),\n fullMenu ?? normalMenuData,\n );\n\n const menu = showFullMenu && fullMenuData ? fullMenuData : normalMenuData;\n\n return (\n <>\n \n {children ?? }\n \n \n {menu ? (\n \n ) : undefined}\n \n \n );\n}\n","import '@/components/mui/icon-button.component.css';\nimport { IconButton as MuiIconButton } from '@mui/material';\nimport { MouseEventHandler, PropsWithChildren } from 'react';\n\nexport type IconButtonProps = PropsWithChildren<{\n /** Optional unique identifier */\n id?: string;\n /**\n * Required. Used as both the tooltip (aka, title) and the aria-label (used for accessibility,\n * testing, etc.), unless a distinct tooltip is supplied.\n */\n label: string;\n /**\n * Enabled status of button\n *\n * @default false\n */\n isDisabled?: boolean;\n /** Optional tooltip to display if different from the aria-label. */\n tooltip?: string;\n /** If true, no tooltip will be displayed. */\n isTooltipSuppressed?: boolean;\n /**\n * If given, uses a negative margin to counteract the padding on one side (this is often helpful\n * for aligning the left or right side of the icon with content above or below, without ruining\n * the border size and shape).\n *\n * @default false\n */\n adjustMarginToAlignToEdge?: 'end' | 'start' | false;\n /**\n * The size of the component. small is equivalent to the dense button styling.\n *\n * @default false\n */\n size: 'small' | 'medium' | 'large';\n /** Additional css classes to help with unique styling of the button */\n className?: string;\n /** Optional click handler */\n onClick?: MouseEventHandler;\n}>;\n\n/**\n * Iconic button a user can click to do something\n *\n * Thanks to MUI for heavy inspiration and documentation\n * https://mui.com/material-ui/getting-started/overview/\n */\nfunction IconButton({\n id,\n label,\n isDisabled = false,\n tooltip,\n isTooltipSuppressed = false,\n adjustMarginToAlignToEdge = false,\n size = 'medium',\n className,\n onClick,\n children,\n}: IconButtonProps) {\n return (\n \n {children /* the icon to display */}\n \n );\n}\n\nexport default IconButton;\n","import { cn } from '@/utils/shadcn-ui.util';\nimport { LoaderCircle, LucideProps } from 'lucide-react';\nimport { forwardRef } from 'react';\n\nexport type SpinnerProps = LucideProps;\n\nconst Spinner = forwardRef(({ className, ...props }, ref) => {\n return (\n \n );\n});\n\nSpinner.displayName = 'Spinner';\n\nexport default Spinner;\n","import { Input as ShadInput } from '@/components/shadcn-ui/input';\nimport { Label as ShadLabel } from '@/components/shadcn-ui/label';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { ChangeEventHandler, FocusEventHandler } from 'react';\n\nexport type TextFieldProps = {\n /** Optional unique identifier */\n id?: string;\n /**\n * If `true`, the component is disabled.\n *\n * @default false\n */\n isDisabled?: boolean;\n /**\n * If `true`, the label is displayed in an error state.\n *\n * @default false\n */\n hasError?: boolean;\n /**\n * If `true`, the input will take up the full width of its container.\n *\n * @default false\n */\n isFullWidth?: boolean;\n /** Text that gives the user instructions on what contents the TextField expects */\n helperText?: string;\n /** The title of the TextField */\n label?: string;\n /** The short hint displayed in the `input` before the user enters a value. */\n placeholder?: string;\n /**\n * If `true`, the label is displayed as required and the `input` element is required.\n *\n * @default false\n */\n isRequired?: boolean;\n /** Additional css classes to help with unique styling of the text field */\n className?: string;\n /** Starting value for the text field if it is not controlled */\n defaultValue?: string | number;\n /** Value of the text field if controlled */\n value?: string | number;\n /** Triggers when content of textfield is changed */\n onChange?: ChangeEventHandler;\n /** Triggers when textfield gets focus */\n onFocus?: FocusEventHandler;\n /** Triggers when textfield loses focus */\n onBlur?: FocusEventHandler;\n};\n\n/**\n * Text input field\n *\n * Thanks to Shadcn for heavy inspiration and documentation\n * https://ui.shadcn.com/docs/components/input#with-label\n */\nfunction TextField({\n id,\n isDisabled = false,\n hasError = false,\n isFullWidth = false,\n helperText,\n label,\n placeholder,\n isRequired = false,\n className,\n defaultValue,\n value,\n onChange,\n onFocus,\n onBlur,\n}: TextFieldProps) {\n return (\n
    \n {`${label}${isRequired ? '*' : ''}`}\n \n

    {helperText}

    \n
    \n );\n}\n\nexport default TextField;\n","import HamburgerMenuButton, {\n MultiColumnMenuProvider,\n} from '@/components/mui/hamburger-menu-button.component';\nimport { CommandHandler } from '@/components/mui/menu-item.component';\nimport '@/components/mui/toolbar.component.css';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { AppBar, Toolbar as MuiToolbar } from '@mui/material';\nimport { PropsWithChildren, useRef } from 'react';\n\nexport type ToolbarProps = PropsWithChildren<{\n /** The handler to use for menu commands (and eventually toolbar commands). */\n commandHandler: CommandHandler;\n\n /**\n * The optional delegate to use to get the menu data. If not specified, the \"hamburger\" menu will\n * not display.\n */\n menuProvider?: MultiColumnMenuProvider;\n\n /** Optional unique identifier */\n id?: string;\n\n /** Additional css classes to help with unique styling of the toolbar */\n className?: string;\n}>;\n\nexport default function Toolbar({\n menuProvider,\n commandHandler,\n className,\n id,\n children,\n}: ToolbarProps) {\n // This ref will always be defined\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const containerRef = useRef(undefined!);\n\n return (\n
    \n \n \n {menuProvider ? (\n \n ) : undefined}\n {children ?
    {children}
    : undefined}\n \n
    \n
    \n );\n}\n","import React from 'react';\nimport { cva, type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst alertVariants = cva(\n 'tw-relative tw-w-full tw-rounded-lg tw-border tw-p-4 [&>svg~*]:tw-pl-7 [&>svg+div]:tw-translate-y-[-3px] [&>svg]:tw-absolute [&>svg]:tw-left-4 [&>svg]:tw-top-4 [&>svg]:tw-text-foreground',\n {\n variants: {\n variant: {\n default: 'tw-bg-background tw-text-foreground',\n destructive:\n 'tw-border-destructive/50 tw-text-destructive dark:tw-border-destructive [&>svg]:tw-text-destructive',\n },\n },\n defaultVariants: {\n variant: 'default',\n },\n },\n);\n\nconst Alert = React.forwardRef<\n HTMLDivElement,\n React.HTMLAttributes & VariantProps\n>(({ className, variant, ...props }, ref) => (\n
    \n));\nAlert.displayName = 'Alert';\n\nconst AlertTitle = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n {/* added because of https://github.com/jsx-eslint/eslint-plugin-jsx-a11y/blob/main/docs/rules/heading-has-content.md */}\n {props.children}{' '}\n \n ),\n);\nAlertTitle.displayName = 'AlertTitle';\n\nconst AlertDescription = React.forwardRef<\n HTMLParagraphElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n
    \n));\nAlertDescription.displayName = 'AlertDescription';\n\nexport { Alert, AlertTitle, AlertDescription };\n","import React from 'react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Card = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nCard.displayName = 'Card';\n\nconst CardHeader = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nCardHeader.displayName = 'CardHeader';\n\nconst CardTitle = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n {/* added because of https://github.com/jsx-eslint/eslint-plugin-jsx-a11y/blob/main/docs/rules/heading-has-content.md */}\n {props.children}\n \n ),\n);\nCardTitle.displayName = 'CardTitle';\n\nconst CardDescription = React.forwardRef<\n HTMLParagraphElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n

    \n));\nCardDescription.displayName = 'CardDescription';\n\nconst CardContent = React.forwardRef>(\n ({ className, ...props }, ref) => (\n

    \n ),\n);\nCardContent.displayName = 'CardContent';\n\nconst CardFooter = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nCardFooter.displayName = 'CardFooter';\n\nexport { Card, CardHeader, CardFooter, CardTitle, CardDescription, CardContent };\n","import { ComponentProps } from 'react';\nimport { toast as sonner, Toaster } from 'sonner';\n\ntype SonnerProps = ComponentProps;\n\nfunction Sonner({ ...props }: SonnerProps) {\n return (\n \n );\n}\n\n// The re-export of the sonner function was added manually\nexport { Sonner, sonner };\n","import React from 'react';\nimport * as SliderPrimitive from '@radix-ui/react-slider';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Slider = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n \n \n \n));\nSlider.displayName = SliderPrimitive.Root.displayName;\n\nexport { Slider };\n","import React from 'react';\nimport * as SwitchPrimitives from '@radix-ui/react-switch';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Switch = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n));\nSwitch.displayName = SwitchPrimitives.Root.displayName;\n\nexport { Switch };\n","import React from 'react';\nimport * as TabsPrimitive from '@radix-ui/react-tabs';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport const Tabs = TabsPrimitive.Root;\n\nexport type TabsListProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport type TabsTriggerProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport type TabsContentProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport const TabsList = React.forwardRef<\n React.ElementRef,\n TabsListProps\n>(({ className, ...props }, ref) => (\n \n));\nTabsList.displayName = TabsPrimitive.List.displayName;\n\nexport const TabsTrigger = React.forwardRef<\n React.ElementRef,\n TabsTriggerProps\n>(({ className, ...props }, ref) => (\n \n));\nTabsTrigger.displayName = TabsPrimitive.Trigger.displayName;\n\nexport const TabsContent = React.forwardRef<\n React.ElementRef,\n TabsContentProps\n>(({ className, ...props }, ref) => (\n \n));\nTabsContent.displayName = TabsPrimitive.Content.displayName;\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Download } from 'lucide-react';\n\ntype InstallButtonProps = {\n /** The installing boolean value determines the state of the button. */\n isInstalling: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n /** Optional text for the button. */\n buttonText?: string;\n} & ButtonProps;\n\n/**\n * The InstallButton component is a button designed for initiating installs. It includes visuals for\n * active installing and idle states.\n *\n * @param isInstalling The installing boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @param buttonText Optional text for the button.\n * @returns A install button.\n */\nexport default function InstallButton({\n isInstalling,\n handleClick,\n buttonText,\n className,\n ...props\n}: InstallButtonProps) {\n return (\n \n {isInstalling ? (\n \n ) : (\n <>\n \n {buttonText}\n \n )}\n \n );\n}\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\n\ntype EnableButtonProps = {\n /** The enabling boolean value determines the state of the button. */\n isEnabling: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n} & ButtonProps;\n\n/**\n * The EnableButton component is a button designed for initiating enabling of downloads. It includes\n * visuals for active enabling and idle states.\n *\n * @param isEnabling The enabling boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @returns A button that can be used to enable.\n */\nexport default function EnableButton({\n isEnabling,\n handleClick,\n className,\n ...props\n}: EnableButtonProps) {\n return (\n \n {isEnabling ? (\n <>\n \n Enabling...\n \n ) : (\n 'Enable'\n )}\n \n );\n}\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\n\ntype DisableButtonProps = {\n /** The disabling boolean value determines the state of the button. */\n isDisabling: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n} & ButtonProps;\n\n/**\n * The DisableButton component is a button designed for initiating disabling of downloads. It\n * includes visuals for active disabling and idle states.\n *\n * @param isDisabling The disabling boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @returns A button that can be used to disable.\n */\nexport default function DisableButton({\n isDisabling,\n handleClick,\n className,\n ...props\n}: DisableButtonProps) {\n return (\n \n {isDisabling ? (\n <>\n \n Disabling...\n \n ) : (\n 'Disable'\n )}\n \n );\n}\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\n\ntype UpdateButtonProps = {\n /** The updating boolean value determines the state of the button. */\n isUpdating: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n} & ButtonProps;\n\n/**\n * The UpdateButton component is a button designed for initiating updates for downloaded extensions.\n * It includes visuals for active updating and idle states.\n *\n * @param isUpdating The updating boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @returns A button that can be used to update.\n */\nexport default function UpdateButton({\n isUpdating,\n handleClick,\n className,\n ...props\n}: UpdateButtonProps) {\n return (\n \n {isUpdating ? (\n <>\n \n Updating...\n \n ) : (\n 'Update'\n )}\n \n );\n}\n","import { cn } from '@/utils/shadcn-ui.util';\nimport Markdown, { MarkdownToJSX } from 'markdown-to-jsx';\nimport { useMemo } from 'react';\n\ninterface MarkdownRendererProps {\n /** Optional unique identifier */\n id?: string;\n /** The markdown string to render */\n markdown: string;\n className?: string;\n /**\n * The [`target` attribute for `a` html\n * tags](https://developer.mozilla.org/en-US/docs/Web/HTML/Element/a#target). Defaults to not\n * adding a `target` to `a` tags\n */\n anchorTarget?: string;\n}\n\n/**\n * This component renders markdown content given a markdown string. It uses typography styles from\n * the platform.\n *\n * @param markdown The markdown string to render.\n * @param id Optional unique identifier\n * @returns A div containing the rendered markdown content.\n */\nexport default function MarkdownRenderer({\n id,\n markdown,\n className,\n anchorTarget,\n}: MarkdownRendererProps) {\n const options: MarkdownToJSX.Options = useMemo(\n () => ({\n overrides: {\n a: {\n props: {\n target: anchorTarget,\n },\n },\n },\n }),\n [anchorTarget],\n );\n return (\n
    \n {markdown}\n
    \n );\n}\n","import { Filter, ChevronDown } from 'lucide-react';\nimport { forwardRef } from 'react';\nimport { Button } from '@/components/shadcn-ui/button';\n\n/**\n * The FilterButton component is a button designed for initiating filtering of data. It is designed\n * to be used with the dropdown menu. It uses forwardRef to pass the button to the dropdown trigger\n * asChild.\n *\n * @returns A button that can be used to filter.\n */\nconst FilterButton = forwardRef((props, ref) => {\n return (\n \n \n Filter\n \n \n );\n});\n\nexport default FilterButton;\n","import {\n DropdownMenu,\n DropdownMenuTrigger,\n DropdownMenuContent,\n DropdownMenuLabel,\n DropdownMenuGroup,\n DropdownMenuCheckboxItem,\n DropdownMenuRadioItem,\n DropdownMenuSeparator,\n} from '@/components/shadcn-ui/dropdown-menu';\nimport FilterButton from './buttons/filter-button.component';\n\nexport enum DropdownMenuItemType {\n Check,\n Radio,\n}\n\nexport type DropdownItem = {\n /** The label is the text that will be displayed on the dropdown item. */\n label: string;\n /** The itemType determines the DropdownMenuItemType type as either Check or Radio. */\n itemType: DropdownMenuItemType;\n /** The onClick function is called when the item is clicked. */\n onClick: () => void;\n};\n\nexport type DropdownGroup = {\n /**\n * The label is the text that will be displayed on the dropdown group. It is used to categorize\n * the items in the group.\n */\n label: string;\n /** The items array contains the items that will be displayed in the dropdown group */\n items: DropdownItem[];\n};\n\nexport type FilterDropdownProps = {\n /** Object unique identifier */\n id?: string;\n /** The groups array contains the groups that will be displayed in the dropdown */\n groups: DropdownGroup[];\n}; // TODO: extend the props later\n\n/**\n * The FilterDropdown component is a dropdown designed for filtering content. It includes groups of\n * items that can be checkboxes or radio items.\n *\n * @param id Optional unique identifier\n * @param groups The groups array contains the groups that will be displayed in the dropdown\n * @returns A filter dropdown.\n */\nexport default function FilterDropdown({ id, groups }: FilterDropdownProps) {\n return (\n
    \n {/* TODO: remove this once the DropDown Menu shadcn has an id prop */}\n \n \n \n \n \n {groups.map((group) => (\n
    \n {group.label}\n \n {group.items.map((item) => (\n
    \n {item.itemType === DropdownMenuItemType.Check ? (\n \n {item.label}\n \n ) : (\n \n {item.label}\n \n )}\n
    \n ))}\n
    \n \n
    \n ))}\n
    \n
    \n
    \n );\n}\n","interface NoExtensionsFoundProps {\n /** Optional unique identifier */\n id?: string;\n /** The message to display */\n message: string;\n}\n/**\n * This component displays a message to the user when no extensions are found in the marketplace.\n *\n * @param id Optional unique identifier\n * @param message The message to display.\n * @returns {JSX.Element} - Returns the message component that displays the message to the user.\n */\nexport default function NoExtensionsFound({ id, message }: NoExtensionsFoundProps) {\n return (\n
    \n
    \n

    {message}

    \n
    \n
    \n );\n}\n","import { CircleHelp, Link as LucideLink, User } from 'lucide-react';\nimport { NumberFormat } from 'platform-bible-utils';\n\n/** Interface that stores the parameters passed to the More Info component */\ninterface MoreInfoProps {\n /** Optional unique identifier */\n id?: string;\n /** The category of the extension */\n category: string;\n /** The number of downloads for the extension */\n downloads: Record;\n /** The languages supported by the extension */\n languages: string[];\n /** The URL to the more info page of the extension */\n moreInfoUrl: string;\n}\n/**\n * This component displays the more info section of the extension which includes the category,\n * number of downloads, languages, and links to the website and support\n *\n * @param id Optional unique identifier\n * @param category The category of the extension\n * @param downloads The number of downloads for the extension\n * @param languages The languages supported by the extension\n * @param moreInfoUrl The URL to the more info page of the extension\n * @returns {JSX.Element} - Returns the more info component that displays the category, number of\n * downloads, languages, and links to the website and support\n */\nexport default function MoreInfo({\n id,\n category,\n downloads,\n languages,\n moreInfoUrl,\n}: MoreInfoProps) {\n /**\n * This constant formats the number of downloads into a more readable format.\n *\n * @example 1000 -> 1K\n *\n * @example 1000000 -> 1M\n *\n * @returns The formatted number of downloads\n */\n const numberFormatted = new NumberFormat('en', {\n notation: 'compact',\n compactDisplay: 'short',\n }).format(Object.values(downloads).reduce((a: number, b: number) => a + b, 0));\n\n /** This function scrolls the window to the bottom of the page. */\n const handleScrollToBottom = () => {\n window.scrollTo(0, document.body.scrollHeight);\n };\n\n return (\n \n
    \n
    \n {category}\n
    \n CATEGORY\n
    \n
    \n
    \n
    \n \n {numberFormatted}\n
    \n USERS\n
    \n
    \n
    \n
    \n {languages.slice(0, 3).map((locale) => (\n \n {locale.toUpperCase()}\n \n ))}\n
    \n {languages.length > 3 && (\n handleScrollToBottom()}\n className=\"tw-text-xs tw-text-gray-500 tw-underline\"\n >\n +{languages.length - 3} more languages\n \n )}\n
    \n
    \n
    \n \n Website\n \n \n \n Support\n \n \n
    \n
    \n );\n}\n","import { useState } from 'react';\n\nexport type VersionInformation = {\n /** Date the version was published */\n date: string;\n /** Description of the changes in the version */\n description: string;\n};\n\n/** Type to store the version history information */\nexport type VersionHistoryType = Record;\n\n/** Interface that stores the parameters passed to the Version History component */\ninterface VersionHistoryProps {\n /** Optional unique identifier */\n id?: string;\n /** Object containing the versions mapped with their information */\n versionHistory: VersionHistoryType;\n}\n\n/**\n * Component to render the version history information shown in the footer component. Lists the 5\n * most recent versions, with the options to show all versions by pressing a button.\n *\n * @param versionHistory Object containing the versions mapped with their information\n * @param id Optional unique identifier\n * @returns Rendered version history for the Footer component\n */\nexport default function VersionHistory({ id, versionHistory }: VersionHistoryProps) {\n const [showAllVersions, setShowAllVersions] = useState(false);\n const currentDate = new Date();\n\n /**\n * Function to format the time string for the version history in the form of 'X year(s) ago'.\n *\n * @param dateString ISO Date string to determine the time string from\n * @returns Formatted time string\n */\n function formatTimeString(dateString: string) {\n const date = new Date(dateString);\n const dateDiff = new Date(currentDate.getTime() - date.getTime());\n const yearDiff = dateDiff.getUTCFullYear() - 1970;\n const monthDiff = dateDiff.getUTCMonth();\n const dayDiff = dateDiff.getUTCDate() - 1;\n\n // Determines how long ago the version was published\n let timeString = '';\n if (yearDiff > 0) {\n timeString = `${yearDiff.toString()} year${yearDiff === 1 ? '' : 's'} ago`;\n } else if (monthDiff > 0) {\n timeString = `${monthDiff.toString()} month${monthDiff === 1 ? '' : 's'} ago`;\n } else if (dayDiff === 0) {\n timeString = 'today';\n } else {\n timeString = `${dayDiff.toString()} day${dayDiff === 1 ? '' : 's'} ago`;\n }\n\n return timeString;\n }\n\n // Sorts the version history by version number\n const sortedEntries = Object.entries(versionHistory).sort((a, b) => b[0].localeCompare(a[0]));\n\n return (\n
    \n

    What`s New

    \n
      \n {(showAllVersions ? sortedEntries : sortedEntries.slice(0, 5)).map((entry) => (\n
      \n
      \n
    • \n {entry[1].description}\n
    • \n
      \n
      \n
      Version {entry[0]}
      \n
      {formatTimeString(entry[1].date)}
      \n
      \n
      \n ))}\n
    \n {sortedEntries.length > 5 && (\n setShowAllVersions(!showAllVersions)}\n className=\"tw-text-xs tw-text-gray-500 tw-underline\"\n >\n {showAllVersions ? 'Show Less Version History' : 'Show All Version History'}\n \n )}\n
    \n );\n}\n","import { useMemo } from 'react';\nimport { formatBytes } from 'platform-bible-utils';\nimport VersionHistory, { VersionHistoryType } from './version-history.component';\n\n/** Interface to store the parameters passed to the Footer component */\ninterface FooterProps {\n /** Optional unique identifier */\n id?: string;\n /** Name of the publisher */\n publisherDisplayName: string;\n /** Size of the extension file in bytes */\n fileSize: number;\n /** List of language codes supported by the extension */\n locales: string[];\n /** Object containing the version history mapped with their information */\n versionHistory: VersionHistoryType;\n}\n\n/**\n * Component to render the footer for the extension details which contains information on the\n * publisher, version history, languages, and file size.\n *\n * @param id Optional unique identifier\n * @param publisherDisplayName Name of the publisher\n * @param fileSize Size of the extension file in bytes\n * @param locales List of language codes supported by the extension\n * @param versionHistory Object containing the version history mapped with their information\n * @returns The rendered Footer component\n */\nexport default function Footer({\n id,\n publisherDisplayName,\n fileSize,\n locales,\n versionHistory,\n}: FooterProps) {\n /** Formats the file size into a human-readable format */\n const formattedFileSize = useMemo(() => formatBytes(fileSize), [fileSize]);\n\n /**\n * This function gets the display names of the languages based on the language codes.\n *\n * @param codes The list of language codes\n * @returns The list of language names\n */\n const getLanguageNames = (codes: string[]) => {\n const displayNames = new Intl.DisplayNames(navigator.language, { type: 'language' });\n return codes.map((code) => displayNames.of(code));\n };\n\n const languageNames = getLanguageNames(locales);\n\n return (\n
    \n
    \n \n
    \n
    \n

    Information

    \n
    \n

    \n Publisher\n {publisherDisplayName}\n Size\n {formattedFileSize}\n

    \n
    \n

    \n Languages\n {languageNames.join(', ')}\n

    \n
    \n
    \n
    \n
    \n
    \n );\n}\n","import { PlatformEvent, PlatformEventHandler } from 'platform-bible-utils';\nimport { useEffect } from 'react';\n\n/**\n * Adds an event handler to an event so the event handler runs when the event is emitted. Use\n * `papi.network.getNetworkEvent` to use a networked event with this hook.\n *\n * @param event The event to subscribe to.\n *\n * - If event is a `PlatformEvent`, that event will be used\n * - If event is undefined, the callback will not be subscribed. Useful if the event is not yet\n * available for example\n *\n * @param eventHandler The callback to run when the event is emitted\n *\n * WARNING: MUST BE STABLE - const or wrapped in useCallback. The reference must not be updated\n * every render\n */\nconst useEvent = (\n event: PlatformEvent | undefined,\n eventHandler: PlatformEventHandler,\n) => {\n useEffect(() => {\n // Do nothing if the event is not provided (in case the event is not yet available, for example)\n if (!event) return () => {};\n\n const unsubscriber = event(eventHandler);\n return () => {\n unsubscriber();\n };\n }, [event, eventHandler]);\n};\nexport default useEvent;\n","import { useCallback, useEffect } from 'react';\nimport { PlatformEvent, PlatformEventAsync, PlatformEventHandler } from 'platform-bible-utils';\nimport usePromise from './use-promise.hook';\n\nconst noopUnsubscriber = () => false;\n\n/**\n * Adds an event handler to an asynchronously subscribing/unsubscribing event so the event handler\n * runs when the event is emitted. Use `papi.network.getNetworkEvent` to use a networked event with\n * this hook.\n *\n * @param event The asynchronously (un)subscribing event to subscribe to.\n *\n * - If event is a `PlatformEvent` or `PlatformEventAsync`, that event will be used\n * - If event is undefined, the callback will not be subscribed. Useful if the event is not yet\n * available for example\n *\n * @param eventHandler The callback to run when the event is emitted\n *\n * WARNING: MUST BE STABLE - const or wrapped in useCallback. The reference must not be updated\n * every render\n */\nconst useEventAsync = (\n event: PlatformEvent | PlatformEventAsync | undefined,\n eventHandler: PlatformEventHandler,\n) => {\n // Subscribe to the event asynchronously\n const [unsubscribe] = usePromise(\n useCallback(async () => {\n // Do nothing if the event is not provided (in case the event is not yet available, for example)\n if (!event) return noopUnsubscriber;\n\n // Wrap subscribe and unsubscribe in promises to allow normal events to be used as well\n const unsub = await Promise.resolve(event(eventHandler));\n return async () => unsub();\n }, [eventHandler, event]),\n noopUnsubscriber,\n // We want the unsubscriber to return to default value immediately upon changing subscription\n // So the useEffect below will unsubscribe asap\n { preserveValue: false },\n );\n\n // Unsubscribe from the event asynchronously (but we aren't awaiting the unsub)\n useEffect(() => {\n return () => {\n if (unsubscribe !== noopUnsubscriber) {\n unsubscribe();\n }\n };\n }, [unsubscribe]);\n};\n\nexport default useEventAsync;\n"],"names":["twMergeCustom","extendTailwindMerge","cn","inputs","clsx","Input","React","className","type","props","ref","jsx","BookChapterInput","forwardRef","handleSearch","handleKeyDown","handleOnClick","handleSubmit","jsxs","ShadInput","event","e","History","P","R","t","s","n","N","B","O","S","K","g","k","x","T","X","V","w","L","G","A","H","C","I","y","q","U","m","l","h","c","E","D","i","a","o","u","v","f","d","b","p","J","DropdownMenu","DropdownMenuPrimitive","DropdownMenuTrigger","DropdownMenuGroup","DropdownMenuPortal","DropdownMenuSub","DropdownMenuRadioGroup","DropdownMenuSubTrigger","inset","children","ChevronRight","DropdownMenuSubContent","DropdownMenuContent","sideOffset","DropdownMenuItem","DropdownMenuCheckboxItem","checked","Check","DropdownMenuRadioItem","Circle","DropdownMenuLabel","DropdownMenuSeparator","DropdownMenuShortcut","BookMenuItem","bookId","handleSelectBook","isSelected","handleHighlightBook","bookType","ShadDropdownMenuItem","Canon","ChapterSelect","handleSelectChapter","endChapter","activeChapter","highlightedChapter","handleHighlightedChapter","chapters","_","handleMouse","useCallback","chapterNumber","chapter","GoToMenuItem","handleSort","handleLocationHistory","handleBookmarks","ShadDropdownMenuLabel","ArrowDownWideNarrow","Clock","Bookmark","ALL_BOOK_IDS","BOOK_TYPE_LABELS","BOOK_TYPE_ARRAY","SCROLL_OFFSET","SEARCH_QUERY_FORMATS","fetchGroupedBooks","fetchEndChapter","getChaptersForBook","getAllEnglishNames","isValidBookEnglishName","bookName","getBookIdFromEnglishName","formattedBookName","BookChapterControl","scrRef","searchQuery","setSearchQuery","useState","selectedBookId","setSelectedBookId","setHighlightedChapter","highlightedBookId","setHighlightedBookId","isContentOpen","setIsContentOpen","isContentOpenDelayed","setIsContentOpenDelayed","inputRef","useRef","contentRef","menuItemRef","fetchFilteredBooks","englishNameLowerCase","normalizedQuery","handleSearchInput","searchString","shouldPreventAutoClosing","controlMenuState","open","updateReference","shouldClose","verse","handleInputSubmit","format","matches","book","englishName","handleKeyDownInput","handleKeyDownContent","key","handleKeyDownMenuItem","chapterOffSet","useEffect","useLayoutEffect","scrollTimeout","scrollPosition","ShadDropdownMenu","ShadDropdownMenuTrigger","ShadDropdownMenuContent","bookTypeIndex","element","ShadDropdownMenuSeparator","buttonVariants","cva","Button","variant","size","asChild","Comp","Slot","labelVariants","Label","LabelPrimitive","RadioGroup","RadioGroupPrimitive","RadioGroupItem","Popover","PopoverPrimitive","PopoverTrigger","PopoverContent","align","DialogPortal","DialogPrimitive","DialogOverlay","DialogContent","DialogTitle","DialogDescription","Command","CommandPrimitive","CommandInput","Search","CommandList","CommandEmpty","CommandGroup","CommandSeparator","CommandItem","getOptionLabelDefault","option","ComboBox","id","options","buttonClassName","popoverContentClassName","value","onChange","getOptionLabel","buttonPlaceholder","textPlaceholder","commandEmptyMessage","buttonVariant","dir","isDisabled","setOpen","ChevronsUpDown","ChapterRangeSelector","startChapter","handleSelectStartChapter","handleSelectEndChapter","chapterCount","chapterOptions","useMemo","index","onChangeStartChapter","onChangeEndChapter","Fragment","BookSelectionMode","BOOK_SELECTOR_STRING_KEYS","localizeString","strings","BookSelector","handleBookSelectionModeChange","currentBookName","onSelectBooks","selectedBookIds","localizedStrings","currentBookText","chooseText","chooseBooksText","bookSelectionMode","setBookSelectionMode","onSelectionModeChange","newMode","DataTableViewOptions","table","FilterIcon","column","Select","SelectPrimitive","SelectGroup","SelectValue","SelectTrigger","ChevronDown","SelectScrollUpButton","ChevronUp","SelectScrollDownButton","SelectContent","position","SelectLabel","SelectItem","SelectSeparator","DataTablePagination","pageSize","ArrowLeftIcon","ChevronLeftIcon","ChevronRightIcon","ArrowRightIcon","Table","stickyHeader","TableHeader","TableBody","TableFooter","TableRow","TableHead","TableCell","TableCaption","DataTable","columns","data","enablePagination","showPaginationControls","showColumnVisibilityControls","onRowClickHandler","sorting","setSorting","columnFilters","setColumnFilters","columnVisibility","setColumnVisibility","rowSelection","setRowSelection","useReactTable","getCoreRowModel","getPaginationRowModel","getSortedRowModel","getFilteredRowModel","headerGroup","header","flexRender","_a","row","cell","OccurrencesTable","occurrenceData","setScriptureReference","referenceHeaderText","occurrenceHeaderText","occurrences","uniqueOccurrences","occurrence","uniqueOccurrence","deepEqual","Checkbox","CheckboxPrimitive","getLinesFromUSFM","text","getNumberFromUSFM","regex","match","getBookNumFromId","getStatusForItem","item","approvedItems","unapprovedItems","toggleVariants","Toggle","TogglePrimitive","ToggleGroupContext","ToggleGroup","ToggleGroupPrimitive","ToggleGroupItem","context","getSortingIcon","sortDirection","ArrowUpIcon","ArrowDownIcon","ArrowUpDownIcon","inventoryItemColumn","itemLabel","inventoryAdditionalItemColumn","additionalItemLabel","additionalItemIndex","inventoryCountColumn","countLabel","statusChangeHandler","changedItems","newStatus","onApprovedItemsChange","onUnapprovedItemsChange","newApprovedItems","validItem","newUnapprovedItems","unapprovedItem","inventoryStatusColumn","statusLabel","status","CircleCheckIcon","CircleXIcon","CircleHelpIcon","INVENTORY_STRING_KEYS","filterItemData","itemData","statusFilter","textFilter","filteredItemData","createTableData","scriptureRef","itemRegex","tableData","currentBook","currentChapter","currentVerse","line","items","itemIndex","existingItem","tableEntry","newReference","substring","newItem","Inventory","scriptureReference","extractItems","additionalItemsLabels","scope","onScopeChange","allItemsText","approvedItemsText","unapprovedItemsText","unknownItemsText","scopeBookText","scopeChapterText","scopeVerseText","filterText","showAdditionalItemsText","showAdditionalItems","setShowAdditionalItems","setStatusFilter","setTextFilter","selectedItem","setSelectedItem","reducedTableData","newTableData","firstItem","existingEntry","newTableEntry","filteredTableData","allColumns","numberOfAdditionalItems","additionalColumns","_b","rowClickHandler","newSelection","handleScopeChange","handleStatusFilterChange","SearchBar","onSearch","placeholder","isFullWidth","handleInputChange","VerticalTabs","TabsPrimitive","VerticalTabsList","VerticalTabsTrigger","VerticalTabsContent","TabNavigationContentSearch","tabList","searchPlaceholder","headerTitle","isSearchBarFullWidth","direction","tab","Separator","orientation","decorative","SeparatorPrimitive","Sheet","SheetPrimitive","SheetPortal","SheetOverlay","sheetVariants","SheetContent","side","SheetTitle","SheetDescription","Skeleton","TooltipProvider","TooltipPrimitive","Tooltip","TooltipTrigger","TooltipContent","MOBILE_BREAKPOINT","useIsMobile","isMobile","setIsMobile","mql","SIDEBAR_COOKIE_NAME","SIDEBAR_COOKIE_MAX_AGE","SIDEBAR_WIDTH","SIDEBAR_WIDTH_MOBILE","SIDEBAR_WIDTH_ICON","SIDEBAR_KEYBOARD_SHORTCUT","SidebarContext","useSidebar","SidebarProvider","defaultOpen","openProp","setOpenProp","style","openMobile","setOpenMobile","_open","_setOpen","isOpen","openState","toggleSidebar","state","contextValue","Sidebar","collapsible","SidebarTrigger","onClick","PanelLeft","SidebarRail","SidebarInset","SidebarInput","SidebarHeader","SidebarFooter","SidebarSeparator","SidebarContent","SidebarGroup","SidebarGroupLabel","SidebarGroupAction","SidebarGroupContent","SidebarMenu","SidebarMenuItem","sidebarMenuButtonVariants","SidebarMenuButton","isActive","tooltip","button","SidebarMenuAction","showOnHover","SidebarMenuBadge","SidebarMenuSkeleton","showIcon","width","SidebarMenuSub","SidebarMenuSubItem","SidebarMenuSubButton","SettingsSidebar","extensionLabels","projectOptions","handleSelectSidebarItem","selectedSidebarItem","handleSelectItem","projectId","getProjectNameFromProjectId","project","getIsActive","label","selectedProjectName","SettingsSidebarContentSearch","scrBookColId","scrRefColId","typeColId","detailsColId","defaultScrRefColumnName","defaultScrBookGroupName","defaultTypeColumnName","defaultDetailsColumnName","getColumns","colInfo","showSourceColumn","showSrcCol","info","formatScrRef","compareScrRefs","toRefOrRange","scriptureSelection","offsetStart","offsetEnd","scrRefToBBBCCCVVV","getRowKey","ScriptureResultsViewer","sources","showColumnHeaders","scriptureReferenceColumnName","scriptureBookGroupName","typeColumnName","detailsColumnName","onRowSelected","grouping","setGrouping","scriptureResults","source","getExpandedRowModel","getGroupedRowModel","selectedRows","keys","selectedRow","scrBookGroupName","typeGroupName","groupingOptions","handleSelectChange","selectedGrouping","handleRowClick","getEvenOrOddBandingStyle","getIndent","groupingState","rowIndex","ChevronLeft","DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS","getLocalizeKeyForScrollGroupId","ScrollGroupSelector","availableScrollGroupIds","scrollGroupId","onChangeScrollGroupId","localizedStringsDefaulted","localizedStringKey","localizedStringValue","newScrollGroupString","scrollGroupOptionId","SettingsList","SettingsListItem","primary","secondary","isLoading","loadingMessage","SettingsListHeader","includeSeparator","Checklist","listItems","selectedListItems","handleSelectListItem","createLabel","_interopRequireDefault","obj","module","chainPropTypes","propType1","propType2","args","_extends","target","isPlainObject","prototype","deepClone","output","deepmerge","r","z","reactIs_production_min","hasSymbol","REACT_ELEMENT_TYPE","REACT_PORTAL_TYPE","REACT_FRAGMENT_TYPE","REACT_STRICT_MODE_TYPE","REACT_PROFILER_TYPE","REACT_PROVIDER_TYPE","REACT_CONTEXT_TYPE","REACT_ASYNC_MODE_TYPE","REACT_CONCURRENT_MODE_TYPE","REACT_FORWARD_REF_TYPE","REACT_SUSPENSE_TYPE","REACT_SUSPENSE_LIST_TYPE","REACT_MEMO_TYPE","REACT_LAZY_TYPE","REACT_BLOCK_TYPE","REACT_FUNDAMENTAL_TYPE","REACT_RESPONDER_TYPE","REACT_SCOPE_TYPE","isValidElementType","typeOf","object","$$typeof","$$typeofType","AsyncMode","ConcurrentMode","ContextConsumer","ContextProvider","Element","ForwardRef","Lazy","Memo","Portal","Profiler","StrictMode","Suspense","hasWarnedAboutDeprecatedIsAsyncMode","isAsyncMode","isConcurrentMode","isContextConsumer","isContextProvider","isElement","isForwardRef","isFragment","isLazy","isMemo","isPortal","isProfiler","isStrictMode","isSuspense","reactIs_development","reactIsModule","require$$0","require$$1","getOwnPropertySymbols","hasOwnProperty","propIsEnumerable","toObject","val","shouldUseNative","test1","test2","order2","test3","letter","objectAssign","from","to","symbols","ReactPropTypesSecret","ReactPropTypesSecret_1","has","printWarning","loggedTypeFailures","message","checkPropTypes","typeSpecs","values","location","componentName","getStack","typeSpecName","error","err","ex","stack","checkPropTypes_1","ReactIs","assign","require$$2","require$$3","require$$4","emptyFunctionThatReturnsNull","factoryWithTypeCheckers","isValidElement","throwOnDirectAccess","ITERATOR_SYMBOL","FAUX_ITERATOR_SYMBOL","getIteratorFn","maybeIterable","iteratorFn","ANONYMOUS","ReactPropTypes","createPrimitiveTypeChecker","createAnyTypeChecker","createArrayOfTypeChecker","createElementTypeChecker","createElementTypeTypeChecker","createInstanceTypeChecker","createNodeChecker","createObjectOfTypeChecker","createEnumTypeChecker","createUnionTypeChecker","createShapeTypeChecker","createStrictShapeTypeChecker","is","PropTypeError","createChainableTypeChecker","validate","manualPropTypeCallCache","manualPropTypeWarningCount","checkType","isRequired","propName","propFullName","secret","cacheKey","chainedCheckType","expectedType","propValue","propType","getPropType","preciseType","getPreciseType","typeChecker","expectedClass","expectedClassName","actualClassName","getClassName","expectedValues","valuesString","arrayOfTypeCheckers","checker","getPostfixForTypeWarning","expectedTypes","checkerResult","expectedTypesMessage","isNode","invalidValidatorError","shapeTypes","allKeys","iterator","step","entry","isSymbol","emptyFunction","emptyFunctionWithReset","factoryWithThrowingShims","shim","getShim","propTypesModule","isClassComponent","elementType","acceptingRef","safePropName","warningHint","elementAcceptingRef","PropTypes","elementAcceptingRef$1","specialProperty","exactProp","propTypes","unsupportedProps","prop","formatMuiErrorMessage","code","url","REACT_SERVER_CONTEXT_TYPE","REACT_OFFSCREEN_TYPE","enableScopeAPI","enableCacheElement","enableTransitionTracing","enableLegacyHidden","enableDebugTracing","REACT_MODULE_REFERENCE","SuspenseList","hasWarnedAboutDeprecatedIsConcurrentMode","isSuspenseList","fnNameMatchRegex","getFunctionName","fn","getFunctionComponentName","Component","fallback","getWrappedName","outerType","innerType","wrapperName","functionName","getDisplayName","HTMLElementType","refType","refType$1","capitalize","string","_formatMuiErrorMessage","createChainedFunction","funcs","acc","func","debounce","wait","timeout","debounced","later","deprecatedPropType","validator","reason","componentNameSafe","propFullNameSafe","isMuiElement","muiNames","_muiName","_element$type","ownerDocument","node","ownerWindow","requirePropFactory","componentNameInError","prevPropTypes","requiredProp","defaultTypeChecker","typeCheckerResult","setRef","useEnhancedEffect","useEnhancedEffect$1","globalId","useGlobalId","idOverride","defaultId","setDefaultId","maybeReactUseId","useId","reactId","unsupportedProp","useControlled","controlled","defaultProp","name","isControlled","valueState","setValue","defaultValue","setValueIfUncontrolled","newValue","useEventCallback","useForkRef","refs","instance","UNINITIALIZED","useLazyRef","init","initArg","EMPTY","useOnMount","Timeout","delay","useTimeout","hadKeyboardEvent","hadFocusVisibleRecently","hadFocusVisibleRecentlyTimeout","inputTypesWhitelist","focusTriggersKeyboardModality","tagName","handlePointerDown","handleVisibilityChange","prepare","doc","isFocusVisible","useIsFocusVisible","isFocusVisibleRef","handleBlurVisible","handleFocusVisible","resolveProps","defaultProps","defaultSlotProps","slotProps","slotPropName","composeClasses","slots","getUtilityClass","classes","slot","utilityClass","defaultGenerator","createClassNameGenerator","generate","generator","ClassNameGenerator","ClassNameGenerator$1","globalStateClasses","generateUtilityClass","globalStatePrefix","globalStateClass","generateUtilityClasses","result","clamp","min","max","_objectWithoutPropertiesLoose","excluded","sourceKeys","_excluded","sortBreakpointsValues","breakpointsAsArray","breakpoint1","breakpoint2","createBreakpoints","breakpoints","unit","other","sortedValues","up","down","between","start","end","endIndex","only","not","keyIndex","shape","shape$1","responsivePropType","responsivePropType$1","merge","defaultBreakpoints","handleBreakpoints","styleFromPropValue","theme","themeBreakpoints","breakpoint","mediaKey","cssKey","createEmptyBreakpointObject","breakpointsInput","_breakpointsInput$key","breakpointStyleKey","removeUnusedBreakpoints","breakpointKeys","breakpointOutput","getPath","path","checkVars","getStyleValue","themeMapping","transform","propValueFinal","userValue","cssProperty","themeKey","memoize","cache","arg","properties","directions","aliases","getCssProperties","property","marginKeys","paddingKeys","spacingKeys","createUnaryUnit","_getPath","themeSpacing","abs","createUnarySpacing","getValue","transformer","transformed","getStyleFromPropValue","cssProperties","resolveCssProperty","margin","padding","createSpacing","spacingInput","spacing","argsInput","argument","compose","styles","handlers","borderTransform","createBorderStyle","border","borderTop","borderRight","borderBottom","borderLeft","borderColor","borderTopColor","borderRightColor","borderBottomColor","borderLeftColor","outline","outlineColor","borderRadius","gap","columnGap","rowGap","gridColumn","gridRow","gridAutoFlow","gridAutoColumns","gridAutoRows","gridTemplateColumns","gridTemplateRows","gridTemplateAreas","gridArea","paletteTransform","color","bgcolor","backgroundColor","sizingTransform","maxWidth","_props$theme","_props$theme2","breakpointsValues","minWidth","height","maxHeight","minHeight","boxSizing","defaultSxConfig","defaultSxConfig$1","objectsHaveSameKeys","objects","union","callIfFn","maybeFn","unstable_createStyleFunctionSx","getThemeValue","config","styleFunctionSx","_theme$unstable_sxCon","sx","traverse","sxInput","sxObject","emptyBreakpoints","breakpointsKeys","css","styleKey","styleFunctionSx$1","applyStyles","createTheme","paletteInput","shapeInput","muiTheme","isObjectEmpty","useTheme","defaultTheme","contextTheme","ThemeContext","systemDefaultTheme","useThemeWithoutDefault","_excluded2","_excluded3","isEmpty","isStringTag","tag","shouldForwardProp","lowercaseFirstLetter","resolveTheme","themeId","defaultOverridesResolver","processStyleArg","callableStyle","_ref","ownerState","resolvedStylesArg","resolvedStyle","variants","isMatch","createStyled","input","rootShouldForwardProp","slotShouldForwardProp","systemSx","inputOptions","processStyles","componentSlot","inputSkipVariantsResolver","inputSkipSx","overridesResolver","skipVariantsResolver","skipSx","shouldForwardPropOption","defaultStyledResolver","styledEngineStyled","transformStyleArg","stylesArg","muiStyledResolver","styleArg","expressions","transformedStyleArg","expressionsWithDefaultTheme","styleOverrides","resolvedStyleOverrides","slotKey","slotStyle","_theme$components","themeVariants","numOfCustomFnsApplied","placeholders","displayName","getThemeProps","params","useThemeProps","clampWrapper","hexToRgb","re","colors","decomposeColor","marker","colorSpace","recomposeColor","hslToRgb","rgb","getLuminance","getContrastRatio","foreground","background","lumA","lumB","alpha","darken","coefficient","lighten","createMixins","mixins","common","common$1","grey","grey$1","purple","purple$1","red","red$1","orange","orange$1","blue","blue$1","lightBlue","lightBlue$1","green","green$1","light","dark","addLightOrDark","intent","shade","tonalOffset","tonalOffsetLight","tonalOffsetDark","getDefaultPrimary","mode","getDefaultSecondary","getDefaultError","getDefaultInfo","getDefaultSuccess","getDefaultWarning","createPalette","palette","contrastThreshold","success","warning","getContrastText","contrastText","contrast","augmentColor","mainShade","lightShade","darkShade","modes","round","caseAllCaps","defaultFontFamily","createTypography","typography","fontFamily","fontSize","fontWeightLight","fontWeightRegular","fontWeightMedium","fontWeightBold","htmlFontSize","allVariants","pxToRem2","coef","pxToRem","buildVariant","fontWeight","lineHeight","letterSpacing","casing","shadowKeyUmbraOpacity","shadowKeyPenumbraOpacity","shadowAmbientShadowOpacity","createShadow","px","shadows","shadows$1","easing","duration","formatMs","milliseconds","getAutoHeightDuration","constant","createTransitions","inputTransitions","mergedEasing","mergedDuration","durationOption","easingOption","isString","isNumber","animatedProp","zIndex","zIndex$1","mixinsInput","transitionsInput","typographyInput","systemTheme","systemCreateTheme","stateClasses","component","child","stateClass","defaultTheme$1","THEME_ID","systemUseThemeProps","styled","styled$1","getSvgIconUtilityClass","useUtilityClasses","SvgIconRoot","_theme$transitions","_theme$transitions$cr","_theme$transitions2","_theme$typography","_theme$typography$pxT","_theme$typography2","_theme$typography2$px","_theme$typography3","_theme$typography3$px","_palette$ownerState$c","_palette","_palette2","_palette3","SvgIcon","inProps","htmlColor","inheritViewBox","titleAccess","viewBox","hasSvgAsChild","more","_jsxs","_jsx","SvgIcon$1","createSvgIcon","unstable_ClassNameGenerator","exports","_utils","ArrowRight","default_1","_createSvgIcon","_jsxRuntime","isHostComponent","appendOwnerState","otherProps","defaultContextValue","ClassNameConfiguratorContext","useClassNamesOverride","disableDefaultClasses","extractEventHandlers","excludeKeys","resolveComponentProps","componentProps","slotState","omitEventHandlers","mergeSlotProps","parameters","getSlotProps","additionalProps","externalSlotProps","externalForwardedProps","joinedClasses","mergedStyle","eventHandlers","componentsPropsWithoutEventHandlers","otherPropsWithoutEventHandlers","internalSlotProps","useSlotProps","_parameters$additiona","skipResolvingSlotProps","rest","resolvedComponentsProps","mergedProps","internalRef","GLOBAL_CLASS_PREFIX","buildStateClass","buildSlotClass","getContainer","container","forwardedRef","disablePortal","mountNode","setMountNode","handleRef","newProps","ReactDOM","top","bottom","right","left","auto","basePlacements","clippingParents","viewport","popper","reference","variationPlacements","placement","placements","beforeRead","read","afterRead","beforeMain","main","afterMain","beforeWrite","write","afterWrite","modifierPhases","getNodeName","getWindow","OwnElement","isHTMLElement","isShadowRoot","attributes","effect","_ref2","initialStyles","styleProperties","attribute","applyStyles$1","getBasePlacement","getUAString","uaData","isLayoutViewport","getBoundingClientRect","includeScale","isFixedStrategy","clientRect","scaleX","scaleY","visualViewport","addVisualOffsets","getLayoutRect","contains","parent","rootNode","next","getComputedStyle","isTableElement","getDocumentElement","getParentNode","getTrueOffsetParent","getContainingBlock","isFirefox","isIE","elementCss","currentNode","getOffsetParent","window","offsetParent","getMainAxisFromPlacement","within","mathMax","mathMin","withinMaxClamp","getFreshSideObject","mergePaddingObject","paddingObject","expandToHashMap","hashMap","toPaddingObject","arrow","_state$modifiersData$","arrowElement","popperOffsets","basePlacement","axis","isVertical","len","arrowRect","minProp","maxProp","endDiff","startDiff","arrowOffsetParent","clientSize","centerToReference","center","offset","axisProp","_options$element","arrow$1","getVariation","unsetSides","roundOffsetsByDPR","win","dpr","mapToStyles","_Object$assign2","popperRect","variation","offsets","gpuAcceleration","adaptive","roundOffsets","isFixed","_offsets$x","_offsets$y","_ref3","hasX","hasY","sideX","sideY","heightProp","widthProp","offsetY","offsetX","commonStyles","_ref4","_Object$assign","computeStyles","_ref5","_options$gpuAccelerat","_options$adaptive","_options$roundOffsets","computeStyles$1","passive","_options$scroll","scroll","_options$resize","resize","scrollParents","scrollParent","eventListeners","hash","getOppositePlacement","matched","getOppositeVariationPlacement","getWindowScroll","scrollLeft","scrollTop","getWindowScrollBarX","getViewportRect","strategy","html","layoutViewport","getDocumentRect","_element$ownerDocumen","winScroll","body","isScrollParent","_getComputedStyle","overflow","overflowX","overflowY","getScrollParent","listScrollParents","list","isBody","updatedList","rectToClientRect","rect","getInnerBoundingClientRect","getClientRectFromMixedType","clippingParent","getClippingParents","canEscapeClipping","clipperElement","getClippingRect","boundary","rootBoundary","mainClippingParents","firstClippingParent","clippingRect","accRect","computeOffsets","commonX","commonY","mainAxis","detectOverflow","_options","_options$placement","_options$strategy","_options$boundary","_options$rootBoundary","_options$elementConte","elementContext","_options$altBoundary","altBoundary","_options$padding","altContext","clippingClientRect","referenceClientRect","popperClientRect","elementClientRect","overflowOffsets","offsetData","multiply","computeAutoPlacement","flipVariations","_options$allowedAutoP","allowedAutoPlacements","allPlacements","allowedPlacements","overflows","getExpandedFallbackPlacements","oppositePlacement","flip","_options$mainAxis","checkMainAxis","_options$altAxis","checkAltAxis","specifiedFallbackPlacements","_options$flipVariatio","preferredPlacement","isBasePlacement","fallbackPlacements","referenceRect","checksMap","makeFallbackChecks","firstFittingPlacement","_basePlacement","isStartVariation","mainVariationSide","altVariationSide","checks","check","numberOfChecks","_loop","_i","fittingPlacement","_ret","flip$1","getSideOffsets","preventedOffsets","isAnySideFullyClipped","hide","referenceOverflow","popperAltOverflow","referenceClippingOffsets","popperEscapeOffsets","isReferenceHidden","hasPopperEscaped","hide$1","distanceAndSkiddingToXY","rects","invertDistance","skidding","distance","_options$offset","_data$state$placement","offset$1","popperOffsets$1","getAltAxis","preventOverflow","_options$tether","tether","_options$tetherOffset","tetherOffset","altAxis","tetherOffsetValue","normalizedTetherOffsetValue","offsetModifierState","_offsetModifierState$","mainSide","altSide","additive","minLen","maxLen","arrowPaddingObject","arrowPaddingMin","arrowPaddingMax","arrowLen","minOffset","maxOffset","clientOffset","offsetModifierValue","tetherMin","tetherMax","preventedOffset","_offsetModifierState$2","_mainSide","_altSide","_offset","_len","_min","_max","isOriginSide","_offsetModifierValue","_tetherMin","_tetherMax","_preventedOffset","preventOverflow$1","getHTMLElementScroll","getNodeScroll","isElementScaled","getCompositeRect","elementOrVirtualElement","isOffsetParentAnElement","offsetParentIsScaled","documentElement","order","modifiers","map","visited","modifier","sort","requires","dep","depModifier","orderModifiers","orderedModifiers","phase","pending","resolve","mergeByName","merged","current","existing","DEFAULT_OPTIONS","areValidElements","_key","popperGenerator","generatorOptions","_generatorOptions","_generatorOptions$def","defaultModifiers","_generatorOptions$def2","defaultOptions","effectCleanupFns","isDestroyed","setOptionsAction","cleanupModifierEffects","runModifierEffects","_state$elements","_state$orderedModifie","_state$orderedModifie2","_ref$options","cleanupFn","noopFn","createPopper","COMPONENT_NAME","getPopperUtilityClass","flipPlacement","resolveAnchorEl","anchorEl","isVirtualElement","defaultPopperOptions","PopperTooltip","_slots$root","initialPlacement","popperOptions","popperRefProp","TransitionProps","tooltipRef","ownRef","popperRef","handlePopperRef","handlePopperRefRef","rtlPlacement","setPlacement","resolvedAnchorElement","setResolvedAnchorElement","handlePopperUpdate","box","popperModifiers","childProps","Root","rootProps","Popper","containerProp","keepMounted","transition","exited","setExited","handleEnter","handleExited","resolvedAnchorEl","display","transitionProps","useThemeSystem","_setPrototypeOf","_inheritsLoose","subClass","superClass","setPrototypeOf","timeoutsShape","TransitionGroupContext","forceReflow","UNMOUNTED","EXITED","ENTERING","ENTERED","EXITING","Transition","_React$Component","_this","parentGroup","appear","initialStatus","prevState","nextIn","_proto","prevProps","nextStatus","exit","enter","mounting","_this2","appearing","maybeNode","maybeAppearing","timeouts","enterTimeout","_this3","nextState","callback","_this4","active","handler","doesNotHaveTimeoutOrListener","maybeNextCallback","_this$props","pt","noop","Transition$1","reflow","getTransitionProps","_style$transitionDura","_style$transitionTimi","getScale","isWebKit154","Grow","addEndListener","inProp","onEnter","onEntered","onEntering","onExit","onExited","onExiting","TransitionComponent","timer","autoTimeout","nodeRef","normalizedTransitionCallback","maybeIsAppearing","handleEntering","isAppearing","transitionDuration","transitionTimingFunction","handleEntered","handleExiting","handleExit","handleAddEndListener","Grow$1","PopperRoot","BasePopper","components","componentsProps","RootComponent","Popper$1","getTooltipUtilityClass","tooltipClasses","tooltipClasses$1","disableInteractive","touch","TooltipPopper","TooltipTooltip","TooltipArrow","hystersisOpen","hystersisTimer","cursorPosition","composeEventHandler","eventHandler","_slots$popper","_slots$transition","_slots$tooltip","_slots$arrow","_slotProps$popper","_ref6","_slotProps$popper2","_slotProps$transition","_slotProps$tooltip","_ref7","_slotProps$tooltip2","_slotProps$arrow","_ref8","_slotProps$arrow2","childrenProp","describeChild","disableFocusListener","disableHoverListener","disableInteractiveProp","disableTouchListener","enterDelay","enterNextDelay","enterTouchDelay","followCursor","idProp","leaveDelay","leaveTouchDelay","onClose","onOpen","PopperComponentProp","PopperProps","title","TransitionComponentProp","isRtl","childNode","setChildNode","arrowRef","setArrowRef","ignoreNonTouchEvents","closeTimer","enterTimer","leaveTimer","touchTimer","setOpenState","prevUserSelect","stopTouchInteraction","handleOpen","handleClose","handleLeave","focusVisibleRef","setChildIsFocusVisible","handleBlur","handleFocus","detectTouchStart","childrenProps","handleMouseOver","handleMouseLeave","handleTouchStart","handleTouchEnd","nativeEvent","handleMouseMove","nameOrDescProps","titleIsString","interactiveWrapperListeners","_PopperProps$popperOp","tooltipModifiers","PopperComponent","TooltipComponent","ArrowComponent","popperProps","tooltipProps","tooltipArrowProps","TransitionPropsInner","Tooltip$1","getIcon","icon","menuLabel","leading","MuiListItemIcon","MenuItem","allowForLeadingIcons","iconPathBefore","iconPathAfter","hasAutoFocus","isDense","isSubMenuParent","hasDisabledGutters","hasDivider","focusVisibleClassName","menuItem","MuiMenuItem","MuiListItemText","getAllGroups","menuDefinition","SubMenu","setAnchorEl","parentMenuItem","parentItemProps","handleParentMenuItemClick","renderSubMenuItems","includedGroups","group","GroupedMenuItemList","Menu","getOrderedGroupItems","groupId","allItems","menuProps","commandHandler","groupsToInclude","sortedGroups","itemArray","allowSpaceForLeadingIcons","createMenuItemProps","isLastItemInGroup","divKey","itemInfo","menuItemProps","TopLevelMenu","columnId","MenuColumn","metadata","Grid","List","GridMenu","multiColumnMenu","sortedColumns","columnNumbers","columnName","col","getUsePromiseOptionsDefaults","usePromise","promiseFactoryCallback","defaultValueRef","optionsDefaultedRef","setIsLoading","promiseIsCurrent","MenuIcon","HamburgerMenuButton","menuProvider","normalMenu","fullMenu","containerRef","ariaLabelPrefix","isMenuOpen","setMenuOpen","showFullMenu","setShowFullMenu","handleMenuItemClick","handleMenuButtonClick","prevIsOpen","isOpening","menuCommandHandler","command","setOffset","normalMenuData","fullMenuData","menu","IconButton","Drawer","isTooltipSuppressed","adjustMarginToAlignToEdge","MuiIconButton","Spinner","LoaderCircle","TextField","hasError","helperText","onFocus","onBlur","ShadLabel","Toolbar","AppBar","MuiToolbar","alertVariants","Alert","AlertTitle","AlertDescription","Card","CardHeader","CardTitle","CardDescription","CardContent","CardFooter","Sonner","Toaster","Slider","SliderPrimitive","Switch","SwitchPrimitives","Tabs","TabsList","TabsTrigger","TabsContent","InstallButton","isInstalling","handleClick","buttonText","Download","EnableButton","isEnabling","DisableButton","isDisabling","UpdateButton","isUpdating","MarkdownRenderer","markdown","anchorTarget","Markdown","FilterButton","Filter","DropdownMenuItemType","DropdownMenuItemType2","FilterDropdown","groups","NoExtensionsFound","MoreInfo","category","downloads","languages","moreInfoUrl","numberFormatted","NumberFormat","handleScrollToBottom","User","locale","LucideLink","CircleHelp","VersionHistory","versionHistory","showAllVersions","setShowAllVersions","currentDate","formatTimeString","dateString","date","dateDiff","yearDiff","monthDiff","dayDiff","timeString","sortedEntries","Footer","publisherDisplayName","fileSize","locales","formattedFileSize","formatBytes","languageNames","codes","displayNames","useEvent","unsubscriber","noopUnsubscriber","useEventAsync","unsubscribe","unsub"],"mappings":"28CAGA,MAAMA,GAAgBC,GAAAA,oBAAoB,CAAE,OAAQ,KAAO,CAAA,EAyDpD,SAASC,KAAMC,EAAsB,CACnC,OAAAH,GAAcI,GAAAA,KAAKD,CAAM,CAAC,CACnC,CCzDO,MAAME,GAAQC,EAAM,WACzB,CAAC,CAA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,MACA,MACA,MACA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MAEA,MAEA,MAEA,MAEA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,MAEA,MAEA,MAEA,MAEA,MACA,MACA,MACA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,KACF,EAAGC,GAAI,CACL,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,KACF,EAAGC,GAAI,CACL,UACA,SACA,YACA,UACA,cACA,SACA,SACA,OACA,WACA,WACA,UACA,UACA,eACA,eACA,OACA,WACA,kBACA,MACA,SACA,WACA,eACA,gBACA,SACA,WACA,eACA,UACA,kBACA,QACA,OACA,OACA,UACA,QACA,QACA,QACA,WACA,YACA,SACA,YACA,UACA,UACA,OACA,OACA,OACA,OACA,SACA,gBACA,gBACA,YACA,YACA,cACA,aACA,kBACA,kBACA,YACA,YACA,QACA,WACA,UACA,QACA,UACA,UACA,SACA,SACA,SACA,OACA,aACA,QACA,SACA,eACA,oBACA,0BACA,SACA,qBACA,sBACA,UACA,qBACA,cACA,cACA,cACA,cACA,mBACA,mBACA,qBACA,YACA,OACA,oBAGA,uBACA,uBACA,sBACA,yBACA,wBACA,qBACA,UACA,UACA,UACA,UACA,UACA,UACA,UACA,eACA,cACA,eACA,oBACA,qBACA,0BACA,0BACA,eACA,eACA,YACA,gBACA,cACA,eACA,iBACA,wBACA,mBACA,WACA,QACA,aACA,aACA,aACA,2BACA,4BACA,YACF,EAAGC,GAAIC,KACP,SAASC,GAAER,EAAGJ,EAAI,GAAI,CACpB,OAAOA,IAAMI,EAAIA,EAAE,YAAa,GAAGA,K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,SACX,EACD,QAAS,CACP,SAAU,UACV,UAAWA,EACZ,EACD,aAAc,CACZ,SAAU,SACX,EACD,aAAc,CACZ,SAAU,qBACV,MAAOc,EACR,EAED,MAAO,CACL,SAAU,UACV,UAAWa,EACZ,EACD,QAAS,CACP,SAAU,UACV,YAAa,kBACb,UAAWA,EACZ,EACD,gBAAiB,CACf,SAAU,UACV,UAAWA,EACZ,EAED,EAAG,CACD,MAAOpC,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,QAAS,CACP,MAAOA,EACR,EACD,WAAY,CACV,MAAOA,EACR,EACD,aAAc,CACZ,MAAOA,EACR,EACD,cAAe,CACb,MAAOA,EACR,EACD,YAAa,CACX,MAAOA,EACR,EACD,SAAU,CACR,MAAOA,EACR,EACD,SAAU,CACR,MAAOA,EACR,EACD,cAAe,CACb,MAAOA,EACR,EACD,mBAAoB,CAClB,MAAOA,EACR,EACD,iBAAkB,CAChB,MAAOA,EACR,EACD,aAAc,CACZ,MAAOA,EACR,EACD,kBAAmB,CACjB,MAAOA,EACR,EACD,gBAAiB,CACf,MAAOA,EACR,EACD,EAAG,CACD,MAAOD,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,OAAQ,CACN,MAAOA,EACR,EACD,UAAW,CACT,MAAOA,EACR,EACD,YAAa,CACX,MAAOA,EACR,EACD,aAAc,CACZ,MAAOA,EACR,EACD,WAAY,CACV,MAAOA,EACR,EACD,QAAS,CACP,MAAOA,EACR,EACD,QAAS,CACP,MAAOA,EACR,EACD,aAAc,CACZ,MAAOA,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;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","x_google_ignoreList":[3,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,83,84,85,86,87,88,89,90,91,92,93,94,95,96,97,98,99,100,101,102,103,104,105,106,107,108,109,110,111,112,113,114,115,116,117,118,119,120,121,122,123,124,125,126,127,128,129,130,131,132,133,134,135,136,137,138,139,140,141,142,143,144,145,146,147,148,149,150,151,152,153,154,155,156,157,158,159,160,161,162,163,164,165,166,167,168,169,170,171,172,173,174,175,176,177,178,179,180,181,182,183,184,185,186,187,188,189,190,191,192,193,194,195,196,197,198,199,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,228]} \ No newline at end of file +{"version":3,"file":"index.cjs","sources":["../src/utils/shadcn-ui.util.ts","../src/components/shadcn-ui/input.tsx","../src/components/advanced/book-chapter-control/book-chapter-input.component.tsx","../../../node_modules/@sillsdev/scripture/dist/index.es.js","../src/components/shadcn-ui/dropdown-menu.tsx","../src/components/advanced/book-chapter-control/book-menu-item.component.tsx","../src/components/advanced/book-chapter-control/chapter-select.component.tsx","../src/components/advanced/book-chapter-control/go-to-menu-item.component.tsx","../src/components/advanced/book-chapter-control/book-chapter-control.component.tsx","../src/components/shadcn-ui/button.tsx","../src/components/shadcn-ui/label.tsx","../src/components/shadcn-ui/radio-group.tsx","../src/components/shadcn-ui/popover.tsx","../src/components/shadcn-ui/dialog.tsx","../src/components/shadcn-ui/command.tsx","../src/components/basics/combo-box.component.tsx","../src/components/basics/chapter-range-selector.component.tsx","../src/components/advanced/book-selector.component.tsx","../src/components/advanced/data-table/data-table-column-toggle.component.tsx","../src/components/shadcn-ui/select.tsx","../src/components/advanced/data-table/data-table-pagination.component.tsx","../src/components/shadcn-ui/table.tsx","../src/components/advanced/data-table/data-table.component.tsx","../src/components/advanced/inventory/occurrences-table.component.tsx","../src/components/shadcn-ui/checkbox.tsx","../src/components/advanced/inventory/inventory-utils.ts","../src/components/shadcn-ui/toggle.tsx","../src/components/shadcn-ui/toggle-group.tsx","../src/components/advanced/inventory/inventory-columns.tsx","../src/components/advanced/inventory/inventory.component.tsx","../src/components/basics/search-bar.component.tsx","../src/components/basics/tabs-vertical.tsx","../src/components/advanced/tab-navigation-content-search.component.tsx","../src/components/shadcn-ui/separator.tsx","../src/components/shadcn-ui/sheet.tsx","../src/components/shadcn-ui/skeleton.tsx","../src/components/shadcn-ui/tooltip.tsx","../src/components/hooks/use-mobile.tsx","../src/components/shadcn-ui/sidebar.tsx","../src/components/advanced/settings-components/settings-sidebar.component.tsx","../src/components/advanced/settings-components/settings-sidebar-content-search.component.tsx","../src/components/advanced/scripture-results-viewer/scripture-results-viewer.component.tsx","../src/components/advanced/scroll-group-selector.component.tsx","../src/components/advanced/settings-components/settings-list.component.tsx","../src/components/basics/checklist.component.tsx","../../../node_modules/@babel/runtime/helpers/interopRequireDefault.js","../../../node_modules/@mui/utils/chainPropTypes/chainPropTypes.js","../../../node_modules/@babel/runtime/helpers/esm/extends.js","../../../node_modules/@mui/utils/deepmerge/deepmerge.js","../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.production.min.js","../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.development.js","../../../node_modules/prop-types/node_modules/react-is/index.js","../../../node_modules/object-assign/index.js","../../../node_modules/prop-types/lib/ReactPropTypesSecret.js","../../../node_modules/prop-types/lib/has.js","../../../node_modules/prop-types/checkPropTypes.js","../../../node_modules/prop-types/factoryWithTypeCheckers.js","../../../node_modules/prop-types/factoryWithThrowingShims.js","../../../node_modules/prop-types/index.js","../../../node_modules/@mui/utils/elementAcceptingRef/elementAcceptingRef.js","../../../node_modules/@mui/utils/exactProp/exactProp.js","../../../node_modules/@mui/utils/formatMuiErrorMessage/formatMuiErrorMessage.js","../../../node_modules/react-is/cjs/react-is.production.min.js","../../../node_modules/react-is/cjs/react-is.development.js","../../../node_modules/react-is/index.js","../../../node_modules/@mui/utils/getDisplayName/getDisplayName.js","../../../node_modules/@mui/utils/HTMLElementType/HTMLElementType.js","../../../node_modules/@mui/utils/refType/refType.js","../../../node_modules/@mui/utils/capitalize/capitalize.js","../../../node_modules/@mui/utils/createChainedFunction/createChainedFunction.js","../../../node_modules/@mui/utils/debounce/debounce.js","../../../node_modules/@mui/utils/deprecatedPropType/deprecatedPropType.js","../../../node_modules/@mui/utils/isMuiElement/isMuiElement.js","../../../node_modules/@mui/utils/ownerDocument/ownerDocument.js","../../../node_modules/@mui/utils/ownerWindow/ownerWindow.js","../../../node_modules/@mui/utils/requirePropFactory/requirePropFactory.js","../../../node_modules/@mui/utils/setRef/setRef.js","../../../node_modules/@mui/utils/useEnhancedEffect/useEnhancedEffect.js","../../../node_modules/@mui/utils/useId/useId.js","../../../node_modules/@mui/utils/unsupportedProp/unsupportedProp.js","../../../node_modules/@mui/utils/useControlled/useControlled.js","../../../node_modules/@mui/utils/useEventCallback/useEventCallback.js","../../../node_modules/@mui/utils/useForkRef/useForkRef.js","../../../node_modules/@mui/utils/useLazyRef/useLazyRef.js","../../../node_modules/@mui/utils/useOnMount/useOnMount.js","../../../node_modules/@mui/utils/useTimeout/useTimeout.js","../../../node_modules/@mui/utils/useIsFocusVisible/useIsFocusVisible.js","../../../node_modules/@mui/utils/resolveProps/resolveProps.js","../../../node_modules/@mui/utils/composeClasses/composeClasses.js","../../../node_modules/@mui/utils/ClassNameGenerator/ClassNameGenerator.js","../../../node_modules/@mui/utils/generateUtilityClass/generateUtilityClass.js","../../../node_modules/@mui/utils/generateUtilityClasses/generateUtilityClasses.js","../../../node_modules/@mui/utils/clamp/clamp.js","../../../node_modules/@babel/runtime/helpers/esm/objectWithoutPropertiesLoose.js","../../../node_modules/@mui/system/esm/createTheme/createBreakpoints.js","../../../node_modules/@mui/system/esm/createTheme/shape.js","../../../node_modules/@mui/system/esm/responsivePropType.js","../../../node_modules/@mui/system/esm/merge.js","../../../node_modules/@mui/system/esm/breakpoints.js","../../../node_modules/@mui/system/esm/style.js","../../../node_modules/@mui/system/esm/memoize.js","../../../node_modules/@mui/system/esm/spacing.js","../../../node_modules/@mui/system/esm/createTheme/createSpacing.js","../../../node_modules/@mui/system/esm/compose.js","../../../node_modules/@mui/system/esm/borders.js","../../../node_modules/@mui/system/esm/cssGrid.js","../../../node_modules/@mui/system/esm/palette.js","../../../node_modules/@mui/system/esm/sizing.js","../../../node_modules/@mui/system/esm/styleFunctionSx/defaultSxConfig.js","../../../node_modules/@mui/system/esm/styleFunctionSx/styleFunctionSx.js","../../../node_modules/@mui/system/esm/createTheme/applyStyles.js","../../../node_modules/@mui/system/esm/createTheme/createTheme.js","../../../node_modules/@mui/system/esm/useThemeWithoutDefault.js","../../../node_modules/@mui/system/esm/useTheme.js","../../../node_modules/@mui/system/esm/createStyled.js","../../../node_modules/@mui/system/esm/useThemeProps/getThemeProps.js","../../../node_modules/@mui/system/esm/useThemeProps/useThemeProps.js","../../../node_modules/@mui/system/esm/colorManipulator.js","../../../node_modules/@mui/material/styles/createMixins.js","../../../node_modules/@mui/material/colors/common.js","../../../node_modules/@mui/material/colors/grey.js","../../../node_modules/@mui/material/colors/purple.js","../../../node_modules/@mui/material/colors/red.js","../../../node_modules/@mui/material/colors/orange.js","../../../node_modules/@mui/material/colors/blue.js","../../../node_modules/@mui/material/colors/lightBlue.js","../../../node_modules/@mui/material/colors/green.js","../../../node_modules/@mui/material/styles/createPalette.js","../../../node_modules/@mui/material/styles/createTypography.js","../../../node_modules/@mui/material/styles/shadows.js","../../../node_modules/@mui/material/styles/createTransitions.js","../../../node_modules/@mui/material/styles/zIndex.js","../../../node_modules/@mui/material/styles/createTheme.js","../../../node_modules/@mui/material/styles/defaultTheme.js","../../../node_modules/@mui/material/styles/identifier.js","../../../node_modules/@mui/material/styles/useThemeProps.js","../../../node_modules/@mui/material/styles/styled.js","../../../node_modules/@mui/material/SvgIcon/svgIconClasses.js","../../../node_modules/@mui/material/SvgIcon/SvgIcon.js","../../../node_modules/@mui/material/utils/createSvgIcon.js","../../../node_modules/@mui/material/utils/index.js","../../../node_modules/@mui/icons-material/utils/createSvgIcon.js","../../../node_modules/@mui/icons-material/ArrowRight.js","../../../node_modules/@mui/base/utils/isHostComponent.js","../../../node_modules/@mui/base/utils/appendOwnerState.js","../../../node_modules/@mui/base/utils/ClassNameConfigurator.js","../../../node_modules/@mui/base/utils/extractEventHandlers.js","../../../node_modules/@mui/base/utils/resolveComponentProps.js","../../../node_modules/@mui/base/utils/omitEventHandlers.js","../../../node_modules/@mui/base/utils/mergeSlotProps.js","../../../node_modules/@mui/base/utils/useSlotProps.js","../../../node_modules/@mui/base/generateUtilityClass/index.js","../../../node_modules/@mui/base/generateUtilityClasses/index.js","../../../node_modules/@mui/base/Portal/Portal.js","../../../node_modules/@popperjs/core/lib/enums.js","../../../node_modules/@popperjs/core/lib/dom-utils/getNodeName.js","../../../node_modules/@popperjs/core/lib/dom-utils/getWindow.js","../../../node_modules/@popperjs/core/lib/dom-utils/instanceOf.js","../../../node_modules/@popperjs/core/lib/modifiers/applyStyles.js","../../../node_modules/@popperjs/core/lib/utils/getBasePlacement.js","../../../node_modules/@popperjs/core/lib/utils/math.js","../../../node_modules/@popperjs/core/lib/utils/userAgent.js","../../../node_modules/@popperjs/core/lib/dom-utils/isLayoutViewport.js","../../../node_modules/@popperjs/core/lib/dom-utils/getBoundingClientRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/getLayoutRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/contains.js","../../../node_modules/@popperjs/core/lib/dom-utils/getComputedStyle.js","../../../node_modules/@popperjs/core/lib/dom-utils/isTableElement.js","../../../node_modules/@popperjs/core/lib/dom-utils/getDocumentElement.js","../../../node_modules/@popperjs/core/lib/dom-utils/getParentNode.js","../../../node_modules/@popperjs/core/lib/dom-utils/getOffsetParent.js","../../../node_modules/@popperjs/core/lib/utils/getMainAxisFromPlacement.js","../../../node_modules/@popperjs/core/lib/utils/within.js","../../../node_modules/@popperjs/core/lib/utils/getFreshSideObject.js","../../../node_modules/@popperjs/core/lib/utils/mergePaddingObject.js","../../../node_modules/@popperjs/core/lib/utils/expandToHashMap.js","../../../node_modules/@popperjs/core/lib/modifiers/arrow.js","../../../node_modules/@popperjs/core/lib/utils/getVariation.js","../../../node_modules/@popperjs/core/lib/modifiers/computeStyles.js","../../../node_modules/@popperjs/core/lib/modifiers/eventListeners.js","../../../node_modules/@popperjs/core/lib/utils/getOppositePlacement.js","../../../node_modules/@popperjs/core/lib/utils/getOppositeVariationPlacement.js","../../../node_modules/@popperjs/core/lib/dom-utils/getWindowScroll.js","../../../node_modules/@popperjs/core/lib/dom-utils/getWindowScrollBarX.js","../../../node_modules/@popperjs/core/lib/dom-utils/getViewportRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/getDocumentRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/isScrollParent.js","../../../node_modules/@popperjs/core/lib/dom-utils/getScrollParent.js","../../../node_modules/@popperjs/core/lib/dom-utils/listScrollParents.js","../../../node_modules/@popperjs/core/lib/utils/rectToClientRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/getClippingRect.js","../../../node_modules/@popperjs/core/lib/utils/computeOffsets.js","../../../node_modules/@popperjs/core/lib/utils/detectOverflow.js","../../../node_modules/@popperjs/core/lib/utils/computeAutoPlacement.js","../../../node_modules/@popperjs/core/lib/modifiers/flip.js","../../../node_modules/@popperjs/core/lib/modifiers/hide.js","../../../node_modules/@popperjs/core/lib/modifiers/offset.js","../../../node_modules/@popperjs/core/lib/modifiers/popperOffsets.js","../../../node_modules/@popperjs/core/lib/utils/getAltAxis.js","../../../node_modules/@popperjs/core/lib/modifiers/preventOverflow.js","../../../node_modules/@popperjs/core/lib/dom-utils/getHTMLElementScroll.js","../../../node_modules/@popperjs/core/lib/dom-utils/getNodeScroll.js","../../../node_modules/@popperjs/core/lib/dom-utils/getCompositeRect.js","../../../node_modules/@popperjs/core/lib/utils/orderModifiers.js","../../../node_modules/@popperjs/core/lib/utils/debounce.js","../../../node_modules/@popperjs/core/lib/utils/mergeByName.js","../../../node_modules/@popperjs/core/lib/createPopper.js","../../../node_modules/@popperjs/core/lib/popper.js","../../../node_modules/@mui/base/Popper/popperClasses.js","../../../node_modules/@mui/base/Popper/Popper.js","../../../node_modules/@mui/material/styles/useTheme.js","../../../node_modules/@babel/runtime/helpers/esm/setPrototypeOf.js","../../../node_modules/@babel/runtime/helpers/esm/inheritsLoose.js","../../../node_modules/react-transition-group/esm/config.js","../../../node_modules/react-transition-group/esm/utils/PropTypes.js","../../../node_modules/react-transition-group/esm/TransitionGroupContext.js","../../../node_modules/react-transition-group/esm/utils/reflow.js","../../../node_modules/react-transition-group/esm/Transition.js","../../../node_modules/@mui/material/transitions/utils.js","../../../node_modules/@mui/material/Grow/Grow.js","../../../node_modules/@mui/material/Popper/Popper.js","../../../node_modules/@mui/material/Tooltip/tooltipClasses.js","../../../node_modules/@mui/material/Tooltip/Tooltip.js","../src/components/mui/menu-item.component.tsx","../src/components/mui/grouped-menu-item-list.component.tsx","../src/components/mui/top-level-menu.component.tsx","../src/components/mui/grid-menu.component.tsx","../src/hooks/use-promise.hook.ts","../../../node_modules/@mui/icons-material/esm/Menu.js","../src/components/mui/hamburger-menu-button.component.tsx","../src/components/mui/icon-button.component.tsx","../src/components/basics/spinner.component.tsx","../src/components/basics/text-field.component.tsx","../src/components/mui/toolbar.component.tsx","../src/components/shadcn-ui/alert.tsx","../src/components/shadcn-ui/card.tsx","../src/components/shadcn-ui/sonner.tsx","../src/components/shadcn-ui/slider.tsx","../src/components/shadcn-ui/switch.tsx","../src/components/shadcn-ui/tabs.tsx","../src/components/advanced/extension-marketplace/buttons/install-button.component.tsx","../src/components/advanced/extension-marketplace/buttons/enable-button.component.tsx","../src/components/advanced/extension-marketplace/buttons/disable-button.component.tsx","../src/components/advanced/extension-marketplace/buttons/update-button.component.tsx","../src/components/advanced/extension-marketplace/markdown-renderer.component.tsx","../src/components/advanced/extension-marketplace/buttons/filter-button.component.tsx","../src/components/advanced/extension-marketplace/filter-dropdown.component.tsx","../src/components/advanced/extension-marketplace/no-extensions-found.component.tsx","../src/components/advanced/extension-marketplace/more-info.component.tsx","../src/components/advanced/extension-marketplace/version-history.component.tsx","../src/components/advanced/extension-marketplace/footer.component.tsx","../src/hooks/use-event.hook.ts","../src/hooks/use-event-async.hook.ts"],"sourcesContent":["import { type ClassValue, clsx } from 'clsx';\nimport { extendTailwindMerge } from 'tailwind-merge';\n\nconst twMergeCustom = extendTailwindMerge({ prefix: 'tw-' });\n\n/**\n * Tailwind and CSS class application helper function. Uses\n * [`clsx`](https://www.npmjs.com/package/clsx) to make it easy to apply classes conditionally using\n * object syntax, and uses [`tailwind-merge`](https://www.npmjs.com/package/tailwind-merge) to make\n * it easy to merge/overwrite Tailwind classes in a programmer-logic-friendly way.\n *\n * Note: `tailwind-merge` is configured to use the prefix `tw-`, so you must use the same prefix\n * with any Tailwind classes you use with this function to successfully overwrite other Tailwind\n * classes. `platform-bible-react` is configured to use `tw-` as its Tailwind prefix, so any\n * Tailwind classes you pass into `platform-bible-react` components will be compared using the `tw-`\n * prefix.\n *\n * This function was popularized by\n * [shadcn/ui](https://ui.shadcn.com/docs/installation/manual#add-a-cn-helper). See [ByteGrad's\n * explanation video](https://www.youtube.com/watch?v=re2JFITR7TI) for more information.\n *\n * @example\n *\n * ```typescript\n * const borderShouldBeBlue = true;\n * const textShouldBeRed = true;\n * const heightShouldBe20 = false;\n * const classString = cn(\n * 'tw-bg-primary tw-h-10 tw-text-primary-foreground',\n * 'tw-bg-secondary',\n * {\n * 'tw-border-blue-500': borderShouldBeBlue,\n * 'tw-text-red-500': textShouldBeRed,\n * 'tw-h-20': heightShouldBe20,\n * },\n * 'some-class',\n * );\n * ```\n *\n * The resulting `classString` is `'tw-h-10 tw-bg-secondary tw-border-blue-500 tw-text-red-500\n * some-class'`\n *\n * - Notice that `'tw-bg-secondary'`, specified later, overwrote `'tw-bg-primary'`, specified earlier,\n * because they are Tailwind classes that affect the same css property\n * - Notice that `'tw-text-red-500'`, specified later, overwrote `'tw-text-primary-foreground'`,\n * specified earlier, because they are Tailwind classes that affect the same css property\n * - Notice that `'tw-h-20'`, specified later, did not overwrite `'tw-h-10'`, specified earlier,\n * because `'tw-h-20'` is part of a conditional class object and its value evaluated to `false`;\n * therefore it was not applied\n * - Notice that `'some-class'` was applied. This function is not limited only to Tailwind classes.\n *\n *\n * @param inputs Class strings or `clsx` conditional class objects to merge. Tailwind classes\n * specified later in the arguments overwrite similar Tailwind classes specified earlier in the\n * arguments\n * @returns Class string containing all applicable classes from the arguments based on the rules\n * described above\n */\n// shadcn/ui uses this export in its boilerplate code\n// eslint-disable-next-line import/prefer-default-export\nexport function cn(...inputs: ClassValue[]) {\n return twMergeCustom(clsx(inputs));\n}\n","import React from 'react';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport interface InputProps extends React.InputHTMLAttributes {}\n\nexport const Input = React.forwardRef(\n ({ className, type, ...props }, ref) => {\n return (\n \n );\n },\n);\nInput.displayName = 'Input';\n","import { FocusEventHandler, forwardRef, KeyboardEvent, MouseEventHandler } from 'react';\nimport { History } from 'lucide-react';\nimport { Input as ShadInput } from '@/components/shadcn-ui/input';\n\nexport type BookChapterInputProps = {\n handleSearch: (searchString: string) => void;\n handleKeyDown: (event: KeyboardEvent) => void;\n handleOnClick: MouseEventHandler;\n handleSubmit: () => void;\n onFocus?: FocusEventHandler;\n value: string;\n placeholder: string;\n};\n\n// Shadcn Input sets type to \"button\"- HAVE to prop spread before setting type\nconst BookChapterInput = forwardRef(\n (\n { handleSearch, handleKeyDown, handleOnClick, handleSubmit, ...props }: BookChapterInputProps,\n ref,\n ) => {\n return (\n
    \n handleSearch(event.target.value)}\n onKeyDown={(e) => {\n if (e.key === 'Enter') {\n handleSubmit();\n }\n handleKeyDown(e);\n }}\n onClick={handleOnClick}\n ref={ref}\n />\n {\n // eslint-disable-next-line no-console\n console.log('back in history');\n }}\n />\n
    \n );\n },\n);\n\nexport default BookChapterInput;\n","var P = Object.defineProperty;\nvar R = (t, e, s) => e in t ? P(t, e, { enumerable: !0, configurable: !0, writable: !0, value: s }) : t[e] = s;\nvar n = (t, e, s) => R(t, typeof e != \"symbol\" ? e + \"\" : e, s);\nclass _ {\n constructor() {\n n(this, \"books\");\n n(this, \"firstSelectedBookNum\");\n n(this, \"lastSelectedBookNum\");\n n(this, \"count\");\n n(this, \"selectedBookNumbers\");\n n(this, \"selectedBookIds\");\n }\n}\nconst N = [\n \"GEN\",\n \"EXO\",\n \"LEV\",\n \"NUM\",\n \"DEU\",\n \"JOS\",\n \"JDG\",\n \"RUT\",\n \"1SA\",\n \"2SA\",\n // 10\n \"1KI\",\n \"2KI\",\n \"1CH\",\n \"2CH\",\n \"EZR\",\n \"NEH\",\n \"EST\",\n \"JOB\",\n \"PSA\",\n \"PRO\",\n // 20\n \"ECC\",\n \"SNG\",\n \"ISA\",\n \"JER\",\n \"LAM\",\n \"EZK\",\n \"DAN\",\n \"HOS\",\n \"JOL\",\n \"AMO\",\n // 30\n \"OBA\",\n \"JON\",\n \"MIC\",\n \"NAM\",\n \"HAB\",\n \"ZEP\",\n \"HAG\",\n \"ZEC\",\n \"MAL\",\n \"MAT\",\n // 40\n \"MRK\",\n \"LUK\",\n \"JHN\",\n \"ACT\",\n \"ROM\",\n \"1CO\",\n \"2CO\",\n \"GAL\",\n \"EPH\",\n \"PHP\",\n // 50\n \"COL\",\n \"1TH\",\n \"2TH\",\n \"1TI\",\n \"2TI\",\n \"TIT\",\n \"PHM\",\n \"HEB\",\n \"JAS\",\n \"1PE\",\n // 60\n \"2PE\",\n \"1JN\",\n \"2JN\",\n \"3JN\",\n \"JUD\",\n \"REV\",\n \"TOB\",\n \"JDT\",\n \"ESG\",\n \"WIS\",\n // 70\n \"SIR\",\n \"BAR\",\n \"LJE\",\n \"S3Y\",\n \"SUS\",\n \"BEL\",\n \"1MA\",\n \"2MA\",\n \"3MA\",\n \"4MA\",\n // 80\n \"1ES\",\n \"2ES\",\n \"MAN\",\n \"PS2\",\n \"ODA\",\n \"PSS\",\n \"JSA\",\n // actual variant text for JOS, now in LXA text\n \"JDB\",\n // actual variant text for JDG, now in LXA text\n \"TBS\",\n // actual variant text for TOB, now in LXA text\n \"SST\",\n // actual variant text for SUS, now in LXA text // 90\n \"DNT\",\n // actual variant text for DAN, now in LXA text\n \"BLT\",\n // actual variant text for BEL, now in LXA text\n \"XXA\",\n \"XXB\",\n \"XXC\",\n \"XXD\",\n \"XXE\",\n \"XXF\",\n \"XXG\",\n \"FRT\",\n // 100\n \"BAK\",\n \"OTH\",\n \"3ES\",\n // Used previously but really should be 2ES\n \"EZA\",\n // Used to be called 4ES, but not actually in any known project\n \"5EZ\",\n // Used to be called 5ES, but not actually in any known project\n \"6EZ\",\n // Used to be called 6ES, but not actually in any known project\n \"INT\",\n \"CNC\",\n \"GLO\",\n \"TDX\",\n // 110\n \"NDX\",\n \"DAG\",\n \"PS3\",\n \"2BA\",\n \"LBA\",\n \"JUB\",\n \"ENO\",\n \"1MQ\",\n \"2MQ\",\n \"3MQ\",\n // 120\n \"REP\",\n \"4BA\",\n \"LAO\"\n], B = [\n \"XXA\",\n \"XXB\",\n \"XXC\",\n \"XXD\",\n \"XXE\",\n \"XXF\",\n \"XXG\",\n \"FRT\",\n \"BAK\",\n \"OTH\",\n \"INT\",\n \"CNC\",\n \"GLO\",\n \"TDX\",\n \"NDX\"\n], O = [\n \"Genesis\",\n \"Exodus\",\n \"Leviticus\",\n \"Numbers\",\n \"Deuteronomy\",\n \"Joshua\",\n \"Judges\",\n \"Ruth\",\n \"1 Samuel\",\n \"2 Samuel\",\n \"1 Kings\",\n \"2 Kings\",\n \"1 Chronicles\",\n \"2 Chronicles\",\n \"Ezra\",\n \"Nehemiah\",\n \"Esther (Hebrew)\",\n \"Job\",\n \"Psalms\",\n \"Proverbs\",\n \"Ecclesiastes\",\n \"Song of Songs\",\n \"Isaiah\",\n \"Jeremiah\",\n \"Lamentations\",\n \"Ezekiel\",\n \"Daniel (Hebrew)\",\n \"Hosea\",\n \"Joel\",\n \"Amos\",\n \"Obadiah\",\n \"Jonah\",\n \"Micah\",\n \"Nahum\",\n \"Habakkuk\",\n \"Zephaniah\",\n \"Haggai\",\n \"Zechariah\",\n \"Malachi\",\n \"Matthew\",\n \"Mark\",\n \"Luke\",\n \"John\",\n \"Acts\",\n \"Romans\",\n \"1 Corinthians\",\n \"2 Corinthians\",\n \"Galatians\",\n \"Ephesians\",\n \"Philippians\",\n \"Colossians\",\n \"1 Thessalonians\",\n \"2 Thessalonians\",\n \"1 Timothy\",\n \"2 Timothy\",\n \"Titus\",\n \"Philemon\",\n \"Hebrews\",\n \"James\",\n \"1 Peter\",\n \"2 Peter\",\n \"1 John\",\n \"2 John\",\n \"3 John\",\n \"Jude\",\n \"Revelation\",\n \"Tobit\",\n \"Judith\",\n \"Esther Greek\",\n \"Wisdom of Solomon\",\n \"Sirach (Ecclesiasticus)\",\n \"Baruch\",\n \"Letter of Jeremiah\",\n \"Song of 3 Young Men\",\n \"Susanna\",\n \"Bel and the Dragon\",\n \"1 Maccabees\",\n \"2 Maccabees\",\n \"3 Maccabees\",\n \"4 Maccabees\",\n \"1 Esdras (Greek)\",\n \"2 Esdras (Latin)\",\n \"Prayer of Manasseh\",\n \"Psalm 151\",\n \"Odes\",\n \"Psalms of Solomon\",\n // WARNING, if you change the spelling of the *obsolete* tag be sure to update\n // IsObsolete routine\n \"Joshua A. *obsolete*\",\n \"Judges B. *obsolete*\",\n \"Tobit S. *obsolete*\",\n \"Susanna Th. *obsolete*\",\n \"Daniel Th. *obsolete*\",\n \"Bel Th. *obsolete*\",\n \"Extra A\",\n \"Extra B\",\n \"Extra C\",\n \"Extra D\",\n \"Extra E\",\n \"Extra F\",\n \"Extra G\",\n \"Front Matter\",\n \"Back Matter\",\n \"Other Matter\",\n \"3 Ezra *obsolete*\",\n \"Apocalypse of Ezra\",\n \"5 Ezra (Latin Prologue)\",\n \"6 Ezra (Latin Epilogue)\",\n \"Introduction\",\n \"Concordance \",\n \"Glossary \",\n \"Topical Index\",\n \"Names Index\",\n \"Daniel Greek\",\n \"Psalms 152-155\",\n \"2 Baruch (Apocalypse)\",\n \"Letter of Baruch\",\n \"Jubilees\",\n \"Enoch\",\n \"1 Meqabyan\",\n \"2 Meqabyan\",\n \"3 Meqabyan\",\n \"Reproof (Proverbs 25-31)\",\n \"4 Baruch (Rest of Baruch)\",\n \"Laodiceans\"\n], S = K();\nfunction g(t, e = !0) {\n return e && (t = t.toUpperCase()), t in S ? S[t] : 0;\n}\nfunction k(t) {\n return g(t) > 0;\n}\nfunction x(t) {\n const e = typeof t == \"string\" ? g(t) : t;\n return e >= 40 && e <= 66;\n}\nfunction T(t) {\n return (typeof t == \"string\" ? g(t) : t) <= 39;\n}\nfunction X(t) {\n return t <= 66;\n}\nfunction V(t) {\n const e = typeof t == \"string\" ? g(t) : t;\n return w(e) && !X(e);\n}\nfunction* L() {\n for (let t = 1; t <= N.length; t++) yield t;\n}\nconst G = 1, A = N.length;\nfunction H() {\n return [\"XXA\", \"XXB\", \"XXC\", \"XXD\", \"XXE\", \"XXF\", \"XXG\"];\n}\nfunction C(t, e = \"***\") {\n const s = t - 1;\n return s < 0 || s >= N.length ? e : N[s];\n}\nfunction I(t) {\n return t <= 0 || t > A ? \"******\" : O[t - 1];\n}\nfunction y(t) {\n return I(g(t));\n}\nfunction w(t) {\n const e = typeof t == \"number\" ? C(t) : t;\n return k(e) && !B.includes(e);\n}\nfunction q(t) {\n const e = typeof t == \"number\" ? C(t) : t;\n return k(e) && B.includes(e);\n}\nfunction U(t) {\n return O[t - 1].includes(\"*obsolete*\");\n}\nfunction K() {\n const t = {};\n for (let e = 0; e < N.length; e++)\n t[N[e]] = e + 1;\n return t;\n}\nconst m = {\n allBookIds: N,\n nonCanonicalIds: B,\n bookIdToNumber: g,\n isBookIdValid: k,\n isBookNT: x,\n isBookOT: T,\n isBookOTNT: X,\n isBookDC: V,\n allBookNumbers: L,\n firstBook: G,\n lastBook: A,\n extraBooks: H,\n bookNumberToId: C,\n bookNumberToEnglishName: I,\n bookIdToEnglishName: y,\n isCanonical: w,\n isExtraMaterial: q,\n isObsolete: U\n};\nvar l = /* @__PURE__ */ ((t) => (t[t.Unknown = 0] = \"Unknown\", t[t.Original = 1] = \"Original\", t[t.Septuagint = 2] = \"Septuagint\", t[t.Vulgate = 3] = \"Vulgate\", t[t.English = 4] = \"English\", t[t.RussianProtestant = 5] = \"RussianProtestant\", t[t.RussianOrthodox = 6] = \"RussianOrthodox\", t))(l || {});\nconst h = class h {\n // private versInfo: Versification;\n constructor(e) {\n n(this, \"name\");\n n(this, \"fullPath\");\n n(this, \"isPresent\");\n n(this, \"hasVerseSegments\");\n n(this, \"isCustomized\");\n n(this, \"baseVersification\");\n n(this, \"scriptureBooks\");\n n(this, \"_type\");\n if (e == null)\n throw new Error(\"Argument undefined\");\n typeof e == \"string\" ? (this.name = e, this._type = l[e]) : (this._type = e, this.name = l[e]);\n }\n get type() {\n return this._type;\n }\n equals(e) {\n return !e.type || !this.type ? !1 : e.type === this.type;\n }\n};\nn(h, \"Original\", new h(l.Original)), n(h, \"Septuagint\", new h(l.Septuagint)), n(h, \"Vulgate\", new h(l.Vulgate)), n(h, \"English\", new h(l.English)), n(h, \"RussianProtestant\", new h(l.RussianProtestant)), n(h, \"RussianOrthodox\", new h(l.RussianOrthodox));\nlet c = h;\nfunction E(t, e) {\n const s = e[0];\n for (let r = 1; r < e.length; r++)\n t = t.split(e[r]).join(s);\n return t.split(s);\n}\nvar D = /* @__PURE__ */ ((t) => (t[t.Valid = 0] = \"Valid\", t[t.UnknownVersification = 1] = \"UnknownVersification\", t[t.OutOfRange = 2] = \"OutOfRange\", t[t.VerseOutOfOrder = 3] = \"VerseOutOfOrder\", t[t.VerseRepeated = 4] = \"VerseRepeated\", t))(D || {});\nconst i = class i {\n constructor(e, s, r, a) {\n /** Not yet implemented. */\n n(this, \"firstChapter\");\n /** Not yet implemented. */\n n(this, \"lastChapter\");\n /** Not yet implemented. */\n n(this, \"lastVerse\");\n /** Not yet implemented. */\n n(this, \"hasSegmentsDefined\");\n /** Not yet implemented. */\n n(this, \"text\");\n /** Not yet implemented. */\n n(this, \"BBBCCCVVVS\");\n /** Not yet implemented. */\n n(this, \"longHashCode\");\n /** The versification of the reference. */\n n(this, \"versification\");\n n(this, \"rtlMark\", \"‏\");\n n(this, \"_bookNum\", 0);\n n(this, \"_chapterNum\", 0);\n n(this, \"_verseNum\", 0);\n n(this, \"_verse\");\n if (r == null && a == null)\n if (e != null && typeof e == \"string\") {\n const o = e, u = s != null && s instanceof c ? s : void 0;\n this.setEmpty(u), this.parse(o);\n } else if (e != null && typeof e == \"number\") {\n const o = s != null && s instanceof c ? s : void 0;\n this.setEmpty(o), this._verseNum = e % i.chapterDigitShifter, this._chapterNum = Math.floor(\n e % i.bookDigitShifter / i.chapterDigitShifter\n ), this._bookNum = Math.floor(e / i.bookDigitShifter);\n } else if (s == null)\n if (e != null && e instanceof i) {\n const o = e;\n this._bookNum = o.bookNum, this._chapterNum = o.chapterNum, this._verseNum = o.verseNum, this._verse = o.verse, this.versification = o.versification;\n } else {\n if (e == null) return;\n const o = e instanceof c ? e : i.defaultVersification;\n this.setEmpty(o);\n }\n else\n throw new Error(\"VerseRef constructor not supported.\");\n else if (e != null && s != null && r != null)\n if (typeof e == \"string\" && typeof s == \"string\" && typeof r == \"string\")\n this.setEmpty(a), this.updateInternal(e, s, r);\n else if (typeof e == \"number\" && typeof s == \"number\" && typeof r == \"number\")\n this._bookNum = e, this._chapterNum = s, this._verseNum = r, this.versification = a ?? i.defaultVersification;\n else\n throw new Error(\"VerseRef constructor not supported.\");\n else\n throw new Error(\"VerseRef constructor not supported.\");\n }\n /**\n * Determines if the verse string is in a valid format (does not consider versification).\n */\n static isVerseParseable(e) {\n return e.length > 0 && \"0123456789\".includes(e[0]) && !e.endsWith(this.verseRangeSeparator) && !e.endsWith(this.verseSequenceIndicator);\n }\n /**\n * Tries to parse the specified string into a verse reference.\n * @param str - The string to attempt to parse.\n * @returns success: `true` if the specified string was successfully parsed, `false` otherwise.\n * @returns verseRef: The result of the parse if successful, or empty VerseRef if it failed\n */\n static tryParse(e) {\n let s;\n try {\n return s = new i(e), { success: !0, verseRef: s };\n } catch (r) {\n if (r instanceof v)\n return s = new i(), { success: !1, verseRef: s };\n throw r;\n }\n }\n /**\n * Gets the reference as a comparable integer where the book, chapter, and verse each occupy 3\n * digits.\n * @param bookNum - Book number (this is 1-based, not an index).\n * @param chapterNum - Chapter number.\n * @param verseNum - Verse number.\n * @returns The reference as a comparable integer where the book, chapter, and verse each occupy 3\n * digits.\n */\n static getBBBCCCVVV(e, s, r) {\n return e % i.bcvMaxValue * i.bookDigitShifter + (s >= 0 ? s % i.bcvMaxValue * i.chapterDigitShifter : 0) + (r >= 0 ? r % i.bcvMaxValue : 0);\n }\n /**\n * Deserializes a serialized VerseRef.\n * @param serializedVerseRef - Serialized VerseRef to create from.\n * @returns the deserialized VerseRef.\n */\n static fromJSON(e) {\n const { book: s, chapterNum: r, verseNum: a, verse: o, versificationStr: u } = e, f = o || a.toString();\n let d;\n return u && (d = new c(u)), s ? new i(s, r.toString(), f, d) : new i();\n }\n /**\n * Parses a verse string and gets the leading numeric portion as a number.\n * @param verseStr - verse string to parse\n * @returns true if the entire string could be parsed as a single, simple verse number (1-999);\n * false if the verse string represented a verse bridge, contained segment letters, or was invalid\n */\n static tryGetVerseNum(e) {\n let s;\n if (!e)\n return s = -1, { success: !0, vNum: s };\n s = 0;\n let r;\n for (let a = 0; a < e.length; a++) {\n if (r = e[a], r < \"0\" || r > \"9\")\n return a === 0 && (s = -1), { success: !1, vNum: s };\n if (s = s * 10 + +r - 0, s > i.bcvMaxValue)\n return s = -1, { success: !1, vNum: s };\n }\n return { success: !0, vNum: s };\n }\n /**\n * Checks to see if a VerseRef hasn't been set - all values are the default.\n */\n get isDefault() {\n return this.bookNum === 0 && this.chapterNum === 0 && this.verseNum === 0 && this.versification == null;\n }\n /**\n * Gets whether the verse contains multiple verses.\n */\n get hasMultiple() {\n return this._verse != null && (this._verse.includes(i.verseRangeSeparator) || this._verse.includes(i.verseSequenceIndicator));\n }\n /**\n * Gets or sets the book of the reference. Book is the 3-letter abbreviation in capital letters,\n * e.g. `'MAT'`.\n */\n get book() {\n return m.bookNumberToId(this.bookNum, \"\");\n }\n set book(e) {\n this.bookNum = m.bookIdToNumber(e);\n }\n /**\n * Gets or sets the chapter of the reference,. e.g. `'3'`.\n */\n get chapter() {\n return this.isDefault || this._chapterNum < 0 ? \"\" : this._chapterNum.toString();\n }\n set chapter(e) {\n const s = +e;\n this._chapterNum = Number.isInteger(s) ? s : -1;\n }\n /**\n * Gets or sets the verse of the reference, including range, segments, and sequences, e.g. `'4'`,\n * or `'4b-5a, 7'`.\n */\n get verse() {\n return this._verse != null ? this._verse : this.isDefault || this._verseNum < 0 ? \"\" : this._verseNum.toString();\n }\n set verse(e) {\n const { success: s, vNum: r } = i.tryGetVerseNum(e);\n this._verse = s ? void 0 : e.replace(this.rtlMark, \"\"), this._verseNum = r, !(this._verseNum >= 0) && ({ vNum: this._verseNum } = i.tryGetVerseNum(this._verse));\n }\n /**\n * Get or set Book based on book number, e.g. `42`.\n */\n get bookNum() {\n return this._bookNum;\n }\n set bookNum(e) {\n if (e <= 0 || e > m.lastBook)\n throw new v(\n \"BookNum must be greater than zero and less than or equal to last book\"\n );\n this._bookNum = e;\n }\n /**\n * Gets or sets the chapter number, e.g. `3`. `-1` if not valid.\n */\n get chapterNum() {\n return this._chapterNum;\n }\n set chapterNum(e) {\n this.chapterNum = e;\n }\n /**\n * Gets or sets verse start number, e.g. `4`. `-1` if not valid.\n */\n get verseNum() {\n return this._verseNum;\n }\n set verseNum(e) {\n this._verseNum = e;\n }\n /**\n * String representing the versification (should ONLY be used for serialization/deserialization).\n *\n * @remarks This is for backwards compatibility when ScrVers was an enumeration.\n */\n get versificationStr() {\n var e;\n return (e = this.versification) == null ? void 0 : e.name;\n }\n set versificationStr(e) {\n this.versification = this.versification != null ? new c(e) : void 0;\n }\n /**\n * Determines if the reference is valid.\n */\n get valid() {\n return this.validStatus === 0;\n }\n /**\n * Get the valid status for this reference.\n */\n get validStatus() {\n return this.validateVerse(i.verseRangeSeparators, i.verseSequenceIndicators);\n }\n /**\n * Gets the reference as a comparable integer where the book,\n * chapter, and verse each occupy three digits and the verse is 0.\n */\n get BBBCCC() {\n return i.getBBBCCCVVV(this._bookNum, this._chapterNum, 0);\n }\n /**\n * Gets the reference as a comparable integer where the book,\n * chapter, and verse each occupy three digits. If verse is not null\n * (i.e., this reference represents a complex reference with verse\n * segments or bridge) this cannot be used for an exact comparison.\n */\n get BBBCCCVVV() {\n return i.getBBBCCCVVV(this._bookNum, this._chapterNum, this._verseNum);\n }\n /**\n * Gets whether the verse is defined as an excluded verse in the versification.\n * Does not handle verse ranges.\n */\n // eslint-disable-next-line @typescript-eslint/class-literal-property-style\n get isExcluded() {\n return !1;\n }\n /**\n * Parses the reference in the specified string.\n * Optionally versification can follow reference as in GEN 3:11/4\n * Throw an exception if\n * - invalid book name\n * - chapter number is missing or not a number\n * - verse number is missing or does not start with a number\n * - versification is invalid\n * @param verseStr - string to parse e.g. 'MAT 3:11'\n */\n parse(e) {\n if (e = e.replace(this.rtlMark, \"\"), e.includes(\"/\")) {\n const o = e.split(\"/\");\n if (e = o[0], o.length > 1)\n try {\n const u = +o[1].trim();\n this.versification = new c(l[u]);\n } catch {\n throw new v(\"Invalid reference : \" + e);\n }\n }\n const s = e.trim().split(\" \");\n if (s.length !== 2)\n throw new v(\"Invalid reference : \" + e);\n const r = s[1].split(\":\"), a = +r[0];\n if (r.length !== 2 || m.bookIdToNumber(s[0]) === 0 || !Number.isInteger(a) || a < 0 || !i.isVerseParseable(r[1]))\n throw new v(\"Invalid reference : \" + e);\n this.updateInternal(s[0], r[0], r[1]);\n }\n /**\n * Simplifies this verse ref so that it has no bridging of verses or\n * verse segments like `'1a'`.\n */\n simplify() {\n this._verse = void 0;\n }\n /**\n * Makes a clone of the reference.\n *\n * @returns The cloned VerseRef.\n */\n clone() {\n return new i(this);\n }\n toString() {\n const e = this.book;\n return e === \"\" ? \"\" : `${e} ${this.chapter}:${this.verse}`;\n }\n toJSON() {\n let e = this.verse;\n (e === \"\" || e === this.verseNum.toString()) && (e = void 0);\n const s = {\n book: this.book,\n chapterNum: this.chapterNum,\n verseNum: this.verseNum,\n verse: e,\n versificationStr: this.versificationStr\n };\n return e || delete s.verse, s;\n }\n /**\n * Compares this `VerseRef` with supplied one.\n * @param verseRef - object to compare this one to.\n * @returns `true` if this `VerseRef` is equal to the supplied one, `false` otherwise.\n */\n equals(e) {\n return e instanceof i ? e._bookNum === this._bookNum && e._chapterNum === this._chapterNum && e._verseNum === this._verseNum && e.verse === this.verse && (e.versification == null && this.versification == null || e.versification != null && this.versification != null && e.versification.equals(this.versification)) : !1;\n }\n /**\n * Enumerate all individual verses contained in a VerseRef.\n * Verse ranges are indicated by \"-\" and consecutive verses by \",\"s.\n * Examples:\n * GEN 1:2 returns GEN 1:2\n * GEN 1:1a-3b,5 returns GEN 1:1a, GEN 1:2, GEN 1:3b, GEN 1:5\n * GEN 1:2a-2c returns //! ??????\n *\n * @param specifiedVersesOnly - if set to true return only verses that are\n * explicitly specified only, not verses within a range. Defaults to `false`.\n * @param verseRangeSeparators - Verse range separators.\n * Defaults to `VerseRef.verseRangeSeparators`.\n * @param verseSequenceSeparators - Verse sequence separators.\n * Defaults to `VerseRef.verseSequenceIndicators`.\n * @returns An array of all single verse references in this VerseRef.\n */\n allVerses(e = !1, s = i.verseRangeSeparators, r = i.verseSequenceIndicators) {\n if (this._verse == null || this.chapterNum <= 0)\n return [this.clone()];\n const a = [], o = E(this._verse, r);\n for (const u of o.map((f) => E(f, s))) {\n const f = this.clone();\n f.verse = u[0];\n const d = f.verseNum;\n if (a.push(f), u.length > 1) {\n const b = this.clone();\n if (b.verse = u[1], !e)\n for (let p = d + 1; p < b.verseNum; p++) {\n const J = new i(\n this._bookNum,\n this._chapterNum,\n p,\n this.versification\n );\n this.isExcluded || a.push(J);\n }\n a.push(b);\n }\n }\n return a;\n }\n /**\n * Validates a verse number using the supplied separators rather than the defaults.\n */\n validateVerse(e, s) {\n if (!this.verse)\n return this.internalValid;\n let r = 0;\n for (const a of this.allVerses(!0, e, s)) {\n const o = a.internalValid;\n if (o !== 0)\n return o;\n const u = a.BBBCCCVVV;\n if (r > u)\n return 3;\n if (r === u)\n return 4;\n r = u;\n }\n return 0;\n }\n /**\n * Gets whether a single verse reference is valid.\n */\n get internalValid() {\n return this.versification == null ? 1 : this._bookNum <= 0 || this._bookNum > m.lastBook ? 2 : (m.isCanonical(this._bookNum), 0);\n }\n setEmpty(e = i.defaultVersification) {\n this._bookNum = 0, this._chapterNum = -1, this._verse = void 0, this.versification = e;\n }\n updateInternal(e, s, r) {\n this.bookNum = m.bookIdToNumber(e), this.chapter = s, this.verse = r;\n }\n};\nn(i, \"defaultVersification\", c.English), n(i, \"verseRangeSeparator\", \"-\"), n(i, \"verseSequenceIndicator\", \",\"), n(i, \"verseRangeSeparators\", [i.verseRangeSeparator]), n(i, \"verseSequenceIndicators\", [i.verseSequenceIndicator]), n(i, \"chapterDigitShifter\", 1e3), n(i, \"bookDigitShifter\", i.chapterDigitShifter * i.chapterDigitShifter), n(i, \"bcvMaxValue\", i.chapterDigitShifter - 1), /**\n * The valid status of the VerseRef.\n */\nn(i, \"ValidStatusType\", D);\nlet M = i;\nclass v extends Error {\n}\nexport {\n _ as BookSet,\n m as Canon,\n c as ScrVers,\n l as ScrVersType,\n M as VerseRef,\n v as VerseRefException\n};\n//# sourceMappingURL=index.es.js.map\n","import React from 'react';\nimport * as DropdownMenuPrimitive from '@radix-ui/react-dropdown-menu';\nimport { Check, ChevronRight, Circle } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport const DropdownMenu = DropdownMenuPrimitive.Root;\n\nexport const DropdownMenuTrigger = DropdownMenuPrimitive.Trigger;\n\nexport const DropdownMenuGroup = DropdownMenuPrimitive.Group;\n\nexport const DropdownMenuPortal = DropdownMenuPrimitive.Portal;\n\nexport const DropdownMenuSub = DropdownMenuPrimitive.Sub;\n\nexport const DropdownMenuRadioGroup = DropdownMenuPrimitive.RadioGroup;\n\nexport type DropdownMenuSubTriggerProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.SubTrigger\n> & {\n className?: string;\n inset?: boolean;\n};\n\nexport type DropdownMenuSubContentProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.SubContent\n> & {\n className?: string;\n};\n\nexport type DropdownMenuContentProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Content\n> & {\n className?: string;\n sideOffset?: number;\n};\n\nexport type DropdownMenuItemProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Item\n> & {\n className?: string;\n inset?: boolean;\n};\n\nexport type DropdownMenuCheckboxItemProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.CheckboxItem\n> & {\n className?: string;\n checked?: boolean;\n};\n\nexport type DropdownMenuRadioItemProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.RadioItem\n> & {\n className?: string;\n};\n\nexport type DropdownMenuLabelProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Label\n> & {\n className?: string;\n inset?: boolean;\n};\n\nexport type DropdownMenuSeparatorProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Separator\n> & {\n className?: string;\n};\n\nexport type DropdownMenuShortcutProps = React.HTMLAttributes & {\n className?: string;\n};\n\nexport const DropdownMenuSubTrigger = React.forwardRef<\n React.ElementRef,\n DropdownMenuSubTriggerProps\n>(({ className, inset, children, ...props }, ref) => (\n \n {children}\n \n \n));\nDropdownMenuSubTrigger.displayName = DropdownMenuPrimitive.SubTrigger.displayName;\n\nexport const DropdownMenuSubContent = React.forwardRef<\n React.ElementRef,\n DropdownMenuSubContentProps\n>(({ className, ...props }, ref) => (\n \n));\nDropdownMenuSubContent.displayName = DropdownMenuPrimitive.SubContent.displayName;\n\nexport const DropdownMenuContent = React.forwardRef<\n React.ElementRef,\n DropdownMenuContentProps\n>(({ className, sideOffset = 4, ...props }, ref) => (\n \n \n \n));\nDropdownMenuContent.displayName = DropdownMenuPrimitive.Content.displayName;\n\n/**\n * TODO: fix: direction is not automatically handled by this component, so that shortcuts are\n * display always to the right\n */\nexport const DropdownMenuItem = React.forwardRef<\n React.ElementRef,\n DropdownMenuItemProps\n>(({ className, inset, ...props }, ref) => (\n \n));\nDropdownMenuItem.displayName = DropdownMenuPrimitive.Item.displayName;\n\nexport const DropdownMenuCheckboxItem = React.forwardRef<\n React.ElementRef,\n DropdownMenuCheckboxItemProps\n>(({ className, children, checked, ...props }, ref) => (\n \n \n \n \n \n \n {children}\n \n));\nDropdownMenuCheckboxItem.displayName = DropdownMenuPrimitive.CheckboxItem.displayName;\n\nexport const DropdownMenuRadioItem = React.forwardRef<\n React.ElementRef,\n DropdownMenuRadioItemProps\n>(({ className, children, ...props }, ref) => (\n \n \n \n \n \n \n {children}\n \n));\nDropdownMenuRadioItem.displayName = DropdownMenuPrimitive.RadioItem.displayName;\n\nexport const DropdownMenuLabel = React.forwardRef<\n React.ElementRef,\n DropdownMenuLabelProps\n>(({ className, inset, ...props }, ref) => (\n \n));\nDropdownMenuLabel.displayName = DropdownMenuPrimitive.Label.displayName;\n\nexport const DropdownMenuSeparator = React.forwardRef<\n React.ElementRef,\n DropdownMenuSeparatorProps\n>(({ className, ...props }, ref) => (\n \n));\nDropdownMenuSeparator.displayName = DropdownMenuPrimitive.Separator.displayName;\n\nexport function DropdownMenuShortcut({ className, ...props }: DropdownMenuShortcutProps) {\n return (\n \n );\n}\nDropdownMenuShortcut.displayName = 'DropdownMenuShortcut';\n","import { Canon } from '@sillsdev/scripture';\nimport { PropsWithChildren, KeyboardEvent, forwardRef } from 'react';\nimport { DropdownMenuItem as ShadDropdownMenuItem } from '@/components/shadcn-ui/dropdown-menu';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport type BookType = 'OT' | 'NT' | 'DC';\n\ntype BookMenuItemProps = PropsWithChildren<{\n /** String id of book */\n bookId: string;\n /** Callback to run when a book menu item is selected */\n handleSelectBook: () => void;\n /** Indicates if this menu item is currently selected */\n isSelected: boolean;\n /** Function that is called upon highlighting a book in the dropdown menu */\n handleHighlightBook: () => void;\n /**\n * Function that is called on pressing a key\n *\n * @param event Event that contains information about the key stroke\n */\n handleKeyDown: (event: KeyboardEvent) => void;\n /**\n * Type of book associated with this menu item, coordinates color labels ? Mock up has the labels\n * coordinated to genre\n */\n bookType: BookType;\n}>;\n\nconst BookMenuItem = forwardRef(\n (\n {\n bookId,\n handleSelectBook,\n isSelected,\n handleHighlightBook,\n handleKeyDown,\n bookType,\n children,\n }: BookMenuItemProps,\n ref,\n ) => {\n return (\n {\n // preventDefault() here prevents the entire dropdown menu from closing when selecting this item\n event.preventDefault();\n handleSelectBook();\n }}\n onKeyDown={(event: KeyboardEvent) => {\n handleKeyDown(event);\n }}\n onFocus={handleHighlightBook}\n onMouseMove={handleHighlightBook}\n >\n \n {Canon.bookIdToEnglishName(bookId)}\n \n {isSelected &&
    {children}
    }\n \n );\n },\n);\n\nexport default BookMenuItem;\n","import { cn } from '@/utils/shadcn-ui.util';\nimport { useCallback } from 'react';\n\nexport type ChapterSelectProps = {\n /**\n * Callback to run when a chapter div is selected\n *\n * @param chapterNumber Number of the chapter that has been selected\n */\n handleSelectChapter: (chapterNumber: number) => void;\n /** The highest chapter number in the book (of course equal to number of chapters in the book) */\n endChapter: number;\n /** The chapter number that is currently selected */\n activeChapter: number;\n /** The chapter number that is currently highlighted using keyboard or mouse navigation */\n highlightedChapter: number;\n /**\n * Callback to run when a chapter is highlighted by the user\n *\n * @param chapterNumber The chapter that is highlighted\n */\n handleHighlightedChapter: (chapterNumber: number) => void;\n};\n\nfunction ChapterSelect({\n handleSelectChapter,\n endChapter,\n activeChapter,\n highlightedChapter,\n handleHighlightedChapter,\n}: ChapterSelectProps) {\n const chapters = Array.from({ length: endChapter }, (_, i) => i + 1);\n\n const handleMouse = useCallback(\n (chapterNumber: number) => {\n handleHighlightedChapter(chapterNumber);\n },\n [handleHighlightedChapter],\n );\n\n return (\n
    \n {chapters.map((chapter) => (\n {\n event.preventDefault();\n event.stopPropagation();\n handleSelectChapter(chapter);\n }}\n role=\"button\"\n onKeyDown={(event) => {\n if (event.key === 'Enter') {\n handleSelectChapter(chapter);\n }\n }}\n tabIndex={0}\n onMouseMove={() => handleMouse(chapter)}\n >\n {chapter}\n
    \n ))}\n
    \n );\n}\n\nexport default ChapterSelect;\n","import { DropdownMenuLabel as ShadDropdownMenuLabel } from '@/components/shadcn-ui/dropdown-menu';\nimport { Bookmark, Clock, ArrowDownWideNarrow } from 'lucide-react';\n\nexport type GoToMenuItemProps = {\n handleSort: () => void;\n handleLocationHistory: () => void;\n handleBookmarks: () => void;\n};\n\nfunction GoToMenuItem({ handleSort, handleLocationHistory, handleBookmarks }: GoToMenuItemProps) {\n return (\n \n

    Go To

    \n
    \n \n \n \n
    \n
    \n );\n}\n\nexport default GoToMenuItem;\n","import BookChapterInput from '@/components/advanced/book-chapter-control/book-chapter-input.component';\nimport BookMenuItem, {\n BookType,\n} from '@/components/advanced/book-chapter-control/book-menu-item.component';\nimport ChapterSelect from '@/components/advanced/book-chapter-control/chapter-select.component';\nimport GoToMenuItem from '@/components/advanced/book-chapter-control/go-to-menu-item.component';\nimport {\n DropdownMenu as ShadDropdownMenu,\n DropdownMenuContent as ShadDropdownMenuContent,\n DropdownMenuLabel as ShadDropdownMenuLabel,\n DropdownMenuSeparator as ShadDropdownMenuSeparator,\n DropdownMenuTrigger as ShadDropdownMenuTrigger,\n} from '@/components/shadcn-ui/dropdown-menu';\nimport { Canon } from '@sillsdev/scripture';\nimport { ScriptureReference, getChaptersForBook } from 'platform-bible-utils';\nimport {\n KeyboardEvent as ReactKeyboardEvent,\n useCallback,\n useEffect,\n useLayoutEffect,\n useRef,\n useState,\n} from 'react';\n\ntype BookTypeLabels = {\n [bookType in BookType]: string;\n};\ntype BookChapterControlProps = {\n scrRef: ScriptureReference;\n handleSubmit: (scrRef: ScriptureReference) => void;\n};\n\nconst ALL_BOOK_IDS = Canon.allBookIds;\nconst BOOK_TYPE_LABELS: BookTypeLabels = {\n OT: 'Old Testament',\n NT: 'New Testament',\n DC: 'Deuterocanon',\n};\nconst BOOK_TYPE_ARRAY: BookType[] = ['OT', 'NT', 'DC'];\n// This is the height of three menu items to offset scrolling to the selected menu item\n// If you use menuItemRef.clientHeight- includes height of chapter div which is too big\nconst SCROLL_OFFSET = 32 + 32 + 32;\nconst SEARCH_QUERY_FORMATS = [\n /^(\\w+)$/i, // Matches a single word (book name or id)\n /^(\\w+)(?:\\s(\\d+))$/i, // Matches a word followed by a chapter number\n /^(\\w+)(?:\\s(\\d+):(\\d+))$/i, // Matches a word followed by a chapter and verse number\n];\nconst fetchGroupedBooks = (bookType: BookType) => {\n const groupedBooks = {\n OT: ALL_BOOK_IDS.filter((bookId) => Canon.isBookOT(bookId)),\n NT: ALL_BOOK_IDS.filter((bookId) => Canon.isBookNT(bookId)),\n DC: ALL_BOOK_IDS.filter((bookId) => Canon.isBookDC(bookId)),\n };\n return groupedBooks[bookType];\n};\nconst fetchEndChapter = (bookId: string) => {\n // getChaptersForBook returns -1 if not found in scrBookData\n // scrBookData only includes OT and NT, so all DC will return -1\n return getChaptersForBook(Canon.bookIdToNumber(bookId));\n};\n\n/**\n * Gets all of the English names from book ids\n *\n * @returns String[]\n */\nfunction getAllEnglishNames(): string[] {\n const allEnglishNames = ALL_BOOK_IDS.map((bookId) => {\n return Canon.bookIdToEnglishName(bookId);\n });\n return allEnglishNames;\n}\n\n/**\n * Determines if bookName is in allEnglishNames\n *\n * @param bookName Book English name\n * @returns True if bookName is included, false otherwise\n */\nfunction isValidBookEnglishName(bookName: string): boolean {\n return getAllEnglishNames().includes(bookName);\n}\n\n/**\n * Gets a bookId from given English name\n *\n * @param bookName Book English name\n * @returns BookId of provided bookName, undefined otherwise\n */\nfunction getBookIdFromEnglishName(bookName: string): string | undefined {\n // Convert bookName to lowercase and then capitalize the first letter\n const formattedBookName = bookName.toLowerCase().replace(/^\\w/, (c) => c.toUpperCase());\n\n if (isValidBookEnglishName(formattedBookName)) {\n const matchingBookId = ALL_BOOK_IDS.find((bookId) => {\n return Canon.bookIdToEnglishName(bookId) === formattedBookName;\n });\n return matchingBookId;\n }\n\n return undefined;\n}\n\nfunction BookChapterControl({ scrRef, handleSubmit }: BookChapterControlProps) {\n const [searchQuery, setSearchQuery] = useState('');\n const [selectedBookId, setSelectedBookId] = useState(\n Canon.bookNumberToId(scrRef.bookNum),\n );\n const [highlightedChapter, setHighlightedChapter] = useState(scrRef.chapterNum ?? 0);\n const [highlightedBookId, setHighlightedBookId] = useState(\n Canon.bookNumberToId(scrRef.bookNum),\n );\n const [isContentOpen, setIsContentOpen] = useState(false);\n const [isContentOpenDelayed, setIsContentOpenDelayed] = useState(isContentOpen);\n\n // This ref will always be defined\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const inputRef = useRef(undefined!);\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const contentRef = useRef(undefined!);\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const menuItemRef = useRef(undefined!);\n\n const fetchFilteredBooks = useCallback(\n (bookType: BookType) => {\n return fetchGroupedBooks(bookType).filter((bookId: string) => {\n const englishNameLowerCase = Canon.bookIdToEnglishName(bookId).toLowerCase();\n const normalizedQuery = searchQuery.replace(/[^a-zA-Z]/g, '').toLowerCase();\n return (\n englishNameLowerCase.includes(normalizedQuery) || // Match book name\n bookId.toLowerCase().includes(normalizedQuery) // Match book ID\n );\n });\n },\n [searchQuery],\n );\n\n const handleSearchInput = (searchString: string) => {\n setSearchQuery(searchString);\n };\n\n /**\n * Whether to prevent radix's logic from closing the dropdown. This is important because radix\n * tries to close the dropdown when the input first focuses, and we don't want it to do that. But\n * we don't want to prevent the dropdown from closing when we click away from the input, so we\n * don't want to just keep it open if the input is focused\n */\n const shouldPreventAutoClosing = useRef(false);\n\n const controlMenuState = useCallback((open: boolean) => {\n if (shouldPreventAutoClosing.current) {\n shouldPreventAutoClosing.current = false;\n return;\n }\n setIsContentOpen(open);\n }, []);\n\n const updateReference = useCallback(\n (bookId: string, shouldClose: boolean, chapter?: number, verse?: number) => {\n setHighlightedChapter(\n Canon.bookNumberToId(scrRef.bookNum) !== bookId ? 1 : scrRef.chapterNum,\n );\n\n if (shouldClose || fetchEndChapter(bookId) === -1) {\n handleSubmit({\n bookNum: Canon.bookIdToNumber(bookId),\n chapterNum: chapter || 1,\n verseNum: verse || 1,\n });\n\n setIsContentOpen(false);\n setSearchQuery('');\n return;\n }\n\n setSelectedBookId(selectedBookId !== bookId ? bookId : '');\n setIsContentOpen(!shouldClose);\n },\n [handleSubmit, scrRef.bookNum, scrRef.chapterNum, selectedBookId],\n );\n\n const handleSelectChapter = (chapterNumber: number) => {\n if (chapterNumber <= 0 || chapterNumber > fetchEndChapter(selectedBookId)) {\n return;\n }\n updateReference(selectedBookId, true, chapterNumber);\n };\n\n const handleInputSubmit = useCallback(() => {\n SEARCH_QUERY_FORMATS.forEach((format) => {\n const matches = searchQuery.match(format);\n if (matches) {\n // Book should be a bookId or an english name\n const [book, chapter = undefined, verse = undefined] = matches.slice(1);\n const englishName = getBookIdFromEnglishName(book);\n\n if (Canon.isBookIdValid(book) || englishName) {\n updateReference(\n englishName ?? book,\n true,\n chapter ? parseInt(chapter, 10) : 1,\n verse ? parseInt(verse, 10) : 1,\n );\n }\n }\n });\n }, [updateReference, searchQuery]);\n\n const handleKeyDownInput = useCallback(\n (event: ReactKeyboardEvent) => {\n if (!isContentOpen) {\n setIsContentOpen(true);\n } else if (event.key === 'ArrowDown' || event.key === 'ArrowUp') {\n if (\n typeof menuItemRef !== 'undefined' &&\n // Ref uses null\n // eslint-disable-next-line no-null/no-null\n menuItemRef.current !== null\n ) {\n menuItemRef.current.focus();\n } else if (\n typeof contentRef !== 'undefined' &&\n // Ref uses null\n // eslint-disable-next-line no-null/no-null\n contentRef.current !== null\n ) {\n contentRef.current.focus();\n }\n event.preventDefault();\n }\n },\n [isContentOpen],\n );\n\n const handleKeyDownContent = (event: ReactKeyboardEvent) => {\n // When the dropdown menu has focus, key strokes should give focus to the input component,\n // unless they're navigation keys (arrows and enter)\n const { key } = event;\n if (\n key === 'ArrowRight' ||\n key === 'ArrowLeft' ||\n key === 'ArrowDown' ||\n key === 'ArrowUp' ||\n key === 'Enter'\n ) {\n return;\n }\n\n inputRef.current.dispatchEvent(new KeyboardEvent('keydown', { key }));\n inputRef.current.focus();\n };\n\n const handleKeyDownMenuItem = (event: ReactKeyboardEvent) => {\n const { key } = event;\n if (highlightedBookId === selectedBookId) {\n if (key === 'Enter') {\n event.preventDefault();\n updateReference(selectedBookId, true, highlightedChapter);\n return;\n }\n\n let chapterOffSet = 0;\n if (key === 'ArrowRight') {\n if (highlightedChapter < fetchEndChapter(highlightedBookId)) {\n chapterOffSet = 1;\n } else {\n event.preventDefault();\n return;\n }\n } else if (key === 'ArrowLeft') {\n if (highlightedChapter > 1) {\n chapterOffSet = -1;\n } else {\n event.preventDefault();\n return;\n }\n } else if (key === 'ArrowDown') {\n chapterOffSet = 6;\n } else if (key === 'ArrowUp') {\n chapterOffSet = -6;\n }\n if (\n highlightedChapter + chapterOffSet <= 0 ||\n highlightedChapter + chapterOffSet > fetchEndChapter(highlightedBookId)\n ) {\n setHighlightedChapter(0);\n } else if (chapterOffSet !== 0) {\n setHighlightedChapter(highlightedChapter + chapterOffSet);\n event.preventDefault();\n }\n }\n };\n\n useEffect(() => {\n if (selectedBookId === highlightedBookId) {\n if (selectedBookId === Canon.bookNumberToId(scrRef.bookNum)) {\n setHighlightedChapter(scrRef.chapterNum);\n } else {\n setHighlightedChapter(1);\n }\n } else {\n setHighlightedChapter(0);\n }\n }, [highlightedBookId, scrRef.bookNum, scrRef.chapterNum, selectedBookId]);\n\n // The purpose of these useLayoutEffects and timeout is to delay the scroll just\n // enough so that the refs are defined and available when they are used after the timeout\n useLayoutEffect(() => {\n setIsContentOpenDelayed(isContentOpen);\n }, [isContentOpen]);\n\n useLayoutEffect(() => {\n const scrollTimeout = setTimeout(() => {\n if (isContentOpenDelayed && contentRef.current && menuItemRef.current) {\n const menuItemOffsetTop = menuItemRef.current.offsetTop;\n const scrollPosition = menuItemOffsetTop - SCROLL_OFFSET;\n contentRef.current.scrollTo({ top: scrollPosition, behavior: 'instant' });\n }\n }, 10);\n return () => {\n clearTimeout(scrollTimeout);\n };\n }, [isContentOpenDelayed]);\n\n return (\n
    \n \n \n {\n setSelectedBookId(Canon.bookNumberToId(scrRef.bookNum));\n setHighlightedBookId(Canon.bookNumberToId(scrRef.bookNum));\n setHighlightedChapter(scrRef.chapterNum > 0 ? scrRef.chapterNum : 0);\n setIsContentOpen(true);\n inputRef.current.focus();\n }}\n onFocus={() => {\n // Radix thinks we want to close because the input is being focused. Prevent that\n shouldPreventAutoClosing.current = true;\n }}\n handleSubmit={handleInputSubmit}\n placeholder={`${Canon.bookNumberToEnglishName(scrRef.bookNum)} ${scrRef.chapterNum}:${scrRef.verseNum}`}\n />\n \n \n console.log('sorting')}\n handleLocationHistory={() => console.log('location history')}\n handleBookmarks={() => console.log('bookmarks')}\n />\n {BOOK_TYPE_ARRAY.map(\n (bookType, bookTypeIndex) =>\n fetchFilteredBooks(bookType).length > 0 && (\n
    \n \n {BOOK_TYPE_LABELS[bookType]}\n \n\n {fetchFilteredBooks(bookType).map((bookId) => (\n
    \n updateReference(bookId, false)}\n isSelected={selectedBookId === bookId}\n handleHighlightBook={() => setHighlightedBookId(bookId)}\n handleKeyDown={handleKeyDownMenuItem}\n bookType={bookType}\n ref={(element: HTMLDivElement) => {\n if (selectedBookId === bookId) menuItemRef.current = element;\n }}\n >\n {\n setHighlightedChapter(chapterNumber);\n }}\n />\n \n
    \n ))}\n {BOOK_TYPE_ARRAY.length - 1 !== bookTypeIndex ? (\n \n ) : undefined}\n
    \n ),\n )}\n \n
    \n
    \n );\n}\n\nexport default BookChapterControl;\n","import React from 'react';\nimport { Slot } from '@radix-ui/react-slot';\nimport { cva, type VariantProps } from 'class-variance-authority';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport const buttonVariants = cva(\n 'pr-twp tw-inline-flex tw-items-center tw-justify-center tw-whitespace-nowrap tw-rounded-md tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-colors focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50',\n {\n variants: {\n variant: {\n default: 'tw-bg-primary tw-text-primary-foreground hover:tw-bg-primary/90',\n destructive: 'tw-bg-destructive tw-text-destructive-foreground hover:tw-bg-destructive/90',\n outline:\n 'tw-border tw-border-input tw-bg-background hover:tw-bg-accent hover:tw-text-accent-foreground',\n secondary: 'tw-bg-secondary tw-text-secondary-foreground hover:tw-bg-secondary/80',\n ghost: 'hover:tw-bg-accent hover:tw-text-accent-foreground',\n link: 'tw-text-primary tw-underline-offset-4 hover:tw-underline',\n },\n size: {\n default: 'tw-h-10 tw-px-4 tw-py-2',\n sm: 'tw-h-9 tw-rounded-md tw-px-3',\n lg: 'tw-h-11 tw-rounded-md tw-px-8',\n icon: 'tw-h-10 tw-w-10',\n },\n },\n defaultVariants: {\n variant: 'default',\n size: 'default',\n },\n },\n);\n\nexport interface ButtonProps\n extends React.ButtonHTMLAttributes,\n VariantProps {\n asChild?: boolean;\n}\n\nexport const Button = React.forwardRef(\n ({ className, variant, size, asChild = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'button';\n return (\n \n );\n },\n);\nButton.displayName = 'Button';\n","import React from 'react';\nimport * as LabelPrimitive from '@radix-ui/react-label';\nimport { cva, type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst labelVariants = cva(\n 'tw-text-sm tw-font-medium tw-leading-none peer-disabled:tw-cursor-not-allowed peer-disabled:tw-opacity-70',\n);\n\nexport const Label = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef & VariantProps\n>(({ className, ...props }, ref) => (\n \n));\nLabel.displayName = LabelPrimitive.Root.displayName;\n","import React from 'react';\nimport * as RadioGroupPrimitive from '@radix-ui/react-radio-group';\nimport { Circle } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst RadioGroup = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => {\n return (\n \n );\n});\nRadioGroup.displayName = RadioGroupPrimitive.Root.displayName;\n\nconst RadioGroupItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => {\n return (\n \n \n \n \n \n );\n});\nRadioGroupItem.displayName = RadioGroupPrimitive.Item.displayName;\n\nexport { RadioGroup, RadioGroupItem };\n","import React from 'react';\nimport * as PopoverPrimitive from '@radix-ui/react-popover';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Popover = PopoverPrimitive.Root;\n\nconst PopoverTrigger = PopoverPrimitive.Trigger;\n\nconst PopoverContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, align = 'center', sideOffset = 4, ...props }, ref) => (\n \n \n \n));\nPopoverContent.displayName = PopoverPrimitive.Content.displayName;\n\nexport { Popover, PopoverTrigger, PopoverContent };\n","import React from 'react';\nimport * as DialogPrimitive from '@radix-ui/react-dialog';\nimport { X } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Dialog = DialogPrimitive.Root;\n\nconst DialogTrigger = DialogPrimitive.Trigger;\n\nconst DialogPortal = DialogPrimitive.Portal;\n\nconst DialogClose = DialogPrimitive.Close;\n\nconst DialogOverlay = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nDialogOverlay.displayName = DialogPrimitive.Overlay.displayName;\n\nconst DialogContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, ...props }, ref) => (\n \n \n \n {children}\n \n \n Close\n \n \n \n));\nDialogContent.displayName = DialogPrimitive.Content.displayName;\n\nfunction DialogHeader({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nDialogHeader.displayName = 'DialogHeader';\n\nfunction DialogFooter({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nDialogFooter.displayName = 'DialogFooter';\n\nconst DialogTitle = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nDialogTitle.displayName = DialogPrimitive.Title.displayName;\n\nconst DialogDescription = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nDialogDescription.displayName = DialogPrimitive.Description.displayName;\n\nexport {\n Dialog,\n DialogPortal,\n DialogOverlay,\n DialogClose,\n DialogTrigger,\n DialogContent,\n DialogHeader,\n DialogFooter,\n DialogTitle,\n DialogDescription,\n};\n","import React from 'react';\nimport { type DialogProps } from '@radix-ui/react-dialog';\nimport { Command as CommandPrimitive } from 'cmdk';\nimport { Search } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Dialog, DialogContent } from '@/components/shadcn-ui/dialog';\n\nconst Command = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nCommand.displayName = CommandPrimitive.displayName;\n\ninterface CommandDialogProps extends DialogProps {}\n\nfunction CommandDialog({ children, ...props }: CommandDialogProps) {\n return (\n \n \n \n {children}\n \n \n \n );\n}\n\nconst CommandInput = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n
    \n \n \n
    \n));\n\nCommandInput.displayName = CommandPrimitive.Input.displayName;\n\nconst CommandList = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\n\nCommandList.displayName = CommandPrimitive.List.displayName;\n\nconst CommandEmpty = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>((props, ref) => (\n \n));\n\nCommandEmpty.displayName = CommandPrimitive.Empty.displayName;\n\nconst CommandGroup = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\n\nCommandGroup.displayName = CommandPrimitive.Group.displayName;\n\nconst CommandSeparator = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nCommandSeparator.displayName = CommandPrimitive.Separator.displayName;\n\nconst CommandItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\n\nCommandItem.displayName = CommandPrimitive.Item.displayName;\n\nfunction CommandShortcut({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nCommandShortcut.displayName = 'CommandShortcut';\n\nexport {\n Command,\n CommandDialog,\n CommandInput,\n CommandList,\n CommandEmpty,\n CommandGroup,\n CommandItem,\n CommandShortcut,\n CommandSeparator,\n};\n","import { useState } from 'react';\nimport { Check, ChevronsUpDown } from 'lucide-react';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport { Popover, PopoverContent, PopoverTrigger } from '@/components/shadcn-ui/popover';\nimport {\n Command,\n CommandEmpty,\n CommandInput,\n CommandItem,\n CommandList,\n} from '@/components/shadcn-ui/command';\nimport { PopoverProps } from '@radix-ui/react-popover';\n\nexport type ComboBoxLabelOption = { label: string };\nexport type ComboBoxOption = string | number | ComboBoxLabelOption;\n\nexport type ComboBoxProps = {\n /** Optional unique identifier */\n id?: string;\n /** Text label title for combobox */\n /** List of available options for the dropdown menu */\n options?: readonly T[];\n /** Additional css classes to help with unique styling of the combo box button */\n buttonClassName?: string;\n /** Additional css classes to help with unique styling of the combo box popover */\n popoverContentClassName?: string;\n /**\n * The selected value that the combo box currently holds. Must be shallow equal to one of the\n * options entries.\n */\n value?: T;\n /** Triggers when content of textfield is changed */\n onChange?: (newValue: T) => void;\n /** Used to determine the string value for a given option. */\n getOptionLabel?: (option: ComboBoxOption) => string;\n /** Text displayed on button if `value` is undefined */\n buttonPlaceholder?: string;\n /** Placeholder text for text field */\n textPlaceholder?: string;\n /** Text to display when no options match input */\n commandEmptyMessage?: string;\n /** Variant of button */\n buttonVariant?: ButtonProps['variant'];\n /** Text direction ltr or rtl */\n dir?: Direction;\n /** Optional boolean to set if trigger should be disabled */\n isDisabled?: boolean;\n} & PopoverProps;\n\ntype Direction = 'ltr' | 'rtl';\n\nfunction getOptionLabelDefault(option: ComboBoxOption): string {\n if (typeof option === 'string') {\n return option;\n }\n if (typeof option === 'number') {\n return option.toString();\n }\n return option.label;\n}\n\n/**\n * Autocomplete input and command palette with a list of suggestions.\n *\n * Thanks to Shadcn for heavy inspiration and documentation\n * https://ui.shadcn.com/docs/components/combobox\n */\nfunction ComboBox({\n id,\n options = [],\n buttonClassName,\n popoverContentClassName,\n value,\n onChange = () => {},\n getOptionLabel = getOptionLabelDefault,\n buttonPlaceholder = '',\n textPlaceholder = '',\n commandEmptyMessage = 'No option found',\n buttonVariant = 'outline',\n dir = 'ltr',\n isDisabled = false,\n ...props\n}: ComboBoxProps) {\n const [open, setOpen] = useState(false);\n\n return (\n \n \n \n \n {value ? getOptionLabel(value) : buttonPlaceholder}\n \n \n \n \n \n \n \n {commandEmptyMessage}\n \n {options.map((option) => (\n {\n onChange(option);\n setOpen(false);\n }}\n >\n \n {getOptionLabel(option)}\n \n ))}\n \n \n \n \n );\n}\n\nexport default ComboBox;\n","import { useMemo } from 'react';\nimport ComboBox from '@/components/basics/combo-box.component';\nimport { Label } from '@/components/shadcn-ui/label';\n\nexport type ChapterRangeSelectorProps = {\n startChapter: number;\n endChapter: number;\n handleSelectStartChapter: (chapter: number) => void;\n handleSelectEndChapter: (chapter: number) => void;\n isDisabled?: boolean;\n chapterCount: number;\n};\n\nexport default function ChapterRangeSelector({\n startChapter,\n endChapter,\n handleSelectStartChapter,\n handleSelectEndChapter,\n isDisabled = false,\n chapterCount,\n}: ChapterRangeSelectorProps) {\n const chapterOptions = useMemo(\n () => Array.from({ length: chapterCount }, (_, index) => index + 1),\n [chapterCount],\n );\n\n const onChangeStartChapter = (value: number) => {\n handleSelectStartChapter(value);\n if (value > endChapter) {\n handleSelectEndChapter(value);\n }\n };\n\n const onChangeEndChapter = (value: number) => {\n handleSelectEndChapter(value);\n if (value < startChapter) {\n handleSelectStartChapter(value);\n }\n };\n\n return (\n <>\n \n option.toString()}\n value={startChapter}\n />\n\n \n option.toString()}\n value={endChapter}\n />\n \n );\n}\n","import { Button } from '@/components/shadcn-ui/button';\nimport { Label } from '@/components/shadcn-ui/label';\nimport { RadioGroup, RadioGroupItem } from '@/components/shadcn-ui/radio-group';\nimport { Canon } from '@sillsdev/scripture';\nimport { LocalizedStringValue } from 'platform-bible-utils';\nimport { useState } from 'react';\nimport ChapterRangeSelector, {\n ChapterRangeSelectorProps,\n} from '../basics/chapter-range-selector.component';\n\nexport enum BookSelectionMode {\n CURRENT_BOOK = 'current book',\n CHOOSE_BOOKS = 'choose books',\n}\n\n/**\n * Object containing all keys used for localization in this component. If you're using this\n * component in an extension, you can pass it into the useLocalizedStrings hook to easily obtain the\n * localized strings and pass them into the localizedStrings prop of this component\n */\nexport const BOOK_SELECTOR_STRING_KEYS = Object.freeze([\n '%webView_bookSelector_currentBook%',\n '%webView_bookSelector_choose%',\n '%webView_bookSelector_chooseBooks%',\n] as const);\n\nexport type BookSelectorLocalizedStrings = {\n [localizedInventoryKey in (typeof BOOK_SELECTOR_STRING_KEYS)[number]]?: LocalizedStringValue;\n};\n\n/**\n * Gets the localized value for the provided key\n *\n * @param strings Object containing localized string\n * @param key Key for a localized string\n * @returns The localized value for the provided key, if available. Returns the key if no localized\n * value is available\n */\nconst localizeString = (\n strings: BookSelectorLocalizedStrings,\n key: keyof BookSelectorLocalizedStrings,\n) => {\n return strings[key] ?? key;\n};\n\ntype BookSelectorProps = ChapterRangeSelectorProps & {\n handleBookSelectionModeChange: (newMode: BookSelectionMode) => void;\n currentBookName: string;\n onSelectBooks: () => void;\n selectedBookIds: string[];\n localizedStrings: BookSelectorLocalizedStrings;\n};\n\nexport default function BookSelector({\n handleBookSelectionModeChange,\n currentBookName,\n onSelectBooks,\n selectedBookIds,\n chapterCount,\n endChapter,\n handleSelectEndChapter,\n startChapter,\n handleSelectStartChapter,\n localizedStrings,\n}: BookSelectorProps) {\n const currentBookText = localizeString(localizedStrings, '%webView_bookSelector_currentBook%');\n const chooseText = localizeString(localizedStrings, '%webView_bookSelector_choose%');\n const chooseBooksText = localizeString(localizedStrings, '%webView_bookSelector_chooseBooks%');\n\n const [bookSelectionMode, setBookSelectionMode] = useState(\n BookSelectionMode.CURRENT_BOOK,\n );\n\n const onSelectionModeChange = (newMode: BookSelectionMode) => {\n setBookSelectionMode(newMode);\n handleBookSelectionModeChange(newMode);\n };\n\n return (\n onSelectionModeChange(value as BookSelectionMode)}\n >\n
    \n
    \n
    \n \n \n
    \n \n
    \n \n
    \n
    \n
    \n
    \n \n \n
    \n \n onSelectBooks()}\n >\n {chooseText}\n \n
    \n
    \n \n );\n}\n","import { DropdownMenuTrigger } from '@radix-ui/react-dropdown-menu';\nimport { FilterIcon } from 'lucide-react';\nimport { Table } from '@tanstack/react-table';\n\nimport { Button } from '@/components/shadcn-ui/button';\nimport {\n DropdownMenu,\n DropdownMenuCheckboxItem,\n DropdownMenuContent,\n DropdownMenuLabel,\n DropdownMenuSeparator,\n} from '@/components/shadcn-ui/dropdown-menu';\n\ninterface DataTableViewOptionsProps {\n table: Table;\n}\n\nfunction DataTableViewOptions({ table }: DataTableViewOptionsProps) {\n return (\n \n \n \n \n \n Toggle columns\n \n {table\n .getAllColumns()\n .filter((column) => column.getCanHide())\n .map((column) => {\n return (\n column.toggleVisibility(!!value)}\n >\n {column.id}\n \n );\n })}\n \n \n );\n}\n\nexport default DataTableViewOptions;\n","import React from 'react';\nimport * as SelectPrimitive from '@radix-ui/react-select';\nimport { Check, ChevronDown, ChevronUp } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Select = SelectPrimitive.Root;\n\nconst SelectGroup = SelectPrimitive.Group;\n\nconst SelectValue = SelectPrimitive.Value;\n\nconst SelectTrigger = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, ...props }, ref) => (\n span]:tw-line-clamp-1',\n className,\n )}\n {...props}\n >\n {children}\n \n \n \n \n));\nSelectTrigger.displayName = SelectPrimitive.Trigger.displayName;\n\nconst SelectScrollUpButton = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n));\nSelectScrollUpButton.displayName = SelectPrimitive.ScrollUpButton.displayName;\n\nconst SelectScrollDownButton = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n));\nSelectScrollDownButton.displayName = SelectPrimitive.ScrollDownButton.displayName;\n\nconst SelectContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, position = 'popper', ...props }, ref) => (\n \n \n \n \n {children}\n \n \n \n \n));\nSelectContent.displayName = SelectPrimitive.Content.displayName;\n\nconst SelectLabel = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSelectLabel.displayName = SelectPrimitive.Label.displayName;\n\nconst SelectItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, ...props }, ref) => (\n \n \n \n \n \n \n\n {children}\n \n));\nSelectItem.displayName = SelectPrimitive.Item.displayName;\n\nconst SelectSeparator = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSelectSeparator.displayName = SelectPrimitive.Separator.displayName;\n\nexport {\n Select,\n SelectGroup,\n SelectValue,\n SelectTrigger,\n SelectContent,\n SelectLabel,\n SelectItem,\n SelectSeparator,\n SelectScrollUpButton,\n SelectScrollDownButton,\n};\n","import { ChevronLeftIcon, ChevronRightIcon, ArrowLeftIcon, ArrowRightIcon } from 'lucide-react';\nimport { Table } from '@tanstack/react-table';\n\nimport { Button } from '@/components/shadcn-ui/button';\nimport {\n Select,\n SelectContent,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\n\ninterface DataTablePaginationProps {\n table: Table;\n}\n\nfunction DataTablePagination({ table }: DataTablePaginationProps) {\n return (\n
    \n
    \n
    \n {table.getFilteredSelectedRowModel().rows.length} of{' '}\n {table.getFilteredRowModel().rows.length} row(s) selected\n
    \n
    \n

    Rows per page

    \n {\n table.setPageSize(Number(value));\n }}\n >\n \n \n \n \n {[10, 20, 30, 40, 50].map((pageSize) => (\n \n {pageSize}\n \n ))}\n \n \n
    \n
    \n Page {table.getState().pagination.pageIndex + 1} of {table.getPageCount()}\n
    \n
    \n table.setPageIndex(0)}\n disabled={!table.getCanPreviousPage()}\n >\n Go to first page\n \n \n table.previousPage()}\n disabled={!table.getCanPreviousPage()}\n >\n Go to previous page\n \n \n table.nextPage()}\n disabled={!table.getCanNextPage()}\n >\n Go to next page\n \n \n table.setPageIndex(table.getPageCount() - 1)}\n disabled={!table.getCanNextPage()}\n >\n Go to last page\n \n \n
    \n
    \n
    \n );\n}\n\nexport default DataTablePagination;\n","import React from 'react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Table = React.forwardRef<\n HTMLTableElement,\n React.HTMLAttributes & { stickyHeader?: boolean }\n>(({ className, stickyHeader, ...props }, ref) => (\n
    \n \n
    \n));\nTable.displayName = 'Table';\n\nconst TableHeader = React.forwardRef<\n HTMLTableSectionElement,\n React.HTMLAttributes & { stickyHeader?: boolean }\n>(({ className, stickyHeader, ...props }, ref) => (\n \n));\nTableHeader.displayName = 'TableHeader';\n\nconst TableBody = React.forwardRef<\n HTMLTableSectionElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableBody.displayName = 'TableBody';\n\nconst TableFooter = React.forwardRef<\n HTMLTableSectionElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n tr]:last:tw-border-b-0', className)}\n {...props}\n />\n));\nTableFooter.displayName = 'TableFooter';\n\nconst TableRow = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nTableRow.displayName = 'TableRow';\n\nconst TableHead = React.forwardRef<\n HTMLTableCellElement,\n React.ThHTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableHead.displayName = 'TableHead';\n\nconst TableCell = React.forwardRef<\n HTMLTableCellElement,\n React.TdHTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableCell.displayName = 'TableCell';\n\nconst TableCaption = React.forwardRef<\n HTMLTableCaptionElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableCaption.displayName = 'TableCaption';\n\nexport { Table, TableHeader, TableBody, TableFooter, TableHead, TableRow, TableCell, TableCaption };\n","import { useState } from 'react';\n\nimport {\n ColumnFiltersState,\n flexRender,\n getCoreRowModel,\n getFilteredRowModel,\n getPaginationRowModel,\n getSortedRowModel,\n SortingState,\n ColumnDef as TSColumnDef,\n Row as TSRow,\n RowSelectionState as TSRowSelectionState,\n SortDirection as TSSortDirection,\n Table as TSTable,\n useReactTable,\n VisibilityState,\n} from '@tanstack/react-table';\n\nimport DataTableViewOptions from '@/components/advanced/data-table/data-table-column-toggle.component';\nimport DataTablePagination from '@/components/advanced/data-table/data-table-pagination.component';\nimport { Button } from '@/components/shadcn-ui/button';\nimport {\n Table,\n TableBody,\n TableCell,\n TableHead,\n TableHeader,\n TableRow,\n} from '@/components/shadcn-ui/table';\n\nexport type ColumnDef = TSColumnDef;\nexport type RowContents = TSRow;\nexport type TableContents = TSTable;\nexport type SortDirection = TSSortDirection;\nexport type RowSelectionState = TSRowSelectionState;\n\ninterface DataTableProps {\n columns: ColumnDef[];\n data: TData[];\n enablePagination?: boolean;\n showPaginationControls?: boolean;\n showColumnVisibilityControls?: boolean;\n stickyHeader?: boolean;\n onRowClickHandler?: (row: RowContents, table: TableContents) => void;\n}\n\n/**\n * Feature-rich table component that infuses our basic shadcn-based Table component with features\n * from TanStack's React Table library\n */\nfunction DataTable({\n columns,\n data,\n enablePagination = false,\n showPaginationControls = false,\n showColumnVisibilityControls = false,\n stickyHeader = false,\n onRowClickHandler = () => {},\n}: DataTableProps) {\n const [sorting, setSorting] = useState([]);\n const [columnFilters, setColumnFilters] = useState([]);\n const [columnVisibility, setColumnVisibility] = useState({});\n const [rowSelection, setRowSelection] = useState({});\n\n const table = useReactTable({\n data,\n columns,\n getCoreRowModel: getCoreRowModel(),\n ...(enablePagination && { getPaginationRowModel: getPaginationRowModel() }),\n onSortingChange: setSorting,\n getSortedRowModel: getSortedRowModel(),\n onColumnFiltersChange: setColumnFilters,\n getFilteredRowModel: getFilteredRowModel(),\n onColumnVisibilityChange: setColumnVisibility,\n onRowSelectionChange: setRowSelection,\n state: {\n sorting,\n columnFilters,\n columnVisibility,\n rowSelection,\n },\n });\n\n return (\n
    \n {showColumnVisibilityControls && }\n \n \n {table.getHeaderGroups().map((headerGroup) => (\n \n {headerGroup.headers.map((header) => {\n return (\n \n {header.isPlaceholder\n ? undefined\n : flexRender(header.column.columnDef.header, header.getContext())}\n \n );\n })}\n \n ))}\n \n \n {table.getRowModel().rows?.length ? (\n table.getRowModel().rows.map((row) => (\n onRowClickHandler(row, table)}\n key={row.id}\n data-state={row.getIsSelected() && 'selected'}\n >\n {row.getVisibleCells().map((cell) => (\n \n {flexRender(cell.column.columnDef.cell, cell.getContext())}\n \n ))}\n \n ))\n ) : (\n \n \n No results.\n \n \n )}\n \n
    \n {enablePagination && (\n
    \n table.previousPage()}\n disabled={!table.getCanPreviousPage()}\n >\n Previous\n \n table.nextPage()}\n disabled={!table.getCanNextPage()}\n >\n Next\n \n
    \n )}\n {enablePagination && showPaginationControls && }\n
    \n );\n}\n\nexport default DataTable;\n","import {\n Table,\n TableBody,\n TableCell,\n TableHead,\n TableHeader,\n TableRow,\n} from '@/components/shadcn-ui/table';\nimport { Canon } from '@sillsdev/scripture';\nimport { deepEqual, LanguageStrings, ScriptureReference } from 'platform-bible-utils';\nimport { useMemo } from 'react';\nimport { InventoryItemOccurrence } from './inventory-utils';\n\n/** Props for the OccurrencesTable component */\ntype OccurrencesTableProps = {\n /** Data that contains scriptures references and snippets of scripture */\n occurrenceData: InventoryItemOccurrence[];\n /** Callback function that is executed when the scripture reference is changed */\n setScriptureReference: (scriptureReference: ScriptureReference) => void;\n /**\n * Object with all localized strings that the OccurrencesTable needs to work well across multiple\n * languages\n */\n localizedStrings: LanguageStrings;\n};\n\n/**\n * Table that shows occurrences of specified inventory item(s). The first column shows the related\n * scripture reference. The second column shows the snippet of scripture that contains the specified\n * inventory item\n */\nfunction OccurrencesTable({\n occurrenceData,\n setScriptureReference,\n localizedStrings,\n}: OccurrencesTableProps) {\n const referenceHeaderText =\n localizedStrings['%webView_inventory_occurrences_table_header_reference%'];\n const occurrenceHeaderText =\n localizedStrings['%webView_inventory_occurrences_table_header_occurrence%'];\n\n const occurrences: InventoryItemOccurrence[] = useMemo(() => {\n const uniqueOccurrences: InventoryItemOccurrence[] = [];\n\n occurrenceData.forEach((occurrence) => {\n if (!uniqueOccurrences.some((uniqueOccurrence) => deepEqual(uniqueOccurrence, occurrence))) {\n uniqueOccurrences.push(occurrence);\n }\n });\n\n return uniqueOccurrences;\n }, [occurrenceData]);\n\n return (\n \n \n \n {referenceHeaderText}\n {occurrenceHeaderText}\n \n \n \n {occurrences.length > 0 &&\n occurrences.map((occurrence) => (\n {\n setScriptureReference(occurrence.reference);\n }}\n >\n {`${Canon.bookNumberToEnglishName(occurrence.reference.bookNum)} ${occurrence.reference.chapterNum}:${occurrence.reference.verseNum}`}\n {occurrence.text}\n \n ))}\n \n
    \n );\n}\n\nexport default OccurrencesTable;\n","import React from 'react';\nimport * as CheckboxPrimitive from '@radix-ui/react-checkbox';\nimport { Check } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Checkbox = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n \n \n));\nCheckbox.displayName = CheckboxPrimitive.Root.displayName;\n\nexport default Checkbox;\n","import { Canon } from '@sillsdev/scripture';\nimport { ScriptureReference } from 'platform-bible-utils';\n\n/* #region Types */\n\n/**\n * Status of items that appear in inventories. 'approved' and 'unapproved' items are defined in the\n * project's `Settings.xml`. All other items are defined as 'unknown'\n */\nexport type Status = 'approved' | 'unapproved' | 'unknown';\n\n/** Occurrence of item in inventory. Primarily used by table that shows occurrences */\nexport type InventoryItemOccurrence = {\n /** Reference to scripture where the item appears */\n reference: ScriptureReference;\n /** Snippet of scripture that contains the occurrence */\n text: string;\n};\n\n/** Data structure that contains all information on an item that is shown in an inventory */\nexport type InventoryTableData = {\n /**\n * The item (e.g. a character in the characters inventory, a marker in the marker inventory) In\n * most cases the array will only have one element. In case of additional items (e.g. the\n * preceding marker in the markers check), the primary item should be stored in the first index.\n * To show additional items in the inventory, make sure to configure the `additionalItemsLabels`\n * prop for the Inventory component\n */\n items: string[];\n /** The number of times this item occurs in the selected scope */\n count: number;\n /** The status of this item (see documentation for `Status` type for more information) */\n status: Status;\n /** Occurrences of this item in the scripture text for the selected scope */\n occurrences: InventoryItemOccurrence[];\n};\n\n/* #endregion */\n\n/* #region Functions */\n\n/**\n * Splits USFM string into shorter line-like segments\n *\n * @param text A single (likely very large) USFM string\n * @returns An array containing the input text, split into shorter segments\n */\nexport const getLinesFromUSFM = (text: string) => {\n // Splits on (CR)LF, CR, \\v, \\c and \\id\n return text.split(/(?:\\r?\\n|\\r)|(?=(?:\\\\(?:v|c|id)))/g);\n};\n\n/**\n * Extracts chapter or verse number from USFM strings that start with a \\c or \\v marker\n *\n * @param text USFM string that is expected to start with \\c or \\v marker\n * @returns Chapter or verse number if one is found. Else returns 0.\n */\nexport const getNumberFromUSFM = (text: string): number | undefined => {\n // Captures all digits that follow \\v or \\c markers followed by whitespace located at the start of a string\n const regex = /^\\\\[vc]\\s+(\\d+)/;\n const match = text.match(regex);\n\n if (match) {\n return +match[1];\n }\n return undefined;\n};\n\n/**\n * Gets book ID from USFM string that starts with the \\id marker, and returns book number for it\n *\n * @param text USFM string that is expected to start with \\id marker\n * @returns Book number corresponding to the \\id marker in the input text. Returns 0 if no marker is\n * found or the marker is not valid\n */\nexport const getBookNumFromId = (text: string): number => {\n // Captures all digits that follow an \\id marker followed by whitespace located at the start of a string\n const match = text.match(/^\\\\id\\s+([A-Za-z]+)/);\n if (match) {\n return Canon.bookIdToNumber(match[1]);\n }\n return 0;\n};\n\n/**\n * Gets the status for an item, typically used in the Inventory component\n *\n * @param item The item for which the status is being requested\n * @param approvedItems Array of approved items, typically as defined in `Settings.xml`\n * @param unapprovedItems Array of unapproved items, typically as defined in `Settings.xml`\n * @returns The status for the specified item\n */\nexport const getStatusForItem = (\n item: string,\n approvedItems: string[],\n unapprovedItems: string[],\n): Status => {\n if (unapprovedItems.includes(item)) return 'unapproved';\n if (approvedItems.includes(item)) return 'approved';\n return 'unknown';\n};\n\n/* #endregion */\n","import React from 'react';\nimport * as TogglePrimitive from '@radix-ui/react-toggle';\nimport { cva, type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst toggleVariants = cva(\n 'pr-twp tw-inline-flex tw-items-center tw-justify-center tw-rounded-md tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-colors hover:tw-bg-muted hover:tw-text-muted-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50 data-[state=on]:tw-bg-accent data-[state=on]:tw-text-accent-foreground',\n {\n variants: {\n variant: {\n default: 'tw-bg-transparent',\n outline:\n 'tw-border tw-border-input tw-bg-transparent hover:tw-bg-accent hover:tw-text-accent-foreground',\n },\n size: {\n default: 'tw-h-10 tw-px-3',\n sm: 'tw-h-9 tw-px-2.5',\n lg: 'tw-h-11 tw-px-5',\n },\n },\n defaultVariants: {\n variant: 'default',\n size: 'default',\n },\n },\n);\n\nconst Toggle = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef & VariantProps\n>(({ className, variant, size, ...props }, ref) => (\n \n));\n\nToggle.displayName = TogglePrimitive.Root.displayName;\n\nexport { Toggle, toggleVariants };\n","import React from 'react';\nimport * as ToggleGroupPrimitive from '@radix-ui/react-toggle-group';\nimport { type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { toggleVariants } from '@/components/shadcn-ui/toggle';\n\nconst ToggleGroupContext = React.createContext>({\n size: 'default',\n variant: 'default',\n});\n\nconst ToggleGroup = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef &\n VariantProps\n>(({ className, variant, size, children, ...props }, ref) => (\n \n \n {children}\n \n \n));\n\nToggleGroup.displayName = ToggleGroupPrimitive.Root.displayName;\n\nconst ToggleGroupItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef &\n VariantProps\n>(({ className, children, variant, size, ...props }, ref) => {\n const context = React.useContext(ToggleGroupContext);\n\n return (\n \n {children}\n \n );\n});\n\nToggleGroupItem.displayName = ToggleGroupPrimitive.Item.displayName;\n\nexport { ToggleGroup, ToggleGroupItem };\n","import { ColumnDef, SortDirection } from '@/components/advanced/data-table/data-table.component';\nimport { Button } from '@/components/shadcn-ui/button';\nimport { ToggleGroup, ToggleGroupItem } from '@/components/shadcn-ui/toggle-group';\nimport {\n ArrowDownIcon,\n ArrowUpDownIcon,\n ArrowUpIcon,\n CircleCheckIcon,\n CircleHelpIcon,\n CircleXIcon,\n} from 'lucide-react';\nimport { ReactNode } from 'react';\nimport { InventoryTableData, Status } from './inventory-utils';\n\n/**\n * Gets an icon that indicates the current sorting direction based on the provided input\n *\n * @param sortDirection Sorting direction. Can be ascending ('asc'), descending ('desc') or false (\n * i.e. not sorted)\n * @returns The appropriate sorting icon for the provided sorting direction\n */\nconst getSortingIcon = (sortDirection: false | SortDirection): ReactNode => {\n if (sortDirection === 'asc') {\n return ;\n }\n if (sortDirection === 'desc') {\n return ;\n }\n return ;\n};\n\n/**\n * Function that creates the item column for inventories\n *\n * @param itemLabel Localized label for the item column (e.g. 'Character', 'Repeated Word', etc.)\n * @returns Column that shows the inventory items. Should be used with the DataTable component\n */\nexport const inventoryItemColumn = (itemLabel: string): ColumnDef => {\n return {\n accessorKey: 'item',\n accessorFn: (row: InventoryTableData) => row.items[0],\n header: ({ column }) => (\n \n ),\n };\n};\n\n/**\n * Function that creates the additional item columns for inventories\n *\n * @param additionalItemLabel Localized label for the additional item column (e.g. 'Preceding\n * Marker')\n * @param additionalItemIndex Index that locates the desired item in the items array of the\n * inventory\n * @returns Column that shows additional inventory items. Should be used with the DataTable\n * component\n */\nexport const inventoryAdditionalItemColumn = (\n additionalItemLabel: string,\n additionalItemIndex: number,\n): ColumnDef => {\n return {\n accessorKey: `item${additionalItemIndex}`,\n accessorFn: (row: InventoryTableData) => row.items[additionalItemIndex],\n header: ({ column }) => (\n \n ),\n };\n};\n\n/**\n * Function that creates the count column for inventories. Should be used with the DataTable\n * component.\n *\n * @param itemLabel Localized label for the count column\n * @returns Column that shows the number of occurrences of the related inventory items\n */\nexport const inventoryCountColumn = (countLabel: string): ColumnDef => {\n return {\n accessorKey: 'count',\n header: ({ column }) => (\n
    \n \n
    \n ),\n cell: ({ row }) =>
    {row.getValue('count')}
    ,\n };\n};\n\n/**\n * Function that updates project settings when status for item(s) changes\n *\n * @param changedItems Array of items for which the status is being updated\n * @param newStatus The status that the items are being given\n * @param approvedItems Array of currently approved items\n * @param onApprovedItemsChange Callback function that stores the updated list of approved items\n * @param unapprovedItems Array of currently unapproved items\n * @param onUnapprovedItemsChange Callback function that stores the updated list of unapproved items\n */\nconst statusChangeHandler = (\n changedItems: string[],\n newStatus: Status,\n approvedItems: string[],\n onApprovedItemsChange: (items: string[]) => void,\n unapprovedItems: string[],\n onUnapprovedItemsChange: (items: string[]) => void,\n) => {\n let newApprovedItems: string[] = [...approvedItems];\n changedItems.forEach((item) => {\n if (newStatus === 'approved') {\n if (!newApprovedItems.includes(item)) {\n newApprovedItems.push(item);\n }\n } else {\n newApprovedItems = newApprovedItems.filter((validItem) => validItem !== item);\n }\n });\n onApprovedItemsChange(newApprovedItems);\n\n let newUnapprovedItems: string[] = [...unapprovedItems];\n changedItems.forEach((item) => {\n if (newStatus === 'unapproved') {\n if (!newUnapprovedItems.includes(item)) {\n newUnapprovedItems.push(item);\n }\n } else {\n newUnapprovedItems = newUnapprovedItems.filter((unapprovedItem) => unapprovedItem !== item);\n }\n });\n onUnapprovedItemsChange(newUnapprovedItems);\n};\n\n/**\n * Function that creates the status column for inventories. Should be used with the DataTable\n * component.\n *\n * @param statusLabel Localized label for the status column\n * @param approvedItems Array of approved items, typically as defined in `Settings.xml`\n * @param onApprovedItemsChange Callback function that stores the updated list of approved items\n * @param unapprovedItems Array of unapproved items, typically as defined in `Settings.xml`\n * @param onUnapprovedItemsChange Callback function that stores the updated list of unapproved items\n * @returns Column that shows the status buttons for the related inventory item. The button for the\n * current status of the item is selected\n */\nexport const inventoryStatusColumn = (\n statusLabel: string,\n approvedItems: string[],\n onApprovedItemsChange: (items: string[]) => void,\n unapprovedItems: string[],\n onUnapprovedItemsChange: (items: string[]) => void,\n): ColumnDef => {\n return {\n accessorKey: 'status',\n header: ({ column }) => {\n return (\n
    \n \n
    \n );\n },\n cell: ({ row }) => {\n const status: Status = row.getValue('status');\n const item: string = row.getValue('item');\n return (\n \n \n statusChangeHandler(\n [item],\n 'approved',\n approvedItems,\n onApprovedItemsChange,\n unapprovedItems,\n onUnapprovedItemsChange,\n )\n }\n value=\"approved\"\n >\n \n \n \n statusChangeHandler(\n [item],\n 'unapproved',\n approvedItems,\n onApprovedItemsChange,\n unapprovedItems,\n onUnapprovedItemsChange,\n )\n }\n value=\"unapproved\"\n >\n \n \n \n statusChangeHandler(\n [item],\n 'unknown',\n approvedItems,\n onApprovedItemsChange,\n unapprovedItems,\n onUnapprovedItemsChange,\n )\n }\n value=\"unknown\"\n >\n \n \n \n );\n },\n };\n};\n","import DataTable, {\n ColumnDef,\n RowContents,\n RowSelectionState,\n TableContents,\n} from '@/components/advanced/data-table/data-table.component';\nimport OccurrencesTable from '@/components/advanced/inventory/occurrences-table.component';\nimport Checkbox from '@/components/shadcn-ui/checkbox';\nimport { Input } from '@/components/shadcn-ui/input';\nimport { Label } from '@/components/shadcn-ui/label';\nimport {\n Select,\n SelectContent,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\nimport {\n deepEqual,\n LocalizedStringValue,\n ScriptureReference,\n substring,\n} from 'platform-bible-utils';\nimport { useEffect, useMemo, useState } from 'react';\nimport {\n getBookNumFromId,\n getLinesFromUSFM,\n getNumberFromUSFM,\n getStatusForItem,\n InventoryItemOccurrence,\n InventoryTableData,\n Status,\n} from './inventory-utils';\nimport { inventoryAdditionalItemColumn } from './inventory-columns';\n\n/**\n * Object containing all keys used for localization in this component. If you're using this\n * component in an extension, you can pass it into the useLocalizedStrings hook to easily obtain the\n * localized strings and pass them into the localizedStrings prop of this component\n */\nexport const INVENTORY_STRING_KEYS = Object.freeze([\n '%webView_inventory_all%',\n '%webView_inventory_approved%',\n '%webView_inventory_unapproved%',\n '%webView_inventory_unknown%',\n '%webView_inventory_scope_currentBook%',\n '%webView_inventory_scope_chapter%',\n '%webView_inventory_scope_verse%',\n '%webView_inventory_filter_text%',\n '%webView_inventory_show_additional_items%',\n '%webView_inventory_occurrences_table_header_reference%',\n '%webView_inventory_occurrences_table_header_occurrence%',\n] as const);\n\nexport type InventoryLocalizedStrings = {\n [localizedInventoryKey in (typeof INVENTORY_STRING_KEYS)[number]]?: LocalizedStringValue;\n};\n\n/** Scope of scripture that the inventory can operate on */\nexport type Scope = 'book' | 'chapter' | 'verse';\n\n/** Status values that the status filter can select from */\ntype StatusFilter = Status | 'all';\n\n/** Text labels for the inventory columns and the control components of additional inventory items */\ntype AdditionalItemsLabels = {\n checkboxText?: string;\n tableHeaders?: string[];\n};\n\n/**\n * Filters data that is shown in the DataTable section of the Inventory\n *\n * @param itemData All inventory items and their related information\n * @param statusFilter Allows filtering by status (i.e. show all items, or only items that are\n * 'approved', 'unapproved' or 'unknown')\n * @param textFilter Allows filtering by text. All items that include the filter text will be\n * selected.\n * @returns Array of items and their related information that are matched by the specified filters\n */\nconst filterItemData = (\n itemData: InventoryTableData[],\n statusFilter: StatusFilter,\n textFilter: string,\n): InventoryTableData[] => {\n let filteredItemData: InventoryTableData[] = itemData;\n\n if (statusFilter !== 'all') {\n filteredItemData = filteredItemData.filter(\n (item) =>\n (statusFilter === 'approved' && item.status === 'approved') ||\n (statusFilter === 'unapproved' && item.status === 'unapproved') ||\n (statusFilter === 'unknown' && item.status === 'unknown'),\n );\n }\n\n if (textFilter !== '')\n filteredItemData = filteredItemData.filter((item) => item.items[0].includes(textFilter));\n\n return filteredItemData;\n};\n\n/**\n * Turns array of strings into array of inventory items, along with their count and status\n *\n * @param text The source scripture text that is searched for inventory items\n * @param scriptureRef The scripture reference that the application is currently set to\n * @param approvedItems Array of approved items, typically as defined in `Settings.xml`\n * @param unapprovedItems Array of unapproved items, typically as defined in `Settings.xml`\n * @param itemRegex Regular expression that describes what items this Inventory should extract from\n * the provided scripture text\n * @returns Array of inventory items, along with their count and status\n */\nconst createTableData = (\n text: string | undefined,\n scriptureRef: ScriptureReference,\n approvedItems: string[],\n unapprovedItems: string[],\n itemRegex: RegExp,\n): InventoryTableData[] => {\n if (!text) return [];\n\n const tableData: InventoryTableData[] = [];\n\n let currentBook: number | undefined = scriptureRef.bookNum;\n let currentChapter: number | undefined = scriptureRef.chapterNum;\n let currentVerse: number | undefined = scriptureRef.verseNum;\n\n const lines = getLinesFromUSFM(text);\n\n lines.forEach((line: string) => {\n if (line.startsWith('\\\\id')) {\n currentBook = getBookNumFromId(line);\n currentChapter = 0;\n currentVerse = 0;\n }\n if (line.startsWith('\\\\c')) {\n currentChapter = getNumberFromUSFM(line);\n currentVerse = 0;\n }\n if (line.startsWith('\\\\v')) {\n currentVerse = getNumberFromUSFM(line);\n if (currentChapter === 0) {\n currentChapter = scriptureRef.chapterNum;\n }\n }\n\n let match: RegExpExecArray | undefined = itemRegex.exec(line) ?? undefined;\n while (match) {\n const items: string[] = [];\n match.forEach((item) => items.push(item));\n const itemIndex = match.index;\n const existingItem = tableData.find((tableEntry) => deepEqual(tableEntry.items, items));\n const newReference: InventoryItemOccurrence = {\n reference: {\n bookNum: currentBook !== undefined ? currentBook : -1,\n chapterNum: currentChapter !== undefined ? currentChapter : -1,\n verseNum: currentVerse !== undefined ? currentVerse : -1,\n },\n text: substring(line, Math.max(0, itemIndex - 25), Math.min(itemIndex + 25, line.length)),\n };\n if (existingItem) {\n existingItem.count += 1;\n existingItem.occurrences.push(newReference);\n } else {\n const newItem: InventoryTableData = {\n items,\n count: 1,\n status: getStatusForItem(items[0], approvedItems, unapprovedItems),\n occurrences: [newReference],\n };\n tableData.push(newItem);\n }\n\n match = itemRegex.exec(line) ?? undefined;\n }\n });\n\n return tableData;\n};\n\n/**\n * Gets the localized value for the provided key\n *\n * @param strings Object containing localized string\n * @param key Key for a localized string\n * @returns The localized value for the provided key, if available. Returns the key if no localized\n * value is available\n */\nconst localizeString = (\n strings: InventoryLocalizedStrings,\n key: keyof InventoryLocalizedStrings,\n) => {\n return strings[key] ?? key;\n};\n\n/** Props for the Inventory component */\ntype InventoryProps = {\n /** The scripture reference that the application is currently set to */\n scriptureReference: ScriptureReference;\n /** Callback function that is executed when the scripture reference is changed */\n setScriptureReference: (scriptureReference: ScriptureReference) => void;\n /**\n * Object with all localized strings that the Inventory needs to work well across multiple\n * languages. When using this component with Platform.Bible, you can import\n * `INVENTORY_STRING_KEYS` from this library, pass it in to the Platform's localization hook, and\n * pass the localized keys that are returned by the hook into this prop.\n */\n localizedStrings: InventoryLocalizedStrings;\n /**\n * The logic that finds the desired items in the source text. This can either be a Regular\n * expression that captures one or multiple items (preferred), or a custom function that builds\n * and return an InventoryDataTable[] manually. Note: In case the logic captures more than one\n * item (i.e. InventoryTableData.items has a length greater than 1), you must provide text labels\n * for the related columns and control elements to show by setting the `additionalItemsLabels`\n * prop\n */\n extractItems:\n | RegExp\n | ((\n text: string | undefined,\n scriptureRef: ScriptureReference,\n approvedItems: string[],\n unapprovedItems: string[],\n ) => InventoryTableData[]);\n /**\n * Text labels for control elements and additional column headers in case your Inventory has more\n * than one item to show (e.g. The 'Preceding Marker' in the Markers Inventory)\n */\n additionalItemsLabels?: AdditionalItemsLabels;\n /** Array of approved items, typically as defined in `Settings.xml` */\n approvedItems: string[];\n /** Array of unapproved items, typically as defined in `Settings.xml` */\n unapprovedItems: string[];\n /** The source scripture text that is searched for in inventory items */\n text: string | undefined;\n /** Scope of scripture that the inventory will operate on */\n scope: Scope;\n /** Callback function that is executed when the scope is changed from the Inventory */\n onScopeChange: (scope: Scope) => void;\n /**\n * Column definitions for the Inventory data table. The most commonly used column definitions are\n * pre-configured for your convenience and can be imported (e.g. inventoryItemColumn,\n * inventoryAdditionalItemColumn inventoryCountColumn, and inventoryStatusColumn). If you need any\n * other columns you can add these yourself\n */\n columns: ColumnDef[];\n};\n\n/** Inventory component that is used to view and control the status of provided project settings */\nexport default function Inventory({\n scriptureReference,\n setScriptureReference,\n localizedStrings,\n extractItems,\n additionalItemsLabels,\n approvedItems,\n unapprovedItems,\n text,\n scope,\n onScopeChange,\n columns,\n}: InventoryProps) {\n const allItemsText = localizeString(localizedStrings, '%webView_inventory_all%');\n const approvedItemsText = localizeString(localizedStrings, '%webView_inventory_approved%');\n const unapprovedItemsText = localizeString(localizedStrings, '%webView_inventory_unapproved%');\n const unknownItemsText = localizeString(localizedStrings, '%webView_inventory_unknown%');\n const scopeBookText = localizeString(localizedStrings, '%webView_inventory_scope_currentBook%');\n const scopeChapterText = localizeString(localizedStrings, '%webView_inventory_scope_chapter%');\n const scopeVerseText = localizeString(localizedStrings, '%webView_inventory_scope_verse%');\n const filterText = localizeString(localizedStrings, '%webView_inventory_filter_text%');\n const showAdditionalItemsText = localizeString(\n localizedStrings,\n '%webView_inventory_show_additional_items%',\n );\n\n const [showAdditionalItems, setShowAdditionalItems] = useState(false);\n const [statusFilter, setStatusFilter] = useState('all');\n const [textFilter, setTextFilter] = useState('');\n const [selectedItem, setSelectedItem] = useState([]);\n\n const tableData: InventoryTableData[] = useMemo(() => {\n if (!text) return [];\n if (extractItems instanceof RegExp)\n return createTableData(\n text,\n scriptureReference,\n approvedItems,\n unapprovedItems,\n extractItems,\n );\n return extractItems(text, scriptureReference, approvedItems, unapprovedItems);\n }, [text, extractItems, scriptureReference, approvedItems, unapprovedItems]);\n\n const reducedTableData: InventoryTableData[] = useMemo(() => {\n if (showAdditionalItems) return tableData;\n\n const newTableData: InventoryTableData[] = [];\n\n tableData.forEach((tableEntry) => {\n const firstItem = tableEntry.items[0];\n\n const existingEntry = newTableData.find(\n (newTableEntry) => newTableEntry.items[0] === firstItem,\n );\n\n if (existingEntry) {\n existingEntry.count += tableEntry.count;\n existingEntry.occurrences = existingEntry.occurrences.concat(tableEntry.occurrences);\n } else {\n newTableData.push({\n items: [firstItem],\n count: tableEntry.count,\n occurrences: tableEntry.occurrences,\n status: tableEntry.status,\n });\n }\n });\n\n return newTableData;\n }, [showAdditionalItems, tableData]);\n\n const filteredTableData: InventoryTableData[] = useMemo(() => {\n return filterItemData(reducedTableData, statusFilter, textFilter);\n }, [reducedTableData, statusFilter, textFilter]);\n\n const allColumns: ColumnDef[] = useMemo(() => {\n if (!showAdditionalItems) return columns;\n\n const numberOfAdditionalItems = additionalItemsLabels?.tableHeaders?.length;\n if (!numberOfAdditionalItems) return columns;\n\n const additionalColumns: ColumnDef[] = [];\n\n for (let index = 0; index < numberOfAdditionalItems; index++) {\n additionalColumns.push(\n inventoryAdditionalItemColumn(\n additionalItemsLabels?.tableHeaders?.[index] || 'Additional Item',\n index + 1,\n ),\n );\n }\n\n return [...additionalColumns, ...columns];\n }, [additionalItemsLabels?.tableHeaders, columns, showAdditionalItems]);\n\n useEffect(() => {\n setSelectedItem([]);\n }, [filteredTableData]);\n\n const rowClickHandler = (\n row: RowContents,\n table: TableContents,\n ) => {\n table.setRowSelection(() => {\n const newSelection: RowSelectionState = {};\n newSelection[row.index] = true;\n return newSelection;\n });\n\n setSelectedItem(row.original.items);\n };\n\n const handleScopeChange = (value: string) => {\n if (value === 'book' || value === 'chapter' || value === 'verse') {\n onScopeChange(value);\n } else {\n throw new Error(`Invalid scope value: ${value}`);\n }\n };\n\n const handleStatusFilterChange = (value: string) => {\n if (value === 'all' || value === 'approved' || value === 'unapproved' || value === 'unknown') {\n setStatusFilter(value);\n } else {\n throw new Error(`Invalid status filter value: ${value}`);\n }\n };\n\n const occurrenceData: InventoryItemOccurrence[] = useMemo(() => {\n if (reducedTableData.length === 0 || selectedItem.length === 0) return [];\n const occurrence = reducedTableData.filter((tableEntry: InventoryTableData) => {\n return deepEqual(\n showAdditionalItems ? tableEntry.items : [tableEntry.items[0]],\n selectedItem,\n );\n });\n if (occurrence.length > 1) throw new Error('Selected item is not unique');\n return occurrence[0].occurrences;\n }, [selectedItem, showAdditionalItems, reducedTableData]);\n\n return (\n
    \n
    \n handleStatusFilterChange(value)}\n defaultValue={statusFilter}\n >\n \n \n \n \n {allItemsText}\n {approvedItemsText}\n {unapprovedItemsText}\n {unknownItemsText}\n \n \n \n {\n setTextFilter(event.target.value);\n }}\n />\n {additionalItemsLabels && (\n
    \n {\n setSelectedItem([]);\n setShowAdditionalItems(checked);\n }}\n />\n \n
    \n )}\n
    \n
    \n \n
    \n {occurrenceData.length > 0 && (\n
    \n \n
    \n )}\n
    \n );\n}\n","import { Input } from '@/components/shadcn-ui/input';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { useState } from 'react';\n\nexport type SearchBarProps = {\n className?: string;\n /**\n * Callback fired to handle the search query when button pressed\n *\n * @param searchQuery\n */\n onSearch: (searchQuery: string) => void;\n\n /** Optional string that appears in the search bar without a search string */\n placeholder?: string;\n\n /** Optional boolean to set the input base to full width */\n isFullWidth?: boolean;\n};\n\nexport default function SearchBar({\n className,\n onSearch,\n placeholder,\n isFullWidth,\n}: SearchBarProps) {\n const [searchQuery, setSearchQuery] = useState('');\n\n const handleInputChange = (searchString: string) => {\n setSearchQuery(searchString);\n onSearch(searchString);\n };\n\n return (\n handleInputChange(e.target.value)}\n />\n );\n}\n","// adapted from: https://github.com/shadcn-ui/ui/discussions/752\n\n'use client';\n\nimport { TabsContentProps, TabsListProps, TabsTriggerProps } from '@/components/shadcn-ui/tabs';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport * as TabsPrimitive from '@radix-ui/react-tabs';\nimport React from 'react';\n\nexport type VerticalTabsProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport type LeftTabsTriggerProps = TabsTriggerProps & {\n value: string;\n ref?: React.Ref;\n};\n\nexport const VerticalTabs = React.forwardRef<\n React.ElementRef,\n VerticalTabsProps\n>(({ className, ...props }, ref) => (\n \n));\n\nVerticalTabs.displayName = TabsPrimitive.List.displayName;\n\nexport const VerticalTabsList = React.forwardRef<\n React.ElementRef,\n TabsListProps\n>(({ className, ...props }, ref) => (\n \n));\nVerticalTabsList.displayName = TabsPrimitive.List.displayName;\n\nexport const VerticalTabsTrigger = React.forwardRef<\n React.ElementRef,\n LeftTabsTriggerProps\n>(({ className, ...props }, ref) => (\n \n));\n\nexport const VerticalTabsContent = React.forwardRef<\n React.ElementRef,\n TabsContentProps\n>(({ className, ...props }, ref) => (\n \n));\nVerticalTabsContent.displayName = TabsPrimitive.Content.displayName;\n","import SearchBar from '@/components/basics/search-bar.component';\nimport {\n VerticalTabs,\n VerticalTabsContent,\n VerticalTabsList,\n VerticalTabsTrigger,\n} from '@/components/basics/tabs-vertical';\nimport { ReactNode } from 'react';\n\nexport type TabKeyValueContent = {\n key: string;\n value: string;\n content: ReactNode;\n};\n\nexport type TabNavigationContentSearchProps = {\n /** List of values and keys for each tab this component should provide */\n tabList: TabKeyValueContent[];\n\n /** Handler to run when the value of the search bar changes */\n onSearch: (searchQuery: string) => void;\n\n /** Optional placeholder for the search bar */\n searchPlaceholder?: string;\n\n /** Optional title to include in the header */\n headerTitle?: string;\n\n /** Optional flag to make the search bar appear full width */\n isSearchBarFullWidth?: boolean;\n\n /** Text direction ltr or rtl */\n direction?: 'ltr' | 'rtl';\n};\n\nexport default function TabNavigationContentSearch({\n tabList,\n onSearch,\n searchPlaceholder,\n headerTitle,\n isSearchBarFullWidth = false,\n direction = 'ltr',\n}: TabNavigationContentSearchProps) {\n return (\n
    \n
    \n {headerTitle ?

    {headerTitle}

    : ''}\n \n
    \n \n \n {tabList.map((tab) => (\n \n {tab.value}\n \n ))}\n \n {tabList.map((tab) => (\n \n {tab.content}\n \n ))}\n \n
    \n );\n}\n","import React from 'react';\nimport * as SeparatorPrimitive from '@radix-ui/react-separator';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Separator = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, orientation = 'horizontal', decorative = true, ...props }, ref) => (\n \n));\nSeparator.displayName = SeparatorPrimitive.Root.displayName;\n\nexport { Separator };\n","'use client';\n\nimport * as React from 'react';\nimport * as SheetPrimitive from '@radix-ui/react-dialog';\nimport { cva, type VariantProps } from 'class-variance-authority';\nimport { X } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Sheet = SheetPrimitive.Root;\n\nconst SheetTrigger = SheetPrimitive.Trigger;\n\nconst SheetClose = SheetPrimitive.Close;\n\nconst SheetPortal = SheetPrimitive.Portal;\n\nconst SheetOverlay = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSheetOverlay.displayName = SheetPrimitive.Overlay.displayName;\n\nconst sheetVariants = cva(\n 'pr-twp tw-fixed tw-z-50 tw-gap-4 tw-bg-background tw-p-6 tw-shadow-lg tw-transition tw-ease-in-out data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-duration-300 data-[state=open]:tw-duration-500',\n {\n variants: {\n side: {\n top: 'tw-inset-x-0 tw-top-0 tw-border-b data-[state=closed]:tw-slide-out-to-top data-[state=open]:tw-slide-in-from-top',\n bottom:\n 'tw-inset-x-0 tw-bottom-0 tw-border-t data-[state=closed]:tw-slide-out-to-bottom data-[state=open]:tw-slide-in-from-bottom',\n left: 'tw-inset-y-0 tw-left-0 tw-h-full tw-w-3/4 tw-border-r data-[state=closed]:tw-slide-out-to-left data-[state=open]:tw-slide-in-from-left sm:tw-max-w-sm',\n right:\n 'tw-inset-y-0 tw-right-0 tw-h-full tw-w-3/4 tw- tw-border-l data-[state=closed]:tw-slide-out-to-right data-[state=open]:tw-slide-in-from-right sm:tw-max-w-sm',\n },\n },\n defaultVariants: {\n side: 'right',\n },\n },\n);\n\ninterface SheetContentProps\n extends React.ComponentPropsWithoutRef,\n VariantProps {}\n\nconst SheetContent = React.forwardRef<\n React.ElementRef,\n SheetContentProps\n>(({ side = 'right', className, children, ...props }, ref) => (\n \n \n \n {children}\n \n \n Close\n \n \n \n));\nSheetContent.displayName = SheetPrimitive.Content.displayName;\n\nfunction SheetHeader({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nSheetHeader.displayName = 'SheetHeader';\n\nfunction SheetFooter({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nSheetFooter.displayName = 'SheetFooter';\n\nconst SheetTitle = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSheetTitle.displayName = SheetPrimitive.Title.displayName;\n\nconst SheetDescription = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSheetDescription.displayName = SheetPrimitive.Description.displayName;\n\nexport {\n Sheet,\n SheetPortal,\n SheetOverlay,\n SheetTrigger,\n SheetClose,\n SheetContent,\n SheetHeader,\n SheetFooter,\n SheetTitle,\n SheetDescription,\n};\n","import React from 'react';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nfunction Skeleton({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\n\nexport { Skeleton };\n","import React from 'react';\nimport * as TooltipPrimitive from '@radix-ui/react-tooltip';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst TooltipProvider = TooltipPrimitive.Provider;\n\nconst Tooltip = TooltipPrimitive.Root;\n\nconst TooltipTrigger = TooltipPrimitive.Trigger;\n\nconst TooltipContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, sideOffset = 4, ...props }, ref) => (\n \n));\nTooltipContent.displayName = TooltipPrimitive.Content.displayName;\n\nexport { Tooltip, TooltipTrigger, TooltipContent, TooltipProvider };\n","import * as React from 'react';\n\nconst MOBILE_BREAKPOINT = 768;\n\nexport default function useIsMobile() {\n const [isMobile, setIsMobile] = React.useState(undefined);\n\n React.useEffect(() => {\n const mql = window.matchMedia(`(max-width: ${MOBILE_BREAKPOINT - 1}px)`);\n const onChange = () => {\n setIsMobile(window.innerWidth < MOBILE_BREAKPOINT);\n };\n mql.addEventListener('change', onChange);\n setIsMobile(window.innerWidth < MOBILE_BREAKPOINT);\n return () => mql.removeEventListener('change', onChange);\n }, []);\n\n return !!isMobile;\n}\n","import React from 'react';\nimport { Slot } from '@radix-ui/react-slot';\nimport { VariantProps, cva } from 'class-variance-authority';\nimport { PanelLeft } from 'lucide-react';\n\nimport { Button } from '@/components/shadcn-ui/button';\nimport { Input } from '@/components/shadcn-ui/input';\nimport { Separator } from '@/components/shadcn-ui/separator';\nimport { Sheet, SheetContent } from '@/components/shadcn-ui/sheet';\nimport { Skeleton } from '@/components/shadcn-ui/skeleton';\nimport {\n Tooltip,\n TooltipContent,\n TooltipProvider,\n TooltipTrigger,\n} from '@/components/shadcn-ui/tooltip';\nimport useIsMobile from '@/components/hooks/use-mobile';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst SIDEBAR_COOKIE_NAME = 'sidebar:state';\nconst SIDEBAR_COOKIE_MAX_AGE = 60 * 60 * 24 * 7;\nconst SIDEBAR_WIDTH = '16rem';\nconst SIDEBAR_WIDTH_MOBILE = '18rem';\nconst SIDEBAR_WIDTH_ICON = '3rem';\nconst SIDEBAR_KEYBOARD_SHORTCUT = 'b';\n\ntype SidebarContextProps = {\n state: 'expanded' | 'collapsed';\n open: boolean;\n setOpen: (open: boolean) => void;\n openMobile: boolean;\n setOpenMobile: (open: boolean) => void;\n isMobile: boolean;\n toggleSidebar: () => void;\n};\n\nconst SidebarContext = React.createContext(undefined);\n\nfunction useSidebar() {\n const context = React.useContext(SidebarContext);\n if (!context) {\n throw new Error('useSidebar must be used within a SidebarProvider.');\n }\n\n return context;\n}\n\nconst SidebarProvider = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & {\n defaultOpen?: boolean;\n open?: boolean;\n onOpenChange?: (open: boolean) => void;\n }\n>(\n (\n {\n defaultOpen = true,\n open: openProp,\n onOpenChange: setOpenProp,\n className,\n style,\n children,\n ...props\n },\n ref,\n ) => {\n const isMobile = useIsMobile();\n const [openMobile, setOpenMobile] = React.useState(false);\n\n // This is the internal state of the sidebar.\n // We use openProp and setOpenProp for control from outside the component.\n const [_open, _setOpen] = React.useState(defaultOpen);\n const isOpen = openProp ?? _open;\n const setOpen = React.useCallback(\n (value: boolean | ((value: boolean) => boolean)) => {\n const openState = typeof value === 'function' ? value(isOpen) : value;\n if (setOpenProp) {\n setOpenProp(openState);\n } else {\n _setOpen(openState);\n }\n\n // This sets the cookie to keep the sidebar state.\n document.cookie = `${SIDEBAR_COOKIE_NAME}=${openState}; path=/; max-age=${SIDEBAR_COOKIE_MAX_AGE}`;\n },\n [setOpenProp, isOpen],\n );\n\n // Helper to toggle the sidebar.\n const toggleSidebar = React.useCallback(() => {\n return isMobile ? setOpenMobile((open) => !open) : setOpen((open) => !open);\n }, [isMobile, setOpen, setOpenMobile]);\n\n // Adds a keyboard shortcut to toggle the sidebar.\n React.useEffect(() => {\n const handleKeyDown = (event: KeyboardEvent) => {\n if (event.key === SIDEBAR_KEYBOARD_SHORTCUT && (event.metaKey || event.ctrlKey)) {\n event.preventDefault();\n toggleSidebar();\n }\n };\n\n window.addEventListener('keydown', handleKeyDown);\n return () => window.removeEventListener('keydown', handleKeyDown);\n }, [toggleSidebar]);\n\n // We add a state so that we can do data-state=\"expanded\" or \"collapsed\".\n // This makes it easier to style the sidebar with Tailwind classes.\n const state = isOpen ? 'expanded' : 'collapsed';\n\n const contextValue = React.useMemo(\n () => ({\n state,\n open: isOpen,\n setOpen,\n isMobile,\n openMobile,\n setOpenMobile,\n toggleSidebar,\n }),\n [state, isOpen, setOpen, isMobile, openMobile, setOpenMobile, toggleSidebar],\n );\n\n return (\n \n \n \n {children}\n
    \n \n \n );\n },\n);\nSidebarProvider.displayName = 'SidebarProvider';\n\nconst Sidebar = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & {\n side?: 'left' | 'right';\n variant?: 'sidebar' | 'floating' | 'inset';\n collapsible?: 'offcanvas' | 'icon' | 'none';\n }\n>(\n (\n {\n side = 'left',\n variant = 'sidebar',\n collapsible = 'offcanvas',\n className,\n children,\n ...props\n },\n ref,\n ) => {\n const { isMobile, state, openMobile, setOpenMobile } = useSidebar();\n\n if (collapsible === 'none') {\n return (\n \n {children}\n
    \n );\n }\n\n if (isMobile) {\n return (\n \n button]:tw-hidden\"\n style={\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n {\n '--sidebar-width': SIDEBAR_WIDTH_MOBILE,\n } as React.CSSProperties\n }\n side={side}\n >\n
    {children}
    \n \n
    \n );\n }\n\n return (\n \n {/* This is what handles the sidebar gap on desktop */}\n \n \n \n {children}\n
    \n
    \n
    \n );\n },\n);\nSidebar.displayName = 'Sidebar';\n\nconst SidebarTrigger = React.forwardRef<\n React.ElementRef,\n React.ComponentProps\n>(({ className, onClick, ...props }, ref) => {\n const { toggleSidebar } = useSidebar();\n\n return (\n {\n onClick?.(event);\n toggleSidebar();\n }}\n {...props}\n >\n \n Toggle Sidebar\n \n );\n});\nSidebarTrigger.displayName = 'SidebarTrigger';\n\nconst SidebarRail = React.forwardRef>(\n ({ className, ...props }, ref) => {\n const { toggleSidebar } = useSidebar();\n\n return (\n \n );\n },\n);\nSidebarRail.displayName = 'SidebarRail';\n\nconst SidebarInset = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarInset.displayName = 'SidebarInset';\n\nconst SidebarInput = React.forwardRef<\n React.ElementRef,\n React.ComponentProps\n>(({ className, ...props }, ref) => {\n return (\n \n );\n});\nSidebarInput.displayName = 'SidebarInput';\n\nconst SidebarHeader = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarHeader.displayName = 'SidebarHeader';\n\nconst SidebarFooter = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarFooter.displayName = 'SidebarFooter';\n\nconst SidebarSeparator = React.forwardRef<\n React.ElementRef,\n React.ComponentProps\n>(({ className, ...props }, ref) => {\n return (\n \n );\n});\nSidebarSeparator.displayName = 'SidebarSeparator';\n\nconst SidebarContent = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarContent.displayName = 'SidebarContent';\n\nconst SidebarGroup = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarGroup.displayName = 'SidebarGroup';\n\nconst SidebarGroupLabel = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & { asChild?: boolean }\n>(({ className, asChild = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'div';\n\n return (\n svg]:tw-size-4 [&>svg]:tw-shrink-0',\n 'group-data-[collapsible=icon]:tw--mt-8 group-data-[collapsible=icon]:tw-opacity-0',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarGroupLabel.displayName = 'SidebarGroupLabel';\n\nconst SidebarGroupAction = React.forwardRef<\n HTMLButtonElement,\n React.ComponentProps<'button'> & { asChild?: boolean }\n>(({ className, asChild = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'button';\n\n return (\n svg]:tw-size-4 [&>svg]:tw-shrink-0',\n // Increases the hit area of the button on mobile.\n 'after:tw-absolute after:tw--inset-2 after:md:tw-hidden',\n 'group-data-[collapsible=icon]:tw-hidden',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarGroupAction.displayName = 'SidebarGroupAction';\n\nconst SidebarGroupContent = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarGroupContent.displayName = 'SidebarGroupContent';\n\nconst SidebarMenu = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenu.displayName = 'SidebarMenu';\n\nconst SidebarMenuItem = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenuItem.displayName = 'SidebarMenuItem';\n\nconst sidebarMenuButtonVariants = cva(\n // Removed data-[active=true]:tw-bg-sidebar-accent\n 'tw-peer/menu-button tw-flex tw-w-full tw-items-center tw-gap-2 tw-overflow-hidden tw-rounded-md tw-p-2 tw-text-left tw-text-sm tw-outline-none tw-ring-sidebar-ring tw-transition-[width,height,padding] hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground focus-visible:tw-ring-2 active:tw-bg-sidebar-accent active:tw-text-sidebar-accent-foreground disabled:tw-pointer-events-none disabled:tw-opacity-50 tw-group-has-[[data-sidebar=menu-action]]/menu-item:pr-8 aria-disabled:tw-pointer-events-none aria-disabled:tw-opacity-50 data-[active=true]:tw-font-medium data-[active=true]:tw-text-sidebar-accent-foreground data-[state=open]:hover:tw-bg-sidebar-accent data-[state=open]:hover:tw-text-sidebar-accent-foreground group-data-[collapsible=icon]:tw-!size-8 group-data-[collapsible=icon]:tw-!p-2 [&>span:last-child]:tw-truncate [&>svg]:tw-size-4 [&>svg]:tw-shrink-0',\n {\n variants: {\n variant: {\n default: 'hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground',\n outline:\n 'tw-bg-background tw-shadow-[0_0_0_1px_hsl(var(--sidebar-border))] hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground hover:tw-shadow-[0_0_0_1px_hsl(var(--sidebar-accent))]',\n },\n size: {\n default: 'tw-h-8 tw-text-sm',\n sm: 'tw-h-7 tw-text-xs',\n lg: 'tw-h-12 tw-text-sm group-data-[collapsible=icon]:tw-!p-0',\n },\n },\n defaultVariants: {\n variant: 'default',\n size: 'default',\n },\n },\n);\n\nconst SidebarMenuButton = React.forwardRef<\n HTMLButtonElement,\n React.ComponentProps<'button'> & {\n asChild?: boolean;\n isActive?: boolean;\n tooltip?: string | React.ComponentProps;\n } & VariantProps\n>(\n (\n {\n asChild = false,\n isActive = false,\n variant = 'default',\n size = 'default',\n tooltip,\n className,\n ...props\n },\n ref,\n ) => {\n const Comp = asChild ? Slot : 'button';\n const { isMobile, state } = useSidebar();\n\n const button = (\n \n );\n\n if (!tooltip) {\n return button;\n }\n\n if (typeof tooltip === 'string') {\n // eslint-disable-next-line no-param-reassign\n tooltip = {\n children: tooltip,\n };\n }\n\n return (\n \n {button}\n \n );\n },\n);\nSidebarMenuButton.displayName = 'SidebarMenuButton';\n\nconst SidebarMenuAction = React.forwardRef<\n HTMLButtonElement,\n React.ComponentProps<'button'> & {\n asChild?: boolean;\n showOnHover?: boolean;\n }\n>(({ className, asChild = false, showOnHover = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'button';\n\n return (\n svg]:tw-size-4 [&>svg]:tw-shrink-0',\n // Increases the hit area of the button on mobile.\n 'after:tw-absolute after:tw--inset-2 after:md:tw-hidden',\n 'tw-peer-data-[size=sm]/menu-button:top-1',\n 'tw-peer-data-[size=default]/menu-button:top-1.5',\n 'tw-peer-data-[size=lg]/menu-button:top-2.5',\n 'group-data-[collapsible=icon]:tw-hidden',\n showOnHover &&\n 'tw-group-focus-within/menu-item:opacity-100 tw-group-hover/menu-item:opacity-100 tw-peer-data-[active=true]/menu-button:text-sidebar-accent-foreground data-[state=open]:tw-opacity-100 md:tw-opacity-0',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarMenuAction.displayName = 'SidebarMenuAction';\n\nconst SidebarMenuBadge = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenuBadge.displayName = 'SidebarMenuBadge';\n\nconst SidebarMenuSkeleton = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & {\n showIcon?: boolean;\n }\n>(({ className, showIcon = false, ...props }, ref) => {\n // Random width between 50 to 90%.\n const width = React.useMemo(() => {\n return `${Math.floor(Math.random() * 40) + 50}%`;\n }, []);\n\n return (\n \n {showIcon && (\n \n )}\n \n
    \n );\n});\nSidebarMenuSkeleton.displayName = 'SidebarMenuSkeleton';\n\nconst SidebarMenuSub = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenuSub.displayName = 'SidebarMenuSub';\n\nconst SidebarMenuSubItem = React.forwardRef>(\n ({ ...props }, ref) =>
  • ,\n);\nSidebarMenuSubItem.displayName = 'SidebarMenuSubItem';\n\nconst SidebarMenuSubButton = React.forwardRef<\n HTMLAnchorElement,\n React.ComponentProps<'a'> & {\n asChild?: boolean;\n size?: 'sm' | 'md';\n isActive?: boolean;\n }\n>(({ asChild = false, size = 'md', isActive, className, ...props }, ref) => {\n const Comp = asChild ? Slot : 'a';\n\n return (\n span:last-child]:tw-truncate [&>svg]:tw-size-4 [&>svg]:tw-shrink-0 [&>svg]:tw-text-sidebar-accent-foreground',\n 'data-[active=true]:tw-bg-sidebar-accent data-[active=true]:tw-text-sidebar-accent-foreground',\n size === 'sm' && 'tw-text-xs',\n size === 'md' && 'tw-text-sm',\n 'group-data-[collapsible=icon]:tw-hidden',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarMenuSubButton.displayName = 'SidebarMenuSubButton';\n\nexport {\n Sidebar,\n SidebarContent,\n SidebarFooter,\n SidebarGroup,\n SidebarGroupAction,\n SidebarGroupContent,\n SidebarGroupLabel,\n SidebarHeader,\n SidebarInput,\n SidebarInset,\n SidebarMenu,\n SidebarMenuAction,\n SidebarMenuBadge,\n SidebarMenuButton,\n SidebarMenuItem,\n SidebarMenuSkeleton,\n SidebarMenuSub,\n SidebarMenuSubButton,\n SidebarMenuSubItem,\n SidebarProvider,\n SidebarRail,\n SidebarSeparator,\n SidebarTrigger,\n useSidebar,\n};\n","import ComboBox, { ComboBoxOption } from '@/components/basics/combo-box.component';\nimport {\n Sidebar,\n SidebarContent,\n SidebarGroup,\n SidebarGroupLabel,\n SidebarGroupContent,\n SidebarMenu,\n SidebarMenuItem,\n SidebarMenuButton,\n} from '@/components/shadcn-ui/sidebar';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { useCallback } from 'react';\n\nexport type SelectedSettingsSidebarItem = {\n label: string;\n projectId?: string;\n};\n\nexport type ProjectOptions = { projectId: string; projectName: string };\n\nexport type SettingsSidebarProps = {\n /** Optional id for testing */\n id?: string;\n\n /** Extension labels from contribution */\n extensionLabels: string[];\n\n /** Project names and ids */\n projectOptions: ProjectOptions[];\n\n /** Handler for selecting a sidebar item */\n handleSelectSidebarItem: (key: string, projectId?: string) => void;\n\n /** The current selected value in the sidebar */\n selectedSidebarItem: SelectedSettingsSidebarItem;\n\n /** Label for the group of extensions setting groups */\n extensionsSidebarGroupLabel: string;\n\n /** Label for the group of projects settings */\n projectsSidebarGroupLabel: string;\n};\n\nexport default function SettingsSidebar({\n id,\n extensionLabels,\n projectOptions,\n handleSelectSidebarItem,\n selectedSidebarItem,\n extensionsSidebarGroupLabel,\n projectsSidebarGroupLabel,\n}: SettingsSidebarProps) {\n const handleSelectItem = useCallback(\n (item: string, projectId?: string) => {\n handleSelectSidebarItem(item, projectId);\n },\n [handleSelectSidebarItem],\n );\n\n const getProjectNameFromProjectId = useCallback(\n (projectId: string) => {\n const project = projectOptions.find((option) => option.projectId === projectId);\n return project ? project.projectName : projectId;\n },\n [projectOptions],\n );\n\n const getIsActive: (label: string) => boolean = useCallback(\n (label: string) => !selectedSidebarItem.projectId && label === selectedSidebarItem.label,\n [selectedSidebarItem],\n );\n\n return (\n \n \n \n \n {extensionsSidebarGroupLabel}\n \n \n \n {extensionLabels.map((label) => (\n \n handleSelectItem(label, undefined)}\n isActive={getIsActive(label)}\n >\n {label}\n \n \n ))}\n \n \n \n \n \n {projectsSidebarGroupLabel}\n \n \n option.projectId)}\n getOptionLabel={(projectId: ComboBoxOption) => {\n // This function expects a ComboBoxOption, but we know it is a string\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n return getProjectNameFromProjectId(projectId as string);\n }}\n buttonPlaceholder=\"Type or select project\"\n onChange={(projectId: string) => {\n const selectedProjectName = getProjectNameFromProjectId(projectId);\n handleSelectItem(selectedProjectName, projectId);\n }}\n value={selectedSidebarItem?.projectId ?? undefined}\n />\n \n \n \n \n );\n}\n","import { SidebarInset, SidebarProvider } from '@/components/shadcn-ui/sidebar';\nimport { PropsWithChildren } from 'react';\nimport SearchBar from '@/components/basics/search-bar.component';\nimport SettingsSidebar, { SettingsSidebarProps } from './settings-sidebar.component';\n\nexport type SettingsSidebarContentSearchProps = SettingsSidebarProps &\n PropsWithChildren & {\n /** Optional id for testing */\n id?: string;\n\n /** Text direction ltr or rtl */\n direction?: 'ltr' | 'rtl';\n\n /** Handler to run when the value of the search bar changes */\n onSearch: (searchQuery: string) => void;\n };\n\nexport default function SettingsSidebarContentSearch({\n id,\n direction = 'ltr',\n extensionLabels,\n projectOptions,\n children,\n handleSelectSidebarItem,\n selectedSidebarItem,\n onSearch,\n extensionsSidebarGroupLabel,\n projectsSidebarGroupLabel,\n}: SettingsSidebarContentSearchProps) {\n return (\n
    \n
    \n \n
    \n \n \n {children}\n \n
    \n );\n}\n","import { Button } from '@/components/shadcn-ui/button';\nimport {\n Select,\n SelectContent,\n SelectGroup,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\nimport {\n Table,\n TableBody,\n TableCell,\n TableHead,\n TableHeader,\n TableRow,\n} from '@/components/shadcn-ui/table';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Canon } from '@sillsdev/scripture';\nimport {\n Cell,\n ColumnDef,\n flexRender,\n getCoreRowModel,\n getExpandedRowModel,\n getGroupedRowModel,\n getSortedRowModel,\n GroupingState,\n Row,\n RowSelectionState,\n SortingState,\n useReactTable,\n} from '@tanstack/react-table';\nimport '@/components/advanced/scripture-results-viewer/scripture-results-viewer.component.css';\nimport {\n compareScrRefs,\n formatScrRef,\n ScriptureSelection,\n scrRefToBBBCCCVVV,\n} from 'platform-bible-utils';\nimport { MouseEvent, useEffect, useMemo, useState } from 'react';\nimport { ChevronDown, ChevronLeft, ChevronRight } from 'lucide-react';\n\n/**\n * Information (e.g., a checking error or some other type of \"transient\" annotation) about something\n * noteworthy at a specific place in an instance of the Scriptures.\n */\nexport type ScriptureItemDetail = ScriptureSelection & {\n /**\n * Text of the error, note, etc. In the future, we might want to support something more than just\n * text so that a JSX element could be provided with a link or some other controls related to the\n * issue being reported.\n */\n detail: string;\n};\n\n/**\n * A uniquely identifiable source of results that can be displayed in the ScriptureResultsViewer.\n * Generally, the source will be a particular Scripture check, but there may be other types of\n * sources.\n */\nexport type ResultsSource = {\n /**\n * Uniquely identifies the source.\n *\n * @type {string}\n */\n id: string;\n\n /**\n * Name (potentially localized) of the source, suitable for display in the UI.\n *\n * @type {string}\n */\n displayName: string;\n};\n\nexport type ScriptureSrcItemDetail = ScriptureItemDetail & {\n /** Source/type of detail. Can be used for grouping. */\n source: ResultsSource;\n};\n\n/**\n * Represents a set of results keyed by Scripture reference. Generally, the source will be a\n * particular Scripture check, but this type also allows for other types of uniquely identifiable\n * sources.\n */\nexport type ResultsSet = {\n /**\n * The backing source associated with this set of results.\n *\n * @type {ResultsSource}\n */\n source: ResultsSource;\n\n /**\n * Array of Scripture item details (messages keyed by Scripture reference).\n *\n * @type {ScriptureItemDetail[]}\n */\n data: ScriptureItemDetail[];\n};\n\nconst scrBookColId = 'scrBook';\nconst scrRefColId = 'scrRef';\nconst typeColId = 'source';\nconst detailsColId = 'details';\n\nconst defaultScrRefColumnName = 'Scripture Reference';\nconst defaultScrBookGroupName = 'Scripture Book';\nconst defaultTypeColumnName = 'Type';\nconst defaultDetailsColumnName = 'Details';\n\nexport type ScriptureResultsViewerColumnInfo = {\n /** Optional header to display for the Reference column. Default value: 'Scripture Reference'. */\n scriptureReferenceColumnName?: string;\n\n /** Optional text to display to refer to the Scripture book group. Default value: 'Scripture Book'. */\n scriptureBookGroupName?: string;\n\n /** Optional header to display for the Type column. Default value: 'Type'. */\n typeColumnName?: string;\n\n /** Optional header to display for the Details column. Default value: 'Details' */\n detailsColumnName?: string;\n};\n\nexport type ScriptureResultsViewerProps = ScriptureResultsViewerColumnInfo & {\n /** Groups of ScriptureItemDetail objects from particular sources (e.g., Scripture checks) */\n sources: ResultsSet[];\n\n /** Flag indicating whether to display column headers. Default is false. */\n showColumnHeaders?: boolean;\n\n /** Flag indicating whether to display source column. Default is false. */\n showSourceColumn?: boolean;\n\n /** Callback function to notify when a row is selected */\n onRowSelected?: (selectedRow: ScriptureSrcItemDetail | undefined) => void;\n\n /** Text direction ltr or rtl */\n direction?: 'ltr' | 'rtl';\n};\n\nfunction getColumns(\n colInfo?: ScriptureResultsViewerColumnInfo,\n showSourceColumn?: boolean,\n): ColumnDef[] {\n const showSrcCol = showSourceColumn ?? false;\n return [\n {\n accessorFn: (row) =>\n `${Canon.bookNumberToId(row.start.bookNum)} ${row.start.chapterNum}:${row.start.verseNum}`,\n id: scrBookColId,\n header: colInfo?.scriptureReferenceColumnName ?? defaultScrRefColumnName,\n cell: (info) => {\n const row = info.row.original;\n if (info.row.getIsGrouped()) {\n return Canon.bookNumberToEnglishName(row.start.bookNum);\n }\n return info.row.groupingColumnId === scrBookColId ? formatScrRef(row.start) : undefined;\n },\n getGroupingValue: (row) => row.start.bookNum,\n sortingFn: (a, b) => {\n return compareScrRefs(a.original.start, b.original.start);\n },\n enableGrouping: true,\n },\n {\n accessorFn: (row) => formatScrRef(row.start),\n id: scrRefColId,\n header: undefined,\n cell: (info) => {\n const row = info.row.original;\n return info.row.getIsGrouped() ? undefined : formatScrRef(row.start);\n },\n sortingFn: (a, b) => {\n return compareScrRefs(a.original.start, b.original.start);\n },\n enableGrouping: false,\n },\n {\n accessorFn: (row) => row.source.displayName,\n id: typeColId,\n header: showSrcCol ? (colInfo?.typeColumnName ?? defaultTypeColumnName) : undefined,\n cell: (info) => (showSrcCol || info.row.getIsGrouped() ? info.getValue() : undefined),\n getGroupingValue: (row) => row.source.id,\n sortingFn: (a, b) =>\n a.original.source.displayName.localeCompare(b.original.source.displayName),\n enableGrouping: true,\n },\n {\n accessorFn: (row) => row.detail,\n id: detailsColId,\n header: colInfo?.detailsColumnName ?? defaultDetailsColumnName,\n cell: (info) => info.getValue(),\n enableGrouping: false,\n },\n ];\n}\n\nconst toRefOrRange = (scriptureSelection: ScriptureSelection) => {\n if (!('offset' in scriptureSelection.start))\n throw new Error('No offset available in range start');\n if (scriptureSelection.end && !('offset' in scriptureSelection.end))\n throw new Error('No offset available in range end');\n const { offset: offsetStart } = scriptureSelection.start;\n let offsetEnd: number = 0;\n if (scriptureSelection.end) ({ offset: offsetEnd } = scriptureSelection.end);\n if (\n !scriptureSelection.end ||\n compareScrRefs(scriptureSelection.start, scriptureSelection.end) === 0\n )\n return `${scrRefToBBBCCCVVV(scriptureSelection.start)}+${offsetStart}`;\n return `${scrRefToBBBCCCVVV(scriptureSelection.start)}+${offsetStart}-${scrRefToBBBCCCVVV(scriptureSelection.end)}+${offsetEnd}`;\n};\n\nconst getRowKey = (row: ScriptureSrcItemDetail) =>\n `${toRefOrRange({ start: row.start, end: row.end })} ${row.source.displayName} ${row.detail}`;\n\n/**\n * Component to display a combined list of detailed items from one or more sources, where the items\n * are keyed primarily by Scripture reference. This is particularly useful for displaying a list of\n * results from Scripture checks, but more generally could be used to display any \"results\" from any\n * source(s). The component allows for grouping by Scripture book, source, or both. By default, it\n * displays somewhat \"tree-like\" which allows it to be more horizontally compact and intuitive. But\n * it also has the option of displaying as a traditional table with column headings (with or without\n * the source column showing).\n */\nexport default function ScriptureResultsViewer({\n sources,\n showColumnHeaders = false,\n showSourceColumn = false,\n scriptureReferenceColumnName,\n scriptureBookGroupName,\n typeColumnName,\n detailsColumnName,\n onRowSelected,\n direction = 'ltr',\n}: ScriptureResultsViewerProps) {\n const [grouping, setGrouping] = useState([]);\n const [sorting, setSorting] = useState([{ id: scrBookColId, desc: false }]);\n const [rowSelection, setRowSelection] = useState({});\n\n const scriptureResults = useMemo(\n () =>\n sources.flatMap((source) => {\n return source.data.map((item) => ({\n ...item,\n source: source.source,\n }));\n }),\n [sources],\n );\n\n const columns = useMemo(\n () =>\n getColumns(\n {\n scriptureReferenceColumnName,\n typeColumnName,\n detailsColumnName,\n },\n showSourceColumn,\n ),\n [scriptureReferenceColumnName, typeColumnName, detailsColumnName, showSourceColumn],\n );\n\n useEffect(() => {\n // Ensure sorting is applied correctly when grouped by type\n if (grouping.includes(typeColId)) {\n setSorting([\n { id: typeColId, desc: false },\n { id: scrBookColId, desc: false },\n ]);\n } else {\n setSorting([{ id: scrBookColId, desc: false }]);\n }\n }, [grouping]);\n\n const table = useReactTable({\n data: scriptureResults,\n columns,\n state: {\n grouping,\n sorting,\n rowSelection,\n },\n onGroupingChange: setGrouping,\n onSortingChange: setSorting,\n onRowSelectionChange: setRowSelection,\n getExpandedRowModel: getExpandedRowModel(),\n getGroupedRowModel: getGroupedRowModel(),\n getCoreRowModel: getCoreRowModel(),\n getSortedRowModel: getSortedRowModel(),\n getRowId: getRowKey,\n autoResetExpanded: false,\n enableMultiRowSelection: false,\n enableSubRowSelection: false,\n });\n\n useEffect(() => {\n if (onRowSelected) {\n const selectedRows = table.getSelectedRowModel().rowsById;\n const keys = Object.keys(selectedRows);\n if (keys.length === 1) {\n const selectedRow = scriptureResults.find((row) => getRowKey(row) === keys[0]) || undefined;\n if (selectedRow) onRowSelected(selectedRow);\n }\n }\n }, [rowSelection, scriptureResults, onRowSelected, table]);\n\n // Define possible grouping options\n const scrBookGroupName = scriptureBookGroupName ?? defaultScrBookGroupName;\n const typeGroupName = typeColumnName ?? defaultTypeColumnName;\n\n const groupingOptions = [\n { label: 'No Grouping', value: [] },\n { label: `Group by ${scrBookGroupName}`, value: [scrBookColId] },\n { label: `Group by ${typeGroupName}`, value: [typeColId] },\n {\n label: `Group by ${scrBookGroupName} and ${typeGroupName}`,\n value: [scrBookColId, typeColId],\n },\n {\n label: `Group by ${typeGroupName} and ${scrBookGroupName}`,\n value: [typeColId, scrBookColId],\n },\n ];\n\n const handleSelectChange = (selectedGrouping: string) => {\n setGrouping(JSON.parse(selectedGrouping));\n };\n\n const handleRowClick = (row: Row, event: MouseEvent) => {\n if (!row.getIsGrouped() && !row.getIsSelected()) {\n row.getToggleSelectedHandler()(event);\n }\n };\n\n const getEvenOrOddBandingStyle = (row: Row, index: number) => {\n if (row.getIsGrouped()) return '';\n // UX has now said they don't think they want banding. I'm leaving in the code to\n // set even and odd styles, but there's nothing in the CSS to style them differently.\n // The \"even\" style used to also have tw-bg-neutral-300 (along with even) to create\n // a visual banding effect. That could be added back in if UX changes the decision.\n return cn('banded-row', index % 2 === 0 ? 'even' : 'odd');\n };\n\n const getIndent = (\n groupingState: GroupingState,\n row: Row,\n cell: Cell,\n ) => {\n if (groupingState?.length === 0 || row.depth < cell.column.getGroupedIndex()) return undefined;\n if (row.getIsGrouped()) {\n switch (row.depth) {\n case 1:\n return 'tw-ps-4';\n default:\n return undefined;\n }\n }\n switch (row.depth) {\n case 1:\n return 'tw-ps-8';\n case 2:\n return 'tw-ps-12';\n default:\n return undefined;\n }\n };\n\n return (\n
    \n {!showColumnHeaders && (\n {\n handleSelectChange(value);\n }}\n >\n \n \n \n \n \n {groupingOptions.map((option) => (\n \n {option.label}\n \n ))}\n \n \n \n )}\n \n {showColumnHeaders && (\n \n {table.getHeaderGroups().map((headerGroup) => (\n \n {headerGroup.headers\n .filter((h) => h.column.columnDef.header)\n .map((header) => (\n /* For sticky column headers to work, we probably need to change the default definition of the shadcn Table component. See https://github.com/shadcn-ui/ui/issues/1151 */\n \n {header.isPlaceholder ? undefined : (\n
    \n {header.column.getCanGroup() ? (\n \n {header.column.getIsGrouped() ? `🛑` : `👊 `}\n \n ) : undefined}{' '}\n {flexRender(header.column.columnDef.header, header.getContext())}\n
    \n )}\n
    \n ))}\n
    \n ))}\n
    \n )}\n \n {table.getRowModel().rows.map((row, rowIndex) => {\n return (\n handleRowClick(row, event)}\n >\n {row.getVisibleCells().map((cell) => {\n if (\n cell.getIsPlaceholder() ||\n (cell.column.columnDef.enableGrouping &&\n !cell.getIsGrouped() &&\n (cell.column.columnDef.id !== typeColId || !showSourceColumn))\n )\n return undefined;\n return (\n \n {(() => {\n if (cell.getIsGrouped()) {\n return (\n \n {row.getIsExpanded() && }\n {!row.getIsExpanded() &&\n (direction === 'ltr' ? : )}{' '}\n {flexRender(cell.column.columnDef.cell, cell.getContext())} (\n {row.subRows.length})\n \n );\n }\n\n // if (cell.getIsAggregated()) {\n // flexRender(\n // cell.column.columnDef.aggregatedCell ?? cell.column.columnDef.cell,\n // cell.getContext(),\n // );\n // }\n\n return flexRender(cell.column.columnDef.cell, cell.getContext());\n })()}\n \n );\n })}\n \n );\n })}\n \n
    \n
    \n );\n}\n","import {\n getLocalizeKeyForScrollGroupId,\n LanguageStrings,\n ScrollGroupId,\n} from 'platform-bible-utils';\nimport {\n Select,\n SelectContent,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\n\nconst DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS = {\n [getLocalizeKeyForScrollGroupId('undefined')]: 'Ø',\n [getLocalizeKeyForScrollGroupId(0)]: 'A',\n [getLocalizeKeyForScrollGroupId(1)]: 'B',\n [getLocalizeKeyForScrollGroupId(2)]: 'C',\n [getLocalizeKeyForScrollGroupId(3)]: 'D',\n [getLocalizeKeyForScrollGroupId(4)]: 'E',\n [getLocalizeKeyForScrollGroupId(5)]: 'F',\n [getLocalizeKeyForScrollGroupId(6)]: 'G',\n [getLocalizeKeyForScrollGroupId(7)]: 'H',\n [getLocalizeKeyForScrollGroupId(8)]: 'I',\n [getLocalizeKeyForScrollGroupId(9)]: 'J',\n [getLocalizeKeyForScrollGroupId(10)]: 'K',\n [getLocalizeKeyForScrollGroupId(11)]: 'L',\n [getLocalizeKeyForScrollGroupId(12)]: 'M',\n [getLocalizeKeyForScrollGroupId(13)]: 'N',\n [getLocalizeKeyForScrollGroupId(14)]: 'O',\n [getLocalizeKeyForScrollGroupId(15)]: 'P',\n [getLocalizeKeyForScrollGroupId(16)]: 'Q',\n [getLocalizeKeyForScrollGroupId(17)]: 'R',\n [getLocalizeKeyForScrollGroupId(18)]: 'S',\n [getLocalizeKeyForScrollGroupId(19)]: 'T',\n [getLocalizeKeyForScrollGroupId(20)]: 'U',\n [getLocalizeKeyForScrollGroupId(21)]: 'V',\n [getLocalizeKeyForScrollGroupId(22)]: 'W',\n [getLocalizeKeyForScrollGroupId(23)]: 'X',\n [getLocalizeKeyForScrollGroupId(24)]: 'Y',\n [getLocalizeKeyForScrollGroupId(25)]: 'Z',\n};\n\nexport type ScrollGroupSelectorProps = {\n /**\n * List of scroll group ids to show to the user. Either a {@link ScrollGroupId} or `undefined` for\n * no scroll group\n */\n availableScrollGroupIds: (ScrollGroupId | undefined)[];\n /** Currently selected scroll group id. `undefined` for no scroll group */\n scrollGroupId: ScrollGroupId | undefined;\n /** Callback function run when the user tries to change the scroll group id */\n onChangeScrollGroupId: (newScrollGroupId: ScrollGroupId | undefined) => void;\n /**\n * Localized strings to use for displaying scroll group ids. Must be an object whose keys are\n * `getLocalizeKeyForScrollGroupId(scrollGroupId)` for all scroll group ids (and `undefined` if\n * included) in {@link ScrollGroupSelectorProps.availableScrollGroupIds} and whose values are the\n * localized strings to use for those scroll group ids.\n *\n * Defaults to English localizations of English alphabet for scroll groups 0-25 (e.g. 0 is A) and\n * Ø for `undefined`. Will fill in any that are not provided with these English localizations.\n * Also, if any values match the keys, the English localization will be used. This is useful in\n * case you want to pass in a temporary version of the localized strings while your localized\n * strings load.\n *\n * @example\n *\n * ```typescript\n * const myScrollGroupIdLocalizedStrings = {\n * [getLocalizeKeyForScrollGroupId('undefined')]: 'Ø',\n * [getLocalizeKeyForScrollGroupId(0)]: 'A',\n * [getLocalizeKeyForScrollGroupId(1)]: 'B',\n * [getLocalizeKeyForScrollGroupId(2)]: 'C',\n * [getLocalizeKeyForScrollGroupId(3)]: 'D',\n * [getLocalizeKeyForScrollGroupId(4)]: 'E',\n * };\n * ```\n *\n * @example\n *\n * ```tsx\n * const availableScrollGroupIds = [undefined, 0, 1, 2, 3, 4];\n *\n * const localizeKeys = getLocalizeKeysForScrollGroupIds();\n *\n * const [localizedStrings] = useLocalizedStrings(localizeKeys);\n *\n * ...\n *\n * \n * ```\n */\n localizedStrings?: LanguageStrings;\n};\n\n/** Selector component for choosing a scroll group */\nexport default function ScrollGroupSelector({\n availableScrollGroupIds,\n scrollGroupId,\n onChangeScrollGroupId,\n localizedStrings = {},\n}: ScrollGroupSelectorProps) {\n const localizedStringsDefaulted = {\n ...DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS,\n ...Object.fromEntries(\n Object.entries(localizedStrings).map(\n ([localizedStringKey, localizedStringValue]: [string, string]) => [\n localizedStringKey,\n localizedStringKey === localizedStringValue &&\n localizedStringKey in DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS\n ? DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS[localizedStringKey]\n : localizedStringValue,\n ],\n ),\n ),\n };\n return (\n \n onChangeScrollGroupId(\n newScrollGroupString === 'undefined' ? undefined : parseInt(newScrollGroupString, 10),\n )\n }\n >\n \n \n \n \n {availableScrollGroupIds.map((scrollGroupOptionId) => (\n \n {localizedStringsDefaulted[getLocalizeKeyForScrollGroupId(scrollGroupOptionId)]}\n \n ))}\n \n \n );\n}\n","import { PropsWithChildren } from 'react';\nimport { Separator } from '@/components/shadcn-ui/separator';\n\n/** Props for the SettingsList component, currently just children */\ntype SettingsListProps = PropsWithChildren;\n\n/**\n * SettingsList component is a wrapper for list items. Rendered with a formatted div\n *\n * @param children To populate the list with\n * @returns Formatted div encompassing the children\n */\nexport function SettingsList({ children }: SettingsListProps) {\n return
    {children}
    ;\n}\n\n/** Props for SettingsListItem component */\ntype SettingsListItemProps = PropsWithChildren & {\n /** Primary text of the list item */\n primary: string;\n\n /** Optional text of the list item */\n secondary?: string | undefined;\n\n /** Optional boolean to display a message if the children aren't loaded yet. Defaults to false */\n isLoading?: boolean;\n\n /** Optional message to display if isLoading */\n loadingMessage?: string;\n};\n\n/**\n * SettingsListItem component is a common list item. Rendered with a formatted div\n *\n * @param primary Primary text of the list item\n * @param secondary Optional secondary text of the list item\n * @param isLoading Optional, to display a message if the action component isn't generated yet,\n * defaults to false\n * @param children The action component(s) to provide for this item\n * @param loadingMessage Optional, message to display if isLoading\n * @returns Formatted div encompassing the list item content\n */\nexport function SettingsListItem({\n primary,\n secondary,\n children,\n isLoading = false,\n loadingMessage,\n}: SettingsListItemProps) {\n return (\n
    \n
    \n

    {primary}

    \n

    \n {secondary}\n

    \n
    \n\n {isLoading ? (\n

    {loadingMessage}

    \n ) : (\n
    {children}
    \n )}\n
    \n );\n}\n\n/** Props for SettingsListHeader component */\ntype SettingsListHeaderProps = {\n /** The primary text of the list header */\n primary: string;\n\n /** Optional secondary text of the list header */\n secondary?: string | undefined;\n\n /** Optional boolean to include a separator underneath the secondary text. Defaults to false */\n includeSeparator?: boolean;\n};\n\n/**\n * SettingsListHeader component displays text above the list\n *\n * @param primary The primary text of the list header\n * @param secondary Optional secondary text of the list header\n * @param includeSeparator Optional boolean to include a separator underneath the secondary text.\n * Defaults to false\n * @returns Formatted div with list header content\n */\nexport function SettingsListHeader({\n primary,\n secondary,\n includeSeparator = false,\n}: SettingsListHeaderProps) {\n return (\n
    \n
    \n

    {primary}

    \n

    {secondary}

    \n
    \n {includeSeparator ? : ''}\n
    \n );\n}\n","import Checkbox from '@/components/shadcn-ui/checkbox';\nimport { Label } from '@/components/shadcn-ui/label';\n\nexport type ChecklistProps = {\n /** Optional string representing the id attribute of the Checklist */\n id?: string;\n /** Optional string representing CSS class name(s) for styling */\n className?: string;\n /** Array of strings representing the checkable items */\n listItems: string[];\n /** Array of strings representing the checked items */\n selectedListItems: string[];\n /**\n * Function that is called when a checkbox item is selected or deselected\n *\n * @param item The string description for this item\n * @param selected True if selected, false if not selected\n */\n handleSelectListItem: (item: string, selected: boolean) => void;\n\n /**\n * Optional function creates a label for a provided checkable item\n *\n * @param item The item for which a label is to be created\n * @returns A string representing the label text for the checkbox associated with that item\n */\n createLabel?: (item: string) => string;\n};\n\n/** Renders a list of checkboxes. Each checkbox corresponds to an item from the `listItems` array. */\nexport default function Checklist({\n id,\n className,\n listItems,\n selectedListItems,\n handleSelectListItem,\n createLabel,\n}: ChecklistProps) {\n return (\n
    \n {listItems.map((item) => (\n
    \n handleSelectListItem(item, value)}\n />\n \n
    \n ))}\n
    \n );\n}\n","function _interopRequireDefault(obj) {\n return obj && obj.__esModule ? obj : {\n \"default\": obj\n };\n}\nmodule.exports = _interopRequireDefault, module.exports.__esModule = true, module.exports[\"default\"] = module.exports;","export default function chainPropTypes(propType1, propType2) {\n if (process.env.NODE_ENV === 'production') {\n return () => null;\n }\n return function validate(...args) {\n return propType1(...args) || propType2(...args);\n };\n}","export default function _extends() {\n _extends = Object.assign ? Object.assign.bind() : function (target) {\n for (var i = 1; i < arguments.length; i++) {\n var source = arguments[i];\n for (var key in source) {\n if (Object.prototype.hasOwnProperty.call(source, key)) {\n target[key] = source[key];\n }\n }\n }\n return target;\n };\n return _extends.apply(this, arguments);\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\n// https://github.com/sindresorhus/is-plain-obj/blob/main/index.js\nexport function isPlainObject(item) {\n if (typeof item !== 'object' || item === null) {\n return false;\n }\n const prototype = Object.getPrototypeOf(item);\n return (prototype === null || prototype === Object.prototype || Object.getPrototypeOf(prototype) === null) && !(Symbol.toStringTag in item) && !(Symbol.iterator in item);\n}\nfunction deepClone(source) {\n if (!isPlainObject(source)) {\n return source;\n }\n const output = {};\n Object.keys(source).forEach(key => {\n output[key] = deepClone(source[key]);\n });\n return output;\n}\nexport default function deepmerge(target, source, options = {\n clone: true\n}) {\n const output = options.clone ? _extends({}, target) : target;\n if (isPlainObject(target) && isPlainObject(source)) {\n Object.keys(source).forEach(key => {\n // Avoid prototype pollution\n if (key === '__proto__') {\n return;\n }\n if (isPlainObject(source[key]) && key in target && isPlainObject(target[key])) {\n // Since `output` is a clone of `target` and we have narrowed `target` in this block we can cast to the same type.\n output[key] = deepmerge(target[key], source[key], options);\n } else if (options.clone) {\n output[key] = isPlainObject(source[key]) ? deepClone(source[key]) : source[key];\n } else {\n output[key] = source[key];\n }\n });\n }\n return output;\n}","/** @license React v16.13.1\n * react-is.production.min.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';var b=\"function\"===typeof Symbol&&Symbol.for,c=b?Symbol.for(\"react.element\"):60103,d=b?Symbol.for(\"react.portal\"):60106,e=b?Symbol.for(\"react.fragment\"):60107,f=b?Symbol.for(\"react.strict_mode\"):60108,g=b?Symbol.for(\"react.profiler\"):60114,h=b?Symbol.for(\"react.provider\"):60109,k=b?Symbol.for(\"react.context\"):60110,l=b?Symbol.for(\"react.async_mode\"):60111,m=b?Symbol.for(\"react.concurrent_mode\"):60111,n=b?Symbol.for(\"react.forward_ref\"):60112,p=b?Symbol.for(\"react.suspense\"):60113,q=b?\nSymbol.for(\"react.suspense_list\"):60120,r=b?Symbol.for(\"react.memo\"):60115,t=b?Symbol.for(\"react.lazy\"):60116,v=b?Symbol.for(\"react.block\"):60121,w=b?Symbol.for(\"react.fundamental\"):60117,x=b?Symbol.for(\"react.responder\"):60118,y=b?Symbol.for(\"react.scope\"):60119;\nfunction z(a){if(\"object\"===typeof a&&null!==a){var u=a.$$typeof;switch(u){case c:switch(a=a.type,a){case l:case m:case e:case g:case f:case p:return a;default:switch(a=a&&a.$$typeof,a){case k:case n:case t:case r:case h:return a;default:return u}}case d:return u}}}function A(a){return z(a)===m}exports.AsyncMode=l;exports.ConcurrentMode=m;exports.ContextConsumer=k;exports.ContextProvider=h;exports.Element=c;exports.ForwardRef=n;exports.Fragment=e;exports.Lazy=t;exports.Memo=r;exports.Portal=d;\nexports.Profiler=g;exports.StrictMode=f;exports.Suspense=p;exports.isAsyncMode=function(a){return A(a)||z(a)===l};exports.isConcurrentMode=A;exports.isContextConsumer=function(a){return z(a)===k};exports.isContextProvider=function(a){return z(a)===h};exports.isElement=function(a){return\"object\"===typeof a&&null!==a&&a.$$typeof===c};exports.isForwardRef=function(a){return z(a)===n};exports.isFragment=function(a){return z(a)===e};exports.isLazy=function(a){return z(a)===t};\nexports.isMemo=function(a){return z(a)===r};exports.isPortal=function(a){return z(a)===d};exports.isProfiler=function(a){return z(a)===g};exports.isStrictMode=function(a){return z(a)===f};exports.isSuspense=function(a){return z(a)===p};\nexports.isValidElementType=function(a){return\"string\"===typeof a||\"function\"===typeof a||a===e||a===m||a===g||a===f||a===p||a===q||\"object\"===typeof a&&null!==a&&(a.$$typeof===t||a.$$typeof===r||a.$$typeof===h||a.$$typeof===k||a.$$typeof===n||a.$$typeof===w||a.$$typeof===x||a.$$typeof===y||a.$$typeof===v)};exports.typeOf=z;\n","/** @license React v16.13.1\n * react-is.development.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\n\n\nif (process.env.NODE_ENV !== \"production\") {\n (function() {\n'use strict';\n\n// The Symbol used to tag the ReactElement-like types. If there is no native Symbol\n// nor polyfill, then a plain number is used for performance.\nvar hasSymbol = typeof Symbol === 'function' && Symbol.for;\nvar REACT_ELEMENT_TYPE = hasSymbol ? Symbol.for('react.element') : 0xeac7;\nvar REACT_PORTAL_TYPE = hasSymbol ? Symbol.for('react.portal') : 0xeaca;\nvar REACT_FRAGMENT_TYPE = hasSymbol ? Symbol.for('react.fragment') : 0xeacb;\nvar REACT_STRICT_MODE_TYPE = hasSymbol ? Symbol.for('react.strict_mode') : 0xeacc;\nvar REACT_PROFILER_TYPE = hasSymbol ? Symbol.for('react.profiler') : 0xead2;\nvar REACT_PROVIDER_TYPE = hasSymbol ? Symbol.for('react.provider') : 0xeacd;\nvar REACT_CONTEXT_TYPE = hasSymbol ? Symbol.for('react.context') : 0xeace; // TODO: We don't use AsyncMode or ConcurrentMode anymore. They were temporary\n// (unstable) APIs that have been removed. Can we remove the symbols?\n\nvar REACT_ASYNC_MODE_TYPE = hasSymbol ? Symbol.for('react.async_mode') : 0xeacf;\nvar REACT_CONCURRENT_MODE_TYPE = hasSymbol ? Symbol.for('react.concurrent_mode') : 0xeacf;\nvar REACT_FORWARD_REF_TYPE = hasSymbol ? Symbol.for('react.forward_ref') : 0xead0;\nvar REACT_SUSPENSE_TYPE = hasSymbol ? Symbol.for('react.suspense') : 0xead1;\nvar REACT_SUSPENSE_LIST_TYPE = hasSymbol ? Symbol.for('react.suspense_list') : 0xead8;\nvar REACT_MEMO_TYPE = hasSymbol ? Symbol.for('react.memo') : 0xead3;\nvar REACT_LAZY_TYPE = hasSymbol ? Symbol.for('react.lazy') : 0xead4;\nvar REACT_BLOCK_TYPE = hasSymbol ? Symbol.for('react.block') : 0xead9;\nvar REACT_FUNDAMENTAL_TYPE = hasSymbol ? Symbol.for('react.fundamental') : 0xead5;\nvar REACT_RESPONDER_TYPE = hasSymbol ? Symbol.for('react.responder') : 0xead6;\nvar REACT_SCOPE_TYPE = hasSymbol ? Symbol.for('react.scope') : 0xead7;\n\nfunction isValidElementType(type) {\n return typeof type === 'string' || typeof type === 'function' || // Note: its typeof might be other than 'symbol' or 'number' if it's a polyfill.\n type === REACT_FRAGMENT_TYPE || type === REACT_CONCURRENT_MODE_TYPE || type === REACT_PROFILER_TYPE || type === REACT_STRICT_MODE_TYPE || type === REACT_SUSPENSE_TYPE || type === REACT_SUSPENSE_LIST_TYPE || typeof type === 'object' && type !== null && (type.$$typeof === REACT_LAZY_TYPE || type.$$typeof === REACT_MEMO_TYPE || type.$$typeof === REACT_PROVIDER_TYPE || type.$$typeof === REACT_CONTEXT_TYPE || type.$$typeof === REACT_FORWARD_REF_TYPE || type.$$typeof === REACT_FUNDAMENTAL_TYPE || type.$$typeof === REACT_RESPONDER_TYPE || type.$$typeof === REACT_SCOPE_TYPE || type.$$typeof === REACT_BLOCK_TYPE);\n}\n\nfunction typeOf(object) {\n if (typeof object === 'object' && object !== null) {\n var $$typeof = object.$$typeof;\n\n switch ($$typeof) {\n case REACT_ELEMENT_TYPE:\n var type = object.type;\n\n switch (type) {\n case REACT_ASYNC_MODE_TYPE:\n case REACT_CONCURRENT_MODE_TYPE:\n case REACT_FRAGMENT_TYPE:\n case REACT_PROFILER_TYPE:\n case REACT_STRICT_MODE_TYPE:\n case REACT_SUSPENSE_TYPE:\n return type;\n\n default:\n var $$typeofType = type && type.$$typeof;\n\n switch ($$typeofType) {\n case REACT_CONTEXT_TYPE:\n case REACT_FORWARD_REF_TYPE:\n case REACT_LAZY_TYPE:\n case REACT_MEMO_TYPE:\n case REACT_PROVIDER_TYPE:\n return $$typeofType;\n\n default:\n return $$typeof;\n }\n\n }\n\n case REACT_PORTAL_TYPE:\n return $$typeof;\n }\n }\n\n return undefined;\n} // AsyncMode is deprecated along with isAsyncMode\n\nvar AsyncMode = REACT_ASYNC_MODE_TYPE;\nvar ConcurrentMode = REACT_CONCURRENT_MODE_TYPE;\nvar ContextConsumer = REACT_CONTEXT_TYPE;\nvar ContextProvider = REACT_PROVIDER_TYPE;\nvar Element = REACT_ELEMENT_TYPE;\nvar ForwardRef = REACT_FORWARD_REF_TYPE;\nvar Fragment = REACT_FRAGMENT_TYPE;\nvar Lazy = REACT_LAZY_TYPE;\nvar Memo = REACT_MEMO_TYPE;\nvar Portal = REACT_PORTAL_TYPE;\nvar Profiler = REACT_PROFILER_TYPE;\nvar StrictMode = REACT_STRICT_MODE_TYPE;\nvar Suspense = REACT_SUSPENSE_TYPE;\nvar hasWarnedAboutDeprecatedIsAsyncMode = false; // AsyncMode should be deprecated\n\nfunction isAsyncMode(object) {\n {\n if (!hasWarnedAboutDeprecatedIsAsyncMode) {\n hasWarnedAboutDeprecatedIsAsyncMode = true; // Using console['warn'] to evade Babel and ESLint\n\n console['warn']('The ReactIs.isAsyncMode() alias has been deprecated, ' + 'and will be removed in React 17+. Update your code to use ' + 'ReactIs.isConcurrentMode() instead. It has the exact same API.');\n }\n }\n\n return isConcurrentMode(object) || typeOf(object) === REACT_ASYNC_MODE_TYPE;\n}\nfunction isConcurrentMode(object) {\n return typeOf(object) === REACT_CONCURRENT_MODE_TYPE;\n}\nfunction isContextConsumer(object) {\n return typeOf(object) === REACT_CONTEXT_TYPE;\n}\nfunction isContextProvider(object) {\n return typeOf(object) === REACT_PROVIDER_TYPE;\n}\nfunction isElement(object) {\n return typeof object === 'object' && object !== null && object.$$typeof === REACT_ELEMENT_TYPE;\n}\nfunction isForwardRef(object) {\n return typeOf(object) === REACT_FORWARD_REF_TYPE;\n}\nfunction isFragment(object) {\n return typeOf(object) === REACT_FRAGMENT_TYPE;\n}\nfunction isLazy(object) {\n return typeOf(object) === REACT_LAZY_TYPE;\n}\nfunction isMemo(object) {\n return typeOf(object) === REACT_MEMO_TYPE;\n}\nfunction isPortal(object) {\n return typeOf(object) === REACT_PORTAL_TYPE;\n}\nfunction isProfiler(object) {\n return typeOf(object) === REACT_PROFILER_TYPE;\n}\nfunction isStrictMode(object) {\n return typeOf(object) === REACT_STRICT_MODE_TYPE;\n}\nfunction isSuspense(object) {\n return typeOf(object) === REACT_SUSPENSE_TYPE;\n}\n\nexports.AsyncMode = AsyncMode;\nexports.ConcurrentMode = ConcurrentMode;\nexports.ContextConsumer = ContextConsumer;\nexports.ContextProvider = ContextProvider;\nexports.Element = Element;\nexports.ForwardRef = ForwardRef;\nexports.Fragment = Fragment;\nexports.Lazy = Lazy;\nexports.Memo = Memo;\nexports.Portal = Portal;\nexports.Profiler = Profiler;\nexports.StrictMode = StrictMode;\nexports.Suspense = Suspense;\nexports.isAsyncMode = isAsyncMode;\nexports.isConcurrentMode = isConcurrentMode;\nexports.isContextConsumer = isContextConsumer;\nexports.isContextProvider = isContextProvider;\nexports.isElement = isElement;\nexports.isForwardRef = isForwardRef;\nexports.isFragment = isFragment;\nexports.isLazy = isLazy;\nexports.isMemo = isMemo;\nexports.isPortal = isPortal;\nexports.isProfiler = isProfiler;\nexports.isStrictMode = isStrictMode;\nexports.isSuspense = isSuspense;\nexports.isValidElementType = isValidElementType;\nexports.typeOf = typeOf;\n })();\n}\n","'use strict';\n\nif (process.env.NODE_ENV === 'production') {\n module.exports = require('./cjs/react-is.production.min.js');\n} else {\n module.exports = require('./cjs/react-is.development.js');\n}\n","/*\nobject-assign\n(c) Sindre Sorhus\n@license MIT\n*/\n\n'use strict';\n/* eslint-disable no-unused-vars */\nvar getOwnPropertySymbols = Object.getOwnPropertySymbols;\nvar hasOwnProperty = Object.prototype.hasOwnProperty;\nvar propIsEnumerable = Object.prototype.propertyIsEnumerable;\n\nfunction toObject(val) {\n\tif (val === null || val === undefined) {\n\t\tthrow new TypeError('Object.assign cannot be called with null or undefined');\n\t}\n\n\treturn Object(val);\n}\n\nfunction shouldUseNative() {\n\ttry {\n\t\tif (!Object.assign) {\n\t\t\treturn false;\n\t\t}\n\n\t\t// Detect buggy property enumeration order in older V8 versions.\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=4118\n\t\tvar test1 = new String('abc'); // eslint-disable-line no-new-wrappers\n\t\ttest1[5] = 'de';\n\t\tif (Object.getOwnPropertyNames(test1)[0] === '5') {\n\t\t\treturn false;\n\t\t}\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=3056\n\t\tvar test2 = {};\n\t\tfor (var i = 0; i < 10; i++) {\n\t\t\ttest2['_' + String.fromCharCode(i)] = i;\n\t\t}\n\t\tvar order2 = Object.getOwnPropertyNames(test2).map(function (n) {\n\t\t\treturn test2[n];\n\t\t});\n\t\tif (order2.join('') !== '0123456789') {\n\t\t\treturn false;\n\t\t}\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=3056\n\t\tvar test3 = {};\n\t\t'abcdefghijklmnopqrst'.split('').forEach(function (letter) {\n\t\t\ttest3[letter] = letter;\n\t\t});\n\t\tif (Object.keys(Object.assign({}, test3)).join('') !==\n\t\t\t\t'abcdefghijklmnopqrst') {\n\t\t\treturn false;\n\t\t}\n\n\t\treturn true;\n\t} catch (err) {\n\t\t// We don't expect any of the above to throw, but better to be safe.\n\t\treturn false;\n\t}\n}\n\nmodule.exports = shouldUseNative() ? Object.assign : function (target, source) {\n\tvar from;\n\tvar to = toObject(target);\n\tvar symbols;\n\n\tfor (var s = 1; s < arguments.length; s++) {\n\t\tfrom = Object(arguments[s]);\n\n\t\tfor (var key in from) {\n\t\t\tif (hasOwnProperty.call(from, key)) {\n\t\t\t\tto[key] = from[key];\n\t\t\t}\n\t\t}\n\n\t\tif (getOwnPropertySymbols) {\n\t\t\tsymbols = getOwnPropertySymbols(from);\n\t\t\tfor (var i = 0; i < symbols.length; i++) {\n\t\t\t\tif (propIsEnumerable.call(from, symbols[i])) {\n\t\t\t\t\tto[symbols[i]] = from[symbols[i]];\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\n\treturn to;\n};\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar ReactPropTypesSecret = 'SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED';\n\nmodule.exports = ReactPropTypesSecret;\n","module.exports = Function.call.bind(Object.prototype.hasOwnProperty);\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar printWarning = function() {};\n\nif (process.env.NODE_ENV !== 'production') {\n var ReactPropTypesSecret = require('./lib/ReactPropTypesSecret');\n var loggedTypeFailures = {};\n var has = require('./lib/has');\n\n printWarning = function(text) {\n var message = 'Warning: ' + text;\n if (typeof console !== 'undefined') {\n console.error(message);\n }\n try {\n // --- Welcome to debugging React ---\n // This error was thrown as a convenience so that you can use this stack\n // to find the callsite that caused this warning to fire.\n throw new Error(message);\n } catch (x) { /**/ }\n };\n}\n\n/**\n * Assert that the values match with the type specs.\n * Error messages are memorized and will only be shown once.\n *\n * @param {object} typeSpecs Map of name to a ReactPropType\n * @param {object} values Runtime values that need to be type-checked\n * @param {string} location e.g. \"prop\", \"context\", \"child context\"\n * @param {string} componentName Name of the component for error messages.\n * @param {?Function} getStack Returns the component stack.\n * @private\n */\nfunction checkPropTypes(typeSpecs, values, location, componentName, getStack) {\n if (process.env.NODE_ENV !== 'production') {\n for (var typeSpecName in typeSpecs) {\n if (has(typeSpecs, typeSpecName)) {\n var error;\n // Prop type validation may throw. In case they do, we don't want to\n // fail the render phase where it didn't fail before. So we log it.\n // After these have been cleaned up, we'll let them throw.\n try {\n // This is intentionally an invariant that gets caught. It's the same\n // behavior as without this statement except with a better message.\n if (typeof typeSpecs[typeSpecName] !== 'function') {\n var err = Error(\n (componentName || 'React class') + ': ' + location + ' type `' + typeSpecName + '` is invalid; ' +\n 'it must be a function, usually from the `prop-types` package, but received `' + typeof typeSpecs[typeSpecName] + '`.' +\n 'This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.'\n );\n err.name = 'Invariant Violation';\n throw err;\n }\n error = typeSpecs[typeSpecName](values, typeSpecName, componentName, location, null, ReactPropTypesSecret);\n } catch (ex) {\n error = ex;\n }\n if (error && !(error instanceof Error)) {\n printWarning(\n (componentName || 'React class') + ': type specification of ' +\n location + ' `' + typeSpecName + '` is invalid; the type checker ' +\n 'function must return `null` or an `Error` but returned a ' + typeof error + '. ' +\n 'You may have forgotten to pass an argument to the type checker ' +\n 'creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and ' +\n 'shape all require an argument).'\n );\n }\n if (error instanceof Error && !(error.message in loggedTypeFailures)) {\n // Only monitor this failure once because there tends to be a lot of the\n // same error.\n loggedTypeFailures[error.message] = true;\n\n var stack = getStack ? getStack() : '';\n\n printWarning(\n 'Failed ' + location + ' type: ' + error.message + (stack != null ? stack : '')\n );\n }\n }\n }\n }\n}\n\n/**\n * Resets warning cache when testing.\n *\n * @private\n */\ncheckPropTypes.resetWarningCache = function() {\n if (process.env.NODE_ENV !== 'production') {\n loggedTypeFailures = {};\n }\n}\n\nmodule.exports = checkPropTypes;\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar ReactIs = require('react-is');\nvar assign = require('object-assign');\n\nvar ReactPropTypesSecret = require('./lib/ReactPropTypesSecret');\nvar has = require('./lib/has');\nvar checkPropTypes = require('./checkPropTypes');\n\nvar printWarning = function() {};\n\nif (process.env.NODE_ENV !== 'production') {\n printWarning = function(text) {\n var message = 'Warning: ' + text;\n if (typeof console !== 'undefined') {\n console.error(message);\n }\n try {\n // --- Welcome to debugging React ---\n // This error was thrown as a convenience so that you can use this stack\n // to find the callsite that caused this warning to fire.\n throw new Error(message);\n } catch (x) {}\n };\n}\n\nfunction emptyFunctionThatReturnsNull() {\n return null;\n}\n\nmodule.exports = function(isValidElement, throwOnDirectAccess) {\n /* global Symbol */\n var ITERATOR_SYMBOL = typeof Symbol === 'function' && Symbol.iterator;\n var FAUX_ITERATOR_SYMBOL = '@@iterator'; // Before Symbol spec.\n\n /**\n * Returns the iterator method function contained on the iterable object.\n *\n * Be sure to invoke the function with the iterable as context:\n *\n * var iteratorFn = getIteratorFn(myIterable);\n * if (iteratorFn) {\n * var iterator = iteratorFn.call(myIterable);\n * ...\n * }\n *\n * @param {?object} maybeIterable\n * @return {?function}\n */\n function getIteratorFn(maybeIterable) {\n var iteratorFn = maybeIterable && (ITERATOR_SYMBOL && maybeIterable[ITERATOR_SYMBOL] || maybeIterable[FAUX_ITERATOR_SYMBOL]);\n if (typeof iteratorFn === 'function') {\n return iteratorFn;\n }\n }\n\n /**\n * Collection of methods that allow declaration and validation of props that are\n * supplied to React components. Example usage:\n *\n * var Props = require('ReactPropTypes');\n * var MyArticle = React.createClass({\n * propTypes: {\n * // An optional string prop named \"description\".\n * description: Props.string,\n *\n * // A required enum prop named \"category\".\n * category: Props.oneOf(['News','Photos']).isRequired,\n *\n * // A prop named \"dialog\" that requires an instance of Dialog.\n * dialog: Props.instanceOf(Dialog).isRequired\n * },\n * render: function() { ... }\n * });\n *\n * A more formal specification of how these methods are used:\n *\n * type := array|bool|func|object|number|string|oneOf([...])|instanceOf(...)\n * decl := ReactPropTypes.{type}(.isRequired)?\n *\n * Each and every declaration produces a function with the same signature. This\n * allows the creation of custom validation functions. For example:\n *\n * var MyLink = React.createClass({\n * propTypes: {\n * // An optional string or URI prop named \"href\".\n * href: function(props, propName, componentName) {\n * var propValue = props[propName];\n * if (propValue != null && typeof propValue !== 'string' &&\n * !(propValue instanceof URI)) {\n * return new Error(\n * 'Expected a string or an URI for ' + propName + ' in ' +\n * componentName\n * );\n * }\n * }\n * },\n * render: function() {...}\n * });\n *\n * @internal\n */\n\n var ANONYMOUS = '<>';\n\n // Important!\n // Keep this list in sync with production version in `./factoryWithThrowingShims.js`.\n var ReactPropTypes = {\n array: createPrimitiveTypeChecker('array'),\n bigint: createPrimitiveTypeChecker('bigint'),\n bool: createPrimitiveTypeChecker('boolean'),\n func: createPrimitiveTypeChecker('function'),\n number: createPrimitiveTypeChecker('number'),\n object: createPrimitiveTypeChecker('object'),\n string: createPrimitiveTypeChecker('string'),\n symbol: createPrimitiveTypeChecker('symbol'),\n\n any: createAnyTypeChecker(),\n arrayOf: createArrayOfTypeChecker,\n element: createElementTypeChecker(),\n elementType: createElementTypeTypeChecker(),\n instanceOf: createInstanceTypeChecker,\n node: createNodeChecker(),\n objectOf: createObjectOfTypeChecker,\n oneOf: createEnumTypeChecker,\n oneOfType: createUnionTypeChecker,\n shape: createShapeTypeChecker,\n exact: createStrictShapeTypeChecker,\n };\n\n /**\n * inlined Object.is polyfill to avoid requiring consumers ship their own\n * https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object/is\n */\n /*eslint-disable no-self-compare*/\n function is(x, y) {\n // SameValue algorithm\n if (x === y) {\n // Steps 1-5, 7-10\n // Steps 6.b-6.e: +0 != -0\n return x !== 0 || 1 / x === 1 / y;\n } else {\n // Step 6.a: NaN == NaN\n return x !== x && y !== y;\n }\n }\n /*eslint-enable no-self-compare*/\n\n /**\n * We use an Error-like object for backward compatibility as people may call\n * PropTypes directly and inspect their output. However, we don't use real\n * Errors anymore. We don't inspect their stack anyway, and creating them\n * is prohibitively expensive if they are created too often, such as what\n * happens in oneOfType() for any type before the one that matched.\n */\n function PropTypeError(message, data) {\n this.message = message;\n this.data = data && typeof data === 'object' ? data: {};\n this.stack = '';\n }\n // Make `instanceof Error` still work for returned errors.\n PropTypeError.prototype = Error.prototype;\n\n function createChainableTypeChecker(validate) {\n if (process.env.NODE_ENV !== 'production') {\n var manualPropTypeCallCache = {};\n var manualPropTypeWarningCount = 0;\n }\n function checkType(isRequired, props, propName, componentName, location, propFullName, secret) {\n componentName = componentName || ANONYMOUS;\n propFullName = propFullName || propName;\n\n if (secret !== ReactPropTypesSecret) {\n if (throwOnDirectAccess) {\n // New behavior only for users of `prop-types` package\n var err = new Error(\n 'Calling PropTypes validators directly is not supported by the `prop-types` package. ' +\n 'Use `PropTypes.checkPropTypes()` to call them. ' +\n 'Read more at http://fb.me/use-check-prop-types'\n );\n err.name = 'Invariant Violation';\n throw err;\n } else if (process.env.NODE_ENV !== 'production' && typeof console !== 'undefined') {\n // Old behavior for people using React.PropTypes\n var cacheKey = componentName + ':' + propName;\n if (\n !manualPropTypeCallCache[cacheKey] &&\n // Avoid spamming the console because they are often not actionable except for lib authors\n manualPropTypeWarningCount < 3\n ) {\n printWarning(\n 'You are manually calling a React.PropTypes validation ' +\n 'function for the `' + propFullName + '` prop on `' + componentName + '`. This is deprecated ' +\n 'and will throw in the standalone `prop-types` package. ' +\n 'You may be seeing this warning due to a third-party PropTypes ' +\n 'library. See https://fb.me/react-warning-dont-call-proptypes ' + 'for details.'\n );\n manualPropTypeCallCache[cacheKey] = true;\n manualPropTypeWarningCount++;\n }\n }\n }\n if (props[propName] == null) {\n if (isRequired) {\n if (props[propName] === null) {\n return new PropTypeError('The ' + location + ' `' + propFullName + '` is marked as required ' + ('in `' + componentName + '`, but its value is `null`.'));\n }\n return new PropTypeError('The ' + location + ' `' + propFullName + '` is marked as required in ' + ('`' + componentName + '`, but its value is `undefined`.'));\n }\n return null;\n } else {\n return validate(props, propName, componentName, location, propFullName);\n }\n }\n\n var chainedCheckType = checkType.bind(null, false);\n chainedCheckType.isRequired = checkType.bind(null, true);\n\n return chainedCheckType;\n }\n\n function createPrimitiveTypeChecker(expectedType) {\n function validate(props, propName, componentName, location, propFullName, secret) {\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== expectedType) {\n // `propValue` being instance of, say, date/regexp, pass the 'object'\n // check, but we can offer a more precise error message here rather than\n // 'of type `object`'.\n var preciseType = getPreciseType(propValue);\n\n return new PropTypeError(\n 'Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + preciseType + '` supplied to `' + componentName + '`, expected ') + ('`' + expectedType + '`.'),\n {expectedType: expectedType}\n );\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createAnyTypeChecker() {\n return createChainableTypeChecker(emptyFunctionThatReturnsNull);\n }\n\n function createArrayOfTypeChecker(typeChecker) {\n function validate(props, propName, componentName, location, propFullName) {\n if (typeof typeChecker !== 'function') {\n return new PropTypeError('Property `' + propFullName + '` of component `' + componentName + '` has invalid PropType notation inside arrayOf.');\n }\n var propValue = props[propName];\n if (!Array.isArray(propValue)) {\n var propType = getPropType(propValue);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected an array.'));\n }\n for (var i = 0; i < propValue.length; i++) {\n var error = typeChecker(propValue, i, componentName, location, propFullName + '[' + i + ']', ReactPropTypesSecret);\n if (error instanceof Error) {\n return error;\n }\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createElementTypeChecker() {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n if (!isValidElement(propValue)) {\n var propType = getPropType(propValue);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected a single ReactElement.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createElementTypeTypeChecker() {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n if (!ReactIs.isValidElementType(propValue)) {\n var propType = getPropType(propValue);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected a single ReactElement type.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createInstanceTypeChecker(expectedClass) {\n function validate(props, propName, componentName, location, propFullName) {\n if (!(props[propName] instanceof expectedClass)) {\n var expectedClassName = expectedClass.name || ANONYMOUS;\n var actualClassName = getClassName(props[propName]);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + actualClassName + '` supplied to `' + componentName + '`, expected ') + ('instance of `' + expectedClassName + '`.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createEnumTypeChecker(expectedValues) {\n if (!Array.isArray(expectedValues)) {\n if (process.env.NODE_ENV !== 'production') {\n if (arguments.length > 1) {\n printWarning(\n 'Invalid arguments supplied to oneOf, expected an array, got ' + arguments.length + ' arguments. ' +\n 'A common mistake is to write oneOf(x, y, z) instead of oneOf([x, y, z]).'\n );\n } else {\n printWarning('Invalid argument supplied to oneOf, expected an array.');\n }\n }\n return emptyFunctionThatReturnsNull;\n }\n\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n for (var i = 0; i < expectedValues.length; i++) {\n if (is(propValue, expectedValues[i])) {\n return null;\n }\n }\n\n var valuesString = JSON.stringify(expectedValues, function replacer(key, value) {\n var type = getPreciseType(value);\n if (type === 'symbol') {\n return String(value);\n }\n return value;\n });\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of value `' + String(propValue) + '` ' + ('supplied to `' + componentName + '`, expected one of ' + valuesString + '.'));\n }\n return createChainableTypeChecker(validate);\n }\n\n function createObjectOfTypeChecker(typeChecker) {\n function validate(props, propName, componentName, location, propFullName) {\n if (typeof typeChecker !== 'function') {\n return new PropTypeError('Property `' + propFullName + '` of component `' + componentName + '` has invalid PropType notation inside objectOf.');\n }\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== 'object') {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected an object.'));\n }\n for (var key in propValue) {\n if (has(propValue, key)) {\n var error = typeChecker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret);\n if (error instanceof Error) {\n return error;\n }\n }\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createUnionTypeChecker(arrayOfTypeCheckers) {\n if (!Array.isArray(arrayOfTypeCheckers)) {\n process.env.NODE_ENV !== 'production' ? printWarning('Invalid argument supplied to oneOfType, expected an instance of array.') : void 0;\n return emptyFunctionThatReturnsNull;\n }\n\n for (var i = 0; i < arrayOfTypeCheckers.length; i++) {\n var checker = arrayOfTypeCheckers[i];\n if (typeof checker !== 'function') {\n printWarning(\n 'Invalid argument supplied to oneOfType. Expected an array of check functions, but ' +\n 'received ' + getPostfixForTypeWarning(checker) + ' at index ' + i + '.'\n );\n return emptyFunctionThatReturnsNull;\n }\n }\n\n function validate(props, propName, componentName, location, propFullName) {\n var expectedTypes = [];\n for (var i = 0; i < arrayOfTypeCheckers.length; i++) {\n var checker = arrayOfTypeCheckers[i];\n var checkerResult = checker(props, propName, componentName, location, propFullName, ReactPropTypesSecret);\n if (checkerResult == null) {\n return null;\n }\n if (checkerResult.data && has(checkerResult.data, 'expectedType')) {\n expectedTypes.push(checkerResult.data.expectedType);\n }\n }\n var expectedTypesMessage = (expectedTypes.length > 0) ? ', expected one of type [' + expectedTypes.join(', ') + ']': '';\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` supplied to ' + ('`' + componentName + '`' + expectedTypesMessage + '.'));\n }\n return createChainableTypeChecker(validate);\n }\n\n function createNodeChecker() {\n function validate(props, propName, componentName, location, propFullName) {\n if (!isNode(props[propName])) {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` supplied to ' + ('`' + componentName + '`, expected a ReactNode.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function invalidValidatorError(componentName, location, propFullName, key, type) {\n return new PropTypeError(\n (componentName || 'React class') + ': ' + location + ' type `' + propFullName + '.' + key + '` is invalid; ' +\n 'it must be a function, usually from the `prop-types` package, but received `' + type + '`.'\n );\n }\n\n function createShapeTypeChecker(shapeTypes) {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== 'object') {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type `' + propType + '` ' + ('supplied to `' + componentName + '`, expected `object`.'));\n }\n for (var key in shapeTypes) {\n var checker = shapeTypes[key];\n if (typeof checker !== 'function') {\n return invalidValidatorError(componentName, location, propFullName, key, getPreciseType(checker));\n }\n var error = checker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret);\n if (error) {\n return error;\n }\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createStrictShapeTypeChecker(shapeTypes) {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== 'object') {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type `' + propType + '` ' + ('supplied to `' + componentName + '`, expected `object`.'));\n }\n // We need to check all keys in case some are required but missing from props.\n var allKeys = assign({}, props[propName], shapeTypes);\n for (var key in allKeys) {\n var checker = shapeTypes[key];\n if (has(shapeTypes, key) && typeof checker !== 'function') {\n return invalidValidatorError(componentName, location, propFullName, key, getPreciseType(checker));\n }\n if (!checker) {\n return new PropTypeError(\n 'Invalid ' + location + ' `' + propFullName + '` key `' + key + '` supplied to `' + componentName + '`.' +\n '\\nBad object: ' + JSON.stringify(props[propName], null, ' ') +\n '\\nValid keys: ' + JSON.stringify(Object.keys(shapeTypes), null, ' ')\n );\n }\n var error = checker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret);\n if (error) {\n return error;\n }\n }\n return null;\n }\n\n return createChainableTypeChecker(validate);\n }\n\n function isNode(propValue) {\n switch (typeof propValue) {\n case 'number':\n case 'string':\n case 'undefined':\n return true;\n case 'boolean':\n return !propValue;\n case 'object':\n if (Array.isArray(propValue)) {\n return propValue.every(isNode);\n }\n if (propValue === null || isValidElement(propValue)) {\n return true;\n }\n\n var iteratorFn = getIteratorFn(propValue);\n if (iteratorFn) {\n var iterator = iteratorFn.call(propValue);\n var step;\n if (iteratorFn !== propValue.entries) {\n while (!(step = iterator.next()).done) {\n if (!isNode(step.value)) {\n return false;\n }\n }\n } else {\n // Iterator will provide entry [k,v] tuples rather than values.\n while (!(step = iterator.next()).done) {\n var entry = step.value;\n if (entry) {\n if (!isNode(entry[1])) {\n return false;\n }\n }\n }\n }\n } else {\n return false;\n }\n\n return true;\n default:\n return false;\n }\n }\n\n function isSymbol(propType, propValue) {\n // Native Symbol.\n if (propType === 'symbol') {\n return true;\n }\n\n // falsy value can't be a Symbol\n if (!propValue) {\n return false;\n }\n\n // 19.4.3.5 Symbol.prototype[@@toStringTag] === 'Symbol'\n if (propValue['@@toStringTag'] === 'Symbol') {\n return true;\n }\n\n // Fallback for non-spec compliant Symbols which are polyfilled.\n if (typeof Symbol === 'function' && propValue instanceof Symbol) {\n return true;\n }\n\n return false;\n }\n\n // Equivalent of `typeof` but with special handling for array and regexp.\n function getPropType(propValue) {\n var propType = typeof propValue;\n if (Array.isArray(propValue)) {\n return 'array';\n }\n if (propValue instanceof RegExp) {\n // Old webkits (at least until Android 4.0) return 'function' rather than\n // 'object' for typeof a RegExp. We'll normalize this here so that /bla/\n // passes PropTypes.object.\n return 'object';\n }\n if (isSymbol(propType, propValue)) {\n return 'symbol';\n }\n return propType;\n }\n\n // This handles more types than `getPropType`. Only used for error messages.\n // See `createPrimitiveTypeChecker`.\n function getPreciseType(propValue) {\n if (typeof propValue === 'undefined' || propValue === null) {\n return '' + propValue;\n }\n var propType = getPropType(propValue);\n if (propType === 'object') {\n if (propValue instanceof Date) {\n return 'date';\n } else if (propValue instanceof RegExp) {\n return 'regexp';\n }\n }\n return propType;\n }\n\n // Returns a string that is postfixed to a warning about an invalid type.\n // For example, \"undefined\" or \"of type array\"\n function getPostfixForTypeWarning(value) {\n var type = getPreciseType(value);\n switch (type) {\n case 'array':\n case 'object':\n return 'an ' + type;\n case 'boolean':\n case 'date':\n case 'regexp':\n return 'a ' + type;\n default:\n return type;\n }\n }\n\n // Returns class name of the object, if any.\n function getClassName(propValue) {\n if (!propValue.constructor || !propValue.constructor.name) {\n return ANONYMOUS;\n }\n return propValue.constructor.name;\n }\n\n ReactPropTypes.checkPropTypes = checkPropTypes;\n ReactPropTypes.resetWarningCache = checkPropTypes.resetWarningCache;\n ReactPropTypes.PropTypes = ReactPropTypes;\n\n return ReactPropTypes;\n};\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar ReactPropTypesSecret = require('./lib/ReactPropTypesSecret');\n\nfunction emptyFunction() {}\nfunction emptyFunctionWithReset() {}\nemptyFunctionWithReset.resetWarningCache = emptyFunction;\n\nmodule.exports = function() {\n function shim(props, propName, componentName, location, propFullName, secret) {\n if (secret === ReactPropTypesSecret) {\n // It is still safe when called from React.\n return;\n }\n var err = new Error(\n 'Calling PropTypes validators directly is not supported by the `prop-types` package. ' +\n 'Use PropTypes.checkPropTypes() to call them. ' +\n 'Read more at http://fb.me/use-check-prop-types'\n );\n err.name = 'Invariant Violation';\n throw err;\n };\n shim.isRequired = shim;\n function getShim() {\n return shim;\n };\n // Important!\n // Keep this list in sync with production version in `./factoryWithTypeCheckers.js`.\n var ReactPropTypes = {\n array: shim,\n bigint: shim,\n bool: shim,\n func: shim,\n number: shim,\n object: shim,\n string: shim,\n symbol: shim,\n\n any: shim,\n arrayOf: getShim,\n element: shim,\n elementType: shim,\n instanceOf: getShim,\n node: shim,\n objectOf: getShim,\n oneOf: getShim,\n oneOfType: getShim,\n shape: getShim,\n exact: getShim,\n\n checkPropTypes: emptyFunctionWithReset,\n resetWarningCache: emptyFunction\n };\n\n ReactPropTypes.PropTypes = ReactPropTypes;\n\n return ReactPropTypes;\n};\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\nif (process.env.NODE_ENV !== 'production') {\n var ReactIs = require('react-is');\n\n // By explicitly using `prop-types` you are opting into new development behavior.\n // http://fb.me/prop-types-in-prod\n var throwOnDirectAccess = true;\n module.exports = require('./factoryWithTypeCheckers')(ReactIs.isElement, throwOnDirectAccess);\n} else {\n // By explicitly using `prop-types` you are opting into new production behavior.\n // http://fb.me/prop-types-in-prod\n module.exports = require('./factoryWithThrowingShims')();\n}\n","import PropTypes from 'prop-types';\nimport chainPropTypes from '../chainPropTypes';\nfunction isClassComponent(elementType) {\n // elementType.prototype?.isReactComponent\n const {\n prototype = {}\n } = elementType;\n return Boolean(prototype.isReactComponent);\n}\nfunction acceptingRef(props, propName, componentName, location, propFullName) {\n const element = props[propName];\n const safePropName = propFullName || propName;\n if (element == null ||\n // When server-side rendering React doesn't warn either.\n // This is not an accurate check for SSR.\n // This is only in place for Emotion compat.\n // TODO: Revisit once https://github.com/facebook/react/issues/20047 is resolved.\n typeof window === 'undefined') {\n return null;\n }\n let warningHint;\n const elementType = element.type;\n /**\n * Blacklisting instead of whitelisting\n *\n * Blacklisting will miss some components, such as React.Fragment. Those will at least\n * trigger a warning in React.\n * We can't whitelist because there is no safe way to detect React.forwardRef\n * or class components. \"Safe\" means there's no public API.\n *\n */\n if (typeof elementType === 'function' && !isClassComponent(elementType)) {\n warningHint = 'Did you accidentally use a plain function component for an element instead?';\n }\n if (warningHint !== undefined) {\n return new Error(`Invalid ${location} \\`${safePropName}\\` supplied to \\`${componentName}\\`. ` + `Expected an element that can hold a ref. ${warningHint} ` + 'For more information see https://mui.com/r/caveat-with-refs-guide');\n }\n return null;\n}\nconst elementAcceptingRef = chainPropTypes(PropTypes.element, acceptingRef);\nelementAcceptingRef.isRequired = chainPropTypes(PropTypes.element.isRequired, acceptingRef);\nexport default elementAcceptingRef;","import _extends from \"@babel/runtime/helpers/esm/extends\";\n// This module is based on https://github.com/airbnb/prop-types-exact repository.\n// However, in order to reduce the number of dependencies and to remove some extra safe checks\n// the module was forked.\n\nconst specialProperty = 'exact-prop: \\u200b';\nexport default function exactProp(propTypes) {\n if (process.env.NODE_ENV === 'production') {\n return propTypes;\n }\n return _extends({}, propTypes, {\n [specialProperty]: props => {\n const unsupportedProps = Object.keys(props).filter(prop => !propTypes.hasOwnProperty(prop));\n if (unsupportedProps.length > 0) {\n return new Error(`The following props are not supported: ${unsupportedProps.map(prop => `\\`${prop}\\``).join(', ')}. Please remove them.`);\n }\n return null;\n }\n });\n}","/**\n * WARNING: Don't import this directly.\n * Use `MuiError` from `@mui/internal-babel-macros/MuiError.macro` instead.\n * @param {number} code\n */\nexport default function formatMuiErrorMessage(code) {\n // Apply babel-plugin-transform-template-literals in loose mode\n // loose mode is safe if we're concatenating primitives\n // see https://babeljs.io/docs/en/babel-plugin-transform-template-literals#loose\n /* eslint-disable prefer-template */\n let url = 'https://mui.com/production-error/?code=' + code;\n for (let i = 1; i < arguments.length; i += 1) {\n // rest params over-transpile for this case\n // eslint-disable-next-line prefer-rest-params\n url += '&args[]=' + encodeURIComponent(arguments[i]);\n }\n return 'Minified MUI error #' + code + '; visit ' + url + ' for the full message.';\n /* eslint-enable prefer-template */\n}","/**\n * @license React\n * react-is.production.min.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n'use strict';var b=Symbol.for(\"react.element\"),c=Symbol.for(\"react.portal\"),d=Symbol.for(\"react.fragment\"),e=Symbol.for(\"react.strict_mode\"),f=Symbol.for(\"react.profiler\"),g=Symbol.for(\"react.provider\"),h=Symbol.for(\"react.context\"),k=Symbol.for(\"react.server_context\"),l=Symbol.for(\"react.forward_ref\"),m=Symbol.for(\"react.suspense\"),n=Symbol.for(\"react.suspense_list\"),p=Symbol.for(\"react.memo\"),q=Symbol.for(\"react.lazy\"),t=Symbol.for(\"react.offscreen\"),u;u=Symbol.for(\"react.module.reference\");\nfunction v(a){if(\"object\"===typeof a&&null!==a){var r=a.$$typeof;switch(r){case b:switch(a=a.type,a){case d:case f:case e:case m:case n:return a;default:switch(a=a&&a.$$typeof,a){case k:case h:case l:case q:case p:case g:return a;default:return r}}case c:return r}}}exports.ContextConsumer=h;exports.ContextProvider=g;exports.Element=b;exports.ForwardRef=l;exports.Fragment=d;exports.Lazy=q;exports.Memo=p;exports.Portal=c;exports.Profiler=f;exports.StrictMode=e;exports.Suspense=m;\nexports.SuspenseList=n;exports.isAsyncMode=function(){return!1};exports.isConcurrentMode=function(){return!1};exports.isContextConsumer=function(a){return v(a)===h};exports.isContextProvider=function(a){return v(a)===g};exports.isElement=function(a){return\"object\"===typeof a&&null!==a&&a.$$typeof===b};exports.isForwardRef=function(a){return v(a)===l};exports.isFragment=function(a){return v(a)===d};exports.isLazy=function(a){return v(a)===q};exports.isMemo=function(a){return v(a)===p};\nexports.isPortal=function(a){return v(a)===c};exports.isProfiler=function(a){return v(a)===f};exports.isStrictMode=function(a){return v(a)===e};exports.isSuspense=function(a){return v(a)===m};exports.isSuspenseList=function(a){return v(a)===n};\nexports.isValidElementType=function(a){return\"string\"===typeof a||\"function\"===typeof a||a===d||a===f||a===e||a===m||a===n||a===t||\"object\"===typeof a&&null!==a&&(a.$$typeof===q||a.$$typeof===p||a.$$typeof===g||a.$$typeof===h||a.$$typeof===l||a.$$typeof===u||void 0!==a.getModuleId)?!0:!1};exports.typeOf=v;\n","/**\n * @license React\n * react-is.development.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nif (process.env.NODE_ENV !== \"production\") {\n (function() {\n'use strict';\n\n// ATTENTION\n// When adding new symbols to this file,\n// Please consider also adding to 'react-devtools-shared/src/backend/ReactSymbols'\n// The Symbol used to tag the ReactElement-like types.\nvar REACT_ELEMENT_TYPE = Symbol.for('react.element');\nvar REACT_PORTAL_TYPE = Symbol.for('react.portal');\nvar REACT_FRAGMENT_TYPE = Symbol.for('react.fragment');\nvar REACT_STRICT_MODE_TYPE = Symbol.for('react.strict_mode');\nvar REACT_PROFILER_TYPE = Symbol.for('react.profiler');\nvar REACT_PROVIDER_TYPE = Symbol.for('react.provider');\nvar REACT_CONTEXT_TYPE = Symbol.for('react.context');\nvar REACT_SERVER_CONTEXT_TYPE = Symbol.for('react.server_context');\nvar REACT_FORWARD_REF_TYPE = Symbol.for('react.forward_ref');\nvar REACT_SUSPENSE_TYPE = Symbol.for('react.suspense');\nvar REACT_SUSPENSE_LIST_TYPE = Symbol.for('react.suspense_list');\nvar REACT_MEMO_TYPE = Symbol.for('react.memo');\nvar REACT_LAZY_TYPE = Symbol.for('react.lazy');\nvar REACT_OFFSCREEN_TYPE = Symbol.for('react.offscreen');\n\n// -----------------------------------------------------------------------------\n\nvar enableScopeAPI = false; // Experimental Create Event Handle API.\nvar enableCacheElement = false;\nvar enableTransitionTracing = false; // No known bugs, but needs performance testing\n\nvar enableLegacyHidden = false; // Enables unstable_avoidThisFallback feature in Fiber\n// stuff. Intended to enable React core members to more easily debug scheduling\n// issues in DEV builds.\n\nvar enableDebugTracing = false; // Track which Fiber(s) schedule render work.\n\nvar REACT_MODULE_REFERENCE;\n\n{\n REACT_MODULE_REFERENCE = Symbol.for('react.module.reference');\n}\n\nfunction isValidElementType(type) {\n if (typeof type === 'string' || typeof type === 'function') {\n return true;\n } // Note: typeof might be other than 'symbol' or 'number' (e.g. if it's a polyfill).\n\n\n if (type === REACT_FRAGMENT_TYPE || type === REACT_PROFILER_TYPE || enableDebugTracing || type === REACT_STRICT_MODE_TYPE || type === REACT_SUSPENSE_TYPE || type === REACT_SUSPENSE_LIST_TYPE || enableLegacyHidden || type === REACT_OFFSCREEN_TYPE || enableScopeAPI || enableCacheElement || enableTransitionTracing ) {\n return true;\n }\n\n if (typeof type === 'object' && type !== null) {\n if (type.$$typeof === REACT_LAZY_TYPE || type.$$typeof === REACT_MEMO_TYPE || type.$$typeof === REACT_PROVIDER_TYPE || type.$$typeof === REACT_CONTEXT_TYPE || type.$$typeof === REACT_FORWARD_REF_TYPE || // This needs to include all possible module reference object\n // types supported by any Flight configuration anywhere since\n // we don't know which Flight build this will end up being used\n // with.\n type.$$typeof === REACT_MODULE_REFERENCE || type.getModuleId !== undefined) {\n return true;\n }\n }\n\n return false;\n}\n\nfunction typeOf(object) {\n if (typeof object === 'object' && object !== null) {\n var $$typeof = object.$$typeof;\n\n switch ($$typeof) {\n case REACT_ELEMENT_TYPE:\n var type = object.type;\n\n switch (type) {\n case REACT_FRAGMENT_TYPE:\n case REACT_PROFILER_TYPE:\n case REACT_STRICT_MODE_TYPE:\n case REACT_SUSPENSE_TYPE:\n case REACT_SUSPENSE_LIST_TYPE:\n return type;\n\n default:\n var $$typeofType = type && type.$$typeof;\n\n switch ($$typeofType) {\n case REACT_SERVER_CONTEXT_TYPE:\n case REACT_CONTEXT_TYPE:\n case REACT_FORWARD_REF_TYPE:\n case REACT_LAZY_TYPE:\n case REACT_MEMO_TYPE:\n case REACT_PROVIDER_TYPE:\n return $$typeofType;\n\n default:\n return $$typeof;\n }\n\n }\n\n case REACT_PORTAL_TYPE:\n return $$typeof;\n }\n }\n\n return undefined;\n}\nvar ContextConsumer = REACT_CONTEXT_TYPE;\nvar ContextProvider = REACT_PROVIDER_TYPE;\nvar Element = REACT_ELEMENT_TYPE;\nvar ForwardRef = REACT_FORWARD_REF_TYPE;\nvar Fragment = REACT_FRAGMENT_TYPE;\nvar Lazy = REACT_LAZY_TYPE;\nvar Memo = REACT_MEMO_TYPE;\nvar Portal = REACT_PORTAL_TYPE;\nvar Profiler = REACT_PROFILER_TYPE;\nvar StrictMode = REACT_STRICT_MODE_TYPE;\nvar Suspense = REACT_SUSPENSE_TYPE;\nvar SuspenseList = REACT_SUSPENSE_LIST_TYPE;\nvar hasWarnedAboutDeprecatedIsAsyncMode = false;\nvar hasWarnedAboutDeprecatedIsConcurrentMode = false; // AsyncMode should be deprecated\n\nfunction isAsyncMode(object) {\n {\n if (!hasWarnedAboutDeprecatedIsAsyncMode) {\n hasWarnedAboutDeprecatedIsAsyncMode = true; // Using console['warn'] to evade Babel and ESLint\n\n console['warn']('The ReactIs.isAsyncMode() alias has been deprecated, ' + 'and will be removed in React 18+.');\n }\n }\n\n return false;\n}\nfunction isConcurrentMode(object) {\n {\n if (!hasWarnedAboutDeprecatedIsConcurrentMode) {\n hasWarnedAboutDeprecatedIsConcurrentMode = true; // Using console['warn'] to evade Babel and ESLint\n\n console['warn']('The ReactIs.isConcurrentMode() alias has been deprecated, ' + 'and will be removed in React 18+.');\n }\n }\n\n return false;\n}\nfunction isContextConsumer(object) {\n return typeOf(object) === REACT_CONTEXT_TYPE;\n}\nfunction isContextProvider(object) {\n return typeOf(object) === REACT_PROVIDER_TYPE;\n}\nfunction isElement(object) {\n return typeof object === 'object' && object !== null && object.$$typeof === REACT_ELEMENT_TYPE;\n}\nfunction isForwardRef(object) {\n return typeOf(object) === REACT_FORWARD_REF_TYPE;\n}\nfunction isFragment(object) {\n return typeOf(object) === REACT_FRAGMENT_TYPE;\n}\nfunction isLazy(object) {\n return typeOf(object) === REACT_LAZY_TYPE;\n}\nfunction isMemo(object) {\n return typeOf(object) === REACT_MEMO_TYPE;\n}\nfunction isPortal(object) {\n return typeOf(object) === REACT_PORTAL_TYPE;\n}\nfunction isProfiler(object) {\n return typeOf(object) === REACT_PROFILER_TYPE;\n}\nfunction isStrictMode(object) {\n return typeOf(object) === REACT_STRICT_MODE_TYPE;\n}\nfunction isSuspense(object) {\n return typeOf(object) === REACT_SUSPENSE_TYPE;\n}\nfunction isSuspenseList(object) {\n return typeOf(object) === REACT_SUSPENSE_LIST_TYPE;\n}\n\nexports.ContextConsumer = ContextConsumer;\nexports.ContextProvider = ContextProvider;\nexports.Element = Element;\nexports.ForwardRef = ForwardRef;\nexports.Fragment = Fragment;\nexports.Lazy = Lazy;\nexports.Memo = Memo;\nexports.Portal = Portal;\nexports.Profiler = Profiler;\nexports.StrictMode = StrictMode;\nexports.Suspense = Suspense;\nexports.SuspenseList = SuspenseList;\nexports.isAsyncMode = isAsyncMode;\nexports.isConcurrentMode = isConcurrentMode;\nexports.isContextConsumer = isContextConsumer;\nexports.isContextProvider = isContextProvider;\nexports.isElement = isElement;\nexports.isForwardRef = isForwardRef;\nexports.isFragment = isFragment;\nexports.isLazy = isLazy;\nexports.isMemo = isMemo;\nexports.isPortal = isPortal;\nexports.isProfiler = isProfiler;\nexports.isStrictMode = isStrictMode;\nexports.isSuspense = isSuspense;\nexports.isSuspenseList = isSuspenseList;\nexports.isValidElementType = isValidElementType;\nexports.typeOf = typeOf;\n })();\n}\n","'use strict';\n\nif (process.env.NODE_ENV === 'production') {\n module.exports = require('./cjs/react-is.production.min.js');\n} else {\n module.exports = require('./cjs/react-is.development.js');\n}\n","import { ForwardRef, Memo } from 'react-is';\n\n// Simplified polyfill for IE11 support\n// https://github.com/JamesMGreene/Function.name/blob/58b314d4a983110c3682f1228f845d39ccca1817/Function.name.js#L3\nconst fnNameMatchRegex = /^\\s*function(?:\\s|\\s*\\/\\*.*\\*\\/\\s*)+([^(\\s/]*)\\s*/;\nexport function getFunctionName(fn) {\n const match = `${fn}`.match(fnNameMatchRegex);\n const name = match && match[1];\n return name || '';\n}\nfunction getFunctionComponentName(Component, fallback = '') {\n return Component.displayName || Component.name || getFunctionName(Component) || fallback;\n}\nfunction getWrappedName(outerType, innerType, wrapperName) {\n const functionName = getFunctionComponentName(innerType);\n return outerType.displayName || (functionName !== '' ? `${wrapperName}(${functionName})` : wrapperName);\n}\n\n/**\n * cherry-pick from\n * https://github.com/facebook/react/blob/769b1f270e1251d9dbdce0fcbd9e92e502d059b8/packages/shared/getComponentName.js\n * originally forked from recompose/getDisplayName with added IE11 support\n */\nexport default function getDisplayName(Component) {\n if (Component == null) {\n return undefined;\n }\n if (typeof Component === 'string') {\n return Component;\n }\n if (typeof Component === 'function') {\n return getFunctionComponentName(Component, 'Component');\n }\n\n // TypeScript can't have components as objects but they exist in the form of `memo` or `Suspense`\n if (typeof Component === 'object') {\n switch (Component.$$typeof) {\n case ForwardRef:\n return getWrappedName(Component, Component.render, 'ForwardRef');\n case Memo:\n return getWrappedName(Component, Component.type, 'memo');\n default:\n return undefined;\n }\n }\n return undefined;\n}","export default function HTMLElementType(props, propName, componentName, location, propFullName) {\n if (process.env.NODE_ENV === 'production') {\n return null;\n }\n const propValue = props[propName];\n const safePropName = propFullName || propName;\n if (propValue == null) {\n return null;\n }\n if (propValue && propValue.nodeType !== 1) {\n return new Error(`Invalid ${location} \\`${safePropName}\\` supplied to \\`${componentName}\\`. ` + `Expected an HTMLElement.`);\n }\n return null;\n}","import PropTypes from 'prop-types';\nconst refType = PropTypes.oneOfType([PropTypes.func, PropTypes.object]);\nexport default refType;","import _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\n// It should to be noted that this function isn't equivalent to `text-transform: capitalize`.\n//\n// A strict capitalization should uppercase the first letter of each word in the sentence.\n// We only handle the first word.\nexport default function capitalize(string) {\n if (typeof string !== 'string') {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: \\`capitalize(string)\\` expects a string argument.` : _formatMuiErrorMessage(7));\n }\n return string.charAt(0).toUpperCase() + string.slice(1);\n}","/**\n * Safe chained function.\n *\n * Will only create a new function if needed,\n * otherwise will pass back existing functions or null.\n */\nexport default function createChainedFunction(...funcs) {\n return funcs.reduce((acc, func) => {\n if (func == null) {\n return acc;\n }\n return function chainedFunction(...args) {\n acc.apply(this, args);\n func.apply(this, args);\n };\n }, () => {});\n}","// Corresponds to 10 frames at 60 Hz.\n// A few bytes payload overhead when lodash/debounce is ~3 kB and debounce ~300 B.\nexport default function debounce(func, wait = 166) {\n let timeout;\n function debounced(...args) {\n const later = () => {\n // @ts-ignore\n func.apply(this, args);\n };\n clearTimeout(timeout);\n timeout = setTimeout(later, wait);\n }\n debounced.clear = () => {\n clearTimeout(timeout);\n };\n return debounced;\n}","export default function deprecatedPropType(validator, reason) {\n if (process.env.NODE_ENV === 'production') {\n return () => null;\n }\n return (props, propName, componentName, location, propFullName) => {\n const componentNameSafe = componentName || '<>';\n const propFullNameSafe = propFullName || propName;\n if (typeof props[propName] !== 'undefined') {\n return new Error(`The ${location} \\`${propFullNameSafe}\\` of ` + `\\`${componentNameSafe}\\` is deprecated. ${reason}`);\n }\n return null;\n };\n}","import * as React from 'react';\nexport default function isMuiElement(element, muiNames) {\n var _muiName, _element$type;\n return /*#__PURE__*/React.isValidElement(element) && muiNames.indexOf( // For server components `muiName` is avaialble in element.type._payload.value.muiName\n // relevant info - https://github.com/facebook/react/blob/2807d781a08db8e9873687fccc25c0f12b4fb3d4/packages/react/src/ReactLazy.js#L45\n // eslint-disable-next-line no-underscore-dangle\n (_muiName = element.type.muiName) != null ? _muiName : (_element$type = element.type) == null || (_element$type = _element$type._payload) == null || (_element$type = _element$type.value) == null ? void 0 : _element$type.muiName) !== -1;\n}","export default function ownerDocument(node) {\n return node && node.ownerDocument || document;\n}","import ownerDocument from '../ownerDocument';\nexport default function ownerWindow(node) {\n const doc = ownerDocument(node);\n return doc.defaultView || window;\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nexport default function requirePropFactory(componentNameInError, Component) {\n if (process.env.NODE_ENV === 'production') {\n return () => null;\n }\n\n // eslint-disable-next-line react/forbid-foreign-prop-types\n const prevPropTypes = Component ? _extends({}, Component.propTypes) : null;\n const requireProp = requiredProp => (props, propName, componentName, location, propFullName, ...args) => {\n const propFullNameSafe = propFullName || propName;\n const defaultTypeChecker = prevPropTypes == null ? void 0 : prevPropTypes[propFullNameSafe];\n if (defaultTypeChecker) {\n const typeCheckerResult = defaultTypeChecker(props, propName, componentName, location, propFullName, ...args);\n if (typeCheckerResult) {\n return typeCheckerResult;\n }\n }\n if (typeof props[propName] !== 'undefined' && !props[requiredProp]) {\n return new Error(`The prop \\`${propFullNameSafe}\\` of ` + `\\`${componentNameInError}\\` can only be used together with the \\`${requiredProp}\\` prop.`);\n }\n return null;\n };\n return requireProp;\n}","/**\n * TODO v5: consider making it private\n *\n * passes {value} to {ref}\n *\n * WARNING: Be sure to only call this inside a callback that is passed as a ref.\n * Otherwise, make sure to cleanup the previous {ref} if it changes. See\n * https://github.com/mui/material-ui/issues/13539\n *\n * Useful if you want to expose the ref of an inner component to the public API\n * while still using it inside the component.\n * @param ref A ref callback or ref object. If anything falsy, this is a no-op.\n */\nexport default function setRef(ref, value) {\n if (typeof ref === 'function') {\n ref(value);\n } else if (ref) {\n ref.current = value;\n }\n}","'use client';\n\nimport * as React from 'react';\n\n/**\n * A version of `React.useLayoutEffect` that does not show a warning when server-side rendering.\n * This is useful for effects that are only needed for client-side rendering but not for SSR.\n *\n * Before you use this hook, make sure to read https://gist.github.com/gaearon/e7d97cdf38a2907924ea12e4ebdf3c85\n * and confirm it doesn't apply to your use-case.\n */\nconst useEnhancedEffect = typeof window !== 'undefined' ? React.useLayoutEffect : React.useEffect;\nexport default useEnhancedEffect;","'use client';\n\nimport * as React from 'react';\nlet globalId = 0;\nfunction useGlobalId(idOverride) {\n const [defaultId, setDefaultId] = React.useState(idOverride);\n const id = idOverride || defaultId;\n React.useEffect(() => {\n if (defaultId == null) {\n // Fallback to this default id when possible.\n // Use the incrementing value for client-side rendering only.\n // We can't use it server-side.\n // If you want to use random values please consider the Birthday Problem: https://en.wikipedia.org/wiki/Birthday_problem\n globalId += 1;\n setDefaultId(`mui-${globalId}`);\n }\n }, [defaultId]);\n return id;\n}\n\n// downstream bundlers may remove unnecessary concatenation, but won't remove toString call -- Workaround for https://github.com/webpack/webpack/issues/14814\nconst maybeReactUseId = React['useId'.toString()];\n/**\n *\n * @example
    \n * @param idOverride\n * @returns {string}\n */\nexport default function useId(idOverride) {\n if (maybeReactUseId !== undefined) {\n const reactId = maybeReactUseId();\n return idOverride != null ? idOverride : reactId;\n }\n // eslint-disable-next-line react-hooks/rules-of-hooks -- `React.useId` is invariant at runtime.\n return useGlobalId(idOverride);\n}","export default function unsupportedProp(props, propName, componentName, location, propFullName) {\n if (process.env.NODE_ENV === 'production') {\n return null;\n }\n const propFullNameSafe = propFullName || propName;\n if (typeof props[propName] !== 'undefined') {\n return new Error(`The prop \\`${propFullNameSafe}\\` is not supported. Please remove it.`);\n }\n return null;\n}","'use client';\n\n/* eslint-disable react-hooks/rules-of-hooks, react-hooks/exhaustive-deps */\nimport * as React from 'react';\nexport default function useControlled({\n controlled,\n default: defaultProp,\n name,\n state = 'value'\n}) {\n // isControlled is ignored in the hook dependency lists as it should never change.\n const {\n current: isControlled\n } = React.useRef(controlled !== undefined);\n const [valueState, setValue] = React.useState(defaultProp);\n const value = isControlled ? controlled : valueState;\n if (process.env.NODE_ENV !== 'production') {\n React.useEffect(() => {\n if (isControlled !== (controlled !== undefined)) {\n console.error([`MUI: A component is changing the ${isControlled ? '' : 'un'}controlled ${state} state of ${name} to be ${isControlled ? 'un' : ''}controlled.`, 'Elements should not switch from uncontrolled to controlled (or vice versa).', `Decide between using a controlled or uncontrolled ${name} ` + 'element for the lifetime of the component.', \"The nature of the state is determined during the first render. It's considered controlled if the value is not `undefined`.\", 'More info: https://fb.me/react-controlled-components'].join('\\n'));\n }\n }, [state, name, controlled]);\n const {\n current: defaultValue\n } = React.useRef(defaultProp);\n React.useEffect(() => {\n if (!isControlled && defaultValue !== defaultProp) {\n console.error([`MUI: A component is changing the default ${state} state of an uncontrolled ${name} after being initialized. ` + `To suppress this warning opt to use a controlled ${name}.`].join('\\n'));\n }\n }, [JSON.stringify(defaultProp)]);\n }\n const setValueIfUncontrolled = React.useCallback(newValue => {\n if (!isControlled) {\n setValue(newValue);\n }\n }, []);\n return [value, setValueIfUncontrolled];\n}","'use client';\n\nimport * as React from 'react';\nimport useEnhancedEffect from '../useEnhancedEffect';\n\n/**\n * Inspired by https://github.com/facebook/react/issues/14099#issuecomment-440013892\n * See RFC in https://github.com/reactjs/rfcs/pull/220\n */\n\nfunction useEventCallback(fn) {\n const ref = React.useRef(fn);\n useEnhancedEffect(() => {\n ref.current = fn;\n });\n return React.useRef((...args) =>\n // @ts-expect-error hide `this`\n (0, ref.current)(...args)).current;\n}\nexport default useEventCallback;","'use client';\n\nimport * as React from 'react';\nimport setRef from '../setRef';\nexport default function useForkRef(...refs) {\n /**\n * This will create a new function if the refs passed to this hook change and are all defined.\n * This means react will call the old forkRef with `null` and the new forkRef\n * with the ref. Cleanup naturally emerges from this behavior.\n */\n return React.useMemo(() => {\n if (refs.every(ref => ref == null)) {\n return null;\n }\n return instance => {\n refs.forEach(ref => {\n setRef(ref, instance);\n });\n };\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, refs);\n}","'use client';\n\nimport * as React from 'react';\nconst UNINITIALIZED = {};\n\n/**\n * A React.useRef() that is initialized lazily with a function. Note that it accepts an optional\n * initialization argument, so the initialization function doesn't need to be an inline closure.\n *\n * @usage\n * const ref = useLazyRef(sortColumns, columns)\n */\nexport default function useLazyRef(init, initArg) {\n const ref = React.useRef(UNINITIALIZED);\n if (ref.current === UNINITIALIZED) {\n ref.current = init(initArg);\n }\n return ref;\n}","'use client';\n\nimport * as React from 'react';\nconst EMPTY = [];\n\n/**\n * A React.useEffect equivalent that runs once, when the component is mounted.\n */\nexport default function useOnMount(fn) {\n /* eslint-disable react-hooks/exhaustive-deps */\n React.useEffect(fn, EMPTY);\n /* eslint-enable react-hooks/exhaustive-deps */\n}","'use client';\n\nimport useLazyRef from '../useLazyRef/useLazyRef';\nimport useOnMount from '../useOnMount/useOnMount';\nexport class Timeout {\n constructor() {\n this.currentId = null;\n this.clear = () => {\n if (this.currentId !== null) {\n clearTimeout(this.currentId);\n this.currentId = null;\n }\n };\n this.disposeEffect = () => {\n return this.clear;\n };\n }\n static create() {\n return new Timeout();\n }\n /**\n * Executes `fn` after `delay`, clearing any previously scheduled call.\n */\n start(delay, fn) {\n this.clear();\n this.currentId = setTimeout(() => {\n this.currentId = null;\n fn();\n }, delay);\n }\n}\nexport default function useTimeout() {\n const timeout = useLazyRef(Timeout.create).current;\n useOnMount(timeout.disposeEffect);\n return timeout;\n}","'use client';\n\n// based on https://github.com/WICG/focus-visible/blob/v4.1.5/src/focus-visible.js\nimport * as React from 'react';\nimport { Timeout } from '../useTimeout/useTimeout';\nlet hadKeyboardEvent = true;\nlet hadFocusVisibleRecently = false;\nconst hadFocusVisibleRecentlyTimeout = new Timeout();\nconst inputTypesWhitelist = {\n text: true,\n search: true,\n url: true,\n tel: true,\n email: true,\n password: true,\n number: true,\n date: true,\n month: true,\n week: true,\n time: true,\n datetime: true,\n 'datetime-local': true\n};\n\n/**\n * Computes whether the given element should automatically trigger the\n * `focus-visible` class being added, i.e. whether it should always match\n * `:focus-visible` when focused.\n * @param {Element} node\n * @returns {boolean}\n */\nfunction focusTriggersKeyboardModality(node) {\n const {\n type,\n tagName\n } = node;\n if (tagName === 'INPUT' && inputTypesWhitelist[type] && !node.readOnly) {\n return true;\n }\n if (tagName === 'TEXTAREA' && !node.readOnly) {\n return true;\n }\n if (node.isContentEditable) {\n return true;\n }\n return false;\n}\n\n/**\n * Keep track of our keyboard modality state with `hadKeyboardEvent`.\n * If the most recent user interaction was via the keyboard;\n * and the key press did not include a meta, alt/option, or control key;\n * then the modality is keyboard. Otherwise, the modality is not keyboard.\n * @param {KeyboardEvent} event\n */\nfunction handleKeyDown(event) {\n if (event.metaKey || event.altKey || event.ctrlKey) {\n return;\n }\n hadKeyboardEvent = true;\n}\n\n/**\n * If at any point a user clicks with a pointing device, ensure that we change\n * the modality away from keyboard.\n * This avoids the situation where a user presses a key on an already focused\n * element, and then clicks on a different element, focusing it with a\n * pointing device, while we still think we're in keyboard modality.\n */\nfunction handlePointerDown() {\n hadKeyboardEvent = false;\n}\nfunction handleVisibilityChange() {\n if (this.visibilityState === 'hidden') {\n // If the tab becomes active again, the browser will handle calling focus\n // on the element (Safari actually calls it twice).\n // If this tab change caused a blur on an element with focus-visible,\n // re-apply the class when the user switches back to the tab.\n if (hadFocusVisibleRecently) {\n hadKeyboardEvent = true;\n }\n }\n}\nfunction prepare(doc) {\n doc.addEventListener('keydown', handleKeyDown, true);\n doc.addEventListener('mousedown', handlePointerDown, true);\n doc.addEventListener('pointerdown', handlePointerDown, true);\n doc.addEventListener('touchstart', handlePointerDown, true);\n doc.addEventListener('visibilitychange', handleVisibilityChange, true);\n}\nexport function teardown(doc) {\n doc.removeEventListener('keydown', handleKeyDown, true);\n doc.removeEventListener('mousedown', handlePointerDown, true);\n doc.removeEventListener('pointerdown', handlePointerDown, true);\n doc.removeEventListener('touchstart', handlePointerDown, true);\n doc.removeEventListener('visibilitychange', handleVisibilityChange, true);\n}\nfunction isFocusVisible(event) {\n const {\n target\n } = event;\n try {\n return target.matches(':focus-visible');\n } catch (error) {\n // Browsers not implementing :focus-visible will throw a SyntaxError.\n // We use our own heuristic for those browsers.\n // Rethrow might be better if it's not the expected error but do we really\n // want to crash if focus-visible malfunctioned?\n }\n\n // No need for validFocusTarget check. The user does that by attaching it to\n // focusable events only.\n return hadKeyboardEvent || focusTriggersKeyboardModality(target);\n}\nexport default function useIsFocusVisible() {\n const ref = React.useCallback(node => {\n if (node != null) {\n prepare(node.ownerDocument);\n }\n }, []);\n const isFocusVisibleRef = React.useRef(false);\n\n /**\n * Should be called if a blur event is fired\n */\n function handleBlurVisible() {\n // checking against potential state variable does not suffice if we focus and blur synchronously.\n // React wouldn't have time to trigger a re-render so `focusVisible` would be stale.\n // Ideally we would adjust `isFocusVisible(event)` to look at `relatedTarget` for blur events.\n // This doesn't work in IE11 due to https://github.com/facebook/react/issues/3751\n // TODO: check again if React releases their internal changes to focus event handling (https://github.com/facebook/react/pull/19186).\n if (isFocusVisibleRef.current) {\n // To detect a tab/window switch, we look for a blur event followed\n // rapidly by a visibility change.\n // If we don't see a visibility change within 100ms, it's probably a\n // regular focus change.\n hadFocusVisibleRecently = true;\n hadFocusVisibleRecentlyTimeout.start(100, () => {\n hadFocusVisibleRecently = false;\n });\n isFocusVisibleRef.current = false;\n return true;\n }\n return false;\n }\n\n /**\n * Should be called if a blur event is fired\n */\n function handleFocusVisible(event) {\n if (isFocusVisible(event)) {\n isFocusVisibleRef.current = true;\n return true;\n }\n return false;\n }\n return {\n isFocusVisibleRef,\n onFocus: handleFocusVisible,\n onBlur: handleBlurVisible,\n ref\n };\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\n/**\n * Add keys, values of `defaultProps` that does not exist in `props`\n * @param {object} defaultProps\n * @param {object} props\n * @returns {object} resolved props\n */\nexport default function resolveProps(defaultProps, props) {\n const output = _extends({}, props);\n Object.keys(defaultProps).forEach(propName => {\n if (propName.toString().match(/^(components|slots)$/)) {\n output[propName] = _extends({}, defaultProps[propName], output[propName]);\n } else if (propName.toString().match(/^(componentsProps|slotProps)$/)) {\n const defaultSlotProps = defaultProps[propName] || {};\n const slotProps = props[propName];\n output[propName] = {};\n if (!slotProps || !Object.keys(slotProps)) {\n // Reduce the iteration if the slot props is empty\n output[propName] = defaultSlotProps;\n } else if (!defaultSlotProps || !Object.keys(defaultSlotProps)) {\n // Reduce the iteration if the default slot props is empty\n output[propName] = slotProps;\n } else {\n output[propName] = _extends({}, slotProps);\n Object.keys(defaultSlotProps).forEach(slotPropName => {\n output[propName][slotPropName] = resolveProps(defaultSlotProps[slotPropName], slotProps[slotPropName]);\n });\n }\n } else if (output[propName] === undefined) {\n output[propName] = defaultProps[propName];\n }\n });\n return output;\n}","export default function composeClasses(slots, getUtilityClass, classes = undefined) {\n const output = {};\n Object.keys(slots).forEach(\n // `Object.keys(slots)` can't be wider than `T` because we infer `T` from `slots`.\n // @ts-expect-error https://github.com/microsoft/TypeScript/pull/12253#issuecomment-263132208\n slot => {\n output[slot] = slots[slot].reduce((acc, key) => {\n if (key) {\n const utilityClass = getUtilityClass(key);\n if (utilityClass !== '') {\n acc.push(utilityClass);\n }\n if (classes && classes[key]) {\n acc.push(classes[key]);\n }\n }\n return acc;\n }, []).join(' ');\n });\n return output;\n}","const defaultGenerator = componentName => componentName;\nconst createClassNameGenerator = () => {\n let generate = defaultGenerator;\n return {\n configure(generator) {\n generate = generator;\n },\n generate(componentName) {\n return generate(componentName);\n },\n reset() {\n generate = defaultGenerator;\n }\n };\n};\nconst ClassNameGenerator = createClassNameGenerator();\nexport default ClassNameGenerator;","import ClassNameGenerator from '../ClassNameGenerator';\nexport const globalStateClasses = {\n active: 'active',\n checked: 'checked',\n completed: 'completed',\n disabled: 'disabled',\n error: 'error',\n expanded: 'expanded',\n focused: 'focused',\n focusVisible: 'focusVisible',\n open: 'open',\n readOnly: 'readOnly',\n required: 'required',\n selected: 'selected'\n};\nexport default function generateUtilityClass(componentName, slot, globalStatePrefix = 'Mui') {\n const globalStateClass = globalStateClasses[slot];\n return globalStateClass ? `${globalStatePrefix}-${globalStateClass}` : `${ClassNameGenerator.generate(componentName)}-${slot}`;\n}\nexport function isGlobalState(slot) {\n return globalStateClasses[slot] !== undefined;\n}","import generateUtilityClass from '../generateUtilityClass';\nexport default function generateUtilityClasses(componentName, slots, globalStatePrefix = 'Mui') {\n const result = {};\n slots.forEach(slot => {\n result[slot] = generateUtilityClass(componentName, slot, globalStatePrefix);\n });\n return result;\n}","function clamp(val, min = Number.MIN_SAFE_INTEGER, max = Number.MAX_SAFE_INTEGER) {\n return Math.max(min, Math.min(val, max));\n}\nexport default clamp;","export default function _objectWithoutPropertiesLoose(source, excluded) {\n if (source == null) return {};\n var target = {};\n var sourceKeys = Object.keys(source);\n var key, i;\n for (i = 0; i < sourceKeys.length; i++) {\n key = sourceKeys[i];\n if (excluded.indexOf(key) >= 0) continue;\n target[key] = source[key];\n }\n return target;\n}","import _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nconst _excluded = [\"values\", \"unit\", \"step\"];\n// Sorted ASC by size. That's important.\n// It can't be configured as it's used statically for propTypes.\nexport const breakpointKeys = ['xs', 'sm', 'md', 'lg', 'xl'];\nconst sortBreakpointsValues = values => {\n const breakpointsAsArray = Object.keys(values).map(key => ({\n key,\n val: values[key]\n })) || [];\n // Sort in ascending order\n breakpointsAsArray.sort((breakpoint1, breakpoint2) => breakpoint1.val - breakpoint2.val);\n return breakpointsAsArray.reduce((acc, obj) => {\n return _extends({}, acc, {\n [obj.key]: obj.val\n });\n }, {});\n};\n\n// Keep in mind that @media is inclusive by the CSS specification.\nexport default function createBreakpoints(breakpoints) {\n const {\n // The breakpoint **start** at this value.\n // For instance with the first breakpoint xs: [xs, sm).\n values = {\n xs: 0,\n // phone\n sm: 600,\n // tablet\n md: 900,\n // small laptop\n lg: 1200,\n // desktop\n xl: 1536 // large screen\n },\n unit = 'px',\n step = 5\n } = breakpoints,\n other = _objectWithoutPropertiesLoose(breakpoints, _excluded);\n const sortedValues = sortBreakpointsValues(values);\n const keys = Object.keys(sortedValues);\n function up(key) {\n const value = typeof values[key] === 'number' ? values[key] : key;\n return `@media (min-width:${value}${unit})`;\n }\n function down(key) {\n const value = typeof values[key] === 'number' ? values[key] : key;\n return `@media (max-width:${value - step / 100}${unit})`;\n }\n function between(start, end) {\n const endIndex = keys.indexOf(end);\n return `@media (min-width:${typeof values[start] === 'number' ? values[start] : start}${unit}) and ` + `(max-width:${(endIndex !== -1 && typeof values[keys[endIndex]] === 'number' ? values[keys[endIndex]] : end) - step / 100}${unit})`;\n }\n function only(key) {\n if (keys.indexOf(key) + 1 < keys.length) {\n return between(key, keys[keys.indexOf(key) + 1]);\n }\n return up(key);\n }\n function not(key) {\n // handle first and last key separately, for better readability\n const keyIndex = keys.indexOf(key);\n if (keyIndex === 0) {\n return up(keys[1]);\n }\n if (keyIndex === keys.length - 1) {\n return down(keys[keyIndex]);\n }\n return between(key, keys[keys.indexOf(key) + 1]).replace('@media', '@media not all and');\n }\n return _extends({\n keys,\n values: sortedValues,\n up,\n down,\n between,\n only,\n not,\n unit\n }, other);\n}","const shape = {\n borderRadius: 4\n};\nexport default shape;","import PropTypes from 'prop-types';\nconst responsivePropType = process.env.NODE_ENV !== 'production' ? PropTypes.oneOfType([PropTypes.number, PropTypes.string, PropTypes.object, PropTypes.array]) : {};\nexport default responsivePropType;","import deepmerge from '@mui/utils/deepmerge';\nfunction merge(acc, item) {\n if (!item) {\n return acc;\n }\n return deepmerge(acc, item, {\n clone: false // No need to clone deep, it's way faster.\n });\n}\nexport default merge;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport PropTypes from 'prop-types';\nimport deepmerge from '@mui/utils/deepmerge';\nimport merge from './merge';\n\n// The breakpoint **start** at this value.\n// For instance with the first breakpoint xs: [xs, sm[.\nexport const values = {\n xs: 0,\n // phone\n sm: 600,\n // tablet\n md: 900,\n // small laptop\n lg: 1200,\n // desktop\n xl: 1536 // large screen\n};\nconst defaultBreakpoints = {\n // Sorted ASC by size. That's important.\n // It can't be configured as it's used statically for propTypes.\n keys: ['xs', 'sm', 'md', 'lg', 'xl'],\n up: key => `@media (min-width:${values[key]}px)`\n};\nexport function handleBreakpoints(props, propValue, styleFromPropValue) {\n const theme = props.theme || {};\n if (Array.isArray(propValue)) {\n const themeBreakpoints = theme.breakpoints || defaultBreakpoints;\n return propValue.reduce((acc, item, index) => {\n acc[themeBreakpoints.up(themeBreakpoints.keys[index])] = styleFromPropValue(propValue[index]);\n return acc;\n }, {});\n }\n if (typeof propValue === 'object') {\n const themeBreakpoints = theme.breakpoints || defaultBreakpoints;\n return Object.keys(propValue).reduce((acc, breakpoint) => {\n // key is breakpoint\n if (Object.keys(themeBreakpoints.values || values).indexOf(breakpoint) !== -1) {\n const mediaKey = themeBreakpoints.up(breakpoint);\n acc[mediaKey] = styleFromPropValue(propValue[breakpoint], breakpoint);\n } else {\n const cssKey = breakpoint;\n acc[cssKey] = propValue[cssKey];\n }\n return acc;\n }, {});\n }\n const output = styleFromPropValue(propValue);\n return output;\n}\nfunction breakpoints(styleFunction) {\n // false positive\n // eslint-disable-next-line react/function-component-definition\n const newStyleFunction = props => {\n const theme = props.theme || {};\n const base = styleFunction(props);\n const themeBreakpoints = theme.breakpoints || defaultBreakpoints;\n const extended = themeBreakpoints.keys.reduce((acc, key) => {\n if (props[key]) {\n acc = acc || {};\n acc[themeBreakpoints.up(key)] = styleFunction(_extends({\n theme\n }, props[key]));\n }\n return acc;\n }, null);\n return merge(base, extended);\n };\n newStyleFunction.propTypes = process.env.NODE_ENV !== 'production' ? _extends({}, styleFunction.propTypes, {\n xs: PropTypes.object,\n sm: PropTypes.object,\n md: PropTypes.object,\n lg: PropTypes.object,\n xl: PropTypes.object\n }) : {};\n newStyleFunction.filterProps = ['xs', 'sm', 'md', 'lg', 'xl', ...styleFunction.filterProps];\n return newStyleFunction;\n}\nexport function createEmptyBreakpointObject(breakpointsInput = {}) {\n var _breakpointsInput$key;\n const breakpointsInOrder = (_breakpointsInput$key = breakpointsInput.keys) == null ? void 0 : _breakpointsInput$key.reduce((acc, key) => {\n const breakpointStyleKey = breakpointsInput.up(key);\n acc[breakpointStyleKey] = {};\n return acc;\n }, {});\n return breakpointsInOrder || {};\n}\nexport function removeUnusedBreakpoints(breakpointKeys, style) {\n return breakpointKeys.reduce((acc, key) => {\n const breakpointOutput = acc[key];\n const isBreakpointUnused = !breakpointOutput || Object.keys(breakpointOutput).length === 0;\n if (isBreakpointUnused) {\n delete acc[key];\n }\n return acc;\n }, style);\n}\nexport function mergeBreakpointsInOrder(breakpointsInput, ...styles) {\n const emptyBreakpoints = createEmptyBreakpointObject(breakpointsInput);\n const mergedOutput = [emptyBreakpoints, ...styles].reduce((prev, next) => deepmerge(prev, next), {});\n return removeUnusedBreakpoints(Object.keys(emptyBreakpoints), mergedOutput);\n}\n\n// compute base for responsive values; e.g.,\n// [1,2,3] => {xs: true, sm: true, md: true}\n// {xs: 1, sm: 2, md: 3} => {xs: true, sm: true, md: true}\nexport function computeBreakpointsBase(breakpointValues, themeBreakpoints) {\n // fixed value\n if (typeof breakpointValues !== 'object') {\n return {};\n }\n const base = {};\n const breakpointsKeys = Object.keys(themeBreakpoints);\n if (Array.isArray(breakpointValues)) {\n breakpointsKeys.forEach((breakpoint, i) => {\n if (i < breakpointValues.length) {\n base[breakpoint] = true;\n }\n });\n } else {\n breakpointsKeys.forEach(breakpoint => {\n if (breakpointValues[breakpoint] != null) {\n base[breakpoint] = true;\n }\n });\n }\n return base;\n}\nexport function resolveBreakpointValues({\n values: breakpointValues,\n breakpoints: themeBreakpoints,\n base: customBase\n}) {\n const base = customBase || computeBreakpointsBase(breakpointValues, themeBreakpoints);\n const keys = Object.keys(base);\n if (keys.length === 0) {\n return breakpointValues;\n }\n let previous;\n return keys.reduce((acc, breakpoint, i) => {\n if (Array.isArray(breakpointValues)) {\n acc[breakpoint] = breakpointValues[i] != null ? breakpointValues[i] : breakpointValues[previous];\n previous = i;\n } else if (typeof breakpointValues === 'object') {\n acc[breakpoint] = breakpointValues[breakpoint] != null ? breakpointValues[breakpoint] : breakpointValues[previous];\n previous = breakpoint;\n } else {\n acc[breakpoint] = breakpointValues;\n }\n return acc;\n }, {});\n}\nexport default breakpoints;","import capitalize from '@mui/utils/capitalize';\nimport responsivePropType from './responsivePropType';\nimport { handleBreakpoints } from './breakpoints';\nexport function getPath(obj, path, checkVars = true) {\n if (!path || typeof path !== 'string') {\n return null;\n }\n\n // Check if CSS variables are used\n if (obj && obj.vars && checkVars) {\n const val = `vars.${path}`.split('.').reduce((acc, item) => acc && acc[item] ? acc[item] : null, obj);\n if (val != null) {\n return val;\n }\n }\n return path.split('.').reduce((acc, item) => {\n if (acc && acc[item] != null) {\n return acc[item];\n }\n return null;\n }, obj);\n}\nexport function getStyleValue(themeMapping, transform, propValueFinal, userValue = propValueFinal) {\n let value;\n if (typeof themeMapping === 'function') {\n value = themeMapping(propValueFinal);\n } else if (Array.isArray(themeMapping)) {\n value = themeMapping[propValueFinal] || userValue;\n } else {\n value = getPath(themeMapping, propValueFinal) || userValue;\n }\n if (transform) {\n value = transform(value, userValue, themeMapping);\n }\n return value;\n}\nfunction style(options) {\n const {\n prop,\n cssProperty = options.prop,\n themeKey,\n transform\n } = options;\n\n // false positive\n // eslint-disable-next-line react/function-component-definition\n const fn = props => {\n if (props[prop] == null) {\n return null;\n }\n const propValue = props[prop];\n const theme = props.theme;\n const themeMapping = getPath(theme, themeKey) || {};\n const styleFromPropValue = propValueFinal => {\n let value = getStyleValue(themeMapping, transform, propValueFinal);\n if (propValueFinal === value && typeof propValueFinal === 'string') {\n // Haven't found value\n value = getStyleValue(themeMapping, transform, `${prop}${propValueFinal === 'default' ? '' : capitalize(propValueFinal)}`, propValueFinal);\n }\n if (cssProperty === false) {\n return value;\n }\n return {\n [cssProperty]: value\n };\n };\n return handleBreakpoints(props, propValue, styleFromPropValue);\n };\n fn.propTypes = process.env.NODE_ENV !== 'production' ? {\n [prop]: responsivePropType\n } : {};\n fn.filterProps = [prop];\n return fn;\n}\nexport default style;","export default function memoize(fn) {\n const cache = {};\n return arg => {\n if (cache[arg] === undefined) {\n cache[arg] = fn(arg);\n }\n return cache[arg];\n };\n}","import responsivePropType from './responsivePropType';\nimport { handleBreakpoints } from './breakpoints';\nimport { getPath } from './style';\nimport merge from './merge';\nimport memoize from './memoize';\nconst properties = {\n m: 'margin',\n p: 'padding'\n};\nconst directions = {\n t: 'Top',\n r: 'Right',\n b: 'Bottom',\n l: 'Left',\n x: ['Left', 'Right'],\n y: ['Top', 'Bottom']\n};\nconst aliases = {\n marginX: 'mx',\n marginY: 'my',\n paddingX: 'px',\n paddingY: 'py'\n};\n\n// memoize() impact:\n// From 300,000 ops/sec\n// To 350,000 ops/sec\nconst getCssProperties = memoize(prop => {\n // It's not a shorthand notation.\n if (prop.length > 2) {\n if (aliases[prop]) {\n prop = aliases[prop];\n } else {\n return [prop];\n }\n }\n const [a, b] = prop.split('');\n const property = properties[a];\n const direction = directions[b] || '';\n return Array.isArray(direction) ? direction.map(dir => property + dir) : [property + direction];\n});\nexport const marginKeys = ['m', 'mt', 'mr', 'mb', 'ml', 'mx', 'my', 'margin', 'marginTop', 'marginRight', 'marginBottom', 'marginLeft', 'marginX', 'marginY', 'marginInline', 'marginInlineStart', 'marginInlineEnd', 'marginBlock', 'marginBlockStart', 'marginBlockEnd'];\nexport const paddingKeys = ['p', 'pt', 'pr', 'pb', 'pl', 'px', 'py', 'padding', 'paddingTop', 'paddingRight', 'paddingBottom', 'paddingLeft', 'paddingX', 'paddingY', 'paddingInline', 'paddingInlineStart', 'paddingInlineEnd', 'paddingBlock', 'paddingBlockStart', 'paddingBlockEnd'];\nconst spacingKeys = [...marginKeys, ...paddingKeys];\nexport function createUnaryUnit(theme, themeKey, defaultValue, propName) {\n var _getPath;\n const themeSpacing = (_getPath = getPath(theme, themeKey, false)) != null ? _getPath : defaultValue;\n if (typeof themeSpacing === 'number') {\n return abs => {\n if (typeof abs === 'string') {\n return abs;\n }\n if (process.env.NODE_ENV !== 'production') {\n if (typeof abs !== 'number') {\n console.error(`MUI: Expected ${propName} argument to be a number or a string, got ${abs}.`);\n }\n }\n return themeSpacing * abs;\n };\n }\n if (Array.isArray(themeSpacing)) {\n return abs => {\n if (typeof abs === 'string') {\n return abs;\n }\n if (process.env.NODE_ENV !== 'production') {\n if (!Number.isInteger(abs)) {\n console.error([`MUI: The \\`theme.${themeKey}\\` array type cannot be combined with non integer values.` + `You should either use an integer value that can be used as index, or define the \\`theme.${themeKey}\\` as a number.`].join('\\n'));\n } else if (abs > themeSpacing.length - 1) {\n console.error([`MUI: The value provided (${abs}) overflows.`, `The supported values are: ${JSON.stringify(themeSpacing)}.`, `${abs} > ${themeSpacing.length - 1}, you need to add the missing values.`].join('\\n'));\n }\n }\n return themeSpacing[abs];\n };\n }\n if (typeof themeSpacing === 'function') {\n return themeSpacing;\n }\n if (process.env.NODE_ENV !== 'production') {\n console.error([`MUI: The \\`theme.${themeKey}\\` value (${themeSpacing}) is invalid.`, 'It should be a number, an array or a function.'].join('\\n'));\n }\n return () => undefined;\n}\nexport function createUnarySpacing(theme) {\n return createUnaryUnit(theme, 'spacing', 8, 'spacing');\n}\nexport function getValue(transformer, propValue) {\n if (typeof propValue === 'string' || propValue == null) {\n return propValue;\n }\n const abs = Math.abs(propValue);\n const transformed = transformer(abs);\n if (propValue >= 0) {\n return transformed;\n }\n if (typeof transformed === 'number') {\n return -transformed;\n }\n return `-${transformed}`;\n}\nexport function getStyleFromPropValue(cssProperties, transformer) {\n return propValue => cssProperties.reduce((acc, cssProperty) => {\n acc[cssProperty] = getValue(transformer, propValue);\n return acc;\n }, {});\n}\nfunction resolveCssProperty(props, keys, prop, transformer) {\n // Using a hash computation over an array iteration could be faster, but with only 28 items,\n // it's doesn't worth the bundle size.\n if (keys.indexOf(prop) === -1) {\n return null;\n }\n const cssProperties = getCssProperties(prop);\n const styleFromPropValue = getStyleFromPropValue(cssProperties, transformer);\n const propValue = props[prop];\n return handleBreakpoints(props, propValue, styleFromPropValue);\n}\nfunction style(props, keys) {\n const transformer = createUnarySpacing(props.theme);\n return Object.keys(props).map(prop => resolveCssProperty(props, keys, prop, transformer)).reduce(merge, {});\n}\nexport function margin(props) {\n return style(props, marginKeys);\n}\nmargin.propTypes = process.env.NODE_ENV !== 'production' ? marginKeys.reduce((obj, key) => {\n obj[key] = responsivePropType;\n return obj;\n}, {}) : {};\nmargin.filterProps = marginKeys;\nexport function padding(props) {\n return style(props, paddingKeys);\n}\npadding.propTypes = process.env.NODE_ENV !== 'production' ? paddingKeys.reduce((obj, key) => {\n obj[key] = responsivePropType;\n return obj;\n}, {}) : {};\npadding.filterProps = paddingKeys;\nfunction spacing(props) {\n return style(props, spacingKeys);\n}\nspacing.propTypes = process.env.NODE_ENV !== 'production' ? spacingKeys.reduce((obj, key) => {\n obj[key] = responsivePropType;\n return obj;\n}, {}) : {};\nspacing.filterProps = spacingKeys;\nexport default spacing;","import { createUnarySpacing } from '../spacing';\n\n// The different signatures imply different meaning for their arguments that can't be expressed structurally.\n// We express the difference with variable names.\n\nexport default function createSpacing(spacingInput = 8) {\n // Already transformed.\n if (spacingInput.mui) {\n return spacingInput;\n }\n\n // Material Design layouts are visually balanced. Most measurements align to an 8dp grid, which aligns both spacing and the overall layout.\n // Smaller components, such as icons, can align to a 4dp grid.\n // https://m2.material.io/design/layout/understanding-layout.html\n const transform = createUnarySpacing({\n spacing: spacingInput\n });\n const spacing = (...argsInput) => {\n if (process.env.NODE_ENV !== 'production') {\n if (!(argsInput.length <= 4)) {\n console.error(`MUI: Too many arguments provided, expected between 0 and 4, got ${argsInput.length}`);\n }\n }\n const args = argsInput.length === 0 ? [1] : argsInput;\n return args.map(argument => {\n const output = transform(argument);\n return typeof output === 'number' ? `${output}px` : output;\n }).join(' ');\n };\n spacing.mui = true;\n return spacing;\n}","import merge from './merge';\nfunction compose(...styles) {\n const handlers = styles.reduce((acc, style) => {\n style.filterProps.forEach(prop => {\n acc[prop] = style;\n });\n return acc;\n }, {});\n\n // false positive\n // eslint-disable-next-line react/function-component-definition\n const fn = props => {\n return Object.keys(props).reduce((acc, prop) => {\n if (handlers[prop]) {\n return merge(acc, handlers[prop](props));\n }\n return acc;\n }, {});\n };\n fn.propTypes = process.env.NODE_ENV !== 'production' ? styles.reduce((acc, style) => Object.assign(acc, style.propTypes), {}) : {};\n fn.filterProps = styles.reduce((acc, style) => acc.concat(style.filterProps), []);\n return fn;\n}\nexport default compose;","import responsivePropType from './responsivePropType';\nimport style from './style';\nimport compose from './compose';\nimport { createUnaryUnit, getValue } from './spacing';\nimport { handleBreakpoints } from './breakpoints';\nexport function borderTransform(value) {\n if (typeof value !== 'number') {\n return value;\n }\n return `${value}px solid`;\n}\nfunction createBorderStyle(prop, transform) {\n return style({\n prop,\n themeKey: 'borders',\n transform\n });\n}\nexport const border = createBorderStyle('border', borderTransform);\nexport const borderTop = createBorderStyle('borderTop', borderTransform);\nexport const borderRight = createBorderStyle('borderRight', borderTransform);\nexport const borderBottom = createBorderStyle('borderBottom', borderTransform);\nexport const borderLeft = createBorderStyle('borderLeft', borderTransform);\nexport const borderColor = createBorderStyle('borderColor');\nexport const borderTopColor = createBorderStyle('borderTopColor');\nexport const borderRightColor = createBorderStyle('borderRightColor');\nexport const borderBottomColor = createBorderStyle('borderBottomColor');\nexport const borderLeftColor = createBorderStyle('borderLeftColor');\nexport const outline = createBorderStyle('outline', borderTransform);\nexport const outlineColor = createBorderStyle('outlineColor');\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const borderRadius = props => {\n if (props.borderRadius !== undefined && props.borderRadius !== null) {\n const transformer = createUnaryUnit(props.theme, 'shape.borderRadius', 4, 'borderRadius');\n const styleFromPropValue = propValue => ({\n borderRadius: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.borderRadius, styleFromPropValue);\n }\n return null;\n};\nborderRadius.propTypes = process.env.NODE_ENV !== 'production' ? {\n borderRadius: responsivePropType\n} : {};\nborderRadius.filterProps = ['borderRadius'];\nconst borders = compose(border, borderTop, borderRight, borderBottom, borderLeft, borderColor, borderTopColor, borderRightColor, borderBottomColor, borderLeftColor, borderRadius, outline, outlineColor);\nexport default borders;","import style from './style';\nimport compose from './compose';\nimport { createUnaryUnit, getValue } from './spacing';\nimport { handleBreakpoints } from './breakpoints';\nimport responsivePropType from './responsivePropType';\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const gap = props => {\n if (props.gap !== undefined && props.gap !== null) {\n const transformer = createUnaryUnit(props.theme, 'spacing', 8, 'gap');\n const styleFromPropValue = propValue => ({\n gap: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.gap, styleFromPropValue);\n }\n return null;\n};\ngap.propTypes = process.env.NODE_ENV !== 'production' ? {\n gap: responsivePropType\n} : {};\ngap.filterProps = ['gap'];\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const columnGap = props => {\n if (props.columnGap !== undefined && props.columnGap !== null) {\n const transformer = createUnaryUnit(props.theme, 'spacing', 8, 'columnGap');\n const styleFromPropValue = propValue => ({\n columnGap: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.columnGap, styleFromPropValue);\n }\n return null;\n};\ncolumnGap.propTypes = process.env.NODE_ENV !== 'production' ? {\n columnGap: responsivePropType\n} : {};\ncolumnGap.filterProps = ['columnGap'];\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const rowGap = props => {\n if (props.rowGap !== undefined && props.rowGap !== null) {\n const transformer = createUnaryUnit(props.theme, 'spacing', 8, 'rowGap');\n const styleFromPropValue = propValue => ({\n rowGap: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.rowGap, styleFromPropValue);\n }\n return null;\n};\nrowGap.propTypes = process.env.NODE_ENV !== 'production' ? {\n rowGap: responsivePropType\n} : {};\nrowGap.filterProps = ['rowGap'];\nexport const gridColumn = style({\n prop: 'gridColumn'\n});\nexport const gridRow = style({\n prop: 'gridRow'\n});\nexport const gridAutoFlow = style({\n prop: 'gridAutoFlow'\n});\nexport const gridAutoColumns = style({\n prop: 'gridAutoColumns'\n});\nexport const gridAutoRows = style({\n prop: 'gridAutoRows'\n});\nexport const gridTemplateColumns = style({\n prop: 'gridTemplateColumns'\n});\nexport const gridTemplateRows = style({\n prop: 'gridTemplateRows'\n});\nexport const gridTemplateAreas = style({\n prop: 'gridTemplateAreas'\n});\nexport const gridArea = style({\n prop: 'gridArea'\n});\nconst grid = compose(gap, columnGap, rowGap, gridColumn, gridRow, gridAutoFlow, gridAutoColumns, gridAutoRows, gridTemplateColumns, gridTemplateRows, gridTemplateAreas, gridArea);\nexport default grid;","import style from './style';\nimport compose from './compose';\nexport function paletteTransform(value, userValue) {\n if (userValue === 'grey') {\n return userValue;\n }\n return value;\n}\nexport const color = style({\n prop: 'color',\n themeKey: 'palette',\n transform: paletteTransform\n});\nexport const bgcolor = style({\n prop: 'bgcolor',\n cssProperty: 'backgroundColor',\n themeKey: 'palette',\n transform: paletteTransform\n});\nexport const backgroundColor = style({\n prop: 'backgroundColor',\n themeKey: 'palette',\n transform: paletteTransform\n});\nconst palette = compose(color, bgcolor, backgroundColor);\nexport default palette;","import style from './style';\nimport compose from './compose';\nimport { handleBreakpoints, values as breakpointsValues } from './breakpoints';\nexport function sizingTransform(value) {\n return value <= 1 && value !== 0 ? `${value * 100}%` : value;\n}\nexport const width = style({\n prop: 'width',\n transform: sizingTransform\n});\nexport const maxWidth = props => {\n if (props.maxWidth !== undefined && props.maxWidth !== null) {\n const styleFromPropValue = propValue => {\n var _props$theme, _props$theme2;\n const breakpoint = ((_props$theme = props.theme) == null || (_props$theme = _props$theme.breakpoints) == null || (_props$theme = _props$theme.values) == null ? void 0 : _props$theme[propValue]) || breakpointsValues[propValue];\n if (!breakpoint) {\n return {\n maxWidth: sizingTransform(propValue)\n };\n }\n if (((_props$theme2 = props.theme) == null || (_props$theme2 = _props$theme2.breakpoints) == null ? void 0 : _props$theme2.unit) !== 'px') {\n return {\n maxWidth: `${breakpoint}${props.theme.breakpoints.unit}`\n };\n }\n return {\n maxWidth: breakpoint\n };\n };\n return handleBreakpoints(props, props.maxWidth, styleFromPropValue);\n }\n return null;\n};\nmaxWidth.filterProps = ['maxWidth'];\nexport const minWidth = style({\n prop: 'minWidth',\n transform: sizingTransform\n});\nexport const height = style({\n prop: 'height',\n transform: sizingTransform\n});\nexport const maxHeight = style({\n prop: 'maxHeight',\n transform: sizingTransform\n});\nexport const minHeight = style({\n prop: 'minHeight',\n transform: sizingTransform\n});\nexport const sizeWidth = style({\n prop: 'size',\n cssProperty: 'width',\n transform: sizingTransform\n});\nexport const sizeHeight = style({\n prop: 'size',\n cssProperty: 'height',\n transform: sizingTransform\n});\nexport const boxSizing = style({\n prop: 'boxSizing'\n});\nconst sizing = compose(width, maxWidth, minWidth, height, maxHeight, minHeight, boxSizing);\nexport default sizing;","import { padding, margin } from '../spacing';\nimport { borderRadius, borderTransform } from '../borders';\nimport { gap, rowGap, columnGap } from '../cssGrid';\nimport { paletteTransform } from '../palette';\nimport { maxWidth, sizingTransform } from '../sizing';\nconst defaultSxConfig = {\n // borders\n border: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderTop: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderRight: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderBottom: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderLeft: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderColor: {\n themeKey: 'palette'\n },\n borderTopColor: {\n themeKey: 'palette'\n },\n borderRightColor: {\n themeKey: 'palette'\n },\n borderBottomColor: {\n themeKey: 'palette'\n },\n borderLeftColor: {\n themeKey: 'palette'\n },\n outline: {\n themeKey: 'borders',\n transform: borderTransform\n },\n outlineColor: {\n themeKey: 'palette'\n },\n borderRadius: {\n themeKey: 'shape.borderRadius',\n style: borderRadius\n },\n // palette\n color: {\n themeKey: 'palette',\n transform: paletteTransform\n },\n bgcolor: {\n themeKey: 'palette',\n cssProperty: 'backgroundColor',\n transform: paletteTransform\n },\n backgroundColor: {\n themeKey: 'palette',\n transform: paletteTransform\n },\n // spacing\n p: {\n style: padding\n },\n pt: {\n style: padding\n },\n pr: {\n style: padding\n },\n pb: {\n style: padding\n },\n pl: {\n style: padding\n },\n px: {\n style: padding\n },\n py: {\n style: padding\n },\n padding: {\n style: padding\n },\n paddingTop: {\n style: padding\n },\n paddingRight: {\n style: padding\n },\n paddingBottom: {\n style: padding\n },\n paddingLeft: {\n style: padding\n },\n paddingX: {\n style: padding\n },\n paddingY: {\n style: padding\n },\n paddingInline: {\n style: padding\n },\n paddingInlineStart: {\n style: padding\n },\n paddingInlineEnd: {\n style: padding\n },\n paddingBlock: {\n style: padding\n },\n paddingBlockStart: {\n style: padding\n },\n paddingBlockEnd: {\n style: padding\n },\n m: {\n style: margin\n },\n mt: {\n style: margin\n },\n mr: {\n style: margin\n },\n mb: {\n style: margin\n },\n ml: {\n style: margin\n },\n mx: {\n style: margin\n },\n my: {\n style: margin\n },\n margin: {\n style: margin\n },\n marginTop: {\n style: margin\n },\n marginRight: {\n style: margin\n },\n marginBottom: {\n style: margin\n },\n marginLeft: {\n style: margin\n },\n marginX: {\n style: margin\n },\n marginY: {\n style: margin\n },\n marginInline: {\n style: margin\n },\n marginInlineStart: {\n style: margin\n },\n marginInlineEnd: {\n style: margin\n },\n marginBlock: {\n style: margin\n },\n marginBlockStart: {\n style: margin\n },\n marginBlockEnd: {\n style: margin\n },\n // display\n displayPrint: {\n cssProperty: false,\n transform: value => ({\n '@media print': {\n display: value\n }\n })\n },\n display: {},\n overflow: {},\n textOverflow: {},\n visibility: {},\n whiteSpace: {},\n // flexbox\n flexBasis: {},\n flexDirection: {},\n flexWrap: {},\n justifyContent: {},\n alignItems: {},\n alignContent: {},\n order: {},\n flex: {},\n flexGrow: {},\n flexShrink: {},\n alignSelf: {},\n justifyItems: {},\n justifySelf: {},\n // grid\n gap: {\n style: gap\n },\n rowGap: {\n style: rowGap\n },\n columnGap: {\n style: columnGap\n },\n gridColumn: {},\n gridRow: {},\n gridAutoFlow: {},\n gridAutoColumns: {},\n gridAutoRows: {},\n gridTemplateColumns: {},\n gridTemplateRows: {},\n gridTemplateAreas: {},\n gridArea: {},\n // positions\n position: {},\n zIndex: {\n themeKey: 'zIndex'\n },\n top: {},\n right: {},\n bottom: {},\n left: {},\n // shadows\n boxShadow: {\n themeKey: 'shadows'\n },\n // sizing\n width: {\n transform: sizingTransform\n },\n maxWidth: {\n style: maxWidth\n },\n minWidth: {\n transform: sizingTransform\n },\n height: {\n transform: sizingTransform\n },\n maxHeight: {\n transform: sizingTransform\n },\n minHeight: {\n transform: sizingTransform\n },\n boxSizing: {},\n // typography\n fontFamily: {\n themeKey: 'typography'\n },\n fontSize: {\n themeKey: 'typography'\n },\n fontStyle: {\n themeKey: 'typography'\n },\n fontWeight: {\n themeKey: 'typography'\n },\n letterSpacing: {},\n textTransform: {},\n lineHeight: {},\n textAlign: {},\n typography: {\n cssProperty: false,\n themeKey: 'typography'\n }\n};\nexport default defaultSxConfig;","import capitalize from '@mui/utils/capitalize';\nimport merge from '../merge';\nimport { getPath, getStyleValue as getValue } from '../style';\nimport { handleBreakpoints, createEmptyBreakpointObject, removeUnusedBreakpoints } from '../breakpoints';\nimport defaultSxConfig from './defaultSxConfig';\nfunction objectsHaveSameKeys(...objects) {\n const allKeys = objects.reduce((keys, object) => keys.concat(Object.keys(object)), []);\n const union = new Set(allKeys);\n return objects.every(object => union.size === Object.keys(object).length);\n}\nfunction callIfFn(maybeFn, arg) {\n return typeof maybeFn === 'function' ? maybeFn(arg) : maybeFn;\n}\n\n// eslint-disable-next-line @typescript-eslint/naming-convention\nexport function unstable_createStyleFunctionSx() {\n function getThemeValue(prop, val, theme, config) {\n const props = {\n [prop]: val,\n theme\n };\n const options = config[prop];\n if (!options) {\n return {\n [prop]: val\n };\n }\n const {\n cssProperty = prop,\n themeKey,\n transform,\n style\n } = options;\n if (val == null) {\n return null;\n }\n\n // TODO v6: remove, see https://github.com/mui/material-ui/pull/38123\n if (themeKey === 'typography' && val === 'inherit') {\n return {\n [prop]: val\n };\n }\n const themeMapping = getPath(theme, themeKey) || {};\n if (style) {\n return style(props);\n }\n const styleFromPropValue = propValueFinal => {\n let value = getValue(themeMapping, transform, propValueFinal);\n if (propValueFinal === value && typeof propValueFinal === 'string') {\n // Haven't found value\n value = getValue(themeMapping, transform, `${prop}${propValueFinal === 'default' ? '' : capitalize(propValueFinal)}`, propValueFinal);\n }\n if (cssProperty === false) {\n return value;\n }\n return {\n [cssProperty]: value\n };\n };\n return handleBreakpoints(props, val, styleFromPropValue);\n }\n function styleFunctionSx(props) {\n var _theme$unstable_sxCon;\n const {\n sx,\n theme = {}\n } = props || {};\n if (!sx) {\n return null; // Emotion & styled-components will neglect null\n }\n const config = (_theme$unstable_sxCon = theme.unstable_sxConfig) != null ? _theme$unstable_sxCon : defaultSxConfig;\n\n /*\n * Receive `sxInput` as object or callback\n * and then recursively check keys & values to create media query object styles.\n * (the result will be used in `styled`)\n */\n function traverse(sxInput) {\n let sxObject = sxInput;\n if (typeof sxInput === 'function') {\n sxObject = sxInput(theme);\n } else if (typeof sxInput !== 'object') {\n // value\n return sxInput;\n }\n if (!sxObject) {\n return null;\n }\n const emptyBreakpoints = createEmptyBreakpointObject(theme.breakpoints);\n const breakpointsKeys = Object.keys(emptyBreakpoints);\n let css = emptyBreakpoints;\n Object.keys(sxObject).forEach(styleKey => {\n const value = callIfFn(sxObject[styleKey], theme);\n if (value !== null && value !== undefined) {\n if (typeof value === 'object') {\n if (config[styleKey]) {\n css = merge(css, getThemeValue(styleKey, value, theme, config));\n } else {\n const breakpointsValues = handleBreakpoints({\n theme\n }, value, x => ({\n [styleKey]: x\n }));\n if (objectsHaveSameKeys(breakpointsValues, value)) {\n css[styleKey] = styleFunctionSx({\n sx: value,\n theme\n });\n } else {\n css = merge(css, breakpointsValues);\n }\n }\n } else {\n css = merge(css, getThemeValue(styleKey, value, theme, config));\n }\n }\n });\n return removeUnusedBreakpoints(breakpointsKeys, css);\n }\n return Array.isArray(sx) ? sx.map(traverse) : traverse(sx);\n }\n return styleFunctionSx;\n}\nconst styleFunctionSx = unstable_createStyleFunctionSx();\nstyleFunctionSx.filterProps = ['sx'];\nexport default styleFunctionSx;","/**\n * A universal utility to style components with multiple color modes. Always use it from the theme object.\n * It works with:\n * - [Basic theme](https://mui.com/material-ui/customization/dark-mode/)\n * - [CSS theme variables](https://mui.com/material-ui/experimental-api/css-theme-variables/overview/)\n * - Zero-runtime engine\n *\n * Tips: Use an array over object spread and place `theme.applyStyles()` last.\n *\n * ✅ [{ background: '#e5e5e5' }, theme.applyStyles('dark', { background: '#1c1c1c' })]\n *\n * 🚫 { background: '#e5e5e5', ...theme.applyStyles('dark', { background: '#1c1c1c' })}\n *\n * @example\n * 1. using with `styled`:\n * ```jsx\n * const Component = styled('div')(({ theme }) => [\n * { background: '#e5e5e5' },\n * theme.applyStyles('dark', {\n * background: '#1c1c1c',\n * color: '#fff',\n * }),\n * ]);\n * ```\n *\n * @example\n * 2. using with `sx` prop:\n * ```jsx\n * [\n * { background: '#e5e5e5' },\n * theme.applyStyles('dark', {\n * background: '#1c1c1c',\n * color: '#fff',\n * }),\n * ]}\n * />\n * ```\n *\n * @example\n * 3. theming a component:\n * ```jsx\n * extendTheme({\n * components: {\n * MuiButton: {\n * styleOverrides: {\n * root: ({ theme }) => [\n * { background: '#e5e5e5' },\n * theme.applyStyles('dark', {\n * background: '#1c1c1c',\n * color: '#fff',\n * }),\n * ],\n * },\n * }\n * }\n * })\n *```\n */\nexport default function applyStyles(key, styles) {\n // @ts-expect-error this is 'any' type\n const theme = this;\n if (theme.vars && typeof theme.getColorSchemeSelector === 'function') {\n // If CssVarsProvider is used as a provider,\n // returns '* :where([data-mui-color-scheme=\"light|dark\"]) &'\n const selector = theme.getColorSchemeSelector(key).replace(/(\\[[^\\]]+\\])/, '*:where($1)');\n return {\n [selector]: styles\n };\n }\n if (theme.palette.mode === key) {\n return styles;\n }\n return {};\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"breakpoints\", \"palette\", \"spacing\", \"shape\"];\nimport deepmerge from '@mui/utils/deepmerge';\nimport createBreakpoints from './createBreakpoints';\nimport shape from './shape';\nimport createSpacing from './createSpacing';\nimport styleFunctionSx from '../styleFunctionSx/styleFunctionSx';\nimport defaultSxConfig from '../styleFunctionSx/defaultSxConfig';\nimport applyStyles from './applyStyles';\nfunction createTheme(options = {}, ...args) {\n const {\n breakpoints: breakpointsInput = {},\n palette: paletteInput = {},\n spacing: spacingInput,\n shape: shapeInput = {}\n } = options,\n other = _objectWithoutPropertiesLoose(options, _excluded);\n const breakpoints = createBreakpoints(breakpointsInput);\n const spacing = createSpacing(spacingInput);\n let muiTheme = deepmerge({\n breakpoints,\n direction: 'ltr',\n components: {},\n // Inject component definitions.\n palette: _extends({\n mode: 'light'\n }, paletteInput),\n spacing,\n shape: _extends({}, shape, shapeInput)\n }, other);\n muiTheme.applyStyles = applyStyles;\n muiTheme = args.reduce((acc, argument) => deepmerge(acc, argument), muiTheme);\n muiTheme.unstable_sxConfig = _extends({}, defaultSxConfig, other == null ? void 0 : other.unstable_sxConfig);\n muiTheme.unstable_sx = function sx(props) {\n return styleFunctionSx({\n sx: props,\n theme: this\n });\n };\n return muiTheme;\n}\nexport default createTheme;","'use client';\n\nimport * as React from 'react';\nimport { ThemeContext } from '@mui/styled-engine';\nfunction isObjectEmpty(obj) {\n return Object.keys(obj).length === 0;\n}\nfunction useTheme(defaultTheme = null) {\n const contextTheme = React.useContext(ThemeContext);\n return !contextTheme || isObjectEmpty(contextTheme) ? defaultTheme : contextTheme;\n}\nexport default useTheme;","'use client';\n\nimport createTheme from './createTheme';\nimport useThemeWithoutDefault from './useThemeWithoutDefault';\nexport const systemDefaultTheme = createTheme();\nfunction useTheme(defaultTheme = systemDefaultTheme) {\n return useThemeWithoutDefault(defaultTheme);\n}\nexport default useTheme;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"ownerState\"],\n _excluded2 = [\"variants\"],\n _excluded3 = [\"name\", \"slot\", \"skipVariantsResolver\", \"skipSx\", \"overridesResolver\"];\n/* eslint-disable no-underscore-dangle */\nimport styledEngineStyled, { internal_processStyles as processStyles } from '@mui/styled-engine';\nimport { isPlainObject } from '@mui/utils/deepmerge';\nimport capitalize from '@mui/utils/capitalize';\nimport getDisplayName from '@mui/utils/getDisplayName';\nimport createTheme from './createTheme';\nimport styleFunctionSx from './styleFunctionSx';\nfunction isEmpty(obj) {\n return Object.keys(obj).length === 0;\n}\n\n// https://github.com/emotion-js/emotion/blob/26ded6109fcd8ca9875cc2ce4564fee678a3f3c5/packages/styled/src/utils.js#L40\nfunction isStringTag(tag) {\n return typeof tag === 'string' &&\n // 96 is one less than the char code\n // for \"a\" so this is checking that\n // it's a lowercase character\n tag.charCodeAt(0) > 96;\n}\n\n// Update /system/styled/#api in case if this changes\nexport function shouldForwardProp(prop) {\n return prop !== 'ownerState' && prop !== 'theme' && prop !== 'sx' && prop !== 'as';\n}\nexport const systemDefaultTheme = createTheme();\nconst lowercaseFirstLetter = string => {\n if (!string) {\n return string;\n }\n return string.charAt(0).toLowerCase() + string.slice(1);\n};\nfunction resolveTheme({\n defaultTheme,\n theme,\n themeId\n}) {\n return isEmpty(theme) ? defaultTheme : theme[themeId] || theme;\n}\nfunction defaultOverridesResolver(slot) {\n if (!slot) {\n return null;\n }\n return (props, styles) => styles[slot];\n}\nfunction processStyleArg(callableStyle, _ref) {\n let {\n ownerState\n } = _ref,\n props = _objectWithoutPropertiesLoose(_ref, _excluded);\n const resolvedStylesArg = typeof callableStyle === 'function' ? callableStyle(_extends({\n ownerState\n }, props)) : callableStyle;\n if (Array.isArray(resolvedStylesArg)) {\n return resolvedStylesArg.flatMap(resolvedStyle => processStyleArg(resolvedStyle, _extends({\n ownerState\n }, props)));\n }\n if (!!resolvedStylesArg && typeof resolvedStylesArg === 'object' && Array.isArray(resolvedStylesArg.variants)) {\n const {\n variants = []\n } = resolvedStylesArg,\n otherStyles = _objectWithoutPropertiesLoose(resolvedStylesArg, _excluded2);\n let result = otherStyles;\n variants.forEach(variant => {\n let isMatch = true;\n if (typeof variant.props === 'function') {\n isMatch = variant.props(_extends({\n ownerState\n }, props, ownerState));\n } else {\n Object.keys(variant.props).forEach(key => {\n if ((ownerState == null ? void 0 : ownerState[key]) !== variant.props[key] && props[key] !== variant.props[key]) {\n isMatch = false;\n }\n });\n }\n if (isMatch) {\n if (!Array.isArray(result)) {\n result = [result];\n }\n result.push(typeof variant.style === 'function' ? variant.style(_extends({\n ownerState\n }, props, ownerState)) : variant.style);\n }\n });\n return result;\n }\n return resolvedStylesArg;\n}\nexport default function createStyled(input = {}) {\n const {\n themeId,\n defaultTheme = systemDefaultTheme,\n rootShouldForwardProp = shouldForwardProp,\n slotShouldForwardProp = shouldForwardProp\n } = input;\n const systemSx = props => {\n return styleFunctionSx(_extends({}, props, {\n theme: resolveTheme(_extends({}, props, {\n defaultTheme,\n themeId\n }))\n }));\n };\n systemSx.__mui_systemSx = true;\n return (tag, inputOptions = {}) => {\n // Filter out the `sx` style function from the previous styled component to prevent unnecessary styles generated by the composite components.\n processStyles(tag, styles => styles.filter(style => !(style != null && style.__mui_systemSx)));\n const {\n name: componentName,\n slot: componentSlot,\n skipVariantsResolver: inputSkipVariantsResolver,\n skipSx: inputSkipSx,\n // TODO v6: remove `lowercaseFirstLetter()` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n overridesResolver = defaultOverridesResolver(lowercaseFirstLetter(componentSlot))\n } = inputOptions,\n options = _objectWithoutPropertiesLoose(inputOptions, _excluded3);\n\n // if skipVariantsResolver option is defined, take the value, otherwise, true for root and false for other slots.\n const skipVariantsResolver = inputSkipVariantsResolver !== undefined ? inputSkipVariantsResolver :\n // TODO v6: remove `Root` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n componentSlot && componentSlot !== 'Root' && componentSlot !== 'root' || false;\n const skipSx = inputSkipSx || false;\n let label;\n if (process.env.NODE_ENV !== 'production') {\n if (componentName) {\n // TODO v6: remove `lowercaseFirstLetter()` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n label = `${componentName}-${lowercaseFirstLetter(componentSlot || 'Root')}`;\n }\n }\n let shouldForwardPropOption = shouldForwardProp;\n\n // TODO v6: remove `Root` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n if (componentSlot === 'Root' || componentSlot === 'root') {\n shouldForwardPropOption = rootShouldForwardProp;\n } else if (componentSlot) {\n // any other slot specified\n shouldForwardPropOption = slotShouldForwardProp;\n } else if (isStringTag(tag)) {\n // for string (html) tag, preserve the behavior in emotion & styled-components.\n shouldForwardPropOption = undefined;\n }\n const defaultStyledResolver = styledEngineStyled(tag, _extends({\n shouldForwardProp: shouldForwardPropOption,\n label\n }, options));\n const transformStyleArg = stylesArg => {\n // On the server Emotion doesn't use React.forwardRef for creating components, so the created\n // component stays as a function. This condition makes sure that we do not interpolate functions\n // which are basically components used as a selectors.\n if (typeof stylesArg === 'function' && stylesArg.__emotion_real !== stylesArg || isPlainObject(stylesArg)) {\n return props => processStyleArg(stylesArg, _extends({}, props, {\n theme: resolveTheme({\n theme: props.theme,\n defaultTheme,\n themeId\n })\n }));\n }\n return stylesArg;\n };\n const muiStyledResolver = (styleArg, ...expressions) => {\n let transformedStyleArg = transformStyleArg(styleArg);\n const expressionsWithDefaultTheme = expressions ? expressions.map(transformStyleArg) : [];\n if (componentName && overridesResolver) {\n expressionsWithDefaultTheme.push(props => {\n const theme = resolveTheme(_extends({}, props, {\n defaultTheme,\n themeId\n }));\n if (!theme.components || !theme.components[componentName] || !theme.components[componentName].styleOverrides) {\n return null;\n }\n const styleOverrides = theme.components[componentName].styleOverrides;\n const resolvedStyleOverrides = {};\n // TODO: v7 remove iteration and use `resolveStyleArg(styleOverrides[slot])` directly\n Object.entries(styleOverrides).forEach(([slotKey, slotStyle]) => {\n resolvedStyleOverrides[slotKey] = processStyleArg(slotStyle, _extends({}, props, {\n theme\n }));\n });\n return overridesResolver(props, resolvedStyleOverrides);\n });\n }\n if (componentName && !skipVariantsResolver) {\n expressionsWithDefaultTheme.push(props => {\n var _theme$components;\n const theme = resolveTheme(_extends({}, props, {\n defaultTheme,\n themeId\n }));\n const themeVariants = theme == null || (_theme$components = theme.components) == null || (_theme$components = _theme$components[componentName]) == null ? void 0 : _theme$components.variants;\n return processStyleArg({\n variants: themeVariants\n }, _extends({}, props, {\n theme\n }));\n });\n }\n if (!skipSx) {\n expressionsWithDefaultTheme.push(systemSx);\n }\n const numOfCustomFnsApplied = expressionsWithDefaultTheme.length - expressions.length;\n if (Array.isArray(styleArg) && numOfCustomFnsApplied > 0) {\n const placeholders = new Array(numOfCustomFnsApplied).fill('');\n // If the type is array, than we need to add placeholders in the template for the overrides, variants and the sx styles.\n transformedStyleArg = [...styleArg, ...placeholders];\n transformedStyleArg.raw = [...styleArg.raw, ...placeholders];\n }\n const Component = defaultStyledResolver(transformedStyleArg, ...expressionsWithDefaultTheme);\n if (process.env.NODE_ENV !== 'production') {\n let displayName;\n if (componentName) {\n displayName = `${componentName}${capitalize(componentSlot || '')}`;\n }\n if (displayName === undefined) {\n displayName = `Styled(${getDisplayName(tag)})`;\n }\n Component.displayName = displayName;\n }\n if (tag.muiName) {\n Component.muiName = tag.muiName;\n }\n return Component;\n };\n if (defaultStyledResolver.withConfig) {\n muiStyledResolver.withConfig = defaultStyledResolver.withConfig;\n }\n return muiStyledResolver;\n };\n}","import resolveProps from '@mui/utils/resolveProps';\nexport default function getThemeProps(params) {\n const {\n theme,\n name,\n props\n } = params;\n if (!theme || !theme.components || !theme.components[name] || !theme.components[name].defaultProps) {\n return props;\n }\n return resolveProps(theme.components[name].defaultProps, props);\n}","'use client';\n\nimport getThemeProps from './getThemeProps';\nimport useTheme from '../useTheme';\nexport default function useThemeProps({\n props,\n name,\n defaultTheme,\n themeId\n}) {\n let theme = useTheme(defaultTheme);\n if (themeId) {\n theme = theme[themeId] || theme;\n }\n const mergedProps = getThemeProps({\n theme,\n name,\n props\n });\n return mergedProps;\n}","import _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\n/* eslint-disable @typescript-eslint/naming-convention */\nimport clamp from '@mui/utils/clamp';\n/**\n * Returns a number whose value is limited to the given range.\n * @param {number} value The value to be clamped\n * @param {number} min The lower boundary of the output range\n * @param {number} max The upper boundary of the output range\n * @returns {number} A number in the range [min, max]\n */\nfunction clampWrapper(value, min = 0, max = 1) {\n if (process.env.NODE_ENV !== 'production') {\n if (value < min || value > max) {\n console.error(`MUI: The value provided ${value} is out of range [${min}, ${max}].`);\n }\n }\n return clamp(value, min, max);\n}\n\n/**\n * Converts a color from CSS hex format to CSS rgb format.\n * @param {string} color - Hex color, i.e. #nnn or #nnnnnn\n * @returns {string} A CSS rgb color string\n */\nexport function hexToRgb(color) {\n color = color.slice(1);\n const re = new RegExp(`.{1,${color.length >= 6 ? 2 : 1}}`, 'g');\n let colors = color.match(re);\n if (colors && colors[0].length === 1) {\n colors = colors.map(n => n + n);\n }\n return colors ? `rgb${colors.length === 4 ? 'a' : ''}(${colors.map((n, index) => {\n return index < 3 ? parseInt(n, 16) : Math.round(parseInt(n, 16) / 255 * 1000) / 1000;\n }).join(', ')})` : '';\n}\nfunction intToHex(int) {\n const hex = int.toString(16);\n return hex.length === 1 ? `0${hex}` : hex;\n}\n\n/**\n * Returns an object with the type and values of a color.\n *\n * Note: Does not support rgb % values.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @returns {object} - A MUI color object: {type: string, values: number[]}\n */\nexport function decomposeColor(color) {\n // Idempotent\n if (color.type) {\n return color;\n }\n if (color.charAt(0) === '#') {\n return decomposeColor(hexToRgb(color));\n }\n const marker = color.indexOf('(');\n const type = color.substring(0, marker);\n if (['rgb', 'rgba', 'hsl', 'hsla', 'color'].indexOf(type) === -1) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: Unsupported \\`${color}\\` color.\nThe following formats are supported: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color().` : _formatMuiErrorMessage(9, color));\n }\n let values = color.substring(marker + 1, color.length - 1);\n let colorSpace;\n if (type === 'color') {\n values = values.split(' ');\n colorSpace = values.shift();\n if (values.length === 4 && values[3].charAt(0) === '/') {\n values[3] = values[3].slice(1);\n }\n if (['srgb', 'display-p3', 'a98-rgb', 'prophoto-rgb', 'rec-2020'].indexOf(colorSpace) === -1) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: unsupported \\`${colorSpace}\\` color space.\nThe following color spaces are supported: srgb, display-p3, a98-rgb, prophoto-rgb, rec-2020.` : _formatMuiErrorMessage(10, colorSpace));\n }\n } else {\n values = values.split(',');\n }\n values = values.map(value => parseFloat(value));\n return {\n type,\n values,\n colorSpace\n };\n}\n\n/**\n * Returns a channel created from the input color.\n *\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @returns {string} - The channel for the color, that can be used in rgba or hsla colors\n */\nexport const colorChannel = color => {\n const decomposedColor = decomposeColor(color);\n return decomposedColor.values.slice(0, 3).map((val, idx) => decomposedColor.type.indexOf('hsl') !== -1 && idx !== 0 ? `${val}%` : val).join(' ');\n};\nexport const private_safeColorChannel = (color, warning) => {\n try {\n return colorChannel(color);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n};\n\n/**\n * Converts a color object with type and values to a string.\n * @param {object} color - Decomposed color\n * @param {string} color.type - One of: 'rgb', 'rgba', 'hsl', 'hsla', 'color'\n * @param {array} color.values - [n,n,n] or [n,n,n,n]\n * @returns {string} A CSS color string\n */\nexport function recomposeColor(color) {\n const {\n type,\n colorSpace\n } = color;\n let {\n values\n } = color;\n if (type.indexOf('rgb') !== -1) {\n // Only convert the first 3 values to int (i.e. not alpha)\n values = values.map((n, i) => i < 3 ? parseInt(n, 10) : n);\n } else if (type.indexOf('hsl') !== -1) {\n values[1] = `${values[1]}%`;\n values[2] = `${values[2]}%`;\n }\n if (type.indexOf('color') !== -1) {\n values = `${colorSpace} ${values.join(' ')}`;\n } else {\n values = `${values.join(', ')}`;\n }\n return `${type}(${values})`;\n}\n\n/**\n * Converts a color from CSS rgb format to CSS hex format.\n * @param {string} color - RGB color, i.e. rgb(n, n, n)\n * @returns {string} A CSS rgb color string, i.e. #nnnnnn\n */\nexport function rgbToHex(color) {\n // Idempotent\n if (color.indexOf('#') === 0) {\n return color;\n }\n const {\n values\n } = decomposeColor(color);\n return `#${values.map((n, i) => intToHex(i === 3 ? Math.round(255 * n) : n)).join('')}`;\n}\n\n/**\n * Converts a color from hsl format to rgb format.\n * @param {string} color - HSL color values\n * @returns {string} rgb color values\n */\nexport function hslToRgb(color) {\n color = decomposeColor(color);\n const {\n values\n } = color;\n const h = values[0];\n const s = values[1] / 100;\n const l = values[2] / 100;\n const a = s * Math.min(l, 1 - l);\n const f = (n, k = (n + h / 30) % 12) => l - a * Math.max(Math.min(k - 3, 9 - k, 1), -1);\n let type = 'rgb';\n const rgb = [Math.round(f(0) * 255), Math.round(f(8) * 255), Math.round(f(4) * 255)];\n if (color.type === 'hsla') {\n type += 'a';\n rgb.push(values[3]);\n }\n return recomposeColor({\n type,\n values: rgb\n });\n}\n/**\n * The relative brightness of any point in a color space,\n * normalized to 0 for darkest black and 1 for lightest white.\n *\n * Formula: https://www.w3.org/TR/WCAG20-TECHS/G17.html#G17-tests\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @returns {number} The relative brightness of the color in the range 0 - 1\n */\nexport function getLuminance(color) {\n color = decomposeColor(color);\n let rgb = color.type === 'hsl' || color.type === 'hsla' ? decomposeColor(hslToRgb(color)).values : color.values;\n rgb = rgb.map(val => {\n if (color.type !== 'color') {\n val /= 255; // normalized\n }\n return val <= 0.03928 ? val / 12.92 : ((val + 0.055) / 1.055) ** 2.4;\n });\n\n // Truncate at 3 digits\n return Number((0.2126 * rgb[0] + 0.7152 * rgb[1] + 0.0722 * rgb[2]).toFixed(3));\n}\n\n/**\n * Calculates the contrast ratio between two colors.\n *\n * Formula: https://www.w3.org/TR/WCAG20-TECHS/G17.html#G17-tests\n * @param {string} foreground - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla()\n * @param {string} background - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla()\n * @returns {number} A contrast ratio value in the range 0 - 21.\n */\nexport function getContrastRatio(foreground, background) {\n const lumA = getLuminance(foreground);\n const lumB = getLuminance(background);\n return (Math.max(lumA, lumB) + 0.05) / (Math.min(lumA, lumB) + 0.05);\n}\n\n/**\n * Sets the absolute transparency of a color.\n * Any existing alpha values are overwritten.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} value - value to set the alpha channel to in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function alpha(color, value) {\n color = decomposeColor(color);\n value = clampWrapper(value);\n if (color.type === 'rgb' || color.type === 'hsl') {\n color.type += 'a';\n }\n if (color.type === 'color') {\n color.values[3] = `/${value}`;\n } else {\n color.values[3] = value;\n }\n return recomposeColor(color);\n}\nexport function private_safeAlpha(color, value, warning) {\n try {\n return alpha(color, value);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Darkens a color.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} coefficient - multiplier in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function darken(color, coefficient) {\n color = decomposeColor(color);\n coefficient = clampWrapper(coefficient);\n if (color.type.indexOf('hsl') !== -1) {\n color.values[2] *= 1 - coefficient;\n } else if (color.type.indexOf('rgb') !== -1 || color.type.indexOf('color') !== -1) {\n for (let i = 0; i < 3; i += 1) {\n color.values[i] *= 1 - coefficient;\n }\n }\n return recomposeColor(color);\n}\nexport function private_safeDarken(color, coefficient, warning) {\n try {\n return darken(color, coefficient);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Lightens a color.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} coefficient - multiplier in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function lighten(color, coefficient) {\n color = decomposeColor(color);\n coefficient = clampWrapper(coefficient);\n if (color.type.indexOf('hsl') !== -1) {\n color.values[2] += (100 - color.values[2]) * coefficient;\n } else if (color.type.indexOf('rgb') !== -1) {\n for (let i = 0; i < 3; i += 1) {\n color.values[i] += (255 - color.values[i]) * coefficient;\n }\n } else if (color.type.indexOf('color') !== -1) {\n for (let i = 0; i < 3; i += 1) {\n color.values[i] += (1 - color.values[i]) * coefficient;\n }\n }\n return recomposeColor(color);\n}\nexport function private_safeLighten(color, coefficient, warning) {\n try {\n return lighten(color, coefficient);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Darken or lighten a color, depending on its luminance.\n * Light colors are darkened, dark colors are lightened.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} coefficient=0.15 - multiplier in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function emphasize(color, coefficient = 0.15) {\n return getLuminance(color) > 0.5 ? darken(color, coefficient) : lighten(color, coefficient);\n}\nexport function private_safeEmphasize(color, coefficient, warning) {\n try {\n return emphasize(color, coefficient);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Blend a transparent overlay color with a background color, resulting in a single\n * RGB color.\n * @param {string} background - CSS color\n * @param {string} overlay - CSS color\n * @param {number} opacity - Opacity multiplier in the range 0 - 1\n * @param {number} [gamma=1.0] - Gamma correction factor. For gamma-correct blending, 2.2 is usual.\n */\nexport function blend(background, overlay, opacity, gamma = 1.0) {\n const blendChannel = (b, o) => Math.round((b ** (1 / gamma) * (1 - opacity) + o ** (1 / gamma) * opacity) ** gamma);\n const backgroundColor = decomposeColor(background);\n const overlayColor = decomposeColor(overlay);\n const rgb = [blendChannel(backgroundColor.values[0], overlayColor.values[0]), blendChannel(backgroundColor.values[1], overlayColor.values[1]), blendChannel(backgroundColor.values[2], overlayColor.values[2])];\n return recomposeColor({\n type: 'rgb',\n values: rgb\n });\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nexport default function createMixins(breakpoints, mixins) {\n return _extends({\n toolbar: {\n minHeight: 56,\n [breakpoints.up('xs')]: {\n '@media (orientation: landscape)': {\n minHeight: 48\n }\n },\n [breakpoints.up('sm')]: {\n minHeight: 64\n }\n }\n }, mixins);\n}","const common = {\n black: '#000',\n white: '#fff'\n};\nexport default common;","const grey = {\n 50: '#fafafa',\n 100: '#f5f5f5',\n 200: '#eeeeee',\n 300: '#e0e0e0',\n 400: '#bdbdbd',\n 500: '#9e9e9e',\n 600: '#757575',\n 700: '#616161',\n 800: '#424242',\n 900: '#212121',\n A100: '#f5f5f5',\n A200: '#eeeeee',\n A400: '#bdbdbd',\n A700: '#616161'\n};\nexport default grey;","const purple = {\n 50: '#f3e5f5',\n 100: '#e1bee7',\n 200: '#ce93d8',\n 300: '#ba68c8',\n 400: '#ab47bc',\n 500: '#9c27b0',\n 600: '#8e24aa',\n 700: '#7b1fa2',\n 800: '#6a1b9a',\n 900: '#4a148c',\n A100: '#ea80fc',\n A200: '#e040fb',\n A400: '#d500f9',\n A700: '#aa00ff'\n};\nexport default purple;","const red = {\n 50: '#ffebee',\n 100: '#ffcdd2',\n 200: '#ef9a9a',\n 300: '#e57373',\n 400: '#ef5350',\n 500: '#f44336',\n 600: '#e53935',\n 700: '#d32f2f',\n 800: '#c62828',\n 900: '#b71c1c',\n A100: '#ff8a80',\n A200: '#ff5252',\n A400: '#ff1744',\n A700: '#d50000'\n};\nexport default red;","const orange = {\n 50: '#fff3e0',\n 100: '#ffe0b2',\n 200: '#ffcc80',\n 300: '#ffb74d',\n 400: '#ffa726',\n 500: '#ff9800',\n 600: '#fb8c00',\n 700: '#f57c00',\n 800: '#ef6c00',\n 900: '#e65100',\n A100: '#ffd180',\n A200: '#ffab40',\n A400: '#ff9100',\n A700: '#ff6d00'\n};\nexport default orange;","const blue = {\n 50: '#e3f2fd',\n 100: '#bbdefb',\n 200: '#90caf9',\n 300: '#64b5f6',\n 400: '#42a5f5',\n 500: '#2196f3',\n 600: '#1e88e5',\n 700: '#1976d2',\n 800: '#1565c0',\n 900: '#0d47a1',\n A100: '#82b1ff',\n A200: '#448aff',\n A400: '#2979ff',\n A700: '#2962ff'\n};\nexport default blue;","const lightBlue = {\n 50: '#e1f5fe',\n 100: '#b3e5fc',\n 200: '#81d4fa',\n 300: '#4fc3f7',\n 400: '#29b6f6',\n 500: '#03a9f4',\n 600: '#039be5',\n 700: '#0288d1',\n 800: '#0277bd',\n 900: '#01579b',\n A100: '#80d8ff',\n A200: '#40c4ff',\n A400: '#00b0ff',\n A700: '#0091ea'\n};\nexport default lightBlue;","const green = {\n 50: '#e8f5e9',\n 100: '#c8e6c9',\n 200: '#a5d6a7',\n 300: '#81c784',\n 400: '#66bb6a',\n 500: '#4caf50',\n 600: '#43a047',\n 700: '#388e3c',\n 800: '#2e7d32',\n 900: '#1b5e20',\n A100: '#b9f6ca',\n A200: '#69f0ae',\n A400: '#00e676',\n A700: '#00c853'\n};\nexport default green;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\nconst _excluded = [\"mode\", \"contrastThreshold\", \"tonalOffset\"];\nimport { deepmerge } from '@mui/utils';\nimport { darken, getContrastRatio, lighten } from '@mui/system';\nimport common from '../colors/common';\nimport grey from '../colors/grey';\nimport purple from '../colors/purple';\nimport red from '../colors/red';\nimport orange from '../colors/orange';\nimport blue from '../colors/blue';\nimport lightBlue from '../colors/lightBlue';\nimport green from '../colors/green';\nexport const light = {\n // The colors used to style the text.\n text: {\n // The most important text.\n primary: 'rgba(0, 0, 0, 0.87)',\n // Secondary text.\n secondary: 'rgba(0, 0, 0, 0.6)',\n // Disabled text have even lower visual prominence.\n disabled: 'rgba(0, 0, 0, 0.38)'\n },\n // The color used to divide different elements.\n divider: 'rgba(0, 0, 0, 0.12)',\n // The background colors used to style the surfaces.\n // Consistency between these values is important.\n background: {\n paper: common.white,\n default: common.white\n },\n // The colors used to style the action elements.\n action: {\n // The color of an active action like an icon button.\n active: 'rgba(0, 0, 0, 0.54)',\n // The color of an hovered action.\n hover: 'rgba(0, 0, 0, 0.04)',\n hoverOpacity: 0.04,\n // The color of a selected action.\n selected: 'rgba(0, 0, 0, 0.08)',\n selectedOpacity: 0.08,\n // The color of a disabled action.\n disabled: 'rgba(0, 0, 0, 0.26)',\n // The background color of a disabled action.\n disabledBackground: 'rgba(0, 0, 0, 0.12)',\n disabledOpacity: 0.38,\n focus: 'rgba(0, 0, 0, 0.12)',\n focusOpacity: 0.12,\n activatedOpacity: 0.12\n }\n};\nexport const dark = {\n text: {\n primary: common.white,\n secondary: 'rgba(255, 255, 255, 0.7)',\n disabled: 'rgba(255, 255, 255, 0.5)',\n icon: 'rgba(255, 255, 255, 0.5)'\n },\n divider: 'rgba(255, 255, 255, 0.12)',\n background: {\n paper: '#121212',\n default: '#121212'\n },\n action: {\n active: common.white,\n hover: 'rgba(255, 255, 255, 0.08)',\n hoverOpacity: 0.08,\n selected: 'rgba(255, 255, 255, 0.16)',\n selectedOpacity: 0.16,\n disabled: 'rgba(255, 255, 255, 0.3)',\n disabledBackground: 'rgba(255, 255, 255, 0.12)',\n disabledOpacity: 0.38,\n focus: 'rgba(255, 255, 255, 0.12)',\n focusOpacity: 0.12,\n activatedOpacity: 0.24\n }\n};\nfunction addLightOrDark(intent, direction, shade, tonalOffset) {\n const tonalOffsetLight = tonalOffset.light || tonalOffset;\n const tonalOffsetDark = tonalOffset.dark || tonalOffset * 1.5;\n if (!intent[direction]) {\n if (intent.hasOwnProperty(shade)) {\n intent[direction] = intent[shade];\n } else if (direction === 'light') {\n intent.light = lighten(intent.main, tonalOffsetLight);\n } else if (direction === 'dark') {\n intent.dark = darken(intent.main, tonalOffsetDark);\n }\n }\n}\nfunction getDefaultPrimary(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: blue[200],\n light: blue[50],\n dark: blue[400]\n };\n }\n return {\n main: blue[700],\n light: blue[400],\n dark: blue[800]\n };\n}\nfunction getDefaultSecondary(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: purple[200],\n light: purple[50],\n dark: purple[400]\n };\n }\n return {\n main: purple[500],\n light: purple[300],\n dark: purple[700]\n };\n}\nfunction getDefaultError(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: red[500],\n light: red[300],\n dark: red[700]\n };\n }\n return {\n main: red[700],\n light: red[400],\n dark: red[800]\n };\n}\nfunction getDefaultInfo(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: lightBlue[400],\n light: lightBlue[300],\n dark: lightBlue[700]\n };\n }\n return {\n main: lightBlue[700],\n light: lightBlue[500],\n dark: lightBlue[900]\n };\n}\nfunction getDefaultSuccess(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: green[400],\n light: green[300],\n dark: green[700]\n };\n }\n return {\n main: green[800],\n light: green[500],\n dark: green[900]\n };\n}\nfunction getDefaultWarning(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: orange[400],\n light: orange[300],\n dark: orange[700]\n };\n }\n return {\n main: '#ed6c02',\n // closest to orange[800] that pass 3:1.\n light: orange[500],\n dark: orange[900]\n };\n}\nexport default function createPalette(palette) {\n const {\n mode = 'light',\n contrastThreshold = 3,\n tonalOffset = 0.2\n } = palette,\n other = _objectWithoutPropertiesLoose(palette, _excluded);\n const primary = palette.primary || getDefaultPrimary(mode);\n const secondary = palette.secondary || getDefaultSecondary(mode);\n const error = palette.error || getDefaultError(mode);\n const info = palette.info || getDefaultInfo(mode);\n const success = palette.success || getDefaultSuccess(mode);\n const warning = palette.warning || getDefaultWarning(mode);\n\n // Use the same logic as\n // Bootstrap: https://github.com/twbs/bootstrap/blob/1d6e3710dd447de1a200f29e8fa521f8a0908f70/scss/_functions.scss#L59\n // and material-components-web https://github.com/material-components/material-components-web/blob/ac46b8863c4dab9fc22c4c662dc6bd1b65dd652f/packages/mdc-theme/_functions.scss#L54\n function getContrastText(background) {\n const contrastText = getContrastRatio(background, dark.text.primary) >= contrastThreshold ? dark.text.primary : light.text.primary;\n if (process.env.NODE_ENV !== 'production') {\n const contrast = getContrastRatio(background, contrastText);\n if (contrast < 3) {\n console.error([`MUI: The contrast ratio of ${contrast}:1 for ${contrastText} on ${background}`, 'falls below the WCAG recommended absolute minimum contrast ratio of 3:1.', 'https://www.w3.org/TR/2008/REC-WCAG20-20081211/#visual-audio-contrast-contrast'].join('\\n'));\n }\n }\n return contrastText;\n }\n const augmentColor = ({\n color,\n name,\n mainShade = 500,\n lightShade = 300,\n darkShade = 700\n }) => {\n color = _extends({}, color);\n if (!color.main && color[mainShade]) {\n color.main = color[mainShade];\n }\n if (!color.hasOwnProperty('main')) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: The color${name ? ` (${name})` : ''} provided to augmentColor(color) is invalid.\nThe color object needs to have a \\`main\\` property or a \\`${mainShade}\\` property.` : _formatMuiErrorMessage(11, name ? ` (${name})` : '', mainShade));\n }\n if (typeof color.main !== 'string') {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: The color${name ? ` (${name})` : ''} provided to augmentColor(color) is invalid.\n\\`color.main\\` should be a string, but \\`${JSON.stringify(color.main)}\\` was provided instead.\n\nDid you intend to use one of the following approaches?\n\nimport { green } from \"@mui/material/colors\";\n\nconst theme1 = createTheme({ palette: {\n primary: green,\n} });\n\nconst theme2 = createTheme({ palette: {\n primary: { main: green[500] },\n} });` : _formatMuiErrorMessage(12, name ? ` (${name})` : '', JSON.stringify(color.main)));\n }\n addLightOrDark(color, 'light', lightShade, tonalOffset);\n addLightOrDark(color, 'dark', darkShade, tonalOffset);\n if (!color.contrastText) {\n color.contrastText = getContrastText(color.main);\n }\n return color;\n };\n const modes = {\n dark,\n light\n };\n if (process.env.NODE_ENV !== 'production') {\n if (!modes[mode]) {\n console.error(`MUI: The palette mode \\`${mode}\\` is not supported.`);\n }\n }\n const paletteOutput = deepmerge(_extends({\n // A collection of common colors.\n common: _extends({}, common),\n // prevent mutable object.\n // The palette mode, can be light or dark.\n mode,\n // The colors used to represent primary interface elements for a user.\n primary: augmentColor({\n color: primary,\n name: 'primary'\n }),\n // The colors used to represent secondary interface elements for a user.\n secondary: augmentColor({\n color: secondary,\n name: 'secondary',\n mainShade: 'A400',\n lightShade: 'A200',\n darkShade: 'A700'\n }),\n // The colors used to represent interface elements that the user should be made aware of.\n error: augmentColor({\n color: error,\n name: 'error'\n }),\n // The colors used to represent potentially dangerous actions or important messages.\n warning: augmentColor({\n color: warning,\n name: 'warning'\n }),\n // The colors used to present information to the user that is neutral and not necessarily important.\n info: augmentColor({\n color: info,\n name: 'info'\n }),\n // The colors used to indicate the successful completion of an action that user triggered.\n success: augmentColor({\n color: success,\n name: 'success'\n }),\n // The grey colors.\n grey,\n // Used by `getContrastText()` to maximize the contrast between\n // the background and the text.\n contrastThreshold,\n // Takes a background color and returns the text color that maximizes the contrast.\n getContrastText,\n // Generate a rich color object.\n augmentColor,\n // Used by the functions below to shift a color's luminance by approximately\n // two indexes within its tonal palette.\n // E.g., shift from Red 500 to Red 300 or Red 700.\n tonalOffset\n }, modes[mode]), other);\n return paletteOutput;\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"fontFamily\", \"fontSize\", \"fontWeightLight\", \"fontWeightRegular\", \"fontWeightMedium\", \"fontWeightBold\", \"htmlFontSize\", \"allVariants\", \"pxToRem\"];\nimport { deepmerge } from '@mui/utils';\nfunction round(value) {\n return Math.round(value * 1e5) / 1e5;\n}\nconst caseAllCaps = {\n textTransform: 'uppercase'\n};\nconst defaultFontFamily = '\"Roboto\", \"Helvetica\", \"Arial\", sans-serif';\n\n/**\n * @see @link{https://m2.material.io/design/typography/the-type-system.html}\n * @see @link{https://m2.material.io/design/typography/understanding-typography.html}\n */\nexport default function createTypography(palette, typography) {\n const _ref = typeof typography === 'function' ? typography(palette) : typography,\n {\n fontFamily = defaultFontFamily,\n // The default font size of the Material Specification.\n fontSize = 14,\n // px\n fontWeightLight = 300,\n fontWeightRegular = 400,\n fontWeightMedium = 500,\n fontWeightBold = 700,\n // Tell MUI what's the font-size on the html element.\n // 16px is the default font-size used by browsers.\n htmlFontSize = 16,\n // Apply the CSS properties to all the variants.\n allVariants,\n pxToRem: pxToRem2\n } = _ref,\n other = _objectWithoutPropertiesLoose(_ref, _excluded);\n if (process.env.NODE_ENV !== 'production') {\n if (typeof fontSize !== 'number') {\n console.error('MUI: `fontSize` is required to be a number.');\n }\n if (typeof htmlFontSize !== 'number') {\n console.error('MUI: `htmlFontSize` is required to be a number.');\n }\n }\n const coef = fontSize / 14;\n const pxToRem = pxToRem2 || (size => `${size / htmlFontSize * coef}rem`);\n const buildVariant = (fontWeight, size, lineHeight, letterSpacing, casing) => _extends({\n fontFamily,\n fontWeight,\n fontSize: pxToRem(size),\n // Unitless following https://meyerweb.com/eric/thoughts/2006/02/08/unitless-line-heights/\n lineHeight\n }, fontFamily === defaultFontFamily ? {\n letterSpacing: `${round(letterSpacing / size)}em`\n } : {}, casing, allVariants);\n const variants = {\n h1: buildVariant(fontWeightLight, 96, 1.167, -1.5),\n h2: buildVariant(fontWeightLight, 60, 1.2, -0.5),\n h3: buildVariant(fontWeightRegular, 48, 1.167, 0),\n h4: buildVariant(fontWeightRegular, 34, 1.235, 0.25),\n h5: buildVariant(fontWeightRegular, 24, 1.334, 0),\n h6: buildVariant(fontWeightMedium, 20, 1.6, 0.15),\n subtitle1: buildVariant(fontWeightRegular, 16, 1.75, 0.15),\n subtitle2: buildVariant(fontWeightMedium, 14, 1.57, 0.1),\n body1: buildVariant(fontWeightRegular, 16, 1.5, 0.15),\n body2: buildVariant(fontWeightRegular, 14, 1.43, 0.15),\n button: buildVariant(fontWeightMedium, 14, 1.75, 0.4, caseAllCaps),\n caption: buildVariant(fontWeightRegular, 12, 1.66, 0.4),\n overline: buildVariant(fontWeightRegular, 12, 2.66, 1, caseAllCaps),\n // TODO v6: Remove handling of 'inherit' variant from the theme as it is already handled in Material UI's Typography component. Also, remember to remove the associated types.\n inherit: {\n fontFamily: 'inherit',\n fontWeight: 'inherit',\n fontSize: 'inherit',\n lineHeight: 'inherit',\n letterSpacing: 'inherit'\n }\n };\n return deepmerge(_extends({\n htmlFontSize,\n pxToRem,\n fontFamily,\n fontSize,\n fontWeightLight,\n fontWeightRegular,\n fontWeightMedium,\n fontWeightBold\n }, variants), other, {\n clone: false // No need to clone deep\n });\n}","const shadowKeyUmbraOpacity = 0.2;\nconst shadowKeyPenumbraOpacity = 0.14;\nconst shadowAmbientShadowOpacity = 0.12;\nfunction createShadow(...px) {\n return [`${px[0]}px ${px[1]}px ${px[2]}px ${px[3]}px rgba(0,0,0,${shadowKeyUmbraOpacity})`, `${px[4]}px ${px[5]}px ${px[6]}px ${px[7]}px rgba(0,0,0,${shadowKeyPenumbraOpacity})`, `${px[8]}px ${px[9]}px ${px[10]}px ${px[11]}px rgba(0,0,0,${shadowAmbientShadowOpacity})`].join(',');\n}\n\n// Values from https://github.com/material-components/material-components-web/blob/be8747f94574669cb5e7add1a7c54fa41a89cec7/packages/mdc-elevation/_variables.scss\nconst shadows = ['none', createShadow(0, 2, 1, -1, 0, 1, 1, 0, 0, 1, 3, 0), createShadow(0, 3, 1, -2, 0, 2, 2, 0, 0, 1, 5, 0), createShadow(0, 3, 3, -2, 0, 3, 4, 0, 0, 1, 8, 0), createShadow(0, 2, 4, -1, 0, 4, 5, 0, 0, 1, 10, 0), createShadow(0, 3, 5, -1, 0, 5, 8, 0, 0, 1, 14, 0), createShadow(0, 3, 5, -1, 0, 6, 10, 0, 0, 1, 18, 0), createShadow(0, 4, 5, -2, 0, 7, 10, 1, 0, 2, 16, 1), createShadow(0, 5, 5, -3, 0, 8, 10, 1, 0, 3, 14, 2), createShadow(0, 5, 6, -3, 0, 9, 12, 1, 0, 3, 16, 2), createShadow(0, 6, 6, -3, 0, 10, 14, 1, 0, 4, 18, 3), createShadow(0, 6, 7, -4, 0, 11, 15, 1, 0, 4, 20, 3), createShadow(0, 7, 8, -4, 0, 12, 17, 2, 0, 5, 22, 4), createShadow(0, 7, 8, -4, 0, 13, 19, 2, 0, 5, 24, 4), createShadow(0, 7, 9, -4, 0, 14, 21, 2, 0, 5, 26, 4), createShadow(0, 8, 9, -5, 0, 15, 22, 2, 0, 6, 28, 5), createShadow(0, 8, 10, -5, 0, 16, 24, 2, 0, 6, 30, 5), createShadow(0, 8, 11, -5, 0, 17, 26, 2, 0, 6, 32, 5), createShadow(0, 9, 11, -5, 0, 18, 28, 2, 0, 7, 34, 6), createShadow(0, 9, 12, -6, 0, 19, 29, 2, 0, 7, 36, 6), createShadow(0, 10, 13, -6, 0, 20, 31, 3, 0, 8, 38, 7), createShadow(0, 10, 13, -6, 0, 21, 33, 3, 0, 8, 40, 7), createShadow(0, 10, 14, -6, 0, 22, 35, 3, 0, 8, 42, 7), createShadow(0, 11, 14, -7, 0, 23, 36, 3, 0, 9, 44, 8), createShadow(0, 11, 15, -7, 0, 24, 38, 3, 0, 9, 46, 8)];\nexport default shadows;","import _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nconst _excluded = [\"duration\", \"easing\", \"delay\"];\n// Follow https://material.google.com/motion/duration-easing.html#duration-easing-natural-easing-curves\n// to learn the context in which each easing should be used.\nexport const easing = {\n // This is the most common easing curve.\n easeInOut: 'cubic-bezier(0.4, 0, 0.2, 1)',\n // Objects enter the screen at full velocity from off-screen and\n // slowly decelerate to a resting point.\n easeOut: 'cubic-bezier(0.0, 0, 0.2, 1)',\n // Objects leave the screen at full velocity. They do not decelerate when off-screen.\n easeIn: 'cubic-bezier(0.4, 0, 1, 1)',\n // The sharp curve is used by objects that may return to the screen at any time.\n sharp: 'cubic-bezier(0.4, 0, 0.6, 1)'\n};\n\n// Follow https://m2.material.io/guidelines/motion/duration-easing.html#duration-easing-common-durations\n// to learn when use what timing\nexport const duration = {\n shortest: 150,\n shorter: 200,\n short: 250,\n // most basic recommended timing\n standard: 300,\n // this is to be used in complex animations\n complex: 375,\n // recommended when something is entering screen\n enteringScreen: 225,\n // recommended when something is leaving screen\n leavingScreen: 195\n};\nfunction formatMs(milliseconds) {\n return `${Math.round(milliseconds)}ms`;\n}\nfunction getAutoHeightDuration(height) {\n if (!height) {\n return 0;\n }\n const constant = height / 36;\n\n // https://www.wolframalpha.com/input/?i=(4+%2B+15+*+(x+%2F+36+)+**+0.25+%2B+(x+%2F+36)+%2F+5)+*+10\n return Math.round((4 + 15 * constant ** 0.25 + constant / 5) * 10);\n}\nexport default function createTransitions(inputTransitions) {\n const mergedEasing = _extends({}, easing, inputTransitions.easing);\n const mergedDuration = _extends({}, duration, inputTransitions.duration);\n const create = (props = ['all'], options = {}) => {\n const {\n duration: durationOption = mergedDuration.standard,\n easing: easingOption = mergedEasing.easeInOut,\n delay = 0\n } = options,\n other = _objectWithoutPropertiesLoose(options, _excluded);\n if (process.env.NODE_ENV !== 'production') {\n const isString = value => typeof value === 'string';\n // IE11 support, replace with Number.isNaN\n // eslint-disable-next-line no-restricted-globals\n const isNumber = value => !isNaN(parseFloat(value));\n if (!isString(props) && !Array.isArray(props)) {\n console.error('MUI: Argument \"props\" must be a string or Array.');\n }\n if (!isNumber(durationOption) && !isString(durationOption)) {\n console.error(`MUI: Argument \"duration\" must be a number or a string but found ${durationOption}.`);\n }\n if (!isString(easingOption)) {\n console.error('MUI: Argument \"easing\" must be a string.');\n }\n if (!isNumber(delay) && !isString(delay)) {\n console.error('MUI: Argument \"delay\" must be a number or a string.');\n }\n if (typeof options !== 'object') {\n console.error(['MUI: Secong argument of transition.create must be an object.', \"Arguments should be either `create('prop1', options)` or `create(['prop1', 'prop2'], options)`\"].join('\\n'));\n }\n if (Object.keys(other).length !== 0) {\n console.error(`MUI: Unrecognized argument(s) [${Object.keys(other).join(',')}].`);\n }\n }\n return (Array.isArray(props) ? props : [props]).map(animatedProp => `${animatedProp} ${typeof durationOption === 'string' ? durationOption : formatMs(durationOption)} ${easingOption} ${typeof delay === 'string' ? delay : formatMs(delay)}`).join(',');\n };\n return _extends({\n getAutoHeightDuration,\n create\n }, inputTransitions, {\n easing: mergedEasing,\n duration: mergedDuration\n });\n}","// We need to centralize the zIndex definitions as they work\n// like global values in the browser.\nconst zIndex = {\n mobileStepper: 1000,\n fab: 1050,\n speedDial: 1050,\n appBar: 1100,\n drawer: 1200,\n modal: 1300,\n snackbar: 1400,\n tooltip: 1500\n};\nexport default zIndex;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\nconst _excluded = [\"breakpoints\", \"mixins\", \"spacing\", \"palette\", \"transitions\", \"typography\", \"shape\"];\nimport { deepmerge } from '@mui/utils';\nimport { createTheme as systemCreateTheme, unstable_defaultSxConfig as defaultSxConfig, unstable_styleFunctionSx as styleFunctionSx } from '@mui/system';\nimport generateUtilityClass from '@mui/utils/generateUtilityClass';\nimport createMixins from './createMixins';\nimport createPalette from './createPalette';\nimport createTypography from './createTypography';\nimport shadows from './shadows';\nimport createTransitions from './createTransitions';\nimport zIndex from './zIndex';\nfunction createTheme(options = {}, ...args) {\n const {\n mixins: mixinsInput = {},\n palette: paletteInput = {},\n transitions: transitionsInput = {},\n typography: typographyInput = {}\n } = options,\n other = _objectWithoutPropertiesLoose(options, _excluded);\n if (options.vars) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: \\`vars\\` is a private field used for CSS variables support.\nPlease use another name.` : _formatMuiErrorMessage(18));\n }\n const palette = createPalette(paletteInput);\n const systemTheme = systemCreateTheme(options);\n let muiTheme = deepmerge(systemTheme, {\n mixins: createMixins(systemTheme.breakpoints, mixinsInput),\n palette,\n // Don't use [...shadows] until you've verified its transpiled code is not invoking the iterator protocol.\n shadows: shadows.slice(),\n typography: createTypography(palette, typographyInput),\n transitions: createTransitions(transitionsInput),\n zIndex: _extends({}, zIndex)\n });\n muiTheme = deepmerge(muiTheme, other);\n muiTheme = args.reduce((acc, argument) => deepmerge(acc, argument), muiTheme);\n if (process.env.NODE_ENV !== 'production') {\n // TODO v6: Refactor to use globalStateClassesMapping from @mui/utils once `readOnly` state class is used in Rating component.\n const stateClasses = ['active', 'checked', 'completed', 'disabled', 'error', 'expanded', 'focused', 'focusVisible', 'required', 'selected'];\n const traverse = (node, component) => {\n let key;\n\n // eslint-disable-next-line guard-for-in, no-restricted-syntax\n for (key in node) {\n const child = node[key];\n if (stateClasses.indexOf(key) !== -1 && Object.keys(child).length > 0) {\n if (process.env.NODE_ENV !== 'production') {\n const stateClass = generateUtilityClass('', key);\n console.error([`MUI: The \\`${component}\\` component increases ` + `the CSS specificity of the \\`${key}\\` internal state.`, 'You can not override it like this: ', JSON.stringify(node, null, 2), '', `Instead, you need to use the '&.${stateClass}' syntax:`, JSON.stringify({\n root: {\n [`&.${stateClass}`]: child\n }\n }, null, 2), '', 'https://mui.com/r/state-classes-guide'].join('\\n'));\n }\n // Remove the style to prevent global conflicts.\n node[key] = {};\n }\n }\n };\n Object.keys(muiTheme.components).forEach(component => {\n const styleOverrides = muiTheme.components[component].styleOverrides;\n if (styleOverrides && component.indexOf('Mui') === 0) {\n traverse(styleOverrides, component);\n }\n });\n }\n muiTheme.unstable_sxConfig = _extends({}, defaultSxConfig, other == null ? void 0 : other.unstable_sxConfig);\n muiTheme.unstable_sx = function sx(props) {\n return styleFunctionSx({\n sx: props,\n theme: this\n });\n };\n return muiTheme;\n}\nlet warnedOnce = false;\nexport function createMuiTheme(...args) {\n if (process.env.NODE_ENV !== 'production') {\n if (!warnedOnce) {\n warnedOnce = true;\n console.error(['MUI: the createMuiTheme function was renamed to createTheme.', '', \"You should use `import { createTheme } from '@mui/material/styles'`\"].join('\\n'));\n }\n }\n return createTheme(...args);\n}\nexport default createTheme;","'use client';\n\nimport createTheme from './createTheme';\nconst defaultTheme = createTheme();\nexport default defaultTheme;","export default '$$material';","'use client';\n\nimport { useThemeProps as systemUseThemeProps } from '@mui/system';\nimport defaultTheme from './defaultTheme';\nimport THEME_ID from './identifier';\nexport default function useThemeProps({\n props,\n name\n}) {\n return systemUseThemeProps({\n props,\n name,\n defaultTheme,\n themeId: THEME_ID\n });\n}","'use client';\n\nimport { createStyled, shouldForwardProp } from '@mui/system';\nimport defaultTheme from './defaultTheme';\nimport THEME_ID from './identifier';\nexport const rootShouldForwardProp = prop => shouldForwardProp(prop) && prop !== 'classes';\nexport const slotShouldForwardProp = shouldForwardProp;\nconst styled = createStyled({\n themeId: THEME_ID,\n defaultTheme,\n rootShouldForwardProp\n});\nexport default styled;","import generateUtilityClasses from '@mui/utils/generateUtilityClasses';\nimport generateUtilityClass from '@mui/utils/generateUtilityClass';\nexport function getSvgIconUtilityClass(slot) {\n return generateUtilityClass('MuiSvgIcon', slot);\n}\nconst svgIconClasses = generateUtilityClasses('MuiSvgIcon', ['root', 'colorPrimary', 'colorSecondary', 'colorAction', 'colorError', 'colorDisabled', 'fontSizeInherit', 'fontSizeSmall', 'fontSizeMedium', 'fontSizeLarge']);\nexport default svgIconClasses;","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"children\", \"className\", \"color\", \"component\", \"fontSize\", \"htmlColor\", \"inheritViewBox\", \"titleAccess\", \"viewBox\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport clsx from 'clsx';\nimport { unstable_composeClasses as composeClasses } from '@mui/base/composeClasses';\nimport capitalize from '../utils/capitalize';\nimport useThemeProps from '../styles/useThemeProps';\nimport styled from '../styles/styled';\nimport { getSvgIconUtilityClass } from './svgIconClasses';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nimport { jsxs as _jsxs } from \"react/jsx-runtime\";\nconst useUtilityClasses = ownerState => {\n const {\n color,\n fontSize,\n classes\n } = ownerState;\n const slots = {\n root: ['root', color !== 'inherit' && `color${capitalize(color)}`, `fontSize${capitalize(fontSize)}`]\n };\n return composeClasses(slots, getSvgIconUtilityClass, classes);\n};\nconst SvgIconRoot = styled('svg', {\n name: 'MuiSvgIcon',\n slot: 'Root',\n overridesResolver: (props, styles) => {\n const {\n ownerState\n } = props;\n return [styles.root, ownerState.color !== 'inherit' && styles[`color${capitalize(ownerState.color)}`], styles[`fontSize${capitalize(ownerState.fontSize)}`]];\n }\n})(({\n theme,\n ownerState\n}) => {\n var _theme$transitions, _theme$transitions$cr, _theme$transitions2, _theme$typography, _theme$typography$pxT, _theme$typography2, _theme$typography2$px, _theme$typography3, _theme$typography3$px, _palette$ownerState$c, _palette, _palette2, _palette3;\n return {\n userSelect: 'none',\n width: '1em',\n height: '1em',\n display: 'inline-block',\n // the will define the property that has `currentColor`\n // e.g. heroicons uses fill=\"none\" and stroke=\"currentColor\"\n fill: ownerState.hasSvgAsChild ? undefined : 'currentColor',\n flexShrink: 0,\n transition: (_theme$transitions = theme.transitions) == null || (_theme$transitions$cr = _theme$transitions.create) == null ? void 0 : _theme$transitions$cr.call(_theme$transitions, 'fill', {\n duration: (_theme$transitions2 = theme.transitions) == null || (_theme$transitions2 = _theme$transitions2.duration) == null ? void 0 : _theme$transitions2.shorter\n }),\n fontSize: {\n inherit: 'inherit',\n small: ((_theme$typography = theme.typography) == null || (_theme$typography$pxT = _theme$typography.pxToRem) == null ? void 0 : _theme$typography$pxT.call(_theme$typography, 20)) || '1.25rem',\n medium: ((_theme$typography2 = theme.typography) == null || (_theme$typography2$px = _theme$typography2.pxToRem) == null ? void 0 : _theme$typography2$px.call(_theme$typography2, 24)) || '1.5rem',\n large: ((_theme$typography3 = theme.typography) == null || (_theme$typography3$px = _theme$typography3.pxToRem) == null ? void 0 : _theme$typography3$px.call(_theme$typography3, 35)) || '2.1875rem'\n }[ownerState.fontSize],\n // TODO v5 deprecate, v6 remove for sx\n color: (_palette$ownerState$c = (_palette = (theme.vars || theme).palette) == null || (_palette = _palette[ownerState.color]) == null ? void 0 : _palette.main) != null ? _palette$ownerState$c : {\n action: (_palette2 = (theme.vars || theme).palette) == null || (_palette2 = _palette2.action) == null ? void 0 : _palette2.active,\n disabled: (_palette3 = (theme.vars || theme).palette) == null || (_palette3 = _palette3.action) == null ? void 0 : _palette3.disabled,\n inherit: undefined\n }[ownerState.color]\n };\n});\nconst SvgIcon = /*#__PURE__*/React.forwardRef(function SvgIcon(inProps, ref) {\n const props = useThemeProps({\n props: inProps,\n name: 'MuiSvgIcon'\n });\n const {\n children,\n className,\n color = 'inherit',\n component = 'svg',\n fontSize = 'medium',\n htmlColor,\n inheritViewBox = false,\n titleAccess,\n viewBox = '0 0 24 24'\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const hasSvgAsChild = /*#__PURE__*/React.isValidElement(children) && children.type === 'svg';\n const ownerState = _extends({}, props, {\n color,\n component,\n fontSize,\n instanceFontSize: inProps.fontSize,\n inheritViewBox,\n viewBox,\n hasSvgAsChild\n });\n const more = {};\n if (!inheritViewBox) {\n more.viewBox = viewBox;\n }\n const classes = useUtilityClasses(ownerState);\n return /*#__PURE__*/_jsxs(SvgIconRoot, _extends({\n as: component,\n className: clsx(classes.root, className),\n focusable: \"false\",\n color: htmlColor,\n \"aria-hidden\": titleAccess ? undefined : true,\n role: titleAccess ? 'img' : undefined,\n ref: ref\n }, more, other, hasSvgAsChild && children.props, {\n ownerState: ownerState,\n children: [hasSvgAsChild ? children.props.children : children, titleAccess ? /*#__PURE__*/_jsx(\"title\", {\n children: titleAccess\n }) : null]\n }));\n});\nprocess.env.NODE_ENV !== \"production\" ? SvgIcon.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the d.ts file and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * Node passed into the SVG element.\n */\n children: PropTypes.node,\n /**\n * Override or extend the styles applied to the component.\n */\n classes: PropTypes.object,\n /**\n * @ignore\n */\n className: PropTypes.string,\n /**\n * The color of the component.\n * It supports both default and custom theme colors, which can be added as shown in the\n * [palette customization guide](https://mui.com/material-ui/customization/palette/#custom-colors).\n * You can use the `htmlColor` prop to apply a color attribute to the SVG element.\n * @default 'inherit'\n */\n color: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.oneOf(['inherit', 'action', 'disabled', 'primary', 'secondary', 'error', 'info', 'success', 'warning']), PropTypes.string]),\n /**\n * The component used for the root node.\n * Either a string to use a HTML element or a component.\n */\n component: PropTypes.elementType,\n /**\n * The fontSize applied to the icon. Defaults to 24px, but can be configure to inherit font size.\n * @default 'medium'\n */\n fontSize: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.oneOf(['inherit', 'large', 'medium', 'small']), PropTypes.string]),\n /**\n * Applies a color attribute to the SVG element.\n */\n htmlColor: PropTypes.string,\n /**\n * If `true`, the root node will inherit the custom `component`'s viewBox and the `viewBox`\n * prop will be ignored.\n * Useful when you want to reference a custom `component` and have `SvgIcon` pass that\n * `component`'s viewBox to the root node.\n * @default false\n */\n inheritViewBox: PropTypes.bool,\n /**\n * The shape-rendering attribute. The behavior of the different options is described on the\n * [MDN Web Docs](https://developer.mozilla.org/en-US/docs/Web/SVG/Attribute/shape-rendering).\n * If you are having issues with blurry icons you should investigate this prop.\n */\n shapeRendering: PropTypes.string,\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Provides a human-readable title for the element that contains it.\n * https://www.w3.org/TR/SVG-access/#Equivalent\n */\n titleAccess: PropTypes.string,\n /**\n * Allows you to redefine what the coordinates without units mean inside an SVG element.\n * For example, if the SVG element is 500 (width) by 200 (height),\n * and you pass viewBox=\"0 0 50 20\",\n * this means that the coordinates inside the SVG will go from the top left corner (0,0)\n * to bottom right (50,20) and each unit will be worth 10px.\n * @default '0 0 24 24'\n */\n viewBox: PropTypes.string\n} : void 0;\nSvgIcon.muiName = 'SvgIcon';\nexport default SvgIcon;","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport * as React from 'react';\nimport SvgIcon from '../SvgIcon';\n\n/**\n * Private module reserved for @mui packages.\n */\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nexport default function createSvgIcon(path, displayName) {\n function Component(props, ref) {\n return /*#__PURE__*/_jsx(SvgIcon, _extends({\n \"data-testid\": `${displayName}Icon`,\n ref: ref\n }, props, {\n children: path\n }));\n }\n if (process.env.NODE_ENV !== 'production') {\n // Need to set `displayName` on the inner component for React.memo.\n // React prior to 16.14 ignores `displayName` on the wrapper.\n Component.displayName = `${displayName}Icon`;\n }\n Component.muiName = SvgIcon.muiName;\n return /*#__PURE__*/React.memo( /*#__PURE__*/React.forwardRef(Component));\n}","'use client';\n\nimport { unstable_ClassNameGenerator as ClassNameGenerator } from '@mui/base/ClassNameGenerator';\nexport { default as capitalize } from './capitalize';\nexport { default as createChainedFunction } from './createChainedFunction';\nexport { default as createSvgIcon } from './createSvgIcon';\nexport { default as debounce } from './debounce';\nexport { default as deprecatedPropType } from './deprecatedPropType';\nexport { default as isMuiElement } from './isMuiElement';\nexport { default as ownerDocument } from './ownerDocument';\nexport { default as ownerWindow } from './ownerWindow';\nexport { default as requirePropFactory } from './requirePropFactory';\nexport { default as setRef } from './setRef';\nexport { default as unstable_useEnhancedEffect } from './useEnhancedEffect';\nexport { default as unstable_useId } from './useId';\nexport { default as unsupportedProp } from './unsupportedProp';\nexport { default as useControlled } from './useControlled';\nexport { default as useEventCallback } from './useEventCallback';\nexport { default as useForkRef } from './useForkRef';\nexport { default as useIsFocusVisible } from './useIsFocusVisible';\n// TODO: remove this export once ClassNameGenerator is stable\n// eslint-disable-next-line @typescript-eslint/naming-convention\nexport const unstable_ClassNameGenerator = {\n configure: generator => {\n if (process.env.NODE_ENV !== 'production') {\n console.warn(['MUI: `ClassNameGenerator` import from `@mui/material/utils` is outdated and might cause unexpected issues.', '', \"You should use `import { unstable_ClassNameGenerator } from '@mui/material/className'` instead\", '', 'The detail of the issue: https://github.com/mui/material-ui/issues/30011#issuecomment-1024993401', '', 'The updated documentation: https://mui.com/guides/classname-generator/'].join('\\n'));\n }\n ClassNameGenerator.configure(generator);\n }\n};","\"use strict\";\n'use client';\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nObject.defineProperty(exports, \"default\", {\n enumerable: true,\n get: function () {\n return _utils.createSvgIcon;\n }\n});\nvar _utils = require(\"@mui/material/utils\");","\"use strict\";\n\"use client\";\n\nvar _interopRequireDefault = require(\"@babel/runtime/helpers/interopRequireDefault\");\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = void 0;\nvar _createSvgIcon = _interopRequireDefault(require(\"./utils/createSvgIcon\"));\nvar _jsxRuntime = require(\"react/jsx-runtime\");\nvar _default = exports.default = (0, _createSvgIcon.default)( /*#__PURE__*/(0, _jsxRuntime.jsx)(\"path\", {\n d: \"m10 17 5-5-5-5z\"\n}), 'ArrowRight');","/**\n * Determines if a given element is a DOM element name (i.e. not a React component).\n */\nexport function isHostComponent(element) {\n return typeof element === 'string';\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport { isHostComponent } from './isHostComponent';\n\n/**\n * Type of the ownerState based on the type of an element it applies to.\n * This resolves to the provided OwnerState for React components and `undefined` for host components.\n * Falls back to `OwnerState | undefined` when the exact type can't be determined in development time.\n */\n\n/**\n * Appends the ownerState object to the props, merging with the existing one if necessary.\n *\n * @param elementType Type of the element that owns the `existingProps`. If the element is a DOM node or undefined, `ownerState` is not applied.\n * @param otherProps Props of the element.\n * @param ownerState\n */\nexport function appendOwnerState(elementType, otherProps, ownerState) {\n if (elementType === undefined || isHostComponent(elementType)) {\n return otherProps;\n }\n return _extends({}, otherProps, {\n ownerState: _extends({}, otherProps.ownerState, ownerState)\n });\n}","'use client';\n\nimport * as React from 'react';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nconst defaultContextValue = {\n disableDefaultClasses: false\n};\nconst ClassNameConfiguratorContext = /*#__PURE__*/React.createContext(defaultContextValue);\n/**\n * @ignore - internal hook.\n *\n * Wraps the `generateUtilityClass` function and controls how the classes are generated.\n * Currently it only affects whether the classes are applied or not.\n *\n * @returns Function to be called with the `generateUtilityClass` function specific to a component to generate the classes.\n */\nexport function useClassNamesOverride(generateUtilityClass) {\n const {\n disableDefaultClasses\n } = React.useContext(ClassNameConfiguratorContext);\n return slot => {\n if (disableDefaultClasses) {\n return '';\n }\n return generateUtilityClass(slot);\n };\n}\n\n/**\n * Allows to configure the components within to not apply any built-in classes.\n */\nexport function ClassNameConfigurator(props) {\n const {\n disableDefaultClasses,\n children\n } = props;\n const contextValue = React.useMemo(() => ({\n disableDefaultClasses: disableDefaultClasses != null ? disableDefaultClasses : false\n }), [disableDefaultClasses]);\n return /*#__PURE__*/_jsx(ClassNameConfiguratorContext.Provider, {\n value: contextValue,\n children: children\n });\n}","/**\n * Extracts event handlers from a given object.\n * A prop is considered an event handler if it is a function and its name starts with `on`.\n *\n * @param object An object to extract event handlers from.\n * @param excludeKeys An array of keys to exclude from the returned object.\n */\nexport function extractEventHandlers(object, excludeKeys = []) {\n if (object === undefined) {\n return {};\n }\n const result = {};\n Object.keys(object).filter(prop => prop.match(/^on[A-Z]/) && typeof object[prop] === 'function' && !excludeKeys.includes(prop)).forEach(prop => {\n result[prop] = object[prop];\n });\n return result;\n}","/**\n * If `componentProps` is a function, calls it with the provided `ownerState`.\n * Otherwise, just returns `componentProps`.\n */\nexport function resolveComponentProps(componentProps, ownerState, slotState) {\n if (typeof componentProps === 'function') {\n return componentProps(ownerState, slotState);\n }\n return componentProps;\n}","/**\n * Removes event handlers from the given object.\n * A field is considered an event handler if it is a function with a name beginning with `on`.\n *\n * @param object Object to remove event handlers from.\n * @returns Object with event handlers removed.\n */\nexport function omitEventHandlers(object) {\n if (object === undefined) {\n return {};\n }\n const result = {};\n Object.keys(object).filter(prop => !(prop.match(/^on[A-Z]/) && typeof object[prop] === 'function')).forEach(prop => {\n result[prop] = object[prop];\n });\n return result;\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport clsx from 'clsx';\nimport { extractEventHandlers } from './extractEventHandlers';\nimport { omitEventHandlers } from './omitEventHandlers';\n/**\n * Merges the slot component internal props (usually coming from a hook)\n * with the externally provided ones.\n *\n * The merge order is (the latter overrides the former):\n * 1. The internal props (specified as a getter function to work with get*Props hook result)\n * 2. Additional props (specified internally on a Base UI component)\n * 3. External props specified on the owner component. These should only be used on a root slot.\n * 4. External props specified in the `slotProps.*` prop.\n * 5. The `className` prop - combined from all the above.\n * @param parameters\n * @returns\n */\nexport function mergeSlotProps(parameters) {\n const {\n getSlotProps,\n additionalProps,\n externalSlotProps,\n externalForwardedProps,\n className\n } = parameters;\n if (!getSlotProps) {\n // The simpler case - getSlotProps is not defined, so no internal event handlers are defined,\n // so we can simply merge all the props without having to worry about extracting event handlers.\n const joinedClasses = clsx(additionalProps == null ? void 0 : additionalProps.className, className, externalForwardedProps == null ? void 0 : externalForwardedProps.className, externalSlotProps == null ? void 0 : externalSlotProps.className);\n const mergedStyle = _extends({}, additionalProps == null ? void 0 : additionalProps.style, externalForwardedProps == null ? void 0 : externalForwardedProps.style, externalSlotProps == null ? void 0 : externalSlotProps.style);\n const props = _extends({}, additionalProps, externalForwardedProps, externalSlotProps);\n if (joinedClasses.length > 0) {\n props.className = joinedClasses;\n }\n if (Object.keys(mergedStyle).length > 0) {\n props.style = mergedStyle;\n }\n return {\n props,\n internalRef: undefined\n };\n }\n\n // In this case, getSlotProps is responsible for calling the external event handlers.\n // We don't need to include them in the merged props because of this.\n\n const eventHandlers = extractEventHandlers(_extends({}, externalForwardedProps, externalSlotProps));\n const componentsPropsWithoutEventHandlers = omitEventHandlers(externalSlotProps);\n const otherPropsWithoutEventHandlers = omitEventHandlers(externalForwardedProps);\n const internalSlotProps = getSlotProps(eventHandlers);\n\n // The order of classes is important here.\n // Emotion (that we use in libraries consuming Base UI) depends on this order\n // to properly override style. It requires the most important classes to be last\n // (see https://github.com/mui/material-ui/pull/33205) for the related discussion.\n const joinedClasses = clsx(internalSlotProps == null ? void 0 : internalSlotProps.className, additionalProps == null ? void 0 : additionalProps.className, className, externalForwardedProps == null ? void 0 : externalForwardedProps.className, externalSlotProps == null ? void 0 : externalSlotProps.className);\n const mergedStyle = _extends({}, internalSlotProps == null ? void 0 : internalSlotProps.style, additionalProps == null ? void 0 : additionalProps.style, externalForwardedProps == null ? void 0 : externalForwardedProps.style, externalSlotProps == null ? void 0 : externalSlotProps.style);\n const props = _extends({}, internalSlotProps, additionalProps, otherPropsWithoutEventHandlers, componentsPropsWithoutEventHandlers);\n if (joinedClasses.length > 0) {\n props.className = joinedClasses;\n }\n if (Object.keys(mergedStyle).length > 0) {\n props.style = mergedStyle;\n }\n return {\n props,\n internalRef: internalSlotProps.ref\n };\n}","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"elementType\", \"externalSlotProps\", \"ownerState\", \"skipResolvingSlotProps\"];\nimport { unstable_useForkRef as useForkRef } from '@mui/utils';\nimport { appendOwnerState } from './appendOwnerState';\nimport { mergeSlotProps } from './mergeSlotProps';\nimport { resolveComponentProps } from './resolveComponentProps';\n/**\n * @ignore - do not document.\n * Builds the props to be passed into the slot of an unstyled component.\n * It merges the internal props of the component with the ones supplied by the user, allowing to customize the behavior.\n * If the slot component is not a host component, it also merges in the `ownerState`.\n *\n * @param parameters.getSlotProps - A function that returns the props to be passed to the slot component.\n */\nexport function useSlotProps(parameters) {\n var _parameters$additiona;\n const {\n elementType,\n externalSlotProps,\n ownerState,\n skipResolvingSlotProps = false\n } = parameters,\n rest = _objectWithoutPropertiesLoose(parameters, _excluded);\n const resolvedComponentsProps = skipResolvingSlotProps ? {} : resolveComponentProps(externalSlotProps, ownerState);\n const {\n props: mergedProps,\n internalRef\n } = mergeSlotProps(_extends({}, rest, {\n externalSlotProps: resolvedComponentsProps\n }));\n const ref = useForkRef(internalRef, resolvedComponentsProps == null ? void 0 : resolvedComponentsProps.ref, (_parameters$additiona = parameters.additionalProps) == null ? void 0 : _parameters$additiona.ref);\n const props = appendOwnerState(elementType, _extends({}, mergedProps, {\n ref\n }), ownerState);\n return props;\n}","import { globalStateClasses } from '@mui/utils/generateUtilityClass';\nconst GLOBAL_CLASS_PREFIX = 'base';\nfunction buildStateClass(state) {\n return `${GLOBAL_CLASS_PREFIX}--${state}`;\n}\nfunction buildSlotClass(componentName, slot) {\n return `${GLOBAL_CLASS_PREFIX}-${componentName}-${slot}`;\n}\nexport function generateUtilityClass(componentName, slot) {\n const globalStateClass = globalStateClasses[slot];\n return globalStateClass ? buildStateClass(globalStateClass) : buildSlotClass(componentName, slot);\n}\nexport function isGlobalState(slot) {\n return globalStateClasses[slot] !== undefined;\n}","import { generateUtilityClass } from '../generateUtilityClass';\nexport function generateUtilityClasses(componentName, slots) {\n const result = {};\n slots.forEach(slot => {\n result[slot] = generateUtilityClass(componentName, slot);\n });\n return result;\n}","'use client';\n\nimport * as React from 'react';\nimport * as ReactDOM from 'react-dom';\nimport PropTypes from 'prop-types';\nimport { exactProp, HTMLElementType, unstable_useEnhancedEffect as useEnhancedEffect, unstable_useForkRef as useForkRef, unstable_setRef as setRef } from '@mui/utils';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nfunction getContainer(container) {\n return typeof container === 'function' ? container() : container;\n}\n\n/**\n * Portals provide a first-class way to render children into a DOM node\n * that exists outside the DOM hierarchy of the parent component.\n *\n * Demos:\n *\n * - [Portal](https://mui.com/base-ui/react-portal/)\n *\n * API:\n *\n * - [Portal API](https://mui.com/base-ui/react-portal/components-api/#portal)\n */\nconst Portal = /*#__PURE__*/React.forwardRef(function Portal(props, forwardedRef) {\n const {\n children,\n container,\n disablePortal = false\n } = props;\n const [mountNode, setMountNode] = React.useState(null);\n // @ts-expect-error TODO upstream fix\n const handleRef = useForkRef( /*#__PURE__*/React.isValidElement(children) ? children.ref : null, forwardedRef);\n useEnhancedEffect(() => {\n if (!disablePortal) {\n setMountNode(getContainer(container) || document.body);\n }\n }, [container, disablePortal]);\n useEnhancedEffect(() => {\n if (mountNode && !disablePortal) {\n setRef(forwardedRef, mountNode);\n return () => {\n setRef(forwardedRef, null);\n };\n }\n return undefined;\n }, [forwardedRef, mountNode, disablePortal]);\n if (disablePortal) {\n if ( /*#__PURE__*/React.isValidElement(children)) {\n const newProps = {\n ref: handleRef\n };\n return /*#__PURE__*/React.cloneElement(children, newProps);\n }\n return /*#__PURE__*/_jsx(React.Fragment, {\n children: children\n });\n }\n return /*#__PURE__*/_jsx(React.Fragment, {\n children: mountNode ? /*#__PURE__*/ReactDOM.createPortal(children, mountNode) : mountNode\n });\n});\nprocess.env.NODE_ENV !== \"production\" ? Portal.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * The children to render into the `container`.\n */\n children: PropTypes.node,\n /**\n * An HTML element or function that returns one.\n * The `container` will have the portal children appended to it.\n *\n * You can also provide a callback, which is called in a React layout effect.\n * This lets you set the container from a ref, and also makes server-side rendering possible.\n *\n * By default, it uses the body of the top-level document object,\n * so it's simply `document.body` most of the time.\n */\n container: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.func]),\n /**\n * The `children` will be under the DOM hierarchy of the parent component.\n * @default false\n */\n disablePortal: PropTypes.bool\n} : void 0;\nif (process.env.NODE_ENV !== 'production') {\n // eslint-disable-next-line\n Portal['propTypes' + ''] = exactProp(Portal.propTypes);\n}\nexport { Portal };","export var top = 'top';\nexport var bottom = 'bottom';\nexport var right = 'right';\nexport var left = 'left';\nexport var auto = 'auto';\nexport var basePlacements = [top, bottom, right, left];\nexport var start = 'start';\nexport var end = 'end';\nexport var clippingParents = 'clippingParents';\nexport var viewport = 'viewport';\nexport var popper = 'popper';\nexport var reference = 'reference';\nexport var variationPlacements = /*#__PURE__*/basePlacements.reduce(function (acc, placement) {\n return acc.concat([placement + \"-\" + start, placement + \"-\" + end]);\n}, []);\nexport var placements = /*#__PURE__*/[].concat(basePlacements, [auto]).reduce(function (acc, placement) {\n return acc.concat([placement, placement + \"-\" + start, placement + \"-\" + end]);\n}, []); // modifiers that need to read the DOM\n\nexport var beforeRead = 'beforeRead';\nexport var read = 'read';\nexport var afterRead = 'afterRead'; // pure-logic modifiers\n\nexport var beforeMain = 'beforeMain';\nexport var main = 'main';\nexport var afterMain = 'afterMain'; // modifier with the purpose to write to the DOM (or write into a framework state)\n\nexport var beforeWrite = 'beforeWrite';\nexport var write = 'write';\nexport var afterWrite = 'afterWrite';\nexport var modifierPhases = [beforeRead, read, afterRead, beforeMain, main, afterMain, beforeWrite, write, afterWrite];","export default function getNodeName(element) {\n return element ? (element.nodeName || '').toLowerCase() : null;\n}","export default function getWindow(node) {\n if (node == null) {\n return window;\n }\n\n if (node.toString() !== '[object Window]') {\n var ownerDocument = node.ownerDocument;\n return ownerDocument ? ownerDocument.defaultView || window : window;\n }\n\n return node;\n}","import getWindow from \"./getWindow.js\";\n\nfunction isElement(node) {\n var OwnElement = getWindow(node).Element;\n return node instanceof OwnElement || node instanceof Element;\n}\n\nfunction isHTMLElement(node) {\n var OwnElement = getWindow(node).HTMLElement;\n return node instanceof OwnElement || node instanceof HTMLElement;\n}\n\nfunction isShadowRoot(node) {\n // IE 11 has no ShadowRoot\n if (typeof ShadowRoot === 'undefined') {\n return false;\n }\n\n var OwnElement = getWindow(node).ShadowRoot;\n return node instanceof OwnElement || node instanceof ShadowRoot;\n}\n\nexport { isElement, isHTMLElement, isShadowRoot };","import getNodeName from \"../dom-utils/getNodeName.js\";\nimport { isHTMLElement } from \"../dom-utils/instanceOf.js\"; // This modifier takes the styles prepared by the `computeStyles` modifier\n// and applies them to the HTMLElements such as popper and arrow\n\nfunction applyStyles(_ref) {\n var state = _ref.state;\n Object.keys(state.elements).forEach(function (name) {\n var style = state.styles[name] || {};\n var attributes = state.attributes[name] || {};\n var element = state.elements[name]; // arrow is optional + virtual elements\n\n if (!isHTMLElement(element) || !getNodeName(element)) {\n return;\n } // Flow doesn't support to extend this property, but it's the most\n // effective way to apply styles to an HTMLElement\n // $FlowFixMe[cannot-write]\n\n\n Object.assign(element.style, style);\n Object.keys(attributes).forEach(function (name) {\n var value = attributes[name];\n\n if (value === false) {\n element.removeAttribute(name);\n } else {\n element.setAttribute(name, value === true ? '' : value);\n }\n });\n });\n}\n\nfunction effect(_ref2) {\n var state = _ref2.state;\n var initialStyles = {\n popper: {\n position: state.options.strategy,\n left: '0',\n top: '0',\n margin: '0'\n },\n arrow: {\n position: 'absolute'\n },\n reference: {}\n };\n Object.assign(state.elements.popper.style, initialStyles.popper);\n state.styles = initialStyles;\n\n if (state.elements.arrow) {\n Object.assign(state.elements.arrow.style, initialStyles.arrow);\n }\n\n return function () {\n Object.keys(state.elements).forEach(function (name) {\n var element = state.elements[name];\n var attributes = state.attributes[name] || {};\n var styleProperties = Object.keys(state.styles.hasOwnProperty(name) ? state.styles[name] : initialStyles[name]); // Set all values to an empty string to unset them\n\n var style = styleProperties.reduce(function (style, property) {\n style[property] = '';\n return style;\n }, {}); // arrow is optional + virtual elements\n\n if (!isHTMLElement(element) || !getNodeName(element)) {\n return;\n }\n\n Object.assign(element.style, style);\n Object.keys(attributes).forEach(function (attribute) {\n element.removeAttribute(attribute);\n });\n });\n };\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'applyStyles',\n enabled: true,\n phase: 'write',\n fn: applyStyles,\n effect: effect,\n requires: ['computeStyles']\n};","import { auto } from \"../enums.js\";\nexport default function getBasePlacement(placement) {\n return placement.split('-')[0];\n}","export var max = Math.max;\nexport var min = Math.min;\nexport var round = Math.round;","export default function getUAString() {\n var uaData = navigator.userAgentData;\n\n if (uaData != null && uaData.brands && Array.isArray(uaData.brands)) {\n return uaData.brands.map(function (item) {\n return item.brand + \"/\" + item.version;\n }).join(' ');\n }\n\n return navigator.userAgent;\n}","import getUAString from \"../utils/userAgent.js\";\nexport default function isLayoutViewport() {\n return !/^((?!chrome|android).)*safari/i.test(getUAString());\n}","import { isElement, isHTMLElement } from \"./instanceOf.js\";\nimport { round } from \"../utils/math.js\";\nimport getWindow from \"./getWindow.js\";\nimport isLayoutViewport from \"./isLayoutViewport.js\";\nexport default function getBoundingClientRect(element, includeScale, isFixedStrategy) {\n if (includeScale === void 0) {\n includeScale = false;\n }\n\n if (isFixedStrategy === void 0) {\n isFixedStrategy = false;\n }\n\n var clientRect = element.getBoundingClientRect();\n var scaleX = 1;\n var scaleY = 1;\n\n if (includeScale && isHTMLElement(element)) {\n scaleX = element.offsetWidth > 0 ? round(clientRect.width) / element.offsetWidth || 1 : 1;\n scaleY = element.offsetHeight > 0 ? round(clientRect.height) / element.offsetHeight || 1 : 1;\n }\n\n var _ref = isElement(element) ? getWindow(element) : window,\n visualViewport = _ref.visualViewport;\n\n var addVisualOffsets = !isLayoutViewport() && isFixedStrategy;\n var x = (clientRect.left + (addVisualOffsets && visualViewport ? visualViewport.offsetLeft : 0)) / scaleX;\n var y = (clientRect.top + (addVisualOffsets && visualViewport ? visualViewport.offsetTop : 0)) / scaleY;\n var width = clientRect.width / scaleX;\n var height = clientRect.height / scaleY;\n return {\n width: width,\n height: height,\n top: y,\n right: x + width,\n bottom: y + height,\n left: x,\n x: x,\n y: y\n };\n}","import getBoundingClientRect from \"./getBoundingClientRect.js\"; // Returns the layout rect of an element relative to its offsetParent. Layout\n// means it doesn't take into account transforms.\n\nexport default function getLayoutRect(element) {\n var clientRect = getBoundingClientRect(element); // Use the clientRect sizes if it's not been transformed.\n // Fixes https://github.com/popperjs/popper-core/issues/1223\n\n var width = element.offsetWidth;\n var height = element.offsetHeight;\n\n if (Math.abs(clientRect.width - width) <= 1) {\n width = clientRect.width;\n }\n\n if (Math.abs(clientRect.height - height) <= 1) {\n height = clientRect.height;\n }\n\n return {\n x: element.offsetLeft,\n y: element.offsetTop,\n width: width,\n height: height\n };\n}","import { isShadowRoot } from \"./instanceOf.js\";\nexport default function contains(parent, child) {\n var rootNode = child.getRootNode && child.getRootNode(); // First, attempt with faster native method\n\n if (parent.contains(child)) {\n return true;\n } // then fallback to custom implementation with Shadow DOM support\n else if (rootNode && isShadowRoot(rootNode)) {\n var next = child;\n\n do {\n if (next && parent.isSameNode(next)) {\n return true;\n } // $FlowFixMe[prop-missing]: need a better way to handle this...\n\n\n next = next.parentNode || next.host;\n } while (next);\n } // Give up, the result is false\n\n\n return false;\n}","import getWindow from \"./getWindow.js\";\nexport default function getComputedStyle(element) {\n return getWindow(element).getComputedStyle(element);\n}","import getNodeName from \"./getNodeName.js\";\nexport default function isTableElement(element) {\n return ['table', 'td', 'th'].indexOf(getNodeName(element)) >= 0;\n}","import { isElement } from \"./instanceOf.js\";\nexport default function getDocumentElement(element) {\n // $FlowFixMe[incompatible-return]: assume body is always available\n return ((isElement(element) ? element.ownerDocument : // $FlowFixMe[prop-missing]\n element.document) || window.document).documentElement;\n}","import getNodeName from \"./getNodeName.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport { isShadowRoot } from \"./instanceOf.js\";\nexport default function getParentNode(element) {\n if (getNodeName(element) === 'html') {\n return element;\n }\n\n return (// this is a quicker (but less type safe) way to save quite some bytes from the bundle\n // $FlowFixMe[incompatible-return]\n // $FlowFixMe[prop-missing]\n element.assignedSlot || // step into the shadow DOM of the parent of a slotted node\n element.parentNode || ( // DOM Element detected\n isShadowRoot(element) ? element.host : null) || // ShadowRoot detected\n // $FlowFixMe[incompatible-call]: HTMLElement is a Node\n getDocumentElement(element) // fallback\n\n );\n}","import getWindow from \"./getWindow.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport getComputedStyle from \"./getComputedStyle.js\";\nimport { isHTMLElement, isShadowRoot } from \"./instanceOf.js\";\nimport isTableElement from \"./isTableElement.js\";\nimport getParentNode from \"./getParentNode.js\";\nimport getUAString from \"../utils/userAgent.js\";\n\nfunction getTrueOffsetParent(element) {\n if (!isHTMLElement(element) || // https://github.com/popperjs/popper-core/issues/837\n getComputedStyle(element).position === 'fixed') {\n return null;\n }\n\n return element.offsetParent;\n} // `.offsetParent` reports `null` for fixed elements, while absolute elements\n// return the containing block\n\n\nfunction getContainingBlock(element) {\n var isFirefox = /firefox/i.test(getUAString());\n var isIE = /Trident/i.test(getUAString());\n\n if (isIE && isHTMLElement(element)) {\n // In IE 9, 10 and 11 fixed elements containing block is always established by the viewport\n var elementCss = getComputedStyle(element);\n\n if (elementCss.position === 'fixed') {\n return null;\n }\n }\n\n var currentNode = getParentNode(element);\n\n if (isShadowRoot(currentNode)) {\n currentNode = currentNode.host;\n }\n\n while (isHTMLElement(currentNode) && ['html', 'body'].indexOf(getNodeName(currentNode)) < 0) {\n var css = getComputedStyle(currentNode); // This is non-exhaustive but covers the most common CSS properties that\n // create a containing block.\n // https://developer.mozilla.org/en-US/docs/Web/CSS/Containing_block#identifying_the_containing_block\n\n if (css.transform !== 'none' || css.perspective !== 'none' || css.contain === 'paint' || ['transform', 'perspective'].indexOf(css.willChange) !== -1 || isFirefox && css.willChange === 'filter' || isFirefox && css.filter && css.filter !== 'none') {\n return currentNode;\n } else {\n currentNode = currentNode.parentNode;\n }\n }\n\n return null;\n} // Gets the closest ancestor positioned element. Handles some edge cases,\n// such as table ancestors and cross browser bugs.\n\n\nexport default function getOffsetParent(element) {\n var window = getWindow(element);\n var offsetParent = getTrueOffsetParent(element);\n\n while (offsetParent && isTableElement(offsetParent) && getComputedStyle(offsetParent).position === 'static') {\n offsetParent = getTrueOffsetParent(offsetParent);\n }\n\n if (offsetParent && (getNodeName(offsetParent) === 'html' || getNodeName(offsetParent) === 'body' && getComputedStyle(offsetParent).position === 'static')) {\n return window;\n }\n\n return offsetParent || getContainingBlock(element) || window;\n}","export default function getMainAxisFromPlacement(placement) {\n return ['top', 'bottom'].indexOf(placement) >= 0 ? 'x' : 'y';\n}","import { max as mathMax, min as mathMin } from \"./math.js\";\nexport function within(min, value, max) {\n return mathMax(min, mathMin(value, max));\n}\nexport function withinMaxClamp(min, value, max) {\n var v = within(min, value, max);\n return v > max ? max : v;\n}","export default function getFreshSideObject() {\n return {\n top: 0,\n right: 0,\n bottom: 0,\n left: 0\n };\n}","import getFreshSideObject from \"./getFreshSideObject.js\";\nexport default function mergePaddingObject(paddingObject) {\n return Object.assign({}, getFreshSideObject(), paddingObject);\n}","export default function expandToHashMap(value, keys) {\n return keys.reduce(function (hashMap, key) {\n hashMap[key] = value;\n return hashMap;\n }, {});\n}","import getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getLayoutRect from \"../dom-utils/getLayoutRect.js\";\nimport contains from \"../dom-utils/contains.js\";\nimport getOffsetParent from \"../dom-utils/getOffsetParent.js\";\nimport getMainAxisFromPlacement from \"../utils/getMainAxisFromPlacement.js\";\nimport { within } from \"../utils/within.js\";\nimport mergePaddingObject from \"../utils/mergePaddingObject.js\";\nimport expandToHashMap from \"../utils/expandToHashMap.js\";\nimport { left, right, basePlacements, top, bottom } from \"../enums.js\"; // eslint-disable-next-line import/no-unused-modules\n\nvar toPaddingObject = function toPaddingObject(padding, state) {\n padding = typeof padding === 'function' ? padding(Object.assign({}, state.rects, {\n placement: state.placement\n })) : padding;\n return mergePaddingObject(typeof padding !== 'number' ? padding : expandToHashMap(padding, basePlacements));\n};\n\nfunction arrow(_ref) {\n var _state$modifiersData$;\n\n var state = _ref.state,\n name = _ref.name,\n options = _ref.options;\n var arrowElement = state.elements.arrow;\n var popperOffsets = state.modifiersData.popperOffsets;\n var basePlacement = getBasePlacement(state.placement);\n var axis = getMainAxisFromPlacement(basePlacement);\n var isVertical = [left, right].indexOf(basePlacement) >= 0;\n var len = isVertical ? 'height' : 'width';\n\n if (!arrowElement || !popperOffsets) {\n return;\n }\n\n var paddingObject = toPaddingObject(options.padding, state);\n var arrowRect = getLayoutRect(arrowElement);\n var minProp = axis === 'y' ? top : left;\n var maxProp = axis === 'y' ? bottom : right;\n var endDiff = state.rects.reference[len] + state.rects.reference[axis] - popperOffsets[axis] - state.rects.popper[len];\n var startDiff = popperOffsets[axis] - state.rects.reference[axis];\n var arrowOffsetParent = getOffsetParent(arrowElement);\n var clientSize = arrowOffsetParent ? axis === 'y' ? arrowOffsetParent.clientHeight || 0 : arrowOffsetParent.clientWidth || 0 : 0;\n var centerToReference = endDiff / 2 - startDiff / 2; // Make sure the arrow doesn't overflow the popper if the center point is\n // outside of the popper bounds\n\n var min = paddingObject[minProp];\n var max = clientSize - arrowRect[len] - paddingObject[maxProp];\n var center = clientSize / 2 - arrowRect[len] / 2 + centerToReference;\n var offset = within(min, center, max); // Prevents breaking syntax highlighting...\n\n var axisProp = axis;\n state.modifiersData[name] = (_state$modifiersData$ = {}, _state$modifiersData$[axisProp] = offset, _state$modifiersData$.centerOffset = offset - center, _state$modifiersData$);\n}\n\nfunction effect(_ref2) {\n var state = _ref2.state,\n options = _ref2.options;\n var _options$element = options.element,\n arrowElement = _options$element === void 0 ? '[data-popper-arrow]' : _options$element;\n\n if (arrowElement == null) {\n return;\n } // CSS selector\n\n\n if (typeof arrowElement === 'string') {\n arrowElement = state.elements.popper.querySelector(arrowElement);\n\n if (!arrowElement) {\n return;\n }\n }\n\n if (!contains(state.elements.popper, arrowElement)) {\n return;\n }\n\n state.elements.arrow = arrowElement;\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'arrow',\n enabled: true,\n phase: 'main',\n fn: arrow,\n effect: effect,\n requires: ['popperOffsets'],\n requiresIfExists: ['preventOverflow']\n};","export default function getVariation(placement) {\n return placement.split('-')[1];\n}","import { top, left, right, bottom, end } from \"../enums.js\";\nimport getOffsetParent from \"../dom-utils/getOffsetParent.js\";\nimport getWindow from \"../dom-utils/getWindow.js\";\nimport getDocumentElement from \"../dom-utils/getDocumentElement.js\";\nimport getComputedStyle from \"../dom-utils/getComputedStyle.js\";\nimport getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getVariation from \"../utils/getVariation.js\";\nimport { round } from \"../utils/math.js\"; // eslint-disable-next-line import/no-unused-modules\n\nvar unsetSides = {\n top: 'auto',\n right: 'auto',\n bottom: 'auto',\n left: 'auto'\n}; // Round the offsets to the nearest suitable subpixel based on the DPR.\n// Zooming can change the DPR, but it seems to report a value that will\n// cleanly divide the values into the appropriate subpixels.\n\nfunction roundOffsetsByDPR(_ref, win) {\n var x = _ref.x,\n y = _ref.y;\n var dpr = win.devicePixelRatio || 1;\n return {\n x: round(x * dpr) / dpr || 0,\n y: round(y * dpr) / dpr || 0\n };\n}\n\nexport function mapToStyles(_ref2) {\n var _Object$assign2;\n\n var popper = _ref2.popper,\n popperRect = _ref2.popperRect,\n placement = _ref2.placement,\n variation = _ref2.variation,\n offsets = _ref2.offsets,\n position = _ref2.position,\n gpuAcceleration = _ref2.gpuAcceleration,\n adaptive = _ref2.adaptive,\n roundOffsets = _ref2.roundOffsets,\n isFixed = _ref2.isFixed;\n var _offsets$x = offsets.x,\n x = _offsets$x === void 0 ? 0 : _offsets$x,\n _offsets$y = offsets.y,\n y = _offsets$y === void 0 ? 0 : _offsets$y;\n\n var _ref3 = typeof roundOffsets === 'function' ? roundOffsets({\n x: x,\n y: y\n }) : {\n x: x,\n y: y\n };\n\n x = _ref3.x;\n y = _ref3.y;\n var hasX = offsets.hasOwnProperty('x');\n var hasY = offsets.hasOwnProperty('y');\n var sideX = left;\n var sideY = top;\n var win = window;\n\n if (adaptive) {\n var offsetParent = getOffsetParent(popper);\n var heightProp = 'clientHeight';\n var widthProp = 'clientWidth';\n\n if (offsetParent === getWindow(popper)) {\n offsetParent = getDocumentElement(popper);\n\n if (getComputedStyle(offsetParent).position !== 'static' && position === 'absolute') {\n heightProp = 'scrollHeight';\n widthProp = 'scrollWidth';\n }\n } // $FlowFixMe[incompatible-cast]: force type refinement, we compare offsetParent with window above, but Flow doesn't detect it\n\n\n offsetParent = offsetParent;\n\n if (placement === top || (placement === left || placement === right) && variation === end) {\n sideY = bottom;\n var offsetY = isFixed && offsetParent === win && win.visualViewport ? win.visualViewport.height : // $FlowFixMe[prop-missing]\n offsetParent[heightProp];\n y -= offsetY - popperRect.height;\n y *= gpuAcceleration ? 1 : -1;\n }\n\n if (placement === left || (placement === top || placement === bottom) && variation === end) {\n sideX = right;\n var offsetX = isFixed && offsetParent === win && win.visualViewport ? win.visualViewport.width : // $FlowFixMe[prop-missing]\n offsetParent[widthProp];\n x -= offsetX - popperRect.width;\n x *= gpuAcceleration ? 1 : -1;\n }\n }\n\n var commonStyles = Object.assign({\n position: position\n }, adaptive && unsetSides);\n\n var _ref4 = roundOffsets === true ? roundOffsetsByDPR({\n x: x,\n y: y\n }, getWindow(popper)) : {\n x: x,\n y: y\n };\n\n x = _ref4.x;\n y = _ref4.y;\n\n if (gpuAcceleration) {\n var _Object$assign;\n\n return Object.assign({}, commonStyles, (_Object$assign = {}, _Object$assign[sideY] = hasY ? '0' : '', _Object$assign[sideX] = hasX ? '0' : '', _Object$assign.transform = (win.devicePixelRatio || 1) <= 1 ? \"translate(\" + x + \"px, \" + y + \"px)\" : \"translate3d(\" + x + \"px, \" + y + \"px, 0)\", _Object$assign));\n }\n\n return Object.assign({}, commonStyles, (_Object$assign2 = {}, _Object$assign2[sideY] = hasY ? y + \"px\" : '', _Object$assign2[sideX] = hasX ? x + \"px\" : '', _Object$assign2.transform = '', _Object$assign2));\n}\n\nfunction computeStyles(_ref5) {\n var state = _ref5.state,\n options = _ref5.options;\n var _options$gpuAccelerat = options.gpuAcceleration,\n gpuAcceleration = _options$gpuAccelerat === void 0 ? true : _options$gpuAccelerat,\n _options$adaptive = options.adaptive,\n adaptive = _options$adaptive === void 0 ? true : _options$adaptive,\n _options$roundOffsets = options.roundOffsets,\n roundOffsets = _options$roundOffsets === void 0 ? true : _options$roundOffsets;\n var commonStyles = {\n placement: getBasePlacement(state.placement),\n variation: getVariation(state.placement),\n popper: state.elements.popper,\n popperRect: state.rects.popper,\n gpuAcceleration: gpuAcceleration,\n isFixed: state.options.strategy === 'fixed'\n };\n\n if (state.modifiersData.popperOffsets != null) {\n state.styles.popper = Object.assign({}, state.styles.popper, mapToStyles(Object.assign({}, commonStyles, {\n offsets: state.modifiersData.popperOffsets,\n position: state.options.strategy,\n adaptive: adaptive,\n roundOffsets: roundOffsets\n })));\n }\n\n if (state.modifiersData.arrow != null) {\n state.styles.arrow = Object.assign({}, state.styles.arrow, mapToStyles(Object.assign({}, commonStyles, {\n offsets: state.modifiersData.arrow,\n position: 'absolute',\n adaptive: false,\n roundOffsets: roundOffsets\n })));\n }\n\n state.attributes.popper = Object.assign({}, state.attributes.popper, {\n 'data-popper-placement': state.placement\n });\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'computeStyles',\n enabled: true,\n phase: 'beforeWrite',\n fn: computeStyles,\n data: {}\n};","import getWindow from \"../dom-utils/getWindow.js\"; // eslint-disable-next-line import/no-unused-modules\n\nvar passive = {\n passive: true\n};\n\nfunction effect(_ref) {\n var state = _ref.state,\n instance = _ref.instance,\n options = _ref.options;\n var _options$scroll = options.scroll,\n scroll = _options$scroll === void 0 ? true : _options$scroll,\n _options$resize = options.resize,\n resize = _options$resize === void 0 ? true : _options$resize;\n var window = getWindow(state.elements.popper);\n var scrollParents = [].concat(state.scrollParents.reference, state.scrollParents.popper);\n\n if (scroll) {\n scrollParents.forEach(function (scrollParent) {\n scrollParent.addEventListener('scroll', instance.update, passive);\n });\n }\n\n if (resize) {\n window.addEventListener('resize', instance.update, passive);\n }\n\n return function () {\n if (scroll) {\n scrollParents.forEach(function (scrollParent) {\n scrollParent.removeEventListener('scroll', instance.update, passive);\n });\n }\n\n if (resize) {\n window.removeEventListener('resize', instance.update, passive);\n }\n };\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'eventListeners',\n enabled: true,\n phase: 'write',\n fn: function fn() {},\n effect: effect,\n data: {}\n};","var hash = {\n left: 'right',\n right: 'left',\n bottom: 'top',\n top: 'bottom'\n};\nexport default function getOppositePlacement(placement) {\n return placement.replace(/left|right|bottom|top/g, function (matched) {\n return hash[matched];\n });\n}","var hash = {\n start: 'end',\n end: 'start'\n};\nexport default function getOppositeVariationPlacement(placement) {\n return placement.replace(/start|end/g, function (matched) {\n return hash[matched];\n });\n}","import getWindow from \"./getWindow.js\";\nexport default function getWindowScroll(node) {\n var win = getWindow(node);\n var scrollLeft = win.pageXOffset;\n var scrollTop = win.pageYOffset;\n return {\n scrollLeft: scrollLeft,\n scrollTop: scrollTop\n };\n}","import getBoundingClientRect from \"./getBoundingClientRect.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport getWindowScroll from \"./getWindowScroll.js\";\nexport default function getWindowScrollBarX(element) {\n // If has a CSS width greater than the viewport, then this will be\n // incorrect for RTL.\n // Popper 1 is broken in this case and never had a bug report so let's assume\n // it's not an issue. I don't think anyone ever specifies width on \n // anyway.\n // Browsers where the left scrollbar doesn't cause an issue report `0` for\n // this (e.g. Edge 2019, IE11, Safari)\n return getBoundingClientRect(getDocumentElement(element)).left + getWindowScroll(element).scrollLeft;\n}","import getWindow from \"./getWindow.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport getWindowScrollBarX from \"./getWindowScrollBarX.js\";\nimport isLayoutViewport from \"./isLayoutViewport.js\";\nexport default function getViewportRect(element, strategy) {\n var win = getWindow(element);\n var html = getDocumentElement(element);\n var visualViewport = win.visualViewport;\n var width = html.clientWidth;\n var height = html.clientHeight;\n var x = 0;\n var y = 0;\n\n if (visualViewport) {\n width = visualViewport.width;\n height = visualViewport.height;\n var layoutViewport = isLayoutViewport();\n\n if (layoutViewport || !layoutViewport && strategy === 'fixed') {\n x = visualViewport.offsetLeft;\n y = visualViewport.offsetTop;\n }\n }\n\n return {\n width: width,\n height: height,\n x: x + getWindowScrollBarX(element),\n y: y\n };\n}","import getDocumentElement from \"./getDocumentElement.js\";\nimport getComputedStyle from \"./getComputedStyle.js\";\nimport getWindowScrollBarX from \"./getWindowScrollBarX.js\";\nimport getWindowScroll from \"./getWindowScroll.js\";\nimport { max } from \"../utils/math.js\"; // Gets the entire size of the scrollable document area, even extending outside\n// of the `` and `` rect bounds if horizontally scrollable\n\nexport default function getDocumentRect(element) {\n var _element$ownerDocumen;\n\n var html = getDocumentElement(element);\n var winScroll = getWindowScroll(element);\n var body = (_element$ownerDocumen = element.ownerDocument) == null ? void 0 : _element$ownerDocumen.body;\n var width = max(html.scrollWidth, html.clientWidth, body ? body.scrollWidth : 0, body ? body.clientWidth : 0);\n var height = max(html.scrollHeight, html.clientHeight, body ? body.scrollHeight : 0, body ? body.clientHeight : 0);\n var x = -winScroll.scrollLeft + getWindowScrollBarX(element);\n var y = -winScroll.scrollTop;\n\n if (getComputedStyle(body || html).direction === 'rtl') {\n x += max(html.clientWidth, body ? body.clientWidth : 0) - width;\n }\n\n return {\n width: width,\n height: height,\n x: x,\n y: y\n };\n}","import getComputedStyle from \"./getComputedStyle.js\";\nexport default function isScrollParent(element) {\n // Firefox wants us to check `-x` and `-y` variations as well\n var _getComputedStyle = getComputedStyle(element),\n overflow = _getComputedStyle.overflow,\n overflowX = _getComputedStyle.overflowX,\n overflowY = _getComputedStyle.overflowY;\n\n return /auto|scroll|overlay|hidden/.test(overflow + overflowY + overflowX);\n}","import getParentNode from \"./getParentNode.js\";\nimport isScrollParent from \"./isScrollParent.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport { isHTMLElement } from \"./instanceOf.js\";\nexport default function getScrollParent(node) {\n if (['html', 'body', '#document'].indexOf(getNodeName(node)) >= 0) {\n // $FlowFixMe[incompatible-return]: assume body is always available\n return node.ownerDocument.body;\n }\n\n if (isHTMLElement(node) && isScrollParent(node)) {\n return node;\n }\n\n return getScrollParent(getParentNode(node));\n}","import getScrollParent from \"./getScrollParent.js\";\nimport getParentNode from \"./getParentNode.js\";\nimport getWindow from \"./getWindow.js\";\nimport isScrollParent from \"./isScrollParent.js\";\n/*\ngiven a DOM element, return the list of all scroll parents, up the list of ancesors\nuntil we get to the top window object. This list is what we attach scroll listeners\nto, because if any of these parent elements scroll, we'll need to re-calculate the\nreference element's position.\n*/\n\nexport default function listScrollParents(element, list) {\n var _element$ownerDocumen;\n\n if (list === void 0) {\n list = [];\n }\n\n var scrollParent = getScrollParent(element);\n var isBody = scrollParent === ((_element$ownerDocumen = element.ownerDocument) == null ? void 0 : _element$ownerDocumen.body);\n var win = getWindow(scrollParent);\n var target = isBody ? [win].concat(win.visualViewport || [], isScrollParent(scrollParent) ? scrollParent : []) : scrollParent;\n var updatedList = list.concat(target);\n return isBody ? updatedList : // $FlowFixMe[incompatible-call]: isBody tells us target will be an HTMLElement here\n updatedList.concat(listScrollParents(getParentNode(target)));\n}","export default function rectToClientRect(rect) {\n return Object.assign({}, rect, {\n left: rect.x,\n top: rect.y,\n right: rect.x + rect.width,\n bottom: rect.y + rect.height\n });\n}","import { viewport } from \"../enums.js\";\nimport getViewportRect from \"./getViewportRect.js\";\nimport getDocumentRect from \"./getDocumentRect.js\";\nimport listScrollParents from \"./listScrollParents.js\";\nimport getOffsetParent from \"./getOffsetParent.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport getComputedStyle from \"./getComputedStyle.js\";\nimport { isElement, isHTMLElement } from \"./instanceOf.js\";\nimport getBoundingClientRect from \"./getBoundingClientRect.js\";\nimport getParentNode from \"./getParentNode.js\";\nimport contains from \"./contains.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport rectToClientRect from \"../utils/rectToClientRect.js\";\nimport { max, min } from \"../utils/math.js\";\n\nfunction getInnerBoundingClientRect(element, strategy) {\n var rect = getBoundingClientRect(element, false, strategy === 'fixed');\n rect.top = rect.top + element.clientTop;\n rect.left = rect.left + element.clientLeft;\n rect.bottom = rect.top + element.clientHeight;\n rect.right = rect.left + element.clientWidth;\n rect.width = element.clientWidth;\n rect.height = element.clientHeight;\n rect.x = rect.left;\n rect.y = rect.top;\n return rect;\n}\n\nfunction getClientRectFromMixedType(element, clippingParent, strategy) {\n return clippingParent === viewport ? rectToClientRect(getViewportRect(element, strategy)) : isElement(clippingParent) ? getInnerBoundingClientRect(clippingParent, strategy) : rectToClientRect(getDocumentRect(getDocumentElement(element)));\n} // A \"clipping parent\" is an overflowable container with the characteristic of\n// clipping (or hiding) overflowing elements with a position different from\n// `initial`\n\n\nfunction getClippingParents(element) {\n var clippingParents = listScrollParents(getParentNode(element));\n var canEscapeClipping = ['absolute', 'fixed'].indexOf(getComputedStyle(element).position) >= 0;\n var clipperElement = canEscapeClipping && isHTMLElement(element) ? getOffsetParent(element) : element;\n\n if (!isElement(clipperElement)) {\n return [];\n } // $FlowFixMe[incompatible-return]: https://github.com/facebook/flow/issues/1414\n\n\n return clippingParents.filter(function (clippingParent) {\n return isElement(clippingParent) && contains(clippingParent, clipperElement) && getNodeName(clippingParent) !== 'body';\n });\n} // Gets the maximum area that the element is visible in due to any number of\n// clipping parents\n\n\nexport default function getClippingRect(element, boundary, rootBoundary, strategy) {\n var mainClippingParents = boundary === 'clippingParents' ? getClippingParents(element) : [].concat(boundary);\n var clippingParents = [].concat(mainClippingParents, [rootBoundary]);\n var firstClippingParent = clippingParents[0];\n var clippingRect = clippingParents.reduce(function (accRect, clippingParent) {\n var rect = getClientRectFromMixedType(element, clippingParent, strategy);\n accRect.top = max(rect.top, accRect.top);\n accRect.right = min(rect.right, accRect.right);\n accRect.bottom = min(rect.bottom, accRect.bottom);\n accRect.left = max(rect.left, accRect.left);\n return accRect;\n }, getClientRectFromMixedType(element, firstClippingParent, strategy));\n clippingRect.width = clippingRect.right - clippingRect.left;\n clippingRect.height = clippingRect.bottom - clippingRect.top;\n clippingRect.x = clippingRect.left;\n clippingRect.y = clippingRect.top;\n return clippingRect;\n}","import getBasePlacement from \"./getBasePlacement.js\";\nimport getVariation from \"./getVariation.js\";\nimport getMainAxisFromPlacement from \"./getMainAxisFromPlacement.js\";\nimport { top, right, bottom, left, start, end } from \"../enums.js\";\nexport default function computeOffsets(_ref) {\n var reference = _ref.reference,\n element = _ref.element,\n placement = _ref.placement;\n var basePlacement = placement ? getBasePlacement(placement) : null;\n var variation = placement ? getVariation(placement) : null;\n var commonX = reference.x + reference.width / 2 - element.width / 2;\n var commonY = reference.y + reference.height / 2 - element.height / 2;\n var offsets;\n\n switch (basePlacement) {\n case top:\n offsets = {\n x: commonX,\n y: reference.y - element.height\n };\n break;\n\n case bottom:\n offsets = {\n x: commonX,\n y: reference.y + reference.height\n };\n break;\n\n case right:\n offsets = {\n x: reference.x + reference.width,\n y: commonY\n };\n break;\n\n case left:\n offsets = {\n x: reference.x - element.width,\n y: commonY\n };\n break;\n\n default:\n offsets = {\n x: reference.x,\n y: reference.y\n };\n }\n\n var mainAxis = basePlacement ? getMainAxisFromPlacement(basePlacement) : null;\n\n if (mainAxis != null) {\n var len = mainAxis === 'y' ? 'height' : 'width';\n\n switch (variation) {\n case start:\n offsets[mainAxis] = offsets[mainAxis] - (reference[len] / 2 - element[len] / 2);\n break;\n\n case end:\n offsets[mainAxis] = offsets[mainAxis] + (reference[len] / 2 - element[len] / 2);\n break;\n\n default:\n }\n }\n\n return offsets;\n}","import getClippingRect from \"../dom-utils/getClippingRect.js\";\nimport getDocumentElement from \"../dom-utils/getDocumentElement.js\";\nimport getBoundingClientRect from \"../dom-utils/getBoundingClientRect.js\";\nimport computeOffsets from \"./computeOffsets.js\";\nimport rectToClientRect from \"./rectToClientRect.js\";\nimport { clippingParents, reference, popper, bottom, top, right, basePlacements, viewport } from \"../enums.js\";\nimport { isElement } from \"../dom-utils/instanceOf.js\";\nimport mergePaddingObject from \"./mergePaddingObject.js\";\nimport expandToHashMap from \"./expandToHashMap.js\"; // eslint-disable-next-line import/no-unused-modules\n\nexport default function detectOverflow(state, options) {\n if (options === void 0) {\n options = {};\n }\n\n var _options = options,\n _options$placement = _options.placement,\n placement = _options$placement === void 0 ? state.placement : _options$placement,\n _options$strategy = _options.strategy,\n strategy = _options$strategy === void 0 ? state.strategy : _options$strategy,\n _options$boundary = _options.boundary,\n boundary = _options$boundary === void 0 ? clippingParents : _options$boundary,\n _options$rootBoundary = _options.rootBoundary,\n rootBoundary = _options$rootBoundary === void 0 ? viewport : _options$rootBoundary,\n _options$elementConte = _options.elementContext,\n elementContext = _options$elementConte === void 0 ? popper : _options$elementConte,\n _options$altBoundary = _options.altBoundary,\n altBoundary = _options$altBoundary === void 0 ? false : _options$altBoundary,\n _options$padding = _options.padding,\n padding = _options$padding === void 0 ? 0 : _options$padding;\n var paddingObject = mergePaddingObject(typeof padding !== 'number' ? padding : expandToHashMap(padding, basePlacements));\n var altContext = elementContext === popper ? reference : popper;\n var popperRect = state.rects.popper;\n var element = state.elements[altBoundary ? altContext : elementContext];\n var clippingClientRect = getClippingRect(isElement(element) ? element : element.contextElement || getDocumentElement(state.elements.popper), boundary, rootBoundary, strategy);\n var referenceClientRect = getBoundingClientRect(state.elements.reference);\n var popperOffsets = computeOffsets({\n reference: referenceClientRect,\n element: popperRect,\n strategy: 'absolute',\n placement: placement\n });\n var popperClientRect = rectToClientRect(Object.assign({}, popperRect, popperOffsets));\n var elementClientRect = elementContext === popper ? popperClientRect : referenceClientRect; // positive = overflowing the clipping rect\n // 0 or negative = within the clipping rect\n\n var overflowOffsets = {\n top: clippingClientRect.top - elementClientRect.top + paddingObject.top,\n bottom: elementClientRect.bottom - clippingClientRect.bottom + paddingObject.bottom,\n left: clippingClientRect.left - elementClientRect.left + paddingObject.left,\n right: elementClientRect.right - clippingClientRect.right + paddingObject.right\n };\n var offsetData = state.modifiersData.offset; // Offsets can be applied only to the popper element\n\n if (elementContext === popper && offsetData) {\n var offset = offsetData[placement];\n Object.keys(overflowOffsets).forEach(function (key) {\n var multiply = [right, bottom].indexOf(key) >= 0 ? 1 : -1;\n var axis = [top, bottom].indexOf(key) >= 0 ? 'y' : 'x';\n overflowOffsets[key] += offset[axis] * multiply;\n });\n }\n\n return overflowOffsets;\n}","import getVariation from \"./getVariation.js\";\nimport { variationPlacements, basePlacements, placements as allPlacements } from \"../enums.js\";\nimport detectOverflow from \"./detectOverflow.js\";\nimport getBasePlacement from \"./getBasePlacement.js\";\nexport default function computeAutoPlacement(state, options) {\n if (options === void 0) {\n options = {};\n }\n\n var _options = options,\n placement = _options.placement,\n boundary = _options.boundary,\n rootBoundary = _options.rootBoundary,\n padding = _options.padding,\n flipVariations = _options.flipVariations,\n _options$allowedAutoP = _options.allowedAutoPlacements,\n allowedAutoPlacements = _options$allowedAutoP === void 0 ? allPlacements : _options$allowedAutoP;\n var variation = getVariation(placement);\n var placements = variation ? flipVariations ? variationPlacements : variationPlacements.filter(function (placement) {\n return getVariation(placement) === variation;\n }) : basePlacements;\n var allowedPlacements = placements.filter(function (placement) {\n return allowedAutoPlacements.indexOf(placement) >= 0;\n });\n\n if (allowedPlacements.length === 0) {\n allowedPlacements = placements;\n } // $FlowFixMe[incompatible-type]: Flow seems to have problems with two array unions...\n\n\n var overflows = allowedPlacements.reduce(function (acc, placement) {\n acc[placement] = detectOverflow(state, {\n placement: placement,\n boundary: boundary,\n rootBoundary: rootBoundary,\n padding: padding\n })[getBasePlacement(placement)];\n return acc;\n }, {});\n return Object.keys(overflows).sort(function (a, b) {\n return overflows[a] - overflows[b];\n });\n}","import getOppositePlacement from \"../utils/getOppositePlacement.js\";\nimport getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getOppositeVariationPlacement from \"../utils/getOppositeVariationPlacement.js\";\nimport detectOverflow from \"../utils/detectOverflow.js\";\nimport computeAutoPlacement from \"../utils/computeAutoPlacement.js\";\nimport { bottom, top, start, right, left, auto } from \"../enums.js\";\nimport getVariation from \"../utils/getVariation.js\"; // eslint-disable-next-line import/no-unused-modules\n\nfunction getExpandedFallbackPlacements(placement) {\n if (getBasePlacement(placement) === auto) {\n return [];\n }\n\n var oppositePlacement = getOppositePlacement(placement);\n return [getOppositeVariationPlacement(placement), oppositePlacement, getOppositeVariationPlacement(oppositePlacement)];\n}\n\nfunction flip(_ref) {\n var state = _ref.state,\n options = _ref.options,\n name = _ref.name;\n\n if (state.modifiersData[name]._skip) {\n return;\n }\n\n var _options$mainAxis = options.mainAxis,\n checkMainAxis = _options$mainAxis === void 0 ? true : _options$mainAxis,\n _options$altAxis = options.altAxis,\n checkAltAxis = _options$altAxis === void 0 ? true : _options$altAxis,\n specifiedFallbackPlacements = options.fallbackPlacements,\n padding = options.padding,\n boundary = options.boundary,\n rootBoundary = options.rootBoundary,\n altBoundary = options.altBoundary,\n _options$flipVariatio = options.flipVariations,\n flipVariations = _options$flipVariatio === void 0 ? true : _options$flipVariatio,\n allowedAutoPlacements = options.allowedAutoPlacements;\n var preferredPlacement = state.options.placement;\n var basePlacement = getBasePlacement(preferredPlacement);\n var isBasePlacement = basePlacement === preferredPlacement;\n var fallbackPlacements = specifiedFallbackPlacements || (isBasePlacement || !flipVariations ? [getOppositePlacement(preferredPlacement)] : getExpandedFallbackPlacements(preferredPlacement));\n var placements = [preferredPlacement].concat(fallbackPlacements).reduce(function (acc, placement) {\n return acc.concat(getBasePlacement(placement) === auto ? computeAutoPlacement(state, {\n placement: placement,\n boundary: boundary,\n rootBoundary: rootBoundary,\n padding: padding,\n flipVariations: flipVariations,\n allowedAutoPlacements: allowedAutoPlacements\n }) : placement);\n }, []);\n var referenceRect = state.rects.reference;\n var popperRect = state.rects.popper;\n var checksMap = new Map();\n var makeFallbackChecks = true;\n var firstFittingPlacement = placements[0];\n\n for (var i = 0; i < placements.length; i++) {\n var placement = placements[i];\n\n var _basePlacement = getBasePlacement(placement);\n\n var isStartVariation = getVariation(placement) === start;\n var isVertical = [top, bottom].indexOf(_basePlacement) >= 0;\n var len = isVertical ? 'width' : 'height';\n var overflow = detectOverflow(state, {\n placement: placement,\n boundary: boundary,\n rootBoundary: rootBoundary,\n altBoundary: altBoundary,\n padding: padding\n });\n var mainVariationSide = isVertical ? isStartVariation ? right : left : isStartVariation ? bottom : top;\n\n if (referenceRect[len] > popperRect[len]) {\n mainVariationSide = getOppositePlacement(mainVariationSide);\n }\n\n var altVariationSide = getOppositePlacement(mainVariationSide);\n var checks = [];\n\n if (checkMainAxis) {\n checks.push(overflow[_basePlacement] <= 0);\n }\n\n if (checkAltAxis) {\n checks.push(overflow[mainVariationSide] <= 0, overflow[altVariationSide] <= 0);\n }\n\n if (checks.every(function (check) {\n return check;\n })) {\n firstFittingPlacement = placement;\n makeFallbackChecks = false;\n break;\n }\n\n checksMap.set(placement, checks);\n }\n\n if (makeFallbackChecks) {\n // `2` may be desired in some cases – research later\n var numberOfChecks = flipVariations ? 3 : 1;\n\n var _loop = function _loop(_i) {\n var fittingPlacement = placements.find(function (placement) {\n var checks = checksMap.get(placement);\n\n if (checks) {\n return checks.slice(0, _i).every(function (check) {\n return check;\n });\n }\n });\n\n if (fittingPlacement) {\n firstFittingPlacement = fittingPlacement;\n return \"break\";\n }\n };\n\n for (var _i = numberOfChecks; _i > 0; _i--) {\n var _ret = _loop(_i);\n\n if (_ret === \"break\") break;\n }\n }\n\n if (state.placement !== firstFittingPlacement) {\n state.modifiersData[name]._skip = true;\n state.placement = firstFittingPlacement;\n state.reset = true;\n }\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'flip',\n enabled: true,\n phase: 'main',\n fn: flip,\n requiresIfExists: ['offset'],\n data: {\n _skip: false\n }\n};","import { top, bottom, left, right } from \"../enums.js\";\nimport detectOverflow from \"../utils/detectOverflow.js\";\n\nfunction getSideOffsets(overflow, rect, preventedOffsets) {\n if (preventedOffsets === void 0) {\n preventedOffsets = {\n x: 0,\n y: 0\n };\n }\n\n return {\n top: overflow.top - rect.height - preventedOffsets.y,\n right: overflow.right - rect.width + preventedOffsets.x,\n bottom: overflow.bottom - rect.height + preventedOffsets.y,\n left: overflow.left - rect.width - preventedOffsets.x\n };\n}\n\nfunction isAnySideFullyClipped(overflow) {\n return [top, right, bottom, left].some(function (side) {\n return overflow[side] >= 0;\n });\n}\n\nfunction hide(_ref) {\n var state = _ref.state,\n name = _ref.name;\n var referenceRect = state.rects.reference;\n var popperRect = state.rects.popper;\n var preventedOffsets = state.modifiersData.preventOverflow;\n var referenceOverflow = detectOverflow(state, {\n elementContext: 'reference'\n });\n var popperAltOverflow = detectOverflow(state, {\n altBoundary: true\n });\n var referenceClippingOffsets = getSideOffsets(referenceOverflow, referenceRect);\n var popperEscapeOffsets = getSideOffsets(popperAltOverflow, popperRect, preventedOffsets);\n var isReferenceHidden = isAnySideFullyClipped(referenceClippingOffsets);\n var hasPopperEscaped = isAnySideFullyClipped(popperEscapeOffsets);\n state.modifiersData[name] = {\n referenceClippingOffsets: referenceClippingOffsets,\n popperEscapeOffsets: popperEscapeOffsets,\n isReferenceHidden: isReferenceHidden,\n hasPopperEscaped: hasPopperEscaped\n };\n state.attributes.popper = Object.assign({}, state.attributes.popper, {\n 'data-popper-reference-hidden': isReferenceHidden,\n 'data-popper-escaped': hasPopperEscaped\n });\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'hide',\n enabled: true,\n phase: 'main',\n requiresIfExists: ['preventOverflow'],\n fn: hide\n};","import getBasePlacement from \"../utils/getBasePlacement.js\";\nimport { top, left, right, placements } from \"../enums.js\"; // eslint-disable-next-line import/no-unused-modules\n\nexport function distanceAndSkiddingToXY(placement, rects, offset) {\n var basePlacement = getBasePlacement(placement);\n var invertDistance = [left, top].indexOf(basePlacement) >= 0 ? -1 : 1;\n\n var _ref = typeof offset === 'function' ? offset(Object.assign({}, rects, {\n placement: placement\n })) : offset,\n skidding = _ref[0],\n distance = _ref[1];\n\n skidding = skidding || 0;\n distance = (distance || 0) * invertDistance;\n return [left, right].indexOf(basePlacement) >= 0 ? {\n x: distance,\n y: skidding\n } : {\n x: skidding,\n y: distance\n };\n}\n\nfunction offset(_ref2) {\n var state = _ref2.state,\n options = _ref2.options,\n name = _ref2.name;\n var _options$offset = options.offset,\n offset = _options$offset === void 0 ? [0, 0] : _options$offset;\n var data = placements.reduce(function (acc, placement) {\n acc[placement] = distanceAndSkiddingToXY(placement, state.rects, offset);\n return acc;\n }, {});\n var _data$state$placement = data[state.placement],\n x = _data$state$placement.x,\n y = _data$state$placement.y;\n\n if (state.modifiersData.popperOffsets != null) {\n state.modifiersData.popperOffsets.x += x;\n state.modifiersData.popperOffsets.y += y;\n }\n\n state.modifiersData[name] = data;\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'offset',\n enabled: true,\n phase: 'main',\n requires: ['popperOffsets'],\n fn: offset\n};","import computeOffsets from \"../utils/computeOffsets.js\";\n\nfunction popperOffsets(_ref) {\n var state = _ref.state,\n name = _ref.name;\n // Offsets are the actual position the popper needs to have to be\n // properly positioned near its reference element\n // This is the most basic placement, and will be adjusted by\n // the modifiers in the next step\n state.modifiersData[name] = computeOffsets({\n reference: state.rects.reference,\n element: state.rects.popper,\n strategy: 'absolute',\n placement: state.placement\n });\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'popperOffsets',\n enabled: true,\n phase: 'read',\n fn: popperOffsets,\n data: {}\n};","export default function getAltAxis(axis) {\n return axis === 'x' ? 'y' : 'x';\n}","import { top, left, right, bottom, start } from \"../enums.js\";\nimport getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getMainAxisFromPlacement from \"../utils/getMainAxisFromPlacement.js\";\nimport getAltAxis from \"../utils/getAltAxis.js\";\nimport { within, withinMaxClamp } from \"../utils/within.js\";\nimport getLayoutRect from \"../dom-utils/getLayoutRect.js\";\nimport getOffsetParent from \"../dom-utils/getOffsetParent.js\";\nimport detectOverflow from \"../utils/detectOverflow.js\";\nimport getVariation from \"../utils/getVariation.js\";\nimport getFreshSideObject from \"../utils/getFreshSideObject.js\";\nimport { min as mathMin, max as mathMax } from \"../utils/math.js\";\n\nfunction preventOverflow(_ref) {\n var state = _ref.state,\n options = _ref.options,\n name = _ref.name;\n var _options$mainAxis = options.mainAxis,\n checkMainAxis = _options$mainAxis === void 0 ? true : _options$mainAxis,\n _options$altAxis = options.altAxis,\n checkAltAxis = _options$altAxis === void 0 ? false : _options$altAxis,\n boundary = options.boundary,\n rootBoundary = options.rootBoundary,\n altBoundary = options.altBoundary,\n padding = options.padding,\n _options$tether = options.tether,\n tether = _options$tether === void 0 ? true : _options$tether,\n _options$tetherOffset = options.tetherOffset,\n tetherOffset = _options$tetherOffset === void 0 ? 0 : _options$tetherOffset;\n var overflow = detectOverflow(state, {\n boundary: boundary,\n rootBoundary: rootBoundary,\n padding: padding,\n altBoundary: altBoundary\n });\n var basePlacement = getBasePlacement(state.placement);\n var variation = getVariation(state.placement);\n var isBasePlacement = !variation;\n var mainAxis = getMainAxisFromPlacement(basePlacement);\n var altAxis = getAltAxis(mainAxis);\n var popperOffsets = state.modifiersData.popperOffsets;\n var referenceRect = state.rects.reference;\n var popperRect = state.rects.popper;\n var tetherOffsetValue = typeof tetherOffset === 'function' ? tetherOffset(Object.assign({}, state.rects, {\n placement: state.placement\n })) : tetherOffset;\n var normalizedTetherOffsetValue = typeof tetherOffsetValue === 'number' ? {\n mainAxis: tetherOffsetValue,\n altAxis: tetherOffsetValue\n } : Object.assign({\n mainAxis: 0,\n altAxis: 0\n }, tetherOffsetValue);\n var offsetModifierState = state.modifiersData.offset ? state.modifiersData.offset[state.placement] : null;\n var data = {\n x: 0,\n y: 0\n };\n\n if (!popperOffsets) {\n return;\n }\n\n if (checkMainAxis) {\n var _offsetModifierState$;\n\n var mainSide = mainAxis === 'y' ? top : left;\n var altSide = mainAxis === 'y' ? bottom : right;\n var len = mainAxis === 'y' ? 'height' : 'width';\n var offset = popperOffsets[mainAxis];\n var min = offset + overflow[mainSide];\n var max = offset - overflow[altSide];\n var additive = tether ? -popperRect[len] / 2 : 0;\n var minLen = variation === start ? referenceRect[len] : popperRect[len];\n var maxLen = variation === start ? -popperRect[len] : -referenceRect[len]; // We need to include the arrow in the calculation so the arrow doesn't go\n // outside the reference bounds\n\n var arrowElement = state.elements.arrow;\n var arrowRect = tether && arrowElement ? getLayoutRect(arrowElement) : {\n width: 0,\n height: 0\n };\n var arrowPaddingObject = state.modifiersData['arrow#persistent'] ? state.modifiersData['arrow#persistent'].padding : getFreshSideObject();\n var arrowPaddingMin = arrowPaddingObject[mainSide];\n var arrowPaddingMax = arrowPaddingObject[altSide]; // If the reference length is smaller than the arrow length, we don't want\n // to include its full size in the calculation. If the reference is small\n // and near the edge of a boundary, the popper can overflow even if the\n // reference is not overflowing as well (e.g. virtual elements with no\n // width or height)\n\n var arrowLen = within(0, referenceRect[len], arrowRect[len]);\n var minOffset = isBasePlacement ? referenceRect[len] / 2 - additive - arrowLen - arrowPaddingMin - normalizedTetherOffsetValue.mainAxis : minLen - arrowLen - arrowPaddingMin - normalizedTetherOffsetValue.mainAxis;\n var maxOffset = isBasePlacement ? -referenceRect[len] / 2 + additive + arrowLen + arrowPaddingMax + normalizedTetherOffsetValue.mainAxis : maxLen + arrowLen + arrowPaddingMax + normalizedTetherOffsetValue.mainAxis;\n var arrowOffsetParent = state.elements.arrow && getOffsetParent(state.elements.arrow);\n var clientOffset = arrowOffsetParent ? mainAxis === 'y' ? arrowOffsetParent.clientTop || 0 : arrowOffsetParent.clientLeft || 0 : 0;\n var offsetModifierValue = (_offsetModifierState$ = offsetModifierState == null ? void 0 : offsetModifierState[mainAxis]) != null ? _offsetModifierState$ : 0;\n var tetherMin = offset + minOffset - offsetModifierValue - clientOffset;\n var tetherMax = offset + maxOffset - offsetModifierValue;\n var preventedOffset = within(tether ? mathMin(min, tetherMin) : min, offset, tether ? mathMax(max, tetherMax) : max);\n popperOffsets[mainAxis] = preventedOffset;\n data[mainAxis] = preventedOffset - offset;\n }\n\n if (checkAltAxis) {\n var _offsetModifierState$2;\n\n var _mainSide = mainAxis === 'x' ? top : left;\n\n var _altSide = mainAxis === 'x' ? bottom : right;\n\n var _offset = popperOffsets[altAxis];\n\n var _len = altAxis === 'y' ? 'height' : 'width';\n\n var _min = _offset + overflow[_mainSide];\n\n var _max = _offset - overflow[_altSide];\n\n var isOriginSide = [top, left].indexOf(basePlacement) !== -1;\n\n var _offsetModifierValue = (_offsetModifierState$2 = offsetModifierState == null ? void 0 : offsetModifierState[altAxis]) != null ? _offsetModifierState$2 : 0;\n\n var _tetherMin = isOriginSide ? _min : _offset - referenceRect[_len] - popperRect[_len] - _offsetModifierValue + normalizedTetherOffsetValue.altAxis;\n\n var _tetherMax = isOriginSide ? _offset + referenceRect[_len] + popperRect[_len] - _offsetModifierValue - normalizedTetherOffsetValue.altAxis : _max;\n\n var _preventedOffset = tether && isOriginSide ? withinMaxClamp(_tetherMin, _offset, _tetherMax) : within(tether ? _tetherMin : _min, _offset, tether ? _tetherMax : _max);\n\n popperOffsets[altAxis] = _preventedOffset;\n data[altAxis] = _preventedOffset - _offset;\n }\n\n state.modifiersData[name] = data;\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'preventOverflow',\n enabled: true,\n phase: 'main',\n fn: preventOverflow,\n requiresIfExists: ['offset']\n};","export default function getHTMLElementScroll(element) {\n return {\n scrollLeft: element.scrollLeft,\n scrollTop: element.scrollTop\n };\n}","import getWindowScroll from \"./getWindowScroll.js\";\nimport getWindow from \"./getWindow.js\";\nimport { isHTMLElement } from \"./instanceOf.js\";\nimport getHTMLElementScroll from \"./getHTMLElementScroll.js\";\nexport default function getNodeScroll(node) {\n if (node === getWindow(node) || !isHTMLElement(node)) {\n return getWindowScroll(node);\n } else {\n return getHTMLElementScroll(node);\n }\n}","import getBoundingClientRect from \"./getBoundingClientRect.js\";\nimport getNodeScroll from \"./getNodeScroll.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport { isHTMLElement } from \"./instanceOf.js\";\nimport getWindowScrollBarX from \"./getWindowScrollBarX.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport isScrollParent from \"./isScrollParent.js\";\nimport { round } from \"../utils/math.js\";\n\nfunction isElementScaled(element) {\n var rect = element.getBoundingClientRect();\n var scaleX = round(rect.width) / element.offsetWidth || 1;\n var scaleY = round(rect.height) / element.offsetHeight || 1;\n return scaleX !== 1 || scaleY !== 1;\n} // Returns the composite rect of an element relative to its offsetParent.\n// Composite means it takes into account transforms as well as layout.\n\n\nexport default function getCompositeRect(elementOrVirtualElement, offsetParent, isFixed) {\n if (isFixed === void 0) {\n isFixed = false;\n }\n\n var isOffsetParentAnElement = isHTMLElement(offsetParent);\n var offsetParentIsScaled = isHTMLElement(offsetParent) && isElementScaled(offsetParent);\n var documentElement = getDocumentElement(offsetParent);\n var rect = getBoundingClientRect(elementOrVirtualElement, offsetParentIsScaled, isFixed);\n var scroll = {\n scrollLeft: 0,\n scrollTop: 0\n };\n var offsets = {\n x: 0,\n y: 0\n };\n\n if (isOffsetParentAnElement || !isOffsetParentAnElement && !isFixed) {\n if (getNodeName(offsetParent) !== 'body' || // https://github.com/popperjs/popper-core/issues/1078\n isScrollParent(documentElement)) {\n scroll = getNodeScroll(offsetParent);\n }\n\n if (isHTMLElement(offsetParent)) {\n offsets = getBoundingClientRect(offsetParent, true);\n offsets.x += offsetParent.clientLeft;\n offsets.y += offsetParent.clientTop;\n } else if (documentElement) {\n offsets.x = getWindowScrollBarX(documentElement);\n }\n }\n\n return {\n x: rect.left + scroll.scrollLeft - offsets.x,\n y: rect.top + scroll.scrollTop - offsets.y,\n width: rect.width,\n height: rect.height\n };\n}","import { modifierPhases } from \"../enums.js\"; // source: https://stackoverflow.com/questions/49875255\n\nfunction order(modifiers) {\n var map = new Map();\n var visited = new Set();\n var result = [];\n modifiers.forEach(function (modifier) {\n map.set(modifier.name, modifier);\n }); // On visiting object, check for its dependencies and visit them recursively\n\n function sort(modifier) {\n visited.add(modifier.name);\n var requires = [].concat(modifier.requires || [], modifier.requiresIfExists || []);\n requires.forEach(function (dep) {\n if (!visited.has(dep)) {\n var depModifier = map.get(dep);\n\n if (depModifier) {\n sort(depModifier);\n }\n }\n });\n result.push(modifier);\n }\n\n modifiers.forEach(function (modifier) {\n if (!visited.has(modifier.name)) {\n // check for visited object\n sort(modifier);\n }\n });\n return result;\n}\n\nexport default function orderModifiers(modifiers) {\n // order based on dependencies\n var orderedModifiers = order(modifiers); // order based on phase\n\n return modifierPhases.reduce(function (acc, phase) {\n return acc.concat(orderedModifiers.filter(function (modifier) {\n return modifier.phase === phase;\n }));\n }, []);\n}","export default function debounce(fn) {\n var pending;\n return function () {\n if (!pending) {\n pending = new Promise(function (resolve) {\n Promise.resolve().then(function () {\n pending = undefined;\n resolve(fn());\n });\n });\n }\n\n return pending;\n };\n}","export default function mergeByName(modifiers) {\n var merged = modifiers.reduce(function (merged, current) {\n var existing = merged[current.name];\n merged[current.name] = existing ? Object.assign({}, existing, current, {\n options: Object.assign({}, existing.options, current.options),\n data: Object.assign({}, existing.data, current.data)\n }) : current;\n return merged;\n }, {}); // IE11 does not support Object.values\n\n return Object.keys(merged).map(function (key) {\n return merged[key];\n });\n}","import getCompositeRect from \"./dom-utils/getCompositeRect.js\";\nimport getLayoutRect from \"./dom-utils/getLayoutRect.js\";\nimport listScrollParents from \"./dom-utils/listScrollParents.js\";\nimport getOffsetParent from \"./dom-utils/getOffsetParent.js\";\nimport orderModifiers from \"./utils/orderModifiers.js\";\nimport debounce from \"./utils/debounce.js\";\nimport mergeByName from \"./utils/mergeByName.js\";\nimport detectOverflow from \"./utils/detectOverflow.js\";\nimport { isElement } from \"./dom-utils/instanceOf.js\";\nvar DEFAULT_OPTIONS = {\n placement: 'bottom',\n modifiers: [],\n strategy: 'absolute'\n};\n\nfunction areValidElements() {\n for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {\n args[_key] = arguments[_key];\n }\n\n return !args.some(function (element) {\n return !(element && typeof element.getBoundingClientRect === 'function');\n });\n}\n\nexport function popperGenerator(generatorOptions) {\n if (generatorOptions === void 0) {\n generatorOptions = {};\n }\n\n var _generatorOptions = generatorOptions,\n _generatorOptions$def = _generatorOptions.defaultModifiers,\n defaultModifiers = _generatorOptions$def === void 0 ? [] : _generatorOptions$def,\n _generatorOptions$def2 = _generatorOptions.defaultOptions,\n defaultOptions = _generatorOptions$def2 === void 0 ? DEFAULT_OPTIONS : _generatorOptions$def2;\n return function createPopper(reference, popper, options) {\n if (options === void 0) {\n options = defaultOptions;\n }\n\n var state = {\n placement: 'bottom',\n orderedModifiers: [],\n options: Object.assign({}, DEFAULT_OPTIONS, defaultOptions),\n modifiersData: {},\n elements: {\n reference: reference,\n popper: popper\n },\n attributes: {},\n styles: {}\n };\n var effectCleanupFns = [];\n var isDestroyed = false;\n var instance = {\n state: state,\n setOptions: function setOptions(setOptionsAction) {\n var options = typeof setOptionsAction === 'function' ? setOptionsAction(state.options) : setOptionsAction;\n cleanupModifierEffects();\n state.options = Object.assign({}, defaultOptions, state.options, options);\n state.scrollParents = {\n reference: isElement(reference) ? listScrollParents(reference) : reference.contextElement ? listScrollParents(reference.contextElement) : [],\n popper: listScrollParents(popper)\n }; // Orders the modifiers based on their dependencies and `phase`\n // properties\n\n var orderedModifiers = orderModifiers(mergeByName([].concat(defaultModifiers, state.options.modifiers))); // Strip out disabled modifiers\n\n state.orderedModifiers = orderedModifiers.filter(function (m) {\n return m.enabled;\n });\n runModifierEffects();\n return instance.update();\n },\n // Sync update – it will always be executed, even if not necessary. This\n // is useful for low frequency updates where sync behavior simplifies the\n // logic.\n // For high frequency updates (e.g. `resize` and `scroll` events), always\n // prefer the async Popper#update method\n forceUpdate: function forceUpdate() {\n if (isDestroyed) {\n return;\n }\n\n var _state$elements = state.elements,\n reference = _state$elements.reference,\n popper = _state$elements.popper; // Don't proceed if `reference` or `popper` are not valid elements\n // anymore\n\n if (!areValidElements(reference, popper)) {\n return;\n } // Store the reference and popper rects to be read by modifiers\n\n\n state.rects = {\n reference: getCompositeRect(reference, getOffsetParent(popper), state.options.strategy === 'fixed'),\n popper: getLayoutRect(popper)\n }; // Modifiers have the ability to reset the current update cycle. The\n // most common use case for this is the `flip` modifier changing the\n // placement, which then needs to re-run all the modifiers, because the\n // logic was previously ran for the previous placement and is therefore\n // stale/incorrect\n\n state.reset = false;\n state.placement = state.options.placement; // On each update cycle, the `modifiersData` property for each modifier\n // is filled with the initial data specified by the modifier. This means\n // it doesn't persist and is fresh on each update.\n // To ensure persistent data, use `${name}#persistent`\n\n state.orderedModifiers.forEach(function (modifier) {\n return state.modifiersData[modifier.name] = Object.assign({}, modifier.data);\n });\n\n for (var index = 0; index < state.orderedModifiers.length; index++) {\n if (state.reset === true) {\n state.reset = false;\n index = -1;\n continue;\n }\n\n var _state$orderedModifie = state.orderedModifiers[index],\n fn = _state$orderedModifie.fn,\n _state$orderedModifie2 = _state$orderedModifie.options,\n _options = _state$orderedModifie2 === void 0 ? {} : _state$orderedModifie2,\n name = _state$orderedModifie.name;\n\n if (typeof fn === 'function') {\n state = fn({\n state: state,\n options: _options,\n name: name,\n instance: instance\n }) || state;\n }\n }\n },\n // Async and optimistically optimized update – it will not be executed if\n // not necessary (debounced to run at most once-per-tick)\n update: debounce(function () {\n return new Promise(function (resolve) {\n instance.forceUpdate();\n resolve(state);\n });\n }),\n destroy: function destroy() {\n cleanupModifierEffects();\n isDestroyed = true;\n }\n };\n\n if (!areValidElements(reference, popper)) {\n return instance;\n }\n\n instance.setOptions(options).then(function (state) {\n if (!isDestroyed && options.onFirstUpdate) {\n options.onFirstUpdate(state);\n }\n }); // Modifiers have the ability to execute arbitrary code before the first\n // update cycle runs. They will be executed in the same order as the update\n // cycle. This is useful when a modifier adds some persistent data that\n // other modifiers need to use, but the modifier is run after the dependent\n // one.\n\n function runModifierEffects() {\n state.orderedModifiers.forEach(function (_ref) {\n var name = _ref.name,\n _ref$options = _ref.options,\n options = _ref$options === void 0 ? {} : _ref$options,\n effect = _ref.effect;\n\n if (typeof effect === 'function') {\n var cleanupFn = effect({\n state: state,\n name: name,\n instance: instance,\n options: options\n });\n\n var noopFn = function noopFn() {};\n\n effectCleanupFns.push(cleanupFn || noopFn);\n }\n });\n }\n\n function cleanupModifierEffects() {\n effectCleanupFns.forEach(function (fn) {\n return fn();\n });\n effectCleanupFns = [];\n }\n\n return instance;\n };\n}\nexport var createPopper = /*#__PURE__*/popperGenerator(); // eslint-disable-next-line import/no-unused-modules\n\nexport { detectOverflow };","import { popperGenerator, detectOverflow } from \"./createPopper.js\";\nimport eventListeners from \"./modifiers/eventListeners.js\";\nimport popperOffsets from \"./modifiers/popperOffsets.js\";\nimport computeStyles from \"./modifiers/computeStyles.js\";\nimport applyStyles from \"./modifiers/applyStyles.js\";\nimport offset from \"./modifiers/offset.js\";\nimport flip from \"./modifiers/flip.js\";\nimport preventOverflow from \"./modifiers/preventOverflow.js\";\nimport arrow from \"./modifiers/arrow.js\";\nimport hide from \"./modifiers/hide.js\";\nvar defaultModifiers = [eventListeners, popperOffsets, computeStyles, applyStyles, offset, flip, preventOverflow, arrow, hide];\nvar createPopper = /*#__PURE__*/popperGenerator({\n defaultModifiers: defaultModifiers\n}); // eslint-disable-next-line import/no-unused-modules\n\nexport { createPopper, popperGenerator, defaultModifiers, detectOverflow }; // eslint-disable-next-line import/no-unused-modules\n\nexport { createPopper as createPopperLite } from \"./popper-lite.js\"; // eslint-disable-next-line import/no-unused-modules\n\nexport * from \"./modifiers/index.js\";","import { generateUtilityClass } from '../generateUtilityClass';\nimport { generateUtilityClasses } from '../generateUtilityClasses';\nconst COMPONENT_NAME = 'Popper';\nexport function getPopperUtilityClass(slot) {\n return generateUtilityClass(COMPONENT_NAME, slot);\n}\nexport const popperClasses = generateUtilityClasses(COMPONENT_NAME, ['root']);","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"anchorEl\", \"children\", \"direction\", \"disablePortal\", \"modifiers\", \"open\", \"placement\", \"popperOptions\", \"popperRef\", \"slotProps\", \"slots\", \"TransitionProps\", \"ownerState\"],\n _excluded2 = [\"anchorEl\", \"children\", \"container\", \"direction\", \"disablePortal\", \"keepMounted\", \"modifiers\", \"open\", \"placement\", \"popperOptions\", \"popperRef\", \"style\", \"transition\", \"slotProps\", \"slots\"];\nimport * as React from 'react';\nimport { chainPropTypes, HTMLElementType, refType, unstable_ownerDocument as ownerDocument, unstable_useEnhancedEffect as useEnhancedEffect, unstable_useForkRef as useForkRef } from '@mui/utils';\nimport { createPopper } from '@popperjs/core';\nimport PropTypes from 'prop-types';\nimport { unstable_composeClasses as composeClasses } from '../composeClasses';\nimport { Portal } from '../Portal';\nimport { getPopperUtilityClass } from './popperClasses';\nimport { useSlotProps } from '../utils';\nimport { useClassNamesOverride } from '../utils/ClassNameConfigurator';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nfunction flipPlacement(placement, direction) {\n if (direction === 'ltr') {\n return placement;\n }\n switch (placement) {\n case 'bottom-end':\n return 'bottom-start';\n case 'bottom-start':\n return 'bottom-end';\n case 'top-end':\n return 'top-start';\n case 'top-start':\n return 'top-end';\n default:\n return placement;\n }\n}\nfunction resolveAnchorEl(anchorEl) {\n return typeof anchorEl === 'function' ? anchorEl() : anchorEl;\n}\nfunction isHTMLElement(element) {\n return element.nodeType !== undefined;\n}\nfunction isVirtualElement(element) {\n return !isHTMLElement(element);\n}\nconst useUtilityClasses = () => {\n const slots = {\n root: ['root']\n };\n return composeClasses(slots, useClassNamesOverride(getPopperUtilityClass));\n};\nconst defaultPopperOptions = {};\nconst PopperTooltip = /*#__PURE__*/React.forwardRef(function PopperTooltip(props, forwardedRef) {\n var _slots$root;\n const {\n anchorEl,\n children,\n direction,\n disablePortal,\n modifiers,\n open,\n placement: initialPlacement,\n popperOptions,\n popperRef: popperRefProp,\n slotProps = {},\n slots = {},\n TransitionProps\n // @ts-ignore internal logic\n // prevent from spreading to DOM, it can come from the parent component e.g. Select.\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const tooltipRef = React.useRef(null);\n const ownRef = useForkRef(tooltipRef, forwardedRef);\n const popperRef = React.useRef(null);\n const handlePopperRef = useForkRef(popperRef, popperRefProp);\n const handlePopperRefRef = React.useRef(handlePopperRef);\n useEnhancedEffect(() => {\n handlePopperRefRef.current = handlePopperRef;\n }, [handlePopperRef]);\n React.useImperativeHandle(popperRefProp, () => popperRef.current, []);\n const rtlPlacement = flipPlacement(initialPlacement, direction);\n /**\n * placement initialized from prop but can change during lifetime if modifiers.flip.\n * modifiers.flip is essentially a flip for controlled/uncontrolled behavior\n */\n const [placement, setPlacement] = React.useState(rtlPlacement);\n const [resolvedAnchorElement, setResolvedAnchorElement] = React.useState(resolveAnchorEl(anchorEl));\n React.useEffect(() => {\n if (popperRef.current) {\n popperRef.current.forceUpdate();\n }\n });\n React.useEffect(() => {\n if (anchorEl) {\n setResolvedAnchorElement(resolveAnchorEl(anchorEl));\n }\n }, [anchorEl]);\n useEnhancedEffect(() => {\n if (!resolvedAnchorElement || !open) {\n return undefined;\n }\n const handlePopperUpdate = data => {\n setPlacement(data.placement);\n };\n if (process.env.NODE_ENV !== 'production') {\n if (resolvedAnchorElement && isHTMLElement(resolvedAnchorElement) && resolvedAnchorElement.nodeType === 1) {\n const box = resolvedAnchorElement.getBoundingClientRect();\n if (process.env.NODE_ENV !== 'test' && box.top === 0 && box.left === 0 && box.right === 0 && box.bottom === 0) {\n console.warn(['MUI: The `anchorEl` prop provided to the component is invalid.', 'The anchor element should be part of the document layout.', \"Make sure the element is present in the document or that it's not display none.\"].join('\\n'));\n }\n }\n }\n let popperModifiers = [{\n name: 'preventOverflow',\n options: {\n altBoundary: disablePortal\n }\n }, {\n name: 'flip',\n options: {\n altBoundary: disablePortal\n }\n }, {\n name: 'onUpdate',\n enabled: true,\n phase: 'afterWrite',\n fn: ({\n state\n }) => {\n handlePopperUpdate(state);\n }\n }];\n if (modifiers != null) {\n popperModifiers = popperModifiers.concat(modifiers);\n }\n if (popperOptions && popperOptions.modifiers != null) {\n popperModifiers = popperModifiers.concat(popperOptions.modifiers);\n }\n const popper = createPopper(resolvedAnchorElement, tooltipRef.current, _extends({\n placement: rtlPlacement\n }, popperOptions, {\n modifiers: popperModifiers\n }));\n handlePopperRefRef.current(popper);\n return () => {\n popper.destroy();\n handlePopperRefRef.current(null);\n };\n }, [resolvedAnchorElement, disablePortal, modifiers, open, popperOptions, rtlPlacement]);\n const childProps = {\n placement: placement\n };\n if (TransitionProps !== null) {\n childProps.TransitionProps = TransitionProps;\n }\n const classes = useUtilityClasses();\n const Root = (_slots$root = slots.root) != null ? _slots$root : 'div';\n const rootProps = useSlotProps({\n elementType: Root,\n externalSlotProps: slotProps.root,\n externalForwardedProps: other,\n additionalProps: {\n role: 'tooltip',\n ref: ownRef\n },\n ownerState: props,\n className: classes.root\n });\n return /*#__PURE__*/_jsx(Root, _extends({}, rootProps, {\n children: typeof children === 'function' ? children(childProps) : children\n }));\n});\n\n/**\n * Poppers rely on the 3rd party library [Popper.js](https://popper.js.org/docs/v2/) for positioning.\n *\n * Demos:\n *\n * - [Popper](https://mui.com/base-ui/react-popper/)\n *\n * API:\n *\n * - [Popper API](https://mui.com/base-ui/react-popper/components-api/#popper)\n */\nconst Popper = /*#__PURE__*/React.forwardRef(function Popper(props, forwardedRef) {\n const {\n anchorEl,\n children,\n container: containerProp,\n direction = 'ltr',\n disablePortal = false,\n keepMounted = false,\n modifiers,\n open,\n placement = 'bottom',\n popperOptions = defaultPopperOptions,\n popperRef,\n style,\n transition = false,\n slotProps = {},\n slots = {}\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded2);\n const [exited, setExited] = React.useState(true);\n const handleEnter = () => {\n setExited(false);\n };\n const handleExited = () => {\n setExited(true);\n };\n if (!keepMounted && !open && (!transition || exited)) {\n return null;\n }\n\n // If the container prop is provided, use that\n // If the anchorEl prop is provided, use its parent body element as the container\n // If neither are provided let the Modal take care of choosing the container\n let container;\n if (containerProp) {\n container = containerProp;\n } else if (anchorEl) {\n const resolvedAnchorEl = resolveAnchorEl(anchorEl);\n container = resolvedAnchorEl && isHTMLElement(resolvedAnchorEl) ? ownerDocument(resolvedAnchorEl).body : ownerDocument(null).body;\n }\n const display = !open && keepMounted && (!transition || exited) ? 'none' : undefined;\n const transitionProps = transition ? {\n in: open,\n onEnter: handleEnter,\n onExited: handleExited\n } : undefined;\n return /*#__PURE__*/_jsx(Portal, {\n disablePortal: disablePortal,\n container: container,\n children: /*#__PURE__*/_jsx(PopperTooltip, _extends({\n anchorEl: anchorEl,\n direction: direction,\n disablePortal: disablePortal,\n modifiers: modifiers,\n ref: forwardedRef,\n open: transition ? !exited : open,\n placement: placement,\n popperOptions: popperOptions,\n popperRef: popperRef,\n slotProps: slotProps,\n slots: slots\n }, other, {\n style: _extends({\n // Prevents scroll issue, waiting for Popper.js to add this style once initiated.\n position: 'fixed',\n // Fix Popper.js display issue\n top: 0,\n left: 0,\n display\n }, style),\n TransitionProps: transitionProps,\n children: children\n }))\n });\n});\nprocess.env.NODE_ENV !== \"production\" ? Popper.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * An HTML element, [virtualElement](https://popper.js.org/docs/v2/virtual-elements/),\n * or a function that returns either.\n * It's used to set the position of the popper.\n * The return value will passed as the reference object of the Popper instance.\n */\n anchorEl: chainPropTypes(PropTypes.oneOfType([HTMLElementType, PropTypes.object, PropTypes.func]), props => {\n if (props.open) {\n const resolvedAnchorEl = resolveAnchorEl(props.anchorEl);\n if (resolvedAnchorEl && isHTMLElement(resolvedAnchorEl) && resolvedAnchorEl.nodeType === 1) {\n const box = resolvedAnchorEl.getBoundingClientRect();\n if (process.env.NODE_ENV !== 'test' && box.top === 0 && box.left === 0 && box.right === 0 && box.bottom === 0) {\n return new Error(['MUI: The `anchorEl` prop provided to the component is invalid.', 'The anchor element should be part of the document layout.', \"Make sure the element is present in the document or that it's not display none.\"].join('\\n'));\n }\n } else if (!resolvedAnchorEl || typeof resolvedAnchorEl.getBoundingClientRect !== 'function' || isVirtualElement(resolvedAnchorEl) && resolvedAnchorEl.contextElement != null && resolvedAnchorEl.contextElement.nodeType !== 1) {\n return new Error(['MUI: The `anchorEl` prop provided to the component is invalid.', 'It should be an HTML element instance or a virtualElement ', '(https://popper.js.org/docs/v2/virtual-elements/).'].join('\\n'));\n }\n }\n return null;\n }),\n /**\n * Popper render function or node.\n */\n children: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.node, PropTypes.func]),\n /**\n * An HTML element or function that returns one.\n * The `container` will have the portal children appended to it.\n *\n * You can also provide a callback, which is called in a React layout effect.\n * This lets you set the container from a ref, and also makes server-side rendering possible.\n *\n * By default, it uses the body of the top-level document object,\n * so it's simply `document.body` most of the time.\n */\n container: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.func]),\n /**\n * Direction of the text.\n * @default 'ltr'\n */\n direction: PropTypes.oneOf(['ltr', 'rtl']),\n /**\n * The `children` will be under the DOM hierarchy of the parent component.\n * @default false\n */\n disablePortal: PropTypes.bool,\n /**\n * Always keep the children in the DOM.\n * This prop can be useful in SEO situation or\n * when you want to maximize the responsiveness of the Popper.\n * @default false\n */\n keepMounted: PropTypes.bool,\n /**\n * Popper.js is based on a \"plugin-like\" architecture,\n * most of its features are fully encapsulated \"modifiers\".\n *\n * A modifier is a function that is called each time Popper.js needs to\n * compute the position of the popper.\n * For this reason, modifiers should be very performant to avoid bottlenecks.\n * To learn how to create a modifier, [read the modifiers documentation](https://popper.js.org/docs/v2/modifiers/).\n */\n modifiers: PropTypes.arrayOf(PropTypes.shape({\n data: PropTypes.object,\n effect: PropTypes.func,\n enabled: PropTypes.bool,\n fn: PropTypes.func,\n name: PropTypes.any,\n options: PropTypes.object,\n phase: PropTypes.oneOf(['afterMain', 'afterRead', 'afterWrite', 'beforeMain', 'beforeRead', 'beforeWrite', 'main', 'read', 'write']),\n requires: PropTypes.arrayOf(PropTypes.string),\n requiresIfExists: PropTypes.arrayOf(PropTypes.string)\n })),\n /**\n * If `true`, the component is shown.\n */\n open: PropTypes.bool.isRequired,\n /**\n * Popper placement.\n * @default 'bottom'\n */\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n /**\n * Options provided to the [`Popper.js`](https://popper.js.org/docs/v2/constructors/#options) instance.\n * @default {}\n */\n popperOptions: PropTypes.shape({\n modifiers: PropTypes.array,\n onFirstUpdate: PropTypes.func,\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n strategy: PropTypes.oneOf(['absolute', 'fixed'])\n }),\n /**\n * A ref that points to the used popper instance.\n */\n popperRef: refType,\n /**\n * The props used for each slot inside the Popper.\n * @default {}\n */\n slotProps: PropTypes.shape({\n root: PropTypes.oneOfType([PropTypes.func, PropTypes.object])\n }),\n /**\n * The components used for each slot inside the Popper.\n * Either a string to use a HTML element or a component.\n * @default {}\n */\n slots: PropTypes.shape({\n root: PropTypes.elementType\n }),\n /**\n * Help supporting a react-transition-group/Transition component.\n * @default false\n */\n transition: PropTypes.bool\n} : void 0;\nexport { Popper };","'use client';\n\nimport * as React from 'react';\nimport { useTheme as useThemeSystem } from '@mui/system';\nimport defaultTheme from './defaultTheme';\nimport THEME_ID from './identifier';\nexport default function useTheme() {\n const theme = useThemeSystem(defaultTheme);\n if (process.env.NODE_ENV !== 'production') {\n // eslint-disable-next-line react-hooks/rules-of-hooks\n React.useDebugValue(theme);\n }\n return theme[THEME_ID] || theme;\n}","export default function _setPrototypeOf(o, p) {\n _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function _setPrototypeOf(o, p) {\n o.__proto__ = p;\n return o;\n };\n return _setPrototypeOf(o, p);\n}","import setPrototypeOf from \"./setPrototypeOf.js\";\nexport default function _inheritsLoose(subClass, superClass) {\n subClass.prototype = Object.create(superClass.prototype);\n subClass.prototype.constructor = subClass;\n setPrototypeOf(subClass, superClass);\n}","export default {\n disabled: false\n};","import PropTypes from 'prop-types';\nexport var timeoutsShape = process.env.NODE_ENV !== 'production' ? PropTypes.oneOfType([PropTypes.number, PropTypes.shape({\n enter: PropTypes.number,\n exit: PropTypes.number,\n appear: PropTypes.number\n}).isRequired]) : null;\nexport var classNamesShape = process.env.NODE_ENV !== 'production' ? PropTypes.oneOfType([PropTypes.string, PropTypes.shape({\n enter: PropTypes.string,\n exit: PropTypes.string,\n active: PropTypes.string\n}), PropTypes.shape({\n enter: PropTypes.string,\n enterDone: PropTypes.string,\n enterActive: PropTypes.string,\n exit: PropTypes.string,\n exitDone: PropTypes.string,\n exitActive: PropTypes.string\n})]) : null;","import React from 'react';\nexport default React.createContext(null);","export var forceReflow = function forceReflow(node) {\n return node.scrollTop;\n};","import _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _inheritsLoose from \"@babel/runtime/helpers/esm/inheritsLoose\";\nimport PropTypes from 'prop-types';\nimport React from 'react';\nimport ReactDOM from 'react-dom';\nimport config from './config';\nimport { timeoutsShape } from './utils/PropTypes';\nimport TransitionGroupContext from './TransitionGroupContext';\nimport { forceReflow } from './utils/reflow';\nexport var UNMOUNTED = 'unmounted';\nexport var EXITED = 'exited';\nexport var ENTERING = 'entering';\nexport var ENTERED = 'entered';\nexport var EXITING = 'exiting';\n/**\n * The Transition component lets you describe a transition from one component\n * state to another _over time_ with a simple declarative API. Most commonly\n * it's used to animate the mounting and unmounting of a component, but can also\n * be used to describe in-place transition states as well.\n *\n * ---\n *\n * **Note**: `Transition` is a platform-agnostic base component. If you're using\n * transitions in CSS, you'll probably want to use\n * [`CSSTransition`](https://reactcommunity.org/react-transition-group/css-transition)\n * instead. It inherits all the features of `Transition`, but contains\n * additional features necessary to play nice with CSS transitions (hence the\n * name of the component).\n *\n * ---\n *\n * By default the `Transition` component does not alter the behavior of the\n * component it renders, it only tracks \"enter\" and \"exit\" states for the\n * components. It's up to you to give meaning and effect to those states. For\n * example we can add styles to a component when it enters or exits:\n *\n * ```jsx\n * import { Transition } from 'react-transition-group';\n *\n * const duration = 300;\n *\n * const defaultStyle = {\n * transition: `opacity ${duration}ms ease-in-out`,\n * opacity: 0,\n * }\n *\n * const transitionStyles = {\n * entering: { opacity: 1 },\n * entered: { opacity: 1 },\n * exiting: { opacity: 0 },\n * exited: { opacity: 0 },\n * };\n *\n * const Fade = ({ in: inProp }) => (\n * \n * {state => (\n *
    \n * I'm a fade Transition!\n *
    \n * )}\n *
    \n * );\n * ```\n *\n * There are 4 main states a Transition can be in:\n * - `'entering'`\n * - `'entered'`\n * - `'exiting'`\n * - `'exited'`\n *\n * Transition state is toggled via the `in` prop. When `true` the component\n * begins the \"Enter\" stage. During this stage, the component will shift from\n * its current transition state, to `'entering'` for the duration of the\n * transition and then to the `'entered'` stage once it's complete. Let's take\n * the following example (we'll use the\n * [useState](https://reactjs.org/docs/hooks-reference.html#usestate) hook):\n *\n * ```jsx\n * function App() {\n * const [inProp, setInProp] = useState(false);\n * return (\n *
    \n * \n * {state => (\n * // ...\n * )}\n * \n * \n *
    \n * );\n * }\n * ```\n *\n * When the button is clicked the component will shift to the `'entering'` state\n * and stay there for 500ms (the value of `timeout`) before it finally switches\n * to `'entered'`.\n *\n * When `in` is `false` the same thing happens except the state moves from\n * `'exiting'` to `'exited'`.\n */\n\nvar Transition = /*#__PURE__*/function (_React$Component) {\n _inheritsLoose(Transition, _React$Component);\n\n function Transition(props, context) {\n var _this;\n\n _this = _React$Component.call(this, props, context) || this;\n var parentGroup = context; // In the context of a TransitionGroup all enters are really appears\n\n var appear = parentGroup && !parentGroup.isMounting ? props.enter : props.appear;\n var initialStatus;\n _this.appearStatus = null;\n\n if (props.in) {\n if (appear) {\n initialStatus = EXITED;\n _this.appearStatus = ENTERING;\n } else {\n initialStatus = ENTERED;\n }\n } else {\n if (props.unmountOnExit || props.mountOnEnter) {\n initialStatus = UNMOUNTED;\n } else {\n initialStatus = EXITED;\n }\n }\n\n _this.state = {\n status: initialStatus\n };\n _this.nextCallback = null;\n return _this;\n }\n\n Transition.getDerivedStateFromProps = function getDerivedStateFromProps(_ref, prevState) {\n var nextIn = _ref.in;\n\n if (nextIn && prevState.status === UNMOUNTED) {\n return {\n status: EXITED\n };\n }\n\n return null;\n } // getSnapshotBeforeUpdate(prevProps) {\n // let nextStatus = null\n // if (prevProps !== this.props) {\n // const { status } = this.state\n // if (this.props.in) {\n // if (status !== ENTERING && status !== ENTERED) {\n // nextStatus = ENTERING\n // }\n // } else {\n // if (status === ENTERING || status === ENTERED) {\n // nextStatus = EXITING\n // }\n // }\n // }\n // return { nextStatus }\n // }\n ;\n\n var _proto = Transition.prototype;\n\n _proto.componentDidMount = function componentDidMount() {\n this.updateStatus(true, this.appearStatus);\n };\n\n _proto.componentDidUpdate = function componentDidUpdate(prevProps) {\n var nextStatus = null;\n\n if (prevProps !== this.props) {\n var status = this.state.status;\n\n if (this.props.in) {\n if (status !== ENTERING && status !== ENTERED) {\n nextStatus = ENTERING;\n }\n } else {\n if (status === ENTERING || status === ENTERED) {\n nextStatus = EXITING;\n }\n }\n }\n\n this.updateStatus(false, nextStatus);\n };\n\n _proto.componentWillUnmount = function componentWillUnmount() {\n this.cancelNextCallback();\n };\n\n _proto.getTimeouts = function getTimeouts() {\n var timeout = this.props.timeout;\n var exit, enter, appear;\n exit = enter = appear = timeout;\n\n if (timeout != null && typeof timeout !== 'number') {\n exit = timeout.exit;\n enter = timeout.enter; // TODO: remove fallback for next major\n\n appear = timeout.appear !== undefined ? timeout.appear : enter;\n }\n\n return {\n exit: exit,\n enter: enter,\n appear: appear\n };\n };\n\n _proto.updateStatus = function updateStatus(mounting, nextStatus) {\n if (mounting === void 0) {\n mounting = false;\n }\n\n if (nextStatus !== null) {\n // nextStatus will always be ENTERING or EXITING.\n this.cancelNextCallback();\n\n if (nextStatus === ENTERING) {\n if (this.props.unmountOnExit || this.props.mountOnEnter) {\n var node = this.props.nodeRef ? this.props.nodeRef.current : ReactDOM.findDOMNode(this); // https://github.com/reactjs/react-transition-group/pull/749\n // With unmountOnExit or mountOnEnter, the enter animation should happen at the transition between `exited` and `entering`.\n // To make the animation happen, we have to separate each rendering and avoid being processed as batched.\n\n if (node) forceReflow(node);\n }\n\n this.performEnter(mounting);\n } else {\n this.performExit();\n }\n } else if (this.props.unmountOnExit && this.state.status === EXITED) {\n this.setState({\n status: UNMOUNTED\n });\n }\n };\n\n _proto.performEnter = function performEnter(mounting) {\n var _this2 = this;\n\n var enter = this.props.enter;\n var appearing = this.context ? this.context.isMounting : mounting;\n\n var _ref2 = this.props.nodeRef ? [appearing] : [ReactDOM.findDOMNode(this), appearing],\n maybeNode = _ref2[0],\n maybeAppearing = _ref2[1];\n\n var timeouts = this.getTimeouts();\n var enterTimeout = appearing ? timeouts.appear : timeouts.enter; // no enter animation skip right to ENTERED\n // if we are mounting and running this it means appear _must_ be set\n\n if (!mounting && !enter || config.disabled) {\n this.safeSetState({\n status: ENTERED\n }, function () {\n _this2.props.onEntered(maybeNode);\n });\n return;\n }\n\n this.props.onEnter(maybeNode, maybeAppearing);\n this.safeSetState({\n status: ENTERING\n }, function () {\n _this2.props.onEntering(maybeNode, maybeAppearing);\n\n _this2.onTransitionEnd(enterTimeout, function () {\n _this2.safeSetState({\n status: ENTERED\n }, function () {\n _this2.props.onEntered(maybeNode, maybeAppearing);\n });\n });\n });\n };\n\n _proto.performExit = function performExit() {\n var _this3 = this;\n\n var exit = this.props.exit;\n var timeouts = this.getTimeouts();\n var maybeNode = this.props.nodeRef ? undefined : ReactDOM.findDOMNode(this); // no exit animation skip right to EXITED\n\n if (!exit || config.disabled) {\n this.safeSetState({\n status: EXITED\n }, function () {\n _this3.props.onExited(maybeNode);\n });\n return;\n }\n\n this.props.onExit(maybeNode);\n this.safeSetState({\n status: EXITING\n }, function () {\n _this3.props.onExiting(maybeNode);\n\n _this3.onTransitionEnd(timeouts.exit, function () {\n _this3.safeSetState({\n status: EXITED\n }, function () {\n _this3.props.onExited(maybeNode);\n });\n });\n });\n };\n\n _proto.cancelNextCallback = function cancelNextCallback() {\n if (this.nextCallback !== null) {\n this.nextCallback.cancel();\n this.nextCallback = null;\n }\n };\n\n _proto.safeSetState = function safeSetState(nextState, callback) {\n // This shouldn't be necessary, but there are weird race conditions with\n // setState callbacks and unmounting in testing, so always make sure that\n // we can cancel any pending setState callbacks after we unmount.\n callback = this.setNextCallback(callback);\n this.setState(nextState, callback);\n };\n\n _proto.setNextCallback = function setNextCallback(callback) {\n var _this4 = this;\n\n var active = true;\n\n this.nextCallback = function (event) {\n if (active) {\n active = false;\n _this4.nextCallback = null;\n callback(event);\n }\n };\n\n this.nextCallback.cancel = function () {\n active = false;\n };\n\n return this.nextCallback;\n };\n\n _proto.onTransitionEnd = function onTransitionEnd(timeout, handler) {\n this.setNextCallback(handler);\n var node = this.props.nodeRef ? this.props.nodeRef.current : ReactDOM.findDOMNode(this);\n var doesNotHaveTimeoutOrListener = timeout == null && !this.props.addEndListener;\n\n if (!node || doesNotHaveTimeoutOrListener) {\n setTimeout(this.nextCallback, 0);\n return;\n }\n\n if (this.props.addEndListener) {\n var _ref3 = this.props.nodeRef ? [this.nextCallback] : [node, this.nextCallback],\n maybeNode = _ref3[0],\n maybeNextCallback = _ref3[1];\n\n this.props.addEndListener(maybeNode, maybeNextCallback);\n }\n\n if (timeout != null) {\n setTimeout(this.nextCallback, timeout);\n }\n };\n\n _proto.render = function render() {\n var status = this.state.status;\n\n if (status === UNMOUNTED) {\n return null;\n }\n\n var _this$props = this.props,\n children = _this$props.children,\n _in = _this$props.in,\n _mountOnEnter = _this$props.mountOnEnter,\n _unmountOnExit = _this$props.unmountOnExit,\n _appear = _this$props.appear,\n _enter = _this$props.enter,\n _exit = _this$props.exit,\n _timeout = _this$props.timeout,\n _addEndListener = _this$props.addEndListener,\n _onEnter = _this$props.onEnter,\n _onEntering = _this$props.onEntering,\n _onEntered = _this$props.onEntered,\n _onExit = _this$props.onExit,\n _onExiting = _this$props.onExiting,\n _onExited = _this$props.onExited,\n _nodeRef = _this$props.nodeRef,\n childProps = _objectWithoutPropertiesLoose(_this$props, [\"children\", \"in\", \"mountOnEnter\", \"unmountOnExit\", \"appear\", \"enter\", \"exit\", \"timeout\", \"addEndListener\", \"onEnter\", \"onEntering\", \"onEntered\", \"onExit\", \"onExiting\", \"onExited\", \"nodeRef\"]);\n\n return (\n /*#__PURE__*/\n // allows for nested Transitions\n React.createElement(TransitionGroupContext.Provider, {\n value: null\n }, typeof children === 'function' ? children(status, childProps) : React.cloneElement(React.Children.only(children), childProps))\n );\n };\n\n return Transition;\n}(React.Component);\n\nTransition.contextType = TransitionGroupContext;\nTransition.propTypes = process.env.NODE_ENV !== \"production\" ? {\n /**\n * A React reference to DOM element that need to transition:\n * https://stackoverflow.com/a/51127130/4671932\n *\n * - When `nodeRef` prop is used, `node` is not passed to callback functions\n * (e.g. `onEnter`) because user already has direct access to the node.\n * - When changing `key` prop of `Transition` in a `TransitionGroup` a new\n * `nodeRef` need to be provided to `Transition` with changed `key` prop\n * (see\n * [test/CSSTransition-test.js](https://github.com/reactjs/react-transition-group/blob/13435f897b3ab71f6e19d724f145596f5910581c/test/CSSTransition-test.js#L362-L437)).\n */\n nodeRef: PropTypes.shape({\n current: typeof Element === 'undefined' ? PropTypes.any : function (propValue, key, componentName, location, propFullName, secret) {\n var value = propValue[key];\n return PropTypes.instanceOf(value && 'ownerDocument' in value ? value.ownerDocument.defaultView.Element : Element)(propValue, key, componentName, location, propFullName, secret);\n }\n }),\n\n /**\n * A `function` child can be used instead of a React element. This function is\n * called with the current transition status (`'entering'`, `'entered'`,\n * `'exiting'`, `'exited'`), which can be used to apply context\n * specific props to a component.\n *\n * ```jsx\n * \n * {state => (\n * \n * )}\n * \n * ```\n */\n children: PropTypes.oneOfType([PropTypes.func.isRequired, PropTypes.element.isRequired]).isRequired,\n\n /**\n * Show the component; triggers the enter or exit states\n */\n in: PropTypes.bool,\n\n /**\n * By default the child component is mounted immediately along with\n * the parent `Transition` component. If you want to \"lazy mount\" the component on the\n * first `in={true}` you can set `mountOnEnter`. After the first enter transition the component will stay\n * mounted, even on \"exited\", unless you also specify `unmountOnExit`.\n */\n mountOnEnter: PropTypes.bool,\n\n /**\n * By default the child component stays mounted after it reaches the `'exited'` state.\n * Set `unmountOnExit` if you'd prefer to unmount the component after it finishes exiting.\n */\n unmountOnExit: PropTypes.bool,\n\n /**\n * By default the child component does not perform the enter transition when\n * it first mounts, regardless of the value of `in`. If you want this\n * behavior, set both `appear` and `in` to `true`.\n *\n * > **Note**: there are no special appear states like `appearing`/`appeared`, this prop\n * > only adds an additional enter transition. However, in the\n * > `` component that first enter transition does result in\n * > additional `.appear-*` classes, that way you can choose to style it\n * > differently.\n */\n appear: PropTypes.bool,\n\n /**\n * Enable or disable enter transitions.\n */\n enter: PropTypes.bool,\n\n /**\n * Enable or disable exit transitions.\n */\n exit: PropTypes.bool,\n\n /**\n * The duration of the transition, in milliseconds.\n * Required unless `addEndListener` is provided.\n *\n * You may specify a single timeout for all transitions:\n *\n * ```jsx\n * timeout={500}\n * ```\n *\n * or individually:\n *\n * ```jsx\n * timeout={{\n * appear: 500,\n * enter: 300,\n * exit: 500,\n * }}\n * ```\n *\n * - `appear` defaults to the value of `enter`\n * - `enter` defaults to `0`\n * - `exit` defaults to `0`\n *\n * @type {number | { enter?: number, exit?: number, appear?: number }}\n */\n timeout: function timeout(props) {\n var pt = timeoutsShape;\n if (!props.addEndListener) pt = pt.isRequired;\n\n for (var _len = arguments.length, args = new Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) {\n args[_key - 1] = arguments[_key];\n }\n\n return pt.apply(void 0, [props].concat(args));\n },\n\n /**\n * Add a custom transition end trigger. Called with the transitioning\n * DOM node and a `done` callback. Allows for more fine grained transition end\n * logic. Timeouts are still used as a fallback if provided.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * ```jsx\n * addEndListener={(node, done) => {\n * // use the css transitionend event to mark the finish of a transition\n * node.addEventListener('transitionend', done, false);\n * }}\n * ```\n */\n addEndListener: PropTypes.func,\n\n /**\n * Callback fired before the \"entering\" status is applied. An extra parameter\n * `isAppearing` is supplied to indicate if the enter stage is occurring on the initial mount\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement, isAppearing: bool) -> void\n */\n onEnter: PropTypes.func,\n\n /**\n * Callback fired after the \"entering\" status is applied. An extra parameter\n * `isAppearing` is supplied to indicate if the enter stage is occurring on the initial mount\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement, isAppearing: bool)\n */\n onEntering: PropTypes.func,\n\n /**\n * Callback fired after the \"entered\" status is applied. An extra parameter\n * `isAppearing` is supplied to indicate if the enter stage is occurring on the initial mount\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement, isAppearing: bool) -> void\n */\n onEntered: PropTypes.func,\n\n /**\n * Callback fired before the \"exiting\" status is applied.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement) -> void\n */\n onExit: PropTypes.func,\n\n /**\n * Callback fired after the \"exiting\" status is applied.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement) -> void\n */\n onExiting: PropTypes.func,\n\n /**\n * Callback fired after the \"exited\" status is applied.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed\n *\n * @type Function(node: HtmlElement) -> void\n */\n onExited: PropTypes.func\n} : {}; // Name the function so it is clearer in the documentation\n\nfunction noop() {}\n\nTransition.defaultProps = {\n in: false,\n mountOnEnter: false,\n unmountOnExit: false,\n appear: false,\n enter: true,\n exit: true,\n onEnter: noop,\n onEntering: noop,\n onEntered: noop,\n onExit: noop,\n onExiting: noop,\n onExited: noop\n};\nTransition.UNMOUNTED = UNMOUNTED;\nTransition.EXITED = EXITED;\nTransition.ENTERING = ENTERING;\nTransition.ENTERED = ENTERED;\nTransition.EXITING = EXITING;\nexport default Transition;","export const reflow = node => node.scrollTop;\nexport function getTransitionProps(props, options) {\n var _style$transitionDura, _style$transitionTimi;\n const {\n timeout,\n easing,\n style = {}\n } = props;\n return {\n duration: (_style$transitionDura = style.transitionDuration) != null ? _style$transitionDura : typeof timeout === 'number' ? timeout : timeout[options.mode] || 0,\n easing: (_style$transitionTimi = style.transitionTimingFunction) != null ? _style$transitionTimi : typeof easing === 'object' ? easing[options.mode] : easing,\n delay: style.transitionDelay\n };\n}","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"addEndListener\", \"appear\", \"children\", \"easing\", \"in\", \"onEnter\", \"onEntered\", \"onEntering\", \"onExit\", \"onExited\", \"onExiting\", \"style\", \"timeout\", \"TransitionComponent\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport { elementAcceptingRef, unstable_useTimeout as useTimeout } from '@mui/utils';\nimport { Transition } from 'react-transition-group';\nimport useTheme from '../styles/useTheme';\nimport { getTransitionProps, reflow } from '../transitions/utils';\nimport useForkRef from '../utils/useForkRef';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nfunction getScale(value) {\n return `scale(${value}, ${value ** 2})`;\n}\nconst styles = {\n entering: {\n opacity: 1,\n transform: getScale(1)\n },\n entered: {\n opacity: 1,\n transform: 'none'\n }\n};\n\n/*\n TODO v6: remove\n Conditionally apply a workaround for the CSS transition bug in Safari 15.4 / WebKit browsers.\n */\nconst isWebKit154 = typeof navigator !== 'undefined' && /^((?!chrome|android).)*(safari|mobile)/i.test(navigator.userAgent) && /(os |version\\/)15(.|_)4/i.test(navigator.userAgent);\n\n/**\n * The Grow transition is used by the [Tooltip](/material-ui/react-tooltip/) and\n * [Popover](/material-ui/react-popover/) components.\n * It uses [react-transition-group](https://github.com/reactjs/react-transition-group) internally.\n */\nconst Grow = /*#__PURE__*/React.forwardRef(function Grow(props, ref) {\n const {\n addEndListener,\n appear = true,\n children,\n easing,\n in: inProp,\n onEnter,\n onEntered,\n onEntering,\n onExit,\n onExited,\n onExiting,\n style,\n timeout = 'auto',\n // eslint-disable-next-line react/prop-types\n TransitionComponent = Transition\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const timer = useTimeout();\n const autoTimeout = React.useRef();\n const theme = useTheme();\n const nodeRef = React.useRef(null);\n const handleRef = useForkRef(nodeRef, children.ref, ref);\n const normalizedTransitionCallback = callback => maybeIsAppearing => {\n if (callback) {\n const node = nodeRef.current;\n\n // onEnterXxx and onExitXxx callbacks have a different arguments.length value.\n if (maybeIsAppearing === undefined) {\n callback(node);\n } else {\n callback(node, maybeIsAppearing);\n }\n }\n };\n const handleEntering = normalizedTransitionCallback(onEntering);\n const handleEnter = normalizedTransitionCallback((node, isAppearing) => {\n reflow(node); // So the animation always start from the start.\n\n const {\n duration: transitionDuration,\n delay,\n easing: transitionTimingFunction\n } = getTransitionProps({\n style,\n timeout,\n easing\n }, {\n mode: 'enter'\n });\n let duration;\n if (timeout === 'auto') {\n duration = theme.transitions.getAutoHeightDuration(node.clientHeight);\n autoTimeout.current = duration;\n } else {\n duration = transitionDuration;\n }\n node.style.transition = [theme.transitions.create('opacity', {\n duration,\n delay\n }), theme.transitions.create('transform', {\n duration: isWebKit154 ? duration : duration * 0.666,\n delay,\n easing: transitionTimingFunction\n })].join(',');\n if (onEnter) {\n onEnter(node, isAppearing);\n }\n });\n const handleEntered = normalizedTransitionCallback(onEntered);\n const handleExiting = normalizedTransitionCallback(onExiting);\n const handleExit = normalizedTransitionCallback(node => {\n const {\n duration: transitionDuration,\n delay,\n easing: transitionTimingFunction\n } = getTransitionProps({\n style,\n timeout,\n easing\n }, {\n mode: 'exit'\n });\n let duration;\n if (timeout === 'auto') {\n duration = theme.transitions.getAutoHeightDuration(node.clientHeight);\n autoTimeout.current = duration;\n } else {\n duration = transitionDuration;\n }\n node.style.transition = [theme.transitions.create('opacity', {\n duration,\n delay\n }), theme.transitions.create('transform', {\n duration: isWebKit154 ? duration : duration * 0.666,\n delay: isWebKit154 ? delay : delay || duration * 0.333,\n easing: transitionTimingFunction\n })].join(',');\n node.style.opacity = 0;\n node.style.transform = getScale(0.75);\n if (onExit) {\n onExit(node);\n }\n });\n const handleExited = normalizedTransitionCallback(onExited);\n const handleAddEndListener = next => {\n if (timeout === 'auto') {\n timer.start(autoTimeout.current || 0, next);\n }\n if (addEndListener) {\n // Old call signature before `react-transition-group` implemented `nodeRef`\n addEndListener(nodeRef.current, next);\n }\n };\n return /*#__PURE__*/_jsx(TransitionComponent, _extends({\n appear: appear,\n in: inProp,\n nodeRef: nodeRef,\n onEnter: handleEnter,\n onEntered: handleEntered,\n onEntering: handleEntering,\n onExit: handleExit,\n onExited: handleExited,\n onExiting: handleExiting,\n addEndListener: handleAddEndListener,\n timeout: timeout === 'auto' ? null : timeout\n }, other, {\n children: (state, childProps) => {\n return /*#__PURE__*/React.cloneElement(children, _extends({\n style: _extends({\n opacity: 0,\n transform: getScale(0.75),\n visibility: state === 'exited' && !inProp ? 'hidden' : undefined\n }, styles[state], style, children.props.style),\n ref: handleRef\n }, childProps));\n }\n }));\n});\nprocess.env.NODE_ENV !== \"production\" ? Grow.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the d.ts file and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * Add a custom transition end trigger. Called with the transitioning DOM\n * node and a done callback. Allows for more fine grained transition end\n * logic. Note: Timeouts are still used as a fallback if provided.\n */\n addEndListener: PropTypes.func,\n /**\n * Perform the enter transition when it first mounts if `in` is also `true`.\n * Set this to `false` to disable this behavior.\n * @default true\n */\n appear: PropTypes.bool,\n /**\n * A single child content element.\n */\n children: elementAcceptingRef.isRequired,\n /**\n * The transition timing function.\n * You may specify a single easing or a object containing enter and exit values.\n */\n easing: PropTypes.oneOfType([PropTypes.shape({\n enter: PropTypes.string,\n exit: PropTypes.string\n }), PropTypes.string]),\n /**\n * If `true`, the component will transition in.\n */\n in: PropTypes.bool,\n /**\n * @ignore\n */\n onEnter: PropTypes.func,\n /**\n * @ignore\n */\n onEntered: PropTypes.func,\n /**\n * @ignore\n */\n onEntering: PropTypes.func,\n /**\n * @ignore\n */\n onExit: PropTypes.func,\n /**\n * @ignore\n */\n onExited: PropTypes.func,\n /**\n * @ignore\n */\n onExiting: PropTypes.func,\n /**\n * @ignore\n */\n style: PropTypes.object,\n /**\n * The duration for the transition, in milliseconds.\n * You may specify a single timeout for all transitions, or individually with an object.\n *\n * Set to 'auto' to automatically calculate transition time based on height.\n * @default 'auto'\n */\n timeout: PropTypes.oneOfType([PropTypes.oneOf(['auto']), PropTypes.number, PropTypes.shape({\n appear: PropTypes.number,\n enter: PropTypes.number,\n exit: PropTypes.number\n })])\n} : void 0;\nGrow.muiSupportAuto = true;\nexport default Grow;","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"anchorEl\", \"component\", \"components\", \"componentsProps\", \"container\", \"disablePortal\", \"keepMounted\", \"modifiers\", \"open\", \"placement\", \"popperOptions\", \"popperRef\", \"transition\", \"slots\", \"slotProps\"];\nimport { Popper as BasePopper } from '@mui/base/Popper';\nimport { useThemeWithoutDefault as useTheme } from '@mui/system';\nimport { HTMLElementType, refType } from '@mui/utils';\nimport PropTypes from 'prop-types';\nimport * as React from 'react';\nimport { styled, useThemeProps } from '../styles';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nconst PopperRoot = styled(BasePopper, {\n name: 'MuiPopper',\n slot: 'Root',\n overridesResolver: (props, styles) => styles.root\n})({});\n\n/**\n *\n * Demos:\n *\n * - [Autocomplete](https://mui.com/material-ui/react-autocomplete/)\n * - [Menu](https://mui.com/material-ui/react-menu/)\n * - [Popper](https://mui.com/material-ui/react-popper/)\n *\n * API:\n *\n * - [Popper API](https://mui.com/material-ui/api/popper/)\n */\nconst Popper = /*#__PURE__*/React.forwardRef(function Popper(inProps, ref) {\n var _slots$root;\n const theme = useTheme();\n const props = useThemeProps({\n props: inProps,\n name: 'MuiPopper'\n });\n const {\n anchorEl,\n component,\n components,\n componentsProps,\n container,\n disablePortal,\n keepMounted,\n modifiers,\n open,\n placement,\n popperOptions,\n popperRef,\n transition,\n slots,\n slotProps\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const RootComponent = (_slots$root = slots == null ? void 0 : slots.root) != null ? _slots$root : components == null ? void 0 : components.Root;\n const otherProps = _extends({\n anchorEl,\n container,\n disablePortal,\n keepMounted,\n modifiers,\n open,\n placement,\n popperOptions,\n popperRef,\n transition\n }, other);\n return /*#__PURE__*/_jsx(PopperRoot, _extends({\n as: component,\n direction: theme == null ? void 0 : theme.direction,\n slots: {\n root: RootComponent\n },\n slotProps: slotProps != null ? slotProps : componentsProps\n }, otherProps, {\n ref: ref\n }));\n});\nprocess.env.NODE_ENV !== \"production\" ? Popper.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * An HTML element, [virtualElement](https://popper.js.org/docs/v2/virtual-elements/),\n * or a function that returns either.\n * It's used to set the position of the popper.\n * The return value will passed as the reference object of the Popper instance.\n */\n anchorEl: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.object, PropTypes.func]),\n /**\n * Popper render function or node.\n */\n children: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.node, PropTypes.func]),\n /**\n * The component used for the root node.\n * Either a string to use a HTML element or a component.\n */\n component: PropTypes.elementType,\n /**\n * The components used for each slot inside the Popper.\n * Either a string to use a HTML element or a component.\n * @default {}\n */\n components: PropTypes.shape({\n Root: PropTypes.elementType\n }),\n /**\n * The props used for each slot inside the Popper.\n * @default {}\n */\n componentsProps: PropTypes.shape({\n root: PropTypes.oneOfType([PropTypes.func, PropTypes.object])\n }),\n /**\n * An HTML element or function that returns one.\n * The `container` will have the portal children appended to it.\n *\n * You can also provide a callback, which is called in a React layout effect.\n * This lets you set the container from a ref, and also makes server-side rendering possible.\n *\n * By default, it uses the body of the top-level document object,\n * so it's simply `document.body` most of the time.\n */\n container: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.func]),\n /**\n * The `children` will be under the DOM hierarchy of the parent component.\n * @default false\n */\n disablePortal: PropTypes.bool,\n /**\n * Always keep the children in the DOM.\n * This prop can be useful in SEO situation or\n * when you want to maximize the responsiveness of the Popper.\n * @default false\n */\n keepMounted: PropTypes.bool,\n /**\n * Popper.js is based on a \"plugin-like\" architecture,\n * most of its features are fully encapsulated \"modifiers\".\n *\n * A modifier is a function that is called each time Popper.js needs to\n * compute the position of the popper.\n * For this reason, modifiers should be very performant to avoid bottlenecks.\n * To learn how to create a modifier, [read the modifiers documentation](https://popper.js.org/docs/v2/modifiers/).\n */\n modifiers: PropTypes.arrayOf(PropTypes.shape({\n data: PropTypes.object,\n effect: PropTypes.func,\n enabled: PropTypes.bool,\n fn: PropTypes.func,\n name: PropTypes.any,\n options: PropTypes.object,\n phase: PropTypes.oneOf(['afterMain', 'afterRead', 'afterWrite', 'beforeMain', 'beforeRead', 'beforeWrite', 'main', 'read', 'write']),\n requires: PropTypes.arrayOf(PropTypes.string),\n requiresIfExists: PropTypes.arrayOf(PropTypes.string)\n })),\n /**\n * If `true`, the component is shown.\n */\n open: PropTypes.bool.isRequired,\n /**\n * Popper placement.\n * @default 'bottom'\n */\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n /**\n * Options provided to the [`Popper.js`](https://popper.js.org/docs/v2/constructors/#options) instance.\n * @default {}\n */\n popperOptions: PropTypes.shape({\n modifiers: PropTypes.array,\n onFirstUpdate: PropTypes.func,\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n strategy: PropTypes.oneOf(['absolute', 'fixed'])\n }),\n /**\n * A ref that points to the used popper instance.\n */\n popperRef: refType,\n /**\n * The props used for each slot inside the Popper.\n * @default {}\n */\n slotProps: PropTypes.shape({\n root: PropTypes.oneOfType([PropTypes.func, PropTypes.object])\n }),\n /**\n * The components used for each slot inside the Popper.\n * Either a string to use a HTML element or a component.\n * @default {}\n */\n slots: PropTypes.shape({\n root: PropTypes.elementType\n }),\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Help supporting a react-transition-group/Transition component.\n * @default false\n */\n transition: PropTypes.bool\n} : void 0;\nexport default Popper;","import generateUtilityClasses from '@mui/utils/generateUtilityClasses';\nimport generateUtilityClass from '@mui/utils/generateUtilityClass';\nexport function getTooltipUtilityClass(slot) {\n return generateUtilityClass('MuiTooltip', slot);\n}\nconst tooltipClasses = generateUtilityClasses('MuiTooltip', ['popper', 'popperInteractive', 'popperArrow', 'popperClose', 'tooltip', 'tooltipArrow', 'touch', 'tooltipPlacementLeft', 'tooltipPlacementRight', 'tooltipPlacementTop', 'tooltipPlacementBottom', 'arrow']);\nexport default tooltipClasses;","'use client';\n\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nconst _excluded = [\"arrow\", \"children\", \"classes\", \"components\", \"componentsProps\", \"describeChild\", \"disableFocusListener\", \"disableHoverListener\", \"disableInteractive\", \"disableTouchListener\", \"enterDelay\", \"enterNextDelay\", \"enterTouchDelay\", \"followCursor\", \"id\", \"leaveDelay\", \"leaveTouchDelay\", \"onClose\", \"onOpen\", \"open\", \"placement\", \"PopperComponent\", \"PopperProps\", \"slotProps\", \"slots\", \"title\", \"TransitionComponent\", \"TransitionProps\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport clsx from 'clsx';\nimport { elementAcceptingRef, unstable_useTimeout as useTimeout, unstable_Timeout as Timeout } from '@mui/utils';\nimport { unstable_composeClasses as composeClasses, appendOwnerState } from '@mui/base';\nimport { alpha } from '@mui/system';\nimport styled from '../styles/styled';\nimport useTheme from '../styles/useTheme';\nimport useThemeProps from '../styles/useThemeProps';\nimport capitalize from '../utils/capitalize';\nimport Grow from '../Grow';\nimport Popper from '../Popper';\nimport useEventCallback from '../utils/useEventCallback';\nimport useForkRef from '../utils/useForkRef';\nimport useId from '../utils/useId';\nimport useIsFocusVisible from '../utils/useIsFocusVisible';\nimport useControlled from '../utils/useControlled';\nimport tooltipClasses, { getTooltipUtilityClass } from './tooltipClasses';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nimport { jsxs as _jsxs } from \"react/jsx-runtime\";\nfunction round(value) {\n return Math.round(value * 1e5) / 1e5;\n}\nconst useUtilityClasses = ownerState => {\n const {\n classes,\n disableInteractive,\n arrow,\n touch,\n placement\n } = ownerState;\n const slots = {\n popper: ['popper', !disableInteractive && 'popperInteractive', arrow && 'popperArrow'],\n tooltip: ['tooltip', arrow && 'tooltipArrow', touch && 'touch', `tooltipPlacement${capitalize(placement.split('-')[0])}`],\n arrow: ['arrow']\n };\n return composeClasses(slots, getTooltipUtilityClass, classes);\n};\nconst TooltipPopper = styled(Popper, {\n name: 'MuiTooltip',\n slot: 'Popper',\n overridesResolver: (props, styles) => {\n const {\n ownerState\n } = props;\n return [styles.popper, !ownerState.disableInteractive && styles.popperInteractive, ownerState.arrow && styles.popperArrow, !ownerState.open && styles.popperClose];\n }\n})(({\n theme,\n ownerState,\n open\n}) => _extends({\n zIndex: (theme.vars || theme).zIndex.tooltip,\n pointerEvents: 'none'\n}, !ownerState.disableInteractive && {\n pointerEvents: 'auto'\n}, !open && {\n pointerEvents: 'none'\n}, ownerState.arrow && {\n [`&[data-popper-placement*=\"bottom\"] .${tooltipClasses.arrow}`]: {\n top: 0,\n marginTop: '-0.71em',\n '&::before': {\n transformOrigin: '0 100%'\n }\n },\n [`&[data-popper-placement*=\"top\"] .${tooltipClasses.arrow}`]: {\n bottom: 0,\n marginBottom: '-0.71em',\n '&::before': {\n transformOrigin: '100% 0'\n }\n },\n [`&[data-popper-placement*=\"right\"] .${tooltipClasses.arrow}`]: _extends({}, !ownerState.isRtl ? {\n left: 0,\n marginLeft: '-0.71em'\n } : {\n right: 0,\n marginRight: '-0.71em'\n }, {\n height: '1em',\n width: '0.71em',\n '&::before': {\n transformOrigin: '100% 100%'\n }\n }),\n [`&[data-popper-placement*=\"left\"] .${tooltipClasses.arrow}`]: _extends({}, !ownerState.isRtl ? {\n right: 0,\n marginRight: '-0.71em'\n } : {\n left: 0,\n marginLeft: '-0.71em'\n }, {\n height: '1em',\n width: '0.71em',\n '&::before': {\n transformOrigin: '0 0'\n }\n })\n}));\nconst TooltipTooltip = styled('div', {\n name: 'MuiTooltip',\n slot: 'Tooltip',\n overridesResolver: (props, styles) => {\n const {\n ownerState\n } = props;\n return [styles.tooltip, ownerState.touch && styles.touch, ownerState.arrow && styles.tooltipArrow, styles[`tooltipPlacement${capitalize(ownerState.placement.split('-')[0])}`]];\n }\n})(({\n theme,\n ownerState\n}) => _extends({\n backgroundColor: theme.vars ? theme.vars.palette.Tooltip.bg : alpha(theme.palette.grey[700], 0.92),\n borderRadius: (theme.vars || theme).shape.borderRadius,\n color: (theme.vars || theme).palette.common.white,\n fontFamily: theme.typography.fontFamily,\n padding: '4px 8px',\n fontSize: theme.typography.pxToRem(11),\n maxWidth: 300,\n margin: 2,\n wordWrap: 'break-word',\n fontWeight: theme.typography.fontWeightMedium\n}, ownerState.arrow && {\n position: 'relative',\n margin: 0\n}, ownerState.touch && {\n padding: '8px 16px',\n fontSize: theme.typography.pxToRem(14),\n lineHeight: `${round(16 / 14)}em`,\n fontWeight: theme.typography.fontWeightRegular\n}, {\n [`.${tooltipClasses.popper}[data-popper-placement*=\"left\"] &`]: _extends({\n transformOrigin: 'right center'\n }, !ownerState.isRtl ? _extends({\n marginRight: '14px'\n }, ownerState.touch && {\n marginRight: '24px'\n }) : _extends({\n marginLeft: '14px'\n }, ownerState.touch && {\n marginLeft: '24px'\n })),\n [`.${tooltipClasses.popper}[data-popper-placement*=\"right\"] &`]: _extends({\n transformOrigin: 'left center'\n }, !ownerState.isRtl ? _extends({\n marginLeft: '14px'\n }, ownerState.touch && {\n marginLeft: '24px'\n }) : _extends({\n marginRight: '14px'\n }, ownerState.touch && {\n marginRight: '24px'\n })),\n [`.${tooltipClasses.popper}[data-popper-placement*=\"top\"] &`]: _extends({\n transformOrigin: 'center bottom',\n marginBottom: '14px'\n }, ownerState.touch && {\n marginBottom: '24px'\n }),\n [`.${tooltipClasses.popper}[data-popper-placement*=\"bottom\"] &`]: _extends({\n transformOrigin: 'center top',\n marginTop: '14px'\n }, ownerState.touch && {\n marginTop: '24px'\n })\n}));\nconst TooltipArrow = styled('span', {\n name: 'MuiTooltip',\n slot: 'Arrow',\n overridesResolver: (props, styles) => styles.arrow\n})(({\n theme\n}) => ({\n overflow: 'hidden',\n position: 'absolute',\n width: '1em',\n height: '0.71em' /* = width / sqrt(2) = (length of the hypotenuse) */,\n boxSizing: 'border-box',\n color: theme.vars ? theme.vars.palette.Tooltip.bg : alpha(theme.palette.grey[700], 0.9),\n '&::before': {\n content: '\"\"',\n margin: 'auto',\n display: 'block',\n width: '100%',\n height: '100%',\n backgroundColor: 'currentColor',\n transform: 'rotate(45deg)'\n }\n}));\nlet hystersisOpen = false;\nconst hystersisTimer = new Timeout();\nlet cursorPosition = {\n x: 0,\n y: 0\n};\nexport function testReset() {\n hystersisOpen = false;\n hystersisTimer.clear();\n}\nfunction composeEventHandler(handler, eventHandler) {\n return event => {\n if (eventHandler) {\n eventHandler(event);\n }\n handler(event);\n };\n}\n\n// TODO v6: Remove PopperComponent, PopperProps, TransitionComponent and TransitionProps.\nconst Tooltip = /*#__PURE__*/React.forwardRef(function Tooltip(inProps, ref) {\n var _ref, _slots$popper, _ref2, _ref3, _slots$transition, _ref4, _slots$tooltip, _ref5, _slots$arrow, _slotProps$popper, _ref6, _slotProps$popper2, _slotProps$transition, _slotProps$tooltip, _ref7, _slotProps$tooltip2, _slotProps$arrow, _ref8, _slotProps$arrow2;\n const props = useThemeProps({\n props: inProps,\n name: 'MuiTooltip'\n });\n const {\n arrow = false,\n children: childrenProp,\n components = {},\n componentsProps = {},\n describeChild = false,\n disableFocusListener = false,\n disableHoverListener = false,\n disableInteractive: disableInteractiveProp = false,\n disableTouchListener = false,\n enterDelay = 100,\n enterNextDelay = 0,\n enterTouchDelay = 700,\n followCursor = false,\n id: idProp,\n leaveDelay = 0,\n leaveTouchDelay = 1500,\n onClose,\n onOpen,\n open: openProp,\n placement = 'bottom',\n PopperComponent: PopperComponentProp,\n PopperProps = {},\n slotProps = {},\n slots = {},\n title,\n TransitionComponent: TransitionComponentProp = Grow,\n TransitionProps\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n\n // to prevent runtime errors, developers will need to provide a child as a React element anyway.\n const children = /*#__PURE__*/React.isValidElement(childrenProp) ? childrenProp : /*#__PURE__*/_jsx(\"span\", {\n children: childrenProp\n });\n const theme = useTheme();\n const isRtl = theme.direction === 'rtl';\n const [childNode, setChildNode] = React.useState();\n const [arrowRef, setArrowRef] = React.useState(null);\n const ignoreNonTouchEvents = React.useRef(false);\n const disableInteractive = disableInteractiveProp || followCursor;\n const closeTimer = useTimeout();\n const enterTimer = useTimeout();\n const leaveTimer = useTimeout();\n const touchTimer = useTimeout();\n const [openState, setOpenState] = useControlled({\n controlled: openProp,\n default: false,\n name: 'Tooltip',\n state: 'open'\n });\n let open = openState;\n if (process.env.NODE_ENV !== 'production') {\n // eslint-disable-next-line react-hooks/rules-of-hooks\n const {\n current: isControlled\n } = React.useRef(openProp !== undefined);\n\n // eslint-disable-next-line react-hooks/rules-of-hooks\n React.useEffect(() => {\n if (childNode && childNode.disabled && !isControlled && title !== '' && childNode.tagName.toLowerCase() === 'button') {\n console.error(['MUI: You are providing a disabled `button` child to the Tooltip component.', 'A disabled element does not fire events.', \"Tooltip needs to listen to the child element's events to display the title.\", '', 'Add a simple wrapper element, such as a `span`.'].join('\\n'));\n }\n }, [title, childNode, isControlled]);\n }\n const id = useId(idProp);\n const prevUserSelect = React.useRef();\n const stopTouchInteraction = useEventCallback(() => {\n if (prevUserSelect.current !== undefined) {\n document.body.style.WebkitUserSelect = prevUserSelect.current;\n prevUserSelect.current = undefined;\n }\n touchTimer.clear();\n });\n React.useEffect(() => stopTouchInteraction, [stopTouchInteraction]);\n const handleOpen = event => {\n hystersisTimer.clear();\n hystersisOpen = true;\n\n // The mouseover event will trigger for every nested element in the tooltip.\n // We can skip rerendering when the tooltip is already open.\n // We are using the mouseover event instead of the mouseenter event to fix a hide/show issue.\n setOpenState(true);\n if (onOpen && !open) {\n onOpen(event);\n }\n };\n const handleClose = useEventCallback(\n /**\n * @param {React.SyntheticEvent | Event} event\n */\n event => {\n hystersisTimer.start(800 + leaveDelay, () => {\n hystersisOpen = false;\n });\n setOpenState(false);\n if (onClose && open) {\n onClose(event);\n }\n closeTimer.start(theme.transitions.duration.shortest, () => {\n ignoreNonTouchEvents.current = false;\n });\n });\n const handleEnter = event => {\n if (ignoreNonTouchEvents.current && event.type !== 'touchstart') {\n return;\n }\n\n // Remove the title ahead of time.\n // We don't want to wait for the next render commit.\n // We would risk displaying two tooltips at the same time (native + this one).\n if (childNode) {\n childNode.removeAttribute('title');\n }\n enterTimer.clear();\n leaveTimer.clear();\n if (enterDelay || hystersisOpen && enterNextDelay) {\n enterTimer.start(hystersisOpen ? enterNextDelay : enterDelay, () => {\n handleOpen(event);\n });\n } else {\n handleOpen(event);\n }\n };\n const handleLeave = event => {\n enterTimer.clear();\n leaveTimer.start(leaveDelay, () => {\n handleClose(event);\n });\n };\n const {\n isFocusVisibleRef,\n onBlur: handleBlurVisible,\n onFocus: handleFocusVisible,\n ref: focusVisibleRef\n } = useIsFocusVisible();\n // We don't necessarily care about the focusVisible state (which is safe to access via ref anyway).\n // We just need to re-render the Tooltip if the focus-visible state changes.\n const [, setChildIsFocusVisible] = React.useState(false);\n const handleBlur = event => {\n handleBlurVisible(event);\n if (isFocusVisibleRef.current === false) {\n setChildIsFocusVisible(false);\n handleLeave(event);\n }\n };\n const handleFocus = event => {\n // Workaround for https://github.com/facebook/react/issues/7769\n // The autoFocus of React might trigger the event before the componentDidMount.\n // We need to account for this eventuality.\n if (!childNode) {\n setChildNode(event.currentTarget);\n }\n handleFocusVisible(event);\n if (isFocusVisibleRef.current === true) {\n setChildIsFocusVisible(true);\n handleEnter(event);\n }\n };\n const detectTouchStart = event => {\n ignoreNonTouchEvents.current = true;\n const childrenProps = children.props;\n if (childrenProps.onTouchStart) {\n childrenProps.onTouchStart(event);\n }\n };\n const handleMouseOver = handleEnter;\n const handleMouseLeave = handleLeave;\n const handleTouchStart = event => {\n detectTouchStart(event);\n leaveTimer.clear();\n closeTimer.clear();\n stopTouchInteraction();\n prevUserSelect.current = document.body.style.WebkitUserSelect;\n // Prevent iOS text selection on long-tap.\n document.body.style.WebkitUserSelect = 'none';\n touchTimer.start(enterTouchDelay, () => {\n document.body.style.WebkitUserSelect = prevUserSelect.current;\n handleEnter(event);\n });\n };\n const handleTouchEnd = event => {\n if (children.props.onTouchEnd) {\n children.props.onTouchEnd(event);\n }\n stopTouchInteraction();\n leaveTimer.start(leaveTouchDelay, () => {\n handleClose(event);\n });\n };\n React.useEffect(() => {\n if (!open) {\n return undefined;\n }\n\n /**\n * @param {KeyboardEvent} nativeEvent\n */\n function handleKeyDown(nativeEvent) {\n // IE11, Edge (prior to using Bink?) use 'Esc'\n if (nativeEvent.key === 'Escape' || nativeEvent.key === 'Esc') {\n handleClose(nativeEvent);\n }\n }\n document.addEventListener('keydown', handleKeyDown);\n return () => {\n document.removeEventListener('keydown', handleKeyDown);\n };\n }, [handleClose, open]);\n const handleRef = useForkRef(children.ref, focusVisibleRef, setChildNode, ref);\n\n // There is no point in displaying an empty tooltip.\n // So we exclude all falsy values, except 0, which is valid.\n if (!title && title !== 0) {\n open = false;\n }\n const popperRef = React.useRef();\n const handleMouseMove = event => {\n const childrenProps = children.props;\n if (childrenProps.onMouseMove) {\n childrenProps.onMouseMove(event);\n }\n cursorPosition = {\n x: event.clientX,\n y: event.clientY\n };\n if (popperRef.current) {\n popperRef.current.update();\n }\n };\n const nameOrDescProps = {};\n const titleIsString = typeof title === 'string';\n if (describeChild) {\n nameOrDescProps.title = !open && titleIsString && !disableHoverListener ? title : null;\n nameOrDescProps['aria-describedby'] = open ? id : null;\n } else {\n nameOrDescProps['aria-label'] = titleIsString ? title : null;\n nameOrDescProps['aria-labelledby'] = open && !titleIsString ? id : null;\n }\n const childrenProps = _extends({}, nameOrDescProps, other, children.props, {\n className: clsx(other.className, children.props.className),\n onTouchStart: detectTouchStart,\n ref: handleRef\n }, followCursor ? {\n onMouseMove: handleMouseMove\n } : {});\n if (process.env.NODE_ENV !== 'production') {\n childrenProps['data-mui-internal-clone-element'] = true;\n\n // eslint-disable-next-line react-hooks/rules-of-hooks\n React.useEffect(() => {\n if (childNode && !childNode.getAttribute('data-mui-internal-clone-element')) {\n console.error(['MUI: The `children` component of the Tooltip is not forwarding its props correctly.', 'Please make sure that props are spread on the same element that the ref is applied to.'].join('\\n'));\n }\n }, [childNode]);\n }\n const interactiveWrapperListeners = {};\n if (!disableTouchListener) {\n childrenProps.onTouchStart = handleTouchStart;\n childrenProps.onTouchEnd = handleTouchEnd;\n }\n if (!disableHoverListener) {\n childrenProps.onMouseOver = composeEventHandler(handleMouseOver, childrenProps.onMouseOver);\n childrenProps.onMouseLeave = composeEventHandler(handleMouseLeave, childrenProps.onMouseLeave);\n if (!disableInteractive) {\n interactiveWrapperListeners.onMouseOver = handleMouseOver;\n interactiveWrapperListeners.onMouseLeave = handleMouseLeave;\n }\n }\n if (!disableFocusListener) {\n childrenProps.onFocus = composeEventHandler(handleFocus, childrenProps.onFocus);\n childrenProps.onBlur = composeEventHandler(handleBlur, childrenProps.onBlur);\n if (!disableInteractive) {\n interactiveWrapperListeners.onFocus = handleFocus;\n interactiveWrapperListeners.onBlur = handleBlur;\n }\n }\n if (process.env.NODE_ENV !== 'production') {\n if (children.props.title) {\n console.error(['MUI: You have provided a `title` prop to the child of .', `Remove this title prop \\`${children.props.title}\\` or the Tooltip component.`].join('\\n'));\n }\n }\n const popperOptions = React.useMemo(() => {\n var _PopperProps$popperOp;\n let tooltipModifiers = [{\n name: 'arrow',\n enabled: Boolean(arrowRef),\n options: {\n element: arrowRef,\n padding: 4\n }\n }];\n if ((_PopperProps$popperOp = PopperProps.popperOptions) != null && _PopperProps$popperOp.modifiers) {\n tooltipModifiers = tooltipModifiers.concat(PopperProps.popperOptions.modifiers);\n }\n return _extends({}, PopperProps.popperOptions, {\n modifiers: tooltipModifiers\n });\n }, [arrowRef, PopperProps]);\n const ownerState = _extends({}, props, {\n isRtl,\n arrow,\n disableInteractive,\n placement,\n PopperComponentProp,\n touch: ignoreNonTouchEvents.current\n });\n const classes = useUtilityClasses(ownerState);\n const PopperComponent = (_ref = (_slots$popper = slots.popper) != null ? _slots$popper : components.Popper) != null ? _ref : TooltipPopper;\n const TransitionComponent = (_ref2 = (_ref3 = (_slots$transition = slots.transition) != null ? _slots$transition : components.Transition) != null ? _ref3 : TransitionComponentProp) != null ? _ref2 : Grow;\n const TooltipComponent = (_ref4 = (_slots$tooltip = slots.tooltip) != null ? _slots$tooltip : components.Tooltip) != null ? _ref4 : TooltipTooltip;\n const ArrowComponent = (_ref5 = (_slots$arrow = slots.arrow) != null ? _slots$arrow : components.Arrow) != null ? _ref5 : TooltipArrow;\n const popperProps = appendOwnerState(PopperComponent, _extends({}, PopperProps, (_slotProps$popper = slotProps.popper) != null ? _slotProps$popper : componentsProps.popper, {\n className: clsx(classes.popper, PopperProps == null ? void 0 : PopperProps.className, (_ref6 = (_slotProps$popper2 = slotProps.popper) != null ? _slotProps$popper2 : componentsProps.popper) == null ? void 0 : _ref6.className)\n }), ownerState);\n const transitionProps = appendOwnerState(TransitionComponent, _extends({}, TransitionProps, (_slotProps$transition = slotProps.transition) != null ? _slotProps$transition : componentsProps.transition), ownerState);\n const tooltipProps = appendOwnerState(TooltipComponent, _extends({}, (_slotProps$tooltip = slotProps.tooltip) != null ? _slotProps$tooltip : componentsProps.tooltip, {\n className: clsx(classes.tooltip, (_ref7 = (_slotProps$tooltip2 = slotProps.tooltip) != null ? _slotProps$tooltip2 : componentsProps.tooltip) == null ? void 0 : _ref7.className)\n }), ownerState);\n const tooltipArrowProps = appendOwnerState(ArrowComponent, _extends({}, (_slotProps$arrow = slotProps.arrow) != null ? _slotProps$arrow : componentsProps.arrow, {\n className: clsx(classes.arrow, (_ref8 = (_slotProps$arrow2 = slotProps.arrow) != null ? _slotProps$arrow2 : componentsProps.arrow) == null ? void 0 : _ref8.className)\n }), ownerState);\n return /*#__PURE__*/_jsxs(React.Fragment, {\n children: [/*#__PURE__*/React.cloneElement(children, childrenProps), /*#__PURE__*/_jsx(PopperComponent, _extends({\n as: PopperComponentProp != null ? PopperComponentProp : Popper,\n placement: placement,\n anchorEl: followCursor ? {\n getBoundingClientRect: () => ({\n top: cursorPosition.y,\n left: cursorPosition.x,\n right: cursorPosition.x,\n bottom: cursorPosition.y,\n width: 0,\n height: 0\n })\n } : childNode,\n popperRef: popperRef,\n open: childNode ? open : false,\n id: id,\n transition: true\n }, interactiveWrapperListeners, popperProps, {\n popperOptions: popperOptions,\n children: ({\n TransitionProps: TransitionPropsInner\n }) => /*#__PURE__*/_jsx(TransitionComponent, _extends({\n timeout: theme.transitions.duration.shorter\n }, TransitionPropsInner, transitionProps, {\n children: /*#__PURE__*/_jsxs(TooltipComponent, _extends({}, tooltipProps, {\n children: [title, arrow ? /*#__PURE__*/_jsx(ArrowComponent, _extends({}, tooltipArrowProps, {\n ref: setArrowRef\n })) : null]\n }))\n }))\n }))]\n });\n});\nprocess.env.NODE_ENV !== \"production\" ? Tooltip.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the d.ts file and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * If `true`, adds an arrow to the tooltip.\n * @default false\n */\n arrow: PropTypes.bool,\n /**\n * Tooltip reference element.\n */\n children: elementAcceptingRef.isRequired,\n /**\n * Override or extend the styles applied to the component.\n */\n classes: PropTypes.object,\n /**\n * @ignore\n */\n className: PropTypes.string,\n /**\n * The components used for each slot inside.\n *\n * This prop is an alias for the `slots` prop.\n * It's recommended to use the `slots` prop instead.\n *\n * @default {}\n */\n components: PropTypes.shape({\n Arrow: PropTypes.elementType,\n Popper: PropTypes.elementType,\n Tooltip: PropTypes.elementType,\n Transition: PropTypes.elementType\n }),\n /**\n * The extra props for the slot components.\n * You can override the existing props or add new ones.\n *\n * This prop is an alias for the `slotProps` prop.\n * It's recommended to use the `slotProps` prop instead, as `componentsProps` will be deprecated in the future.\n *\n * @default {}\n */\n componentsProps: PropTypes.shape({\n arrow: PropTypes.object,\n popper: PropTypes.object,\n tooltip: PropTypes.object,\n transition: PropTypes.object\n }),\n /**\n * Set to `true` if the `title` acts as an accessible description.\n * By default the `title` acts as an accessible label for the child.\n * @default false\n */\n describeChild: PropTypes.bool,\n /**\n * Do not respond to focus-visible events.\n * @default false\n */\n disableFocusListener: PropTypes.bool,\n /**\n * Do not respond to hover events.\n * @default false\n */\n disableHoverListener: PropTypes.bool,\n /**\n * Makes a tooltip not interactive, i.e. it will close when the user\n * hovers over the tooltip before the `leaveDelay` is expired.\n * @default false\n */\n disableInteractive: PropTypes.bool,\n /**\n * Do not respond to long press touch events.\n * @default false\n */\n disableTouchListener: PropTypes.bool,\n /**\n * The number of milliseconds to wait before showing the tooltip.\n * This prop won't impact the enter touch delay (`enterTouchDelay`).\n * @default 100\n */\n enterDelay: PropTypes.number,\n /**\n * The number of milliseconds to wait before showing the tooltip when one was already recently opened.\n * @default 0\n */\n enterNextDelay: PropTypes.number,\n /**\n * The number of milliseconds a user must touch the element before showing the tooltip.\n * @default 700\n */\n enterTouchDelay: PropTypes.number,\n /**\n * If `true`, the tooltip follow the cursor over the wrapped element.\n * @default false\n */\n followCursor: PropTypes.bool,\n /**\n * This prop is used to help implement the accessibility logic.\n * If you don't provide this prop. It falls back to a randomly generated id.\n */\n id: PropTypes.string,\n /**\n * The number of milliseconds to wait before hiding the tooltip.\n * This prop won't impact the leave touch delay (`leaveTouchDelay`).\n * @default 0\n */\n leaveDelay: PropTypes.number,\n /**\n * The number of milliseconds after the user stops touching an element before hiding the tooltip.\n * @default 1500\n */\n leaveTouchDelay: PropTypes.number,\n /**\n * Callback fired when the component requests to be closed.\n *\n * @param {React.SyntheticEvent} event The event source of the callback.\n */\n onClose: PropTypes.func,\n /**\n * Callback fired when the component requests to be open.\n *\n * @param {React.SyntheticEvent} event The event source of the callback.\n */\n onOpen: PropTypes.func,\n /**\n * If `true`, the component is shown.\n */\n open: PropTypes.bool,\n /**\n * Tooltip placement.\n * @default 'bottom'\n */\n placement: PropTypes.oneOf(['bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n /**\n * The component used for the popper.\n * @default Popper\n */\n PopperComponent: PropTypes.elementType,\n /**\n * Props applied to the [`Popper`](/material-ui/api/popper/) element.\n * @default {}\n */\n PopperProps: PropTypes.object,\n /**\n * The extra props for the slot components.\n * You can override the existing props or add new ones.\n *\n * This prop is an alias for the `componentsProps` prop, which will be deprecated in the future.\n *\n * @default {}\n */\n slotProps: PropTypes.shape({\n arrow: PropTypes.object,\n popper: PropTypes.object,\n tooltip: PropTypes.object,\n transition: PropTypes.object\n }),\n /**\n * The components used for each slot inside.\n *\n * This prop is an alias for the `components` prop, which will be deprecated in the future.\n *\n * @default {}\n */\n slots: PropTypes.shape({\n arrow: PropTypes.elementType,\n popper: PropTypes.elementType,\n tooltip: PropTypes.elementType,\n transition: PropTypes.elementType\n }),\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Tooltip title. Zero-length titles string, undefined, null and false are never displayed.\n */\n title: PropTypes.node,\n /**\n * The component used for the transition.\n * [Follow this guide](/material-ui/transitions/#transitioncomponent-prop) to learn more about the requirements for this component.\n * @default Grow\n */\n TransitionComponent: PropTypes.elementType,\n /**\n * Props applied to the transition element.\n * By default, the element is based on this [`Transition`](http://reactcommunity.org/react-transition-group/transition/) component.\n */\n TransitionProps: PropTypes.object\n} : void 0;\nexport default Tooltip;","import '@/components/mui/menu-item.component.css';\nimport ArrowRightIcon from '@mui/icons-material/ArrowRight';\nimport {\n ListItemIcon as MuiListItemIcon,\n ListItemText as MuiListItemText,\n MenuItem as MuiMenuItem,\n} from '@mui/material';\nimport Tooltip from '@mui/material/Tooltip';\nimport { Localized, ReferencedItem, SingleColumnMenu } from 'platform-bible-utils';\nimport { MouseEvent, PropsWithChildren } from 'react';\n\ntype MenuItemInfoBase = {\n /** Text (displayable in the UI) as the name of the menu item */\n label: string;\n /** Text to display when the mouse hovers over the menu item */\n tooltip?: string;\n};\n\nexport type Command = MenuItemInfoBase & {\n /** Command to execute (string.string) */\n command: string;\n};\n\ntype SubMenu = MenuItemInfoBase & {\n /** Command to execute (string.string) */\n items: MenuItemInfo[];\n};\n\nexport interface CommandHandler {\n (command: Command): void;\n}\n\nexport type MenuPropsBase = {\n /*\n * The JSON defining the menu whose items are to be rendered. This will typically be one of the\n * menus in the \"defs\" in a Platform.Bible menu (see PlatformMenus). The schema for this is\n * menuDocumentSchema (at the end of menus.model.ts). Note that while this is a\n * \"SingleColumnMenu\", somewhat bizarrely, a MultiColumnMenu is a SingleColumnMenu, so it really\n * could be a MultiColumnMenu, in which case, column had better be defined so it can be used\n * to filter out the actual groups and items to display on the column.\n */\n menuDefinition: Localized;\n\n commandHandler: CommandHandler;\n\n /**\n * Additional action to perform when any menu item is clicked. Allows the caller to handle event\n * (e.g., to close the menu).\n */\n onClick?: (event: MouseEvent) => void;\n};\n\nexport type MenuItemListProps = MenuPropsBase & {\n /** Optional unique (column) identifier */\n columnId?: ReferencedItem;\n};\n\nexport type MenuItemProps = Omit &\n PropsWithChildren<{\n /** Optional unique identifier */\n id?: string;\n\n onClick: (event: MouseEvent) => void;\n }>;\n\ntype MenuItemInfo = (Command | SubMenu) & {\n /**\n * If specified, menu item will be inset if it does not have a leading icon.\n *\n * @default true\n */\n allowForLeadingIcons?: boolean;\n /**\n * If specified, the path to the icon image to display on the leading side of the menu text.\n *\n * @default undefined (no leading icon will be shown)\n */\n iconPathBefore?: string;\n /**\n * If specified, the path to the icon image to display on the trailing side of the menu text.\n *\n * @default undefined (no trailing icon will be shown)\n */\n iconPathAfter?: string;\n /**\n * If true, list item is focused during the first mount\n *\n * @default false\n */\n hasAutoFocus?: boolean;\n\n /** Additional css classes to help with unique styling of the menu item */\n className?: string;\n\n /**\n * If true, the menu item will appear disabled and it will not respond to clicks or mouse hovers.\n *\n * @default false\n */\n isDisabled?: boolean;\n\n /**\n * If true, compact vertical padding designed for keyboard and mouse input is used.\n *\n * @default true\n */\n isDense?: boolean;\n\n /**\n * If true, a right-arrow icon will be displayed (iconPathAfter, if specified, will be ignored).\n *\n * @default false\n */\n isSubMenuParent?: boolean;\n\n /**\n * If true, the left and right padding is removed\n *\n * @default false\n */\n hasDisabledGutters?: boolean;\n\n /**\n * If true, a 1px light border is added to bottom of menu item\n *\n * @default false\n */\n hasDivider?: boolean;\n\n /** Help identify which element has keyboard focus */\n focusVisibleClassName?: string;\n\n /** If it's a submenu, it should have the items property */\n items?: MenuItemInfo[];\n};\n\nfunction getIcon(icon: string | undefined, menuLabel: string, leading: boolean) {\n return icon ? (\n \n {`${leading\n \n ) : undefined;\n}\n\nexport default function MenuItem(props: MenuItemProps) {\n const {\n onClick,\n label,\n tooltip,\n allowForLeadingIcons = true,\n iconPathBefore = undefined,\n iconPathAfter = undefined,\n hasAutoFocus = false,\n className,\n isDisabled = false,\n isDense = true,\n isSubMenuParent = false,\n hasDisabledGutters = false,\n hasDivider = false,\n focusVisibleClassName,\n id,\n children,\n } = props;\n\n const menuItem = (\n \n {label ? (\n <>\n {getIcon(iconPathBefore, label, true)}\n \n {isSubMenuParent ? (\n \n \n \n ) : (\n getIcon(iconPathAfter, label, false)\n )}\n \n ) : (\n children\n )}\n \n );\n\n return tooltip ? (\n \n
    {menuItem}
    \n
    \n ) : (\n menuItem\n );\n}\n","import MenuItem, {\n MenuItemListProps,\n MenuItemProps,\n MenuPropsBase,\n} from '@/components/mui/menu-item.component';\nimport { Menu } from '@mui/material';\nimport {\n Localized,\n MenuGroupDetailsInSubMenu,\n MenuItemContainingCommand,\n MenuItemContainingSubmenu,\n OrderedExtensibleContainer,\n ReferencedItem,\n SingleColumnMenu,\n} from 'platform-bible-utils';\nimport { MouseEvent, useMemo, useState } from 'react';\n\n/**\n * All the exported types in this file should be regarded as \"internal\" (i.e., they should not be\n * exposed via index.ts).\n */\n\nexport type GroupedMenuPropsBase = MenuPropsBase & {\n /** Optional unique (column) identifier */\n columnId?: ReferencedItem;\n};\n\nexport type GroupedMenuItemListProps = MenuItemListProps & {\n /**\n * If the menuDefinition includes \"top-level\" groups (i.e., those that belong to a column as\n * opposed to those that belong to a submenu) that should not be included in the list, then this\n * array specifies which groups to include. Likewise, for a submenu, this list indicates which\n * groups are pertinent for that submenu. So then for a context menu this property need not be\n * specified since it is a top-level menu based on a \"true\" SingleColumnMenu (i.e., one that is\n * not a MultiColumnMenu).\n */\n includedGroups?: {\n id: string;\n group: Localized;\n }[];\n};\n\ninterface ItemInfo {\n item: Localized;\n isLastItemInGroup: boolean;\n}\n\ntype SubMenuProps = MenuPropsBase & {\n parentMenuItem: Localized;\n parentItemProps: Omit, 'iconPathAfter'>;\n};\n\nfunction getAllGroups(menuDefinition: Localized) {\n const groupEntries = Object.entries(menuDefinition.groups);\n // Convert array of entries to array of objects with id and group properties\n return groupEntries.map(([key, value]) => ({ id: key, group: value }));\n}\n\nfunction SubMenu(props: SubMenuProps) {\n const [anchorEl, setAnchorEl] = useState(undefined);\n\n const { parentMenuItem, parentItemProps, menuDefinition } = props;\n\n const handleParentMenuItemClick = (event: MouseEvent) => {\n setAnchorEl(event.currentTarget);\n };\n\n const handleClose = () => {\n setAnchorEl(undefined);\n };\n\n const renderSubMenuItems = () => {\n let includedGroups = getAllGroups(menuDefinition).filter((g) => 'menuItem' in g.group);\n\n // Ensure valid parent menu was provided. (If not, submenu will contain all groups!)\n if (!parentMenuItem?.id) throw new Error('A valid parent menu item is required for submenus.');\n\n // When laying out a submenu, only include groups associated with the provided parent menu.\n // Note: without the (annoying) redundant check that the included groups\n // have the menuItem field, TS doesn't think it exists.\n includedGroups = includedGroups.filter(\n (group) => 'menuItem' in group.group && group.group.menuItem === parentMenuItem.id,\n );\n\n return ;\n };\n\n return (\n <>\n \n \n {renderSubMenuItems()}\n \n \n );\n}\n\nconst getOrderedGroupItems = (\n groupId: string,\n allItems: Localized[],\n) => {\n // Filter items that belong to the specified group\n const itemsForGroup = allItems.filter((item) => item.group === groupId);\n // Sort items based on order\n const sortedItems = itemsForGroup.sort((a, b) => (a.order || 0) - (b.order || 0));\n return sortedItems;\n};\n\n/**\n * This component is internal; it does not need to be exposed to the outside world since it is not\n * useful on its own. It is used to generate and lay out the MenuItems that appear either on a\n * top-level menu (in a GridMenu or ContextMenu) or in a submenu.\n */\nexport default function GroupedMenuItemList(menuProps: GroupedMenuItemListProps) {\n const { menuDefinition, onClick, commandHandler, includedGroups } = menuProps;\n\n const { items, allowForLeadingIcons } = useMemo(() => {\n const groupsToInclude =\n includedGroups && includedGroups.length > 0\n ? includedGroups\n : // We're apparently laying out a single-column menu (presumably a context menu). In this\n // case, all groups should be included except ones that belong to a submenu.\n getAllGroups(menuDefinition).filter((g) => !('menuItem' in g.group));\n\n const sortedGroups = Object.values(groupsToInclude).sort(\n (a, b) => (a.group.order || 0) - (b.group.order || 0),\n );\n\n const itemArray: ItemInfo[] = [];\n\n sortedGroups.forEach((group) => {\n getOrderedGroupItems(group.id, menuDefinition.items).forEach((item) =>\n itemArray.push({ item, isLastItemInGroup: false }),\n );\n if (itemArray.length > 0) itemArray[itemArray.length - 1].isLastItemInGroup = true;\n });\n\n // No divider after last item in final group.\n if (itemArray.length > 0) itemArray[itemArray.length - 1].isLastItemInGroup = false;\n\n const allowSpaceForLeadingIcons = itemArray.some(\n (i) => 'iconPathBefore' in i.item && i.item.iconPathBefore,\n );\n\n return { items: itemArray, allowForLeadingIcons: allowSpaceForLeadingIcons };\n }, [includedGroups, menuDefinition]);\n\n // Create props for MenuItem component including setting hasDivider for the last item in a group\n const createMenuItemProps = ({ item, isLastItemInGroup }: ItemInfo) => {\n const menuItemProps = {\n className: 'papi-menu-item',\n label: item.label,\n tooltip: item.tooltip,\n iconPathBefore: 'iconPathBefore' in item ? item.iconPathBefore : undefined,\n iconPathAfter: 'iconPathAfter' in item ? item.iconPathAfter : undefined,\n hasDivider: isLastItemInGroup, // Set hasDivider to true for the last item in a group\n allowForLeadingIcons,\n };\n\n return menuItemProps;\n };\n\n const [firstItem] = items;\n\n if (!firstItem) return
    ;\n\n const divKey = firstItem.item.group;\n\n return (\n
    \n {items.map((itemInfo, index) => {\n const { item } = itemInfo;\n const menuItemProps = createMenuItemProps(itemInfo);\n if ('command' in item) {\n const key = item.group + index;\n return (\n ) => {\n onClick?.(event);\n commandHandler(item);\n }}\n {...menuItemProps}\n />\n );\n }\n return (\n \n );\n })}\n
    \n );\n}\n","import GroupedMenuItemList from '@/components/mui/grouped-menu-item-list.component';\nimport { MenuItemListProps } from '@/components/mui/menu-item.component';\nimport { MultiColumnMenu } from 'platform-bible-utils';\n\n/**\n * This component is internal; it does not need to be exposed to the outside world since it is not\n * useful on its own. Use either GridMenu or ContextMenu.\n */\nexport default function TopLevelMenu(props: MenuItemListProps) {\n const { menuDefinition, columnId } = props;\n\n const groupEntries = Object.entries(menuDefinition.groups);\n // Convert array of entries to array of objects with id and group properties\n const groups = groupEntries.map(([key, value]) => ({ id: key, group: value }));\n let includedGroups = groups.filter((g) => 'column' in g.group);\n\n // Check if column is provided and menuDefinition is a MultiColumnMenu\n if (\n columnId &&\n 'columns' in menuDefinition &&\n // Without this type assertion, TS doesn't know what columns is.\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n (menuDefinition as MultiColumnMenu).columns[columnId]\n ) {\n // When laying out a single column in a MultiColumnMenu, only include groups associated with\n // the provided column. Note: without the (annoying) redundant check that the included groups\n // have the colum field, TS doesn't think it exists.\n includedGroups = includedGroups.filter(\n (g) => 'column' in g.group && g.group.column === columnId,\n );\n }\n\n return ;\n}\n","import '@/components/mui/grid-menu.component.css';\nimport { GroupedMenuPropsBase } from '@/components/mui/grouped-menu-item-list.component';\nimport { CommandHandler } from '@/components/mui/menu-item.component';\nimport TopLevelMenu from '@/components/mui/top-level-menu.component';\nimport { Grid, List } from '@mui/material';\nimport {\n Localized,\n MenuColumnWithHeader,\n MultiColumnMenu,\n ReferencedItem,\n} from 'platform-bible-utils';\nimport { useMemo } from 'react';\n\ntype ColumnInfo = {\n /*\n * The ID (`${string}.${string}`) of a specific menu column.\n */\n id: ReferencedItem;\n\n /*\n * Metadata (label, order, etc.) for a specific menu column.\n */\n metadata: Localized;\n};\n\ntype MenuColumnProps = ColumnInfo &\n GroupedMenuPropsBase & {\n /** Additional css classes to help with unique styling of the menu column */\n className?: string;\n };\n\nexport type GridMenuInfo = {\n /** The menu object containing information about the columns, groups, and items to display. */\n multiColumnMenu: Localized;\n};\n\nexport type GridMenuProps = GridMenuInfo & {\n /** Optional unique identifier */\n id?: string;\n\n commandHandler: CommandHandler;\n\n /** Additional css classes to help with unique styling of the grid menu */\n className?: string;\n};\n\nfunction MenuColumn({\n commandHandler,\n menuDefinition,\n id,\n metadata,\n onClick,\n className,\n}: MenuColumnProps) {\n return (\n \n

    \n {metadata.label}\n

    \n {/* It would seem as though this List component were unnecessary, since it only contains one\n thing, but the \"dense\" property does affect the layout of the items (in a way I don't fully\n understand). There might be a better way. */}\n \n \n \n \n );\n}\n\nexport default function GridMenu({\n commandHandler,\n className,\n multiColumnMenu,\n id,\n}: GridMenuProps) {\n const { columns } = multiColumnMenu;\n\n const sortedColumns = useMemo(() => {\n const columnNumbers = new Map();\n Object.getOwnPropertyNames(columns).forEach((columnName: string) => {\n // We know for sure there is a (boolean) property 'isExtensible' that we are not interested in.\n if (columnName === 'isExtensible') return;\n // TS doesn't allow `columnName` above to be a ReferencedItem even though the type says it is\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const columnId = columnName as ReferencedItem;\n const column = columns[columnId];\n // As of right now (and hopefully forever after), all remaining properties of the\n // ColumnsWithHeaders object are columns whose property names are the IDs of the columns.\n // This is an additional (redundant) sanity check. Specifically we're interested in\n // MenuColumnWithHeader objects, which TypeScript now \"knows\" we have, but at runtime all we\n // can check for is that it's an object with a valid numeric order field. That's likely good\n // enough.\n if (\n typeof column === 'object' &&\n typeof column.order === 'number' &&\n !Number.isNaN(column.order)\n )\n columnNumbers.set(column.order, { id: columnId, metadata: column });\n else\n console.warn(\n `Property ${columnName} (${typeof column}) on menu ${id} is not a valid column and is being ignored. This might indicate data corruption`,\n );\n });\n\n // Extract values and sort them based on the 'order' property\n return Array.from(columnNumbers.values()).sort((a, b) => {\n return (a.metadata.order || 0) - (b.metadata.order || 0);\n });\n }, [columns, id]);\n\n // We might need something like this if we need to be able to prevent empty columns\n // sortedColumns.filter((c) => multiColumnMenu.groups.some((g) => 'column' in g && (g as .column)...\n\n return (\n \n {sortedColumns.map((col, index) => (\n \n ))}\n \n );\n}\n","import { useEffect, useRef, useState } from 'react';\n\nexport type UsePromiseOptions = {\n /**\n * Whether to leave the value as the most recent resolved promise value or set it back to\n * defaultValue while running the promise again. Defaults to true\n */\n preserveValue?: boolean;\n};\n\n/** Set up defaults for options for usePromise hook */\nfunction getUsePromiseOptionsDefaults(options: UsePromiseOptions): UsePromiseOptions {\n return {\n preserveValue: true,\n ...options,\n };\n}\n\n/**\n * Awaits a promise and returns a loading value while the promise is unresolved\n *\n * @param promiseFactoryCallback A function that returns the promise to await. If this callback is\n * undefined, the current value will be returned (defaultValue unless it was previously changed\n * and `options.preserveValue` is true), and there will be no loading.\n *\n * WARNING: MUST BE STABLE - const or wrapped in useCallback. The reference must not be updated\n * every render\n * @param defaultValue The initial value to return while first awaiting the promise. If\n * `options.preserveValue` is false, this value is also shown while awaiting the promise on\n * subsequent calls.\n *\n * Note: this parameter is internally assigned to a `ref`, so changing it will not cause any hooks\n * to re-run with its new value. This means that, if the `promiseFactoryCallback` changes and\n * `options.preserveValue` is `false`, the returned value will be set to the current\n * `defaultValue`. However, the returned value will not be updated if`defaultValue` changes.\n * @param options Various options for adjusting how this hook runs the `promiseFactoryCallback`\n *\n * Note: this parameter is internally assigned to a `ref`, so changing it will not cause any hooks\n * to re-run with its new value. However, the latest `options.preserveValue` will always be used\n * appropriately to determine whether to preserve the returned value when changing the\n * `promiseFactoryCallback`\n * @returns `[value, isLoading]`\n *\n * - `value`: the current value for the promise, either the defaultValue or the resolved promise value\n * - `isLoading`: whether the promise is waiting to be resolved\n */\nconst usePromise = (\n promiseFactoryCallback: (() => Promise) | undefined,\n defaultValue: T,\n options: UsePromiseOptions = {},\n): [value: T, isLoading: boolean] => {\n // Use defaultValue as a ref so it doesn't update dependency arrays\n const defaultValueRef = useRef(defaultValue);\n defaultValueRef.current = defaultValue;\n // Use options as a ref so it doesn't update dependency arrays\n const optionsDefaultedRef = useRef(options);\n optionsDefaultedRef.current = getUsePromiseOptionsDefaults(optionsDefaultedRef.current);\n\n const [value, setValue] = useState(() => defaultValueRef.current);\n const [isLoading, setIsLoading] = useState(true);\n useEffect(() => {\n let promiseIsCurrent = true;\n // If a promiseFactoryCallback was provided, we are loading. Otherwise, there is no loading to do\n setIsLoading(!!promiseFactoryCallback);\n (async () => {\n // If there is a callback to run, run it\n if (promiseFactoryCallback) {\n const result = await promiseFactoryCallback();\n // If the promise was not already replaced, update the value\n if (promiseIsCurrent) {\n setValue(() => result);\n setIsLoading(false);\n }\n }\n })();\n\n return () => {\n // Mark this promise as old and not to be used\n promiseIsCurrent = false;\n if (!optionsDefaultedRef.current.preserveValue) setValue(() => defaultValueRef.current);\n };\n }, [promiseFactoryCallback]);\n\n return [value, isLoading];\n};\nexport default usePromise;\n","\"use client\";\n\nimport createSvgIcon from './utils/createSvgIcon';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nexport default createSvgIcon( /*#__PURE__*/_jsx(\"path\", {\n d: \"M3 18h18v-2H3zm0-5h18v-2H3zm0-7v2h18V6z\"\n}), 'Menu');","import GridMenu from '@/components/mui/grid-menu.component';\nimport { Command, CommandHandler } from '@/components/mui/menu-item.component';\nimport usePromise from '@/hooks/use-promise.hook';\nimport { Menu as MenuIcon } from '@mui/icons-material';\nimport { Drawer, IconButton } from '@mui/material';\nimport { Localized, MultiColumnMenu } from 'platform-bible-utils';\nimport {\n MouseEvent,\n MutableRefObject,\n PropsWithChildren,\n useCallback,\n useEffect,\n useState,\n} from 'react';\n\nexport interface MultiColumnMenuProvider {\n (isSupportAndDevelopment: boolean): Promise>;\n}\n\nexport type HamburgerMenuButtonProps = PropsWithChildren & {\n /** The handler to use for menu commands (and eventually toolbar commands). */\n commandHandler: CommandHandler;\n\n /**\n * Optional reference to the \"div\" container that determines the where the menu should appear. If\n * not defined, then (1,1) used.\n */\n containerRef?: MutableRefObject;\n\n /**\n * The delegate to use to get the menu data. If not specified or if it returns undefined, the data\n * in normalMenu or fullMenu property will be used.\n */\n menuProvider?: MultiColumnMenuProvider;\n\n /**\n * The menu data to show when the menu is opened if the menuProvider property is not defined.\n * (This allows for a default or test-only static menu to be used.)\n */\n normalMenu?: Localized;\n\n /**\n * The menu data to show for \"full\" menu (when opened with the SHIFT key pressed) if the\n * menuProvider property is not defined. (This allows for a default or test-only static menu to be\n * used.)\n */\n fullMenu?: Localized;\n\n /** Additional css class(es) to help with unique styling of the sub-components */\n className?: string;\n\n /** Value to use as prefix for ARIA labels on interactive sub-components */\n ariaLabelPrefix?: string;\n};\n\nexport default function HamburgerMenuButton({\n menuProvider,\n normalMenu,\n fullMenu,\n commandHandler,\n containerRef,\n className,\n ariaLabelPrefix,\n children,\n}: HamburgerMenuButtonProps) {\n const [isMenuOpen, setMenuOpen] = useState(false);\n const [showFullMenu, setShowFullMenu] = useState(false);\n\n const handleMenuItemClick = useCallback(() => {\n if (isMenuOpen) setMenuOpen(false);\n setShowFullMenu(false);\n }, [isMenuOpen]);\n\n const handleMenuButtonClick = useCallback((e: MouseEvent) => {\n e.stopPropagation();\n setMenuOpen((prevIsOpen) => {\n const isOpening = !prevIsOpen;\n if (isOpening && e.shiftKey) setShowFullMenu(true);\n else if (!isOpening) setShowFullMenu(false);\n return isOpening;\n });\n }, []);\n\n const menuCommandHandler = useCallback(\n (command: Command) => {\n handleMenuItemClick();\n return commandHandler(command);\n },\n [commandHandler, handleMenuItemClick],\n );\n\n const [offset, setOffset] = useState({ top: 1, left: 1 });\n\n useEffect(() => {\n if (isMenuOpen) {\n const node = containerRef?.current;\n if (node) {\n const rect = node.getBoundingClientRect();\n const scrollTop = window.scrollY;\n const scrollLeft = window.scrollX;\n const top = rect.top + scrollTop + node.clientHeight;\n const left = rect.left + scrollLeft;\n setOffset({ top, left });\n }\n }\n }, [isMenuOpen, containerRef]);\n\n const [normalMenuData] = usePromise(\n useCallback(async () => {\n return menuProvider?.(false) ?? normalMenu;\n // isMenuOpen needs to be included for the menu contents to reevaluate when reopened\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [menuProvider, normalMenu, isMenuOpen]),\n normalMenu,\n );\n\n const [fullMenuData] = usePromise(\n useCallback(async () => {\n return menuProvider?.(true) ?? fullMenu ?? normalMenuData;\n // isMenuOpen needs to be included for the menu contents to reevaluate when reopened\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [menuProvider, fullMenu, normalMenuData, isMenuOpen]),\n fullMenu ?? normalMenuData,\n );\n\n const menu = showFullMenu && fullMenuData ? fullMenuData : normalMenuData;\n\n return (\n <>\n \n {children ?? }\n \n \n {menu ? (\n \n ) : undefined}\n \n \n );\n}\n","import '@/components/mui/icon-button.component.css';\nimport { IconButton as MuiIconButton } from '@mui/material';\nimport { MouseEventHandler, PropsWithChildren } from 'react';\n\nexport type IconButtonProps = PropsWithChildren<{\n /** Optional unique identifier */\n id?: string;\n /**\n * Required. Used as both the tooltip (aka, title) and the aria-label (used for accessibility,\n * testing, etc.), unless a distinct tooltip is supplied.\n */\n label: string;\n /**\n * Enabled status of button\n *\n * @default false\n */\n isDisabled?: boolean;\n /** Optional tooltip to display if different from the aria-label. */\n tooltip?: string;\n /** If true, no tooltip will be displayed. */\n isTooltipSuppressed?: boolean;\n /**\n * If given, uses a negative margin to counteract the padding on one side (this is often helpful\n * for aligning the left or right side of the icon with content above or below, without ruining\n * the border size and shape).\n *\n * @default false\n */\n adjustMarginToAlignToEdge?: 'end' | 'start' | false;\n /**\n * The size of the component. small is equivalent to the dense button styling.\n *\n * @default false\n */\n size: 'small' | 'medium' | 'large';\n /** Additional css classes to help with unique styling of the button */\n className?: string;\n /** Optional click handler */\n onClick?: MouseEventHandler;\n}>;\n\n/**\n * Iconic button a user can click to do something\n *\n * Thanks to MUI for heavy inspiration and documentation\n * https://mui.com/material-ui/getting-started/overview/\n */\nfunction IconButton({\n id,\n label,\n isDisabled = false,\n tooltip,\n isTooltipSuppressed = false,\n adjustMarginToAlignToEdge = false,\n size = 'medium',\n className,\n onClick,\n children,\n}: IconButtonProps) {\n return (\n \n {children /* the icon to display */}\n \n );\n}\n\nexport default IconButton;\n","import { cn } from '@/utils/shadcn-ui.util';\nimport { LoaderCircle, LucideProps } from 'lucide-react';\nimport { forwardRef } from 'react';\n\nexport type SpinnerProps = LucideProps;\n\nconst Spinner = forwardRef(({ className, ...props }, ref) => {\n return (\n \n );\n});\n\nSpinner.displayName = 'Spinner';\n\nexport default Spinner;\n","import { Input as ShadInput } from '@/components/shadcn-ui/input';\nimport { Label as ShadLabel } from '@/components/shadcn-ui/label';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { ChangeEventHandler, FocusEventHandler } from 'react';\n\nexport type TextFieldProps = {\n /** Optional unique identifier */\n id?: string;\n /**\n * If `true`, the component is disabled.\n *\n * @default false\n */\n isDisabled?: boolean;\n /**\n * If `true`, the label is displayed in an error state.\n *\n * @default false\n */\n hasError?: boolean;\n /**\n * If `true`, the input will take up the full width of its container.\n *\n * @default false\n */\n isFullWidth?: boolean;\n /** Text that gives the user instructions on what contents the TextField expects */\n helperText?: string;\n /** The title of the TextField */\n label?: string;\n /** The short hint displayed in the `input` before the user enters a value. */\n placeholder?: string;\n /**\n * If `true`, the label is displayed as required and the `input` element is required.\n *\n * @default false\n */\n isRequired?: boolean;\n /** Additional css classes to help with unique styling of the text field */\n className?: string;\n /** Starting value for the text field if it is not controlled */\n defaultValue?: string | number;\n /** Value of the text field if controlled */\n value?: string | number;\n /** Triggers when content of textfield is changed */\n onChange?: ChangeEventHandler;\n /** Triggers when textfield gets focus */\n onFocus?: FocusEventHandler;\n /** Triggers when textfield loses focus */\n onBlur?: FocusEventHandler;\n};\n\n/**\n * Text input field\n *\n * Thanks to Shadcn for heavy inspiration and documentation\n * https://ui.shadcn.com/docs/components/input#with-label\n */\nfunction TextField({\n id,\n isDisabled = false,\n hasError = false,\n isFullWidth = false,\n helperText,\n label,\n placeholder,\n isRequired = false,\n className,\n defaultValue,\n value,\n onChange,\n onFocus,\n onBlur,\n}: TextFieldProps) {\n return (\n
    \n {`${label}${isRequired ? '*' : ''}`}\n \n

    {helperText}

    \n
    \n );\n}\n\nexport default TextField;\n","import HamburgerMenuButton, {\n MultiColumnMenuProvider,\n} from '@/components/mui/hamburger-menu-button.component';\nimport { CommandHandler } from '@/components/mui/menu-item.component';\nimport '@/components/mui/toolbar.component.css';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { AppBar, Toolbar as MuiToolbar } from '@mui/material';\nimport { PropsWithChildren, useRef } from 'react';\n\nexport type ToolbarProps = PropsWithChildren<{\n /** The handler to use for menu commands (and eventually toolbar commands). */\n commandHandler: CommandHandler;\n\n /**\n * The optional delegate to use to get the menu data. If not specified, the \"hamburger\" menu will\n * not display.\n */\n menuProvider?: MultiColumnMenuProvider;\n\n /** Optional unique identifier */\n id?: string;\n\n /** Additional css classes to help with unique styling of the toolbar */\n className?: string;\n}>;\n\nexport default function Toolbar({\n menuProvider,\n commandHandler,\n className,\n id,\n children,\n}: ToolbarProps) {\n // This ref will always be defined\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const containerRef = useRef(undefined!);\n\n return (\n
    \n \n \n {menuProvider ? (\n \n ) : undefined}\n {children ?
    {children}
    : undefined}\n \n
    \n
    \n );\n}\n","import React from 'react';\nimport { cva, type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst alertVariants = cva(\n 'tw-relative tw-w-full tw-rounded-lg tw-border tw-p-4 [&>svg~*]:tw-pl-7 [&>svg+div]:tw-translate-y-[-3px] [&>svg]:tw-absolute [&>svg]:tw-left-4 [&>svg]:tw-top-4 [&>svg]:tw-text-foreground',\n {\n variants: {\n variant: {\n default: 'tw-bg-background tw-text-foreground',\n destructive:\n 'tw-border-destructive/50 tw-text-destructive dark:tw-border-destructive [&>svg]:tw-text-destructive',\n },\n },\n defaultVariants: {\n variant: 'default',\n },\n },\n);\n\nconst Alert = React.forwardRef<\n HTMLDivElement,\n React.HTMLAttributes & VariantProps\n>(({ className, variant, ...props }, ref) => (\n
    \n));\nAlert.displayName = 'Alert';\n\nconst AlertTitle = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n {/* added because of https://github.com/jsx-eslint/eslint-plugin-jsx-a11y/blob/main/docs/rules/heading-has-content.md */}\n {props.children}{' '}\n \n ),\n);\nAlertTitle.displayName = 'AlertTitle';\n\nconst AlertDescription = React.forwardRef<\n HTMLParagraphElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n
    \n));\nAlertDescription.displayName = 'AlertDescription';\n\nexport { Alert, AlertTitle, AlertDescription };\n","import React from 'react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Card = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nCard.displayName = 'Card';\n\nconst CardHeader = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nCardHeader.displayName = 'CardHeader';\n\nconst CardTitle = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n {/* added because of https://github.com/jsx-eslint/eslint-plugin-jsx-a11y/blob/main/docs/rules/heading-has-content.md */}\n {props.children}\n \n ),\n);\nCardTitle.displayName = 'CardTitle';\n\nconst CardDescription = React.forwardRef<\n HTMLParagraphElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n

    \n));\nCardDescription.displayName = 'CardDescription';\n\nconst CardContent = React.forwardRef>(\n ({ className, ...props }, ref) => (\n

    \n ),\n);\nCardContent.displayName = 'CardContent';\n\nconst CardFooter = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nCardFooter.displayName = 'CardFooter';\n\nexport { Card, CardHeader, CardFooter, CardTitle, CardDescription, CardContent };\n","import { ComponentProps } from 'react';\nimport { toast as sonner, Toaster } from 'sonner';\n\ntype SonnerProps = ComponentProps;\n\nfunction Sonner({ ...props }: SonnerProps) {\n return (\n \n );\n}\n\n// The re-export of the sonner function was added manually\nexport { Sonner, sonner };\n","import React from 'react';\nimport * as SliderPrimitive from '@radix-ui/react-slider';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Slider = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n \n \n \n));\nSlider.displayName = SliderPrimitive.Root.displayName;\n\nexport { Slider };\n","import React from 'react';\nimport * as SwitchPrimitives from '@radix-ui/react-switch';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Switch = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n));\nSwitch.displayName = SwitchPrimitives.Root.displayName;\n\nexport { Switch };\n","import React from 'react';\nimport * as TabsPrimitive from '@radix-ui/react-tabs';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport const Tabs = TabsPrimitive.Root;\n\nexport type TabsListProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport type TabsTriggerProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport type TabsContentProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport const TabsList = React.forwardRef<\n React.ElementRef,\n TabsListProps\n>(({ className, ...props }, ref) => (\n \n));\nTabsList.displayName = TabsPrimitive.List.displayName;\n\nexport const TabsTrigger = React.forwardRef<\n React.ElementRef,\n TabsTriggerProps\n>(({ className, ...props }, ref) => (\n \n));\nTabsTrigger.displayName = TabsPrimitive.Trigger.displayName;\n\nexport const TabsContent = React.forwardRef<\n React.ElementRef,\n TabsContentProps\n>(({ className, ...props }, ref) => (\n \n));\nTabsContent.displayName = TabsPrimitive.Content.displayName;\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Download } from 'lucide-react';\n\ntype InstallButtonProps = {\n /** The installing boolean value determines the state of the button. */\n isInstalling: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n /** Optional text for the button. */\n buttonText?: string;\n} & ButtonProps;\n\n/**\n * The InstallButton component is a button designed for initiating installs. It includes visuals for\n * active installing and idle states.\n *\n * @param isInstalling The installing boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @param buttonText Optional text for the button.\n * @returns A install button.\n */\nexport default function InstallButton({\n isInstalling,\n handleClick,\n buttonText,\n className,\n ...props\n}: InstallButtonProps) {\n return (\n \n {isInstalling ? (\n \n ) : (\n <>\n \n {buttonText}\n \n )}\n \n );\n}\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\n\ntype EnableButtonProps = {\n /** The enabling boolean value determines the state of the button. */\n isEnabling: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n} & ButtonProps;\n\n/**\n * The EnableButton component is a button designed for initiating enabling of downloads. It includes\n * visuals for active enabling and idle states.\n *\n * @param isEnabling The enabling boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @returns A button that can be used to enable.\n */\nexport default function EnableButton({\n isEnabling,\n handleClick,\n className,\n ...props\n}: EnableButtonProps) {\n return (\n \n {isEnabling ? (\n <>\n \n Enabling...\n \n ) : (\n 'Enable'\n )}\n \n );\n}\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\n\ntype DisableButtonProps = {\n /** The disabling boolean value determines the state of the button. */\n isDisabling: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n} & ButtonProps;\n\n/**\n * The DisableButton component is a button designed for initiating disabling of downloads. It\n * includes visuals for active disabling and idle states.\n *\n * @param isDisabling The disabling boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @returns A button that can be used to disable.\n */\nexport default function DisableButton({\n isDisabling,\n handleClick,\n className,\n ...props\n}: DisableButtonProps) {\n return (\n \n {isDisabling ? (\n <>\n \n Disabling...\n \n ) : (\n 'Disable'\n )}\n \n );\n}\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\n\ntype UpdateButtonProps = {\n /** The updating boolean value determines the state of the button. */\n isUpdating: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n} & ButtonProps;\n\n/**\n * The UpdateButton component is a button designed for initiating updates for downloaded extensions.\n * It includes visuals for active updating and idle states.\n *\n * @param isUpdating The updating boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @returns A button that can be used to update.\n */\nexport default function UpdateButton({\n isUpdating,\n handleClick,\n className,\n ...props\n}: UpdateButtonProps) {\n return (\n \n {isUpdating ? (\n <>\n \n Updating...\n \n ) : (\n 'Update'\n )}\n \n );\n}\n","import { cn } from '@/utils/shadcn-ui.util';\nimport Markdown, { MarkdownToJSX } from 'markdown-to-jsx';\nimport { useMemo } from 'react';\n\ninterface MarkdownRendererProps {\n /** Optional unique identifier */\n id?: string;\n /** The markdown string to render */\n markdown: string;\n className?: string;\n /**\n * The [`target` attribute for `a` html\n * tags](https://developer.mozilla.org/en-US/docs/Web/HTML/Element/a#target). Defaults to not\n * adding a `target` to `a` tags\n */\n anchorTarget?: string;\n}\n\n/**\n * This component renders markdown content given a markdown string. It uses typography styles from\n * the platform.\n *\n * @param markdown The markdown string to render.\n * @param id Optional unique identifier\n * @returns A div containing the rendered markdown content.\n */\nexport default function MarkdownRenderer({\n id,\n markdown,\n className,\n anchorTarget,\n}: MarkdownRendererProps) {\n const options: MarkdownToJSX.Options = useMemo(\n () => ({\n overrides: {\n a: {\n props: {\n target: anchorTarget,\n },\n },\n },\n }),\n [anchorTarget],\n );\n return (\n
    \n {markdown}\n
    \n );\n}\n","import { Filter, ChevronDown } from 'lucide-react';\nimport { forwardRef } from 'react';\nimport { Button } from '@/components/shadcn-ui/button';\n\n/**\n * The FilterButton component is a button designed for initiating filtering of data. It is designed\n * to be used with the dropdown menu. It uses forwardRef to pass the button to the dropdown trigger\n * asChild.\n *\n * @returns A button that can be used to filter.\n */\nconst FilterButton = forwardRef((props, ref) => {\n return (\n \n \n Filter\n \n \n );\n});\n\nexport default FilterButton;\n","import {\n DropdownMenu,\n DropdownMenuTrigger,\n DropdownMenuContent,\n DropdownMenuLabel,\n DropdownMenuGroup,\n DropdownMenuCheckboxItem,\n DropdownMenuRadioItem,\n DropdownMenuSeparator,\n} from '@/components/shadcn-ui/dropdown-menu';\nimport FilterButton from './buttons/filter-button.component';\n\nexport enum DropdownMenuItemType {\n Check,\n Radio,\n}\n\nexport type DropdownItem = {\n /** The label is the text that will be displayed on the dropdown item. */\n label: string;\n /** The itemType determines the DropdownMenuItemType type as either Check or Radio. */\n itemType: DropdownMenuItemType;\n /** The onClick function is called when the item is clicked. */\n onClick: () => void;\n};\n\nexport type DropdownGroup = {\n /**\n * The label is the text that will be displayed on the dropdown group. It is used to categorize\n * the items in the group.\n */\n label: string;\n /** The items array contains the items that will be displayed in the dropdown group */\n items: DropdownItem[];\n};\n\nexport type FilterDropdownProps = {\n /** Object unique identifier */\n id?: string;\n /** The groups array contains the groups that will be displayed in the dropdown */\n groups: DropdownGroup[];\n}; // TODO: extend the props later\n\n/**\n * The FilterDropdown component is a dropdown designed for filtering content. It includes groups of\n * items that can be checkboxes or radio items.\n *\n * @param id Optional unique identifier\n * @param groups The groups array contains the groups that will be displayed in the dropdown\n * @returns A filter dropdown.\n */\nexport default function FilterDropdown({ id, groups }: FilterDropdownProps) {\n return (\n
    \n {/* TODO: remove this once the DropDown Menu shadcn has an id prop */}\n \n \n \n \n \n {groups.map((group) => (\n
    \n {group.label}\n \n {group.items.map((item) => (\n
    \n {item.itemType === DropdownMenuItemType.Check ? (\n \n {item.label}\n \n ) : (\n \n {item.label}\n \n )}\n
    \n ))}\n
    \n \n
    \n ))}\n
    \n
    \n
    \n );\n}\n","interface NoExtensionsFoundProps {\n /** Optional unique identifier */\n id?: string;\n /** The message to display */\n message: string;\n}\n/**\n * This component displays a message to the user when no extensions are found in the marketplace.\n *\n * @param id Optional unique identifier\n * @param message The message to display.\n * @returns {JSX.Element} - Returns the message component that displays the message to the user.\n */\nexport default function NoExtensionsFound({ id, message }: NoExtensionsFoundProps) {\n return (\n
    \n
    \n

    {message}

    \n
    \n
    \n );\n}\n","import { CircleHelp, Link as LucideLink, User } from 'lucide-react';\nimport { NumberFormat } from 'platform-bible-utils';\n\n/** Interface that stores the parameters passed to the More Info component */\ninterface MoreInfoProps {\n /** Optional unique identifier */\n id?: string;\n /** The category of the extension */\n category: string;\n /** The number of downloads for the extension */\n downloads: Record;\n /** The languages supported by the extension */\n languages: string[];\n /** The URL to the more info page of the extension */\n moreInfoUrl: string;\n}\n/**\n * This component displays the more info section of the extension which includes the category,\n * number of downloads, languages, and links to the website and support\n *\n * @param id Optional unique identifier\n * @param category The category of the extension\n * @param downloads The number of downloads for the extension\n * @param languages The languages supported by the extension\n * @param moreInfoUrl The URL to the more info page of the extension\n * @returns {JSX.Element} - Returns the more info component that displays the category, number of\n * downloads, languages, and links to the website and support\n */\nexport default function MoreInfo({\n id,\n category,\n downloads,\n languages,\n moreInfoUrl,\n}: MoreInfoProps) {\n /**\n * This constant formats the number of downloads into a more readable format.\n *\n * @example 1000 -> 1K\n *\n * @example 1000000 -> 1M\n *\n * @returns The formatted number of downloads\n */\n const numberFormatted = new NumberFormat('en', {\n notation: 'compact',\n compactDisplay: 'short',\n }).format(Object.values(downloads).reduce((a: number, b: number) => a + b, 0));\n\n /** This function scrolls the window to the bottom of the page. */\n const handleScrollToBottom = () => {\n window.scrollTo(0, document.body.scrollHeight);\n };\n\n return (\n \n
    \n
    \n {category}\n
    \n CATEGORY\n
    \n
    \n
    \n
    \n \n {numberFormatted}\n
    \n USERS\n
    \n
    \n
    \n
    \n {languages.slice(0, 3).map((locale) => (\n \n {locale.toUpperCase()}\n \n ))}\n
    \n {languages.length > 3 && (\n handleScrollToBottom()}\n className=\"tw-text-xs tw-text-gray-500 tw-underline\"\n >\n +{languages.length - 3} more languages\n \n )}\n
    \n
    \n
    \n \n Website\n \n \n \n Support\n \n \n
    \n
    \n );\n}\n","import { useState } from 'react';\n\nexport type VersionInformation = {\n /** Date the version was published */\n date: string;\n /** Description of the changes in the version */\n description: string;\n};\n\n/** Type to store the version history information */\nexport type VersionHistoryType = Record;\n\n/** Interface that stores the parameters passed to the Version History component */\ninterface VersionHistoryProps {\n /** Optional unique identifier */\n id?: string;\n /** Object containing the versions mapped with their information */\n versionHistory: VersionHistoryType;\n}\n\n/**\n * Component to render the version history information shown in the footer component. Lists the 5\n * most recent versions, with the options to show all versions by pressing a button.\n *\n * @param versionHistory Object containing the versions mapped with their information\n * @param id Optional unique identifier\n * @returns Rendered version history for the Footer component\n */\nexport default function VersionHistory({ id, versionHistory }: VersionHistoryProps) {\n const [showAllVersions, setShowAllVersions] = useState(false);\n const currentDate = new Date();\n\n /**\n * Function to format the time string for the version history in the form of 'X year(s) ago'.\n *\n * @param dateString ISO Date string to determine the time string from\n * @returns Formatted time string\n */\n function formatTimeString(dateString: string) {\n const date = new Date(dateString);\n const dateDiff = new Date(currentDate.getTime() - date.getTime());\n const yearDiff = dateDiff.getUTCFullYear() - 1970;\n const monthDiff = dateDiff.getUTCMonth();\n const dayDiff = dateDiff.getUTCDate() - 1;\n\n // Determines how long ago the version was published\n let timeString = '';\n if (yearDiff > 0) {\n timeString = `${yearDiff.toString()} year${yearDiff === 1 ? '' : 's'} ago`;\n } else if (monthDiff > 0) {\n timeString = `${monthDiff.toString()} month${monthDiff === 1 ? '' : 's'} ago`;\n } else if (dayDiff === 0) {\n timeString = 'today';\n } else {\n timeString = `${dayDiff.toString()} day${dayDiff === 1 ? '' : 's'} ago`;\n }\n\n return timeString;\n }\n\n // Sorts the version history by version number\n const sortedEntries = Object.entries(versionHistory).sort((a, b) => b[0].localeCompare(a[0]));\n\n return (\n
    \n

    What`s New

    \n
      \n {(showAllVersions ? sortedEntries : sortedEntries.slice(0, 5)).map((entry) => (\n
      \n
      \n
    • \n {entry[1].description}\n
    • \n
      \n
      \n
      Version {entry[0]}
      \n
      {formatTimeString(entry[1].date)}
      \n
      \n
      \n ))}\n
    \n {sortedEntries.length > 5 && (\n setShowAllVersions(!showAllVersions)}\n className=\"tw-text-xs tw-text-gray-500 tw-underline\"\n >\n {showAllVersions ? 'Show Less Version History' : 'Show All Version History'}\n \n )}\n
    \n );\n}\n","import { useMemo } from 'react';\nimport { formatBytes } from 'platform-bible-utils';\nimport VersionHistory, { VersionHistoryType } from './version-history.component';\n\n/** Interface to store the parameters passed to the Footer component */\ninterface FooterProps {\n /** Optional unique identifier */\n id?: string;\n /** Name of the publisher */\n publisherDisplayName: string;\n /** Size of the extension file in bytes */\n fileSize: number;\n /** List of language codes supported by the extension */\n locales: string[];\n /** Object containing the version history mapped with their information */\n versionHistory: VersionHistoryType;\n}\n\n/**\n * Component to render the footer for the extension details which contains information on the\n * publisher, version history, languages, and file size.\n *\n * @param id Optional unique identifier\n * @param publisherDisplayName Name of the publisher\n * @param fileSize Size of the extension file in bytes\n * @param locales List of language codes supported by the extension\n * @param versionHistory Object containing the version history mapped with their information\n * @returns The rendered Footer component\n */\nexport default function Footer({\n id,\n publisherDisplayName,\n fileSize,\n locales,\n versionHistory,\n}: FooterProps) {\n /** Formats the file size into a human-readable format */\n const formattedFileSize = useMemo(() => formatBytes(fileSize), [fileSize]);\n\n /**\n * This function gets the display names of the languages based on the language codes.\n *\n * @param codes The list of language codes\n * @returns The list of language names\n */\n const getLanguageNames = (codes: string[]) => {\n const displayNames = new Intl.DisplayNames(navigator.language, { type: 'language' });\n return codes.map((code) => displayNames.of(code));\n };\n\n const languageNames = getLanguageNames(locales);\n\n return (\n
    \n
    \n \n
    \n
    \n

    Information

    \n
    \n

    \n Publisher\n {publisherDisplayName}\n Size\n {formattedFileSize}\n

    \n
    \n

    \n Languages\n {languageNames.join(', ')}\n

    \n
    \n
    \n
    \n
    \n
    \n );\n}\n","import { PlatformEvent, PlatformEventHandler } from 'platform-bible-utils';\nimport { useEffect } from 'react';\n\n/**\n * Adds an event handler to an event so the event handler runs when the event is emitted. Use\n * `papi.network.getNetworkEvent` to use a networked event with this hook.\n *\n * @param event The event to subscribe to.\n *\n * - If event is a `PlatformEvent`, that event will be used\n * - If event is undefined, the callback will not be subscribed. Useful if the event is not yet\n * available for example\n *\n * @param eventHandler The callback to run when the event is emitted\n *\n * WARNING: MUST BE STABLE - const or wrapped in useCallback. The reference must not be updated\n * every render\n */\nconst useEvent = (\n event: PlatformEvent | undefined,\n eventHandler: PlatformEventHandler,\n) => {\n useEffect(() => {\n // Do nothing if the event is not provided (in case the event is not yet available, for example)\n if (!event) return () => {};\n\n const unsubscriber = event(eventHandler);\n return () => {\n unsubscriber();\n };\n }, [event, eventHandler]);\n};\nexport default useEvent;\n","import { useCallback, useEffect } from 'react';\nimport { PlatformEvent, PlatformEventAsync, PlatformEventHandler } from 'platform-bible-utils';\nimport usePromise from './use-promise.hook';\n\nconst noopUnsubscriber = () => false;\n\n/**\n * Adds an event handler to an asynchronously subscribing/unsubscribing event so the event handler\n * runs when the event is emitted. Use `papi.network.getNetworkEvent` to use a networked event with\n * this hook.\n *\n * @param event The asynchronously (un)subscribing event to subscribe to.\n *\n * - If event is a `PlatformEvent` or `PlatformEventAsync`, that event will be used\n * - If event is undefined, the callback will not be subscribed. Useful if the event is not yet\n * available for example\n *\n * @param eventHandler The callback to run when the event is emitted\n *\n * WARNING: MUST BE STABLE - const or wrapped in useCallback. The reference must not be updated\n * every render\n */\nconst useEventAsync = (\n event: PlatformEvent | PlatformEventAsync | undefined,\n eventHandler: PlatformEventHandler,\n) => {\n // Subscribe to the event asynchronously\n const [unsubscribe] = usePromise(\n useCallback(async () => {\n // Do nothing if the event is not provided (in case the event is not yet available, for example)\n if (!event) return noopUnsubscriber;\n\n // Wrap subscribe and unsubscribe in promises to allow normal events to be used as well\n const unsub = await Promise.resolve(event(eventHandler));\n return async () => unsub();\n }, [eventHandler, event]),\n noopUnsubscriber,\n // We want the unsubscriber to return to default value immediately upon changing subscription\n // So the useEffect below will unsubscribe asap\n { preserveValue: false },\n );\n\n // Unsubscribe from the event asynchronously (but we aren't awaiting the unsub)\n useEffect(() => {\n return () => {\n if (unsubscribe !== noopUnsubscriber) {\n unsubscribe();\n }\n };\n }, [unsubscribe]);\n};\n\nexport default useEventAsync;\n"],"names":["twMergeCustom","extendTailwindMerge","cn","inputs","clsx","Input","React","className","type","props","ref","jsx","BookChapterInput","forwardRef","handleSearch","handleKeyDown","handleOnClick","handleSubmit","jsxs","ShadInput","event","e","History","P","R","t","s","n","N","B","O","S","K","g","k","x","T","X","V","w","L","G","A","H","C","I","y","q","U","m","l","h","c","E","D","i","a","o","u","v","f","d","b","p","J","DropdownMenu","DropdownMenuPrimitive","DropdownMenuTrigger","DropdownMenuGroup","DropdownMenuPortal","DropdownMenuSub","DropdownMenuRadioGroup","DropdownMenuSubTrigger","inset","children","ChevronRight","DropdownMenuSubContent","DropdownMenuContent","sideOffset","DropdownMenuItem","DropdownMenuCheckboxItem","checked","Check","DropdownMenuRadioItem","Circle","DropdownMenuLabel","DropdownMenuSeparator","DropdownMenuShortcut","BookMenuItem","bookId","handleSelectBook","isSelected","handleHighlightBook","bookType","ShadDropdownMenuItem","Canon","ChapterSelect","handleSelectChapter","endChapter","activeChapter","highlightedChapter","handleHighlightedChapter","chapters","_","handleMouse","useCallback","chapterNumber","chapter","GoToMenuItem","handleSort","handleLocationHistory","handleBookmarks","ShadDropdownMenuLabel","ArrowDownWideNarrow","Clock","Bookmark","ALL_BOOK_IDS","BOOK_TYPE_LABELS","BOOK_TYPE_ARRAY","SCROLL_OFFSET","SEARCH_QUERY_FORMATS","fetchGroupedBooks","fetchEndChapter","getChaptersForBook","getAllEnglishNames","isValidBookEnglishName","bookName","getBookIdFromEnglishName","formattedBookName","BookChapterControl","scrRef","searchQuery","setSearchQuery","useState","selectedBookId","setSelectedBookId","setHighlightedChapter","highlightedBookId","setHighlightedBookId","isContentOpen","setIsContentOpen","isContentOpenDelayed","setIsContentOpenDelayed","inputRef","useRef","contentRef","menuItemRef","fetchFilteredBooks","englishNameLowerCase","normalizedQuery","handleSearchInput","searchString","shouldPreventAutoClosing","controlMenuState","open","updateReference","shouldClose","verse","handleInputSubmit","format","matches","book","englishName","handleKeyDownInput","handleKeyDownContent","key","handleKeyDownMenuItem","chapterOffSet","useEffect","useLayoutEffect","scrollTimeout","scrollPosition","ShadDropdownMenu","ShadDropdownMenuTrigger","ShadDropdownMenuContent","bookTypeIndex","element","ShadDropdownMenuSeparator","buttonVariants","cva","Button","variant","size","asChild","Comp","Slot","labelVariants","Label","LabelPrimitive","RadioGroup","RadioGroupPrimitive","RadioGroupItem","Popover","PopoverPrimitive","PopoverTrigger","PopoverContent","align","DialogPortal","DialogPrimitive","DialogOverlay","DialogContent","DialogTitle","DialogDescription","Command","CommandPrimitive","CommandInput","Search","CommandList","CommandEmpty","CommandGroup","CommandSeparator","CommandItem","getOptionLabelDefault","option","ComboBox","id","options","buttonClassName","popoverContentClassName","value","onChange","getOptionLabel","buttonPlaceholder","textPlaceholder","commandEmptyMessage","buttonVariant","dir","isDisabled","setOpen","ChevronsUpDown","ChapterRangeSelector","startChapter","handleSelectStartChapter","handleSelectEndChapter","chapterCount","chapterOptions","useMemo","index","onChangeStartChapter","onChangeEndChapter","Fragment","BookSelectionMode","BOOK_SELECTOR_STRING_KEYS","localizeString","strings","BookSelector","handleBookSelectionModeChange","currentBookName","onSelectBooks","selectedBookIds","localizedStrings","currentBookText","chooseText","chooseBooksText","bookSelectionMode","setBookSelectionMode","onSelectionModeChange","newMode","DataTableViewOptions","table","FilterIcon","column","Select","SelectPrimitive","SelectGroup","SelectValue","SelectTrigger","ChevronDown","SelectScrollUpButton","ChevronUp","SelectScrollDownButton","SelectContent","position","SelectLabel","SelectItem","SelectSeparator","DataTablePagination","pageSize","ArrowLeftIcon","ChevronLeftIcon","ChevronRightIcon","ArrowRightIcon","Table","stickyHeader","TableHeader","TableBody","TableFooter","TableRow","TableHead","TableCell","TableCaption","DataTable","columns","data","enablePagination","showPaginationControls","showColumnVisibilityControls","onRowClickHandler","sorting","setSorting","columnFilters","setColumnFilters","columnVisibility","setColumnVisibility","rowSelection","setRowSelection","useReactTable","getCoreRowModel","getPaginationRowModel","getSortedRowModel","getFilteredRowModel","headerGroup","header","flexRender","_a","row","cell","OccurrencesTable","occurrenceData","setScriptureReference","referenceHeaderText","occurrenceHeaderText","occurrences","uniqueOccurrences","occurrence","uniqueOccurrence","deepEqual","Checkbox","CheckboxPrimitive","getLinesFromUSFM","text","getNumberFromUSFM","regex","match","getBookNumFromId","getStatusForItem","item","approvedItems","unapprovedItems","toggleVariants","Toggle","TogglePrimitive","ToggleGroupContext","ToggleGroup","ToggleGroupPrimitive","ToggleGroupItem","context","getSortingIcon","sortDirection","ArrowUpIcon","ArrowDownIcon","ArrowUpDownIcon","inventoryItemColumn","itemLabel","inventoryAdditionalItemColumn","additionalItemLabel","additionalItemIndex","inventoryCountColumn","countLabel","statusChangeHandler","changedItems","newStatus","onApprovedItemsChange","onUnapprovedItemsChange","newApprovedItems","validItem","newUnapprovedItems","unapprovedItem","inventoryStatusColumn","statusLabel","status","CircleCheckIcon","CircleXIcon","CircleHelpIcon","INVENTORY_STRING_KEYS","filterItemData","itemData","statusFilter","textFilter","filteredItemData","createTableData","scriptureRef","itemRegex","tableData","currentBook","currentChapter","currentVerse","line","items","itemIndex","existingItem","tableEntry","newReference","substring","newItem","Inventory","scriptureReference","extractItems","additionalItemsLabels","scope","onScopeChange","allItemsText","approvedItemsText","unapprovedItemsText","unknownItemsText","scopeBookText","scopeChapterText","scopeVerseText","filterText","showAdditionalItemsText","showAdditionalItems","setShowAdditionalItems","setStatusFilter","setTextFilter","selectedItem","setSelectedItem","reducedTableData","newTableData","firstItem","existingEntry","newTableEntry","filteredTableData","allColumns","numberOfAdditionalItems","additionalColumns","_b","rowClickHandler","newSelection","handleScopeChange","handleStatusFilterChange","SearchBar","onSearch","placeholder","isFullWidth","handleInputChange","VerticalTabs","TabsPrimitive","VerticalTabsList","VerticalTabsTrigger","VerticalTabsContent","TabNavigationContentSearch","tabList","searchPlaceholder","headerTitle","isSearchBarFullWidth","direction","tab","Separator","orientation","decorative","SeparatorPrimitive","Sheet","SheetPrimitive","SheetPortal","SheetOverlay","sheetVariants","SheetContent","side","SheetTitle","SheetDescription","Skeleton","TooltipProvider","TooltipPrimitive","Tooltip","TooltipTrigger","TooltipContent","MOBILE_BREAKPOINT","useIsMobile","isMobile","setIsMobile","mql","SIDEBAR_COOKIE_NAME","SIDEBAR_COOKIE_MAX_AGE","SIDEBAR_WIDTH","SIDEBAR_WIDTH_MOBILE","SIDEBAR_WIDTH_ICON","SIDEBAR_KEYBOARD_SHORTCUT","SidebarContext","useSidebar","SidebarProvider","defaultOpen","openProp","setOpenProp","style","openMobile","setOpenMobile","_open","_setOpen","isOpen","openState","toggleSidebar","state","contextValue","Sidebar","collapsible","SidebarTrigger","onClick","PanelLeft","SidebarRail","SidebarInset","SidebarInput","SidebarHeader","SidebarFooter","SidebarSeparator","SidebarContent","SidebarGroup","SidebarGroupLabel","SidebarGroupAction","SidebarGroupContent","SidebarMenu","SidebarMenuItem","sidebarMenuButtonVariants","SidebarMenuButton","isActive","tooltip","button","SidebarMenuAction","showOnHover","SidebarMenuBadge","SidebarMenuSkeleton","showIcon","width","SidebarMenuSub","SidebarMenuSubItem","SidebarMenuSubButton","SettingsSidebar","extensionLabels","projectOptions","handleSelectSidebarItem","selectedSidebarItem","extensionsSidebarGroupLabel","projectsSidebarGroupLabel","handleSelectItem","projectId","getProjectNameFromProjectId","project","getIsActive","label","selectedProjectName","SettingsSidebarContentSearch","scrBookColId","scrRefColId","typeColId","detailsColId","defaultScrRefColumnName","defaultScrBookGroupName","defaultTypeColumnName","defaultDetailsColumnName","getColumns","colInfo","showSourceColumn","showSrcCol","info","formatScrRef","compareScrRefs","toRefOrRange","scriptureSelection","offsetStart","offsetEnd","scrRefToBBBCCCVVV","getRowKey","ScriptureResultsViewer","sources","showColumnHeaders","scriptureReferenceColumnName","scriptureBookGroupName","typeColumnName","detailsColumnName","onRowSelected","grouping","setGrouping","scriptureResults","source","getExpandedRowModel","getGroupedRowModel","selectedRows","keys","selectedRow","scrBookGroupName","typeGroupName","groupingOptions","handleSelectChange","selectedGrouping","handleRowClick","getEvenOrOddBandingStyle","getIndent","groupingState","rowIndex","ChevronLeft","DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS","getLocalizeKeyForScrollGroupId","ScrollGroupSelector","availableScrollGroupIds","scrollGroupId","onChangeScrollGroupId","localizedStringsDefaulted","localizedStringKey","localizedStringValue","newScrollGroupString","scrollGroupOptionId","SettingsList","SettingsListItem","primary","secondary","isLoading","loadingMessage","SettingsListHeader","includeSeparator","Checklist","listItems","selectedListItems","handleSelectListItem","createLabel","_interopRequireDefault","obj","module","chainPropTypes","propType1","propType2","args","_extends","target","isPlainObject","prototype","deepClone","output","deepmerge","r","z","reactIs_production_min","hasSymbol","REACT_ELEMENT_TYPE","REACT_PORTAL_TYPE","REACT_FRAGMENT_TYPE","REACT_STRICT_MODE_TYPE","REACT_PROFILER_TYPE","REACT_PROVIDER_TYPE","REACT_CONTEXT_TYPE","REACT_ASYNC_MODE_TYPE","REACT_CONCURRENT_MODE_TYPE","REACT_FORWARD_REF_TYPE","REACT_SUSPENSE_TYPE","REACT_SUSPENSE_LIST_TYPE","REACT_MEMO_TYPE","REACT_LAZY_TYPE","REACT_BLOCK_TYPE","REACT_FUNDAMENTAL_TYPE","REACT_RESPONDER_TYPE","REACT_SCOPE_TYPE","isValidElementType","typeOf","object","$$typeof","$$typeofType","AsyncMode","ConcurrentMode","ContextConsumer","ContextProvider","Element","ForwardRef","Lazy","Memo","Portal","Profiler","StrictMode","Suspense","hasWarnedAboutDeprecatedIsAsyncMode","isAsyncMode","isConcurrentMode","isContextConsumer","isContextProvider","isElement","isForwardRef","isFragment","isLazy","isMemo","isPortal","isProfiler","isStrictMode","isSuspense","reactIs_development","reactIsModule","require$$0","require$$1","getOwnPropertySymbols","hasOwnProperty","propIsEnumerable","toObject","val","shouldUseNative","test1","test2","order2","test3","letter","objectAssign","from","to","symbols","ReactPropTypesSecret","ReactPropTypesSecret_1","has","printWarning","loggedTypeFailures","message","checkPropTypes","typeSpecs","values","location","componentName","getStack","typeSpecName","error","err","ex","stack","checkPropTypes_1","ReactIs","assign","require$$2","require$$3","require$$4","emptyFunctionThatReturnsNull","factoryWithTypeCheckers","isValidElement","throwOnDirectAccess","ITERATOR_SYMBOL","FAUX_ITERATOR_SYMBOL","getIteratorFn","maybeIterable","iteratorFn","ANONYMOUS","ReactPropTypes","createPrimitiveTypeChecker","createAnyTypeChecker","createArrayOfTypeChecker","createElementTypeChecker","createElementTypeTypeChecker","createInstanceTypeChecker","createNodeChecker","createObjectOfTypeChecker","createEnumTypeChecker","createUnionTypeChecker","createShapeTypeChecker","createStrictShapeTypeChecker","is","PropTypeError","createChainableTypeChecker","validate","manualPropTypeCallCache","manualPropTypeWarningCount","checkType","isRequired","propName","propFullName","secret","cacheKey","chainedCheckType","expectedType","propValue","propType","getPropType","preciseType","getPreciseType","typeChecker","expectedClass","expectedClassName","actualClassName","getClassName","expectedValues","valuesString","arrayOfTypeCheckers","checker","getPostfixForTypeWarning","expectedTypes","checkerResult","expectedTypesMessage","isNode","invalidValidatorError","shapeTypes","allKeys","iterator","step","entry","isSymbol","emptyFunction","emptyFunctionWithReset","factoryWithThrowingShims","shim","getShim","propTypesModule","isClassComponent","elementType","acceptingRef","safePropName","warningHint","elementAcceptingRef","PropTypes","elementAcceptingRef$1","specialProperty","exactProp","propTypes","unsupportedProps","prop","formatMuiErrorMessage","code","url","REACT_SERVER_CONTEXT_TYPE","REACT_OFFSCREEN_TYPE","enableScopeAPI","enableCacheElement","enableTransitionTracing","enableLegacyHidden","enableDebugTracing","REACT_MODULE_REFERENCE","SuspenseList","hasWarnedAboutDeprecatedIsConcurrentMode","isSuspenseList","fnNameMatchRegex","getFunctionName","fn","getFunctionComponentName","Component","fallback","getWrappedName","outerType","innerType","wrapperName","functionName","getDisplayName","HTMLElementType","refType","refType$1","capitalize","string","_formatMuiErrorMessage","createChainedFunction","funcs","acc","func","debounce","wait","timeout","debounced","later","deprecatedPropType","validator","reason","componentNameSafe","propFullNameSafe","isMuiElement","muiNames","_muiName","_element$type","ownerDocument","node","ownerWindow","requirePropFactory","componentNameInError","prevPropTypes","requiredProp","defaultTypeChecker","typeCheckerResult","setRef","useEnhancedEffect","useEnhancedEffect$1","globalId","useGlobalId","idOverride","defaultId","setDefaultId","maybeReactUseId","useId","reactId","unsupportedProp","useControlled","controlled","defaultProp","name","isControlled","valueState","setValue","defaultValue","setValueIfUncontrolled","newValue","useEventCallback","useForkRef","refs","instance","UNINITIALIZED","useLazyRef","init","initArg","EMPTY","useOnMount","Timeout","delay","useTimeout","hadKeyboardEvent","hadFocusVisibleRecently","hadFocusVisibleRecentlyTimeout","inputTypesWhitelist","focusTriggersKeyboardModality","tagName","handlePointerDown","handleVisibilityChange","prepare","doc","isFocusVisible","useIsFocusVisible","isFocusVisibleRef","handleBlurVisible","handleFocusVisible","resolveProps","defaultProps","defaultSlotProps","slotProps","slotPropName","composeClasses","slots","getUtilityClass","classes","slot","utilityClass","defaultGenerator","createClassNameGenerator","generate","generator","ClassNameGenerator","ClassNameGenerator$1","globalStateClasses","generateUtilityClass","globalStatePrefix","globalStateClass","generateUtilityClasses","result","clamp","min","max","_objectWithoutPropertiesLoose","excluded","sourceKeys","_excluded","sortBreakpointsValues","breakpointsAsArray","breakpoint1","breakpoint2","createBreakpoints","breakpoints","unit","other","sortedValues","up","down","between","start","end","endIndex","only","not","keyIndex","shape","shape$1","responsivePropType","responsivePropType$1","merge","defaultBreakpoints","handleBreakpoints","styleFromPropValue","theme","themeBreakpoints","breakpoint","mediaKey","cssKey","createEmptyBreakpointObject","breakpointsInput","_breakpointsInput$key","breakpointStyleKey","removeUnusedBreakpoints","breakpointKeys","breakpointOutput","getPath","path","checkVars","getStyleValue","themeMapping","transform","propValueFinal","userValue","cssProperty","themeKey","memoize","cache","arg","properties","directions","aliases","getCssProperties","property","marginKeys","paddingKeys","spacingKeys","createUnaryUnit","_getPath","themeSpacing","abs","createUnarySpacing","getValue","transformer","transformed","getStyleFromPropValue","cssProperties","resolveCssProperty","margin","padding","createSpacing","spacingInput","spacing","argsInput","argument","compose","styles","handlers","borderTransform","createBorderStyle","border","borderTop","borderRight","borderBottom","borderLeft","borderColor","borderTopColor","borderRightColor","borderBottomColor","borderLeftColor","outline","outlineColor","borderRadius","gap","columnGap","rowGap","gridColumn","gridRow","gridAutoFlow","gridAutoColumns","gridAutoRows","gridTemplateColumns","gridTemplateRows","gridTemplateAreas","gridArea","paletteTransform","color","bgcolor","backgroundColor","sizingTransform","maxWidth","_props$theme","_props$theme2","breakpointsValues","minWidth","height","maxHeight","minHeight","boxSizing","defaultSxConfig","defaultSxConfig$1","objectsHaveSameKeys","objects","union","callIfFn","maybeFn","unstable_createStyleFunctionSx","getThemeValue","config","styleFunctionSx","_theme$unstable_sxCon","sx","traverse","sxInput","sxObject","emptyBreakpoints","breakpointsKeys","css","styleKey","styleFunctionSx$1","applyStyles","createTheme","paletteInput","shapeInput","muiTheme","isObjectEmpty","useTheme","defaultTheme","contextTheme","ThemeContext","systemDefaultTheme","useThemeWithoutDefault","_excluded2","_excluded3","isEmpty","isStringTag","tag","shouldForwardProp","lowercaseFirstLetter","resolveTheme","themeId","defaultOverridesResolver","processStyleArg","callableStyle","_ref","ownerState","resolvedStylesArg","resolvedStyle","variants","isMatch","createStyled","input","rootShouldForwardProp","slotShouldForwardProp","systemSx","inputOptions","processStyles","componentSlot","inputSkipVariantsResolver","inputSkipSx","overridesResolver","skipVariantsResolver","skipSx","shouldForwardPropOption","defaultStyledResolver","styledEngineStyled","transformStyleArg","stylesArg","muiStyledResolver","styleArg","expressions","transformedStyleArg","expressionsWithDefaultTheme","styleOverrides","resolvedStyleOverrides","slotKey","slotStyle","_theme$components","themeVariants","numOfCustomFnsApplied","placeholders","displayName","getThemeProps","params","useThemeProps","clampWrapper","hexToRgb","re","colors","decomposeColor","marker","colorSpace","recomposeColor","hslToRgb","rgb","getLuminance","getContrastRatio","foreground","background","lumA","lumB","alpha","darken","coefficient","lighten","createMixins","mixins","common","common$1","grey","grey$1","purple","purple$1","red","red$1","orange","orange$1","blue","blue$1","lightBlue","lightBlue$1","green","green$1","light","dark","addLightOrDark","intent","shade","tonalOffset","tonalOffsetLight","tonalOffsetDark","getDefaultPrimary","mode","getDefaultSecondary","getDefaultError","getDefaultInfo","getDefaultSuccess","getDefaultWarning","createPalette","palette","contrastThreshold","success","warning","getContrastText","contrastText","contrast","augmentColor","mainShade","lightShade","darkShade","modes","round","caseAllCaps","defaultFontFamily","createTypography","typography","fontFamily","fontSize","fontWeightLight","fontWeightRegular","fontWeightMedium","fontWeightBold","htmlFontSize","allVariants","pxToRem2","coef","pxToRem","buildVariant","fontWeight","lineHeight","letterSpacing","casing","shadowKeyUmbraOpacity","shadowKeyPenumbraOpacity","shadowAmbientShadowOpacity","createShadow","px","shadows","shadows$1","easing","duration","formatMs","milliseconds","getAutoHeightDuration","constant","createTransitions","inputTransitions","mergedEasing","mergedDuration","durationOption","easingOption","isString","isNumber","animatedProp","zIndex","zIndex$1","mixinsInput","transitionsInput","typographyInput","systemTheme","systemCreateTheme","stateClasses","component","child","stateClass","defaultTheme$1","THEME_ID","systemUseThemeProps","styled","styled$1","getSvgIconUtilityClass","useUtilityClasses","SvgIconRoot","_theme$transitions","_theme$transitions$cr","_theme$transitions2","_theme$typography","_theme$typography$pxT","_theme$typography2","_theme$typography2$px","_theme$typography3","_theme$typography3$px","_palette$ownerState$c","_palette","_palette2","_palette3","SvgIcon","inProps","htmlColor","inheritViewBox","titleAccess","viewBox","hasSvgAsChild","more","_jsxs","_jsx","SvgIcon$1","createSvgIcon","unstable_ClassNameGenerator","exports","_utils","ArrowRight","default_1","_createSvgIcon","_jsxRuntime","isHostComponent","appendOwnerState","otherProps","defaultContextValue","ClassNameConfiguratorContext","useClassNamesOverride","disableDefaultClasses","extractEventHandlers","excludeKeys","resolveComponentProps","componentProps","slotState","omitEventHandlers","mergeSlotProps","parameters","getSlotProps","additionalProps","externalSlotProps","externalForwardedProps","joinedClasses","mergedStyle","eventHandlers","componentsPropsWithoutEventHandlers","otherPropsWithoutEventHandlers","internalSlotProps","useSlotProps","_parameters$additiona","skipResolvingSlotProps","rest","resolvedComponentsProps","mergedProps","internalRef","GLOBAL_CLASS_PREFIX","buildStateClass","buildSlotClass","getContainer","container","forwardedRef","disablePortal","mountNode","setMountNode","handleRef","newProps","ReactDOM","top","bottom","right","left","auto","basePlacements","clippingParents","viewport","popper","reference","variationPlacements","placement","placements","beforeRead","read","afterRead","beforeMain","main","afterMain","beforeWrite","write","afterWrite","modifierPhases","getNodeName","getWindow","OwnElement","isHTMLElement","isShadowRoot","attributes","effect","_ref2","initialStyles","styleProperties","attribute","applyStyles$1","getBasePlacement","getUAString","uaData","isLayoutViewport","getBoundingClientRect","includeScale","isFixedStrategy","clientRect","scaleX","scaleY","visualViewport","addVisualOffsets","getLayoutRect","contains","parent","rootNode","next","getComputedStyle","isTableElement","getDocumentElement","getParentNode","getTrueOffsetParent","getContainingBlock","isFirefox","isIE","elementCss","currentNode","getOffsetParent","window","offsetParent","getMainAxisFromPlacement","within","mathMax","mathMin","withinMaxClamp","getFreshSideObject","mergePaddingObject","paddingObject","expandToHashMap","hashMap","toPaddingObject","arrow","_state$modifiersData$","arrowElement","popperOffsets","basePlacement","axis","isVertical","len","arrowRect","minProp","maxProp","endDiff","startDiff","arrowOffsetParent","clientSize","centerToReference","center","offset","axisProp","_options$element","arrow$1","getVariation","unsetSides","roundOffsetsByDPR","win","dpr","mapToStyles","_Object$assign2","popperRect","variation","offsets","gpuAcceleration","adaptive","roundOffsets","isFixed","_offsets$x","_offsets$y","_ref3","hasX","hasY","sideX","sideY","heightProp","widthProp","offsetY","offsetX","commonStyles","_ref4","_Object$assign","computeStyles","_ref5","_options$gpuAccelerat","_options$adaptive","_options$roundOffsets","computeStyles$1","passive","_options$scroll","scroll","_options$resize","resize","scrollParents","scrollParent","eventListeners","hash","getOppositePlacement","matched","getOppositeVariationPlacement","getWindowScroll","scrollLeft","scrollTop","getWindowScrollBarX","getViewportRect","strategy","html","layoutViewport","getDocumentRect","_element$ownerDocumen","winScroll","body","isScrollParent","_getComputedStyle","overflow","overflowX","overflowY","getScrollParent","listScrollParents","list","isBody","updatedList","rectToClientRect","rect","getInnerBoundingClientRect","getClientRectFromMixedType","clippingParent","getClippingParents","canEscapeClipping","clipperElement","getClippingRect","boundary","rootBoundary","mainClippingParents","firstClippingParent","clippingRect","accRect","computeOffsets","commonX","commonY","mainAxis","detectOverflow","_options","_options$placement","_options$strategy","_options$boundary","_options$rootBoundary","_options$elementConte","elementContext","_options$altBoundary","altBoundary","_options$padding","altContext","clippingClientRect","referenceClientRect","popperClientRect","elementClientRect","overflowOffsets","offsetData","multiply","computeAutoPlacement","flipVariations","_options$allowedAutoP","allowedAutoPlacements","allPlacements","allowedPlacements","overflows","getExpandedFallbackPlacements","oppositePlacement","flip","_options$mainAxis","checkMainAxis","_options$altAxis","checkAltAxis","specifiedFallbackPlacements","_options$flipVariatio","preferredPlacement","isBasePlacement","fallbackPlacements","referenceRect","checksMap","makeFallbackChecks","firstFittingPlacement","_basePlacement","isStartVariation","mainVariationSide","altVariationSide","checks","check","numberOfChecks","_loop","_i","fittingPlacement","_ret","flip$1","getSideOffsets","preventedOffsets","isAnySideFullyClipped","hide","referenceOverflow","popperAltOverflow","referenceClippingOffsets","popperEscapeOffsets","isReferenceHidden","hasPopperEscaped","hide$1","distanceAndSkiddingToXY","rects","invertDistance","skidding","distance","_options$offset","_data$state$placement","offset$1","popperOffsets$1","getAltAxis","preventOverflow","_options$tether","tether","_options$tetherOffset","tetherOffset","altAxis","tetherOffsetValue","normalizedTetherOffsetValue","offsetModifierState","_offsetModifierState$","mainSide","altSide","additive","minLen","maxLen","arrowPaddingObject","arrowPaddingMin","arrowPaddingMax","arrowLen","minOffset","maxOffset","clientOffset","offsetModifierValue","tetherMin","tetherMax","preventedOffset","_offsetModifierState$2","_mainSide","_altSide","_offset","_len","_min","_max","isOriginSide","_offsetModifierValue","_tetherMin","_tetherMax","_preventedOffset","preventOverflow$1","getHTMLElementScroll","getNodeScroll","isElementScaled","getCompositeRect","elementOrVirtualElement","isOffsetParentAnElement","offsetParentIsScaled","documentElement","order","modifiers","map","visited","modifier","sort","requires","dep","depModifier","orderModifiers","orderedModifiers","phase","pending","resolve","mergeByName","merged","current","existing","DEFAULT_OPTIONS","areValidElements","_key","popperGenerator","generatorOptions","_generatorOptions","_generatorOptions$def","defaultModifiers","_generatorOptions$def2","defaultOptions","effectCleanupFns","isDestroyed","setOptionsAction","cleanupModifierEffects","runModifierEffects","_state$elements","_state$orderedModifie","_state$orderedModifie2","_ref$options","cleanupFn","noopFn","createPopper","COMPONENT_NAME","getPopperUtilityClass","flipPlacement","resolveAnchorEl","anchorEl","isVirtualElement","defaultPopperOptions","PopperTooltip","_slots$root","initialPlacement","popperOptions","popperRefProp","TransitionProps","tooltipRef","ownRef","popperRef","handlePopperRef","handlePopperRefRef","rtlPlacement","setPlacement","resolvedAnchorElement","setResolvedAnchorElement","handlePopperUpdate","box","popperModifiers","childProps","Root","rootProps","Popper","containerProp","keepMounted","transition","exited","setExited","handleEnter","handleExited","resolvedAnchorEl","display","transitionProps","useThemeSystem","_setPrototypeOf","_inheritsLoose","subClass","superClass","setPrototypeOf","timeoutsShape","TransitionGroupContext","forceReflow","UNMOUNTED","EXITED","ENTERING","ENTERED","EXITING","Transition","_React$Component","_this","parentGroup","appear","initialStatus","prevState","nextIn","_proto","prevProps","nextStatus","exit","enter","mounting","_this2","appearing","maybeNode","maybeAppearing","timeouts","enterTimeout","_this3","nextState","callback","_this4","active","handler","doesNotHaveTimeoutOrListener","maybeNextCallback","_this$props","pt","noop","Transition$1","reflow","getTransitionProps","_style$transitionDura","_style$transitionTimi","getScale","isWebKit154","Grow","addEndListener","inProp","onEnter","onEntered","onEntering","onExit","onExited","onExiting","TransitionComponent","timer","autoTimeout","nodeRef","normalizedTransitionCallback","maybeIsAppearing","handleEntering","isAppearing","transitionDuration","transitionTimingFunction","handleEntered","handleExiting","handleExit","handleAddEndListener","Grow$1","PopperRoot","BasePopper","components","componentsProps","RootComponent","Popper$1","getTooltipUtilityClass","tooltipClasses","tooltipClasses$1","disableInteractive","touch","TooltipPopper","TooltipTooltip","TooltipArrow","hystersisOpen","hystersisTimer","cursorPosition","composeEventHandler","eventHandler","_slots$popper","_slots$transition","_slots$tooltip","_slots$arrow","_slotProps$popper","_ref6","_slotProps$popper2","_slotProps$transition","_slotProps$tooltip","_ref7","_slotProps$tooltip2","_slotProps$arrow","_ref8","_slotProps$arrow2","childrenProp","describeChild","disableFocusListener","disableHoverListener","disableInteractiveProp","disableTouchListener","enterDelay","enterNextDelay","enterTouchDelay","followCursor","idProp","leaveDelay","leaveTouchDelay","onClose","onOpen","PopperComponentProp","PopperProps","title","TransitionComponentProp","isRtl","childNode","setChildNode","arrowRef","setArrowRef","ignoreNonTouchEvents","closeTimer","enterTimer","leaveTimer","touchTimer","setOpenState","prevUserSelect","stopTouchInteraction","handleOpen","handleClose","handleLeave","focusVisibleRef","setChildIsFocusVisible","handleBlur","handleFocus","detectTouchStart","childrenProps","handleMouseOver","handleMouseLeave","handleTouchStart","handleTouchEnd","nativeEvent","handleMouseMove","nameOrDescProps","titleIsString","interactiveWrapperListeners","_PopperProps$popperOp","tooltipModifiers","PopperComponent","TooltipComponent","ArrowComponent","popperProps","tooltipProps","tooltipArrowProps","TransitionPropsInner","Tooltip$1","getIcon","icon","menuLabel","leading","MuiListItemIcon","MenuItem","allowForLeadingIcons","iconPathBefore","iconPathAfter","hasAutoFocus","isDense","isSubMenuParent","hasDisabledGutters","hasDivider","focusVisibleClassName","menuItem","MuiMenuItem","MuiListItemText","getAllGroups","menuDefinition","SubMenu","setAnchorEl","parentMenuItem","parentItemProps","handleParentMenuItemClick","renderSubMenuItems","includedGroups","group","GroupedMenuItemList","Menu","getOrderedGroupItems","groupId","allItems","menuProps","commandHandler","groupsToInclude","sortedGroups","itemArray","allowSpaceForLeadingIcons","createMenuItemProps","isLastItemInGroup","divKey","itemInfo","menuItemProps","TopLevelMenu","columnId","MenuColumn","metadata","Grid","List","GridMenu","multiColumnMenu","sortedColumns","columnNumbers","columnName","col","getUsePromiseOptionsDefaults","usePromise","promiseFactoryCallback","defaultValueRef","optionsDefaultedRef","setIsLoading","promiseIsCurrent","MenuIcon","HamburgerMenuButton","menuProvider","normalMenu","fullMenu","containerRef","ariaLabelPrefix","isMenuOpen","setMenuOpen","showFullMenu","setShowFullMenu","handleMenuItemClick","handleMenuButtonClick","prevIsOpen","isOpening","menuCommandHandler","command","setOffset","normalMenuData","fullMenuData","menu","IconButton","Drawer","isTooltipSuppressed","adjustMarginToAlignToEdge","MuiIconButton","Spinner","LoaderCircle","TextField","hasError","helperText","onFocus","onBlur","ShadLabel","Toolbar","AppBar","MuiToolbar","alertVariants","Alert","AlertTitle","AlertDescription","Card","CardHeader","CardTitle","CardDescription","CardContent","CardFooter","Sonner","Toaster","Slider","SliderPrimitive","Switch","SwitchPrimitives","Tabs","TabsList","TabsTrigger","TabsContent","InstallButton","isInstalling","handleClick","buttonText","Download","EnableButton","isEnabling","DisableButton","isDisabling","UpdateButton","isUpdating","MarkdownRenderer","markdown","anchorTarget","Markdown","FilterButton","Filter","DropdownMenuItemType","DropdownMenuItemType2","FilterDropdown","groups","NoExtensionsFound","MoreInfo","category","downloads","languages","moreInfoUrl","numberFormatted","NumberFormat","handleScrollToBottom","User","locale","LucideLink","CircleHelp","VersionHistory","versionHistory","showAllVersions","setShowAllVersions","currentDate","formatTimeString","dateString","date","dateDiff","yearDiff","monthDiff","dayDiff","timeString","sortedEntries","Footer","publisherDisplayName","fileSize","locales","formattedFileSize","formatBytes","languageNames","codes","displayNames","useEvent","unsubscriber","noopUnsubscriber","useEventAsync","unsubscribe","unsub"],"mappings":"28CAGA,MAAMA,GAAgBC,GAAAA,oBAAoB,CAAE,OAAQ,KAAO,CAAA,EAyDpD,SAASC,KAAMC,EAAsB,CACnC,OAAAH,GAAcI,GAAAA,KAAKD,CAAM,CAAC,CACnC,CCzDO,MAAME,GAAQC,EAAM,WACzB,CAAC,CAAE,UAAAC,EAAW,KAAAC,EAAM,GAAGC,CAAA,EAASC,IAE5BC,EAAA,IAAC,QAAA,CACC,KAAAH,EACA,UAAWN,EACT,sbACAK,CACF,EACA,IAAAG,EAEC,GAAGD,CAAA,CAAA,CAIZ,EACAJ,GAAM,YAAc,QCNpB,MAAMO,GAAmBC,EAAA,WACvB,CACE,CAAE,aAAAC,EAAc,cAAAC,EAAe,cAAAC,EAAe,aAAAC,EAAc,GAAGR,CAAM,EACrEC,IAGEQ,EAAA,KAAC,MAAI,CAAA,UAAU,cACb,SAAA,CAAAP,EAAA,IAACQ,GAAA,CACE,GAAGV,EACJ,KAAK,OACL,UAAU,0JACV,SAAWW,GAAUN,EAAaM,EAAM,OAAO,KAAK,EACpD,UAAYC,GAAM,CACZA,EAAE,MAAQ,SACCJ,IAEfF,EAAcM,CAAC,CACjB,EACA,QAASL,EACT,IAAAN,CAAA,CACF,EACAC,EAAA,IAACW,EAAA,QAAA,CACC,UAAU,8HACV,QAAS,IAAM,CAEb,QAAQ,IAAI,iBAAiB,CAC/B,CAAA,CACF,CACF,CAAA,CAAA,CAGN,EC9CA,IAAIC,GAAI,OAAO,eACXC,GAAI,CAACC,EAAGJ,EAAGK,IAAML,KAAKI,EAAIF,GAAEE,EAAGJ,EAAG,CAAE,WAAY,GAAI,aAAc,GAAI,SAAU,GAAI,MAAOK,CAAC,CAAE,EAAID,EAAEJ,CAAC,EAAIK,EACzGC,GAAI,CAACF,EAAGJ,EAAGK,IAAMF,GAAEC,EAAG,OAAOJ,GAAK,SAAWA,EAAI,GAAKA,EAAGK,CAAC,EAW9D,MAAME,GAAI,CACR,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MAEA,MAEA,MAEA,MAEA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,MAEA,MAEA,MAEA,MAEA,MACA,MACA,MACA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,KACF,EAAGC,GAAI,CACL,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,KACF,EAAGC,GAAI,CACL,UACA,SACA,YACA,UACA,cACA,SACA,SACA,OACA,WACA,WACA,UACA,UACA,eACA,eACA,OACA,WACA,kBACA,MACA,SACA,WACA,eACA,gBACA,SACA,WACA,eACA,UACA,kBACA,QACA,OACA,OACA,UACA,QACA,QACA,QACA,WACA,YACA,SACA,YACA,UACA,UACA,OACA,OACA,OACA,OACA,SACA,gBACA,gBACA,YACA,YACA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AAe,CACb,MAAOA,EACR,EACD,mBAAoB,CAClB,MAAOA,EACR,EACD,iBAAkB,CAChB,MAAOA,EACR,EACD,aAAc,CACZ,MAAOA,EACR,EACD,kBAAmB,CACjB,MAAOA,EACR,EACD,gBAAiB,CACf,MAAOA,EACR,EACD,EAAG,CACD,MAAOD,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,OAAQ,CACN,MAAOA,EACR,EACD,UAAW,CACT,MAAOA,EACR,EACD,YAAa,CACX,MAAOA,EACR,EACD,aAAc,CACZ,MAAOA,EACR,EACD,WAAY,CACV,MAAOA,EACR,EACD,QAAS,CACP,MAAOA,EACR,EACD,QAAS,CACP,MAAOA,EACR,EACD,aAAc,CACZ,MAAOA,EACR,EACD,kBAAmB,CACjB,MAAOA,EACR,EACD,gBAAiB,CACf,MAAOA,EACR,EACD,YAAa,CACX,MAAOA,EACR,EACD,iBAAkB,CAChB,MAAOA,EACR,EACD,eAAgB,CACd,MAAOA,EACR,EAED,aAAc,CACZ,YAAa,GACb,UAAW1xB,IAAU,CACnB,eAAgB,CACd,QAASA,CACV,CACP,EACG,EACD,QAAS,CAAE,EACX,SAAU,CAAE,EACZ,aAAc,CAAE,EAChB,WAAY,CAAE,EACd,WAAY,CAAE,EAEd,UAAW,CAAE,EACb,cAAe,CAAE,EACjB,SAAU,CAAE,EACZ,eAAgB,CAAE,EAClB,WAAY,CAAE,EACd,aAAc,CAAE,EAChB,MAAO,CAAE,EACT,KAAM,CAAE,EACR,SAAU,CAAE,EACZ,WAAY,CAAE,EACd,UAAW,CAAE,EACb,aAAc,CAAE,EAChB,YAAa,CAAE,EAEf,IAAK,CACH,MAAOmzB,EACR,EACD,OAAQ,CACN,MAAOE,EACR,EACD,UAAW,CACT,MAAOD,EACR,EACD,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,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,83,84,85,86,87,88,89,90,91,92,93,94,95,96,97,98,99,100,101,102,103,104,105,106,107,108,109,110,111,112,113,114,115,116,117,118,119,120,121,122,123,124,125,126,127,128,129,130,131,132,133,134,135,136,137,138,139,140,141,142,143,144,145,146,147,148,149,150,151,152,153,154,155,156,157,158,159,160,161,162,163,164,165,166,167,168,169,170,171,172,173,174,175,176,177,178,179,180,181,182,183,184,185,186,187,188,189,190,191,192,193,194,195,196,197,198,199,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,228]} \ No newline at end of file diff --git a/lib/platform-bible-react/dist/index.d.ts b/lib/platform-bible-react/dist/index.d.ts index b041f6653d..99def22981 100644 --- a/lib/platform-bible-react/dist/index.d.ts +++ b/lib/platform-bible-react/dist/index.d.ts @@ -451,8 +451,12 @@ export type SettingsSidebarProps = { handleSelectSidebarItem: (key: string, projectId?: string) => void; /** The current selected value in the sidebar */ selectedSidebarItem: SelectedSettingsSidebarItem; + /** Label for the group of extensions setting groups */ + extensionsSidebarGroupLabel: string; + /** Label for the group of projects settings */ + projectsSidebarGroupLabel: string; }; -export function SettingsSidebar({ id, extensionLabels, projectOptions, handleSelectSidebarItem, selectedSidebarItem, }: SettingsSidebarProps): import("react/jsx-runtime").JSX.Element; +export function SettingsSidebar({ id, extensionLabels, projectOptions, handleSelectSidebarItem, selectedSidebarItem, extensionsSidebarGroupLabel, projectsSidebarGroupLabel, }: SettingsSidebarProps): import("react/jsx-runtime").JSX.Element; export type SettingsSidebarContentSearchProps = SettingsSidebarProps & React$1.PropsWithChildren & { /** Optional id for testing */ id?: string; @@ -461,7 +465,7 @@ export type SettingsSidebarContentSearchProps = SettingsSidebarProps & React$1.P /** Handler to run when the value of the search bar changes */ onSearch: (searchQuery: string) => void; }; -export function SettingsSidebarContentSearch({ id, direction, extensionLabels, projectOptions, children, handleSelectSidebarItem, selectedSidebarItem, onSearch, }: SettingsSidebarContentSearchProps): import("react/jsx-runtime").JSX.Element; +export function SettingsSidebarContentSearch({ id, direction, extensionLabels, projectOptions, children, handleSelectSidebarItem, selectedSidebarItem, onSearch, extensionsSidebarGroupLabel, projectsSidebarGroupLabel, }: SettingsSidebarContentSearchProps): import("react/jsx-runtime").JSX.Element; /** * Information (e.g., a checking error or some other type of "transient" annotation) about something * noteworthy at a specific place in an instance of the Scriptures. diff --git a/lib/platform-bible-react/dist/index.js b/lib/platform-bible-react/dist/index.js index 8edfed1139..44518f1b19 100644 --- a/lib/platform-bible-react/dist/index.js +++ b/lib/platform-bible-react/dist/index.js @@ -777,18 +777,18 @@ const Tt = class nt { l.verse = i[0]; const c = l.verseNum; if (o.push(l), i.length > 1) { - const d = this.clone(); - if (d.verse = i[1], !e) - for (let p = c + 1; p < d.verseNum; p++) { - const h = new nt( + const p = this.clone(); + if (p.verse = i[1], !e) + for (let d = c + 1; d < p.verseNum; d++) { + const m = new nt( this._bookNum, this._chapterNum, - p, + d, this.versification ); - this.isExcluded || o.push(h); + this.isExcluded || o.push(m); } - o.push(d); + o.push(p); } } return o; @@ -1093,9 +1093,9 @@ function yc(t) { function gh({ scrRef: t, handleSubmit: e }) { const [n, r] = ut(""), [o, a] = ut( ot.bookNumberToId(t.bookNum) - ), [i, l] = ut(t.chapterNum ?? 0), [c, d] = ut( + ), [i, l] = ut(t.chapterNum ?? 0), [c, p] = ut( ot.bookNumberToId(t.bookNum) - ), [p, h] = ut(!1), [w, g] = ut(p), v = ge(void 0), f = ge(void 0), m = ge(void 0), E = Et( + ), [d, m] = ut(!1), [w, g] = ut(d), v = ge(void 0), f = ge(void 0), h = ge(void 0), E = Et( (k) => gc(k).filter((B) => { const D = ot.bookIdToEnglishName(B).toLowerCase(), J = n.replace(/[^a-zA-Z]/g, "").toLowerCase(); return D.includes(J) || // Match book name @@ -1109,7 +1109,7 @@ function gh({ scrRef: t, handleSubmit: e }) { C.current = !1; return; } - h(k); + m(k); }, []), b = Et( (k, B, D, J) => { if (l( @@ -1119,10 +1119,10 @@ function gh({ scrRef: t, handleSubmit: e }) { bookNum: ot.bookIdToNumber(k), chapterNum: D || 1, verseNum: J || 1 - }), h(!1), r(""); + }), m(!1), r(""); return; } - a(o !== k ? k : ""), h(!B); + a(o !== k ? k : ""), m(!B); }, [e, t.bookNum, t.chapterNum, o] ), I = (k) => { @@ -1142,13 +1142,13 @@ function gh({ scrRef: t, handleSubmit: e }) { }); }, [b, n]), H = Et( (k) => { - p ? (k.key === "ArrowDown" || k.key === "ArrowUp") && (typeof m < "u" && // Ref uses null + d ? (k.key === "ArrowDown" || k.key === "ArrowUp") && (typeof h < "u" && // Ref uses null // eslint-disable-next-line no-null/no-null - m.current !== null ? m.current.focus() : typeof f < "u" && // Ref uses null + h.current !== null ? h.current.focus() : typeof f < "u" && // Ref uses null // eslint-disable-next-line no-null/no-null - f.current !== null && f.current.focus(), k.preventDefault()) : h(!0); + f.current !== null && f.current.focus(), k.preventDefault()) : m(!0); }, - [p] + [d] ), O = (k) => { const { key: B } = k; B === "ArrowRight" || B === "ArrowLeft" || B === "ArrowDown" || B === "ArrowUp" || B === "Enter" || (v.current.dispatchEvent(new KeyboardEvent("keydown", { key: B })), v.current.focus()); @@ -1182,18 +1182,18 @@ function gh({ scrRef: t, handleSubmit: e }) { return ae(() => { o === c ? o === ot.bookNumberToId(t.bookNum) ? l(t.chapterNum) : l(1) : l(0); }, [c, t.bookNum, t.chapterNum, o]), ta(() => { - g(p); - }, [p]), ta(() => { + g(d); + }, [d]), ta(() => { const k = setTimeout(() => { - if (w && f.current && m.current) { - const D = m.current.offsetTop - mc; + if (w && f.current && h.current) { + const D = h.current.offsetTop - mc; f.current.scrollTo({ top: D, behavior: "instant" }); } }, 10); return () => { clearTimeout(k); }; - }, [w]), /* @__PURE__ */ s("div", { className: "pr-twp tw-flex", children: /* @__PURE__ */ N(fo, { modal: !1, open: p, onOpenChange: S, children: [ + }, [w]), /* @__PURE__ */ s("div", { className: "pr-twp tw-flex", children: /* @__PURE__ */ N(fo, { modal: !1, open: d, onOpenChange: S, children: [ /* @__PURE__ */ s(mi, { asChild: !0, children: /* @__PURE__ */ s( Wl, { @@ -1202,7 +1202,7 @@ function gh({ scrRef: t, handleSubmit: e }) { handleSearch: _, handleKeyDown: H, handleOnClick: () => { - a(ot.bookNumberToId(t.bookNum)), d(ot.bookNumberToId(t.bookNum)), l(t.chapterNum > 0 ? t.chapterNum : 0), h(!0), v.current.focus(); + a(ot.bookNumberToId(t.bookNum)), p(ot.bookNumberToId(t.bookNum)), l(t.chapterNum > 0 ? t.chapterNum : 0), m(!0), v.current.focus(); }, onFocus: () => { C.current = !0; @@ -1237,11 +1237,11 @@ function gh({ scrRef: t, handleSubmit: e }) { bookId: D, handleSelectBook: () => b(D, !1), isSelected: o === D, - handleHighlightBook: () => d(D), + handleHighlightBook: () => p(D), handleKeyDown: $, bookType: k, ref: (J) => { - o === D && (m.current = J); + o === D && (h.current = J); }, children: /* @__PURE__ */ s( uc, @@ -1470,9 +1470,9 @@ function qr({ getOptionLabel: i = Pc, buttonPlaceholder: l = "", textPlaceholder: c = "", - commandEmptyMessage: d = "No option found", - buttonVariant: p = "outline", - dir: h = "ltr", + commandEmptyMessage: p = "No option found", + buttonVariant: d = "outline", + dir: m = "ltr", isDisabled: w = !1, ...g }) { @@ -1481,7 +1481,7 @@ function qr({ /* @__PURE__ */ s(Ec, { asChild: !0, children: /* @__PURE__ */ N( gt, { - variant: p, + variant: d, role: "combobox", "aria-expanded": v, id: t, @@ -1493,29 +1493,29 @@ function qr({ ] } ) }), - /* @__PURE__ */ s(vi, { className: x("tw-w-[200px] tw-p-0", r), dir: h, children: /* @__PURE__ */ N(xi, { children: [ - /* @__PURE__ */ s(Ni, { dir: h, placeholder: c, className: "tw-text-inherit" }), - /* @__PURE__ */ s(Ei, { children: d }), - /* @__PURE__ */ s(ki, { children: e.map((m) => /* @__PURE__ */ N( + /* @__PURE__ */ s(vi, { className: x("tw-w-[200px] tw-p-0", r), dir: m, children: /* @__PURE__ */ N(xi, { children: [ + /* @__PURE__ */ s(Ni, { dir: m, placeholder: c, className: "tw-text-inherit" }), + /* @__PURE__ */ s(Ei, { children: p }), + /* @__PURE__ */ s(ki, { children: e.map((h) => /* @__PURE__ */ N( Si, { - value: i(m), + value: i(h), onSelect: () => { - a(m), f(!1); + a(h), f(!1); }, children: [ /* @__PURE__ */ s( tr, { className: x("tw-me-2 tw-h-4 tw-w-4", { - "tw-opacity-0": !o || i(o) !== i(m) + "tw-opacity-0": !o || i(o) !== i(h) }) } ), - i(m) + i(h) ] }, - i(m) + i(h) )) }) ] }) }) ] }); @@ -1529,7 +1529,7 @@ function $c({ chapterCount: a }) { const i = It( - () => Array.from({ length: a }, (d, p) => p + 1), + () => Array.from({ length: a }, (p, d) => d + 1), [a] ); return /* @__PURE__ */ N(ie, { children: [ @@ -1538,12 +1538,12 @@ function $c({ qr, { isDisabled: o, - onChange: (d) => { - n(d), d > e && r(d); + onChange: (p) => { + n(p), p > e && r(p); }, buttonClassName: "tw-ml-2 tw-mr-2 tw-w-20", options: i, - getOptionLabel: (d) => d.toString(), + getOptionLabel: (p) => p.toString(), value: t }, "start chapter" @@ -1553,12 +1553,12 @@ function $c({ qr, { isDisabled: o, - onChange: (d) => { - r(d), d < t && n(d); + onChange: (p) => { + r(p), p < t && n(p); }, buttonClassName: "tw-ml-2 tw-w-20", options: i, - getOptionLabel: (d) => d.toString(), + getOptionLabel: (p) => p.toString(), value: e }, "end chapter" @@ -1581,20 +1581,20 @@ function vh({ handleSelectEndChapter: i, startChapter: l, handleSelectStartChapter: c, - localizedStrings: d + localizedStrings: p }) { - const p = _r(d, "%webView_bookSelector_currentBook%"), h = _r(d, "%webView_bookSelector_choose%"), w = _r(d, "%webView_bookSelector_chooseBooks%"), [g, v] = ut( + const d = _r(p, "%webView_bookSelector_currentBook%"), m = _r(p, "%webView_bookSelector_choose%"), w = _r(p, "%webView_bookSelector_chooseBooks%"), [g, v] = ut( "current book" /* CURRENT_BOOK */ - ), f = (m) => { - v(m), t(m); + ), f = (h) => { + v(h), t(h); }; return /* @__PURE__ */ s( bi, { className: "pr-twp tw-flex", value: g, - onValueChange: (m) => f(m), + onValueChange: (h) => f(h), children: /* @__PURE__ */ N("div", { className: "tw-flex tw-w-full tw-flex-col tw-gap-4", children: [ /* @__PURE__ */ N("div", { className: "tw-grid tw-grid-cols-[25%,25%,50%]", children: [ /* @__PURE__ */ N("div", { className: "tw-flex tw-items-center", children: [ @@ -1602,7 +1602,7 @@ function vh({ value: "current book" /* CURRENT_BOOK */ }), - /* @__PURE__ */ s(Xt, { className: "tw-ml-1", children: p }) + /* @__PURE__ */ s(Xt, { className: "tw-ml-1", children: d }) ] }), /* @__PURE__ */ s(Xt, { className: "tw-flex tw-items-center", children: e }), /* @__PURE__ */ s("div", { className: "tw-flex tw-items-center tw-justify-end", children: /* @__PURE__ */ s( @@ -1625,13 +1625,13 @@ function vh({ }), /* @__PURE__ */ s(Xt, { className: "tw-ml-1", children: w }) ] }), - /* @__PURE__ */ s(Xt, { className: "tw-flex tw-items-center", children: r.map((m) => ot.bookIdToEnglishName(m)).join(", ") }), + /* @__PURE__ */ s(Xt, { className: "tw-flex tw-items-center", children: r.map((h) => ot.bookIdToEnglishName(h)).join(", ") }), /* @__PURE__ */ s( gt, { disabled: g === "current book", onClick: () => n(), - children: h + children: m } ) ] }) @@ -1937,22 +1937,22 @@ function Lc({ onRowClickHandler: i = () => { } }) { - var m; - const [l, c] = ut([]), [d, p] = ut([]), [h, w] = ut({}), [g, v] = ut({}), f = ei({ + var h; + const [l, c] = ut([]), [p, d] = ut([]), [m, w] = ut({}), [g, v] = ut({}), f = ei({ data: e, columns: t, getCoreRowModel: ni(), ...n && { getPaginationRowModel: _l() }, onSortingChange: c, getSortedRowModel: ri(), - onColumnFiltersChange: p, + onColumnFiltersChange: d, getFilteredRowModel: Pl(), onColumnVisibilityChange: w, onRowSelectionChange: v, state: { sorting: l, - columnFilters: d, - columnVisibility: h, + columnFilters: p, + columnVisibility: m, rowSelection: g } }); @@ -1960,7 +1960,7 @@ function Lc({ o && /* @__PURE__ */ s(Ac, { table: f }), /* @__PURE__ */ N(ar, { stickyHeader: a, children: [ /* @__PURE__ */ s(ir, { stickyHeader: a, children: f.getHeaderGroups().map((E) => /* @__PURE__ */ s(oe, { children: E.headers.map((_) => /* @__PURE__ */ s(vn, { children: _.isPlaceholder ? void 0 : dn(_.column.columnDef.header, _.getContext()) }, _.id)) }, E.id)) }), - /* @__PURE__ */ s(sr, { children: (m = f.getRowModel().rows) != null && m.length ? f.getRowModel().rows.map((E) => /* @__PURE__ */ s( + /* @__PURE__ */ s(sr, { children: (h = f.getRowModel().rows) != null && h.length ? f.getRowModel().rows.map((E) => /* @__PURE__ */ s( oe, { onClick: () => i(E, f), @@ -2142,11 +2142,11 @@ const lr = (t) => t === "asc" ? /* @__PURE__ */ s(ul, { className: "tw-ms-2 tw-h }), Pr = (t, e, n, r, o, a) => { let i = [...n]; t.forEach((c) => { - e === "approved" ? i.includes(c) || i.push(c) : i = i.filter((d) => d !== c); + e === "approved" ? i.includes(c) || i.push(c) : i = i.filter((p) => p !== c); }), r(i); let l = [...o]; t.forEach((c) => { - e === "unapproved" ? l.includes(c) || l.push(c) : l = l.filter((d) => d !== c); + e === "unapproved" ? l.includes(c) || l.push(c) : l = l.filter((p) => p !== c); }), a(l); }, Nh = (t, e, n, r, o) => ({ accessorKey: "status", @@ -2226,32 +2226,32 @@ const lr = (t) => t === "asc" ? /* @__PURE__ */ s(ul, { className: "tw-ms-2 tw-h return []; const a = []; let i = e.bookNum, l = e.chapterNum, c = e.verseNum; - return Uc(t).forEach((p) => { - p.startsWith("\\id") && (i = Gc(p), l = 0, c = 0), p.startsWith("\\c") && (l = oa(p), c = 0), p.startsWith("\\v") && (c = oa(p), l === 0 && (l = e.chapterNum)); - let h = o.exec(p) ?? void 0; - for (; h; ) { + return Uc(t).forEach((d) => { + d.startsWith("\\id") && (i = Gc(d), l = 0, c = 0), d.startsWith("\\c") && (l = oa(d), c = 0), d.startsWith("\\v") && (c = oa(d), l === 0 && (l = e.chapterNum)); + let m = o.exec(d) ?? void 0; + for (; m; ) { const w = []; - h.forEach((m) => w.push(m)); - const g = h.index, v = a.find((m) => co(m.items, w)), f = { + m.forEach((h) => w.push(h)); + const g = m.index, v = a.find((h) => co(h.items, w)), f = { reference: { bookNum: i !== void 0 ? i : -1, chapterNum: l !== void 0 ? l : -1, verseNum: c !== void 0 ? c : -1 }, - text: Cl(p, Math.max(0, g - 25), Math.min(g + 25, p.length)) + text: Cl(d, Math.max(0, g - 25), Math.min(g + 25, d.length)) }; if (v) v.count += 1, v.occurrences.push(f); else { - const m = { + const h = { items: w, count: 1, status: Hc(w[0], n, r), occurrences: [f] }; - a.push(m); + a.push(h); } - h = o.exec(p) ?? void 0; + m = o.exec(d) ?? void 0; } }), a; }, Jt = (t, e) => t[e] ?? e; @@ -2265,10 +2265,10 @@ function Eh({ unapprovedItems: i, text: l, scope: c, - onScopeChange: d, - columns: p + onScopeChange: p, + columns: d }) { - const h = Jt(n, "%webView_inventory_all%"), w = Jt(n, "%webView_inventory_approved%"), g = Jt(n, "%webView_inventory_unapproved%"), v = Jt(n, "%webView_inventory_unknown%"), f = Jt(n, "%webView_inventory_scope_currentBook%"), m = Jt(n, "%webView_inventory_scope_chapter%"), E = Jt(n, "%webView_inventory_scope_verse%"), _ = Jt(n, "%webView_inventory_filter_text%"), C = Jt( + const m = Jt(n, "%webView_inventory_all%"), w = Jt(n, "%webView_inventory_approved%"), g = Jt(n, "%webView_inventory_unapproved%"), v = Jt(n, "%webView_inventory_unknown%"), f = Jt(n, "%webView_inventory_scope_currentBook%"), h = Jt(n, "%webView_inventory_scope_chapter%"), E = Jt(n, "%webView_inventory_scope_verse%"), _ = Jt(n, "%webView_inventory_filter_text%"), C = Jt( n, "%webView_inventory_show_additional_items%" ), [S, b] = ut(!1), [I, z] = ut("all"), [H, O] = ut(""), [$, k] = ut([]), B = It(() => l ? r instanceof RegExp ? qc( @@ -2295,10 +2295,10 @@ function Eh({ }, [S, B]), J = It(() => Wc(D, I, H), [D, I, H]), q = It(() => { var L, F; if (!S) - return p; + return d; const y = (L = o == null ? void 0 : o.tableHeaders) == null ? void 0 : L.length; if (!y) - return p; + return d; const R = []; for (let V = 0; V < y; V++) R.push( @@ -2307,8 +2307,8 @@ function Eh({ V + 1 ) ); - return [...R, ...p]; - }, [o == null ? void 0 : o.tableHeaders, p, S]); + return [...R, ...d]; + }, [o == null ? void 0 : o.tableHeaders, d, S]); ae(() => { k([]); }, [J]); @@ -2319,7 +2319,7 @@ function Eh({ }), k(y.original.items); }, tt = (y) => { if (y === "book" || y === "chapter" || y === "verse") - d(y); + p(y); else throw new Error(`Invalid scope value: ${y}`); }, at = (y) => { @@ -2348,7 +2348,7 @@ function Eh({ children: [ /* @__PURE__ */ s(De, { className: "tw-m-1", children: /* @__PURE__ */ s(bn, { placeholder: "Select filter" }) }), /* @__PURE__ */ N(Be, { children: [ - /* @__PURE__ */ s(Gt, { value: "all", children: h }), + /* @__PURE__ */ s(Gt, { value: "all", children: m }), /* @__PURE__ */ s(Gt, { value: "approved", children: w }), /* @__PURE__ */ s(Gt, { value: "unapproved", children: g }), /* @__PURE__ */ s(Gt, { value: "unknown", children: v }) @@ -2360,7 +2360,7 @@ function Eh({ /* @__PURE__ */ s(De, { className: "tw-m-1", children: /* @__PURE__ */ s(bn, { placeholder: "Select scope" }) }), /* @__PURE__ */ N(Be, { children: [ /* @__PURE__ */ s(Gt, { value: "book", children: f }), - /* @__PURE__ */ s(Gt, { value: "chapter", children: m }), + /* @__PURE__ */ s(Gt, { value: "chapter", children: h }), /* @__PURE__ */ s(Gt, { value: "verse", children: E }) ] }) ] }), @@ -2622,30 +2622,30 @@ const Vi = T.forwardRef( children: a, ...i }, l) => { - const c = ad(), [d, p] = T.useState(!1), [h, w] = T.useState(t), g = e ?? h, v = T.useCallback( + const c = ad(), [p, d] = T.useState(!1), [m, w] = T.useState(t), g = e ?? m, v = T.useCallback( (_) => { const C = typeof _ == "function" ? _(g) : _; n ? n(C) : w(C), document.cookie = `${id}=${C}; path=/; max-age=${sd}`; }, [n, g] - ), f = T.useCallback(() => c ? p((_) => !_) : v((_) => !_), [c, v, p]); + ), f = T.useCallback(() => c ? d((_) => !_) : v((_) => !_), [c, v, d]); T.useEffect(() => { const _ = (C) => { C.key === pd && (C.metaKey || C.ctrlKey) && (C.preventDefault(), f()); }; return window.addEventListener("keydown", _), () => window.removeEventListener("keydown", _); }, [f]); - const m = g ? "expanded" : "collapsed", E = T.useMemo( + const h = g ? "expanded" : "collapsed", E = T.useMemo( () => ({ - state: m, + state: h, open: g, setOpen: v, isMobile: c, - openMobile: d, - setOpenMobile: p, + openMobile: p, + setOpenMobile: d, toggleSidebar: f }), - [m, g, v, c, d, p, f] + [h, g, v, c, p, d, f] ); return /* @__PURE__ */ s(ji.Provider, { value: E, children: /* @__PURE__ */ s(nd, { delayDuration: 0, children: /* @__PURE__ */ s( "div", @@ -2680,7 +2680,7 @@ const zi = T.forwardRef( children: o, ...a }, i) => { - const { isMobile: l, state: c, openMobile: d, setOpenMobile: p } = cr(); + const { isMobile: l, state: c, openMobile: p, setOpenMobile: d } = cr(); return n === "none" ? /* @__PURE__ */ s( "div", { @@ -2692,7 +2692,7 @@ const zi = T.forwardRef( ...a, children: o } - ) : l ? /* @__PURE__ */ s(Jc, { open: d, onOpenChange: p, ...a, children: /* @__PURE__ */ s( + ) : l ? /* @__PURE__ */ s(Jc, { open: p, onOpenChange: d, ...a, children: /* @__PURE__ */ s( Di, { "data-sidebar": "sidebar", @@ -2992,7 +2992,7 @@ const vd = Xe( className: a, ...i }, l) => { - const c = t ? He : "button", { isMobile: d, state: p } = cr(), h = /* @__PURE__ */ s( + const c = t ? He : "button", { isMobile: p, state: d } = cr(), m = /* @__PURE__ */ s( c, { ref: l, @@ -3006,17 +3006,17 @@ const vd = Xe( return o ? (typeof o == "string" && (o = { children: o }), /* @__PURE__ */ N(rd, { children: [ - /* @__PURE__ */ s(od, { asChild: !0, children: h }), + /* @__PURE__ */ s(od, { asChild: !0, children: m }), /* @__PURE__ */ s( Bi, { side: "right", align: "center", - hidden: p !== "collapsed" || d, + hidden: d !== "collapsed" || p, ...o } ) - ] })) : h; + ] })) : m; } ); Hi.displayName = "SidebarMenuButton"; @@ -3133,21 +3133,23 @@ function Td({ extensionLabels: e, projectOptions: n, handleSelectSidebarItem: r, - selectedSidebarItem: o + selectedSidebarItem: o, + extensionsSidebarGroupLabel: a, + projectsSidebarGroupLabel: i }) { - const a = Et( - (c, d) => { - r(c, d); + const l = Et( + (d, m) => { + r(d, m); }, [r] - ), i = Et( - (c) => { - const d = n.find((p) => p.projectId === c); - return d ? d.projectName : c; + ), c = Et( + (d) => { + const m = n.find((w) => w.projectId === d); + return m ? m.projectName : d; }, [n] - ), l = Et( - (c) => !o.projectId && c === o.label, + ), p = Et( + (d) => !o.projectId && d === o.label, [o] ); return /* @__PURE__ */ s( @@ -3159,32 +3161,32 @@ function Td({ className: "tw-w-96 tw-gap-2 tw-overflow-y-auto tw-rounded tw-bg-slate-100", children: /* @__PURE__ */ N(Fi, { children: [ /* @__PURE__ */ N(Kr, { children: [ - /* @__PURE__ */ s(Jr, { className: "tw-text-sm tw-text-gray-400", children: "Extensions" }), - /* @__PURE__ */ s(Zr, { children: /* @__PURE__ */ s(Ui, { children: e.map((c) => /* @__PURE__ */ s(Gi, { children: /* @__PURE__ */ s( + /* @__PURE__ */ s(Jr, { className: "tw-text-sm tw-text-gray-400", children: a }), + /* @__PURE__ */ s(Zr, { children: /* @__PURE__ */ s(Ui, { children: e.map((d) => /* @__PURE__ */ s(Gi, { children: /* @__PURE__ */ s( Hi, { className: x( "tw-rounded tw-py-2 tw-text-sm tw-text-gray-500 hover:tw-bg-white hover:tw-text-gray-900 hover:tw-shadow-sm active:tw-bg-white", - { "tw-bg-white tw-text-gray-900 tw-shadow-sm": l(c) } + { "tw-bg-white tw-text-gray-900 tw-shadow-sm": p(d) } ), - onClick: () => a(c, void 0), - isActive: l(c), - children: /* @__PURE__ */ s("span", { className: "tw-pl-3", children: c }) + onClick: () => l(d, void 0), + isActive: p(d), + children: /* @__PURE__ */ s("span", { className: "tw-pl-3", children: d }) } - ) }, c)) }) }) + ) }, d)) }) }) ] }), /* @__PURE__ */ N(Kr, { children: [ - /* @__PURE__ */ s(Jr, { className: "tw-text-sm tw-text-gray-400", children: "Projects" }), + /* @__PURE__ */ s(Jr, { className: "tw-text-sm tw-text-gray-400", children: i }), /* @__PURE__ */ s(Zr, { className: "tw-pl-3", children: /* @__PURE__ */ s( qr, { popoverContentClassName: "tw-z-[1000]", - options: n.flatMap((c) => c.projectId), - getOptionLabel: (c) => i(c), + options: n.flatMap((d) => d.projectId), + getOptionLabel: (d) => c(d), buttonPlaceholder: "Type or select project", - onChange: (c) => { - const d = i(c); - a(d, c); + onChange: (d) => { + const m = c(d); + l(m, d); }, value: (o == null ? void 0 : o.projectId) ?? void 0 } @@ -3202,7 +3204,9 @@ function Th({ children: o, handleSelectSidebarItem: a, selectedSidebarItem: i, - onSearch: l + onSearch: l, + extensionsSidebarGroupLabel: c, + projectsSidebarGroupLabel: p }) { return /* @__PURE__ */ N("div", { className: "tw-flex tw-h-full tw-flex-col tw-p-3 tw-pb-2", children: [ /* @__PURE__ */ s("div", { className: "tw-flex tw-items-center tw-justify-center tw-py-4", children: /* @__PURE__ */ s( @@ -3220,7 +3224,9 @@ function Th({ extensionLabels: n, projectOptions: r, handleSelectSidebarItem: a, - selectedSidebarItem: i + selectedSidebarItem: i, + extensionsSidebarGroupLabel: c, + projectsSidebarGroupLabel: p } ), /* @__PURE__ */ s(Li, { className: "tw-overflow-y-auto", children: o }) @@ -3292,13 +3298,13 @@ function Ch({ onRowSelected: l, direction: c = "ltr" }) { - const [d, p] = ut([]), [h, w] = ut([{ id: ne, desc: !1 }]), [g, v] = ut({}), f = It( + const [p, d] = ut([]), [m, w] = ut([{ id: ne, desc: !1 }]), [g, v] = ut({}), f = It( () => t.flatMap((O) => O.data.map(($) => ({ ...$, source: O.source }))), [t] - ), m = It( + ), h = It( () => $d( { scriptureReferenceColumnName: r, @@ -3310,20 +3316,20 @@ function Ch({ [r, a, i, n] ); ae(() => { - d.includes(we) ? w([ + p.includes(we) ? w([ { id: we, desc: !1 }, { id: ne, desc: !1 } ]) : w([{ id: ne, desc: !1 }]); - }, [d]); + }, [p]); const E = ei({ data: f, - columns: m, + columns: h, state: { - grouping: d, - sorting: h, + grouping: p, + sorting: m, rowSelection: g }, - onGroupingChange: p, + onGroupingChange: d, onSortingChange: w, onRowSelectionChange: v, getExpandedRowModel: $l(), @@ -3357,7 +3363,7 @@ function Ch({ value: [we, ne] } ], b = (O) => { - p(JSON.parse(O)); + d(JSON.parse(O)); }, I = (O, $) => { !O.getIsGrouped() && !O.getIsSelected() && O.getToggleSelectedHandler()($); }, z = (O, $) => O.getIsGrouped() ? "" : x("banded-row", $ % 2 === 0 ? "even" : "odd"), H = (O, $, k) => { @@ -3383,7 +3389,7 @@ function Ch({ !e && /* @__PURE__ */ N( gn, { - value: JSON.stringify(d), + value: JSON.stringify(p), onValueChange: (O) => { b(O); }, @@ -3425,7 +3431,7 @@ function Ch({ className: x( k.column.columnDef.id, "tw-p-[1px]", - H(d, O, k) + H(p, O, k) ), children: (() => k.getIsGrouped() ? /* @__PURE__ */ N( gt, @@ -3661,7 +3667,7 @@ function Bd() { if (sa) return it; sa = 1; - var t = typeof Symbol == "function" && Symbol.for, e = t ? Symbol.for("react.element") : 60103, n = t ? Symbol.for("react.portal") : 60106, r = t ? Symbol.for("react.fragment") : 60107, o = t ? Symbol.for("react.strict_mode") : 60108, a = t ? Symbol.for("react.profiler") : 60114, i = t ? Symbol.for("react.provider") : 60109, l = t ? Symbol.for("react.context") : 60110, c = t ? Symbol.for("react.async_mode") : 60111, d = t ? Symbol.for("react.concurrent_mode") : 60111, p = t ? Symbol.for("react.forward_ref") : 60112, h = t ? Symbol.for("react.suspense") : 60113, w = t ? Symbol.for("react.suspense_list") : 60120, g = t ? Symbol.for("react.memo") : 60115, v = t ? Symbol.for("react.lazy") : 60116, f = t ? Symbol.for("react.block") : 60121, m = t ? Symbol.for("react.fundamental") : 60117, E = t ? Symbol.for("react.responder") : 60118, _ = t ? Symbol.for("react.scope") : 60119; + var t = typeof Symbol == "function" && Symbol.for, e = t ? Symbol.for("react.element") : 60103, n = t ? Symbol.for("react.portal") : 60106, r = t ? Symbol.for("react.fragment") : 60107, o = t ? Symbol.for("react.strict_mode") : 60108, a = t ? Symbol.for("react.profiler") : 60114, i = t ? Symbol.for("react.provider") : 60109, l = t ? Symbol.for("react.context") : 60110, c = t ? Symbol.for("react.async_mode") : 60111, p = t ? Symbol.for("react.concurrent_mode") : 60111, d = t ? Symbol.for("react.forward_ref") : 60112, m = t ? Symbol.for("react.suspense") : 60113, w = t ? Symbol.for("react.suspense_list") : 60120, g = t ? Symbol.for("react.memo") : 60115, v = t ? Symbol.for("react.lazy") : 60116, f = t ? Symbol.for("react.block") : 60121, h = t ? Symbol.for("react.fundamental") : 60117, E = t ? Symbol.for("react.responder") : 60118, _ = t ? Symbol.for("react.scope") : 60119; function C(b) { if (typeof b == "object" && b !== null) { var I = b.$$typeof; @@ -3669,16 +3675,16 @@ function Bd() { case e: switch (b = b.type, b) { case c: - case d: + case p: case r: case a: case o: - case h: + case m: return b; default: switch (b = b && b.$$typeof, b) { case l: - case p: + case d: case v: case g: case i: @@ -3693,9 +3699,9 @@ function Bd() { } } function S(b) { - return C(b) === d; + return C(b) === p; } - return it.AsyncMode = c, it.ConcurrentMode = d, it.ContextConsumer = l, it.ContextProvider = i, it.Element = e, it.ForwardRef = p, it.Fragment = r, it.Lazy = v, it.Memo = g, it.Portal = n, it.Profiler = a, it.StrictMode = o, it.Suspense = h, it.isAsyncMode = function(b) { + return it.AsyncMode = c, it.ConcurrentMode = p, it.ContextConsumer = l, it.ContextProvider = i, it.Element = e, it.ForwardRef = d, it.Fragment = r, it.Lazy = v, it.Memo = g, it.Portal = n, it.Profiler = a, it.StrictMode = o, it.Suspense = m, it.isAsyncMode = function(b) { return S(b) || C(b) === c; }, it.isConcurrentMode = S, it.isContextConsumer = function(b) { return C(b) === l; @@ -3704,7 +3710,7 @@ function Bd() { }, it.isElement = function(b) { return typeof b == "object" && b !== null && b.$$typeof === e; }, it.isForwardRef = function(b) { - return C(b) === p; + return C(b) === d; }, it.isFragment = function(b) { return C(b) === r; }, it.isLazy = function(b) { @@ -3718,9 +3724,9 @@ function Bd() { }, it.isStrictMode = function(b) { return C(b) === o; }, it.isSuspense = function(b) { - return C(b) === h; + return C(b) === m; }, it.isValidElementType = function(b) { - return typeof b == "string" || typeof b == "function" || b === r || b === d || b === a || b === o || b === h || b === w || typeof b == "object" && b !== null && (b.$$typeof === v || b.$$typeof === g || b.$$typeof === i || b.$$typeof === l || b.$$typeof === p || b.$$typeof === m || b.$$typeof === E || b.$$typeof === _ || b.$$typeof === f); + return typeof b == "string" || typeof b == "function" || b === r || b === p || b === a || b === o || b === m || b === w || typeof b == "object" && b !== null && (b.$$typeof === v || b.$$typeof === g || b.$$typeof === i || b.$$typeof === l || b.$$typeof === d || b.$$typeof === h || b.$$typeof === E || b.$$typeof === _ || b.$$typeof === f); }, it.typeOf = C, it; } var st = {}; @@ -3735,10 +3741,10 @@ var st = {}; var la; function jd() { return la || (la = 1, process.env.NODE_ENV !== "production" && function() { - var t = typeof Symbol == "function" && Symbol.for, e = t ? Symbol.for("react.element") : 60103, n = t ? Symbol.for("react.portal") : 60106, r = t ? Symbol.for("react.fragment") : 60107, o = t ? Symbol.for("react.strict_mode") : 60108, a = t ? Symbol.for("react.profiler") : 60114, i = t ? Symbol.for("react.provider") : 60109, l = t ? Symbol.for("react.context") : 60110, c = t ? Symbol.for("react.async_mode") : 60111, d = t ? Symbol.for("react.concurrent_mode") : 60111, p = t ? Symbol.for("react.forward_ref") : 60112, h = t ? Symbol.for("react.suspense") : 60113, w = t ? Symbol.for("react.suspense_list") : 60120, g = t ? Symbol.for("react.memo") : 60115, v = t ? Symbol.for("react.lazy") : 60116, f = t ? Symbol.for("react.block") : 60121, m = t ? Symbol.for("react.fundamental") : 60117, E = t ? Symbol.for("react.responder") : 60118, _ = t ? Symbol.for("react.scope") : 60119; + var t = typeof Symbol == "function" && Symbol.for, e = t ? Symbol.for("react.element") : 60103, n = t ? Symbol.for("react.portal") : 60106, r = t ? Symbol.for("react.fragment") : 60107, o = t ? Symbol.for("react.strict_mode") : 60108, a = t ? Symbol.for("react.profiler") : 60114, i = t ? Symbol.for("react.provider") : 60109, l = t ? Symbol.for("react.context") : 60110, c = t ? Symbol.for("react.async_mode") : 60111, p = t ? Symbol.for("react.concurrent_mode") : 60111, d = t ? Symbol.for("react.forward_ref") : 60112, m = t ? Symbol.for("react.suspense") : 60113, w = t ? Symbol.for("react.suspense_list") : 60120, g = t ? Symbol.for("react.memo") : 60115, v = t ? Symbol.for("react.lazy") : 60116, f = t ? Symbol.for("react.block") : 60121, h = t ? Symbol.for("react.fundamental") : 60117, E = t ? Symbol.for("react.responder") : 60118, _ = t ? Symbol.for("react.scope") : 60119; function C(A) { return typeof A == "string" || typeof A == "function" || // Note: its typeof might be other than 'symbol' or 'number' if it's a polyfill. - A === r || A === d || A === a || A === o || A === h || A === w || typeof A == "object" && A !== null && (A.$$typeof === v || A.$$typeof === g || A.$$typeof === i || A.$$typeof === l || A.$$typeof === p || A.$$typeof === m || A.$$typeof === E || A.$$typeof === _ || A.$$typeof === f); + A === r || A === p || A === a || A === o || A === m || A === w || typeof A == "object" && A !== null && (A.$$typeof === v || A.$$typeof === g || A.$$typeof === i || A.$$typeof === l || A.$$typeof === d || A.$$typeof === h || A.$$typeof === E || A.$$typeof === _ || A.$$typeof === f); } function S(A) { if (typeof A == "object" && A !== null) { @@ -3748,17 +3754,17 @@ function jd() { var j = A.type; switch (j) { case c: - case d: + case p: case r: case a: case o: - case h: + case m: return j; default: var xt = j && j.$$typeof; switch (xt) { case l: - case p: + case d: case v: case g: case i: @@ -3772,12 +3778,12 @@ function jd() { } } } - var b = c, I = d, z = l, H = i, O = e, $ = p, k = r, B = v, D = g, J = n, q = a, U = o, tt = h, at = !1; + var b = c, I = p, z = l, H = i, O = e, $ = d, k = r, B = v, D = g, J = n, q = a, U = o, tt = m, at = !1; function rt(A) { return at || (at = !0, console.warn("The ReactIs.isAsyncMode() alias has been deprecated, and will be removed in React 17+. Update your code to use ReactIs.isConcurrentMode() instead. It has the exact same API.")), y(A) || S(A) === c; } function y(A) { - return S(A) === d; + return S(A) === p; } function R(A) { return S(A) === l; @@ -3789,7 +3795,7 @@ function jd() { return typeof A == "object" && A !== null && A.$$typeof === e; } function V(A) { - return S(A) === p; + return S(A) === d; } function W(A) { return S(A) === r; @@ -3810,7 +3816,7 @@ function jd() { return S(A) === o; } function dt(A) { - return S(A) === h; + return S(A) === m; } st.AsyncMode = b, st.ConcurrentMode = I, st.ContextConsumer = z, st.ContextProvider = H, st.Element = O, st.ForwardRef = $, st.Fragment = k, st.Lazy = B, st.Memo = D, st.Portal = J, st.Profiler = q, st.StrictMode = U, st.Suspense = tt, st.isAsyncMode = rt, st.isConcurrentMode = y, st.isContextConsumer = R, st.isContextProvider = L, st.isElement = F, st.isForwardRef = V, st.isFragment = W, st.isLazy = X, st.isMemo = Y, st.isPortal = G, st.isProfiler = K, st.isStrictMode = Z, st.isSuspense = dt, st.isValidElementType = C, st.typeOf = S; }()), st; @@ -3844,28 +3850,28 @@ function Vd() { return !1; for (var i = {}, l = 0; l < 10; l++) i["_" + String.fromCharCode(l)] = l; - var c = Object.getOwnPropertyNames(i).map(function(p) { - return i[p]; + var c = Object.getOwnPropertyNames(i).map(function(d) { + return i[d]; }); if (c.join("") !== "0123456789") return !1; - var d = {}; - return "abcdefghijklmnopqrst".split("").forEach(function(p) { - d[p] = p; - }), Object.keys(Object.assign({}, d)).join("") === "abcdefghijklmnopqrst"; + var p = {}; + return "abcdefghijklmnopqrst".split("").forEach(function(d) { + p[d] = d; + }), Object.keys(Object.assign({}, p)).join("") === "abcdefghijklmnopqrst"; } catch { return !1; } } return Mr = o() ? Object.assign : function(a, i) { - for (var l, c = r(a), d, p = 1; p < arguments.length; p++) { - l = Object(arguments[p]); - for (var h in l) - e.call(l, h) && (c[h] = l[h]); + for (var l, c = r(a), p, d = 1; d < arguments.length; d++) { + l = Object(arguments[d]); + for (var m in l) + e.call(l, m) && (c[m] = l[m]); if (t) { - d = t(l); - for (var w = 0; w < d.length; w++) - n.call(l, d[w]) && (c[d[w]] = l[d[w]]); + p = t(l); + for (var w = 0; w < p.length; w++) + n.call(l, p[w]) && (c[p[w]] = l[p[w]]); } } return c; @@ -3901,29 +3907,29 @@ function zd() { } }; } - function o(a, i, l, c, d) { + function o(a, i, l, c, p) { if (process.env.NODE_ENV !== "production") { - for (var p in a) - if (r(a, p)) { - var h; + for (var d in a) + if (r(a, d)) { + var m; try { - if (typeof a[p] != "function") { + if (typeof a[d] != "function") { var w = Error( - (c || "React class") + ": " + l + " type `" + p + "` is invalid; it must be a function, usually from the `prop-types` package, but received `" + typeof a[p] + "`.This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`." + (c || "React class") + ": " + l + " type `" + d + "` is invalid; it must be a function, usually from the `prop-types` package, but received `" + typeof a[d] + "`.This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`." ); throw w.name = "Invariant Violation", w; } - h = a[p](i, p, c, l, null, e); + m = a[d](i, d, c, l, null, e); } catch (v) { - h = v; + m = v; } - if (h && !(h instanceof Error) && t( - (c || "React class") + ": type specification of " + l + " `" + p + "` is invalid; the type checker function must return `null` or an `Error` but returned a " + typeof h + ". You may have forgotten to pass an argument to the type checker creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and shape all require an argument)." - ), h instanceof Error && !(h.message in n)) { - n[h.message] = !0; - var g = d ? d() : ""; + if (m && !(m instanceof Error) && t( + (c || "React class") + ": type specification of " + l + " `" + d + "` is invalid; the type checker function must return `null` or an `Error` but returned a " + typeof m + ". You may have forgotten to pass an argument to the type checker creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and shape all require an argument)." + ), m instanceof Error && !(m.message in n)) { + n[m.message] = !0; + var g = p ? p() : ""; t( - "Failed " + l + " type: " + h.message + (g ?? "") + "Failed " + l + " type: " + m.message + (g ?? "") ); } } @@ -3952,9 +3958,9 @@ function Ld() { return null; } return Vr = function(l, c) { - var d = typeof Symbol == "function" && Symbol.iterator, p = "@@iterator"; - function h(y) { - var R = y && (d && y[d] || y[p]); + var p = typeof Symbol == "function" && Symbol.iterator, d = "@@iterator"; + function m(y) { + var R = y && (p && y[p] || y[d]); if (typeof R == "function") return R; } @@ -3986,7 +3992,7 @@ function Ld() { this.message = y, this.data = R && typeof R == "object" ? R : {}, this.stack = ""; } f.prototype = Error.prototype; - function m(y) { + function h(y) { if (process.env.NODE_ENV !== "production") var R = {}, L = 0; function F(W, X, Y, G, K, Z, dt) { @@ -4021,10 +4027,10 @@ function Ld() { } return null; } - return m(R); + return h(R); } function _() { - return m(i); + return h(i); } function C(y) { function R(L, F, V, W, X) { @@ -4042,7 +4048,7 @@ function Ld() { } return null; } - return m(R); + return h(R); } function S() { function y(R, L, F, V, W) { @@ -4053,7 +4059,7 @@ function Ld() { } return null; } - return m(y); + return h(y); } function b() { function y(R, L, F, V, W) { @@ -4064,7 +4070,7 @@ function Ld() { } return null; } - return m(y); + return h(y); } function I(y) { function R(L, F, V, W, X) { @@ -4074,7 +4080,7 @@ function Ld() { } return null; } - return m(R); + return h(R); } function z(y) { if (!Array.isArray(y)) @@ -4091,7 +4097,7 @@ function Ld() { }); return new f("Invalid " + W + " `" + X + "` of value `" + String(Y) + "` " + ("supplied to `" + V + "`, expected one of " + K + ".")); } - return m(R); + return h(R); } function H(y) { function R(L, F, V, W, X) { @@ -4108,7 +4114,7 @@ function Ld() { } return null; } - return m(R); + return h(R); } function O(y) { if (!Array.isArray(y)) @@ -4130,13 +4136,13 @@ function Ld() { var Nt = K.length > 0 ? ", expected one of type [" + K.join(", ") + "]" : ""; return new f("Invalid " + Y + " `" + G + "` supplied to " + ("`" + X + "`" + Nt + ".")); } - return m(F); + return h(F); } function $() { function y(R, L, F, V, W) { return J(R[L]) ? null : new f("Invalid " + V + " `" + W + "` supplied to " + ("`" + F + "`, expected a ReactNode.")); } - return m(y); + return h(y); } function k(y, R, L, F, V) { return new f( @@ -4158,7 +4164,7 @@ function Ld() { } return null; } - return m(R); + return h(R); } function D(y) { function R(L, F, V, W, X) { @@ -4181,7 +4187,7 @@ Valid keys: ` + JSON.stringify(Object.keys(y), null, " ") } return null; } - return m(R); + return h(R); } function J(y) { switch (typeof y) { @@ -4196,7 +4202,7 @@ Valid keys: ` + JSON.stringify(Object.keys(y), null, " ") return y.every(J); if (y === null || l(y)) return !0; - var R = h(y); + var R = m(y); if (R) { var L = R.call(y), F; if (R !== y.entries) { @@ -4266,8 +4272,8 @@ function Fd() { function n() { } return n.resetWarningCache = e, zr = function() { - function r(i, l, c, d, p, h) { - if (h !== t) { + function r(i, l, c, p, d, m) { + if (m !== t) { var w = new Error( "Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types" ); @@ -4361,29 +4367,29 @@ function qd() { if (ha) return lt; ha = 1; - var t = Symbol.for("react.element"), e = Symbol.for("react.portal"), n = Symbol.for("react.fragment"), r = Symbol.for("react.strict_mode"), o = Symbol.for("react.profiler"), a = Symbol.for("react.provider"), i = Symbol.for("react.context"), l = Symbol.for("react.server_context"), c = Symbol.for("react.forward_ref"), d = Symbol.for("react.suspense"), p = Symbol.for("react.suspense_list"), h = Symbol.for("react.memo"), w = Symbol.for("react.lazy"), g = Symbol.for("react.offscreen"), v; + var t = Symbol.for("react.element"), e = Symbol.for("react.portal"), n = Symbol.for("react.fragment"), r = Symbol.for("react.strict_mode"), o = Symbol.for("react.profiler"), a = Symbol.for("react.provider"), i = Symbol.for("react.context"), l = Symbol.for("react.server_context"), c = Symbol.for("react.forward_ref"), p = Symbol.for("react.suspense"), d = Symbol.for("react.suspense_list"), m = Symbol.for("react.memo"), w = Symbol.for("react.lazy"), g = Symbol.for("react.offscreen"), v; v = Symbol.for("react.module.reference"); - function f(m) { - if (typeof m == "object" && m !== null) { - var E = m.$$typeof; + function f(h) { + if (typeof h == "object" && h !== null) { + var E = h.$$typeof; switch (E) { case t: - switch (m = m.type, m) { + switch (h = h.type, h) { case n: case o: case r: - case d: case p: - return m; + case d: + return h; default: - switch (m = m && m.$$typeof, m) { + switch (h = h && h.$$typeof, h) { case l: case i: case c: case w: - case h: + case m: case a: - return m; + return h; default: return E; } @@ -4393,36 +4399,36 @@ function qd() { } } } - return lt.ContextConsumer = i, lt.ContextProvider = a, lt.Element = t, lt.ForwardRef = c, lt.Fragment = n, lt.Lazy = w, lt.Memo = h, lt.Portal = e, lt.Profiler = o, lt.StrictMode = r, lt.Suspense = d, lt.SuspenseList = p, lt.isAsyncMode = function() { + return lt.ContextConsumer = i, lt.ContextProvider = a, lt.Element = t, lt.ForwardRef = c, lt.Fragment = n, lt.Lazy = w, lt.Memo = m, lt.Portal = e, lt.Profiler = o, lt.StrictMode = r, lt.Suspense = p, lt.SuspenseList = d, lt.isAsyncMode = function() { return !1; }, lt.isConcurrentMode = function() { return !1; - }, lt.isContextConsumer = function(m) { - return f(m) === i; - }, lt.isContextProvider = function(m) { - return f(m) === a; - }, lt.isElement = function(m) { - return typeof m == "object" && m !== null && m.$$typeof === t; - }, lt.isForwardRef = function(m) { - return f(m) === c; - }, lt.isFragment = function(m) { - return f(m) === n; - }, lt.isLazy = function(m) { - return f(m) === w; - }, lt.isMemo = function(m) { - return f(m) === h; - }, lt.isPortal = function(m) { - return f(m) === e; - }, lt.isProfiler = function(m) { - return f(m) === o; - }, lt.isStrictMode = function(m) { - return f(m) === r; - }, lt.isSuspense = function(m) { - return f(m) === d; - }, lt.isSuspenseList = function(m) { - return f(m) === p; - }, lt.isValidElementType = function(m) { - return typeof m == "string" || typeof m == "function" || m === n || m === o || m === r || m === d || m === p || m === g || typeof m == "object" && m !== null && (m.$$typeof === w || m.$$typeof === h || m.$$typeof === a || m.$$typeof === i || m.$$typeof === c || m.$$typeof === v || m.getModuleId !== void 0); + }, lt.isContextConsumer = function(h) { + return f(h) === i; + }, lt.isContextProvider = function(h) { + return f(h) === a; + }, lt.isElement = function(h) { + return typeof h == "object" && h !== null && h.$$typeof === t; + }, lt.isForwardRef = function(h) { + return f(h) === c; + }, lt.isFragment = function(h) { + return f(h) === n; + }, lt.isLazy = function(h) { + return f(h) === w; + }, lt.isMemo = function(h) { + return f(h) === m; + }, lt.isPortal = function(h) { + return f(h) === e; + }, lt.isProfiler = function(h) { + return f(h) === o; + }, lt.isStrictMode = function(h) { + return f(h) === r; + }, lt.isSuspense = function(h) { + return f(h) === p; + }, lt.isSuspenseList = function(h) { + return f(h) === d; + }, lt.isValidElementType = function(h) { + return typeof h == "string" || typeof h == "function" || h === n || h === o || h === r || h === p || h === d || h === g || typeof h == "object" && h !== null && (h.$$typeof === w || h.$$typeof === m || h.$$typeof === a || h.$$typeof === i || h.$$typeof === c || h.$$typeof === v || h.getModuleId !== void 0); }, lt.typeOf = f, lt; } var ct = {}; @@ -4438,10 +4444,10 @@ var ct = {}; var ga; function Kd() { return ga || (ga = 1, process.env.NODE_ENV !== "production" && function() { - var t = Symbol.for("react.element"), e = Symbol.for("react.portal"), n = Symbol.for("react.fragment"), r = Symbol.for("react.strict_mode"), o = Symbol.for("react.profiler"), a = Symbol.for("react.provider"), i = Symbol.for("react.context"), l = Symbol.for("react.server_context"), c = Symbol.for("react.forward_ref"), d = Symbol.for("react.suspense"), p = Symbol.for("react.suspense_list"), h = Symbol.for("react.memo"), w = Symbol.for("react.lazy"), g = Symbol.for("react.offscreen"), v = !1, f = !1, m = !1, E = !1, _ = !1, C; + var t = Symbol.for("react.element"), e = Symbol.for("react.portal"), n = Symbol.for("react.fragment"), r = Symbol.for("react.strict_mode"), o = Symbol.for("react.profiler"), a = Symbol.for("react.provider"), i = Symbol.for("react.context"), l = Symbol.for("react.server_context"), c = Symbol.for("react.forward_ref"), p = Symbol.for("react.suspense"), d = Symbol.for("react.suspense_list"), m = Symbol.for("react.memo"), w = Symbol.for("react.lazy"), g = Symbol.for("react.offscreen"), v = !1, f = !1, h = !1, E = !1, _ = !1, C; C = Symbol.for("react.module.reference"); function S(j) { - return !!(typeof j == "string" || typeof j == "function" || j === n || j === o || _ || j === r || j === d || j === p || E || j === g || v || f || m || typeof j == "object" && j !== null && (j.$$typeof === w || j.$$typeof === h || j.$$typeof === a || j.$$typeof === i || j.$$typeof === c || // This needs to include all possible module reference object + return !!(typeof j == "string" || typeof j == "function" || j === n || j === o || _ || j === r || j === p || j === d || E || j === g || v || f || h || typeof j == "object" && j !== null && (j.$$typeof === w || j.$$typeof === m || j.$$typeof === a || j.$$typeof === i || j.$$typeof === c || // This needs to include all possible module reference object // types supported by any Flight configuration anywhere since // we don't know which Flight build this will end up being used // with. @@ -4457,8 +4463,8 @@ function Kd() { case n: case o: case r: - case d: case p: + case d: return Ft; default: var ce = Ft && Ft.$$typeof; @@ -4467,7 +4473,7 @@ function Kd() { case i: case c: case w: - case h: + case m: case a: return ce; default: @@ -4479,7 +4485,7 @@ function Kd() { } } } - var I = i, z = a, H = t, O = c, $ = n, k = w, B = h, D = e, J = o, q = r, U = d, tt = p, at = !1, rt = !1; + var I = i, z = a, H = t, O = c, $ = n, k = w, B = m, D = e, J = o, q = r, U = p, tt = d, at = !1, rt = !1; function y(j) { return at || (at = !0, console.warn("The ReactIs.isAsyncMode() alias has been deprecated, and will be removed in React 18+.")), !1; } @@ -4505,7 +4511,7 @@ function Kd() { return b(j) === w; } function G(j) { - return b(j) === h; + return b(j) === m; } function K(j) { return b(j) === e; @@ -4517,10 +4523,10 @@ function Kd() { return b(j) === r; } function A(j) { - return b(j) === d; + return b(j) === p; } function Nt(j) { - return b(j) === p; + return b(j) === d; } ct.ContextConsumer = I, ct.ContextProvider = z, ct.Element = H, ct.ForwardRef = O, ct.Fragment = $, ct.Lazy = k, ct.Memo = B, ct.Portal = D, ct.Profiler = J, ct.StrictMode = q, ct.Suspense = U, ct.SuspenseList = tt, ct.isAsyncMode = y, ct.isConcurrentMode = R, ct.isContextConsumer = L, ct.isContextProvider = F, ct.isElement = V, ct.isForwardRef = W, ct.isFragment = X, ct.isLazy = Y, ct.isMemo = G, ct.isPortal = K, ct.isProfiler = Z, ct.isStrictMode = dt, ct.isSuspense = A, ct.isSuspenseList = Nt, ct.isValidElementType = S, ct.typeOf = b; }()), ct; @@ -4611,14 +4617,14 @@ function ip(t, e) { if (process.env.NODE_ENV === "production") return () => null; const n = e ? P({}, e.propTypes) : null; - return (o) => (a, i, l, c, d, ...p) => { - const h = d || i, w = n == null ? void 0 : n[h]; + return (o) => (a, i, l, c, p, ...d) => { + const m = p || i, w = n == null ? void 0 : n[m]; if (w) { - const g = w(a, i, l, c, d, ...p); + const g = w(a, i, l, c, p, ...d); if (g) return g; } - return typeof a[i] < "u" && !a[o] ? new Error(`The prop \`${h}\` of \`${t}\` can only be used together with the \`${o}\` prop.`) : null; + return typeof a[i] < "u" && !a[o] ? new Error(`The prop \`${m}\` of \`${t}\` can only be used together with the \`${o}\` prop.`) : null; }; } function Wn(t, e) { @@ -4661,15 +4667,15 @@ function rs({ `)); }, [r, n, t]); const { - current: d + current: p } = M.useRef(e); M.useEffect(() => { - !o && d !== e && console.error([`MUI: A component is changing the default ${r} state of an uncontrolled ${n} after being initialized. To suppress this warning opt to use a controlled ${n}.`].join(` + !o && p !== e && console.error([`MUI: A component is changing the default ${r} state of an uncontrolled ${n} after being initialized. To suppress this warning opt to use a controlled ${n}.`].join(` `)); }, [JSON.stringify(e)]); } - const c = M.useCallback((d) => { - o || i(d); + const c = M.useCallback((p) => { + o || i(p); }, []); return [l, c]; } @@ -4896,25 +4902,25 @@ function Sp(t) { function c(w) { return `@media (max-width:${(typeof e[w] == "number" ? e[w] : w) - r / 100}${n})`; } - function d(w, g) { + function p(w, g) { const v = i.indexOf(g); return `@media (min-width:${typeof e[w] == "number" ? e[w] : w}${n}) and (max-width:${(v !== -1 && typeof e[i[v]] == "number" ? e[i[v]] : g) - r / 100}${n})`; } - function p(w) { - return i.indexOf(w) + 1 < i.length ? d(w, i[i.indexOf(w) + 1]) : l(w); + function d(w) { + return i.indexOf(w) + 1 < i.length ? p(w, i[i.indexOf(w) + 1]) : l(w); } - function h(w) { + function m(w) { const g = i.indexOf(w); - return g === 0 ? l(i[1]) : g === i.length - 1 ? c(i[g]) : d(w, i[i.indexOf(w) + 1]).replace("@media", "@media not all and"); + return g === 0 ? l(i[1]) : g === i.length - 1 ? c(i[g]) : p(w, i[i.indexOf(w) + 1]).replace("@media", "@media not all and"); } return P({ keys: i, values: a, up: l, down: c, - between: d, - only: p, - not: h, + between: p, + only: d, + not: m, unit: n }, o); } @@ -5001,10 +5007,10 @@ function yt(t) { } = t, a = (i) => { if (i[e] == null) return null; - const l = i[e], c = i.theme, d = ur(c, r) || {}; - return Qt(i, l, (h) => { - let w = qn(d, o, h); - return h === w && typeof h == "string" && (w = qn(d, o, `${e}${h === "default" ? "" : Wt(h)}`, h)), n === !1 ? w : { + const l = i[e], c = i.theme, p = ur(c, r) || {}; + return Qt(i, l, (m) => { + let w = qn(p, o, m); + return m === w && typeof m == "string" && (w = qn(p, o, `${e}${m === "default" ? "" : Wt(m)}`, m)), n === !1 ? w : { [n]: w }; }); @@ -5556,20 +5562,20 @@ function bu() { }; const { cssProperty: c = n, - themeKey: d, - transform: p, - style: h + themeKey: p, + transform: d, + style: m } = l; if (r == null) return null; - if (d === "typography" && r === "inherit") + if (p === "typography" && r === "inherit") return { [n]: r }; - const w = ur(o, d) || {}; - return h ? h(i) : Qt(i, r, (v) => { - let f = qn(w, p, v); - return v === f && typeof v == "string" && (f = qn(w, p, `${n}${v === "default" ? "" : Wt(v)}`, v)), c === !1 ? f : { + const w = ur(o, p) || {}; + return m ? m(i) : Qt(i, r, (v) => { + let f = qn(w, d, v); + return v === f && typeof v == "string" && (f = qn(w, d, `${n}${v === "default" ? "" : Wt(v)}`, v)), c === !1 ? f : { [c]: f }; }); @@ -5584,17 +5590,17 @@ function bu() { return null; const i = (r = a.unstable_sxConfig) != null ? r : Eo; function l(c) { - let d = c; + let p = c; if (typeof c == "function") - d = c(a); + p = c(a); else if (typeof c != "object") return c; - if (!d) + if (!p) return null; - const p = Rp(a.breakpoints), h = Object.keys(p); - let w = p; - return Object.keys(d).forEach((g) => { - const v = gu(d[g], a); + const d = Rp(a.breakpoints), m = Object.keys(d); + let w = d; + return Object.keys(p).forEach((g) => { + const v = gu(p[g], a); if (v != null) if (typeof v == "object") if (i[g]) @@ -5602,8 +5608,8 @@ function bu() { else { const f = Qt({ theme: a - }, v, (m) => ({ - [g]: m + }, v, (h) => ({ + [g]: h })); hu(f, v) ? w[g] = e({ sx: v, @@ -5612,7 +5618,7 @@ function bu() { } else w = un(w, t(g, v, a, i)); - }), _p(h, w); + }), _p(m, w); } return Array.isArray(o) ? o.map(l) : l(o); } @@ -5635,7 +5641,7 @@ function To(t = {}, ...e) { spacing: o, shape: a = {} } = t, i = kt(t, yu), l = Sp(n), c = jp(o); - let d = Zt({ + let p = Zt({ breakpoints: l, direction: "ltr", components: {}, @@ -5646,12 +5652,12 @@ function To(t = {}, ...e) { spacing: c, shape: P({}, Cp, a) }, i); - return d.applyStyles = vu, d = e.reduce((p, h) => Zt(p, h), d), d.unstable_sxConfig = P({}, Eo, i == null ? void 0 : i.unstable_sxConfig), d.unstable_sx = function(h) { + return p.applyStyles = vu, p = e.reduce((d, m) => Zt(d, m), p), p.unstable_sxConfig = P({}, Eo, i == null ? void 0 : i.unstable_sxConfig), p.unstable_sx = function(m) { return So({ - sx: h, + sx: m, theme: this }); - }, d; + }, p; } function xu(t) { return Object.keys(t).length === 0; @@ -5705,12 +5711,12 @@ function Hn(t, e) { } = o; let l = kt(o, Eu); return a.forEach((c) => { - let d = !0; - typeof c.props == "function" ? d = c.props(P({ + let p = !0; + typeof c.props == "function" ? p = c.props(P({ ownerState: n - }, r, n)) : Object.keys(c.props).forEach((p) => { - (n == null ? void 0 : n[p]) !== c.props[p] && r[p] !== c.props[p] && (d = !1); - }), d && (Array.isArray(l) || (l = [l]), l.push(typeof c.style == "function" ? c.style(P({ + }, r, n)) : Object.keys(c.props).forEach((d) => { + (n == null ? void 0 : n[d]) !== c.props[d] && r[d] !== c.props[d] && (p = !1); + }), p && (Array.isArray(l) || (l = [l]), l.push(typeof c.style == "function" ? c.style(P({ ownerState: n }, r, n)) : c.style)); }), l; @@ -5733,24 +5739,24 @@ function _u(t = {}) { Dl(i, (b) => b.filter((I) => !(I != null && I.__mui_systemSx))); const { name: c, - slot: d, - skipVariantsResolver: p, - skipSx: h, + slot: p, + skipVariantsResolver: d, + skipSx: m, // TODO v6: remove `lowercaseFirstLetter()` in the next major release // For more details: https://github.com/mui/material-ui/pull/37908 - overridesResolver: w = Ru(Ta(d)) - } = l, g = kt(l, Su), v = p !== void 0 ? p : ( + overridesResolver: w = Ru(Ta(p)) + } = l, g = kt(l, Su), v = d !== void 0 ? d : ( // TODO v6: remove `Root` in the next major release // For more details: https://github.com/mui/material-ui/pull/37908 - d && d !== "Root" && d !== "root" || !1 - ), f = h || !1; - let m; - process.env.NODE_ENV !== "production" && c && (m = `${c}-${Ta(d || "Root")}`); + p && p !== "Root" && p !== "root" || !1 + ), f = m || !1; + let h; + process.env.NODE_ENV !== "production" && c && (h = `${c}-${Ta(p || "Root")}`); let E = Gn; - d === "Root" || d === "root" ? E = r : d ? E = o : Cu(i) && (E = void 0); + p === "Root" || p === "root" ? E = r : p ? E = o : Cu(i) && (E = void 0); const _ = Al(i, P({ shouldForwardProp: E, - label: m + label: h }, g)), C = (b) => typeof b == "function" && b.__emotion_real !== b || he(b) ? (I) => Hn(b, P({}, I, { theme: Vn({ theme: I.theme, @@ -5793,7 +5799,7 @@ function _u(t = {}) { const $ = _(z, ...H); if (process.env.NODE_ENV !== "production") { let k; - c && (k = `${c}${Wt(d || "")}`), k === void 0 && (k = `Styled(${Qd(i)})`), $.displayName = k; + c && (k = `${c}${Wt(p || "")}`), k === void 0 && (k = `Styled(${Qd(i)})`), $.displayName = k; } return i.muiName && ($.muiName = i.muiName), $; }; @@ -5866,7 +5872,7 @@ function Au(t) { t = Ne(t); const { values: e - } = t, n = e[0], r = e[1] / 100, o = e[2] / 100, a = r * Math.min(o, 1 - o), i = (d, p = (d + n / 30) % 12) => o - a * Math.max(Math.min(p - 3, 9 - p, 1), -1); + } = t, n = e[0], r = e[1] / 100, o = e[2] / 100, a = r * Math.min(o, 1 - o), i = (p, d = (p + n / 30) % 12) => o - a * Math.max(Math.min(d - 3, 9 - d, 1), -1); let l = "rgb"; const c = [Math.round(i(0) * 255), Math.round(i(8) * 255), Math.round(i(4) * 255)]; return t.type === "hsla" && (l += "a", c.push(e[3])), yr({ @@ -6167,28 +6173,28 @@ function tw(t) { mode: e = "light", contrastThreshold: n = 3, tonalOffset: r = 0.2 - } = t, o = kt(t, Yu), a = t.primary || Wu(e), i = t.secondary || qu(e), l = t.error || Ku(e), c = t.info || Ju(e), d = t.success || Zu(e), p = t.warning || Qu(e); - function h(f) { - const m = Oa(f, Fr.text.primary) >= n ? Fr.text.primary : Ra.text.primary; + } = t, o = kt(t, Yu), a = t.primary || Wu(e), i = t.secondary || qu(e), l = t.error || Ku(e), c = t.info || Ju(e), p = t.success || Zu(e), d = t.warning || Qu(e); + function m(f) { + const h = Oa(f, Fr.text.primary) >= n ? Fr.text.primary : Ra.text.primary; if (process.env.NODE_ENV !== "production") { - const E = Oa(f, m); - E < 3 && console.error([`MUI: The contrast ratio of ${E}:1 for ${m} on ${f}`, "falls below the WCAG recommended absolute minimum contrast ratio of 3:1.", "https://www.w3.org/TR/2008/REC-WCAG20-20081211/#visual-audio-contrast-contrast"].join(` + const E = Oa(f, h); + E < 3 && console.error([`MUI: The contrast ratio of ${E}:1 for ${h} on ${f}`, "falls below the WCAG recommended absolute minimum contrast ratio of 3:1.", "https://www.w3.org/TR/2008/REC-WCAG20-20081211/#visual-audio-contrast-contrast"].join(` `)); } - return m; + return h; } const w = ({ color: f, - name: m, + name: h, mainShade: E = 500, lightShade: _ = 300, darkShade: C = 700 }) => { if (f = P({}, f), !f.main && f[E] && (f.main = f[E]), !f.hasOwnProperty("main")) - throw new Error(process.env.NODE_ENV !== "production" ? `MUI: The color${m ? ` (${m})` : ""} provided to augmentColor(color) is invalid. -The color object needs to have a \`main\` property or a \`${E}\` property.` : Ve(11, m ? ` (${m})` : "", E)); + throw new Error(process.env.NODE_ENV !== "production" ? `MUI: The color${h ? ` (${h})` : ""} provided to augmentColor(color) is invalid. +The color object needs to have a \`main\` property or a \`${E}\` property.` : Ve(11, h ? ` (${h})` : "", E)); if (typeof f.main != "string") - throw new Error(process.env.NODE_ENV !== "production" ? `MUI: The color${m ? ` (${m})` : ""} provided to augmentColor(color) is invalid. + throw new Error(process.env.NODE_ENV !== "production" ? `MUI: The color${h ? ` (${h})` : ""} provided to augmentColor(color) is invalid. \`color.main\` should be a string, but \`${JSON.stringify(f.main)}\` was provided instead. Did you intend to use one of the following approaches? @@ -6201,8 +6207,8 @@ const theme1 = createTheme({ palette: { const theme2 = createTheme({ palette: { primary: { main: green[500] }, -} });` : Ve(12, m ? ` (${m})` : "", JSON.stringify(f.main))); - return _a(f, "light", _, r), _a(f, "dark", C, r), f.contrastText || (f.contrastText = h(f.main)), f; +} });` : Ve(12, h ? ` (${h})` : "", JSON.stringify(f.main))); + return _a(f, "light", _, r), _a(f, "dark", C, r), f.contrastText || (f.contrastText = m(f.main)), f; }, g = { dark: Fr, light: Ra @@ -6233,7 +6239,7 @@ const theme2 = createTheme({ palette: { }), // The colors used to represent potentially dangerous actions or important messages. warning: w({ - color: p, + color: d, name: "warning" }), // The colors used to present information to the user that is neutral and not necessarily important. @@ -6243,7 +6249,7 @@ const theme2 = createTheme({ palette: { }), // The colors used to indicate the successful completion of an action that user triggered. success: w({ - color: d, + color: p, name: "success" }), // The grey colors. @@ -6252,7 +6258,7 @@ const theme2 = createTheme({ palette: { // the background and the text. contrastThreshold: n, // Takes a background color and returns the text color that maximizes the contrast. - getContrastText: h, + getContrastText: m, // Generate a rich color object. augmentColor: w, // Used by the functions below to shift a color's luminance by approximately @@ -6280,13 +6286,13 @@ function rw(t, e) { fontWeightBold: c = 700, // Tell MUI what's the font-size on the html element. // 16px is the default font-size used by browsers. - htmlFontSize: d = 16, + htmlFontSize: p = 16, // Apply the CSS properties to all the variants. - allVariants: p, - pxToRem: h + allVariants: d, + pxToRem: m } = n, w = kt(n, ew); - process.env.NODE_ENV !== "production" && (typeof o != "number" && console.error("MUI: `fontSize` is required to be a number."), typeof d != "number" && console.error("MUI: `htmlFontSize` is required to be a number.")); - const g = o / 14, v = h || ((E) => `${E / d * g}rem`), f = (E, _, C, S, b) => P({ + process.env.NODE_ENV !== "production" && (typeof o != "number" && console.error("MUI: `fontSize` is required to be a number."), typeof p != "number" && console.error("MUI: `htmlFontSize` is required to be a number.")); + const g = o / 14, v = m || ((E) => `${E / p * g}rem`), f = (E, _, C, S, b) => P({ fontFamily: r, fontWeight: E, fontSize: v(_), @@ -6294,7 +6300,7 @@ function rw(t, e) { lineHeight: C }, r === $a ? { letterSpacing: `${nw(S / _)}em` - } : {}, b, p), m = { + } : {}, b, d), h = { h1: f(a, 96, 1.167, -1.5), h2: f(a, 60, 1.2, -0.5), h3: f(i, 48, 1.167, 0), @@ -6318,7 +6324,7 @@ function rw(t, e) { } }; return Zt(P({ - htmlFontSize: d, + htmlFontSize: p, pxToRem: v, fontFamily: r, fontSize: o, @@ -6326,7 +6332,7 @@ function rw(t, e) { fontWeightRegular: i, fontWeightMedium: l, fontWeightBold: c - }, m), w, { + }, h), w, { clone: !1 // No need to clone deep }); @@ -6376,13 +6382,13 @@ function ww(t) { duration: i = n.standard, easing: l = e.easeInOut, delay: c = 0 - } = a, d = kt(a, cw); + } = a, p = kt(a, cw); if (process.env.NODE_ENV !== "production") { - const p = (w) => typeof w == "string", h = (w) => !isNaN(parseFloat(w)); - !p(o) && !Array.isArray(o) && console.error('MUI: Argument "props" must be a string or Array.'), !h(i) && !p(i) && console.error(`MUI: Argument "duration" must be a number or a string but found ${i}.`), p(l) || console.error('MUI: Argument "easing" must be a string.'), !h(c) && !p(c) && console.error('MUI: Argument "delay" must be a number or a string.'), typeof a != "object" && console.error(["MUI: Secong argument of transition.create must be an object.", "Arguments should be either `create('prop1', options)` or `create(['prop1', 'prop2'], options)`"].join(` -`)), Object.keys(d).length !== 0 && console.error(`MUI: Unrecognized argument(s) [${Object.keys(d).join(",")}].`); + const d = (w) => typeof w == "string", m = (w) => !isNaN(parseFloat(w)); + !d(o) && !Array.isArray(o) && console.error('MUI: Argument "props" must be a string or Array.'), !m(i) && !d(i) && console.error(`MUI: Argument "duration" must be a number or a string but found ${i}.`), d(l) || console.error('MUI: Argument "easing" must be a string.'), !m(c) && !d(c) && console.error('MUI: Argument "delay" must be a number or a string.'), typeof a != "object" && console.error(["MUI: Secong argument of transition.create must be an object.", "Arguments should be either `create('prop1', options)` or `create(['prop1', 'prop2'], options)`"].join(` +`)), Object.keys(p).length !== 0 && console.error(`MUI: Unrecognized argument(s) [${Object.keys(p).join(",")}].`); } - return (Array.isArray(o) ? o : [o]).map((p) => `${p} ${typeof i == "string" ? i : Ia(i)} ${l} ${typeof c == "string" ? c : Ia(c)}`).join(","); + return (Array.isArray(o) ? o : [o]).map((d) => `${d} ${typeof i == "string" ? i : Ia(i)} ${l} ${typeof c == "string" ? c : Ia(c)}`).join(","); } }, t, { easing: e, @@ -6409,7 +6415,7 @@ function gw(t = {}, ...e) { if (t.vars) throw new Error(process.env.NODE_ENV !== "production" ? "MUI: `vars` is a private field used for CSS variables support.\nPlease use another name." : Ve(18)); const l = tw(r), c = To(t); - let d = Zt(c, { + let p = Zt(c, { mixins: Bu(c.breakpoints, n), palette: l, // Don't use [...shadows] until you've verified its transpiled code is not invoking the iterator protocol. @@ -6418,17 +6424,17 @@ function gw(t = {}, ...e) { transitions: ww(o), zIndex: P({}, mw) }); - if (d = Zt(d, i), d = e.reduce((p, h) => Zt(p, h), d), process.env.NODE_ENV !== "production") { - const p = ["active", "checked", "completed", "disabled", "error", "expanded", "focused", "focusVisible", "required", "selected"], h = (w, g) => { + if (p = Zt(p, i), p = e.reduce((d, m) => Zt(d, m), p), process.env.NODE_ENV !== "production") { + const d = ["active", "checked", "completed", "disabled", "error", "expanded", "focused", "focusVisible", "required", "selected"], m = (w, g) => { let v; for (v in w) { const f = w[v]; - if (p.indexOf(v) !== -1 && Object.keys(f).length > 0) { + if (d.indexOf(v) !== -1 && Object.keys(f).length > 0) { if (process.env.NODE_ENV !== "production") { - const m = pr("", v); - console.error([`MUI: The \`${g}\` component increases the CSS specificity of the \`${v}\` internal state.`, "You can not override it like this: ", JSON.stringify(w, null, 2), "", `Instead, you need to use the '&.${m}' syntax:`, JSON.stringify({ + const h = pr("", v); + console.error([`MUI: The \`${g}\` component increases the CSS specificity of the \`${v}\` internal state.`, "You can not override it like this: ", JSON.stringify(w, null, 2), "", `Instead, you need to use the '&.${h}' syntax:`, JSON.stringify({ root: { - [`&.${m}`]: f + [`&.${h}`]: f } }, null, 2), "", "https://mui.com/r/state-classes-guide"].join(` `)); @@ -6437,17 +6443,17 @@ function gw(t = {}, ...e) { } } }; - Object.keys(d.components).forEach((w) => { - const g = d.components[w].styleOverrides; - g && w.indexOf("Mui") === 0 && h(g, w); + Object.keys(p.components).forEach((w) => { + const g = p.components[w].styleOverrides; + g && w.indexOf("Mui") === 0 && m(g, w); }); } - return d.unstable_sxConfig = P({}, Eo, i == null ? void 0 : i.unstable_sxConfig), d.unstable_sx = function(h) { + return p.unstable_sxConfig = P({}, Eo, i == null ? void 0 : i.unstable_sxConfig), p.unstable_sx = function(m) { return So({ - sx: h, + sx: m, theme: this }); - }, d; + }, p; } const bw = gw(), Oo = bw, Ro = "$$material"; function _o({ @@ -6492,7 +6498,7 @@ const Nw = ["children", "className", "color", "component", "fontSize", "htmlColo theme: t, ownerState: e }) => { - var n, r, o, a, i, l, c, d, p, h, w, g, v; + var n, r, o, a, i, l, c, p, d, m, w, g, v; return { userSelect: "none", width: "1em", @@ -6509,10 +6515,10 @@ const Nw = ["children", "className", "color", "component", "fontSize", "htmlColo inherit: "inherit", small: ((a = t.typography) == null || (i = a.pxToRem) == null ? void 0 : i.call(a, 20)) || "1.25rem", medium: ((l = t.typography) == null || (c = l.pxToRem) == null ? void 0 : c.call(l, 24)) || "1.5rem", - large: ((d = t.typography) == null || (p = d.pxToRem) == null ? void 0 : p.call(d, 35)) || "2.1875rem" + large: ((p = t.typography) == null || (d = p.pxToRem) == null ? void 0 : d.call(p, 35)) || "2.1875rem" }[e.fontSize], // TODO v5 deprecate, v6 remove for sx - color: (h = (w = (t.vars || t).palette) == null || (w = w[e.color]) == null ? void 0 : w.main) != null ? h : { + color: (m = (w = (t.vars || t).palette) == null || (w = w[e.color]) == null ? void 0 : w.main) != null ? m : { action: (g = (t.vars || t).palette) == null || (g = g.action) == null ? void 0 : g.active, disabled: (v = (t.vars || t).palette) == null || (v = v.action) == null ? void 0 : v.disabled, inherit: void 0 @@ -6528,33 +6534,33 @@ const Nw = ["children", "className", "color", "component", "fontSize", "htmlColo color: i = "inherit", component: l = "svg", fontSize: c = "medium", - htmlColor: d, - inheritViewBox: p = !1, - titleAccess: h, + htmlColor: p, + inheritViewBox: d = !1, + titleAccess: m, viewBox: w = "0 0 24 24" } = r, g = kt(r, Nw), v = /* @__PURE__ */ M.isValidElement(o) && o.type === "svg", f = P({}, r, { color: i, component: l, fontSize: c, instanceFontSize: e.fontSize, - inheritViewBox: p, + inheritViewBox: d, viewBox: w, hasSvgAsChild: v - }), m = {}; - p || (m.viewBox = w); + }), h = {}; + d || (h.viewBox = w); const E = kw(f); return /* @__PURE__ */ N(Ew, P({ as: l, className: be(E.root, a), focusable: "false", - color: d, - "aria-hidden": h ? void 0 : !0, - role: h ? "img" : void 0, + color: p, + "aria-hidden": m ? void 0 : !0, + role: m ? "img" : void 0, ref: n - }, m, g, v && o.props, { + }, h, g, v && o.props, { ownerState: f, - children: [v ? o.props.children : o, h ? /* @__PURE__ */ s("title", { - children: h + children: [v ? o.props.children : o, m ? /* @__PURE__ */ s("title", { + children: m }) : null] })); }); @@ -6743,10 +6749,10 @@ function jw(t) { internalRef: void 0 }; } - const i = Dw(P({}, o, r)), l = Da(r), c = Da(o), d = e(i), p = be(d == null ? void 0 : d.className, n == null ? void 0 : n.className, a, o == null ? void 0 : o.className, r == null ? void 0 : r.className), h = P({}, d == null ? void 0 : d.style, n == null ? void 0 : n.style, o == null ? void 0 : o.style, r == null ? void 0 : r.style), w = P({}, d, n, c, l); - return p.length > 0 && (w.className = p), Object.keys(h).length > 0 && (w.style = h), { + const i = Dw(P({}, o, r)), l = Da(r), c = Da(o), p = e(i), d = be(p == null ? void 0 : p.className, n == null ? void 0 : n.className, a, o == null ? void 0 : o.className, r == null ? void 0 : r.className), m = P({}, p == null ? void 0 : p.style, n == null ? void 0 : n.style, o == null ? void 0 : o.style, r == null ? void 0 : r.style), w = P({}, p, n, c, l); + return d.length > 0 && (w.className = d), Object.keys(m).length > 0 && (w.style = m), { props: w, - internalRef: d.ref + internalRef: p.ref }; } const Vw = ["elementType", "externalSlotProps", "ownerState", "skipResolvingSlotProps"]; @@ -6759,12 +6765,12 @@ function zw(t) { skipResolvingSlotProps: a = !1 } = t, i = kt(t, Vw), l = a ? {} : Bw(r, o), { props: c, - internalRef: d + internalRef: p } = jw(P({}, i, { externalSlotProps: l - })), p = xe(d, l == null ? void 0 : l.ref, (e = t.additionalProps) == null ? void 0 : e.ref); + })), d = xe(p, l == null ? void 0 : l.ref, (e = t.additionalProps) == null ? void 0 : e.ref); return ln(n, P({}, c, { - ref: p + ref: d }), o); } const gs = "base"; @@ -6802,10 +6808,10 @@ const Kn = /* @__PURE__ */ M.forwardRef(function(e, n) { }; }, [n, i, a]), a) { if (/* @__PURE__ */ M.isValidElement(r)) { - const d = { + const p = { ref: c }; - return /* @__PURE__ */ M.cloneElement(r, d); + return /* @__PURE__ */ M.cloneElement(r, p); } return /* @__PURE__ */ s(M.Fragment, { children: r @@ -6898,8 +6904,8 @@ function of(t) { }; return Object.assign(e.elements.popper.style, n.popper), e.styles = n, e.elements.arrow && Object.assign(e.elements.arrow.style, n.arrow), function() { Object.keys(e.elements).forEach(function(r) { - var o = e.elements[r], a = e.attributes[r] || {}, i = Object.keys(e.styles.hasOwnProperty(r) ? e.styles[r] : n[r]), l = i.reduce(function(c, d) { - return c[d] = "", c; + var o = e.elements[r], a = e.attributes[r] || {}, i = Object.keys(e.styles.hasOwnProperty(r) ? e.styles[r] : n[r]), l = i.reduce(function(c, p) { + return c[p] = "", c; }, {}); !jt(o) || !qt(o) || (Object.assign(o.style, l), Object.keys(a).forEach(function(c) { o.removeAttribute(c); @@ -6932,16 +6938,16 @@ function Ue(t, e, n) { e === void 0 && (e = !1), n === void 0 && (n = !1); var r = t.getBoundingClientRect(), o = 1, a = 1; e && jt(t) && (o = t.offsetWidth > 0 && Fe(r.width) / t.offsetWidth || 1, a = t.offsetHeight > 0 && Fe(r.height) / t.offsetHeight || 1); - var i = ke(t) ? Mt(t) : window, l = i.visualViewport, c = !xs() && n, d = (r.left + (c && l ? l.offsetLeft : 0)) / o, p = (r.top + (c && l ? l.offsetTop : 0)) / a, h = r.width / o, w = r.height / a; + var i = ke(t) ? Mt(t) : window, l = i.visualViewport, c = !xs() && n, p = (r.left + (c && l ? l.offsetLeft : 0)) / o, d = (r.top + (c && l ? l.offsetTop : 0)) / a, m = r.width / o, w = r.height / a; return { - width: h, + width: m, height: w, - top: p, - right: d + h, - bottom: p + w, - left: d, - x: d, - y: p + top: d, + right: p + m, + bottom: d + w, + left: p, + x: p, + y: d }; } function Ao(t) { @@ -7048,9 +7054,9 @@ var df = function(e, n) { })) : e, Es(typeof e != "number" ? e : Ss(e, _n)); }; function pf(t) { - var e, n = t.state, r = t.name, o = t.options, a = n.elements.arrow, i = n.modifiersData.popperOffsets, l = Yt(n.placement), c = Mo(l), d = [Ot, zt].indexOf(l) >= 0, p = d ? "height" : "width"; + var e, n = t.state, r = t.name, o = t.options, a = n.elements.arrow, i = n.modifiersData.popperOffsets, l = Yt(n.placement), c = Mo(l), p = [Ot, zt].indexOf(l) >= 0, d = p ? "height" : "width"; if (!(!a || !i)) { - var h = df(o.padding, n), w = Ao(a), g = c === "y" ? Ct : Ot, v = c === "y" ? Vt : zt, f = n.rects.reference[p] + n.rects.reference[c] - i[c] - n.rects.popper[p], m = i[c] - n.rects.reference[c], E = Pn(a), _ = E ? c === "y" ? E.clientHeight || 0 : E.clientWidth || 0 : 0, C = f / 2 - m / 2, S = h[g], b = _ - w[p] - h[v], I = _ / 2 - w[p] / 2 + C, z = wn(S, I, b), H = c; + var m = df(o.padding, n), w = Ao(a), g = c === "y" ? Ct : Ot, v = c === "y" ? Vt : zt, f = n.rects.reference[d] + n.rects.reference[c] - i[c] - n.rects.popper[d], h = i[c] - n.rects.reference[c], E = Pn(a), _ = E ? c === "y" ? E.clientHeight || 0 : E.clientWidth || 0 : 0, C = f / 2 - h / 2, S = m[g], b = _ - w[d] - m[v], I = _ / 2 - w[d] / 2 + C, z = wn(S, I, b), H = c; n.modifiersData[r] = (e = {}, e[H] = z, e.centerOffset = z - I, e); } } @@ -7084,20 +7090,20 @@ function mf(t, e) { }; } function Va(t) { - var e, n = t.popper, r = t.popperRect, o = t.placement, a = t.variation, i = t.offsets, l = t.position, c = t.gpuAcceleration, d = t.adaptive, p = t.roundOffsets, h = t.isFixed, w = i.x, g = w === void 0 ? 0 : w, v = i.y, f = v === void 0 ? 0 : v, m = typeof p == "function" ? p({ + var e, n = t.popper, r = t.popperRect, o = t.placement, a = t.variation, i = t.offsets, l = t.position, c = t.gpuAcceleration, p = t.adaptive, d = t.roundOffsets, m = t.isFixed, w = i.x, g = w === void 0 ? 0 : w, v = i.y, f = v === void 0 ? 0 : v, h = typeof d == "function" ? d({ x: g, y: f }) : { x: g, y: f }; - g = m.x, f = m.y; + g = h.x, f = h.y; var E = i.hasOwnProperty("x"), _ = i.hasOwnProperty("y"), C = Ot, S = Ct, b = window; - if (d) { + if (p) { var I = Pn(n), z = "clientHeight", H = "clientWidth"; if (I === Mt(n) && (I = le(n), te(I).position !== "static" && l === "absolute" && (z = "scrollHeight", H = "scrollWidth")), I = I, o === Ct || (o === Ot || o === zt) && a === Nn) { S = Vt; - var O = h && I === b && b.visualViewport ? b.visualViewport.height : ( + var O = m && I === b && b.visualViewport ? b.visualViewport.height : ( // $FlowFixMe[prop-missing] I[z] ); @@ -7105,7 +7111,7 @@ function Va(t) { } if (o === Ot || (o === Ct || o === Vt) && a === Nn) { C = zt; - var $ = h && I === b && b.visualViewport ? b.visualViewport.width : ( + var $ = m && I === b && b.visualViewport ? b.visualViewport.width : ( // $FlowFixMe[prop-missing] I[H] ); @@ -7114,7 +7120,7 @@ function Va(t) { } var k = Object.assign({ position: l - }, d && ff), B = p === !0 ? mf({ + }, p && ff), B = d === !0 ? mf({ x: g, y: f }, Mt(n)) : { @@ -7128,7 +7134,7 @@ function Va(t) { return Object.assign({}, k, (e = {}, e[S] = _ ? f + "px" : "", e[C] = E ? g + "px" : "", e.transform = "", e)); } function hf(t) { - var e = t.state, n = t.options, r = n.gpuAcceleration, o = r === void 0 ? !0 : r, a = n.adaptive, i = a === void 0 ? !0 : a, l = n.roundOffsets, c = l === void 0 ? !0 : l, d = { + var e = t.state, n = t.options, r = n.gpuAcceleration, o = r === void 0 ? !0 : r, a = n.adaptive, i = a === void 0 ? !0 : a, l = n.roundOffsets, c = l === void 0 ? !0 : l, p = { placement: Yt(e.placement), variation: Ge(e.placement), popper: e.elements.popper, @@ -7136,12 +7142,12 @@ function hf(t) { gpuAcceleration: o, isFixed: e.options.strategy === "fixed" }; - e.modifiersData.popperOffsets != null && (e.styles.popper = Object.assign({}, e.styles.popper, Va(Object.assign({}, d, { + e.modifiersData.popperOffsets != null && (e.styles.popper = Object.assign({}, e.styles.popper, Va(Object.assign({}, p, { offsets: e.modifiersData.popperOffsets, position: e.options.strategy, adaptive: i, roundOffsets: c - })))), e.modifiersData.arrow != null && (e.styles.arrow = Object.assign({}, e.styles.arrow, Va(Object.assign({}, d, { + })))), e.modifiersData.arrow != null && (e.styles.arrow = Object.assign({}, e.styles.arrow, Va(Object.assign({}, p, { offsets: e.modifiersData.arrow, position: "absolute", adaptive: !1, @@ -7161,12 +7167,12 @@ var zn = { passive: !0 }; function bf(t) { - var e = t.state, n = t.instance, r = t.options, o = r.scroll, a = o === void 0 ? !0 : o, i = r.resize, l = i === void 0 ? !0 : i, c = Mt(e.elements.popper), d = [].concat(e.scrollParents.reference, e.scrollParents.popper); - return a && d.forEach(function(p) { - p.addEventListener("scroll", n.update, zn); + var e = t.state, n = t.instance, r = t.options, o = r.scroll, a = o === void 0 ? !0 : o, i = r.resize, l = i === void 0 ? !0 : i, c = Mt(e.elements.popper), p = [].concat(e.scrollParents.reference, e.scrollParents.popper); + return a && p.forEach(function(d) { + d.addEventListener("scroll", n.update, zn); }), l && c.addEventListener("resize", n.update, zn), function() { - a && d.forEach(function(p) { - p.removeEventListener("scroll", n.update, zn); + a && p.forEach(function(d) { + d.removeEventListener("scroll", n.update, zn); }), l && c.removeEventListener("resize", n.update, zn); }; } @@ -7213,8 +7219,8 @@ function Nf(t, e) { var n = Mt(t), r = le(t), o = n.visualViewport, a = r.clientWidth, i = r.clientHeight, l = 0, c = 0; if (o) { a = o.width, i = o.height; - var d = xs(); - (d || !d && e === "fixed") && (l = o.offsetLeft, c = o.offsetTop); + var p = xs(); + (p || !p && e === "fixed") && (l = o.offsetLeft, c = o.offsetTop); } return { width: a, @@ -7270,9 +7276,9 @@ function Sf(t) { }) : []; } function Tf(t, e, n, r) { - var o = e === "clippingParents" ? Sf(t) : [].concat(e), a = [].concat(o, [n]), i = a[0], l = a.reduce(function(c, d) { - var p = La(t, d, r); - return c.top = ve(p.top, c.top), c.right = Jn(p.right, c.right), c.bottom = Jn(p.bottom, c.bottom), c.left = ve(p.left, c.left), c; + var o = e === "clippingParents" ? Sf(t) : [].concat(e), a = [].concat(o, [n]), i = a[0], l = a.reduce(function(c, p) { + var d = La(t, p, r); + return c.top = ve(d.top, c.top), c.right = Jn(d.right, c.right), c.bottom = Jn(d.bottom, c.bottom), c.left = ve(d.left, c.left), c; }, La(t, i, r)); return l.width = l.right - l.left, l.height = l.bottom - l.top, l.x = l.left, l.y = l.top, l; } @@ -7309,15 +7315,15 @@ function Cs(t) { y: e.y }; } - var d = o ? Mo(o) : null; - if (d != null) { - var p = d === "y" ? "height" : "width"; + var p = o ? Mo(o) : null; + if (p != null) { + var d = p === "y" ? "height" : "width"; switch (a) { case Le: - c[d] = c[d] - (e[p] / 2 - n[p] / 2); + c[p] = c[p] - (e[d] / 2 - n[d] / 2); break; case Nn: - c[d] = c[d] + (e[p] / 2 - n[p] / 2); + c[p] = c[p] + (e[d] / 2 - n[d] / 2); break; } } @@ -7325,7 +7331,7 @@ function Cs(t) { } function kn(t, e) { e === void 0 && (e = {}); - var n = e, r = n.placement, o = r === void 0 ? t.placement : r, a = n.strategy, i = a === void 0 ? t.strategy : a, l = n.boundary, c = l === void 0 ? Hw : l, d = n.rootBoundary, p = d === void 0 ? vs : d, h = n.elementContext, w = h === void 0 ? rn : h, g = n.altBoundary, v = g === void 0 ? !1 : g, f = n.padding, m = f === void 0 ? 0 : f, E = Es(typeof m != "number" ? m : Ss(m, _n)), _ = w === rn ? Xw : rn, C = t.rects.popper, S = t.elements[v ? _ : w], b = Tf(ke(S) ? S : S.contextElement || le(t.elements.popper), c, p, i), I = Ue(t.elements.reference), z = Cs({ + var n = e, r = n.placement, o = r === void 0 ? t.placement : r, a = n.strategy, i = a === void 0 ? t.strategy : a, l = n.boundary, c = l === void 0 ? Hw : l, p = n.rootBoundary, d = p === void 0 ? vs : p, m = n.elementContext, w = m === void 0 ? rn : m, g = n.altBoundary, v = g === void 0 ? !1 : g, f = n.padding, h = f === void 0 ? 0 : f, E = Es(typeof h != "number" ? h : Ss(h, _n)), _ = w === rn ? Xw : rn, C = t.rects.popper, S = t.elements[v ? _ : w], b = Tf(ke(S) ? S : S.contextElement || le(t.elements.popper), c, d, i), I = Ue(t.elements.reference), z = Cs({ reference: I, element: C, strategy: "absolute", @@ -7347,12 +7353,12 @@ function kn(t, e) { } function Cf(t, e) { e === void 0 && (e = {}); - var n = e, r = n.placement, o = n.boundary, a = n.rootBoundary, i = n.padding, l = n.flipVariations, c = n.allowedAutoPlacements, d = c === void 0 ? ys : c, p = Ge(r), h = p ? l ? Ba : Ba.filter(function(v) { - return Ge(v) === p; - }) : _n, w = h.filter(function(v) { - return d.indexOf(v) >= 0; + var n = e, r = n.placement, o = n.boundary, a = n.rootBoundary, i = n.padding, l = n.flipVariations, c = n.allowedAutoPlacements, p = c === void 0 ? ys : c, d = Ge(r), m = d ? l ? Ba : Ba.filter(function(v) { + return Ge(v) === d; + }) : _n, w = m.filter(function(v) { + return p.indexOf(v) >= 0; }); - w.length === 0 && (w = h); + w.length === 0 && (w = m); var g = w.reduce(function(v, f) { return v[f] = kn(t, { placement: f, @@ -7374,22 +7380,22 @@ function Of(t) { function Rf(t) { var e = t.state, n = t.options, r = t.name; if (!e.modifiersData[r]._skip) { - for (var o = n.mainAxis, a = o === void 0 ? !0 : o, i = n.altAxis, l = i === void 0 ? !0 : i, c = n.fallbackPlacements, d = n.padding, p = n.boundary, h = n.rootBoundary, w = n.altBoundary, g = n.flipVariations, v = g === void 0 ? !0 : g, f = n.allowedAutoPlacements, m = e.options.placement, E = Yt(m), _ = E === m, C = c || (_ || !v ? [Xn(m)] : Of(m)), S = [m].concat(C).reduce(function(V, W) { + for (var o = n.mainAxis, a = o === void 0 ? !0 : o, i = n.altAxis, l = i === void 0 ? !0 : i, c = n.fallbackPlacements, p = n.padding, d = n.boundary, m = n.rootBoundary, w = n.altBoundary, g = n.flipVariations, v = g === void 0 ? !0 : g, f = n.allowedAutoPlacements, h = e.options.placement, E = Yt(h), _ = E === h, C = c || (_ || !v ? [Xn(h)] : Of(h)), S = [h].concat(C).reduce(function(V, W) { return V.concat(Yt(W) === $o ? Cf(e, { placement: W, - boundary: p, - rootBoundary: h, - padding: d, + boundary: d, + rootBoundary: m, + padding: p, flipVariations: v, allowedAutoPlacements: f }) : W); }, []), b = e.rects.reference, I = e.rects.popper, z = /* @__PURE__ */ new Map(), H = !0, O = S[0], $ = 0; $ < S.length; $++) { var k = S[$], B = Yt(k), D = Ge(k) === Le, J = [Ct, Vt].indexOf(B) >= 0, q = J ? "width" : "height", U = kn(e, { placement: k, - boundary: p, - rootBoundary: h, + boundary: d, + rootBoundary: m, altBoundary: w, - padding: d + padding: p }), tt = J ? D ? zt : Ot : D ? Vt : Ct; b[q] > I[q] && (tt = Xn(tt)); var at = Xn(tt), rt = []; @@ -7451,15 +7457,15 @@ function Pf(t) { elementContext: "reference" }), l = kn(e, { altBoundary: !0 - }), c = Fa(i, r), d = Fa(l, o, a), p = Ua(c), h = Ua(d); + }), c = Fa(i, r), p = Fa(l, o, a), d = Ua(c), m = Ua(p); e.modifiersData[n] = { referenceClippingOffsets: c, - popperEscapeOffsets: d, - isReferenceHidden: p, - hasPopperEscaped: h + popperEscapeOffsets: p, + isReferenceHidden: d, + hasPopperEscaped: m }, e.attributes.popper = Object.assign({}, e.attributes.popper, { - "data-popper-reference-hidden": p, - "data-popper-escaped": h + "data-popper-reference-hidden": d, + "data-popper-escaped": m }); } const $f = { @@ -7482,10 +7488,10 @@ function If(t, e, n) { }; } function Af(t) { - var e = t.state, n = t.options, r = t.name, o = n.offset, a = o === void 0 ? [0, 0] : o, i = ys.reduce(function(p, h) { - return p[h] = If(h, e.rects, a), p; - }, {}), l = i[e.placement], c = l.x, d = l.y; - e.modifiersData.popperOffsets != null && (e.modifiersData.popperOffsets.x += c, e.modifiersData.popperOffsets.y += d), e.modifiersData[r] = i; + var e = t.state, n = t.options, r = t.name, o = n.offset, a = o === void 0 ? [0, 0] : o, i = ys.reduce(function(d, m) { + return d[m] = If(m, e.rects, a), d; + }, {}), l = i[e.placement], c = l.x, p = l.y; + e.modifiersData.popperOffsets != null && (e.modifiersData.popperOffsets.x += c, e.modifiersData.popperOffsets.y += p), e.modifiersData[r] = i; } const Mf = { name: "offset", @@ -7514,11 +7520,11 @@ function jf(t) { return t === "x" ? "y" : "x"; } function Vf(t) { - var e = t.state, n = t.options, r = t.name, o = n.mainAxis, a = o === void 0 ? !0 : o, i = n.altAxis, l = i === void 0 ? !1 : i, c = n.boundary, d = n.rootBoundary, p = n.altBoundary, h = n.padding, w = n.tether, g = w === void 0 ? !0 : w, v = n.tetherOffset, f = v === void 0 ? 0 : v, m = kn(e, { + var e = t.state, n = t.options, r = t.name, o = n.mainAxis, a = o === void 0 ? !0 : o, i = n.altAxis, l = i === void 0 ? !1 : i, c = n.boundary, p = n.rootBoundary, d = n.altBoundary, m = n.padding, w = n.tether, g = w === void 0 ? !0 : w, v = n.tetherOffset, f = v === void 0 ? 0 : v, h = kn(e, { boundary: c, - rootBoundary: d, - padding: h, - altBoundary: p + rootBoundary: p, + padding: m, + altBoundary: d }), E = Yt(e.placement), _ = Ge(e.placement), C = !_, S = Mo(E), b = jf(S), I = e.modifiersData.popperOffsets, z = e.rects.reference, H = e.rects.popper, O = typeof f == "function" ? f(Object.assign({}, e.rects, { placement: e.placement })) : f, $ = typeof O == "number" ? { @@ -7533,14 +7539,14 @@ function Vf(t) { }; if (I) { if (a) { - var D, J = S === "y" ? Ct : Ot, q = S === "y" ? Vt : zt, U = S === "y" ? "height" : "width", tt = I[S], at = tt + m[J], rt = tt - m[q], y = g ? -H[U] / 2 : 0, R = _ === Le ? z[U] : H[U], L = _ === Le ? -H[U] : -z[U], F = e.elements.arrow, V = g && F ? Ao(F) : { + var D, J = S === "y" ? Ct : Ot, q = S === "y" ? Vt : zt, U = S === "y" ? "height" : "width", tt = I[S], at = tt + h[J], rt = tt - h[q], y = g ? -H[U] / 2 : 0, R = _ === Le ? z[U] : H[U], L = _ === Le ? -H[U] : -z[U], F = e.elements.arrow, V = g && F ? Ao(F) : { width: 0, height: 0 }, W = e.modifiersData["arrow#persistent"] ? e.modifiersData["arrow#persistent"].padding : ks(), X = W[J], Y = W[q], G = wn(0, z[U], V[U]), K = C ? z[U] / 2 - y - G - X - $.mainAxis : R - G - X - $.mainAxis, Z = C ? -z[U] / 2 + y + G + Y + $.mainAxis : L + G + Y + $.mainAxis, dt = e.elements.arrow && Pn(e.elements.arrow), A = dt ? S === "y" ? dt.clientTop || 0 : dt.clientLeft || 0 : 0, Nt = (D = k == null ? void 0 : k[S]) != null ? D : 0, j = tt + K - Nt - A, xt = tt + Z - Nt, Ft = wn(g ? Jn(at, j) : at, tt, g ? ve(rt, xt) : rt); I[S] = Ft, B[S] = Ft - tt; } if (l) { - var ce, St = S === "x" ? Ct : Ot, In = S === "x" ? Vt : zt, Ut = I[b], Ee = b === "y" ? "height" : "width", de = Ut + m[St], Se = Ut - m[In], Te = [Ct, Ot].indexOf(E) !== -1, Ce = (ce = k == null ? void 0 : k[b]) != null ? ce : 0, pe = Te ? de : Ut - z[Ee] - H[Ee] - Ce + $.altAxis, qe = Te ? Ut + z[Ee] + H[Ee] - Ce - $.altAxis : Se, An = g && Te ? cf(pe, Ut, qe) : wn(g ? pe : de, Ut, g ? qe : Se); + var ce, St = S === "x" ? Ct : Ot, In = S === "x" ? Vt : zt, Ut = I[b], Ee = b === "y" ? "height" : "width", de = Ut + h[St], Se = Ut - h[In], Te = [Ct, Ot].indexOf(E) !== -1, Ce = (ce = k == null ? void 0 : k[b]) != null ? ce : 0, pe = Te ? de : Ut - z[Ee] - H[Ee] - Ce + $.altAxis, qe = Te ? Ut + z[Ee] + H[Ee] - Ce - $.altAxis : Se, An = g && Te ? cf(pe, Ut, qe) : wn(g ? pe : de, Ut, g ? qe : Se); I[b] = An, B[b] = An - Ut; } e.modifiersData[r] = B; @@ -7647,9 +7653,9 @@ function Ha() { function qf(t) { t === void 0 && (t = {}); var e = t, n = e.defaultModifiers, r = n === void 0 ? [] : n, o = e.defaultOptions, a = o === void 0 ? Ga : o; - return function(l, c, d) { - d === void 0 && (d = a); - var p = { + return function(l, c, p) { + p === void 0 && (p = a); + var d = { placement: "bottom", orderedModifiers: [], options: Object.assign({}, Ga, a), @@ -7660,16 +7666,16 @@ function qf(t) { }, attributes: {}, styles: {} - }, h = [], w = !1, g = { - state: p, + }, m = [], w = !1, g = { + state: d, setOptions: function(E) { - var _ = typeof E == "function" ? E(p.options) : E; - f(), p.options = Object.assign({}, a, p.options, _), p.scrollParents = { + var _ = typeof E == "function" ? E(d.options) : E; + f(), d.options = Object.assign({}, a, d.options, _), d.scrollParents = { reference: ke(l) ? fn(l) : l.contextElement ? fn(l.contextElement) : [], popper: fn(c) }; - var C = Xf(Wf([].concat(r, p.options.modifiers))); - return p.orderedModifiers = C.filter(function(S) { + var C = Xf(Wf([].concat(r, d.options.modifiers))); + return d.orderedModifiers = C.filter(function(S) { return S.enabled; }), v(), g.update(); }, @@ -7680,26 +7686,26 @@ function qf(t) { // prefer the async Popper#update method forceUpdate: function() { if (!w) { - var E = p.elements, _ = E.reference, C = E.popper; + var E = d.elements, _ = E.reference, C = E.popper; if (Ha(_, C)) { - p.rects = { - reference: Gf(_, Pn(C), p.options.strategy === "fixed"), + d.rects = { + reference: Gf(_, Pn(C), d.options.strategy === "fixed"), popper: Ao(C) - }, p.reset = !1, p.placement = p.options.placement, p.orderedModifiers.forEach(function($) { - return p.modifiersData[$.name] = Object.assign({}, $.data); + }, d.reset = !1, d.placement = d.options.placement, d.orderedModifiers.forEach(function($) { + return d.modifiersData[$.name] = Object.assign({}, $.data); }); - for (var S = 0; S < p.orderedModifiers.length; S++) { - if (p.reset === !0) { - p.reset = !1, S = -1; + for (var S = 0; S < d.orderedModifiers.length; S++) { + if (d.reset === !0) { + d.reset = !1, S = -1; continue; } - var b = p.orderedModifiers[S], I = b.fn, z = b.options, H = z === void 0 ? {} : z, O = b.name; - typeof I == "function" && (p = I({ - state: p, + var b = d.orderedModifiers[S], I = b.fn, z = b.options, H = z === void 0 ? {} : z, O = b.name; + typeof I == "function" && (d = I({ + state: d, options: H, name: O, instance: g - }) || p); + }) || d); } } } @@ -7707,8 +7713,8 @@ function qf(t) { // Async and optimistically optimized update – it will not be executed if // not necessary (debounced to run at most once-per-tick) update: Yf(function() { - return new Promise(function(m) { - g.forceUpdate(), m(p); + return new Promise(function(h) { + g.forceUpdate(), h(d); }); }), destroy: function() { @@ -7717,28 +7723,28 @@ function qf(t) { }; if (!Ha(l, c)) return g; - g.setOptions(d).then(function(m) { - !w && d.onFirstUpdate && d.onFirstUpdate(m); + g.setOptions(p).then(function(h) { + !w && p.onFirstUpdate && p.onFirstUpdate(h); }); function v() { - p.orderedModifiers.forEach(function(m) { - var E = m.name, _ = m.options, C = _ === void 0 ? {} : _, S = m.effect; + d.orderedModifiers.forEach(function(h) { + var E = h.name, _ = h.options, C = _ === void 0 ? {} : _, S = h.effect; if (typeof S == "function") { var b = S({ - state: p, + state: d, name: E, instance: g, options: C }), I = function() { }; - h.push(b || I); + m.push(b || I); } }); } function f() { - h.forEach(function(m) { - return m(); - }), h = []; + m.forEach(function(h) { + return h(); + }), m = []; } return g; }; @@ -7787,26 +7793,26 @@ const rm = () => xo({ direction: i, disablePortal: l, modifiers: c, - open: d, - placement: p, - popperOptions: h, + open: p, + placement: d, + popperOptions: m, popperRef: w, slotProps: g = {}, slots: v = {}, TransitionProps: f // @ts-ignore internal logic // prevent from spreading to DOM, it can come from the parent component e.g. Select. - } = e, m = kt(e, Qf), E = M.useRef(null), _ = xe(E, n), C = M.useRef(null), S = xe(C, w), b = M.useRef(S); + } = e, h = kt(e, Qf), E = M.useRef(null), _ = xe(E, n), C = M.useRef(null), S = xe(C, w), b = M.useRef(S); ze(() => { b.current = S; }, [S]), M.useImperativeHandle(w, () => C.current, []); - const I = em(p, i), [z, H] = M.useState(I), [O, $] = M.useState(Zn(o)); + const I = em(d, i), [z, H] = M.useState(I), [O, $] = M.useState(Zn(o)); M.useEffect(() => { C.current && C.current.forceUpdate(); }), M.useEffect(() => { o && $(Zn(o)); }, [o]), ze(() => { - if (!O || !d) + if (!O || !p) return; const q = (at) => { H(at.placement); @@ -7836,16 +7842,16 @@ const rm = () => xo({ q(at); } }]; - c != null && (U = U.concat(c)), h && h.modifiers != null && (U = U.concat(h.modifiers)); + c != null && (U = U.concat(c)), m && m.modifiers != null && (U = U.concat(m.modifiers)); const tt = Jf(O, E.current, P({ placement: I - }, h, { + }, m, { modifiers: U })); return b.current(tt), () => { tt.destroy(), b.current(null); }; - }, [O, l, c, d, h, I]); + }, [O, l, c, p, m, I]); const k = { placement: z }; @@ -7853,7 +7859,7 @@ const rm = () => xo({ const B = rm(), D = (r = v.root) != null ? r : "div", J = zw({ elementType: D, externalSlotProps: g.root, - externalForwardedProps: m, + externalForwardedProps: h, additionalProps: { role: "tooltip", ref: _ @@ -7872,21 +7878,21 @@ const rm = () => xo({ direction: i = "ltr", disablePortal: l = !1, keepMounted: c = !1, - modifiers: d, - open: p, - placement: h = "bottom", + modifiers: p, + open: d, + placement: m = "bottom", popperOptions: w = om, popperRef: g, style: v, transition: f = !1, - slotProps: m = {}, + slotProps: h = {}, slots: E = {} } = e, _ = kt(e, tm), [C, S] = M.useState(!0), b = () => { S(!1); }, I = () => { S(!0); }; - if (!c && !p && (!f || C)) + if (!c && !d && (!f || C)) return null; let z; if (a) @@ -7895,8 +7901,8 @@ const rm = () => xo({ const $ = Zn(r); z = $ && Nr($) ? Yn($).body : Yn(null).body; } - const H = !p && c && (!f || C) ? "none" : void 0, O = f ? { - in: p, + const H = !d && c && (!f || C) ? "none" : void 0, O = f ? { + in: d, onEnter: b, onExited: I } : void 0; @@ -7907,13 +7913,13 @@ const rm = () => xo({ anchorEl: r, direction: i, disablePortal: l, - modifiers: d, + modifiers: p, ref: n, - open: f ? !C : p, - placement: h, + open: f ? !C : d, + placement: m, popperOptions: w, popperRef: g, - slotProps: m, + slotProps: h, slots: E }, _, { style: P({ @@ -8135,23 +8141,23 @@ var lm = function(e) { status: cn }); }, n.performEnter = function(o) { - var a = this, i = this.props.enter, l = this.context ? this.context.isMounting : o, c = this.props.nodeRef ? [l] : [Bn.findDOMNode(this), l], d = c[0], p = c[1], h = this.getTimeouts(), w = l ? h.appear : h.enter; + var a = this, i = this.props.enter, l = this.context ? this.context.isMounting : o, c = this.props.nodeRef ? [l] : [Bn.findDOMNode(this), l], p = c[0], d = c[1], m = this.getTimeouts(), w = l ? m.appear : m.enter; if (!o && !i || Xa.disabled) { this.safeSetState({ status: Ae }, function() { - a.props.onEntered(d); + a.props.onEntered(p); }); return; } - this.props.onEnter(d, p), this.safeSetState({ + this.props.onEnter(p, d), this.safeSetState({ status: me }, function() { - a.props.onEntering(d, p), a.onTransitionEnd(w, function() { + a.props.onEntering(p, d), a.onTransitionEnd(w, function() { a.safeSetState({ status: Ae }, function() { - a.props.onEntered(d, p); + a.props.onEntered(p, d); }); }); }); @@ -8195,8 +8201,8 @@ var lm = function(e) { return; } if (this.props.addEndListener) { - var c = this.props.nodeRef ? [this.nextCallback] : [i, this.nextCallback], d = c[0], p = c[1]; - this.props.addEndListener(d, p); + var c = this.props.nodeRef ? [this.nextCallback] : [i, this.nextCallback], p = c[0], d = c[1]; + this.props.addEndListener(p, d); } o != null && setTimeout(this.nextCallback, o); }, n.render = function() { @@ -8440,21 +8446,21 @@ const um = { easing: i, in: l, onEnter: c, - onEntered: d, - onEntering: p, - onExit: h, + onEntered: p, + onEntering: d, + onExit: m, onExited: w, onExiting: g, style: v, timeout: f = "auto", // eslint-disable-next-line react/prop-types - TransitionComponent: m = cm + TransitionComponent: h = cm } = e, E = kt(e, pm), _ = sn(), C = M.useRef(), S = _s(), b = M.useRef(null), I = xe(b, a.ref, n), z = (q) => (U) => { if (q) { const tt = b.current; U === void 0 ? q(tt) : q(tt, U); } - }, H = z(p), O = z((q, U) => { + }, H = z(d), O = z((q, U) => { dm(q); const { duration: tt, @@ -8476,7 +8482,7 @@ const um = { delay: at, easing: rt })].join(","), c && c(q, U); - }), $ = z(d), k = z(g), B = z((q) => { + }), $ = z(p), k = z(g), B = z((q) => { const { duration: U, delay: tt, @@ -8496,9 +8502,9 @@ const um = { duration: Ur ? rt : rt * 0.666, delay: Ur ? tt : tt || rt * 0.333, easing: at - })].join(","), q.style.opacity = 0, q.style.transform = so(0.75), h && h(q); + })].join(","), q.style.opacity = 0, q.style.transform = so(0.75), m && m(q); }), D = z(w); - return /* @__PURE__ */ s(m, P({ + return /* @__PURE__ */ s(h, P({ appear: o, in: l, nodeRef: b, @@ -8611,27 +8617,27 @@ const Wa = Vo, wm = ["anchorEl", "component", "components", "componentsProps", " anchorEl: i, component: l, components: c, - componentsProps: d, - container: p, - disablePortal: h, + componentsProps: p, + container: d, + disablePortal: m, keepMounted: w, modifiers: g, open: v, placement: f, - popperOptions: m, + popperOptions: h, popperRef: E, transition: _, slots: C, slotProps: S } = a, b = kt(a, wm), I = (r = C == null ? void 0 : C.root) != null ? r : c == null ? void 0 : c.Root, z = P({ anchorEl: i, - container: p, - disablePortal: h, + container: d, + disablePortal: m, keepMounted: w, modifiers: g, open: v, placement: f, - popperOptions: m, + popperOptions: h, popperRef: E, transition: _ }, b); @@ -8641,7 +8647,7 @@ const Wa = Vo, wm = ["anchorEl", "component", "components", "componentsProps", " slots: { root: I }, - slotProps: S ?? d + slotProps: S ?? p }, z, { ref: n })); @@ -8956,7 +8962,7 @@ function Fn(t, e) { }; } const As = /* @__PURE__ */ M.forwardRef(function(e, n) { - var r, o, a, i, l, c, d, p, h, w, g, v, f, m, E, _, C, S, b; + var r, o, a, i, l, c, p, d, m, w, g, v, f, h, E, _, C, S, b; const I = _o({ props: e, name: "MuiTooltip" @@ -9107,9 +9113,9 @@ const As = /* @__PURE__ */ M.forwardRef(function(e, n) { placement: X, PopperComponentProp: Y, touch: de.current - }), Cr = vm(Qe), Ko = (r = (o = Z.popper) != null ? o : O.Popper) != null ? r : ym, Jo = (a = (i = (l = Z.transition) != null ? l : O.Transition) != null ? i : A) != null ? a : Wa, Zo = (c = (d = Z.tooltip) != null ? d : O.Tooltip) != null ? c : xm, Qo = (p = (h = Z.arrow) != null ? h : O.Arrow) != null ? p : Nm, Xs = ln(Ko, P({}, G, (w = K.popper) != null ? w : $.popper, { + }), Cr = vm(Qe), Ko = (r = (o = Z.popper) != null ? o : O.Popper) != null ? r : ym, Jo = (a = (i = (l = Z.transition) != null ? l : O.Transition) != null ? i : A) != null ? a : Wa, Zo = (c = (p = Z.tooltip) != null ? p : O.Tooltip) != null ? c : xm, Qo = (d = (m = Z.arrow) != null ? m : O.Arrow) != null ? d : Nm, Xs = ln(Ko, P({}, G, (w = K.popper) != null ? w : $.popper, { className: be(Cr.popper, G == null ? void 0 : G.className, (g = (v = K.popper) != null ? v : $.popper) == null ? void 0 : g.className) - }), Qe), Ys = ln(Jo, P({}, Nt, (f = K.transition) != null ? f : $.transition), Qe), Ws = ln(Zo, P({}, (m = K.tooltip) != null ? m : $.tooltip, { + }), Qe), Ys = ln(Jo, P({}, Nt, (f = K.transition) != null ? f : $.transition), Qe), Ws = ln(Zo, P({}, (h = K.tooltip) != null ? h : $.tooltip, { className: be(Cr.tooltip, (E = (_ = K.tooltip) != null ? _ : $.tooltip) == null ? void 0 : E.className) }), Qe), qs = ln(Qo, P({}, (C = K.arrow) != null ? C : $.arrow, { className: be(Cr.arrow, (S = (b = K.arrow) != null ? b : $.arrow) == null ? void 0 : S.className) @@ -9355,22 +9361,22 @@ function Ms(t) { iconPathAfter: i = void 0, hasAutoFocus: l = !1, className: c, - isDisabled: d = !1, - isDense: p = !0, - isSubMenuParent: h = !1, + isDisabled: p = !1, + isDense: d = !0, + isSubMenuParent: m = !1, hasDisabledGutters: w = !1, hasDivider: g = !1, focusVisibleClassName: v, id: f, - children: m + children: h } = t, E = /* @__PURE__ */ s( Bl, { sx: { lineHeight: 0.8 }, autoFocus: l, className: c, - disabled: d, - dense: p, + disabled: p, + dense: d, disableGutters: w, divider: g, focusVisibleClassName: v, @@ -9379,8 +9385,8 @@ function Ms(t) { children: n ? /* @__PURE__ */ N(ie, { children: [ Ka(a, n, !0), /* @__PURE__ */ s(jl, { primary: n, inset: !a && o }), - h ? /* @__PURE__ */ s(ii, { className: "papi-menu-icon-trailing", children: /* @__PURE__ */ s(hs, {}) }) : Ka(i, n, !1) - ] }) : m + m ? /* @__PURE__ */ s(ii, { className: "papi-menu-icon-trailing", children: /* @__PURE__ */ s(hs, {}) }) : Ka(i, n, !1) + ] }) : h } ); return r ? /* @__PURE__ */ s(km, { title: r, placement: "right", children: /* @__PURE__ */ s("div", { children: E }) }) : E; @@ -9389,17 +9395,17 @@ function Ds(t) { return Object.entries(t.groups).map(([n, r]) => ({ id: n, group: r })); } function Em(t) { - const [e, n] = ut(void 0), { parentMenuItem: r, parentItemProps: o, menuDefinition: a } = t, i = (d) => { - n(d.currentTarget); + const [e, n] = ut(void 0), { parentMenuItem: r, parentItemProps: o, menuDefinition: a } = t, i = (p) => { + n(p.currentTarget); }, l = () => { n(void 0); }, c = () => { - let d = Ds(a).filter((p) => "menuItem" in p.group); + let p = Ds(a).filter((d) => "menuItem" in d.group); if (!(r != null && r.id)) throw new Error("A valid parent menu item is required for submenus."); - return d = d.filter( - (p) => "menuItem" in p.group && p.group.menuItem === r.id - ), /* @__PURE__ */ s(Bs, { ...t, includedGroups: d }); + return p = p.filter( + (d) => "menuItem" in d.group && d.group.menuItem === r.id + ), /* @__PURE__ */ s(Bs, { ...t, includedGroups: p }); }; return /* @__PURE__ */ N(ie, { children: [ /* @__PURE__ */ s(Ms, { onClick: i, ...o, isSubMenuParent: !0 }), @@ -9426,14 +9432,14 @@ function Em(t) { const Sm = (t, e) => e.filter((o) => o.group === t).sort((o, a) => (o.order || 0) - (a.order || 0)); function Bs(t) { const { menuDefinition: e, onClick: n, commandHandler: r, includedGroups: o } = t, { items: a, allowForLeadingIcons: i } = It(() => { - const p = o && o.length > 0 ? o : ( + const d = o && o.length > 0 ? o : ( // We're apparently laying out a single-column menu (presumably a context menu). In this // case, all groups should be included except ones that belong to a submenu. Ds(e).filter((v) => !("menuItem" in v.group)) - ), h = Object.values(p).sort( + ), m = Object.values(d).sort( (v, f) => (v.group.order || 0) - (f.group.order || 0) ), w = []; - h.forEach((v) => { + m.forEach((v) => { Sm(v.id, e.items).forEach( (f) => w.push({ item: f, isLastItemInGroup: !1 }) ), w.length > 0 && (w[w.length - 1].isLastItemInGroup = !0); @@ -9442,23 +9448,23 @@ function Bs(t) { (v) => "iconPathBefore" in v.item && v.item.iconPathBefore ); return { items: w, allowForLeadingIcons: g }; - }, [o, e]), l = ({ item: p, isLastItemInGroup: h }) => ({ + }, [o, e]), l = ({ item: d, isLastItemInGroup: m }) => ({ className: "papi-menu-item", - label: p.label, - tooltip: p.tooltip, - iconPathBefore: "iconPathBefore" in p ? p.iconPathBefore : void 0, - iconPathAfter: "iconPathAfter" in p ? p.iconPathAfter : void 0, - hasDivider: h, + label: d.label, + tooltip: d.tooltip, + iconPathBefore: "iconPathBefore" in d ? d.iconPathBefore : void 0, + iconPathAfter: "iconPathAfter" in d ? d.iconPathAfter : void 0, + hasDivider: m, // Set hasDivider to true for the last item in a group allowForLeadingIcons: i }), [c] = a; if (!c) return /* @__PURE__ */ s("div", {}); - const d = c.item.group; - return /* @__PURE__ */ s("div", { role: "menu", "aria-label": d, children: a.map((p, h) => { - const { item: w } = p, g = l(p); + const p = c.item.group; + return /* @__PURE__ */ s("div", { role: "menu", "aria-label": p, children: a.map((d, m) => { + const { item: w } = d, g = l(d); if ("command" in w) { - const v = w.group + h; + const v = w.group + m; return /* @__PURE__ */ s( Ms, { @@ -9477,9 +9483,9 @@ function Bs(t) { parentItemProps: g, ...t }, - d + w.id + p + w.id ); - }) }, d); + }) }, p); } function Tm(t) { const { menuDefinition: e, columnId: n } = t; @@ -9533,9 +9539,9 @@ function Om({ return Object.getOwnPropertyNames(o).forEach((l) => { if (l === "isExtensible") return; - const c = l, d = o[c]; - typeof d == "object" && typeof d.order == "number" && !Number.isNaN(d.order) ? i.set(d.order, { id: c, metadata: d }) : console.warn( - `Property ${l} (${typeof d}) on menu ${r} is not a valid column and is being ignored. This might indicate data corruption` + const c = l, p = o[c]; + typeof p == "object" && typeof p.order == "number" && !Number.isNaN(p.order) ? i.set(p.order, { id: c, metadata: p }) : console.warn( + `Property ${l} (${typeof p}) on menu ${r} is not a valid column and is being ignored. This might indicate data corruption` ); }), Array.from(i.values()).sort((l, c) => (l.metadata.order || 0) - (c.metadata.order || 0)); }, [o, r]); @@ -9575,14 +9581,14 @@ const lo = (t, e, n = {}) => { o.current = Rm(o.current); const [a, i] = ut(() => r.current), [l, c] = ut(!0); return ae(() => { - let d = !0; + let p = !0; return c(!!t), (async () => { if (t) { - const p = await t(); - d && (i(() => p), c(!1)); + const d = await t(); + p && (i(() => d), c(!1)); } })(), () => { - d = !1, o.current.preserveValue || i(() => r.current); + p = !1, o.current.preserveValue || i(() => r.current); }; }, [t]), [a, l]; }, _m = ms(/* @__PURE__ */ s("path", { @@ -9598,23 +9604,23 @@ function Pm({ ariaLabelPrefix: i, children: l }) { - const [c, d] = ut(!1), [p, h] = ut(!1), w = Et(() => { - c && d(!1), h(!1); + const [c, p] = ut(!1), [d, m] = ut(!1), w = Et(() => { + c && p(!1), m(!1); }, [c]), g = Et((S) => { - S.stopPropagation(), d((b) => { + S.stopPropagation(), p((b) => { const I = !b; - return I && S.shiftKey ? h(!0) : I || h(!1), I; + return I && S.shiftKey ? m(!0) : I || m(!1), I; }); }, []), v = Et( (S) => (w(), r(S)), [r, w] - ), [f, m] = ut({ top: 1, left: 1 }); + ), [f, h] = ut({ top: 1, left: 1 }); ae(() => { if (c) { const S = o == null ? void 0 : o.current; if (S) { const b = S.getBoundingClientRect(), I = window.scrollY, z = window.scrollX, H = b.top + I + S.clientHeight, O = b.left + z; - m({ top: H, left: O }); + h({ top: H, left: O }); } } }, [c, o]); @@ -9624,7 +9630,7 @@ function Pm({ ), [_] = lo( Et(async () => (t == null ? void 0 : t(!0)) ?? n ?? E, [t, n, E, c]), n ?? E - ), C = p && _ ? _ : E; + ), C = d && _ ? _ : E; return /* @__PURE__ */ N(ie, { children: [ /* @__PURE__ */ s( li, @@ -9679,7 +9685,7 @@ function Ih({ size: i = "medium", className: l, onClick: c, - children: d + children: p }) { return /* @__PURE__ */ s( li, @@ -9692,7 +9698,7 @@ function Ih({ title: o ? void 0 : r ?? e, className: `papi-icon-button ${l ?? ""}`, onClick: c, - children: d + children: p } ); } @@ -9708,9 +9714,9 @@ function Ah({ placeholder: i, isRequired: l = !1, className: c, - defaultValue: d, - value: p, - onChange: h, + defaultValue: p, + value: d, + onChange: m, onFocus: w, onBlur: g }) { @@ -9734,9 +9740,9 @@ function Ah({ placeholder: i, required: l, className: x(c, { "tw-border-red-600": n }), - defaultValue: d, - value: p, - onChange: h, + defaultValue: p, + value: d, + onChange: m, onFocus: w, onBlur: g } @@ -10197,9 +10203,9 @@ function Hh({ function qm({ id: t, versionHistory: e }) { const [n, r] = ut(!1), o = /* @__PURE__ */ new Date(); function a(l) { - const c = new Date(l), d = new Date(o.getTime() - c.getTime()), p = d.getUTCFullYear() - 1970, h = d.getUTCMonth(), w = d.getUTCDate() - 1; + const c = new Date(l), p = new Date(o.getTime() - c.getTime()), d = p.getUTCFullYear() - 1970, m = p.getUTCMonth(), w = p.getUTCDate() - 1; let g = ""; - return p > 0 ? g = `${p.toString()} year${p === 1 ? "" : "s"} ago` : h > 0 ? g = `${h.toString()} month${h === 1 ? "" : "s"} ago` : w === 0 ? g = "today" : g = `${w.toString()} day${w === 1 ? "" : "s"} ago`, g; + return d > 0 ? g = `${d.toString()} year${d === 1 ? "" : "s"} ago` : m > 0 ? g = `${m.toString()} month${m === 1 ? "" : "s"} ago` : w === 0 ? g = "today" : g = `${w.toString()} day${w === 1 ? "" : "s"} ago`, g; } const i = Object.entries(e).sort((l, c) => c[0].localeCompare(l[0])); return /* @__PURE__ */ N("div", { id: t, children: [ @@ -10233,8 +10239,8 @@ function Xh({ versionHistory: o }) { const a = It(() => Rl(n), [n]), l = ((c) => { - const d = new Intl.DisplayNames(navigator.language, { type: "language" }); - return c.map((p) => d.of(p)); + const p = new Intl.DisplayNames(navigator.language, { type: "language" }); + return c.map((d) => p.of(d)); })(r); return /* @__PURE__ */ s("div", { id: t, className: "tw-border-t tw-pb-4 tw-pt-4", children: /* @__PURE__ */ N("div", { className: "tw-md:flex-row tw-md:space-x-8 tw-flex tw-flex-col tw-space-x-0", children: [ /* @__PURE__ */ s(qm, { versionHistory: o }), @@ -13818,6 +13824,32 @@ video:where(.pr-twp,.pr-twp *) { .banded-row[data-state='selected']:hover { cursor: default; } +.papi-icon-button { + border: 0; + border-radius: 3em; + cursor: pointer; + display: inline-block; +} + +.papi-icon-button.primary { + background-color: #1ea7fd; + color: white; +} + +.papi-icon-button.secondary { + background-color: transparent; + color: #333; +} + +.papi-icon-button.paratext { + background-color: darkgreen; + color: greenyellow; +} + +.papi-icon-button.paratext.bright { + background-color: greenyellow; + color: darkgreen; +} .papi-multi-column-menu { background-color: rgb(222, 222, 222); display: flex; @@ -13865,32 +13897,6 @@ video:where(.pr-twp,.pr-twp *) { max-width: 24px; max-height: 24px; } -.papi-icon-button { - border: 0; - border-radius: 3em; - cursor: pointer; - display: inline-block; -} - -.papi-icon-button.primary { - background-color: #1ea7fd; - color: white; -} - -.papi-icon-button.secondary { - background-color: transparent; - color: #333; -} - -.papi-icon-button.paratext { - background-color: darkgreen; - color: greenyellow; -} - -.papi-icon-button.paratext.bright { - background-color: greenyellow; - color: darkgreen; -} .papi-menu-drawer-paper { height: fit-content !important; position: absolute !important; diff --git a/lib/platform-bible-react/dist/index.js.map b/lib/platform-bible-react/dist/index.js.map index ac9b9185b7..46da395ba6 100644 --- a/lib/platform-bible-react/dist/index.js.map +++ b/lib/platform-bible-react/dist/index.js.map @@ -1 +1 @@ -{"version":3,"file":"index.js","sources":["../src/utils/shadcn-ui.util.ts","../src/components/shadcn-ui/input.tsx","../src/components/advanced/book-chapter-control/book-chapter-input.component.tsx","../../../node_modules/@sillsdev/scripture/dist/index.es.js","../src/components/shadcn-ui/dropdown-menu.tsx","../src/components/advanced/book-chapter-control/book-menu-item.component.tsx","../src/components/advanced/book-chapter-control/chapter-select.component.tsx","../src/components/advanced/book-chapter-control/go-to-menu-item.component.tsx","../src/components/advanced/book-chapter-control/book-chapter-control.component.tsx","../src/components/shadcn-ui/button.tsx","../src/components/shadcn-ui/label.tsx","../src/components/shadcn-ui/radio-group.tsx","../src/components/shadcn-ui/popover.tsx","../src/components/shadcn-ui/dialog.tsx","../src/components/shadcn-ui/command.tsx","../src/components/basics/combo-box.component.tsx","../src/components/basics/chapter-range-selector.component.tsx","../src/components/advanced/book-selector.component.tsx","../src/components/advanced/data-table/data-table-column-toggle.component.tsx","../src/components/shadcn-ui/select.tsx","../src/components/advanced/data-table/data-table-pagination.component.tsx","../src/components/shadcn-ui/table.tsx","../src/components/advanced/data-table/data-table.component.tsx","../src/components/advanced/inventory/occurrences-table.component.tsx","../src/components/shadcn-ui/checkbox.tsx","../src/components/advanced/inventory/inventory-utils.ts","../src/components/shadcn-ui/toggle.tsx","../src/components/shadcn-ui/toggle-group.tsx","../src/components/advanced/inventory/inventory-columns.tsx","../src/components/advanced/inventory/inventory.component.tsx","../src/components/basics/search-bar.component.tsx","../src/components/basics/tabs-vertical.tsx","../src/components/advanced/tab-navigation-content-search.component.tsx","../src/components/shadcn-ui/separator.tsx","../src/components/shadcn-ui/sheet.tsx","../src/components/shadcn-ui/skeleton.tsx","../src/components/shadcn-ui/tooltip.tsx","../src/components/hooks/use-mobile.tsx","../src/components/shadcn-ui/sidebar.tsx","../src/components/advanced/settings-components/settings-sidebar.component.tsx","../src/components/advanced/settings-components/settings-sidebar-content-search.component.tsx","../src/components/advanced/scripture-results-viewer/scripture-results-viewer.component.tsx","../src/components/advanced/scroll-group-selector.component.tsx","../src/components/advanced/settings-components/settings-list.component.tsx","../src/components/basics/checklist.component.tsx","../../../node_modules/@babel/runtime/helpers/interopRequireDefault.js","../../../node_modules/@mui/utils/chainPropTypes/chainPropTypes.js","../../../node_modules/@babel/runtime/helpers/esm/extends.js","../../../node_modules/@mui/utils/deepmerge/deepmerge.js","../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.production.min.js","../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.development.js","../../../node_modules/prop-types/node_modules/react-is/index.js","../../../node_modules/object-assign/index.js","../../../node_modules/prop-types/lib/ReactPropTypesSecret.js","../../../node_modules/prop-types/lib/has.js","../../../node_modules/prop-types/checkPropTypes.js","../../../node_modules/prop-types/factoryWithTypeCheckers.js","../../../node_modules/prop-types/factoryWithThrowingShims.js","../../../node_modules/prop-types/index.js","../../../node_modules/@mui/utils/elementAcceptingRef/elementAcceptingRef.js","../../../node_modules/@mui/utils/exactProp/exactProp.js","../../../node_modules/@mui/utils/formatMuiErrorMessage/formatMuiErrorMessage.js","../../../node_modules/react-is/cjs/react-is.production.min.js","../../../node_modules/react-is/cjs/react-is.development.js","../../../node_modules/react-is/index.js","../../../node_modules/@mui/utils/getDisplayName/getDisplayName.js","../../../node_modules/@mui/utils/HTMLElementType/HTMLElementType.js","../../../node_modules/@mui/utils/refType/refType.js","../../../node_modules/@mui/utils/capitalize/capitalize.js","../../../node_modules/@mui/utils/createChainedFunction/createChainedFunction.js","../../../node_modules/@mui/utils/debounce/debounce.js","../../../node_modules/@mui/utils/deprecatedPropType/deprecatedPropType.js","../../../node_modules/@mui/utils/isMuiElement/isMuiElement.js","../../../node_modules/@mui/utils/ownerDocument/ownerDocument.js","../../../node_modules/@mui/utils/ownerWindow/ownerWindow.js","../../../node_modules/@mui/utils/requirePropFactory/requirePropFactory.js","../../../node_modules/@mui/utils/setRef/setRef.js","../../../node_modules/@mui/utils/useEnhancedEffect/useEnhancedEffect.js","../../../node_modules/@mui/utils/useId/useId.js","../../../node_modules/@mui/utils/unsupportedProp/unsupportedProp.js","../../../node_modules/@mui/utils/useControlled/useControlled.js","../../../node_modules/@mui/utils/useEventCallback/useEventCallback.js","../../../node_modules/@mui/utils/useForkRef/useForkRef.js","../../../node_modules/@mui/utils/useLazyRef/useLazyRef.js","../../../node_modules/@mui/utils/useOnMount/useOnMount.js","../../../node_modules/@mui/utils/useTimeout/useTimeout.js","../../../node_modules/@mui/utils/useIsFocusVisible/useIsFocusVisible.js","../../../node_modules/@mui/utils/resolveProps/resolveProps.js","../../../node_modules/@mui/utils/composeClasses/composeClasses.js","../../../node_modules/@mui/utils/ClassNameGenerator/ClassNameGenerator.js","../../../node_modules/@mui/utils/generateUtilityClass/generateUtilityClass.js","../../../node_modules/@mui/utils/generateUtilityClasses/generateUtilityClasses.js","../../../node_modules/@mui/utils/clamp/clamp.js","../../../node_modules/@babel/runtime/helpers/esm/objectWithoutPropertiesLoose.js","../../../node_modules/@mui/system/esm/createTheme/createBreakpoints.js","../../../node_modules/@mui/system/esm/createTheme/shape.js","../../../node_modules/@mui/system/esm/responsivePropType.js","../../../node_modules/@mui/system/esm/merge.js","../../../node_modules/@mui/system/esm/breakpoints.js","../../../node_modules/@mui/system/esm/style.js","../../../node_modules/@mui/system/esm/memoize.js","../../../node_modules/@mui/system/esm/spacing.js","../../../node_modules/@mui/system/esm/createTheme/createSpacing.js","../../../node_modules/@mui/system/esm/compose.js","../../../node_modules/@mui/system/esm/borders.js","../../../node_modules/@mui/system/esm/cssGrid.js","../../../node_modules/@mui/system/esm/palette.js","../../../node_modules/@mui/system/esm/sizing.js","../../../node_modules/@mui/system/esm/styleFunctionSx/defaultSxConfig.js","../../../node_modules/@mui/system/esm/styleFunctionSx/styleFunctionSx.js","../../../node_modules/@mui/system/esm/createTheme/applyStyles.js","../../../node_modules/@mui/system/esm/createTheme/createTheme.js","../../../node_modules/@mui/system/esm/useThemeWithoutDefault.js","../../../node_modules/@mui/system/esm/useTheme.js","../../../node_modules/@mui/system/esm/createStyled.js","../../../node_modules/@mui/system/esm/useThemeProps/getThemeProps.js","../../../node_modules/@mui/system/esm/useThemeProps/useThemeProps.js","../../../node_modules/@mui/system/esm/colorManipulator.js","../../../node_modules/@mui/material/styles/createMixins.js","../../../node_modules/@mui/material/colors/common.js","../../../node_modules/@mui/material/colors/grey.js","../../../node_modules/@mui/material/colors/purple.js","../../../node_modules/@mui/material/colors/red.js","../../../node_modules/@mui/material/colors/orange.js","../../../node_modules/@mui/material/colors/blue.js","../../../node_modules/@mui/material/colors/lightBlue.js","../../../node_modules/@mui/material/colors/green.js","../../../node_modules/@mui/material/styles/createPalette.js","../../../node_modules/@mui/material/styles/createTypography.js","../../../node_modules/@mui/material/styles/shadows.js","../../../node_modules/@mui/material/styles/createTransitions.js","../../../node_modules/@mui/material/styles/zIndex.js","../../../node_modules/@mui/material/styles/createTheme.js","../../../node_modules/@mui/material/styles/defaultTheme.js","../../../node_modules/@mui/material/styles/identifier.js","../../../node_modules/@mui/material/styles/useThemeProps.js","../../../node_modules/@mui/material/styles/styled.js","../../../node_modules/@mui/material/SvgIcon/svgIconClasses.js","../../../node_modules/@mui/material/SvgIcon/SvgIcon.js","../../../node_modules/@mui/material/utils/createSvgIcon.js","../../../node_modules/@mui/material/utils/index.js","../../../node_modules/@mui/icons-material/utils/createSvgIcon.js","../../../node_modules/@mui/icons-material/ArrowRight.js","../../../node_modules/@mui/base/utils/isHostComponent.js","../../../node_modules/@mui/base/utils/appendOwnerState.js","../../../node_modules/@mui/base/utils/ClassNameConfigurator.js","../../../node_modules/@mui/base/utils/extractEventHandlers.js","../../../node_modules/@mui/base/utils/resolveComponentProps.js","../../../node_modules/@mui/base/utils/omitEventHandlers.js","../../../node_modules/@mui/base/utils/mergeSlotProps.js","../../../node_modules/@mui/base/utils/useSlotProps.js","../../../node_modules/@mui/base/generateUtilityClass/index.js","../../../node_modules/@mui/base/generateUtilityClasses/index.js","../../../node_modules/@mui/base/Portal/Portal.js","../../../node_modules/@popperjs/core/lib/enums.js","../../../node_modules/@popperjs/core/lib/dom-utils/getNodeName.js","../../../node_modules/@popperjs/core/lib/dom-utils/getWindow.js","../../../node_modules/@popperjs/core/lib/dom-utils/instanceOf.js","../../../node_modules/@popperjs/core/lib/modifiers/applyStyles.js","../../../node_modules/@popperjs/core/lib/utils/getBasePlacement.js","../../../node_modules/@popperjs/core/lib/utils/math.js","../../../node_modules/@popperjs/core/lib/utils/userAgent.js","../../../node_modules/@popperjs/core/lib/dom-utils/isLayoutViewport.js","../../../node_modules/@popperjs/core/lib/dom-utils/getBoundingClientRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/getLayoutRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/contains.js","../../../node_modules/@popperjs/core/lib/dom-utils/getComputedStyle.js","../../../node_modules/@popperjs/core/lib/dom-utils/isTableElement.js","../../../node_modules/@popperjs/core/lib/dom-utils/getDocumentElement.js","../../../node_modules/@popperjs/core/lib/dom-utils/getParentNode.js","../../../node_modules/@popperjs/core/lib/dom-utils/getOffsetParent.js","../../../node_modules/@popperjs/core/lib/utils/getMainAxisFromPlacement.js","../../../node_modules/@popperjs/core/lib/utils/within.js","../../../node_modules/@popperjs/core/lib/utils/getFreshSideObject.js","../../../node_modules/@popperjs/core/lib/utils/mergePaddingObject.js","../../../node_modules/@popperjs/core/lib/utils/expandToHashMap.js","../../../node_modules/@popperjs/core/lib/modifiers/arrow.js","../../../node_modules/@popperjs/core/lib/utils/getVariation.js","../../../node_modules/@popperjs/core/lib/modifiers/computeStyles.js","../../../node_modules/@popperjs/core/lib/modifiers/eventListeners.js","../../../node_modules/@popperjs/core/lib/utils/getOppositePlacement.js","../../../node_modules/@popperjs/core/lib/utils/getOppositeVariationPlacement.js","../../../node_modules/@popperjs/core/lib/dom-utils/getWindowScroll.js","../../../node_modules/@popperjs/core/lib/dom-utils/getWindowScrollBarX.js","../../../node_modules/@popperjs/core/lib/dom-utils/getViewportRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/getDocumentRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/isScrollParent.js","../../../node_modules/@popperjs/core/lib/dom-utils/getScrollParent.js","../../../node_modules/@popperjs/core/lib/dom-utils/listScrollParents.js","../../../node_modules/@popperjs/core/lib/utils/rectToClientRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/getClippingRect.js","../../../node_modules/@popperjs/core/lib/utils/computeOffsets.js","../../../node_modules/@popperjs/core/lib/utils/detectOverflow.js","../../../node_modules/@popperjs/core/lib/utils/computeAutoPlacement.js","../../../node_modules/@popperjs/core/lib/modifiers/flip.js","../../../node_modules/@popperjs/core/lib/modifiers/hide.js","../../../node_modules/@popperjs/core/lib/modifiers/offset.js","../../../node_modules/@popperjs/core/lib/modifiers/popperOffsets.js","../../../node_modules/@popperjs/core/lib/utils/getAltAxis.js","../../../node_modules/@popperjs/core/lib/modifiers/preventOverflow.js","../../../node_modules/@popperjs/core/lib/dom-utils/getHTMLElementScroll.js","../../../node_modules/@popperjs/core/lib/dom-utils/getNodeScroll.js","../../../node_modules/@popperjs/core/lib/dom-utils/getCompositeRect.js","../../../node_modules/@popperjs/core/lib/utils/orderModifiers.js","../../../node_modules/@popperjs/core/lib/utils/debounce.js","../../../node_modules/@popperjs/core/lib/utils/mergeByName.js","../../../node_modules/@popperjs/core/lib/createPopper.js","../../../node_modules/@popperjs/core/lib/popper.js","../../../node_modules/@mui/base/Popper/popperClasses.js","../../../node_modules/@mui/base/Popper/Popper.js","../../../node_modules/@mui/material/styles/useTheme.js","../../../node_modules/@babel/runtime/helpers/esm/setPrototypeOf.js","../../../node_modules/@babel/runtime/helpers/esm/inheritsLoose.js","../../../node_modules/react-transition-group/esm/config.js","../../../node_modules/react-transition-group/esm/utils/PropTypes.js","../../../node_modules/react-transition-group/esm/TransitionGroupContext.js","../../../node_modules/react-transition-group/esm/utils/reflow.js","../../../node_modules/react-transition-group/esm/Transition.js","../../../node_modules/@mui/material/transitions/utils.js","../../../node_modules/@mui/material/Grow/Grow.js","../../../node_modules/@mui/material/Popper/Popper.js","../../../node_modules/@mui/material/Tooltip/tooltipClasses.js","../../../node_modules/@mui/material/Tooltip/Tooltip.js","../src/components/mui/menu-item.component.tsx","../src/components/mui/grouped-menu-item-list.component.tsx","../src/components/mui/top-level-menu.component.tsx","../src/components/mui/grid-menu.component.tsx","../src/hooks/use-promise.hook.ts","../../../node_modules/@mui/icons-material/esm/Menu.js","../src/components/mui/hamburger-menu-button.component.tsx","../src/components/mui/icon-button.component.tsx","../src/components/basics/spinner.component.tsx","../src/components/basics/text-field.component.tsx","../src/components/mui/toolbar.component.tsx","../src/components/shadcn-ui/alert.tsx","../src/components/shadcn-ui/card.tsx","../src/components/shadcn-ui/sonner.tsx","../src/components/shadcn-ui/slider.tsx","../src/components/shadcn-ui/switch.tsx","../src/components/shadcn-ui/tabs.tsx","../src/components/advanced/extension-marketplace/buttons/install-button.component.tsx","../src/components/advanced/extension-marketplace/buttons/enable-button.component.tsx","../src/components/advanced/extension-marketplace/buttons/disable-button.component.tsx","../src/components/advanced/extension-marketplace/buttons/update-button.component.tsx","../src/components/advanced/extension-marketplace/markdown-renderer.component.tsx","../src/components/advanced/extension-marketplace/buttons/filter-button.component.tsx","../src/components/advanced/extension-marketplace/filter-dropdown.component.tsx","../src/components/advanced/extension-marketplace/no-extensions-found.component.tsx","../src/components/advanced/extension-marketplace/more-info.component.tsx","../src/components/advanced/extension-marketplace/version-history.component.tsx","../src/components/advanced/extension-marketplace/footer.component.tsx","../src/hooks/use-event.hook.ts","../src/hooks/use-event-async.hook.ts"],"sourcesContent":["import { type ClassValue, clsx } from 'clsx';\nimport { extendTailwindMerge } from 'tailwind-merge';\n\nconst twMergeCustom = extendTailwindMerge({ prefix: 'tw-' });\n\n/**\n * Tailwind and CSS class application helper function. Uses\n * [`clsx`](https://www.npmjs.com/package/clsx) to make it easy to apply classes conditionally using\n * object syntax, and uses [`tailwind-merge`](https://www.npmjs.com/package/tailwind-merge) to make\n * it easy to merge/overwrite Tailwind classes in a programmer-logic-friendly way.\n *\n * Note: `tailwind-merge` is configured to use the prefix `tw-`, so you must use the same prefix\n * with any Tailwind classes you use with this function to successfully overwrite other Tailwind\n * classes. `platform-bible-react` is configured to use `tw-` as its Tailwind prefix, so any\n * Tailwind classes you pass into `platform-bible-react` components will be compared using the `tw-`\n * prefix.\n *\n * This function was popularized by\n * [shadcn/ui](https://ui.shadcn.com/docs/installation/manual#add-a-cn-helper). See [ByteGrad's\n * explanation video](https://www.youtube.com/watch?v=re2JFITR7TI) for more information.\n *\n * @example\n *\n * ```typescript\n * const borderShouldBeBlue = true;\n * const textShouldBeRed = true;\n * const heightShouldBe20 = false;\n * const classString = cn(\n * 'tw-bg-primary tw-h-10 tw-text-primary-foreground',\n * 'tw-bg-secondary',\n * {\n * 'tw-border-blue-500': borderShouldBeBlue,\n * 'tw-text-red-500': textShouldBeRed,\n * 'tw-h-20': heightShouldBe20,\n * },\n * 'some-class',\n * );\n * ```\n *\n * The resulting `classString` is `'tw-h-10 tw-bg-secondary tw-border-blue-500 tw-text-red-500\n * some-class'`\n *\n * - Notice that `'tw-bg-secondary'`, specified later, overwrote `'tw-bg-primary'`, specified earlier,\n * because they are Tailwind classes that affect the same css property\n * - Notice that `'tw-text-red-500'`, specified later, overwrote `'tw-text-primary-foreground'`,\n * specified earlier, because they are Tailwind classes that affect the same css property\n * - Notice that `'tw-h-20'`, specified later, did not overwrite `'tw-h-10'`, specified earlier,\n * because `'tw-h-20'` is part of a conditional class object and its value evaluated to `false`;\n * therefore it was not applied\n * - Notice that `'some-class'` was applied. This function is not limited only to Tailwind classes.\n *\n *\n * @param inputs Class strings or `clsx` conditional class objects to merge. Tailwind classes\n * specified later in the arguments overwrite similar Tailwind classes specified earlier in the\n * arguments\n * @returns Class string containing all applicable classes from the arguments based on the rules\n * described above\n */\n// shadcn/ui uses this export in its boilerplate code\n// eslint-disable-next-line import/prefer-default-export\nexport function cn(...inputs: ClassValue[]) {\n return twMergeCustom(clsx(inputs));\n}\n","import React from 'react';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport interface InputProps extends React.InputHTMLAttributes {}\n\nexport const Input = React.forwardRef(\n ({ className, type, ...props }, ref) => {\n return (\n \n );\n },\n);\nInput.displayName = 'Input';\n","import { FocusEventHandler, forwardRef, KeyboardEvent, MouseEventHandler } from 'react';\nimport { History } from 'lucide-react';\nimport { Input as ShadInput } from '@/components/shadcn-ui/input';\n\nexport type BookChapterInputProps = {\n handleSearch: (searchString: string) => void;\n handleKeyDown: (event: KeyboardEvent) => void;\n handleOnClick: MouseEventHandler;\n handleSubmit: () => void;\n onFocus?: FocusEventHandler;\n value: string;\n placeholder: string;\n};\n\n// Shadcn Input sets type to \"button\"- HAVE to prop spread before setting type\nconst BookChapterInput = forwardRef(\n (\n { handleSearch, handleKeyDown, handleOnClick, handleSubmit, ...props }: BookChapterInputProps,\n ref,\n ) => {\n return (\n
    \n handleSearch(event.target.value)}\n onKeyDown={(e) => {\n if (e.key === 'Enter') {\n handleSubmit();\n }\n handleKeyDown(e);\n }}\n onClick={handleOnClick}\n ref={ref}\n />\n {\n // eslint-disable-next-line no-console\n console.log('back in history');\n }}\n />\n
    \n );\n },\n);\n\nexport default BookChapterInput;\n","var P = Object.defineProperty;\nvar R = (t, e, s) => e in t ? P(t, e, { enumerable: !0, configurable: !0, writable: !0, value: s }) : t[e] = s;\nvar n = (t, e, s) => R(t, typeof e != \"symbol\" ? e + \"\" : e, s);\nclass _ {\n constructor() {\n n(this, \"books\");\n n(this, \"firstSelectedBookNum\");\n n(this, \"lastSelectedBookNum\");\n n(this, \"count\");\n n(this, \"selectedBookNumbers\");\n n(this, \"selectedBookIds\");\n }\n}\nconst N = [\n \"GEN\",\n \"EXO\",\n \"LEV\",\n \"NUM\",\n \"DEU\",\n \"JOS\",\n \"JDG\",\n \"RUT\",\n \"1SA\",\n \"2SA\",\n // 10\n \"1KI\",\n \"2KI\",\n \"1CH\",\n \"2CH\",\n \"EZR\",\n \"NEH\",\n \"EST\",\n \"JOB\",\n \"PSA\",\n \"PRO\",\n // 20\n \"ECC\",\n \"SNG\",\n \"ISA\",\n \"JER\",\n \"LAM\",\n \"EZK\",\n \"DAN\",\n \"HOS\",\n \"JOL\",\n \"AMO\",\n // 30\n \"OBA\",\n \"JON\",\n \"MIC\",\n \"NAM\",\n \"HAB\",\n \"ZEP\",\n \"HAG\",\n \"ZEC\",\n \"MAL\",\n \"MAT\",\n // 40\n \"MRK\",\n \"LUK\",\n \"JHN\",\n \"ACT\",\n \"ROM\",\n \"1CO\",\n \"2CO\",\n \"GAL\",\n \"EPH\",\n \"PHP\",\n // 50\n \"COL\",\n \"1TH\",\n \"2TH\",\n \"1TI\",\n \"2TI\",\n \"TIT\",\n \"PHM\",\n \"HEB\",\n \"JAS\",\n \"1PE\",\n // 60\n \"2PE\",\n \"1JN\",\n \"2JN\",\n \"3JN\",\n \"JUD\",\n \"REV\",\n \"TOB\",\n \"JDT\",\n \"ESG\",\n \"WIS\",\n // 70\n \"SIR\",\n \"BAR\",\n \"LJE\",\n \"S3Y\",\n \"SUS\",\n \"BEL\",\n \"1MA\",\n \"2MA\",\n \"3MA\",\n \"4MA\",\n // 80\n \"1ES\",\n \"2ES\",\n \"MAN\",\n \"PS2\",\n \"ODA\",\n \"PSS\",\n \"JSA\",\n // actual variant text for JOS, now in LXA text\n \"JDB\",\n // actual variant text for JDG, now in LXA text\n \"TBS\",\n // actual variant text for TOB, now in LXA text\n \"SST\",\n // actual variant text for SUS, now in LXA text // 90\n \"DNT\",\n // actual variant text for DAN, now in LXA text\n \"BLT\",\n // actual variant text for BEL, now in LXA text\n \"XXA\",\n \"XXB\",\n \"XXC\",\n \"XXD\",\n \"XXE\",\n \"XXF\",\n \"XXG\",\n \"FRT\",\n // 100\n \"BAK\",\n \"OTH\",\n \"3ES\",\n // Used previously but really should be 2ES\n \"EZA\",\n // Used to be called 4ES, but not actually in any known project\n \"5EZ\",\n // Used to be called 5ES, but not actually in any known project\n \"6EZ\",\n // Used to be called 6ES, but not actually in any known project\n \"INT\",\n \"CNC\",\n \"GLO\",\n \"TDX\",\n // 110\n \"NDX\",\n \"DAG\",\n \"PS3\",\n \"2BA\",\n \"LBA\",\n \"JUB\",\n \"ENO\",\n \"1MQ\",\n \"2MQ\",\n \"3MQ\",\n // 120\n \"REP\",\n \"4BA\",\n \"LAO\"\n], B = [\n \"XXA\",\n \"XXB\",\n \"XXC\",\n \"XXD\",\n \"XXE\",\n \"XXF\",\n \"XXG\",\n \"FRT\",\n \"BAK\",\n \"OTH\",\n \"INT\",\n \"CNC\",\n \"GLO\",\n \"TDX\",\n \"NDX\"\n], O = [\n \"Genesis\",\n \"Exodus\",\n \"Leviticus\",\n \"Numbers\",\n \"Deuteronomy\",\n \"Joshua\",\n \"Judges\",\n \"Ruth\",\n \"1 Samuel\",\n \"2 Samuel\",\n \"1 Kings\",\n \"2 Kings\",\n \"1 Chronicles\",\n \"2 Chronicles\",\n \"Ezra\",\n \"Nehemiah\",\n \"Esther (Hebrew)\",\n \"Job\",\n \"Psalms\",\n \"Proverbs\",\n \"Ecclesiastes\",\n \"Song of Songs\",\n \"Isaiah\",\n \"Jeremiah\",\n \"Lamentations\",\n \"Ezekiel\",\n \"Daniel (Hebrew)\",\n \"Hosea\",\n \"Joel\",\n \"Amos\",\n \"Obadiah\",\n \"Jonah\",\n \"Micah\",\n \"Nahum\",\n \"Habakkuk\",\n \"Zephaniah\",\n \"Haggai\",\n \"Zechariah\",\n \"Malachi\",\n \"Matthew\",\n \"Mark\",\n \"Luke\",\n \"John\",\n \"Acts\",\n \"Romans\",\n \"1 Corinthians\",\n \"2 Corinthians\",\n \"Galatians\",\n \"Ephesians\",\n \"Philippians\",\n \"Colossians\",\n \"1 Thessalonians\",\n \"2 Thessalonians\",\n \"1 Timothy\",\n \"2 Timothy\",\n \"Titus\",\n \"Philemon\",\n \"Hebrews\",\n \"James\",\n \"1 Peter\",\n \"2 Peter\",\n \"1 John\",\n \"2 John\",\n \"3 John\",\n \"Jude\",\n \"Revelation\",\n \"Tobit\",\n \"Judith\",\n \"Esther Greek\",\n \"Wisdom of Solomon\",\n \"Sirach (Ecclesiasticus)\",\n \"Baruch\",\n \"Letter of Jeremiah\",\n \"Song of 3 Young Men\",\n \"Susanna\",\n \"Bel and the Dragon\",\n \"1 Maccabees\",\n \"2 Maccabees\",\n \"3 Maccabees\",\n \"4 Maccabees\",\n \"1 Esdras (Greek)\",\n \"2 Esdras (Latin)\",\n \"Prayer of Manasseh\",\n \"Psalm 151\",\n \"Odes\",\n \"Psalms of Solomon\",\n // WARNING, if you change the spelling of the *obsolete* tag be sure to update\n // IsObsolete routine\n \"Joshua A. *obsolete*\",\n \"Judges B. *obsolete*\",\n \"Tobit S. *obsolete*\",\n \"Susanna Th. *obsolete*\",\n \"Daniel Th. *obsolete*\",\n \"Bel Th. *obsolete*\",\n \"Extra A\",\n \"Extra B\",\n \"Extra C\",\n \"Extra D\",\n \"Extra E\",\n \"Extra F\",\n \"Extra G\",\n \"Front Matter\",\n \"Back Matter\",\n \"Other Matter\",\n \"3 Ezra *obsolete*\",\n \"Apocalypse of Ezra\",\n \"5 Ezra (Latin Prologue)\",\n \"6 Ezra (Latin Epilogue)\",\n \"Introduction\",\n \"Concordance \",\n \"Glossary \",\n \"Topical Index\",\n \"Names Index\",\n \"Daniel Greek\",\n \"Psalms 152-155\",\n \"2 Baruch (Apocalypse)\",\n \"Letter of Baruch\",\n \"Jubilees\",\n \"Enoch\",\n \"1 Meqabyan\",\n \"2 Meqabyan\",\n \"3 Meqabyan\",\n \"Reproof (Proverbs 25-31)\",\n \"4 Baruch (Rest of Baruch)\",\n \"Laodiceans\"\n], S = K();\nfunction g(t, e = !0) {\n return e && (t = t.toUpperCase()), t in S ? S[t] : 0;\n}\nfunction k(t) {\n return g(t) > 0;\n}\nfunction x(t) {\n const e = typeof t == \"string\" ? g(t) : t;\n return e >= 40 && e <= 66;\n}\nfunction T(t) {\n return (typeof t == \"string\" ? g(t) : t) <= 39;\n}\nfunction X(t) {\n return t <= 66;\n}\nfunction V(t) {\n const e = typeof t == \"string\" ? g(t) : t;\n return w(e) && !X(e);\n}\nfunction* L() {\n for (let t = 1; t <= N.length; t++) yield t;\n}\nconst G = 1, A = N.length;\nfunction H() {\n return [\"XXA\", \"XXB\", \"XXC\", \"XXD\", \"XXE\", \"XXF\", \"XXG\"];\n}\nfunction C(t, e = \"***\") {\n const s = t - 1;\n return s < 0 || s >= N.length ? e : N[s];\n}\nfunction I(t) {\n return t <= 0 || t > A ? \"******\" : O[t - 1];\n}\nfunction y(t) {\n return I(g(t));\n}\nfunction w(t) {\n const e = typeof t == \"number\" ? C(t) : t;\n return k(e) && !B.includes(e);\n}\nfunction q(t) {\n const e = typeof t == \"number\" ? C(t) : t;\n return k(e) && B.includes(e);\n}\nfunction U(t) {\n return O[t - 1].includes(\"*obsolete*\");\n}\nfunction K() {\n const t = {};\n for (let e = 0; e < N.length; e++)\n t[N[e]] = e + 1;\n return t;\n}\nconst m = {\n allBookIds: N,\n nonCanonicalIds: B,\n bookIdToNumber: g,\n isBookIdValid: k,\n isBookNT: x,\n isBookOT: T,\n isBookOTNT: X,\n isBookDC: V,\n allBookNumbers: L,\n firstBook: G,\n lastBook: A,\n extraBooks: H,\n bookNumberToId: C,\n bookNumberToEnglishName: I,\n bookIdToEnglishName: y,\n isCanonical: w,\n isExtraMaterial: q,\n isObsolete: U\n};\nvar l = /* @__PURE__ */ ((t) => (t[t.Unknown = 0] = \"Unknown\", t[t.Original = 1] = \"Original\", t[t.Septuagint = 2] = \"Septuagint\", t[t.Vulgate = 3] = \"Vulgate\", t[t.English = 4] = \"English\", t[t.RussianProtestant = 5] = \"RussianProtestant\", t[t.RussianOrthodox = 6] = \"RussianOrthodox\", t))(l || {});\nconst h = class h {\n // private versInfo: Versification;\n constructor(e) {\n n(this, \"name\");\n n(this, \"fullPath\");\n n(this, \"isPresent\");\n n(this, \"hasVerseSegments\");\n n(this, \"isCustomized\");\n n(this, \"baseVersification\");\n n(this, \"scriptureBooks\");\n n(this, \"_type\");\n if (e == null)\n throw new Error(\"Argument undefined\");\n typeof e == \"string\" ? (this.name = e, this._type = l[e]) : (this._type = e, this.name = l[e]);\n }\n get type() {\n return this._type;\n }\n equals(e) {\n return !e.type || !this.type ? !1 : e.type === this.type;\n }\n};\nn(h, \"Original\", new h(l.Original)), n(h, \"Septuagint\", new h(l.Septuagint)), n(h, \"Vulgate\", new h(l.Vulgate)), n(h, \"English\", new h(l.English)), n(h, \"RussianProtestant\", new h(l.RussianProtestant)), n(h, \"RussianOrthodox\", new h(l.RussianOrthodox));\nlet c = h;\nfunction E(t, e) {\n const s = e[0];\n for (let r = 1; r < e.length; r++)\n t = t.split(e[r]).join(s);\n return t.split(s);\n}\nvar D = /* @__PURE__ */ ((t) => (t[t.Valid = 0] = \"Valid\", t[t.UnknownVersification = 1] = \"UnknownVersification\", t[t.OutOfRange = 2] = \"OutOfRange\", t[t.VerseOutOfOrder = 3] = \"VerseOutOfOrder\", t[t.VerseRepeated = 4] = \"VerseRepeated\", t))(D || {});\nconst i = class i {\n constructor(e, s, r, a) {\n /** Not yet implemented. */\n n(this, \"firstChapter\");\n /** Not yet implemented. */\n n(this, \"lastChapter\");\n /** Not yet implemented. */\n n(this, \"lastVerse\");\n /** Not yet implemented. */\n n(this, \"hasSegmentsDefined\");\n /** Not yet implemented. */\n n(this, \"text\");\n /** Not yet implemented. */\n n(this, \"BBBCCCVVVS\");\n /** Not yet implemented. */\n n(this, \"longHashCode\");\n /** The versification of the reference. */\n n(this, \"versification\");\n n(this, \"rtlMark\", \"‏\");\n n(this, \"_bookNum\", 0);\n n(this, \"_chapterNum\", 0);\n n(this, \"_verseNum\", 0);\n n(this, \"_verse\");\n if (r == null && a == null)\n if (e != null && typeof e == \"string\") {\n const o = e, u = s != null && s instanceof c ? s : void 0;\n this.setEmpty(u), this.parse(o);\n } else if (e != null && typeof e == \"number\") {\n const o = s != null && s instanceof c ? s : void 0;\n this.setEmpty(o), this._verseNum = e % i.chapterDigitShifter, this._chapterNum = Math.floor(\n e % i.bookDigitShifter / i.chapterDigitShifter\n ), this._bookNum = Math.floor(e / i.bookDigitShifter);\n } else if (s == null)\n if (e != null && e instanceof i) {\n const o = e;\n this._bookNum = o.bookNum, this._chapterNum = o.chapterNum, this._verseNum = o.verseNum, this._verse = o.verse, this.versification = o.versification;\n } else {\n if (e == null) return;\n const o = e instanceof c ? e : i.defaultVersification;\n this.setEmpty(o);\n }\n else\n throw new Error(\"VerseRef constructor not supported.\");\n else if (e != null && s != null && r != null)\n if (typeof e == \"string\" && typeof s == \"string\" && typeof r == \"string\")\n this.setEmpty(a), this.updateInternal(e, s, r);\n else if (typeof e == \"number\" && typeof s == \"number\" && typeof r == \"number\")\n this._bookNum = e, this._chapterNum = s, this._verseNum = r, this.versification = a ?? i.defaultVersification;\n else\n throw new Error(\"VerseRef constructor not supported.\");\n else\n throw new Error(\"VerseRef constructor not supported.\");\n }\n /**\n * Determines if the verse string is in a valid format (does not consider versification).\n */\n static isVerseParseable(e) {\n return e.length > 0 && \"0123456789\".includes(e[0]) && !e.endsWith(this.verseRangeSeparator) && !e.endsWith(this.verseSequenceIndicator);\n }\n /**\n * Tries to parse the specified string into a verse reference.\n * @param str - The string to attempt to parse.\n * @returns success: `true` if the specified string was successfully parsed, `false` otherwise.\n * @returns verseRef: The result of the parse if successful, or empty VerseRef if it failed\n */\n static tryParse(e) {\n let s;\n try {\n return s = new i(e), { success: !0, verseRef: s };\n } catch (r) {\n if (r instanceof v)\n return s = new i(), { success: !1, verseRef: s };\n throw r;\n }\n }\n /**\n * Gets the reference as a comparable integer where the book, chapter, and verse each occupy 3\n * digits.\n * @param bookNum - Book number (this is 1-based, not an index).\n * @param chapterNum - Chapter number.\n * @param verseNum - Verse number.\n * @returns The reference as a comparable integer where the book, chapter, and verse each occupy 3\n * digits.\n */\n static getBBBCCCVVV(e, s, r) {\n return e % i.bcvMaxValue * i.bookDigitShifter + (s >= 0 ? s % i.bcvMaxValue * i.chapterDigitShifter : 0) + (r >= 0 ? r % i.bcvMaxValue : 0);\n }\n /**\n * Deserializes a serialized VerseRef.\n * @param serializedVerseRef - Serialized VerseRef to create from.\n * @returns the deserialized VerseRef.\n */\n static fromJSON(e) {\n const { book: s, chapterNum: r, verseNum: a, verse: o, versificationStr: u } = e, f = o || a.toString();\n let d;\n return u && (d = new c(u)), s ? new i(s, r.toString(), f, d) : new i();\n }\n /**\n * Parses a verse string and gets the leading numeric portion as a number.\n * @param verseStr - verse string to parse\n * @returns true if the entire string could be parsed as a single, simple verse number (1-999);\n * false if the verse string represented a verse bridge, contained segment letters, or was invalid\n */\n static tryGetVerseNum(e) {\n let s;\n if (!e)\n return s = -1, { success: !0, vNum: s };\n s = 0;\n let r;\n for (let a = 0; a < e.length; a++) {\n if (r = e[a], r < \"0\" || r > \"9\")\n return a === 0 && (s = -1), { success: !1, vNum: s };\n if (s = s * 10 + +r - 0, s > i.bcvMaxValue)\n return s = -1, { success: !1, vNum: s };\n }\n return { success: !0, vNum: s };\n }\n /**\n * Checks to see if a VerseRef hasn't been set - all values are the default.\n */\n get isDefault() {\n return this.bookNum === 0 && this.chapterNum === 0 && this.verseNum === 0 && this.versification == null;\n }\n /**\n * Gets whether the verse contains multiple verses.\n */\n get hasMultiple() {\n return this._verse != null && (this._verse.includes(i.verseRangeSeparator) || this._verse.includes(i.verseSequenceIndicator));\n }\n /**\n * Gets or sets the book of the reference. Book is the 3-letter abbreviation in capital letters,\n * e.g. `'MAT'`.\n */\n get book() {\n return m.bookNumberToId(this.bookNum, \"\");\n }\n set book(e) {\n this.bookNum = m.bookIdToNumber(e);\n }\n /**\n * Gets or sets the chapter of the reference,. e.g. `'3'`.\n */\n get chapter() {\n return this.isDefault || this._chapterNum < 0 ? \"\" : this._chapterNum.toString();\n }\n set chapter(e) {\n const s = +e;\n this._chapterNum = Number.isInteger(s) ? s : -1;\n }\n /**\n * Gets or sets the verse of the reference, including range, segments, and sequences, e.g. `'4'`,\n * or `'4b-5a, 7'`.\n */\n get verse() {\n return this._verse != null ? this._verse : this.isDefault || this._verseNum < 0 ? \"\" : this._verseNum.toString();\n }\n set verse(e) {\n const { success: s, vNum: r } = i.tryGetVerseNum(e);\n this._verse = s ? void 0 : e.replace(this.rtlMark, \"\"), this._verseNum = r, !(this._verseNum >= 0) && ({ vNum: this._verseNum } = i.tryGetVerseNum(this._verse));\n }\n /**\n * Get or set Book based on book number, e.g. `42`.\n */\n get bookNum() {\n return this._bookNum;\n }\n set bookNum(e) {\n if (e <= 0 || e > m.lastBook)\n throw new v(\n \"BookNum must be greater than zero and less than or equal to last book\"\n );\n this._bookNum = e;\n }\n /**\n * Gets or sets the chapter number, e.g. `3`. `-1` if not valid.\n */\n get chapterNum() {\n return this._chapterNum;\n }\n set chapterNum(e) {\n this.chapterNum = e;\n }\n /**\n * Gets or sets verse start number, e.g. `4`. `-1` if not valid.\n */\n get verseNum() {\n return this._verseNum;\n }\n set verseNum(e) {\n this._verseNum = e;\n }\n /**\n * String representing the versification (should ONLY be used for serialization/deserialization).\n *\n * @remarks This is for backwards compatibility when ScrVers was an enumeration.\n */\n get versificationStr() {\n var e;\n return (e = this.versification) == null ? void 0 : e.name;\n }\n set versificationStr(e) {\n this.versification = this.versification != null ? new c(e) : void 0;\n }\n /**\n * Determines if the reference is valid.\n */\n get valid() {\n return this.validStatus === 0;\n }\n /**\n * Get the valid status for this reference.\n */\n get validStatus() {\n return this.validateVerse(i.verseRangeSeparators, i.verseSequenceIndicators);\n }\n /**\n * Gets the reference as a comparable integer where the book,\n * chapter, and verse each occupy three digits and the verse is 0.\n */\n get BBBCCC() {\n return i.getBBBCCCVVV(this._bookNum, this._chapterNum, 0);\n }\n /**\n * Gets the reference as a comparable integer where the book,\n * chapter, and verse each occupy three digits. If verse is not null\n * (i.e., this reference represents a complex reference with verse\n * segments or bridge) this cannot be used for an exact comparison.\n */\n get BBBCCCVVV() {\n return i.getBBBCCCVVV(this._bookNum, this._chapterNum, this._verseNum);\n }\n /**\n * Gets whether the verse is defined as an excluded verse in the versification.\n * Does not handle verse ranges.\n */\n // eslint-disable-next-line @typescript-eslint/class-literal-property-style\n get isExcluded() {\n return !1;\n }\n /**\n * Parses the reference in the specified string.\n * Optionally versification can follow reference as in GEN 3:11/4\n * Throw an exception if\n * - invalid book name\n * - chapter number is missing or not a number\n * - verse number is missing or does not start with a number\n * - versification is invalid\n * @param verseStr - string to parse e.g. 'MAT 3:11'\n */\n parse(e) {\n if (e = e.replace(this.rtlMark, \"\"), e.includes(\"/\")) {\n const o = e.split(\"/\");\n if (e = o[0], o.length > 1)\n try {\n const u = +o[1].trim();\n this.versification = new c(l[u]);\n } catch {\n throw new v(\"Invalid reference : \" + e);\n }\n }\n const s = e.trim().split(\" \");\n if (s.length !== 2)\n throw new v(\"Invalid reference : \" + e);\n const r = s[1].split(\":\"), a = +r[0];\n if (r.length !== 2 || m.bookIdToNumber(s[0]) === 0 || !Number.isInteger(a) || a < 0 || !i.isVerseParseable(r[1]))\n throw new v(\"Invalid reference : \" + e);\n this.updateInternal(s[0], r[0], r[1]);\n }\n /**\n * Simplifies this verse ref so that it has no bridging of verses or\n * verse segments like `'1a'`.\n */\n simplify() {\n this._verse = void 0;\n }\n /**\n * Makes a clone of the reference.\n *\n * @returns The cloned VerseRef.\n */\n clone() {\n return new i(this);\n }\n toString() {\n const e = this.book;\n return e === \"\" ? \"\" : `${e} ${this.chapter}:${this.verse}`;\n }\n toJSON() {\n let e = this.verse;\n (e === \"\" || e === this.verseNum.toString()) && (e = void 0);\n const s = {\n book: this.book,\n chapterNum: this.chapterNum,\n verseNum: this.verseNum,\n verse: e,\n versificationStr: this.versificationStr\n };\n return e || delete s.verse, s;\n }\n /**\n * Compares this `VerseRef` with supplied one.\n * @param verseRef - object to compare this one to.\n * @returns `true` if this `VerseRef` is equal to the supplied one, `false` otherwise.\n */\n equals(e) {\n return e instanceof i ? e._bookNum === this._bookNum && e._chapterNum === this._chapterNum && e._verseNum === this._verseNum && e.verse === this.verse && (e.versification == null && this.versification == null || e.versification != null && this.versification != null && e.versification.equals(this.versification)) : !1;\n }\n /**\n * Enumerate all individual verses contained in a VerseRef.\n * Verse ranges are indicated by \"-\" and consecutive verses by \",\"s.\n * Examples:\n * GEN 1:2 returns GEN 1:2\n * GEN 1:1a-3b,5 returns GEN 1:1a, GEN 1:2, GEN 1:3b, GEN 1:5\n * GEN 1:2a-2c returns //! ??????\n *\n * @param specifiedVersesOnly - if set to true return only verses that are\n * explicitly specified only, not verses within a range. Defaults to `false`.\n * @param verseRangeSeparators - Verse range separators.\n * Defaults to `VerseRef.verseRangeSeparators`.\n * @param verseSequenceSeparators - Verse sequence separators.\n * Defaults to `VerseRef.verseSequenceIndicators`.\n * @returns An array of all single verse references in this VerseRef.\n */\n allVerses(e = !1, s = i.verseRangeSeparators, r = i.verseSequenceIndicators) {\n if (this._verse == null || this.chapterNum <= 0)\n return [this.clone()];\n const a = [], o = E(this._verse, r);\n for (const u of o.map((f) => E(f, s))) {\n const f = this.clone();\n f.verse = u[0];\n const d = f.verseNum;\n if (a.push(f), u.length > 1) {\n const b = this.clone();\n if (b.verse = u[1], !e)\n for (let p = d + 1; p < b.verseNum; p++) {\n const J = new i(\n this._bookNum,\n this._chapterNum,\n p,\n this.versification\n );\n this.isExcluded || a.push(J);\n }\n a.push(b);\n }\n }\n return a;\n }\n /**\n * Validates a verse number using the supplied separators rather than the defaults.\n */\n validateVerse(e, s) {\n if (!this.verse)\n return this.internalValid;\n let r = 0;\n for (const a of this.allVerses(!0, e, s)) {\n const o = a.internalValid;\n if (o !== 0)\n return o;\n const u = a.BBBCCCVVV;\n if (r > u)\n return 3;\n if (r === u)\n return 4;\n r = u;\n }\n return 0;\n }\n /**\n * Gets whether a single verse reference is valid.\n */\n get internalValid() {\n return this.versification == null ? 1 : this._bookNum <= 0 || this._bookNum > m.lastBook ? 2 : (m.isCanonical(this._bookNum), 0);\n }\n setEmpty(e = i.defaultVersification) {\n this._bookNum = 0, this._chapterNum = -1, this._verse = void 0, this.versification = e;\n }\n updateInternal(e, s, r) {\n this.bookNum = m.bookIdToNumber(e), this.chapter = s, this.verse = r;\n }\n};\nn(i, \"defaultVersification\", c.English), n(i, \"verseRangeSeparator\", \"-\"), n(i, \"verseSequenceIndicator\", \",\"), n(i, \"verseRangeSeparators\", [i.verseRangeSeparator]), n(i, \"verseSequenceIndicators\", [i.verseSequenceIndicator]), n(i, \"chapterDigitShifter\", 1e3), n(i, \"bookDigitShifter\", i.chapterDigitShifter * i.chapterDigitShifter), n(i, \"bcvMaxValue\", i.chapterDigitShifter - 1), /**\n * The valid status of the VerseRef.\n */\nn(i, \"ValidStatusType\", D);\nlet M = i;\nclass v extends Error {\n}\nexport {\n _ as BookSet,\n m as Canon,\n c as ScrVers,\n l as ScrVersType,\n M as VerseRef,\n v as VerseRefException\n};\n//# sourceMappingURL=index.es.js.map\n","import React from 'react';\nimport * as DropdownMenuPrimitive from '@radix-ui/react-dropdown-menu';\nimport { Check, ChevronRight, Circle } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport const DropdownMenu = DropdownMenuPrimitive.Root;\n\nexport const DropdownMenuTrigger = DropdownMenuPrimitive.Trigger;\n\nexport const DropdownMenuGroup = DropdownMenuPrimitive.Group;\n\nexport const DropdownMenuPortal = DropdownMenuPrimitive.Portal;\n\nexport const DropdownMenuSub = DropdownMenuPrimitive.Sub;\n\nexport const DropdownMenuRadioGroup = DropdownMenuPrimitive.RadioGroup;\n\nexport type DropdownMenuSubTriggerProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.SubTrigger\n> & {\n className?: string;\n inset?: boolean;\n};\n\nexport type DropdownMenuSubContentProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.SubContent\n> & {\n className?: string;\n};\n\nexport type DropdownMenuContentProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Content\n> & {\n className?: string;\n sideOffset?: number;\n};\n\nexport type DropdownMenuItemProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Item\n> & {\n className?: string;\n inset?: boolean;\n};\n\nexport type DropdownMenuCheckboxItemProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.CheckboxItem\n> & {\n className?: string;\n checked?: boolean;\n};\n\nexport type DropdownMenuRadioItemProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.RadioItem\n> & {\n className?: string;\n};\n\nexport type DropdownMenuLabelProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Label\n> & {\n className?: string;\n inset?: boolean;\n};\n\nexport type DropdownMenuSeparatorProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Separator\n> & {\n className?: string;\n};\n\nexport type DropdownMenuShortcutProps = React.HTMLAttributes & {\n className?: string;\n};\n\nexport const DropdownMenuSubTrigger = React.forwardRef<\n React.ElementRef,\n DropdownMenuSubTriggerProps\n>(({ className, inset, children, ...props }, ref) => (\n \n {children}\n \n \n));\nDropdownMenuSubTrigger.displayName = DropdownMenuPrimitive.SubTrigger.displayName;\n\nexport const DropdownMenuSubContent = React.forwardRef<\n React.ElementRef,\n DropdownMenuSubContentProps\n>(({ className, ...props }, ref) => (\n \n));\nDropdownMenuSubContent.displayName = DropdownMenuPrimitive.SubContent.displayName;\n\nexport const DropdownMenuContent = React.forwardRef<\n React.ElementRef,\n DropdownMenuContentProps\n>(({ className, sideOffset = 4, ...props }, ref) => (\n \n \n \n));\nDropdownMenuContent.displayName = DropdownMenuPrimitive.Content.displayName;\n\n/**\n * TODO: fix: direction is not automatically handled by this component, so that shortcuts are\n * display always to the right\n */\nexport const DropdownMenuItem = React.forwardRef<\n React.ElementRef,\n DropdownMenuItemProps\n>(({ className, inset, ...props }, ref) => (\n \n));\nDropdownMenuItem.displayName = DropdownMenuPrimitive.Item.displayName;\n\nexport const DropdownMenuCheckboxItem = React.forwardRef<\n React.ElementRef,\n DropdownMenuCheckboxItemProps\n>(({ className, children, checked, ...props }, ref) => (\n \n \n \n \n \n \n {children}\n \n));\nDropdownMenuCheckboxItem.displayName = DropdownMenuPrimitive.CheckboxItem.displayName;\n\nexport const DropdownMenuRadioItem = React.forwardRef<\n React.ElementRef,\n DropdownMenuRadioItemProps\n>(({ className, children, ...props }, ref) => (\n \n \n \n \n \n \n {children}\n \n));\nDropdownMenuRadioItem.displayName = DropdownMenuPrimitive.RadioItem.displayName;\n\nexport const DropdownMenuLabel = React.forwardRef<\n React.ElementRef,\n DropdownMenuLabelProps\n>(({ className, inset, ...props }, ref) => (\n \n));\nDropdownMenuLabel.displayName = DropdownMenuPrimitive.Label.displayName;\n\nexport const DropdownMenuSeparator = React.forwardRef<\n React.ElementRef,\n DropdownMenuSeparatorProps\n>(({ className, ...props }, ref) => (\n \n));\nDropdownMenuSeparator.displayName = DropdownMenuPrimitive.Separator.displayName;\n\nexport function DropdownMenuShortcut({ className, ...props }: DropdownMenuShortcutProps) {\n return (\n \n );\n}\nDropdownMenuShortcut.displayName = 'DropdownMenuShortcut';\n","import { Canon } from '@sillsdev/scripture';\nimport { PropsWithChildren, KeyboardEvent, forwardRef } from 'react';\nimport { DropdownMenuItem as ShadDropdownMenuItem } from '@/components/shadcn-ui/dropdown-menu';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport type BookType = 'OT' | 'NT' | 'DC';\n\ntype BookMenuItemProps = PropsWithChildren<{\n /** String id of book */\n bookId: string;\n /** Callback to run when a book menu item is selected */\n handleSelectBook: () => void;\n /** Indicates if this menu item is currently selected */\n isSelected: boolean;\n /** Function that is called upon highlighting a book in the dropdown menu */\n handleHighlightBook: () => void;\n /**\n * Function that is called on pressing a key\n *\n * @param event Event that contains information about the key stroke\n */\n handleKeyDown: (event: KeyboardEvent) => void;\n /**\n * Type of book associated with this menu item, coordinates color labels ? Mock up has the labels\n * coordinated to genre\n */\n bookType: BookType;\n}>;\n\nconst BookMenuItem = forwardRef(\n (\n {\n bookId,\n handleSelectBook,\n isSelected,\n handleHighlightBook,\n handleKeyDown,\n bookType,\n children,\n }: BookMenuItemProps,\n ref,\n ) => {\n return (\n {\n // preventDefault() here prevents the entire dropdown menu from closing when selecting this item\n event.preventDefault();\n handleSelectBook();\n }}\n onKeyDown={(event: KeyboardEvent) => {\n handleKeyDown(event);\n }}\n onFocus={handleHighlightBook}\n onMouseMove={handleHighlightBook}\n >\n \n {Canon.bookIdToEnglishName(bookId)}\n \n {isSelected &&
    {children}
    }\n \n );\n },\n);\n\nexport default BookMenuItem;\n","import { cn } from '@/utils/shadcn-ui.util';\nimport { useCallback } from 'react';\n\nexport type ChapterSelectProps = {\n /**\n * Callback to run when a chapter div is selected\n *\n * @param chapterNumber Number of the chapter that has been selected\n */\n handleSelectChapter: (chapterNumber: number) => void;\n /** The highest chapter number in the book (of course equal to number of chapters in the book) */\n endChapter: number;\n /** The chapter number that is currently selected */\n activeChapter: number;\n /** The chapter number that is currently highlighted using keyboard or mouse navigation */\n highlightedChapter: number;\n /**\n * Callback to run when a chapter is highlighted by the user\n *\n * @param chapterNumber The chapter that is highlighted\n */\n handleHighlightedChapter: (chapterNumber: number) => void;\n};\n\nfunction ChapterSelect({\n handleSelectChapter,\n endChapter,\n activeChapter,\n highlightedChapter,\n handleHighlightedChapter,\n}: ChapterSelectProps) {\n const chapters = Array.from({ length: endChapter }, (_, i) => i + 1);\n\n const handleMouse = useCallback(\n (chapterNumber: number) => {\n handleHighlightedChapter(chapterNumber);\n },\n [handleHighlightedChapter],\n );\n\n return (\n
    \n {chapters.map((chapter) => (\n {\n event.preventDefault();\n event.stopPropagation();\n handleSelectChapter(chapter);\n }}\n role=\"button\"\n onKeyDown={(event) => {\n if (event.key === 'Enter') {\n handleSelectChapter(chapter);\n }\n }}\n tabIndex={0}\n onMouseMove={() => handleMouse(chapter)}\n >\n {chapter}\n
    \n ))}\n
    \n );\n}\n\nexport default ChapterSelect;\n","import { DropdownMenuLabel as ShadDropdownMenuLabel } from '@/components/shadcn-ui/dropdown-menu';\nimport { Bookmark, Clock, ArrowDownWideNarrow } from 'lucide-react';\n\nexport type GoToMenuItemProps = {\n handleSort: () => void;\n handleLocationHistory: () => void;\n handleBookmarks: () => void;\n};\n\nfunction GoToMenuItem({ handleSort, handleLocationHistory, handleBookmarks }: GoToMenuItemProps) {\n return (\n \n

    Go To

    \n
    \n \n \n \n
    \n
    \n );\n}\n\nexport default GoToMenuItem;\n","import BookChapterInput from '@/components/advanced/book-chapter-control/book-chapter-input.component';\nimport BookMenuItem, {\n BookType,\n} from '@/components/advanced/book-chapter-control/book-menu-item.component';\nimport ChapterSelect from '@/components/advanced/book-chapter-control/chapter-select.component';\nimport GoToMenuItem from '@/components/advanced/book-chapter-control/go-to-menu-item.component';\nimport {\n DropdownMenu as ShadDropdownMenu,\n DropdownMenuContent as ShadDropdownMenuContent,\n DropdownMenuLabel as ShadDropdownMenuLabel,\n DropdownMenuSeparator as ShadDropdownMenuSeparator,\n DropdownMenuTrigger as ShadDropdownMenuTrigger,\n} from '@/components/shadcn-ui/dropdown-menu';\nimport { Canon } from '@sillsdev/scripture';\nimport { ScriptureReference, getChaptersForBook } from 'platform-bible-utils';\nimport {\n KeyboardEvent as ReactKeyboardEvent,\n useCallback,\n useEffect,\n useLayoutEffect,\n useRef,\n useState,\n} from 'react';\n\ntype BookTypeLabels = {\n [bookType in BookType]: string;\n};\ntype BookChapterControlProps = {\n scrRef: ScriptureReference;\n handleSubmit: (scrRef: ScriptureReference) => void;\n};\n\nconst ALL_BOOK_IDS = Canon.allBookIds;\nconst BOOK_TYPE_LABELS: BookTypeLabels = {\n OT: 'Old Testament',\n NT: 'New Testament',\n DC: 'Deuterocanon',\n};\nconst BOOK_TYPE_ARRAY: BookType[] = ['OT', 'NT', 'DC'];\n// This is the height of three menu items to offset scrolling to the selected menu item\n// If you use menuItemRef.clientHeight- includes height of chapter div which is too big\nconst SCROLL_OFFSET = 32 + 32 + 32;\nconst SEARCH_QUERY_FORMATS = [\n /^(\\w+)$/i, // Matches a single word (book name or id)\n /^(\\w+)(?:\\s(\\d+))$/i, // Matches a word followed by a chapter number\n /^(\\w+)(?:\\s(\\d+):(\\d+))$/i, // Matches a word followed by a chapter and verse number\n];\nconst fetchGroupedBooks = (bookType: BookType) => {\n const groupedBooks = {\n OT: ALL_BOOK_IDS.filter((bookId) => Canon.isBookOT(bookId)),\n NT: ALL_BOOK_IDS.filter((bookId) => Canon.isBookNT(bookId)),\n DC: ALL_BOOK_IDS.filter((bookId) => Canon.isBookDC(bookId)),\n };\n return groupedBooks[bookType];\n};\nconst fetchEndChapter = (bookId: string) => {\n // getChaptersForBook returns -1 if not found in scrBookData\n // scrBookData only includes OT and NT, so all DC will return -1\n return getChaptersForBook(Canon.bookIdToNumber(bookId));\n};\n\n/**\n * Gets all of the English names from book ids\n *\n * @returns String[]\n */\nfunction getAllEnglishNames(): string[] {\n const allEnglishNames = ALL_BOOK_IDS.map((bookId) => {\n return Canon.bookIdToEnglishName(bookId);\n });\n return allEnglishNames;\n}\n\n/**\n * Determines if bookName is in allEnglishNames\n *\n * @param bookName Book English name\n * @returns True if bookName is included, false otherwise\n */\nfunction isValidBookEnglishName(bookName: string): boolean {\n return getAllEnglishNames().includes(bookName);\n}\n\n/**\n * Gets a bookId from given English name\n *\n * @param bookName Book English name\n * @returns BookId of provided bookName, undefined otherwise\n */\nfunction getBookIdFromEnglishName(bookName: string): string | undefined {\n // Convert bookName to lowercase and then capitalize the first letter\n const formattedBookName = bookName.toLowerCase().replace(/^\\w/, (c) => c.toUpperCase());\n\n if (isValidBookEnglishName(formattedBookName)) {\n const matchingBookId = ALL_BOOK_IDS.find((bookId) => {\n return Canon.bookIdToEnglishName(bookId) === formattedBookName;\n });\n return matchingBookId;\n }\n\n return undefined;\n}\n\nfunction BookChapterControl({ scrRef, handleSubmit }: BookChapterControlProps) {\n const [searchQuery, setSearchQuery] = useState('');\n const [selectedBookId, setSelectedBookId] = useState(\n Canon.bookNumberToId(scrRef.bookNum),\n );\n const [highlightedChapter, setHighlightedChapter] = useState(scrRef.chapterNum ?? 0);\n const [highlightedBookId, setHighlightedBookId] = useState(\n Canon.bookNumberToId(scrRef.bookNum),\n );\n const [isContentOpen, setIsContentOpen] = useState(false);\n const [isContentOpenDelayed, setIsContentOpenDelayed] = useState(isContentOpen);\n\n // This ref will always be defined\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const inputRef = useRef(undefined!);\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const contentRef = useRef(undefined!);\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const menuItemRef = useRef(undefined!);\n\n const fetchFilteredBooks = useCallback(\n (bookType: BookType) => {\n return fetchGroupedBooks(bookType).filter((bookId: string) => {\n const englishNameLowerCase = Canon.bookIdToEnglishName(bookId).toLowerCase();\n const normalizedQuery = searchQuery.replace(/[^a-zA-Z]/g, '').toLowerCase();\n return (\n englishNameLowerCase.includes(normalizedQuery) || // Match book name\n bookId.toLowerCase().includes(normalizedQuery) // Match book ID\n );\n });\n },\n [searchQuery],\n );\n\n const handleSearchInput = (searchString: string) => {\n setSearchQuery(searchString);\n };\n\n /**\n * Whether to prevent radix's logic from closing the dropdown. This is important because radix\n * tries to close the dropdown when the input first focuses, and we don't want it to do that. But\n * we don't want to prevent the dropdown from closing when we click away from the input, so we\n * don't want to just keep it open if the input is focused\n */\n const shouldPreventAutoClosing = useRef(false);\n\n const controlMenuState = useCallback((open: boolean) => {\n if (shouldPreventAutoClosing.current) {\n shouldPreventAutoClosing.current = false;\n return;\n }\n setIsContentOpen(open);\n }, []);\n\n const updateReference = useCallback(\n (bookId: string, shouldClose: boolean, chapter?: number, verse?: number) => {\n setHighlightedChapter(\n Canon.bookNumberToId(scrRef.bookNum) !== bookId ? 1 : scrRef.chapterNum,\n );\n\n if (shouldClose || fetchEndChapter(bookId) === -1) {\n handleSubmit({\n bookNum: Canon.bookIdToNumber(bookId),\n chapterNum: chapter || 1,\n verseNum: verse || 1,\n });\n\n setIsContentOpen(false);\n setSearchQuery('');\n return;\n }\n\n setSelectedBookId(selectedBookId !== bookId ? bookId : '');\n setIsContentOpen(!shouldClose);\n },\n [handleSubmit, scrRef.bookNum, scrRef.chapterNum, selectedBookId],\n );\n\n const handleSelectChapter = (chapterNumber: number) => {\n if (chapterNumber <= 0 || chapterNumber > fetchEndChapter(selectedBookId)) {\n return;\n }\n updateReference(selectedBookId, true, chapterNumber);\n };\n\n const handleInputSubmit = useCallback(() => {\n SEARCH_QUERY_FORMATS.forEach((format) => {\n const matches = searchQuery.match(format);\n if (matches) {\n // Book should be a bookId or an english name\n const [book, chapter = undefined, verse = undefined] = matches.slice(1);\n const englishName = getBookIdFromEnglishName(book);\n\n if (Canon.isBookIdValid(book) || englishName) {\n updateReference(\n englishName ?? book,\n true,\n chapter ? parseInt(chapter, 10) : 1,\n verse ? parseInt(verse, 10) : 1,\n );\n }\n }\n });\n }, [updateReference, searchQuery]);\n\n const handleKeyDownInput = useCallback(\n (event: ReactKeyboardEvent) => {\n if (!isContentOpen) {\n setIsContentOpen(true);\n } else if (event.key === 'ArrowDown' || event.key === 'ArrowUp') {\n if (\n typeof menuItemRef !== 'undefined' &&\n // Ref uses null\n // eslint-disable-next-line no-null/no-null\n menuItemRef.current !== null\n ) {\n menuItemRef.current.focus();\n } else if (\n typeof contentRef !== 'undefined' &&\n // Ref uses null\n // eslint-disable-next-line no-null/no-null\n contentRef.current !== null\n ) {\n contentRef.current.focus();\n }\n event.preventDefault();\n }\n },\n [isContentOpen],\n );\n\n const handleKeyDownContent = (event: ReactKeyboardEvent) => {\n // When the dropdown menu has focus, key strokes should give focus to the input component,\n // unless they're navigation keys (arrows and enter)\n const { key } = event;\n if (\n key === 'ArrowRight' ||\n key === 'ArrowLeft' ||\n key === 'ArrowDown' ||\n key === 'ArrowUp' ||\n key === 'Enter'\n ) {\n return;\n }\n\n inputRef.current.dispatchEvent(new KeyboardEvent('keydown', { key }));\n inputRef.current.focus();\n };\n\n const handleKeyDownMenuItem = (event: ReactKeyboardEvent) => {\n const { key } = event;\n if (highlightedBookId === selectedBookId) {\n if (key === 'Enter') {\n event.preventDefault();\n updateReference(selectedBookId, true, highlightedChapter);\n return;\n }\n\n let chapterOffSet = 0;\n if (key === 'ArrowRight') {\n if (highlightedChapter < fetchEndChapter(highlightedBookId)) {\n chapterOffSet = 1;\n } else {\n event.preventDefault();\n return;\n }\n } else if (key === 'ArrowLeft') {\n if (highlightedChapter > 1) {\n chapterOffSet = -1;\n } else {\n event.preventDefault();\n return;\n }\n } else if (key === 'ArrowDown') {\n chapterOffSet = 6;\n } else if (key === 'ArrowUp') {\n chapterOffSet = -6;\n }\n if (\n highlightedChapter + chapterOffSet <= 0 ||\n highlightedChapter + chapterOffSet > fetchEndChapter(highlightedBookId)\n ) {\n setHighlightedChapter(0);\n } else if (chapterOffSet !== 0) {\n setHighlightedChapter(highlightedChapter + chapterOffSet);\n event.preventDefault();\n }\n }\n };\n\n useEffect(() => {\n if (selectedBookId === highlightedBookId) {\n if (selectedBookId === Canon.bookNumberToId(scrRef.bookNum)) {\n setHighlightedChapter(scrRef.chapterNum);\n } else {\n setHighlightedChapter(1);\n }\n } else {\n setHighlightedChapter(0);\n }\n }, [highlightedBookId, scrRef.bookNum, scrRef.chapterNum, selectedBookId]);\n\n // The purpose of these useLayoutEffects and timeout is to delay the scroll just\n // enough so that the refs are defined and available when they are used after the timeout\n useLayoutEffect(() => {\n setIsContentOpenDelayed(isContentOpen);\n }, [isContentOpen]);\n\n useLayoutEffect(() => {\n const scrollTimeout = setTimeout(() => {\n if (isContentOpenDelayed && contentRef.current && menuItemRef.current) {\n const menuItemOffsetTop = menuItemRef.current.offsetTop;\n const scrollPosition = menuItemOffsetTop - SCROLL_OFFSET;\n contentRef.current.scrollTo({ top: scrollPosition, behavior: 'instant' });\n }\n }, 10);\n return () => {\n clearTimeout(scrollTimeout);\n };\n }, [isContentOpenDelayed]);\n\n return (\n
    \n \n \n {\n setSelectedBookId(Canon.bookNumberToId(scrRef.bookNum));\n setHighlightedBookId(Canon.bookNumberToId(scrRef.bookNum));\n setHighlightedChapter(scrRef.chapterNum > 0 ? scrRef.chapterNum : 0);\n setIsContentOpen(true);\n inputRef.current.focus();\n }}\n onFocus={() => {\n // Radix thinks we want to close because the input is being focused. Prevent that\n shouldPreventAutoClosing.current = true;\n }}\n handleSubmit={handleInputSubmit}\n placeholder={`${Canon.bookNumberToEnglishName(scrRef.bookNum)} ${scrRef.chapterNum}:${scrRef.verseNum}`}\n />\n \n \n console.log('sorting')}\n handleLocationHistory={() => console.log('location history')}\n handleBookmarks={() => console.log('bookmarks')}\n />\n {BOOK_TYPE_ARRAY.map(\n (bookType, bookTypeIndex) =>\n fetchFilteredBooks(bookType).length > 0 && (\n
    \n \n {BOOK_TYPE_LABELS[bookType]}\n \n\n {fetchFilteredBooks(bookType).map((bookId) => (\n
    \n updateReference(bookId, false)}\n isSelected={selectedBookId === bookId}\n handleHighlightBook={() => setHighlightedBookId(bookId)}\n handleKeyDown={handleKeyDownMenuItem}\n bookType={bookType}\n ref={(element: HTMLDivElement) => {\n if (selectedBookId === bookId) menuItemRef.current = element;\n }}\n >\n {\n setHighlightedChapter(chapterNumber);\n }}\n />\n \n
    \n ))}\n {BOOK_TYPE_ARRAY.length - 1 !== bookTypeIndex ? (\n \n ) : undefined}\n
    \n ),\n )}\n \n
    \n
    \n );\n}\n\nexport default BookChapterControl;\n","import React from 'react';\nimport { Slot } from '@radix-ui/react-slot';\nimport { cva, type VariantProps } from 'class-variance-authority';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport const buttonVariants = cva(\n 'pr-twp tw-inline-flex tw-items-center tw-justify-center tw-whitespace-nowrap tw-rounded-md tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-colors focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50',\n {\n variants: {\n variant: {\n default: 'tw-bg-primary tw-text-primary-foreground hover:tw-bg-primary/90',\n destructive: 'tw-bg-destructive tw-text-destructive-foreground hover:tw-bg-destructive/90',\n outline:\n 'tw-border tw-border-input tw-bg-background hover:tw-bg-accent hover:tw-text-accent-foreground',\n secondary: 'tw-bg-secondary tw-text-secondary-foreground hover:tw-bg-secondary/80',\n ghost: 'hover:tw-bg-accent hover:tw-text-accent-foreground',\n link: 'tw-text-primary tw-underline-offset-4 hover:tw-underline',\n },\n size: {\n default: 'tw-h-10 tw-px-4 tw-py-2',\n sm: 'tw-h-9 tw-rounded-md tw-px-3',\n lg: 'tw-h-11 tw-rounded-md tw-px-8',\n icon: 'tw-h-10 tw-w-10',\n },\n },\n defaultVariants: {\n variant: 'default',\n size: 'default',\n },\n },\n);\n\nexport interface ButtonProps\n extends React.ButtonHTMLAttributes,\n VariantProps {\n asChild?: boolean;\n}\n\nexport const Button = React.forwardRef(\n ({ className, variant, size, asChild = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'button';\n return (\n \n );\n },\n);\nButton.displayName = 'Button';\n","import React from 'react';\nimport * as LabelPrimitive from '@radix-ui/react-label';\nimport { cva, type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst labelVariants = cva(\n 'tw-text-sm tw-font-medium tw-leading-none peer-disabled:tw-cursor-not-allowed peer-disabled:tw-opacity-70',\n);\n\nexport const Label = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef & VariantProps\n>(({ className, ...props }, ref) => (\n \n));\nLabel.displayName = LabelPrimitive.Root.displayName;\n","import React from 'react';\nimport * as RadioGroupPrimitive from '@radix-ui/react-radio-group';\nimport { Circle } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst RadioGroup = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => {\n return (\n \n );\n});\nRadioGroup.displayName = RadioGroupPrimitive.Root.displayName;\n\nconst RadioGroupItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => {\n return (\n \n \n \n \n \n );\n});\nRadioGroupItem.displayName = RadioGroupPrimitive.Item.displayName;\n\nexport { RadioGroup, RadioGroupItem };\n","import React from 'react';\nimport * as PopoverPrimitive from '@radix-ui/react-popover';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Popover = PopoverPrimitive.Root;\n\nconst PopoverTrigger = PopoverPrimitive.Trigger;\n\nconst PopoverContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, align = 'center', sideOffset = 4, ...props }, ref) => (\n \n \n \n));\nPopoverContent.displayName = PopoverPrimitive.Content.displayName;\n\nexport { Popover, PopoverTrigger, PopoverContent };\n","import React from 'react';\nimport * as DialogPrimitive from '@radix-ui/react-dialog';\nimport { X } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Dialog = DialogPrimitive.Root;\n\nconst DialogTrigger = DialogPrimitive.Trigger;\n\nconst DialogPortal = DialogPrimitive.Portal;\n\nconst DialogClose = DialogPrimitive.Close;\n\nconst DialogOverlay = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nDialogOverlay.displayName = DialogPrimitive.Overlay.displayName;\n\nconst DialogContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, ...props }, ref) => (\n \n \n \n {children}\n \n \n Close\n \n \n \n));\nDialogContent.displayName = DialogPrimitive.Content.displayName;\n\nfunction DialogHeader({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nDialogHeader.displayName = 'DialogHeader';\n\nfunction DialogFooter({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nDialogFooter.displayName = 'DialogFooter';\n\nconst DialogTitle = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nDialogTitle.displayName = DialogPrimitive.Title.displayName;\n\nconst DialogDescription = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nDialogDescription.displayName = DialogPrimitive.Description.displayName;\n\nexport {\n Dialog,\n DialogPortal,\n DialogOverlay,\n DialogClose,\n DialogTrigger,\n DialogContent,\n DialogHeader,\n DialogFooter,\n DialogTitle,\n DialogDescription,\n};\n","import React from 'react';\nimport { type DialogProps } from '@radix-ui/react-dialog';\nimport { Command as CommandPrimitive } from 'cmdk';\nimport { Search } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Dialog, DialogContent } from '@/components/shadcn-ui/dialog';\n\nconst Command = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nCommand.displayName = CommandPrimitive.displayName;\n\ninterface CommandDialogProps extends DialogProps {}\n\nfunction CommandDialog({ children, ...props }: CommandDialogProps) {\n return (\n \n \n \n {children}\n \n \n \n );\n}\n\nconst CommandInput = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n
    \n \n \n
    \n));\n\nCommandInput.displayName = CommandPrimitive.Input.displayName;\n\nconst CommandList = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\n\nCommandList.displayName = CommandPrimitive.List.displayName;\n\nconst CommandEmpty = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>((props, ref) => (\n \n));\n\nCommandEmpty.displayName = CommandPrimitive.Empty.displayName;\n\nconst CommandGroup = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\n\nCommandGroup.displayName = CommandPrimitive.Group.displayName;\n\nconst CommandSeparator = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nCommandSeparator.displayName = CommandPrimitive.Separator.displayName;\n\nconst CommandItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\n\nCommandItem.displayName = CommandPrimitive.Item.displayName;\n\nfunction CommandShortcut({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nCommandShortcut.displayName = 'CommandShortcut';\n\nexport {\n Command,\n CommandDialog,\n CommandInput,\n CommandList,\n CommandEmpty,\n CommandGroup,\n CommandItem,\n CommandShortcut,\n CommandSeparator,\n};\n","import { useState } from 'react';\nimport { Check, ChevronsUpDown } from 'lucide-react';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport { Popover, PopoverContent, PopoverTrigger } from '@/components/shadcn-ui/popover';\nimport {\n Command,\n CommandEmpty,\n CommandInput,\n CommandItem,\n CommandList,\n} from '@/components/shadcn-ui/command';\nimport { PopoverProps } from '@radix-ui/react-popover';\n\nexport type ComboBoxLabelOption = { label: string };\nexport type ComboBoxOption = string | number | ComboBoxLabelOption;\n\nexport type ComboBoxProps = {\n /** Optional unique identifier */\n id?: string;\n /** Text label title for combobox */\n /** List of available options for the dropdown menu */\n options?: readonly T[];\n /** Additional css classes to help with unique styling of the combo box button */\n buttonClassName?: string;\n /** Additional css classes to help with unique styling of the combo box popover */\n popoverContentClassName?: string;\n /**\n * The selected value that the combo box currently holds. Must be shallow equal to one of the\n * options entries.\n */\n value?: T;\n /** Triggers when content of textfield is changed */\n onChange?: (newValue: T) => void;\n /** Used to determine the string value for a given option. */\n getOptionLabel?: (option: ComboBoxOption) => string;\n /** Text displayed on button if `value` is undefined */\n buttonPlaceholder?: string;\n /** Placeholder text for text field */\n textPlaceholder?: string;\n /** Text to display when no options match input */\n commandEmptyMessage?: string;\n /** Variant of button */\n buttonVariant?: ButtonProps['variant'];\n /** Text direction ltr or rtl */\n dir?: Direction;\n /** Optional boolean to set if trigger should be disabled */\n isDisabled?: boolean;\n} & PopoverProps;\n\ntype Direction = 'ltr' | 'rtl';\n\nfunction getOptionLabelDefault(option: ComboBoxOption): string {\n if (typeof option === 'string') {\n return option;\n }\n if (typeof option === 'number') {\n return option.toString();\n }\n return option.label;\n}\n\n/**\n * Autocomplete input and command palette with a list of suggestions.\n *\n * Thanks to Shadcn for heavy inspiration and documentation\n * https://ui.shadcn.com/docs/components/combobox\n */\nfunction ComboBox({\n id,\n options = [],\n buttonClassName,\n popoverContentClassName,\n value,\n onChange = () => {},\n getOptionLabel = getOptionLabelDefault,\n buttonPlaceholder = '',\n textPlaceholder = '',\n commandEmptyMessage = 'No option found',\n buttonVariant = 'outline',\n dir = 'ltr',\n isDisabled = false,\n ...props\n}: ComboBoxProps) {\n const [open, setOpen] = useState(false);\n\n return (\n \n \n \n \n {value ? getOptionLabel(value) : buttonPlaceholder}\n \n \n \n \n \n \n \n {commandEmptyMessage}\n \n {options.map((option) => (\n {\n onChange(option);\n setOpen(false);\n }}\n >\n \n {getOptionLabel(option)}\n \n ))}\n \n \n \n \n );\n}\n\nexport default ComboBox;\n","import { useMemo } from 'react';\nimport ComboBox from '@/components/basics/combo-box.component';\nimport { Label } from '@/components/shadcn-ui/label';\n\nexport type ChapterRangeSelectorProps = {\n startChapter: number;\n endChapter: number;\n handleSelectStartChapter: (chapter: number) => void;\n handleSelectEndChapter: (chapter: number) => void;\n isDisabled?: boolean;\n chapterCount: number;\n};\n\nexport default function ChapterRangeSelector({\n startChapter,\n endChapter,\n handleSelectStartChapter,\n handleSelectEndChapter,\n isDisabled = false,\n chapterCount,\n}: ChapterRangeSelectorProps) {\n const chapterOptions = useMemo(\n () => Array.from({ length: chapterCount }, (_, index) => index + 1),\n [chapterCount],\n );\n\n const onChangeStartChapter = (value: number) => {\n handleSelectStartChapter(value);\n if (value > endChapter) {\n handleSelectEndChapter(value);\n }\n };\n\n const onChangeEndChapter = (value: number) => {\n handleSelectEndChapter(value);\n if (value < startChapter) {\n handleSelectStartChapter(value);\n }\n };\n\n return (\n <>\n \n option.toString()}\n value={startChapter}\n />\n\n \n option.toString()}\n value={endChapter}\n />\n \n );\n}\n","import { Button } from '@/components/shadcn-ui/button';\nimport { Label } from '@/components/shadcn-ui/label';\nimport { RadioGroup, RadioGroupItem } from '@/components/shadcn-ui/radio-group';\nimport { Canon } from '@sillsdev/scripture';\nimport { LocalizedStringValue } from 'platform-bible-utils';\nimport { useState } from 'react';\nimport ChapterRangeSelector, {\n ChapterRangeSelectorProps,\n} from '../basics/chapter-range-selector.component';\n\nexport enum BookSelectionMode {\n CURRENT_BOOK = 'current book',\n CHOOSE_BOOKS = 'choose books',\n}\n\n/**\n * Object containing all keys used for localization in this component. If you're using this\n * component in an extension, you can pass it into the useLocalizedStrings hook to easily obtain the\n * localized strings and pass them into the localizedStrings prop of this component\n */\nexport const BOOK_SELECTOR_STRING_KEYS = Object.freeze([\n '%webView_bookSelector_currentBook%',\n '%webView_bookSelector_choose%',\n '%webView_bookSelector_chooseBooks%',\n] as const);\n\nexport type BookSelectorLocalizedStrings = {\n [localizedInventoryKey in (typeof BOOK_SELECTOR_STRING_KEYS)[number]]?: LocalizedStringValue;\n};\n\n/**\n * Gets the localized value for the provided key\n *\n * @param strings Object containing localized string\n * @param key Key for a localized string\n * @returns The localized value for the provided key, if available. Returns the key if no localized\n * value is available\n */\nconst localizeString = (\n strings: BookSelectorLocalizedStrings,\n key: keyof BookSelectorLocalizedStrings,\n) => {\n return strings[key] ?? key;\n};\n\ntype BookSelectorProps = ChapterRangeSelectorProps & {\n handleBookSelectionModeChange: (newMode: BookSelectionMode) => void;\n currentBookName: string;\n onSelectBooks: () => void;\n selectedBookIds: string[];\n localizedStrings: BookSelectorLocalizedStrings;\n};\n\nexport default function BookSelector({\n handleBookSelectionModeChange,\n currentBookName,\n onSelectBooks,\n selectedBookIds,\n chapterCount,\n endChapter,\n handleSelectEndChapter,\n startChapter,\n handleSelectStartChapter,\n localizedStrings,\n}: BookSelectorProps) {\n const currentBookText = localizeString(localizedStrings, '%webView_bookSelector_currentBook%');\n const chooseText = localizeString(localizedStrings, '%webView_bookSelector_choose%');\n const chooseBooksText = localizeString(localizedStrings, '%webView_bookSelector_chooseBooks%');\n\n const [bookSelectionMode, setBookSelectionMode] = useState(\n BookSelectionMode.CURRENT_BOOK,\n );\n\n const onSelectionModeChange = (newMode: BookSelectionMode) => {\n setBookSelectionMode(newMode);\n handleBookSelectionModeChange(newMode);\n };\n\n return (\n onSelectionModeChange(value as BookSelectionMode)}\n >\n
    \n
    \n
    \n \n \n
    \n \n
    \n \n
    \n
    \n
    \n
    \n \n \n
    \n \n onSelectBooks()}\n >\n {chooseText}\n \n
    \n
    \n \n );\n}\n","import { DropdownMenuTrigger } from '@radix-ui/react-dropdown-menu';\nimport { FilterIcon } from 'lucide-react';\nimport { Table } from '@tanstack/react-table';\n\nimport { Button } from '@/components/shadcn-ui/button';\nimport {\n DropdownMenu,\n DropdownMenuCheckboxItem,\n DropdownMenuContent,\n DropdownMenuLabel,\n DropdownMenuSeparator,\n} from '@/components/shadcn-ui/dropdown-menu';\n\ninterface DataTableViewOptionsProps {\n table: Table;\n}\n\nfunction DataTableViewOptions({ table }: DataTableViewOptionsProps) {\n return (\n \n \n \n \n \n Toggle columns\n \n {table\n .getAllColumns()\n .filter((column) => column.getCanHide())\n .map((column) => {\n return (\n column.toggleVisibility(!!value)}\n >\n {column.id}\n \n );\n })}\n \n \n );\n}\n\nexport default DataTableViewOptions;\n","import React from 'react';\nimport * as SelectPrimitive from '@radix-ui/react-select';\nimport { Check, ChevronDown, ChevronUp } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Select = SelectPrimitive.Root;\n\nconst SelectGroup = SelectPrimitive.Group;\n\nconst SelectValue = SelectPrimitive.Value;\n\nconst SelectTrigger = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, ...props }, ref) => (\n span]:tw-line-clamp-1',\n className,\n )}\n {...props}\n >\n {children}\n \n \n \n \n));\nSelectTrigger.displayName = SelectPrimitive.Trigger.displayName;\n\nconst SelectScrollUpButton = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n));\nSelectScrollUpButton.displayName = SelectPrimitive.ScrollUpButton.displayName;\n\nconst SelectScrollDownButton = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n));\nSelectScrollDownButton.displayName = SelectPrimitive.ScrollDownButton.displayName;\n\nconst SelectContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, position = 'popper', ...props }, ref) => (\n \n \n \n \n {children}\n \n \n \n \n));\nSelectContent.displayName = SelectPrimitive.Content.displayName;\n\nconst SelectLabel = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSelectLabel.displayName = SelectPrimitive.Label.displayName;\n\nconst SelectItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, ...props }, ref) => (\n \n \n \n \n \n \n\n {children}\n \n));\nSelectItem.displayName = SelectPrimitive.Item.displayName;\n\nconst SelectSeparator = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSelectSeparator.displayName = SelectPrimitive.Separator.displayName;\n\nexport {\n Select,\n SelectGroup,\n SelectValue,\n SelectTrigger,\n SelectContent,\n SelectLabel,\n SelectItem,\n SelectSeparator,\n SelectScrollUpButton,\n SelectScrollDownButton,\n};\n","import { ChevronLeftIcon, ChevronRightIcon, ArrowLeftIcon, ArrowRightIcon } from 'lucide-react';\nimport { Table } from '@tanstack/react-table';\n\nimport { Button } from '@/components/shadcn-ui/button';\nimport {\n Select,\n SelectContent,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\n\ninterface DataTablePaginationProps {\n table: Table;\n}\n\nfunction DataTablePagination({ table }: DataTablePaginationProps) {\n return (\n
    \n
    \n
    \n {table.getFilteredSelectedRowModel().rows.length} of{' '}\n {table.getFilteredRowModel().rows.length} row(s) selected\n
    \n
    \n

    Rows per page

    \n {\n table.setPageSize(Number(value));\n }}\n >\n \n \n \n \n {[10, 20, 30, 40, 50].map((pageSize) => (\n \n {pageSize}\n \n ))}\n \n \n
    \n
    \n Page {table.getState().pagination.pageIndex + 1} of {table.getPageCount()}\n
    \n
    \n table.setPageIndex(0)}\n disabled={!table.getCanPreviousPage()}\n >\n Go to first page\n \n \n table.previousPage()}\n disabled={!table.getCanPreviousPage()}\n >\n Go to previous page\n \n \n table.nextPage()}\n disabled={!table.getCanNextPage()}\n >\n Go to next page\n \n \n table.setPageIndex(table.getPageCount() - 1)}\n disabled={!table.getCanNextPage()}\n >\n Go to last page\n \n \n
    \n
    \n
    \n );\n}\n\nexport default DataTablePagination;\n","import React from 'react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Table = React.forwardRef<\n HTMLTableElement,\n React.HTMLAttributes & { stickyHeader?: boolean }\n>(({ className, stickyHeader, ...props }, ref) => (\n
    \n \n
    \n));\nTable.displayName = 'Table';\n\nconst TableHeader = React.forwardRef<\n HTMLTableSectionElement,\n React.HTMLAttributes & { stickyHeader?: boolean }\n>(({ className, stickyHeader, ...props }, ref) => (\n \n));\nTableHeader.displayName = 'TableHeader';\n\nconst TableBody = React.forwardRef<\n HTMLTableSectionElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableBody.displayName = 'TableBody';\n\nconst TableFooter = React.forwardRef<\n HTMLTableSectionElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n tr]:last:tw-border-b-0', className)}\n {...props}\n />\n));\nTableFooter.displayName = 'TableFooter';\n\nconst TableRow = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nTableRow.displayName = 'TableRow';\n\nconst TableHead = React.forwardRef<\n HTMLTableCellElement,\n React.ThHTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableHead.displayName = 'TableHead';\n\nconst TableCell = React.forwardRef<\n HTMLTableCellElement,\n React.TdHTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableCell.displayName = 'TableCell';\n\nconst TableCaption = React.forwardRef<\n HTMLTableCaptionElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableCaption.displayName = 'TableCaption';\n\nexport { Table, TableHeader, TableBody, TableFooter, TableHead, TableRow, TableCell, TableCaption };\n","import { useState } from 'react';\n\nimport {\n ColumnFiltersState,\n flexRender,\n getCoreRowModel,\n getFilteredRowModel,\n getPaginationRowModel,\n getSortedRowModel,\n SortingState,\n ColumnDef as TSColumnDef,\n Row as TSRow,\n RowSelectionState as TSRowSelectionState,\n SortDirection as TSSortDirection,\n Table as TSTable,\n useReactTable,\n VisibilityState,\n} from '@tanstack/react-table';\n\nimport DataTableViewOptions from '@/components/advanced/data-table/data-table-column-toggle.component';\nimport DataTablePagination from '@/components/advanced/data-table/data-table-pagination.component';\nimport { Button } from '@/components/shadcn-ui/button';\nimport {\n Table,\n TableBody,\n TableCell,\n TableHead,\n TableHeader,\n TableRow,\n} from '@/components/shadcn-ui/table';\n\nexport type ColumnDef = TSColumnDef;\nexport type RowContents = TSRow;\nexport type TableContents = TSTable;\nexport type SortDirection = TSSortDirection;\nexport type RowSelectionState = TSRowSelectionState;\n\ninterface DataTableProps {\n columns: ColumnDef[];\n data: TData[];\n enablePagination?: boolean;\n showPaginationControls?: boolean;\n showColumnVisibilityControls?: boolean;\n stickyHeader?: boolean;\n onRowClickHandler?: (row: RowContents, table: TableContents) => void;\n}\n\n/**\n * Feature-rich table component that infuses our basic shadcn-based Table component with features\n * from TanStack's React Table library\n */\nfunction DataTable({\n columns,\n data,\n enablePagination = false,\n showPaginationControls = false,\n showColumnVisibilityControls = false,\n stickyHeader = false,\n onRowClickHandler = () => {},\n}: DataTableProps) {\n const [sorting, setSorting] = useState([]);\n const [columnFilters, setColumnFilters] = useState([]);\n const [columnVisibility, setColumnVisibility] = useState({});\n const [rowSelection, setRowSelection] = useState({});\n\n const table = useReactTable({\n data,\n columns,\n getCoreRowModel: getCoreRowModel(),\n ...(enablePagination && { getPaginationRowModel: getPaginationRowModel() }),\n onSortingChange: setSorting,\n getSortedRowModel: getSortedRowModel(),\n onColumnFiltersChange: setColumnFilters,\n getFilteredRowModel: getFilteredRowModel(),\n onColumnVisibilityChange: setColumnVisibility,\n onRowSelectionChange: setRowSelection,\n state: {\n sorting,\n columnFilters,\n columnVisibility,\n rowSelection,\n },\n });\n\n return (\n
    \n {showColumnVisibilityControls && }\n \n \n {table.getHeaderGroups().map((headerGroup) => (\n \n {headerGroup.headers.map((header) => {\n return (\n \n {header.isPlaceholder\n ? undefined\n : flexRender(header.column.columnDef.header, header.getContext())}\n \n );\n })}\n \n ))}\n \n \n {table.getRowModel().rows?.length ? (\n table.getRowModel().rows.map((row) => (\n onRowClickHandler(row, table)}\n key={row.id}\n data-state={row.getIsSelected() && 'selected'}\n >\n {row.getVisibleCells().map((cell) => (\n \n {flexRender(cell.column.columnDef.cell, cell.getContext())}\n \n ))}\n \n ))\n ) : (\n \n \n No results.\n \n \n )}\n \n
    \n {enablePagination && (\n
    \n table.previousPage()}\n disabled={!table.getCanPreviousPage()}\n >\n Previous\n \n table.nextPage()}\n disabled={!table.getCanNextPage()}\n >\n Next\n \n
    \n )}\n {enablePagination && showPaginationControls && }\n
    \n );\n}\n\nexport default DataTable;\n","import {\n Table,\n TableBody,\n TableCell,\n TableHead,\n TableHeader,\n TableRow,\n} from '@/components/shadcn-ui/table';\nimport { Canon } from '@sillsdev/scripture';\nimport { deepEqual, LanguageStrings, ScriptureReference } from 'platform-bible-utils';\nimport { useMemo } from 'react';\nimport { InventoryItemOccurrence } from './inventory-utils';\n\n/** Props for the OccurrencesTable component */\ntype OccurrencesTableProps = {\n /** Data that contains scriptures references and snippets of scripture */\n occurrenceData: InventoryItemOccurrence[];\n /** Callback function that is executed when the scripture reference is changed */\n setScriptureReference: (scriptureReference: ScriptureReference) => void;\n /**\n * Object with all localized strings that the OccurrencesTable needs to work well across multiple\n * languages\n */\n localizedStrings: LanguageStrings;\n};\n\n/**\n * Table that shows occurrences of specified inventory item(s). The first column shows the related\n * scripture reference. The second column shows the snippet of scripture that contains the specified\n * inventory item\n */\nfunction OccurrencesTable({\n occurrenceData,\n setScriptureReference,\n localizedStrings,\n}: OccurrencesTableProps) {\n const referenceHeaderText =\n localizedStrings['%webView_inventory_occurrences_table_header_reference%'];\n const occurrenceHeaderText =\n localizedStrings['%webView_inventory_occurrences_table_header_occurrence%'];\n\n const occurrences: InventoryItemOccurrence[] = useMemo(() => {\n const uniqueOccurrences: InventoryItemOccurrence[] = [];\n\n occurrenceData.forEach((occurrence) => {\n if (!uniqueOccurrences.some((uniqueOccurrence) => deepEqual(uniqueOccurrence, occurrence))) {\n uniqueOccurrences.push(occurrence);\n }\n });\n\n return uniqueOccurrences;\n }, [occurrenceData]);\n\n return (\n \n \n \n {referenceHeaderText}\n {occurrenceHeaderText}\n \n \n \n {occurrences.length > 0 &&\n occurrences.map((occurrence) => (\n {\n setScriptureReference(occurrence.reference);\n }}\n >\n {`${Canon.bookNumberToEnglishName(occurrence.reference.bookNum)} ${occurrence.reference.chapterNum}:${occurrence.reference.verseNum}`}\n {occurrence.text}\n \n ))}\n \n
    \n );\n}\n\nexport default OccurrencesTable;\n","import React from 'react';\nimport * as CheckboxPrimitive from '@radix-ui/react-checkbox';\nimport { Check } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Checkbox = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n \n \n));\nCheckbox.displayName = CheckboxPrimitive.Root.displayName;\n\nexport default Checkbox;\n","import { Canon } from '@sillsdev/scripture';\nimport { ScriptureReference } from 'platform-bible-utils';\n\n/* #region Types */\n\n/**\n * Status of items that appear in inventories. 'approved' and 'unapproved' items are defined in the\n * project's `Settings.xml`. All other items are defined as 'unknown'\n */\nexport type Status = 'approved' | 'unapproved' | 'unknown';\n\n/** Occurrence of item in inventory. Primarily used by table that shows occurrences */\nexport type InventoryItemOccurrence = {\n /** Reference to scripture where the item appears */\n reference: ScriptureReference;\n /** Snippet of scripture that contains the occurrence */\n text: string;\n};\n\n/** Data structure that contains all information on an item that is shown in an inventory */\nexport type InventoryTableData = {\n /**\n * The item (e.g. a character in the characters inventory, a marker in the marker inventory) In\n * most cases the array will only have one element. In case of additional items (e.g. the\n * preceding marker in the markers check), the primary item should be stored in the first index.\n * To show additional items in the inventory, make sure to configure the `additionalItemsLabels`\n * prop for the Inventory component\n */\n items: string[];\n /** The number of times this item occurs in the selected scope */\n count: number;\n /** The status of this item (see documentation for `Status` type for more information) */\n status: Status;\n /** Occurrences of this item in the scripture text for the selected scope */\n occurrences: InventoryItemOccurrence[];\n};\n\n/* #endregion */\n\n/* #region Functions */\n\n/**\n * Splits USFM string into shorter line-like segments\n *\n * @param text A single (likely very large) USFM string\n * @returns An array containing the input text, split into shorter segments\n */\nexport const getLinesFromUSFM = (text: string) => {\n // Splits on (CR)LF, CR, \\v, \\c and \\id\n return text.split(/(?:\\r?\\n|\\r)|(?=(?:\\\\(?:v|c|id)))/g);\n};\n\n/**\n * Extracts chapter or verse number from USFM strings that start with a \\c or \\v marker\n *\n * @param text USFM string that is expected to start with \\c or \\v marker\n * @returns Chapter or verse number if one is found. Else returns 0.\n */\nexport const getNumberFromUSFM = (text: string): number | undefined => {\n // Captures all digits that follow \\v or \\c markers followed by whitespace located at the start of a string\n const regex = /^\\\\[vc]\\s+(\\d+)/;\n const match = text.match(regex);\n\n if (match) {\n return +match[1];\n }\n return undefined;\n};\n\n/**\n * Gets book ID from USFM string that starts with the \\id marker, and returns book number for it\n *\n * @param text USFM string that is expected to start with \\id marker\n * @returns Book number corresponding to the \\id marker in the input text. Returns 0 if no marker is\n * found or the marker is not valid\n */\nexport const getBookNumFromId = (text: string): number => {\n // Captures all digits that follow an \\id marker followed by whitespace located at the start of a string\n const match = text.match(/^\\\\id\\s+([A-Za-z]+)/);\n if (match) {\n return Canon.bookIdToNumber(match[1]);\n }\n return 0;\n};\n\n/**\n * Gets the status for an item, typically used in the Inventory component\n *\n * @param item The item for which the status is being requested\n * @param approvedItems Array of approved items, typically as defined in `Settings.xml`\n * @param unapprovedItems Array of unapproved items, typically as defined in `Settings.xml`\n * @returns The status for the specified item\n */\nexport const getStatusForItem = (\n item: string,\n approvedItems: string[],\n unapprovedItems: string[],\n): Status => {\n if (unapprovedItems.includes(item)) return 'unapproved';\n if (approvedItems.includes(item)) return 'approved';\n return 'unknown';\n};\n\n/* #endregion */\n","import React from 'react';\nimport * as TogglePrimitive from '@radix-ui/react-toggle';\nimport { cva, type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst toggleVariants = cva(\n 'pr-twp tw-inline-flex tw-items-center tw-justify-center tw-rounded-md tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-colors hover:tw-bg-muted hover:tw-text-muted-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50 data-[state=on]:tw-bg-accent data-[state=on]:tw-text-accent-foreground',\n {\n variants: {\n variant: {\n default: 'tw-bg-transparent',\n outline:\n 'tw-border tw-border-input tw-bg-transparent hover:tw-bg-accent hover:tw-text-accent-foreground',\n },\n size: {\n default: 'tw-h-10 tw-px-3',\n sm: 'tw-h-9 tw-px-2.5',\n lg: 'tw-h-11 tw-px-5',\n },\n },\n defaultVariants: {\n variant: 'default',\n size: 'default',\n },\n },\n);\n\nconst Toggle = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef & VariantProps\n>(({ className, variant, size, ...props }, ref) => (\n \n));\n\nToggle.displayName = TogglePrimitive.Root.displayName;\n\nexport { Toggle, toggleVariants };\n","import React from 'react';\nimport * as ToggleGroupPrimitive from '@radix-ui/react-toggle-group';\nimport { type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { toggleVariants } from '@/components/shadcn-ui/toggle';\n\nconst ToggleGroupContext = React.createContext>({\n size: 'default',\n variant: 'default',\n});\n\nconst ToggleGroup = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef &\n VariantProps\n>(({ className, variant, size, children, ...props }, ref) => (\n \n \n {children}\n \n \n));\n\nToggleGroup.displayName = ToggleGroupPrimitive.Root.displayName;\n\nconst ToggleGroupItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef &\n VariantProps\n>(({ className, children, variant, size, ...props }, ref) => {\n const context = React.useContext(ToggleGroupContext);\n\n return (\n \n {children}\n \n );\n});\n\nToggleGroupItem.displayName = ToggleGroupPrimitive.Item.displayName;\n\nexport { ToggleGroup, ToggleGroupItem };\n","import { ColumnDef, SortDirection } from '@/components/advanced/data-table/data-table.component';\nimport { Button } from '@/components/shadcn-ui/button';\nimport { ToggleGroup, ToggleGroupItem } from '@/components/shadcn-ui/toggle-group';\nimport {\n ArrowDownIcon,\n ArrowUpDownIcon,\n ArrowUpIcon,\n CircleCheckIcon,\n CircleHelpIcon,\n CircleXIcon,\n} from 'lucide-react';\nimport { ReactNode } from 'react';\nimport { InventoryTableData, Status } from './inventory-utils';\n\n/**\n * Gets an icon that indicates the current sorting direction based on the provided input\n *\n * @param sortDirection Sorting direction. Can be ascending ('asc'), descending ('desc') or false (\n * i.e. not sorted)\n * @returns The appropriate sorting icon for the provided sorting direction\n */\nconst getSortingIcon = (sortDirection: false | SortDirection): ReactNode => {\n if (sortDirection === 'asc') {\n return ;\n }\n if (sortDirection === 'desc') {\n return ;\n }\n return ;\n};\n\n/**\n * Function that creates the item column for inventories\n *\n * @param itemLabel Localized label for the item column (e.g. 'Character', 'Repeated Word', etc.)\n * @returns Column that shows the inventory items. Should be used with the DataTable component\n */\nexport const inventoryItemColumn = (itemLabel: string): ColumnDef => {\n return {\n accessorKey: 'item',\n accessorFn: (row: InventoryTableData) => row.items[0],\n header: ({ column }) => (\n \n ),\n };\n};\n\n/**\n * Function that creates the additional item columns for inventories\n *\n * @param additionalItemLabel Localized label for the additional item column (e.g. 'Preceding\n * Marker')\n * @param additionalItemIndex Index that locates the desired item in the items array of the\n * inventory\n * @returns Column that shows additional inventory items. Should be used with the DataTable\n * component\n */\nexport const inventoryAdditionalItemColumn = (\n additionalItemLabel: string,\n additionalItemIndex: number,\n): ColumnDef => {\n return {\n accessorKey: `item${additionalItemIndex}`,\n accessorFn: (row: InventoryTableData) => row.items[additionalItemIndex],\n header: ({ column }) => (\n \n ),\n };\n};\n\n/**\n * Function that creates the count column for inventories. Should be used with the DataTable\n * component.\n *\n * @param itemLabel Localized label for the count column\n * @returns Column that shows the number of occurrences of the related inventory items\n */\nexport const inventoryCountColumn = (countLabel: string): ColumnDef => {\n return {\n accessorKey: 'count',\n header: ({ column }) => (\n
    \n \n
    \n ),\n cell: ({ row }) =>
    {row.getValue('count')}
    ,\n };\n};\n\n/**\n * Function that updates project settings when status for item(s) changes\n *\n * @param changedItems Array of items for which the status is being updated\n * @param newStatus The status that the items are being given\n * @param approvedItems Array of currently approved items\n * @param onApprovedItemsChange Callback function that stores the updated list of approved items\n * @param unapprovedItems Array of currently unapproved items\n * @param onUnapprovedItemsChange Callback function that stores the updated list of unapproved items\n */\nconst statusChangeHandler = (\n changedItems: string[],\n newStatus: Status,\n approvedItems: string[],\n onApprovedItemsChange: (items: string[]) => void,\n unapprovedItems: string[],\n onUnapprovedItemsChange: (items: string[]) => void,\n) => {\n let newApprovedItems: string[] = [...approvedItems];\n changedItems.forEach((item) => {\n if (newStatus === 'approved') {\n if (!newApprovedItems.includes(item)) {\n newApprovedItems.push(item);\n }\n } else {\n newApprovedItems = newApprovedItems.filter((validItem) => validItem !== item);\n }\n });\n onApprovedItemsChange(newApprovedItems);\n\n let newUnapprovedItems: string[] = [...unapprovedItems];\n changedItems.forEach((item) => {\n if (newStatus === 'unapproved') {\n if (!newUnapprovedItems.includes(item)) {\n newUnapprovedItems.push(item);\n }\n } else {\n newUnapprovedItems = newUnapprovedItems.filter((unapprovedItem) => unapprovedItem !== item);\n }\n });\n onUnapprovedItemsChange(newUnapprovedItems);\n};\n\n/**\n * Function that creates the status column for inventories. Should be used with the DataTable\n * component.\n *\n * @param statusLabel Localized label for the status column\n * @param approvedItems Array of approved items, typically as defined in `Settings.xml`\n * @param onApprovedItemsChange Callback function that stores the updated list of approved items\n * @param unapprovedItems Array of unapproved items, typically as defined in `Settings.xml`\n * @param onUnapprovedItemsChange Callback function that stores the updated list of unapproved items\n * @returns Column that shows the status buttons for the related inventory item. The button for the\n * current status of the item is selected\n */\nexport const inventoryStatusColumn = (\n statusLabel: string,\n approvedItems: string[],\n onApprovedItemsChange: (items: string[]) => void,\n unapprovedItems: string[],\n onUnapprovedItemsChange: (items: string[]) => void,\n): ColumnDef => {\n return {\n accessorKey: 'status',\n header: ({ column }) => {\n return (\n
    \n \n
    \n );\n },\n cell: ({ row }) => {\n const status: Status = row.getValue('status');\n const item: string = row.getValue('item');\n return (\n \n \n statusChangeHandler(\n [item],\n 'approved',\n approvedItems,\n onApprovedItemsChange,\n unapprovedItems,\n onUnapprovedItemsChange,\n )\n }\n value=\"approved\"\n >\n \n \n \n statusChangeHandler(\n [item],\n 'unapproved',\n approvedItems,\n onApprovedItemsChange,\n unapprovedItems,\n onUnapprovedItemsChange,\n )\n }\n value=\"unapproved\"\n >\n \n \n \n statusChangeHandler(\n [item],\n 'unknown',\n approvedItems,\n onApprovedItemsChange,\n unapprovedItems,\n onUnapprovedItemsChange,\n )\n }\n value=\"unknown\"\n >\n \n \n \n );\n },\n };\n};\n","import DataTable, {\n ColumnDef,\n RowContents,\n RowSelectionState,\n TableContents,\n} from '@/components/advanced/data-table/data-table.component';\nimport OccurrencesTable from '@/components/advanced/inventory/occurrences-table.component';\nimport Checkbox from '@/components/shadcn-ui/checkbox';\nimport { Input } from '@/components/shadcn-ui/input';\nimport { Label } from '@/components/shadcn-ui/label';\nimport {\n Select,\n SelectContent,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\nimport {\n deepEqual,\n LocalizedStringValue,\n ScriptureReference,\n substring,\n} from 'platform-bible-utils';\nimport { useEffect, useMemo, useState } from 'react';\nimport {\n getBookNumFromId,\n getLinesFromUSFM,\n getNumberFromUSFM,\n getStatusForItem,\n InventoryItemOccurrence,\n InventoryTableData,\n Status,\n} from './inventory-utils';\nimport { inventoryAdditionalItemColumn } from './inventory-columns';\n\n/**\n * Object containing all keys used for localization in this component. If you're using this\n * component in an extension, you can pass it into the useLocalizedStrings hook to easily obtain the\n * localized strings and pass them into the localizedStrings prop of this component\n */\nexport const INVENTORY_STRING_KEYS = Object.freeze([\n '%webView_inventory_all%',\n '%webView_inventory_approved%',\n '%webView_inventory_unapproved%',\n '%webView_inventory_unknown%',\n '%webView_inventory_scope_currentBook%',\n '%webView_inventory_scope_chapter%',\n '%webView_inventory_scope_verse%',\n '%webView_inventory_filter_text%',\n '%webView_inventory_show_additional_items%',\n '%webView_inventory_occurrences_table_header_reference%',\n '%webView_inventory_occurrences_table_header_occurrence%',\n] as const);\n\nexport type InventoryLocalizedStrings = {\n [localizedInventoryKey in (typeof INVENTORY_STRING_KEYS)[number]]?: LocalizedStringValue;\n};\n\n/** Scope of scripture that the inventory can operate on */\nexport type Scope = 'book' | 'chapter' | 'verse';\n\n/** Status values that the status filter can select from */\ntype StatusFilter = Status | 'all';\n\n/** Text labels for the inventory columns and the control components of additional inventory items */\ntype AdditionalItemsLabels = {\n checkboxText?: string;\n tableHeaders?: string[];\n};\n\n/**\n * Filters data that is shown in the DataTable section of the Inventory\n *\n * @param itemData All inventory items and their related information\n * @param statusFilter Allows filtering by status (i.e. show all items, or only items that are\n * 'approved', 'unapproved' or 'unknown')\n * @param textFilter Allows filtering by text. All items that include the filter text will be\n * selected.\n * @returns Array of items and their related information that are matched by the specified filters\n */\nconst filterItemData = (\n itemData: InventoryTableData[],\n statusFilter: StatusFilter,\n textFilter: string,\n): InventoryTableData[] => {\n let filteredItemData: InventoryTableData[] = itemData;\n\n if (statusFilter !== 'all') {\n filteredItemData = filteredItemData.filter(\n (item) =>\n (statusFilter === 'approved' && item.status === 'approved') ||\n (statusFilter === 'unapproved' && item.status === 'unapproved') ||\n (statusFilter === 'unknown' && item.status === 'unknown'),\n );\n }\n\n if (textFilter !== '')\n filteredItemData = filteredItemData.filter((item) => item.items[0].includes(textFilter));\n\n return filteredItemData;\n};\n\n/**\n * Turns array of strings into array of inventory items, along with their count and status\n *\n * @param text The source scripture text that is searched for inventory items\n * @param scriptureRef The scripture reference that the application is currently set to\n * @param approvedItems Array of approved items, typically as defined in `Settings.xml`\n * @param unapprovedItems Array of unapproved items, typically as defined in `Settings.xml`\n * @param itemRegex Regular expression that describes what items this Inventory should extract from\n * the provided scripture text\n * @returns Array of inventory items, along with their count and status\n */\nconst createTableData = (\n text: string | undefined,\n scriptureRef: ScriptureReference,\n approvedItems: string[],\n unapprovedItems: string[],\n itemRegex: RegExp,\n): InventoryTableData[] => {\n if (!text) return [];\n\n const tableData: InventoryTableData[] = [];\n\n let currentBook: number | undefined = scriptureRef.bookNum;\n let currentChapter: number | undefined = scriptureRef.chapterNum;\n let currentVerse: number | undefined = scriptureRef.verseNum;\n\n const lines = getLinesFromUSFM(text);\n\n lines.forEach((line: string) => {\n if (line.startsWith('\\\\id')) {\n currentBook = getBookNumFromId(line);\n currentChapter = 0;\n currentVerse = 0;\n }\n if (line.startsWith('\\\\c')) {\n currentChapter = getNumberFromUSFM(line);\n currentVerse = 0;\n }\n if (line.startsWith('\\\\v')) {\n currentVerse = getNumberFromUSFM(line);\n if (currentChapter === 0) {\n currentChapter = scriptureRef.chapterNum;\n }\n }\n\n let match: RegExpExecArray | undefined = itemRegex.exec(line) ?? undefined;\n while (match) {\n const items: string[] = [];\n match.forEach((item) => items.push(item));\n const itemIndex = match.index;\n const existingItem = tableData.find((tableEntry) => deepEqual(tableEntry.items, items));\n const newReference: InventoryItemOccurrence = {\n reference: {\n bookNum: currentBook !== undefined ? currentBook : -1,\n chapterNum: currentChapter !== undefined ? currentChapter : -1,\n verseNum: currentVerse !== undefined ? currentVerse : -1,\n },\n text: substring(line, Math.max(0, itemIndex - 25), Math.min(itemIndex + 25, line.length)),\n };\n if (existingItem) {\n existingItem.count += 1;\n existingItem.occurrences.push(newReference);\n } else {\n const newItem: InventoryTableData = {\n items,\n count: 1,\n status: getStatusForItem(items[0], approvedItems, unapprovedItems),\n occurrences: [newReference],\n };\n tableData.push(newItem);\n }\n\n match = itemRegex.exec(line) ?? undefined;\n }\n });\n\n return tableData;\n};\n\n/**\n * Gets the localized value for the provided key\n *\n * @param strings Object containing localized string\n * @param key Key for a localized string\n * @returns The localized value for the provided key, if available. Returns the key if no localized\n * value is available\n */\nconst localizeString = (\n strings: InventoryLocalizedStrings,\n key: keyof InventoryLocalizedStrings,\n) => {\n return strings[key] ?? key;\n};\n\n/** Props for the Inventory component */\ntype InventoryProps = {\n /** The scripture reference that the application is currently set to */\n scriptureReference: ScriptureReference;\n /** Callback function that is executed when the scripture reference is changed */\n setScriptureReference: (scriptureReference: ScriptureReference) => void;\n /**\n * Object with all localized strings that the Inventory needs to work well across multiple\n * languages. When using this component with Platform.Bible, you can import\n * `INVENTORY_STRING_KEYS` from this library, pass it in to the Platform's localization hook, and\n * pass the localized keys that are returned by the hook into this prop.\n */\n localizedStrings: InventoryLocalizedStrings;\n /**\n * The logic that finds the desired items in the source text. This can either be a Regular\n * expression that captures one or multiple items (preferred), or a custom function that builds\n * and return an InventoryDataTable[] manually. Note: In case the logic captures more than one\n * item (i.e. InventoryTableData.items has a length greater than 1), you must provide text labels\n * for the related columns and control elements to show by setting the `additionalItemsLabels`\n * prop\n */\n extractItems:\n | RegExp\n | ((\n text: string | undefined,\n scriptureRef: ScriptureReference,\n approvedItems: string[],\n unapprovedItems: string[],\n ) => InventoryTableData[]);\n /**\n * Text labels for control elements and additional column headers in case your Inventory has more\n * than one item to show (e.g. The 'Preceding Marker' in the Markers Inventory)\n */\n additionalItemsLabels?: AdditionalItemsLabels;\n /** Array of approved items, typically as defined in `Settings.xml` */\n approvedItems: string[];\n /** Array of unapproved items, typically as defined in `Settings.xml` */\n unapprovedItems: string[];\n /** The source scripture text that is searched for in inventory items */\n text: string | undefined;\n /** Scope of scripture that the inventory will operate on */\n scope: Scope;\n /** Callback function that is executed when the scope is changed from the Inventory */\n onScopeChange: (scope: Scope) => void;\n /**\n * Column definitions for the Inventory data table. The most commonly used column definitions are\n * pre-configured for your convenience and can be imported (e.g. inventoryItemColumn,\n * inventoryAdditionalItemColumn inventoryCountColumn, and inventoryStatusColumn). If you need any\n * other columns you can add these yourself\n */\n columns: ColumnDef[];\n};\n\n/** Inventory component that is used to view and control the status of provided project settings */\nexport default function Inventory({\n scriptureReference,\n setScriptureReference,\n localizedStrings,\n extractItems,\n additionalItemsLabels,\n approvedItems,\n unapprovedItems,\n text,\n scope,\n onScopeChange,\n columns,\n}: InventoryProps) {\n const allItemsText = localizeString(localizedStrings, '%webView_inventory_all%');\n const approvedItemsText = localizeString(localizedStrings, '%webView_inventory_approved%');\n const unapprovedItemsText = localizeString(localizedStrings, '%webView_inventory_unapproved%');\n const unknownItemsText = localizeString(localizedStrings, '%webView_inventory_unknown%');\n const scopeBookText = localizeString(localizedStrings, '%webView_inventory_scope_currentBook%');\n const scopeChapterText = localizeString(localizedStrings, '%webView_inventory_scope_chapter%');\n const scopeVerseText = localizeString(localizedStrings, '%webView_inventory_scope_verse%');\n const filterText = localizeString(localizedStrings, '%webView_inventory_filter_text%');\n const showAdditionalItemsText = localizeString(\n localizedStrings,\n '%webView_inventory_show_additional_items%',\n );\n\n const [showAdditionalItems, setShowAdditionalItems] = useState(false);\n const [statusFilter, setStatusFilter] = useState('all');\n const [textFilter, setTextFilter] = useState('');\n const [selectedItem, setSelectedItem] = useState([]);\n\n const tableData: InventoryTableData[] = useMemo(() => {\n if (!text) return [];\n if (extractItems instanceof RegExp)\n return createTableData(\n text,\n scriptureReference,\n approvedItems,\n unapprovedItems,\n extractItems,\n );\n return extractItems(text, scriptureReference, approvedItems, unapprovedItems);\n }, [text, extractItems, scriptureReference, approvedItems, unapprovedItems]);\n\n const reducedTableData: InventoryTableData[] = useMemo(() => {\n if (showAdditionalItems) return tableData;\n\n const newTableData: InventoryTableData[] = [];\n\n tableData.forEach((tableEntry) => {\n const firstItem = tableEntry.items[0];\n\n const existingEntry = newTableData.find(\n (newTableEntry) => newTableEntry.items[0] === firstItem,\n );\n\n if (existingEntry) {\n existingEntry.count += tableEntry.count;\n existingEntry.occurrences = existingEntry.occurrences.concat(tableEntry.occurrences);\n } else {\n newTableData.push({\n items: [firstItem],\n count: tableEntry.count,\n occurrences: tableEntry.occurrences,\n status: tableEntry.status,\n });\n }\n });\n\n return newTableData;\n }, [showAdditionalItems, tableData]);\n\n const filteredTableData: InventoryTableData[] = useMemo(() => {\n return filterItemData(reducedTableData, statusFilter, textFilter);\n }, [reducedTableData, statusFilter, textFilter]);\n\n const allColumns: ColumnDef[] = useMemo(() => {\n if (!showAdditionalItems) return columns;\n\n const numberOfAdditionalItems = additionalItemsLabels?.tableHeaders?.length;\n if (!numberOfAdditionalItems) return columns;\n\n const additionalColumns: ColumnDef[] = [];\n\n for (let index = 0; index < numberOfAdditionalItems; index++) {\n additionalColumns.push(\n inventoryAdditionalItemColumn(\n additionalItemsLabels?.tableHeaders?.[index] || 'Additional Item',\n index + 1,\n ),\n );\n }\n\n return [...additionalColumns, ...columns];\n }, [additionalItemsLabels?.tableHeaders, columns, showAdditionalItems]);\n\n useEffect(() => {\n setSelectedItem([]);\n }, [filteredTableData]);\n\n const rowClickHandler = (\n row: RowContents,\n table: TableContents,\n ) => {\n table.setRowSelection(() => {\n const newSelection: RowSelectionState = {};\n newSelection[row.index] = true;\n return newSelection;\n });\n\n setSelectedItem(row.original.items);\n };\n\n const handleScopeChange = (value: string) => {\n if (value === 'book' || value === 'chapter' || value === 'verse') {\n onScopeChange(value);\n } else {\n throw new Error(`Invalid scope value: ${value}`);\n }\n };\n\n const handleStatusFilterChange = (value: string) => {\n if (value === 'all' || value === 'approved' || value === 'unapproved' || value === 'unknown') {\n setStatusFilter(value);\n } else {\n throw new Error(`Invalid status filter value: ${value}`);\n }\n };\n\n const occurrenceData: InventoryItemOccurrence[] = useMemo(() => {\n if (reducedTableData.length === 0 || selectedItem.length === 0) return [];\n const occurrence = reducedTableData.filter((tableEntry: InventoryTableData) => {\n return deepEqual(\n showAdditionalItems ? tableEntry.items : [tableEntry.items[0]],\n selectedItem,\n );\n });\n if (occurrence.length > 1) throw new Error('Selected item is not unique');\n return occurrence[0].occurrences;\n }, [selectedItem, showAdditionalItems, reducedTableData]);\n\n return (\n
    \n
    \n handleStatusFilterChange(value)}\n defaultValue={statusFilter}\n >\n \n \n \n \n {allItemsText}\n {approvedItemsText}\n {unapprovedItemsText}\n {unknownItemsText}\n \n \n \n {\n setTextFilter(event.target.value);\n }}\n />\n {additionalItemsLabels && (\n
    \n {\n setSelectedItem([]);\n setShowAdditionalItems(checked);\n }}\n />\n \n
    \n )}\n
    \n
    \n \n
    \n {occurrenceData.length > 0 && (\n
    \n \n
    \n )}\n
    \n );\n}\n","import { Input } from '@/components/shadcn-ui/input';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { useState } from 'react';\n\nexport type SearchBarProps = {\n className?: string;\n /**\n * Callback fired to handle the search query when button pressed\n *\n * @param searchQuery\n */\n onSearch: (searchQuery: string) => void;\n\n /** Optional string that appears in the search bar without a search string */\n placeholder?: string;\n\n /** Optional boolean to set the input base to full width */\n isFullWidth?: boolean;\n};\n\nexport default function SearchBar({\n className,\n onSearch,\n placeholder,\n isFullWidth,\n}: SearchBarProps) {\n const [searchQuery, setSearchQuery] = useState('');\n\n const handleInputChange = (searchString: string) => {\n setSearchQuery(searchString);\n onSearch(searchString);\n };\n\n return (\n handleInputChange(e.target.value)}\n />\n );\n}\n","// adapted from: https://github.com/shadcn-ui/ui/discussions/752\n\n'use client';\n\nimport { TabsContentProps, TabsListProps, TabsTriggerProps } from '@/components/shadcn-ui/tabs';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport * as TabsPrimitive from '@radix-ui/react-tabs';\nimport React from 'react';\n\nexport type VerticalTabsProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport type LeftTabsTriggerProps = TabsTriggerProps & {\n value: string;\n ref?: React.Ref;\n};\n\nexport const VerticalTabs = React.forwardRef<\n React.ElementRef,\n VerticalTabsProps\n>(({ className, ...props }, ref) => (\n \n));\n\nVerticalTabs.displayName = TabsPrimitive.List.displayName;\n\nexport const VerticalTabsList = React.forwardRef<\n React.ElementRef,\n TabsListProps\n>(({ className, ...props }, ref) => (\n \n));\nVerticalTabsList.displayName = TabsPrimitive.List.displayName;\n\nexport const VerticalTabsTrigger = React.forwardRef<\n React.ElementRef,\n LeftTabsTriggerProps\n>(({ className, ...props }, ref) => (\n \n));\n\nexport const VerticalTabsContent = React.forwardRef<\n React.ElementRef,\n TabsContentProps\n>(({ className, ...props }, ref) => (\n \n));\nVerticalTabsContent.displayName = TabsPrimitive.Content.displayName;\n","import SearchBar from '@/components/basics/search-bar.component';\nimport {\n VerticalTabs,\n VerticalTabsContent,\n VerticalTabsList,\n VerticalTabsTrigger,\n} from '@/components/basics/tabs-vertical';\nimport { ReactNode } from 'react';\n\nexport type TabKeyValueContent = {\n key: string;\n value: string;\n content: ReactNode;\n};\n\nexport type TabNavigationContentSearchProps = {\n /** List of values and keys for each tab this component should provide */\n tabList: TabKeyValueContent[];\n\n /** Handler to run when the value of the search bar changes */\n onSearch: (searchQuery: string) => void;\n\n /** Optional placeholder for the search bar */\n searchPlaceholder?: string;\n\n /** Optional title to include in the header */\n headerTitle?: string;\n\n /** Optional flag to make the search bar appear full width */\n isSearchBarFullWidth?: boolean;\n\n /** Text direction ltr or rtl */\n direction?: 'ltr' | 'rtl';\n};\n\nexport default function TabNavigationContentSearch({\n tabList,\n onSearch,\n searchPlaceholder,\n headerTitle,\n isSearchBarFullWidth = false,\n direction = 'ltr',\n}: TabNavigationContentSearchProps) {\n return (\n
    \n
    \n {headerTitle ?

    {headerTitle}

    : ''}\n \n
    \n \n \n {tabList.map((tab) => (\n \n {tab.value}\n \n ))}\n \n {tabList.map((tab) => (\n \n {tab.content}\n \n ))}\n \n
    \n );\n}\n","import React from 'react';\nimport * as SeparatorPrimitive from '@radix-ui/react-separator';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Separator = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, orientation = 'horizontal', decorative = true, ...props }, ref) => (\n \n));\nSeparator.displayName = SeparatorPrimitive.Root.displayName;\n\nexport { Separator };\n","'use client';\n\nimport * as React from 'react';\nimport * as SheetPrimitive from '@radix-ui/react-dialog';\nimport { cva, type VariantProps } from 'class-variance-authority';\nimport { X } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Sheet = SheetPrimitive.Root;\n\nconst SheetTrigger = SheetPrimitive.Trigger;\n\nconst SheetClose = SheetPrimitive.Close;\n\nconst SheetPortal = SheetPrimitive.Portal;\n\nconst SheetOverlay = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSheetOverlay.displayName = SheetPrimitive.Overlay.displayName;\n\nconst sheetVariants = cva(\n 'pr-twp tw-fixed tw-z-50 tw-gap-4 tw-bg-background tw-p-6 tw-shadow-lg tw-transition tw-ease-in-out data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-duration-300 data-[state=open]:tw-duration-500',\n {\n variants: {\n side: {\n top: 'tw-inset-x-0 tw-top-0 tw-border-b data-[state=closed]:tw-slide-out-to-top data-[state=open]:tw-slide-in-from-top',\n bottom:\n 'tw-inset-x-0 tw-bottom-0 tw-border-t data-[state=closed]:tw-slide-out-to-bottom data-[state=open]:tw-slide-in-from-bottom',\n left: 'tw-inset-y-0 tw-left-0 tw-h-full tw-w-3/4 tw-border-r data-[state=closed]:tw-slide-out-to-left data-[state=open]:tw-slide-in-from-left sm:tw-max-w-sm',\n right:\n 'tw-inset-y-0 tw-right-0 tw-h-full tw-w-3/4 tw- tw-border-l data-[state=closed]:tw-slide-out-to-right data-[state=open]:tw-slide-in-from-right sm:tw-max-w-sm',\n },\n },\n defaultVariants: {\n side: 'right',\n },\n },\n);\n\ninterface SheetContentProps\n extends React.ComponentPropsWithoutRef,\n VariantProps {}\n\nconst SheetContent = React.forwardRef<\n React.ElementRef,\n SheetContentProps\n>(({ side = 'right', className, children, ...props }, ref) => (\n \n \n \n {children}\n \n \n Close\n \n \n \n));\nSheetContent.displayName = SheetPrimitive.Content.displayName;\n\nfunction SheetHeader({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nSheetHeader.displayName = 'SheetHeader';\n\nfunction SheetFooter({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nSheetFooter.displayName = 'SheetFooter';\n\nconst SheetTitle = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSheetTitle.displayName = SheetPrimitive.Title.displayName;\n\nconst SheetDescription = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSheetDescription.displayName = SheetPrimitive.Description.displayName;\n\nexport {\n Sheet,\n SheetPortal,\n SheetOverlay,\n SheetTrigger,\n SheetClose,\n SheetContent,\n SheetHeader,\n SheetFooter,\n SheetTitle,\n SheetDescription,\n};\n","import React from 'react';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nfunction Skeleton({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\n\nexport { Skeleton };\n","import React from 'react';\nimport * as TooltipPrimitive from '@radix-ui/react-tooltip';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst TooltipProvider = TooltipPrimitive.Provider;\n\nconst Tooltip = TooltipPrimitive.Root;\n\nconst TooltipTrigger = TooltipPrimitive.Trigger;\n\nconst TooltipContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, sideOffset = 4, ...props }, ref) => (\n \n));\nTooltipContent.displayName = TooltipPrimitive.Content.displayName;\n\nexport { Tooltip, TooltipTrigger, TooltipContent, TooltipProvider };\n","import * as React from 'react';\n\nconst MOBILE_BREAKPOINT = 768;\n\nexport default function useIsMobile() {\n const [isMobile, setIsMobile] = React.useState(undefined);\n\n React.useEffect(() => {\n const mql = window.matchMedia(`(max-width: ${MOBILE_BREAKPOINT - 1}px)`);\n const onChange = () => {\n setIsMobile(window.innerWidth < MOBILE_BREAKPOINT);\n };\n mql.addEventListener('change', onChange);\n setIsMobile(window.innerWidth < MOBILE_BREAKPOINT);\n return () => mql.removeEventListener('change', onChange);\n }, []);\n\n return !!isMobile;\n}\n","import React from 'react';\nimport { Slot } from '@radix-ui/react-slot';\nimport { VariantProps, cva } from 'class-variance-authority';\nimport { PanelLeft } from 'lucide-react';\n\nimport { Button } from '@/components/shadcn-ui/button';\nimport { Input } from '@/components/shadcn-ui/input';\nimport { Separator } from '@/components/shadcn-ui/separator';\nimport { Sheet, SheetContent } from '@/components/shadcn-ui/sheet';\nimport { Skeleton } from '@/components/shadcn-ui/skeleton';\nimport {\n Tooltip,\n TooltipContent,\n TooltipProvider,\n TooltipTrigger,\n} from '@/components/shadcn-ui/tooltip';\nimport useIsMobile from '@/components/hooks/use-mobile';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst SIDEBAR_COOKIE_NAME = 'sidebar:state';\nconst SIDEBAR_COOKIE_MAX_AGE = 60 * 60 * 24 * 7;\nconst SIDEBAR_WIDTH = '16rem';\nconst SIDEBAR_WIDTH_MOBILE = '18rem';\nconst SIDEBAR_WIDTH_ICON = '3rem';\nconst SIDEBAR_KEYBOARD_SHORTCUT = 'b';\n\ntype SidebarContextProps = {\n state: 'expanded' | 'collapsed';\n open: boolean;\n setOpen: (open: boolean) => void;\n openMobile: boolean;\n setOpenMobile: (open: boolean) => void;\n isMobile: boolean;\n toggleSidebar: () => void;\n};\n\nconst SidebarContext = React.createContext(undefined);\n\nfunction useSidebar() {\n const context = React.useContext(SidebarContext);\n if (!context) {\n throw new Error('useSidebar must be used within a SidebarProvider.');\n }\n\n return context;\n}\n\nconst SidebarProvider = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & {\n defaultOpen?: boolean;\n open?: boolean;\n onOpenChange?: (open: boolean) => void;\n }\n>(\n (\n {\n defaultOpen = true,\n open: openProp,\n onOpenChange: setOpenProp,\n className,\n style,\n children,\n ...props\n },\n ref,\n ) => {\n const isMobile = useIsMobile();\n const [openMobile, setOpenMobile] = React.useState(false);\n\n // This is the internal state of the sidebar.\n // We use openProp and setOpenProp for control from outside the component.\n const [_open, _setOpen] = React.useState(defaultOpen);\n const isOpen = openProp ?? _open;\n const setOpen = React.useCallback(\n (value: boolean | ((value: boolean) => boolean)) => {\n const openState = typeof value === 'function' ? value(isOpen) : value;\n if (setOpenProp) {\n setOpenProp(openState);\n } else {\n _setOpen(openState);\n }\n\n // This sets the cookie to keep the sidebar state.\n document.cookie = `${SIDEBAR_COOKIE_NAME}=${openState}; path=/; max-age=${SIDEBAR_COOKIE_MAX_AGE}`;\n },\n [setOpenProp, isOpen],\n );\n\n // Helper to toggle the sidebar.\n const toggleSidebar = React.useCallback(() => {\n return isMobile ? setOpenMobile((open) => !open) : setOpen((open) => !open);\n }, [isMobile, setOpen, setOpenMobile]);\n\n // Adds a keyboard shortcut to toggle the sidebar.\n React.useEffect(() => {\n const handleKeyDown = (event: KeyboardEvent) => {\n if (event.key === SIDEBAR_KEYBOARD_SHORTCUT && (event.metaKey || event.ctrlKey)) {\n event.preventDefault();\n toggleSidebar();\n }\n };\n\n window.addEventListener('keydown', handleKeyDown);\n return () => window.removeEventListener('keydown', handleKeyDown);\n }, [toggleSidebar]);\n\n // We add a state so that we can do data-state=\"expanded\" or \"collapsed\".\n // This makes it easier to style the sidebar with Tailwind classes.\n const state = isOpen ? 'expanded' : 'collapsed';\n\n const contextValue = React.useMemo(\n () => ({\n state,\n open: isOpen,\n setOpen,\n isMobile,\n openMobile,\n setOpenMobile,\n toggleSidebar,\n }),\n [state, isOpen, setOpen, isMobile, openMobile, setOpenMobile, toggleSidebar],\n );\n\n return (\n \n \n \n {children}\n
    \n \n \n );\n },\n);\nSidebarProvider.displayName = 'SidebarProvider';\n\nconst Sidebar = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & {\n side?: 'left' | 'right';\n variant?: 'sidebar' | 'floating' | 'inset';\n collapsible?: 'offcanvas' | 'icon' | 'none';\n }\n>(\n (\n {\n side = 'left',\n variant = 'sidebar',\n collapsible = 'offcanvas',\n className,\n children,\n ...props\n },\n ref,\n ) => {\n const { isMobile, state, openMobile, setOpenMobile } = useSidebar();\n\n if (collapsible === 'none') {\n return (\n \n {children}\n
    \n );\n }\n\n if (isMobile) {\n return (\n \n button]:tw-hidden\"\n style={\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n {\n '--sidebar-width': SIDEBAR_WIDTH_MOBILE,\n } as React.CSSProperties\n }\n side={side}\n >\n
    {children}
    \n \n
    \n );\n }\n\n return (\n \n {/* This is what handles the sidebar gap on desktop */}\n \n \n \n {children}\n
    \n
    \n
    \n );\n },\n);\nSidebar.displayName = 'Sidebar';\n\nconst SidebarTrigger = React.forwardRef<\n React.ElementRef,\n React.ComponentProps\n>(({ className, onClick, ...props }, ref) => {\n const { toggleSidebar } = useSidebar();\n\n return (\n {\n onClick?.(event);\n toggleSidebar();\n }}\n {...props}\n >\n \n Toggle Sidebar\n \n );\n});\nSidebarTrigger.displayName = 'SidebarTrigger';\n\nconst SidebarRail = React.forwardRef>(\n ({ className, ...props }, ref) => {\n const { toggleSidebar } = useSidebar();\n\n return (\n \n );\n },\n);\nSidebarRail.displayName = 'SidebarRail';\n\nconst SidebarInset = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarInset.displayName = 'SidebarInset';\n\nconst SidebarInput = React.forwardRef<\n React.ElementRef,\n React.ComponentProps\n>(({ className, ...props }, ref) => {\n return (\n \n );\n});\nSidebarInput.displayName = 'SidebarInput';\n\nconst SidebarHeader = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarHeader.displayName = 'SidebarHeader';\n\nconst SidebarFooter = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarFooter.displayName = 'SidebarFooter';\n\nconst SidebarSeparator = React.forwardRef<\n React.ElementRef,\n React.ComponentProps\n>(({ className, ...props }, ref) => {\n return (\n \n );\n});\nSidebarSeparator.displayName = 'SidebarSeparator';\n\nconst SidebarContent = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarContent.displayName = 'SidebarContent';\n\nconst SidebarGroup = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarGroup.displayName = 'SidebarGroup';\n\nconst SidebarGroupLabel = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & { asChild?: boolean }\n>(({ className, asChild = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'div';\n\n return (\n svg]:tw-size-4 [&>svg]:tw-shrink-0',\n 'group-data-[collapsible=icon]:tw--mt-8 group-data-[collapsible=icon]:tw-opacity-0',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarGroupLabel.displayName = 'SidebarGroupLabel';\n\nconst SidebarGroupAction = React.forwardRef<\n HTMLButtonElement,\n React.ComponentProps<'button'> & { asChild?: boolean }\n>(({ className, asChild = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'button';\n\n return (\n svg]:tw-size-4 [&>svg]:tw-shrink-0',\n // Increases the hit area of the button on mobile.\n 'after:tw-absolute after:tw--inset-2 after:md:tw-hidden',\n 'group-data-[collapsible=icon]:tw-hidden',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarGroupAction.displayName = 'SidebarGroupAction';\n\nconst SidebarGroupContent = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarGroupContent.displayName = 'SidebarGroupContent';\n\nconst SidebarMenu = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenu.displayName = 'SidebarMenu';\n\nconst SidebarMenuItem = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenuItem.displayName = 'SidebarMenuItem';\n\nconst sidebarMenuButtonVariants = cva(\n // Removed data-[active=true]:tw-bg-sidebar-accent\n 'tw-peer/menu-button tw-flex tw-w-full tw-items-center tw-gap-2 tw-overflow-hidden tw-rounded-md tw-p-2 tw-text-left tw-text-sm tw-outline-none tw-ring-sidebar-ring tw-transition-[width,height,padding] hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground focus-visible:tw-ring-2 active:tw-bg-sidebar-accent active:tw-text-sidebar-accent-foreground disabled:tw-pointer-events-none disabled:tw-opacity-50 tw-group-has-[[data-sidebar=menu-action]]/menu-item:pr-8 aria-disabled:tw-pointer-events-none aria-disabled:tw-opacity-50 data-[active=true]:tw-font-medium data-[active=true]:tw-text-sidebar-accent-foreground data-[state=open]:hover:tw-bg-sidebar-accent data-[state=open]:hover:tw-text-sidebar-accent-foreground group-data-[collapsible=icon]:tw-!size-8 group-data-[collapsible=icon]:tw-!p-2 [&>span:last-child]:tw-truncate [&>svg]:tw-size-4 [&>svg]:tw-shrink-0',\n {\n variants: {\n variant: {\n default: 'hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground',\n outline:\n 'tw-bg-background tw-shadow-[0_0_0_1px_hsl(var(--sidebar-border))] hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground hover:tw-shadow-[0_0_0_1px_hsl(var(--sidebar-accent))]',\n },\n size: {\n default: 'tw-h-8 tw-text-sm',\n sm: 'tw-h-7 tw-text-xs',\n lg: 'tw-h-12 tw-text-sm group-data-[collapsible=icon]:tw-!p-0',\n },\n },\n defaultVariants: {\n variant: 'default',\n size: 'default',\n },\n },\n);\n\nconst SidebarMenuButton = React.forwardRef<\n HTMLButtonElement,\n React.ComponentProps<'button'> & {\n asChild?: boolean;\n isActive?: boolean;\n tooltip?: string | React.ComponentProps;\n } & VariantProps\n>(\n (\n {\n asChild = false,\n isActive = false,\n variant = 'default',\n size = 'default',\n tooltip,\n className,\n ...props\n },\n ref,\n ) => {\n const Comp = asChild ? Slot : 'button';\n const { isMobile, state } = useSidebar();\n\n const button = (\n \n );\n\n if (!tooltip) {\n return button;\n }\n\n if (typeof tooltip === 'string') {\n // eslint-disable-next-line no-param-reassign\n tooltip = {\n children: tooltip,\n };\n }\n\n return (\n \n {button}\n \n );\n },\n);\nSidebarMenuButton.displayName = 'SidebarMenuButton';\n\nconst SidebarMenuAction = React.forwardRef<\n HTMLButtonElement,\n React.ComponentProps<'button'> & {\n asChild?: boolean;\n showOnHover?: boolean;\n }\n>(({ className, asChild = false, showOnHover = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'button';\n\n return (\n svg]:tw-size-4 [&>svg]:tw-shrink-0',\n // Increases the hit area of the button on mobile.\n 'after:tw-absolute after:tw--inset-2 after:md:tw-hidden',\n 'tw-peer-data-[size=sm]/menu-button:top-1',\n 'tw-peer-data-[size=default]/menu-button:top-1.5',\n 'tw-peer-data-[size=lg]/menu-button:top-2.5',\n 'group-data-[collapsible=icon]:tw-hidden',\n showOnHover &&\n 'tw-group-focus-within/menu-item:opacity-100 tw-group-hover/menu-item:opacity-100 tw-peer-data-[active=true]/menu-button:text-sidebar-accent-foreground data-[state=open]:tw-opacity-100 md:tw-opacity-0',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarMenuAction.displayName = 'SidebarMenuAction';\n\nconst SidebarMenuBadge = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenuBadge.displayName = 'SidebarMenuBadge';\n\nconst SidebarMenuSkeleton = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & {\n showIcon?: boolean;\n }\n>(({ className, showIcon = false, ...props }, ref) => {\n // Random width between 50 to 90%.\n const width = React.useMemo(() => {\n return `${Math.floor(Math.random() * 40) + 50}%`;\n }, []);\n\n return (\n \n {showIcon && (\n \n )}\n \n
    \n );\n});\nSidebarMenuSkeleton.displayName = 'SidebarMenuSkeleton';\n\nconst SidebarMenuSub = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenuSub.displayName = 'SidebarMenuSub';\n\nconst SidebarMenuSubItem = React.forwardRef>(\n ({ ...props }, ref) =>
  • ,\n);\nSidebarMenuSubItem.displayName = 'SidebarMenuSubItem';\n\nconst SidebarMenuSubButton = React.forwardRef<\n HTMLAnchorElement,\n React.ComponentProps<'a'> & {\n asChild?: boolean;\n size?: 'sm' | 'md';\n isActive?: boolean;\n }\n>(({ asChild = false, size = 'md', isActive, className, ...props }, ref) => {\n const Comp = asChild ? Slot : 'a';\n\n return (\n span:last-child]:tw-truncate [&>svg]:tw-size-4 [&>svg]:tw-shrink-0 [&>svg]:tw-text-sidebar-accent-foreground',\n 'data-[active=true]:tw-bg-sidebar-accent data-[active=true]:tw-text-sidebar-accent-foreground',\n size === 'sm' && 'tw-text-xs',\n size === 'md' && 'tw-text-sm',\n 'group-data-[collapsible=icon]:tw-hidden',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarMenuSubButton.displayName = 'SidebarMenuSubButton';\n\nexport {\n Sidebar,\n SidebarContent,\n SidebarFooter,\n SidebarGroup,\n SidebarGroupAction,\n SidebarGroupContent,\n SidebarGroupLabel,\n SidebarHeader,\n SidebarInput,\n SidebarInset,\n SidebarMenu,\n SidebarMenuAction,\n SidebarMenuBadge,\n SidebarMenuButton,\n SidebarMenuItem,\n SidebarMenuSkeleton,\n SidebarMenuSub,\n SidebarMenuSubButton,\n SidebarMenuSubItem,\n SidebarProvider,\n SidebarRail,\n SidebarSeparator,\n SidebarTrigger,\n useSidebar,\n};\n","import ComboBox, { ComboBoxOption } from '@/components/basics/combo-box.component';\nimport {\n Sidebar,\n SidebarContent,\n SidebarGroup,\n SidebarGroupLabel,\n SidebarGroupContent,\n SidebarMenu,\n SidebarMenuItem,\n SidebarMenuButton,\n} from '@/components/shadcn-ui/sidebar';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { useCallback } from 'react';\n\nexport type SelectedSettingsSidebarItem = {\n label: string;\n projectId?: string;\n};\n\nexport type ProjectOptions = { projectId: string; projectName: string };\n\nexport type SettingsSidebarProps = {\n /** Optional id for testing */\n id?: string;\n\n /** Extension labels from contribution */\n extensionLabels: string[];\n\n /** Project names and ids */\n projectOptions: ProjectOptions[];\n\n /** Handler for selecting a sidebar item */\n handleSelectSidebarItem: (key: string, projectId?: string) => void;\n\n /** The current selected value in the sidebar */\n selectedSidebarItem: SelectedSettingsSidebarItem;\n};\n\nexport default function SettingsSidebar({\n id,\n extensionLabels,\n projectOptions,\n handleSelectSidebarItem,\n selectedSidebarItem,\n}: SettingsSidebarProps) {\n const handleSelectItem = useCallback(\n (item: string, projectId?: string) => {\n handleSelectSidebarItem(item, projectId);\n },\n [handleSelectSidebarItem],\n );\n\n const getProjectNameFromProjectId = useCallback(\n (projectId: string) => {\n const project = projectOptions.find((option) => option.projectId === projectId);\n return project ? project.projectName : projectId;\n },\n [projectOptions],\n );\n\n const getIsActive: (label: string) => boolean = useCallback(\n (label: string) => !selectedSidebarItem.projectId && label === selectedSidebarItem.label,\n [selectedSidebarItem],\n );\n\n return (\n \n \n \n Extensions\n \n \n {extensionLabels.map((label) => (\n \n handleSelectItem(label, undefined)}\n isActive={getIsActive(label)}\n >\n {label}\n \n \n ))}\n \n \n \n \n Projects\n \n option.projectId)}\n getOptionLabel={(projectId: ComboBoxOption) => {\n // This function expects a ComboBoxOption, but we know it is a string\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n return getProjectNameFromProjectId(projectId as string);\n }}\n buttonPlaceholder=\"Type or select project\"\n onChange={(projectId: string) => {\n const selectedProjectName = getProjectNameFromProjectId(projectId);\n handleSelectItem(selectedProjectName, projectId);\n }}\n value={selectedSidebarItem?.projectId ?? undefined}\n />\n \n \n \n \n );\n}\n","import { SidebarInset, SidebarProvider } from '@/components/shadcn-ui/sidebar';\nimport { PropsWithChildren } from 'react';\nimport SearchBar from '@/components/basics/search-bar.component';\nimport SettingsSidebar, { SettingsSidebarProps } from './settings-sidebar.component';\n\nexport type SettingsSidebarContentSearchProps = SettingsSidebarProps &\n PropsWithChildren & {\n /** Optional id for testing */\n id?: string;\n\n /** Text direction ltr or rtl */\n direction?: 'ltr' | 'rtl';\n\n /** Handler to run when the value of the search bar changes */\n onSearch: (searchQuery: string) => void;\n };\n\nexport default function SettingsSidebarContentSearch({\n id,\n direction = 'ltr',\n extensionLabels,\n projectOptions,\n children,\n handleSelectSidebarItem,\n selectedSidebarItem,\n onSearch,\n}: SettingsSidebarContentSearchProps) {\n return (\n
    \n
    \n \n
    \n \n \n {children}\n \n
    \n );\n}\n","import { Button } from '@/components/shadcn-ui/button';\nimport {\n Select,\n SelectContent,\n SelectGroup,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\nimport {\n Table,\n TableBody,\n TableCell,\n TableHead,\n TableHeader,\n TableRow,\n} from '@/components/shadcn-ui/table';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Canon } from '@sillsdev/scripture';\nimport {\n Cell,\n ColumnDef,\n flexRender,\n getCoreRowModel,\n getExpandedRowModel,\n getGroupedRowModel,\n getSortedRowModel,\n GroupingState,\n Row,\n RowSelectionState,\n SortingState,\n useReactTable,\n} from '@tanstack/react-table';\nimport '@/components/advanced/scripture-results-viewer/scripture-results-viewer.component.css';\nimport {\n compareScrRefs,\n formatScrRef,\n ScriptureSelection,\n scrRefToBBBCCCVVV,\n} from 'platform-bible-utils';\nimport { MouseEvent, useEffect, useMemo, useState } from 'react';\nimport { ChevronDown, ChevronLeft, ChevronRight } from 'lucide-react';\n\n/**\n * Information (e.g., a checking error or some other type of \"transient\" annotation) about something\n * noteworthy at a specific place in an instance of the Scriptures.\n */\nexport type ScriptureItemDetail = ScriptureSelection & {\n /**\n * Text of the error, note, etc. In the future, we might want to support something more than just\n * text so that a JSX element could be provided with a link or some other controls related to the\n * issue being reported.\n */\n detail: string;\n};\n\n/**\n * A uniquely identifiable source of results that can be displayed in the ScriptureResultsViewer.\n * Generally, the source will be a particular Scripture check, but there may be other types of\n * sources.\n */\nexport type ResultsSource = {\n /**\n * Uniquely identifies the source.\n *\n * @type {string}\n */\n id: string;\n\n /**\n * Name (potentially localized) of the source, suitable for display in the UI.\n *\n * @type {string}\n */\n displayName: string;\n};\n\nexport type ScriptureSrcItemDetail = ScriptureItemDetail & {\n /** Source/type of detail. Can be used for grouping. */\n source: ResultsSource;\n};\n\n/**\n * Represents a set of results keyed by Scripture reference. Generally, the source will be a\n * particular Scripture check, but this type also allows for other types of uniquely identifiable\n * sources.\n */\nexport type ResultsSet = {\n /**\n * The backing source associated with this set of results.\n *\n * @type {ResultsSource}\n */\n source: ResultsSource;\n\n /**\n * Array of Scripture item details (messages keyed by Scripture reference).\n *\n * @type {ScriptureItemDetail[]}\n */\n data: ScriptureItemDetail[];\n};\n\nconst scrBookColId = 'scrBook';\nconst scrRefColId = 'scrRef';\nconst typeColId = 'source';\nconst detailsColId = 'details';\n\nconst defaultScrRefColumnName = 'Scripture Reference';\nconst defaultScrBookGroupName = 'Scripture Book';\nconst defaultTypeColumnName = 'Type';\nconst defaultDetailsColumnName = 'Details';\n\nexport type ScriptureResultsViewerColumnInfo = {\n /** Optional header to display for the Reference column. Default value: 'Scripture Reference'. */\n scriptureReferenceColumnName?: string;\n\n /** Optional text to display to refer to the Scripture book group. Default value: 'Scripture Book'. */\n scriptureBookGroupName?: string;\n\n /** Optional header to display for the Type column. Default value: 'Type'. */\n typeColumnName?: string;\n\n /** Optional header to display for the Details column. Default value: 'Details' */\n detailsColumnName?: string;\n};\n\nexport type ScriptureResultsViewerProps = ScriptureResultsViewerColumnInfo & {\n /** Groups of ScriptureItemDetail objects from particular sources (e.g., Scripture checks) */\n sources: ResultsSet[];\n\n /** Flag indicating whether to display column headers. Default is false. */\n showColumnHeaders?: boolean;\n\n /** Flag indicating whether to display source column. Default is false. */\n showSourceColumn?: boolean;\n\n /** Callback function to notify when a row is selected */\n onRowSelected?: (selectedRow: ScriptureSrcItemDetail | undefined) => void;\n\n /** Text direction ltr or rtl */\n direction?: 'ltr' | 'rtl';\n};\n\nfunction getColumns(\n colInfo?: ScriptureResultsViewerColumnInfo,\n showSourceColumn?: boolean,\n): ColumnDef[] {\n const showSrcCol = showSourceColumn ?? false;\n return [\n {\n accessorFn: (row) =>\n `${Canon.bookNumberToId(row.start.bookNum)} ${row.start.chapterNum}:${row.start.verseNum}`,\n id: scrBookColId,\n header: colInfo?.scriptureReferenceColumnName ?? defaultScrRefColumnName,\n cell: (info) => {\n const row = info.row.original;\n if (info.row.getIsGrouped()) {\n return Canon.bookNumberToEnglishName(row.start.bookNum);\n }\n return info.row.groupingColumnId === scrBookColId ? formatScrRef(row.start) : undefined;\n },\n getGroupingValue: (row) => row.start.bookNum,\n sortingFn: (a, b) => {\n return compareScrRefs(a.original.start, b.original.start);\n },\n enableGrouping: true,\n },\n {\n accessorFn: (row) => formatScrRef(row.start),\n id: scrRefColId,\n header: undefined,\n cell: (info) => {\n const row = info.row.original;\n return info.row.getIsGrouped() ? undefined : formatScrRef(row.start);\n },\n sortingFn: (a, b) => {\n return compareScrRefs(a.original.start, b.original.start);\n },\n enableGrouping: false,\n },\n {\n accessorFn: (row) => row.source.displayName,\n id: typeColId,\n header: showSrcCol ? (colInfo?.typeColumnName ?? defaultTypeColumnName) : undefined,\n cell: (info) => (showSrcCol || info.row.getIsGrouped() ? info.getValue() : undefined),\n getGroupingValue: (row) => row.source.id,\n sortingFn: (a, b) =>\n a.original.source.displayName.localeCompare(b.original.source.displayName),\n enableGrouping: true,\n },\n {\n accessorFn: (row) => row.detail,\n id: detailsColId,\n header: colInfo?.detailsColumnName ?? defaultDetailsColumnName,\n cell: (info) => info.getValue(),\n enableGrouping: false,\n },\n ];\n}\n\nconst toRefOrRange = (scriptureSelection: ScriptureSelection) => {\n if (!('offset' in scriptureSelection.start))\n throw new Error('No offset available in range start');\n if (scriptureSelection.end && !('offset' in scriptureSelection.end))\n throw new Error('No offset available in range end');\n const { offset: offsetStart } = scriptureSelection.start;\n let offsetEnd: number = 0;\n if (scriptureSelection.end) ({ offset: offsetEnd } = scriptureSelection.end);\n if (\n !scriptureSelection.end ||\n compareScrRefs(scriptureSelection.start, scriptureSelection.end) === 0\n )\n return `${scrRefToBBBCCCVVV(scriptureSelection.start)}+${offsetStart}`;\n return `${scrRefToBBBCCCVVV(scriptureSelection.start)}+${offsetStart}-${scrRefToBBBCCCVVV(scriptureSelection.end)}+${offsetEnd}`;\n};\n\nconst getRowKey = (row: ScriptureSrcItemDetail) =>\n `${toRefOrRange({ start: row.start, end: row.end })} ${row.source.displayName} ${row.detail}`;\n\n/**\n * Component to display a combined list of detailed items from one or more sources, where the items\n * are keyed primarily by Scripture reference. This is particularly useful for displaying a list of\n * results from Scripture checks, but more generally could be used to display any \"results\" from any\n * source(s). The component allows for grouping by Scripture book, source, or both. By default, it\n * displays somewhat \"tree-like\" which allows it to be more horizontally compact and intuitive. But\n * it also has the option of displaying as a traditional table with column headings (with or without\n * the source column showing).\n */\nexport default function ScriptureResultsViewer({\n sources,\n showColumnHeaders = false,\n showSourceColumn = false,\n scriptureReferenceColumnName,\n scriptureBookGroupName,\n typeColumnName,\n detailsColumnName,\n onRowSelected,\n direction = 'ltr',\n}: ScriptureResultsViewerProps) {\n const [grouping, setGrouping] = useState([]);\n const [sorting, setSorting] = useState([{ id: scrBookColId, desc: false }]);\n const [rowSelection, setRowSelection] = useState({});\n\n const scriptureResults = useMemo(\n () =>\n sources.flatMap((source) => {\n return source.data.map((item) => ({\n ...item,\n source: source.source,\n }));\n }),\n [sources],\n );\n\n const columns = useMemo(\n () =>\n getColumns(\n {\n scriptureReferenceColumnName,\n typeColumnName,\n detailsColumnName,\n },\n showSourceColumn,\n ),\n [scriptureReferenceColumnName, typeColumnName, detailsColumnName, showSourceColumn],\n );\n\n useEffect(() => {\n // Ensure sorting is applied correctly when grouped by type\n if (grouping.includes(typeColId)) {\n setSorting([\n { id: typeColId, desc: false },\n { id: scrBookColId, desc: false },\n ]);\n } else {\n setSorting([{ id: scrBookColId, desc: false }]);\n }\n }, [grouping]);\n\n const table = useReactTable({\n data: scriptureResults,\n columns,\n state: {\n grouping,\n sorting,\n rowSelection,\n },\n onGroupingChange: setGrouping,\n onSortingChange: setSorting,\n onRowSelectionChange: setRowSelection,\n getExpandedRowModel: getExpandedRowModel(),\n getGroupedRowModel: getGroupedRowModel(),\n getCoreRowModel: getCoreRowModel(),\n getSortedRowModel: getSortedRowModel(),\n getRowId: getRowKey,\n autoResetExpanded: false,\n enableMultiRowSelection: false,\n enableSubRowSelection: false,\n });\n\n useEffect(() => {\n if (onRowSelected) {\n const selectedRows = table.getSelectedRowModel().rowsById;\n const keys = Object.keys(selectedRows);\n if (keys.length === 1) {\n const selectedRow = scriptureResults.find((row) => getRowKey(row) === keys[0]) || undefined;\n if (selectedRow) onRowSelected(selectedRow);\n }\n }\n }, [rowSelection, scriptureResults, onRowSelected, table]);\n\n // Define possible grouping options\n const scrBookGroupName = scriptureBookGroupName ?? defaultScrBookGroupName;\n const typeGroupName = typeColumnName ?? defaultTypeColumnName;\n\n const groupingOptions = [\n { label: 'No Grouping', value: [] },\n { label: `Group by ${scrBookGroupName}`, value: [scrBookColId] },\n { label: `Group by ${typeGroupName}`, value: [typeColId] },\n {\n label: `Group by ${scrBookGroupName} and ${typeGroupName}`,\n value: [scrBookColId, typeColId],\n },\n {\n label: `Group by ${typeGroupName} and ${scrBookGroupName}`,\n value: [typeColId, scrBookColId],\n },\n ];\n\n const handleSelectChange = (selectedGrouping: string) => {\n setGrouping(JSON.parse(selectedGrouping));\n };\n\n const handleRowClick = (row: Row, event: MouseEvent) => {\n if (!row.getIsGrouped() && !row.getIsSelected()) {\n row.getToggleSelectedHandler()(event);\n }\n };\n\n const getEvenOrOddBandingStyle = (row: Row, index: number) => {\n if (row.getIsGrouped()) return '';\n // UX has now said they don't think they want banding. I'm leaving in the code to\n // set even and odd styles, but there's nothing in the CSS to style them differently.\n // The \"even\" style used to also have tw-bg-neutral-300 (along with even) to create\n // a visual banding effect. That could be added back in if UX changes the decision.\n return cn('banded-row', index % 2 === 0 ? 'even' : 'odd');\n };\n\n const getIndent = (\n groupingState: GroupingState,\n row: Row,\n cell: Cell,\n ) => {\n if (groupingState?.length === 0 || row.depth < cell.column.getGroupedIndex()) return undefined;\n if (row.getIsGrouped()) {\n switch (row.depth) {\n case 1:\n return 'tw-ps-4';\n default:\n return undefined;\n }\n }\n switch (row.depth) {\n case 1:\n return 'tw-ps-8';\n case 2:\n return 'tw-ps-12';\n default:\n return undefined;\n }\n };\n\n return (\n
    \n {!showColumnHeaders && (\n {\n handleSelectChange(value);\n }}\n >\n \n \n \n \n \n {groupingOptions.map((option) => (\n \n {option.label}\n \n ))}\n \n \n \n )}\n \n {showColumnHeaders && (\n \n {table.getHeaderGroups().map((headerGroup) => (\n \n {headerGroup.headers\n .filter((h) => h.column.columnDef.header)\n .map((header) => (\n /* For sticky column headers to work, we probably need to change the default definition of the shadcn Table component. See https://github.com/shadcn-ui/ui/issues/1151 */\n \n {header.isPlaceholder ? undefined : (\n
    \n {header.column.getCanGroup() ? (\n \n {header.column.getIsGrouped() ? `🛑` : `👊 `}\n \n ) : undefined}{' '}\n {flexRender(header.column.columnDef.header, header.getContext())}\n
    \n )}\n
    \n ))}\n
    \n ))}\n
    \n )}\n \n {table.getRowModel().rows.map((row, rowIndex) => {\n return (\n handleRowClick(row, event)}\n >\n {row.getVisibleCells().map((cell) => {\n if (\n cell.getIsPlaceholder() ||\n (cell.column.columnDef.enableGrouping &&\n !cell.getIsGrouped() &&\n (cell.column.columnDef.id !== typeColId || !showSourceColumn))\n )\n return undefined;\n return (\n \n {(() => {\n if (cell.getIsGrouped()) {\n return (\n \n {row.getIsExpanded() && }\n {!row.getIsExpanded() &&\n (direction === 'ltr' ? : )}{' '}\n {flexRender(cell.column.columnDef.cell, cell.getContext())} (\n {row.subRows.length})\n \n );\n }\n\n // if (cell.getIsAggregated()) {\n // flexRender(\n // cell.column.columnDef.aggregatedCell ?? cell.column.columnDef.cell,\n // cell.getContext(),\n // );\n // }\n\n return flexRender(cell.column.columnDef.cell, cell.getContext());\n })()}\n \n );\n })}\n \n );\n })}\n \n
    \n
    \n );\n}\n","import {\n getLocalizeKeyForScrollGroupId,\n LanguageStrings,\n ScrollGroupId,\n} from 'platform-bible-utils';\nimport {\n Select,\n SelectContent,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\n\nconst DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS = {\n [getLocalizeKeyForScrollGroupId('undefined')]: 'Ø',\n [getLocalizeKeyForScrollGroupId(0)]: 'A',\n [getLocalizeKeyForScrollGroupId(1)]: 'B',\n [getLocalizeKeyForScrollGroupId(2)]: 'C',\n [getLocalizeKeyForScrollGroupId(3)]: 'D',\n [getLocalizeKeyForScrollGroupId(4)]: 'E',\n [getLocalizeKeyForScrollGroupId(5)]: 'F',\n [getLocalizeKeyForScrollGroupId(6)]: 'G',\n [getLocalizeKeyForScrollGroupId(7)]: 'H',\n [getLocalizeKeyForScrollGroupId(8)]: 'I',\n [getLocalizeKeyForScrollGroupId(9)]: 'J',\n [getLocalizeKeyForScrollGroupId(10)]: 'K',\n [getLocalizeKeyForScrollGroupId(11)]: 'L',\n [getLocalizeKeyForScrollGroupId(12)]: 'M',\n [getLocalizeKeyForScrollGroupId(13)]: 'N',\n [getLocalizeKeyForScrollGroupId(14)]: 'O',\n [getLocalizeKeyForScrollGroupId(15)]: 'P',\n [getLocalizeKeyForScrollGroupId(16)]: 'Q',\n [getLocalizeKeyForScrollGroupId(17)]: 'R',\n [getLocalizeKeyForScrollGroupId(18)]: 'S',\n [getLocalizeKeyForScrollGroupId(19)]: 'T',\n [getLocalizeKeyForScrollGroupId(20)]: 'U',\n [getLocalizeKeyForScrollGroupId(21)]: 'V',\n [getLocalizeKeyForScrollGroupId(22)]: 'W',\n [getLocalizeKeyForScrollGroupId(23)]: 'X',\n [getLocalizeKeyForScrollGroupId(24)]: 'Y',\n [getLocalizeKeyForScrollGroupId(25)]: 'Z',\n};\n\nexport type ScrollGroupSelectorProps = {\n /**\n * List of scroll group ids to show to the user. Either a {@link ScrollGroupId} or `undefined` for\n * no scroll group\n */\n availableScrollGroupIds: (ScrollGroupId | undefined)[];\n /** Currently selected scroll group id. `undefined` for no scroll group */\n scrollGroupId: ScrollGroupId | undefined;\n /** Callback function run when the user tries to change the scroll group id */\n onChangeScrollGroupId: (newScrollGroupId: ScrollGroupId | undefined) => void;\n /**\n * Localized strings to use for displaying scroll group ids. Must be an object whose keys are\n * `getLocalizeKeyForScrollGroupId(scrollGroupId)` for all scroll group ids (and `undefined` if\n * included) in {@link ScrollGroupSelectorProps.availableScrollGroupIds} and whose values are the\n * localized strings to use for those scroll group ids.\n *\n * Defaults to English localizations of English alphabet for scroll groups 0-25 (e.g. 0 is A) and\n * Ø for `undefined`. Will fill in any that are not provided with these English localizations.\n * Also, if any values match the keys, the English localization will be used. This is useful in\n * case you want to pass in a temporary version of the localized strings while your localized\n * strings load.\n *\n * @example\n *\n * ```typescript\n * const myScrollGroupIdLocalizedStrings = {\n * [getLocalizeKeyForScrollGroupId('undefined')]: 'Ø',\n * [getLocalizeKeyForScrollGroupId(0)]: 'A',\n * [getLocalizeKeyForScrollGroupId(1)]: 'B',\n * [getLocalizeKeyForScrollGroupId(2)]: 'C',\n * [getLocalizeKeyForScrollGroupId(3)]: 'D',\n * [getLocalizeKeyForScrollGroupId(4)]: 'E',\n * };\n * ```\n *\n * @example\n *\n * ```tsx\n * const availableScrollGroupIds = [undefined, 0, 1, 2, 3, 4];\n *\n * const localizeKeys = getLocalizeKeysForScrollGroupIds();\n *\n * const [localizedStrings] = useLocalizedStrings(localizeKeys);\n *\n * ...\n *\n * \n * ```\n */\n localizedStrings?: LanguageStrings;\n};\n\n/** Selector component for choosing a scroll group */\nexport default function ScrollGroupSelector({\n availableScrollGroupIds,\n scrollGroupId,\n onChangeScrollGroupId,\n localizedStrings = {},\n}: ScrollGroupSelectorProps) {\n const localizedStringsDefaulted = {\n ...DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS,\n ...Object.fromEntries(\n Object.entries(localizedStrings).map(\n ([localizedStringKey, localizedStringValue]: [string, string]) => [\n localizedStringKey,\n localizedStringKey === localizedStringValue &&\n localizedStringKey in DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS\n ? DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS[localizedStringKey]\n : localizedStringValue,\n ],\n ),\n ),\n };\n return (\n \n onChangeScrollGroupId(\n newScrollGroupString === 'undefined' ? undefined : parseInt(newScrollGroupString, 10),\n )\n }\n >\n \n \n \n \n {availableScrollGroupIds.map((scrollGroupOptionId) => (\n \n {localizedStringsDefaulted[getLocalizeKeyForScrollGroupId(scrollGroupOptionId)]}\n \n ))}\n \n \n );\n}\n","import { PropsWithChildren } from 'react';\nimport { Separator } from '@/components/shadcn-ui/separator';\n\n/** Props for the SettingsList component, currently just children */\ntype SettingsListProps = PropsWithChildren;\n\n/**\n * SettingsList component is a wrapper for list items. Rendered with a formatted div\n *\n * @param children To populate the list with\n * @returns Formatted div encompassing the children\n */\nexport function SettingsList({ children }: SettingsListProps) {\n return
    {children}
    ;\n}\n\n/** Props for SettingsListItem component */\ntype SettingsListItemProps = PropsWithChildren & {\n /** Primary text of the list item */\n primary: string;\n\n /** Optional text of the list item */\n secondary?: string | undefined;\n\n /** Optional boolean to display a message if the children aren't loaded yet. Defaults to false */\n isLoading?: boolean;\n\n /** Optional message to display if isLoading */\n loadingMessage?: string;\n};\n\n/**\n * SettingsListItem component is a common list item. Rendered with a formatted div\n *\n * @param primary Primary text of the list item\n * @param secondary Optional secondary text of the list item\n * @param isLoading Optional, to display a message if the action component isn't generated yet,\n * defaults to false\n * @param children The action component(s) to provide for this item\n * @param loadingMessage Optional, message to display if isLoading\n * @returns Formatted div encompassing the list item content\n */\nexport function SettingsListItem({\n primary,\n secondary,\n children,\n isLoading = false,\n loadingMessage,\n}: SettingsListItemProps) {\n return (\n
    \n
    \n

    {primary}

    \n

    \n {secondary}\n

    \n
    \n\n {isLoading ? (\n

    {loadingMessage}

    \n ) : (\n
    {children}
    \n )}\n
    \n );\n}\n\n/** Props for SettingsListHeader component */\ntype SettingsListHeaderProps = {\n /** The primary text of the list header */\n primary: string;\n\n /** Optional secondary text of the list header */\n secondary?: string | undefined;\n\n /** Optional boolean to include a separator underneath the secondary text. Defaults to false */\n includeSeparator?: boolean;\n};\n\n/**\n * SettingsListHeader component displays text above the list\n *\n * @param primary The primary text of the list header\n * @param secondary Optional secondary text of the list header\n * @param includeSeparator Optional boolean to include a separator underneath the secondary text.\n * Defaults to false\n * @returns Formatted div with list header content\n */\nexport function SettingsListHeader({\n primary,\n secondary,\n includeSeparator = false,\n}: SettingsListHeaderProps) {\n return (\n
    \n
    \n

    {primary}

    \n

    {secondary}

    \n
    \n {includeSeparator ? : ''}\n
    \n );\n}\n","import Checkbox from '@/components/shadcn-ui/checkbox';\nimport { Label } from '@/components/shadcn-ui/label';\n\nexport type ChecklistProps = {\n /** Optional string representing the id attribute of the Checklist */\n id?: string;\n /** Optional string representing CSS class name(s) for styling */\n className?: string;\n /** Array of strings representing the checkable items */\n listItems: string[];\n /** Array of strings representing the checked items */\n selectedListItems: string[];\n /**\n * Function that is called when a checkbox item is selected or deselected\n *\n * @param item The string description for this item\n * @param selected True if selected, false if not selected\n */\n handleSelectListItem: (item: string, selected: boolean) => void;\n\n /**\n * Optional function creates a label for a provided checkable item\n *\n * @param item The item for which a label is to be created\n * @returns A string representing the label text for the checkbox associated with that item\n */\n createLabel?: (item: string) => string;\n};\n\n/** Renders a list of checkboxes. Each checkbox corresponds to an item from the `listItems` array. */\nexport default function Checklist({\n id,\n className,\n listItems,\n selectedListItems,\n handleSelectListItem,\n createLabel,\n}: ChecklistProps) {\n return (\n
    \n {listItems.map((item) => (\n
    \n handleSelectListItem(item, value)}\n />\n \n
    \n ))}\n
    \n );\n}\n","function _interopRequireDefault(obj) {\n return obj && obj.__esModule ? obj : {\n \"default\": obj\n };\n}\nmodule.exports = _interopRequireDefault, module.exports.__esModule = true, module.exports[\"default\"] = module.exports;","export default function chainPropTypes(propType1, propType2) {\n if (process.env.NODE_ENV === 'production') {\n return () => null;\n }\n return function validate(...args) {\n return propType1(...args) || propType2(...args);\n };\n}","export default function _extends() {\n _extends = Object.assign ? Object.assign.bind() : function (target) {\n for (var i = 1; i < arguments.length; i++) {\n var source = arguments[i];\n for (var key in source) {\n if (Object.prototype.hasOwnProperty.call(source, key)) {\n target[key] = source[key];\n }\n }\n }\n return target;\n };\n return _extends.apply(this, arguments);\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\n// https://github.com/sindresorhus/is-plain-obj/blob/main/index.js\nexport function isPlainObject(item) {\n if (typeof item !== 'object' || item === null) {\n return false;\n }\n const prototype = Object.getPrototypeOf(item);\n return (prototype === null || prototype === Object.prototype || Object.getPrototypeOf(prototype) === null) && !(Symbol.toStringTag in item) && !(Symbol.iterator in item);\n}\nfunction deepClone(source) {\n if (!isPlainObject(source)) {\n return source;\n }\n const output = {};\n Object.keys(source).forEach(key => {\n output[key] = deepClone(source[key]);\n });\n return output;\n}\nexport default function deepmerge(target, source, options = {\n clone: true\n}) {\n const output = options.clone ? _extends({}, target) : target;\n if (isPlainObject(target) && isPlainObject(source)) {\n Object.keys(source).forEach(key => {\n // Avoid prototype pollution\n if (key === '__proto__') {\n return;\n }\n if (isPlainObject(source[key]) && key in target && isPlainObject(target[key])) {\n // Since `output` is a clone of `target` and we have narrowed `target` in this block we can cast to the same type.\n output[key] = deepmerge(target[key], source[key], options);\n } else if (options.clone) {\n output[key] = isPlainObject(source[key]) ? deepClone(source[key]) : source[key];\n } else {\n output[key] = source[key];\n }\n });\n }\n return output;\n}","/** @license React v16.13.1\n * react-is.production.min.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';var b=\"function\"===typeof Symbol&&Symbol.for,c=b?Symbol.for(\"react.element\"):60103,d=b?Symbol.for(\"react.portal\"):60106,e=b?Symbol.for(\"react.fragment\"):60107,f=b?Symbol.for(\"react.strict_mode\"):60108,g=b?Symbol.for(\"react.profiler\"):60114,h=b?Symbol.for(\"react.provider\"):60109,k=b?Symbol.for(\"react.context\"):60110,l=b?Symbol.for(\"react.async_mode\"):60111,m=b?Symbol.for(\"react.concurrent_mode\"):60111,n=b?Symbol.for(\"react.forward_ref\"):60112,p=b?Symbol.for(\"react.suspense\"):60113,q=b?\nSymbol.for(\"react.suspense_list\"):60120,r=b?Symbol.for(\"react.memo\"):60115,t=b?Symbol.for(\"react.lazy\"):60116,v=b?Symbol.for(\"react.block\"):60121,w=b?Symbol.for(\"react.fundamental\"):60117,x=b?Symbol.for(\"react.responder\"):60118,y=b?Symbol.for(\"react.scope\"):60119;\nfunction z(a){if(\"object\"===typeof a&&null!==a){var u=a.$$typeof;switch(u){case c:switch(a=a.type,a){case l:case m:case e:case g:case f:case p:return a;default:switch(a=a&&a.$$typeof,a){case k:case n:case t:case r:case h:return a;default:return u}}case d:return u}}}function A(a){return z(a)===m}exports.AsyncMode=l;exports.ConcurrentMode=m;exports.ContextConsumer=k;exports.ContextProvider=h;exports.Element=c;exports.ForwardRef=n;exports.Fragment=e;exports.Lazy=t;exports.Memo=r;exports.Portal=d;\nexports.Profiler=g;exports.StrictMode=f;exports.Suspense=p;exports.isAsyncMode=function(a){return A(a)||z(a)===l};exports.isConcurrentMode=A;exports.isContextConsumer=function(a){return z(a)===k};exports.isContextProvider=function(a){return z(a)===h};exports.isElement=function(a){return\"object\"===typeof a&&null!==a&&a.$$typeof===c};exports.isForwardRef=function(a){return z(a)===n};exports.isFragment=function(a){return z(a)===e};exports.isLazy=function(a){return z(a)===t};\nexports.isMemo=function(a){return z(a)===r};exports.isPortal=function(a){return z(a)===d};exports.isProfiler=function(a){return z(a)===g};exports.isStrictMode=function(a){return z(a)===f};exports.isSuspense=function(a){return z(a)===p};\nexports.isValidElementType=function(a){return\"string\"===typeof a||\"function\"===typeof a||a===e||a===m||a===g||a===f||a===p||a===q||\"object\"===typeof a&&null!==a&&(a.$$typeof===t||a.$$typeof===r||a.$$typeof===h||a.$$typeof===k||a.$$typeof===n||a.$$typeof===w||a.$$typeof===x||a.$$typeof===y||a.$$typeof===v)};exports.typeOf=z;\n","/** @license React v16.13.1\n * react-is.development.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\n\n\nif (process.env.NODE_ENV !== \"production\") {\n (function() {\n'use strict';\n\n// The Symbol used to tag the ReactElement-like types. If there is no native Symbol\n// nor polyfill, then a plain number is used for performance.\nvar hasSymbol = typeof Symbol === 'function' && Symbol.for;\nvar REACT_ELEMENT_TYPE = hasSymbol ? Symbol.for('react.element') : 0xeac7;\nvar REACT_PORTAL_TYPE = hasSymbol ? Symbol.for('react.portal') : 0xeaca;\nvar REACT_FRAGMENT_TYPE = hasSymbol ? Symbol.for('react.fragment') : 0xeacb;\nvar REACT_STRICT_MODE_TYPE = hasSymbol ? Symbol.for('react.strict_mode') : 0xeacc;\nvar REACT_PROFILER_TYPE = hasSymbol ? Symbol.for('react.profiler') : 0xead2;\nvar REACT_PROVIDER_TYPE = hasSymbol ? Symbol.for('react.provider') : 0xeacd;\nvar REACT_CONTEXT_TYPE = hasSymbol ? Symbol.for('react.context') : 0xeace; // TODO: We don't use AsyncMode or ConcurrentMode anymore. They were temporary\n// (unstable) APIs that have been removed. Can we remove the symbols?\n\nvar REACT_ASYNC_MODE_TYPE = hasSymbol ? Symbol.for('react.async_mode') : 0xeacf;\nvar REACT_CONCURRENT_MODE_TYPE = hasSymbol ? Symbol.for('react.concurrent_mode') : 0xeacf;\nvar REACT_FORWARD_REF_TYPE = hasSymbol ? Symbol.for('react.forward_ref') : 0xead0;\nvar REACT_SUSPENSE_TYPE = hasSymbol ? Symbol.for('react.suspense') : 0xead1;\nvar REACT_SUSPENSE_LIST_TYPE = hasSymbol ? Symbol.for('react.suspense_list') : 0xead8;\nvar REACT_MEMO_TYPE = hasSymbol ? Symbol.for('react.memo') : 0xead3;\nvar REACT_LAZY_TYPE = hasSymbol ? Symbol.for('react.lazy') : 0xead4;\nvar REACT_BLOCK_TYPE = hasSymbol ? Symbol.for('react.block') : 0xead9;\nvar REACT_FUNDAMENTAL_TYPE = hasSymbol ? Symbol.for('react.fundamental') : 0xead5;\nvar REACT_RESPONDER_TYPE = hasSymbol ? Symbol.for('react.responder') : 0xead6;\nvar REACT_SCOPE_TYPE = hasSymbol ? Symbol.for('react.scope') : 0xead7;\n\nfunction isValidElementType(type) {\n return typeof type === 'string' || typeof type === 'function' || // Note: its typeof might be other than 'symbol' or 'number' if it's a polyfill.\n type === REACT_FRAGMENT_TYPE || type === REACT_CONCURRENT_MODE_TYPE || type === REACT_PROFILER_TYPE || type === REACT_STRICT_MODE_TYPE || type === REACT_SUSPENSE_TYPE || type === REACT_SUSPENSE_LIST_TYPE || typeof type === 'object' && type !== null && (type.$$typeof === REACT_LAZY_TYPE || type.$$typeof === REACT_MEMO_TYPE || type.$$typeof === REACT_PROVIDER_TYPE || type.$$typeof === REACT_CONTEXT_TYPE || type.$$typeof === REACT_FORWARD_REF_TYPE || type.$$typeof === REACT_FUNDAMENTAL_TYPE || type.$$typeof === REACT_RESPONDER_TYPE || type.$$typeof === REACT_SCOPE_TYPE || type.$$typeof === REACT_BLOCK_TYPE);\n}\n\nfunction typeOf(object) {\n if (typeof object === 'object' && object !== null) {\n var $$typeof = object.$$typeof;\n\n switch ($$typeof) {\n case REACT_ELEMENT_TYPE:\n var type = object.type;\n\n switch (type) {\n case REACT_ASYNC_MODE_TYPE:\n case REACT_CONCURRENT_MODE_TYPE:\n case REACT_FRAGMENT_TYPE:\n case REACT_PROFILER_TYPE:\n case REACT_STRICT_MODE_TYPE:\n case REACT_SUSPENSE_TYPE:\n return type;\n\n default:\n var $$typeofType = type && type.$$typeof;\n\n switch ($$typeofType) {\n case REACT_CONTEXT_TYPE:\n case REACT_FORWARD_REF_TYPE:\n case REACT_LAZY_TYPE:\n case REACT_MEMO_TYPE:\n case REACT_PROVIDER_TYPE:\n return $$typeofType;\n\n default:\n return $$typeof;\n }\n\n }\n\n case REACT_PORTAL_TYPE:\n return $$typeof;\n }\n }\n\n return undefined;\n} // AsyncMode is deprecated along with isAsyncMode\n\nvar AsyncMode = REACT_ASYNC_MODE_TYPE;\nvar ConcurrentMode = REACT_CONCURRENT_MODE_TYPE;\nvar ContextConsumer = REACT_CONTEXT_TYPE;\nvar ContextProvider = REACT_PROVIDER_TYPE;\nvar Element = REACT_ELEMENT_TYPE;\nvar ForwardRef = REACT_FORWARD_REF_TYPE;\nvar Fragment = REACT_FRAGMENT_TYPE;\nvar Lazy = REACT_LAZY_TYPE;\nvar Memo = REACT_MEMO_TYPE;\nvar Portal = REACT_PORTAL_TYPE;\nvar Profiler = REACT_PROFILER_TYPE;\nvar StrictMode = REACT_STRICT_MODE_TYPE;\nvar Suspense = REACT_SUSPENSE_TYPE;\nvar hasWarnedAboutDeprecatedIsAsyncMode = false; // AsyncMode should be deprecated\n\nfunction isAsyncMode(object) {\n {\n if (!hasWarnedAboutDeprecatedIsAsyncMode) {\n hasWarnedAboutDeprecatedIsAsyncMode = true; // Using console['warn'] to evade Babel and ESLint\n\n console['warn']('The ReactIs.isAsyncMode() alias has been deprecated, ' + 'and will be removed in React 17+. Update your code to use ' + 'ReactIs.isConcurrentMode() instead. It has the exact same API.');\n }\n }\n\n return isConcurrentMode(object) || typeOf(object) === REACT_ASYNC_MODE_TYPE;\n}\nfunction isConcurrentMode(object) {\n return typeOf(object) === REACT_CONCURRENT_MODE_TYPE;\n}\nfunction isContextConsumer(object) {\n return typeOf(object) === REACT_CONTEXT_TYPE;\n}\nfunction isContextProvider(object) {\n return typeOf(object) === REACT_PROVIDER_TYPE;\n}\nfunction isElement(object) {\n return typeof object === 'object' && object !== null && object.$$typeof === REACT_ELEMENT_TYPE;\n}\nfunction isForwardRef(object) {\n return typeOf(object) === REACT_FORWARD_REF_TYPE;\n}\nfunction isFragment(object) {\n return typeOf(object) === REACT_FRAGMENT_TYPE;\n}\nfunction isLazy(object) {\n return typeOf(object) === REACT_LAZY_TYPE;\n}\nfunction isMemo(object) {\n return typeOf(object) === REACT_MEMO_TYPE;\n}\nfunction isPortal(object) {\n return typeOf(object) === REACT_PORTAL_TYPE;\n}\nfunction isProfiler(object) {\n return typeOf(object) === REACT_PROFILER_TYPE;\n}\nfunction isStrictMode(object) {\n return typeOf(object) === REACT_STRICT_MODE_TYPE;\n}\nfunction isSuspense(object) {\n return typeOf(object) === REACT_SUSPENSE_TYPE;\n}\n\nexports.AsyncMode = AsyncMode;\nexports.ConcurrentMode = ConcurrentMode;\nexports.ContextConsumer = ContextConsumer;\nexports.ContextProvider = ContextProvider;\nexports.Element = Element;\nexports.ForwardRef = ForwardRef;\nexports.Fragment = Fragment;\nexports.Lazy = Lazy;\nexports.Memo = Memo;\nexports.Portal = Portal;\nexports.Profiler = Profiler;\nexports.StrictMode = StrictMode;\nexports.Suspense = Suspense;\nexports.isAsyncMode = isAsyncMode;\nexports.isConcurrentMode = isConcurrentMode;\nexports.isContextConsumer = isContextConsumer;\nexports.isContextProvider = isContextProvider;\nexports.isElement = isElement;\nexports.isForwardRef = isForwardRef;\nexports.isFragment = isFragment;\nexports.isLazy = isLazy;\nexports.isMemo = isMemo;\nexports.isPortal = isPortal;\nexports.isProfiler = isProfiler;\nexports.isStrictMode = isStrictMode;\nexports.isSuspense = isSuspense;\nexports.isValidElementType = isValidElementType;\nexports.typeOf = typeOf;\n })();\n}\n","'use strict';\n\nif (process.env.NODE_ENV === 'production') {\n module.exports = require('./cjs/react-is.production.min.js');\n} else {\n module.exports = require('./cjs/react-is.development.js');\n}\n","/*\nobject-assign\n(c) Sindre Sorhus\n@license MIT\n*/\n\n'use strict';\n/* eslint-disable no-unused-vars */\nvar getOwnPropertySymbols = Object.getOwnPropertySymbols;\nvar hasOwnProperty = Object.prototype.hasOwnProperty;\nvar propIsEnumerable = Object.prototype.propertyIsEnumerable;\n\nfunction toObject(val) {\n\tif (val === null || val === undefined) {\n\t\tthrow new TypeError('Object.assign cannot be called with null or undefined');\n\t}\n\n\treturn Object(val);\n}\n\nfunction shouldUseNative() {\n\ttry {\n\t\tif (!Object.assign) {\n\t\t\treturn false;\n\t\t}\n\n\t\t// Detect buggy property enumeration order in older V8 versions.\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=4118\n\t\tvar test1 = new String('abc'); // eslint-disable-line no-new-wrappers\n\t\ttest1[5] = 'de';\n\t\tif (Object.getOwnPropertyNames(test1)[0] === '5') {\n\t\t\treturn false;\n\t\t}\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=3056\n\t\tvar test2 = {};\n\t\tfor (var i = 0; i < 10; i++) {\n\t\t\ttest2['_' + String.fromCharCode(i)] = i;\n\t\t}\n\t\tvar order2 = Object.getOwnPropertyNames(test2).map(function (n) {\n\t\t\treturn test2[n];\n\t\t});\n\t\tif (order2.join('') !== '0123456789') {\n\t\t\treturn false;\n\t\t}\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=3056\n\t\tvar test3 = {};\n\t\t'abcdefghijklmnopqrst'.split('').forEach(function (letter) {\n\t\t\ttest3[letter] = letter;\n\t\t});\n\t\tif (Object.keys(Object.assign({}, test3)).join('') !==\n\t\t\t\t'abcdefghijklmnopqrst') {\n\t\t\treturn false;\n\t\t}\n\n\t\treturn true;\n\t} catch (err) {\n\t\t// We don't expect any of the above to throw, but better to be safe.\n\t\treturn false;\n\t}\n}\n\nmodule.exports = shouldUseNative() ? Object.assign : function (target, source) {\n\tvar from;\n\tvar to = toObject(target);\n\tvar symbols;\n\n\tfor (var s = 1; s < arguments.length; s++) {\n\t\tfrom = Object(arguments[s]);\n\n\t\tfor (var key in from) {\n\t\t\tif (hasOwnProperty.call(from, key)) {\n\t\t\t\tto[key] = from[key];\n\t\t\t}\n\t\t}\n\n\t\tif (getOwnPropertySymbols) {\n\t\t\tsymbols = getOwnPropertySymbols(from);\n\t\t\tfor (var i = 0; i < symbols.length; i++) {\n\t\t\t\tif (propIsEnumerable.call(from, symbols[i])) {\n\t\t\t\t\tto[symbols[i]] = from[symbols[i]];\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\n\treturn to;\n};\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar ReactPropTypesSecret = 'SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED';\n\nmodule.exports = ReactPropTypesSecret;\n","module.exports = Function.call.bind(Object.prototype.hasOwnProperty);\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar printWarning = function() {};\n\nif (process.env.NODE_ENV !== 'production') {\n var ReactPropTypesSecret = require('./lib/ReactPropTypesSecret');\n var loggedTypeFailures = {};\n var has = require('./lib/has');\n\n printWarning = function(text) {\n var message = 'Warning: ' + text;\n if (typeof console !== 'undefined') {\n console.error(message);\n }\n try {\n // --- Welcome to debugging React ---\n // This error was thrown as a convenience so that you can use this stack\n // to find the callsite that caused this warning to fire.\n throw new Error(message);\n } catch (x) { /**/ }\n };\n}\n\n/**\n * Assert that the values match with the type specs.\n * Error messages are memorized and will only be shown once.\n *\n * @param {object} typeSpecs Map of name to a ReactPropType\n * @param {object} values Runtime values that need to be type-checked\n * @param {string} location e.g. \"prop\", \"context\", \"child context\"\n * @param {string} componentName Name of the component for error messages.\n * @param {?Function} getStack Returns the component stack.\n * @private\n */\nfunction checkPropTypes(typeSpecs, values, location, componentName, getStack) {\n if (process.env.NODE_ENV !== 'production') {\n for (var typeSpecName in typeSpecs) {\n if (has(typeSpecs, typeSpecName)) {\n var error;\n // Prop type validation may throw. In case they do, we don't want to\n // fail the render phase where it didn't fail before. So we log it.\n // After these have been cleaned up, we'll let them throw.\n try {\n // This is intentionally an invariant that gets caught. It's the same\n // behavior as without this statement except with a better message.\n if (typeof typeSpecs[typeSpecName] !== 'function') {\n var err = Error(\n (componentName || 'React class') + ': ' + location + ' type `' + typeSpecName + '` is invalid; ' +\n 'it must be a function, usually from the `prop-types` package, but received `' + typeof typeSpecs[typeSpecName] + '`.' +\n 'This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.'\n );\n err.name = 'Invariant Violation';\n throw err;\n }\n error = typeSpecs[typeSpecName](values, typeSpecName, componentName, location, null, ReactPropTypesSecret);\n } catch (ex) {\n error = ex;\n }\n if (error && !(error instanceof Error)) {\n printWarning(\n (componentName || 'React class') + ': type specification of ' +\n location + ' `' + typeSpecName + '` is invalid; the type checker ' +\n 'function must return `null` or an `Error` but returned a ' + typeof error + '. ' +\n 'You may have forgotten to pass an argument to the type checker ' +\n 'creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and ' +\n 'shape all require an argument).'\n );\n }\n if (error instanceof Error && !(error.message in loggedTypeFailures)) {\n // Only monitor this failure once because there tends to be a lot of the\n // same error.\n loggedTypeFailures[error.message] = true;\n\n var stack = getStack ? getStack() : '';\n\n printWarning(\n 'Failed ' + location + ' type: ' + error.message + (stack != null ? stack : '')\n );\n }\n }\n }\n }\n}\n\n/**\n * Resets warning cache when testing.\n *\n * @private\n */\ncheckPropTypes.resetWarningCache = function() {\n if (process.env.NODE_ENV !== 'production') {\n loggedTypeFailures = {};\n }\n}\n\nmodule.exports = checkPropTypes;\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar ReactIs = require('react-is');\nvar assign = require('object-assign');\n\nvar ReactPropTypesSecret = require('./lib/ReactPropTypesSecret');\nvar has = require('./lib/has');\nvar checkPropTypes = require('./checkPropTypes');\n\nvar printWarning = function() {};\n\nif (process.env.NODE_ENV !== 'production') {\n printWarning = function(text) {\n var message = 'Warning: ' + text;\n if (typeof console !== 'undefined') {\n console.error(message);\n }\n try {\n // --- Welcome to debugging React ---\n // This error was thrown as a convenience so that you can use this stack\n // to find the callsite that caused this warning to fire.\n throw new Error(message);\n } catch (x) {}\n };\n}\n\nfunction emptyFunctionThatReturnsNull() {\n return null;\n}\n\nmodule.exports = function(isValidElement, throwOnDirectAccess) {\n /* global Symbol */\n var ITERATOR_SYMBOL = typeof Symbol === 'function' && Symbol.iterator;\n var FAUX_ITERATOR_SYMBOL = '@@iterator'; // Before Symbol spec.\n\n /**\n * Returns the iterator method function contained on the iterable object.\n *\n * Be sure to invoke the function with the iterable as context:\n *\n * var iteratorFn = getIteratorFn(myIterable);\n * if (iteratorFn) {\n * var iterator = iteratorFn.call(myIterable);\n * ...\n * }\n *\n * @param {?object} maybeIterable\n * @return {?function}\n */\n function getIteratorFn(maybeIterable) {\n var iteratorFn = maybeIterable && (ITERATOR_SYMBOL && maybeIterable[ITERATOR_SYMBOL] || maybeIterable[FAUX_ITERATOR_SYMBOL]);\n if (typeof iteratorFn === 'function') {\n return iteratorFn;\n }\n }\n\n /**\n * Collection of methods that allow declaration and validation of props that are\n * supplied to React components. Example usage:\n *\n * var Props = require('ReactPropTypes');\n * var MyArticle = React.createClass({\n * propTypes: {\n * // An optional string prop named \"description\".\n * description: Props.string,\n *\n * // A required enum prop named \"category\".\n * category: Props.oneOf(['News','Photos']).isRequired,\n *\n * // A prop named \"dialog\" that requires an instance of Dialog.\n * dialog: Props.instanceOf(Dialog).isRequired\n * },\n * render: function() { ... }\n * });\n *\n * A more formal specification of how these methods are used:\n *\n * type := array|bool|func|object|number|string|oneOf([...])|instanceOf(...)\n * decl := ReactPropTypes.{type}(.isRequired)?\n *\n * Each and every declaration produces a function with the same signature. This\n * allows the creation of custom validation functions. For example:\n *\n * var MyLink = React.createClass({\n * propTypes: {\n * // An optional string or URI prop named \"href\".\n * href: function(props, propName, componentName) {\n * var propValue = props[propName];\n * if (propValue != null && typeof propValue !== 'string' &&\n * !(propValue instanceof URI)) {\n * return new Error(\n * 'Expected a string or an URI for ' + propName + ' in ' +\n * componentName\n * );\n * }\n * }\n * },\n * render: function() {...}\n * });\n *\n * @internal\n */\n\n var ANONYMOUS = '<>';\n\n // Important!\n // Keep this list in sync with production version in `./factoryWithThrowingShims.js`.\n var ReactPropTypes = {\n array: createPrimitiveTypeChecker('array'),\n bigint: createPrimitiveTypeChecker('bigint'),\n bool: createPrimitiveTypeChecker('boolean'),\n func: createPrimitiveTypeChecker('function'),\n number: createPrimitiveTypeChecker('number'),\n object: createPrimitiveTypeChecker('object'),\n string: createPrimitiveTypeChecker('string'),\n symbol: createPrimitiveTypeChecker('symbol'),\n\n any: createAnyTypeChecker(),\n arrayOf: createArrayOfTypeChecker,\n element: createElementTypeChecker(),\n elementType: createElementTypeTypeChecker(),\n instanceOf: createInstanceTypeChecker,\n node: createNodeChecker(),\n objectOf: createObjectOfTypeChecker,\n oneOf: createEnumTypeChecker,\n oneOfType: createUnionTypeChecker,\n shape: createShapeTypeChecker,\n exact: createStrictShapeTypeChecker,\n };\n\n /**\n * inlined Object.is polyfill to avoid requiring consumers ship their own\n * https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object/is\n */\n /*eslint-disable no-self-compare*/\n function is(x, y) {\n // SameValue algorithm\n if (x === y) {\n // Steps 1-5, 7-10\n // Steps 6.b-6.e: +0 != -0\n return x !== 0 || 1 / x === 1 / y;\n } else {\n // Step 6.a: NaN == NaN\n return x !== x && y !== y;\n }\n }\n /*eslint-enable no-self-compare*/\n\n /**\n * We use an Error-like object for backward compatibility as people may call\n * PropTypes directly and inspect their output. However, we don't use real\n * Errors anymore. We don't inspect their stack anyway, and creating them\n * is prohibitively expensive if they are created too often, such as what\n * happens in oneOfType() for any type before the one that matched.\n */\n function PropTypeError(message, data) {\n this.message = message;\n this.data = data && typeof data === 'object' ? data: {};\n this.stack = '';\n }\n // Make `instanceof Error` still work for returned errors.\n PropTypeError.prototype = Error.prototype;\n\n function createChainableTypeChecker(validate) {\n if (process.env.NODE_ENV !== 'production') {\n var manualPropTypeCallCache = {};\n var manualPropTypeWarningCount = 0;\n }\n function checkType(isRequired, props, propName, componentName, location, propFullName, secret) {\n componentName = componentName || ANONYMOUS;\n propFullName = propFullName || propName;\n\n if (secret !== ReactPropTypesSecret) {\n if (throwOnDirectAccess) {\n // New behavior only for users of `prop-types` package\n var err = new Error(\n 'Calling PropTypes validators directly is not supported by the `prop-types` package. ' +\n 'Use `PropTypes.checkPropTypes()` to call them. ' +\n 'Read more at http://fb.me/use-check-prop-types'\n );\n err.name = 'Invariant Violation';\n throw err;\n } else if (process.env.NODE_ENV !== 'production' && typeof console !== 'undefined') {\n // Old behavior for people using React.PropTypes\n var cacheKey = componentName + ':' + propName;\n if (\n !manualPropTypeCallCache[cacheKey] &&\n // Avoid spamming the console because they are often not actionable except for lib authors\n manualPropTypeWarningCount < 3\n ) {\n printWarning(\n 'You are manually calling a React.PropTypes validation ' +\n 'function for the `' + propFullName + '` prop on `' + componentName + '`. This is deprecated ' +\n 'and will throw in the standalone `prop-types` package. ' +\n 'You may be seeing this warning due to a third-party PropTypes ' +\n 'library. See https://fb.me/react-warning-dont-call-proptypes ' + 'for details.'\n );\n manualPropTypeCallCache[cacheKey] = true;\n manualPropTypeWarningCount++;\n }\n }\n }\n if (props[propName] == null) {\n if (isRequired) {\n if (props[propName] === null) {\n return new PropTypeError('The ' + location + ' `' + propFullName + '` is marked as required ' + ('in `' + componentName + '`, but its value is `null`.'));\n }\n return new PropTypeError('The ' + location + ' `' + propFullName + '` is marked as required in ' + ('`' + componentName + '`, but its value is `undefined`.'));\n }\n return null;\n } else {\n return validate(props, propName, componentName, location, propFullName);\n }\n }\n\n var chainedCheckType = checkType.bind(null, false);\n chainedCheckType.isRequired = checkType.bind(null, true);\n\n return chainedCheckType;\n }\n\n function createPrimitiveTypeChecker(expectedType) {\n function validate(props, propName, componentName, location, propFullName, secret) {\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== expectedType) {\n // `propValue` being instance of, say, date/regexp, pass the 'object'\n // check, but we can offer a more precise error message here rather than\n // 'of type `object`'.\n var preciseType = getPreciseType(propValue);\n\n return new PropTypeError(\n 'Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + preciseType + '` supplied to `' + componentName + '`, expected ') + ('`' + expectedType + '`.'),\n {expectedType: expectedType}\n );\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createAnyTypeChecker() {\n return createChainableTypeChecker(emptyFunctionThatReturnsNull);\n }\n\n function createArrayOfTypeChecker(typeChecker) {\n function validate(props, propName, componentName, location, propFullName) {\n if (typeof typeChecker !== 'function') {\n return new PropTypeError('Property `' + propFullName + '` of component `' + componentName + '` has invalid PropType notation inside arrayOf.');\n }\n var propValue = props[propName];\n if (!Array.isArray(propValue)) {\n var propType = getPropType(propValue);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected an array.'));\n }\n for (var i = 0; i < propValue.length; i++) {\n var error = typeChecker(propValue, i, componentName, location, propFullName + '[' + i + ']', ReactPropTypesSecret);\n if (error instanceof Error) {\n return error;\n }\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createElementTypeChecker() {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n if (!isValidElement(propValue)) {\n var propType = getPropType(propValue);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected a single ReactElement.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createElementTypeTypeChecker() {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n if (!ReactIs.isValidElementType(propValue)) {\n var propType = getPropType(propValue);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected a single ReactElement type.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createInstanceTypeChecker(expectedClass) {\n function validate(props, propName, componentName, location, propFullName) {\n if (!(props[propName] instanceof expectedClass)) {\n var expectedClassName = expectedClass.name || ANONYMOUS;\n var actualClassName = getClassName(props[propName]);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + actualClassName + '` supplied to `' + componentName + '`, expected ') + ('instance of `' + expectedClassName + '`.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createEnumTypeChecker(expectedValues) {\n if (!Array.isArray(expectedValues)) {\n if (process.env.NODE_ENV !== 'production') {\n if (arguments.length > 1) {\n printWarning(\n 'Invalid arguments supplied to oneOf, expected an array, got ' + arguments.length + ' arguments. ' +\n 'A common mistake is to write oneOf(x, y, z) instead of oneOf([x, y, z]).'\n );\n } else {\n printWarning('Invalid argument supplied to oneOf, expected an array.');\n }\n }\n return emptyFunctionThatReturnsNull;\n }\n\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n for (var i = 0; i < expectedValues.length; i++) {\n if (is(propValue, expectedValues[i])) {\n return null;\n }\n }\n\n var valuesString = JSON.stringify(expectedValues, function replacer(key, value) {\n var type = getPreciseType(value);\n if (type === 'symbol') {\n return String(value);\n }\n return value;\n });\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of value `' + String(propValue) + '` ' + ('supplied to `' + componentName + '`, expected one of ' + valuesString + '.'));\n }\n return createChainableTypeChecker(validate);\n }\n\n function createObjectOfTypeChecker(typeChecker) {\n function validate(props, propName, componentName, location, propFullName) {\n if (typeof typeChecker !== 'function') {\n return new PropTypeError('Property `' + propFullName + '` of component `' + componentName + '` has invalid PropType notation inside objectOf.');\n }\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== 'object') {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected an object.'));\n }\n for (var key in propValue) {\n if (has(propValue, key)) {\n var error = typeChecker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret);\n if (error instanceof Error) {\n return error;\n }\n }\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createUnionTypeChecker(arrayOfTypeCheckers) {\n if (!Array.isArray(arrayOfTypeCheckers)) {\n process.env.NODE_ENV !== 'production' ? printWarning('Invalid argument supplied to oneOfType, expected an instance of array.') : void 0;\n return emptyFunctionThatReturnsNull;\n }\n\n for (var i = 0; i < arrayOfTypeCheckers.length; i++) {\n var checker = arrayOfTypeCheckers[i];\n if (typeof checker !== 'function') {\n printWarning(\n 'Invalid argument supplied to oneOfType. Expected an array of check functions, but ' +\n 'received ' + getPostfixForTypeWarning(checker) + ' at index ' + i + '.'\n );\n return emptyFunctionThatReturnsNull;\n }\n }\n\n function validate(props, propName, componentName, location, propFullName) {\n var expectedTypes = [];\n for (var i = 0; i < arrayOfTypeCheckers.length; i++) {\n var checker = arrayOfTypeCheckers[i];\n var checkerResult = checker(props, propName, componentName, location, propFullName, ReactPropTypesSecret);\n if (checkerResult == null) {\n return null;\n }\n if (checkerResult.data && has(checkerResult.data, 'expectedType')) {\n expectedTypes.push(checkerResult.data.expectedType);\n }\n }\n var expectedTypesMessage = (expectedTypes.length > 0) ? ', expected one of type [' + expectedTypes.join(', ') + ']': '';\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` supplied to ' + ('`' + componentName + '`' + expectedTypesMessage + '.'));\n }\n return createChainableTypeChecker(validate);\n }\n\n function createNodeChecker() {\n function validate(props, propName, componentName, location, propFullName) {\n if (!isNode(props[propName])) {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` supplied to ' + ('`' + componentName + '`, expected a ReactNode.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function invalidValidatorError(componentName, location, propFullName, key, type) {\n return new PropTypeError(\n (componentName || 'React class') + ': ' + location + ' type `' + propFullName + '.' + key + '` is invalid; ' +\n 'it must be a function, usually from the `prop-types` package, but received `' + type + '`.'\n );\n }\n\n function createShapeTypeChecker(shapeTypes) {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== 'object') {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type `' + propType + '` ' + ('supplied to `' + componentName + '`, expected `object`.'));\n }\n for (var key in shapeTypes) {\n var checker = shapeTypes[key];\n if (typeof checker !== 'function') {\n return invalidValidatorError(componentName, location, propFullName, key, getPreciseType(checker));\n }\n var error = checker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret);\n if (error) {\n return error;\n }\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createStrictShapeTypeChecker(shapeTypes) {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== 'object') {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type `' + propType + '` ' + ('supplied to `' + componentName + '`, expected `object`.'));\n }\n // We need to check all keys in case some are required but missing from props.\n var allKeys = assign({}, props[propName], shapeTypes);\n for (var key in allKeys) {\n var checker = shapeTypes[key];\n if (has(shapeTypes, key) && typeof checker !== 'function') {\n return invalidValidatorError(componentName, location, propFullName, key, getPreciseType(checker));\n }\n if (!checker) {\n return new PropTypeError(\n 'Invalid ' + location + ' `' + propFullName + '` key `' + key + '` supplied to `' + componentName + '`.' +\n '\\nBad object: ' + JSON.stringify(props[propName], null, ' ') +\n '\\nValid keys: ' + JSON.stringify(Object.keys(shapeTypes), null, ' ')\n );\n }\n var error = checker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret);\n if (error) {\n return error;\n }\n }\n return null;\n }\n\n return createChainableTypeChecker(validate);\n }\n\n function isNode(propValue) {\n switch (typeof propValue) {\n case 'number':\n case 'string':\n case 'undefined':\n return true;\n case 'boolean':\n return !propValue;\n case 'object':\n if (Array.isArray(propValue)) {\n return propValue.every(isNode);\n }\n if (propValue === null || isValidElement(propValue)) {\n return true;\n }\n\n var iteratorFn = getIteratorFn(propValue);\n if (iteratorFn) {\n var iterator = iteratorFn.call(propValue);\n var step;\n if (iteratorFn !== propValue.entries) {\n while (!(step = iterator.next()).done) {\n if (!isNode(step.value)) {\n return false;\n }\n }\n } else {\n // Iterator will provide entry [k,v] tuples rather than values.\n while (!(step = iterator.next()).done) {\n var entry = step.value;\n if (entry) {\n if (!isNode(entry[1])) {\n return false;\n }\n }\n }\n }\n } else {\n return false;\n }\n\n return true;\n default:\n return false;\n }\n }\n\n function isSymbol(propType, propValue) {\n // Native Symbol.\n if (propType === 'symbol') {\n return true;\n }\n\n // falsy value can't be a Symbol\n if (!propValue) {\n return false;\n }\n\n // 19.4.3.5 Symbol.prototype[@@toStringTag] === 'Symbol'\n if (propValue['@@toStringTag'] === 'Symbol') {\n return true;\n }\n\n // Fallback for non-spec compliant Symbols which are polyfilled.\n if (typeof Symbol === 'function' && propValue instanceof Symbol) {\n return true;\n }\n\n return false;\n }\n\n // Equivalent of `typeof` but with special handling for array and regexp.\n function getPropType(propValue) {\n var propType = typeof propValue;\n if (Array.isArray(propValue)) {\n return 'array';\n }\n if (propValue instanceof RegExp) {\n // Old webkits (at least until Android 4.0) return 'function' rather than\n // 'object' for typeof a RegExp. We'll normalize this here so that /bla/\n // passes PropTypes.object.\n return 'object';\n }\n if (isSymbol(propType, propValue)) {\n return 'symbol';\n }\n return propType;\n }\n\n // This handles more types than `getPropType`. Only used for error messages.\n // See `createPrimitiveTypeChecker`.\n function getPreciseType(propValue) {\n if (typeof propValue === 'undefined' || propValue === null) {\n return '' + propValue;\n }\n var propType = getPropType(propValue);\n if (propType === 'object') {\n if (propValue instanceof Date) {\n return 'date';\n } else if (propValue instanceof RegExp) {\n return 'regexp';\n }\n }\n return propType;\n }\n\n // Returns a string that is postfixed to a warning about an invalid type.\n // For example, \"undefined\" or \"of type array\"\n function getPostfixForTypeWarning(value) {\n var type = getPreciseType(value);\n switch (type) {\n case 'array':\n case 'object':\n return 'an ' + type;\n case 'boolean':\n case 'date':\n case 'regexp':\n return 'a ' + type;\n default:\n return type;\n }\n }\n\n // Returns class name of the object, if any.\n function getClassName(propValue) {\n if (!propValue.constructor || !propValue.constructor.name) {\n return ANONYMOUS;\n }\n return propValue.constructor.name;\n }\n\n ReactPropTypes.checkPropTypes = checkPropTypes;\n ReactPropTypes.resetWarningCache = checkPropTypes.resetWarningCache;\n ReactPropTypes.PropTypes = ReactPropTypes;\n\n return ReactPropTypes;\n};\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar ReactPropTypesSecret = require('./lib/ReactPropTypesSecret');\n\nfunction emptyFunction() {}\nfunction emptyFunctionWithReset() {}\nemptyFunctionWithReset.resetWarningCache = emptyFunction;\n\nmodule.exports = function() {\n function shim(props, propName, componentName, location, propFullName, secret) {\n if (secret === ReactPropTypesSecret) {\n // It is still safe when called from React.\n return;\n }\n var err = new Error(\n 'Calling PropTypes validators directly is not supported by the `prop-types` package. ' +\n 'Use PropTypes.checkPropTypes() to call them. ' +\n 'Read more at http://fb.me/use-check-prop-types'\n );\n err.name = 'Invariant Violation';\n throw err;\n };\n shim.isRequired = shim;\n function getShim() {\n return shim;\n };\n // Important!\n // Keep this list in sync with production version in `./factoryWithTypeCheckers.js`.\n var ReactPropTypes = {\n array: shim,\n bigint: shim,\n bool: shim,\n func: shim,\n number: shim,\n object: shim,\n string: shim,\n symbol: shim,\n\n any: shim,\n arrayOf: getShim,\n element: shim,\n elementType: shim,\n instanceOf: getShim,\n node: shim,\n objectOf: getShim,\n oneOf: getShim,\n oneOfType: getShim,\n shape: getShim,\n exact: getShim,\n\n checkPropTypes: emptyFunctionWithReset,\n resetWarningCache: emptyFunction\n };\n\n ReactPropTypes.PropTypes = ReactPropTypes;\n\n return ReactPropTypes;\n};\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\nif (process.env.NODE_ENV !== 'production') {\n var ReactIs = require('react-is');\n\n // By explicitly using `prop-types` you are opting into new development behavior.\n // http://fb.me/prop-types-in-prod\n var throwOnDirectAccess = true;\n module.exports = require('./factoryWithTypeCheckers')(ReactIs.isElement, throwOnDirectAccess);\n} else {\n // By explicitly using `prop-types` you are opting into new production behavior.\n // http://fb.me/prop-types-in-prod\n module.exports = require('./factoryWithThrowingShims')();\n}\n","import PropTypes from 'prop-types';\nimport chainPropTypes from '../chainPropTypes';\nfunction isClassComponent(elementType) {\n // elementType.prototype?.isReactComponent\n const {\n prototype = {}\n } = elementType;\n return Boolean(prototype.isReactComponent);\n}\nfunction acceptingRef(props, propName, componentName, location, propFullName) {\n const element = props[propName];\n const safePropName = propFullName || propName;\n if (element == null ||\n // When server-side rendering React doesn't warn either.\n // This is not an accurate check for SSR.\n // This is only in place for Emotion compat.\n // TODO: Revisit once https://github.com/facebook/react/issues/20047 is resolved.\n typeof window === 'undefined') {\n return null;\n }\n let warningHint;\n const elementType = element.type;\n /**\n * Blacklisting instead of whitelisting\n *\n * Blacklisting will miss some components, such as React.Fragment. Those will at least\n * trigger a warning in React.\n * We can't whitelist because there is no safe way to detect React.forwardRef\n * or class components. \"Safe\" means there's no public API.\n *\n */\n if (typeof elementType === 'function' && !isClassComponent(elementType)) {\n warningHint = 'Did you accidentally use a plain function component for an element instead?';\n }\n if (warningHint !== undefined) {\n return new Error(`Invalid ${location} \\`${safePropName}\\` supplied to \\`${componentName}\\`. ` + `Expected an element that can hold a ref. ${warningHint} ` + 'For more information see https://mui.com/r/caveat-with-refs-guide');\n }\n return null;\n}\nconst elementAcceptingRef = chainPropTypes(PropTypes.element, acceptingRef);\nelementAcceptingRef.isRequired = chainPropTypes(PropTypes.element.isRequired, acceptingRef);\nexport default elementAcceptingRef;","import _extends from \"@babel/runtime/helpers/esm/extends\";\n// This module is based on https://github.com/airbnb/prop-types-exact repository.\n// However, in order to reduce the number of dependencies and to remove some extra safe checks\n// the module was forked.\n\nconst specialProperty = 'exact-prop: \\u200b';\nexport default function exactProp(propTypes) {\n if (process.env.NODE_ENV === 'production') {\n return propTypes;\n }\n return _extends({}, propTypes, {\n [specialProperty]: props => {\n const unsupportedProps = Object.keys(props).filter(prop => !propTypes.hasOwnProperty(prop));\n if (unsupportedProps.length > 0) {\n return new Error(`The following props are not supported: ${unsupportedProps.map(prop => `\\`${prop}\\``).join(', ')}. Please remove them.`);\n }\n return null;\n }\n });\n}","/**\n * WARNING: Don't import this directly.\n * Use `MuiError` from `@mui/internal-babel-macros/MuiError.macro` instead.\n * @param {number} code\n */\nexport default function formatMuiErrorMessage(code) {\n // Apply babel-plugin-transform-template-literals in loose mode\n // loose mode is safe if we're concatenating primitives\n // see https://babeljs.io/docs/en/babel-plugin-transform-template-literals#loose\n /* eslint-disable prefer-template */\n let url = 'https://mui.com/production-error/?code=' + code;\n for (let i = 1; i < arguments.length; i += 1) {\n // rest params over-transpile for this case\n // eslint-disable-next-line prefer-rest-params\n url += '&args[]=' + encodeURIComponent(arguments[i]);\n }\n return 'Minified MUI error #' + code + '; visit ' + url + ' for the full message.';\n /* eslint-enable prefer-template */\n}","/**\n * @license React\n * react-is.production.min.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n'use strict';var b=Symbol.for(\"react.element\"),c=Symbol.for(\"react.portal\"),d=Symbol.for(\"react.fragment\"),e=Symbol.for(\"react.strict_mode\"),f=Symbol.for(\"react.profiler\"),g=Symbol.for(\"react.provider\"),h=Symbol.for(\"react.context\"),k=Symbol.for(\"react.server_context\"),l=Symbol.for(\"react.forward_ref\"),m=Symbol.for(\"react.suspense\"),n=Symbol.for(\"react.suspense_list\"),p=Symbol.for(\"react.memo\"),q=Symbol.for(\"react.lazy\"),t=Symbol.for(\"react.offscreen\"),u;u=Symbol.for(\"react.module.reference\");\nfunction v(a){if(\"object\"===typeof a&&null!==a){var r=a.$$typeof;switch(r){case b:switch(a=a.type,a){case d:case f:case e:case m:case n:return a;default:switch(a=a&&a.$$typeof,a){case k:case h:case l:case q:case p:case g:return a;default:return r}}case c:return r}}}exports.ContextConsumer=h;exports.ContextProvider=g;exports.Element=b;exports.ForwardRef=l;exports.Fragment=d;exports.Lazy=q;exports.Memo=p;exports.Portal=c;exports.Profiler=f;exports.StrictMode=e;exports.Suspense=m;\nexports.SuspenseList=n;exports.isAsyncMode=function(){return!1};exports.isConcurrentMode=function(){return!1};exports.isContextConsumer=function(a){return v(a)===h};exports.isContextProvider=function(a){return v(a)===g};exports.isElement=function(a){return\"object\"===typeof a&&null!==a&&a.$$typeof===b};exports.isForwardRef=function(a){return v(a)===l};exports.isFragment=function(a){return v(a)===d};exports.isLazy=function(a){return v(a)===q};exports.isMemo=function(a){return v(a)===p};\nexports.isPortal=function(a){return v(a)===c};exports.isProfiler=function(a){return v(a)===f};exports.isStrictMode=function(a){return v(a)===e};exports.isSuspense=function(a){return v(a)===m};exports.isSuspenseList=function(a){return v(a)===n};\nexports.isValidElementType=function(a){return\"string\"===typeof a||\"function\"===typeof a||a===d||a===f||a===e||a===m||a===n||a===t||\"object\"===typeof a&&null!==a&&(a.$$typeof===q||a.$$typeof===p||a.$$typeof===g||a.$$typeof===h||a.$$typeof===l||a.$$typeof===u||void 0!==a.getModuleId)?!0:!1};exports.typeOf=v;\n","/**\n * @license React\n * react-is.development.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nif (process.env.NODE_ENV !== \"production\") {\n (function() {\n'use strict';\n\n// ATTENTION\n// When adding new symbols to this file,\n// Please consider also adding to 'react-devtools-shared/src/backend/ReactSymbols'\n// The Symbol used to tag the ReactElement-like types.\nvar REACT_ELEMENT_TYPE = Symbol.for('react.element');\nvar REACT_PORTAL_TYPE = Symbol.for('react.portal');\nvar REACT_FRAGMENT_TYPE = Symbol.for('react.fragment');\nvar REACT_STRICT_MODE_TYPE = Symbol.for('react.strict_mode');\nvar REACT_PROFILER_TYPE = Symbol.for('react.profiler');\nvar REACT_PROVIDER_TYPE = Symbol.for('react.provider');\nvar REACT_CONTEXT_TYPE = Symbol.for('react.context');\nvar REACT_SERVER_CONTEXT_TYPE = Symbol.for('react.server_context');\nvar REACT_FORWARD_REF_TYPE = Symbol.for('react.forward_ref');\nvar REACT_SUSPENSE_TYPE = Symbol.for('react.suspense');\nvar REACT_SUSPENSE_LIST_TYPE = Symbol.for('react.suspense_list');\nvar REACT_MEMO_TYPE = Symbol.for('react.memo');\nvar REACT_LAZY_TYPE = Symbol.for('react.lazy');\nvar REACT_OFFSCREEN_TYPE = Symbol.for('react.offscreen');\n\n// -----------------------------------------------------------------------------\n\nvar enableScopeAPI = false; // Experimental Create Event Handle API.\nvar enableCacheElement = false;\nvar enableTransitionTracing = false; // No known bugs, but needs performance testing\n\nvar enableLegacyHidden = false; // Enables unstable_avoidThisFallback feature in Fiber\n// stuff. Intended to enable React core members to more easily debug scheduling\n// issues in DEV builds.\n\nvar enableDebugTracing = false; // Track which Fiber(s) schedule render work.\n\nvar REACT_MODULE_REFERENCE;\n\n{\n REACT_MODULE_REFERENCE = Symbol.for('react.module.reference');\n}\n\nfunction isValidElementType(type) {\n if (typeof type === 'string' || typeof type === 'function') {\n return true;\n } // Note: typeof might be other than 'symbol' or 'number' (e.g. if it's a polyfill).\n\n\n if (type === REACT_FRAGMENT_TYPE || type === REACT_PROFILER_TYPE || enableDebugTracing || type === REACT_STRICT_MODE_TYPE || type === REACT_SUSPENSE_TYPE || type === REACT_SUSPENSE_LIST_TYPE || enableLegacyHidden || type === REACT_OFFSCREEN_TYPE || enableScopeAPI || enableCacheElement || enableTransitionTracing ) {\n return true;\n }\n\n if (typeof type === 'object' && type !== null) {\n if (type.$$typeof === REACT_LAZY_TYPE || type.$$typeof === REACT_MEMO_TYPE || type.$$typeof === REACT_PROVIDER_TYPE || type.$$typeof === REACT_CONTEXT_TYPE || type.$$typeof === REACT_FORWARD_REF_TYPE || // This needs to include all possible module reference object\n // types supported by any Flight configuration anywhere since\n // we don't know which Flight build this will end up being used\n // with.\n type.$$typeof === REACT_MODULE_REFERENCE || type.getModuleId !== undefined) {\n return true;\n }\n }\n\n return false;\n}\n\nfunction typeOf(object) {\n if (typeof object === 'object' && object !== null) {\n var $$typeof = object.$$typeof;\n\n switch ($$typeof) {\n case REACT_ELEMENT_TYPE:\n var type = object.type;\n\n switch (type) {\n case REACT_FRAGMENT_TYPE:\n case REACT_PROFILER_TYPE:\n case REACT_STRICT_MODE_TYPE:\n case REACT_SUSPENSE_TYPE:\n case REACT_SUSPENSE_LIST_TYPE:\n return type;\n\n default:\n var $$typeofType = type && type.$$typeof;\n\n switch ($$typeofType) {\n case REACT_SERVER_CONTEXT_TYPE:\n case REACT_CONTEXT_TYPE:\n case REACT_FORWARD_REF_TYPE:\n case REACT_LAZY_TYPE:\n case REACT_MEMO_TYPE:\n case REACT_PROVIDER_TYPE:\n return $$typeofType;\n\n default:\n return $$typeof;\n }\n\n }\n\n case REACT_PORTAL_TYPE:\n return $$typeof;\n }\n }\n\n return undefined;\n}\nvar ContextConsumer = REACT_CONTEXT_TYPE;\nvar ContextProvider = REACT_PROVIDER_TYPE;\nvar Element = REACT_ELEMENT_TYPE;\nvar ForwardRef = REACT_FORWARD_REF_TYPE;\nvar Fragment = REACT_FRAGMENT_TYPE;\nvar Lazy = REACT_LAZY_TYPE;\nvar Memo = REACT_MEMO_TYPE;\nvar Portal = REACT_PORTAL_TYPE;\nvar Profiler = REACT_PROFILER_TYPE;\nvar StrictMode = REACT_STRICT_MODE_TYPE;\nvar Suspense = REACT_SUSPENSE_TYPE;\nvar SuspenseList = REACT_SUSPENSE_LIST_TYPE;\nvar hasWarnedAboutDeprecatedIsAsyncMode = false;\nvar hasWarnedAboutDeprecatedIsConcurrentMode = false; // AsyncMode should be deprecated\n\nfunction isAsyncMode(object) {\n {\n if (!hasWarnedAboutDeprecatedIsAsyncMode) {\n hasWarnedAboutDeprecatedIsAsyncMode = true; // Using console['warn'] to evade Babel and ESLint\n\n console['warn']('The ReactIs.isAsyncMode() alias has been deprecated, ' + 'and will be removed in React 18+.');\n }\n }\n\n return false;\n}\nfunction isConcurrentMode(object) {\n {\n if (!hasWarnedAboutDeprecatedIsConcurrentMode) {\n hasWarnedAboutDeprecatedIsConcurrentMode = true; // Using console['warn'] to evade Babel and ESLint\n\n console['warn']('The ReactIs.isConcurrentMode() alias has been deprecated, ' + 'and will be removed in React 18+.');\n }\n }\n\n return false;\n}\nfunction isContextConsumer(object) {\n return typeOf(object) === REACT_CONTEXT_TYPE;\n}\nfunction isContextProvider(object) {\n return typeOf(object) === REACT_PROVIDER_TYPE;\n}\nfunction isElement(object) {\n return typeof object === 'object' && object !== null && object.$$typeof === REACT_ELEMENT_TYPE;\n}\nfunction isForwardRef(object) {\n return typeOf(object) === REACT_FORWARD_REF_TYPE;\n}\nfunction isFragment(object) {\n return typeOf(object) === REACT_FRAGMENT_TYPE;\n}\nfunction isLazy(object) {\n return typeOf(object) === REACT_LAZY_TYPE;\n}\nfunction isMemo(object) {\n return typeOf(object) === REACT_MEMO_TYPE;\n}\nfunction isPortal(object) {\n return typeOf(object) === REACT_PORTAL_TYPE;\n}\nfunction isProfiler(object) {\n return typeOf(object) === REACT_PROFILER_TYPE;\n}\nfunction isStrictMode(object) {\n return typeOf(object) === REACT_STRICT_MODE_TYPE;\n}\nfunction isSuspense(object) {\n return typeOf(object) === REACT_SUSPENSE_TYPE;\n}\nfunction isSuspenseList(object) {\n return typeOf(object) === REACT_SUSPENSE_LIST_TYPE;\n}\n\nexports.ContextConsumer = ContextConsumer;\nexports.ContextProvider = ContextProvider;\nexports.Element = Element;\nexports.ForwardRef = ForwardRef;\nexports.Fragment = Fragment;\nexports.Lazy = Lazy;\nexports.Memo = Memo;\nexports.Portal = Portal;\nexports.Profiler = Profiler;\nexports.StrictMode = StrictMode;\nexports.Suspense = Suspense;\nexports.SuspenseList = SuspenseList;\nexports.isAsyncMode = isAsyncMode;\nexports.isConcurrentMode = isConcurrentMode;\nexports.isContextConsumer = isContextConsumer;\nexports.isContextProvider = isContextProvider;\nexports.isElement = isElement;\nexports.isForwardRef = isForwardRef;\nexports.isFragment = isFragment;\nexports.isLazy = isLazy;\nexports.isMemo = isMemo;\nexports.isPortal = isPortal;\nexports.isProfiler = isProfiler;\nexports.isStrictMode = isStrictMode;\nexports.isSuspense = isSuspense;\nexports.isSuspenseList = isSuspenseList;\nexports.isValidElementType = isValidElementType;\nexports.typeOf = typeOf;\n })();\n}\n","'use strict';\n\nif (process.env.NODE_ENV === 'production') {\n module.exports = require('./cjs/react-is.production.min.js');\n} else {\n module.exports = require('./cjs/react-is.development.js');\n}\n","import { ForwardRef, Memo } from 'react-is';\n\n// Simplified polyfill for IE11 support\n// https://github.com/JamesMGreene/Function.name/blob/58b314d4a983110c3682f1228f845d39ccca1817/Function.name.js#L3\nconst fnNameMatchRegex = /^\\s*function(?:\\s|\\s*\\/\\*.*\\*\\/\\s*)+([^(\\s/]*)\\s*/;\nexport function getFunctionName(fn) {\n const match = `${fn}`.match(fnNameMatchRegex);\n const name = match && match[1];\n return name || '';\n}\nfunction getFunctionComponentName(Component, fallback = '') {\n return Component.displayName || Component.name || getFunctionName(Component) || fallback;\n}\nfunction getWrappedName(outerType, innerType, wrapperName) {\n const functionName = getFunctionComponentName(innerType);\n return outerType.displayName || (functionName !== '' ? `${wrapperName}(${functionName})` : wrapperName);\n}\n\n/**\n * cherry-pick from\n * https://github.com/facebook/react/blob/769b1f270e1251d9dbdce0fcbd9e92e502d059b8/packages/shared/getComponentName.js\n * originally forked from recompose/getDisplayName with added IE11 support\n */\nexport default function getDisplayName(Component) {\n if (Component == null) {\n return undefined;\n }\n if (typeof Component === 'string') {\n return Component;\n }\n if (typeof Component === 'function') {\n return getFunctionComponentName(Component, 'Component');\n }\n\n // TypeScript can't have components as objects but they exist in the form of `memo` or `Suspense`\n if (typeof Component === 'object') {\n switch (Component.$$typeof) {\n case ForwardRef:\n return getWrappedName(Component, Component.render, 'ForwardRef');\n case Memo:\n return getWrappedName(Component, Component.type, 'memo');\n default:\n return undefined;\n }\n }\n return undefined;\n}","export default function HTMLElementType(props, propName, componentName, location, propFullName) {\n if (process.env.NODE_ENV === 'production') {\n return null;\n }\n const propValue = props[propName];\n const safePropName = propFullName || propName;\n if (propValue == null) {\n return null;\n }\n if (propValue && propValue.nodeType !== 1) {\n return new Error(`Invalid ${location} \\`${safePropName}\\` supplied to \\`${componentName}\\`. ` + `Expected an HTMLElement.`);\n }\n return null;\n}","import PropTypes from 'prop-types';\nconst refType = PropTypes.oneOfType([PropTypes.func, PropTypes.object]);\nexport default refType;","import _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\n// It should to be noted that this function isn't equivalent to `text-transform: capitalize`.\n//\n// A strict capitalization should uppercase the first letter of each word in the sentence.\n// We only handle the first word.\nexport default function capitalize(string) {\n if (typeof string !== 'string') {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: \\`capitalize(string)\\` expects a string argument.` : _formatMuiErrorMessage(7));\n }\n return string.charAt(0).toUpperCase() + string.slice(1);\n}","/**\n * Safe chained function.\n *\n * Will only create a new function if needed,\n * otherwise will pass back existing functions or null.\n */\nexport default function createChainedFunction(...funcs) {\n return funcs.reduce((acc, func) => {\n if (func == null) {\n return acc;\n }\n return function chainedFunction(...args) {\n acc.apply(this, args);\n func.apply(this, args);\n };\n }, () => {});\n}","// Corresponds to 10 frames at 60 Hz.\n// A few bytes payload overhead when lodash/debounce is ~3 kB and debounce ~300 B.\nexport default function debounce(func, wait = 166) {\n let timeout;\n function debounced(...args) {\n const later = () => {\n // @ts-ignore\n func.apply(this, args);\n };\n clearTimeout(timeout);\n timeout = setTimeout(later, wait);\n }\n debounced.clear = () => {\n clearTimeout(timeout);\n };\n return debounced;\n}","export default function deprecatedPropType(validator, reason) {\n if (process.env.NODE_ENV === 'production') {\n return () => null;\n }\n return (props, propName, componentName, location, propFullName) => {\n const componentNameSafe = componentName || '<>';\n const propFullNameSafe = propFullName || propName;\n if (typeof props[propName] !== 'undefined') {\n return new Error(`The ${location} \\`${propFullNameSafe}\\` of ` + `\\`${componentNameSafe}\\` is deprecated. ${reason}`);\n }\n return null;\n };\n}","import * as React from 'react';\nexport default function isMuiElement(element, muiNames) {\n var _muiName, _element$type;\n return /*#__PURE__*/React.isValidElement(element) && muiNames.indexOf( // For server components `muiName` is avaialble in element.type._payload.value.muiName\n // relevant info - https://github.com/facebook/react/blob/2807d781a08db8e9873687fccc25c0f12b4fb3d4/packages/react/src/ReactLazy.js#L45\n // eslint-disable-next-line no-underscore-dangle\n (_muiName = element.type.muiName) != null ? _muiName : (_element$type = element.type) == null || (_element$type = _element$type._payload) == null || (_element$type = _element$type.value) == null ? void 0 : _element$type.muiName) !== -1;\n}","export default function ownerDocument(node) {\n return node && node.ownerDocument || document;\n}","import ownerDocument from '../ownerDocument';\nexport default function ownerWindow(node) {\n const doc = ownerDocument(node);\n return doc.defaultView || window;\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nexport default function requirePropFactory(componentNameInError, Component) {\n if (process.env.NODE_ENV === 'production') {\n return () => null;\n }\n\n // eslint-disable-next-line react/forbid-foreign-prop-types\n const prevPropTypes = Component ? _extends({}, Component.propTypes) : null;\n const requireProp = requiredProp => (props, propName, componentName, location, propFullName, ...args) => {\n const propFullNameSafe = propFullName || propName;\n const defaultTypeChecker = prevPropTypes == null ? void 0 : prevPropTypes[propFullNameSafe];\n if (defaultTypeChecker) {\n const typeCheckerResult = defaultTypeChecker(props, propName, componentName, location, propFullName, ...args);\n if (typeCheckerResult) {\n return typeCheckerResult;\n }\n }\n if (typeof props[propName] !== 'undefined' && !props[requiredProp]) {\n return new Error(`The prop \\`${propFullNameSafe}\\` of ` + `\\`${componentNameInError}\\` can only be used together with the \\`${requiredProp}\\` prop.`);\n }\n return null;\n };\n return requireProp;\n}","/**\n * TODO v5: consider making it private\n *\n * passes {value} to {ref}\n *\n * WARNING: Be sure to only call this inside a callback that is passed as a ref.\n * Otherwise, make sure to cleanup the previous {ref} if it changes. See\n * https://github.com/mui/material-ui/issues/13539\n *\n * Useful if you want to expose the ref of an inner component to the public API\n * while still using it inside the component.\n * @param ref A ref callback or ref object. If anything falsy, this is a no-op.\n */\nexport default function setRef(ref, value) {\n if (typeof ref === 'function') {\n ref(value);\n } else if (ref) {\n ref.current = value;\n }\n}","'use client';\n\nimport * as React from 'react';\n\n/**\n * A version of `React.useLayoutEffect` that does not show a warning when server-side rendering.\n * This is useful for effects that are only needed for client-side rendering but not for SSR.\n *\n * Before you use this hook, make sure to read https://gist.github.com/gaearon/e7d97cdf38a2907924ea12e4ebdf3c85\n * and confirm it doesn't apply to your use-case.\n */\nconst useEnhancedEffect = typeof window !== 'undefined' ? React.useLayoutEffect : React.useEffect;\nexport default useEnhancedEffect;","'use client';\n\nimport * as React from 'react';\nlet globalId = 0;\nfunction useGlobalId(idOverride) {\n const [defaultId, setDefaultId] = React.useState(idOverride);\n const id = idOverride || defaultId;\n React.useEffect(() => {\n if (defaultId == null) {\n // Fallback to this default id when possible.\n // Use the incrementing value for client-side rendering only.\n // We can't use it server-side.\n // If you want to use random values please consider the Birthday Problem: https://en.wikipedia.org/wiki/Birthday_problem\n globalId += 1;\n setDefaultId(`mui-${globalId}`);\n }\n }, [defaultId]);\n return id;\n}\n\n// downstream bundlers may remove unnecessary concatenation, but won't remove toString call -- Workaround for https://github.com/webpack/webpack/issues/14814\nconst maybeReactUseId = React['useId'.toString()];\n/**\n *\n * @example
    \n * @param idOverride\n * @returns {string}\n */\nexport default function useId(idOverride) {\n if (maybeReactUseId !== undefined) {\n const reactId = maybeReactUseId();\n return idOverride != null ? idOverride : reactId;\n }\n // eslint-disable-next-line react-hooks/rules-of-hooks -- `React.useId` is invariant at runtime.\n return useGlobalId(idOverride);\n}","export default function unsupportedProp(props, propName, componentName, location, propFullName) {\n if (process.env.NODE_ENV === 'production') {\n return null;\n }\n const propFullNameSafe = propFullName || propName;\n if (typeof props[propName] !== 'undefined') {\n return new Error(`The prop \\`${propFullNameSafe}\\` is not supported. Please remove it.`);\n }\n return null;\n}","'use client';\n\n/* eslint-disable react-hooks/rules-of-hooks, react-hooks/exhaustive-deps */\nimport * as React from 'react';\nexport default function useControlled({\n controlled,\n default: defaultProp,\n name,\n state = 'value'\n}) {\n // isControlled is ignored in the hook dependency lists as it should never change.\n const {\n current: isControlled\n } = React.useRef(controlled !== undefined);\n const [valueState, setValue] = React.useState(defaultProp);\n const value = isControlled ? controlled : valueState;\n if (process.env.NODE_ENV !== 'production') {\n React.useEffect(() => {\n if (isControlled !== (controlled !== undefined)) {\n console.error([`MUI: A component is changing the ${isControlled ? '' : 'un'}controlled ${state} state of ${name} to be ${isControlled ? 'un' : ''}controlled.`, 'Elements should not switch from uncontrolled to controlled (or vice versa).', `Decide between using a controlled or uncontrolled ${name} ` + 'element for the lifetime of the component.', \"The nature of the state is determined during the first render. It's considered controlled if the value is not `undefined`.\", 'More info: https://fb.me/react-controlled-components'].join('\\n'));\n }\n }, [state, name, controlled]);\n const {\n current: defaultValue\n } = React.useRef(defaultProp);\n React.useEffect(() => {\n if (!isControlled && defaultValue !== defaultProp) {\n console.error([`MUI: A component is changing the default ${state} state of an uncontrolled ${name} after being initialized. ` + `To suppress this warning opt to use a controlled ${name}.`].join('\\n'));\n }\n }, [JSON.stringify(defaultProp)]);\n }\n const setValueIfUncontrolled = React.useCallback(newValue => {\n if (!isControlled) {\n setValue(newValue);\n }\n }, []);\n return [value, setValueIfUncontrolled];\n}","'use client';\n\nimport * as React from 'react';\nimport useEnhancedEffect from '../useEnhancedEffect';\n\n/**\n * Inspired by https://github.com/facebook/react/issues/14099#issuecomment-440013892\n * See RFC in https://github.com/reactjs/rfcs/pull/220\n */\n\nfunction useEventCallback(fn) {\n const ref = React.useRef(fn);\n useEnhancedEffect(() => {\n ref.current = fn;\n });\n return React.useRef((...args) =>\n // @ts-expect-error hide `this`\n (0, ref.current)(...args)).current;\n}\nexport default useEventCallback;","'use client';\n\nimport * as React from 'react';\nimport setRef from '../setRef';\nexport default function useForkRef(...refs) {\n /**\n * This will create a new function if the refs passed to this hook change and are all defined.\n * This means react will call the old forkRef with `null` and the new forkRef\n * with the ref. Cleanup naturally emerges from this behavior.\n */\n return React.useMemo(() => {\n if (refs.every(ref => ref == null)) {\n return null;\n }\n return instance => {\n refs.forEach(ref => {\n setRef(ref, instance);\n });\n };\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, refs);\n}","'use client';\n\nimport * as React from 'react';\nconst UNINITIALIZED = {};\n\n/**\n * A React.useRef() that is initialized lazily with a function. Note that it accepts an optional\n * initialization argument, so the initialization function doesn't need to be an inline closure.\n *\n * @usage\n * const ref = useLazyRef(sortColumns, columns)\n */\nexport default function useLazyRef(init, initArg) {\n const ref = React.useRef(UNINITIALIZED);\n if (ref.current === UNINITIALIZED) {\n ref.current = init(initArg);\n }\n return ref;\n}","'use client';\n\nimport * as React from 'react';\nconst EMPTY = [];\n\n/**\n * A React.useEffect equivalent that runs once, when the component is mounted.\n */\nexport default function useOnMount(fn) {\n /* eslint-disable react-hooks/exhaustive-deps */\n React.useEffect(fn, EMPTY);\n /* eslint-enable react-hooks/exhaustive-deps */\n}","'use client';\n\nimport useLazyRef from '../useLazyRef/useLazyRef';\nimport useOnMount from '../useOnMount/useOnMount';\nexport class Timeout {\n constructor() {\n this.currentId = null;\n this.clear = () => {\n if (this.currentId !== null) {\n clearTimeout(this.currentId);\n this.currentId = null;\n }\n };\n this.disposeEffect = () => {\n return this.clear;\n };\n }\n static create() {\n return new Timeout();\n }\n /**\n * Executes `fn` after `delay`, clearing any previously scheduled call.\n */\n start(delay, fn) {\n this.clear();\n this.currentId = setTimeout(() => {\n this.currentId = null;\n fn();\n }, delay);\n }\n}\nexport default function useTimeout() {\n const timeout = useLazyRef(Timeout.create).current;\n useOnMount(timeout.disposeEffect);\n return timeout;\n}","'use client';\n\n// based on https://github.com/WICG/focus-visible/blob/v4.1.5/src/focus-visible.js\nimport * as React from 'react';\nimport { Timeout } from '../useTimeout/useTimeout';\nlet hadKeyboardEvent = true;\nlet hadFocusVisibleRecently = false;\nconst hadFocusVisibleRecentlyTimeout = new Timeout();\nconst inputTypesWhitelist = {\n text: true,\n search: true,\n url: true,\n tel: true,\n email: true,\n password: true,\n number: true,\n date: true,\n month: true,\n week: true,\n time: true,\n datetime: true,\n 'datetime-local': true\n};\n\n/**\n * Computes whether the given element should automatically trigger the\n * `focus-visible` class being added, i.e. whether it should always match\n * `:focus-visible` when focused.\n * @param {Element} node\n * @returns {boolean}\n */\nfunction focusTriggersKeyboardModality(node) {\n const {\n type,\n tagName\n } = node;\n if (tagName === 'INPUT' && inputTypesWhitelist[type] && !node.readOnly) {\n return true;\n }\n if (tagName === 'TEXTAREA' && !node.readOnly) {\n return true;\n }\n if (node.isContentEditable) {\n return true;\n }\n return false;\n}\n\n/**\n * Keep track of our keyboard modality state with `hadKeyboardEvent`.\n * If the most recent user interaction was via the keyboard;\n * and the key press did not include a meta, alt/option, or control key;\n * then the modality is keyboard. Otherwise, the modality is not keyboard.\n * @param {KeyboardEvent} event\n */\nfunction handleKeyDown(event) {\n if (event.metaKey || event.altKey || event.ctrlKey) {\n return;\n }\n hadKeyboardEvent = true;\n}\n\n/**\n * If at any point a user clicks with a pointing device, ensure that we change\n * the modality away from keyboard.\n * This avoids the situation where a user presses a key on an already focused\n * element, and then clicks on a different element, focusing it with a\n * pointing device, while we still think we're in keyboard modality.\n */\nfunction handlePointerDown() {\n hadKeyboardEvent = false;\n}\nfunction handleVisibilityChange() {\n if (this.visibilityState === 'hidden') {\n // If the tab becomes active again, the browser will handle calling focus\n // on the element (Safari actually calls it twice).\n // If this tab change caused a blur on an element with focus-visible,\n // re-apply the class when the user switches back to the tab.\n if (hadFocusVisibleRecently) {\n hadKeyboardEvent = true;\n }\n }\n}\nfunction prepare(doc) {\n doc.addEventListener('keydown', handleKeyDown, true);\n doc.addEventListener('mousedown', handlePointerDown, true);\n doc.addEventListener('pointerdown', handlePointerDown, true);\n doc.addEventListener('touchstart', handlePointerDown, true);\n doc.addEventListener('visibilitychange', handleVisibilityChange, true);\n}\nexport function teardown(doc) {\n doc.removeEventListener('keydown', handleKeyDown, true);\n doc.removeEventListener('mousedown', handlePointerDown, true);\n doc.removeEventListener('pointerdown', handlePointerDown, true);\n doc.removeEventListener('touchstart', handlePointerDown, true);\n doc.removeEventListener('visibilitychange', handleVisibilityChange, true);\n}\nfunction isFocusVisible(event) {\n const {\n target\n } = event;\n try {\n return target.matches(':focus-visible');\n } catch (error) {\n // Browsers not implementing :focus-visible will throw a SyntaxError.\n // We use our own heuristic for those browsers.\n // Rethrow might be better if it's not the expected error but do we really\n // want to crash if focus-visible malfunctioned?\n }\n\n // No need for validFocusTarget check. The user does that by attaching it to\n // focusable events only.\n return hadKeyboardEvent || focusTriggersKeyboardModality(target);\n}\nexport default function useIsFocusVisible() {\n const ref = React.useCallback(node => {\n if (node != null) {\n prepare(node.ownerDocument);\n }\n }, []);\n const isFocusVisibleRef = React.useRef(false);\n\n /**\n * Should be called if a blur event is fired\n */\n function handleBlurVisible() {\n // checking against potential state variable does not suffice if we focus and blur synchronously.\n // React wouldn't have time to trigger a re-render so `focusVisible` would be stale.\n // Ideally we would adjust `isFocusVisible(event)` to look at `relatedTarget` for blur events.\n // This doesn't work in IE11 due to https://github.com/facebook/react/issues/3751\n // TODO: check again if React releases their internal changes to focus event handling (https://github.com/facebook/react/pull/19186).\n if (isFocusVisibleRef.current) {\n // To detect a tab/window switch, we look for a blur event followed\n // rapidly by a visibility change.\n // If we don't see a visibility change within 100ms, it's probably a\n // regular focus change.\n hadFocusVisibleRecently = true;\n hadFocusVisibleRecentlyTimeout.start(100, () => {\n hadFocusVisibleRecently = false;\n });\n isFocusVisibleRef.current = false;\n return true;\n }\n return false;\n }\n\n /**\n * Should be called if a blur event is fired\n */\n function handleFocusVisible(event) {\n if (isFocusVisible(event)) {\n isFocusVisibleRef.current = true;\n return true;\n }\n return false;\n }\n return {\n isFocusVisibleRef,\n onFocus: handleFocusVisible,\n onBlur: handleBlurVisible,\n ref\n };\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\n/**\n * Add keys, values of `defaultProps` that does not exist in `props`\n * @param {object} defaultProps\n * @param {object} props\n * @returns {object} resolved props\n */\nexport default function resolveProps(defaultProps, props) {\n const output = _extends({}, props);\n Object.keys(defaultProps).forEach(propName => {\n if (propName.toString().match(/^(components|slots)$/)) {\n output[propName] = _extends({}, defaultProps[propName], output[propName]);\n } else if (propName.toString().match(/^(componentsProps|slotProps)$/)) {\n const defaultSlotProps = defaultProps[propName] || {};\n const slotProps = props[propName];\n output[propName] = {};\n if (!slotProps || !Object.keys(slotProps)) {\n // Reduce the iteration if the slot props is empty\n output[propName] = defaultSlotProps;\n } else if (!defaultSlotProps || !Object.keys(defaultSlotProps)) {\n // Reduce the iteration if the default slot props is empty\n output[propName] = slotProps;\n } else {\n output[propName] = _extends({}, slotProps);\n Object.keys(defaultSlotProps).forEach(slotPropName => {\n output[propName][slotPropName] = resolveProps(defaultSlotProps[slotPropName], slotProps[slotPropName]);\n });\n }\n } else if (output[propName] === undefined) {\n output[propName] = defaultProps[propName];\n }\n });\n return output;\n}","export default function composeClasses(slots, getUtilityClass, classes = undefined) {\n const output = {};\n Object.keys(slots).forEach(\n // `Object.keys(slots)` can't be wider than `T` because we infer `T` from `slots`.\n // @ts-expect-error https://github.com/microsoft/TypeScript/pull/12253#issuecomment-263132208\n slot => {\n output[slot] = slots[slot].reduce((acc, key) => {\n if (key) {\n const utilityClass = getUtilityClass(key);\n if (utilityClass !== '') {\n acc.push(utilityClass);\n }\n if (classes && classes[key]) {\n acc.push(classes[key]);\n }\n }\n return acc;\n }, []).join(' ');\n });\n return output;\n}","const defaultGenerator = componentName => componentName;\nconst createClassNameGenerator = () => {\n let generate = defaultGenerator;\n return {\n configure(generator) {\n generate = generator;\n },\n generate(componentName) {\n return generate(componentName);\n },\n reset() {\n generate = defaultGenerator;\n }\n };\n};\nconst ClassNameGenerator = createClassNameGenerator();\nexport default ClassNameGenerator;","import ClassNameGenerator from '../ClassNameGenerator';\nexport const globalStateClasses = {\n active: 'active',\n checked: 'checked',\n completed: 'completed',\n disabled: 'disabled',\n error: 'error',\n expanded: 'expanded',\n focused: 'focused',\n focusVisible: 'focusVisible',\n open: 'open',\n readOnly: 'readOnly',\n required: 'required',\n selected: 'selected'\n};\nexport default function generateUtilityClass(componentName, slot, globalStatePrefix = 'Mui') {\n const globalStateClass = globalStateClasses[slot];\n return globalStateClass ? `${globalStatePrefix}-${globalStateClass}` : `${ClassNameGenerator.generate(componentName)}-${slot}`;\n}\nexport function isGlobalState(slot) {\n return globalStateClasses[slot] !== undefined;\n}","import generateUtilityClass from '../generateUtilityClass';\nexport default function generateUtilityClasses(componentName, slots, globalStatePrefix = 'Mui') {\n const result = {};\n slots.forEach(slot => {\n result[slot] = generateUtilityClass(componentName, slot, globalStatePrefix);\n });\n return result;\n}","function clamp(val, min = Number.MIN_SAFE_INTEGER, max = Number.MAX_SAFE_INTEGER) {\n return Math.max(min, Math.min(val, max));\n}\nexport default clamp;","export default function _objectWithoutPropertiesLoose(source, excluded) {\n if (source == null) return {};\n var target = {};\n var sourceKeys = Object.keys(source);\n var key, i;\n for (i = 0; i < sourceKeys.length; i++) {\n key = sourceKeys[i];\n if (excluded.indexOf(key) >= 0) continue;\n target[key] = source[key];\n }\n return target;\n}","import _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nconst _excluded = [\"values\", \"unit\", \"step\"];\n// Sorted ASC by size. That's important.\n// It can't be configured as it's used statically for propTypes.\nexport const breakpointKeys = ['xs', 'sm', 'md', 'lg', 'xl'];\nconst sortBreakpointsValues = values => {\n const breakpointsAsArray = Object.keys(values).map(key => ({\n key,\n val: values[key]\n })) || [];\n // Sort in ascending order\n breakpointsAsArray.sort((breakpoint1, breakpoint2) => breakpoint1.val - breakpoint2.val);\n return breakpointsAsArray.reduce((acc, obj) => {\n return _extends({}, acc, {\n [obj.key]: obj.val\n });\n }, {});\n};\n\n// Keep in mind that @media is inclusive by the CSS specification.\nexport default function createBreakpoints(breakpoints) {\n const {\n // The breakpoint **start** at this value.\n // For instance with the first breakpoint xs: [xs, sm).\n values = {\n xs: 0,\n // phone\n sm: 600,\n // tablet\n md: 900,\n // small laptop\n lg: 1200,\n // desktop\n xl: 1536 // large screen\n },\n unit = 'px',\n step = 5\n } = breakpoints,\n other = _objectWithoutPropertiesLoose(breakpoints, _excluded);\n const sortedValues = sortBreakpointsValues(values);\n const keys = Object.keys(sortedValues);\n function up(key) {\n const value = typeof values[key] === 'number' ? values[key] : key;\n return `@media (min-width:${value}${unit})`;\n }\n function down(key) {\n const value = typeof values[key] === 'number' ? values[key] : key;\n return `@media (max-width:${value - step / 100}${unit})`;\n }\n function between(start, end) {\n const endIndex = keys.indexOf(end);\n return `@media (min-width:${typeof values[start] === 'number' ? values[start] : start}${unit}) and ` + `(max-width:${(endIndex !== -1 && typeof values[keys[endIndex]] === 'number' ? values[keys[endIndex]] : end) - step / 100}${unit})`;\n }\n function only(key) {\n if (keys.indexOf(key) + 1 < keys.length) {\n return between(key, keys[keys.indexOf(key) + 1]);\n }\n return up(key);\n }\n function not(key) {\n // handle first and last key separately, for better readability\n const keyIndex = keys.indexOf(key);\n if (keyIndex === 0) {\n return up(keys[1]);\n }\n if (keyIndex === keys.length - 1) {\n return down(keys[keyIndex]);\n }\n return between(key, keys[keys.indexOf(key) + 1]).replace('@media', '@media not all and');\n }\n return _extends({\n keys,\n values: sortedValues,\n up,\n down,\n between,\n only,\n not,\n unit\n }, other);\n}","const shape = {\n borderRadius: 4\n};\nexport default shape;","import PropTypes from 'prop-types';\nconst responsivePropType = process.env.NODE_ENV !== 'production' ? PropTypes.oneOfType([PropTypes.number, PropTypes.string, PropTypes.object, PropTypes.array]) : {};\nexport default responsivePropType;","import deepmerge from '@mui/utils/deepmerge';\nfunction merge(acc, item) {\n if (!item) {\n return acc;\n }\n return deepmerge(acc, item, {\n clone: false // No need to clone deep, it's way faster.\n });\n}\nexport default merge;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport PropTypes from 'prop-types';\nimport deepmerge from '@mui/utils/deepmerge';\nimport merge from './merge';\n\n// The breakpoint **start** at this value.\n// For instance with the first breakpoint xs: [xs, sm[.\nexport const values = {\n xs: 0,\n // phone\n sm: 600,\n // tablet\n md: 900,\n // small laptop\n lg: 1200,\n // desktop\n xl: 1536 // large screen\n};\nconst defaultBreakpoints = {\n // Sorted ASC by size. That's important.\n // It can't be configured as it's used statically for propTypes.\n keys: ['xs', 'sm', 'md', 'lg', 'xl'],\n up: key => `@media (min-width:${values[key]}px)`\n};\nexport function handleBreakpoints(props, propValue, styleFromPropValue) {\n const theme = props.theme || {};\n if (Array.isArray(propValue)) {\n const themeBreakpoints = theme.breakpoints || defaultBreakpoints;\n return propValue.reduce((acc, item, index) => {\n acc[themeBreakpoints.up(themeBreakpoints.keys[index])] = styleFromPropValue(propValue[index]);\n return acc;\n }, {});\n }\n if (typeof propValue === 'object') {\n const themeBreakpoints = theme.breakpoints || defaultBreakpoints;\n return Object.keys(propValue).reduce((acc, breakpoint) => {\n // key is breakpoint\n if (Object.keys(themeBreakpoints.values || values).indexOf(breakpoint) !== -1) {\n const mediaKey = themeBreakpoints.up(breakpoint);\n acc[mediaKey] = styleFromPropValue(propValue[breakpoint], breakpoint);\n } else {\n const cssKey = breakpoint;\n acc[cssKey] = propValue[cssKey];\n }\n return acc;\n }, {});\n }\n const output = styleFromPropValue(propValue);\n return output;\n}\nfunction breakpoints(styleFunction) {\n // false positive\n // eslint-disable-next-line react/function-component-definition\n const newStyleFunction = props => {\n const theme = props.theme || {};\n const base = styleFunction(props);\n const themeBreakpoints = theme.breakpoints || defaultBreakpoints;\n const extended = themeBreakpoints.keys.reduce((acc, key) => {\n if (props[key]) {\n acc = acc || {};\n acc[themeBreakpoints.up(key)] = styleFunction(_extends({\n theme\n }, props[key]));\n }\n return acc;\n }, null);\n return merge(base, extended);\n };\n newStyleFunction.propTypes = process.env.NODE_ENV !== 'production' ? _extends({}, styleFunction.propTypes, {\n xs: PropTypes.object,\n sm: PropTypes.object,\n md: PropTypes.object,\n lg: PropTypes.object,\n xl: PropTypes.object\n }) : {};\n newStyleFunction.filterProps = ['xs', 'sm', 'md', 'lg', 'xl', ...styleFunction.filterProps];\n return newStyleFunction;\n}\nexport function createEmptyBreakpointObject(breakpointsInput = {}) {\n var _breakpointsInput$key;\n const breakpointsInOrder = (_breakpointsInput$key = breakpointsInput.keys) == null ? void 0 : _breakpointsInput$key.reduce((acc, key) => {\n const breakpointStyleKey = breakpointsInput.up(key);\n acc[breakpointStyleKey] = {};\n return acc;\n }, {});\n return breakpointsInOrder || {};\n}\nexport function removeUnusedBreakpoints(breakpointKeys, style) {\n return breakpointKeys.reduce((acc, key) => {\n const breakpointOutput = acc[key];\n const isBreakpointUnused = !breakpointOutput || Object.keys(breakpointOutput).length === 0;\n if (isBreakpointUnused) {\n delete acc[key];\n }\n return acc;\n }, style);\n}\nexport function mergeBreakpointsInOrder(breakpointsInput, ...styles) {\n const emptyBreakpoints = createEmptyBreakpointObject(breakpointsInput);\n const mergedOutput = [emptyBreakpoints, ...styles].reduce((prev, next) => deepmerge(prev, next), {});\n return removeUnusedBreakpoints(Object.keys(emptyBreakpoints), mergedOutput);\n}\n\n// compute base for responsive values; e.g.,\n// [1,2,3] => {xs: true, sm: true, md: true}\n// {xs: 1, sm: 2, md: 3} => {xs: true, sm: true, md: true}\nexport function computeBreakpointsBase(breakpointValues, themeBreakpoints) {\n // fixed value\n if (typeof breakpointValues !== 'object') {\n return {};\n }\n const base = {};\n const breakpointsKeys = Object.keys(themeBreakpoints);\n if (Array.isArray(breakpointValues)) {\n breakpointsKeys.forEach((breakpoint, i) => {\n if (i < breakpointValues.length) {\n base[breakpoint] = true;\n }\n });\n } else {\n breakpointsKeys.forEach(breakpoint => {\n if (breakpointValues[breakpoint] != null) {\n base[breakpoint] = true;\n }\n });\n }\n return base;\n}\nexport function resolveBreakpointValues({\n values: breakpointValues,\n breakpoints: themeBreakpoints,\n base: customBase\n}) {\n const base = customBase || computeBreakpointsBase(breakpointValues, themeBreakpoints);\n const keys = Object.keys(base);\n if (keys.length === 0) {\n return breakpointValues;\n }\n let previous;\n return keys.reduce((acc, breakpoint, i) => {\n if (Array.isArray(breakpointValues)) {\n acc[breakpoint] = breakpointValues[i] != null ? breakpointValues[i] : breakpointValues[previous];\n previous = i;\n } else if (typeof breakpointValues === 'object') {\n acc[breakpoint] = breakpointValues[breakpoint] != null ? breakpointValues[breakpoint] : breakpointValues[previous];\n previous = breakpoint;\n } else {\n acc[breakpoint] = breakpointValues;\n }\n return acc;\n }, {});\n}\nexport default breakpoints;","import capitalize from '@mui/utils/capitalize';\nimport responsivePropType from './responsivePropType';\nimport { handleBreakpoints } from './breakpoints';\nexport function getPath(obj, path, checkVars = true) {\n if (!path || typeof path !== 'string') {\n return null;\n }\n\n // Check if CSS variables are used\n if (obj && obj.vars && checkVars) {\n const val = `vars.${path}`.split('.').reduce((acc, item) => acc && acc[item] ? acc[item] : null, obj);\n if (val != null) {\n return val;\n }\n }\n return path.split('.').reduce((acc, item) => {\n if (acc && acc[item] != null) {\n return acc[item];\n }\n return null;\n }, obj);\n}\nexport function getStyleValue(themeMapping, transform, propValueFinal, userValue = propValueFinal) {\n let value;\n if (typeof themeMapping === 'function') {\n value = themeMapping(propValueFinal);\n } else if (Array.isArray(themeMapping)) {\n value = themeMapping[propValueFinal] || userValue;\n } else {\n value = getPath(themeMapping, propValueFinal) || userValue;\n }\n if (transform) {\n value = transform(value, userValue, themeMapping);\n }\n return value;\n}\nfunction style(options) {\n const {\n prop,\n cssProperty = options.prop,\n themeKey,\n transform\n } = options;\n\n // false positive\n // eslint-disable-next-line react/function-component-definition\n const fn = props => {\n if (props[prop] == null) {\n return null;\n }\n const propValue = props[prop];\n const theme = props.theme;\n const themeMapping = getPath(theme, themeKey) || {};\n const styleFromPropValue = propValueFinal => {\n let value = getStyleValue(themeMapping, transform, propValueFinal);\n if (propValueFinal === value && typeof propValueFinal === 'string') {\n // Haven't found value\n value = getStyleValue(themeMapping, transform, `${prop}${propValueFinal === 'default' ? '' : capitalize(propValueFinal)}`, propValueFinal);\n }\n if (cssProperty === false) {\n return value;\n }\n return {\n [cssProperty]: value\n };\n };\n return handleBreakpoints(props, propValue, styleFromPropValue);\n };\n fn.propTypes = process.env.NODE_ENV !== 'production' ? {\n [prop]: responsivePropType\n } : {};\n fn.filterProps = [prop];\n return fn;\n}\nexport default style;","export default function memoize(fn) {\n const cache = {};\n return arg => {\n if (cache[arg] === undefined) {\n cache[arg] = fn(arg);\n }\n return cache[arg];\n };\n}","import responsivePropType from './responsivePropType';\nimport { handleBreakpoints } from './breakpoints';\nimport { getPath } from './style';\nimport merge from './merge';\nimport memoize from './memoize';\nconst properties = {\n m: 'margin',\n p: 'padding'\n};\nconst directions = {\n t: 'Top',\n r: 'Right',\n b: 'Bottom',\n l: 'Left',\n x: ['Left', 'Right'],\n y: ['Top', 'Bottom']\n};\nconst aliases = {\n marginX: 'mx',\n marginY: 'my',\n paddingX: 'px',\n paddingY: 'py'\n};\n\n// memoize() impact:\n// From 300,000 ops/sec\n// To 350,000 ops/sec\nconst getCssProperties = memoize(prop => {\n // It's not a shorthand notation.\n if (prop.length > 2) {\n if (aliases[prop]) {\n prop = aliases[prop];\n } else {\n return [prop];\n }\n }\n const [a, b] = prop.split('');\n const property = properties[a];\n const direction = directions[b] || '';\n return Array.isArray(direction) ? direction.map(dir => property + dir) : [property + direction];\n});\nexport const marginKeys = ['m', 'mt', 'mr', 'mb', 'ml', 'mx', 'my', 'margin', 'marginTop', 'marginRight', 'marginBottom', 'marginLeft', 'marginX', 'marginY', 'marginInline', 'marginInlineStart', 'marginInlineEnd', 'marginBlock', 'marginBlockStart', 'marginBlockEnd'];\nexport const paddingKeys = ['p', 'pt', 'pr', 'pb', 'pl', 'px', 'py', 'padding', 'paddingTop', 'paddingRight', 'paddingBottom', 'paddingLeft', 'paddingX', 'paddingY', 'paddingInline', 'paddingInlineStart', 'paddingInlineEnd', 'paddingBlock', 'paddingBlockStart', 'paddingBlockEnd'];\nconst spacingKeys = [...marginKeys, ...paddingKeys];\nexport function createUnaryUnit(theme, themeKey, defaultValue, propName) {\n var _getPath;\n const themeSpacing = (_getPath = getPath(theme, themeKey, false)) != null ? _getPath : defaultValue;\n if (typeof themeSpacing === 'number') {\n return abs => {\n if (typeof abs === 'string') {\n return abs;\n }\n if (process.env.NODE_ENV !== 'production') {\n if (typeof abs !== 'number') {\n console.error(`MUI: Expected ${propName} argument to be a number or a string, got ${abs}.`);\n }\n }\n return themeSpacing * abs;\n };\n }\n if (Array.isArray(themeSpacing)) {\n return abs => {\n if (typeof abs === 'string') {\n return abs;\n }\n if (process.env.NODE_ENV !== 'production') {\n if (!Number.isInteger(abs)) {\n console.error([`MUI: The \\`theme.${themeKey}\\` array type cannot be combined with non integer values.` + `You should either use an integer value that can be used as index, or define the \\`theme.${themeKey}\\` as a number.`].join('\\n'));\n } else if (abs > themeSpacing.length - 1) {\n console.error([`MUI: The value provided (${abs}) overflows.`, `The supported values are: ${JSON.stringify(themeSpacing)}.`, `${abs} > ${themeSpacing.length - 1}, you need to add the missing values.`].join('\\n'));\n }\n }\n return themeSpacing[abs];\n };\n }\n if (typeof themeSpacing === 'function') {\n return themeSpacing;\n }\n if (process.env.NODE_ENV !== 'production') {\n console.error([`MUI: The \\`theme.${themeKey}\\` value (${themeSpacing}) is invalid.`, 'It should be a number, an array or a function.'].join('\\n'));\n }\n return () => undefined;\n}\nexport function createUnarySpacing(theme) {\n return createUnaryUnit(theme, 'spacing', 8, 'spacing');\n}\nexport function getValue(transformer, propValue) {\n if (typeof propValue === 'string' || propValue == null) {\n return propValue;\n }\n const abs = Math.abs(propValue);\n const transformed = transformer(abs);\n if (propValue >= 0) {\n return transformed;\n }\n if (typeof transformed === 'number') {\n return -transformed;\n }\n return `-${transformed}`;\n}\nexport function getStyleFromPropValue(cssProperties, transformer) {\n return propValue => cssProperties.reduce((acc, cssProperty) => {\n acc[cssProperty] = getValue(transformer, propValue);\n return acc;\n }, {});\n}\nfunction resolveCssProperty(props, keys, prop, transformer) {\n // Using a hash computation over an array iteration could be faster, but with only 28 items,\n // it's doesn't worth the bundle size.\n if (keys.indexOf(prop) === -1) {\n return null;\n }\n const cssProperties = getCssProperties(prop);\n const styleFromPropValue = getStyleFromPropValue(cssProperties, transformer);\n const propValue = props[prop];\n return handleBreakpoints(props, propValue, styleFromPropValue);\n}\nfunction style(props, keys) {\n const transformer = createUnarySpacing(props.theme);\n return Object.keys(props).map(prop => resolveCssProperty(props, keys, prop, transformer)).reduce(merge, {});\n}\nexport function margin(props) {\n return style(props, marginKeys);\n}\nmargin.propTypes = process.env.NODE_ENV !== 'production' ? marginKeys.reduce((obj, key) => {\n obj[key] = responsivePropType;\n return obj;\n}, {}) : {};\nmargin.filterProps = marginKeys;\nexport function padding(props) {\n return style(props, paddingKeys);\n}\npadding.propTypes = process.env.NODE_ENV !== 'production' ? paddingKeys.reduce((obj, key) => {\n obj[key] = responsivePropType;\n return obj;\n}, {}) : {};\npadding.filterProps = paddingKeys;\nfunction spacing(props) {\n return style(props, spacingKeys);\n}\nspacing.propTypes = process.env.NODE_ENV !== 'production' ? spacingKeys.reduce((obj, key) => {\n obj[key] = responsivePropType;\n return obj;\n}, {}) : {};\nspacing.filterProps = spacingKeys;\nexport default spacing;","import { createUnarySpacing } from '../spacing';\n\n// The different signatures imply different meaning for their arguments that can't be expressed structurally.\n// We express the difference with variable names.\n\nexport default function createSpacing(spacingInput = 8) {\n // Already transformed.\n if (spacingInput.mui) {\n return spacingInput;\n }\n\n // Material Design layouts are visually balanced. Most measurements align to an 8dp grid, which aligns both spacing and the overall layout.\n // Smaller components, such as icons, can align to a 4dp grid.\n // https://m2.material.io/design/layout/understanding-layout.html\n const transform = createUnarySpacing({\n spacing: spacingInput\n });\n const spacing = (...argsInput) => {\n if (process.env.NODE_ENV !== 'production') {\n if (!(argsInput.length <= 4)) {\n console.error(`MUI: Too many arguments provided, expected between 0 and 4, got ${argsInput.length}`);\n }\n }\n const args = argsInput.length === 0 ? [1] : argsInput;\n return args.map(argument => {\n const output = transform(argument);\n return typeof output === 'number' ? `${output}px` : output;\n }).join(' ');\n };\n spacing.mui = true;\n return spacing;\n}","import merge from './merge';\nfunction compose(...styles) {\n const handlers = styles.reduce((acc, style) => {\n style.filterProps.forEach(prop => {\n acc[prop] = style;\n });\n return acc;\n }, {});\n\n // false positive\n // eslint-disable-next-line react/function-component-definition\n const fn = props => {\n return Object.keys(props).reduce((acc, prop) => {\n if (handlers[prop]) {\n return merge(acc, handlers[prop](props));\n }\n return acc;\n }, {});\n };\n fn.propTypes = process.env.NODE_ENV !== 'production' ? styles.reduce((acc, style) => Object.assign(acc, style.propTypes), {}) : {};\n fn.filterProps = styles.reduce((acc, style) => acc.concat(style.filterProps), []);\n return fn;\n}\nexport default compose;","import responsivePropType from './responsivePropType';\nimport style from './style';\nimport compose from './compose';\nimport { createUnaryUnit, getValue } from './spacing';\nimport { handleBreakpoints } from './breakpoints';\nexport function borderTransform(value) {\n if (typeof value !== 'number') {\n return value;\n }\n return `${value}px solid`;\n}\nfunction createBorderStyle(prop, transform) {\n return style({\n prop,\n themeKey: 'borders',\n transform\n });\n}\nexport const border = createBorderStyle('border', borderTransform);\nexport const borderTop = createBorderStyle('borderTop', borderTransform);\nexport const borderRight = createBorderStyle('borderRight', borderTransform);\nexport const borderBottom = createBorderStyle('borderBottom', borderTransform);\nexport const borderLeft = createBorderStyle('borderLeft', borderTransform);\nexport const borderColor = createBorderStyle('borderColor');\nexport const borderTopColor = createBorderStyle('borderTopColor');\nexport const borderRightColor = createBorderStyle('borderRightColor');\nexport const borderBottomColor = createBorderStyle('borderBottomColor');\nexport const borderLeftColor = createBorderStyle('borderLeftColor');\nexport const outline = createBorderStyle('outline', borderTransform);\nexport const outlineColor = createBorderStyle('outlineColor');\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const borderRadius = props => {\n if (props.borderRadius !== undefined && props.borderRadius !== null) {\n const transformer = createUnaryUnit(props.theme, 'shape.borderRadius', 4, 'borderRadius');\n const styleFromPropValue = propValue => ({\n borderRadius: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.borderRadius, styleFromPropValue);\n }\n return null;\n};\nborderRadius.propTypes = process.env.NODE_ENV !== 'production' ? {\n borderRadius: responsivePropType\n} : {};\nborderRadius.filterProps = ['borderRadius'];\nconst borders = compose(border, borderTop, borderRight, borderBottom, borderLeft, borderColor, borderTopColor, borderRightColor, borderBottomColor, borderLeftColor, borderRadius, outline, outlineColor);\nexport default borders;","import style from './style';\nimport compose from './compose';\nimport { createUnaryUnit, getValue } from './spacing';\nimport { handleBreakpoints } from './breakpoints';\nimport responsivePropType from './responsivePropType';\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const gap = props => {\n if (props.gap !== undefined && props.gap !== null) {\n const transformer = createUnaryUnit(props.theme, 'spacing', 8, 'gap');\n const styleFromPropValue = propValue => ({\n gap: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.gap, styleFromPropValue);\n }\n return null;\n};\ngap.propTypes = process.env.NODE_ENV !== 'production' ? {\n gap: responsivePropType\n} : {};\ngap.filterProps = ['gap'];\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const columnGap = props => {\n if (props.columnGap !== undefined && props.columnGap !== null) {\n const transformer = createUnaryUnit(props.theme, 'spacing', 8, 'columnGap');\n const styleFromPropValue = propValue => ({\n columnGap: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.columnGap, styleFromPropValue);\n }\n return null;\n};\ncolumnGap.propTypes = process.env.NODE_ENV !== 'production' ? {\n columnGap: responsivePropType\n} : {};\ncolumnGap.filterProps = ['columnGap'];\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const rowGap = props => {\n if (props.rowGap !== undefined && props.rowGap !== null) {\n const transformer = createUnaryUnit(props.theme, 'spacing', 8, 'rowGap');\n const styleFromPropValue = propValue => ({\n rowGap: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.rowGap, styleFromPropValue);\n }\n return null;\n};\nrowGap.propTypes = process.env.NODE_ENV !== 'production' ? {\n rowGap: responsivePropType\n} : {};\nrowGap.filterProps = ['rowGap'];\nexport const gridColumn = style({\n prop: 'gridColumn'\n});\nexport const gridRow = style({\n prop: 'gridRow'\n});\nexport const gridAutoFlow = style({\n prop: 'gridAutoFlow'\n});\nexport const gridAutoColumns = style({\n prop: 'gridAutoColumns'\n});\nexport const gridAutoRows = style({\n prop: 'gridAutoRows'\n});\nexport const gridTemplateColumns = style({\n prop: 'gridTemplateColumns'\n});\nexport const gridTemplateRows = style({\n prop: 'gridTemplateRows'\n});\nexport const gridTemplateAreas = style({\n prop: 'gridTemplateAreas'\n});\nexport const gridArea = style({\n prop: 'gridArea'\n});\nconst grid = compose(gap, columnGap, rowGap, gridColumn, gridRow, gridAutoFlow, gridAutoColumns, gridAutoRows, gridTemplateColumns, gridTemplateRows, gridTemplateAreas, gridArea);\nexport default grid;","import style from './style';\nimport compose from './compose';\nexport function paletteTransform(value, userValue) {\n if (userValue === 'grey') {\n return userValue;\n }\n return value;\n}\nexport const color = style({\n prop: 'color',\n themeKey: 'palette',\n transform: paletteTransform\n});\nexport const bgcolor = style({\n prop: 'bgcolor',\n cssProperty: 'backgroundColor',\n themeKey: 'palette',\n transform: paletteTransform\n});\nexport const backgroundColor = style({\n prop: 'backgroundColor',\n themeKey: 'palette',\n transform: paletteTransform\n});\nconst palette = compose(color, bgcolor, backgroundColor);\nexport default palette;","import style from './style';\nimport compose from './compose';\nimport { handleBreakpoints, values as breakpointsValues } from './breakpoints';\nexport function sizingTransform(value) {\n return value <= 1 && value !== 0 ? `${value * 100}%` : value;\n}\nexport const width = style({\n prop: 'width',\n transform: sizingTransform\n});\nexport const maxWidth = props => {\n if (props.maxWidth !== undefined && props.maxWidth !== null) {\n const styleFromPropValue = propValue => {\n var _props$theme, _props$theme2;\n const breakpoint = ((_props$theme = props.theme) == null || (_props$theme = _props$theme.breakpoints) == null || (_props$theme = _props$theme.values) == null ? void 0 : _props$theme[propValue]) || breakpointsValues[propValue];\n if (!breakpoint) {\n return {\n maxWidth: sizingTransform(propValue)\n };\n }\n if (((_props$theme2 = props.theme) == null || (_props$theme2 = _props$theme2.breakpoints) == null ? void 0 : _props$theme2.unit) !== 'px') {\n return {\n maxWidth: `${breakpoint}${props.theme.breakpoints.unit}`\n };\n }\n return {\n maxWidth: breakpoint\n };\n };\n return handleBreakpoints(props, props.maxWidth, styleFromPropValue);\n }\n return null;\n};\nmaxWidth.filterProps = ['maxWidth'];\nexport const minWidth = style({\n prop: 'minWidth',\n transform: sizingTransform\n});\nexport const height = style({\n prop: 'height',\n transform: sizingTransform\n});\nexport const maxHeight = style({\n prop: 'maxHeight',\n transform: sizingTransform\n});\nexport const minHeight = style({\n prop: 'minHeight',\n transform: sizingTransform\n});\nexport const sizeWidth = style({\n prop: 'size',\n cssProperty: 'width',\n transform: sizingTransform\n});\nexport const sizeHeight = style({\n prop: 'size',\n cssProperty: 'height',\n transform: sizingTransform\n});\nexport const boxSizing = style({\n prop: 'boxSizing'\n});\nconst sizing = compose(width, maxWidth, minWidth, height, maxHeight, minHeight, boxSizing);\nexport default sizing;","import { padding, margin } from '../spacing';\nimport { borderRadius, borderTransform } from '../borders';\nimport { gap, rowGap, columnGap } from '../cssGrid';\nimport { paletteTransform } from '../palette';\nimport { maxWidth, sizingTransform } from '../sizing';\nconst defaultSxConfig = {\n // borders\n border: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderTop: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderRight: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderBottom: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderLeft: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderColor: {\n themeKey: 'palette'\n },\n borderTopColor: {\n themeKey: 'palette'\n },\n borderRightColor: {\n themeKey: 'palette'\n },\n borderBottomColor: {\n themeKey: 'palette'\n },\n borderLeftColor: {\n themeKey: 'palette'\n },\n outline: {\n themeKey: 'borders',\n transform: borderTransform\n },\n outlineColor: {\n themeKey: 'palette'\n },\n borderRadius: {\n themeKey: 'shape.borderRadius',\n style: borderRadius\n },\n // palette\n color: {\n themeKey: 'palette',\n transform: paletteTransform\n },\n bgcolor: {\n themeKey: 'palette',\n cssProperty: 'backgroundColor',\n transform: paletteTransform\n },\n backgroundColor: {\n themeKey: 'palette',\n transform: paletteTransform\n },\n // spacing\n p: {\n style: padding\n },\n pt: {\n style: padding\n },\n pr: {\n style: padding\n },\n pb: {\n style: padding\n },\n pl: {\n style: padding\n },\n px: {\n style: padding\n },\n py: {\n style: padding\n },\n padding: {\n style: padding\n },\n paddingTop: {\n style: padding\n },\n paddingRight: {\n style: padding\n },\n paddingBottom: {\n style: padding\n },\n paddingLeft: {\n style: padding\n },\n paddingX: {\n style: padding\n },\n paddingY: {\n style: padding\n },\n paddingInline: {\n style: padding\n },\n paddingInlineStart: {\n style: padding\n },\n paddingInlineEnd: {\n style: padding\n },\n paddingBlock: {\n style: padding\n },\n paddingBlockStart: {\n style: padding\n },\n paddingBlockEnd: {\n style: padding\n },\n m: {\n style: margin\n },\n mt: {\n style: margin\n },\n mr: {\n style: margin\n },\n mb: {\n style: margin\n },\n ml: {\n style: margin\n },\n mx: {\n style: margin\n },\n my: {\n style: margin\n },\n margin: {\n style: margin\n },\n marginTop: {\n style: margin\n },\n marginRight: {\n style: margin\n },\n marginBottom: {\n style: margin\n },\n marginLeft: {\n style: margin\n },\n marginX: {\n style: margin\n },\n marginY: {\n style: margin\n },\n marginInline: {\n style: margin\n },\n marginInlineStart: {\n style: margin\n },\n marginInlineEnd: {\n style: margin\n },\n marginBlock: {\n style: margin\n },\n marginBlockStart: {\n style: margin\n },\n marginBlockEnd: {\n style: margin\n },\n // display\n displayPrint: {\n cssProperty: false,\n transform: value => ({\n '@media print': {\n display: value\n }\n })\n },\n display: {},\n overflow: {},\n textOverflow: {},\n visibility: {},\n whiteSpace: {},\n // flexbox\n flexBasis: {},\n flexDirection: {},\n flexWrap: {},\n justifyContent: {},\n alignItems: {},\n alignContent: {},\n order: {},\n flex: {},\n flexGrow: {},\n flexShrink: {},\n alignSelf: {},\n justifyItems: {},\n justifySelf: {},\n // grid\n gap: {\n style: gap\n },\n rowGap: {\n style: rowGap\n },\n columnGap: {\n style: columnGap\n },\n gridColumn: {},\n gridRow: {},\n gridAutoFlow: {},\n gridAutoColumns: {},\n gridAutoRows: {},\n gridTemplateColumns: {},\n gridTemplateRows: {},\n gridTemplateAreas: {},\n gridArea: {},\n // positions\n position: {},\n zIndex: {\n themeKey: 'zIndex'\n },\n top: {},\n right: {},\n bottom: {},\n left: {},\n // shadows\n boxShadow: {\n themeKey: 'shadows'\n },\n // sizing\n width: {\n transform: sizingTransform\n },\n maxWidth: {\n style: maxWidth\n },\n minWidth: {\n transform: sizingTransform\n },\n height: {\n transform: sizingTransform\n },\n maxHeight: {\n transform: sizingTransform\n },\n minHeight: {\n transform: sizingTransform\n },\n boxSizing: {},\n // typography\n fontFamily: {\n themeKey: 'typography'\n },\n fontSize: {\n themeKey: 'typography'\n },\n fontStyle: {\n themeKey: 'typography'\n },\n fontWeight: {\n themeKey: 'typography'\n },\n letterSpacing: {},\n textTransform: {},\n lineHeight: {},\n textAlign: {},\n typography: {\n cssProperty: false,\n themeKey: 'typography'\n }\n};\nexport default defaultSxConfig;","import capitalize from '@mui/utils/capitalize';\nimport merge from '../merge';\nimport { getPath, getStyleValue as getValue } from '../style';\nimport { handleBreakpoints, createEmptyBreakpointObject, removeUnusedBreakpoints } from '../breakpoints';\nimport defaultSxConfig from './defaultSxConfig';\nfunction objectsHaveSameKeys(...objects) {\n const allKeys = objects.reduce((keys, object) => keys.concat(Object.keys(object)), []);\n const union = new Set(allKeys);\n return objects.every(object => union.size === Object.keys(object).length);\n}\nfunction callIfFn(maybeFn, arg) {\n return typeof maybeFn === 'function' ? maybeFn(arg) : maybeFn;\n}\n\n// eslint-disable-next-line @typescript-eslint/naming-convention\nexport function unstable_createStyleFunctionSx() {\n function getThemeValue(prop, val, theme, config) {\n const props = {\n [prop]: val,\n theme\n };\n const options = config[prop];\n if (!options) {\n return {\n [prop]: val\n };\n }\n const {\n cssProperty = prop,\n themeKey,\n transform,\n style\n } = options;\n if (val == null) {\n return null;\n }\n\n // TODO v6: remove, see https://github.com/mui/material-ui/pull/38123\n if (themeKey === 'typography' && val === 'inherit') {\n return {\n [prop]: val\n };\n }\n const themeMapping = getPath(theme, themeKey) || {};\n if (style) {\n return style(props);\n }\n const styleFromPropValue = propValueFinal => {\n let value = getValue(themeMapping, transform, propValueFinal);\n if (propValueFinal === value && typeof propValueFinal === 'string') {\n // Haven't found value\n value = getValue(themeMapping, transform, `${prop}${propValueFinal === 'default' ? '' : capitalize(propValueFinal)}`, propValueFinal);\n }\n if (cssProperty === false) {\n return value;\n }\n return {\n [cssProperty]: value\n };\n };\n return handleBreakpoints(props, val, styleFromPropValue);\n }\n function styleFunctionSx(props) {\n var _theme$unstable_sxCon;\n const {\n sx,\n theme = {}\n } = props || {};\n if (!sx) {\n return null; // Emotion & styled-components will neglect null\n }\n const config = (_theme$unstable_sxCon = theme.unstable_sxConfig) != null ? _theme$unstable_sxCon : defaultSxConfig;\n\n /*\n * Receive `sxInput` as object or callback\n * and then recursively check keys & values to create media query object styles.\n * (the result will be used in `styled`)\n */\n function traverse(sxInput) {\n let sxObject = sxInput;\n if (typeof sxInput === 'function') {\n sxObject = sxInput(theme);\n } else if (typeof sxInput !== 'object') {\n // value\n return sxInput;\n }\n if (!sxObject) {\n return null;\n }\n const emptyBreakpoints = createEmptyBreakpointObject(theme.breakpoints);\n const breakpointsKeys = Object.keys(emptyBreakpoints);\n let css = emptyBreakpoints;\n Object.keys(sxObject).forEach(styleKey => {\n const value = callIfFn(sxObject[styleKey], theme);\n if (value !== null && value !== undefined) {\n if (typeof value === 'object') {\n if (config[styleKey]) {\n css = merge(css, getThemeValue(styleKey, value, theme, config));\n } else {\n const breakpointsValues = handleBreakpoints({\n theme\n }, value, x => ({\n [styleKey]: x\n }));\n if (objectsHaveSameKeys(breakpointsValues, value)) {\n css[styleKey] = styleFunctionSx({\n sx: value,\n theme\n });\n } else {\n css = merge(css, breakpointsValues);\n }\n }\n } else {\n css = merge(css, getThemeValue(styleKey, value, theme, config));\n }\n }\n });\n return removeUnusedBreakpoints(breakpointsKeys, css);\n }\n return Array.isArray(sx) ? sx.map(traverse) : traverse(sx);\n }\n return styleFunctionSx;\n}\nconst styleFunctionSx = unstable_createStyleFunctionSx();\nstyleFunctionSx.filterProps = ['sx'];\nexport default styleFunctionSx;","/**\n * A universal utility to style components with multiple color modes. Always use it from the theme object.\n * It works with:\n * - [Basic theme](https://mui.com/material-ui/customization/dark-mode/)\n * - [CSS theme variables](https://mui.com/material-ui/experimental-api/css-theme-variables/overview/)\n * - Zero-runtime engine\n *\n * Tips: Use an array over object spread and place `theme.applyStyles()` last.\n *\n * ✅ [{ background: '#e5e5e5' }, theme.applyStyles('dark', { background: '#1c1c1c' })]\n *\n * 🚫 { background: '#e5e5e5', ...theme.applyStyles('dark', { background: '#1c1c1c' })}\n *\n * @example\n * 1. using with `styled`:\n * ```jsx\n * const Component = styled('div')(({ theme }) => [\n * { background: '#e5e5e5' },\n * theme.applyStyles('dark', {\n * background: '#1c1c1c',\n * color: '#fff',\n * }),\n * ]);\n * ```\n *\n * @example\n * 2. using with `sx` prop:\n * ```jsx\n * [\n * { background: '#e5e5e5' },\n * theme.applyStyles('dark', {\n * background: '#1c1c1c',\n * color: '#fff',\n * }),\n * ]}\n * />\n * ```\n *\n * @example\n * 3. theming a component:\n * ```jsx\n * extendTheme({\n * components: {\n * MuiButton: {\n * styleOverrides: {\n * root: ({ theme }) => [\n * { background: '#e5e5e5' },\n * theme.applyStyles('dark', {\n * background: '#1c1c1c',\n * color: '#fff',\n * }),\n * ],\n * },\n * }\n * }\n * })\n *```\n */\nexport default function applyStyles(key, styles) {\n // @ts-expect-error this is 'any' type\n const theme = this;\n if (theme.vars && typeof theme.getColorSchemeSelector === 'function') {\n // If CssVarsProvider is used as a provider,\n // returns '* :where([data-mui-color-scheme=\"light|dark\"]) &'\n const selector = theme.getColorSchemeSelector(key).replace(/(\\[[^\\]]+\\])/, '*:where($1)');\n return {\n [selector]: styles\n };\n }\n if (theme.palette.mode === key) {\n return styles;\n }\n return {};\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"breakpoints\", \"palette\", \"spacing\", \"shape\"];\nimport deepmerge from '@mui/utils/deepmerge';\nimport createBreakpoints from './createBreakpoints';\nimport shape from './shape';\nimport createSpacing from './createSpacing';\nimport styleFunctionSx from '../styleFunctionSx/styleFunctionSx';\nimport defaultSxConfig from '../styleFunctionSx/defaultSxConfig';\nimport applyStyles from './applyStyles';\nfunction createTheme(options = {}, ...args) {\n const {\n breakpoints: breakpointsInput = {},\n palette: paletteInput = {},\n spacing: spacingInput,\n shape: shapeInput = {}\n } = options,\n other = _objectWithoutPropertiesLoose(options, _excluded);\n const breakpoints = createBreakpoints(breakpointsInput);\n const spacing = createSpacing(spacingInput);\n let muiTheme = deepmerge({\n breakpoints,\n direction: 'ltr',\n components: {},\n // Inject component definitions.\n palette: _extends({\n mode: 'light'\n }, paletteInput),\n spacing,\n shape: _extends({}, shape, shapeInput)\n }, other);\n muiTheme.applyStyles = applyStyles;\n muiTheme = args.reduce((acc, argument) => deepmerge(acc, argument), muiTheme);\n muiTheme.unstable_sxConfig = _extends({}, defaultSxConfig, other == null ? void 0 : other.unstable_sxConfig);\n muiTheme.unstable_sx = function sx(props) {\n return styleFunctionSx({\n sx: props,\n theme: this\n });\n };\n return muiTheme;\n}\nexport default createTheme;","'use client';\n\nimport * as React from 'react';\nimport { ThemeContext } from '@mui/styled-engine';\nfunction isObjectEmpty(obj) {\n return Object.keys(obj).length === 0;\n}\nfunction useTheme(defaultTheme = null) {\n const contextTheme = React.useContext(ThemeContext);\n return !contextTheme || isObjectEmpty(contextTheme) ? defaultTheme : contextTheme;\n}\nexport default useTheme;","'use client';\n\nimport createTheme from './createTheme';\nimport useThemeWithoutDefault from './useThemeWithoutDefault';\nexport const systemDefaultTheme = createTheme();\nfunction useTheme(defaultTheme = systemDefaultTheme) {\n return useThemeWithoutDefault(defaultTheme);\n}\nexport default useTheme;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"ownerState\"],\n _excluded2 = [\"variants\"],\n _excluded3 = [\"name\", \"slot\", \"skipVariantsResolver\", \"skipSx\", \"overridesResolver\"];\n/* eslint-disable no-underscore-dangle */\nimport styledEngineStyled, { internal_processStyles as processStyles } from '@mui/styled-engine';\nimport { isPlainObject } from '@mui/utils/deepmerge';\nimport capitalize from '@mui/utils/capitalize';\nimport getDisplayName from '@mui/utils/getDisplayName';\nimport createTheme from './createTheme';\nimport styleFunctionSx from './styleFunctionSx';\nfunction isEmpty(obj) {\n return Object.keys(obj).length === 0;\n}\n\n// https://github.com/emotion-js/emotion/blob/26ded6109fcd8ca9875cc2ce4564fee678a3f3c5/packages/styled/src/utils.js#L40\nfunction isStringTag(tag) {\n return typeof tag === 'string' &&\n // 96 is one less than the char code\n // for \"a\" so this is checking that\n // it's a lowercase character\n tag.charCodeAt(0) > 96;\n}\n\n// Update /system/styled/#api in case if this changes\nexport function shouldForwardProp(prop) {\n return prop !== 'ownerState' && prop !== 'theme' && prop !== 'sx' && prop !== 'as';\n}\nexport const systemDefaultTheme = createTheme();\nconst lowercaseFirstLetter = string => {\n if (!string) {\n return string;\n }\n return string.charAt(0).toLowerCase() + string.slice(1);\n};\nfunction resolveTheme({\n defaultTheme,\n theme,\n themeId\n}) {\n return isEmpty(theme) ? defaultTheme : theme[themeId] || theme;\n}\nfunction defaultOverridesResolver(slot) {\n if (!slot) {\n return null;\n }\n return (props, styles) => styles[slot];\n}\nfunction processStyleArg(callableStyle, _ref) {\n let {\n ownerState\n } = _ref,\n props = _objectWithoutPropertiesLoose(_ref, _excluded);\n const resolvedStylesArg = typeof callableStyle === 'function' ? callableStyle(_extends({\n ownerState\n }, props)) : callableStyle;\n if (Array.isArray(resolvedStylesArg)) {\n return resolvedStylesArg.flatMap(resolvedStyle => processStyleArg(resolvedStyle, _extends({\n ownerState\n }, props)));\n }\n if (!!resolvedStylesArg && typeof resolvedStylesArg === 'object' && Array.isArray(resolvedStylesArg.variants)) {\n const {\n variants = []\n } = resolvedStylesArg,\n otherStyles = _objectWithoutPropertiesLoose(resolvedStylesArg, _excluded2);\n let result = otherStyles;\n variants.forEach(variant => {\n let isMatch = true;\n if (typeof variant.props === 'function') {\n isMatch = variant.props(_extends({\n ownerState\n }, props, ownerState));\n } else {\n Object.keys(variant.props).forEach(key => {\n if ((ownerState == null ? void 0 : ownerState[key]) !== variant.props[key] && props[key] !== variant.props[key]) {\n isMatch = false;\n }\n });\n }\n if (isMatch) {\n if (!Array.isArray(result)) {\n result = [result];\n }\n result.push(typeof variant.style === 'function' ? variant.style(_extends({\n ownerState\n }, props, ownerState)) : variant.style);\n }\n });\n return result;\n }\n return resolvedStylesArg;\n}\nexport default function createStyled(input = {}) {\n const {\n themeId,\n defaultTheme = systemDefaultTheme,\n rootShouldForwardProp = shouldForwardProp,\n slotShouldForwardProp = shouldForwardProp\n } = input;\n const systemSx = props => {\n return styleFunctionSx(_extends({}, props, {\n theme: resolveTheme(_extends({}, props, {\n defaultTheme,\n themeId\n }))\n }));\n };\n systemSx.__mui_systemSx = true;\n return (tag, inputOptions = {}) => {\n // Filter out the `sx` style function from the previous styled component to prevent unnecessary styles generated by the composite components.\n processStyles(tag, styles => styles.filter(style => !(style != null && style.__mui_systemSx)));\n const {\n name: componentName,\n slot: componentSlot,\n skipVariantsResolver: inputSkipVariantsResolver,\n skipSx: inputSkipSx,\n // TODO v6: remove `lowercaseFirstLetter()` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n overridesResolver = defaultOverridesResolver(lowercaseFirstLetter(componentSlot))\n } = inputOptions,\n options = _objectWithoutPropertiesLoose(inputOptions, _excluded3);\n\n // if skipVariantsResolver option is defined, take the value, otherwise, true for root and false for other slots.\n const skipVariantsResolver = inputSkipVariantsResolver !== undefined ? inputSkipVariantsResolver :\n // TODO v6: remove `Root` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n componentSlot && componentSlot !== 'Root' && componentSlot !== 'root' || false;\n const skipSx = inputSkipSx || false;\n let label;\n if (process.env.NODE_ENV !== 'production') {\n if (componentName) {\n // TODO v6: remove `lowercaseFirstLetter()` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n label = `${componentName}-${lowercaseFirstLetter(componentSlot || 'Root')}`;\n }\n }\n let shouldForwardPropOption = shouldForwardProp;\n\n // TODO v6: remove `Root` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n if (componentSlot === 'Root' || componentSlot === 'root') {\n shouldForwardPropOption = rootShouldForwardProp;\n } else if (componentSlot) {\n // any other slot specified\n shouldForwardPropOption = slotShouldForwardProp;\n } else if (isStringTag(tag)) {\n // for string (html) tag, preserve the behavior in emotion & styled-components.\n shouldForwardPropOption = undefined;\n }\n const defaultStyledResolver = styledEngineStyled(tag, _extends({\n shouldForwardProp: shouldForwardPropOption,\n label\n }, options));\n const transformStyleArg = stylesArg => {\n // On the server Emotion doesn't use React.forwardRef for creating components, so the created\n // component stays as a function. This condition makes sure that we do not interpolate functions\n // which are basically components used as a selectors.\n if (typeof stylesArg === 'function' && stylesArg.__emotion_real !== stylesArg || isPlainObject(stylesArg)) {\n return props => processStyleArg(stylesArg, _extends({}, props, {\n theme: resolveTheme({\n theme: props.theme,\n defaultTheme,\n themeId\n })\n }));\n }\n return stylesArg;\n };\n const muiStyledResolver = (styleArg, ...expressions) => {\n let transformedStyleArg = transformStyleArg(styleArg);\n const expressionsWithDefaultTheme = expressions ? expressions.map(transformStyleArg) : [];\n if (componentName && overridesResolver) {\n expressionsWithDefaultTheme.push(props => {\n const theme = resolveTheme(_extends({}, props, {\n defaultTheme,\n themeId\n }));\n if (!theme.components || !theme.components[componentName] || !theme.components[componentName].styleOverrides) {\n return null;\n }\n const styleOverrides = theme.components[componentName].styleOverrides;\n const resolvedStyleOverrides = {};\n // TODO: v7 remove iteration and use `resolveStyleArg(styleOverrides[slot])` directly\n Object.entries(styleOverrides).forEach(([slotKey, slotStyle]) => {\n resolvedStyleOverrides[slotKey] = processStyleArg(slotStyle, _extends({}, props, {\n theme\n }));\n });\n return overridesResolver(props, resolvedStyleOverrides);\n });\n }\n if (componentName && !skipVariantsResolver) {\n expressionsWithDefaultTheme.push(props => {\n var _theme$components;\n const theme = resolveTheme(_extends({}, props, {\n defaultTheme,\n themeId\n }));\n const themeVariants = theme == null || (_theme$components = theme.components) == null || (_theme$components = _theme$components[componentName]) == null ? void 0 : _theme$components.variants;\n return processStyleArg({\n variants: themeVariants\n }, _extends({}, props, {\n theme\n }));\n });\n }\n if (!skipSx) {\n expressionsWithDefaultTheme.push(systemSx);\n }\n const numOfCustomFnsApplied = expressionsWithDefaultTheme.length - expressions.length;\n if (Array.isArray(styleArg) && numOfCustomFnsApplied > 0) {\n const placeholders = new Array(numOfCustomFnsApplied).fill('');\n // If the type is array, than we need to add placeholders in the template for the overrides, variants and the sx styles.\n transformedStyleArg = [...styleArg, ...placeholders];\n transformedStyleArg.raw = [...styleArg.raw, ...placeholders];\n }\n const Component = defaultStyledResolver(transformedStyleArg, ...expressionsWithDefaultTheme);\n if (process.env.NODE_ENV !== 'production') {\n let displayName;\n if (componentName) {\n displayName = `${componentName}${capitalize(componentSlot || '')}`;\n }\n if (displayName === undefined) {\n displayName = `Styled(${getDisplayName(tag)})`;\n }\n Component.displayName = displayName;\n }\n if (tag.muiName) {\n Component.muiName = tag.muiName;\n }\n return Component;\n };\n if (defaultStyledResolver.withConfig) {\n muiStyledResolver.withConfig = defaultStyledResolver.withConfig;\n }\n return muiStyledResolver;\n };\n}","import resolveProps from '@mui/utils/resolveProps';\nexport default function getThemeProps(params) {\n const {\n theme,\n name,\n props\n } = params;\n if (!theme || !theme.components || !theme.components[name] || !theme.components[name].defaultProps) {\n return props;\n }\n return resolveProps(theme.components[name].defaultProps, props);\n}","'use client';\n\nimport getThemeProps from './getThemeProps';\nimport useTheme from '../useTheme';\nexport default function useThemeProps({\n props,\n name,\n defaultTheme,\n themeId\n}) {\n let theme = useTheme(defaultTheme);\n if (themeId) {\n theme = theme[themeId] || theme;\n }\n const mergedProps = getThemeProps({\n theme,\n name,\n props\n });\n return mergedProps;\n}","import _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\n/* eslint-disable @typescript-eslint/naming-convention */\nimport clamp from '@mui/utils/clamp';\n/**\n * Returns a number whose value is limited to the given range.\n * @param {number} value The value to be clamped\n * @param {number} min The lower boundary of the output range\n * @param {number} max The upper boundary of the output range\n * @returns {number} A number in the range [min, max]\n */\nfunction clampWrapper(value, min = 0, max = 1) {\n if (process.env.NODE_ENV !== 'production') {\n if (value < min || value > max) {\n console.error(`MUI: The value provided ${value} is out of range [${min}, ${max}].`);\n }\n }\n return clamp(value, min, max);\n}\n\n/**\n * Converts a color from CSS hex format to CSS rgb format.\n * @param {string} color - Hex color, i.e. #nnn or #nnnnnn\n * @returns {string} A CSS rgb color string\n */\nexport function hexToRgb(color) {\n color = color.slice(1);\n const re = new RegExp(`.{1,${color.length >= 6 ? 2 : 1}}`, 'g');\n let colors = color.match(re);\n if (colors && colors[0].length === 1) {\n colors = colors.map(n => n + n);\n }\n return colors ? `rgb${colors.length === 4 ? 'a' : ''}(${colors.map((n, index) => {\n return index < 3 ? parseInt(n, 16) : Math.round(parseInt(n, 16) / 255 * 1000) / 1000;\n }).join(', ')})` : '';\n}\nfunction intToHex(int) {\n const hex = int.toString(16);\n return hex.length === 1 ? `0${hex}` : hex;\n}\n\n/**\n * Returns an object with the type and values of a color.\n *\n * Note: Does not support rgb % values.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @returns {object} - A MUI color object: {type: string, values: number[]}\n */\nexport function decomposeColor(color) {\n // Idempotent\n if (color.type) {\n return color;\n }\n if (color.charAt(0) === '#') {\n return decomposeColor(hexToRgb(color));\n }\n const marker = color.indexOf('(');\n const type = color.substring(0, marker);\n if (['rgb', 'rgba', 'hsl', 'hsla', 'color'].indexOf(type) === -1) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: Unsupported \\`${color}\\` color.\nThe following formats are supported: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color().` : _formatMuiErrorMessage(9, color));\n }\n let values = color.substring(marker + 1, color.length - 1);\n let colorSpace;\n if (type === 'color') {\n values = values.split(' ');\n colorSpace = values.shift();\n if (values.length === 4 && values[3].charAt(0) === '/') {\n values[3] = values[3].slice(1);\n }\n if (['srgb', 'display-p3', 'a98-rgb', 'prophoto-rgb', 'rec-2020'].indexOf(colorSpace) === -1) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: unsupported \\`${colorSpace}\\` color space.\nThe following color spaces are supported: srgb, display-p3, a98-rgb, prophoto-rgb, rec-2020.` : _formatMuiErrorMessage(10, colorSpace));\n }\n } else {\n values = values.split(',');\n }\n values = values.map(value => parseFloat(value));\n return {\n type,\n values,\n colorSpace\n };\n}\n\n/**\n * Returns a channel created from the input color.\n *\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @returns {string} - The channel for the color, that can be used in rgba or hsla colors\n */\nexport const colorChannel = color => {\n const decomposedColor = decomposeColor(color);\n return decomposedColor.values.slice(0, 3).map((val, idx) => decomposedColor.type.indexOf('hsl') !== -1 && idx !== 0 ? `${val}%` : val).join(' ');\n};\nexport const private_safeColorChannel = (color, warning) => {\n try {\n return colorChannel(color);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n};\n\n/**\n * Converts a color object with type and values to a string.\n * @param {object} color - Decomposed color\n * @param {string} color.type - One of: 'rgb', 'rgba', 'hsl', 'hsla', 'color'\n * @param {array} color.values - [n,n,n] or [n,n,n,n]\n * @returns {string} A CSS color string\n */\nexport function recomposeColor(color) {\n const {\n type,\n colorSpace\n } = color;\n let {\n values\n } = color;\n if (type.indexOf('rgb') !== -1) {\n // Only convert the first 3 values to int (i.e. not alpha)\n values = values.map((n, i) => i < 3 ? parseInt(n, 10) : n);\n } else if (type.indexOf('hsl') !== -1) {\n values[1] = `${values[1]}%`;\n values[2] = `${values[2]}%`;\n }\n if (type.indexOf('color') !== -1) {\n values = `${colorSpace} ${values.join(' ')}`;\n } else {\n values = `${values.join(', ')}`;\n }\n return `${type}(${values})`;\n}\n\n/**\n * Converts a color from CSS rgb format to CSS hex format.\n * @param {string} color - RGB color, i.e. rgb(n, n, n)\n * @returns {string} A CSS rgb color string, i.e. #nnnnnn\n */\nexport function rgbToHex(color) {\n // Idempotent\n if (color.indexOf('#') === 0) {\n return color;\n }\n const {\n values\n } = decomposeColor(color);\n return `#${values.map((n, i) => intToHex(i === 3 ? Math.round(255 * n) : n)).join('')}`;\n}\n\n/**\n * Converts a color from hsl format to rgb format.\n * @param {string} color - HSL color values\n * @returns {string} rgb color values\n */\nexport function hslToRgb(color) {\n color = decomposeColor(color);\n const {\n values\n } = color;\n const h = values[0];\n const s = values[1] / 100;\n const l = values[2] / 100;\n const a = s * Math.min(l, 1 - l);\n const f = (n, k = (n + h / 30) % 12) => l - a * Math.max(Math.min(k - 3, 9 - k, 1), -1);\n let type = 'rgb';\n const rgb = [Math.round(f(0) * 255), Math.round(f(8) * 255), Math.round(f(4) * 255)];\n if (color.type === 'hsla') {\n type += 'a';\n rgb.push(values[3]);\n }\n return recomposeColor({\n type,\n values: rgb\n });\n}\n/**\n * The relative brightness of any point in a color space,\n * normalized to 0 for darkest black and 1 for lightest white.\n *\n * Formula: https://www.w3.org/TR/WCAG20-TECHS/G17.html#G17-tests\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @returns {number} The relative brightness of the color in the range 0 - 1\n */\nexport function getLuminance(color) {\n color = decomposeColor(color);\n let rgb = color.type === 'hsl' || color.type === 'hsla' ? decomposeColor(hslToRgb(color)).values : color.values;\n rgb = rgb.map(val => {\n if (color.type !== 'color') {\n val /= 255; // normalized\n }\n return val <= 0.03928 ? val / 12.92 : ((val + 0.055) / 1.055) ** 2.4;\n });\n\n // Truncate at 3 digits\n return Number((0.2126 * rgb[0] + 0.7152 * rgb[1] + 0.0722 * rgb[2]).toFixed(3));\n}\n\n/**\n * Calculates the contrast ratio between two colors.\n *\n * Formula: https://www.w3.org/TR/WCAG20-TECHS/G17.html#G17-tests\n * @param {string} foreground - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla()\n * @param {string} background - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla()\n * @returns {number} A contrast ratio value in the range 0 - 21.\n */\nexport function getContrastRatio(foreground, background) {\n const lumA = getLuminance(foreground);\n const lumB = getLuminance(background);\n return (Math.max(lumA, lumB) + 0.05) / (Math.min(lumA, lumB) + 0.05);\n}\n\n/**\n * Sets the absolute transparency of a color.\n * Any existing alpha values are overwritten.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} value - value to set the alpha channel to in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function alpha(color, value) {\n color = decomposeColor(color);\n value = clampWrapper(value);\n if (color.type === 'rgb' || color.type === 'hsl') {\n color.type += 'a';\n }\n if (color.type === 'color') {\n color.values[3] = `/${value}`;\n } else {\n color.values[3] = value;\n }\n return recomposeColor(color);\n}\nexport function private_safeAlpha(color, value, warning) {\n try {\n return alpha(color, value);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Darkens a color.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} coefficient - multiplier in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function darken(color, coefficient) {\n color = decomposeColor(color);\n coefficient = clampWrapper(coefficient);\n if (color.type.indexOf('hsl') !== -1) {\n color.values[2] *= 1 - coefficient;\n } else if (color.type.indexOf('rgb') !== -1 || color.type.indexOf('color') !== -1) {\n for (let i = 0; i < 3; i += 1) {\n color.values[i] *= 1 - coefficient;\n }\n }\n return recomposeColor(color);\n}\nexport function private_safeDarken(color, coefficient, warning) {\n try {\n return darken(color, coefficient);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Lightens a color.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} coefficient - multiplier in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function lighten(color, coefficient) {\n color = decomposeColor(color);\n coefficient = clampWrapper(coefficient);\n if (color.type.indexOf('hsl') !== -1) {\n color.values[2] += (100 - color.values[2]) * coefficient;\n } else if (color.type.indexOf('rgb') !== -1) {\n for (let i = 0; i < 3; i += 1) {\n color.values[i] += (255 - color.values[i]) * coefficient;\n }\n } else if (color.type.indexOf('color') !== -1) {\n for (let i = 0; i < 3; i += 1) {\n color.values[i] += (1 - color.values[i]) * coefficient;\n }\n }\n return recomposeColor(color);\n}\nexport function private_safeLighten(color, coefficient, warning) {\n try {\n return lighten(color, coefficient);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Darken or lighten a color, depending on its luminance.\n * Light colors are darkened, dark colors are lightened.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} coefficient=0.15 - multiplier in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function emphasize(color, coefficient = 0.15) {\n return getLuminance(color) > 0.5 ? darken(color, coefficient) : lighten(color, coefficient);\n}\nexport function private_safeEmphasize(color, coefficient, warning) {\n try {\n return emphasize(color, coefficient);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Blend a transparent overlay color with a background color, resulting in a single\n * RGB color.\n * @param {string} background - CSS color\n * @param {string} overlay - CSS color\n * @param {number} opacity - Opacity multiplier in the range 0 - 1\n * @param {number} [gamma=1.0] - Gamma correction factor. For gamma-correct blending, 2.2 is usual.\n */\nexport function blend(background, overlay, opacity, gamma = 1.0) {\n const blendChannel = (b, o) => Math.round((b ** (1 / gamma) * (1 - opacity) + o ** (1 / gamma) * opacity) ** gamma);\n const backgroundColor = decomposeColor(background);\n const overlayColor = decomposeColor(overlay);\n const rgb = [blendChannel(backgroundColor.values[0], overlayColor.values[0]), blendChannel(backgroundColor.values[1], overlayColor.values[1]), blendChannel(backgroundColor.values[2], overlayColor.values[2])];\n return recomposeColor({\n type: 'rgb',\n values: rgb\n });\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nexport default function createMixins(breakpoints, mixins) {\n return _extends({\n toolbar: {\n minHeight: 56,\n [breakpoints.up('xs')]: {\n '@media (orientation: landscape)': {\n minHeight: 48\n }\n },\n [breakpoints.up('sm')]: {\n minHeight: 64\n }\n }\n }, mixins);\n}","const common = {\n black: '#000',\n white: '#fff'\n};\nexport default common;","const grey = {\n 50: '#fafafa',\n 100: '#f5f5f5',\n 200: '#eeeeee',\n 300: '#e0e0e0',\n 400: '#bdbdbd',\n 500: '#9e9e9e',\n 600: '#757575',\n 700: '#616161',\n 800: '#424242',\n 900: '#212121',\n A100: '#f5f5f5',\n A200: '#eeeeee',\n A400: '#bdbdbd',\n A700: '#616161'\n};\nexport default grey;","const purple = {\n 50: '#f3e5f5',\n 100: '#e1bee7',\n 200: '#ce93d8',\n 300: '#ba68c8',\n 400: '#ab47bc',\n 500: '#9c27b0',\n 600: '#8e24aa',\n 700: '#7b1fa2',\n 800: '#6a1b9a',\n 900: '#4a148c',\n A100: '#ea80fc',\n A200: '#e040fb',\n A400: '#d500f9',\n A700: '#aa00ff'\n};\nexport default purple;","const red = {\n 50: '#ffebee',\n 100: '#ffcdd2',\n 200: '#ef9a9a',\n 300: '#e57373',\n 400: '#ef5350',\n 500: '#f44336',\n 600: '#e53935',\n 700: '#d32f2f',\n 800: '#c62828',\n 900: '#b71c1c',\n A100: '#ff8a80',\n A200: '#ff5252',\n A400: '#ff1744',\n A700: '#d50000'\n};\nexport default red;","const orange = {\n 50: '#fff3e0',\n 100: '#ffe0b2',\n 200: '#ffcc80',\n 300: '#ffb74d',\n 400: '#ffa726',\n 500: '#ff9800',\n 600: '#fb8c00',\n 700: '#f57c00',\n 800: '#ef6c00',\n 900: '#e65100',\n A100: '#ffd180',\n A200: '#ffab40',\n A400: '#ff9100',\n A700: '#ff6d00'\n};\nexport default orange;","const blue = {\n 50: '#e3f2fd',\n 100: '#bbdefb',\n 200: '#90caf9',\n 300: '#64b5f6',\n 400: '#42a5f5',\n 500: '#2196f3',\n 600: '#1e88e5',\n 700: '#1976d2',\n 800: '#1565c0',\n 900: '#0d47a1',\n A100: '#82b1ff',\n A200: '#448aff',\n A400: '#2979ff',\n A700: '#2962ff'\n};\nexport default blue;","const lightBlue = {\n 50: '#e1f5fe',\n 100: '#b3e5fc',\n 200: '#81d4fa',\n 300: '#4fc3f7',\n 400: '#29b6f6',\n 500: '#03a9f4',\n 600: '#039be5',\n 700: '#0288d1',\n 800: '#0277bd',\n 900: '#01579b',\n A100: '#80d8ff',\n A200: '#40c4ff',\n A400: '#00b0ff',\n A700: '#0091ea'\n};\nexport default lightBlue;","const green = {\n 50: '#e8f5e9',\n 100: '#c8e6c9',\n 200: '#a5d6a7',\n 300: '#81c784',\n 400: '#66bb6a',\n 500: '#4caf50',\n 600: '#43a047',\n 700: '#388e3c',\n 800: '#2e7d32',\n 900: '#1b5e20',\n A100: '#b9f6ca',\n A200: '#69f0ae',\n A400: '#00e676',\n A700: '#00c853'\n};\nexport default green;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\nconst _excluded = [\"mode\", \"contrastThreshold\", \"tonalOffset\"];\nimport { deepmerge } from '@mui/utils';\nimport { darken, getContrastRatio, lighten } from '@mui/system';\nimport common from '../colors/common';\nimport grey from '../colors/grey';\nimport purple from '../colors/purple';\nimport red from '../colors/red';\nimport orange from '../colors/orange';\nimport blue from '../colors/blue';\nimport lightBlue from '../colors/lightBlue';\nimport green from '../colors/green';\nexport const light = {\n // The colors used to style the text.\n text: {\n // The most important text.\n primary: 'rgba(0, 0, 0, 0.87)',\n // Secondary text.\n secondary: 'rgba(0, 0, 0, 0.6)',\n // Disabled text have even lower visual prominence.\n disabled: 'rgba(0, 0, 0, 0.38)'\n },\n // The color used to divide different elements.\n divider: 'rgba(0, 0, 0, 0.12)',\n // The background colors used to style the surfaces.\n // Consistency between these values is important.\n background: {\n paper: common.white,\n default: common.white\n },\n // The colors used to style the action elements.\n action: {\n // The color of an active action like an icon button.\n active: 'rgba(0, 0, 0, 0.54)',\n // The color of an hovered action.\n hover: 'rgba(0, 0, 0, 0.04)',\n hoverOpacity: 0.04,\n // The color of a selected action.\n selected: 'rgba(0, 0, 0, 0.08)',\n selectedOpacity: 0.08,\n // The color of a disabled action.\n disabled: 'rgba(0, 0, 0, 0.26)',\n // The background color of a disabled action.\n disabledBackground: 'rgba(0, 0, 0, 0.12)',\n disabledOpacity: 0.38,\n focus: 'rgba(0, 0, 0, 0.12)',\n focusOpacity: 0.12,\n activatedOpacity: 0.12\n }\n};\nexport const dark = {\n text: {\n primary: common.white,\n secondary: 'rgba(255, 255, 255, 0.7)',\n disabled: 'rgba(255, 255, 255, 0.5)',\n icon: 'rgba(255, 255, 255, 0.5)'\n },\n divider: 'rgba(255, 255, 255, 0.12)',\n background: {\n paper: '#121212',\n default: '#121212'\n },\n action: {\n active: common.white,\n hover: 'rgba(255, 255, 255, 0.08)',\n hoverOpacity: 0.08,\n selected: 'rgba(255, 255, 255, 0.16)',\n selectedOpacity: 0.16,\n disabled: 'rgba(255, 255, 255, 0.3)',\n disabledBackground: 'rgba(255, 255, 255, 0.12)',\n disabledOpacity: 0.38,\n focus: 'rgba(255, 255, 255, 0.12)',\n focusOpacity: 0.12,\n activatedOpacity: 0.24\n }\n};\nfunction addLightOrDark(intent, direction, shade, tonalOffset) {\n const tonalOffsetLight = tonalOffset.light || tonalOffset;\n const tonalOffsetDark = tonalOffset.dark || tonalOffset * 1.5;\n if (!intent[direction]) {\n if (intent.hasOwnProperty(shade)) {\n intent[direction] = intent[shade];\n } else if (direction === 'light') {\n intent.light = lighten(intent.main, tonalOffsetLight);\n } else if (direction === 'dark') {\n intent.dark = darken(intent.main, tonalOffsetDark);\n }\n }\n}\nfunction getDefaultPrimary(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: blue[200],\n light: blue[50],\n dark: blue[400]\n };\n }\n return {\n main: blue[700],\n light: blue[400],\n dark: blue[800]\n };\n}\nfunction getDefaultSecondary(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: purple[200],\n light: purple[50],\n dark: purple[400]\n };\n }\n return {\n main: purple[500],\n light: purple[300],\n dark: purple[700]\n };\n}\nfunction getDefaultError(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: red[500],\n light: red[300],\n dark: red[700]\n };\n }\n return {\n main: red[700],\n light: red[400],\n dark: red[800]\n };\n}\nfunction getDefaultInfo(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: lightBlue[400],\n light: lightBlue[300],\n dark: lightBlue[700]\n };\n }\n return {\n main: lightBlue[700],\n light: lightBlue[500],\n dark: lightBlue[900]\n };\n}\nfunction getDefaultSuccess(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: green[400],\n light: green[300],\n dark: green[700]\n };\n }\n return {\n main: green[800],\n light: green[500],\n dark: green[900]\n };\n}\nfunction getDefaultWarning(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: orange[400],\n light: orange[300],\n dark: orange[700]\n };\n }\n return {\n main: '#ed6c02',\n // closest to orange[800] that pass 3:1.\n light: orange[500],\n dark: orange[900]\n };\n}\nexport default function createPalette(palette) {\n const {\n mode = 'light',\n contrastThreshold = 3,\n tonalOffset = 0.2\n } = palette,\n other = _objectWithoutPropertiesLoose(palette, _excluded);\n const primary = palette.primary || getDefaultPrimary(mode);\n const secondary = palette.secondary || getDefaultSecondary(mode);\n const error = palette.error || getDefaultError(mode);\n const info = palette.info || getDefaultInfo(mode);\n const success = palette.success || getDefaultSuccess(mode);\n const warning = palette.warning || getDefaultWarning(mode);\n\n // Use the same logic as\n // Bootstrap: https://github.com/twbs/bootstrap/blob/1d6e3710dd447de1a200f29e8fa521f8a0908f70/scss/_functions.scss#L59\n // and material-components-web https://github.com/material-components/material-components-web/blob/ac46b8863c4dab9fc22c4c662dc6bd1b65dd652f/packages/mdc-theme/_functions.scss#L54\n function getContrastText(background) {\n const contrastText = getContrastRatio(background, dark.text.primary) >= contrastThreshold ? dark.text.primary : light.text.primary;\n if (process.env.NODE_ENV !== 'production') {\n const contrast = getContrastRatio(background, contrastText);\n if (contrast < 3) {\n console.error([`MUI: The contrast ratio of ${contrast}:1 for ${contrastText} on ${background}`, 'falls below the WCAG recommended absolute minimum contrast ratio of 3:1.', 'https://www.w3.org/TR/2008/REC-WCAG20-20081211/#visual-audio-contrast-contrast'].join('\\n'));\n }\n }\n return contrastText;\n }\n const augmentColor = ({\n color,\n name,\n mainShade = 500,\n lightShade = 300,\n darkShade = 700\n }) => {\n color = _extends({}, color);\n if (!color.main && color[mainShade]) {\n color.main = color[mainShade];\n }\n if (!color.hasOwnProperty('main')) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: The color${name ? ` (${name})` : ''} provided to augmentColor(color) is invalid.\nThe color object needs to have a \\`main\\` property or a \\`${mainShade}\\` property.` : _formatMuiErrorMessage(11, name ? ` (${name})` : '', mainShade));\n }\n if (typeof color.main !== 'string') {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: The color${name ? ` (${name})` : ''} provided to augmentColor(color) is invalid.\n\\`color.main\\` should be a string, but \\`${JSON.stringify(color.main)}\\` was provided instead.\n\nDid you intend to use one of the following approaches?\n\nimport { green } from \"@mui/material/colors\";\n\nconst theme1 = createTheme({ palette: {\n primary: green,\n} });\n\nconst theme2 = createTheme({ palette: {\n primary: { main: green[500] },\n} });` : _formatMuiErrorMessage(12, name ? ` (${name})` : '', JSON.stringify(color.main)));\n }\n addLightOrDark(color, 'light', lightShade, tonalOffset);\n addLightOrDark(color, 'dark', darkShade, tonalOffset);\n if (!color.contrastText) {\n color.contrastText = getContrastText(color.main);\n }\n return color;\n };\n const modes = {\n dark,\n light\n };\n if (process.env.NODE_ENV !== 'production') {\n if (!modes[mode]) {\n console.error(`MUI: The palette mode \\`${mode}\\` is not supported.`);\n }\n }\n const paletteOutput = deepmerge(_extends({\n // A collection of common colors.\n common: _extends({}, common),\n // prevent mutable object.\n // The palette mode, can be light or dark.\n mode,\n // The colors used to represent primary interface elements for a user.\n primary: augmentColor({\n color: primary,\n name: 'primary'\n }),\n // The colors used to represent secondary interface elements for a user.\n secondary: augmentColor({\n color: secondary,\n name: 'secondary',\n mainShade: 'A400',\n lightShade: 'A200',\n darkShade: 'A700'\n }),\n // The colors used to represent interface elements that the user should be made aware of.\n error: augmentColor({\n color: error,\n name: 'error'\n }),\n // The colors used to represent potentially dangerous actions or important messages.\n warning: augmentColor({\n color: warning,\n name: 'warning'\n }),\n // The colors used to present information to the user that is neutral and not necessarily important.\n info: augmentColor({\n color: info,\n name: 'info'\n }),\n // The colors used to indicate the successful completion of an action that user triggered.\n success: augmentColor({\n color: success,\n name: 'success'\n }),\n // The grey colors.\n grey,\n // Used by `getContrastText()` to maximize the contrast between\n // the background and the text.\n contrastThreshold,\n // Takes a background color and returns the text color that maximizes the contrast.\n getContrastText,\n // Generate a rich color object.\n augmentColor,\n // Used by the functions below to shift a color's luminance by approximately\n // two indexes within its tonal palette.\n // E.g., shift from Red 500 to Red 300 or Red 700.\n tonalOffset\n }, modes[mode]), other);\n return paletteOutput;\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"fontFamily\", \"fontSize\", \"fontWeightLight\", \"fontWeightRegular\", \"fontWeightMedium\", \"fontWeightBold\", \"htmlFontSize\", \"allVariants\", \"pxToRem\"];\nimport { deepmerge } from '@mui/utils';\nfunction round(value) {\n return Math.round(value * 1e5) / 1e5;\n}\nconst caseAllCaps = {\n textTransform: 'uppercase'\n};\nconst defaultFontFamily = '\"Roboto\", \"Helvetica\", \"Arial\", sans-serif';\n\n/**\n * @see @link{https://m2.material.io/design/typography/the-type-system.html}\n * @see @link{https://m2.material.io/design/typography/understanding-typography.html}\n */\nexport default function createTypography(palette, typography) {\n const _ref = typeof typography === 'function' ? typography(palette) : typography,\n {\n fontFamily = defaultFontFamily,\n // The default font size of the Material Specification.\n fontSize = 14,\n // px\n fontWeightLight = 300,\n fontWeightRegular = 400,\n fontWeightMedium = 500,\n fontWeightBold = 700,\n // Tell MUI what's the font-size on the html element.\n // 16px is the default font-size used by browsers.\n htmlFontSize = 16,\n // Apply the CSS properties to all the variants.\n allVariants,\n pxToRem: pxToRem2\n } = _ref,\n other = _objectWithoutPropertiesLoose(_ref, _excluded);\n if (process.env.NODE_ENV !== 'production') {\n if (typeof fontSize !== 'number') {\n console.error('MUI: `fontSize` is required to be a number.');\n }\n if (typeof htmlFontSize !== 'number') {\n console.error('MUI: `htmlFontSize` is required to be a number.');\n }\n }\n const coef = fontSize / 14;\n const pxToRem = pxToRem2 || (size => `${size / htmlFontSize * coef}rem`);\n const buildVariant = (fontWeight, size, lineHeight, letterSpacing, casing) => _extends({\n fontFamily,\n fontWeight,\n fontSize: pxToRem(size),\n // Unitless following https://meyerweb.com/eric/thoughts/2006/02/08/unitless-line-heights/\n lineHeight\n }, fontFamily === defaultFontFamily ? {\n letterSpacing: `${round(letterSpacing / size)}em`\n } : {}, casing, allVariants);\n const variants = {\n h1: buildVariant(fontWeightLight, 96, 1.167, -1.5),\n h2: buildVariant(fontWeightLight, 60, 1.2, -0.5),\n h3: buildVariant(fontWeightRegular, 48, 1.167, 0),\n h4: buildVariant(fontWeightRegular, 34, 1.235, 0.25),\n h5: buildVariant(fontWeightRegular, 24, 1.334, 0),\n h6: buildVariant(fontWeightMedium, 20, 1.6, 0.15),\n subtitle1: buildVariant(fontWeightRegular, 16, 1.75, 0.15),\n subtitle2: buildVariant(fontWeightMedium, 14, 1.57, 0.1),\n body1: buildVariant(fontWeightRegular, 16, 1.5, 0.15),\n body2: buildVariant(fontWeightRegular, 14, 1.43, 0.15),\n button: buildVariant(fontWeightMedium, 14, 1.75, 0.4, caseAllCaps),\n caption: buildVariant(fontWeightRegular, 12, 1.66, 0.4),\n overline: buildVariant(fontWeightRegular, 12, 2.66, 1, caseAllCaps),\n // TODO v6: Remove handling of 'inherit' variant from the theme as it is already handled in Material UI's Typography component. Also, remember to remove the associated types.\n inherit: {\n fontFamily: 'inherit',\n fontWeight: 'inherit',\n fontSize: 'inherit',\n lineHeight: 'inherit',\n letterSpacing: 'inherit'\n }\n };\n return deepmerge(_extends({\n htmlFontSize,\n pxToRem,\n fontFamily,\n fontSize,\n fontWeightLight,\n fontWeightRegular,\n fontWeightMedium,\n fontWeightBold\n }, variants), other, {\n clone: false // No need to clone deep\n });\n}","const shadowKeyUmbraOpacity = 0.2;\nconst shadowKeyPenumbraOpacity = 0.14;\nconst shadowAmbientShadowOpacity = 0.12;\nfunction createShadow(...px) {\n return [`${px[0]}px ${px[1]}px ${px[2]}px ${px[3]}px rgba(0,0,0,${shadowKeyUmbraOpacity})`, `${px[4]}px ${px[5]}px ${px[6]}px ${px[7]}px rgba(0,0,0,${shadowKeyPenumbraOpacity})`, `${px[8]}px ${px[9]}px ${px[10]}px ${px[11]}px rgba(0,0,0,${shadowAmbientShadowOpacity})`].join(',');\n}\n\n// Values from https://github.com/material-components/material-components-web/blob/be8747f94574669cb5e7add1a7c54fa41a89cec7/packages/mdc-elevation/_variables.scss\nconst shadows = ['none', createShadow(0, 2, 1, -1, 0, 1, 1, 0, 0, 1, 3, 0), createShadow(0, 3, 1, -2, 0, 2, 2, 0, 0, 1, 5, 0), createShadow(0, 3, 3, -2, 0, 3, 4, 0, 0, 1, 8, 0), createShadow(0, 2, 4, -1, 0, 4, 5, 0, 0, 1, 10, 0), createShadow(0, 3, 5, -1, 0, 5, 8, 0, 0, 1, 14, 0), createShadow(0, 3, 5, -1, 0, 6, 10, 0, 0, 1, 18, 0), createShadow(0, 4, 5, -2, 0, 7, 10, 1, 0, 2, 16, 1), createShadow(0, 5, 5, -3, 0, 8, 10, 1, 0, 3, 14, 2), createShadow(0, 5, 6, -3, 0, 9, 12, 1, 0, 3, 16, 2), createShadow(0, 6, 6, -3, 0, 10, 14, 1, 0, 4, 18, 3), createShadow(0, 6, 7, -4, 0, 11, 15, 1, 0, 4, 20, 3), createShadow(0, 7, 8, -4, 0, 12, 17, 2, 0, 5, 22, 4), createShadow(0, 7, 8, -4, 0, 13, 19, 2, 0, 5, 24, 4), createShadow(0, 7, 9, -4, 0, 14, 21, 2, 0, 5, 26, 4), createShadow(0, 8, 9, -5, 0, 15, 22, 2, 0, 6, 28, 5), createShadow(0, 8, 10, -5, 0, 16, 24, 2, 0, 6, 30, 5), createShadow(0, 8, 11, -5, 0, 17, 26, 2, 0, 6, 32, 5), createShadow(0, 9, 11, -5, 0, 18, 28, 2, 0, 7, 34, 6), createShadow(0, 9, 12, -6, 0, 19, 29, 2, 0, 7, 36, 6), createShadow(0, 10, 13, -6, 0, 20, 31, 3, 0, 8, 38, 7), createShadow(0, 10, 13, -6, 0, 21, 33, 3, 0, 8, 40, 7), createShadow(0, 10, 14, -6, 0, 22, 35, 3, 0, 8, 42, 7), createShadow(0, 11, 14, -7, 0, 23, 36, 3, 0, 9, 44, 8), createShadow(0, 11, 15, -7, 0, 24, 38, 3, 0, 9, 46, 8)];\nexport default shadows;","import _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nconst _excluded = [\"duration\", \"easing\", \"delay\"];\n// Follow https://material.google.com/motion/duration-easing.html#duration-easing-natural-easing-curves\n// to learn the context in which each easing should be used.\nexport const easing = {\n // This is the most common easing curve.\n easeInOut: 'cubic-bezier(0.4, 0, 0.2, 1)',\n // Objects enter the screen at full velocity from off-screen and\n // slowly decelerate to a resting point.\n easeOut: 'cubic-bezier(0.0, 0, 0.2, 1)',\n // Objects leave the screen at full velocity. They do not decelerate when off-screen.\n easeIn: 'cubic-bezier(0.4, 0, 1, 1)',\n // The sharp curve is used by objects that may return to the screen at any time.\n sharp: 'cubic-bezier(0.4, 0, 0.6, 1)'\n};\n\n// Follow https://m2.material.io/guidelines/motion/duration-easing.html#duration-easing-common-durations\n// to learn when use what timing\nexport const duration = {\n shortest: 150,\n shorter: 200,\n short: 250,\n // most basic recommended timing\n standard: 300,\n // this is to be used in complex animations\n complex: 375,\n // recommended when something is entering screen\n enteringScreen: 225,\n // recommended when something is leaving screen\n leavingScreen: 195\n};\nfunction formatMs(milliseconds) {\n return `${Math.round(milliseconds)}ms`;\n}\nfunction getAutoHeightDuration(height) {\n if (!height) {\n return 0;\n }\n const constant = height / 36;\n\n // https://www.wolframalpha.com/input/?i=(4+%2B+15+*+(x+%2F+36+)+**+0.25+%2B+(x+%2F+36)+%2F+5)+*+10\n return Math.round((4 + 15 * constant ** 0.25 + constant / 5) * 10);\n}\nexport default function createTransitions(inputTransitions) {\n const mergedEasing = _extends({}, easing, inputTransitions.easing);\n const mergedDuration = _extends({}, duration, inputTransitions.duration);\n const create = (props = ['all'], options = {}) => {\n const {\n duration: durationOption = mergedDuration.standard,\n easing: easingOption = mergedEasing.easeInOut,\n delay = 0\n } = options,\n other = _objectWithoutPropertiesLoose(options, _excluded);\n if (process.env.NODE_ENV !== 'production') {\n const isString = value => typeof value === 'string';\n // IE11 support, replace with Number.isNaN\n // eslint-disable-next-line no-restricted-globals\n const isNumber = value => !isNaN(parseFloat(value));\n if (!isString(props) && !Array.isArray(props)) {\n console.error('MUI: Argument \"props\" must be a string or Array.');\n }\n if (!isNumber(durationOption) && !isString(durationOption)) {\n console.error(`MUI: Argument \"duration\" must be a number or a string but found ${durationOption}.`);\n }\n if (!isString(easingOption)) {\n console.error('MUI: Argument \"easing\" must be a string.');\n }\n if (!isNumber(delay) && !isString(delay)) {\n console.error('MUI: Argument \"delay\" must be a number or a string.');\n }\n if (typeof options !== 'object') {\n console.error(['MUI: Secong argument of transition.create must be an object.', \"Arguments should be either `create('prop1', options)` or `create(['prop1', 'prop2'], options)`\"].join('\\n'));\n }\n if (Object.keys(other).length !== 0) {\n console.error(`MUI: Unrecognized argument(s) [${Object.keys(other).join(',')}].`);\n }\n }\n return (Array.isArray(props) ? props : [props]).map(animatedProp => `${animatedProp} ${typeof durationOption === 'string' ? durationOption : formatMs(durationOption)} ${easingOption} ${typeof delay === 'string' ? delay : formatMs(delay)}`).join(',');\n };\n return _extends({\n getAutoHeightDuration,\n create\n }, inputTransitions, {\n easing: mergedEasing,\n duration: mergedDuration\n });\n}","// We need to centralize the zIndex definitions as they work\n// like global values in the browser.\nconst zIndex = {\n mobileStepper: 1000,\n fab: 1050,\n speedDial: 1050,\n appBar: 1100,\n drawer: 1200,\n modal: 1300,\n snackbar: 1400,\n tooltip: 1500\n};\nexport default zIndex;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\nconst _excluded = [\"breakpoints\", \"mixins\", \"spacing\", \"palette\", \"transitions\", \"typography\", \"shape\"];\nimport { deepmerge } from '@mui/utils';\nimport { createTheme as systemCreateTheme, unstable_defaultSxConfig as defaultSxConfig, unstable_styleFunctionSx as styleFunctionSx } from '@mui/system';\nimport generateUtilityClass from '@mui/utils/generateUtilityClass';\nimport createMixins from './createMixins';\nimport createPalette from './createPalette';\nimport createTypography from './createTypography';\nimport shadows from './shadows';\nimport createTransitions from './createTransitions';\nimport zIndex from './zIndex';\nfunction createTheme(options = {}, ...args) {\n const {\n mixins: mixinsInput = {},\n palette: paletteInput = {},\n transitions: transitionsInput = {},\n typography: typographyInput = {}\n } = options,\n other = _objectWithoutPropertiesLoose(options, _excluded);\n if (options.vars) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: \\`vars\\` is a private field used for CSS variables support.\nPlease use another name.` : _formatMuiErrorMessage(18));\n }\n const palette = createPalette(paletteInput);\n const systemTheme = systemCreateTheme(options);\n let muiTheme = deepmerge(systemTheme, {\n mixins: createMixins(systemTheme.breakpoints, mixinsInput),\n palette,\n // Don't use [...shadows] until you've verified its transpiled code is not invoking the iterator protocol.\n shadows: shadows.slice(),\n typography: createTypography(palette, typographyInput),\n transitions: createTransitions(transitionsInput),\n zIndex: _extends({}, zIndex)\n });\n muiTheme = deepmerge(muiTheme, other);\n muiTheme = args.reduce((acc, argument) => deepmerge(acc, argument), muiTheme);\n if (process.env.NODE_ENV !== 'production') {\n // TODO v6: Refactor to use globalStateClassesMapping from @mui/utils once `readOnly` state class is used in Rating component.\n const stateClasses = ['active', 'checked', 'completed', 'disabled', 'error', 'expanded', 'focused', 'focusVisible', 'required', 'selected'];\n const traverse = (node, component) => {\n let key;\n\n // eslint-disable-next-line guard-for-in, no-restricted-syntax\n for (key in node) {\n const child = node[key];\n if (stateClasses.indexOf(key) !== -1 && Object.keys(child).length > 0) {\n if (process.env.NODE_ENV !== 'production') {\n const stateClass = generateUtilityClass('', key);\n console.error([`MUI: The \\`${component}\\` component increases ` + `the CSS specificity of the \\`${key}\\` internal state.`, 'You can not override it like this: ', JSON.stringify(node, null, 2), '', `Instead, you need to use the '&.${stateClass}' syntax:`, JSON.stringify({\n root: {\n [`&.${stateClass}`]: child\n }\n }, null, 2), '', 'https://mui.com/r/state-classes-guide'].join('\\n'));\n }\n // Remove the style to prevent global conflicts.\n node[key] = {};\n }\n }\n };\n Object.keys(muiTheme.components).forEach(component => {\n const styleOverrides = muiTheme.components[component].styleOverrides;\n if (styleOverrides && component.indexOf('Mui') === 0) {\n traverse(styleOverrides, component);\n }\n });\n }\n muiTheme.unstable_sxConfig = _extends({}, defaultSxConfig, other == null ? void 0 : other.unstable_sxConfig);\n muiTheme.unstable_sx = function sx(props) {\n return styleFunctionSx({\n sx: props,\n theme: this\n });\n };\n return muiTheme;\n}\nlet warnedOnce = false;\nexport function createMuiTheme(...args) {\n if (process.env.NODE_ENV !== 'production') {\n if (!warnedOnce) {\n warnedOnce = true;\n console.error(['MUI: the createMuiTheme function was renamed to createTheme.', '', \"You should use `import { createTheme } from '@mui/material/styles'`\"].join('\\n'));\n }\n }\n return createTheme(...args);\n}\nexport default createTheme;","'use client';\n\nimport createTheme from './createTheme';\nconst defaultTheme = createTheme();\nexport default defaultTheme;","export default '$$material';","'use client';\n\nimport { useThemeProps as systemUseThemeProps } from '@mui/system';\nimport defaultTheme from './defaultTheme';\nimport THEME_ID from './identifier';\nexport default function useThemeProps({\n props,\n name\n}) {\n return systemUseThemeProps({\n props,\n name,\n defaultTheme,\n themeId: THEME_ID\n });\n}","'use client';\n\nimport { createStyled, shouldForwardProp } from '@mui/system';\nimport defaultTheme from './defaultTheme';\nimport THEME_ID from './identifier';\nexport const rootShouldForwardProp = prop => shouldForwardProp(prop) && prop !== 'classes';\nexport const slotShouldForwardProp = shouldForwardProp;\nconst styled = createStyled({\n themeId: THEME_ID,\n defaultTheme,\n rootShouldForwardProp\n});\nexport default styled;","import generateUtilityClasses from '@mui/utils/generateUtilityClasses';\nimport generateUtilityClass from '@mui/utils/generateUtilityClass';\nexport function getSvgIconUtilityClass(slot) {\n return generateUtilityClass('MuiSvgIcon', slot);\n}\nconst svgIconClasses = generateUtilityClasses('MuiSvgIcon', ['root', 'colorPrimary', 'colorSecondary', 'colorAction', 'colorError', 'colorDisabled', 'fontSizeInherit', 'fontSizeSmall', 'fontSizeMedium', 'fontSizeLarge']);\nexport default svgIconClasses;","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"children\", \"className\", \"color\", \"component\", \"fontSize\", \"htmlColor\", \"inheritViewBox\", \"titleAccess\", \"viewBox\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport clsx from 'clsx';\nimport { unstable_composeClasses as composeClasses } from '@mui/base/composeClasses';\nimport capitalize from '../utils/capitalize';\nimport useThemeProps from '../styles/useThemeProps';\nimport styled from '../styles/styled';\nimport { getSvgIconUtilityClass } from './svgIconClasses';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nimport { jsxs as _jsxs } from \"react/jsx-runtime\";\nconst useUtilityClasses = ownerState => {\n const {\n color,\n fontSize,\n classes\n } = ownerState;\n const slots = {\n root: ['root', color !== 'inherit' && `color${capitalize(color)}`, `fontSize${capitalize(fontSize)}`]\n };\n return composeClasses(slots, getSvgIconUtilityClass, classes);\n};\nconst SvgIconRoot = styled('svg', {\n name: 'MuiSvgIcon',\n slot: 'Root',\n overridesResolver: (props, styles) => {\n const {\n ownerState\n } = props;\n return [styles.root, ownerState.color !== 'inherit' && styles[`color${capitalize(ownerState.color)}`], styles[`fontSize${capitalize(ownerState.fontSize)}`]];\n }\n})(({\n theme,\n ownerState\n}) => {\n var _theme$transitions, _theme$transitions$cr, _theme$transitions2, _theme$typography, _theme$typography$pxT, _theme$typography2, _theme$typography2$px, _theme$typography3, _theme$typography3$px, _palette$ownerState$c, _palette, _palette2, _palette3;\n return {\n userSelect: 'none',\n width: '1em',\n height: '1em',\n display: 'inline-block',\n // the will define the property that has `currentColor`\n // e.g. heroicons uses fill=\"none\" and stroke=\"currentColor\"\n fill: ownerState.hasSvgAsChild ? undefined : 'currentColor',\n flexShrink: 0,\n transition: (_theme$transitions = theme.transitions) == null || (_theme$transitions$cr = _theme$transitions.create) == null ? void 0 : _theme$transitions$cr.call(_theme$transitions, 'fill', {\n duration: (_theme$transitions2 = theme.transitions) == null || (_theme$transitions2 = _theme$transitions2.duration) == null ? void 0 : _theme$transitions2.shorter\n }),\n fontSize: {\n inherit: 'inherit',\n small: ((_theme$typography = theme.typography) == null || (_theme$typography$pxT = _theme$typography.pxToRem) == null ? void 0 : _theme$typography$pxT.call(_theme$typography, 20)) || '1.25rem',\n medium: ((_theme$typography2 = theme.typography) == null || (_theme$typography2$px = _theme$typography2.pxToRem) == null ? void 0 : _theme$typography2$px.call(_theme$typography2, 24)) || '1.5rem',\n large: ((_theme$typography3 = theme.typography) == null || (_theme$typography3$px = _theme$typography3.pxToRem) == null ? void 0 : _theme$typography3$px.call(_theme$typography3, 35)) || '2.1875rem'\n }[ownerState.fontSize],\n // TODO v5 deprecate, v6 remove for sx\n color: (_palette$ownerState$c = (_palette = (theme.vars || theme).palette) == null || (_palette = _palette[ownerState.color]) == null ? void 0 : _palette.main) != null ? _palette$ownerState$c : {\n action: (_palette2 = (theme.vars || theme).palette) == null || (_palette2 = _palette2.action) == null ? void 0 : _palette2.active,\n disabled: (_palette3 = (theme.vars || theme).palette) == null || (_palette3 = _palette3.action) == null ? void 0 : _palette3.disabled,\n inherit: undefined\n }[ownerState.color]\n };\n});\nconst SvgIcon = /*#__PURE__*/React.forwardRef(function SvgIcon(inProps, ref) {\n const props = useThemeProps({\n props: inProps,\n name: 'MuiSvgIcon'\n });\n const {\n children,\n className,\n color = 'inherit',\n component = 'svg',\n fontSize = 'medium',\n htmlColor,\n inheritViewBox = false,\n titleAccess,\n viewBox = '0 0 24 24'\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const hasSvgAsChild = /*#__PURE__*/React.isValidElement(children) && children.type === 'svg';\n const ownerState = _extends({}, props, {\n color,\n component,\n fontSize,\n instanceFontSize: inProps.fontSize,\n inheritViewBox,\n viewBox,\n hasSvgAsChild\n });\n const more = {};\n if (!inheritViewBox) {\n more.viewBox = viewBox;\n }\n const classes = useUtilityClasses(ownerState);\n return /*#__PURE__*/_jsxs(SvgIconRoot, _extends({\n as: component,\n className: clsx(classes.root, className),\n focusable: \"false\",\n color: htmlColor,\n \"aria-hidden\": titleAccess ? undefined : true,\n role: titleAccess ? 'img' : undefined,\n ref: ref\n }, more, other, hasSvgAsChild && children.props, {\n ownerState: ownerState,\n children: [hasSvgAsChild ? children.props.children : children, titleAccess ? /*#__PURE__*/_jsx(\"title\", {\n children: titleAccess\n }) : null]\n }));\n});\nprocess.env.NODE_ENV !== \"production\" ? SvgIcon.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the d.ts file and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * Node passed into the SVG element.\n */\n children: PropTypes.node,\n /**\n * Override or extend the styles applied to the component.\n */\n classes: PropTypes.object,\n /**\n * @ignore\n */\n className: PropTypes.string,\n /**\n * The color of the component.\n * It supports both default and custom theme colors, which can be added as shown in the\n * [palette customization guide](https://mui.com/material-ui/customization/palette/#custom-colors).\n * You can use the `htmlColor` prop to apply a color attribute to the SVG element.\n * @default 'inherit'\n */\n color: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.oneOf(['inherit', 'action', 'disabled', 'primary', 'secondary', 'error', 'info', 'success', 'warning']), PropTypes.string]),\n /**\n * The component used for the root node.\n * Either a string to use a HTML element or a component.\n */\n component: PropTypes.elementType,\n /**\n * The fontSize applied to the icon. Defaults to 24px, but can be configure to inherit font size.\n * @default 'medium'\n */\n fontSize: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.oneOf(['inherit', 'large', 'medium', 'small']), PropTypes.string]),\n /**\n * Applies a color attribute to the SVG element.\n */\n htmlColor: PropTypes.string,\n /**\n * If `true`, the root node will inherit the custom `component`'s viewBox and the `viewBox`\n * prop will be ignored.\n * Useful when you want to reference a custom `component` and have `SvgIcon` pass that\n * `component`'s viewBox to the root node.\n * @default false\n */\n inheritViewBox: PropTypes.bool,\n /**\n * The shape-rendering attribute. The behavior of the different options is described on the\n * [MDN Web Docs](https://developer.mozilla.org/en-US/docs/Web/SVG/Attribute/shape-rendering).\n * If you are having issues with blurry icons you should investigate this prop.\n */\n shapeRendering: PropTypes.string,\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Provides a human-readable title for the element that contains it.\n * https://www.w3.org/TR/SVG-access/#Equivalent\n */\n titleAccess: PropTypes.string,\n /**\n * Allows you to redefine what the coordinates without units mean inside an SVG element.\n * For example, if the SVG element is 500 (width) by 200 (height),\n * and you pass viewBox=\"0 0 50 20\",\n * this means that the coordinates inside the SVG will go from the top left corner (0,0)\n * to bottom right (50,20) and each unit will be worth 10px.\n * @default '0 0 24 24'\n */\n viewBox: PropTypes.string\n} : void 0;\nSvgIcon.muiName = 'SvgIcon';\nexport default SvgIcon;","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport * as React from 'react';\nimport SvgIcon from '../SvgIcon';\n\n/**\n * Private module reserved for @mui packages.\n */\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nexport default function createSvgIcon(path, displayName) {\n function Component(props, ref) {\n return /*#__PURE__*/_jsx(SvgIcon, _extends({\n \"data-testid\": `${displayName}Icon`,\n ref: ref\n }, props, {\n children: path\n }));\n }\n if (process.env.NODE_ENV !== 'production') {\n // Need to set `displayName` on the inner component for React.memo.\n // React prior to 16.14 ignores `displayName` on the wrapper.\n Component.displayName = `${displayName}Icon`;\n }\n Component.muiName = SvgIcon.muiName;\n return /*#__PURE__*/React.memo( /*#__PURE__*/React.forwardRef(Component));\n}","'use client';\n\nimport { unstable_ClassNameGenerator as ClassNameGenerator } from '@mui/base/ClassNameGenerator';\nexport { default as capitalize } from './capitalize';\nexport { default as createChainedFunction } from './createChainedFunction';\nexport { default as createSvgIcon } from './createSvgIcon';\nexport { default as debounce } from './debounce';\nexport { default as deprecatedPropType } from './deprecatedPropType';\nexport { default as isMuiElement } from './isMuiElement';\nexport { default as ownerDocument } from './ownerDocument';\nexport { default as ownerWindow } from './ownerWindow';\nexport { default as requirePropFactory } from './requirePropFactory';\nexport { default as setRef } from './setRef';\nexport { default as unstable_useEnhancedEffect } from './useEnhancedEffect';\nexport { default as unstable_useId } from './useId';\nexport { default as unsupportedProp } from './unsupportedProp';\nexport { default as useControlled } from './useControlled';\nexport { default as useEventCallback } from './useEventCallback';\nexport { default as useForkRef } from './useForkRef';\nexport { default as useIsFocusVisible } from './useIsFocusVisible';\n// TODO: remove this export once ClassNameGenerator is stable\n// eslint-disable-next-line @typescript-eslint/naming-convention\nexport const unstable_ClassNameGenerator = {\n configure: generator => {\n if (process.env.NODE_ENV !== 'production') {\n console.warn(['MUI: `ClassNameGenerator` import from `@mui/material/utils` is outdated and might cause unexpected issues.', '', \"You should use `import { unstable_ClassNameGenerator } from '@mui/material/className'` instead\", '', 'The detail of the issue: https://github.com/mui/material-ui/issues/30011#issuecomment-1024993401', '', 'The updated documentation: https://mui.com/guides/classname-generator/'].join('\\n'));\n }\n ClassNameGenerator.configure(generator);\n }\n};","\"use strict\";\n'use client';\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nObject.defineProperty(exports, \"default\", {\n enumerable: true,\n get: function () {\n return _utils.createSvgIcon;\n }\n});\nvar _utils = require(\"@mui/material/utils\");","\"use strict\";\n\"use client\";\n\nvar _interopRequireDefault = require(\"@babel/runtime/helpers/interopRequireDefault\");\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = void 0;\nvar _createSvgIcon = _interopRequireDefault(require(\"./utils/createSvgIcon\"));\nvar _jsxRuntime = require(\"react/jsx-runtime\");\nvar _default = exports.default = (0, _createSvgIcon.default)( /*#__PURE__*/(0, _jsxRuntime.jsx)(\"path\", {\n d: \"m10 17 5-5-5-5z\"\n}), 'ArrowRight');","/**\n * Determines if a given element is a DOM element name (i.e. not a React component).\n */\nexport function isHostComponent(element) {\n return typeof element === 'string';\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport { isHostComponent } from './isHostComponent';\n\n/**\n * Type of the ownerState based on the type of an element it applies to.\n * This resolves to the provided OwnerState for React components and `undefined` for host components.\n * Falls back to `OwnerState | undefined` when the exact type can't be determined in development time.\n */\n\n/**\n * Appends the ownerState object to the props, merging with the existing one if necessary.\n *\n * @param elementType Type of the element that owns the `existingProps`. If the element is a DOM node or undefined, `ownerState` is not applied.\n * @param otherProps Props of the element.\n * @param ownerState\n */\nexport function appendOwnerState(elementType, otherProps, ownerState) {\n if (elementType === undefined || isHostComponent(elementType)) {\n return otherProps;\n }\n return _extends({}, otherProps, {\n ownerState: _extends({}, otherProps.ownerState, ownerState)\n });\n}","'use client';\n\nimport * as React from 'react';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nconst defaultContextValue = {\n disableDefaultClasses: false\n};\nconst ClassNameConfiguratorContext = /*#__PURE__*/React.createContext(defaultContextValue);\n/**\n * @ignore - internal hook.\n *\n * Wraps the `generateUtilityClass` function and controls how the classes are generated.\n * Currently it only affects whether the classes are applied or not.\n *\n * @returns Function to be called with the `generateUtilityClass` function specific to a component to generate the classes.\n */\nexport function useClassNamesOverride(generateUtilityClass) {\n const {\n disableDefaultClasses\n } = React.useContext(ClassNameConfiguratorContext);\n return slot => {\n if (disableDefaultClasses) {\n return '';\n }\n return generateUtilityClass(slot);\n };\n}\n\n/**\n * Allows to configure the components within to not apply any built-in classes.\n */\nexport function ClassNameConfigurator(props) {\n const {\n disableDefaultClasses,\n children\n } = props;\n const contextValue = React.useMemo(() => ({\n disableDefaultClasses: disableDefaultClasses != null ? disableDefaultClasses : false\n }), [disableDefaultClasses]);\n return /*#__PURE__*/_jsx(ClassNameConfiguratorContext.Provider, {\n value: contextValue,\n children: children\n });\n}","/**\n * Extracts event handlers from a given object.\n * A prop is considered an event handler if it is a function and its name starts with `on`.\n *\n * @param object An object to extract event handlers from.\n * @param excludeKeys An array of keys to exclude from the returned object.\n */\nexport function extractEventHandlers(object, excludeKeys = []) {\n if (object === undefined) {\n return {};\n }\n const result = {};\n Object.keys(object).filter(prop => prop.match(/^on[A-Z]/) && typeof object[prop] === 'function' && !excludeKeys.includes(prop)).forEach(prop => {\n result[prop] = object[prop];\n });\n return result;\n}","/**\n * If `componentProps` is a function, calls it with the provided `ownerState`.\n * Otherwise, just returns `componentProps`.\n */\nexport function resolveComponentProps(componentProps, ownerState, slotState) {\n if (typeof componentProps === 'function') {\n return componentProps(ownerState, slotState);\n }\n return componentProps;\n}","/**\n * Removes event handlers from the given object.\n * A field is considered an event handler if it is a function with a name beginning with `on`.\n *\n * @param object Object to remove event handlers from.\n * @returns Object with event handlers removed.\n */\nexport function omitEventHandlers(object) {\n if (object === undefined) {\n return {};\n }\n const result = {};\n Object.keys(object).filter(prop => !(prop.match(/^on[A-Z]/) && typeof object[prop] === 'function')).forEach(prop => {\n result[prop] = object[prop];\n });\n return result;\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport clsx from 'clsx';\nimport { extractEventHandlers } from './extractEventHandlers';\nimport { omitEventHandlers } from './omitEventHandlers';\n/**\n * Merges the slot component internal props (usually coming from a hook)\n * with the externally provided ones.\n *\n * The merge order is (the latter overrides the former):\n * 1. The internal props (specified as a getter function to work with get*Props hook result)\n * 2. Additional props (specified internally on a Base UI component)\n * 3. External props specified on the owner component. These should only be used on a root slot.\n * 4. External props specified in the `slotProps.*` prop.\n * 5. The `className` prop - combined from all the above.\n * @param parameters\n * @returns\n */\nexport function mergeSlotProps(parameters) {\n const {\n getSlotProps,\n additionalProps,\n externalSlotProps,\n externalForwardedProps,\n className\n } = parameters;\n if (!getSlotProps) {\n // The simpler case - getSlotProps is not defined, so no internal event handlers are defined,\n // so we can simply merge all the props without having to worry about extracting event handlers.\n const joinedClasses = clsx(additionalProps == null ? void 0 : additionalProps.className, className, externalForwardedProps == null ? void 0 : externalForwardedProps.className, externalSlotProps == null ? void 0 : externalSlotProps.className);\n const mergedStyle = _extends({}, additionalProps == null ? void 0 : additionalProps.style, externalForwardedProps == null ? void 0 : externalForwardedProps.style, externalSlotProps == null ? void 0 : externalSlotProps.style);\n const props = _extends({}, additionalProps, externalForwardedProps, externalSlotProps);\n if (joinedClasses.length > 0) {\n props.className = joinedClasses;\n }\n if (Object.keys(mergedStyle).length > 0) {\n props.style = mergedStyle;\n }\n return {\n props,\n internalRef: undefined\n };\n }\n\n // In this case, getSlotProps is responsible for calling the external event handlers.\n // We don't need to include them in the merged props because of this.\n\n const eventHandlers = extractEventHandlers(_extends({}, externalForwardedProps, externalSlotProps));\n const componentsPropsWithoutEventHandlers = omitEventHandlers(externalSlotProps);\n const otherPropsWithoutEventHandlers = omitEventHandlers(externalForwardedProps);\n const internalSlotProps = getSlotProps(eventHandlers);\n\n // The order of classes is important here.\n // Emotion (that we use in libraries consuming Base UI) depends on this order\n // to properly override style. It requires the most important classes to be last\n // (see https://github.com/mui/material-ui/pull/33205) for the related discussion.\n const joinedClasses = clsx(internalSlotProps == null ? void 0 : internalSlotProps.className, additionalProps == null ? void 0 : additionalProps.className, className, externalForwardedProps == null ? void 0 : externalForwardedProps.className, externalSlotProps == null ? void 0 : externalSlotProps.className);\n const mergedStyle = _extends({}, internalSlotProps == null ? void 0 : internalSlotProps.style, additionalProps == null ? void 0 : additionalProps.style, externalForwardedProps == null ? void 0 : externalForwardedProps.style, externalSlotProps == null ? void 0 : externalSlotProps.style);\n const props = _extends({}, internalSlotProps, additionalProps, otherPropsWithoutEventHandlers, componentsPropsWithoutEventHandlers);\n if (joinedClasses.length > 0) {\n props.className = joinedClasses;\n }\n if (Object.keys(mergedStyle).length > 0) {\n props.style = mergedStyle;\n }\n return {\n props,\n internalRef: internalSlotProps.ref\n };\n}","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"elementType\", \"externalSlotProps\", \"ownerState\", \"skipResolvingSlotProps\"];\nimport { unstable_useForkRef as useForkRef } from '@mui/utils';\nimport { appendOwnerState } from './appendOwnerState';\nimport { mergeSlotProps } from './mergeSlotProps';\nimport { resolveComponentProps } from './resolveComponentProps';\n/**\n * @ignore - do not document.\n * Builds the props to be passed into the slot of an unstyled component.\n * It merges the internal props of the component with the ones supplied by the user, allowing to customize the behavior.\n * If the slot component is not a host component, it also merges in the `ownerState`.\n *\n * @param parameters.getSlotProps - A function that returns the props to be passed to the slot component.\n */\nexport function useSlotProps(parameters) {\n var _parameters$additiona;\n const {\n elementType,\n externalSlotProps,\n ownerState,\n skipResolvingSlotProps = false\n } = parameters,\n rest = _objectWithoutPropertiesLoose(parameters, _excluded);\n const resolvedComponentsProps = skipResolvingSlotProps ? {} : resolveComponentProps(externalSlotProps, ownerState);\n const {\n props: mergedProps,\n internalRef\n } = mergeSlotProps(_extends({}, rest, {\n externalSlotProps: resolvedComponentsProps\n }));\n const ref = useForkRef(internalRef, resolvedComponentsProps == null ? void 0 : resolvedComponentsProps.ref, (_parameters$additiona = parameters.additionalProps) == null ? void 0 : _parameters$additiona.ref);\n const props = appendOwnerState(elementType, _extends({}, mergedProps, {\n ref\n }), ownerState);\n return props;\n}","import { globalStateClasses } from '@mui/utils/generateUtilityClass';\nconst GLOBAL_CLASS_PREFIX = 'base';\nfunction buildStateClass(state) {\n return `${GLOBAL_CLASS_PREFIX}--${state}`;\n}\nfunction buildSlotClass(componentName, slot) {\n return `${GLOBAL_CLASS_PREFIX}-${componentName}-${slot}`;\n}\nexport function generateUtilityClass(componentName, slot) {\n const globalStateClass = globalStateClasses[slot];\n return globalStateClass ? buildStateClass(globalStateClass) : buildSlotClass(componentName, slot);\n}\nexport function isGlobalState(slot) {\n return globalStateClasses[slot] !== undefined;\n}","import { generateUtilityClass } from '../generateUtilityClass';\nexport function generateUtilityClasses(componentName, slots) {\n const result = {};\n slots.forEach(slot => {\n result[slot] = generateUtilityClass(componentName, slot);\n });\n return result;\n}","'use client';\n\nimport * as React from 'react';\nimport * as ReactDOM from 'react-dom';\nimport PropTypes from 'prop-types';\nimport { exactProp, HTMLElementType, unstable_useEnhancedEffect as useEnhancedEffect, unstable_useForkRef as useForkRef, unstable_setRef as setRef } from '@mui/utils';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nfunction getContainer(container) {\n return typeof container === 'function' ? container() : container;\n}\n\n/**\n * Portals provide a first-class way to render children into a DOM node\n * that exists outside the DOM hierarchy of the parent component.\n *\n * Demos:\n *\n * - [Portal](https://mui.com/base-ui/react-portal/)\n *\n * API:\n *\n * - [Portal API](https://mui.com/base-ui/react-portal/components-api/#portal)\n */\nconst Portal = /*#__PURE__*/React.forwardRef(function Portal(props, forwardedRef) {\n const {\n children,\n container,\n disablePortal = false\n } = props;\n const [mountNode, setMountNode] = React.useState(null);\n // @ts-expect-error TODO upstream fix\n const handleRef = useForkRef( /*#__PURE__*/React.isValidElement(children) ? children.ref : null, forwardedRef);\n useEnhancedEffect(() => {\n if (!disablePortal) {\n setMountNode(getContainer(container) || document.body);\n }\n }, [container, disablePortal]);\n useEnhancedEffect(() => {\n if (mountNode && !disablePortal) {\n setRef(forwardedRef, mountNode);\n return () => {\n setRef(forwardedRef, null);\n };\n }\n return undefined;\n }, [forwardedRef, mountNode, disablePortal]);\n if (disablePortal) {\n if ( /*#__PURE__*/React.isValidElement(children)) {\n const newProps = {\n ref: handleRef\n };\n return /*#__PURE__*/React.cloneElement(children, newProps);\n }\n return /*#__PURE__*/_jsx(React.Fragment, {\n children: children\n });\n }\n return /*#__PURE__*/_jsx(React.Fragment, {\n children: mountNode ? /*#__PURE__*/ReactDOM.createPortal(children, mountNode) : mountNode\n });\n});\nprocess.env.NODE_ENV !== \"production\" ? Portal.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * The children to render into the `container`.\n */\n children: PropTypes.node,\n /**\n * An HTML element or function that returns one.\n * The `container` will have the portal children appended to it.\n *\n * You can also provide a callback, which is called in a React layout effect.\n * This lets you set the container from a ref, and also makes server-side rendering possible.\n *\n * By default, it uses the body of the top-level document object,\n * so it's simply `document.body` most of the time.\n */\n container: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.func]),\n /**\n * The `children` will be under the DOM hierarchy of the parent component.\n * @default false\n */\n disablePortal: PropTypes.bool\n} : void 0;\nif (process.env.NODE_ENV !== 'production') {\n // eslint-disable-next-line\n Portal['propTypes' + ''] = exactProp(Portal.propTypes);\n}\nexport { Portal };","export var top = 'top';\nexport var bottom = 'bottom';\nexport var right = 'right';\nexport var left = 'left';\nexport var auto = 'auto';\nexport var basePlacements = [top, bottom, right, left];\nexport var start = 'start';\nexport var end = 'end';\nexport var clippingParents = 'clippingParents';\nexport var viewport = 'viewport';\nexport var popper = 'popper';\nexport var reference = 'reference';\nexport var variationPlacements = /*#__PURE__*/basePlacements.reduce(function (acc, placement) {\n return acc.concat([placement + \"-\" + start, placement + \"-\" + end]);\n}, []);\nexport var placements = /*#__PURE__*/[].concat(basePlacements, [auto]).reduce(function (acc, placement) {\n return acc.concat([placement, placement + \"-\" + start, placement + \"-\" + end]);\n}, []); // modifiers that need to read the DOM\n\nexport var beforeRead = 'beforeRead';\nexport var read = 'read';\nexport var afterRead = 'afterRead'; // pure-logic modifiers\n\nexport var beforeMain = 'beforeMain';\nexport var main = 'main';\nexport var afterMain = 'afterMain'; // modifier with the purpose to write to the DOM (or write into a framework state)\n\nexport var beforeWrite = 'beforeWrite';\nexport var write = 'write';\nexport var afterWrite = 'afterWrite';\nexport var modifierPhases = [beforeRead, read, afterRead, beforeMain, main, afterMain, beforeWrite, write, afterWrite];","export default function getNodeName(element) {\n return element ? (element.nodeName || '').toLowerCase() : null;\n}","export default function getWindow(node) {\n if (node == null) {\n return window;\n }\n\n if (node.toString() !== '[object Window]') {\n var ownerDocument = node.ownerDocument;\n return ownerDocument ? ownerDocument.defaultView || window : window;\n }\n\n return node;\n}","import getWindow from \"./getWindow.js\";\n\nfunction isElement(node) {\n var OwnElement = getWindow(node).Element;\n return node instanceof OwnElement || node instanceof Element;\n}\n\nfunction isHTMLElement(node) {\n var OwnElement = getWindow(node).HTMLElement;\n return node instanceof OwnElement || node instanceof HTMLElement;\n}\n\nfunction isShadowRoot(node) {\n // IE 11 has no ShadowRoot\n if (typeof ShadowRoot === 'undefined') {\n return false;\n }\n\n var OwnElement = getWindow(node).ShadowRoot;\n return node instanceof OwnElement || node instanceof ShadowRoot;\n}\n\nexport { isElement, isHTMLElement, isShadowRoot };","import getNodeName from \"../dom-utils/getNodeName.js\";\nimport { isHTMLElement } from \"../dom-utils/instanceOf.js\"; // This modifier takes the styles prepared by the `computeStyles` modifier\n// and applies them to the HTMLElements such as popper and arrow\n\nfunction applyStyles(_ref) {\n var state = _ref.state;\n Object.keys(state.elements).forEach(function (name) {\n var style = state.styles[name] || {};\n var attributes = state.attributes[name] || {};\n var element = state.elements[name]; // arrow is optional + virtual elements\n\n if (!isHTMLElement(element) || !getNodeName(element)) {\n return;\n } // Flow doesn't support to extend this property, but it's the most\n // effective way to apply styles to an HTMLElement\n // $FlowFixMe[cannot-write]\n\n\n Object.assign(element.style, style);\n Object.keys(attributes).forEach(function (name) {\n var value = attributes[name];\n\n if (value === false) {\n element.removeAttribute(name);\n } else {\n element.setAttribute(name, value === true ? '' : value);\n }\n });\n });\n}\n\nfunction effect(_ref2) {\n var state = _ref2.state;\n var initialStyles = {\n popper: {\n position: state.options.strategy,\n left: '0',\n top: '0',\n margin: '0'\n },\n arrow: {\n position: 'absolute'\n },\n reference: {}\n };\n Object.assign(state.elements.popper.style, initialStyles.popper);\n state.styles = initialStyles;\n\n if (state.elements.arrow) {\n Object.assign(state.elements.arrow.style, initialStyles.arrow);\n }\n\n return function () {\n Object.keys(state.elements).forEach(function (name) {\n var element = state.elements[name];\n var attributes = state.attributes[name] || {};\n var styleProperties = Object.keys(state.styles.hasOwnProperty(name) ? state.styles[name] : initialStyles[name]); // Set all values to an empty string to unset them\n\n var style = styleProperties.reduce(function (style, property) {\n style[property] = '';\n return style;\n }, {}); // arrow is optional + virtual elements\n\n if (!isHTMLElement(element) || !getNodeName(element)) {\n return;\n }\n\n Object.assign(element.style, style);\n Object.keys(attributes).forEach(function (attribute) {\n element.removeAttribute(attribute);\n });\n });\n };\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'applyStyles',\n enabled: true,\n phase: 'write',\n fn: applyStyles,\n effect: effect,\n requires: ['computeStyles']\n};","import { auto } from \"../enums.js\";\nexport default function getBasePlacement(placement) {\n return placement.split('-')[0];\n}","export var max = Math.max;\nexport var min = Math.min;\nexport var round = Math.round;","export default function getUAString() {\n var uaData = navigator.userAgentData;\n\n if (uaData != null && uaData.brands && Array.isArray(uaData.brands)) {\n return uaData.brands.map(function (item) {\n return item.brand + \"/\" + item.version;\n }).join(' ');\n }\n\n return navigator.userAgent;\n}","import getUAString from \"../utils/userAgent.js\";\nexport default function isLayoutViewport() {\n return !/^((?!chrome|android).)*safari/i.test(getUAString());\n}","import { isElement, isHTMLElement } from \"./instanceOf.js\";\nimport { round } from \"../utils/math.js\";\nimport getWindow from \"./getWindow.js\";\nimport isLayoutViewport from \"./isLayoutViewport.js\";\nexport default function getBoundingClientRect(element, includeScale, isFixedStrategy) {\n if (includeScale === void 0) {\n includeScale = false;\n }\n\n if (isFixedStrategy === void 0) {\n isFixedStrategy = false;\n }\n\n var clientRect = element.getBoundingClientRect();\n var scaleX = 1;\n var scaleY = 1;\n\n if (includeScale && isHTMLElement(element)) {\n scaleX = element.offsetWidth > 0 ? round(clientRect.width) / element.offsetWidth || 1 : 1;\n scaleY = element.offsetHeight > 0 ? round(clientRect.height) / element.offsetHeight || 1 : 1;\n }\n\n var _ref = isElement(element) ? getWindow(element) : window,\n visualViewport = _ref.visualViewport;\n\n var addVisualOffsets = !isLayoutViewport() && isFixedStrategy;\n var x = (clientRect.left + (addVisualOffsets && visualViewport ? visualViewport.offsetLeft : 0)) / scaleX;\n var y = (clientRect.top + (addVisualOffsets && visualViewport ? visualViewport.offsetTop : 0)) / scaleY;\n var width = clientRect.width / scaleX;\n var height = clientRect.height / scaleY;\n return {\n width: width,\n height: height,\n top: y,\n right: x + width,\n bottom: y + height,\n left: x,\n x: x,\n y: y\n };\n}","import getBoundingClientRect from \"./getBoundingClientRect.js\"; // Returns the layout rect of an element relative to its offsetParent. Layout\n// means it doesn't take into account transforms.\n\nexport default function getLayoutRect(element) {\n var clientRect = getBoundingClientRect(element); // Use the clientRect sizes if it's not been transformed.\n // Fixes https://github.com/popperjs/popper-core/issues/1223\n\n var width = element.offsetWidth;\n var height = element.offsetHeight;\n\n if (Math.abs(clientRect.width - width) <= 1) {\n width = clientRect.width;\n }\n\n if (Math.abs(clientRect.height - height) <= 1) {\n height = clientRect.height;\n }\n\n return {\n x: element.offsetLeft,\n y: element.offsetTop,\n width: width,\n height: height\n };\n}","import { isShadowRoot } from \"./instanceOf.js\";\nexport default function contains(parent, child) {\n var rootNode = child.getRootNode && child.getRootNode(); // First, attempt with faster native method\n\n if (parent.contains(child)) {\n return true;\n } // then fallback to custom implementation with Shadow DOM support\n else if (rootNode && isShadowRoot(rootNode)) {\n var next = child;\n\n do {\n if (next && parent.isSameNode(next)) {\n return true;\n } // $FlowFixMe[prop-missing]: need a better way to handle this...\n\n\n next = next.parentNode || next.host;\n } while (next);\n } // Give up, the result is false\n\n\n return false;\n}","import getWindow from \"./getWindow.js\";\nexport default function getComputedStyle(element) {\n return getWindow(element).getComputedStyle(element);\n}","import getNodeName from \"./getNodeName.js\";\nexport default function isTableElement(element) {\n return ['table', 'td', 'th'].indexOf(getNodeName(element)) >= 0;\n}","import { isElement } from \"./instanceOf.js\";\nexport default function getDocumentElement(element) {\n // $FlowFixMe[incompatible-return]: assume body is always available\n return ((isElement(element) ? element.ownerDocument : // $FlowFixMe[prop-missing]\n element.document) || window.document).documentElement;\n}","import getNodeName from \"./getNodeName.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport { isShadowRoot } from \"./instanceOf.js\";\nexport default function getParentNode(element) {\n if (getNodeName(element) === 'html') {\n return element;\n }\n\n return (// this is a quicker (but less type safe) way to save quite some bytes from the bundle\n // $FlowFixMe[incompatible-return]\n // $FlowFixMe[prop-missing]\n element.assignedSlot || // step into the shadow DOM of the parent of a slotted node\n element.parentNode || ( // DOM Element detected\n isShadowRoot(element) ? element.host : null) || // ShadowRoot detected\n // $FlowFixMe[incompatible-call]: HTMLElement is a Node\n getDocumentElement(element) // fallback\n\n );\n}","import getWindow from \"./getWindow.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport getComputedStyle from \"./getComputedStyle.js\";\nimport { isHTMLElement, isShadowRoot } from \"./instanceOf.js\";\nimport isTableElement from \"./isTableElement.js\";\nimport getParentNode from \"./getParentNode.js\";\nimport getUAString from \"../utils/userAgent.js\";\n\nfunction getTrueOffsetParent(element) {\n if (!isHTMLElement(element) || // https://github.com/popperjs/popper-core/issues/837\n getComputedStyle(element).position === 'fixed') {\n return null;\n }\n\n return element.offsetParent;\n} // `.offsetParent` reports `null` for fixed elements, while absolute elements\n// return the containing block\n\n\nfunction getContainingBlock(element) {\n var isFirefox = /firefox/i.test(getUAString());\n var isIE = /Trident/i.test(getUAString());\n\n if (isIE && isHTMLElement(element)) {\n // In IE 9, 10 and 11 fixed elements containing block is always established by the viewport\n var elementCss = getComputedStyle(element);\n\n if (elementCss.position === 'fixed') {\n return null;\n }\n }\n\n var currentNode = getParentNode(element);\n\n if (isShadowRoot(currentNode)) {\n currentNode = currentNode.host;\n }\n\n while (isHTMLElement(currentNode) && ['html', 'body'].indexOf(getNodeName(currentNode)) < 0) {\n var css = getComputedStyle(currentNode); // This is non-exhaustive but covers the most common CSS properties that\n // create a containing block.\n // https://developer.mozilla.org/en-US/docs/Web/CSS/Containing_block#identifying_the_containing_block\n\n if (css.transform !== 'none' || css.perspective !== 'none' || css.contain === 'paint' || ['transform', 'perspective'].indexOf(css.willChange) !== -1 || isFirefox && css.willChange === 'filter' || isFirefox && css.filter && css.filter !== 'none') {\n return currentNode;\n } else {\n currentNode = currentNode.parentNode;\n }\n }\n\n return null;\n} // Gets the closest ancestor positioned element. Handles some edge cases,\n// such as table ancestors and cross browser bugs.\n\n\nexport default function getOffsetParent(element) {\n var window = getWindow(element);\n var offsetParent = getTrueOffsetParent(element);\n\n while (offsetParent && isTableElement(offsetParent) && getComputedStyle(offsetParent).position === 'static') {\n offsetParent = getTrueOffsetParent(offsetParent);\n }\n\n if (offsetParent && (getNodeName(offsetParent) === 'html' || getNodeName(offsetParent) === 'body' && getComputedStyle(offsetParent).position === 'static')) {\n return window;\n }\n\n return offsetParent || getContainingBlock(element) || window;\n}","export default function getMainAxisFromPlacement(placement) {\n return ['top', 'bottom'].indexOf(placement) >= 0 ? 'x' : 'y';\n}","import { max as mathMax, min as mathMin } from \"./math.js\";\nexport function within(min, value, max) {\n return mathMax(min, mathMin(value, max));\n}\nexport function withinMaxClamp(min, value, max) {\n var v = within(min, value, max);\n return v > max ? max : v;\n}","export default function getFreshSideObject() {\n return {\n top: 0,\n right: 0,\n bottom: 0,\n left: 0\n };\n}","import getFreshSideObject from \"./getFreshSideObject.js\";\nexport default function mergePaddingObject(paddingObject) {\n return Object.assign({}, getFreshSideObject(), paddingObject);\n}","export default function expandToHashMap(value, keys) {\n return keys.reduce(function (hashMap, key) {\n hashMap[key] = value;\n return hashMap;\n }, {});\n}","import getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getLayoutRect from \"../dom-utils/getLayoutRect.js\";\nimport contains from \"../dom-utils/contains.js\";\nimport getOffsetParent from \"../dom-utils/getOffsetParent.js\";\nimport getMainAxisFromPlacement from \"../utils/getMainAxisFromPlacement.js\";\nimport { within } from \"../utils/within.js\";\nimport mergePaddingObject from \"../utils/mergePaddingObject.js\";\nimport expandToHashMap from \"../utils/expandToHashMap.js\";\nimport { left, right, basePlacements, top, bottom } from \"../enums.js\"; // eslint-disable-next-line import/no-unused-modules\n\nvar toPaddingObject = function toPaddingObject(padding, state) {\n padding = typeof padding === 'function' ? padding(Object.assign({}, state.rects, {\n placement: state.placement\n })) : padding;\n return mergePaddingObject(typeof padding !== 'number' ? padding : expandToHashMap(padding, basePlacements));\n};\n\nfunction arrow(_ref) {\n var _state$modifiersData$;\n\n var state = _ref.state,\n name = _ref.name,\n options = _ref.options;\n var arrowElement = state.elements.arrow;\n var popperOffsets = state.modifiersData.popperOffsets;\n var basePlacement = getBasePlacement(state.placement);\n var axis = getMainAxisFromPlacement(basePlacement);\n var isVertical = [left, right].indexOf(basePlacement) >= 0;\n var len = isVertical ? 'height' : 'width';\n\n if (!arrowElement || !popperOffsets) {\n return;\n }\n\n var paddingObject = toPaddingObject(options.padding, state);\n var arrowRect = getLayoutRect(arrowElement);\n var minProp = axis === 'y' ? top : left;\n var maxProp = axis === 'y' ? bottom : right;\n var endDiff = state.rects.reference[len] + state.rects.reference[axis] - popperOffsets[axis] - state.rects.popper[len];\n var startDiff = popperOffsets[axis] - state.rects.reference[axis];\n var arrowOffsetParent = getOffsetParent(arrowElement);\n var clientSize = arrowOffsetParent ? axis === 'y' ? arrowOffsetParent.clientHeight || 0 : arrowOffsetParent.clientWidth || 0 : 0;\n var centerToReference = endDiff / 2 - startDiff / 2; // Make sure the arrow doesn't overflow the popper if the center point is\n // outside of the popper bounds\n\n var min = paddingObject[minProp];\n var max = clientSize - arrowRect[len] - paddingObject[maxProp];\n var center = clientSize / 2 - arrowRect[len] / 2 + centerToReference;\n var offset = within(min, center, max); // Prevents breaking syntax highlighting...\n\n var axisProp = axis;\n state.modifiersData[name] = (_state$modifiersData$ = {}, _state$modifiersData$[axisProp] = offset, _state$modifiersData$.centerOffset = offset - center, _state$modifiersData$);\n}\n\nfunction effect(_ref2) {\n var state = _ref2.state,\n options = _ref2.options;\n var _options$element = options.element,\n arrowElement = _options$element === void 0 ? '[data-popper-arrow]' : _options$element;\n\n if (arrowElement == null) {\n return;\n } // CSS selector\n\n\n if (typeof arrowElement === 'string') {\n arrowElement = state.elements.popper.querySelector(arrowElement);\n\n if (!arrowElement) {\n return;\n }\n }\n\n if (!contains(state.elements.popper, arrowElement)) {\n return;\n }\n\n state.elements.arrow = arrowElement;\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'arrow',\n enabled: true,\n phase: 'main',\n fn: arrow,\n effect: effect,\n requires: ['popperOffsets'],\n requiresIfExists: ['preventOverflow']\n};","export default function getVariation(placement) {\n return placement.split('-')[1];\n}","import { top, left, right, bottom, end } from \"../enums.js\";\nimport getOffsetParent from \"../dom-utils/getOffsetParent.js\";\nimport getWindow from \"../dom-utils/getWindow.js\";\nimport getDocumentElement from \"../dom-utils/getDocumentElement.js\";\nimport getComputedStyle from \"../dom-utils/getComputedStyle.js\";\nimport getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getVariation from \"../utils/getVariation.js\";\nimport { round } from \"../utils/math.js\"; // eslint-disable-next-line import/no-unused-modules\n\nvar unsetSides = {\n top: 'auto',\n right: 'auto',\n bottom: 'auto',\n left: 'auto'\n}; // Round the offsets to the nearest suitable subpixel based on the DPR.\n// Zooming can change the DPR, but it seems to report a value that will\n// cleanly divide the values into the appropriate subpixels.\n\nfunction roundOffsetsByDPR(_ref, win) {\n var x = _ref.x,\n y = _ref.y;\n var dpr = win.devicePixelRatio || 1;\n return {\n x: round(x * dpr) / dpr || 0,\n y: round(y * dpr) / dpr || 0\n };\n}\n\nexport function mapToStyles(_ref2) {\n var _Object$assign2;\n\n var popper = _ref2.popper,\n popperRect = _ref2.popperRect,\n placement = _ref2.placement,\n variation = _ref2.variation,\n offsets = _ref2.offsets,\n position = _ref2.position,\n gpuAcceleration = _ref2.gpuAcceleration,\n adaptive = _ref2.adaptive,\n roundOffsets = _ref2.roundOffsets,\n isFixed = _ref2.isFixed;\n var _offsets$x = offsets.x,\n x = _offsets$x === void 0 ? 0 : _offsets$x,\n _offsets$y = offsets.y,\n y = _offsets$y === void 0 ? 0 : _offsets$y;\n\n var _ref3 = typeof roundOffsets === 'function' ? roundOffsets({\n x: x,\n y: y\n }) : {\n x: x,\n y: y\n };\n\n x = _ref3.x;\n y = _ref3.y;\n var hasX = offsets.hasOwnProperty('x');\n var hasY = offsets.hasOwnProperty('y');\n var sideX = left;\n var sideY = top;\n var win = window;\n\n if (adaptive) {\n var offsetParent = getOffsetParent(popper);\n var heightProp = 'clientHeight';\n var widthProp = 'clientWidth';\n\n if (offsetParent === getWindow(popper)) {\n offsetParent = getDocumentElement(popper);\n\n if (getComputedStyle(offsetParent).position !== 'static' && position === 'absolute') {\n heightProp = 'scrollHeight';\n widthProp = 'scrollWidth';\n }\n } // $FlowFixMe[incompatible-cast]: force type refinement, we compare offsetParent with window above, but Flow doesn't detect it\n\n\n offsetParent = offsetParent;\n\n if (placement === top || (placement === left || placement === right) && variation === end) {\n sideY = bottom;\n var offsetY = isFixed && offsetParent === win && win.visualViewport ? win.visualViewport.height : // $FlowFixMe[prop-missing]\n offsetParent[heightProp];\n y -= offsetY - popperRect.height;\n y *= gpuAcceleration ? 1 : -1;\n }\n\n if (placement === left || (placement === top || placement === bottom) && variation === end) {\n sideX = right;\n var offsetX = isFixed && offsetParent === win && win.visualViewport ? win.visualViewport.width : // $FlowFixMe[prop-missing]\n offsetParent[widthProp];\n x -= offsetX - popperRect.width;\n x *= gpuAcceleration ? 1 : -1;\n }\n }\n\n var commonStyles = Object.assign({\n position: position\n }, adaptive && unsetSides);\n\n var _ref4 = roundOffsets === true ? roundOffsetsByDPR({\n x: x,\n y: y\n }, getWindow(popper)) : {\n x: x,\n y: y\n };\n\n x = _ref4.x;\n y = _ref4.y;\n\n if (gpuAcceleration) {\n var _Object$assign;\n\n return Object.assign({}, commonStyles, (_Object$assign = {}, _Object$assign[sideY] = hasY ? '0' : '', _Object$assign[sideX] = hasX ? '0' : '', _Object$assign.transform = (win.devicePixelRatio || 1) <= 1 ? \"translate(\" + x + \"px, \" + y + \"px)\" : \"translate3d(\" + x + \"px, \" + y + \"px, 0)\", _Object$assign));\n }\n\n return Object.assign({}, commonStyles, (_Object$assign2 = {}, _Object$assign2[sideY] = hasY ? y + \"px\" : '', _Object$assign2[sideX] = hasX ? x + \"px\" : '', _Object$assign2.transform = '', _Object$assign2));\n}\n\nfunction computeStyles(_ref5) {\n var state = _ref5.state,\n options = _ref5.options;\n var _options$gpuAccelerat = options.gpuAcceleration,\n gpuAcceleration = _options$gpuAccelerat === void 0 ? true : _options$gpuAccelerat,\n _options$adaptive = options.adaptive,\n adaptive = _options$adaptive === void 0 ? true : _options$adaptive,\n _options$roundOffsets = options.roundOffsets,\n roundOffsets = _options$roundOffsets === void 0 ? true : _options$roundOffsets;\n var commonStyles = {\n placement: getBasePlacement(state.placement),\n variation: getVariation(state.placement),\n popper: state.elements.popper,\n popperRect: state.rects.popper,\n gpuAcceleration: gpuAcceleration,\n isFixed: state.options.strategy === 'fixed'\n };\n\n if (state.modifiersData.popperOffsets != null) {\n state.styles.popper = Object.assign({}, state.styles.popper, mapToStyles(Object.assign({}, commonStyles, {\n offsets: state.modifiersData.popperOffsets,\n position: state.options.strategy,\n adaptive: adaptive,\n roundOffsets: roundOffsets\n })));\n }\n\n if (state.modifiersData.arrow != null) {\n state.styles.arrow = Object.assign({}, state.styles.arrow, mapToStyles(Object.assign({}, commonStyles, {\n offsets: state.modifiersData.arrow,\n position: 'absolute',\n adaptive: false,\n roundOffsets: roundOffsets\n })));\n }\n\n state.attributes.popper = Object.assign({}, state.attributes.popper, {\n 'data-popper-placement': state.placement\n });\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'computeStyles',\n enabled: true,\n phase: 'beforeWrite',\n fn: computeStyles,\n data: {}\n};","import getWindow from \"../dom-utils/getWindow.js\"; // eslint-disable-next-line import/no-unused-modules\n\nvar passive = {\n passive: true\n};\n\nfunction effect(_ref) {\n var state = _ref.state,\n instance = _ref.instance,\n options = _ref.options;\n var _options$scroll = options.scroll,\n scroll = _options$scroll === void 0 ? true : _options$scroll,\n _options$resize = options.resize,\n resize = _options$resize === void 0 ? true : _options$resize;\n var window = getWindow(state.elements.popper);\n var scrollParents = [].concat(state.scrollParents.reference, state.scrollParents.popper);\n\n if (scroll) {\n scrollParents.forEach(function (scrollParent) {\n scrollParent.addEventListener('scroll', instance.update, passive);\n });\n }\n\n if (resize) {\n window.addEventListener('resize', instance.update, passive);\n }\n\n return function () {\n if (scroll) {\n scrollParents.forEach(function (scrollParent) {\n scrollParent.removeEventListener('scroll', instance.update, passive);\n });\n }\n\n if (resize) {\n window.removeEventListener('resize', instance.update, passive);\n }\n };\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'eventListeners',\n enabled: true,\n phase: 'write',\n fn: function fn() {},\n effect: effect,\n data: {}\n};","var hash = {\n left: 'right',\n right: 'left',\n bottom: 'top',\n top: 'bottom'\n};\nexport default function getOppositePlacement(placement) {\n return placement.replace(/left|right|bottom|top/g, function (matched) {\n return hash[matched];\n });\n}","var hash = {\n start: 'end',\n end: 'start'\n};\nexport default function getOppositeVariationPlacement(placement) {\n return placement.replace(/start|end/g, function (matched) {\n return hash[matched];\n });\n}","import getWindow from \"./getWindow.js\";\nexport default function getWindowScroll(node) {\n var win = getWindow(node);\n var scrollLeft = win.pageXOffset;\n var scrollTop = win.pageYOffset;\n return {\n scrollLeft: scrollLeft,\n scrollTop: scrollTop\n };\n}","import getBoundingClientRect from \"./getBoundingClientRect.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport getWindowScroll from \"./getWindowScroll.js\";\nexport default function getWindowScrollBarX(element) {\n // If has a CSS width greater than the viewport, then this will be\n // incorrect for RTL.\n // Popper 1 is broken in this case and never had a bug report so let's assume\n // it's not an issue. I don't think anyone ever specifies width on \n // anyway.\n // Browsers where the left scrollbar doesn't cause an issue report `0` for\n // this (e.g. Edge 2019, IE11, Safari)\n return getBoundingClientRect(getDocumentElement(element)).left + getWindowScroll(element).scrollLeft;\n}","import getWindow from \"./getWindow.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport getWindowScrollBarX from \"./getWindowScrollBarX.js\";\nimport isLayoutViewport from \"./isLayoutViewport.js\";\nexport default function getViewportRect(element, strategy) {\n var win = getWindow(element);\n var html = getDocumentElement(element);\n var visualViewport = win.visualViewport;\n var width = html.clientWidth;\n var height = html.clientHeight;\n var x = 0;\n var y = 0;\n\n if (visualViewport) {\n width = visualViewport.width;\n height = visualViewport.height;\n var layoutViewport = isLayoutViewport();\n\n if (layoutViewport || !layoutViewport && strategy === 'fixed') {\n x = visualViewport.offsetLeft;\n y = visualViewport.offsetTop;\n }\n }\n\n return {\n width: width,\n height: height,\n x: x + getWindowScrollBarX(element),\n y: y\n };\n}","import getDocumentElement from \"./getDocumentElement.js\";\nimport getComputedStyle from \"./getComputedStyle.js\";\nimport getWindowScrollBarX from \"./getWindowScrollBarX.js\";\nimport getWindowScroll from \"./getWindowScroll.js\";\nimport { max } from \"../utils/math.js\"; // Gets the entire size of the scrollable document area, even extending outside\n// of the `` and `` rect bounds if horizontally scrollable\n\nexport default function getDocumentRect(element) {\n var _element$ownerDocumen;\n\n var html = getDocumentElement(element);\n var winScroll = getWindowScroll(element);\n var body = (_element$ownerDocumen = element.ownerDocument) == null ? void 0 : _element$ownerDocumen.body;\n var width = max(html.scrollWidth, html.clientWidth, body ? body.scrollWidth : 0, body ? body.clientWidth : 0);\n var height = max(html.scrollHeight, html.clientHeight, body ? body.scrollHeight : 0, body ? body.clientHeight : 0);\n var x = -winScroll.scrollLeft + getWindowScrollBarX(element);\n var y = -winScroll.scrollTop;\n\n if (getComputedStyle(body || html).direction === 'rtl') {\n x += max(html.clientWidth, body ? body.clientWidth : 0) - width;\n }\n\n return {\n width: width,\n height: height,\n x: x,\n y: y\n };\n}","import getComputedStyle from \"./getComputedStyle.js\";\nexport default function isScrollParent(element) {\n // Firefox wants us to check `-x` and `-y` variations as well\n var _getComputedStyle = getComputedStyle(element),\n overflow = _getComputedStyle.overflow,\n overflowX = _getComputedStyle.overflowX,\n overflowY = _getComputedStyle.overflowY;\n\n return /auto|scroll|overlay|hidden/.test(overflow + overflowY + overflowX);\n}","import getParentNode from \"./getParentNode.js\";\nimport isScrollParent from \"./isScrollParent.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport { isHTMLElement } from \"./instanceOf.js\";\nexport default function getScrollParent(node) {\n if (['html', 'body', '#document'].indexOf(getNodeName(node)) >= 0) {\n // $FlowFixMe[incompatible-return]: assume body is always available\n return node.ownerDocument.body;\n }\n\n if (isHTMLElement(node) && isScrollParent(node)) {\n return node;\n }\n\n return getScrollParent(getParentNode(node));\n}","import getScrollParent from \"./getScrollParent.js\";\nimport getParentNode from \"./getParentNode.js\";\nimport getWindow from \"./getWindow.js\";\nimport isScrollParent from \"./isScrollParent.js\";\n/*\ngiven a DOM element, return the list of all scroll parents, up the list of ancesors\nuntil we get to the top window object. This list is what we attach scroll listeners\nto, because if any of these parent elements scroll, we'll need to re-calculate the\nreference element's position.\n*/\n\nexport default function listScrollParents(element, list) {\n var _element$ownerDocumen;\n\n if (list === void 0) {\n list = [];\n }\n\n var scrollParent = getScrollParent(element);\n var isBody = scrollParent === ((_element$ownerDocumen = element.ownerDocument) == null ? void 0 : _element$ownerDocumen.body);\n var win = getWindow(scrollParent);\n var target = isBody ? [win].concat(win.visualViewport || [], isScrollParent(scrollParent) ? scrollParent : []) : scrollParent;\n var updatedList = list.concat(target);\n return isBody ? updatedList : // $FlowFixMe[incompatible-call]: isBody tells us target will be an HTMLElement here\n updatedList.concat(listScrollParents(getParentNode(target)));\n}","export default function rectToClientRect(rect) {\n return Object.assign({}, rect, {\n left: rect.x,\n top: rect.y,\n right: rect.x + rect.width,\n bottom: rect.y + rect.height\n });\n}","import { viewport } from \"../enums.js\";\nimport getViewportRect from \"./getViewportRect.js\";\nimport getDocumentRect from \"./getDocumentRect.js\";\nimport listScrollParents from \"./listScrollParents.js\";\nimport getOffsetParent from \"./getOffsetParent.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport getComputedStyle from \"./getComputedStyle.js\";\nimport { isElement, isHTMLElement } from \"./instanceOf.js\";\nimport getBoundingClientRect from \"./getBoundingClientRect.js\";\nimport getParentNode from \"./getParentNode.js\";\nimport contains from \"./contains.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport rectToClientRect from \"../utils/rectToClientRect.js\";\nimport { max, min } from \"../utils/math.js\";\n\nfunction getInnerBoundingClientRect(element, strategy) {\n var rect = getBoundingClientRect(element, false, strategy === 'fixed');\n rect.top = rect.top + element.clientTop;\n rect.left = rect.left + element.clientLeft;\n rect.bottom = rect.top + element.clientHeight;\n rect.right = rect.left + element.clientWidth;\n rect.width = element.clientWidth;\n rect.height = element.clientHeight;\n rect.x = rect.left;\n rect.y = rect.top;\n return rect;\n}\n\nfunction getClientRectFromMixedType(element, clippingParent, strategy) {\n return clippingParent === viewport ? rectToClientRect(getViewportRect(element, strategy)) : isElement(clippingParent) ? getInnerBoundingClientRect(clippingParent, strategy) : rectToClientRect(getDocumentRect(getDocumentElement(element)));\n} // A \"clipping parent\" is an overflowable container with the characteristic of\n// clipping (or hiding) overflowing elements with a position different from\n// `initial`\n\n\nfunction getClippingParents(element) {\n var clippingParents = listScrollParents(getParentNode(element));\n var canEscapeClipping = ['absolute', 'fixed'].indexOf(getComputedStyle(element).position) >= 0;\n var clipperElement = canEscapeClipping && isHTMLElement(element) ? getOffsetParent(element) : element;\n\n if (!isElement(clipperElement)) {\n return [];\n } // $FlowFixMe[incompatible-return]: https://github.com/facebook/flow/issues/1414\n\n\n return clippingParents.filter(function (clippingParent) {\n return isElement(clippingParent) && contains(clippingParent, clipperElement) && getNodeName(clippingParent) !== 'body';\n });\n} // Gets the maximum area that the element is visible in due to any number of\n// clipping parents\n\n\nexport default function getClippingRect(element, boundary, rootBoundary, strategy) {\n var mainClippingParents = boundary === 'clippingParents' ? getClippingParents(element) : [].concat(boundary);\n var clippingParents = [].concat(mainClippingParents, [rootBoundary]);\n var firstClippingParent = clippingParents[0];\n var clippingRect = clippingParents.reduce(function (accRect, clippingParent) {\n var rect = getClientRectFromMixedType(element, clippingParent, strategy);\n accRect.top = max(rect.top, accRect.top);\n accRect.right = min(rect.right, accRect.right);\n accRect.bottom = min(rect.bottom, accRect.bottom);\n accRect.left = max(rect.left, accRect.left);\n return accRect;\n }, getClientRectFromMixedType(element, firstClippingParent, strategy));\n clippingRect.width = clippingRect.right - clippingRect.left;\n clippingRect.height = clippingRect.bottom - clippingRect.top;\n clippingRect.x = clippingRect.left;\n clippingRect.y = clippingRect.top;\n return clippingRect;\n}","import getBasePlacement from \"./getBasePlacement.js\";\nimport getVariation from \"./getVariation.js\";\nimport getMainAxisFromPlacement from \"./getMainAxisFromPlacement.js\";\nimport { top, right, bottom, left, start, end } from \"../enums.js\";\nexport default function computeOffsets(_ref) {\n var reference = _ref.reference,\n element = _ref.element,\n placement = _ref.placement;\n var basePlacement = placement ? getBasePlacement(placement) : null;\n var variation = placement ? getVariation(placement) : null;\n var commonX = reference.x + reference.width / 2 - element.width / 2;\n var commonY = reference.y + reference.height / 2 - element.height / 2;\n var offsets;\n\n switch (basePlacement) {\n case top:\n offsets = {\n x: commonX,\n y: reference.y - element.height\n };\n break;\n\n case bottom:\n offsets = {\n x: commonX,\n y: reference.y + reference.height\n };\n break;\n\n case right:\n offsets = {\n x: reference.x + reference.width,\n y: commonY\n };\n break;\n\n case left:\n offsets = {\n x: reference.x - element.width,\n y: commonY\n };\n break;\n\n default:\n offsets = {\n x: reference.x,\n y: reference.y\n };\n }\n\n var mainAxis = basePlacement ? getMainAxisFromPlacement(basePlacement) : null;\n\n if (mainAxis != null) {\n var len = mainAxis === 'y' ? 'height' : 'width';\n\n switch (variation) {\n case start:\n offsets[mainAxis] = offsets[mainAxis] - (reference[len] / 2 - element[len] / 2);\n break;\n\n case end:\n offsets[mainAxis] = offsets[mainAxis] + (reference[len] / 2 - element[len] / 2);\n break;\n\n default:\n }\n }\n\n return offsets;\n}","import getClippingRect from \"../dom-utils/getClippingRect.js\";\nimport getDocumentElement from \"../dom-utils/getDocumentElement.js\";\nimport getBoundingClientRect from \"../dom-utils/getBoundingClientRect.js\";\nimport computeOffsets from \"./computeOffsets.js\";\nimport rectToClientRect from \"./rectToClientRect.js\";\nimport { clippingParents, reference, popper, bottom, top, right, basePlacements, viewport } from \"../enums.js\";\nimport { isElement } from \"../dom-utils/instanceOf.js\";\nimport mergePaddingObject from \"./mergePaddingObject.js\";\nimport expandToHashMap from \"./expandToHashMap.js\"; // eslint-disable-next-line import/no-unused-modules\n\nexport default function detectOverflow(state, options) {\n if (options === void 0) {\n options = {};\n }\n\n var _options = options,\n _options$placement = _options.placement,\n placement = _options$placement === void 0 ? state.placement : _options$placement,\n _options$strategy = _options.strategy,\n strategy = _options$strategy === void 0 ? state.strategy : _options$strategy,\n _options$boundary = _options.boundary,\n boundary = _options$boundary === void 0 ? clippingParents : _options$boundary,\n _options$rootBoundary = _options.rootBoundary,\n rootBoundary = _options$rootBoundary === void 0 ? viewport : _options$rootBoundary,\n _options$elementConte = _options.elementContext,\n elementContext = _options$elementConte === void 0 ? popper : _options$elementConte,\n _options$altBoundary = _options.altBoundary,\n altBoundary = _options$altBoundary === void 0 ? false : _options$altBoundary,\n _options$padding = _options.padding,\n padding = _options$padding === void 0 ? 0 : _options$padding;\n var paddingObject = mergePaddingObject(typeof padding !== 'number' ? padding : expandToHashMap(padding, basePlacements));\n var altContext = elementContext === popper ? reference : popper;\n var popperRect = state.rects.popper;\n var element = state.elements[altBoundary ? altContext : elementContext];\n var clippingClientRect = getClippingRect(isElement(element) ? element : element.contextElement || getDocumentElement(state.elements.popper), boundary, rootBoundary, strategy);\n var referenceClientRect = getBoundingClientRect(state.elements.reference);\n var popperOffsets = computeOffsets({\n reference: referenceClientRect,\n element: popperRect,\n strategy: 'absolute',\n placement: placement\n });\n var popperClientRect = rectToClientRect(Object.assign({}, popperRect, popperOffsets));\n var elementClientRect = elementContext === popper ? popperClientRect : referenceClientRect; // positive = overflowing the clipping rect\n // 0 or negative = within the clipping rect\n\n var overflowOffsets = {\n top: clippingClientRect.top - elementClientRect.top + paddingObject.top,\n bottom: elementClientRect.bottom - clippingClientRect.bottom + paddingObject.bottom,\n left: clippingClientRect.left - elementClientRect.left + paddingObject.left,\n right: elementClientRect.right - clippingClientRect.right + paddingObject.right\n };\n var offsetData = state.modifiersData.offset; // Offsets can be applied only to the popper element\n\n if (elementContext === popper && offsetData) {\n var offset = offsetData[placement];\n Object.keys(overflowOffsets).forEach(function (key) {\n var multiply = [right, bottom].indexOf(key) >= 0 ? 1 : -1;\n var axis = [top, bottom].indexOf(key) >= 0 ? 'y' : 'x';\n overflowOffsets[key] += offset[axis] * multiply;\n });\n }\n\n return overflowOffsets;\n}","import getVariation from \"./getVariation.js\";\nimport { variationPlacements, basePlacements, placements as allPlacements } from \"../enums.js\";\nimport detectOverflow from \"./detectOverflow.js\";\nimport getBasePlacement from \"./getBasePlacement.js\";\nexport default function computeAutoPlacement(state, options) {\n if (options === void 0) {\n options = {};\n }\n\n var _options = options,\n placement = _options.placement,\n boundary = _options.boundary,\n rootBoundary = _options.rootBoundary,\n padding = _options.padding,\n flipVariations = _options.flipVariations,\n _options$allowedAutoP = _options.allowedAutoPlacements,\n allowedAutoPlacements = _options$allowedAutoP === void 0 ? allPlacements : _options$allowedAutoP;\n var variation = getVariation(placement);\n var placements = variation ? flipVariations ? variationPlacements : variationPlacements.filter(function (placement) {\n return getVariation(placement) === variation;\n }) : basePlacements;\n var allowedPlacements = placements.filter(function (placement) {\n return allowedAutoPlacements.indexOf(placement) >= 0;\n });\n\n if (allowedPlacements.length === 0) {\n allowedPlacements = placements;\n } // $FlowFixMe[incompatible-type]: Flow seems to have problems with two array unions...\n\n\n var overflows = allowedPlacements.reduce(function (acc, placement) {\n acc[placement] = detectOverflow(state, {\n placement: placement,\n boundary: boundary,\n rootBoundary: rootBoundary,\n padding: padding\n })[getBasePlacement(placement)];\n return acc;\n }, {});\n return Object.keys(overflows).sort(function (a, b) {\n return overflows[a] - overflows[b];\n });\n}","import getOppositePlacement from \"../utils/getOppositePlacement.js\";\nimport getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getOppositeVariationPlacement from \"../utils/getOppositeVariationPlacement.js\";\nimport detectOverflow from \"../utils/detectOverflow.js\";\nimport computeAutoPlacement from \"../utils/computeAutoPlacement.js\";\nimport { bottom, top, start, right, left, auto } from \"../enums.js\";\nimport getVariation from \"../utils/getVariation.js\"; // eslint-disable-next-line import/no-unused-modules\n\nfunction getExpandedFallbackPlacements(placement) {\n if (getBasePlacement(placement) === auto) {\n return [];\n }\n\n var oppositePlacement = getOppositePlacement(placement);\n return [getOppositeVariationPlacement(placement), oppositePlacement, getOppositeVariationPlacement(oppositePlacement)];\n}\n\nfunction flip(_ref) {\n var state = _ref.state,\n options = _ref.options,\n name = _ref.name;\n\n if (state.modifiersData[name]._skip) {\n return;\n }\n\n var _options$mainAxis = options.mainAxis,\n checkMainAxis = _options$mainAxis === void 0 ? true : _options$mainAxis,\n _options$altAxis = options.altAxis,\n checkAltAxis = _options$altAxis === void 0 ? true : _options$altAxis,\n specifiedFallbackPlacements = options.fallbackPlacements,\n padding = options.padding,\n boundary = options.boundary,\n rootBoundary = options.rootBoundary,\n altBoundary = options.altBoundary,\n _options$flipVariatio = options.flipVariations,\n flipVariations = _options$flipVariatio === void 0 ? true : _options$flipVariatio,\n allowedAutoPlacements = options.allowedAutoPlacements;\n var preferredPlacement = state.options.placement;\n var basePlacement = getBasePlacement(preferredPlacement);\n var isBasePlacement = basePlacement === preferredPlacement;\n var fallbackPlacements = specifiedFallbackPlacements || (isBasePlacement || !flipVariations ? [getOppositePlacement(preferredPlacement)] : getExpandedFallbackPlacements(preferredPlacement));\n var placements = [preferredPlacement].concat(fallbackPlacements).reduce(function (acc, placement) {\n return acc.concat(getBasePlacement(placement) === auto ? computeAutoPlacement(state, {\n placement: placement,\n boundary: boundary,\n rootBoundary: rootBoundary,\n padding: padding,\n flipVariations: flipVariations,\n allowedAutoPlacements: allowedAutoPlacements\n }) : placement);\n }, []);\n var referenceRect = state.rects.reference;\n var popperRect = state.rects.popper;\n var checksMap = new Map();\n var makeFallbackChecks = true;\n var firstFittingPlacement = placements[0];\n\n for (var i = 0; i < placements.length; i++) {\n var placement = placements[i];\n\n var _basePlacement = getBasePlacement(placement);\n\n var isStartVariation = getVariation(placement) === start;\n var isVertical = [top, bottom].indexOf(_basePlacement) >= 0;\n var len = isVertical ? 'width' : 'height';\n var overflow = detectOverflow(state, {\n placement: placement,\n boundary: boundary,\n rootBoundary: rootBoundary,\n altBoundary: altBoundary,\n padding: padding\n });\n var mainVariationSide = isVertical ? isStartVariation ? right : left : isStartVariation ? bottom : top;\n\n if (referenceRect[len] > popperRect[len]) {\n mainVariationSide = getOppositePlacement(mainVariationSide);\n }\n\n var altVariationSide = getOppositePlacement(mainVariationSide);\n var checks = [];\n\n if (checkMainAxis) {\n checks.push(overflow[_basePlacement] <= 0);\n }\n\n if (checkAltAxis) {\n checks.push(overflow[mainVariationSide] <= 0, overflow[altVariationSide] <= 0);\n }\n\n if (checks.every(function (check) {\n return check;\n })) {\n firstFittingPlacement = placement;\n makeFallbackChecks = false;\n break;\n }\n\n checksMap.set(placement, checks);\n }\n\n if (makeFallbackChecks) {\n // `2` may be desired in some cases – research later\n var numberOfChecks = flipVariations ? 3 : 1;\n\n var _loop = function _loop(_i) {\n var fittingPlacement = placements.find(function (placement) {\n var checks = checksMap.get(placement);\n\n if (checks) {\n return checks.slice(0, _i).every(function (check) {\n return check;\n });\n }\n });\n\n if (fittingPlacement) {\n firstFittingPlacement = fittingPlacement;\n return \"break\";\n }\n };\n\n for (var _i = numberOfChecks; _i > 0; _i--) {\n var _ret = _loop(_i);\n\n if (_ret === \"break\") break;\n }\n }\n\n if (state.placement !== firstFittingPlacement) {\n state.modifiersData[name]._skip = true;\n state.placement = firstFittingPlacement;\n state.reset = true;\n }\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'flip',\n enabled: true,\n phase: 'main',\n fn: flip,\n requiresIfExists: ['offset'],\n data: {\n _skip: false\n }\n};","import { top, bottom, left, right } from \"../enums.js\";\nimport detectOverflow from \"../utils/detectOverflow.js\";\n\nfunction getSideOffsets(overflow, rect, preventedOffsets) {\n if (preventedOffsets === void 0) {\n preventedOffsets = {\n x: 0,\n y: 0\n };\n }\n\n return {\n top: overflow.top - rect.height - preventedOffsets.y,\n right: overflow.right - rect.width + preventedOffsets.x,\n bottom: overflow.bottom - rect.height + preventedOffsets.y,\n left: overflow.left - rect.width - preventedOffsets.x\n };\n}\n\nfunction isAnySideFullyClipped(overflow) {\n return [top, right, bottom, left].some(function (side) {\n return overflow[side] >= 0;\n });\n}\n\nfunction hide(_ref) {\n var state = _ref.state,\n name = _ref.name;\n var referenceRect = state.rects.reference;\n var popperRect = state.rects.popper;\n var preventedOffsets = state.modifiersData.preventOverflow;\n var referenceOverflow = detectOverflow(state, {\n elementContext: 'reference'\n });\n var popperAltOverflow = detectOverflow(state, {\n altBoundary: true\n });\n var referenceClippingOffsets = getSideOffsets(referenceOverflow, referenceRect);\n var popperEscapeOffsets = getSideOffsets(popperAltOverflow, popperRect, preventedOffsets);\n var isReferenceHidden = isAnySideFullyClipped(referenceClippingOffsets);\n var hasPopperEscaped = isAnySideFullyClipped(popperEscapeOffsets);\n state.modifiersData[name] = {\n referenceClippingOffsets: referenceClippingOffsets,\n popperEscapeOffsets: popperEscapeOffsets,\n isReferenceHidden: isReferenceHidden,\n hasPopperEscaped: hasPopperEscaped\n };\n state.attributes.popper = Object.assign({}, state.attributes.popper, {\n 'data-popper-reference-hidden': isReferenceHidden,\n 'data-popper-escaped': hasPopperEscaped\n });\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'hide',\n enabled: true,\n phase: 'main',\n requiresIfExists: ['preventOverflow'],\n fn: hide\n};","import getBasePlacement from \"../utils/getBasePlacement.js\";\nimport { top, left, right, placements } from \"../enums.js\"; // eslint-disable-next-line import/no-unused-modules\n\nexport function distanceAndSkiddingToXY(placement, rects, offset) {\n var basePlacement = getBasePlacement(placement);\n var invertDistance = [left, top].indexOf(basePlacement) >= 0 ? -1 : 1;\n\n var _ref = typeof offset === 'function' ? offset(Object.assign({}, rects, {\n placement: placement\n })) : offset,\n skidding = _ref[0],\n distance = _ref[1];\n\n skidding = skidding || 0;\n distance = (distance || 0) * invertDistance;\n return [left, right].indexOf(basePlacement) >= 0 ? {\n x: distance,\n y: skidding\n } : {\n x: skidding,\n y: distance\n };\n}\n\nfunction offset(_ref2) {\n var state = _ref2.state,\n options = _ref2.options,\n name = _ref2.name;\n var _options$offset = options.offset,\n offset = _options$offset === void 0 ? [0, 0] : _options$offset;\n var data = placements.reduce(function (acc, placement) {\n acc[placement] = distanceAndSkiddingToXY(placement, state.rects, offset);\n return acc;\n }, {});\n var _data$state$placement = data[state.placement],\n x = _data$state$placement.x,\n y = _data$state$placement.y;\n\n if (state.modifiersData.popperOffsets != null) {\n state.modifiersData.popperOffsets.x += x;\n state.modifiersData.popperOffsets.y += y;\n }\n\n state.modifiersData[name] = data;\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'offset',\n enabled: true,\n phase: 'main',\n requires: ['popperOffsets'],\n fn: offset\n};","import computeOffsets from \"../utils/computeOffsets.js\";\n\nfunction popperOffsets(_ref) {\n var state = _ref.state,\n name = _ref.name;\n // Offsets are the actual position the popper needs to have to be\n // properly positioned near its reference element\n // This is the most basic placement, and will be adjusted by\n // the modifiers in the next step\n state.modifiersData[name] = computeOffsets({\n reference: state.rects.reference,\n element: state.rects.popper,\n strategy: 'absolute',\n placement: state.placement\n });\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'popperOffsets',\n enabled: true,\n phase: 'read',\n fn: popperOffsets,\n data: {}\n};","export default function getAltAxis(axis) {\n return axis === 'x' ? 'y' : 'x';\n}","import { top, left, right, bottom, start } from \"../enums.js\";\nimport getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getMainAxisFromPlacement from \"../utils/getMainAxisFromPlacement.js\";\nimport getAltAxis from \"../utils/getAltAxis.js\";\nimport { within, withinMaxClamp } from \"../utils/within.js\";\nimport getLayoutRect from \"../dom-utils/getLayoutRect.js\";\nimport getOffsetParent from \"../dom-utils/getOffsetParent.js\";\nimport detectOverflow from \"../utils/detectOverflow.js\";\nimport getVariation from \"../utils/getVariation.js\";\nimport getFreshSideObject from \"../utils/getFreshSideObject.js\";\nimport { min as mathMin, max as mathMax } from \"../utils/math.js\";\n\nfunction preventOverflow(_ref) {\n var state = _ref.state,\n options = _ref.options,\n name = _ref.name;\n var _options$mainAxis = options.mainAxis,\n checkMainAxis = _options$mainAxis === void 0 ? true : _options$mainAxis,\n _options$altAxis = options.altAxis,\n checkAltAxis = _options$altAxis === void 0 ? false : _options$altAxis,\n boundary = options.boundary,\n rootBoundary = options.rootBoundary,\n altBoundary = options.altBoundary,\n padding = options.padding,\n _options$tether = options.tether,\n tether = _options$tether === void 0 ? true : _options$tether,\n _options$tetherOffset = options.tetherOffset,\n tetherOffset = _options$tetherOffset === void 0 ? 0 : _options$tetherOffset;\n var overflow = detectOverflow(state, {\n boundary: boundary,\n rootBoundary: rootBoundary,\n padding: padding,\n altBoundary: altBoundary\n });\n var basePlacement = getBasePlacement(state.placement);\n var variation = getVariation(state.placement);\n var isBasePlacement = !variation;\n var mainAxis = getMainAxisFromPlacement(basePlacement);\n var altAxis = getAltAxis(mainAxis);\n var popperOffsets = state.modifiersData.popperOffsets;\n var referenceRect = state.rects.reference;\n var popperRect = state.rects.popper;\n var tetherOffsetValue = typeof tetherOffset === 'function' ? tetherOffset(Object.assign({}, state.rects, {\n placement: state.placement\n })) : tetherOffset;\n var normalizedTetherOffsetValue = typeof tetherOffsetValue === 'number' ? {\n mainAxis: tetherOffsetValue,\n altAxis: tetherOffsetValue\n } : Object.assign({\n mainAxis: 0,\n altAxis: 0\n }, tetherOffsetValue);\n var offsetModifierState = state.modifiersData.offset ? state.modifiersData.offset[state.placement] : null;\n var data = {\n x: 0,\n y: 0\n };\n\n if (!popperOffsets) {\n return;\n }\n\n if (checkMainAxis) {\n var _offsetModifierState$;\n\n var mainSide = mainAxis === 'y' ? top : left;\n var altSide = mainAxis === 'y' ? bottom : right;\n var len = mainAxis === 'y' ? 'height' : 'width';\n var offset = popperOffsets[mainAxis];\n var min = offset + overflow[mainSide];\n var max = offset - overflow[altSide];\n var additive = tether ? -popperRect[len] / 2 : 0;\n var minLen = variation === start ? referenceRect[len] : popperRect[len];\n var maxLen = variation === start ? -popperRect[len] : -referenceRect[len]; // We need to include the arrow in the calculation so the arrow doesn't go\n // outside the reference bounds\n\n var arrowElement = state.elements.arrow;\n var arrowRect = tether && arrowElement ? getLayoutRect(arrowElement) : {\n width: 0,\n height: 0\n };\n var arrowPaddingObject = state.modifiersData['arrow#persistent'] ? state.modifiersData['arrow#persistent'].padding : getFreshSideObject();\n var arrowPaddingMin = arrowPaddingObject[mainSide];\n var arrowPaddingMax = arrowPaddingObject[altSide]; // If the reference length is smaller than the arrow length, we don't want\n // to include its full size in the calculation. If the reference is small\n // and near the edge of a boundary, the popper can overflow even if the\n // reference is not overflowing as well (e.g. virtual elements with no\n // width or height)\n\n var arrowLen = within(0, referenceRect[len], arrowRect[len]);\n var minOffset = isBasePlacement ? referenceRect[len] / 2 - additive - arrowLen - arrowPaddingMin - normalizedTetherOffsetValue.mainAxis : minLen - arrowLen - arrowPaddingMin - normalizedTetherOffsetValue.mainAxis;\n var maxOffset = isBasePlacement ? -referenceRect[len] / 2 + additive + arrowLen + arrowPaddingMax + normalizedTetherOffsetValue.mainAxis : maxLen + arrowLen + arrowPaddingMax + normalizedTetherOffsetValue.mainAxis;\n var arrowOffsetParent = state.elements.arrow && getOffsetParent(state.elements.arrow);\n var clientOffset = arrowOffsetParent ? mainAxis === 'y' ? arrowOffsetParent.clientTop || 0 : arrowOffsetParent.clientLeft || 0 : 0;\n var offsetModifierValue = (_offsetModifierState$ = offsetModifierState == null ? void 0 : offsetModifierState[mainAxis]) != null ? _offsetModifierState$ : 0;\n var tetherMin = offset + minOffset - offsetModifierValue - clientOffset;\n var tetherMax = offset + maxOffset - offsetModifierValue;\n var preventedOffset = within(tether ? mathMin(min, tetherMin) : min, offset, tether ? mathMax(max, tetherMax) : max);\n popperOffsets[mainAxis] = preventedOffset;\n data[mainAxis] = preventedOffset - offset;\n }\n\n if (checkAltAxis) {\n var _offsetModifierState$2;\n\n var _mainSide = mainAxis === 'x' ? top : left;\n\n var _altSide = mainAxis === 'x' ? bottom : right;\n\n var _offset = popperOffsets[altAxis];\n\n var _len = altAxis === 'y' ? 'height' : 'width';\n\n var _min = _offset + overflow[_mainSide];\n\n var _max = _offset - overflow[_altSide];\n\n var isOriginSide = [top, left].indexOf(basePlacement) !== -1;\n\n var _offsetModifierValue = (_offsetModifierState$2 = offsetModifierState == null ? void 0 : offsetModifierState[altAxis]) != null ? _offsetModifierState$2 : 0;\n\n var _tetherMin = isOriginSide ? _min : _offset - referenceRect[_len] - popperRect[_len] - _offsetModifierValue + normalizedTetherOffsetValue.altAxis;\n\n var _tetherMax = isOriginSide ? _offset + referenceRect[_len] + popperRect[_len] - _offsetModifierValue - normalizedTetherOffsetValue.altAxis : _max;\n\n var _preventedOffset = tether && isOriginSide ? withinMaxClamp(_tetherMin, _offset, _tetherMax) : within(tether ? _tetherMin : _min, _offset, tether ? _tetherMax : _max);\n\n popperOffsets[altAxis] = _preventedOffset;\n data[altAxis] = _preventedOffset - _offset;\n }\n\n state.modifiersData[name] = data;\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'preventOverflow',\n enabled: true,\n phase: 'main',\n fn: preventOverflow,\n requiresIfExists: ['offset']\n};","export default function getHTMLElementScroll(element) {\n return {\n scrollLeft: element.scrollLeft,\n scrollTop: element.scrollTop\n };\n}","import getWindowScroll from \"./getWindowScroll.js\";\nimport getWindow from \"./getWindow.js\";\nimport { isHTMLElement } from \"./instanceOf.js\";\nimport getHTMLElementScroll from \"./getHTMLElementScroll.js\";\nexport default function getNodeScroll(node) {\n if (node === getWindow(node) || !isHTMLElement(node)) {\n return getWindowScroll(node);\n } else {\n return getHTMLElementScroll(node);\n }\n}","import getBoundingClientRect from \"./getBoundingClientRect.js\";\nimport getNodeScroll from \"./getNodeScroll.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport { isHTMLElement } from \"./instanceOf.js\";\nimport getWindowScrollBarX from \"./getWindowScrollBarX.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport isScrollParent from \"./isScrollParent.js\";\nimport { round } from \"../utils/math.js\";\n\nfunction isElementScaled(element) {\n var rect = element.getBoundingClientRect();\n var scaleX = round(rect.width) / element.offsetWidth || 1;\n var scaleY = round(rect.height) / element.offsetHeight || 1;\n return scaleX !== 1 || scaleY !== 1;\n} // Returns the composite rect of an element relative to its offsetParent.\n// Composite means it takes into account transforms as well as layout.\n\n\nexport default function getCompositeRect(elementOrVirtualElement, offsetParent, isFixed) {\n if (isFixed === void 0) {\n isFixed = false;\n }\n\n var isOffsetParentAnElement = isHTMLElement(offsetParent);\n var offsetParentIsScaled = isHTMLElement(offsetParent) && isElementScaled(offsetParent);\n var documentElement = getDocumentElement(offsetParent);\n var rect = getBoundingClientRect(elementOrVirtualElement, offsetParentIsScaled, isFixed);\n var scroll = {\n scrollLeft: 0,\n scrollTop: 0\n };\n var offsets = {\n x: 0,\n y: 0\n };\n\n if (isOffsetParentAnElement || !isOffsetParentAnElement && !isFixed) {\n if (getNodeName(offsetParent) !== 'body' || // https://github.com/popperjs/popper-core/issues/1078\n isScrollParent(documentElement)) {\n scroll = getNodeScroll(offsetParent);\n }\n\n if (isHTMLElement(offsetParent)) {\n offsets = getBoundingClientRect(offsetParent, true);\n offsets.x += offsetParent.clientLeft;\n offsets.y += offsetParent.clientTop;\n } else if (documentElement) {\n offsets.x = getWindowScrollBarX(documentElement);\n }\n }\n\n return {\n x: rect.left + scroll.scrollLeft - offsets.x,\n y: rect.top + scroll.scrollTop - offsets.y,\n width: rect.width,\n height: rect.height\n };\n}","import { modifierPhases } from \"../enums.js\"; // source: https://stackoverflow.com/questions/49875255\n\nfunction order(modifiers) {\n var map = new Map();\n var visited = new Set();\n var result = [];\n modifiers.forEach(function (modifier) {\n map.set(modifier.name, modifier);\n }); // On visiting object, check for its dependencies and visit them recursively\n\n function sort(modifier) {\n visited.add(modifier.name);\n var requires = [].concat(modifier.requires || [], modifier.requiresIfExists || []);\n requires.forEach(function (dep) {\n if (!visited.has(dep)) {\n var depModifier = map.get(dep);\n\n if (depModifier) {\n sort(depModifier);\n }\n }\n });\n result.push(modifier);\n }\n\n modifiers.forEach(function (modifier) {\n if (!visited.has(modifier.name)) {\n // check for visited object\n sort(modifier);\n }\n });\n return result;\n}\n\nexport default function orderModifiers(modifiers) {\n // order based on dependencies\n var orderedModifiers = order(modifiers); // order based on phase\n\n return modifierPhases.reduce(function (acc, phase) {\n return acc.concat(orderedModifiers.filter(function (modifier) {\n return modifier.phase === phase;\n }));\n }, []);\n}","export default function debounce(fn) {\n var pending;\n return function () {\n if (!pending) {\n pending = new Promise(function (resolve) {\n Promise.resolve().then(function () {\n pending = undefined;\n resolve(fn());\n });\n });\n }\n\n return pending;\n };\n}","export default function mergeByName(modifiers) {\n var merged = modifiers.reduce(function (merged, current) {\n var existing = merged[current.name];\n merged[current.name] = existing ? Object.assign({}, existing, current, {\n options: Object.assign({}, existing.options, current.options),\n data: Object.assign({}, existing.data, current.data)\n }) : current;\n return merged;\n }, {}); // IE11 does not support Object.values\n\n return Object.keys(merged).map(function (key) {\n return merged[key];\n });\n}","import getCompositeRect from \"./dom-utils/getCompositeRect.js\";\nimport getLayoutRect from \"./dom-utils/getLayoutRect.js\";\nimport listScrollParents from \"./dom-utils/listScrollParents.js\";\nimport getOffsetParent from \"./dom-utils/getOffsetParent.js\";\nimport orderModifiers from \"./utils/orderModifiers.js\";\nimport debounce from \"./utils/debounce.js\";\nimport mergeByName from \"./utils/mergeByName.js\";\nimport detectOverflow from \"./utils/detectOverflow.js\";\nimport { isElement } from \"./dom-utils/instanceOf.js\";\nvar DEFAULT_OPTIONS = {\n placement: 'bottom',\n modifiers: [],\n strategy: 'absolute'\n};\n\nfunction areValidElements() {\n for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {\n args[_key] = arguments[_key];\n }\n\n return !args.some(function (element) {\n return !(element && typeof element.getBoundingClientRect === 'function');\n });\n}\n\nexport function popperGenerator(generatorOptions) {\n if (generatorOptions === void 0) {\n generatorOptions = {};\n }\n\n var _generatorOptions = generatorOptions,\n _generatorOptions$def = _generatorOptions.defaultModifiers,\n defaultModifiers = _generatorOptions$def === void 0 ? [] : _generatorOptions$def,\n _generatorOptions$def2 = _generatorOptions.defaultOptions,\n defaultOptions = _generatorOptions$def2 === void 0 ? DEFAULT_OPTIONS : _generatorOptions$def2;\n return function createPopper(reference, popper, options) {\n if (options === void 0) {\n options = defaultOptions;\n }\n\n var state = {\n placement: 'bottom',\n orderedModifiers: [],\n options: Object.assign({}, DEFAULT_OPTIONS, defaultOptions),\n modifiersData: {},\n elements: {\n reference: reference,\n popper: popper\n },\n attributes: {},\n styles: {}\n };\n var effectCleanupFns = [];\n var isDestroyed = false;\n var instance = {\n state: state,\n setOptions: function setOptions(setOptionsAction) {\n var options = typeof setOptionsAction === 'function' ? setOptionsAction(state.options) : setOptionsAction;\n cleanupModifierEffects();\n state.options = Object.assign({}, defaultOptions, state.options, options);\n state.scrollParents = {\n reference: isElement(reference) ? listScrollParents(reference) : reference.contextElement ? listScrollParents(reference.contextElement) : [],\n popper: listScrollParents(popper)\n }; // Orders the modifiers based on their dependencies and `phase`\n // properties\n\n var orderedModifiers = orderModifiers(mergeByName([].concat(defaultModifiers, state.options.modifiers))); // Strip out disabled modifiers\n\n state.orderedModifiers = orderedModifiers.filter(function (m) {\n return m.enabled;\n });\n runModifierEffects();\n return instance.update();\n },\n // Sync update – it will always be executed, even if not necessary. This\n // is useful for low frequency updates where sync behavior simplifies the\n // logic.\n // For high frequency updates (e.g. `resize` and `scroll` events), always\n // prefer the async Popper#update method\n forceUpdate: function forceUpdate() {\n if (isDestroyed) {\n return;\n }\n\n var _state$elements = state.elements,\n reference = _state$elements.reference,\n popper = _state$elements.popper; // Don't proceed if `reference` or `popper` are not valid elements\n // anymore\n\n if (!areValidElements(reference, popper)) {\n return;\n } // Store the reference and popper rects to be read by modifiers\n\n\n state.rects = {\n reference: getCompositeRect(reference, getOffsetParent(popper), state.options.strategy === 'fixed'),\n popper: getLayoutRect(popper)\n }; // Modifiers have the ability to reset the current update cycle. The\n // most common use case for this is the `flip` modifier changing the\n // placement, which then needs to re-run all the modifiers, because the\n // logic was previously ran for the previous placement and is therefore\n // stale/incorrect\n\n state.reset = false;\n state.placement = state.options.placement; // On each update cycle, the `modifiersData` property for each modifier\n // is filled with the initial data specified by the modifier. This means\n // it doesn't persist and is fresh on each update.\n // To ensure persistent data, use `${name}#persistent`\n\n state.orderedModifiers.forEach(function (modifier) {\n return state.modifiersData[modifier.name] = Object.assign({}, modifier.data);\n });\n\n for (var index = 0; index < state.orderedModifiers.length; index++) {\n if (state.reset === true) {\n state.reset = false;\n index = -1;\n continue;\n }\n\n var _state$orderedModifie = state.orderedModifiers[index],\n fn = _state$orderedModifie.fn,\n _state$orderedModifie2 = _state$orderedModifie.options,\n _options = _state$orderedModifie2 === void 0 ? {} : _state$orderedModifie2,\n name = _state$orderedModifie.name;\n\n if (typeof fn === 'function') {\n state = fn({\n state: state,\n options: _options,\n name: name,\n instance: instance\n }) || state;\n }\n }\n },\n // Async and optimistically optimized update – it will not be executed if\n // not necessary (debounced to run at most once-per-tick)\n update: debounce(function () {\n return new Promise(function (resolve) {\n instance.forceUpdate();\n resolve(state);\n });\n }),\n destroy: function destroy() {\n cleanupModifierEffects();\n isDestroyed = true;\n }\n };\n\n if (!areValidElements(reference, popper)) {\n return instance;\n }\n\n instance.setOptions(options).then(function (state) {\n if (!isDestroyed && options.onFirstUpdate) {\n options.onFirstUpdate(state);\n }\n }); // Modifiers have the ability to execute arbitrary code before the first\n // update cycle runs. They will be executed in the same order as the update\n // cycle. This is useful when a modifier adds some persistent data that\n // other modifiers need to use, but the modifier is run after the dependent\n // one.\n\n function runModifierEffects() {\n state.orderedModifiers.forEach(function (_ref) {\n var name = _ref.name,\n _ref$options = _ref.options,\n options = _ref$options === void 0 ? {} : _ref$options,\n effect = _ref.effect;\n\n if (typeof effect === 'function') {\n var cleanupFn = effect({\n state: state,\n name: name,\n instance: instance,\n options: options\n });\n\n var noopFn = function noopFn() {};\n\n effectCleanupFns.push(cleanupFn || noopFn);\n }\n });\n }\n\n function cleanupModifierEffects() {\n effectCleanupFns.forEach(function (fn) {\n return fn();\n });\n effectCleanupFns = [];\n }\n\n return instance;\n };\n}\nexport var createPopper = /*#__PURE__*/popperGenerator(); // eslint-disable-next-line import/no-unused-modules\n\nexport { detectOverflow };","import { popperGenerator, detectOverflow } from \"./createPopper.js\";\nimport eventListeners from \"./modifiers/eventListeners.js\";\nimport popperOffsets from \"./modifiers/popperOffsets.js\";\nimport computeStyles from \"./modifiers/computeStyles.js\";\nimport applyStyles from \"./modifiers/applyStyles.js\";\nimport offset from \"./modifiers/offset.js\";\nimport flip from \"./modifiers/flip.js\";\nimport preventOverflow from \"./modifiers/preventOverflow.js\";\nimport arrow from \"./modifiers/arrow.js\";\nimport hide from \"./modifiers/hide.js\";\nvar defaultModifiers = [eventListeners, popperOffsets, computeStyles, applyStyles, offset, flip, preventOverflow, arrow, hide];\nvar createPopper = /*#__PURE__*/popperGenerator({\n defaultModifiers: defaultModifiers\n}); // eslint-disable-next-line import/no-unused-modules\n\nexport { createPopper, popperGenerator, defaultModifiers, detectOverflow }; // eslint-disable-next-line import/no-unused-modules\n\nexport { createPopper as createPopperLite } from \"./popper-lite.js\"; // eslint-disable-next-line import/no-unused-modules\n\nexport * from \"./modifiers/index.js\";","import { generateUtilityClass } from '../generateUtilityClass';\nimport { generateUtilityClasses } from '../generateUtilityClasses';\nconst COMPONENT_NAME = 'Popper';\nexport function getPopperUtilityClass(slot) {\n return generateUtilityClass(COMPONENT_NAME, slot);\n}\nexport const popperClasses = generateUtilityClasses(COMPONENT_NAME, ['root']);","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"anchorEl\", \"children\", \"direction\", \"disablePortal\", \"modifiers\", \"open\", \"placement\", \"popperOptions\", \"popperRef\", \"slotProps\", \"slots\", \"TransitionProps\", \"ownerState\"],\n _excluded2 = [\"anchorEl\", \"children\", \"container\", \"direction\", \"disablePortal\", \"keepMounted\", \"modifiers\", \"open\", \"placement\", \"popperOptions\", \"popperRef\", \"style\", \"transition\", \"slotProps\", \"slots\"];\nimport * as React from 'react';\nimport { chainPropTypes, HTMLElementType, refType, unstable_ownerDocument as ownerDocument, unstable_useEnhancedEffect as useEnhancedEffect, unstable_useForkRef as useForkRef } from '@mui/utils';\nimport { createPopper } from '@popperjs/core';\nimport PropTypes from 'prop-types';\nimport { unstable_composeClasses as composeClasses } from '../composeClasses';\nimport { Portal } from '../Portal';\nimport { getPopperUtilityClass } from './popperClasses';\nimport { useSlotProps } from '../utils';\nimport { useClassNamesOverride } from '../utils/ClassNameConfigurator';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nfunction flipPlacement(placement, direction) {\n if (direction === 'ltr') {\n return placement;\n }\n switch (placement) {\n case 'bottom-end':\n return 'bottom-start';\n case 'bottom-start':\n return 'bottom-end';\n case 'top-end':\n return 'top-start';\n case 'top-start':\n return 'top-end';\n default:\n return placement;\n }\n}\nfunction resolveAnchorEl(anchorEl) {\n return typeof anchorEl === 'function' ? anchorEl() : anchorEl;\n}\nfunction isHTMLElement(element) {\n return element.nodeType !== undefined;\n}\nfunction isVirtualElement(element) {\n return !isHTMLElement(element);\n}\nconst useUtilityClasses = () => {\n const slots = {\n root: ['root']\n };\n return composeClasses(slots, useClassNamesOverride(getPopperUtilityClass));\n};\nconst defaultPopperOptions = {};\nconst PopperTooltip = /*#__PURE__*/React.forwardRef(function PopperTooltip(props, forwardedRef) {\n var _slots$root;\n const {\n anchorEl,\n children,\n direction,\n disablePortal,\n modifiers,\n open,\n placement: initialPlacement,\n popperOptions,\n popperRef: popperRefProp,\n slotProps = {},\n slots = {},\n TransitionProps\n // @ts-ignore internal logic\n // prevent from spreading to DOM, it can come from the parent component e.g. Select.\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const tooltipRef = React.useRef(null);\n const ownRef = useForkRef(tooltipRef, forwardedRef);\n const popperRef = React.useRef(null);\n const handlePopperRef = useForkRef(popperRef, popperRefProp);\n const handlePopperRefRef = React.useRef(handlePopperRef);\n useEnhancedEffect(() => {\n handlePopperRefRef.current = handlePopperRef;\n }, [handlePopperRef]);\n React.useImperativeHandle(popperRefProp, () => popperRef.current, []);\n const rtlPlacement = flipPlacement(initialPlacement, direction);\n /**\n * placement initialized from prop but can change during lifetime if modifiers.flip.\n * modifiers.flip is essentially a flip for controlled/uncontrolled behavior\n */\n const [placement, setPlacement] = React.useState(rtlPlacement);\n const [resolvedAnchorElement, setResolvedAnchorElement] = React.useState(resolveAnchorEl(anchorEl));\n React.useEffect(() => {\n if (popperRef.current) {\n popperRef.current.forceUpdate();\n }\n });\n React.useEffect(() => {\n if (anchorEl) {\n setResolvedAnchorElement(resolveAnchorEl(anchorEl));\n }\n }, [anchorEl]);\n useEnhancedEffect(() => {\n if (!resolvedAnchorElement || !open) {\n return undefined;\n }\n const handlePopperUpdate = data => {\n setPlacement(data.placement);\n };\n if (process.env.NODE_ENV !== 'production') {\n if (resolvedAnchorElement && isHTMLElement(resolvedAnchorElement) && resolvedAnchorElement.nodeType === 1) {\n const box = resolvedAnchorElement.getBoundingClientRect();\n if (process.env.NODE_ENV !== 'test' && box.top === 0 && box.left === 0 && box.right === 0 && box.bottom === 0) {\n console.warn(['MUI: The `anchorEl` prop provided to the component is invalid.', 'The anchor element should be part of the document layout.', \"Make sure the element is present in the document or that it's not display none.\"].join('\\n'));\n }\n }\n }\n let popperModifiers = [{\n name: 'preventOverflow',\n options: {\n altBoundary: disablePortal\n }\n }, {\n name: 'flip',\n options: {\n altBoundary: disablePortal\n }\n }, {\n name: 'onUpdate',\n enabled: true,\n phase: 'afterWrite',\n fn: ({\n state\n }) => {\n handlePopperUpdate(state);\n }\n }];\n if (modifiers != null) {\n popperModifiers = popperModifiers.concat(modifiers);\n }\n if (popperOptions && popperOptions.modifiers != null) {\n popperModifiers = popperModifiers.concat(popperOptions.modifiers);\n }\n const popper = createPopper(resolvedAnchorElement, tooltipRef.current, _extends({\n placement: rtlPlacement\n }, popperOptions, {\n modifiers: popperModifiers\n }));\n handlePopperRefRef.current(popper);\n return () => {\n popper.destroy();\n handlePopperRefRef.current(null);\n };\n }, [resolvedAnchorElement, disablePortal, modifiers, open, popperOptions, rtlPlacement]);\n const childProps = {\n placement: placement\n };\n if (TransitionProps !== null) {\n childProps.TransitionProps = TransitionProps;\n }\n const classes = useUtilityClasses();\n const Root = (_slots$root = slots.root) != null ? _slots$root : 'div';\n const rootProps = useSlotProps({\n elementType: Root,\n externalSlotProps: slotProps.root,\n externalForwardedProps: other,\n additionalProps: {\n role: 'tooltip',\n ref: ownRef\n },\n ownerState: props,\n className: classes.root\n });\n return /*#__PURE__*/_jsx(Root, _extends({}, rootProps, {\n children: typeof children === 'function' ? children(childProps) : children\n }));\n});\n\n/**\n * Poppers rely on the 3rd party library [Popper.js](https://popper.js.org/docs/v2/) for positioning.\n *\n * Demos:\n *\n * - [Popper](https://mui.com/base-ui/react-popper/)\n *\n * API:\n *\n * - [Popper API](https://mui.com/base-ui/react-popper/components-api/#popper)\n */\nconst Popper = /*#__PURE__*/React.forwardRef(function Popper(props, forwardedRef) {\n const {\n anchorEl,\n children,\n container: containerProp,\n direction = 'ltr',\n disablePortal = false,\n keepMounted = false,\n modifiers,\n open,\n placement = 'bottom',\n popperOptions = defaultPopperOptions,\n popperRef,\n style,\n transition = false,\n slotProps = {},\n slots = {}\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded2);\n const [exited, setExited] = React.useState(true);\n const handleEnter = () => {\n setExited(false);\n };\n const handleExited = () => {\n setExited(true);\n };\n if (!keepMounted && !open && (!transition || exited)) {\n return null;\n }\n\n // If the container prop is provided, use that\n // If the anchorEl prop is provided, use its parent body element as the container\n // If neither are provided let the Modal take care of choosing the container\n let container;\n if (containerProp) {\n container = containerProp;\n } else if (anchorEl) {\n const resolvedAnchorEl = resolveAnchorEl(anchorEl);\n container = resolvedAnchorEl && isHTMLElement(resolvedAnchorEl) ? ownerDocument(resolvedAnchorEl).body : ownerDocument(null).body;\n }\n const display = !open && keepMounted && (!transition || exited) ? 'none' : undefined;\n const transitionProps = transition ? {\n in: open,\n onEnter: handleEnter,\n onExited: handleExited\n } : undefined;\n return /*#__PURE__*/_jsx(Portal, {\n disablePortal: disablePortal,\n container: container,\n children: /*#__PURE__*/_jsx(PopperTooltip, _extends({\n anchorEl: anchorEl,\n direction: direction,\n disablePortal: disablePortal,\n modifiers: modifiers,\n ref: forwardedRef,\n open: transition ? !exited : open,\n placement: placement,\n popperOptions: popperOptions,\n popperRef: popperRef,\n slotProps: slotProps,\n slots: slots\n }, other, {\n style: _extends({\n // Prevents scroll issue, waiting for Popper.js to add this style once initiated.\n position: 'fixed',\n // Fix Popper.js display issue\n top: 0,\n left: 0,\n display\n }, style),\n TransitionProps: transitionProps,\n children: children\n }))\n });\n});\nprocess.env.NODE_ENV !== \"production\" ? Popper.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * An HTML element, [virtualElement](https://popper.js.org/docs/v2/virtual-elements/),\n * or a function that returns either.\n * It's used to set the position of the popper.\n * The return value will passed as the reference object of the Popper instance.\n */\n anchorEl: chainPropTypes(PropTypes.oneOfType([HTMLElementType, PropTypes.object, PropTypes.func]), props => {\n if (props.open) {\n const resolvedAnchorEl = resolveAnchorEl(props.anchorEl);\n if (resolvedAnchorEl && isHTMLElement(resolvedAnchorEl) && resolvedAnchorEl.nodeType === 1) {\n const box = resolvedAnchorEl.getBoundingClientRect();\n if (process.env.NODE_ENV !== 'test' && box.top === 0 && box.left === 0 && box.right === 0 && box.bottom === 0) {\n return new Error(['MUI: The `anchorEl` prop provided to the component is invalid.', 'The anchor element should be part of the document layout.', \"Make sure the element is present in the document or that it's not display none.\"].join('\\n'));\n }\n } else if (!resolvedAnchorEl || typeof resolvedAnchorEl.getBoundingClientRect !== 'function' || isVirtualElement(resolvedAnchorEl) && resolvedAnchorEl.contextElement != null && resolvedAnchorEl.contextElement.nodeType !== 1) {\n return new Error(['MUI: The `anchorEl` prop provided to the component is invalid.', 'It should be an HTML element instance or a virtualElement ', '(https://popper.js.org/docs/v2/virtual-elements/).'].join('\\n'));\n }\n }\n return null;\n }),\n /**\n * Popper render function or node.\n */\n children: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.node, PropTypes.func]),\n /**\n * An HTML element or function that returns one.\n * The `container` will have the portal children appended to it.\n *\n * You can also provide a callback, which is called in a React layout effect.\n * This lets you set the container from a ref, and also makes server-side rendering possible.\n *\n * By default, it uses the body of the top-level document object,\n * so it's simply `document.body` most of the time.\n */\n container: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.func]),\n /**\n * Direction of the text.\n * @default 'ltr'\n */\n direction: PropTypes.oneOf(['ltr', 'rtl']),\n /**\n * The `children` will be under the DOM hierarchy of the parent component.\n * @default false\n */\n disablePortal: PropTypes.bool,\n /**\n * Always keep the children in the DOM.\n * This prop can be useful in SEO situation or\n * when you want to maximize the responsiveness of the Popper.\n * @default false\n */\n keepMounted: PropTypes.bool,\n /**\n * Popper.js is based on a \"plugin-like\" architecture,\n * most of its features are fully encapsulated \"modifiers\".\n *\n * A modifier is a function that is called each time Popper.js needs to\n * compute the position of the popper.\n * For this reason, modifiers should be very performant to avoid bottlenecks.\n * To learn how to create a modifier, [read the modifiers documentation](https://popper.js.org/docs/v2/modifiers/).\n */\n modifiers: PropTypes.arrayOf(PropTypes.shape({\n data: PropTypes.object,\n effect: PropTypes.func,\n enabled: PropTypes.bool,\n fn: PropTypes.func,\n name: PropTypes.any,\n options: PropTypes.object,\n phase: PropTypes.oneOf(['afterMain', 'afterRead', 'afterWrite', 'beforeMain', 'beforeRead', 'beforeWrite', 'main', 'read', 'write']),\n requires: PropTypes.arrayOf(PropTypes.string),\n requiresIfExists: PropTypes.arrayOf(PropTypes.string)\n })),\n /**\n * If `true`, the component is shown.\n */\n open: PropTypes.bool.isRequired,\n /**\n * Popper placement.\n * @default 'bottom'\n */\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n /**\n * Options provided to the [`Popper.js`](https://popper.js.org/docs/v2/constructors/#options) instance.\n * @default {}\n */\n popperOptions: PropTypes.shape({\n modifiers: PropTypes.array,\n onFirstUpdate: PropTypes.func,\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n strategy: PropTypes.oneOf(['absolute', 'fixed'])\n }),\n /**\n * A ref that points to the used popper instance.\n */\n popperRef: refType,\n /**\n * The props used for each slot inside the Popper.\n * @default {}\n */\n slotProps: PropTypes.shape({\n root: PropTypes.oneOfType([PropTypes.func, PropTypes.object])\n }),\n /**\n * The components used for each slot inside the Popper.\n * Either a string to use a HTML element or a component.\n * @default {}\n */\n slots: PropTypes.shape({\n root: PropTypes.elementType\n }),\n /**\n * Help supporting a react-transition-group/Transition component.\n * @default false\n */\n transition: PropTypes.bool\n} : void 0;\nexport { Popper };","'use client';\n\nimport * as React from 'react';\nimport { useTheme as useThemeSystem } from '@mui/system';\nimport defaultTheme from './defaultTheme';\nimport THEME_ID from './identifier';\nexport default function useTheme() {\n const theme = useThemeSystem(defaultTheme);\n if (process.env.NODE_ENV !== 'production') {\n // eslint-disable-next-line react-hooks/rules-of-hooks\n React.useDebugValue(theme);\n }\n return theme[THEME_ID] || theme;\n}","export default function _setPrototypeOf(o, p) {\n _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function _setPrototypeOf(o, p) {\n o.__proto__ = p;\n return o;\n };\n return _setPrototypeOf(o, p);\n}","import setPrototypeOf from \"./setPrototypeOf.js\";\nexport default function _inheritsLoose(subClass, superClass) {\n subClass.prototype = Object.create(superClass.prototype);\n subClass.prototype.constructor = subClass;\n setPrototypeOf(subClass, superClass);\n}","export default {\n disabled: false\n};","import PropTypes from 'prop-types';\nexport var timeoutsShape = process.env.NODE_ENV !== 'production' ? PropTypes.oneOfType([PropTypes.number, PropTypes.shape({\n enter: PropTypes.number,\n exit: PropTypes.number,\n appear: PropTypes.number\n}).isRequired]) : null;\nexport var classNamesShape = process.env.NODE_ENV !== 'production' ? PropTypes.oneOfType([PropTypes.string, PropTypes.shape({\n enter: PropTypes.string,\n exit: PropTypes.string,\n active: PropTypes.string\n}), PropTypes.shape({\n enter: PropTypes.string,\n enterDone: PropTypes.string,\n enterActive: PropTypes.string,\n exit: PropTypes.string,\n exitDone: PropTypes.string,\n exitActive: PropTypes.string\n})]) : null;","import React from 'react';\nexport default React.createContext(null);","export var forceReflow = function forceReflow(node) {\n return node.scrollTop;\n};","import _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _inheritsLoose from \"@babel/runtime/helpers/esm/inheritsLoose\";\nimport PropTypes from 'prop-types';\nimport React from 'react';\nimport ReactDOM from 'react-dom';\nimport config from './config';\nimport { timeoutsShape } from './utils/PropTypes';\nimport TransitionGroupContext from './TransitionGroupContext';\nimport { forceReflow } from './utils/reflow';\nexport var UNMOUNTED = 'unmounted';\nexport var EXITED = 'exited';\nexport var ENTERING = 'entering';\nexport var ENTERED = 'entered';\nexport var EXITING = 'exiting';\n/**\n * The Transition component lets you describe a transition from one component\n * state to another _over time_ with a simple declarative API. Most commonly\n * it's used to animate the mounting and unmounting of a component, but can also\n * be used to describe in-place transition states as well.\n *\n * ---\n *\n * **Note**: `Transition` is a platform-agnostic base component. If you're using\n * transitions in CSS, you'll probably want to use\n * [`CSSTransition`](https://reactcommunity.org/react-transition-group/css-transition)\n * instead. It inherits all the features of `Transition`, but contains\n * additional features necessary to play nice with CSS transitions (hence the\n * name of the component).\n *\n * ---\n *\n * By default the `Transition` component does not alter the behavior of the\n * component it renders, it only tracks \"enter\" and \"exit\" states for the\n * components. It's up to you to give meaning and effect to those states. For\n * example we can add styles to a component when it enters or exits:\n *\n * ```jsx\n * import { Transition } from 'react-transition-group';\n *\n * const duration = 300;\n *\n * const defaultStyle = {\n * transition: `opacity ${duration}ms ease-in-out`,\n * opacity: 0,\n * }\n *\n * const transitionStyles = {\n * entering: { opacity: 1 },\n * entered: { opacity: 1 },\n * exiting: { opacity: 0 },\n * exited: { opacity: 0 },\n * };\n *\n * const Fade = ({ in: inProp }) => (\n * \n * {state => (\n *
    \n * I'm a fade Transition!\n *
    \n * )}\n *
    \n * );\n * ```\n *\n * There are 4 main states a Transition can be in:\n * - `'entering'`\n * - `'entered'`\n * - `'exiting'`\n * - `'exited'`\n *\n * Transition state is toggled via the `in` prop. When `true` the component\n * begins the \"Enter\" stage. During this stage, the component will shift from\n * its current transition state, to `'entering'` for the duration of the\n * transition and then to the `'entered'` stage once it's complete. Let's take\n * the following example (we'll use the\n * [useState](https://reactjs.org/docs/hooks-reference.html#usestate) hook):\n *\n * ```jsx\n * function App() {\n * const [inProp, setInProp] = useState(false);\n * return (\n *
    \n * \n * {state => (\n * // ...\n * )}\n * \n * \n *
    \n * );\n * }\n * ```\n *\n * When the button is clicked the component will shift to the `'entering'` state\n * and stay there for 500ms (the value of `timeout`) before it finally switches\n * to `'entered'`.\n *\n * When `in` is `false` the same thing happens except the state moves from\n * `'exiting'` to `'exited'`.\n */\n\nvar Transition = /*#__PURE__*/function (_React$Component) {\n _inheritsLoose(Transition, _React$Component);\n\n function Transition(props, context) {\n var _this;\n\n _this = _React$Component.call(this, props, context) || this;\n var parentGroup = context; // In the context of a TransitionGroup all enters are really appears\n\n var appear = parentGroup && !parentGroup.isMounting ? props.enter : props.appear;\n var initialStatus;\n _this.appearStatus = null;\n\n if (props.in) {\n if (appear) {\n initialStatus = EXITED;\n _this.appearStatus = ENTERING;\n } else {\n initialStatus = ENTERED;\n }\n } else {\n if (props.unmountOnExit || props.mountOnEnter) {\n initialStatus = UNMOUNTED;\n } else {\n initialStatus = EXITED;\n }\n }\n\n _this.state = {\n status: initialStatus\n };\n _this.nextCallback = null;\n return _this;\n }\n\n Transition.getDerivedStateFromProps = function getDerivedStateFromProps(_ref, prevState) {\n var nextIn = _ref.in;\n\n if (nextIn && prevState.status === UNMOUNTED) {\n return {\n status: EXITED\n };\n }\n\n return null;\n } // getSnapshotBeforeUpdate(prevProps) {\n // let nextStatus = null\n // if (prevProps !== this.props) {\n // const { status } = this.state\n // if (this.props.in) {\n // if (status !== ENTERING && status !== ENTERED) {\n // nextStatus = ENTERING\n // }\n // } else {\n // if (status === ENTERING || status === ENTERED) {\n // nextStatus = EXITING\n // }\n // }\n // }\n // return { nextStatus }\n // }\n ;\n\n var _proto = Transition.prototype;\n\n _proto.componentDidMount = function componentDidMount() {\n this.updateStatus(true, this.appearStatus);\n };\n\n _proto.componentDidUpdate = function componentDidUpdate(prevProps) {\n var nextStatus = null;\n\n if (prevProps !== this.props) {\n var status = this.state.status;\n\n if (this.props.in) {\n if (status !== ENTERING && status !== ENTERED) {\n nextStatus = ENTERING;\n }\n } else {\n if (status === ENTERING || status === ENTERED) {\n nextStatus = EXITING;\n }\n }\n }\n\n this.updateStatus(false, nextStatus);\n };\n\n _proto.componentWillUnmount = function componentWillUnmount() {\n this.cancelNextCallback();\n };\n\n _proto.getTimeouts = function getTimeouts() {\n var timeout = this.props.timeout;\n var exit, enter, appear;\n exit = enter = appear = timeout;\n\n if (timeout != null && typeof timeout !== 'number') {\n exit = timeout.exit;\n enter = timeout.enter; // TODO: remove fallback for next major\n\n appear = timeout.appear !== undefined ? timeout.appear : enter;\n }\n\n return {\n exit: exit,\n enter: enter,\n appear: appear\n };\n };\n\n _proto.updateStatus = function updateStatus(mounting, nextStatus) {\n if (mounting === void 0) {\n mounting = false;\n }\n\n if (nextStatus !== null) {\n // nextStatus will always be ENTERING or EXITING.\n this.cancelNextCallback();\n\n if (nextStatus === ENTERING) {\n if (this.props.unmountOnExit || this.props.mountOnEnter) {\n var node = this.props.nodeRef ? this.props.nodeRef.current : ReactDOM.findDOMNode(this); // https://github.com/reactjs/react-transition-group/pull/749\n // With unmountOnExit or mountOnEnter, the enter animation should happen at the transition between `exited` and `entering`.\n // To make the animation happen, we have to separate each rendering and avoid being processed as batched.\n\n if (node) forceReflow(node);\n }\n\n this.performEnter(mounting);\n } else {\n this.performExit();\n }\n } else if (this.props.unmountOnExit && this.state.status === EXITED) {\n this.setState({\n status: UNMOUNTED\n });\n }\n };\n\n _proto.performEnter = function performEnter(mounting) {\n var _this2 = this;\n\n var enter = this.props.enter;\n var appearing = this.context ? this.context.isMounting : mounting;\n\n var _ref2 = this.props.nodeRef ? [appearing] : [ReactDOM.findDOMNode(this), appearing],\n maybeNode = _ref2[0],\n maybeAppearing = _ref2[1];\n\n var timeouts = this.getTimeouts();\n var enterTimeout = appearing ? timeouts.appear : timeouts.enter; // no enter animation skip right to ENTERED\n // if we are mounting and running this it means appear _must_ be set\n\n if (!mounting && !enter || config.disabled) {\n this.safeSetState({\n status: ENTERED\n }, function () {\n _this2.props.onEntered(maybeNode);\n });\n return;\n }\n\n this.props.onEnter(maybeNode, maybeAppearing);\n this.safeSetState({\n status: ENTERING\n }, function () {\n _this2.props.onEntering(maybeNode, maybeAppearing);\n\n _this2.onTransitionEnd(enterTimeout, function () {\n _this2.safeSetState({\n status: ENTERED\n }, function () {\n _this2.props.onEntered(maybeNode, maybeAppearing);\n });\n });\n });\n };\n\n _proto.performExit = function performExit() {\n var _this3 = this;\n\n var exit = this.props.exit;\n var timeouts = this.getTimeouts();\n var maybeNode = this.props.nodeRef ? undefined : ReactDOM.findDOMNode(this); // no exit animation skip right to EXITED\n\n if (!exit || config.disabled) {\n this.safeSetState({\n status: EXITED\n }, function () {\n _this3.props.onExited(maybeNode);\n });\n return;\n }\n\n this.props.onExit(maybeNode);\n this.safeSetState({\n status: EXITING\n }, function () {\n _this3.props.onExiting(maybeNode);\n\n _this3.onTransitionEnd(timeouts.exit, function () {\n _this3.safeSetState({\n status: EXITED\n }, function () {\n _this3.props.onExited(maybeNode);\n });\n });\n });\n };\n\n _proto.cancelNextCallback = function cancelNextCallback() {\n if (this.nextCallback !== null) {\n this.nextCallback.cancel();\n this.nextCallback = null;\n }\n };\n\n _proto.safeSetState = function safeSetState(nextState, callback) {\n // This shouldn't be necessary, but there are weird race conditions with\n // setState callbacks and unmounting in testing, so always make sure that\n // we can cancel any pending setState callbacks after we unmount.\n callback = this.setNextCallback(callback);\n this.setState(nextState, callback);\n };\n\n _proto.setNextCallback = function setNextCallback(callback) {\n var _this4 = this;\n\n var active = true;\n\n this.nextCallback = function (event) {\n if (active) {\n active = false;\n _this4.nextCallback = null;\n callback(event);\n }\n };\n\n this.nextCallback.cancel = function () {\n active = false;\n };\n\n return this.nextCallback;\n };\n\n _proto.onTransitionEnd = function onTransitionEnd(timeout, handler) {\n this.setNextCallback(handler);\n var node = this.props.nodeRef ? this.props.nodeRef.current : ReactDOM.findDOMNode(this);\n var doesNotHaveTimeoutOrListener = timeout == null && !this.props.addEndListener;\n\n if (!node || doesNotHaveTimeoutOrListener) {\n setTimeout(this.nextCallback, 0);\n return;\n }\n\n if (this.props.addEndListener) {\n var _ref3 = this.props.nodeRef ? [this.nextCallback] : [node, this.nextCallback],\n maybeNode = _ref3[0],\n maybeNextCallback = _ref3[1];\n\n this.props.addEndListener(maybeNode, maybeNextCallback);\n }\n\n if (timeout != null) {\n setTimeout(this.nextCallback, timeout);\n }\n };\n\n _proto.render = function render() {\n var status = this.state.status;\n\n if (status === UNMOUNTED) {\n return null;\n }\n\n var _this$props = this.props,\n children = _this$props.children,\n _in = _this$props.in,\n _mountOnEnter = _this$props.mountOnEnter,\n _unmountOnExit = _this$props.unmountOnExit,\n _appear = _this$props.appear,\n _enter = _this$props.enter,\n _exit = _this$props.exit,\n _timeout = _this$props.timeout,\n _addEndListener = _this$props.addEndListener,\n _onEnter = _this$props.onEnter,\n _onEntering = _this$props.onEntering,\n _onEntered = _this$props.onEntered,\n _onExit = _this$props.onExit,\n _onExiting = _this$props.onExiting,\n _onExited = _this$props.onExited,\n _nodeRef = _this$props.nodeRef,\n childProps = _objectWithoutPropertiesLoose(_this$props, [\"children\", \"in\", \"mountOnEnter\", \"unmountOnExit\", \"appear\", \"enter\", \"exit\", \"timeout\", \"addEndListener\", \"onEnter\", \"onEntering\", \"onEntered\", \"onExit\", \"onExiting\", \"onExited\", \"nodeRef\"]);\n\n return (\n /*#__PURE__*/\n // allows for nested Transitions\n React.createElement(TransitionGroupContext.Provider, {\n value: null\n }, typeof children === 'function' ? children(status, childProps) : React.cloneElement(React.Children.only(children), childProps))\n );\n };\n\n return Transition;\n}(React.Component);\n\nTransition.contextType = TransitionGroupContext;\nTransition.propTypes = process.env.NODE_ENV !== \"production\" ? {\n /**\n * A React reference to DOM element that need to transition:\n * https://stackoverflow.com/a/51127130/4671932\n *\n * - When `nodeRef` prop is used, `node` is not passed to callback functions\n * (e.g. `onEnter`) because user already has direct access to the node.\n * - When changing `key` prop of `Transition` in a `TransitionGroup` a new\n * `nodeRef` need to be provided to `Transition` with changed `key` prop\n * (see\n * [test/CSSTransition-test.js](https://github.com/reactjs/react-transition-group/blob/13435f897b3ab71f6e19d724f145596f5910581c/test/CSSTransition-test.js#L362-L437)).\n */\n nodeRef: PropTypes.shape({\n current: typeof Element === 'undefined' ? PropTypes.any : function (propValue, key, componentName, location, propFullName, secret) {\n var value = propValue[key];\n return PropTypes.instanceOf(value && 'ownerDocument' in value ? value.ownerDocument.defaultView.Element : Element)(propValue, key, componentName, location, propFullName, secret);\n }\n }),\n\n /**\n * A `function` child can be used instead of a React element. This function is\n * called with the current transition status (`'entering'`, `'entered'`,\n * `'exiting'`, `'exited'`), which can be used to apply context\n * specific props to a component.\n *\n * ```jsx\n * \n * {state => (\n * \n * )}\n * \n * ```\n */\n children: PropTypes.oneOfType([PropTypes.func.isRequired, PropTypes.element.isRequired]).isRequired,\n\n /**\n * Show the component; triggers the enter or exit states\n */\n in: PropTypes.bool,\n\n /**\n * By default the child component is mounted immediately along with\n * the parent `Transition` component. If you want to \"lazy mount\" the component on the\n * first `in={true}` you can set `mountOnEnter`. After the first enter transition the component will stay\n * mounted, even on \"exited\", unless you also specify `unmountOnExit`.\n */\n mountOnEnter: PropTypes.bool,\n\n /**\n * By default the child component stays mounted after it reaches the `'exited'` state.\n * Set `unmountOnExit` if you'd prefer to unmount the component after it finishes exiting.\n */\n unmountOnExit: PropTypes.bool,\n\n /**\n * By default the child component does not perform the enter transition when\n * it first mounts, regardless of the value of `in`. If you want this\n * behavior, set both `appear` and `in` to `true`.\n *\n * > **Note**: there are no special appear states like `appearing`/`appeared`, this prop\n * > only adds an additional enter transition. However, in the\n * > `` component that first enter transition does result in\n * > additional `.appear-*` classes, that way you can choose to style it\n * > differently.\n */\n appear: PropTypes.bool,\n\n /**\n * Enable or disable enter transitions.\n */\n enter: PropTypes.bool,\n\n /**\n * Enable or disable exit transitions.\n */\n exit: PropTypes.bool,\n\n /**\n * The duration of the transition, in milliseconds.\n * Required unless `addEndListener` is provided.\n *\n * You may specify a single timeout for all transitions:\n *\n * ```jsx\n * timeout={500}\n * ```\n *\n * or individually:\n *\n * ```jsx\n * timeout={{\n * appear: 500,\n * enter: 300,\n * exit: 500,\n * }}\n * ```\n *\n * - `appear` defaults to the value of `enter`\n * - `enter` defaults to `0`\n * - `exit` defaults to `0`\n *\n * @type {number | { enter?: number, exit?: number, appear?: number }}\n */\n timeout: function timeout(props) {\n var pt = timeoutsShape;\n if (!props.addEndListener) pt = pt.isRequired;\n\n for (var _len = arguments.length, args = new Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) {\n args[_key - 1] = arguments[_key];\n }\n\n return pt.apply(void 0, [props].concat(args));\n },\n\n /**\n * Add a custom transition end trigger. Called with the transitioning\n * DOM node and a `done` callback. Allows for more fine grained transition end\n * logic. Timeouts are still used as a fallback if provided.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * ```jsx\n * addEndListener={(node, done) => {\n * // use the css transitionend event to mark the finish of a transition\n * node.addEventListener('transitionend', done, false);\n * }}\n * ```\n */\n addEndListener: PropTypes.func,\n\n /**\n * Callback fired before the \"entering\" status is applied. An extra parameter\n * `isAppearing` is supplied to indicate if the enter stage is occurring on the initial mount\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement, isAppearing: bool) -> void\n */\n onEnter: PropTypes.func,\n\n /**\n * Callback fired after the \"entering\" status is applied. An extra parameter\n * `isAppearing` is supplied to indicate if the enter stage is occurring on the initial mount\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement, isAppearing: bool)\n */\n onEntering: PropTypes.func,\n\n /**\n * Callback fired after the \"entered\" status is applied. An extra parameter\n * `isAppearing` is supplied to indicate if the enter stage is occurring on the initial mount\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement, isAppearing: bool) -> void\n */\n onEntered: PropTypes.func,\n\n /**\n * Callback fired before the \"exiting\" status is applied.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement) -> void\n */\n onExit: PropTypes.func,\n\n /**\n * Callback fired after the \"exiting\" status is applied.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement) -> void\n */\n onExiting: PropTypes.func,\n\n /**\n * Callback fired after the \"exited\" status is applied.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed\n *\n * @type Function(node: HtmlElement) -> void\n */\n onExited: PropTypes.func\n} : {}; // Name the function so it is clearer in the documentation\n\nfunction noop() {}\n\nTransition.defaultProps = {\n in: false,\n mountOnEnter: false,\n unmountOnExit: false,\n appear: false,\n enter: true,\n exit: true,\n onEnter: noop,\n onEntering: noop,\n onEntered: noop,\n onExit: noop,\n onExiting: noop,\n onExited: noop\n};\nTransition.UNMOUNTED = UNMOUNTED;\nTransition.EXITED = EXITED;\nTransition.ENTERING = ENTERING;\nTransition.ENTERED = ENTERED;\nTransition.EXITING = EXITING;\nexport default Transition;","export const reflow = node => node.scrollTop;\nexport function getTransitionProps(props, options) {\n var _style$transitionDura, _style$transitionTimi;\n const {\n timeout,\n easing,\n style = {}\n } = props;\n return {\n duration: (_style$transitionDura = style.transitionDuration) != null ? _style$transitionDura : typeof timeout === 'number' ? timeout : timeout[options.mode] || 0,\n easing: (_style$transitionTimi = style.transitionTimingFunction) != null ? _style$transitionTimi : typeof easing === 'object' ? easing[options.mode] : easing,\n delay: style.transitionDelay\n };\n}","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"addEndListener\", \"appear\", \"children\", \"easing\", \"in\", \"onEnter\", \"onEntered\", \"onEntering\", \"onExit\", \"onExited\", \"onExiting\", \"style\", \"timeout\", \"TransitionComponent\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport { elementAcceptingRef, unstable_useTimeout as useTimeout } from '@mui/utils';\nimport { Transition } from 'react-transition-group';\nimport useTheme from '../styles/useTheme';\nimport { getTransitionProps, reflow } from '../transitions/utils';\nimport useForkRef from '../utils/useForkRef';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nfunction getScale(value) {\n return `scale(${value}, ${value ** 2})`;\n}\nconst styles = {\n entering: {\n opacity: 1,\n transform: getScale(1)\n },\n entered: {\n opacity: 1,\n transform: 'none'\n }\n};\n\n/*\n TODO v6: remove\n Conditionally apply a workaround for the CSS transition bug in Safari 15.4 / WebKit browsers.\n */\nconst isWebKit154 = typeof navigator !== 'undefined' && /^((?!chrome|android).)*(safari|mobile)/i.test(navigator.userAgent) && /(os |version\\/)15(.|_)4/i.test(navigator.userAgent);\n\n/**\n * The Grow transition is used by the [Tooltip](/material-ui/react-tooltip/) and\n * [Popover](/material-ui/react-popover/) components.\n * It uses [react-transition-group](https://github.com/reactjs/react-transition-group) internally.\n */\nconst Grow = /*#__PURE__*/React.forwardRef(function Grow(props, ref) {\n const {\n addEndListener,\n appear = true,\n children,\n easing,\n in: inProp,\n onEnter,\n onEntered,\n onEntering,\n onExit,\n onExited,\n onExiting,\n style,\n timeout = 'auto',\n // eslint-disable-next-line react/prop-types\n TransitionComponent = Transition\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const timer = useTimeout();\n const autoTimeout = React.useRef();\n const theme = useTheme();\n const nodeRef = React.useRef(null);\n const handleRef = useForkRef(nodeRef, children.ref, ref);\n const normalizedTransitionCallback = callback => maybeIsAppearing => {\n if (callback) {\n const node = nodeRef.current;\n\n // onEnterXxx and onExitXxx callbacks have a different arguments.length value.\n if (maybeIsAppearing === undefined) {\n callback(node);\n } else {\n callback(node, maybeIsAppearing);\n }\n }\n };\n const handleEntering = normalizedTransitionCallback(onEntering);\n const handleEnter = normalizedTransitionCallback((node, isAppearing) => {\n reflow(node); // So the animation always start from the start.\n\n const {\n duration: transitionDuration,\n delay,\n easing: transitionTimingFunction\n } = getTransitionProps({\n style,\n timeout,\n easing\n }, {\n mode: 'enter'\n });\n let duration;\n if (timeout === 'auto') {\n duration = theme.transitions.getAutoHeightDuration(node.clientHeight);\n autoTimeout.current = duration;\n } else {\n duration = transitionDuration;\n }\n node.style.transition = [theme.transitions.create('opacity', {\n duration,\n delay\n }), theme.transitions.create('transform', {\n duration: isWebKit154 ? duration : duration * 0.666,\n delay,\n easing: transitionTimingFunction\n })].join(',');\n if (onEnter) {\n onEnter(node, isAppearing);\n }\n });\n const handleEntered = normalizedTransitionCallback(onEntered);\n const handleExiting = normalizedTransitionCallback(onExiting);\n const handleExit = normalizedTransitionCallback(node => {\n const {\n duration: transitionDuration,\n delay,\n easing: transitionTimingFunction\n } = getTransitionProps({\n style,\n timeout,\n easing\n }, {\n mode: 'exit'\n });\n let duration;\n if (timeout === 'auto') {\n duration = theme.transitions.getAutoHeightDuration(node.clientHeight);\n autoTimeout.current = duration;\n } else {\n duration = transitionDuration;\n }\n node.style.transition = [theme.transitions.create('opacity', {\n duration,\n delay\n }), theme.transitions.create('transform', {\n duration: isWebKit154 ? duration : duration * 0.666,\n delay: isWebKit154 ? delay : delay || duration * 0.333,\n easing: transitionTimingFunction\n })].join(',');\n node.style.opacity = 0;\n node.style.transform = getScale(0.75);\n if (onExit) {\n onExit(node);\n }\n });\n const handleExited = normalizedTransitionCallback(onExited);\n const handleAddEndListener = next => {\n if (timeout === 'auto') {\n timer.start(autoTimeout.current || 0, next);\n }\n if (addEndListener) {\n // Old call signature before `react-transition-group` implemented `nodeRef`\n addEndListener(nodeRef.current, next);\n }\n };\n return /*#__PURE__*/_jsx(TransitionComponent, _extends({\n appear: appear,\n in: inProp,\n nodeRef: nodeRef,\n onEnter: handleEnter,\n onEntered: handleEntered,\n onEntering: handleEntering,\n onExit: handleExit,\n onExited: handleExited,\n onExiting: handleExiting,\n addEndListener: handleAddEndListener,\n timeout: timeout === 'auto' ? null : timeout\n }, other, {\n children: (state, childProps) => {\n return /*#__PURE__*/React.cloneElement(children, _extends({\n style: _extends({\n opacity: 0,\n transform: getScale(0.75),\n visibility: state === 'exited' && !inProp ? 'hidden' : undefined\n }, styles[state], style, children.props.style),\n ref: handleRef\n }, childProps));\n }\n }));\n});\nprocess.env.NODE_ENV !== \"production\" ? Grow.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the d.ts file and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * Add a custom transition end trigger. Called with the transitioning DOM\n * node and a done callback. Allows for more fine grained transition end\n * logic. Note: Timeouts are still used as a fallback if provided.\n */\n addEndListener: PropTypes.func,\n /**\n * Perform the enter transition when it first mounts if `in` is also `true`.\n * Set this to `false` to disable this behavior.\n * @default true\n */\n appear: PropTypes.bool,\n /**\n * A single child content element.\n */\n children: elementAcceptingRef.isRequired,\n /**\n * The transition timing function.\n * You may specify a single easing or a object containing enter and exit values.\n */\n easing: PropTypes.oneOfType([PropTypes.shape({\n enter: PropTypes.string,\n exit: PropTypes.string\n }), PropTypes.string]),\n /**\n * If `true`, the component will transition in.\n */\n in: PropTypes.bool,\n /**\n * @ignore\n */\n onEnter: PropTypes.func,\n /**\n * @ignore\n */\n onEntered: PropTypes.func,\n /**\n * @ignore\n */\n onEntering: PropTypes.func,\n /**\n * @ignore\n */\n onExit: PropTypes.func,\n /**\n * @ignore\n */\n onExited: PropTypes.func,\n /**\n * @ignore\n */\n onExiting: PropTypes.func,\n /**\n * @ignore\n */\n style: PropTypes.object,\n /**\n * The duration for the transition, in milliseconds.\n * You may specify a single timeout for all transitions, or individually with an object.\n *\n * Set to 'auto' to automatically calculate transition time based on height.\n * @default 'auto'\n */\n timeout: PropTypes.oneOfType([PropTypes.oneOf(['auto']), PropTypes.number, PropTypes.shape({\n appear: PropTypes.number,\n enter: PropTypes.number,\n exit: PropTypes.number\n })])\n} : void 0;\nGrow.muiSupportAuto = true;\nexport default Grow;","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"anchorEl\", \"component\", \"components\", \"componentsProps\", \"container\", \"disablePortal\", \"keepMounted\", \"modifiers\", \"open\", \"placement\", \"popperOptions\", \"popperRef\", \"transition\", \"slots\", \"slotProps\"];\nimport { Popper as BasePopper } from '@mui/base/Popper';\nimport { useThemeWithoutDefault as useTheme } from '@mui/system';\nimport { HTMLElementType, refType } from '@mui/utils';\nimport PropTypes from 'prop-types';\nimport * as React from 'react';\nimport { styled, useThemeProps } from '../styles';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nconst PopperRoot = styled(BasePopper, {\n name: 'MuiPopper',\n slot: 'Root',\n overridesResolver: (props, styles) => styles.root\n})({});\n\n/**\n *\n * Demos:\n *\n * - [Autocomplete](https://mui.com/material-ui/react-autocomplete/)\n * - [Menu](https://mui.com/material-ui/react-menu/)\n * - [Popper](https://mui.com/material-ui/react-popper/)\n *\n * API:\n *\n * - [Popper API](https://mui.com/material-ui/api/popper/)\n */\nconst Popper = /*#__PURE__*/React.forwardRef(function Popper(inProps, ref) {\n var _slots$root;\n const theme = useTheme();\n const props = useThemeProps({\n props: inProps,\n name: 'MuiPopper'\n });\n const {\n anchorEl,\n component,\n components,\n componentsProps,\n container,\n disablePortal,\n keepMounted,\n modifiers,\n open,\n placement,\n popperOptions,\n popperRef,\n transition,\n slots,\n slotProps\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const RootComponent = (_slots$root = slots == null ? void 0 : slots.root) != null ? _slots$root : components == null ? void 0 : components.Root;\n const otherProps = _extends({\n anchorEl,\n container,\n disablePortal,\n keepMounted,\n modifiers,\n open,\n placement,\n popperOptions,\n popperRef,\n transition\n }, other);\n return /*#__PURE__*/_jsx(PopperRoot, _extends({\n as: component,\n direction: theme == null ? void 0 : theme.direction,\n slots: {\n root: RootComponent\n },\n slotProps: slotProps != null ? slotProps : componentsProps\n }, otherProps, {\n ref: ref\n }));\n});\nprocess.env.NODE_ENV !== \"production\" ? Popper.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * An HTML element, [virtualElement](https://popper.js.org/docs/v2/virtual-elements/),\n * or a function that returns either.\n * It's used to set the position of the popper.\n * The return value will passed as the reference object of the Popper instance.\n */\n anchorEl: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.object, PropTypes.func]),\n /**\n * Popper render function or node.\n */\n children: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.node, PropTypes.func]),\n /**\n * The component used for the root node.\n * Either a string to use a HTML element or a component.\n */\n component: PropTypes.elementType,\n /**\n * The components used for each slot inside the Popper.\n * Either a string to use a HTML element or a component.\n * @default {}\n */\n components: PropTypes.shape({\n Root: PropTypes.elementType\n }),\n /**\n * The props used for each slot inside the Popper.\n * @default {}\n */\n componentsProps: PropTypes.shape({\n root: PropTypes.oneOfType([PropTypes.func, PropTypes.object])\n }),\n /**\n * An HTML element or function that returns one.\n * The `container` will have the portal children appended to it.\n *\n * You can also provide a callback, which is called in a React layout effect.\n * This lets you set the container from a ref, and also makes server-side rendering possible.\n *\n * By default, it uses the body of the top-level document object,\n * so it's simply `document.body` most of the time.\n */\n container: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.func]),\n /**\n * The `children` will be under the DOM hierarchy of the parent component.\n * @default false\n */\n disablePortal: PropTypes.bool,\n /**\n * Always keep the children in the DOM.\n * This prop can be useful in SEO situation or\n * when you want to maximize the responsiveness of the Popper.\n * @default false\n */\n keepMounted: PropTypes.bool,\n /**\n * Popper.js is based on a \"plugin-like\" architecture,\n * most of its features are fully encapsulated \"modifiers\".\n *\n * A modifier is a function that is called each time Popper.js needs to\n * compute the position of the popper.\n * For this reason, modifiers should be very performant to avoid bottlenecks.\n * To learn how to create a modifier, [read the modifiers documentation](https://popper.js.org/docs/v2/modifiers/).\n */\n modifiers: PropTypes.arrayOf(PropTypes.shape({\n data: PropTypes.object,\n effect: PropTypes.func,\n enabled: PropTypes.bool,\n fn: PropTypes.func,\n name: PropTypes.any,\n options: PropTypes.object,\n phase: PropTypes.oneOf(['afterMain', 'afterRead', 'afterWrite', 'beforeMain', 'beforeRead', 'beforeWrite', 'main', 'read', 'write']),\n requires: PropTypes.arrayOf(PropTypes.string),\n requiresIfExists: PropTypes.arrayOf(PropTypes.string)\n })),\n /**\n * If `true`, the component is shown.\n */\n open: PropTypes.bool.isRequired,\n /**\n * Popper placement.\n * @default 'bottom'\n */\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n /**\n * Options provided to the [`Popper.js`](https://popper.js.org/docs/v2/constructors/#options) instance.\n * @default {}\n */\n popperOptions: PropTypes.shape({\n modifiers: PropTypes.array,\n onFirstUpdate: PropTypes.func,\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n strategy: PropTypes.oneOf(['absolute', 'fixed'])\n }),\n /**\n * A ref that points to the used popper instance.\n */\n popperRef: refType,\n /**\n * The props used for each slot inside the Popper.\n * @default {}\n */\n slotProps: PropTypes.shape({\n root: PropTypes.oneOfType([PropTypes.func, PropTypes.object])\n }),\n /**\n * The components used for each slot inside the Popper.\n * Either a string to use a HTML element or a component.\n * @default {}\n */\n slots: PropTypes.shape({\n root: PropTypes.elementType\n }),\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Help supporting a react-transition-group/Transition component.\n * @default false\n */\n transition: PropTypes.bool\n} : void 0;\nexport default Popper;","import generateUtilityClasses from '@mui/utils/generateUtilityClasses';\nimport generateUtilityClass from '@mui/utils/generateUtilityClass';\nexport function getTooltipUtilityClass(slot) {\n return generateUtilityClass('MuiTooltip', slot);\n}\nconst tooltipClasses = generateUtilityClasses('MuiTooltip', ['popper', 'popperInteractive', 'popperArrow', 'popperClose', 'tooltip', 'tooltipArrow', 'touch', 'tooltipPlacementLeft', 'tooltipPlacementRight', 'tooltipPlacementTop', 'tooltipPlacementBottom', 'arrow']);\nexport default tooltipClasses;","'use client';\n\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nconst _excluded = [\"arrow\", \"children\", \"classes\", \"components\", \"componentsProps\", \"describeChild\", \"disableFocusListener\", \"disableHoverListener\", \"disableInteractive\", \"disableTouchListener\", \"enterDelay\", \"enterNextDelay\", \"enterTouchDelay\", \"followCursor\", \"id\", \"leaveDelay\", \"leaveTouchDelay\", \"onClose\", \"onOpen\", \"open\", \"placement\", \"PopperComponent\", \"PopperProps\", \"slotProps\", \"slots\", \"title\", \"TransitionComponent\", \"TransitionProps\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport clsx from 'clsx';\nimport { elementAcceptingRef, unstable_useTimeout as useTimeout, unstable_Timeout as Timeout } from '@mui/utils';\nimport { unstable_composeClasses as composeClasses, appendOwnerState } from '@mui/base';\nimport { alpha } from '@mui/system';\nimport styled from '../styles/styled';\nimport useTheme from '../styles/useTheme';\nimport useThemeProps from '../styles/useThemeProps';\nimport capitalize from '../utils/capitalize';\nimport Grow from '../Grow';\nimport Popper from '../Popper';\nimport useEventCallback from '../utils/useEventCallback';\nimport useForkRef from '../utils/useForkRef';\nimport useId from '../utils/useId';\nimport useIsFocusVisible from '../utils/useIsFocusVisible';\nimport useControlled from '../utils/useControlled';\nimport tooltipClasses, { getTooltipUtilityClass } from './tooltipClasses';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nimport { jsxs as _jsxs } from \"react/jsx-runtime\";\nfunction round(value) {\n return Math.round(value * 1e5) / 1e5;\n}\nconst useUtilityClasses = ownerState => {\n const {\n classes,\n disableInteractive,\n arrow,\n touch,\n placement\n } = ownerState;\n const slots = {\n popper: ['popper', !disableInteractive && 'popperInteractive', arrow && 'popperArrow'],\n tooltip: ['tooltip', arrow && 'tooltipArrow', touch && 'touch', `tooltipPlacement${capitalize(placement.split('-')[0])}`],\n arrow: ['arrow']\n };\n return composeClasses(slots, getTooltipUtilityClass, classes);\n};\nconst TooltipPopper = styled(Popper, {\n name: 'MuiTooltip',\n slot: 'Popper',\n overridesResolver: (props, styles) => {\n const {\n ownerState\n } = props;\n return [styles.popper, !ownerState.disableInteractive && styles.popperInteractive, ownerState.arrow && styles.popperArrow, !ownerState.open && styles.popperClose];\n }\n})(({\n theme,\n ownerState,\n open\n}) => _extends({\n zIndex: (theme.vars || theme).zIndex.tooltip,\n pointerEvents: 'none'\n}, !ownerState.disableInteractive && {\n pointerEvents: 'auto'\n}, !open && {\n pointerEvents: 'none'\n}, ownerState.arrow && {\n [`&[data-popper-placement*=\"bottom\"] .${tooltipClasses.arrow}`]: {\n top: 0,\n marginTop: '-0.71em',\n '&::before': {\n transformOrigin: '0 100%'\n }\n },\n [`&[data-popper-placement*=\"top\"] .${tooltipClasses.arrow}`]: {\n bottom: 0,\n marginBottom: '-0.71em',\n '&::before': {\n transformOrigin: '100% 0'\n }\n },\n [`&[data-popper-placement*=\"right\"] .${tooltipClasses.arrow}`]: _extends({}, !ownerState.isRtl ? {\n left: 0,\n marginLeft: '-0.71em'\n } : {\n right: 0,\n marginRight: '-0.71em'\n }, {\n height: '1em',\n width: '0.71em',\n '&::before': {\n transformOrigin: '100% 100%'\n }\n }),\n [`&[data-popper-placement*=\"left\"] .${tooltipClasses.arrow}`]: _extends({}, !ownerState.isRtl ? {\n right: 0,\n marginRight: '-0.71em'\n } : {\n left: 0,\n marginLeft: '-0.71em'\n }, {\n height: '1em',\n width: '0.71em',\n '&::before': {\n transformOrigin: '0 0'\n }\n })\n}));\nconst TooltipTooltip = styled('div', {\n name: 'MuiTooltip',\n slot: 'Tooltip',\n overridesResolver: (props, styles) => {\n const {\n ownerState\n } = props;\n return [styles.tooltip, ownerState.touch && styles.touch, ownerState.arrow && styles.tooltipArrow, styles[`tooltipPlacement${capitalize(ownerState.placement.split('-')[0])}`]];\n }\n})(({\n theme,\n ownerState\n}) => _extends({\n backgroundColor: theme.vars ? theme.vars.palette.Tooltip.bg : alpha(theme.palette.grey[700], 0.92),\n borderRadius: (theme.vars || theme).shape.borderRadius,\n color: (theme.vars || theme).palette.common.white,\n fontFamily: theme.typography.fontFamily,\n padding: '4px 8px',\n fontSize: theme.typography.pxToRem(11),\n maxWidth: 300,\n margin: 2,\n wordWrap: 'break-word',\n fontWeight: theme.typography.fontWeightMedium\n}, ownerState.arrow && {\n position: 'relative',\n margin: 0\n}, ownerState.touch && {\n padding: '8px 16px',\n fontSize: theme.typography.pxToRem(14),\n lineHeight: `${round(16 / 14)}em`,\n fontWeight: theme.typography.fontWeightRegular\n}, {\n [`.${tooltipClasses.popper}[data-popper-placement*=\"left\"] &`]: _extends({\n transformOrigin: 'right center'\n }, !ownerState.isRtl ? _extends({\n marginRight: '14px'\n }, ownerState.touch && {\n marginRight: '24px'\n }) : _extends({\n marginLeft: '14px'\n }, ownerState.touch && {\n marginLeft: '24px'\n })),\n [`.${tooltipClasses.popper}[data-popper-placement*=\"right\"] &`]: _extends({\n transformOrigin: 'left center'\n }, !ownerState.isRtl ? _extends({\n marginLeft: '14px'\n }, ownerState.touch && {\n marginLeft: '24px'\n }) : _extends({\n marginRight: '14px'\n }, ownerState.touch && {\n marginRight: '24px'\n })),\n [`.${tooltipClasses.popper}[data-popper-placement*=\"top\"] &`]: _extends({\n transformOrigin: 'center bottom',\n marginBottom: '14px'\n }, ownerState.touch && {\n marginBottom: '24px'\n }),\n [`.${tooltipClasses.popper}[data-popper-placement*=\"bottom\"] &`]: _extends({\n transformOrigin: 'center top',\n marginTop: '14px'\n }, ownerState.touch && {\n marginTop: '24px'\n })\n}));\nconst TooltipArrow = styled('span', {\n name: 'MuiTooltip',\n slot: 'Arrow',\n overridesResolver: (props, styles) => styles.arrow\n})(({\n theme\n}) => ({\n overflow: 'hidden',\n position: 'absolute',\n width: '1em',\n height: '0.71em' /* = width / sqrt(2) = (length of the hypotenuse) */,\n boxSizing: 'border-box',\n color: theme.vars ? theme.vars.palette.Tooltip.bg : alpha(theme.palette.grey[700], 0.9),\n '&::before': {\n content: '\"\"',\n margin: 'auto',\n display: 'block',\n width: '100%',\n height: '100%',\n backgroundColor: 'currentColor',\n transform: 'rotate(45deg)'\n }\n}));\nlet hystersisOpen = false;\nconst hystersisTimer = new Timeout();\nlet cursorPosition = {\n x: 0,\n y: 0\n};\nexport function testReset() {\n hystersisOpen = false;\n hystersisTimer.clear();\n}\nfunction composeEventHandler(handler, eventHandler) {\n return event => {\n if (eventHandler) {\n eventHandler(event);\n }\n handler(event);\n };\n}\n\n// TODO v6: Remove PopperComponent, PopperProps, TransitionComponent and TransitionProps.\nconst Tooltip = /*#__PURE__*/React.forwardRef(function Tooltip(inProps, ref) {\n var _ref, _slots$popper, _ref2, _ref3, _slots$transition, _ref4, _slots$tooltip, _ref5, _slots$arrow, _slotProps$popper, _ref6, _slotProps$popper2, _slotProps$transition, _slotProps$tooltip, _ref7, _slotProps$tooltip2, _slotProps$arrow, _ref8, _slotProps$arrow2;\n const props = useThemeProps({\n props: inProps,\n name: 'MuiTooltip'\n });\n const {\n arrow = false,\n children: childrenProp,\n components = {},\n componentsProps = {},\n describeChild = false,\n disableFocusListener = false,\n disableHoverListener = false,\n disableInteractive: disableInteractiveProp = false,\n disableTouchListener = false,\n enterDelay = 100,\n enterNextDelay = 0,\n enterTouchDelay = 700,\n followCursor = false,\n id: idProp,\n leaveDelay = 0,\n leaveTouchDelay = 1500,\n onClose,\n onOpen,\n open: openProp,\n placement = 'bottom',\n PopperComponent: PopperComponentProp,\n PopperProps = {},\n slotProps = {},\n slots = {},\n title,\n TransitionComponent: TransitionComponentProp = Grow,\n TransitionProps\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n\n // to prevent runtime errors, developers will need to provide a child as a React element anyway.\n const children = /*#__PURE__*/React.isValidElement(childrenProp) ? childrenProp : /*#__PURE__*/_jsx(\"span\", {\n children: childrenProp\n });\n const theme = useTheme();\n const isRtl = theme.direction === 'rtl';\n const [childNode, setChildNode] = React.useState();\n const [arrowRef, setArrowRef] = React.useState(null);\n const ignoreNonTouchEvents = React.useRef(false);\n const disableInteractive = disableInteractiveProp || followCursor;\n const closeTimer = useTimeout();\n const enterTimer = useTimeout();\n const leaveTimer = useTimeout();\n const touchTimer = useTimeout();\n const [openState, setOpenState] = useControlled({\n controlled: openProp,\n default: false,\n name: 'Tooltip',\n state: 'open'\n });\n let open = openState;\n if (process.env.NODE_ENV !== 'production') {\n // eslint-disable-next-line react-hooks/rules-of-hooks\n const {\n current: isControlled\n } = React.useRef(openProp !== undefined);\n\n // eslint-disable-next-line react-hooks/rules-of-hooks\n React.useEffect(() => {\n if (childNode && childNode.disabled && !isControlled && title !== '' && childNode.tagName.toLowerCase() === 'button') {\n console.error(['MUI: You are providing a disabled `button` child to the Tooltip component.', 'A disabled element does not fire events.', \"Tooltip needs to listen to the child element's events to display the title.\", '', 'Add a simple wrapper element, such as a `span`.'].join('\\n'));\n }\n }, [title, childNode, isControlled]);\n }\n const id = useId(idProp);\n const prevUserSelect = React.useRef();\n const stopTouchInteraction = useEventCallback(() => {\n if (prevUserSelect.current !== undefined) {\n document.body.style.WebkitUserSelect = prevUserSelect.current;\n prevUserSelect.current = undefined;\n }\n touchTimer.clear();\n });\n React.useEffect(() => stopTouchInteraction, [stopTouchInteraction]);\n const handleOpen = event => {\n hystersisTimer.clear();\n hystersisOpen = true;\n\n // The mouseover event will trigger for every nested element in the tooltip.\n // We can skip rerendering when the tooltip is already open.\n // We are using the mouseover event instead of the mouseenter event to fix a hide/show issue.\n setOpenState(true);\n if (onOpen && !open) {\n onOpen(event);\n }\n };\n const handleClose = useEventCallback(\n /**\n * @param {React.SyntheticEvent | Event} event\n */\n event => {\n hystersisTimer.start(800 + leaveDelay, () => {\n hystersisOpen = false;\n });\n setOpenState(false);\n if (onClose && open) {\n onClose(event);\n }\n closeTimer.start(theme.transitions.duration.shortest, () => {\n ignoreNonTouchEvents.current = false;\n });\n });\n const handleEnter = event => {\n if (ignoreNonTouchEvents.current && event.type !== 'touchstart') {\n return;\n }\n\n // Remove the title ahead of time.\n // We don't want to wait for the next render commit.\n // We would risk displaying two tooltips at the same time (native + this one).\n if (childNode) {\n childNode.removeAttribute('title');\n }\n enterTimer.clear();\n leaveTimer.clear();\n if (enterDelay || hystersisOpen && enterNextDelay) {\n enterTimer.start(hystersisOpen ? enterNextDelay : enterDelay, () => {\n handleOpen(event);\n });\n } else {\n handleOpen(event);\n }\n };\n const handleLeave = event => {\n enterTimer.clear();\n leaveTimer.start(leaveDelay, () => {\n handleClose(event);\n });\n };\n const {\n isFocusVisibleRef,\n onBlur: handleBlurVisible,\n onFocus: handleFocusVisible,\n ref: focusVisibleRef\n } = useIsFocusVisible();\n // We don't necessarily care about the focusVisible state (which is safe to access via ref anyway).\n // We just need to re-render the Tooltip if the focus-visible state changes.\n const [, setChildIsFocusVisible] = React.useState(false);\n const handleBlur = event => {\n handleBlurVisible(event);\n if (isFocusVisibleRef.current === false) {\n setChildIsFocusVisible(false);\n handleLeave(event);\n }\n };\n const handleFocus = event => {\n // Workaround for https://github.com/facebook/react/issues/7769\n // The autoFocus of React might trigger the event before the componentDidMount.\n // We need to account for this eventuality.\n if (!childNode) {\n setChildNode(event.currentTarget);\n }\n handleFocusVisible(event);\n if (isFocusVisibleRef.current === true) {\n setChildIsFocusVisible(true);\n handleEnter(event);\n }\n };\n const detectTouchStart = event => {\n ignoreNonTouchEvents.current = true;\n const childrenProps = children.props;\n if (childrenProps.onTouchStart) {\n childrenProps.onTouchStart(event);\n }\n };\n const handleMouseOver = handleEnter;\n const handleMouseLeave = handleLeave;\n const handleTouchStart = event => {\n detectTouchStart(event);\n leaveTimer.clear();\n closeTimer.clear();\n stopTouchInteraction();\n prevUserSelect.current = document.body.style.WebkitUserSelect;\n // Prevent iOS text selection on long-tap.\n document.body.style.WebkitUserSelect = 'none';\n touchTimer.start(enterTouchDelay, () => {\n document.body.style.WebkitUserSelect = prevUserSelect.current;\n handleEnter(event);\n });\n };\n const handleTouchEnd = event => {\n if (children.props.onTouchEnd) {\n children.props.onTouchEnd(event);\n }\n stopTouchInteraction();\n leaveTimer.start(leaveTouchDelay, () => {\n handleClose(event);\n });\n };\n React.useEffect(() => {\n if (!open) {\n return undefined;\n }\n\n /**\n * @param {KeyboardEvent} nativeEvent\n */\n function handleKeyDown(nativeEvent) {\n // IE11, Edge (prior to using Bink?) use 'Esc'\n if (nativeEvent.key === 'Escape' || nativeEvent.key === 'Esc') {\n handleClose(nativeEvent);\n }\n }\n document.addEventListener('keydown', handleKeyDown);\n return () => {\n document.removeEventListener('keydown', handleKeyDown);\n };\n }, [handleClose, open]);\n const handleRef = useForkRef(children.ref, focusVisibleRef, setChildNode, ref);\n\n // There is no point in displaying an empty tooltip.\n // So we exclude all falsy values, except 0, which is valid.\n if (!title && title !== 0) {\n open = false;\n }\n const popperRef = React.useRef();\n const handleMouseMove = event => {\n const childrenProps = children.props;\n if (childrenProps.onMouseMove) {\n childrenProps.onMouseMove(event);\n }\n cursorPosition = {\n x: event.clientX,\n y: event.clientY\n };\n if (popperRef.current) {\n popperRef.current.update();\n }\n };\n const nameOrDescProps = {};\n const titleIsString = typeof title === 'string';\n if (describeChild) {\n nameOrDescProps.title = !open && titleIsString && !disableHoverListener ? title : null;\n nameOrDescProps['aria-describedby'] = open ? id : null;\n } else {\n nameOrDescProps['aria-label'] = titleIsString ? title : null;\n nameOrDescProps['aria-labelledby'] = open && !titleIsString ? id : null;\n }\n const childrenProps = _extends({}, nameOrDescProps, other, children.props, {\n className: clsx(other.className, children.props.className),\n onTouchStart: detectTouchStart,\n ref: handleRef\n }, followCursor ? {\n onMouseMove: handleMouseMove\n } : {});\n if (process.env.NODE_ENV !== 'production') {\n childrenProps['data-mui-internal-clone-element'] = true;\n\n // eslint-disable-next-line react-hooks/rules-of-hooks\n React.useEffect(() => {\n if (childNode && !childNode.getAttribute('data-mui-internal-clone-element')) {\n console.error(['MUI: The `children` component of the Tooltip is not forwarding its props correctly.', 'Please make sure that props are spread on the same element that the ref is applied to.'].join('\\n'));\n }\n }, [childNode]);\n }\n const interactiveWrapperListeners = {};\n if (!disableTouchListener) {\n childrenProps.onTouchStart = handleTouchStart;\n childrenProps.onTouchEnd = handleTouchEnd;\n }\n if (!disableHoverListener) {\n childrenProps.onMouseOver = composeEventHandler(handleMouseOver, childrenProps.onMouseOver);\n childrenProps.onMouseLeave = composeEventHandler(handleMouseLeave, childrenProps.onMouseLeave);\n if (!disableInteractive) {\n interactiveWrapperListeners.onMouseOver = handleMouseOver;\n interactiveWrapperListeners.onMouseLeave = handleMouseLeave;\n }\n }\n if (!disableFocusListener) {\n childrenProps.onFocus = composeEventHandler(handleFocus, childrenProps.onFocus);\n childrenProps.onBlur = composeEventHandler(handleBlur, childrenProps.onBlur);\n if (!disableInteractive) {\n interactiveWrapperListeners.onFocus = handleFocus;\n interactiveWrapperListeners.onBlur = handleBlur;\n }\n }\n if (process.env.NODE_ENV !== 'production') {\n if (children.props.title) {\n console.error(['MUI: You have provided a `title` prop to the child of .', `Remove this title prop \\`${children.props.title}\\` or the Tooltip component.`].join('\\n'));\n }\n }\n const popperOptions = React.useMemo(() => {\n var _PopperProps$popperOp;\n let tooltipModifiers = [{\n name: 'arrow',\n enabled: Boolean(arrowRef),\n options: {\n element: arrowRef,\n padding: 4\n }\n }];\n if ((_PopperProps$popperOp = PopperProps.popperOptions) != null && _PopperProps$popperOp.modifiers) {\n tooltipModifiers = tooltipModifiers.concat(PopperProps.popperOptions.modifiers);\n }\n return _extends({}, PopperProps.popperOptions, {\n modifiers: tooltipModifiers\n });\n }, [arrowRef, PopperProps]);\n const ownerState = _extends({}, props, {\n isRtl,\n arrow,\n disableInteractive,\n placement,\n PopperComponentProp,\n touch: ignoreNonTouchEvents.current\n });\n const classes = useUtilityClasses(ownerState);\n const PopperComponent = (_ref = (_slots$popper = slots.popper) != null ? _slots$popper : components.Popper) != null ? _ref : TooltipPopper;\n const TransitionComponent = (_ref2 = (_ref3 = (_slots$transition = slots.transition) != null ? _slots$transition : components.Transition) != null ? _ref3 : TransitionComponentProp) != null ? _ref2 : Grow;\n const TooltipComponent = (_ref4 = (_slots$tooltip = slots.tooltip) != null ? _slots$tooltip : components.Tooltip) != null ? _ref4 : TooltipTooltip;\n const ArrowComponent = (_ref5 = (_slots$arrow = slots.arrow) != null ? _slots$arrow : components.Arrow) != null ? _ref5 : TooltipArrow;\n const popperProps = appendOwnerState(PopperComponent, _extends({}, PopperProps, (_slotProps$popper = slotProps.popper) != null ? _slotProps$popper : componentsProps.popper, {\n className: clsx(classes.popper, PopperProps == null ? void 0 : PopperProps.className, (_ref6 = (_slotProps$popper2 = slotProps.popper) != null ? _slotProps$popper2 : componentsProps.popper) == null ? void 0 : _ref6.className)\n }), ownerState);\n const transitionProps = appendOwnerState(TransitionComponent, _extends({}, TransitionProps, (_slotProps$transition = slotProps.transition) != null ? _slotProps$transition : componentsProps.transition), ownerState);\n const tooltipProps = appendOwnerState(TooltipComponent, _extends({}, (_slotProps$tooltip = slotProps.tooltip) != null ? _slotProps$tooltip : componentsProps.tooltip, {\n className: clsx(classes.tooltip, (_ref7 = (_slotProps$tooltip2 = slotProps.tooltip) != null ? _slotProps$tooltip2 : componentsProps.tooltip) == null ? void 0 : _ref7.className)\n }), ownerState);\n const tooltipArrowProps = appendOwnerState(ArrowComponent, _extends({}, (_slotProps$arrow = slotProps.arrow) != null ? _slotProps$arrow : componentsProps.arrow, {\n className: clsx(classes.arrow, (_ref8 = (_slotProps$arrow2 = slotProps.arrow) != null ? _slotProps$arrow2 : componentsProps.arrow) == null ? void 0 : _ref8.className)\n }), ownerState);\n return /*#__PURE__*/_jsxs(React.Fragment, {\n children: [/*#__PURE__*/React.cloneElement(children, childrenProps), /*#__PURE__*/_jsx(PopperComponent, _extends({\n as: PopperComponentProp != null ? PopperComponentProp : Popper,\n placement: placement,\n anchorEl: followCursor ? {\n getBoundingClientRect: () => ({\n top: cursorPosition.y,\n left: cursorPosition.x,\n right: cursorPosition.x,\n bottom: cursorPosition.y,\n width: 0,\n height: 0\n })\n } : childNode,\n popperRef: popperRef,\n open: childNode ? open : false,\n id: id,\n transition: true\n }, interactiveWrapperListeners, popperProps, {\n popperOptions: popperOptions,\n children: ({\n TransitionProps: TransitionPropsInner\n }) => /*#__PURE__*/_jsx(TransitionComponent, _extends({\n timeout: theme.transitions.duration.shorter\n }, TransitionPropsInner, transitionProps, {\n children: /*#__PURE__*/_jsxs(TooltipComponent, _extends({}, tooltipProps, {\n children: [title, arrow ? /*#__PURE__*/_jsx(ArrowComponent, _extends({}, tooltipArrowProps, {\n ref: setArrowRef\n })) : null]\n }))\n }))\n }))]\n });\n});\nprocess.env.NODE_ENV !== \"production\" ? Tooltip.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the d.ts file and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * If `true`, adds an arrow to the tooltip.\n * @default false\n */\n arrow: PropTypes.bool,\n /**\n * Tooltip reference element.\n */\n children: elementAcceptingRef.isRequired,\n /**\n * Override or extend the styles applied to the component.\n */\n classes: PropTypes.object,\n /**\n * @ignore\n */\n className: PropTypes.string,\n /**\n * The components used for each slot inside.\n *\n * This prop is an alias for the `slots` prop.\n * It's recommended to use the `slots` prop instead.\n *\n * @default {}\n */\n components: PropTypes.shape({\n Arrow: PropTypes.elementType,\n Popper: PropTypes.elementType,\n Tooltip: PropTypes.elementType,\n Transition: PropTypes.elementType\n }),\n /**\n * The extra props for the slot components.\n * You can override the existing props or add new ones.\n *\n * This prop is an alias for the `slotProps` prop.\n * It's recommended to use the `slotProps` prop instead, as `componentsProps` will be deprecated in the future.\n *\n * @default {}\n */\n componentsProps: PropTypes.shape({\n arrow: PropTypes.object,\n popper: PropTypes.object,\n tooltip: PropTypes.object,\n transition: PropTypes.object\n }),\n /**\n * Set to `true` if the `title` acts as an accessible description.\n * By default the `title` acts as an accessible label for the child.\n * @default false\n */\n describeChild: PropTypes.bool,\n /**\n * Do not respond to focus-visible events.\n * @default false\n */\n disableFocusListener: PropTypes.bool,\n /**\n * Do not respond to hover events.\n * @default false\n */\n disableHoverListener: PropTypes.bool,\n /**\n * Makes a tooltip not interactive, i.e. it will close when the user\n * hovers over the tooltip before the `leaveDelay` is expired.\n * @default false\n */\n disableInteractive: PropTypes.bool,\n /**\n * Do not respond to long press touch events.\n * @default false\n */\n disableTouchListener: PropTypes.bool,\n /**\n * The number of milliseconds to wait before showing the tooltip.\n * This prop won't impact the enter touch delay (`enterTouchDelay`).\n * @default 100\n */\n enterDelay: PropTypes.number,\n /**\n * The number of milliseconds to wait before showing the tooltip when one was already recently opened.\n * @default 0\n */\n enterNextDelay: PropTypes.number,\n /**\n * The number of milliseconds a user must touch the element before showing the tooltip.\n * @default 700\n */\n enterTouchDelay: PropTypes.number,\n /**\n * If `true`, the tooltip follow the cursor over the wrapped element.\n * @default false\n */\n followCursor: PropTypes.bool,\n /**\n * This prop is used to help implement the accessibility logic.\n * If you don't provide this prop. It falls back to a randomly generated id.\n */\n id: PropTypes.string,\n /**\n * The number of milliseconds to wait before hiding the tooltip.\n * This prop won't impact the leave touch delay (`leaveTouchDelay`).\n * @default 0\n */\n leaveDelay: PropTypes.number,\n /**\n * The number of milliseconds after the user stops touching an element before hiding the tooltip.\n * @default 1500\n */\n leaveTouchDelay: PropTypes.number,\n /**\n * Callback fired when the component requests to be closed.\n *\n * @param {React.SyntheticEvent} event The event source of the callback.\n */\n onClose: PropTypes.func,\n /**\n * Callback fired when the component requests to be open.\n *\n * @param {React.SyntheticEvent} event The event source of the callback.\n */\n onOpen: PropTypes.func,\n /**\n * If `true`, the component is shown.\n */\n open: PropTypes.bool,\n /**\n * Tooltip placement.\n * @default 'bottom'\n */\n placement: PropTypes.oneOf(['bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n /**\n * The component used for the popper.\n * @default Popper\n */\n PopperComponent: PropTypes.elementType,\n /**\n * Props applied to the [`Popper`](/material-ui/api/popper/) element.\n * @default {}\n */\n PopperProps: PropTypes.object,\n /**\n * The extra props for the slot components.\n * You can override the existing props or add new ones.\n *\n * This prop is an alias for the `componentsProps` prop, which will be deprecated in the future.\n *\n * @default {}\n */\n slotProps: PropTypes.shape({\n arrow: PropTypes.object,\n popper: PropTypes.object,\n tooltip: PropTypes.object,\n transition: PropTypes.object\n }),\n /**\n * The components used for each slot inside.\n *\n * This prop is an alias for the `components` prop, which will be deprecated in the future.\n *\n * @default {}\n */\n slots: PropTypes.shape({\n arrow: PropTypes.elementType,\n popper: PropTypes.elementType,\n tooltip: PropTypes.elementType,\n transition: PropTypes.elementType\n }),\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Tooltip title. Zero-length titles string, undefined, null and false are never displayed.\n */\n title: PropTypes.node,\n /**\n * The component used for the transition.\n * [Follow this guide](/material-ui/transitions/#transitioncomponent-prop) to learn more about the requirements for this component.\n * @default Grow\n */\n TransitionComponent: PropTypes.elementType,\n /**\n * Props applied to the transition element.\n * By default, the element is based on this [`Transition`](http://reactcommunity.org/react-transition-group/transition/) component.\n */\n TransitionProps: PropTypes.object\n} : void 0;\nexport default Tooltip;","import '@/components/mui/menu-item.component.css';\nimport ArrowRightIcon from '@mui/icons-material/ArrowRight';\nimport {\n ListItemIcon as MuiListItemIcon,\n ListItemText as MuiListItemText,\n MenuItem as MuiMenuItem,\n} from '@mui/material';\nimport Tooltip from '@mui/material/Tooltip';\nimport { Localized, ReferencedItem, SingleColumnMenu } from 'platform-bible-utils';\nimport { MouseEvent, PropsWithChildren } from 'react';\n\ntype MenuItemInfoBase = {\n /** Text (displayable in the UI) as the name of the menu item */\n label: string;\n /** Text to display when the mouse hovers over the menu item */\n tooltip?: string;\n};\n\nexport type Command = MenuItemInfoBase & {\n /** Command to execute (string.string) */\n command: string;\n};\n\ntype SubMenu = MenuItemInfoBase & {\n /** Command to execute (string.string) */\n items: MenuItemInfo[];\n};\n\nexport interface CommandHandler {\n (command: Command): void;\n}\n\nexport type MenuPropsBase = {\n /*\n * The JSON defining the menu whose items are to be rendered. This will typically be one of the\n * menus in the \"defs\" in a Platform.Bible menu (see PlatformMenus). The schema for this is\n * menuDocumentSchema (at the end of menus.model.ts). Note that while this is a\n * \"SingleColumnMenu\", somewhat bizarrely, a MultiColumnMenu is a SingleColumnMenu, so it really\n * could be a MultiColumnMenu, in which case, column had better be defined so it can be used\n * to filter out the actual groups and items to display on the column.\n */\n menuDefinition: Localized;\n\n commandHandler: CommandHandler;\n\n /**\n * Additional action to perform when any menu item is clicked. Allows the caller to handle event\n * (e.g., to close the menu).\n */\n onClick?: (event: MouseEvent) => void;\n};\n\nexport type MenuItemListProps = MenuPropsBase & {\n /** Optional unique (column) identifier */\n columnId?: ReferencedItem;\n};\n\nexport type MenuItemProps = Omit &\n PropsWithChildren<{\n /** Optional unique identifier */\n id?: string;\n\n onClick: (event: MouseEvent) => void;\n }>;\n\ntype MenuItemInfo = (Command | SubMenu) & {\n /**\n * If specified, menu item will be inset if it does not have a leading icon.\n *\n * @default true\n */\n allowForLeadingIcons?: boolean;\n /**\n * If specified, the path to the icon image to display on the leading side of the menu text.\n *\n * @default undefined (no leading icon will be shown)\n */\n iconPathBefore?: string;\n /**\n * If specified, the path to the icon image to display on the trailing side of the menu text.\n *\n * @default undefined (no trailing icon will be shown)\n */\n iconPathAfter?: string;\n /**\n * If true, list item is focused during the first mount\n *\n * @default false\n */\n hasAutoFocus?: boolean;\n\n /** Additional css classes to help with unique styling of the menu item */\n className?: string;\n\n /**\n * If true, the menu item will appear disabled and it will not respond to clicks or mouse hovers.\n *\n * @default false\n */\n isDisabled?: boolean;\n\n /**\n * If true, compact vertical padding designed for keyboard and mouse input is used.\n *\n * @default true\n */\n isDense?: boolean;\n\n /**\n * If true, a right-arrow icon will be displayed (iconPathAfter, if specified, will be ignored).\n *\n * @default false\n */\n isSubMenuParent?: boolean;\n\n /**\n * If true, the left and right padding is removed\n *\n * @default false\n */\n hasDisabledGutters?: boolean;\n\n /**\n * If true, a 1px light border is added to bottom of menu item\n *\n * @default false\n */\n hasDivider?: boolean;\n\n /** Help identify which element has keyboard focus */\n focusVisibleClassName?: string;\n\n /** If it's a submenu, it should have the items property */\n items?: MenuItemInfo[];\n};\n\nfunction getIcon(icon: string | undefined, menuLabel: string, leading: boolean) {\n return icon ? (\n \n {`${leading\n \n ) : undefined;\n}\n\nexport default function MenuItem(props: MenuItemProps) {\n const {\n onClick,\n label,\n tooltip,\n allowForLeadingIcons = true,\n iconPathBefore = undefined,\n iconPathAfter = undefined,\n hasAutoFocus = false,\n className,\n isDisabled = false,\n isDense = true,\n isSubMenuParent = false,\n hasDisabledGutters = false,\n hasDivider = false,\n focusVisibleClassName,\n id,\n children,\n } = props;\n\n const menuItem = (\n \n {label ? (\n <>\n {getIcon(iconPathBefore, label, true)}\n \n {isSubMenuParent ? (\n \n \n \n ) : (\n getIcon(iconPathAfter, label, false)\n )}\n \n ) : (\n children\n )}\n \n );\n\n return tooltip ? (\n \n
    {menuItem}
    \n
    \n ) : (\n menuItem\n );\n}\n","import MenuItem, {\n MenuItemListProps,\n MenuItemProps,\n MenuPropsBase,\n} from '@/components/mui/menu-item.component';\nimport { Menu } from '@mui/material';\nimport {\n Localized,\n MenuGroupDetailsInSubMenu,\n MenuItemContainingCommand,\n MenuItemContainingSubmenu,\n OrderedExtensibleContainer,\n ReferencedItem,\n SingleColumnMenu,\n} from 'platform-bible-utils';\nimport { MouseEvent, useMemo, useState } from 'react';\n\n/**\n * All the exported types in this file should be regarded as \"internal\" (i.e., they should not be\n * exposed via index.ts).\n */\n\nexport type GroupedMenuPropsBase = MenuPropsBase & {\n /** Optional unique (column) identifier */\n columnId?: ReferencedItem;\n};\n\nexport type GroupedMenuItemListProps = MenuItemListProps & {\n /**\n * If the menuDefinition includes \"top-level\" groups (i.e., those that belong to a column as\n * opposed to those that belong to a submenu) that should not be included in the list, then this\n * array specifies which groups to include. Likewise, for a submenu, this list indicates which\n * groups are pertinent for that submenu. So then for a context menu this property need not be\n * specified since it is a top-level menu based on a \"true\" SingleColumnMenu (i.e., one that is\n * not a MultiColumnMenu).\n */\n includedGroups?: {\n id: string;\n group: Localized;\n }[];\n};\n\ninterface ItemInfo {\n item: Localized;\n isLastItemInGroup: boolean;\n}\n\ntype SubMenuProps = MenuPropsBase & {\n parentMenuItem: Localized;\n parentItemProps: Omit, 'iconPathAfter'>;\n};\n\nfunction getAllGroups(menuDefinition: Localized) {\n const groupEntries = Object.entries(menuDefinition.groups);\n // Convert array of entries to array of objects with id and group properties\n return groupEntries.map(([key, value]) => ({ id: key, group: value }));\n}\n\nfunction SubMenu(props: SubMenuProps) {\n const [anchorEl, setAnchorEl] = useState(undefined);\n\n const { parentMenuItem, parentItemProps, menuDefinition } = props;\n\n const handleParentMenuItemClick = (event: MouseEvent) => {\n setAnchorEl(event.currentTarget);\n };\n\n const handleClose = () => {\n setAnchorEl(undefined);\n };\n\n const renderSubMenuItems = () => {\n let includedGroups = getAllGroups(menuDefinition).filter((g) => 'menuItem' in g.group);\n\n // Ensure valid parent menu was provided. (If not, submenu will contain all groups!)\n if (!parentMenuItem?.id) throw new Error('A valid parent menu item is required for submenus.');\n\n // When laying out a submenu, only include groups associated with the provided parent menu.\n // Note: without the (annoying) redundant check that the included groups\n // have the menuItem field, TS doesn't think it exists.\n includedGroups = includedGroups.filter(\n (group) => 'menuItem' in group.group && group.group.menuItem === parentMenuItem.id,\n );\n\n return ;\n };\n\n return (\n <>\n \n \n {renderSubMenuItems()}\n \n \n );\n}\n\nconst getOrderedGroupItems = (\n groupId: string,\n allItems: Localized[],\n) => {\n // Filter items that belong to the specified group\n const itemsForGroup = allItems.filter((item) => item.group === groupId);\n // Sort items based on order\n const sortedItems = itemsForGroup.sort((a, b) => (a.order || 0) - (b.order || 0));\n return sortedItems;\n};\n\n/**\n * This component is internal; it does not need to be exposed to the outside world since it is not\n * useful on its own. It is used to generate and lay out the MenuItems that appear either on a\n * top-level menu (in a GridMenu or ContextMenu) or in a submenu.\n */\nexport default function GroupedMenuItemList(menuProps: GroupedMenuItemListProps) {\n const { menuDefinition, onClick, commandHandler, includedGroups } = menuProps;\n\n const { items, allowForLeadingIcons } = useMemo(() => {\n const groupsToInclude =\n includedGroups && includedGroups.length > 0\n ? includedGroups\n : // We're apparently laying out a single-column menu (presumably a context menu). In this\n // case, all groups should be included except ones that belong to a submenu.\n getAllGroups(menuDefinition).filter((g) => !('menuItem' in g.group));\n\n const sortedGroups = Object.values(groupsToInclude).sort(\n (a, b) => (a.group.order || 0) - (b.group.order || 0),\n );\n\n const itemArray: ItemInfo[] = [];\n\n sortedGroups.forEach((group) => {\n getOrderedGroupItems(group.id, menuDefinition.items).forEach((item) =>\n itemArray.push({ item, isLastItemInGroup: false }),\n );\n if (itemArray.length > 0) itemArray[itemArray.length - 1].isLastItemInGroup = true;\n });\n\n // No divider after last item in final group.\n if (itemArray.length > 0) itemArray[itemArray.length - 1].isLastItemInGroup = false;\n\n const allowSpaceForLeadingIcons = itemArray.some(\n (i) => 'iconPathBefore' in i.item && i.item.iconPathBefore,\n );\n\n return { items: itemArray, allowForLeadingIcons: allowSpaceForLeadingIcons };\n }, [includedGroups, menuDefinition]);\n\n // Create props for MenuItem component including setting hasDivider for the last item in a group\n const createMenuItemProps = ({ item, isLastItemInGroup }: ItemInfo) => {\n const menuItemProps = {\n className: 'papi-menu-item',\n label: item.label,\n tooltip: item.tooltip,\n iconPathBefore: 'iconPathBefore' in item ? item.iconPathBefore : undefined,\n iconPathAfter: 'iconPathAfter' in item ? item.iconPathAfter : undefined,\n hasDivider: isLastItemInGroup, // Set hasDivider to true for the last item in a group\n allowForLeadingIcons,\n };\n\n return menuItemProps;\n };\n\n const [firstItem] = items;\n\n if (!firstItem) return
    ;\n\n const divKey = firstItem.item.group;\n\n return (\n
    \n {items.map((itemInfo, index) => {\n const { item } = itemInfo;\n const menuItemProps = createMenuItemProps(itemInfo);\n if ('command' in item) {\n const key = item.group + index;\n return (\n ) => {\n onClick?.(event);\n commandHandler(item);\n }}\n {...menuItemProps}\n />\n );\n }\n return (\n \n );\n })}\n
    \n );\n}\n","import GroupedMenuItemList from '@/components/mui/grouped-menu-item-list.component';\nimport { MenuItemListProps } from '@/components/mui/menu-item.component';\nimport { MultiColumnMenu } from 'platform-bible-utils';\n\n/**\n * This component is internal; it does not need to be exposed to the outside world since it is not\n * useful on its own. Use either GridMenu or ContextMenu.\n */\nexport default function TopLevelMenu(props: MenuItemListProps) {\n const { menuDefinition, columnId } = props;\n\n const groupEntries = Object.entries(menuDefinition.groups);\n // Convert array of entries to array of objects with id and group properties\n const groups = groupEntries.map(([key, value]) => ({ id: key, group: value }));\n let includedGroups = groups.filter((g) => 'column' in g.group);\n\n // Check if column is provided and menuDefinition is a MultiColumnMenu\n if (\n columnId &&\n 'columns' in menuDefinition &&\n // Without this type assertion, TS doesn't know what columns is.\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n (menuDefinition as MultiColumnMenu).columns[columnId]\n ) {\n // When laying out a single column in a MultiColumnMenu, only include groups associated with\n // the provided column. Note: without the (annoying) redundant check that the included groups\n // have the colum field, TS doesn't think it exists.\n includedGroups = includedGroups.filter(\n (g) => 'column' in g.group && g.group.column === columnId,\n );\n }\n\n return ;\n}\n","import '@/components/mui/grid-menu.component.css';\nimport { GroupedMenuPropsBase } from '@/components/mui/grouped-menu-item-list.component';\nimport { CommandHandler } from '@/components/mui/menu-item.component';\nimport TopLevelMenu from '@/components/mui/top-level-menu.component';\nimport { Grid, List } from '@mui/material';\nimport {\n Localized,\n MenuColumnWithHeader,\n MultiColumnMenu,\n ReferencedItem,\n} from 'platform-bible-utils';\nimport { useMemo } from 'react';\n\ntype ColumnInfo = {\n /*\n * The ID (`${string}.${string}`) of a specific menu column.\n */\n id: ReferencedItem;\n\n /*\n * Metadata (label, order, etc.) for a specific menu column.\n */\n metadata: Localized;\n};\n\ntype MenuColumnProps = ColumnInfo &\n GroupedMenuPropsBase & {\n /** Additional css classes to help with unique styling of the menu column */\n className?: string;\n };\n\nexport type GridMenuInfo = {\n /** The menu object containing information about the columns, groups, and items to display. */\n multiColumnMenu: Localized;\n};\n\nexport type GridMenuProps = GridMenuInfo & {\n /** Optional unique identifier */\n id?: string;\n\n commandHandler: CommandHandler;\n\n /** Additional css classes to help with unique styling of the grid menu */\n className?: string;\n};\n\nfunction MenuColumn({\n commandHandler,\n menuDefinition,\n id,\n metadata,\n onClick,\n className,\n}: MenuColumnProps) {\n return (\n \n

    \n {metadata.label}\n

    \n {/* It would seem as though this List component were unnecessary, since it only contains one\n thing, but the \"dense\" property does affect the layout of the items (in a way I don't fully\n understand). There might be a better way. */}\n \n \n \n \n );\n}\n\nexport default function GridMenu({\n commandHandler,\n className,\n multiColumnMenu,\n id,\n}: GridMenuProps) {\n const { columns } = multiColumnMenu;\n\n const sortedColumns = useMemo(() => {\n const columnNumbers = new Map();\n Object.getOwnPropertyNames(columns).forEach((columnName: string) => {\n // We know for sure there is a (boolean) property 'isExtensible' that we are not interested in.\n if (columnName === 'isExtensible') return;\n // TS doesn't allow `columnName` above to be a ReferencedItem even though the type says it is\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const columnId = columnName as ReferencedItem;\n const column = columns[columnId];\n // As of right now (and hopefully forever after), all remaining properties of the\n // ColumnsWithHeaders object are columns whose property names are the IDs of the columns.\n // This is an additional (redundant) sanity check. Specifically we're interested in\n // MenuColumnWithHeader objects, which TypeScript now \"knows\" we have, but at runtime all we\n // can check for is that it's an object with a valid numeric order field. That's likely good\n // enough.\n if (\n typeof column === 'object' &&\n typeof column.order === 'number' &&\n !Number.isNaN(column.order)\n )\n columnNumbers.set(column.order, { id: columnId, metadata: column });\n else\n console.warn(\n `Property ${columnName} (${typeof column}) on menu ${id} is not a valid column and is being ignored. This might indicate data corruption`,\n );\n });\n\n // Extract values and sort them based on the 'order' property\n return Array.from(columnNumbers.values()).sort((a, b) => {\n return (a.metadata.order || 0) - (b.metadata.order || 0);\n });\n }, [columns, id]);\n\n // We might need something like this if we need to be able to prevent empty columns\n // sortedColumns.filter((c) => multiColumnMenu.groups.some((g) => 'column' in g && (g as .column)...\n\n return (\n \n {sortedColumns.map((col, index) => (\n \n ))}\n \n );\n}\n","import { useEffect, useRef, useState } from 'react';\n\nexport type UsePromiseOptions = {\n /**\n * Whether to leave the value as the most recent resolved promise value or set it back to\n * defaultValue while running the promise again. Defaults to true\n */\n preserveValue?: boolean;\n};\n\n/** Set up defaults for options for usePromise hook */\nfunction getUsePromiseOptionsDefaults(options: UsePromiseOptions): UsePromiseOptions {\n return {\n preserveValue: true,\n ...options,\n };\n}\n\n/**\n * Awaits a promise and returns a loading value while the promise is unresolved\n *\n * @param promiseFactoryCallback A function that returns the promise to await. If this callback is\n * undefined, the current value will be returned (defaultValue unless it was previously changed\n * and `options.preserveValue` is true), and there will be no loading.\n *\n * WARNING: MUST BE STABLE - const or wrapped in useCallback. The reference must not be updated\n * every render\n * @param defaultValue The initial value to return while first awaiting the promise. If\n * `options.preserveValue` is false, this value is also shown while awaiting the promise on\n * subsequent calls.\n *\n * Note: this parameter is internally assigned to a `ref`, so changing it will not cause any hooks\n * to re-run with its new value. This means that, if the `promiseFactoryCallback` changes and\n * `options.preserveValue` is `false`, the returned value will be set to the current\n * `defaultValue`. However, the returned value will not be updated if`defaultValue` changes.\n * @param options Various options for adjusting how this hook runs the `promiseFactoryCallback`\n *\n * Note: this parameter is internally assigned to a `ref`, so changing it will not cause any hooks\n * to re-run with its new value. However, the latest `options.preserveValue` will always be used\n * appropriately to determine whether to preserve the returned value when changing the\n * `promiseFactoryCallback`\n * @returns `[value, isLoading]`\n *\n * - `value`: the current value for the promise, either the defaultValue or the resolved promise value\n * - `isLoading`: whether the promise is waiting to be resolved\n */\nconst usePromise = (\n promiseFactoryCallback: (() => Promise) | undefined,\n defaultValue: T,\n options: UsePromiseOptions = {},\n): [value: T, isLoading: boolean] => {\n // Use defaultValue as a ref so it doesn't update dependency arrays\n const defaultValueRef = useRef(defaultValue);\n defaultValueRef.current = defaultValue;\n // Use options as a ref so it doesn't update dependency arrays\n const optionsDefaultedRef = useRef(options);\n optionsDefaultedRef.current = getUsePromiseOptionsDefaults(optionsDefaultedRef.current);\n\n const [value, setValue] = useState(() => defaultValueRef.current);\n const [isLoading, setIsLoading] = useState(true);\n useEffect(() => {\n let promiseIsCurrent = true;\n // If a promiseFactoryCallback was provided, we are loading. Otherwise, there is no loading to do\n setIsLoading(!!promiseFactoryCallback);\n (async () => {\n // If there is a callback to run, run it\n if (promiseFactoryCallback) {\n const result = await promiseFactoryCallback();\n // If the promise was not already replaced, update the value\n if (promiseIsCurrent) {\n setValue(() => result);\n setIsLoading(false);\n }\n }\n })();\n\n return () => {\n // Mark this promise as old and not to be used\n promiseIsCurrent = false;\n if (!optionsDefaultedRef.current.preserveValue) setValue(() => defaultValueRef.current);\n };\n }, [promiseFactoryCallback]);\n\n return [value, isLoading];\n};\nexport default usePromise;\n","\"use client\";\n\nimport createSvgIcon from './utils/createSvgIcon';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nexport default createSvgIcon( /*#__PURE__*/_jsx(\"path\", {\n d: \"M3 18h18v-2H3zm0-5h18v-2H3zm0-7v2h18V6z\"\n}), 'Menu');","import GridMenu from '@/components/mui/grid-menu.component';\nimport { Command, CommandHandler } from '@/components/mui/menu-item.component';\nimport usePromise from '@/hooks/use-promise.hook';\nimport { Menu as MenuIcon } from '@mui/icons-material';\nimport { Drawer, IconButton } from '@mui/material';\nimport { Localized, MultiColumnMenu } from 'platform-bible-utils';\nimport {\n MouseEvent,\n MutableRefObject,\n PropsWithChildren,\n useCallback,\n useEffect,\n useState,\n} from 'react';\n\nexport interface MultiColumnMenuProvider {\n (isSupportAndDevelopment: boolean): Promise>;\n}\n\nexport type HamburgerMenuButtonProps = PropsWithChildren & {\n /** The handler to use for menu commands (and eventually toolbar commands). */\n commandHandler: CommandHandler;\n\n /**\n * Optional reference to the \"div\" container that determines the where the menu should appear. If\n * not defined, then (1,1) used.\n */\n containerRef?: MutableRefObject;\n\n /**\n * The delegate to use to get the menu data. If not specified or if it returns undefined, the data\n * in normalMenu or fullMenu property will be used.\n */\n menuProvider?: MultiColumnMenuProvider;\n\n /**\n * The menu data to show when the menu is opened if the menuProvider property is not defined.\n * (This allows for a default or test-only static menu to be used.)\n */\n normalMenu?: Localized;\n\n /**\n * The menu data to show for \"full\" menu (when opened with the SHIFT key pressed) if the\n * menuProvider property is not defined. (This allows for a default or test-only static menu to be\n * used.)\n */\n fullMenu?: Localized;\n\n /** Additional css class(es) to help with unique styling of the sub-components */\n className?: string;\n\n /** Value to use as prefix for ARIA labels on interactive sub-components */\n ariaLabelPrefix?: string;\n};\n\nexport default function HamburgerMenuButton({\n menuProvider,\n normalMenu,\n fullMenu,\n commandHandler,\n containerRef,\n className,\n ariaLabelPrefix,\n children,\n}: HamburgerMenuButtonProps) {\n const [isMenuOpen, setMenuOpen] = useState(false);\n const [showFullMenu, setShowFullMenu] = useState(false);\n\n const handleMenuItemClick = useCallback(() => {\n if (isMenuOpen) setMenuOpen(false);\n setShowFullMenu(false);\n }, [isMenuOpen]);\n\n const handleMenuButtonClick = useCallback((e: MouseEvent) => {\n e.stopPropagation();\n setMenuOpen((prevIsOpen) => {\n const isOpening = !prevIsOpen;\n if (isOpening && e.shiftKey) setShowFullMenu(true);\n else if (!isOpening) setShowFullMenu(false);\n return isOpening;\n });\n }, []);\n\n const menuCommandHandler = useCallback(\n (command: Command) => {\n handleMenuItemClick();\n return commandHandler(command);\n },\n [commandHandler, handleMenuItemClick],\n );\n\n const [offset, setOffset] = useState({ top: 1, left: 1 });\n\n useEffect(() => {\n if (isMenuOpen) {\n const node = containerRef?.current;\n if (node) {\n const rect = node.getBoundingClientRect();\n const scrollTop = window.scrollY;\n const scrollLeft = window.scrollX;\n const top = rect.top + scrollTop + node.clientHeight;\n const left = rect.left + scrollLeft;\n setOffset({ top, left });\n }\n }\n }, [isMenuOpen, containerRef]);\n\n const [normalMenuData] = usePromise(\n useCallback(async () => {\n return menuProvider?.(false) ?? normalMenu;\n // isMenuOpen needs to be included for the menu contents to reevaluate when reopened\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [menuProvider, normalMenu, isMenuOpen]),\n normalMenu,\n );\n\n const [fullMenuData] = usePromise(\n useCallback(async () => {\n return menuProvider?.(true) ?? fullMenu ?? normalMenuData;\n // isMenuOpen needs to be included for the menu contents to reevaluate when reopened\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [menuProvider, fullMenu, normalMenuData, isMenuOpen]),\n fullMenu ?? normalMenuData,\n );\n\n const menu = showFullMenu && fullMenuData ? fullMenuData : normalMenuData;\n\n return (\n <>\n \n {children ?? }\n \n \n {menu ? (\n \n ) : undefined}\n \n \n );\n}\n","import '@/components/mui/icon-button.component.css';\nimport { IconButton as MuiIconButton } from '@mui/material';\nimport { MouseEventHandler, PropsWithChildren } from 'react';\n\nexport type IconButtonProps = PropsWithChildren<{\n /** Optional unique identifier */\n id?: string;\n /**\n * Required. Used as both the tooltip (aka, title) and the aria-label (used for accessibility,\n * testing, etc.), unless a distinct tooltip is supplied.\n */\n label: string;\n /**\n * Enabled status of button\n *\n * @default false\n */\n isDisabled?: boolean;\n /** Optional tooltip to display if different from the aria-label. */\n tooltip?: string;\n /** If true, no tooltip will be displayed. */\n isTooltipSuppressed?: boolean;\n /**\n * If given, uses a negative margin to counteract the padding on one side (this is often helpful\n * for aligning the left or right side of the icon with content above or below, without ruining\n * the border size and shape).\n *\n * @default false\n */\n adjustMarginToAlignToEdge?: 'end' | 'start' | false;\n /**\n * The size of the component. small is equivalent to the dense button styling.\n *\n * @default false\n */\n size: 'small' | 'medium' | 'large';\n /** Additional css classes to help with unique styling of the button */\n className?: string;\n /** Optional click handler */\n onClick?: MouseEventHandler;\n}>;\n\n/**\n * Iconic button a user can click to do something\n *\n * Thanks to MUI for heavy inspiration and documentation\n * https://mui.com/material-ui/getting-started/overview/\n */\nfunction IconButton({\n id,\n label,\n isDisabled = false,\n tooltip,\n isTooltipSuppressed = false,\n adjustMarginToAlignToEdge = false,\n size = 'medium',\n className,\n onClick,\n children,\n}: IconButtonProps) {\n return (\n \n {children /* the icon to display */}\n \n );\n}\n\nexport default IconButton;\n","import { cn } from '@/utils/shadcn-ui.util';\nimport { LoaderCircle, LucideProps } from 'lucide-react';\nimport { forwardRef } from 'react';\n\nexport type SpinnerProps = LucideProps;\n\nconst Spinner = forwardRef(({ className, ...props }, ref) => {\n return (\n \n );\n});\n\nSpinner.displayName = 'Spinner';\n\nexport default Spinner;\n","import { Input as ShadInput } from '@/components/shadcn-ui/input';\nimport { Label as ShadLabel } from '@/components/shadcn-ui/label';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { ChangeEventHandler, FocusEventHandler } from 'react';\n\nexport type TextFieldProps = {\n /** Optional unique identifier */\n id?: string;\n /**\n * If `true`, the component is disabled.\n *\n * @default false\n */\n isDisabled?: boolean;\n /**\n * If `true`, the label is displayed in an error state.\n *\n * @default false\n */\n hasError?: boolean;\n /**\n * If `true`, the input will take up the full width of its container.\n *\n * @default false\n */\n isFullWidth?: boolean;\n /** Text that gives the user instructions on what contents the TextField expects */\n helperText?: string;\n /** The title of the TextField */\n label?: string;\n /** The short hint displayed in the `input` before the user enters a value. */\n placeholder?: string;\n /**\n * If `true`, the label is displayed as required and the `input` element is required.\n *\n * @default false\n */\n isRequired?: boolean;\n /** Additional css classes to help with unique styling of the text field */\n className?: string;\n /** Starting value for the text field if it is not controlled */\n defaultValue?: string | number;\n /** Value of the text field if controlled */\n value?: string | number;\n /** Triggers when content of textfield is changed */\n onChange?: ChangeEventHandler;\n /** Triggers when textfield gets focus */\n onFocus?: FocusEventHandler;\n /** Triggers when textfield loses focus */\n onBlur?: FocusEventHandler;\n};\n\n/**\n * Text input field\n *\n * Thanks to Shadcn for heavy inspiration and documentation\n * https://ui.shadcn.com/docs/components/input#with-label\n */\nfunction TextField({\n id,\n isDisabled = false,\n hasError = false,\n isFullWidth = false,\n helperText,\n label,\n placeholder,\n isRequired = false,\n className,\n defaultValue,\n value,\n onChange,\n onFocus,\n onBlur,\n}: TextFieldProps) {\n return (\n
    \n {`${label}${isRequired ? '*' : ''}`}\n \n

    {helperText}

    \n
    \n );\n}\n\nexport default TextField;\n","import HamburgerMenuButton, {\n MultiColumnMenuProvider,\n} from '@/components/mui/hamburger-menu-button.component';\nimport { CommandHandler } from '@/components/mui/menu-item.component';\nimport '@/components/mui/toolbar.component.css';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { AppBar, Toolbar as MuiToolbar } from '@mui/material';\nimport { PropsWithChildren, useRef } from 'react';\n\nexport type ToolbarProps = PropsWithChildren<{\n /** The handler to use for menu commands (and eventually toolbar commands). */\n commandHandler: CommandHandler;\n\n /**\n * The optional delegate to use to get the menu data. If not specified, the \"hamburger\" menu will\n * not display.\n */\n menuProvider?: MultiColumnMenuProvider;\n\n /** Optional unique identifier */\n id?: string;\n\n /** Additional css classes to help with unique styling of the toolbar */\n className?: string;\n}>;\n\nexport default function Toolbar({\n menuProvider,\n commandHandler,\n className,\n id,\n children,\n}: ToolbarProps) {\n // This ref will always be defined\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const containerRef = useRef(undefined!);\n\n return (\n
    \n \n \n {menuProvider ? (\n \n ) : undefined}\n {children ?
    {children}
    : undefined}\n \n
    \n
    \n );\n}\n","import React from 'react';\nimport { cva, type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst alertVariants = cva(\n 'tw-relative tw-w-full tw-rounded-lg tw-border tw-p-4 [&>svg~*]:tw-pl-7 [&>svg+div]:tw-translate-y-[-3px] [&>svg]:tw-absolute [&>svg]:tw-left-4 [&>svg]:tw-top-4 [&>svg]:tw-text-foreground',\n {\n variants: {\n variant: {\n default: 'tw-bg-background tw-text-foreground',\n destructive:\n 'tw-border-destructive/50 tw-text-destructive dark:tw-border-destructive [&>svg]:tw-text-destructive',\n },\n },\n defaultVariants: {\n variant: 'default',\n },\n },\n);\n\nconst Alert = React.forwardRef<\n HTMLDivElement,\n React.HTMLAttributes & VariantProps\n>(({ className, variant, ...props }, ref) => (\n
    \n));\nAlert.displayName = 'Alert';\n\nconst AlertTitle = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n {/* added because of https://github.com/jsx-eslint/eslint-plugin-jsx-a11y/blob/main/docs/rules/heading-has-content.md */}\n {props.children}{' '}\n \n ),\n);\nAlertTitle.displayName = 'AlertTitle';\n\nconst AlertDescription = React.forwardRef<\n HTMLParagraphElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n
    \n));\nAlertDescription.displayName = 'AlertDescription';\n\nexport { Alert, AlertTitle, AlertDescription };\n","import React from 'react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Card = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nCard.displayName = 'Card';\n\nconst CardHeader = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nCardHeader.displayName = 'CardHeader';\n\nconst CardTitle = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n {/* added because of https://github.com/jsx-eslint/eslint-plugin-jsx-a11y/blob/main/docs/rules/heading-has-content.md */}\n {props.children}\n \n ),\n);\nCardTitle.displayName = 'CardTitle';\n\nconst CardDescription = React.forwardRef<\n HTMLParagraphElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n

    \n));\nCardDescription.displayName = 'CardDescription';\n\nconst CardContent = React.forwardRef>(\n ({ className, ...props }, ref) => (\n

    \n ),\n);\nCardContent.displayName = 'CardContent';\n\nconst CardFooter = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nCardFooter.displayName = 'CardFooter';\n\nexport { Card, CardHeader, CardFooter, CardTitle, CardDescription, CardContent };\n","import { ComponentProps } from 'react';\nimport { toast as sonner, Toaster } from 'sonner';\n\ntype SonnerProps = ComponentProps;\n\nfunction Sonner({ ...props }: SonnerProps) {\n return (\n \n );\n}\n\n// The re-export of the sonner function was added manually\nexport { Sonner, sonner };\n","import React from 'react';\nimport * as SliderPrimitive from '@radix-ui/react-slider';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Slider = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n \n \n \n));\nSlider.displayName = SliderPrimitive.Root.displayName;\n\nexport { Slider };\n","import React from 'react';\nimport * as SwitchPrimitives from '@radix-ui/react-switch';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Switch = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n));\nSwitch.displayName = SwitchPrimitives.Root.displayName;\n\nexport { Switch };\n","import React from 'react';\nimport * as TabsPrimitive from '@radix-ui/react-tabs';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport const Tabs = TabsPrimitive.Root;\n\nexport type TabsListProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport type TabsTriggerProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport type TabsContentProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport const TabsList = React.forwardRef<\n React.ElementRef,\n TabsListProps\n>(({ className, ...props }, ref) => (\n \n));\nTabsList.displayName = TabsPrimitive.List.displayName;\n\nexport const TabsTrigger = React.forwardRef<\n React.ElementRef,\n TabsTriggerProps\n>(({ className, ...props }, ref) => (\n \n));\nTabsTrigger.displayName = TabsPrimitive.Trigger.displayName;\n\nexport const TabsContent = React.forwardRef<\n React.ElementRef,\n TabsContentProps\n>(({ className, ...props }, ref) => (\n \n));\nTabsContent.displayName = TabsPrimitive.Content.displayName;\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Download } from 'lucide-react';\n\ntype InstallButtonProps = {\n /** The installing boolean value determines the state of the button. */\n isInstalling: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n /** Optional text for the button. */\n buttonText?: string;\n} & ButtonProps;\n\n/**\n * The InstallButton component is a button designed for initiating installs. It includes visuals for\n * active installing and idle states.\n *\n * @param isInstalling The installing boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @param buttonText Optional text for the button.\n * @returns A install button.\n */\nexport default function InstallButton({\n isInstalling,\n handleClick,\n buttonText,\n className,\n ...props\n}: InstallButtonProps) {\n return (\n \n {isInstalling ? (\n \n ) : (\n <>\n \n {buttonText}\n \n )}\n \n );\n}\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\n\ntype EnableButtonProps = {\n /** The enabling boolean value determines the state of the button. */\n isEnabling: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n} & ButtonProps;\n\n/**\n * The EnableButton component is a button designed for initiating enabling of downloads. It includes\n * visuals for active enabling and idle states.\n *\n * @param isEnabling The enabling boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @returns A button that can be used to enable.\n */\nexport default function EnableButton({\n isEnabling,\n handleClick,\n className,\n ...props\n}: EnableButtonProps) {\n return (\n \n {isEnabling ? (\n <>\n \n Enabling...\n \n ) : (\n 'Enable'\n )}\n \n );\n}\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\n\ntype DisableButtonProps = {\n /** The disabling boolean value determines the state of the button. */\n isDisabling: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n} & ButtonProps;\n\n/**\n * The DisableButton component is a button designed for initiating disabling of downloads. It\n * includes visuals for active disabling and idle states.\n *\n * @param isDisabling The disabling boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @returns A button that can be used to disable.\n */\nexport default function DisableButton({\n isDisabling,\n handleClick,\n className,\n ...props\n}: DisableButtonProps) {\n return (\n \n {isDisabling ? (\n <>\n \n Disabling...\n \n ) : (\n 'Disable'\n )}\n \n );\n}\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\n\ntype UpdateButtonProps = {\n /** The updating boolean value determines the state of the button. */\n isUpdating: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n} & ButtonProps;\n\n/**\n * The UpdateButton component is a button designed for initiating updates for downloaded extensions.\n * It includes visuals for active updating and idle states.\n *\n * @param isUpdating The updating boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @returns A button that can be used to update.\n */\nexport default function UpdateButton({\n isUpdating,\n handleClick,\n className,\n ...props\n}: UpdateButtonProps) {\n return (\n \n {isUpdating ? (\n <>\n \n Updating...\n \n ) : (\n 'Update'\n )}\n \n );\n}\n","import { cn } from '@/utils/shadcn-ui.util';\nimport Markdown, { MarkdownToJSX } from 'markdown-to-jsx';\nimport { useMemo } from 'react';\n\ninterface MarkdownRendererProps {\n /** Optional unique identifier */\n id?: string;\n /** The markdown string to render */\n markdown: string;\n className?: string;\n /**\n * The [`target` attribute for `a` html\n * tags](https://developer.mozilla.org/en-US/docs/Web/HTML/Element/a#target). Defaults to not\n * adding a `target` to `a` tags\n */\n anchorTarget?: string;\n}\n\n/**\n * This component renders markdown content given a markdown string. It uses typography styles from\n * the platform.\n *\n * @param markdown The markdown string to render.\n * @param id Optional unique identifier\n * @returns A div containing the rendered markdown content.\n */\nexport default function MarkdownRenderer({\n id,\n markdown,\n className,\n anchorTarget,\n}: MarkdownRendererProps) {\n const options: MarkdownToJSX.Options = useMemo(\n () => ({\n overrides: {\n a: {\n props: {\n target: anchorTarget,\n },\n },\n },\n }),\n [anchorTarget],\n );\n return (\n
    \n {markdown}\n
    \n );\n}\n","import { Filter, ChevronDown } from 'lucide-react';\nimport { forwardRef } from 'react';\nimport { Button } from '@/components/shadcn-ui/button';\n\n/**\n * The FilterButton component is a button designed for initiating filtering of data. It is designed\n * to be used with the dropdown menu. It uses forwardRef to pass the button to the dropdown trigger\n * asChild.\n *\n * @returns A button that can be used to filter.\n */\nconst FilterButton = forwardRef((props, ref) => {\n return (\n \n \n Filter\n \n \n );\n});\n\nexport default FilterButton;\n","import {\n DropdownMenu,\n DropdownMenuTrigger,\n DropdownMenuContent,\n DropdownMenuLabel,\n DropdownMenuGroup,\n DropdownMenuCheckboxItem,\n DropdownMenuRadioItem,\n DropdownMenuSeparator,\n} from '@/components/shadcn-ui/dropdown-menu';\nimport FilterButton from './buttons/filter-button.component';\n\nexport enum DropdownMenuItemType {\n Check,\n Radio,\n}\n\nexport type DropdownItem = {\n /** The label is the text that will be displayed on the dropdown item. */\n label: string;\n /** The itemType determines the DropdownMenuItemType type as either Check or Radio. */\n itemType: DropdownMenuItemType;\n /** The onClick function is called when the item is clicked. */\n onClick: () => void;\n};\n\nexport type DropdownGroup = {\n /**\n * The label is the text that will be displayed on the dropdown group. It is used to categorize\n * the items in the group.\n */\n label: string;\n /** The items array contains the items that will be displayed in the dropdown group */\n items: DropdownItem[];\n};\n\nexport type FilterDropdownProps = {\n /** Object unique identifier */\n id?: string;\n /** The groups array contains the groups that will be displayed in the dropdown */\n groups: DropdownGroup[];\n}; // TODO: extend the props later\n\n/**\n * The FilterDropdown component is a dropdown designed for filtering content. It includes groups of\n * items that can be checkboxes or radio items.\n *\n * @param id Optional unique identifier\n * @param groups The groups array contains the groups that will be displayed in the dropdown\n * @returns A filter dropdown.\n */\nexport default function FilterDropdown({ id, groups }: FilterDropdownProps) {\n return (\n
    \n {/* TODO: remove this once the DropDown Menu shadcn has an id prop */}\n \n \n \n \n \n {groups.map((group) => (\n
    \n {group.label}\n \n {group.items.map((item) => (\n
    \n {item.itemType === DropdownMenuItemType.Check ? (\n \n {item.label}\n \n ) : (\n \n {item.label}\n \n )}\n
    \n ))}\n
    \n \n
    \n ))}\n
    \n
    \n
    \n );\n}\n","interface NoExtensionsFoundProps {\n /** Optional unique identifier */\n id?: string;\n /** The message to display */\n message: string;\n}\n/**\n * This component displays a message to the user when no extensions are found in the marketplace.\n *\n * @param id Optional unique identifier\n * @param message The message to display.\n * @returns {JSX.Element} - Returns the message component that displays the message to the user.\n */\nexport default function NoExtensionsFound({ id, message }: NoExtensionsFoundProps) {\n return (\n
    \n
    \n

    {message}

    \n
    \n
    \n );\n}\n","import { CircleHelp, Link as LucideLink, User } from 'lucide-react';\nimport { NumberFormat } from 'platform-bible-utils';\n\n/** Interface that stores the parameters passed to the More Info component */\ninterface MoreInfoProps {\n /** Optional unique identifier */\n id?: string;\n /** The category of the extension */\n category: string;\n /** The number of downloads for the extension */\n downloads: Record;\n /** The languages supported by the extension */\n languages: string[];\n /** The URL to the more info page of the extension */\n moreInfoUrl: string;\n}\n/**\n * This component displays the more info section of the extension which includes the category,\n * number of downloads, languages, and links to the website and support\n *\n * @param id Optional unique identifier\n * @param category The category of the extension\n * @param downloads The number of downloads for the extension\n * @param languages The languages supported by the extension\n * @param moreInfoUrl The URL to the more info page of the extension\n * @returns {JSX.Element} - Returns the more info component that displays the category, number of\n * downloads, languages, and links to the website and support\n */\nexport default function MoreInfo({\n id,\n category,\n downloads,\n languages,\n moreInfoUrl,\n}: MoreInfoProps) {\n /**\n * This constant formats the number of downloads into a more readable format.\n *\n * @example 1000 -> 1K\n *\n * @example 1000000 -> 1M\n *\n * @returns The formatted number of downloads\n */\n const numberFormatted = new NumberFormat('en', {\n notation: 'compact',\n compactDisplay: 'short',\n }).format(Object.values(downloads).reduce((a: number, b: number) => a + b, 0));\n\n /** This function scrolls the window to the bottom of the page. */\n const handleScrollToBottom = () => {\n window.scrollTo(0, document.body.scrollHeight);\n };\n\n return (\n \n
    \n
    \n {category}\n
    \n CATEGORY\n
    \n
    \n
    \n
    \n \n {numberFormatted}\n
    \n USERS\n
    \n
    \n
    \n
    \n {languages.slice(0, 3).map((locale) => (\n \n {locale.toUpperCase()}\n \n ))}\n
    \n {languages.length > 3 && (\n handleScrollToBottom()}\n className=\"tw-text-xs tw-text-gray-500 tw-underline\"\n >\n +{languages.length - 3} more languages\n \n )}\n
    \n
    \n
    \n \n Website\n \n \n \n Support\n \n \n
    \n
    \n );\n}\n","import { useState } from 'react';\n\nexport type VersionInformation = {\n /** Date the version was published */\n date: string;\n /** Description of the changes in the version */\n description: string;\n};\n\n/** Type to store the version history information */\nexport type VersionHistoryType = Record;\n\n/** Interface that stores the parameters passed to the Version History component */\ninterface VersionHistoryProps {\n /** Optional unique identifier */\n id?: string;\n /** Object containing the versions mapped with their information */\n versionHistory: VersionHistoryType;\n}\n\n/**\n * Component to render the version history information shown in the footer component. Lists the 5\n * most recent versions, with the options to show all versions by pressing a button.\n *\n * @param versionHistory Object containing the versions mapped with their information\n * @param id Optional unique identifier\n * @returns Rendered version history for the Footer component\n */\nexport default function VersionHistory({ id, versionHistory }: VersionHistoryProps) {\n const [showAllVersions, setShowAllVersions] = useState(false);\n const currentDate = new Date();\n\n /**\n * Function to format the time string for the version history in the form of 'X year(s) ago'.\n *\n * @param dateString ISO Date string to determine the time string from\n * @returns Formatted time string\n */\n function formatTimeString(dateString: string) {\n const date = new Date(dateString);\n const dateDiff = new Date(currentDate.getTime() - date.getTime());\n const yearDiff = dateDiff.getUTCFullYear() - 1970;\n const monthDiff = dateDiff.getUTCMonth();\n const dayDiff = dateDiff.getUTCDate() - 1;\n\n // Determines how long ago the version was published\n let timeString = '';\n if (yearDiff > 0) {\n timeString = `${yearDiff.toString()} year${yearDiff === 1 ? '' : 's'} ago`;\n } else if (monthDiff > 0) {\n timeString = `${monthDiff.toString()} month${monthDiff === 1 ? '' : 's'} ago`;\n } else if (dayDiff === 0) {\n timeString = 'today';\n } else {\n timeString = `${dayDiff.toString()} day${dayDiff === 1 ? '' : 's'} ago`;\n }\n\n return timeString;\n }\n\n // Sorts the version history by version number\n const sortedEntries = Object.entries(versionHistory).sort((a, b) => b[0].localeCompare(a[0]));\n\n return (\n
    \n

    What`s New

    \n
      \n {(showAllVersions ? sortedEntries : sortedEntries.slice(0, 5)).map((entry) => (\n
      \n
      \n
    • \n {entry[1].description}\n
    • \n
      \n
      \n
      Version {entry[0]}
      \n
      {formatTimeString(entry[1].date)}
      \n
      \n
      \n ))}\n
    \n {sortedEntries.length > 5 && (\n setShowAllVersions(!showAllVersions)}\n className=\"tw-text-xs tw-text-gray-500 tw-underline\"\n >\n {showAllVersions ? 'Show Less Version History' : 'Show All Version History'}\n \n )}\n
    \n );\n}\n","import { useMemo } from 'react';\nimport { formatBytes } from 'platform-bible-utils';\nimport VersionHistory, { VersionHistoryType } from './version-history.component';\n\n/** Interface to store the parameters passed to the Footer component */\ninterface FooterProps {\n /** Optional unique identifier */\n id?: string;\n /** Name of the publisher */\n publisherDisplayName: string;\n /** Size of the extension file in bytes */\n fileSize: number;\n /** List of language codes supported by the extension */\n locales: string[];\n /** Object containing the version history mapped with their information */\n versionHistory: VersionHistoryType;\n}\n\n/**\n * Component to render the footer for the extension details which contains information on the\n * publisher, version history, languages, and file size.\n *\n * @param id Optional unique identifier\n * @param publisherDisplayName Name of the publisher\n * @param fileSize Size of the extension file in bytes\n * @param locales List of language codes supported by the extension\n * @param versionHistory Object containing the version history mapped with their information\n * @returns The rendered Footer component\n */\nexport default function Footer({\n id,\n publisherDisplayName,\n fileSize,\n locales,\n versionHistory,\n}: FooterProps) {\n /** Formats the file size into a human-readable format */\n const formattedFileSize = useMemo(() => formatBytes(fileSize), [fileSize]);\n\n /**\n * This function gets the display names of the languages based on the language codes.\n *\n * @param codes The list of language codes\n * @returns The list of language names\n */\n const getLanguageNames = (codes: string[]) => {\n const displayNames = new Intl.DisplayNames(navigator.language, { type: 'language' });\n return codes.map((code) => displayNames.of(code));\n };\n\n const languageNames = getLanguageNames(locales);\n\n return (\n
    \n
    \n \n
    \n
    \n

    Information

    \n
    \n

    \n Publisher\n {publisherDisplayName}\n Size\n {formattedFileSize}\n

    \n
    \n

    \n Languages\n {languageNames.join(', ')}\n

    \n
    \n
    \n
    \n
    \n
    \n );\n}\n","import { PlatformEvent, PlatformEventHandler } from 'platform-bible-utils';\nimport { useEffect } from 'react';\n\n/**\n * Adds an event handler to an event so the event handler runs when the event is emitted. Use\n * `papi.network.getNetworkEvent` to use a networked event with this hook.\n *\n * @param event The event to subscribe to.\n *\n * - If event is a `PlatformEvent`, that event will be used\n * - If event is undefined, the callback will not be subscribed. Useful if the event is not yet\n * available for example\n *\n * @param eventHandler The callback to run when the event is emitted\n *\n * WARNING: MUST BE STABLE - const or wrapped in useCallback. The reference must not be updated\n * every render\n */\nconst useEvent = (\n event: PlatformEvent | undefined,\n eventHandler: PlatformEventHandler,\n) => {\n useEffect(() => {\n // Do nothing if the event is not provided (in case the event is not yet available, for example)\n if (!event) return () => {};\n\n const unsubscriber = event(eventHandler);\n return () => {\n unsubscriber();\n };\n }, [event, eventHandler]);\n};\nexport default useEvent;\n","import { useCallback, useEffect } from 'react';\nimport { PlatformEvent, PlatformEventAsync, PlatformEventHandler } from 'platform-bible-utils';\nimport usePromise from './use-promise.hook';\n\nconst noopUnsubscriber = () => false;\n\n/**\n * Adds an event handler to an asynchronously subscribing/unsubscribing event so the event handler\n * runs when the event is emitted. Use `papi.network.getNetworkEvent` to use a networked event with\n * this hook.\n *\n * @param event The asynchronously (un)subscribing event to subscribe to.\n *\n * - If event is a `PlatformEvent` or `PlatformEventAsync`, that event will be used\n * - If event is undefined, the callback will not be subscribed. Useful if the event is not yet\n * available for example\n *\n * @param eventHandler The callback to run when the event is emitted\n *\n * WARNING: MUST BE STABLE - const or wrapped in useCallback. The reference must not be updated\n * every render\n */\nconst useEventAsync = (\n event: PlatformEvent | PlatformEventAsync | undefined,\n eventHandler: PlatformEventHandler,\n) => {\n // Subscribe to the event asynchronously\n const [unsubscribe] = usePromise(\n useCallback(async () => {\n // Do nothing if the event is not provided (in case the event is not yet available, for example)\n if (!event) return noopUnsubscriber;\n\n // Wrap subscribe and unsubscribe in promises to allow normal events to be used as well\n const unsub = await Promise.resolve(event(eventHandler));\n return async () => unsub();\n }, [eventHandler, event]),\n noopUnsubscriber,\n // We want the unsubscriber to return to default value immediately upon changing subscription\n // So the useEffect below will unsubscribe asap\n { preserveValue: false },\n );\n\n // Unsubscribe from the event asynchronously (but we aren't awaiting the unsub)\n useEffect(() => {\n return () => {\n if (unsubscribe !== noopUnsubscriber) {\n unsubscribe();\n }\n };\n }, [unsubscribe]);\n};\n\nexport default useEventAsync;\n"],"names":["twMergeCustom","extendTailwindMerge","cn","inputs","clsx","Input","React","className","type","props","ref","jsx","BookChapterInput","forwardRef","handleSearch","handleKeyDown","handleOnClick","handleSubmit","jsxs","ShadInput","event","e","History","P","R","s","n","N","B","O","S","K","g","k","x","T","X","V","w","L","G","A","H","C","I","y","q","U","m","l","h","c","E","D","i","a","o","u","v","f","d","b","J","DropdownMenu","DropdownMenuPrimitive","DropdownMenuTrigger","DropdownMenuGroup","DropdownMenuPortal","DropdownMenuSub","DropdownMenuRadioGroup","DropdownMenuSubTrigger","inset","children","ChevronRight","DropdownMenuSubContent","DropdownMenuContent","sideOffset","DropdownMenuItem","DropdownMenuCheckboxItem","checked","Check","DropdownMenuRadioItem","Circle","DropdownMenuLabel","DropdownMenuSeparator","DropdownMenuShortcut","BookMenuItem","bookId","handleSelectBook","isSelected","handleHighlightBook","bookType","ShadDropdownMenuItem","Canon","ChapterSelect","handleSelectChapter","endChapter","activeChapter","highlightedChapter","handleHighlightedChapter","chapters","_","handleMouse","useCallback","chapterNumber","chapter","GoToMenuItem","handleSort","handleLocationHistory","handleBookmarks","ShadDropdownMenuLabel","ArrowDownWideNarrow","Clock","Bookmark","ALL_BOOK_IDS","BOOK_TYPE_LABELS","BOOK_TYPE_ARRAY","SCROLL_OFFSET","SEARCH_QUERY_FORMATS","fetchGroupedBooks","fetchEndChapter","getChaptersForBook","getAllEnglishNames","isValidBookEnglishName","bookName","getBookIdFromEnglishName","formattedBookName","BookChapterControl","scrRef","searchQuery","setSearchQuery","useState","selectedBookId","setSelectedBookId","setHighlightedChapter","highlightedBookId","setHighlightedBookId","isContentOpen","setIsContentOpen","isContentOpenDelayed","setIsContentOpenDelayed","inputRef","useRef","contentRef","menuItemRef","fetchFilteredBooks","englishNameLowerCase","normalizedQuery","handleSearchInput","searchString","shouldPreventAutoClosing","controlMenuState","open","updateReference","shouldClose","verse","handleInputSubmit","format","matches","book","englishName","handleKeyDownInput","handleKeyDownContent","key","handleKeyDownMenuItem","chapterOffSet","useEffect","useLayoutEffect","scrollTimeout","scrollPosition","ShadDropdownMenu","ShadDropdownMenuTrigger","ShadDropdownMenuContent","bookTypeIndex","element","ShadDropdownMenuSeparator","buttonVariants","cva","Button","variant","size","asChild","Slot","labelVariants","Label","LabelPrimitive","RadioGroup","RadioGroupPrimitive","RadioGroupItem","Popover","PopoverPrimitive","PopoverTrigger","PopoverContent","align","DialogPortal","DialogPrimitive","DialogOverlay","DialogContent","DialogTitle","DialogDescription","Command","CommandPrimitive","CommandInput","Search","CommandList","CommandEmpty","CommandGroup","CommandSeparator","CommandItem","getOptionLabelDefault","option","ComboBox","id","options","buttonClassName","popoverContentClassName","value","onChange","getOptionLabel","buttonPlaceholder","textPlaceholder","commandEmptyMessage","buttonVariant","dir","isDisabled","setOpen","ChevronsUpDown","ChapterRangeSelector","startChapter","handleSelectStartChapter","handleSelectEndChapter","chapterCount","chapterOptions","useMemo","index","Fragment","BookSelectionMode","BOOK_SELECTOR_STRING_KEYS","localizeString","strings","BookSelector","handleBookSelectionModeChange","currentBookName","onSelectBooks","selectedBookIds","localizedStrings","currentBookText","chooseText","chooseBooksText","bookSelectionMode","setBookSelectionMode","onSelectionModeChange","newMode","DataTableViewOptions","table","FilterIcon","column","Select","SelectPrimitive","SelectGroup","SelectValue","SelectTrigger","ChevronDown","SelectScrollUpButton","ChevronUp","SelectScrollDownButton","SelectContent","position","SelectLabel","SelectItem","SelectSeparator","DataTablePagination","pageSize","ArrowLeftIcon","ChevronLeftIcon","ChevronRightIcon","ArrowRightIcon","Table","stickyHeader","TableHeader","TableBody","TableFooter","TableRow","TableHead","TableCell","TableCaption","DataTable","columns","data","enablePagination","showPaginationControls","showColumnVisibilityControls","onRowClickHandler","sorting","setSorting","columnFilters","setColumnFilters","columnVisibility","setColumnVisibility","rowSelection","setRowSelection","useReactTable","getCoreRowModel","getPaginationRowModel","getSortedRowModel","getFilteredRowModel","headerGroup","header","flexRender","_a","row","cell","OccurrencesTable","occurrenceData","setScriptureReference","referenceHeaderText","occurrenceHeaderText","occurrences","uniqueOccurrences","occurrence","uniqueOccurrence","deepEqual","Checkbox","CheckboxPrimitive","getLinesFromUSFM","text","getNumberFromUSFM","regex","match","getBookNumFromId","getStatusForItem","item","approvedItems","unapprovedItems","toggleVariants","Toggle","TogglePrimitive","ToggleGroupContext","ToggleGroup","ToggleGroupPrimitive","ToggleGroupItem","context","getSortingIcon","sortDirection","ArrowUpIcon","ArrowDownIcon","ArrowUpDownIcon","inventoryItemColumn","itemLabel","inventoryAdditionalItemColumn","additionalItemLabel","additionalItemIndex","inventoryCountColumn","countLabel","statusChangeHandler","changedItems","newStatus","onApprovedItemsChange","onUnapprovedItemsChange","newApprovedItems","validItem","newUnapprovedItems","unapprovedItem","inventoryStatusColumn","statusLabel","status","CircleCheckIcon","CircleXIcon","CircleHelpIcon","INVENTORY_STRING_KEYS","filterItemData","itemData","statusFilter","textFilter","filteredItemData","createTableData","scriptureRef","itemRegex","tableData","currentBook","currentChapter","currentVerse","line","items","itemIndex","existingItem","tableEntry","newReference","substring","newItem","Inventory","scriptureReference","extractItems","additionalItemsLabels","scope","onScopeChange","allItemsText","approvedItemsText","unapprovedItemsText","unknownItemsText","scopeBookText","scopeChapterText","scopeVerseText","filterText","showAdditionalItemsText","showAdditionalItems","setShowAdditionalItems","setStatusFilter","setTextFilter","selectedItem","setSelectedItem","reducedTableData","newTableData","firstItem","existingEntry","newTableEntry","filteredTableData","allColumns","numberOfAdditionalItems","additionalColumns","_b","rowClickHandler","newSelection","handleScopeChange","handleStatusFilterChange","SearchBar","onSearch","placeholder","isFullWidth","handleInputChange","VerticalTabs","TabsPrimitive","VerticalTabsList","VerticalTabsTrigger","VerticalTabsContent","TabNavigationContentSearch","tabList","searchPlaceholder","headerTitle","isSearchBarFullWidth","direction","tab","Separator","orientation","decorative","SeparatorPrimitive","Sheet","SheetPrimitive","SheetPortal","SheetOverlay","sheetVariants","SheetContent","side","SheetTitle","SheetDescription","Skeleton","TooltipProvider","TooltipPrimitive","Tooltip","TooltipTrigger","TooltipContent","MOBILE_BREAKPOINT","useIsMobile","isMobile","setIsMobile","mql","SIDEBAR_COOKIE_NAME","SIDEBAR_COOKIE_MAX_AGE","SIDEBAR_WIDTH","SIDEBAR_WIDTH_MOBILE","SIDEBAR_WIDTH_ICON","SIDEBAR_KEYBOARD_SHORTCUT","SidebarContext","useSidebar","SidebarProvider","defaultOpen","openProp","setOpenProp","style","openMobile","setOpenMobile","_open","_setOpen","isOpen","openState","toggleSidebar","state","contextValue","Sidebar","collapsible","SidebarTrigger","onClick","PanelLeft","SidebarRail","SidebarInset","SidebarInput","SidebarHeader","SidebarFooter","SidebarSeparator","SidebarContent","SidebarGroup","SidebarGroupLabel","SidebarGroupAction","SidebarGroupContent","SidebarMenu","SidebarMenuItem","sidebarMenuButtonVariants","SidebarMenuButton","isActive","tooltip","Comp","button","SidebarMenuAction","showOnHover","SidebarMenuBadge","SidebarMenuSkeleton","showIcon","width","SidebarMenuSub","SidebarMenuSubItem","SidebarMenuSubButton","SettingsSidebar","extensionLabels","projectOptions","handleSelectSidebarItem","selectedSidebarItem","handleSelectItem","projectId","getProjectNameFromProjectId","project","getIsActive","label","selectedProjectName","SettingsSidebarContentSearch","scrBookColId","scrRefColId","typeColId","detailsColId","defaultScrRefColumnName","defaultScrBookGroupName","defaultTypeColumnName","defaultDetailsColumnName","getColumns","colInfo","showSourceColumn","showSrcCol","info","formatScrRef","compareScrRefs","toRefOrRange","scriptureSelection","offsetStart","offsetEnd","scrRefToBBBCCCVVV","getRowKey","ScriptureResultsViewer","sources","showColumnHeaders","scriptureReferenceColumnName","scriptureBookGroupName","typeColumnName","detailsColumnName","onRowSelected","grouping","setGrouping","scriptureResults","source","getExpandedRowModel","getGroupedRowModel","selectedRows","keys","selectedRow","scrBookGroupName","typeGroupName","groupingOptions","handleSelectChange","selectedGrouping","handleRowClick","getEvenOrOddBandingStyle","getIndent","groupingState","rowIndex","ChevronLeft","DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS","getLocalizeKeyForScrollGroupId","ScrollGroupSelector","availableScrollGroupIds","scrollGroupId","onChangeScrollGroupId","localizedStringsDefaulted","localizedStringKey","localizedStringValue","newScrollGroupString","scrollGroupOptionId","SettingsList","SettingsListItem","primary","secondary","isLoading","loadingMessage","SettingsListHeader","includeSeparator","Checklist","listItems","selectedListItems","handleSelectListItem","createLabel","_interopRequireDefault","obj","module","chainPropTypes","propType1","propType2","args","_extends","target","isPlainObject","prototype","deepClone","output","deepmerge","p","r","t","z","reactIs_production_min","hasSymbol","REACT_ELEMENT_TYPE","REACT_PORTAL_TYPE","REACT_FRAGMENT_TYPE","REACT_STRICT_MODE_TYPE","REACT_PROFILER_TYPE","REACT_PROVIDER_TYPE","REACT_CONTEXT_TYPE","REACT_ASYNC_MODE_TYPE","REACT_CONCURRENT_MODE_TYPE","REACT_FORWARD_REF_TYPE","REACT_SUSPENSE_TYPE","REACT_SUSPENSE_LIST_TYPE","REACT_MEMO_TYPE","REACT_LAZY_TYPE","REACT_BLOCK_TYPE","REACT_FUNDAMENTAL_TYPE","REACT_RESPONDER_TYPE","REACT_SCOPE_TYPE","isValidElementType","typeOf","object","$$typeof","$$typeofType","AsyncMode","ConcurrentMode","ContextConsumer","ContextProvider","Element","ForwardRef","Lazy","Memo","Portal","Profiler","StrictMode","Suspense","hasWarnedAboutDeprecatedIsAsyncMode","isAsyncMode","isConcurrentMode","isContextConsumer","isContextProvider","isElement","isForwardRef","isFragment","isLazy","isMemo","isPortal","isProfiler","isStrictMode","isSuspense","reactIs_development","reactIsModule","require$$0","require$$1","getOwnPropertySymbols","hasOwnProperty","propIsEnumerable","toObject","val","shouldUseNative","test1","test2","order2","test3","letter","objectAssign","from","to","symbols","ReactPropTypesSecret","ReactPropTypesSecret_1","has","printWarning","loggedTypeFailures","message","checkPropTypes","typeSpecs","values","location","componentName","getStack","typeSpecName","error","err","ex","stack","checkPropTypes_1","ReactIs","assign","require$$2","require$$3","require$$4","emptyFunctionThatReturnsNull","factoryWithTypeCheckers","isValidElement","throwOnDirectAccess","ITERATOR_SYMBOL","FAUX_ITERATOR_SYMBOL","getIteratorFn","maybeIterable","iteratorFn","ANONYMOUS","ReactPropTypes","createPrimitiveTypeChecker","createAnyTypeChecker","createArrayOfTypeChecker","createElementTypeChecker","createElementTypeTypeChecker","createInstanceTypeChecker","createNodeChecker","createObjectOfTypeChecker","createEnumTypeChecker","createUnionTypeChecker","createShapeTypeChecker","createStrictShapeTypeChecker","is","PropTypeError","createChainableTypeChecker","validate","manualPropTypeCallCache","manualPropTypeWarningCount","checkType","isRequired","propName","propFullName","secret","cacheKey","chainedCheckType","expectedType","propValue","propType","getPropType","preciseType","getPreciseType","typeChecker","expectedClass","expectedClassName","actualClassName","getClassName","expectedValues","valuesString","arrayOfTypeCheckers","checker","getPostfixForTypeWarning","expectedTypes","checkerResult","expectedTypesMessage","isNode","invalidValidatorError","shapeTypes","allKeys","iterator","step","entry","isSymbol","emptyFunction","emptyFunctionWithReset","factoryWithThrowingShims","shim","getShim","propTypesModule","isClassComponent","elementType","acceptingRef","safePropName","warningHint","elementAcceptingRef","PropTypes","elementAcceptingRef$1","specialProperty","exactProp","propTypes","unsupportedProps","prop","formatMuiErrorMessage","code","url","REACT_SERVER_CONTEXT_TYPE","REACT_OFFSCREEN_TYPE","enableScopeAPI","enableCacheElement","enableTransitionTracing","enableLegacyHidden","enableDebugTracing","REACT_MODULE_REFERENCE","SuspenseList","hasWarnedAboutDeprecatedIsConcurrentMode","isSuspenseList","fnNameMatchRegex","getFunctionName","fn","getFunctionComponentName","Component","fallback","getWrappedName","outerType","innerType","wrapperName","functionName","getDisplayName","HTMLElementType","refType","refType$1","capitalize","string","_formatMuiErrorMessage","createChainedFunction","funcs","acc","func","debounce","wait","timeout","debounced","later","deprecatedPropType","validator","reason","componentNameSafe","propFullNameSafe","isMuiElement","muiNames","_muiName","_element$type","ownerDocument","node","ownerWindow","requirePropFactory","componentNameInError","prevPropTypes","requiredProp","defaultTypeChecker","typeCheckerResult","setRef","useEnhancedEffect","useEnhancedEffect$1","globalId","useGlobalId","idOverride","defaultId","setDefaultId","maybeReactUseId","useId","reactId","unsupportedProp","useControlled","controlled","defaultProp","name","isControlled","valueState","setValue","defaultValue","setValueIfUncontrolled","newValue","useEventCallback","useForkRef","refs","instance","UNINITIALIZED","useLazyRef","init","initArg","EMPTY","useOnMount","Timeout","delay","useTimeout","hadKeyboardEvent","hadFocusVisibleRecently","hadFocusVisibleRecentlyTimeout","inputTypesWhitelist","focusTriggersKeyboardModality","tagName","handlePointerDown","handleVisibilityChange","prepare","doc","isFocusVisible","useIsFocusVisible","isFocusVisibleRef","handleBlurVisible","handleFocusVisible","resolveProps","defaultProps","defaultSlotProps","slotProps","slotPropName","composeClasses","slots","getUtilityClass","classes","slot","utilityClass","defaultGenerator","createClassNameGenerator","generate","generator","ClassNameGenerator","ClassNameGenerator$1","globalStateClasses","generateUtilityClass","globalStatePrefix","globalStateClass","generateUtilityClasses","result","clamp","min","max","_objectWithoutPropertiesLoose","excluded","sourceKeys","_excluded","sortBreakpointsValues","breakpointsAsArray","breakpoint1","breakpoint2","createBreakpoints","breakpoints","unit","other","sortedValues","up","down","between","start","end","endIndex","only","not","keyIndex","shape","shape$1","responsivePropType","responsivePropType$1","merge","defaultBreakpoints","handleBreakpoints","styleFromPropValue","theme","themeBreakpoints","breakpoint","mediaKey","cssKey","createEmptyBreakpointObject","breakpointsInput","_breakpointsInput$key","breakpointStyleKey","removeUnusedBreakpoints","breakpointKeys","breakpointOutput","getPath","path","checkVars","getStyleValue","themeMapping","transform","propValueFinal","userValue","cssProperty","themeKey","memoize","cache","arg","properties","directions","aliases","getCssProperties","property","marginKeys","paddingKeys","spacingKeys","createUnaryUnit","_getPath","themeSpacing","abs","createUnarySpacing","getValue","transformer","transformed","getStyleFromPropValue","cssProperties","resolveCssProperty","margin","padding","createSpacing","spacingInput","spacing","argsInput","argument","compose","styles","handlers","borderTransform","createBorderStyle","border","borderTop","borderRight","borderBottom","borderLeft","borderColor","borderTopColor","borderRightColor","borderBottomColor","borderLeftColor","outline","outlineColor","borderRadius","gap","columnGap","rowGap","gridColumn","gridRow","gridAutoFlow","gridAutoColumns","gridAutoRows","gridTemplateColumns","gridTemplateRows","gridTemplateAreas","gridArea","paletteTransform","color","bgcolor","backgroundColor","sizingTransform","maxWidth","_props$theme","_props$theme2","breakpointsValues","minWidth","height","maxHeight","minHeight","boxSizing","defaultSxConfig","defaultSxConfig$1","objectsHaveSameKeys","objects","union","callIfFn","maybeFn","unstable_createStyleFunctionSx","getThemeValue","config","styleFunctionSx","_theme$unstable_sxCon","sx","traverse","sxInput","sxObject","emptyBreakpoints","breakpointsKeys","css","styleKey","styleFunctionSx$1","applyStyles","createTheme","paletteInput","shapeInput","muiTheme","isObjectEmpty","useTheme","defaultTheme","contextTheme","ThemeContext","systemDefaultTheme","useThemeWithoutDefault","_excluded2","_excluded3","isEmpty","isStringTag","tag","shouldForwardProp","lowercaseFirstLetter","resolveTheme","themeId","defaultOverridesResolver","processStyleArg","callableStyle","_ref","ownerState","resolvedStylesArg","resolvedStyle","variants","isMatch","createStyled","input","rootShouldForwardProp","slotShouldForwardProp","systemSx","inputOptions","processStyles","componentSlot","inputSkipVariantsResolver","inputSkipSx","overridesResolver","skipVariantsResolver","skipSx","shouldForwardPropOption","defaultStyledResolver","styledEngineStyled","transformStyleArg","stylesArg","muiStyledResolver","styleArg","expressions","transformedStyleArg","expressionsWithDefaultTheme","styleOverrides","resolvedStyleOverrides","slotKey","slotStyle","_theme$components","themeVariants","numOfCustomFnsApplied","placeholders","displayName","getThemeProps","params","useThemeProps","clampWrapper","hexToRgb","re","colors","decomposeColor","marker","colorSpace","recomposeColor","hslToRgb","rgb","getLuminance","getContrastRatio","foreground","background","lumA","lumB","alpha","darken","coefficient","lighten","createMixins","mixins","common","common$1","grey","grey$1","purple","purple$1","red","red$1","orange","orange$1","blue","blue$1","lightBlue","lightBlue$1","green","green$1","light","dark","addLightOrDark","intent","shade","tonalOffset","tonalOffsetLight","tonalOffsetDark","getDefaultPrimary","mode","getDefaultSecondary","getDefaultError","getDefaultInfo","getDefaultSuccess","getDefaultWarning","createPalette","palette","contrastThreshold","success","warning","getContrastText","contrastText","contrast","augmentColor","mainShade","lightShade","darkShade","modes","round","caseAllCaps","defaultFontFamily","createTypography","typography","fontFamily","fontSize","fontWeightLight","fontWeightRegular","fontWeightMedium","fontWeightBold","htmlFontSize","allVariants","pxToRem2","coef","pxToRem","buildVariant","fontWeight","lineHeight","letterSpacing","casing","shadowKeyUmbraOpacity","shadowKeyPenumbraOpacity","shadowAmbientShadowOpacity","createShadow","px","shadows","shadows$1","easing","duration","formatMs","milliseconds","getAutoHeightDuration","constant","createTransitions","inputTransitions","mergedEasing","mergedDuration","durationOption","easingOption","isString","isNumber","animatedProp","zIndex","zIndex$1","mixinsInput","transitionsInput","typographyInput","systemTheme","systemCreateTheme","stateClasses","component","child","stateClass","defaultTheme$1","THEME_ID","systemUseThemeProps","styled","styled$1","getSvgIconUtilityClass","useUtilityClasses","SvgIconRoot","_theme$transitions","_theme$transitions$cr","_theme$transitions2","_theme$typography","_theme$typography$pxT","_theme$typography2","_theme$typography2$px","_theme$typography3","_theme$typography3$px","_palette$ownerState$c","_palette","_palette2","_palette3","SvgIcon","inProps","htmlColor","inheritViewBox","titleAccess","viewBox","hasSvgAsChild","more","_jsxs","_jsx","SvgIcon$1","createSvgIcon","unstable_ClassNameGenerator","exports","_utils","ArrowRight","default_1","_createSvgIcon","_jsxRuntime","isHostComponent","appendOwnerState","otherProps","defaultContextValue","ClassNameConfiguratorContext","useClassNamesOverride","disableDefaultClasses","extractEventHandlers","excludeKeys","resolveComponentProps","componentProps","slotState","omitEventHandlers","mergeSlotProps","parameters","getSlotProps","additionalProps","externalSlotProps","externalForwardedProps","joinedClasses","mergedStyle","eventHandlers","componentsPropsWithoutEventHandlers","otherPropsWithoutEventHandlers","internalSlotProps","useSlotProps","_parameters$additiona","skipResolvingSlotProps","rest","resolvedComponentsProps","mergedProps","internalRef","GLOBAL_CLASS_PREFIX","buildStateClass","buildSlotClass","getContainer","container","forwardedRef","disablePortal","mountNode","setMountNode","handleRef","newProps","ReactDOM","top","bottom","right","left","auto","basePlacements","clippingParents","viewport","popper","reference","variationPlacements","placement","placements","beforeRead","read","afterRead","beforeMain","main","afterMain","beforeWrite","write","afterWrite","modifierPhases","getNodeName","getWindow","OwnElement","isHTMLElement","isShadowRoot","attributes","effect","_ref2","initialStyles","styleProperties","attribute","applyStyles$1","getBasePlacement","getUAString","uaData","isLayoutViewport","getBoundingClientRect","includeScale","isFixedStrategy","clientRect","scaleX","scaleY","visualViewport","addVisualOffsets","getLayoutRect","contains","parent","rootNode","next","getComputedStyle","isTableElement","getDocumentElement","getParentNode","getTrueOffsetParent","getContainingBlock","isFirefox","isIE","elementCss","currentNode","getOffsetParent","window","offsetParent","getMainAxisFromPlacement","within","mathMax","mathMin","withinMaxClamp","getFreshSideObject","mergePaddingObject","paddingObject","expandToHashMap","hashMap","toPaddingObject","arrow","_state$modifiersData$","arrowElement","popperOffsets","basePlacement","axis","isVertical","len","arrowRect","minProp","maxProp","endDiff","startDiff","arrowOffsetParent","clientSize","centerToReference","center","offset","axisProp","_options$element","arrow$1","getVariation","unsetSides","roundOffsetsByDPR","win","dpr","mapToStyles","_Object$assign2","popperRect","variation","offsets","gpuAcceleration","adaptive","roundOffsets","isFixed","_offsets$x","_offsets$y","_ref3","hasX","hasY","sideX","sideY","heightProp","widthProp","offsetY","offsetX","commonStyles","_ref4","_Object$assign","computeStyles","_ref5","_options$gpuAccelerat","_options$adaptive","_options$roundOffsets","computeStyles$1","passive","_options$scroll","scroll","_options$resize","resize","scrollParents","scrollParent","eventListeners","hash","getOppositePlacement","matched","getOppositeVariationPlacement","getWindowScroll","scrollLeft","scrollTop","getWindowScrollBarX","getViewportRect","strategy","html","layoutViewport","getDocumentRect","_element$ownerDocumen","winScroll","body","isScrollParent","_getComputedStyle","overflow","overflowX","overflowY","getScrollParent","listScrollParents","list","isBody","updatedList","rectToClientRect","rect","getInnerBoundingClientRect","getClientRectFromMixedType","clippingParent","getClippingParents","canEscapeClipping","clipperElement","getClippingRect","boundary","rootBoundary","mainClippingParents","firstClippingParent","clippingRect","accRect","computeOffsets","commonX","commonY","mainAxis","detectOverflow","_options","_options$placement","_options$strategy","_options$boundary","_options$rootBoundary","_options$elementConte","elementContext","_options$altBoundary","altBoundary","_options$padding","altContext","clippingClientRect","referenceClientRect","popperClientRect","elementClientRect","overflowOffsets","offsetData","multiply","computeAutoPlacement","flipVariations","_options$allowedAutoP","allowedAutoPlacements","allPlacements","allowedPlacements","overflows","getExpandedFallbackPlacements","oppositePlacement","flip","_options$mainAxis","checkMainAxis","_options$altAxis","checkAltAxis","specifiedFallbackPlacements","_options$flipVariatio","preferredPlacement","isBasePlacement","fallbackPlacements","referenceRect","checksMap","makeFallbackChecks","firstFittingPlacement","_basePlacement","isStartVariation","mainVariationSide","altVariationSide","checks","check","numberOfChecks","_loop","_i","fittingPlacement","_ret","flip$1","getSideOffsets","preventedOffsets","isAnySideFullyClipped","hide","referenceOverflow","popperAltOverflow","referenceClippingOffsets","popperEscapeOffsets","isReferenceHidden","hasPopperEscaped","hide$1","distanceAndSkiddingToXY","rects","invertDistance","skidding","distance","_options$offset","_data$state$placement","offset$1","popperOffsets$1","getAltAxis","preventOverflow","_options$tether","tether","_options$tetherOffset","tetherOffset","altAxis","tetherOffsetValue","normalizedTetherOffsetValue","offsetModifierState","_offsetModifierState$","mainSide","altSide","additive","minLen","maxLen","arrowPaddingObject","arrowPaddingMin","arrowPaddingMax","arrowLen","minOffset","maxOffset","clientOffset","offsetModifierValue","tetherMin","tetherMax","preventedOffset","_offsetModifierState$2","_mainSide","_altSide","_offset","_len","_min","_max","isOriginSide","_offsetModifierValue","_tetherMin","_tetherMax","_preventedOffset","preventOverflow$1","getHTMLElementScroll","getNodeScroll","isElementScaled","getCompositeRect","elementOrVirtualElement","isOffsetParentAnElement","offsetParentIsScaled","documentElement","order","modifiers","map","visited","modifier","sort","requires","dep","depModifier","orderModifiers","orderedModifiers","phase","pending","resolve","mergeByName","merged","current","existing","DEFAULT_OPTIONS","areValidElements","_key","popperGenerator","generatorOptions","_generatorOptions","_generatorOptions$def","defaultModifiers","_generatorOptions$def2","defaultOptions","effectCleanupFns","isDestroyed","setOptionsAction","cleanupModifierEffects","runModifierEffects","_state$elements","_state$orderedModifie","_state$orderedModifie2","_ref$options","cleanupFn","noopFn","createPopper","COMPONENT_NAME","getPopperUtilityClass","flipPlacement","resolveAnchorEl","anchorEl","isVirtualElement","defaultPopperOptions","PopperTooltip","_slots$root","initialPlacement","popperOptions","popperRefProp","TransitionProps","tooltipRef","ownRef","popperRef","handlePopperRef","handlePopperRefRef","rtlPlacement","setPlacement","resolvedAnchorElement","setResolvedAnchorElement","handlePopperUpdate","box","popperModifiers","childProps","Root","rootProps","Popper","containerProp","keepMounted","transition","exited","setExited","handleEnter","handleExited","resolvedAnchorEl","display","transitionProps","useThemeSystem","_setPrototypeOf","_inheritsLoose","subClass","superClass","setPrototypeOf","timeoutsShape","TransitionGroupContext","forceReflow","UNMOUNTED","EXITED","ENTERING","ENTERED","EXITING","Transition","_React$Component","_this","parentGroup","appear","initialStatus","prevState","nextIn","_proto","prevProps","nextStatus","exit","enter","mounting","_this2","appearing","maybeNode","maybeAppearing","timeouts","enterTimeout","_this3","nextState","callback","_this4","active","handler","doesNotHaveTimeoutOrListener","maybeNextCallback","_this$props","pt","noop","Transition$1","reflow","getTransitionProps","_style$transitionDura","_style$transitionTimi","getScale","isWebKit154","Grow","addEndListener","inProp","onEnter","onEntered","onEntering","onExit","onExited","onExiting","TransitionComponent","timer","autoTimeout","nodeRef","normalizedTransitionCallback","maybeIsAppearing","handleEntering","isAppearing","transitionDuration","transitionTimingFunction","handleEntered","handleExiting","handleExit","Grow$1","PopperRoot","BasePopper","components","componentsProps","RootComponent","Popper$1","getTooltipUtilityClass","tooltipClasses","tooltipClasses$1","disableInteractive","touch","TooltipPopper","TooltipTooltip","TooltipArrow","hystersisOpen","hystersisTimer","cursorPosition","composeEventHandler","eventHandler","_slots$popper","_slots$transition","_slots$tooltip","_slots$arrow","_slotProps$popper","_ref6","_slotProps$popper2","_slotProps$transition","_slotProps$tooltip","_ref7","_slotProps$tooltip2","_slotProps$arrow","_ref8","_slotProps$arrow2","childrenProp","describeChild","disableFocusListener","disableHoverListener","disableInteractiveProp","disableTouchListener","enterDelay","enterNextDelay","enterTouchDelay","followCursor","idProp","leaveDelay","leaveTouchDelay","onClose","onOpen","PopperComponentProp","PopperProps","title","TransitionComponentProp","isRtl","childNode","setChildNode","arrowRef","setArrowRef","ignoreNonTouchEvents","closeTimer","enterTimer","leaveTimer","touchTimer","setOpenState","prevUserSelect","stopTouchInteraction","handleOpen","handleClose","handleLeave","focusVisibleRef","setChildIsFocusVisible","handleBlur","handleFocus","detectTouchStart","childrenProps","handleMouseOver","handleMouseLeave","handleTouchStart","handleTouchEnd","nativeEvent","handleMouseMove","nameOrDescProps","titleIsString","interactiveWrapperListeners","_PopperProps$popperOp","tooltipModifiers","PopperComponent","TooltipComponent","ArrowComponent","popperProps","tooltipProps","tooltipArrowProps","TransitionPropsInner","Tooltip$1","getIcon","icon","menuLabel","leading","MuiListItemIcon","MenuItem","allowForLeadingIcons","iconPathBefore","iconPathAfter","hasAutoFocus","isDense","isSubMenuParent","hasDisabledGutters","hasDivider","focusVisibleClassName","menuItem","MuiMenuItem","MuiListItemText","getAllGroups","menuDefinition","SubMenu","setAnchorEl","parentMenuItem","parentItemProps","handleParentMenuItemClick","renderSubMenuItems","includedGroups","group","GroupedMenuItemList","Menu","getOrderedGroupItems","groupId","allItems","menuProps","commandHandler","groupsToInclude","sortedGroups","itemArray","allowSpaceForLeadingIcons","createMenuItemProps","isLastItemInGroup","divKey","itemInfo","menuItemProps","TopLevelMenu","columnId","MenuColumn","metadata","Grid","List","GridMenu","multiColumnMenu","sortedColumns","columnNumbers","columnName","col","getUsePromiseOptionsDefaults","usePromise","promiseFactoryCallback","defaultValueRef","optionsDefaultedRef","setIsLoading","promiseIsCurrent","MenuIcon","HamburgerMenuButton","menuProvider","normalMenu","fullMenu","containerRef","ariaLabelPrefix","isMenuOpen","setMenuOpen","showFullMenu","setShowFullMenu","handleMenuItemClick","handleMenuButtonClick","prevIsOpen","isOpening","menuCommandHandler","command","setOffset","normalMenuData","fullMenuData","menu","IconButton","Drawer","isTooltipSuppressed","adjustMarginToAlignToEdge","MuiIconButton","Spinner","LoaderCircle","TextField","hasError","helperText","onFocus","onBlur","ShadLabel","Toolbar","AppBar","MuiToolbar","alertVariants","Alert","AlertTitle","AlertDescription","Card","CardHeader","CardTitle","CardDescription","CardContent","CardFooter","Sonner","Toaster","Slider","SliderPrimitive","Switch","SwitchPrimitives","Tabs","TabsList","TabsTrigger","TabsContent","InstallButton","isInstalling","handleClick","buttonText","Download","EnableButton","isEnabling","DisableButton","isDisabling","UpdateButton","isUpdating","MarkdownRenderer","markdown","anchorTarget","Markdown","FilterButton","Filter","DropdownMenuItemType","DropdownMenuItemType2","FilterDropdown","groups","NoExtensionsFound","MoreInfo","category","downloads","languages","moreInfoUrl","numberFormatted","NumberFormat","handleScrollToBottom","User","locale","LucideLink","CircleHelp","VersionHistory","versionHistory","showAllVersions","setShowAllVersions","currentDate","formatTimeString","dateString","date","dateDiff","yearDiff","monthDiff","dayDiff","timeString","sortedEntries","Footer","publisherDisplayName","fileSize","locales","formattedFileSize","formatBytes","langu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;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","x_google_ignoreList":[3,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,83,84,85,86,87,88,89,90,91,92,93,94,95,96,97,98,99,100,101,102,103,104,105,106,107,108,109,110,111,112,113,114,115,116,117,118,119,120,121,122,123,124,125,126,127,128,129,130,131,132,133,134,135,136,137,138,139,140,141,142,143,144,145,146,147,148,149,150,151,152,153,154,155,156,157,158,159,160,161,162,163,164,165,166,167,168,169,170,171,172,173,174,175,176,177,178,179,180,181,182,183,184,185,186,187,188,189,190,191,192,193,194,195,196,197,198,199,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,228]} \ No newline at end of file +{"version":3,"file":"index.js","sources":["../src/utils/shadcn-ui.util.ts","../src/components/shadcn-ui/input.tsx","../src/components/advanced/book-chapter-control/book-chapter-input.component.tsx","../../../node_modules/@sillsdev/scripture/dist/index.es.js","../src/components/shadcn-ui/dropdown-menu.tsx","../src/components/advanced/book-chapter-control/book-menu-item.component.tsx","../src/components/advanced/book-chapter-control/chapter-select.component.tsx","../src/components/advanced/book-chapter-control/go-to-menu-item.component.tsx","../src/components/advanced/book-chapter-control/book-chapter-control.component.tsx","../src/components/shadcn-ui/button.tsx","../src/components/shadcn-ui/label.tsx","../src/components/shadcn-ui/radio-group.tsx","../src/components/shadcn-ui/popover.tsx","../src/components/shadcn-ui/dialog.tsx","../src/components/shadcn-ui/command.tsx","../src/components/basics/combo-box.component.tsx","../src/components/basics/chapter-range-selector.component.tsx","../src/components/advanced/book-selector.component.tsx","../src/components/advanced/data-table/data-table-column-toggle.component.tsx","../src/components/shadcn-ui/select.tsx","../src/components/advanced/data-table/data-table-pagination.component.tsx","../src/components/shadcn-ui/table.tsx","../src/components/advanced/data-table/data-table.component.tsx","../src/components/advanced/inventory/occurrences-table.component.tsx","../src/components/shadcn-ui/checkbox.tsx","../src/components/advanced/inventory/inventory-utils.ts","../src/components/shadcn-ui/toggle.tsx","../src/components/shadcn-ui/toggle-group.tsx","../src/components/advanced/inventory/inventory-columns.tsx","../src/components/advanced/inventory/inventory.component.tsx","../src/components/basics/search-bar.component.tsx","../src/components/basics/tabs-vertical.tsx","../src/components/advanced/tab-navigation-content-search.component.tsx","../src/components/shadcn-ui/separator.tsx","../src/components/shadcn-ui/sheet.tsx","../src/components/shadcn-ui/skeleton.tsx","../src/components/shadcn-ui/tooltip.tsx","../src/components/hooks/use-mobile.tsx","../src/components/shadcn-ui/sidebar.tsx","../src/components/advanced/settings-components/settings-sidebar.component.tsx","../src/components/advanced/settings-components/settings-sidebar-content-search.component.tsx","../src/components/advanced/scripture-results-viewer/scripture-results-viewer.component.tsx","../src/components/advanced/scroll-group-selector.component.tsx","../src/components/advanced/settings-components/settings-list.component.tsx","../src/components/basics/checklist.component.tsx","../../../node_modules/@babel/runtime/helpers/interopRequireDefault.js","../../../node_modules/@mui/utils/chainPropTypes/chainPropTypes.js","../../../node_modules/@babel/runtime/helpers/esm/extends.js","../../../node_modules/@mui/utils/deepmerge/deepmerge.js","../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.production.min.js","../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.development.js","../../../node_modules/prop-types/node_modules/react-is/index.js","../../../node_modules/object-assign/index.js","../../../node_modules/prop-types/lib/ReactPropTypesSecret.js","../../../node_modules/prop-types/lib/has.js","../../../node_modules/prop-types/checkPropTypes.js","../../../node_modules/prop-types/factoryWithTypeCheckers.js","../../../node_modules/prop-types/factoryWithThrowingShims.js","../../../node_modules/prop-types/index.js","../../../node_modules/@mui/utils/elementAcceptingRef/elementAcceptingRef.js","../../../node_modules/@mui/utils/exactProp/exactProp.js","../../../node_modules/@mui/utils/formatMuiErrorMessage/formatMuiErrorMessage.js","../../../node_modules/react-is/cjs/react-is.production.min.js","../../../node_modules/react-is/cjs/react-is.development.js","../../../node_modules/react-is/index.js","../../../node_modules/@mui/utils/getDisplayName/getDisplayName.js","../../../node_modules/@mui/utils/HTMLElementType/HTMLElementType.js","../../../node_modules/@mui/utils/refType/refType.js","../../../node_modules/@mui/utils/capitalize/capitalize.js","../../../node_modules/@mui/utils/createChainedFunction/createChainedFunction.js","../../../node_modules/@mui/utils/debounce/debounce.js","../../../node_modules/@mui/utils/deprecatedPropType/deprecatedPropType.js","../../../node_modules/@mui/utils/isMuiElement/isMuiElement.js","../../../node_modules/@mui/utils/ownerDocument/ownerDocument.js","../../../node_modules/@mui/utils/ownerWindow/ownerWindow.js","../../../node_modules/@mui/utils/requirePropFactory/requirePropFactory.js","../../../node_modules/@mui/utils/setRef/setRef.js","../../../node_modules/@mui/utils/useEnhancedEffect/useEnhancedEffect.js","../../../node_modules/@mui/utils/useId/useId.js","../../../node_modules/@mui/utils/unsupportedProp/unsupportedProp.js","../../../node_modules/@mui/utils/useControlled/useControlled.js","../../../node_modules/@mui/utils/useEventCallback/useEventCallback.js","../../../node_modules/@mui/utils/useForkRef/useForkRef.js","../../../node_modules/@mui/utils/useLazyRef/useLazyRef.js","../../../node_modules/@mui/utils/useOnMount/useOnMount.js","../../../node_modules/@mui/utils/useTimeout/useTimeout.js","../../../node_modules/@mui/utils/useIsFocusVisible/useIsFocusVisible.js","../../../node_modules/@mui/utils/resolveProps/resolveProps.js","../../../node_modules/@mui/utils/composeClasses/composeClasses.js","../../../node_modules/@mui/utils/ClassNameGenerator/ClassNameGenerator.js","../../../node_modules/@mui/utils/generateUtilityClass/generateUtilityClass.js","../../../node_modules/@mui/utils/generateUtilityClasses/generateUtilityClasses.js","../../../node_modules/@mui/utils/clamp/clamp.js","../../../node_modules/@babel/runtime/helpers/esm/objectWithoutPropertiesLoose.js","../../../node_modules/@mui/system/esm/createTheme/createBreakpoints.js","../../../node_modules/@mui/system/esm/createTheme/shape.js","../../../node_modules/@mui/system/esm/responsivePropType.js","../../../node_modules/@mui/system/esm/merge.js","../../../node_modules/@mui/system/esm/breakpoints.js","../../../node_modules/@mui/system/esm/style.js","../../../node_modules/@mui/system/esm/memoize.js","../../../node_modules/@mui/system/esm/spacing.js","../../../node_modules/@mui/system/esm/createTheme/createSpacing.js","../../../node_modules/@mui/system/esm/compose.js","../../../node_modules/@mui/system/esm/borders.js","../../../node_modules/@mui/system/esm/cssGrid.js","../../../node_modules/@mui/system/esm/palette.js","../../../node_modules/@mui/system/esm/sizing.js","../../../node_modules/@mui/system/esm/styleFunctionSx/defaultSxConfig.js","../../../node_modules/@mui/system/esm/styleFunctionSx/styleFunctionSx.js","../../../node_modules/@mui/system/esm/createTheme/applyStyles.js","../../../node_modules/@mui/system/esm/createTheme/createTheme.js","../../../node_modules/@mui/system/esm/useThemeWithoutDefault.js","../../../node_modules/@mui/system/esm/useTheme.js","../../../node_modules/@mui/system/esm/createStyled.js","../../../node_modules/@mui/system/esm/useThemeProps/getThemeProps.js","../../../node_modules/@mui/system/esm/useThemeProps/useThemeProps.js","../../../node_modules/@mui/system/esm/colorManipulator.js","../../../node_modules/@mui/material/styles/createMixins.js","../../../node_modules/@mui/material/colors/common.js","../../../node_modules/@mui/material/colors/grey.js","../../../node_modules/@mui/material/colors/purple.js","../../../node_modules/@mui/material/colors/red.js","../../../node_modules/@mui/material/colors/orange.js","../../../node_modules/@mui/material/colors/blue.js","../../../node_modules/@mui/material/colors/lightBlue.js","../../../node_modules/@mui/material/colors/green.js","../../../node_modules/@mui/material/styles/createPalette.js","../../../node_modules/@mui/material/styles/createTypography.js","../../../node_modules/@mui/material/styles/shadows.js","../../../node_modules/@mui/material/styles/createTransitions.js","../../../node_modules/@mui/material/styles/zIndex.js","../../../node_modules/@mui/material/styles/createTheme.js","../../../node_modules/@mui/material/styles/defaultTheme.js","../../../node_modules/@mui/material/styles/identifier.js","../../../node_modules/@mui/material/styles/useThemeProps.js","../../../node_modules/@mui/material/styles/styled.js","../../../node_modules/@mui/material/SvgIcon/svgIconClasses.js","../../../node_modules/@mui/material/SvgIcon/SvgIcon.js","../../../node_modules/@mui/material/utils/createSvgIcon.js","../../../node_modules/@mui/material/utils/index.js","../../../node_modules/@mui/icons-material/utils/createSvgIcon.js","../../../node_modules/@mui/icons-material/ArrowRight.js","../../../node_modules/@mui/base/utils/isHostComponent.js","../../../node_modules/@mui/base/utils/appendOwnerState.js","../../../node_modules/@mui/base/utils/ClassNameConfigurator.js","../../../node_modules/@mui/base/utils/extractEventHandlers.js","../../../node_modules/@mui/base/utils/resolveComponentProps.js","../../../node_modules/@mui/base/utils/omitEventHandlers.js","../../../node_modules/@mui/base/utils/mergeSlotProps.js","../../../node_modules/@mui/base/utils/useSlotProps.js","../../../node_modules/@mui/base/generateUtilityClass/index.js","../../../node_modules/@mui/base/generateUtilityClasses/index.js","../../../node_modules/@mui/base/Portal/Portal.js","../../../node_modules/@popperjs/core/lib/enums.js","../../../node_modules/@popperjs/core/lib/dom-utils/getNodeName.js","../../../node_modules/@popperjs/core/lib/dom-utils/getWindow.js","../../../node_modules/@popperjs/core/lib/dom-utils/instanceOf.js","../../../node_modules/@popperjs/core/lib/modifiers/applyStyles.js","../../../node_modules/@popperjs/core/lib/utils/getBasePlacement.js","../../../node_modules/@popperjs/core/lib/utils/math.js","../../../node_modules/@popperjs/core/lib/utils/userAgent.js","../../../node_modules/@popperjs/core/lib/dom-utils/isLayoutViewport.js","../../../node_modules/@popperjs/core/lib/dom-utils/getBoundingClientRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/getLayoutRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/contains.js","../../../node_modules/@popperjs/core/lib/dom-utils/getComputedStyle.js","../../../node_modules/@popperjs/core/lib/dom-utils/isTableElement.js","../../../node_modules/@popperjs/core/lib/dom-utils/getDocumentElement.js","../../../node_modules/@popperjs/core/lib/dom-utils/getParentNode.js","../../../node_modules/@popperjs/core/lib/dom-utils/getOffsetParent.js","../../../node_modules/@popperjs/core/lib/utils/getMainAxisFromPlacement.js","../../../node_modules/@popperjs/core/lib/utils/within.js","../../../node_modules/@popperjs/core/lib/utils/getFreshSideObject.js","../../../node_modules/@popperjs/core/lib/utils/mergePaddingObject.js","../../../node_modules/@popperjs/core/lib/utils/expandToHashMap.js","../../../node_modules/@popperjs/core/lib/modifiers/arrow.js","../../../node_modules/@popperjs/core/lib/utils/getVariation.js","../../../node_modules/@popperjs/core/lib/modifiers/computeStyles.js","../../../node_modules/@popperjs/core/lib/modifiers/eventListeners.js","../../../node_modules/@popperjs/core/lib/utils/getOppositePlacement.js","../../../node_modules/@popperjs/core/lib/utils/getOppositeVariationPlacement.js","../../../node_modules/@popperjs/core/lib/dom-utils/getWindowScroll.js","../../../node_modules/@popperjs/core/lib/dom-utils/getWindowScrollBarX.js","../../../node_modules/@popperjs/core/lib/dom-utils/getViewportRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/getDocumentRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/isScrollParent.js","../../../node_modules/@popperjs/core/lib/dom-utils/getScrollParent.js","../../../node_modules/@popperjs/core/lib/dom-utils/listScrollParents.js","../../../node_modules/@popperjs/core/lib/utils/rectToClientRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/getClippingRect.js","../../../node_modules/@popperjs/core/lib/utils/computeOffsets.js","../../../node_modules/@popperjs/core/lib/utils/detectOverflow.js","../../../node_modules/@popperjs/core/lib/utils/computeAutoPlacement.js","../../../node_modules/@popperjs/core/lib/modifiers/flip.js","../../../node_modules/@popperjs/core/lib/modifiers/hide.js","../../../node_modules/@popperjs/core/lib/modifiers/offset.js","../../../node_modules/@popperjs/core/lib/modifiers/popperOffsets.js","../../../node_modules/@popperjs/core/lib/utils/getAltAxis.js","../../../node_modules/@popperjs/core/lib/modifiers/preventOverflow.js","../../../node_modules/@popperjs/core/lib/dom-utils/getHTMLElementScroll.js","../../../node_modules/@popperjs/core/lib/dom-utils/getNodeScroll.js","../../../node_modules/@popperjs/core/lib/dom-utils/getCompositeRect.js","../../../node_modules/@popperjs/core/lib/utils/orderModifiers.js","../../../node_modules/@popperjs/core/lib/utils/debounce.js","../../../node_modules/@popperjs/core/lib/utils/mergeByName.js","../../../node_modules/@popperjs/core/lib/createPopper.js","../../../node_modules/@popperjs/core/lib/popper.js","../../../node_modules/@mui/base/Popper/popperClasses.js","../../../node_modules/@mui/base/Popper/Popper.js","../../../node_modules/@mui/material/styles/useTheme.js","../../../node_modules/@babel/runtime/helpers/esm/setPrototypeOf.js","../../../node_modules/@babel/runtime/helpers/esm/inheritsLoose.js","../../../node_modules/react-transition-group/esm/config.js","../../../node_modules/react-transition-group/esm/utils/PropTypes.js","../../../node_modules/react-transition-group/esm/TransitionGroupContext.js","../../../node_modules/react-transition-group/esm/utils/reflow.js","../../../node_modules/react-transition-group/esm/Transition.js","../../../node_modules/@mui/material/transitions/utils.js","../../../node_modules/@mui/material/Grow/Grow.js","../../../node_modules/@mui/material/Popper/Popper.js","../../../node_modules/@mui/material/Tooltip/tooltipClasses.js","../../../node_modules/@mui/material/Tooltip/Tooltip.js","../src/components/mui/menu-item.component.tsx","../src/components/mui/grouped-menu-item-list.component.tsx","../src/components/mui/top-level-menu.component.tsx","../src/components/mui/grid-menu.component.tsx","../src/hooks/use-promise.hook.ts","../../../node_modules/@mui/icons-material/esm/Menu.js","../src/components/mui/hamburger-menu-button.component.tsx","../src/components/mui/icon-button.component.tsx","../src/components/basics/spinner.component.tsx","../src/components/basics/text-field.component.tsx","../src/components/mui/toolbar.component.tsx","../src/components/shadcn-ui/alert.tsx","../src/components/shadcn-ui/card.tsx","../src/components/shadcn-ui/sonner.tsx","../src/components/shadcn-ui/slider.tsx","../src/components/shadcn-ui/switch.tsx","../src/components/shadcn-ui/tabs.tsx","../src/components/advanced/extension-marketplace/buttons/install-button.component.tsx","../src/components/advanced/extension-marketplace/buttons/enable-button.component.tsx","../src/components/advanced/extension-marketplace/buttons/disable-button.component.tsx","../src/components/advanced/extension-marketplace/buttons/update-button.component.tsx","../src/components/advanced/extension-marketplace/markdown-renderer.component.tsx","../src/components/advanced/extension-marketplace/buttons/filter-button.component.tsx","../src/components/advanced/extension-marketplace/filter-dropdown.component.tsx","../src/components/advanced/extension-marketplace/no-extensions-found.component.tsx","../src/components/advanced/extension-marketplace/more-info.component.tsx","../src/components/advanced/extension-marketplace/version-history.component.tsx","../src/components/advanced/extension-marketplace/footer.component.tsx","../src/hooks/use-event.hook.ts","../src/hooks/use-event-async.hook.ts"],"sourcesContent":["import { type ClassValue, clsx } from 'clsx';\nimport { extendTailwindMerge } from 'tailwind-merge';\n\nconst twMergeCustom = extendTailwindMerge({ prefix: 'tw-' });\n\n/**\n * Tailwind and CSS class application helper function. Uses\n * [`clsx`](https://www.npmjs.com/package/clsx) to make it easy to apply classes conditionally using\n * object syntax, and uses [`tailwind-merge`](https://www.npmjs.com/package/tailwind-merge) to make\n * it easy to merge/overwrite Tailwind classes in a programmer-logic-friendly way.\n *\n * Note: `tailwind-merge` is configured to use the prefix `tw-`, so you must use the same prefix\n * with any Tailwind classes you use with this function to successfully overwrite other Tailwind\n * classes. `platform-bible-react` is configured to use `tw-` as its Tailwind prefix, so any\n * Tailwind classes you pass into `platform-bible-react` components will be compared using the `tw-`\n * prefix.\n *\n * This function was popularized by\n * [shadcn/ui](https://ui.shadcn.com/docs/installation/manual#add-a-cn-helper). See [ByteGrad's\n * explanation video](https://www.youtube.com/watch?v=re2JFITR7TI) for more information.\n *\n * @example\n *\n * ```typescript\n * const borderShouldBeBlue = true;\n * const textShouldBeRed = true;\n * const heightShouldBe20 = false;\n * const classString = cn(\n * 'tw-bg-primary tw-h-10 tw-text-primary-foreground',\n * 'tw-bg-secondary',\n * {\n * 'tw-border-blue-500': borderShouldBeBlue,\n * 'tw-text-red-500': textShouldBeRed,\n * 'tw-h-20': heightShouldBe20,\n * },\n * 'some-class',\n * );\n * ```\n *\n * The resulting `classString` is `'tw-h-10 tw-bg-secondary tw-border-blue-500 tw-text-red-500\n * some-class'`\n *\n * - Notice that `'tw-bg-secondary'`, specified later, overwrote `'tw-bg-primary'`, specified earlier,\n * because they are Tailwind classes that affect the same css property\n * - Notice that `'tw-text-red-500'`, specified later, overwrote `'tw-text-primary-foreground'`,\n * specified earlier, because they are Tailwind classes that affect the same css property\n * - Notice that `'tw-h-20'`, specified later, did not overwrite `'tw-h-10'`, specified earlier,\n * because `'tw-h-20'` is part of a conditional class object and its value evaluated to `false`;\n * therefore it was not applied\n * - Notice that `'some-class'` was applied. This function is not limited only to Tailwind classes.\n *\n *\n * @param inputs Class strings or `clsx` conditional class objects to merge. Tailwind classes\n * specified later in the arguments overwrite similar Tailwind classes specified earlier in the\n * arguments\n * @returns Class string containing all applicable classes from the arguments based on the rules\n * described above\n */\n// shadcn/ui uses this export in its boilerplate code\n// eslint-disable-next-line import/prefer-default-export\nexport function cn(...inputs: ClassValue[]) {\n return twMergeCustom(clsx(inputs));\n}\n","import React from 'react';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport interface InputProps extends React.InputHTMLAttributes {}\n\nexport const Input = React.forwardRef(\n ({ className, type, ...props }, ref) => {\n return (\n \n );\n },\n);\nInput.displayName = 'Input';\n","import { FocusEventHandler, forwardRef, KeyboardEvent, MouseEventHandler } from 'react';\nimport { History } from 'lucide-react';\nimport { Input as ShadInput } from '@/components/shadcn-ui/input';\n\nexport type BookChapterInputProps = {\n handleSearch: (searchString: string) => void;\n handleKeyDown: (event: KeyboardEvent) => void;\n handleOnClick: MouseEventHandler;\n handleSubmit: () => void;\n onFocus?: FocusEventHandler;\n value: string;\n placeholder: string;\n};\n\n// Shadcn Input sets type to \"button\"- HAVE to prop spread before setting type\nconst BookChapterInput = forwardRef(\n (\n { handleSearch, handleKeyDown, handleOnClick, handleSubmit, ...props }: BookChapterInputProps,\n ref,\n ) => {\n return (\n
    \n handleSearch(event.target.value)}\n onKeyDown={(e) => {\n if (e.key === 'Enter') {\n handleSubmit();\n }\n handleKeyDown(e);\n }}\n onClick={handleOnClick}\n ref={ref}\n />\n {\n // eslint-disable-next-line no-console\n console.log('back in history');\n }}\n />\n
    \n );\n },\n);\n\nexport default BookChapterInput;\n","var P = Object.defineProperty;\nvar R = (t, e, s) => e in t ? P(t, e, { enumerable: !0, configurable: !0, writable: !0, value: s }) : t[e] = s;\nvar n = (t, e, s) => R(t, typeof e != \"symbol\" ? e + \"\" : e, s);\nclass _ {\n constructor() {\n n(this, \"books\");\n n(this, \"firstSelectedBookNum\");\n n(this, \"lastSelectedBookNum\");\n n(this, \"count\");\n n(this, \"selectedBookNumbers\");\n n(this, \"selectedBookIds\");\n }\n}\nconst N = [\n \"GEN\",\n \"EXO\",\n \"LEV\",\n \"NUM\",\n \"DEU\",\n \"JOS\",\n \"JDG\",\n \"RUT\",\n \"1SA\",\n \"2SA\",\n // 10\n \"1KI\",\n \"2KI\",\n \"1CH\",\n \"2CH\",\n \"EZR\",\n \"NEH\",\n \"EST\",\n \"JOB\",\n \"PSA\",\n \"PRO\",\n // 20\n \"ECC\",\n \"SNG\",\n \"ISA\",\n \"JER\",\n \"LAM\",\n \"EZK\",\n \"DAN\",\n \"HOS\",\n \"JOL\",\n \"AMO\",\n // 30\n \"OBA\",\n \"JON\",\n \"MIC\",\n \"NAM\",\n \"HAB\",\n \"ZEP\",\n \"HAG\",\n \"ZEC\",\n \"MAL\",\n \"MAT\",\n // 40\n \"MRK\",\n \"LUK\",\n \"JHN\",\n \"ACT\",\n \"ROM\",\n \"1CO\",\n \"2CO\",\n \"GAL\",\n \"EPH\",\n \"PHP\",\n // 50\n \"COL\",\n \"1TH\",\n \"2TH\",\n \"1TI\",\n \"2TI\",\n \"TIT\",\n \"PHM\",\n \"HEB\",\n \"JAS\",\n \"1PE\",\n // 60\n \"2PE\",\n \"1JN\",\n \"2JN\",\n \"3JN\",\n \"JUD\",\n \"REV\",\n \"TOB\",\n \"JDT\",\n \"ESG\",\n \"WIS\",\n // 70\n \"SIR\",\n \"BAR\",\n \"LJE\",\n \"S3Y\",\n \"SUS\",\n \"BEL\",\n \"1MA\",\n \"2MA\",\n \"3MA\",\n \"4MA\",\n // 80\n \"1ES\",\n \"2ES\",\n \"MAN\",\n \"PS2\",\n \"ODA\",\n \"PSS\",\n \"JSA\",\n // actual variant text for JOS, now in LXA text\n \"JDB\",\n // actual variant text for JDG, now in LXA text\n \"TBS\",\n // actual variant text for TOB, now in LXA text\n \"SST\",\n // actual variant text for SUS, now in LXA text // 90\n \"DNT\",\n // actual variant text for DAN, now in LXA text\n \"BLT\",\n // actual variant text for BEL, now in LXA text\n \"XXA\",\n \"XXB\",\n \"XXC\",\n \"XXD\",\n \"XXE\",\n \"XXF\",\n \"XXG\",\n \"FRT\",\n // 100\n \"BAK\",\n \"OTH\",\n \"3ES\",\n // Used previously but really should be 2ES\n \"EZA\",\n // Used to be called 4ES, but not actually in any known project\n \"5EZ\",\n // Used to be called 5ES, but not actually in any known project\n \"6EZ\",\n // Used to be called 6ES, but not actually in any known project\n \"INT\",\n \"CNC\",\n \"GLO\",\n \"TDX\",\n // 110\n \"NDX\",\n \"DAG\",\n \"PS3\",\n \"2BA\",\n \"LBA\",\n \"JUB\",\n \"ENO\",\n \"1MQ\",\n \"2MQ\",\n \"3MQ\",\n // 120\n \"REP\",\n \"4BA\",\n \"LAO\"\n], B = [\n \"XXA\",\n \"XXB\",\n \"XXC\",\n \"XXD\",\n \"XXE\",\n \"XXF\",\n \"XXG\",\n \"FRT\",\n \"BAK\",\n \"OTH\",\n \"INT\",\n \"CNC\",\n \"GLO\",\n \"TDX\",\n \"NDX\"\n], O = [\n \"Genesis\",\n \"Exodus\",\n \"Leviticus\",\n \"Numbers\",\n \"Deuteronomy\",\n \"Joshua\",\n \"Judges\",\n \"Ruth\",\n \"1 Samuel\",\n \"2 Samuel\",\n \"1 Kings\",\n \"2 Kings\",\n \"1 Chronicles\",\n \"2 Chronicles\",\n \"Ezra\",\n \"Nehemiah\",\n \"Esther (Hebrew)\",\n \"Job\",\n \"Psalms\",\n \"Proverbs\",\n \"Ecclesiastes\",\n \"Song of Songs\",\n \"Isaiah\",\n \"Jeremiah\",\n \"Lamentations\",\n \"Ezekiel\",\n \"Daniel (Hebrew)\",\n \"Hosea\",\n \"Joel\",\n \"Amos\",\n \"Obadiah\",\n \"Jonah\",\n \"Micah\",\n \"Nahum\",\n \"Habakkuk\",\n \"Zephaniah\",\n \"Haggai\",\n \"Zechariah\",\n \"Malachi\",\n \"Matthew\",\n \"Mark\",\n \"Luke\",\n \"John\",\n \"Acts\",\n \"Romans\",\n \"1 Corinthians\",\n \"2 Corinthians\",\n \"Galatians\",\n \"Ephesians\",\n \"Philippians\",\n \"Colossians\",\n \"1 Thessalonians\",\n \"2 Thessalonians\",\n \"1 Timothy\",\n \"2 Timothy\",\n \"Titus\",\n \"Philemon\",\n \"Hebrews\",\n \"James\",\n \"1 Peter\",\n \"2 Peter\",\n \"1 John\",\n \"2 John\",\n \"3 John\",\n \"Jude\",\n \"Revelation\",\n \"Tobit\",\n \"Judith\",\n \"Esther Greek\",\n \"Wisdom of Solomon\",\n \"Sirach (Ecclesiasticus)\",\n \"Baruch\",\n \"Letter of Jeremiah\",\n \"Song of 3 Young Men\",\n \"Susanna\",\n \"Bel and the Dragon\",\n \"1 Maccabees\",\n \"2 Maccabees\",\n \"3 Maccabees\",\n \"4 Maccabees\",\n \"1 Esdras (Greek)\",\n \"2 Esdras (Latin)\",\n \"Prayer of Manasseh\",\n \"Psalm 151\",\n \"Odes\",\n \"Psalms of Solomon\",\n // WARNING, if you change the spelling of the *obsolete* tag be sure to update\n // IsObsolete routine\n \"Joshua A. *obsolete*\",\n \"Judges B. *obsolete*\",\n \"Tobit S. *obsolete*\",\n \"Susanna Th. *obsolete*\",\n \"Daniel Th. *obsolete*\",\n \"Bel Th. *obsolete*\",\n \"Extra A\",\n \"Extra B\",\n \"Extra C\",\n \"Extra D\",\n \"Extra E\",\n \"Extra F\",\n \"Extra G\",\n \"Front Matter\",\n \"Back Matter\",\n \"Other Matter\",\n \"3 Ezra *obsolete*\",\n \"Apocalypse of Ezra\",\n \"5 Ezra (Latin Prologue)\",\n \"6 Ezra (Latin Epilogue)\",\n \"Introduction\",\n \"Concordance \",\n \"Glossary \",\n \"Topical Index\",\n \"Names Index\",\n \"Daniel Greek\",\n \"Psalms 152-155\",\n \"2 Baruch (Apocalypse)\",\n \"Letter of Baruch\",\n \"Jubilees\",\n \"Enoch\",\n \"1 Meqabyan\",\n \"2 Meqabyan\",\n \"3 Meqabyan\",\n \"Reproof (Proverbs 25-31)\",\n \"4 Baruch (Rest of Baruch)\",\n \"Laodiceans\"\n], S = K();\nfunction g(t, e = !0) {\n return e && (t = t.toUpperCase()), t in S ? S[t] : 0;\n}\nfunction k(t) {\n return g(t) > 0;\n}\nfunction x(t) {\n const e = typeof t == \"string\" ? g(t) : t;\n return e >= 40 && e <= 66;\n}\nfunction T(t) {\n return (typeof t == \"string\" ? g(t) : t) <= 39;\n}\nfunction X(t) {\n return t <= 66;\n}\nfunction V(t) {\n const e = typeof t == \"string\" ? g(t) : t;\n return w(e) && !X(e);\n}\nfunction* L() {\n for (let t = 1; t <= N.length; t++) yield t;\n}\nconst G = 1, A = N.length;\nfunction H() {\n return [\"XXA\", \"XXB\", \"XXC\", \"XXD\", \"XXE\", \"XXF\", \"XXG\"];\n}\nfunction C(t, e = \"***\") {\n const s = t - 1;\n return s < 0 || s >= N.length ? e : N[s];\n}\nfunction I(t) {\n return t <= 0 || t > A ? \"******\" : O[t - 1];\n}\nfunction y(t) {\n return I(g(t));\n}\nfunction w(t) {\n const e = typeof t == \"number\" ? C(t) : t;\n return k(e) && !B.includes(e);\n}\nfunction q(t) {\n const e = typeof t == \"number\" ? C(t) : t;\n return k(e) && B.includes(e);\n}\nfunction U(t) {\n return O[t - 1].includes(\"*obsolete*\");\n}\nfunction K() {\n const t = {};\n for (let e = 0; e < N.length; e++)\n t[N[e]] = e + 1;\n return t;\n}\nconst m = {\n allBookIds: N,\n nonCanonicalIds: B,\n bookIdToNumber: g,\n isBookIdValid: k,\n isBookNT: x,\n isBookOT: T,\n isBookOTNT: X,\n isBookDC: V,\n allBookNumbers: L,\n firstBook: G,\n lastBook: A,\n extraBooks: H,\n bookNumberToId: C,\n bookNumberToEnglishName: I,\n bookIdToEnglishName: y,\n isCanonical: w,\n isExtraMaterial: q,\n isObsolete: U\n};\nvar l = /* @__PURE__ */ ((t) => (t[t.Unknown = 0] = \"Unknown\", t[t.Original = 1] = \"Original\", t[t.Septuagint = 2] = \"Septuagint\", t[t.Vulgate = 3] = \"Vulgate\", t[t.English = 4] = \"English\", t[t.RussianProtestant = 5] = \"RussianProtestant\", t[t.RussianOrthodox = 6] = \"RussianOrthodox\", t))(l || {});\nconst h = class h {\n // private versInfo: Versification;\n constructor(e) {\n n(this, \"name\");\n n(this, \"fullPath\");\n n(this, \"isPresent\");\n n(this, \"hasVerseSegments\");\n n(this, \"isCustomized\");\n n(this, \"baseVersification\");\n n(this, \"scriptureBooks\");\n n(this, \"_type\");\n if (e == null)\n throw new Error(\"Argument undefined\");\n typeof e == \"string\" ? (this.name = e, this._type = l[e]) : (this._type = e, this.name = l[e]);\n }\n get type() {\n return this._type;\n }\n equals(e) {\n return !e.type || !this.type ? !1 : e.type === this.type;\n }\n};\nn(h, \"Original\", new h(l.Original)), n(h, \"Septuagint\", new h(l.Septuagint)), n(h, \"Vulgate\", new h(l.Vulgate)), n(h, \"English\", new h(l.English)), n(h, \"RussianProtestant\", new h(l.RussianProtestant)), n(h, \"RussianOrthodox\", new h(l.RussianOrthodox));\nlet c = h;\nfunction E(t, e) {\n const s = e[0];\n for (let r = 1; r < e.length; r++)\n t = t.split(e[r]).join(s);\n return t.split(s);\n}\nvar D = /* @__PURE__ */ ((t) => (t[t.Valid = 0] = \"Valid\", t[t.UnknownVersification = 1] = \"UnknownVersification\", t[t.OutOfRange = 2] = \"OutOfRange\", t[t.VerseOutOfOrder = 3] = \"VerseOutOfOrder\", t[t.VerseRepeated = 4] = \"VerseRepeated\", t))(D || {});\nconst i = class i {\n constructor(e, s, r, a) {\n /** Not yet implemented. */\n n(this, \"firstChapter\");\n /** Not yet implemented. */\n n(this, \"lastChapter\");\n /** Not yet implemented. */\n n(this, \"lastVerse\");\n /** Not yet implemented. */\n n(this, \"hasSegmentsDefined\");\n /** Not yet implemented. */\n n(this, \"text\");\n /** Not yet implemented. */\n n(this, \"BBBCCCVVVS\");\n /** Not yet implemented. */\n n(this, \"longHashCode\");\n /** The versification of the reference. */\n n(this, \"versification\");\n n(this, \"rtlMark\", \"‏\");\n n(this, \"_bookNum\", 0);\n n(this, \"_chapterNum\", 0);\n n(this, \"_verseNum\", 0);\n n(this, \"_verse\");\n if (r == null && a == null)\n if (e != null && typeof e == \"string\") {\n const o = e, u = s != null && s instanceof c ? s : void 0;\n this.setEmpty(u), this.parse(o);\n } else if (e != null && typeof e == \"number\") {\n const o = s != null && s instanceof c ? s : void 0;\n this.setEmpty(o), this._verseNum = e % i.chapterDigitShifter, this._chapterNum = Math.floor(\n e % i.bookDigitShifter / i.chapterDigitShifter\n ), this._bookNum = Math.floor(e / i.bookDigitShifter);\n } else if (s == null)\n if (e != null && e instanceof i) {\n const o = e;\n this._bookNum = o.bookNum, this._chapterNum = o.chapterNum, this._verseNum = o.verseNum, this._verse = o.verse, this.versification = o.versification;\n } else {\n if (e == null) return;\n const o = e instanceof c ? e : i.defaultVersification;\n this.setEmpty(o);\n }\n else\n throw new Error(\"VerseRef constructor not supported.\");\n else if (e != null && s != null && r != null)\n if (typeof e == \"string\" && typeof s == \"string\" && typeof r == \"string\")\n this.setEmpty(a), this.updateInternal(e, s, r);\n else if (typeof e == \"number\" && typeof s == \"number\" && typeof r == \"number\")\n this._bookNum = e, this._chapterNum = s, this._verseNum = r, this.versification = a ?? i.defaultVersification;\n else\n throw new Error(\"VerseRef constructor not supported.\");\n else\n throw new Error(\"VerseRef constructor not supported.\");\n }\n /**\n * Determines if the verse string is in a valid format (does not consider versification).\n */\n static isVerseParseable(e) {\n return e.length > 0 && \"0123456789\".includes(e[0]) && !e.endsWith(this.verseRangeSeparator) && !e.endsWith(this.verseSequenceIndicator);\n }\n /**\n * Tries to parse the specified string into a verse reference.\n * @param str - The string to attempt to parse.\n * @returns success: `true` if the specified string was successfully parsed, `false` otherwise.\n * @returns verseRef: The result of the parse if successful, or empty VerseRef if it failed\n */\n static tryParse(e) {\n let s;\n try {\n return s = new i(e), { success: !0, verseRef: s };\n } catch (r) {\n if (r instanceof v)\n return s = new i(), { success: !1, verseRef: s };\n throw r;\n }\n }\n /**\n * Gets the reference as a comparable integer where the book, chapter, and verse each occupy 3\n * digits.\n * @param bookNum - Book number (this is 1-based, not an index).\n * @param chapterNum - Chapter number.\n * @param verseNum - Verse number.\n * @returns The reference as a comparable integer where the book, chapter, and verse each occupy 3\n * digits.\n */\n static getBBBCCCVVV(e, s, r) {\n return e % i.bcvMaxValue * i.bookDigitShifter + (s >= 0 ? s % i.bcvMaxValue * i.chapterDigitShifter : 0) + (r >= 0 ? r % i.bcvMaxValue : 0);\n }\n /**\n * Deserializes a serialized VerseRef.\n * @param serializedVerseRef - Serialized VerseRef to create from.\n * @returns the deserialized VerseRef.\n */\n static fromJSON(e) {\n const { book: s, chapterNum: r, verseNum: a, verse: o, versificationStr: u } = e, f = o || a.toString();\n let d;\n return u && (d = new c(u)), s ? new i(s, r.toString(), f, d) : new i();\n }\n /**\n * Parses a verse string and gets the leading numeric portion as a number.\n * @param verseStr - verse string to parse\n * @returns true if the entire string could be parsed as a single, simple verse number (1-999);\n * false if the verse string represented a verse bridge, contained segment letters, or was invalid\n */\n static tryGetVerseNum(e) {\n let s;\n if (!e)\n return s = -1, { success: !0, vNum: s };\n s = 0;\n let r;\n for (let a = 0; a < e.length; a++) {\n if (r = e[a], r < \"0\" || r > \"9\")\n return a === 0 && (s = -1), { success: !1, vNum: s };\n if (s = s * 10 + +r - 0, s > i.bcvMaxValue)\n return s = -1, { success: !1, vNum: s };\n }\n return { success: !0, vNum: s };\n }\n /**\n * Checks to see if a VerseRef hasn't been set - all values are the default.\n */\n get isDefault() {\n return this.bookNum === 0 && this.chapterNum === 0 && this.verseNum === 0 && this.versification == null;\n }\n /**\n * Gets whether the verse contains multiple verses.\n */\n get hasMultiple() {\n return this._verse != null && (this._verse.includes(i.verseRangeSeparator) || this._verse.includes(i.verseSequenceIndicator));\n }\n /**\n * Gets or sets the book of the reference. Book is the 3-letter abbreviation in capital letters,\n * e.g. `'MAT'`.\n */\n get book() {\n return m.bookNumberToId(this.bookNum, \"\");\n }\n set book(e) {\n this.bookNum = m.bookIdToNumber(e);\n }\n /**\n * Gets or sets the chapter of the reference,. e.g. `'3'`.\n */\n get chapter() {\n return this.isDefault || this._chapterNum < 0 ? \"\" : this._chapterNum.toString();\n }\n set chapter(e) {\n const s = +e;\n this._chapterNum = Number.isInteger(s) ? s : -1;\n }\n /**\n * Gets or sets the verse of the reference, including range, segments, and sequences, e.g. `'4'`,\n * or `'4b-5a, 7'`.\n */\n get verse() {\n return this._verse != null ? this._verse : this.isDefault || this._verseNum < 0 ? \"\" : this._verseNum.toString();\n }\n set verse(e) {\n const { success: s, vNum: r } = i.tryGetVerseNum(e);\n this._verse = s ? void 0 : e.replace(this.rtlMark, \"\"), this._verseNum = r, !(this._verseNum >= 0) && ({ vNum: this._verseNum } = i.tryGetVerseNum(this._verse));\n }\n /**\n * Get or set Book based on book number, e.g. `42`.\n */\n get bookNum() {\n return this._bookNum;\n }\n set bookNum(e) {\n if (e <= 0 || e > m.lastBook)\n throw new v(\n \"BookNum must be greater than zero and less than or equal to last book\"\n );\n this._bookNum = e;\n }\n /**\n * Gets or sets the chapter number, e.g. `3`. `-1` if not valid.\n */\n get chapterNum() {\n return this._chapterNum;\n }\n set chapterNum(e) {\n this.chapterNum = e;\n }\n /**\n * Gets or sets verse start number, e.g. `4`. `-1` if not valid.\n */\n get verseNum() {\n return this._verseNum;\n }\n set verseNum(e) {\n this._verseNum = e;\n }\n /**\n * String representing the versification (should ONLY be used for serialization/deserialization).\n *\n * @remarks This is for backwards compatibility when ScrVers was an enumeration.\n */\n get versificationStr() {\n var e;\n return (e = this.versification) == null ? void 0 : e.name;\n }\n set versificationStr(e) {\n this.versification = this.versification != null ? new c(e) : void 0;\n }\n /**\n * Determines if the reference is valid.\n */\n get valid() {\n return this.validStatus === 0;\n }\n /**\n * Get the valid status for this reference.\n */\n get validStatus() {\n return this.validateVerse(i.verseRangeSeparators, i.verseSequenceIndicators);\n }\n /**\n * Gets the reference as a comparable integer where the book,\n * chapter, and verse each occupy three digits and the verse is 0.\n */\n get BBBCCC() {\n return i.getBBBCCCVVV(this._bookNum, this._chapterNum, 0);\n }\n /**\n * Gets the reference as a comparable integer where the book,\n * chapter, and verse each occupy three digits. If verse is not null\n * (i.e., this reference represents a complex reference with verse\n * segments or bridge) this cannot be used for an exact comparison.\n */\n get BBBCCCVVV() {\n return i.getBBBCCCVVV(this._bookNum, this._chapterNum, this._verseNum);\n }\n /**\n * Gets whether the verse is defined as an excluded verse in the versification.\n * Does not handle verse ranges.\n */\n // eslint-disable-next-line @typescript-eslint/class-literal-property-style\n get isExcluded() {\n return !1;\n }\n /**\n * Parses the reference in the specified string.\n * Optionally versification can follow reference as in GEN 3:11/4\n * Throw an exception if\n * - invalid book name\n * - chapter number is missing or not a number\n * - verse number is missing or does not start with a number\n * - versification is invalid\n * @param verseStr - string to parse e.g. 'MAT 3:11'\n */\n parse(e) {\n if (e = e.replace(this.rtlMark, \"\"), e.includes(\"/\")) {\n const o = e.split(\"/\");\n if (e = o[0], o.length > 1)\n try {\n const u = +o[1].trim();\n this.versification = new c(l[u]);\n } catch {\n throw new v(\"Invalid reference : \" + e);\n }\n }\n const s = e.trim().split(\" \");\n if (s.length !== 2)\n throw new v(\"Invalid reference : \" + e);\n const r = s[1].split(\":\"), a = +r[0];\n if (r.length !== 2 || m.bookIdToNumber(s[0]) === 0 || !Number.isInteger(a) || a < 0 || !i.isVerseParseable(r[1]))\n throw new v(\"Invalid reference : \" + e);\n this.updateInternal(s[0], r[0], r[1]);\n }\n /**\n * Simplifies this verse ref so that it has no bridging of verses or\n * verse segments like `'1a'`.\n */\n simplify() {\n this._verse = void 0;\n }\n /**\n * Makes a clone of the reference.\n *\n * @returns The cloned VerseRef.\n */\n clone() {\n return new i(this);\n }\n toString() {\n const e = this.book;\n return e === \"\" ? \"\" : `${e} ${this.chapter}:${this.verse}`;\n }\n toJSON() {\n let e = this.verse;\n (e === \"\" || e === this.verseNum.toString()) && (e = void 0);\n const s = {\n book: this.book,\n chapterNum: this.chapterNum,\n verseNum: this.verseNum,\n verse: e,\n versificationStr: this.versificationStr\n };\n return e || delete s.verse, s;\n }\n /**\n * Compares this `VerseRef` with supplied one.\n * @param verseRef - object to compare this one to.\n * @returns `true` if this `VerseRef` is equal to the supplied one, `false` otherwise.\n */\n equals(e) {\n return e instanceof i ? e._bookNum === this._bookNum && e._chapterNum === this._chapterNum && e._verseNum === this._verseNum && e.verse === this.verse && (e.versification == null && this.versification == null || e.versification != null && this.versification != null && e.versification.equals(this.versification)) : !1;\n }\n /**\n * Enumerate all individual verses contained in a VerseRef.\n * Verse ranges are indicated by \"-\" and consecutive verses by \",\"s.\n * Examples:\n * GEN 1:2 returns GEN 1:2\n * GEN 1:1a-3b,5 returns GEN 1:1a, GEN 1:2, GEN 1:3b, GEN 1:5\n * GEN 1:2a-2c returns //! ??????\n *\n * @param specifiedVersesOnly - if set to true return only verses that are\n * explicitly specified only, not verses within a range. Defaults to `false`.\n * @param verseRangeSeparators - Verse range separators.\n * Defaults to `VerseRef.verseRangeSeparators`.\n * @param verseSequenceSeparators - Verse sequence separators.\n * Defaults to `VerseRef.verseSequenceIndicators`.\n * @returns An array of all single verse references in this VerseRef.\n */\n allVerses(e = !1, s = i.verseRangeSeparators, r = i.verseSequenceIndicators) {\n if (this._verse == null || this.chapterNum <= 0)\n return [this.clone()];\n const a = [], o = E(this._verse, r);\n for (const u of o.map((f) => E(f, s))) {\n const f = this.clone();\n f.verse = u[0];\n const d = f.verseNum;\n if (a.push(f), u.length > 1) {\n const b = this.clone();\n if (b.verse = u[1], !e)\n for (let p = d + 1; p < b.verseNum; p++) {\n const J = new i(\n this._bookNum,\n this._chapterNum,\n p,\n this.versification\n );\n this.isExcluded || a.push(J);\n }\n a.push(b);\n }\n }\n return a;\n }\n /**\n * Validates a verse number using the supplied separators rather than the defaults.\n */\n validateVerse(e, s) {\n if (!this.verse)\n return this.internalValid;\n let r = 0;\n for (const a of this.allVerses(!0, e, s)) {\n const o = a.internalValid;\n if (o !== 0)\n return o;\n const u = a.BBBCCCVVV;\n if (r > u)\n return 3;\n if (r === u)\n return 4;\n r = u;\n }\n return 0;\n }\n /**\n * Gets whether a single verse reference is valid.\n */\n get internalValid() {\n return this.versification == null ? 1 : this._bookNum <= 0 || this._bookNum > m.lastBook ? 2 : (m.isCanonical(this._bookNum), 0);\n }\n setEmpty(e = i.defaultVersification) {\n this._bookNum = 0, this._chapterNum = -1, this._verse = void 0, this.versification = e;\n }\n updateInternal(e, s, r) {\n this.bookNum = m.bookIdToNumber(e), this.chapter = s, this.verse = r;\n }\n};\nn(i, \"defaultVersification\", c.English), n(i, \"verseRangeSeparator\", \"-\"), n(i, \"verseSequenceIndicator\", \",\"), n(i, \"verseRangeSeparators\", [i.verseRangeSeparator]), n(i, \"verseSequenceIndicators\", [i.verseSequenceIndicator]), n(i, \"chapterDigitShifter\", 1e3), n(i, \"bookDigitShifter\", i.chapterDigitShifter * i.chapterDigitShifter), n(i, \"bcvMaxValue\", i.chapterDigitShifter - 1), /**\n * The valid status of the VerseRef.\n */\nn(i, \"ValidStatusType\", D);\nlet M = i;\nclass v extends Error {\n}\nexport {\n _ as BookSet,\n m as Canon,\n c as ScrVers,\n l as ScrVersType,\n M as VerseRef,\n v as VerseRefException\n};\n//# sourceMappingURL=index.es.js.map\n","import React from 'react';\nimport * as DropdownMenuPrimitive from '@radix-ui/react-dropdown-menu';\nimport { Check, ChevronRight, Circle } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport const DropdownMenu = DropdownMenuPrimitive.Root;\n\nexport const DropdownMenuTrigger = DropdownMenuPrimitive.Trigger;\n\nexport const DropdownMenuGroup = DropdownMenuPrimitive.Group;\n\nexport const DropdownMenuPortal = DropdownMenuPrimitive.Portal;\n\nexport const DropdownMenuSub = DropdownMenuPrimitive.Sub;\n\nexport const DropdownMenuRadioGroup = DropdownMenuPrimitive.RadioGroup;\n\nexport type DropdownMenuSubTriggerProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.SubTrigger\n> & {\n className?: string;\n inset?: boolean;\n};\n\nexport type DropdownMenuSubContentProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.SubContent\n> & {\n className?: string;\n};\n\nexport type DropdownMenuContentProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Content\n> & {\n className?: string;\n sideOffset?: number;\n};\n\nexport type DropdownMenuItemProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Item\n> & {\n className?: string;\n inset?: boolean;\n};\n\nexport type DropdownMenuCheckboxItemProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.CheckboxItem\n> & {\n className?: string;\n checked?: boolean;\n};\n\nexport type DropdownMenuRadioItemProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.RadioItem\n> & {\n className?: string;\n};\n\nexport type DropdownMenuLabelProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Label\n> & {\n className?: string;\n inset?: boolean;\n};\n\nexport type DropdownMenuSeparatorProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Separator\n> & {\n className?: string;\n};\n\nexport type DropdownMenuShortcutProps = React.HTMLAttributes & {\n className?: string;\n};\n\nexport const DropdownMenuSubTrigger = React.forwardRef<\n React.ElementRef,\n DropdownMenuSubTriggerProps\n>(({ className, inset, children, ...props }, ref) => (\n \n {children}\n \n \n));\nDropdownMenuSubTrigger.displayName = DropdownMenuPrimitive.SubTrigger.displayName;\n\nexport const DropdownMenuSubContent = React.forwardRef<\n React.ElementRef,\n DropdownMenuSubContentProps\n>(({ className, ...props }, ref) => (\n \n));\nDropdownMenuSubContent.displayName = DropdownMenuPrimitive.SubContent.displayName;\n\nexport const DropdownMenuContent = React.forwardRef<\n React.ElementRef,\n DropdownMenuContentProps\n>(({ className, sideOffset = 4, ...props }, ref) => (\n \n \n \n));\nDropdownMenuContent.displayName = DropdownMenuPrimitive.Content.displayName;\n\n/**\n * TODO: fix: direction is not automatically handled by this component, so that shortcuts are\n * display always to the right\n */\nexport const DropdownMenuItem = React.forwardRef<\n React.ElementRef,\n DropdownMenuItemProps\n>(({ className, inset, ...props }, ref) => (\n \n));\nDropdownMenuItem.displayName = DropdownMenuPrimitive.Item.displayName;\n\nexport const DropdownMenuCheckboxItem = React.forwardRef<\n React.ElementRef,\n DropdownMenuCheckboxItemProps\n>(({ className, children, checked, ...props }, ref) => (\n \n \n \n \n \n \n {children}\n \n));\nDropdownMenuCheckboxItem.displayName = DropdownMenuPrimitive.CheckboxItem.displayName;\n\nexport const DropdownMenuRadioItem = React.forwardRef<\n React.ElementRef,\n DropdownMenuRadioItemProps\n>(({ className, children, ...props }, ref) => (\n \n \n \n \n \n \n {children}\n \n));\nDropdownMenuRadioItem.displayName = DropdownMenuPrimitive.RadioItem.displayName;\n\nexport const DropdownMenuLabel = React.forwardRef<\n React.ElementRef,\n DropdownMenuLabelProps\n>(({ className, inset, ...props }, ref) => (\n \n));\nDropdownMenuLabel.displayName = DropdownMenuPrimitive.Label.displayName;\n\nexport const DropdownMenuSeparator = React.forwardRef<\n React.ElementRef,\n DropdownMenuSeparatorProps\n>(({ className, ...props }, ref) => (\n \n));\nDropdownMenuSeparator.displayName = DropdownMenuPrimitive.Separator.displayName;\n\nexport function DropdownMenuShortcut({ className, ...props }: DropdownMenuShortcutProps) {\n return (\n \n );\n}\nDropdownMenuShortcut.displayName = 'DropdownMenuShortcut';\n","import { Canon } from '@sillsdev/scripture';\nimport { PropsWithChildren, KeyboardEvent, forwardRef } from 'react';\nimport { DropdownMenuItem as ShadDropdownMenuItem } from '@/components/shadcn-ui/dropdown-menu';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport type BookType = 'OT' | 'NT' | 'DC';\n\ntype BookMenuItemProps = PropsWithChildren<{\n /** String id of book */\n bookId: string;\n /** Callback to run when a book menu item is selected */\n handleSelectBook: () => void;\n /** Indicates if this menu item is currently selected */\n isSelected: boolean;\n /** Function that is called upon highlighting a book in the dropdown menu */\n handleHighlightBook: () => void;\n /**\n * Function that is called on pressing a key\n *\n * @param event Event that contains information about the key stroke\n */\n handleKeyDown: (event: KeyboardEvent) => void;\n /**\n * Type of book associated with this menu item, coordinates color labels ? Mock up has the labels\n * coordinated to genre\n */\n bookType: BookType;\n}>;\n\nconst BookMenuItem = forwardRef(\n (\n {\n bookId,\n handleSelectBook,\n isSelected,\n handleHighlightBook,\n handleKeyDown,\n bookType,\n children,\n }: BookMenuItemProps,\n ref,\n ) => {\n return (\n {\n // preventDefault() here prevents the entire dropdown menu from closing when selecting this item\n event.preventDefault();\n handleSelectBook();\n }}\n onKeyDown={(event: KeyboardEvent) => {\n handleKeyDown(event);\n }}\n onFocus={handleHighlightBook}\n onMouseMove={handleHighlightBook}\n >\n \n {Canon.bookIdToEnglishName(bookId)}\n \n {isSelected &&
    {children}
    }\n \n );\n },\n);\n\nexport default BookMenuItem;\n","import { cn } from '@/utils/shadcn-ui.util';\nimport { useCallback } from 'react';\n\nexport type ChapterSelectProps = {\n /**\n * Callback to run when a chapter div is selected\n *\n * @param chapterNumber Number of the chapter that has been selected\n */\n handleSelectChapter: (chapterNumber: number) => void;\n /** The highest chapter number in the book (of course equal to number of chapters in the book) */\n endChapter: number;\n /** The chapter number that is currently selected */\n activeChapter: number;\n /** The chapter number that is currently highlighted using keyboard or mouse navigation */\n highlightedChapter: number;\n /**\n * Callback to run when a chapter is highlighted by the user\n *\n * @param chapterNumber The chapter that is highlighted\n */\n handleHighlightedChapter: (chapterNumber: number) => void;\n};\n\nfunction ChapterSelect({\n handleSelectChapter,\n endChapter,\n activeChapter,\n highlightedChapter,\n handleHighlightedChapter,\n}: ChapterSelectProps) {\n const chapters = Array.from({ length: endChapter }, (_, i) => i + 1);\n\n const handleMouse = useCallback(\n (chapterNumber: number) => {\n handleHighlightedChapter(chapterNumber);\n },\n [handleHighlightedChapter],\n );\n\n return (\n
    \n {chapters.map((chapter) => (\n {\n event.preventDefault();\n event.stopPropagation();\n handleSelectChapter(chapter);\n }}\n role=\"button\"\n onKeyDown={(event) => {\n if (event.key === 'Enter') {\n handleSelectChapter(chapter);\n }\n }}\n tabIndex={0}\n onMouseMove={() => handleMouse(chapter)}\n >\n {chapter}\n
    \n ))}\n
    \n );\n}\n\nexport default ChapterSelect;\n","import { DropdownMenuLabel as ShadDropdownMenuLabel } from '@/components/shadcn-ui/dropdown-menu';\nimport { Bookmark, Clock, ArrowDownWideNarrow } from 'lucide-react';\n\nexport type GoToMenuItemProps = {\n handleSort: () => void;\n handleLocationHistory: () => void;\n handleBookmarks: () => void;\n};\n\nfunction GoToMenuItem({ handleSort, handleLocationHistory, handleBookmarks }: GoToMenuItemProps) {\n return (\n \n

    Go To

    \n
    \n \n \n \n
    \n
    \n );\n}\n\nexport default GoToMenuItem;\n","import BookChapterInput from '@/components/advanced/book-chapter-control/book-chapter-input.component';\nimport BookMenuItem, {\n BookType,\n} from '@/components/advanced/book-chapter-control/book-menu-item.component';\nimport ChapterSelect from '@/components/advanced/book-chapter-control/chapter-select.component';\nimport GoToMenuItem from '@/components/advanced/book-chapter-control/go-to-menu-item.component';\nimport {\n DropdownMenu as ShadDropdownMenu,\n DropdownMenuContent as ShadDropdownMenuContent,\n DropdownMenuLabel as ShadDropdownMenuLabel,\n DropdownMenuSeparator as ShadDropdownMenuSeparator,\n DropdownMenuTrigger as ShadDropdownMenuTrigger,\n} from '@/components/shadcn-ui/dropdown-menu';\nimport { Canon } from '@sillsdev/scripture';\nimport { ScriptureReference, getChaptersForBook } from 'platform-bible-utils';\nimport {\n KeyboardEvent as ReactKeyboardEvent,\n useCallback,\n useEffect,\n useLayoutEffect,\n useRef,\n useState,\n} from 'react';\n\ntype BookTypeLabels = {\n [bookType in BookType]: string;\n};\ntype BookChapterControlProps = {\n scrRef: ScriptureReference;\n handleSubmit: (scrRef: ScriptureReference) => void;\n};\n\nconst ALL_BOOK_IDS = Canon.allBookIds;\nconst BOOK_TYPE_LABELS: BookTypeLabels = {\n OT: 'Old Testament',\n NT: 'New Testament',\n DC: 'Deuterocanon',\n};\nconst BOOK_TYPE_ARRAY: BookType[] = ['OT', 'NT', 'DC'];\n// This is the height of three menu items to offset scrolling to the selected menu item\n// If you use menuItemRef.clientHeight- includes height of chapter div which is too big\nconst SCROLL_OFFSET = 32 + 32 + 32;\nconst SEARCH_QUERY_FORMATS = [\n /^(\\w+)$/i, // Matches a single word (book name or id)\n /^(\\w+)(?:\\s(\\d+))$/i, // Matches a word followed by a chapter number\n /^(\\w+)(?:\\s(\\d+):(\\d+))$/i, // Matches a word followed by a chapter and verse number\n];\nconst fetchGroupedBooks = (bookType: BookType) => {\n const groupedBooks = {\n OT: ALL_BOOK_IDS.filter((bookId) => Canon.isBookOT(bookId)),\n NT: ALL_BOOK_IDS.filter((bookId) => Canon.isBookNT(bookId)),\n DC: ALL_BOOK_IDS.filter((bookId) => Canon.isBookDC(bookId)),\n };\n return groupedBooks[bookType];\n};\nconst fetchEndChapter = (bookId: string) => {\n // getChaptersForBook returns -1 if not found in scrBookData\n // scrBookData only includes OT and NT, so all DC will return -1\n return getChaptersForBook(Canon.bookIdToNumber(bookId));\n};\n\n/**\n * Gets all of the English names from book ids\n *\n * @returns String[]\n */\nfunction getAllEnglishNames(): string[] {\n const allEnglishNames = ALL_BOOK_IDS.map((bookId) => {\n return Canon.bookIdToEnglishName(bookId);\n });\n return allEnglishNames;\n}\n\n/**\n * Determines if bookName is in allEnglishNames\n *\n * @param bookName Book English name\n * @returns True if bookName is included, false otherwise\n */\nfunction isValidBookEnglishName(bookName: string): boolean {\n return getAllEnglishNames().includes(bookName);\n}\n\n/**\n * Gets a bookId from given English name\n *\n * @param bookName Book English name\n * @returns BookId of provided bookName, undefined otherwise\n */\nfunction getBookIdFromEnglishName(bookName: string): string | undefined {\n // Convert bookName to lowercase and then capitalize the first letter\n const formattedBookName = bookName.toLowerCase().replace(/^\\w/, (c) => c.toUpperCase());\n\n if (isValidBookEnglishName(formattedBookName)) {\n const matchingBookId = ALL_BOOK_IDS.find((bookId) => {\n return Canon.bookIdToEnglishName(bookId) === formattedBookName;\n });\n return matchingBookId;\n }\n\n return undefined;\n}\n\nfunction BookChapterControl({ scrRef, handleSubmit }: BookChapterControlProps) {\n const [searchQuery, setSearchQuery] = useState('');\n const [selectedBookId, setSelectedBookId] = useState(\n Canon.bookNumberToId(scrRef.bookNum),\n );\n const [highlightedChapter, setHighlightedChapter] = useState(scrRef.chapterNum ?? 0);\n const [highlightedBookId, setHighlightedBookId] = useState(\n Canon.bookNumberToId(scrRef.bookNum),\n );\n const [isContentOpen, setIsContentOpen] = useState(false);\n const [isContentOpenDelayed, setIsContentOpenDelayed] = useState(isContentOpen);\n\n // This ref will always be defined\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const inputRef = useRef(undefined!);\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const contentRef = useRef(undefined!);\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const menuItemRef = useRef(undefined!);\n\n const fetchFilteredBooks = useCallback(\n (bookType: BookType) => {\n return fetchGroupedBooks(bookType).filter((bookId: string) => {\n const englishNameLowerCase = Canon.bookIdToEnglishName(bookId).toLowerCase();\n const normalizedQuery = searchQuery.replace(/[^a-zA-Z]/g, '').toLowerCase();\n return (\n englishNameLowerCase.includes(normalizedQuery) || // Match book name\n bookId.toLowerCase().includes(normalizedQuery) // Match book ID\n );\n });\n },\n [searchQuery],\n );\n\n const handleSearchInput = (searchString: string) => {\n setSearchQuery(searchString);\n };\n\n /**\n * Whether to prevent radix's logic from closing the dropdown. This is important because radix\n * tries to close the dropdown when the input first focuses, and we don't want it to do that. But\n * we don't want to prevent the dropdown from closing when we click away from the input, so we\n * don't want to just keep it open if the input is focused\n */\n const shouldPreventAutoClosing = useRef(false);\n\n const controlMenuState = useCallback((open: boolean) => {\n if (shouldPreventAutoClosing.current) {\n shouldPreventAutoClosing.current = false;\n return;\n }\n setIsContentOpen(open);\n }, []);\n\n const updateReference = useCallback(\n (bookId: string, shouldClose: boolean, chapter?: number, verse?: number) => {\n setHighlightedChapter(\n Canon.bookNumberToId(scrRef.bookNum) !== bookId ? 1 : scrRef.chapterNum,\n );\n\n if (shouldClose || fetchEndChapter(bookId) === -1) {\n handleSubmit({\n bookNum: Canon.bookIdToNumber(bookId),\n chapterNum: chapter || 1,\n verseNum: verse || 1,\n });\n\n setIsContentOpen(false);\n setSearchQuery('');\n return;\n }\n\n setSelectedBookId(selectedBookId !== bookId ? bookId : '');\n setIsContentOpen(!shouldClose);\n },\n [handleSubmit, scrRef.bookNum, scrRef.chapterNum, selectedBookId],\n );\n\n const handleSelectChapter = (chapterNumber: number) => {\n if (chapterNumber <= 0 || chapterNumber > fetchEndChapter(selectedBookId)) {\n return;\n }\n updateReference(selectedBookId, true, chapterNumber);\n };\n\n const handleInputSubmit = useCallback(() => {\n SEARCH_QUERY_FORMATS.forEach((format) => {\n const matches = searchQuery.match(format);\n if (matches) {\n // Book should be a bookId or an english name\n const [book, chapter = undefined, verse = undefined] = matches.slice(1);\n const englishName = getBookIdFromEnglishName(book);\n\n if (Canon.isBookIdValid(book) || englishName) {\n updateReference(\n englishName ?? book,\n true,\n chapter ? parseInt(chapter, 10) : 1,\n verse ? parseInt(verse, 10) : 1,\n );\n }\n }\n });\n }, [updateReference, searchQuery]);\n\n const handleKeyDownInput = useCallback(\n (event: ReactKeyboardEvent) => {\n if (!isContentOpen) {\n setIsContentOpen(true);\n } else if (event.key === 'ArrowDown' || event.key === 'ArrowUp') {\n if (\n typeof menuItemRef !== 'undefined' &&\n // Ref uses null\n // eslint-disable-next-line no-null/no-null\n menuItemRef.current !== null\n ) {\n menuItemRef.current.focus();\n } else if (\n typeof contentRef !== 'undefined' &&\n // Ref uses null\n // eslint-disable-next-line no-null/no-null\n contentRef.current !== null\n ) {\n contentRef.current.focus();\n }\n event.preventDefault();\n }\n },\n [isContentOpen],\n );\n\n const handleKeyDownContent = (event: ReactKeyboardEvent) => {\n // When the dropdown menu has focus, key strokes should give focus to the input component,\n // unless they're navigation keys (arrows and enter)\n const { key } = event;\n if (\n key === 'ArrowRight' ||\n key === 'ArrowLeft' ||\n key === 'ArrowDown' ||\n key === 'ArrowUp' ||\n key === 'Enter'\n ) {\n return;\n }\n\n inputRef.current.dispatchEvent(new KeyboardEvent('keydown', { key }));\n inputRef.current.focus();\n };\n\n const handleKeyDownMenuItem = (event: ReactKeyboardEvent) => {\n const { key } = event;\n if (highlightedBookId === selectedBookId) {\n if (key === 'Enter') {\n event.preventDefault();\n updateReference(selectedBookId, true, highlightedChapter);\n return;\n }\n\n let chapterOffSet = 0;\n if (key === 'ArrowRight') {\n if (highlightedChapter < fetchEndChapter(highlightedBookId)) {\n chapterOffSet = 1;\n } else {\n event.preventDefault();\n return;\n }\n } else if (key === 'ArrowLeft') {\n if (highlightedChapter > 1) {\n chapterOffSet = -1;\n } else {\n event.preventDefault();\n return;\n }\n } else if (key === 'ArrowDown') {\n chapterOffSet = 6;\n } else if (key === 'ArrowUp') {\n chapterOffSet = -6;\n }\n if (\n highlightedChapter + chapterOffSet <= 0 ||\n highlightedChapter + chapterOffSet > fetchEndChapter(highlightedBookId)\n ) {\n setHighlightedChapter(0);\n } else if (chapterOffSet !== 0) {\n setHighlightedChapter(highlightedChapter + chapterOffSet);\n event.preventDefault();\n }\n }\n };\n\n useEffect(() => {\n if (selectedBookId === highlightedBookId) {\n if (selectedBookId === Canon.bookNumberToId(scrRef.bookNum)) {\n setHighlightedChapter(scrRef.chapterNum);\n } else {\n setHighlightedChapter(1);\n }\n } else {\n setHighlightedChapter(0);\n }\n }, [highlightedBookId, scrRef.bookNum, scrRef.chapterNum, selectedBookId]);\n\n // The purpose of these useLayoutEffects and timeout is to delay the scroll just\n // enough so that the refs are defined and available when they are used after the timeout\n useLayoutEffect(() => {\n setIsContentOpenDelayed(isContentOpen);\n }, [isContentOpen]);\n\n useLayoutEffect(() => {\n const scrollTimeout = setTimeout(() => {\n if (isContentOpenDelayed && contentRef.current && menuItemRef.current) {\n const menuItemOffsetTop = menuItemRef.current.offsetTop;\n const scrollPosition = menuItemOffsetTop - SCROLL_OFFSET;\n contentRef.current.scrollTo({ top: scrollPosition, behavior: 'instant' });\n }\n }, 10);\n return () => {\n clearTimeout(scrollTimeout);\n };\n }, [isContentOpenDelayed]);\n\n return (\n
    \n \n \n {\n setSelectedBookId(Canon.bookNumberToId(scrRef.bookNum));\n setHighlightedBookId(Canon.bookNumberToId(scrRef.bookNum));\n setHighlightedChapter(scrRef.chapterNum > 0 ? scrRef.chapterNum : 0);\n setIsContentOpen(true);\n inputRef.current.focus();\n }}\n onFocus={() => {\n // Radix thinks we want to close because the input is being focused. Prevent that\n shouldPreventAutoClosing.current = true;\n }}\n handleSubmit={handleInputSubmit}\n placeholder={`${Canon.bookNumberToEnglishName(scrRef.bookNum)} ${scrRef.chapterNum}:${scrRef.verseNum}`}\n />\n \n \n console.log('sorting')}\n handleLocationHistory={() => console.log('location history')}\n handleBookmarks={() => console.log('bookmarks')}\n />\n {BOOK_TYPE_ARRAY.map(\n (bookType, bookTypeIndex) =>\n fetchFilteredBooks(bookType).length > 0 && (\n
    \n \n {BOOK_TYPE_LABELS[bookType]}\n \n\n {fetchFilteredBooks(bookType).map((bookId) => (\n
    \n updateReference(bookId, false)}\n isSelected={selectedBookId === bookId}\n handleHighlightBook={() => setHighlightedBookId(bookId)}\n handleKeyDown={handleKeyDownMenuItem}\n bookType={bookType}\n ref={(element: HTMLDivElement) => {\n if (selectedBookId === bookId) menuItemRef.current = element;\n }}\n >\n {\n setHighlightedChapter(chapterNumber);\n }}\n />\n \n
    \n ))}\n {BOOK_TYPE_ARRAY.length - 1 !== bookTypeIndex ? (\n \n ) : undefined}\n
    \n ),\n )}\n \n
    \n
    \n );\n}\n\nexport default BookChapterControl;\n","import React from 'react';\nimport { Slot } from '@radix-ui/react-slot';\nimport { cva, type VariantProps } from 'class-variance-authority';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport const buttonVariants = cva(\n 'pr-twp tw-inline-flex tw-items-center tw-justify-center tw-whitespace-nowrap tw-rounded-md tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-colors focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50',\n {\n variants: {\n variant: {\n default: 'tw-bg-primary tw-text-primary-foreground hover:tw-bg-primary/90',\n destructive: 'tw-bg-destructive tw-text-destructive-foreground hover:tw-bg-destructive/90',\n outline:\n 'tw-border tw-border-input tw-bg-background hover:tw-bg-accent hover:tw-text-accent-foreground',\n secondary: 'tw-bg-secondary tw-text-secondary-foreground hover:tw-bg-secondary/80',\n ghost: 'hover:tw-bg-accent hover:tw-text-accent-foreground',\n link: 'tw-text-primary tw-underline-offset-4 hover:tw-underline',\n },\n size: {\n default: 'tw-h-10 tw-px-4 tw-py-2',\n sm: 'tw-h-9 tw-rounded-md tw-px-3',\n lg: 'tw-h-11 tw-rounded-md tw-px-8',\n icon: 'tw-h-10 tw-w-10',\n },\n },\n defaultVariants: {\n variant: 'default',\n size: 'default',\n },\n },\n);\n\nexport interface ButtonProps\n extends React.ButtonHTMLAttributes,\n VariantProps {\n asChild?: boolean;\n}\n\nexport const Button = React.forwardRef(\n ({ className, variant, size, asChild = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'button';\n return (\n \n );\n },\n);\nButton.displayName = 'Button';\n","import React from 'react';\nimport * as LabelPrimitive from '@radix-ui/react-label';\nimport { cva, type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst labelVariants = cva(\n 'tw-text-sm tw-font-medium tw-leading-none peer-disabled:tw-cursor-not-allowed peer-disabled:tw-opacity-70',\n);\n\nexport const Label = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef & VariantProps\n>(({ className, ...props }, ref) => (\n \n));\nLabel.displayName = LabelPrimitive.Root.displayName;\n","import React from 'react';\nimport * as RadioGroupPrimitive from '@radix-ui/react-radio-group';\nimport { Circle } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst RadioGroup = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => {\n return (\n \n );\n});\nRadioGroup.displayName = RadioGroupPrimitive.Root.displayName;\n\nconst RadioGroupItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => {\n return (\n \n \n \n \n \n );\n});\nRadioGroupItem.displayName = RadioGroupPrimitive.Item.displayName;\n\nexport { RadioGroup, RadioGroupItem };\n","import React from 'react';\nimport * as PopoverPrimitive from '@radix-ui/react-popover';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Popover = PopoverPrimitive.Root;\n\nconst PopoverTrigger = PopoverPrimitive.Trigger;\n\nconst PopoverContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, align = 'center', sideOffset = 4, ...props }, ref) => (\n \n \n \n));\nPopoverContent.displayName = PopoverPrimitive.Content.displayName;\n\nexport { Popover, PopoverTrigger, PopoverContent };\n","import React from 'react';\nimport * as DialogPrimitive from '@radix-ui/react-dialog';\nimport { X } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Dialog = DialogPrimitive.Root;\n\nconst DialogTrigger = DialogPrimitive.Trigger;\n\nconst DialogPortal = DialogPrimitive.Portal;\n\nconst DialogClose = DialogPrimitive.Close;\n\nconst DialogOverlay = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nDialogOverlay.displayName = DialogPrimitive.Overlay.displayName;\n\nconst DialogContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, ...props }, ref) => (\n \n \n \n {children}\n \n \n Close\n \n \n \n));\nDialogContent.displayName = DialogPrimitive.Content.displayName;\n\nfunction DialogHeader({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nDialogHeader.displayName = 'DialogHeader';\n\nfunction DialogFooter({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nDialogFooter.displayName = 'DialogFooter';\n\nconst DialogTitle = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nDialogTitle.displayName = DialogPrimitive.Title.displayName;\n\nconst DialogDescription = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nDialogDescription.displayName = DialogPrimitive.Description.displayName;\n\nexport {\n Dialog,\n DialogPortal,\n DialogOverlay,\n DialogClose,\n DialogTrigger,\n DialogContent,\n DialogHeader,\n DialogFooter,\n DialogTitle,\n DialogDescription,\n};\n","import React from 'react';\nimport { type DialogProps } from '@radix-ui/react-dialog';\nimport { Command as CommandPrimitive } from 'cmdk';\nimport { Search } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Dialog, DialogContent } from '@/components/shadcn-ui/dialog';\n\nconst Command = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nCommand.displayName = CommandPrimitive.displayName;\n\ninterface CommandDialogProps extends DialogProps {}\n\nfunction CommandDialog({ children, ...props }: CommandDialogProps) {\n return (\n \n \n \n {children}\n \n \n \n );\n}\n\nconst CommandInput = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n
    \n \n \n
    \n));\n\nCommandInput.displayName = CommandPrimitive.Input.displayName;\n\nconst CommandList = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\n\nCommandList.displayName = CommandPrimitive.List.displayName;\n\nconst CommandEmpty = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>((props, ref) => (\n \n));\n\nCommandEmpty.displayName = CommandPrimitive.Empty.displayName;\n\nconst CommandGroup = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\n\nCommandGroup.displayName = CommandPrimitive.Group.displayName;\n\nconst CommandSeparator = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nCommandSeparator.displayName = CommandPrimitive.Separator.displayName;\n\nconst CommandItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\n\nCommandItem.displayName = CommandPrimitive.Item.displayName;\n\nfunction CommandShortcut({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nCommandShortcut.displayName = 'CommandShortcut';\n\nexport {\n Command,\n CommandDialog,\n CommandInput,\n CommandList,\n CommandEmpty,\n CommandGroup,\n CommandItem,\n CommandShortcut,\n CommandSeparator,\n};\n","import { useState } from 'react';\nimport { Check, ChevronsUpDown } from 'lucide-react';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport { Popover, PopoverContent, PopoverTrigger } from '@/components/shadcn-ui/popover';\nimport {\n Command,\n CommandEmpty,\n CommandInput,\n CommandItem,\n CommandList,\n} from '@/components/shadcn-ui/command';\nimport { PopoverProps } from '@radix-ui/react-popover';\n\nexport type ComboBoxLabelOption = { label: string };\nexport type ComboBoxOption = string | number | ComboBoxLabelOption;\n\nexport type ComboBoxProps = {\n /** Optional unique identifier */\n id?: string;\n /** Text label title for combobox */\n /** List of available options for the dropdown menu */\n options?: readonly T[];\n /** Additional css classes to help with unique styling of the combo box button */\n buttonClassName?: string;\n /** Additional css classes to help with unique styling of the combo box popover */\n popoverContentClassName?: string;\n /**\n * The selected value that the combo box currently holds. Must be shallow equal to one of the\n * options entries.\n */\n value?: T;\n /** Triggers when content of textfield is changed */\n onChange?: (newValue: T) => void;\n /** Used to determine the string value for a given option. */\n getOptionLabel?: (option: ComboBoxOption) => string;\n /** Text displayed on button if `value` is undefined */\n buttonPlaceholder?: string;\n /** Placeholder text for text field */\n textPlaceholder?: string;\n /** Text to display when no options match input */\n commandEmptyMessage?: string;\n /** Variant of button */\n buttonVariant?: ButtonProps['variant'];\n /** Text direction ltr or rtl */\n dir?: Direction;\n /** Optional boolean to set if trigger should be disabled */\n isDisabled?: boolean;\n} & PopoverProps;\n\ntype Direction = 'ltr' | 'rtl';\n\nfunction getOptionLabelDefault(option: ComboBoxOption): string {\n if (typeof option === 'string') {\n return option;\n }\n if (typeof option === 'number') {\n return option.toString();\n }\n return option.label;\n}\n\n/**\n * Autocomplete input and command palette with a list of suggestions.\n *\n * Thanks to Shadcn for heavy inspiration and documentation\n * https://ui.shadcn.com/docs/components/combobox\n */\nfunction ComboBox({\n id,\n options = [],\n buttonClassName,\n popoverContentClassName,\n value,\n onChange = () => {},\n getOptionLabel = getOptionLabelDefault,\n buttonPlaceholder = '',\n textPlaceholder = '',\n commandEmptyMessage = 'No option found',\n buttonVariant = 'outline',\n dir = 'ltr',\n isDisabled = false,\n ...props\n}: ComboBoxProps) {\n const [open, setOpen] = useState(false);\n\n return (\n \n \n \n \n {value ? getOptionLabel(value) : buttonPlaceholder}\n \n \n \n \n \n \n \n {commandEmptyMessage}\n \n {options.map((option) => (\n {\n onChange(option);\n setOpen(false);\n }}\n >\n \n {getOptionLabel(option)}\n \n ))}\n \n \n \n \n );\n}\n\nexport default ComboBox;\n","import { useMemo } from 'react';\nimport ComboBox from '@/components/basics/combo-box.component';\nimport { Label } from '@/components/shadcn-ui/label';\n\nexport type ChapterRangeSelectorProps = {\n startChapter: number;\n endChapter: number;\n handleSelectStartChapter: (chapter: number) => void;\n handleSelectEndChapter: (chapter: number) => void;\n isDisabled?: boolean;\n chapterCount: number;\n};\n\nexport default function ChapterRangeSelector({\n startChapter,\n endChapter,\n handleSelectStartChapter,\n handleSelectEndChapter,\n isDisabled = false,\n chapterCount,\n}: ChapterRangeSelectorProps) {\n const chapterOptions = useMemo(\n () => Array.from({ length: chapterCount }, (_, index) => index + 1),\n [chapterCount],\n );\n\n const onChangeStartChapter = (value: number) => {\n handleSelectStartChapter(value);\n if (value > endChapter) {\n handleSelectEndChapter(value);\n }\n };\n\n const onChangeEndChapter = (value: number) => {\n handleSelectEndChapter(value);\n if (value < startChapter) {\n handleSelectStartChapter(value);\n }\n };\n\n return (\n <>\n \n option.toString()}\n value={startChapter}\n />\n\n \n option.toString()}\n value={endChapter}\n />\n \n );\n}\n","import { Button } from '@/components/shadcn-ui/button';\nimport { Label } from '@/components/shadcn-ui/label';\nimport { RadioGroup, RadioGroupItem } from '@/components/shadcn-ui/radio-group';\nimport { Canon } from '@sillsdev/scripture';\nimport { LocalizedStringValue } from 'platform-bible-utils';\nimport { useState } from 'react';\nimport ChapterRangeSelector, {\n ChapterRangeSelectorProps,\n} from '../basics/chapter-range-selector.component';\n\nexport enum BookSelectionMode {\n CURRENT_BOOK = 'current book',\n CHOOSE_BOOKS = 'choose books',\n}\n\n/**\n * Object containing all keys used for localization in this component. If you're using this\n * component in an extension, you can pass it into the useLocalizedStrings hook to easily obtain the\n * localized strings and pass them into the localizedStrings prop of this component\n */\nexport const BOOK_SELECTOR_STRING_KEYS = Object.freeze([\n '%webView_bookSelector_currentBook%',\n '%webView_bookSelector_choose%',\n '%webView_bookSelector_chooseBooks%',\n] as const);\n\nexport type BookSelectorLocalizedStrings = {\n [localizedInventoryKey in (typeof BOOK_SELECTOR_STRING_KEYS)[number]]?: LocalizedStringValue;\n};\n\n/**\n * Gets the localized value for the provided key\n *\n * @param strings Object containing localized string\n * @param key Key for a localized string\n * @returns The localized value for the provided key, if available. Returns the key if no localized\n * value is available\n */\nconst localizeString = (\n strings: BookSelectorLocalizedStrings,\n key: keyof BookSelectorLocalizedStrings,\n) => {\n return strings[key] ?? key;\n};\n\ntype BookSelectorProps = ChapterRangeSelectorProps & {\n handleBookSelectionModeChange: (newMode: BookSelectionMode) => void;\n currentBookName: string;\n onSelectBooks: () => void;\n selectedBookIds: string[];\n localizedStrings: BookSelectorLocalizedStrings;\n};\n\nexport default function BookSelector({\n handleBookSelectionModeChange,\n currentBookName,\n onSelectBooks,\n selectedBookIds,\n chapterCount,\n endChapter,\n handleSelectEndChapter,\n startChapter,\n handleSelectStartChapter,\n localizedStrings,\n}: BookSelectorProps) {\n const currentBookText = localizeString(localizedStrings, '%webView_bookSelector_currentBook%');\n const chooseText = localizeString(localizedStrings, '%webView_bookSelector_choose%');\n const chooseBooksText = localizeString(localizedStrings, '%webView_bookSelector_chooseBooks%');\n\n const [bookSelectionMode, setBookSelectionMode] = useState(\n BookSelectionMode.CURRENT_BOOK,\n );\n\n const onSelectionModeChange = (newMode: BookSelectionMode) => {\n setBookSelectionMode(newMode);\n handleBookSelectionModeChange(newMode);\n };\n\n return (\n onSelectionModeChange(value as BookSelectionMode)}\n >\n
    \n
    \n
    \n \n \n
    \n \n
    \n \n
    \n
    \n
    \n
    \n \n \n
    \n \n onSelectBooks()}\n >\n {chooseText}\n \n
    \n
    \n \n );\n}\n","import { DropdownMenuTrigger } from '@radix-ui/react-dropdown-menu';\nimport { FilterIcon } from 'lucide-react';\nimport { Table } from '@tanstack/react-table';\n\nimport { Button } from '@/components/shadcn-ui/button';\nimport {\n DropdownMenu,\n DropdownMenuCheckboxItem,\n DropdownMenuContent,\n DropdownMenuLabel,\n DropdownMenuSeparator,\n} from '@/components/shadcn-ui/dropdown-menu';\n\ninterface DataTableViewOptionsProps {\n table: Table;\n}\n\nfunction DataTableViewOptions({ table }: DataTableViewOptionsProps) {\n return (\n \n \n \n \n \n Toggle columns\n \n {table\n .getAllColumns()\n .filter((column) => column.getCanHide())\n .map((column) => {\n return (\n column.toggleVisibility(!!value)}\n >\n {column.id}\n \n );\n })}\n \n \n );\n}\n\nexport default DataTableViewOptions;\n","import React from 'react';\nimport * as SelectPrimitive from '@radix-ui/react-select';\nimport { Check, ChevronDown, ChevronUp } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Select = SelectPrimitive.Root;\n\nconst SelectGroup = SelectPrimitive.Group;\n\nconst SelectValue = SelectPrimitive.Value;\n\nconst SelectTrigger = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, ...props }, ref) => (\n span]:tw-line-clamp-1',\n className,\n )}\n {...props}\n >\n {children}\n \n \n \n \n));\nSelectTrigger.displayName = SelectPrimitive.Trigger.displayName;\n\nconst SelectScrollUpButton = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n));\nSelectScrollUpButton.displayName = SelectPrimitive.ScrollUpButton.displayName;\n\nconst SelectScrollDownButton = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n));\nSelectScrollDownButton.displayName = SelectPrimitive.ScrollDownButton.displayName;\n\nconst SelectContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, position = 'popper', ...props }, ref) => (\n \n \n \n \n {children}\n \n \n \n \n));\nSelectContent.displayName = SelectPrimitive.Content.displayName;\n\nconst SelectLabel = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSelectLabel.displayName = SelectPrimitive.Label.displayName;\n\nconst SelectItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, ...props }, ref) => (\n \n \n \n \n \n \n\n {children}\n \n));\nSelectItem.displayName = SelectPrimitive.Item.displayName;\n\nconst SelectSeparator = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSelectSeparator.displayName = SelectPrimitive.Separator.displayName;\n\nexport {\n Select,\n SelectGroup,\n SelectValue,\n SelectTrigger,\n SelectContent,\n SelectLabel,\n SelectItem,\n SelectSeparator,\n SelectScrollUpButton,\n SelectScrollDownButton,\n};\n","import { ChevronLeftIcon, ChevronRightIcon, ArrowLeftIcon, ArrowRightIcon } from 'lucide-react';\nimport { Table } from '@tanstack/react-table';\n\nimport { Button } from '@/components/shadcn-ui/button';\nimport {\n Select,\n SelectContent,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\n\ninterface DataTablePaginationProps {\n table: Table;\n}\n\nfunction DataTablePagination({ table }: DataTablePaginationProps) {\n return (\n
    \n
    \n
    \n {table.getFilteredSelectedRowModel().rows.length} of{' '}\n {table.getFilteredRowModel().rows.length} row(s) selected\n
    \n
    \n

    Rows per page

    \n {\n table.setPageSize(Number(value));\n }}\n >\n \n \n \n \n {[10, 20, 30, 40, 50].map((pageSize) => (\n \n {pageSize}\n \n ))}\n \n \n
    \n
    \n Page {table.getState().pagination.pageIndex + 1} of {table.getPageCount()}\n
    \n
    \n table.setPageIndex(0)}\n disabled={!table.getCanPreviousPage()}\n >\n Go to first page\n \n \n table.previousPage()}\n disabled={!table.getCanPreviousPage()}\n >\n Go to previous page\n \n \n table.nextPage()}\n disabled={!table.getCanNextPage()}\n >\n Go to next page\n \n \n table.setPageIndex(table.getPageCount() - 1)}\n disabled={!table.getCanNextPage()}\n >\n Go to last page\n \n \n
    \n
    \n
    \n );\n}\n\nexport default DataTablePagination;\n","import React from 'react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Table = React.forwardRef<\n HTMLTableElement,\n React.HTMLAttributes & { stickyHeader?: boolean }\n>(({ className, stickyHeader, ...props }, ref) => (\n
    \n \n
    \n));\nTable.displayName = 'Table';\n\nconst TableHeader = React.forwardRef<\n HTMLTableSectionElement,\n React.HTMLAttributes & { stickyHeader?: boolean }\n>(({ className, stickyHeader, ...props }, ref) => (\n \n));\nTableHeader.displayName = 'TableHeader';\n\nconst TableBody = React.forwardRef<\n HTMLTableSectionElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableBody.displayName = 'TableBody';\n\nconst TableFooter = React.forwardRef<\n HTMLTableSectionElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n tr]:last:tw-border-b-0', className)}\n {...props}\n />\n));\nTableFooter.displayName = 'TableFooter';\n\nconst TableRow = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nTableRow.displayName = 'TableRow';\n\nconst TableHead = React.forwardRef<\n HTMLTableCellElement,\n React.ThHTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableHead.displayName = 'TableHead';\n\nconst TableCell = React.forwardRef<\n HTMLTableCellElement,\n React.TdHTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableCell.displayName = 'TableCell';\n\nconst TableCaption = React.forwardRef<\n HTMLTableCaptionElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableCaption.displayName = 'TableCaption';\n\nexport { Table, TableHeader, TableBody, TableFooter, TableHead, TableRow, TableCell, TableCaption };\n","import { useState } from 'react';\n\nimport {\n ColumnFiltersState,\n flexRender,\n getCoreRowModel,\n getFilteredRowModel,\n getPaginationRowModel,\n getSortedRowModel,\n SortingState,\n ColumnDef as TSColumnDef,\n Row as TSRow,\n RowSelectionState as TSRowSelectionState,\n SortDirection as TSSortDirection,\n Table as TSTable,\n useReactTable,\n VisibilityState,\n} from '@tanstack/react-table';\n\nimport DataTableViewOptions from '@/components/advanced/data-table/data-table-column-toggle.component';\nimport DataTablePagination from '@/components/advanced/data-table/data-table-pagination.component';\nimport { Button } from '@/components/shadcn-ui/button';\nimport {\n Table,\n TableBody,\n TableCell,\n TableHead,\n TableHeader,\n TableRow,\n} from '@/components/shadcn-ui/table';\n\nexport type ColumnDef = TSColumnDef;\nexport type RowContents = TSRow;\nexport type TableContents = TSTable;\nexport type SortDirection = TSSortDirection;\nexport type RowSelectionState = TSRowSelectionState;\n\ninterface DataTableProps {\n columns: ColumnDef[];\n data: TData[];\n enablePagination?: boolean;\n showPaginationControls?: boolean;\n showColumnVisibilityControls?: boolean;\n stickyHeader?: boolean;\n onRowClickHandler?: (row: RowContents, table: TableContents) => void;\n}\n\n/**\n * Feature-rich table component that infuses our basic shadcn-based Table component with features\n * from TanStack's React Table library\n */\nfunction DataTable({\n columns,\n data,\n enablePagination = false,\n showPaginationControls = false,\n showColumnVisibilityControls = false,\n stickyHeader = false,\n onRowClickHandler = () => {},\n}: DataTableProps) {\n const [sorting, setSorting] = useState([]);\n const [columnFilters, setColumnFilters] = useState([]);\n const [columnVisibility, setColumnVisibility] = useState({});\n const [rowSelection, setRowSelection] = useState({});\n\n const table = useReactTable({\n data,\n columns,\n getCoreRowModel: getCoreRowModel(),\n ...(enablePagination && { getPaginationRowModel: getPaginationRowModel() }),\n onSortingChange: setSorting,\n getSortedRowModel: getSortedRowModel(),\n onColumnFiltersChange: setColumnFilters,\n getFilteredRowModel: getFilteredRowModel(),\n onColumnVisibilityChange: setColumnVisibility,\n onRowSelectionChange: setRowSelection,\n state: {\n sorting,\n columnFilters,\n columnVisibility,\n rowSelection,\n },\n });\n\n return (\n
    \n {showColumnVisibilityControls && }\n \n \n {table.getHeaderGroups().map((headerGroup) => (\n \n {headerGroup.headers.map((header) => {\n return (\n \n {header.isPlaceholder\n ? undefined\n : flexRender(header.column.columnDef.header, header.getContext())}\n \n );\n })}\n \n ))}\n \n \n {table.getRowModel().rows?.length ? (\n table.getRowModel().rows.map((row) => (\n onRowClickHandler(row, table)}\n key={row.id}\n data-state={row.getIsSelected() && 'selected'}\n >\n {row.getVisibleCells().map((cell) => (\n \n {flexRender(cell.column.columnDef.cell, cell.getContext())}\n \n ))}\n \n ))\n ) : (\n \n \n No results.\n \n \n )}\n \n
    \n {enablePagination && (\n
    \n table.previousPage()}\n disabled={!table.getCanPreviousPage()}\n >\n Previous\n \n table.nextPage()}\n disabled={!table.getCanNextPage()}\n >\n Next\n \n
    \n )}\n {enablePagination && showPaginationControls && }\n
    \n );\n}\n\nexport default DataTable;\n","import {\n Table,\n TableBody,\n TableCell,\n TableHead,\n TableHeader,\n TableRow,\n} from '@/components/shadcn-ui/table';\nimport { Canon } from '@sillsdev/scripture';\nimport { deepEqual, LanguageStrings, ScriptureReference } from 'platform-bible-utils';\nimport { useMemo } from 'react';\nimport { InventoryItemOccurrence } from './inventory-utils';\n\n/** Props for the OccurrencesTable component */\ntype OccurrencesTableProps = {\n /** Data that contains scriptures references and snippets of scripture */\n occurrenceData: InventoryItemOccurrence[];\n /** Callback function that is executed when the scripture reference is changed */\n setScriptureReference: (scriptureReference: ScriptureReference) => void;\n /**\n * Object with all localized strings that the OccurrencesTable needs to work well across multiple\n * languages\n */\n localizedStrings: LanguageStrings;\n};\n\n/**\n * Table that shows occurrences of specified inventory item(s). The first column shows the related\n * scripture reference. The second column shows the snippet of scripture that contains the specified\n * inventory item\n */\nfunction OccurrencesTable({\n occurrenceData,\n setScriptureReference,\n localizedStrings,\n}: OccurrencesTableProps) {\n const referenceHeaderText =\n localizedStrings['%webView_inventory_occurrences_table_header_reference%'];\n const occurrenceHeaderText =\n localizedStrings['%webView_inventory_occurrences_table_header_occurrence%'];\n\n const occurrences: InventoryItemOccurrence[] = useMemo(() => {\n const uniqueOccurrences: InventoryItemOccurrence[] = [];\n\n occurrenceData.forEach((occurrence) => {\n if (!uniqueOccurrences.some((uniqueOccurrence) => deepEqual(uniqueOccurrence, occurrence))) {\n uniqueOccurrences.push(occurrence);\n }\n });\n\n return uniqueOccurrences;\n }, [occurrenceData]);\n\n return (\n \n \n \n {referenceHeaderText}\n {occurrenceHeaderText}\n \n \n \n {occurrences.length > 0 &&\n occurrences.map((occurrence) => (\n {\n setScriptureReference(occurrence.reference);\n }}\n >\n {`${Canon.bookNumberToEnglishName(occurrence.reference.bookNum)} ${occurrence.reference.chapterNum}:${occurrence.reference.verseNum}`}\n {occurrence.text}\n \n ))}\n \n
    \n );\n}\n\nexport default OccurrencesTable;\n","import React from 'react';\nimport * as CheckboxPrimitive from '@radix-ui/react-checkbox';\nimport { Check } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Checkbox = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n \n \n));\nCheckbox.displayName = CheckboxPrimitive.Root.displayName;\n\nexport default Checkbox;\n","import { Canon } from '@sillsdev/scripture';\nimport { ScriptureReference } from 'platform-bible-utils';\n\n/* #region Types */\n\n/**\n * Status of items that appear in inventories. 'approved' and 'unapproved' items are defined in the\n * project's `Settings.xml`. All other items are defined as 'unknown'\n */\nexport type Status = 'approved' | 'unapproved' | 'unknown';\n\n/** Occurrence of item in inventory. Primarily used by table that shows occurrences */\nexport type InventoryItemOccurrence = {\n /** Reference to scripture where the item appears */\n reference: ScriptureReference;\n /** Snippet of scripture that contains the occurrence */\n text: string;\n};\n\n/** Data structure that contains all information on an item that is shown in an inventory */\nexport type InventoryTableData = {\n /**\n * The item (e.g. a character in the characters inventory, a marker in the marker inventory) In\n * most cases the array will only have one element. In case of additional items (e.g. the\n * preceding marker in the markers check), the primary item should be stored in the first index.\n * To show additional items in the inventory, make sure to configure the `additionalItemsLabels`\n * prop for the Inventory component\n */\n items: string[];\n /** The number of times this item occurs in the selected scope */\n count: number;\n /** The status of this item (see documentation for `Status` type for more information) */\n status: Status;\n /** Occurrences of this item in the scripture text for the selected scope */\n occurrences: InventoryItemOccurrence[];\n};\n\n/* #endregion */\n\n/* #region Functions */\n\n/**\n * Splits USFM string into shorter line-like segments\n *\n * @param text A single (likely very large) USFM string\n * @returns An array containing the input text, split into shorter segments\n */\nexport const getLinesFromUSFM = (text: string) => {\n // Splits on (CR)LF, CR, \\v, \\c and \\id\n return text.split(/(?:\\r?\\n|\\r)|(?=(?:\\\\(?:v|c|id)))/g);\n};\n\n/**\n * Extracts chapter or verse number from USFM strings that start with a \\c or \\v marker\n *\n * @param text USFM string that is expected to start with \\c or \\v marker\n * @returns Chapter or verse number if one is found. Else returns 0.\n */\nexport const getNumberFromUSFM = (text: string): number | undefined => {\n // Captures all digits that follow \\v or \\c markers followed by whitespace located at the start of a string\n const regex = /^\\\\[vc]\\s+(\\d+)/;\n const match = text.match(regex);\n\n if (match) {\n return +match[1];\n }\n return undefined;\n};\n\n/**\n * Gets book ID from USFM string that starts with the \\id marker, and returns book number for it\n *\n * @param text USFM string that is expected to start with \\id marker\n * @returns Book number corresponding to the \\id marker in the input text. Returns 0 if no marker is\n * found or the marker is not valid\n */\nexport const getBookNumFromId = (text: string): number => {\n // Captures all digits that follow an \\id marker followed by whitespace located at the start of a string\n const match = text.match(/^\\\\id\\s+([A-Za-z]+)/);\n if (match) {\n return Canon.bookIdToNumber(match[1]);\n }\n return 0;\n};\n\n/**\n * Gets the status for an item, typically used in the Inventory component\n *\n * @param item The item for which the status is being requested\n * @param approvedItems Array of approved items, typically as defined in `Settings.xml`\n * @param unapprovedItems Array of unapproved items, typically as defined in `Settings.xml`\n * @returns The status for the specified item\n */\nexport const getStatusForItem = (\n item: string,\n approvedItems: string[],\n unapprovedItems: string[],\n): Status => {\n if (unapprovedItems.includes(item)) return 'unapproved';\n if (approvedItems.includes(item)) return 'approved';\n return 'unknown';\n};\n\n/* #endregion */\n","import React from 'react';\nimport * as TogglePrimitive from '@radix-ui/react-toggle';\nimport { cva, type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst toggleVariants = cva(\n 'pr-twp tw-inline-flex tw-items-center tw-justify-center tw-rounded-md tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-colors hover:tw-bg-muted hover:tw-text-muted-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50 data-[state=on]:tw-bg-accent data-[state=on]:tw-text-accent-foreground',\n {\n variants: {\n variant: {\n default: 'tw-bg-transparent',\n outline:\n 'tw-border tw-border-input tw-bg-transparent hover:tw-bg-accent hover:tw-text-accent-foreground',\n },\n size: {\n default: 'tw-h-10 tw-px-3',\n sm: 'tw-h-9 tw-px-2.5',\n lg: 'tw-h-11 tw-px-5',\n },\n },\n defaultVariants: {\n variant: 'default',\n size: 'default',\n },\n },\n);\n\nconst Toggle = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef & VariantProps\n>(({ className, variant, size, ...props }, ref) => (\n \n));\n\nToggle.displayName = TogglePrimitive.Root.displayName;\n\nexport { Toggle, toggleVariants };\n","import React from 'react';\nimport * as ToggleGroupPrimitive from '@radix-ui/react-toggle-group';\nimport { type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { toggleVariants } from '@/components/shadcn-ui/toggle';\n\nconst ToggleGroupContext = React.createContext>({\n size: 'default',\n variant: 'default',\n});\n\nconst ToggleGroup = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef &\n VariantProps\n>(({ className, variant, size, children, ...props }, ref) => (\n \n \n {children}\n \n \n));\n\nToggleGroup.displayName = ToggleGroupPrimitive.Root.displayName;\n\nconst ToggleGroupItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef &\n VariantProps\n>(({ className, children, variant, size, ...props }, ref) => {\n const context = React.useContext(ToggleGroupContext);\n\n return (\n \n {children}\n \n );\n});\n\nToggleGroupItem.displayName = ToggleGroupPrimitive.Item.displayName;\n\nexport { ToggleGroup, ToggleGroupItem };\n","import { ColumnDef, SortDirection } from '@/components/advanced/data-table/data-table.component';\nimport { Button } from '@/components/shadcn-ui/button';\nimport { ToggleGroup, ToggleGroupItem } from '@/components/shadcn-ui/toggle-group';\nimport {\n ArrowDownIcon,\n ArrowUpDownIcon,\n ArrowUpIcon,\n CircleCheckIcon,\n CircleHelpIcon,\n CircleXIcon,\n} from 'lucide-react';\nimport { ReactNode } from 'react';\nimport { InventoryTableData, Status } from './inventory-utils';\n\n/**\n * Gets an icon that indicates the current sorting direction based on the provided input\n *\n * @param sortDirection Sorting direction. Can be ascending ('asc'), descending ('desc') or false (\n * i.e. not sorted)\n * @returns The appropriate sorting icon for the provided sorting direction\n */\nconst getSortingIcon = (sortDirection: false | SortDirection): ReactNode => {\n if (sortDirection === 'asc') {\n return ;\n }\n if (sortDirection === 'desc') {\n return ;\n }\n return ;\n};\n\n/**\n * Function that creates the item column for inventories\n *\n * @param itemLabel Localized label for the item column (e.g. 'Character', 'Repeated Word', etc.)\n * @returns Column that shows the inventory items. Should be used with the DataTable component\n */\nexport const inventoryItemColumn = (itemLabel: string): ColumnDef => {\n return {\n accessorKey: 'item',\n accessorFn: (row: InventoryTableData) => row.items[0],\n header: ({ column }) => (\n \n ),\n };\n};\n\n/**\n * Function that creates the additional item columns for inventories\n *\n * @param additionalItemLabel Localized label for the additional item column (e.g. 'Preceding\n * Marker')\n * @param additionalItemIndex Index that locates the desired item in the items array of the\n * inventory\n * @returns Column that shows additional inventory items. Should be used with the DataTable\n * component\n */\nexport const inventoryAdditionalItemColumn = (\n additionalItemLabel: string,\n additionalItemIndex: number,\n): ColumnDef => {\n return {\n accessorKey: `item${additionalItemIndex}`,\n accessorFn: (row: InventoryTableData) => row.items[additionalItemIndex],\n header: ({ column }) => (\n \n ),\n };\n};\n\n/**\n * Function that creates the count column for inventories. Should be used with the DataTable\n * component.\n *\n * @param itemLabel Localized label for the count column\n * @returns Column that shows the number of occurrences of the related inventory items\n */\nexport const inventoryCountColumn = (countLabel: string): ColumnDef => {\n return {\n accessorKey: 'count',\n header: ({ column }) => (\n
    \n \n
    \n ),\n cell: ({ row }) =>
    {row.getValue('count')}
    ,\n };\n};\n\n/**\n * Function that updates project settings when status for item(s) changes\n *\n * @param changedItems Array of items for which the status is being updated\n * @param newStatus The status that the items are being given\n * @param approvedItems Array of currently approved items\n * @param onApprovedItemsChange Callback function that stores the updated list of approved items\n * @param unapprovedItems Array of currently unapproved items\n * @param onUnapprovedItemsChange Callback function that stores the updated list of unapproved items\n */\nconst statusChangeHandler = (\n changedItems: string[],\n newStatus: Status,\n approvedItems: string[],\n onApprovedItemsChange: (items: string[]) => void,\n unapprovedItems: string[],\n onUnapprovedItemsChange: (items: string[]) => void,\n) => {\n let newApprovedItems: string[] = [...approvedItems];\n changedItems.forEach((item) => {\n if (newStatus === 'approved') {\n if (!newApprovedItems.includes(item)) {\n newApprovedItems.push(item);\n }\n } else {\n newApprovedItems = newApprovedItems.filter((validItem) => validItem !== item);\n }\n });\n onApprovedItemsChange(newApprovedItems);\n\n let newUnapprovedItems: string[] = [...unapprovedItems];\n changedItems.forEach((item) => {\n if (newStatus === 'unapproved') {\n if (!newUnapprovedItems.includes(item)) {\n newUnapprovedItems.push(item);\n }\n } else {\n newUnapprovedItems = newUnapprovedItems.filter((unapprovedItem) => unapprovedItem !== item);\n }\n });\n onUnapprovedItemsChange(newUnapprovedItems);\n};\n\n/**\n * Function that creates the status column for inventories. Should be used with the DataTable\n * component.\n *\n * @param statusLabel Localized label for the status column\n * @param approvedItems Array of approved items, typically as defined in `Settings.xml`\n * @param onApprovedItemsChange Callback function that stores the updated list of approved items\n * @param unapprovedItems Array of unapproved items, typically as defined in `Settings.xml`\n * @param onUnapprovedItemsChange Callback function that stores the updated list of unapproved items\n * @returns Column that shows the status buttons for the related inventory item. The button for the\n * current status of the item is selected\n */\nexport const inventoryStatusColumn = (\n statusLabel: string,\n approvedItems: string[],\n onApprovedItemsChange: (items: string[]) => void,\n unapprovedItems: string[],\n onUnapprovedItemsChange: (items: string[]) => void,\n): ColumnDef => {\n return {\n accessorKey: 'status',\n header: ({ column }) => {\n return (\n
    \n \n
    \n );\n },\n cell: ({ row }) => {\n const status: Status = row.getValue('status');\n const item: string = row.getValue('item');\n return (\n \n \n statusChangeHandler(\n [item],\n 'approved',\n approvedItems,\n onApprovedItemsChange,\n unapprovedItems,\n onUnapprovedItemsChange,\n )\n }\n value=\"approved\"\n >\n \n \n \n statusChangeHandler(\n [item],\n 'unapproved',\n approvedItems,\n onApprovedItemsChange,\n unapprovedItems,\n onUnapprovedItemsChange,\n )\n }\n value=\"unapproved\"\n >\n \n \n \n statusChangeHandler(\n [item],\n 'unknown',\n approvedItems,\n onApprovedItemsChange,\n unapprovedItems,\n onUnapprovedItemsChange,\n )\n }\n value=\"unknown\"\n >\n \n \n \n );\n },\n };\n};\n","import DataTable, {\n ColumnDef,\n RowContents,\n RowSelectionState,\n TableContents,\n} from '@/components/advanced/data-table/data-table.component';\nimport OccurrencesTable from '@/components/advanced/inventory/occurrences-table.component';\nimport Checkbox from '@/components/shadcn-ui/checkbox';\nimport { Input } from '@/components/shadcn-ui/input';\nimport { Label } from '@/components/shadcn-ui/label';\nimport {\n Select,\n SelectContent,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\nimport {\n deepEqual,\n LocalizedStringValue,\n ScriptureReference,\n substring,\n} from 'platform-bible-utils';\nimport { useEffect, useMemo, useState } from 'react';\nimport {\n getBookNumFromId,\n getLinesFromUSFM,\n getNumberFromUSFM,\n getStatusForItem,\n InventoryItemOccurrence,\n InventoryTableData,\n Status,\n} from './inventory-utils';\nimport { inventoryAdditionalItemColumn } from './inventory-columns';\n\n/**\n * Object containing all keys used for localization in this component. If you're using this\n * component in an extension, you can pass it into the useLocalizedStrings hook to easily obtain the\n * localized strings and pass them into the localizedStrings prop of this component\n */\nexport const INVENTORY_STRING_KEYS = Object.freeze([\n '%webView_inventory_all%',\n '%webView_inventory_approved%',\n '%webView_inventory_unapproved%',\n '%webView_inventory_unknown%',\n '%webView_inventory_scope_currentBook%',\n '%webView_inventory_scope_chapter%',\n '%webView_inventory_scope_verse%',\n '%webView_inventory_filter_text%',\n '%webView_inventory_show_additional_items%',\n '%webView_inventory_occurrences_table_header_reference%',\n '%webView_inventory_occurrences_table_header_occurrence%',\n] as const);\n\nexport type InventoryLocalizedStrings = {\n [localizedInventoryKey in (typeof INVENTORY_STRING_KEYS)[number]]?: LocalizedStringValue;\n};\n\n/** Scope of scripture that the inventory can operate on */\nexport type Scope = 'book' | 'chapter' | 'verse';\n\n/** Status values that the status filter can select from */\ntype StatusFilter = Status | 'all';\n\n/** Text labels for the inventory columns and the control components of additional inventory items */\ntype AdditionalItemsLabels = {\n checkboxText?: string;\n tableHeaders?: string[];\n};\n\n/**\n * Filters data that is shown in the DataTable section of the Inventory\n *\n * @param itemData All inventory items and their related information\n * @param statusFilter Allows filtering by status (i.e. show all items, or only items that are\n * 'approved', 'unapproved' or 'unknown')\n * @param textFilter Allows filtering by text. All items that include the filter text will be\n * selected.\n * @returns Array of items and their related information that are matched by the specified filters\n */\nconst filterItemData = (\n itemData: InventoryTableData[],\n statusFilter: StatusFilter,\n textFilter: string,\n): InventoryTableData[] => {\n let filteredItemData: InventoryTableData[] = itemData;\n\n if (statusFilter !== 'all') {\n filteredItemData = filteredItemData.filter(\n (item) =>\n (statusFilter === 'approved' && item.status === 'approved') ||\n (statusFilter === 'unapproved' && item.status === 'unapproved') ||\n (statusFilter === 'unknown' && item.status === 'unknown'),\n );\n }\n\n if (textFilter !== '')\n filteredItemData = filteredItemData.filter((item) => item.items[0].includes(textFilter));\n\n return filteredItemData;\n};\n\n/**\n * Turns array of strings into array of inventory items, along with their count and status\n *\n * @param text The source scripture text that is searched for inventory items\n * @param scriptureRef The scripture reference that the application is currently set to\n * @param approvedItems Array of approved items, typically as defined in `Settings.xml`\n * @param unapprovedItems Array of unapproved items, typically as defined in `Settings.xml`\n * @param itemRegex Regular expression that describes what items this Inventory should extract from\n * the provided scripture text\n * @returns Array of inventory items, along with their count and status\n */\nconst createTableData = (\n text: string | undefined,\n scriptureRef: ScriptureReference,\n approvedItems: string[],\n unapprovedItems: string[],\n itemRegex: RegExp,\n): InventoryTableData[] => {\n if (!text) return [];\n\n const tableData: InventoryTableData[] = [];\n\n let currentBook: number | undefined = scriptureRef.bookNum;\n let currentChapter: number | undefined = scriptureRef.chapterNum;\n let currentVerse: number | undefined = scriptureRef.verseNum;\n\n const lines = getLinesFromUSFM(text);\n\n lines.forEach((line: string) => {\n if (line.startsWith('\\\\id')) {\n currentBook = getBookNumFromId(line);\n currentChapter = 0;\n currentVerse = 0;\n }\n if (line.startsWith('\\\\c')) {\n currentChapter = getNumberFromUSFM(line);\n currentVerse = 0;\n }\n if (line.startsWith('\\\\v')) {\n currentVerse = getNumberFromUSFM(line);\n if (currentChapter === 0) {\n currentChapter = scriptureRef.chapterNum;\n }\n }\n\n let match: RegExpExecArray | undefined = itemRegex.exec(line) ?? undefined;\n while (match) {\n const items: string[] = [];\n match.forEach((item) => items.push(item));\n const itemIndex = match.index;\n const existingItem = tableData.find((tableEntry) => deepEqual(tableEntry.items, items));\n const newReference: InventoryItemOccurrence = {\n reference: {\n bookNum: currentBook !== undefined ? currentBook : -1,\n chapterNum: currentChapter !== undefined ? currentChapter : -1,\n verseNum: currentVerse !== undefined ? currentVerse : -1,\n },\n text: substring(line, Math.max(0, itemIndex - 25), Math.min(itemIndex + 25, line.length)),\n };\n if (existingItem) {\n existingItem.count += 1;\n existingItem.occurrences.push(newReference);\n } else {\n const newItem: InventoryTableData = {\n items,\n count: 1,\n status: getStatusForItem(items[0], approvedItems, unapprovedItems),\n occurrences: [newReference],\n };\n tableData.push(newItem);\n }\n\n match = itemRegex.exec(line) ?? undefined;\n }\n });\n\n return tableData;\n};\n\n/**\n * Gets the localized value for the provided key\n *\n * @param strings Object containing localized string\n * @param key Key for a localized string\n * @returns The localized value for the provided key, if available. Returns the key if no localized\n * value is available\n */\nconst localizeString = (\n strings: InventoryLocalizedStrings,\n key: keyof InventoryLocalizedStrings,\n) => {\n return strings[key] ?? key;\n};\n\n/** Props for the Inventory component */\ntype InventoryProps = {\n /** The scripture reference that the application is currently set to */\n scriptureReference: ScriptureReference;\n /** Callback function that is executed when the scripture reference is changed */\n setScriptureReference: (scriptureReference: ScriptureReference) => void;\n /**\n * Object with all localized strings that the Inventory needs to work well across multiple\n * languages. When using this component with Platform.Bible, you can import\n * `INVENTORY_STRING_KEYS` from this library, pass it in to the Platform's localization hook, and\n * pass the localized keys that are returned by the hook into this prop.\n */\n localizedStrings: InventoryLocalizedStrings;\n /**\n * The logic that finds the desired items in the source text. This can either be a Regular\n * expression that captures one or multiple items (preferred), or a custom function that builds\n * and return an InventoryDataTable[] manually. Note: In case the logic captures more than one\n * item (i.e. InventoryTableData.items has a length greater than 1), you must provide text labels\n * for the related columns and control elements to show by setting the `additionalItemsLabels`\n * prop\n */\n extractItems:\n | RegExp\n | ((\n text: string | undefined,\n scriptureRef: ScriptureReference,\n approvedItems: string[],\n unapprovedItems: string[],\n ) => InventoryTableData[]);\n /**\n * Text labels for control elements and additional column headers in case your Inventory has more\n * than one item to show (e.g. The 'Preceding Marker' in the Markers Inventory)\n */\n additionalItemsLabels?: AdditionalItemsLabels;\n /** Array of approved items, typically as defined in `Settings.xml` */\n approvedItems: string[];\n /** Array of unapproved items, typically as defined in `Settings.xml` */\n unapprovedItems: string[];\n /** The source scripture text that is searched for in inventory items */\n text: string | undefined;\n /** Scope of scripture that the inventory will operate on */\n scope: Scope;\n /** Callback function that is executed when the scope is changed from the Inventory */\n onScopeChange: (scope: Scope) => void;\n /**\n * Column definitions for the Inventory data table. The most commonly used column definitions are\n * pre-configured for your convenience and can be imported (e.g. inventoryItemColumn,\n * inventoryAdditionalItemColumn inventoryCountColumn, and inventoryStatusColumn). If you need any\n * other columns you can add these yourself\n */\n columns: ColumnDef[];\n};\n\n/** Inventory component that is used to view and control the status of provided project settings */\nexport default function Inventory({\n scriptureReference,\n setScriptureReference,\n localizedStrings,\n extractItems,\n additionalItemsLabels,\n approvedItems,\n unapprovedItems,\n text,\n scope,\n onScopeChange,\n columns,\n}: InventoryProps) {\n const allItemsText = localizeString(localizedStrings, '%webView_inventory_all%');\n const approvedItemsText = localizeString(localizedStrings, '%webView_inventory_approved%');\n const unapprovedItemsText = localizeString(localizedStrings, '%webView_inventory_unapproved%');\n const unknownItemsText = localizeString(localizedStrings, '%webView_inventory_unknown%');\n const scopeBookText = localizeString(localizedStrings, '%webView_inventory_scope_currentBook%');\n const scopeChapterText = localizeString(localizedStrings, '%webView_inventory_scope_chapter%');\n const scopeVerseText = localizeString(localizedStrings, '%webView_inventory_scope_verse%');\n const filterText = localizeString(localizedStrings, '%webView_inventory_filter_text%');\n const showAdditionalItemsText = localizeString(\n localizedStrings,\n '%webView_inventory_show_additional_items%',\n );\n\n const [showAdditionalItems, setShowAdditionalItems] = useState(false);\n const [statusFilter, setStatusFilter] = useState('all');\n const [textFilter, setTextFilter] = useState('');\n const [selectedItem, setSelectedItem] = useState([]);\n\n const tableData: InventoryTableData[] = useMemo(() => {\n if (!text) return [];\n if (extractItems instanceof RegExp)\n return createTableData(\n text,\n scriptureReference,\n approvedItems,\n unapprovedItems,\n extractItems,\n );\n return extractItems(text, scriptureReference, approvedItems, unapprovedItems);\n }, [text, extractItems, scriptureReference, approvedItems, unapprovedItems]);\n\n const reducedTableData: InventoryTableData[] = useMemo(() => {\n if (showAdditionalItems) return tableData;\n\n const newTableData: InventoryTableData[] = [];\n\n tableData.forEach((tableEntry) => {\n const firstItem = tableEntry.items[0];\n\n const existingEntry = newTableData.find(\n (newTableEntry) => newTableEntry.items[0] === firstItem,\n );\n\n if (existingEntry) {\n existingEntry.count += tableEntry.count;\n existingEntry.occurrences = existingEntry.occurrences.concat(tableEntry.occurrences);\n } else {\n newTableData.push({\n items: [firstItem],\n count: tableEntry.count,\n occurrences: tableEntry.occurrences,\n status: tableEntry.status,\n });\n }\n });\n\n return newTableData;\n }, [showAdditionalItems, tableData]);\n\n const filteredTableData: InventoryTableData[] = useMemo(() => {\n return filterItemData(reducedTableData, statusFilter, textFilter);\n }, [reducedTableData, statusFilter, textFilter]);\n\n const allColumns: ColumnDef[] = useMemo(() => {\n if (!showAdditionalItems) return columns;\n\n const numberOfAdditionalItems = additionalItemsLabels?.tableHeaders?.length;\n if (!numberOfAdditionalItems) return columns;\n\n const additionalColumns: ColumnDef[] = [];\n\n for (let index = 0; index < numberOfAdditionalItems; index++) {\n additionalColumns.push(\n inventoryAdditionalItemColumn(\n additionalItemsLabels?.tableHeaders?.[index] || 'Additional Item',\n index + 1,\n ),\n );\n }\n\n return [...additionalColumns, ...columns];\n }, [additionalItemsLabels?.tableHeaders, columns, showAdditionalItems]);\n\n useEffect(() => {\n setSelectedItem([]);\n }, [filteredTableData]);\n\n const rowClickHandler = (\n row: RowContents,\n table: TableContents,\n ) => {\n table.setRowSelection(() => {\n const newSelection: RowSelectionState = {};\n newSelection[row.index] = true;\n return newSelection;\n });\n\n setSelectedItem(row.original.items);\n };\n\n const handleScopeChange = (value: string) => {\n if (value === 'book' || value === 'chapter' || value === 'verse') {\n onScopeChange(value);\n } else {\n throw new Error(`Invalid scope value: ${value}`);\n }\n };\n\n const handleStatusFilterChange = (value: string) => {\n if (value === 'all' || value === 'approved' || value === 'unapproved' || value === 'unknown') {\n setStatusFilter(value);\n } else {\n throw new Error(`Invalid status filter value: ${value}`);\n }\n };\n\n const occurrenceData: InventoryItemOccurrence[] = useMemo(() => {\n if (reducedTableData.length === 0 || selectedItem.length === 0) return [];\n const occurrence = reducedTableData.filter((tableEntry: InventoryTableData) => {\n return deepEqual(\n showAdditionalItems ? tableEntry.items : [tableEntry.items[0]],\n selectedItem,\n );\n });\n if (occurrence.length > 1) throw new Error('Selected item is not unique');\n return occurrence[0].occurrences;\n }, [selectedItem, showAdditionalItems, reducedTableData]);\n\n return (\n
    \n
    \n handleStatusFilterChange(value)}\n defaultValue={statusFilter}\n >\n \n \n \n \n {allItemsText}\n {approvedItemsText}\n {unapprovedItemsText}\n {unknownItemsText}\n \n \n \n {\n setTextFilter(event.target.value);\n }}\n />\n {additionalItemsLabels && (\n
    \n {\n setSelectedItem([]);\n setShowAdditionalItems(checked);\n }}\n />\n \n
    \n )}\n
    \n
    \n \n
    \n {occurrenceData.length > 0 && (\n
    \n \n
    \n )}\n
    \n );\n}\n","import { Input } from '@/components/shadcn-ui/input';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { useState } from 'react';\n\nexport type SearchBarProps = {\n className?: string;\n /**\n * Callback fired to handle the search query when button pressed\n *\n * @param searchQuery\n */\n onSearch: (searchQuery: string) => void;\n\n /** Optional string that appears in the search bar without a search string */\n placeholder?: string;\n\n /** Optional boolean to set the input base to full width */\n isFullWidth?: boolean;\n};\n\nexport default function SearchBar({\n className,\n onSearch,\n placeholder,\n isFullWidth,\n}: SearchBarProps) {\n const [searchQuery, setSearchQuery] = useState('');\n\n const handleInputChange = (searchString: string) => {\n setSearchQuery(searchString);\n onSearch(searchString);\n };\n\n return (\n handleInputChange(e.target.value)}\n />\n );\n}\n","// adapted from: https://github.com/shadcn-ui/ui/discussions/752\n\n'use client';\n\nimport { TabsContentProps, TabsListProps, TabsTriggerProps } from '@/components/shadcn-ui/tabs';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport * as TabsPrimitive from '@radix-ui/react-tabs';\nimport React from 'react';\n\nexport type VerticalTabsProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport type LeftTabsTriggerProps = TabsTriggerProps & {\n value: string;\n ref?: React.Ref;\n};\n\nexport const VerticalTabs = React.forwardRef<\n React.ElementRef,\n VerticalTabsProps\n>(({ className, ...props }, ref) => (\n \n));\n\nVerticalTabs.displayName = TabsPrimitive.List.displayName;\n\nexport const VerticalTabsList = React.forwardRef<\n React.ElementRef,\n TabsListProps\n>(({ className, ...props }, ref) => (\n \n));\nVerticalTabsList.displayName = TabsPrimitive.List.displayName;\n\nexport const VerticalTabsTrigger = React.forwardRef<\n React.ElementRef,\n LeftTabsTriggerProps\n>(({ className, ...props }, ref) => (\n \n));\n\nexport const VerticalTabsContent = React.forwardRef<\n React.ElementRef,\n TabsContentProps\n>(({ className, ...props }, ref) => (\n \n));\nVerticalTabsContent.displayName = TabsPrimitive.Content.displayName;\n","import SearchBar from '@/components/basics/search-bar.component';\nimport {\n VerticalTabs,\n VerticalTabsContent,\n VerticalTabsList,\n VerticalTabsTrigger,\n} from '@/components/basics/tabs-vertical';\nimport { ReactNode } from 'react';\n\nexport type TabKeyValueContent = {\n key: string;\n value: string;\n content: ReactNode;\n};\n\nexport type TabNavigationContentSearchProps = {\n /** List of values and keys for each tab this component should provide */\n tabList: TabKeyValueContent[];\n\n /** Handler to run when the value of the search bar changes */\n onSearch: (searchQuery: string) => void;\n\n /** Optional placeholder for the search bar */\n searchPlaceholder?: string;\n\n /** Optional title to include in the header */\n headerTitle?: string;\n\n /** Optional flag to make the search bar appear full width */\n isSearchBarFullWidth?: boolean;\n\n /** Text direction ltr or rtl */\n direction?: 'ltr' | 'rtl';\n};\n\nexport default function TabNavigationContentSearch({\n tabList,\n onSearch,\n searchPlaceholder,\n headerTitle,\n isSearchBarFullWidth = false,\n direction = 'ltr',\n}: TabNavigationContentSearchProps) {\n return (\n
    \n
    \n {headerTitle ?

    {headerTitle}

    : ''}\n \n
    \n \n \n {tabList.map((tab) => (\n \n {tab.value}\n \n ))}\n \n {tabList.map((tab) => (\n \n {tab.content}\n \n ))}\n \n
    \n );\n}\n","import React from 'react';\nimport * as SeparatorPrimitive from '@radix-ui/react-separator';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Separator = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, orientation = 'horizontal', decorative = true, ...props }, ref) => (\n \n));\nSeparator.displayName = SeparatorPrimitive.Root.displayName;\n\nexport { Separator };\n","'use client';\n\nimport * as React from 'react';\nimport * as SheetPrimitive from '@radix-ui/react-dialog';\nimport { cva, type VariantProps } from 'class-variance-authority';\nimport { X } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Sheet = SheetPrimitive.Root;\n\nconst SheetTrigger = SheetPrimitive.Trigger;\n\nconst SheetClose = SheetPrimitive.Close;\n\nconst SheetPortal = SheetPrimitive.Portal;\n\nconst SheetOverlay = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSheetOverlay.displayName = SheetPrimitive.Overlay.displayName;\n\nconst sheetVariants = cva(\n 'pr-twp tw-fixed tw-z-50 tw-gap-4 tw-bg-background tw-p-6 tw-shadow-lg tw-transition tw-ease-in-out data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-duration-300 data-[state=open]:tw-duration-500',\n {\n variants: {\n side: {\n top: 'tw-inset-x-0 tw-top-0 tw-border-b data-[state=closed]:tw-slide-out-to-top data-[state=open]:tw-slide-in-from-top',\n bottom:\n 'tw-inset-x-0 tw-bottom-0 tw-border-t data-[state=closed]:tw-slide-out-to-bottom data-[state=open]:tw-slide-in-from-bottom',\n left: 'tw-inset-y-0 tw-left-0 tw-h-full tw-w-3/4 tw-border-r data-[state=closed]:tw-slide-out-to-left data-[state=open]:tw-slide-in-from-left sm:tw-max-w-sm',\n right:\n 'tw-inset-y-0 tw-right-0 tw-h-full tw-w-3/4 tw- tw-border-l data-[state=closed]:tw-slide-out-to-right data-[state=open]:tw-slide-in-from-right sm:tw-max-w-sm',\n },\n },\n defaultVariants: {\n side: 'right',\n },\n },\n);\n\ninterface SheetContentProps\n extends React.ComponentPropsWithoutRef,\n VariantProps {}\n\nconst SheetContent = React.forwardRef<\n React.ElementRef,\n SheetContentProps\n>(({ side = 'right', className, children, ...props }, ref) => (\n \n \n \n {children}\n \n \n Close\n \n \n \n));\nSheetContent.displayName = SheetPrimitive.Content.displayName;\n\nfunction SheetHeader({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nSheetHeader.displayName = 'SheetHeader';\n\nfunction SheetFooter({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nSheetFooter.displayName = 'SheetFooter';\n\nconst SheetTitle = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSheetTitle.displayName = SheetPrimitive.Title.displayName;\n\nconst SheetDescription = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSheetDescription.displayName = SheetPrimitive.Description.displayName;\n\nexport {\n Sheet,\n SheetPortal,\n SheetOverlay,\n SheetTrigger,\n SheetClose,\n SheetContent,\n SheetHeader,\n SheetFooter,\n SheetTitle,\n SheetDescription,\n};\n","import React from 'react';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nfunction Skeleton({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\n\nexport { Skeleton };\n","import React from 'react';\nimport * as TooltipPrimitive from '@radix-ui/react-tooltip';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst TooltipProvider = TooltipPrimitive.Provider;\n\nconst Tooltip = TooltipPrimitive.Root;\n\nconst TooltipTrigger = TooltipPrimitive.Trigger;\n\nconst TooltipContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, sideOffset = 4, ...props }, ref) => (\n \n));\nTooltipContent.displayName = TooltipPrimitive.Content.displayName;\n\nexport { Tooltip, TooltipTrigger, TooltipContent, TooltipProvider };\n","import * as React from 'react';\n\nconst MOBILE_BREAKPOINT = 768;\n\nexport default function useIsMobile() {\n const [isMobile, setIsMobile] = React.useState(undefined);\n\n React.useEffect(() => {\n const mql = window.matchMedia(`(max-width: ${MOBILE_BREAKPOINT - 1}px)`);\n const onChange = () => {\n setIsMobile(window.innerWidth < MOBILE_BREAKPOINT);\n };\n mql.addEventListener('change', onChange);\n setIsMobile(window.innerWidth < MOBILE_BREAKPOINT);\n return () => mql.removeEventListener('change', onChange);\n }, []);\n\n return !!isMobile;\n}\n","import React from 'react';\nimport { Slot } from '@radix-ui/react-slot';\nimport { VariantProps, cva } from 'class-variance-authority';\nimport { PanelLeft } from 'lucide-react';\n\nimport { Button } from '@/components/shadcn-ui/button';\nimport { Input } from '@/components/shadcn-ui/input';\nimport { Separator } from '@/components/shadcn-ui/separator';\nimport { Sheet, SheetContent } from '@/components/shadcn-ui/sheet';\nimport { Skeleton } from '@/components/shadcn-ui/skeleton';\nimport {\n Tooltip,\n TooltipContent,\n TooltipProvider,\n TooltipTrigger,\n} from '@/components/shadcn-ui/tooltip';\nimport useIsMobile from '@/components/hooks/use-mobile';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst SIDEBAR_COOKIE_NAME = 'sidebar:state';\nconst SIDEBAR_COOKIE_MAX_AGE = 60 * 60 * 24 * 7;\nconst SIDEBAR_WIDTH = '16rem';\nconst SIDEBAR_WIDTH_MOBILE = '18rem';\nconst SIDEBAR_WIDTH_ICON = '3rem';\nconst SIDEBAR_KEYBOARD_SHORTCUT = 'b';\n\ntype SidebarContextProps = {\n state: 'expanded' | 'collapsed';\n open: boolean;\n setOpen: (open: boolean) => void;\n openMobile: boolean;\n setOpenMobile: (open: boolean) => void;\n isMobile: boolean;\n toggleSidebar: () => void;\n};\n\nconst SidebarContext = React.createContext(undefined);\n\nfunction useSidebar() {\n const context = React.useContext(SidebarContext);\n if (!context) {\n throw new Error('useSidebar must be used within a SidebarProvider.');\n }\n\n return context;\n}\n\nconst SidebarProvider = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & {\n defaultOpen?: boolean;\n open?: boolean;\n onOpenChange?: (open: boolean) => void;\n }\n>(\n (\n {\n defaultOpen = true,\n open: openProp,\n onOpenChange: setOpenProp,\n className,\n style,\n children,\n ...props\n },\n ref,\n ) => {\n const isMobile = useIsMobile();\n const [openMobile, setOpenMobile] = React.useState(false);\n\n // This is the internal state of the sidebar.\n // We use openProp and setOpenProp for control from outside the component.\n const [_open, _setOpen] = React.useState(defaultOpen);\n const isOpen = openProp ?? _open;\n const setOpen = React.useCallback(\n (value: boolean | ((value: boolean) => boolean)) => {\n const openState = typeof value === 'function' ? value(isOpen) : value;\n if (setOpenProp) {\n setOpenProp(openState);\n } else {\n _setOpen(openState);\n }\n\n // This sets the cookie to keep the sidebar state.\n document.cookie = `${SIDEBAR_COOKIE_NAME}=${openState}; path=/; max-age=${SIDEBAR_COOKIE_MAX_AGE}`;\n },\n [setOpenProp, isOpen],\n );\n\n // Helper to toggle the sidebar.\n const toggleSidebar = React.useCallback(() => {\n return isMobile ? setOpenMobile((open) => !open) : setOpen((open) => !open);\n }, [isMobile, setOpen, setOpenMobile]);\n\n // Adds a keyboard shortcut to toggle the sidebar.\n React.useEffect(() => {\n const handleKeyDown = (event: KeyboardEvent) => {\n if (event.key === SIDEBAR_KEYBOARD_SHORTCUT && (event.metaKey || event.ctrlKey)) {\n event.preventDefault();\n toggleSidebar();\n }\n };\n\n window.addEventListener('keydown', handleKeyDown);\n return () => window.removeEventListener('keydown', handleKeyDown);\n }, [toggleSidebar]);\n\n // We add a state so that we can do data-state=\"expanded\" or \"collapsed\".\n // This makes it easier to style the sidebar with Tailwind classes.\n const state = isOpen ? 'expanded' : 'collapsed';\n\n const contextValue = React.useMemo(\n () => ({\n state,\n open: isOpen,\n setOpen,\n isMobile,\n openMobile,\n setOpenMobile,\n toggleSidebar,\n }),\n [state, isOpen, setOpen, isMobile, openMobile, setOpenMobile, toggleSidebar],\n );\n\n return (\n \n \n \n {children}\n
    \n \n \n );\n },\n);\nSidebarProvider.displayName = 'SidebarProvider';\n\nconst Sidebar = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & {\n side?: 'left' | 'right';\n variant?: 'sidebar' | 'floating' | 'inset';\n collapsible?: 'offcanvas' | 'icon' | 'none';\n }\n>(\n (\n {\n side = 'left',\n variant = 'sidebar',\n collapsible = 'offcanvas',\n className,\n children,\n ...props\n },\n ref,\n ) => {\n const { isMobile, state, openMobile, setOpenMobile } = useSidebar();\n\n if (collapsible === 'none') {\n return (\n \n {children}\n
    \n );\n }\n\n if (isMobile) {\n return (\n \n button]:tw-hidden\"\n style={\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n {\n '--sidebar-width': SIDEBAR_WIDTH_MOBILE,\n } as React.CSSProperties\n }\n side={side}\n >\n
    {children}
    \n \n
    \n );\n }\n\n return (\n \n {/* This is what handles the sidebar gap on desktop */}\n \n \n \n {children}\n
    \n
    \n
    \n );\n },\n);\nSidebar.displayName = 'Sidebar';\n\nconst SidebarTrigger = React.forwardRef<\n React.ElementRef,\n React.ComponentProps\n>(({ className, onClick, ...props }, ref) => {\n const { toggleSidebar } = useSidebar();\n\n return (\n {\n onClick?.(event);\n toggleSidebar();\n }}\n {...props}\n >\n \n Toggle Sidebar\n \n );\n});\nSidebarTrigger.displayName = 'SidebarTrigger';\n\nconst SidebarRail = React.forwardRef>(\n ({ className, ...props }, ref) => {\n const { toggleSidebar } = useSidebar();\n\n return (\n \n );\n },\n);\nSidebarRail.displayName = 'SidebarRail';\n\nconst SidebarInset = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarInset.displayName = 'SidebarInset';\n\nconst SidebarInput = React.forwardRef<\n React.ElementRef,\n React.ComponentProps\n>(({ className, ...props }, ref) => {\n return (\n \n );\n});\nSidebarInput.displayName = 'SidebarInput';\n\nconst SidebarHeader = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarHeader.displayName = 'SidebarHeader';\n\nconst SidebarFooter = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarFooter.displayName = 'SidebarFooter';\n\nconst SidebarSeparator = React.forwardRef<\n React.ElementRef,\n React.ComponentProps\n>(({ className, ...props }, ref) => {\n return (\n \n );\n});\nSidebarSeparator.displayName = 'SidebarSeparator';\n\nconst SidebarContent = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarContent.displayName = 'SidebarContent';\n\nconst SidebarGroup = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarGroup.displayName = 'SidebarGroup';\n\nconst SidebarGroupLabel = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & { asChild?: boolean }\n>(({ className, asChild = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'div';\n\n return (\n svg]:tw-size-4 [&>svg]:tw-shrink-0',\n 'group-data-[collapsible=icon]:tw--mt-8 group-data-[collapsible=icon]:tw-opacity-0',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarGroupLabel.displayName = 'SidebarGroupLabel';\n\nconst SidebarGroupAction = React.forwardRef<\n HTMLButtonElement,\n React.ComponentProps<'button'> & { asChild?: boolean }\n>(({ className, asChild = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'button';\n\n return (\n svg]:tw-size-4 [&>svg]:tw-shrink-0',\n // Increases the hit area of the button on mobile.\n 'after:tw-absolute after:tw--inset-2 after:md:tw-hidden',\n 'group-data-[collapsible=icon]:tw-hidden',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarGroupAction.displayName = 'SidebarGroupAction';\n\nconst SidebarGroupContent = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarGroupContent.displayName = 'SidebarGroupContent';\n\nconst SidebarMenu = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenu.displayName = 'SidebarMenu';\n\nconst SidebarMenuItem = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenuItem.displayName = 'SidebarMenuItem';\n\nconst sidebarMenuButtonVariants = cva(\n // Removed data-[active=true]:tw-bg-sidebar-accent\n 'tw-peer/menu-button tw-flex tw-w-full tw-items-center tw-gap-2 tw-overflow-hidden tw-rounded-md tw-p-2 tw-text-left tw-text-sm tw-outline-none tw-ring-sidebar-ring tw-transition-[width,height,padding] hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground focus-visible:tw-ring-2 active:tw-bg-sidebar-accent active:tw-text-sidebar-accent-foreground disabled:tw-pointer-events-none disabled:tw-opacity-50 tw-group-has-[[data-sidebar=menu-action]]/menu-item:pr-8 aria-disabled:tw-pointer-events-none aria-disabled:tw-opacity-50 data-[active=true]:tw-font-medium data-[active=true]:tw-text-sidebar-accent-foreground data-[state=open]:hover:tw-bg-sidebar-accent data-[state=open]:hover:tw-text-sidebar-accent-foreground group-data-[collapsible=icon]:tw-!size-8 group-data-[collapsible=icon]:tw-!p-2 [&>span:last-child]:tw-truncate [&>svg]:tw-size-4 [&>svg]:tw-shrink-0',\n {\n variants: {\n variant: {\n default: 'hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground',\n outline:\n 'tw-bg-background tw-shadow-[0_0_0_1px_hsl(var(--sidebar-border))] hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground hover:tw-shadow-[0_0_0_1px_hsl(var(--sidebar-accent))]',\n },\n size: {\n default: 'tw-h-8 tw-text-sm',\n sm: 'tw-h-7 tw-text-xs',\n lg: 'tw-h-12 tw-text-sm group-data-[collapsible=icon]:tw-!p-0',\n },\n },\n defaultVariants: {\n variant: 'default',\n size: 'default',\n },\n },\n);\n\nconst SidebarMenuButton = React.forwardRef<\n HTMLButtonElement,\n React.ComponentProps<'button'> & {\n asChild?: boolean;\n isActive?: boolean;\n tooltip?: string | React.ComponentProps;\n } & VariantProps\n>(\n (\n {\n asChild = false,\n isActive = false,\n variant = 'default',\n size = 'default',\n tooltip,\n className,\n ...props\n },\n ref,\n ) => {\n const Comp = asChild ? Slot : 'button';\n const { isMobile, state } = useSidebar();\n\n const button = (\n \n );\n\n if (!tooltip) {\n return button;\n }\n\n if (typeof tooltip === 'string') {\n // eslint-disable-next-line no-param-reassign\n tooltip = {\n children: tooltip,\n };\n }\n\n return (\n \n {button}\n \n );\n },\n);\nSidebarMenuButton.displayName = 'SidebarMenuButton';\n\nconst SidebarMenuAction = React.forwardRef<\n HTMLButtonElement,\n React.ComponentProps<'button'> & {\n asChild?: boolean;\n showOnHover?: boolean;\n }\n>(({ className, asChild = false, showOnHover = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'button';\n\n return (\n svg]:tw-size-4 [&>svg]:tw-shrink-0',\n // Increases the hit area of the button on mobile.\n 'after:tw-absolute after:tw--inset-2 after:md:tw-hidden',\n 'tw-peer-data-[size=sm]/menu-button:top-1',\n 'tw-peer-data-[size=default]/menu-button:top-1.5',\n 'tw-peer-data-[size=lg]/menu-button:top-2.5',\n 'group-data-[collapsible=icon]:tw-hidden',\n showOnHover &&\n 'tw-group-focus-within/menu-item:opacity-100 tw-group-hover/menu-item:opacity-100 tw-peer-data-[active=true]/menu-button:text-sidebar-accent-foreground data-[state=open]:tw-opacity-100 md:tw-opacity-0',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarMenuAction.displayName = 'SidebarMenuAction';\n\nconst SidebarMenuBadge = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenuBadge.displayName = 'SidebarMenuBadge';\n\nconst SidebarMenuSkeleton = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & {\n showIcon?: boolean;\n }\n>(({ className, showIcon = false, ...props }, ref) => {\n // Random width between 50 to 90%.\n const width = React.useMemo(() => {\n return `${Math.floor(Math.random() * 40) + 50}%`;\n }, []);\n\n return (\n \n {showIcon && (\n \n )}\n \n
    \n );\n});\nSidebarMenuSkeleton.displayName = 'SidebarMenuSkeleton';\n\nconst SidebarMenuSub = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenuSub.displayName = 'SidebarMenuSub';\n\nconst SidebarMenuSubItem = React.forwardRef>(\n ({ ...props }, ref) =>
  • ,\n);\nSidebarMenuSubItem.displayName = 'SidebarMenuSubItem';\n\nconst SidebarMenuSubButton = React.forwardRef<\n HTMLAnchorElement,\n React.ComponentProps<'a'> & {\n asChild?: boolean;\n size?: 'sm' | 'md';\n isActive?: boolean;\n }\n>(({ asChild = false, size = 'md', isActive, className, ...props }, ref) => {\n const Comp = asChild ? Slot : 'a';\n\n return (\n span:last-child]:tw-truncate [&>svg]:tw-size-4 [&>svg]:tw-shrink-0 [&>svg]:tw-text-sidebar-accent-foreground',\n 'data-[active=true]:tw-bg-sidebar-accent data-[active=true]:tw-text-sidebar-accent-foreground',\n size === 'sm' && 'tw-text-xs',\n size === 'md' && 'tw-text-sm',\n 'group-data-[collapsible=icon]:tw-hidden',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarMenuSubButton.displayName = 'SidebarMenuSubButton';\n\nexport {\n Sidebar,\n SidebarContent,\n SidebarFooter,\n SidebarGroup,\n SidebarGroupAction,\n SidebarGroupContent,\n SidebarGroupLabel,\n SidebarHeader,\n SidebarInput,\n SidebarInset,\n SidebarMenu,\n SidebarMenuAction,\n SidebarMenuBadge,\n SidebarMenuButton,\n SidebarMenuItem,\n SidebarMenuSkeleton,\n SidebarMenuSub,\n SidebarMenuSubButton,\n SidebarMenuSubItem,\n SidebarProvider,\n SidebarRail,\n SidebarSeparator,\n SidebarTrigger,\n useSidebar,\n};\n","import ComboBox, { ComboBoxOption } from '@/components/basics/combo-box.component';\nimport {\n Sidebar,\n SidebarContent,\n SidebarGroup,\n SidebarGroupLabel,\n SidebarGroupContent,\n SidebarMenu,\n SidebarMenuItem,\n SidebarMenuButton,\n} from '@/components/shadcn-ui/sidebar';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { useCallback } from 'react';\n\nexport type SelectedSettingsSidebarItem = {\n label: string;\n projectId?: string;\n};\n\nexport type ProjectOptions = { projectId: string; projectName: string };\n\nexport type SettingsSidebarProps = {\n /** Optional id for testing */\n id?: string;\n\n /** Extension labels from contribution */\n extensionLabels: string[];\n\n /** Project names and ids */\n projectOptions: ProjectOptions[];\n\n /** Handler for selecting a sidebar item */\n handleSelectSidebarItem: (key: string, projectId?: string) => void;\n\n /** The current selected value in the sidebar */\n selectedSidebarItem: SelectedSettingsSidebarItem;\n\n /** Label for the group of extensions setting groups */\n extensionsSidebarGroupLabel: string;\n\n /** Label for the group of projects settings */\n projectsSidebarGroupLabel: string;\n};\n\nexport default function SettingsSidebar({\n id,\n extensionLabels,\n projectOptions,\n handleSelectSidebarItem,\n selectedSidebarItem,\n extensionsSidebarGroupLabel,\n projectsSidebarGroupLabel,\n}: SettingsSidebarProps) {\n const handleSelectItem = useCallback(\n (item: string, projectId?: string) => {\n handleSelectSidebarItem(item, projectId);\n },\n [handleSelectSidebarItem],\n );\n\n const getProjectNameFromProjectId = useCallback(\n (projectId: string) => {\n const project = projectOptions.find((option) => option.projectId === projectId);\n return project ? project.projectName : projectId;\n },\n [projectOptions],\n );\n\n const getIsActive: (label: string) => boolean = useCallback(\n (label: string) => !selectedSidebarItem.projectId && label === selectedSidebarItem.label,\n [selectedSidebarItem],\n );\n\n return (\n \n \n \n \n {extensionsSidebarGroupLabel}\n \n \n \n {extensionLabels.map((label) => (\n \n handleSelectItem(label, undefined)}\n isActive={getIsActive(label)}\n >\n {label}\n \n \n ))}\n \n \n \n \n \n {projectsSidebarGroupLabel}\n \n \n option.projectId)}\n getOptionLabel={(projectId: ComboBoxOption) => {\n // This function expects a ComboBoxOption, but we know it is a string\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n return getProjectNameFromProjectId(projectId as string);\n }}\n buttonPlaceholder=\"Type or select project\"\n onChange={(projectId: string) => {\n const selectedProjectName = getProjectNameFromProjectId(projectId);\n handleSelectItem(selectedProjectName, projectId);\n }}\n value={selectedSidebarItem?.projectId ?? undefined}\n />\n \n \n \n \n );\n}\n","import { SidebarInset, SidebarProvider } from '@/components/shadcn-ui/sidebar';\nimport { PropsWithChildren } from 'react';\nimport SearchBar from '@/components/basics/search-bar.component';\nimport SettingsSidebar, { SettingsSidebarProps } from './settings-sidebar.component';\n\nexport type SettingsSidebarContentSearchProps = SettingsSidebarProps &\n PropsWithChildren & {\n /** Optional id for testing */\n id?: string;\n\n /** Text direction ltr or rtl */\n direction?: 'ltr' | 'rtl';\n\n /** Handler to run when the value of the search bar changes */\n onSearch: (searchQuery: string) => void;\n };\n\nexport default function SettingsSidebarContentSearch({\n id,\n direction = 'ltr',\n extensionLabels,\n projectOptions,\n children,\n handleSelectSidebarItem,\n selectedSidebarItem,\n onSearch,\n extensionsSidebarGroupLabel,\n projectsSidebarGroupLabel,\n}: SettingsSidebarContentSearchProps) {\n return (\n
    \n
    \n \n
    \n \n \n {children}\n \n
    \n );\n}\n","import { Button } from '@/components/shadcn-ui/button';\nimport {\n Select,\n SelectContent,\n SelectGroup,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\nimport {\n Table,\n TableBody,\n TableCell,\n TableHead,\n TableHeader,\n TableRow,\n} from '@/components/shadcn-ui/table';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Canon } from '@sillsdev/scripture';\nimport {\n Cell,\n ColumnDef,\n flexRender,\n getCoreRowModel,\n getExpandedRowModel,\n getGroupedRowModel,\n getSortedRowModel,\n GroupingState,\n Row,\n RowSelectionState,\n SortingState,\n useReactTable,\n} from '@tanstack/react-table';\nimport '@/components/advanced/scripture-results-viewer/scripture-results-viewer.component.css';\nimport {\n compareScrRefs,\n formatScrRef,\n ScriptureSelection,\n scrRefToBBBCCCVVV,\n} from 'platform-bible-utils';\nimport { MouseEvent, useEffect, useMemo, useState } from 'react';\nimport { ChevronDown, ChevronLeft, ChevronRight } from 'lucide-react';\n\n/**\n * Information (e.g., a checking error or some other type of \"transient\" annotation) about something\n * noteworthy at a specific place in an instance of the Scriptures.\n */\nexport type ScriptureItemDetail = ScriptureSelection & {\n /**\n * Text of the error, note, etc. In the future, we might want to support something more than just\n * text so that a JSX element could be provided with a link or some other controls related to the\n * issue being reported.\n */\n detail: string;\n};\n\n/**\n * A uniquely identifiable source of results that can be displayed in the ScriptureResultsViewer.\n * Generally, the source will be a particular Scripture check, but there may be other types of\n * sources.\n */\nexport type ResultsSource = {\n /**\n * Uniquely identifies the source.\n *\n * @type {string}\n */\n id: string;\n\n /**\n * Name (potentially localized) of the source, suitable for display in the UI.\n *\n * @type {string}\n */\n displayName: string;\n};\n\nexport type ScriptureSrcItemDetail = ScriptureItemDetail & {\n /** Source/type of detail. Can be used for grouping. */\n source: ResultsSource;\n};\n\n/**\n * Represents a set of results keyed by Scripture reference. Generally, the source will be a\n * particular Scripture check, but this type also allows for other types of uniquely identifiable\n * sources.\n */\nexport type ResultsSet = {\n /**\n * The backing source associated with this set of results.\n *\n * @type {ResultsSource}\n */\n source: ResultsSource;\n\n /**\n * Array of Scripture item details (messages keyed by Scripture reference).\n *\n * @type {ScriptureItemDetail[]}\n */\n data: ScriptureItemDetail[];\n};\n\nconst scrBookColId = 'scrBook';\nconst scrRefColId = 'scrRef';\nconst typeColId = 'source';\nconst detailsColId = 'details';\n\nconst defaultScrRefColumnName = 'Scripture Reference';\nconst defaultScrBookGroupName = 'Scripture Book';\nconst defaultTypeColumnName = 'Type';\nconst defaultDetailsColumnName = 'Details';\n\nexport type ScriptureResultsViewerColumnInfo = {\n /** Optional header to display for the Reference column. Default value: 'Scripture Reference'. */\n scriptureReferenceColumnName?: string;\n\n /** Optional text to display to refer to the Scripture book group. Default value: 'Scripture Book'. */\n scriptureBookGroupName?: string;\n\n /** Optional header to display for the Type column. Default value: 'Type'. */\n typeColumnName?: string;\n\n /** Optional header to display for the Details column. Default value: 'Details' */\n detailsColumnName?: string;\n};\n\nexport type ScriptureResultsViewerProps = ScriptureResultsViewerColumnInfo & {\n /** Groups of ScriptureItemDetail objects from particular sources (e.g., Scripture checks) */\n sources: ResultsSet[];\n\n /** Flag indicating whether to display column headers. Default is false. */\n showColumnHeaders?: boolean;\n\n /** Flag indicating whether to display source column. Default is false. */\n showSourceColumn?: boolean;\n\n /** Callback function to notify when a row is selected */\n onRowSelected?: (selectedRow: ScriptureSrcItemDetail | undefined) => void;\n\n /** Text direction ltr or rtl */\n direction?: 'ltr' | 'rtl';\n};\n\nfunction getColumns(\n colInfo?: ScriptureResultsViewerColumnInfo,\n showSourceColumn?: boolean,\n): ColumnDef[] {\n const showSrcCol = showSourceColumn ?? false;\n return [\n {\n accessorFn: (row) =>\n `${Canon.bookNumberToId(row.start.bookNum)} ${row.start.chapterNum}:${row.start.verseNum}`,\n id: scrBookColId,\n header: colInfo?.scriptureReferenceColumnName ?? defaultScrRefColumnName,\n cell: (info) => {\n const row = info.row.original;\n if (info.row.getIsGrouped()) {\n return Canon.bookNumberToEnglishName(row.start.bookNum);\n }\n return info.row.groupingColumnId === scrBookColId ? formatScrRef(row.start) : undefined;\n },\n getGroupingValue: (row) => row.start.bookNum,\n sortingFn: (a, b) => {\n return compareScrRefs(a.original.start, b.original.start);\n },\n enableGrouping: true,\n },\n {\n accessorFn: (row) => formatScrRef(row.start),\n id: scrRefColId,\n header: undefined,\n cell: (info) => {\n const row = info.row.original;\n return info.row.getIsGrouped() ? undefined : formatScrRef(row.start);\n },\n sortingFn: (a, b) => {\n return compareScrRefs(a.original.start, b.original.start);\n },\n enableGrouping: false,\n },\n {\n accessorFn: (row) => row.source.displayName,\n id: typeColId,\n header: showSrcCol ? (colInfo?.typeColumnName ?? defaultTypeColumnName) : undefined,\n cell: (info) => (showSrcCol || info.row.getIsGrouped() ? info.getValue() : undefined),\n getGroupingValue: (row) => row.source.id,\n sortingFn: (a, b) =>\n a.original.source.displayName.localeCompare(b.original.source.displayName),\n enableGrouping: true,\n },\n {\n accessorFn: (row) => row.detail,\n id: detailsColId,\n header: colInfo?.detailsColumnName ?? defaultDetailsColumnName,\n cell: (info) => info.getValue(),\n enableGrouping: false,\n },\n ];\n}\n\nconst toRefOrRange = (scriptureSelection: ScriptureSelection) => {\n if (!('offset' in scriptureSelection.start))\n throw new Error('No offset available in range start');\n if (scriptureSelection.end && !('offset' in scriptureSelection.end))\n throw new Error('No offset available in range end');\n const { offset: offsetStart } = scriptureSelection.start;\n let offsetEnd: number = 0;\n if (scriptureSelection.end) ({ offset: offsetEnd } = scriptureSelection.end);\n if (\n !scriptureSelection.end ||\n compareScrRefs(scriptureSelection.start, scriptureSelection.end) === 0\n )\n return `${scrRefToBBBCCCVVV(scriptureSelection.start)}+${offsetStart}`;\n return `${scrRefToBBBCCCVVV(scriptureSelection.start)}+${offsetStart}-${scrRefToBBBCCCVVV(scriptureSelection.end)}+${offsetEnd}`;\n};\n\nconst getRowKey = (row: ScriptureSrcItemDetail) =>\n `${toRefOrRange({ start: row.start, end: row.end })} ${row.source.displayName} ${row.detail}`;\n\n/**\n * Component to display a combined list of detailed items from one or more sources, where the items\n * are keyed primarily by Scripture reference. This is particularly useful for displaying a list of\n * results from Scripture checks, but more generally could be used to display any \"results\" from any\n * source(s). The component allows for grouping by Scripture book, source, or both. By default, it\n * displays somewhat \"tree-like\" which allows it to be more horizontally compact and intuitive. But\n * it also has the option of displaying as a traditional table with column headings (with or without\n * the source column showing).\n */\nexport default function ScriptureResultsViewer({\n sources,\n showColumnHeaders = false,\n showSourceColumn = false,\n scriptureReferenceColumnName,\n scriptureBookGroupName,\n typeColumnName,\n detailsColumnName,\n onRowSelected,\n direction = 'ltr',\n}: ScriptureResultsViewerProps) {\n const [grouping, setGrouping] = useState([]);\n const [sorting, setSorting] = useState([{ id: scrBookColId, desc: false }]);\n const [rowSelection, setRowSelection] = useState({});\n\n const scriptureResults = useMemo(\n () =>\n sources.flatMap((source) => {\n return source.data.map((item) => ({\n ...item,\n source: source.source,\n }));\n }),\n [sources],\n );\n\n const columns = useMemo(\n () =>\n getColumns(\n {\n scriptureReferenceColumnName,\n typeColumnName,\n detailsColumnName,\n },\n showSourceColumn,\n ),\n [scriptureReferenceColumnName, typeColumnName, detailsColumnName, showSourceColumn],\n );\n\n useEffect(() => {\n // Ensure sorting is applied correctly when grouped by type\n if (grouping.includes(typeColId)) {\n setSorting([\n { id: typeColId, desc: false },\n { id: scrBookColId, desc: false },\n ]);\n } else {\n setSorting([{ id: scrBookColId, desc: false }]);\n }\n }, [grouping]);\n\n const table = useReactTable({\n data: scriptureResults,\n columns,\n state: {\n grouping,\n sorting,\n rowSelection,\n },\n onGroupingChange: setGrouping,\n onSortingChange: setSorting,\n onRowSelectionChange: setRowSelection,\n getExpandedRowModel: getExpandedRowModel(),\n getGroupedRowModel: getGroupedRowModel(),\n getCoreRowModel: getCoreRowModel(),\n getSortedRowModel: getSortedRowModel(),\n getRowId: getRowKey,\n autoResetExpanded: false,\n enableMultiRowSelection: false,\n enableSubRowSelection: false,\n });\n\n useEffect(() => {\n if (onRowSelected) {\n const selectedRows = table.getSelectedRowModel().rowsById;\n const keys = Object.keys(selectedRows);\n if (keys.length === 1) {\n const selectedRow = scriptureResults.find((row) => getRowKey(row) === keys[0]) || undefined;\n if (selectedRow) onRowSelected(selectedRow);\n }\n }\n }, [rowSelection, scriptureResults, onRowSelected, table]);\n\n // Define possible grouping options\n const scrBookGroupName = scriptureBookGroupName ?? defaultScrBookGroupName;\n const typeGroupName = typeColumnName ?? defaultTypeColumnName;\n\n const groupingOptions = [\n { label: 'No Grouping', value: [] },\n { label: `Group by ${scrBookGroupName}`, value: [scrBookColId] },\n { label: `Group by ${typeGroupName}`, value: [typeColId] },\n {\n label: `Group by ${scrBookGroupName} and ${typeGroupName}`,\n value: [scrBookColId, typeColId],\n },\n {\n label: `Group by ${typeGroupName} and ${scrBookGroupName}`,\n value: [typeColId, scrBookColId],\n },\n ];\n\n const handleSelectChange = (selectedGrouping: string) => {\n setGrouping(JSON.parse(selectedGrouping));\n };\n\n const handleRowClick = (row: Row, event: MouseEvent) => {\n if (!row.getIsGrouped() && !row.getIsSelected()) {\n row.getToggleSelectedHandler()(event);\n }\n };\n\n const getEvenOrOddBandingStyle = (row: Row, index: number) => {\n if (row.getIsGrouped()) return '';\n // UX has now said they don't think they want banding. I'm leaving in the code to\n // set even and odd styles, but there's nothing in the CSS to style them differently.\n // The \"even\" style used to also have tw-bg-neutral-300 (along with even) to create\n // a visual banding effect. That could be added back in if UX changes the decision.\n return cn('banded-row', index % 2 === 0 ? 'even' : 'odd');\n };\n\n const getIndent = (\n groupingState: GroupingState,\n row: Row,\n cell: Cell,\n ) => {\n if (groupingState?.length === 0 || row.depth < cell.column.getGroupedIndex()) return undefined;\n if (row.getIsGrouped()) {\n switch (row.depth) {\n case 1:\n return 'tw-ps-4';\n default:\n return undefined;\n }\n }\n switch (row.depth) {\n case 1:\n return 'tw-ps-8';\n case 2:\n return 'tw-ps-12';\n default:\n return undefined;\n }\n };\n\n return (\n
    \n {!showColumnHeaders && (\n {\n handleSelectChange(value);\n }}\n >\n \n \n \n \n \n {groupingOptions.map((option) => (\n \n {option.label}\n \n ))}\n \n \n \n )}\n \n {showColumnHeaders && (\n \n {table.getHeaderGroups().map((headerGroup) => (\n \n {headerGroup.headers\n .filter((h) => h.column.columnDef.header)\n .map((header) => (\n /* For sticky column headers to work, we probably need to change the default definition of the shadcn Table component. See https://github.com/shadcn-ui/ui/issues/1151 */\n \n {header.isPlaceholder ? undefined : (\n
    \n {header.column.getCanGroup() ? (\n \n {header.column.getIsGrouped() ? `🛑` : `👊 `}\n \n ) : undefined}{' '}\n {flexRender(header.column.columnDef.header, header.getContext())}\n
    \n )}\n
    \n ))}\n
    \n ))}\n
    \n )}\n \n {table.getRowModel().rows.map((row, rowIndex) => {\n return (\n handleRowClick(row, event)}\n >\n {row.getVisibleCells().map((cell) => {\n if (\n cell.getIsPlaceholder() ||\n (cell.column.columnDef.enableGrouping &&\n !cell.getIsGrouped() &&\n (cell.column.columnDef.id !== typeColId || !showSourceColumn))\n )\n return undefined;\n return (\n \n {(() => {\n if (cell.getIsGrouped()) {\n return (\n \n {row.getIsExpanded() && }\n {!row.getIsExpanded() &&\n (direction === 'ltr' ? : )}{' '}\n {flexRender(cell.column.columnDef.cell, cell.getContext())} (\n {row.subRows.length})\n \n );\n }\n\n // if (cell.getIsAggregated()) {\n // flexRender(\n // cell.column.columnDef.aggregatedCell ?? cell.column.columnDef.cell,\n // cell.getContext(),\n // );\n // }\n\n return flexRender(cell.column.columnDef.cell, cell.getContext());\n })()}\n \n );\n })}\n \n );\n })}\n \n
    \n
    \n );\n}\n","import {\n getLocalizeKeyForScrollGroupId,\n LanguageStrings,\n ScrollGroupId,\n} from 'platform-bible-utils';\nimport {\n Select,\n SelectContent,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\n\nconst DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS = {\n [getLocalizeKeyForScrollGroupId('undefined')]: 'Ø',\n [getLocalizeKeyForScrollGroupId(0)]: 'A',\n [getLocalizeKeyForScrollGroupId(1)]: 'B',\n [getLocalizeKeyForScrollGroupId(2)]: 'C',\n [getLocalizeKeyForScrollGroupId(3)]: 'D',\n [getLocalizeKeyForScrollGroupId(4)]: 'E',\n [getLocalizeKeyForScrollGroupId(5)]: 'F',\n [getLocalizeKeyForScrollGroupId(6)]: 'G',\n [getLocalizeKeyForScrollGroupId(7)]: 'H',\n [getLocalizeKeyForScrollGroupId(8)]: 'I',\n [getLocalizeKeyForScrollGroupId(9)]: 'J',\n [getLocalizeKeyForScrollGroupId(10)]: 'K',\n [getLocalizeKeyForScrollGroupId(11)]: 'L',\n [getLocalizeKeyForScrollGroupId(12)]: 'M',\n [getLocalizeKeyForScrollGroupId(13)]: 'N',\n [getLocalizeKeyForScrollGroupId(14)]: 'O',\n [getLocalizeKeyForScrollGroupId(15)]: 'P',\n [getLocalizeKeyForScrollGroupId(16)]: 'Q',\n [getLocalizeKeyForScrollGroupId(17)]: 'R',\n [getLocalizeKeyForScrollGroupId(18)]: 'S',\n [getLocalizeKeyForScrollGroupId(19)]: 'T',\n [getLocalizeKeyForScrollGroupId(20)]: 'U',\n [getLocalizeKeyForScrollGroupId(21)]: 'V',\n [getLocalizeKeyForScrollGroupId(22)]: 'W',\n [getLocalizeKeyForScrollGroupId(23)]: 'X',\n [getLocalizeKeyForScrollGroupId(24)]: 'Y',\n [getLocalizeKeyForScrollGroupId(25)]: 'Z',\n};\n\nexport type ScrollGroupSelectorProps = {\n /**\n * List of scroll group ids to show to the user. Either a {@link ScrollGroupId} or `undefined` for\n * no scroll group\n */\n availableScrollGroupIds: (ScrollGroupId | undefined)[];\n /** Currently selected scroll group id. `undefined` for no scroll group */\n scrollGroupId: ScrollGroupId | undefined;\n /** Callback function run when the user tries to change the scroll group id */\n onChangeScrollGroupId: (newScrollGroupId: ScrollGroupId | undefined) => void;\n /**\n * Localized strings to use for displaying scroll group ids. Must be an object whose keys are\n * `getLocalizeKeyForScrollGroupId(scrollGroupId)` for all scroll group ids (and `undefined` if\n * included) in {@link ScrollGroupSelectorProps.availableScrollGroupIds} and whose values are the\n * localized strings to use for those scroll group ids.\n *\n * Defaults to English localizations of English alphabet for scroll groups 0-25 (e.g. 0 is A) and\n * Ø for `undefined`. Will fill in any that are not provided with these English localizations.\n * Also, if any values match the keys, the English localization will be used. This is useful in\n * case you want to pass in a temporary version of the localized strings while your localized\n * strings load.\n *\n * @example\n *\n * ```typescript\n * const myScrollGroupIdLocalizedStrings = {\n * [getLocalizeKeyForScrollGroupId('undefined')]: 'Ø',\n * [getLocalizeKeyForScrollGroupId(0)]: 'A',\n * [getLocalizeKeyForScrollGroupId(1)]: 'B',\n * [getLocalizeKeyForScrollGroupId(2)]: 'C',\n * [getLocalizeKeyForScrollGroupId(3)]: 'D',\n * [getLocalizeKeyForScrollGroupId(4)]: 'E',\n * };\n * ```\n *\n * @example\n *\n * ```tsx\n * const availableScrollGroupIds = [undefined, 0, 1, 2, 3, 4];\n *\n * const localizeKeys = getLocalizeKeysForScrollGroupIds();\n *\n * const [localizedStrings] = useLocalizedStrings(localizeKeys);\n *\n * ...\n *\n * \n * ```\n */\n localizedStrings?: LanguageStrings;\n};\n\n/** Selector component for choosing a scroll group */\nexport default function ScrollGroupSelector({\n availableScrollGroupIds,\n scrollGroupId,\n onChangeScrollGroupId,\n localizedStrings = {},\n}: ScrollGroupSelectorProps) {\n const localizedStringsDefaulted = {\n ...DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS,\n ...Object.fromEntries(\n Object.entries(localizedStrings).map(\n ([localizedStringKey, localizedStringValue]: [string, string]) => [\n localizedStringKey,\n localizedStringKey === localizedStringValue &&\n localizedStringKey in DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS\n ? DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS[localizedStringKey]\n : localizedStringValue,\n ],\n ),\n ),\n };\n return (\n \n onChangeScrollGroupId(\n newScrollGroupString === 'undefined' ? undefined : parseInt(newScrollGroupString, 10),\n )\n }\n >\n \n \n \n \n {availableScrollGroupIds.map((scrollGroupOptionId) => (\n \n {localizedStringsDefaulted[getLocalizeKeyForScrollGroupId(scrollGroupOptionId)]}\n \n ))}\n \n \n );\n}\n","import { PropsWithChildren } from 'react';\nimport { Separator } from '@/components/shadcn-ui/separator';\n\n/** Props for the SettingsList component, currently just children */\ntype SettingsListProps = PropsWithChildren;\n\n/**\n * SettingsList component is a wrapper for list items. Rendered with a formatted div\n *\n * @param children To populate the list with\n * @returns Formatted div encompassing the children\n */\nexport function SettingsList({ children }: SettingsListProps) {\n return
    {children}
    ;\n}\n\n/** Props for SettingsListItem component */\ntype SettingsListItemProps = PropsWithChildren & {\n /** Primary text of the list item */\n primary: string;\n\n /** Optional text of the list item */\n secondary?: string | undefined;\n\n /** Optional boolean to display a message if the children aren't loaded yet. Defaults to false */\n isLoading?: boolean;\n\n /** Optional message to display if isLoading */\n loadingMessage?: string;\n};\n\n/**\n * SettingsListItem component is a common list item. Rendered with a formatted div\n *\n * @param primary Primary text of the list item\n * @param secondary Optional secondary text of the list item\n * @param isLoading Optional, to display a message if the action component isn't generated yet,\n * defaults to false\n * @param children The action component(s) to provide for this item\n * @param loadingMessage Optional, message to display if isLoading\n * @returns Formatted div encompassing the list item content\n */\nexport function SettingsListItem({\n primary,\n secondary,\n children,\n isLoading = false,\n loadingMessage,\n}: SettingsListItemProps) {\n return (\n
    \n
    \n

    {primary}

    \n

    \n {secondary}\n

    \n
    \n\n {isLoading ? (\n

    {loadingMessage}

    \n ) : (\n
    {children}
    \n )}\n
    \n );\n}\n\n/** Props for SettingsListHeader component */\ntype SettingsListHeaderProps = {\n /** The primary text of the list header */\n primary: string;\n\n /** Optional secondary text of the list header */\n secondary?: string | undefined;\n\n /** Optional boolean to include a separator underneath the secondary text. Defaults to false */\n includeSeparator?: boolean;\n};\n\n/**\n * SettingsListHeader component displays text above the list\n *\n * @param primary The primary text of the list header\n * @param secondary Optional secondary text of the list header\n * @param includeSeparator Optional boolean to include a separator underneath the secondary text.\n * Defaults to false\n * @returns Formatted div with list header content\n */\nexport function SettingsListHeader({\n primary,\n secondary,\n includeSeparator = false,\n}: SettingsListHeaderProps) {\n return (\n
    \n
    \n

    {primary}

    \n

    {secondary}

    \n
    \n {includeSeparator ? : ''}\n
    \n );\n}\n","import Checkbox from '@/components/shadcn-ui/checkbox';\nimport { Label } from '@/components/shadcn-ui/label';\n\nexport type ChecklistProps = {\n /** Optional string representing the id attribute of the Checklist */\n id?: string;\n /** Optional string representing CSS class name(s) for styling */\n className?: string;\n /** Array of strings representing the checkable items */\n listItems: string[];\n /** Array of strings representing the checked items */\n selectedListItems: string[];\n /**\n * Function that is called when a checkbox item is selected or deselected\n *\n * @param item The string description for this item\n * @param selected True if selected, false if not selected\n */\n handleSelectListItem: (item: string, selected: boolean) => void;\n\n /**\n * Optional function creates a label for a provided checkable item\n *\n * @param item The item for which a label is to be created\n * @returns A string representing the label text for the checkbox associated with that item\n */\n createLabel?: (item: string) => string;\n};\n\n/** Renders a list of checkboxes. Each checkbox corresponds to an item from the `listItems` array. */\nexport default function Checklist({\n id,\n className,\n listItems,\n selectedListItems,\n handleSelectListItem,\n createLabel,\n}: ChecklistProps) {\n return (\n
    \n {listItems.map((item) => (\n
    \n handleSelectListItem(item, value)}\n />\n \n
    \n ))}\n
    \n );\n}\n","function _interopRequireDefault(obj) {\n return obj && obj.__esModule ? obj : {\n \"default\": obj\n };\n}\nmodule.exports = _interopRequireDefault, module.exports.__esModule = true, module.exports[\"default\"] = module.exports;","export default function chainPropTypes(propType1, propType2) {\n if (process.env.NODE_ENV === 'production') {\n return () => null;\n }\n return function validate(...args) {\n return propType1(...args) || propType2(...args);\n };\n}","export default function _extends() {\n _extends = Object.assign ? Object.assign.bind() : function (target) {\n for (var i = 1; i < arguments.length; i++) {\n var source = arguments[i];\n for (var key in source) {\n if (Object.prototype.hasOwnProperty.call(source, key)) {\n target[key] = source[key];\n }\n }\n }\n return target;\n };\n return _extends.apply(this, arguments);\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\n// https://github.com/sindresorhus/is-plain-obj/blob/main/index.js\nexport function isPlainObject(item) {\n if (typeof item !== 'object' || item === null) {\n return false;\n }\n const prototype = Object.getPrototypeOf(item);\n return (prototype === null || prototype === Object.prototype || Object.getPrototypeOf(prototype) === null) && !(Symbol.toStringTag in item) && !(Symbol.iterator in item);\n}\nfunction deepClone(source) {\n if (!isPlainObject(source)) {\n return source;\n }\n const output = {};\n Object.keys(source).forEach(key => {\n output[key] = deepClone(source[key]);\n });\n return output;\n}\nexport default function deepmerge(target, source, options = {\n clone: true\n}) {\n const output = options.clone ? _extends({}, target) : target;\n if (isPlainObject(target) && isPlainObject(source)) {\n Object.keys(source).forEach(key => {\n // Avoid prototype pollution\n if (key === '__proto__') {\n return;\n }\n if (isPlainObject(source[key]) && key in target && isPlainObject(target[key])) {\n // Since `output` is a clone of `target` and we have narrowed `target` in this block we can cast to the same type.\n output[key] = deepmerge(target[key], source[key], options);\n } else if (options.clone) {\n output[key] = isPlainObject(source[key]) ? deepClone(source[key]) : source[key];\n } else {\n output[key] = source[key];\n }\n });\n }\n return output;\n}","/** @license React v16.13.1\n * react-is.production.min.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';var b=\"function\"===typeof Symbol&&Symbol.for,c=b?Symbol.for(\"react.element\"):60103,d=b?Symbol.for(\"react.portal\"):60106,e=b?Symbol.for(\"react.fragment\"):60107,f=b?Symbol.for(\"react.strict_mode\"):60108,g=b?Symbol.for(\"react.profiler\"):60114,h=b?Symbol.for(\"react.provider\"):60109,k=b?Symbol.for(\"react.context\"):60110,l=b?Symbol.for(\"react.async_mode\"):60111,m=b?Symbol.for(\"react.concurrent_mode\"):60111,n=b?Symbol.for(\"react.forward_ref\"):60112,p=b?Symbol.for(\"react.suspense\"):60113,q=b?\nSymbol.for(\"react.suspense_list\"):60120,r=b?Symbol.for(\"react.memo\"):60115,t=b?Symbol.for(\"react.lazy\"):60116,v=b?Symbol.for(\"react.block\"):60121,w=b?Symbol.for(\"react.fundamental\"):60117,x=b?Symbol.for(\"react.responder\"):60118,y=b?Symbol.for(\"react.scope\"):60119;\nfunction z(a){if(\"object\"===typeof a&&null!==a){var u=a.$$typeof;switch(u){case c:switch(a=a.type,a){case l:case m:case e:case g:case f:case p:return a;default:switch(a=a&&a.$$typeof,a){case k:case n:case t:case r:case h:return a;default:return u}}case d:return u}}}function A(a){return z(a)===m}exports.AsyncMode=l;exports.ConcurrentMode=m;exports.ContextConsumer=k;exports.ContextProvider=h;exports.Element=c;exports.ForwardRef=n;exports.Fragment=e;exports.Lazy=t;exports.Memo=r;exports.Portal=d;\nexports.Profiler=g;exports.StrictMode=f;exports.Suspense=p;exports.isAsyncMode=function(a){return A(a)||z(a)===l};exports.isConcurrentMode=A;exports.isContextConsumer=function(a){return z(a)===k};exports.isContextProvider=function(a){return z(a)===h};exports.isElement=function(a){return\"object\"===typeof a&&null!==a&&a.$$typeof===c};exports.isForwardRef=function(a){return z(a)===n};exports.isFragment=function(a){return z(a)===e};exports.isLazy=function(a){return z(a)===t};\nexports.isMemo=function(a){return z(a)===r};exports.isPortal=function(a){return z(a)===d};exports.isProfiler=function(a){return z(a)===g};exports.isStrictMode=function(a){return z(a)===f};exports.isSuspense=function(a){return z(a)===p};\nexports.isValidElementType=function(a){return\"string\"===typeof a||\"function\"===typeof a||a===e||a===m||a===g||a===f||a===p||a===q||\"object\"===typeof a&&null!==a&&(a.$$typeof===t||a.$$typeof===r||a.$$typeof===h||a.$$typeof===k||a.$$typeof===n||a.$$typeof===w||a.$$typeof===x||a.$$typeof===y||a.$$typeof===v)};exports.typeOf=z;\n","/** @license React v16.13.1\n * react-is.development.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\n\n\nif (process.env.NODE_ENV !== \"production\") {\n (function() {\n'use strict';\n\n// The Symbol used to tag the ReactElement-like types. If there is no native Symbol\n// nor polyfill, then a plain number is used for performance.\nvar hasSymbol = typeof Symbol === 'function' && Symbol.for;\nvar REACT_ELEMENT_TYPE = hasSymbol ? Symbol.for('react.element') : 0xeac7;\nvar REACT_PORTAL_TYPE = hasSymbol ? Symbol.for('react.portal') : 0xeaca;\nvar REACT_FRAGMENT_TYPE = hasSymbol ? Symbol.for('react.fragment') : 0xeacb;\nvar REACT_STRICT_MODE_TYPE = hasSymbol ? Symbol.for('react.strict_mode') : 0xeacc;\nvar REACT_PROFILER_TYPE = hasSymbol ? Symbol.for('react.profiler') : 0xead2;\nvar REACT_PROVIDER_TYPE = hasSymbol ? Symbol.for('react.provider') : 0xeacd;\nvar REACT_CONTEXT_TYPE = hasSymbol ? Symbol.for('react.context') : 0xeace; // TODO: We don't use AsyncMode or ConcurrentMode anymore. They were temporary\n// (unstable) APIs that have been removed. Can we remove the symbols?\n\nvar REACT_ASYNC_MODE_TYPE = hasSymbol ? Symbol.for('react.async_mode') : 0xeacf;\nvar REACT_CONCURRENT_MODE_TYPE = hasSymbol ? Symbol.for('react.concurrent_mode') : 0xeacf;\nvar REACT_FORWARD_REF_TYPE = hasSymbol ? Symbol.for('react.forward_ref') : 0xead0;\nvar REACT_SUSPENSE_TYPE = hasSymbol ? Symbol.for('react.suspense') : 0xead1;\nvar REACT_SUSPENSE_LIST_TYPE = hasSymbol ? Symbol.for('react.suspense_list') : 0xead8;\nvar REACT_MEMO_TYPE = hasSymbol ? Symbol.for('react.memo') : 0xead3;\nvar REACT_LAZY_TYPE = hasSymbol ? Symbol.for('react.lazy') : 0xead4;\nvar REACT_BLOCK_TYPE = hasSymbol ? Symbol.for('react.block') : 0xead9;\nvar REACT_FUNDAMENTAL_TYPE = hasSymbol ? Symbol.for('react.fundamental') : 0xead5;\nvar REACT_RESPONDER_TYPE = hasSymbol ? Symbol.for('react.responder') : 0xead6;\nvar REACT_SCOPE_TYPE = hasSymbol ? Symbol.for('react.scope') : 0xead7;\n\nfunction isValidElementType(type) {\n return typeof type === 'string' || typeof type === 'function' || // Note: its typeof might be other than 'symbol' or 'number' if it's a polyfill.\n type === REACT_FRAGMENT_TYPE || type === REACT_CONCURRENT_MODE_TYPE || type === REACT_PROFILER_TYPE || type === REACT_STRICT_MODE_TYPE || type === REACT_SUSPENSE_TYPE || type === REACT_SUSPENSE_LIST_TYPE || typeof type === 'object' && type !== null && (type.$$typeof === REACT_LAZY_TYPE || type.$$typeof === REACT_MEMO_TYPE || type.$$typeof === REACT_PROVIDER_TYPE || type.$$typeof === REACT_CONTEXT_TYPE || type.$$typeof === REACT_FORWARD_REF_TYPE || type.$$typeof === REACT_FUNDAMENTAL_TYPE || type.$$typeof === REACT_RESPONDER_TYPE || type.$$typeof === REACT_SCOPE_TYPE || type.$$typeof === REACT_BLOCK_TYPE);\n}\n\nfunction typeOf(object) {\n if (typeof object === 'object' && object !== null) {\n var $$typeof = object.$$typeof;\n\n switch ($$typeof) {\n case REACT_ELEMENT_TYPE:\n var type = object.type;\n\n switch (type) {\n case REACT_ASYNC_MODE_TYPE:\n case REACT_CONCURRENT_MODE_TYPE:\n case REACT_FRAGMENT_TYPE:\n case REACT_PROFILER_TYPE:\n case REACT_STRICT_MODE_TYPE:\n case REACT_SUSPENSE_TYPE:\n return type;\n\n default:\n var $$typeofType = type && type.$$typeof;\n\n switch ($$typeofType) {\n case REACT_CONTEXT_TYPE:\n case REACT_FORWARD_REF_TYPE:\n case REACT_LAZY_TYPE:\n case REACT_MEMO_TYPE:\n case REACT_PROVIDER_TYPE:\n return $$typeofType;\n\n default:\n return $$typeof;\n }\n\n }\n\n case REACT_PORTAL_TYPE:\n return $$typeof;\n }\n }\n\n return undefined;\n} // AsyncMode is deprecated along with isAsyncMode\n\nvar AsyncMode = REACT_ASYNC_MODE_TYPE;\nvar ConcurrentMode = REACT_CONCURRENT_MODE_TYPE;\nvar ContextConsumer = REACT_CONTEXT_TYPE;\nvar ContextProvider = REACT_PROVIDER_TYPE;\nvar Element = REACT_ELEMENT_TYPE;\nvar ForwardRef = REACT_FORWARD_REF_TYPE;\nvar Fragment = REACT_FRAGMENT_TYPE;\nvar Lazy = REACT_LAZY_TYPE;\nvar Memo = REACT_MEMO_TYPE;\nvar Portal = REACT_PORTAL_TYPE;\nvar Profiler = REACT_PROFILER_TYPE;\nvar StrictMode = REACT_STRICT_MODE_TYPE;\nvar Suspense = REACT_SUSPENSE_TYPE;\nvar hasWarnedAboutDeprecatedIsAsyncMode = false; // AsyncMode should be deprecated\n\nfunction isAsyncMode(object) {\n {\n if (!hasWarnedAboutDeprecatedIsAsyncMode) {\n hasWarnedAboutDeprecatedIsAsyncMode = true; // Using console['warn'] to evade Babel and ESLint\n\n console['warn']('The ReactIs.isAsyncMode() alias has been deprecated, ' + 'and will be removed in React 17+. Update your code to use ' + 'ReactIs.isConcurrentMode() instead. It has the exact same API.');\n }\n }\n\n return isConcurrentMode(object) || typeOf(object) === REACT_ASYNC_MODE_TYPE;\n}\nfunction isConcurrentMode(object) {\n return typeOf(object) === REACT_CONCURRENT_MODE_TYPE;\n}\nfunction isContextConsumer(object) {\n return typeOf(object) === REACT_CONTEXT_TYPE;\n}\nfunction isContextProvider(object) {\n return typeOf(object) === REACT_PROVIDER_TYPE;\n}\nfunction isElement(object) {\n return typeof object === 'object' && object !== null && object.$$typeof === REACT_ELEMENT_TYPE;\n}\nfunction isForwardRef(object) {\n return typeOf(object) === REACT_FORWARD_REF_TYPE;\n}\nfunction isFragment(object) {\n return typeOf(object) === REACT_FRAGMENT_TYPE;\n}\nfunction isLazy(object) {\n return typeOf(object) === REACT_LAZY_TYPE;\n}\nfunction isMemo(object) {\n return typeOf(object) === REACT_MEMO_TYPE;\n}\nfunction isPortal(object) {\n return typeOf(object) === REACT_PORTAL_TYPE;\n}\nfunction isProfiler(object) {\n return typeOf(object) === REACT_PROFILER_TYPE;\n}\nfunction isStrictMode(object) {\n return typeOf(object) === REACT_STRICT_MODE_TYPE;\n}\nfunction isSuspense(object) {\n return typeOf(object) === REACT_SUSPENSE_TYPE;\n}\n\nexports.AsyncMode = AsyncMode;\nexports.ConcurrentMode = ConcurrentMode;\nexports.ContextConsumer = ContextConsumer;\nexports.ContextProvider = ContextProvider;\nexports.Element = Element;\nexports.ForwardRef = ForwardRef;\nexports.Fragment = Fragment;\nexports.Lazy = Lazy;\nexports.Memo = Memo;\nexports.Portal = Portal;\nexports.Profiler = Profiler;\nexports.StrictMode = StrictMode;\nexports.Suspense = Suspense;\nexports.isAsyncMode = isAsyncMode;\nexports.isConcurrentMode = isConcurrentMode;\nexports.isContextConsumer = isContextConsumer;\nexports.isContextProvider = isContextProvider;\nexports.isElement = isElement;\nexports.isForwardRef = isForwardRef;\nexports.isFragment = isFragment;\nexports.isLazy = isLazy;\nexports.isMemo = isMemo;\nexports.isPortal = isPortal;\nexports.isProfiler = isProfiler;\nexports.isStrictMode = isStrictMode;\nexports.isSuspense = isSuspense;\nexports.isValidElementType = isValidElementType;\nexports.typeOf = typeOf;\n })();\n}\n","'use strict';\n\nif (process.env.NODE_ENV === 'production') {\n module.exports = require('./cjs/react-is.production.min.js');\n} else {\n module.exports = require('./cjs/react-is.development.js');\n}\n","/*\nobject-assign\n(c) Sindre Sorhus\n@license MIT\n*/\n\n'use strict';\n/* eslint-disable no-unused-vars */\nvar getOwnPropertySymbols = Object.getOwnPropertySymbols;\nvar hasOwnProperty = Object.prototype.hasOwnProperty;\nvar propIsEnumerable = Object.prototype.propertyIsEnumerable;\n\nfunction toObject(val) {\n\tif (val === null || val === undefined) {\n\t\tthrow new TypeError('Object.assign cannot be called with null or undefined');\n\t}\n\n\treturn Object(val);\n}\n\nfunction shouldUseNative() {\n\ttry {\n\t\tif (!Object.assign) {\n\t\t\treturn false;\n\t\t}\n\n\t\t// Detect buggy property enumeration order in older V8 versions.\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=4118\n\t\tvar test1 = new String('abc'); // eslint-disable-line no-new-wrappers\n\t\ttest1[5] = 'de';\n\t\tif (Object.getOwnPropertyNames(test1)[0] === '5') {\n\t\t\treturn false;\n\t\t}\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=3056\n\t\tvar test2 = {};\n\t\tfor (var i = 0; i < 10; i++) {\n\t\t\ttest2['_' + String.fromCharCode(i)] = i;\n\t\t}\n\t\tvar order2 = Object.getOwnPropertyNames(test2).map(function (n) {\n\t\t\treturn test2[n];\n\t\t});\n\t\tif (order2.join('') !== '0123456789') {\n\t\t\treturn false;\n\t\t}\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=3056\n\t\tvar test3 = {};\n\t\t'abcdefghijklmnopqrst'.split('').forEach(function (letter) {\n\t\t\ttest3[letter] = letter;\n\t\t});\n\t\tif (Object.keys(Object.assign({}, test3)).join('') !==\n\t\t\t\t'abcdefghijklmnopqrst') {\n\t\t\treturn false;\n\t\t}\n\n\t\treturn true;\n\t} catch (err) {\n\t\t// We don't expect any of the above to throw, but better to be safe.\n\t\treturn false;\n\t}\n}\n\nmodule.exports = shouldUseNative() ? Object.assign : function (target, source) {\n\tvar from;\n\tvar to = toObject(target);\n\tvar symbols;\n\n\tfor (var s = 1; s < arguments.length; s++) {\n\t\tfrom = Object(arguments[s]);\n\n\t\tfor (var key in from) {\n\t\t\tif (hasOwnProperty.call(from, key)) {\n\t\t\t\tto[key] = from[key];\n\t\t\t}\n\t\t}\n\n\t\tif (getOwnPropertySymbols) {\n\t\t\tsymbols = getOwnPropertySymbols(from);\n\t\t\tfor (var i = 0; i < symbols.length; i++) {\n\t\t\t\tif (propIsEnumerable.call(from, symbols[i])) {\n\t\t\t\t\tto[symbols[i]] = from[symbols[i]];\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\n\treturn to;\n};\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar ReactPropTypesSecret = 'SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED';\n\nmodule.exports = ReactPropTypesSecret;\n","module.exports = Function.call.bind(Object.prototype.hasOwnProperty);\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar printWarning = function() {};\n\nif (process.env.NODE_ENV !== 'production') {\n var ReactPropTypesSecret = require('./lib/ReactPropTypesSecret');\n var loggedTypeFailures = {};\n var has = require('./lib/has');\n\n printWarning = function(text) {\n var message = 'Warning: ' + text;\n if (typeof console !== 'undefined') {\n console.error(message);\n }\n try {\n // --- Welcome to debugging React ---\n // This error was thrown as a convenience so that you can use this stack\n // to find the callsite that caused this warning to fire.\n throw new Error(message);\n } catch (x) { /**/ }\n };\n}\n\n/**\n * Assert that the values match with the type specs.\n * Error messages are memorized and will only be shown once.\n *\n * @param {object} typeSpecs Map of name to a ReactPropType\n * @param {object} values Runtime values that need to be type-checked\n * @param {string} location e.g. \"prop\", \"context\", \"child context\"\n * @param {string} componentName Name of the component for error messages.\n * @param {?Function} getStack Returns the component stack.\n * @private\n */\nfunction checkPropTypes(typeSpecs, values, location, componentName, getStack) {\n if (process.env.NODE_ENV !== 'production') {\n for (var typeSpecName in typeSpecs) {\n if (has(typeSpecs, typeSpecName)) {\n var error;\n // Prop type validation may throw. In case they do, we don't want to\n // fail the render phase where it didn't fail before. So we log it.\n // After these have been cleaned up, we'll let them throw.\n try {\n // This is intentionally an invariant that gets caught. It's the same\n // behavior as without this statement except with a better message.\n if (typeof typeSpecs[typeSpecName] !== 'function') {\n var err = Error(\n (componentName || 'React class') + ': ' + location + ' type `' + typeSpecName + '` is invalid; ' +\n 'it must be a function, usually from the `prop-types` package, but received `' + typeof typeSpecs[typeSpecName] + '`.' +\n 'This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.'\n );\n err.name = 'Invariant Violation';\n throw err;\n }\n error = typeSpecs[typeSpecName](values, typeSpecName, componentName, location, null, ReactPropTypesSecret);\n } catch (ex) {\n error = ex;\n }\n if (error && !(error instanceof Error)) {\n printWarning(\n (componentName || 'React class') + ': type specification of ' +\n location + ' `' + typeSpecName + '` is invalid; the type checker ' +\n 'function must return `null` or an `Error` but returned a ' + typeof error + '. ' +\n 'You may have forgotten to pass an argument to the type checker ' +\n 'creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and ' +\n 'shape all require an argument).'\n );\n }\n if (error instanceof Error && !(error.message in loggedTypeFailures)) {\n // Only monitor this failure once because there tends to be a lot of the\n // same error.\n loggedTypeFailures[error.message] = true;\n\n var stack = getStack ? getStack() : '';\n\n printWarning(\n 'Failed ' + location + ' type: ' + error.message + (stack != null ? stack : '')\n );\n }\n }\n }\n }\n}\n\n/**\n * Resets warning cache when testing.\n *\n * @private\n */\ncheckPropTypes.resetWarningCache = function() {\n if (process.env.NODE_ENV !== 'production') {\n loggedTypeFailures = {};\n }\n}\n\nmodule.exports = checkPropTypes;\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar ReactIs = require('react-is');\nvar assign = require('object-assign');\n\nvar ReactPropTypesSecret = require('./lib/ReactPropTypesSecret');\nvar has = require('./lib/has');\nvar checkPropTypes = require('./checkPropTypes');\n\nvar printWarning = function() {};\n\nif (process.env.NODE_ENV !== 'production') {\n printWarning = function(text) {\n var message = 'Warning: ' + text;\n if (typeof console !== 'undefined') {\n console.error(message);\n }\n try {\n // --- Welcome to debugging React ---\n // This error was thrown as a convenience so that you can use this stack\n // to find the callsite that caused this warning to fire.\n throw new Error(message);\n } catch (x) {}\n };\n}\n\nfunction emptyFunctionThatReturnsNull() {\n return null;\n}\n\nmodule.exports = function(isValidElement, throwOnDirectAccess) {\n /* global Symbol */\n var ITERATOR_SYMBOL = typeof Symbol === 'function' && Symbol.iterator;\n var FAUX_ITERATOR_SYMBOL = '@@iterator'; // Before Symbol spec.\n\n /**\n * Returns the iterator method function contained on the iterable object.\n *\n * Be sure to invoke the function with the iterable as context:\n *\n * var iteratorFn = getIteratorFn(myIterable);\n * if (iteratorFn) {\n * var iterator = iteratorFn.call(myIterable);\n * ...\n * }\n *\n * @param {?object} maybeIterable\n * @return {?function}\n */\n function getIteratorFn(maybeIterable) {\n var iteratorFn = maybeIterable && (ITERATOR_SYMBOL && maybeIterable[ITERATOR_SYMBOL] || maybeIterable[FAUX_ITERATOR_SYMBOL]);\n if (typeof iteratorFn === 'function') {\n return iteratorFn;\n }\n }\n\n /**\n * Collection of methods that allow declaration and validation of props that are\n * supplied to React components. Example usage:\n *\n * var Props = require('ReactPropTypes');\n * var MyArticle = React.createClass({\n * propTypes: {\n * // An optional string prop named \"description\".\n * description: Props.string,\n *\n * // A required enum prop named \"category\".\n * category: Props.oneOf(['News','Photos']).isRequired,\n *\n * // A prop named \"dialog\" that requires an instance of Dialog.\n * dialog: Props.instanceOf(Dialog).isRequired\n * },\n * render: function() { ... }\n * });\n *\n * A more formal specification of how these methods are used:\n *\n * type := array|bool|func|object|number|string|oneOf([...])|instanceOf(...)\n * decl := ReactPropTypes.{type}(.isRequired)?\n *\n * Each and every declaration produces a function with the same signature. This\n * allows the creation of custom validation functions. For example:\n *\n * var MyLink = React.createClass({\n * propTypes: {\n * // An optional string or URI prop named \"href\".\n * href: function(props, propName, componentName) {\n * var propValue = props[propName];\n * if (propValue != null && typeof propValue !== 'string' &&\n * !(propValue instanceof URI)) {\n * return new Error(\n * 'Expected a string or an URI for ' + propName + ' in ' +\n * componentName\n * );\n * }\n * }\n * },\n * render: function() {...}\n * });\n *\n * @internal\n */\n\n var ANONYMOUS = '<>';\n\n // Important!\n // Keep this list in sync with production version in `./factoryWithThrowingShims.js`.\n var ReactPropTypes = {\n array: createPrimitiveTypeChecker('array'),\n bigint: createPrimitiveTypeChecker('bigint'),\n bool: createPrimitiveTypeChecker('boolean'),\n func: createPrimitiveTypeChecker('function'),\n number: createPrimitiveTypeChecker('number'),\n object: createPrimitiveTypeChecker('object'),\n string: createPrimitiveTypeChecker('string'),\n symbol: createPrimitiveTypeChecker('symbol'),\n\n any: createAnyTypeChecker(),\n arrayOf: createArrayOfTypeChecker,\n element: createElementTypeChecker(),\n elementType: createElementTypeTypeChecker(),\n instanceOf: createInstanceTypeChecker,\n node: createNodeChecker(),\n objectOf: createObjectOfTypeChecker,\n oneOf: createEnumTypeChecker,\n oneOfType: createUnionTypeChecker,\n shape: createShapeTypeChecker,\n exact: createStrictShapeTypeChecker,\n };\n\n /**\n * inlined Object.is polyfill to avoid requiring consumers ship their own\n * https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object/is\n */\n /*eslint-disable no-self-compare*/\n function is(x, y) {\n // SameValue algorithm\n if (x === y) {\n // Steps 1-5, 7-10\n // Steps 6.b-6.e: +0 != -0\n return x !== 0 || 1 / x === 1 / y;\n } else {\n // Step 6.a: NaN == NaN\n return x !== x && y !== y;\n }\n }\n /*eslint-enable no-self-compare*/\n\n /**\n * We use an Error-like object for backward compatibility as people may call\n * PropTypes directly and inspect their output. However, we don't use real\n * Errors anymore. We don't inspect their stack anyway, and creating them\n * is prohibitively expensive if they are created too often, such as what\n * happens in oneOfType() for any type before the one that matched.\n */\n function PropTypeError(message, data) {\n this.message = message;\n this.data = data && typeof data === 'object' ? data: {};\n this.stack = '';\n }\n // Make `instanceof Error` still work for returned errors.\n PropTypeError.prototype = Error.prototype;\n\n function createChainableTypeChecker(validate) {\n if (process.env.NODE_ENV !== 'production') {\n var manualPropTypeCallCache = {};\n var manualPropTypeWarningCount = 0;\n }\n function checkType(isRequired, props, propName, componentName, location, propFullName, secret) {\n componentName = componentName || ANONYMOUS;\n propFullName = propFullName || propName;\n\n if (secret !== ReactPropTypesSecret) {\n if (throwOnDirectAccess) {\n // New behavior only for users of `prop-types` package\n var err = new Error(\n 'Calling PropTypes validators directly is not supported by the `prop-types` package. ' +\n 'Use `PropTypes.checkPropTypes()` to call them. ' +\n 'Read more at http://fb.me/use-check-prop-types'\n );\n err.name = 'Invariant Violation';\n throw err;\n } else if (process.env.NODE_ENV !== 'production' && typeof console !== 'undefined') {\n // Old behavior for people using React.PropTypes\n var cacheKey = componentName + ':' + propName;\n if (\n !manualPropTypeCallCache[cacheKey] &&\n // Avoid spamming the console because they are often not actionable except for lib authors\n manualPropTypeWarningCount < 3\n ) {\n printWarning(\n 'You are manually calling a React.PropTypes validation ' +\n 'function for the `' + propFullName + '` prop on `' + componentName + '`. This is deprecated ' +\n 'and will throw in the standalone `prop-types` package. ' +\n 'You may be seeing this warning due to a third-party PropTypes ' +\n 'library. See https://fb.me/react-warning-dont-call-proptypes ' + 'for details.'\n );\n manualPropTypeCallCache[cacheKey] = true;\n manualPropTypeWarningCount++;\n }\n }\n }\n if (props[propName] == null) {\n if (isRequired) {\n if (props[propName] === null) {\n return new PropTypeError('The ' + location + ' `' + propFullName + '` is marked as required ' + ('in `' + componentName + '`, but its value is `null`.'));\n }\n return new PropTypeError('The ' + location + ' `' + propFullName + '` is marked as required in ' + ('`' + componentName + '`, but its value is `undefined`.'));\n }\n return null;\n } else {\n return validate(props, propName, componentName, location, propFullName);\n }\n }\n\n var chainedCheckType = checkType.bind(null, false);\n chainedCheckType.isRequired = checkType.bind(null, true);\n\n return chainedCheckType;\n }\n\n function createPrimitiveTypeChecker(expectedType) {\n function validate(props, propName, componentName, location, propFullName, secret) {\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== expectedType) {\n // `propValue` being instance of, say, date/regexp, pass the 'object'\n // check, but we can offer a more precise error message here rather than\n // 'of type `object`'.\n var preciseType = getPreciseType(propValue);\n\n return new PropTypeError(\n 'Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + preciseType + '` supplied to `' + componentName + '`, expected ') + ('`' + expectedType + '`.'),\n {expectedType: expectedType}\n );\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createAnyTypeChecker() {\n return createChainableTypeChecker(emptyFunctionThatReturnsNull);\n }\n\n function createArrayOfTypeChecker(typeChecker) {\n function validate(props, propName, componentName, location, propFullName) {\n if (typeof typeChecker !== 'function') {\n return new PropTypeError('Property `' + propFullName + '` of component `' + componentName + '` has invalid PropType notation inside arrayOf.');\n }\n var propValue = props[propName];\n if (!Array.isArray(propValue)) {\n var propType = getPropType(propValue);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected an array.'));\n }\n for (var i = 0; i < propValue.length; i++) {\n var error = typeChecker(propValue, i, componentName, location, propFullName + '[' + i + ']', ReactPropTypesSecret);\n if (error instanceof Error) {\n return error;\n }\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createElementTypeChecker() {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n if (!isValidElement(propValue)) {\n var propType = getPropType(propValue);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected a single ReactElement.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createElementTypeTypeChecker() {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n if (!ReactIs.isValidElementType(propValue)) {\n var propType = getPropType(propValue);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected a single ReactElement type.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createInstanceTypeChecker(expectedClass) {\n function validate(props, propName, componentName, location, propFullName) {\n if (!(props[propName] instanceof expectedClass)) {\n var expectedClassName = expectedClass.name || ANONYMOUS;\n var actualClassName = getClassName(props[propName]);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + actualClassName + '` supplied to `' + componentName + '`, expected ') + ('instance of `' + expectedClassName + '`.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createEnumTypeChecker(expectedValues) {\n if (!Array.isArray(expectedValues)) {\n if (process.env.NODE_ENV !== 'production') {\n if (arguments.length > 1) {\n printWarning(\n 'Invalid arguments supplied to oneOf, expected an array, got ' + arguments.length + ' arguments. ' +\n 'A common mistake is to write oneOf(x, y, z) instead of oneOf([x, y, z]).'\n );\n } else {\n printWarning('Invalid argument supplied to oneOf, expected an array.');\n }\n }\n return emptyFunctionThatReturnsNull;\n }\n\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n for (var i = 0; i < expectedValues.length; i++) {\n if (is(propValue, expectedValues[i])) {\n return null;\n }\n }\n\n var valuesString = JSON.stringify(expectedValues, function replacer(key, value) {\n var type = getPreciseType(value);\n if (type === 'symbol') {\n return String(value);\n }\n return value;\n });\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of value `' + String(propValue) + '` ' + ('supplied to `' + componentName + '`, expected one of ' + valuesString + '.'));\n }\n return createChainableTypeChecker(validate);\n }\n\n function createObjectOfTypeChecker(typeChecker) {\n function validate(props, propName, componentName, location, propFullName) {\n if (typeof typeChecker !== 'function') {\n return new PropTypeError('Property `' + propFullName + '` of component `' + componentName + '` has invalid PropType notation inside objectOf.');\n }\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== 'object') {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected an object.'));\n }\n for (var key in propValue) {\n if (has(propValue, key)) {\n var error = typeChecker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret);\n if (error instanceof Error) {\n return error;\n }\n }\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createUnionTypeChecker(arrayOfTypeCheckers) {\n if (!Array.isArray(arrayOfTypeCheckers)) {\n process.env.NODE_ENV !== 'production' ? printWarning('Invalid argument supplied to oneOfType, expected an instance of array.') : void 0;\n return emptyFunctionThatReturnsNull;\n }\n\n for (var i = 0; i < arrayOfTypeCheckers.length; i++) {\n var checker = arrayOfTypeCheckers[i];\n if (typeof checker !== 'function') {\n printWarning(\n 'Invalid argument supplied to oneOfType. Expected an array of check functions, but ' +\n 'received ' + getPostfixForTypeWarning(checker) + ' at index ' + i + '.'\n );\n return emptyFunctionThatReturnsNull;\n }\n }\n\n function validate(props, propName, componentName, location, propFullName) {\n var expectedTypes = [];\n for (var i = 0; i < arrayOfTypeCheckers.length; i++) {\n var checker = arrayOfTypeCheckers[i];\n var checkerResult = checker(props, propName, componentName, location, propFullName, ReactPropTypesSecret);\n if (checkerResult == null) {\n return null;\n }\n if (checkerResult.data && has(checkerResult.data, 'expectedType')) {\n expectedTypes.push(checkerResult.data.expectedType);\n }\n }\n var expectedTypesMessage = (expectedTypes.length > 0) ? ', expected one of type [' + expectedTypes.join(', ') + ']': '';\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` supplied to ' + ('`' + componentName + '`' + expectedTypesMessage + '.'));\n }\n return createChainableTypeChecker(validate);\n }\n\n function createNodeChecker() {\n function validate(props, propName, componentName, location, propFullName) {\n if (!isNode(props[propName])) {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` supplied to ' + ('`' + componentName + '`, expected a ReactNode.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function invalidValidatorError(componentName, location, propFullName, key, type) {\n return new PropTypeError(\n (componentName || 'React class') + ': ' + location + ' type `' + propFullName + '.' + key + '` is invalid; ' +\n 'it must be a function, usually from the `prop-types` package, but received `' + type + '`.'\n );\n }\n\n function createShapeTypeChecker(shapeTypes) {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== 'object') {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type `' + propType + '` ' + ('supplied to `' + componentName + '`, expected `object`.'));\n }\n for (var key in shapeTypes) {\n var checker = shapeTypes[key];\n if (typeof checker !== 'function') {\n return invalidValidatorError(componentName, location, propFullName, key, getPreciseType(checker));\n }\n var error = checker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret);\n if (error) {\n return error;\n }\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createStrictShapeTypeChecker(shapeTypes) {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== 'object') {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type `' + propType + '` ' + ('supplied to `' + componentName + '`, expected `object`.'));\n }\n // We need to check all keys in case some are required but missing from props.\n var allKeys = assign({}, props[propName], shapeTypes);\n for (var key in allKeys) {\n var checker = shapeTypes[key];\n if (has(shapeTypes, key) && typeof checker !== 'function') {\n return invalidValidatorError(componentName, location, propFullName, key, getPreciseType(checker));\n }\n if (!checker) {\n return new PropTypeError(\n 'Invalid ' + location + ' `' + propFullName + '` key `' + key + '` supplied to `' + componentName + '`.' +\n '\\nBad object: ' + JSON.stringify(props[propName], null, ' ') +\n '\\nValid keys: ' + JSON.stringify(Object.keys(shapeTypes), null, ' ')\n );\n }\n var error = checker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret);\n if (error) {\n return error;\n }\n }\n return null;\n }\n\n return createChainableTypeChecker(validate);\n }\n\n function isNode(propValue) {\n switch (typeof propValue) {\n case 'number':\n case 'string':\n case 'undefined':\n return true;\n case 'boolean':\n return !propValue;\n case 'object':\n if (Array.isArray(propValue)) {\n return propValue.every(isNode);\n }\n if (propValue === null || isValidElement(propValue)) {\n return true;\n }\n\n var iteratorFn = getIteratorFn(propValue);\n if (iteratorFn) {\n var iterator = iteratorFn.call(propValue);\n var step;\n if (iteratorFn !== propValue.entries) {\n while (!(step = iterator.next()).done) {\n if (!isNode(step.value)) {\n return false;\n }\n }\n } else {\n // Iterator will provide entry [k,v] tuples rather than values.\n while (!(step = iterator.next()).done) {\n var entry = step.value;\n if (entry) {\n if (!isNode(entry[1])) {\n return false;\n }\n }\n }\n }\n } else {\n return false;\n }\n\n return true;\n default:\n return false;\n }\n }\n\n function isSymbol(propType, propValue) {\n // Native Symbol.\n if (propType === 'symbol') {\n return true;\n }\n\n // falsy value can't be a Symbol\n if (!propValue) {\n return false;\n }\n\n // 19.4.3.5 Symbol.prototype[@@toStringTag] === 'Symbol'\n if (propValue['@@toStringTag'] === 'Symbol') {\n return true;\n }\n\n // Fallback for non-spec compliant Symbols which are polyfilled.\n if (typeof Symbol === 'function' && propValue instanceof Symbol) {\n return true;\n }\n\n return false;\n }\n\n // Equivalent of `typeof` but with special handling for array and regexp.\n function getPropType(propValue) {\n var propType = typeof propValue;\n if (Array.isArray(propValue)) {\n return 'array';\n }\n if (propValue instanceof RegExp) {\n // Old webkits (at least until Android 4.0) return 'function' rather than\n // 'object' for typeof a RegExp. We'll normalize this here so that /bla/\n // passes PropTypes.object.\n return 'object';\n }\n if (isSymbol(propType, propValue)) {\n return 'symbol';\n }\n return propType;\n }\n\n // This handles more types than `getPropType`. Only used for error messages.\n // See `createPrimitiveTypeChecker`.\n function getPreciseType(propValue) {\n if (typeof propValue === 'undefined' || propValue === null) {\n return '' + propValue;\n }\n var propType = getPropType(propValue);\n if (propType === 'object') {\n if (propValue instanceof Date) {\n return 'date';\n } else if (propValue instanceof RegExp) {\n return 'regexp';\n }\n }\n return propType;\n }\n\n // Returns a string that is postfixed to a warning about an invalid type.\n // For example, \"undefined\" or \"of type array\"\n function getPostfixForTypeWarning(value) {\n var type = getPreciseType(value);\n switch (type) {\n case 'array':\n case 'object':\n return 'an ' + type;\n case 'boolean':\n case 'date':\n case 'regexp':\n return 'a ' + type;\n default:\n return type;\n }\n }\n\n // Returns class name of the object, if any.\n function getClassName(propValue) {\n if (!propValue.constructor || !propValue.constructor.name) {\n return ANONYMOUS;\n }\n return propValue.constructor.name;\n }\n\n ReactPropTypes.checkPropTypes = checkPropTypes;\n ReactPropTypes.resetWarningCache = checkPropTypes.resetWarningCache;\n ReactPropTypes.PropTypes = ReactPropTypes;\n\n return ReactPropTypes;\n};\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar ReactPropTypesSecret = require('./lib/ReactPropTypesSecret');\n\nfunction emptyFunction() {}\nfunction emptyFunctionWithReset() {}\nemptyFunctionWithReset.resetWarningCache = emptyFunction;\n\nmodule.exports = function() {\n function shim(props, propName, componentName, location, propFullName, secret) {\n if (secret === ReactPropTypesSecret) {\n // It is still safe when called from React.\n return;\n }\n var err = new Error(\n 'Calling PropTypes validators directly is not supported by the `prop-types` package. ' +\n 'Use PropTypes.checkPropTypes() to call them. ' +\n 'Read more at http://fb.me/use-check-prop-types'\n );\n err.name = 'Invariant Violation';\n throw err;\n };\n shim.isRequired = shim;\n function getShim() {\n return shim;\n };\n // Important!\n // Keep this list in sync with production version in `./factoryWithTypeCheckers.js`.\n var ReactPropTypes = {\n array: shim,\n bigint: shim,\n bool: shim,\n func: shim,\n number: shim,\n object: shim,\n string: shim,\n symbol: shim,\n\n any: shim,\n arrayOf: getShim,\n element: shim,\n elementType: shim,\n instanceOf: getShim,\n node: shim,\n objectOf: getShim,\n oneOf: getShim,\n oneOfType: getShim,\n shape: getShim,\n exact: getShim,\n\n checkPropTypes: emptyFunctionWithReset,\n resetWarningCache: emptyFunction\n };\n\n ReactPropTypes.PropTypes = ReactPropTypes;\n\n return ReactPropTypes;\n};\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\nif (process.env.NODE_ENV !== 'production') {\n var ReactIs = require('react-is');\n\n // By explicitly using `prop-types` you are opting into new development behavior.\n // http://fb.me/prop-types-in-prod\n var throwOnDirectAccess = true;\n module.exports = require('./factoryWithTypeCheckers')(ReactIs.isElement, throwOnDirectAccess);\n} else {\n // By explicitly using `prop-types` you are opting into new production behavior.\n // http://fb.me/prop-types-in-prod\n module.exports = require('./factoryWithThrowingShims')();\n}\n","import PropTypes from 'prop-types';\nimport chainPropTypes from '../chainPropTypes';\nfunction isClassComponent(elementType) {\n // elementType.prototype?.isReactComponent\n const {\n prototype = {}\n } = elementType;\n return Boolean(prototype.isReactComponent);\n}\nfunction acceptingRef(props, propName, componentName, location, propFullName) {\n const element = props[propName];\n const safePropName = propFullName || propName;\n if (element == null ||\n // When server-side rendering React doesn't warn either.\n // This is not an accurate check for SSR.\n // This is only in place for Emotion compat.\n // TODO: Revisit once https://github.com/facebook/react/issues/20047 is resolved.\n typeof window === 'undefined') {\n return null;\n }\n let warningHint;\n const elementType = element.type;\n /**\n * Blacklisting instead of whitelisting\n *\n * Blacklisting will miss some components, such as React.Fragment. Those will at least\n * trigger a warning in React.\n * We can't whitelist because there is no safe way to detect React.forwardRef\n * or class components. \"Safe\" means there's no public API.\n *\n */\n if (typeof elementType === 'function' && !isClassComponent(elementType)) {\n warningHint = 'Did you accidentally use a plain function component for an element instead?';\n }\n if (warningHint !== undefined) {\n return new Error(`Invalid ${location} \\`${safePropName}\\` supplied to \\`${componentName}\\`. ` + `Expected an element that can hold a ref. ${warningHint} ` + 'For more information see https://mui.com/r/caveat-with-refs-guide');\n }\n return null;\n}\nconst elementAcceptingRef = chainPropTypes(PropTypes.element, acceptingRef);\nelementAcceptingRef.isRequired = chainPropTypes(PropTypes.element.isRequired, acceptingRef);\nexport default elementAcceptingRef;","import _extends from \"@babel/runtime/helpers/esm/extends\";\n// This module is based on https://github.com/airbnb/prop-types-exact repository.\n// However, in order to reduce the number of dependencies and to remove some extra safe checks\n// the module was forked.\n\nconst specialProperty = 'exact-prop: \\u200b';\nexport default function exactProp(propTypes) {\n if (process.env.NODE_ENV === 'production') {\n return propTypes;\n }\n return _extends({}, propTypes, {\n [specialProperty]: props => {\n const unsupportedProps = Object.keys(props).filter(prop => !propTypes.hasOwnProperty(prop));\n if (unsupportedProps.length > 0) {\n return new Error(`The following props are not supported: ${unsupportedProps.map(prop => `\\`${prop}\\``).join(', ')}. Please remove them.`);\n }\n return null;\n }\n });\n}","/**\n * WARNING: Don't import this directly.\n * Use `MuiError` from `@mui/internal-babel-macros/MuiError.macro` instead.\n * @param {number} code\n */\nexport default function formatMuiErrorMessage(code) {\n // Apply babel-plugin-transform-template-literals in loose mode\n // loose mode is safe if we're concatenating primitives\n // see https://babeljs.io/docs/en/babel-plugin-transform-template-literals#loose\n /* eslint-disable prefer-template */\n let url = 'https://mui.com/production-error/?code=' + code;\n for (let i = 1; i < arguments.length; i += 1) {\n // rest params over-transpile for this case\n // eslint-disable-next-line prefer-rest-params\n url += '&args[]=' + encodeURIComponent(arguments[i]);\n }\n return 'Minified MUI error #' + code + '; visit ' + url + ' for the full message.';\n /* eslint-enable prefer-template */\n}","/**\n * @license React\n * react-is.production.min.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n'use strict';var b=Symbol.for(\"react.element\"),c=Symbol.for(\"react.portal\"),d=Symbol.for(\"react.fragment\"),e=Symbol.for(\"react.strict_mode\"),f=Symbol.for(\"react.profiler\"),g=Symbol.for(\"react.provider\"),h=Symbol.for(\"react.context\"),k=Symbol.for(\"react.server_context\"),l=Symbol.for(\"react.forward_ref\"),m=Symbol.for(\"react.suspense\"),n=Symbol.for(\"react.suspense_list\"),p=Symbol.for(\"react.memo\"),q=Symbol.for(\"react.lazy\"),t=Symbol.for(\"react.offscreen\"),u;u=Symbol.for(\"react.module.reference\");\nfunction v(a){if(\"object\"===typeof a&&null!==a){var r=a.$$typeof;switch(r){case b:switch(a=a.type,a){case d:case f:case e:case m:case n:return a;default:switch(a=a&&a.$$typeof,a){case k:case h:case l:case q:case p:case g:return a;default:return r}}case c:return r}}}exports.ContextConsumer=h;exports.ContextProvider=g;exports.Element=b;exports.ForwardRef=l;exports.Fragment=d;exports.Lazy=q;exports.Memo=p;exports.Portal=c;exports.Profiler=f;exports.StrictMode=e;exports.Suspense=m;\nexports.SuspenseList=n;exports.isAsyncMode=function(){return!1};exports.isConcurrentMode=function(){return!1};exports.isContextConsumer=function(a){return v(a)===h};exports.isContextProvider=function(a){return v(a)===g};exports.isElement=function(a){return\"object\"===typeof a&&null!==a&&a.$$typeof===b};exports.isForwardRef=function(a){return v(a)===l};exports.isFragment=function(a){return v(a)===d};exports.isLazy=function(a){return v(a)===q};exports.isMemo=function(a){return v(a)===p};\nexports.isPortal=function(a){return v(a)===c};exports.isProfiler=function(a){return v(a)===f};exports.isStrictMode=function(a){return v(a)===e};exports.isSuspense=function(a){return v(a)===m};exports.isSuspenseList=function(a){return v(a)===n};\nexports.isValidElementType=function(a){return\"string\"===typeof a||\"function\"===typeof a||a===d||a===f||a===e||a===m||a===n||a===t||\"object\"===typeof a&&null!==a&&(a.$$typeof===q||a.$$typeof===p||a.$$typeof===g||a.$$typeof===h||a.$$typeof===l||a.$$typeof===u||void 0!==a.getModuleId)?!0:!1};exports.typeOf=v;\n","/**\n * @license React\n * react-is.development.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nif (process.env.NODE_ENV !== \"production\") {\n (function() {\n'use strict';\n\n// ATTENTION\n// When adding new symbols to this file,\n// Please consider also adding to 'react-devtools-shared/src/backend/ReactSymbols'\n// The Symbol used to tag the ReactElement-like types.\nvar REACT_ELEMENT_TYPE = Symbol.for('react.element');\nvar REACT_PORTAL_TYPE = Symbol.for('react.portal');\nvar REACT_FRAGMENT_TYPE = Symbol.for('react.fragment');\nvar REACT_STRICT_MODE_TYPE = Symbol.for('react.strict_mode');\nvar REACT_PROFILER_TYPE = Symbol.for('react.profiler');\nvar REACT_PROVIDER_TYPE = Symbol.for('react.provider');\nvar REACT_CONTEXT_TYPE = Symbol.for('react.context');\nvar REACT_SERVER_CONTEXT_TYPE = Symbol.for('react.server_context');\nvar REACT_FORWARD_REF_TYPE = Symbol.for('react.forward_ref');\nvar REACT_SUSPENSE_TYPE = Symbol.for('react.suspense');\nvar REACT_SUSPENSE_LIST_TYPE = Symbol.for('react.suspense_list');\nvar REACT_MEMO_TYPE = Symbol.for('react.memo');\nvar REACT_LAZY_TYPE = Symbol.for('react.lazy');\nvar REACT_OFFSCREEN_TYPE = Symbol.for('react.offscreen');\n\n// -----------------------------------------------------------------------------\n\nvar enableScopeAPI = false; // Experimental Create Event Handle API.\nvar enableCacheElement = false;\nvar enableTransitionTracing = false; // No known bugs, but needs performance testing\n\nvar enableLegacyHidden = false; // Enables unstable_avoidThisFallback feature in Fiber\n// stuff. Intended to enable React core members to more easily debug scheduling\n// issues in DEV builds.\n\nvar enableDebugTracing = false; // Track which Fiber(s) schedule render work.\n\nvar REACT_MODULE_REFERENCE;\n\n{\n REACT_MODULE_REFERENCE = Symbol.for('react.module.reference');\n}\n\nfunction isValidElementType(type) {\n if (typeof type === 'string' || typeof type === 'function') {\n return true;\n } // Note: typeof might be other than 'symbol' or 'number' (e.g. if it's a polyfill).\n\n\n if (type === REACT_FRAGMENT_TYPE || type === REACT_PROFILER_TYPE || enableDebugTracing || type === REACT_STRICT_MODE_TYPE || type === REACT_SUSPENSE_TYPE || type === REACT_SUSPENSE_LIST_TYPE || enableLegacyHidden || type === REACT_OFFSCREEN_TYPE || enableScopeAPI || enableCacheElement || enableTransitionTracing ) {\n return true;\n }\n\n if (typeof type === 'object' && type !== null) {\n if (type.$$typeof === REACT_LAZY_TYPE || type.$$typeof === REACT_MEMO_TYPE || type.$$typeof === REACT_PROVIDER_TYPE || type.$$typeof === REACT_CONTEXT_TYPE || type.$$typeof === REACT_FORWARD_REF_TYPE || // This needs to include all possible module reference object\n // types supported by any Flight configuration anywhere since\n // we don't know which Flight build this will end up being used\n // with.\n type.$$typeof === REACT_MODULE_REFERENCE || type.getModuleId !== undefined) {\n return true;\n }\n }\n\n return false;\n}\n\nfunction typeOf(object) {\n if (typeof object === 'object' && object !== null) {\n var $$typeof = object.$$typeof;\n\n switch ($$typeof) {\n case REACT_ELEMENT_TYPE:\n var type = object.type;\n\n switch (type) {\n case REACT_FRAGMENT_TYPE:\n case REACT_PROFILER_TYPE:\n case REACT_STRICT_MODE_TYPE:\n case REACT_SUSPENSE_TYPE:\n case REACT_SUSPENSE_LIST_TYPE:\n return type;\n\n default:\n var $$typeofType = type && type.$$typeof;\n\n switch ($$typeofType) {\n case REACT_SERVER_CONTEXT_TYPE:\n case REACT_CONTEXT_TYPE:\n case REACT_FORWARD_REF_TYPE:\n case REACT_LAZY_TYPE:\n case REACT_MEMO_TYPE:\n case REACT_PROVIDER_TYPE:\n return $$typeofType;\n\n default:\n return $$typeof;\n }\n\n }\n\n case REACT_PORTAL_TYPE:\n return $$typeof;\n }\n }\n\n return undefined;\n}\nvar ContextConsumer = REACT_CONTEXT_TYPE;\nvar ContextProvider = REACT_PROVIDER_TYPE;\nvar Element = REACT_ELEMENT_TYPE;\nvar ForwardRef = REACT_FORWARD_REF_TYPE;\nvar Fragment = REACT_FRAGMENT_TYPE;\nvar Lazy = REACT_LAZY_TYPE;\nvar Memo = REACT_MEMO_TYPE;\nvar Portal = REACT_PORTAL_TYPE;\nvar Profiler = REACT_PROFILER_TYPE;\nvar StrictMode = REACT_STRICT_MODE_TYPE;\nvar Suspense = REACT_SUSPENSE_TYPE;\nvar SuspenseList = REACT_SUSPENSE_LIST_TYPE;\nvar hasWarnedAboutDeprecatedIsAsyncMode = false;\nvar hasWarnedAboutDeprecatedIsConcurrentMode = false; // AsyncMode should be deprecated\n\nfunction isAsyncMode(object) {\n {\n if (!hasWarnedAboutDeprecatedIsAsyncMode) {\n hasWarnedAboutDeprecatedIsAsyncMode = true; // Using console['warn'] to evade Babel and ESLint\n\n console['warn']('The ReactIs.isAsyncMode() alias has been deprecated, ' + 'and will be removed in React 18+.');\n }\n }\n\n return false;\n}\nfunction isConcurrentMode(object) {\n {\n if (!hasWarnedAboutDeprecatedIsConcurrentMode) {\n hasWarnedAboutDeprecatedIsConcurrentMode = true; // Using console['warn'] to evade Babel and ESLint\n\n console['warn']('The ReactIs.isConcurrentMode() alias has been deprecated, ' + 'and will be removed in React 18+.');\n }\n }\n\n return false;\n}\nfunction isContextConsumer(object) {\n return typeOf(object) === REACT_CONTEXT_TYPE;\n}\nfunction isContextProvider(object) {\n return typeOf(object) === REACT_PROVIDER_TYPE;\n}\nfunction isElement(object) {\n return typeof object === 'object' && object !== null && object.$$typeof === REACT_ELEMENT_TYPE;\n}\nfunction isForwardRef(object) {\n return typeOf(object) === REACT_FORWARD_REF_TYPE;\n}\nfunction isFragment(object) {\n return typeOf(object) === REACT_FRAGMENT_TYPE;\n}\nfunction isLazy(object) {\n return typeOf(object) === REACT_LAZY_TYPE;\n}\nfunction isMemo(object) {\n return typeOf(object) === REACT_MEMO_TYPE;\n}\nfunction isPortal(object) {\n return typeOf(object) === REACT_PORTAL_TYPE;\n}\nfunction isProfiler(object) {\n return typeOf(object) === REACT_PROFILER_TYPE;\n}\nfunction isStrictMode(object) {\n return typeOf(object) === REACT_STRICT_MODE_TYPE;\n}\nfunction isSuspense(object) {\n return typeOf(object) === REACT_SUSPENSE_TYPE;\n}\nfunction isSuspenseList(object) {\n return typeOf(object) === REACT_SUSPENSE_LIST_TYPE;\n}\n\nexports.ContextConsumer = ContextConsumer;\nexports.ContextProvider = ContextProvider;\nexports.Element = Element;\nexports.ForwardRef = ForwardRef;\nexports.Fragment = Fragment;\nexports.Lazy = Lazy;\nexports.Memo = Memo;\nexports.Portal = Portal;\nexports.Profiler = Profiler;\nexports.StrictMode = StrictMode;\nexports.Suspense = Suspense;\nexports.SuspenseList = SuspenseList;\nexports.isAsyncMode = isAsyncMode;\nexports.isConcurrentMode = isConcurrentMode;\nexports.isContextConsumer = isContextConsumer;\nexports.isContextProvider = isContextProvider;\nexports.isElement = isElement;\nexports.isForwardRef = isForwardRef;\nexports.isFragment = isFragment;\nexports.isLazy = isLazy;\nexports.isMemo = isMemo;\nexports.isPortal = isPortal;\nexports.isProfiler = isProfiler;\nexports.isStrictMode = isStrictMode;\nexports.isSuspense = isSuspense;\nexports.isSuspenseList = isSuspenseList;\nexports.isValidElementType = isValidElementType;\nexports.typeOf = typeOf;\n })();\n}\n","'use strict';\n\nif (process.env.NODE_ENV === 'production') {\n module.exports = require('./cjs/react-is.production.min.js');\n} else {\n module.exports = require('./cjs/react-is.development.js');\n}\n","import { ForwardRef, Memo } from 'react-is';\n\n// Simplified polyfill for IE11 support\n// https://github.com/JamesMGreene/Function.name/blob/58b314d4a983110c3682f1228f845d39ccca1817/Function.name.js#L3\nconst fnNameMatchRegex = /^\\s*function(?:\\s|\\s*\\/\\*.*\\*\\/\\s*)+([^(\\s/]*)\\s*/;\nexport function getFunctionName(fn) {\n const match = `${fn}`.match(fnNameMatchRegex);\n const name = match && match[1];\n return name || '';\n}\nfunction getFunctionComponentName(Component, fallback = '') {\n return Component.displayName || Component.name || getFunctionName(Component) || fallback;\n}\nfunction getWrappedName(outerType, innerType, wrapperName) {\n const functionName = getFunctionComponentName(innerType);\n return outerType.displayName || (functionName !== '' ? `${wrapperName}(${functionName})` : wrapperName);\n}\n\n/**\n * cherry-pick from\n * https://github.com/facebook/react/blob/769b1f270e1251d9dbdce0fcbd9e92e502d059b8/packages/shared/getComponentName.js\n * originally forked from recompose/getDisplayName with added IE11 support\n */\nexport default function getDisplayName(Component) {\n if (Component == null) {\n return undefined;\n }\n if (typeof Component === 'string') {\n return Component;\n }\n if (typeof Component === 'function') {\n return getFunctionComponentName(Component, 'Component');\n }\n\n // TypeScript can't have components as objects but they exist in the form of `memo` or `Suspense`\n if (typeof Component === 'object') {\n switch (Component.$$typeof) {\n case ForwardRef:\n return getWrappedName(Component, Component.render, 'ForwardRef');\n case Memo:\n return getWrappedName(Component, Component.type, 'memo');\n default:\n return undefined;\n }\n }\n return undefined;\n}","export default function HTMLElementType(props, propName, componentName, location, propFullName) {\n if (process.env.NODE_ENV === 'production') {\n return null;\n }\n const propValue = props[propName];\n const safePropName = propFullName || propName;\n if (propValue == null) {\n return null;\n }\n if (propValue && propValue.nodeType !== 1) {\n return new Error(`Invalid ${location} \\`${safePropName}\\` supplied to \\`${componentName}\\`. ` + `Expected an HTMLElement.`);\n }\n return null;\n}","import PropTypes from 'prop-types';\nconst refType = PropTypes.oneOfType([PropTypes.func, PropTypes.object]);\nexport default refType;","import _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\n// It should to be noted that this function isn't equivalent to `text-transform: capitalize`.\n//\n// A strict capitalization should uppercase the first letter of each word in the sentence.\n// We only handle the first word.\nexport default function capitalize(string) {\n if (typeof string !== 'string') {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: \\`capitalize(string)\\` expects a string argument.` : _formatMuiErrorMessage(7));\n }\n return string.charAt(0).toUpperCase() + string.slice(1);\n}","/**\n * Safe chained function.\n *\n * Will only create a new function if needed,\n * otherwise will pass back existing functions or null.\n */\nexport default function createChainedFunction(...funcs) {\n return funcs.reduce((acc, func) => {\n if (func == null) {\n return acc;\n }\n return function chainedFunction(...args) {\n acc.apply(this, args);\n func.apply(this, args);\n };\n }, () => {});\n}","// Corresponds to 10 frames at 60 Hz.\n// A few bytes payload overhead when lodash/debounce is ~3 kB and debounce ~300 B.\nexport default function debounce(func, wait = 166) {\n let timeout;\n function debounced(...args) {\n const later = () => {\n // @ts-ignore\n func.apply(this, args);\n };\n clearTimeout(timeout);\n timeout = setTimeout(later, wait);\n }\n debounced.clear = () => {\n clearTimeout(timeout);\n };\n return debounced;\n}","export default function deprecatedPropType(validator, reason) {\n if (process.env.NODE_ENV === 'production') {\n return () => null;\n }\n return (props, propName, componentName, location, propFullName) => {\n const componentNameSafe = componentName || '<>';\n const propFullNameSafe = propFullName || propName;\n if (typeof props[propName] !== 'undefined') {\n return new Error(`The ${location} \\`${propFullNameSafe}\\` of ` + `\\`${componentNameSafe}\\` is deprecated. ${reason}`);\n }\n return null;\n };\n}","import * as React from 'react';\nexport default function isMuiElement(element, muiNames) {\n var _muiName, _element$type;\n return /*#__PURE__*/React.isValidElement(element) && muiNames.indexOf( // For server components `muiName` is avaialble in element.type._payload.value.muiName\n // relevant info - https://github.com/facebook/react/blob/2807d781a08db8e9873687fccc25c0f12b4fb3d4/packages/react/src/ReactLazy.js#L45\n // eslint-disable-next-line no-underscore-dangle\n (_muiName = element.type.muiName) != null ? _muiName : (_element$type = element.type) == null || (_element$type = _element$type._payload) == null || (_element$type = _element$type.value) == null ? void 0 : _element$type.muiName) !== -1;\n}","export default function ownerDocument(node) {\n return node && node.ownerDocument || document;\n}","import ownerDocument from '../ownerDocument';\nexport default function ownerWindow(node) {\n const doc = ownerDocument(node);\n return doc.defaultView || window;\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nexport default function requirePropFactory(componentNameInError, Component) {\n if (process.env.NODE_ENV === 'production') {\n return () => null;\n }\n\n // eslint-disable-next-line react/forbid-foreign-prop-types\n const prevPropTypes = Component ? _extends({}, Component.propTypes) : null;\n const requireProp = requiredProp => (props, propName, componentName, location, propFullName, ...args) => {\n const propFullNameSafe = propFullName || propName;\n const defaultTypeChecker = prevPropTypes == null ? void 0 : prevPropTypes[propFullNameSafe];\n if (defaultTypeChecker) {\n const typeCheckerResult = defaultTypeChecker(props, propName, componentName, location, propFullName, ...args);\n if (typeCheckerResult) {\n return typeCheckerResult;\n }\n }\n if (typeof props[propName] !== 'undefined' && !props[requiredProp]) {\n return new Error(`The prop \\`${propFullNameSafe}\\` of ` + `\\`${componentNameInError}\\` can only be used together with the \\`${requiredProp}\\` prop.`);\n }\n return null;\n };\n return requireProp;\n}","/**\n * TODO v5: consider making it private\n *\n * passes {value} to {ref}\n *\n * WARNING: Be sure to only call this inside a callback that is passed as a ref.\n * Otherwise, make sure to cleanup the previous {ref} if it changes. See\n * https://github.com/mui/material-ui/issues/13539\n *\n * Useful if you want to expose the ref of an inner component to the public API\n * while still using it inside the component.\n * @param ref A ref callback or ref object. If anything falsy, this is a no-op.\n */\nexport default function setRef(ref, value) {\n if (typeof ref === 'function') {\n ref(value);\n } else if (ref) {\n ref.current = value;\n }\n}","'use client';\n\nimport * as React from 'react';\n\n/**\n * A version of `React.useLayoutEffect` that does not show a warning when server-side rendering.\n * This is useful for effects that are only needed for client-side rendering but not for SSR.\n *\n * Before you use this hook, make sure to read https://gist.github.com/gaearon/e7d97cdf38a2907924ea12e4ebdf3c85\n * and confirm it doesn't apply to your use-case.\n */\nconst useEnhancedEffect = typeof window !== 'undefined' ? React.useLayoutEffect : React.useEffect;\nexport default useEnhancedEffect;","'use client';\n\nimport * as React from 'react';\nlet globalId = 0;\nfunction useGlobalId(idOverride) {\n const [defaultId, setDefaultId] = React.useState(idOverride);\n const id = idOverride || defaultId;\n React.useEffect(() => {\n if (defaultId == null) {\n // Fallback to this default id when possible.\n // Use the incrementing value for client-side rendering only.\n // We can't use it server-side.\n // If you want to use random values please consider the Birthday Problem: https://en.wikipedia.org/wiki/Birthday_problem\n globalId += 1;\n setDefaultId(`mui-${globalId}`);\n }\n }, [defaultId]);\n return id;\n}\n\n// downstream bundlers may remove unnecessary concatenation, but won't remove toString call -- Workaround for https://github.com/webpack/webpack/issues/14814\nconst maybeReactUseId = React['useId'.toString()];\n/**\n *\n * @example
    \n * @param idOverride\n * @returns {string}\n */\nexport default function useId(idOverride) {\n if (maybeReactUseId !== undefined) {\n const reactId = maybeReactUseId();\n return idOverride != null ? idOverride : reactId;\n }\n // eslint-disable-next-line react-hooks/rules-of-hooks -- `React.useId` is invariant at runtime.\n return useGlobalId(idOverride);\n}","export default function unsupportedProp(props, propName, componentName, location, propFullName) {\n if (process.env.NODE_ENV === 'production') {\n return null;\n }\n const propFullNameSafe = propFullName || propName;\n if (typeof props[propName] !== 'undefined') {\n return new Error(`The prop \\`${propFullNameSafe}\\` is not supported. Please remove it.`);\n }\n return null;\n}","'use client';\n\n/* eslint-disable react-hooks/rules-of-hooks, react-hooks/exhaustive-deps */\nimport * as React from 'react';\nexport default function useControlled({\n controlled,\n default: defaultProp,\n name,\n state = 'value'\n}) {\n // isControlled is ignored in the hook dependency lists as it should never change.\n const {\n current: isControlled\n } = React.useRef(controlled !== undefined);\n const [valueState, setValue] = React.useState(defaultProp);\n const value = isControlled ? controlled : valueState;\n if (process.env.NODE_ENV !== 'production') {\n React.useEffect(() => {\n if (isControlled !== (controlled !== undefined)) {\n console.error([`MUI: A component is changing the ${isControlled ? '' : 'un'}controlled ${state} state of ${name} to be ${isControlled ? 'un' : ''}controlled.`, 'Elements should not switch from uncontrolled to controlled (or vice versa).', `Decide between using a controlled or uncontrolled ${name} ` + 'element for the lifetime of the component.', \"The nature of the state is determined during the first render. It's considered controlled if the value is not `undefined`.\", 'More info: https://fb.me/react-controlled-components'].join('\\n'));\n }\n }, [state, name, controlled]);\n const {\n current: defaultValue\n } = React.useRef(defaultProp);\n React.useEffect(() => {\n if (!isControlled && defaultValue !== defaultProp) {\n console.error([`MUI: A component is changing the default ${state} state of an uncontrolled ${name} after being initialized. ` + `To suppress this warning opt to use a controlled ${name}.`].join('\\n'));\n }\n }, [JSON.stringify(defaultProp)]);\n }\n const setValueIfUncontrolled = React.useCallback(newValue => {\n if (!isControlled) {\n setValue(newValue);\n }\n }, []);\n return [value, setValueIfUncontrolled];\n}","'use client';\n\nimport * as React from 'react';\nimport useEnhancedEffect from '../useEnhancedEffect';\n\n/**\n * Inspired by https://github.com/facebook/react/issues/14099#issuecomment-440013892\n * See RFC in https://github.com/reactjs/rfcs/pull/220\n */\n\nfunction useEventCallback(fn) {\n const ref = React.useRef(fn);\n useEnhancedEffect(() => {\n ref.current = fn;\n });\n return React.useRef((...args) =>\n // @ts-expect-error hide `this`\n (0, ref.current)(...args)).current;\n}\nexport default useEventCallback;","'use client';\n\nimport * as React from 'react';\nimport setRef from '../setRef';\nexport default function useForkRef(...refs) {\n /**\n * This will create a new function if the refs passed to this hook change and are all defined.\n * This means react will call the old forkRef with `null` and the new forkRef\n * with the ref. Cleanup naturally emerges from this behavior.\n */\n return React.useMemo(() => {\n if (refs.every(ref => ref == null)) {\n return null;\n }\n return instance => {\n refs.forEach(ref => {\n setRef(ref, instance);\n });\n };\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, refs);\n}","'use client';\n\nimport * as React from 'react';\nconst UNINITIALIZED = {};\n\n/**\n * A React.useRef() that is initialized lazily with a function. Note that it accepts an optional\n * initialization argument, so the initialization function doesn't need to be an inline closure.\n *\n * @usage\n * const ref = useLazyRef(sortColumns, columns)\n */\nexport default function useLazyRef(init, initArg) {\n const ref = React.useRef(UNINITIALIZED);\n if (ref.current === UNINITIALIZED) {\n ref.current = init(initArg);\n }\n return ref;\n}","'use client';\n\nimport * as React from 'react';\nconst EMPTY = [];\n\n/**\n * A React.useEffect equivalent that runs once, when the component is mounted.\n */\nexport default function useOnMount(fn) {\n /* eslint-disable react-hooks/exhaustive-deps */\n React.useEffect(fn, EMPTY);\n /* eslint-enable react-hooks/exhaustive-deps */\n}","'use client';\n\nimport useLazyRef from '../useLazyRef/useLazyRef';\nimport useOnMount from '../useOnMount/useOnMount';\nexport class Timeout {\n constructor() {\n this.currentId = null;\n this.clear = () => {\n if (this.currentId !== null) {\n clearTimeout(this.currentId);\n this.currentId = null;\n }\n };\n this.disposeEffect = () => {\n return this.clear;\n };\n }\n static create() {\n return new Timeout();\n }\n /**\n * Executes `fn` after `delay`, clearing any previously scheduled call.\n */\n start(delay, fn) {\n this.clear();\n this.currentId = setTimeout(() => {\n this.currentId = null;\n fn();\n }, delay);\n }\n}\nexport default function useTimeout() {\n const timeout = useLazyRef(Timeout.create).current;\n useOnMount(timeout.disposeEffect);\n return timeout;\n}","'use client';\n\n// based on https://github.com/WICG/focus-visible/blob/v4.1.5/src/focus-visible.js\nimport * as React from 'react';\nimport { Timeout } from '../useTimeout/useTimeout';\nlet hadKeyboardEvent = true;\nlet hadFocusVisibleRecently = false;\nconst hadFocusVisibleRecentlyTimeout = new Timeout();\nconst inputTypesWhitelist = {\n text: true,\n search: true,\n url: true,\n tel: true,\n email: true,\n password: true,\n number: true,\n date: true,\n month: true,\n week: true,\n time: true,\n datetime: true,\n 'datetime-local': true\n};\n\n/**\n * Computes whether the given element should automatically trigger the\n * `focus-visible` class being added, i.e. whether it should always match\n * `:focus-visible` when focused.\n * @param {Element} node\n * @returns {boolean}\n */\nfunction focusTriggersKeyboardModality(node) {\n const {\n type,\n tagName\n } = node;\n if (tagName === 'INPUT' && inputTypesWhitelist[type] && !node.readOnly) {\n return true;\n }\n if (tagName === 'TEXTAREA' && !node.readOnly) {\n return true;\n }\n if (node.isContentEditable) {\n return true;\n }\n return false;\n}\n\n/**\n * Keep track of our keyboard modality state with `hadKeyboardEvent`.\n * If the most recent user interaction was via the keyboard;\n * and the key press did not include a meta, alt/option, or control key;\n * then the modality is keyboard. Otherwise, the modality is not keyboard.\n * @param {KeyboardEvent} event\n */\nfunction handleKeyDown(event) {\n if (event.metaKey || event.altKey || event.ctrlKey) {\n return;\n }\n hadKeyboardEvent = true;\n}\n\n/**\n * If at any point a user clicks with a pointing device, ensure that we change\n * the modality away from keyboard.\n * This avoids the situation where a user presses a key on an already focused\n * element, and then clicks on a different element, focusing it with a\n * pointing device, while we still think we're in keyboard modality.\n */\nfunction handlePointerDown() {\n hadKeyboardEvent = false;\n}\nfunction handleVisibilityChange() {\n if (this.visibilityState === 'hidden') {\n // If the tab becomes active again, the browser will handle calling focus\n // on the element (Safari actually calls it twice).\n // If this tab change caused a blur on an element with focus-visible,\n // re-apply the class when the user switches back to the tab.\n if (hadFocusVisibleRecently) {\n hadKeyboardEvent = true;\n }\n }\n}\nfunction prepare(doc) {\n doc.addEventListener('keydown', handleKeyDown, true);\n doc.addEventListener('mousedown', handlePointerDown, true);\n doc.addEventListener('pointerdown', handlePointerDown, true);\n doc.addEventListener('touchstart', handlePointerDown, true);\n doc.addEventListener('visibilitychange', handleVisibilityChange, true);\n}\nexport function teardown(doc) {\n doc.removeEventListener('keydown', handleKeyDown, true);\n doc.removeEventListener('mousedown', handlePointerDown, true);\n doc.removeEventListener('pointerdown', handlePointerDown, true);\n doc.removeEventListener('touchstart', handlePointerDown, true);\n doc.removeEventListener('visibilitychange', handleVisibilityChange, true);\n}\nfunction isFocusVisible(event) {\n const {\n target\n } = event;\n try {\n return target.matches(':focus-visible');\n } catch (error) {\n // Browsers not implementing :focus-visible will throw a SyntaxError.\n // We use our own heuristic for those browsers.\n // Rethrow might be better if it's not the expected error but do we really\n // want to crash if focus-visible malfunctioned?\n }\n\n // No need for validFocusTarget check. The user does that by attaching it to\n // focusable events only.\n return hadKeyboardEvent || focusTriggersKeyboardModality(target);\n}\nexport default function useIsFocusVisible() {\n const ref = React.useCallback(node => {\n if (node != null) {\n prepare(node.ownerDocument);\n }\n }, []);\n const isFocusVisibleRef = React.useRef(false);\n\n /**\n * Should be called if a blur event is fired\n */\n function handleBlurVisible() {\n // checking against potential state variable does not suffice if we focus and blur synchronously.\n // React wouldn't have time to trigger a re-render so `focusVisible` would be stale.\n // Ideally we would adjust `isFocusVisible(event)` to look at `relatedTarget` for blur events.\n // This doesn't work in IE11 due to https://github.com/facebook/react/issues/3751\n // TODO: check again if React releases their internal changes to focus event handling (https://github.com/facebook/react/pull/19186).\n if (isFocusVisibleRef.current) {\n // To detect a tab/window switch, we look for a blur event followed\n // rapidly by a visibility change.\n // If we don't see a visibility change within 100ms, it's probably a\n // regular focus change.\n hadFocusVisibleRecently = true;\n hadFocusVisibleRecentlyTimeout.start(100, () => {\n hadFocusVisibleRecently = false;\n });\n isFocusVisibleRef.current = false;\n return true;\n }\n return false;\n }\n\n /**\n * Should be called if a blur event is fired\n */\n function handleFocusVisible(event) {\n if (isFocusVisible(event)) {\n isFocusVisibleRef.current = true;\n return true;\n }\n return false;\n }\n return {\n isFocusVisibleRef,\n onFocus: handleFocusVisible,\n onBlur: handleBlurVisible,\n ref\n };\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\n/**\n * Add keys, values of `defaultProps` that does not exist in `props`\n * @param {object} defaultProps\n * @param {object} props\n * @returns {object} resolved props\n */\nexport default function resolveProps(defaultProps, props) {\n const output = _extends({}, props);\n Object.keys(defaultProps).forEach(propName => {\n if (propName.toString().match(/^(components|slots)$/)) {\n output[propName] = _extends({}, defaultProps[propName], output[propName]);\n } else if (propName.toString().match(/^(componentsProps|slotProps)$/)) {\n const defaultSlotProps = defaultProps[propName] || {};\n const slotProps = props[propName];\n output[propName] = {};\n if (!slotProps || !Object.keys(slotProps)) {\n // Reduce the iteration if the slot props is empty\n output[propName] = defaultSlotProps;\n } else if (!defaultSlotProps || !Object.keys(defaultSlotProps)) {\n // Reduce the iteration if the default slot props is empty\n output[propName] = slotProps;\n } else {\n output[propName] = _extends({}, slotProps);\n Object.keys(defaultSlotProps).forEach(slotPropName => {\n output[propName][slotPropName] = resolveProps(defaultSlotProps[slotPropName], slotProps[slotPropName]);\n });\n }\n } else if (output[propName] === undefined) {\n output[propName] = defaultProps[propName];\n }\n });\n return output;\n}","export default function composeClasses(slots, getUtilityClass, classes = undefined) {\n const output = {};\n Object.keys(slots).forEach(\n // `Object.keys(slots)` can't be wider than `T` because we infer `T` from `slots`.\n // @ts-expect-error https://github.com/microsoft/TypeScript/pull/12253#issuecomment-263132208\n slot => {\n output[slot] = slots[slot].reduce((acc, key) => {\n if (key) {\n const utilityClass = getUtilityClass(key);\n if (utilityClass !== '') {\n acc.push(utilityClass);\n }\n if (classes && classes[key]) {\n acc.push(classes[key]);\n }\n }\n return acc;\n }, []).join(' ');\n });\n return output;\n}","const defaultGenerator = componentName => componentName;\nconst createClassNameGenerator = () => {\n let generate = defaultGenerator;\n return {\n configure(generator) {\n generate = generator;\n },\n generate(componentName) {\n return generate(componentName);\n },\n reset() {\n generate = defaultGenerator;\n }\n };\n};\nconst ClassNameGenerator = createClassNameGenerator();\nexport default ClassNameGenerator;","import ClassNameGenerator from '../ClassNameGenerator';\nexport const globalStateClasses = {\n active: 'active',\n checked: 'checked',\n completed: 'completed',\n disabled: 'disabled',\n error: 'error',\n expanded: 'expanded',\n focused: 'focused',\n focusVisible: 'focusVisible',\n open: 'open',\n readOnly: 'readOnly',\n required: 'required',\n selected: 'selected'\n};\nexport default function generateUtilityClass(componentName, slot, globalStatePrefix = 'Mui') {\n const globalStateClass = globalStateClasses[slot];\n return globalStateClass ? `${globalStatePrefix}-${globalStateClass}` : `${ClassNameGenerator.generate(componentName)}-${slot}`;\n}\nexport function isGlobalState(slot) {\n return globalStateClasses[slot] !== undefined;\n}","import generateUtilityClass from '../generateUtilityClass';\nexport default function generateUtilityClasses(componentName, slots, globalStatePrefix = 'Mui') {\n const result = {};\n slots.forEach(slot => {\n result[slot] = generateUtilityClass(componentName, slot, globalStatePrefix);\n });\n return result;\n}","function clamp(val, min = Number.MIN_SAFE_INTEGER, max = Number.MAX_SAFE_INTEGER) {\n return Math.max(min, Math.min(val, max));\n}\nexport default clamp;","export default function _objectWithoutPropertiesLoose(source, excluded) {\n if (source == null) return {};\n var target = {};\n var sourceKeys = Object.keys(source);\n var key, i;\n for (i = 0; i < sourceKeys.length; i++) {\n key = sourceKeys[i];\n if (excluded.indexOf(key) >= 0) continue;\n target[key] = source[key];\n }\n return target;\n}","import _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nconst _excluded = [\"values\", \"unit\", \"step\"];\n// Sorted ASC by size. That's important.\n// It can't be configured as it's used statically for propTypes.\nexport const breakpointKeys = ['xs', 'sm', 'md', 'lg', 'xl'];\nconst sortBreakpointsValues = values => {\n const breakpointsAsArray = Object.keys(values).map(key => ({\n key,\n val: values[key]\n })) || [];\n // Sort in ascending order\n breakpointsAsArray.sort((breakpoint1, breakpoint2) => breakpoint1.val - breakpoint2.val);\n return breakpointsAsArray.reduce((acc, obj) => {\n return _extends({}, acc, {\n [obj.key]: obj.val\n });\n }, {});\n};\n\n// Keep in mind that @media is inclusive by the CSS specification.\nexport default function createBreakpoints(breakpoints) {\n const {\n // The breakpoint **start** at this value.\n // For instance with the first breakpoint xs: [xs, sm).\n values = {\n xs: 0,\n // phone\n sm: 600,\n // tablet\n md: 900,\n // small laptop\n lg: 1200,\n // desktop\n xl: 1536 // large screen\n },\n unit = 'px',\n step = 5\n } = breakpoints,\n other = _objectWithoutPropertiesLoose(breakpoints, _excluded);\n const sortedValues = sortBreakpointsValues(values);\n const keys = Object.keys(sortedValues);\n function up(key) {\n const value = typeof values[key] === 'number' ? values[key] : key;\n return `@media (min-width:${value}${unit})`;\n }\n function down(key) {\n const value = typeof values[key] === 'number' ? values[key] : key;\n return `@media (max-width:${value - step / 100}${unit})`;\n }\n function between(start, end) {\n const endIndex = keys.indexOf(end);\n return `@media (min-width:${typeof values[start] === 'number' ? values[start] : start}${unit}) and ` + `(max-width:${(endIndex !== -1 && typeof values[keys[endIndex]] === 'number' ? values[keys[endIndex]] : end) - step / 100}${unit})`;\n }\n function only(key) {\n if (keys.indexOf(key) + 1 < keys.length) {\n return between(key, keys[keys.indexOf(key) + 1]);\n }\n return up(key);\n }\n function not(key) {\n // handle first and last key separately, for better readability\n const keyIndex = keys.indexOf(key);\n if (keyIndex === 0) {\n return up(keys[1]);\n }\n if (keyIndex === keys.length - 1) {\n return down(keys[keyIndex]);\n }\n return between(key, keys[keys.indexOf(key) + 1]).replace('@media', '@media not all and');\n }\n return _extends({\n keys,\n values: sortedValues,\n up,\n down,\n between,\n only,\n not,\n unit\n }, other);\n}","const shape = {\n borderRadius: 4\n};\nexport default shape;","import PropTypes from 'prop-types';\nconst responsivePropType = process.env.NODE_ENV !== 'production' ? PropTypes.oneOfType([PropTypes.number, PropTypes.string, PropTypes.object, PropTypes.array]) : {};\nexport default responsivePropType;","import deepmerge from '@mui/utils/deepmerge';\nfunction merge(acc, item) {\n if (!item) {\n return acc;\n }\n return deepmerge(acc, item, {\n clone: false // No need to clone deep, it's way faster.\n });\n}\nexport default merge;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport PropTypes from 'prop-types';\nimport deepmerge from '@mui/utils/deepmerge';\nimport merge from './merge';\n\n// The breakpoint **start** at this value.\n// For instance with the first breakpoint xs: [xs, sm[.\nexport const values = {\n xs: 0,\n // phone\n sm: 600,\n // tablet\n md: 900,\n // small laptop\n lg: 1200,\n // desktop\n xl: 1536 // large screen\n};\nconst defaultBreakpoints = {\n // Sorted ASC by size. That's important.\n // It can't be configured as it's used statically for propTypes.\n keys: ['xs', 'sm', 'md', 'lg', 'xl'],\n up: key => `@media (min-width:${values[key]}px)`\n};\nexport function handleBreakpoints(props, propValue, styleFromPropValue) {\n const theme = props.theme || {};\n if (Array.isArray(propValue)) {\n const themeBreakpoints = theme.breakpoints || defaultBreakpoints;\n return propValue.reduce((acc, item, index) => {\n acc[themeBreakpoints.up(themeBreakpoints.keys[index])] = styleFromPropValue(propValue[index]);\n return acc;\n }, {});\n }\n if (typeof propValue === 'object') {\n const themeBreakpoints = theme.breakpoints || defaultBreakpoints;\n return Object.keys(propValue).reduce((acc, breakpoint) => {\n // key is breakpoint\n if (Object.keys(themeBreakpoints.values || values).indexOf(breakpoint) !== -1) {\n const mediaKey = themeBreakpoints.up(breakpoint);\n acc[mediaKey] = styleFromPropValue(propValue[breakpoint], breakpoint);\n } else {\n const cssKey = breakpoint;\n acc[cssKey] = propValue[cssKey];\n }\n return acc;\n }, {});\n }\n const output = styleFromPropValue(propValue);\n return output;\n}\nfunction breakpoints(styleFunction) {\n // false positive\n // eslint-disable-next-line react/function-component-definition\n const newStyleFunction = props => {\n const theme = props.theme || {};\n const base = styleFunction(props);\n const themeBreakpoints = theme.breakpoints || defaultBreakpoints;\n const extended = themeBreakpoints.keys.reduce((acc, key) => {\n if (props[key]) {\n acc = acc || {};\n acc[themeBreakpoints.up(key)] = styleFunction(_extends({\n theme\n }, props[key]));\n }\n return acc;\n }, null);\n return merge(base, extended);\n };\n newStyleFunction.propTypes = process.env.NODE_ENV !== 'production' ? _extends({}, styleFunction.propTypes, {\n xs: PropTypes.object,\n sm: PropTypes.object,\n md: PropTypes.object,\n lg: PropTypes.object,\n xl: PropTypes.object\n }) : {};\n newStyleFunction.filterProps = ['xs', 'sm', 'md', 'lg', 'xl', ...styleFunction.filterProps];\n return newStyleFunction;\n}\nexport function createEmptyBreakpointObject(breakpointsInput = {}) {\n var _breakpointsInput$key;\n const breakpointsInOrder = (_breakpointsInput$key = breakpointsInput.keys) == null ? void 0 : _breakpointsInput$key.reduce((acc, key) => {\n const breakpointStyleKey = breakpointsInput.up(key);\n acc[breakpointStyleKey] = {};\n return acc;\n }, {});\n return breakpointsInOrder || {};\n}\nexport function removeUnusedBreakpoints(breakpointKeys, style) {\n return breakpointKeys.reduce((acc, key) => {\n const breakpointOutput = acc[key];\n const isBreakpointUnused = !breakpointOutput || Object.keys(breakpointOutput).length === 0;\n if (isBreakpointUnused) {\n delete acc[key];\n }\n return acc;\n }, style);\n}\nexport function mergeBreakpointsInOrder(breakpointsInput, ...styles) {\n const emptyBreakpoints = createEmptyBreakpointObject(breakpointsInput);\n const mergedOutput = [emptyBreakpoints, ...styles].reduce((prev, next) => deepmerge(prev, next), {});\n return removeUnusedBreakpoints(Object.keys(emptyBreakpoints), mergedOutput);\n}\n\n// compute base for responsive values; e.g.,\n// [1,2,3] => {xs: true, sm: true, md: true}\n// {xs: 1, sm: 2, md: 3} => {xs: true, sm: true, md: true}\nexport function computeBreakpointsBase(breakpointValues, themeBreakpoints) {\n // fixed value\n if (typeof breakpointValues !== 'object') {\n return {};\n }\n const base = {};\n const breakpointsKeys = Object.keys(themeBreakpoints);\n if (Array.isArray(breakpointValues)) {\n breakpointsKeys.forEach((breakpoint, i) => {\n if (i < breakpointValues.length) {\n base[breakpoint] = true;\n }\n });\n } else {\n breakpointsKeys.forEach(breakpoint => {\n if (breakpointValues[breakpoint] != null) {\n base[breakpoint] = true;\n }\n });\n }\n return base;\n}\nexport function resolveBreakpointValues({\n values: breakpointValues,\n breakpoints: themeBreakpoints,\n base: customBase\n}) {\n const base = customBase || computeBreakpointsBase(breakpointValues, themeBreakpoints);\n const keys = Object.keys(base);\n if (keys.length === 0) {\n return breakpointValues;\n }\n let previous;\n return keys.reduce((acc, breakpoint, i) => {\n if (Array.isArray(breakpointValues)) {\n acc[breakpoint] = breakpointValues[i] != null ? breakpointValues[i] : breakpointValues[previous];\n previous = i;\n } else if (typeof breakpointValues === 'object') {\n acc[breakpoint] = breakpointValues[breakpoint] != null ? breakpointValues[breakpoint] : breakpointValues[previous];\n previous = breakpoint;\n } else {\n acc[breakpoint] = breakpointValues;\n }\n return acc;\n }, {});\n}\nexport default breakpoints;","import capitalize from '@mui/utils/capitalize';\nimport responsivePropType from './responsivePropType';\nimport { handleBreakpoints } from './breakpoints';\nexport function getPath(obj, path, checkVars = true) {\n if (!path || typeof path !== 'string') {\n return null;\n }\n\n // Check if CSS variables are used\n if (obj && obj.vars && checkVars) {\n const val = `vars.${path}`.split('.').reduce((acc, item) => acc && acc[item] ? acc[item] : null, obj);\n if (val != null) {\n return val;\n }\n }\n return path.split('.').reduce((acc, item) => {\n if (acc && acc[item] != null) {\n return acc[item];\n }\n return null;\n }, obj);\n}\nexport function getStyleValue(themeMapping, transform, propValueFinal, userValue = propValueFinal) {\n let value;\n if (typeof themeMapping === 'function') {\n value = themeMapping(propValueFinal);\n } else if (Array.isArray(themeMapping)) {\n value = themeMapping[propValueFinal] || userValue;\n } else {\n value = getPath(themeMapping, propValueFinal) || userValue;\n }\n if (transform) {\n value = transform(value, userValue, themeMapping);\n }\n return value;\n}\nfunction style(options) {\n const {\n prop,\n cssProperty = options.prop,\n themeKey,\n transform\n } = options;\n\n // false positive\n // eslint-disable-next-line react/function-component-definition\n const fn = props => {\n if (props[prop] == null) {\n return null;\n }\n const propValue = props[prop];\n const theme = props.theme;\n const themeMapping = getPath(theme, themeKey) || {};\n const styleFromPropValue = propValueFinal => {\n let value = getStyleValue(themeMapping, transform, propValueFinal);\n if (propValueFinal === value && typeof propValueFinal === 'string') {\n // Haven't found value\n value = getStyleValue(themeMapping, transform, `${prop}${propValueFinal === 'default' ? '' : capitalize(propValueFinal)}`, propValueFinal);\n }\n if (cssProperty === false) {\n return value;\n }\n return {\n [cssProperty]: value\n };\n };\n return handleBreakpoints(props, propValue, styleFromPropValue);\n };\n fn.propTypes = process.env.NODE_ENV !== 'production' ? {\n [prop]: responsivePropType\n } : {};\n fn.filterProps = [prop];\n return fn;\n}\nexport default style;","export default function memoize(fn) {\n const cache = {};\n return arg => {\n if (cache[arg] === undefined) {\n cache[arg] = fn(arg);\n }\n return cache[arg];\n };\n}","import responsivePropType from './responsivePropType';\nimport { handleBreakpoints } from './breakpoints';\nimport { getPath } from './style';\nimport merge from './merge';\nimport memoize from './memoize';\nconst properties = {\n m: 'margin',\n p: 'padding'\n};\nconst directions = {\n t: 'Top',\n r: 'Right',\n b: 'Bottom',\n l: 'Left',\n x: ['Left', 'Right'],\n y: ['Top', 'Bottom']\n};\nconst aliases = {\n marginX: 'mx',\n marginY: 'my',\n paddingX: 'px',\n paddingY: 'py'\n};\n\n// memoize() impact:\n// From 300,000 ops/sec\n// To 350,000 ops/sec\nconst getCssProperties = memoize(prop => {\n // It's not a shorthand notation.\n if (prop.length > 2) {\n if (aliases[prop]) {\n prop = aliases[prop];\n } else {\n return [prop];\n }\n }\n const [a, b] = prop.split('');\n const property = properties[a];\n const direction = directions[b] || '';\n return Array.isArray(direction) ? direction.map(dir => property + dir) : [property + direction];\n});\nexport const marginKeys = ['m', 'mt', 'mr', 'mb', 'ml', 'mx', 'my', 'margin', 'marginTop', 'marginRight', 'marginBottom', 'marginLeft', 'marginX', 'marginY', 'marginInline', 'marginInlineStart', 'marginInlineEnd', 'marginBlock', 'marginBlockStart', 'marginBlockEnd'];\nexport const paddingKeys = ['p', 'pt', 'pr', 'pb', 'pl', 'px', 'py', 'padding', 'paddingTop', 'paddingRight', 'paddingBottom', 'paddingLeft', 'paddingX', 'paddingY', 'paddingInline', 'paddingInlineStart', 'paddingInlineEnd', 'paddingBlock', 'paddingBlockStart', 'paddingBlockEnd'];\nconst spacingKeys = [...marginKeys, ...paddingKeys];\nexport function createUnaryUnit(theme, themeKey, defaultValue, propName) {\n var _getPath;\n const themeSpacing = (_getPath = getPath(theme, themeKey, false)) != null ? _getPath : defaultValue;\n if (typeof themeSpacing === 'number') {\n return abs => {\n if (typeof abs === 'string') {\n return abs;\n }\n if (process.env.NODE_ENV !== 'production') {\n if (typeof abs !== 'number') {\n console.error(`MUI: Expected ${propName} argument to be a number or a string, got ${abs}.`);\n }\n }\n return themeSpacing * abs;\n };\n }\n if (Array.isArray(themeSpacing)) {\n return abs => {\n if (typeof abs === 'string') {\n return abs;\n }\n if (process.env.NODE_ENV !== 'production') {\n if (!Number.isInteger(abs)) {\n console.error([`MUI: The \\`theme.${themeKey}\\` array type cannot be combined with non integer values.` + `You should either use an integer value that can be used as index, or define the \\`theme.${themeKey}\\` as a number.`].join('\\n'));\n } else if (abs > themeSpacing.length - 1) {\n console.error([`MUI: The value provided (${abs}) overflows.`, `The supported values are: ${JSON.stringify(themeSpacing)}.`, `${abs} > ${themeSpacing.length - 1}, you need to add the missing values.`].join('\\n'));\n }\n }\n return themeSpacing[abs];\n };\n }\n if (typeof themeSpacing === 'function') {\n return themeSpacing;\n }\n if (process.env.NODE_ENV !== 'production') {\n console.error([`MUI: The \\`theme.${themeKey}\\` value (${themeSpacing}) is invalid.`, 'It should be a number, an array or a function.'].join('\\n'));\n }\n return () => undefined;\n}\nexport function createUnarySpacing(theme) {\n return createUnaryUnit(theme, 'spacing', 8, 'spacing');\n}\nexport function getValue(transformer, propValue) {\n if (typeof propValue === 'string' || propValue == null) {\n return propValue;\n }\n const abs = Math.abs(propValue);\n const transformed = transformer(abs);\n if (propValue >= 0) {\n return transformed;\n }\n if (typeof transformed === 'number') {\n return -transformed;\n }\n return `-${transformed}`;\n}\nexport function getStyleFromPropValue(cssProperties, transformer) {\n return propValue => cssProperties.reduce((acc, cssProperty) => {\n acc[cssProperty] = getValue(transformer, propValue);\n return acc;\n }, {});\n}\nfunction resolveCssProperty(props, keys, prop, transformer) {\n // Using a hash computation over an array iteration could be faster, but with only 28 items,\n // it's doesn't worth the bundle size.\n if (keys.indexOf(prop) === -1) {\n return null;\n }\n const cssProperties = getCssProperties(prop);\n const styleFromPropValue = getStyleFromPropValue(cssProperties, transformer);\n const propValue = props[prop];\n return handleBreakpoints(props, propValue, styleFromPropValue);\n}\nfunction style(props, keys) {\n const transformer = createUnarySpacing(props.theme);\n return Object.keys(props).map(prop => resolveCssProperty(props, keys, prop, transformer)).reduce(merge, {});\n}\nexport function margin(props) {\n return style(props, marginKeys);\n}\nmargin.propTypes = process.env.NODE_ENV !== 'production' ? marginKeys.reduce((obj, key) => {\n obj[key] = responsivePropType;\n return obj;\n}, {}) : {};\nmargin.filterProps = marginKeys;\nexport function padding(props) {\n return style(props, paddingKeys);\n}\npadding.propTypes = process.env.NODE_ENV !== 'production' ? paddingKeys.reduce((obj, key) => {\n obj[key] = responsivePropType;\n return obj;\n}, {}) : {};\npadding.filterProps = paddingKeys;\nfunction spacing(props) {\n return style(props, spacingKeys);\n}\nspacing.propTypes = process.env.NODE_ENV !== 'production' ? spacingKeys.reduce((obj, key) => {\n obj[key] = responsivePropType;\n return obj;\n}, {}) : {};\nspacing.filterProps = spacingKeys;\nexport default spacing;","import { createUnarySpacing } from '../spacing';\n\n// The different signatures imply different meaning for their arguments that can't be expressed structurally.\n// We express the difference with variable names.\n\nexport default function createSpacing(spacingInput = 8) {\n // Already transformed.\n if (spacingInput.mui) {\n return spacingInput;\n }\n\n // Material Design layouts are visually balanced. Most measurements align to an 8dp grid, which aligns both spacing and the overall layout.\n // Smaller components, such as icons, can align to a 4dp grid.\n // https://m2.material.io/design/layout/understanding-layout.html\n const transform = createUnarySpacing({\n spacing: spacingInput\n });\n const spacing = (...argsInput) => {\n if (process.env.NODE_ENV !== 'production') {\n if (!(argsInput.length <= 4)) {\n console.error(`MUI: Too many arguments provided, expected between 0 and 4, got ${argsInput.length}`);\n }\n }\n const args = argsInput.length === 0 ? [1] : argsInput;\n return args.map(argument => {\n const output = transform(argument);\n return typeof output === 'number' ? `${output}px` : output;\n }).join(' ');\n };\n spacing.mui = true;\n return spacing;\n}","import merge from './merge';\nfunction compose(...styles) {\n const handlers = styles.reduce((acc, style) => {\n style.filterProps.forEach(prop => {\n acc[prop] = style;\n });\n return acc;\n }, {});\n\n // false positive\n // eslint-disable-next-line react/function-component-definition\n const fn = props => {\n return Object.keys(props).reduce((acc, prop) => {\n if (handlers[prop]) {\n return merge(acc, handlers[prop](props));\n }\n return acc;\n }, {});\n };\n fn.propTypes = process.env.NODE_ENV !== 'production' ? styles.reduce((acc, style) => Object.assign(acc, style.propTypes), {}) : {};\n fn.filterProps = styles.reduce((acc, style) => acc.concat(style.filterProps), []);\n return fn;\n}\nexport default compose;","import responsivePropType from './responsivePropType';\nimport style from './style';\nimport compose from './compose';\nimport { createUnaryUnit, getValue } from './spacing';\nimport { handleBreakpoints } from './breakpoints';\nexport function borderTransform(value) {\n if (typeof value !== 'number') {\n return value;\n }\n return `${value}px solid`;\n}\nfunction createBorderStyle(prop, transform) {\n return style({\n prop,\n themeKey: 'borders',\n transform\n });\n}\nexport const border = createBorderStyle('border', borderTransform);\nexport const borderTop = createBorderStyle('borderTop', borderTransform);\nexport const borderRight = createBorderStyle('borderRight', borderTransform);\nexport const borderBottom = createBorderStyle('borderBottom', borderTransform);\nexport const borderLeft = createBorderStyle('borderLeft', borderTransform);\nexport const borderColor = createBorderStyle('borderColor');\nexport const borderTopColor = createBorderStyle('borderTopColor');\nexport const borderRightColor = createBorderStyle('borderRightColor');\nexport const borderBottomColor = createBorderStyle('borderBottomColor');\nexport const borderLeftColor = createBorderStyle('borderLeftColor');\nexport const outline = createBorderStyle('outline', borderTransform);\nexport const outlineColor = createBorderStyle('outlineColor');\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const borderRadius = props => {\n if (props.borderRadius !== undefined && props.borderRadius !== null) {\n const transformer = createUnaryUnit(props.theme, 'shape.borderRadius', 4, 'borderRadius');\n const styleFromPropValue = propValue => ({\n borderRadius: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.borderRadius, styleFromPropValue);\n }\n return null;\n};\nborderRadius.propTypes = process.env.NODE_ENV !== 'production' ? {\n borderRadius: responsivePropType\n} : {};\nborderRadius.filterProps = ['borderRadius'];\nconst borders = compose(border, borderTop, borderRight, borderBottom, borderLeft, borderColor, borderTopColor, borderRightColor, borderBottomColor, borderLeftColor, borderRadius, outline, outlineColor);\nexport default borders;","import style from './style';\nimport compose from './compose';\nimport { createUnaryUnit, getValue } from './spacing';\nimport { handleBreakpoints } from './breakpoints';\nimport responsivePropType from './responsivePropType';\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const gap = props => {\n if (props.gap !== undefined && props.gap !== null) {\n const transformer = createUnaryUnit(props.theme, 'spacing', 8, 'gap');\n const styleFromPropValue = propValue => ({\n gap: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.gap, styleFromPropValue);\n }\n return null;\n};\ngap.propTypes = process.env.NODE_ENV !== 'production' ? {\n gap: responsivePropType\n} : {};\ngap.filterProps = ['gap'];\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const columnGap = props => {\n if (props.columnGap !== undefined && props.columnGap !== null) {\n const transformer = createUnaryUnit(props.theme, 'spacing', 8, 'columnGap');\n const styleFromPropValue = propValue => ({\n columnGap: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.columnGap, styleFromPropValue);\n }\n return null;\n};\ncolumnGap.propTypes = process.env.NODE_ENV !== 'production' ? {\n columnGap: responsivePropType\n} : {};\ncolumnGap.filterProps = ['columnGap'];\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const rowGap = props => {\n if (props.rowGap !== undefined && props.rowGap !== null) {\n const transformer = createUnaryUnit(props.theme, 'spacing', 8, 'rowGap');\n const styleFromPropValue = propValue => ({\n rowGap: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.rowGap, styleFromPropValue);\n }\n return null;\n};\nrowGap.propTypes = process.env.NODE_ENV !== 'production' ? {\n rowGap: responsivePropType\n} : {};\nrowGap.filterProps = ['rowGap'];\nexport const gridColumn = style({\n prop: 'gridColumn'\n});\nexport const gridRow = style({\n prop: 'gridRow'\n});\nexport const gridAutoFlow = style({\n prop: 'gridAutoFlow'\n});\nexport const gridAutoColumns = style({\n prop: 'gridAutoColumns'\n});\nexport const gridAutoRows = style({\n prop: 'gridAutoRows'\n});\nexport const gridTemplateColumns = style({\n prop: 'gridTemplateColumns'\n});\nexport const gridTemplateRows = style({\n prop: 'gridTemplateRows'\n});\nexport const gridTemplateAreas = style({\n prop: 'gridTemplateAreas'\n});\nexport const gridArea = style({\n prop: 'gridArea'\n});\nconst grid = compose(gap, columnGap, rowGap, gridColumn, gridRow, gridAutoFlow, gridAutoColumns, gridAutoRows, gridTemplateColumns, gridTemplateRows, gridTemplateAreas, gridArea);\nexport default grid;","import style from './style';\nimport compose from './compose';\nexport function paletteTransform(value, userValue) {\n if (userValue === 'grey') {\n return userValue;\n }\n return value;\n}\nexport const color = style({\n prop: 'color',\n themeKey: 'palette',\n transform: paletteTransform\n});\nexport const bgcolor = style({\n prop: 'bgcolor',\n cssProperty: 'backgroundColor',\n themeKey: 'palette',\n transform: paletteTransform\n});\nexport const backgroundColor = style({\n prop: 'backgroundColor',\n themeKey: 'palette',\n transform: paletteTransform\n});\nconst palette = compose(color, bgcolor, backgroundColor);\nexport default palette;","import style from './style';\nimport compose from './compose';\nimport { handleBreakpoints, values as breakpointsValues } from './breakpoints';\nexport function sizingTransform(value) {\n return value <= 1 && value !== 0 ? `${value * 100}%` : value;\n}\nexport const width = style({\n prop: 'width',\n transform: sizingTransform\n});\nexport const maxWidth = props => {\n if (props.maxWidth !== undefined && props.maxWidth !== null) {\n const styleFromPropValue = propValue => {\n var _props$theme, _props$theme2;\n const breakpoint = ((_props$theme = props.theme) == null || (_props$theme = _props$theme.breakpoints) == null || (_props$theme = _props$theme.values) == null ? void 0 : _props$theme[propValue]) || breakpointsValues[propValue];\n if (!breakpoint) {\n return {\n maxWidth: sizingTransform(propValue)\n };\n }\n if (((_props$theme2 = props.theme) == null || (_props$theme2 = _props$theme2.breakpoints) == null ? void 0 : _props$theme2.unit) !== 'px') {\n return {\n maxWidth: `${breakpoint}${props.theme.breakpoints.unit}`\n };\n }\n return {\n maxWidth: breakpoint\n };\n };\n return handleBreakpoints(props, props.maxWidth, styleFromPropValue);\n }\n return null;\n};\nmaxWidth.filterProps = ['maxWidth'];\nexport const minWidth = style({\n prop: 'minWidth',\n transform: sizingTransform\n});\nexport const height = style({\n prop: 'height',\n transform: sizingTransform\n});\nexport const maxHeight = style({\n prop: 'maxHeight',\n transform: sizingTransform\n});\nexport const minHeight = style({\n prop: 'minHeight',\n transform: sizingTransform\n});\nexport const sizeWidth = style({\n prop: 'size',\n cssProperty: 'width',\n transform: sizingTransform\n});\nexport const sizeHeight = style({\n prop: 'size',\n cssProperty: 'height',\n transform: sizingTransform\n});\nexport const boxSizing = style({\n prop: 'boxSizing'\n});\nconst sizing = compose(width, maxWidth, minWidth, height, maxHeight, minHeight, boxSizing);\nexport default sizing;","import { padding, margin } from '../spacing';\nimport { borderRadius, borderTransform } from '../borders';\nimport { gap, rowGap, columnGap } from '../cssGrid';\nimport { paletteTransform } from '../palette';\nimport { maxWidth, sizingTransform } from '../sizing';\nconst defaultSxConfig = {\n // borders\n border: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderTop: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderRight: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderBottom: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderLeft: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderColor: {\n themeKey: 'palette'\n },\n borderTopColor: {\n themeKey: 'palette'\n },\n borderRightColor: {\n themeKey: 'palette'\n },\n borderBottomColor: {\n themeKey: 'palette'\n },\n borderLeftColor: {\n themeKey: 'palette'\n },\n outline: {\n themeKey: 'borders',\n transform: borderTransform\n },\n outlineColor: {\n themeKey: 'palette'\n },\n borderRadius: {\n themeKey: 'shape.borderRadius',\n style: borderRadius\n },\n // palette\n color: {\n themeKey: 'palette',\n transform: paletteTransform\n },\n bgcolor: {\n themeKey: 'palette',\n cssProperty: 'backgroundColor',\n transform: paletteTransform\n },\n backgroundColor: {\n themeKey: 'palette',\n transform: paletteTransform\n },\n // spacing\n p: {\n style: padding\n },\n pt: {\n style: padding\n },\n pr: {\n style: padding\n },\n pb: {\n style: padding\n },\n pl: {\n style: padding\n },\n px: {\n style: padding\n },\n py: {\n style: padding\n },\n padding: {\n style: padding\n },\n paddingTop: {\n style: padding\n },\n paddingRight: {\n style: padding\n },\n paddingBottom: {\n style: padding\n },\n paddingLeft: {\n style: padding\n },\n paddingX: {\n style: padding\n },\n paddingY: {\n style: padding\n },\n paddingInline: {\n style: padding\n },\n paddingInlineStart: {\n style: padding\n },\n paddingInlineEnd: {\n style: padding\n },\n paddingBlock: {\n style: padding\n },\n paddingBlockStart: {\n style: padding\n },\n paddingBlockEnd: {\n style: padding\n },\n m: {\n style: margin\n },\n mt: {\n style: margin\n },\n mr: {\n style: margin\n },\n mb: {\n style: margin\n },\n ml: {\n style: margin\n },\n mx: {\n style: margin\n },\n my: {\n style: margin\n },\n margin: {\n style: margin\n },\n marginTop: {\n style: margin\n },\n marginRight: {\n style: margin\n },\n marginBottom: {\n style: margin\n },\n marginLeft: {\n style: margin\n },\n marginX: {\n style: margin\n },\n marginY: {\n style: margin\n },\n marginInline: {\n style: margin\n },\n marginInlineStart: {\n style: margin\n },\n marginInlineEnd: {\n style: margin\n },\n marginBlock: {\n style: margin\n },\n marginBlockStart: {\n style: margin\n },\n marginBlockEnd: {\n style: margin\n },\n // display\n displayPrint: {\n cssProperty: false,\n transform: value => ({\n '@media print': {\n display: value\n }\n })\n },\n display: {},\n overflow: {},\n textOverflow: {},\n visibility: {},\n whiteSpace: {},\n // flexbox\n flexBasis: {},\n flexDirection: {},\n flexWrap: {},\n justifyContent: {},\n alignItems: {},\n alignContent: {},\n order: {},\n flex: {},\n flexGrow: {},\n flexShrink: {},\n alignSelf: {},\n justifyItems: {},\n justifySelf: {},\n // grid\n gap: {\n style: gap\n },\n rowGap: {\n style: rowGap\n },\n columnGap: {\n style: columnGap\n },\n gridColumn: {},\n gridRow: {},\n gridAutoFlow: {},\n gridAutoColumns: {},\n gridAutoRows: {},\n gridTemplateColumns: {},\n gridTemplateRows: {},\n gridTemplateAreas: {},\n gridArea: {},\n // positions\n position: {},\n zIndex: {\n themeKey: 'zIndex'\n },\n top: {},\n right: {},\n bottom: {},\n left: {},\n // shadows\n boxShadow: {\n themeKey: 'shadows'\n },\n // sizing\n width: {\n transform: sizingTransform\n },\n maxWidth: {\n style: maxWidth\n },\n minWidth: {\n transform: sizingTransform\n },\n height: {\n transform: sizingTransform\n },\n maxHeight: {\n transform: sizingTransform\n },\n minHeight: {\n transform: sizingTransform\n },\n boxSizing: {},\n // typography\n fontFamily: {\n themeKey: 'typography'\n },\n fontSize: {\n themeKey: 'typography'\n },\n fontStyle: {\n themeKey: 'typography'\n },\n fontWeight: {\n themeKey: 'typography'\n },\n letterSpacing: {},\n textTransform: {},\n lineHeight: {},\n textAlign: {},\n typography: {\n cssProperty: false,\n themeKey: 'typography'\n }\n};\nexport default defaultSxConfig;","import capitalize from '@mui/utils/capitalize';\nimport merge from '../merge';\nimport { getPath, getStyleValue as getValue } from '../style';\nimport { handleBreakpoints, createEmptyBreakpointObject, removeUnusedBreakpoints } from '../breakpoints';\nimport defaultSxConfig from './defaultSxConfig';\nfunction objectsHaveSameKeys(...objects) {\n const allKeys = objects.reduce((keys, object) => keys.concat(Object.keys(object)), []);\n const union = new Set(allKeys);\n return objects.every(object => union.size === Object.keys(object).length);\n}\nfunction callIfFn(maybeFn, arg) {\n return typeof maybeFn === 'function' ? maybeFn(arg) : maybeFn;\n}\n\n// eslint-disable-next-line @typescript-eslint/naming-convention\nexport function unstable_createStyleFunctionSx() {\n function getThemeValue(prop, val, theme, config) {\n const props = {\n [prop]: val,\n theme\n };\n const options = config[prop];\n if (!options) {\n return {\n [prop]: val\n };\n }\n const {\n cssProperty = prop,\n themeKey,\n transform,\n style\n } = options;\n if (val == null) {\n return null;\n }\n\n // TODO v6: remove, see https://github.com/mui/material-ui/pull/38123\n if (themeKey === 'typography' && val === 'inherit') {\n return {\n [prop]: val\n };\n }\n const themeMapping = getPath(theme, themeKey) || {};\n if (style) {\n return style(props);\n }\n const styleFromPropValue = propValueFinal => {\n let value = getValue(themeMapping, transform, propValueFinal);\n if (propValueFinal === value && typeof propValueFinal === 'string') {\n // Haven't found value\n value = getValue(themeMapping, transform, `${prop}${propValueFinal === 'default' ? '' : capitalize(propValueFinal)}`, propValueFinal);\n }\n if (cssProperty === false) {\n return value;\n }\n return {\n [cssProperty]: value\n };\n };\n return handleBreakpoints(props, val, styleFromPropValue);\n }\n function styleFunctionSx(props) {\n var _theme$unstable_sxCon;\n const {\n sx,\n theme = {}\n } = props || {};\n if (!sx) {\n return null; // Emotion & styled-components will neglect null\n }\n const config = (_theme$unstable_sxCon = theme.unstable_sxConfig) != null ? _theme$unstable_sxCon : defaultSxConfig;\n\n /*\n * Receive `sxInput` as object or callback\n * and then recursively check keys & values to create media query object styles.\n * (the result will be used in `styled`)\n */\n function traverse(sxInput) {\n let sxObject = sxInput;\n if (typeof sxInput === 'function') {\n sxObject = sxInput(theme);\n } else if (typeof sxInput !== 'object') {\n // value\n return sxInput;\n }\n if (!sxObject) {\n return null;\n }\n const emptyBreakpoints = createEmptyBreakpointObject(theme.breakpoints);\n const breakpointsKeys = Object.keys(emptyBreakpoints);\n let css = emptyBreakpoints;\n Object.keys(sxObject).forEach(styleKey => {\n const value = callIfFn(sxObject[styleKey], theme);\n if (value !== null && value !== undefined) {\n if (typeof value === 'object') {\n if (config[styleKey]) {\n css = merge(css, getThemeValue(styleKey, value, theme, config));\n } else {\n const breakpointsValues = handleBreakpoints({\n theme\n }, value, x => ({\n [styleKey]: x\n }));\n if (objectsHaveSameKeys(breakpointsValues, value)) {\n css[styleKey] = styleFunctionSx({\n sx: value,\n theme\n });\n } else {\n css = merge(css, breakpointsValues);\n }\n }\n } else {\n css = merge(css, getThemeValue(styleKey, value, theme, config));\n }\n }\n });\n return removeUnusedBreakpoints(breakpointsKeys, css);\n }\n return Array.isArray(sx) ? sx.map(traverse) : traverse(sx);\n }\n return styleFunctionSx;\n}\nconst styleFunctionSx = unstable_createStyleFunctionSx();\nstyleFunctionSx.filterProps = ['sx'];\nexport default styleFunctionSx;","/**\n * A universal utility to style components with multiple color modes. Always use it from the theme object.\n * It works with:\n * - [Basic theme](https://mui.com/material-ui/customization/dark-mode/)\n * - [CSS theme variables](https://mui.com/material-ui/experimental-api/css-theme-variables/overview/)\n * - Zero-runtime engine\n *\n * Tips: Use an array over object spread and place `theme.applyStyles()` last.\n *\n * ✅ [{ background: '#e5e5e5' }, theme.applyStyles('dark', { background: '#1c1c1c' })]\n *\n * 🚫 { background: '#e5e5e5', ...theme.applyStyles('dark', { background: '#1c1c1c' })}\n *\n * @example\n * 1. using with `styled`:\n * ```jsx\n * const Component = styled('div')(({ theme }) => [\n * { background: '#e5e5e5' },\n * theme.applyStyles('dark', {\n * background: '#1c1c1c',\n * color: '#fff',\n * }),\n * ]);\n * ```\n *\n * @example\n * 2. using with `sx` prop:\n * ```jsx\n * [\n * { background: '#e5e5e5' },\n * theme.applyStyles('dark', {\n * background: '#1c1c1c',\n * color: '#fff',\n * }),\n * ]}\n * />\n * ```\n *\n * @example\n * 3. theming a component:\n * ```jsx\n * extendTheme({\n * components: {\n * MuiButton: {\n * styleOverrides: {\n * root: ({ theme }) => [\n * { background: '#e5e5e5' },\n * theme.applyStyles('dark', {\n * background: '#1c1c1c',\n * color: '#fff',\n * }),\n * ],\n * },\n * }\n * }\n * })\n *```\n */\nexport default function applyStyles(key, styles) {\n // @ts-expect-error this is 'any' type\n const theme = this;\n if (theme.vars && typeof theme.getColorSchemeSelector === 'function') {\n // If CssVarsProvider is used as a provider,\n // returns '* :where([data-mui-color-scheme=\"light|dark\"]) &'\n const selector = theme.getColorSchemeSelector(key).replace(/(\\[[^\\]]+\\])/, '*:where($1)');\n return {\n [selector]: styles\n };\n }\n if (theme.palette.mode === key) {\n return styles;\n }\n return {};\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"breakpoints\", \"palette\", \"spacing\", \"shape\"];\nimport deepmerge from '@mui/utils/deepmerge';\nimport createBreakpoints from './createBreakpoints';\nimport shape from './shape';\nimport createSpacing from './createSpacing';\nimport styleFunctionSx from '../styleFunctionSx/styleFunctionSx';\nimport defaultSxConfig from '../styleFunctionSx/defaultSxConfig';\nimport applyStyles from './applyStyles';\nfunction createTheme(options = {}, ...args) {\n const {\n breakpoints: breakpointsInput = {},\n palette: paletteInput = {},\n spacing: spacingInput,\n shape: shapeInput = {}\n } = options,\n other = _objectWithoutPropertiesLoose(options, _excluded);\n const breakpoints = createBreakpoints(breakpointsInput);\n const spacing = createSpacing(spacingInput);\n let muiTheme = deepmerge({\n breakpoints,\n direction: 'ltr',\n components: {},\n // Inject component definitions.\n palette: _extends({\n mode: 'light'\n }, paletteInput),\n spacing,\n shape: _extends({}, shape, shapeInput)\n }, other);\n muiTheme.applyStyles = applyStyles;\n muiTheme = args.reduce((acc, argument) => deepmerge(acc, argument), muiTheme);\n muiTheme.unstable_sxConfig = _extends({}, defaultSxConfig, other == null ? void 0 : other.unstable_sxConfig);\n muiTheme.unstable_sx = function sx(props) {\n return styleFunctionSx({\n sx: props,\n theme: this\n });\n };\n return muiTheme;\n}\nexport default createTheme;","'use client';\n\nimport * as React from 'react';\nimport { ThemeContext } from '@mui/styled-engine';\nfunction isObjectEmpty(obj) {\n return Object.keys(obj).length === 0;\n}\nfunction useTheme(defaultTheme = null) {\n const contextTheme = React.useContext(ThemeContext);\n return !contextTheme || isObjectEmpty(contextTheme) ? defaultTheme : contextTheme;\n}\nexport default useTheme;","'use client';\n\nimport createTheme from './createTheme';\nimport useThemeWithoutDefault from './useThemeWithoutDefault';\nexport const systemDefaultTheme = createTheme();\nfunction useTheme(defaultTheme = systemDefaultTheme) {\n return useThemeWithoutDefault(defaultTheme);\n}\nexport default useTheme;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"ownerState\"],\n _excluded2 = [\"variants\"],\n _excluded3 = [\"name\", \"slot\", \"skipVariantsResolver\", \"skipSx\", \"overridesResolver\"];\n/* eslint-disable no-underscore-dangle */\nimport styledEngineStyled, { internal_processStyles as processStyles } from '@mui/styled-engine';\nimport { isPlainObject } from '@mui/utils/deepmerge';\nimport capitalize from '@mui/utils/capitalize';\nimport getDisplayName from '@mui/utils/getDisplayName';\nimport createTheme from './createTheme';\nimport styleFunctionSx from './styleFunctionSx';\nfunction isEmpty(obj) {\n return Object.keys(obj).length === 0;\n}\n\n// https://github.com/emotion-js/emotion/blob/26ded6109fcd8ca9875cc2ce4564fee678a3f3c5/packages/styled/src/utils.js#L40\nfunction isStringTag(tag) {\n return typeof tag === 'string' &&\n // 96 is one less than the char code\n // for \"a\" so this is checking that\n // it's a lowercase character\n tag.charCodeAt(0) > 96;\n}\n\n// Update /system/styled/#api in case if this changes\nexport function shouldForwardProp(prop) {\n return prop !== 'ownerState' && prop !== 'theme' && prop !== 'sx' && prop !== 'as';\n}\nexport const systemDefaultTheme = createTheme();\nconst lowercaseFirstLetter = string => {\n if (!string) {\n return string;\n }\n return string.charAt(0).toLowerCase() + string.slice(1);\n};\nfunction resolveTheme({\n defaultTheme,\n theme,\n themeId\n}) {\n return isEmpty(theme) ? defaultTheme : theme[themeId] || theme;\n}\nfunction defaultOverridesResolver(slot) {\n if (!slot) {\n return null;\n }\n return (props, styles) => styles[slot];\n}\nfunction processStyleArg(callableStyle, _ref) {\n let {\n ownerState\n } = _ref,\n props = _objectWithoutPropertiesLoose(_ref, _excluded);\n const resolvedStylesArg = typeof callableStyle === 'function' ? callableStyle(_extends({\n ownerState\n }, props)) : callableStyle;\n if (Array.isArray(resolvedStylesArg)) {\n return resolvedStylesArg.flatMap(resolvedStyle => processStyleArg(resolvedStyle, _extends({\n ownerState\n }, props)));\n }\n if (!!resolvedStylesArg && typeof resolvedStylesArg === 'object' && Array.isArray(resolvedStylesArg.variants)) {\n const {\n variants = []\n } = resolvedStylesArg,\n otherStyles = _objectWithoutPropertiesLoose(resolvedStylesArg, _excluded2);\n let result = otherStyles;\n variants.forEach(variant => {\n let isMatch = true;\n if (typeof variant.props === 'function') {\n isMatch = variant.props(_extends({\n ownerState\n }, props, ownerState));\n } else {\n Object.keys(variant.props).forEach(key => {\n if ((ownerState == null ? void 0 : ownerState[key]) !== variant.props[key] && props[key] !== variant.props[key]) {\n isMatch = false;\n }\n });\n }\n if (isMatch) {\n if (!Array.isArray(result)) {\n result = [result];\n }\n result.push(typeof variant.style === 'function' ? variant.style(_extends({\n ownerState\n }, props, ownerState)) : variant.style);\n }\n });\n return result;\n }\n return resolvedStylesArg;\n}\nexport default function createStyled(input = {}) {\n const {\n themeId,\n defaultTheme = systemDefaultTheme,\n rootShouldForwardProp = shouldForwardProp,\n slotShouldForwardProp = shouldForwardProp\n } = input;\n const systemSx = props => {\n return styleFunctionSx(_extends({}, props, {\n theme: resolveTheme(_extends({}, props, {\n defaultTheme,\n themeId\n }))\n }));\n };\n systemSx.__mui_systemSx = true;\n return (tag, inputOptions = {}) => {\n // Filter out the `sx` style function from the previous styled component to prevent unnecessary styles generated by the composite components.\n processStyles(tag, styles => styles.filter(style => !(style != null && style.__mui_systemSx)));\n const {\n name: componentName,\n slot: componentSlot,\n skipVariantsResolver: inputSkipVariantsResolver,\n skipSx: inputSkipSx,\n // TODO v6: remove `lowercaseFirstLetter()` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n overridesResolver = defaultOverridesResolver(lowercaseFirstLetter(componentSlot))\n } = inputOptions,\n options = _objectWithoutPropertiesLoose(inputOptions, _excluded3);\n\n // if skipVariantsResolver option is defined, take the value, otherwise, true for root and false for other slots.\n const skipVariantsResolver = inputSkipVariantsResolver !== undefined ? inputSkipVariantsResolver :\n // TODO v6: remove `Root` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n componentSlot && componentSlot !== 'Root' && componentSlot !== 'root' || false;\n const skipSx = inputSkipSx || false;\n let label;\n if (process.env.NODE_ENV !== 'production') {\n if (componentName) {\n // TODO v6: remove `lowercaseFirstLetter()` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n label = `${componentName}-${lowercaseFirstLetter(componentSlot || 'Root')}`;\n }\n }\n let shouldForwardPropOption = shouldForwardProp;\n\n // TODO v6: remove `Root` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n if (componentSlot === 'Root' || componentSlot === 'root') {\n shouldForwardPropOption = rootShouldForwardProp;\n } else if (componentSlot) {\n // any other slot specified\n shouldForwardPropOption = slotShouldForwardProp;\n } else if (isStringTag(tag)) {\n // for string (html) tag, preserve the behavior in emotion & styled-components.\n shouldForwardPropOption = undefined;\n }\n const defaultStyledResolver = styledEngineStyled(tag, _extends({\n shouldForwardProp: shouldForwardPropOption,\n label\n }, options));\n const transformStyleArg = stylesArg => {\n // On the server Emotion doesn't use React.forwardRef for creating components, so the created\n // component stays as a function. This condition makes sure that we do not interpolate functions\n // which are basically components used as a selectors.\n if (typeof stylesArg === 'function' && stylesArg.__emotion_real !== stylesArg || isPlainObject(stylesArg)) {\n return props => processStyleArg(stylesArg, _extends({}, props, {\n theme: resolveTheme({\n theme: props.theme,\n defaultTheme,\n themeId\n })\n }));\n }\n return stylesArg;\n };\n const muiStyledResolver = (styleArg, ...expressions) => {\n let transformedStyleArg = transformStyleArg(styleArg);\n const expressionsWithDefaultTheme = expressions ? expressions.map(transformStyleArg) : [];\n if (componentName && overridesResolver) {\n expressionsWithDefaultTheme.push(props => {\n const theme = resolveTheme(_extends({}, props, {\n defaultTheme,\n themeId\n }));\n if (!theme.components || !theme.components[componentName] || !theme.components[componentName].styleOverrides) {\n return null;\n }\n const styleOverrides = theme.components[componentName].styleOverrides;\n const resolvedStyleOverrides = {};\n // TODO: v7 remove iteration and use `resolveStyleArg(styleOverrides[slot])` directly\n Object.entries(styleOverrides).forEach(([slotKey, slotStyle]) => {\n resolvedStyleOverrides[slotKey] = processStyleArg(slotStyle, _extends({}, props, {\n theme\n }));\n });\n return overridesResolver(props, resolvedStyleOverrides);\n });\n }\n if (componentName && !skipVariantsResolver) {\n expressionsWithDefaultTheme.push(props => {\n var _theme$components;\n const theme = resolveTheme(_extends({}, props, {\n defaultTheme,\n themeId\n }));\n const themeVariants = theme == null || (_theme$components = theme.components) == null || (_theme$components = _theme$components[componentName]) == null ? void 0 : _theme$components.variants;\n return processStyleArg({\n variants: themeVariants\n }, _extends({}, props, {\n theme\n }));\n });\n }\n if (!skipSx) {\n expressionsWithDefaultTheme.push(systemSx);\n }\n const numOfCustomFnsApplied = expressionsWithDefaultTheme.length - expressions.length;\n if (Array.isArray(styleArg) && numOfCustomFnsApplied > 0) {\n const placeholders = new Array(numOfCustomFnsApplied).fill('');\n // If the type is array, than we need to add placeholders in the template for the overrides, variants and the sx styles.\n transformedStyleArg = [...styleArg, ...placeholders];\n transformedStyleArg.raw = [...styleArg.raw, ...placeholders];\n }\n const Component = defaultStyledResolver(transformedStyleArg, ...expressionsWithDefaultTheme);\n if (process.env.NODE_ENV !== 'production') {\n let displayName;\n if (componentName) {\n displayName = `${componentName}${capitalize(componentSlot || '')}`;\n }\n if (displayName === undefined) {\n displayName = `Styled(${getDisplayName(tag)})`;\n }\n Component.displayName = displayName;\n }\n if (tag.muiName) {\n Component.muiName = tag.muiName;\n }\n return Component;\n };\n if (defaultStyledResolver.withConfig) {\n muiStyledResolver.withConfig = defaultStyledResolver.withConfig;\n }\n return muiStyledResolver;\n };\n}","import resolveProps from '@mui/utils/resolveProps';\nexport default function getThemeProps(params) {\n const {\n theme,\n name,\n props\n } = params;\n if (!theme || !theme.components || !theme.components[name] || !theme.components[name].defaultProps) {\n return props;\n }\n return resolveProps(theme.components[name].defaultProps, props);\n}","'use client';\n\nimport getThemeProps from './getThemeProps';\nimport useTheme from '../useTheme';\nexport default function useThemeProps({\n props,\n name,\n defaultTheme,\n themeId\n}) {\n let theme = useTheme(defaultTheme);\n if (themeId) {\n theme = theme[themeId] || theme;\n }\n const mergedProps = getThemeProps({\n theme,\n name,\n props\n });\n return mergedProps;\n}","import _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\n/* eslint-disable @typescript-eslint/naming-convention */\nimport clamp from '@mui/utils/clamp';\n/**\n * Returns a number whose value is limited to the given range.\n * @param {number} value The value to be clamped\n * @param {number} min The lower boundary of the output range\n * @param {number} max The upper boundary of the output range\n * @returns {number} A number in the range [min, max]\n */\nfunction clampWrapper(value, min = 0, max = 1) {\n if (process.env.NODE_ENV !== 'production') {\n if (value < min || value > max) {\n console.error(`MUI: The value provided ${value} is out of range [${min}, ${max}].`);\n }\n }\n return clamp(value, min, max);\n}\n\n/**\n * Converts a color from CSS hex format to CSS rgb format.\n * @param {string} color - Hex color, i.e. #nnn or #nnnnnn\n * @returns {string} A CSS rgb color string\n */\nexport function hexToRgb(color) {\n color = color.slice(1);\n const re = new RegExp(`.{1,${color.length >= 6 ? 2 : 1}}`, 'g');\n let colors = color.match(re);\n if (colors && colors[0].length === 1) {\n colors = colors.map(n => n + n);\n }\n return colors ? `rgb${colors.length === 4 ? 'a' : ''}(${colors.map((n, index) => {\n return index < 3 ? parseInt(n, 16) : Math.round(parseInt(n, 16) / 255 * 1000) / 1000;\n }).join(', ')})` : '';\n}\nfunction intToHex(int) {\n const hex = int.toString(16);\n return hex.length === 1 ? `0${hex}` : hex;\n}\n\n/**\n * Returns an object with the type and values of a color.\n *\n * Note: Does not support rgb % values.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @returns {object} - A MUI color object: {type: string, values: number[]}\n */\nexport function decomposeColor(color) {\n // Idempotent\n if (color.type) {\n return color;\n }\n if (color.charAt(0) === '#') {\n return decomposeColor(hexToRgb(color));\n }\n const marker = color.indexOf('(');\n const type = color.substring(0, marker);\n if (['rgb', 'rgba', 'hsl', 'hsla', 'color'].indexOf(type) === -1) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: Unsupported \\`${color}\\` color.\nThe following formats are supported: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color().` : _formatMuiErrorMessage(9, color));\n }\n let values = color.substring(marker + 1, color.length - 1);\n let colorSpace;\n if (type === 'color') {\n values = values.split(' ');\n colorSpace = values.shift();\n if (values.length === 4 && values[3].charAt(0) === '/') {\n values[3] = values[3].slice(1);\n }\n if (['srgb', 'display-p3', 'a98-rgb', 'prophoto-rgb', 'rec-2020'].indexOf(colorSpace) === -1) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: unsupported \\`${colorSpace}\\` color space.\nThe following color spaces are supported: srgb, display-p3, a98-rgb, prophoto-rgb, rec-2020.` : _formatMuiErrorMessage(10, colorSpace));\n }\n } else {\n values = values.split(',');\n }\n values = values.map(value => parseFloat(value));\n return {\n type,\n values,\n colorSpace\n };\n}\n\n/**\n * Returns a channel created from the input color.\n *\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @returns {string} - The channel for the color, that can be used in rgba or hsla colors\n */\nexport const colorChannel = color => {\n const decomposedColor = decomposeColor(color);\n return decomposedColor.values.slice(0, 3).map((val, idx) => decomposedColor.type.indexOf('hsl') !== -1 && idx !== 0 ? `${val}%` : val).join(' ');\n};\nexport const private_safeColorChannel = (color, warning) => {\n try {\n return colorChannel(color);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n};\n\n/**\n * Converts a color object with type and values to a string.\n * @param {object} color - Decomposed color\n * @param {string} color.type - One of: 'rgb', 'rgba', 'hsl', 'hsla', 'color'\n * @param {array} color.values - [n,n,n] or [n,n,n,n]\n * @returns {string} A CSS color string\n */\nexport function recomposeColor(color) {\n const {\n type,\n colorSpace\n } = color;\n let {\n values\n } = color;\n if (type.indexOf('rgb') !== -1) {\n // Only convert the first 3 values to int (i.e. not alpha)\n values = values.map((n, i) => i < 3 ? parseInt(n, 10) : n);\n } else if (type.indexOf('hsl') !== -1) {\n values[1] = `${values[1]}%`;\n values[2] = `${values[2]}%`;\n }\n if (type.indexOf('color') !== -1) {\n values = `${colorSpace} ${values.join(' ')}`;\n } else {\n values = `${values.join(', ')}`;\n }\n return `${type}(${values})`;\n}\n\n/**\n * Converts a color from CSS rgb format to CSS hex format.\n * @param {string} color - RGB color, i.e. rgb(n, n, n)\n * @returns {string} A CSS rgb color string, i.e. #nnnnnn\n */\nexport function rgbToHex(color) {\n // Idempotent\n if (color.indexOf('#') === 0) {\n return color;\n }\n const {\n values\n } = decomposeColor(color);\n return `#${values.map((n, i) => intToHex(i === 3 ? Math.round(255 * n) : n)).join('')}`;\n}\n\n/**\n * Converts a color from hsl format to rgb format.\n * @param {string} color - HSL color values\n * @returns {string} rgb color values\n */\nexport function hslToRgb(color) {\n color = decomposeColor(color);\n const {\n values\n } = color;\n const h = values[0];\n const s = values[1] / 100;\n const l = values[2] / 100;\n const a = s * Math.min(l, 1 - l);\n const f = (n, k = (n + h / 30) % 12) => l - a * Math.max(Math.min(k - 3, 9 - k, 1), -1);\n let type = 'rgb';\n const rgb = [Math.round(f(0) * 255), Math.round(f(8) * 255), Math.round(f(4) * 255)];\n if (color.type === 'hsla') {\n type += 'a';\n rgb.push(values[3]);\n }\n return recomposeColor({\n type,\n values: rgb\n });\n}\n/**\n * The relative brightness of any point in a color space,\n * normalized to 0 for darkest black and 1 for lightest white.\n *\n * Formula: https://www.w3.org/TR/WCAG20-TECHS/G17.html#G17-tests\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @returns {number} The relative brightness of the color in the range 0 - 1\n */\nexport function getLuminance(color) {\n color = decomposeColor(color);\n let rgb = color.type === 'hsl' || color.type === 'hsla' ? decomposeColor(hslToRgb(color)).values : color.values;\n rgb = rgb.map(val => {\n if (color.type !== 'color') {\n val /= 255; // normalized\n }\n return val <= 0.03928 ? val / 12.92 : ((val + 0.055) / 1.055) ** 2.4;\n });\n\n // Truncate at 3 digits\n return Number((0.2126 * rgb[0] + 0.7152 * rgb[1] + 0.0722 * rgb[2]).toFixed(3));\n}\n\n/**\n * Calculates the contrast ratio between two colors.\n *\n * Formula: https://www.w3.org/TR/WCAG20-TECHS/G17.html#G17-tests\n * @param {string} foreground - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla()\n * @param {string} background - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla()\n * @returns {number} A contrast ratio value in the range 0 - 21.\n */\nexport function getContrastRatio(foreground, background) {\n const lumA = getLuminance(foreground);\n const lumB = getLuminance(background);\n return (Math.max(lumA, lumB) + 0.05) / (Math.min(lumA, lumB) + 0.05);\n}\n\n/**\n * Sets the absolute transparency of a color.\n * Any existing alpha values are overwritten.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} value - value to set the alpha channel to in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function alpha(color, value) {\n color = decomposeColor(color);\n value = clampWrapper(value);\n if (color.type === 'rgb' || color.type === 'hsl') {\n color.type += 'a';\n }\n if (color.type === 'color') {\n color.values[3] = `/${value}`;\n } else {\n color.values[3] = value;\n }\n return recomposeColor(color);\n}\nexport function private_safeAlpha(color, value, warning) {\n try {\n return alpha(color, value);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Darkens a color.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} coefficient - multiplier in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function darken(color, coefficient) {\n color = decomposeColor(color);\n coefficient = clampWrapper(coefficient);\n if (color.type.indexOf('hsl') !== -1) {\n color.values[2] *= 1 - coefficient;\n } else if (color.type.indexOf('rgb') !== -1 || color.type.indexOf('color') !== -1) {\n for (let i = 0; i < 3; i += 1) {\n color.values[i] *= 1 - coefficient;\n }\n }\n return recomposeColor(color);\n}\nexport function private_safeDarken(color, coefficient, warning) {\n try {\n return darken(color, coefficient);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Lightens a color.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} coefficient - multiplier in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function lighten(color, coefficient) {\n color = decomposeColor(color);\n coefficient = clampWrapper(coefficient);\n if (color.type.indexOf('hsl') !== -1) {\n color.values[2] += (100 - color.values[2]) * coefficient;\n } else if (color.type.indexOf('rgb') !== -1) {\n for (let i = 0; i < 3; i += 1) {\n color.values[i] += (255 - color.values[i]) * coefficient;\n }\n } else if (color.type.indexOf('color') !== -1) {\n for (let i = 0; i < 3; i += 1) {\n color.values[i] += (1 - color.values[i]) * coefficient;\n }\n }\n return recomposeColor(color);\n}\nexport function private_safeLighten(color, coefficient, warning) {\n try {\n return lighten(color, coefficient);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Darken or lighten a color, depending on its luminance.\n * Light colors are darkened, dark colors are lightened.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} coefficient=0.15 - multiplier in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function emphasize(color, coefficient = 0.15) {\n return getLuminance(color) > 0.5 ? darken(color, coefficient) : lighten(color, coefficient);\n}\nexport function private_safeEmphasize(color, coefficient, warning) {\n try {\n return emphasize(color, coefficient);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Blend a transparent overlay color with a background color, resulting in a single\n * RGB color.\n * @param {string} background - CSS color\n * @param {string} overlay - CSS color\n * @param {number} opacity - Opacity multiplier in the range 0 - 1\n * @param {number} [gamma=1.0] - Gamma correction factor. For gamma-correct blending, 2.2 is usual.\n */\nexport function blend(background, overlay, opacity, gamma = 1.0) {\n const blendChannel = (b, o) => Math.round((b ** (1 / gamma) * (1 - opacity) + o ** (1 / gamma) * opacity) ** gamma);\n const backgroundColor = decomposeColor(background);\n const overlayColor = decomposeColor(overlay);\n const rgb = [blendChannel(backgroundColor.values[0], overlayColor.values[0]), blendChannel(backgroundColor.values[1], overlayColor.values[1]), blendChannel(backgroundColor.values[2], overlayColor.values[2])];\n return recomposeColor({\n type: 'rgb',\n values: rgb\n });\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nexport default function createMixins(breakpoints, mixins) {\n return _extends({\n toolbar: {\n minHeight: 56,\n [breakpoints.up('xs')]: {\n '@media (orientation: landscape)': {\n minHeight: 48\n }\n },\n [breakpoints.up('sm')]: {\n minHeight: 64\n }\n }\n }, mixins);\n}","const common = {\n black: '#000',\n white: '#fff'\n};\nexport default common;","const grey = {\n 50: '#fafafa',\n 100: '#f5f5f5',\n 200: '#eeeeee',\n 300: '#e0e0e0',\n 400: '#bdbdbd',\n 500: '#9e9e9e',\n 600: '#757575',\n 700: '#616161',\n 800: '#424242',\n 900: '#212121',\n A100: '#f5f5f5',\n A200: '#eeeeee',\n A400: '#bdbdbd',\n A700: '#616161'\n};\nexport default grey;","const purple = {\n 50: '#f3e5f5',\n 100: '#e1bee7',\n 200: '#ce93d8',\n 300: '#ba68c8',\n 400: '#ab47bc',\n 500: '#9c27b0',\n 600: '#8e24aa',\n 700: '#7b1fa2',\n 800: '#6a1b9a',\n 900: '#4a148c',\n A100: '#ea80fc',\n A200: '#e040fb',\n A400: '#d500f9',\n A700: '#aa00ff'\n};\nexport default purple;","const red = {\n 50: '#ffebee',\n 100: '#ffcdd2',\n 200: '#ef9a9a',\n 300: '#e57373',\n 400: '#ef5350',\n 500: '#f44336',\n 600: '#e53935',\n 700: '#d32f2f',\n 800: '#c62828',\n 900: '#b71c1c',\n A100: '#ff8a80',\n A200: '#ff5252',\n A400: '#ff1744',\n A700: '#d50000'\n};\nexport default red;","const orange = {\n 50: '#fff3e0',\n 100: '#ffe0b2',\n 200: '#ffcc80',\n 300: '#ffb74d',\n 400: '#ffa726',\n 500: '#ff9800',\n 600: '#fb8c00',\n 700: '#f57c00',\n 800: '#ef6c00',\n 900: '#e65100',\n A100: '#ffd180',\n A200: '#ffab40',\n A400: '#ff9100',\n A700: '#ff6d00'\n};\nexport default orange;","const blue = {\n 50: '#e3f2fd',\n 100: '#bbdefb',\n 200: '#90caf9',\n 300: '#64b5f6',\n 400: '#42a5f5',\n 500: '#2196f3',\n 600: '#1e88e5',\n 700: '#1976d2',\n 800: '#1565c0',\n 900: '#0d47a1',\n A100: '#82b1ff',\n A200: '#448aff',\n A400: '#2979ff',\n A700: '#2962ff'\n};\nexport default blue;","const lightBlue = {\n 50: '#e1f5fe',\n 100: '#b3e5fc',\n 200: '#81d4fa',\n 300: '#4fc3f7',\n 400: '#29b6f6',\n 500: '#03a9f4',\n 600: '#039be5',\n 700: '#0288d1',\n 800: '#0277bd',\n 900: '#01579b',\n A100: '#80d8ff',\n A200: '#40c4ff',\n A400: '#00b0ff',\n A700: '#0091ea'\n};\nexport default lightBlue;","const green = {\n 50: '#e8f5e9',\n 100: '#c8e6c9',\n 200: '#a5d6a7',\n 300: '#81c784',\n 400: '#66bb6a',\n 500: '#4caf50',\n 600: '#43a047',\n 700: '#388e3c',\n 800: '#2e7d32',\n 900: '#1b5e20',\n A100: '#b9f6ca',\n A200: '#69f0ae',\n A400: '#00e676',\n A700: '#00c853'\n};\nexport default green;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\nconst _excluded = [\"mode\", \"contrastThreshold\", \"tonalOffset\"];\nimport { deepmerge } from '@mui/utils';\nimport { darken, getContrastRatio, lighten } from '@mui/system';\nimport common from '../colors/common';\nimport grey from '../colors/grey';\nimport purple from '../colors/purple';\nimport red from '../colors/red';\nimport orange from '../colors/orange';\nimport blue from '../colors/blue';\nimport lightBlue from '../colors/lightBlue';\nimport green from '../colors/green';\nexport const light = {\n // The colors used to style the text.\n text: {\n // The most important text.\n primary: 'rgba(0, 0, 0, 0.87)',\n // Secondary text.\n secondary: 'rgba(0, 0, 0, 0.6)',\n // Disabled text have even lower visual prominence.\n disabled: 'rgba(0, 0, 0, 0.38)'\n },\n // The color used to divide different elements.\n divider: 'rgba(0, 0, 0, 0.12)',\n // The background colors used to style the surfaces.\n // Consistency between these values is important.\n background: {\n paper: common.white,\n default: common.white\n },\n // The colors used to style the action elements.\n action: {\n // The color of an active action like an icon button.\n active: 'rgba(0, 0, 0, 0.54)',\n // The color of an hovered action.\n hover: 'rgba(0, 0, 0, 0.04)',\n hoverOpacity: 0.04,\n // The color of a selected action.\n selected: 'rgba(0, 0, 0, 0.08)',\n selectedOpacity: 0.08,\n // The color of a disabled action.\n disabled: 'rgba(0, 0, 0, 0.26)',\n // The background color of a disabled action.\n disabledBackground: 'rgba(0, 0, 0, 0.12)',\n disabledOpacity: 0.38,\n focus: 'rgba(0, 0, 0, 0.12)',\n focusOpacity: 0.12,\n activatedOpacity: 0.12\n }\n};\nexport const dark = {\n text: {\n primary: common.white,\n secondary: 'rgba(255, 255, 255, 0.7)',\n disabled: 'rgba(255, 255, 255, 0.5)',\n icon: 'rgba(255, 255, 255, 0.5)'\n },\n divider: 'rgba(255, 255, 255, 0.12)',\n background: {\n paper: '#121212',\n default: '#121212'\n },\n action: {\n active: common.white,\n hover: 'rgba(255, 255, 255, 0.08)',\n hoverOpacity: 0.08,\n selected: 'rgba(255, 255, 255, 0.16)',\n selectedOpacity: 0.16,\n disabled: 'rgba(255, 255, 255, 0.3)',\n disabledBackground: 'rgba(255, 255, 255, 0.12)',\n disabledOpacity: 0.38,\n focus: 'rgba(255, 255, 255, 0.12)',\n focusOpacity: 0.12,\n activatedOpacity: 0.24\n }\n};\nfunction addLightOrDark(intent, direction, shade, tonalOffset) {\n const tonalOffsetLight = tonalOffset.light || tonalOffset;\n const tonalOffsetDark = tonalOffset.dark || tonalOffset * 1.5;\n if (!intent[direction]) {\n if (intent.hasOwnProperty(shade)) {\n intent[direction] = intent[shade];\n } else if (direction === 'light') {\n intent.light = lighten(intent.main, tonalOffsetLight);\n } else if (direction === 'dark') {\n intent.dark = darken(intent.main, tonalOffsetDark);\n }\n }\n}\nfunction getDefaultPrimary(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: blue[200],\n light: blue[50],\n dark: blue[400]\n };\n }\n return {\n main: blue[700],\n light: blue[400],\n dark: blue[800]\n };\n}\nfunction getDefaultSecondary(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: purple[200],\n light: purple[50],\n dark: purple[400]\n };\n }\n return {\n main: purple[500],\n light: purple[300],\n dark: purple[700]\n };\n}\nfunction getDefaultError(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: red[500],\n light: red[300],\n dark: red[700]\n };\n }\n return {\n main: red[700],\n light: red[400],\n dark: red[800]\n };\n}\nfunction getDefaultInfo(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: lightBlue[400],\n light: lightBlue[300],\n dark: lightBlue[700]\n };\n }\n return {\n main: lightBlue[700],\n light: lightBlue[500],\n dark: lightBlue[900]\n };\n}\nfunction getDefaultSuccess(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: green[400],\n light: green[300],\n dark: green[700]\n };\n }\n return {\n main: green[800],\n light: green[500],\n dark: green[900]\n };\n}\nfunction getDefaultWarning(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: orange[400],\n light: orange[300],\n dark: orange[700]\n };\n }\n return {\n main: '#ed6c02',\n // closest to orange[800] that pass 3:1.\n light: orange[500],\n dark: orange[900]\n };\n}\nexport default function createPalette(palette) {\n const {\n mode = 'light',\n contrastThreshold = 3,\n tonalOffset = 0.2\n } = palette,\n other = _objectWithoutPropertiesLoose(palette, _excluded);\n const primary = palette.primary || getDefaultPrimary(mode);\n const secondary = palette.secondary || getDefaultSecondary(mode);\n const error = palette.error || getDefaultError(mode);\n const info = palette.info || getDefaultInfo(mode);\n const success = palette.success || getDefaultSuccess(mode);\n const warning = palette.warning || getDefaultWarning(mode);\n\n // Use the same logic as\n // Bootstrap: https://github.com/twbs/bootstrap/blob/1d6e3710dd447de1a200f29e8fa521f8a0908f70/scss/_functions.scss#L59\n // and material-components-web https://github.com/material-components/material-components-web/blob/ac46b8863c4dab9fc22c4c662dc6bd1b65dd652f/packages/mdc-theme/_functions.scss#L54\n function getContrastText(background) {\n const contrastText = getContrastRatio(background, dark.text.primary) >= contrastThreshold ? dark.text.primary : light.text.primary;\n if (process.env.NODE_ENV !== 'production') {\n const contrast = getContrastRatio(background, contrastText);\n if (contrast < 3) {\n console.error([`MUI: The contrast ratio of ${contrast}:1 for ${contrastText} on ${background}`, 'falls below the WCAG recommended absolute minimum contrast ratio of 3:1.', 'https://www.w3.org/TR/2008/REC-WCAG20-20081211/#visual-audio-contrast-contrast'].join('\\n'));\n }\n }\n return contrastText;\n }\n const augmentColor = ({\n color,\n name,\n mainShade = 500,\n lightShade = 300,\n darkShade = 700\n }) => {\n color = _extends({}, color);\n if (!color.main && color[mainShade]) {\n color.main = color[mainShade];\n }\n if (!color.hasOwnProperty('main')) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: The color${name ? ` (${name})` : ''} provided to augmentColor(color) is invalid.\nThe color object needs to have a \\`main\\` property or a \\`${mainShade}\\` property.` : _formatMuiErrorMessage(11, name ? ` (${name})` : '', mainShade));\n }\n if (typeof color.main !== 'string') {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: The color${name ? ` (${name})` : ''} provided to augmentColor(color) is invalid.\n\\`color.main\\` should be a string, but \\`${JSON.stringify(color.main)}\\` was provided instead.\n\nDid you intend to use one of the following approaches?\n\nimport { green } from \"@mui/material/colors\";\n\nconst theme1 = createTheme({ palette: {\n primary: green,\n} });\n\nconst theme2 = createTheme({ palette: {\n primary: { main: green[500] },\n} });` : _formatMuiErrorMessage(12, name ? ` (${name})` : '', JSON.stringify(color.main)));\n }\n addLightOrDark(color, 'light', lightShade, tonalOffset);\n addLightOrDark(color, 'dark', darkShade, tonalOffset);\n if (!color.contrastText) {\n color.contrastText = getContrastText(color.main);\n }\n return color;\n };\n const modes = {\n dark,\n light\n };\n if (process.env.NODE_ENV !== 'production') {\n if (!modes[mode]) {\n console.error(`MUI: The palette mode \\`${mode}\\` is not supported.`);\n }\n }\n const paletteOutput = deepmerge(_extends({\n // A collection of common colors.\n common: _extends({}, common),\n // prevent mutable object.\n // The palette mode, can be light or dark.\n mode,\n // The colors used to represent primary interface elements for a user.\n primary: augmentColor({\n color: primary,\n name: 'primary'\n }),\n // The colors used to represent secondary interface elements for a user.\n secondary: augmentColor({\n color: secondary,\n name: 'secondary',\n mainShade: 'A400',\n lightShade: 'A200',\n darkShade: 'A700'\n }),\n // The colors used to represent interface elements that the user should be made aware of.\n error: augmentColor({\n color: error,\n name: 'error'\n }),\n // The colors used to represent potentially dangerous actions or important messages.\n warning: augmentColor({\n color: warning,\n name: 'warning'\n }),\n // The colors used to present information to the user that is neutral and not necessarily important.\n info: augmentColor({\n color: info,\n name: 'info'\n }),\n // The colors used to indicate the successful completion of an action that user triggered.\n success: augmentColor({\n color: success,\n name: 'success'\n }),\n // The grey colors.\n grey,\n // Used by `getContrastText()` to maximize the contrast between\n // the background and the text.\n contrastThreshold,\n // Takes a background color and returns the text color that maximizes the contrast.\n getContrastText,\n // Generate a rich color object.\n augmentColor,\n // Used by the functions below to shift a color's luminance by approximately\n // two indexes within its tonal palette.\n // E.g., shift from Red 500 to Red 300 or Red 700.\n tonalOffset\n }, modes[mode]), other);\n return paletteOutput;\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"fontFamily\", \"fontSize\", \"fontWeightLight\", \"fontWeightRegular\", \"fontWeightMedium\", \"fontWeightBold\", \"htmlFontSize\", \"allVariants\", \"pxToRem\"];\nimport { deepmerge } from '@mui/utils';\nfunction round(value) {\n return Math.round(value * 1e5) / 1e5;\n}\nconst caseAllCaps = {\n textTransform: 'uppercase'\n};\nconst defaultFontFamily = '\"Roboto\", \"Helvetica\", \"Arial\", sans-serif';\n\n/**\n * @see @link{https://m2.material.io/design/typography/the-type-system.html}\n * @see @link{https://m2.material.io/design/typography/understanding-typography.html}\n */\nexport default function createTypography(palette, typography) {\n const _ref = typeof typography === 'function' ? typography(palette) : typography,\n {\n fontFamily = defaultFontFamily,\n // The default font size of the Material Specification.\n fontSize = 14,\n // px\n fontWeightLight = 300,\n fontWeightRegular = 400,\n fontWeightMedium = 500,\n fontWeightBold = 700,\n // Tell MUI what's the font-size on the html element.\n // 16px is the default font-size used by browsers.\n htmlFontSize = 16,\n // Apply the CSS properties to all the variants.\n allVariants,\n pxToRem: pxToRem2\n } = _ref,\n other = _objectWithoutPropertiesLoose(_ref, _excluded);\n if (process.env.NODE_ENV !== 'production') {\n if (typeof fontSize !== 'number') {\n console.error('MUI: `fontSize` is required to be a number.');\n }\n if (typeof htmlFontSize !== 'number') {\n console.error('MUI: `htmlFontSize` is required to be a number.');\n }\n }\n const coef = fontSize / 14;\n const pxToRem = pxToRem2 || (size => `${size / htmlFontSize * coef}rem`);\n const buildVariant = (fontWeight, size, lineHeight, letterSpacing, casing) => _extends({\n fontFamily,\n fontWeight,\n fontSize: pxToRem(size),\n // Unitless following https://meyerweb.com/eric/thoughts/2006/02/08/unitless-line-heights/\n lineHeight\n }, fontFamily === defaultFontFamily ? {\n letterSpacing: `${round(letterSpacing / size)}em`\n } : {}, casing, allVariants);\n const variants = {\n h1: buildVariant(fontWeightLight, 96, 1.167, -1.5),\n h2: buildVariant(fontWeightLight, 60, 1.2, -0.5),\n h3: buildVariant(fontWeightRegular, 48, 1.167, 0),\n h4: buildVariant(fontWeightRegular, 34, 1.235, 0.25),\n h5: buildVariant(fontWeightRegular, 24, 1.334, 0),\n h6: buildVariant(fontWeightMedium, 20, 1.6, 0.15),\n subtitle1: buildVariant(fontWeightRegular, 16, 1.75, 0.15),\n subtitle2: buildVariant(fontWeightMedium, 14, 1.57, 0.1),\n body1: buildVariant(fontWeightRegular, 16, 1.5, 0.15),\n body2: buildVariant(fontWeightRegular, 14, 1.43, 0.15),\n button: buildVariant(fontWeightMedium, 14, 1.75, 0.4, caseAllCaps),\n caption: buildVariant(fontWeightRegular, 12, 1.66, 0.4),\n overline: buildVariant(fontWeightRegular, 12, 2.66, 1, caseAllCaps),\n // TODO v6: Remove handling of 'inherit' variant from the theme as it is already handled in Material UI's Typography component. Also, remember to remove the associated types.\n inherit: {\n fontFamily: 'inherit',\n fontWeight: 'inherit',\n fontSize: 'inherit',\n lineHeight: 'inherit',\n letterSpacing: 'inherit'\n }\n };\n return deepmerge(_extends({\n htmlFontSize,\n pxToRem,\n fontFamily,\n fontSize,\n fontWeightLight,\n fontWeightRegular,\n fontWeightMedium,\n fontWeightBold\n }, variants), other, {\n clone: false // No need to clone deep\n });\n}","const shadowKeyUmbraOpacity = 0.2;\nconst shadowKeyPenumbraOpacity = 0.14;\nconst shadowAmbientShadowOpacity = 0.12;\nfunction createShadow(...px) {\n return [`${px[0]}px ${px[1]}px ${px[2]}px ${px[3]}px rgba(0,0,0,${shadowKeyUmbraOpacity})`, `${px[4]}px ${px[5]}px ${px[6]}px ${px[7]}px rgba(0,0,0,${shadowKeyPenumbraOpacity})`, `${px[8]}px ${px[9]}px ${px[10]}px ${px[11]}px rgba(0,0,0,${shadowAmbientShadowOpacity})`].join(',');\n}\n\n// Values from https://github.com/material-components/material-components-web/blob/be8747f94574669cb5e7add1a7c54fa41a89cec7/packages/mdc-elevation/_variables.scss\nconst shadows = ['none', createShadow(0, 2, 1, -1, 0, 1, 1, 0, 0, 1, 3, 0), createShadow(0, 3, 1, -2, 0, 2, 2, 0, 0, 1, 5, 0), createShadow(0, 3, 3, -2, 0, 3, 4, 0, 0, 1, 8, 0), createShadow(0, 2, 4, -1, 0, 4, 5, 0, 0, 1, 10, 0), createShadow(0, 3, 5, -1, 0, 5, 8, 0, 0, 1, 14, 0), createShadow(0, 3, 5, -1, 0, 6, 10, 0, 0, 1, 18, 0), createShadow(0, 4, 5, -2, 0, 7, 10, 1, 0, 2, 16, 1), createShadow(0, 5, 5, -3, 0, 8, 10, 1, 0, 3, 14, 2), createShadow(0, 5, 6, -3, 0, 9, 12, 1, 0, 3, 16, 2), createShadow(0, 6, 6, -3, 0, 10, 14, 1, 0, 4, 18, 3), createShadow(0, 6, 7, -4, 0, 11, 15, 1, 0, 4, 20, 3), createShadow(0, 7, 8, -4, 0, 12, 17, 2, 0, 5, 22, 4), createShadow(0, 7, 8, -4, 0, 13, 19, 2, 0, 5, 24, 4), createShadow(0, 7, 9, -4, 0, 14, 21, 2, 0, 5, 26, 4), createShadow(0, 8, 9, -5, 0, 15, 22, 2, 0, 6, 28, 5), createShadow(0, 8, 10, -5, 0, 16, 24, 2, 0, 6, 30, 5), createShadow(0, 8, 11, -5, 0, 17, 26, 2, 0, 6, 32, 5), createShadow(0, 9, 11, -5, 0, 18, 28, 2, 0, 7, 34, 6), createShadow(0, 9, 12, -6, 0, 19, 29, 2, 0, 7, 36, 6), createShadow(0, 10, 13, -6, 0, 20, 31, 3, 0, 8, 38, 7), createShadow(0, 10, 13, -6, 0, 21, 33, 3, 0, 8, 40, 7), createShadow(0, 10, 14, -6, 0, 22, 35, 3, 0, 8, 42, 7), createShadow(0, 11, 14, -7, 0, 23, 36, 3, 0, 9, 44, 8), createShadow(0, 11, 15, -7, 0, 24, 38, 3, 0, 9, 46, 8)];\nexport default shadows;","import _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nconst _excluded = [\"duration\", \"easing\", \"delay\"];\n// Follow https://material.google.com/motion/duration-easing.html#duration-easing-natural-easing-curves\n// to learn the context in which each easing should be used.\nexport const easing = {\n // This is the most common easing curve.\n easeInOut: 'cubic-bezier(0.4, 0, 0.2, 1)',\n // Objects enter the screen at full velocity from off-screen and\n // slowly decelerate to a resting point.\n easeOut: 'cubic-bezier(0.0, 0, 0.2, 1)',\n // Objects leave the screen at full velocity. They do not decelerate when off-screen.\n easeIn: 'cubic-bezier(0.4, 0, 1, 1)',\n // The sharp curve is used by objects that may return to the screen at any time.\n sharp: 'cubic-bezier(0.4, 0, 0.6, 1)'\n};\n\n// Follow https://m2.material.io/guidelines/motion/duration-easing.html#duration-easing-common-durations\n// to learn when use what timing\nexport const duration = {\n shortest: 150,\n shorter: 200,\n short: 250,\n // most basic recommended timing\n standard: 300,\n // this is to be used in complex animations\n complex: 375,\n // recommended when something is entering screen\n enteringScreen: 225,\n // recommended when something is leaving screen\n leavingScreen: 195\n};\nfunction formatMs(milliseconds) {\n return `${Math.round(milliseconds)}ms`;\n}\nfunction getAutoHeightDuration(height) {\n if (!height) {\n return 0;\n }\n const constant = height / 36;\n\n // https://www.wolframalpha.com/input/?i=(4+%2B+15+*+(x+%2F+36+)+**+0.25+%2B+(x+%2F+36)+%2F+5)+*+10\n return Math.round((4 + 15 * constant ** 0.25 + constant / 5) * 10);\n}\nexport default function createTransitions(inputTransitions) {\n const mergedEasing = _extends({}, easing, inputTransitions.easing);\n const mergedDuration = _extends({}, duration, inputTransitions.duration);\n const create = (props = ['all'], options = {}) => {\n const {\n duration: durationOption = mergedDuration.standard,\n easing: easingOption = mergedEasing.easeInOut,\n delay = 0\n } = options,\n other = _objectWithoutPropertiesLoose(options, _excluded);\n if (process.env.NODE_ENV !== 'production') {\n const isString = value => typeof value === 'string';\n // IE11 support, replace with Number.isNaN\n // eslint-disable-next-line no-restricted-globals\n const isNumber = value => !isNaN(parseFloat(value));\n if (!isString(props) && !Array.isArray(props)) {\n console.error('MUI: Argument \"props\" must be a string or Array.');\n }\n if (!isNumber(durationOption) && !isString(durationOption)) {\n console.error(`MUI: Argument \"duration\" must be a number or a string but found ${durationOption}.`);\n }\n if (!isString(easingOption)) {\n console.error('MUI: Argument \"easing\" must be a string.');\n }\n if (!isNumber(delay) && !isString(delay)) {\n console.error('MUI: Argument \"delay\" must be a number or a string.');\n }\n if (typeof options !== 'object') {\n console.error(['MUI: Secong argument of transition.create must be an object.', \"Arguments should be either `create('prop1', options)` or `create(['prop1', 'prop2'], options)`\"].join('\\n'));\n }\n if (Object.keys(other).length !== 0) {\n console.error(`MUI: Unrecognized argument(s) [${Object.keys(other).join(',')}].`);\n }\n }\n return (Array.isArray(props) ? props : [props]).map(animatedProp => `${animatedProp} ${typeof durationOption === 'string' ? durationOption : formatMs(durationOption)} ${easingOption} ${typeof delay === 'string' ? delay : formatMs(delay)}`).join(',');\n };\n return _extends({\n getAutoHeightDuration,\n create\n }, inputTransitions, {\n easing: mergedEasing,\n duration: mergedDuration\n });\n}","// We need to centralize the zIndex definitions as they work\n// like global values in the browser.\nconst zIndex = {\n mobileStepper: 1000,\n fab: 1050,\n speedDial: 1050,\n appBar: 1100,\n drawer: 1200,\n modal: 1300,\n snackbar: 1400,\n tooltip: 1500\n};\nexport default zIndex;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\nconst _excluded = [\"breakpoints\", \"mixins\", \"spacing\", \"palette\", \"transitions\", \"typography\", \"shape\"];\nimport { deepmerge } from '@mui/utils';\nimport { createTheme as systemCreateTheme, unstable_defaultSxConfig as defaultSxConfig, unstable_styleFunctionSx as styleFunctionSx } from '@mui/system';\nimport generateUtilityClass from '@mui/utils/generateUtilityClass';\nimport createMixins from './createMixins';\nimport createPalette from './createPalette';\nimport createTypography from './createTypography';\nimport shadows from './shadows';\nimport createTransitions from './createTransitions';\nimport zIndex from './zIndex';\nfunction createTheme(options = {}, ...args) {\n const {\n mixins: mixinsInput = {},\n palette: paletteInput = {},\n transitions: transitionsInput = {},\n typography: typographyInput = {}\n } = options,\n other = _objectWithoutPropertiesLoose(options, _excluded);\n if (options.vars) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: \\`vars\\` is a private field used for CSS variables support.\nPlease use another name.` : _formatMuiErrorMessage(18));\n }\n const palette = createPalette(paletteInput);\n const systemTheme = systemCreateTheme(options);\n let muiTheme = deepmerge(systemTheme, {\n mixins: createMixins(systemTheme.breakpoints, mixinsInput),\n palette,\n // Don't use [...shadows] until you've verified its transpiled code is not invoking the iterator protocol.\n shadows: shadows.slice(),\n typography: createTypography(palette, typographyInput),\n transitions: createTransitions(transitionsInput),\n zIndex: _extends({}, zIndex)\n });\n muiTheme = deepmerge(muiTheme, other);\n muiTheme = args.reduce((acc, argument) => deepmerge(acc, argument), muiTheme);\n if (process.env.NODE_ENV !== 'production') {\n // TODO v6: Refactor to use globalStateClassesMapping from @mui/utils once `readOnly` state class is used in Rating component.\n const stateClasses = ['active', 'checked', 'completed', 'disabled', 'error', 'expanded', 'focused', 'focusVisible', 'required', 'selected'];\n const traverse = (node, component) => {\n let key;\n\n // eslint-disable-next-line guard-for-in, no-restricted-syntax\n for (key in node) {\n const child = node[key];\n if (stateClasses.indexOf(key) !== -1 && Object.keys(child).length > 0) {\n if (process.env.NODE_ENV !== 'production') {\n const stateClass = generateUtilityClass('', key);\n console.error([`MUI: The \\`${component}\\` component increases ` + `the CSS specificity of the \\`${key}\\` internal state.`, 'You can not override it like this: ', JSON.stringify(node, null, 2), '', `Instead, you need to use the '&.${stateClass}' syntax:`, JSON.stringify({\n root: {\n [`&.${stateClass}`]: child\n }\n }, null, 2), '', 'https://mui.com/r/state-classes-guide'].join('\\n'));\n }\n // Remove the style to prevent global conflicts.\n node[key] = {};\n }\n }\n };\n Object.keys(muiTheme.components).forEach(component => {\n const styleOverrides = muiTheme.components[component].styleOverrides;\n if (styleOverrides && component.indexOf('Mui') === 0) {\n traverse(styleOverrides, component);\n }\n });\n }\n muiTheme.unstable_sxConfig = _extends({}, defaultSxConfig, other == null ? void 0 : other.unstable_sxConfig);\n muiTheme.unstable_sx = function sx(props) {\n return styleFunctionSx({\n sx: props,\n theme: this\n });\n };\n return muiTheme;\n}\nlet warnedOnce = false;\nexport function createMuiTheme(...args) {\n if (process.env.NODE_ENV !== 'production') {\n if (!warnedOnce) {\n warnedOnce = true;\n console.error(['MUI: the createMuiTheme function was renamed to createTheme.', '', \"You should use `import { createTheme } from '@mui/material/styles'`\"].join('\\n'));\n }\n }\n return createTheme(...args);\n}\nexport default createTheme;","'use client';\n\nimport createTheme from './createTheme';\nconst defaultTheme = createTheme();\nexport default defaultTheme;","export default '$$material';","'use client';\n\nimport { useThemeProps as systemUseThemeProps } from '@mui/system';\nimport defaultTheme from './defaultTheme';\nimport THEME_ID from './identifier';\nexport default function useThemeProps({\n props,\n name\n}) {\n return systemUseThemeProps({\n props,\n name,\n defaultTheme,\n themeId: THEME_ID\n });\n}","'use client';\n\nimport { createStyled, shouldForwardProp } from '@mui/system';\nimport defaultTheme from './defaultTheme';\nimport THEME_ID from './identifier';\nexport const rootShouldForwardProp = prop => shouldForwardProp(prop) && prop !== 'classes';\nexport const slotShouldForwardProp = shouldForwardProp;\nconst styled = createStyled({\n themeId: THEME_ID,\n defaultTheme,\n rootShouldForwardProp\n});\nexport default styled;","import generateUtilityClasses from '@mui/utils/generateUtilityClasses';\nimport generateUtilityClass from '@mui/utils/generateUtilityClass';\nexport function getSvgIconUtilityClass(slot) {\n return generateUtilityClass('MuiSvgIcon', slot);\n}\nconst svgIconClasses = generateUtilityClasses('MuiSvgIcon', ['root', 'colorPrimary', 'colorSecondary', 'colorAction', 'colorError', 'colorDisabled', 'fontSizeInherit', 'fontSizeSmall', 'fontSizeMedium', 'fontSizeLarge']);\nexport default svgIconClasses;","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"children\", \"className\", \"color\", \"component\", \"fontSize\", \"htmlColor\", \"inheritViewBox\", \"titleAccess\", \"viewBox\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport clsx from 'clsx';\nimport { unstable_composeClasses as composeClasses } from '@mui/base/composeClasses';\nimport capitalize from '../utils/capitalize';\nimport useThemeProps from '../styles/useThemeProps';\nimport styled from '../styles/styled';\nimport { getSvgIconUtilityClass } from './svgIconClasses';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nimport { jsxs as _jsxs } from \"react/jsx-runtime\";\nconst useUtilityClasses = ownerState => {\n const {\n color,\n fontSize,\n classes\n } = ownerState;\n const slots = {\n root: ['root', color !== 'inherit' && `color${capitalize(color)}`, `fontSize${capitalize(fontSize)}`]\n };\n return composeClasses(slots, getSvgIconUtilityClass, classes);\n};\nconst SvgIconRoot = styled('svg', {\n name: 'MuiSvgIcon',\n slot: 'Root',\n overridesResolver: (props, styles) => {\n const {\n ownerState\n } = props;\n return [styles.root, ownerState.color !== 'inherit' && styles[`color${capitalize(ownerState.color)}`], styles[`fontSize${capitalize(ownerState.fontSize)}`]];\n }\n})(({\n theme,\n ownerState\n}) => {\n var _theme$transitions, _theme$transitions$cr, _theme$transitions2, _theme$typography, _theme$typography$pxT, _theme$typography2, _theme$typography2$px, _theme$typography3, _theme$typography3$px, _palette$ownerState$c, _palette, _palette2, _palette3;\n return {\n userSelect: 'none',\n width: '1em',\n height: '1em',\n display: 'inline-block',\n // the will define the property that has `currentColor`\n // e.g. heroicons uses fill=\"none\" and stroke=\"currentColor\"\n fill: ownerState.hasSvgAsChild ? undefined : 'currentColor',\n flexShrink: 0,\n transition: (_theme$transitions = theme.transitions) == null || (_theme$transitions$cr = _theme$transitions.create) == null ? void 0 : _theme$transitions$cr.call(_theme$transitions, 'fill', {\n duration: (_theme$transitions2 = theme.transitions) == null || (_theme$transitions2 = _theme$transitions2.duration) == null ? void 0 : _theme$transitions2.shorter\n }),\n fontSize: {\n inherit: 'inherit',\n small: ((_theme$typography = theme.typography) == null || (_theme$typography$pxT = _theme$typography.pxToRem) == null ? void 0 : _theme$typography$pxT.call(_theme$typography, 20)) || '1.25rem',\n medium: ((_theme$typography2 = theme.typography) == null || (_theme$typography2$px = _theme$typography2.pxToRem) == null ? void 0 : _theme$typography2$px.call(_theme$typography2, 24)) || '1.5rem',\n large: ((_theme$typography3 = theme.typography) == null || (_theme$typography3$px = _theme$typography3.pxToRem) == null ? void 0 : _theme$typography3$px.call(_theme$typography3, 35)) || '2.1875rem'\n }[ownerState.fontSize],\n // TODO v5 deprecate, v6 remove for sx\n color: (_palette$ownerState$c = (_palette = (theme.vars || theme).palette) == null || (_palette = _palette[ownerState.color]) == null ? void 0 : _palette.main) != null ? _palette$ownerState$c : {\n action: (_palette2 = (theme.vars || theme).palette) == null || (_palette2 = _palette2.action) == null ? void 0 : _palette2.active,\n disabled: (_palette3 = (theme.vars || theme).palette) == null || (_palette3 = _palette3.action) == null ? void 0 : _palette3.disabled,\n inherit: undefined\n }[ownerState.color]\n };\n});\nconst SvgIcon = /*#__PURE__*/React.forwardRef(function SvgIcon(inProps, ref) {\n const props = useThemeProps({\n props: inProps,\n name: 'MuiSvgIcon'\n });\n const {\n children,\n className,\n color = 'inherit',\n component = 'svg',\n fontSize = 'medium',\n htmlColor,\n inheritViewBox = false,\n titleAccess,\n viewBox = '0 0 24 24'\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const hasSvgAsChild = /*#__PURE__*/React.isValidElement(children) && children.type === 'svg';\n const ownerState = _extends({}, props, {\n color,\n component,\n fontSize,\n instanceFontSize: inProps.fontSize,\n inheritViewBox,\n viewBox,\n hasSvgAsChild\n });\n const more = {};\n if (!inheritViewBox) {\n more.viewBox = viewBox;\n }\n const classes = useUtilityClasses(ownerState);\n return /*#__PURE__*/_jsxs(SvgIconRoot, _extends({\n as: component,\n className: clsx(classes.root, className),\n focusable: \"false\",\n color: htmlColor,\n \"aria-hidden\": titleAccess ? undefined : true,\n role: titleAccess ? 'img' : undefined,\n ref: ref\n }, more, other, hasSvgAsChild && children.props, {\n ownerState: ownerState,\n children: [hasSvgAsChild ? children.props.children : children, titleAccess ? /*#__PURE__*/_jsx(\"title\", {\n children: titleAccess\n }) : null]\n }));\n});\nprocess.env.NODE_ENV !== \"production\" ? SvgIcon.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the d.ts file and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * Node passed into the SVG element.\n */\n children: PropTypes.node,\n /**\n * Override or extend the styles applied to the component.\n */\n classes: PropTypes.object,\n /**\n * @ignore\n */\n className: PropTypes.string,\n /**\n * The color of the component.\n * It supports both default and custom theme colors, which can be added as shown in the\n * [palette customization guide](https://mui.com/material-ui/customization/palette/#custom-colors).\n * You can use the `htmlColor` prop to apply a color attribute to the SVG element.\n * @default 'inherit'\n */\n color: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.oneOf(['inherit', 'action', 'disabled', 'primary', 'secondary', 'error', 'info', 'success', 'warning']), PropTypes.string]),\n /**\n * The component used for the root node.\n * Either a string to use a HTML element or a component.\n */\n component: PropTypes.elementType,\n /**\n * The fontSize applied to the icon. Defaults to 24px, but can be configure to inherit font size.\n * @default 'medium'\n */\n fontSize: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.oneOf(['inherit', 'large', 'medium', 'small']), PropTypes.string]),\n /**\n * Applies a color attribute to the SVG element.\n */\n htmlColor: PropTypes.string,\n /**\n * If `true`, the root node will inherit the custom `component`'s viewBox and the `viewBox`\n * prop will be ignored.\n * Useful when you want to reference a custom `component` and have `SvgIcon` pass that\n * `component`'s viewBox to the root node.\n * @default false\n */\n inheritViewBox: PropTypes.bool,\n /**\n * The shape-rendering attribute. The behavior of the different options is described on the\n * [MDN Web Docs](https://developer.mozilla.org/en-US/docs/Web/SVG/Attribute/shape-rendering).\n * If you are having issues with blurry icons you should investigate this prop.\n */\n shapeRendering: PropTypes.string,\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Provides a human-readable title for the element that contains it.\n * https://www.w3.org/TR/SVG-access/#Equivalent\n */\n titleAccess: PropTypes.string,\n /**\n * Allows you to redefine what the coordinates without units mean inside an SVG element.\n * For example, if the SVG element is 500 (width) by 200 (height),\n * and you pass viewBox=\"0 0 50 20\",\n * this means that the coordinates inside the SVG will go from the top left corner (0,0)\n * to bottom right (50,20) and each unit will be worth 10px.\n * @default '0 0 24 24'\n */\n viewBox: PropTypes.string\n} : void 0;\nSvgIcon.muiName = 'SvgIcon';\nexport default SvgIcon;","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport * as React from 'react';\nimport SvgIcon from '../SvgIcon';\n\n/**\n * Private module reserved for @mui packages.\n */\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nexport default function createSvgIcon(path, displayName) {\n function Component(props, ref) {\n return /*#__PURE__*/_jsx(SvgIcon, _extends({\n \"data-testid\": `${displayName}Icon`,\n ref: ref\n }, props, {\n children: path\n }));\n }\n if (process.env.NODE_ENV !== 'production') {\n // Need to set `displayName` on the inner component for React.memo.\n // React prior to 16.14 ignores `displayName` on the wrapper.\n Component.displayName = `${displayName}Icon`;\n }\n Component.muiName = SvgIcon.muiName;\n return /*#__PURE__*/React.memo( /*#__PURE__*/React.forwardRef(Component));\n}","'use client';\n\nimport { unstable_ClassNameGenerator as ClassNameGenerator } from '@mui/base/ClassNameGenerator';\nexport { default as capitalize } from './capitalize';\nexport { default as createChainedFunction } from './createChainedFunction';\nexport { default as createSvgIcon } from './createSvgIcon';\nexport { default as debounce } from './debounce';\nexport { default as deprecatedPropType } from './deprecatedPropType';\nexport { default as isMuiElement } from './isMuiElement';\nexport { default as ownerDocument } from './ownerDocument';\nexport { default as ownerWindow } from './ownerWindow';\nexport { default as requirePropFactory } from './requirePropFactory';\nexport { default as setRef } from './setRef';\nexport { default as unstable_useEnhancedEffect } from './useEnhancedEffect';\nexport { default as unstable_useId } from './useId';\nexport { default as unsupportedProp } from './unsupportedProp';\nexport { default as useControlled } from './useControlled';\nexport { default as useEventCallback } from './useEventCallback';\nexport { default as useForkRef } from './useForkRef';\nexport { default as useIsFocusVisible } from './useIsFocusVisible';\n// TODO: remove this export once ClassNameGenerator is stable\n// eslint-disable-next-line @typescript-eslint/naming-convention\nexport const unstable_ClassNameGenerator = {\n configure: generator => {\n if (process.env.NODE_ENV !== 'production') {\n console.warn(['MUI: `ClassNameGenerator` import from `@mui/material/utils` is outdated and might cause unexpected issues.', '', \"You should use `import { unstable_ClassNameGenerator } from '@mui/material/className'` instead\", '', 'The detail of the issue: https://github.com/mui/material-ui/issues/30011#issuecomment-1024993401', '', 'The updated documentation: https://mui.com/guides/classname-generator/'].join('\\n'));\n }\n ClassNameGenerator.configure(generator);\n }\n};","\"use strict\";\n'use client';\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nObject.defineProperty(exports, \"default\", {\n enumerable: true,\n get: function () {\n return _utils.createSvgIcon;\n }\n});\nvar _utils = require(\"@mui/material/utils\");","\"use strict\";\n\"use client\";\n\nvar _interopRequireDefault = require(\"@babel/runtime/helpers/interopRequireDefault\");\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = void 0;\nvar _createSvgIcon = _interopRequireDefault(require(\"./utils/createSvgIcon\"));\nvar _jsxRuntime = require(\"react/jsx-runtime\");\nvar _default = exports.default = (0, _createSvgIcon.default)( /*#__PURE__*/(0, _jsxRuntime.jsx)(\"path\", {\n d: \"m10 17 5-5-5-5z\"\n}), 'ArrowRight');","/**\n * Determines if a given element is a DOM element name (i.e. not a React component).\n */\nexport function isHostComponent(element) {\n return typeof element === 'string';\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport { isHostComponent } from './isHostComponent';\n\n/**\n * Type of the ownerState based on the type of an element it applies to.\n * This resolves to the provided OwnerState for React components and `undefined` for host components.\n * Falls back to `OwnerState | undefined` when the exact type can't be determined in development time.\n */\n\n/**\n * Appends the ownerState object to the props, merging with the existing one if necessary.\n *\n * @param elementType Type of the element that owns the `existingProps`. If the element is a DOM node or undefined, `ownerState` is not applied.\n * @param otherProps Props of the element.\n * @param ownerState\n */\nexport function appendOwnerState(elementType, otherProps, ownerState) {\n if (elementType === undefined || isHostComponent(elementType)) {\n return otherProps;\n }\n return _extends({}, otherProps, {\n ownerState: _extends({}, otherProps.ownerState, ownerState)\n });\n}","'use client';\n\nimport * as React from 'react';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nconst defaultContextValue = {\n disableDefaultClasses: false\n};\nconst ClassNameConfiguratorContext = /*#__PURE__*/React.createContext(defaultContextValue);\n/**\n * @ignore - internal hook.\n *\n * Wraps the `generateUtilityClass` function and controls how the classes are generated.\n * Currently it only affects whether the classes are applied or not.\n *\n * @returns Function to be called with the `generateUtilityClass` function specific to a component to generate the classes.\n */\nexport function useClassNamesOverride(generateUtilityClass) {\n const {\n disableDefaultClasses\n } = React.useContext(ClassNameConfiguratorContext);\n return slot => {\n if (disableDefaultClasses) {\n return '';\n }\n return generateUtilityClass(slot);\n };\n}\n\n/**\n * Allows to configure the components within to not apply any built-in classes.\n */\nexport function ClassNameConfigurator(props) {\n const {\n disableDefaultClasses,\n children\n } = props;\n const contextValue = React.useMemo(() => ({\n disableDefaultClasses: disableDefaultClasses != null ? disableDefaultClasses : false\n }), [disableDefaultClasses]);\n return /*#__PURE__*/_jsx(ClassNameConfiguratorContext.Provider, {\n value: contextValue,\n children: children\n });\n}","/**\n * Extracts event handlers from a given object.\n * A prop is considered an event handler if it is a function and its name starts with `on`.\n *\n * @param object An object to extract event handlers from.\n * @param excludeKeys An array of keys to exclude from the returned object.\n */\nexport function extractEventHandlers(object, excludeKeys = []) {\n if (object === undefined) {\n return {};\n }\n const result = {};\n Object.keys(object).filter(prop => prop.match(/^on[A-Z]/) && typeof object[prop] === 'function' && !excludeKeys.includes(prop)).forEach(prop => {\n result[prop] = object[prop];\n });\n return result;\n}","/**\n * If `componentProps` is a function, calls it with the provided `ownerState`.\n * Otherwise, just returns `componentProps`.\n */\nexport function resolveComponentProps(componentProps, ownerState, slotState) {\n if (typeof componentProps === 'function') {\n return componentProps(ownerState, slotState);\n }\n return componentProps;\n}","/**\n * Removes event handlers from the given object.\n * A field is considered an event handler if it is a function with a name beginning with `on`.\n *\n * @param object Object to remove event handlers from.\n * @returns Object with event handlers removed.\n */\nexport function omitEventHandlers(object) {\n if (object === undefined) {\n return {};\n }\n const result = {};\n Object.keys(object).filter(prop => !(prop.match(/^on[A-Z]/) && typeof object[prop] === 'function')).forEach(prop => {\n result[prop] = object[prop];\n });\n return result;\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport clsx from 'clsx';\nimport { extractEventHandlers } from './extractEventHandlers';\nimport { omitEventHandlers } from './omitEventHandlers';\n/**\n * Merges the slot component internal props (usually coming from a hook)\n * with the externally provided ones.\n *\n * The merge order is (the latter overrides the former):\n * 1. The internal props (specified as a getter function to work with get*Props hook result)\n * 2. Additional props (specified internally on a Base UI component)\n * 3. External props specified on the owner component. These should only be used on a root slot.\n * 4. External props specified in the `slotProps.*` prop.\n * 5. The `className` prop - combined from all the above.\n * @param parameters\n * @returns\n */\nexport function mergeSlotProps(parameters) {\n const {\n getSlotProps,\n additionalProps,\n externalSlotProps,\n externalForwardedProps,\n className\n } = parameters;\n if (!getSlotProps) {\n // The simpler case - getSlotProps is not defined, so no internal event handlers are defined,\n // so we can simply merge all the props without having to worry about extracting event handlers.\n const joinedClasses = clsx(additionalProps == null ? void 0 : additionalProps.className, className, externalForwardedProps == null ? void 0 : externalForwardedProps.className, externalSlotProps == null ? void 0 : externalSlotProps.className);\n const mergedStyle = _extends({}, additionalProps == null ? void 0 : additionalProps.style, externalForwardedProps == null ? void 0 : externalForwardedProps.style, externalSlotProps == null ? void 0 : externalSlotProps.style);\n const props = _extends({}, additionalProps, externalForwardedProps, externalSlotProps);\n if (joinedClasses.length > 0) {\n props.className = joinedClasses;\n }\n if (Object.keys(mergedStyle).length > 0) {\n props.style = mergedStyle;\n }\n return {\n props,\n internalRef: undefined\n };\n }\n\n // In this case, getSlotProps is responsible for calling the external event handlers.\n // We don't need to include them in the merged props because of this.\n\n const eventHandlers = extractEventHandlers(_extends({}, externalForwardedProps, externalSlotProps));\n const componentsPropsWithoutEventHandlers = omitEventHandlers(externalSlotProps);\n const otherPropsWithoutEventHandlers = omitEventHandlers(externalForwardedProps);\n const internalSlotProps = getSlotProps(eventHandlers);\n\n // The order of classes is important here.\n // Emotion (that we use in libraries consuming Base UI) depends on this order\n // to properly override style. It requires the most important classes to be last\n // (see https://github.com/mui/material-ui/pull/33205) for the related discussion.\n const joinedClasses = clsx(internalSlotProps == null ? void 0 : internalSlotProps.className, additionalProps == null ? void 0 : additionalProps.className, className, externalForwardedProps == null ? void 0 : externalForwardedProps.className, externalSlotProps == null ? void 0 : externalSlotProps.className);\n const mergedStyle = _extends({}, internalSlotProps == null ? void 0 : internalSlotProps.style, additionalProps == null ? void 0 : additionalProps.style, externalForwardedProps == null ? void 0 : externalForwardedProps.style, externalSlotProps == null ? void 0 : externalSlotProps.style);\n const props = _extends({}, internalSlotProps, additionalProps, otherPropsWithoutEventHandlers, componentsPropsWithoutEventHandlers);\n if (joinedClasses.length > 0) {\n props.className = joinedClasses;\n }\n if (Object.keys(mergedStyle).length > 0) {\n props.style = mergedStyle;\n }\n return {\n props,\n internalRef: internalSlotProps.ref\n };\n}","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"elementType\", \"externalSlotProps\", \"ownerState\", \"skipResolvingSlotProps\"];\nimport { unstable_useForkRef as useForkRef } from '@mui/utils';\nimport { appendOwnerState } from './appendOwnerState';\nimport { mergeSlotProps } from './mergeSlotProps';\nimport { resolveComponentProps } from './resolveComponentProps';\n/**\n * @ignore - do not document.\n * Builds the props to be passed into the slot of an unstyled component.\n * It merges the internal props of the component with the ones supplied by the user, allowing to customize the behavior.\n * If the slot component is not a host component, it also merges in the `ownerState`.\n *\n * @param parameters.getSlotProps - A function that returns the props to be passed to the slot component.\n */\nexport function useSlotProps(parameters) {\n var _parameters$additiona;\n const {\n elementType,\n externalSlotProps,\n ownerState,\n skipResolvingSlotProps = false\n } = parameters,\n rest = _objectWithoutPropertiesLoose(parameters, _excluded);\n const resolvedComponentsProps = skipResolvingSlotProps ? {} : resolveComponentProps(externalSlotProps, ownerState);\n const {\n props: mergedProps,\n internalRef\n } = mergeSlotProps(_extends({}, rest, {\n externalSlotProps: resolvedComponentsProps\n }));\n const ref = useForkRef(internalRef, resolvedComponentsProps == null ? void 0 : resolvedComponentsProps.ref, (_parameters$additiona = parameters.additionalProps) == null ? void 0 : _parameters$additiona.ref);\n const props = appendOwnerState(elementType, _extends({}, mergedProps, {\n ref\n }), ownerState);\n return props;\n}","import { globalStateClasses } from '@mui/utils/generateUtilityClass';\nconst GLOBAL_CLASS_PREFIX = 'base';\nfunction buildStateClass(state) {\n return `${GLOBAL_CLASS_PREFIX}--${state}`;\n}\nfunction buildSlotClass(componentName, slot) {\n return `${GLOBAL_CLASS_PREFIX}-${componentName}-${slot}`;\n}\nexport function generateUtilityClass(componentName, slot) {\n const globalStateClass = globalStateClasses[slot];\n return globalStateClass ? buildStateClass(globalStateClass) : buildSlotClass(componentName, slot);\n}\nexport function isGlobalState(slot) {\n return globalStateClasses[slot] !== undefined;\n}","import { generateUtilityClass } from '../generateUtilityClass';\nexport function generateUtilityClasses(componentName, slots) {\n const result = {};\n slots.forEach(slot => {\n result[slot] = generateUtilityClass(componentName, slot);\n });\n return result;\n}","'use client';\n\nimport * as React from 'react';\nimport * as ReactDOM from 'react-dom';\nimport PropTypes from 'prop-types';\nimport { exactProp, HTMLElementType, unstable_useEnhancedEffect as useEnhancedEffect, unstable_useForkRef as useForkRef, unstable_setRef as setRef } from '@mui/utils';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nfunction getContainer(container) {\n return typeof container === 'function' ? container() : container;\n}\n\n/**\n * Portals provide a first-class way to render children into a DOM node\n * that exists outside the DOM hierarchy of the parent component.\n *\n * Demos:\n *\n * - [Portal](https://mui.com/base-ui/react-portal/)\n *\n * API:\n *\n * - [Portal API](https://mui.com/base-ui/react-portal/components-api/#portal)\n */\nconst Portal = /*#__PURE__*/React.forwardRef(function Portal(props, forwardedRef) {\n const {\n children,\n container,\n disablePortal = false\n } = props;\n const [mountNode, setMountNode] = React.useState(null);\n // @ts-expect-error TODO upstream fix\n const handleRef = useForkRef( /*#__PURE__*/React.isValidElement(children) ? children.ref : null, forwardedRef);\n useEnhancedEffect(() => {\n if (!disablePortal) {\n setMountNode(getContainer(container) || document.body);\n }\n }, [container, disablePortal]);\n useEnhancedEffect(() => {\n if (mountNode && !disablePortal) {\n setRef(forwardedRef, mountNode);\n return () => {\n setRef(forwardedRef, null);\n };\n }\n return undefined;\n }, [forwardedRef, mountNode, disablePortal]);\n if (disablePortal) {\n if ( /*#__PURE__*/React.isValidElement(children)) {\n const newProps = {\n ref: handleRef\n };\n return /*#__PURE__*/React.cloneElement(children, newProps);\n }\n return /*#__PURE__*/_jsx(React.Fragment, {\n children: children\n });\n }\n return /*#__PURE__*/_jsx(React.Fragment, {\n children: mountNode ? /*#__PURE__*/ReactDOM.createPortal(children, mountNode) : mountNode\n });\n});\nprocess.env.NODE_ENV !== \"production\" ? Portal.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * The children to render into the `container`.\n */\n children: PropTypes.node,\n /**\n * An HTML element or function that returns one.\n * The `container` will have the portal children appended to it.\n *\n * You can also provide a callback, which is called in a React layout effect.\n * This lets you set the container from a ref, and also makes server-side rendering possible.\n *\n * By default, it uses the body of the top-level document object,\n * so it's simply `document.body` most of the time.\n */\n container: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.func]),\n /**\n * The `children` will be under the DOM hierarchy of the parent component.\n * @default false\n */\n disablePortal: PropTypes.bool\n} : void 0;\nif (process.env.NODE_ENV !== 'production') {\n // eslint-disable-next-line\n Portal['propTypes' + ''] = exactProp(Portal.propTypes);\n}\nexport { Portal };","export var top = 'top';\nexport var bottom = 'bottom';\nexport var right = 'right';\nexport var left = 'left';\nexport var auto = 'auto';\nexport var basePlacements = [top, bottom, right, left];\nexport var start = 'start';\nexport var end = 'end';\nexport var clippingParents = 'clippingParents';\nexport var viewport = 'viewport';\nexport var popper = 'popper';\nexport var reference = 'reference';\nexport var variationPlacements = /*#__PURE__*/basePlacements.reduce(function (acc, placement) {\n return acc.concat([placement + \"-\" + start, placement + \"-\" + end]);\n}, []);\nexport var placements = /*#__PURE__*/[].concat(basePlacements, [auto]).reduce(function (acc, placement) {\n return acc.concat([placement, placement + \"-\" + start, placement + \"-\" + end]);\n}, []); // modifiers that need to read the DOM\n\nexport var beforeRead = 'beforeRead';\nexport var read = 'read';\nexport var afterRead = 'afterRead'; // pure-logic modifiers\n\nexport var beforeMain = 'beforeMain';\nexport var main = 'main';\nexport var afterMain = 'afterMain'; // modifier with the purpose to write to the DOM (or write into a framework state)\n\nexport var beforeWrite = 'beforeWrite';\nexport var write = 'write';\nexport var afterWrite = 'afterWrite';\nexport var modifierPhases = [beforeRead, read, afterRead, beforeMain, main, afterMain, beforeWrite, write, afterWrite];","export default function getNodeName(element) {\n return element ? (element.nodeName || '').toLowerCase() : null;\n}","export default function getWindow(node) {\n if (node == null) {\n return window;\n }\n\n if (node.toString() !== '[object Window]') {\n var ownerDocument = node.ownerDocument;\n return ownerDocument ? ownerDocument.defaultView || window : window;\n }\n\n return node;\n}","import getWindow from \"./getWindow.js\";\n\nfunction isElement(node) {\n var OwnElement = getWindow(node).Element;\n return node instanceof OwnElement || node instanceof Element;\n}\n\nfunction isHTMLElement(node) {\n var OwnElement = getWindow(node).HTMLElement;\n return node instanceof OwnElement || node instanceof HTMLElement;\n}\n\nfunction isShadowRoot(node) {\n // IE 11 has no ShadowRoot\n if (typeof ShadowRoot === 'undefined') {\n return false;\n }\n\n var OwnElement = getWindow(node).ShadowRoot;\n return node instanceof OwnElement || node instanceof ShadowRoot;\n}\n\nexport { isElement, isHTMLElement, isShadowRoot };","import getNodeName from \"../dom-utils/getNodeName.js\";\nimport { isHTMLElement } from \"../dom-utils/instanceOf.js\"; // This modifier takes the styles prepared by the `computeStyles` modifier\n// and applies them to the HTMLElements such as popper and arrow\n\nfunction applyStyles(_ref) {\n var state = _ref.state;\n Object.keys(state.elements).forEach(function (name) {\n var style = state.styles[name] || {};\n var attributes = state.attributes[name] || {};\n var element = state.elements[name]; // arrow is optional + virtual elements\n\n if (!isHTMLElement(element) || !getNodeName(element)) {\n return;\n } // Flow doesn't support to extend this property, but it's the most\n // effective way to apply styles to an HTMLElement\n // $FlowFixMe[cannot-write]\n\n\n Object.assign(element.style, style);\n Object.keys(attributes).forEach(function (name) {\n var value = attributes[name];\n\n if (value === false) {\n element.removeAttribute(name);\n } else {\n element.setAttribute(name, value === true ? '' : value);\n }\n });\n });\n}\n\nfunction effect(_ref2) {\n var state = _ref2.state;\n var initialStyles = {\n popper: {\n position: state.options.strategy,\n left: '0',\n top: '0',\n margin: '0'\n },\n arrow: {\n position: 'absolute'\n },\n reference: {}\n };\n Object.assign(state.elements.popper.style, initialStyles.popper);\n state.styles = initialStyles;\n\n if (state.elements.arrow) {\n Object.assign(state.elements.arrow.style, initialStyles.arrow);\n }\n\n return function () {\n Object.keys(state.elements).forEach(function (name) {\n var element = state.elements[name];\n var attributes = state.attributes[name] || {};\n var styleProperties = Object.keys(state.styles.hasOwnProperty(name) ? state.styles[name] : initialStyles[name]); // Set all values to an empty string to unset them\n\n var style = styleProperties.reduce(function (style, property) {\n style[property] = '';\n return style;\n }, {}); // arrow is optional + virtual elements\n\n if (!isHTMLElement(element) || !getNodeName(element)) {\n return;\n }\n\n Object.assign(element.style, style);\n Object.keys(attributes).forEach(function (attribute) {\n element.removeAttribute(attribute);\n });\n });\n };\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'applyStyles',\n enabled: true,\n phase: 'write',\n fn: applyStyles,\n effect: effect,\n requires: ['computeStyles']\n};","import { auto } from \"../enums.js\";\nexport default function getBasePlacement(placement) {\n return placement.split('-')[0];\n}","export var max = Math.max;\nexport var min = Math.min;\nexport var round = Math.round;","export default function getUAString() {\n var uaData = navigator.userAgentData;\n\n if (uaData != null && uaData.brands && Array.isArray(uaData.brands)) {\n return uaData.brands.map(function (item) {\n return item.brand + \"/\" + item.version;\n }).join(' ');\n }\n\n return navigator.userAgent;\n}","import getUAString from \"../utils/userAgent.js\";\nexport default function isLayoutViewport() {\n return !/^((?!chrome|android).)*safari/i.test(getUAString());\n}","import { isElement, isHTMLElement } from \"./instanceOf.js\";\nimport { round } from \"../utils/math.js\";\nimport getWindow from \"./getWindow.js\";\nimport isLayoutViewport from \"./isLayoutViewport.js\";\nexport default function getBoundingClientRect(element, includeScale, isFixedStrategy) {\n if (includeScale === void 0) {\n includeScale = false;\n }\n\n if (isFixedStrategy === void 0) {\n isFixedStrategy = false;\n }\n\n var clientRect = element.getBoundingClientRect();\n var scaleX = 1;\n var scaleY = 1;\n\n if (includeScale && isHTMLElement(element)) {\n scaleX = element.offsetWidth > 0 ? round(clientRect.width) / element.offsetWidth || 1 : 1;\n scaleY = element.offsetHeight > 0 ? round(clientRect.height) / element.offsetHeight || 1 : 1;\n }\n\n var _ref = isElement(element) ? getWindow(element) : window,\n visualViewport = _ref.visualViewport;\n\n var addVisualOffsets = !isLayoutViewport() && isFixedStrategy;\n var x = (clientRect.left + (addVisualOffsets && visualViewport ? visualViewport.offsetLeft : 0)) / scaleX;\n var y = (clientRect.top + (addVisualOffsets && visualViewport ? visualViewport.offsetTop : 0)) / scaleY;\n var width = clientRect.width / scaleX;\n var height = clientRect.height / scaleY;\n return {\n width: width,\n height: height,\n top: y,\n right: x + width,\n bottom: y + height,\n left: x,\n x: x,\n y: y\n };\n}","import getBoundingClientRect from \"./getBoundingClientRect.js\"; // Returns the layout rect of an element relative to its offsetParent. Layout\n// means it doesn't take into account transforms.\n\nexport default function getLayoutRect(element) {\n var clientRect = getBoundingClientRect(element); // Use the clientRect sizes if it's not been transformed.\n // Fixes https://github.com/popperjs/popper-core/issues/1223\n\n var width = element.offsetWidth;\n var height = element.offsetHeight;\n\n if (Math.abs(clientRect.width - width) <= 1) {\n width = clientRect.width;\n }\n\n if (Math.abs(clientRect.height - height) <= 1) {\n height = clientRect.height;\n }\n\n return {\n x: element.offsetLeft,\n y: element.offsetTop,\n width: width,\n height: height\n };\n}","import { isShadowRoot } from \"./instanceOf.js\";\nexport default function contains(parent, child) {\n var rootNode = child.getRootNode && child.getRootNode(); // First, attempt with faster native method\n\n if (parent.contains(child)) {\n return true;\n } // then fallback to custom implementation with Shadow DOM support\n else if (rootNode && isShadowRoot(rootNode)) {\n var next = child;\n\n do {\n if (next && parent.isSameNode(next)) {\n return true;\n } // $FlowFixMe[prop-missing]: need a better way to handle this...\n\n\n next = next.parentNode || next.host;\n } while (next);\n } // Give up, the result is false\n\n\n return false;\n}","import getWindow from \"./getWindow.js\";\nexport default function getComputedStyle(element) {\n return getWindow(element).getComputedStyle(element);\n}","import getNodeName from \"./getNodeName.js\";\nexport default function isTableElement(element) {\n return ['table', 'td', 'th'].indexOf(getNodeName(element)) >= 0;\n}","import { isElement } from \"./instanceOf.js\";\nexport default function getDocumentElement(element) {\n // $FlowFixMe[incompatible-return]: assume body is always available\n return ((isElement(element) ? element.ownerDocument : // $FlowFixMe[prop-missing]\n element.document) || window.document).documentElement;\n}","import getNodeName from \"./getNodeName.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport { isShadowRoot } from \"./instanceOf.js\";\nexport default function getParentNode(element) {\n if (getNodeName(element) === 'html') {\n return element;\n }\n\n return (// this is a quicker (but less type safe) way to save quite some bytes from the bundle\n // $FlowFixMe[incompatible-return]\n // $FlowFixMe[prop-missing]\n element.assignedSlot || // step into the shadow DOM of the parent of a slotted node\n element.parentNode || ( // DOM Element detected\n isShadowRoot(element) ? element.host : null) || // ShadowRoot detected\n // $FlowFixMe[incompatible-call]: HTMLElement is a Node\n getDocumentElement(element) // fallback\n\n );\n}","import getWindow from \"./getWindow.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport getComputedStyle from \"./getComputedStyle.js\";\nimport { isHTMLElement, isShadowRoot } from \"./instanceOf.js\";\nimport isTableElement from \"./isTableElement.js\";\nimport getParentNode from \"./getParentNode.js\";\nimport getUAString from \"../utils/userAgent.js\";\n\nfunction getTrueOffsetParent(element) {\n if (!isHTMLElement(element) || // https://github.com/popperjs/popper-core/issues/837\n getComputedStyle(element).position === 'fixed') {\n return null;\n }\n\n return element.offsetParent;\n} // `.offsetParent` reports `null` for fixed elements, while absolute elements\n// return the containing block\n\n\nfunction getContainingBlock(element) {\n var isFirefox = /firefox/i.test(getUAString());\n var isIE = /Trident/i.test(getUAString());\n\n if (isIE && isHTMLElement(element)) {\n // In IE 9, 10 and 11 fixed elements containing block is always established by the viewport\n var elementCss = getComputedStyle(element);\n\n if (elementCss.position === 'fixed') {\n return null;\n }\n }\n\n var currentNode = getParentNode(element);\n\n if (isShadowRoot(currentNode)) {\n currentNode = currentNode.host;\n }\n\n while (isHTMLElement(currentNode) && ['html', 'body'].indexOf(getNodeName(currentNode)) < 0) {\n var css = getComputedStyle(currentNode); // This is non-exhaustive but covers the most common CSS properties that\n // create a containing block.\n // https://developer.mozilla.org/en-US/docs/Web/CSS/Containing_block#identifying_the_containing_block\n\n if (css.transform !== 'none' || css.perspective !== 'none' || css.contain === 'paint' || ['transform', 'perspective'].indexOf(css.willChange) !== -1 || isFirefox && css.willChange === 'filter' || isFirefox && css.filter && css.filter !== 'none') {\n return currentNode;\n } else {\n currentNode = currentNode.parentNode;\n }\n }\n\n return null;\n} // Gets the closest ancestor positioned element. Handles some edge cases,\n// such as table ancestors and cross browser bugs.\n\n\nexport default function getOffsetParent(element) {\n var window = getWindow(element);\n var offsetParent = getTrueOffsetParent(element);\n\n while (offsetParent && isTableElement(offsetParent) && getComputedStyle(offsetParent).position === 'static') {\n offsetParent = getTrueOffsetParent(offsetParent);\n }\n\n if (offsetParent && (getNodeName(offsetParent) === 'html' || getNodeName(offsetParent) === 'body' && getComputedStyle(offsetParent).position === 'static')) {\n return window;\n }\n\n return offsetParent || getContainingBlock(element) || window;\n}","export default function getMainAxisFromPlacement(placement) {\n return ['top', 'bottom'].indexOf(placement) >= 0 ? 'x' : 'y';\n}","import { max as mathMax, min as mathMin } from \"./math.js\";\nexport function within(min, value, max) {\n return mathMax(min, mathMin(value, max));\n}\nexport function withinMaxClamp(min, value, max) {\n var v = within(min, value, max);\n return v > max ? max : v;\n}","export default function getFreshSideObject() {\n return {\n top: 0,\n right: 0,\n bottom: 0,\n left: 0\n };\n}","import getFreshSideObject from \"./getFreshSideObject.js\";\nexport default function mergePaddingObject(paddingObject) {\n return Object.assign({}, getFreshSideObject(), paddingObject);\n}","export default function expandToHashMap(value, keys) {\n return keys.reduce(function (hashMap, key) {\n hashMap[key] = value;\n return hashMap;\n }, {});\n}","import getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getLayoutRect from \"../dom-utils/getLayoutRect.js\";\nimport contains from \"../dom-utils/contains.js\";\nimport getOffsetParent from \"../dom-utils/getOffsetParent.js\";\nimport getMainAxisFromPlacement from \"../utils/getMainAxisFromPlacement.js\";\nimport { within } from \"../utils/within.js\";\nimport mergePaddingObject from \"../utils/mergePaddingObject.js\";\nimport expandToHashMap from \"../utils/expandToHashMap.js\";\nimport { left, right, basePlacements, top, bottom } from \"../enums.js\"; // eslint-disable-next-line import/no-unused-modules\n\nvar toPaddingObject = function toPaddingObject(padding, state) {\n padding = typeof padding === 'function' ? padding(Object.assign({}, state.rects, {\n placement: state.placement\n })) : padding;\n return mergePaddingObject(typeof padding !== 'number' ? padding : expandToHashMap(padding, basePlacements));\n};\n\nfunction arrow(_ref) {\n var _state$modifiersData$;\n\n var state = _ref.state,\n name = _ref.name,\n options = _ref.options;\n var arrowElement = state.elements.arrow;\n var popperOffsets = state.modifiersData.popperOffsets;\n var basePlacement = getBasePlacement(state.placement);\n var axis = getMainAxisFromPlacement(basePlacement);\n var isVertical = [left, right].indexOf(basePlacement) >= 0;\n var len = isVertical ? 'height' : 'width';\n\n if (!arrowElement || !popperOffsets) {\n return;\n }\n\n var paddingObject = toPaddingObject(options.padding, state);\n var arrowRect = getLayoutRect(arrowElement);\n var minProp = axis === 'y' ? top : left;\n var maxProp = axis === 'y' ? bottom : right;\n var endDiff = state.rects.reference[len] + state.rects.reference[axis] - popperOffsets[axis] - state.rects.popper[len];\n var startDiff = popperOffsets[axis] - state.rects.reference[axis];\n var arrowOffsetParent = getOffsetParent(arrowElement);\n var clientSize = arrowOffsetParent ? axis === 'y' ? arrowOffsetParent.clientHeight || 0 : arrowOffsetParent.clientWidth || 0 : 0;\n var centerToReference = endDiff / 2 - startDiff / 2; // Make sure the arrow doesn't overflow the popper if the center point is\n // outside of the popper bounds\n\n var min = paddingObject[minProp];\n var max = clientSize - arrowRect[len] - paddingObject[maxProp];\n var center = clientSize / 2 - arrowRect[len] / 2 + centerToReference;\n var offset = within(min, center, max); // Prevents breaking syntax highlighting...\n\n var axisProp = axis;\n state.modifiersData[name] = (_state$modifiersData$ = {}, _state$modifiersData$[axisProp] = offset, _state$modifiersData$.centerOffset = offset - center, _state$modifiersData$);\n}\n\nfunction effect(_ref2) {\n var state = _ref2.state,\n options = _ref2.options;\n var _options$element = options.element,\n arrowElement = _options$element === void 0 ? '[data-popper-arrow]' : _options$element;\n\n if (arrowElement == null) {\n return;\n } // CSS selector\n\n\n if (typeof arrowElement === 'string') {\n arrowElement = state.elements.popper.querySelector(arrowElement);\n\n if (!arrowElement) {\n return;\n }\n }\n\n if (!contains(state.elements.popper, arrowElement)) {\n return;\n }\n\n state.elements.arrow = arrowElement;\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'arrow',\n enabled: true,\n phase: 'main',\n fn: arrow,\n effect: effect,\n requires: ['popperOffsets'],\n requiresIfExists: ['preventOverflow']\n};","export default function getVariation(placement) {\n return placement.split('-')[1];\n}","import { top, left, right, bottom, end } from \"../enums.js\";\nimport getOffsetParent from \"../dom-utils/getOffsetParent.js\";\nimport getWindow from \"../dom-utils/getWindow.js\";\nimport getDocumentElement from \"../dom-utils/getDocumentElement.js\";\nimport getComputedStyle from \"../dom-utils/getComputedStyle.js\";\nimport getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getVariation from \"../utils/getVariation.js\";\nimport { round } from \"../utils/math.js\"; // eslint-disable-next-line import/no-unused-modules\n\nvar unsetSides = {\n top: 'auto',\n right: 'auto',\n bottom: 'auto',\n left: 'auto'\n}; // Round the offsets to the nearest suitable subpixel based on the DPR.\n// Zooming can change the DPR, but it seems to report a value that will\n// cleanly divide the values into the appropriate subpixels.\n\nfunction roundOffsetsByDPR(_ref, win) {\n var x = _ref.x,\n y = _ref.y;\n var dpr = win.devicePixelRatio || 1;\n return {\n x: round(x * dpr) / dpr || 0,\n y: round(y * dpr) / dpr || 0\n };\n}\n\nexport function mapToStyles(_ref2) {\n var _Object$assign2;\n\n var popper = _ref2.popper,\n popperRect = _ref2.popperRect,\n placement = _ref2.placement,\n variation = _ref2.variation,\n offsets = _ref2.offsets,\n position = _ref2.position,\n gpuAcceleration = _ref2.gpuAcceleration,\n adaptive = _ref2.adaptive,\n roundOffsets = _ref2.roundOffsets,\n isFixed = _ref2.isFixed;\n var _offsets$x = offsets.x,\n x = _offsets$x === void 0 ? 0 : _offsets$x,\n _offsets$y = offsets.y,\n y = _offsets$y === void 0 ? 0 : _offsets$y;\n\n var _ref3 = typeof roundOffsets === 'function' ? roundOffsets({\n x: x,\n y: y\n }) : {\n x: x,\n y: y\n };\n\n x = _ref3.x;\n y = _ref3.y;\n var hasX = offsets.hasOwnProperty('x');\n var hasY = offsets.hasOwnProperty('y');\n var sideX = left;\n var sideY = top;\n var win = window;\n\n if (adaptive) {\n var offsetParent = getOffsetParent(popper);\n var heightProp = 'clientHeight';\n var widthProp = 'clientWidth';\n\n if (offsetParent === getWindow(popper)) {\n offsetParent = getDocumentElement(popper);\n\n if (getComputedStyle(offsetParent).position !== 'static' && position === 'absolute') {\n heightProp = 'scrollHeight';\n widthProp = 'scrollWidth';\n }\n } // $FlowFixMe[incompatible-cast]: force type refinement, we compare offsetParent with window above, but Flow doesn't detect it\n\n\n offsetParent = offsetParent;\n\n if (placement === top || (placement === left || placement === right) && variation === end) {\n sideY = bottom;\n var offsetY = isFixed && offsetParent === win && win.visualViewport ? win.visualViewport.height : // $FlowFixMe[prop-missing]\n offsetParent[heightProp];\n y -= offsetY - popperRect.height;\n y *= gpuAcceleration ? 1 : -1;\n }\n\n if (placement === left || (placement === top || placement === bottom) && variation === end) {\n sideX = right;\n var offsetX = isFixed && offsetParent === win && win.visualViewport ? win.visualViewport.width : // $FlowFixMe[prop-missing]\n offsetParent[widthProp];\n x -= offsetX - popperRect.width;\n x *= gpuAcceleration ? 1 : -1;\n }\n }\n\n var commonStyles = Object.assign({\n position: position\n }, adaptive && unsetSides);\n\n var _ref4 = roundOffsets === true ? roundOffsetsByDPR({\n x: x,\n y: y\n }, getWindow(popper)) : {\n x: x,\n y: y\n };\n\n x = _ref4.x;\n y = _ref4.y;\n\n if (gpuAcceleration) {\n var _Object$assign;\n\n return Object.assign({}, commonStyles, (_Object$assign = {}, _Object$assign[sideY] = hasY ? '0' : '', _Object$assign[sideX] = hasX ? '0' : '', _Object$assign.transform = (win.devicePixelRatio || 1) <= 1 ? \"translate(\" + x + \"px, \" + y + \"px)\" : \"translate3d(\" + x + \"px, \" + y + \"px, 0)\", _Object$assign));\n }\n\n return Object.assign({}, commonStyles, (_Object$assign2 = {}, _Object$assign2[sideY] = hasY ? y + \"px\" : '', _Object$assign2[sideX] = hasX ? x + \"px\" : '', _Object$assign2.transform = '', _Object$assign2));\n}\n\nfunction computeStyles(_ref5) {\n var state = _ref5.state,\n options = _ref5.options;\n var _options$gpuAccelerat = options.gpuAcceleration,\n gpuAcceleration = _options$gpuAccelerat === void 0 ? true : _options$gpuAccelerat,\n _options$adaptive = options.adaptive,\n adaptive = _options$adaptive === void 0 ? true : _options$adaptive,\n _options$roundOffsets = options.roundOffsets,\n roundOffsets = _options$roundOffsets === void 0 ? true : _options$roundOffsets;\n var commonStyles = {\n placement: getBasePlacement(state.placement),\n variation: getVariation(state.placement),\n popper: state.elements.popper,\n popperRect: state.rects.popper,\n gpuAcceleration: gpuAcceleration,\n isFixed: state.options.strategy === 'fixed'\n };\n\n if (state.modifiersData.popperOffsets != null) {\n state.styles.popper = Object.assign({}, state.styles.popper, mapToStyles(Object.assign({}, commonStyles, {\n offsets: state.modifiersData.popperOffsets,\n position: state.options.strategy,\n adaptive: adaptive,\n roundOffsets: roundOffsets\n })));\n }\n\n if (state.modifiersData.arrow != null) {\n state.styles.arrow = Object.assign({}, state.styles.arrow, mapToStyles(Object.assign({}, commonStyles, {\n offsets: state.modifiersData.arrow,\n position: 'absolute',\n adaptive: false,\n roundOffsets: roundOffsets\n })));\n }\n\n state.attributes.popper = Object.assign({}, state.attributes.popper, {\n 'data-popper-placement': state.placement\n });\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'computeStyles',\n enabled: true,\n phase: 'beforeWrite',\n fn: computeStyles,\n data: {}\n};","import getWindow from \"../dom-utils/getWindow.js\"; // eslint-disable-next-line import/no-unused-modules\n\nvar passive = {\n passive: true\n};\n\nfunction effect(_ref) {\n var state = _ref.state,\n instance = _ref.instance,\n options = _ref.options;\n var _options$scroll = options.scroll,\n scroll = _options$scroll === void 0 ? true : _options$scroll,\n _options$resize = options.resize,\n resize = _options$resize === void 0 ? true : _options$resize;\n var window = getWindow(state.elements.popper);\n var scrollParents = [].concat(state.scrollParents.reference, state.scrollParents.popper);\n\n if (scroll) {\n scrollParents.forEach(function (scrollParent) {\n scrollParent.addEventListener('scroll', instance.update, passive);\n });\n }\n\n if (resize) {\n window.addEventListener('resize', instance.update, passive);\n }\n\n return function () {\n if (scroll) {\n scrollParents.forEach(function (scrollParent) {\n scrollParent.removeEventListener('scroll', instance.update, passive);\n });\n }\n\n if (resize) {\n window.removeEventListener('resize', instance.update, passive);\n }\n };\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'eventListeners',\n enabled: true,\n phase: 'write',\n fn: function fn() {},\n effect: effect,\n data: {}\n};","var hash = {\n left: 'right',\n right: 'left',\n bottom: 'top',\n top: 'bottom'\n};\nexport default function getOppositePlacement(placement) {\n return placement.replace(/left|right|bottom|top/g, function (matched) {\n return hash[matched];\n });\n}","var hash = {\n start: 'end',\n end: 'start'\n};\nexport default function getOppositeVariationPlacement(placement) {\n return placement.replace(/start|end/g, function (matched) {\n return hash[matched];\n });\n}","import getWindow from \"./getWindow.js\";\nexport default function getWindowScroll(node) {\n var win = getWindow(node);\n var scrollLeft = win.pageXOffset;\n var scrollTop = win.pageYOffset;\n return {\n scrollLeft: scrollLeft,\n scrollTop: scrollTop\n };\n}","import getBoundingClientRect from \"./getBoundingClientRect.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport getWindowScroll from \"./getWindowScroll.js\";\nexport default function getWindowScrollBarX(element) {\n // If has a CSS width greater than the viewport, then this will be\n // incorrect for RTL.\n // Popper 1 is broken in this case and never had a bug report so let's assume\n // it's not an issue. I don't think anyone ever specifies width on \n // anyway.\n // Browsers where the left scrollbar doesn't cause an issue report `0` for\n // this (e.g. Edge 2019, IE11, Safari)\n return getBoundingClientRect(getDocumentElement(element)).left + getWindowScroll(element).scrollLeft;\n}","import getWindow from \"./getWindow.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport getWindowScrollBarX from \"./getWindowScrollBarX.js\";\nimport isLayoutViewport from \"./isLayoutViewport.js\";\nexport default function getViewportRect(element, strategy) {\n var win = getWindow(element);\n var html = getDocumentElement(element);\n var visualViewport = win.visualViewport;\n var width = html.clientWidth;\n var height = html.clientHeight;\n var x = 0;\n var y = 0;\n\n if (visualViewport) {\n width = visualViewport.width;\n height = visualViewport.height;\n var layoutViewport = isLayoutViewport();\n\n if (layoutViewport || !layoutViewport && strategy === 'fixed') {\n x = visualViewport.offsetLeft;\n y = visualViewport.offsetTop;\n }\n }\n\n return {\n width: width,\n height: height,\n x: x + getWindowScrollBarX(element),\n y: y\n };\n}","import getDocumentElement from \"./getDocumentElement.js\";\nimport getComputedStyle from \"./getComputedStyle.js\";\nimport getWindowScrollBarX from \"./getWindowScrollBarX.js\";\nimport getWindowScroll from \"./getWindowScroll.js\";\nimport { max } from \"../utils/math.js\"; // Gets the entire size of the scrollable document area, even extending outside\n// of the `` and `` rect bounds if horizontally scrollable\n\nexport default function getDocumentRect(element) {\n var _element$ownerDocumen;\n\n var html = getDocumentElement(element);\n var winScroll = getWindowScroll(element);\n var body = (_element$ownerDocumen = element.ownerDocument) == null ? void 0 : _element$ownerDocumen.body;\n var width = max(html.scrollWidth, html.clientWidth, body ? body.scrollWidth : 0, body ? body.clientWidth : 0);\n var height = max(html.scrollHeight, html.clientHeight, body ? body.scrollHeight : 0, body ? body.clientHeight : 0);\n var x = -winScroll.scrollLeft + getWindowScrollBarX(element);\n var y = -winScroll.scrollTop;\n\n if (getComputedStyle(body || html).direction === 'rtl') {\n x += max(html.clientWidth, body ? body.clientWidth : 0) - width;\n }\n\n return {\n width: width,\n height: height,\n x: x,\n y: y\n };\n}","import getComputedStyle from \"./getComputedStyle.js\";\nexport default function isScrollParent(element) {\n // Firefox wants us to check `-x` and `-y` variations as well\n var _getComputedStyle = getComputedStyle(element),\n overflow = _getComputedStyle.overflow,\n overflowX = _getComputedStyle.overflowX,\n overflowY = _getComputedStyle.overflowY;\n\n return /auto|scroll|overlay|hidden/.test(overflow + overflowY + overflowX);\n}","import getParentNode from \"./getParentNode.js\";\nimport isScrollParent from \"./isScrollParent.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport { isHTMLElement } from \"./instanceOf.js\";\nexport default function getScrollParent(node) {\n if (['html', 'body', '#document'].indexOf(getNodeName(node)) >= 0) {\n // $FlowFixMe[incompatible-return]: assume body is always available\n return node.ownerDocument.body;\n }\n\n if (isHTMLElement(node) && isScrollParent(node)) {\n return node;\n }\n\n return getScrollParent(getParentNode(node));\n}","import getScrollParent from \"./getScrollParent.js\";\nimport getParentNode from \"./getParentNode.js\";\nimport getWindow from \"./getWindow.js\";\nimport isScrollParent from \"./isScrollParent.js\";\n/*\ngiven a DOM element, return the list of all scroll parents, up the list of ancesors\nuntil we get to the top window object. This list is what we attach scroll listeners\nto, because if any of these parent elements scroll, we'll need to re-calculate the\nreference element's position.\n*/\n\nexport default function listScrollParents(element, list) {\n var _element$ownerDocumen;\n\n if (list === void 0) {\n list = [];\n }\n\n var scrollParent = getScrollParent(element);\n var isBody = scrollParent === ((_element$ownerDocumen = element.ownerDocument) == null ? void 0 : _element$ownerDocumen.body);\n var win = getWindow(scrollParent);\n var target = isBody ? [win].concat(win.visualViewport || [], isScrollParent(scrollParent) ? scrollParent : []) : scrollParent;\n var updatedList = list.concat(target);\n return isBody ? updatedList : // $FlowFixMe[incompatible-call]: isBody tells us target will be an HTMLElement here\n updatedList.concat(listScrollParents(getParentNode(target)));\n}","export default function rectToClientRect(rect) {\n return Object.assign({}, rect, {\n left: rect.x,\n top: rect.y,\n right: rect.x + rect.width,\n bottom: rect.y + rect.height\n });\n}","import { viewport } from \"../enums.js\";\nimport getViewportRect from \"./getViewportRect.js\";\nimport getDocumentRect from \"./getDocumentRect.js\";\nimport listScrollParents from \"./listScrollParents.js\";\nimport getOffsetParent from \"./getOffsetParent.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport getComputedStyle from \"./getComputedStyle.js\";\nimport { isElement, isHTMLElement } from \"./instanceOf.js\";\nimport getBoundingClientRect from \"./getBoundingClientRect.js\";\nimport getParentNode from \"./getParentNode.js\";\nimport contains from \"./contains.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport rectToClientRect from \"../utils/rectToClientRect.js\";\nimport { max, min } from \"../utils/math.js\";\n\nfunction getInnerBoundingClientRect(element, strategy) {\n var rect = getBoundingClientRect(element, false, strategy === 'fixed');\n rect.top = rect.top + element.clientTop;\n rect.left = rect.left + element.clientLeft;\n rect.bottom = rect.top + element.clientHeight;\n rect.right = rect.left + element.clientWidth;\n rect.width = element.clientWidth;\n rect.height = element.clientHeight;\n rect.x = rect.left;\n rect.y = rect.top;\n return rect;\n}\n\nfunction getClientRectFromMixedType(element, clippingParent, strategy) {\n return clippingParent === viewport ? rectToClientRect(getViewportRect(element, strategy)) : isElement(clippingParent) ? getInnerBoundingClientRect(clippingParent, strategy) : rectToClientRect(getDocumentRect(getDocumentElement(element)));\n} // A \"clipping parent\" is an overflowable container with the characteristic of\n// clipping (or hiding) overflowing elements with a position different from\n// `initial`\n\n\nfunction getClippingParents(element) {\n var clippingParents = listScrollParents(getParentNode(element));\n var canEscapeClipping = ['absolute', 'fixed'].indexOf(getComputedStyle(element).position) >= 0;\n var clipperElement = canEscapeClipping && isHTMLElement(element) ? getOffsetParent(element) : element;\n\n if (!isElement(clipperElement)) {\n return [];\n } // $FlowFixMe[incompatible-return]: https://github.com/facebook/flow/issues/1414\n\n\n return clippingParents.filter(function (clippingParent) {\n return isElement(clippingParent) && contains(clippingParent, clipperElement) && getNodeName(clippingParent) !== 'body';\n });\n} // Gets the maximum area that the element is visible in due to any number of\n// clipping parents\n\n\nexport default function getClippingRect(element, boundary, rootBoundary, strategy) {\n var mainClippingParents = boundary === 'clippingParents' ? getClippingParents(element) : [].concat(boundary);\n var clippingParents = [].concat(mainClippingParents, [rootBoundary]);\n var firstClippingParent = clippingParents[0];\n var clippingRect = clippingParents.reduce(function (accRect, clippingParent) {\n var rect = getClientRectFromMixedType(element, clippingParent, strategy);\n accRect.top = max(rect.top, accRect.top);\n accRect.right = min(rect.right, accRect.right);\n accRect.bottom = min(rect.bottom, accRect.bottom);\n accRect.left = max(rect.left, accRect.left);\n return accRect;\n }, getClientRectFromMixedType(element, firstClippingParent, strategy));\n clippingRect.width = clippingRect.right - clippingRect.left;\n clippingRect.height = clippingRect.bottom - clippingRect.top;\n clippingRect.x = clippingRect.left;\n clippingRect.y = clippingRect.top;\n return clippingRect;\n}","import getBasePlacement from \"./getBasePlacement.js\";\nimport getVariation from \"./getVariation.js\";\nimport getMainAxisFromPlacement from \"./getMainAxisFromPlacement.js\";\nimport { top, right, bottom, left, start, end } from \"../enums.js\";\nexport default function computeOffsets(_ref) {\n var reference = _ref.reference,\n element = _ref.element,\n placement = _ref.placement;\n var basePlacement = placement ? getBasePlacement(placement) : null;\n var variation = placement ? getVariation(placement) : null;\n var commonX = reference.x + reference.width / 2 - element.width / 2;\n var commonY = reference.y + reference.height / 2 - element.height / 2;\n var offsets;\n\n switch (basePlacement) {\n case top:\n offsets = {\n x: commonX,\n y: reference.y - element.height\n };\n break;\n\n case bottom:\n offsets = {\n x: commonX,\n y: reference.y + reference.height\n };\n break;\n\n case right:\n offsets = {\n x: reference.x + reference.width,\n y: commonY\n };\n break;\n\n case left:\n offsets = {\n x: reference.x - element.width,\n y: commonY\n };\n break;\n\n default:\n offsets = {\n x: reference.x,\n y: reference.y\n };\n }\n\n var mainAxis = basePlacement ? getMainAxisFromPlacement(basePlacement) : null;\n\n if (mainAxis != null) {\n var len = mainAxis === 'y' ? 'height' : 'width';\n\n switch (variation) {\n case start:\n offsets[mainAxis] = offsets[mainAxis] - (reference[len] / 2 - element[len] / 2);\n break;\n\n case end:\n offsets[mainAxis] = offsets[mainAxis] + (reference[len] / 2 - element[len] / 2);\n break;\n\n default:\n }\n }\n\n return offsets;\n}","import getClippingRect from \"../dom-utils/getClippingRect.js\";\nimport getDocumentElement from \"../dom-utils/getDocumentElement.js\";\nimport getBoundingClientRect from \"../dom-utils/getBoundingClientRect.js\";\nimport computeOffsets from \"./computeOffsets.js\";\nimport rectToClientRect from \"./rectToClientRect.js\";\nimport { clippingParents, reference, popper, bottom, top, right, basePlacements, viewport } from \"../enums.js\";\nimport { isElement } from \"../dom-utils/instanceOf.js\";\nimport mergePaddingObject from \"./mergePaddingObject.js\";\nimport expandToHashMap from \"./expandToHashMap.js\"; // eslint-disable-next-line import/no-unused-modules\n\nexport default function detectOverflow(state, options) {\n if (options === void 0) {\n options = {};\n }\n\n var _options = options,\n _options$placement = _options.placement,\n placement = _options$placement === void 0 ? state.placement : _options$placement,\n _options$strategy = _options.strategy,\n strategy = _options$strategy === void 0 ? state.strategy : _options$strategy,\n _options$boundary = _options.boundary,\n boundary = _options$boundary === void 0 ? clippingParents : _options$boundary,\n _options$rootBoundary = _options.rootBoundary,\n rootBoundary = _options$rootBoundary === void 0 ? viewport : _options$rootBoundary,\n _options$elementConte = _options.elementContext,\n elementContext = _options$elementConte === void 0 ? popper : _options$elementConte,\n _options$altBoundary = _options.altBoundary,\n altBoundary = _options$altBoundary === void 0 ? false : _options$altBoundary,\n _options$padding = _options.padding,\n padding = _options$padding === void 0 ? 0 : _options$padding;\n var paddingObject = mergePaddingObject(typeof padding !== 'number' ? padding : expandToHashMap(padding, basePlacements));\n var altContext = elementContext === popper ? reference : popper;\n var popperRect = state.rects.popper;\n var element = state.elements[altBoundary ? altContext : elementContext];\n var clippingClientRect = getClippingRect(isElement(element) ? element : element.contextElement || getDocumentElement(state.elements.popper), boundary, rootBoundary, strategy);\n var referenceClientRect = getBoundingClientRect(state.elements.reference);\n var popperOffsets = computeOffsets({\n reference: referenceClientRect,\n element: popperRect,\n strategy: 'absolute',\n placement: placement\n });\n var popperClientRect = rectToClientRect(Object.assign({}, popperRect, popperOffsets));\n var elementClientRect = elementContext === popper ? popperClientRect : referenceClientRect; // positive = overflowing the clipping rect\n // 0 or negative = within the clipping rect\n\n var overflowOffsets = {\n top: clippingClientRect.top - elementClientRect.top + paddingObject.top,\n bottom: elementClientRect.bottom - clippingClientRect.bottom + paddingObject.bottom,\n left: clippingClientRect.left - elementClientRect.left + paddingObject.left,\n right: elementClientRect.right - clippingClientRect.right + paddingObject.right\n };\n var offsetData = state.modifiersData.offset; // Offsets can be applied only to the popper element\n\n if (elementContext === popper && offsetData) {\n var offset = offsetData[placement];\n Object.keys(overflowOffsets).forEach(function (key) {\n var multiply = [right, bottom].indexOf(key) >= 0 ? 1 : -1;\n var axis = [top, bottom].indexOf(key) >= 0 ? 'y' : 'x';\n overflowOffsets[key] += offset[axis] * multiply;\n });\n }\n\n return overflowOffsets;\n}","import getVariation from \"./getVariation.js\";\nimport { variationPlacements, basePlacements, placements as allPlacements } from \"../enums.js\";\nimport detectOverflow from \"./detectOverflow.js\";\nimport getBasePlacement from \"./getBasePlacement.js\";\nexport default function computeAutoPlacement(state, options) {\n if (options === void 0) {\n options = {};\n }\n\n var _options = options,\n placement = _options.placement,\n boundary = _options.boundary,\n rootBoundary = _options.rootBoundary,\n padding = _options.padding,\n flipVariations = _options.flipVariations,\n _options$allowedAutoP = _options.allowedAutoPlacements,\n allowedAutoPlacements = _options$allowedAutoP === void 0 ? allPlacements : _options$allowedAutoP;\n var variation = getVariation(placement);\n var placements = variation ? flipVariations ? variationPlacements : variationPlacements.filter(function (placement) {\n return getVariation(placement) === variation;\n }) : basePlacements;\n var allowedPlacements = placements.filter(function (placement) {\n return allowedAutoPlacements.indexOf(placement) >= 0;\n });\n\n if (allowedPlacements.length === 0) {\n allowedPlacements = placements;\n } // $FlowFixMe[incompatible-type]: Flow seems to have problems with two array unions...\n\n\n var overflows = allowedPlacements.reduce(function (acc, placement) {\n acc[placement] = detectOverflow(state, {\n placement: placement,\n boundary: boundary,\n rootBoundary: rootBoundary,\n padding: padding\n })[getBasePlacement(placement)];\n return acc;\n }, {});\n return Object.keys(overflows).sort(function (a, b) {\n return overflows[a] - overflows[b];\n });\n}","import getOppositePlacement from \"../utils/getOppositePlacement.js\";\nimport getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getOppositeVariationPlacement from \"../utils/getOppositeVariationPlacement.js\";\nimport detectOverflow from \"../utils/detectOverflow.js\";\nimport computeAutoPlacement from \"../utils/computeAutoPlacement.js\";\nimport { bottom, top, start, right, left, auto } from \"../enums.js\";\nimport getVariation from \"../utils/getVariation.js\"; // eslint-disable-next-line import/no-unused-modules\n\nfunction getExpandedFallbackPlacements(placement) {\n if (getBasePlacement(placement) === auto) {\n return [];\n }\n\n var oppositePlacement = getOppositePlacement(placement);\n return [getOppositeVariationPlacement(placement), oppositePlacement, getOppositeVariationPlacement(oppositePlacement)];\n}\n\nfunction flip(_ref) {\n var state = _ref.state,\n options = _ref.options,\n name = _ref.name;\n\n if (state.modifiersData[name]._skip) {\n return;\n }\n\n var _options$mainAxis = options.mainAxis,\n checkMainAxis = _options$mainAxis === void 0 ? true : _options$mainAxis,\n _options$altAxis = options.altAxis,\n checkAltAxis = _options$altAxis === void 0 ? true : _options$altAxis,\n specifiedFallbackPlacements = options.fallbackPlacements,\n padding = options.padding,\n boundary = options.boundary,\n rootBoundary = options.rootBoundary,\n altBoundary = options.altBoundary,\n _options$flipVariatio = options.flipVariations,\n flipVariations = _options$flipVariatio === void 0 ? true : _options$flipVariatio,\n allowedAutoPlacements = options.allowedAutoPlacements;\n var preferredPlacement = state.options.placement;\n var basePlacement = getBasePlacement(preferredPlacement);\n var isBasePlacement = basePlacement === preferredPlacement;\n var fallbackPlacements = specifiedFallbackPlacements || (isBasePlacement || !flipVariations ? [getOppositePlacement(preferredPlacement)] : getExpandedFallbackPlacements(preferredPlacement));\n var placements = [preferredPlacement].concat(fallbackPlacements).reduce(function (acc, placement) {\n return acc.concat(getBasePlacement(placement) === auto ? computeAutoPlacement(state, {\n placement: placement,\n boundary: boundary,\n rootBoundary: rootBoundary,\n padding: padding,\n flipVariations: flipVariations,\n allowedAutoPlacements: allowedAutoPlacements\n }) : placement);\n }, []);\n var referenceRect = state.rects.reference;\n var popperRect = state.rects.popper;\n var checksMap = new Map();\n var makeFallbackChecks = true;\n var firstFittingPlacement = placements[0];\n\n for (var i = 0; i < placements.length; i++) {\n var placement = placements[i];\n\n var _basePlacement = getBasePlacement(placement);\n\n var isStartVariation = getVariation(placement) === start;\n var isVertical = [top, bottom].indexOf(_basePlacement) >= 0;\n var len = isVertical ? 'width' : 'height';\n var overflow = detectOverflow(state, {\n placement: placement,\n boundary: boundary,\n rootBoundary: rootBoundary,\n altBoundary: altBoundary,\n padding: padding\n });\n var mainVariationSide = isVertical ? isStartVariation ? right : left : isStartVariation ? bottom : top;\n\n if (referenceRect[len] > popperRect[len]) {\n mainVariationSide = getOppositePlacement(mainVariationSide);\n }\n\n var altVariationSide = getOppositePlacement(mainVariationSide);\n var checks = [];\n\n if (checkMainAxis) {\n checks.push(overflow[_basePlacement] <= 0);\n }\n\n if (checkAltAxis) {\n checks.push(overflow[mainVariationSide] <= 0, overflow[altVariationSide] <= 0);\n }\n\n if (checks.every(function (check) {\n return check;\n })) {\n firstFittingPlacement = placement;\n makeFallbackChecks = false;\n break;\n }\n\n checksMap.set(placement, checks);\n }\n\n if (makeFallbackChecks) {\n // `2` may be desired in some cases – research later\n var numberOfChecks = flipVariations ? 3 : 1;\n\n var _loop = function _loop(_i) {\n var fittingPlacement = placements.find(function (placement) {\n var checks = checksMap.get(placement);\n\n if (checks) {\n return checks.slice(0, _i).every(function (check) {\n return check;\n });\n }\n });\n\n if (fittingPlacement) {\n firstFittingPlacement = fittingPlacement;\n return \"break\";\n }\n };\n\n for (var _i = numberOfChecks; _i > 0; _i--) {\n var _ret = _loop(_i);\n\n if (_ret === \"break\") break;\n }\n }\n\n if (state.placement !== firstFittingPlacement) {\n state.modifiersData[name]._skip = true;\n state.placement = firstFittingPlacement;\n state.reset = true;\n }\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'flip',\n enabled: true,\n phase: 'main',\n fn: flip,\n requiresIfExists: ['offset'],\n data: {\n _skip: false\n }\n};","import { top, bottom, left, right } from \"../enums.js\";\nimport detectOverflow from \"../utils/detectOverflow.js\";\n\nfunction getSideOffsets(overflow, rect, preventedOffsets) {\n if (preventedOffsets === void 0) {\n preventedOffsets = {\n x: 0,\n y: 0\n };\n }\n\n return {\n top: overflow.top - rect.height - preventedOffsets.y,\n right: overflow.right - rect.width + preventedOffsets.x,\n bottom: overflow.bottom - rect.height + preventedOffsets.y,\n left: overflow.left - rect.width - preventedOffsets.x\n };\n}\n\nfunction isAnySideFullyClipped(overflow) {\n return [top, right, bottom, left].some(function (side) {\n return overflow[side] >= 0;\n });\n}\n\nfunction hide(_ref) {\n var state = _ref.state,\n name = _ref.name;\n var referenceRect = state.rects.reference;\n var popperRect = state.rects.popper;\n var preventedOffsets = state.modifiersData.preventOverflow;\n var referenceOverflow = detectOverflow(state, {\n elementContext: 'reference'\n });\n var popperAltOverflow = detectOverflow(state, {\n altBoundary: true\n });\n var referenceClippingOffsets = getSideOffsets(referenceOverflow, referenceRect);\n var popperEscapeOffsets = getSideOffsets(popperAltOverflow, popperRect, preventedOffsets);\n var isReferenceHidden = isAnySideFullyClipped(referenceClippingOffsets);\n var hasPopperEscaped = isAnySideFullyClipped(popperEscapeOffsets);\n state.modifiersData[name] = {\n referenceClippingOffsets: referenceClippingOffsets,\n popperEscapeOffsets: popperEscapeOffsets,\n isReferenceHidden: isReferenceHidden,\n hasPopperEscaped: hasPopperEscaped\n };\n state.attributes.popper = Object.assign({}, state.attributes.popper, {\n 'data-popper-reference-hidden': isReferenceHidden,\n 'data-popper-escaped': hasPopperEscaped\n });\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'hide',\n enabled: true,\n phase: 'main',\n requiresIfExists: ['preventOverflow'],\n fn: hide\n};","import getBasePlacement from \"../utils/getBasePlacement.js\";\nimport { top, left, right, placements } from \"../enums.js\"; // eslint-disable-next-line import/no-unused-modules\n\nexport function distanceAndSkiddingToXY(placement, rects, offset) {\n var basePlacement = getBasePlacement(placement);\n var invertDistance = [left, top].indexOf(basePlacement) >= 0 ? -1 : 1;\n\n var _ref = typeof offset === 'function' ? offset(Object.assign({}, rects, {\n placement: placement\n })) : offset,\n skidding = _ref[0],\n distance = _ref[1];\n\n skidding = skidding || 0;\n distance = (distance || 0) * invertDistance;\n return [left, right].indexOf(basePlacement) >= 0 ? {\n x: distance,\n y: skidding\n } : {\n x: skidding,\n y: distance\n };\n}\n\nfunction offset(_ref2) {\n var state = _ref2.state,\n options = _ref2.options,\n name = _ref2.name;\n var _options$offset = options.offset,\n offset = _options$offset === void 0 ? [0, 0] : _options$offset;\n var data = placements.reduce(function (acc, placement) {\n acc[placement] = distanceAndSkiddingToXY(placement, state.rects, offset);\n return acc;\n }, {});\n var _data$state$placement = data[state.placement],\n x = _data$state$placement.x,\n y = _data$state$placement.y;\n\n if (state.modifiersData.popperOffsets != null) {\n state.modifiersData.popperOffsets.x += x;\n state.modifiersData.popperOffsets.y += y;\n }\n\n state.modifiersData[name] = data;\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'offset',\n enabled: true,\n phase: 'main',\n requires: ['popperOffsets'],\n fn: offset\n};","import computeOffsets from \"../utils/computeOffsets.js\";\n\nfunction popperOffsets(_ref) {\n var state = _ref.state,\n name = _ref.name;\n // Offsets are the actual position the popper needs to have to be\n // properly positioned near its reference element\n // This is the most basic placement, and will be adjusted by\n // the modifiers in the next step\n state.modifiersData[name] = computeOffsets({\n reference: state.rects.reference,\n element: state.rects.popper,\n strategy: 'absolute',\n placement: state.placement\n });\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'popperOffsets',\n enabled: true,\n phase: 'read',\n fn: popperOffsets,\n data: {}\n};","export default function getAltAxis(axis) {\n return axis === 'x' ? 'y' : 'x';\n}","import { top, left, right, bottom, start } from \"../enums.js\";\nimport getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getMainAxisFromPlacement from \"../utils/getMainAxisFromPlacement.js\";\nimport getAltAxis from \"../utils/getAltAxis.js\";\nimport { within, withinMaxClamp } from \"../utils/within.js\";\nimport getLayoutRect from \"../dom-utils/getLayoutRect.js\";\nimport getOffsetParent from \"../dom-utils/getOffsetParent.js\";\nimport detectOverflow from \"../utils/detectOverflow.js\";\nimport getVariation from \"../utils/getVariation.js\";\nimport getFreshSideObject from \"../utils/getFreshSideObject.js\";\nimport { min as mathMin, max as mathMax } from \"../utils/math.js\";\n\nfunction preventOverflow(_ref) {\n var state = _ref.state,\n options = _ref.options,\n name = _ref.name;\n var _options$mainAxis = options.mainAxis,\n checkMainAxis = _options$mainAxis === void 0 ? true : _options$mainAxis,\n _options$altAxis = options.altAxis,\n checkAltAxis = _options$altAxis === void 0 ? false : _options$altAxis,\n boundary = options.boundary,\n rootBoundary = options.rootBoundary,\n altBoundary = options.altBoundary,\n padding = options.padding,\n _options$tether = options.tether,\n tether = _options$tether === void 0 ? true : _options$tether,\n _options$tetherOffset = options.tetherOffset,\n tetherOffset = _options$tetherOffset === void 0 ? 0 : _options$tetherOffset;\n var overflow = detectOverflow(state, {\n boundary: boundary,\n rootBoundary: rootBoundary,\n padding: padding,\n altBoundary: altBoundary\n });\n var basePlacement = getBasePlacement(state.placement);\n var variation = getVariation(state.placement);\n var isBasePlacement = !variation;\n var mainAxis = getMainAxisFromPlacement(basePlacement);\n var altAxis = getAltAxis(mainAxis);\n var popperOffsets = state.modifiersData.popperOffsets;\n var referenceRect = state.rects.reference;\n var popperRect = state.rects.popper;\n var tetherOffsetValue = typeof tetherOffset === 'function' ? tetherOffset(Object.assign({}, state.rects, {\n placement: state.placement\n })) : tetherOffset;\n var normalizedTetherOffsetValue = typeof tetherOffsetValue === 'number' ? {\n mainAxis: tetherOffsetValue,\n altAxis: tetherOffsetValue\n } : Object.assign({\n mainAxis: 0,\n altAxis: 0\n }, tetherOffsetValue);\n var offsetModifierState = state.modifiersData.offset ? state.modifiersData.offset[state.placement] : null;\n var data = {\n x: 0,\n y: 0\n };\n\n if (!popperOffsets) {\n return;\n }\n\n if (checkMainAxis) {\n var _offsetModifierState$;\n\n var mainSide = mainAxis === 'y' ? top : left;\n var altSide = mainAxis === 'y' ? bottom : right;\n var len = mainAxis === 'y' ? 'height' : 'width';\n var offset = popperOffsets[mainAxis];\n var min = offset + overflow[mainSide];\n var max = offset - overflow[altSide];\n var additive = tether ? -popperRect[len] / 2 : 0;\n var minLen = variation === start ? referenceRect[len] : popperRect[len];\n var maxLen = variation === start ? -popperRect[len] : -referenceRect[len]; // We need to include the arrow in the calculation so the arrow doesn't go\n // outside the reference bounds\n\n var arrowElement = state.elements.arrow;\n var arrowRect = tether && arrowElement ? getLayoutRect(arrowElement) : {\n width: 0,\n height: 0\n };\n var arrowPaddingObject = state.modifiersData['arrow#persistent'] ? state.modifiersData['arrow#persistent'].padding : getFreshSideObject();\n var arrowPaddingMin = arrowPaddingObject[mainSide];\n var arrowPaddingMax = arrowPaddingObject[altSide]; // If the reference length is smaller than the arrow length, we don't want\n // to include its full size in the calculation. If the reference is small\n // and near the edge of a boundary, the popper can overflow even if the\n // reference is not overflowing as well (e.g. virtual elements with no\n // width or height)\n\n var arrowLen = within(0, referenceRect[len], arrowRect[len]);\n var minOffset = isBasePlacement ? referenceRect[len] / 2 - additive - arrowLen - arrowPaddingMin - normalizedTetherOffsetValue.mainAxis : minLen - arrowLen - arrowPaddingMin - normalizedTetherOffsetValue.mainAxis;\n var maxOffset = isBasePlacement ? -referenceRect[len] / 2 + additive + arrowLen + arrowPaddingMax + normalizedTetherOffsetValue.mainAxis : maxLen + arrowLen + arrowPaddingMax + normalizedTetherOffsetValue.mainAxis;\n var arrowOffsetParent = state.elements.arrow && getOffsetParent(state.elements.arrow);\n var clientOffset = arrowOffsetParent ? mainAxis === 'y' ? arrowOffsetParent.clientTop || 0 : arrowOffsetParent.clientLeft || 0 : 0;\n var offsetModifierValue = (_offsetModifierState$ = offsetModifierState == null ? void 0 : offsetModifierState[mainAxis]) != null ? _offsetModifierState$ : 0;\n var tetherMin = offset + minOffset - offsetModifierValue - clientOffset;\n var tetherMax = offset + maxOffset - offsetModifierValue;\n var preventedOffset = within(tether ? mathMin(min, tetherMin) : min, offset, tether ? mathMax(max, tetherMax) : max);\n popperOffsets[mainAxis] = preventedOffset;\n data[mainAxis] = preventedOffset - offset;\n }\n\n if (checkAltAxis) {\n var _offsetModifierState$2;\n\n var _mainSide = mainAxis === 'x' ? top : left;\n\n var _altSide = mainAxis === 'x' ? bottom : right;\n\n var _offset = popperOffsets[altAxis];\n\n var _len = altAxis === 'y' ? 'height' : 'width';\n\n var _min = _offset + overflow[_mainSide];\n\n var _max = _offset - overflow[_altSide];\n\n var isOriginSide = [top, left].indexOf(basePlacement) !== -1;\n\n var _offsetModifierValue = (_offsetModifierState$2 = offsetModifierState == null ? void 0 : offsetModifierState[altAxis]) != null ? _offsetModifierState$2 : 0;\n\n var _tetherMin = isOriginSide ? _min : _offset - referenceRect[_len] - popperRect[_len] - _offsetModifierValue + normalizedTetherOffsetValue.altAxis;\n\n var _tetherMax = isOriginSide ? _offset + referenceRect[_len] + popperRect[_len] - _offsetModifierValue - normalizedTetherOffsetValue.altAxis : _max;\n\n var _preventedOffset = tether && isOriginSide ? withinMaxClamp(_tetherMin, _offset, _tetherMax) : within(tether ? _tetherMin : _min, _offset, tether ? _tetherMax : _max);\n\n popperOffsets[altAxis] = _preventedOffset;\n data[altAxis] = _preventedOffset - _offset;\n }\n\n state.modifiersData[name] = data;\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'preventOverflow',\n enabled: true,\n phase: 'main',\n fn: preventOverflow,\n requiresIfExists: ['offset']\n};","export default function getHTMLElementScroll(element) {\n return {\n scrollLeft: element.scrollLeft,\n scrollTop: element.scrollTop\n };\n}","import getWindowScroll from \"./getWindowScroll.js\";\nimport getWindow from \"./getWindow.js\";\nimport { isHTMLElement } from \"./instanceOf.js\";\nimport getHTMLElementScroll from \"./getHTMLElementScroll.js\";\nexport default function getNodeScroll(node) {\n if (node === getWindow(node) || !isHTMLElement(node)) {\n return getWindowScroll(node);\n } else {\n return getHTMLElementScroll(node);\n }\n}","import getBoundingClientRect from \"./getBoundingClientRect.js\";\nimport getNodeScroll from \"./getNodeScroll.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport { isHTMLElement } from \"./instanceOf.js\";\nimport getWindowScrollBarX from \"./getWindowScrollBarX.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport isScrollParent from \"./isScrollParent.js\";\nimport { round } from \"../utils/math.js\";\n\nfunction isElementScaled(element) {\n var rect = element.getBoundingClientRect();\n var scaleX = round(rect.width) / element.offsetWidth || 1;\n var scaleY = round(rect.height) / element.offsetHeight || 1;\n return scaleX !== 1 || scaleY !== 1;\n} // Returns the composite rect of an element relative to its offsetParent.\n// Composite means it takes into account transforms as well as layout.\n\n\nexport default function getCompositeRect(elementOrVirtualElement, offsetParent, isFixed) {\n if (isFixed === void 0) {\n isFixed = false;\n }\n\n var isOffsetParentAnElement = isHTMLElement(offsetParent);\n var offsetParentIsScaled = isHTMLElement(offsetParent) && isElementScaled(offsetParent);\n var documentElement = getDocumentElement(offsetParent);\n var rect = getBoundingClientRect(elementOrVirtualElement, offsetParentIsScaled, isFixed);\n var scroll = {\n scrollLeft: 0,\n scrollTop: 0\n };\n var offsets = {\n x: 0,\n y: 0\n };\n\n if (isOffsetParentAnElement || !isOffsetParentAnElement && !isFixed) {\n if (getNodeName(offsetParent) !== 'body' || // https://github.com/popperjs/popper-core/issues/1078\n isScrollParent(documentElement)) {\n scroll = getNodeScroll(offsetParent);\n }\n\n if (isHTMLElement(offsetParent)) {\n offsets = getBoundingClientRect(offsetParent, true);\n offsets.x += offsetParent.clientLeft;\n offsets.y += offsetParent.clientTop;\n } else if (documentElement) {\n offsets.x = getWindowScrollBarX(documentElement);\n }\n }\n\n return {\n x: rect.left + scroll.scrollLeft - offsets.x,\n y: rect.top + scroll.scrollTop - offsets.y,\n width: rect.width,\n height: rect.height\n };\n}","import { modifierPhases } from \"../enums.js\"; // source: https://stackoverflow.com/questions/49875255\n\nfunction order(modifiers) {\n var map = new Map();\n var visited = new Set();\n var result = [];\n modifiers.forEach(function (modifier) {\n map.set(modifier.name, modifier);\n }); // On visiting object, check for its dependencies and visit them recursively\n\n function sort(modifier) {\n visited.add(modifier.name);\n var requires = [].concat(modifier.requires || [], modifier.requiresIfExists || []);\n requires.forEach(function (dep) {\n if (!visited.has(dep)) {\n var depModifier = map.get(dep);\n\n if (depModifier) {\n sort(depModifier);\n }\n }\n });\n result.push(modifier);\n }\n\n modifiers.forEach(function (modifier) {\n if (!visited.has(modifier.name)) {\n // check for visited object\n sort(modifier);\n }\n });\n return result;\n}\n\nexport default function orderModifiers(modifiers) {\n // order based on dependencies\n var orderedModifiers = order(modifiers); // order based on phase\n\n return modifierPhases.reduce(function (acc, phase) {\n return acc.concat(orderedModifiers.filter(function (modifier) {\n return modifier.phase === phase;\n }));\n }, []);\n}","export default function debounce(fn) {\n var pending;\n return function () {\n if (!pending) {\n pending = new Promise(function (resolve) {\n Promise.resolve().then(function () {\n pending = undefined;\n resolve(fn());\n });\n });\n }\n\n return pending;\n };\n}","export default function mergeByName(modifiers) {\n var merged = modifiers.reduce(function (merged, current) {\n var existing = merged[current.name];\n merged[current.name] = existing ? Object.assign({}, existing, current, {\n options: Object.assign({}, existing.options, current.options),\n data: Object.assign({}, existing.data, current.data)\n }) : current;\n return merged;\n }, {}); // IE11 does not support Object.values\n\n return Object.keys(merged).map(function (key) {\n return merged[key];\n });\n}","import getCompositeRect from \"./dom-utils/getCompositeRect.js\";\nimport getLayoutRect from \"./dom-utils/getLayoutRect.js\";\nimport listScrollParents from \"./dom-utils/listScrollParents.js\";\nimport getOffsetParent from \"./dom-utils/getOffsetParent.js\";\nimport orderModifiers from \"./utils/orderModifiers.js\";\nimport debounce from \"./utils/debounce.js\";\nimport mergeByName from \"./utils/mergeByName.js\";\nimport detectOverflow from \"./utils/detectOverflow.js\";\nimport { isElement } from \"./dom-utils/instanceOf.js\";\nvar DEFAULT_OPTIONS = {\n placement: 'bottom',\n modifiers: [],\n strategy: 'absolute'\n};\n\nfunction areValidElements() {\n for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {\n args[_key] = arguments[_key];\n }\n\n return !args.some(function (element) {\n return !(element && typeof element.getBoundingClientRect === 'function');\n });\n}\n\nexport function popperGenerator(generatorOptions) {\n if (generatorOptions === void 0) {\n generatorOptions = {};\n }\n\n var _generatorOptions = generatorOptions,\n _generatorOptions$def = _generatorOptions.defaultModifiers,\n defaultModifiers = _generatorOptions$def === void 0 ? [] : _generatorOptions$def,\n _generatorOptions$def2 = _generatorOptions.defaultOptions,\n defaultOptions = _generatorOptions$def2 === void 0 ? DEFAULT_OPTIONS : _generatorOptions$def2;\n return function createPopper(reference, popper, options) {\n if (options === void 0) {\n options = defaultOptions;\n }\n\n var state = {\n placement: 'bottom',\n orderedModifiers: [],\n options: Object.assign({}, DEFAULT_OPTIONS, defaultOptions),\n modifiersData: {},\n elements: {\n reference: reference,\n popper: popper\n },\n attributes: {},\n styles: {}\n };\n var effectCleanupFns = [];\n var isDestroyed = false;\n var instance = {\n state: state,\n setOptions: function setOptions(setOptionsAction) {\n var options = typeof setOptionsAction === 'function' ? setOptionsAction(state.options) : setOptionsAction;\n cleanupModifierEffects();\n state.options = Object.assign({}, defaultOptions, state.options, options);\n state.scrollParents = {\n reference: isElement(reference) ? listScrollParents(reference) : reference.contextElement ? listScrollParents(reference.contextElement) : [],\n popper: listScrollParents(popper)\n }; // Orders the modifiers based on their dependencies and `phase`\n // properties\n\n var orderedModifiers = orderModifiers(mergeByName([].concat(defaultModifiers, state.options.modifiers))); // Strip out disabled modifiers\n\n state.orderedModifiers = orderedModifiers.filter(function (m) {\n return m.enabled;\n });\n runModifierEffects();\n return instance.update();\n },\n // Sync update – it will always be executed, even if not necessary. This\n // is useful for low frequency updates where sync behavior simplifies the\n // logic.\n // For high frequency updates (e.g. `resize` and `scroll` events), always\n // prefer the async Popper#update method\n forceUpdate: function forceUpdate() {\n if (isDestroyed) {\n return;\n }\n\n var _state$elements = state.elements,\n reference = _state$elements.reference,\n popper = _state$elements.popper; // Don't proceed if `reference` or `popper` are not valid elements\n // anymore\n\n if (!areValidElements(reference, popper)) {\n return;\n } // Store the reference and popper rects to be read by modifiers\n\n\n state.rects = {\n reference: getCompositeRect(reference, getOffsetParent(popper), state.options.strategy === 'fixed'),\n popper: getLayoutRect(popper)\n }; // Modifiers have the ability to reset the current update cycle. The\n // most common use case for this is the `flip` modifier changing the\n // placement, which then needs to re-run all the modifiers, because the\n // logic was previously ran for the previous placement and is therefore\n // stale/incorrect\n\n state.reset = false;\n state.placement = state.options.placement; // On each update cycle, the `modifiersData` property for each modifier\n // is filled with the initial data specified by the modifier. This means\n // it doesn't persist and is fresh on each update.\n // To ensure persistent data, use `${name}#persistent`\n\n state.orderedModifiers.forEach(function (modifier) {\n return state.modifiersData[modifier.name] = Object.assign({}, modifier.data);\n });\n\n for (var index = 0; index < state.orderedModifiers.length; index++) {\n if (state.reset === true) {\n state.reset = false;\n index = -1;\n continue;\n }\n\n var _state$orderedModifie = state.orderedModifiers[index],\n fn = _state$orderedModifie.fn,\n _state$orderedModifie2 = _state$orderedModifie.options,\n _options = _state$orderedModifie2 === void 0 ? {} : _state$orderedModifie2,\n name = _state$orderedModifie.name;\n\n if (typeof fn === 'function') {\n state = fn({\n state: state,\n options: _options,\n name: name,\n instance: instance\n }) || state;\n }\n }\n },\n // Async and optimistically optimized update – it will not be executed if\n // not necessary (debounced to run at most once-per-tick)\n update: debounce(function () {\n return new Promise(function (resolve) {\n instance.forceUpdate();\n resolve(state);\n });\n }),\n destroy: function destroy() {\n cleanupModifierEffects();\n isDestroyed = true;\n }\n };\n\n if (!areValidElements(reference, popper)) {\n return instance;\n }\n\n instance.setOptions(options).then(function (state) {\n if (!isDestroyed && options.onFirstUpdate) {\n options.onFirstUpdate(state);\n }\n }); // Modifiers have the ability to execute arbitrary code before the first\n // update cycle runs. They will be executed in the same order as the update\n // cycle. This is useful when a modifier adds some persistent data that\n // other modifiers need to use, but the modifier is run after the dependent\n // one.\n\n function runModifierEffects() {\n state.orderedModifiers.forEach(function (_ref) {\n var name = _ref.name,\n _ref$options = _ref.options,\n options = _ref$options === void 0 ? {} : _ref$options,\n effect = _ref.effect;\n\n if (typeof effect === 'function') {\n var cleanupFn = effect({\n state: state,\n name: name,\n instance: instance,\n options: options\n });\n\n var noopFn = function noopFn() {};\n\n effectCleanupFns.push(cleanupFn || noopFn);\n }\n });\n }\n\n function cleanupModifierEffects() {\n effectCleanupFns.forEach(function (fn) {\n return fn();\n });\n effectCleanupFns = [];\n }\n\n return instance;\n };\n}\nexport var createPopper = /*#__PURE__*/popperGenerator(); // eslint-disable-next-line import/no-unused-modules\n\nexport { detectOverflow };","import { popperGenerator, detectOverflow } from \"./createPopper.js\";\nimport eventListeners from \"./modifiers/eventListeners.js\";\nimport popperOffsets from \"./modifiers/popperOffsets.js\";\nimport computeStyles from \"./modifiers/computeStyles.js\";\nimport applyStyles from \"./modifiers/applyStyles.js\";\nimport offset from \"./modifiers/offset.js\";\nimport flip from \"./modifiers/flip.js\";\nimport preventOverflow from \"./modifiers/preventOverflow.js\";\nimport arrow from \"./modifiers/arrow.js\";\nimport hide from \"./modifiers/hide.js\";\nvar defaultModifiers = [eventListeners, popperOffsets, computeStyles, applyStyles, offset, flip, preventOverflow, arrow, hide];\nvar createPopper = /*#__PURE__*/popperGenerator({\n defaultModifiers: defaultModifiers\n}); // eslint-disable-next-line import/no-unused-modules\n\nexport { createPopper, popperGenerator, defaultModifiers, detectOverflow }; // eslint-disable-next-line import/no-unused-modules\n\nexport { createPopper as createPopperLite } from \"./popper-lite.js\"; // eslint-disable-next-line import/no-unused-modules\n\nexport * from \"./modifiers/index.js\";","import { generateUtilityClass } from '../generateUtilityClass';\nimport { generateUtilityClasses } from '../generateUtilityClasses';\nconst COMPONENT_NAME = 'Popper';\nexport function getPopperUtilityClass(slot) {\n return generateUtilityClass(COMPONENT_NAME, slot);\n}\nexport const popperClasses = generateUtilityClasses(COMPONENT_NAME, ['root']);","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"anchorEl\", \"children\", \"direction\", \"disablePortal\", \"modifiers\", \"open\", \"placement\", \"popperOptions\", \"popperRef\", \"slotProps\", \"slots\", \"TransitionProps\", \"ownerState\"],\n _excluded2 = [\"anchorEl\", \"children\", \"container\", \"direction\", \"disablePortal\", \"keepMounted\", \"modifiers\", \"open\", \"placement\", \"popperOptions\", \"popperRef\", \"style\", \"transition\", \"slotProps\", \"slots\"];\nimport * as React from 'react';\nimport { chainPropTypes, HTMLElementType, refType, unstable_ownerDocument as ownerDocument, unstable_useEnhancedEffect as useEnhancedEffect, unstable_useForkRef as useForkRef } from '@mui/utils';\nimport { createPopper } from '@popperjs/core';\nimport PropTypes from 'prop-types';\nimport { unstable_composeClasses as composeClasses } from '../composeClasses';\nimport { Portal } from '../Portal';\nimport { getPopperUtilityClass } from './popperClasses';\nimport { useSlotProps } from '../utils';\nimport { useClassNamesOverride } from '../utils/ClassNameConfigurator';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nfunction flipPlacement(placement, direction) {\n if (direction === 'ltr') {\n return placement;\n }\n switch (placement) {\n case 'bottom-end':\n return 'bottom-start';\n case 'bottom-start':\n return 'bottom-end';\n case 'top-end':\n return 'top-start';\n case 'top-start':\n return 'top-end';\n default:\n return placement;\n }\n}\nfunction resolveAnchorEl(anchorEl) {\n return typeof anchorEl === 'function' ? anchorEl() : anchorEl;\n}\nfunction isHTMLElement(element) {\n return element.nodeType !== undefined;\n}\nfunction isVirtualElement(element) {\n return !isHTMLElement(element);\n}\nconst useUtilityClasses = () => {\n const slots = {\n root: ['root']\n };\n return composeClasses(slots, useClassNamesOverride(getPopperUtilityClass));\n};\nconst defaultPopperOptions = {};\nconst PopperTooltip = /*#__PURE__*/React.forwardRef(function PopperTooltip(props, forwardedRef) {\n var _slots$root;\n const {\n anchorEl,\n children,\n direction,\n disablePortal,\n modifiers,\n open,\n placement: initialPlacement,\n popperOptions,\n popperRef: popperRefProp,\n slotProps = {},\n slots = {},\n TransitionProps\n // @ts-ignore internal logic\n // prevent from spreading to DOM, it can come from the parent component e.g. Select.\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const tooltipRef = React.useRef(null);\n const ownRef = useForkRef(tooltipRef, forwardedRef);\n const popperRef = React.useRef(null);\n const handlePopperRef = useForkRef(popperRef, popperRefProp);\n const handlePopperRefRef = React.useRef(handlePopperRef);\n useEnhancedEffect(() => {\n handlePopperRefRef.current = handlePopperRef;\n }, [handlePopperRef]);\n React.useImperativeHandle(popperRefProp, () => popperRef.current, []);\n const rtlPlacement = flipPlacement(initialPlacement, direction);\n /**\n * placement initialized from prop but can change during lifetime if modifiers.flip.\n * modifiers.flip is essentially a flip for controlled/uncontrolled behavior\n */\n const [placement, setPlacement] = React.useState(rtlPlacement);\n const [resolvedAnchorElement, setResolvedAnchorElement] = React.useState(resolveAnchorEl(anchorEl));\n React.useEffect(() => {\n if (popperRef.current) {\n popperRef.current.forceUpdate();\n }\n });\n React.useEffect(() => {\n if (anchorEl) {\n setResolvedAnchorElement(resolveAnchorEl(anchorEl));\n }\n }, [anchorEl]);\n useEnhancedEffect(() => {\n if (!resolvedAnchorElement || !open) {\n return undefined;\n }\n const handlePopperUpdate = data => {\n setPlacement(data.placement);\n };\n if (process.env.NODE_ENV !== 'production') {\n if (resolvedAnchorElement && isHTMLElement(resolvedAnchorElement) && resolvedAnchorElement.nodeType === 1) {\n const box = resolvedAnchorElement.getBoundingClientRect();\n if (process.env.NODE_ENV !== 'test' && box.top === 0 && box.left === 0 && box.right === 0 && box.bottom === 0) {\n console.warn(['MUI: The `anchorEl` prop provided to the component is invalid.', 'The anchor element should be part of the document layout.', \"Make sure the element is present in the document or that it's not display none.\"].join('\\n'));\n }\n }\n }\n let popperModifiers = [{\n name: 'preventOverflow',\n options: {\n altBoundary: disablePortal\n }\n }, {\n name: 'flip',\n options: {\n altBoundary: disablePortal\n }\n }, {\n name: 'onUpdate',\n enabled: true,\n phase: 'afterWrite',\n fn: ({\n state\n }) => {\n handlePopperUpdate(state);\n }\n }];\n if (modifiers != null) {\n popperModifiers = popperModifiers.concat(modifiers);\n }\n if (popperOptions && popperOptions.modifiers != null) {\n popperModifiers = popperModifiers.concat(popperOptions.modifiers);\n }\n const popper = createPopper(resolvedAnchorElement, tooltipRef.current, _extends({\n placement: rtlPlacement\n }, popperOptions, {\n modifiers: popperModifiers\n }));\n handlePopperRefRef.current(popper);\n return () => {\n popper.destroy();\n handlePopperRefRef.current(null);\n };\n }, [resolvedAnchorElement, disablePortal, modifiers, open, popperOptions, rtlPlacement]);\n const childProps = {\n placement: placement\n };\n if (TransitionProps !== null) {\n childProps.TransitionProps = TransitionProps;\n }\n const classes = useUtilityClasses();\n const Root = (_slots$root = slots.root) != null ? _slots$root : 'div';\n const rootProps = useSlotProps({\n elementType: Root,\n externalSlotProps: slotProps.root,\n externalForwardedProps: other,\n additionalProps: {\n role: 'tooltip',\n ref: ownRef\n },\n ownerState: props,\n className: classes.root\n });\n return /*#__PURE__*/_jsx(Root, _extends({}, rootProps, {\n children: typeof children === 'function' ? children(childProps) : children\n }));\n});\n\n/**\n * Poppers rely on the 3rd party library [Popper.js](https://popper.js.org/docs/v2/) for positioning.\n *\n * Demos:\n *\n * - [Popper](https://mui.com/base-ui/react-popper/)\n *\n * API:\n *\n * - [Popper API](https://mui.com/base-ui/react-popper/components-api/#popper)\n */\nconst Popper = /*#__PURE__*/React.forwardRef(function Popper(props, forwardedRef) {\n const {\n anchorEl,\n children,\n container: containerProp,\n direction = 'ltr',\n disablePortal = false,\n keepMounted = false,\n modifiers,\n open,\n placement = 'bottom',\n popperOptions = defaultPopperOptions,\n popperRef,\n style,\n transition = false,\n slotProps = {},\n slots = {}\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded2);\n const [exited, setExited] = React.useState(true);\n const handleEnter = () => {\n setExited(false);\n };\n const handleExited = () => {\n setExited(true);\n };\n if (!keepMounted && !open && (!transition || exited)) {\n return null;\n }\n\n // If the container prop is provided, use that\n // If the anchorEl prop is provided, use its parent body element as the container\n // If neither are provided let the Modal take care of choosing the container\n let container;\n if (containerProp) {\n container = containerProp;\n } else if (anchorEl) {\n const resolvedAnchorEl = resolveAnchorEl(anchorEl);\n container = resolvedAnchorEl && isHTMLElement(resolvedAnchorEl) ? ownerDocument(resolvedAnchorEl).body : ownerDocument(null).body;\n }\n const display = !open && keepMounted && (!transition || exited) ? 'none' : undefined;\n const transitionProps = transition ? {\n in: open,\n onEnter: handleEnter,\n onExited: handleExited\n } : undefined;\n return /*#__PURE__*/_jsx(Portal, {\n disablePortal: disablePortal,\n container: container,\n children: /*#__PURE__*/_jsx(PopperTooltip, _extends({\n anchorEl: anchorEl,\n direction: direction,\n disablePortal: disablePortal,\n modifiers: modifiers,\n ref: forwardedRef,\n open: transition ? !exited : open,\n placement: placement,\n popperOptions: popperOptions,\n popperRef: popperRef,\n slotProps: slotProps,\n slots: slots\n }, other, {\n style: _extends({\n // Prevents scroll issue, waiting for Popper.js to add this style once initiated.\n position: 'fixed',\n // Fix Popper.js display issue\n top: 0,\n left: 0,\n display\n }, style),\n TransitionProps: transitionProps,\n children: children\n }))\n });\n});\nprocess.env.NODE_ENV !== \"production\" ? Popper.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * An HTML element, [virtualElement](https://popper.js.org/docs/v2/virtual-elements/),\n * or a function that returns either.\n * It's used to set the position of the popper.\n * The return value will passed as the reference object of the Popper instance.\n */\n anchorEl: chainPropTypes(PropTypes.oneOfType([HTMLElementType, PropTypes.object, PropTypes.func]), props => {\n if (props.open) {\n const resolvedAnchorEl = resolveAnchorEl(props.anchorEl);\n if (resolvedAnchorEl && isHTMLElement(resolvedAnchorEl) && resolvedAnchorEl.nodeType === 1) {\n const box = resolvedAnchorEl.getBoundingClientRect();\n if (process.env.NODE_ENV !== 'test' && box.top === 0 && box.left === 0 && box.right === 0 && box.bottom === 0) {\n return new Error(['MUI: The `anchorEl` prop provided to the component is invalid.', 'The anchor element should be part of the document layout.', \"Make sure the element is present in the document or that it's not display none.\"].join('\\n'));\n }\n } else if (!resolvedAnchorEl || typeof resolvedAnchorEl.getBoundingClientRect !== 'function' || isVirtualElement(resolvedAnchorEl) && resolvedAnchorEl.contextElement != null && resolvedAnchorEl.contextElement.nodeType !== 1) {\n return new Error(['MUI: The `anchorEl` prop provided to the component is invalid.', 'It should be an HTML element instance or a virtualElement ', '(https://popper.js.org/docs/v2/virtual-elements/).'].join('\\n'));\n }\n }\n return null;\n }),\n /**\n * Popper render function or node.\n */\n children: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.node, PropTypes.func]),\n /**\n * An HTML element or function that returns one.\n * The `container` will have the portal children appended to it.\n *\n * You can also provide a callback, which is called in a React layout effect.\n * This lets you set the container from a ref, and also makes server-side rendering possible.\n *\n * By default, it uses the body of the top-level document object,\n * so it's simply `document.body` most of the time.\n */\n container: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.func]),\n /**\n * Direction of the text.\n * @default 'ltr'\n */\n direction: PropTypes.oneOf(['ltr', 'rtl']),\n /**\n * The `children` will be under the DOM hierarchy of the parent component.\n * @default false\n */\n disablePortal: PropTypes.bool,\n /**\n * Always keep the children in the DOM.\n * This prop can be useful in SEO situation or\n * when you want to maximize the responsiveness of the Popper.\n * @default false\n */\n keepMounted: PropTypes.bool,\n /**\n * Popper.js is based on a \"plugin-like\" architecture,\n * most of its features are fully encapsulated \"modifiers\".\n *\n * A modifier is a function that is called each time Popper.js needs to\n * compute the position of the popper.\n * For this reason, modifiers should be very performant to avoid bottlenecks.\n * To learn how to create a modifier, [read the modifiers documentation](https://popper.js.org/docs/v2/modifiers/).\n */\n modifiers: PropTypes.arrayOf(PropTypes.shape({\n data: PropTypes.object,\n effect: PropTypes.func,\n enabled: PropTypes.bool,\n fn: PropTypes.func,\n name: PropTypes.any,\n options: PropTypes.object,\n phase: PropTypes.oneOf(['afterMain', 'afterRead', 'afterWrite', 'beforeMain', 'beforeRead', 'beforeWrite', 'main', 'read', 'write']),\n requires: PropTypes.arrayOf(PropTypes.string),\n requiresIfExists: PropTypes.arrayOf(PropTypes.string)\n })),\n /**\n * If `true`, the component is shown.\n */\n open: PropTypes.bool.isRequired,\n /**\n * Popper placement.\n * @default 'bottom'\n */\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n /**\n * Options provided to the [`Popper.js`](https://popper.js.org/docs/v2/constructors/#options) instance.\n * @default {}\n */\n popperOptions: PropTypes.shape({\n modifiers: PropTypes.array,\n onFirstUpdate: PropTypes.func,\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n strategy: PropTypes.oneOf(['absolute', 'fixed'])\n }),\n /**\n * A ref that points to the used popper instance.\n */\n popperRef: refType,\n /**\n * The props used for each slot inside the Popper.\n * @default {}\n */\n slotProps: PropTypes.shape({\n root: PropTypes.oneOfType([PropTypes.func, PropTypes.object])\n }),\n /**\n * The components used for each slot inside the Popper.\n * Either a string to use a HTML element or a component.\n * @default {}\n */\n slots: PropTypes.shape({\n root: PropTypes.elementType\n }),\n /**\n * Help supporting a react-transition-group/Transition component.\n * @default false\n */\n transition: PropTypes.bool\n} : void 0;\nexport { Popper };","'use client';\n\nimport * as React from 'react';\nimport { useTheme as useThemeSystem } from '@mui/system';\nimport defaultTheme from './defaultTheme';\nimport THEME_ID from './identifier';\nexport default function useTheme() {\n const theme = useThemeSystem(defaultTheme);\n if (process.env.NODE_ENV !== 'production') {\n // eslint-disable-next-line react-hooks/rules-of-hooks\n React.useDebugValue(theme);\n }\n return theme[THEME_ID] || theme;\n}","export default function _setPrototypeOf(o, p) {\n _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function _setPrototypeOf(o, p) {\n o.__proto__ = p;\n return o;\n };\n return _setPrototypeOf(o, p);\n}","import setPrototypeOf from \"./setPrototypeOf.js\";\nexport default function _inheritsLoose(subClass, superClass) {\n subClass.prototype = Object.create(superClass.prototype);\n subClass.prototype.constructor = subClass;\n setPrototypeOf(subClass, superClass);\n}","export default {\n disabled: false\n};","import PropTypes from 'prop-types';\nexport var timeoutsShape = process.env.NODE_ENV !== 'production' ? PropTypes.oneOfType([PropTypes.number, PropTypes.shape({\n enter: PropTypes.number,\n exit: PropTypes.number,\n appear: PropTypes.number\n}).isRequired]) : null;\nexport var classNamesShape = process.env.NODE_ENV !== 'production' ? PropTypes.oneOfType([PropTypes.string, PropTypes.shape({\n enter: PropTypes.string,\n exit: PropTypes.string,\n active: PropTypes.string\n}), PropTypes.shape({\n enter: PropTypes.string,\n enterDone: PropTypes.string,\n enterActive: PropTypes.string,\n exit: PropTypes.string,\n exitDone: PropTypes.string,\n exitActive: PropTypes.string\n})]) : null;","import React from 'react';\nexport default React.createContext(null);","export var forceReflow = function forceReflow(node) {\n return node.scrollTop;\n};","import _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _inheritsLoose from \"@babel/runtime/helpers/esm/inheritsLoose\";\nimport PropTypes from 'prop-types';\nimport React from 'react';\nimport ReactDOM from 'react-dom';\nimport config from './config';\nimport { timeoutsShape } from './utils/PropTypes';\nimport TransitionGroupContext from './TransitionGroupContext';\nimport { forceReflow } from './utils/reflow';\nexport var UNMOUNTED = 'unmounted';\nexport var EXITED = 'exited';\nexport var ENTERING = 'entering';\nexport var ENTERED = 'entered';\nexport var EXITING = 'exiting';\n/**\n * The Transition component lets you describe a transition from one component\n * state to another _over time_ with a simple declarative API. Most commonly\n * it's used to animate the mounting and unmounting of a component, but can also\n * be used to describe in-place transition states as well.\n *\n * ---\n *\n * **Note**: `Transition` is a platform-agnostic base component. If you're using\n * transitions in CSS, you'll probably want to use\n * [`CSSTransition`](https://reactcommunity.org/react-transition-group/css-transition)\n * instead. It inherits all the features of `Transition`, but contains\n * additional features necessary to play nice with CSS transitions (hence the\n * name of the component).\n *\n * ---\n *\n * By default the `Transition` component does not alter the behavior of the\n * component it renders, it only tracks \"enter\" and \"exit\" states for the\n * components. It's up to you to give meaning and effect to those states. For\n * example we can add styles to a component when it enters or exits:\n *\n * ```jsx\n * import { Transition } from 'react-transition-group';\n *\n * const duration = 300;\n *\n * const defaultStyle = {\n * transition: `opacity ${duration}ms ease-in-out`,\n * opacity: 0,\n * }\n *\n * const transitionStyles = {\n * entering: { opacity: 1 },\n * entered: { opacity: 1 },\n * exiting: { opacity: 0 },\n * exited: { opacity: 0 },\n * };\n *\n * const Fade = ({ in: inProp }) => (\n * \n * {state => (\n *
    \n * I'm a fade Transition!\n *
    \n * )}\n *
    \n * );\n * ```\n *\n * There are 4 main states a Transition can be in:\n * - `'entering'`\n * - `'entered'`\n * - `'exiting'`\n * - `'exited'`\n *\n * Transition state is toggled via the `in` prop. When `true` the component\n * begins the \"Enter\" stage. During this stage, the component will shift from\n * its current transition state, to `'entering'` for the duration of the\n * transition and then to the `'entered'` stage once it's complete. Let's take\n * the following example (we'll use the\n * [useState](https://reactjs.org/docs/hooks-reference.html#usestate) hook):\n *\n * ```jsx\n * function App() {\n * const [inProp, setInProp] = useState(false);\n * return (\n *
    \n * \n * {state => (\n * // ...\n * )}\n * \n * \n *
    \n * );\n * }\n * ```\n *\n * When the button is clicked the component will shift to the `'entering'` state\n * and stay there for 500ms (the value of `timeout`) before it finally switches\n * to `'entered'`.\n *\n * When `in` is `false` the same thing happens except the state moves from\n * `'exiting'` to `'exited'`.\n */\n\nvar Transition = /*#__PURE__*/function (_React$Component) {\n _inheritsLoose(Transition, _React$Component);\n\n function Transition(props, context) {\n var _this;\n\n _this = _React$Component.call(this, props, context) || this;\n var parentGroup = context; // In the context of a TransitionGroup all enters are really appears\n\n var appear = parentGroup && !parentGroup.isMounting ? props.enter : props.appear;\n var initialStatus;\n _this.appearStatus = null;\n\n if (props.in) {\n if (appear) {\n initialStatus = EXITED;\n _this.appearStatus = ENTERING;\n } else {\n initialStatus = ENTERED;\n }\n } else {\n if (props.unmountOnExit || props.mountOnEnter) {\n initialStatus = UNMOUNTED;\n } else {\n initialStatus = EXITED;\n }\n }\n\n _this.state = {\n status: initialStatus\n };\n _this.nextCallback = null;\n return _this;\n }\n\n Transition.getDerivedStateFromProps = function getDerivedStateFromProps(_ref, prevState) {\n var nextIn = _ref.in;\n\n if (nextIn && prevState.status === UNMOUNTED) {\n return {\n status: EXITED\n };\n }\n\n return null;\n } // getSnapshotBeforeUpdate(prevProps) {\n // let nextStatus = null\n // if (prevProps !== this.props) {\n // const { status } = this.state\n // if (this.props.in) {\n // if (status !== ENTERING && status !== ENTERED) {\n // nextStatus = ENTERING\n // }\n // } else {\n // if (status === ENTERING || status === ENTERED) {\n // nextStatus = EXITING\n // }\n // }\n // }\n // return { nextStatus }\n // }\n ;\n\n var _proto = Transition.prototype;\n\n _proto.componentDidMount = function componentDidMount() {\n this.updateStatus(true, this.appearStatus);\n };\n\n _proto.componentDidUpdate = function componentDidUpdate(prevProps) {\n var nextStatus = null;\n\n if (prevProps !== this.props) {\n var status = this.state.status;\n\n if (this.props.in) {\n if (status !== ENTERING && status !== ENTERED) {\n nextStatus = ENTERING;\n }\n } else {\n if (status === ENTERING || status === ENTERED) {\n nextStatus = EXITING;\n }\n }\n }\n\n this.updateStatus(false, nextStatus);\n };\n\n _proto.componentWillUnmount = function componentWillUnmount() {\n this.cancelNextCallback();\n };\n\n _proto.getTimeouts = function getTimeouts() {\n var timeout = this.props.timeout;\n var exit, enter, appear;\n exit = enter = appear = timeout;\n\n if (timeout != null && typeof timeout !== 'number') {\n exit = timeout.exit;\n enter = timeout.enter; // TODO: remove fallback for next major\n\n appear = timeout.appear !== undefined ? timeout.appear : enter;\n }\n\n return {\n exit: exit,\n enter: enter,\n appear: appear\n };\n };\n\n _proto.updateStatus = function updateStatus(mounting, nextStatus) {\n if (mounting === void 0) {\n mounting = false;\n }\n\n if (nextStatus !== null) {\n // nextStatus will always be ENTERING or EXITING.\n this.cancelNextCallback();\n\n if (nextStatus === ENTERING) {\n if (this.props.unmountOnExit || this.props.mountOnEnter) {\n var node = this.props.nodeRef ? this.props.nodeRef.current : ReactDOM.findDOMNode(this); // https://github.com/reactjs/react-transition-group/pull/749\n // With unmountOnExit or mountOnEnter, the enter animation should happen at the transition between `exited` and `entering`.\n // To make the animation happen, we have to separate each rendering and avoid being processed as batched.\n\n if (node) forceReflow(node);\n }\n\n this.performEnter(mounting);\n } else {\n this.performExit();\n }\n } else if (this.props.unmountOnExit && this.state.status === EXITED) {\n this.setState({\n status: UNMOUNTED\n });\n }\n };\n\n _proto.performEnter = function performEnter(mounting) {\n var _this2 = this;\n\n var enter = this.props.enter;\n var appearing = this.context ? this.context.isMounting : mounting;\n\n var _ref2 = this.props.nodeRef ? [appearing] : [ReactDOM.findDOMNode(this), appearing],\n maybeNode = _ref2[0],\n maybeAppearing = _ref2[1];\n\n var timeouts = this.getTimeouts();\n var enterTimeout = appearing ? timeouts.appear : timeouts.enter; // no enter animation skip right to ENTERED\n // if we are mounting and running this it means appear _must_ be set\n\n if (!mounting && !enter || config.disabled) {\n this.safeSetState({\n status: ENTERED\n }, function () {\n _this2.props.onEntered(maybeNode);\n });\n return;\n }\n\n this.props.onEnter(maybeNode, maybeAppearing);\n this.safeSetState({\n status: ENTERING\n }, function () {\n _this2.props.onEntering(maybeNode, maybeAppearing);\n\n _this2.onTransitionEnd(enterTimeout, function () {\n _this2.safeSetState({\n status: ENTERED\n }, function () {\n _this2.props.onEntered(maybeNode, maybeAppearing);\n });\n });\n });\n };\n\n _proto.performExit = function performExit() {\n var _this3 = this;\n\n var exit = this.props.exit;\n var timeouts = this.getTimeouts();\n var maybeNode = this.props.nodeRef ? undefined : ReactDOM.findDOMNode(this); // no exit animation skip right to EXITED\n\n if (!exit || config.disabled) {\n this.safeSetState({\n status: EXITED\n }, function () {\n _this3.props.onExited(maybeNode);\n });\n return;\n }\n\n this.props.onExit(maybeNode);\n this.safeSetState({\n status: EXITING\n }, function () {\n _this3.props.onExiting(maybeNode);\n\n _this3.onTransitionEnd(timeouts.exit, function () {\n _this3.safeSetState({\n status: EXITED\n }, function () {\n _this3.props.onExited(maybeNode);\n });\n });\n });\n };\n\n _proto.cancelNextCallback = function cancelNextCallback() {\n if (this.nextCallback !== null) {\n this.nextCallback.cancel();\n this.nextCallback = null;\n }\n };\n\n _proto.safeSetState = function safeSetState(nextState, callback) {\n // This shouldn't be necessary, but there are weird race conditions with\n // setState callbacks and unmounting in testing, so always make sure that\n // we can cancel any pending setState callbacks after we unmount.\n callback = this.setNextCallback(callback);\n this.setState(nextState, callback);\n };\n\n _proto.setNextCallback = function setNextCallback(callback) {\n var _this4 = this;\n\n var active = true;\n\n this.nextCallback = function (event) {\n if (active) {\n active = false;\n _this4.nextCallback = null;\n callback(event);\n }\n };\n\n this.nextCallback.cancel = function () {\n active = false;\n };\n\n return this.nextCallback;\n };\n\n _proto.onTransitionEnd = function onTransitionEnd(timeout, handler) {\n this.setNextCallback(handler);\n var node = this.props.nodeRef ? this.props.nodeRef.current : ReactDOM.findDOMNode(this);\n var doesNotHaveTimeoutOrListener = timeout == null && !this.props.addEndListener;\n\n if (!node || doesNotHaveTimeoutOrListener) {\n setTimeout(this.nextCallback, 0);\n return;\n }\n\n if (this.props.addEndListener) {\n var _ref3 = this.props.nodeRef ? [this.nextCallback] : [node, this.nextCallback],\n maybeNode = _ref3[0],\n maybeNextCallback = _ref3[1];\n\n this.props.addEndListener(maybeNode, maybeNextCallback);\n }\n\n if (timeout != null) {\n setTimeout(this.nextCallback, timeout);\n }\n };\n\n _proto.render = function render() {\n var status = this.state.status;\n\n if (status === UNMOUNTED) {\n return null;\n }\n\n var _this$props = this.props,\n children = _this$props.children,\n _in = _this$props.in,\n _mountOnEnter = _this$props.mountOnEnter,\n _unmountOnExit = _this$props.unmountOnExit,\n _appear = _this$props.appear,\n _enter = _this$props.enter,\n _exit = _this$props.exit,\n _timeout = _this$props.timeout,\n _addEndListener = _this$props.addEndListener,\n _onEnter = _this$props.onEnter,\n _onEntering = _this$props.onEntering,\n _onEntered = _this$props.onEntered,\n _onExit = _this$props.onExit,\n _onExiting = _this$props.onExiting,\n _onExited = _this$props.onExited,\n _nodeRef = _this$props.nodeRef,\n childProps = _objectWithoutPropertiesLoose(_this$props, [\"children\", \"in\", \"mountOnEnter\", \"unmountOnExit\", \"appear\", \"enter\", \"exit\", \"timeout\", \"addEndListener\", \"onEnter\", \"onEntering\", \"onEntered\", \"onExit\", \"onExiting\", \"onExited\", \"nodeRef\"]);\n\n return (\n /*#__PURE__*/\n // allows for nested Transitions\n React.createElement(TransitionGroupContext.Provider, {\n value: null\n }, typeof children === 'function' ? children(status, childProps) : React.cloneElement(React.Children.only(children), childProps))\n );\n };\n\n return Transition;\n}(React.Component);\n\nTransition.contextType = TransitionGroupContext;\nTransition.propTypes = process.env.NODE_ENV !== \"production\" ? {\n /**\n * A React reference to DOM element that need to transition:\n * https://stackoverflow.com/a/51127130/4671932\n *\n * - When `nodeRef` prop is used, `node` is not passed to callback functions\n * (e.g. `onEnter`) because user already has direct access to the node.\n * - When changing `key` prop of `Transition` in a `TransitionGroup` a new\n * `nodeRef` need to be provided to `Transition` with changed `key` prop\n * (see\n * [test/CSSTransition-test.js](https://github.com/reactjs/react-transition-group/blob/13435f897b3ab71f6e19d724f145596f5910581c/test/CSSTransition-test.js#L362-L437)).\n */\n nodeRef: PropTypes.shape({\n current: typeof Element === 'undefined' ? PropTypes.any : function (propValue, key, componentName, location, propFullName, secret) {\n var value = propValue[key];\n return PropTypes.instanceOf(value && 'ownerDocument' in value ? value.ownerDocument.defaultView.Element : Element)(propValue, key, componentName, location, propFullName, secret);\n }\n }),\n\n /**\n * A `function` child can be used instead of a React element. This function is\n * called with the current transition status (`'entering'`, `'entered'`,\n * `'exiting'`, `'exited'`), which can be used to apply context\n * specific props to a component.\n *\n * ```jsx\n * \n * {state => (\n * \n * )}\n * \n * ```\n */\n children: PropTypes.oneOfType([PropTypes.func.isRequired, PropTypes.element.isRequired]).isRequired,\n\n /**\n * Show the component; triggers the enter or exit states\n */\n in: PropTypes.bool,\n\n /**\n * By default the child component is mounted immediately along with\n * the parent `Transition` component. If you want to \"lazy mount\" the component on the\n * first `in={true}` you can set `mountOnEnter`. After the first enter transition the component will stay\n * mounted, even on \"exited\", unless you also specify `unmountOnExit`.\n */\n mountOnEnter: PropTypes.bool,\n\n /**\n * By default the child component stays mounted after it reaches the `'exited'` state.\n * Set `unmountOnExit` if you'd prefer to unmount the component after it finishes exiting.\n */\n unmountOnExit: PropTypes.bool,\n\n /**\n * By default the child component does not perform the enter transition when\n * it first mounts, regardless of the value of `in`. If you want this\n * behavior, set both `appear` and `in` to `true`.\n *\n * > **Note**: there are no special appear states like `appearing`/`appeared`, this prop\n * > only adds an additional enter transition. However, in the\n * > `` component that first enter transition does result in\n * > additional `.appear-*` classes, that way you can choose to style it\n * > differently.\n */\n appear: PropTypes.bool,\n\n /**\n * Enable or disable enter transitions.\n */\n enter: PropTypes.bool,\n\n /**\n * Enable or disable exit transitions.\n */\n exit: PropTypes.bool,\n\n /**\n * The duration of the transition, in milliseconds.\n * Required unless `addEndListener` is provided.\n *\n * You may specify a single timeout for all transitions:\n *\n * ```jsx\n * timeout={500}\n * ```\n *\n * or individually:\n *\n * ```jsx\n * timeout={{\n * appear: 500,\n * enter: 300,\n * exit: 500,\n * }}\n * ```\n *\n * - `appear` defaults to the value of `enter`\n * - `enter` defaults to `0`\n * - `exit` defaults to `0`\n *\n * @type {number | { enter?: number, exit?: number, appear?: number }}\n */\n timeout: function timeout(props) {\n var pt = timeoutsShape;\n if (!props.addEndListener) pt = pt.isRequired;\n\n for (var _len = arguments.length, args = new Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) {\n args[_key - 1] = arguments[_key];\n }\n\n return pt.apply(void 0, [props].concat(args));\n },\n\n /**\n * Add a custom transition end trigger. Called with the transitioning\n * DOM node and a `done` callback. Allows for more fine grained transition end\n * logic. Timeouts are still used as a fallback if provided.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * ```jsx\n * addEndListener={(node, done) => {\n * // use the css transitionend event to mark the finish of a transition\n * node.addEventListener('transitionend', done, false);\n * }}\n * ```\n */\n addEndListener: PropTypes.func,\n\n /**\n * Callback fired before the \"entering\" status is applied. An extra parameter\n * `isAppearing` is supplied to indicate if the enter stage is occurring on the initial mount\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement, isAppearing: bool) -> void\n */\n onEnter: PropTypes.func,\n\n /**\n * Callback fired after the \"entering\" status is applied. An extra parameter\n * `isAppearing` is supplied to indicate if the enter stage is occurring on the initial mount\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement, isAppearing: bool)\n */\n onEntering: PropTypes.func,\n\n /**\n * Callback fired after the \"entered\" status is applied. An extra parameter\n * `isAppearing` is supplied to indicate if the enter stage is occurring on the initial mount\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement, isAppearing: bool) -> void\n */\n onEntered: PropTypes.func,\n\n /**\n * Callback fired before the \"exiting\" status is applied.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement) -> void\n */\n onExit: PropTypes.func,\n\n /**\n * Callback fired after the \"exiting\" status is applied.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement) -> void\n */\n onExiting: PropTypes.func,\n\n /**\n * Callback fired after the \"exited\" status is applied.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed\n *\n * @type Function(node: HtmlElement) -> void\n */\n onExited: PropTypes.func\n} : {}; // Name the function so it is clearer in the documentation\n\nfunction noop() {}\n\nTransition.defaultProps = {\n in: false,\n mountOnEnter: false,\n unmountOnExit: false,\n appear: false,\n enter: true,\n exit: true,\n onEnter: noop,\n onEntering: noop,\n onEntered: noop,\n onExit: noop,\n onExiting: noop,\n onExited: noop\n};\nTransition.UNMOUNTED = UNMOUNTED;\nTransition.EXITED = EXITED;\nTransition.ENTERING = ENTERING;\nTransition.ENTERED = ENTERED;\nTransition.EXITING = EXITING;\nexport default Transition;","export const reflow = node => node.scrollTop;\nexport function getTransitionProps(props, options) {\n var _style$transitionDura, _style$transitionTimi;\n const {\n timeout,\n easing,\n style = {}\n } = props;\n return {\n duration: (_style$transitionDura = style.transitionDuration) != null ? _style$transitionDura : typeof timeout === 'number' ? timeout : timeout[options.mode] || 0,\n easing: (_style$transitionTimi = style.transitionTimingFunction) != null ? _style$transitionTimi : typeof easing === 'object' ? easing[options.mode] : easing,\n delay: style.transitionDelay\n };\n}","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"addEndListener\", \"appear\", \"children\", \"easing\", \"in\", \"onEnter\", \"onEntered\", \"onEntering\", \"onExit\", \"onExited\", \"onExiting\", \"style\", \"timeout\", \"TransitionComponent\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport { elementAcceptingRef, unstable_useTimeout as useTimeout } from '@mui/utils';\nimport { Transition } from 'react-transition-group';\nimport useTheme from '../styles/useTheme';\nimport { getTransitionProps, reflow } from '../transitions/utils';\nimport useForkRef from '../utils/useForkRef';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nfunction getScale(value) {\n return `scale(${value}, ${value ** 2})`;\n}\nconst styles = {\n entering: {\n opacity: 1,\n transform: getScale(1)\n },\n entered: {\n opacity: 1,\n transform: 'none'\n }\n};\n\n/*\n TODO v6: remove\n Conditionally apply a workaround for the CSS transition bug in Safari 15.4 / WebKit browsers.\n */\nconst isWebKit154 = typeof navigator !== 'undefined' && /^((?!chrome|android).)*(safari|mobile)/i.test(navigator.userAgent) && /(os |version\\/)15(.|_)4/i.test(navigator.userAgent);\n\n/**\n * The Grow transition is used by the [Tooltip](/material-ui/react-tooltip/) and\n * [Popover](/material-ui/react-popover/) components.\n * It uses [react-transition-group](https://github.com/reactjs/react-transition-group) internally.\n */\nconst Grow = /*#__PURE__*/React.forwardRef(function Grow(props, ref) {\n const {\n addEndListener,\n appear = true,\n children,\n easing,\n in: inProp,\n onEnter,\n onEntered,\n onEntering,\n onExit,\n onExited,\n onExiting,\n style,\n timeout = 'auto',\n // eslint-disable-next-line react/prop-types\n TransitionComponent = Transition\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const timer = useTimeout();\n const autoTimeout = React.useRef();\n const theme = useTheme();\n const nodeRef = React.useRef(null);\n const handleRef = useForkRef(nodeRef, children.ref, ref);\n const normalizedTransitionCallback = callback => maybeIsAppearing => {\n if (callback) {\n const node = nodeRef.current;\n\n // onEnterXxx and onExitXxx callbacks have a different arguments.length value.\n if (maybeIsAppearing === undefined) {\n callback(node);\n } else {\n callback(node, maybeIsAppearing);\n }\n }\n };\n const handleEntering = normalizedTransitionCallback(onEntering);\n const handleEnter = normalizedTransitionCallback((node, isAppearing) => {\n reflow(node); // So the animation always start from the start.\n\n const {\n duration: transitionDuration,\n delay,\n easing: transitionTimingFunction\n } = getTransitionProps({\n style,\n timeout,\n easing\n }, {\n mode: 'enter'\n });\n let duration;\n if (timeout === 'auto') {\n duration = theme.transitions.getAutoHeightDuration(node.clientHeight);\n autoTimeout.current = duration;\n } else {\n duration = transitionDuration;\n }\n node.style.transition = [theme.transitions.create('opacity', {\n duration,\n delay\n }), theme.transitions.create('transform', {\n duration: isWebKit154 ? duration : duration * 0.666,\n delay,\n easing: transitionTimingFunction\n })].join(',');\n if (onEnter) {\n onEnter(node, isAppearing);\n }\n });\n const handleEntered = normalizedTransitionCallback(onEntered);\n const handleExiting = normalizedTransitionCallback(onExiting);\n const handleExit = normalizedTransitionCallback(node => {\n const {\n duration: transitionDuration,\n delay,\n easing: transitionTimingFunction\n } = getTransitionProps({\n style,\n timeout,\n easing\n }, {\n mode: 'exit'\n });\n let duration;\n if (timeout === 'auto') {\n duration = theme.transitions.getAutoHeightDuration(node.clientHeight);\n autoTimeout.current = duration;\n } else {\n duration = transitionDuration;\n }\n node.style.transition = [theme.transitions.create('opacity', {\n duration,\n delay\n }), theme.transitions.create('transform', {\n duration: isWebKit154 ? duration : duration * 0.666,\n delay: isWebKit154 ? delay : delay || duration * 0.333,\n easing: transitionTimingFunction\n })].join(',');\n node.style.opacity = 0;\n node.style.transform = getScale(0.75);\n if (onExit) {\n onExit(node);\n }\n });\n const handleExited = normalizedTransitionCallback(onExited);\n const handleAddEndListener = next => {\n if (timeout === 'auto') {\n timer.start(autoTimeout.current || 0, next);\n }\n if (addEndListener) {\n // Old call signature before `react-transition-group` implemented `nodeRef`\n addEndListener(nodeRef.current, next);\n }\n };\n return /*#__PURE__*/_jsx(TransitionComponent, _extends({\n appear: appear,\n in: inProp,\n nodeRef: nodeRef,\n onEnter: handleEnter,\n onEntered: handleEntered,\n onEntering: handleEntering,\n onExit: handleExit,\n onExited: handleExited,\n onExiting: handleExiting,\n addEndListener: handleAddEndListener,\n timeout: timeout === 'auto' ? null : timeout\n }, other, {\n children: (state, childProps) => {\n return /*#__PURE__*/React.cloneElement(children, _extends({\n style: _extends({\n opacity: 0,\n transform: getScale(0.75),\n visibility: state === 'exited' && !inProp ? 'hidden' : undefined\n }, styles[state], style, children.props.style),\n ref: handleRef\n }, childProps));\n }\n }));\n});\nprocess.env.NODE_ENV !== \"production\" ? Grow.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the d.ts file and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * Add a custom transition end trigger. Called with the transitioning DOM\n * node and a done callback. Allows for more fine grained transition end\n * logic. Note: Timeouts are still used as a fallback if provided.\n */\n addEndListener: PropTypes.func,\n /**\n * Perform the enter transition when it first mounts if `in` is also `true`.\n * Set this to `false` to disable this behavior.\n * @default true\n */\n appear: PropTypes.bool,\n /**\n * A single child content element.\n */\n children: elementAcceptingRef.isRequired,\n /**\n * The transition timing function.\n * You may specify a single easing or a object containing enter and exit values.\n */\n easing: PropTypes.oneOfType([PropTypes.shape({\n enter: PropTypes.string,\n exit: PropTypes.string\n }), PropTypes.string]),\n /**\n * If `true`, the component will transition in.\n */\n in: PropTypes.bool,\n /**\n * @ignore\n */\n onEnter: PropTypes.func,\n /**\n * @ignore\n */\n onEntered: PropTypes.func,\n /**\n * @ignore\n */\n onEntering: PropTypes.func,\n /**\n * @ignore\n */\n onExit: PropTypes.func,\n /**\n * @ignore\n */\n onExited: PropTypes.func,\n /**\n * @ignore\n */\n onExiting: PropTypes.func,\n /**\n * @ignore\n */\n style: PropTypes.object,\n /**\n * The duration for the transition, in milliseconds.\n * You may specify a single timeout for all transitions, or individually with an object.\n *\n * Set to 'auto' to automatically calculate transition time based on height.\n * @default 'auto'\n */\n timeout: PropTypes.oneOfType([PropTypes.oneOf(['auto']), PropTypes.number, PropTypes.shape({\n appear: PropTypes.number,\n enter: PropTypes.number,\n exit: PropTypes.number\n })])\n} : void 0;\nGrow.muiSupportAuto = true;\nexport default Grow;","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"anchorEl\", \"component\", \"components\", \"componentsProps\", \"container\", \"disablePortal\", \"keepMounted\", \"modifiers\", \"open\", \"placement\", \"popperOptions\", \"popperRef\", \"transition\", \"slots\", \"slotProps\"];\nimport { Popper as BasePopper } from '@mui/base/Popper';\nimport { useThemeWithoutDefault as useTheme } from '@mui/system';\nimport { HTMLElementType, refType } from '@mui/utils';\nimport PropTypes from 'prop-types';\nimport * as React from 'react';\nimport { styled, useThemeProps } from '../styles';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nconst PopperRoot = styled(BasePopper, {\n name: 'MuiPopper',\n slot: 'Root',\n overridesResolver: (props, styles) => styles.root\n})({});\n\n/**\n *\n * Demos:\n *\n * - [Autocomplete](https://mui.com/material-ui/react-autocomplete/)\n * - [Menu](https://mui.com/material-ui/react-menu/)\n * - [Popper](https://mui.com/material-ui/react-popper/)\n *\n * API:\n *\n * - [Popper API](https://mui.com/material-ui/api/popper/)\n */\nconst Popper = /*#__PURE__*/React.forwardRef(function Popper(inProps, ref) {\n var _slots$root;\n const theme = useTheme();\n const props = useThemeProps({\n props: inProps,\n name: 'MuiPopper'\n });\n const {\n anchorEl,\n component,\n components,\n componentsProps,\n container,\n disablePortal,\n keepMounted,\n modifiers,\n open,\n placement,\n popperOptions,\n popperRef,\n transition,\n slots,\n slotProps\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const RootComponent = (_slots$root = slots == null ? void 0 : slots.root) != null ? _slots$root : components == null ? void 0 : components.Root;\n const otherProps = _extends({\n anchorEl,\n container,\n disablePortal,\n keepMounted,\n modifiers,\n open,\n placement,\n popperOptions,\n popperRef,\n transition\n }, other);\n return /*#__PURE__*/_jsx(PopperRoot, _extends({\n as: component,\n direction: theme == null ? void 0 : theme.direction,\n slots: {\n root: RootComponent\n },\n slotProps: slotProps != null ? slotProps : componentsProps\n }, otherProps, {\n ref: ref\n }));\n});\nprocess.env.NODE_ENV !== \"production\" ? Popper.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * An HTML element, [virtualElement](https://popper.js.org/docs/v2/virtual-elements/),\n * or a function that returns either.\n * It's used to set the position of the popper.\n * The return value will passed as the reference object of the Popper instance.\n */\n anchorEl: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.object, PropTypes.func]),\n /**\n * Popper render function or node.\n */\n children: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.node, PropTypes.func]),\n /**\n * The component used for the root node.\n * Either a string to use a HTML element or a component.\n */\n component: PropTypes.elementType,\n /**\n * The components used for each slot inside the Popper.\n * Either a string to use a HTML element or a component.\n * @default {}\n */\n components: PropTypes.shape({\n Root: PropTypes.elementType\n }),\n /**\n * The props used for each slot inside the Popper.\n * @default {}\n */\n componentsProps: PropTypes.shape({\n root: PropTypes.oneOfType([PropTypes.func, PropTypes.object])\n }),\n /**\n * An HTML element or function that returns one.\n * The `container` will have the portal children appended to it.\n *\n * You can also provide a callback, which is called in a React layout effect.\n * This lets you set the container from a ref, and also makes server-side rendering possible.\n *\n * By default, it uses the body of the top-level document object,\n * so it's simply `document.body` most of the time.\n */\n container: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.func]),\n /**\n * The `children` will be under the DOM hierarchy of the parent component.\n * @default false\n */\n disablePortal: PropTypes.bool,\n /**\n * Always keep the children in the DOM.\n * This prop can be useful in SEO situation or\n * when you want to maximize the responsiveness of the Popper.\n * @default false\n */\n keepMounted: PropTypes.bool,\n /**\n * Popper.js is based on a \"plugin-like\" architecture,\n * most of its features are fully encapsulated \"modifiers\".\n *\n * A modifier is a function that is called each time Popper.js needs to\n * compute the position of the popper.\n * For this reason, modifiers should be very performant to avoid bottlenecks.\n * To learn how to create a modifier, [read the modifiers documentation](https://popper.js.org/docs/v2/modifiers/).\n */\n modifiers: PropTypes.arrayOf(PropTypes.shape({\n data: PropTypes.object,\n effect: PropTypes.func,\n enabled: PropTypes.bool,\n fn: PropTypes.func,\n name: PropTypes.any,\n options: PropTypes.object,\n phase: PropTypes.oneOf(['afterMain', 'afterRead', 'afterWrite', 'beforeMain', 'beforeRead', 'beforeWrite', 'main', 'read', 'write']),\n requires: PropTypes.arrayOf(PropTypes.string),\n requiresIfExists: PropTypes.arrayOf(PropTypes.string)\n })),\n /**\n * If `true`, the component is shown.\n */\n open: PropTypes.bool.isRequired,\n /**\n * Popper placement.\n * @default 'bottom'\n */\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n /**\n * Options provided to the [`Popper.js`](https://popper.js.org/docs/v2/constructors/#options) instance.\n * @default {}\n */\n popperOptions: PropTypes.shape({\n modifiers: PropTypes.array,\n onFirstUpdate: PropTypes.func,\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n strategy: PropTypes.oneOf(['absolute', 'fixed'])\n }),\n /**\n * A ref that points to the used popper instance.\n */\n popperRef: refType,\n /**\n * The props used for each slot inside the Popper.\n * @default {}\n */\n slotProps: PropTypes.shape({\n root: PropTypes.oneOfType([PropTypes.func, PropTypes.object])\n }),\n /**\n * The components used for each slot inside the Popper.\n * Either a string to use a HTML element or a component.\n * @default {}\n */\n slots: PropTypes.shape({\n root: PropTypes.elementType\n }),\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Help supporting a react-transition-group/Transition component.\n * @default false\n */\n transition: PropTypes.bool\n} : void 0;\nexport default Popper;","import generateUtilityClasses from '@mui/utils/generateUtilityClasses';\nimport generateUtilityClass from '@mui/utils/generateUtilityClass';\nexport function getTooltipUtilityClass(slot) {\n return generateUtilityClass('MuiTooltip', slot);\n}\nconst tooltipClasses = generateUtilityClasses('MuiTooltip', ['popper', 'popperInteractive', 'popperArrow', 'popperClose', 'tooltip', 'tooltipArrow', 'touch', 'tooltipPlacementLeft', 'tooltipPlacementRight', 'tooltipPlacementTop', 'tooltipPlacementBottom', 'arrow']);\nexport default tooltipClasses;","'use client';\n\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nconst _excluded = [\"arrow\", \"children\", \"classes\", \"components\", \"componentsProps\", \"describeChild\", \"disableFocusListener\", \"disableHoverListener\", \"disableInteractive\", \"disableTouchListener\", \"enterDelay\", \"enterNextDelay\", \"enterTouchDelay\", \"followCursor\", \"id\", \"leaveDelay\", \"leaveTouchDelay\", \"onClose\", \"onOpen\", \"open\", \"placement\", \"PopperComponent\", \"PopperProps\", \"slotProps\", \"slots\", \"title\", \"TransitionComponent\", \"TransitionProps\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport clsx from 'clsx';\nimport { elementAcceptingRef, unstable_useTimeout as useTimeout, unstable_Timeout as Timeout } from '@mui/utils';\nimport { unstable_composeClasses as composeClasses, appendOwnerState } from '@mui/base';\nimport { alpha } from '@mui/system';\nimport styled from '../styles/styled';\nimport useTheme from '../styles/useTheme';\nimport useThemeProps from '../styles/useThemeProps';\nimport capitalize from '../utils/capitalize';\nimport Grow from '../Grow';\nimport Popper from '../Popper';\nimport useEventCallback from '../utils/useEventCallback';\nimport useForkRef from '../utils/useForkRef';\nimport useId from '../utils/useId';\nimport useIsFocusVisible from '../utils/useIsFocusVisible';\nimport useControlled from '../utils/useControlled';\nimport tooltipClasses, { getTooltipUtilityClass } from './tooltipClasses';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nimport { jsxs as _jsxs } from \"react/jsx-runtime\";\nfunction round(value) {\n return Math.round(value * 1e5) / 1e5;\n}\nconst useUtilityClasses = ownerState => {\n const {\n classes,\n disableInteractive,\n arrow,\n touch,\n placement\n } = ownerState;\n const slots = {\n popper: ['popper', !disableInteractive && 'popperInteractive', arrow && 'popperArrow'],\n tooltip: ['tooltip', arrow && 'tooltipArrow', touch && 'touch', `tooltipPlacement${capitalize(placement.split('-')[0])}`],\n arrow: ['arrow']\n };\n return composeClasses(slots, getTooltipUtilityClass, classes);\n};\nconst TooltipPopper = styled(Popper, {\n name: 'MuiTooltip',\n slot: 'Popper',\n overridesResolver: (props, styles) => {\n const {\n ownerState\n } = props;\n return [styles.popper, !ownerState.disableInteractive && styles.popperInteractive, ownerState.arrow && styles.popperArrow, !ownerState.open && styles.popperClose];\n }\n})(({\n theme,\n ownerState,\n open\n}) => _extends({\n zIndex: (theme.vars || theme).zIndex.tooltip,\n pointerEvents: 'none'\n}, !ownerState.disableInteractive && {\n pointerEvents: 'auto'\n}, !open && {\n pointerEvents: 'none'\n}, ownerState.arrow && {\n [`&[data-popper-placement*=\"bottom\"] .${tooltipClasses.arrow}`]: {\n top: 0,\n marginTop: '-0.71em',\n '&::before': {\n transformOrigin: '0 100%'\n }\n },\n [`&[data-popper-placement*=\"top\"] .${tooltipClasses.arrow}`]: {\n bottom: 0,\n marginBottom: '-0.71em',\n '&::before': {\n transformOrigin: '100% 0'\n }\n },\n [`&[data-popper-placement*=\"right\"] .${tooltipClasses.arrow}`]: _extends({}, !ownerState.isRtl ? {\n left: 0,\n marginLeft: '-0.71em'\n } : {\n right: 0,\n marginRight: '-0.71em'\n }, {\n height: '1em',\n width: '0.71em',\n '&::before': {\n transformOrigin: '100% 100%'\n }\n }),\n [`&[data-popper-placement*=\"left\"] .${tooltipClasses.arrow}`]: _extends({}, !ownerState.isRtl ? {\n right: 0,\n marginRight: '-0.71em'\n } : {\n left: 0,\n marginLeft: '-0.71em'\n }, {\n height: '1em',\n width: '0.71em',\n '&::before': {\n transformOrigin: '0 0'\n }\n })\n}));\nconst TooltipTooltip = styled('div', {\n name: 'MuiTooltip',\n slot: 'Tooltip',\n overridesResolver: (props, styles) => {\n const {\n ownerState\n } = props;\n return [styles.tooltip, ownerState.touch && styles.touch, ownerState.arrow && styles.tooltipArrow, styles[`tooltipPlacement${capitalize(ownerState.placement.split('-')[0])}`]];\n }\n})(({\n theme,\n ownerState\n}) => _extends({\n backgroundColor: theme.vars ? theme.vars.palette.Tooltip.bg : alpha(theme.palette.grey[700], 0.92),\n borderRadius: (theme.vars || theme).shape.borderRadius,\n color: (theme.vars || theme).palette.common.white,\n fontFamily: theme.typography.fontFamily,\n padding: '4px 8px',\n fontSize: theme.typography.pxToRem(11),\n maxWidth: 300,\n margin: 2,\n wordWrap: 'break-word',\n fontWeight: theme.typography.fontWeightMedium\n}, ownerState.arrow && {\n position: 'relative',\n margin: 0\n}, ownerState.touch && {\n padding: '8px 16px',\n fontSize: theme.typography.pxToRem(14),\n lineHeight: `${round(16 / 14)}em`,\n fontWeight: theme.typography.fontWeightRegular\n}, {\n [`.${tooltipClasses.popper}[data-popper-placement*=\"left\"] &`]: _extends({\n transformOrigin: 'right center'\n }, !ownerState.isRtl ? _extends({\n marginRight: '14px'\n }, ownerState.touch && {\n marginRight: '24px'\n }) : _extends({\n marginLeft: '14px'\n }, ownerState.touch && {\n marginLeft: '24px'\n })),\n [`.${tooltipClasses.popper}[data-popper-placement*=\"right\"] &`]: _extends({\n transformOrigin: 'left center'\n }, !ownerState.isRtl ? _extends({\n marginLeft: '14px'\n }, ownerState.touch && {\n marginLeft: '24px'\n }) : _extends({\n marginRight: '14px'\n }, ownerState.touch && {\n marginRight: '24px'\n })),\n [`.${tooltipClasses.popper}[data-popper-placement*=\"top\"] &`]: _extends({\n transformOrigin: 'center bottom',\n marginBottom: '14px'\n }, ownerState.touch && {\n marginBottom: '24px'\n }),\n [`.${tooltipClasses.popper}[data-popper-placement*=\"bottom\"] &`]: _extends({\n transformOrigin: 'center top',\n marginTop: '14px'\n }, ownerState.touch && {\n marginTop: '24px'\n })\n}));\nconst TooltipArrow = styled('span', {\n name: 'MuiTooltip',\n slot: 'Arrow',\n overridesResolver: (props, styles) => styles.arrow\n})(({\n theme\n}) => ({\n overflow: 'hidden',\n position: 'absolute',\n width: '1em',\n height: '0.71em' /* = width / sqrt(2) = (length of the hypotenuse) */,\n boxSizing: 'border-box',\n color: theme.vars ? theme.vars.palette.Tooltip.bg : alpha(theme.palette.grey[700], 0.9),\n '&::before': {\n content: '\"\"',\n margin: 'auto',\n display: 'block',\n width: '100%',\n height: '100%',\n backgroundColor: 'currentColor',\n transform: 'rotate(45deg)'\n }\n}));\nlet hystersisOpen = false;\nconst hystersisTimer = new Timeout();\nlet cursorPosition = {\n x: 0,\n y: 0\n};\nexport function testReset() {\n hystersisOpen = false;\n hystersisTimer.clear();\n}\nfunction composeEventHandler(handler, eventHandler) {\n return event => {\n if (eventHandler) {\n eventHandler(event);\n }\n handler(event);\n };\n}\n\n// TODO v6: Remove PopperComponent, PopperProps, TransitionComponent and TransitionProps.\nconst Tooltip = /*#__PURE__*/React.forwardRef(function Tooltip(inProps, ref) {\n var _ref, _slots$popper, _ref2, _ref3, _slots$transition, _ref4, _slots$tooltip, _ref5, _slots$arrow, _slotProps$popper, _ref6, _slotProps$popper2, _slotProps$transition, _slotProps$tooltip, _ref7, _slotProps$tooltip2, _slotProps$arrow, _ref8, _slotProps$arrow2;\n const props = useThemeProps({\n props: inProps,\n name: 'MuiTooltip'\n });\n const {\n arrow = false,\n children: childrenProp,\n components = {},\n componentsProps = {},\n describeChild = false,\n disableFocusListener = false,\n disableHoverListener = false,\n disableInteractive: disableInteractiveProp = false,\n disableTouchListener = false,\n enterDelay = 100,\n enterNextDelay = 0,\n enterTouchDelay = 700,\n followCursor = false,\n id: idProp,\n leaveDelay = 0,\n leaveTouchDelay = 1500,\n onClose,\n onOpen,\n open: openProp,\n placement = 'bottom',\n PopperComponent: PopperComponentProp,\n PopperProps = {},\n slotProps = {},\n slots = {},\n title,\n TransitionComponent: TransitionComponentProp = Grow,\n TransitionProps\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n\n // to prevent runtime errors, developers will need to provide a child as a React element anyway.\n const children = /*#__PURE__*/React.isValidElement(childrenProp) ? childrenProp : /*#__PURE__*/_jsx(\"span\", {\n children: childrenProp\n });\n const theme = useTheme();\n const isRtl = theme.direction === 'rtl';\n const [childNode, setChildNode] = React.useState();\n const [arrowRef, setArrowRef] = React.useState(null);\n const ignoreNonTouchEvents = React.useRef(false);\n const disableInteractive = disableInteractiveProp || followCursor;\n const closeTimer = useTimeout();\n const enterTimer = useTimeout();\n const leaveTimer = useTimeout();\n const touchTimer = useTimeout();\n const [openState, setOpenState] = useControlled({\n controlled: openProp,\n default: false,\n name: 'Tooltip',\n state: 'open'\n });\n let open = openState;\n if (process.env.NODE_ENV !== 'production') {\n // eslint-disable-next-line react-hooks/rules-of-hooks\n const {\n current: isControlled\n } = React.useRef(openProp !== undefined);\n\n // eslint-disable-next-line react-hooks/rules-of-hooks\n React.useEffect(() => {\n if (childNode && childNode.disabled && !isControlled && title !== '' && childNode.tagName.toLowerCase() === 'button') {\n console.error(['MUI: You are providing a disabled `button` child to the Tooltip component.', 'A disabled element does not fire events.', \"Tooltip needs to listen to the child element's events to display the title.\", '', 'Add a simple wrapper element, such as a `span`.'].join('\\n'));\n }\n }, [title, childNode, isControlled]);\n }\n const id = useId(idProp);\n const prevUserSelect = React.useRef();\n const stopTouchInteraction = useEventCallback(() => {\n if (prevUserSelect.current !== undefined) {\n document.body.style.WebkitUserSelect = prevUserSelect.current;\n prevUserSelect.current = undefined;\n }\n touchTimer.clear();\n });\n React.useEffect(() => stopTouchInteraction, [stopTouchInteraction]);\n const handleOpen = event => {\n hystersisTimer.clear();\n hystersisOpen = true;\n\n // The mouseover event will trigger for every nested element in the tooltip.\n // We can skip rerendering when the tooltip is already open.\n // We are using the mouseover event instead of the mouseenter event to fix a hide/show issue.\n setOpenState(true);\n if (onOpen && !open) {\n onOpen(event);\n }\n };\n const handleClose = useEventCallback(\n /**\n * @param {React.SyntheticEvent | Event} event\n */\n event => {\n hystersisTimer.start(800 + leaveDelay, () => {\n hystersisOpen = false;\n });\n setOpenState(false);\n if (onClose && open) {\n onClose(event);\n }\n closeTimer.start(theme.transitions.duration.shortest, () => {\n ignoreNonTouchEvents.current = false;\n });\n });\n const handleEnter = event => {\n if (ignoreNonTouchEvents.current && event.type !== 'touchstart') {\n return;\n }\n\n // Remove the title ahead of time.\n // We don't want to wait for the next render commit.\n // We would risk displaying two tooltips at the same time (native + this one).\n if (childNode) {\n childNode.removeAttribute('title');\n }\n enterTimer.clear();\n leaveTimer.clear();\n if (enterDelay || hystersisOpen && enterNextDelay) {\n enterTimer.start(hystersisOpen ? enterNextDelay : enterDelay, () => {\n handleOpen(event);\n });\n } else {\n handleOpen(event);\n }\n };\n const handleLeave = event => {\n enterTimer.clear();\n leaveTimer.start(leaveDelay, () => {\n handleClose(event);\n });\n };\n const {\n isFocusVisibleRef,\n onBlur: handleBlurVisible,\n onFocus: handleFocusVisible,\n ref: focusVisibleRef\n } = useIsFocusVisible();\n // We don't necessarily care about the focusVisible state (which is safe to access via ref anyway).\n // We just need to re-render the Tooltip if the focus-visible state changes.\n const [, setChildIsFocusVisible] = React.useState(false);\n const handleBlur = event => {\n handleBlurVisible(event);\n if (isFocusVisibleRef.current === false) {\n setChildIsFocusVisible(false);\n handleLeave(event);\n }\n };\n const handleFocus = event => {\n // Workaround for https://github.com/facebook/react/issues/7769\n // The autoFocus of React might trigger the event before the componentDidMount.\n // We need to account for this eventuality.\n if (!childNode) {\n setChildNode(event.currentTarget);\n }\n handleFocusVisible(event);\n if (isFocusVisibleRef.current === true) {\n setChildIsFocusVisible(true);\n handleEnter(event);\n }\n };\n const detectTouchStart = event => {\n ignoreNonTouchEvents.current = true;\n const childrenProps = children.props;\n if (childrenProps.onTouchStart) {\n childrenProps.onTouchStart(event);\n }\n };\n const handleMouseOver = handleEnter;\n const handleMouseLeave = handleLeave;\n const handleTouchStart = event => {\n detectTouchStart(event);\n leaveTimer.clear();\n closeTimer.clear();\n stopTouchInteraction();\n prevUserSelect.current = document.body.style.WebkitUserSelect;\n // Prevent iOS text selection on long-tap.\n document.body.style.WebkitUserSelect = 'none';\n touchTimer.start(enterTouchDelay, () => {\n document.body.style.WebkitUserSelect = prevUserSelect.current;\n handleEnter(event);\n });\n };\n const handleTouchEnd = event => {\n if (children.props.onTouchEnd) {\n children.props.onTouchEnd(event);\n }\n stopTouchInteraction();\n leaveTimer.start(leaveTouchDelay, () => {\n handleClose(event);\n });\n };\n React.useEffect(() => {\n if (!open) {\n return undefined;\n }\n\n /**\n * @param {KeyboardEvent} nativeEvent\n */\n function handleKeyDown(nativeEvent) {\n // IE11, Edge (prior to using Bink?) use 'Esc'\n if (nativeEvent.key === 'Escape' || nativeEvent.key === 'Esc') {\n handleClose(nativeEvent);\n }\n }\n document.addEventListener('keydown', handleKeyDown);\n return () => {\n document.removeEventListener('keydown', handleKeyDown);\n };\n }, [handleClose, open]);\n const handleRef = useForkRef(children.ref, focusVisibleRef, setChildNode, ref);\n\n // There is no point in displaying an empty tooltip.\n // So we exclude all falsy values, except 0, which is valid.\n if (!title && title !== 0) {\n open = false;\n }\n const popperRef = React.useRef();\n const handleMouseMove = event => {\n const childrenProps = children.props;\n if (childrenProps.onMouseMove) {\n childrenProps.onMouseMove(event);\n }\n cursorPosition = {\n x: event.clientX,\n y: event.clientY\n };\n if (popperRef.current) {\n popperRef.current.update();\n }\n };\n const nameOrDescProps = {};\n const titleIsString = typeof title === 'string';\n if (describeChild) {\n nameOrDescProps.title = !open && titleIsString && !disableHoverListener ? title : null;\n nameOrDescProps['aria-describedby'] = open ? id : null;\n } else {\n nameOrDescProps['aria-label'] = titleIsString ? title : null;\n nameOrDescProps['aria-labelledby'] = open && !titleIsString ? id : null;\n }\n const childrenProps = _extends({}, nameOrDescProps, other, children.props, {\n className: clsx(other.className, children.props.className),\n onTouchStart: detectTouchStart,\n ref: handleRef\n }, followCursor ? {\n onMouseMove: handleMouseMove\n } : {});\n if (process.env.NODE_ENV !== 'production') {\n childrenProps['data-mui-internal-clone-element'] = true;\n\n // eslint-disable-next-line react-hooks/rules-of-hooks\n React.useEffect(() => {\n if (childNode && !childNode.getAttribute('data-mui-internal-clone-element')) {\n console.error(['MUI: The `children` component of the Tooltip is not forwarding its props correctly.', 'Please make sure that props are spread on the same element that the ref is applied to.'].join('\\n'));\n }\n }, [childNode]);\n }\n const interactiveWrapperListeners = {};\n if (!disableTouchListener) {\n childrenProps.onTouchStart = handleTouchStart;\n childrenProps.onTouchEnd = handleTouchEnd;\n }\n if (!disableHoverListener) {\n childrenProps.onMouseOver = composeEventHandler(handleMouseOver, childrenProps.onMouseOver);\n childrenProps.onMouseLeave = composeEventHandler(handleMouseLeave, childrenProps.onMouseLeave);\n if (!disableInteractive) {\n interactiveWrapperListeners.onMouseOver = handleMouseOver;\n interactiveWrapperListeners.onMouseLeave = handleMouseLeave;\n }\n }\n if (!disableFocusListener) {\n childrenProps.onFocus = composeEventHandler(handleFocus, childrenProps.onFocus);\n childrenProps.onBlur = composeEventHandler(handleBlur, childrenProps.onBlur);\n if (!disableInteractive) {\n interactiveWrapperListeners.onFocus = handleFocus;\n interactiveWrapperListeners.onBlur = handleBlur;\n }\n }\n if (process.env.NODE_ENV !== 'production') {\n if (children.props.title) {\n console.error(['MUI: You have provided a `title` prop to the child of .', `Remove this title prop \\`${children.props.title}\\` or the Tooltip component.`].join('\\n'));\n }\n }\n const popperOptions = React.useMemo(() => {\n var _PopperProps$popperOp;\n let tooltipModifiers = [{\n name: 'arrow',\n enabled: Boolean(arrowRef),\n options: {\n element: arrowRef,\n padding: 4\n }\n }];\n if ((_PopperProps$popperOp = PopperProps.popperOptions) != null && _PopperProps$popperOp.modifiers) {\n tooltipModifiers = tooltipModifiers.concat(PopperProps.popperOptions.modifiers);\n }\n return _extends({}, PopperProps.popperOptions, {\n modifiers: tooltipModifiers\n });\n }, [arrowRef, PopperProps]);\n const ownerState = _extends({}, props, {\n isRtl,\n arrow,\n disableInteractive,\n placement,\n PopperComponentProp,\n touch: ignoreNonTouchEvents.current\n });\n const classes = useUtilityClasses(ownerState);\n const PopperComponent = (_ref = (_slots$popper = slots.popper) != null ? _slots$popper : components.Popper) != null ? _ref : TooltipPopper;\n const TransitionComponent = (_ref2 = (_ref3 = (_slots$transition = slots.transition) != null ? _slots$transition : components.Transition) != null ? _ref3 : TransitionComponentProp) != null ? _ref2 : Grow;\n const TooltipComponent = (_ref4 = (_slots$tooltip = slots.tooltip) != null ? _slots$tooltip : components.Tooltip) != null ? _ref4 : TooltipTooltip;\n const ArrowComponent = (_ref5 = (_slots$arrow = slots.arrow) != null ? _slots$arrow : components.Arrow) != null ? _ref5 : TooltipArrow;\n const popperProps = appendOwnerState(PopperComponent, _extends({}, PopperProps, (_slotProps$popper = slotProps.popper) != null ? _slotProps$popper : componentsProps.popper, {\n className: clsx(classes.popper, PopperProps == null ? void 0 : PopperProps.className, (_ref6 = (_slotProps$popper2 = slotProps.popper) != null ? _slotProps$popper2 : componentsProps.popper) == null ? void 0 : _ref6.className)\n }), ownerState);\n const transitionProps = appendOwnerState(TransitionComponent, _extends({}, TransitionProps, (_slotProps$transition = slotProps.transition) != null ? _slotProps$transition : componentsProps.transition), ownerState);\n const tooltipProps = appendOwnerState(TooltipComponent, _extends({}, (_slotProps$tooltip = slotProps.tooltip) != null ? _slotProps$tooltip : componentsProps.tooltip, {\n className: clsx(classes.tooltip, (_ref7 = (_slotProps$tooltip2 = slotProps.tooltip) != null ? _slotProps$tooltip2 : componentsProps.tooltip) == null ? void 0 : _ref7.className)\n }), ownerState);\n const tooltipArrowProps = appendOwnerState(ArrowComponent, _extends({}, (_slotProps$arrow = slotProps.arrow) != null ? _slotProps$arrow : componentsProps.arrow, {\n className: clsx(classes.arrow, (_ref8 = (_slotProps$arrow2 = slotProps.arrow) != null ? _slotProps$arrow2 : componentsProps.arrow) == null ? void 0 : _ref8.className)\n }), ownerState);\n return /*#__PURE__*/_jsxs(React.Fragment, {\n children: [/*#__PURE__*/React.cloneElement(children, childrenProps), /*#__PURE__*/_jsx(PopperComponent, _extends({\n as: PopperComponentProp != null ? PopperComponentProp : Popper,\n placement: placement,\n anchorEl: followCursor ? {\n getBoundingClientRect: () => ({\n top: cursorPosition.y,\n left: cursorPosition.x,\n right: cursorPosition.x,\n bottom: cursorPosition.y,\n width: 0,\n height: 0\n })\n } : childNode,\n popperRef: popperRef,\n open: childNode ? open : false,\n id: id,\n transition: true\n }, interactiveWrapperListeners, popperProps, {\n popperOptions: popperOptions,\n children: ({\n TransitionProps: TransitionPropsInner\n }) => /*#__PURE__*/_jsx(TransitionComponent, _extends({\n timeout: theme.transitions.duration.shorter\n }, TransitionPropsInner, transitionProps, {\n children: /*#__PURE__*/_jsxs(TooltipComponent, _extends({}, tooltipProps, {\n children: [title, arrow ? /*#__PURE__*/_jsx(ArrowComponent, _extends({}, tooltipArrowProps, {\n ref: setArrowRef\n })) : null]\n }))\n }))\n }))]\n });\n});\nprocess.env.NODE_ENV !== \"production\" ? Tooltip.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the d.ts file and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * If `true`, adds an arrow to the tooltip.\n * @default false\n */\n arrow: PropTypes.bool,\n /**\n * Tooltip reference element.\n */\n children: elementAcceptingRef.isRequired,\n /**\n * Override or extend the styles applied to the component.\n */\n classes: PropTypes.object,\n /**\n * @ignore\n */\n className: PropTypes.string,\n /**\n * The components used for each slot inside.\n *\n * This prop is an alias for the `slots` prop.\n * It's recommended to use the `slots` prop instead.\n *\n * @default {}\n */\n components: PropTypes.shape({\n Arrow: PropTypes.elementType,\n Popper: PropTypes.elementType,\n Tooltip: PropTypes.elementType,\n Transition: PropTypes.elementType\n }),\n /**\n * The extra props for the slot components.\n * You can override the existing props or add new ones.\n *\n * This prop is an alias for the `slotProps` prop.\n * It's recommended to use the `slotProps` prop instead, as `componentsProps` will be deprecated in the future.\n *\n * @default {}\n */\n componentsProps: PropTypes.shape({\n arrow: PropTypes.object,\n popper: PropTypes.object,\n tooltip: PropTypes.object,\n transition: PropTypes.object\n }),\n /**\n * Set to `true` if the `title` acts as an accessible description.\n * By default the `title` acts as an accessible label for the child.\n * @default false\n */\n describeChild: PropTypes.bool,\n /**\n * Do not respond to focus-visible events.\n * @default false\n */\n disableFocusListener: PropTypes.bool,\n /**\n * Do not respond to hover events.\n * @default false\n */\n disableHoverListener: PropTypes.bool,\n /**\n * Makes a tooltip not interactive, i.e. it will close when the user\n * hovers over the tooltip before the `leaveDelay` is expired.\n * @default false\n */\n disableInteractive: PropTypes.bool,\n /**\n * Do not respond to long press touch events.\n * @default false\n */\n disableTouchListener: PropTypes.bool,\n /**\n * The number of milliseconds to wait before showing the tooltip.\n * This prop won't impact the enter touch delay (`enterTouchDelay`).\n * @default 100\n */\n enterDelay: PropTypes.number,\n /**\n * The number of milliseconds to wait before showing the tooltip when one was already recently opened.\n * @default 0\n */\n enterNextDelay: PropTypes.number,\n /**\n * The number of milliseconds a user must touch the element before showing the tooltip.\n * @default 700\n */\n enterTouchDelay: PropTypes.number,\n /**\n * If `true`, the tooltip follow the cursor over the wrapped element.\n * @default false\n */\n followCursor: PropTypes.bool,\n /**\n * This prop is used to help implement the accessibility logic.\n * If you don't provide this prop. It falls back to a randomly generated id.\n */\n id: PropTypes.string,\n /**\n * The number of milliseconds to wait before hiding the tooltip.\n * This prop won't impact the leave touch delay (`leaveTouchDelay`).\n * @default 0\n */\n leaveDelay: PropTypes.number,\n /**\n * The number of milliseconds after the user stops touching an element before hiding the tooltip.\n * @default 1500\n */\n leaveTouchDelay: PropTypes.number,\n /**\n * Callback fired when the component requests to be closed.\n *\n * @param {React.SyntheticEvent} event The event source of the callback.\n */\n onClose: PropTypes.func,\n /**\n * Callback fired when the component requests to be open.\n *\n * @param {React.SyntheticEvent} event The event source of the callback.\n */\n onOpen: PropTypes.func,\n /**\n * If `true`, the component is shown.\n */\n open: PropTypes.bool,\n /**\n * Tooltip placement.\n * @default 'bottom'\n */\n placement: PropTypes.oneOf(['bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n /**\n * The component used for the popper.\n * @default Popper\n */\n PopperComponent: PropTypes.elementType,\n /**\n * Props applied to the [`Popper`](/material-ui/api/popper/) element.\n * @default {}\n */\n PopperProps: PropTypes.object,\n /**\n * The extra props for the slot components.\n * You can override the existing props or add new ones.\n *\n * This prop is an alias for the `componentsProps` prop, which will be deprecated in the future.\n *\n * @default {}\n */\n slotProps: PropTypes.shape({\n arrow: PropTypes.object,\n popper: PropTypes.object,\n tooltip: PropTypes.object,\n transition: PropTypes.object\n }),\n /**\n * The components used for each slot inside.\n *\n * This prop is an alias for the `components` prop, which will be deprecated in the future.\n *\n * @default {}\n */\n slots: PropTypes.shape({\n arrow: PropTypes.elementType,\n popper: PropTypes.elementType,\n tooltip: PropTypes.elementType,\n transition: PropTypes.elementType\n }),\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Tooltip title. Zero-length titles string, undefined, null and false are never displayed.\n */\n title: PropTypes.node,\n /**\n * The component used for the transition.\n * [Follow this guide](/material-ui/transitions/#transitioncomponent-prop) to learn more about the requirements for this component.\n * @default Grow\n */\n TransitionComponent: PropTypes.elementType,\n /**\n * Props applied to the transition element.\n * By default, the element is based on this [`Transition`](http://reactcommunity.org/react-transition-group/transition/) component.\n */\n TransitionProps: PropTypes.object\n} : void 0;\nexport default Tooltip;","import '@/components/mui/menu-item.component.css';\nimport ArrowRightIcon from '@mui/icons-material/ArrowRight';\nimport {\n ListItemIcon as MuiListItemIcon,\n ListItemText as MuiListItemText,\n MenuItem as MuiMenuItem,\n} from '@mui/material';\nimport Tooltip from '@mui/material/Tooltip';\nimport { Localized, ReferencedItem, SingleColumnMenu } from 'platform-bible-utils';\nimport { MouseEvent, PropsWithChildren } from 'react';\n\ntype MenuItemInfoBase = {\n /** Text (displayable in the UI) as the name of the menu item */\n label: string;\n /** Text to display when the mouse hovers over the menu item */\n tooltip?: string;\n};\n\nexport type Command = MenuItemInfoBase & {\n /** Command to execute (string.string) */\n command: string;\n};\n\ntype SubMenu = MenuItemInfoBase & {\n /** Command to execute (string.string) */\n items: MenuItemInfo[];\n};\n\nexport interface CommandHandler {\n (command: Command): void;\n}\n\nexport type MenuPropsBase = {\n /*\n * The JSON defining the menu whose items are to be rendered. This will typically be one of the\n * menus in the \"defs\" in a Platform.Bible menu (see PlatformMenus). The schema for this is\n * menuDocumentSchema (at the end of menus.model.ts). Note that while this is a\n * \"SingleColumnMenu\", somewhat bizarrely, a MultiColumnMenu is a SingleColumnMenu, so it really\n * could be a MultiColumnMenu, in which case, column had better be defined so it can be used\n * to filter out the actual groups and items to display on the column.\n */\n menuDefinition: Localized;\n\n commandHandler: CommandHandler;\n\n /**\n * Additional action to perform when any menu item is clicked. Allows the caller to handle event\n * (e.g., to close the menu).\n */\n onClick?: (event: MouseEvent) => void;\n};\n\nexport type MenuItemListProps = MenuPropsBase & {\n /** Optional unique (column) identifier */\n columnId?: ReferencedItem;\n};\n\nexport type MenuItemProps = Omit &\n PropsWithChildren<{\n /** Optional unique identifier */\n id?: string;\n\n onClick: (event: MouseEvent) => void;\n }>;\n\ntype MenuItemInfo = (Command | SubMenu) & {\n /**\n * If specified, menu item will be inset if it does not have a leading icon.\n *\n * @default true\n */\n allowForLeadingIcons?: boolean;\n /**\n * If specified, the path to the icon image to display on the leading side of the menu text.\n *\n * @default undefined (no leading icon will be shown)\n */\n iconPathBefore?: string;\n /**\n * If specified, the path to the icon image to display on the trailing side of the menu text.\n *\n * @default undefined (no trailing icon will be shown)\n */\n iconPathAfter?: string;\n /**\n * If true, list item is focused during the first mount\n *\n * @default false\n */\n hasAutoFocus?: boolean;\n\n /** Additional css classes to help with unique styling of the menu item */\n className?: string;\n\n /**\n * If true, the menu item will appear disabled and it will not respond to clicks or mouse hovers.\n *\n * @default false\n */\n isDisabled?: boolean;\n\n /**\n * If true, compact vertical padding designed for keyboard and mouse input is used.\n *\n * @default true\n */\n isDense?: boolean;\n\n /**\n * If true, a right-arrow icon will be displayed (iconPathAfter, if specified, will be ignored).\n *\n * @default false\n */\n isSubMenuParent?: boolean;\n\n /**\n * If true, the left and right padding is removed\n *\n * @default false\n */\n hasDisabledGutters?: boolean;\n\n /**\n * If true, a 1px light border is added to bottom of menu item\n *\n * @default false\n */\n hasDivider?: boolean;\n\n /** Help identify which element has keyboard focus */\n focusVisibleClassName?: string;\n\n /** If it's a submenu, it should have the items property */\n items?: MenuItemInfo[];\n};\n\nfunction getIcon(icon: string | undefined, menuLabel: string, leading: boolean) {\n return icon ? (\n \n {`${leading\n \n ) : undefined;\n}\n\nexport default function MenuItem(props: MenuItemProps) {\n const {\n onClick,\n label,\n tooltip,\n allowForLeadingIcons = true,\n iconPathBefore = undefined,\n iconPathAfter = undefined,\n hasAutoFocus = false,\n className,\n isDisabled = false,\n isDense = true,\n isSubMenuParent = false,\n hasDisabledGutters = false,\n hasDivider = false,\n focusVisibleClassName,\n id,\n children,\n } = props;\n\n const menuItem = (\n \n {label ? (\n <>\n {getIcon(iconPathBefore, label, true)}\n \n {isSubMenuParent ? (\n \n \n \n ) : (\n getIcon(iconPathAfter, label, false)\n )}\n \n ) : (\n children\n )}\n \n );\n\n return tooltip ? (\n \n
    {menuItem}
    \n
    \n ) : (\n menuItem\n );\n}\n","import MenuItem, {\n MenuItemListProps,\n MenuItemProps,\n MenuPropsBase,\n} from '@/components/mui/menu-item.component';\nimport { Menu } from '@mui/material';\nimport {\n Localized,\n MenuGroupDetailsInSubMenu,\n MenuItemContainingCommand,\n MenuItemContainingSubmenu,\n OrderedExtensibleContainer,\n ReferencedItem,\n SingleColumnMenu,\n} from 'platform-bible-utils';\nimport { MouseEvent, useMemo, useState } from 'react';\n\n/**\n * All the exported types in this file should be regarded as \"internal\" (i.e., they should not be\n * exposed via index.ts).\n */\n\nexport type GroupedMenuPropsBase = MenuPropsBase & {\n /** Optional unique (column) identifier */\n columnId?: ReferencedItem;\n};\n\nexport type GroupedMenuItemListProps = MenuItemListProps & {\n /**\n * If the menuDefinition includes \"top-level\" groups (i.e., those that belong to a column as\n * opposed to those that belong to a submenu) that should not be included in the list, then this\n * array specifies which groups to include. Likewise, for a submenu, this list indicates which\n * groups are pertinent for that submenu. So then for a context menu this property need not be\n * specified since it is a top-level menu based on a \"true\" SingleColumnMenu (i.e., one that is\n * not a MultiColumnMenu).\n */\n includedGroups?: {\n id: string;\n group: Localized;\n }[];\n};\n\ninterface ItemInfo {\n item: Localized;\n isLastItemInGroup: boolean;\n}\n\ntype SubMenuProps = MenuPropsBase & {\n parentMenuItem: Localized;\n parentItemProps: Omit, 'iconPathAfter'>;\n};\n\nfunction getAllGroups(menuDefinition: Localized) {\n const groupEntries = Object.entries(menuDefinition.groups);\n // Convert array of entries to array of objects with id and group properties\n return groupEntries.map(([key, value]) => ({ id: key, group: value }));\n}\n\nfunction SubMenu(props: SubMenuProps) {\n const [anchorEl, setAnchorEl] = useState(undefined);\n\n const { parentMenuItem, parentItemProps, menuDefinition } = props;\n\n const handleParentMenuItemClick = (event: MouseEvent) => {\n setAnchorEl(event.currentTarget);\n };\n\n const handleClose = () => {\n setAnchorEl(undefined);\n };\n\n const renderSubMenuItems = () => {\n let includedGroups = getAllGroups(menuDefinition).filter((g) => 'menuItem' in g.group);\n\n // Ensure valid parent menu was provided. (If not, submenu will contain all groups!)\n if (!parentMenuItem?.id) throw new Error('A valid parent menu item is required for submenus.');\n\n // When laying out a submenu, only include groups associated with the provided parent menu.\n // Note: without the (annoying) redundant check that the included groups\n // have the menuItem field, TS doesn't think it exists.\n includedGroups = includedGroups.filter(\n (group) => 'menuItem' in group.group && group.group.menuItem === parentMenuItem.id,\n );\n\n return ;\n };\n\n return (\n <>\n \n \n {renderSubMenuItems()}\n \n \n );\n}\n\nconst getOrderedGroupItems = (\n groupId: string,\n allItems: Localized[],\n) => {\n // Filter items that belong to the specified group\n const itemsForGroup = allItems.filter((item) => item.group === groupId);\n // Sort items based on order\n const sortedItems = itemsForGroup.sort((a, b) => (a.order || 0) - (b.order || 0));\n return sortedItems;\n};\n\n/**\n * This component is internal; it does not need to be exposed to the outside world since it is not\n * useful on its own. It is used to generate and lay out the MenuItems that appear either on a\n * top-level menu (in a GridMenu or ContextMenu) or in a submenu.\n */\nexport default function GroupedMenuItemList(menuProps: GroupedMenuItemListProps) {\n const { menuDefinition, onClick, commandHandler, includedGroups } = menuProps;\n\n const { items, allowForLeadingIcons } = useMemo(() => {\n const groupsToInclude =\n includedGroups && includedGroups.length > 0\n ? includedGroups\n : // We're apparently laying out a single-column menu (presumably a context menu). In this\n // case, all groups should be included except ones that belong to a submenu.\n getAllGroups(menuDefinition).filter((g) => !('menuItem' in g.group));\n\n const sortedGroups = Object.values(groupsToInclude).sort(\n (a, b) => (a.group.order || 0) - (b.group.order || 0),\n );\n\n const itemArray: ItemInfo[] = [];\n\n sortedGroups.forEach((group) => {\n getOrderedGroupItems(group.id, menuDefinition.items).forEach((item) =>\n itemArray.push({ item, isLastItemInGroup: false }),\n );\n if (itemArray.length > 0) itemArray[itemArray.length - 1].isLastItemInGroup = true;\n });\n\n // No divider after last item in final group.\n if (itemArray.length > 0) itemArray[itemArray.length - 1].isLastItemInGroup = false;\n\n const allowSpaceForLeadingIcons = itemArray.some(\n (i) => 'iconPathBefore' in i.item && i.item.iconPathBefore,\n );\n\n return { items: itemArray, allowForLeadingIcons: allowSpaceForLeadingIcons };\n }, [includedGroups, menuDefinition]);\n\n // Create props for MenuItem component including setting hasDivider for the last item in a group\n const createMenuItemProps = ({ item, isLastItemInGroup }: ItemInfo) => {\n const menuItemProps = {\n className: 'papi-menu-item',\n label: item.label,\n tooltip: item.tooltip,\n iconPathBefore: 'iconPathBefore' in item ? item.iconPathBefore : undefined,\n iconPathAfter: 'iconPathAfter' in item ? item.iconPathAfter : undefined,\n hasDivider: isLastItemInGroup, // Set hasDivider to true for the last item in a group\n allowForLeadingIcons,\n };\n\n return menuItemProps;\n };\n\n const [firstItem] = items;\n\n if (!firstItem) return
    ;\n\n const divKey = firstItem.item.group;\n\n return (\n
    \n {items.map((itemInfo, index) => {\n const { item } = itemInfo;\n const menuItemProps = createMenuItemProps(itemInfo);\n if ('command' in item) {\n const key = item.group + index;\n return (\n ) => {\n onClick?.(event);\n commandHandler(item);\n }}\n {...menuItemProps}\n />\n );\n }\n return (\n \n );\n })}\n
    \n );\n}\n","import GroupedMenuItemList from '@/components/mui/grouped-menu-item-list.component';\nimport { MenuItemListProps } from '@/components/mui/menu-item.component';\nimport { MultiColumnMenu } from 'platform-bible-utils';\n\n/**\n * This component is internal; it does not need to be exposed to the outside world since it is not\n * useful on its own. Use either GridMenu or ContextMenu.\n */\nexport default function TopLevelMenu(props: MenuItemListProps) {\n const { menuDefinition, columnId } = props;\n\n const groupEntries = Object.entries(menuDefinition.groups);\n // Convert array of entries to array of objects with id and group properties\n const groups = groupEntries.map(([key, value]) => ({ id: key, group: value }));\n let includedGroups = groups.filter((g) => 'column' in g.group);\n\n // Check if column is provided and menuDefinition is a MultiColumnMenu\n if (\n columnId &&\n 'columns' in menuDefinition &&\n // Without this type assertion, TS doesn't know what columns is.\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n (menuDefinition as MultiColumnMenu).columns[columnId]\n ) {\n // When laying out a single column in a MultiColumnMenu, only include groups associated with\n // the provided column. Note: without the (annoying) redundant check that the included groups\n // have the colum field, TS doesn't think it exists.\n includedGroups = includedGroups.filter(\n (g) => 'column' in g.group && g.group.column === columnId,\n );\n }\n\n return ;\n}\n","import '@/components/mui/grid-menu.component.css';\nimport { GroupedMenuPropsBase } from '@/components/mui/grouped-menu-item-list.component';\nimport { CommandHandler } from '@/components/mui/menu-item.component';\nimport TopLevelMenu from '@/components/mui/top-level-menu.component';\nimport { Grid, List } from '@mui/material';\nimport {\n Localized,\n MenuColumnWithHeader,\n MultiColumnMenu,\n ReferencedItem,\n} from 'platform-bible-utils';\nimport { useMemo } from 'react';\n\ntype ColumnInfo = {\n /*\n * The ID (`${string}.${string}`) of a specific menu column.\n */\n id: ReferencedItem;\n\n /*\n * Metadata (label, order, etc.) for a specific menu column.\n */\n metadata: Localized;\n};\n\ntype MenuColumnProps = ColumnInfo &\n GroupedMenuPropsBase & {\n /** Additional css classes to help with unique styling of the menu column */\n className?: string;\n };\n\nexport type GridMenuInfo = {\n /** The menu object containing information about the columns, groups, and items to display. */\n multiColumnMenu: Localized;\n};\n\nexport type GridMenuProps = GridMenuInfo & {\n /** Optional unique identifier */\n id?: string;\n\n commandHandler: CommandHandler;\n\n /** Additional css classes to help with unique styling of the grid menu */\n className?: string;\n};\n\nfunction MenuColumn({\n commandHandler,\n menuDefinition,\n id,\n metadata,\n onClick,\n className,\n}: MenuColumnProps) {\n return (\n \n

    \n {metadata.label}\n

    \n {/* It would seem as though this List component were unnecessary, since it only contains one\n thing, but the \"dense\" property does affect the layout of the items (in a way I don't fully\n understand). There might be a better way. */}\n \n \n \n \n );\n}\n\nexport default function GridMenu({\n commandHandler,\n className,\n multiColumnMenu,\n id,\n}: GridMenuProps) {\n const { columns } = multiColumnMenu;\n\n const sortedColumns = useMemo(() => {\n const columnNumbers = new Map();\n Object.getOwnPropertyNames(columns).forEach((columnName: string) => {\n // We know for sure there is a (boolean) property 'isExtensible' that we are not interested in.\n if (columnName === 'isExtensible') return;\n // TS doesn't allow `columnName` above to be a ReferencedItem even though the type says it is\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const columnId = columnName as ReferencedItem;\n const column = columns[columnId];\n // As of right now (and hopefully forever after), all remaining properties of the\n // ColumnsWithHeaders object are columns whose property names are the IDs of the columns.\n // This is an additional (redundant) sanity check. Specifically we're interested in\n // MenuColumnWithHeader objects, which TypeScript now \"knows\" we have, but at runtime all we\n // can check for is that it's an object with a valid numeric order field. That's likely good\n // enough.\n if (\n typeof column === 'object' &&\n typeof column.order === 'number' &&\n !Number.isNaN(column.order)\n )\n columnNumbers.set(column.order, { id: columnId, metadata: column });\n else\n console.warn(\n `Property ${columnName} (${typeof column}) on menu ${id} is not a valid column and is being ignored. This might indicate data corruption`,\n );\n });\n\n // Extract values and sort them based on the 'order' property\n return Array.from(columnNumbers.values()).sort((a, b) => {\n return (a.metadata.order || 0) - (b.metadata.order || 0);\n });\n }, [columns, id]);\n\n // We might need something like this if we need to be able to prevent empty columns\n // sortedColumns.filter((c) => multiColumnMenu.groups.some((g) => 'column' in g && (g as .column)...\n\n return (\n \n {sortedColumns.map((col, index) => (\n \n ))}\n \n );\n}\n","import { useEffect, useRef, useState } from 'react';\n\nexport type UsePromiseOptions = {\n /**\n * Whether to leave the value as the most recent resolved promise value or set it back to\n * defaultValue while running the promise again. Defaults to true\n */\n preserveValue?: boolean;\n};\n\n/** Set up defaults for options for usePromise hook */\nfunction getUsePromiseOptionsDefaults(options: UsePromiseOptions): UsePromiseOptions {\n return {\n preserveValue: true,\n ...options,\n };\n}\n\n/**\n * Awaits a promise and returns a loading value while the promise is unresolved\n *\n * @param promiseFactoryCallback A function that returns the promise to await. If this callback is\n * undefined, the current value will be returned (defaultValue unless it was previously changed\n * and `options.preserveValue` is true), and there will be no loading.\n *\n * WARNING: MUST BE STABLE - const or wrapped in useCallback. The reference must not be updated\n * every render\n * @param defaultValue The initial value to return while first awaiting the promise. If\n * `options.preserveValue` is false, this value is also shown while awaiting the promise on\n * subsequent calls.\n *\n * Note: this parameter is internally assigned to a `ref`, so changing it will not cause any hooks\n * to re-run with its new value. This means that, if the `promiseFactoryCallback` changes and\n * `options.preserveValue` is `false`, the returned value will be set to the current\n * `defaultValue`. However, the returned value will not be updated if`defaultValue` changes.\n * @param options Various options for adjusting how this hook runs the `promiseFactoryCallback`\n *\n * Note: this parameter is internally assigned to a `ref`, so changing it will not cause any hooks\n * to re-run with its new value. However, the latest `options.preserveValue` will always be used\n * appropriately to determine whether to preserve the returned value when changing the\n * `promiseFactoryCallback`\n * @returns `[value, isLoading]`\n *\n * - `value`: the current value for the promise, either the defaultValue or the resolved promise value\n * - `isLoading`: whether the promise is waiting to be resolved\n */\nconst usePromise = (\n promiseFactoryCallback: (() => Promise) | undefined,\n defaultValue: T,\n options: UsePromiseOptions = {},\n): [value: T, isLoading: boolean] => {\n // Use defaultValue as a ref so it doesn't update dependency arrays\n const defaultValueRef = useRef(defaultValue);\n defaultValueRef.current = defaultValue;\n // Use options as a ref so it doesn't update dependency arrays\n const optionsDefaultedRef = useRef(options);\n optionsDefaultedRef.current = getUsePromiseOptionsDefaults(optionsDefaultedRef.current);\n\n const [value, setValue] = useState(() => defaultValueRef.current);\n const [isLoading, setIsLoading] = useState(true);\n useEffect(() => {\n let promiseIsCurrent = true;\n // If a promiseFactoryCallback was provided, we are loading. Otherwise, there is no loading to do\n setIsLoading(!!promiseFactoryCallback);\n (async () => {\n // If there is a callback to run, run it\n if (promiseFactoryCallback) {\n const result = await promiseFactoryCallback();\n // If the promise was not already replaced, update the value\n if (promiseIsCurrent) {\n setValue(() => result);\n setIsLoading(false);\n }\n }\n })();\n\n return () => {\n // Mark this promise as old and not to be used\n promiseIsCurrent = false;\n if (!optionsDefaultedRef.current.preserveValue) setValue(() => defaultValueRef.current);\n };\n }, [promiseFactoryCallback]);\n\n return [value, isLoading];\n};\nexport default usePromise;\n","\"use client\";\n\nimport createSvgIcon from './utils/createSvgIcon';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nexport default createSvgIcon( /*#__PURE__*/_jsx(\"path\", {\n d: \"M3 18h18v-2H3zm0-5h18v-2H3zm0-7v2h18V6z\"\n}), 'Menu');","import GridMenu from '@/components/mui/grid-menu.component';\nimport { Command, CommandHandler } from '@/components/mui/menu-item.component';\nimport usePromise from '@/hooks/use-promise.hook';\nimport { Menu as MenuIcon } from '@mui/icons-material';\nimport { Drawer, IconButton } from '@mui/material';\nimport { Localized, MultiColumnMenu } from 'platform-bible-utils';\nimport {\n MouseEvent,\n MutableRefObject,\n PropsWithChildren,\n useCallback,\n useEffect,\n useState,\n} from 'react';\n\nexport interface MultiColumnMenuProvider {\n (isSupportAndDevelopment: boolean): Promise>;\n}\n\nexport type HamburgerMenuButtonProps = PropsWithChildren & {\n /** The handler to use for menu commands (and eventually toolbar commands). */\n commandHandler: CommandHandler;\n\n /**\n * Optional reference to the \"div\" container that determines the where the menu should appear. If\n * not defined, then (1,1) used.\n */\n containerRef?: MutableRefObject;\n\n /**\n * The delegate to use to get the menu data. If not specified or if it returns undefined, the data\n * in normalMenu or fullMenu property will be used.\n */\n menuProvider?: MultiColumnMenuProvider;\n\n /**\n * The menu data to show when the menu is opened if the menuProvider property is not defined.\n * (This allows for a default or test-only static menu to be used.)\n */\n normalMenu?: Localized;\n\n /**\n * The menu data to show for \"full\" menu (when opened with the SHIFT key pressed) if the\n * menuProvider property is not defined. (This allows for a default or test-only static menu to be\n * used.)\n */\n fullMenu?: Localized;\n\n /** Additional css class(es) to help with unique styling of the sub-components */\n className?: string;\n\n /** Value to use as prefix for ARIA labels on interactive sub-components */\n ariaLabelPrefix?: string;\n};\n\nexport default function HamburgerMenuButton({\n menuProvider,\n normalMenu,\n fullMenu,\n commandHandler,\n containerRef,\n className,\n ariaLabelPrefix,\n children,\n}: HamburgerMenuButtonProps) {\n const [isMenuOpen, setMenuOpen] = useState(false);\n const [showFullMenu, setShowFullMenu] = useState(false);\n\n const handleMenuItemClick = useCallback(() => {\n if (isMenuOpen) setMenuOpen(false);\n setShowFullMenu(false);\n }, [isMenuOpen]);\n\n const handleMenuButtonClick = useCallback((e: MouseEvent) => {\n e.stopPropagation();\n setMenuOpen((prevIsOpen) => {\n const isOpening = !prevIsOpen;\n if (isOpening && e.shiftKey) setShowFullMenu(true);\n else if (!isOpening) setShowFullMenu(false);\n return isOpening;\n });\n }, []);\n\n const menuCommandHandler = useCallback(\n (command: Command) => {\n handleMenuItemClick();\n return commandHandler(command);\n },\n [commandHandler, handleMenuItemClick],\n );\n\n const [offset, setOffset] = useState({ top: 1, left: 1 });\n\n useEffect(() => {\n if (isMenuOpen) {\n const node = containerRef?.current;\n if (node) {\n const rect = node.getBoundingClientRect();\n const scrollTop = window.scrollY;\n const scrollLeft = window.scrollX;\n const top = rect.top + scrollTop + node.clientHeight;\n const left = rect.left + scrollLeft;\n setOffset({ top, left });\n }\n }\n }, [isMenuOpen, containerRef]);\n\n const [normalMenuData] = usePromise(\n useCallback(async () => {\n return menuProvider?.(false) ?? normalMenu;\n // isMenuOpen needs to be included for the menu contents to reevaluate when reopened\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [menuProvider, normalMenu, isMenuOpen]),\n normalMenu,\n );\n\n const [fullMenuData] = usePromise(\n useCallback(async () => {\n return menuProvider?.(true) ?? fullMenu ?? normalMenuData;\n // isMenuOpen needs to be included for the menu contents to reevaluate when reopened\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [menuProvider, fullMenu, normalMenuData, isMenuOpen]),\n fullMenu ?? normalMenuData,\n );\n\n const menu = showFullMenu && fullMenuData ? fullMenuData : normalMenuData;\n\n return (\n <>\n \n {children ?? }\n \n \n {menu ? (\n \n ) : undefined}\n \n \n );\n}\n","import '@/components/mui/icon-button.component.css';\nimport { IconButton as MuiIconButton } from '@mui/material';\nimport { MouseEventHandler, PropsWithChildren } from 'react';\n\nexport type IconButtonProps = PropsWithChildren<{\n /** Optional unique identifier */\n id?: string;\n /**\n * Required. Used as both the tooltip (aka, title) and the aria-label (used for accessibility,\n * testing, etc.), unless a distinct tooltip is supplied.\n */\n label: string;\n /**\n * Enabled status of button\n *\n * @default false\n */\n isDisabled?: boolean;\n /** Optional tooltip to display if different from the aria-label. */\n tooltip?: string;\n /** If true, no tooltip will be displayed. */\n isTooltipSuppressed?: boolean;\n /**\n * If given, uses a negative margin to counteract the padding on one side (this is often helpful\n * for aligning the left or right side of the icon with content above or below, without ruining\n * the border size and shape).\n *\n * @default false\n */\n adjustMarginToAlignToEdge?: 'end' | 'start' | false;\n /**\n * The size of the component. small is equivalent to the dense button styling.\n *\n * @default false\n */\n size: 'small' | 'medium' | 'large';\n /** Additional css classes to help with unique styling of the button */\n className?: string;\n /** Optional click handler */\n onClick?: MouseEventHandler;\n}>;\n\n/**\n * Iconic button a user can click to do something\n *\n * Thanks to MUI for heavy inspiration and documentation\n * https://mui.com/material-ui/getting-started/overview/\n */\nfunction IconButton({\n id,\n label,\n isDisabled = false,\n tooltip,\n isTooltipSuppressed = false,\n adjustMarginToAlignToEdge = false,\n size = 'medium',\n className,\n onClick,\n children,\n}: IconButtonProps) {\n return (\n \n {children /* the icon to display */}\n \n );\n}\n\nexport default IconButton;\n","import { cn } from '@/utils/shadcn-ui.util';\nimport { LoaderCircle, LucideProps } from 'lucide-react';\nimport { forwardRef } from 'react';\n\nexport type SpinnerProps = LucideProps;\n\nconst Spinner = forwardRef(({ className, ...props }, ref) => {\n return (\n \n );\n});\n\nSpinner.displayName = 'Spinner';\n\nexport default Spinner;\n","import { Input as ShadInput } from '@/components/shadcn-ui/input';\nimport { Label as ShadLabel } from '@/components/shadcn-ui/label';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { ChangeEventHandler, FocusEventHandler } from 'react';\n\nexport type TextFieldProps = {\n /** Optional unique identifier */\n id?: string;\n /**\n * If `true`, the component is disabled.\n *\n * @default false\n */\n isDisabled?: boolean;\n /**\n * If `true`, the label is displayed in an error state.\n *\n * @default false\n */\n hasError?: boolean;\n /**\n * If `true`, the input will take up the full width of its container.\n *\n * @default false\n */\n isFullWidth?: boolean;\n /** Text that gives the user instructions on what contents the TextField expects */\n helperText?: string;\n /** The title of the TextField */\n label?: string;\n /** The short hint displayed in the `input` before the user enters a value. */\n placeholder?: string;\n /**\n * If `true`, the label is displayed as required and the `input` element is required.\n *\n * @default false\n */\n isRequired?: boolean;\n /** Additional css classes to help with unique styling of the text field */\n className?: string;\n /** Starting value for the text field if it is not controlled */\n defaultValue?: string | number;\n /** Value of the text field if controlled */\n value?: string | number;\n /** Triggers when content of textfield is changed */\n onChange?: ChangeEventHandler;\n /** Triggers when textfield gets focus */\n onFocus?: FocusEventHandler;\n /** Triggers when textfield loses focus */\n onBlur?: FocusEventHandler;\n};\n\n/**\n * Text input field\n *\n * Thanks to Shadcn for heavy inspiration and documentation\n * https://ui.shadcn.com/docs/components/input#with-label\n */\nfunction TextField({\n id,\n isDisabled = false,\n hasError = false,\n isFullWidth = false,\n helperText,\n label,\n placeholder,\n isRequired = false,\n className,\n defaultValue,\n value,\n onChange,\n onFocus,\n onBlur,\n}: TextFieldProps) {\n return (\n
    \n {`${label}${isRequired ? '*' : ''}`}\n \n

    {helperText}

    \n
    \n );\n}\n\nexport default TextField;\n","import HamburgerMenuButton, {\n MultiColumnMenuProvider,\n} from '@/components/mui/hamburger-menu-button.component';\nimport { CommandHandler } from '@/components/mui/menu-item.component';\nimport '@/components/mui/toolbar.component.css';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { AppBar, Toolbar as MuiToolbar } from '@mui/material';\nimport { PropsWithChildren, useRef } from 'react';\n\nexport type ToolbarProps = PropsWithChildren<{\n /** The handler to use for menu commands (and eventually toolbar commands). */\n commandHandler: CommandHandler;\n\n /**\n * The optional delegate to use to get the menu data. If not specified, the \"hamburger\" menu will\n * not display.\n */\n menuProvider?: MultiColumnMenuProvider;\n\n /** Optional unique identifier */\n id?: string;\n\n /** Additional css classes to help with unique styling of the toolbar */\n className?: string;\n}>;\n\nexport default function Toolbar({\n menuProvider,\n commandHandler,\n className,\n id,\n children,\n}: ToolbarProps) {\n // This ref will always be defined\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const containerRef = useRef(undefined!);\n\n return (\n
    \n \n \n {menuProvider ? (\n \n ) : undefined}\n {children ?
    {children}
    : undefined}\n \n
    \n
    \n );\n}\n","import React from 'react';\nimport { cva, type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst alertVariants = cva(\n 'tw-relative tw-w-full tw-rounded-lg tw-border tw-p-4 [&>svg~*]:tw-pl-7 [&>svg+div]:tw-translate-y-[-3px] [&>svg]:tw-absolute [&>svg]:tw-left-4 [&>svg]:tw-top-4 [&>svg]:tw-text-foreground',\n {\n variants: {\n variant: {\n default: 'tw-bg-background tw-text-foreground',\n destructive:\n 'tw-border-destructive/50 tw-text-destructive dark:tw-border-destructive [&>svg]:tw-text-destructive',\n },\n },\n defaultVariants: {\n variant: 'default',\n },\n },\n);\n\nconst Alert = React.forwardRef<\n HTMLDivElement,\n React.HTMLAttributes & VariantProps\n>(({ className, variant, ...props }, ref) => (\n
    \n));\nAlert.displayName = 'Alert';\n\nconst AlertTitle = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n {/* added because of https://github.com/jsx-eslint/eslint-plugin-jsx-a11y/blob/main/docs/rules/heading-has-content.md */}\n {props.children}{' '}\n \n ),\n);\nAlertTitle.displayName = 'AlertTitle';\n\nconst AlertDescription = React.forwardRef<\n HTMLParagraphElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n
    \n));\nAlertDescription.displayName = 'AlertDescription';\n\nexport { Alert, AlertTitle, AlertDescription };\n","import React from 'react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Card = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nCard.displayName = 'Card';\n\nconst CardHeader = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nCardHeader.displayName = 'CardHeader';\n\nconst CardTitle = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n {/* added because of https://github.com/jsx-eslint/eslint-plugin-jsx-a11y/blob/main/docs/rules/heading-has-content.md */}\n {props.children}\n \n ),\n);\nCardTitle.displayName = 'CardTitle';\n\nconst CardDescription = React.forwardRef<\n HTMLParagraphElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n

    \n));\nCardDescription.displayName = 'CardDescription';\n\nconst CardContent = React.forwardRef>(\n ({ className, ...props }, ref) => (\n

    \n ),\n);\nCardContent.displayName = 'CardContent';\n\nconst CardFooter = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nCardFooter.displayName = 'CardFooter';\n\nexport { Card, CardHeader, CardFooter, CardTitle, CardDescription, CardContent };\n","import { ComponentProps } from 'react';\nimport { toast as sonner, Toaster } from 'sonner';\n\ntype SonnerProps = ComponentProps;\n\nfunction Sonner({ ...props }: SonnerProps) {\n return (\n \n );\n}\n\n// The re-export of the sonner function was added manually\nexport { Sonner, sonner };\n","import React from 'react';\nimport * as SliderPrimitive from '@radix-ui/react-slider';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Slider = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n \n \n \n));\nSlider.displayName = SliderPrimitive.Root.displayName;\n\nexport { Slider };\n","import React from 'react';\nimport * as SwitchPrimitives from '@radix-ui/react-switch';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Switch = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n));\nSwitch.displayName = SwitchPrimitives.Root.displayName;\n\nexport { Switch };\n","import React from 'react';\nimport * as TabsPrimitive from '@radix-ui/react-tabs';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport const Tabs = TabsPrimitive.Root;\n\nexport type TabsListProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport type TabsTriggerProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport type TabsContentProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport const TabsList = React.forwardRef<\n React.ElementRef,\n TabsListProps\n>(({ className, ...props }, ref) => (\n \n));\nTabsList.displayName = TabsPrimitive.List.displayName;\n\nexport const TabsTrigger = React.forwardRef<\n React.ElementRef,\n TabsTriggerProps\n>(({ className, ...props }, ref) => (\n \n));\nTabsTrigger.displayName = TabsPrimitive.Trigger.displayName;\n\nexport const TabsContent = React.forwardRef<\n React.ElementRef,\n TabsContentProps\n>(({ className, ...props }, ref) => (\n \n));\nTabsContent.displayName = TabsPrimitive.Content.displayName;\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Download } from 'lucide-react';\n\ntype InstallButtonProps = {\n /** The installing boolean value determines the state of the button. */\n isInstalling: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n /** Optional text for the button. */\n buttonText?: string;\n} & ButtonProps;\n\n/**\n * The InstallButton component is a button designed for initiating installs. It includes visuals for\n * active installing and idle states.\n *\n * @param isInstalling The installing boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @param buttonText Optional text for the button.\n * @returns A install button.\n */\nexport default function InstallButton({\n isInstalling,\n handleClick,\n buttonText,\n className,\n ...props\n}: InstallButtonProps) {\n return (\n \n {isInstalling ? (\n \n ) : (\n <>\n \n {buttonText}\n \n )}\n \n );\n}\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\n\ntype EnableButtonProps = {\n /** The enabling boolean value determines the state of the button. */\n isEnabling: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n} & ButtonProps;\n\n/**\n * The EnableButton component is a button designed for initiating enabling of downloads. It includes\n * visuals for active enabling and idle states.\n *\n * @param isEnabling The enabling boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @returns A button that can be used to enable.\n */\nexport default function EnableButton({\n isEnabling,\n handleClick,\n className,\n ...props\n}: EnableButtonProps) {\n return (\n \n {isEnabling ? (\n <>\n \n Enabling...\n \n ) : (\n 'Enable'\n )}\n \n );\n}\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\n\ntype DisableButtonProps = {\n /** The disabling boolean value determines the state of the button. */\n isDisabling: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n} & ButtonProps;\n\n/**\n * The DisableButton component is a button designed for initiating disabling of downloads. It\n * includes visuals for active disabling and idle states.\n *\n * @param isDisabling The disabling boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @returns A button that can be used to disable.\n */\nexport default function DisableButton({\n isDisabling,\n handleClick,\n className,\n ...props\n}: DisableButtonProps) {\n return (\n \n {isDisabling ? (\n <>\n \n Disabling...\n \n ) : (\n 'Disable'\n )}\n \n );\n}\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\n\ntype UpdateButtonProps = {\n /** The updating boolean value determines the state of the button. */\n isUpdating: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n} & ButtonProps;\n\n/**\n * The UpdateButton component is a button designed for initiating updates for downloaded extensions.\n * It includes visuals for active updating and idle states.\n *\n * @param isUpdating The updating boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @returns A button that can be used to update.\n */\nexport default function UpdateButton({\n isUpdating,\n handleClick,\n className,\n ...props\n}: UpdateButtonProps) {\n return (\n \n {isUpdating ? (\n <>\n \n Updating...\n \n ) : (\n 'Update'\n )}\n \n );\n}\n","import { cn } from '@/utils/shadcn-ui.util';\nimport Markdown, { MarkdownToJSX } from 'markdown-to-jsx';\nimport { useMemo } from 'react';\n\ninterface MarkdownRendererProps {\n /** Optional unique identifier */\n id?: string;\n /** The markdown string to render */\n markdown: string;\n className?: string;\n /**\n * The [`target` attribute for `a` html\n * tags](https://developer.mozilla.org/en-US/docs/Web/HTML/Element/a#target). Defaults to not\n * adding a `target` to `a` tags\n */\n anchorTarget?: string;\n}\n\n/**\n * This component renders markdown content given a markdown string. It uses typography styles from\n * the platform.\n *\n * @param markdown The markdown string to render.\n * @param id Optional unique identifier\n * @returns A div containing the rendered markdown content.\n */\nexport default function MarkdownRenderer({\n id,\n markdown,\n className,\n anchorTarget,\n}: MarkdownRendererProps) {\n const options: MarkdownToJSX.Options = useMemo(\n () => ({\n overrides: {\n a: {\n props: {\n target: anchorTarget,\n },\n },\n },\n }),\n [anchorTarget],\n );\n return (\n
    \n {markdown}\n
    \n );\n}\n","import { Filter, ChevronDown } from 'lucide-react';\nimport { forwardRef } from 'react';\nimport { Button } from '@/components/shadcn-ui/button';\n\n/**\n * The FilterButton component is a button designed for initiating filtering of data. It is designed\n * to be used with the dropdown menu. It uses forwardRef to pass the button to the dropdown trigger\n * asChild.\n *\n * @returns A button that can be used to filter.\n */\nconst FilterButton = forwardRef((props, ref) => {\n return (\n \n \n Filter\n \n \n );\n});\n\nexport default FilterButton;\n","import {\n DropdownMenu,\n DropdownMenuTrigger,\n DropdownMenuContent,\n DropdownMenuLabel,\n DropdownMenuGroup,\n DropdownMenuCheckboxItem,\n DropdownMenuRadioItem,\n DropdownMenuSeparator,\n} from '@/components/shadcn-ui/dropdown-menu';\nimport FilterButton from './buttons/filter-button.component';\n\nexport enum DropdownMenuItemType {\n Check,\n Radio,\n}\n\nexport type DropdownItem = {\n /** The label is the text that will be displayed on the dropdown item. */\n label: string;\n /** The itemType determines the DropdownMenuItemType type as either Check or Radio. */\n itemType: DropdownMenuItemType;\n /** The onClick function is called when the item is clicked. */\n onClick: () => void;\n};\n\nexport type DropdownGroup = {\n /**\n * The label is the text that will be displayed on the dropdown group. It is used to categorize\n * the items in the group.\n */\n label: string;\n /** The items array contains the items that will be displayed in the dropdown group */\n items: DropdownItem[];\n};\n\nexport type FilterDropdownProps = {\n /** Object unique identifier */\n id?: string;\n /** The groups array contains the groups that will be displayed in the dropdown */\n groups: DropdownGroup[];\n}; // TODO: extend the props later\n\n/**\n * The FilterDropdown component is a dropdown designed for filtering content. It includes groups of\n * items that can be checkboxes or radio items.\n *\n * @param id Optional unique identifier\n * @param groups The groups array contains the groups that will be displayed in the dropdown\n * @returns A filter dropdown.\n */\nexport default function FilterDropdown({ id, groups }: FilterDropdownProps) {\n return (\n
    \n {/* TODO: remove this once the DropDown Menu shadcn has an id prop */}\n \n \n \n \n \n {groups.map((group) => (\n
    \n {group.label}\n \n {group.items.map((item) => (\n
    \n {item.itemType === DropdownMenuItemType.Check ? (\n \n {item.label}\n \n ) : (\n \n {item.label}\n \n )}\n
    \n ))}\n
    \n \n
    \n ))}\n
    \n
    \n
    \n );\n}\n","interface NoExtensionsFoundProps {\n /** Optional unique identifier */\n id?: string;\n /** The message to display */\n message: string;\n}\n/**\n * This component displays a message to the user when no extensions are found in the marketplace.\n *\n * @param id Optional unique identifier\n * @param message The message to display.\n * @returns {JSX.Element} - Returns the message component that displays the message to the user.\n */\nexport default function NoExtensionsFound({ id, message }: NoExtensionsFoundProps) {\n return (\n
    \n
    \n

    {message}

    \n
    \n
    \n );\n}\n","import { CircleHelp, Link as LucideLink, User } from 'lucide-react';\nimport { NumberFormat } from 'platform-bible-utils';\n\n/** Interface that stores the parameters passed to the More Info component */\ninterface MoreInfoProps {\n /** Optional unique identifier */\n id?: string;\n /** The category of the extension */\n category: string;\n /** The number of downloads for the extension */\n downloads: Record;\n /** The languages supported by the extension */\n languages: string[];\n /** The URL to the more info page of the extension */\n moreInfoUrl: string;\n}\n/**\n * This component displays the more info section of the extension which includes the category,\n * number of downloads, languages, and links to the website and support\n *\n * @param id Optional unique identifier\n * @param category The category of the extension\n * @param downloads The number of downloads for the extension\n * @param languages The languages supported by the extension\n * @param moreInfoUrl The URL to the more info page of the extension\n * @returns {JSX.Element} - Returns the more info component that displays the category, number of\n * downloads, languages, and links to the website and support\n */\nexport default function MoreInfo({\n id,\n category,\n downloads,\n languages,\n moreInfoUrl,\n}: MoreInfoProps) {\n /**\n * This constant formats the number of downloads into a more readable format.\n *\n * @example 1000 -> 1K\n *\n * @example 1000000 -> 1M\n *\n * @returns The formatted number of downloads\n */\n const numberFormatted = new NumberFormat('en', {\n notation: 'compact',\n compactDisplay: 'short',\n }).format(Object.values(downloads).reduce((a: number, b: number) => a + b, 0));\n\n /** This function scrolls the window to the bottom of the page. */\n const handleScrollToBottom = () => {\n window.scrollTo(0, document.body.scrollHeight);\n };\n\n return (\n \n
    \n
    \n {category}\n
    \n CATEGORY\n
    \n
    \n
    \n
    \n \n {numberFormatted}\n
    \n USERS\n
    \n
    \n
    \n
    \n {languages.slice(0, 3).map((locale) => (\n \n {locale.toUpperCase()}\n \n ))}\n
    \n {languages.length > 3 && (\n handleScrollToBottom()}\n className=\"tw-text-xs tw-text-gray-500 tw-underline\"\n >\n +{languages.length - 3} more languages\n \n )}\n
    \n
    \n
    \n \n Website\n \n \n \n Support\n \n \n
    \n
    \n );\n}\n","import { useState } from 'react';\n\nexport type VersionInformation = {\n /** Date the version was published */\n date: string;\n /** Description of the changes in the version */\n description: string;\n};\n\n/** Type to store the version history information */\nexport type VersionHistoryType = Record;\n\n/** Interface that stores the parameters passed to the Version History component */\ninterface VersionHistoryProps {\n /** Optional unique identifier */\n id?: string;\n /** Object containing the versions mapped with their information */\n versionHistory: VersionHistoryType;\n}\n\n/**\n * Component to render the version history information shown in the footer component. Lists the 5\n * most recent versions, with the options to show all versions by pressing a button.\n *\n * @param versionHistory Object containing the versions mapped with their information\n * @param id Optional unique identifier\n * @returns Rendered version history for the Footer component\n */\nexport default function VersionHistory({ id, versionHistory }: VersionHistoryProps) {\n const [showAllVersions, setShowAllVersions] = useState(false);\n const currentDate = new Date();\n\n /**\n * Function to format the time string for the version history in the form of 'X year(s) ago'.\n *\n * @param dateString ISO Date string to determine the time string from\n * @returns Formatted time string\n */\n function formatTimeString(dateString: string) {\n const date = new Date(dateString);\n const dateDiff = new Date(currentDate.getTime() - date.getTime());\n const yearDiff = dateDiff.getUTCFullYear() - 1970;\n const monthDiff = dateDiff.getUTCMonth();\n const dayDiff = dateDiff.getUTCDate() - 1;\n\n // Determines how long ago the version was published\n let timeString = '';\n if (yearDiff > 0) {\n timeString = `${yearDiff.toString()} year${yearDiff === 1 ? '' : 's'} ago`;\n } else if (monthDiff > 0) {\n timeString = `${monthDiff.toString()} month${monthDiff === 1 ? '' : 's'} ago`;\n } else if (dayDiff === 0) {\n timeString = 'today';\n } else {\n timeString = `${dayDiff.toString()} day${dayDiff === 1 ? '' : 's'} ago`;\n }\n\n return timeString;\n }\n\n // Sorts the version history by version number\n const sortedEntries = Object.entries(versionHistory).sort((a, b) => b[0].localeCompare(a[0]));\n\n return (\n
    \n

    What`s New

    \n
      \n {(showAllVersions ? sortedEntries : sortedEntries.slice(0, 5)).map((entry) => (\n
      \n
      \n
    • \n {entry[1].description}\n
    • \n
      \n
      \n
      Version {entry[0]}
      \n
      {formatTimeString(entry[1].date)}
      \n
      \n
      \n ))}\n
    \n {sortedEntries.length > 5 && (\n setShowAllVersions(!showAllVersions)}\n className=\"tw-text-xs tw-text-gray-500 tw-underline\"\n >\n {showAllVersions ? 'Show Less Version History' : 'Show All Version History'}\n \n )}\n
    \n );\n}\n","import { useMemo } from 'react';\nimport { formatBytes } from 'platform-bible-utils';\nimport VersionHistory, { VersionHistoryType } from './version-history.component';\n\n/** Interface to store the parameters passed to the Footer component */\ninterface FooterProps {\n /** Optional unique identifier */\n id?: string;\n /** Name of the publisher */\n publisherDisplayName: string;\n /** Size of the extension file in bytes */\n fileSize: number;\n /** List of language codes supported by the extension */\n locales: string[];\n /** Object containing the version history mapped with their information */\n versionHistory: VersionHistoryType;\n}\n\n/**\n * Component to render the footer for the extension details which contains information on the\n * publisher, version history, languages, and file size.\n *\n * @param id Optional unique identifier\n * @param publisherDisplayName Name of the publisher\n * @param fileSize Size of the extension file in bytes\n * @param locales List of language codes supported by the extension\n * @param versionHistory Object containing the version history mapped with their information\n * @returns The rendered Footer component\n */\nexport default function Footer({\n id,\n publisherDisplayName,\n fileSize,\n locales,\n versionHistory,\n}: FooterProps) {\n /** Formats the file size into a human-readable format */\n const formattedFileSize = useMemo(() => formatBytes(fileSize), [fileSize]);\n\n /**\n * This function gets the display names of the languages based on the language codes.\n *\n * @param codes The list of language codes\n * @returns The list of language names\n */\n const getLanguageNames = (codes: string[]) => {\n const displayNames = new Intl.DisplayNames(navigator.language, { type: 'language' });\n return codes.map((code) => displayNames.of(code));\n };\n\n const languageNames = getLanguageNames(locales);\n\n return (\n
    \n
    \n \n
    \n
    \n

    Information

    \n
    \n

    \n Publisher\n {publisherDisplayName}\n Size\n {formattedFileSize}\n

    \n
    \n

    \n Languages\n {languageNames.join(', ')}\n

    \n
    \n
    \n
    \n
    \n
    \n );\n}\n","import { PlatformEvent, PlatformEventHandler } from 'platform-bible-utils';\nimport { useEffect } from 'react';\n\n/**\n * Adds an event handler to an event so the event handler runs when the event is emitted. Use\n * `papi.network.getNetworkEvent` to use a networked event with this hook.\n *\n * @param event The event to subscribe to.\n *\n * - If event is a `PlatformEvent`, that event will be used\n * - If event is undefined, the callback will not be subscribed. Useful if the event is not yet\n * available for example\n *\n * @param eventHandler The callback to run when the event is emitted\n *\n * WARNING: MUST BE STABLE - const or wrapped in useCallback. The reference must not be updated\n * every render\n */\nconst useEvent = (\n event: PlatformEvent | undefined,\n eventHandler: PlatformEventHandler,\n) => {\n useEffect(() => {\n // Do nothing if the event is not provided (in case the event is not yet available, for example)\n if (!event) return () => {};\n\n const unsubscriber = event(eventHandler);\n return () => {\n unsubscriber();\n };\n }, [event, eventHandler]);\n};\nexport default useEvent;\n","import { useCallback, useEffect } from 'react';\nimport { PlatformEvent, PlatformEventAsync, PlatformEventHandler } from 'platform-bible-utils';\nimport usePromise from './use-promise.hook';\n\nconst noopUnsubscriber = () => false;\n\n/**\n * Adds an event handler to an asynchronously subscribing/unsubscribing event so the event handler\n * runs when the event is emitted. Use `papi.network.getNetworkEvent` to use a networked event with\n * this hook.\n *\n * @param event The asynchronously (un)subscribing event to subscribe to.\n *\n * - If event is a `PlatformEvent` or `PlatformEventAsync`, that event will be used\n * - If event is undefined, the callback will not be subscribed. Useful if the event is not yet\n * available for example\n *\n * @param eventHandler The callback to run when the event is emitted\n *\n * WARNING: MUST BE STABLE - const or wrapped in useCallback. The reference must not be updated\n * every render\n */\nconst useEventAsync = (\n event: PlatformEvent | PlatformEventAsync | undefined,\n eventHandler: PlatformEventHandler,\n) => {\n // Subscribe to the event asynchronously\n const [unsubscribe] = usePromise(\n useCallback(async () => {\n // Do nothing if the event is not provided (in case the event is not yet available, for example)\n if (!event) return noopUnsubscriber;\n\n // Wrap subscribe and unsubscribe in promises to allow normal events to be used as well\n const unsub = await Promise.resolve(event(eventHandler));\n return async () => unsub();\n }, [eventHandler, event]),\n noopUnsubscriber,\n // We want the unsubscriber to return to default value immediately upon changing subscription\n // So the useEffect below will unsubscribe asap\n { preserveValue: false },\n );\n\n // Unsubscribe from the event asynchronously (but we aren't awaiting the unsub)\n useEffect(() => {\n return () => {\n if (unsubscribe !== noopUnsubscriber) {\n unsubscribe();\n }\n };\n }, [unsubscribe]);\n};\n\nexport default useEventAsync;\n"],"names":["twMergeCustom","extendTailwindMerge","cn","inputs","clsx","Input","React","className","type","props","ref","jsx","BookChapterInput","forwardRef","handleSearch","handleKeyDown","handleOnClick","handleSubmit","jsxs","ShadInput","event","e","History","P","R","s","n","N","B","O","S","K","g","k","x","T","X","V","w","L","G","A","H","C","I","y","q","U","m","l","h","c","E","D","i","a","o","u","v","f","d","b","p","J","DropdownMenu","DropdownMenuPrimitive","DropdownMenuTrigger","DropdownMenuGroup","DropdownMenuPortal","DropdownMenuSub","DropdownMenuRadioGroup","DropdownMenuSubTrigger","inset","children","ChevronRight","DropdownMenuSubContent","DropdownMenuContent","sideOffset","DropdownMenuItem","DropdownMenuCheckboxItem","checked","Check","DropdownMenuRadioItem","Circle","DropdownMenuLabel","DropdownMenuSeparator","DropdownMenuShortcut","BookMenuItem","bookId","handleSelectBook","isSelected","handleHighlightBook","bookType","ShadDropdownMenuItem","Canon","ChapterSelect","handleSelectChapter","endChapter","activeChapter","highlightedChapter","handleHighlightedChapter","chapters","_","handleMouse","useCallback","chapterNumber","chapter","GoToMenuItem","handleSort","handleLocationHistory","handleBookmarks","ShadDropdownMenuLabel","ArrowDownWideNarrow","Clock","Bookmark","ALL_BOOK_IDS","BOOK_TYPE_LABELS","BOOK_TYPE_ARRAY","SCROLL_OFFSET","SEARCH_QUERY_FORMATS","fetchGroupedBooks","fetchEndChapter","getChaptersForBook","getAllEnglishNames","isValidBookEnglishName","bookName","getBookIdFromEnglishName","formattedBookName","BookChapterControl","scrRef","searchQuery","setSearchQuery","useState","selectedBookId","setSelectedBookId","setHighlightedChapter","highlightedBookId","setHighlightedBookId","isContentOpen","setIsContentOpen","isContentOpenDelayed","setIsContentOpenDelayed","inputRef","useRef","contentRef","menuItemRef","fetchFilteredBooks","englishNameLowerCase","normalizedQuery","handleSearchInput","searchString","shouldPreventAutoClosing","controlMenuState","open","updateReference","shouldClose","verse","handleInputSubmit","format","matches","book","englishName","handleKeyDownInput","handleKeyDownContent","key","handleKeyDownMenuItem","chapterOffSet","useEffect","useLayoutEffect","scrollTimeout","scrollPosition","ShadDropdownMenu","ShadDropdownMenuTrigger","ShadDropdownMenuContent","bookTypeIndex","element","ShadDropdownMenuSeparator","buttonVariants","cva","Button","variant","size","asChild","Slot","labelVariants","Label","LabelPrimitive","RadioGroup","RadioGroupPrimitive","RadioGroupItem","Popover","PopoverPrimitive","PopoverTrigger","PopoverContent","align","DialogPortal","DialogPrimitive","DialogOverlay","DialogContent","DialogTitle","DialogDescription","Command","CommandPrimitive","CommandInput","Search","CommandList","CommandEmpty","CommandGroup","CommandSeparator","CommandItem","getOptionLabelDefault","option","ComboBox","id","options","buttonClassName","popoverContentClassName","value","onChange","getOptionLabel","buttonPlaceholder","textPlaceholder","commandEmptyMessage","buttonVariant","dir","isDisabled","setOpen","ChevronsUpDown","ChapterRangeSelector","startChapter","handleSelectStartChapter","handleSelectEndChapter","chapterCount","chapterOptions","useMemo","index","Fragment","BookSelectionMode","BOOK_SELECTOR_STRING_KEYS","localizeString","strings","BookSelector","handleBookSelectionModeChange","currentBookName","onSelectBooks","selectedBookIds","localizedStrings","currentBookText","chooseText","chooseBooksText","bookSelectionMode","setBookSelectionMode","onSelectionModeChange","newMode","DataTableViewOptions","table","FilterIcon","column","Select","SelectPrimitive","SelectGroup","SelectValue","SelectTrigger","ChevronDown","SelectScrollUpButton","ChevronUp","SelectScrollDownButton","SelectContent","position","SelectLabel","SelectItem","SelectSeparator","DataTablePagination","pageSize","ArrowLeftIcon","ChevronLeftIcon","ChevronRightIcon","ArrowRightIcon","Table","stickyHeader","TableHeader","TableBody","TableFooter","TableRow","TableHead","TableCell","TableCaption","DataTable","columns","data","enablePagination","showPaginationControls","showColumnVisibilityControls","onRowClickHandler","sorting","setSorting","columnFilters","setColumnFilters","columnVisibility","setColumnVisibility","rowSelection","setRowSelection","useReactTable","getCoreRowModel","getPaginationRowModel","getSortedRowModel","getFilteredRowModel","headerGroup","header","flexRender","_a","row","cell","OccurrencesTable","occurrenceData","setScriptureReference","referenceHeaderText","occurrenceHeaderText","occurrences","uniqueOccurrences","occurrence","uniqueOccurrence","deepEqual","Checkbox","CheckboxPrimitive","getLinesFromUSFM","text","getNumberFromUSFM","regex","match","getBookNumFromId","getStatusForItem","item","approvedItems","unapprovedItems","toggleVariants","Toggle","TogglePrimitive","ToggleGroupContext","ToggleGroup","ToggleGroupPrimitive","ToggleGroupItem","context","getSortingIcon","sortDirection","ArrowUpIcon","ArrowDownIcon","ArrowUpDownIcon","inventoryItemColumn","itemLabel","inventoryAdditionalItemColumn","additionalItemLabel","additionalItemIndex","inventoryCountColumn","countLabel","statusChangeHandler","changedItems","newStatus","onApprovedItemsChange","onUnapprovedItemsChange","newApprovedItems","validItem","newUnapprovedItems","unapprovedItem","inventoryStatusColumn","statusLabel","status","CircleCheckIcon","CircleXIcon","CircleHelpIcon","INVENTORY_STRING_KEYS","filterItemData","itemData","statusFilter","textFilter","filteredItemData","createTableData","scriptureRef","itemRegex","tableData","currentBook","currentChapter","currentVerse","line","items","itemIndex","existingItem","tableEntry","newReference","substring","newItem","Inventory","scriptureReference","extractItems","additionalItemsLabels","scope","onScopeChange","allItemsText","approvedItemsText","unapprovedItemsText","unknownItemsText","scopeBookText","scopeChapterText","scopeVerseText","filterText","showAdditionalItemsText","showAdditionalItems","setShowAdditionalItems","setStatusFilter","setTextFilter","selectedItem","setSelectedItem","reducedTableData","newTableData","firstItem","existingEntry","newTableEntry","filteredTableData","allColumns","numberOfAdditionalItems","additionalColumns","_b","rowClickHandler","newSelection","handleScopeChange","handleStatusFilterChange","SearchBar","onSearch","placeholder","isFullWidth","handleInputChange","VerticalTabs","TabsPrimitive","VerticalTabsList","VerticalTabsTrigger","VerticalTabsContent","TabNavigationContentSearch","tabList","searchPlaceholder","headerTitle","isSearchBarFullWidth","direction","tab","Separator","orientation","decorative","SeparatorPrimitive","Sheet","SheetPrimitive","SheetPortal","SheetOverlay","sheetVariants","SheetContent","side","SheetTitle","SheetDescription","Skeleton","TooltipProvider","TooltipPrimitive","Tooltip","TooltipTrigger","TooltipContent","MOBILE_BREAKPOINT","useIsMobile","isMobile","setIsMobile","mql","SIDEBAR_COOKIE_NAME","SIDEBAR_COOKIE_MAX_AGE","SIDEBAR_WIDTH","SIDEBAR_WIDTH_MOBILE","SIDEBAR_WIDTH_ICON","SIDEBAR_KEYBOARD_SHORTCUT","SidebarContext","useSidebar","SidebarProvider","defaultOpen","openProp","setOpenProp","style","openMobile","setOpenMobile","_open","_setOpen","isOpen","openState","toggleSidebar","state","contextValue","Sidebar","collapsible","SidebarTrigger","onClick","PanelLeft","SidebarRail","SidebarInset","SidebarInput","SidebarHeader","SidebarFooter","SidebarSeparator","SidebarContent","SidebarGroup","SidebarGroupLabel","SidebarGroupAction","SidebarGroupContent","SidebarMenu","SidebarMenuItem","sidebarMenuButtonVariants","SidebarMenuButton","isActive","tooltip","Comp","button","SidebarMenuAction","showOnHover","SidebarMenuBadge","SidebarMenuSkeleton","showIcon","width","SidebarMenuSub","SidebarMenuSubItem","SidebarMenuSubButton","SettingsSidebar","extensionLabels","projectOptions","handleSelectSidebarItem","selectedSidebarItem","extensionsSidebarGroupLabel","projectsSidebarGroupLabel","handleSelectItem","projectId","getProjectNameFromProjectId","project","getIsActive","label","selectedProjectName","SettingsSidebarContentSearch","scrBookColId","scrRefColId","typeColId","detailsColId","defaultScrRefColumnName","defaultScrBookGroupName","defaultTypeColumnName","defaultDetailsColumnName","getColumns","colInfo","showSourceColumn","showSrcCol","info","formatScrRef","compareScrRefs","toRefOrRange","scriptureSelection","offsetStart","offsetEnd","scrRefToBBBCCCVVV","getRowKey","ScriptureResultsViewer","sources","showColumnHeaders","scriptureReferenceColumnName","scriptureBookGroupName","typeColumnName","detailsColumnName","onRowSelected","grouping","setGrouping","scriptureResults","source","getExpandedRowModel","getGroupedRowModel","selectedRows","keys","selectedRow","scrBookGroupName","typeGroupName","groupingOptions","handleSelectChange","selectedGrouping","handleRowClick","getEvenOrOddBandingStyle","getIndent","groupingState","rowIndex","ChevronLeft","DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS","getLocalizeKeyForScrollGroupId","ScrollGroupSelector","availableScrollGroupIds","scrollGroupId","onChangeScrollGroupId","localizedStringsDefaulted","localizedStringKey","localizedStringValue","newScrollGroupString","scrollGroupOptionId","SettingsList","SettingsListItem","primary","secondary","isLoading","loadingMessage","SettingsListHeader","includeSeparator","Checklist","listItems","selectedListItems","handleSelectListItem","createLabel","_interopRequireDefault","obj","module","chainPropTypes","propType1","propType2","args","_extends","target","isPlainObject","prototype","deepClone","output","deepmerge","r","t","z","reactIs_production_min","hasSymbol","REACT_ELEMENT_TYPE","REACT_PORTAL_TYPE","REACT_FRAGMENT_TYPE","REACT_STRICT_MODE_TYPE","REACT_PROFILER_TYPE","REACT_PROVIDER_TYPE","REACT_CONTEXT_TYPE","REACT_ASYNC_MODE_TYPE","REACT_CONCURRENT_MODE_TYPE","REACT_FORWARD_REF_TYPE","REACT_SUSPENSE_TYPE","REACT_SUSPENSE_LIST_TYPE","REACT_MEMO_TYPE","REACT_LAZY_TYPE","REACT_BLOCK_TYPE","REACT_FUNDAMENTAL_TYPE","REACT_RESPONDER_TYPE","REACT_SCOPE_TYPE","isValidElementType","typeOf","object","$$typeof","$$typeofType","AsyncMode","ConcurrentMode","ContextConsumer","ContextProvider","Element","ForwardRef","Lazy","Memo","Portal","Profiler","StrictMode","Suspense","hasWarnedAboutDeprecatedIsAsyncMode","isAsyncMode","isConcurrentMode","isContextConsumer","isContextProvider","isElement","isForwardRef","isFragment","isLazy","isMemo","isPortal","isProfiler","isStrictMode","isSuspense","reactIs_development","reactIsModule","require$$0","require$$1","getOwnPropertySymbols","hasOwnProperty","propIsEnumerable","toObject","val","shouldUseNative","test1","test2","order2","test3","letter","objectAssign","from","to","symbols","ReactPropTypesSecret","ReactPropTypesSecret_1","has","printWarning","loggedTypeFailures","message","checkPropTypes","typeSpecs","values","location","componentName","getStack","typeSpecName","error","err","ex","stack","checkPropTypes_1","ReactIs","assign","require$$2","require$$3","require$$4","emptyFunctionThatReturnsNull","factoryWithTypeCheckers","isValidElement","throwOnDirectAccess","ITERATOR_SYMBOL","FAUX_ITERATOR_SYMBOL","getIteratorFn","maybeIterable","iteratorFn","ANONYMOUS","ReactPropTypes","createPrimitiveTypeChecker","createAnyTypeChecker","createArrayOfTypeChecker","createElementTypeChecker","createElementTypeTypeChecker","createInstanceTypeChecker","createNodeChecker","createObjectOfTypeChecker","createEnumTypeChecker","createUnionTypeChecker","createShapeTypeChecker","createStrictShapeTypeChecker","is","PropTypeError","createChainableTypeChecker","validate","manualPropTypeCallCache","manualPropTypeWarningCount","checkType","isRequired","propName","propFullName","secret","cacheKey","chainedCheckType","expectedType","propValue","propType","getPropType","preciseType","getPreciseType","typeChecker","expectedClass","expectedClassName","actualClassName","getClassName","expectedValues","valuesString","arrayOfTypeCheckers","checker","getPostfixForTypeWarning","expectedTypes","checkerResult","expectedTypesMessage","isNode","invalidValidatorError","shapeTypes","allKeys","iterator","step","entry","isSymbol","emptyFunction","emptyFunctionWithReset","factoryWithThrowingShims","shim","getShim","propTypesModule","isClassComponent","elementType","acceptingRef","safePropName","warningHint","elementAcceptingRef","PropTypes","elementAcceptingRef$1","specialProperty","exactProp","propTypes","unsupportedProps","prop","formatMuiErrorMessage","code","url","REACT_SERVER_CONTEXT_TYPE","REACT_OFFSCREEN_TYPE","enableScopeAPI","enableCacheElement","enableTransitionTracing","enableLegacyHidden","enableDebugTracing","REACT_MODULE_REFERENCE","SuspenseList","hasWarnedAboutDeprecatedIsConcurrentMode","isSuspenseList","fnNameMatchRegex","getFunctionName","fn","getFunctionComponentName","Component","fallback","getWrappedName","outerType","innerType","wrapperName","functionName","getDisplayName","HTMLElementType","refType","refType$1","capitalize","string","_formatMuiErrorMessage","createChainedFunction","funcs","acc","func","debounce","wait","timeout","debounced","later","deprecatedPropType","validator","reason","componentNameSafe","propFullNameSafe","isMuiElement","muiNames","_muiName","_element$type","ownerDocument","node","ownerWindow","requirePropFactory","componentNameInError","prevPropTypes","requiredProp","defaultTypeChecker","typeCheckerResult","setRef","useEnhancedEffect","useEnhancedEffect$1","globalId","useGlobalId","idOverride","defaultId","setDefaultId","maybeReactUseId","useId","reactId","unsupportedProp","useControlled","controlled","defaultProp","name","isControlled","valueState","setValue","defaultValue","setValueIfUncontrolled","newValue","useEventCallback","useForkRef","refs","instance","UNINITIALIZED","useLazyRef","init","initArg","EMPTY","useOnMount","Timeout","delay","useTimeout","hadKeyboardEvent","hadFocusVisibleRecently","hadFocusVisibleRecentlyTimeout","inputTypesWhitelist","focusTriggersKeyboardModality","tagName","handlePointerDown","handleVisibilityChange","prepare","doc","isFocusVisible","useIsFocusVisible","isFocusVisibleRef","handleBlurVisible","handleFocusVisible","resolveProps","defaultProps","defaultSlotProps","slotProps","slotPropName","composeClasses","slots","getUtilityClass","classes","slot","utilityClass","defaultGenerator","createClassNameGenerator","generate","generator","ClassNameGenerator","ClassNameGenerator$1","globalStateClasses","generateUtilityClass","globalStatePrefix","globalStateClass","generateUtilityClasses","result","clamp","min","max","_objectWithoutPropertiesLoose","excluded","sourceKeys","_excluded","sortBreakpointsValues","breakpointsAsArray","breakpoint1","breakpoint2","createBreakpoints","breakpoints","unit","other","sortedValues","up","down","between","start","end","endIndex","only","not","keyIndex","shape","shape$1","responsivePropType","responsivePropType$1","merge","defaultBreakpoints","handleBreakpoints","styleFromPropValue","theme","themeBreakpoints","breakpoint","mediaKey","cssKey","createEmptyBreakpointObject","breakpointsInput","_breakpointsInput$key","breakpointStyleKey","removeUnusedBreakpoints","breakpointKeys","breakpointOutput","getPath","path","checkVars","getStyleValue","themeMapping","transform","propValueFinal","userValue","cssProperty","themeKey","memoize","cache","arg","properties","directions","aliases","getCssProperties","property","marginKeys","paddingKeys","spacingKeys","createUnaryUnit","_getPath","themeSpacing","abs","createUnarySpacing","getValue","transformer","transformed","getStyleFromPropValue","cssProperties","resolveCssProperty","margin","padding","createSpacing","spacingInput","spacing","argsInput","argument","compose","styles","handlers","borderTransform","createBorderStyle","border","borderTop","borderRight","borderBottom","borderLeft","borderColor","borderTopColor","borderRightColor","borderBottomColor","borderLeftColor","outline","outlineColor","borderRadius","gap","columnGap","rowGap","gridColumn","gridRow","gridAutoFlow","gridAutoColumns","gridAutoRows","gridTemplateColumns","gridTemplateRows","gridTemplateAreas","gridArea","paletteTransform","color","bgcolor","backgroundColor","sizingTransform","maxWidth","_props$theme","_props$theme2","breakpointsValues","minWidth","height","maxHeight","minHeight","boxSizing","defaultSxConfig","defaultSxConfig$1","objectsHaveSameKeys","objects","union","callIfFn","maybeFn","unstable_createStyleFunctionSx","getThemeValue","config","styleFunctionSx","_theme$unstable_sxCon","sx","traverse","sxInput","sxObject","emptyBreakpoints","breakpointsKeys","css","styleKey","styleFunctionSx$1","applyStyles","createTheme","paletteInput","shapeInput","muiTheme","isObjectEmpty","useTheme","defaultTheme","contextTheme","ThemeContext","systemDefaultTheme","useThemeWithoutDefault","_excluded2","_excluded3","isEmpty","isStringTag","tag","shouldForwardProp","lowercaseFirstLetter","resolveTheme","themeId","defaultOverridesResolver","processStyleArg","callableStyle","_ref","ownerState","resolvedStylesArg","resolvedStyle","variants","isMatch","createStyled","input","rootShouldForwardProp","slotShouldForwardProp","systemSx","inputOptions","processStyles","componentSlot","inputSkipVariantsResolver","inputSkipSx","overridesResolver","skipVariantsResolver","skipSx","shouldForwardPropOption","defaultStyledResolver","styledEngineStyled","transformStyleArg","stylesArg","muiStyledResolver","styleArg","expressions","transformedStyleArg","expressionsWithDefaultTheme","styleOverrides","resolvedStyleOverrides","slotKey","slotStyle","_theme$components","themeVariants","numOfCustomFnsApplied","placeholders","displayName","getThemeProps","params","useThemeProps","clampWrapper","hexToRgb","re","colors","decomposeColor","marker","colorSpace","recomposeColor","hslToRgb","rgb","getLuminance","getContrastRatio","foreground","background","lumA","lumB","alpha","darken","coefficient","lighten","createMixins","mixins","common","common$1","grey","grey$1","purple","purple$1","red","red$1","orange","orange$1","blue","blue$1","lightBlue","lightBlue$1","green","green$1","light","dark","addLightOrDark","intent","shade","tonalOffset","tonalOffsetLight","tonalOffsetDark","getDefaultPrimary","mode","getDefaultSecondary","getDefaultError","getDefaultInfo","getDefaultSuccess","getDefaultWarning","createPalette","palette","contrastThreshold","success","warning","getContrastText","contrastText","contrast","augmentColor","mainShade","lightShade","darkShade","modes","round","caseAllCaps","defaultFontFamily","createTypography","typography","fontFamily","fontSize","fontWeightLight","fontWeightRegular","fontWeightMedium","fontWeightBold","htmlFontSize","allVariants","pxToRem2","coef","pxToRem","buildVariant","fontWeight","lineHeight","letterSpacing","casing","shadowKeyUmbraOpacity","shadowKeyPenumbraOpacity","shadowAmbientShadowOpacity","createShadow","px","shadows","shadows$1","easing","duration","formatMs","milliseconds","getAutoHeightDuration","constant","createTransitions","inputTransitions","mergedEasing","mergedDuration","durationOption","easingOption","isString","isNumber","animatedProp","zIndex","zIndex$1","mixinsInput","transitionsInput","typographyInput","systemTheme","systemCreateTheme","stateClasses","component","child","stateClass","defaultTheme$1","THEME_ID","systemUseThemeProps","styled","styled$1","getSvgIconUtilityClass","useUtilityClasses","SvgIconRoot","_theme$transitions","_theme$transitions$cr","_theme$transitions2","_theme$typography","_theme$typography$pxT","_theme$typography2","_theme$typography2$px","_theme$typography3","_theme$typography3$px","_palette$ownerState$c","_palette","_palette2","_palette3","SvgIcon","inProps","htmlColor","inheritViewBox","titleAccess","viewBox","hasSvgAsChild","more","_jsxs","_jsx","SvgIcon$1","createSvgIcon","unstable_ClassNameGenerator","exports","_utils","ArrowRight","default_1","_createSvgIcon","_jsxRuntime","isHostComponent","appendOwnerState","otherProps","defaultContextValue","ClassNameConfiguratorContext","useClassNamesOverride","disableDefaultClasses","extractEventHandlers","excludeKeys","resolveComponentProps","componentProps","slotState","omitEventHandlers","mergeSlotProps","parameters","getSlotProps","additionalProps","externalSlotProps","externalForwardedProps","joinedClasses","mergedStyle","eventHandlers","componentsPropsWithoutEventHandlers","otherPropsWithoutEventHandlers","internalSlotProps","useSlotProps","_parameters$additiona","skipResolvingSlotProps","rest","resolvedComponentsProps","mergedProps","internalRef","GLOBAL_CLASS_PREFIX","buildStateClass","buildSlotClass","getContainer","container","forwardedRef","disablePortal","mountNode","setMountNode","handleRef","newProps","ReactDOM","top","bottom","right","left","auto","basePlacements","clippingParents","viewport","popper","reference","variationPlacements","placement","placements","beforeRead","read","afterRead","beforeMain","main","afterMain","beforeWrite","write","afterWrite","modifierPhases","getNodeName","getWindow","OwnElement","isHTMLElement","isShadowRoot","attributes","effect","_ref2","initialStyles","styleProperties","attribute","applyStyles$1","getBasePlacement","getUAString","uaData","isLayoutViewport","getBoundingClientRect","includeScale","isFixedStrategy","clientRect","scaleX","scaleY","visualViewport","addVisualOffsets","getLayoutRect","contains","parent","rootNode","next","getComputedStyle","isTableElement","getDocumentElement","getParentNode","getTrueOffsetParent","getContainingBlock","isFirefox","isIE","elementCss","currentNode","getOffsetParent","window","offsetParent","getMainAxisFromPlacement","within","mathMax","mathMin","withinMaxClamp","getFreshSideObject","mergePaddingObject","paddingObject","expandToHashMap","hashMap","toPaddingObject","arrow","_state$modifiersData$","arrowElement","popperOffsets","basePlacement","axis","isVertical","len","arrowRect","minProp","maxProp","endDiff","startDiff","arrowOffsetParent","clientSize","centerToReference","center","offset","axisProp","_options$element","arrow$1","getVariation","unsetSides","roundOffsetsByDPR","win","dpr","mapToStyles","_Object$assign2","popperRect","variation","offsets","gpuAcceleration","adaptive","roundOffsets","isFixed","_offsets$x","_offsets$y","_ref3","hasX","hasY","sideX","sideY","heightProp","widthProp","offsetY","offsetX","commonStyles","_ref4","_Object$assign","computeStyles","_ref5","_options$gpuAccelerat","_options$adaptive","_options$roundOffsets","computeStyles$1","passive","_options$scroll","scroll","_options$resize","resize","scrollParents","scrollParent","eventListeners","hash","getOppositePlacement","matched","getOppositeVariationPlacement","getWindowScroll","scrollLeft","scrollTop","getWindowScrollBarX","getViewportRect","strategy","html","layoutViewport","getDocumentRect","_element$ownerDocumen","winScroll","body","isScrollParent","_getComputedStyle","overflow","overflowX","overflowY","getScrollParent","listScrollParents","list","isBody","updatedList","rectToClientRect","rect","getInnerBoundingClientRect","getClientRectFromMixedType","clippingParent","getClippingParents","canEscapeClipping","clipperElement","getClippingRect","boundary","rootBoundary","mainClippingParents","firstClippingParent","clippingRect","accRect","computeOffsets","commonX","commonY","mainAxis","detectOverflow","_options","_options$placement","_options$strategy","_options$boundary","_options$rootBoundary","_options$elementConte","elementContext","_options$altBoundary","altBoundary","_options$padding","altContext","clippingClientRect","referenceClientRect","popperClientRect","elementClientRect","overflowOffsets","offsetData","multiply","computeAutoPlacement","flipVariations","_options$allowedAutoP","allowedAutoPlacements","allPlacements","allowedPlacements","overflows","getExpandedFallbackPlacements","oppositePlacement","flip","_options$mainAxis","checkMainAxis","_options$altAxis","checkAltAxis","specifiedFallbackPlacements","_options$flipVariatio","preferredPlacement","isBasePlacement","fallbackPlacements","referenceRect","checksMap","makeFallbackChecks","firstFittingPlacement","_basePlacement","isStartVariation","mainVariationSide","altVariationSide","checks","check","numberOfChecks","_loop","_i","fittingPlacement","_ret","flip$1","getSideOffsets","preventedOffsets","isAnySideFullyClipped","hide","referenceOverflow","popperAltOverflow","referenceClippingOffsets","popperEscapeOffsets","isReferenceHidden","hasPopperEscaped","hide$1","distanceAndSkiddingToXY","rects","invertDistance","skidding","distance","_options$offset","_data$state$placement","offset$1","popperOffsets$1","getAltAxis","preventOverflow","_options$tether","tether","_options$tetherOffset","tetherOffset","altAxis","tetherOffsetValue","normalizedTetherOffsetValue","offsetModifierState","_offsetModifierState$","mainSide","altSide","additive","minLen","maxLen","arrowPaddingObject","arrowPaddingMin","arrowPaddingMax","arrowLen","minOffset","maxOffset","clientOffset","offsetModifierValue","tetherMin","tetherMax","preventedOffset","_offsetModifierState$2","_mainSide","_altSide","_offset","_len","_min","_max","isOriginSide","_offsetModifierValue","_tetherMin","_tetherMax","_preventedOffset","preventOverflow$1","getHTMLElementScroll","getNodeScroll","isElementScaled","getCompositeRect","elementOrVirtualElement","isOffsetParentAnElement","offsetParentIsScaled","documentElement","order","modifiers","map","visited","modifier","sort","requires","dep","depModifier","orderModifiers","orderedModifiers","phase","pending","resolve","mergeByName","merged","current","existing","DEFAULT_OPTIONS","areValidElements","_key","popperGenerator","generatorOptions","_generatorOptions","_generatorOptions$def","defaultModifiers","_generatorOptions$def2","defaultOptions","effectCleanupFns","isDestroyed","setOptionsAction","cleanupModifierEffects","runModifierEffects","_state$elements","_state$orderedModifie","_state$orderedModifie2","_ref$options","cleanupFn","noopFn","createPopper","COMPONENT_NAME","getPopperUtilityClass","flipPlacement","resolveAnchorEl","anchorEl","isVirtualElement","defaultPopperOptions","PopperTooltip","_slots$root","initialPlacement","popperOptions","popperRefProp","TransitionProps","tooltipRef","ownRef","popperRef","handlePopperRef","handlePopperRefRef","rtlPlacement","setPlacement","resolvedAnchorElement","setResolvedAnchorElement","handlePopperUpdate","box","popperModifiers","childProps","Root","rootProps","Popper","containerProp","keepMounted","transition","exited","setExited","handleEnter","handleExited","resolvedAnchorEl","display","transitionProps","useThemeSystem","_setPrototypeOf","_inheritsLoose","subClass","superClass","setPrototypeOf","timeoutsShape","TransitionGroupContext","forceReflow","UNMOUNTED","EXITED","ENTERING","ENTERED","EXITING","Transition","_React$Component","_this","parentGroup","appear","initialStatus","prevState","nextIn","_proto","prevProps","nextStatus","exit","enter","mounting","_this2","appearing","maybeNode","maybeAppearing","timeouts","enterTimeout","_this3","nextState","callback","_this4","active","handler","doesNotHaveTimeoutOrListener","maybeNextCallback","_this$props","pt","noop","Transition$1","reflow","getTransitionProps","_style$transitionDura","_style$transitionTimi","getScale","isWebKit154","Grow","addEndListener","inProp","onEnter","onEntered","onEntering","onExit","onExited","onExiting","TransitionComponent","timer","autoTimeout","nodeRef","normalizedTransitionCallback","maybeIsAppearing","handleEntering","isAppearing","transitionDuration","transitionTimingFunction","handleEntered","handleExiting","handleExit","Grow$1","PopperRoot","BasePopper","components","componentsProps","RootComponent","Popper$1","getTooltipUtilityClass","tooltipClasses","tooltipClasses$1","disableInteractive","touch","TooltipPopper","TooltipTooltip","TooltipArrow","hystersisOpen","hystersisTimer","cursorPosition","composeEventHandler","eventHandler","_slots$popper","_slots$transition","_slots$tooltip","_slots$arrow","_slotProps$popper","_ref6","_slotProps$popper2","_slotProps$transition","_slotProps$tooltip","_ref7","_slotProps$tooltip2","_slotProps$arrow","_ref8","_slotProps$arrow2","childrenProp","describeChild","disableFocusListener","disableHoverListener","disableInteractiveProp","disableTouchListener","enterDelay","enterNextDelay","enterTouchDelay","followCursor","idProp","leaveDelay","leaveTouchDelay","onClose","onOpen","PopperComponentProp","PopperProps","title","TransitionComponentProp","isRtl","childNode","setChildNode","arrowRef","setArrowRef","ignoreNonTouchEvents","closeTimer","enterTimer","leaveTimer","touchTimer","setOpenState","prevUserSelect","stopTouchInteraction","handleOpen","handleClose","handleLeave","focusVisibleRef","setChildIsFocusVisible","handleBlur","handleFocus","detectTouchStart","childrenProps","handleMouseOver","handleMouseLeave","handleTouchStart","handleTouchEnd","nativeEvent","handleMouseMove","nameOrDescProps","titleIsString","interactiveWrapperListeners","_PopperProps$popperOp","tooltipModifiers","PopperComponent","TooltipComponent","ArrowComponent","popperProps","tooltipProps","tooltipArrowProps","TransitionPropsInner","Tooltip$1","getIcon","icon","menuLabel","leading","MuiListItemIcon","MenuItem","allowForLeadingIcons","iconPathBefore","iconPathAfter","hasAutoFocus","isDense","isSubMenuParent","hasDisabledGutters","hasDivider","focusVisibleClassName","menuItem","MuiMenuItem","MuiListItemText","getAllGroups","menuDefinition","SubMenu","setAnchorEl","parentMenuItem","parentItemProps","handleParentMenuItemClick","renderSubMenuItems","includedGroups","group","GroupedMenuItemList","Menu","getOrderedGroupItems","groupId","allItems","menuProps","commandHandler","groupsToInclude","sortedGroups","itemArray","allowSpaceForLeadingIcons","createMenuItemProps","isLastItemInGroup","divKey","itemInfo","menuItemProps","TopLevelMenu","columnId","MenuColumn","metadata","Grid","List","GridMenu","multiColumnMenu","sortedColumns","columnNumbers","columnName","col","getUsePromiseOptionsDefaults","usePromise","promiseFactoryCallback","defaultValueRef","optionsDefaultedRef","setIsLoading","promiseIsCurrent","MenuIcon","HamburgerMenuButton","menuProvider","normalMenu","fullMenu","containerRef","ariaLabelPrefix","isMenuOpen","setMenuOpen","showFullMenu","setShowFullMenu","handleMenuItemClick","handleMenuButtonClick","prevIsOpen","isOpening","menuCommandHandler","command","setOffset","normalMenuData","fullMenuData","menu","IconButton","Drawer","isTooltipSuppressed","adjustMarginToAlignToEdge","MuiIconButton","Spinner","LoaderCircle","TextField","hasError","helperText","onFocus","onBlur","ShadLabel","Toolbar","AppBar","MuiToolbar","alertVariants","Alert","AlertTitle","AlertDescription","Card","CardHeader","CardTitle","CardDescription","CardContent","CardFooter","Sonner","Toaster","Slider","SliderPrimitive","Switch","SwitchPrimitives","Tabs","TabsList","TabsTrigger","TabsContent","InstallButton","isInstalling","handleClick","buttonText","Download","EnableButton","isEnabling","DisableButton","isDisabling","UpdateButton","isUpdating","MarkdownRenderer","markdown","anchorTarget","Markdown","FilterButton","Filter","DropdownMenuItemType","DropdownMenuItemType2","FilterDropdown","groups","NoExtensionsFound","MoreInfo","category","downloads","languages","moreInfoUrl","numberFormatted","NumberFormat","handleScrollToBottom","User","locale","LucideLink","CircleHelp","VersionHistory","versionHistory","showAllVersions","setShowAllVersions","currentDate","formatTimeString","dateString","date","dateDiff","yearDiff","monthDiff","dayDiff","timeString","sortedEntries","Footer","publisherDisplayName","fileSize","locales","formattedFileSize","formatBytes","languageNames","codes","displayNames","useEvent","unsubscriber","noopUnsubscriber","useEventAsync","unsubscribe","unsub"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAGA,MAAMA,KAAgBC,GAAoB,EAAE,QAAQ,MAAO,CAAA;AAyDpD,SAASC,KAAMC,GAAsB;AACnC,SAAAH,GAAcI,GAAKD,CAAM,CAAC;AACnC;ACzDO,MAAME,KAAQC,EAAM;AAAA,EACzB,CAAC,EAAE,WAAAC,GAAW,MAAAC,GAAM,GAAGC,EAAA,GAASC,MAE5B,gBAAAC;AAAA,IAAC;AAAA,IAAA;AAAA,MACC,MAAAH;AAAA,MACA,WAAWN;AAAA,QACT;AAAA,QACAK;AAAA,MACF;AAAA,MACA,KAAAG;AAAA,MAEC,GAAGD;AAAA,IAAA;AAAA,EAAA;AAIZ;AACAJ,GAAM,cAAc;ACNpB,MAAMO,KAAmBC;AAAA,EACvB,CACE,EAAE,cAAAC,GAAc,eAAAC,GAAe,eAAAC,GAAe,cAAAC,GAAc,GAAGR,EAAM,GACrEC,MAGE,gBAAAQ,EAAC,OAAI,EAAA,WAAU,eACb,UAAA;AAAA,IAAA,gBAAAP;AAAA,MAACQ;AAAAA,MAAA;AAAA,QACE,GAAGV;AAAA,QACJ,MAAK;AAAA,QACL,WAAU;AAAA,QACV,UAAU,CAACW,MAAUN,EAAaM,EAAM,OAAO,KAAK;AAAA,QACpD,WAAW,CAACC,MAAM;AACZ,UAAAA,EAAE,QAAQ,WACCJ,KAEfF,EAAcM,CAAC;AAAA,QACjB;AAAA,QACA,SAASL;AAAA,QACT,KAAAN;AAAA,MAAA;AAAA,IACF;AAAA,IACA,gBAAAC;AAAA,MAACW;AAAA,MAAA;AAAA,QACC,WAAU;AAAA,QACV,SAAS,MAAM;AAEb,kBAAQ,IAAI,iBAAiB;AAAA,QAC/B;AAAA,MAAA;AAAA,IACF;AAAA,EACF,EAAA,CAAA;AAGN;AC9CA,IAAIC,KAAI,OAAO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;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","x_google_ignoreList":[3,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,83,84,85,86,87,88,89,90,91,92,93,94,95,96,97,98,99,100,101,102,103,104,105,106,107,108,109,110,111,112,113,114,115,116,117,118,119,120,121,122,123,124,125,126,127,128,129,130,131,132,133,134,135,136,137,138,139,140,141,142,143,144,145,146,147,148,149,150,151,152,153,154,155,156,157,158,159,160,161,162,163,164,165,166,167,168,169,170,171,172,173,174,175,176,177,178,179,180,181,182,183,184,185,186,187,188,189,190,191,192,193,194,195,196,197,198,199,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,228]} \ No newline at end of file diff --git a/lib/platform-bible-react/src/components/advanced/settings-components/settings-sidebar-content-search.component.tsx b/lib/platform-bible-react/src/components/advanced/settings-components/settings-sidebar-content-search.component.tsx index 2f3da42869..237eae2eae 100644 --- a/lib/platform-bible-react/src/components/advanced/settings-components/settings-sidebar-content-search.component.tsx +++ b/lib/platform-bible-react/src/components/advanced/settings-components/settings-sidebar-content-search.component.tsx @@ -24,6 +24,8 @@ export default function SettingsSidebarContentSearch({ handleSelectSidebarItem, selectedSidebarItem, onSearch, + extensionsSidebarGroupLabel, + projectsSidebarGroupLabel, }: SettingsSidebarContentSearchProps) { return (
    @@ -40,6 +42,8 @@ export default function SettingsSidebarContentSearch({ projectOptions={projectOptions} handleSelectSidebarItem={handleSelectSidebarItem} selectedSidebarItem={selectedSidebarItem} + extensionsSidebarGroupLabel={extensionsSidebarGroupLabel} + projectsSidebarGroupLabel={projectsSidebarGroupLabel} /> {children} diff --git a/lib/platform-bible-react/src/components/advanced/settings-components/settings-sidebar.component.tsx b/lib/platform-bible-react/src/components/advanced/settings-components/settings-sidebar.component.tsx index 1652119d9e..2747ad1eb7 100644 --- a/lib/platform-bible-react/src/components/advanced/settings-components/settings-sidebar.component.tsx +++ b/lib/platform-bible-react/src/components/advanced/settings-components/settings-sidebar.component.tsx @@ -34,6 +34,12 @@ export type SettingsSidebarProps = { /** The current selected value in the sidebar */ selectedSidebarItem: SelectedSettingsSidebarItem; + + /** Label for the group of extensions setting groups */ + extensionsSidebarGroupLabel: string; + + /** Label for the group of projects settings */ + projectsSidebarGroupLabel: string; }; export default function SettingsSidebar({ @@ -42,6 +48,8 @@ export default function SettingsSidebar({ projectOptions, handleSelectSidebarItem, selectedSidebarItem, + extensionsSidebarGroupLabel, + projectsSidebarGroupLabel, }: SettingsSidebarProps) { const handleSelectItem = useCallback( (item: string, projectId?: string) => { @@ -72,7 +80,9 @@ export default function SettingsSidebar({ > - Extensions + + {extensionsSidebarGroupLabel} + {extensionLabels.map((label) => ( @@ -93,7 +103,9 @@ export default function SettingsSidebar({ - Projects + + {projectsSidebarGroupLabel} + Paratext column > Settings', group: 'platform.misc', order: 1, - command: 'platform.openUserSettings', + command: 'platform.openSettings', }, { label: 'Reload Extensions', diff --git a/src/renderer/components/settings-tabs/settings-components/setting.component.tsx b/src/renderer/components/settings-tabs/settings-components/setting.component.tsx index 51e0889039..353a27089b 100644 --- a/src/renderer/components/settings-tabs/settings-components/setting.component.tsx +++ b/src/renderer/components/settings-tabs/settings-components/setting.component.tsx @@ -6,7 +6,7 @@ import { SettingTypes, } from 'papi-shared-types'; import { Input, Label, Switch } from 'platform-bible-react'; -import { debounce, getErrorMessage } from 'platform-bible-utils'; +import { debounce, getErrorMessage, LocalizeKey } from 'platform-bible-utils'; import { DataProviderUpdateInstructions } from '@shared/models/data-provider.model'; import { SettingDataTypes } from '@shared/services/settings.service-model'; import logger from '@shared/services/logger.service'; @@ -92,6 +92,14 @@ type CombinedSettingProps = (settingKey: any, newValue: any, currentValue: any) => Promise >; +const LOCALIZE_SETTING_KEYS: LocalizeKey[] = [ + '%settings_defaultMessage_loadingOneSetting%', + '%settings_defaultMessage_noSettingComponent%', + '%settings_errorMessages_invalidNumber%', + '%settings_errorMessages_invalidJSON%', + '%settings_errorMessages_invalidValue%', +]; + /** * Renders a setting component based on the type of setting (string, number, boolean, or object) and * includes validating the setting and displaying errors @@ -109,6 +117,8 @@ export default function Setting({ const [errorMessage, setErrorMessage] = useState(undefined); + const [localizedStrings] = useLocalizedStrings(useMemo(() => LOCALIZE_SETTING_KEYS, [])); + /** * Validate and change a setting * @@ -132,7 +142,7 @@ export default function Setting({ if (typeof setting === 'number') { const numericValue = parseInt(value, 10); if (Number.isNaN(numericValue)) { - setErrorMessage('Invalid number'); + setErrorMessage(localizedStrings['%settings_errorMessages_invalidNumber%']); return; } newValue = numericValue; @@ -142,7 +152,7 @@ export default function Setting({ try { newValue = JSON.parse(value); } catch { - setErrorMessage('Invalid JSON'); + setErrorMessage(localizedStrings['%settings_errorMessages_invalidJSON%']); return; } } else { @@ -155,7 +165,7 @@ export default function Setting({ setErrorMessage(undefined); if (setSetting) setSetting(newValue); } else { - setErrorMessage('Invalid value'); + setErrorMessage(localizedStrings['%settings_errorMessages_invalidValue%']); } } catch (error) { setErrorMessage(getErrorMessage(error)); @@ -165,7 +175,7 @@ export default function Setting({ const debouncedHandleChange = debounce(handleChangeSetting, 500); const generateComponent = useCallback(() => { - let component =

    No setting component

    ; // isLoading ?

    Loading setting

    : + let component =

    {localizedStrings['%settings_defaultMessage_noSettingComponent%']}

    ; if (typeof setting === 'string' || typeof setting === 'number') component = ( @@ -190,16 +200,14 @@ export default function Setting({ {errorMessage && }
    ); - }, [setting, settingKey, debouncedHandleChange, errorMessage]); - - const loadingSettingKey = '%settings_defaultMessage_loadingSetting%'; - const [localizedStrings] = useLocalizedStrings(useMemo(() => [loadingSettingKey], [])); - const localizedLoadingSetting = localizedStrings[loadingSettingKey]; + }, [localizedStrings, setting, settingKey, debouncedHandleChange, errorMessage]); return (
    {isLoading ? ( - + ) : (
    ); } if (isLoadingSettingsContributions || isLoadingProjectSettingsContributions) - return
    Loading Settings
    ; + return ( +
    + {localizedStrings['%settings_defaultMessage_loadingSettings%']} +
    + ); if (!settingsContributions) return
    No Settings
    ; @@ -198,6 +189,8 @@ export default function SettingsTab({ projectIdToLimitSettings }: SettingsTabPro } selectedSidebarItem={selectedSidebarItem} onSearch={handleSearchInput} + extensionsSidebarGroupLabel={localizedStrings['%settings_sidebar_extensionsLabel%']} + projectsSidebarGroupLabel={localizedStrings['%settings_sidebar_projectsLabel%']} >
    {selectedSidebarItem.projectId @@ -225,7 +218,9 @@ export const loadSettingsTab = (savedTabInfo: SavedTabInfo): TabInfo => { // eslint-disable-next-line no-type-assertion/no-type-assertion const tabData: SettingsTabData = savedTabInfo.data as SettingsTabData; - const title = tabData.projectIdToLimitSettings ? 'Project Settings' : 'Settings'; + const title = tabData.projectIdToLimitSettings + ? '%settings_title_projectSettings%' + : '%settings_title%'; return { ...savedTabInfo, From 082477c4b5c9065516203c2ecc07a98cc9bcbcb0 Mon Sep 17 00:00:00 2001 From: Jolie Rabideau Date: Tue, 26 Nov 2024 16:57:36 -0500 Subject: [PATCH 07/18] Fix sidebar content scrolling, add missing localized strings --- assets/localization/en.json | 1 + .../src/hello-world/contributions/menus.json | 6 + lib/platform-bible-react/dist/index.cjs | 94 +- lib/platform-bible-react/dist/index.cjs.map | 2 +- lib/platform-bible-react/dist/index.d.ts | 6 +- lib/platform-bible-react/dist/index.js | 1267 +++++++++-------- lib/platform-bible-react/dist/index.js.map | 2 +- ...tings-sidebar-content-search.component.tsx | 12 +- .../settings-sidebar.component.tsx | 6 +- src/extension-host/data/menu.data.json | 2 +- .../settings-tabs/settings-tab.component.scss | 4 +- .../settings-tabs/settings-tab.component.tsx | 8 +- 12 files changed, 722 insertions(+), 688 deletions(-) diff --git a/assets/localization/en.json b/assets/localization/en.json index 06fe9f5b75..2f2469f32e 100644 --- a/assets/localization/en.json +++ b/assets/localization/en.json @@ -59,6 +59,7 @@ "%settings_errorMessages_invalidJSON%": "Invalid JSON", "%settings_errorMessages_invalidValue%": "Invalid value", "%settings_sidebar_extensionsLabel%": "Extensions", + "%settings_sidebar_projectsComboBoxPlaceholder%": "Type or select project", "%settings_sidebar_projectsLabel%": "Projects", "%settings_title_projectSettings%": "Project Settings", "%settings_title%": "Settings", diff --git a/extensions/src/hello-world/contributions/menus.json b/extensions/src/hello-world/contributions/menus.json index b72d3794a9..2e7495003f 100644 --- a/extensions/src/hello-world/contributions/menus.json +++ b/extensions/src/hello-world/contributions/menus.json @@ -83,6 +83,12 @@ "group": "helloWorld.viewGroup", "order": 1, "command": "helloWorld.openViewerByWebViewId" + }, + { + "label": "%webView_openProjectSettings%", + "group": "helloWorld.projectGroup", + "order": 3, + "command": "platform.openSettings" } ] } diff --git a/lib/platform-bible-react/dist/index.cjs b/lib/platform-bible-react/dist/index.cjs index 2221a01654..210d6a85b9 100644 --- a/lib/platform-bible-react/dist/index.cjs +++ b/lib/platform-bible-react/dist/index.cjs @@ -1,23 +1,23 @@ -"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const a=require("react/jsx-runtime"),g=require("react"),Q=require("lucide-react"),ot=require("clsx"),ml=require("tailwind-merge"),Za=require("@radix-ui/react-dropdown-menu"),W=require("platform-bible-utils"),Ht=require("@radix-ui/react-slot"),Xt=require("class-variance-authority"),hl=require("@radix-ui/react-label"),gl=require("@radix-ui/react-radio-group"),bl=require("@radix-ui/react-popover"),Re=require("cmdk"),vl=require("@radix-ui/react-dialog"),Se=require("@tanstack/react-table"),xl=require("@radix-ui/react-select"),yl=require("@radix-ui/react-checkbox"),Nl=require("@radix-ui/react-toggle-group"),kl=require("@radix-ui/react-toggle"),Sl=require("@radix-ui/react-tabs"),El=require("@radix-ui/react-separator"),jl=require("@radix-ui/react-tooltip"),Gr=require("@mui/styled-engine"),Me=require("@mui/material"),ln=require("react-dom"),Qa=require("sonner"),Cl=require("@radix-ui/react-slider"),Tl=require("@radix-ui/react-switch"),Rl=require("markdown-to-jsx");function ke(e){const t=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(e){for(const n in e)if(n!=="default"){const r=Object.getOwnPropertyDescriptor(e,n);Object.defineProperty(t,n,r.get?r:{enumerable:!0,get:()=>e[n]})}}return t.default=e,Object.freeze(t)}const M=ke(g),pe=ke(Za),es=ke(hl),bn=ke(gl),vn=ke(bl),be=ke(vl),ge=ke(xl),Ur=ke(yl),rr=ke(Nl),ts=ke(kl),Oe=ke(Sl),ns=ke(El),Sn=ke(jl),Ol=ke(ln),cn=ke(Cl),qr=ke(Tl);const _l=ml.extendTailwindMerge({prefix:"tw-"});function N(...e){return _l(ot.clsx(e))}const St=g.forwardRef(({className:e,type:t,...n},r)=>a.jsx("input",{type:t,className:N("pr-twp tw-flex tw-h-10 tw-rounded-md tw-border tw-border-input tw-bg-background tw-px-3 tw-py-2 tw-text-sm tw-ring-offset-background file:tw-border-0 file:tw-bg-transparent file:tw-text-sm file:tw-font-medium file:tw-text-foreground placeholder:tw-text-muted-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-cursor-not-allowed disabled:tw-opacity-50",e),ref:r,...n}));St.displayName="Input";const Pl=g.forwardRef(({handleSearch:e,handleKeyDown:t,handleOnClick:n,handleSubmit:r,...o},s)=>a.jsxs("div",{className:"tw-relative",children:[a.jsx(St,{...o,type:"text",className:"tw-box-border tw-gap-2.5 tw-rounded-lg tw-border tw-border-solid tw-bg-background tw-py-2 tw-pl-4 tw-pr-3 tw-font-medium tw-shadow-none tw-outline-none",onChange:i=>e(i.target.value),onKeyDown:i=>{i.key==="Enter"&&r(),t(i)},onClick:n,ref:s}),a.jsx(Q.History,{className:"tw-absolute tw-right-3 tw-top-1/2 tw-h-4 tw-w-4 tw--translate-y-1/2 tw-transform tw-cursor-pointer tw-text-muted-foreground",onClick:()=>{console.log("back in history")}})]}));var Il=Object.defineProperty,Ml=(e,t,n)=>t in e?Il(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,ne=(e,t,n)=>Ml(e,typeof t!="symbol"?t+"":t,n);const gt=["GEN","EXO","LEV","NUM","DEU","JOS","JDG","RUT","1SA","2SA","1KI","2KI","1CH","2CH","EZR","NEH","EST","JOB","PSA","PRO","ECC","SNG","ISA","JER","LAM","EZK","DAN","HOS","JOL","AMO","OBA","JON","MIC","NAM","HAB","ZEP","HAG","ZEC","MAL","MAT","MRK","LUK","JHN","ACT","ROM","1CO","2CO","GAL","EPH","PHP","COL","1TH","2TH","1TI","2TI","TIT","PHM","HEB","JAS","1PE","2PE","1JN","2JN","3JN","JUD","REV","TOB","JDT","ESG","WIS","SIR","BAR","LJE","S3Y","SUS","BEL","1MA","2MA","3MA","4MA","1ES","2ES","MAN","PS2","ODA","PSS","JSA","JDB","TBS","SST","DNT","BLT","XXA","XXB","XXC","XXD","XXE","XXF","XXG","FRT","BAK","OTH","3ES","EZA","5EZ","6EZ","INT","CNC","GLO","TDX","NDX","DAG","PS3","2BA","LBA","JUB","ENO","1MQ","2MQ","3MQ","REP","4BA","LAO"],ao=["XXA","XXB","XXC","XXD","XXE","XXF","XXG","FRT","BAK","OTH","INT","CNC","GLO","TDX","NDX"],rs=["Genesis","Exodus","Leviticus","Numbers","Deuteronomy","Joshua","Judges","Ruth","1 Samuel","2 Samuel","1 Kings","2 Kings","1 Chronicles","2 Chronicles","Ezra","Nehemiah","Esther (Hebrew)","Job","Psalms","Proverbs","Ecclesiastes","Song of Songs","Isaiah","Jeremiah","Lamentations","Ezekiel","Daniel (Hebrew)","Hosea","Joel","Amos","Obadiah","Jonah","Micah","Nahum","Habakkuk","Zephaniah","Haggai","Zechariah","Malachi","Matthew","Mark","Luke","John","Acts","Romans","1 Corinthians","2 Corinthians","Galatians","Ephesians","Philippians","Colossians","1 Thessalonians","2 Thessalonians","1 Timothy","2 Timothy","Titus","Philemon","Hebrews","James","1 Peter","2 Peter","1 John","2 John","3 John","Jude","Revelation","Tobit","Judith","Esther Greek","Wisdom of Solomon","Sirach (Ecclesiasticus)","Baruch","Letter of Jeremiah","Song of 3 Young Men","Susanna","Bel and the Dragon","1 Maccabees","2 Maccabees","3 Maccabees","4 Maccabees","1 Esdras (Greek)","2 Esdras (Latin)","Prayer of Manasseh","Psalm 151","Odes","Psalms of Solomon","Joshua A. *obsolete*","Judges B. *obsolete*","Tobit S. *obsolete*","Susanna Th. *obsolete*","Daniel Th. *obsolete*","Bel Th. *obsolete*","Extra A","Extra B","Extra C","Extra D","Extra E","Extra F","Extra G","Front Matter","Back Matter","Other Matter","3 Ezra *obsolete*","Apocalypse of Ezra","5 Ezra (Latin Prologue)","6 Ezra (Latin Epilogue)","Introduction","Concordance ","Glossary ","Topical Index","Names Index","Daniel Greek","Psalms 152-155","2 Baruch (Apocalypse)","Letter of Baruch","Jubilees","Enoch","1 Meqabyan","2 Meqabyan","3 Meqabyan","Reproof (Proverbs 25-31)","4 Baruch (Rest of Baruch)","Laodiceans"],ra=Ul();function Yt(e,t=!0){return t&&(e=e.toUpperCase()),e in ra?ra[e]:0}function so(e){return Yt(e)>0}function $l(e){const t=typeof e=="string"?Yt(e):e;return t>=40&&t<=66}function Dl(e){return(typeof e=="string"?Yt(e):e)<=39}function os(e){return e<=66}function Al(e){const t=typeof e=="string"?Yt(e):e;return is(t)&&!os(t)}function*Bl(){for(let e=1;e<=gt.length;e++)yield e}const Vl=1,as=gt.length;function zl(){return["XXA","XXB","XXC","XXD","XXE","XXF","XXG"]}function io(e,t="***"){const n=e-1;return n<0||n>=gt.length?t:gt[n]}function ss(e){return e<=0||e>as?"******":rs[e-1]}function Ll(e){return ss(Yt(e))}function is(e){const t=typeof e=="number"?io(e):e;return so(t)&&!ao.includes(t)}function Fl(e){const t=typeof e=="number"?io(e):e;return so(t)&&ao.includes(t)}function Gl(e){return rs[e-1].includes("*obsolete*")}function Ul(){const e={};for(let t=0;t(e[e.Unknown=0]="Unknown",e[e.Original=1]="Original",e[e.Septuagint=2]="Septuagint",e[e.Vulgate=3]="Vulgate",e[e.English=4]="English",e[e.RussianProtestant=5]="RussianProtestant",e[e.RussianOrthodox=6]="RussianOrthodox",e))(He||{});const Pe=class{constructor(t){if(ne(this,"name"),ne(this,"fullPath"),ne(this,"isPresent"),ne(this,"hasVerseSegments"),ne(this,"isCustomized"),ne(this,"baseVersification"),ne(this,"scriptureBooks"),ne(this,"_type"),t==null)throw new Error("Argument undefined");typeof t=="string"?(this.name=t,this._type=He[t]):(this._type=t,this.name=He[t])}get type(){return this._type}equals(t){return!t.type||!this.type?!1:t.type===this.type}};ne(Pe,"Original",new Pe(He.Original)),ne(Pe,"Septuagint",new Pe(He.Septuagint)),ne(Pe,"Vulgate",new Pe(He.Vulgate)),ne(Pe,"English",new Pe(He.English)),ne(Pe,"RussianProtestant",new Pe(He.RussianProtestant)),ne(Pe,"RussianOrthodox",new Pe(He.RussianOrthodox));let ut=Pe;function oa(e,t){const n=t[0];for(let r=1;r(e[e.Valid=0]="Valid",e[e.UnknownVersification=1]="UnknownVersification",e[e.OutOfRange=2]="OutOfRange",e[e.VerseOutOfOrder=3]="VerseOutOfOrder",e[e.VerseRepeated=4]="VerseRepeated",e))(ls||{});const je=class re{constructor(t,n,r,o){if(ne(this,"firstChapter"),ne(this,"lastChapter"),ne(this,"lastVerse"),ne(this,"hasSegmentsDefined"),ne(this,"text"),ne(this,"BBBCCCVVVS"),ne(this,"longHashCode"),ne(this,"versification"),ne(this,"rtlMark","‏"),ne(this,"_bookNum",0),ne(this,"_chapterNum",0),ne(this,"_verseNum",0),ne(this,"_verse"),r==null&&o==null)if(t!=null&&typeof t=="string"){const s=t,i=n!=null&&n instanceof ut?n:void 0;this.setEmpty(i),this.parse(s)}else if(t!=null&&typeof t=="number"){const s=n!=null&&n instanceof ut?n:void 0;this.setEmpty(s),this._verseNum=t%re.chapterDigitShifter,this._chapterNum=Math.floor(t%re.bookDigitShifter/re.chapterDigitShifter),this._bookNum=Math.floor(t/re.bookDigitShifter)}else if(n==null)if(t!=null&&t instanceof re){const s=t;this._bookNum=s.bookNum,this._chapterNum=s.chapterNum,this._verseNum=s.verseNum,this._verse=s.verse,this.versification=s.versification}else{if(t==null)return;const s=t instanceof ut?t:re.defaultVersification;this.setEmpty(s)}else throw new Error("VerseRef constructor not supported.");else if(t!=null&&n!=null&&r!=null)if(typeof t=="string"&&typeof n=="string"&&typeof r=="string")this.setEmpty(o),this.updateInternal(t,n,r);else if(typeof t=="number"&&typeof n=="number"&&typeof r=="number")this._bookNum=t,this._chapterNum=n,this._verseNum=r,this.versification=o??re.defaultVersification;else throw new Error("VerseRef constructor not supported.");else throw new Error("VerseRef constructor not supported.")}static isVerseParseable(t){return t.length>0&&"0123456789".includes(t[0])&&!t.endsWith(this.verseRangeSeparator)&&!t.endsWith(this.verseSequenceIndicator)}static tryParse(t){let n;try{return n=new re(t),{success:!0,verseRef:n}}catch(r){if(r instanceof nn)return n=new re,{success:!1,verseRef:n};throw r}}static getBBBCCCVVV(t,n,r){return t%re.bcvMaxValue*re.bookDigitShifter+(n>=0?n%re.bcvMaxValue*re.chapterDigitShifter:0)+(r>=0?r%re.bcvMaxValue:0)}static fromJSON(t){const{book:n,chapterNum:r,verseNum:o,verse:s,versificationStr:i}=t,l=s||o.toString();let c;return i&&(c=new ut(i)),n?new re(n,r.toString(),l,c):new re}static tryGetVerseNum(t){let n;if(!t)return n=-1,{success:!0,vNum:n};n=0;let r;for(let o=0;o"9")return o===0&&(n=-1),{success:!1,vNum:n};if(n=n*10+ +r-0,n>re.bcvMaxValue)return n=-1,{success:!1,vNum:n}}return{success:!0,vNum:n}}get isDefault(){return this.bookNum===0&&this.chapterNum===0&&this.verseNum===0&&this.versification==null}get hasMultiple(){return this._verse!=null&&(this._verse.includes(re.verseRangeSeparator)||this._verse.includes(re.verseSequenceIndicator))}get book(){return ae.bookNumberToId(this.bookNum,"")}set book(t){this.bookNum=ae.bookIdToNumber(t)}get chapter(){return this.isDefault||this._chapterNum<0?"":this._chapterNum.toString()}set chapter(t){const n=+t;this._chapterNum=Number.isInteger(n)?n:-1}get verse(){return this._verse!=null?this._verse:this.isDefault||this._verseNum<0?"":this._verseNum.toString()}set verse(t){const{success:n,vNum:r}=re.tryGetVerseNum(t);this._verse=n?void 0:t.replace(this.rtlMark,""),this._verseNum=r,!(this._verseNum>=0)&&({vNum:this._verseNum}=re.tryGetVerseNum(this._verse))}get bookNum(){return this._bookNum}set bookNum(t){if(t<=0||t>ae.lastBook)throw new nn("BookNum must be greater than zero and less than or equal to last book");this._bookNum=t}get chapterNum(){return this._chapterNum}set chapterNum(t){this.chapterNum=t}get verseNum(){return this._verseNum}set verseNum(t){this._verseNum=t}get versificationStr(){var t;return(t=this.versification)==null?void 0:t.name}set versificationStr(t){this.versification=this.versification!=null?new ut(t):void 0}get valid(){return this.validStatus===0}get validStatus(){return this.validateVerse(re.verseRangeSeparators,re.verseSequenceIndicators)}get BBBCCC(){return re.getBBBCCCVVV(this._bookNum,this._chapterNum,0)}get BBBCCCVVV(){return re.getBBBCCCVVV(this._bookNum,this._chapterNum,this._verseNum)}get isExcluded(){return!1}parse(t){if(t=t.replace(this.rtlMark,""),t.includes("/")){const s=t.split("/");if(t=s[0],s.length>1)try{const i=+s[1].trim();this.versification=new ut(He[i])}catch{throw new nn("Invalid reference : "+t)}}const n=t.trim().split(" ");if(n.length!==2)throw new nn("Invalid reference : "+t);const r=n[1].split(":"),o=+r[0];if(r.length!==2||ae.bookIdToNumber(n[0])===0||!Number.isInteger(o)||o<0||!re.isVerseParseable(r[1]))throw new nn("Invalid reference : "+t);this.updateInternal(n[0],r[0],r[1])}simplify(){this._verse=void 0}clone(){return new re(this)}toString(){const t=this.book;return t===""?"":`${t} ${this.chapter}:${this.verse}`}toJSON(){let t=this.verse;(t===""||t===this.verseNum.toString())&&(t=void 0);const n={book:this.book,chapterNum:this.chapterNum,verseNum:this.verseNum,verse:t,versificationStr:this.versificationStr};return t||delete n.verse,n}equals(t){return t instanceof re?t._bookNum===this._bookNum&&t._chapterNum===this._chapterNum&&t._verseNum===this._verseNum&&t.verse===this.verse&&(t.versification==null&&this.versification==null||t.versification!=null&&this.versification!=null&&t.versification.equals(this.versification)):!1}allVerses(t=!1,n=re.verseRangeSeparators,r=re.verseSequenceIndicators){if(this._verse==null||this.chapterNum<=0)return[this.clone()];const o=[],s=oa(this._verse,r);for(const i of s.map(l=>oa(l,n))){const l=this.clone();l.verse=i[0];const c=l.verseNum;if(o.push(l),i.length>1){const u=this.clone();if(u.verse=i[1],!t)for(let d=c+1;di)return 3;if(r===i)return 4;r=i}return 0}get internalValid(){return this.versification==null?1:this._bookNum<=0||this._bookNum>ae.lastBook?2:(ae.isCanonical(this._bookNum),0)}setEmpty(t=re.defaultVersification){this._bookNum=0,this._chapterNum=-1,this._verse=void 0,this.versification=t}updateInternal(t,n,r){this.bookNum=ae.bookIdToNumber(t),this.chapter=n,this.verse=r}};ne(je,"defaultVersification",ut.English),ne(je,"verseRangeSeparator","-"),ne(je,"verseSequenceIndicator",","),ne(je,"verseRangeSeparators",[je.verseRangeSeparator]),ne(je,"verseSequenceIndicators",[je.verseSequenceIndicator]),ne(je,"chapterDigitShifter",1e3),ne(je,"bookDigitShifter",je.chapterDigitShifter*je.chapterDigitShifter),ne(je,"bcvMaxValue",je.chapterDigitShifter-1),ne(je,"ValidStatusType",ls);class nn extends Error{}const or=pe.Root,lo=pe.Trigger,cs=pe.Group,ql=pe.Portal,Hl=pe.Sub,Xl=pe.RadioGroup,ds=g.forwardRef(({className:e,inset:t,children:n,...r},o)=>a.jsxs(pe.SubTrigger,{ref:o,className:N("tw-flex tw-cursor-default tw-select-none tw-items-center tw-rounded-sm tw-px-2 tw-py-1.5 tw-text-sm tw-outline-none focus:tw-bg-accent data-[state=open]:tw-bg-accent",t&&"tw-pl-8",e),...r,children:[n,a.jsx(Q.ChevronRight,{className:"tw-ml-auto tw-h-4 tw-w-4"})]}));ds.displayName=pe.SubTrigger.displayName;const us=g.forwardRef(({className:e,...t},n)=>a.jsx(pe.SubContent,{ref:n,className:N("tw-z-50 tw-min-w-[8rem] tw-overflow-hidden tw-rounded-md tw-border tw-bg-popover tw-p-1 tw-text-popover-foreground tw-shadow-lg data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0 data-[state=closed]:tw-zoom-out-95 data-[state=open]:tw-zoom-in-95 data-[side=bottom]:tw-slide-in-from-top-2 data-[side=left]:tw-slide-in-from-right-2 data-[side=right]:tw-slide-in-from-left-2 data-[side=top]:tw-slide-in-from-bottom-2",e),...t}));us.displayName=pe.SubContent.displayName;const En=g.forwardRef(({className:e,sideOffset:t=4,...n},r)=>a.jsx(pe.Portal,{children:a.jsx(pe.Content,{ref:r,sideOffset:t,className:N("pr-twp tw-z-50 tw-min-w-[8rem] tw-overflow-hidden tw-rounded-md tw-border tw-bg-popover tw-p-1 tw-text-popover-foreground tw-shadow-md data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0 data-[state=closed]:tw-zoom-out-95 data-[state=open]:tw-zoom-in-95 data-[side=bottom]:tw-slide-in-from-top-2 data-[side=left]:tw-slide-in-from-right-2 data-[side=right]:tw-slide-in-from-left-2 data-[side=top]:tw-slide-in-from-bottom-2",e),...n})}));En.displayName=pe.Content.displayName;const co=g.forwardRef(({className:e,inset:t,...n},r)=>a.jsx(pe.Item,{ref:r,className:N("tw-cursor-default tw-select-none tw-items-center tw-rounded-sm tw-px-2 tw-py-1.5 tw-text-sm tw-outline-none tw-transition-colors focus:tw-bg-accent data-[disabled]:tw-pointer-events-none data-[disabled]:tw-opacity-50",t&&"tw-pl-8",e),...n}));co.displayName=pe.Item.displayName;const ar=g.forwardRef(({className:e,children:t,checked:n,...r},o)=>a.jsxs(pe.CheckboxItem,{ref:o,className:N("tw-relative tw-flex tw-cursor-default tw-select-none tw-items-center tw-rounded-sm tw-py-1.5 tw-pl-8 tw-pr-2 tw-text-sm tw-outline-none tw-transition-colors focus:tw-bg-accent focus:tw-text-accent-foreground data-[disabled]:tw-pointer-events-none data-[disabled]:tw-opacity-50",e),checked:n,...r,children:[a.jsx("span",{className:"tw-absolute tw-left-2 tw-flex tw-h-3.5 tw-w-3.5 tw-items-center tw-justify-center",children:a.jsx(pe.ItemIndicator,{children:a.jsx(Q.Check,{className:"tw-h-4 tw-w-4"})})}),t]}));ar.displayName=pe.CheckboxItem.displayName;const uo=g.forwardRef(({className:e,children:t,...n},r)=>a.jsxs(pe.RadioItem,{ref:r,className:N("tw-relative tw-flex tw-cursor-default tw-select-none tw-items-center tw-rounded-sm tw-py-1.5 tw-pl-8 tw-pr-2 tw-text-sm tw-outline-none tw-transition-colors focus:tw-bg-accent focus:tw-text-accent-foreground data-[disabled]:tw-pointer-events-none data-[disabled]:tw-opacity-50",e),...n,children:[a.jsx("span",{className:"tw-absolute tw-left-2 tw-flex tw-h-3.5 tw-w-3.5 tw-items-center tw-justify-center",children:a.jsx(pe.ItemIndicator,{children:a.jsx(Q.Circle,{className:"tw-h-2 tw-w-2 tw-fill-current"})})}),t]}));uo.displayName=pe.RadioItem.displayName;const Wt=g.forwardRef(({className:e,inset:t,...n},r)=>a.jsx(pe.Label,{ref:r,className:N("tw-px-2 tw-py-1.5 tw-text-sm tw-font-semibold",t&&"tw-pl-8",e),...n}));Wt.displayName=pe.Label.displayName;const jn=g.forwardRef(({className:e,...t},n)=>a.jsx(pe.Separator,{ref:n,className:N("tw--mx-1 tw-my-1 tw-h-px tw-bg-muted",e),...t}));jn.displayName=pe.Separator.displayName;function ps({className:e,...t}){return a.jsx("span",{className:N("tw-ml-auto tw-text-xs tw-tracking-widest tw-opacity-60",e),...t})}ps.displayName="DropdownMenuShortcut";const Yl=g.forwardRef(({bookId:e,handleSelectBook:t,isSelected:n,handleHighlightBook:r,handleKeyDown:o,bookType:s,children:i},l)=>a.jsxs(co,{ref:l,textValue:e,className:N("tw-mx-1 tw-px-1 tw-font-normal tw-text-foreground/80",{"tw-bg-amber-50 tw-text-yellow-900 data-[highlighted]:tw-bg-amber-100":n}),onSelect:c=>{c.preventDefault(),t()},onKeyDown:c=>{o(c)},onFocus:r,onMouseMove:r,children:[a.jsx("span",{className:N("tw-border-b-0 tw-border-l-2 tw-border-r-0 tw-border-t-0 tw-border-solid tw-px-2",{"tw-font-bold":n,"tw-border-l-red-200":s.toLowerCase()==="ot","tw-border-l-purple-200":s.toLowerCase()==="nt","tw-border-l-indigo-200":s.toLowerCase()==="dc"}),children:ae.bookIdToEnglishName(e)}),n&&a.jsx("div",{children:i})]},e));function Wl({handleSelectChapter:e,endChapter:t,activeChapter:n,highlightedChapter:r,handleHighlightedChapter:o}){const s=Array.from({length:t},(l,c)=>c+1),i=g.useCallback(l=>{o(l)},[o]);return a.jsx("div",{className:N("tw-flex tw-flex-wrap tw-items-start tw-justify-start tw-self-stretch"),children:s.map(l=>a.jsx("div",{className:N("tw-box-content tw-flex tw-h-4 tw-w-4 tw-cursor-pointer tw-items-center tw-justify-end tw-rounded-md tw-p-2 tw-text-amber-800",{"tw-font-semibold tw-text-amber-900":l===n,"tw-bg-amber-200":l===r}),onClick:c=>{c.preventDefault(),c.stopPropagation(),e(l)},role:"button",onKeyDown:c=>{c.key==="Enter"&&e(l)},tabIndex:0,onMouseMove:()=>i(l),children:l},l))})}function Kl({handleSort:e,handleLocationHistory:t,handleBookmarks:n}){return a.jsxs(Wt,{className:"tw-flex tw-justify-between",children:[a.jsx("p",{className:"tw-inline-block tw-align-middle",children:"Go To"}),a.jsxs("div",{className:"tw-flex tw-items-center",children:[a.jsx(Q.ArrowDownWideNarrow,{onClick:e,className:"tw-m-2 tw-h-4 tw-w-4 tw-cursor-pointer tw-gap-2"}),a.jsx(Q.Clock,{onClick:t,className:"tw-m-2 tw-h-4 tw-w-4 tw-cursor-pointer tw-gap-2"}),a.jsx(Q.Bookmark,{onClick:n,className:"tw-m-2 tw-h-4 tw-w-4 tw-cursor-pointer tw-gap-2"})]})]})}const wn=ae.allBookIds,Jl={OT:"Old Testament",NT:"New Testament",DC:"Deuterocanon"},aa=["OT","NT","DC"],Zl=32+32+32,Ql=[/^(\w+)$/i,/^(\w+)(?:\s(\d+))$/i,/^(\w+)(?:\s(\d+):(\d+))$/i],ec=e=>({OT:wn.filter(n=>ae.isBookOT(n)),NT:wn.filter(n=>ae.isBookNT(n)),DC:wn.filter(n=>ae.isBookDC(n))})[e],rn=e=>W.getChaptersForBook(ae.bookIdToNumber(e));function tc(){return wn.map(t=>ae.bookIdToEnglishName(t))}function nc(e){return tc().includes(e)}function rc(e){const t=e.toLowerCase().replace(/^\w/,n=>n.toUpperCase());if(nc(t))return wn.find(r=>ae.bookIdToEnglishName(r)===t)}function oc({scrRef:e,handleSubmit:t}){const[n,r]=g.useState(""),[o,s]=g.useState(ae.bookNumberToId(e.bookNum)),[i,l]=g.useState(e.chapterNum??0),[c,u]=g.useState(ae.bookNumberToId(e.bookNum)),[d,m]=g.useState(!1),[w,b]=g.useState(d),x=g.useRef(void 0),f=g.useRef(void 0),h=g.useRef(void 0),S=g.useCallback(k=>ec(k).filter(D=>{const $=ae.bookIdToEnglishName(D).toLowerCase(),J=n.replace(/[^a-zA-Z]/g,"").toLowerCase();return $.includes(J)||D.toLowerCase().includes(J)}),[n]),R=k=>{r(k)},j=g.useRef(!1),E=g.useCallback(k=>{if(j.current){j.current=!1;return}m(k)},[]),v=g.useCallback((k,D,$,J)=>{if(l(ae.bookNumberToId(e.bookNum)!==k?1:e.chapterNum),D||rn(k)===-1){t({bookNum:ae.bookIdToNumber(k),chapterNum:$||1,verseNum:J||1}),m(!1),r("");return}s(o!==k?k:""),m(!D)},[t,e.bookNum,e.chapterNum,o]),P=k=>{k<=0||k>rn(o)||v(o,!0,k)},V=g.useCallback(()=>{Ql.forEach(k=>{const D=n.match(k);if(D){const[$,J=void 0,Y=void 0]=D.slice(1),F=rc($);(ae.isBookIdValid($)||F)&&v(F??$,!0,J?parseInt(J,10):1,Y?parseInt(Y,10):1)}})},[v,n]),U=g.useCallback(k=>{d?(k.key==="ArrowDown"||k.key==="ArrowUp")&&(typeof h<"u"&&h.current!==null?h.current.focus():typeof f<"u"&&f.current!==null&&f.current.focus(),k.preventDefault()):m(!0)},[d]),C=k=>{const{key:D}=k;D==="ArrowRight"||D==="ArrowLeft"||D==="ArrowDown"||D==="ArrowUp"||D==="Enter"||(x.current.dispatchEvent(new KeyboardEvent("keydown",{key:D})),x.current.focus())},_=k=>{const{key:D}=k;if(c===o){if(D==="Enter"){k.preventDefault(),v(o,!0,i);return}let $=0;if(D==="ArrowRight")if(i1)$=-1;else{k.preventDefault();return}else D==="ArrowDown"?$=6:D==="ArrowUp"&&($=-6);i+$<=0||i+$>rn(c)?l(0):$!==0&&(l(i+$),k.preventDefault())}};return g.useEffect(()=>{o===c?o===ae.bookNumberToId(e.bookNum)?l(e.chapterNum):l(1):l(0)},[c,e.bookNum,e.chapterNum,o]),g.useLayoutEffect(()=>{b(d)},[d]),g.useLayoutEffect(()=>{const k=setTimeout(()=>{if(w&&f.current&&h.current){const $=h.current.offsetTop-Zl;f.current.scrollTo({top:$,behavior:"instant"})}},10);return()=>{clearTimeout(k)}},[w]),a.jsx("div",{className:"pr-twp tw-flex",children:a.jsxs(or,{modal:!1,open:d,onOpenChange:E,children:[a.jsx(lo,{asChild:!0,children:a.jsx(Pl,{ref:x,value:n,handleSearch:R,handleKeyDown:U,handleOnClick:()=>{s(ae.bookNumberToId(e.bookNum)),u(ae.bookNumberToId(e.bookNum)),l(e.chapterNum>0?e.chapterNum:0),m(!0),x.current.focus()},onFocus:()=>{j.current=!0},handleSubmit:V,placeholder:`${ae.bookNumberToEnglishName(e.bookNum)} ${e.chapterNum}:${e.verseNum}`})}),a.jsxs(En,{className:"tw-m-1 tw-overflow-y-auto tw-p-0 tw-font-normal tw-text-foreground/80",style:{width:"233px",maxHeight:"500px",zIndex:"250"},onKeyDown:C,align:"start",ref:f,children:[a.jsx(Kl,{handleSort:()=>console.log("sorting"),handleLocationHistory:()=>console.log("location history"),handleBookmarks:()=>console.log("bookmarks")}),aa.map((k,D)=>S(k).length>0&&a.jsxs("div",{children:[a.jsx(Wt,{className:"tw-font-semibold tw-text-foreground/80",children:Jl[k]}),S(k).map($=>a.jsx("div",{children:a.jsx(Yl,{bookId:$,handleSelectBook:()=>v($,!1),isSelected:o===$,handleHighlightBook:()=>u($),handleKeyDown:_,bookType:k,ref:J=>{o===$&&(h.current=J)},children:a.jsx(Wl,{handleSelectChapter:P,endChapter:rn($),activeChapter:e.bookNum===ae.bookIdToNumber($)?e.chapterNum:0,highlightedChapter:i,handleHighlightedChapter:J=>{l(J)}})})},$)),aa.length-1!==D?a.jsx(jn,{}):void 0]},k))]})]})})}const ws=Xt.cva("pr-twp tw-inline-flex tw-items-center tw-justify-center tw-whitespace-nowrap tw-rounded-md tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-colors focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50",{variants:{variant:{default:"tw-bg-primary tw-text-primary-foreground hover:tw-bg-primary/90",destructive:"tw-bg-destructive tw-text-destructive-foreground hover:tw-bg-destructive/90",outline:"tw-border tw-border-input tw-bg-background hover:tw-bg-accent hover:tw-text-accent-foreground",secondary:"tw-bg-secondary tw-text-secondary-foreground hover:tw-bg-secondary/80",ghost:"hover:tw-bg-accent hover:tw-text-accent-foreground",link:"tw-text-primary tw-underline-offset-4 hover:tw-underline"},size:{default:"tw-h-10 tw-px-4 tw-py-2",sm:"tw-h-9 tw-rounded-md tw-px-3",lg:"tw-h-11 tw-rounded-md tw-px-8",icon:"tw-h-10 tw-w-10"}},defaultVariants:{variant:"default",size:"default"}}),fe=g.forwardRef(({className:e,variant:t,size:n,asChild:r=!1,...o},s)=>{const i=r?Ht.Slot:"button";return a.jsx(i,{className:N(ws({variant:t,size:n,className:e})),ref:s,...o})});fe.displayName="Button";const ac=Xt.cva("tw-text-sm tw-font-medium tw-leading-none peer-disabled:tw-cursor-not-allowed peer-disabled:tw-opacity-70"),qe=g.forwardRef(({className:e,...t},n)=>a.jsx(es.Root,{ref:n,className:N("pr-twp",ac(),e),...t}));qe.displayName=es.Root.displayName;const po=g.forwardRef(({className:e,...t},n)=>a.jsx(bn.Root,{className:N("pr-twp tw-grid tw-gap-2",e),...t,ref:n}));po.displayName=bn.Root.displayName;const Yn=g.forwardRef(({className:e,...t},n)=>a.jsx(bn.Item,{ref:n,className:N("pr-twp tw-aspect-square tw-h-4 tw-w-4 tw-rounded-full tw-border tw-border-primary tw-text-primary tw-ring-offset-background focus:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-cursor-not-allowed disabled:tw-opacity-50",e),...t,children:a.jsx(bn.Indicator,{className:"tw-flex tw-items-center tw-justify-center",children:a.jsx(Q.Circle,{className:"tw-h-2.5 tw-w-2.5 tw-fill-current tw-text-current"})})}));Yn.displayName=bn.Item.displayName;const sc=vn.Root,ic=vn.Trigger,fs=g.forwardRef(({className:e,align:t="center",sideOffset:n=4,...r},o)=>a.jsx(vn.Portal,{children:a.jsx(vn.Content,{ref:o,align:t,sideOffset:n,className:N("pr-twp tw-z-50 tw-w-72 tw-rounded-md tw-border tw-bg-popover tw-p-4 tw-text-popover-foreground tw-shadow-md tw-outline-none data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0 data-[state=closed]:tw-zoom-out-95 data-[state=open]:tw-zoom-in-95 data-[side=bottom]:tw-slide-in-from-top-2 data-[side=left]:tw-slide-in-from-right-2 data-[side=right]:tw-slide-in-from-left-2 data-[side=top]:tw-slide-in-from-bottom-2",e),...r})}));fs.displayName=vn.Content.displayName;const lc=be.Portal,ms=g.forwardRef(({className:e,...t},n)=>a.jsx(be.Overlay,{ref:n,className:N("tw-fixed tw-inset-0 tw-z-50 tw-bg-black/80 data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0",e),...t}));ms.displayName=be.Overlay.displayName;const cc=g.forwardRef(({className:e,children:t,...n},r)=>a.jsxs(lc,{children:[a.jsx(ms,{}),a.jsxs(be.Content,{ref:r,className:N("tw-fixed tw-left-[50%] tw-top-[50%] tw-z-50 tw-grid tw-w-full tw-max-w-lg tw-translate-x-[-50%] tw-translate-y-[-50%] tw-gap-4 tw-border tw-bg-background tw-p-6 tw-shadow-lg tw-duration-200 data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0 data-[state=closed]:tw-zoom-out-95 data-[state=open]:tw-zoom-in-95 data-[state=closed]:tw-slide-out-to-left-1/2 data-[state=closed]:tw-slide-out-to-top-[48%] data-[state=open]:tw-slide-in-from-left-1/2 data-[state=open]:tw-slide-in-from-top-[48%] sm:tw-rounded-lg",e),...n,children:[t,a.jsxs(be.Close,{className:"tw-absolute tw-right-4 tw-top-4 tw-rounded-sm tw-opacity-70 tw-ring-offset-background tw-transition-opacity hover:tw-opacity-100 focus:tw-outline-none focus:tw-ring-2 focus:tw-ring-ring focus:tw-ring-offset-2 disabled:tw-pointer-events-none data-[state=open]:tw-bg-accent data-[state=open]:tw-text-muted-foreground",children:[a.jsx(Q.X,{className:"tw-h-4 tw-w-4"}),a.jsx("span",{className:"tw-sr-only",children:"Close"})]})]})]}));cc.displayName=be.Content.displayName;const dc=g.forwardRef(({className:e,...t},n)=>a.jsx(be.Title,{ref:n,className:N("tw-text-lg tw-font-semibold tw-leading-none tw-tracking-tight",e),...t}));dc.displayName=be.Title.displayName;const uc=g.forwardRef(({className:e,...t},n)=>a.jsx(be.Description,{ref:n,className:N("tw-text-sm tw-text-muted-foreground",e),...t}));uc.displayName=be.Description.displayName;const hs=g.forwardRef(({className:e,...t},n)=>a.jsx(Re.Command,{ref:n,className:N("tw-flex tw-h-full tw-w-full tw-flex-col tw-overflow-hidden tw-rounded-md tw-bg-popover tw-text-popover-foreground",e),...t}));hs.displayName=Re.Command.displayName;const gs=g.forwardRef(({className:e,...t},n)=>a.jsxs("div",{className:"tw-flex tw-items-center tw-border-b tw-px-3",children:[a.jsx(Q.Search,{className:"tw-me-2 tw-h-4 tw-w-4 tw-shrink-0 tw-opacity-50"}),a.jsx(Re.Command.Input,{ref:n,className:N("tw-flex tw-h-11 tw-w-full tw-rounded-md tw-bg-transparent tw-py-3 tw-text-sm tw-outline-none placeholder:tw-text-muted-foreground disabled:tw-cursor-not-allowed disabled:tw-opacity-50",e),...t})]}));gs.displayName=Re.Command.Input.displayName;const bs=g.forwardRef(({className:e,...t},n)=>a.jsx(Re.Command.List,{ref:n,className:N("tw-max-h-[300px] tw-overflow-y-auto tw-overflow-x-hidden",e),...t}));bs.displayName=Re.Command.List.displayName;const vs=g.forwardRef((e,t)=>a.jsx(Re.Command.Empty,{ref:t,className:"tw-py-6 tw-text-center tw-text-sm",...e}));vs.displayName=Re.Command.Empty.displayName;const pc=g.forwardRef(({className:e,...t},n)=>a.jsx(Re.Command.Group,{ref:n,className:N("tw-overflow-hidden tw-p-1 tw-text-foreground [&_[cmdk-group-heading]]:tw-px-2 [&_[cmdk-group-heading]]:tw-py-1.5 [&_[cmdk-group-heading]]:tw-text-xs [&_[cmdk-group-heading]]:tw-font-medium [&_[cmdk-group-heading]]:tw-text-muted-foreground",e),...t}));pc.displayName=Re.Command.Group.displayName;const wc=g.forwardRef(({className:e,...t},n)=>a.jsx(Re.Command.Separator,{ref:n,className:N("tw--mx-1 tw-h-px tw-bg-border",e),...t}));wc.displayName=Re.Command.Separator.displayName;const xs=g.forwardRef(({className:e,...t},n)=>a.jsx(Re.Command.Item,{ref:n,className:N("tw-relative tw-flex tw-cursor-default tw-select-none tw-items-center tw-rounded-sm tw-px-2 tw-py-1.5 tw-text-sm tw-outline-none data-[disabled=true]:tw-pointer-events-none data-[selected=true]:tw-bg-accent data-[selected=true]:tw-text-accent-foreground data-[disabled=true]:tw-opacity-50",e),...t}));xs.displayName=Re.Command.Item.displayName;function fc(e){return typeof e=="string"?e:typeof e=="number"?e.toString():e.label}function Wn({id:e,options:t=[],buttonClassName:n,popoverContentClassName:r,value:o,onChange:s=()=>{},getOptionLabel:i=fc,buttonPlaceholder:l="",textPlaceholder:c="",commandEmptyMessage:u="No option found",buttonVariant:d="outline",dir:m="ltr",isDisabled:w=!1,...b}){const[x,f]=g.useState(!1);return a.jsxs(sc,{open:x,onOpenChange:f,...b,children:[a.jsx(ic,{asChild:!0,children:a.jsxs(fe,{variant:d,role:"combobox","aria-expanded":x,id:e,className:N("tw-w-[200px] tw-justify-between",n),disabled:w,children:[a.jsx("span",{className:"tw-overflow-hidden tw-text-ellipsis tw-whitespace-nowrap",children:o?i(o):l}),a.jsx(Q.ChevronsUpDown,{className:"tw-ms-2 tw-h-4 tw-w-4 tw-shrink-0 tw-opacity-50"})]})}),a.jsx(fs,{className:N("tw-w-[200px] tw-p-0",r),dir:m,children:a.jsxs(hs,{children:[a.jsx(gs,{dir:m,placeholder:c,className:"tw-text-inherit"}),a.jsx(vs,{children:u}),a.jsx(bs,{children:t.map(h=>a.jsxs(xs,{value:i(h),onSelect:()=>{s(h),f(!1)},children:[a.jsx(Q.Check,{className:N("tw-me-2 tw-h-4 tw-w-4",{"tw-opacity-0":!o||i(o)!==i(h)})}),i(h)]},i(h)))})]})})]})}function ys({startChapter:e,endChapter:t,handleSelectStartChapter:n,handleSelectEndChapter:r,isDisabled:o=!1,chapterCount:s}){const i=g.useMemo(()=>Array.from({length:s},(u,d)=>d+1),[s]),l=u=>{n(u),u>t&&r(u)},c=u=>{r(u),uu.toString(),value:e},"start chapter"),a.jsx(qe,{htmlFor:"end-chapters-combobox",children:"to"}),a.jsx(Wn,{isDisabled:o,onChange:c,buttonClassName:"tw-ml-2 tw-w-20",options:i,getOptionLabel:u=>u.toString(),value:t},"end chapter")]})}var Ns=(e=>(e.CURRENT_BOOK="current book",e.CHOOSE_BOOKS="choose books",e))(Ns||{});const mc=Object.freeze(["%webView_bookSelector_currentBook%","%webView_bookSelector_choose%","%webView_bookSelector_chooseBooks%"]),Tr=(e,t)=>e[t]??t;function hc({handleBookSelectionModeChange:e,currentBookName:t,onSelectBooks:n,selectedBookIds:r,chapterCount:o,endChapter:s,handleSelectEndChapter:i,startChapter:l,handleSelectStartChapter:c,localizedStrings:u}){const d=Tr(u,"%webView_bookSelector_currentBook%"),m=Tr(u,"%webView_bookSelector_choose%"),w=Tr(u,"%webView_bookSelector_chooseBooks%"),[b,x]=g.useState("current book"),f=h=>{x(h),e(h)};return a.jsx(po,{className:"pr-twp tw-flex",value:b,onValueChange:h=>f(h),children:a.jsxs("div",{className:"tw-flex tw-w-full tw-flex-col tw-gap-4",children:[a.jsxs("div",{className:"tw-grid tw-grid-cols-[25%,25%,50%]",children:[a.jsxs("div",{className:"tw-flex tw-items-center",children:[a.jsx(Yn,{value:"current book"}),a.jsx(qe,{className:"tw-ml-1",children:d})]}),a.jsx(qe,{className:"tw-flex tw-items-center",children:t}),a.jsx("div",{className:"tw-flex tw-items-center tw-justify-end",children:a.jsx(ys,{isDisabled:b==="choose books",handleSelectStartChapter:c,handleSelectEndChapter:i,chapterCount:o,startChapter:l,endChapter:s})})]}),a.jsxs("div",{className:"tw-grid tw-grid-cols-[25%,50%,25%]",children:[a.jsxs("div",{className:"tw-flex tw-items-center",children:[a.jsx(Yn,{value:"choose books"}),a.jsx(qe,{className:"tw-ml-1",children:w})]}),a.jsx(qe,{className:"tw-flex tw-items-center",children:r.map(h=>ae.bookIdToEnglishName(h)).join(", ")}),a.jsx(fe,{disabled:b==="current book",onClick:()=>n(),children:m})]})]})})}function gc({table:e}){return a.jsxs(or,{children:[a.jsx(Za.DropdownMenuTrigger,{asChild:!0,children:a.jsxs(fe,{variant:"outline",size:"sm",className:"tw-ml-auto tw-hidden tw-h-8 lg:tw-flex",children:[a.jsx(Q.FilterIcon,{className:"tw-mr-2 tw-h-4 tw-w-4"}),"View"]})}),a.jsxs(En,{align:"end",className:"tw-w-[150px]",children:[a.jsx(Wt,{children:"Toggle columns"}),a.jsx(jn,{}),e.getAllColumns().filter(t=>t.getCanHide()).map(t=>a.jsx(ar,{className:"tw-capitalize",checked:t.getIsVisible(),onCheckedChange:n=>t.toggleVisibility(!!n),children:t.id},t.id))]})]})}const At=ge.Root,ks=ge.Group,Bt=ge.Value,bt=g.forwardRef(({className:e,children:t,...n},r)=>a.jsxs(ge.Trigger,{ref:r,className:N("tw-flex tw-h-10 tw-w-full tw-items-center tw-justify-between tw-rounded-md tw-border tw-border-input tw-bg-background tw-px-3 tw-py-2 tw-text-sm tw-ring-offset-background placeholder:tw-text-muted-foreground focus:tw-outline-none focus:tw-ring-2 focus:tw-ring-ring focus:tw-ring-offset-2 disabled:tw-cursor-not-allowed disabled:tw-opacity-50 [&>span]:tw-line-clamp-1",e),...n,children:[t,a.jsx(ge.Icon,{asChild:!0,children:a.jsx(Q.ChevronDown,{className:"tw-h-4 tw-w-4 tw-opacity-50"})})]}));bt.displayName=ge.Trigger.displayName;const wo=g.forwardRef(({className:e,...t},n)=>a.jsx(ge.ScrollUpButton,{ref:n,className:N("tw-flex tw-cursor-default tw-items-center tw-justify-center tw-py-1",e),...t,children:a.jsx(Q.ChevronUp,{className:"tw-h-4 tw-w-4"})}));wo.displayName=ge.ScrollUpButton.displayName;const fo=g.forwardRef(({className:e,...t},n)=>a.jsx(ge.ScrollDownButton,{ref:n,className:N("tw-flex tw-cursor-default tw-items-center tw-justify-center tw-py-1",e),...t,children:a.jsx(Q.ChevronDown,{className:"tw-h-4 tw-w-4"})}));fo.displayName=ge.ScrollDownButton.displayName;const vt=g.forwardRef(({className:e,children:t,position:n="popper",...r},o)=>a.jsx(ge.Portal,{children:a.jsxs(ge.Content,{ref:o,className:N("pr-twp tw-relative tw-z-50 tw-max-h-96 tw-min-w-[8rem] tw-overflow-hidden tw-rounded-md tw-border tw-bg-popover tw-text-popover-foreground tw-shadow-md data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0 data-[state=closed]:tw-zoom-out-95 data-[state=open]:tw-zoom-in-95 data-[side=bottom]:tw-slide-in-from-top-2 data-[side=left]:tw-slide-in-from-right-2 data-[side=right]:tw-slide-in-from-left-2 data-[side=top]:tw-slide-in-from-bottom-2",n==="popper"&&"data-[side=bottom]:tw-translate-y-1 data-[side=left]:tw--translate-x-1 data-[side=right]:tw-translate-x-1 data-[side=top]:tw--translate-y-1",e),position:n,...r,children:[a.jsx(wo,{}),a.jsx(ge.Viewport,{className:N("tw-p-1",n==="popper"&&"tw-h-[var(--radix-select-trigger-height)] tw-w-full tw-min-w-[var(--radix-select-trigger-width)]"),children:t}),a.jsx(fo,{})]})}));vt.displayName=ge.Content.displayName;const Ss=g.forwardRef(({className:e,...t},n)=>a.jsx(ge.Label,{ref:n,className:N("tw-py-1.5 tw-pl-8 tw-pr-2 tw-text-sm tw-font-semibold",e),...t}));Ss.displayName=ge.Label.displayName;const Ae=g.forwardRef(({className:e,children:t,...n},r)=>a.jsxs(ge.Item,{ref:r,className:N("tw-relative tw-flex tw-w-full tw-cursor-default tw-select-none tw-items-center tw-rounded-sm tw-py-1.5 tw-pl-8 tw-pr-2 tw-text-sm tw-outline-none focus:tw-bg-accent focus:tw-text-accent-foreground data-[disabled]:tw-pointer-events-none data-[disabled]:tw-opacity-50",e),...n,children:[a.jsx("span",{className:"tw-absolute tw-left-2 tw-flex tw-h-3.5 tw-w-3.5 tw-items-center tw-justify-center",children:a.jsx(ge.ItemIndicator,{children:a.jsx(Q.Check,{className:"tw-h-4 tw-w-4"})})}),a.jsx(ge.ItemText,{children:t})]}));Ae.displayName=ge.Item.displayName;const Es=g.forwardRef(({className:e,...t},n)=>a.jsx(ge.Separator,{ref:n,className:N("tw--mx-1 tw-my-1 tw-h-px tw-bg-muted",e),...t}));Es.displayName=ge.Separator.displayName;function bc({table:e}){return a.jsx("div",{className:"tw-flex tw-items-center tw-justify-between tw-px-2 tw-pb-3 tw-pt-3",children:a.jsxs("div",{className:"tw-flex tw-items-center tw-space-x-6 lg:tw-space-x-8",children:[a.jsxs("div",{className:"tw-flex-1 tw-text-sm tw-text-muted-foreground",children:[e.getFilteredSelectedRowModel().rows.length," of"," ",e.getFilteredRowModel().rows.length," row(s) selected"]}),a.jsxs("div",{className:"tw-flex tw-items-center tw-space-x-2",children:[a.jsx("p",{className:"tw-text-nowrap tw-text-sm tw-font-medium",children:"Rows per page"}),a.jsxs(At,{value:`${e.getState().pagination.pageSize}`,onValueChange:t=>{e.setPageSize(Number(t))},children:[a.jsx(bt,{className:"tw-h-8 tw-w-[70px]",children:a.jsx(Bt,{placeholder:e.getState().pagination.pageSize})}),a.jsx(vt,{side:"top",children:[10,20,30,40,50].map(t=>a.jsx(Ae,{value:`${t}`,children:t},t))})]})]}),a.jsxs("div",{className:"tw-flex tw-w-[100px] tw-items-center tw-justify-center tw-text-sm tw-font-medium",children:["Page ",e.getState().pagination.pageIndex+1," of ",e.getPageCount()]}),a.jsxs("div",{className:"tw-flex tw-items-center tw-space-x-2",children:[a.jsxs(fe,{variant:"outline",size:"icon",className:"tw-hidden tw-h-8 tw-w-8 tw-p-0 lg:tw-flex",onClick:()=>e.setPageIndex(0),disabled:!e.getCanPreviousPage(),children:[a.jsx("span",{className:"tw-sr-only",children:"Go to first page"}),a.jsx(Q.ArrowLeftIcon,{className:"tw-h-4 tw-w-4"})]}),a.jsxs(fe,{variant:"outline",size:"icon",className:"tw-h-8 tw-w-8 tw-p-0",onClick:()=>e.previousPage(),disabled:!e.getCanPreviousPage(),children:[a.jsx("span",{className:"tw-sr-only",children:"Go to previous page"}),a.jsx(Q.ChevronLeftIcon,{className:"tw-h-4 tw-w-4"})]}),a.jsxs(fe,{variant:"outline",size:"icon",className:"tw-h-8 tw-w-8 tw-p-0",onClick:()=>e.nextPage(),disabled:!e.getCanNextPage(),children:[a.jsx("span",{className:"tw-sr-only",children:"Go to next page"}),a.jsx(Q.ChevronRightIcon,{className:"tw-h-4 tw-w-4"})]}),a.jsxs(fe,{variant:"outline",size:"icon",className:"tw-hidden tw-h-8 tw-w-8 tw-p-0 lg:tw-flex",onClick:()=>e.setPageIndex(e.getPageCount()-1),disabled:!e.getCanNextPage(),children:[a.jsx("span",{className:"tw-sr-only",children:"Go to last page"}),a.jsx(Q.ArrowRightIcon,{className:"tw-h-4 tw-w-4"})]})]})]})})}const Cn=g.forwardRef(({className:e,stickyHeader:t,...n},r)=>a.jsx("div",{className:N("pr-twp tw-relative tw-w-full",{"tw-overflow-auto":!t}),children:a.jsx("table",{ref:r,className:N("tw-w-full tw-caption-bottom tw-text-sm",e),...n})}));Cn.displayName="Table";const Tn=g.forwardRef(({className:e,stickyHeader:t,...n},r)=>a.jsx("thead",{ref:r,className:N({"tw-sticky tw-top-[-1px] tw-bg-background tw-drop-shadow-sm":t},"[&_tr]:tw-border-b",e),...n}));Tn.displayName="TableHeader";const Rn=g.forwardRef(({className:e,...t},n)=>a.jsx("tbody",{ref:n,className:N("[&_tr:last-child]:tw-border-0",e),...t}));Rn.displayName="TableBody";const js=g.forwardRef(({className:e,...t},n)=>a.jsx("tfoot",{ref:n,className:N("tw-border-t tw-bg-muted/50 tw-font-medium [&>tr]:last:tw-border-b-0",e),...t}));js.displayName="TableFooter";const Ze=g.forwardRef(({className:e,...t},n)=>a.jsx("tr",{ref:n,className:N("tw-border-b tw-transition-colors hover:tw-bg-muted/50 data-[state=selected]:tw-bg-muted",e),...t}));Ze.displayName="TableRow";const Vt=g.forwardRef(({className:e,...t},n)=>a.jsx("th",{ref:n,className:N("tw-h-12 tw-px-4 tw-text-start tw-align-middle tw-font-medium tw-text-muted-foreground [&:has([role=checkbox])]:tw-pe-0",e),...t}));Vt.displayName="TableHead";const xt=g.forwardRef(({className:e,...t},n)=>a.jsx("td",{ref:n,className:N("tw-p-4 tw-align-middle [&:has([role=checkbox])]:tw-pe-0",e),...t}));xt.displayName="TableCell";const Cs=g.forwardRef(({className:e,...t},n)=>a.jsx("caption",{ref:n,className:N("tw-mt-4 tw-text-sm tw-text-muted-foreground",e),...t}));Cs.displayName="TableCaption";function Ts({columns:e,data:t,enablePagination:n=!1,showPaginationControls:r=!1,showColumnVisibilityControls:o=!1,stickyHeader:s=!1,onRowClickHandler:i=()=>{}}){var h;const[l,c]=g.useState([]),[u,d]=g.useState([]),[m,w]=g.useState({}),[b,x]=g.useState({}),f=Se.useReactTable({data:t,columns:e,getCoreRowModel:Se.getCoreRowModel(),...n&&{getPaginationRowModel:Se.getPaginationRowModel()},onSortingChange:c,getSortedRowModel:Se.getSortedRowModel(),onColumnFiltersChange:d,getFilteredRowModel:Se.getFilteredRowModel(),onColumnVisibilityChange:w,onRowSelectionChange:x,state:{sorting:l,columnFilters:u,columnVisibility:m,rowSelection:b}});return a.jsxs("div",{className:"pr-twp",children:[o&&a.jsx(gc,{table:f}),a.jsxs(Cn,{stickyHeader:s,children:[a.jsx(Tn,{stickyHeader:s,children:f.getHeaderGroups().map(S=>a.jsx(Ze,{children:S.headers.map(R=>a.jsx(Vt,{children:R.isPlaceholder?void 0:Se.flexRender(R.column.columnDef.header,R.getContext())},R.id))},S.id))}),a.jsx(Rn,{children:(h=f.getRowModel().rows)!=null&&h.length?f.getRowModel().rows.map(S=>a.jsx(Ze,{onClick:()=>i(S,f),"data-state":S.getIsSelected()&&"selected",children:S.getVisibleCells().map(R=>a.jsx(xt,{children:Se.flexRender(R.column.columnDef.cell,R.getContext())},R.id))},S.id)):a.jsx(Ze,{children:a.jsx(xt,{colSpan:e.length,className:"tw-h-24 tw-text-center",children:"No results."})})})]}),n&&a.jsxs("div",{className:"tw-flex tw-items-center tw-justify-end tw-space-x-2 tw-py-4",children:[a.jsx(fe,{variant:"outline",size:"sm",onClick:()=>f.previousPage(),disabled:!f.getCanPreviousPage(),children:"Previous"}),a.jsx(fe,{variant:"outline",size:"sm",onClick:()=>f.nextPage(),disabled:!f.getCanNextPage(),children:"Next"})]}),n&&r&&a.jsx(bc,{table:f})]})}function vc({occurrenceData:e,setScriptureReference:t,localizedStrings:n}){const r=n["%webView_inventory_occurrences_table_header_reference%"],o=n["%webView_inventory_occurrences_table_header_occurrence%"],s=g.useMemo(()=>{const i=[];return e.forEach(l=>{i.some(c=>W.deepEqual(c,l))||i.push(l)}),i},[e]);return a.jsxs(Cn,{stickyHeader:!0,children:[a.jsx(Tn,{stickyHeader:!0,children:a.jsxs(Ze,{children:[a.jsx(Vt,{children:r}),a.jsx(Vt,{children:o})]})}),a.jsx(Rn,{children:s.length>0&&s.map(i=>a.jsxs(Ze,{onClick:()=>{t(i.reference)},children:[a.jsx(xt,{children:`${ae.bookNumberToEnglishName(i.reference.bookNum)} ${i.reference.chapterNum}:${i.reference.verseNum}`}),a.jsx(xt,{children:i.text})]},`${i.reference.bookNum} ${i.reference.chapterNum}:${i.reference.verseNum}-${i.text}`))})]})}const sr=g.forwardRef(({className:e,...t},n)=>a.jsx(Ur.Root,{ref:n,className:N("tw-peer pr-twp tw-h-4 tw-w-4 tw-shrink-0 tw-rounded-sm tw-border tw-border-primary tw-ring-offset-background focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-cursor-not-allowed disabled:tw-opacity-50 data-[state=checked]:tw-bg-primary data-[state=checked]:tw-text-primary-foreground",e),...t,children:a.jsx(Ur.Indicator,{className:N("tw-flex tw-items-center tw-justify-center tw-text-current"),children:a.jsx(Q.Check,{className:"tw-h-4 tw-w-4"})})}));sr.displayName=Ur.Root.displayName;const Rs=e=>e.split(/(?:\r?\n|\r)|(?=(?:\\(?:v|c|id)))/g),Hr=e=>{const t=/^\\[vc]\s+(\d+)/,n=e.match(t);if(n)return+n[1]},Os=e=>{const t=e.match(/^\\id\s+([A-Za-z]+)/);return t?ae.bookIdToNumber(t[1]):0},_s=(e,t,n)=>n.includes(e)?"unapproved":t.includes(e)?"approved":"unknown",Ps=Xt.cva("pr-twp tw-inline-flex tw-items-center tw-justify-center tw-rounded-md tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-colors hover:tw-bg-muted hover:tw-text-muted-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50 data-[state=on]:tw-bg-accent data-[state=on]:tw-text-accent-foreground",{variants:{variant:{default:"tw-bg-transparent",outline:"tw-border tw-border-input tw-bg-transparent hover:tw-bg-accent hover:tw-text-accent-foreground"},size:{default:"tw-h-10 tw-px-3",sm:"tw-h-9 tw-px-2.5",lg:"tw-h-11 tw-px-5"}},defaultVariants:{variant:"default",size:"default"}}),xc=g.forwardRef(({className:e,variant:t,size:n,...r},o)=>a.jsx(ts.Root,{ref:o,className:N(Ps({variant:t,size:n,className:e})),...r}));xc.displayName=ts.Root.displayName;const Is=g.createContext({size:"default",variant:"default"}),mo=g.forwardRef(({className:e,variant:t,size:n,children:r,...o},s)=>a.jsx(rr.Root,{ref:s,className:N("pr-twp tw-flex tw-items-center tw-justify-center tw-gap-1",e),...o,children:a.jsx(Is.Provider,{value:{variant:t,size:n},children:r})}));mo.displayName=rr.Root.displayName;const fn=g.forwardRef(({className:e,children:t,variant:n,size:r,...o},s)=>{const i=g.useContext(Is);return a.jsx(rr.Item,{ref:s,className:N(Ps({variant:i.variant||n,size:i.size||r}),e),...o,children:t})});fn.displayName=rr.Item.displayName;const ir=e=>e==="asc"?a.jsx(Q.ArrowUpIcon,{className:"tw-ms-2 tw-h-4 tw-w-4"}):e==="desc"?a.jsx(Q.ArrowDownIcon,{className:"tw-ms-2 tw-h-4 tw-w-4"}):a.jsx(Q.ArrowUpDownIcon,{className:"tw-ms-2 tw-h-4 tw-w-4"}),yc=e=>({accessorKey:"item",accessorFn:t=>t.items[0],header:({column:t})=>a.jsxs(fe,{variant:"ghost",onClick:()=>t.toggleSorting(void 0),children:[e,ir(t.getIsSorted())]})}),Nc=(e,t)=>({accessorKey:`item${t}`,accessorFn:n=>n.items[t],header:({column:n})=>a.jsxs(fe,{variant:"ghost",onClick:()=>n.toggleSorting(void 0),children:[e,ir(n.getIsSorted())]})}),kc=e=>({accessorKey:"count",header:({column:t})=>a.jsx("div",{className:"tw-flex tw-justify-end tw-tabular-nums",children:a.jsxs(fe,{variant:"ghost",onClick:()=>t.toggleSorting(void 0),children:[e,ir(t.getIsSorted())]})}),cell:({row:t})=>a.jsx("div",{className:"tw-flex tw-justify-end",children:t.getValue("count")})}),Rr=(e,t,n,r,o,s)=>{let i=[...n];e.forEach(c=>{t==="approved"?i.includes(c)||i.push(c):i=i.filter(u=>u!==c)}),r(i);let l=[...o];e.forEach(c=>{t==="unapproved"?l.includes(c)||l.push(c):l=l.filter(u=>u!==c)}),s(l)},Sc=(e,t,n,r,o)=>({accessorKey:"status",header:({column:s})=>a.jsx("div",{className:"tw-flex tw-justify-center",children:a.jsxs(fe,{variant:"ghost",onClick:()=>s.toggleSorting(void 0),children:[e,ir(s.getIsSorted())]})}),cell:({row:s})=>{const i=s.getValue("status"),l=s.getValue("item");return a.jsxs(mo,{value:i,variant:"outline",type:"single",children:[a.jsx(fn,{onClick:()=>Rr([l],"approved",t,n,r,o),value:"approved",children:a.jsx(Q.CircleCheckIcon,{})}),a.jsx(fn,{onClick:()=>Rr([l],"unapproved",t,n,r,o),value:"unapproved",children:a.jsx(Q.CircleXIcon,{})}),a.jsx(fn,{onClick:()=>Rr([l],"unknown",t,n,r,o),value:"unknown",children:a.jsx(Q.CircleHelpIcon,{})})]})}}),Ec=Object.freeze(["%webView_inventory_all%","%webView_inventory_approved%","%webView_inventory_unapproved%","%webView_inventory_unknown%","%webView_inventory_scope_currentBook%","%webView_inventory_scope_chapter%","%webView_inventory_scope_verse%","%webView_inventory_filter_text%","%webView_inventory_show_additional_items%","%webView_inventory_occurrences_table_header_reference%","%webView_inventory_occurrences_table_header_occurrence%"]),jc=(e,t,n)=>{let r=e;return t!=="all"&&(r=r.filter(o=>t==="approved"&&o.status==="approved"||t==="unapproved"&&o.status==="unapproved"||t==="unknown"&&o.status==="unknown")),n!==""&&(r=r.filter(o=>o.items[0].includes(n))),r},Cc=(e,t,n,r,o)=>{if(!e)return[];const s=[];let i=t.bookNum,l=t.chapterNum,c=t.verseNum;return Rs(e).forEach(d=>{d.startsWith("\\id")&&(i=Os(d),l=0,c=0),d.startsWith("\\c")&&(l=Hr(d),c=0),d.startsWith("\\v")&&(c=Hr(d),l===0&&(l=t.chapterNum));let m=o.exec(d)??void 0;for(;m;){const w=[];m.forEach(h=>w.push(h));const b=m.index,x=s.find(h=>W.deepEqual(h.items,w)),f={reference:{bookNum:i!==void 0?i:-1,chapterNum:l!==void 0?l:-1,verseNum:c!==void 0?c:-1},text:W.substring(d,Math.max(0,b-25),Math.min(b+25,d.length))};if(x)x.count+=1,x.occurrences.push(f);else{const h={items:w,count:1,status:_s(w[0],n,r),occurrences:[f]};s.push(h)}m=o.exec(d)??void 0}}),s},Je=(e,t)=>e[t]??t;function Tc({scriptureReference:e,setScriptureReference:t,localizedStrings:n,extractItems:r,additionalItemsLabels:o,approvedItems:s,unapprovedItems:i,text:l,scope:c,onScopeChange:u,columns:d}){const m=Je(n,"%webView_inventory_all%"),w=Je(n,"%webView_inventory_approved%"),b=Je(n,"%webView_inventory_unapproved%"),x=Je(n,"%webView_inventory_unknown%"),f=Je(n,"%webView_inventory_scope_currentBook%"),h=Je(n,"%webView_inventory_scope_chapter%"),S=Je(n,"%webView_inventory_scope_verse%"),R=Je(n,"%webView_inventory_filter_text%"),j=Je(n,"%webView_inventory_show_additional_items%"),[E,v]=g.useState(!1),[P,V]=g.useState("all"),[U,C]=g.useState(""),[_,k]=g.useState([]),D=g.useMemo(()=>l?r instanceof RegExp?Cc(l,e,s,i,r):r(l,e,s,i):[],[l,r,e,s,i]),$=g.useMemo(()=>{if(E)return D;const y=[];return D.forEach(T=>{const z=T.items[0],L=y.find(B=>B.items[0]===z);L?(L.count+=T.count,L.occurrences=L.occurrences.concat(T.occurrences)):y.push({items:[z],count:T.count,occurrences:T.occurrences,status:T.status})}),y},[E,D]),J=g.useMemo(()=>jc($,P,U),[$,P,U]),Y=g.useMemo(()=>{var z,L;if(!E)return d;const y=(z=o==null?void 0:o.tableHeaders)==null?void 0:z.length;if(!y)return d;const T=[];for(let B=0;B{k([])},[J]);const F=(y,T)=>{T.setRowSelection(()=>{const z={};return z[y.index]=!0,z}),k(y.original.items)},te=y=>{if(y==="book"||y==="chapter"||y==="verse")u(y);else throw new Error(`Invalid scope value: ${y}`)},se=y=>{if(y==="all"||y==="approved"||y==="unapproved"||y==="unknown")V(y);else throw new Error(`Invalid status filter value: ${y}`)},oe=g.useMemo(()=>{if($.length===0||_.length===0)return[];const y=$.filter(T=>W.deepEqual(E?T.items:[T.items[0]],_));if(y.length>1)throw new Error("Selected item is not unique");return y[0].occurrences},[_,E,$]);return a.jsxs("div",{className:"pr-twp tw-flex tw-h-full tw-flex-col",children:[a.jsxs("div",{className:"tw-flex tw-items-stretch",children:[a.jsxs(At,{onValueChange:y=>se(y),defaultValue:P,children:[a.jsx(bt,{className:"tw-m-1",children:a.jsx(Bt,{placeholder:"Select filter"})}),a.jsxs(vt,{children:[a.jsx(Ae,{value:"all",children:m}),a.jsx(Ae,{value:"approved",children:w}),a.jsx(Ae,{value:"unapproved",children:b}),a.jsx(Ae,{value:"unknown",children:x})]})]}),a.jsxs(At,{onValueChange:y=>te(y),defaultValue:c,children:[a.jsx(bt,{className:"tw-m-1",children:a.jsx(Bt,{placeholder:"Select scope"})}),a.jsxs(vt,{children:[a.jsx(Ae,{value:"book",children:f}),a.jsx(Ae,{value:"chapter",children:h}),a.jsx(Ae,{value:"verse",children:S})]})]}),a.jsx(St,{className:"tw-m-1 tw-rounded-md tw-border",placeholder:R,value:U,onChange:y=>{C(y.target.value)}}),o&&a.jsxs("div",{className:"tw-m-1 tw-flex tw-items-center tw-rounded-md tw-border",children:[a.jsx(sr,{className:"tw-m-1",checked:E,onCheckedChange:y=>{k([]),v(y)}}),a.jsx(qe,{className:"tw-m-1 tw-flex-shrink-0 tw-whitespace-nowrap",children:(o==null?void 0:o.checkboxText)??j})]})]}),a.jsx("div",{className:"tw-m-1 tw-flex-1 tw-overflow-auto tw-rounded-md tw-border",children:a.jsx(Ts,{columns:Y,data:J,onRowClickHandler:F,stickyHeader:!0})}),oe.length>0&&a.jsx("div",{className:"tw-m-1 tw-flex-1 tw-overflow-auto tw-rounded-md tw-border",children:a.jsx(vc,{occurrenceData:oe,setScriptureReference:t,localizedStrings:n})})]})}function ho({className:e,onSearch:t,placeholder:n,isFullWidth:r}){const[o,s]=g.useState(""),i=l=>{s(l),t(l)};return a.jsx(St,{className:N("tw-flex tw-h-10 tw-rounded-md tw-border tw-border-input tw-bg-background tw-px-3 tw-py-2 tw-text-sm tw-ring-offset-background file:tw-border-0 file:tw-bg-transparent file:tw-text-sm file:tw-font-medium placeholder:tw-text-muted-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-[color:hsl(240,5%,64.9%)] focus-visible:tw-ring-offset-2 disabled:tw-cursor-not-allowed disabled:tw-opacity-50",{"tw-w-full":r},e),placeholder:n,value:o,onChange:l=>i(l.target.value)})}const go=g.forwardRef(({className:e,...t},n)=>a.jsx(Oe.Root,{orientation:"vertical",ref:n,className:N("tw-flex tw-gap-1 tw-rounded-md tw-text-muted-foreground",e),...t}));go.displayName=Oe.List.displayName;const bo=g.forwardRef(({className:e,...t},n)=>a.jsx(Oe.List,{ref:n,className:N("tw-flex-fit tw-mlk-items-center tw-w-[124px] tw-justify-center tw-rounded-md tw-bg-muted tw-p-1 tw-text-muted-foreground",e),...t}));bo.displayName=Oe.List.displayName;const Ms=g.forwardRef(({className:e,...t},n)=>a.jsx(Oe.Trigger,{ref:n,...t,className:N("overflow-clip tw-inline-flex tw-w-[116px] tw-cursor-pointer tw-items-center tw-justify-center tw-break-words tw-rounded-sm tw-border-0 tw-bg-muted tw-px-3 tw-py-1.5 tw-text-sm tw-font-medium tw-text-inherit tw-ring-offset-background tw-transition-all hover:tw-text-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50 data-[state=active]:tw-bg-background data-[state=active]:tw-text-foreground data-[state=active]:tw-shadow-sm",e)})),vo=g.forwardRef(({className:e,...t},n)=>a.jsx(Oe.Content,{ref:n,className:N("tw-ms-5 tw-flex-grow tw-text-foreground tw-ring-offset-background focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2",e),...t}));vo.displayName=Oe.Content.displayName;function Rc({tabList:e,onSearch:t,searchPlaceholder:n,headerTitle:r,isSearchBarFullWidth:o=!1,direction:s="ltr"}){return a.jsxs("div",{className:"pr-twp",children:[a.jsxs("div",{className:"tw-sticky tw-top-0 tw-space-y-2 tw-pb-2",children:[r?a.jsx("h1",{children:r}):"",a.jsx(ho,{isFullWidth:o,onSearch:t,placeholder:n})]}),a.jsxs(go,{dir:s,children:[a.jsx(bo,{children:e.map(i=>a.jsx(Ms,{value:i.value,children:i.value},i.key))}),e.map(i=>a.jsx(vo,{value:i.value,children:i.content},i.key))]})]})}const lr=g.forwardRef(({className:e,orientation:t="horizontal",decorative:n=!0,...r},o)=>a.jsx(ns.Root,{ref:o,decorative:n,orientation:t,className:N("pr-twp tw-shrink-0 tw-bg-border",t==="horizontal"?"tw-h-[1px] tw-w-full":"tw-h-full tw-w-[1px]",e),...r}));lr.displayName=ns.Root.displayName;const Oc=be.Root,_c=be.Portal,$s=M.forwardRef(({className:e,...t},n)=>a.jsx(be.Overlay,{className:N("tw-fixed tw-inset-0 tw-z-50 tw-bg-black/80 data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0",e),...t,ref:n}));$s.displayName=be.Overlay.displayName;const Pc=Xt.cva("pr-twp tw-fixed tw-z-50 tw-gap-4 tw-bg-background tw-p-6 tw-shadow-lg tw-transition tw-ease-in-out data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-duration-300 data-[state=open]:tw-duration-500",{variants:{side:{top:"tw-inset-x-0 tw-top-0 tw-border-b data-[state=closed]:tw-slide-out-to-top data-[state=open]:tw-slide-in-from-top",bottom:"tw-inset-x-0 tw-bottom-0 tw-border-t data-[state=closed]:tw-slide-out-to-bottom data-[state=open]:tw-slide-in-from-bottom",left:"tw-inset-y-0 tw-left-0 tw-h-full tw-w-3/4 tw-border-r data-[state=closed]:tw-slide-out-to-left data-[state=open]:tw-slide-in-from-left sm:tw-max-w-sm",right:"tw-inset-y-0 tw-right-0 tw-h-full tw-w-3/4 tw- tw-border-l data-[state=closed]:tw-slide-out-to-right data-[state=open]:tw-slide-in-from-right sm:tw-max-w-sm"}},defaultVariants:{side:"right"}}),Ds=M.forwardRef(({side:e="right",className:t,children:n,...r},o)=>a.jsxs(_c,{children:[a.jsx($s,{}),a.jsxs(be.Content,{ref:o,className:N(Pc({side:e}),t),...r,children:[n,a.jsxs(be.Close,{className:"tw-absolute tw-right-4 tw-top-4 tw-rounded-sm tw-opacity-70 tw-ring-offset-background tw-transition-opacity hover:tw-opacity-100 focus:tw-outline-none focus:tw-ring-2 focus:tw-ring-ring focus:tw-ring-offset-2 disabled:tw-pointer-events-none data-[state=open]:tw-bg-secondary",children:[a.jsx(Q.X,{className:"tw-h-4 tw-w-4"}),a.jsx("span",{className:"tw-sr-only",children:"Close"})]})]})]}));Ds.displayName=be.Content.displayName;const Ic=M.forwardRef(({className:e,...t},n)=>a.jsx(be.Title,{ref:n,className:N("tw-text-lg tw-font-semibold tw-text-foreground",e),...t}));Ic.displayName=be.Title.displayName;const Mc=M.forwardRef(({className:e,...t},n)=>a.jsx(be.Description,{ref:n,className:N("tw-text-sm tw-text-muted-foreground",e),...t}));Mc.displayName=be.Description.displayName;function sa({className:e,...t}){return a.jsx("div",{className:N("pr-twp tw-animate-pulse tw-rounded-md tw-bg-muted",e),...t})}const $c=Sn.Provider,Dc=Sn.Root,Ac=Sn.Trigger,As=g.forwardRef(({className:e,sideOffset:t=4,...n},r)=>a.jsx(Sn.Content,{ref:r,sideOffset:t,className:N("pr-twp tw-z-50 tw-overflow-hidden tw-rounded-md tw-border tw-bg-popover tw-px-3 tw-py-1.5 tw-text-sm tw-text-popover-foreground tw-shadow-md tw-animate-in tw-fade-in-0 tw-zoom-in-95 data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=closed]:tw-zoom-out-95 data-[side=bottom]:tw-slide-in-from-top-2 data-[side=left]:tw-slide-in-from-right-2 data-[side=right]:tw-slide-in-from-left-2 data-[side=top]:tw-slide-in-from-bottom-2",e),...n}));As.displayName=Sn.Content.displayName;const Or=768;function Bc(){const[e,t]=M.useState(void 0);return M.useEffect(()=>{const n=window.matchMedia(`(max-width: ${Or-1}px)`),r=()=>{t(window.innerWidthn.removeEventListener("change",r)},[]),!!e}const Vc="sidebar:state",zc=60*60*24*7,Lc="16rem",Fc="18rem",Gc="3rem",Uc="b",Bs=g.createContext(void 0);function cr(){const e=g.useContext(Bs);if(!e)throw new Error("useSidebar must be used within a SidebarProvider.");return e}const Vs=g.forwardRef(({defaultOpen:e=!0,open:t,onOpenChange:n,className:r,style:o,children:s,...i},l)=>{const c=Bc(),[u,d]=g.useState(!1),[m,w]=g.useState(e),b=t??m,x=g.useCallback(R=>{const j=typeof R=="function"?R(b):R;n?n(j):w(j),document.cookie=`${Vc}=${j}; path=/; max-age=${zc}`},[n,b]),f=g.useCallback(()=>c?d(R=>!R):x(R=>!R),[c,x,d]);g.useEffect(()=>{const R=j=>{j.key===Uc&&(j.metaKey||j.ctrlKey)&&(j.preventDefault(),f())};return window.addEventListener("keydown",R),()=>window.removeEventListener("keydown",R)},[f]);const h=b?"expanded":"collapsed",S=g.useMemo(()=>({state:h,open:b,setOpen:x,isMobile:c,openMobile:u,setOpenMobile:d,toggleSidebar:f}),[h,b,x,c,u,d,f]);return a.jsx(Bs.Provider,{value:S,children:a.jsx($c,{delayDuration:0,children:a.jsx("div",{style:{"--sidebar-width":Lc,"--sidebar-width-icon":Gc,...o},className:N("tw-group/sidebar-wrapper pr-twp tw-flex tw-w-full has-[[data-variant=inset]]:tw-bg-sidebar",r),ref:l,...i,children:s})})})});Vs.displayName="SidebarProvider";const zs=g.forwardRef(({side:e="left",variant:t="sidebar",collapsible:n="offcanvas",className:r,children:o,...s},i)=>{const{isMobile:l,state:c,openMobile:u,setOpenMobile:d}=cr();return n==="none"?a.jsx("div",{className:N("tw-flex tw-h-full tw-w-[--sidebar-width] tw-flex-col tw-bg-sidebar tw-text-sidebar-foreground",r),ref:i,...s,children:o}):l?a.jsx(Oc,{open:u,onOpenChange:d,...s,children:a.jsx(Ds,{"data-sidebar":"sidebar","data-mobile":"true",className:"tw-w-[--sidebar-width] tw-bg-sidebar tw-p-0 tw-text-sidebar-foreground [&>button]:tw-hidden",style:{"--sidebar-width":Fc},side:e,children:a.jsx("div",{className:"tw-flex tw-h-full tw-w-full tw-flex-col",children:o})})}):a.jsxs("div",{ref:i,className:"tw-group tw-peer tw-hidden tw-text-sidebar-foreground md:tw-block","data-state":c,"data-collapsible":c==="collapsed"?n:"","data-variant":t,"data-side":e,children:[a.jsx("div",{className:N("tw-relative tw-h-svh tw-w-[--sidebar-width] tw-bg-transparent tw-transition-[width] tw-duration-200 tw-ease-linear","group-data-[collapsible=offcanvas]:tw-w-0","group-data-[side=right]:tw-rotate-180",t==="floating"||t==="inset"?"group-data-[collapsible=icon]:tw-w-[calc(var(--sidebar-width-icon)_+_theme(spacing.4))]":"group-data-[collapsible=icon]:tw-w-[--sidebar-width-icon]")}),a.jsx("div",{className:N("tw-absolute tw-inset-y-0 tw-z-10 tw-hidden tw-h-svh tw-w-[--sidebar-width] tw-transition-[left,right,width] tw-duration-200 tw-ease-linear md:tw-flex",e==="left"?"tw-left-0 group-data-[collapsible=offcanvas]:tw-left-[calc(var(--sidebar-width)*-1)]":"tw-right-0 group-data-[collapsible=offcanvas]:tw-right-[calc(var(--sidebar-width)*-1)]",t==="floating"||t==="inset"?"tw-p-2 group-data-[collapsible=icon]:tw-w-[calc(var(--sidebar-width-icon)_+_theme(spacing.4)_+2px)]":"group-data-[collapsible=icon]:tw-w-[--sidebar-width-icon] group-data-[side=left]:tw-border-r group-data-[side=right]:tw-border-l",r),...s,children:a.jsx("div",{"data-sidebar":"sidebar",className:"tw-flex tw-h-full tw-w-full tw-flex-col tw-bg-sidebar group-data-[variant=floating]:tw-rounded-lg group-data-[variant=floating]:tw-border group-data-[variant=floating]:tw-border-sidebar-border group-data-[variant=floating]:tw-shadow",children:o})})]})});zs.displayName="Sidebar";const qc=g.forwardRef(({className:e,onClick:t,...n},r)=>{const{toggleSidebar:o}=cr();return a.jsxs(fe,{ref:r,"data-sidebar":"trigger",variant:"ghost",size:"icon",className:N("tw-h-7 tw-w-7",e),onClick:s=>{t==null||t(s),o()},...n,children:[a.jsx(Q.PanelLeft,{}),a.jsx("span",{className:"tw-sr-only",children:"Toggle Sidebar"})]})});qc.displayName="SidebarTrigger";const Hc=g.forwardRef(({className:e,...t},n)=>{const{toggleSidebar:r}=cr();return a.jsx("button",{type:"button",ref:n,"data-sidebar":"rail","aria-label":"Toggle Sidebar",tabIndex:-1,onClick:r,title:"Toggle Sidebar",className:N("tw-absolute tw-inset-y-0 tw-z-20 tw-hidden tw-w-4 tw--translate-x-1/2 tw-transition-all tw-ease-linear after:tw-absolute after:tw-inset-y-0 after:tw-left-1/2 after:tw-w-[2px] hover:after:tw-bg-sidebar-border group-data-[side=left]:tw--right-4 group-data-[side=right]:tw-left-0 sm:tw-flex","[[data-side=left]_&]:tw-cursor-w-resize [[data-side=right]_&]:tw-cursor-e-resize","[[data-side=left][data-state=collapsed]_&]:tw-cursor-e-resize [[data-side=right][data-state=collapsed]_&]:tw-cursor-w-resize","group-data-[collapsible=offcanvas]:tw-translate-x-0 group-data-[collapsible=offcanvas]:after:tw-left-full group-data-[collapsible=offcanvas]:hover:tw-bg-sidebar","[[data-side=left][data-collapsible=offcanvas]_&]:tw--right-2","[[data-side=right][data-collapsible=offcanvas]_&]:tw--left-2",e),...t})});Hc.displayName="SidebarRail";const Ls=g.forwardRef(({className:e,...t},n)=>a.jsx("main",{ref:n,className:N("tw-relative tw-flex tw-flex-1 tw-flex-col tw-bg-background","peer-data-[variant=inset]:tw-min-h-[calc(100svh-theme(spacing.4))] md:peer-data-[variant=inset]:tw-m-2 md:peer-data-[state=collapsed]:peer-data-[variant=inset]:tw-ml-2 md:peer-data-[variant=inset]:tw-ml-0 md:peer-data-[variant=inset]:tw-rounded-xl md:peer-data-[variant=inset]:tw-shadow",e),...t}));Ls.displayName="SidebarInset";const Xc=g.forwardRef(({className:e,...t},n)=>a.jsx(St,{ref:n,"data-sidebar":"input",className:N("tw-h-8 tw-w-full tw-bg-background tw-shadow-none focus-visible:tw-ring-2 focus-visible:tw-ring-sidebar-ring",e),...t}));Xc.displayName="SidebarInput";const Yc=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,"data-sidebar":"header",className:N("tw-flex tw-flex-col tw-gap-2 tw-p-2",e),...t}));Yc.displayName="SidebarHeader";const Wc=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,"data-sidebar":"footer",className:N("tw-flex tw-flex-col tw-gap-2 tw-p-2",e),...t}));Wc.displayName="SidebarFooter";const Kc=g.forwardRef(({className:e,...t},n)=>a.jsx(lr,{ref:n,"data-sidebar":"separator",className:N("tw-mx-2 tw-w-auto tw-bg-sidebar-border",e),...t}));Kc.displayName="SidebarSeparator";const Fs=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,"data-sidebar":"content",className:N("tw-flex tw-min-h-0 tw-flex-1 tw-flex-col tw-gap-2 tw-overflow-auto group-data-[collapsible=icon]:tw-overflow-hidden",e),...t}));Fs.displayName="SidebarContent";const Xr=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,"data-sidebar":"group",className:N("tw-relative tw-flex tw-w-full tw-min-w-0 tw-flex-col tw-p-2",e),...t}));Xr.displayName="SidebarGroup";const Yr=g.forwardRef(({className:e,asChild:t=!1,...n},r)=>{const o=t?Ht.Slot:"div";return a.jsx(o,{ref:r,"data-sidebar":"group-label",className:N("tw-flex tw-h-8 tw-shrink-0 tw-items-center tw-rounded-md tw-px-2 tw-text-xs tw-font-medium tw-text-sidebar-foreground/70 tw-outline-none tw-ring-sidebar-ring tw-transition-[margin,opa] tw-duration-200 tw-ease-linear focus-visible:tw-ring-2 [&>svg]:tw-size-4 [&>svg]:tw-shrink-0","group-data-[collapsible=icon]:tw--mt-8 group-data-[collapsible=icon]:tw-opacity-0",e),...n})});Yr.displayName="SidebarGroupLabel";const Jc=g.forwardRef(({className:e,asChild:t=!1,...n},r)=>{const o=t?Ht.Slot:"button";return a.jsx(o,{ref:r,"data-sidebar":"group-action",className:N("tw-absolute tw-right-3 tw-top-3.5 tw-flex tw-aspect-square tw-w-5 tw-items-center tw-justify-center tw-rounded-md tw-p-0 tw-text-sidebar-foreground tw-outline-none tw-ring-sidebar-ring tw-transition-transform hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground focus-visible:tw-ring-2 [&>svg]:tw-size-4 [&>svg]:tw-shrink-0","after:tw-absolute after:tw--inset-2 after:md:tw-hidden","group-data-[collapsible=icon]:tw-hidden",e),...n})});Jc.displayName="SidebarGroupAction";const Wr=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,"data-sidebar":"group-content",className:N("tw-w-full tw-text-sm",e),...t}));Wr.displayName="SidebarGroupContent";const Gs=g.forwardRef(({className:e,...t},n)=>a.jsx("ul",{ref:n,"data-sidebar":"menu",className:N("tw-flex tw-w-full tw-min-w-0 tw-flex-col tw-gap-1",e),...t}));Gs.displayName="SidebarMenu";const Us=g.forwardRef(({className:e,...t},n)=>a.jsx("li",{ref:n,"data-sidebar":"menu-item",className:N("tw-group/menu-item tw-relative",e),...t}));Us.displayName="SidebarMenuItem";const Zc=Xt.cva("tw-peer/menu-button tw-flex tw-w-full tw-items-center tw-gap-2 tw-overflow-hidden tw-rounded-md tw-p-2 tw-text-left tw-text-sm tw-outline-none tw-ring-sidebar-ring tw-transition-[width,height,padding] hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground focus-visible:tw-ring-2 active:tw-bg-sidebar-accent active:tw-text-sidebar-accent-foreground disabled:tw-pointer-events-none disabled:tw-opacity-50 tw-group-has-[[data-sidebar=menu-action]]/menu-item:pr-8 aria-disabled:tw-pointer-events-none aria-disabled:tw-opacity-50 data-[active=true]:tw-font-medium data-[active=true]:tw-text-sidebar-accent-foreground data-[state=open]:hover:tw-bg-sidebar-accent data-[state=open]:hover:tw-text-sidebar-accent-foreground group-data-[collapsible=icon]:tw-!size-8 group-data-[collapsible=icon]:tw-!p-2 [&>span:last-child]:tw-truncate [&>svg]:tw-size-4 [&>svg]:tw-shrink-0",{variants:{variant:{default:"hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground",outline:"tw-bg-background tw-shadow-[0_0_0_1px_hsl(var(--sidebar-border))] hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground hover:tw-shadow-[0_0_0_1px_hsl(var(--sidebar-accent))]"},size:{default:"tw-h-8 tw-text-sm",sm:"tw-h-7 tw-text-xs",lg:"tw-h-12 tw-text-sm group-data-[collapsible=icon]:tw-!p-0"}},defaultVariants:{variant:"default",size:"default"}}),qs=g.forwardRef(({asChild:e=!1,isActive:t=!1,variant:n="default",size:r="default",tooltip:o,className:s,...i},l)=>{const c=e?Ht.Slot:"button",{isMobile:u,state:d}=cr(),m=a.jsx(c,{ref:l,"data-sidebar":"menu-button","data-size":r,"data-active":t,className:N(Zc({variant:n,size:r}),s),...i});return o?(typeof o=="string"&&(o={children:o}),a.jsxs(Dc,{children:[a.jsx(Ac,{asChild:!0,children:m}),a.jsx(As,{side:"right",align:"center",hidden:d!=="collapsed"||u,...o})]})):m});qs.displayName="SidebarMenuButton";const Qc=g.forwardRef(({className:e,asChild:t=!1,showOnHover:n=!1,...r},o)=>{const s=t?Ht.Slot:"button";return a.jsx(s,{ref:o,"data-sidebar":"menu-action",className:N("tw-peer-hover/menu-button:text-sidebar-accent-foreground tw-absolute tw-right-1 tw-top-1.5 tw-flex tw-aspect-square tw-w-5 tw-items-center tw-justify-center tw-rounded-md tw-p-0 tw-text-sidebar-foreground tw-outline-none tw-ring-sidebar-ring tw-transition-transform hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground focus-visible:tw-ring-2 [&>svg]:tw-size-4 [&>svg]:tw-shrink-0","after:tw-absolute after:tw--inset-2 after:md:tw-hidden","tw-peer-data-[size=sm]/menu-button:top-1","tw-peer-data-[size=default]/menu-button:top-1.5","tw-peer-data-[size=lg]/menu-button:top-2.5","group-data-[collapsible=icon]:tw-hidden",n&&"tw-group-focus-within/menu-item:opacity-100 tw-group-hover/menu-item:opacity-100 tw-peer-data-[active=true]/menu-button:text-sidebar-accent-foreground data-[state=open]:tw-opacity-100 md:tw-opacity-0",e),...r})});Qc.displayName="SidebarMenuAction";const ed=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,"data-sidebar":"menu-badge",className:N("tw-pointer-events-none tw-absolute tw-right-1 tw-flex tw-h-5 tw-min-w-5 tw-select-none tw-items-center tw-justify-center tw-rounded-md tw-px-1 tw-text-xs tw-font-medium tw-tabular-nums tw-text-sidebar-foreground","tw-peer-hover/menu-button:text-sidebar-accent-foreground tw-peer-data-[active=true]/menu-button:text-sidebar-accent-foreground","tw-peer-data-[size=sm]/menu-button:top-1","tw-peer-data-[size=default]/menu-button:top-1.5","tw-peer-data-[size=lg]/menu-button:top-2.5","group-data-[collapsible=icon]:tw-hidden",e),...t}));ed.displayName="SidebarMenuBadge";const td=g.forwardRef(({className:e,showIcon:t=!1,...n},r)=>{const o=g.useMemo(()=>`${Math.floor(Math.random()*40)+50}%`,[]);return a.jsxs("div",{ref:r,"data-sidebar":"menu-skeleton",className:N("tw-flex tw-h-8 tw-items-center tw-gap-2 tw-rounded-md tw-px-2",e),...n,children:[t&&a.jsx(sa,{className:"tw-size-4 tw-rounded-md","data-sidebar":"menu-skeleton-icon"}),a.jsx(sa,{className:"tw-h-4 tw-max-w-[--skeleton-width] tw-flex-1","data-sidebar":"menu-skeleton-text",style:{"--skeleton-width":o}})]})});td.displayName="SidebarMenuSkeleton";const nd=g.forwardRef(({className:e,...t},n)=>a.jsx("ul",{ref:n,"data-sidebar":"menu-sub",className:N("tw-mx-3.5 tw-flex tw-min-w-0 tw-translate-x-px tw-flex-col tw-gap-1 tw-border-l tw-border-sidebar-border tw-px-2.5 tw-py-0.5","group-data-[collapsible=icon]:tw-hidden",e),...t}));nd.displayName="SidebarMenuSub";const rd=g.forwardRef(({...e},t)=>a.jsx("li",{ref:t,...e}));rd.displayName="SidebarMenuSubItem";const od=g.forwardRef(({asChild:e=!1,size:t="md",isActive:n,className:r,...o},s)=>{const i=e?Ht.Slot:"a";return a.jsx(i,{ref:s,"data-sidebar":"menu-sub-button","data-size":t,"data-active":n,className:N("tw-flex tw-h-7 tw-min-w-0 tw--translate-x-px tw-items-center tw-gap-2 tw-overflow-hidden tw-rounded-md tw-px-2 tw-text-sidebar-foreground tw-outline-none tw-ring-sidebar-ring hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground focus-visible:tw-ring-2 active:tw-bg-sidebar-accent active:tw-text-sidebar-accent-foreground disabled:tw-pointer-events-none disabled:tw-opacity-50 aria-disabled:tw-pointer-events-none aria-disabled:tw-opacity-50 [&>span:last-child]:tw-truncate [&>svg]:tw-size-4 [&>svg]:tw-shrink-0 [&>svg]:tw-text-sidebar-accent-foreground","data-[active=true]:tw-bg-sidebar-accent data-[active=true]:tw-text-sidebar-accent-foreground",t==="sm"&&"tw-text-xs",t==="md"&&"tw-text-sm","group-data-[collapsible=icon]:tw-hidden",r),...o})});od.displayName="SidebarMenuSubButton";function Hs({id:e,extensionLabels:t,projectOptions:n,handleSelectSidebarItem:r,selectedSidebarItem:o,extensionsSidebarGroupLabel:s,projectsSidebarGroupLabel:i}){const l=g.useCallback((d,m)=>{r(d,m)},[r]),c=g.useCallback(d=>{const m=n.find(w=>w.projectId===d);return m?m.projectName:d},[n]),u=g.useCallback(d=>!o.projectId&&d===o.label,[o]);return a.jsx(zs,{id:e,collapsible:"none",variant:"inset",className:"tw-w-96 tw-gap-2 tw-overflow-y-auto tw-rounded tw-bg-slate-100",children:a.jsxs(Fs,{children:[a.jsxs(Xr,{children:[a.jsx(Yr,{className:"tw-text-sm tw-text-gray-400",children:s}),a.jsx(Wr,{children:a.jsx(Gs,{children:t.map(d=>a.jsx(Us,{children:a.jsx(qs,{className:N("tw-rounded tw-py-2 tw-text-sm tw-text-gray-500 hover:tw-bg-white hover:tw-text-gray-900 hover:tw-shadow-sm active:tw-bg-white",{"tw-bg-white tw-text-gray-900 tw-shadow-sm":u(d)}),onClick:()=>l(d,void 0),isActive:u(d),children:a.jsx("span",{className:"tw-pl-3",children:d})})},d))})})]}),a.jsxs(Xr,{children:[a.jsx(Yr,{className:"tw-text-sm tw-text-gray-400",children:i}),a.jsx(Wr,{className:"tw-pl-3",children:a.jsx(Wn,{popoverContentClassName:"tw-z-[1000]",options:n.flatMap(d=>d.projectId),getOptionLabel:d=>c(d),buttonPlaceholder:"Type or select project",onChange:d=>{const m=c(d);l(m,d)},value:(o==null?void 0:o.projectId)??void 0})})]})]})})}function ad({id:e,direction:t="ltr",extensionLabels:n,projectOptions:r,children:o,handleSelectSidebarItem:s,selectedSidebarItem:i,onSearch:l,extensionsSidebarGroupLabel:c,projectsSidebarGroupLabel:u}){return a.jsxs("div",{className:"tw-flex tw-h-full tw-flex-col tw-p-3 tw-pb-2",children:[a.jsx("div",{className:"tw-flex tw-items-center tw-justify-center tw-py-4",children:a.jsx(ho,{className:"tw-w-9/12",onSearch:l,placeholder:"Search app settings, extension settings, and project settings"})}),a.jsxs(Vs,{dir:t,id:e,className:"tw-h-full tw-flex-1 tw-gap-4",children:[a.jsx(Hs,{extensionLabels:n,projectOptions:r,handleSelectSidebarItem:s,selectedSidebarItem:i,extensionsSidebarGroupLabel:c,projectsSidebarGroupLabel:u}),a.jsx(Ls,{className:"tw-overflow-y-auto",children:o})]})]})}const rt="scrBook",sd="scrRef",pt="source",id="details",ld="Scripture Reference",cd="Scripture Book",Xs="Type",dd="Details";function ud(e,t){const n=t??!1;return[{accessorFn:r=>`${ae.bookNumberToId(r.start.bookNum)} ${r.start.chapterNum}:${r.start.verseNum}`,id:rt,header:(e==null?void 0:e.scriptureReferenceColumnName)??ld,cell:r=>{const o=r.row.original;return r.row.getIsGrouped()?ae.bookNumberToEnglishName(o.start.bookNum):r.row.groupingColumnId===rt?W.formatScrRef(o.start):void 0},getGroupingValue:r=>r.start.bookNum,sortingFn:(r,o)=>W.compareScrRefs(r.original.start,o.original.start),enableGrouping:!0},{accessorFn:r=>W.formatScrRef(r.start),id:sd,header:void 0,cell:r=>{const o=r.row.original;return r.row.getIsGrouped()?void 0:W.formatScrRef(o.start)},sortingFn:(r,o)=>W.compareScrRefs(r.original.start,o.original.start),enableGrouping:!1},{accessorFn:r=>r.source.displayName,id:pt,header:n?(e==null?void 0:e.typeColumnName)??Xs:void 0,cell:r=>n||r.row.getIsGrouped()?r.getValue():void 0,getGroupingValue:r=>r.source.id,sortingFn:(r,o)=>r.original.source.displayName.localeCompare(o.original.source.displayName),enableGrouping:!0},{accessorFn:r=>r.detail,id,header:(e==null?void 0:e.detailsColumnName)??dd,cell:r=>r.getValue(),enableGrouping:!1}]}const pd=e=>{if(!("offset"in e.start))throw new Error("No offset available in range start");if(e.end&&!("offset"in e.end))throw new Error("No offset available in range end");const{offset:t}=e.start;let n=0;return e.end&&({offset:n}=e.end),!e.end||W.compareScrRefs(e.start,e.end)===0?`${W.scrRefToBBBCCCVVV(e.start)}+${t}`:`${W.scrRefToBBBCCCVVV(e.start)}+${t}-${W.scrRefToBBBCCCVVV(e.end)}+${n}`},ia=e=>`${pd({start:e.start,end:e.end})} ${e.source.displayName} ${e.detail}`;function wd({sources:e,showColumnHeaders:t=!1,showSourceColumn:n=!1,scriptureReferenceColumnName:r,scriptureBookGroupName:o,typeColumnName:s,detailsColumnName:i,onRowSelected:l,direction:c="ltr"}){const[u,d]=g.useState([]),[m,w]=g.useState([{id:rt,desc:!1}]),[b,x]=g.useState({}),f=g.useMemo(()=>e.flatMap(C=>C.data.map(_=>({..._,source:C.source}))),[e]),h=g.useMemo(()=>ud({scriptureReferenceColumnName:r,typeColumnName:s,detailsColumnName:i},n),[r,s,i,n]);g.useEffect(()=>{u.includes(pt)?w([{id:pt,desc:!1},{id:rt,desc:!1}]):w([{id:rt,desc:!1}])},[u]);const S=Se.useReactTable({data:f,columns:h,state:{grouping:u,sorting:m,rowSelection:b},onGroupingChange:d,onSortingChange:w,onRowSelectionChange:x,getExpandedRowModel:Se.getExpandedRowModel(),getGroupedRowModel:Se.getGroupedRowModel(),getCoreRowModel:Se.getCoreRowModel(),getSortedRowModel:Se.getSortedRowModel(),getRowId:ia,autoResetExpanded:!1,enableMultiRowSelection:!1,enableSubRowSelection:!1});g.useEffect(()=>{if(l){const C=S.getSelectedRowModel().rowsById,_=Object.keys(C);if(_.length===1){const k=f.find(D=>ia(D)===_[0])||void 0;k&&l(k)}}},[b,f,l,S]);const R=o??cd,j=s??Xs,E=[{label:"No Grouping",value:[]},{label:`Group by ${R}`,value:[rt]},{label:`Group by ${j}`,value:[pt]},{label:`Group by ${R} and ${j}`,value:[rt,pt]},{label:`Group by ${j} and ${R}`,value:[pt,rt]}],v=C=>{d(JSON.parse(C))},P=(C,_)=>{!C.getIsGrouped()&&!C.getIsSelected()&&C.getToggleSelectedHandler()(_)},V=(C,_)=>C.getIsGrouped()?"":N("banded-row",_%2===0?"even":"odd"),U=(C,_,k)=>{if(!((C==null?void 0:C.length)===0||_.depth{v(C)},children:[a.jsx(bt,{className:"tw-mb-1 tw-mt-2",children:a.jsx(Bt,{})}),a.jsx(vt,{position:"item-aligned",children:a.jsx(ks,{children:E.map(C=>a.jsx(Ae,{value:JSON.stringify(C.value),children:C.label},C.label))})})]}),a.jsxs(Cn,{className:"tw-relative tw-flex tw-flex-col tw-overflow-y-auto tw-p-0",children:[t&&a.jsx(Tn,{children:S.getHeaderGroups().map(C=>a.jsx(Ze,{children:C.headers.filter(_=>_.column.columnDef.header).map(_=>a.jsx(Vt,{colSpan:_.colSpan,className:"top-0 tw-sticky",children:_.isPlaceholder?void 0:a.jsxs("div",{children:[_.column.getCanGroup()?a.jsx(fe,{variant:"ghost",title:`Toggle grouping by ${_.column.columnDef.header}`,onClick:_.column.getToggleGroupingHandler(),type:"button",children:_.column.getIsGrouped()?"🛑":"👊 "}):void 0," ",Se.flexRender(_.column.columnDef.header,_.getContext())]})},_.id))},C.id))}),a.jsx(Rn,{children:S.getRowModel().rows.map((C,_)=>a.jsx(Ze,{"data-state":C.getIsSelected()?"selected":"",className:N(V(C,_)),onClick:k=>P(C,k),children:C.getVisibleCells().map(k=>{if(!(k.getIsPlaceholder()||k.column.columnDef.enableGrouping&&!k.getIsGrouped()&&(k.column.columnDef.id!==pt||!n)))return a.jsx(xt,{className:N(k.column.columnDef.id,"tw-p-[1px]",U(u,C,k)),children:(()=>k.getIsGrouped()?a.jsxs(fe,{variant:"link",onClick:C.getToggleExpandedHandler(),type:"button",children:[C.getIsExpanded()&&a.jsx(Q.ChevronDown,{}),!C.getIsExpanded()&&(c==="ltr"?a.jsx(Q.ChevronRight,{}):a.jsx(Q.ChevronLeft,{}))," ",Se.flexRender(k.column.columnDef.cell,k.getContext())," (",C.subRows.length,")"]}):Se.flexRender(k.column.columnDef.cell,k.getContext()))()},k.id)})},C.id))})]})]})}const _r={[W.getLocalizeKeyForScrollGroupId("undefined")]:"Ø",[W.getLocalizeKeyForScrollGroupId(0)]:"A",[W.getLocalizeKeyForScrollGroupId(1)]:"B",[W.getLocalizeKeyForScrollGroupId(2)]:"C",[W.getLocalizeKeyForScrollGroupId(3)]:"D",[W.getLocalizeKeyForScrollGroupId(4)]:"E",[W.getLocalizeKeyForScrollGroupId(5)]:"F",[W.getLocalizeKeyForScrollGroupId(6)]:"G",[W.getLocalizeKeyForScrollGroupId(7)]:"H",[W.getLocalizeKeyForScrollGroupId(8)]:"I",[W.getLocalizeKeyForScrollGroupId(9)]:"J",[W.getLocalizeKeyForScrollGroupId(10)]:"K",[W.getLocalizeKeyForScrollGroupId(11)]:"L",[W.getLocalizeKeyForScrollGroupId(12)]:"M",[W.getLocalizeKeyForScrollGroupId(13)]:"N",[W.getLocalizeKeyForScrollGroupId(14)]:"O",[W.getLocalizeKeyForScrollGroupId(15)]:"P",[W.getLocalizeKeyForScrollGroupId(16)]:"Q",[W.getLocalizeKeyForScrollGroupId(17)]:"R",[W.getLocalizeKeyForScrollGroupId(18)]:"S",[W.getLocalizeKeyForScrollGroupId(19)]:"T",[W.getLocalizeKeyForScrollGroupId(20)]:"U",[W.getLocalizeKeyForScrollGroupId(21)]:"V",[W.getLocalizeKeyForScrollGroupId(22)]:"W",[W.getLocalizeKeyForScrollGroupId(23)]:"X",[W.getLocalizeKeyForScrollGroupId(24)]:"Y",[W.getLocalizeKeyForScrollGroupId(25)]:"Z"};function fd({availableScrollGroupIds:e,scrollGroupId:t,onChangeScrollGroupId:n,localizedStrings:r={}}){const o={..._r,...Object.fromEntries(Object.entries(r).map(([s,i])=>[s,s===i&&s in _r?_r[s]:i]))};return a.jsxs(At,{value:`${t}`,onValueChange:s=>n(s==="undefined"?void 0:parseInt(s,10)),children:[a.jsx(bt,{className:"pr-twp tw-w-auto",children:a.jsx(Bt,{placeholder:o[W.getLocalizeKeyForScrollGroupId(t)]??t})}),a.jsx(vt,{style:{zIndex:250},children:e.map(s=>a.jsx(Ae,{value:`${s}`,children:o[W.getLocalizeKeyForScrollGroupId(s)]},`${s}`))})]})}function md({children:e}){return a.jsx("div",{className:"pr-twp tw-grid",children:e})}function hd({primary:e,secondary:t,children:n,isLoading:r=!1,loadingMessage:o}){return a.jsxs("div",{className:"tw-flex tw-items-center tw-justify-between tw-space-x-4 tw-py-2",children:[a.jsxs("div",{children:[a.jsx("p",{className:"tw-text-sm tw-font-medium tw-leading-none",children:e}),a.jsx("p",{className:"tw-whitespace-normal tw-break-words tw-text-sm tw-text-muted-foreground",children:t})]}),r?a.jsx("p",{className:"tw-text-sm tw-text-muted-foreground",children:o}):a.jsx("div",{children:n})]})}function gd({primary:e,secondary:t,includeSeparator:n=!1}){return a.jsxs("div",{className:"tw-space-y-4 tw-py-2",children:[a.jsxs("div",{children:[a.jsx("h3",{className:"tw-text-lg tw-font-medium",children:e}),a.jsx("p",{className:"tw-text-sm tw-text-muted-foreground",children:t})]}),n?a.jsx(lr,{}):""]})}function bd({id:e,className:t,listItems:n,selectedListItems:r,handleSelectListItem:o,createLabel:s}){return a.jsx("div",{id:e,className:t,children:n.map(i=>a.jsxs("div",{className:"tw-m-2 tw-flex tw-items-center",children:[a.jsx(sr,{className:"tw-mr-2 tw-align-middle",checked:r.includes(i),onCheckedChange:l=>o(i,l)}),a.jsx(qe,{children:s?s(i):i})]},i))})}function vd(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}function xd(e){if(e.__esModule)return e;var t=e.default;if(typeof t=="function"){var n=function r(){return this instanceof r?Reflect.construct(t,arguments,this.constructor):t.apply(this,arguments)};n.prototype=t.prototype}else n={};return Object.defineProperty(n,"__esModule",{value:!0}),Object.keys(e).forEach(function(r){var o=Object.getOwnPropertyDescriptor(e,r);Object.defineProperty(n,r,o.get?o:{enumerable:!0,get:function(){return e[r]}})}),n}var xo={},Ys={exports:{}};(function(e){function t(n){return n&&n.__esModule?n:{default:n}}e.exports=t,e.exports.__esModule=!0,e.exports.default=e.exports})(Ys);var yd=Ys.exports,Pr={};function yo(e,t){return process.env.NODE_ENV==="production"?()=>null:function(...r){return e(...r)||t(...r)}}function O(){return O=Object.assign?Object.assign.bind():function(e){for(var t=1;t{t[n]=Ws(e[n])}),t}function Qe(e,t,n={clone:!0}){const r=n.clone?O({},e):e;return mt(e)&&mt(t)&&Object.keys(t).forEach(o=>{o!=="__proto__"&&(mt(t[o])&&o in e&&mt(e[o])?r[o]=Qe(e[o],t[o],n):n.clone?r[o]=mt(t[o])?Ws(t[o]):t[o]:r[o]=t[o])}),r}var Kr={exports:{}},zn={exports:{}},ie={};/** @license React v16.13.1 +"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const a=require("react/jsx-runtime"),g=require("react"),Q=require("lucide-react"),ot=require("clsx"),ml=require("tailwind-merge"),Za=require("@radix-ui/react-dropdown-menu"),W=require("platform-bible-utils"),Ht=require("@radix-ui/react-slot"),Xt=require("class-variance-authority"),hl=require("@radix-ui/react-label"),gl=require("@radix-ui/react-radio-group"),bl=require("@radix-ui/react-popover"),Re=require("cmdk"),vl=require("@radix-ui/react-dialog"),Se=require("@tanstack/react-table"),xl=require("@radix-ui/react-select"),yl=require("@radix-ui/react-checkbox"),Nl=require("@radix-ui/react-toggle-group"),kl=require("@radix-ui/react-toggle"),Sl=require("@radix-ui/react-tabs"),El=require("@radix-ui/react-separator"),jl=require("@radix-ui/react-tooltip"),Gr=require("@mui/styled-engine"),Me=require("@mui/material"),ln=require("react-dom"),Qa=require("sonner"),Cl=require("@radix-ui/react-slider"),Tl=require("@radix-ui/react-switch"),Rl=require("markdown-to-jsx");function ke(e){const t=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(e){for(const n in e)if(n!=="default"){const r=Object.getOwnPropertyDescriptor(e,n);Object.defineProperty(t,n,r.get?r:{enumerable:!0,get:()=>e[n]})}}return t.default=e,Object.freeze(t)}const M=ke(g),pe=ke(Za),es=ke(hl),bn=ke(gl),vn=ke(bl),be=ke(vl),ge=ke(xl),Ur=ke(yl),rr=ke(Nl),ts=ke(kl),Oe=ke(Sl),ns=ke(El),Sn=ke(jl),Ol=ke(ln),cn=ke(Cl),qr=ke(Tl);const _l=ml.extendTailwindMerge({prefix:"tw-"});function N(...e){return _l(ot.clsx(e))}const St=g.forwardRef(({className:e,type:t,...n},r)=>a.jsx("input",{type:t,className:N("pr-twp tw-flex tw-h-10 tw-rounded-md tw-border tw-border-input tw-bg-background tw-px-3 tw-py-2 tw-text-sm tw-ring-offset-background file:tw-border-0 file:tw-bg-transparent file:tw-text-sm file:tw-font-medium file:tw-text-foreground placeholder:tw-text-muted-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-cursor-not-allowed disabled:tw-opacity-50",e),ref:r,...n}));St.displayName="Input";const Pl=g.forwardRef(({handleSearch:e,handleKeyDown:t,handleOnClick:n,handleSubmit:r,...o},s)=>a.jsxs("div",{className:"tw-relative",children:[a.jsx(St,{...o,type:"text",className:"tw-box-border tw-gap-2.5 tw-rounded-lg tw-border tw-border-solid tw-bg-background tw-py-2 tw-pl-4 tw-pr-3 tw-font-medium tw-shadow-none tw-outline-none",onChange:i=>e(i.target.value),onKeyDown:i=>{i.key==="Enter"&&r(),t(i)},onClick:n,ref:s}),a.jsx(Q.History,{className:"tw-absolute tw-right-3 tw-top-1/2 tw-h-4 tw-w-4 tw--translate-y-1/2 tw-transform tw-cursor-pointer tw-text-muted-foreground",onClick:()=>{console.log("back in history")}})]}));var Il=Object.defineProperty,Ml=(e,t,n)=>t in e?Il(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,ne=(e,t,n)=>Ml(e,typeof t!="symbol"?t+"":t,n);const gt=["GEN","EXO","LEV","NUM","DEU","JOS","JDG","RUT","1SA","2SA","1KI","2KI","1CH","2CH","EZR","NEH","EST","JOB","PSA","PRO","ECC","SNG","ISA","JER","LAM","EZK","DAN","HOS","JOL","AMO","OBA","JON","MIC","NAM","HAB","ZEP","HAG","ZEC","MAL","MAT","MRK","LUK","JHN","ACT","ROM","1CO","2CO","GAL","EPH","PHP","COL","1TH","2TH","1TI","2TI","TIT","PHM","HEB","JAS","1PE","2PE","1JN","2JN","3JN","JUD","REV","TOB","JDT","ESG","WIS","SIR","BAR","LJE","S3Y","SUS","BEL","1MA","2MA","3MA","4MA","1ES","2ES","MAN","PS2","ODA","PSS","JSA","JDB","TBS","SST","DNT","BLT","XXA","XXB","XXC","XXD","XXE","XXF","XXG","FRT","BAK","OTH","3ES","EZA","5EZ","6EZ","INT","CNC","GLO","TDX","NDX","DAG","PS3","2BA","LBA","JUB","ENO","1MQ","2MQ","3MQ","REP","4BA","LAO"],ao=["XXA","XXB","XXC","XXD","XXE","XXF","XXG","FRT","BAK","OTH","INT","CNC","GLO","TDX","NDX"],rs=["Genesis","Exodus","Leviticus","Numbers","Deuteronomy","Joshua","Judges","Ruth","1 Samuel","2 Samuel","1 Kings","2 Kings","1 Chronicles","2 Chronicles","Ezra","Nehemiah","Esther (Hebrew)","Job","Psalms","Proverbs","Ecclesiastes","Song of Songs","Isaiah","Jeremiah","Lamentations","Ezekiel","Daniel (Hebrew)","Hosea","Joel","Amos","Obadiah","Jonah","Micah","Nahum","Habakkuk","Zephaniah","Haggai","Zechariah","Malachi","Matthew","Mark","Luke","John","Acts","Romans","1 Corinthians","2 Corinthians","Galatians","Ephesians","Philippians","Colossians","1 Thessalonians","2 Thessalonians","1 Timothy","2 Timothy","Titus","Philemon","Hebrews","James","1 Peter","2 Peter","1 John","2 John","3 John","Jude","Revelation","Tobit","Judith","Esther Greek","Wisdom of Solomon","Sirach (Ecclesiasticus)","Baruch","Letter of Jeremiah","Song of 3 Young Men","Susanna","Bel and the Dragon","1 Maccabees","2 Maccabees","3 Maccabees","4 Maccabees","1 Esdras (Greek)","2 Esdras (Latin)","Prayer of Manasseh","Psalm 151","Odes","Psalms of Solomon","Joshua A. *obsolete*","Judges B. *obsolete*","Tobit S. *obsolete*","Susanna Th. *obsolete*","Daniel Th. *obsolete*","Bel Th. *obsolete*","Extra A","Extra B","Extra C","Extra D","Extra E","Extra F","Extra G","Front Matter","Back Matter","Other Matter","3 Ezra *obsolete*","Apocalypse of Ezra","5 Ezra (Latin Prologue)","6 Ezra (Latin Epilogue)","Introduction","Concordance ","Glossary ","Topical Index","Names Index","Daniel Greek","Psalms 152-155","2 Baruch (Apocalypse)","Letter of Baruch","Jubilees","Enoch","1 Meqabyan","2 Meqabyan","3 Meqabyan","Reproof (Proverbs 25-31)","4 Baruch (Rest of Baruch)","Laodiceans"],ra=Ul();function Yt(e,t=!0){return t&&(e=e.toUpperCase()),e in ra?ra[e]:0}function so(e){return Yt(e)>0}function $l(e){const t=typeof e=="string"?Yt(e):e;return t>=40&&t<=66}function Dl(e){return(typeof e=="string"?Yt(e):e)<=39}function os(e){return e<=66}function Al(e){const t=typeof e=="string"?Yt(e):e;return is(t)&&!os(t)}function*Bl(){for(let e=1;e<=gt.length;e++)yield e}const Vl=1,as=gt.length;function zl(){return["XXA","XXB","XXC","XXD","XXE","XXF","XXG"]}function io(e,t="***"){const n=e-1;return n<0||n>=gt.length?t:gt[n]}function ss(e){return e<=0||e>as?"******":rs[e-1]}function Ll(e){return ss(Yt(e))}function is(e){const t=typeof e=="number"?io(e):e;return so(t)&&!ao.includes(t)}function Fl(e){const t=typeof e=="number"?io(e):e;return so(t)&&ao.includes(t)}function Gl(e){return rs[e-1].includes("*obsolete*")}function Ul(){const e={};for(let t=0;t(e[e.Unknown=0]="Unknown",e[e.Original=1]="Original",e[e.Septuagint=2]="Septuagint",e[e.Vulgate=3]="Vulgate",e[e.English=4]="English",e[e.RussianProtestant=5]="RussianProtestant",e[e.RussianOrthodox=6]="RussianOrthodox",e))(He||{});const Pe=class{constructor(t){if(ne(this,"name"),ne(this,"fullPath"),ne(this,"isPresent"),ne(this,"hasVerseSegments"),ne(this,"isCustomized"),ne(this,"baseVersification"),ne(this,"scriptureBooks"),ne(this,"_type"),t==null)throw new Error("Argument undefined");typeof t=="string"?(this.name=t,this._type=He[t]):(this._type=t,this.name=He[t])}get type(){return this._type}equals(t){return!t.type||!this.type?!1:t.type===this.type}};ne(Pe,"Original",new Pe(He.Original)),ne(Pe,"Septuagint",new Pe(He.Septuagint)),ne(Pe,"Vulgate",new Pe(He.Vulgate)),ne(Pe,"English",new Pe(He.English)),ne(Pe,"RussianProtestant",new Pe(He.RussianProtestant)),ne(Pe,"RussianOrthodox",new Pe(He.RussianOrthodox));let ut=Pe;function oa(e,t){const n=t[0];for(let r=1;r(e[e.Valid=0]="Valid",e[e.UnknownVersification=1]="UnknownVersification",e[e.OutOfRange=2]="OutOfRange",e[e.VerseOutOfOrder=3]="VerseOutOfOrder",e[e.VerseRepeated=4]="VerseRepeated",e))(ls||{});const je=class re{constructor(t,n,r,o){if(ne(this,"firstChapter"),ne(this,"lastChapter"),ne(this,"lastVerse"),ne(this,"hasSegmentsDefined"),ne(this,"text"),ne(this,"BBBCCCVVVS"),ne(this,"longHashCode"),ne(this,"versification"),ne(this,"rtlMark","‏"),ne(this,"_bookNum",0),ne(this,"_chapterNum",0),ne(this,"_verseNum",0),ne(this,"_verse"),r==null&&o==null)if(t!=null&&typeof t=="string"){const s=t,i=n!=null&&n instanceof ut?n:void 0;this.setEmpty(i),this.parse(s)}else if(t!=null&&typeof t=="number"){const s=n!=null&&n instanceof ut?n:void 0;this.setEmpty(s),this._verseNum=t%re.chapterDigitShifter,this._chapterNum=Math.floor(t%re.bookDigitShifter/re.chapterDigitShifter),this._bookNum=Math.floor(t/re.bookDigitShifter)}else if(n==null)if(t!=null&&t instanceof re){const s=t;this._bookNum=s.bookNum,this._chapterNum=s.chapterNum,this._verseNum=s.verseNum,this._verse=s.verse,this.versification=s.versification}else{if(t==null)return;const s=t instanceof ut?t:re.defaultVersification;this.setEmpty(s)}else throw new Error("VerseRef constructor not supported.");else if(t!=null&&n!=null&&r!=null)if(typeof t=="string"&&typeof n=="string"&&typeof r=="string")this.setEmpty(o),this.updateInternal(t,n,r);else if(typeof t=="number"&&typeof n=="number"&&typeof r=="number")this._bookNum=t,this._chapterNum=n,this._verseNum=r,this.versification=o??re.defaultVersification;else throw new Error("VerseRef constructor not supported.");else throw new Error("VerseRef constructor not supported.")}static isVerseParseable(t){return t.length>0&&"0123456789".includes(t[0])&&!t.endsWith(this.verseRangeSeparator)&&!t.endsWith(this.verseSequenceIndicator)}static tryParse(t){let n;try{return n=new re(t),{success:!0,verseRef:n}}catch(r){if(r instanceof nn)return n=new re,{success:!1,verseRef:n};throw r}}static getBBBCCCVVV(t,n,r){return t%re.bcvMaxValue*re.bookDigitShifter+(n>=0?n%re.bcvMaxValue*re.chapterDigitShifter:0)+(r>=0?r%re.bcvMaxValue:0)}static fromJSON(t){const{book:n,chapterNum:r,verseNum:o,verse:s,versificationStr:i}=t,l=s||o.toString();let c;return i&&(c=new ut(i)),n?new re(n,r.toString(),l,c):new re}static tryGetVerseNum(t){let n;if(!t)return n=-1,{success:!0,vNum:n};n=0;let r;for(let o=0;o"9")return o===0&&(n=-1),{success:!1,vNum:n};if(n=n*10+ +r-0,n>re.bcvMaxValue)return n=-1,{success:!1,vNum:n}}return{success:!0,vNum:n}}get isDefault(){return this.bookNum===0&&this.chapterNum===0&&this.verseNum===0&&this.versification==null}get hasMultiple(){return this._verse!=null&&(this._verse.includes(re.verseRangeSeparator)||this._verse.includes(re.verseSequenceIndicator))}get book(){return ae.bookNumberToId(this.bookNum,"")}set book(t){this.bookNum=ae.bookIdToNumber(t)}get chapter(){return this.isDefault||this._chapterNum<0?"":this._chapterNum.toString()}set chapter(t){const n=+t;this._chapterNum=Number.isInteger(n)?n:-1}get verse(){return this._verse!=null?this._verse:this.isDefault||this._verseNum<0?"":this._verseNum.toString()}set verse(t){const{success:n,vNum:r}=re.tryGetVerseNum(t);this._verse=n?void 0:t.replace(this.rtlMark,""),this._verseNum=r,!(this._verseNum>=0)&&({vNum:this._verseNum}=re.tryGetVerseNum(this._verse))}get bookNum(){return this._bookNum}set bookNum(t){if(t<=0||t>ae.lastBook)throw new nn("BookNum must be greater than zero and less than or equal to last book");this._bookNum=t}get chapterNum(){return this._chapterNum}set chapterNum(t){this.chapterNum=t}get verseNum(){return this._verseNum}set verseNum(t){this._verseNum=t}get versificationStr(){var t;return(t=this.versification)==null?void 0:t.name}set versificationStr(t){this.versification=this.versification!=null?new ut(t):void 0}get valid(){return this.validStatus===0}get validStatus(){return this.validateVerse(re.verseRangeSeparators,re.verseSequenceIndicators)}get BBBCCC(){return re.getBBBCCCVVV(this._bookNum,this._chapterNum,0)}get BBBCCCVVV(){return re.getBBBCCCVVV(this._bookNum,this._chapterNum,this._verseNum)}get isExcluded(){return!1}parse(t){if(t=t.replace(this.rtlMark,""),t.includes("/")){const s=t.split("/");if(t=s[0],s.length>1)try{const i=+s[1].trim();this.versification=new ut(He[i])}catch{throw new nn("Invalid reference : "+t)}}const n=t.trim().split(" ");if(n.length!==2)throw new nn("Invalid reference : "+t);const r=n[1].split(":"),o=+r[0];if(r.length!==2||ae.bookIdToNumber(n[0])===0||!Number.isInteger(o)||o<0||!re.isVerseParseable(r[1]))throw new nn("Invalid reference : "+t);this.updateInternal(n[0],r[0],r[1])}simplify(){this._verse=void 0}clone(){return new re(this)}toString(){const t=this.book;return t===""?"":`${t} ${this.chapter}:${this.verse}`}toJSON(){let t=this.verse;(t===""||t===this.verseNum.toString())&&(t=void 0);const n={book:this.book,chapterNum:this.chapterNum,verseNum:this.verseNum,verse:t,versificationStr:this.versificationStr};return t||delete n.verse,n}equals(t){return t instanceof re?t._bookNum===this._bookNum&&t._chapterNum===this._chapterNum&&t._verseNum===this._verseNum&&t.verse===this.verse&&(t.versification==null&&this.versification==null||t.versification!=null&&this.versification!=null&&t.versification.equals(this.versification)):!1}allVerses(t=!1,n=re.verseRangeSeparators,r=re.verseSequenceIndicators){if(this._verse==null||this.chapterNum<=0)return[this.clone()];const o=[],s=oa(this._verse,r);for(const i of s.map(l=>oa(l,n))){const l=this.clone();l.verse=i[0];const c=l.verseNum;if(o.push(l),i.length>1){const d=this.clone();if(d.verse=i[1],!t)for(let u=c+1;ui)return 3;if(r===i)return 4;r=i}return 0}get internalValid(){return this.versification==null?1:this._bookNum<=0||this._bookNum>ae.lastBook?2:(ae.isCanonical(this._bookNum),0)}setEmpty(t=re.defaultVersification){this._bookNum=0,this._chapterNum=-1,this._verse=void 0,this.versification=t}updateInternal(t,n,r){this.bookNum=ae.bookIdToNumber(t),this.chapter=n,this.verse=r}};ne(je,"defaultVersification",ut.English),ne(je,"verseRangeSeparator","-"),ne(je,"verseSequenceIndicator",","),ne(je,"verseRangeSeparators",[je.verseRangeSeparator]),ne(je,"verseSequenceIndicators",[je.verseSequenceIndicator]),ne(je,"chapterDigitShifter",1e3),ne(je,"bookDigitShifter",je.chapterDigitShifter*je.chapterDigitShifter),ne(je,"bcvMaxValue",je.chapterDigitShifter-1),ne(je,"ValidStatusType",ls);class nn extends Error{}const or=pe.Root,lo=pe.Trigger,cs=pe.Group,ql=pe.Portal,Hl=pe.Sub,Xl=pe.RadioGroup,ds=g.forwardRef(({className:e,inset:t,children:n,...r},o)=>a.jsxs(pe.SubTrigger,{ref:o,className:N("tw-flex tw-cursor-default tw-select-none tw-items-center tw-rounded-sm tw-px-2 tw-py-1.5 tw-text-sm tw-outline-none focus:tw-bg-accent data-[state=open]:tw-bg-accent",t&&"tw-pl-8",e),...r,children:[n,a.jsx(Q.ChevronRight,{className:"tw-ml-auto tw-h-4 tw-w-4"})]}));ds.displayName=pe.SubTrigger.displayName;const us=g.forwardRef(({className:e,...t},n)=>a.jsx(pe.SubContent,{ref:n,className:N("tw-z-50 tw-min-w-[8rem] tw-overflow-hidden tw-rounded-md tw-border tw-bg-popover tw-p-1 tw-text-popover-foreground tw-shadow-lg data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0 data-[state=closed]:tw-zoom-out-95 data-[state=open]:tw-zoom-in-95 data-[side=bottom]:tw-slide-in-from-top-2 data-[side=left]:tw-slide-in-from-right-2 data-[side=right]:tw-slide-in-from-left-2 data-[side=top]:tw-slide-in-from-bottom-2",e),...t}));us.displayName=pe.SubContent.displayName;const En=g.forwardRef(({className:e,sideOffset:t=4,...n},r)=>a.jsx(pe.Portal,{children:a.jsx(pe.Content,{ref:r,sideOffset:t,className:N("pr-twp tw-z-50 tw-min-w-[8rem] tw-overflow-hidden tw-rounded-md tw-border tw-bg-popover tw-p-1 tw-text-popover-foreground tw-shadow-md data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0 data-[state=closed]:tw-zoom-out-95 data-[state=open]:tw-zoom-in-95 data-[side=bottom]:tw-slide-in-from-top-2 data-[side=left]:tw-slide-in-from-right-2 data-[side=right]:tw-slide-in-from-left-2 data-[side=top]:tw-slide-in-from-bottom-2",e),...n})}));En.displayName=pe.Content.displayName;const co=g.forwardRef(({className:e,inset:t,...n},r)=>a.jsx(pe.Item,{ref:r,className:N("tw-cursor-default tw-select-none tw-items-center tw-rounded-sm tw-px-2 tw-py-1.5 tw-text-sm tw-outline-none tw-transition-colors focus:tw-bg-accent data-[disabled]:tw-pointer-events-none data-[disabled]:tw-opacity-50",t&&"tw-pl-8",e),...n}));co.displayName=pe.Item.displayName;const ar=g.forwardRef(({className:e,children:t,checked:n,...r},o)=>a.jsxs(pe.CheckboxItem,{ref:o,className:N("tw-relative tw-flex tw-cursor-default tw-select-none tw-items-center tw-rounded-sm tw-py-1.5 tw-pl-8 tw-pr-2 tw-text-sm tw-outline-none tw-transition-colors focus:tw-bg-accent focus:tw-text-accent-foreground data-[disabled]:tw-pointer-events-none data-[disabled]:tw-opacity-50",e),checked:n,...r,children:[a.jsx("span",{className:"tw-absolute tw-left-2 tw-flex tw-h-3.5 tw-w-3.5 tw-items-center tw-justify-center",children:a.jsx(pe.ItemIndicator,{children:a.jsx(Q.Check,{className:"tw-h-4 tw-w-4"})})}),t]}));ar.displayName=pe.CheckboxItem.displayName;const uo=g.forwardRef(({className:e,children:t,...n},r)=>a.jsxs(pe.RadioItem,{ref:r,className:N("tw-relative tw-flex tw-cursor-default tw-select-none tw-items-center tw-rounded-sm tw-py-1.5 tw-pl-8 tw-pr-2 tw-text-sm tw-outline-none tw-transition-colors focus:tw-bg-accent focus:tw-text-accent-foreground data-[disabled]:tw-pointer-events-none data-[disabled]:tw-opacity-50",e),...n,children:[a.jsx("span",{className:"tw-absolute tw-left-2 tw-flex tw-h-3.5 tw-w-3.5 tw-items-center tw-justify-center",children:a.jsx(pe.ItemIndicator,{children:a.jsx(Q.Circle,{className:"tw-h-2 tw-w-2 tw-fill-current"})})}),t]}));uo.displayName=pe.RadioItem.displayName;const Wt=g.forwardRef(({className:e,inset:t,...n},r)=>a.jsx(pe.Label,{ref:r,className:N("tw-px-2 tw-py-1.5 tw-text-sm tw-font-semibold",t&&"tw-pl-8",e),...n}));Wt.displayName=pe.Label.displayName;const jn=g.forwardRef(({className:e,...t},n)=>a.jsx(pe.Separator,{ref:n,className:N("tw--mx-1 tw-my-1 tw-h-px tw-bg-muted",e),...t}));jn.displayName=pe.Separator.displayName;function ps({className:e,...t}){return a.jsx("span",{className:N("tw-ml-auto tw-text-xs tw-tracking-widest tw-opacity-60",e),...t})}ps.displayName="DropdownMenuShortcut";const Yl=g.forwardRef(({bookId:e,handleSelectBook:t,isSelected:n,handleHighlightBook:r,handleKeyDown:o,bookType:s,children:i},l)=>a.jsxs(co,{ref:l,textValue:e,className:N("tw-mx-1 tw-px-1 tw-font-normal tw-text-foreground/80",{"tw-bg-amber-50 tw-text-yellow-900 data-[highlighted]:tw-bg-amber-100":n}),onSelect:c=>{c.preventDefault(),t()},onKeyDown:c=>{o(c)},onFocus:r,onMouseMove:r,children:[a.jsx("span",{className:N("tw-border-b-0 tw-border-l-2 tw-border-r-0 tw-border-t-0 tw-border-solid tw-px-2",{"tw-font-bold":n,"tw-border-l-red-200":s.toLowerCase()==="ot","tw-border-l-purple-200":s.toLowerCase()==="nt","tw-border-l-indigo-200":s.toLowerCase()==="dc"}),children:ae.bookIdToEnglishName(e)}),n&&a.jsx("div",{children:i})]},e));function Wl({handleSelectChapter:e,endChapter:t,activeChapter:n,highlightedChapter:r,handleHighlightedChapter:o}){const s=Array.from({length:t},(l,c)=>c+1),i=g.useCallback(l=>{o(l)},[o]);return a.jsx("div",{className:N("tw-flex tw-flex-wrap tw-items-start tw-justify-start tw-self-stretch"),children:s.map(l=>a.jsx("div",{className:N("tw-box-content tw-flex tw-h-4 tw-w-4 tw-cursor-pointer tw-items-center tw-justify-end tw-rounded-md tw-p-2 tw-text-amber-800",{"tw-font-semibold tw-text-amber-900":l===n,"tw-bg-amber-200":l===r}),onClick:c=>{c.preventDefault(),c.stopPropagation(),e(l)},role:"button",onKeyDown:c=>{c.key==="Enter"&&e(l)},tabIndex:0,onMouseMove:()=>i(l),children:l},l))})}function Kl({handleSort:e,handleLocationHistory:t,handleBookmarks:n}){return a.jsxs(Wt,{className:"tw-flex tw-justify-between",children:[a.jsx("p",{className:"tw-inline-block tw-align-middle",children:"Go To"}),a.jsxs("div",{className:"tw-flex tw-items-center",children:[a.jsx(Q.ArrowDownWideNarrow,{onClick:e,className:"tw-m-2 tw-h-4 tw-w-4 tw-cursor-pointer tw-gap-2"}),a.jsx(Q.Clock,{onClick:t,className:"tw-m-2 tw-h-4 tw-w-4 tw-cursor-pointer tw-gap-2"}),a.jsx(Q.Bookmark,{onClick:n,className:"tw-m-2 tw-h-4 tw-w-4 tw-cursor-pointer tw-gap-2"})]})]})}const wn=ae.allBookIds,Jl={OT:"Old Testament",NT:"New Testament",DC:"Deuterocanon"},aa=["OT","NT","DC"],Zl=32+32+32,Ql=[/^(\w+)$/i,/^(\w+)(?:\s(\d+))$/i,/^(\w+)(?:\s(\d+):(\d+))$/i],ec=e=>({OT:wn.filter(n=>ae.isBookOT(n)),NT:wn.filter(n=>ae.isBookNT(n)),DC:wn.filter(n=>ae.isBookDC(n))})[e],rn=e=>W.getChaptersForBook(ae.bookIdToNumber(e));function tc(){return wn.map(t=>ae.bookIdToEnglishName(t))}function nc(e){return tc().includes(e)}function rc(e){const t=e.toLowerCase().replace(/^\w/,n=>n.toUpperCase());if(nc(t))return wn.find(r=>ae.bookIdToEnglishName(r)===t)}function oc({scrRef:e,handleSubmit:t}){const[n,r]=g.useState(""),[o,s]=g.useState(ae.bookNumberToId(e.bookNum)),[i,l]=g.useState(e.chapterNum??0),[c,d]=g.useState(ae.bookNumberToId(e.bookNum)),[u,f]=g.useState(!1),[w,b]=g.useState(u),x=g.useRef(void 0),m=g.useRef(void 0),h=g.useRef(void 0),S=g.useCallback(k=>ec(k).filter(D=>{const $=ae.bookIdToEnglishName(D).toLowerCase(),J=n.replace(/[^a-zA-Z]/g,"").toLowerCase();return $.includes(J)||D.toLowerCase().includes(J)}),[n]),R=k=>{r(k)},j=g.useRef(!1),E=g.useCallback(k=>{if(j.current){j.current=!1;return}f(k)},[]),v=g.useCallback((k,D,$,J)=>{if(l(ae.bookNumberToId(e.bookNum)!==k?1:e.chapterNum),D||rn(k)===-1){t({bookNum:ae.bookIdToNumber(k),chapterNum:$||1,verseNum:J||1}),f(!1),r("");return}s(o!==k?k:""),f(!D)},[t,e.bookNum,e.chapterNum,o]),P=k=>{k<=0||k>rn(o)||v(o,!0,k)},V=g.useCallback(()=>{Ql.forEach(k=>{const D=n.match(k);if(D){const[$,J=void 0,Y=void 0]=D.slice(1),F=rc($);(ae.isBookIdValid($)||F)&&v(F??$,!0,J?parseInt(J,10):1,Y?parseInt(Y,10):1)}})},[v,n]),U=g.useCallback(k=>{u?(k.key==="ArrowDown"||k.key==="ArrowUp")&&(typeof h<"u"&&h.current!==null?h.current.focus():typeof m<"u"&&m.current!==null&&m.current.focus(),k.preventDefault()):f(!0)},[u]),C=k=>{const{key:D}=k;D==="ArrowRight"||D==="ArrowLeft"||D==="ArrowDown"||D==="ArrowUp"||D==="Enter"||(x.current.dispatchEvent(new KeyboardEvent("keydown",{key:D})),x.current.focus())},_=k=>{const{key:D}=k;if(c===o){if(D==="Enter"){k.preventDefault(),v(o,!0,i);return}let $=0;if(D==="ArrowRight")if(i1)$=-1;else{k.preventDefault();return}else D==="ArrowDown"?$=6:D==="ArrowUp"&&($=-6);i+$<=0||i+$>rn(c)?l(0):$!==0&&(l(i+$),k.preventDefault())}};return g.useEffect(()=>{o===c?o===ae.bookNumberToId(e.bookNum)?l(e.chapterNum):l(1):l(0)},[c,e.bookNum,e.chapterNum,o]),g.useLayoutEffect(()=>{b(u)},[u]),g.useLayoutEffect(()=>{const k=setTimeout(()=>{if(w&&m.current&&h.current){const $=h.current.offsetTop-Zl;m.current.scrollTo({top:$,behavior:"instant"})}},10);return()=>{clearTimeout(k)}},[w]),a.jsx("div",{className:"pr-twp tw-flex",children:a.jsxs(or,{modal:!1,open:u,onOpenChange:E,children:[a.jsx(lo,{asChild:!0,children:a.jsx(Pl,{ref:x,value:n,handleSearch:R,handleKeyDown:U,handleOnClick:()=>{s(ae.bookNumberToId(e.bookNum)),d(ae.bookNumberToId(e.bookNum)),l(e.chapterNum>0?e.chapterNum:0),f(!0),x.current.focus()},onFocus:()=>{j.current=!0},handleSubmit:V,placeholder:`${ae.bookNumberToEnglishName(e.bookNum)} ${e.chapterNum}:${e.verseNum}`})}),a.jsxs(En,{className:"tw-m-1 tw-overflow-y-auto tw-p-0 tw-font-normal tw-text-foreground/80",style:{width:"233px",maxHeight:"500px",zIndex:"250"},onKeyDown:C,align:"start",ref:m,children:[a.jsx(Kl,{handleSort:()=>console.log("sorting"),handleLocationHistory:()=>console.log("location history"),handleBookmarks:()=>console.log("bookmarks")}),aa.map((k,D)=>S(k).length>0&&a.jsxs("div",{children:[a.jsx(Wt,{className:"tw-font-semibold tw-text-foreground/80",children:Jl[k]}),S(k).map($=>a.jsx("div",{children:a.jsx(Yl,{bookId:$,handleSelectBook:()=>v($,!1),isSelected:o===$,handleHighlightBook:()=>d($),handleKeyDown:_,bookType:k,ref:J=>{o===$&&(h.current=J)},children:a.jsx(Wl,{handleSelectChapter:P,endChapter:rn($),activeChapter:e.bookNum===ae.bookIdToNumber($)?e.chapterNum:0,highlightedChapter:i,handleHighlightedChapter:J=>{l(J)}})})},$)),aa.length-1!==D?a.jsx(jn,{}):void 0]},k))]})]})})}const ws=Xt.cva("pr-twp tw-inline-flex tw-items-center tw-justify-center tw-whitespace-nowrap tw-rounded-md tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-colors focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50",{variants:{variant:{default:"tw-bg-primary tw-text-primary-foreground hover:tw-bg-primary/90",destructive:"tw-bg-destructive tw-text-destructive-foreground hover:tw-bg-destructive/90",outline:"tw-border tw-border-input tw-bg-background hover:tw-bg-accent hover:tw-text-accent-foreground",secondary:"tw-bg-secondary tw-text-secondary-foreground hover:tw-bg-secondary/80",ghost:"hover:tw-bg-accent hover:tw-text-accent-foreground",link:"tw-text-primary tw-underline-offset-4 hover:tw-underline"},size:{default:"tw-h-10 tw-px-4 tw-py-2",sm:"tw-h-9 tw-rounded-md tw-px-3",lg:"tw-h-11 tw-rounded-md tw-px-8",icon:"tw-h-10 tw-w-10"}},defaultVariants:{variant:"default",size:"default"}}),fe=g.forwardRef(({className:e,variant:t,size:n,asChild:r=!1,...o},s)=>{const i=r?Ht.Slot:"button";return a.jsx(i,{className:N(ws({variant:t,size:n,className:e})),ref:s,...o})});fe.displayName="Button";const ac=Xt.cva("tw-text-sm tw-font-medium tw-leading-none peer-disabled:tw-cursor-not-allowed peer-disabled:tw-opacity-70"),qe=g.forwardRef(({className:e,...t},n)=>a.jsx(es.Root,{ref:n,className:N("pr-twp",ac(),e),...t}));qe.displayName=es.Root.displayName;const po=g.forwardRef(({className:e,...t},n)=>a.jsx(bn.Root,{className:N("pr-twp tw-grid tw-gap-2",e),...t,ref:n}));po.displayName=bn.Root.displayName;const Yn=g.forwardRef(({className:e,...t},n)=>a.jsx(bn.Item,{ref:n,className:N("pr-twp tw-aspect-square tw-h-4 tw-w-4 tw-rounded-full tw-border tw-border-primary tw-text-primary tw-ring-offset-background focus:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-cursor-not-allowed disabled:tw-opacity-50",e),...t,children:a.jsx(bn.Indicator,{className:"tw-flex tw-items-center tw-justify-center",children:a.jsx(Q.Circle,{className:"tw-h-2.5 tw-w-2.5 tw-fill-current tw-text-current"})})}));Yn.displayName=bn.Item.displayName;const sc=vn.Root,ic=vn.Trigger,fs=g.forwardRef(({className:e,align:t="center",sideOffset:n=4,...r},o)=>a.jsx(vn.Portal,{children:a.jsx(vn.Content,{ref:o,align:t,sideOffset:n,className:N("pr-twp tw-z-50 tw-w-72 tw-rounded-md tw-border tw-bg-popover tw-p-4 tw-text-popover-foreground tw-shadow-md tw-outline-none data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0 data-[state=closed]:tw-zoom-out-95 data-[state=open]:tw-zoom-in-95 data-[side=bottom]:tw-slide-in-from-top-2 data-[side=left]:tw-slide-in-from-right-2 data-[side=right]:tw-slide-in-from-left-2 data-[side=top]:tw-slide-in-from-bottom-2",e),...r})}));fs.displayName=vn.Content.displayName;const lc=be.Portal,ms=g.forwardRef(({className:e,...t},n)=>a.jsx(be.Overlay,{ref:n,className:N("tw-fixed tw-inset-0 tw-z-50 tw-bg-black/80 data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0",e),...t}));ms.displayName=be.Overlay.displayName;const cc=g.forwardRef(({className:e,children:t,...n},r)=>a.jsxs(lc,{children:[a.jsx(ms,{}),a.jsxs(be.Content,{ref:r,className:N("tw-fixed tw-left-[50%] tw-top-[50%] tw-z-50 tw-grid tw-w-full tw-max-w-lg tw-translate-x-[-50%] tw-translate-y-[-50%] tw-gap-4 tw-border tw-bg-background tw-p-6 tw-shadow-lg tw-duration-200 data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0 data-[state=closed]:tw-zoom-out-95 data-[state=open]:tw-zoom-in-95 data-[state=closed]:tw-slide-out-to-left-1/2 data-[state=closed]:tw-slide-out-to-top-[48%] data-[state=open]:tw-slide-in-from-left-1/2 data-[state=open]:tw-slide-in-from-top-[48%] sm:tw-rounded-lg",e),...n,children:[t,a.jsxs(be.Close,{className:"tw-absolute tw-right-4 tw-top-4 tw-rounded-sm tw-opacity-70 tw-ring-offset-background tw-transition-opacity hover:tw-opacity-100 focus:tw-outline-none focus:tw-ring-2 focus:tw-ring-ring focus:tw-ring-offset-2 disabled:tw-pointer-events-none data-[state=open]:tw-bg-accent data-[state=open]:tw-text-muted-foreground",children:[a.jsx(Q.X,{className:"tw-h-4 tw-w-4"}),a.jsx("span",{className:"tw-sr-only",children:"Close"})]})]})]}));cc.displayName=be.Content.displayName;const dc=g.forwardRef(({className:e,...t},n)=>a.jsx(be.Title,{ref:n,className:N("tw-text-lg tw-font-semibold tw-leading-none tw-tracking-tight",e),...t}));dc.displayName=be.Title.displayName;const uc=g.forwardRef(({className:e,...t},n)=>a.jsx(be.Description,{ref:n,className:N("tw-text-sm tw-text-muted-foreground",e),...t}));uc.displayName=be.Description.displayName;const hs=g.forwardRef(({className:e,...t},n)=>a.jsx(Re.Command,{ref:n,className:N("tw-flex tw-h-full tw-w-full tw-flex-col tw-overflow-hidden tw-rounded-md tw-bg-popover tw-text-popover-foreground",e),...t}));hs.displayName=Re.Command.displayName;const gs=g.forwardRef(({className:e,...t},n)=>a.jsxs("div",{className:"tw-flex tw-items-center tw-border-b tw-px-3",children:[a.jsx(Q.Search,{className:"tw-me-2 tw-h-4 tw-w-4 tw-shrink-0 tw-opacity-50"}),a.jsx(Re.Command.Input,{ref:n,className:N("tw-flex tw-h-11 tw-w-full tw-rounded-md tw-bg-transparent tw-py-3 tw-text-sm tw-outline-none placeholder:tw-text-muted-foreground disabled:tw-cursor-not-allowed disabled:tw-opacity-50",e),...t})]}));gs.displayName=Re.Command.Input.displayName;const bs=g.forwardRef(({className:e,...t},n)=>a.jsx(Re.Command.List,{ref:n,className:N("tw-max-h-[300px] tw-overflow-y-auto tw-overflow-x-hidden",e),...t}));bs.displayName=Re.Command.List.displayName;const vs=g.forwardRef((e,t)=>a.jsx(Re.Command.Empty,{ref:t,className:"tw-py-6 tw-text-center tw-text-sm",...e}));vs.displayName=Re.Command.Empty.displayName;const pc=g.forwardRef(({className:e,...t},n)=>a.jsx(Re.Command.Group,{ref:n,className:N("tw-overflow-hidden tw-p-1 tw-text-foreground [&_[cmdk-group-heading]]:tw-px-2 [&_[cmdk-group-heading]]:tw-py-1.5 [&_[cmdk-group-heading]]:tw-text-xs [&_[cmdk-group-heading]]:tw-font-medium [&_[cmdk-group-heading]]:tw-text-muted-foreground",e),...t}));pc.displayName=Re.Command.Group.displayName;const wc=g.forwardRef(({className:e,...t},n)=>a.jsx(Re.Command.Separator,{ref:n,className:N("tw--mx-1 tw-h-px tw-bg-border",e),...t}));wc.displayName=Re.Command.Separator.displayName;const xs=g.forwardRef(({className:e,...t},n)=>a.jsx(Re.Command.Item,{ref:n,className:N("tw-relative tw-flex tw-cursor-default tw-select-none tw-items-center tw-rounded-sm tw-px-2 tw-py-1.5 tw-text-sm tw-outline-none data-[disabled=true]:tw-pointer-events-none data-[selected=true]:tw-bg-accent data-[selected=true]:tw-text-accent-foreground data-[disabled=true]:tw-opacity-50",e),...t}));xs.displayName=Re.Command.Item.displayName;function fc(e){return typeof e=="string"?e:typeof e=="number"?e.toString():e.label}function Wn({id:e,options:t=[],buttonClassName:n,popoverContentClassName:r,value:o,onChange:s=()=>{},getOptionLabel:i=fc,buttonPlaceholder:l="",textPlaceholder:c="",commandEmptyMessage:d="No option found",buttonVariant:u="outline",dir:f="ltr",isDisabled:w=!1,...b}){const[x,m]=g.useState(!1);return a.jsxs(sc,{open:x,onOpenChange:m,...b,children:[a.jsx(ic,{asChild:!0,children:a.jsxs(fe,{variant:u,role:"combobox","aria-expanded":x,id:e,className:N("tw-w-[200px] tw-justify-between",n),disabled:w,children:[a.jsx("span",{className:"tw-overflow-hidden tw-text-ellipsis tw-whitespace-nowrap",children:o?i(o):l}),a.jsx(Q.ChevronsUpDown,{className:"tw-ms-2 tw-h-4 tw-w-4 tw-shrink-0 tw-opacity-50"})]})}),a.jsx(fs,{className:N("tw-w-[200px] tw-p-0",r),dir:f,children:a.jsxs(hs,{children:[a.jsx(gs,{dir:f,placeholder:c,className:"tw-text-inherit"}),a.jsx(vs,{children:d}),a.jsx(bs,{children:t.map(h=>a.jsxs(xs,{value:i(h),onSelect:()=>{s(h),m(!1)},children:[a.jsx(Q.Check,{className:N("tw-me-2 tw-h-4 tw-w-4",{"tw-opacity-0":!o||i(o)!==i(h)})}),i(h)]},i(h)))})]})})]})}function ys({startChapter:e,endChapter:t,handleSelectStartChapter:n,handleSelectEndChapter:r,isDisabled:o=!1,chapterCount:s}){const i=g.useMemo(()=>Array.from({length:s},(d,u)=>u+1),[s]),l=d=>{n(d),d>t&&r(d)},c=d=>{r(d),dd.toString(),value:e},"start chapter"),a.jsx(qe,{htmlFor:"end-chapters-combobox",children:"to"}),a.jsx(Wn,{isDisabled:o,onChange:c,buttonClassName:"tw-ml-2 tw-w-20",options:i,getOptionLabel:d=>d.toString(),value:t},"end chapter")]})}var Ns=(e=>(e.CURRENT_BOOK="current book",e.CHOOSE_BOOKS="choose books",e))(Ns||{});const mc=Object.freeze(["%webView_bookSelector_currentBook%","%webView_bookSelector_choose%","%webView_bookSelector_chooseBooks%"]),Tr=(e,t)=>e[t]??t;function hc({handleBookSelectionModeChange:e,currentBookName:t,onSelectBooks:n,selectedBookIds:r,chapterCount:o,endChapter:s,handleSelectEndChapter:i,startChapter:l,handleSelectStartChapter:c,localizedStrings:d}){const u=Tr(d,"%webView_bookSelector_currentBook%"),f=Tr(d,"%webView_bookSelector_choose%"),w=Tr(d,"%webView_bookSelector_chooseBooks%"),[b,x]=g.useState("current book"),m=h=>{x(h),e(h)};return a.jsx(po,{className:"pr-twp tw-flex",value:b,onValueChange:h=>m(h),children:a.jsxs("div",{className:"tw-flex tw-w-full tw-flex-col tw-gap-4",children:[a.jsxs("div",{className:"tw-grid tw-grid-cols-[25%,25%,50%]",children:[a.jsxs("div",{className:"tw-flex tw-items-center",children:[a.jsx(Yn,{value:"current book"}),a.jsx(qe,{className:"tw-ml-1",children:u})]}),a.jsx(qe,{className:"tw-flex tw-items-center",children:t}),a.jsx("div",{className:"tw-flex tw-items-center tw-justify-end",children:a.jsx(ys,{isDisabled:b==="choose books",handleSelectStartChapter:c,handleSelectEndChapter:i,chapterCount:o,startChapter:l,endChapter:s})})]}),a.jsxs("div",{className:"tw-grid tw-grid-cols-[25%,50%,25%]",children:[a.jsxs("div",{className:"tw-flex tw-items-center",children:[a.jsx(Yn,{value:"choose books"}),a.jsx(qe,{className:"tw-ml-1",children:w})]}),a.jsx(qe,{className:"tw-flex tw-items-center",children:r.map(h=>ae.bookIdToEnglishName(h)).join(", ")}),a.jsx(fe,{disabled:b==="current book",onClick:()=>n(),children:f})]})]})})}function gc({table:e}){return a.jsxs(or,{children:[a.jsx(Za.DropdownMenuTrigger,{asChild:!0,children:a.jsxs(fe,{variant:"outline",size:"sm",className:"tw-ml-auto tw-hidden tw-h-8 lg:tw-flex",children:[a.jsx(Q.FilterIcon,{className:"tw-mr-2 tw-h-4 tw-w-4"}),"View"]})}),a.jsxs(En,{align:"end",className:"tw-w-[150px]",children:[a.jsx(Wt,{children:"Toggle columns"}),a.jsx(jn,{}),e.getAllColumns().filter(t=>t.getCanHide()).map(t=>a.jsx(ar,{className:"tw-capitalize",checked:t.getIsVisible(),onCheckedChange:n=>t.toggleVisibility(!!n),children:t.id},t.id))]})]})}const At=ge.Root,ks=ge.Group,Bt=ge.Value,bt=g.forwardRef(({className:e,children:t,...n},r)=>a.jsxs(ge.Trigger,{ref:r,className:N("tw-flex tw-h-10 tw-w-full tw-items-center tw-justify-between tw-rounded-md tw-border tw-border-input tw-bg-background tw-px-3 tw-py-2 tw-text-sm tw-ring-offset-background placeholder:tw-text-muted-foreground focus:tw-outline-none focus:tw-ring-2 focus:tw-ring-ring focus:tw-ring-offset-2 disabled:tw-cursor-not-allowed disabled:tw-opacity-50 [&>span]:tw-line-clamp-1",e),...n,children:[t,a.jsx(ge.Icon,{asChild:!0,children:a.jsx(Q.ChevronDown,{className:"tw-h-4 tw-w-4 tw-opacity-50"})})]}));bt.displayName=ge.Trigger.displayName;const wo=g.forwardRef(({className:e,...t},n)=>a.jsx(ge.ScrollUpButton,{ref:n,className:N("tw-flex tw-cursor-default tw-items-center tw-justify-center tw-py-1",e),...t,children:a.jsx(Q.ChevronUp,{className:"tw-h-4 tw-w-4"})}));wo.displayName=ge.ScrollUpButton.displayName;const fo=g.forwardRef(({className:e,...t},n)=>a.jsx(ge.ScrollDownButton,{ref:n,className:N("tw-flex tw-cursor-default tw-items-center tw-justify-center tw-py-1",e),...t,children:a.jsx(Q.ChevronDown,{className:"tw-h-4 tw-w-4"})}));fo.displayName=ge.ScrollDownButton.displayName;const vt=g.forwardRef(({className:e,children:t,position:n="popper",...r},o)=>a.jsx(ge.Portal,{children:a.jsxs(ge.Content,{ref:o,className:N("pr-twp tw-relative tw-z-50 tw-max-h-96 tw-min-w-[8rem] tw-overflow-hidden tw-rounded-md tw-border tw-bg-popover tw-text-popover-foreground tw-shadow-md data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0 data-[state=closed]:tw-zoom-out-95 data-[state=open]:tw-zoom-in-95 data-[side=bottom]:tw-slide-in-from-top-2 data-[side=left]:tw-slide-in-from-right-2 data-[side=right]:tw-slide-in-from-left-2 data-[side=top]:tw-slide-in-from-bottom-2",n==="popper"&&"data-[side=bottom]:tw-translate-y-1 data-[side=left]:tw--translate-x-1 data-[side=right]:tw-translate-x-1 data-[side=top]:tw--translate-y-1",e),position:n,...r,children:[a.jsx(wo,{}),a.jsx(ge.Viewport,{className:N("tw-p-1",n==="popper"&&"tw-h-[var(--radix-select-trigger-height)] tw-w-full tw-min-w-[var(--radix-select-trigger-width)]"),children:t}),a.jsx(fo,{})]})}));vt.displayName=ge.Content.displayName;const Ss=g.forwardRef(({className:e,...t},n)=>a.jsx(ge.Label,{ref:n,className:N("tw-py-1.5 tw-pl-8 tw-pr-2 tw-text-sm tw-font-semibold",e),...t}));Ss.displayName=ge.Label.displayName;const Ae=g.forwardRef(({className:e,children:t,...n},r)=>a.jsxs(ge.Item,{ref:r,className:N("tw-relative tw-flex tw-w-full tw-cursor-default tw-select-none tw-items-center tw-rounded-sm tw-py-1.5 tw-pl-8 tw-pr-2 tw-text-sm tw-outline-none focus:tw-bg-accent focus:tw-text-accent-foreground data-[disabled]:tw-pointer-events-none data-[disabled]:tw-opacity-50",e),...n,children:[a.jsx("span",{className:"tw-absolute tw-left-2 tw-flex tw-h-3.5 tw-w-3.5 tw-items-center tw-justify-center",children:a.jsx(ge.ItemIndicator,{children:a.jsx(Q.Check,{className:"tw-h-4 tw-w-4"})})}),a.jsx(ge.ItemText,{children:t})]}));Ae.displayName=ge.Item.displayName;const Es=g.forwardRef(({className:e,...t},n)=>a.jsx(ge.Separator,{ref:n,className:N("tw--mx-1 tw-my-1 tw-h-px tw-bg-muted",e),...t}));Es.displayName=ge.Separator.displayName;function bc({table:e}){return a.jsx("div",{className:"tw-flex tw-items-center tw-justify-between tw-px-2 tw-pb-3 tw-pt-3",children:a.jsxs("div",{className:"tw-flex tw-items-center tw-space-x-6 lg:tw-space-x-8",children:[a.jsxs("div",{className:"tw-flex-1 tw-text-sm tw-text-muted-foreground",children:[e.getFilteredSelectedRowModel().rows.length," of"," ",e.getFilteredRowModel().rows.length," row(s) selected"]}),a.jsxs("div",{className:"tw-flex tw-items-center tw-space-x-2",children:[a.jsx("p",{className:"tw-text-nowrap tw-text-sm tw-font-medium",children:"Rows per page"}),a.jsxs(At,{value:`${e.getState().pagination.pageSize}`,onValueChange:t=>{e.setPageSize(Number(t))},children:[a.jsx(bt,{className:"tw-h-8 tw-w-[70px]",children:a.jsx(Bt,{placeholder:e.getState().pagination.pageSize})}),a.jsx(vt,{side:"top",children:[10,20,30,40,50].map(t=>a.jsx(Ae,{value:`${t}`,children:t},t))})]})]}),a.jsxs("div",{className:"tw-flex tw-w-[100px] tw-items-center tw-justify-center tw-text-sm tw-font-medium",children:["Page ",e.getState().pagination.pageIndex+1," of ",e.getPageCount()]}),a.jsxs("div",{className:"tw-flex tw-items-center tw-space-x-2",children:[a.jsxs(fe,{variant:"outline",size:"icon",className:"tw-hidden tw-h-8 tw-w-8 tw-p-0 lg:tw-flex",onClick:()=>e.setPageIndex(0),disabled:!e.getCanPreviousPage(),children:[a.jsx("span",{className:"tw-sr-only",children:"Go to first page"}),a.jsx(Q.ArrowLeftIcon,{className:"tw-h-4 tw-w-4"})]}),a.jsxs(fe,{variant:"outline",size:"icon",className:"tw-h-8 tw-w-8 tw-p-0",onClick:()=>e.previousPage(),disabled:!e.getCanPreviousPage(),children:[a.jsx("span",{className:"tw-sr-only",children:"Go to previous page"}),a.jsx(Q.ChevronLeftIcon,{className:"tw-h-4 tw-w-4"})]}),a.jsxs(fe,{variant:"outline",size:"icon",className:"tw-h-8 tw-w-8 tw-p-0",onClick:()=>e.nextPage(),disabled:!e.getCanNextPage(),children:[a.jsx("span",{className:"tw-sr-only",children:"Go to next page"}),a.jsx(Q.ChevronRightIcon,{className:"tw-h-4 tw-w-4"})]}),a.jsxs(fe,{variant:"outline",size:"icon",className:"tw-hidden tw-h-8 tw-w-8 tw-p-0 lg:tw-flex",onClick:()=>e.setPageIndex(e.getPageCount()-1),disabled:!e.getCanNextPage(),children:[a.jsx("span",{className:"tw-sr-only",children:"Go to last page"}),a.jsx(Q.ArrowRightIcon,{className:"tw-h-4 tw-w-4"})]})]})]})})}const Cn=g.forwardRef(({className:e,stickyHeader:t,...n},r)=>a.jsx("div",{className:N("pr-twp tw-relative tw-w-full",{"tw-overflow-auto":!t}),children:a.jsx("table",{ref:r,className:N("tw-w-full tw-caption-bottom tw-text-sm",e),...n})}));Cn.displayName="Table";const Tn=g.forwardRef(({className:e,stickyHeader:t,...n},r)=>a.jsx("thead",{ref:r,className:N({"tw-sticky tw-top-[-1px] tw-bg-background tw-drop-shadow-sm":t},"[&_tr]:tw-border-b",e),...n}));Tn.displayName="TableHeader";const Rn=g.forwardRef(({className:e,...t},n)=>a.jsx("tbody",{ref:n,className:N("[&_tr:last-child]:tw-border-0",e),...t}));Rn.displayName="TableBody";const js=g.forwardRef(({className:e,...t},n)=>a.jsx("tfoot",{ref:n,className:N("tw-border-t tw-bg-muted/50 tw-font-medium [&>tr]:last:tw-border-b-0",e),...t}));js.displayName="TableFooter";const Ze=g.forwardRef(({className:e,...t},n)=>a.jsx("tr",{ref:n,className:N("tw-border-b tw-transition-colors hover:tw-bg-muted/50 data-[state=selected]:tw-bg-muted",e),...t}));Ze.displayName="TableRow";const Vt=g.forwardRef(({className:e,...t},n)=>a.jsx("th",{ref:n,className:N("tw-h-12 tw-px-4 tw-text-start tw-align-middle tw-font-medium tw-text-muted-foreground [&:has([role=checkbox])]:tw-pe-0",e),...t}));Vt.displayName="TableHead";const xt=g.forwardRef(({className:e,...t},n)=>a.jsx("td",{ref:n,className:N("tw-p-4 tw-align-middle [&:has([role=checkbox])]:tw-pe-0",e),...t}));xt.displayName="TableCell";const Cs=g.forwardRef(({className:e,...t},n)=>a.jsx("caption",{ref:n,className:N("tw-mt-4 tw-text-sm tw-text-muted-foreground",e),...t}));Cs.displayName="TableCaption";function Ts({columns:e,data:t,enablePagination:n=!1,showPaginationControls:r=!1,showColumnVisibilityControls:o=!1,stickyHeader:s=!1,onRowClickHandler:i=()=>{}}){var h;const[l,c]=g.useState([]),[d,u]=g.useState([]),[f,w]=g.useState({}),[b,x]=g.useState({}),m=Se.useReactTable({data:t,columns:e,getCoreRowModel:Se.getCoreRowModel(),...n&&{getPaginationRowModel:Se.getPaginationRowModel()},onSortingChange:c,getSortedRowModel:Se.getSortedRowModel(),onColumnFiltersChange:u,getFilteredRowModel:Se.getFilteredRowModel(),onColumnVisibilityChange:w,onRowSelectionChange:x,state:{sorting:l,columnFilters:d,columnVisibility:f,rowSelection:b}});return a.jsxs("div",{className:"pr-twp",children:[o&&a.jsx(gc,{table:m}),a.jsxs(Cn,{stickyHeader:s,children:[a.jsx(Tn,{stickyHeader:s,children:m.getHeaderGroups().map(S=>a.jsx(Ze,{children:S.headers.map(R=>a.jsx(Vt,{children:R.isPlaceholder?void 0:Se.flexRender(R.column.columnDef.header,R.getContext())},R.id))},S.id))}),a.jsx(Rn,{children:(h=m.getRowModel().rows)!=null&&h.length?m.getRowModel().rows.map(S=>a.jsx(Ze,{onClick:()=>i(S,m),"data-state":S.getIsSelected()&&"selected",children:S.getVisibleCells().map(R=>a.jsx(xt,{children:Se.flexRender(R.column.columnDef.cell,R.getContext())},R.id))},S.id)):a.jsx(Ze,{children:a.jsx(xt,{colSpan:e.length,className:"tw-h-24 tw-text-center",children:"No results."})})})]}),n&&a.jsxs("div",{className:"tw-flex tw-items-center tw-justify-end tw-space-x-2 tw-py-4",children:[a.jsx(fe,{variant:"outline",size:"sm",onClick:()=>m.previousPage(),disabled:!m.getCanPreviousPage(),children:"Previous"}),a.jsx(fe,{variant:"outline",size:"sm",onClick:()=>m.nextPage(),disabled:!m.getCanNextPage(),children:"Next"})]}),n&&r&&a.jsx(bc,{table:m})]})}function vc({occurrenceData:e,setScriptureReference:t,localizedStrings:n}){const r=n["%webView_inventory_occurrences_table_header_reference%"],o=n["%webView_inventory_occurrences_table_header_occurrence%"],s=g.useMemo(()=>{const i=[];return e.forEach(l=>{i.some(c=>W.deepEqual(c,l))||i.push(l)}),i},[e]);return a.jsxs(Cn,{stickyHeader:!0,children:[a.jsx(Tn,{stickyHeader:!0,children:a.jsxs(Ze,{children:[a.jsx(Vt,{children:r}),a.jsx(Vt,{children:o})]})}),a.jsx(Rn,{children:s.length>0&&s.map(i=>a.jsxs(Ze,{onClick:()=>{t(i.reference)},children:[a.jsx(xt,{children:`${ae.bookNumberToEnglishName(i.reference.bookNum)} ${i.reference.chapterNum}:${i.reference.verseNum}`}),a.jsx(xt,{children:i.text})]},`${i.reference.bookNum} ${i.reference.chapterNum}:${i.reference.verseNum}-${i.text}`))})]})}const sr=g.forwardRef(({className:e,...t},n)=>a.jsx(Ur.Root,{ref:n,className:N("tw-peer pr-twp tw-h-4 tw-w-4 tw-shrink-0 tw-rounded-sm tw-border tw-border-primary tw-ring-offset-background focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-cursor-not-allowed disabled:tw-opacity-50 data-[state=checked]:tw-bg-primary data-[state=checked]:tw-text-primary-foreground",e),...t,children:a.jsx(Ur.Indicator,{className:N("tw-flex tw-items-center tw-justify-center tw-text-current"),children:a.jsx(Q.Check,{className:"tw-h-4 tw-w-4"})})}));sr.displayName=Ur.Root.displayName;const Rs=e=>e.split(/(?:\r?\n|\r)|(?=(?:\\(?:v|c|id)))/g),Hr=e=>{const t=/^\\[vc]\s+(\d+)/,n=e.match(t);if(n)return+n[1]},Os=e=>{const t=e.match(/^\\id\s+([A-Za-z]+)/);return t?ae.bookIdToNumber(t[1]):0},_s=(e,t,n)=>n.includes(e)?"unapproved":t.includes(e)?"approved":"unknown",Ps=Xt.cva("pr-twp tw-inline-flex tw-items-center tw-justify-center tw-rounded-md tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-colors hover:tw-bg-muted hover:tw-text-muted-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50 data-[state=on]:tw-bg-accent data-[state=on]:tw-text-accent-foreground",{variants:{variant:{default:"tw-bg-transparent",outline:"tw-border tw-border-input tw-bg-transparent hover:tw-bg-accent hover:tw-text-accent-foreground"},size:{default:"tw-h-10 tw-px-3",sm:"tw-h-9 tw-px-2.5",lg:"tw-h-11 tw-px-5"}},defaultVariants:{variant:"default",size:"default"}}),xc=g.forwardRef(({className:e,variant:t,size:n,...r},o)=>a.jsx(ts.Root,{ref:o,className:N(Ps({variant:t,size:n,className:e})),...r}));xc.displayName=ts.Root.displayName;const Is=g.createContext({size:"default",variant:"default"}),mo=g.forwardRef(({className:e,variant:t,size:n,children:r,...o},s)=>a.jsx(rr.Root,{ref:s,className:N("pr-twp tw-flex tw-items-center tw-justify-center tw-gap-1",e),...o,children:a.jsx(Is.Provider,{value:{variant:t,size:n},children:r})}));mo.displayName=rr.Root.displayName;const fn=g.forwardRef(({className:e,children:t,variant:n,size:r,...o},s)=>{const i=g.useContext(Is);return a.jsx(rr.Item,{ref:s,className:N(Ps({variant:i.variant||n,size:i.size||r}),e),...o,children:t})});fn.displayName=rr.Item.displayName;const ir=e=>e==="asc"?a.jsx(Q.ArrowUpIcon,{className:"tw-ms-2 tw-h-4 tw-w-4"}):e==="desc"?a.jsx(Q.ArrowDownIcon,{className:"tw-ms-2 tw-h-4 tw-w-4"}):a.jsx(Q.ArrowUpDownIcon,{className:"tw-ms-2 tw-h-4 tw-w-4"}),yc=e=>({accessorKey:"item",accessorFn:t=>t.items[0],header:({column:t})=>a.jsxs(fe,{variant:"ghost",onClick:()=>t.toggleSorting(void 0),children:[e,ir(t.getIsSorted())]})}),Nc=(e,t)=>({accessorKey:`item${t}`,accessorFn:n=>n.items[t],header:({column:n})=>a.jsxs(fe,{variant:"ghost",onClick:()=>n.toggleSorting(void 0),children:[e,ir(n.getIsSorted())]})}),kc=e=>({accessorKey:"count",header:({column:t})=>a.jsx("div",{className:"tw-flex tw-justify-end tw-tabular-nums",children:a.jsxs(fe,{variant:"ghost",onClick:()=>t.toggleSorting(void 0),children:[e,ir(t.getIsSorted())]})}),cell:({row:t})=>a.jsx("div",{className:"tw-flex tw-justify-end",children:t.getValue("count")})}),Rr=(e,t,n,r,o,s)=>{let i=[...n];e.forEach(c=>{t==="approved"?i.includes(c)||i.push(c):i=i.filter(d=>d!==c)}),r(i);let l=[...o];e.forEach(c=>{t==="unapproved"?l.includes(c)||l.push(c):l=l.filter(d=>d!==c)}),s(l)},Sc=(e,t,n,r,o)=>({accessorKey:"status",header:({column:s})=>a.jsx("div",{className:"tw-flex tw-justify-center",children:a.jsxs(fe,{variant:"ghost",onClick:()=>s.toggleSorting(void 0),children:[e,ir(s.getIsSorted())]})}),cell:({row:s})=>{const i=s.getValue("status"),l=s.getValue("item");return a.jsxs(mo,{value:i,variant:"outline",type:"single",children:[a.jsx(fn,{onClick:()=>Rr([l],"approved",t,n,r,o),value:"approved",children:a.jsx(Q.CircleCheckIcon,{})}),a.jsx(fn,{onClick:()=>Rr([l],"unapproved",t,n,r,o),value:"unapproved",children:a.jsx(Q.CircleXIcon,{})}),a.jsx(fn,{onClick:()=>Rr([l],"unknown",t,n,r,o),value:"unknown",children:a.jsx(Q.CircleHelpIcon,{})})]})}}),Ec=Object.freeze(["%webView_inventory_all%","%webView_inventory_approved%","%webView_inventory_unapproved%","%webView_inventory_unknown%","%webView_inventory_scope_currentBook%","%webView_inventory_scope_chapter%","%webView_inventory_scope_verse%","%webView_inventory_filter_text%","%webView_inventory_show_additional_items%","%webView_inventory_occurrences_table_header_reference%","%webView_inventory_occurrences_table_header_occurrence%"]),jc=(e,t,n)=>{let r=e;return t!=="all"&&(r=r.filter(o=>t==="approved"&&o.status==="approved"||t==="unapproved"&&o.status==="unapproved"||t==="unknown"&&o.status==="unknown")),n!==""&&(r=r.filter(o=>o.items[0].includes(n))),r},Cc=(e,t,n,r,o)=>{if(!e)return[];const s=[];let i=t.bookNum,l=t.chapterNum,c=t.verseNum;return Rs(e).forEach(u=>{u.startsWith("\\id")&&(i=Os(u),l=0,c=0),u.startsWith("\\c")&&(l=Hr(u),c=0),u.startsWith("\\v")&&(c=Hr(u),l===0&&(l=t.chapterNum));let f=o.exec(u)??void 0;for(;f;){const w=[];f.forEach(h=>w.push(h));const b=f.index,x=s.find(h=>W.deepEqual(h.items,w)),m={reference:{bookNum:i!==void 0?i:-1,chapterNum:l!==void 0?l:-1,verseNum:c!==void 0?c:-1},text:W.substring(u,Math.max(0,b-25),Math.min(b+25,u.length))};if(x)x.count+=1,x.occurrences.push(m);else{const h={items:w,count:1,status:_s(w[0],n,r),occurrences:[m]};s.push(h)}f=o.exec(u)??void 0}}),s},Je=(e,t)=>e[t]??t;function Tc({scriptureReference:e,setScriptureReference:t,localizedStrings:n,extractItems:r,additionalItemsLabels:o,approvedItems:s,unapprovedItems:i,text:l,scope:c,onScopeChange:d,columns:u}){const f=Je(n,"%webView_inventory_all%"),w=Je(n,"%webView_inventory_approved%"),b=Je(n,"%webView_inventory_unapproved%"),x=Je(n,"%webView_inventory_unknown%"),m=Je(n,"%webView_inventory_scope_currentBook%"),h=Je(n,"%webView_inventory_scope_chapter%"),S=Je(n,"%webView_inventory_scope_verse%"),R=Je(n,"%webView_inventory_filter_text%"),j=Je(n,"%webView_inventory_show_additional_items%"),[E,v]=g.useState(!1),[P,V]=g.useState("all"),[U,C]=g.useState(""),[_,k]=g.useState([]),D=g.useMemo(()=>l?r instanceof RegExp?Cc(l,e,s,i,r):r(l,e,s,i):[],[l,r,e,s,i]),$=g.useMemo(()=>{if(E)return D;const y=[];return D.forEach(T=>{const z=T.items[0],L=y.find(B=>B.items[0]===z);L?(L.count+=T.count,L.occurrences=L.occurrences.concat(T.occurrences)):y.push({items:[z],count:T.count,occurrences:T.occurrences,status:T.status})}),y},[E,D]),J=g.useMemo(()=>jc($,P,U),[$,P,U]),Y=g.useMemo(()=>{var z,L;if(!E)return u;const y=(z=o==null?void 0:o.tableHeaders)==null?void 0:z.length;if(!y)return u;const T=[];for(let B=0;B{k([])},[J]);const F=(y,T)=>{T.setRowSelection(()=>{const z={};return z[y.index]=!0,z}),k(y.original.items)},te=y=>{if(y==="book"||y==="chapter"||y==="verse")d(y);else throw new Error(`Invalid scope value: ${y}`)},se=y=>{if(y==="all"||y==="approved"||y==="unapproved"||y==="unknown")V(y);else throw new Error(`Invalid status filter value: ${y}`)},oe=g.useMemo(()=>{if($.length===0||_.length===0)return[];const y=$.filter(T=>W.deepEqual(E?T.items:[T.items[0]],_));if(y.length>1)throw new Error("Selected item is not unique");return y[0].occurrences},[_,E,$]);return a.jsxs("div",{className:"pr-twp tw-flex tw-h-full tw-flex-col",children:[a.jsxs("div",{className:"tw-flex tw-items-stretch",children:[a.jsxs(At,{onValueChange:y=>se(y),defaultValue:P,children:[a.jsx(bt,{className:"tw-m-1",children:a.jsx(Bt,{placeholder:"Select filter"})}),a.jsxs(vt,{children:[a.jsx(Ae,{value:"all",children:f}),a.jsx(Ae,{value:"approved",children:w}),a.jsx(Ae,{value:"unapproved",children:b}),a.jsx(Ae,{value:"unknown",children:x})]})]}),a.jsxs(At,{onValueChange:y=>te(y),defaultValue:c,children:[a.jsx(bt,{className:"tw-m-1",children:a.jsx(Bt,{placeholder:"Select scope"})}),a.jsxs(vt,{children:[a.jsx(Ae,{value:"book",children:m}),a.jsx(Ae,{value:"chapter",children:h}),a.jsx(Ae,{value:"verse",children:S})]})]}),a.jsx(St,{className:"tw-m-1 tw-rounded-md tw-border",placeholder:R,value:U,onChange:y=>{C(y.target.value)}}),o&&a.jsxs("div",{className:"tw-m-1 tw-flex tw-items-center tw-rounded-md tw-border",children:[a.jsx(sr,{className:"tw-m-1",checked:E,onCheckedChange:y=>{k([]),v(y)}}),a.jsx(qe,{className:"tw-m-1 tw-flex-shrink-0 tw-whitespace-nowrap",children:(o==null?void 0:o.checkboxText)??j})]})]}),a.jsx("div",{className:"tw-m-1 tw-flex-1 tw-overflow-auto tw-rounded-md tw-border",children:a.jsx(Ts,{columns:Y,data:J,onRowClickHandler:F,stickyHeader:!0})}),oe.length>0&&a.jsx("div",{className:"tw-m-1 tw-flex-1 tw-overflow-auto tw-rounded-md tw-border",children:a.jsx(vc,{occurrenceData:oe,setScriptureReference:t,localizedStrings:n})})]})}function ho({className:e,onSearch:t,placeholder:n,isFullWidth:r}){const[o,s]=g.useState(""),i=l=>{s(l),t(l)};return a.jsx(St,{className:N("tw-flex tw-h-10 tw-rounded-md tw-border tw-border-input tw-bg-background tw-px-3 tw-py-2 tw-text-sm tw-ring-offset-background file:tw-border-0 file:tw-bg-transparent file:tw-text-sm file:tw-font-medium placeholder:tw-text-muted-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-[color:hsl(240,5%,64.9%)] focus-visible:tw-ring-offset-2 disabled:tw-cursor-not-allowed disabled:tw-opacity-50",{"tw-w-full":r},e),placeholder:n,value:o,onChange:l=>i(l.target.value)})}const go=g.forwardRef(({className:e,...t},n)=>a.jsx(Oe.Root,{orientation:"vertical",ref:n,className:N("tw-flex tw-gap-1 tw-rounded-md tw-text-muted-foreground",e),...t}));go.displayName=Oe.List.displayName;const bo=g.forwardRef(({className:e,...t},n)=>a.jsx(Oe.List,{ref:n,className:N("tw-flex-fit tw-mlk-items-center tw-w-[124px] tw-justify-center tw-rounded-md tw-bg-muted tw-p-1 tw-text-muted-foreground",e),...t}));bo.displayName=Oe.List.displayName;const Ms=g.forwardRef(({className:e,...t},n)=>a.jsx(Oe.Trigger,{ref:n,...t,className:N("overflow-clip tw-inline-flex tw-w-[116px] tw-cursor-pointer tw-items-center tw-justify-center tw-break-words tw-rounded-sm tw-border-0 tw-bg-muted tw-px-3 tw-py-1.5 tw-text-sm tw-font-medium tw-text-inherit tw-ring-offset-background tw-transition-all hover:tw-text-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50 data-[state=active]:tw-bg-background data-[state=active]:tw-text-foreground data-[state=active]:tw-shadow-sm",e)})),vo=g.forwardRef(({className:e,...t},n)=>a.jsx(Oe.Content,{ref:n,className:N("tw-ms-5 tw-flex-grow tw-text-foreground tw-ring-offset-background focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2",e),...t}));vo.displayName=Oe.Content.displayName;function Rc({tabList:e,onSearch:t,searchPlaceholder:n,headerTitle:r,isSearchBarFullWidth:o=!1,direction:s="ltr"}){return a.jsxs("div",{className:"pr-twp",children:[a.jsxs("div",{className:"tw-sticky tw-top-0 tw-space-y-2 tw-pb-2",children:[r?a.jsx("h1",{children:r}):"",a.jsx(ho,{isFullWidth:o,onSearch:t,placeholder:n})]}),a.jsxs(go,{dir:s,children:[a.jsx(bo,{children:e.map(i=>a.jsx(Ms,{value:i.value,children:i.value},i.key))}),e.map(i=>a.jsx(vo,{value:i.value,children:i.content},i.key))]})]})}const lr=g.forwardRef(({className:e,orientation:t="horizontal",decorative:n=!0,...r},o)=>a.jsx(ns.Root,{ref:o,decorative:n,orientation:t,className:N("pr-twp tw-shrink-0 tw-bg-border",t==="horizontal"?"tw-h-[1px] tw-w-full":"tw-h-full tw-w-[1px]",e),...r}));lr.displayName=ns.Root.displayName;const Oc=be.Root,_c=be.Portal,$s=M.forwardRef(({className:e,...t},n)=>a.jsx(be.Overlay,{className:N("tw-fixed tw-inset-0 tw-z-50 tw-bg-black/80 data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0",e),...t,ref:n}));$s.displayName=be.Overlay.displayName;const Pc=Xt.cva("pr-twp tw-fixed tw-z-50 tw-gap-4 tw-bg-background tw-p-6 tw-shadow-lg tw-transition tw-ease-in-out data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-duration-300 data-[state=open]:tw-duration-500",{variants:{side:{top:"tw-inset-x-0 tw-top-0 tw-border-b data-[state=closed]:tw-slide-out-to-top data-[state=open]:tw-slide-in-from-top",bottom:"tw-inset-x-0 tw-bottom-0 tw-border-t data-[state=closed]:tw-slide-out-to-bottom data-[state=open]:tw-slide-in-from-bottom",left:"tw-inset-y-0 tw-left-0 tw-h-full tw-w-3/4 tw-border-r data-[state=closed]:tw-slide-out-to-left data-[state=open]:tw-slide-in-from-left sm:tw-max-w-sm",right:"tw-inset-y-0 tw-right-0 tw-h-full tw-w-3/4 tw- tw-border-l data-[state=closed]:tw-slide-out-to-right data-[state=open]:tw-slide-in-from-right sm:tw-max-w-sm"}},defaultVariants:{side:"right"}}),Ds=M.forwardRef(({side:e="right",className:t,children:n,...r},o)=>a.jsxs(_c,{children:[a.jsx($s,{}),a.jsxs(be.Content,{ref:o,className:N(Pc({side:e}),t),...r,children:[n,a.jsxs(be.Close,{className:"tw-absolute tw-right-4 tw-top-4 tw-rounded-sm tw-opacity-70 tw-ring-offset-background tw-transition-opacity hover:tw-opacity-100 focus:tw-outline-none focus:tw-ring-2 focus:tw-ring-ring focus:tw-ring-offset-2 disabled:tw-pointer-events-none data-[state=open]:tw-bg-secondary",children:[a.jsx(Q.X,{className:"tw-h-4 tw-w-4"}),a.jsx("span",{className:"tw-sr-only",children:"Close"})]})]})]}));Ds.displayName=be.Content.displayName;const Ic=M.forwardRef(({className:e,...t},n)=>a.jsx(be.Title,{ref:n,className:N("tw-text-lg tw-font-semibold tw-text-foreground",e),...t}));Ic.displayName=be.Title.displayName;const Mc=M.forwardRef(({className:e,...t},n)=>a.jsx(be.Description,{ref:n,className:N("tw-text-sm tw-text-muted-foreground",e),...t}));Mc.displayName=be.Description.displayName;function sa({className:e,...t}){return a.jsx("div",{className:N("pr-twp tw-animate-pulse tw-rounded-md tw-bg-muted",e),...t})}const $c=Sn.Provider,Dc=Sn.Root,Ac=Sn.Trigger,As=g.forwardRef(({className:e,sideOffset:t=4,...n},r)=>a.jsx(Sn.Content,{ref:r,sideOffset:t,className:N("pr-twp tw-z-50 tw-overflow-hidden tw-rounded-md tw-border tw-bg-popover tw-px-3 tw-py-1.5 tw-text-sm tw-text-popover-foreground tw-shadow-md tw-animate-in tw-fade-in-0 tw-zoom-in-95 data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=closed]:tw-zoom-out-95 data-[side=bottom]:tw-slide-in-from-top-2 data-[side=left]:tw-slide-in-from-right-2 data-[side=right]:tw-slide-in-from-left-2 data-[side=top]:tw-slide-in-from-bottom-2",e),...n}));As.displayName=Sn.Content.displayName;const Or=768;function Bc(){const[e,t]=M.useState(void 0);return M.useEffect(()=>{const n=window.matchMedia(`(max-width: ${Or-1}px)`),r=()=>{t(window.innerWidthn.removeEventListener("change",r)},[]),!!e}const Vc="sidebar:state",zc=60*60*24*7,Lc="16rem",Fc="18rem",Gc="3rem",Uc="b",Bs=g.createContext(void 0);function cr(){const e=g.useContext(Bs);if(!e)throw new Error("useSidebar must be used within a SidebarProvider.");return e}const Vs=g.forwardRef(({defaultOpen:e=!0,open:t,onOpenChange:n,className:r,style:o,children:s,...i},l)=>{const c=Bc(),[d,u]=g.useState(!1),[f,w]=g.useState(e),b=t??f,x=g.useCallback(R=>{const j=typeof R=="function"?R(b):R;n?n(j):w(j),document.cookie=`${Vc}=${j}; path=/; max-age=${zc}`},[n,b]),m=g.useCallback(()=>c?u(R=>!R):x(R=>!R),[c,x,u]);g.useEffect(()=>{const R=j=>{j.key===Uc&&(j.metaKey||j.ctrlKey)&&(j.preventDefault(),m())};return window.addEventListener("keydown",R),()=>window.removeEventListener("keydown",R)},[m]);const h=b?"expanded":"collapsed",S=g.useMemo(()=>({state:h,open:b,setOpen:x,isMobile:c,openMobile:d,setOpenMobile:u,toggleSidebar:m}),[h,b,x,c,d,u,m]);return a.jsx(Bs.Provider,{value:S,children:a.jsx($c,{delayDuration:0,children:a.jsx("div",{style:{"--sidebar-width":Lc,"--sidebar-width-icon":Gc,...o},className:N("tw-group/sidebar-wrapper pr-twp tw-flex tw-w-full has-[[data-variant=inset]]:tw-bg-sidebar",r),ref:l,...i,children:s})})})});Vs.displayName="SidebarProvider";const zs=g.forwardRef(({side:e="left",variant:t="sidebar",collapsible:n="offcanvas",className:r,children:o,...s},i)=>{const{isMobile:l,state:c,openMobile:d,setOpenMobile:u}=cr();return n==="none"?a.jsx("div",{className:N("tw-flex tw-h-full tw-w-[--sidebar-width] tw-flex-col tw-bg-sidebar tw-text-sidebar-foreground",r),ref:i,...s,children:o}):l?a.jsx(Oc,{open:d,onOpenChange:u,...s,children:a.jsx(Ds,{"data-sidebar":"sidebar","data-mobile":"true",className:"tw-w-[--sidebar-width] tw-bg-sidebar tw-p-0 tw-text-sidebar-foreground [&>button]:tw-hidden",style:{"--sidebar-width":Fc},side:e,children:a.jsx("div",{className:"tw-flex tw-h-full tw-w-full tw-flex-col",children:o})})}):a.jsxs("div",{ref:i,className:"tw-group tw-peer tw-hidden tw-text-sidebar-foreground md:tw-block","data-state":c,"data-collapsible":c==="collapsed"?n:"","data-variant":t,"data-side":e,children:[a.jsx("div",{className:N("tw-relative tw-h-svh tw-w-[--sidebar-width] tw-bg-transparent tw-transition-[width] tw-duration-200 tw-ease-linear","group-data-[collapsible=offcanvas]:tw-w-0","group-data-[side=right]:tw-rotate-180",t==="floating"||t==="inset"?"group-data-[collapsible=icon]:tw-w-[calc(var(--sidebar-width-icon)_+_theme(spacing.4))]":"group-data-[collapsible=icon]:tw-w-[--sidebar-width-icon]")}),a.jsx("div",{className:N("tw-absolute tw-inset-y-0 tw-z-10 tw-hidden tw-h-svh tw-w-[--sidebar-width] tw-transition-[left,right,width] tw-duration-200 tw-ease-linear md:tw-flex",e==="left"?"tw-left-0 group-data-[collapsible=offcanvas]:tw-left-[calc(var(--sidebar-width)*-1)]":"tw-right-0 group-data-[collapsible=offcanvas]:tw-right-[calc(var(--sidebar-width)*-1)]",t==="floating"||t==="inset"?"tw-p-2 group-data-[collapsible=icon]:tw-w-[calc(var(--sidebar-width-icon)_+_theme(spacing.4)_+2px)]":"group-data-[collapsible=icon]:tw-w-[--sidebar-width-icon] group-data-[side=left]:tw-border-r group-data-[side=right]:tw-border-l",r),...s,children:a.jsx("div",{"data-sidebar":"sidebar",className:"tw-flex tw-h-full tw-w-full tw-flex-col tw-bg-sidebar group-data-[variant=floating]:tw-rounded-lg group-data-[variant=floating]:tw-border group-data-[variant=floating]:tw-border-sidebar-border group-data-[variant=floating]:tw-shadow",children:o})})]})});zs.displayName="Sidebar";const qc=g.forwardRef(({className:e,onClick:t,...n},r)=>{const{toggleSidebar:o}=cr();return a.jsxs(fe,{ref:r,"data-sidebar":"trigger",variant:"ghost",size:"icon",className:N("tw-h-7 tw-w-7",e),onClick:s=>{t==null||t(s),o()},...n,children:[a.jsx(Q.PanelLeft,{}),a.jsx("span",{className:"tw-sr-only",children:"Toggle Sidebar"})]})});qc.displayName="SidebarTrigger";const Hc=g.forwardRef(({className:e,...t},n)=>{const{toggleSidebar:r}=cr();return a.jsx("button",{type:"button",ref:n,"data-sidebar":"rail","aria-label":"Toggle Sidebar",tabIndex:-1,onClick:r,title:"Toggle Sidebar",className:N("tw-absolute tw-inset-y-0 tw-z-20 tw-hidden tw-w-4 tw--translate-x-1/2 tw-transition-all tw-ease-linear after:tw-absolute after:tw-inset-y-0 after:tw-left-1/2 after:tw-w-[2px] hover:after:tw-bg-sidebar-border group-data-[side=left]:tw--right-4 group-data-[side=right]:tw-left-0 sm:tw-flex","[[data-side=left]_&]:tw-cursor-w-resize [[data-side=right]_&]:tw-cursor-e-resize","[[data-side=left][data-state=collapsed]_&]:tw-cursor-e-resize [[data-side=right][data-state=collapsed]_&]:tw-cursor-w-resize","group-data-[collapsible=offcanvas]:tw-translate-x-0 group-data-[collapsible=offcanvas]:after:tw-left-full group-data-[collapsible=offcanvas]:hover:tw-bg-sidebar","[[data-side=left][data-collapsible=offcanvas]_&]:tw--right-2","[[data-side=right][data-collapsible=offcanvas]_&]:tw--left-2",e),...t})});Hc.displayName="SidebarRail";const Ls=g.forwardRef(({className:e,...t},n)=>a.jsx("main",{ref:n,className:N("tw-relative tw-flex tw-flex-1 tw-flex-col tw-bg-background","peer-data-[variant=inset]:tw-min-h-[calc(100svh-theme(spacing.4))] md:peer-data-[variant=inset]:tw-m-2 md:peer-data-[state=collapsed]:peer-data-[variant=inset]:tw-ml-2 md:peer-data-[variant=inset]:tw-ml-0 md:peer-data-[variant=inset]:tw-rounded-xl md:peer-data-[variant=inset]:tw-shadow",e),...t}));Ls.displayName="SidebarInset";const Xc=g.forwardRef(({className:e,...t},n)=>a.jsx(St,{ref:n,"data-sidebar":"input",className:N("tw-h-8 tw-w-full tw-bg-background tw-shadow-none focus-visible:tw-ring-2 focus-visible:tw-ring-sidebar-ring",e),...t}));Xc.displayName="SidebarInput";const Yc=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,"data-sidebar":"header",className:N("tw-flex tw-flex-col tw-gap-2 tw-p-2",e),...t}));Yc.displayName="SidebarHeader";const Wc=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,"data-sidebar":"footer",className:N("tw-flex tw-flex-col tw-gap-2 tw-p-2",e),...t}));Wc.displayName="SidebarFooter";const Kc=g.forwardRef(({className:e,...t},n)=>a.jsx(lr,{ref:n,"data-sidebar":"separator",className:N("tw-mx-2 tw-w-auto tw-bg-sidebar-border",e),...t}));Kc.displayName="SidebarSeparator";const Fs=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,"data-sidebar":"content",className:N("tw-flex tw-min-h-0 tw-flex-1 tw-flex-col tw-gap-2 tw-overflow-auto group-data-[collapsible=icon]:tw-overflow-hidden",e),...t}));Fs.displayName="SidebarContent";const Xr=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,"data-sidebar":"group",className:N("tw-relative tw-flex tw-w-full tw-min-w-0 tw-flex-col tw-p-2",e),...t}));Xr.displayName="SidebarGroup";const Yr=g.forwardRef(({className:e,asChild:t=!1,...n},r)=>{const o=t?Ht.Slot:"div";return a.jsx(o,{ref:r,"data-sidebar":"group-label",className:N("tw-flex tw-h-8 tw-shrink-0 tw-items-center tw-rounded-md tw-px-2 tw-text-xs tw-font-medium tw-text-sidebar-foreground/70 tw-outline-none tw-ring-sidebar-ring tw-transition-[margin,opa] tw-duration-200 tw-ease-linear focus-visible:tw-ring-2 [&>svg]:tw-size-4 [&>svg]:tw-shrink-0","group-data-[collapsible=icon]:tw--mt-8 group-data-[collapsible=icon]:tw-opacity-0",e),...n})});Yr.displayName="SidebarGroupLabel";const Jc=g.forwardRef(({className:e,asChild:t=!1,...n},r)=>{const o=t?Ht.Slot:"button";return a.jsx(o,{ref:r,"data-sidebar":"group-action",className:N("tw-absolute tw-right-3 tw-top-3.5 tw-flex tw-aspect-square tw-w-5 tw-items-center tw-justify-center tw-rounded-md tw-p-0 tw-text-sidebar-foreground tw-outline-none tw-ring-sidebar-ring tw-transition-transform hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground focus-visible:tw-ring-2 [&>svg]:tw-size-4 [&>svg]:tw-shrink-0","after:tw-absolute after:tw--inset-2 after:md:tw-hidden","group-data-[collapsible=icon]:tw-hidden",e),...n})});Jc.displayName="SidebarGroupAction";const Wr=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,"data-sidebar":"group-content",className:N("tw-w-full tw-text-sm",e),...t}));Wr.displayName="SidebarGroupContent";const Gs=g.forwardRef(({className:e,...t},n)=>a.jsx("ul",{ref:n,"data-sidebar":"menu",className:N("tw-flex tw-w-full tw-min-w-0 tw-flex-col tw-gap-1",e),...t}));Gs.displayName="SidebarMenu";const Us=g.forwardRef(({className:e,...t},n)=>a.jsx("li",{ref:n,"data-sidebar":"menu-item",className:N("tw-group/menu-item tw-relative",e),...t}));Us.displayName="SidebarMenuItem";const Zc=Xt.cva("tw-peer/menu-button tw-flex tw-w-full tw-items-center tw-gap-2 tw-overflow-hidden tw-rounded-md tw-p-2 tw-text-left tw-text-sm tw-outline-none tw-ring-sidebar-ring tw-transition-[width,height,padding] hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground focus-visible:tw-ring-2 active:tw-bg-sidebar-accent active:tw-text-sidebar-accent-foreground disabled:tw-pointer-events-none disabled:tw-opacity-50 tw-group-has-[[data-sidebar=menu-action]]/menu-item:pr-8 aria-disabled:tw-pointer-events-none aria-disabled:tw-opacity-50 data-[active=true]:tw-font-medium data-[active=true]:tw-text-sidebar-accent-foreground data-[state=open]:hover:tw-bg-sidebar-accent data-[state=open]:hover:tw-text-sidebar-accent-foreground group-data-[collapsible=icon]:tw-!size-8 group-data-[collapsible=icon]:tw-!p-2 [&>span:last-child]:tw-truncate [&>svg]:tw-size-4 [&>svg]:tw-shrink-0",{variants:{variant:{default:"hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground",outline:"tw-bg-background tw-shadow-[0_0_0_1px_hsl(var(--sidebar-border))] hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground hover:tw-shadow-[0_0_0_1px_hsl(var(--sidebar-accent))]"},size:{default:"tw-h-8 tw-text-sm",sm:"tw-h-7 tw-text-xs",lg:"tw-h-12 tw-text-sm group-data-[collapsible=icon]:tw-!p-0"}},defaultVariants:{variant:"default",size:"default"}}),qs=g.forwardRef(({asChild:e=!1,isActive:t=!1,variant:n="default",size:r="default",tooltip:o,className:s,...i},l)=>{const c=e?Ht.Slot:"button",{isMobile:d,state:u}=cr(),f=a.jsx(c,{ref:l,"data-sidebar":"menu-button","data-size":r,"data-active":t,className:N(Zc({variant:n,size:r}),s),...i});return o?(typeof o=="string"&&(o={children:o}),a.jsxs(Dc,{children:[a.jsx(Ac,{asChild:!0,children:f}),a.jsx(As,{side:"right",align:"center",hidden:u!=="collapsed"||d,...o})]})):f});qs.displayName="SidebarMenuButton";const Qc=g.forwardRef(({className:e,asChild:t=!1,showOnHover:n=!1,...r},o)=>{const s=t?Ht.Slot:"button";return a.jsx(s,{ref:o,"data-sidebar":"menu-action",className:N("tw-peer-hover/menu-button:text-sidebar-accent-foreground tw-absolute tw-right-1 tw-top-1.5 tw-flex tw-aspect-square tw-w-5 tw-items-center tw-justify-center tw-rounded-md tw-p-0 tw-text-sidebar-foreground tw-outline-none tw-ring-sidebar-ring tw-transition-transform hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground focus-visible:tw-ring-2 [&>svg]:tw-size-4 [&>svg]:tw-shrink-0","after:tw-absolute after:tw--inset-2 after:md:tw-hidden","tw-peer-data-[size=sm]/menu-button:top-1","tw-peer-data-[size=default]/menu-button:top-1.5","tw-peer-data-[size=lg]/menu-button:top-2.5","group-data-[collapsible=icon]:tw-hidden",n&&"tw-group-focus-within/menu-item:opacity-100 tw-group-hover/menu-item:opacity-100 tw-peer-data-[active=true]/menu-button:text-sidebar-accent-foreground data-[state=open]:tw-opacity-100 md:tw-opacity-0",e),...r})});Qc.displayName="SidebarMenuAction";const ed=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,"data-sidebar":"menu-badge",className:N("tw-pointer-events-none tw-absolute tw-right-1 tw-flex tw-h-5 tw-min-w-5 tw-select-none tw-items-center tw-justify-center tw-rounded-md tw-px-1 tw-text-xs tw-font-medium tw-tabular-nums tw-text-sidebar-foreground","tw-peer-hover/menu-button:text-sidebar-accent-foreground tw-peer-data-[active=true]/menu-button:text-sidebar-accent-foreground","tw-peer-data-[size=sm]/menu-button:top-1","tw-peer-data-[size=default]/menu-button:top-1.5","tw-peer-data-[size=lg]/menu-button:top-2.5","group-data-[collapsible=icon]:tw-hidden",e),...t}));ed.displayName="SidebarMenuBadge";const td=g.forwardRef(({className:e,showIcon:t=!1,...n},r)=>{const o=g.useMemo(()=>`${Math.floor(Math.random()*40)+50}%`,[]);return a.jsxs("div",{ref:r,"data-sidebar":"menu-skeleton",className:N("tw-flex tw-h-8 tw-items-center tw-gap-2 tw-rounded-md tw-px-2",e),...n,children:[t&&a.jsx(sa,{className:"tw-size-4 tw-rounded-md","data-sidebar":"menu-skeleton-icon"}),a.jsx(sa,{className:"tw-h-4 tw-max-w-[--skeleton-width] tw-flex-1","data-sidebar":"menu-skeleton-text",style:{"--skeleton-width":o}})]})});td.displayName="SidebarMenuSkeleton";const nd=g.forwardRef(({className:e,...t},n)=>a.jsx("ul",{ref:n,"data-sidebar":"menu-sub",className:N("tw-mx-3.5 tw-flex tw-min-w-0 tw-translate-x-px tw-flex-col tw-gap-1 tw-border-l tw-border-sidebar-border tw-px-2.5 tw-py-0.5","group-data-[collapsible=icon]:tw-hidden",e),...t}));nd.displayName="SidebarMenuSub";const rd=g.forwardRef(({...e},t)=>a.jsx("li",{ref:t,...e}));rd.displayName="SidebarMenuSubItem";const od=g.forwardRef(({asChild:e=!1,size:t="md",isActive:n,className:r,...o},s)=>{const i=e?Ht.Slot:"a";return a.jsx(i,{ref:s,"data-sidebar":"menu-sub-button","data-size":t,"data-active":n,className:N("tw-flex tw-h-7 tw-min-w-0 tw--translate-x-px tw-items-center tw-gap-2 tw-overflow-hidden tw-rounded-md tw-px-2 tw-text-sidebar-foreground tw-outline-none tw-ring-sidebar-ring hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground focus-visible:tw-ring-2 active:tw-bg-sidebar-accent active:tw-text-sidebar-accent-foreground disabled:tw-pointer-events-none disabled:tw-opacity-50 aria-disabled:tw-pointer-events-none aria-disabled:tw-opacity-50 [&>span:last-child]:tw-truncate [&>svg]:tw-size-4 [&>svg]:tw-shrink-0 [&>svg]:tw-text-sidebar-accent-foreground","data-[active=true]:tw-bg-sidebar-accent data-[active=true]:tw-text-sidebar-accent-foreground",t==="sm"&&"tw-text-xs",t==="md"&&"tw-text-sm","group-data-[collapsible=icon]:tw-hidden",r),...o})});od.displayName="SidebarMenuSubButton";function Hs({id:e,extensionLabels:t,projectOptions:n,handleSelectSidebarItem:r,selectedSidebarItem:o,extensionsSidebarGroupLabel:s,projectsSidebarGroupLabel:i,buttonPlaceholder:l}){const c=g.useCallback((f,w)=>{r(f,w)},[r]),d=g.useCallback(f=>{const w=n.find(b=>b.projectId===f);return w?w.projectName:f},[n]),u=g.useCallback(f=>!o.projectId&&f===o.label,[o]);return a.jsx(zs,{id:e,collapsible:"none",variant:"inset",className:"tw-w-96 tw-gap-2 tw-overflow-y-auto tw-rounded tw-bg-slate-100",children:a.jsxs(Fs,{children:[a.jsxs(Xr,{children:[a.jsx(Yr,{className:"tw-text-sm tw-text-gray-400",children:s}),a.jsx(Wr,{children:a.jsx(Gs,{children:t.map(f=>a.jsx(Us,{children:a.jsx(qs,{className:N("tw-rounded tw-py-2 tw-text-sm tw-text-gray-500 hover:tw-bg-white hover:tw-text-gray-900 hover:tw-shadow-sm active:tw-bg-white",{"tw-bg-white tw-text-gray-900 tw-shadow-sm":u(f)}),onClick:()=>c(f,void 0),isActive:u(f),children:a.jsx("span",{className:"tw-pl-3",children:f})})},f))})})]}),a.jsxs(Xr,{children:[a.jsx(Yr,{className:"tw-text-sm tw-text-gray-400",children:i}),a.jsx(Wr,{className:"tw-pl-3",children:a.jsx(Wn,{popoverContentClassName:"tw-z-[1000]",options:n.flatMap(f=>f.projectId),getOptionLabel:f=>d(f),buttonPlaceholder:l,onChange:f=>{const w=d(f);c(w,f)},value:(o==null?void 0:o.projectId)??void 0})})]})]})})}function ad({id:e,direction:t="ltr",extensionLabels:n,projectOptions:r,children:o,handleSelectSidebarItem:s,selectedSidebarItem:i,onSearch:l,extensionsSidebarGroupLabel:c,projectsSidebarGroupLabel:d,buttonPlaceholder:u}){return a.jsxs("div",{className:"tw-box-border tw-flex tw-h-full tw-flex-col tw-p-3",children:[a.jsx("div",{className:"tw-box-border tw-flex tw-items-center tw-justify-center tw-py-4",children:a.jsx(ho,{className:"tw-w-9/12",onSearch:l,placeholder:"Search app settings, extension settings, and project settings"})}),a.jsxs(Vs,{dir:t,id:e,className:"tw-h-full tw-flex-1 tw-gap-4 tw-overflow-auto",children:[a.jsx(Hs,{extensionLabels:n,projectOptions:r,handleSelectSidebarItem:s,selectedSidebarItem:i,extensionsSidebarGroupLabel:c,projectsSidebarGroupLabel:d,buttonPlaceholder:u}),a.jsx(Ls,{className:"tw-overflow-y-auto",children:o})]})]})}const rt="scrBook",sd="scrRef",pt="source",id="details",ld="Scripture Reference",cd="Scripture Book",Xs="Type",dd="Details";function ud(e,t){const n=t??!1;return[{accessorFn:r=>`${ae.bookNumberToId(r.start.bookNum)} ${r.start.chapterNum}:${r.start.verseNum}`,id:rt,header:(e==null?void 0:e.scriptureReferenceColumnName)??ld,cell:r=>{const o=r.row.original;return r.row.getIsGrouped()?ae.bookNumberToEnglishName(o.start.bookNum):r.row.groupingColumnId===rt?W.formatScrRef(o.start):void 0},getGroupingValue:r=>r.start.bookNum,sortingFn:(r,o)=>W.compareScrRefs(r.original.start,o.original.start),enableGrouping:!0},{accessorFn:r=>W.formatScrRef(r.start),id:sd,header:void 0,cell:r=>{const o=r.row.original;return r.row.getIsGrouped()?void 0:W.formatScrRef(o.start)},sortingFn:(r,o)=>W.compareScrRefs(r.original.start,o.original.start),enableGrouping:!1},{accessorFn:r=>r.source.displayName,id:pt,header:n?(e==null?void 0:e.typeColumnName)??Xs:void 0,cell:r=>n||r.row.getIsGrouped()?r.getValue():void 0,getGroupingValue:r=>r.source.id,sortingFn:(r,o)=>r.original.source.displayName.localeCompare(o.original.source.displayName),enableGrouping:!0},{accessorFn:r=>r.detail,id,header:(e==null?void 0:e.detailsColumnName)??dd,cell:r=>r.getValue(),enableGrouping:!1}]}const pd=e=>{if(!("offset"in e.start))throw new Error("No offset available in range start");if(e.end&&!("offset"in e.end))throw new Error("No offset available in range end");const{offset:t}=e.start;let n=0;return e.end&&({offset:n}=e.end),!e.end||W.compareScrRefs(e.start,e.end)===0?`${W.scrRefToBBBCCCVVV(e.start)}+${t}`:`${W.scrRefToBBBCCCVVV(e.start)}+${t}-${W.scrRefToBBBCCCVVV(e.end)}+${n}`},ia=e=>`${pd({start:e.start,end:e.end})} ${e.source.displayName} ${e.detail}`;function wd({sources:e,showColumnHeaders:t=!1,showSourceColumn:n=!1,scriptureReferenceColumnName:r,scriptureBookGroupName:o,typeColumnName:s,detailsColumnName:i,onRowSelected:l,direction:c="ltr"}){const[d,u]=g.useState([]),[f,w]=g.useState([{id:rt,desc:!1}]),[b,x]=g.useState({}),m=g.useMemo(()=>e.flatMap(C=>C.data.map(_=>({..._,source:C.source}))),[e]),h=g.useMemo(()=>ud({scriptureReferenceColumnName:r,typeColumnName:s,detailsColumnName:i},n),[r,s,i,n]);g.useEffect(()=>{d.includes(pt)?w([{id:pt,desc:!1},{id:rt,desc:!1}]):w([{id:rt,desc:!1}])},[d]);const S=Se.useReactTable({data:m,columns:h,state:{grouping:d,sorting:f,rowSelection:b},onGroupingChange:u,onSortingChange:w,onRowSelectionChange:x,getExpandedRowModel:Se.getExpandedRowModel(),getGroupedRowModel:Se.getGroupedRowModel(),getCoreRowModel:Se.getCoreRowModel(),getSortedRowModel:Se.getSortedRowModel(),getRowId:ia,autoResetExpanded:!1,enableMultiRowSelection:!1,enableSubRowSelection:!1});g.useEffect(()=>{if(l){const C=S.getSelectedRowModel().rowsById,_=Object.keys(C);if(_.length===1){const k=m.find(D=>ia(D)===_[0])||void 0;k&&l(k)}}},[b,m,l,S]);const R=o??cd,j=s??Xs,E=[{label:"No Grouping",value:[]},{label:`Group by ${R}`,value:[rt]},{label:`Group by ${j}`,value:[pt]},{label:`Group by ${R} and ${j}`,value:[rt,pt]},{label:`Group by ${j} and ${R}`,value:[pt,rt]}],v=C=>{u(JSON.parse(C))},P=(C,_)=>{!C.getIsGrouped()&&!C.getIsSelected()&&C.getToggleSelectedHandler()(_)},V=(C,_)=>C.getIsGrouped()?"":N("banded-row",_%2===0?"even":"odd"),U=(C,_,k)=>{if(!((C==null?void 0:C.length)===0||_.depth{v(C)},children:[a.jsx(bt,{className:"tw-mb-1 tw-mt-2",children:a.jsx(Bt,{})}),a.jsx(vt,{position:"item-aligned",children:a.jsx(ks,{children:E.map(C=>a.jsx(Ae,{value:JSON.stringify(C.value),children:C.label},C.label))})})]}),a.jsxs(Cn,{className:"tw-relative tw-flex tw-flex-col tw-overflow-y-auto tw-p-0",children:[t&&a.jsx(Tn,{children:S.getHeaderGroups().map(C=>a.jsx(Ze,{children:C.headers.filter(_=>_.column.columnDef.header).map(_=>a.jsx(Vt,{colSpan:_.colSpan,className:"top-0 tw-sticky",children:_.isPlaceholder?void 0:a.jsxs("div",{children:[_.column.getCanGroup()?a.jsx(fe,{variant:"ghost",title:`Toggle grouping by ${_.column.columnDef.header}`,onClick:_.column.getToggleGroupingHandler(),type:"button",children:_.column.getIsGrouped()?"🛑":"👊 "}):void 0," ",Se.flexRender(_.column.columnDef.header,_.getContext())]})},_.id))},C.id))}),a.jsx(Rn,{children:S.getRowModel().rows.map((C,_)=>a.jsx(Ze,{"data-state":C.getIsSelected()?"selected":"",className:N(V(C,_)),onClick:k=>P(C,k),children:C.getVisibleCells().map(k=>{if(!(k.getIsPlaceholder()||k.column.columnDef.enableGrouping&&!k.getIsGrouped()&&(k.column.columnDef.id!==pt||!n)))return a.jsx(xt,{className:N(k.column.columnDef.id,"tw-p-[1px]",U(d,C,k)),children:(()=>k.getIsGrouped()?a.jsxs(fe,{variant:"link",onClick:C.getToggleExpandedHandler(),type:"button",children:[C.getIsExpanded()&&a.jsx(Q.ChevronDown,{}),!C.getIsExpanded()&&(c==="ltr"?a.jsx(Q.ChevronRight,{}):a.jsx(Q.ChevronLeft,{}))," ",Se.flexRender(k.column.columnDef.cell,k.getContext())," (",C.subRows.length,")"]}):Se.flexRender(k.column.columnDef.cell,k.getContext()))()},k.id)})},C.id))})]})]})}const _r={[W.getLocalizeKeyForScrollGroupId("undefined")]:"Ø",[W.getLocalizeKeyForScrollGroupId(0)]:"A",[W.getLocalizeKeyForScrollGroupId(1)]:"B",[W.getLocalizeKeyForScrollGroupId(2)]:"C",[W.getLocalizeKeyForScrollGroupId(3)]:"D",[W.getLocalizeKeyForScrollGroupId(4)]:"E",[W.getLocalizeKeyForScrollGroupId(5)]:"F",[W.getLocalizeKeyForScrollGroupId(6)]:"G",[W.getLocalizeKeyForScrollGroupId(7)]:"H",[W.getLocalizeKeyForScrollGroupId(8)]:"I",[W.getLocalizeKeyForScrollGroupId(9)]:"J",[W.getLocalizeKeyForScrollGroupId(10)]:"K",[W.getLocalizeKeyForScrollGroupId(11)]:"L",[W.getLocalizeKeyForScrollGroupId(12)]:"M",[W.getLocalizeKeyForScrollGroupId(13)]:"N",[W.getLocalizeKeyForScrollGroupId(14)]:"O",[W.getLocalizeKeyForScrollGroupId(15)]:"P",[W.getLocalizeKeyForScrollGroupId(16)]:"Q",[W.getLocalizeKeyForScrollGroupId(17)]:"R",[W.getLocalizeKeyForScrollGroupId(18)]:"S",[W.getLocalizeKeyForScrollGroupId(19)]:"T",[W.getLocalizeKeyForScrollGroupId(20)]:"U",[W.getLocalizeKeyForScrollGroupId(21)]:"V",[W.getLocalizeKeyForScrollGroupId(22)]:"W",[W.getLocalizeKeyForScrollGroupId(23)]:"X",[W.getLocalizeKeyForScrollGroupId(24)]:"Y",[W.getLocalizeKeyForScrollGroupId(25)]:"Z"};function fd({availableScrollGroupIds:e,scrollGroupId:t,onChangeScrollGroupId:n,localizedStrings:r={}}){const o={..._r,...Object.fromEntries(Object.entries(r).map(([s,i])=>[s,s===i&&s in _r?_r[s]:i]))};return a.jsxs(At,{value:`${t}`,onValueChange:s=>n(s==="undefined"?void 0:parseInt(s,10)),children:[a.jsx(bt,{className:"pr-twp tw-w-auto",children:a.jsx(Bt,{placeholder:o[W.getLocalizeKeyForScrollGroupId(t)]??t})}),a.jsx(vt,{style:{zIndex:250},children:e.map(s=>a.jsx(Ae,{value:`${s}`,children:o[W.getLocalizeKeyForScrollGroupId(s)]},`${s}`))})]})}function md({children:e}){return a.jsx("div",{className:"pr-twp tw-grid",children:e})}function hd({primary:e,secondary:t,children:n,isLoading:r=!1,loadingMessage:o}){return a.jsxs("div",{className:"tw-flex tw-items-center tw-justify-between tw-space-x-4 tw-py-2",children:[a.jsxs("div",{children:[a.jsx("p",{className:"tw-text-sm tw-font-medium tw-leading-none",children:e}),a.jsx("p",{className:"tw-whitespace-normal tw-break-words tw-text-sm tw-text-muted-foreground",children:t})]}),r?a.jsx("p",{className:"tw-text-sm tw-text-muted-foreground",children:o}):a.jsx("div",{children:n})]})}function gd({primary:e,secondary:t,includeSeparator:n=!1}){return a.jsxs("div",{className:"tw-space-y-4 tw-py-2",children:[a.jsxs("div",{children:[a.jsx("h3",{className:"tw-text-lg tw-font-medium",children:e}),a.jsx("p",{className:"tw-text-sm tw-text-muted-foreground",children:t})]}),n?a.jsx(lr,{}):""]})}function bd({id:e,className:t,listItems:n,selectedListItems:r,handleSelectListItem:o,createLabel:s}){return a.jsx("div",{id:e,className:t,children:n.map(i=>a.jsxs("div",{className:"tw-m-2 tw-flex tw-items-center",children:[a.jsx(sr,{className:"tw-mr-2 tw-align-middle",checked:r.includes(i),onCheckedChange:l=>o(i,l)}),a.jsx(qe,{children:s?s(i):i})]},i))})}function vd(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}function xd(e){if(e.__esModule)return e;var t=e.default;if(typeof t=="function"){var n=function r(){return this instanceof r?Reflect.construct(t,arguments,this.constructor):t.apply(this,arguments)};n.prototype=t.prototype}else n={};return Object.defineProperty(n,"__esModule",{value:!0}),Object.keys(e).forEach(function(r){var o=Object.getOwnPropertyDescriptor(e,r);Object.defineProperty(n,r,o.get?o:{enumerable:!0,get:function(){return e[r]}})}),n}var xo={},Ys={exports:{}};(function(e){function t(n){return n&&n.__esModule?n:{default:n}}e.exports=t,e.exports.__esModule=!0,e.exports.default=e.exports})(Ys);var yd=Ys.exports,Pr={};function yo(e,t){return process.env.NODE_ENV==="production"?()=>null:function(...r){return e(...r)||t(...r)}}function O(){return O=Object.assign?Object.assign.bind():function(e){for(var t=1;t{t[n]=Ws(e[n])}),t}function Qe(e,t,n={clone:!0}){const r=n.clone?O({},e):e;return mt(e)&&mt(t)&&Object.keys(t).forEach(o=>{o!=="__proto__"&&(mt(t[o])&&o in e&&mt(e[o])?r[o]=Qe(e[o],t[o],n):n.clone?r[o]=mt(t[o])?Ws(t[o]):t[o]:r[o]=t[o])}),r}var Kr={exports:{}},zn={exports:{}},ie={};/** @license React v16.13.1 * react-is.production.min.js * * Copyright (c) Facebook, Inc. and its affiliates. * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. - */var la;function Nd(){if(la)return ie;la=1;var e=typeof Symbol=="function"&&Symbol.for,t=e?Symbol.for("react.element"):60103,n=e?Symbol.for("react.portal"):60106,r=e?Symbol.for("react.fragment"):60107,o=e?Symbol.for("react.strict_mode"):60108,s=e?Symbol.for("react.profiler"):60114,i=e?Symbol.for("react.provider"):60109,l=e?Symbol.for("react.context"):60110,c=e?Symbol.for("react.async_mode"):60111,u=e?Symbol.for("react.concurrent_mode"):60111,d=e?Symbol.for("react.forward_ref"):60112,m=e?Symbol.for("react.suspense"):60113,w=e?Symbol.for("react.suspense_list"):60120,b=e?Symbol.for("react.memo"):60115,x=e?Symbol.for("react.lazy"):60116,f=e?Symbol.for("react.block"):60121,h=e?Symbol.for("react.fundamental"):60117,S=e?Symbol.for("react.responder"):60118,R=e?Symbol.for("react.scope"):60119;function j(v){if(typeof v=="object"&&v!==null){var P=v.$$typeof;switch(P){case t:switch(v=v.type,v){case c:case u:case r:case s:case o:case m:return v;default:switch(v=v&&v.$$typeof,v){case l:case d:case x:case b:case i:return v;default:return P}}case n:return P}}}function E(v){return j(v)===u}return ie.AsyncMode=c,ie.ConcurrentMode=u,ie.ContextConsumer=l,ie.ContextProvider=i,ie.Element=t,ie.ForwardRef=d,ie.Fragment=r,ie.Lazy=x,ie.Memo=b,ie.Portal=n,ie.Profiler=s,ie.StrictMode=o,ie.Suspense=m,ie.isAsyncMode=function(v){return E(v)||j(v)===c},ie.isConcurrentMode=E,ie.isContextConsumer=function(v){return j(v)===l},ie.isContextProvider=function(v){return j(v)===i},ie.isElement=function(v){return typeof v=="object"&&v!==null&&v.$$typeof===t},ie.isForwardRef=function(v){return j(v)===d},ie.isFragment=function(v){return j(v)===r},ie.isLazy=function(v){return j(v)===x},ie.isMemo=function(v){return j(v)===b},ie.isPortal=function(v){return j(v)===n},ie.isProfiler=function(v){return j(v)===s},ie.isStrictMode=function(v){return j(v)===o},ie.isSuspense=function(v){return j(v)===m},ie.isValidElementType=function(v){return typeof v=="string"||typeof v=="function"||v===r||v===u||v===s||v===o||v===m||v===w||typeof v=="object"&&v!==null&&(v.$$typeof===x||v.$$typeof===b||v.$$typeof===i||v.$$typeof===l||v.$$typeof===d||v.$$typeof===h||v.$$typeof===S||v.$$typeof===R||v.$$typeof===f)},ie.typeOf=j,ie}var le={};/** @license React v16.13.1 + */var la;function Nd(){if(la)return ie;la=1;var e=typeof Symbol=="function"&&Symbol.for,t=e?Symbol.for("react.element"):60103,n=e?Symbol.for("react.portal"):60106,r=e?Symbol.for("react.fragment"):60107,o=e?Symbol.for("react.strict_mode"):60108,s=e?Symbol.for("react.profiler"):60114,i=e?Symbol.for("react.provider"):60109,l=e?Symbol.for("react.context"):60110,c=e?Symbol.for("react.async_mode"):60111,d=e?Symbol.for("react.concurrent_mode"):60111,u=e?Symbol.for("react.forward_ref"):60112,f=e?Symbol.for("react.suspense"):60113,w=e?Symbol.for("react.suspense_list"):60120,b=e?Symbol.for("react.memo"):60115,x=e?Symbol.for("react.lazy"):60116,m=e?Symbol.for("react.block"):60121,h=e?Symbol.for("react.fundamental"):60117,S=e?Symbol.for("react.responder"):60118,R=e?Symbol.for("react.scope"):60119;function j(v){if(typeof v=="object"&&v!==null){var P=v.$$typeof;switch(P){case t:switch(v=v.type,v){case c:case d:case r:case s:case o:case f:return v;default:switch(v=v&&v.$$typeof,v){case l:case u:case x:case b:case i:return v;default:return P}}case n:return P}}}function E(v){return j(v)===d}return ie.AsyncMode=c,ie.ConcurrentMode=d,ie.ContextConsumer=l,ie.ContextProvider=i,ie.Element=t,ie.ForwardRef=u,ie.Fragment=r,ie.Lazy=x,ie.Memo=b,ie.Portal=n,ie.Profiler=s,ie.StrictMode=o,ie.Suspense=f,ie.isAsyncMode=function(v){return E(v)||j(v)===c},ie.isConcurrentMode=E,ie.isContextConsumer=function(v){return j(v)===l},ie.isContextProvider=function(v){return j(v)===i},ie.isElement=function(v){return typeof v=="object"&&v!==null&&v.$$typeof===t},ie.isForwardRef=function(v){return j(v)===u},ie.isFragment=function(v){return j(v)===r},ie.isLazy=function(v){return j(v)===x},ie.isMemo=function(v){return j(v)===b},ie.isPortal=function(v){return j(v)===n},ie.isProfiler=function(v){return j(v)===s},ie.isStrictMode=function(v){return j(v)===o},ie.isSuspense=function(v){return j(v)===f},ie.isValidElementType=function(v){return typeof v=="string"||typeof v=="function"||v===r||v===d||v===s||v===o||v===f||v===w||typeof v=="object"&&v!==null&&(v.$$typeof===x||v.$$typeof===b||v.$$typeof===i||v.$$typeof===l||v.$$typeof===u||v.$$typeof===h||v.$$typeof===S||v.$$typeof===R||v.$$typeof===m)},ie.typeOf=j,ie}var le={};/** @license React v16.13.1 * react-is.development.js * * Copyright (c) Facebook, Inc. and its affiliates. * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. - */var ca;function kd(){return ca||(ca=1,process.env.NODE_ENV!=="production"&&function(){var e=typeof Symbol=="function"&&Symbol.for,t=e?Symbol.for("react.element"):60103,n=e?Symbol.for("react.portal"):60106,r=e?Symbol.for("react.fragment"):60107,o=e?Symbol.for("react.strict_mode"):60108,s=e?Symbol.for("react.profiler"):60114,i=e?Symbol.for("react.provider"):60109,l=e?Symbol.for("react.context"):60110,c=e?Symbol.for("react.async_mode"):60111,u=e?Symbol.for("react.concurrent_mode"):60111,d=e?Symbol.for("react.forward_ref"):60112,m=e?Symbol.for("react.suspense"):60113,w=e?Symbol.for("react.suspense_list"):60120,b=e?Symbol.for("react.memo"):60115,x=e?Symbol.for("react.lazy"):60116,f=e?Symbol.for("react.block"):60121,h=e?Symbol.for("react.fundamental"):60117,S=e?Symbol.for("react.responder"):60118,R=e?Symbol.for("react.scope"):60119;function j(I){return typeof I=="string"||typeof I=="function"||I===r||I===u||I===s||I===o||I===m||I===w||typeof I=="object"&&I!==null&&(I.$$typeof===x||I.$$typeof===b||I.$$typeof===i||I.$$typeof===l||I.$$typeof===d||I.$$typeof===h||I.$$typeof===S||I.$$typeof===R||I.$$typeof===f)}function E(I){if(typeof I=="object"&&I!==null){var ye=I.$$typeof;switch(ye){case t:var A=I.type;switch(A){case c:case u:case r:case s:case o:case m:return A;default:var xe=A&&A.$$typeof;switch(xe){case l:case d:case x:case b:case i:return xe;default:return ye}}case n:return ye}}}var v=c,P=u,V=l,U=i,C=t,_=d,k=r,D=x,$=b,J=n,Y=s,F=o,te=m,se=!1;function oe(I){return se||(se=!0,console.warn("The ReactIs.isAsyncMode() alias has been deprecated, and will be removed in React 17+. Update your code to use ReactIs.isConcurrentMode() instead. It has the exact same API.")),y(I)||E(I)===c}function y(I){return E(I)===u}function T(I){return E(I)===l}function z(I){return E(I)===i}function L(I){return typeof I=="object"&&I!==null&&I.$$typeof===t}function B(I){return E(I)===d}function X(I){return E(I)===r}function q(I){return E(I)===x}function H(I){return E(I)===b}function G(I){return E(I)===n}function K(I){return E(I)===s}function Z(I){return E(I)===o}function ue(I){return E(I)===m}le.AsyncMode=v,le.ConcurrentMode=P,le.ContextConsumer=V,le.ContextProvider=U,le.Element=C,le.ForwardRef=_,le.Fragment=k,le.Lazy=D,le.Memo=$,le.Portal=J,le.Profiler=Y,le.StrictMode=F,le.Suspense=te,le.isAsyncMode=oe,le.isConcurrentMode=y,le.isContextConsumer=T,le.isContextProvider=z,le.isElement=L,le.isForwardRef=B,le.isFragment=X,le.isLazy=q,le.isMemo=H,le.isPortal=G,le.isProfiler=K,le.isStrictMode=Z,le.isSuspense=ue,le.isValidElementType=j,le.typeOf=E}()),le}var da;function Ks(){return da||(da=1,process.env.NODE_ENV==="production"?zn.exports=Nd():zn.exports=kd()),zn.exports}/* + */var ca;function kd(){return ca||(ca=1,process.env.NODE_ENV!=="production"&&function(){var e=typeof Symbol=="function"&&Symbol.for,t=e?Symbol.for("react.element"):60103,n=e?Symbol.for("react.portal"):60106,r=e?Symbol.for("react.fragment"):60107,o=e?Symbol.for("react.strict_mode"):60108,s=e?Symbol.for("react.profiler"):60114,i=e?Symbol.for("react.provider"):60109,l=e?Symbol.for("react.context"):60110,c=e?Symbol.for("react.async_mode"):60111,d=e?Symbol.for("react.concurrent_mode"):60111,u=e?Symbol.for("react.forward_ref"):60112,f=e?Symbol.for("react.suspense"):60113,w=e?Symbol.for("react.suspense_list"):60120,b=e?Symbol.for("react.memo"):60115,x=e?Symbol.for("react.lazy"):60116,m=e?Symbol.for("react.block"):60121,h=e?Symbol.for("react.fundamental"):60117,S=e?Symbol.for("react.responder"):60118,R=e?Symbol.for("react.scope"):60119;function j(I){return typeof I=="string"||typeof I=="function"||I===r||I===d||I===s||I===o||I===f||I===w||typeof I=="object"&&I!==null&&(I.$$typeof===x||I.$$typeof===b||I.$$typeof===i||I.$$typeof===l||I.$$typeof===u||I.$$typeof===h||I.$$typeof===S||I.$$typeof===R||I.$$typeof===m)}function E(I){if(typeof I=="object"&&I!==null){var ye=I.$$typeof;switch(ye){case t:var A=I.type;switch(A){case c:case d:case r:case s:case o:case f:return A;default:var xe=A&&A.$$typeof;switch(xe){case l:case u:case x:case b:case i:return xe;default:return ye}}case n:return ye}}}var v=c,P=d,V=l,U=i,C=t,_=u,k=r,D=x,$=b,J=n,Y=s,F=o,te=f,se=!1;function oe(I){return se||(se=!0,console.warn("The ReactIs.isAsyncMode() alias has been deprecated, and will be removed in React 17+. Update your code to use ReactIs.isConcurrentMode() instead. It has the exact same API.")),y(I)||E(I)===c}function y(I){return E(I)===d}function T(I){return E(I)===l}function z(I){return E(I)===i}function L(I){return typeof I=="object"&&I!==null&&I.$$typeof===t}function B(I){return E(I)===u}function X(I){return E(I)===r}function q(I){return E(I)===x}function H(I){return E(I)===b}function G(I){return E(I)===n}function K(I){return E(I)===s}function Z(I){return E(I)===o}function ue(I){return E(I)===f}le.AsyncMode=v,le.ConcurrentMode=P,le.ContextConsumer=V,le.ContextProvider=U,le.Element=C,le.ForwardRef=_,le.Fragment=k,le.Lazy=D,le.Memo=$,le.Portal=J,le.Profiler=Y,le.StrictMode=F,le.Suspense=te,le.isAsyncMode=oe,le.isConcurrentMode=y,le.isContextConsumer=T,le.isContextProvider=z,le.isElement=L,le.isForwardRef=B,le.isFragment=X,le.isLazy=q,le.isMemo=H,le.isPortal=G,le.isProfiler=K,le.isStrictMode=Z,le.isSuspense=ue,le.isValidElementType=j,le.typeOf=E}()),le}var da;function Ks(){return da||(da=1,process.env.NODE_ENV==="production"?zn.exports=Nd():zn.exports=kd()),zn.exports}/* object-assign (c) Sindre Sorhus @license MIT -*/var Ir,ua;function Sd(){if(ua)return Ir;ua=1;var e=Object.getOwnPropertySymbols,t=Object.prototype.hasOwnProperty,n=Object.prototype.propertyIsEnumerable;function r(s){if(s==null)throw new TypeError("Object.assign cannot be called with null or undefined");return Object(s)}function o(){try{if(!Object.assign)return!1;var s=new String("abc");if(s[5]="de",Object.getOwnPropertyNames(s)[0]==="5")return!1;for(var i={},l=0;l<10;l++)i["_"+String.fromCharCode(l)]=l;var c=Object.getOwnPropertyNames(i).map(function(d){return i[d]});if(c.join("")!=="0123456789")return!1;var u={};return"abcdefghijklmnopqrst".split("").forEach(function(d){u[d]=d}),Object.keys(Object.assign({},u)).join("")==="abcdefghijklmnopqrst"}catch{return!1}}return Ir=o()?Object.assign:function(s,i){for(var l,c=r(s),u,d=1;d1?s("Invalid arguments supplied to oneOf, expected an array, got "+arguments.length+" arguments. A common mistake is to write oneOf(x, y, z) instead of oneOf([x, y, z])."):s("Invalid argument supplied to oneOf, expected an array.")),i;function T(z,L,B,X,q){for(var H=z[L],G=0;G0?", expected one of type ["+K.join(", ")+"]":"";return new f("Invalid "+H+" `"+G+"` supplied to "+("`"+q+"`"+ye+"."))}return h(L)}function _(){function y(T,z,L,B,X){return J(T[z])?null:new f("Invalid "+B+" `"+X+"` supplied to "+("`"+L+"`, expected a ReactNode."))}return h(y)}function k(y,T,z,L,B){return new f((y||"React class")+": "+T+" type `"+z+"."+L+"` is invalid; it must be a function, usually from the `prop-types` package, but received `"+B+"`.")}function D(y){function T(z,L,B,X,q){var H=z[L],G=F(H);if(G!=="object")return new f("Invalid "+X+" `"+q+"` of type `"+G+"` "+("supplied to `"+B+"`, expected `object`."));for(var K in y){var Z=y[K];if(typeof Z!="function")return k(B,X,q,K,te(Z));var ue=Z(H,K,B,X,q+"."+K,n);if(ue)return ue}return null}return h(T)}function $(y){function T(z,L,B,X,q){var H=z[L],G=F(H);if(G!=="object")return new f("Invalid "+X+" `"+q+"` of type `"+G+"` "+("supplied to `"+B+"`, expected `object`."));var K=t({},z[L],y);for(var Z in K){var ue=y[Z];if(r(y,Z)&&typeof ue!="function")return k(B,X,q,Z,te(ue));if(!ue)return new f("Invalid "+X+" `"+q+"` key `"+Z+"` supplied to `"+B+"`.\nBad object: "+JSON.stringify(z[L],null," ")+` -Valid keys: `+JSON.stringify(Object.keys(y),null," "));var I=ue(H,Z,B,X,q+"."+Z,n);if(I)return I}return null}return h(T)}function J(y){switch(typeof y){case"number":case"string":case"undefined":return!0;case"boolean":return!y;case"object":if(Array.isArray(y))return y.every(J);if(y===null||l(y))return!0;var T=m(y);if(T){var z=T.call(y),L;if(T!==y.entries){for(;!(L=z.next()).done;)if(!J(L.value))return!1}else for(;!(L=z.next()).done;){var B=L.value;if(B&&!J(B[1]))return!1}}else return!1;return!0;default:return!1}}function Y(y,T){return y==="symbol"?!0:T?T["@@toStringTag"]==="Symbol"||typeof Symbol=="function"&&T instanceof Symbol:!1}function F(y){var T=typeof y;return Array.isArray(y)?"array":y instanceof RegExp?"object":Y(T,y)?"symbol":T}function te(y){if(typeof y>"u"||y===null)return""+y;var T=F(y);if(T==="object"){if(y instanceof Date)return"date";if(y instanceof RegExp)return"regexp"}return T}function se(y){var T=te(y);switch(T){case"array":case"object":return"an "+T;case"boolean":case"date":case"regexp":return"a "+T;default:return T}}function oe(y){return!y.constructor||!y.constructor.name?w:y.constructor.name}return b.checkPropTypes=o,b.resetWarningCache=o.resetWarningCache,b.PropTypes=b,b},Ar}var Br,ha;function Cd(){if(ha)return Br;ha=1;var e=No();function t(){}function n(){}return n.resetWarningCache=t,Br=function(){function r(i,l,c,u,d,m){if(m!==e){var w=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types");throw w.name="Invariant Violation",w}}r.isRequired=r;function o(){return r}var s={array:r,bigint:r,bool:r,func:r,number:r,object:r,string:r,symbol:r,any:r,arrayOf:o,element:r,elementType:r,instanceOf:o,node:r,objectOf:o,oneOf:o,oneOfType:o,shape:o,exact:o,checkPropTypes:n,resetWarningCache:t};return s.PropTypes=s,s},Br}if(process.env.NODE_ENV!=="production"){var Td=Ks(),Rd=!0;Kr.exports=jd()(Td.isElement,Rd)}else Kr.exports=Cd()();var Od=Kr.exports;const p=vd(Od);function _d(e){const{prototype:t={}}=e;return!!t.isReactComponent}function Zs(e,t,n,r,o){const s=e[t],i=o||t;if(s==null||typeof window>"u")return null;let l;const c=s.type;return typeof c=="function"&&!_d(c)&&(l="Did you accidentally use a plain function component for an element instead?"),l!==void 0?new Error(`Invalid ${r} \`${i}\` supplied to \`${n}\`. Expected an element that can hold a ref. ${l} For more information see https://mui.com/r/caveat-with-refs-guide`):null}const Qs=yo(p.element,Zs);Qs.isRequired=yo(p.element.isRequired,Zs);const ei=Qs,Pd="exact-prop: ​";function Id(e){return process.env.NODE_ENV==="production"?e:O({},e,{[Pd]:t=>{const n=Object.keys(t).filter(r=>!e.hasOwnProperty(r));return n.length>0?new Error(`The following props are not supported: ${n.map(r=>`\`${r}\``).join(", ")}. Please remove them.`):null}})}function zt(e){let t="https://mui.com/production-error/?code="+e;for(let n=1;n1?s("Invalid arguments supplied to oneOf, expected an array, got "+arguments.length+" arguments. A common mistake is to write oneOf(x, y, z) instead of oneOf([x, y, z])."):s("Invalid argument supplied to oneOf, expected an array.")),i;function T(z,L,B,X,q){for(var H=z[L],G=0;G0?", expected one of type ["+K.join(", ")+"]":"";return new m("Invalid "+H+" `"+G+"` supplied to "+("`"+q+"`"+ye+"."))}return h(L)}function _(){function y(T,z,L,B,X){return J(T[z])?null:new m("Invalid "+B+" `"+X+"` supplied to "+("`"+L+"`, expected a ReactNode."))}return h(y)}function k(y,T,z,L,B){return new m((y||"React class")+": "+T+" type `"+z+"."+L+"` is invalid; it must be a function, usually from the `prop-types` package, but received `"+B+"`.")}function D(y){function T(z,L,B,X,q){var H=z[L],G=F(H);if(G!=="object")return new m("Invalid "+X+" `"+q+"` of type `"+G+"` "+("supplied to `"+B+"`, expected `object`."));for(var K in y){var Z=y[K];if(typeof Z!="function")return k(B,X,q,K,te(Z));var ue=Z(H,K,B,X,q+"."+K,n);if(ue)return ue}return null}return h(T)}function $(y){function T(z,L,B,X,q){var H=z[L],G=F(H);if(G!=="object")return new m("Invalid "+X+" `"+q+"` of type `"+G+"` "+("supplied to `"+B+"`, expected `object`."));var K=t({},z[L],y);for(var Z in K){var ue=y[Z];if(r(y,Z)&&typeof ue!="function")return k(B,X,q,Z,te(ue));if(!ue)return new m("Invalid "+X+" `"+q+"` key `"+Z+"` supplied to `"+B+"`.\nBad object: "+JSON.stringify(z[L],null," ")+` +Valid keys: `+JSON.stringify(Object.keys(y),null," "));var I=ue(H,Z,B,X,q+"."+Z,n);if(I)return I}return null}return h(T)}function J(y){switch(typeof y){case"number":case"string":case"undefined":return!0;case"boolean":return!y;case"object":if(Array.isArray(y))return y.every(J);if(y===null||l(y))return!0;var T=f(y);if(T){var z=T.call(y),L;if(T!==y.entries){for(;!(L=z.next()).done;)if(!J(L.value))return!1}else for(;!(L=z.next()).done;){var B=L.value;if(B&&!J(B[1]))return!1}}else return!1;return!0;default:return!1}}function Y(y,T){return y==="symbol"?!0:T?T["@@toStringTag"]==="Symbol"||typeof Symbol=="function"&&T instanceof Symbol:!1}function F(y){var T=typeof y;return Array.isArray(y)?"array":y instanceof RegExp?"object":Y(T,y)?"symbol":T}function te(y){if(typeof y>"u"||y===null)return""+y;var T=F(y);if(T==="object"){if(y instanceof Date)return"date";if(y instanceof RegExp)return"regexp"}return T}function se(y){var T=te(y);switch(T){case"array":case"object":return"an "+T;case"boolean":case"date":case"regexp":return"a "+T;default:return T}}function oe(y){return!y.constructor||!y.constructor.name?w:y.constructor.name}return b.checkPropTypes=o,b.resetWarningCache=o.resetWarningCache,b.PropTypes=b,b},Ar}var Br,ha;function Cd(){if(ha)return Br;ha=1;var e=No();function t(){}function n(){}return n.resetWarningCache=t,Br=function(){function r(i,l,c,d,u,f){if(f!==e){var w=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types");throw w.name="Invariant Violation",w}}r.isRequired=r;function o(){return r}var s={array:r,bigint:r,bool:r,func:r,number:r,object:r,string:r,symbol:r,any:r,arrayOf:o,element:r,elementType:r,instanceOf:o,node:r,objectOf:o,oneOf:o,oneOfType:o,shape:o,exact:o,checkPropTypes:n,resetWarningCache:t};return s.PropTypes=s,s},Br}if(process.env.NODE_ENV!=="production"){var Td=Ks(),Rd=!0;Kr.exports=jd()(Td.isElement,Rd)}else Kr.exports=Cd()();var Od=Kr.exports;const p=vd(Od);function _d(e){const{prototype:t={}}=e;return!!t.isReactComponent}function Zs(e,t,n,r,o){const s=e[t],i=o||t;if(s==null||typeof window>"u")return null;let l;const c=s.type;return typeof c=="function"&&!_d(c)&&(l="Did you accidentally use a plain function component for an element instead?"),l!==void 0?new Error(`Invalid ${r} \`${i}\` supplied to \`${n}\`. Expected an element that can hold a ref. ${l} For more information see https://mui.com/r/caveat-with-refs-guide`):null}const Qs=yo(p.element,Zs);Qs.isRequired=yo(p.element.isRequired,Zs);const ei=Qs,Pd="exact-prop: ​";function Id(e){return process.env.NODE_ENV==="production"?e:O({},e,{[Pd]:t=>{const n=Object.keys(t).filter(r=>!e.hasOwnProperty(r));return n.length>0?new Error(`The following props are not supported: ${n.map(r=>`\`${r}\``).join(", ")}. Please remove them.`):null}})}function zt(e){let t="https://mui.com/production-error/?code="+e;for(let n=1;nn==null?t:function(...o){t.apply(this,o),n.apply(this,o)},()=>{})}function Ld(e,t=166){let n;function r(...o){const s=()=>{e.apply(this,o)};clearTimeout(n),n=setTimeout(s,t)}return r.clear=()=>{clearTimeout(n)},r}function Fd(e,t){return process.env.NODE_ENV==="production"?()=>null:(n,r,o,s,i)=>{const l=o||"<>",c=i||r;return typeof n[r]<"u"?new Error(`The ${s} \`${c}\` of \`${l}\` is deprecated. ${t}`):null}}function Gd(e,t){var n,r;return M.isValidElement(e)&&t.indexOf((n=e.type.muiName)!=null?n:(r=e.type)==null||(r=r._payload)==null||(r=r.value)==null?void 0:r.muiName)!==-1}function Kn(e){return e&&e.ownerDocument||document}function Ud(e){return Kn(e).defaultView||window}function qd(e,t){if(process.env.NODE_ENV==="production")return()=>null;const n=t?O({},t.propTypes):null;return o=>(s,i,l,c,u,...d)=>{const m=u||i,w=n==null?void 0:n[m];if(w){const b=w(s,i,l,c,u,...d);if(b)return b}return typeof s[i]<"u"&&!s[o]?new Error(`The prop \`${m}\` of \`${e}\` can only be used together with the \`${o}\` prop.`):null}}function Jn(e,t){typeof e=="function"?e(t):e&&(e.current=t)}const Hd=typeof window<"u"?M.useLayoutEffect:M.useEffect,Lt=Hd;let ya=0;function Xd(e){const[t,n]=M.useState(e),r=e||t;return M.useEffect(()=>{t==null&&(ya+=1,n(`mui-${ya}`))},[t]),r}const Na=M["useId".toString()];function ri(e){if(Na!==void 0){const t=Na();return e??t}return Xd(e)}function Yd(e,t,n,r,o){if(process.env.NODE_ENV==="production")return null;const s=o||t;return typeof e[t]<"u"?new Error(`The prop \`${s}\` is not supported. Please remove it.`):null}function oi({controlled:e,default:t,name:n,state:r="value"}){const{current:o}=M.useRef(e!==void 0),[s,i]=M.useState(t),l=o?e:s;if(process.env.NODE_ENV!=="production"){M.useEffect(()=>{o!==(e!==void 0)&&console.error([`MUI: A component is changing the ${o?"":"un"}controlled ${r} state of ${n} to be ${o?"un":""}controlled.`,"Elements should not switch from uncontrolled to controlled (or vice versa).",`Decide between using a controlled or uncontrolled ${n} element for the lifetime of the component.`,"The nature of the state is determined during the first render. It's considered controlled if the value is not `undefined`.","More info: https://fb.me/react-controlled-components"].join(` -`))},[r,n,e]);const{current:u}=M.useRef(t);M.useEffect(()=>{!o&&u!==t&&console.error([`MUI: A component is changing the default ${r} state of an uncontrolled ${n} after being initialized. To suppress this warning opt to use a controlled ${n}.`].join(` -`))},[JSON.stringify(t)])}const c=M.useCallback(u=>{o||i(u)},[]);return[l,c]}function Zr(e){const t=M.useRef(e);return Lt(()=>{t.current=e}),M.useRef((...n)=>(0,t.current)(...n)).current}function yt(...e){return M.useMemo(()=>e.every(t=>t==null)?null:t=>{e.forEach(n=>{Jn(n,t)})},e)}const ka={};function Wd(e,t){const n=M.useRef(ka);return n.current===ka&&(n.current=e(t)),n}const Kd=[];function Jd(e){M.useEffect(e,Kd)}class On{constructor(){this.currentId=null,this.clear=()=>{this.currentId!==null&&(clearTimeout(this.currentId),this.currentId=null)},this.disposeEffect=()=>this.clear}static create(){return new On}start(t,n){this.clear(),this.currentId=setTimeout(()=>{this.currentId=null,n()},t)}}function dn(){const e=Wd(On.create).current;return Jd(e.disposeEffect),e}let dr=!0,Qr=!1;const Zd=new On,Qd={text:!0,search:!0,url:!0,tel:!0,email:!0,password:!0,number:!0,date:!0,month:!0,week:!0,time:!0,datetime:!0,"datetime-local":!0};function eu(e){const{type:t,tagName:n}=e;return!!(n==="INPUT"&&Qd[t]&&!e.readOnly||n==="TEXTAREA"&&!e.readOnly||e.isContentEditable)}function tu(e){e.metaKey||e.altKey||e.ctrlKey||(dr=!0)}function Vr(){dr=!1}function nu(){this.visibilityState==="hidden"&&Qr&&(dr=!0)}function ru(e){e.addEventListener("keydown",tu,!0),e.addEventListener("mousedown",Vr,!0),e.addEventListener("pointerdown",Vr,!0),e.addEventListener("touchstart",Vr,!0),e.addEventListener("visibilitychange",nu,!0)}function ou(e){const{target:t}=e;try{return t.matches(":focus-visible")}catch{}return dr||eu(t)}function ai(){const e=M.useCallback(o=>{o!=null&&ru(o.ownerDocument)},[]),t=M.useRef(!1);function n(){return t.current?(Qr=!0,Zd.start(100,()=>{Qr=!1}),t.current=!1,!0):!1}function r(o){return ou(o)?(t.current=!0,!0):!1}return{isFocusVisibleRef:t,onFocus:r,onBlur:n,ref:e}}function si(e,t){const n=O({},t);return Object.keys(e).forEach(r=>{if(r.toString().match(/^(components|slots)$/))n[r]=O({},e[r],n[r]);else if(r.toString().match(/^(componentsProps|slotProps)$/)){const o=e[r]||{},s=t[r];n[r]={},!s||!Object.keys(s)?n[r]=o:!o||!Object.keys(o)?n[r]=s:(n[r]=O({},s),Object.keys(o).forEach(i=>{n[r][i]=si(o[i],s[i])}))}else n[r]===void 0&&(n[r]=e[r])}),n}function ko(e,t,n=void 0){const r={};return Object.keys(e).forEach(o=>{r[o]=e[o].reduce((s,i)=>{if(i){const l=t(i);l!==""&&s.push(l),n&&n[i]&&s.push(n[i])}return s},[]).join(" ")}),r}const Sa=e=>e,au=()=>{let e=Sa;return{configure(t){e=t},generate(t){return e(t)},reset(){e=Sa}}},su=au(),ii=su,li={active:"active",checked:"checked",completed:"completed",disabled:"disabled",error:"error",expanded:"expanded",focused:"focused",focusVisible:"focusVisible",open:"open",readOnly:"readOnly",required:"required",selected:"selected"};function ur(e,t,n="Mui"){const r=li[t];return r?`${n}-${r}`:`${ii.generate(e)}-${t}`}function ci(e,t,n="Mui"){const r={};return t.forEach(o=>{r[o]=ur(e,o,n)}),r}function iu(e,t=Number.MIN_SAFE_INTEGER,n=Number.MAX_SAFE_INTEGER){return Math.max(t,Math.min(e,n))}function Ne(e,t){if(e==null)return{};var n={},r=Object.keys(e),o,s;for(s=0;s=0)&&(n[o]=e[o]);return n}const lu=["values","unit","step"],cu=e=>{const t=Object.keys(e).map(n=>({key:n,val:e[n]}))||[];return t.sort((n,r)=>n.val-r.val),t.reduce((n,r)=>O({},n,{[r.key]:r.val}),{})};function du(e){const{values:t={xs:0,sm:600,md:900,lg:1200,xl:1536},unit:n="px",step:r=5}=e,o=Ne(e,lu),s=cu(t),i=Object.keys(s);function l(w){return`@media (min-width:${typeof t[w]=="number"?t[w]:w}${n})`}function c(w){return`@media (max-width:${(typeof t[w]=="number"?t[w]:w)-r/100}${n})`}function u(w,b){const x=i.indexOf(b);return`@media (min-width:${typeof t[w]=="number"?t[w]:w}${n}) and (max-width:${(x!==-1&&typeof t[i[x]]=="number"?t[i[x]]:b)-r/100}${n})`}function d(w){return i.indexOf(w)+1`@media (min-width:${So[e]}px)`};function et(e,t,n){const r=e.theme||{};if(Array.isArray(t)){const s=r.breakpoints||Ea;return t.reduce((i,l,c)=>(i[s.up(s.keys[c])]=n(t[c]),i),{})}if(typeof t=="object"){const s=r.breakpoints||Ea;return Object.keys(t).reduce((i,l)=>{if(Object.keys(s.values||So).indexOf(l)!==-1){const c=s.up(l);i[c]=n(t[l],l)}else{const c=l;i[c]=t[c]}return i},{})}return n(t)}function fu(e={}){var t;return((t=e.keys)==null?void 0:t.reduce((r,o)=>{const s=e.up(o);return r[s]={},r},{}))||{}}function mu(e,t){return e.reduce((n,r)=>{const o=n[r];return(!o||Object.keys(o).length===0)&&delete n[r],n},t)}function pr(e,t,n=!0){if(!t||typeof t!="string")return null;if(e&&e.vars&&n){const r=`vars.${t}`.split(".").reduce((o,s)=>o&&o[s]?o[s]:null,e);if(r!=null)return r}return t.split(".").reduce((r,o)=>r&&r[o]!=null?r[o]:null,e)}function Zn(e,t,n,r=n){let o;return typeof e=="function"?o=e(n):Array.isArray(e)?o=e[n]||r:o=pr(e,n)||r,t&&(o=t(o,r,e)),o}function ve(e){const{prop:t,cssProperty:n=e.prop,themeKey:r,transform:o}=e,s=i=>{if(i[t]==null)return null;const l=i[t],c=i.theme,u=pr(c,r)||{};return et(i,l,m=>{let w=Zn(u,o,m);return m===w&&typeof m=="string"&&(w=Zn(u,o,`${t}${m==="default"?"":Ye(m)}`,m)),n===!1?w:{[n]:w}})};return s.propTypes=process.env.NODE_ENV!=="production"?{[t]:st}:{},s.filterProps=[t],s}function hu(e){const t={};return n=>(t[n]===void 0&&(t[n]=e(n)),t[n])}const gu={m:"margin",p:"padding"},bu={t:"Top",r:"Right",b:"Bottom",l:"Left",x:["Left","Right"],y:["Top","Bottom"]},ja={marginX:"mx",marginY:"my",paddingX:"px",paddingY:"py"},vu=hu(e=>{if(e.length>2)if(ja[e])e=ja[e];else return[e];const[t,n]=e.split(""),r=gu[t],o=bu[n]||"";return Array.isArray(o)?o.map(s=>r+s):[r+o]}),wr=["m","mt","mr","mb","ml","mx","my","margin","marginTop","marginRight","marginBottom","marginLeft","marginX","marginY","marginInline","marginInlineStart","marginInlineEnd","marginBlock","marginBlockStart","marginBlockEnd"],fr=["p","pt","pr","pb","pl","px","py","padding","paddingTop","paddingRight","paddingBottom","paddingLeft","paddingX","paddingY","paddingInline","paddingInlineStart","paddingInlineEnd","paddingBlock","paddingBlockStart","paddingBlockEnd"],xu=[...wr,...fr];function _n(e,t,n,r){var o;const s=(o=pr(e,t,!1))!=null?o:n;return typeof s=="number"?i=>typeof i=="string"?i:(process.env.NODE_ENV!=="production"&&typeof i!="number"&&console.error(`MUI: Expected ${r} argument to be a number or a string, got ${i}.`),s*i):Array.isArray(s)?i=>typeof i=="string"?i:(process.env.NODE_ENV!=="production"&&(Number.isInteger(i)?i>s.length-1&&console.error([`MUI: The value provided (${i}) overflows.`,`The supported values are: ${JSON.stringify(s)}.`,`${i} > ${s.length-1}, you need to add the missing values.`].join(` + */var ba;function $d(){return ba||(ba=1,process.env.NODE_ENV!=="production"&&function(){var e=Symbol.for("react.element"),t=Symbol.for("react.portal"),n=Symbol.for("react.fragment"),r=Symbol.for("react.strict_mode"),o=Symbol.for("react.profiler"),s=Symbol.for("react.provider"),i=Symbol.for("react.context"),l=Symbol.for("react.server_context"),c=Symbol.for("react.forward_ref"),d=Symbol.for("react.suspense"),u=Symbol.for("react.suspense_list"),f=Symbol.for("react.memo"),w=Symbol.for("react.lazy"),b=Symbol.for("react.offscreen"),x=!1,m=!1,h=!1,S=!1,R=!1,j;j=Symbol.for("react.module.reference");function E(A){return!!(typeof A=="string"||typeof A=="function"||A===n||A===o||R||A===r||A===d||A===u||S||A===b||x||m||h||typeof A=="object"&&A!==null&&(A.$$typeof===w||A.$$typeof===f||A.$$typeof===s||A.$$typeof===i||A.$$typeof===c||A.$$typeof===j||A.getModuleId!==void 0))}function v(A){if(typeof A=="object"&&A!==null){var xe=A.$$typeof;switch(xe){case e:var Ge=A.type;switch(Ge){case n:case o:case r:case d:case u:return Ge;default:var lt=Ge&&Ge.$$typeof;switch(lt){case l:case i:case c:case w:case f:case s:return lt;default:return xe}}case t:return xe}}}var P=i,V=s,U=e,C=c,_=n,k=w,D=f,$=t,J=o,Y=r,F=d,te=u,se=!1,oe=!1;function y(A){return se||(se=!0,console.warn("The ReactIs.isAsyncMode() alias has been deprecated, and will be removed in React 18+.")),!1}function T(A){return oe||(oe=!0,console.warn("The ReactIs.isConcurrentMode() alias has been deprecated, and will be removed in React 18+.")),!1}function z(A){return v(A)===i}function L(A){return v(A)===s}function B(A){return typeof A=="object"&&A!==null&&A.$$typeof===e}function X(A){return v(A)===c}function q(A){return v(A)===n}function H(A){return v(A)===w}function G(A){return v(A)===f}function K(A){return v(A)===t}function Z(A){return v(A)===o}function ue(A){return v(A)===r}function I(A){return v(A)===d}function ye(A){return v(A)===u}de.ContextConsumer=P,de.ContextProvider=V,de.Element=U,de.ForwardRef=C,de.Fragment=_,de.Lazy=k,de.Memo=D,de.Portal=$,de.Profiler=J,de.StrictMode=Y,de.Suspense=F,de.SuspenseList=te,de.isAsyncMode=y,de.isConcurrentMode=T,de.isContextConsumer=z,de.isContextProvider=L,de.isElement=B,de.isForwardRef=X,de.isFragment=q,de.isLazy=H,de.isMemo=G,de.isPortal=K,de.isProfiler=Z,de.isStrictMode=ue,de.isSuspense=I,de.isSuspenseList=ye,de.isValidElementType=E,de.typeOf=v}()),de}process.env.NODE_ENV==="production"?Jr.exports=Md():Jr.exports=$d();var va=Jr.exports;const Dd=/^\s*function(?:\s|\s*\/\*.*\*\/\s*)+([^(\s/]*)\s*/;function Ad(e){const t=`${e}`.match(Dd);return t&&t[1]||""}function ti(e,t=""){return e.displayName||e.name||Ad(e)||t}function xa(e,t,n){const r=ti(t);return e.displayName||(r!==""?`${n}(${r})`:n)}function Bd(e){if(e!=null){if(typeof e=="string")return e;if(typeof e=="function")return ti(e,"Component");if(typeof e=="object")switch(e.$$typeof){case va.ForwardRef:return xa(e,e.render,"ForwardRef");case va.Memo:return xa(e,e.type,"memo");default:return}}}function xn(e,t,n,r,o){if(process.env.NODE_ENV==="production")return null;const s=e[t],i=o||t;return s==null?null:s&&s.nodeType!==1?new Error(`Invalid ${r} \`${i}\` supplied to \`${n}\`. Expected an HTMLElement.`):null}const Vd=p.oneOfType([p.func,p.object]),ni=Vd;function Ye(e){if(typeof e!="string")throw new Error(process.env.NODE_ENV!=="production"?"MUI: `capitalize(string)` expects a string argument.":zt(7));return e.charAt(0).toUpperCase()+e.slice(1)}function zd(...e){return e.reduce((t,n)=>n==null?t:function(...o){t.apply(this,o),n.apply(this,o)},()=>{})}function Ld(e,t=166){let n;function r(...o){const s=()=>{e.apply(this,o)};clearTimeout(n),n=setTimeout(s,t)}return r.clear=()=>{clearTimeout(n)},r}function Fd(e,t){return process.env.NODE_ENV==="production"?()=>null:(n,r,o,s,i)=>{const l=o||"<>",c=i||r;return typeof n[r]<"u"?new Error(`The ${s} \`${c}\` of \`${l}\` is deprecated. ${t}`):null}}function Gd(e,t){var n,r;return M.isValidElement(e)&&t.indexOf((n=e.type.muiName)!=null?n:(r=e.type)==null||(r=r._payload)==null||(r=r.value)==null?void 0:r.muiName)!==-1}function Kn(e){return e&&e.ownerDocument||document}function Ud(e){return Kn(e).defaultView||window}function qd(e,t){if(process.env.NODE_ENV==="production")return()=>null;const n=t?O({},t.propTypes):null;return o=>(s,i,l,c,d,...u)=>{const f=d||i,w=n==null?void 0:n[f];if(w){const b=w(s,i,l,c,d,...u);if(b)return b}return typeof s[i]<"u"&&!s[o]?new Error(`The prop \`${f}\` of \`${e}\` can only be used together with the \`${o}\` prop.`):null}}function Jn(e,t){typeof e=="function"?e(t):e&&(e.current=t)}const Hd=typeof window<"u"?M.useLayoutEffect:M.useEffect,Lt=Hd;let ya=0;function Xd(e){const[t,n]=M.useState(e),r=e||t;return M.useEffect(()=>{t==null&&(ya+=1,n(`mui-${ya}`))},[t]),r}const Na=M["useId".toString()];function ri(e){if(Na!==void 0){const t=Na();return e??t}return Xd(e)}function Yd(e,t,n,r,o){if(process.env.NODE_ENV==="production")return null;const s=o||t;return typeof e[t]<"u"?new Error(`The prop \`${s}\` is not supported. Please remove it.`):null}function oi({controlled:e,default:t,name:n,state:r="value"}){const{current:o}=M.useRef(e!==void 0),[s,i]=M.useState(t),l=o?e:s;if(process.env.NODE_ENV!=="production"){M.useEffect(()=>{o!==(e!==void 0)&&console.error([`MUI: A component is changing the ${o?"":"un"}controlled ${r} state of ${n} to be ${o?"un":""}controlled.`,"Elements should not switch from uncontrolled to controlled (or vice versa).",`Decide between using a controlled or uncontrolled ${n} element for the lifetime of the component.`,"The nature of the state is determined during the first render. It's considered controlled if the value is not `undefined`.","More info: https://fb.me/react-controlled-components"].join(` +`))},[r,n,e]);const{current:d}=M.useRef(t);M.useEffect(()=>{!o&&d!==t&&console.error([`MUI: A component is changing the default ${r} state of an uncontrolled ${n} after being initialized. To suppress this warning opt to use a controlled ${n}.`].join(` +`))},[JSON.stringify(t)])}const c=M.useCallback(d=>{o||i(d)},[]);return[l,c]}function Zr(e){const t=M.useRef(e);return Lt(()=>{t.current=e}),M.useRef((...n)=>(0,t.current)(...n)).current}function yt(...e){return M.useMemo(()=>e.every(t=>t==null)?null:t=>{e.forEach(n=>{Jn(n,t)})},e)}const ka={};function Wd(e,t){const n=M.useRef(ka);return n.current===ka&&(n.current=e(t)),n}const Kd=[];function Jd(e){M.useEffect(e,Kd)}class On{constructor(){this.currentId=null,this.clear=()=>{this.currentId!==null&&(clearTimeout(this.currentId),this.currentId=null)},this.disposeEffect=()=>this.clear}static create(){return new On}start(t,n){this.clear(),this.currentId=setTimeout(()=>{this.currentId=null,n()},t)}}function dn(){const e=Wd(On.create).current;return Jd(e.disposeEffect),e}let dr=!0,Qr=!1;const Zd=new On,Qd={text:!0,search:!0,url:!0,tel:!0,email:!0,password:!0,number:!0,date:!0,month:!0,week:!0,time:!0,datetime:!0,"datetime-local":!0};function eu(e){const{type:t,tagName:n}=e;return!!(n==="INPUT"&&Qd[t]&&!e.readOnly||n==="TEXTAREA"&&!e.readOnly||e.isContentEditable)}function tu(e){e.metaKey||e.altKey||e.ctrlKey||(dr=!0)}function Vr(){dr=!1}function nu(){this.visibilityState==="hidden"&&Qr&&(dr=!0)}function ru(e){e.addEventListener("keydown",tu,!0),e.addEventListener("mousedown",Vr,!0),e.addEventListener("pointerdown",Vr,!0),e.addEventListener("touchstart",Vr,!0),e.addEventListener("visibilitychange",nu,!0)}function ou(e){const{target:t}=e;try{return t.matches(":focus-visible")}catch{}return dr||eu(t)}function ai(){const e=M.useCallback(o=>{o!=null&&ru(o.ownerDocument)},[]),t=M.useRef(!1);function n(){return t.current?(Qr=!0,Zd.start(100,()=>{Qr=!1}),t.current=!1,!0):!1}function r(o){return ou(o)?(t.current=!0,!0):!1}return{isFocusVisibleRef:t,onFocus:r,onBlur:n,ref:e}}function si(e,t){const n=O({},t);return Object.keys(e).forEach(r=>{if(r.toString().match(/^(components|slots)$/))n[r]=O({},e[r],n[r]);else if(r.toString().match(/^(componentsProps|slotProps)$/)){const o=e[r]||{},s=t[r];n[r]={},!s||!Object.keys(s)?n[r]=o:!o||!Object.keys(o)?n[r]=s:(n[r]=O({},s),Object.keys(o).forEach(i=>{n[r][i]=si(o[i],s[i])}))}else n[r]===void 0&&(n[r]=e[r])}),n}function ko(e,t,n=void 0){const r={};return Object.keys(e).forEach(o=>{r[o]=e[o].reduce((s,i)=>{if(i){const l=t(i);l!==""&&s.push(l),n&&n[i]&&s.push(n[i])}return s},[]).join(" ")}),r}const Sa=e=>e,au=()=>{let e=Sa;return{configure(t){e=t},generate(t){return e(t)},reset(){e=Sa}}},su=au(),ii=su,li={active:"active",checked:"checked",completed:"completed",disabled:"disabled",error:"error",expanded:"expanded",focused:"focused",focusVisible:"focusVisible",open:"open",readOnly:"readOnly",required:"required",selected:"selected"};function ur(e,t,n="Mui"){const r=li[t];return r?`${n}-${r}`:`${ii.generate(e)}-${t}`}function ci(e,t,n="Mui"){const r={};return t.forEach(o=>{r[o]=ur(e,o,n)}),r}function iu(e,t=Number.MIN_SAFE_INTEGER,n=Number.MAX_SAFE_INTEGER){return Math.max(t,Math.min(e,n))}function Ne(e,t){if(e==null)return{};var n={},r=Object.keys(e),o,s;for(s=0;s=0)&&(n[o]=e[o]);return n}const lu=["values","unit","step"],cu=e=>{const t=Object.keys(e).map(n=>({key:n,val:e[n]}))||[];return t.sort((n,r)=>n.val-r.val),t.reduce((n,r)=>O({},n,{[r.key]:r.val}),{})};function du(e){const{values:t={xs:0,sm:600,md:900,lg:1200,xl:1536},unit:n="px",step:r=5}=e,o=Ne(e,lu),s=cu(t),i=Object.keys(s);function l(w){return`@media (min-width:${typeof t[w]=="number"?t[w]:w}${n})`}function c(w){return`@media (max-width:${(typeof t[w]=="number"?t[w]:w)-r/100}${n})`}function d(w,b){const x=i.indexOf(b);return`@media (min-width:${typeof t[w]=="number"?t[w]:w}${n}) and (max-width:${(x!==-1&&typeof t[i[x]]=="number"?t[i[x]]:b)-r/100}${n})`}function u(w){return i.indexOf(w)+1`@media (min-width:${So[e]}px)`};function et(e,t,n){const r=e.theme||{};if(Array.isArray(t)){const s=r.breakpoints||Ea;return t.reduce((i,l,c)=>(i[s.up(s.keys[c])]=n(t[c]),i),{})}if(typeof t=="object"){const s=r.breakpoints||Ea;return Object.keys(t).reduce((i,l)=>{if(Object.keys(s.values||So).indexOf(l)!==-1){const c=s.up(l);i[c]=n(t[l],l)}else{const c=l;i[c]=t[c]}return i},{})}return n(t)}function fu(e={}){var t;return((t=e.keys)==null?void 0:t.reduce((r,o)=>{const s=e.up(o);return r[s]={},r},{}))||{}}function mu(e,t){return e.reduce((n,r)=>{const o=n[r];return(!o||Object.keys(o).length===0)&&delete n[r],n},t)}function pr(e,t,n=!0){if(!t||typeof t!="string")return null;if(e&&e.vars&&n){const r=`vars.${t}`.split(".").reduce((o,s)=>o&&o[s]?o[s]:null,e);if(r!=null)return r}return t.split(".").reduce((r,o)=>r&&r[o]!=null?r[o]:null,e)}function Zn(e,t,n,r=n){let o;return typeof e=="function"?o=e(n):Array.isArray(e)?o=e[n]||r:o=pr(e,n)||r,t&&(o=t(o,r,e)),o}function ve(e){const{prop:t,cssProperty:n=e.prop,themeKey:r,transform:o}=e,s=i=>{if(i[t]==null)return null;const l=i[t],c=i.theme,d=pr(c,r)||{};return et(i,l,f=>{let w=Zn(d,o,f);return f===w&&typeof f=="string"&&(w=Zn(d,o,`${t}${f==="default"?"":Ye(f)}`,f)),n===!1?w:{[n]:w}})};return s.propTypes=process.env.NODE_ENV!=="production"?{[t]:st}:{},s.filterProps=[t],s}function hu(e){const t={};return n=>(t[n]===void 0&&(t[n]=e(n)),t[n])}const gu={m:"margin",p:"padding"},bu={t:"Top",r:"Right",b:"Bottom",l:"Left",x:["Left","Right"],y:["Top","Bottom"]},ja={marginX:"mx",marginY:"my",paddingX:"px",paddingY:"py"},vu=hu(e=>{if(e.length>2)if(ja[e])e=ja[e];else return[e];const[t,n]=e.split(""),r=gu[t],o=bu[n]||"";return Array.isArray(o)?o.map(s=>r+s):[r+o]}),wr=["m","mt","mr","mb","ml","mx","my","margin","marginTop","marginRight","marginBottom","marginLeft","marginX","marginY","marginInline","marginInlineStart","marginInlineEnd","marginBlock","marginBlockStart","marginBlockEnd"],fr=["p","pt","pr","pb","pl","px","py","padding","paddingTop","paddingRight","paddingBottom","paddingLeft","paddingX","paddingY","paddingInline","paddingInlineStart","paddingInlineEnd","paddingBlock","paddingBlockStart","paddingBlockEnd"],xu=[...wr,...fr];function _n(e,t,n,r){var o;const s=(o=pr(e,t,!1))!=null?o:n;return typeof s=="number"?i=>typeof i=="string"?i:(process.env.NODE_ENV!=="production"&&typeof i!="number"&&console.error(`MUI: Expected ${r} argument to be a number or a string, got ${i}.`),s*i):Array.isArray(s)?i=>typeof i=="string"?i:(process.env.NODE_ENV!=="production"&&(Number.isInteger(i)?i>s.length-1&&console.error([`MUI: The value provided (${i}) overflows.`,`The supported values are: ${JSON.stringify(s)}.`,`${i} > ${s.length-1}, you need to add the missing values.`].join(` `)):console.error([`MUI: The \`theme.${t}\` array type cannot be combined with non integer values.You should either use an integer value that can be used as index, or define the \`theme.${t}\` as a number.`].join(` `))),s[i]):typeof s=="function"?s:(process.env.NODE_ENV!=="production"&&console.error([`MUI: The \`theme.${t}\` value (${s}) is invalid.`,"It should be a number, an array or a function."].join(` -`)),()=>{})}function di(e){return _n(e,"spacing",8,"spacing")}function Pn(e,t){if(typeof t=="string"||t==null)return t;const n=Math.abs(t),r=e(n);return t>=0?r:typeof r=="number"?-r:`-${r}`}function yu(e,t){return n=>e.reduce((r,o)=>(r[o]=Pn(t,n),r),{})}function Nu(e,t,n,r){if(t.indexOf(n)===-1)return null;const o=vu(n),s=yu(o,r),i=e[n];return et(e,i,s)}function ui(e,t){const n=di(e.theme);return Object.keys(e).map(r=>Nu(e,t,r,n)).reduce(mn,{})}function me(e){return ui(e,wr)}me.propTypes=process.env.NODE_ENV!=="production"?wr.reduce((e,t)=>(e[t]=st,e),{}):{};me.filterProps=wr;function he(e){return ui(e,fr)}he.propTypes=process.env.NODE_ENV!=="production"?fr.reduce((e,t)=>(e[t]=st,e),{}):{};he.filterProps=fr;process.env.NODE_ENV!=="production"&&xu.reduce((e,t)=>(e[t]=st,e),{});function ku(e=8){if(e.mui)return e;const t=di({spacing:e}),n=(...r)=>(process.env.NODE_ENV!=="production"&&(r.length<=4||console.error(`MUI: Too many arguments provided, expected between 0 and 4, got ${r.length}`)),(r.length===0?[1]:r).map(s=>{const i=t(s);return typeof i=="number"?`${i}px`:i}).join(" "));return n.mui=!0,n}function mr(...e){const t=e.reduce((r,o)=>(o.filterProps.forEach(s=>{r[s]=o}),r),{}),n=r=>Object.keys(r).reduce((o,s)=>t[s]?mn(o,t[s](r)):o,{});return n.propTypes=process.env.NODE_ENV!=="production"?e.reduce((r,o)=>Object.assign(r,o.propTypes),{}):{},n.filterProps=e.reduce((r,o)=>r.concat(o.filterProps),[]),n}function Be(e){return typeof e!="number"?e:`${e}px solid`}function Fe(e,t){return ve({prop:e,themeKey:"borders",transform:t})}const Su=Fe("border",Be),Eu=Fe("borderTop",Be),ju=Fe("borderRight",Be),Cu=Fe("borderBottom",Be),Tu=Fe("borderLeft",Be),Ru=Fe("borderColor"),Ou=Fe("borderTopColor"),_u=Fe("borderRightColor"),Pu=Fe("borderBottomColor"),Iu=Fe("borderLeftColor"),Mu=Fe("outline",Be),$u=Fe("outlineColor"),hr=e=>{if(e.borderRadius!==void 0&&e.borderRadius!==null){const t=_n(e.theme,"shape.borderRadius",4,"borderRadius"),n=r=>({borderRadius:Pn(t,r)});return et(e,e.borderRadius,n)}return null};hr.propTypes=process.env.NODE_ENV!=="production"?{borderRadius:st}:{};hr.filterProps=["borderRadius"];mr(Su,Eu,ju,Cu,Tu,Ru,Ou,_u,Pu,Iu,hr,Mu,$u);const gr=e=>{if(e.gap!==void 0&&e.gap!==null){const t=_n(e.theme,"spacing",8,"gap"),n=r=>({gap:Pn(t,r)});return et(e,e.gap,n)}return null};gr.propTypes=process.env.NODE_ENV!=="production"?{gap:st}:{};gr.filterProps=["gap"];const br=e=>{if(e.columnGap!==void 0&&e.columnGap!==null){const t=_n(e.theme,"spacing",8,"columnGap"),n=r=>({columnGap:Pn(t,r)});return et(e,e.columnGap,n)}return null};br.propTypes=process.env.NODE_ENV!=="production"?{columnGap:st}:{};br.filterProps=["columnGap"];const vr=e=>{if(e.rowGap!==void 0&&e.rowGap!==null){const t=_n(e.theme,"spacing",8,"rowGap"),n=r=>({rowGap:Pn(t,r)});return et(e,e.rowGap,n)}return null};vr.propTypes=process.env.NODE_ENV!=="production"?{rowGap:st}:{};vr.filterProps=["rowGap"];const Du=ve({prop:"gridColumn"}),Au=ve({prop:"gridRow"}),Bu=ve({prop:"gridAutoFlow"}),Vu=ve({prop:"gridAutoColumns"}),zu=ve({prop:"gridAutoRows"}),Lu=ve({prop:"gridTemplateColumns"}),Fu=ve({prop:"gridTemplateRows"}),Gu=ve({prop:"gridTemplateAreas"}),Uu=ve({prop:"gridArea"});mr(gr,br,vr,Du,Au,Bu,Vu,zu,Lu,Fu,Gu,Uu);function Dt(e,t){return t==="grey"?t:e}const qu=ve({prop:"color",themeKey:"palette",transform:Dt}),Hu=ve({prop:"bgcolor",cssProperty:"backgroundColor",themeKey:"palette",transform:Dt}),Xu=ve({prop:"backgroundColor",themeKey:"palette",transform:Dt});mr(qu,Hu,Xu);function Ie(e){return e<=1&&e!==0?`${e*100}%`:e}const Yu=ve({prop:"width",transform:Ie}),Eo=e=>{if(e.maxWidth!==void 0&&e.maxWidth!==null){const t=n=>{var r,o;const s=((r=e.theme)==null||(r=r.breakpoints)==null||(r=r.values)==null?void 0:r[n])||So[n];return s?((o=e.theme)==null||(o=o.breakpoints)==null?void 0:o.unit)!=="px"?{maxWidth:`${s}${e.theme.breakpoints.unit}`}:{maxWidth:s}:{maxWidth:Ie(n)}};return et(e,e.maxWidth,t)}return null};Eo.filterProps=["maxWidth"];const Wu=ve({prop:"minWidth",transform:Ie}),Ku=ve({prop:"height",transform:Ie}),Ju=ve({prop:"maxHeight",transform:Ie}),Zu=ve({prop:"minHeight",transform:Ie});ve({prop:"size",cssProperty:"width",transform:Ie});ve({prop:"size",cssProperty:"height",transform:Ie});const Qu=ve({prop:"boxSizing"});mr(Yu,Eo,Wu,Ku,Ju,Zu,Qu);const ep={border:{themeKey:"borders",transform:Be},borderTop:{themeKey:"borders",transform:Be},borderRight:{themeKey:"borders",transform:Be},borderBottom:{themeKey:"borders",transform:Be},borderLeft:{themeKey:"borders",transform:Be},borderColor:{themeKey:"palette"},borderTopColor:{themeKey:"palette"},borderRightColor:{themeKey:"palette"},borderBottomColor:{themeKey:"palette"},borderLeftColor:{themeKey:"palette"},outline:{themeKey:"borders",transform:Be},outlineColor:{themeKey:"palette"},borderRadius:{themeKey:"shape.borderRadius",style:hr},color:{themeKey:"palette",transform:Dt},bgcolor:{themeKey:"palette",cssProperty:"backgroundColor",transform:Dt},backgroundColor:{themeKey:"palette",transform:Dt},p:{style:he},pt:{style:he},pr:{style:he},pb:{style:he},pl:{style:he},px:{style:he},py:{style:he},padding:{style:he},paddingTop:{style:he},paddingRight:{style:he},paddingBottom:{style:he},paddingLeft:{style:he},paddingX:{style:he},paddingY:{style:he},paddingInline:{style:he},paddingInlineStart:{style:he},paddingInlineEnd:{style:he},paddingBlock:{style:he},paddingBlockStart:{style:he},paddingBlockEnd:{style:he},m:{style:me},mt:{style:me},mr:{style:me},mb:{style:me},ml:{style:me},mx:{style:me},my:{style:me},margin:{style:me},marginTop:{style:me},marginRight:{style:me},marginBottom:{style:me},marginLeft:{style:me},marginX:{style:me},marginY:{style:me},marginInline:{style:me},marginInlineStart:{style:me},marginInlineEnd:{style:me},marginBlock:{style:me},marginBlockStart:{style:me},marginBlockEnd:{style:me},displayPrint:{cssProperty:!1,transform:e=>({"@media print":{display:e}})},display:{},overflow:{},textOverflow:{},visibility:{},whiteSpace:{},flexBasis:{},flexDirection:{},flexWrap:{},justifyContent:{},alignItems:{},alignContent:{},order:{},flex:{},flexGrow:{},flexShrink:{},alignSelf:{},justifyItems:{},justifySelf:{},gap:{style:gr},rowGap:{style:vr},columnGap:{style:br},gridColumn:{},gridRow:{},gridAutoFlow:{},gridAutoColumns:{},gridAutoRows:{},gridTemplateColumns:{},gridTemplateRows:{},gridTemplateAreas:{},gridArea:{},position:{},zIndex:{themeKey:"zIndex"},top:{},right:{},bottom:{},left:{},boxShadow:{themeKey:"shadows"},width:{transform:Ie},maxWidth:{style:Eo},minWidth:{transform:Ie},height:{transform:Ie},maxHeight:{transform:Ie},minHeight:{transform:Ie},boxSizing:{},fontFamily:{themeKey:"typography"},fontSize:{themeKey:"typography"},fontStyle:{themeKey:"typography"},fontWeight:{themeKey:"typography"},letterSpacing:{},textTransform:{},lineHeight:{},textAlign:{},typography:{cssProperty:!1,themeKey:"typography"}},jo=ep;function tp(...e){const t=e.reduce((r,o)=>r.concat(Object.keys(o)),[]),n=new Set(t);return e.every(r=>n.size===Object.keys(r).length)}function np(e,t){return typeof e=="function"?e(t):e}function rp(){function e(n,r,o,s){const i={[n]:r,theme:o},l=s[n];if(!l)return{[n]:r};const{cssProperty:c=n,themeKey:u,transform:d,style:m}=l;if(r==null)return null;if(u==="typography"&&r==="inherit")return{[n]:r};const w=pr(o,u)||{};return m?m(i):et(i,r,x=>{let f=Zn(w,d,x);return x===f&&typeof x=="string"&&(f=Zn(w,d,`${n}${x==="default"?"":Ye(x)}`,x)),c===!1?f:{[c]:f}})}function t(n){var r;const{sx:o,theme:s={}}=n||{};if(!o)return null;const i=(r=s.unstable_sxConfig)!=null?r:jo;function l(c){let u=c;if(typeof c=="function")u=c(s);else if(typeof c!="object")return c;if(!u)return null;const d=fu(s.breakpoints),m=Object.keys(d);let w=d;return Object.keys(u).forEach(b=>{const x=np(u[b],s);if(x!=null)if(typeof x=="object")if(i[b])w=mn(w,e(b,x,s,i));else{const f=et({theme:s},x,h=>({[b]:h}));tp(f,x)?w[b]=t({sx:x,theme:s}):w=mn(w,f)}else w=mn(w,e(b,x,s,i))}),mu(m,w)}return Array.isArray(o)?o.map(l):l(o)}return t}const pi=rp();pi.filterProps=["sx"];const Co=pi;function op(e,t){const n=this;return n.vars&&typeof n.getColorSchemeSelector=="function"?{[n.getColorSchemeSelector(e).replace(/(\[[^\]]+\])/,"*:where($1)")]:t}:n.palette.mode===e?t:{}}const ap=["breakpoints","palette","spacing","shape"];function To(e={},...t){const{breakpoints:n={},palette:r={},spacing:o,shape:s={}}=e,i=Ne(e,ap),l=du(n),c=ku(o);let u=Qe({breakpoints:l,direction:"ltr",components:{},palette:O({mode:"light"},r),spacing:c,shape:O({},pu,s)},i);return u.applyStyles=op,u=t.reduce((d,m)=>Qe(d,m),u),u.unstable_sxConfig=O({},jo,i==null?void 0:i.unstable_sxConfig),u.unstable_sx=function(m){return Co({sx:m,theme:this})},u}function sp(e){return Object.keys(e).length===0}function wi(e=null){const t=M.useContext(Gr.ThemeContext);return!t||sp(t)?e:t}const ip=To();function fi(e=ip){return wi(e)}const lp=["ownerState"],cp=["variants"],dp=["name","slot","skipVariantsResolver","skipSx","overridesResolver"];function up(e){return Object.keys(e).length===0}function pp(e){return typeof e=="string"&&e.charCodeAt(0)>96}function qn(e){return e!=="ownerState"&&e!=="theme"&&e!=="sx"&&e!=="as"}const wp=To(),Ca=e=>e&&e.charAt(0).toLowerCase()+e.slice(1);function Ln({defaultTheme:e,theme:t,themeId:n}){return up(t)?e:t[n]||t}function fp(e){return e?(t,n)=>n[e]:null}function Hn(e,t){let{ownerState:n}=t,r=Ne(t,lp);const o=typeof e=="function"?e(O({ownerState:n},r)):e;if(Array.isArray(o))return o.flatMap(s=>Hn(s,O({ownerState:n},r)));if(o&&typeof o=="object"&&Array.isArray(o.variants)){const{variants:s=[]}=o;let l=Ne(o,cp);return s.forEach(c=>{let u=!0;typeof c.props=="function"?u=c.props(O({ownerState:n},r,n)):Object.keys(c.props).forEach(d=>{(n==null?void 0:n[d])!==c.props[d]&&r[d]!==c.props[d]&&(u=!1)}),u&&(Array.isArray(l)||(l=[l]),l.push(typeof c.style=="function"?c.style(O({ownerState:n},r,n)):c.style))}),l}return o}function mp(e={}){const{themeId:t,defaultTheme:n=wp,rootShouldForwardProp:r=qn,slotShouldForwardProp:o=qn}=e,s=i=>Co(O({},i,{theme:Ln(O({},i,{defaultTheme:n,themeId:t}))}));return s.__mui_systemSx=!0,(i,l={})=>{Gr.internal_processStyles(i,v=>v.filter(P=>!(P!=null&&P.__mui_systemSx)));const{name:c,slot:u,skipVariantsResolver:d,skipSx:m,overridesResolver:w=fp(Ca(u))}=l,b=Ne(l,dp),x=d!==void 0?d:u&&u!=="Root"&&u!=="root"||!1,f=m||!1;let h;process.env.NODE_ENV!=="production"&&c&&(h=`${c}-${Ca(u||"Root")}`);let S=qn;u==="Root"||u==="root"?S=r:u?S=o:pp(i)&&(S=void 0);const R=Gr(i,O({shouldForwardProp:S,label:h},b)),j=v=>typeof v=="function"&&v.__emotion_real!==v||mt(v)?P=>Hn(v,O({},P,{theme:Ln({theme:P.theme,defaultTheme:n,themeId:t})})):v,E=(v,...P)=>{let V=j(v);const U=P?P.map(j):[];c&&w&&U.push(k=>{const D=Ln(O({},k,{defaultTheme:n,themeId:t}));if(!D.components||!D.components[c]||!D.components[c].styleOverrides)return null;const $=D.components[c].styleOverrides,J={};return Object.entries($).forEach(([Y,F])=>{J[Y]=Hn(F,O({},k,{theme:D}))}),w(k,J)}),c&&!x&&U.push(k=>{var D;const $=Ln(O({},k,{defaultTheme:n,themeId:t})),J=$==null||(D=$.components)==null||(D=D[c])==null?void 0:D.variants;return Hn({variants:J},O({},k,{theme:$}))}),f||U.push(s);const C=U.length-P.length;if(Array.isArray(v)&&C>0){const k=new Array(C).fill("");V=[...v,...k],V.raw=[...v.raw,...k]}const _=R(V,...U);if(process.env.NODE_ENV!=="production"){let k;c&&(k=`${c}${Ye(u||"")}`),k===void 0&&(k=`Styled(${Bd(i)})`),_.displayName=k}return i.muiName&&(_.muiName=i.muiName),_};return R.withConfig&&(E.withConfig=R.withConfig),E}}function hp(e){const{theme:t,name:n,props:r}=e;return!t||!t.components||!t.components[n]||!t.components[n].defaultProps?r:si(t.components[n].defaultProps,r)}function gp({props:e,name:t,defaultTheme:n,themeId:r}){let o=fi(n);return r&&(o=o[r]||o),hp({theme:o,name:t,props:e})}function Ro(e,t=0,n=1){return process.env.NODE_ENV!=="production"&&(en)&&console.error(`MUI: The value provided ${e} is out of range [${t}, ${n}].`),iu(e,t,n)}function bp(e){e=e.slice(1);const t=new RegExp(`.{1,${e.length>=6?2:1}}`,"g");let n=e.match(t);return n&&n[0].length===1&&(n=n.map(r=>r+r)),n?`rgb${n.length===4?"a":""}(${n.map((r,o)=>o<3?parseInt(r,16):Math.round(parseInt(r,16)/255*1e3)/1e3).join(", ")})`:""}function Nt(e){if(e.type)return e;if(e.charAt(0)==="#")return Nt(bp(e));const t=e.indexOf("("),n=e.substring(0,t);if(["rgb","rgba","hsl","hsla","color"].indexOf(n)===-1)throw new Error(process.env.NODE_ENV!=="production"?`MUI: Unsupported \`${e}\` color. +`)),()=>{})}function di(e){return _n(e,"spacing",8,"spacing")}function Pn(e,t){if(typeof t=="string"||t==null)return t;const n=Math.abs(t),r=e(n);return t>=0?r:typeof r=="number"?-r:`-${r}`}function yu(e,t){return n=>e.reduce((r,o)=>(r[o]=Pn(t,n),r),{})}function Nu(e,t,n,r){if(t.indexOf(n)===-1)return null;const o=vu(n),s=yu(o,r),i=e[n];return et(e,i,s)}function ui(e,t){const n=di(e.theme);return Object.keys(e).map(r=>Nu(e,t,r,n)).reduce(mn,{})}function me(e){return ui(e,wr)}me.propTypes=process.env.NODE_ENV!=="production"?wr.reduce((e,t)=>(e[t]=st,e),{}):{};me.filterProps=wr;function he(e){return ui(e,fr)}he.propTypes=process.env.NODE_ENV!=="production"?fr.reduce((e,t)=>(e[t]=st,e),{}):{};he.filterProps=fr;process.env.NODE_ENV!=="production"&&xu.reduce((e,t)=>(e[t]=st,e),{});function ku(e=8){if(e.mui)return e;const t=di({spacing:e}),n=(...r)=>(process.env.NODE_ENV!=="production"&&(r.length<=4||console.error(`MUI: Too many arguments provided, expected between 0 and 4, got ${r.length}`)),(r.length===0?[1]:r).map(s=>{const i=t(s);return typeof i=="number"?`${i}px`:i}).join(" "));return n.mui=!0,n}function mr(...e){const t=e.reduce((r,o)=>(o.filterProps.forEach(s=>{r[s]=o}),r),{}),n=r=>Object.keys(r).reduce((o,s)=>t[s]?mn(o,t[s](r)):o,{});return n.propTypes=process.env.NODE_ENV!=="production"?e.reduce((r,o)=>Object.assign(r,o.propTypes),{}):{},n.filterProps=e.reduce((r,o)=>r.concat(o.filterProps),[]),n}function Be(e){return typeof e!="number"?e:`${e}px solid`}function Fe(e,t){return ve({prop:e,themeKey:"borders",transform:t})}const Su=Fe("border",Be),Eu=Fe("borderTop",Be),ju=Fe("borderRight",Be),Cu=Fe("borderBottom",Be),Tu=Fe("borderLeft",Be),Ru=Fe("borderColor"),Ou=Fe("borderTopColor"),_u=Fe("borderRightColor"),Pu=Fe("borderBottomColor"),Iu=Fe("borderLeftColor"),Mu=Fe("outline",Be),$u=Fe("outlineColor"),hr=e=>{if(e.borderRadius!==void 0&&e.borderRadius!==null){const t=_n(e.theme,"shape.borderRadius",4,"borderRadius"),n=r=>({borderRadius:Pn(t,r)});return et(e,e.borderRadius,n)}return null};hr.propTypes=process.env.NODE_ENV!=="production"?{borderRadius:st}:{};hr.filterProps=["borderRadius"];mr(Su,Eu,ju,Cu,Tu,Ru,Ou,_u,Pu,Iu,hr,Mu,$u);const gr=e=>{if(e.gap!==void 0&&e.gap!==null){const t=_n(e.theme,"spacing",8,"gap"),n=r=>({gap:Pn(t,r)});return et(e,e.gap,n)}return null};gr.propTypes=process.env.NODE_ENV!=="production"?{gap:st}:{};gr.filterProps=["gap"];const br=e=>{if(e.columnGap!==void 0&&e.columnGap!==null){const t=_n(e.theme,"spacing",8,"columnGap"),n=r=>({columnGap:Pn(t,r)});return et(e,e.columnGap,n)}return null};br.propTypes=process.env.NODE_ENV!=="production"?{columnGap:st}:{};br.filterProps=["columnGap"];const vr=e=>{if(e.rowGap!==void 0&&e.rowGap!==null){const t=_n(e.theme,"spacing",8,"rowGap"),n=r=>({rowGap:Pn(t,r)});return et(e,e.rowGap,n)}return null};vr.propTypes=process.env.NODE_ENV!=="production"?{rowGap:st}:{};vr.filterProps=["rowGap"];const Du=ve({prop:"gridColumn"}),Au=ve({prop:"gridRow"}),Bu=ve({prop:"gridAutoFlow"}),Vu=ve({prop:"gridAutoColumns"}),zu=ve({prop:"gridAutoRows"}),Lu=ve({prop:"gridTemplateColumns"}),Fu=ve({prop:"gridTemplateRows"}),Gu=ve({prop:"gridTemplateAreas"}),Uu=ve({prop:"gridArea"});mr(gr,br,vr,Du,Au,Bu,Vu,zu,Lu,Fu,Gu,Uu);function Dt(e,t){return t==="grey"?t:e}const qu=ve({prop:"color",themeKey:"palette",transform:Dt}),Hu=ve({prop:"bgcolor",cssProperty:"backgroundColor",themeKey:"palette",transform:Dt}),Xu=ve({prop:"backgroundColor",themeKey:"palette",transform:Dt});mr(qu,Hu,Xu);function Ie(e){return e<=1&&e!==0?`${e*100}%`:e}const Yu=ve({prop:"width",transform:Ie}),Eo=e=>{if(e.maxWidth!==void 0&&e.maxWidth!==null){const t=n=>{var r,o;const s=((r=e.theme)==null||(r=r.breakpoints)==null||(r=r.values)==null?void 0:r[n])||So[n];return s?((o=e.theme)==null||(o=o.breakpoints)==null?void 0:o.unit)!=="px"?{maxWidth:`${s}${e.theme.breakpoints.unit}`}:{maxWidth:s}:{maxWidth:Ie(n)}};return et(e,e.maxWidth,t)}return null};Eo.filterProps=["maxWidth"];const Wu=ve({prop:"minWidth",transform:Ie}),Ku=ve({prop:"height",transform:Ie}),Ju=ve({prop:"maxHeight",transform:Ie}),Zu=ve({prop:"minHeight",transform:Ie});ve({prop:"size",cssProperty:"width",transform:Ie});ve({prop:"size",cssProperty:"height",transform:Ie});const Qu=ve({prop:"boxSizing"});mr(Yu,Eo,Wu,Ku,Ju,Zu,Qu);const ep={border:{themeKey:"borders",transform:Be},borderTop:{themeKey:"borders",transform:Be},borderRight:{themeKey:"borders",transform:Be},borderBottom:{themeKey:"borders",transform:Be},borderLeft:{themeKey:"borders",transform:Be},borderColor:{themeKey:"palette"},borderTopColor:{themeKey:"palette"},borderRightColor:{themeKey:"palette"},borderBottomColor:{themeKey:"palette"},borderLeftColor:{themeKey:"palette"},outline:{themeKey:"borders",transform:Be},outlineColor:{themeKey:"palette"},borderRadius:{themeKey:"shape.borderRadius",style:hr},color:{themeKey:"palette",transform:Dt},bgcolor:{themeKey:"palette",cssProperty:"backgroundColor",transform:Dt},backgroundColor:{themeKey:"palette",transform:Dt},p:{style:he},pt:{style:he},pr:{style:he},pb:{style:he},pl:{style:he},px:{style:he},py:{style:he},padding:{style:he},paddingTop:{style:he},paddingRight:{style:he},paddingBottom:{style:he},paddingLeft:{style:he},paddingX:{style:he},paddingY:{style:he},paddingInline:{style:he},paddingInlineStart:{style:he},paddingInlineEnd:{style:he},paddingBlock:{style:he},paddingBlockStart:{style:he},paddingBlockEnd:{style:he},m:{style:me},mt:{style:me},mr:{style:me},mb:{style:me},ml:{style:me},mx:{style:me},my:{style:me},margin:{style:me},marginTop:{style:me},marginRight:{style:me},marginBottom:{style:me},marginLeft:{style:me},marginX:{style:me},marginY:{style:me},marginInline:{style:me},marginInlineStart:{style:me},marginInlineEnd:{style:me},marginBlock:{style:me},marginBlockStart:{style:me},marginBlockEnd:{style:me},displayPrint:{cssProperty:!1,transform:e=>({"@media print":{display:e}})},display:{},overflow:{},textOverflow:{},visibility:{},whiteSpace:{},flexBasis:{},flexDirection:{},flexWrap:{},justifyContent:{},alignItems:{},alignContent:{},order:{},flex:{},flexGrow:{},flexShrink:{},alignSelf:{},justifyItems:{},justifySelf:{},gap:{style:gr},rowGap:{style:vr},columnGap:{style:br},gridColumn:{},gridRow:{},gridAutoFlow:{},gridAutoColumns:{},gridAutoRows:{},gridTemplateColumns:{},gridTemplateRows:{},gridTemplateAreas:{},gridArea:{},position:{},zIndex:{themeKey:"zIndex"},top:{},right:{},bottom:{},left:{},boxShadow:{themeKey:"shadows"},width:{transform:Ie},maxWidth:{style:Eo},minWidth:{transform:Ie},height:{transform:Ie},maxHeight:{transform:Ie},minHeight:{transform:Ie},boxSizing:{},fontFamily:{themeKey:"typography"},fontSize:{themeKey:"typography"},fontStyle:{themeKey:"typography"},fontWeight:{themeKey:"typography"},letterSpacing:{},textTransform:{},lineHeight:{},textAlign:{},typography:{cssProperty:!1,themeKey:"typography"}},jo=ep;function tp(...e){const t=e.reduce((r,o)=>r.concat(Object.keys(o)),[]),n=new Set(t);return e.every(r=>n.size===Object.keys(r).length)}function np(e,t){return typeof e=="function"?e(t):e}function rp(){function e(n,r,o,s){const i={[n]:r,theme:o},l=s[n];if(!l)return{[n]:r};const{cssProperty:c=n,themeKey:d,transform:u,style:f}=l;if(r==null)return null;if(d==="typography"&&r==="inherit")return{[n]:r};const w=pr(o,d)||{};return f?f(i):et(i,r,x=>{let m=Zn(w,u,x);return x===m&&typeof x=="string"&&(m=Zn(w,u,`${n}${x==="default"?"":Ye(x)}`,x)),c===!1?m:{[c]:m}})}function t(n){var r;const{sx:o,theme:s={}}=n||{};if(!o)return null;const i=(r=s.unstable_sxConfig)!=null?r:jo;function l(c){let d=c;if(typeof c=="function")d=c(s);else if(typeof c!="object")return c;if(!d)return null;const u=fu(s.breakpoints),f=Object.keys(u);let w=u;return Object.keys(d).forEach(b=>{const x=np(d[b],s);if(x!=null)if(typeof x=="object")if(i[b])w=mn(w,e(b,x,s,i));else{const m=et({theme:s},x,h=>({[b]:h}));tp(m,x)?w[b]=t({sx:x,theme:s}):w=mn(w,m)}else w=mn(w,e(b,x,s,i))}),mu(f,w)}return Array.isArray(o)?o.map(l):l(o)}return t}const pi=rp();pi.filterProps=["sx"];const Co=pi;function op(e,t){const n=this;return n.vars&&typeof n.getColorSchemeSelector=="function"?{[n.getColorSchemeSelector(e).replace(/(\[[^\]]+\])/,"*:where($1)")]:t}:n.palette.mode===e?t:{}}const ap=["breakpoints","palette","spacing","shape"];function To(e={},...t){const{breakpoints:n={},palette:r={},spacing:o,shape:s={}}=e,i=Ne(e,ap),l=du(n),c=ku(o);let d=Qe({breakpoints:l,direction:"ltr",components:{},palette:O({mode:"light"},r),spacing:c,shape:O({},pu,s)},i);return d.applyStyles=op,d=t.reduce((u,f)=>Qe(u,f),d),d.unstable_sxConfig=O({},jo,i==null?void 0:i.unstable_sxConfig),d.unstable_sx=function(f){return Co({sx:f,theme:this})},d}function sp(e){return Object.keys(e).length===0}function wi(e=null){const t=M.useContext(Gr.ThemeContext);return!t||sp(t)?e:t}const ip=To();function fi(e=ip){return wi(e)}const lp=["ownerState"],cp=["variants"],dp=["name","slot","skipVariantsResolver","skipSx","overridesResolver"];function up(e){return Object.keys(e).length===0}function pp(e){return typeof e=="string"&&e.charCodeAt(0)>96}function qn(e){return e!=="ownerState"&&e!=="theme"&&e!=="sx"&&e!=="as"}const wp=To(),Ca=e=>e&&e.charAt(0).toLowerCase()+e.slice(1);function Ln({defaultTheme:e,theme:t,themeId:n}){return up(t)?e:t[n]||t}function fp(e){return e?(t,n)=>n[e]:null}function Hn(e,t){let{ownerState:n}=t,r=Ne(t,lp);const o=typeof e=="function"?e(O({ownerState:n},r)):e;if(Array.isArray(o))return o.flatMap(s=>Hn(s,O({ownerState:n},r)));if(o&&typeof o=="object"&&Array.isArray(o.variants)){const{variants:s=[]}=o;let l=Ne(o,cp);return s.forEach(c=>{let d=!0;typeof c.props=="function"?d=c.props(O({ownerState:n},r,n)):Object.keys(c.props).forEach(u=>{(n==null?void 0:n[u])!==c.props[u]&&r[u]!==c.props[u]&&(d=!1)}),d&&(Array.isArray(l)||(l=[l]),l.push(typeof c.style=="function"?c.style(O({ownerState:n},r,n)):c.style))}),l}return o}function mp(e={}){const{themeId:t,defaultTheme:n=wp,rootShouldForwardProp:r=qn,slotShouldForwardProp:o=qn}=e,s=i=>Co(O({},i,{theme:Ln(O({},i,{defaultTheme:n,themeId:t}))}));return s.__mui_systemSx=!0,(i,l={})=>{Gr.internal_processStyles(i,v=>v.filter(P=>!(P!=null&&P.__mui_systemSx)));const{name:c,slot:d,skipVariantsResolver:u,skipSx:f,overridesResolver:w=fp(Ca(d))}=l,b=Ne(l,dp),x=u!==void 0?u:d&&d!=="Root"&&d!=="root"||!1,m=f||!1;let h;process.env.NODE_ENV!=="production"&&c&&(h=`${c}-${Ca(d||"Root")}`);let S=qn;d==="Root"||d==="root"?S=r:d?S=o:pp(i)&&(S=void 0);const R=Gr(i,O({shouldForwardProp:S,label:h},b)),j=v=>typeof v=="function"&&v.__emotion_real!==v||mt(v)?P=>Hn(v,O({},P,{theme:Ln({theme:P.theme,defaultTheme:n,themeId:t})})):v,E=(v,...P)=>{let V=j(v);const U=P?P.map(j):[];c&&w&&U.push(k=>{const D=Ln(O({},k,{defaultTheme:n,themeId:t}));if(!D.components||!D.components[c]||!D.components[c].styleOverrides)return null;const $=D.components[c].styleOverrides,J={};return Object.entries($).forEach(([Y,F])=>{J[Y]=Hn(F,O({},k,{theme:D}))}),w(k,J)}),c&&!x&&U.push(k=>{var D;const $=Ln(O({},k,{defaultTheme:n,themeId:t})),J=$==null||(D=$.components)==null||(D=D[c])==null?void 0:D.variants;return Hn({variants:J},O({},k,{theme:$}))}),m||U.push(s);const C=U.length-P.length;if(Array.isArray(v)&&C>0){const k=new Array(C).fill("");V=[...v,...k],V.raw=[...v.raw,...k]}const _=R(V,...U);if(process.env.NODE_ENV!=="production"){let k;c&&(k=`${c}${Ye(d||"")}`),k===void 0&&(k=`Styled(${Bd(i)})`),_.displayName=k}return i.muiName&&(_.muiName=i.muiName),_};return R.withConfig&&(E.withConfig=R.withConfig),E}}function hp(e){const{theme:t,name:n,props:r}=e;return!t||!t.components||!t.components[n]||!t.components[n].defaultProps?r:si(t.components[n].defaultProps,r)}function gp({props:e,name:t,defaultTheme:n,themeId:r}){let o=fi(n);return r&&(o=o[r]||o),hp({theme:o,name:t,props:e})}function Ro(e,t=0,n=1){return process.env.NODE_ENV!=="production"&&(en)&&console.error(`MUI: The value provided ${e} is out of range [${t}, ${n}].`),iu(e,t,n)}function bp(e){e=e.slice(1);const t=new RegExp(`.{1,${e.length>=6?2:1}}`,"g");let n=e.match(t);return n&&n[0].length===1&&(n=n.map(r=>r+r)),n?`rgb${n.length===4?"a":""}(${n.map((r,o)=>o<3?parseInt(r,16):Math.round(parseInt(r,16)/255*1e3)/1e3).join(", ")})`:""}function Nt(e){if(e.type)return e;if(e.charAt(0)==="#")return Nt(bp(e));const t=e.indexOf("("),n=e.substring(0,t);if(["rgb","rgba","hsl","hsla","color"].indexOf(n)===-1)throw new Error(process.env.NODE_ENV!=="production"?`MUI: Unsupported \`${e}\` color. The following formats are supported: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color().`:zt(9,e));let r=e.substring(t+1,e.length-1),o;if(n==="color"){if(r=r.split(" "),o=r.shift(),r.length===4&&r[3].charAt(0)==="/"&&(r[3]=r[3].slice(1)),["srgb","display-p3","a98-rgb","prophoto-rgb","rec-2020"].indexOf(o)===-1)throw new Error(process.env.NODE_ENV!=="production"?`MUI: unsupported \`${o}\` color space. -The following color spaces are supported: srgb, display-p3, a98-rgb, prophoto-rgb, rec-2020.`:zt(10,o))}else r=r.split(",");return r=r.map(s=>parseFloat(s)),{type:n,values:r,colorSpace:o}}function xr(e){const{type:t,colorSpace:n}=e;let{values:r}=e;return t.indexOf("rgb")!==-1?r=r.map((o,s)=>s<3?parseInt(o,10):o):t.indexOf("hsl")!==-1&&(r[1]=`${r[1]}%`,r[2]=`${r[2]}%`),t.indexOf("color")!==-1?r=`${n} ${r.join(" ")}`:r=`${r.join(", ")}`,`${t}(${r})`}function vp(e){e=Nt(e);const{values:t}=e,n=t[0],r=t[1]/100,o=t[2]/100,s=r*Math.min(o,1-o),i=(u,d=(u+n/30)%12)=>o-s*Math.max(Math.min(d-3,9-d,1),-1);let l="rgb";const c=[Math.round(i(0)*255),Math.round(i(8)*255),Math.round(i(4)*255)];return e.type==="hsla"&&(l+="a",c.push(t[3])),xr({type:l,values:c})}function Ta(e){e=Nt(e);let t=e.type==="hsl"||e.type==="hsla"?Nt(vp(e)).values:e.values;return t=t.map(n=>(e.type!=="color"&&(n/=255),n<=.03928?n/12.92:((n+.055)/1.055)**2.4)),Number((.2126*t[0]+.7152*t[1]+.0722*t[2]).toFixed(3))}function Ra(e,t){const n=Ta(e),r=Ta(t);return(Math.max(n,r)+.05)/(Math.min(n,r)+.05)}function mi(e,t){return e=Nt(e),t=Ro(t),(e.type==="rgb"||e.type==="hsl")&&(e.type+="a"),e.type==="color"?e.values[3]=`/${t}`:e.values[3]=t,xr(e)}function xp(e,t){if(e=Nt(e),t=Ro(t),e.type.indexOf("hsl")!==-1)e.values[2]*=1-t;else if(e.type.indexOf("rgb")!==-1||e.type.indexOf("color")!==-1)for(let n=0;n<3;n+=1)e.values[n]*=1-t;return xr(e)}function yp(e,t){if(e=Nt(e),t=Ro(t),e.type.indexOf("hsl")!==-1)e.values[2]+=(100-e.values[2])*t;else if(e.type.indexOf("rgb")!==-1)for(let n=0;n<3;n+=1)e.values[n]+=(255-e.values[n])*t;else if(e.type.indexOf("color")!==-1)for(let n=0;n<3;n+=1)e.values[n]+=(1-e.values[n])*t;return xr(e)}function Np(e,t){return O({toolbar:{minHeight:56,[e.up("xs")]:{"@media (orientation: landscape)":{minHeight:48}},[e.up("sm")]:{minHeight:64}}},t)}const kp={black:"#000",white:"#fff"},yn=kp,Sp={50:"#fafafa",100:"#f5f5f5",200:"#eeeeee",300:"#e0e0e0",400:"#bdbdbd",500:"#9e9e9e",600:"#757575",700:"#616161",800:"#424242",900:"#212121",A100:"#f5f5f5",A200:"#eeeeee",A400:"#bdbdbd",A700:"#616161"},Ep=Sp,jp={50:"#f3e5f5",100:"#e1bee7",200:"#ce93d8",300:"#ba68c8",400:"#ab47bc",500:"#9c27b0",600:"#8e24aa",700:"#7b1fa2",800:"#6a1b9a",900:"#4a148c",A100:"#ea80fc",A200:"#e040fb",A400:"#d500f9",A700:"#aa00ff"},Rt=jp,Cp={50:"#ffebee",100:"#ffcdd2",200:"#ef9a9a",300:"#e57373",400:"#ef5350",500:"#f44336",600:"#e53935",700:"#d32f2f",800:"#c62828",900:"#b71c1c",A100:"#ff8a80",A200:"#ff5252",A400:"#ff1744",A700:"#d50000"},Ot=Cp,Tp={50:"#fff3e0",100:"#ffe0b2",200:"#ffcc80",300:"#ffb74d",400:"#ffa726",500:"#ff9800",600:"#fb8c00",700:"#f57c00",800:"#ef6c00",900:"#e65100",A100:"#ffd180",A200:"#ffab40",A400:"#ff9100",A700:"#ff6d00"},on=Tp,Rp={50:"#e3f2fd",100:"#bbdefb",200:"#90caf9",300:"#64b5f6",400:"#42a5f5",500:"#2196f3",600:"#1e88e5",700:"#1976d2",800:"#1565c0",900:"#0d47a1",A100:"#82b1ff",A200:"#448aff",A400:"#2979ff",A700:"#2962ff"},_t=Rp,Op={50:"#e1f5fe",100:"#b3e5fc",200:"#81d4fa",300:"#4fc3f7",400:"#29b6f6",500:"#03a9f4",600:"#039be5",700:"#0288d1",800:"#0277bd",900:"#01579b",A100:"#80d8ff",A200:"#40c4ff",A400:"#00b0ff",A700:"#0091ea"},Pt=Op,_p={50:"#e8f5e9",100:"#c8e6c9",200:"#a5d6a7",300:"#81c784",400:"#66bb6a",500:"#4caf50",600:"#43a047",700:"#388e3c",800:"#2e7d32",900:"#1b5e20",A100:"#b9f6ca",A200:"#69f0ae",A400:"#00e676",A700:"#00c853"},It=_p,Pp=["mode","contrastThreshold","tonalOffset"],Oa={text:{primary:"rgba(0, 0, 0, 0.87)",secondary:"rgba(0, 0, 0, 0.6)",disabled:"rgba(0, 0, 0, 0.38)"},divider:"rgba(0, 0, 0, 0.12)",background:{paper:yn.white,default:yn.white},action:{active:"rgba(0, 0, 0, 0.54)",hover:"rgba(0, 0, 0, 0.04)",hoverOpacity:.04,selected:"rgba(0, 0, 0, 0.08)",selectedOpacity:.08,disabled:"rgba(0, 0, 0, 0.26)",disabledBackground:"rgba(0, 0, 0, 0.12)",disabledOpacity:.38,focus:"rgba(0, 0, 0, 0.12)",focusOpacity:.12,activatedOpacity:.12}},zr={text:{primary:yn.white,secondary:"rgba(255, 255, 255, 0.7)",disabled:"rgba(255, 255, 255, 0.5)",icon:"rgba(255, 255, 255, 0.5)"},divider:"rgba(255, 255, 255, 0.12)",background:{paper:"#121212",default:"#121212"},action:{active:yn.white,hover:"rgba(255, 255, 255, 0.08)",hoverOpacity:.08,selected:"rgba(255, 255, 255, 0.16)",selectedOpacity:.16,disabled:"rgba(255, 255, 255, 0.3)",disabledBackground:"rgba(255, 255, 255, 0.12)",disabledOpacity:.38,focus:"rgba(255, 255, 255, 0.12)",focusOpacity:.12,activatedOpacity:.24}};function _a(e,t,n,r){const o=r.light||r,s=r.dark||r*1.5;e[t]||(e.hasOwnProperty(n)?e[t]=e[n]:t==="light"?e.light=yp(e.main,o):t==="dark"&&(e.dark=xp(e.main,s)))}function Ip(e="light"){return e==="dark"?{main:_t[200],light:_t[50],dark:_t[400]}:{main:_t[700],light:_t[400],dark:_t[800]}}function Mp(e="light"){return e==="dark"?{main:Rt[200],light:Rt[50],dark:Rt[400]}:{main:Rt[500],light:Rt[300],dark:Rt[700]}}function $p(e="light"){return e==="dark"?{main:Ot[500],light:Ot[300],dark:Ot[700]}:{main:Ot[700],light:Ot[400],dark:Ot[800]}}function Dp(e="light"){return e==="dark"?{main:Pt[400],light:Pt[300],dark:Pt[700]}:{main:Pt[700],light:Pt[500],dark:Pt[900]}}function Ap(e="light"){return e==="dark"?{main:It[400],light:It[300],dark:It[700]}:{main:It[800],light:It[500],dark:It[900]}}function Bp(e="light"){return e==="dark"?{main:on[400],light:on[300],dark:on[700]}:{main:"#ed6c02",light:on[500],dark:on[900]}}function Vp(e){const{mode:t="light",contrastThreshold:n=3,tonalOffset:r=.2}=e,o=Ne(e,Pp),s=e.primary||Ip(t),i=e.secondary||Mp(t),l=e.error||$p(t),c=e.info||Dp(t),u=e.success||Ap(t),d=e.warning||Bp(t);function m(f){const h=Ra(f,zr.text.primary)>=n?zr.text.primary:Oa.text.primary;if(process.env.NODE_ENV!=="production"){const S=Ra(f,h);S<3&&console.error([`MUI: The contrast ratio of ${S}:1 for ${h} on ${f}`,"falls below the WCAG recommended absolute minimum contrast ratio of 3:1.","https://www.w3.org/TR/2008/REC-WCAG20-20081211/#visual-audio-contrast-contrast"].join(` -`))}return h}const w=({color:f,name:h,mainShade:S=500,lightShade:R=300,darkShade:j=700})=>{if(f=O({},f),!f.main&&f[S]&&(f.main=f[S]),!f.hasOwnProperty("main"))throw new Error(process.env.NODE_ENV!=="production"?`MUI: The color${h?` (${h})`:""} provided to augmentColor(color) is invalid. -The color object needs to have a \`main\` property or a \`${S}\` property.`:zt(11,h?` (${h})`:"",S));if(typeof f.main!="string")throw new Error(process.env.NODE_ENV!=="production"?`MUI: The color${h?` (${h})`:""} provided to augmentColor(color) is invalid. -\`color.main\` should be a string, but \`${JSON.stringify(f.main)}\` was provided instead. +The following color spaces are supported: srgb, display-p3, a98-rgb, prophoto-rgb, rec-2020.`:zt(10,o))}else r=r.split(",");return r=r.map(s=>parseFloat(s)),{type:n,values:r,colorSpace:o}}function xr(e){const{type:t,colorSpace:n}=e;let{values:r}=e;return t.indexOf("rgb")!==-1?r=r.map((o,s)=>s<3?parseInt(o,10):o):t.indexOf("hsl")!==-1&&(r[1]=`${r[1]}%`,r[2]=`${r[2]}%`),t.indexOf("color")!==-1?r=`${n} ${r.join(" ")}`:r=`${r.join(", ")}`,`${t}(${r})`}function vp(e){e=Nt(e);const{values:t}=e,n=t[0],r=t[1]/100,o=t[2]/100,s=r*Math.min(o,1-o),i=(d,u=(d+n/30)%12)=>o-s*Math.max(Math.min(u-3,9-u,1),-1);let l="rgb";const c=[Math.round(i(0)*255),Math.round(i(8)*255),Math.round(i(4)*255)];return e.type==="hsla"&&(l+="a",c.push(t[3])),xr({type:l,values:c})}function Ta(e){e=Nt(e);let t=e.type==="hsl"||e.type==="hsla"?Nt(vp(e)).values:e.values;return t=t.map(n=>(e.type!=="color"&&(n/=255),n<=.03928?n/12.92:((n+.055)/1.055)**2.4)),Number((.2126*t[0]+.7152*t[1]+.0722*t[2]).toFixed(3))}function Ra(e,t){const n=Ta(e),r=Ta(t);return(Math.max(n,r)+.05)/(Math.min(n,r)+.05)}function mi(e,t){return e=Nt(e),t=Ro(t),(e.type==="rgb"||e.type==="hsl")&&(e.type+="a"),e.type==="color"?e.values[3]=`/${t}`:e.values[3]=t,xr(e)}function xp(e,t){if(e=Nt(e),t=Ro(t),e.type.indexOf("hsl")!==-1)e.values[2]*=1-t;else if(e.type.indexOf("rgb")!==-1||e.type.indexOf("color")!==-1)for(let n=0;n<3;n+=1)e.values[n]*=1-t;return xr(e)}function yp(e,t){if(e=Nt(e),t=Ro(t),e.type.indexOf("hsl")!==-1)e.values[2]+=(100-e.values[2])*t;else if(e.type.indexOf("rgb")!==-1)for(let n=0;n<3;n+=1)e.values[n]+=(255-e.values[n])*t;else if(e.type.indexOf("color")!==-1)for(let n=0;n<3;n+=1)e.values[n]+=(1-e.values[n])*t;return xr(e)}function Np(e,t){return O({toolbar:{minHeight:56,[e.up("xs")]:{"@media (orientation: landscape)":{minHeight:48}},[e.up("sm")]:{minHeight:64}}},t)}const kp={black:"#000",white:"#fff"},yn=kp,Sp={50:"#fafafa",100:"#f5f5f5",200:"#eeeeee",300:"#e0e0e0",400:"#bdbdbd",500:"#9e9e9e",600:"#757575",700:"#616161",800:"#424242",900:"#212121",A100:"#f5f5f5",A200:"#eeeeee",A400:"#bdbdbd",A700:"#616161"},Ep=Sp,jp={50:"#f3e5f5",100:"#e1bee7",200:"#ce93d8",300:"#ba68c8",400:"#ab47bc",500:"#9c27b0",600:"#8e24aa",700:"#7b1fa2",800:"#6a1b9a",900:"#4a148c",A100:"#ea80fc",A200:"#e040fb",A400:"#d500f9",A700:"#aa00ff"},Rt=jp,Cp={50:"#ffebee",100:"#ffcdd2",200:"#ef9a9a",300:"#e57373",400:"#ef5350",500:"#f44336",600:"#e53935",700:"#d32f2f",800:"#c62828",900:"#b71c1c",A100:"#ff8a80",A200:"#ff5252",A400:"#ff1744",A700:"#d50000"},Ot=Cp,Tp={50:"#fff3e0",100:"#ffe0b2",200:"#ffcc80",300:"#ffb74d",400:"#ffa726",500:"#ff9800",600:"#fb8c00",700:"#f57c00",800:"#ef6c00",900:"#e65100",A100:"#ffd180",A200:"#ffab40",A400:"#ff9100",A700:"#ff6d00"},on=Tp,Rp={50:"#e3f2fd",100:"#bbdefb",200:"#90caf9",300:"#64b5f6",400:"#42a5f5",500:"#2196f3",600:"#1e88e5",700:"#1976d2",800:"#1565c0",900:"#0d47a1",A100:"#82b1ff",A200:"#448aff",A400:"#2979ff",A700:"#2962ff"},_t=Rp,Op={50:"#e1f5fe",100:"#b3e5fc",200:"#81d4fa",300:"#4fc3f7",400:"#29b6f6",500:"#03a9f4",600:"#039be5",700:"#0288d1",800:"#0277bd",900:"#01579b",A100:"#80d8ff",A200:"#40c4ff",A400:"#00b0ff",A700:"#0091ea"},Pt=Op,_p={50:"#e8f5e9",100:"#c8e6c9",200:"#a5d6a7",300:"#81c784",400:"#66bb6a",500:"#4caf50",600:"#43a047",700:"#388e3c",800:"#2e7d32",900:"#1b5e20",A100:"#b9f6ca",A200:"#69f0ae",A400:"#00e676",A700:"#00c853"},It=_p,Pp=["mode","contrastThreshold","tonalOffset"],Oa={text:{primary:"rgba(0, 0, 0, 0.87)",secondary:"rgba(0, 0, 0, 0.6)",disabled:"rgba(0, 0, 0, 0.38)"},divider:"rgba(0, 0, 0, 0.12)",background:{paper:yn.white,default:yn.white},action:{active:"rgba(0, 0, 0, 0.54)",hover:"rgba(0, 0, 0, 0.04)",hoverOpacity:.04,selected:"rgba(0, 0, 0, 0.08)",selectedOpacity:.08,disabled:"rgba(0, 0, 0, 0.26)",disabledBackground:"rgba(0, 0, 0, 0.12)",disabledOpacity:.38,focus:"rgba(0, 0, 0, 0.12)",focusOpacity:.12,activatedOpacity:.12}},zr={text:{primary:yn.white,secondary:"rgba(255, 255, 255, 0.7)",disabled:"rgba(255, 255, 255, 0.5)",icon:"rgba(255, 255, 255, 0.5)"},divider:"rgba(255, 255, 255, 0.12)",background:{paper:"#121212",default:"#121212"},action:{active:yn.white,hover:"rgba(255, 255, 255, 0.08)",hoverOpacity:.08,selected:"rgba(255, 255, 255, 0.16)",selectedOpacity:.16,disabled:"rgba(255, 255, 255, 0.3)",disabledBackground:"rgba(255, 255, 255, 0.12)",disabledOpacity:.38,focus:"rgba(255, 255, 255, 0.12)",focusOpacity:.12,activatedOpacity:.24}};function _a(e,t,n,r){const o=r.light||r,s=r.dark||r*1.5;e[t]||(e.hasOwnProperty(n)?e[t]=e[n]:t==="light"?e.light=yp(e.main,o):t==="dark"&&(e.dark=xp(e.main,s)))}function Ip(e="light"){return e==="dark"?{main:_t[200],light:_t[50],dark:_t[400]}:{main:_t[700],light:_t[400],dark:_t[800]}}function Mp(e="light"){return e==="dark"?{main:Rt[200],light:Rt[50],dark:Rt[400]}:{main:Rt[500],light:Rt[300],dark:Rt[700]}}function $p(e="light"){return e==="dark"?{main:Ot[500],light:Ot[300],dark:Ot[700]}:{main:Ot[700],light:Ot[400],dark:Ot[800]}}function Dp(e="light"){return e==="dark"?{main:Pt[400],light:Pt[300],dark:Pt[700]}:{main:Pt[700],light:Pt[500],dark:Pt[900]}}function Ap(e="light"){return e==="dark"?{main:It[400],light:It[300],dark:It[700]}:{main:It[800],light:It[500],dark:It[900]}}function Bp(e="light"){return e==="dark"?{main:on[400],light:on[300],dark:on[700]}:{main:"#ed6c02",light:on[500],dark:on[900]}}function Vp(e){const{mode:t="light",contrastThreshold:n=3,tonalOffset:r=.2}=e,o=Ne(e,Pp),s=e.primary||Ip(t),i=e.secondary||Mp(t),l=e.error||$p(t),c=e.info||Dp(t),d=e.success||Ap(t),u=e.warning||Bp(t);function f(m){const h=Ra(m,zr.text.primary)>=n?zr.text.primary:Oa.text.primary;if(process.env.NODE_ENV!=="production"){const S=Ra(m,h);S<3&&console.error([`MUI: The contrast ratio of ${S}:1 for ${h} on ${m}`,"falls below the WCAG recommended absolute minimum contrast ratio of 3:1.","https://www.w3.org/TR/2008/REC-WCAG20-20081211/#visual-audio-contrast-contrast"].join(` +`))}return h}const w=({color:m,name:h,mainShade:S=500,lightShade:R=300,darkShade:j=700})=>{if(m=O({},m),!m.main&&m[S]&&(m.main=m[S]),!m.hasOwnProperty("main"))throw new Error(process.env.NODE_ENV!=="production"?`MUI: The color${h?` (${h})`:""} provided to augmentColor(color) is invalid. +The color object needs to have a \`main\` property or a \`${S}\` property.`:zt(11,h?` (${h})`:"",S));if(typeof m.main!="string")throw new Error(process.env.NODE_ENV!=="production"?`MUI: The color${h?` (${h})`:""} provided to augmentColor(color) is invalid. +\`color.main\` should be a string, but \`${JSON.stringify(m.main)}\` was provided instead. Did you intend to use one of the following approaches? @@ -55,16 +55,16 @@ const theme1 = createTheme({ palette: { const theme2 = createTheme({ palette: { primary: { main: green[500] }, -} });`:zt(12,h?` (${h})`:"",JSON.stringify(f.main)));return _a(f,"light",R,r),_a(f,"dark",j,r),f.contrastText||(f.contrastText=m(f.main)),f},b={dark:zr,light:Oa};return process.env.NODE_ENV!=="production"&&(b[t]||console.error(`MUI: The palette mode \`${t}\` is not supported.`)),Qe(O({common:O({},yn),mode:t,primary:w({color:s,name:"primary"}),secondary:w({color:i,name:"secondary",mainShade:"A400",lightShade:"A200",darkShade:"A700"}),error:w({color:l,name:"error"}),warning:w({color:d,name:"warning"}),info:w({color:c,name:"info"}),success:w({color:u,name:"success"}),grey:Ep,contrastThreshold:n,getContrastText:m,augmentColor:w,tonalOffset:r},b[t]),o)}const zp=["fontFamily","fontSize","fontWeightLight","fontWeightRegular","fontWeightMedium","fontWeightBold","htmlFontSize","allVariants","pxToRem"];function Lp(e){return Math.round(e*1e5)/1e5}const Pa={textTransform:"uppercase"},Ia='"Roboto", "Helvetica", "Arial", sans-serif';function Fp(e,t){const n=typeof t=="function"?t(e):t,{fontFamily:r=Ia,fontSize:o=14,fontWeightLight:s=300,fontWeightRegular:i=400,fontWeightMedium:l=500,fontWeightBold:c=700,htmlFontSize:u=16,allVariants:d,pxToRem:m}=n,w=Ne(n,zp);process.env.NODE_ENV!=="production"&&(typeof o!="number"&&console.error("MUI: `fontSize` is required to be a number."),typeof u!="number"&&console.error("MUI: `htmlFontSize` is required to be a number."));const b=o/14,x=m||(S=>`${S/u*b}rem`),f=(S,R,j,E,v)=>O({fontFamily:r,fontWeight:S,fontSize:x(R),lineHeight:j},r===Ia?{letterSpacing:`${Lp(E/R)}em`}:{},v,d),h={h1:f(s,96,1.167,-1.5),h2:f(s,60,1.2,-.5),h3:f(i,48,1.167,0),h4:f(i,34,1.235,.25),h5:f(i,24,1.334,0),h6:f(l,20,1.6,.15),subtitle1:f(i,16,1.75,.15),subtitle2:f(l,14,1.57,.1),body1:f(i,16,1.5,.15),body2:f(i,14,1.43,.15),button:f(l,14,1.75,.4,Pa),caption:f(i,12,1.66,.4),overline:f(i,12,2.66,1,Pa),inherit:{fontFamily:"inherit",fontWeight:"inherit",fontSize:"inherit",lineHeight:"inherit",letterSpacing:"inherit"}};return Qe(O({htmlFontSize:u,pxToRem:x,fontFamily:r,fontSize:o,fontWeightLight:s,fontWeightRegular:i,fontWeightMedium:l,fontWeightBold:c},h),w,{clone:!1})}const Gp=.2,Up=.14,qp=.12;function we(...e){return[`${e[0]}px ${e[1]}px ${e[2]}px ${e[3]}px rgba(0,0,0,${Gp})`,`${e[4]}px ${e[5]}px ${e[6]}px ${e[7]}px rgba(0,0,0,${Up})`,`${e[8]}px ${e[9]}px ${e[10]}px ${e[11]}px rgba(0,0,0,${qp})`].join(",")}const Hp=["none",we(0,2,1,-1,0,1,1,0,0,1,3,0),we(0,3,1,-2,0,2,2,0,0,1,5,0),we(0,3,3,-2,0,3,4,0,0,1,8,0),we(0,2,4,-1,0,4,5,0,0,1,10,0),we(0,3,5,-1,0,5,8,0,0,1,14,0),we(0,3,5,-1,0,6,10,0,0,1,18,0),we(0,4,5,-2,0,7,10,1,0,2,16,1),we(0,5,5,-3,0,8,10,1,0,3,14,2),we(0,5,6,-3,0,9,12,1,0,3,16,2),we(0,6,6,-3,0,10,14,1,0,4,18,3),we(0,6,7,-4,0,11,15,1,0,4,20,3),we(0,7,8,-4,0,12,17,2,0,5,22,4),we(0,7,8,-4,0,13,19,2,0,5,24,4),we(0,7,9,-4,0,14,21,2,0,5,26,4),we(0,8,9,-5,0,15,22,2,0,6,28,5),we(0,8,10,-5,0,16,24,2,0,6,30,5),we(0,8,11,-5,0,17,26,2,0,6,32,5),we(0,9,11,-5,0,18,28,2,0,7,34,6),we(0,9,12,-6,0,19,29,2,0,7,36,6),we(0,10,13,-6,0,20,31,3,0,8,38,7),we(0,10,13,-6,0,21,33,3,0,8,40,7),we(0,10,14,-6,0,22,35,3,0,8,42,7),we(0,11,14,-7,0,23,36,3,0,9,44,8),we(0,11,15,-7,0,24,38,3,0,9,46,8)],Xp=Hp,Yp=["duration","easing","delay"],Wp={easeInOut:"cubic-bezier(0.4, 0, 0.2, 1)",easeOut:"cubic-bezier(0.0, 0, 0.2, 1)",easeIn:"cubic-bezier(0.4, 0, 1, 1)",sharp:"cubic-bezier(0.4, 0, 0.6, 1)"},Kp={shortest:150,shorter:200,short:250,standard:300,complex:375,enteringScreen:225,leavingScreen:195};function Ma(e){return`${Math.round(e)}ms`}function Jp(e){if(!e)return 0;const t=e/36;return Math.round((4+15*t**.25+t/5)*10)}function Zp(e){const t=O({},Wp,e.easing),n=O({},Kp,e.duration);return O({getAutoHeightDuration:Jp,create:(o=["all"],s={})=>{const{duration:i=n.standard,easing:l=t.easeInOut,delay:c=0}=s,u=Ne(s,Yp);if(process.env.NODE_ENV!=="production"){const d=w=>typeof w=="string",m=w=>!isNaN(parseFloat(w));!d(o)&&!Array.isArray(o)&&console.error('MUI: Argument "props" must be a string or Array.'),!m(i)&&!d(i)&&console.error(`MUI: Argument "duration" must be a number or a string but found ${i}.`),d(l)||console.error('MUI: Argument "easing" must be a string.'),!m(c)&&!d(c)&&console.error('MUI: Argument "delay" must be a number or a string.'),typeof s!="object"&&console.error(["MUI: Secong argument of transition.create must be an object.","Arguments should be either `create('prop1', options)` or `create(['prop1', 'prop2'], options)`"].join(` -`)),Object.keys(u).length!==0&&console.error(`MUI: Unrecognized argument(s) [${Object.keys(u).join(",")}].`)}return(Array.isArray(o)?o:[o]).map(d=>`${d} ${typeof i=="string"?i:Ma(i)} ${l} ${typeof c=="string"?c:Ma(c)}`).join(",")}},e,{easing:t,duration:n})}const Qp={mobileStepper:1e3,fab:1050,speedDial:1050,appBar:1100,drawer:1200,modal:1300,snackbar:1400,tooltip:1500},ew=Qp,tw=["breakpoints","mixins","spacing","palette","transitions","typography","shape"];function nw(e={},...t){const{mixins:n={},palette:r={},transitions:o={},typography:s={}}=e,i=Ne(e,tw);if(e.vars)throw new Error(process.env.NODE_ENV!=="production"?"MUI: `vars` is a private field used for CSS variables support.\nPlease use another name.":zt(18));const l=Vp(r),c=To(e);let u=Qe(c,{mixins:Np(c.breakpoints,n),palette:l,shadows:Xp.slice(),typography:Fp(l,s),transitions:Zp(o),zIndex:O({},ew)});if(u=Qe(u,i),u=t.reduce((d,m)=>Qe(d,m),u),process.env.NODE_ENV!=="production"){const d=["active","checked","completed","disabled","error","expanded","focused","focusVisible","required","selected"],m=(w,b)=>{let x;for(x in w){const f=w[x];if(d.indexOf(x)!==-1&&Object.keys(f).length>0){if(process.env.NODE_ENV!=="production"){const h=ur("",x);console.error([`MUI: The \`${b}\` component increases the CSS specificity of the \`${x}\` internal state.`,"You can not override it like this: ",JSON.stringify(w,null,2),"",`Instead, you need to use the '&.${h}' syntax:`,JSON.stringify({root:{[`&.${h}`]:f}},null,2),"","https://mui.com/r/state-classes-guide"].join(` -`))}w[x]={}}}};Object.keys(u.components).forEach(w=>{const b=u.components[w].styleOverrides;b&&w.indexOf("Mui")===0&&m(b,w)})}return u.unstable_sxConfig=O({},jo,i==null?void 0:i.unstable_sxConfig),u.unstable_sx=function(m){return Co({sx:m,theme:this})},u}const rw=nw(),Oo=rw,_o="$$material";function Po({props:e,name:t}){return gp({props:e,name:t,defaultTheme:Oo,themeId:_o})}const ow=e=>qn(e)&&e!=="classes",aw=mp({themeId:_o,defaultTheme:Oo,rootShouldForwardProp:ow}),In=aw;function sw(e){return ur("MuiSvgIcon",e)}ci("MuiSvgIcon",["root","colorPrimary","colorSecondary","colorAction","colorError","colorDisabled","fontSizeInherit","fontSizeSmall","fontSizeMedium","fontSizeLarge"]);const iw=["children","className","color","component","fontSize","htmlColor","inheritViewBox","titleAccess","viewBox"],lw=e=>{const{color:t,fontSize:n,classes:r}=e,o={root:["root",t!=="inherit"&&`color${Ye(t)}`,`fontSize${Ye(n)}`]};return ko(o,sw,r)},cw=In("svg",{name:"MuiSvgIcon",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.root,n.color!=="inherit"&&t[`color${Ye(n.color)}`],t[`fontSize${Ye(n.fontSize)}`]]}})(({theme:e,ownerState:t})=>{var n,r,o,s,i,l,c,u,d,m,w,b,x;return{userSelect:"none",width:"1em",height:"1em",display:"inline-block",fill:t.hasSvgAsChild?void 0:"currentColor",flexShrink:0,transition:(n=e.transitions)==null||(r=n.create)==null?void 0:r.call(n,"fill",{duration:(o=e.transitions)==null||(o=o.duration)==null?void 0:o.shorter}),fontSize:{inherit:"inherit",small:((s=e.typography)==null||(i=s.pxToRem)==null?void 0:i.call(s,20))||"1.25rem",medium:((l=e.typography)==null||(c=l.pxToRem)==null?void 0:c.call(l,24))||"1.5rem",large:((u=e.typography)==null||(d=u.pxToRem)==null?void 0:d.call(u,35))||"2.1875rem"}[t.fontSize],color:(m=(w=(e.vars||e).palette)==null||(w=w[t.color])==null?void 0:w.main)!=null?m:{action:(b=(e.vars||e).palette)==null||(b=b.action)==null?void 0:b.active,disabled:(x=(e.vars||e).palette)==null||(x=x.action)==null?void 0:x.disabled,inherit:void 0}[t.color]}}),Io=M.forwardRef(function(t,n){const r=Po({props:t,name:"MuiSvgIcon"}),{children:o,className:s,color:i="inherit",component:l="svg",fontSize:c="medium",htmlColor:u,inheritViewBox:d=!1,titleAccess:m,viewBox:w="0 0 24 24"}=r,b=Ne(r,iw),x=M.isValidElement(o)&&o.type==="svg",f=O({},r,{color:i,component:l,fontSize:c,instanceFontSize:t.fontSize,inheritViewBox:d,viewBox:w,hasSvgAsChild:x}),h={};d||(h.viewBox=w);const S=lw(f);return a.jsxs(cw,O({as:l,className:ot(S.root,s),focusable:"false",color:u,"aria-hidden":m?void 0:!0,role:m?"img":void 0,ref:n},h,b,x&&o.props,{ownerState:f,children:[x?o.props.children:o,m?a.jsx("title",{children:m}):null]}))});process.env.NODE_ENV!=="production"&&(Io.propTypes={children:p.node,classes:p.object,className:p.string,color:p.oneOfType([p.oneOf(["inherit","action","disabled","primary","secondary","error","info","success","warning"]),p.string]),component:p.elementType,fontSize:p.oneOfType([p.oneOf(["inherit","large","medium","small"]),p.string]),htmlColor:p.string,inheritViewBox:p.bool,shapeRendering:p.string,sx:p.oneOfType([p.arrayOf(p.oneOfType([p.func,p.object,p.bool])),p.func,p.object]),titleAccess:p.string,viewBox:p.string});Io.muiName="SvgIcon";const $a=Io;function hi(e,t){function n(r,o){return a.jsx($a,O({"data-testid":`${t}Icon`,ref:o},r,{children:e}))}return process.env.NODE_ENV!=="production"&&(n.displayName=`${t}Icon`),n.muiName=$a.muiName,M.memo(M.forwardRef(n))}const dw={configure:e=>{process.env.NODE_ENV!=="production"&&console.warn(["MUI: `ClassNameGenerator` import from `@mui/material/utils` is outdated and might cause unexpected issues.","","You should use `import { unstable_ClassNameGenerator } from '@mui/material/className'` instead","","The detail of the issue: https://github.com/mui/material-ui/issues/30011#issuecomment-1024993401","","The updated documentation: https://mui.com/guides/classname-generator/"].join(` -`)),ii.configure(e)}},uw=Object.freeze(Object.defineProperty({__proto__:null,capitalize:Ye,createChainedFunction:zd,createSvgIcon:hi,debounce:Ld,deprecatedPropType:Fd,isMuiElement:Gd,ownerDocument:Kn,ownerWindow:Ud,requirePropFactory:qd,setRef:Jn,unstable_ClassNameGenerator:dw,unstable_useEnhancedEffect:Lt,unstable_useId:ri,unsupportedProp:Yd,useControlled:oi,useEventCallback:Zr,useForkRef:yt,useIsFocusVisible:ai},Symbol.toStringTag,{value:"Module"})),pw=xd(uw);var Da;function ww(){return Da||(Da=1,function(e){"use client";Object.defineProperty(e,"__esModule",{value:!0}),Object.defineProperty(e,"default",{enumerable:!0,get:function(){return t.createSvgIcon}});var t=pw}(Pr)),Pr}var fw=yd;Object.defineProperty(xo,"__esModule",{value:!0});var gi=xo.default=void 0,mw=fw(ww()),hw=a;gi=xo.default=(0,mw.default)((0,hw.jsx)("path",{d:"m10 17 5-5-5-5z"}),"ArrowRight");function gw(e){return typeof e=="string"}function un(e,t,n){return e===void 0||gw(e)?t:O({},t,{ownerState:O({},t.ownerState,n)})}const bw={disableDefaultClasses:!1},vw=M.createContext(bw);function xw(e){const{disableDefaultClasses:t}=M.useContext(vw);return n=>t?"":e(n)}function yw(e,t=[]){if(e===void 0)return{};const n={};return Object.keys(e).filter(r=>r.match(/^on[A-Z]/)&&typeof e[r]=="function"&&!t.includes(r)).forEach(r=>{n[r]=e[r]}),n}function Nw(e,t,n){return typeof e=="function"?e(t,n):e}function Aa(e){if(e===void 0)return{};const t={};return Object.keys(e).filter(n=>!(n.match(/^on[A-Z]/)&&typeof e[n]=="function")).forEach(n=>{t[n]=e[n]}),t}function kw(e){const{getSlotProps:t,additionalProps:n,externalSlotProps:r,externalForwardedProps:o,className:s}=e;if(!t){const b=ot(n==null?void 0:n.className,s,o==null?void 0:o.className,r==null?void 0:r.className),x=O({},n==null?void 0:n.style,o==null?void 0:o.style,r==null?void 0:r.style),f=O({},n,o,r);return b.length>0&&(f.className=b),Object.keys(x).length>0&&(f.style=x),{props:f,internalRef:void 0}}const i=yw(O({},o,r)),l=Aa(r),c=Aa(o),u=t(i),d=ot(u==null?void 0:u.className,n==null?void 0:n.className,s,o==null?void 0:o.className,r==null?void 0:r.className),m=O({},u==null?void 0:u.style,n==null?void 0:n.style,o==null?void 0:o.style,r==null?void 0:r.style),w=O({},u,n,c,l);return d.length>0&&(w.className=d),Object.keys(m).length>0&&(w.style=m),{props:w,internalRef:u.ref}}const Sw=["elementType","externalSlotProps","ownerState","skipResolvingSlotProps"];function Ew(e){var t;const{elementType:n,externalSlotProps:r,ownerState:o,skipResolvingSlotProps:s=!1}=e,i=Ne(e,Sw),l=s?{}:Nw(r,o),{props:c,internalRef:u}=kw(O({},i,{externalSlotProps:l})),d=yt(u,l==null?void 0:l.ref,(t=e.additionalProps)==null?void 0:t.ref);return un(n,O({},c,{ref:d}),o)}const bi="base";function jw(e){return`${bi}--${e}`}function Cw(e,t){return`${bi}-${e}-${t}`}function vi(e,t){const n=li[t];return n?jw(n):Cw(e,t)}function Tw(e,t){const n={};return t.forEach(r=>{n[r]=vi(e,r)}),n}function Rw(e){return typeof e=="function"?e():e}const Qn=M.forwardRef(function(t,n){const{children:r,container:o,disablePortal:s=!1}=t,[i,l]=M.useState(null),c=yt(M.isValidElement(r)?r.ref:null,n);if(Lt(()=>{s||l(Rw(o)||document.body)},[o,s]),Lt(()=>{if(i&&!s)return Jn(n,i),()=>{Jn(n,null)}},[n,i,s]),s){if(M.isValidElement(r)){const u={ref:c};return M.cloneElement(r,u)}return a.jsx(M.Fragment,{children:r})}return a.jsx(M.Fragment,{children:i&&Ol.createPortal(r,i)})});process.env.NODE_ENV!=="production"&&(Qn.propTypes={children:p.node,container:p.oneOfType([xn,p.func]),disablePortal:p.bool});process.env.NODE_ENV!=="production"&&(Qn["propTypes"]=Id(Qn.propTypes));var Ce="top",ze="bottom",Le="right",Te="left",Mo="auto",Mn=[Ce,ze,Le,Te],Ft="start",Nn="end",Ow="clippingParents",xi="viewport",an="popper",_w="reference",Ba=Mn.reduce(function(e,t){return e.concat([t+"-"+Ft,t+"-"+Nn])},[]),yi=[].concat(Mn,[Mo]).reduce(function(e,t){return e.concat([t,t+"-"+Ft,t+"-"+Nn])},[]),Pw="beforeRead",Iw="read",Mw="afterRead",$w="beforeMain",Dw="main",Aw="afterMain",Bw="beforeWrite",Vw="write",zw="afterWrite",Lw=[Pw,Iw,Mw,$w,Dw,Aw,Bw,Vw,zw];function We(e){return e?(e.nodeName||"").toLowerCase():null}function $e(e){if(e==null)return window;if(e.toString()!=="[object Window]"){var t=e.ownerDocument;return t&&t.defaultView||window}return e}function kt(e){var t=$e(e).Element;return e instanceof t||e instanceof Element}function Ve(e){var t=$e(e).HTMLElement;return e instanceof t||e instanceof HTMLElement}function $o(e){if(typeof ShadowRoot>"u")return!1;var t=$e(e).ShadowRoot;return e instanceof t||e instanceof ShadowRoot}function Fw(e){var t=e.state;Object.keys(t.elements).forEach(function(n){var r=t.styles[n]||{},o=t.attributes[n]||{},s=t.elements[n];!Ve(s)||!We(s)||(Object.assign(s.style,r),Object.keys(o).forEach(function(i){var l=o[i];l===!1?s.removeAttribute(i):s.setAttribute(i,l===!0?"":l)}))})}function Gw(e){var t=e.state,n={popper:{position:t.options.strategy,left:"0",top:"0",margin:"0"},arrow:{position:"absolute"},reference:{}};return Object.assign(t.elements.popper.style,n.popper),t.styles=n,t.elements.arrow&&Object.assign(t.elements.arrow.style,n.arrow),function(){Object.keys(t.elements).forEach(function(r){var o=t.elements[r],s=t.attributes[r]||{},i=Object.keys(t.styles.hasOwnProperty(r)?t.styles[r]:n[r]),l=i.reduce(function(c,u){return c[u]="",c},{});!Ve(o)||!We(o)||(Object.assign(o.style,l),Object.keys(s).forEach(function(c){o.removeAttribute(c)}))})}}const Uw={name:"applyStyles",enabled:!0,phase:"write",fn:Fw,effect:Gw,requires:["computeStyles"]};function Xe(e){return e.split("-")[0]}var ht=Math.max,er=Math.min,Gt=Math.round;function eo(){var e=navigator.userAgentData;return e!=null&&e.brands&&Array.isArray(e.brands)?e.brands.map(function(t){return t.brand+"/"+t.version}).join(" "):navigator.userAgent}function Ni(){return!/^((?!chrome|android).)*safari/i.test(eo())}function Ut(e,t,n){t===void 0&&(t=!1),n===void 0&&(n=!1);var r=e.getBoundingClientRect(),o=1,s=1;t&&Ve(e)&&(o=e.offsetWidth>0&&Gt(r.width)/e.offsetWidth||1,s=e.offsetHeight>0&&Gt(r.height)/e.offsetHeight||1);var i=kt(e)?$e(e):window,l=i.visualViewport,c=!Ni()&&n,u=(r.left+(c&&l?l.offsetLeft:0))/o,d=(r.top+(c&&l?l.offsetTop:0))/s,m=r.width/o,w=r.height/s;return{width:m,height:w,top:d,right:u+m,bottom:d+w,left:u,x:u,y:d}}function Do(e){var t=Ut(e),n=e.offsetWidth,r=e.offsetHeight;return Math.abs(t.width-n)<=1&&(n=t.width),Math.abs(t.height-r)<=1&&(r=t.height),{x:e.offsetLeft,y:e.offsetTop,width:n,height:r}}function ki(e,t){var n=t.getRootNode&&t.getRootNode();if(e.contains(t))return!0;if(n&&$o(n)){var r=t;do{if(r&&e.isSameNode(r))return!0;r=r.parentNode||r.host}while(r)}return!1}function tt(e){return $e(e).getComputedStyle(e)}function qw(e){return["table","td","th"].indexOf(We(e))>=0}function it(e){return((kt(e)?e.ownerDocument:e.document)||window.document).documentElement}function yr(e){return We(e)==="html"?e:e.assignedSlot||e.parentNode||($o(e)?e.host:null)||it(e)}function Va(e){return!Ve(e)||tt(e).position==="fixed"?null:e.offsetParent}function Hw(e){var t=/firefox/i.test(eo()),n=/Trident/i.test(eo());if(n&&Ve(e)){var r=tt(e);if(r.position==="fixed")return null}var o=yr(e);for($o(o)&&(o=o.host);Ve(o)&&["html","body"].indexOf(We(o))<0;){var s=tt(o);if(s.transform!=="none"||s.perspective!=="none"||s.contain==="paint"||["transform","perspective"].indexOf(s.willChange)!==-1||t&&s.willChange==="filter"||t&&s.filter&&s.filter!=="none")return o;o=o.parentNode}return null}function $n(e){for(var t=$e(e),n=Va(e);n&&qw(n)&&tt(n).position==="static";)n=Va(n);return n&&(We(n)==="html"||We(n)==="body"&&tt(n).position==="static")?t:n||Hw(e)||t}function Ao(e){return["top","bottom"].indexOf(e)>=0?"x":"y"}function hn(e,t,n){return ht(e,er(t,n))}function Xw(e,t,n){var r=hn(e,t,n);return r>n?n:r}function Si(){return{top:0,right:0,bottom:0,left:0}}function Ei(e){return Object.assign({},Si(),e)}function ji(e,t){return t.reduce(function(n,r){return n[r]=e,n},{})}var Yw=function(t,n){return t=typeof t=="function"?t(Object.assign({},n.rects,{placement:n.placement})):t,Ei(typeof t!="number"?t:ji(t,Mn))};function Ww(e){var t,n=e.state,r=e.name,o=e.options,s=n.elements.arrow,i=n.modifiersData.popperOffsets,l=Xe(n.placement),c=Ao(l),u=[Te,Le].indexOf(l)>=0,d=u?"height":"width";if(!(!s||!i)){var m=Yw(o.padding,n),w=Do(s),b=c==="y"?Ce:Te,x=c==="y"?ze:Le,f=n.rects.reference[d]+n.rects.reference[c]-i[c]-n.rects.popper[d],h=i[c]-n.rects.reference[c],S=$n(s),R=S?c==="y"?S.clientHeight||0:S.clientWidth||0:0,j=f/2-h/2,E=m[b],v=R-w[d]-m[x],P=R/2-w[d]/2+j,V=hn(E,P,v),U=c;n.modifiersData[r]=(t={},t[U]=V,t.centerOffset=V-P,t)}}function Kw(e){var t=e.state,n=e.options,r=n.element,o=r===void 0?"[data-popper-arrow]":r;o!=null&&(typeof o=="string"&&(o=t.elements.popper.querySelector(o),!o)||ki(t.elements.popper,o)&&(t.elements.arrow=o))}const Jw={name:"arrow",enabled:!0,phase:"main",fn:Ww,effect:Kw,requires:["popperOffsets"],requiresIfExists:["preventOverflow"]};function qt(e){return e.split("-")[1]}var Zw={top:"auto",right:"auto",bottom:"auto",left:"auto"};function Qw(e,t){var n=e.x,r=e.y,o=t.devicePixelRatio||1;return{x:Gt(n*o)/o||0,y:Gt(r*o)/o||0}}function za(e){var t,n=e.popper,r=e.popperRect,o=e.placement,s=e.variation,i=e.offsets,l=e.position,c=e.gpuAcceleration,u=e.adaptive,d=e.roundOffsets,m=e.isFixed,w=i.x,b=w===void 0?0:w,x=i.y,f=x===void 0?0:x,h=typeof d=="function"?d({x:b,y:f}):{x:b,y:f};b=h.x,f=h.y;var S=i.hasOwnProperty("x"),R=i.hasOwnProperty("y"),j=Te,E=Ce,v=window;if(u){var P=$n(n),V="clientHeight",U="clientWidth";if(P===$e(n)&&(P=it(n),tt(P).position!=="static"&&l==="absolute"&&(V="scrollHeight",U="scrollWidth")),P=P,o===Ce||(o===Te||o===Le)&&s===Nn){E=ze;var C=m&&P===v&&v.visualViewport?v.visualViewport.height:P[V];f-=C-r.height,f*=c?1:-1}if(o===Te||(o===Ce||o===ze)&&s===Nn){j=Le;var _=m&&P===v&&v.visualViewport?v.visualViewport.width:P[U];b-=_-r.width,b*=c?1:-1}}var k=Object.assign({position:l},u&&Zw),D=d===!0?Qw({x:b,y:f},$e(n)):{x:b,y:f};if(b=D.x,f=D.y,c){var $;return Object.assign({},k,($={},$[E]=R?"0":"",$[j]=S?"0":"",$.transform=(v.devicePixelRatio||1)<=1?"translate("+b+"px, "+f+"px)":"translate3d("+b+"px, "+f+"px, 0)",$))}return Object.assign({},k,(t={},t[E]=R?f+"px":"",t[j]=S?b+"px":"",t.transform="",t))}function ef(e){var t=e.state,n=e.options,r=n.gpuAcceleration,o=r===void 0?!0:r,s=n.adaptive,i=s===void 0?!0:s,l=n.roundOffsets,c=l===void 0?!0:l,u={placement:Xe(t.placement),variation:qt(t.placement),popper:t.elements.popper,popperRect:t.rects.popper,gpuAcceleration:o,isFixed:t.options.strategy==="fixed"};t.modifiersData.popperOffsets!=null&&(t.styles.popper=Object.assign({},t.styles.popper,za(Object.assign({},u,{offsets:t.modifiersData.popperOffsets,position:t.options.strategy,adaptive:i,roundOffsets:c})))),t.modifiersData.arrow!=null&&(t.styles.arrow=Object.assign({},t.styles.arrow,za(Object.assign({},u,{offsets:t.modifiersData.arrow,position:"absolute",adaptive:!1,roundOffsets:c})))),t.attributes.popper=Object.assign({},t.attributes.popper,{"data-popper-placement":t.placement})}const tf={name:"computeStyles",enabled:!0,phase:"beforeWrite",fn:ef,data:{}};var Fn={passive:!0};function nf(e){var t=e.state,n=e.instance,r=e.options,o=r.scroll,s=o===void 0?!0:o,i=r.resize,l=i===void 0?!0:i,c=$e(t.elements.popper),u=[].concat(t.scrollParents.reference,t.scrollParents.popper);return s&&u.forEach(function(d){d.addEventListener("scroll",n.update,Fn)}),l&&c.addEventListener("resize",n.update,Fn),function(){s&&u.forEach(function(d){d.removeEventListener("scroll",n.update,Fn)}),l&&c.removeEventListener("resize",n.update,Fn)}}const rf={name:"eventListeners",enabled:!0,phase:"write",fn:function(){},effect:nf,data:{}};var of={left:"right",right:"left",bottom:"top",top:"bottom"};function Xn(e){return e.replace(/left|right|bottom|top/g,function(t){return of[t]})}var af={start:"end",end:"start"};function La(e){return e.replace(/start|end/g,function(t){return af[t]})}function Bo(e){var t=$e(e),n=t.pageXOffset,r=t.pageYOffset;return{scrollLeft:n,scrollTop:r}}function Vo(e){return Ut(it(e)).left+Bo(e).scrollLeft}function sf(e,t){var n=$e(e),r=it(e),o=n.visualViewport,s=r.clientWidth,i=r.clientHeight,l=0,c=0;if(o){s=o.width,i=o.height;var u=Ni();(u||!u&&t==="fixed")&&(l=o.offsetLeft,c=o.offsetTop)}return{width:s,height:i,x:l+Vo(e),y:c}}function lf(e){var t,n=it(e),r=Bo(e),o=(t=e.ownerDocument)==null?void 0:t.body,s=ht(n.scrollWidth,n.clientWidth,o?o.scrollWidth:0,o?o.clientWidth:0),i=ht(n.scrollHeight,n.clientHeight,o?o.scrollHeight:0,o?o.clientHeight:0),l=-r.scrollLeft+Vo(e),c=-r.scrollTop;return tt(o||n).direction==="rtl"&&(l+=ht(n.clientWidth,o?o.clientWidth:0)-s),{width:s,height:i,x:l,y:c}}function zo(e){var t=tt(e),n=t.overflow,r=t.overflowX,o=t.overflowY;return/auto|scroll|overlay|hidden/.test(n+o+r)}function Ci(e){return["html","body","#document"].indexOf(We(e))>=0?e.ownerDocument.body:Ve(e)&&zo(e)?e:Ci(yr(e))}function gn(e,t){var n;t===void 0&&(t=[]);var r=Ci(e),o=r===((n=e.ownerDocument)==null?void 0:n.body),s=$e(r),i=o?[s].concat(s.visualViewport||[],zo(r)?r:[]):r,l=t.concat(i);return o?l:l.concat(gn(yr(i)))}function to(e){return Object.assign({},e,{left:e.x,top:e.y,right:e.x+e.width,bottom:e.y+e.height})}function cf(e,t){var n=Ut(e,!1,t==="fixed");return n.top=n.top+e.clientTop,n.left=n.left+e.clientLeft,n.bottom=n.top+e.clientHeight,n.right=n.left+e.clientWidth,n.width=e.clientWidth,n.height=e.clientHeight,n.x=n.left,n.y=n.top,n}function Fa(e,t,n){return t===xi?to(sf(e,n)):kt(t)?cf(t,n):to(lf(it(e)))}function df(e){var t=gn(yr(e)),n=["absolute","fixed"].indexOf(tt(e).position)>=0,r=n&&Ve(e)?$n(e):e;return kt(r)?t.filter(function(o){return kt(o)&&ki(o,r)&&We(o)!=="body"}):[]}function uf(e,t,n,r){var o=t==="clippingParents"?df(e):[].concat(t),s=[].concat(o,[n]),i=s[0],l=s.reduce(function(c,u){var d=Fa(e,u,r);return c.top=ht(d.top,c.top),c.right=er(d.right,c.right),c.bottom=er(d.bottom,c.bottom),c.left=ht(d.left,c.left),c},Fa(e,i,r));return l.width=l.right-l.left,l.height=l.bottom-l.top,l.x=l.left,l.y=l.top,l}function Ti(e){var t=e.reference,n=e.element,r=e.placement,o=r?Xe(r):null,s=r?qt(r):null,i=t.x+t.width/2-n.width/2,l=t.y+t.height/2-n.height/2,c;switch(o){case Ce:c={x:i,y:t.y-n.height};break;case ze:c={x:i,y:t.y+t.height};break;case Le:c={x:t.x+t.width,y:l};break;case Te:c={x:t.x-n.width,y:l};break;default:c={x:t.x,y:t.y}}var u=o?Ao(o):null;if(u!=null){var d=u==="y"?"height":"width";switch(s){case Ft:c[u]=c[u]-(t[d]/2-n[d]/2);break;case Nn:c[u]=c[u]+(t[d]/2-n[d]/2);break}}return c}function kn(e,t){t===void 0&&(t={});var n=t,r=n.placement,o=r===void 0?e.placement:r,s=n.strategy,i=s===void 0?e.strategy:s,l=n.boundary,c=l===void 0?Ow:l,u=n.rootBoundary,d=u===void 0?xi:u,m=n.elementContext,w=m===void 0?an:m,b=n.altBoundary,x=b===void 0?!1:b,f=n.padding,h=f===void 0?0:f,S=Ei(typeof h!="number"?h:ji(h,Mn)),R=w===an?_w:an,j=e.rects.popper,E=e.elements[x?R:w],v=uf(kt(E)?E:E.contextElement||it(e.elements.popper),c,d,i),P=Ut(e.elements.reference),V=Ti({reference:P,element:j,strategy:"absolute",placement:o}),U=to(Object.assign({},j,V)),C=w===an?U:P,_={top:v.top-C.top+S.top,bottom:C.bottom-v.bottom+S.bottom,left:v.left-C.left+S.left,right:C.right-v.right+S.right},k=e.modifiersData.offset;if(w===an&&k){var D=k[o];Object.keys(_).forEach(function($){var J=[Le,ze].indexOf($)>=0?1:-1,Y=[Ce,ze].indexOf($)>=0?"y":"x";_[$]+=D[Y]*J})}return _}function pf(e,t){t===void 0&&(t={});var n=t,r=n.placement,o=n.boundary,s=n.rootBoundary,i=n.padding,l=n.flipVariations,c=n.allowedAutoPlacements,u=c===void 0?yi:c,d=qt(r),m=d?l?Ba:Ba.filter(function(x){return qt(x)===d}):Mn,w=m.filter(function(x){return u.indexOf(x)>=0});w.length===0&&(w=m);var b=w.reduce(function(x,f){return x[f]=kn(e,{placement:f,boundary:o,rootBoundary:s,padding:i})[Xe(f)],x},{});return Object.keys(b).sort(function(x,f){return b[x]-b[f]})}function wf(e){if(Xe(e)===Mo)return[];var t=Xn(e);return[La(e),t,La(t)]}function ff(e){var t=e.state,n=e.options,r=e.name;if(!t.modifiersData[r]._skip){for(var o=n.mainAxis,s=o===void 0?!0:o,i=n.altAxis,l=i===void 0?!0:i,c=n.fallbackPlacements,u=n.padding,d=n.boundary,m=n.rootBoundary,w=n.altBoundary,b=n.flipVariations,x=b===void 0?!0:b,f=n.allowedAutoPlacements,h=t.options.placement,S=Xe(h),R=S===h,j=c||(R||!x?[Xn(h)]:wf(h)),E=[h].concat(j).reduce(function(B,X){return B.concat(Xe(X)===Mo?pf(t,{placement:X,boundary:d,rootBoundary:m,padding:u,flipVariations:x,allowedAutoPlacements:f}):X)},[]),v=t.rects.reference,P=t.rects.popper,V=new Map,U=!0,C=E[0],_=0;_=0,Y=J?"width":"height",F=kn(t,{placement:k,boundary:d,rootBoundary:m,altBoundary:w,padding:u}),te=J?$?Le:Te:$?ze:Ce;v[Y]>P[Y]&&(te=Xn(te));var se=Xn(te),oe=[];if(s&&oe.push(F[D]<=0),l&&oe.push(F[te]<=0,F[se]<=0),oe.every(function(B){return B})){C=k,U=!1;break}V.set(k,oe)}if(U)for(var y=x?3:1,T=function(X){var q=E.find(function(H){var G=V.get(H);if(G)return G.slice(0,X).every(function(K){return K})});if(q)return C=q,"break"},z=y;z>0;z--){var L=T(z);if(L==="break")break}t.placement!==C&&(t.modifiersData[r]._skip=!0,t.placement=C,t.reset=!0)}}const mf={name:"flip",enabled:!0,phase:"main",fn:ff,requiresIfExists:["offset"],data:{_skip:!1}};function Ga(e,t,n){return n===void 0&&(n={x:0,y:0}),{top:e.top-t.height-n.y,right:e.right-t.width+n.x,bottom:e.bottom-t.height+n.y,left:e.left-t.width-n.x}}function Ua(e){return[Ce,Le,ze,Te].some(function(t){return e[t]>=0})}function hf(e){var t=e.state,n=e.name,r=t.rects.reference,o=t.rects.popper,s=t.modifiersData.preventOverflow,i=kn(t,{elementContext:"reference"}),l=kn(t,{altBoundary:!0}),c=Ga(i,r),u=Ga(l,o,s),d=Ua(c),m=Ua(u);t.modifiersData[n]={referenceClippingOffsets:c,popperEscapeOffsets:u,isReferenceHidden:d,hasPopperEscaped:m},t.attributes.popper=Object.assign({},t.attributes.popper,{"data-popper-reference-hidden":d,"data-popper-escaped":m})}const gf={name:"hide",enabled:!0,phase:"main",requiresIfExists:["preventOverflow"],fn:hf};function bf(e,t,n){var r=Xe(e),o=[Te,Ce].indexOf(r)>=0?-1:1,s=typeof n=="function"?n(Object.assign({},t,{placement:e})):n,i=s[0],l=s[1];return i=i||0,l=(l||0)*o,[Te,Le].indexOf(r)>=0?{x:l,y:i}:{x:i,y:l}}function vf(e){var t=e.state,n=e.options,r=e.name,o=n.offset,s=o===void 0?[0,0]:o,i=yi.reduce(function(d,m){return d[m]=bf(m,t.rects,s),d},{}),l=i[t.placement],c=l.x,u=l.y;t.modifiersData.popperOffsets!=null&&(t.modifiersData.popperOffsets.x+=c,t.modifiersData.popperOffsets.y+=u),t.modifiersData[r]=i}const xf={name:"offset",enabled:!0,phase:"main",requires:["popperOffsets"],fn:vf};function yf(e){var t=e.state,n=e.name;t.modifiersData[n]=Ti({reference:t.rects.reference,element:t.rects.popper,strategy:"absolute",placement:t.placement})}const Nf={name:"popperOffsets",enabled:!0,phase:"read",fn:yf,data:{}};function kf(e){return e==="x"?"y":"x"}function Sf(e){var t=e.state,n=e.options,r=e.name,o=n.mainAxis,s=o===void 0?!0:o,i=n.altAxis,l=i===void 0?!1:i,c=n.boundary,u=n.rootBoundary,d=n.altBoundary,m=n.padding,w=n.tether,b=w===void 0?!0:w,x=n.tetherOffset,f=x===void 0?0:x,h=kn(t,{boundary:c,rootBoundary:u,padding:m,altBoundary:d}),S=Xe(t.placement),R=qt(t.placement),j=!R,E=Ao(S),v=kf(E),P=t.modifiersData.popperOffsets,V=t.rects.reference,U=t.rects.popper,C=typeof f=="function"?f(Object.assign({},t.rects,{placement:t.placement})):f,_=typeof C=="number"?{mainAxis:C,altAxis:C}:Object.assign({mainAxis:0,altAxis:0},C),k=t.modifiersData.offset?t.modifiersData.offset[t.placement]:null,D={x:0,y:0};if(P){if(s){var $,J=E==="y"?Ce:Te,Y=E==="y"?ze:Le,F=E==="y"?"height":"width",te=P[E],se=te+h[J],oe=te-h[Y],y=b?-U[F]/2:0,T=R===Ft?V[F]:U[F],z=R===Ft?-U[F]:-V[F],L=t.elements.arrow,B=b&&L?Do(L):{width:0,height:0},X=t.modifiersData["arrow#persistent"]?t.modifiersData["arrow#persistent"].padding:Si(),q=X[J],H=X[Y],G=hn(0,V[F],B[F]),K=j?V[F]/2-y-G-q-_.mainAxis:T-G-q-_.mainAxis,Z=j?-V[F]/2+y+G+H+_.mainAxis:z+G+H+_.mainAxis,ue=t.elements.arrow&&$n(t.elements.arrow),I=ue?E==="y"?ue.clientTop||0:ue.clientLeft||0:0,ye=($=k==null?void 0:k[E])!=null?$:0,A=te+K-ye-I,xe=te+Z-ye,Ge=hn(b?er(se,A):se,te,b?ht(oe,xe):oe);P[E]=Ge,D[E]=Ge-te}if(l){var lt,Ee=E==="x"?Ce:Te,Dn=E==="x"?ze:Le,Ue=P[v],Et=v==="y"?"height":"width",ct=Ue+h[Ee],jt=Ue-h[Dn],Ct=[Ce,Te].indexOf(S)!==-1,Tt=(lt=k==null?void 0:k[v])!=null?lt:0,dt=Ct?ct:Ue-V[Et]-U[Et]-Tt+_.altAxis,Jt=Ct?Ue+V[Et]+U[Et]-Tt-_.altAxis:jt,An=b&&Ct?Xw(dt,Ue,Jt):hn(b?dt:ct,Ue,b?Jt:jt);P[v]=An,D[v]=An-Ue}t.modifiersData[r]=D}}const Ef={name:"preventOverflow",enabled:!0,phase:"main",fn:Sf,requiresIfExists:["offset"]};function jf(e){return{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}}function Cf(e){return e===$e(e)||!Ve(e)?Bo(e):jf(e)}function Tf(e){var t=e.getBoundingClientRect(),n=Gt(t.width)/e.offsetWidth||1,r=Gt(t.height)/e.offsetHeight||1;return n!==1||r!==1}function Rf(e,t,n){n===void 0&&(n=!1);var r=Ve(t),o=Ve(t)&&Tf(t),s=it(t),i=Ut(e,o,n),l={scrollLeft:0,scrollTop:0},c={x:0,y:0};return(r||!r&&!n)&&((We(t)!=="body"||zo(s))&&(l=Cf(t)),Ve(t)?(c=Ut(t,!0),c.x+=t.clientLeft,c.y+=t.clientTop):s&&(c.x=Vo(s))),{x:i.left+l.scrollLeft-c.x,y:i.top+l.scrollTop-c.y,width:i.width,height:i.height}}function Of(e){var t=new Map,n=new Set,r=[];e.forEach(function(s){t.set(s.name,s)});function o(s){n.add(s.name);var i=[].concat(s.requires||[],s.requiresIfExists||[]);i.forEach(function(l){if(!n.has(l)){var c=t.get(l);c&&o(c)}}),r.push(s)}return e.forEach(function(s){n.has(s.name)||o(s)}),r}function _f(e){var t=Of(e);return Lw.reduce(function(n,r){return n.concat(t.filter(function(o){return o.phase===r}))},[])}function Pf(e){var t;return function(){return t||(t=new Promise(function(n){Promise.resolve().then(function(){t=void 0,n(e())})})),t}}function If(e){var t=e.reduce(function(n,r){var o=n[r.name];return n[r.name]=o?Object.assign({},o,r,{options:Object.assign({},o.options,r.options),data:Object.assign({},o.data,r.data)}):r,n},{});return Object.keys(t).map(function(n){return t[n]})}var qa={placement:"bottom",modifiers:[],strategy:"absolute"};function Ha(){for(var e=arguments.length,t=new Array(e),n=0;nko({root:["root"]},xw(Af)),Gf={},Uf=M.forwardRef(function(t,n){var r;const{anchorEl:o,children:s,direction:i,disablePortal:l,modifiers:c,open:u,placement:d,popperOptions:m,popperRef:w,slotProps:b={},slots:x={},TransitionProps:f}=t,h=Ne(t,Bf),S=M.useRef(null),R=yt(S,n),j=M.useRef(null),E=yt(j,w),v=M.useRef(E);Lt(()=>{v.current=E},[E]),M.useImperativeHandle(w,()=>j.current,[]);const P=zf(d,i),[V,U]=M.useState(P),[C,_]=M.useState(tr(o));M.useEffect(()=>{j.current&&j.current.forceUpdate()}),M.useEffect(()=>{o&&_(tr(o))},[o]),Lt(()=>{if(!C||!u)return;const Y=se=>{U(se.placement)};if(process.env.NODE_ENV!=="production"&&C&&Nr(C)&&C.nodeType===1){const se=C.getBoundingClientRect();process.env.NODE_ENV!=="test"&&se.top===0&&se.left===0&&se.right===0&&se.bottom===0&&console.warn(["MUI: The `anchorEl` prop provided to the component is invalid.","The anchor element should be part of the document layout.","Make sure the element is present in the document or that it's not display none."].join(` -`))}let F=[{name:"preventOverflow",options:{altBoundary:l}},{name:"flip",options:{altBoundary:l}},{name:"onUpdate",enabled:!0,phase:"afterWrite",fn:({state:se})=>{Y(se)}}];c!=null&&(F=F.concat(c)),m&&m.modifiers!=null&&(F=F.concat(m.modifiers));const te=Df(C,S.current,O({placement:P},m,{modifiers:F}));return v.current(te),()=>{te.destroy(),v.current(null)}},[C,l,c,u,m,P]);const k={placement:V};f!==null&&(k.TransitionProps=f);const D=Ff(),$=(r=x.root)!=null?r:"div",J=Ew({elementType:$,externalSlotProps:b.root,externalForwardedProps:h,additionalProps:{role:"tooltip",ref:R},ownerState:t,className:D.root});return a.jsx($,O({},J,{children:typeof s=="function"?s(k):s}))}),Oi=M.forwardRef(function(t,n){const{anchorEl:r,children:o,container:s,direction:i="ltr",disablePortal:l=!1,keepMounted:c=!1,modifiers:u,open:d,placement:m="bottom",popperOptions:w=Gf,popperRef:b,style:x,transition:f=!1,slotProps:h={},slots:S={}}=t,R=Ne(t,Vf),[j,E]=M.useState(!0),v=()=>{E(!1)},P=()=>{E(!0)};if(!c&&!d&&(!f||j))return null;let V;if(s)V=s;else if(r){const _=tr(r);V=_&&Nr(_)?Kn(_).body:Kn(null).body}const U=!d&&c&&(!f||j)?"none":void 0,C=f?{in:d,onEnter:v,onExited:P}:void 0;return a.jsx(Qn,{disablePortal:l,container:V,children:a.jsx(Uf,O({anchorEl:r,direction:i,disablePortal:l,modifiers:u,ref:n,open:f?!j:d,placement:m,popperOptions:w,popperRef:b,slotProps:h,slots:S},R,{style:O({position:"fixed",top:0,left:0,display:U},x),TransitionProps:C,children:o}))})});process.env.NODE_ENV!=="production"&&(Oi.propTypes={anchorEl:yo(p.oneOfType([xn,p.object,p.func]),e=>{if(e.open){const t=tr(e.anchorEl);if(t&&Nr(t)&&t.nodeType===1){const n=t.getBoundingClientRect();if(process.env.NODE_ENV!=="test"&&n.top===0&&n.left===0&&n.right===0&&n.bottom===0)return new Error(["MUI: The `anchorEl` prop provided to the component is invalid.","The anchor element should be part of the document layout.","Make sure the element is present in the document or that it's not display none."].join(` +} });`:zt(12,h?` (${h})`:"",JSON.stringify(m.main)));return _a(m,"light",R,r),_a(m,"dark",j,r),m.contrastText||(m.contrastText=f(m.main)),m},b={dark:zr,light:Oa};return process.env.NODE_ENV!=="production"&&(b[t]||console.error(`MUI: The palette mode \`${t}\` is not supported.`)),Qe(O({common:O({},yn),mode:t,primary:w({color:s,name:"primary"}),secondary:w({color:i,name:"secondary",mainShade:"A400",lightShade:"A200",darkShade:"A700"}),error:w({color:l,name:"error"}),warning:w({color:u,name:"warning"}),info:w({color:c,name:"info"}),success:w({color:d,name:"success"}),grey:Ep,contrastThreshold:n,getContrastText:f,augmentColor:w,tonalOffset:r},b[t]),o)}const zp=["fontFamily","fontSize","fontWeightLight","fontWeightRegular","fontWeightMedium","fontWeightBold","htmlFontSize","allVariants","pxToRem"];function Lp(e){return Math.round(e*1e5)/1e5}const Pa={textTransform:"uppercase"},Ia='"Roboto", "Helvetica", "Arial", sans-serif';function Fp(e,t){const n=typeof t=="function"?t(e):t,{fontFamily:r=Ia,fontSize:o=14,fontWeightLight:s=300,fontWeightRegular:i=400,fontWeightMedium:l=500,fontWeightBold:c=700,htmlFontSize:d=16,allVariants:u,pxToRem:f}=n,w=Ne(n,zp);process.env.NODE_ENV!=="production"&&(typeof o!="number"&&console.error("MUI: `fontSize` is required to be a number."),typeof d!="number"&&console.error("MUI: `htmlFontSize` is required to be a number."));const b=o/14,x=f||(S=>`${S/d*b}rem`),m=(S,R,j,E,v)=>O({fontFamily:r,fontWeight:S,fontSize:x(R),lineHeight:j},r===Ia?{letterSpacing:`${Lp(E/R)}em`}:{},v,u),h={h1:m(s,96,1.167,-1.5),h2:m(s,60,1.2,-.5),h3:m(i,48,1.167,0),h4:m(i,34,1.235,.25),h5:m(i,24,1.334,0),h6:m(l,20,1.6,.15),subtitle1:m(i,16,1.75,.15),subtitle2:m(l,14,1.57,.1),body1:m(i,16,1.5,.15),body2:m(i,14,1.43,.15),button:m(l,14,1.75,.4,Pa),caption:m(i,12,1.66,.4),overline:m(i,12,2.66,1,Pa),inherit:{fontFamily:"inherit",fontWeight:"inherit",fontSize:"inherit",lineHeight:"inherit",letterSpacing:"inherit"}};return Qe(O({htmlFontSize:d,pxToRem:x,fontFamily:r,fontSize:o,fontWeightLight:s,fontWeightRegular:i,fontWeightMedium:l,fontWeightBold:c},h),w,{clone:!1})}const Gp=.2,Up=.14,qp=.12;function we(...e){return[`${e[0]}px ${e[1]}px ${e[2]}px ${e[3]}px rgba(0,0,0,${Gp})`,`${e[4]}px ${e[5]}px ${e[6]}px ${e[7]}px rgba(0,0,0,${Up})`,`${e[8]}px ${e[9]}px ${e[10]}px ${e[11]}px rgba(0,0,0,${qp})`].join(",")}const Hp=["none",we(0,2,1,-1,0,1,1,0,0,1,3,0),we(0,3,1,-2,0,2,2,0,0,1,5,0),we(0,3,3,-2,0,3,4,0,0,1,8,0),we(0,2,4,-1,0,4,5,0,0,1,10,0),we(0,3,5,-1,0,5,8,0,0,1,14,0),we(0,3,5,-1,0,6,10,0,0,1,18,0),we(0,4,5,-2,0,7,10,1,0,2,16,1),we(0,5,5,-3,0,8,10,1,0,3,14,2),we(0,5,6,-3,0,9,12,1,0,3,16,2),we(0,6,6,-3,0,10,14,1,0,4,18,3),we(0,6,7,-4,0,11,15,1,0,4,20,3),we(0,7,8,-4,0,12,17,2,0,5,22,4),we(0,7,8,-4,0,13,19,2,0,5,24,4),we(0,7,9,-4,0,14,21,2,0,5,26,4),we(0,8,9,-5,0,15,22,2,0,6,28,5),we(0,8,10,-5,0,16,24,2,0,6,30,5),we(0,8,11,-5,0,17,26,2,0,6,32,5),we(0,9,11,-5,0,18,28,2,0,7,34,6),we(0,9,12,-6,0,19,29,2,0,7,36,6),we(0,10,13,-6,0,20,31,3,0,8,38,7),we(0,10,13,-6,0,21,33,3,0,8,40,7),we(0,10,14,-6,0,22,35,3,0,8,42,7),we(0,11,14,-7,0,23,36,3,0,9,44,8),we(0,11,15,-7,0,24,38,3,0,9,46,8)],Xp=Hp,Yp=["duration","easing","delay"],Wp={easeInOut:"cubic-bezier(0.4, 0, 0.2, 1)",easeOut:"cubic-bezier(0.0, 0, 0.2, 1)",easeIn:"cubic-bezier(0.4, 0, 1, 1)",sharp:"cubic-bezier(0.4, 0, 0.6, 1)"},Kp={shortest:150,shorter:200,short:250,standard:300,complex:375,enteringScreen:225,leavingScreen:195};function Ma(e){return`${Math.round(e)}ms`}function Jp(e){if(!e)return 0;const t=e/36;return Math.round((4+15*t**.25+t/5)*10)}function Zp(e){const t=O({},Wp,e.easing),n=O({},Kp,e.duration);return O({getAutoHeightDuration:Jp,create:(o=["all"],s={})=>{const{duration:i=n.standard,easing:l=t.easeInOut,delay:c=0}=s,d=Ne(s,Yp);if(process.env.NODE_ENV!=="production"){const u=w=>typeof w=="string",f=w=>!isNaN(parseFloat(w));!u(o)&&!Array.isArray(o)&&console.error('MUI: Argument "props" must be a string or Array.'),!f(i)&&!u(i)&&console.error(`MUI: Argument "duration" must be a number or a string but found ${i}.`),u(l)||console.error('MUI: Argument "easing" must be a string.'),!f(c)&&!u(c)&&console.error('MUI: Argument "delay" must be a number or a string.'),typeof s!="object"&&console.error(["MUI: Secong argument of transition.create must be an object.","Arguments should be either `create('prop1', options)` or `create(['prop1', 'prop2'], options)`"].join(` +`)),Object.keys(d).length!==0&&console.error(`MUI: Unrecognized argument(s) [${Object.keys(d).join(",")}].`)}return(Array.isArray(o)?o:[o]).map(u=>`${u} ${typeof i=="string"?i:Ma(i)} ${l} ${typeof c=="string"?c:Ma(c)}`).join(",")}},e,{easing:t,duration:n})}const Qp={mobileStepper:1e3,fab:1050,speedDial:1050,appBar:1100,drawer:1200,modal:1300,snackbar:1400,tooltip:1500},ew=Qp,tw=["breakpoints","mixins","spacing","palette","transitions","typography","shape"];function nw(e={},...t){const{mixins:n={},palette:r={},transitions:o={},typography:s={}}=e,i=Ne(e,tw);if(e.vars)throw new Error(process.env.NODE_ENV!=="production"?"MUI: `vars` is a private field used for CSS variables support.\nPlease use another name.":zt(18));const l=Vp(r),c=To(e);let d=Qe(c,{mixins:Np(c.breakpoints,n),palette:l,shadows:Xp.slice(),typography:Fp(l,s),transitions:Zp(o),zIndex:O({},ew)});if(d=Qe(d,i),d=t.reduce((u,f)=>Qe(u,f),d),process.env.NODE_ENV!=="production"){const u=["active","checked","completed","disabled","error","expanded","focused","focusVisible","required","selected"],f=(w,b)=>{let x;for(x in w){const m=w[x];if(u.indexOf(x)!==-1&&Object.keys(m).length>0){if(process.env.NODE_ENV!=="production"){const h=ur("",x);console.error([`MUI: The \`${b}\` component increases the CSS specificity of the \`${x}\` internal state.`,"You can not override it like this: ",JSON.stringify(w,null,2),"",`Instead, you need to use the '&.${h}' syntax:`,JSON.stringify({root:{[`&.${h}`]:m}},null,2),"","https://mui.com/r/state-classes-guide"].join(` +`))}w[x]={}}}};Object.keys(d.components).forEach(w=>{const b=d.components[w].styleOverrides;b&&w.indexOf("Mui")===0&&f(b,w)})}return d.unstable_sxConfig=O({},jo,i==null?void 0:i.unstable_sxConfig),d.unstable_sx=function(f){return Co({sx:f,theme:this})},d}const rw=nw(),Oo=rw,_o="$$material";function Po({props:e,name:t}){return gp({props:e,name:t,defaultTheme:Oo,themeId:_o})}const ow=e=>qn(e)&&e!=="classes",aw=mp({themeId:_o,defaultTheme:Oo,rootShouldForwardProp:ow}),In=aw;function sw(e){return ur("MuiSvgIcon",e)}ci("MuiSvgIcon",["root","colorPrimary","colorSecondary","colorAction","colorError","colorDisabled","fontSizeInherit","fontSizeSmall","fontSizeMedium","fontSizeLarge"]);const iw=["children","className","color","component","fontSize","htmlColor","inheritViewBox","titleAccess","viewBox"],lw=e=>{const{color:t,fontSize:n,classes:r}=e,o={root:["root",t!=="inherit"&&`color${Ye(t)}`,`fontSize${Ye(n)}`]};return ko(o,sw,r)},cw=In("svg",{name:"MuiSvgIcon",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.root,n.color!=="inherit"&&t[`color${Ye(n.color)}`],t[`fontSize${Ye(n.fontSize)}`]]}})(({theme:e,ownerState:t})=>{var n,r,o,s,i,l,c,d,u,f,w,b,x;return{userSelect:"none",width:"1em",height:"1em",display:"inline-block",fill:t.hasSvgAsChild?void 0:"currentColor",flexShrink:0,transition:(n=e.transitions)==null||(r=n.create)==null?void 0:r.call(n,"fill",{duration:(o=e.transitions)==null||(o=o.duration)==null?void 0:o.shorter}),fontSize:{inherit:"inherit",small:((s=e.typography)==null||(i=s.pxToRem)==null?void 0:i.call(s,20))||"1.25rem",medium:((l=e.typography)==null||(c=l.pxToRem)==null?void 0:c.call(l,24))||"1.5rem",large:((d=e.typography)==null||(u=d.pxToRem)==null?void 0:u.call(d,35))||"2.1875rem"}[t.fontSize],color:(f=(w=(e.vars||e).palette)==null||(w=w[t.color])==null?void 0:w.main)!=null?f:{action:(b=(e.vars||e).palette)==null||(b=b.action)==null?void 0:b.active,disabled:(x=(e.vars||e).palette)==null||(x=x.action)==null?void 0:x.disabled,inherit:void 0}[t.color]}}),Io=M.forwardRef(function(t,n){const r=Po({props:t,name:"MuiSvgIcon"}),{children:o,className:s,color:i="inherit",component:l="svg",fontSize:c="medium",htmlColor:d,inheritViewBox:u=!1,titleAccess:f,viewBox:w="0 0 24 24"}=r,b=Ne(r,iw),x=M.isValidElement(o)&&o.type==="svg",m=O({},r,{color:i,component:l,fontSize:c,instanceFontSize:t.fontSize,inheritViewBox:u,viewBox:w,hasSvgAsChild:x}),h={};u||(h.viewBox=w);const S=lw(m);return a.jsxs(cw,O({as:l,className:ot(S.root,s),focusable:"false",color:d,"aria-hidden":f?void 0:!0,role:f?"img":void 0,ref:n},h,b,x&&o.props,{ownerState:m,children:[x?o.props.children:o,f?a.jsx("title",{children:f}):null]}))});process.env.NODE_ENV!=="production"&&(Io.propTypes={children:p.node,classes:p.object,className:p.string,color:p.oneOfType([p.oneOf(["inherit","action","disabled","primary","secondary","error","info","success","warning"]),p.string]),component:p.elementType,fontSize:p.oneOfType([p.oneOf(["inherit","large","medium","small"]),p.string]),htmlColor:p.string,inheritViewBox:p.bool,shapeRendering:p.string,sx:p.oneOfType([p.arrayOf(p.oneOfType([p.func,p.object,p.bool])),p.func,p.object]),titleAccess:p.string,viewBox:p.string});Io.muiName="SvgIcon";const $a=Io;function hi(e,t){function n(r,o){return a.jsx($a,O({"data-testid":`${t}Icon`,ref:o},r,{children:e}))}return process.env.NODE_ENV!=="production"&&(n.displayName=`${t}Icon`),n.muiName=$a.muiName,M.memo(M.forwardRef(n))}const dw={configure:e=>{process.env.NODE_ENV!=="production"&&console.warn(["MUI: `ClassNameGenerator` import from `@mui/material/utils` is outdated and might cause unexpected issues.","","You should use `import { unstable_ClassNameGenerator } from '@mui/material/className'` instead","","The detail of the issue: https://github.com/mui/material-ui/issues/30011#issuecomment-1024993401","","The updated documentation: https://mui.com/guides/classname-generator/"].join(` +`)),ii.configure(e)}},uw=Object.freeze(Object.defineProperty({__proto__:null,capitalize:Ye,createChainedFunction:zd,createSvgIcon:hi,debounce:Ld,deprecatedPropType:Fd,isMuiElement:Gd,ownerDocument:Kn,ownerWindow:Ud,requirePropFactory:qd,setRef:Jn,unstable_ClassNameGenerator:dw,unstable_useEnhancedEffect:Lt,unstable_useId:ri,unsupportedProp:Yd,useControlled:oi,useEventCallback:Zr,useForkRef:yt,useIsFocusVisible:ai},Symbol.toStringTag,{value:"Module"})),pw=xd(uw);var Da;function ww(){return Da||(Da=1,function(e){"use client";Object.defineProperty(e,"__esModule",{value:!0}),Object.defineProperty(e,"default",{enumerable:!0,get:function(){return t.createSvgIcon}});var t=pw}(Pr)),Pr}var fw=yd;Object.defineProperty(xo,"__esModule",{value:!0});var gi=xo.default=void 0,mw=fw(ww()),hw=a;gi=xo.default=(0,mw.default)((0,hw.jsx)("path",{d:"m10 17 5-5-5-5z"}),"ArrowRight");function gw(e){return typeof e=="string"}function un(e,t,n){return e===void 0||gw(e)?t:O({},t,{ownerState:O({},t.ownerState,n)})}const bw={disableDefaultClasses:!1},vw=M.createContext(bw);function xw(e){const{disableDefaultClasses:t}=M.useContext(vw);return n=>t?"":e(n)}function yw(e,t=[]){if(e===void 0)return{};const n={};return Object.keys(e).filter(r=>r.match(/^on[A-Z]/)&&typeof e[r]=="function"&&!t.includes(r)).forEach(r=>{n[r]=e[r]}),n}function Nw(e,t,n){return typeof e=="function"?e(t,n):e}function Aa(e){if(e===void 0)return{};const t={};return Object.keys(e).filter(n=>!(n.match(/^on[A-Z]/)&&typeof e[n]=="function")).forEach(n=>{t[n]=e[n]}),t}function kw(e){const{getSlotProps:t,additionalProps:n,externalSlotProps:r,externalForwardedProps:o,className:s}=e;if(!t){const b=ot(n==null?void 0:n.className,s,o==null?void 0:o.className,r==null?void 0:r.className),x=O({},n==null?void 0:n.style,o==null?void 0:o.style,r==null?void 0:r.style),m=O({},n,o,r);return b.length>0&&(m.className=b),Object.keys(x).length>0&&(m.style=x),{props:m,internalRef:void 0}}const i=yw(O({},o,r)),l=Aa(r),c=Aa(o),d=t(i),u=ot(d==null?void 0:d.className,n==null?void 0:n.className,s,o==null?void 0:o.className,r==null?void 0:r.className),f=O({},d==null?void 0:d.style,n==null?void 0:n.style,o==null?void 0:o.style,r==null?void 0:r.style),w=O({},d,n,c,l);return u.length>0&&(w.className=u),Object.keys(f).length>0&&(w.style=f),{props:w,internalRef:d.ref}}const Sw=["elementType","externalSlotProps","ownerState","skipResolvingSlotProps"];function Ew(e){var t;const{elementType:n,externalSlotProps:r,ownerState:o,skipResolvingSlotProps:s=!1}=e,i=Ne(e,Sw),l=s?{}:Nw(r,o),{props:c,internalRef:d}=kw(O({},i,{externalSlotProps:l})),u=yt(d,l==null?void 0:l.ref,(t=e.additionalProps)==null?void 0:t.ref);return un(n,O({},c,{ref:u}),o)}const bi="base";function jw(e){return`${bi}--${e}`}function Cw(e,t){return`${bi}-${e}-${t}`}function vi(e,t){const n=li[t];return n?jw(n):Cw(e,t)}function Tw(e,t){const n={};return t.forEach(r=>{n[r]=vi(e,r)}),n}function Rw(e){return typeof e=="function"?e():e}const Qn=M.forwardRef(function(t,n){const{children:r,container:o,disablePortal:s=!1}=t,[i,l]=M.useState(null),c=yt(M.isValidElement(r)?r.ref:null,n);if(Lt(()=>{s||l(Rw(o)||document.body)},[o,s]),Lt(()=>{if(i&&!s)return Jn(n,i),()=>{Jn(n,null)}},[n,i,s]),s){if(M.isValidElement(r)){const d={ref:c};return M.cloneElement(r,d)}return a.jsx(M.Fragment,{children:r})}return a.jsx(M.Fragment,{children:i&&Ol.createPortal(r,i)})});process.env.NODE_ENV!=="production"&&(Qn.propTypes={children:p.node,container:p.oneOfType([xn,p.func]),disablePortal:p.bool});process.env.NODE_ENV!=="production"&&(Qn["propTypes"]=Id(Qn.propTypes));var Ce="top",ze="bottom",Le="right",Te="left",Mo="auto",Mn=[Ce,ze,Le,Te],Ft="start",Nn="end",Ow="clippingParents",xi="viewport",an="popper",_w="reference",Ba=Mn.reduce(function(e,t){return e.concat([t+"-"+Ft,t+"-"+Nn])},[]),yi=[].concat(Mn,[Mo]).reduce(function(e,t){return e.concat([t,t+"-"+Ft,t+"-"+Nn])},[]),Pw="beforeRead",Iw="read",Mw="afterRead",$w="beforeMain",Dw="main",Aw="afterMain",Bw="beforeWrite",Vw="write",zw="afterWrite",Lw=[Pw,Iw,Mw,$w,Dw,Aw,Bw,Vw,zw];function We(e){return e?(e.nodeName||"").toLowerCase():null}function $e(e){if(e==null)return window;if(e.toString()!=="[object Window]"){var t=e.ownerDocument;return t&&t.defaultView||window}return e}function kt(e){var t=$e(e).Element;return e instanceof t||e instanceof Element}function Ve(e){var t=$e(e).HTMLElement;return e instanceof t||e instanceof HTMLElement}function $o(e){if(typeof ShadowRoot>"u")return!1;var t=$e(e).ShadowRoot;return e instanceof t||e instanceof ShadowRoot}function Fw(e){var t=e.state;Object.keys(t.elements).forEach(function(n){var r=t.styles[n]||{},o=t.attributes[n]||{},s=t.elements[n];!Ve(s)||!We(s)||(Object.assign(s.style,r),Object.keys(o).forEach(function(i){var l=o[i];l===!1?s.removeAttribute(i):s.setAttribute(i,l===!0?"":l)}))})}function Gw(e){var t=e.state,n={popper:{position:t.options.strategy,left:"0",top:"0",margin:"0"},arrow:{position:"absolute"},reference:{}};return Object.assign(t.elements.popper.style,n.popper),t.styles=n,t.elements.arrow&&Object.assign(t.elements.arrow.style,n.arrow),function(){Object.keys(t.elements).forEach(function(r){var o=t.elements[r],s=t.attributes[r]||{},i=Object.keys(t.styles.hasOwnProperty(r)?t.styles[r]:n[r]),l=i.reduce(function(c,d){return c[d]="",c},{});!Ve(o)||!We(o)||(Object.assign(o.style,l),Object.keys(s).forEach(function(c){o.removeAttribute(c)}))})}}const Uw={name:"applyStyles",enabled:!0,phase:"write",fn:Fw,effect:Gw,requires:["computeStyles"]};function Xe(e){return e.split("-")[0]}var ht=Math.max,er=Math.min,Gt=Math.round;function eo(){var e=navigator.userAgentData;return e!=null&&e.brands&&Array.isArray(e.brands)?e.brands.map(function(t){return t.brand+"/"+t.version}).join(" "):navigator.userAgent}function Ni(){return!/^((?!chrome|android).)*safari/i.test(eo())}function Ut(e,t,n){t===void 0&&(t=!1),n===void 0&&(n=!1);var r=e.getBoundingClientRect(),o=1,s=1;t&&Ve(e)&&(o=e.offsetWidth>0&&Gt(r.width)/e.offsetWidth||1,s=e.offsetHeight>0&&Gt(r.height)/e.offsetHeight||1);var i=kt(e)?$e(e):window,l=i.visualViewport,c=!Ni()&&n,d=(r.left+(c&&l?l.offsetLeft:0))/o,u=(r.top+(c&&l?l.offsetTop:0))/s,f=r.width/o,w=r.height/s;return{width:f,height:w,top:u,right:d+f,bottom:u+w,left:d,x:d,y:u}}function Do(e){var t=Ut(e),n=e.offsetWidth,r=e.offsetHeight;return Math.abs(t.width-n)<=1&&(n=t.width),Math.abs(t.height-r)<=1&&(r=t.height),{x:e.offsetLeft,y:e.offsetTop,width:n,height:r}}function ki(e,t){var n=t.getRootNode&&t.getRootNode();if(e.contains(t))return!0;if(n&&$o(n)){var r=t;do{if(r&&e.isSameNode(r))return!0;r=r.parentNode||r.host}while(r)}return!1}function tt(e){return $e(e).getComputedStyle(e)}function qw(e){return["table","td","th"].indexOf(We(e))>=0}function it(e){return((kt(e)?e.ownerDocument:e.document)||window.document).documentElement}function yr(e){return We(e)==="html"?e:e.assignedSlot||e.parentNode||($o(e)?e.host:null)||it(e)}function Va(e){return!Ve(e)||tt(e).position==="fixed"?null:e.offsetParent}function Hw(e){var t=/firefox/i.test(eo()),n=/Trident/i.test(eo());if(n&&Ve(e)){var r=tt(e);if(r.position==="fixed")return null}var o=yr(e);for($o(o)&&(o=o.host);Ve(o)&&["html","body"].indexOf(We(o))<0;){var s=tt(o);if(s.transform!=="none"||s.perspective!=="none"||s.contain==="paint"||["transform","perspective"].indexOf(s.willChange)!==-1||t&&s.willChange==="filter"||t&&s.filter&&s.filter!=="none")return o;o=o.parentNode}return null}function $n(e){for(var t=$e(e),n=Va(e);n&&qw(n)&&tt(n).position==="static";)n=Va(n);return n&&(We(n)==="html"||We(n)==="body"&&tt(n).position==="static")?t:n||Hw(e)||t}function Ao(e){return["top","bottom"].indexOf(e)>=0?"x":"y"}function hn(e,t,n){return ht(e,er(t,n))}function Xw(e,t,n){var r=hn(e,t,n);return r>n?n:r}function Si(){return{top:0,right:0,bottom:0,left:0}}function Ei(e){return Object.assign({},Si(),e)}function ji(e,t){return t.reduce(function(n,r){return n[r]=e,n},{})}var Yw=function(t,n){return t=typeof t=="function"?t(Object.assign({},n.rects,{placement:n.placement})):t,Ei(typeof t!="number"?t:ji(t,Mn))};function Ww(e){var t,n=e.state,r=e.name,o=e.options,s=n.elements.arrow,i=n.modifiersData.popperOffsets,l=Xe(n.placement),c=Ao(l),d=[Te,Le].indexOf(l)>=0,u=d?"height":"width";if(!(!s||!i)){var f=Yw(o.padding,n),w=Do(s),b=c==="y"?Ce:Te,x=c==="y"?ze:Le,m=n.rects.reference[u]+n.rects.reference[c]-i[c]-n.rects.popper[u],h=i[c]-n.rects.reference[c],S=$n(s),R=S?c==="y"?S.clientHeight||0:S.clientWidth||0:0,j=m/2-h/2,E=f[b],v=R-w[u]-f[x],P=R/2-w[u]/2+j,V=hn(E,P,v),U=c;n.modifiersData[r]=(t={},t[U]=V,t.centerOffset=V-P,t)}}function Kw(e){var t=e.state,n=e.options,r=n.element,o=r===void 0?"[data-popper-arrow]":r;o!=null&&(typeof o=="string"&&(o=t.elements.popper.querySelector(o),!o)||ki(t.elements.popper,o)&&(t.elements.arrow=o))}const Jw={name:"arrow",enabled:!0,phase:"main",fn:Ww,effect:Kw,requires:["popperOffsets"],requiresIfExists:["preventOverflow"]};function qt(e){return e.split("-")[1]}var Zw={top:"auto",right:"auto",bottom:"auto",left:"auto"};function Qw(e,t){var n=e.x,r=e.y,o=t.devicePixelRatio||1;return{x:Gt(n*o)/o||0,y:Gt(r*o)/o||0}}function za(e){var t,n=e.popper,r=e.popperRect,o=e.placement,s=e.variation,i=e.offsets,l=e.position,c=e.gpuAcceleration,d=e.adaptive,u=e.roundOffsets,f=e.isFixed,w=i.x,b=w===void 0?0:w,x=i.y,m=x===void 0?0:x,h=typeof u=="function"?u({x:b,y:m}):{x:b,y:m};b=h.x,m=h.y;var S=i.hasOwnProperty("x"),R=i.hasOwnProperty("y"),j=Te,E=Ce,v=window;if(d){var P=$n(n),V="clientHeight",U="clientWidth";if(P===$e(n)&&(P=it(n),tt(P).position!=="static"&&l==="absolute"&&(V="scrollHeight",U="scrollWidth")),P=P,o===Ce||(o===Te||o===Le)&&s===Nn){E=ze;var C=f&&P===v&&v.visualViewport?v.visualViewport.height:P[V];m-=C-r.height,m*=c?1:-1}if(o===Te||(o===Ce||o===ze)&&s===Nn){j=Le;var _=f&&P===v&&v.visualViewport?v.visualViewport.width:P[U];b-=_-r.width,b*=c?1:-1}}var k=Object.assign({position:l},d&&Zw),D=u===!0?Qw({x:b,y:m},$e(n)):{x:b,y:m};if(b=D.x,m=D.y,c){var $;return Object.assign({},k,($={},$[E]=R?"0":"",$[j]=S?"0":"",$.transform=(v.devicePixelRatio||1)<=1?"translate("+b+"px, "+m+"px)":"translate3d("+b+"px, "+m+"px, 0)",$))}return Object.assign({},k,(t={},t[E]=R?m+"px":"",t[j]=S?b+"px":"",t.transform="",t))}function ef(e){var t=e.state,n=e.options,r=n.gpuAcceleration,o=r===void 0?!0:r,s=n.adaptive,i=s===void 0?!0:s,l=n.roundOffsets,c=l===void 0?!0:l,d={placement:Xe(t.placement),variation:qt(t.placement),popper:t.elements.popper,popperRect:t.rects.popper,gpuAcceleration:o,isFixed:t.options.strategy==="fixed"};t.modifiersData.popperOffsets!=null&&(t.styles.popper=Object.assign({},t.styles.popper,za(Object.assign({},d,{offsets:t.modifiersData.popperOffsets,position:t.options.strategy,adaptive:i,roundOffsets:c})))),t.modifiersData.arrow!=null&&(t.styles.arrow=Object.assign({},t.styles.arrow,za(Object.assign({},d,{offsets:t.modifiersData.arrow,position:"absolute",adaptive:!1,roundOffsets:c})))),t.attributes.popper=Object.assign({},t.attributes.popper,{"data-popper-placement":t.placement})}const tf={name:"computeStyles",enabled:!0,phase:"beforeWrite",fn:ef,data:{}};var Fn={passive:!0};function nf(e){var t=e.state,n=e.instance,r=e.options,o=r.scroll,s=o===void 0?!0:o,i=r.resize,l=i===void 0?!0:i,c=$e(t.elements.popper),d=[].concat(t.scrollParents.reference,t.scrollParents.popper);return s&&d.forEach(function(u){u.addEventListener("scroll",n.update,Fn)}),l&&c.addEventListener("resize",n.update,Fn),function(){s&&d.forEach(function(u){u.removeEventListener("scroll",n.update,Fn)}),l&&c.removeEventListener("resize",n.update,Fn)}}const rf={name:"eventListeners",enabled:!0,phase:"write",fn:function(){},effect:nf,data:{}};var of={left:"right",right:"left",bottom:"top",top:"bottom"};function Xn(e){return e.replace(/left|right|bottom|top/g,function(t){return of[t]})}var af={start:"end",end:"start"};function La(e){return e.replace(/start|end/g,function(t){return af[t]})}function Bo(e){var t=$e(e),n=t.pageXOffset,r=t.pageYOffset;return{scrollLeft:n,scrollTop:r}}function Vo(e){return Ut(it(e)).left+Bo(e).scrollLeft}function sf(e,t){var n=$e(e),r=it(e),o=n.visualViewport,s=r.clientWidth,i=r.clientHeight,l=0,c=0;if(o){s=o.width,i=o.height;var d=Ni();(d||!d&&t==="fixed")&&(l=o.offsetLeft,c=o.offsetTop)}return{width:s,height:i,x:l+Vo(e),y:c}}function lf(e){var t,n=it(e),r=Bo(e),o=(t=e.ownerDocument)==null?void 0:t.body,s=ht(n.scrollWidth,n.clientWidth,o?o.scrollWidth:0,o?o.clientWidth:0),i=ht(n.scrollHeight,n.clientHeight,o?o.scrollHeight:0,o?o.clientHeight:0),l=-r.scrollLeft+Vo(e),c=-r.scrollTop;return tt(o||n).direction==="rtl"&&(l+=ht(n.clientWidth,o?o.clientWidth:0)-s),{width:s,height:i,x:l,y:c}}function zo(e){var t=tt(e),n=t.overflow,r=t.overflowX,o=t.overflowY;return/auto|scroll|overlay|hidden/.test(n+o+r)}function Ci(e){return["html","body","#document"].indexOf(We(e))>=0?e.ownerDocument.body:Ve(e)&&zo(e)?e:Ci(yr(e))}function gn(e,t){var n;t===void 0&&(t=[]);var r=Ci(e),o=r===((n=e.ownerDocument)==null?void 0:n.body),s=$e(r),i=o?[s].concat(s.visualViewport||[],zo(r)?r:[]):r,l=t.concat(i);return o?l:l.concat(gn(yr(i)))}function to(e){return Object.assign({},e,{left:e.x,top:e.y,right:e.x+e.width,bottom:e.y+e.height})}function cf(e,t){var n=Ut(e,!1,t==="fixed");return n.top=n.top+e.clientTop,n.left=n.left+e.clientLeft,n.bottom=n.top+e.clientHeight,n.right=n.left+e.clientWidth,n.width=e.clientWidth,n.height=e.clientHeight,n.x=n.left,n.y=n.top,n}function Fa(e,t,n){return t===xi?to(sf(e,n)):kt(t)?cf(t,n):to(lf(it(e)))}function df(e){var t=gn(yr(e)),n=["absolute","fixed"].indexOf(tt(e).position)>=0,r=n&&Ve(e)?$n(e):e;return kt(r)?t.filter(function(o){return kt(o)&&ki(o,r)&&We(o)!=="body"}):[]}function uf(e,t,n,r){var o=t==="clippingParents"?df(e):[].concat(t),s=[].concat(o,[n]),i=s[0],l=s.reduce(function(c,d){var u=Fa(e,d,r);return c.top=ht(u.top,c.top),c.right=er(u.right,c.right),c.bottom=er(u.bottom,c.bottom),c.left=ht(u.left,c.left),c},Fa(e,i,r));return l.width=l.right-l.left,l.height=l.bottom-l.top,l.x=l.left,l.y=l.top,l}function Ti(e){var t=e.reference,n=e.element,r=e.placement,o=r?Xe(r):null,s=r?qt(r):null,i=t.x+t.width/2-n.width/2,l=t.y+t.height/2-n.height/2,c;switch(o){case Ce:c={x:i,y:t.y-n.height};break;case ze:c={x:i,y:t.y+t.height};break;case Le:c={x:t.x+t.width,y:l};break;case Te:c={x:t.x-n.width,y:l};break;default:c={x:t.x,y:t.y}}var d=o?Ao(o):null;if(d!=null){var u=d==="y"?"height":"width";switch(s){case Ft:c[d]=c[d]-(t[u]/2-n[u]/2);break;case Nn:c[d]=c[d]+(t[u]/2-n[u]/2);break}}return c}function kn(e,t){t===void 0&&(t={});var n=t,r=n.placement,o=r===void 0?e.placement:r,s=n.strategy,i=s===void 0?e.strategy:s,l=n.boundary,c=l===void 0?Ow:l,d=n.rootBoundary,u=d===void 0?xi:d,f=n.elementContext,w=f===void 0?an:f,b=n.altBoundary,x=b===void 0?!1:b,m=n.padding,h=m===void 0?0:m,S=Ei(typeof h!="number"?h:ji(h,Mn)),R=w===an?_w:an,j=e.rects.popper,E=e.elements[x?R:w],v=uf(kt(E)?E:E.contextElement||it(e.elements.popper),c,u,i),P=Ut(e.elements.reference),V=Ti({reference:P,element:j,strategy:"absolute",placement:o}),U=to(Object.assign({},j,V)),C=w===an?U:P,_={top:v.top-C.top+S.top,bottom:C.bottom-v.bottom+S.bottom,left:v.left-C.left+S.left,right:C.right-v.right+S.right},k=e.modifiersData.offset;if(w===an&&k){var D=k[o];Object.keys(_).forEach(function($){var J=[Le,ze].indexOf($)>=0?1:-1,Y=[Ce,ze].indexOf($)>=0?"y":"x";_[$]+=D[Y]*J})}return _}function pf(e,t){t===void 0&&(t={});var n=t,r=n.placement,o=n.boundary,s=n.rootBoundary,i=n.padding,l=n.flipVariations,c=n.allowedAutoPlacements,d=c===void 0?yi:c,u=qt(r),f=u?l?Ba:Ba.filter(function(x){return qt(x)===u}):Mn,w=f.filter(function(x){return d.indexOf(x)>=0});w.length===0&&(w=f);var b=w.reduce(function(x,m){return x[m]=kn(e,{placement:m,boundary:o,rootBoundary:s,padding:i})[Xe(m)],x},{});return Object.keys(b).sort(function(x,m){return b[x]-b[m]})}function wf(e){if(Xe(e)===Mo)return[];var t=Xn(e);return[La(e),t,La(t)]}function ff(e){var t=e.state,n=e.options,r=e.name;if(!t.modifiersData[r]._skip){for(var o=n.mainAxis,s=o===void 0?!0:o,i=n.altAxis,l=i===void 0?!0:i,c=n.fallbackPlacements,d=n.padding,u=n.boundary,f=n.rootBoundary,w=n.altBoundary,b=n.flipVariations,x=b===void 0?!0:b,m=n.allowedAutoPlacements,h=t.options.placement,S=Xe(h),R=S===h,j=c||(R||!x?[Xn(h)]:wf(h)),E=[h].concat(j).reduce(function(B,X){return B.concat(Xe(X)===Mo?pf(t,{placement:X,boundary:u,rootBoundary:f,padding:d,flipVariations:x,allowedAutoPlacements:m}):X)},[]),v=t.rects.reference,P=t.rects.popper,V=new Map,U=!0,C=E[0],_=0;_=0,Y=J?"width":"height",F=kn(t,{placement:k,boundary:u,rootBoundary:f,altBoundary:w,padding:d}),te=J?$?Le:Te:$?ze:Ce;v[Y]>P[Y]&&(te=Xn(te));var se=Xn(te),oe=[];if(s&&oe.push(F[D]<=0),l&&oe.push(F[te]<=0,F[se]<=0),oe.every(function(B){return B})){C=k,U=!1;break}V.set(k,oe)}if(U)for(var y=x?3:1,T=function(X){var q=E.find(function(H){var G=V.get(H);if(G)return G.slice(0,X).every(function(K){return K})});if(q)return C=q,"break"},z=y;z>0;z--){var L=T(z);if(L==="break")break}t.placement!==C&&(t.modifiersData[r]._skip=!0,t.placement=C,t.reset=!0)}}const mf={name:"flip",enabled:!0,phase:"main",fn:ff,requiresIfExists:["offset"],data:{_skip:!1}};function Ga(e,t,n){return n===void 0&&(n={x:0,y:0}),{top:e.top-t.height-n.y,right:e.right-t.width+n.x,bottom:e.bottom-t.height+n.y,left:e.left-t.width-n.x}}function Ua(e){return[Ce,Le,ze,Te].some(function(t){return e[t]>=0})}function hf(e){var t=e.state,n=e.name,r=t.rects.reference,o=t.rects.popper,s=t.modifiersData.preventOverflow,i=kn(t,{elementContext:"reference"}),l=kn(t,{altBoundary:!0}),c=Ga(i,r),d=Ga(l,o,s),u=Ua(c),f=Ua(d);t.modifiersData[n]={referenceClippingOffsets:c,popperEscapeOffsets:d,isReferenceHidden:u,hasPopperEscaped:f},t.attributes.popper=Object.assign({},t.attributes.popper,{"data-popper-reference-hidden":u,"data-popper-escaped":f})}const gf={name:"hide",enabled:!0,phase:"main",requiresIfExists:["preventOverflow"],fn:hf};function bf(e,t,n){var r=Xe(e),o=[Te,Ce].indexOf(r)>=0?-1:1,s=typeof n=="function"?n(Object.assign({},t,{placement:e})):n,i=s[0],l=s[1];return i=i||0,l=(l||0)*o,[Te,Le].indexOf(r)>=0?{x:l,y:i}:{x:i,y:l}}function vf(e){var t=e.state,n=e.options,r=e.name,o=n.offset,s=o===void 0?[0,0]:o,i=yi.reduce(function(u,f){return u[f]=bf(f,t.rects,s),u},{}),l=i[t.placement],c=l.x,d=l.y;t.modifiersData.popperOffsets!=null&&(t.modifiersData.popperOffsets.x+=c,t.modifiersData.popperOffsets.y+=d),t.modifiersData[r]=i}const xf={name:"offset",enabled:!0,phase:"main",requires:["popperOffsets"],fn:vf};function yf(e){var t=e.state,n=e.name;t.modifiersData[n]=Ti({reference:t.rects.reference,element:t.rects.popper,strategy:"absolute",placement:t.placement})}const Nf={name:"popperOffsets",enabled:!0,phase:"read",fn:yf,data:{}};function kf(e){return e==="x"?"y":"x"}function Sf(e){var t=e.state,n=e.options,r=e.name,o=n.mainAxis,s=o===void 0?!0:o,i=n.altAxis,l=i===void 0?!1:i,c=n.boundary,d=n.rootBoundary,u=n.altBoundary,f=n.padding,w=n.tether,b=w===void 0?!0:w,x=n.tetherOffset,m=x===void 0?0:x,h=kn(t,{boundary:c,rootBoundary:d,padding:f,altBoundary:u}),S=Xe(t.placement),R=qt(t.placement),j=!R,E=Ao(S),v=kf(E),P=t.modifiersData.popperOffsets,V=t.rects.reference,U=t.rects.popper,C=typeof m=="function"?m(Object.assign({},t.rects,{placement:t.placement})):m,_=typeof C=="number"?{mainAxis:C,altAxis:C}:Object.assign({mainAxis:0,altAxis:0},C),k=t.modifiersData.offset?t.modifiersData.offset[t.placement]:null,D={x:0,y:0};if(P){if(s){var $,J=E==="y"?Ce:Te,Y=E==="y"?ze:Le,F=E==="y"?"height":"width",te=P[E],se=te+h[J],oe=te-h[Y],y=b?-U[F]/2:0,T=R===Ft?V[F]:U[F],z=R===Ft?-U[F]:-V[F],L=t.elements.arrow,B=b&&L?Do(L):{width:0,height:0},X=t.modifiersData["arrow#persistent"]?t.modifiersData["arrow#persistent"].padding:Si(),q=X[J],H=X[Y],G=hn(0,V[F],B[F]),K=j?V[F]/2-y-G-q-_.mainAxis:T-G-q-_.mainAxis,Z=j?-V[F]/2+y+G+H+_.mainAxis:z+G+H+_.mainAxis,ue=t.elements.arrow&&$n(t.elements.arrow),I=ue?E==="y"?ue.clientTop||0:ue.clientLeft||0:0,ye=($=k==null?void 0:k[E])!=null?$:0,A=te+K-ye-I,xe=te+Z-ye,Ge=hn(b?er(se,A):se,te,b?ht(oe,xe):oe);P[E]=Ge,D[E]=Ge-te}if(l){var lt,Ee=E==="x"?Ce:Te,Dn=E==="x"?ze:Le,Ue=P[v],Et=v==="y"?"height":"width",ct=Ue+h[Ee],jt=Ue-h[Dn],Ct=[Ce,Te].indexOf(S)!==-1,Tt=(lt=k==null?void 0:k[v])!=null?lt:0,dt=Ct?ct:Ue-V[Et]-U[Et]-Tt+_.altAxis,Jt=Ct?Ue+V[Et]+U[Et]-Tt-_.altAxis:jt,An=b&&Ct?Xw(dt,Ue,Jt):hn(b?dt:ct,Ue,b?Jt:jt);P[v]=An,D[v]=An-Ue}t.modifiersData[r]=D}}const Ef={name:"preventOverflow",enabled:!0,phase:"main",fn:Sf,requiresIfExists:["offset"]};function jf(e){return{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}}function Cf(e){return e===$e(e)||!Ve(e)?Bo(e):jf(e)}function Tf(e){var t=e.getBoundingClientRect(),n=Gt(t.width)/e.offsetWidth||1,r=Gt(t.height)/e.offsetHeight||1;return n!==1||r!==1}function Rf(e,t,n){n===void 0&&(n=!1);var r=Ve(t),o=Ve(t)&&Tf(t),s=it(t),i=Ut(e,o,n),l={scrollLeft:0,scrollTop:0},c={x:0,y:0};return(r||!r&&!n)&&((We(t)!=="body"||zo(s))&&(l=Cf(t)),Ve(t)?(c=Ut(t,!0),c.x+=t.clientLeft,c.y+=t.clientTop):s&&(c.x=Vo(s))),{x:i.left+l.scrollLeft-c.x,y:i.top+l.scrollTop-c.y,width:i.width,height:i.height}}function Of(e){var t=new Map,n=new Set,r=[];e.forEach(function(s){t.set(s.name,s)});function o(s){n.add(s.name);var i=[].concat(s.requires||[],s.requiresIfExists||[]);i.forEach(function(l){if(!n.has(l)){var c=t.get(l);c&&o(c)}}),r.push(s)}return e.forEach(function(s){n.has(s.name)||o(s)}),r}function _f(e){var t=Of(e);return Lw.reduce(function(n,r){return n.concat(t.filter(function(o){return o.phase===r}))},[])}function Pf(e){var t;return function(){return t||(t=new Promise(function(n){Promise.resolve().then(function(){t=void 0,n(e())})})),t}}function If(e){var t=e.reduce(function(n,r){var o=n[r.name];return n[r.name]=o?Object.assign({},o,r,{options:Object.assign({},o.options,r.options),data:Object.assign({},o.data,r.data)}):r,n},{});return Object.keys(t).map(function(n){return t[n]})}var qa={placement:"bottom",modifiers:[],strategy:"absolute"};function Ha(){for(var e=arguments.length,t=new Array(e),n=0;nko({root:["root"]},xw(Af)),Gf={},Uf=M.forwardRef(function(t,n){var r;const{anchorEl:o,children:s,direction:i,disablePortal:l,modifiers:c,open:d,placement:u,popperOptions:f,popperRef:w,slotProps:b={},slots:x={},TransitionProps:m}=t,h=Ne(t,Bf),S=M.useRef(null),R=yt(S,n),j=M.useRef(null),E=yt(j,w),v=M.useRef(E);Lt(()=>{v.current=E},[E]),M.useImperativeHandle(w,()=>j.current,[]);const P=zf(u,i),[V,U]=M.useState(P),[C,_]=M.useState(tr(o));M.useEffect(()=>{j.current&&j.current.forceUpdate()}),M.useEffect(()=>{o&&_(tr(o))},[o]),Lt(()=>{if(!C||!d)return;const Y=se=>{U(se.placement)};if(process.env.NODE_ENV!=="production"&&C&&Nr(C)&&C.nodeType===1){const se=C.getBoundingClientRect();process.env.NODE_ENV!=="test"&&se.top===0&&se.left===0&&se.right===0&&se.bottom===0&&console.warn(["MUI: The `anchorEl` prop provided to the component is invalid.","The anchor element should be part of the document layout.","Make sure the element is present in the document or that it's not display none."].join(` +`))}let F=[{name:"preventOverflow",options:{altBoundary:l}},{name:"flip",options:{altBoundary:l}},{name:"onUpdate",enabled:!0,phase:"afterWrite",fn:({state:se})=>{Y(se)}}];c!=null&&(F=F.concat(c)),f&&f.modifiers!=null&&(F=F.concat(f.modifiers));const te=Df(C,S.current,O({placement:P},f,{modifiers:F}));return v.current(te),()=>{te.destroy(),v.current(null)}},[C,l,c,d,f,P]);const k={placement:V};m!==null&&(k.TransitionProps=m);const D=Ff(),$=(r=x.root)!=null?r:"div",J=Ew({elementType:$,externalSlotProps:b.root,externalForwardedProps:h,additionalProps:{role:"tooltip",ref:R},ownerState:t,className:D.root});return a.jsx($,O({},J,{children:typeof s=="function"?s(k):s}))}),Oi=M.forwardRef(function(t,n){const{anchorEl:r,children:o,container:s,direction:i="ltr",disablePortal:l=!1,keepMounted:c=!1,modifiers:d,open:u,placement:f="bottom",popperOptions:w=Gf,popperRef:b,style:x,transition:m=!1,slotProps:h={},slots:S={}}=t,R=Ne(t,Vf),[j,E]=M.useState(!0),v=()=>{E(!1)},P=()=>{E(!0)};if(!c&&!u&&(!m||j))return null;let V;if(s)V=s;else if(r){const _=tr(r);V=_&&Nr(_)?Kn(_).body:Kn(null).body}const U=!u&&c&&(!m||j)?"none":void 0,C=m?{in:u,onEnter:v,onExited:P}:void 0;return a.jsx(Qn,{disablePortal:l,container:V,children:a.jsx(Uf,O({anchorEl:r,direction:i,disablePortal:l,modifiers:d,ref:n,open:m?!j:u,placement:f,popperOptions:w,popperRef:b,slotProps:h,slots:S},R,{style:O({position:"fixed",top:0,left:0,display:U},x),TransitionProps:C,children:o}))})});process.env.NODE_ENV!=="production"&&(Oi.propTypes={anchorEl:yo(p.oneOfType([xn,p.object,p.func]),e=>{if(e.open){const t=tr(e.anchorEl);if(t&&Nr(t)&&t.nodeType===1){const n=t.getBoundingClientRect();if(process.env.NODE_ENV!=="test"&&n.top===0&&n.left===0&&n.right===0&&n.bottom===0)return new Error(["MUI: The `anchorEl` prop provided to the component is invalid.","The anchor element should be part of the document layout.","Make sure the element is present in the document or that it's not display none."].join(` `))}else if(!t||typeof t.getBoundingClientRect!="function"||Lf(t)&&t.contextElement!=null&&t.contextElement.nodeType!==1)return new Error(["MUI: The `anchorEl` prop provided to the component is invalid.","It should be an HTML element instance or a virtualElement ","(https://popper.js.org/docs/v2/virtual-elements/)."].join(` -`))}return null}),children:p.oneOfType([p.node,p.func]),container:p.oneOfType([xn,p.func]),direction:p.oneOf(["ltr","rtl"]),disablePortal:p.bool,keepMounted:p.bool,modifiers:p.arrayOf(p.shape({data:p.object,effect:p.func,enabled:p.bool,fn:p.func,name:p.any,options:p.object,phase:p.oneOf(["afterMain","afterRead","afterWrite","beforeMain","beforeRead","beforeWrite","main","read","write"]),requires:p.arrayOf(p.string),requiresIfExists:p.arrayOf(p.string)})),open:p.bool.isRequired,placement:p.oneOf(["auto-end","auto-start","auto","bottom-end","bottom-start","bottom","left-end","left-start","left","right-end","right-start","right","top-end","top-start","top"]),popperOptions:p.shape({modifiers:p.array,onFirstUpdate:p.func,placement:p.oneOf(["auto-end","auto-start","auto","bottom-end","bottom-start","bottom","left-end","left-start","left","right-end","right-start","right","top-end","top-start","top"]),strategy:p.oneOf(["absolute","fixed"])}),popperRef:ni,slotProps:p.shape({root:p.oneOfType([p.func,p.object])}),slots:p.shape({root:p.elementType}),transition:p.bool});function _i(){const e=fi(Oo);return process.env.NODE_ENV!=="production"&&M.useDebugValue(e),e[_o]||e}function no(e,t){return no=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,o){return r.__proto__=o,r},no(e,t)}function qf(e,t){e.prototype=Object.create(t.prototype),e.prototype.constructor=e,no(e,t)}const Xa={disabled:!1};var Hf=process.env.NODE_ENV!=="production"?p.oneOfType([p.number,p.shape({enter:p.number,exit:p.number,appear:p.number}).isRequired]):null;process.env.NODE_ENV!=="production"&&p.oneOfType([p.string,p.shape({enter:p.string,exit:p.string,active:p.string}),p.shape({enter:p.string,enterDone:p.string,enterActive:p.string,exit:p.string,exitDone:p.string,exitActive:p.string})]);const Pi=g.createContext(null);var Xf=function(t){return t.scrollTop},pn="unmounted",wt="exited",ft="entering",$t="entered",ro="exiting",nt=function(e){qf(t,e);function t(r,o){var s;s=e.call(this,r,o)||this;var i=o,l=i&&!i.isMounting?r.enter:r.appear,c;return s.appearStatus=null,r.in?l?(c=wt,s.appearStatus=ft):c=$t:r.unmountOnExit||r.mountOnEnter?c=pn:c=wt,s.state={status:c},s.nextCallback=null,s}t.getDerivedStateFromProps=function(o,s){var i=o.in;return i&&s.status===pn?{status:wt}:null};var n=t.prototype;return n.componentDidMount=function(){this.updateStatus(!0,this.appearStatus)},n.componentDidUpdate=function(o){var s=null;if(o!==this.props){var i=this.state.status;this.props.in?i!==ft&&i!==$t&&(s=ft):(i===ft||i===$t)&&(s=ro)}this.updateStatus(!1,s)},n.componentWillUnmount=function(){this.cancelNextCallback()},n.getTimeouts=function(){var o=this.props.timeout,s,i,l;return s=i=l=o,o!=null&&typeof o!="number"&&(s=o.exit,i=o.enter,l=o.appear!==void 0?o.appear:i),{exit:s,enter:i,appear:l}},n.updateStatus=function(o,s){if(o===void 0&&(o=!1),s!==null)if(this.cancelNextCallback(),s===ft){if(this.props.unmountOnExit||this.props.mountOnEnter){var i=this.props.nodeRef?this.props.nodeRef.current:ln.findDOMNode(this);i&&Xf(i)}this.performEnter(o)}else this.performExit();else this.props.unmountOnExit&&this.state.status===wt&&this.setState({status:pn})},n.performEnter=function(o){var s=this,i=this.props.enter,l=this.context?this.context.isMounting:o,c=this.props.nodeRef?[l]:[ln.findDOMNode(this),l],u=c[0],d=c[1],m=this.getTimeouts(),w=l?m.appear:m.enter;if(!o&&!i||Xa.disabled){this.safeSetState({status:$t},function(){s.props.onEntered(u)});return}this.props.onEnter(u,d),this.safeSetState({status:ft},function(){s.props.onEntering(u,d),s.onTransitionEnd(w,function(){s.safeSetState({status:$t},function(){s.props.onEntered(u,d)})})})},n.performExit=function(){var o=this,s=this.props.exit,i=this.getTimeouts(),l=this.props.nodeRef?void 0:ln.findDOMNode(this);if(!s||Xa.disabled){this.safeSetState({status:wt},function(){o.props.onExited(l)});return}this.props.onExit(l),this.safeSetState({status:ro},function(){o.props.onExiting(l),o.onTransitionEnd(i.exit,function(){o.safeSetState({status:wt},function(){o.props.onExited(l)})})})},n.cancelNextCallback=function(){this.nextCallback!==null&&(this.nextCallback.cancel(),this.nextCallback=null)},n.safeSetState=function(o,s){s=this.setNextCallback(s),this.setState(o,s)},n.setNextCallback=function(o){var s=this,i=!0;return this.nextCallback=function(l){i&&(i=!1,s.nextCallback=null,o(l))},this.nextCallback.cancel=function(){i=!1},this.nextCallback},n.onTransitionEnd=function(o,s){this.setNextCallback(s);var i=this.props.nodeRef?this.props.nodeRef.current:ln.findDOMNode(this),l=o==null&&!this.props.addEndListener;if(!i||l){setTimeout(this.nextCallback,0);return}if(this.props.addEndListener){var c=this.props.nodeRef?[this.nextCallback]:[i,this.nextCallback],u=c[0],d=c[1];this.props.addEndListener(u,d)}o!=null&&setTimeout(this.nextCallback,o)},n.render=function(){var o=this.state.status;if(o===pn)return null;var s=this.props,i=s.children;s.in,s.mountOnEnter,s.unmountOnExit,s.appear,s.enter,s.exit,s.timeout,s.addEndListener,s.onEnter,s.onEntering,s.onEntered,s.onExit,s.onExiting,s.onExited,s.nodeRef;var l=Ne(s,["children","in","mountOnEnter","unmountOnExit","appear","enter","exit","timeout","addEndListener","onEnter","onEntering","onEntered","onExit","onExiting","onExited","nodeRef"]);return g.createElement(Pi.Provider,{value:null},typeof i=="function"?i(o,l):g.cloneElement(g.Children.only(i),l))},t}(g.Component);nt.contextType=Pi;nt.propTypes=process.env.NODE_ENV!=="production"?{nodeRef:p.shape({current:typeof Element>"u"?p.any:function(e,t,n,r,o,s){var i=e[t];return p.instanceOf(i&&"ownerDocument"in i?i.ownerDocument.defaultView.Element:Element)(e,t,n,r,o,s)}}),children:p.oneOfType([p.func.isRequired,p.element.isRequired]).isRequired,in:p.bool,mountOnEnter:p.bool,unmountOnExit:p.bool,appear:p.bool,enter:p.bool,exit:p.bool,timeout:function(t){var n=Hf;t.addEndListener||(n=n.isRequired);for(var r=arguments.length,o=new Array(r>1?r-1:0),s=1;se.scrollTop;function Ya(e,t){var n,r;const{timeout:o,easing:s,style:i={}}=e;return{duration:(n=i.transitionDuration)!=null?n:typeof o=="number"?o:o[t.mode]||0,easing:(r=i.transitionTimingFunction)!=null?r:typeof s=="object"?s[t.mode]:s,delay:i.transitionDelay}}const Kf=["addEndListener","appear","children","easing","in","onEnter","onEntered","onEntering","onExit","onExited","onExiting","style","timeout","TransitionComponent"];function oo(e){return`scale(${e}, ${e**2})`}const Jf={entering:{opacity:1,transform:oo(1)},entered:{opacity:1,transform:"none"}},Lr=typeof navigator<"u"&&/^((?!chrome|android).)*(safari|mobile)/i.test(navigator.userAgent)&&/(os |version\/)15(.|_)4/i.test(navigator.userAgent),Lo=M.forwardRef(function(t,n){const{addEndListener:r,appear:o=!0,children:s,easing:i,in:l,onEnter:c,onEntered:u,onEntering:d,onExit:m,onExited:w,onExiting:b,style:x,timeout:f="auto",TransitionComponent:h=Yf}=t,S=Ne(t,Kf),R=dn(),j=M.useRef(),E=_i(),v=M.useRef(null),P=yt(v,s.ref,n),V=Y=>F=>{if(Y){const te=v.current;F===void 0?Y(te):Y(te,F)}},U=V(d),C=V((Y,F)=>{Wf(Y);const{duration:te,delay:se,easing:oe}=Ya({style:x,timeout:f,easing:i},{mode:"enter"});let y;f==="auto"?(y=E.transitions.getAutoHeightDuration(Y.clientHeight),j.current=y):y=te,Y.style.transition=[E.transitions.create("opacity",{duration:y,delay:se}),E.transitions.create("transform",{duration:Lr?y:y*.666,delay:se,easing:oe})].join(","),c&&c(Y,F)}),_=V(u),k=V(b),D=V(Y=>{const{duration:F,delay:te,easing:se}=Ya({style:x,timeout:f,easing:i},{mode:"exit"});let oe;f==="auto"?(oe=E.transitions.getAutoHeightDuration(Y.clientHeight),j.current=oe):oe=F,Y.style.transition=[E.transitions.create("opacity",{duration:oe,delay:te}),E.transitions.create("transform",{duration:Lr?oe:oe*.666,delay:Lr?te:te||oe*.333,easing:se})].join(","),Y.style.opacity=0,Y.style.transform=oo(.75),m&&m(Y)}),$=V(w),J=Y=>{f==="auto"&&R.start(j.current||0,Y),r&&r(v.current,Y)};return a.jsx(h,O({appear:o,in:l,nodeRef:v,onEnter:C,onEntered:_,onEntering:U,onExit:D,onExited:$,onExiting:k,addEndListener:J,timeout:f==="auto"?null:f},S,{children:(Y,F)=>M.cloneElement(s,O({style:O({opacity:0,transform:oo(.75),visibility:Y==="exited"&&!l?"hidden":void 0},Jf[Y],x,s.props.style),ref:P},F))}))});process.env.NODE_ENV!=="production"&&(Lo.propTypes={addEndListener:p.func,appear:p.bool,children:ei.isRequired,easing:p.oneOfType([p.shape({enter:p.string,exit:p.string}),p.string]),in:p.bool,onEnter:p.func,onEntered:p.func,onEntering:p.func,onExit:p.func,onExited:p.func,onExiting:p.func,style:p.object,timeout:p.oneOfType([p.oneOf(["auto"]),p.number,p.shape({appear:p.number,enter:p.number,exit:p.number})])});Lo.muiSupportAuto=!0;const Wa=Lo,Zf=["anchorEl","component","components","componentsProps","container","disablePortal","keepMounted","modifiers","open","placement","popperOptions","popperRef","transition","slots","slotProps"],Qf=In(Oi,{name:"MuiPopper",slot:"Root",overridesResolver:(e,t)=>t.root})({}),Ii=M.forwardRef(function(t,n){var r;const o=wi(),s=Po({props:t,name:"MuiPopper"}),{anchorEl:i,component:l,components:c,componentsProps:u,container:d,disablePortal:m,keepMounted:w,modifiers:b,open:x,placement:f,popperOptions:h,popperRef:S,transition:R,slots:j,slotProps:E}=s,v=Ne(s,Zf),P=(r=j==null?void 0:j.root)!=null?r:c==null?void 0:c.Root,V=O({anchorEl:i,container:d,disablePortal:m,keepMounted:w,modifiers:b,open:x,placement:f,popperOptions:h,popperRef:S,transition:R},v);return a.jsx(Qf,O({as:l,direction:o==null?void 0:o.direction,slots:{root:P},slotProps:E??u},V,{ref:n}))});process.env.NODE_ENV!=="production"&&(Ii.propTypes={anchorEl:p.oneOfType([xn,p.object,p.func]),children:p.oneOfType([p.node,p.func]),component:p.elementType,components:p.shape({Root:p.elementType}),componentsProps:p.shape({root:p.oneOfType([p.func,p.object])}),container:p.oneOfType([xn,p.func]),disablePortal:p.bool,keepMounted:p.bool,modifiers:p.arrayOf(p.shape({data:p.object,effect:p.func,enabled:p.bool,fn:p.func,name:p.any,options:p.object,phase:p.oneOf(["afterMain","afterRead","afterWrite","beforeMain","beforeRead","beforeWrite","main","read","write"]),requires:p.arrayOf(p.string),requiresIfExists:p.arrayOf(p.string)})),open:p.bool.isRequired,placement:p.oneOf(["auto-end","auto-start","auto","bottom-end","bottom-start","bottom","left-end","left-start","left","right-end","right-start","right","top-end","top-start","top"]),popperOptions:p.shape({modifiers:p.array,onFirstUpdate:p.func,placement:p.oneOf(["auto-end","auto-start","auto","bottom-end","bottom-start","bottom","left-end","left-start","left","right-end","right-start","right","top-end","top-start","top"]),strategy:p.oneOf(["absolute","fixed"])}),popperRef:ni,slotProps:p.shape({root:p.oneOfType([p.func,p.object])}),slots:p.shape({root:p.elementType}),sx:p.oneOfType([p.arrayOf(p.oneOfType([p.func,p.object,p.bool])),p.func,p.object]),transition:p.bool});const Mi=Ii;function em(e){return ur("MuiTooltip",e)}const tm=ci("MuiTooltip",["popper","popperInteractive","popperArrow","popperClose","tooltip","tooltipArrow","touch","tooltipPlacementLeft","tooltipPlacementRight","tooltipPlacementTop","tooltipPlacementBottom","arrow"]),at=tm,nm=["arrow","children","classes","components","componentsProps","describeChild","disableFocusListener","disableHoverListener","disableInteractive","disableTouchListener","enterDelay","enterNextDelay","enterTouchDelay","followCursor","id","leaveDelay","leaveTouchDelay","onClose","onOpen","open","placement","PopperComponent","PopperProps","slotProps","slots","title","TransitionComponent","TransitionProps"];function rm(e){return Math.round(e*1e5)/1e5}const om=e=>{const{classes:t,disableInteractive:n,arrow:r,touch:o,placement:s}=e,i={popper:["popper",!n&&"popperInteractive",r&&"popperArrow"],tooltip:["tooltip",r&&"tooltipArrow",o&&"touch",`tooltipPlacement${Ye(s.split("-")[0])}`],arrow:["arrow"]};return ko(i,em,t)},am=In(Mi,{name:"MuiTooltip",slot:"Popper",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.popper,!n.disableInteractive&&t.popperInteractive,n.arrow&&t.popperArrow,!n.open&&t.popperClose]}})(({theme:e,ownerState:t,open:n})=>O({zIndex:(e.vars||e).zIndex.tooltip,pointerEvents:"none"},!t.disableInteractive&&{pointerEvents:"auto"},!n&&{pointerEvents:"none"},t.arrow&&{[`&[data-popper-placement*="bottom"] .${at.arrow}`]:{top:0,marginTop:"-0.71em","&::before":{transformOrigin:"0 100%"}},[`&[data-popper-placement*="top"] .${at.arrow}`]:{bottom:0,marginBottom:"-0.71em","&::before":{transformOrigin:"100% 0"}},[`&[data-popper-placement*="right"] .${at.arrow}`]:O({},t.isRtl?{right:0,marginRight:"-0.71em"}:{left:0,marginLeft:"-0.71em"},{height:"1em",width:"0.71em","&::before":{transformOrigin:"100% 100%"}}),[`&[data-popper-placement*="left"] .${at.arrow}`]:O({},t.isRtl?{left:0,marginLeft:"-0.71em"}:{right:0,marginRight:"-0.71em"},{height:"1em",width:"0.71em","&::before":{transformOrigin:"0 0"}})})),sm=In("div",{name:"MuiTooltip",slot:"Tooltip",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.tooltip,n.touch&&t.touch,n.arrow&&t.tooltipArrow,t[`tooltipPlacement${Ye(n.placement.split("-")[0])}`]]}})(({theme:e,ownerState:t})=>O({backgroundColor:e.vars?e.vars.palette.Tooltip.bg:mi(e.palette.grey[700],.92),borderRadius:(e.vars||e).shape.borderRadius,color:(e.vars||e).palette.common.white,fontFamily:e.typography.fontFamily,padding:"4px 8px",fontSize:e.typography.pxToRem(11),maxWidth:300,margin:2,wordWrap:"break-word",fontWeight:e.typography.fontWeightMedium},t.arrow&&{position:"relative",margin:0},t.touch&&{padding:"8px 16px",fontSize:e.typography.pxToRem(14),lineHeight:`${rm(16/14)}em`,fontWeight:e.typography.fontWeightRegular},{[`.${at.popper}[data-popper-placement*="left"] &`]:O({transformOrigin:"right center"},t.isRtl?O({marginLeft:"14px"},t.touch&&{marginLeft:"24px"}):O({marginRight:"14px"},t.touch&&{marginRight:"24px"})),[`.${at.popper}[data-popper-placement*="right"] &`]:O({transformOrigin:"left center"},t.isRtl?O({marginRight:"14px"},t.touch&&{marginRight:"24px"}):O({marginLeft:"14px"},t.touch&&{marginLeft:"24px"})),[`.${at.popper}[data-popper-placement*="top"] &`]:O({transformOrigin:"center bottom",marginBottom:"14px"},t.touch&&{marginBottom:"24px"}),[`.${at.popper}[data-popper-placement*="bottom"] &`]:O({transformOrigin:"center top",marginTop:"14px"},t.touch&&{marginTop:"24px"})})),im=In("span",{name:"MuiTooltip",slot:"Arrow",overridesResolver:(e,t)=>t.arrow})(({theme:e})=>({overflow:"hidden",position:"absolute",width:"1em",height:"0.71em",boxSizing:"border-box",color:e.vars?e.vars.palette.Tooltip.bg:mi(e.palette.grey[700],.9),"&::before":{content:'""',margin:"auto",display:"block",width:"100%",height:"100%",backgroundColor:"currentColor",transform:"rotate(45deg)"}}));let Gn=!1;const Ka=new On;let sn={x:0,y:0};function Un(e,t){return n=>{t&&t(n),e(n)}}const $i=M.forwardRef(function(t,n){var r,o,s,i,l,c,u,d,m,w,b,x,f,h,S,R,j,E,v;const P=Po({props:t,name:"MuiTooltip"}),{arrow:V=!1,children:U,components:C={},componentsProps:_={},describeChild:k=!1,disableFocusListener:D=!1,disableHoverListener:$=!1,disableInteractive:J=!1,disableTouchListener:Y=!1,enterDelay:F=100,enterNextDelay:te=0,enterTouchDelay:se=700,followCursor:oe=!1,id:y,leaveDelay:T=0,leaveTouchDelay:z=1500,onClose:L,onOpen:B,open:X,placement:q="bottom",PopperComponent:H,PopperProps:G={},slotProps:K={},slots:Z={},title:ue,TransitionComponent:I=Wa,TransitionProps:ye}=P,A=Ne(P,nm),xe=M.isValidElement(U)?U:a.jsx("span",{children:U}),Ge=_i(),lt=Ge.direction==="rtl",[Ee,Dn]=M.useState(),[Ue,Et]=M.useState(null),ct=M.useRef(!1),jt=J||oe,Ct=dn(),Tt=dn(),dt=dn(),Jt=dn(),[An,Go]=oi({controlled:X,default:!1,name:"Tooltip",state:"open"});let Ke=An;if(process.env.NODE_ENV!=="production"){const{current:ee}=M.useRef(X!==void 0);M.useEffect(()=>{Ee&&Ee.disabled&&!ee&&ue!==""&&Ee.tagName.toLowerCase()==="button"&&console.error(["MUI: You are providing a disabled `button` child to the Tooltip component.","A disabled element does not fire events.","Tooltip needs to listen to the child element's events to display the title.","","Add a simple wrapper element, such as a `span`."].join(` +`))}return null}),children:p.oneOfType([p.node,p.func]),container:p.oneOfType([xn,p.func]),direction:p.oneOf(["ltr","rtl"]),disablePortal:p.bool,keepMounted:p.bool,modifiers:p.arrayOf(p.shape({data:p.object,effect:p.func,enabled:p.bool,fn:p.func,name:p.any,options:p.object,phase:p.oneOf(["afterMain","afterRead","afterWrite","beforeMain","beforeRead","beforeWrite","main","read","write"]),requires:p.arrayOf(p.string),requiresIfExists:p.arrayOf(p.string)})),open:p.bool.isRequired,placement:p.oneOf(["auto-end","auto-start","auto","bottom-end","bottom-start","bottom","left-end","left-start","left","right-end","right-start","right","top-end","top-start","top"]),popperOptions:p.shape({modifiers:p.array,onFirstUpdate:p.func,placement:p.oneOf(["auto-end","auto-start","auto","bottom-end","bottom-start","bottom","left-end","left-start","left","right-end","right-start","right","top-end","top-start","top"]),strategy:p.oneOf(["absolute","fixed"])}),popperRef:ni,slotProps:p.shape({root:p.oneOfType([p.func,p.object])}),slots:p.shape({root:p.elementType}),transition:p.bool});function _i(){const e=fi(Oo);return process.env.NODE_ENV!=="production"&&M.useDebugValue(e),e[_o]||e}function no(e,t){return no=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,o){return r.__proto__=o,r},no(e,t)}function qf(e,t){e.prototype=Object.create(t.prototype),e.prototype.constructor=e,no(e,t)}const Xa={disabled:!1};var Hf=process.env.NODE_ENV!=="production"?p.oneOfType([p.number,p.shape({enter:p.number,exit:p.number,appear:p.number}).isRequired]):null;process.env.NODE_ENV!=="production"&&p.oneOfType([p.string,p.shape({enter:p.string,exit:p.string,active:p.string}),p.shape({enter:p.string,enterDone:p.string,enterActive:p.string,exit:p.string,exitDone:p.string,exitActive:p.string})]);const Pi=g.createContext(null);var Xf=function(t){return t.scrollTop},pn="unmounted",wt="exited",ft="entering",$t="entered",ro="exiting",nt=function(e){qf(t,e);function t(r,o){var s;s=e.call(this,r,o)||this;var i=o,l=i&&!i.isMounting?r.enter:r.appear,c;return s.appearStatus=null,r.in?l?(c=wt,s.appearStatus=ft):c=$t:r.unmountOnExit||r.mountOnEnter?c=pn:c=wt,s.state={status:c},s.nextCallback=null,s}t.getDerivedStateFromProps=function(o,s){var i=o.in;return i&&s.status===pn?{status:wt}:null};var n=t.prototype;return n.componentDidMount=function(){this.updateStatus(!0,this.appearStatus)},n.componentDidUpdate=function(o){var s=null;if(o!==this.props){var i=this.state.status;this.props.in?i!==ft&&i!==$t&&(s=ft):(i===ft||i===$t)&&(s=ro)}this.updateStatus(!1,s)},n.componentWillUnmount=function(){this.cancelNextCallback()},n.getTimeouts=function(){var o=this.props.timeout,s,i,l;return s=i=l=o,o!=null&&typeof o!="number"&&(s=o.exit,i=o.enter,l=o.appear!==void 0?o.appear:i),{exit:s,enter:i,appear:l}},n.updateStatus=function(o,s){if(o===void 0&&(o=!1),s!==null)if(this.cancelNextCallback(),s===ft){if(this.props.unmountOnExit||this.props.mountOnEnter){var i=this.props.nodeRef?this.props.nodeRef.current:ln.findDOMNode(this);i&&Xf(i)}this.performEnter(o)}else this.performExit();else this.props.unmountOnExit&&this.state.status===wt&&this.setState({status:pn})},n.performEnter=function(o){var s=this,i=this.props.enter,l=this.context?this.context.isMounting:o,c=this.props.nodeRef?[l]:[ln.findDOMNode(this),l],d=c[0],u=c[1],f=this.getTimeouts(),w=l?f.appear:f.enter;if(!o&&!i||Xa.disabled){this.safeSetState({status:$t},function(){s.props.onEntered(d)});return}this.props.onEnter(d,u),this.safeSetState({status:ft},function(){s.props.onEntering(d,u),s.onTransitionEnd(w,function(){s.safeSetState({status:$t},function(){s.props.onEntered(d,u)})})})},n.performExit=function(){var o=this,s=this.props.exit,i=this.getTimeouts(),l=this.props.nodeRef?void 0:ln.findDOMNode(this);if(!s||Xa.disabled){this.safeSetState({status:wt},function(){o.props.onExited(l)});return}this.props.onExit(l),this.safeSetState({status:ro},function(){o.props.onExiting(l),o.onTransitionEnd(i.exit,function(){o.safeSetState({status:wt},function(){o.props.onExited(l)})})})},n.cancelNextCallback=function(){this.nextCallback!==null&&(this.nextCallback.cancel(),this.nextCallback=null)},n.safeSetState=function(o,s){s=this.setNextCallback(s),this.setState(o,s)},n.setNextCallback=function(o){var s=this,i=!0;return this.nextCallback=function(l){i&&(i=!1,s.nextCallback=null,o(l))},this.nextCallback.cancel=function(){i=!1},this.nextCallback},n.onTransitionEnd=function(o,s){this.setNextCallback(s);var i=this.props.nodeRef?this.props.nodeRef.current:ln.findDOMNode(this),l=o==null&&!this.props.addEndListener;if(!i||l){setTimeout(this.nextCallback,0);return}if(this.props.addEndListener){var c=this.props.nodeRef?[this.nextCallback]:[i,this.nextCallback],d=c[0],u=c[1];this.props.addEndListener(d,u)}o!=null&&setTimeout(this.nextCallback,o)},n.render=function(){var o=this.state.status;if(o===pn)return null;var s=this.props,i=s.children;s.in,s.mountOnEnter,s.unmountOnExit,s.appear,s.enter,s.exit,s.timeout,s.addEndListener,s.onEnter,s.onEntering,s.onEntered,s.onExit,s.onExiting,s.onExited,s.nodeRef;var l=Ne(s,["children","in","mountOnEnter","unmountOnExit","appear","enter","exit","timeout","addEndListener","onEnter","onEntering","onEntered","onExit","onExiting","onExited","nodeRef"]);return g.createElement(Pi.Provider,{value:null},typeof i=="function"?i(o,l):g.cloneElement(g.Children.only(i),l))},t}(g.Component);nt.contextType=Pi;nt.propTypes=process.env.NODE_ENV!=="production"?{nodeRef:p.shape({current:typeof Element>"u"?p.any:function(e,t,n,r,o,s){var i=e[t];return p.instanceOf(i&&"ownerDocument"in i?i.ownerDocument.defaultView.Element:Element)(e,t,n,r,o,s)}}),children:p.oneOfType([p.func.isRequired,p.element.isRequired]).isRequired,in:p.bool,mountOnEnter:p.bool,unmountOnExit:p.bool,appear:p.bool,enter:p.bool,exit:p.bool,timeout:function(t){var n=Hf;t.addEndListener||(n=n.isRequired);for(var r=arguments.length,o=new Array(r>1?r-1:0),s=1;se.scrollTop;function Ya(e,t){var n,r;const{timeout:o,easing:s,style:i={}}=e;return{duration:(n=i.transitionDuration)!=null?n:typeof o=="number"?o:o[t.mode]||0,easing:(r=i.transitionTimingFunction)!=null?r:typeof s=="object"?s[t.mode]:s,delay:i.transitionDelay}}const Kf=["addEndListener","appear","children","easing","in","onEnter","onEntered","onEntering","onExit","onExited","onExiting","style","timeout","TransitionComponent"];function oo(e){return`scale(${e}, ${e**2})`}const Jf={entering:{opacity:1,transform:oo(1)},entered:{opacity:1,transform:"none"}},Lr=typeof navigator<"u"&&/^((?!chrome|android).)*(safari|mobile)/i.test(navigator.userAgent)&&/(os |version\/)15(.|_)4/i.test(navigator.userAgent),Lo=M.forwardRef(function(t,n){const{addEndListener:r,appear:o=!0,children:s,easing:i,in:l,onEnter:c,onEntered:d,onEntering:u,onExit:f,onExited:w,onExiting:b,style:x,timeout:m="auto",TransitionComponent:h=Yf}=t,S=Ne(t,Kf),R=dn(),j=M.useRef(),E=_i(),v=M.useRef(null),P=yt(v,s.ref,n),V=Y=>F=>{if(Y){const te=v.current;F===void 0?Y(te):Y(te,F)}},U=V(u),C=V((Y,F)=>{Wf(Y);const{duration:te,delay:se,easing:oe}=Ya({style:x,timeout:m,easing:i},{mode:"enter"});let y;m==="auto"?(y=E.transitions.getAutoHeightDuration(Y.clientHeight),j.current=y):y=te,Y.style.transition=[E.transitions.create("opacity",{duration:y,delay:se}),E.transitions.create("transform",{duration:Lr?y:y*.666,delay:se,easing:oe})].join(","),c&&c(Y,F)}),_=V(d),k=V(b),D=V(Y=>{const{duration:F,delay:te,easing:se}=Ya({style:x,timeout:m,easing:i},{mode:"exit"});let oe;m==="auto"?(oe=E.transitions.getAutoHeightDuration(Y.clientHeight),j.current=oe):oe=F,Y.style.transition=[E.transitions.create("opacity",{duration:oe,delay:te}),E.transitions.create("transform",{duration:Lr?oe:oe*.666,delay:Lr?te:te||oe*.333,easing:se})].join(","),Y.style.opacity=0,Y.style.transform=oo(.75),f&&f(Y)}),$=V(w),J=Y=>{m==="auto"&&R.start(j.current||0,Y),r&&r(v.current,Y)};return a.jsx(h,O({appear:o,in:l,nodeRef:v,onEnter:C,onEntered:_,onEntering:U,onExit:D,onExited:$,onExiting:k,addEndListener:J,timeout:m==="auto"?null:m},S,{children:(Y,F)=>M.cloneElement(s,O({style:O({opacity:0,transform:oo(.75),visibility:Y==="exited"&&!l?"hidden":void 0},Jf[Y],x,s.props.style),ref:P},F))}))});process.env.NODE_ENV!=="production"&&(Lo.propTypes={addEndListener:p.func,appear:p.bool,children:ei.isRequired,easing:p.oneOfType([p.shape({enter:p.string,exit:p.string}),p.string]),in:p.bool,onEnter:p.func,onEntered:p.func,onEntering:p.func,onExit:p.func,onExited:p.func,onExiting:p.func,style:p.object,timeout:p.oneOfType([p.oneOf(["auto"]),p.number,p.shape({appear:p.number,enter:p.number,exit:p.number})])});Lo.muiSupportAuto=!0;const Wa=Lo,Zf=["anchorEl","component","components","componentsProps","container","disablePortal","keepMounted","modifiers","open","placement","popperOptions","popperRef","transition","slots","slotProps"],Qf=In(Oi,{name:"MuiPopper",slot:"Root",overridesResolver:(e,t)=>t.root})({}),Ii=M.forwardRef(function(t,n){var r;const o=wi(),s=Po({props:t,name:"MuiPopper"}),{anchorEl:i,component:l,components:c,componentsProps:d,container:u,disablePortal:f,keepMounted:w,modifiers:b,open:x,placement:m,popperOptions:h,popperRef:S,transition:R,slots:j,slotProps:E}=s,v=Ne(s,Zf),P=(r=j==null?void 0:j.root)!=null?r:c==null?void 0:c.Root,V=O({anchorEl:i,container:u,disablePortal:f,keepMounted:w,modifiers:b,open:x,placement:m,popperOptions:h,popperRef:S,transition:R},v);return a.jsx(Qf,O({as:l,direction:o==null?void 0:o.direction,slots:{root:P},slotProps:E??d},V,{ref:n}))});process.env.NODE_ENV!=="production"&&(Ii.propTypes={anchorEl:p.oneOfType([xn,p.object,p.func]),children:p.oneOfType([p.node,p.func]),component:p.elementType,components:p.shape({Root:p.elementType}),componentsProps:p.shape({root:p.oneOfType([p.func,p.object])}),container:p.oneOfType([xn,p.func]),disablePortal:p.bool,keepMounted:p.bool,modifiers:p.arrayOf(p.shape({data:p.object,effect:p.func,enabled:p.bool,fn:p.func,name:p.any,options:p.object,phase:p.oneOf(["afterMain","afterRead","afterWrite","beforeMain","beforeRead","beforeWrite","main","read","write"]),requires:p.arrayOf(p.string),requiresIfExists:p.arrayOf(p.string)})),open:p.bool.isRequired,placement:p.oneOf(["auto-end","auto-start","auto","bottom-end","bottom-start","bottom","left-end","left-start","left","right-end","right-start","right","top-end","top-start","top"]),popperOptions:p.shape({modifiers:p.array,onFirstUpdate:p.func,placement:p.oneOf(["auto-end","auto-start","auto","bottom-end","bottom-start","bottom","left-end","left-start","left","right-end","right-start","right","top-end","top-start","top"]),strategy:p.oneOf(["absolute","fixed"])}),popperRef:ni,slotProps:p.shape({root:p.oneOfType([p.func,p.object])}),slots:p.shape({root:p.elementType}),sx:p.oneOfType([p.arrayOf(p.oneOfType([p.func,p.object,p.bool])),p.func,p.object]),transition:p.bool});const Mi=Ii;function em(e){return ur("MuiTooltip",e)}const tm=ci("MuiTooltip",["popper","popperInteractive","popperArrow","popperClose","tooltip","tooltipArrow","touch","tooltipPlacementLeft","tooltipPlacementRight","tooltipPlacementTop","tooltipPlacementBottom","arrow"]),at=tm,nm=["arrow","children","classes","components","componentsProps","describeChild","disableFocusListener","disableHoverListener","disableInteractive","disableTouchListener","enterDelay","enterNextDelay","enterTouchDelay","followCursor","id","leaveDelay","leaveTouchDelay","onClose","onOpen","open","placement","PopperComponent","PopperProps","slotProps","slots","title","TransitionComponent","TransitionProps"];function rm(e){return Math.round(e*1e5)/1e5}const om=e=>{const{classes:t,disableInteractive:n,arrow:r,touch:o,placement:s}=e,i={popper:["popper",!n&&"popperInteractive",r&&"popperArrow"],tooltip:["tooltip",r&&"tooltipArrow",o&&"touch",`tooltipPlacement${Ye(s.split("-")[0])}`],arrow:["arrow"]};return ko(i,em,t)},am=In(Mi,{name:"MuiTooltip",slot:"Popper",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.popper,!n.disableInteractive&&t.popperInteractive,n.arrow&&t.popperArrow,!n.open&&t.popperClose]}})(({theme:e,ownerState:t,open:n})=>O({zIndex:(e.vars||e).zIndex.tooltip,pointerEvents:"none"},!t.disableInteractive&&{pointerEvents:"auto"},!n&&{pointerEvents:"none"},t.arrow&&{[`&[data-popper-placement*="bottom"] .${at.arrow}`]:{top:0,marginTop:"-0.71em","&::before":{transformOrigin:"0 100%"}},[`&[data-popper-placement*="top"] .${at.arrow}`]:{bottom:0,marginBottom:"-0.71em","&::before":{transformOrigin:"100% 0"}},[`&[data-popper-placement*="right"] .${at.arrow}`]:O({},t.isRtl?{right:0,marginRight:"-0.71em"}:{left:0,marginLeft:"-0.71em"},{height:"1em",width:"0.71em","&::before":{transformOrigin:"100% 100%"}}),[`&[data-popper-placement*="left"] .${at.arrow}`]:O({},t.isRtl?{left:0,marginLeft:"-0.71em"}:{right:0,marginRight:"-0.71em"},{height:"1em",width:"0.71em","&::before":{transformOrigin:"0 0"}})})),sm=In("div",{name:"MuiTooltip",slot:"Tooltip",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.tooltip,n.touch&&t.touch,n.arrow&&t.tooltipArrow,t[`tooltipPlacement${Ye(n.placement.split("-")[0])}`]]}})(({theme:e,ownerState:t})=>O({backgroundColor:e.vars?e.vars.palette.Tooltip.bg:mi(e.palette.grey[700],.92),borderRadius:(e.vars||e).shape.borderRadius,color:(e.vars||e).palette.common.white,fontFamily:e.typography.fontFamily,padding:"4px 8px",fontSize:e.typography.pxToRem(11),maxWidth:300,margin:2,wordWrap:"break-word",fontWeight:e.typography.fontWeightMedium},t.arrow&&{position:"relative",margin:0},t.touch&&{padding:"8px 16px",fontSize:e.typography.pxToRem(14),lineHeight:`${rm(16/14)}em`,fontWeight:e.typography.fontWeightRegular},{[`.${at.popper}[data-popper-placement*="left"] &`]:O({transformOrigin:"right center"},t.isRtl?O({marginLeft:"14px"},t.touch&&{marginLeft:"24px"}):O({marginRight:"14px"},t.touch&&{marginRight:"24px"})),[`.${at.popper}[data-popper-placement*="right"] &`]:O({transformOrigin:"left center"},t.isRtl?O({marginRight:"14px"},t.touch&&{marginRight:"24px"}):O({marginLeft:"14px"},t.touch&&{marginLeft:"24px"})),[`.${at.popper}[data-popper-placement*="top"] &`]:O({transformOrigin:"center bottom",marginBottom:"14px"},t.touch&&{marginBottom:"24px"}),[`.${at.popper}[data-popper-placement*="bottom"] &`]:O({transformOrigin:"center top",marginTop:"14px"},t.touch&&{marginTop:"24px"})})),im=In("span",{name:"MuiTooltip",slot:"Arrow",overridesResolver:(e,t)=>t.arrow})(({theme:e})=>({overflow:"hidden",position:"absolute",width:"1em",height:"0.71em",boxSizing:"border-box",color:e.vars?e.vars.palette.Tooltip.bg:mi(e.palette.grey[700],.9),"&::before":{content:'""',margin:"auto",display:"block",width:"100%",height:"100%",backgroundColor:"currentColor",transform:"rotate(45deg)"}}));let Gn=!1;const Ka=new On;let sn={x:0,y:0};function Un(e,t){return n=>{t&&t(n),e(n)}}const $i=M.forwardRef(function(t,n){var r,o,s,i,l,c,d,u,f,w,b,x,m,h,S,R,j,E,v;const P=Po({props:t,name:"MuiTooltip"}),{arrow:V=!1,children:U,components:C={},componentsProps:_={},describeChild:k=!1,disableFocusListener:D=!1,disableHoverListener:$=!1,disableInteractive:J=!1,disableTouchListener:Y=!1,enterDelay:F=100,enterNextDelay:te=0,enterTouchDelay:se=700,followCursor:oe=!1,id:y,leaveDelay:T=0,leaveTouchDelay:z=1500,onClose:L,onOpen:B,open:X,placement:q="bottom",PopperComponent:H,PopperProps:G={},slotProps:K={},slots:Z={},title:ue,TransitionComponent:I=Wa,TransitionProps:ye}=P,A=Ne(P,nm),xe=M.isValidElement(U)?U:a.jsx("span",{children:U}),Ge=_i(),lt=Ge.direction==="rtl",[Ee,Dn]=M.useState(),[Ue,Et]=M.useState(null),ct=M.useRef(!1),jt=J||oe,Ct=dn(),Tt=dn(),dt=dn(),Jt=dn(),[An,Go]=oi({controlled:X,default:!1,name:"Tooltip",state:"open"});let Ke=An;if(process.env.NODE_ENV!=="production"){const{current:ee}=M.useRef(X!==void 0);M.useEffect(()=>{Ee&&Ee.disabled&&!ee&&ue!==""&&Ee.tagName.toLowerCase()==="button"&&console.error(["MUI: You are providing a disabled `button` child to the Tooltip component.","A disabled element does not fire events.","Tooltip needs to listen to the child element's events to display the title.","","Add a simple wrapper element, such as a `span`."].join(` `))},[ue,Ee,ee])}const kr=ri(y),Zt=M.useRef(),Bn=Zr(()=>{Zt.current!==void 0&&(document.body.style.WebkitUserSelect=Zt.current,Zt.current=void 0),Jt.clear()});M.useEffect(()=>Bn,[Bn]);const Uo=ee=>{Ka.clear(),Gn=!0,Go(!0),B&&!Ke&&B(ee)},Vn=Zr(ee=>{Ka.start(800+T,()=>{Gn=!1}),Go(!1),L&&Ke&&L(ee),Ct.start(Ge.transitions.duration.shortest,()=>{ct.current=!1})}),Sr=ee=>{ct.current&&ee.type!=="touchstart"||(Ee&&Ee.removeAttribute("title"),Tt.clear(),dt.clear(),F||Gn&&te?Tt.start(Gn?te:F,()=>{Uo(ee)}):Uo(ee))},qo=ee=>{Tt.clear(),dt.start(T,()=>{Vn(ee)})},{isFocusVisibleRef:Ho,onBlur:rl,onFocus:ol,ref:al}=ai(),[,Xo]=M.useState(!1),Yo=ee=>{rl(ee),Ho.current===!1&&(Xo(!1),qo(ee))},Wo=ee=>{Ee||Dn(ee.currentTarget),ol(ee),Ho.current===!0&&(Xo(!0),Sr(ee))},Ko=ee=>{ct.current=!0;const _e=xe.props;_e.onTouchStart&&_e.onTouchStart(ee)},Jo=Sr,Zo=qo,sl=ee=>{Ko(ee),dt.clear(),Ct.clear(),Bn(),Zt.current=document.body.style.WebkitUserSelect,document.body.style.WebkitUserSelect="none",Jt.start(se,()=>{document.body.style.WebkitUserSelect=Zt.current,Sr(ee)})},il=ee=>{xe.props.onTouchEnd&&xe.props.onTouchEnd(ee),Bn(),dt.start(z,()=>{Vn(ee)})};M.useEffect(()=>{if(!Ke)return;function ee(_e){(_e.key==="Escape"||_e.key==="Esc")&&Vn(_e)}return document.addEventListener("keydown",ee),()=>{document.removeEventListener("keydown",ee)}},[Vn,Ke]);const ll=yt(xe.ref,al,Dn,n);!ue&&ue!==0&&(Ke=!1);const Er=M.useRef(),cl=ee=>{const _e=xe.props;_e.onMouseMove&&_e.onMouseMove(ee),sn={x:ee.clientX,y:ee.clientY},Er.current&&Er.current.update()},Qt={},jr=typeof ue=="string";k?(Qt.title=!Ke&&jr&&!$?ue:null,Qt["aria-describedby"]=Ke?kr:null):(Qt["aria-label"]=jr?ue:null,Qt["aria-labelledby"]=Ke&&!jr?kr:null);const De=O({},Qt,A,xe.props,{className:ot(A.className,xe.props.className),onTouchStart:Ko,ref:ll},oe?{onMouseMove:cl}:{});process.env.NODE_ENV!=="production"&&(De["data-mui-internal-clone-element"]=!0,M.useEffect(()=>{Ee&&!Ee.getAttribute("data-mui-internal-clone-element")&&console.error(["MUI: The `children` component of the Tooltip is not forwarding its props correctly.","Please make sure that props are spread on the same element that the ref is applied to."].join(` `))},[Ee]));const en={};Y||(De.onTouchStart=sl,De.onTouchEnd=il),$||(De.onMouseOver=Un(Jo,De.onMouseOver),De.onMouseLeave=Un(Zo,De.onMouseLeave),jt||(en.onMouseOver=Jo,en.onMouseLeave=Zo)),D||(De.onFocus=Un(Wo,De.onFocus),De.onBlur=Un(Yo,De.onBlur),jt||(en.onFocus=Wo,en.onBlur=Yo)),process.env.NODE_ENV!=="production"&&xe.props.title&&console.error(["MUI: You have provided a `title` prop to the child of .",`Remove this title prop \`${xe.props.title}\` or the Tooltip component.`].join(` -`));const dl=M.useMemo(()=>{var ee;let _e=[{name:"arrow",enabled:!!Ue,options:{element:Ue,padding:4}}];return(ee=G.popperOptions)!=null&&ee.modifiers&&(_e=_e.concat(G.popperOptions.modifiers)),O({},G.popperOptions,{modifiers:_e})},[Ue,G]),tn=O({},P,{isRtl:lt,arrow:V,disableInteractive:jt,placement:q,PopperComponentProp:H,touch:ct.current}),Cr=om(tn),Qo=(r=(o=Z.popper)!=null?o:C.Popper)!=null?r:am,ea=(s=(i=(l=Z.transition)!=null?l:C.Transition)!=null?i:I)!=null?s:Wa,ta=(c=(u=Z.tooltip)!=null?u:C.Tooltip)!=null?c:sm,na=(d=(m=Z.arrow)!=null?m:C.Arrow)!=null?d:im,ul=un(Qo,O({},G,(w=K.popper)!=null?w:_.popper,{className:ot(Cr.popper,G==null?void 0:G.className,(b=(x=K.popper)!=null?x:_.popper)==null?void 0:b.className)}),tn),pl=un(ea,O({},ye,(f=K.transition)!=null?f:_.transition),tn),wl=un(ta,O({},(h=K.tooltip)!=null?h:_.tooltip,{className:ot(Cr.tooltip,(S=(R=K.tooltip)!=null?R:_.tooltip)==null?void 0:S.className)}),tn),fl=un(na,O({},(j=K.arrow)!=null?j:_.arrow,{className:ot(Cr.arrow,(E=(v=K.arrow)!=null?v:_.arrow)==null?void 0:E.className)}),tn);return a.jsxs(M.Fragment,{children:[M.cloneElement(xe,De),a.jsx(Qo,O({as:H??Mi,placement:q,anchorEl:oe?{getBoundingClientRect:()=>({top:sn.y,left:sn.x,right:sn.x,bottom:sn.y,width:0,height:0})}:Ee,popperRef:Er,open:Ee?Ke:!1,id:kr,transition:!0},en,ul,{popperOptions:dl,children:({TransitionProps:ee})=>a.jsx(ea,O({timeout:Ge.transitions.duration.shorter},ee,pl,{children:a.jsxs(ta,O({},wl,{children:[ue,V?a.jsx(na,O({},fl,{ref:Et})):null]}))}))}))]})});process.env.NODE_ENV!=="production"&&($i.propTypes={arrow:p.bool,children:ei.isRequired,classes:p.object,className:p.string,components:p.shape({Arrow:p.elementType,Popper:p.elementType,Tooltip:p.elementType,Transition:p.elementType}),componentsProps:p.shape({arrow:p.object,popper:p.object,tooltip:p.object,transition:p.object}),describeChild:p.bool,disableFocusListener:p.bool,disableHoverListener:p.bool,disableInteractive:p.bool,disableTouchListener:p.bool,enterDelay:p.number,enterNextDelay:p.number,enterTouchDelay:p.number,followCursor:p.bool,id:p.string,leaveDelay:p.number,leaveTouchDelay:p.number,onClose:p.func,onOpen:p.func,open:p.bool,placement:p.oneOf(["bottom-end","bottom-start","bottom","left-end","left-start","left","right-end","right-start","right","top-end","top-start","top"]),PopperComponent:p.elementType,PopperProps:p.object,slotProps:p.shape({arrow:p.object,popper:p.object,tooltip:p.object,transition:p.object}),slots:p.shape({arrow:p.elementType,popper:p.elementType,tooltip:p.elementType,transition:p.elementType}),sx:p.oneOfType([p.arrayOf(p.oneOfType([p.func,p.object,p.bool])),p.func,p.object]),title:p.node,TransitionComponent:p.elementType,TransitionProps:p.object});const lm=$i;function Ja(e,t,n){return e?a.jsx(Me.ListItemIcon,{className:`papi-menu-icon-${n?"leading":"trailing"}`,children:a.jsx("img",{src:e,alt:`${n?"Leading":"Trailing"} icon for ${t}`})}):void 0}function Fo(e){const{onClick:t,label:n,tooltip:r,allowForLeadingIcons:o=!0,iconPathBefore:s=void 0,iconPathAfter:i=void 0,hasAutoFocus:l=!1,className:c,isDisabled:u=!1,isDense:d=!0,isSubMenuParent:m=!1,hasDisabledGutters:w=!1,hasDivider:b=!1,focusVisibleClassName:x,id:f,children:h}=e,S=a.jsx(Me.MenuItem,{sx:{lineHeight:.8},autoFocus:l,className:c,disabled:u,dense:d,disableGutters:w,divider:b,focusVisibleClassName:x,onClick:t,id:f,children:n?a.jsxs(a.Fragment,{children:[Ja(s,n,!0),a.jsx(Me.ListItemText,{primary:n,inset:!s&&o}),m?a.jsx(Me.ListItemIcon,{className:"papi-menu-icon-trailing",children:a.jsx(gi,{})}):Ja(i,n,!1)]}):h});return r?a.jsx(lm,{title:r,placement:"right",children:a.jsx("div",{children:S})}):S}function Di(e){return Object.entries(e.groups).map(([n,r])=>({id:n,group:r}))}function cm(e){const[t,n]=g.useState(void 0),{parentMenuItem:r,parentItemProps:o,menuDefinition:s}=e,i=u=>{n(u.currentTarget)},l=()=>{n(void 0)},c=()=>{let u=Di(s).filter(d=>"menuItem"in d.group);if(!(r!=null&&r.id))throw new Error("A valid parent menu item is required for submenus.");return u=u.filter(d=>"menuItem"in d.group&&d.group.menuItem===r.id),a.jsx(Ai,{...e,includedGroups:u})};return a.jsxs(a.Fragment,{children:[a.jsx(Fo,{onClick:i,...o,isSubMenuParent:!0}),a.jsx(Me.Menu,{anchorEl:t,open:!!t,onClose:l,anchorOrigin:{vertical:"top",horizontal:"right"},transformOrigin:{vertical:"top",horizontal:"left"},children:c()},r.id)]})}const dm=(e,t)=>t.filter(o=>o.group===e).sort((o,s)=>(o.order||0)-(s.order||0));function Ai(e){const{menuDefinition:t,onClick:n,commandHandler:r,includedGroups:o}=e,{items:s,allowForLeadingIcons:i}=g.useMemo(()=>{const d=o&&o.length>0?o:Di(t).filter(x=>!("menuItem"in x.group)),m=Object.values(d).sort((x,f)=>(x.group.order||0)-(f.group.order||0)),w=[];m.forEach(x=>{dm(x.id,t.items).forEach(f=>w.push({item:f,isLastItemInGroup:!1})),w.length>0&&(w[w.length-1].isLastItemInGroup=!0)}),w.length>0&&(w[w.length-1].isLastItemInGroup=!1);const b=w.some(x=>"iconPathBefore"in x.item&&x.item.iconPathBefore);return{items:w,allowForLeadingIcons:b}},[o,t]),l=({item:d,isLastItemInGroup:m})=>({className:"papi-menu-item",label:d.label,tooltip:d.tooltip,iconPathBefore:"iconPathBefore"in d?d.iconPathBefore:void 0,iconPathAfter:"iconPathAfter"in d?d.iconPathAfter:void 0,hasDivider:m,allowForLeadingIcons:i}),[c]=s;if(!c)return a.jsx("div",{});const u=c.item.group;return a.jsx("div",{role:"menu","aria-label":u,children:s.map((d,m)=>{const{item:w}=d,b=l(d);if("command"in w){const x=w.group+m;return a.jsx(Fo,{onClick:f=>{n==null||n(f),r(w)},...b},x)}return a.jsx(cm,{parentMenuItem:w,parentItemProps:b,...e},u+w.id)})},u)}function um(e){const{menuDefinition:t,columnId:n}=e;let s=Object.entries(t.groups).map(([i,l])=>({id:i,group:l})).filter(i=>"column"in i.group);return n&&"columns"in t&&t.columns[n]&&(s=s.filter(i=>"column"in i.group&&i.group.column===n)),a.jsx(Ai,{...e,includedGroups:s})}function pm({commandHandler:e,menuDefinition:t,id:n,metadata:r,onClick:o,className:s}){return a.jsxs(Me.Grid,{id:n,item:!0,xs:"auto",role:"menu","aria-label":n,className:`papi-menu-column ${s??""}`,children:[a.jsx("h3",{"aria-label":r.label,className:`papi-menu-column-header ${s??""}`,children:r.label}),a.jsx(Me.List,{id:n,dense:!0,className:s??"",children:a.jsx(um,{commandHandler:e,menuDefinition:t,columnId:n,onClick:o})})]})}function Bi({commandHandler:e,className:t,multiColumnMenu:n,id:r}){const{columns:o}=n,s=g.useMemo(()=>{const i=new Map;return Object.getOwnPropertyNames(o).forEach(l=>{if(l==="isExtensible")return;const c=l,u=o[c];typeof u=="object"&&typeof u.order=="number"&&!Number.isNaN(u.order)?i.set(u.order,{id:c,metadata:u}):console.warn(`Property ${l} (${typeof u}) on menu ${r} is not a valid column and is being ignored. This might indicate data corruption`)}),Array.from(i.values()).sort((l,c)=>(l.metadata.order||0)-(c.metadata.order||0))},[o,r]);return a.jsx(Me.Grid,{container:!0,spacing:0,className:`papi-multi-column-menu ${t??""}`,columns:s.length,role:"menu","aria-label":"GridMenu",id:r,children:s.map((i,l)=>a.jsx(pm,{commandHandler:e,menuDefinition:n,...i,className:t},l))})}function wm(e){return{preserveValue:!0,...e}}const nr=(e,t,n={})=>{const r=g.useRef(t);r.current=t;const o=g.useRef(n);o.current=wm(o.current);const[s,i]=g.useState(()=>r.current),[l,c]=g.useState(!0);return g.useEffect(()=>{let u=!0;return c(!!e),(async()=>{if(e){const d=await e();u&&(i(()=>d),c(!1))}})(),()=>{u=!1,o.current.preserveValue||i(()=>r.current)}},[e]),[s,l]},fm=hi(a.jsx("path",{d:"M3 18h18v-2H3zm0-5h18v-2H3zm0-7v2h18V6z"}),"Menu");function Vi({menuProvider:e,normalMenu:t,fullMenu:n,commandHandler:r,containerRef:o,className:s,ariaLabelPrefix:i,children:l}){const[c,u]=g.useState(!1),[d,m]=g.useState(!1),w=g.useCallback(()=>{c&&u(!1),m(!1)},[c]),b=g.useCallback(E=>{E.stopPropagation(),u(v=>{const P=!v;return P&&E.shiftKey?m(!0):P||m(!1),P})},[]),x=g.useCallback(E=>(w(),r(E)),[r,w]),[f,h]=g.useState({top:1,left:1});g.useEffect(()=>{if(c){const E=o==null?void 0:o.current;if(E){const v=E.getBoundingClientRect(),P=window.scrollY,V=window.scrollX,U=v.top+P+E.clientHeight,C=v.left+V;h({top:U,left:C})}}},[c,o]);const[S]=nr(g.useCallback(async()=>(e==null?void 0:e(!1))??t,[e,t,c]),t),[R]=nr(g.useCallback(async()=>(e==null?void 0:e(!0))??n??S,[e,n,S,c]),n??S),j=d&&R?R:S;return a.jsxs(a.Fragment,{children:[a.jsx(Me.IconButton,{sx:{paddingTop:0,paddingBottom:0},edge:"start",className:`papi-menuButton ${s??""}`,color:"inherit","aria-label":`${i??""} menu button`,onClick:b,children:l??a.jsx(fm,{})}),a.jsx(Me.Drawer,{className:`papi-menu-drawer ${s??""}`,anchor:"left",variant:"temporary",open:c,onClose:w,PaperProps:{className:"papi-menu-drawer-paper",style:{top:f.top,left:f.left}},children:j?a.jsx(Bi,{className:s,id:`${i??""} main menu`,commandHandler:x,multiColumnMenu:j}):void 0})]})}function mm({id:e,label:t,isDisabled:n=!1,tooltip:r,isTooltipSuppressed:o=!1,adjustMarginToAlignToEdge:s=!1,size:i="medium",className:l,onClick:c,children:u}){return a.jsx(Me.IconButton,{id:e,disabled:n,edge:s,size:i,"aria-label":t,title:o?void 0:r??t,className:`papi-icon-button ${l??""}`,onClick:c,children:u})}const Kt=g.forwardRef(({className:e,...t},n)=>a.jsx(Q.LoaderCircle,{size:35,className:N("tw-animate-spin",e),...t,ref:n}));Kt.displayName="Spinner";function hm({id:e,isDisabled:t=!1,hasError:n=!1,isFullWidth:r=!1,helperText:o,label:s,placeholder:i,isRequired:l=!1,className:c,defaultValue:u,value:d,onChange:m,onFocus:w,onBlur:b}){return a.jsxs("div",{className:N("tw-inline-grid tw-items-center tw-gap-1.5",{"tw-w-full":r}),children:[a.jsx(qe,{htmlFor:e,className:N({"tw-text-red-600":n,"tw-hidden":!s}),children:`${s}${l?"*":""}`}),a.jsx(St,{id:e,disabled:t,placeholder:i,required:l,className:N(c,{"tw-border-red-600":n}),defaultValue:u,value:d,onChange:m,onFocus:w,onBlur:b}),a.jsx("p",{className:N({"tw-hidden":!o}),children:o})]})}function gm({menuProvider:e,commandHandler:t,className:n,id:r,children:o}){const s=g.useRef(void 0);return a.jsx("div",{ref:s,style:{position:"relative"},children:a.jsx(Me.AppBar,{position:"static",id:r,children:a.jsxs(Me.Toolbar,{className:N("tw-bg-muted tw-text-muted-foreground",n),variant:"dense",children:[e?a.jsx(Vi,{commandHandler:t,containerRef:s,menuProvider:e}):void 0,o?a.jsx("div",{className:"papi-toolbar-children",children:o}):void 0]})})})}const bm=Xt.cva("tw-relative tw-w-full tw-rounded-lg tw-border tw-p-4 [&>svg~*]:tw-pl-7 [&>svg+div]:tw-translate-y-[-3px] [&>svg]:tw-absolute [&>svg]:tw-left-4 [&>svg]:tw-top-4 [&>svg]:tw-text-foreground",{variants:{variant:{default:"tw-bg-background tw-text-foreground",destructive:"tw-border-destructive/50 tw-text-destructive dark:tw-border-destructive [&>svg]:tw-text-destructive"}},defaultVariants:{variant:"default"}}),zi=g.forwardRef(({className:e,variant:t,...n},r)=>a.jsx("div",{ref:r,role:"alert",className:N(bm({variant:t}),e),...n}));zi.displayName="Alert";const Li=g.forwardRef(({className:e,...t},n)=>a.jsxs("h5",{ref:n,className:N("tw-mb-1 tw-font-medium tw-leading-none tw-tracking-tight",e),...t,children:[t.children," "]}));Li.displayName="AlertTitle";const Fi=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,className:N("tw-text-sm [&_p]:tw-leading-relaxed",e),...t}));Fi.displayName="AlertDescription";const Gi=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,className:N("pr-twp tw-rounded-lg tw-border tw-bg-card tw-text-card-foreground tw-shadow-sm",e),...t}));Gi.displayName="Card";const Ui=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,className:N("pr-twp tw-flex tw-flex-col tw-space-y-1.5 tw-p-6",e),...t}));Ui.displayName="CardHeader";const qi=g.forwardRef(({className:e,...t},n)=>a.jsx("h3",{ref:n,className:N("pr-twp tw-text-2xl tw-font-semibold tw-leading-none tw-tracking-tight",e),...t,children:t.children}));qi.displayName="CardTitle";const Hi=g.forwardRef(({className:e,...t},n)=>a.jsx("p",{ref:n,className:N("pr-twp tw-text-sm tw-text-muted-foreground",e),...t}));Hi.displayName="CardDescription";const Xi=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,className:N("pr-twp tw-p-6 tw-pt-0",e),...t}));Xi.displayName="CardContent";const Yi=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,className:N("pr-twp tw-flex tw-items-center tw-p-6 tw-pt-0",e),...t}));Yi.displayName="CardFooter";function vm({...e}){return a.jsx(Qa.Toaster,{className:"tw-toaster tw-group",toastOptions:{classNames:{toast:"group toast group-[.toaster]:bg-background group-[.toaster]:text-foreground group-[.toaster]:border-border group-[.toaster]:shadow-lg",description:"group-[.toast]:text-muted-foreground",actionButton:"group-[.toast]:bg-primary group-[.toast]:text-primary-foreground",cancelButton:"group-[.toast]:bg-muted group-[.toast]:text-muted-foreground"}},...e})}const Wi=g.forwardRef(({className:e,...t},n)=>a.jsxs(cn.Root,{ref:n,className:N("pr-twp tw-relative tw-flex tw-w-full tw-touch-none tw-select-none tw-items-center",e),...t,children:[a.jsx(cn.Track,{className:"tw-relative tw-h-2 tw-w-full tw-grow tw-overflow-hidden tw-rounded-full tw-bg-secondary",children:a.jsx(cn.Range,{className:"tw-absolute tw-h-full tw-bg-primary"})}),a.jsx(cn.Thumb,{className:"tw-block tw-h-5 tw-w-5 tw-rounded-full tw-border-2 tw-border-primary tw-bg-background tw-ring-offset-background tw-transition-colors focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50"})]}));Wi.displayName=cn.Root.displayName;const Ki=g.forwardRef(({className:e,...t},n)=>a.jsx(qr.Root,{className:N("tw-peer pr-twp tw-inline-flex tw-h-6 tw-w-11 tw-shrink-0 tw-cursor-pointer tw-items-center tw-rounded-full tw-border-2 tw-border-transparent tw-transition-colors focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 focus-visible:tw-ring-offset-background disabled:tw-cursor-not-allowed disabled:tw-opacity-50 data-[state=checked]:tw-bg-primary data-[state=unchecked]:tw-bg-input",e),...t,ref:n,children:a.jsx(qr.Thumb,{className:N("pr-twp tw-pointer-events-none tw-block tw-h-5 tw-w-5 tw-rounded-full tw-bg-background tw-shadow-lg tw-ring-0 tw-transition-transform data-[state=checked]:tw-translate-x-5 data-[state=unchecked]:tw-translate-x-0")})}));Ki.displayName=qr.Root.displayName;const xm=Oe.Root,Ji=g.forwardRef(({className:e,...t},n)=>a.jsx(Oe.List,{ref:n,className:N("tw-inline-flex tw-h-10 tw-items-center tw-justify-center tw-rounded-md tw-bg-muted tw-p-1 tw-text-muted-foreground",e),...t}));Ji.displayName=Oe.List.displayName;const Zi=g.forwardRef(({className:e,...t},n)=>a.jsx(Oe.Trigger,{ref:n,className:N("tw-inline-flex tw-items-center tw-justify-center tw-whitespace-nowrap tw-rounded-sm tw-px-3 tw-py-1.5 tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-all hover:tw-text-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50 data-[state=active]:tw-bg-background data-[state=active]:tw-text-foreground data-[state=active]:tw-shadow-sm",e),...t}));Zi.displayName=Oe.Trigger.displayName;const Qi=g.forwardRef(({className:e,...t},n)=>a.jsx(Oe.Content,{ref:n,className:N("tw-mt-2 tw-ring-offset-background focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2",e),...t}));Qi.displayName=Oe.Content.displayName;function ym({isInstalling:e,handleClick:t,buttonText:n,className:r,...o}){return a.jsx(fe,{className:N("tw-h-8 tw-rounded-md tw-text-white tw-transition tw-duration-300 tw-ease-in-out hover:tw-bg-blue-700",{"tw-cursor-not-allowed tw-bg-blue-700":e,"tw-bg-blue-600":!e,"tw-bg-white tw-text-blue-600 hover:tw-text-white":!n,"tw-w-20":n},r),onClick:t,...o,children:e?a.jsx(Kt,{size:15}):a.jsxs(a.Fragment,{children:[a.jsx(Q.Download,{size:25,className:N("tw-h-4 tw-w-4",{"tw-mr-1":n})}),n]})})}function Nm({isEnabling:e,handleClick:t,className:n,...r}){return a.jsx(fe,{className:N("tw-h-8 tw-rounded-md tw-bg-blue-600 tw-px-4 tw-text-white tw-transition tw-duration-300 tw-ease-in-out hover:tw-bg-blue-700",{"tw-cursor-not-allowed tw-bg-blue-700":e},n),onClick:t,...r,children:e?a.jsxs(a.Fragment,{children:[a.jsx(Kt,{size:15,className:"tw-mr-1 tw-text-white"}),"Enabling..."]}):"Enable"})}function km({isDisabling:e,handleClick:t,className:n,...r}){return a.jsx(fe,{className:N("tw-h-8 tw-rounded-md tw-bg-gray-300 tw-text-black tw-transition tw-duration-300 tw-ease-in-out hover:tw-bg-gray-400",{"tw-cursor-not-allowed tw-bg-gray-400":e},n),onClick:t,...r,children:e?a.jsxs(a.Fragment,{children:[a.jsx(Kt,{size:15,className:"tw-mr-1 tw-text-black"}),"Disabling..."]}):"Disable"})}function Sm({isUpdating:e,handleClick:t,className:n,...r}){return a.jsx(fe,{className:N("tw-h-8 tw-rounded-md tw-bg-blue-600 tw-px-4 tw-text-white tw-transition tw-duration-300 tw-ease-in-out hover:tw-bg-blue-700 hover:tw-text-white",{"tw-cursor-not-allowed tw-bg-blue-700":e},n),onClick:t,...r,children:e?a.jsxs(a.Fragment,{children:[a.jsx(Kt,{size:15,className:"tw-mr-1 tw-text-white"}),"Updating..."]}):"Update"})}function Em({id:e,markdown:t,className:n,anchorTarget:r}){const o=g.useMemo(()=>({overrides:{a:{props:{target:r}}}}),[r]);return a.jsx("div",{id:e,className:N("pr-twp tw-prose",n),children:a.jsx(Rl,{options:o,children:t})})}const el=g.forwardRef((e,t)=>a.jsxs(fe,{ref:t,className:"tw-rounded-md tw-border tw-border-dashed tw-border-gray-400 tw-bg-white tw-px-4 tw-py-2 tw-text-black tw-transition tw-duration-300 tw-ease-in-out hover:tw-border-blue-600 hover:tw-bg-white hover:tw-text-blue-600",...e,children:[a.jsx(Q.Filter,{size:16,className:"tw-mr-2 tw-h-4 tw-w-4 tw-text-gray-700 hover:tw-text-blue-600"}),"Filter",a.jsx(Q.ChevronDown,{size:16,className:"tw-ml-2 tw-h-4 tw-w-4 tw-text-gray-700 hover:tw-text-blue-600"})]}));var tl=(e=>(e[e.Check=0]="Check",e[e.Radio=1]="Radio",e))(tl||{});function jm({id:e,groups:t}){return a.jsx("div",{id:e,children:a.jsxs(or,{children:[a.jsx(lo,{asChild:!0,children:a.jsx(el,{})}),a.jsx(En,{children:t.map(n=>a.jsxs("div",{children:[a.jsx(Wt,{children:n.label}),a.jsx(cs,{children:n.items.map(r=>a.jsx("div",{children:r.itemType===0?a.jsx(ar,{onClick:r.onClick,children:r.label}):a.jsx(uo,{onClick:r.onClick,value:r.label,children:r.label})},r.label))}),a.jsx(jn,{})]},n.label))})]})})}function Cm({id:e,message:t}){return a.jsx("div",{id:e,className:"tw-mb-20 tw-mt-20 tw-flex tw-items-center tw-justify-center",children:a.jsx("div",{className:"tw-w-3/4 tw-rounded-lg tw-bg-gray-100 tw-p-8 tw-text-center",children:a.jsx("p",{className:"tw-text-lg tw-text-gray-800",children:t})})})}function Tm({id:e,category:t,downloads:n,languages:r,moreInfoUrl:o}){const s=new W.NumberFormat("en",{notation:"compact",compactDisplay:"short"}).format(Object.values(n).reduce((l,c)=>l+c,0)),i=()=>{window.scrollTo(0,document.body.scrollHeight)};return a.jsxs("div",{id:e,className:"tw-flex tw-flex-wrap tw-items-start tw-space-x-4 tw-border-b tw-border-t tw-bg-white tw-pb-4 tw-pt-4",children:[a.jsxs("div",{className:"tw-flex tw-flex-col tw-items-center",children:[a.jsx("div",{className:"tw-flex tw-items-center tw-rounded-md tw-bg-gray-100 tw-px-2 tw-py-1",children:a.jsx("span",{className:"tw-text-xs tw-font-semibold tw-text-gray-700",children:t})}),a.jsx("span",{className:"tw-text-xs tw-text-gray-500",children:"CATEGORY"})]}),a.jsx("div",{className:"tw-mx-2 tw-h-10 tw-border-l tw-border-gray-300"}),a.jsxs("div",{className:"tw-flex tw-flex-col tw-items-center",children:[a.jsxs("div",{className:"tw-flex tw-items-center tw-rounded-md tw-bg-gray-100 tw-px-2 tw-py-1",children:[a.jsx(Q.User,{className:"tw-mr-1 tw-h-4 tw-w-4"}),a.jsx("span",{className:"tw-text-xs tw-font-semibold tw-text-gray-700",children:s})]}),a.jsx("span",{className:"tw-text-xs tw-text-gray-500",children:"USERS"})]}),a.jsx("div",{className:"tw-mx-2 tw-h-10 tw-border-l tw-border-gray-300"}),a.jsxs("div",{className:"tw-flex tw-flex-col tw-items-center",children:[a.jsx("div",{className:"tw-flex tw-items-center",children:r.slice(0,3).map(l=>a.jsx("span",{className:"tw-ml-1 tw-rounded-md tw-bg-gray-100 tw-px-2 tw-py-1 tw-text-xs tw-font-semibold tw-text-gray-700",children:l.toUpperCase()},l))}),r.length>3&&a.jsxs("button",{type:"button",onClick:()=>i(),className:"tw-text-xs tw-text-gray-500 tw-underline",children:["+",r.length-3," more languages"]})]}),a.jsx("div",{className:"tw-mx-2 tw-h-10 tw-border-l tw-border-gray-300"}),a.jsxs("div",{className:"tw-ml-auto tw-flex tw-flex-col tw-space-y-2",children:[a.jsxs("a",{href:o,target:"_blank",rel:"noreferrer",className:"tw-flex tw-items-center tw-text-xs tw-font-semibold tw-text-gray-500 tw-underline",children:["Website",a.jsx(Q.Link,{className:"tw-ml-1 tw-inline tw-h-4 tw-w-4"})]}),a.jsxs("a",{href:"https://example.com",target:"_blank",rel:"noreferrer",className:"tw-flex tw-items-center tw-text-xs tw-font-semibold tw-text-gray-500 tw-underline",children:["Support",a.jsx(Q.CircleHelp,{className:"tw-ml-1 tw-inline tw-h-4 tw-w-4"})]})]})]})}function nl({id:e,versionHistory:t}){const[n,r]=g.useState(!1),o=new Date;function s(l){const c=new Date(l),u=new Date(o.getTime()-c.getTime()),d=u.getUTCFullYear()-1970,m=u.getUTCMonth(),w=u.getUTCDate()-1;let b="";return d>0?b=`${d.toString()} year${d===1?"":"s"} ago`:m>0?b=`${m.toString()} month${m===1?"":"s"} ago`:w===0?b="today":b=`${w.toString()} day${w===1?"":"s"} ago`,b}const i=Object.entries(t).sort((l,c)=>c[0].localeCompare(l[0]));return a.jsxs("div",{id:e,children:[a.jsx("h3",{className:"tw-text-md tw-font-semibold",children:"What`s New"}),a.jsx("ul",{className:"tw-list-disc tw-pl-5 tw-pr-4 tw-text-xs tw-text-gray-600",children:(n?i:i.slice(0,5)).map(l=>a.jsxs("div",{className:"tw-mt-3 tw-flex tw-justify-between",children:[a.jsx("div",{className:"tw-text-gray-600",children:a.jsx("li",{className:"tw-prose tw-text-xs",children:a.jsx("span",{children:l[1].description})})}),a.jsxs("div",{className:"tw-justify-end tw-text-right",children:[a.jsxs("div",{children:["Version ",l[0]]}),a.jsx("div",{children:s(l[1].date)})]})]},l[0]))}),i.length>5&&a.jsx("button",{type:"button",onClick:()=>r(!n),className:"tw-text-xs tw-text-gray-500 tw-underline",children:n?"Show Less Version History":"Show All Version History"})]})}function Rm({id:e,publisherDisplayName:t,fileSize:n,locales:r,versionHistory:o}){const s=g.useMemo(()=>W.formatBytes(n),[n]),l=(c=>{const u=new Intl.DisplayNames(navigator.language,{type:"language"});return c.map(d=>u.of(d))})(r);return a.jsx("div",{id:e,className:"tw-border-t tw-pb-4 tw-pt-4",children:a.jsxs("div",{className:"tw-md:flex-row tw-md:space-x-8 tw-flex tw-flex-col tw-space-x-0",children:[a.jsx(nl,{versionHistory:o}),a.jsx("div",{className:"tw-md:border-t-0 tw-md:border-l tw-md-h-auto tw-md-ml-8 tw-mt-4 tw-border-t tw-border-gray-300"}),a.jsxs("div",{className:"tw-md:mt-0 tw-mt-4 tw-flex-1 tw-space-y-3",children:[a.jsx("h2",{className:"tw-text-md tw-font-semibold",children:"Information"}),a.jsxs("div",{className:"tw-flex tw-items-start tw-justify-between tw-pr-4 tw-text-xs tw-text-gray-600",children:[a.jsxs("p",{className:"tw-flex tw-flex-col tw-justify-start",children:[a.jsx("span",{className:"tw-mb-2",children:"Publisher"}),a.jsx("span",{className:"tw-font-semibold",children:t}),a.jsx("span",{className:"tw-mb-2 tw-mt-4",children:"Size"}),a.jsx("span",{className:"tw-font-semibold",children:s})]}),a.jsx("div",{className:"tw-flex tw-w-3/4 tw-items-center tw-justify-between tw-text-xs tw-text-gray-600",children:a.jsxs("p",{className:"tw-flex tw-flex-col tw-justify-start",children:[a.jsx("span",{className:"tw-mb-2",children:"Languages"}),a.jsx("span",{className:"tw-font-semibold",children:l.join(", ")})]})})]})]})]})})}const Om=(e,t)=>{g.useEffect(()=>{if(!e)return()=>{};const n=e(t);return()=>{n()}},[e,t])},Fr=()=>!1,_m=(e,t)=>{const[n]=nr(g.useCallback(async()=>{if(!e)return Fr;const r=await Promise.resolve(e(t));return async()=>r()},[t,e]),Fr,{preserveValue:!1});g.useEffect(()=>()=>{n!==Fr&&n()},[n])};Object.defineProperty(exports,"sonner",{enumerable:!0,get:()=>Qa.toast});exports.Alert=zi;exports.AlertDescription=Fi;exports.AlertTitle=Li;exports.BOOK_SELECTOR_STRING_KEYS=mc;exports.BookChapterControl=oc;exports.BookSelectionMode=Ns;exports.BookSelector=hc;exports.Button=fe;exports.Card=Gi;exports.CardContent=Xi;exports.CardDescription=Hi;exports.CardFooter=Yi;exports.CardHeader=Ui;exports.CardTitle=qi;exports.ChapterRangeSelector=ys;exports.Checkbox=sr;exports.Checklist=bd;exports.ComboBox=Wn;exports.DataTable=Ts;exports.DisableButton=km;exports.DropdownMenu=or;exports.DropdownMenuCheckboxItem=ar;exports.DropdownMenuContent=En;exports.DropdownMenuGroup=cs;exports.DropdownMenuItem=co;exports.DropdownMenuItemType=tl;exports.DropdownMenuLabel=Wt;exports.DropdownMenuPortal=ql;exports.DropdownMenuRadioGroup=Xl;exports.DropdownMenuRadioItem=uo;exports.DropdownMenuSeparator=jn;exports.DropdownMenuShortcut=ps;exports.DropdownMenuSub=Hl;exports.DropdownMenuSubContent=us;exports.DropdownMenuSubTrigger=ds;exports.DropdownMenuTrigger=lo;exports.EnableButton=Nm;exports.FilterButton=el;exports.FilterDropdown=jm;exports.Footer=Rm;exports.GridMenu=Bi;exports.HamburgerMenuButton=Vi;exports.INVENTORY_STRING_KEYS=Ec;exports.IconButton=mm;exports.Input=St;exports.InstallButton=ym;exports.Inventory=Tc;exports.Label=qe;exports.MarkdownRenderer=Em;exports.MenuItem=Fo;exports.MoreInfo=Tm;exports.NavigationContentSearch=Rc;exports.NoExtensionsFound=Cm;exports.RadioGroup=po;exports.RadioGroupItem=Yn;exports.ScriptureResultsViewer=wd;exports.ScrollGroupSelector=fd;exports.SearchBar=ho;exports.Select=At;exports.SelectContent=vt;exports.SelectGroup=ks;exports.SelectItem=Ae;exports.SelectLabel=Ss;exports.SelectScrollDownButton=fo;exports.SelectScrollUpButton=wo;exports.SelectSeparator=Es;exports.SelectTrigger=bt;exports.SelectValue=Bt;exports.Separator=lr;exports.SettingsList=md;exports.SettingsListHeader=gd;exports.SettingsListItem=hd;exports.SettingsSidebar=Hs;exports.SettingsSidebarContentSearch=ad;exports.Slider=Wi;exports.Sonner=vm;exports.Spinner=Kt;exports.Switch=Ki;exports.Table=Cn;exports.TableBody=Rn;exports.TableCaption=Cs;exports.TableCell=xt;exports.TableFooter=js;exports.TableHead=Vt;exports.TableHeader=Tn;exports.TableRow=Ze;exports.Tabs=xm;exports.TabsContent=Qi;exports.TabsList=Ji;exports.TabsTrigger=Zi;exports.TextField=hm;exports.ToggleGroup=mo;exports.ToggleGroupItem=fn;exports.Toolbar=gm;exports.UpdateButton=Sm;exports.VersionHistory=nl;exports.VerticalTabs=go;exports.VerticalTabsContent=vo;exports.VerticalTabsList=bo;exports.VerticalTabsTrigger=Ms;exports.buttonVariants=ws;exports.cn=N;exports.getBookNumFromId=Os;exports.getLinesFromUSFM=Rs;exports.getNumberFromUSFM=Hr;exports.getStatusForItem=_s;exports.inventoryCountColumn=kc;exports.inventoryItemColumn=yc;exports.inventoryStatusColumn=Sc;exports.useEvent=Om;exports.useEventAsync=_m;exports.usePromise=nr;function Pm(e,t="top"){if(!e||typeof document>"u")return;const n=document.head||document.querySelector("head"),r=n.querySelector(":first-child"),o=document.createElement("style");o.appendChild(document.createTextNode(e)),t==="top"&&r?n.insertBefore(o,r):n.appendChild(o)}Pm(`*, ::before, ::after { +`));const dl=M.useMemo(()=>{var ee;let _e=[{name:"arrow",enabled:!!Ue,options:{element:Ue,padding:4}}];return(ee=G.popperOptions)!=null&&ee.modifiers&&(_e=_e.concat(G.popperOptions.modifiers)),O({},G.popperOptions,{modifiers:_e})},[Ue,G]),tn=O({},P,{isRtl:lt,arrow:V,disableInteractive:jt,placement:q,PopperComponentProp:H,touch:ct.current}),Cr=om(tn),Qo=(r=(o=Z.popper)!=null?o:C.Popper)!=null?r:am,ea=(s=(i=(l=Z.transition)!=null?l:C.Transition)!=null?i:I)!=null?s:Wa,ta=(c=(d=Z.tooltip)!=null?d:C.Tooltip)!=null?c:sm,na=(u=(f=Z.arrow)!=null?f:C.Arrow)!=null?u:im,ul=un(Qo,O({},G,(w=K.popper)!=null?w:_.popper,{className:ot(Cr.popper,G==null?void 0:G.className,(b=(x=K.popper)!=null?x:_.popper)==null?void 0:b.className)}),tn),pl=un(ea,O({},ye,(m=K.transition)!=null?m:_.transition),tn),wl=un(ta,O({},(h=K.tooltip)!=null?h:_.tooltip,{className:ot(Cr.tooltip,(S=(R=K.tooltip)!=null?R:_.tooltip)==null?void 0:S.className)}),tn),fl=un(na,O({},(j=K.arrow)!=null?j:_.arrow,{className:ot(Cr.arrow,(E=(v=K.arrow)!=null?v:_.arrow)==null?void 0:E.className)}),tn);return a.jsxs(M.Fragment,{children:[M.cloneElement(xe,De),a.jsx(Qo,O({as:H??Mi,placement:q,anchorEl:oe?{getBoundingClientRect:()=>({top:sn.y,left:sn.x,right:sn.x,bottom:sn.y,width:0,height:0})}:Ee,popperRef:Er,open:Ee?Ke:!1,id:kr,transition:!0},en,ul,{popperOptions:dl,children:({TransitionProps:ee})=>a.jsx(ea,O({timeout:Ge.transitions.duration.shorter},ee,pl,{children:a.jsxs(ta,O({},wl,{children:[ue,V?a.jsx(na,O({},fl,{ref:Et})):null]}))}))}))]})});process.env.NODE_ENV!=="production"&&($i.propTypes={arrow:p.bool,children:ei.isRequired,classes:p.object,className:p.string,components:p.shape({Arrow:p.elementType,Popper:p.elementType,Tooltip:p.elementType,Transition:p.elementType}),componentsProps:p.shape({arrow:p.object,popper:p.object,tooltip:p.object,transition:p.object}),describeChild:p.bool,disableFocusListener:p.bool,disableHoverListener:p.bool,disableInteractive:p.bool,disableTouchListener:p.bool,enterDelay:p.number,enterNextDelay:p.number,enterTouchDelay:p.number,followCursor:p.bool,id:p.string,leaveDelay:p.number,leaveTouchDelay:p.number,onClose:p.func,onOpen:p.func,open:p.bool,placement:p.oneOf(["bottom-end","bottom-start","bottom","left-end","left-start","left","right-end","right-start","right","top-end","top-start","top"]),PopperComponent:p.elementType,PopperProps:p.object,slotProps:p.shape({arrow:p.object,popper:p.object,tooltip:p.object,transition:p.object}),slots:p.shape({arrow:p.elementType,popper:p.elementType,tooltip:p.elementType,transition:p.elementType}),sx:p.oneOfType([p.arrayOf(p.oneOfType([p.func,p.object,p.bool])),p.func,p.object]),title:p.node,TransitionComponent:p.elementType,TransitionProps:p.object});const lm=$i;function Ja(e,t,n){return e?a.jsx(Me.ListItemIcon,{className:`papi-menu-icon-${n?"leading":"trailing"}`,children:a.jsx("img",{src:e,alt:`${n?"Leading":"Trailing"} icon for ${t}`})}):void 0}function Fo(e){const{onClick:t,label:n,tooltip:r,allowForLeadingIcons:o=!0,iconPathBefore:s=void 0,iconPathAfter:i=void 0,hasAutoFocus:l=!1,className:c,isDisabled:d=!1,isDense:u=!0,isSubMenuParent:f=!1,hasDisabledGutters:w=!1,hasDivider:b=!1,focusVisibleClassName:x,id:m,children:h}=e,S=a.jsx(Me.MenuItem,{sx:{lineHeight:.8},autoFocus:l,className:c,disabled:d,dense:u,disableGutters:w,divider:b,focusVisibleClassName:x,onClick:t,id:m,children:n?a.jsxs(a.Fragment,{children:[Ja(s,n,!0),a.jsx(Me.ListItemText,{primary:n,inset:!s&&o}),f?a.jsx(Me.ListItemIcon,{className:"papi-menu-icon-trailing",children:a.jsx(gi,{})}):Ja(i,n,!1)]}):h});return r?a.jsx(lm,{title:r,placement:"right",children:a.jsx("div",{children:S})}):S}function Di(e){return Object.entries(e.groups).map(([n,r])=>({id:n,group:r}))}function cm(e){const[t,n]=g.useState(void 0),{parentMenuItem:r,parentItemProps:o,menuDefinition:s}=e,i=d=>{n(d.currentTarget)},l=()=>{n(void 0)},c=()=>{let d=Di(s).filter(u=>"menuItem"in u.group);if(!(r!=null&&r.id))throw new Error("A valid parent menu item is required for submenus.");return d=d.filter(u=>"menuItem"in u.group&&u.group.menuItem===r.id),a.jsx(Ai,{...e,includedGroups:d})};return a.jsxs(a.Fragment,{children:[a.jsx(Fo,{onClick:i,...o,isSubMenuParent:!0}),a.jsx(Me.Menu,{anchorEl:t,open:!!t,onClose:l,anchorOrigin:{vertical:"top",horizontal:"right"},transformOrigin:{vertical:"top",horizontal:"left"},children:c()},r.id)]})}const dm=(e,t)=>t.filter(o=>o.group===e).sort((o,s)=>(o.order||0)-(s.order||0));function Ai(e){const{menuDefinition:t,onClick:n,commandHandler:r,includedGroups:o}=e,{items:s,allowForLeadingIcons:i}=g.useMemo(()=>{const u=o&&o.length>0?o:Di(t).filter(x=>!("menuItem"in x.group)),f=Object.values(u).sort((x,m)=>(x.group.order||0)-(m.group.order||0)),w=[];f.forEach(x=>{dm(x.id,t.items).forEach(m=>w.push({item:m,isLastItemInGroup:!1})),w.length>0&&(w[w.length-1].isLastItemInGroup=!0)}),w.length>0&&(w[w.length-1].isLastItemInGroup=!1);const b=w.some(x=>"iconPathBefore"in x.item&&x.item.iconPathBefore);return{items:w,allowForLeadingIcons:b}},[o,t]),l=({item:u,isLastItemInGroup:f})=>({className:"papi-menu-item",label:u.label,tooltip:u.tooltip,iconPathBefore:"iconPathBefore"in u?u.iconPathBefore:void 0,iconPathAfter:"iconPathAfter"in u?u.iconPathAfter:void 0,hasDivider:f,allowForLeadingIcons:i}),[c]=s;if(!c)return a.jsx("div",{});const d=c.item.group;return a.jsx("div",{role:"menu","aria-label":d,children:s.map((u,f)=>{const{item:w}=u,b=l(u);if("command"in w){const x=w.group+f;return a.jsx(Fo,{onClick:m=>{n==null||n(m),r(w)},...b},x)}return a.jsx(cm,{parentMenuItem:w,parentItemProps:b,...e},d+w.id)})},d)}function um(e){const{menuDefinition:t,columnId:n}=e;let s=Object.entries(t.groups).map(([i,l])=>({id:i,group:l})).filter(i=>"column"in i.group);return n&&"columns"in t&&t.columns[n]&&(s=s.filter(i=>"column"in i.group&&i.group.column===n)),a.jsx(Ai,{...e,includedGroups:s})}function pm({commandHandler:e,menuDefinition:t,id:n,metadata:r,onClick:o,className:s}){return a.jsxs(Me.Grid,{id:n,item:!0,xs:"auto",role:"menu","aria-label":n,className:`papi-menu-column ${s??""}`,children:[a.jsx("h3",{"aria-label":r.label,className:`papi-menu-column-header ${s??""}`,children:r.label}),a.jsx(Me.List,{id:n,dense:!0,className:s??"",children:a.jsx(um,{commandHandler:e,menuDefinition:t,columnId:n,onClick:o})})]})}function Bi({commandHandler:e,className:t,multiColumnMenu:n,id:r}){const{columns:o}=n,s=g.useMemo(()=>{const i=new Map;return Object.getOwnPropertyNames(o).forEach(l=>{if(l==="isExtensible")return;const c=l,d=o[c];typeof d=="object"&&typeof d.order=="number"&&!Number.isNaN(d.order)?i.set(d.order,{id:c,metadata:d}):console.warn(`Property ${l} (${typeof d}) on menu ${r} is not a valid column and is being ignored. This might indicate data corruption`)}),Array.from(i.values()).sort((l,c)=>(l.metadata.order||0)-(c.metadata.order||0))},[o,r]);return a.jsx(Me.Grid,{container:!0,spacing:0,className:`papi-multi-column-menu ${t??""}`,columns:s.length,role:"menu","aria-label":"GridMenu",id:r,children:s.map((i,l)=>a.jsx(pm,{commandHandler:e,menuDefinition:n,...i,className:t},l))})}function wm(e){return{preserveValue:!0,...e}}const nr=(e,t,n={})=>{const r=g.useRef(t);r.current=t;const o=g.useRef(n);o.current=wm(o.current);const[s,i]=g.useState(()=>r.current),[l,c]=g.useState(!0);return g.useEffect(()=>{let d=!0;return c(!!e),(async()=>{if(e){const u=await e();d&&(i(()=>u),c(!1))}})(),()=>{d=!1,o.current.preserveValue||i(()=>r.current)}},[e]),[s,l]},fm=hi(a.jsx("path",{d:"M3 18h18v-2H3zm0-5h18v-2H3zm0-7v2h18V6z"}),"Menu");function Vi({menuProvider:e,normalMenu:t,fullMenu:n,commandHandler:r,containerRef:o,className:s,ariaLabelPrefix:i,children:l}){const[c,d]=g.useState(!1),[u,f]=g.useState(!1),w=g.useCallback(()=>{c&&d(!1),f(!1)},[c]),b=g.useCallback(E=>{E.stopPropagation(),d(v=>{const P=!v;return P&&E.shiftKey?f(!0):P||f(!1),P})},[]),x=g.useCallback(E=>(w(),r(E)),[r,w]),[m,h]=g.useState({top:1,left:1});g.useEffect(()=>{if(c){const E=o==null?void 0:o.current;if(E){const v=E.getBoundingClientRect(),P=window.scrollY,V=window.scrollX,U=v.top+P+E.clientHeight,C=v.left+V;h({top:U,left:C})}}},[c,o]);const[S]=nr(g.useCallback(async()=>(e==null?void 0:e(!1))??t,[e,t,c]),t),[R]=nr(g.useCallback(async()=>(e==null?void 0:e(!0))??n??S,[e,n,S,c]),n??S),j=u&&R?R:S;return a.jsxs(a.Fragment,{children:[a.jsx(Me.IconButton,{sx:{paddingTop:0,paddingBottom:0},edge:"start",className:`papi-menuButton ${s??""}`,color:"inherit","aria-label":`${i??""} menu button`,onClick:b,children:l??a.jsx(fm,{})}),a.jsx(Me.Drawer,{className:`papi-menu-drawer ${s??""}`,anchor:"left",variant:"temporary",open:c,onClose:w,PaperProps:{className:"papi-menu-drawer-paper",style:{top:m.top,left:m.left}},children:j?a.jsx(Bi,{className:s,id:`${i??""} main menu`,commandHandler:x,multiColumnMenu:j}):void 0})]})}function mm({id:e,label:t,isDisabled:n=!1,tooltip:r,isTooltipSuppressed:o=!1,adjustMarginToAlignToEdge:s=!1,size:i="medium",className:l,onClick:c,children:d}){return a.jsx(Me.IconButton,{id:e,disabled:n,edge:s,size:i,"aria-label":t,title:o?void 0:r??t,className:`papi-icon-button ${l??""}`,onClick:c,children:d})}const Kt=g.forwardRef(({className:e,...t},n)=>a.jsx(Q.LoaderCircle,{size:35,className:N("tw-animate-spin",e),...t,ref:n}));Kt.displayName="Spinner";function hm({id:e,isDisabled:t=!1,hasError:n=!1,isFullWidth:r=!1,helperText:o,label:s,placeholder:i,isRequired:l=!1,className:c,defaultValue:d,value:u,onChange:f,onFocus:w,onBlur:b}){return a.jsxs("div",{className:N("tw-inline-grid tw-items-center tw-gap-1.5",{"tw-w-full":r}),children:[a.jsx(qe,{htmlFor:e,className:N({"tw-text-red-600":n,"tw-hidden":!s}),children:`${s}${l?"*":""}`}),a.jsx(St,{id:e,disabled:t,placeholder:i,required:l,className:N(c,{"tw-border-red-600":n}),defaultValue:d,value:u,onChange:f,onFocus:w,onBlur:b}),a.jsx("p",{className:N({"tw-hidden":!o}),children:o})]})}function gm({menuProvider:e,commandHandler:t,className:n,id:r,children:o}){const s=g.useRef(void 0);return a.jsx("div",{ref:s,style:{position:"relative"},children:a.jsx(Me.AppBar,{position:"static",id:r,children:a.jsxs(Me.Toolbar,{className:N("tw-bg-muted tw-text-muted-foreground",n),variant:"dense",children:[e?a.jsx(Vi,{commandHandler:t,containerRef:s,menuProvider:e}):void 0,o?a.jsx("div",{className:"papi-toolbar-children",children:o}):void 0]})})})}const bm=Xt.cva("tw-relative tw-w-full tw-rounded-lg tw-border tw-p-4 [&>svg~*]:tw-pl-7 [&>svg+div]:tw-translate-y-[-3px] [&>svg]:tw-absolute [&>svg]:tw-left-4 [&>svg]:tw-top-4 [&>svg]:tw-text-foreground",{variants:{variant:{default:"tw-bg-background tw-text-foreground",destructive:"tw-border-destructive/50 tw-text-destructive dark:tw-border-destructive [&>svg]:tw-text-destructive"}},defaultVariants:{variant:"default"}}),zi=g.forwardRef(({className:e,variant:t,...n},r)=>a.jsx("div",{ref:r,role:"alert",className:N(bm({variant:t}),e),...n}));zi.displayName="Alert";const Li=g.forwardRef(({className:e,...t},n)=>a.jsxs("h5",{ref:n,className:N("tw-mb-1 tw-font-medium tw-leading-none tw-tracking-tight",e),...t,children:[t.children," "]}));Li.displayName="AlertTitle";const Fi=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,className:N("tw-text-sm [&_p]:tw-leading-relaxed",e),...t}));Fi.displayName="AlertDescription";const Gi=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,className:N("pr-twp tw-rounded-lg tw-border tw-bg-card tw-text-card-foreground tw-shadow-sm",e),...t}));Gi.displayName="Card";const Ui=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,className:N("pr-twp tw-flex tw-flex-col tw-space-y-1.5 tw-p-6",e),...t}));Ui.displayName="CardHeader";const qi=g.forwardRef(({className:e,...t},n)=>a.jsx("h3",{ref:n,className:N("pr-twp tw-text-2xl tw-font-semibold tw-leading-none tw-tracking-tight",e),...t,children:t.children}));qi.displayName="CardTitle";const Hi=g.forwardRef(({className:e,...t},n)=>a.jsx("p",{ref:n,className:N("pr-twp tw-text-sm tw-text-muted-foreground",e),...t}));Hi.displayName="CardDescription";const Xi=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,className:N("pr-twp tw-p-6 tw-pt-0",e),...t}));Xi.displayName="CardContent";const Yi=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,className:N("pr-twp tw-flex tw-items-center tw-p-6 tw-pt-0",e),...t}));Yi.displayName="CardFooter";function vm({...e}){return a.jsx(Qa.Toaster,{className:"tw-toaster tw-group",toastOptions:{classNames:{toast:"group toast group-[.toaster]:bg-background group-[.toaster]:text-foreground group-[.toaster]:border-border group-[.toaster]:shadow-lg",description:"group-[.toast]:text-muted-foreground",actionButton:"group-[.toast]:bg-primary group-[.toast]:text-primary-foreground",cancelButton:"group-[.toast]:bg-muted group-[.toast]:text-muted-foreground"}},...e})}const Wi=g.forwardRef(({className:e,...t},n)=>a.jsxs(cn.Root,{ref:n,className:N("pr-twp tw-relative tw-flex tw-w-full tw-touch-none tw-select-none tw-items-center",e),...t,children:[a.jsx(cn.Track,{className:"tw-relative tw-h-2 tw-w-full tw-grow tw-overflow-hidden tw-rounded-full tw-bg-secondary",children:a.jsx(cn.Range,{className:"tw-absolute tw-h-full tw-bg-primary"})}),a.jsx(cn.Thumb,{className:"tw-block tw-h-5 tw-w-5 tw-rounded-full tw-border-2 tw-border-primary tw-bg-background tw-ring-offset-background tw-transition-colors focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50"})]}));Wi.displayName=cn.Root.displayName;const Ki=g.forwardRef(({className:e,...t},n)=>a.jsx(qr.Root,{className:N("tw-peer pr-twp tw-inline-flex tw-h-6 tw-w-11 tw-shrink-0 tw-cursor-pointer tw-items-center tw-rounded-full tw-border-2 tw-border-transparent tw-transition-colors focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 focus-visible:tw-ring-offset-background disabled:tw-cursor-not-allowed disabled:tw-opacity-50 data-[state=checked]:tw-bg-primary data-[state=unchecked]:tw-bg-input",e),...t,ref:n,children:a.jsx(qr.Thumb,{className:N("pr-twp tw-pointer-events-none tw-block tw-h-5 tw-w-5 tw-rounded-full tw-bg-background tw-shadow-lg tw-ring-0 tw-transition-transform data-[state=checked]:tw-translate-x-5 data-[state=unchecked]:tw-translate-x-0")})}));Ki.displayName=qr.Root.displayName;const xm=Oe.Root,Ji=g.forwardRef(({className:e,...t},n)=>a.jsx(Oe.List,{ref:n,className:N("tw-inline-flex tw-h-10 tw-items-center tw-justify-center tw-rounded-md tw-bg-muted tw-p-1 tw-text-muted-foreground",e),...t}));Ji.displayName=Oe.List.displayName;const Zi=g.forwardRef(({className:e,...t},n)=>a.jsx(Oe.Trigger,{ref:n,className:N("tw-inline-flex tw-items-center tw-justify-center tw-whitespace-nowrap tw-rounded-sm tw-px-3 tw-py-1.5 tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-all hover:tw-text-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50 data-[state=active]:tw-bg-background data-[state=active]:tw-text-foreground data-[state=active]:tw-shadow-sm",e),...t}));Zi.displayName=Oe.Trigger.displayName;const Qi=g.forwardRef(({className:e,...t},n)=>a.jsx(Oe.Content,{ref:n,className:N("tw-mt-2 tw-ring-offset-background focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2",e),...t}));Qi.displayName=Oe.Content.displayName;function ym({isInstalling:e,handleClick:t,buttonText:n,className:r,...o}){return a.jsx(fe,{className:N("tw-h-8 tw-rounded-md tw-text-white tw-transition tw-duration-300 tw-ease-in-out hover:tw-bg-blue-700",{"tw-cursor-not-allowed tw-bg-blue-700":e,"tw-bg-blue-600":!e,"tw-bg-white tw-text-blue-600 hover:tw-text-white":!n,"tw-w-20":n},r),onClick:t,...o,children:e?a.jsx(Kt,{size:15}):a.jsxs(a.Fragment,{children:[a.jsx(Q.Download,{size:25,className:N("tw-h-4 tw-w-4",{"tw-mr-1":n})}),n]})})}function Nm({isEnabling:e,handleClick:t,className:n,...r}){return a.jsx(fe,{className:N("tw-h-8 tw-rounded-md tw-bg-blue-600 tw-px-4 tw-text-white tw-transition tw-duration-300 tw-ease-in-out hover:tw-bg-blue-700",{"tw-cursor-not-allowed tw-bg-blue-700":e},n),onClick:t,...r,children:e?a.jsxs(a.Fragment,{children:[a.jsx(Kt,{size:15,className:"tw-mr-1 tw-text-white"}),"Enabling..."]}):"Enable"})}function km({isDisabling:e,handleClick:t,className:n,...r}){return a.jsx(fe,{className:N("tw-h-8 tw-rounded-md tw-bg-gray-300 tw-text-black tw-transition tw-duration-300 tw-ease-in-out hover:tw-bg-gray-400",{"tw-cursor-not-allowed tw-bg-gray-400":e},n),onClick:t,...r,children:e?a.jsxs(a.Fragment,{children:[a.jsx(Kt,{size:15,className:"tw-mr-1 tw-text-black"}),"Disabling..."]}):"Disable"})}function Sm({isUpdating:e,handleClick:t,className:n,...r}){return a.jsx(fe,{className:N("tw-h-8 tw-rounded-md tw-bg-blue-600 tw-px-4 tw-text-white tw-transition tw-duration-300 tw-ease-in-out hover:tw-bg-blue-700 hover:tw-text-white",{"tw-cursor-not-allowed tw-bg-blue-700":e},n),onClick:t,...r,children:e?a.jsxs(a.Fragment,{children:[a.jsx(Kt,{size:15,className:"tw-mr-1 tw-text-white"}),"Updating..."]}):"Update"})}function Em({id:e,markdown:t,className:n,anchorTarget:r}){const o=g.useMemo(()=>({overrides:{a:{props:{target:r}}}}),[r]);return a.jsx("div",{id:e,className:N("pr-twp tw-prose",n),children:a.jsx(Rl,{options:o,children:t})})}const el=g.forwardRef((e,t)=>a.jsxs(fe,{ref:t,className:"tw-rounded-md tw-border tw-border-dashed tw-border-gray-400 tw-bg-white tw-px-4 tw-py-2 tw-text-black tw-transition tw-duration-300 tw-ease-in-out hover:tw-border-blue-600 hover:tw-bg-white hover:tw-text-blue-600",...e,children:[a.jsx(Q.Filter,{size:16,className:"tw-mr-2 tw-h-4 tw-w-4 tw-text-gray-700 hover:tw-text-blue-600"}),"Filter",a.jsx(Q.ChevronDown,{size:16,className:"tw-ml-2 tw-h-4 tw-w-4 tw-text-gray-700 hover:tw-text-blue-600"})]}));var tl=(e=>(e[e.Check=0]="Check",e[e.Radio=1]="Radio",e))(tl||{});function jm({id:e,groups:t}){return a.jsx("div",{id:e,children:a.jsxs(or,{children:[a.jsx(lo,{asChild:!0,children:a.jsx(el,{})}),a.jsx(En,{children:t.map(n=>a.jsxs("div",{children:[a.jsx(Wt,{children:n.label}),a.jsx(cs,{children:n.items.map(r=>a.jsx("div",{children:r.itemType===0?a.jsx(ar,{onClick:r.onClick,children:r.label}):a.jsx(uo,{onClick:r.onClick,value:r.label,children:r.label})},r.label))}),a.jsx(jn,{})]},n.label))})]})})}function Cm({id:e,message:t}){return a.jsx("div",{id:e,className:"tw-mb-20 tw-mt-20 tw-flex tw-items-center tw-justify-center",children:a.jsx("div",{className:"tw-w-3/4 tw-rounded-lg tw-bg-gray-100 tw-p-8 tw-text-center",children:a.jsx("p",{className:"tw-text-lg tw-text-gray-800",children:t})})})}function Tm({id:e,category:t,downloads:n,languages:r,moreInfoUrl:o}){const s=new W.NumberFormat("en",{notation:"compact",compactDisplay:"short"}).format(Object.values(n).reduce((l,c)=>l+c,0)),i=()=>{window.scrollTo(0,document.body.scrollHeight)};return a.jsxs("div",{id:e,className:"tw-flex tw-flex-wrap tw-items-start tw-space-x-4 tw-border-b tw-border-t tw-bg-white tw-pb-4 tw-pt-4",children:[a.jsxs("div",{className:"tw-flex tw-flex-col tw-items-center",children:[a.jsx("div",{className:"tw-flex tw-items-center tw-rounded-md tw-bg-gray-100 tw-px-2 tw-py-1",children:a.jsx("span",{className:"tw-text-xs tw-font-semibold tw-text-gray-700",children:t})}),a.jsx("span",{className:"tw-text-xs tw-text-gray-500",children:"CATEGORY"})]}),a.jsx("div",{className:"tw-mx-2 tw-h-10 tw-border-l tw-border-gray-300"}),a.jsxs("div",{className:"tw-flex tw-flex-col tw-items-center",children:[a.jsxs("div",{className:"tw-flex tw-items-center tw-rounded-md tw-bg-gray-100 tw-px-2 tw-py-1",children:[a.jsx(Q.User,{className:"tw-mr-1 tw-h-4 tw-w-4"}),a.jsx("span",{className:"tw-text-xs tw-font-semibold tw-text-gray-700",children:s})]}),a.jsx("span",{className:"tw-text-xs tw-text-gray-500",children:"USERS"})]}),a.jsx("div",{className:"tw-mx-2 tw-h-10 tw-border-l tw-border-gray-300"}),a.jsxs("div",{className:"tw-flex tw-flex-col tw-items-center",children:[a.jsx("div",{className:"tw-flex tw-items-center",children:r.slice(0,3).map(l=>a.jsx("span",{className:"tw-ml-1 tw-rounded-md tw-bg-gray-100 tw-px-2 tw-py-1 tw-text-xs tw-font-semibold tw-text-gray-700",children:l.toUpperCase()},l))}),r.length>3&&a.jsxs("button",{type:"button",onClick:()=>i(),className:"tw-text-xs tw-text-gray-500 tw-underline",children:["+",r.length-3," more languages"]})]}),a.jsx("div",{className:"tw-mx-2 tw-h-10 tw-border-l tw-border-gray-300"}),a.jsxs("div",{className:"tw-ml-auto tw-flex tw-flex-col tw-space-y-2",children:[a.jsxs("a",{href:o,target:"_blank",rel:"noreferrer",className:"tw-flex tw-items-center tw-text-xs tw-font-semibold tw-text-gray-500 tw-underline",children:["Website",a.jsx(Q.Link,{className:"tw-ml-1 tw-inline tw-h-4 tw-w-4"})]}),a.jsxs("a",{href:"https://example.com",target:"_blank",rel:"noreferrer",className:"tw-flex tw-items-center tw-text-xs tw-font-semibold tw-text-gray-500 tw-underline",children:["Support",a.jsx(Q.CircleHelp,{className:"tw-ml-1 tw-inline tw-h-4 tw-w-4"})]})]})]})}function nl({id:e,versionHistory:t}){const[n,r]=g.useState(!1),o=new Date;function s(l){const c=new Date(l),d=new Date(o.getTime()-c.getTime()),u=d.getUTCFullYear()-1970,f=d.getUTCMonth(),w=d.getUTCDate()-1;let b="";return u>0?b=`${u.toString()} year${u===1?"":"s"} ago`:f>0?b=`${f.toString()} month${f===1?"":"s"} ago`:w===0?b="today":b=`${w.toString()} day${w===1?"":"s"} ago`,b}const i=Object.entries(t).sort((l,c)=>c[0].localeCompare(l[0]));return a.jsxs("div",{id:e,children:[a.jsx("h3",{className:"tw-text-md tw-font-semibold",children:"What`s New"}),a.jsx("ul",{className:"tw-list-disc tw-pl-5 tw-pr-4 tw-text-xs tw-text-gray-600",children:(n?i:i.slice(0,5)).map(l=>a.jsxs("div",{className:"tw-mt-3 tw-flex tw-justify-between",children:[a.jsx("div",{className:"tw-text-gray-600",children:a.jsx("li",{className:"tw-prose tw-text-xs",children:a.jsx("span",{children:l[1].description})})}),a.jsxs("div",{className:"tw-justify-end tw-text-right",children:[a.jsxs("div",{children:["Version ",l[0]]}),a.jsx("div",{children:s(l[1].date)})]})]},l[0]))}),i.length>5&&a.jsx("button",{type:"button",onClick:()=>r(!n),className:"tw-text-xs tw-text-gray-500 tw-underline",children:n?"Show Less Version History":"Show All Version History"})]})}function Rm({id:e,publisherDisplayName:t,fileSize:n,locales:r,versionHistory:o}){const s=g.useMemo(()=>W.formatBytes(n),[n]),l=(c=>{const d=new Intl.DisplayNames(navigator.language,{type:"language"});return c.map(u=>d.of(u))})(r);return a.jsx("div",{id:e,className:"tw-border-t tw-pb-4 tw-pt-4",children:a.jsxs("div",{className:"tw-md:flex-row tw-md:space-x-8 tw-flex tw-flex-col tw-space-x-0",children:[a.jsx(nl,{versionHistory:o}),a.jsx("div",{className:"tw-md:border-t-0 tw-md:border-l tw-md-h-auto tw-md-ml-8 tw-mt-4 tw-border-t tw-border-gray-300"}),a.jsxs("div",{className:"tw-md:mt-0 tw-mt-4 tw-flex-1 tw-space-y-3",children:[a.jsx("h2",{className:"tw-text-md tw-font-semibold",children:"Information"}),a.jsxs("div",{className:"tw-flex tw-items-start tw-justify-between tw-pr-4 tw-text-xs tw-text-gray-600",children:[a.jsxs("p",{className:"tw-flex tw-flex-col tw-justify-start",children:[a.jsx("span",{className:"tw-mb-2",children:"Publisher"}),a.jsx("span",{className:"tw-font-semibold",children:t}),a.jsx("span",{className:"tw-mb-2 tw-mt-4",children:"Size"}),a.jsx("span",{className:"tw-font-semibold",children:s})]}),a.jsx("div",{className:"tw-flex tw-w-3/4 tw-items-center tw-justify-between tw-text-xs tw-text-gray-600",children:a.jsxs("p",{className:"tw-flex tw-flex-col tw-justify-start",children:[a.jsx("span",{className:"tw-mb-2",children:"Languages"}),a.jsx("span",{className:"tw-font-semibold",children:l.join(", ")})]})})]})]})]})})}const Om=(e,t)=>{g.useEffect(()=>{if(!e)return()=>{};const n=e(t);return()=>{n()}},[e,t])},Fr=()=>!1,_m=(e,t)=>{const[n]=nr(g.useCallback(async()=>{if(!e)return Fr;const r=await Promise.resolve(e(t));return async()=>r()},[t,e]),Fr,{preserveValue:!1});g.useEffect(()=>()=>{n!==Fr&&n()},[n])};Object.defineProperty(exports,"sonner",{enumerable:!0,get:()=>Qa.toast});exports.Alert=zi;exports.AlertDescription=Fi;exports.AlertTitle=Li;exports.BOOK_SELECTOR_STRING_KEYS=mc;exports.BookChapterControl=oc;exports.BookSelectionMode=Ns;exports.BookSelector=hc;exports.Button=fe;exports.Card=Gi;exports.CardContent=Xi;exports.CardDescription=Hi;exports.CardFooter=Yi;exports.CardHeader=Ui;exports.CardTitle=qi;exports.ChapterRangeSelector=ys;exports.Checkbox=sr;exports.Checklist=bd;exports.ComboBox=Wn;exports.DataTable=Ts;exports.DisableButton=km;exports.DropdownMenu=or;exports.DropdownMenuCheckboxItem=ar;exports.DropdownMenuContent=En;exports.DropdownMenuGroup=cs;exports.DropdownMenuItem=co;exports.DropdownMenuItemType=tl;exports.DropdownMenuLabel=Wt;exports.DropdownMenuPortal=ql;exports.DropdownMenuRadioGroup=Xl;exports.DropdownMenuRadioItem=uo;exports.DropdownMenuSeparator=jn;exports.DropdownMenuShortcut=ps;exports.DropdownMenuSub=Hl;exports.DropdownMenuSubContent=us;exports.DropdownMenuSubTrigger=ds;exports.DropdownMenuTrigger=lo;exports.EnableButton=Nm;exports.FilterButton=el;exports.FilterDropdown=jm;exports.Footer=Rm;exports.GridMenu=Bi;exports.HamburgerMenuButton=Vi;exports.INVENTORY_STRING_KEYS=Ec;exports.IconButton=mm;exports.Input=St;exports.InstallButton=ym;exports.Inventory=Tc;exports.Label=qe;exports.MarkdownRenderer=Em;exports.MenuItem=Fo;exports.MoreInfo=Tm;exports.NavigationContentSearch=Rc;exports.NoExtensionsFound=Cm;exports.RadioGroup=po;exports.RadioGroupItem=Yn;exports.ScriptureResultsViewer=wd;exports.ScrollGroupSelector=fd;exports.SearchBar=ho;exports.Select=At;exports.SelectContent=vt;exports.SelectGroup=ks;exports.SelectItem=Ae;exports.SelectLabel=Ss;exports.SelectScrollDownButton=fo;exports.SelectScrollUpButton=wo;exports.SelectSeparator=Es;exports.SelectTrigger=bt;exports.SelectValue=Bt;exports.Separator=lr;exports.SettingsList=md;exports.SettingsListHeader=gd;exports.SettingsListItem=hd;exports.SettingsSidebar=Hs;exports.SettingsSidebarContentSearch=ad;exports.Slider=Wi;exports.Sonner=vm;exports.Spinner=Kt;exports.Switch=Ki;exports.Table=Cn;exports.TableBody=Rn;exports.TableCaption=Cs;exports.TableCell=xt;exports.TableFooter=js;exports.TableHead=Vt;exports.TableHeader=Tn;exports.TableRow=Ze;exports.Tabs=xm;exports.TabsContent=Qi;exports.TabsList=Ji;exports.TabsTrigger=Zi;exports.TextField=hm;exports.ToggleGroup=mo;exports.ToggleGroupItem=fn;exports.Toolbar=gm;exports.UpdateButton=Sm;exports.VersionHistory=nl;exports.VerticalTabs=go;exports.VerticalTabsContent=vo;exports.VerticalTabsList=bo;exports.VerticalTabsTrigger=Ms;exports.buttonVariants=ws;exports.cn=N;exports.getBookNumFromId=Os;exports.getLinesFromUSFM=Rs;exports.getNumberFromUSFM=Hr;exports.getStatusForItem=_s;exports.inventoryCountColumn=kc;exports.inventoryItemColumn=yc;exports.inventoryStatusColumn=Sc;exports.useEvent=Om;exports.useEventAsync=_m;exports.usePromise=nr;function Pm(e,t="top"){if(!e||typeof document>"u")return;const n=document.head||document.querySelector("head"),r=n.querySelector(":first-child"),o=document.createElement("style");o.appendChild(document.createTextNode(e)),t==="top"&&r?n.insertBefore(o,r):n.appendChild(o)}Pm(`*, ::before, ::after { --tw-border-spacing-x: 0; --tw-border-spacing-y: 0; --tw-translate-x: 0; @@ -3593,32 +3593,6 @@ video:where(.pr-twp,.pr-twp *) { .banded-row[data-state='selected']:hover { cursor: default; } -.papi-icon-button { - border: 0; - border-radius: 3em; - cursor: pointer; - display: inline-block; -} - -.papi-icon-button.primary { - background-color: #1ea7fd; - color: white; -} - -.papi-icon-button.secondary { - background-color: transparent; - color: #333; -} - -.papi-icon-button.paratext { - background-color: darkgreen; - color: greenyellow; -} - -.papi-icon-button.paratext.bright { - background-color: greenyellow; - color: darkgreen; -} .papi-multi-column-menu { background-color: rgb(222, 222, 222); display: flex; @@ -3653,6 +3627,32 @@ video:where(.pr-twp,.pr-twp *) { color: rgb(76, 106, 76); background-color: rgb(214, 255, 152); } +.papi-icon-button { + border: 0; + border-radius: 3em; + cursor: pointer; + display: inline-block; +} + +.papi-icon-button.primary { + background-color: #1ea7fd; + color: white; +} + +.papi-icon-button.secondary { + background-color: transparent; + color: #333; +} + +.papi-icon-button.paratext { + background-color: darkgreen; + color: greenyellow; +} + +.papi-icon-button.paratext.bright { + background-color: greenyellow; + color: darkgreen; +} .papi-menu-item { background-color: transparent; } diff --git a/lib/platform-bible-react/dist/index.cjs.map b/lib/platform-bible-react/dist/index.cjs.map index dfd802cd06..7842c2b8ae 100644 --- a/lib/platform-bible-react/dist/index.cjs.map +++ b/lib/platform-bible-react/dist/index.cjs.map @@ -1 +1 @@ -{"version":3,"file":"index.cjs","sources":["../src/utils/shadcn-ui.util.ts","../src/components/shadcn-ui/input.tsx","../src/components/advanced/book-chapter-control/book-chapter-input.component.tsx","../../../node_modules/@sillsdev/scripture/dist/index.es.js","../src/components/shadcn-ui/dropdown-menu.tsx","../src/components/advanced/book-chapter-control/book-menu-item.component.tsx","../src/components/advanced/book-chapter-control/chapter-select.component.tsx","../src/components/advanced/book-chapter-control/go-to-menu-item.component.tsx","../src/components/advanced/book-chapter-control/book-chapter-control.component.tsx","../src/components/shadcn-ui/button.tsx","../src/components/shadcn-ui/label.tsx","../src/components/shadcn-ui/radio-group.tsx","../src/components/shadcn-ui/popover.tsx","../src/components/shadcn-ui/dialog.tsx","../src/components/shadcn-ui/command.tsx","../src/components/basics/combo-box.component.tsx","../src/components/basics/chapter-range-selector.component.tsx","../src/components/advanced/book-selector.component.tsx","../src/components/advanced/data-table/data-table-column-toggle.component.tsx","../src/components/shadcn-ui/select.tsx","../src/components/advanced/data-table/data-table-pagination.component.tsx","../src/components/shadcn-ui/table.tsx","../src/components/advanced/data-table/data-table.component.tsx","../src/components/advanced/inventory/occurrences-table.component.tsx","../src/components/shadcn-ui/checkbox.tsx","../src/components/advanced/inventory/inventory-utils.ts","../src/components/shadcn-ui/toggle.tsx","../src/components/shadcn-ui/toggle-group.tsx","../src/components/advanced/inventory/inventory-columns.tsx","../src/components/advanced/inventory/inventory.component.tsx","../src/components/basics/search-bar.component.tsx","../src/components/basics/tabs-vertical.tsx","../src/components/advanced/tab-navigation-content-search.component.tsx","../src/components/shadcn-ui/separator.tsx","../src/components/shadcn-ui/sheet.tsx","../src/components/shadcn-ui/skeleton.tsx","../src/components/shadcn-ui/tooltip.tsx","../src/components/hooks/use-mobile.tsx","../src/components/shadcn-ui/sidebar.tsx","../src/components/advanced/settings-components/settings-sidebar.component.tsx","../src/components/advanced/settings-components/settings-sidebar-content-search.component.tsx","../src/components/advanced/scripture-results-viewer/scripture-results-viewer.component.tsx","../src/components/advanced/scroll-group-selector.component.tsx","../src/components/advanced/settings-components/settings-list.component.tsx","../src/components/basics/checklist.component.tsx","../../../node_modules/@babel/runtime/helpers/interopRequireDefault.js","../../../node_modules/@mui/utils/chainPropTypes/chainPropTypes.js","../../../node_modules/@babel/runtime/helpers/esm/extends.js","../../../node_modules/@mui/utils/deepmerge/deepmerge.js","../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.production.min.js","../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.development.js","../../../node_modules/prop-types/node_modules/react-is/index.js","../../../node_modules/object-assign/index.js","../../../node_modules/prop-types/lib/ReactPropTypesSecret.js","../../../node_modules/prop-types/lib/has.js","../../../node_modules/prop-types/checkPropTypes.js","../../../node_modules/prop-types/factoryWithTypeCheckers.js","../../../node_modules/prop-types/factoryWithThrowingShims.js","../../../node_modules/prop-types/index.js","../../../node_modules/@mui/utils/elementAcceptingRef/elementAcceptingRef.js","../../../node_modules/@mui/utils/exactProp/exactProp.js","../../../node_modules/@mui/utils/formatMuiErrorMessage/formatMuiErrorMessage.js","../../../node_modules/react-is/cjs/react-is.production.min.js","../../../node_modules/react-is/cjs/react-is.development.js","../../../node_modules/react-is/index.js","../../../node_modules/@mui/utils/getDisplayName/getDisplayName.js","../../../node_modules/@mui/utils/HTMLElementType/HTMLElementType.js","../../../node_modules/@mui/utils/refType/refType.js","../../../node_modules/@mui/utils/capitalize/capitalize.js","../../../node_modules/@mui/utils/createChainedFunction/createChainedFunction.js","../../../node_modules/@mui/utils/debounce/debounce.js","../../../node_modules/@mui/utils/deprecatedPropType/deprecatedPropType.js","../../../node_modules/@mui/utils/isMuiElement/isMuiElement.js","../../../node_modules/@mui/utils/ownerDocument/ownerDocument.js","../../../node_modules/@mui/utils/ownerWindow/ownerWindow.js","../../../node_modules/@mui/utils/requirePropFactory/requirePropFactory.js","../../../node_modules/@mui/utils/setRef/setRef.js","../../../node_modules/@mui/utils/useEnhancedEffect/useEnhancedEffect.js","../../../node_modules/@mui/utils/useId/useId.js","../../../node_modules/@mui/utils/unsupportedProp/unsupportedProp.js","../../../node_modules/@mui/utils/useControlled/useControlled.js","../../../node_modules/@mui/utils/useEventCallback/useEventCallback.js","../../../node_modules/@mui/utils/useForkRef/useForkRef.js","../../../node_modules/@mui/utils/useLazyRef/useLazyRef.js","../../../node_modules/@mui/utils/useOnMount/useOnMount.js","../../../node_modules/@mui/utils/useTimeout/useTimeout.js","../../../node_modules/@mui/utils/useIsFocusVisible/useIsFocusVisible.js","../../../node_modules/@mui/utils/resolveProps/resolveProps.js","../../../node_modules/@mui/utils/composeClasses/composeClasses.js","../../../node_modules/@mui/utils/ClassNameGenerator/ClassNameGenerator.js","../../../node_modules/@mui/utils/generateUtilityClass/generateUtilityClass.js","../../../node_modules/@mui/utils/generateUtilityClasses/generateUtilityClasses.js","../../../node_modules/@mui/utils/clamp/clamp.js","../../../node_modules/@babel/runtime/helpers/esm/objectWithoutPropertiesLoose.js","../../../node_modules/@mui/system/esm/createTheme/createBreakpoints.js","../../../node_modules/@mui/system/esm/createTheme/shape.js","../../../node_modules/@mui/system/esm/responsivePropType.js","../../../node_modules/@mui/system/esm/merge.js","../../../node_modules/@mui/system/esm/breakpoints.js","../../../node_modules/@mui/system/esm/style.js","../../../node_modules/@mui/system/esm/memoize.js","../../../node_modules/@mui/system/esm/spacing.js","../../../node_modules/@mui/system/esm/createTheme/createSpacing.js","../../../node_modules/@mui/system/esm/compose.js","../../../node_modules/@mui/system/esm/borders.js","../../../node_modules/@mui/system/esm/cssGrid.js","../../../node_modules/@mui/system/esm/palette.js","../../../node_modules/@mui/system/esm/sizing.js","../../../node_modules/@mui/system/esm/styleFunctionSx/defaultSxConfig.js","../../../node_modules/@mui/system/esm/styleFunctionSx/styleFunctionSx.js","../../../node_modules/@mui/system/esm/createTheme/applyStyles.js","../../../node_modules/@mui/system/esm/createTheme/createTheme.js","../../../node_modules/@mui/system/esm/useThemeWithoutDefault.js","../../../node_modules/@mui/system/esm/useTheme.js","../../../node_modules/@mui/system/esm/createStyled.js","../../../node_modules/@mui/system/esm/useThemeProps/getThemeProps.js","../../../node_modules/@mui/system/esm/useThemeProps/useThemeProps.js","../../../node_modules/@mui/system/esm/colorManipulator.js","../../../node_modules/@mui/material/styles/createMixins.js","../../../node_modules/@mui/material/colors/common.js","../../../node_modules/@mui/material/colors/grey.js","../../../node_modules/@mui/material/colors/purple.js","../../../node_modules/@mui/material/colors/red.js","../../../node_modules/@mui/material/colors/orange.js","../../../node_modules/@mui/material/colors/blue.js","../../../node_modules/@mui/material/colors/lightBlue.js","../../../node_modules/@mui/material/colors/green.js","../../../node_modules/@mui/material/styles/createPalette.js","../../../node_modules/@mui/material/styles/createTypography.js","../../../node_modules/@mui/material/styles/shadows.js","../../../node_modules/@mui/material/styles/createTransitions.js","../../../node_modules/@mui/material/styles/zIndex.js","../../../node_modules/@mui/material/styles/createTheme.js","../../../node_modules/@mui/material/styles/defaultTheme.js","../../../node_modules/@mui/material/styles/identifier.js","../../../node_modules/@mui/material/styles/useThemeProps.js","../../../node_modules/@mui/material/styles/styled.js","../../../node_modules/@mui/material/SvgIcon/svgIconClasses.js","../../../node_modules/@mui/material/SvgIcon/SvgIcon.js","../../../node_modules/@mui/material/utils/createSvgIcon.js","../../../node_modules/@mui/material/utils/index.js","../../../node_modules/@mui/icons-material/utils/createSvgIcon.js","../../../node_modules/@mui/icons-material/ArrowRight.js","../../../node_modules/@mui/base/utils/isHostComponent.js","../../../node_modules/@mui/base/utils/appendOwnerState.js","../../../node_modules/@mui/base/utils/ClassNameConfigurator.js","../../../node_modules/@mui/base/utils/extractEventHandlers.js","../../../node_modules/@mui/base/utils/resolveComponentProps.js","../../../node_modules/@mui/base/utils/omitEventHandlers.js","../../../node_modules/@mui/base/utils/mergeSlotProps.js","../../../node_modules/@mui/base/utils/useSlotProps.js","../../../node_modules/@mui/base/generateUtilityClass/index.js","../../../node_modules/@mui/base/generateUtilityClasses/index.js","../../../node_modules/@mui/base/Portal/Portal.js","../../../node_modules/@popperjs/core/lib/enums.js","../../../node_modules/@popperjs/core/lib/dom-utils/getNodeName.js","../../../node_modules/@popperjs/core/lib/dom-utils/getWindow.js","../../../node_modules/@popperjs/core/lib/dom-utils/instanceOf.js","../../../node_modules/@popperjs/core/lib/modifiers/applyStyles.js","../../../node_modules/@popperjs/core/lib/utils/getBasePlacement.js","../../../node_modules/@popperjs/core/lib/utils/math.js","../../../node_modules/@popperjs/core/lib/utils/userAgent.js","../../../node_modules/@popperjs/core/lib/dom-utils/isLayoutViewport.js","../../../node_modules/@popperjs/core/lib/dom-utils/getBoundingClientRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/getLayoutRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/contains.js","../../../node_modules/@popperjs/core/lib/dom-utils/getComputedStyle.js","../../../node_modules/@popperjs/core/lib/dom-utils/isTableElement.js","../../../node_modules/@popperjs/core/lib/dom-utils/getDocumentElement.js","../../../node_modules/@popperjs/core/lib/dom-utils/getParentNode.js","../../../node_modules/@popperjs/core/lib/dom-utils/getOffsetParent.js","../../../node_modules/@popperjs/core/lib/utils/getMainAxisFromPlacement.js","../../../node_modules/@popperjs/core/lib/utils/within.js","../../../node_modules/@popperjs/core/lib/utils/getFreshSideObject.js","../../../node_modules/@popperjs/core/lib/utils/mergePaddingObject.js","../../../node_modules/@popperjs/core/lib/utils/expandToHashMap.js","../../../node_modules/@popperjs/core/lib/modifiers/arrow.js","../../../node_modules/@popperjs/core/lib/utils/getVariation.js","../../../node_modules/@popperjs/core/lib/modifiers/computeStyles.js","../../../node_modules/@popperjs/core/lib/modifiers/eventListeners.js","../../../node_modules/@popperjs/core/lib/utils/getOppositePlacement.js","../../../node_modules/@popperjs/core/lib/utils/getOppositeVariationPlacement.js","../../../node_modules/@popperjs/core/lib/dom-utils/getWindowScroll.js","../../../node_modules/@popperjs/core/lib/dom-utils/getWindowScrollBarX.js","../../../node_modules/@popperjs/core/lib/dom-utils/getViewportRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/getDocumentRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/isScrollParent.js","../../../node_modules/@popperjs/core/lib/dom-utils/getScrollParent.js","../../../node_modules/@popperjs/core/lib/dom-utils/listScrollParents.js","../../../node_modules/@popperjs/core/lib/utils/rectToClientRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/getClippingRect.js","../../../node_modules/@popperjs/core/lib/utils/computeOffsets.js","../../../node_modules/@popperjs/core/lib/utils/detectOverflow.js","../../../node_modules/@popperjs/core/lib/utils/computeAutoPlacement.js","../../../node_modules/@popperjs/core/lib/modifiers/flip.js","../../../node_modules/@popperjs/core/lib/modifiers/hide.js","../../../node_modules/@popperjs/core/lib/modifiers/offset.js","../../../node_modules/@popperjs/core/lib/modifiers/popperOffsets.js","../../../node_modules/@popperjs/core/lib/utils/getAltAxis.js","../../../node_modules/@popperjs/core/lib/modifiers/preventOverflow.js","../../../node_modules/@popperjs/core/lib/dom-utils/getHTMLElementScroll.js","../../../node_modules/@popperjs/core/lib/dom-utils/getNodeScroll.js","../../../node_modules/@popperjs/core/lib/dom-utils/getCompositeRect.js","../../../node_modules/@popperjs/core/lib/utils/orderModifiers.js","../../../node_modules/@popperjs/core/lib/utils/debounce.js","../../../node_modules/@popperjs/core/lib/utils/mergeByName.js","../../../node_modules/@popperjs/core/lib/createPopper.js","../../../node_modules/@popperjs/core/lib/popper.js","../../../node_modules/@mui/base/Popper/popperClasses.js","../../../node_modules/@mui/base/Popper/Popper.js","../../../node_modules/@mui/material/styles/useTheme.js","../../../node_modules/@babel/runtime/helpers/esm/setPrototypeOf.js","../../../node_modules/@babel/runtime/helpers/esm/inheritsLoose.js","../../../node_modules/react-transition-group/esm/config.js","../../../node_modules/react-transition-group/esm/utils/PropTypes.js","../../../node_modules/react-transition-group/esm/TransitionGroupContext.js","../../../node_modules/react-transition-group/esm/utils/reflow.js","../../../node_modules/react-transition-group/esm/Transition.js","../../../node_modules/@mui/material/transitions/utils.js","../../../node_modules/@mui/material/Grow/Grow.js","../../../node_modules/@mui/material/Popper/Popper.js","../../../node_modules/@mui/material/Tooltip/tooltipClasses.js","../../../node_modules/@mui/material/Tooltip/Tooltip.js","../src/components/mui/menu-item.component.tsx","../src/components/mui/grouped-menu-item-list.component.tsx","../src/components/mui/top-level-menu.component.tsx","../src/components/mui/grid-menu.component.tsx","../src/hooks/use-promise.hook.ts","../../../node_modules/@mui/icons-material/esm/Menu.js","../src/components/mui/hamburger-menu-button.component.tsx","../src/components/mui/icon-button.component.tsx","../src/components/basics/spinner.component.tsx","../src/components/basics/text-field.component.tsx","../src/components/mui/toolbar.component.tsx","../src/components/shadcn-ui/alert.tsx","../src/components/shadcn-ui/card.tsx","../src/components/shadcn-ui/sonner.tsx","../src/components/shadcn-ui/slider.tsx","../src/components/shadcn-ui/switch.tsx","../src/components/shadcn-ui/tabs.tsx","../src/components/advanced/extension-marketplace/buttons/install-button.component.tsx","../src/components/advanced/extension-marketplace/buttons/enable-button.component.tsx","../src/components/advanced/extension-marketplace/buttons/disable-button.component.tsx","../src/components/advanced/extension-marketplace/buttons/update-button.component.tsx","../src/components/advanced/extension-marketplace/markdown-renderer.component.tsx","../src/components/advanced/extension-marketplace/buttons/filter-button.component.tsx","../src/components/advanced/extension-marketplace/filter-dropdown.component.tsx","../src/components/advanced/extension-marketplace/no-extensions-found.component.tsx","../src/components/advanced/extension-marketplace/more-info.component.tsx","../src/components/advanced/extension-marketplace/version-history.component.tsx","../src/components/advanced/extension-marketplace/footer.component.tsx","../src/hooks/use-event.hook.ts","../src/hooks/use-event-async.hook.ts"],"sourcesContent":["import { type ClassValue, clsx } from 'clsx';\nimport { extendTailwindMerge } from 'tailwind-merge';\n\nconst twMergeCustom = extendTailwindMerge({ prefix: 'tw-' });\n\n/**\n * Tailwind and CSS class application helper function. Uses\n * [`clsx`](https://www.npmjs.com/package/clsx) to make it easy to apply classes conditionally using\n * object syntax, and uses [`tailwind-merge`](https://www.npmjs.com/package/tailwind-merge) to make\n * it easy to merge/overwrite Tailwind classes in a programmer-logic-friendly way.\n *\n * Note: `tailwind-merge` is configured to use the prefix `tw-`, so you must use the same prefix\n * with any Tailwind classes you use with this function to successfully overwrite other Tailwind\n * classes. `platform-bible-react` is configured to use `tw-` as its Tailwind prefix, so any\n * Tailwind classes you pass into `platform-bible-react` components will be compared using the `tw-`\n * prefix.\n *\n * This function was popularized by\n * [shadcn/ui](https://ui.shadcn.com/docs/installation/manual#add-a-cn-helper). See [ByteGrad's\n * explanation video](https://www.youtube.com/watch?v=re2JFITR7TI) for more information.\n *\n * @example\n *\n * ```typescript\n * const borderShouldBeBlue = true;\n * const textShouldBeRed = true;\n * const heightShouldBe20 = false;\n * const classString = cn(\n * 'tw-bg-primary tw-h-10 tw-text-primary-foreground',\n * 'tw-bg-secondary',\n * {\n * 'tw-border-blue-500': borderShouldBeBlue,\n * 'tw-text-red-500': textShouldBeRed,\n * 'tw-h-20': heightShouldBe20,\n * },\n * 'some-class',\n * );\n * ```\n *\n * The resulting `classString` is `'tw-h-10 tw-bg-secondary tw-border-blue-500 tw-text-red-500\n * some-class'`\n *\n * - Notice that `'tw-bg-secondary'`, specified later, overwrote `'tw-bg-primary'`, specified earlier,\n * because they are Tailwind classes that affect the same css property\n * - Notice that `'tw-text-red-500'`, specified later, overwrote `'tw-text-primary-foreground'`,\n * specified earlier, because they are Tailwind classes that affect the same css property\n * - Notice that `'tw-h-20'`, specified later, did not overwrite `'tw-h-10'`, specified earlier,\n * because `'tw-h-20'` is part of a conditional class object and its value evaluated to `false`;\n * therefore it was not applied\n * - Notice that `'some-class'` was applied. This function is not limited only to Tailwind classes.\n *\n *\n * @param inputs Class strings or `clsx` conditional class objects to merge. Tailwind classes\n * specified later in the arguments overwrite similar Tailwind classes specified earlier in the\n * arguments\n * @returns Class string containing all applicable classes from the arguments based on the rules\n * described above\n */\n// shadcn/ui uses this export in its boilerplate code\n// eslint-disable-next-line import/prefer-default-export\nexport function cn(...inputs: ClassValue[]) {\n return twMergeCustom(clsx(inputs));\n}\n","import React from 'react';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport interface InputProps extends React.InputHTMLAttributes {}\n\nexport const Input = React.forwardRef(\n ({ className, type, ...props }, ref) => {\n return (\n \n );\n },\n);\nInput.displayName = 'Input';\n","import { FocusEventHandler, forwardRef, KeyboardEvent, MouseEventHandler } from 'react';\nimport { History } from 'lucide-react';\nimport { Input as ShadInput } from '@/components/shadcn-ui/input';\n\nexport type BookChapterInputProps = {\n handleSearch: (searchString: string) => void;\n handleKeyDown: (event: KeyboardEvent) => void;\n handleOnClick: MouseEventHandler;\n handleSubmit: () => void;\n onFocus?: FocusEventHandler;\n value: string;\n placeholder: string;\n};\n\n// Shadcn Input sets type to \"button\"- HAVE to prop spread before setting type\nconst BookChapterInput = forwardRef(\n (\n { handleSearch, handleKeyDown, handleOnClick, handleSubmit, ...props }: BookChapterInputProps,\n ref,\n ) => {\n return (\n
    \n handleSearch(event.target.value)}\n onKeyDown={(e) => {\n if (e.key === 'Enter') {\n handleSubmit();\n }\n handleKeyDown(e);\n }}\n onClick={handleOnClick}\n ref={ref}\n />\n {\n // eslint-disable-next-line no-console\n console.log('back in history');\n }}\n />\n
    \n );\n },\n);\n\nexport default BookChapterInput;\n","var P = Object.defineProperty;\nvar R = (t, e, s) => e in t ? P(t, e, { enumerable: !0, configurable: !0, writable: !0, value: s }) : t[e] = s;\nvar n = (t, e, s) => R(t, typeof e != \"symbol\" ? e + \"\" : e, s);\nclass _ {\n constructor() {\n n(this, \"books\");\n n(this, \"firstSelectedBookNum\");\n n(this, \"lastSelectedBookNum\");\n n(this, \"count\");\n n(this, \"selectedBookNumbers\");\n n(this, \"selectedBookIds\");\n }\n}\nconst N = [\n \"GEN\",\n \"EXO\",\n \"LEV\",\n \"NUM\",\n \"DEU\",\n \"JOS\",\n \"JDG\",\n \"RUT\",\n \"1SA\",\n \"2SA\",\n // 10\n \"1KI\",\n \"2KI\",\n \"1CH\",\n \"2CH\",\n \"EZR\",\n \"NEH\",\n \"EST\",\n \"JOB\",\n \"PSA\",\n \"PRO\",\n // 20\n \"ECC\",\n \"SNG\",\n \"ISA\",\n \"JER\",\n \"LAM\",\n \"EZK\",\n \"DAN\",\n \"HOS\",\n \"JOL\",\n \"AMO\",\n // 30\n \"OBA\",\n \"JON\",\n \"MIC\",\n \"NAM\",\n \"HAB\",\n \"ZEP\",\n \"HAG\",\n \"ZEC\",\n \"MAL\",\n \"MAT\",\n // 40\n \"MRK\",\n \"LUK\",\n \"JHN\",\n \"ACT\",\n \"ROM\",\n \"1CO\",\n \"2CO\",\n \"GAL\",\n \"EPH\",\n \"PHP\",\n // 50\n \"COL\",\n \"1TH\",\n \"2TH\",\n \"1TI\",\n \"2TI\",\n \"TIT\",\n \"PHM\",\n \"HEB\",\n \"JAS\",\n \"1PE\",\n // 60\n \"2PE\",\n \"1JN\",\n \"2JN\",\n \"3JN\",\n \"JUD\",\n \"REV\",\n \"TOB\",\n \"JDT\",\n \"ESG\",\n \"WIS\",\n // 70\n \"SIR\",\n \"BAR\",\n \"LJE\",\n \"S3Y\",\n \"SUS\",\n \"BEL\",\n \"1MA\",\n \"2MA\",\n \"3MA\",\n \"4MA\",\n // 80\n \"1ES\",\n \"2ES\",\n \"MAN\",\n \"PS2\",\n \"ODA\",\n \"PSS\",\n \"JSA\",\n // actual variant text for JOS, now in LXA text\n \"JDB\",\n // actual variant text for JDG, now in LXA text\n \"TBS\",\n // actual variant text for TOB, now in LXA text\n \"SST\",\n // actual variant text for SUS, now in LXA text // 90\n \"DNT\",\n // actual variant text for DAN, now in LXA text\n \"BLT\",\n // actual variant text for BEL, now in LXA text\n \"XXA\",\n \"XXB\",\n \"XXC\",\n \"XXD\",\n \"XXE\",\n \"XXF\",\n \"XXG\",\n \"FRT\",\n // 100\n \"BAK\",\n \"OTH\",\n \"3ES\",\n // Used previously but really should be 2ES\n \"EZA\",\n // Used to be called 4ES, but not actually in any known project\n \"5EZ\",\n // Used to be called 5ES, but not actually in any known project\n \"6EZ\",\n // Used to be called 6ES, but not actually in any known project\n \"INT\",\n \"CNC\",\n \"GLO\",\n \"TDX\",\n // 110\n \"NDX\",\n \"DAG\",\n \"PS3\",\n \"2BA\",\n \"LBA\",\n \"JUB\",\n \"ENO\",\n \"1MQ\",\n \"2MQ\",\n \"3MQ\",\n // 120\n \"REP\",\n \"4BA\",\n \"LAO\"\n], B = [\n \"XXA\",\n \"XXB\",\n \"XXC\",\n \"XXD\",\n \"XXE\",\n \"XXF\",\n \"XXG\",\n \"FRT\",\n \"BAK\",\n \"OTH\",\n \"INT\",\n \"CNC\",\n \"GLO\",\n \"TDX\",\n \"NDX\"\n], O = [\n \"Genesis\",\n \"Exodus\",\n \"Leviticus\",\n \"Numbers\",\n \"Deuteronomy\",\n \"Joshua\",\n \"Judges\",\n \"Ruth\",\n \"1 Samuel\",\n \"2 Samuel\",\n \"1 Kings\",\n \"2 Kings\",\n \"1 Chronicles\",\n \"2 Chronicles\",\n \"Ezra\",\n \"Nehemiah\",\n \"Esther (Hebrew)\",\n \"Job\",\n \"Psalms\",\n \"Proverbs\",\n \"Ecclesiastes\",\n \"Song of Songs\",\n \"Isaiah\",\n \"Jeremiah\",\n \"Lamentations\",\n \"Ezekiel\",\n \"Daniel (Hebrew)\",\n \"Hosea\",\n \"Joel\",\n \"Amos\",\n \"Obadiah\",\n \"Jonah\",\n \"Micah\",\n \"Nahum\",\n \"Habakkuk\",\n \"Zephaniah\",\n \"Haggai\",\n \"Zechariah\",\n \"Malachi\",\n \"Matthew\",\n \"Mark\",\n \"Luke\",\n \"John\",\n \"Acts\",\n \"Romans\",\n \"1 Corinthians\",\n \"2 Corinthians\",\n \"Galatians\",\n \"Ephesians\",\n \"Philippians\",\n \"Colossians\",\n \"1 Thessalonians\",\n \"2 Thessalonians\",\n \"1 Timothy\",\n \"2 Timothy\",\n \"Titus\",\n \"Philemon\",\n \"Hebrews\",\n \"James\",\n \"1 Peter\",\n \"2 Peter\",\n \"1 John\",\n \"2 John\",\n \"3 John\",\n \"Jude\",\n \"Revelation\",\n \"Tobit\",\n \"Judith\",\n \"Esther Greek\",\n \"Wisdom of Solomon\",\n \"Sirach (Ecclesiasticus)\",\n \"Baruch\",\n \"Letter of Jeremiah\",\n \"Song of 3 Young Men\",\n \"Susanna\",\n \"Bel and the Dragon\",\n \"1 Maccabees\",\n \"2 Maccabees\",\n \"3 Maccabees\",\n \"4 Maccabees\",\n \"1 Esdras (Greek)\",\n \"2 Esdras (Latin)\",\n \"Prayer of Manasseh\",\n \"Psalm 151\",\n \"Odes\",\n \"Psalms of Solomon\",\n // WARNING, if you change the spelling of the *obsolete* tag be sure to update\n // IsObsolete routine\n \"Joshua A. *obsolete*\",\n \"Judges B. *obsolete*\",\n \"Tobit S. *obsolete*\",\n \"Susanna Th. *obsolete*\",\n \"Daniel Th. *obsolete*\",\n \"Bel Th. *obsolete*\",\n \"Extra A\",\n \"Extra B\",\n \"Extra C\",\n \"Extra D\",\n \"Extra E\",\n \"Extra F\",\n \"Extra G\",\n \"Front Matter\",\n \"Back Matter\",\n \"Other Matter\",\n \"3 Ezra *obsolete*\",\n \"Apocalypse of Ezra\",\n \"5 Ezra (Latin Prologue)\",\n \"6 Ezra (Latin Epilogue)\",\n \"Introduction\",\n \"Concordance \",\n \"Glossary \",\n \"Topical Index\",\n \"Names Index\",\n \"Daniel Greek\",\n \"Psalms 152-155\",\n \"2 Baruch (Apocalypse)\",\n \"Letter of Baruch\",\n \"Jubilees\",\n \"Enoch\",\n \"1 Meqabyan\",\n \"2 Meqabyan\",\n \"3 Meqabyan\",\n \"Reproof (Proverbs 25-31)\",\n \"4 Baruch (Rest of Baruch)\",\n \"Laodiceans\"\n], S = K();\nfunction g(t, e = !0) {\n return e && (t = t.toUpperCase()), t in S ? S[t] : 0;\n}\nfunction k(t) {\n return g(t) > 0;\n}\nfunction x(t) {\n const e = typeof t == \"string\" ? g(t) : t;\n return e >= 40 && e <= 66;\n}\nfunction T(t) {\n return (typeof t == \"string\" ? g(t) : t) <= 39;\n}\nfunction X(t) {\n return t <= 66;\n}\nfunction V(t) {\n const e = typeof t == \"string\" ? g(t) : t;\n return w(e) && !X(e);\n}\nfunction* L() {\n for (let t = 1; t <= N.length; t++) yield t;\n}\nconst G = 1, A = N.length;\nfunction H() {\n return [\"XXA\", \"XXB\", \"XXC\", \"XXD\", \"XXE\", \"XXF\", \"XXG\"];\n}\nfunction C(t, e = \"***\") {\n const s = t - 1;\n return s < 0 || s >= N.length ? e : N[s];\n}\nfunction I(t) {\n return t <= 0 || t > A ? \"******\" : O[t - 1];\n}\nfunction y(t) {\n return I(g(t));\n}\nfunction w(t) {\n const e = typeof t == \"number\" ? C(t) : t;\n return k(e) && !B.includes(e);\n}\nfunction q(t) {\n const e = typeof t == \"number\" ? C(t) : t;\n return k(e) && B.includes(e);\n}\nfunction U(t) {\n return O[t - 1].includes(\"*obsolete*\");\n}\nfunction K() {\n const t = {};\n for (let e = 0; e < N.length; e++)\n t[N[e]] = e + 1;\n return t;\n}\nconst m = {\n allBookIds: N,\n nonCanonicalIds: B,\n bookIdToNumber: g,\n isBookIdValid: k,\n isBookNT: x,\n isBookOT: T,\n isBookOTNT: X,\n isBookDC: V,\n allBookNumbers: L,\n firstBook: G,\n lastBook: A,\n extraBooks: H,\n bookNumberToId: C,\n bookNumberToEnglishName: I,\n bookIdToEnglishName: y,\n isCanonical: w,\n isExtraMaterial: q,\n isObsolete: U\n};\nvar l = /* @__PURE__ */ ((t) => (t[t.Unknown = 0] = \"Unknown\", t[t.Original = 1] = \"Original\", t[t.Septuagint = 2] = \"Septuagint\", t[t.Vulgate = 3] = \"Vulgate\", t[t.English = 4] = \"English\", t[t.RussianProtestant = 5] = \"RussianProtestant\", t[t.RussianOrthodox = 6] = \"RussianOrthodox\", t))(l || {});\nconst h = class h {\n // private versInfo: Versification;\n constructor(e) {\n n(this, \"name\");\n n(this, \"fullPath\");\n n(this, \"isPresent\");\n n(this, \"hasVerseSegments\");\n n(this, \"isCustomized\");\n n(this, \"baseVersification\");\n n(this, \"scriptureBooks\");\n n(this, \"_type\");\n if (e == null)\n throw new Error(\"Argument undefined\");\n typeof e == \"string\" ? (this.name = e, this._type = l[e]) : (this._type = e, this.name = l[e]);\n }\n get type() {\n return this._type;\n }\n equals(e) {\n return !e.type || !this.type ? !1 : e.type === this.type;\n }\n};\nn(h, \"Original\", new h(l.Original)), n(h, \"Septuagint\", new h(l.Septuagint)), n(h, \"Vulgate\", new h(l.Vulgate)), n(h, \"English\", new h(l.English)), n(h, \"RussianProtestant\", new h(l.RussianProtestant)), n(h, \"RussianOrthodox\", new h(l.RussianOrthodox));\nlet c = h;\nfunction E(t, e) {\n const s = e[0];\n for (let r = 1; r < e.length; r++)\n t = t.split(e[r]).join(s);\n return t.split(s);\n}\nvar D = /* @__PURE__ */ ((t) => (t[t.Valid = 0] = \"Valid\", t[t.UnknownVersification = 1] = \"UnknownVersification\", t[t.OutOfRange = 2] = \"OutOfRange\", t[t.VerseOutOfOrder = 3] = \"VerseOutOfOrder\", t[t.VerseRepeated = 4] = \"VerseRepeated\", t))(D || {});\nconst i = class i {\n constructor(e, s, r, a) {\n /** Not yet implemented. */\n n(this, \"firstChapter\");\n /** Not yet implemented. */\n n(this, \"lastChapter\");\n /** Not yet implemented. */\n n(this, \"lastVerse\");\n /** Not yet implemented. */\n n(this, \"hasSegmentsDefined\");\n /** Not yet implemented. */\n n(this, \"text\");\n /** Not yet implemented. */\n n(this, \"BBBCCCVVVS\");\n /** Not yet implemented. */\n n(this, \"longHashCode\");\n /** The versification of the reference. */\n n(this, \"versification\");\n n(this, \"rtlMark\", \"‏\");\n n(this, \"_bookNum\", 0);\n n(this, \"_chapterNum\", 0);\n n(this, \"_verseNum\", 0);\n n(this, \"_verse\");\n if (r == null && a == null)\n if (e != null && typeof e == \"string\") {\n const o = e, u = s != null && s instanceof c ? s : void 0;\n this.setEmpty(u), this.parse(o);\n } else if (e != null && typeof e == \"number\") {\n const o = s != null && s instanceof c ? s : void 0;\n this.setEmpty(o), this._verseNum = e % i.chapterDigitShifter, this._chapterNum = Math.floor(\n e % i.bookDigitShifter / i.chapterDigitShifter\n ), this._bookNum = Math.floor(e / i.bookDigitShifter);\n } else if (s == null)\n if (e != null && e instanceof i) {\n const o = e;\n this._bookNum = o.bookNum, this._chapterNum = o.chapterNum, this._verseNum = o.verseNum, this._verse = o.verse, this.versification = o.versification;\n } else {\n if (e == null) return;\n const o = e instanceof c ? e : i.defaultVersification;\n this.setEmpty(o);\n }\n else\n throw new Error(\"VerseRef constructor not supported.\");\n else if (e != null && s != null && r != null)\n if (typeof e == \"string\" && typeof s == \"string\" && typeof r == \"string\")\n this.setEmpty(a), this.updateInternal(e, s, r);\n else if (typeof e == \"number\" && typeof s == \"number\" && typeof r == \"number\")\n this._bookNum = e, this._chapterNum = s, this._verseNum = r, this.versification = a ?? i.defaultVersification;\n else\n throw new Error(\"VerseRef constructor not supported.\");\n else\n throw new Error(\"VerseRef constructor not supported.\");\n }\n /**\n * Determines if the verse string is in a valid format (does not consider versification).\n */\n static isVerseParseable(e) {\n return e.length > 0 && \"0123456789\".includes(e[0]) && !e.endsWith(this.verseRangeSeparator) && !e.endsWith(this.verseSequenceIndicator);\n }\n /**\n * Tries to parse the specified string into a verse reference.\n * @param str - The string to attempt to parse.\n * @returns success: `true` if the specified string was successfully parsed, `false` otherwise.\n * @returns verseRef: The result of the parse if successful, or empty VerseRef if it failed\n */\n static tryParse(e) {\n let s;\n try {\n return s = new i(e), { success: !0, verseRef: s };\n } catch (r) {\n if (r instanceof v)\n return s = new i(), { success: !1, verseRef: s };\n throw r;\n }\n }\n /**\n * Gets the reference as a comparable integer where the book, chapter, and verse each occupy 3\n * digits.\n * @param bookNum - Book number (this is 1-based, not an index).\n * @param chapterNum - Chapter number.\n * @param verseNum - Verse number.\n * @returns The reference as a comparable integer where the book, chapter, and verse each occupy 3\n * digits.\n */\n static getBBBCCCVVV(e, s, r) {\n return e % i.bcvMaxValue * i.bookDigitShifter + (s >= 0 ? s % i.bcvMaxValue * i.chapterDigitShifter : 0) + (r >= 0 ? r % i.bcvMaxValue : 0);\n }\n /**\n * Deserializes a serialized VerseRef.\n * @param serializedVerseRef - Serialized VerseRef to create from.\n * @returns the deserialized VerseRef.\n */\n static fromJSON(e) {\n const { book: s, chapterNum: r, verseNum: a, verse: o, versificationStr: u } = e, f = o || a.toString();\n let d;\n return u && (d = new c(u)), s ? new i(s, r.toString(), f, d) : new i();\n }\n /**\n * Parses a verse string and gets the leading numeric portion as a number.\n * @param verseStr - verse string to parse\n * @returns true if the entire string could be parsed as a single, simple verse number (1-999);\n * false if the verse string represented a verse bridge, contained segment letters, or was invalid\n */\n static tryGetVerseNum(e) {\n let s;\n if (!e)\n return s = -1, { success: !0, vNum: s };\n s = 0;\n let r;\n for (let a = 0; a < e.length; a++) {\n if (r = e[a], r < \"0\" || r > \"9\")\n return a === 0 && (s = -1), { success: !1, vNum: s };\n if (s = s * 10 + +r - 0, s > i.bcvMaxValue)\n return s = -1, { success: !1, vNum: s };\n }\n return { success: !0, vNum: s };\n }\n /**\n * Checks to see if a VerseRef hasn't been set - all values are the default.\n */\n get isDefault() {\n return this.bookNum === 0 && this.chapterNum === 0 && this.verseNum === 0 && this.versification == null;\n }\n /**\n * Gets whether the verse contains multiple verses.\n */\n get hasMultiple() {\n return this._verse != null && (this._verse.includes(i.verseRangeSeparator) || this._verse.includes(i.verseSequenceIndicator));\n }\n /**\n * Gets or sets the book of the reference. Book is the 3-letter abbreviation in capital letters,\n * e.g. `'MAT'`.\n */\n get book() {\n return m.bookNumberToId(this.bookNum, \"\");\n }\n set book(e) {\n this.bookNum = m.bookIdToNumber(e);\n }\n /**\n * Gets or sets the chapter of the reference,. e.g. `'3'`.\n */\n get chapter() {\n return this.isDefault || this._chapterNum < 0 ? \"\" : this._chapterNum.toString();\n }\n set chapter(e) {\n const s = +e;\n this._chapterNum = Number.isInteger(s) ? s : -1;\n }\n /**\n * Gets or sets the verse of the reference, including range, segments, and sequences, e.g. `'4'`,\n * or `'4b-5a, 7'`.\n */\n get verse() {\n return this._verse != null ? this._verse : this.isDefault || this._verseNum < 0 ? \"\" : this._verseNum.toString();\n }\n set verse(e) {\n const { success: s, vNum: r } = i.tryGetVerseNum(e);\n this._verse = s ? void 0 : e.replace(this.rtlMark, \"\"), this._verseNum = r, !(this._verseNum >= 0) && ({ vNum: this._verseNum } = i.tryGetVerseNum(this._verse));\n }\n /**\n * Get or set Book based on book number, e.g. `42`.\n */\n get bookNum() {\n return this._bookNum;\n }\n set bookNum(e) {\n if (e <= 0 || e > m.lastBook)\n throw new v(\n \"BookNum must be greater than zero and less than or equal to last book\"\n );\n this._bookNum = e;\n }\n /**\n * Gets or sets the chapter number, e.g. `3`. `-1` if not valid.\n */\n get chapterNum() {\n return this._chapterNum;\n }\n set chapterNum(e) {\n this.chapterNum = e;\n }\n /**\n * Gets or sets verse start number, e.g. `4`. `-1` if not valid.\n */\n get verseNum() {\n return this._verseNum;\n }\n set verseNum(e) {\n this._verseNum = e;\n }\n /**\n * String representing the versification (should ONLY be used for serialization/deserialization).\n *\n * @remarks This is for backwards compatibility when ScrVers was an enumeration.\n */\n get versificationStr() {\n var e;\n return (e = this.versification) == null ? void 0 : e.name;\n }\n set versificationStr(e) {\n this.versification = this.versification != null ? new c(e) : void 0;\n }\n /**\n * Determines if the reference is valid.\n */\n get valid() {\n return this.validStatus === 0;\n }\n /**\n * Get the valid status for this reference.\n */\n get validStatus() {\n return this.validateVerse(i.verseRangeSeparators, i.verseSequenceIndicators);\n }\n /**\n * Gets the reference as a comparable integer where the book,\n * chapter, and verse each occupy three digits and the verse is 0.\n */\n get BBBCCC() {\n return i.getBBBCCCVVV(this._bookNum, this._chapterNum, 0);\n }\n /**\n * Gets the reference as a comparable integer where the book,\n * chapter, and verse each occupy three digits. If verse is not null\n * (i.e., this reference represents a complex reference with verse\n * segments or bridge) this cannot be used for an exact comparison.\n */\n get BBBCCCVVV() {\n return i.getBBBCCCVVV(this._bookNum, this._chapterNum, this._verseNum);\n }\n /**\n * Gets whether the verse is defined as an excluded verse in the versification.\n * Does not handle verse ranges.\n */\n // eslint-disable-next-line @typescript-eslint/class-literal-property-style\n get isExcluded() {\n return !1;\n }\n /**\n * Parses the reference in the specified string.\n * Optionally versification can follow reference as in GEN 3:11/4\n * Throw an exception if\n * - invalid book name\n * - chapter number is missing or not a number\n * - verse number is missing or does not start with a number\n * - versification is invalid\n * @param verseStr - string to parse e.g. 'MAT 3:11'\n */\n parse(e) {\n if (e = e.replace(this.rtlMark, \"\"), e.includes(\"/\")) {\n const o = e.split(\"/\");\n if (e = o[0], o.length > 1)\n try {\n const u = +o[1].trim();\n this.versification = new c(l[u]);\n } catch {\n throw new v(\"Invalid reference : \" + e);\n }\n }\n const s = e.trim().split(\" \");\n if (s.length !== 2)\n throw new v(\"Invalid reference : \" + e);\n const r = s[1].split(\":\"), a = +r[0];\n if (r.length !== 2 || m.bookIdToNumber(s[0]) === 0 || !Number.isInteger(a) || a < 0 || !i.isVerseParseable(r[1]))\n throw new v(\"Invalid reference : \" + e);\n this.updateInternal(s[0], r[0], r[1]);\n }\n /**\n * Simplifies this verse ref so that it has no bridging of verses or\n * verse segments like `'1a'`.\n */\n simplify() {\n this._verse = void 0;\n }\n /**\n * Makes a clone of the reference.\n *\n * @returns The cloned VerseRef.\n */\n clone() {\n return new i(this);\n }\n toString() {\n const e = this.book;\n return e === \"\" ? \"\" : `${e} ${this.chapter}:${this.verse}`;\n }\n toJSON() {\n let e = this.verse;\n (e === \"\" || e === this.verseNum.toString()) && (e = void 0);\n const s = {\n book: this.book,\n chapterNum: this.chapterNum,\n verseNum: this.verseNum,\n verse: e,\n versificationStr: this.versificationStr\n };\n return e || delete s.verse, s;\n }\n /**\n * Compares this `VerseRef` with supplied one.\n * @param verseRef - object to compare this one to.\n * @returns `true` if this `VerseRef` is equal to the supplied one, `false` otherwise.\n */\n equals(e) {\n return e instanceof i ? e._bookNum === this._bookNum && e._chapterNum === this._chapterNum && e._verseNum === this._verseNum && e.verse === this.verse && (e.versification == null && this.versification == null || e.versification != null && this.versification != null && e.versification.equals(this.versification)) : !1;\n }\n /**\n * Enumerate all individual verses contained in a VerseRef.\n * Verse ranges are indicated by \"-\" and consecutive verses by \",\"s.\n * Examples:\n * GEN 1:2 returns GEN 1:2\n * GEN 1:1a-3b,5 returns GEN 1:1a, GEN 1:2, GEN 1:3b, GEN 1:5\n * GEN 1:2a-2c returns //! ??????\n *\n * @param specifiedVersesOnly - if set to true return only verses that are\n * explicitly specified only, not verses within a range. Defaults to `false`.\n * @param verseRangeSeparators - Verse range separators.\n * Defaults to `VerseRef.verseRangeSeparators`.\n * @param verseSequenceSeparators - Verse sequence separators.\n * Defaults to `VerseRef.verseSequenceIndicators`.\n * @returns An array of all single verse references in this VerseRef.\n */\n allVerses(e = !1, s = i.verseRangeSeparators, r = i.verseSequenceIndicators) {\n if (this._verse == null || this.chapterNum <= 0)\n return [this.clone()];\n const a = [], o = E(this._verse, r);\n for (const u of o.map((f) => E(f, s))) {\n const f = this.clone();\n f.verse = u[0];\n const d = f.verseNum;\n if (a.push(f), u.length > 1) {\n const b = this.clone();\n if (b.verse = u[1], !e)\n for (let p = d + 1; p < b.verseNum; p++) {\n const J = new i(\n this._bookNum,\n this._chapterNum,\n p,\n this.versification\n );\n this.isExcluded || a.push(J);\n }\n a.push(b);\n }\n }\n return a;\n }\n /**\n * Validates a verse number using the supplied separators rather than the defaults.\n */\n validateVerse(e, s) {\n if (!this.verse)\n return this.internalValid;\n let r = 0;\n for (const a of this.allVerses(!0, e, s)) {\n const o = a.internalValid;\n if (o !== 0)\n return o;\n const u = a.BBBCCCVVV;\n if (r > u)\n return 3;\n if (r === u)\n return 4;\n r = u;\n }\n return 0;\n }\n /**\n * Gets whether a single verse reference is valid.\n */\n get internalValid() {\n return this.versification == null ? 1 : this._bookNum <= 0 || this._bookNum > m.lastBook ? 2 : (m.isCanonical(this._bookNum), 0);\n }\n setEmpty(e = i.defaultVersification) {\n this._bookNum = 0, this._chapterNum = -1, this._verse = void 0, this.versification = e;\n }\n updateInternal(e, s, r) {\n this.bookNum = m.bookIdToNumber(e), this.chapter = s, this.verse = r;\n }\n};\nn(i, \"defaultVersification\", c.English), n(i, \"verseRangeSeparator\", \"-\"), n(i, \"verseSequenceIndicator\", \",\"), n(i, \"verseRangeSeparators\", [i.verseRangeSeparator]), n(i, \"verseSequenceIndicators\", [i.verseSequenceIndicator]), n(i, \"chapterDigitShifter\", 1e3), n(i, \"bookDigitShifter\", i.chapterDigitShifter * i.chapterDigitShifter), n(i, \"bcvMaxValue\", i.chapterDigitShifter - 1), /**\n * The valid status of the VerseRef.\n */\nn(i, \"ValidStatusType\", D);\nlet M = i;\nclass v extends Error {\n}\nexport {\n _ as BookSet,\n m as Canon,\n c as ScrVers,\n l as ScrVersType,\n M as VerseRef,\n v as VerseRefException\n};\n//# sourceMappingURL=index.es.js.map\n","import React from 'react';\nimport * as DropdownMenuPrimitive from '@radix-ui/react-dropdown-menu';\nimport { Check, ChevronRight, Circle } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport const DropdownMenu = DropdownMenuPrimitive.Root;\n\nexport const DropdownMenuTrigger = DropdownMenuPrimitive.Trigger;\n\nexport const DropdownMenuGroup = DropdownMenuPrimitive.Group;\n\nexport const DropdownMenuPortal = DropdownMenuPrimitive.Portal;\n\nexport const DropdownMenuSub = DropdownMenuPrimitive.Sub;\n\nexport const DropdownMenuRadioGroup = DropdownMenuPrimitive.RadioGroup;\n\nexport type DropdownMenuSubTriggerProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.SubTrigger\n> & {\n className?: string;\n inset?: boolean;\n};\n\nexport type DropdownMenuSubContentProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.SubContent\n> & {\n className?: string;\n};\n\nexport type DropdownMenuContentProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Content\n> & {\n className?: string;\n sideOffset?: number;\n};\n\nexport type DropdownMenuItemProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Item\n> & {\n className?: string;\n inset?: boolean;\n};\n\nexport type DropdownMenuCheckboxItemProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.CheckboxItem\n> & {\n className?: string;\n checked?: boolean;\n};\n\nexport type DropdownMenuRadioItemProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.RadioItem\n> & {\n className?: string;\n};\n\nexport type DropdownMenuLabelProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Label\n> & {\n className?: string;\n inset?: boolean;\n};\n\nexport type DropdownMenuSeparatorProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Separator\n> & {\n className?: string;\n};\n\nexport type DropdownMenuShortcutProps = React.HTMLAttributes & {\n className?: string;\n};\n\nexport const DropdownMenuSubTrigger = React.forwardRef<\n React.ElementRef,\n DropdownMenuSubTriggerProps\n>(({ className, inset, children, ...props }, ref) => (\n \n {children}\n \n \n));\nDropdownMenuSubTrigger.displayName = DropdownMenuPrimitive.SubTrigger.displayName;\n\nexport const DropdownMenuSubContent = React.forwardRef<\n React.ElementRef,\n DropdownMenuSubContentProps\n>(({ className, ...props }, ref) => (\n \n));\nDropdownMenuSubContent.displayName = DropdownMenuPrimitive.SubContent.displayName;\n\nexport const DropdownMenuContent = React.forwardRef<\n React.ElementRef,\n DropdownMenuContentProps\n>(({ className, sideOffset = 4, ...props }, ref) => (\n \n \n \n));\nDropdownMenuContent.displayName = DropdownMenuPrimitive.Content.displayName;\n\n/**\n * TODO: fix: direction is not automatically handled by this component, so that shortcuts are\n * display always to the right\n */\nexport const DropdownMenuItem = React.forwardRef<\n React.ElementRef,\n DropdownMenuItemProps\n>(({ className, inset, ...props }, ref) => (\n \n));\nDropdownMenuItem.displayName = DropdownMenuPrimitive.Item.displayName;\n\nexport const DropdownMenuCheckboxItem = React.forwardRef<\n React.ElementRef,\n DropdownMenuCheckboxItemProps\n>(({ className, children, checked, ...props }, ref) => (\n \n \n \n \n \n \n {children}\n \n));\nDropdownMenuCheckboxItem.displayName = DropdownMenuPrimitive.CheckboxItem.displayName;\n\nexport const DropdownMenuRadioItem = React.forwardRef<\n React.ElementRef,\n DropdownMenuRadioItemProps\n>(({ className, children, ...props }, ref) => (\n \n \n \n \n \n \n {children}\n \n));\nDropdownMenuRadioItem.displayName = DropdownMenuPrimitive.RadioItem.displayName;\n\nexport const DropdownMenuLabel = React.forwardRef<\n React.ElementRef,\n DropdownMenuLabelProps\n>(({ className, inset, ...props }, ref) => (\n \n));\nDropdownMenuLabel.displayName = DropdownMenuPrimitive.Label.displayName;\n\nexport const DropdownMenuSeparator = React.forwardRef<\n React.ElementRef,\n DropdownMenuSeparatorProps\n>(({ className, ...props }, ref) => (\n \n));\nDropdownMenuSeparator.displayName = DropdownMenuPrimitive.Separator.displayName;\n\nexport function DropdownMenuShortcut({ className, ...props }: DropdownMenuShortcutProps) {\n return (\n \n );\n}\nDropdownMenuShortcut.displayName = 'DropdownMenuShortcut';\n","import { Canon } from '@sillsdev/scripture';\nimport { PropsWithChildren, KeyboardEvent, forwardRef } from 'react';\nimport { DropdownMenuItem as ShadDropdownMenuItem } from '@/components/shadcn-ui/dropdown-menu';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport type BookType = 'OT' | 'NT' | 'DC';\n\ntype BookMenuItemProps = PropsWithChildren<{\n /** String id of book */\n bookId: string;\n /** Callback to run when a book menu item is selected */\n handleSelectBook: () => void;\n /** Indicates if this menu item is currently selected */\n isSelected: boolean;\n /** Function that is called upon highlighting a book in the dropdown menu */\n handleHighlightBook: () => void;\n /**\n * Function that is called on pressing a key\n *\n * @param event Event that contains information about the key stroke\n */\n handleKeyDown: (event: KeyboardEvent) => void;\n /**\n * Type of book associated with this menu item, coordinates color labels ? Mock up has the labels\n * coordinated to genre\n */\n bookType: BookType;\n}>;\n\nconst BookMenuItem = forwardRef(\n (\n {\n bookId,\n handleSelectBook,\n isSelected,\n handleHighlightBook,\n handleKeyDown,\n bookType,\n children,\n }: BookMenuItemProps,\n ref,\n ) => {\n return (\n {\n // preventDefault() here prevents the entire dropdown menu from closing when selecting this item\n event.preventDefault();\n handleSelectBook();\n }}\n onKeyDown={(event: KeyboardEvent) => {\n handleKeyDown(event);\n }}\n onFocus={handleHighlightBook}\n onMouseMove={handleHighlightBook}\n >\n \n {Canon.bookIdToEnglishName(bookId)}\n \n {isSelected &&
    {children}
    }\n \n );\n },\n);\n\nexport default BookMenuItem;\n","import { cn } from '@/utils/shadcn-ui.util';\nimport { useCallback } from 'react';\n\nexport type ChapterSelectProps = {\n /**\n * Callback to run when a chapter div is selected\n *\n * @param chapterNumber Number of the chapter that has been selected\n */\n handleSelectChapter: (chapterNumber: number) => void;\n /** The highest chapter number in the book (of course equal to number of chapters in the book) */\n endChapter: number;\n /** The chapter number that is currently selected */\n activeChapter: number;\n /** The chapter number that is currently highlighted using keyboard or mouse navigation */\n highlightedChapter: number;\n /**\n * Callback to run when a chapter is highlighted by the user\n *\n * @param chapterNumber The chapter that is highlighted\n */\n handleHighlightedChapter: (chapterNumber: number) => void;\n};\n\nfunction ChapterSelect({\n handleSelectChapter,\n endChapter,\n activeChapter,\n highlightedChapter,\n handleHighlightedChapter,\n}: ChapterSelectProps) {\n const chapters = Array.from({ length: endChapter }, (_, i) => i + 1);\n\n const handleMouse = useCallback(\n (chapterNumber: number) => {\n handleHighlightedChapter(chapterNumber);\n },\n [handleHighlightedChapter],\n );\n\n return (\n
    \n {chapters.map((chapter) => (\n {\n event.preventDefault();\n event.stopPropagation();\n handleSelectChapter(chapter);\n }}\n role=\"button\"\n onKeyDown={(event) => {\n if (event.key === 'Enter') {\n handleSelectChapter(chapter);\n }\n }}\n tabIndex={0}\n onMouseMove={() => handleMouse(chapter)}\n >\n {chapter}\n
    \n ))}\n
    \n );\n}\n\nexport default ChapterSelect;\n","import { DropdownMenuLabel as ShadDropdownMenuLabel } from '@/components/shadcn-ui/dropdown-menu';\nimport { Bookmark, Clock, ArrowDownWideNarrow } from 'lucide-react';\n\nexport type GoToMenuItemProps = {\n handleSort: () => void;\n handleLocationHistory: () => void;\n handleBookmarks: () => void;\n};\n\nfunction GoToMenuItem({ handleSort, handleLocationHistory, handleBookmarks }: GoToMenuItemProps) {\n return (\n \n

    Go To

    \n
    \n \n \n \n
    \n
    \n );\n}\n\nexport default GoToMenuItem;\n","import BookChapterInput from '@/components/advanced/book-chapter-control/book-chapter-input.component';\nimport BookMenuItem, {\n BookType,\n} from '@/components/advanced/book-chapter-control/book-menu-item.component';\nimport ChapterSelect from '@/components/advanced/book-chapter-control/chapter-select.component';\nimport GoToMenuItem from '@/components/advanced/book-chapter-control/go-to-menu-item.component';\nimport {\n DropdownMenu as ShadDropdownMenu,\n DropdownMenuContent as ShadDropdownMenuContent,\n DropdownMenuLabel as ShadDropdownMenuLabel,\n DropdownMenuSeparator as ShadDropdownMenuSeparator,\n DropdownMenuTrigger as ShadDropdownMenuTrigger,\n} from '@/components/shadcn-ui/dropdown-menu';\nimport { Canon } from '@sillsdev/scripture';\nimport { ScriptureReference, getChaptersForBook } from 'platform-bible-utils';\nimport {\n KeyboardEvent as ReactKeyboardEvent,\n useCallback,\n useEffect,\n useLayoutEffect,\n useRef,\n useState,\n} from 'react';\n\ntype BookTypeLabels = {\n [bookType in BookType]: string;\n};\ntype BookChapterControlProps = {\n scrRef: ScriptureReference;\n handleSubmit: (scrRef: ScriptureReference) => void;\n};\n\nconst ALL_BOOK_IDS = Canon.allBookIds;\nconst BOOK_TYPE_LABELS: BookTypeLabels = {\n OT: 'Old Testament',\n NT: 'New Testament',\n DC: 'Deuterocanon',\n};\nconst BOOK_TYPE_ARRAY: BookType[] = ['OT', 'NT', 'DC'];\n// This is the height of three menu items to offset scrolling to the selected menu item\n// If you use menuItemRef.clientHeight- includes height of chapter div which is too big\nconst SCROLL_OFFSET = 32 + 32 + 32;\nconst SEARCH_QUERY_FORMATS = [\n /^(\\w+)$/i, // Matches a single word (book name or id)\n /^(\\w+)(?:\\s(\\d+))$/i, // Matches a word followed by a chapter number\n /^(\\w+)(?:\\s(\\d+):(\\d+))$/i, // Matches a word followed by a chapter and verse number\n];\nconst fetchGroupedBooks = (bookType: BookType) => {\n const groupedBooks = {\n OT: ALL_BOOK_IDS.filter((bookId) => Canon.isBookOT(bookId)),\n NT: ALL_BOOK_IDS.filter((bookId) => Canon.isBookNT(bookId)),\n DC: ALL_BOOK_IDS.filter((bookId) => Canon.isBookDC(bookId)),\n };\n return groupedBooks[bookType];\n};\nconst fetchEndChapter = (bookId: string) => {\n // getChaptersForBook returns -1 if not found in scrBookData\n // scrBookData only includes OT and NT, so all DC will return -1\n return getChaptersForBook(Canon.bookIdToNumber(bookId));\n};\n\n/**\n * Gets all of the English names from book ids\n *\n * @returns String[]\n */\nfunction getAllEnglishNames(): string[] {\n const allEnglishNames = ALL_BOOK_IDS.map((bookId) => {\n return Canon.bookIdToEnglishName(bookId);\n });\n return allEnglishNames;\n}\n\n/**\n * Determines if bookName is in allEnglishNames\n *\n * @param bookName Book English name\n * @returns True if bookName is included, false otherwise\n */\nfunction isValidBookEnglishName(bookName: string): boolean {\n return getAllEnglishNames().includes(bookName);\n}\n\n/**\n * Gets a bookId from given English name\n *\n * @param bookName Book English name\n * @returns BookId of provided bookName, undefined otherwise\n */\nfunction getBookIdFromEnglishName(bookName: string): string | undefined {\n // Convert bookName to lowercase and then capitalize the first letter\n const formattedBookName = bookName.toLowerCase().replace(/^\\w/, (c) => c.toUpperCase());\n\n if (isValidBookEnglishName(formattedBookName)) {\n const matchingBookId = ALL_BOOK_IDS.find((bookId) => {\n return Canon.bookIdToEnglishName(bookId) === formattedBookName;\n });\n return matchingBookId;\n }\n\n return undefined;\n}\n\nfunction BookChapterControl({ scrRef, handleSubmit }: BookChapterControlProps) {\n const [searchQuery, setSearchQuery] = useState('');\n const [selectedBookId, setSelectedBookId] = useState(\n Canon.bookNumberToId(scrRef.bookNum),\n );\n const [highlightedChapter, setHighlightedChapter] = useState(scrRef.chapterNum ?? 0);\n const [highlightedBookId, setHighlightedBookId] = useState(\n Canon.bookNumberToId(scrRef.bookNum),\n );\n const [isContentOpen, setIsContentOpen] = useState(false);\n const [isContentOpenDelayed, setIsContentOpenDelayed] = useState(isContentOpen);\n\n // This ref will always be defined\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const inputRef = useRef(undefined!);\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const contentRef = useRef(undefined!);\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const menuItemRef = useRef(undefined!);\n\n const fetchFilteredBooks = useCallback(\n (bookType: BookType) => {\n return fetchGroupedBooks(bookType).filter((bookId: string) => {\n const englishNameLowerCase = Canon.bookIdToEnglishName(bookId).toLowerCase();\n const normalizedQuery = searchQuery.replace(/[^a-zA-Z]/g, '').toLowerCase();\n return (\n englishNameLowerCase.includes(normalizedQuery) || // Match book name\n bookId.toLowerCase().includes(normalizedQuery) // Match book ID\n );\n });\n },\n [searchQuery],\n );\n\n const handleSearchInput = (searchString: string) => {\n setSearchQuery(searchString);\n };\n\n /**\n * Whether to prevent radix's logic from closing the dropdown. This is important because radix\n * tries to close the dropdown when the input first focuses, and we don't want it to do that. But\n * we don't want to prevent the dropdown from closing when we click away from the input, so we\n * don't want to just keep it open if the input is focused\n */\n const shouldPreventAutoClosing = useRef(false);\n\n const controlMenuState = useCallback((open: boolean) => {\n if (shouldPreventAutoClosing.current) {\n shouldPreventAutoClosing.current = false;\n return;\n }\n setIsContentOpen(open);\n }, []);\n\n const updateReference = useCallback(\n (bookId: string, shouldClose: boolean, chapter?: number, verse?: number) => {\n setHighlightedChapter(\n Canon.bookNumberToId(scrRef.bookNum) !== bookId ? 1 : scrRef.chapterNum,\n );\n\n if (shouldClose || fetchEndChapter(bookId) === -1) {\n handleSubmit({\n bookNum: Canon.bookIdToNumber(bookId),\n chapterNum: chapter || 1,\n verseNum: verse || 1,\n });\n\n setIsContentOpen(false);\n setSearchQuery('');\n return;\n }\n\n setSelectedBookId(selectedBookId !== bookId ? bookId : '');\n setIsContentOpen(!shouldClose);\n },\n [handleSubmit, scrRef.bookNum, scrRef.chapterNum, selectedBookId],\n );\n\n const handleSelectChapter = (chapterNumber: number) => {\n if (chapterNumber <= 0 || chapterNumber > fetchEndChapter(selectedBookId)) {\n return;\n }\n updateReference(selectedBookId, true, chapterNumber);\n };\n\n const handleInputSubmit = useCallback(() => {\n SEARCH_QUERY_FORMATS.forEach((format) => {\n const matches = searchQuery.match(format);\n if (matches) {\n // Book should be a bookId or an english name\n const [book, chapter = undefined, verse = undefined] = matches.slice(1);\n const englishName = getBookIdFromEnglishName(book);\n\n if (Canon.isBookIdValid(book) || englishName) {\n updateReference(\n englishName ?? book,\n true,\n chapter ? parseInt(chapter, 10) : 1,\n verse ? parseInt(verse, 10) : 1,\n );\n }\n }\n });\n }, [updateReference, searchQuery]);\n\n const handleKeyDownInput = useCallback(\n (event: ReactKeyboardEvent) => {\n if (!isContentOpen) {\n setIsContentOpen(true);\n } else if (event.key === 'ArrowDown' || event.key === 'ArrowUp') {\n if (\n typeof menuItemRef !== 'undefined' &&\n // Ref uses null\n // eslint-disable-next-line no-null/no-null\n menuItemRef.current !== null\n ) {\n menuItemRef.current.focus();\n } else if (\n typeof contentRef !== 'undefined' &&\n // Ref uses null\n // eslint-disable-next-line no-null/no-null\n contentRef.current !== null\n ) {\n contentRef.current.focus();\n }\n event.preventDefault();\n }\n },\n [isContentOpen],\n );\n\n const handleKeyDownContent = (event: ReactKeyboardEvent) => {\n // When the dropdown menu has focus, key strokes should give focus to the input component,\n // unless they're navigation keys (arrows and enter)\n const { key } = event;\n if (\n key === 'ArrowRight' ||\n key === 'ArrowLeft' ||\n key === 'ArrowDown' ||\n key === 'ArrowUp' ||\n key === 'Enter'\n ) {\n return;\n }\n\n inputRef.current.dispatchEvent(new KeyboardEvent('keydown', { key }));\n inputRef.current.focus();\n };\n\n const handleKeyDownMenuItem = (event: ReactKeyboardEvent) => {\n const { key } = event;\n if (highlightedBookId === selectedBookId) {\n if (key === 'Enter') {\n event.preventDefault();\n updateReference(selectedBookId, true, highlightedChapter);\n return;\n }\n\n let chapterOffSet = 0;\n if (key === 'ArrowRight') {\n if (highlightedChapter < fetchEndChapter(highlightedBookId)) {\n chapterOffSet = 1;\n } else {\n event.preventDefault();\n return;\n }\n } else if (key === 'ArrowLeft') {\n if (highlightedChapter > 1) {\n chapterOffSet = -1;\n } else {\n event.preventDefault();\n return;\n }\n } else if (key === 'ArrowDown') {\n chapterOffSet = 6;\n } else if (key === 'ArrowUp') {\n chapterOffSet = -6;\n }\n if (\n highlightedChapter + chapterOffSet <= 0 ||\n highlightedChapter + chapterOffSet > fetchEndChapter(highlightedBookId)\n ) {\n setHighlightedChapter(0);\n } else if (chapterOffSet !== 0) {\n setHighlightedChapter(highlightedChapter + chapterOffSet);\n event.preventDefault();\n }\n }\n };\n\n useEffect(() => {\n if (selectedBookId === highlightedBookId) {\n if (selectedBookId === Canon.bookNumberToId(scrRef.bookNum)) {\n setHighlightedChapter(scrRef.chapterNum);\n } else {\n setHighlightedChapter(1);\n }\n } else {\n setHighlightedChapter(0);\n }\n }, [highlightedBookId, scrRef.bookNum, scrRef.chapterNum, selectedBookId]);\n\n // The purpose of these useLayoutEffects and timeout is to delay the scroll just\n // enough so that the refs are defined and available when they are used after the timeout\n useLayoutEffect(() => {\n setIsContentOpenDelayed(isContentOpen);\n }, [isContentOpen]);\n\n useLayoutEffect(() => {\n const scrollTimeout = setTimeout(() => {\n if (isContentOpenDelayed && contentRef.current && menuItemRef.current) {\n const menuItemOffsetTop = menuItemRef.current.offsetTop;\n const scrollPosition = menuItemOffsetTop - SCROLL_OFFSET;\n contentRef.current.scrollTo({ top: scrollPosition, behavior: 'instant' });\n }\n }, 10);\n return () => {\n clearTimeout(scrollTimeout);\n };\n }, [isContentOpenDelayed]);\n\n return (\n
    \n \n \n {\n setSelectedBookId(Canon.bookNumberToId(scrRef.bookNum));\n setHighlightedBookId(Canon.bookNumberToId(scrRef.bookNum));\n setHighlightedChapter(scrRef.chapterNum > 0 ? scrRef.chapterNum : 0);\n setIsContentOpen(true);\n inputRef.current.focus();\n }}\n onFocus={() => {\n // Radix thinks we want to close because the input is being focused. Prevent that\n shouldPreventAutoClosing.current = true;\n }}\n handleSubmit={handleInputSubmit}\n placeholder={`${Canon.bookNumberToEnglishName(scrRef.bookNum)} ${scrRef.chapterNum}:${scrRef.verseNum}`}\n />\n \n \n console.log('sorting')}\n handleLocationHistory={() => console.log('location history')}\n handleBookmarks={() => console.log('bookmarks')}\n />\n {BOOK_TYPE_ARRAY.map(\n (bookType, bookTypeIndex) =>\n fetchFilteredBooks(bookType).length > 0 && (\n
    \n \n {BOOK_TYPE_LABELS[bookType]}\n \n\n {fetchFilteredBooks(bookType).map((bookId) => (\n
    \n updateReference(bookId, false)}\n isSelected={selectedBookId === bookId}\n handleHighlightBook={() => setHighlightedBookId(bookId)}\n handleKeyDown={handleKeyDownMenuItem}\n bookType={bookType}\n ref={(element: HTMLDivElement) => {\n if (selectedBookId === bookId) menuItemRef.current = element;\n }}\n >\n {\n setHighlightedChapter(chapterNumber);\n }}\n />\n \n
    \n ))}\n {BOOK_TYPE_ARRAY.length - 1 !== bookTypeIndex ? (\n \n ) : undefined}\n
    \n ),\n )}\n \n
    \n
    \n );\n}\n\nexport default BookChapterControl;\n","import React from 'react';\nimport { Slot } from '@radix-ui/react-slot';\nimport { cva, type VariantProps } from 'class-variance-authority';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport const buttonVariants = cva(\n 'pr-twp tw-inline-flex tw-items-center tw-justify-center tw-whitespace-nowrap tw-rounded-md tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-colors focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50',\n {\n variants: {\n variant: {\n default: 'tw-bg-primary tw-text-primary-foreground hover:tw-bg-primary/90',\n destructive: 'tw-bg-destructive tw-text-destructive-foreground hover:tw-bg-destructive/90',\n outline:\n 'tw-border tw-border-input tw-bg-background hover:tw-bg-accent hover:tw-text-accent-foreground',\n secondary: 'tw-bg-secondary tw-text-secondary-foreground hover:tw-bg-secondary/80',\n ghost: 'hover:tw-bg-accent hover:tw-text-accent-foreground',\n link: 'tw-text-primary tw-underline-offset-4 hover:tw-underline',\n },\n size: {\n default: 'tw-h-10 tw-px-4 tw-py-2',\n sm: 'tw-h-9 tw-rounded-md tw-px-3',\n lg: 'tw-h-11 tw-rounded-md tw-px-8',\n icon: 'tw-h-10 tw-w-10',\n },\n },\n defaultVariants: {\n variant: 'default',\n size: 'default',\n },\n },\n);\n\nexport interface ButtonProps\n extends React.ButtonHTMLAttributes,\n VariantProps {\n asChild?: boolean;\n}\n\nexport const Button = React.forwardRef(\n ({ className, variant, size, asChild = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'button';\n return (\n \n );\n },\n);\nButton.displayName = 'Button';\n","import React from 'react';\nimport * as LabelPrimitive from '@radix-ui/react-label';\nimport { cva, type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst labelVariants = cva(\n 'tw-text-sm tw-font-medium tw-leading-none peer-disabled:tw-cursor-not-allowed peer-disabled:tw-opacity-70',\n);\n\nexport const Label = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef & VariantProps\n>(({ className, ...props }, ref) => (\n \n));\nLabel.displayName = LabelPrimitive.Root.displayName;\n","import React from 'react';\nimport * as RadioGroupPrimitive from '@radix-ui/react-radio-group';\nimport { Circle } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst RadioGroup = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => {\n return (\n \n );\n});\nRadioGroup.displayName = RadioGroupPrimitive.Root.displayName;\n\nconst RadioGroupItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => {\n return (\n \n \n \n \n \n );\n});\nRadioGroupItem.displayName = RadioGroupPrimitive.Item.displayName;\n\nexport { RadioGroup, RadioGroupItem };\n","import React from 'react';\nimport * as PopoverPrimitive from '@radix-ui/react-popover';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Popover = PopoverPrimitive.Root;\n\nconst PopoverTrigger = PopoverPrimitive.Trigger;\n\nconst PopoverContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, align = 'center', sideOffset = 4, ...props }, ref) => (\n \n \n \n));\nPopoverContent.displayName = PopoverPrimitive.Content.displayName;\n\nexport { Popover, PopoverTrigger, PopoverContent };\n","import React from 'react';\nimport * as DialogPrimitive from '@radix-ui/react-dialog';\nimport { X } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Dialog = DialogPrimitive.Root;\n\nconst DialogTrigger = DialogPrimitive.Trigger;\n\nconst DialogPortal = DialogPrimitive.Portal;\n\nconst DialogClose = DialogPrimitive.Close;\n\nconst DialogOverlay = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nDialogOverlay.displayName = DialogPrimitive.Overlay.displayName;\n\nconst DialogContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, ...props }, ref) => (\n \n \n \n {children}\n \n \n Close\n \n \n \n));\nDialogContent.displayName = DialogPrimitive.Content.displayName;\n\nfunction DialogHeader({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nDialogHeader.displayName = 'DialogHeader';\n\nfunction DialogFooter({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nDialogFooter.displayName = 'DialogFooter';\n\nconst DialogTitle = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nDialogTitle.displayName = DialogPrimitive.Title.displayName;\n\nconst DialogDescription = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nDialogDescription.displayName = DialogPrimitive.Description.displayName;\n\nexport {\n Dialog,\n DialogPortal,\n DialogOverlay,\n DialogClose,\n DialogTrigger,\n DialogContent,\n DialogHeader,\n DialogFooter,\n DialogTitle,\n DialogDescription,\n};\n","import React from 'react';\nimport { type DialogProps } from '@radix-ui/react-dialog';\nimport { Command as CommandPrimitive } from 'cmdk';\nimport { Search } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Dialog, DialogContent } from '@/components/shadcn-ui/dialog';\n\nconst Command = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nCommand.displayName = CommandPrimitive.displayName;\n\ninterface CommandDialogProps extends DialogProps {}\n\nfunction CommandDialog({ children, ...props }: CommandDialogProps) {\n return (\n \n \n \n {children}\n \n \n \n );\n}\n\nconst CommandInput = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n
    \n \n \n
    \n));\n\nCommandInput.displayName = CommandPrimitive.Input.displayName;\n\nconst CommandList = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\n\nCommandList.displayName = CommandPrimitive.List.displayName;\n\nconst CommandEmpty = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>((props, ref) => (\n \n));\n\nCommandEmpty.displayName = CommandPrimitive.Empty.displayName;\n\nconst CommandGroup = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\n\nCommandGroup.displayName = CommandPrimitive.Group.displayName;\n\nconst CommandSeparator = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nCommandSeparator.displayName = CommandPrimitive.Separator.displayName;\n\nconst CommandItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\n\nCommandItem.displayName = CommandPrimitive.Item.displayName;\n\nfunction CommandShortcut({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nCommandShortcut.displayName = 'CommandShortcut';\n\nexport {\n Command,\n CommandDialog,\n CommandInput,\n CommandList,\n CommandEmpty,\n CommandGroup,\n CommandItem,\n CommandShortcut,\n CommandSeparator,\n};\n","import { useState } from 'react';\nimport { Check, ChevronsUpDown } from 'lucide-react';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport { Popover, PopoverContent, PopoverTrigger } from '@/components/shadcn-ui/popover';\nimport {\n Command,\n CommandEmpty,\n CommandInput,\n CommandItem,\n CommandList,\n} from '@/components/shadcn-ui/command';\nimport { PopoverProps } from '@radix-ui/react-popover';\n\nexport type ComboBoxLabelOption = { label: string };\nexport type ComboBoxOption = string | number | ComboBoxLabelOption;\n\nexport type ComboBoxProps = {\n /** Optional unique identifier */\n id?: string;\n /** Text label title for combobox */\n /** List of available options for the dropdown menu */\n options?: readonly T[];\n /** Additional css classes to help with unique styling of the combo box button */\n buttonClassName?: string;\n /** Additional css classes to help with unique styling of the combo box popover */\n popoverContentClassName?: string;\n /**\n * The selected value that the combo box currently holds. Must be shallow equal to one of the\n * options entries.\n */\n value?: T;\n /** Triggers when content of textfield is changed */\n onChange?: (newValue: T) => void;\n /** Used to determine the string value for a given option. */\n getOptionLabel?: (option: ComboBoxOption) => string;\n /** Text displayed on button if `value` is undefined */\n buttonPlaceholder?: string;\n /** Placeholder text for text field */\n textPlaceholder?: string;\n /** Text to display when no options match input */\n commandEmptyMessage?: string;\n /** Variant of button */\n buttonVariant?: ButtonProps['variant'];\n /** Text direction ltr or rtl */\n dir?: Direction;\n /** Optional boolean to set if trigger should be disabled */\n isDisabled?: boolean;\n} & PopoverProps;\n\ntype Direction = 'ltr' | 'rtl';\n\nfunction getOptionLabelDefault(option: ComboBoxOption): string {\n if (typeof option === 'string') {\n return option;\n }\n if (typeof option === 'number') {\n return option.toString();\n }\n return option.label;\n}\n\n/**\n * Autocomplete input and command palette with a list of suggestions.\n *\n * Thanks to Shadcn for heavy inspiration and documentation\n * https://ui.shadcn.com/docs/components/combobox\n */\nfunction ComboBox({\n id,\n options = [],\n buttonClassName,\n popoverContentClassName,\n value,\n onChange = () => {},\n getOptionLabel = getOptionLabelDefault,\n buttonPlaceholder = '',\n textPlaceholder = '',\n commandEmptyMessage = 'No option found',\n buttonVariant = 'outline',\n dir = 'ltr',\n isDisabled = false,\n ...props\n}: ComboBoxProps) {\n const [open, setOpen] = useState(false);\n\n return (\n \n \n \n \n {value ? getOptionLabel(value) : buttonPlaceholder}\n \n \n \n \n \n \n \n {commandEmptyMessage}\n \n {options.map((option) => (\n {\n onChange(option);\n setOpen(false);\n }}\n >\n \n {getOptionLabel(option)}\n \n ))}\n \n \n \n \n );\n}\n\nexport default ComboBox;\n","import { useMemo } from 'react';\nimport ComboBox from '@/components/basics/combo-box.component';\nimport { Label } from '@/components/shadcn-ui/label';\n\nexport type ChapterRangeSelectorProps = {\n startChapter: number;\n endChapter: number;\n handleSelectStartChapter: (chapter: number) => void;\n handleSelectEndChapter: (chapter: number) => void;\n isDisabled?: boolean;\n chapterCount: number;\n};\n\nexport default function ChapterRangeSelector({\n startChapter,\n endChapter,\n handleSelectStartChapter,\n handleSelectEndChapter,\n isDisabled = false,\n chapterCount,\n}: ChapterRangeSelectorProps) {\n const chapterOptions = useMemo(\n () => Array.from({ length: chapterCount }, (_, index) => index + 1),\n [chapterCount],\n );\n\n const onChangeStartChapter = (value: number) => {\n handleSelectStartChapter(value);\n if (value > endChapter) {\n handleSelectEndChapter(value);\n }\n };\n\n const onChangeEndChapter = (value: number) => {\n handleSelectEndChapter(value);\n if (value < startChapter) {\n handleSelectStartChapter(value);\n }\n };\n\n return (\n <>\n \n option.toString()}\n value={startChapter}\n />\n\n \n option.toString()}\n value={endChapter}\n />\n \n );\n}\n","import { Button } from '@/components/shadcn-ui/button';\nimport { Label } from '@/components/shadcn-ui/label';\nimport { RadioGroup, RadioGroupItem } from '@/components/shadcn-ui/radio-group';\nimport { Canon } from '@sillsdev/scripture';\nimport { LocalizedStringValue } from 'platform-bible-utils';\nimport { useState } from 'react';\nimport ChapterRangeSelector, {\n ChapterRangeSelectorProps,\n} from '../basics/chapter-range-selector.component';\n\nexport enum BookSelectionMode {\n CURRENT_BOOK = 'current book',\n CHOOSE_BOOKS = 'choose books',\n}\n\n/**\n * Object containing all keys used for localization in this component. If you're using this\n * component in an extension, you can pass it into the useLocalizedStrings hook to easily obtain the\n * localized strings and pass them into the localizedStrings prop of this component\n */\nexport const BOOK_SELECTOR_STRING_KEYS = Object.freeze([\n '%webView_bookSelector_currentBook%',\n '%webView_bookSelector_choose%',\n '%webView_bookSelector_chooseBooks%',\n] as const);\n\nexport type BookSelectorLocalizedStrings = {\n [localizedInventoryKey in (typeof BOOK_SELECTOR_STRING_KEYS)[number]]?: LocalizedStringValue;\n};\n\n/**\n * Gets the localized value for the provided key\n *\n * @param strings Object containing localized string\n * @param key Key for a localized string\n * @returns The localized value for the provided key, if available. Returns the key if no localized\n * value is available\n */\nconst localizeString = (\n strings: BookSelectorLocalizedStrings,\n key: keyof BookSelectorLocalizedStrings,\n) => {\n return strings[key] ?? key;\n};\n\ntype BookSelectorProps = ChapterRangeSelectorProps & {\n handleBookSelectionModeChange: (newMode: BookSelectionMode) => void;\n currentBookName: string;\n onSelectBooks: () => void;\n selectedBookIds: string[];\n localizedStrings: BookSelectorLocalizedStrings;\n};\n\nexport default function BookSelector({\n handleBookSelectionModeChange,\n currentBookName,\n onSelectBooks,\n selectedBookIds,\n chapterCount,\n endChapter,\n handleSelectEndChapter,\n startChapter,\n handleSelectStartChapter,\n localizedStrings,\n}: BookSelectorProps) {\n const currentBookText = localizeString(localizedStrings, '%webView_bookSelector_currentBook%');\n const chooseText = localizeString(localizedStrings, '%webView_bookSelector_choose%');\n const chooseBooksText = localizeString(localizedStrings, '%webView_bookSelector_chooseBooks%');\n\n const [bookSelectionMode, setBookSelectionMode] = useState(\n BookSelectionMode.CURRENT_BOOK,\n );\n\n const onSelectionModeChange = (newMode: BookSelectionMode) => {\n setBookSelectionMode(newMode);\n handleBookSelectionModeChange(newMode);\n };\n\n return (\n onSelectionModeChange(value as BookSelectionMode)}\n >\n
    \n
    \n
    \n \n \n
    \n \n
    \n \n
    \n
    \n
    \n
    \n \n \n
    \n \n onSelectBooks()}\n >\n {chooseText}\n \n
    \n
    \n \n );\n}\n","import { DropdownMenuTrigger } from '@radix-ui/react-dropdown-menu';\nimport { FilterIcon } from 'lucide-react';\nimport { Table } from '@tanstack/react-table';\n\nimport { Button } from '@/components/shadcn-ui/button';\nimport {\n DropdownMenu,\n DropdownMenuCheckboxItem,\n DropdownMenuContent,\n DropdownMenuLabel,\n DropdownMenuSeparator,\n} from '@/components/shadcn-ui/dropdown-menu';\n\ninterface DataTableViewOptionsProps {\n table: Table;\n}\n\nfunction DataTableViewOptions({ table }: DataTableViewOptionsProps) {\n return (\n \n \n \n \n \n Toggle columns\n \n {table\n .getAllColumns()\n .filter((column) => column.getCanHide())\n .map((column) => {\n return (\n column.toggleVisibility(!!value)}\n >\n {column.id}\n \n );\n })}\n \n \n );\n}\n\nexport default DataTableViewOptions;\n","import React from 'react';\nimport * as SelectPrimitive from '@radix-ui/react-select';\nimport { Check, ChevronDown, ChevronUp } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Select = SelectPrimitive.Root;\n\nconst SelectGroup = SelectPrimitive.Group;\n\nconst SelectValue = SelectPrimitive.Value;\n\nconst SelectTrigger = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, ...props }, ref) => (\n span]:tw-line-clamp-1',\n className,\n )}\n {...props}\n >\n {children}\n \n \n \n \n));\nSelectTrigger.displayName = SelectPrimitive.Trigger.displayName;\n\nconst SelectScrollUpButton = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n));\nSelectScrollUpButton.displayName = SelectPrimitive.ScrollUpButton.displayName;\n\nconst SelectScrollDownButton = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n));\nSelectScrollDownButton.displayName = SelectPrimitive.ScrollDownButton.displayName;\n\nconst SelectContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, position = 'popper', ...props }, ref) => (\n \n \n \n \n {children}\n \n \n \n \n));\nSelectContent.displayName = SelectPrimitive.Content.displayName;\n\nconst SelectLabel = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSelectLabel.displayName = SelectPrimitive.Label.displayName;\n\nconst SelectItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, ...props }, ref) => (\n \n \n \n \n \n \n\n {children}\n \n));\nSelectItem.displayName = SelectPrimitive.Item.displayName;\n\nconst SelectSeparator = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSelectSeparator.displayName = SelectPrimitive.Separator.displayName;\n\nexport {\n Select,\n SelectGroup,\n SelectValue,\n SelectTrigger,\n SelectContent,\n SelectLabel,\n SelectItem,\n SelectSeparator,\n SelectScrollUpButton,\n SelectScrollDownButton,\n};\n","import { ChevronLeftIcon, ChevronRightIcon, ArrowLeftIcon, ArrowRightIcon } from 'lucide-react';\nimport { Table } from '@tanstack/react-table';\n\nimport { Button } from '@/components/shadcn-ui/button';\nimport {\n Select,\n SelectContent,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\n\ninterface DataTablePaginationProps {\n table: Table;\n}\n\nfunction DataTablePagination({ table }: DataTablePaginationProps) {\n return (\n
    \n
    \n
    \n {table.getFilteredSelectedRowModel().rows.length} of{' '}\n {table.getFilteredRowModel().rows.length} row(s) selected\n
    \n
    \n

    Rows per page

    \n {\n table.setPageSize(Number(value));\n }}\n >\n \n \n \n \n {[10, 20, 30, 40, 50].map((pageSize) => (\n \n {pageSize}\n \n ))}\n \n \n
    \n
    \n Page {table.getState().pagination.pageIndex + 1} of {table.getPageCount()}\n
    \n
    \n table.setPageIndex(0)}\n disabled={!table.getCanPreviousPage()}\n >\n Go to first page\n \n \n table.previousPage()}\n disabled={!table.getCanPreviousPage()}\n >\n Go to previous page\n \n \n table.nextPage()}\n disabled={!table.getCanNextPage()}\n >\n Go to next page\n \n \n table.setPageIndex(table.getPageCount() - 1)}\n disabled={!table.getCanNextPage()}\n >\n Go to last page\n \n \n
    \n
    \n
    \n );\n}\n\nexport default DataTablePagination;\n","import React from 'react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Table = React.forwardRef<\n HTMLTableElement,\n React.HTMLAttributes & { stickyHeader?: boolean }\n>(({ className, stickyHeader, ...props }, ref) => (\n
    \n \n
    \n));\nTable.displayName = 'Table';\n\nconst TableHeader = React.forwardRef<\n HTMLTableSectionElement,\n React.HTMLAttributes & { stickyHeader?: boolean }\n>(({ className, stickyHeader, ...props }, ref) => (\n \n));\nTableHeader.displayName = 'TableHeader';\n\nconst TableBody = React.forwardRef<\n HTMLTableSectionElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableBody.displayName = 'TableBody';\n\nconst TableFooter = React.forwardRef<\n HTMLTableSectionElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n tr]:last:tw-border-b-0', className)}\n {...props}\n />\n));\nTableFooter.displayName = 'TableFooter';\n\nconst TableRow = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nTableRow.displayName = 'TableRow';\n\nconst TableHead = React.forwardRef<\n HTMLTableCellElement,\n React.ThHTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableHead.displayName = 'TableHead';\n\nconst TableCell = React.forwardRef<\n HTMLTableCellElement,\n React.TdHTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableCell.displayName = 'TableCell';\n\nconst TableCaption = React.forwardRef<\n HTMLTableCaptionElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableCaption.displayName = 'TableCaption';\n\nexport { Table, TableHeader, TableBody, TableFooter, TableHead, TableRow, TableCell, TableCaption };\n","import { useState } from 'react';\n\nimport {\n ColumnFiltersState,\n flexRender,\n getCoreRowModel,\n getFilteredRowModel,\n getPaginationRowModel,\n getSortedRowModel,\n SortingState,\n ColumnDef as TSColumnDef,\n Row as TSRow,\n RowSelectionState as TSRowSelectionState,\n SortDirection as TSSortDirection,\n Table as TSTable,\n useReactTable,\n VisibilityState,\n} from '@tanstack/react-table';\n\nimport DataTableViewOptions from '@/components/advanced/data-table/data-table-column-toggle.component';\nimport DataTablePagination from '@/components/advanced/data-table/data-table-pagination.component';\nimport { Button } from '@/components/shadcn-ui/button';\nimport {\n Table,\n TableBody,\n TableCell,\n TableHead,\n TableHeader,\n TableRow,\n} from '@/components/shadcn-ui/table';\n\nexport type ColumnDef = TSColumnDef;\nexport type RowContents = TSRow;\nexport type TableContents = TSTable;\nexport type SortDirection = TSSortDirection;\nexport type RowSelectionState = TSRowSelectionState;\n\ninterface DataTableProps {\n columns: ColumnDef[];\n data: TData[];\n enablePagination?: boolean;\n showPaginationControls?: boolean;\n showColumnVisibilityControls?: boolean;\n stickyHeader?: boolean;\n onRowClickHandler?: (row: RowContents, table: TableContents) => void;\n}\n\n/**\n * Feature-rich table component that infuses our basic shadcn-based Table component with features\n * from TanStack's React Table library\n */\nfunction DataTable({\n columns,\n data,\n enablePagination = false,\n showPaginationControls = false,\n showColumnVisibilityControls = false,\n stickyHeader = false,\n onRowClickHandler = () => {},\n}: DataTableProps) {\n const [sorting, setSorting] = useState([]);\n const [columnFilters, setColumnFilters] = useState([]);\n const [columnVisibility, setColumnVisibility] = useState({});\n const [rowSelection, setRowSelection] = useState({});\n\n const table = useReactTable({\n data,\n columns,\n getCoreRowModel: getCoreRowModel(),\n ...(enablePagination && { getPaginationRowModel: getPaginationRowModel() }),\n onSortingChange: setSorting,\n getSortedRowModel: getSortedRowModel(),\n onColumnFiltersChange: setColumnFilters,\n getFilteredRowModel: getFilteredRowModel(),\n onColumnVisibilityChange: setColumnVisibility,\n onRowSelectionChange: setRowSelection,\n state: {\n sorting,\n columnFilters,\n columnVisibility,\n rowSelection,\n },\n });\n\n return (\n
    \n {showColumnVisibilityControls && }\n \n \n {table.getHeaderGroups().map((headerGroup) => (\n \n {headerGroup.headers.map((header) => {\n return (\n \n {header.isPlaceholder\n ? undefined\n : flexRender(header.column.columnDef.header, header.getContext())}\n \n );\n })}\n \n ))}\n \n \n {table.getRowModel().rows?.length ? (\n table.getRowModel().rows.map((row) => (\n onRowClickHandler(row, table)}\n key={row.id}\n data-state={row.getIsSelected() && 'selected'}\n >\n {row.getVisibleCells().map((cell) => (\n \n {flexRender(cell.column.columnDef.cell, cell.getContext())}\n \n ))}\n \n ))\n ) : (\n \n \n No results.\n \n \n )}\n \n
    \n {enablePagination && (\n
    \n table.previousPage()}\n disabled={!table.getCanPreviousPage()}\n >\n Previous\n \n table.nextPage()}\n disabled={!table.getCanNextPage()}\n >\n Next\n \n
    \n )}\n {enablePagination && showPaginationControls && }\n
    \n );\n}\n\nexport default DataTable;\n","import {\n Table,\n TableBody,\n TableCell,\n TableHead,\n TableHeader,\n TableRow,\n} from '@/components/shadcn-ui/table';\nimport { Canon } from '@sillsdev/scripture';\nimport { deepEqual, LanguageStrings, ScriptureReference } from 'platform-bible-utils';\nimport { useMemo } from 'react';\nimport { InventoryItemOccurrence } from './inventory-utils';\n\n/** Props for the OccurrencesTable component */\ntype OccurrencesTableProps = {\n /** Data that contains scriptures references and snippets of scripture */\n occurrenceData: InventoryItemOccurrence[];\n /** Callback function that is executed when the scripture reference is changed */\n setScriptureReference: (scriptureReference: ScriptureReference) => void;\n /**\n * Object with all localized strings that the OccurrencesTable needs to work well across multiple\n * languages\n */\n localizedStrings: LanguageStrings;\n};\n\n/**\n * Table that shows occurrences of specified inventory item(s). The first column shows the related\n * scripture reference. The second column shows the snippet of scripture that contains the specified\n * inventory item\n */\nfunction OccurrencesTable({\n occurrenceData,\n setScriptureReference,\n localizedStrings,\n}: OccurrencesTableProps) {\n const referenceHeaderText =\n localizedStrings['%webView_inventory_occurrences_table_header_reference%'];\n const occurrenceHeaderText =\n localizedStrings['%webView_inventory_occurrences_table_header_occurrence%'];\n\n const occurrences: InventoryItemOccurrence[] = useMemo(() => {\n const uniqueOccurrences: InventoryItemOccurrence[] = [];\n\n occurrenceData.forEach((occurrence) => {\n if (!uniqueOccurrences.some((uniqueOccurrence) => deepEqual(uniqueOccurrence, occurrence))) {\n uniqueOccurrences.push(occurrence);\n }\n });\n\n return uniqueOccurrences;\n }, [occurrenceData]);\n\n return (\n \n \n \n {referenceHeaderText}\n {occurrenceHeaderText}\n \n \n \n {occurrences.length > 0 &&\n occurrences.map((occurrence) => (\n {\n setScriptureReference(occurrence.reference);\n }}\n >\n {`${Canon.bookNumberToEnglishName(occurrence.reference.bookNum)} ${occurrence.reference.chapterNum}:${occurrence.reference.verseNum}`}\n {occurrence.text}\n \n ))}\n \n
    \n );\n}\n\nexport default OccurrencesTable;\n","import React from 'react';\nimport * as CheckboxPrimitive from '@radix-ui/react-checkbox';\nimport { Check } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Checkbox = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n \n \n));\nCheckbox.displayName = CheckboxPrimitive.Root.displayName;\n\nexport default Checkbox;\n","import { Canon } from '@sillsdev/scripture';\nimport { ScriptureReference } from 'platform-bible-utils';\n\n/* #region Types */\n\n/**\n * Status of items that appear in inventories. 'approved' and 'unapproved' items are defined in the\n * project's `Settings.xml`. All other items are defined as 'unknown'\n */\nexport type Status = 'approved' | 'unapproved' | 'unknown';\n\n/** Occurrence of item in inventory. Primarily used by table that shows occurrences */\nexport type InventoryItemOccurrence = {\n /** Reference to scripture where the item appears */\n reference: ScriptureReference;\n /** Snippet of scripture that contains the occurrence */\n text: string;\n};\n\n/** Data structure that contains all information on an item that is shown in an inventory */\nexport type InventoryTableData = {\n /**\n * The item (e.g. a character in the characters inventory, a marker in the marker inventory) In\n * most cases the array will only have one element. In case of additional items (e.g. the\n * preceding marker in the markers check), the primary item should be stored in the first index.\n * To show additional items in the inventory, make sure to configure the `additionalItemsLabels`\n * prop for the Inventory component\n */\n items: string[];\n /** The number of times this item occurs in the selected scope */\n count: number;\n /** The status of this item (see documentation for `Status` type for more information) */\n status: Status;\n /** Occurrences of this item in the scripture text for the selected scope */\n occurrences: InventoryItemOccurrence[];\n};\n\n/* #endregion */\n\n/* #region Functions */\n\n/**\n * Splits USFM string into shorter line-like segments\n *\n * @param text A single (likely very large) USFM string\n * @returns An array containing the input text, split into shorter segments\n */\nexport const getLinesFromUSFM = (text: string) => {\n // Splits on (CR)LF, CR, \\v, \\c and \\id\n return text.split(/(?:\\r?\\n|\\r)|(?=(?:\\\\(?:v|c|id)))/g);\n};\n\n/**\n * Extracts chapter or verse number from USFM strings that start with a \\c or \\v marker\n *\n * @param text USFM string that is expected to start with \\c or \\v marker\n * @returns Chapter or verse number if one is found. Else returns 0.\n */\nexport const getNumberFromUSFM = (text: string): number | undefined => {\n // Captures all digits that follow \\v or \\c markers followed by whitespace located at the start of a string\n const regex = /^\\\\[vc]\\s+(\\d+)/;\n const match = text.match(regex);\n\n if (match) {\n return +match[1];\n }\n return undefined;\n};\n\n/**\n * Gets book ID from USFM string that starts with the \\id marker, and returns book number for it\n *\n * @param text USFM string that is expected to start with \\id marker\n * @returns Book number corresponding to the \\id marker in the input text. Returns 0 if no marker is\n * found or the marker is not valid\n */\nexport const getBookNumFromId = (text: string): number => {\n // Captures all digits that follow an \\id marker followed by whitespace located at the start of a string\n const match = text.match(/^\\\\id\\s+([A-Za-z]+)/);\n if (match) {\n return Canon.bookIdToNumber(match[1]);\n }\n return 0;\n};\n\n/**\n * Gets the status for an item, typically used in the Inventory component\n *\n * @param item The item for which the status is being requested\n * @param approvedItems Array of approved items, typically as defined in `Settings.xml`\n * @param unapprovedItems Array of unapproved items, typically as defined in `Settings.xml`\n * @returns The status for the specified item\n */\nexport const getStatusForItem = (\n item: string,\n approvedItems: string[],\n unapprovedItems: string[],\n): Status => {\n if (unapprovedItems.includes(item)) return 'unapproved';\n if (approvedItems.includes(item)) return 'approved';\n return 'unknown';\n};\n\n/* #endregion */\n","import React from 'react';\nimport * as TogglePrimitive from '@radix-ui/react-toggle';\nimport { cva, type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst toggleVariants = cva(\n 'pr-twp tw-inline-flex tw-items-center tw-justify-center tw-rounded-md tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-colors hover:tw-bg-muted hover:tw-text-muted-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50 data-[state=on]:tw-bg-accent data-[state=on]:tw-text-accent-foreground',\n {\n variants: {\n variant: {\n default: 'tw-bg-transparent',\n outline:\n 'tw-border tw-border-input tw-bg-transparent hover:tw-bg-accent hover:tw-text-accent-foreground',\n },\n size: {\n default: 'tw-h-10 tw-px-3',\n sm: 'tw-h-9 tw-px-2.5',\n lg: 'tw-h-11 tw-px-5',\n },\n },\n defaultVariants: {\n variant: 'default',\n size: 'default',\n },\n },\n);\n\nconst Toggle = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef & VariantProps\n>(({ className, variant, size, ...props }, ref) => (\n \n));\n\nToggle.displayName = TogglePrimitive.Root.displayName;\n\nexport { Toggle, toggleVariants };\n","import React from 'react';\nimport * as ToggleGroupPrimitive from '@radix-ui/react-toggle-group';\nimport { type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { toggleVariants } from '@/components/shadcn-ui/toggle';\n\nconst ToggleGroupContext = React.createContext>({\n size: 'default',\n variant: 'default',\n});\n\nconst ToggleGroup = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef &\n VariantProps\n>(({ className, variant, size, children, ...props }, ref) => (\n \n \n {children}\n \n \n));\n\nToggleGroup.displayName = ToggleGroupPrimitive.Root.displayName;\n\nconst ToggleGroupItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef &\n VariantProps\n>(({ className, children, variant, size, ...props }, ref) => {\n const context = React.useContext(ToggleGroupContext);\n\n return (\n \n {children}\n \n );\n});\n\nToggleGroupItem.displayName = ToggleGroupPrimitive.Item.displayName;\n\nexport { ToggleGroup, ToggleGroupItem };\n","import { ColumnDef, SortDirection } from '@/components/advanced/data-table/data-table.component';\nimport { Button } from '@/components/shadcn-ui/button';\nimport { ToggleGroup, ToggleGroupItem } from '@/components/shadcn-ui/toggle-group';\nimport {\n ArrowDownIcon,\n ArrowUpDownIcon,\n ArrowUpIcon,\n CircleCheckIcon,\n CircleHelpIcon,\n CircleXIcon,\n} from 'lucide-react';\nimport { ReactNode } from 'react';\nimport { InventoryTableData, Status } from './inventory-utils';\n\n/**\n * Gets an icon that indicates the current sorting direction based on the provided input\n *\n * @param sortDirection Sorting direction. Can be ascending ('asc'), descending ('desc') or false (\n * i.e. not sorted)\n * @returns The appropriate sorting icon for the provided sorting direction\n */\nconst getSortingIcon = (sortDirection: false | SortDirection): ReactNode => {\n if (sortDirection === 'asc') {\n return ;\n }\n if (sortDirection === 'desc') {\n return ;\n }\n return ;\n};\n\n/**\n * Function that creates the item column for inventories\n *\n * @param itemLabel Localized label for the item column (e.g. 'Character', 'Repeated Word', etc.)\n * @returns Column that shows the inventory items. Should be used with the DataTable component\n */\nexport const inventoryItemColumn = (itemLabel: string): ColumnDef => {\n return {\n accessorKey: 'item',\n accessorFn: (row: InventoryTableData) => row.items[0],\n header: ({ column }) => (\n \n ),\n };\n};\n\n/**\n * Function that creates the additional item columns for inventories\n *\n * @param additionalItemLabel Localized label for the additional item column (e.g. 'Preceding\n * Marker')\n * @param additionalItemIndex Index that locates the desired item in the items array of the\n * inventory\n * @returns Column that shows additional inventory items. Should be used with the DataTable\n * component\n */\nexport const inventoryAdditionalItemColumn = (\n additionalItemLabel: string,\n additionalItemIndex: number,\n): ColumnDef => {\n return {\n accessorKey: `item${additionalItemIndex}`,\n accessorFn: (row: InventoryTableData) => row.items[additionalItemIndex],\n header: ({ column }) => (\n \n ),\n };\n};\n\n/**\n * Function that creates the count column for inventories. Should be used with the DataTable\n * component.\n *\n * @param itemLabel Localized label for the count column\n * @returns Column that shows the number of occurrences of the related inventory items\n */\nexport const inventoryCountColumn = (countLabel: string): ColumnDef => {\n return {\n accessorKey: 'count',\n header: ({ column }) => (\n
    \n \n
    \n ),\n cell: ({ row }) =>
    {row.getValue('count')}
    ,\n };\n};\n\n/**\n * Function that updates project settings when status for item(s) changes\n *\n * @param changedItems Array of items for which the status is being updated\n * @param newStatus The status that the items are being given\n * @param approvedItems Array of currently approved items\n * @param onApprovedItemsChange Callback function that stores the updated list of approved items\n * @param unapprovedItems Array of currently unapproved items\n * @param onUnapprovedItemsChange Callback function that stores the updated list of unapproved items\n */\nconst statusChangeHandler = (\n changedItems: string[],\n newStatus: Status,\n approvedItems: string[],\n onApprovedItemsChange: (items: string[]) => void,\n unapprovedItems: string[],\n onUnapprovedItemsChange: (items: string[]) => void,\n) => {\n let newApprovedItems: string[] = [...approvedItems];\n changedItems.forEach((item) => {\n if (newStatus === 'approved') {\n if (!newApprovedItems.includes(item)) {\n newApprovedItems.push(item);\n }\n } else {\n newApprovedItems = newApprovedItems.filter((validItem) => validItem !== item);\n }\n });\n onApprovedItemsChange(newApprovedItems);\n\n let newUnapprovedItems: string[] = [...unapprovedItems];\n changedItems.forEach((item) => {\n if (newStatus === 'unapproved') {\n if (!newUnapprovedItems.includes(item)) {\n newUnapprovedItems.push(item);\n }\n } else {\n newUnapprovedItems = newUnapprovedItems.filter((unapprovedItem) => unapprovedItem !== item);\n }\n });\n onUnapprovedItemsChange(newUnapprovedItems);\n};\n\n/**\n * Function that creates the status column for inventories. Should be used with the DataTable\n * component.\n *\n * @param statusLabel Localized label for the status column\n * @param approvedItems Array of approved items, typically as defined in `Settings.xml`\n * @param onApprovedItemsChange Callback function that stores the updated list of approved items\n * @param unapprovedItems Array of unapproved items, typically as defined in `Settings.xml`\n * @param onUnapprovedItemsChange Callback function that stores the updated list of unapproved items\n * @returns Column that shows the status buttons for the related inventory item. The button for the\n * current status of the item is selected\n */\nexport const inventoryStatusColumn = (\n statusLabel: string,\n approvedItems: string[],\n onApprovedItemsChange: (items: string[]) => void,\n unapprovedItems: string[],\n onUnapprovedItemsChange: (items: string[]) => void,\n): ColumnDef => {\n return {\n accessorKey: 'status',\n header: ({ column }) => {\n return (\n
    \n \n
    \n );\n },\n cell: ({ row }) => {\n const status: Status = row.getValue('status');\n const item: string = row.getValue('item');\n return (\n \n \n statusChangeHandler(\n [item],\n 'approved',\n approvedItems,\n onApprovedItemsChange,\n unapprovedItems,\n onUnapprovedItemsChange,\n )\n }\n value=\"approved\"\n >\n \n \n \n statusChangeHandler(\n [item],\n 'unapproved',\n approvedItems,\n onApprovedItemsChange,\n unapprovedItems,\n onUnapprovedItemsChange,\n )\n }\n value=\"unapproved\"\n >\n \n \n \n statusChangeHandler(\n [item],\n 'unknown',\n approvedItems,\n onApprovedItemsChange,\n unapprovedItems,\n onUnapprovedItemsChange,\n )\n }\n value=\"unknown\"\n >\n \n \n \n );\n },\n };\n};\n","import DataTable, {\n ColumnDef,\n RowContents,\n RowSelectionState,\n TableContents,\n} from '@/components/advanced/data-table/data-table.component';\nimport OccurrencesTable from '@/components/advanced/inventory/occurrences-table.component';\nimport Checkbox from '@/components/shadcn-ui/checkbox';\nimport { Input } from '@/components/shadcn-ui/input';\nimport { Label } from '@/components/shadcn-ui/label';\nimport {\n Select,\n SelectContent,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\nimport {\n deepEqual,\n LocalizedStringValue,\n ScriptureReference,\n substring,\n} from 'platform-bible-utils';\nimport { useEffect, useMemo, useState } from 'react';\nimport {\n getBookNumFromId,\n getLinesFromUSFM,\n getNumberFromUSFM,\n getStatusForItem,\n InventoryItemOccurrence,\n InventoryTableData,\n Status,\n} from './inventory-utils';\nimport { inventoryAdditionalItemColumn } from './inventory-columns';\n\n/**\n * Object containing all keys used for localization in this component. If you're using this\n * component in an extension, you can pass it into the useLocalizedStrings hook to easily obtain the\n * localized strings and pass them into the localizedStrings prop of this component\n */\nexport const INVENTORY_STRING_KEYS = Object.freeze([\n '%webView_inventory_all%',\n '%webView_inventory_approved%',\n '%webView_inventory_unapproved%',\n '%webView_inventory_unknown%',\n '%webView_inventory_scope_currentBook%',\n '%webView_inventory_scope_chapter%',\n '%webView_inventory_scope_verse%',\n '%webView_inventory_filter_text%',\n '%webView_inventory_show_additional_items%',\n '%webView_inventory_occurrences_table_header_reference%',\n '%webView_inventory_occurrences_table_header_occurrence%',\n] as const);\n\nexport type InventoryLocalizedStrings = {\n [localizedInventoryKey in (typeof INVENTORY_STRING_KEYS)[number]]?: LocalizedStringValue;\n};\n\n/** Scope of scripture that the inventory can operate on */\nexport type Scope = 'book' | 'chapter' | 'verse';\n\n/** Status values that the status filter can select from */\ntype StatusFilter = Status | 'all';\n\n/** Text labels for the inventory columns and the control components of additional inventory items */\ntype AdditionalItemsLabels = {\n checkboxText?: string;\n tableHeaders?: string[];\n};\n\n/**\n * Filters data that is shown in the DataTable section of the Inventory\n *\n * @param itemData All inventory items and their related information\n * @param statusFilter Allows filtering by status (i.e. show all items, or only items that are\n * 'approved', 'unapproved' or 'unknown')\n * @param textFilter Allows filtering by text. All items that include the filter text will be\n * selected.\n * @returns Array of items and their related information that are matched by the specified filters\n */\nconst filterItemData = (\n itemData: InventoryTableData[],\n statusFilter: StatusFilter,\n textFilter: string,\n): InventoryTableData[] => {\n let filteredItemData: InventoryTableData[] = itemData;\n\n if (statusFilter !== 'all') {\n filteredItemData = filteredItemData.filter(\n (item) =>\n (statusFilter === 'approved' && item.status === 'approved') ||\n (statusFilter === 'unapproved' && item.status === 'unapproved') ||\n (statusFilter === 'unknown' && item.status === 'unknown'),\n );\n }\n\n if (textFilter !== '')\n filteredItemData = filteredItemData.filter((item) => item.items[0].includes(textFilter));\n\n return filteredItemData;\n};\n\n/**\n * Turns array of strings into array of inventory items, along with their count and status\n *\n * @param text The source scripture text that is searched for inventory items\n * @param scriptureRef The scripture reference that the application is currently set to\n * @param approvedItems Array of approved items, typically as defined in `Settings.xml`\n * @param unapprovedItems Array of unapproved items, typically as defined in `Settings.xml`\n * @param itemRegex Regular expression that describes what items this Inventory should extract from\n * the provided scripture text\n * @returns Array of inventory items, along with their count and status\n */\nconst createTableData = (\n text: string | undefined,\n scriptureRef: ScriptureReference,\n approvedItems: string[],\n unapprovedItems: string[],\n itemRegex: RegExp,\n): InventoryTableData[] => {\n if (!text) return [];\n\n const tableData: InventoryTableData[] = [];\n\n let currentBook: number | undefined = scriptureRef.bookNum;\n let currentChapter: number | undefined = scriptureRef.chapterNum;\n let currentVerse: number | undefined = scriptureRef.verseNum;\n\n const lines = getLinesFromUSFM(text);\n\n lines.forEach((line: string) => {\n if (line.startsWith('\\\\id')) {\n currentBook = getBookNumFromId(line);\n currentChapter = 0;\n currentVerse = 0;\n }\n if (line.startsWith('\\\\c')) {\n currentChapter = getNumberFromUSFM(line);\n currentVerse = 0;\n }\n if (line.startsWith('\\\\v')) {\n currentVerse = getNumberFromUSFM(line);\n if (currentChapter === 0) {\n currentChapter = scriptureRef.chapterNum;\n }\n }\n\n let match: RegExpExecArray | undefined = itemRegex.exec(line) ?? undefined;\n while (match) {\n const items: string[] = [];\n match.forEach((item) => items.push(item));\n const itemIndex = match.index;\n const existingItem = tableData.find((tableEntry) => deepEqual(tableEntry.items, items));\n const newReference: InventoryItemOccurrence = {\n reference: {\n bookNum: currentBook !== undefined ? currentBook : -1,\n chapterNum: currentChapter !== undefined ? currentChapter : -1,\n verseNum: currentVerse !== undefined ? currentVerse : -1,\n },\n text: substring(line, Math.max(0, itemIndex - 25), Math.min(itemIndex + 25, line.length)),\n };\n if (existingItem) {\n existingItem.count += 1;\n existingItem.occurrences.push(newReference);\n } else {\n const newItem: InventoryTableData = {\n items,\n count: 1,\n status: getStatusForItem(items[0], approvedItems, unapprovedItems),\n occurrences: [newReference],\n };\n tableData.push(newItem);\n }\n\n match = itemRegex.exec(line) ?? undefined;\n }\n });\n\n return tableData;\n};\n\n/**\n * Gets the localized value for the provided key\n *\n * @param strings Object containing localized string\n * @param key Key for a localized string\n * @returns The localized value for the provided key, if available. Returns the key if no localized\n * value is available\n */\nconst localizeString = (\n strings: InventoryLocalizedStrings,\n key: keyof InventoryLocalizedStrings,\n) => {\n return strings[key] ?? key;\n};\n\n/** Props for the Inventory component */\ntype InventoryProps = {\n /** The scripture reference that the application is currently set to */\n scriptureReference: ScriptureReference;\n /** Callback function that is executed when the scripture reference is changed */\n setScriptureReference: (scriptureReference: ScriptureReference) => void;\n /**\n * Object with all localized strings that the Inventory needs to work well across multiple\n * languages. When using this component with Platform.Bible, you can import\n * `INVENTORY_STRING_KEYS` from this library, pass it in to the Platform's localization hook, and\n * pass the localized keys that are returned by the hook into this prop.\n */\n localizedStrings: InventoryLocalizedStrings;\n /**\n * The logic that finds the desired items in the source text. This can either be a Regular\n * expression that captures one or multiple items (preferred), or a custom function that builds\n * and return an InventoryDataTable[] manually. Note: In case the logic captures more than one\n * item (i.e. InventoryTableData.items has a length greater than 1), you must provide text labels\n * for the related columns and control elements to show by setting the `additionalItemsLabels`\n * prop\n */\n extractItems:\n | RegExp\n | ((\n text: string | undefined,\n scriptureRef: ScriptureReference,\n approvedItems: string[],\n unapprovedItems: string[],\n ) => InventoryTableData[]);\n /**\n * Text labels for control elements and additional column headers in case your Inventory has more\n * than one item to show (e.g. The 'Preceding Marker' in the Markers Inventory)\n */\n additionalItemsLabels?: AdditionalItemsLabels;\n /** Array of approved items, typically as defined in `Settings.xml` */\n approvedItems: string[];\n /** Array of unapproved items, typically as defined in `Settings.xml` */\n unapprovedItems: string[];\n /** The source scripture text that is searched for in inventory items */\n text: string | undefined;\n /** Scope of scripture that the inventory will operate on */\n scope: Scope;\n /** Callback function that is executed when the scope is changed from the Inventory */\n onScopeChange: (scope: Scope) => void;\n /**\n * Column definitions for the Inventory data table. The most commonly used column definitions are\n * pre-configured for your convenience and can be imported (e.g. inventoryItemColumn,\n * inventoryAdditionalItemColumn inventoryCountColumn, and inventoryStatusColumn). If you need any\n * other columns you can add these yourself\n */\n columns: ColumnDef[];\n};\n\n/** Inventory component that is used to view and control the status of provided project settings */\nexport default function Inventory({\n scriptureReference,\n setScriptureReference,\n localizedStrings,\n extractItems,\n additionalItemsLabels,\n approvedItems,\n unapprovedItems,\n text,\n scope,\n onScopeChange,\n columns,\n}: InventoryProps) {\n const allItemsText = localizeString(localizedStrings, '%webView_inventory_all%');\n const approvedItemsText = localizeString(localizedStrings, '%webView_inventory_approved%');\n const unapprovedItemsText = localizeString(localizedStrings, '%webView_inventory_unapproved%');\n const unknownItemsText = localizeString(localizedStrings, '%webView_inventory_unknown%');\n const scopeBookText = localizeString(localizedStrings, '%webView_inventory_scope_currentBook%');\n const scopeChapterText = localizeString(localizedStrings, '%webView_inventory_scope_chapter%');\n const scopeVerseText = localizeString(localizedStrings, '%webView_inventory_scope_verse%');\n const filterText = localizeString(localizedStrings, '%webView_inventory_filter_text%');\n const showAdditionalItemsText = localizeString(\n localizedStrings,\n '%webView_inventory_show_additional_items%',\n );\n\n const [showAdditionalItems, setShowAdditionalItems] = useState(false);\n const [statusFilter, setStatusFilter] = useState('all');\n const [textFilter, setTextFilter] = useState('');\n const [selectedItem, setSelectedItem] = useState([]);\n\n const tableData: InventoryTableData[] = useMemo(() => {\n if (!text) return [];\n if (extractItems instanceof RegExp)\n return createTableData(\n text,\n scriptureReference,\n approvedItems,\n unapprovedItems,\n extractItems,\n );\n return extractItems(text, scriptureReference, approvedItems, unapprovedItems);\n }, [text, extractItems, scriptureReference, approvedItems, unapprovedItems]);\n\n const reducedTableData: InventoryTableData[] = useMemo(() => {\n if (showAdditionalItems) return tableData;\n\n const newTableData: InventoryTableData[] = [];\n\n tableData.forEach((tableEntry) => {\n const firstItem = tableEntry.items[0];\n\n const existingEntry = newTableData.find(\n (newTableEntry) => newTableEntry.items[0] === firstItem,\n );\n\n if (existingEntry) {\n existingEntry.count += tableEntry.count;\n existingEntry.occurrences = existingEntry.occurrences.concat(tableEntry.occurrences);\n } else {\n newTableData.push({\n items: [firstItem],\n count: tableEntry.count,\n occurrences: tableEntry.occurrences,\n status: tableEntry.status,\n });\n }\n });\n\n return newTableData;\n }, [showAdditionalItems, tableData]);\n\n const filteredTableData: InventoryTableData[] = useMemo(() => {\n return filterItemData(reducedTableData, statusFilter, textFilter);\n }, [reducedTableData, statusFilter, textFilter]);\n\n const allColumns: ColumnDef[] = useMemo(() => {\n if (!showAdditionalItems) return columns;\n\n const numberOfAdditionalItems = additionalItemsLabels?.tableHeaders?.length;\n if (!numberOfAdditionalItems) return columns;\n\n const additionalColumns: ColumnDef[] = [];\n\n for (let index = 0; index < numberOfAdditionalItems; index++) {\n additionalColumns.push(\n inventoryAdditionalItemColumn(\n additionalItemsLabels?.tableHeaders?.[index] || 'Additional Item',\n index + 1,\n ),\n );\n }\n\n return [...additionalColumns, ...columns];\n }, [additionalItemsLabels?.tableHeaders, columns, showAdditionalItems]);\n\n useEffect(() => {\n setSelectedItem([]);\n }, [filteredTableData]);\n\n const rowClickHandler = (\n row: RowContents,\n table: TableContents,\n ) => {\n table.setRowSelection(() => {\n const newSelection: RowSelectionState = {};\n newSelection[row.index] = true;\n return newSelection;\n });\n\n setSelectedItem(row.original.items);\n };\n\n const handleScopeChange = (value: string) => {\n if (value === 'book' || value === 'chapter' || value === 'verse') {\n onScopeChange(value);\n } else {\n throw new Error(`Invalid scope value: ${value}`);\n }\n };\n\n const handleStatusFilterChange = (value: string) => {\n if (value === 'all' || value === 'approved' || value === 'unapproved' || value === 'unknown') {\n setStatusFilter(value);\n } else {\n throw new Error(`Invalid status filter value: ${value}`);\n }\n };\n\n const occurrenceData: InventoryItemOccurrence[] = useMemo(() => {\n if (reducedTableData.length === 0 || selectedItem.length === 0) return [];\n const occurrence = reducedTableData.filter((tableEntry: InventoryTableData) => {\n return deepEqual(\n showAdditionalItems ? tableEntry.items : [tableEntry.items[0]],\n selectedItem,\n );\n });\n if (occurrence.length > 1) throw new Error('Selected item is not unique');\n return occurrence[0].occurrences;\n }, [selectedItem, showAdditionalItems, reducedTableData]);\n\n return (\n
    \n
    \n handleStatusFilterChange(value)}\n defaultValue={statusFilter}\n >\n \n \n \n \n {allItemsText}\n {approvedItemsText}\n {unapprovedItemsText}\n {unknownItemsText}\n \n \n \n {\n setTextFilter(event.target.value);\n }}\n />\n {additionalItemsLabels && (\n
    \n {\n setSelectedItem([]);\n setShowAdditionalItems(checked);\n }}\n />\n \n
    \n )}\n
    \n
    \n \n
    \n {occurrenceData.length > 0 && (\n
    \n \n
    \n )}\n
    \n );\n}\n","import { Input } from '@/components/shadcn-ui/input';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { useState } from 'react';\n\nexport type SearchBarProps = {\n className?: string;\n /**\n * Callback fired to handle the search query when button pressed\n *\n * @param searchQuery\n */\n onSearch: (searchQuery: string) => void;\n\n /** Optional string that appears in the search bar without a search string */\n placeholder?: string;\n\n /** Optional boolean to set the input base to full width */\n isFullWidth?: boolean;\n};\n\nexport default function SearchBar({\n className,\n onSearch,\n placeholder,\n isFullWidth,\n}: SearchBarProps) {\n const [searchQuery, setSearchQuery] = useState('');\n\n const handleInputChange = (searchString: string) => {\n setSearchQuery(searchString);\n onSearch(searchString);\n };\n\n return (\n handleInputChange(e.target.value)}\n />\n );\n}\n","// adapted from: https://github.com/shadcn-ui/ui/discussions/752\n\n'use client';\n\nimport { TabsContentProps, TabsListProps, TabsTriggerProps } from '@/components/shadcn-ui/tabs';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport * as TabsPrimitive from '@radix-ui/react-tabs';\nimport React from 'react';\n\nexport type VerticalTabsProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport type LeftTabsTriggerProps = TabsTriggerProps & {\n value: string;\n ref?: React.Ref;\n};\n\nexport const VerticalTabs = React.forwardRef<\n React.ElementRef,\n VerticalTabsProps\n>(({ className, ...props }, ref) => (\n \n));\n\nVerticalTabs.displayName = TabsPrimitive.List.displayName;\n\nexport const VerticalTabsList = React.forwardRef<\n React.ElementRef,\n TabsListProps\n>(({ className, ...props }, ref) => (\n \n));\nVerticalTabsList.displayName = TabsPrimitive.List.displayName;\n\nexport const VerticalTabsTrigger = React.forwardRef<\n React.ElementRef,\n LeftTabsTriggerProps\n>(({ className, ...props }, ref) => (\n \n));\n\nexport const VerticalTabsContent = React.forwardRef<\n React.ElementRef,\n TabsContentProps\n>(({ className, ...props }, ref) => (\n \n));\nVerticalTabsContent.displayName = TabsPrimitive.Content.displayName;\n","import SearchBar from '@/components/basics/search-bar.component';\nimport {\n VerticalTabs,\n VerticalTabsContent,\n VerticalTabsList,\n VerticalTabsTrigger,\n} from '@/components/basics/tabs-vertical';\nimport { ReactNode } from 'react';\n\nexport type TabKeyValueContent = {\n key: string;\n value: string;\n content: ReactNode;\n};\n\nexport type TabNavigationContentSearchProps = {\n /** List of values and keys for each tab this component should provide */\n tabList: TabKeyValueContent[];\n\n /** Handler to run when the value of the search bar changes */\n onSearch: (searchQuery: string) => void;\n\n /** Optional placeholder for the search bar */\n searchPlaceholder?: string;\n\n /** Optional title to include in the header */\n headerTitle?: string;\n\n /** Optional flag to make the search bar appear full width */\n isSearchBarFullWidth?: boolean;\n\n /** Text direction ltr or rtl */\n direction?: 'ltr' | 'rtl';\n};\n\nexport default function TabNavigationContentSearch({\n tabList,\n onSearch,\n searchPlaceholder,\n headerTitle,\n isSearchBarFullWidth = false,\n direction = 'ltr',\n}: TabNavigationContentSearchProps) {\n return (\n
    \n
    \n {headerTitle ?

    {headerTitle}

    : ''}\n \n
    \n \n \n {tabList.map((tab) => (\n \n {tab.value}\n \n ))}\n \n {tabList.map((tab) => (\n \n {tab.content}\n \n ))}\n \n
    \n );\n}\n","import React from 'react';\nimport * as SeparatorPrimitive from '@radix-ui/react-separator';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Separator = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, orientation = 'horizontal', decorative = true, ...props }, ref) => (\n \n));\nSeparator.displayName = SeparatorPrimitive.Root.displayName;\n\nexport { Separator };\n","'use client';\n\nimport * as React from 'react';\nimport * as SheetPrimitive from '@radix-ui/react-dialog';\nimport { cva, type VariantProps } from 'class-variance-authority';\nimport { X } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Sheet = SheetPrimitive.Root;\n\nconst SheetTrigger = SheetPrimitive.Trigger;\n\nconst SheetClose = SheetPrimitive.Close;\n\nconst SheetPortal = SheetPrimitive.Portal;\n\nconst SheetOverlay = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSheetOverlay.displayName = SheetPrimitive.Overlay.displayName;\n\nconst sheetVariants = cva(\n 'pr-twp tw-fixed tw-z-50 tw-gap-4 tw-bg-background tw-p-6 tw-shadow-lg tw-transition tw-ease-in-out data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-duration-300 data-[state=open]:tw-duration-500',\n {\n variants: {\n side: {\n top: 'tw-inset-x-0 tw-top-0 tw-border-b data-[state=closed]:tw-slide-out-to-top data-[state=open]:tw-slide-in-from-top',\n bottom:\n 'tw-inset-x-0 tw-bottom-0 tw-border-t data-[state=closed]:tw-slide-out-to-bottom data-[state=open]:tw-slide-in-from-bottom',\n left: 'tw-inset-y-0 tw-left-0 tw-h-full tw-w-3/4 tw-border-r data-[state=closed]:tw-slide-out-to-left data-[state=open]:tw-slide-in-from-left sm:tw-max-w-sm',\n right:\n 'tw-inset-y-0 tw-right-0 tw-h-full tw-w-3/4 tw- tw-border-l data-[state=closed]:tw-slide-out-to-right data-[state=open]:tw-slide-in-from-right sm:tw-max-w-sm',\n },\n },\n defaultVariants: {\n side: 'right',\n },\n },\n);\n\ninterface SheetContentProps\n extends React.ComponentPropsWithoutRef,\n VariantProps {}\n\nconst SheetContent = React.forwardRef<\n React.ElementRef,\n SheetContentProps\n>(({ side = 'right', className, children, ...props }, ref) => (\n \n \n \n {children}\n \n \n Close\n \n \n \n));\nSheetContent.displayName = SheetPrimitive.Content.displayName;\n\nfunction SheetHeader({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nSheetHeader.displayName = 'SheetHeader';\n\nfunction SheetFooter({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nSheetFooter.displayName = 'SheetFooter';\n\nconst SheetTitle = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSheetTitle.displayName = SheetPrimitive.Title.displayName;\n\nconst SheetDescription = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSheetDescription.displayName = SheetPrimitive.Description.displayName;\n\nexport {\n Sheet,\n SheetPortal,\n SheetOverlay,\n SheetTrigger,\n SheetClose,\n SheetContent,\n SheetHeader,\n SheetFooter,\n SheetTitle,\n SheetDescription,\n};\n","import React from 'react';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nfunction Skeleton({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\n\nexport { Skeleton };\n","import React from 'react';\nimport * as TooltipPrimitive from '@radix-ui/react-tooltip';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst TooltipProvider = TooltipPrimitive.Provider;\n\nconst Tooltip = TooltipPrimitive.Root;\n\nconst TooltipTrigger = TooltipPrimitive.Trigger;\n\nconst TooltipContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, sideOffset = 4, ...props }, ref) => (\n \n));\nTooltipContent.displayName = TooltipPrimitive.Content.displayName;\n\nexport { Tooltip, TooltipTrigger, TooltipContent, TooltipProvider };\n","import * as React from 'react';\n\nconst MOBILE_BREAKPOINT = 768;\n\nexport default function useIsMobile() {\n const [isMobile, setIsMobile] = React.useState(undefined);\n\n React.useEffect(() => {\n const mql = window.matchMedia(`(max-width: ${MOBILE_BREAKPOINT - 1}px)`);\n const onChange = () => {\n setIsMobile(window.innerWidth < MOBILE_BREAKPOINT);\n };\n mql.addEventListener('change', onChange);\n setIsMobile(window.innerWidth < MOBILE_BREAKPOINT);\n return () => mql.removeEventListener('change', onChange);\n }, []);\n\n return !!isMobile;\n}\n","import React from 'react';\nimport { Slot } from '@radix-ui/react-slot';\nimport { VariantProps, cva } from 'class-variance-authority';\nimport { PanelLeft } from 'lucide-react';\n\nimport { Button } from '@/components/shadcn-ui/button';\nimport { Input } from '@/components/shadcn-ui/input';\nimport { Separator } from '@/components/shadcn-ui/separator';\nimport { Sheet, SheetContent } from '@/components/shadcn-ui/sheet';\nimport { Skeleton } from '@/components/shadcn-ui/skeleton';\nimport {\n Tooltip,\n TooltipContent,\n TooltipProvider,\n TooltipTrigger,\n} from '@/components/shadcn-ui/tooltip';\nimport useIsMobile from '@/components/hooks/use-mobile';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst SIDEBAR_COOKIE_NAME = 'sidebar:state';\nconst SIDEBAR_COOKIE_MAX_AGE = 60 * 60 * 24 * 7;\nconst SIDEBAR_WIDTH = '16rem';\nconst SIDEBAR_WIDTH_MOBILE = '18rem';\nconst SIDEBAR_WIDTH_ICON = '3rem';\nconst SIDEBAR_KEYBOARD_SHORTCUT = 'b';\n\ntype SidebarContextProps = {\n state: 'expanded' | 'collapsed';\n open: boolean;\n setOpen: (open: boolean) => void;\n openMobile: boolean;\n setOpenMobile: (open: boolean) => void;\n isMobile: boolean;\n toggleSidebar: () => void;\n};\n\nconst SidebarContext = React.createContext(undefined);\n\nfunction useSidebar() {\n const context = React.useContext(SidebarContext);\n if (!context) {\n throw new Error('useSidebar must be used within a SidebarProvider.');\n }\n\n return context;\n}\n\nconst SidebarProvider = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & {\n defaultOpen?: boolean;\n open?: boolean;\n onOpenChange?: (open: boolean) => void;\n }\n>(\n (\n {\n defaultOpen = true,\n open: openProp,\n onOpenChange: setOpenProp,\n className,\n style,\n children,\n ...props\n },\n ref,\n ) => {\n const isMobile = useIsMobile();\n const [openMobile, setOpenMobile] = React.useState(false);\n\n // This is the internal state of the sidebar.\n // We use openProp and setOpenProp for control from outside the component.\n const [_open, _setOpen] = React.useState(defaultOpen);\n const isOpen = openProp ?? _open;\n const setOpen = React.useCallback(\n (value: boolean | ((value: boolean) => boolean)) => {\n const openState = typeof value === 'function' ? value(isOpen) : value;\n if (setOpenProp) {\n setOpenProp(openState);\n } else {\n _setOpen(openState);\n }\n\n // This sets the cookie to keep the sidebar state.\n document.cookie = `${SIDEBAR_COOKIE_NAME}=${openState}; path=/; max-age=${SIDEBAR_COOKIE_MAX_AGE}`;\n },\n [setOpenProp, isOpen],\n );\n\n // Helper to toggle the sidebar.\n const toggleSidebar = React.useCallback(() => {\n return isMobile ? setOpenMobile((open) => !open) : setOpen((open) => !open);\n }, [isMobile, setOpen, setOpenMobile]);\n\n // Adds a keyboard shortcut to toggle the sidebar.\n React.useEffect(() => {\n const handleKeyDown = (event: KeyboardEvent) => {\n if (event.key === SIDEBAR_KEYBOARD_SHORTCUT && (event.metaKey || event.ctrlKey)) {\n event.preventDefault();\n toggleSidebar();\n }\n };\n\n window.addEventListener('keydown', handleKeyDown);\n return () => window.removeEventListener('keydown', handleKeyDown);\n }, [toggleSidebar]);\n\n // We add a state so that we can do data-state=\"expanded\" or \"collapsed\".\n // This makes it easier to style the sidebar with Tailwind classes.\n const state = isOpen ? 'expanded' : 'collapsed';\n\n const contextValue = React.useMemo(\n () => ({\n state,\n open: isOpen,\n setOpen,\n isMobile,\n openMobile,\n setOpenMobile,\n toggleSidebar,\n }),\n [state, isOpen, setOpen, isMobile, openMobile, setOpenMobile, toggleSidebar],\n );\n\n return (\n \n \n \n {children}\n
    \n \n \n );\n },\n);\nSidebarProvider.displayName = 'SidebarProvider';\n\nconst Sidebar = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & {\n side?: 'left' | 'right';\n variant?: 'sidebar' | 'floating' | 'inset';\n collapsible?: 'offcanvas' | 'icon' | 'none';\n }\n>(\n (\n {\n side = 'left',\n variant = 'sidebar',\n collapsible = 'offcanvas',\n className,\n children,\n ...props\n },\n ref,\n ) => {\n const { isMobile, state, openMobile, setOpenMobile } = useSidebar();\n\n if (collapsible === 'none') {\n return (\n \n {children}\n
    \n );\n }\n\n if (isMobile) {\n return (\n \n button]:tw-hidden\"\n style={\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n {\n '--sidebar-width': SIDEBAR_WIDTH_MOBILE,\n } as React.CSSProperties\n }\n side={side}\n >\n
    {children}
    \n \n
    \n );\n }\n\n return (\n \n {/* This is what handles the sidebar gap on desktop */}\n \n \n \n {children}\n
    \n
    \n
    \n );\n },\n);\nSidebar.displayName = 'Sidebar';\n\nconst SidebarTrigger = React.forwardRef<\n React.ElementRef,\n React.ComponentProps\n>(({ className, onClick, ...props }, ref) => {\n const { toggleSidebar } = useSidebar();\n\n return (\n {\n onClick?.(event);\n toggleSidebar();\n }}\n {...props}\n >\n \n Toggle Sidebar\n \n );\n});\nSidebarTrigger.displayName = 'SidebarTrigger';\n\nconst SidebarRail = React.forwardRef>(\n ({ className, ...props }, ref) => {\n const { toggleSidebar } = useSidebar();\n\n return (\n \n );\n },\n);\nSidebarRail.displayName = 'SidebarRail';\n\nconst SidebarInset = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarInset.displayName = 'SidebarInset';\n\nconst SidebarInput = React.forwardRef<\n React.ElementRef,\n React.ComponentProps\n>(({ className, ...props }, ref) => {\n return (\n \n );\n});\nSidebarInput.displayName = 'SidebarInput';\n\nconst SidebarHeader = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarHeader.displayName = 'SidebarHeader';\n\nconst SidebarFooter = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarFooter.displayName = 'SidebarFooter';\n\nconst SidebarSeparator = React.forwardRef<\n React.ElementRef,\n React.ComponentProps\n>(({ className, ...props }, ref) => {\n return (\n \n );\n});\nSidebarSeparator.displayName = 'SidebarSeparator';\n\nconst SidebarContent = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarContent.displayName = 'SidebarContent';\n\nconst SidebarGroup = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarGroup.displayName = 'SidebarGroup';\n\nconst SidebarGroupLabel = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & { asChild?: boolean }\n>(({ className, asChild = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'div';\n\n return (\n svg]:tw-size-4 [&>svg]:tw-shrink-0',\n 'group-data-[collapsible=icon]:tw--mt-8 group-data-[collapsible=icon]:tw-opacity-0',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarGroupLabel.displayName = 'SidebarGroupLabel';\n\nconst SidebarGroupAction = React.forwardRef<\n HTMLButtonElement,\n React.ComponentProps<'button'> & { asChild?: boolean }\n>(({ className, asChild = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'button';\n\n return (\n svg]:tw-size-4 [&>svg]:tw-shrink-0',\n // Increases the hit area of the button on mobile.\n 'after:tw-absolute after:tw--inset-2 after:md:tw-hidden',\n 'group-data-[collapsible=icon]:tw-hidden',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarGroupAction.displayName = 'SidebarGroupAction';\n\nconst SidebarGroupContent = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarGroupContent.displayName = 'SidebarGroupContent';\n\nconst SidebarMenu = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenu.displayName = 'SidebarMenu';\n\nconst SidebarMenuItem = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenuItem.displayName = 'SidebarMenuItem';\n\nconst sidebarMenuButtonVariants = cva(\n // Removed data-[active=true]:tw-bg-sidebar-accent\n 'tw-peer/menu-button tw-flex tw-w-full tw-items-center tw-gap-2 tw-overflow-hidden tw-rounded-md tw-p-2 tw-text-left tw-text-sm tw-outline-none tw-ring-sidebar-ring tw-transition-[width,height,padding] hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground focus-visible:tw-ring-2 active:tw-bg-sidebar-accent active:tw-text-sidebar-accent-foreground disabled:tw-pointer-events-none disabled:tw-opacity-50 tw-group-has-[[data-sidebar=menu-action]]/menu-item:pr-8 aria-disabled:tw-pointer-events-none aria-disabled:tw-opacity-50 data-[active=true]:tw-font-medium data-[active=true]:tw-text-sidebar-accent-foreground data-[state=open]:hover:tw-bg-sidebar-accent data-[state=open]:hover:tw-text-sidebar-accent-foreground group-data-[collapsible=icon]:tw-!size-8 group-data-[collapsible=icon]:tw-!p-2 [&>span:last-child]:tw-truncate [&>svg]:tw-size-4 [&>svg]:tw-shrink-0',\n {\n variants: {\n variant: {\n default: 'hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground',\n outline:\n 'tw-bg-background tw-shadow-[0_0_0_1px_hsl(var(--sidebar-border))] hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground hover:tw-shadow-[0_0_0_1px_hsl(var(--sidebar-accent))]',\n },\n size: {\n default: 'tw-h-8 tw-text-sm',\n sm: 'tw-h-7 tw-text-xs',\n lg: 'tw-h-12 tw-text-sm group-data-[collapsible=icon]:tw-!p-0',\n },\n },\n defaultVariants: {\n variant: 'default',\n size: 'default',\n },\n },\n);\n\nconst SidebarMenuButton = React.forwardRef<\n HTMLButtonElement,\n React.ComponentProps<'button'> & {\n asChild?: boolean;\n isActive?: boolean;\n tooltip?: string | React.ComponentProps;\n } & VariantProps\n>(\n (\n {\n asChild = false,\n isActive = false,\n variant = 'default',\n size = 'default',\n tooltip,\n className,\n ...props\n },\n ref,\n ) => {\n const Comp = asChild ? Slot : 'button';\n const { isMobile, state } = useSidebar();\n\n const button = (\n \n );\n\n if (!tooltip) {\n return button;\n }\n\n if (typeof tooltip === 'string') {\n // eslint-disable-next-line no-param-reassign\n tooltip = {\n children: tooltip,\n };\n }\n\n return (\n \n {button}\n \n );\n },\n);\nSidebarMenuButton.displayName = 'SidebarMenuButton';\n\nconst SidebarMenuAction = React.forwardRef<\n HTMLButtonElement,\n React.ComponentProps<'button'> & {\n asChild?: boolean;\n showOnHover?: boolean;\n }\n>(({ className, asChild = false, showOnHover = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'button';\n\n return (\n svg]:tw-size-4 [&>svg]:tw-shrink-0',\n // Increases the hit area of the button on mobile.\n 'after:tw-absolute after:tw--inset-2 after:md:tw-hidden',\n 'tw-peer-data-[size=sm]/menu-button:top-1',\n 'tw-peer-data-[size=default]/menu-button:top-1.5',\n 'tw-peer-data-[size=lg]/menu-button:top-2.5',\n 'group-data-[collapsible=icon]:tw-hidden',\n showOnHover &&\n 'tw-group-focus-within/menu-item:opacity-100 tw-group-hover/menu-item:opacity-100 tw-peer-data-[active=true]/menu-button:text-sidebar-accent-foreground data-[state=open]:tw-opacity-100 md:tw-opacity-0',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarMenuAction.displayName = 'SidebarMenuAction';\n\nconst SidebarMenuBadge = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenuBadge.displayName = 'SidebarMenuBadge';\n\nconst SidebarMenuSkeleton = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & {\n showIcon?: boolean;\n }\n>(({ className, showIcon = false, ...props }, ref) => {\n // Random width between 50 to 90%.\n const width = React.useMemo(() => {\n return `${Math.floor(Math.random() * 40) + 50}%`;\n }, []);\n\n return (\n \n {showIcon && (\n \n )}\n \n
    \n );\n});\nSidebarMenuSkeleton.displayName = 'SidebarMenuSkeleton';\n\nconst SidebarMenuSub = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenuSub.displayName = 'SidebarMenuSub';\n\nconst SidebarMenuSubItem = React.forwardRef>(\n ({ ...props }, ref) =>
  • ,\n);\nSidebarMenuSubItem.displayName = 'SidebarMenuSubItem';\n\nconst SidebarMenuSubButton = React.forwardRef<\n HTMLAnchorElement,\n React.ComponentProps<'a'> & {\n asChild?: boolean;\n size?: 'sm' | 'md';\n isActive?: boolean;\n }\n>(({ asChild = false, size = 'md', isActive, className, ...props }, ref) => {\n const Comp = asChild ? Slot : 'a';\n\n return (\n span:last-child]:tw-truncate [&>svg]:tw-size-4 [&>svg]:tw-shrink-0 [&>svg]:tw-text-sidebar-accent-foreground',\n 'data-[active=true]:tw-bg-sidebar-accent data-[active=true]:tw-text-sidebar-accent-foreground',\n size === 'sm' && 'tw-text-xs',\n size === 'md' && 'tw-text-sm',\n 'group-data-[collapsible=icon]:tw-hidden',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarMenuSubButton.displayName = 'SidebarMenuSubButton';\n\nexport {\n Sidebar,\n SidebarContent,\n SidebarFooter,\n SidebarGroup,\n SidebarGroupAction,\n SidebarGroupContent,\n SidebarGroupLabel,\n SidebarHeader,\n SidebarInput,\n SidebarInset,\n SidebarMenu,\n SidebarMenuAction,\n SidebarMenuBadge,\n SidebarMenuButton,\n SidebarMenuItem,\n SidebarMenuSkeleton,\n SidebarMenuSub,\n SidebarMenuSubButton,\n SidebarMenuSubItem,\n SidebarProvider,\n SidebarRail,\n SidebarSeparator,\n SidebarTrigger,\n useSidebar,\n};\n","import ComboBox, { ComboBoxOption } from '@/components/basics/combo-box.component';\nimport {\n Sidebar,\n SidebarContent,\n SidebarGroup,\n SidebarGroupLabel,\n SidebarGroupContent,\n SidebarMenu,\n SidebarMenuItem,\n SidebarMenuButton,\n} from '@/components/shadcn-ui/sidebar';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { useCallback } from 'react';\n\nexport type SelectedSettingsSidebarItem = {\n label: string;\n projectId?: string;\n};\n\nexport type ProjectOptions = { projectId: string; projectName: string };\n\nexport type SettingsSidebarProps = {\n /** Optional id for testing */\n id?: string;\n\n /** Extension labels from contribution */\n extensionLabels: string[];\n\n /** Project names and ids */\n projectOptions: ProjectOptions[];\n\n /** Handler for selecting a sidebar item */\n handleSelectSidebarItem: (key: string, projectId?: string) => void;\n\n /** The current selected value in the sidebar */\n selectedSidebarItem: SelectedSettingsSidebarItem;\n\n /** Label for the group of extensions setting groups */\n extensionsSidebarGroupLabel: string;\n\n /** Label for the group of projects settings */\n projectsSidebarGroupLabel: string;\n};\n\nexport default function SettingsSidebar({\n id,\n extensionLabels,\n projectOptions,\n handleSelectSidebarItem,\n selectedSidebarItem,\n extensionsSidebarGroupLabel,\n projectsSidebarGroupLabel,\n}: SettingsSidebarProps) {\n const handleSelectItem = useCallback(\n (item: string, projectId?: string) => {\n handleSelectSidebarItem(item, projectId);\n },\n [handleSelectSidebarItem],\n );\n\n const getProjectNameFromProjectId = useCallback(\n (projectId: string) => {\n const project = projectOptions.find((option) => option.projectId === projectId);\n return project ? project.projectName : projectId;\n },\n [projectOptions],\n );\n\n const getIsActive: (label: string) => boolean = useCallback(\n (label: string) => !selectedSidebarItem.projectId && label === selectedSidebarItem.label,\n [selectedSidebarItem],\n );\n\n return (\n \n \n \n \n {extensionsSidebarGroupLabel}\n \n \n \n {extensionLabels.map((label) => (\n \n handleSelectItem(label, undefined)}\n isActive={getIsActive(label)}\n >\n {label}\n \n \n ))}\n \n \n \n \n \n {projectsSidebarGroupLabel}\n \n \n option.projectId)}\n getOptionLabel={(projectId: ComboBoxOption) => {\n // This function expects a ComboBoxOption, but we know it is a string\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n return getProjectNameFromProjectId(projectId as string);\n }}\n buttonPlaceholder=\"Type or select project\"\n onChange={(projectId: string) => {\n const selectedProjectName = getProjectNameFromProjectId(projectId);\n handleSelectItem(selectedProjectName, projectId);\n }}\n value={selectedSidebarItem?.projectId ?? undefined}\n />\n \n \n \n \n );\n}\n","import { SidebarInset, SidebarProvider } from '@/components/shadcn-ui/sidebar';\nimport { PropsWithChildren } from 'react';\nimport SearchBar from '@/components/basics/search-bar.component';\nimport SettingsSidebar, { SettingsSidebarProps } from './settings-sidebar.component';\n\nexport type SettingsSidebarContentSearchProps = SettingsSidebarProps &\n PropsWithChildren & {\n /** Optional id for testing */\n id?: string;\n\n /** Text direction ltr or rtl */\n direction?: 'ltr' | 'rtl';\n\n /** Handler to run when the value of the search bar changes */\n onSearch: (searchQuery: string) => void;\n };\n\nexport default function SettingsSidebarContentSearch({\n id,\n direction = 'ltr',\n extensionLabels,\n projectOptions,\n children,\n handleSelectSidebarItem,\n selectedSidebarItem,\n onSearch,\n extensionsSidebarGroupLabel,\n projectsSidebarGroupLabel,\n}: SettingsSidebarContentSearchProps) {\n return (\n
    \n
    \n \n
    \n \n \n {children}\n \n
    \n );\n}\n","import { Button } from '@/components/shadcn-ui/button';\nimport {\n Select,\n SelectContent,\n SelectGroup,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\nimport {\n Table,\n TableBody,\n TableCell,\n TableHead,\n TableHeader,\n TableRow,\n} from '@/components/shadcn-ui/table';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Canon } from '@sillsdev/scripture';\nimport {\n Cell,\n ColumnDef,\n flexRender,\n getCoreRowModel,\n getExpandedRowModel,\n getGroupedRowModel,\n getSortedRowModel,\n GroupingState,\n Row,\n RowSelectionState,\n SortingState,\n useReactTable,\n} from '@tanstack/react-table';\nimport '@/components/advanced/scripture-results-viewer/scripture-results-viewer.component.css';\nimport {\n compareScrRefs,\n formatScrRef,\n ScriptureSelection,\n scrRefToBBBCCCVVV,\n} from 'platform-bible-utils';\nimport { MouseEvent, useEffect, useMemo, useState } from 'react';\nimport { ChevronDown, ChevronLeft, ChevronRight } from 'lucide-react';\n\n/**\n * Information (e.g., a checking error or some other type of \"transient\" annotation) about something\n * noteworthy at a specific place in an instance of the Scriptures.\n */\nexport type ScriptureItemDetail = ScriptureSelection & {\n /**\n * Text of the error, note, etc. In the future, we might want to support something more than just\n * text so that a JSX element could be provided with a link or some other controls related to the\n * issue being reported.\n */\n detail: string;\n};\n\n/**\n * A uniquely identifiable source of results that can be displayed in the ScriptureResultsViewer.\n * Generally, the source will be a particular Scripture check, but there may be other types of\n * sources.\n */\nexport type ResultsSource = {\n /**\n * Uniquely identifies the source.\n *\n * @type {string}\n */\n id: string;\n\n /**\n * Name (potentially localized) of the source, suitable for display in the UI.\n *\n * @type {string}\n */\n displayName: string;\n};\n\nexport type ScriptureSrcItemDetail = ScriptureItemDetail & {\n /** Source/type of detail. Can be used for grouping. */\n source: ResultsSource;\n};\n\n/**\n * Represents a set of results keyed by Scripture reference. Generally, the source will be a\n * particular Scripture check, but this type also allows for other types of uniquely identifiable\n * sources.\n */\nexport type ResultsSet = {\n /**\n * The backing source associated with this set of results.\n *\n * @type {ResultsSource}\n */\n source: ResultsSource;\n\n /**\n * Array of Scripture item details (messages keyed by Scripture reference).\n *\n * @type {ScriptureItemDetail[]}\n */\n data: ScriptureItemDetail[];\n};\n\nconst scrBookColId = 'scrBook';\nconst scrRefColId = 'scrRef';\nconst typeColId = 'source';\nconst detailsColId = 'details';\n\nconst defaultScrRefColumnName = 'Scripture Reference';\nconst defaultScrBookGroupName = 'Scripture Book';\nconst defaultTypeColumnName = 'Type';\nconst defaultDetailsColumnName = 'Details';\n\nexport type ScriptureResultsViewerColumnInfo = {\n /** Optional header to display for the Reference column. Default value: 'Scripture Reference'. */\n scriptureReferenceColumnName?: string;\n\n /** Optional text to display to refer to the Scripture book group. Default value: 'Scripture Book'. */\n scriptureBookGroupName?: string;\n\n /** Optional header to display for the Type column. Default value: 'Type'. */\n typeColumnName?: string;\n\n /** Optional header to display for the Details column. Default value: 'Details' */\n detailsColumnName?: string;\n};\n\nexport type ScriptureResultsViewerProps = ScriptureResultsViewerColumnInfo & {\n /** Groups of ScriptureItemDetail objects from particular sources (e.g., Scripture checks) */\n sources: ResultsSet[];\n\n /** Flag indicating whether to display column headers. Default is false. */\n showColumnHeaders?: boolean;\n\n /** Flag indicating whether to display source column. Default is false. */\n showSourceColumn?: boolean;\n\n /** Callback function to notify when a row is selected */\n onRowSelected?: (selectedRow: ScriptureSrcItemDetail | undefined) => void;\n\n /** Text direction ltr or rtl */\n direction?: 'ltr' | 'rtl';\n};\n\nfunction getColumns(\n colInfo?: ScriptureResultsViewerColumnInfo,\n showSourceColumn?: boolean,\n): ColumnDef[] {\n const showSrcCol = showSourceColumn ?? false;\n return [\n {\n accessorFn: (row) =>\n `${Canon.bookNumberToId(row.start.bookNum)} ${row.start.chapterNum}:${row.start.verseNum}`,\n id: scrBookColId,\n header: colInfo?.scriptureReferenceColumnName ?? defaultScrRefColumnName,\n cell: (info) => {\n const row = info.row.original;\n if (info.row.getIsGrouped()) {\n return Canon.bookNumberToEnglishName(row.start.bookNum);\n }\n return info.row.groupingColumnId === scrBookColId ? formatScrRef(row.start) : undefined;\n },\n getGroupingValue: (row) => row.start.bookNum,\n sortingFn: (a, b) => {\n return compareScrRefs(a.original.start, b.original.start);\n },\n enableGrouping: true,\n },\n {\n accessorFn: (row) => formatScrRef(row.start),\n id: scrRefColId,\n header: undefined,\n cell: (info) => {\n const row = info.row.original;\n return info.row.getIsGrouped() ? undefined : formatScrRef(row.start);\n },\n sortingFn: (a, b) => {\n return compareScrRefs(a.original.start, b.original.start);\n },\n enableGrouping: false,\n },\n {\n accessorFn: (row) => row.source.displayName,\n id: typeColId,\n header: showSrcCol ? (colInfo?.typeColumnName ?? defaultTypeColumnName) : undefined,\n cell: (info) => (showSrcCol || info.row.getIsGrouped() ? info.getValue() : undefined),\n getGroupingValue: (row) => row.source.id,\n sortingFn: (a, b) =>\n a.original.source.displayName.localeCompare(b.original.source.displayName),\n enableGrouping: true,\n },\n {\n accessorFn: (row) => row.detail,\n id: detailsColId,\n header: colInfo?.detailsColumnName ?? defaultDetailsColumnName,\n cell: (info) => info.getValue(),\n enableGrouping: false,\n },\n ];\n}\n\nconst toRefOrRange = (scriptureSelection: ScriptureSelection) => {\n if (!('offset' in scriptureSelection.start))\n throw new Error('No offset available in range start');\n if (scriptureSelection.end && !('offset' in scriptureSelection.end))\n throw new Error('No offset available in range end');\n const { offset: offsetStart } = scriptureSelection.start;\n let offsetEnd: number = 0;\n if (scriptureSelection.end) ({ offset: offsetEnd } = scriptureSelection.end);\n if (\n !scriptureSelection.end ||\n compareScrRefs(scriptureSelection.start, scriptureSelection.end) === 0\n )\n return `${scrRefToBBBCCCVVV(scriptureSelection.start)}+${offsetStart}`;\n return `${scrRefToBBBCCCVVV(scriptureSelection.start)}+${offsetStart}-${scrRefToBBBCCCVVV(scriptureSelection.end)}+${offsetEnd}`;\n};\n\nconst getRowKey = (row: ScriptureSrcItemDetail) =>\n `${toRefOrRange({ start: row.start, end: row.end })} ${row.source.displayName} ${row.detail}`;\n\n/**\n * Component to display a combined list of detailed items from one or more sources, where the items\n * are keyed primarily by Scripture reference. This is particularly useful for displaying a list of\n * results from Scripture checks, but more generally could be used to display any \"results\" from any\n * source(s). The component allows for grouping by Scripture book, source, or both. By default, it\n * displays somewhat \"tree-like\" which allows it to be more horizontally compact and intuitive. But\n * it also has the option of displaying as a traditional table with column headings (with or without\n * the source column showing).\n */\nexport default function ScriptureResultsViewer({\n sources,\n showColumnHeaders = false,\n showSourceColumn = false,\n scriptureReferenceColumnName,\n scriptureBookGroupName,\n typeColumnName,\n detailsColumnName,\n onRowSelected,\n direction = 'ltr',\n}: ScriptureResultsViewerProps) {\n const [grouping, setGrouping] = useState([]);\n const [sorting, setSorting] = useState([{ id: scrBookColId, desc: false }]);\n const [rowSelection, setRowSelection] = useState({});\n\n const scriptureResults = useMemo(\n () =>\n sources.flatMap((source) => {\n return source.data.map((item) => ({\n ...item,\n source: source.source,\n }));\n }),\n [sources],\n );\n\n const columns = useMemo(\n () =>\n getColumns(\n {\n scriptureReferenceColumnName,\n typeColumnName,\n detailsColumnName,\n },\n showSourceColumn,\n ),\n [scriptureReferenceColumnName, typeColumnName, detailsColumnName, showSourceColumn],\n );\n\n useEffect(() => {\n // Ensure sorting is applied correctly when grouped by type\n if (grouping.includes(typeColId)) {\n setSorting([\n { id: typeColId, desc: false },\n { id: scrBookColId, desc: false },\n ]);\n } else {\n setSorting([{ id: scrBookColId, desc: false }]);\n }\n }, [grouping]);\n\n const table = useReactTable({\n data: scriptureResults,\n columns,\n state: {\n grouping,\n sorting,\n rowSelection,\n },\n onGroupingChange: setGrouping,\n onSortingChange: setSorting,\n onRowSelectionChange: setRowSelection,\n getExpandedRowModel: getExpandedRowModel(),\n getGroupedRowModel: getGroupedRowModel(),\n getCoreRowModel: getCoreRowModel(),\n getSortedRowModel: getSortedRowModel(),\n getRowId: getRowKey,\n autoResetExpanded: false,\n enableMultiRowSelection: false,\n enableSubRowSelection: false,\n });\n\n useEffect(() => {\n if (onRowSelected) {\n const selectedRows = table.getSelectedRowModel().rowsById;\n const keys = Object.keys(selectedRows);\n if (keys.length === 1) {\n const selectedRow = scriptureResults.find((row) => getRowKey(row) === keys[0]) || undefined;\n if (selectedRow) onRowSelected(selectedRow);\n }\n }\n }, [rowSelection, scriptureResults, onRowSelected, table]);\n\n // Define possible grouping options\n const scrBookGroupName = scriptureBookGroupName ?? defaultScrBookGroupName;\n const typeGroupName = typeColumnName ?? defaultTypeColumnName;\n\n const groupingOptions = [\n { label: 'No Grouping', value: [] },\n { label: `Group by ${scrBookGroupName}`, value: [scrBookColId] },\n { label: `Group by ${typeGroupName}`, value: [typeColId] },\n {\n label: `Group by ${scrBookGroupName} and ${typeGroupName}`,\n value: [scrBookColId, typeColId],\n },\n {\n label: `Group by ${typeGroupName} and ${scrBookGroupName}`,\n value: [typeColId, scrBookColId],\n },\n ];\n\n const handleSelectChange = (selectedGrouping: string) => {\n setGrouping(JSON.parse(selectedGrouping));\n };\n\n const handleRowClick = (row: Row, event: MouseEvent) => {\n if (!row.getIsGrouped() && !row.getIsSelected()) {\n row.getToggleSelectedHandler()(event);\n }\n };\n\n const getEvenOrOddBandingStyle = (row: Row, index: number) => {\n if (row.getIsGrouped()) return '';\n // UX has now said they don't think they want banding. I'm leaving in the code to\n // set even and odd styles, but there's nothing in the CSS to style them differently.\n // The \"even\" style used to also have tw-bg-neutral-300 (along with even) to create\n // a visual banding effect. That could be added back in if UX changes the decision.\n return cn('banded-row', index % 2 === 0 ? 'even' : 'odd');\n };\n\n const getIndent = (\n groupingState: GroupingState,\n row: Row,\n cell: Cell,\n ) => {\n if (groupingState?.length === 0 || row.depth < cell.column.getGroupedIndex()) return undefined;\n if (row.getIsGrouped()) {\n switch (row.depth) {\n case 1:\n return 'tw-ps-4';\n default:\n return undefined;\n }\n }\n switch (row.depth) {\n case 1:\n return 'tw-ps-8';\n case 2:\n return 'tw-ps-12';\n default:\n return undefined;\n }\n };\n\n return (\n
    \n {!showColumnHeaders && (\n {\n handleSelectChange(value);\n }}\n >\n \n \n \n \n \n {groupingOptions.map((option) => (\n \n {option.label}\n \n ))}\n \n \n \n )}\n \n {showColumnHeaders && (\n \n {table.getHeaderGroups().map((headerGroup) => (\n \n {headerGroup.headers\n .filter((h) => h.column.columnDef.header)\n .map((header) => (\n /* For sticky column headers to work, we probably need to change the default definition of the shadcn Table component. See https://github.com/shadcn-ui/ui/issues/1151 */\n \n {header.isPlaceholder ? undefined : (\n
    \n {header.column.getCanGroup() ? (\n \n {header.column.getIsGrouped() ? `🛑` : `👊 `}\n \n ) : undefined}{' '}\n {flexRender(header.column.columnDef.header, header.getContext())}\n
    \n )}\n
    \n ))}\n
    \n ))}\n
    \n )}\n \n {table.getRowModel().rows.map((row, rowIndex) => {\n return (\n handleRowClick(row, event)}\n >\n {row.getVisibleCells().map((cell) => {\n if (\n cell.getIsPlaceholder() ||\n (cell.column.columnDef.enableGrouping &&\n !cell.getIsGrouped() &&\n (cell.column.columnDef.id !== typeColId || !showSourceColumn))\n )\n return undefined;\n return (\n \n {(() => {\n if (cell.getIsGrouped()) {\n return (\n \n {row.getIsExpanded() && }\n {!row.getIsExpanded() &&\n (direction === 'ltr' ? : )}{' '}\n {flexRender(cell.column.columnDef.cell, cell.getContext())} (\n {row.subRows.length})\n \n );\n }\n\n // if (cell.getIsAggregated()) {\n // flexRender(\n // cell.column.columnDef.aggregatedCell ?? cell.column.columnDef.cell,\n // cell.getContext(),\n // );\n // }\n\n return flexRender(cell.column.columnDef.cell, cell.getContext());\n })()}\n \n );\n })}\n \n );\n })}\n \n
    \n
    \n );\n}\n","import {\n getLocalizeKeyForScrollGroupId,\n LanguageStrings,\n ScrollGroupId,\n} from 'platform-bible-utils';\nimport {\n Select,\n SelectContent,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\n\nconst DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS = {\n [getLocalizeKeyForScrollGroupId('undefined')]: 'Ø',\n [getLocalizeKeyForScrollGroupId(0)]: 'A',\n [getLocalizeKeyForScrollGroupId(1)]: 'B',\n [getLocalizeKeyForScrollGroupId(2)]: 'C',\n [getLocalizeKeyForScrollGroupId(3)]: 'D',\n [getLocalizeKeyForScrollGroupId(4)]: 'E',\n [getLocalizeKeyForScrollGroupId(5)]: 'F',\n [getLocalizeKeyForScrollGroupId(6)]: 'G',\n [getLocalizeKeyForScrollGroupId(7)]: 'H',\n [getLocalizeKeyForScrollGroupId(8)]: 'I',\n [getLocalizeKeyForScrollGroupId(9)]: 'J',\n [getLocalizeKeyForScrollGroupId(10)]: 'K',\n [getLocalizeKeyForScrollGroupId(11)]: 'L',\n [getLocalizeKeyForScrollGroupId(12)]: 'M',\n [getLocalizeKeyForScrollGroupId(13)]: 'N',\n [getLocalizeKeyForScrollGroupId(14)]: 'O',\n [getLocalizeKeyForScrollGroupId(15)]: 'P',\n [getLocalizeKeyForScrollGroupId(16)]: 'Q',\n [getLocalizeKeyForScrollGroupId(17)]: 'R',\n [getLocalizeKeyForScrollGroupId(18)]: 'S',\n [getLocalizeKeyForScrollGroupId(19)]: 'T',\n [getLocalizeKeyForScrollGroupId(20)]: 'U',\n [getLocalizeKeyForScrollGroupId(21)]: 'V',\n [getLocalizeKeyForScrollGroupId(22)]: 'W',\n [getLocalizeKeyForScrollGroupId(23)]: 'X',\n [getLocalizeKeyForScrollGroupId(24)]: 'Y',\n [getLocalizeKeyForScrollGroupId(25)]: 'Z',\n};\n\nexport type ScrollGroupSelectorProps = {\n /**\n * List of scroll group ids to show to the user. Either a {@link ScrollGroupId} or `undefined` for\n * no scroll group\n */\n availableScrollGroupIds: (ScrollGroupId | undefined)[];\n /** Currently selected scroll group id. `undefined` for no scroll group */\n scrollGroupId: ScrollGroupId | undefined;\n /** Callback function run when the user tries to change the scroll group id */\n onChangeScrollGroupId: (newScrollGroupId: ScrollGroupId | undefined) => void;\n /**\n * Localized strings to use for displaying scroll group ids. Must be an object whose keys are\n * `getLocalizeKeyForScrollGroupId(scrollGroupId)` for all scroll group ids (and `undefined` if\n * included) in {@link ScrollGroupSelectorProps.availableScrollGroupIds} and whose values are the\n * localized strings to use for those scroll group ids.\n *\n * Defaults to English localizations of English alphabet for scroll groups 0-25 (e.g. 0 is A) and\n * Ø for `undefined`. Will fill in any that are not provided with these English localizations.\n * Also, if any values match the keys, the English localization will be used. This is useful in\n * case you want to pass in a temporary version of the localized strings while your localized\n * strings load.\n *\n * @example\n *\n * ```typescript\n * const myScrollGroupIdLocalizedStrings = {\n * [getLocalizeKeyForScrollGroupId('undefined')]: 'Ø',\n * [getLocalizeKeyForScrollGroupId(0)]: 'A',\n * [getLocalizeKeyForScrollGroupId(1)]: 'B',\n * [getLocalizeKeyForScrollGroupId(2)]: 'C',\n * [getLocalizeKeyForScrollGroupId(3)]: 'D',\n * [getLocalizeKeyForScrollGroupId(4)]: 'E',\n * };\n * ```\n *\n * @example\n *\n * ```tsx\n * const availableScrollGroupIds = [undefined, 0, 1, 2, 3, 4];\n *\n * const localizeKeys = getLocalizeKeysForScrollGroupIds();\n *\n * const [localizedStrings] = useLocalizedStrings(localizeKeys);\n *\n * ...\n *\n * \n * ```\n */\n localizedStrings?: LanguageStrings;\n};\n\n/** Selector component for choosing a scroll group */\nexport default function ScrollGroupSelector({\n availableScrollGroupIds,\n scrollGroupId,\n onChangeScrollGroupId,\n localizedStrings = {},\n}: ScrollGroupSelectorProps) {\n const localizedStringsDefaulted = {\n ...DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS,\n ...Object.fromEntries(\n Object.entries(localizedStrings).map(\n ([localizedStringKey, localizedStringValue]: [string, string]) => [\n localizedStringKey,\n localizedStringKey === localizedStringValue &&\n localizedStringKey in DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS\n ? DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS[localizedStringKey]\n : localizedStringValue,\n ],\n ),\n ),\n };\n return (\n \n onChangeScrollGroupId(\n newScrollGroupString === 'undefined' ? undefined : parseInt(newScrollGroupString, 10),\n )\n }\n >\n \n \n \n \n {availableScrollGroupIds.map((scrollGroupOptionId) => (\n \n {localizedStringsDefaulted[getLocalizeKeyForScrollGroupId(scrollGroupOptionId)]}\n \n ))}\n \n \n );\n}\n","import { PropsWithChildren } from 'react';\nimport { Separator } from '@/components/shadcn-ui/separator';\n\n/** Props for the SettingsList component, currently just children */\ntype SettingsListProps = PropsWithChildren;\n\n/**\n * SettingsList component is a wrapper for list items. Rendered with a formatted div\n *\n * @param children To populate the list with\n * @returns Formatted div encompassing the children\n */\nexport function SettingsList({ children }: SettingsListProps) {\n return
    {children}
    ;\n}\n\n/** Props for SettingsListItem component */\ntype SettingsListItemProps = PropsWithChildren & {\n /** Primary text of the list item */\n primary: string;\n\n /** Optional text of the list item */\n secondary?: string | undefined;\n\n /** Optional boolean to display a message if the children aren't loaded yet. Defaults to false */\n isLoading?: boolean;\n\n /** Optional message to display if isLoading */\n loadingMessage?: string;\n};\n\n/**\n * SettingsListItem component is a common list item. Rendered with a formatted div\n *\n * @param primary Primary text of the list item\n * @param secondary Optional secondary text of the list item\n * @param isLoading Optional, to display a message if the action component isn't generated yet,\n * defaults to false\n * @param children The action component(s) to provide for this item\n * @param loadingMessage Optional, message to display if isLoading\n * @returns Formatted div encompassing the list item content\n */\nexport function SettingsListItem({\n primary,\n secondary,\n children,\n isLoading = false,\n loadingMessage,\n}: SettingsListItemProps) {\n return (\n
    \n
    \n

    {primary}

    \n

    \n {secondary}\n

    \n
    \n\n {isLoading ? (\n

    {loadingMessage}

    \n ) : (\n
    {children}
    \n )}\n
    \n );\n}\n\n/** Props for SettingsListHeader component */\ntype SettingsListHeaderProps = {\n /** The primary text of the list header */\n primary: string;\n\n /** Optional secondary text of the list header */\n secondary?: string | undefined;\n\n /** Optional boolean to include a separator underneath the secondary text. Defaults to false */\n includeSeparator?: boolean;\n};\n\n/**\n * SettingsListHeader component displays text above the list\n *\n * @param primary The primary text of the list header\n * @param secondary Optional secondary text of the list header\n * @param includeSeparator Optional boolean to include a separator underneath the secondary text.\n * Defaults to false\n * @returns Formatted div with list header content\n */\nexport function SettingsListHeader({\n primary,\n secondary,\n includeSeparator = false,\n}: SettingsListHeaderProps) {\n return (\n
    \n
    \n

    {primary}

    \n

    {secondary}

    \n
    \n {includeSeparator ? : ''}\n
    \n );\n}\n","import Checkbox from '@/components/shadcn-ui/checkbox';\nimport { Label } from '@/components/shadcn-ui/label';\n\nexport type ChecklistProps = {\n /** Optional string representing the id attribute of the Checklist */\n id?: string;\n /** Optional string representing CSS class name(s) for styling */\n className?: string;\n /** Array of strings representing the checkable items */\n listItems: string[];\n /** Array of strings representing the checked items */\n selectedListItems: string[];\n /**\n * Function that is called when a checkbox item is selected or deselected\n *\n * @param item The string description for this item\n * @param selected True if selected, false if not selected\n */\n handleSelectListItem: (item: string, selected: boolean) => void;\n\n /**\n * Optional function creates a label for a provided checkable item\n *\n * @param item The item for which a label is to be created\n * @returns A string representing the label text for the checkbox associated with that item\n */\n createLabel?: (item: string) => string;\n};\n\n/** Renders a list of checkboxes. Each checkbox corresponds to an item from the `listItems` array. */\nexport default function Checklist({\n id,\n className,\n listItems,\n selectedListItems,\n handleSelectListItem,\n createLabel,\n}: ChecklistProps) {\n return (\n
    \n {listItems.map((item) => (\n
    \n handleSelectListItem(item, value)}\n />\n \n
    \n ))}\n
    \n );\n}\n","function _interopRequireDefault(obj) {\n return obj && obj.__esModule ? obj : {\n \"default\": obj\n };\n}\nmodule.exports = _interopRequireDefault, module.exports.__esModule = true, module.exports[\"default\"] = module.exports;","export default function chainPropTypes(propType1, propType2) {\n if (process.env.NODE_ENV === 'production') {\n return () => null;\n }\n return function validate(...args) {\n return propType1(...args) || propType2(...args);\n };\n}","export default function _extends() {\n _extends = Object.assign ? Object.assign.bind() : function (target) {\n for (var i = 1; i < arguments.length; i++) {\n var source = arguments[i];\n for (var key in source) {\n if (Object.prototype.hasOwnProperty.call(source, key)) {\n target[key] = source[key];\n }\n }\n }\n return target;\n };\n return _extends.apply(this, arguments);\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\n// https://github.com/sindresorhus/is-plain-obj/blob/main/index.js\nexport function isPlainObject(item) {\n if (typeof item !== 'object' || item === null) {\n return false;\n }\n const prototype = Object.getPrototypeOf(item);\n return (prototype === null || prototype === Object.prototype || Object.getPrototypeOf(prototype) === null) && !(Symbol.toStringTag in item) && !(Symbol.iterator in item);\n}\nfunction deepClone(source) {\n if (!isPlainObject(source)) {\n return source;\n }\n const output = {};\n Object.keys(source).forEach(key => {\n output[key] = deepClone(source[key]);\n });\n return output;\n}\nexport default function deepmerge(target, source, options = {\n clone: true\n}) {\n const output = options.clone ? _extends({}, target) : target;\n if (isPlainObject(target) && isPlainObject(source)) {\n Object.keys(source).forEach(key => {\n // Avoid prototype pollution\n if (key === '__proto__') {\n return;\n }\n if (isPlainObject(source[key]) && key in target && isPlainObject(target[key])) {\n // Since `output` is a clone of `target` and we have narrowed `target` in this block we can cast to the same type.\n output[key] = deepmerge(target[key], source[key], options);\n } else if (options.clone) {\n output[key] = isPlainObject(source[key]) ? deepClone(source[key]) : source[key];\n } else {\n output[key] = source[key];\n }\n });\n }\n return output;\n}","/** @license React v16.13.1\n * react-is.production.min.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';var b=\"function\"===typeof Symbol&&Symbol.for,c=b?Symbol.for(\"react.element\"):60103,d=b?Symbol.for(\"react.portal\"):60106,e=b?Symbol.for(\"react.fragment\"):60107,f=b?Symbol.for(\"react.strict_mode\"):60108,g=b?Symbol.for(\"react.profiler\"):60114,h=b?Symbol.for(\"react.provider\"):60109,k=b?Symbol.for(\"react.context\"):60110,l=b?Symbol.for(\"react.async_mode\"):60111,m=b?Symbol.for(\"react.concurrent_mode\"):60111,n=b?Symbol.for(\"react.forward_ref\"):60112,p=b?Symbol.for(\"react.suspense\"):60113,q=b?\nSymbol.for(\"react.suspense_list\"):60120,r=b?Symbol.for(\"react.memo\"):60115,t=b?Symbol.for(\"react.lazy\"):60116,v=b?Symbol.for(\"react.block\"):60121,w=b?Symbol.for(\"react.fundamental\"):60117,x=b?Symbol.for(\"react.responder\"):60118,y=b?Symbol.for(\"react.scope\"):60119;\nfunction z(a){if(\"object\"===typeof a&&null!==a){var u=a.$$typeof;switch(u){case c:switch(a=a.type,a){case l:case m:case e:case g:case f:case p:return a;default:switch(a=a&&a.$$typeof,a){case k:case n:case t:case r:case h:return a;default:return u}}case d:return u}}}function A(a){return z(a)===m}exports.AsyncMode=l;exports.ConcurrentMode=m;exports.ContextConsumer=k;exports.ContextProvider=h;exports.Element=c;exports.ForwardRef=n;exports.Fragment=e;exports.Lazy=t;exports.Memo=r;exports.Portal=d;\nexports.Profiler=g;exports.StrictMode=f;exports.Suspense=p;exports.isAsyncMode=function(a){return A(a)||z(a)===l};exports.isConcurrentMode=A;exports.isContextConsumer=function(a){return z(a)===k};exports.isContextProvider=function(a){return z(a)===h};exports.isElement=function(a){return\"object\"===typeof a&&null!==a&&a.$$typeof===c};exports.isForwardRef=function(a){return z(a)===n};exports.isFragment=function(a){return z(a)===e};exports.isLazy=function(a){return z(a)===t};\nexports.isMemo=function(a){return z(a)===r};exports.isPortal=function(a){return z(a)===d};exports.isProfiler=function(a){return z(a)===g};exports.isStrictMode=function(a){return z(a)===f};exports.isSuspense=function(a){return z(a)===p};\nexports.isValidElementType=function(a){return\"string\"===typeof a||\"function\"===typeof a||a===e||a===m||a===g||a===f||a===p||a===q||\"object\"===typeof a&&null!==a&&(a.$$typeof===t||a.$$typeof===r||a.$$typeof===h||a.$$typeof===k||a.$$typeof===n||a.$$typeof===w||a.$$typeof===x||a.$$typeof===y||a.$$typeof===v)};exports.typeOf=z;\n","/** @license React v16.13.1\n * react-is.development.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\n\n\nif (process.env.NODE_ENV !== \"production\") {\n (function() {\n'use strict';\n\n// The Symbol used to tag the ReactElement-like types. If there is no native Symbol\n// nor polyfill, then a plain number is used for performance.\nvar hasSymbol = typeof Symbol === 'function' && Symbol.for;\nvar REACT_ELEMENT_TYPE = hasSymbol ? Symbol.for('react.element') : 0xeac7;\nvar REACT_PORTAL_TYPE = hasSymbol ? Symbol.for('react.portal') : 0xeaca;\nvar REACT_FRAGMENT_TYPE = hasSymbol ? Symbol.for('react.fragment') : 0xeacb;\nvar REACT_STRICT_MODE_TYPE = hasSymbol ? Symbol.for('react.strict_mode') : 0xeacc;\nvar REACT_PROFILER_TYPE = hasSymbol ? Symbol.for('react.profiler') : 0xead2;\nvar REACT_PROVIDER_TYPE = hasSymbol ? Symbol.for('react.provider') : 0xeacd;\nvar REACT_CONTEXT_TYPE = hasSymbol ? Symbol.for('react.context') : 0xeace; // TODO: We don't use AsyncMode or ConcurrentMode anymore. They were temporary\n// (unstable) APIs that have been removed. Can we remove the symbols?\n\nvar REACT_ASYNC_MODE_TYPE = hasSymbol ? Symbol.for('react.async_mode') : 0xeacf;\nvar REACT_CONCURRENT_MODE_TYPE = hasSymbol ? Symbol.for('react.concurrent_mode') : 0xeacf;\nvar REACT_FORWARD_REF_TYPE = hasSymbol ? Symbol.for('react.forward_ref') : 0xead0;\nvar REACT_SUSPENSE_TYPE = hasSymbol ? Symbol.for('react.suspense') : 0xead1;\nvar REACT_SUSPENSE_LIST_TYPE = hasSymbol ? Symbol.for('react.suspense_list') : 0xead8;\nvar REACT_MEMO_TYPE = hasSymbol ? Symbol.for('react.memo') : 0xead3;\nvar REACT_LAZY_TYPE = hasSymbol ? Symbol.for('react.lazy') : 0xead4;\nvar REACT_BLOCK_TYPE = hasSymbol ? Symbol.for('react.block') : 0xead9;\nvar REACT_FUNDAMENTAL_TYPE = hasSymbol ? Symbol.for('react.fundamental') : 0xead5;\nvar REACT_RESPONDER_TYPE = hasSymbol ? Symbol.for('react.responder') : 0xead6;\nvar REACT_SCOPE_TYPE = hasSymbol ? Symbol.for('react.scope') : 0xead7;\n\nfunction isValidElementType(type) {\n return typeof type === 'string' || typeof type === 'function' || // Note: its typeof might be other than 'symbol' or 'number' if it's a polyfill.\n type === REACT_FRAGMENT_TYPE || type === REACT_CONCURRENT_MODE_TYPE || type === REACT_PROFILER_TYPE || type === REACT_STRICT_MODE_TYPE || type === REACT_SUSPENSE_TYPE || type === REACT_SUSPENSE_LIST_TYPE || typeof type === 'object' && type !== null && (type.$$typeof === REACT_LAZY_TYPE || type.$$typeof === REACT_MEMO_TYPE || type.$$typeof === REACT_PROVIDER_TYPE || type.$$typeof === REACT_CONTEXT_TYPE || type.$$typeof === REACT_FORWARD_REF_TYPE || type.$$typeof === REACT_FUNDAMENTAL_TYPE || type.$$typeof === REACT_RESPONDER_TYPE || type.$$typeof === REACT_SCOPE_TYPE || type.$$typeof === REACT_BLOCK_TYPE);\n}\n\nfunction typeOf(object) {\n if (typeof object === 'object' && object !== null) {\n var $$typeof = object.$$typeof;\n\n switch ($$typeof) {\n case REACT_ELEMENT_TYPE:\n var type = object.type;\n\n switch (type) {\n case REACT_ASYNC_MODE_TYPE:\n case REACT_CONCURRENT_MODE_TYPE:\n case REACT_FRAGMENT_TYPE:\n case REACT_PROFILER_TYPE:\n case REACT_STRICT_MODE_TYPE:\n case REACT_SUSPENSE_TYPE:\n return type;\n\n default:\n var $$typeofType = type && type.$$typeof;\n\n switch ($$typeofType) {\n case REACT_CONTEXT_TYPE:\n case REACT_FORWARD_REF_TYPE:\n case REACT_LAZY_TYPE:\n case REACT_MEMO_TYPE:\n case REACT_PROVIDER_TYPE:\n return $$typeofType;\n\n default:\n return $$typeof;\n }\n\n }\n\n case REACT_PORTAL_TYPE:\n return $$typeof;\n }\n }\n\n return undefined;\n} // AsyncMode is deprecated along with isAsyncMode\n\nvar AsyncMode = REACT_ASYNC_MODE_TYPE;\nvar ConcurrentMode = REACT_CONCURRENT_MODE_TYPE;\nvar ContextConsumer = REACT_CONTEXT_TYPE;\nvar ContextProvider = REACT_PROVIDER_TYPE;\nvar Element = REACT_ELEMENT_TYPE;\nvar ForwardRef = REACT_FORWARD_REF_TYPE;\nvar Fragment = REACT_FRAGMENT_TYPE;\nvar Lazy = REACT_LAZY_TYPE;\nvar Memo = REACT_MEMO_TYPE;\nvar Portal = REACT_PORTAL_TYPE;\nvar Profiler = REACT_PROFILER_TYPE;\nvar StrictMode = REACT_STRICT_MODE_TYPE;\nvar Suspense = REACT_SUSPENSE_TYPE;\nvar hasWarnedAboutDeprecatedIsAsyncMode = false; // AsyncMode should be deprecated\n\nfunction isAsyncMode(object) {\n {\n if (!hasWarnedAboutDeprecatedIsAsyncMode) {\n hasWarnedAboutDeprecatedIsAsyncMode = true; // Using console['warn'] to evade Babel and ESLint\n\n console['warn']('The ReactIs.isAsyncMode() alias has been deprecated, ' + 'and will be removed in React 17+. Update your code to use ' + 'ReactIs.isConcurrentMode() instead. It has the exact same API.');\n }\n }\n\n return isConcurrentMode(object) || typeOf(object) === REACT_ASYNC_MODE_TYPE;\n}\nfunction isConcurrentMode(object) {\n return typeOf(object) === REACT_CONCURRENT_MODE_TYPE;\n}\nfunction isContextConsumer(object) {\n return typeOf(object) === REACT_CONTEXT_TYPE;\n}\nfunction isContextProvider(object) {\n return typeOf(object) === REACT_PROVIDER_TYPE;\n}\nfunction isElement(object) {\n return typeof object === 'object' && object !== null && object.$$typeof === REACT_ELEMENT_TYPE;\n}\nfunction isForwardRef(object) {\n return typeOf(object) === REACT_FORWARD_REF_TYPE;\n}\nfunction isFragment(object) {\n return typeOf(object) === REACT_FRAGMENT_TYPE;\n}\nfunction isLazy(object) {\n return typeOf(object) === REACT_LAZY_TYPE;\n}\nfunction isMemo(object) {\n return typeOf(object) === REACT_MEMO_TYPE;\n}\nfunction isPortal(object) {\n return typeOf(object) === REACT_PORTAL_TYPE;\n}\nfunction isProfiler(object) {\n return typeOf(object) === REACT_PROFILER_TYPE;\n}\nfunction isStrictMode(object) {\n return typeOf(object) === REACT_STRICT_MODE_TYPE;\n}\nfunction isSuspense(object) {\n return typeOf(object) === REACT_SUSPENSE_TYPE;\n}\n\nexports.AsyncMode = AsyncMode;\nexports.ConcurrentMode = ConcurrentMode;\nexports.ContextConsumer = ContextConsumer;\nexports.ContextProvider = ContextProvider;\nexports.Element = Element;\nexports.ForwardRef = ForwardRef;\nexports.Fragment = Fragment;\nexports.Lazy = Lazy;\nexports.Memo = Memo;\nexports.Portal = Portal;\nexports.Profiler = Profiler;\nexports.StrictMode = StrictMode;\nexports.Suspense = Suspense;\nexports.isAsyncMode = isAsyncMode;\nexports.isConcurrentMode = isConcurrentMode;\nexports.isContextConsumer = isContextConsumer;\nexports.isContextProvider = isContextProvider;\nexports.isElement = isElement;\nexports.isForwardRef = isForwardRef;\nexports.isFragment = isFragment;\nexports.isLazy = isLazy;\nexports.isMemo = isMemo;\nexports.isPortal = isPortal;\nexports.isProfiler = isProfiler;\nexports.isStrictMode = isStrictMode;\nexports.isSuspense = isSuspense;\nexports.isValidElementType = isValidElementType;\nexports.typeOf = typeOf;\n })();\n}\n","'use strict';\n\nif (process.env.NODE_ENV === 'production') {\n module.exports = require('./cjs/react-is.production.min.js');\n} else {\n module.exports = require('./cjs/react-is.development.js');\n}\n","/*\nobject-assign\n(c) Sindre Sorhus\n@license MIT\n*/\n\n'use strict';\n/* eslint-disable no-unused-vars */\nvar getOwnPropertySymbols = Object.getOwnPropertySymbols;\nvar hasOwnProperty = Object.prototype.hasOwnProperty;\nvar propIsEnumerable = Object.prototype.propertyIsEnumerable;\n\nfunction toObject(val) {\n\tif (val === null || val === undefined) {\n\t\tthrow new TypeError('Object.assign cannot be called with null or undefined');\n\t}\n\n\treturn Object(val);\n}\n\nfunction shouldUseNative() {\n\ttry {\n\t\tif (!Object.assign) {\n\t\t\treturn false;\n\t\t}\n\n\t\t// Detect buggy property enumeration order in older V8 versions.\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=4118\n\t\tvar test1 = new String('abc'); // eslint-disable-line no-new-wrappers\n\t\ttest1[5] = 'de';\n\t\tif (Object.getOwnPropertyNames(test1)[0] === '5') {\n\t\t\treturn false;\n\t\t}\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=3056\n\t\tvar test2 = {};\n\t\tfor (var i = 0; i < 10; i++) {\n\t\t\ttest2['_' + String.fromCharCode(i)] = i;\n\t\t}\n\t\tvar order2 = Object.getOwnPropertyNames(test2).map(function (n) {\n\t\t\treturn test2[n];\n\t\t});\n\t\tif (order2.join('') !== '0123456789') {\n\t\t\treturn false;\n\t\t}\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=3056\n\t\tvar test3 = {};\n\t\t'abcdefghijklmnopqrst'.split('').forEach(function (letter) {\n\t\t\ttest3[letter] = letter;\n\t\t});\n\t\tif (Object.keys(Object.assign({}, test3)).join('') !==\n\t\t\t\t'abcdefghijklmnopqrst') {\n\t\t\treturn false;\n\t\t}\n\n\t\treturn true;\n\t} catch (err) {\n\t\t// We don't expect any of the above to throw, but better to be safe.\n\t\treturn false;\n\t}\n}\n\nmodule.exports = shouldUseNative() ? Object.assign : function (target, source) {\n\tvar from;\n\tvar to = toObject(target);\n\tvar symbols;\n\n\tfor (var s = 1; s < arguments.length; s++) {\n\t\tfrom = Object(arguments[s]);\n\n\t\tfor (var key in from) {\n\t\t\tif (hasOwnProperty.call(from, key)) {\n\t\t\t\tto[key] = from[key];\n\t\t\t}\n\t\t}\n\n\t\tif (getOwnPropertySymbols) {\n\t\t\tsymbols = getOwnPropertySymbols(from);\n\t\t\tfor (var i = 0; i < symbols.length; i++) {\n\t\t\t\tif (propIsEnumerable.call(from, symbols[i])) {\n\t\t\t\t\tto[symbols[i]] = from[symbols[i]];\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\n\treturn to;\n};\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar ReactPropTypesSecret = 'SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED';\n\nmodule.exports = ReactPropTypesSecret;\n","module.exports = Function.call.bind(Object.prototype.hasOwnProperty);\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar printWarning = function() {};\n\nif (process.env.NODE_ENV !== 'production') {\n var ReactPropTypesSecret = require('./lib/ReactPropTypesSecret');\n var loggedTypeFailures = {};\n var has = require('./lib/has');\n\n printWarning = function(text) {\n var message = 'Warning: ' + text;\n if (typeof console !== 'undefined') {\n console.error(message);\n }\n try {\n // --- Welcome to debugging React ---\n // This error was thrown as a convenience so that you can use this stack\n // to find the callsite that caused this warning to fire.\n throw new Error(message);\n } catch (x) { /**/ }\n };\n}\n\n/**\n * Assert that the values match with the type specs.\n * Error messages are memorized and will only be shown once.\n *\n * @param {object} typeSpecs Map of name to a ReactPropType\n * @param {object} values Runtime values that need to be type-checked\n * @param {string} location e.g. \"prop\", \"context\", \"child context\"\n * @param {string} componentName Name of the component for error messages.\n * @param {?Function} getStack Returns the component stack.\n * @private\n */\nfunction checkPropTypes(typeSpecs, values, location, componentName, getStack) {\n if (process.env.NODE_ENV !== 'production') {\n for (var typeSpecName in typeSpecs) {\n if (has(typeSpecs, typeSpecName)) {\n var error;\n // Prop type validation may throw. In case they do, we don't want to\n // fail the render phase where it didn't fail before. So we log it.\n // After these have been cleaned up, we'll let them throw.\n try {\n // This is intentionally an invariant that gets caught. It's the same\n // behavior as without this statement except with a better message.\n if (typeof typeSpecs[typeSpecName] !== 'function') {\n var err = Error(\n (componentName || 'React class') + ': ' + location + ' type `' + typeSpecName + '` is invalid; ' +\n 'it must be a function, usually from the `prop-types` package, but received `' + typeof typeSpecs[typeSpecName] + '`.' +\n 'This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.'\n );\n err.name = 'Invariant Violation';\n throw err;\n }\n error = typeSpecs[typeSpecName](values, typeSpecName, componentName, location, null, ReactPropTypesSecret);\n } catch (ex) {\n error = ex;\n }\n if (error && !(error instanceof Error)) {\n printWarning(\n (componentName || 'React class') + ': type specification of ' +\n location + ' `' + typeSpecName + '` is invalid; the type checker ' +\n 'function must return `null` or an `Error` but returned a ' + typeof error + '. ' +\n 'You may have forgotten to pass an argument to the type checker ' +\n 'creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and ' +\n 'shape all require an argument).'\n );\n }\n if (error instanceof Error && !(error.message in loggedTypeFailures)) {\n // Only monitor this failure once because there tends to be a lot of the\n // same error.\n loggedTypeFailures[error.message] = true;\n\n var stack = getStack ? getStack() : '';\n\n printWarning(\n 'Failed ' + location + ' type: ' + error.message + (stack != null ? stack : '')\n );\n }\n }\n }\n }\n}\n\n/**\n * Resets warning cache when testing.\n *\n * @private\n */\ncheckPropTypes.resetWarningCache = function() {\n if (process.env.NODE_ENV !== 'production') {\n loggedTypeFailures = {};\n }\n}\n\nmodule.exports = checkPropTypes;\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar ReactIs = require('react-is');\nvar assign = require('object-assign');\n\nvar ReactPropTypesSecret = require('./lib/ReactPropTypesSecret');\nvar has = require('./lib/has');\nvar checkPropTypes = require('./checkPropTypes');\n\nvar printWarning = function() {};\n\nif (process.env.NODE_ENV !== 'production') {\n printWarning = function(text) {\n var message = 'Warning: ' + text;\n if (typeof console !== 'undefined') {\n console.error(message);\n }\n try {\n // --- Welcome to debugging React ---\n // This error was thrown as a convenience so that you can use this stack\n // to find the callsite that caused this warning to fire.\n throw new Error(message);\n } catch (x) {}\n };\n}\n\nfunction emptyFunctionThatReturnsNull() {\n return null;\n}\n\nmodule.exports = function(isValidElement, throwOnDirectAccess) {\n /* global Symbol */\n var ITERATOR_SYMBOL = typeof Symbol === 'function' && Symbol.iterator;\n var FAUX_ITERATOR_SYMBOL = '@@iterator'; // Before Symbol spec.\n\n /**\n * Returns the iterator method function contained on the iterable object.\n *\n * Be sure to invoke the function with the iterable as context:\n *\n * var iteratorFn = getIteratorFn(myIterable);\n * if (iteratorFn) {\n * var iterator = iteratorFn.call(myIterable);\n * ...\n * }\n *\n * @param {?object} maybeIterable\n * @return {?function}\n */\n function getIteratorFn(maybeIterable) {\n var iteratorFn = maybeIterable && (ITERATOR_SYMBOL && maybeIterable[ITERATOR_SYMBOL] || maybeIterable[FAUX_ITERATOR_SYMBOL]);\n if (typeof iteratorFn === 'function') {\n return iteratorFn;\n }\n }\n\n /**\n * Collection of methods that allow declaration and validation of props that are\n * supplied to React components. Example usage:\n *\n * var Props = require('ReactPropTypes');\n * var MyArticle = React.createClass({\n * propTypes: {\n * // An optional string prop named \"description\".\n * description: Props.string,\n *\n * // A required enum prop named \"category\".\n * category: Props.oneOf(['News','Photos']).isRequired,\n *\n * // A prop named \"dialog\" that requires an instance of Dialog.\n * dialog: Props.instanceOf(Dialog).isRequired\n * },\n * render: function() { ... }\n * });\n *\n * A more formal specification of how these methods are used:\n *\n * type := array|bool|func|object|number|string|oneOf([...])|instanceOf(...)\n * decl := ReactPropTypes.{type}(.isRequired)?\n *\n * Each and every declaration produces a function with the same signature. This\n * allows the creation of custom validation functions. For example:\n *\n * var MyLink = React.createClass({\n * propTypes: {\n * // An optional string or URI prop named \"href\".\n * href: function(props, propName, componentName) {\n * var propValue = props[propName];\n * if (propValue != null && typeof propValue !== 'string' &&\n * !(propValue instanceof URI)) {\n * return new Error(\n * 'Expected a string or an URI for ' + propName + ' in ' +\n * componentName\n * );\n * }\n * }\n * },\n * render: function() {...}\n * });\n *\n * @internal\n */\n\n var ANONYMOUS = '<>';\n\n // Important!\n // Keep this list in sync with production version in `./factoryWithThrowingShims.js`.\n var ReactPropTypes = {\n array: createPrimitiveTypeChecker('array'),\n bigint: createPrimitiveTypeChecker('bigint'),\n bool: createPrimitiveTypeChecker('boolean'),\n func: createPrimitiveTypeChecker('function'),\n number: createPrimitiveTypeChecker('number'),\n object: createPrimitiveTypeChecker('object'),\n string: createPrimitiveTypeChecker('string'),\n symbol: createPrimitiveTypeChecker('symbol'),\n\n any: createAnyTypeChecker(),\n arrayOf: createArrayOfTypeChecker,\n element: createElementTypeChecker(),\n elementType: createElementTypeTypeChecker(),\n instanceOf: createInstanceTypeChecker,\n node: createNodeChecker(),\n objectOf: createObjectOfTypeChecker,\n oneOf: createEnumTypeChecker,\n oneOfType: createUnionTypeChecker,\n shape: createShapeTypeChecker,\n exact: createStrictShapeTypeChecker,\n };\n\n /**\n * inlined Object.is polyfill to avoid requiring consumers ship their own\n * https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object/is\n */\n /*eslint-disable no-self-compare*/\n function is(x, y) {\n // SameValue algorithm\n if (x === y) {\n // Steps 1-5, 7-10\n // Steps 6.b-6.e: +0 != -0\n return x !== 0 || 1 / x === 1 / y;\n } else {\n // Step 6.a: NaN == NaN\n return x !== x && y !== y;\n }\n }\n /*eslint-enable no-self-compare*/\n\n /**\n * We use an Error-like object for backward compatibility as people may call\n * PropTypes directly and inspect their output. However, we don't use real\n * Errors anymore. We don't inspect their stack anyway, and creating them\n * is prohibitively expensive if they are created too often, such as what\n * happens in oneOfType() for any type before the one that matched.\n */\n function PropTypeError(message, data) {\n this.message = message;\n this.data = data && typeof data === 'object' ? data: {};\n this.stack = '';\n }\n // Make `instanceof Error` still work for returned errors.\n PropTypeError.prototype = Error.prototype;\n\n function createChainableTypeChecker(validate) {\n if (process.env.NODE_ENV !== 'production') {\n var manualPropTypeCallCache = {};\n var manualPropTypeWarningCount = 0;\n }\n function checkType(isRequired, props, propName, componentName, location, propFullName, secret) {\n componentName = componentName || ANONYMOUS;\n propFullName = propFullName || propName;\n\n if (secret !== ReactPropTypesSecret) {\n if (throwOnDirectAccess) {\n // New behavior only for users of `prop-types` package\n var err = new Error(\n 'Calling PropTypes validators directly is not supported by the `prop-types` package. ' +\n 'Use `PropTypes.checkPropTypes()` to call them. ' +\n 'Read more at http://fb.me/use-check-prop-types'\n );\n err.name = 'Invariant Violation';\n throw err;\n } else if (process.env.NODE_ENV !== 'production' && typeof console !== 'undefined') {\n // Old behavior for people using React.PropTypes\n var cacheKey = componentName + ':' + propName;\n if (\n !manualPropTypeCallCache[cacheKey] &&\n // Avoid spamming the console because they are often not actionable except for lib authors\n manualPropTypeWarningCount < 3\n ) {\n printWarning(\n 'You are manually calling a React.PropTypes validation ' +\n 'function for the `' + propFullName + '` prop on `' + componentName + '`. This is deprecated ' +\n 'and will throw in the standalone `prop-types` package. ' +\n 'You may be seeing this warning due to a third-party PropTypes ' +\n 'library. See https://fb.me/react-warning-dont-call-proptypes ' + 'for details.'\n );\n manualPropTypeCallCache[cacheKey] = true;\n manualPropTypeWarningCount++;\n }\n }\n }\n if (props[propName] == null) {\n if (isRequired) {\n if (props[propName] === null) {\n return new PropTypeError('The ' + location + ' `' + propFullName + '` is marked as required ' + ('in `' + componentName + '`, but its value is `null`.'));\n }\n return new PropTypeError('The ' + location + ' `' + propFullName + '` is marked as required in ' + ('`' + componentName + '`, but its value is `undefined`.'));\n }\n return null;\n } else {\n return validate(props, propName, componentName, location, propFullName);\n }\n }\n\n var chainedCheckType = checkType.bind(null, false);\n chainedCheckType.isRequired = checkType.bind(null, true);\n\n return chainedCheckType;\n }\n\n function createPrimitiveTypeChecker(expectedType) {\n function validate(props, propName, componentName, location, propFullName, secret) {\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== expectedType) {\n // `propValue` being instance of, say, date/regexp, pass the 'object'\n // check, but we can offer a more precise error message here rather than\n // 'of type `object`'.\n var preciseType = getPreciseType(propValue);\n\n return new PropTypeError(\n 'Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + preciseType + '` supplied to `' + componentName + '`, expected ') + ('`' + expectedType + '`.'),\n {expectedType: expectedType}\n );\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createAnyTypeChecker() {\n return createChainableTypeChecker(emptyFunctionThatReturnsNull);\n }\n\n function createArrayOfTypeChecker(typeChecker) {\n function validate(props, propName, componentName, location, propFullName) {\n if (typeof typeChecker !== 'function') {\n return new PropTypeError('Property `' + propFullName + '` of component `' + componentName + '` has invalid PropType notation inside arrayOf.');\n }\n var propValue = props[propName];\n if (!Array.isArray(propValue)) {\n var propType = getPropType(propValue);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected an array.'));\n }\n for (var i = 0; i < propValue.length; i++) {\n var error = typeChecker(propValue, i, componentName, location, propFullName + '[' + i + ']', ReactPropTypesSecret);\n if (error instanceof Error) {\n return error;\n }\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createElementTypeChecker() {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n if (!isValidElement(propValue)) {\n var propType = getPropType(propValue);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected a single ReactElement.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createElementTypeTypeChecker() {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n if (!ReactIs.isValidElementType(propValue)) {\n var propType = getPropType(propValue);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected a single ReactElement type.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createInstanceTypeChecker(expectedClass) {\n function validate(props, propName, componentName, location, propFullName) {\n if (!(props[propName] instanceof expectedClass)) {\n var expectedClassName = expectedClass.name || ANONYMOUS;\n var actualClassName = getClassName(props[propName]);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + actualClassName + '` supplied to `' + componentName + '`, expected ') + ('instance of `' + expectedClassName + '`.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createEnumTypeChecker(expectedValues) {\n if (!Array.isArray(expectedValues)) {\n if (process.env.NODE_ENV !== 'production') {\n if (arguments.length > 1) {\n printWarning(\n 'Invalid arguments supplied to oneOf, expected an array, got ' + arguments.length + ' arguments. ' +\n 'A common mistake is to write oneOf(x, y, z) instead of oneOf([x, y, z]).'\n );\n } else {\n printWarning('Invalid argument supplied to oneOf, expected an array.');\n }\n }\n return emptyFunctionThatReturnsNull;\n }\n\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n for (var i = 0; i < expectedValues.length; i++) {\n if (is(propValue, expectedValues[i])) {\n return null;\n }\n }\n\n var valuesString = JSON.stringify(expectedValues, function replacer(key, value) {\n var type = getPreciseType(value);\n if (type === 'symbol') {\n return String(value);\n }\n return value;\n });\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of value `' + String(propValue) + '` ' + ('supplied to `' + componentName + '`, expected one of ' + valuesString + '.'));\n }\n return createChainableTypeChecker(validate);\n }\n\n function createObjectOfTypeChecker(typeChecker) {\n function validate(props, propName, componentName, location, propFullName) {\n if (typeof typeChecker !== 'function') {\n return new PropTypeError('Property `' + propFullName + '` of component `' + componentName + '` has invalid PropType notation inside objectOf.');\n }\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== 'object') {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected an object.'));\n }\n for (var key in propValue) {\n if (has(propValue, key)) {\n var error = typeChecker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret);\n if (error instanceof Error) {\n return error;\n }\n }\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createUnionTypeChecker(arrayOfTypeCheckers) {\n if (!Array.isArray(arrayOfTypeCheckers)) {\n process.env.NODE_ENV !== 'production' ? printWarning('Invalid argument supplied to oneOfType, expected an instance of array.') : void 0;\n return emptyFunctionThatReturnsNull;\n }\n\n for (var i = 0; i < arrayOfTypeCheckers.length; i++) {\n var checker = arrayOfTypeCheckers[i];\n if (typeof checker !== 'function') {\n printWarning(\n 'Invalid argument supplied to oneOfType. Expected an array of check functions, but ' +\n 'received ' + getPostfixForTypeWarning(checker) + ' at index ' + i + '.'\n );\n return emptyFunctionThatReturnsNull;\n }\n }\n\n function validate(props, propName, componentName, location, propFullName) {\n var expectedTypes = [];\n for (var i = 0; i < arrayOfTypeCheckers.length; i++) {\n var checker = arrayOfTypeCheckers[i];\n var checkerResult = checker(props, propName, componentName, location, propFullName, ReactPropTypesSecret);\n if (checkerResult == null) {\n return null;\n }\n if (checkerResult.data && has(checkerResult.data, 'expectedType')) {\n expectedTypes.push(checkerResult.data.expectedType);\n }\n }\n var expectedTypesMessage = (expectedTypes.length > 0) ? ', expected one of type [' + expectedTypes.join(', ') + ']': '';\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` supplied to ' + ('`' + componentName + '`' + expectedTypesMessage + '.'));\n }\n return createChainableTypeChecker(validate);\n }\n\n function createNodeChecker() {\n function validate(props, propName, componentName, location, propFullName) {\n if (!isNode(props[propName])) {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` supplied to ' + ('`' + componentName + '`, expected a ReactNode.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function invalidValidatorError(componentName, location, propFullName, key, type) {\n return new PropTypeError(\n (componentName || 'React class') + ': ' + location + ' type `' + propFullName + '.' + key + '` is invalid; ' +\n 'it must be a function, usually from the `prop-types` package, but received `' + type + '`.'\n );\n }\n\n function createShapeTypeChecker(shapeTypes) {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== 'object') {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type `' + propType + '` ' + ('supplied to `' + componentName + '`, expected `object`.'));\n }\n for (var key in shapeTypes) {\n var checker = shapeTypes[key];\n if (typeof checker !== 'function') {\n return invalidValidatorError(componentName, location, propFullName, key, getPreciseType(checker));\n }\n var error = checker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret);\n if (error) {\n return error;\n }\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createStrictShapeTypeChecker(shapeTypes) {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== 'object') {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type `' + propType + '` ' + ('supplied to `' + componentName + '`, expected `object`.'));\n }\n // We need to check all keys in case some are required but missing from props.\n var allKeys = assign({}, props[propName], shapeTypes);\n for (var key in allKeys) {\n var checker = shapeTypes[key];\n if (has(shapeTypes, key) && typeof checker !== 'function') {\n return invalidValidatorError(componentName, location, propFullName, key, getPreciseType(checker));\n }\n if (!checker) {\n return new PropTypeError(\n 'Invalid ' + location + ' `' + propFullName + '` key `' + key + '` supplied to `' + componentName + '`.' +\n '\\nBad object: ' + JSON.stringify(props[propName], null, ' ') +\n '\\nValid keys: ' + JSON.stringify(Object.keys(shapeTypes), null, ' ')\n );\n }\n var error = checker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret);\n if (error) {\n return error;\n }\n }\n return null;\n }\n\n return createChainableTypeChecker(validate);\n }\n\n function isNode(propValue) {\n switch (typeof propValue) {\n case 'number':\n case 'string':\n case 'undefined':\n return true;\n case 'boolean':\n return !propValue;\n case 'object':\n if (Array.isArray(propValue)) {\n return propValue.every(isNode);\n }\n if (propValue === null || isValidElement(propValue)) {\n return true;\n }\n\n var iteratorFn = getIteratorFn(propValue);\n if (iteratorFn) {\n var iterator = iteratorFn.call(propValue);\n var step;\n if (iteratorFn !== propValue.entries) {\n while (!(step = iterator.next()).done) {\n if (!isNode(step.value)) {\n return false;\n }\n }\n } else {\n // Iterator will provide entry [k,v] tuples rather than values.\n while (!(step = iterator.next()).done) {\n var entry = step.value;\n if (entry) {\n if (!isNode(entry[1])) {\n return false;\n }\n }\n }\n }\n } else {\n return false;\n }\n\n return true;\n default:\n return false;\n }\n }\n\n function isSymbol(propType, propValue) {\n // Native Symbol.\n if (propType === 'symbol') {\n return true;\n }\n\n // falsy value can't be a Symbol\n if (!propValue) {\n return false;\n }\n\n // 19.4.3.5 Symbol.prototype[@@toStringTag] === 'Symbol'\n if (propValue['@@toStringTag'] === 'Symbol') {\n return true;\n }\n\n // Fallback for non-spec compliant Symbols which are polyfilled.\n if (typeof Symbol === 'function' && propValue instanceof Symbol) {\n return true;\n }\n\n return false;\n }\n\n // Equivalent of `typeof` but with special handling for array and regexp.\n function getPropType(propValue) {\n var propType = typeof propValue;\n if (Array.isArray(propValue)) {\n return 'array';\n }\n if (propValue instanceof RegExp) {\n // Old webkits (at least until Android 4.0) return 'function' rather than\n // 'object' for typeof a RegExp. We'll normalize this here so that /bla/\n // passes PropTypes.object.\n return 'object';\n }\n if (isSymbol(propType, propValue)) {\n return 'symbol';\n }\n return propType;\n }\n\n // This handles more types than `getPropType`. Only used for error messages.\n // See `createPrimitiveTypeChecker`.\n function getPreciseType(propValue) {\n if (typeof propValue === 'undefined' || propValue === null) {\n return '' + propValue;\n }\n var propType = getPropType(propValue);\n if (propType === 'object') {\n if (propValue instanceof Date) {\n return 'date';\n } else if (propValue instanceof RegExp) {\n return 'regexp';\n }\n }\n return propType;\n }\n\n // Returns a string that is postfixed to a warning about an invalid type.\n // For example, \"undefined\" or \"of type array\"\n function getPostfixForTypeWarning(value) {\n var type = getPreciseType(value);\n switch (type) {\n case 'array':\n case 'object':\n return 'an ' + type;\n case 'boolean':\n case 'date':\n case 'regexp':\n return 'a ' + type;\n default:\n return type;\n }\n }\n\n // Returns class name of the object, if any.\n function getClassName(propValue) {\n if (!propValue.constructor || !propValue.constructor.name) {\n return ANONYMOUS;\n }\n return propValue.constructor.name;\n }\n\n ReactPropTypes.checkPropTypes = checkPropTypes;\n ReactPropTypes.resetWarningCache = checkPropTypes.resetWarningCache;\n ReactPropTypes.PropTypes = ReactPropTypes;\n\n return ReactPropTypes;\n};\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar ReactPropTypesSecret = require('./lib/ReactPropTypesSecret');\n\nfunction emptyFunction() {}\nfunction emptyFunctionWithReset() {}\nemptyFunctionWithReset.resetWarningCache = emptyFunction;\n\nmodule.exports = function() {\n function shim(props, propName, componentName, location, propFullName, secret) {\n if (secret === ReactPropTypesSecret) {\n // It is still safe when called from React.\n return;\n }\n var err = new Error(\n 'Calling PropTypes validators directly is not supported by the `prop-types` package. ' +\n 'Use PropTypes.checkPropTypes() to call them. ' +\n 'Read more at http://fb.me/use-check-prop-types'\n );\n err.name = 'Invariant Violation';\n throw err;\n };\n shim.isRequired = shim;\n function getShim() {\n return shim;\n };\n // Important!\n // Keep this list in sync with production version in `./factoryWithTypeCheckers.js`.\n var ReactPropTypes = {\n array: shim,\n bigint: shim,\n bool: shim,\n func: shim,\n number: shim,\n object: shim,\n string: shim,\n symbol: shim,\n\n any: shim,\n arrayOf: getShim,\n element: shim,\n elementType: shim,\n instanceOf: getShim,\n node: shim,\n objectOf: getShim,\n oneOf: getShim,\n oneOfType: getShim,\n shape: getShim,\n exact: getShim,\n\n checkPropTypes: emptyFunctionWithReset,\n resetWarningCache: emptyFunction\n };\n\n ReactPropTypes.PropTypes = ReactPropTypes;\n\n return ReactPropTypes;\n};\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\nif (process.env.NODE_ENV !== 'production') {\n var ReactIs = require('react-is');\n\n // By explicitly using `prop-types` you are opting into new development behavior.\n // http://fb.me/prop-types-in-prod\n var throwOnDirectAccess = true;\n module.exports = require('./factoryWithTypeCheckers')(ReactIs.isElement, throwOnDirectAccess);\n} else {\n // By explicitly using `prop-types` you are opting into new production behavior.\n // http://fb.me/prop-types-in-prod\n module.exports = require('./factoryWithThrowingShims')();\n}\n","import PropTypes from 'prop-types';\nimport chainPropTypes from '../chainPropTypes';\nfunction isClassComponent(elementType) {\n // elementType.prototype?.isReactComponent\n const {\n prototype = {}\n } = elementType;\n return Boolean(prototype.isReactComponent);\n}\nfunction acceptingRef(props, propName, componentName, location, propFullName) {\n const element = props[propName];\n const safePropName = propFullName || propName;\n if (element == null ||\n // When server-side rendering React doesn't warn either.\n // This is not an accurate check for SSR.\n // This is only in place for Emotion compat.\n // TODO: Revisit once https://github.com/facebook/react/issues/20047 is resolved.\n typeof window === 'undefined') {\n return null;\n }\n let warningHint;\n const elementType = element.type;\n /**\n * Blacklisting instead of whitelisting\n *\n * Blacklisting will miss some components, such as React.Fragment. Those will at least\n * trigger a warning in React.\n * We can't whitelist because there is no safe way to detect React.forwardRef\n * or class components. \"Safe\" means there's no public API.\n *\n */\n if (typeof elementType === 'function' && !isClassComponent(elementType)) {\n warningHint = 'Did you accidentally use a plain function component for an element instead?';\n }\n if (warningHint !== undefined) {\n return new Error(`Invalid ${location} \\`${safePropName}\\` supplied to \\`${componentName}\\`. ` + `Expected an element that can hold a ref. ${warningHint} ` + 'For more information see https://mui.com/r/caveat-with-refs-guide');\n }\n return null;\n}\nconst elementAcceptingRef = chainPropTypes(PropTypes.element, acceptingRef);\nelementAcceptingRef.isRequired = chainPropTypes(PropTypes.element.isRequired, acceptingRef);\nexport default elementAcceptingRef;","import _extends from \"@babel/runtime/helpers/esm/extends\";\n// This module is based on https://github.com/airbnb/prop-types-exact repository.\n// However, in order to reduce the number of dependencies and to remove some extra safe checks\n// the module was forked.\n\nconst specialProperty = 'exact-prop: \\u200b';\nexport default function exactProp(propTypes) {\n if (process.env.NODE_ENV === 'production') {\n return propTypes;\n }\n return _extends({}, propTypes, {\n [specialProperty]: props => {\n const unsupportedProps = Object.keys(props).filter(prop => !propTypes.hasOwnProperty(prop));\n if (unsupportedProps.length > 0) {\n return new Error(`The following props are not supported: ${unsupportedProps.map(prop => `\\`${prop}\\``).join(', ')}. Please remove them.`);\n }\n return null;\n }\n });\n}","/**\n * WARNING: Don't import this directly.\n * Use `MuiError` from `@mui/internal-babel-macros/MuiError.macro` instead.\n * @param {number} code\n */\nexport default function formatMuiErrorMessage(code) {\n // Apply babel-plugin-transform-template-literals in loose mode\n // loose mode is safe if we're concatenating primitives\n // see https://babeljs.io/docs/en/babel-plugin-transform-template-literals#loose\n /* eslint-disable prefer-template */\n let url = 'https://mui.com/production-error/?code=' + code;\n for (let i = 1; i < arguments.length; i += 1) {\n // rest params over-transpile for this case\n // eslint-disable-next-line prefer-rest-params\n url += '&args[]=' + encodeURIComponent(arguments[i]);\n }\n return 'Minified MUI error #' + code + '; visit ' + url + ' for the full message.';\n /* eslint-enable prefer-template */\n}","/**\n * @license React\n * react-is.production.min.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n'use strict';var b=Symbol.for(\"react.element\"),c=Symbol.for(\"react.portal\"),d=Symbol.for(\"react.fragment\"),e=Symbol.for(\"react.strict_mode\"),f=Symbol.for(\"react.profiler\"),g=Symbol.for(\"react.provider\"),h=Symbol.for(\"react.context\"),k=Symbol.for(\"react.server_context\"),l=Symbol.for(\"react.forward_ref\"),m=Symbol.for(\"react.suspense\"),n=Symbol.for(\"react.suspense_list\"),p=Symbol.for(\"react.memo\"),q=Symbol.for(\"react.lazy\"),t=Symbol.for(\"react.offscreen\"),u;u=Symbol.for(\"react.module.reference\");\nfunction v(a){if(\"object\"===typeof a&&null!==a){var r=a.$$typeof;switch(r){case b:switch(a=a.type,a){case d:case f:case e:case m:case n:return a;default:switch(a=a&&a.$$typeof,a){case k:case h:case l:case q:case p:case g:return a;default:return r}}case c:return r}}}exports.ContextConsumer=h;exports.ContextProvider=g;exports.Element=b;exports.ForwardRef=l;exports.Fragment=d;exports.Lazy=q;exports.Memo=p;exports.Portal=c;exports.Profiler=f;exports.StrictMode=e;exports.Suspense=m;\nexports.SuspenseList=n;exports.isAsyncMode=function(){return!1};exports.isConcurrentMode=function(){return!1};exports.isContextConsumer=function(a){return v(a)===h};exports.isContextProvider=function(a){return v(a)===g};exports.isElement=function(a){return\"object\"===typeof a&&null!==a&&a.$$typeof===b};exports.isForwardRef=function(a){return v(a)===l};exports.isFragment=function(a){return v(a)===d};exports.isLazy=function(a){return v(a)===q};exports.isMemo=function(a){return v(a)===p};\nexports.isPortal=function(a){return v(a)===c};exports.isProfiler=function(a){return v(a)===f};exports.isStrictMode=function(a){return v(a)===e};exports.isSuspense=function(a){return v(a)===m};exports.isSuspenseList=function(a){return v(a)===n};\nexports.isValidElementType=function(a){return\"string\"===typeof a||\"function\"===typeof a||a===d||a===f||a===e||a===m||a===n||a===t||\"object\"===typeof a&&null!==a&&(a.$$typeof===q||a.$$typeof===p||a.$$typeof===g||a.$$typeof===h||a.$$typeof===l||a.$$typeof===u||void 0!==a.getModuleId)?!0:!1};exports.typeOf=v;\n","/**\n * @license React\n * react-is.development.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nif (process.env.NODE_ENV !== \"production\") {\n (function() {\n'use strict';\n\n// ATTENTION\n// When adding new symbols to this file,\n// Please consider also adding to 'react-devtools-shared/src/backend/ReactSymbols'\n// The Symbol used to tag the ReactElement-like types.\nvar REACT_ELEMENT_TYPE = Symbol.for('react.element');\nvar REACT_PORTAL_TYPE = Symbol.for('react.portal');\nvar REACT_FRAGMENT_TYPE = Symbol.for('react.fragment');\nvar REACT_STRICT_MODE_TYPE = Symbol.for('react.strict_mode');\nvar REACT_PROFILER_TYPE = Symbol.for('react.profiler');\nvar REACT_PROVIDER_TYPE = Symbol.for('react.provider');\nvar REACT_CONTEXT_TYPE = Symbol.for('react.context');\nvar REACT_SERVER_CONTEXT_TYPE = Symbol.for('react.server_context');\nvar REACT_FORWARD_REF_TYPE = Symbol.for('react.forward_ref');\nvar REACT_SUSPENSE_TYPE = Symbol.for('react.suspense');\nvar REACT_SUSPENSE_LIST_TYPE = Symbol.for('react.suspense_list');\nvar REACT_MEMO_TYPE = Symbol.for('react.memo');\nvar REACT_LAZY_TYPE = Symbol.for('react.lazy');\nvar REACT_OFFSCREEN_TYPE = Symbol.for('react.offscreen');\n\n// -----------------------------------------------------------------------------\n\nvar enableScopeAPI = false; // Experimental Create Event Handle API.\nvar enableCacheElement = false;\nvar enableTransitionTracing = false; // No known bugs, but needs performance testing\n\nvar enableLegacyHidden = false; // Enables unstable_avoidThisFallback feature in Fiber\n// stuff. Intended to enable React core members to more easily debug scheduling\n// issues in DEV builds.\n\nvar enableDebugTracing = false; // Track which Fiber(s) schedule render work.\n\nvar REACT_MODULE_REFERENCE;\n\n{\n REACT_MODULE_REFERENCE = Symbol.for('react.module.reference');\n}\n\nfunction isValidElementType(type) {\n if (typeof type === 'string' || typeof type === 'function') {\n return true;\n } // Note: typeof might be other than 'symbol' or 'number' (e.g. if it's a polyfill).\n\n\n if (type === REACT_FRAGMENT_TYPE || type === REACT_PROFILER_TYPE || enableDebugTracing || type === REACT_STRICT_MODE_TYPE || type === REACT_SUSPENSE_TYPE || type === REACT_SUSPENSE_LIST_TYPE || enableLegacyHidden || type === REACT_OFFSCREEN_TYPE || enableScopeAPI || enableCacheElement || enableTransitionTracing ) {\n return true;\n }\n\n if (typeof type === 'object' && type !== null) {\n if (type.$$typeof === REACT_LAZY_TYPE || type.$$typeof === REACT_MEMO_TYPE || type.$$typeof === REACT_PROVIDER_TYPE || type.$$typeof === REACT_CONTEXT_TYPE || type.$$typeof === REACT_FORWARD_REF_TYPE || // This needs to include all possible module reference object\n // types supported by any Flight configuration anywhere since\n // we don't know which Flight build this will end up being used\n // with.\n type.$$typeof === REACT_MODULE_REFERENCE || type.getModuleId !== undefined) {\n return true;\n }\n }\n\n return false;\n}\n\nfunction typeOf(object) {\n if (typeof object === 'object' && object !== null) {\n var $$typeof = object.$$typeof;\n\n switch ($$typeof) {\n case REACT_ELEMENT_TYPE:\n var type = object.type;\n\n switch (type) {\n case REACT_FRAGMENT_TYPE:\n case REACT_PROFILER_TYPE:\n case REACT_STRICT_MODE_TYPE:\n case REACT_SUSPENSE_TYPE:\n case REACT_SUSPENSE_LIST_TYPE:\n return type;\n\n default:\n var $$typeofType = type && type.$$typeof;\n\n switch ($$typeofType) {\n case REACT_SERVER_CONTEXT_TYPE:\n case REACT_CONTEXT_TYPE:\n case REACT_FORWARD_REF_TYPE:\n case REACT_LAZY_TYPE:\n case REACT_MEMO_TYPE:\n case REACT_PROVIDER_TYPE:\n return $$typeofType;\n\n default:\n return $$typeof;\n }\n\n }\n\n case REACT_PORTAL_TYPE:\n return $$typeof;\n }\n }\n\n return undefined;\n}\nvar ContextConsumer = REACT_CONTEXT_TYPE;\nvar ContextProvider = REACT_PROVIDER_TYPE;\nvar Element = REACT_ELEMENT_TYPE;\nvar ForwardRef = REACT_FORWARD_REF_TYPE;\nvar Fragment = REACT_FRAGMENT_TYPE;\nvar Lazy = REACT_LAZY_TYPE;\nvar Memo = REACT_MEMO_TYPE;\nvar Portal = REACT_PORTAL_TYPE;\nvar Profiler = REACT_PROFILER_TYPE;\nvar StrictMode = REACT_STRICT_MODE_TYPE;\nvar Suspense = REACT_SUSPENSE_TYPE;\nvar SuspenseList = REACT_SUSPENSE_LIST_TYPE;\nvar hasWarnedAboutDeprecatedIsAsyncMode = false;\nvar hasWarnedAboutDeprecatedIsConcurrentMode = false; // AsyncMode should be deprecated\n\nfunction isAsyncMode(object) {\n {\n if (!hasWarnedAboutDeprecatedIsAsyncMode) {\n hasWarnedAboutDeprecatedIsAsyncMode = true; // Using console['warn'] to evade Babel and ESLint\n\n console['warn']('The ReactIs.isAsyncMode() alias has been deprecated, ' + 'and will be removed in React 18+.');\n }\n }\n\n return false;\n}\nfunction isConcurrentMode(object) {\n {\n if (!hasWarnedAboutDeprecatedIsConcurrentMode) {\n hasWarnedAboutDeprecatedIsConcurrentMode = true; // Using console['warn'] to evade Babel and ESLint\n\n console['warn']('The ReactIs.isConcurrentMode() alias has been deprecated, ' + 'and will be removed in React 18+.');\n }\n }\n\n return false;\n}\nfunction isContextConsumer(object) {\n return typeOf(object) === REACT_CONTEXT_TYPE;\n}\nfunction isContextProvider(object) {\n return typeOf(object) === REACT_PROVIDER_TYPE;\n}\nfunction isElement(object) {\n return typeof object === 'object' && object !== null && object.$$typeof === REACT_ELEMENT_TYPE;\n}\nfunction isForwardRef(object) {\n return typeOf(object) === REACT_FORWARD_REF_TYPE;\n}\nfunction isFragment(object) {\n return typeOf(object) === REACT_FRAGMENT_TYPE;\n}\nfunction isLazy(object) {\n return typeOf(object) === REACT_LAZY_TYPE;\n}\nfunction isMemo(object) {\n return typeOf(object) === REACT_MEMO_TYPE;\n}\nfunction isPortal(object) {\n return typeOf(object) === REACT_PORTAL_TYPE;\n}\nfunction isProfiler(object) {\n return typeOf(object) === REACT_PROFILER_TYPE;\n}\nfunction isStrictMode(object) {\n return typeOf(object) === REACT_STRICT_MODE_TYPE;\n}\nfunction isSuspense(object) {\n return typeOf(object) === REACT_SUSPENSE_TYPE;\n}\nfunction isSuspenseList(object) {\n return typeOf(object) === REACT_SUSPENSE_LIST_TYPE;\n}\n\nexports.ContextConsumer = ContextConsumer;\nexports.ContextProvider = ContextProvider;\nexports.Element = Element;\nexports.ForwardRef = ForwardRef;\nexports.Fragment = Fragment;\nexports.Lazy = Lazy;\nexports.Memo = Memo;\nexports.Portal = Portal;\nexports.Profiler = Profiler;\nexports.StrictMode = StrictMode;\nexports.Suspense = Suspense;\nexports.SuspenseList = SuspenseList;\nexports.isAsyncMode = isAsyncMode;\nexports.isConcurrentMode = isConcurrentMode;\nexports.isContextConsumer = isContextConsumer;\nexports.isContextProvider = isContextProvider;\nexports.isElement = isElement;\nexports.isForwardRef = isForwardRef;\nexports.isFragment = isFragment;\nexports.isLazy = isLazy;\nexports.isMemo = isMemo;\nexports.isPortal = isPortal;\nexports.isProfiler = isProfiler;\nexports.isStrictMode = isStrictMode;\nexports.isSuspense = isSuspense;\nexports.isSuspenseList = isSuspenseList;\nexports.isValidElementType = isValidElementType;\nexports.typeOf = typeOf;\n })();\n}\n","'use strict';\n\nif (process.env.NODE_ENV === 'production') {\n module.exports = require('./cjs/react-is.production.min.js');\n} else {\n module.exports = require('./cjs/react-is.development.js');\n}\n","import { ForwardRef, Memo } from 'react-is';\n\n// Simplified polyfill for IE11 support\n// https://github.com/JamesMGreene/Function.name/blob/58b314d4a983110c3682f1228f845d39ccca1817/Function.name.js#L3\nconst fnNameMatchRegex = /^\\s*function(?:\\s|\\s*\\/\\*.*\\*\\/\\s*)+([^(\\s/]*)\\s*/;\nexport function getFunctionName(fn) {\n const match = `${fn}`.match(fnNameMatchRegex);\n const name = match && match[1];\n return name || '';\n}\nfunction getFunctionComponentName(Component, fallback = '') {\n return Component.displayName || Component.name || getFunctionName(Component) || fallback;\n}\nfunction getWrappedName(outerType, innerType, wrapperName) {\n const functionName = getFunctionComponentName(innerType);\n return outerType.displayName || (functionName !== '' ? `${wrapperName}(${functionName})` : wrapperName);\n}\n\n/**\n * cherry-pick from\n * https://github.com/facebook/react/blob/769b1f270e1251d9dbdce0fcbd9e92e502d059b8/packages/shared/getComponentName.js\n * originally forked from recompose/getDisplayName with added IE11 support\n */\nexport default function getDisplayName(Component) {\n if (Component == null) {\n return undefined;\n }\n if (typeof Component === 'string') {\n return Component;\n }\n if (typeof Component === 'function') {\n return getFunctionComponentName(Component, 'Component');\n }\n\n // TypeScript can't have components as objects but they exist in the form of `memo` or `Suspense`\n if (typeof Component === 'object') {\n switch (Component.$$typeof) {\n case ForwardRef:\n return getWrappedName(Component, Component.render, 'ForwardRef');\n case Memo:\n return getWrappedName(Component, Component.type, 'memo');\n default:\n return undefined;\n }\n }\n return undefined;\n}","export default function HTMLElementType(props, propName, componentName, location, propFullName) {\n if (process.env.NODE_ENV === 'production') {\n return null;\n }\n const propValue = props[propName];\n const safePropName = propFullName || propName;\n if (propValue == null) {\n return null;\n }\n if (propValue && propValue.nodeType !== 1) {\n return new Error(`Invalid ${location} \\`${safePropName}\\` supplied to \\`${componentName}\\`. ` + `Expected an HTMLElement.`);\n }\n return null;\n}","import PropTypes from 'prop-types';\nconst refType = PropTypes.oneOfType([PropTypes.func, PropTypes.object]);\nexport default refType;","import _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\n// It should to be noted that this function isn't equivalent to `text-transform: capitalize`.\n//\n// A strict capitalization should uppercase the first letter of each word in the sentence.\n// We only handle the first word.\nexport default function capitalize(string) {\n if (typeof string !== 'string') {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: \\`capitalize(string)\\` expects a string argument.` : _formatMuiErrorMessage(7));\n }\n return string.charAt(0).toUpperCase() + string.slice(1);\n}","/**\n * Safe chained function.\n *\n * Will only create a new function if needed,\n * otherwise will pass back existing functions or null.\n */\nexport default function createChainedFunction(...funcs) {\n return funcs.reduce((acc, func) => {\n if (func == null) {\n return acc;\n }\n return function chainedFunction(...args) {\n acc.apply(this, args);\n func.apply(this, args);\n };\n }, () => {});\n}","// Corresponds to 10 frames at 60 Hz.\n// A few bytes payload overhead when lodash/debounce is ~3 kB and debounce ~300 B.\nexport default function debounce(func, wait = 166) {\n let timeout;\n function debounced(...args) {\n const later = () => {\n // @ts-ignore\n func.apply(this, args);\n };\n clearTimeout(timeout);\n timeout = setTimeout(later, wait);\n }\n debounced.clear = () => {\n clearTimeout(timeout);\n };\n return debounced;\n}","export default function deprecatedPropType(validator, reason) {\n if (process.env.NODE_ENV === 'production') {\n return () => null;\n }\n return (props, propName, componentName, location, propFullName) => {\n const componentNameSafe = componentName || '<>';\n const propFullNameSafe = propFullName || propName;\n if (typeof props[propName] !== 'undefined') {\n return new Error(`The ${location} \\`${propFullNameSafe}\\` of ` + `\\`${componentNameSafe}\\` is deprecated. ${reason}`);\n }\n return null;\n };\n}","import * as React from 'react';\nexport default function isMuiElement(element, muiNames) {\n var _muiName, _element$type;\n return /*#__PURE__*/React.isValidElement(element) && muiNames.indexOf( // For server components `muiName` is avaialble in element.type._payload.value.muiName\n // relevant info - https://github.com/facebook/react/blob/2807d781a08db8e9873687fccc25c0f12b4fb3d4/packages/react/src/ReactLazy.js#L45\n // eslint-disable-next-line no-underscore-dangle\n (_muiName = element.type.muiName) != null ? _muiName : (_element$type = element.type) == null || (_element$type = _element$type._payload) == null || (_element$type = _element$type.value) == null ? void 0 : _element$type.muiName) !== -1;\n}","export default function ownerDocument(node) {\n return node && node.ownerDocument || document;\n}","import ownerDocument from '../ownerDocument';\nexport default function ownerWindow(node) {\n const doc = ownerDocument(node);\n return doc.defaultView || window;\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nexport default function requirePropFactory(componentNameInError, Component) {\n if (process.env.NODE_ENV === 'production') {\n return () => null;\n }\n\n // eslint-disable-next-line react/forbid-foreign-prop-types\n const prevPropTypes = Component ? _extends({}, Component.propTypes) : null;\n const requireProp = requiredProp => (props, propName, componentName, location, propFullName, ...args) => {\n const propFullNameSafe = propFullName || propName;\n const defaultTypeChecker = prevPropTypes == null ? void 0 : prevPropTypes[propFullNameSafe];\n if (defaultTypeChecker) {\n const typeCheckerResult = defaultTypeChecker(props, propName, componentName, location, propFullName, ...args);\n if (typeCheckerResult) {\n return typeCheckerResult;\n }\n }\n if (typeof props[propName] !== 'undefined' && !props[requiredProp]) {\n return new Error(`The prop \\`${propFullNameSafe}\\` of ` + `\\`${componentNameInError}\\` can only be used together with the \\`${requiredProp}\\` prop.`);\n }\n return null;\n };\n return requireProp;\n}","/**\n * TODO v5: consider making it private\n *\n * passes {value} to {ref}\n *\n * WARNING: Be sure to only call this inside a callback that is passed as a ref.\n * Otherwise, make sure to cleanup the previous {ref} if it changes. See\n * https://github.com/mui/material-ui/issues/13539\n *\n * Useful if you want to expose the ref of an inner component to the public API\n * while still using it inside the component.\n * @param ref A ref callback or ref object. If anything falsy, this is a no-op.\n */\nexport default function setRef(ref, value) {\n if (typeof ref === 'function') {\n ref(value);\n } else if (ref) {\n ref.current = value;\n }\n}","'use client';\n\nimport * as React from 'react';\n\n/**\n * A version of `React.useLayoutEffect` that does not show a warning when server-side rendering.\n * This is useful for effects that are only needed for client-side rendering but not for SSR.\n *\n * Before you use this hook, make sure to read https://gist.github.com/gaearon/e7d97cdf38a2907924ea12e4ebdf3c85\n * and confirm it doesn't apply to your use-case.\n */\nconst useEnhancedEffect = typeof window !== 'undefined' ? React.useLayoutEffect : React.useEffect;\nexport default useEnhancedEffect;","'use client';\n\nimport * as React from 'react';\nlet globalId = 0;\nfunction useGlobalId(idOverride) {\n const [defaultId, setDefaultId] = React.useState(idOverride);\n const id = idOverride || defaultId;\n React.useEffect(() => {\n if (defaultId == null) {\n // Fallback to this default id when possible.\n // Use the incrementing value for client-side rendering only.\n // We can't use it server-side.\n // If you want to use random values please consider the Birthday Problem: https://en.wikipedia.org/wiki/Birthday_problem\n globalId += 1;\n setDefaultId(`mui-${globalId}`);\n }\n }, [defaultId]);\n return id;\n}\n\n// downstream bundlers may remove unnecessary concatenation, but won't remove toString call -- Workaround for https://github.com/webpack/webpack/issues/14814\nconst maybeReactUseId = React['useId'.toString()];\n/**\n *\n * @example
    \n * @param idOverride\n * @returns {string}\n */\nexport default function useId(idOverride) {\n if (maybeReactUseId !== undefined) {\n const reactId = maybeReactUseId();\n return idOverride != null ? idOverride : reactId;\n }\n // eslint-disable-next-line react-hooks/rules-of-hooks -- `React.useId` is invariant at runtime.\n return useGlobalId(idOverride);\n}","export default function unsupportedProp(props, propName, componentName, location, propFullName) {\n if (process.env.NODE_ENV === 'production') {\n return null;\n }\n const propFullNameSafe = propFullName || propName;\n if (typeof props[propName] !== 'undefined') {\n return new Error(`The prop \\`${propFullNameSafe}\\` is not supported. Please remove it.`);\n }\n return null;\n}","'use client';\n\n/* eslint-disable react-hooks/rules-of-hooks, react-hooks/exhaustive-deps */\nimport * as React from 'react';\nexport default function useControlled({\n controlled,\n default: defaultProp,\n name,\n state = 'value'\n}) {\n // isControlled is ignored in the hook dependency lists as it should never change.\n const {\n current: isControlled\n } = React.useRef(controlled !== undefined);\n const [valueState, setValue] = React.useState(defaultProp);\n const value = isControlled ? controlled : valueState;\n if (process.env.NODE_ENV !== 'production') {\n React.useEffect(() => {\n if (isControlled !== (controlled !== undefined)) {\n console.error([`MUI: A component is changing the ${isControlled ? '' : 'un'}controlled ${state} state of ${name} to be ${isControlled ? 'un' : ''}controlled.`, 'Elements should not switch from uncontrolled to controlled (or vice versa).', `Decide between using a controlled or uncontrolled ${name} ` + 'element for the lifetime of the component.', \"The nature of the state is determined during the first render. It's considered controlled if the value is not `undefined`.\", 'More info: https://fb.me/react-controlled-components'].join('\\n'));\n }\n }, [state, name, controlled]);\n const {\n current: defaultValue\n } = React.useRef(defaultProp);\n React.useEffect(() => {\n if (!isControlled && defaultValue !== defaultProp) {\n console.error([`MUI: A component is changing the default ${state} state of an uncontrolled ${name} after being initialized. ` + `To suppress this warning opt to use a controlled ${name}.`].join('\\n'));\n }\n }, [JSON.stringify(defaultProp)]);\n }\n const setValueIfUncontrolled = React.useCallback(newValue => {\n if (!isControlled) {\n setValue(newValue);\n }\n }, []);\n return [value, setValueIfUncontrolled];\n}","'use client';\n\nimport * as React from 'react';\nimport useEnhancedEffect from '../useEnhancedEffect';\n\n/**\n * Inspired by https://github.com/facebook/react/issues/14099#issuecomment-440013892\n * See RFC in https://github.com/reactjs/rfcs/pull/220\n */\n\nfunction useEventCallback(fn) {\n const ref = React.useRef(fn);\n useEnhancedEffect(() => {\n ref.current = fn;\n });\n return React.useRef((...args) =>\n // @ts-expect-error hide `this`\n (0, ref.current)(...args)).current;\n}\nexport default useEventCallback;","'use client';\n\nimport * as React from 'react';\nimport setRef from '../setRef';\nexport default function useForkRef(...refs) {\n /**\n * This will create a new function if the refs passed to this hook change and are all defined.\n * This means react will call the old forkRef with `null` and the new forkRef\n * with the ref. Cleanup naturally emerges from this behavior.\n */\n return React.useMemo(() => {\n if (refs.every(ref => ref == null)) {\n return null;\n }\n return instance => {\n refs.forEach(ref => {\n setRef(ref, instance);\n });\n };\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, refs);\n}","'use client';\n\nimport * as React from 'react';\nconst UNINITIALIZED = {};\n\n/**\n * A React.useRef() that is initialized lazily with a function. Note that it accepts an optional\n * initialization argument, so the initialization function doesn't need to be an inline closure.\n *\n * @usage\n * const ref = useLazyRef(sortColumns, columns)\n */\nexport default function useLazyRef(init, initArg) {\n const ref = React.useRef(UNINITIALIZED);\n if (ref.current === UNINITIALIZED) {\n ref.current = init(initArg);\n }\n return ref;\n}","'use client';\n\nimport * as React from 'react';\nconst EMPTY = [];\n\n/**\n * A React.useEffect equivalent that runs once, when the component is mounted.\n */\nexport default function useOnMount(fn) {\n /* eslint-disable react-hooks/exhaustive-deps */\n React.useEffect(fn, EMPTY);\n /* eslint-enable react-hooks/exhaustive-deps */\n}","'use client';\n\nimport useLazyRef from '../useLazyRef/useLazyRef';\nimport useOnMount from '../useOnMount/useOnMount';\nexport class Timeout {\n constructor() {\n this.currentId = null;\n this.clear = () => {\n if (this.currentId !== null) {\n clearTimeout(this.currentId);\n this.currentId = null;\n }\n };\n this.disposeEffect = () => {\n return this.clear;\n };\n }\n static create() {\n return new Timeout();\n }\n /**\n * Executes `fn` after `delay`, clearing any previously scheduled call.\n */\n start(delay, fn) {\n this.clear();\n this.currentId = setTimeout(() => {\n this.currentId = null;\n fn();\n }, delay);\n }\n}\nexport default function useTimeout() {\n const timeout = useLazyRef(Timeout.create).current;\n useOnMount(timeout.disposeEffect);\n return timeout;\n}","'use client';\n\n// based on https://github.com/WICG/focus-visible/blob/v4.1.5/src/focus-visible.js\nimport * as React from 'react';\nimport { Timeout } from '../useTimeout/useTimeout';\nlet hadKeyboardEvent = true;\nlet hadFocusVisibleRecently = false;\nconst hadFocusVisibleRecentlyTimeout = new Timeout();\nconst inputTypesWhitelist = {\n text: true,\n search: true,\n url: true,\n tel: true,\n email: true,\n password: true,\n number: true,\n date: true,\n month: true,\n week: true,\n time: true,\n datetime: true,\n 'datetime-local': true\n};\n\n/**\n * Computes whether the given element should automatically trigger the\n * `focus-visible` class being added, i.e. whether it should always match\n * `:focus-visible` when focused.\n * @param {Element} node\n * @returns {boolean}\n */\nfunction focusTriggersKeyboardModality(node) {\n const {\n type,\n tagName\n } = node;\n if (tagName === 'INPUT' && inputTypesWhitelist[type] && !node.readOnly) {\n return true;\n }\n if (tagName === 'TEXTAREA' && !node.readOnly) {\n return true;\n }\n if (node.isContentEditable) {\n return true;\n }\n return false;\n}\n\n/**\n * Keep track of our keyboard modality state with `hadKeyboardEvent`.\n * If the most recent user interaction was via the keyboard;\n * and the key press did not include a meta, alt/option, or control key;\n * then the modality is keyboard. Otherwise, the modality is not keyboard.\n * @param {KeyboardEvent} event\n */\nfunction handleKeyDown(event) {\n if (event.metaKey || event.altKey || event.ctrlKey) {\n return;\n }\n hadKeyboardEvent = true;\n}\n\n/**\n * If at any point a user clicks with a pointing device, ensure that we change\n * the modality away from keyboard.\n * This avoids the situation where a user presses a key on an already focused\n * element, and then clicks on a different element, focusing it with a\n * pointing device, while we still think we're in keyboard modality.\n */\nfunction handlePointerDown() {\n hadKeyboardEvent = false;\n}\nfunction handleVisibilityChange() {\n if (this.visibilityState === 'hidden') {\n // If the tab becomes active again, the browser will handle calling focus\n // on the element (Safari actually calls it twice).\n // If this tab change caused a blur on an element with focus-visible,\n // re-apply the class when the user switches back to the tab.\n if (hadFocusVisibleRecently) {\n hadKeyboardEvent = true;\n }\n }\n}\nfunction prepare(doc) {\n doc.addEventListener('keydown', handleKeyDown, true);\n doc.addEventListener('mousedown', handlePointerDown, true);\n doc.addEventListener('pointerdown', handlePointerDown, true);\n doc.addEventListener('touchstart', handlePointerDown, true);\n doc.addEventListener('visibilitychange', handleVisibilityChange, true);\n}\nexport function teardown(doc) {\n doc.removeEventListener('keydown', handleKeyDown, true);\n doc.removeEventListener('mousedown', handlePointerDown, true);\n doc.removeEventListener('pointerdown', handlePointerDown, true);\n doc.removeEventListener('touchstart', handlePointerDown, true);\n doc.removeEventListener('visibilitychange', handleVisibilityChange, true);\n}\nfunction isFocusVisible(event) {\n const {\n target\n } = event;\n try {\n return target.matches(':focus-visible');\n } catch (error) {\n // Browsers not implementing :focus-visible will throw a SyntaxError.\n // We use our own heuristic for those browsers.\n // Rethrow might be better if it's not the expected error but do we really\n // want to crash if focus-visible malfunctioned?\n }\n\n // No need for validFocusTarget check. The user does that by attaching it to\n // focusable events only.\n return hadKeyboardEvent || focusTriggersKeyboardModality(target);\n}\nexport default function useIsFocusVisible() {\n const ref = React.useCallback(node => {\n if (node != null) {\n prepare(node.ownerDocument);\n }\n }, []);\n const isFocusVisibleRef = React.useRef(false);\n\n /**\n * Should be called if a blur event is fired\n */\n function handleBlurVisible() {\n // checking against potential state variable does not suffice if we focus and blur synchronously.\n // React wouldn't have time to trigger a re-render so `focusVisible` would be stale.\n // Ideally we would adjust `isFocusVisible(event)` to look at `relatedTarget` for blur events.\n // This doesn't work in IE11 due to https://github.com/facebook/react/issues/3751\n // TODO: check again if React releases their internal changes to focus event handling (https://github.com/facebook/react/pull/19186).\n if (isFocusVisibleRef.current) {\n // To detect a tab/window switch, we look for a blur event followed\n // rapidly by a visibility change.\n // If we don't see a visibility change within 100ms, it's probably a\n // regular focus change.\n hadFocusVisibleRecently = true;\n hadFocusVisibleRecentlyTimeout.start(100, () => {\n hadFocusVisibleRecently = false;\n });\n isFocusVisibleRef.current = false;\n return true;\n }\n return false;\n }\n\n /**\n * Should be called if a blur event is fired\n */\n function handleFocusVisible(event) {\n if (isFocusVisible(event)) {\n isFocusVisibleRef.current = true;\n return true;\n }\n return false;\n }\n return {\n isFocusVisibleRef,\n onFocus: handleFocusVisible,\n onBlur: handleBlurVisible,\n ref\n };\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\n/**\n * Add keys, values of `defaultProps` that does not exist in `props`\n * @param {object} defaultProps\n * @param {object} props\n * @returns {object} resolved props\n */\nexport default function resolveProps(defaultProps, props) {\n const output = _extends({}, props);\n Object.keys(defaultProps).forEach(propName => {\n if (propName.toString().match(/^(components|slots)$/)) {\n output[propName] = _extends({}, defaultProps[propName], output[propName]);\n } else if (propName.toString().match(/^(componentsProps|slotProps)$/)) {\n const defaultSlotProps = defaultProps[propName] || {};\n const slotProps = props[propName];\n output[propName] = {};\n if (!slotProps || !Object.keys(slotProps)) {\n // Reduce the iteration if the slot props is empty\n output[propName] = defaultSlotProps;\n } else if (!defaultSlotProps || !Object.keys(defaultSlotProps)) {\n // Reduce the iteration if the default slot props is empty\n output[propName] = slotProps;\n } else {\n output[propName] = _extends({}, slotProps);\n Object.keys(defaultSlotProps).forEach(slotPropName => {\n output[propName][slotPropName] = resolveProps(defaultSlotProps[slotPropName], slotProps[slotPropName]);\n });\n }\n } else if (output[propName] === undefined) {\n output[propName] = defaultProps[propName];\n }\n });\n return output;\n}","export default function composeClasses(slots, getUtilityClass, classes = undefined) {\n const output = {};\n Object.keys(slots).forEach(\n // `Object.keys(slots)` can't be wider than `T` because we infer `T` from `slots`.\n // @ts-expect-error https://github.com/microsoft/TypeScript/pull/12253#issuecomment-263132208\n slot => {\n output[slot] = slots[slot].reduce((acc, key) => {\n if (key) {\n const utilityClass = getUtilityClass(key);\n if (utilityClass !== '') {\n acc.push(utilityClass);\n }\n if (classes && classes[key]) {\n acc.push(classes[key]);\n }\n }\n return acc;\n }, []).join(' ');\n });\n return output;\n}","const defaultGenerator = componentName => componentName;\nconst createClassNameGenerator = () => {\n let generate = defaultGenerator;\n return {\n configure(generator) {\n generate = generator;\n },\n generate(componentName) {\n return generate(componentName);\n },\n reset() {\n generate = defaultGenerator;\n }\n };\n};\nconst ClassNameGenerator = createClassNameGenerator();\nexport default ClassNameGenerator;","import ClassNameGenerator from '../ClassNameGenerator';\nexport const globalStateClasses = {\n active: 'active',\n checked: 'checked',\n completed: 'completed',\n disabled: 'disabled',\n error: 'error',\n expanded: 'expanded',\n focused: 'focused',\n focusVisible: 'focusVisible',\n open: 'open',\n readOnly: 'readOnly',\n required: 'required',\n selected: 'selected'\n};\nexport default function generateUtilityClass(componentName, slot, globalStatePrefix = 'Mui') {\n const globalStateClass = globalStateClasses[slot];\n return globalStateClass ? `${globalStatePrefix}-${globalStateClass}` : `${ClassNameGenerator.generate(componentName)}-${slot}`;\n}\nexport function isGlobalState(slot) {\n return globalStateClasses[slot] !== undefined;\n}","import generateUtilityClass from '../generateUtilityClass';\nexport default function generateUtilityClasses(componentName, slots, globalStatePrefix = 'Mui') {\n const result = {};\n slots.forEach(slot => {\n result[slot] = generateUtilityClass(componentName, slot, globalStatePrefix);\n });\n return result;\n}","function clamp(val, min = Number.MIN_SAFE_INTEGER, max = Number.MAX_SAFE_INTEGER) {\n return Math.max(min, Math.min(val, max));\n}\nexport default clamp;","export default function _objectWithoutPropertiesLoose(source, excluded) {\n if (source == null) return {};\n var target = {};\n var sourceKeys = Object.keys(source);\n var key, i;\n for (i = 0; i < sourceKeys.length; i++) {\n key = sourceKeys[i];\n if (excluded.indexOf(key) >= 0) continue;\n target[key] = source[key];\n }\n return target;\n}","import _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nconst _excluded = [\"values\", \"unit\", \"step\"];\n// Sorted ASC by size. That's important.\n// It can't be configured as it's used statically for propTypes.\nexport const breakpointKeys = ['xs', 'sm', 'md', 'lg', 'xl'];\nconst sortBreakpointsValues = values => {\n const breakpointsAsArray = Object.keys(values).map(key => ({\n key,\n val: values[key]\n })) || [];\n // Sort in ascending order\n breakpointsAsArray.sort((breakpoint1, breakpoint2) => breakpoint1.val - breakpoint2.val);\n return breakpointsAsArray.reduce((acc, obj) => {\n return _extends({}, acc, {\n [obj.key]: obj.val\n });\n }, {});\n};\n\n// Keep in mind that @media is inclusive by the CSS specification.\nexport default function createBreakpoints(breakpoints) {\n const {\n // The breakpoint **start** at this value.\n // For instance with the first breakpoint xs: [xs, sm).\n values = {\n xs: 0,\n // phone\n sm: 600,\n // tablet\n md: 900,\n // small laptop\n lg: 1200,\n // desktop\n xl: 1536 // large screen\n },\n unit = 'px',\n step = 5\n } = breakpoints,\n other = _objectWithoutPropertiesLoose(breakpoints, _excluded);\n const sortedValues = sortBreakpointsValues(values);\n const keys = Object.keys(sortedValues);\n function up(key) {\n const value = typeof values[key] === 'number' ? values[key] : key;\n return `@media (min-width:${value}${unit})`;\n }\n function down(key) {\n const value = typeof values[key] === 'number' ? values[key] : key;\n return `@media (max-width:${value - step / 100}${unit})`;\n }\n function between(start, end) {\n const endIndex = keys.indexOf(end);\n return `@media (min-width:${typeof values[start] === 'number' ? values[start] : start}${unit}) and ` + `(max-width:${(endIndex !== -1 && typeof values[keys[endIndex]] === 'number' ? values[keys[endIndex]] : end) - step / 100}${unit})`;\n }\n function only(key) {\n if (keys.indexOf(key) + 1 < keys.length) {\n return between(key, keys[keys.indexOf(key) + 1]);\n }\n return up(key);\n }\n function not(key) {\n // handle first and last key separately, for better readability\n const keyIndex = keys.indexOf(key);\n if (keyIndex === 0) {\n return up(keys[1]);\n }\n if (keyIndex === keys.length - 1) {\n return down(keys[keyIndex]);\n }\n return between(key, keys[keys.indexOf(key) + 1]).replace('@media', '@media not all and');\n }\n return _extends({\n keys,\n values: sortedValues,\n up,\n down,\n between,\n only,\n not,\n unit\n }, other);\n}","const shape = {\n borderRadius: 4\n};\nexport default shape;","import PropTypes from 'prop-types';\nconst responsivePropType = process.env.NODE_ENV !== 'production' ? PropTypes.oneOfType([PropTypes.number, PropTypes.string, PropTypes.object, PropTypes.array]) : {};\nexport default responsivePropType;","import deepmerge from '@mui/utils/deepmerge';\nfunction merge(acc, item) {\n if (!item) {\n return acc;\n }\n return deepmerge(acc, item, {\n clone: false // No need to clone deep, it's way faster.\n });\n}\nexport default merge;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport PropTypes from 'prop-types';\nimport deepmerge from '@mui/utils/deepmerge';\nimport merge from './merge';\n\n// The breakpoint **start** at this value.\n// For instance with the first breakpoint xs: [xs, sm[.\nexport const values = {\n xs: 0,\n // phone\n sm: 600,\n // tablet\n md: 900,\n // small laptop\n lg: 1200,\n // desktop\n xl: 1536 // large screen\n};\nconst defaultBreakpoints = {\n // Sorted ASC by size. That's important.\n // It can't be configured as it's used statically for propTypes.\n keys: ['xs', 'sm', 'md', 'lg', 'xl'],\n up: key => `@media (min-width:${values[key]}px)`\n};\nexport function handleBreakpoints(props, propValue, styleFromPropValue) {\n const theme = props.theme || {};\n if (Array.isArray(propValue)) {\n const themeBreakpoints = theme.breakpoints || defaultBreakpoints;\n return propValue.reduce((acc, item, index) => {\n acc[themeBreakpoints.up(themeBreakpoints.keys[index])] = styleFromPropValue(propValue[index]);\n return acc;\n }, {});\n }\n if (typeof propValue === 'object') {\n const themeBreakpoints = theme.breakpoints || defaultBreakpoints;\n return Object.keys(propValue).reduce((acc, breakpoint) => {\n // key is breakpoint\n if (Object.keys(themeBreakpoints.values || values).indexOf(breakpoint) !== -1) {\n const mediaKey = themeBreakpoints.up(breakpoint);\n acc[mediaKey] = styleFromPropValue(propValue[breakpoint], breakpoint);\n } else {\n const cssKey = breakpoint;\n acc[cssKey] = propValue[cssKey];\n }\n return acc;\n }, {});\n }\n const output = styleFromPropValue(propValue);\n return output;\n}\nfunction breakpoints(styleFunction) {\n // false positive\n // eslint-disable-next-line react/function-component-definition\n const newStyleFunction = props => {\n const theme = props.theme || {};\n const base = styleFunction(props);\n const themeBreakpoints = theme.breakpoints || defaultBreakpoints;\n const extended = themeBreakpoints.keys.reduce((acc, key) => {\n if (props[key]) {\n acc = acc || {};\n acc[themeBreakpoints.up(key)] = styleFunction(_extends({\n theme\n }, props[key]));\n }\n return acc;\n }, null);\n return merge(base, extended);\n };\n newStyleFunction.propTypes = process.env.NODE_ENV !== 'production' ? _extends({}, styleFunction.propTypes, {\n xs: PropTypes.object,\n sm: PropTypes.object,\n md: PropTypes.object,\n lg: PropTypes.object,\n xl: PropTypes.object\n }) : {};\n newStyleFunction.filterProps = ['xs', 'sm', 'md', 'lg', 'xl', ...styleFunction.filterProps];\n return newStyleFunction;\n}\nexport function createEmptyBreakpointObject(breakpointsInput = {}) {\n var _breakpointsInput$key;\n const breakpointsInOrder = (_breakpointsInput$key = breakpointsInput.keys) == null ? void 0 : _breakpointsInput$key.reduce((acc, key) => {\n const breakpointStyleKey = breakpointsInput.up(key);\n acc[breakpointStyleKey] = {};\n return acc;\n }, {});\n return breakpointsInOrder || {};\n}\nexport function removeUnusedBreakpoints(breakpointKeys, style) {\n return breakpointKeys.reduce((acc, key) => {\n const breakpointOutput = acc[key];\n const isBreakpointUnused = !breakpointOutput || Object.keys(breakpointOutput).length === 0;\n if (isBreakpointUnused) {\n delete acc[key];\n }\n return acc;\n }, style);\n}\nexport function mergeBreakpointsInOrder(breakpointsInput, ...styles) {\n const emptyBreakpoints = createEmptyBreakpointObject(breakpointsInput);\n const mergedOutput = [emptyBreakpoints, ...styles].reduce((prev, next) => deepmerge(prev, next), {});\n return removeUnusedBreakpoints(Object.keys(emptyBreakpoints), mergedOutput);\n}\n\n// compute base for responsive values; e.g.,\n// [1,2,3] => {xs: true, sm: true, md: true}\n// {xs: 1, sm: 2, md: 3} => {xs: true, sm: true, md: true}\nexport function computeBreakpointsBase(breakpointValues, themeBreakpoints) {\n // fixed value\n if (typeof breakpointValues !== 'object') {\n return {};\n }\n const base = {};\n const breakpointsKeys = Object.keys(themeBreakpoints);\n if (Array.isArray(breakpointValues)) {\n breakpointsKeys.forEach((breakpoint, i) => {\n if (i < breakpointValues.length) {\n base[breakpoint] = true;\n }\n });\n } else {\n breakpointsKeys.forEach(breakpoint => {\n if (breakpointValues[breakpoint] != null) {\n base[breakpoint] = true;\n }\n });\n }\n return base;\n}\nexport function resolveBreakpointValues({\n values: breakpointValues,\n breakpoints: themeBreakpoints,\n base: customBase\n}) {\n const base = customBase || computeBreakpointsBase(breakpointValues, themeBreakpoints);\n const keys = Object.keys(base);\n if (keys.length === 0) {\n return breakpointValues;\n }\n let previous;\n return keys.reduce((acc, breakpoint, i) => {\n if (Array.isArray(breakpointValues)) {\n acc[breakpoint] = breakpointValues[i] != null ? breakpointValues[i] : breakpointValues[previous];\n previous = i;\n } else if (typeof breakpointValues === 'object') {\n acc[breakpoint] = breakpointValues[breakpoint] != null ? breakpointValues[breakpoint] : breakpointValues[previous];\n previous = breakpoint;\n } else {\n acc[breakpoint] = breakpointValues;\n }\n return acc;\n }, {});\n}\nexport default breakpoints;","import capitalize from '@mui/utils/capitalize';\nimport responsivePropType from './responsivePropType';\nimport { handleBreakpoints } from './breakpoints';\nexport function getPath(obj, path, checkVars = true) {\n if (!path || typeof path !== 'string') {\n return null;\n }\n\n // Check if CSS variables are used\n if (obj && obj.vars && checkVars) {\n const val = `vars.${path}`.split('.').reduce((acc, item) => acc && acc[item] ? acc[item] : null, obj);\n if (val != null) {\n return val;\n }\n }\n return path.split('.').reduce((acc, item) => {\n if (acc && acc[item] != null) {\n return acc[item];\n }\n return null;\n }, obj);\n}\nexport function getStyleValue(themeMapping, transform, propValueFinal, userValue = propValueFinal) {\n let value;\n if (typeof themeMapping === 'function') {\n value = themeMapping(propValueFinal);\n } else if (Array.isArray(themeMapping)) {\n value = themeMapping[propValueFinal] || userValue;\n } else {\n value = getPath(themeMapping, propValueFinal) || userValue;\n }\n if (transform) {\n value = transform(value, userValue, themeMapping);\n }\n return value;\n}\nfunction style(options) {\n const {\n prop,\n cssProperty = options.prop,\n themeKey,\n transform\n } = options;\n\n // false positive\n // eslint-disable-next-line react/function-component-definition\n const fn = props => {\n if (props[prop] == null) {\n return null;\n }\n const propValue = props[prop];\n const theme = props.theme;\n const themeMapping = getPath(theme, themeKey) || {};\n const styleFromPropValue = propValueFinal => {\n let value = getStyleValue(themeMapping, transform, propValueFinal);\n if (propValueFinal === value && typeof propValueFinal === 'string') {\n // Haven't found value\n value = getStyleValue(themeMapping, transform, `${prop}${propValueFinal === 'default' ? '' : capitalize(propValueFinal)}`, propValueFinal);\n }\n if (cssProperty === false) {\n return value;\n }\n return {\n [cssProperty]: value\n };\n };\n return handleBreakpoints(props, propValue, styleFromPropValue);\n };\n fn.propTypes = process.env.NODE_ENV !== 'production' ? {\n [prop]: responsivePropType\n } : {};\n fn.filterProps = [prop];\n return fn;\n}\nexport default style;","export default function memoize(fn) {\n const cache = {};\n return arg => {\n if (cache[arg] === undefined) {\n cache[arg] = fn(arg);\n }\n return cache[arg];\n };\n}","import responsivePropType from './responsivePropType';\nimport { handleBreakpoints } from './breakpoints';\nimport { getPath } from './style';\nimport merge from './merge';\nimport memoize from './memoize';\nconst properties = {\n m: 'margin',\n p: 'padding'\n};\nconst directions = {\n t: 'Top',\n r: 'Right',\n b: 'Bottom',\n l: 'Left',\n x: ['Left', 'Right'],\n y: ['Top', 'Bottom']\n};\nconst aliases = {\n marginX: 'mx',\n marginY: 'my',\n paddingX: 'px',\n paddingY: 'py'\n};\n\n// memoize() impact:\n// From 300,000 ops/sec\n// To 350,000 ops/sec\nconst getCssProperties = memoize(prop => {\n // It's not a shorthand notation.\n if (prop.length > 2) {\n if (aliases[prop]) {\n prop = aliases[prop];\n } else {\n return [prop];\n }\n }\n const [a, b] = prop.split('');\n const property = properties[a];\n const direction = directions[b] || '';\n return Array.isArray(direction) ? direction.map(dir => property + dir) : [property + direction];\n});\nexport const marginKeys = ['m', 'mt', 'mr', 'mb', 'ml', 'mx', 'my', 'margin', 'marginTop', 'marginRight', 'marginBottom', 'marginLeft', 'marginX', 'marginY', 'marginInline', 'marginInlineStart', 'marginInlineEnd', 'marginBlock', 'marginBlockStart', 'marginBlockEnd'];\nexport const paddingKeys = ['p', 'pt', 'pr', 'pb', 'pl', 'px', 'py', 'padding', 'paddingTop', 'paddingRight', 'paddingBottom', 'paddingLeft', 'paddingX', 'paddingY', 'paddingInline', 'paddingInlineStart', 'paddingInlineEnd', 'paddingBlock', 'paddingBlockStart', 'paddingBlockEnd'];\nconst spacingKeys = [...marginKeys, ...paddingKeys];\nexport function createUnaryUnit(theme, themeKey, defaultValue, propName) {\n var _getPath;\n const themeSpacing = (_getPath = getPath(theme, themeKey, false)) != null ? _getPath : defaultValue;\n if (typeof themeSpacing === 'number') {\n return abs => {\n if (typeof abs === 'string') {\n return abs;\n }\n if (process.env.NODE_ENV !== 'production') {\n if (typeof abs !== 'number') {\n console.error(`MUI: Expected ${propName} argument to be a number or a string, got ${abs}.`);\n }\n }\n return themeSpacing * abs;\n };\n }\n if (Array.isArray(themeSpacing)) {\n return abs => {\n if (typeof abs === 'string') {\n return abs;\n }\n if (process.env.NODE_ENV !== 'production') {\n if (!Number.isInteger(abs)) {\n console.error([`MUI: The \\`theme.${themeKey}\\` array type cannot be combined with non integer values.` + `You should either use an integer value that can be used as index, or define the \\`theme.${themeKey}\\` as a number.`].join('\\n'));\n } else if (abs > themeSpacing.length - 1) {\n console.error([`MUI: The value provided (${abs}) overflows.`, `The supported values are: ${JSON.stringify(themeSpacing)}.`, `${abs} > ${themeSpacing.length - 1}, you need to add the missing values.`].join('\\n'));\n }\n }\n return themeSpacing[abs];\n };\n }\n if (typeof themeSpacing === 'function') {\n return themeSpacing;\n }\n if (process.env.NODE_ENV !== 'production') {\n console.error([`MUI: The \\`theme.${themeKey}\\` value (${themeSpacing}) is invalid.`, 'It should be a number, an array or a function.'].join('\\n'));\n }\n return () => undefined;\n}\nexport function createUnarySpacing(theme) {\n return createUnaryUnit(theme, 'spacing', 8, 'spacing');\n}\nexport function getValue(transformer, propValue) {\n if (typeof propValue === 'string' || propValue == null) {\n return propValue;\n }\n const abs = Math.abs(propValue);\n const transformed = transformer(abs);\n if (propValue >= 0) {\n return transformed;\n }\n if (typeof transformed === 'number') {\n return -transformed;\n }\n return `-${transformed}`;\n}\nexport function getStyleFromPropValue(cssProperties, transformer) {\n return propValue => cssProperties.reduce((acc, cssProperty) => {\n acc[cssProperty] = getValue(transformer, propValue);\n return acc;\n }, {});\n}\nfunction resolveCssProperty(props, keys, prop, transformer) {\n // Using a hash computation over an array iteration could be faster, but with only 28 items,\n // it's doesn't worth the bundle size.\n if (keys.indexOf(prop) === -1) {\n return null;\n }\n const cssProperties = getCssProperties(prop);\n const styleFromPropValue = getStyleFromPropValue(cssProperties, transformer);\n const propValue = props[prop];\n return handleBreakpoints(props, propValue, styleFromPropValue);\n}\nfunction style(props, keys) {\n const transformer = createUnarySpacing(props.theme);\n return Object.keys(props).map(prop => resolveCssProperty(props, keys, prop, transformer)).reduce(merge, {});\n}\nexport function margin(props) {\n return style(props, marginKeys);\n}\nmargin.propTypes = process.env.NODE_ENV !== 'production' ? marginKeys.reduce((obj, key) => {\n obj[key] = responsivePropType;\n return obj;\n}, {}) : {};\nmargin.filterProps = marginKeys;\nexport function padding(props) {\n return style(props, paddingKeys);\n}\npadding.propTypes = process.env.NODE_ENV !== 'production' ? paddingKeys.reduce((obj, key) => {\n obj[key] = responsivePropType;\n return obj;\n}, {}) : {};\npadding.filterProps = paddingKeys;\nfunction spacing(props) {\n return style(props, spacingKeys);\n}\nspacing.propTypes = process.env.NODE_ENV !== 'production' ? spacingKeys.reduce((obj, key) => {\n obj[key] = responsivePropType;\n return obj;\n}, {}) : {};\nspacing.filterProps = spacingKeys;\nexport default spacing;","import { createUnarySpacing } from '../spacing';\n\n// The different signatures imply different meaning for their arguments that can't be expressed structurally.\n// We express the difference with variable names.\n\nexport default function createSpacing(spacingInput = 8) {\n // Already transformed.\n if (spacingInput.mui) {\n return spacingInput;\n }\n\n // Material Design layouts are visually balanced. Most measurements align to an 8dp grid, which aligns both spacing and the overall layout.\n // Smaller components, such as icons, can align to a 4dp grid.\n // https://m2.material.io/design/layout/understanding-layout.html\n const transform = createUnarySpacing({\n spacing: spacingInput\n });\n const spacing = (...argsInput) => {\n if (process.env.NODE_ENV !== 'production') {\n if (!(argsInput.length <= 4)) {\n console.error(`MUI: Too many arguments provided, expected between 0 and 4, got ${argsInput.length}`);\n }\n }\n const args = argsInput.length === 0 ? [1] : argsInput;\n return args.map(argument => {\n const output = transform(argument);\n return typeof output === 'number' ? `${output}px` : output;\n }).join(' ');\n };\n spacing.mui = true;\n return spacing;\n}","import merge from './merge';\nfunction compose(...styles) {\n const handlers = styles.reduce((acc, style) => {\n style.filterProps.forEach(prop => {\n acc[prop] = style;\n });\n return acc;\n }, {});\n\n // false positive\n // eslint-disable-next-line react/function-component-definition\n const fn = props => {\n return Object.keys(props).reduce((acc, prop) => {\n if (handlers[prop]) {\n return merge(acc, handlers[prop](props));\n }\n return acc;\n }, {});\n };\n fn.propTypes = process.env.NODE_ENV !== 'production' ? styles.reduce((acc, style) => Object.assign(acc, style.propTypes), {}) : {};\n fn.filterProps = styles.reduce((acc, style) => acc.concat(style.filterProps), []);\n return fn;\n}\nexport default compose;","import responsivePropType from './responsivePropType';\nimport style from './style';\nimport compose from './compose';\nimport { createUnaryUnit, getValue } from './spacing';\nimport { handleBreakpoints } from './breakpoints';\nexport function borderTransform(value) {\n if (typeof value !== 'number') {\n return value;\n }\n return `${value}px solid`;\n}\nfunction createBorderStyle(prop, transform) {\n return style({\n prop,\n themeKey: 'borders',\n transform\n });\n}\nexport const border = createBorderStyle('border', borderTransform);\nexport const borderTop = createBorderStyle('borderTop', borderTransform);\nexport const borderRight = createBorderStyle('borderRight', borderTransform);\nexport const borderBottom = createBorderStyle('borderBottom', borderTransform);\nexport const borderLeft = createBorderStyle('borderLeft', borderTransform);\nexport const borderColor = createBorderStyle('borderColor');\nexport const borderTopColor = createBorderStyle('borderTopColor');\nexport const borderRightColor = createBorderStyle('borderRightColor');\nexport const borderBottomColor = createBorderStyle('borderBottomColor');\nexport const borderLeftColor = createBorderStyle('borderLeftColor');\nexport const outline = createBorderStyle('outline', borderTransform);\nexport const outlineColor = createBorderStyle('outlineColor');\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const borderRadius = props => {\n if (props.borderRadius !== undefined && props.borderRadius !== null) {\n const transformer = createUnaryUnit(props.theme, 'shape.borderRadius', 4, 'borderRadius');\n const styleFromPropValue = propValue => ({\n borderRadius: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.borderRadius, styleFromPropValue);\n }\n return null;\n};\nborderRadius.propTypes = process.env.NODE_ENV !== 'production' ? {\n borderRadius: responsivePropType\n} : {};\nborderRadius.filterProps = ['borderRadius'];\nconst borders = compose(border, borderTop, borderRight, borderBottom, borderLeft, borderColor, borderTopColor, borderRightColor, borderBottomColor, borderLeftColor, borderRadius, outline, outlineColor);\nexport default borders;","import style from './style';\nimport compose from './compose';\nimport { createUnaryUnit, getValue } from './spacing';\nimport { handleBreakpoints } from './breakpoints';\nimport responsivePropType from './responsivePropType';\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const gap = props => {\n if (props.gap !== undefined && props.gap !== null) {\n const transformer = createUnaryUnit(props.theme, 'spacing', 8, 'gap');\n const styleFromPropValue = propValue => ({\n gap: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.gap, styleFromPropValue);\n }\n return null;\n};\ngap.propTypes = process.env.NODE_ENV !== 'production' ? {\n gap: responsivePropType\n} : {};\ngap.filterProps = ['gap'];\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const columnGap = props => {\n if (props.columnGap !== undefined && props.columnGap !== null) {\n const transformer = createUnaryUnit(props.theme, 'spacing', 8, 'columnGap');\n const styleFromPropValue = propValue => ({\n columnGap: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.columnGap, styleFromPropValue);\n }\n return null;\n};\ncolumnGap.propTypes = process.env.NODE_ENV !== 'production' ? {\n columnGap: responsivePropType\n} : {};\ncolumnGap.filterProps = ['columnGap'];\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const rowGap = props => {\n if (props.rowGap !== undefined && props.rowGap !== null) {\n const transformer = createUnaryUnit(props.theme, 'spacing', 8, 'rowGap');\n const styleFromPropValue = propValue => ({\n rowGap: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.rowGap, styleFromPropValue);\n }\n return null;\n};\nrowGap.propTypes = process.env.NODE_ENV !== 'production' ? {\n rowGap: responsivePropType\n} : {};\nrowGap.filterProps = ['rowGap'];\nexport const gridColumn = style({\n prop: 'gridColumn'\n});\nexport const gridRow = style({\n prop: 'gridRow'\n});\nexport const gridAutoFlow = style({\n prop: 'gridAutoFlow'\n});\nexport const gridAutoColumns = style({\n prop: 'gridAutoColumns'\n});\nexport const gridAutoRows = style({\n prop: 'gridAutoRows'\n});\nexport const gridTemplateColumns = style({\n prop: 'gridTemplateColumns'\n});\nexport const gridTemplateRows = style({\n prop: 'gridTemplateRows'\n});\nexport const gridTemplateAreas = style({\n prop: 'gridTemplateAreas'\n});\nexport const gridArea = style({\n prop: 'gridArea'\n});\nconst grid = compose(gap, columnGap, rowGap, gridColumn, gridRow, gridAutoFlow, gridAutoColumns, gridAutoRows, gridTemplateColumns, gridTemplateRows, gridTemplateAreas, gridArea);\nexport default grid;","import style from './style';\nimport compose from './compose';\nexport function paletteTransform(value, userValue) {\n if (userValue === 'grey') {\n return userValue;\n }\n return value;\n}\nexport const color = style({\n prop: 'color',\n themeKey: 'palette',\n transform: paletteTransform\n});\nexport const bgcolor = style({\n prop: 'bgcolor',\n cssProperty: 'backgroundColor',\n themeKey: 'palette',\n transform: paletteTransform\n});\nexport const backgroundColor = style({\n prop: 'backgroundColor',\n themeKey: 'palette',\n transform: paletteTransform\n});\nconst palette = compose(color, bgcolor, backgroundColor);\nexport default palette;","import style from './style';\nimport compose from './compose';\nimport { handleBreakpoints, values as breakpointsValues } from './breakpoints';\nexport function sizingTransform(value) {\n return value <= 1 && value !== 0 ? `${value * 100}%` : value;\n}\nexport const width = style({\n prop: 'width',\n transform: sizingTransform\n});\nexport const maxWidth = props => {\n if (props.maxWidth !== undefined && props.maxWidth !== null) {\n const styleFromPropValue = propValue => {\n var _props$theme, _props$theme2;\n const breakpoint = ((_props$theme = props.theme) == null || (_props$theme = _props$theme.breakpoints) == null || (_props$theme = _props$theme.values) == null ? void 0 : _props$theme[propValue]) || breakpointsValues[propValue];\n if (!breakpoint) {\n return {\n maxWidth: sizingTransform(propValue)\n };\n }\n if (((_props$theme2 = props.theme) == null || (_props$theme2 = _props$theme2.breakpoints) == null ? void 0 : _props$theme2.unit) !== 'px') {\n return {\n maxWidth: `${breakpoint}${props.theme.breakpoints.unit}`\n };\n }\n return {\n maxWidth: breakpoint\n };\n };\n return handleBreakpoints(props, props.maxWidth, styleFromPropValue);\n }\n return null;\n};\nmaxWidth.filterProps = ['maxWidth'];\nexport const minWidth = style({\n prop: 'minWidth',\n transform: sizingTransform\n});\nexport const height = style({\n prop: 'height',\n transform: sizingTransform\n});\nexport const maxHeight = style({\n prop: 'maxHeight',\n transform: sizingTransform\n});\nexport const minHeight = style({\n prop: 'minHeight',\n transform: sizingTransform\n});\nexport const sizeWidth = style({\n prop: 'size',\n cssProperty: 'width',\n transform: sizingTransform\n});\nexport const sizeHeight = style({\n prop: 'size',\n cssProperty: 'height',\n transform: sizingTransform\n});\nexport const boxSizing = style({\n prop: 'boxSizing'\n});\nconst sizing = compose(width, maxWidth, minWidth, height, maxHeight, minHeight, boxSizing);\nexport default sizing;","import { padding, margin } from '../spacing';\nimport { borderRadius, borderTransform } from '../borders';\nimport { gap, rowGap, columnGap } from '../cssGrid';\nimport { paletteTransform } from '../palette';\nimport { maxWidth, sizingTransform } from '../sizing';\nconst defaultSxConfig = {\n // borders\n border: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderTop: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderRight: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderBottom: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderLeft: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderColor: {\n themeKey: 'palette'\n },\n borderTopColor: {\n themeKey: 'palette'\n },\n borderRightColor: {\n themeKey: 'palette'\n },\n borderBottomColor: {\n themeKey: 'palette'\n },\n borderLeftColor: {\n themeKey: 'palette'\n },\n outline: {\n themeKey: 'borders',\n transform: borderTransform\n },\n outlineColor: {\n themeKey: 'palette'\n },\n borderRadius: {\n themeKey: 'shape.borderRadius',\n style: borderRadius\n },\n // palette\n color: {\n themeKey: 'palette',\n transform: paletteTransform\n },\n bgcolor: {\n themeKey: 'palette',\n cssProperty: 'backgroundColor',\n transform: paletteTransform\n },\n backgroundColor: {\n themeKey: 'palette',\n transform: paletteTransform\n },\n // spacing\n p: {\n style: padding\n },\n pt: {\n style: padding\n },\n pr: {\n style: padding\n },\n pb: {\n style: padding\n },\n pl: {\n style: padding\n },\n px: {\n style: padding\n },\n py: {\n style: padding\n },\n padding: {\n style: padding\n },\n paddingTop: {\n style: padding\n },\n paddingRight: {\n style: padding\n },\n paddingBottom: {\n style: padding\n },\n paddingLeft: {\n style: padding\n },\n paddingX: {\n style: padding\n },\n paddingY: {\n style: padding\n },\n paddingInline: {\n style: padding\n },\n paddingInlineStart: {\n style: padding\n },\n paddingInlineEnd: {\n style: padding\n },\n paddingBlock: {\n style: padding\n },\n paddingBlockStart: {\n style: padding\n },\n paddingBlockEnd: {\n style: padding\n },\n m: {\n style: margin\n },\n mt: {\n style: margin\n },\n mr: {\n style: margin\n },\n mb: {\n style: margin\n },\n ml: {\n style: margin\n },\n mx: {\n style: margin\n },\n my: {\n style: margin\n },\n margin: {\n style: margin\n },\n marginTop: {\n style: margin\n },\n marginRight: {\n style: margin\n },\n marginBottom: {\n style: margin\n },\n marginLeft: {\n style: margin\n },\n marginX: {\n style: margin\n },\n marginY: {\n style: margin\n },\n marginInline: {\n style: margin\n },\n marginInlineStart: {\n style: margin\n },\n marginInlineEnd: {\n style: margin\n },\n marginBlock: {\n style: margin\n },\n marginBlockStart: {\n style: margin\n },\n marginBlockEnd: {\n style: margin\n },\n // display\n displayPrint: {\n cssProperty: false,\n transform: value => ({\n '@media print': {\n display: value\n }\n })\n },\n display: {},\n overflow: {},\n textOverflow: {},\n visibility: {},\n whiteSpace: {},\n // flexbox\n flexBasis: {},\n flexDirection: {},\n flexWrap: {},\n justifyContent: {},\n alignItems: {},\n alignContent: {},\n order: {},\n flex: {},\n flexGrow: {},\n flexShrink: {},\n alignSelf: {},\n justifyItems: {},\n justifySelf: {},\n // grid\n gap: {\n style: gap\n },\n rowGap: {\n style: rowGap\n },\n columnGap: {\n style: columnGap\n },\n gridColumn: {},\n gridRow: {},\n gridAutoFlow: {},\n gridAutoColumns: {},\n gridAutoRows: {},\n gridTemplateColumns: {},\n gridTemplateRows: {},\n gridTemplateAreas: {},\n gridArea: {},\n // positions\n position: {},\n zIndex: {\n themeKey: 'zIndex'\n },\n top: {},\n right: {},\n bottom: {},\n left: {},\n // shadows\n boxShadow: {\n themeKey: 'shadows'\n },\n // sizing\n width: {\n transform: sizingTransform\n },\n maxWidth: {\n style: maxWidth\n },\n minWidth: {\n transform: sizingTransform\n },\n height: {\n transform: sizingTransform\n },\n maxHeight: {\n transform: sizingTransform\n },\n minHeight: {\n transform: sizingTransform\n },\n boxSizing: {},\n // typography\n fontFamily: {\n themeKey: 'typography'\n },\n fontSize: {\n themeKey: 'typography'\n },\n fontStyle: {\n themeKey: 'typography'\n },\n fontWeight: {\n themeKey: 'typography'\n },\n letterSpacing: {},\n textTransform: {},\n lineHeight: {},\n textAlign: {},\n typography: {\n cssProperty: false,\n themeKey: 'typography'\n }\n};\nexport default defaultSxConfig;","import capitalize from '@mui/utils/capitalize';\nimport merge from '../merge';\nimport { getPath, getStyleValue as getValue } from '../style';\nimport { handleBreakpoints, createEmptyBreakpointObject, removeUnusedBreakpoints } from '../breakpoints';\nimport defaultSxConfig from './defaultSxConfig';\nfunction objectsHaveSameKeys(...objects) {\n const allKeys = objects.reduce((keys, object) => keys.concat(Object.keys(object)), []);\n const union = new Set(allKeys);\n return objects.every(object => union.size === Object.keys(object).length);\n}\nfunction callIfFn(maybeFn, arg) {\n return typeof maybeFn === 'function' ? maybeFn(arg) : maybeFn;\n}\n\n// eslint-disable-next-line @typescript-eslint/naming-convention\nexport function unstable_createStyleFunctionSx() {\n function getThemeValue(prop, val, theme, config) {\n const props = {\n [prop]: val,\n theme\n };\n const options = config[prop];\n if (!options) {\n return {\n [prop]: val\n };\n }\n const {\n cssProperty = prop,\n themeKey,\n transform,\n style\n } = options;\n if (val == null) {\n return null;\n }\n\n // TODO v6: remove, see https://github.com/mui/material-ui/pull/38123\n if (themeKey === 'typography' && val === 'inherit') {\n return {\n [prop]: val\n };\n }\n const themeMapping = getPath(theme, themeKey) || {};\n if (style) {\n return style(props);\n }\n const styleFromPropValue = propValueFinal => {\n let value = getValue(themeMapping, transform, propValueFinal);\n if (propValueFinal === value && typeof propValueFinal === 'string') {\n // Haven't found value\n value = getValue(themeMapping, transform, `${prop}${propValueFinal === 'default' ? '' : capitalize(propValueFinal)}`, propValueFinal);\n }\n if (cssProperty === false) {\n return value;\n }\n return {\n [cssProperty]: value\n };\n };\n return handleBreakpoints(props, val, styleFromPropValue);\n }\n function styleFunctionSx(props) {\n var _theme$unstable_sxCon;\n const {\n sx,\n theme = {}\n } = props || {};\n if (!sx) {\n return null; // Emotion & styled-components will neglect null\n }\n const config = (_theme$unstable_sxCon = theme.unstable_sxConfig) != null ? _theme$unstable_sxCon : defaultSxConfig;\n\n /*\n * Receive `sxInput` as object or callback\n * and then recursively check keys & values to create media query object styles.\n * (the result will be used in `styled`)\n */\n function traverse(sxInput) {\n let sxObject = sxInput;\n if (typeof sxInput === 'function') {\n sxObject = sxInput(theme);\n } else if (typeof sxInput !== 'object') {\n // value\n return sxInput;\n }\n if (!sxObject) {\n return null;\n }\n const emptyBreakpoints = createEmptyBreakpointObject(theme.breakpoints);\n const breakpointsKeys = Object.keys(emptyBreakpoints);\n let css = emptyBreakpoints;\n Object.keys(sxObject).forEach(styleKey => {\n const value = callIfFn(sxObject[styleKey], theme);\n if (value !== null && value !== undefined) {\n if (typeof value === 'object') {\n if (config[styleKey]) {\n css = merge(css, getThemeValue(styleKey, value, theme, config));\n } else {\n const breakpointsValues = handleBreakpoints({\n theme\n }, value, x => ({\n [styleKey]: x\n }));\n if (objectsHaveSameKeys(breakpointsValues, value)) {\n css[styleKey] = styleFunctionSx({\n sx: value,\n theme\n });\n } else {\n css = merge(css, breakpointsValues);\n }\n }\n } else {\n css = merge(css, getThemeValue(styleKey, value, theme, config));\n }\n }\n });\n return removeUnusedBreakpoints(breakpointsKeys, css);\n }\n return Array.isArray(sx) ? sx.map(traverse) : traverse(sx);\n }\n return styleFunctionSx;\n}\nconst styleFunctionSx = unstable_createStyleFunctionSx();\nstyleFunctionSx.filterProps = ['sx'];\nexport default styleFunctionSx;","/**\n * A universal utility to style components with multiple color modes. Always use it from the theme object.\n * It works with:\n * - [Basic theme](https://mui.com/material-ui/customization/dark-mode/)\n * - [CSS theme variables](https://mui.com/material-ui/experimental-api/css-theme-variables/overview/)\n * - Zero-runtime engine\n *\n * Tips: Use an array over object spread and place `theme.applyStyles()` last.\n *\n * ✅ [{ background: '#e5e5e5' }, theme.applyStyles('dark', { background: '#1c1c1c' })]\n *\n * 🚫 { background: '#e5e5e5', ...theme.applyStyles('dark', { background: '#1c1c1c' })}\n *\n * @example\n * 1. using with `styled`:\n * ```jsx\n * const Component = styled('div')(({ theme }) => [\n * { background: '#e5e5e5' },\n * theme.applyStyles('dark', {\n * background: '#1c1c1c',\n * color: '#fff',\n * }),\n * ]);\n * ```\n *\n * @example\n * 2. using with `sx` prop:\n * ```jsx\n * [\n * { background: '#e5e5e5' },\n * theme.applyStyles('dark', {\n * background: '#1c1c1c',\n * color: '#fff',\n * }),\n * ]}\n * />\n * ```\n *\n * @example\n * 3. theming a component:\n * ```jsx\n * extendTheme({\n * components: {\n * MuiButton: {\n * styleOverrides: {\n * root: ({ theme }) => [\n * { background: '#e5e5e5' },\n * theme.applyStyles('dark', {\n * background: '#1c1c1c',\n * color: '#fff',\n * }),\n * ],\n * },\n * }\n * }\n * })\n *```\n */\nexport default function applyStyles(key, styles) {\n // @ts-expect-error this is 'any' type\n const theme = this;\n if (theme.vars && typeof theme.getColorSchemeSelector === 'function') {\n // If CssVarsProvider is used as a provider,\n // returns '* :where([data-mui-color-scheme=\"light|dark\"]) &'\n const selector = theme.getColorSchemeSelector(key).replace(/(\\[[^\\]]+\\])/, '*:where($1)');\n return {\n [selector]: styles\n };\n }\n if (theme.palette.mode === key) {\n return styles;\n }\n return {};\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"breakpoints\", \"palette\", \"spacing\", \"shape\"];\nimport deepmerge from '@mui/utils/deepmerge';\nimport createBreakpoints from './createBreakpoints';\nimport shape from './shape';\nimport createSpacing from './createSpacing';\nimport styleFunctionSx from '../styleFunctionSx/styleFunctionSx';\nimport defaultSxConfig from '../styleFunctionSx/defaultSxConfig';\nimport applyStyles from './applyStyles';\nfunction createTheme(options = {}, ...args) {\n const {\n breakpoints: breakpointsInput = {},\n palette: paletteInput = {},\n spacing: spacingInput,\n shape: shapeInput = {}\n } = options,\n other = _objectWithoutPropertiesLoose(options, _excluded);\n const breakpoints = createBreakpoints(breakpointsInput);\n const spacing = createSpacing(spacingInput);\n let muiTheme = deepmerge({\n breakpoints,\n direction: 'ltr',\n components: {},\n // Inject component definitions.\n palette: _extends({\n mode: 'light'\n }, paletteInput),\n spacing,\n shape: _extends({}, shape, shapeInput)\n }, other);\n muiTheme.applyStyles = applyStyles;\n muiTheme = args.reduce((acc, argument) => deepmerge(acc, argument), muiTheme);\n muiTheme.unstable_sxConfig = _extends({}, defaultSxConfig, other == null ? void 0 : other.unstable_sxConfig);\n muiTheme.unstable_sx = function sx(props) {\n return styleFunctionSx({\n sx: props,\n theme: this\n });\n };\n return muiTheme;\n}\nexport default createTheme;","'use client';\n\nimport * as React from 'react';\nimport { ThemeContext } from '@mui/styled-engine';\nfunction isObjectEmpty(obj) {\n return Object.keys(obj).length === 0;\n}\nfunction useTheme(defaultTheme = null) {\n const contextTheme = React.useContext(ThemeContext);\n return !contextTheme || isObjectEmpty(contextTheme) ? defaultTheme : contextTheme;\n}\nexport default useTheme;","'use client';\n\nimport createTheme from './createTheme';\nimport useThemeWithoutDefault from './useThemeWithoutDefault';\nexport const systemDefaultTheme = createTheme();\nfunction useTheme(defaultTheme = systemDefaultTheme) {\n return useThemeWithoutDefault(defaultTheme);\n}\nexport default useTheme;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"ownerState\"],\n _excluded2 = [\"variants\"],\n _excluded3 = [\"name\", \"slot\", \"skipVariantsResolver\", \"skipSx\", \"overridesResolver\"];\n/* eslint-disable no-underscore-dangle */\nimport styledEngineStyled, { internal_processStyles as processStyles } from '@mui/styled-engine';\nimport { isPlainObject } from '@mui/utils/deepmerge';\nimport capitalize from '@mui/utils/capitalize';\nimport getDisplayName from '@mui/utils/getDisplayName';\nimport createTheme from './createTheme';\nimport styleFunctionSx from './styleFunctionSx';\nfunction isEmpty(obj) {\n return Object.keys(obj).length === 0;\n}\n\n// https://github.com/emotion-js/emotion/blob/26ded6109fcd8ca9875cc2ce4564fee678a3f3c5/packages/styled/src/utils.js#L40\nfunction isStringTag(tag) {\n return typeof tag === 'string' &&\n // 96 is one less than the char code\n // for \"a\" so this is checking that\n // it's a lowercase character\n tag.charCodeAt(0) > 96;\n}\n\n// Update /system/styled/#api in case if this changes\nexport function shouldForwardProp(prop) {\n return prop !== 'ownerState' && prop !== 'theme' && prop !== 'sx' && prop !== 'as';\n}\nexport const systemDefaultTheme = createTheme();\nconst lowercaseFirstLetter = string => {\n if (!string) {\n return string;\n }\n return string.charAt(0).toLowerCase() + string.slice(1);\n};\nfunction resolveTheme({\n defaultTheme,\n theme,\n themeId\n}) {\n return isEmpty(theme) ? defaultTheme : theme[themeId] || theme;\n}\nfunction defaultOverridesResolver(slot) {\n if (!slot) {\n return null;\n }\n return (props, styles) => styles[slot];\n}\nfunction processStyleArg(callableStyle, _ref) {\n let {\n ownerState\n } = _ref,\n props = _objectWithoutPropertiesLoose(_ref, _excluded);\n const resolvedStylesArg = typeof callableStyle === 'function' ? callableStyle(_extends({\n ownerState\n }, props)) : callableStyle;\n if (Array.isArray(resolvedStylesArg)) {\n return resolvedStylesArg.flatMap(resolvedStyle => processStyleArg(resolvedStyle, _extends({\n ownerState\n }, props)));\n }\n if (!!resolvedStylesArg && typeof resolvedStylesArg === 'object' && Array.isArray(resolvedStylesArg.variants)) {\n const {\n variants = []\n } = resolvedStylesArg,\n otherStyles = _objectWithoutPropertiesLoose(resolvedStylesArg, _excluded2);\n let result = otherStyles;\n variants.forEach(variant => {\n let isMatch = true;\n if (typeof variant.props === 'function') {\n isMatch = variant.props(_extends({\n ownerState\n }, props, ownerState));\n } else {\n Object.keys(variant.props).forEach(key => {\n if ((ownerState == null ? void 0 : ownerState[key]) !== variant.props[key] && props[key] !== variant.props[key]) {\n isMatch = false;\n }\n });\n }\n if (isMatch) {\n if (!Array.isArray(result)) {\n result = [result];\n }\n result.push(typeof variant.style === 'function' ? variant.style(_extends({\n ownerState\n }, props, ownerState)) : variant.style);\n }\n });\n return result;\n }\n return resolvedStylesArg;\n}\nexport default function createStyled(input = {}) {\n const {\n themeId,\n defaultTheme = systemDefaultTheme,\n rootShouldForwardProp = shouldForwardProp,\n slotShouldForwardProp = shouldForwardProp\n } = input;\n const systemSx = props => {\n return styleFunctionSx(_extends({}, props, {\n theme: resolveTheme(_extends({}, props, {\n defaultTheme,\n themeId\n }))\n }));\n };\n systemSx.__mui_systemSx = true;\n return (tag, inputOptions = {}) => {\n // Filter out the `sx` style function from the previous styled component to prevent unnecessary styles generated by the composite components.\n processStyles(tag, styles => styles.filter(style => !(style != null && style.__mui_systemSx)));\n const {\n name: componentName,\n slot: componentSlot,\n skipVariantsResolver: inputSkipVariantsResolver,\n skipSx: inputSkipSx,\n // TODO v6: remove `lowercaseFirstLetter()` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n overridesResolver = defaultOverridesResolver(lowercaseFirstLetter(componentSlot))\n } = inputOptions,\n options = _objectWithoutPropertiesLoose(inputOptions, _excluded3);\n\n // if skipVariantsResolver option is defined, take the value, otherwise, true for root and false for other slots.\n const skipVariantsResolver = inputSkipVariantsResolver !== undefined ? inputSkipVariantsResolver :\n // TODO v6: remove `Root` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n componentSlot && componentSlot !== 'Root' && componentSlot !== 'root' || false;\n const skipSx = inputSkipSx || false;\n let label;\n if (process.env.NODE_ENV !== 'production') {\n if (componentName) {\n // TODO v6: remove `lowercaseFirstLetter()` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n label = `${componentName}-${lowercaseFirstLetter(componentSlot || 'Root')}`;\n }\n }\n let shouldForwardPropOption = shouldForwardProp;\n\n // TODO v6: remove `Root` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n if (componentSlot === 'Root' || componentSlot === 'root') {\n shouldForwardPropOption = rootShouldForwardProp;\n } else if (componentSlot) {\n // any other slot specified\n shouldForwardPropOption = slotShouldForwardProp;\n } else if (isStringTag(tag)) {\n // for string (html) tag, preserve the behavior in emotion & styled-components.\n shouldForwardPropOption = undefined;\n }\n const defaultStyledResolver = styledEngineStyled(tag, _extends({\n shouldForwardProp: shouldForwardPropOption,\n label\n }, options));\n const transformStyleArg = stylesArg => {\n // On the server Emotion doesn't use React.forwardRef for creating components, so the created\n // component stays as a function. This condition makes sure that we do not interpolate functions\n // which are basically components used as a selectors.\n if (typeof stylesArg === 'function' && stylesArg.__emotion_real !== stylesArg || isPlainObject(stylesArg)) {\n return props => processStyleArg(stylesArg, _extends({}, props, {\n theme: resolveTheme({\n theme: props.theme,\n defaultTheme,\n themeId\n })\n }));\n }\n return stylesArg;\n };\n const muiStyledResolver = (styleArg, ...expressions) => {\n let transformedStyleArg = transformStyleArg(styleArg);\n const expressionsWithDefaultTheme = expressions ? expressions.map(transformStyleArg) : [];\n if (componentName && overridesResolver) {\n expressionsWithDefaultTheme.push(props => {\n const theme = resolveTheme(_extends({}, props, {\n defaultTheme,\n themeId\n }));\n if (!theme.components || !theme.components[componentName] || !theme.components[componentName].styleOverrides) {\n return null;\n }\n const styleOverrides = theme.components[componentName].styleOverrides;\n const resolvedStyleOverrides = {};\n // TODO: v7 remove iteration and use `resolveStyleArg(styleOverrides[slot])` directly\n Object.entries(styleOverrides).forEach(([slotKey, slotStyle]) => {\n resolvedStyleOverrides[slotKey] = processStyleArg(slotStyle, _extends({}, props, {\n theme\n }));\n });\n return overridesResolver(props, resolvedStyleOverrides);\n });\n }\n if (componentName && !skipVariantsResolver) {\n expressionsWithDefaultTheme.push(props => {\n var _theme$components;\n const theme = resolveTheme(_extends({}, props, {\n defaultTheme,\n themeId\n }));\n const themeVariants = theme == null || (_theme$components = theme.components) == null || (_theme$components = _theme$components[componentName]) == null ? void 0 : _theme$components.variants;\n return processStyleArg({\n variants: themeVariants\n }, _extends({}, props, {\n theme\n }));\n });\n }\n if (!skipSx) {\n expressionsWithDefaultTheme.push(systemSx);\n }\n const numOfCustomFnsApplied = expressionsWithDefaultTheme.length - expressions.length;\n if (Array.isArray(styleArg) && numOfCustomFnsApplied > 0) {\n const placeholders = new Array(numOfCustomFnsApplied).fill('');\n // If the type is array, than we need to add placeholders in the template for the overrides, variants and the sx styles.\n transformedStyleArg = [...styleArg, ...placeholders];\n transformedStyleArg.raw = [...styleArg.raw, ...placeholders];\n }\n const Component = defaultStyledResolver(transformedStyleArg, ...expressionsWithDefaultTheme);\n if (process.env.NODE_ENV !== 'production') {\n let displayName;\n if (componentName) {\n displayName = `${componentName}${capitalize(componentSlot || '')}`;\n }\n if (displayName === undefined) {\n displayName = `Styled(${getDisplayName(tag)})`;\n }\n Component.displayName = displayName;\n }\n if (tag.muiName) {\n Component.muiName = tag.muiName;\n }\n return Component;\n };\n if (defaultStyledResolver.withConfig) {\n muiStyledResolver.withConfig = defaultStyledResolver.withConfig;\n }\n return muiStyledResolver;\n };\n}","import resolveProps from '@mui/utils/resolveProps';\nexport default function getThemeProps(params) {\n const {\n theme,\n name,\n props\n } = params;\n if (!theme || !theme.components || !theme.components[name] || !theme.components[name].defaultProps) {\n return props;\n }\n return resolveProps(theme.components[name].defaultProps, props);\n}","'use client';\n\nimport getThemeProps from './getThemeProps';\nimport useTheme from '../useTheme';\nexport default function useThemeProps({\n props,\n name,\n defaultTheme,\n themeId\n}) {\n let theme = useTheme(defaultTheme);\n if (themeId) {\n theme = theme[themeId] || theme;\n }\n const mergedProps = getThemeProps({\n theme,\n name,\n props\n });\n return mergedProps;\n}","import _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\n/* eslint-disable @typescript-eslint/naming-convention */\nimport clamp from '@mui/utils/clamp';\n/**\n * Returns a number whose value is limited to the given range.\n * @param {number} value The value to be clamped\n * @param {number} min The lower boundary of the output range\n * @param {number} max The upper boundary of the output range\n * @returns {number} A number in the range [min, max]\n */\nfunction clampWrapper(value, min = 0, max = 1) {\n if (process.env.NODE_ENV !== 'production') {\n if (value < min || value > max) {\n console.error(`MUI: The value provided ${value} is out of range [${min}, ${max}].`);\n }\n }\n return clamp(value, min, max);\n}\n\n/**\n * Converts a color from CSS hex format to CSS rgb format.\n * @param {string} color - Hex color, i.e. #nnn or #nnnnnn\n * @returns {string} A CSS rgb color string\n */\nexport function hexToRgb(color) {\n color = color.slice(1);\n const re = new RegExp(`.{1,${color.length >= 6 ? 2 : 1}}`, 'g');\n let colors = color.match(re);\n if (colors && colors[0].length === 1) {\n colors = colors.map(n => n + n);\n }\n return colors ? `rgb${colors.length === 4 ? 'a' : ''}(${colors.map((n, index) => {\n return index < 3 ? parseInt(n, 16) : Math.round(parseInt(n, 16) / 255 * 1000) / 1000;\n }).join(', ')})` : '';\n}\nfunction intToHex(int) {\n const hex = int.toString(16);\n return hex.length === 1 ? `0${hex}` : hex;\n}\n\n/**\n * Returns an object with the type and values of a color.\n *\n * Note: Does not support rgb % values.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @returns {object} - A MUI color object: {type: string, values: number[]}\n */\nexport function decomposeColor(color) {\n // Idempotent\n if (color.type) {\n return color;\n }\n if (color.charAt(0) === '#') {\n return decomposeColor(hexToRgb(color));\n }\n const marker = color.indexOf('(');\n const type = color.substring(0, marker);\n if (['rgb', 'rgba', 'hsl', 'hsla', 'color'].indexOf(type) === -1) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: Unsupported \\`${color}\\` color.\nThe following formats are supported: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color().` : _formatMuiErrorMessage(9, color));\n }\n let values = color.substring(marker + 1, color.length - 1);\n let colorSpace;\n if (type === 'color') {\n values = values.split(' ');\n colorSpace = values.shift();\n if (values.length === 4 && values[3].charAt(0) === '/') {\n values[3] = values[3].slice(1);\n }\n if (['srgb', 'display-p3', 'a98-rgb', 'prophoto-rgb', 'rec-2020'].indexOf(colorSpace) === -1) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: unsupported \\`${colorSpace}\\` color space.\nThe following color spaces are supported: srgb, display-p3, a98-rgb, prophoto-rgb, rec-2020.` : _formatMuiErrorMessage(10, colorSpace));\n }\n } else {\n values = values.split(',');\n }\n values = values.map(value => parseFloat(value));\n return {\n type,\n values,\n colorSpace\n };\n}\n\n/**\n * Returns a channel created from the input color.\n *\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @returns {string} - The channel for the color, that can be used in rgba or hsla colors\n */\nexport const colorChannel = color => {\n const decomposedColor = decomposeColor(color);\n return decomposedColor.values.slice(0, 3).map((val, idx) => decomposedColor.type.indexOf('hsl') !== -1 && idx !== 0 ? `${val}%` : val).join(' ');\n};\nexport const private_safeColorChannel = (color, warning) => {\n try {\n return colorChannel(color);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n};\n\n/**\n * Converts a color object with type and values to a string.\n * @param {object} color - Decomposed color\n * @param {string} color.type - One of: 'rgb', 'rgba', 'hsl', 'hsla', 'color'\n * @param {array} color.values - [n,n,n] or [n,n,n,n]\n * @returns {string} A CSS color string\n */\nexport function recomposeColor(color) {\n const {\n type,\n colorSpace\n } = color;\n let {\n values\n } = color;\n if (type.indexOf('rgb') !== -1) {\n // Only convert the first 3 values to int (i.e. not alpha)\n values = values.map((n, i) => i < 3 ? parseInt(n, 10) : n);\n } else if (type.indexOf('hsl') !== -1) {\n values[1] = `${values[1]}%`;\n values[2] = `${values[2]}%`;\n }\n if (type.indexOf('color') !== -1) {\n values = `${colorSpace} ${values.join(' ')}`;\n } else {\n values = `${values.join(', ')}`;\n }\n return `${type}(${values})`;\n}\n\n/**\n * Converts a color from CSS rgb format to CSS hex format.\n * @param {string} color - RGB color, i.e. rgb(n, n, n)\n * @returns {string} A CSS rgb color string, i.e. #nnnnnn\n */\nexport function rgbToHex(color) {\n // Idempotent\n if (color.indexOf('#') === 0) {\n return color;\n }\n const {\n values\n } = decomposeColor(color);\n return `#${values.map((n, i) => intToHex(i === 3 ? Math.round(255 * n) : n)).join('')}`;\n}\n\n/**\n * Converts a color from hsl format to rgb format.\n * @param {string} color - HSL color values\n * @returns {string} rgb color values\n */\nexport function hslToRgb(color) {\n color = decomposeColor(color);\n const {\n values\n } = color;\n const h = values[0];\n const s = values[1] / 100;\n const l = values[2] / 100;\n const a = s * Math.min(l, 1 - l);\n const f = (n, k = (n + h / 30) % 12) => l - a * Math.max(Math.min(k - 3, 9 - k, 1), -1);\n let type = 'rgb';\n const rgb = [Math.round(f(0) * 255), Math.round(f(8) * 255), Math.round(f(4) * 255)];\n if (color.type === 'hsla') {\n type += 'a';\n rgb.push(values[3]);\n }\n return recomposeColor({\n type,\n values: rgb\n });\n}\n/**\n * The relative brightness of any point in a color space,\n * normalized to 0 for darkest black and 1 for lightest white.\n *\n * Formula: https://www.w3.org/TR/WCAG20-TECHS/G17.html#G17-tests\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @returns {number} The relative brightness of the color in the range 0 - 1\n */\nexport function getLuminance(color) {\n color = decomposeColor(color);\n let rgb = color.type === 'hsl' || color.type === 'hsla' ? decomposeColor(hslToRgb(color)).values : color.values;\n rgb = rgb.map(val => {\n if (color.type !== 'color') {\n val /= 255; // normalized\n }\n return val <= 0.03928 ? val / 12.92 : ((val + 0.055) / 1.055) ** 2.4;\n });\n\n // Truncate at 3 digits\n return Number((0.2126 * rgb[0] + 0.7152 * rgb[1] + 0.0722 * rgb[2]).toFixed(3));\n}\n\n/**\n * Calculates the contrast ratio between two colors.\n *\n * Formula: https://www.w3.org/TR/WCAG20-TECHS/G17.html#G17-tests\n * @param {string} foreground - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla()\n * @param {string} background - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla()\n * @returns {number} A contrast ratio value in the range 0 - 21.\n */\nexport function getContrastRatio(foreground, background) {\n const lumA = getLuminance(foreground);\n const lumB = getLuminance(background);\n return (Math.max(lumA, lumB) + 0.05) / (Math.min(lumA, lumB) + 0.05);\n}\n\n/**\n * Sets the absolute transparency of a color.\n * Any existing alpha values are overwritten.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} value - value to set the alpha channel to in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function alpha(color, value) {\n color = decomposeColor(color);\n value = clampWrapper(value);\n if (color.type === 'rgb' || color.type === 'hsl') {\n color.type += 'a';\n }\n if (color.type === 'color') {\n color.values[3] = `/${value}`;\n } else {\n color.values[3] = value;\n }\n return recomposeColor(color);\n}\nexport function private_safeAlpha(color, value, warning) {\n try {\n return alpha(color, value);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Darkens a color.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} coefficient - multiplier in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function darken(color, coefficient) {\n color = decomposeColor(color);\n coefficient = clampWrapper(coefficient);\n if (color.type.indexOf('hsl') !== -1) {\n color.values[2] *= 1 - coefficient;\n } else if (color.type.indexOf('rgb') !== -1 || color.type.indexOf('color') !== -1) {\n for (let i = 0; i < 3; i += 1) {\n color.values[i] *= 1 - coefficient;\n }\n }\n return recomposeColor(color);\n}\nexport function private_safeDarken(color, coefficient, warning) {\n try {\n return darken(color, coefficient);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Lightens a color.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} coefficient - multiplier in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function lighten(color, coefficient) {\n color = decomposeColor(color);\n coefficient = clampWrapper(coefficient);\n if (color.type.indexOf('hsl') !== -1) {\n color.values[2] += (100 - color.values[2]) * coefficient;\n } else if (color.type.indexOf('rgb') !== -1) {\n for (let i = 0; i < 3; i += 1) {\n color.values[i] += (255 - color.values[i]) * coefficient;\n }\n } else if (color.type.indexOf('color') !== -1) {\n for (let i = 0; i < 3; i += 1) {\n color.values[i] += (1 - color.values[i]) * coefficient;\n }\n }\n return recomposeColor(color);\n}\nexport function private_safeLighten(color, coefficient, warning) {\n try {\n return lighten(color, coefficient);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Darken or lighten a color, depending on its luminance.\n * Light colors are darkened, dark colors are lightened.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} coefficient=0.15 - multiplier in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function emphasize(color, coefficient = 0.15) {\n return getLuminance(color) > 0.5 ? darken(color, coefficient) : lighten(color, coefficient);\n}\nexport function private_safeEmphasize(color, coefficient, warning) {\n try {\n return emphasize(color, coefficient);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Blend a transparent overlay color with a background color, resulting in a single\n * RGB color.\n * @param {string} background - CSS color\n * @param {string} overlay - CSS color\n * @param {number} opacity - Opacity multiplier in the range 0 - 1\n * @param {number} [gamma=1.0] - Gamma correction factor. For gamma-correct blending, 2.2 is usual.\n */\nexport function blend(background, overlay, opacity, gamma = 1.0) {\n const blendChannel = (b, o) => Math.round((b ** (1 / gamma) * (1 - opacity) + o ** (1 / gamma) * opacity) ** gamma);\n const backgroundColor = decomposeColor(background);\n const overlayColor = decomposeColor(overlay);\n const rgb = [blendChannel(backgroundColor.values[0], overlayColor.values[0]), blendChannel(backgroundColor.values[1], overlayColor.values[1]), blendChannel(backgroundColor.values[2], overlayColor.values[2])];\n return recomposeColor({\n type: 'rgb',\n values: rgb\n });\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nexport default function createMixins(breakpoints, mixins) {\n return _extends({\n toolbar: {\n minHeight: 56,\n [breakpoints.up('xs')]: {\n '@media (orientation: landscape)': {\n minHeight: 48\n }\n },\n [breakpoints.up('sm')]: {\n minHeight: 64\n }\n }\n }, mixins);\n}","const common = {\n black: '#000',\n white: '#fff'\n};\nexport default common;","const grey = {\n 50: '#fafafa',\n 100: '#f5f5f5',\n 200: '#eeeeee',\n 300: '#e0e0e0',\n 400: '#bdbdbd',\n 500: '#9e9e9e',\n 600: '#757575',\n 700: '#616161',\n 800: '#424242',\n 900: '#212121',\n A100: '#f5f5f5',\n A200: '#eeeeee',\n A400: '#bdbdbd',\n A700: '#616161'\n};\nexport default grey;","const purple = {\n 50: '#f3e5f5',\n 100: '#e1bee7',\n 200: '#ce93d8',\n 300: '#ba68c8',\n 400: '#ab47bc',\n 500: '#9c27b0',\n 600: '#8e24aa',\n 700: '#7b1fa2',\n 800: '#6a1b9a',\n 900: '#4a148c',\n A100: '#ea80fc',\n A200: '#e040fb',\n A400: '#d500f9',\n A700: '#aa00ff'\n};\nexport default purple;","const red = {\n 50: '#ffebee',\n 100: '#ffcdd2',\n 200: '#ef9a9a',\n 300: '#e57373',\n 400: '#ef5350',\n 500: '#f44336',\n 600: '#e53935',\n 700: '#d32f2f',\n 800: '#c62828',\n 900: '#b71c1c',\n A100: '#ff8a80',\n A200: '#ff5252',\n A400: '#ff1744',\n A700: '#d50000'\n};\nexport default red;","const orange = {\n 50: '#fff3e0',\n 100: '#ffe0b2',\n 200: '#ffcc80',\n 300: '#ffb74d',\n 400: '#ffa726',\n 500: '#ff9800',\n 600: '#fb8c00',\n 700: '#f57c00',\n 800: '#ef6c00',\n 900: '#e65100',\n A100: '#ffd180',\n A200: '#ffab40',\n A400: '#ff9100',\n A700: '#ff6d00'\n};\nexport default orange;","const blue = {\n 50: '#e3f2fd',\n 100: '#bbdefb',\n 200: '#90caf9',\n 300: '#64b5f6',\n 400: '#42a5f5',\n 500: '#2196f3',\n 600: '#1e88e5',\n 700: '#1976d2',\n 800: '#1565c0',\n 900: '#0d47a1',\n A100: '#82b1ff',\n A200: '#448aff',\n A400: '#2979ff',\n A700: '#2962ff'\n};\nexport default blue;","const lightBlue = {\n 50: '#e1f5fe',\n 100: '#b3e5fc',\n 200: '#81d4fa',\n 300: '#4fc3f7',\n 400: '#29b6f6',\n 500: '#03a9f4',\n 600: '#039be5',\n 700: '#0288d1',\n 800: '#0277bd',\n 900: '#01579b',\n A100: '#80d8ff',\n A200: '#40c4ff',\n A400: '#00b0ff',\n A700: '#0091ea'\n};\nexport default lightBlue;","const green = {\n 50: '#e8f5e9',\n 100: '#c8e6c9',\n 200: '#a5d6a7',\n 300: '#81c784',\n 400: '#66bb6a',\n 500: '#4caf50',\n 600: '#43a047',\n 700: '#388e3c',\n 800: '#2e7d32',\n 900: '#1b5e20',\n A100: '#b9f6ca',\n A200: '#69f0ae',\n A400: '#00e676',\n A700: '#00c853'\n};\nexport default green;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\nconst _excluded = [\"mode\", \"contrastThreshold\", \"tonalOffset\"];\nimport { deepmerge } from '@mui/utils';\nimport { darken, getContrastRatio, lighten } from '@mui/system';\nimport common from '../colors/common';\nimport grey from '../colors/grey';\nimport purple from '../colors/purple';\nimport red from '../colors/red';\nimport orange from '../colors/orange';\nimport blue from '../colors/blue';\nimport lightBlue from '../colors/lightBlue';\nimport green from '../colors/green';\nexport const light = {\n // The colors used to style the text.\n text: {\n // The most important text.\n primary: 'rgba(0, 0, 0, 0.87)',\n // Secondary text.\n secondary: 'rgba(0, 0, 0, 0.6)',\n // Disabled text have even lower visual prominence.\n disabled: 'rgba(0, 0, 0, 0.38)'\n },\n // The color used to divide different elements.\n divider: 'rgba(0, 0, 0, 0.12)',\n // The background colors used to style the surfaces.\n // Consistency between these values is important.\n background: {\n paper: common.white,\n default: common.white\n },\n // The colors used to style the action elements.\n action: {\n // The color of an active action like an icon button.\n active: 'rgba(0, 0, 0, 0.54)',\n // The color of an hovered action.\n hover: 'rgba(0, 0, 0, 0.04)',\n hoverOpacity: 0.04,\n // The color of a selected action.\n selected: 'rgba(0, 0, 0, 0.08)',\n selectedOpacity: 0.08,\n // The color of a disabled action.\n disabled: 'rgba(0, 0, 0, 0.26)',\n // The background color of a disabled action.\n disabledBackground: 'rgba(0, 0, 0, 0.12)',\n disabledOpacity: 0.38,\n focus: 'rgba(0, 0, 0, 0.12)',\n focusOpacity: 0.12,\n activatedOpacity: 0.12\n }\n};\nexport const dark = {\n text: {\n primary: common.white,\n secondary: 'rgba(255, 255, 255, 0.7)',\n disabled: 'rgba(255, 255, 255, 0.5)',\n icon: 'rgba(255, 255, 255, 0.5)'\n },\n divider: 'rgba(255, 255, 255, 0.12)',\n background: {\n paper: '#121212',\n default: '#121212'\n },\n action: {\n active: common.white,\n hover: 'rgba(255, 255, 255, 0.08)',\n hoverOpacity: 0.08,\n selected: 'rgba(255, 255, 255, 0.16)',\n selectedOpacity: 0.16,\n disabled: 'rgba(255, 255, 255, 0.3)',\n disabledBackground: 'rgba(255, 255, 255, 0.12)',\n disabledOpacity: 0.38,\n focus: 'rgba(255, 255, 255, 0.12)',\n focusOpacity: 0.12,\n activatedOpacity: 0.24\n }\n};\nfunction addLightOrDark(intent, direction, shade, tonalOffset) {\n const tonalOffsetLight = tonalOffset.light || tonalOffset;\n const tonalOffsetDark = tonalOffset.dark || tonalOffset * 1.5;\n if (!intent[direction]) {\n if (intent.hasOwnProperty(shade)) {\n intent[direction] = intent[shade];\n } else if (direction === 'light') {\n intent.light = lighten(intent.main, tonalOffsetLight);\n } else if (direction === 'dark') {\n intent.dark = darken(intent.main, tonalOffsetDark);\n }\n }\n}\nfunction getDefaultPrimary(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: blue[200],\n light: blue[50],\n dark: blue[400]\n };\n }\n return {\n main: blue[700],\n light: blue[400],\n dark: blue[800]\n };\n}\nfunction getDefaultSecondary(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: purple[200],\n light: purple[50],\n dark: purple[400]\n };\n }\n return {\n main: purple[500],\n light: purple[300],\n dark: purple[700]\n };\n}\nfunction getDefaultError(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: red[500],\n light: red[300],\n dark: red[700]\n };\n }\n return {\n main: red[700],\n light: red[400],\n dark: red[800]\n };\n}\nfunction getDefaultInfo(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: lightBlue[400],\n light: lightBlue[300],\n dark: lightBlue[700]\n };\n }\n return {\n main: lightBlue[700],\n light: lightBlue[500],\n dark: lightBlue[900]\n };\n}\nfunction getDefaultSuccess(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: green[400],\n light: green[300],\n dark: green[700]\n };\n }\n return {\n main: green[800],\n light: green[500],\n dark: green[900]\n };\n}\nfunction getDefaultWarning(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: orange[400],\n light: orange[300],\n dark: orange[700]\n };\n }\n return {\n main: '#ed6c02',\n // closest to orange[800] that pass 3:1.\n light: orange[500],\n dark: orange[900]\n };\n}\nexport default function createPalette(palette) {\n const {\n mode = 'light',\n contrastThreshold = 3,\n tonalOffset = 0.2\n } = palette,\n other = _objectWithoutPropertiesLoose(palette, _excluded);\n const primary = palette.primary || getDefaultPrimary(mode);\n const secondary = palette.secondary || getDefaultSecondary(mode);\n const error = palette.error || getDefaultError(mode);\n const info = palette.info || getDefaultInfo(mode);\n const success = palette.success || getDefaultSuccess(mode);\n const warning = palette.warning || getDefaultWarning(mode);\n\n // Use the same logic as\n // Bootstrap: https://github.com/twbs/bootstrap/blob/1d6e3710dd447de1a200f29e8fa521f8a0908f70/scss/_functions.scss#L59\n // and material-components-web https://github.com/material-components/material-components-web/blob/ac46b8863c4dab9fc22c4c662dc6bd1b65dd652f/packages/mdc-theme/_functions.scss#L54\n function getContrastText(background) {\n const contrastText = getContrastRatio(background, dark.text.primary) >= contrastThreshold ? dark.text.primary : light.text.primary;\n if (process.env.NODE_ENV !== 'production') {\n const contrast = getContrastRatio(background, contrastText);\n if (contrast < 3) {\n console.error([`MUI: The contrast ratio of ${contrast}:1 for ${contrastText} on ${background}`, 'falls below the WCAG recommended absolute minimum contrast ratio of 3:1.', 'https://www.w3.org/TR/2008/REC-WCAG20-20081211/#visual-audio-contrast-contrast'].join('\\n'));\n }\n }\n return contrastText;\n }\n const augmentColor = ({\n color,\n name,\n mainShade = 500,\n lightShade = 300,\n darkShade = 700\n }) => {\n color = _extends({}, color);\n if (!color.main && color[mainShade]) {\n color.main = color[mainShade];\n }\n if (!color.hasOwnProperty('main')) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: The color${name ? ` (${name})` : ''} provided to augmentColor(color) is invalid.\nThe color object needs to have a \\`main\\` property or a \\`${mainShade}\\` property.` : _formatMuiErrorMessage(11, name ? ` (${name})` : '', mainShade));\n }\n if (typeof color.main !== 'string') {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: The color${name ? ` (${name})` : ''} provided to augmentColor(color) is invalid.\n\\`color.main\\` should be a string, but \\`${JSON.stringify(color.main)}\\` was provided instead.\n\nDid you intend to use one of the following approaches?\n\nimport { green } from \"@mui/material/colors\";\n\nconst theme1 = createTheme({ palette: {\n primary: green,\n} });\n\nconst theme2 = createTheme({ palette: {\n primary: { main: green[500] },\n} });` : _formatMuiErrorMessage(12, name ? ` (${name})` : '', JSON.stringify(color.main)));\n }\n addLightOrDark(color, 'light', lightShade, tonalOffset);\n addLightOrDark(color, 'dark', darkShade, tonalOffset);\n if (!color.contrastText) {\n color.contrastText = getContrastText(color.main);\n }\n return color;\n };\n const modes = {\n dark,\n light\n };\n if (process.env.NODE_ENV !== 'production') {\n if (!modes[mode]) {\n console.error(`MUI: The palette mode \\`${mode}\\` is not supported.`);\n }\n }\n const paletteOutput = deepmerge(_extends({\n // A collection of common colors.\n common: _extends({}, common),\n // prevent mutable object.\n // The palette mode, can be light or dark.\n mode,\n // The colors used to represent primary interface elements for a user.\n primary: augmentColor({\n color: primary,\n name: 'primary'\n }),\n // The colors used to represent secondary interface elements for a user.\n secondary: augmentColor({\n color: secondary,\n name: 'secondary',\n mainShade: 'A400',\n lightShade: 'A200',\n darkShade: 'A700'\n }),\n // The colors used to represent interface elements that the user should be made aware of.\n error: augmentColor({\n color: error,\n name: 'error'\n }),\n // The colors used to represent potentially dangerous actions or important messages.\n warning: augmentColor({\n color: warning,\n name: 'warning'\n }),\n // The colors used to present information to the user that is neutral and not necessarily important.\n info: augmentColor({\n color: info,\n name: 'info'\n }),\n // The colors used to indicate the successful completion of an action that user triggered.\n success: augmentColor({\n color: success,\n name: 'success'\n }),\n // The grey colors.\n grey,\n // Used by `getContrastText()` to maximize the contrast between\n // the background and the text.\n contrastThreshold,\n // Takes a background color and returns the text color that maximizes the contrast.\n getContrastText,\n // Generate a rich color object.\n augmentColor,\n // Used by the functions below to shift a color's luminance by approximately\n // two indexes within its tonal palette.\n // E.g., shift from Red 500 to Red 300 or Red 700.\n tonalOffset\n }, modes[mode]), other);\n return paletteOutput;\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"fontFamily\", \"fontSize\", \"fontWeightLight\", \"fontWeightRegular\", \"fontWeightMedium\", \"fontWeightBold\", \"htmlFontSize\", \"allVariants\", \"pxToRem\"];\nimport { deepmerge } from '@mui/utils';\nfunction round(value) {\n return Math.round(value * 1e5) / 1e5;\n}\nconst caseAllCaps = {\n textTransform: 'uppercase'\n};\nconst defaultFontFamily = '\"Roboto\", \"Helvetica\", \"Arial\", sans-serif';\n\n/**\n * @see @link{https://m2.material.io/design/typography/the-type-system.html}\n * @see @link{https://m2.material.io/design/typography/understanding-typography.html}\n */\nexport default function createTypography(palette, typography) {\n const _ref = typeof typography === 'function' ? typography(palette) : typography,\n {\n fontFamily = defaultFontFamily,\n // The default font size of the Material Specification.\n fontSize = 14,\n // px\n fontWeightLight = 300,\n fontWeightRegular = 400,\n fontWeightMedium = 500,\n fontWeightBold = 700,\n // Tell MUI what's the font-size on the html element.\n // 16px is the default font-size used by browsers.\n htmlFontSize = 16,\n // Apply the CSS properties to all the variants.\n allVariants,\n pxToRem: pxToRem2\n } = _ref,\n other = _objectWithoutPropertiesLoose(_ref, _excluded);\n if (process.env.NODE_ENV !== 'production') {\n if (typeof fontSize !== 'number') {\n console.error('MUI: `fontSize` is required to be a number.');\n }\n if (typeof htmlFontSize !== 'number') {\n console.error('MUI: `htmlFontSize` is required to be a number.');\n }\n }\n const coef = fontSize / 14;\n const pxToRem = pxToRem2 || (size => `${size / htmlFontSize * coef}rem`);\n const buildVariant = (fontWeight, size, lineHeight, letterSpacing, casing) => _extends({\n fontFamily,\n fontWeight,\n fontSize: pxToRem(size),\n // Unitless following https://meyerweb.com/eric/thoughts/2006/02/08/unitless-line-heights/\n lineHeight\n }, fontFamily === defaultFontFamily ? {\n letterSpacing: `${round(letterSpacing / size)}em`\n } : {}, casing, allVariants);\n const variants = {\n h1: buildVariant(fontWeightLight, 96, 1.167, -1.5),\n h2: buildVariant(fontWeightLight, 60, 1.2, -0.5),\n h3: buildVariant(fontWeightRegular, 48, 1.167, 0),\n h4: buildVariant(fontWeightRegular, 34, 1.235, 0.25),\n h5: buildVariant(fontWeightRegular, 24, 1.334, 0),\n h6: buildVariant(fontWeightMedium, 20, 1.6, 0.15),\n subtitle1: buildVariant(fontWeightRegular, 16, 1.75, 0.15),\n subtitle2: buildVariant(fontWeightMedium, 14, 1.57, 0.1),\n body1: buildVariant(fontWeightRegular, 16, 1.5, 0.15),\n body2: buildVariant(fontWeightRegular, 14, 1.43, 0.15),\n button: buildVariant(fontWeightMedium, 14, 1.75, 0.4, caseAllCaps),\n caption: buildVariant(fontWeightRegular, 12, 1.66, 0.4),\n overline: buildVariant(fontWeightRegular, 12, 2.66, 1, caseAllCaps),\n // TODO v6: Remove handling of 'inherit' variant from the theme as it is already handled in Material UI's Typography component. Also, remember to remove the associated types.\n inherit: {\n fontFamily: 'inherit',\n fontWeight: 'inherit',\n fontSize: 'inherit',\n lineHeight: 'inherit',\n letterSpacing: 'inherit'\n }\n };\n return deepmerge(_extends({\n htmlFontSize,\n pxToRem,\n fontFamily,\n fontSize,\n fontWeightLight,\n fontWeightRegular,\n fontWeightMedium,\n fontWeightBold\n }, variants), other, {\n clone: false // No need to clone deep\n });\n}","const shadowKeyUmbraOpacity = 0.2;\nconst shadowKeyPenumbraOpacity = 0.14;\nconst shadowAmbientShadowOpacity = 0.12;\nfunction createShadow(...px) {\n return [`${px[0]}px ${px[1]}px ${px[2]}px ${px[3]}px rgba(0,0,0,${shadowKeyUmbraOpacity})`, `${px[4]}px ${px[5]}px ${px[6]}px ${px[7]}px rgba(0,0,0,${shadowKeyPenumbraOpacity})`, `${px[8]}px ${px[9]}px ${px[10]}px ${px[11]}px rgba(0,0,0,${shadowAmbientShadowOpacity})`].join(',');\n}\n\n// Values from https://github.com/material-components/material-components-web/blob/be8747f94574669cb5e7add1a7c54fa41a89cec7/packages/mdc-elevation/_variables.scss\nconst shadows = ['none', createShadow(0, 2, 1, -1, 0, 1, 1, 0, 0, 1, 3, 0), createShadow(0, 3, 1, -2, 0, 2, 2, 0, 0, 1, 5, 0), createShadow(0, 3, 3, -2, 0, 3, 4, 0, 0, 1, 8, 0), createShadow(0, 2, 4, -1, 0, 4, 5, 0, 0, 1, 10, 0), createShadow(0, 3, 5, -1, 0, 5, 8, 0, 0, 1, 14, 0), createShadow(0, 3, 5, -1, 0, 6, 10, 0, 0, 1, 18, 0), createShadow(0, 4, 5, -2, 0, 7, 10, 1, 0, 2, 16, 1), createShadow(0, 5, 5, -3, 0, 8, 10, 1, 0, 3, 14, 2), createShadow(0, 5, 6, -3, 0, 9, 12, 1, 0, 3, 16, 2), createShadow(0, 6, 6, -3, 0, 10, 14, 1, 0, 4, 18, 3), createShadow(0, 6, 7, -4, 0, 11, 15, 1, 0, 4, 20, 3), createShadow(0, 7, 8, -4, 0, 12, 17, 2, 0, 5, 22, 4), createShadow(0, 7, 8, -4, 0, 13, 19, 2, 0, 5, 24, 4), createShadow(0, 7, 9, -4, 0, 14, 21, 2, 0, 5, 26, 4), createShadow(0, 8, 9, -5, 0, 15, 22, 2, 0, 6, 28, 5), createShadow(0, 8, 10, -5, 0, 16, 24, 2, 0, 6, 30, 5), createShadow(0, 8, 11, -5, 0, 17, 26, 2, 0, 6, 32, 5), createShadow(0, 9, 11, -5, 0, 18, 28, 2, 0, 7, 34, 6), createShadow(0, 9, 12, -6, 0, 19, 29, 2, 0, 7, 36, 6), createShadow(0, 10, 13, -6, 0, 20, 31, 3, 0, 8, 38, 7), createShadow(0, 10, 13, -6, 0, 21, 33, 3, 0, 8, 40, 7), createShadow(0, 10, 14, -6, 0, 22, 35, 3, 0, 8, 42, 7), createShadow(0, 11, 14, -7, 0, 23, 36, 3, 0, 9, 44, 8), createShadow(0, 11, 15, -7, 0, 24, 38, 3, 0, 9, 46, 8)];\nexport default shadows;","import _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nconst _excluded = [\"duration\", \"easing\", \"delay\"];\n// Follow https://material.google.com/motion/duration-easing.html#duration-easing-natural-easing-curves\n// to learn the context in which each easing should be used.\nexport const easing = {\n // This is the most common easing curve.\n easeInOut: 'cubic-bezier(0.4, 0, 0.2, 1)',\n // Objects enter the screen at full velocity from off-screen and\n // slowly decelerate to a resting point.\n easeOut: 'cubic-bezier(0.0, 0, 0.2, 1)',\n // Objects leave the screen at full velocity. They do not decelerate when off-screen.\n easeIn: 'cubic-bezier(0.4, 0, 1, 1)',\n // The sharp curve is used by objects that may return to the screen at any time.\n sharp: 'cubic-bezier(0.4, 0, 0.6, 1)'\n};\n\n// Follow https://m2.material.io/guidelines/motion/duration-easing.html#duration-easing-common-durations\n// to learn when use what timing\nexport const duration = {\n shortest: 150,\n shorter: 200,\n short: 250,\n // most basic recommended timing\n standard: 300,\n // this is to be used in complex animations\n complex: 375,\n // recommended when something is entering screen\n enteringScreen: 225,\n // recommended when something is leaving screen\n leavingScreen: 195\n};\nfunction formatMs(milliseconds) {\n return `${Math.round(milliseconds)}ms`;\n}\nfunction getAutoHeightDuration(height) {\n if (!height) {\n return 0;\n }\n const constant = height / 36;\n\n // https://www.wolframalpha.com/input/?i=(4+%2B+15+*+(x+%2F+36+)+**+0.25+%2B+(x+%2F+36)+%2F+5)+*+10\n return Math.round((4 + 15 * constant ** 0.25 + constant / 5) * 10);\n}\nexport default function createTransitions(inputTransitions) {\n const mergedEasing = _extends({}, easing, inputTransitions.easing);\n const mergedDuration = _extends({}, duration, inputTransitions.duration);\n const create = (props = ['all'], options = {}) => {\n const {\n duration: durationOption = mergedDuration.standard,\n easing: easingOption = mergedEasing.easeInOut,\n delay = 0\n } = options,\n other = _objectWithoutPropertiesLoose(options, _excluded);\n if (process.env.NODE_ENV !== 'production') {\n const isString = value => typeof value === 'string';\n // IE11 support, replace with Number.isNaN\n // eslint-disable-next-line no-restricted-globals\n const isNumber = value => !isNaN(parseFloat(value));\n if (!isString(props) && !Array.isArray(props)) {\n console.error('MUI: Argument \"props\" must be a string or Array.');\n }\n if (!isNumber(durationOption) && !isString(durationOption)) {\n console.error(`MUI: Argument \"duration\" must be a number or a string but found ${durationOption}.`);\n }\n if (!isString(easingOption)) {\n console.error('MUI: Argument \"easing\" must be a string.');\n }\n if (!isNumber(delay) && !isString(delay)) {\n console.error('MUI: Argument \"delay\" must be a number or a string.');\n }\n if (typeof options !== 'object') {\n console.error(['MUI: Secong argument of transition.create must be an object.', \"Arguments should be either `create('prop1', options)` or `create(['prop1', 'prop2'], options)`\"].join('\\n'));\n }\n if (Object.keys(other).length !== 0) {\n console.error(`MUI: Unrecognized argument(s) [${Object.keys(other).join(',')}].`);\n }\n }\n return (Array.isArray(props) ? props : [props]).map(animatedProp => `${animatedProp} ${typeof durationOption === 'string' ? durationOption : formatMs(durationOption)} ${easingOption} ${typeof delay === 'string' ? delay : formatMs(delay)}`).join(',');\n };\n return _extends({\n getAutoHeightDuration,\n create\n }, inputTransitions, {\n easing: mergedEasing,\n duration: mergedDuration\n });\n}","// We need to centralize the zIndex definitions as they work\n// like global values in the browser.\nconst zIndex = {\n mobileStepper: 1000,\n fab: 1050,\n speedDial: 1050,\n appBar: 1100,\n drawer: 1200,\n modal: 1300,\n snackbar: 1400,\n tooltip: 1500\n};\nexport default zIndex;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\nconst _excluded = [\"breakpoints\", \"mixins\", \"spacing\", \"palette\", \"transitions\", \"typography\", \"shape\"];\nimport { deepmerge } from '@mui/utils';\nimport { createTheme as systemCreateTheme, unstable_defaultSxConfig as defaultSxConfig, unstable_styleFunctionSx as styleFunctionSx } from '@mui/system';\nimport generateUtilityClass from '@mui/utils/generateUtilityClass';\nimport createMixins from './createMixins';\nimport createPalette from './createPalette';\nimport createTypography from './createTypography';\nimport shadows from './shadows';\nimport createTransitions from './createTransitions';\nimport zIndex from './zIndex';\nfunction createTheme(options = {}, ...args) {\n const {\n mixins: mixinsInput = {},\n palette: paletteInput = {},\n transitions: transitionsInput = {},\n typography: typographyInput = {}\n } = options,\n other = _objectWithoutPropertiesLoose(options, _excluded);\n if (options.vars) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: \\`vars\\` is a private field used for CSS variables support.\nPlease use another name.` : _formatMuiErrorMessage(18));\n }\n const palette = createPalette(paletteInput);\n const systemTheme = systemCreateTheme(options);\n let muiTheme = deepmerge(systemTheme, {\n mixins: createMixins(systemTheme.breakpoints, mixinsInput),\n palette,\n // Don't use [...shadows] until you've verified its transpiled code is not invoking the iterator protocol.\n shadows: shadows.slice(),\n typography: createTypography(palette, typographyInput),\n transitions: createTransitions(transitionsInput),\n zIndex: _extends({}, zIndex)\n });\n muiTheme = deepmerge(muiTheme, other);\n muiTheme = args.reduce((acc, argument) => deepmerge(acc, argument), muiTheme);\n if (process.env.NODE_ENV !== 'production') {\n // TODO v6: Refactor to use globalStateClassesMapping from @mui/utils once `readOnly` state class is used in Rating component.\n const stateClasses = ['active', 'checked', 'completed', 'disabled', 'error', 'expanded', 'focused', 'focusVisible', 'required', 'selected'];\n const traverse = (node, component) => {\n let key;\n\n // eslint-disable-next-line guard-for-in, no-restricted-syntax\n for (key in node) {\n const child = node[key];\n if (stateClasses.indexOf(key) !== -1 && Object.keys(child).length > 0) {\n if (process.env.NODE_ENV !== 'production') {\n const stateClass = generateUtilityClass('', key);\n console.error([`MUI: The \\`${component}\\` component increases ` + `the CSS specificity of the \\`${key}\\` internal state.`, 'You can not override it like this: ', JSON.stringify(node, null, 2), '', `Instead, you need to use the '&.${stateClass}' syntax:`, JSON.stringify({\n root: {\n [`&.${stateClass}`]: child\n }\n }, null, 2), '', 'https://mui.com/r/state-classes-guide'].join('\\n'));\n }\n // Remove the style to prevent global conflicts.\n node[key] = {};\n }\n }\n };\n Object.keys(muiTheme.components).forEach(component => {\n const styleOverrides = muiTheme.components[component].styleOverrides;\n if (styleOverrides && component.indexOf('Mui') === 0) {\n traverse(styleOverrides, component);\n }\n });\n }\n muiTheme.unstable_sxConfig = _extends({}, defaultSxConfig, other == null ? void 0 : other.unstable_sxConfig);\n muiTheme.unstable_sx = function sx(props) {\n return styleFunctionSx({\n sx: props,\n theme: this\n });\n };\n return muiTheme;\n}\nlet warnedOnce = false;\nexport function createMuiTheme(...args) {\n if (process.env.NODE_ENV !== 'production') {\n if (!warnedOnce) {\n warnedOnce = true;\n console.error(['MUI: the createMuiTheme function was renamed to createTheme.', '', \"You should use `import { createTheme } from '@mui/material/styles'`\"].join('\\n'));\n }\n }\n return createTheme(...args);\n}\nexport default createTheme;","'use client';\n\nimport createTheme from './createTheme';\nconst defaultTheme = createTheme();\nexport default defaultTheme;","export default '$$material';","'use client';\n\nimport { useThemeProps as systemUseThemeProps } from '@mui/system';\nimport defaultTheme from './defaultTheme';\nimport THEME_ID from './identifier';\nexport default function useThemeProps({\n props,\n name\n}) {\n return systemUseThemeProps({\n props,\n name,\n defaultTheme,\n themeId: THEME_ID\n });\n}","'use client';\n\nimport { createStyled, shouldForwardProp } from '@mui/system';\nimport defaultTheme from './defaultTheme';\nimport THEME_ID from './identifier';\nexport const rootShouldForwardProp = prop => shouldForwardProp(prop) && prop !== 'classes';\nexport const slotShouldForwardProp = shouldForwardProp;\nconst styled = createStyled({\n themeId: THEME_ID,\n defaultTheme,\n rootShouldForwardProp\n});\nexport default styled;","import generateUtilityClasses from '@mui/utils/generateUtilityClasses';\nimport generateUtilityClass from '@mui/utils/generateUtilityClass';\nexport function getSvgIconUtilityClass(slot) {\n return generateUtilityClass('MuiSvgIcon', slot);\n}\nconst svgIconClasses = generateUtilityClasses('MuiSvgIcon', ['root', 'colorPrimary', 'colorSecondary', 'colorAction', 'colorError', 'colorDisabled', 'fontSizeInherit', 'fontSizeSmall', 'fontSizeMedium', 'fontSizeLarge']);\nexport default svgIconClasses;","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"children\", \"className\", \"color\", \"component\", \"fontSize\", \"htmlColor\", \"inheritViewBox\", \"titleAccess\", \"viewBox\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport clsx from 'clsx';\nimport { unstable_composeClasses as composeClasses } from '@mui/base/composeClasses';\nimport capitalize from '../utils/capitalize';\nimport useThemeProps from '../styles/useThemeProps';\nimport styled from '../styles/styled';\nimport { getSvgIconUtilityClass } from './svgIconClasses';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nimport { jsxs as _jsxs } from \"react/jsx-runtime\";\nconst useUtilityClasses = ownerState => {\n const {\n color,\n fontSize,\n classes\n } = ownerState;\n const slots = {\n root: ['root', color !== 'inherit' && `color${capitalize(color)}`, `fontSize${capitalize(fontSize)}`]\n };\n return composeClasses(slots, getSvgIconUtilityClass, classes);\n};\nconst SvgIconRoot = styled('svg', {\n name: 'MuiSvgIcon',\n slot: 'Root',\n overridesResolver: (props, styles) => {\n const {\n ownerState\n } = props;\n return [styles.root, ownerState.color !== 'inherit' && styles[`color${capitalize(ownerState.color)}`], styles[`fontSize${capitalize(ownerState.fontSize)}`]];\n }\n})(({\n theme,\n ownerState\n}) => {\n var _theme$transitions, _theme$transitions$cr, _theme$transitions2, _theme$typography, _theme$typography$pxT, _theme$typography2, _theme$typography2$px, _theme$typography3, _theme$typography3$px, _palette$ownerState$c, _palette, _palette2, _palette3;\n return {\n userSelect: 'none',\n width: '1em',\n height: '1em',\n display: 'inline-block',\n // the will define the property that has `currentColor`\n // e.g. heroicons uses fill=\"none\" and stroke=\"currentColor\"\n fill: ownerState.hasSvgAsChild ? undefined : 'currentColor',\n flexShrink: 0,\n transition: (_theme$transitions = theme.transitions) == null || (_theme$transitions$cr = _theme$transitions.create) == null ? void 0 : _theme$transitions$cr.call(_theme$transitions, 'fill', {\n duration: (_theme$transitions2 = theme.transitions) == null || (_theme$transitions2 = _theme$transitions2.duration) == null ? void 0 : _theme$transitions2.shorter\n }),\n fontSize: {\n inherit: 'inherit',\n small: ((_theme$typography = theme.typography) == null || (_theme$typography$pxT = _theme$typography.pxToRem) == null ? void 0 : _theme$typography$pxT.call(_theme$typography, 20)) || '1.25rem',\n medium: ((_theme$typography2 = theme.typography) == null || (_theme$typography2$px = _theme$typography2.pxToRem) == null ? void 0 : _theme$typography2$px.call(_theme$typography2, 24)) || '1.5rem',\n large: ((_theme$typography3 = theme.typography) == null || (_theme$typography3$px = _theme$typography3.pxToRem) == null ? void 0 : _theme$typography3$px.call(_theme$typography3, 35)) || '2.1875rem'\n }[ownerState.fontSize],\n // TODO v5 deprecate, v6 remove for sx\n color: (_palette$ownerState$c = (_palette = (theme.vars || theme).palette) == null || (_palette = _palette[ownerState.color]) == null ? void 0 : _palette.main) != null ? _palette$ownerState$c : {\n action: (_palette2 = (theme.vars || theme).palette) == null || (_palette2 = _palette2.action) == null ? void 0 : _palette2.active,\n disabled: (_palette3 = (theme.vars || theme).palette) == null || (_palette3 = _palette3.action) == null ? void 0 : _palette3.disabled,\n inherit: undefined\n }[ownerState.color]\n };\n});\nconst SvgIcon = /*#__PURE__*/React.forwardRef(function SvgIcon(inProps, ref) {\n const props = useThemeProps({\n props: inProps,\n name: 'MuiSvgIcon'\n });\n const {\n children,\n className,\n color = 'inherit',\n component = 'svg',\n fontSize = 'medium',\n htmlColor,\n inheritViewBox = false,\n titleAccess,\n viewBox = '0 0 24 24'\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const hasSvgAsChild = /*#__PURE__*/React.isValidElement(children) && children.type === 'svg';\n const ownerState = _extends({}, props, {\n color,\n component,\n fontSize,\n instanceFontSize: inProps.fontSize,\n inheritViewBox,\n viewBox,\n hasSvgAsChild\n });\n const more = {};\n if (!inheritViewBox) {\n more.viewBox = viewBox;\n }\n const classes = useUtilityClasses(ownerState);\n return /*#__PURE__*/_jsxs(SvgIconRoot, _extends({\n as: component,\n className: clsx(classes.root, className),\n focusable: \"false\",\n color: htmlColor,\n \"aria-hidden\": titleAccess ? undefined : true,\n role: titleAccess ? 'img' : undefined,\n ref: ref\n }, more, other, hasSvgAsChild && children.props, {\n ownerState: ownerState,\n children: [hasSvgAsChild ? children.props.children : children, titleAccess ? /*#__PURE__*/_jsx(\"title\", {\n children: titleAccess\n }) : null]\n }));\n});\nprocess.env.NODE_ENV !== \"production\" ? SvgIcon.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the d.ts file and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * Node passed into the SVG element.\n */\n children: PropTypes.node,\n /**\n * Override or extend the styles applied to the component.\n */\n classes: PropTypes.object,\n /**\n * @ignore\n */\n className: PropTypes.string,\n /**\n * The color of the component.\n * It supports both default and custom theme colors, which can be added as shown in the\n * [palette customization guide](https://mui.com/material-ui/customization/palette/#custom-colors).\n * You can use the `htmlColor` prop to apply a color attribute to the SVG element.\n * @default 'inherit'\n */\n color: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.oneOf(['inherit', 'action', 'disabled', 'primary', 'secondary', 'error', 'info', 'success', 'warning']), PropTypes.string]),\n /**\n * The component used for the root node.\n * Either a string to use a HTML element or a component.\n */\n component: PropTypes.elementType,\n /**\n * The fontSize applied to the icon. Defaults to 24px, but can be configure to inherit font size.\n * @default 'medium'\n */\n fontSize: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.oneOf(['inherit', 'large', 'medium', 'small']), PropTypes.string]),\n /**\n * Applies a color attribute to the SVG element.\n */\n htmlColor: PropTypes.string,\n /**\n * If `true`, the root node will inherit the custom `component`'s viewBox and the `viewBox`\n * prop will be ignored.\n * Useful when you want to reference a custom `component` and have `SvgIcon` pass that\n * `component`'s viewBox to the root node.\n * @default false\n */\n inheritViewBox: PropTypes.bool,\n /**\n * The shape-rendering attribute. The behavior of the different options is described on the\n * [MDN Web Docs](https://developer.mozilla.org/en-US/docs/Web/SVG/Attribute/shape-rendering).\n * If you are having issues with blurry icons you should investigate this prop.\n */\n shapeRendering: PropTypes.string,\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Provides a human-readable title for the element that contains it.\n * https://www.w3.org/TR/SVG-access/#Equivalent\n */\n titleAccess: PropTypes.string,\n /**\n * Allows you to redefine what the coordinates without units mean inside an SVG element.\n * For example, if the SVG element is 500 (width) by 200 (height),\n * and you pass viewBox=\"0 0 50 20\",\n * this means that the coordinates inside the SVG will go from the top left corner (0,0)\n * to bottom right (50,20) and each unit will be worth 10px.\n * @default '0 0 24 24'\n */\n viewBox: PropTypes.string\n} : void 0;\nSvgIcon.muiName = 'SvgIcon';\nexport default SvgIcon;","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport * as React from 'react';\nimport SvgIcon from '../SvgIcon';\n\n/**\n * Private module reserved for @mui packages.\n */\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nexport default function createSvgIcon(path, displayName) {\n function Component(props, ref) {\n return /*#__PURE__*/_jsx(SvgIcon, _extends({\n \"data-testid\": `${displayName}Icon`,\n ref: ref\n }, props, {\n children: path\n }));\n }\n if (process.env.NODE_ENV !== 'production') {\n // Need to set `displayName` on the inner component for React.memo.\n // React prior to 16.14 ignores `displayName` on the wrapper.\n Component.displayName = `${displayName}Icon`;\n }\n Component.muiName = SvgIcon.muiName;\n return /*#__PURE__*/React.memo( /*#__PURE__*/React.forwardRef(Component));\n}","'use client';\n\nimport { unstable_ClassNameGenerator as ClassNameGenerator } from '@mui/base/ClassNameGenerator';\nexport { default as capitalize } from './capitalize';\nexport { default as createChainedFunction } from './createChainedFunction';\nexport { default as createSvgIcon } from './createSvgIcon';\nexport { default as debounce } from './debounce';\nexport { default as deprecatedPropType } from './deprecatedPropType';\nexport { default as isMuiElement } from './isMuiElement';\nexport { default as ownerDocument } from './ownerDocument';\nexport { default as ownerWindow } from './ownerWindow';\nexport { default as requirePropFactory } from './requirePropFactory';\nexport { default as setRef } from './setRef';\nexport { default as unstable_useEnhancedEffect } from './useEnhancedEffect';\nexport { default as unstable_useId } from './useId';\nexport { default as unsupportedProp } from './unsupportedProp';\nexport { default as useControlled } from './useControlled';\nexport { default as useEventCallback } from './useEventCallback';\nexport { default as useForkRef } from './useForkRef';\nexport { default as useIsFocusVisible } from './useIsFocusVisible';\n// TODO: remove this export once ClassNameGenerator is stable\n// eslint-disable-next-line @typescript-eslint/naming-convention\nexport const unstable_ClassNameGenerator = {\n configure: generator => {\n if (process.env.NODE_ENV !== 'production') {\n console.warn(['MUI: `ClassNameGenerator` import from `@mui/material/utils` is outdated and might cause unexpected issues.', '', \"You should use `import { unstable_ClassNameGenerator } from '@mui/material/className'` instead\", '', 'The detail of the issue: https://github.com/mui/material-ui/issues/30011#issuecomment-1024993401', '', 'The updated documentation: https://mui.com/guides/classname-generator/'].join('\\n'));\n }\n ClassNameGenerator.configure(generator);\n }\n};","\"use strict\";\n'use client';\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nObject.defineProperty(exports, \"default\", {\n enumerable: true,\n get: function () {\n return _utils.createSvgIcon;\n }\n});\nvar _utils = require(\"@mui/material/utils\");","\"use strict\";\n\"use client\";\n\nvar _interopRequireDefault = require(\"@babel/runtime/helpers/interopRequireDefault\");\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = void 0;\nvar _createSvgIcon = _interopRequireDefault(require(\"./utils/createSvgIcon\"));\nvar _jsxRuntime = require(\"react/jsx-runtime\");\nvar _default = exports.default = (0, _createSvgIcon.default)( /*#__PURE__*/(0, _jsxRuntime.jsx)(\"path\", {\n d: \"m10 17 5-5-5-5z\"\n}), 'ArrowRight');","/**\n * Determines if a given element is a DOM element name (i.e. not a React component).\n */\nexport function isHostComponent(element) {\n return typeof element === 'string';\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport { isHostComponent } from './isHostComponent';\n\n/**\n * Type of the ownerState based on the type of an element it applies to.\n * This resolves to the provided OwnerState for React components and `undefined` for host components.\n * Falls back to `OwnerState | undefined` when the exact type can't be determined in development time.\n */\n\n/**\n * Appends the ownerState object to the props, merging with the existing one if necessary.\n *\n * @param elementType Type of the element that owns the `existingProps`. If the element is a DOM node or undefined, `ownerState` is not applied.\n * @param otherProps Props of the element.\n * @param ownerState\n */\nexport function appendOwnerState(elementType, otherProps, ownerState) {\n if (elementType === undefined || isHostComponent(elementType)) {\n return otherProps;\n }\n return _extends({}, otherProps, {\n ownerState: _extends({}, otherProps.ownerState, ownerState)\n });\n}","'use client';\n\nimport * as React from 'react';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nconst defaultContextValue = {\n disableDefaultClasses: false\n};\nconst ClassNameConfiguratorContext = /*#__PURE__*/React.createContext(defaultContextValue);\n/**\n * @ignore - internal hook.\n *\n * Wraps the `generateUtilityClass` function and controls how the classes are generated.\n * Currently it only affects whether the classes are applied or not.\n *\n * @returns Function to be called with the `generateUtilityClass` function specific to a component to generate the classes.\n */\nexport function useClassNamesOverride(generateUtilityClass) {\n const {\n disableDefaultClasses\n } = React.useContext(ClassNameConfiguratorContext);\n return slot => {\n if (disableDefaultClasses) {\n return '';\n }\n return generateUtilityClass(slot);\n };\n}\n\n/**\n * Allows to configure the components within to not apply any built-in classes.\n */\nexport function ClassNameConfigurator(props) {\n const {\n disableDefaultClasses,\n children\n } = props;\n const contextValue = React.useMemo(() => ({\n disableDefaultClasses: disableDefaultClasses != null ? disableDefaultClasses : false\n }), [disableDefaultClasses]);\n return /*#__PURE__*/_jsx(ClassNameConfiguratorContext.Provider, {\n value: contextValue,\n children: children\n });\n}","/**\n * Extracts event handlers from a given object.\n * A prop is considered an event handler if it is a function and its name starts with `on`.\n *\n * @param object An object to extract event handlers from.\n * @param excludeKeys An array of keys to exclude from the returned object.\n */\nexport function extractEventHandlers(object, excludeKeys = []) {\n if (object === undefined) {\n return {};\n }\n const result = {};\n Object.keys(object).filter(prop => prop.match(/^on[A-Z]/) && typeof object[prop] === 'function' && !excludeKeys.includes(prop)).forEach(prop => {\n result[prop] = object[prop];\n });\n return result;\n}","/**\n * If `componentProps` is a function, calls it with the provided `ownerState`.\n * Otherwise, just returns `componentProps`.\n */\nexport function resolveComponentProps(componentProps, ownerState, slotState) {\n if (typeof componentProps === 'function') {\n return componentProps(ownerState, slotState);\n }\n return componentProps;\n}","/**\n * Removes event handlers from the given object.\n * A field is considered an event handler if it is a function with a name beginning with `on`.\n *\n * @param object Object to remove event handlers from.\n * @returns Object with event handlers removed.\n */\nexport function omitEventHandlers(object) {\n if (object === undefined) {\n return {};\n }\n const result = {};\n Object.keys(object).filter(prop => !(prop.match(/^on[A-Z]/) && typeof object[prop] === 'function')).forEach(prop => {\n result[prop] = object[prop];\n });\n return result;\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport clsx from 'clsx';\nimport { extractEventHandlers } from './extractEventHandlers';\nimport { omitEventHandlers } from './omitEventHandlers';\n/**\n * Merges the slot component internal props (usually coming from a hook)\n * with the externally provided ones.\n *\n * The merge order is (the latter overrides the former):\n * 1. The internal props (specified as a getter function to work with get*Props hook result)\n * 2. Additional props (specified internally on a Base UI component)\n * 3. External props specified on the owner component. These should only be used on a root slot.\n * 4. External props specified in the `slotProps.*` prop.\n * 5. The `className` prop - combined from all the above.\n * @param parameters\n * @returns\n */\nexport function mergeSlotProps(parameters) {\n const {\n getSlotProps,\n additionalProps,\n externalSlotProps,\n externalForwardedProps,\n className\n } = parameters;\n if (!getSlotProps) {\n // The simpler case - getSlotProps is not defined, so no internal event handlers are defined,\n // so we can simply merge all the props without having to worry about extracting event handlers.\n const joinedClasses = clsx(additionalProps == null ? void 0 : additionalProps.className, className, externalForwardedProps == null ? void 0 : externalForwardedProps.className, externalSlotProps == null ? void 0 : externalSlotProps.className);\n const mergedStyle = _extends({}, additionalProps == null ? void 0 : additionalProps.style, externalForwardedProps == null ? void 0 : externalForwardedProps.style, externalSlotProps == null ? void 0 : externalSlotProps.style);\n const props = _extends({}, additionalProps, externalForwardedProps, externalSlotProps);\n if (joinedClasses.length > 0) {\n props.className = joinedClasses;\n }\n if (Object.keys(mergedStyle).length > 0) {\n props.style = mergedStyle;\n }\n return {\n props,\n internalRef: undefined\n };\n }\n\n // In this case, getSlotProps is responsible for calling the external event handlers.\n // We don't need to include them in the merged props because of this.\n\n const eventHandlers = extractEventHandlers(_extends({}, externalForwardedProps, externalSlotProps));\n const componentsPropsWithoutEventHandlers = omitEventHandlers(externalSlotProps);\n const otherPropsWithoutEventHandlers = omitEventHandlers(externalForwardedProps);\n const internalSlotProps = getSlotProps(eventHandlers);\n\n // The order of classes is important here.\n // Emotion (that we use in libraries consuming Base UI) depends on this order\n // to properly override style. It requires the most important classes to be last\n // (see https://github.com/mui/material-ui/pull/33205) for the related discussion.\n const joinedClasses = clsx(internalSlotProps == null ? void 0 : internalSlotProps.className, additionalProps == null ? void 0 : additionalProps.className, className, externalForwardedProps == null ? void 0 : externalForwardedProps.className, externalSlotProps == null ? void 0 : externalSlotProps.className);\n const mergedStyle = _extends({}, internalSlotProps == null ? void 0 : internalSlotProps.style, additionalProps == null ? void 0 : additionalProps.style, externalForwardedProps == null ? void 0 : externalForwardedProps.style, externalSlotProps == null ? void 0 : externalSlotProps.style);\n const props = _extends({}, internalSlotProps, additionalProps, otherPropsWithoutEventHandlers, componentsPropsWithoutEventHandlers);\n if (joinedClasses.length > 0) {\n props.className = joinedClasses;\n }\n if (Object.keys(mergedStyle).length > 0) {\n props.style = mergedStyle;\n }\n return {\n props,\n internalRef: internalSlotProps.ref\n };\n}","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"elementType\", \"externalSlotProps\", \"ownerState\", \"skipResolvingSlotProps\"];\nimport { unstable_useForkRef as useForkRef } from '@mui/utils';\nimport { appendOwnerState } from './appendOwnerState';\nimport { mergeSlotProps } from './mergeSlotProps';\nimport { resolveComponentProps } from './resolveComponentProps';\n/**\n * @ignore - do not document.\n * Builds the props to be passed into the slot of an unstyled component.\n * It merges the internal props of the component with the ones supplied by the user, allowing to customize the behavior.\n * If the slot component is not a host component, it also merges in the `ownerState`.\n *\n * @param parameters.getSlotProps - A function that returns the props to be passed to the slot component.\n */\nexport function useSlotProps(parameters) {\n var _parameters$additiona;\n const {\n elementType,\n externalSlotProps,\n ownerState,\n skipResolvingSlotProps = false\n } = parameters,\n rest = _objectWithoutPropertiesLoose(parameters, _excluded);\n const resolvedComponentsProps = skipResolvingSlotProps ? {} : resolveComponentProps(externalSlotProps, ownerState);\n const {\n props: mergedProps,\n internalRef\n } = mergeSlotProps(_extends({}, rest, {\n externalSlotProps: resolvedComponentsProps\n }));\n const ref = useForkRef(internalRef, resolvedComponentsProps == null ? void 0 : resolvedComponentsProps.ref, (_parameters$additiona = parameters.additionalProps) == null ? void 0 : _parameters$additiona.ref);\n const props = appendOwnerState(elementType, _extends({}, mergedProps, {\n ref\n }), ownerState);\n return props;\n}","import { globalStateClasses } from '@mui/utils/generateUtilityClass';\nconst GLOBAL_CLASS_PREFIX = 'base';\nfunction buildStateClass(state) {\n return `${GLOBAL_CLASS_PREFIX}--${state}`;\n}\nfunction buildSlotClass(componentName, slot) {\n return `${GLOBAL_CLASS_PREFIX}-${componentName}-${slot}`;\n}\nexport function generateUtilityClass(componentName, slot) {\n const globalStateClass = globalStateClasses[slot];\n return globalStateClass ? buildStateClass(globalStateClass) : buildSlotClass(componentName, slot);\n}\nexport function isGlobalState(slot) {\n return globalStateClasses[slot] !== undefined;\n}","import { generateUtilityClass } from '../generateUtilityClass';\nexport function generateUtilityClasses(componentName, slots) {\n const result = {};\n slots.forEach(slot => {\n result[slot] = generateUtilityClass(componentName, slot);\n });\n return result;\n}","'use client';\n\nimport * as React from 'react';\nimport * as ReactDOM from 'react-dom';\nimport PropTypes from 'prop-types';\nimport { exactProp, HTMLElementType, unstable_useEnhancedEffect as useEnhancedEffect, unstable_useForkRef as useForkRef, unstable_setRef as setRef } from '@mui/utils';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nfunction getContainer(container) {\n return typeof container === 'function' ? container() : container;\n}\n\n/**\n * Portals provide a first-class way to render children into a DOM node\n * that exists outside the DOM hierarchy of the parent component.\n *\n * Demos:\n *\n * - [Portal](https://mui.com/base-ui/react-portal/)\n *\n * API:\n *\n * - [Portal API](https://mui.com/base-ui/react-portal/components-api/#portal)\n */\nconst Portal = /*#__PURE__*/React.forwardRef(function Portal(props, forwardedRef) {\n const {\n children,\n container,\n disablePortal = false\n } = props;\n const [mountNode, setMountNode] = React.useState(null);\n // @ts-expect-error TODO upstream fix\n const handleRef = useForkRef( /*#__PURE__*/React.isValidElement(children) ? children.ref : null, forwardedRef);\n useEnhancedEffect(() => {\n if (!disablePortal) {\n setMountNode(getContainer(container) || document.body);\n }\n }, [container, disablePortal]);\n useEnhancedEffect(() => {\n if (mountNode && !disablePortal) {\n setRef(forwardedRef, mountNode);\n return () => {\n setRef(forwardedRef, null);\n };\n }\n return undefined;\n }, [forwardedRef, mountNode, disablePortal]);\n if (disablePortal) {\n if ( /*#__PURE__*/React.isValidElement(children)) {\n const newProps = {\n ref: handleRef\n };\n return /*#__PURE__*/React.cloneElement(children, newProps);\n }\n return /*#__PURE__*/_jsx(React.Fragment, {\n children: children\n });\n }\n return /*#__PURE__*/_jsx(React.Fragment, {\n children: mountNode ? /*#__PURE__*/ReactDOM.createPortal(children, mountNode) : mountNode\n });\n});\nprocess.env.NODE_ENV !== \"production\" ? Portal.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * The children to render into the `container`.\n */\n children: PropTypes.node,\n /**\n * An HTML element or function that returns one.\n * The `container` will have the portal children appended to it.\n *\n * You can also provide a callback, which is called in a React layout effect.\n * This lets you set the container from a ref, and also makes server-side rendering possible.\n *\n * By default, it uses the body of the top-level document object,\n * so it's simply `document.body` most of the time.\n */\n container: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.func]),\n /**\n * The `children` will be under the DOM hierarchy of the parent component.\n * @default false\n */\n disablePortal: PropTypes.bool\n} : void 0;\nif (process.env.NODE_ENV !== 'production') {\n // eslint-disable-next-line\n Portal['propTypes' + ''] = exactProp(Portal.propTypes);\n}\nexport { Portal };","export var top = 'top';\nexport var bottom = 'bottom';\nexport var right = 'right';\nexport var left = 'left';\nexport var auto = 'auto';\nexport var basePlacements = [top, bottom, right, left];\nexport var start = 'start';\nexport var end = 'end';\nexport var clippingParents = 'clippingParents';\nexport var viewport = 'viewport';\nexport var popper = 'popper';\nexport var reference = 'reference';\nexport var variationPlacements = /*#__PURE__*/basePlacements.reduce(function (acc, placement) {\n return acc.concat([placement + \"-\" + start, placement + \"-\" + end]);\n}, []);\nexport var placements = /*#__PURE__*/[].concat(basePlacements, [auto]).reduce(function (acc, placement) {\n return acc.concat([placement, placement + \"-\" + start, placement + \"-\" + end]);\n}, []); // modifiers that need to read the DOM\n\nexport var beforeRead = 'beforeRead';\nexport var read = 'read';\nexport var afterRead = 'afterRead'; // pure-logic modifiers\n\nexport var beforeMain = 'beforeMain';\nexport var main = 'main';\nexport var afterMain = 'afterMain'; // modifier with the purpose to write to the DOM (or write into a framework state)\n\nexport var beforeWrite = 'beforeWrite';\nexport var write = 'write';\nexport var afterWrite = 'afterWrite';\nexport var modifierPhases = [beforeRead, read, afterRead, beforeMain, main, afterMain, beforeWrite, write, afterWrite];","export default function getNodeName(element) {\n return element ? (element.nodeName || '').toLowerCase() : null;\n}","export default function getWindow(node) {\n if (node == null) {\n return window;\n }\n\n if (node.toString() !== '[object Window]') {\n var ownerDocument = node.ownerDocument;\n return ownerDocument ? ownerDocument.defaultView || window : window;\n }\n\n return node;\n}","import getWindow from \"./getWindow.js\";\n\nfunction isElement(node) {\n var OwnElement = getWindow(node).Element;\n return node instanceof OwnElement || node instanceof Element;\n}\n\nfunction isHTMLElement(node) {\n var OwnElement = getWindow(node).HTMLElement;\n return node instanceof OwnElement || node instanceof HTMLElement;\n}\n\nfunction isShadowRoot(node) {\n // IE 11 has no ShadowRoot\n if (typeof ShadowRoot === 'undefined') {\n return false;\n }\n\n var OwnElement = getWindow(node).ShadowRoot;\n return node instanceof OwnElement || node instanceof ShadowRoot;\n}\n\nexport { isElement, isHTMLElement, isShadowRoot };","import getNodeName from \"../dom-utils/getNodeName.js\";\nimport { isHTMLElement } from \"../dom-utils/instanceOf.js\"; // This modifier takes the styles prepared by the `computeStyles` modifier\n// and applies them to the HTMLElements such as popper and arrow\n\nfunction applyStyles(_ref) {\n var state = _ref.state;\n Object.keys(state.elements).forEach(function (name) {\n var style = state.styles[name] || {};\n var attributes = state.attributes[name] || {};\n var element = state.elements[name]; // arrow is optional + virtual elements\n\n if (!isHTMLElement(element) || !getNodeName(element)) {\n return;\n } // Flow doesn't support to extend this property, but it's the most\n // effective way to apply styles to an HTMLElement\n // $FlowFixMe[cannot-write]\n\n\n Object.assign(element.style, style);\n Object.keys(attributes).forEach(function (name) {\n var value = attributes[name];\n\n if (value === false) {\n element.removeAttribute(name);\n } else {\n element.setAttribute(name, value === true ? '' : value);\n }\n });\n });\n}\n\nfunction effect(_ref2) {\n var state = _ref2.state;\n var initialStyles = {\n popper: {\n position: state.options.strategy,\n left: '0',\n top: '0',\n margin: '0'\n },\n arrow: {\n position: 'absolute'\n },\n reference: {}\n };\n Object.assign(state.elements.popper.style, initialStyles.popper);\n state.styles = initialStyles;\n\n if (state.elements.arrow) {\n Object.assign(state.elements.arrow.style, initialStyles.arrow);\n }\n\n return function () {\n Object.keys(state.elements).forEach(function (name) {\n var element = state.elements[name];\n var attributes = state.attributes[name] || {};\n var styleProperties = Object.keys(state.styles.hasOwnProperty(name) ? state.styles[name] : initialStyles[name]); // Set all values to an empty string to unset them\n\n var style = styleProperties.reduce(function (style, property) {\n style[property] = '';\n return style;\n }, {}); // arrow is optional + virtual elements\n\n if (!isHTMLElement(element) || !getNodeName(element)) {\n return;\n }\n\n Object.assign(element.style, style);\n Object.keys(attributes).forEach(function (attribute) {\n element.removeAttribute(attribute);\n });\n });\n };\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'applyStyles',\n enabled: true,\n phase: 'write',\n fn: applyStyles,\n effect: effect,\n requires: ['computeStyles']\n};","import { auto } from \"../enums.js\";\nexport default function getBasePlacement(placement) {\n return placement.split('-')[0];\n}","export var max = Math.max;\nexport var min = Math.min;\nexport var round = Math.round;","export default function getUAString() {\n var uaData = navigator.userAgentData;\n\n if (uaData != null && uaData.brands && Array.isArray(uaData.brands)) {\n return uaData.brands.map(function (item) {\n return item.brand + \"/\" + item.version;\n }).join(' ');\n }\n\n return navigator.userAgent;\n}","import getUAString from \"../utils/userAgent.js\";\nexport default function isLayoutViewport() {\n return !/^((?!chrome|android).)*safari/i.test(getUAString());\n}","import { isElement, isHTMLElement } from \"./instanceOf.js\";\nimport { round } from \"../utils/math.js\";\nimport getWindow from \"./getWindow.js\";\nimport isLayoutViewport from \"./isLayoutViewport.js\";\nexport default function getBoundingClientRect(element, includeScale, isFixedStrategy) {\n if (includeScale === void 0) {\n includeScale = false;\n }\n\n if (isFixedStrategy === void 0) {\n isFixedStrategy = false;\n }\n\n var clientRect = element.getBoundingClientRect();\n var scaleX = 1;\n var scaleY = 1;\n\n if (includeScale && isHTMLElement(element)) {\n scaleX = element.offsetWidth > 0 ? round(clientRect.width) / element.offsetWidth || 1 : 1;\n scaleY = element.offsetHeight > 0 ? round(clientRect.height) / element.offsetHeight || 1 : 1;\n }\n\n var _ref = isElement(element) ? getWindow(element) : window,\n visualViewport = _ref.visualViewport;\n\n var addVisualOffsets = !isLayoutViewport() && isFixedStrategy;\n var x = (clientRect.left + (addVisualOffsets && visualViewport ? visualViewport.offsetLeft : 0)) / scaleX;\n var y = (clientRect.top + (addVisualOffsets && visualViewport ? visualViewport.offsetTop : 0)) / scaleY;\n var width = clientRect.width / scaleX;\n var height = clientRect.height / scaleY;\n return {\n width: width,\n height: height,\n top: y,\n right: x + width,\n bottom: y + height,\n left: x,\n x: x,\n y: y\n };\n}","import getBoundingClientRect from \"./getBoundingClientRect.js\"; // Returns the layout rect of an element relative to its offsetParent. Layout\n// means it doesn't take into account transforms.\n\nexport default function getLayoutRect(element) {\n var clientRect = getBoundingClientRect(element); // Use the clientRect sizes if it's not been transformed.\n // Fixes https://github.com/popperjs/popper-core/issues/1223\n\n var width = element.offsetWidth;\n var height = element.offsetHeight;\n\n if (Math.abs(clientRect.width - width) <= 1) {\n width = clientRect.width;\n }\n\n if (Math.abs(clientRect.height - height) <= 1) {\n height = clientRect.height;\n }\n\n return {\n x: element.offsetLeft,\n y: element.offsetTop,\n width: width,\n height: height\n };\n}","import { isShadowRoot } from \"./instanceOf.js\";\nexport default function contains(parent, child) {\n var rootNode = child.getRootNode && child.getRootNode(); // First, attempt with faster native method\n\n if (parent.contains(child)) {\n return true;\n } // then fallback to custom implementation with Shadow DOM support\n else if (rootNode && isShadowRoot(rootNode)) {\n var next = child;\n\n do {\n if (next && parent.isSameNode(next)) {\n return true;\n } // $FlowFixMe[prop-missing]: need a better way to handle this...\n\n\n next = next.parentNode || next.host;\n } while (next);\n } // Give up, the result is false\n\n\n return false;\n}","import getWindow from \"./getWindow.js\";\nexport default function getComputedStyle(element) {\n return getWindow(element).getComputedStyle(element);\n}","import getNodeName from \"./getNodeName.js\";\nexport default function isTableElement(element) {\n return ['table', 'td', 'th'].indexOf(getNodeName(element)) >= 0;\n}","import { isElement } from \"./instanceOf.js\";\nexport default function getDocumentElement(element) {\n // $FlowFixMe[incompatible-return]: assume body is always available\n return ((isElement(element) ? element.ownerDocument : // $FlowFixMe[prop-missing]\n element.document) || window.document).documentElement;\n}","import getNodeName from \"./getNodeName.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport { isShadowRoot } from \"./instanceOf.js\";\nexport default function getParentNode(element) {\n if (getNodeName(element) === 'html') {\n return element;\n }\n\n return (// this is a quicker (but less type safe) way to save quite some bytes from the bundle\n // $FlowFixMe[incompatible-return]\n // $FlowFixMe[prop-missing]\n element.assignedSlot || // step into the shadow DOM of the parent of a slotted node\n element.parentNode || ( // DOM Element detected\n isShadowRoot(element) ? element.host : null) || // ShadowRoot detected\n // $FlowFixMe[incompatible-call]: HTMLElement is a Node\n getDocumentElement(element) // fallback\n\n );\n}","import getWindow from \"./getWindow.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport getComputedStyle from \"./getComputedStyle.js\";\nimport { isHTMLElement, isShadowRoot } from \"./instanceOf.js\";\nimport isTableElement from \"./isTableElement.js\";\nimport getParentNode from \"./getParentNode.js\";\nimport getUAString from \"../utils/userAgent.js\";\n\nfunction getTrueOffsetParent(element) {\n if (!isHTMLElement(element) || // https://github.com/popperjs/popper-core/issues/837\n getComputedStyle(element).position === 'fixed') {\n return null;\n }\n\n return element.offsetParent;\n} // `.offsetParent` reports `null` for fixed elements, while absolute elements\n// return the containing block\n\n\nfunction getContainingBlock(element) {\n var isFirefox = /firefox/i.test(getUAString());\n var isIE = /Trident/i.test(getUAString());\n\n if (isIE && isHTMLElement(element)) {\n // In IE 9, 10 and 11 fixed elements containing block is always established by the viewport\n var elementCss = getComputedStyle(element);\n\n if (elementCss.position === 'fixed') {\n return null;\n }\n }\n\n var currentNode = getParentNode(element);\n\n if (isShadowRoot(currentNode)) {\n currentNode = currentNode.host;\n }\n\n while (isHTMLElement(currentNode) && ['html', 'body'].indexOf(getNodeName(currentNode)) < 0) {\n var css = getComputedStyle(currentNode); // This is non-exhaustive but covers the most common CSS properties that\n // create a containing block.\n // https://developer.mozilla.org/en-US/docs/Web/CSS/Containing_block#identifying_the_containing_block\n\n if (css.transform !== 'none' || css.perspective !== 'none' || css.contain === 'paint' || ['transform', 'perspective'].indexOf(css.willChange) !== -1 || isFirefox && css.willChange === 'filter' || isFirefox && css.filter && css.filter !== 'none') {\n return currentNode;\n } else {\n currentNode = currentNode.parentNode;\n }\n }\n\n return null;\n} // Gets the closest ancestor positioned element. Handles some edge cases,\n// such as table ancestors and cross browser bugs.\n\n\nexport default function getOffsetParent(element) {\n var window = getWindow(element);\n var offsetParent = getTrueOffsetParent(element);\n\n while (offsetParent && isTableElement(offsetParent) && getComputedStyle(offsetParent).position === 'static') {\n offsetParent = getTrueOffsetParent(offsetParent);\n }\n\n if (offsetParent && (getNodeName(offsetParent) === 'html' || getNodeName(offsetParent) === 'body' && getComputedStyle(offsetParent).position === 'static')) {\n return window;\n }\n\n return offsetParent || getContainingBlock(element) || window;\n}","export default function getMainAxisFromPlacement(placement) {\n return ['top', 'bottom'].indexOf(placement) >= 0 ? 'x' : 'y';\n}","import { max as mathMax, min as mathMin } from \"./math.js\";\nexport function within(min, value, max) {\n return mathMax(min, mathMin(value, max));\n}\nexport function withinMaxClamp(min, value, max) {\n var v = within(min, value, max);\n return v > max ? max : v;\n}","export default function getFreshSideObject() {\n return {\n top: 0,\n right: 0,\n bottom: 0,\n left: 0\n };\n}","import getFreshSideObject from \"./getFreshSideObject.js\";\nexport default function mergePaddingObject(paddingObject) {\n return Object.assign({}, getFreshSideObject(), paddingObject);\n}","export default function expandToHashMap(value, keys) {\n return keys.reduce(function (hashMap, key) {\n hashMap[key] = value;\n return hashMap;\n }, {});\n}","import getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getLayoutRect from \"../dom-utils/getLayoutRect.js\";\nimport contains from \"../dom-utils/contains.js\";\nimport getOffsetParent from \"../dom-utils/getOffsetParent.js\";\nimport getMainAxisFromPlacement from \"../utils/getMainAxisFromPlacement.js\";\nimport { within } from \"../utils/within.js\";\nimport mergePaddingObject from \"../utils/mergePaddingObject.js\";\nimport expandToHashMap from \"../utils/expandToHashMap.js\";\nimport { left, right, basePlacements, top, bottom } from \"../enums.js\"; // eslint-disable-next-line import/no-unused-modules\n\nvar toPaddingObject = function toPaddingObject(padding, state) {\n padding = typeof padding === 'function' ? padding(Object.assign({}, state.rects, {\n placement: state.placement\n })) : padding;\n return mergePaddingObject(typeof padding !== 'number' ? padding : expandToHashMap(padding, basePlacements));\n};\n\nfunction arrow(_ref) {\n var _state$modifiersData$;\n\n var state = _ref.state,\n name = _ref.name,\n options = _ref.options;\n var arrowElement = state.elements.arrow;\n var popperOffsets = state.modifiersData.popperOffsets;\n var basePlacement = getBasePlacement(state.placement);\n var axis = getMainAxisFromPlacement(basePlacement);\n var isVertical = [left, right].indexOf(basePlacement) >= 0;\n var len = isVertical ? 'height' : 'width';\n\n if (!arrowElement || !popperOffsets) {\n return;\n }\n\n var paddingObject = toPaddingObject(options.padding, state);\n var arrowRect = getLayoutRect(arrowElement);\n var minProp = axis === 'y' ? top : left;\n var maxProp = axis === 'y' ? bottom : right;\n var endDiff = state.rects.reference[len] + state.rects.reference[axis] - popperOffsets[axis] - state.rects.popper[len];\n var startDiff = popperOffsets[axis] - state.rects.reference[axis];\n var arrowOffsetParent = getOffsetParent(arrowElement);\n var clientSize = arrowOffsetParent ? axis === 'y' ? arrowOffsetParent.clientHeight || 0 : arrowOffsetParent.clientWidth || 0 : 0;\n var centerToReference = endDiff / 2 - startDiff / 2; // Make sure the arrow doesn't overflow the popper if the center point is\n // outside of the popper bounds\n\n var min = paddingObject[minProp];\n var max = clientSize - arrowRect[len] - paddingObject[maxProp];\n var center = clientSize / 2 - arrowRect[len] / 2 + centerToReference;\n var offset = within(min, center, max); // Prevents breaking syntax highlighting...\n\n var axisProp = axis;\n state.modifiersData[name] = (_state$modifiersData$ = {}, _state$modifiersData$[axisProp] = offset, _state$modifiersData$.centerOffset = offset - center, _state$modifiersData$);\n}\n\nfunction effect(_ref2) {\n var state = _ref2.state,\n options = _ref2.options;\n var _options$element = options.element,\n arrowElement = _options$element === void 0 ? '[data-popper-arrow]' : _options$element;\n\n if (arrowElement == null) {\n return;\n } // CSS selector\n\n\n if (typeof arrowElement === 'string') {\n arrowElement = state.elements.popper.querySelector(arrowElement);\n\n if (!arrowElement) {\n return;\n }\n }\n\n if (!contains(state.elements.popper, arrowElement)) {\n return;\n }\n\n state.elements.arrow = arrowElement;\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'arrow',\n enabled: true,\n phase: 'main',\n fn: arrow,\n effect: effect,\n requires: ['popperOffsets'],\n requiresIfExists: ['preventOverflow']\n};","export default function getVariation(placement) {\n return placement.split('-')[1];\n}","import { top, left, right, bottom, end } from \"../enums.js\";\nimport getOffsetParent from \"../dom-utils/getOffsetParent.js\";\nimport getWindow from \"../dom-utils/getWindow.js\";\nimport getDocumentElement from \"../dom-utils/getDocumentElement.js\";\nimport getComputedStyle from \"../dom-utils/getComputedStyle.js\";\nimport getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getVariation from \"../utils/getVariation.js\";\nimport { round } from \"../utils/math.js\"; // eslint-disable-next-line import/no-unused-modules\n\nvar unsetSides = {\n top: 'auto',\n right: 'auto',\n bottom: 'auto',\n left: 'auto'\n}; // Round the offsets to the nearest suitable subpixel based on the DPR.\n// Zooming can change the DPR, but it seems to report a value that will\n// cleanly divide the values into the appropriate subpixels.\n\nfunction roundOffsetsByDPR(_ref, win) {\n var x = _ref.x,\n y = _ref.y;\n var dpr = win.devicePixelRatio || 1;\n return {\n x: round(x * dpr) / dpr || 0,\n y: round(y * dpr) / dpr || 0\n };\n}\n\nexport function mapToStyles(_ref2) {\n var _Object$assign2;\n\n var popper = _ref2.popper,\n popperRect = _ref2.popperRect,\n placement = _ref2.placement,\n variation = _ref2.variation,\n offsets = _ref2.offsets,\n position = _ref2.position,\n gpuAcceleration = _ref2.gpuAcceleration,\n adaptive = _ref2.adaptive,\n roundOffsets = _ref2.roundOffsets,\n isFixed = _ref2.isFixed;\n var _offsets$x = offsets.x,\n x = _offsets$x === void 0 ? 0 : _offsets$x,\n _offsets$y = offsets.y,\n y = _offsets$y === void 0 ? 0 : _offsets$y;\n\n var _ref3 = typeof roundOffsets === 'function' ? roundOffsets({\n x: x,\n y: y\n }) : {\n x: x,\n y: y\n };\n\n x = _ref3.x;\n y = _ref3.y;\n var hasX = offsets.hasOwnProperty('x');\n var hasY = offsets.hasOwnProperty('y');\n var sideX = left;\n var sideY = top;\n var win = window;\n\n if (adaptive) {\n var offsetParent = getOffsetParent(popper);\n var heightProp = 'clientHeight';\n var widthProp = 'clientWidth';\n\n if (offsetParent === getWindow(popper)) {\n offsetParent = getDocumentElement(popper);\n\n if (getComputedStyle(offsetParent).position !== 'static' && position === 'absolute') {\n heightProp = 'scrollHeight';\n widthProp = 'scrollWidth';\n }\n } // $FlowFixMe[incompatible-cast]: force type refinement, we compare offsetParent with window above, but Flow doesn't detect it\n\n\n offsetParent = offsetParent;\n\n if (placement === top || (placement === left || placement === right) && variation === end) {\n sideY = bottom;\n var offsetY = isFixed && offsetParent === win && win.visualViewport ? win.visualViewport.height : // $FlowFixMe[prop-missing]\n offsetParent[heightProp];\n y -= offsetY - popperRect.height;\n y *= gpuAcceleration ? 1 : -1;\n }\n\n if (placement === left || (placement === top || placement === bottom) && variation === end) {\n sideX = right;\n var offsetX = isFixed && offsetParent === win && win.visualViewport ? win.visualViewport.width : // $FlowFixMe[prop-missing]\n offsetParent[widthProp];\n x -= offsetX - popperRect.width;\n x *= gpuAcceleration ? 1 : -1;\n }\n }\n\n var commonStyles = Object.assign({\n position: position\n }, adaptive && unsetSides);\n\n var _ref4 = roundOffsets === true ? roundOffsetsByDPR({\n x: x,\n y: y\n }, getWindow(popper)) : {\n x: x,\n y: y\n };\n\n x = _ref4.x;\n y = _ref4.y;\n\n if (gpuAcceleration) {\n var _Object$assign;\n\n return Object.assign({}, commonStyles, (_Object$assign = {}, _Object$assign[sideY] = hasY ? '0' : '', _Object$assign[sideX] = hasX ? '0' : '', _Object$assign.transform = (win.devicePixelRatio || 1) <= 1 ? \"translate(\" + x + \"px, \" + y + \"px)\" : \"translate3d(\" + x + \"px, \" + y + \"px, 0)\", _Object$assign));\n }\n\n return Object.assign({}, commonStyles, (_Object$assign2 = {}, _Object$assign2[sideY] = hasY ? y + \"px\" : '', _Object$assign2[sideX] = hasX ? x + \"px\" : '', _Object$assign2.transform = '', _Object$assign2));\n}\n\nfunction computeStyles(_ref5) {\n var state = _ref5.state,\n options = _ref5.options;\n var _options$gpuAccelerat = options.gpuAcceleration,\n gpuAcceleration = _options$gpuAccelerat === void 0 ? true : _options$gpuAccelerat,\n _options$adaptive = options.adaptive,\n adaptive = _options$adaptive === void 0 ? true : _options$adaptive,\n _options$roundOffsets = options.roundOffsets,\n roundOffsets = _options$roundOffsets === void 0 ? true : _options$roundOffsets;\n var commonStyles = {\n placement: getBasePlacement(state.placement),\n variation: getVariation(state.placement),\n popper: state.elements.popper,\n popperRect: state.rects.popper,\n gpuAcceleration: gpuAcceleration,\n isFixed: state.options.strategy === 'fixed'\n };\n\n if (state.modifiersData.popperOffsets != null) {\n state.styles.popper = Object.assign({}, state.styles.popper, mapToStyles(Object.assign({}, commonStyles, {\n offsets: state.modifiersData.popperOffsets,\n position: state.options.strategy,\n adaptive: adaptive,\n roundOffsets: roundOffsets\n })));\n }\n\n if (state.modifiersData.arrow != null) {\n state.styles.arrow = Object.assign({}, state.styles.arrow, mapToStyles(Object.assign({}, commonStyles, {\n offsets: state.modifiersData.arrow,\n position: 'absolute',\n adaptive: false,\n roundOffsets: roundOffsets\n })));\n }\n\n state.attributes.popper = Object.assign({}, state.attributes.popper, {\n 'data-popper-placement': state.placement\n });\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'computeStyles',\n enabled: true,\n phase: 'beforeWrite',\n fn: computeStyles,\n data: {}\n};","import getWindow from \"../dom-utils/getWindow.js\"; // eslint-disable-next-line import/no-unused-modules\n\nvar passive = {\n passive: true\n};\n\nfunction effect(_ref) {\n var state = _ref.state,\n instance = _ref.instance,\n options = _ref.options;\n var _options$scroll = options.scroll,\n scroll = _options$scroll === void 0 ? true : _options$scroll,\n _options$resize = options.resize,\n resize = _options$resize === void 0 ? true : _options$resize;\n var window = getWindow(state.elements.popper);\n var scrollParents = [].concat(state.scrollParents.reference, state.scrollParents.popper);\n\n if (scroll) {\n scrollParents.forEach(function (scrollParent) {\n scrollParent.addEventListener('scroll', instance.update, passive);\n });\n }\n\n if (resize) {\n window.addEventListener('resize', instance.update, passive);\n }\n\n return function () {\n if (scroll) {\n scrollParents.forEach(function (scrollParent) {\n scrollParent.removeEventListener('scroll', instance.update, passive);\n });\n }\n\n if (resize) {\n window.removeEventListener('resize', instance.update, passive);\n }\n };\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'eventListeners',\n enabled: true,\n phase: 'write',\n fn: function fn() {},\n effect: effect,\n data: {}\n};","var hash = {\n left: 'right',\n right: 'left',\n bottom: 'top',\n top: 'bottom'\n};\nexport default function getOppositePlacement(placement) {\n return placement.replace(/left|right|bottom|top/g, function (matched) {\n return hash[matched];\n });\n}","var hash = {\n start: 'end',\n end: 'start'\n};\nexport default function getOppositeVariationPlacement(placement) {\n return placement.replace(/start|end/g, function (matched) {\n return hash[matched];\n });\n}","import getWindow from \"./getWindow.js\";\nexport default function getWindowScroll(node) {\n var win = getWindow(node);\n var scrollLeft = win.pageXOffset;\n var scrollTop = win.pageYOffset;\n return {\n scrollLeft: scrollLeft,\n scrollTop: scrollTop\n };\n}","import getBoundingClientRect from \"./getBoundingClientRect.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport getWindowScroll from \"./getWindowScroll.js\";\nexport default function getWindowScrollBarX(element) {\n // If has a CSS width greater than the viewport, then this will be\n // incorrect for RTL.\n // Popper 1 is broken in this case and never had a bug report so let's assume\n // it's not an issue. I don't think anyone ever specifies width on \n // anyway.\n // Browsers where the left scrollbar doesn't cause an issue report `0` for\n // this (e.g. Edge 2019, IE11, Safari)\n return getBoundingClientRect(getDocumentElement(element)).left + getWindowScroll(element).scrollLeft;\n}","import getWindow from \"./getWindow.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport getWindowScrollBarX from \"./getWindowScrollBarX.js\";\nimport isLayoutViewport from \"./isLayoutViewport.js\";\nexport default function getViewportRect(element, strategy) {\n var win = getWindow(element);\n var html = getDocumentElement(element);\n var visualViewport = win.visualViewport;\n var width = html.clientWidth;\n var height = html.clientHeight;\n var x = 0;\n var y = 0;\n\n if (visualViewport) {\n width = visualViewport.width;\n height = visualViewport.height;\n var layoutViewport = isLayoutViewport();\n\n if (layoutViewport || !layoutViewport && strategy === 'fixed') {\n x = visualViewport.offsetLeft;\n y = visualViewport.offsetTop;\n }\n }\n\n return {\n width: width,\n height: height,\n x: x + getWindowScrollBarX(element),\n y: y\n };\n}","import getDocumentElement from \"./getDocumentElement.js\";\nimport getComputedStyle from \"./getComputedStyle.js\";\nimport getWindowScrollBarX from \"./getWindowScrollBarX.js\";\nimport getWindowScroll from \"./getWindowScroll.js\";\nimport { max } from \"../utils/math.js\"; // Gets the entire size of the scrollable document area, even extending outside\n// of the `` and `` rect bounds if horizontally scrollable\n\nexport default function getDocumentRect(element) {\n var _element$ownerDocumen;\n\n var html = getDocumentElement(element);\n var winScroll = getWindowScroll(element);\n var body = (_element$ownerDocumen = element.ownerDocument) == null ? void 0 : _element$ownerDocumen.body;\n var width = max(html.scrollWidth, html.clientWidth, body ? body.scrollWidth : 0, body ? body.clientWidth : 0);\n var height = max(html.scrollHeight, html.clientHeight, body ? body.scrollHeight : 0, body ? body.clientHeight : 0);\n var x = -winScroll.scrollLeft + getWindowScrollBarX(element);\n var y = -winScroll.scrollTop;\n\n if (getComputedStyle(body || html).direction === 'rtl') {\n x += max(html.clientWidth, body ? body.clientWidth : 0) - width;\n }\n\n return {\n width: width,\n height: height,\n x: x,\n y: y\n };\n}","import getComputedStyle from \"./getComputedStyle.js\";\nexport default function isScrollParent(element) {\n // Firefox wants us to check `-x` and `-y` variations as well\n var _getComputedStyle = getComputedStyle(element),\n overflow = _getComputedStyle.overflow,\n overflowX = _getComputedStyle.overflowX,\n overflowY = _getComputedStyle.overflowY;\n\n return /auto|scroll|overlay|hidden/.test(overflow + overflowY + overflowX);\n}","import getParentNode from \"./getParentNode.js\";\nimport isScrollParent from \"./isScrollParent.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport { isHTMLElement } from \"./instanceOf.js\";\nexport default function getScrollParent(node) {\n if (['html', 'body', '#document'].indexOf(getNodeName(node)) >= 0) {\n // $FlowFixMe[incompatible-return]: assume body is always available\n return node.ownerDocument.body;\n }\n\n if (isHTMLElement(node) && isScrollParent(node)) {\n return node;\n }\n\n return getScrollParent(getParentNode(node));\n}","import getScrollParent from \"./getScrollParent.js\";\nimport getParentNode from \"./getParentNode.js\";\nimport getWindow from \"./getWindow.js\";\nimport isScrollParent from \"./isScrollParent.js\";\n/*\ngiven a DOM element, return the list of all scroll parents, up the list of ancesors\nuntil we get to the top window object. This list is what we attach scroll listeners\nto, because if any of these parent elements scroll, we'll need to re-calculate the\nreference element's position.\n*/\n\nexport default function listScrollParents(element, list) {\n var _element$ownerDocumen;\n\n if (list === void 0) {\n list = [];\n }\n\n var scrollParent = getScrollParent(element);\n var isBody = scrollParent === ((_element$ownerDocumen = element.ownerDocument) == null ? void 0 : _element$ownerDocumen.body);\n var win = getWindow(scrollParent);\n var target = isBody ? [win].concat(win.visualViewport || [], isScrollParent(scrollParent) ? scrollParent : []) : scrollParent;\n var updatedList = list.concat(target);\n return isBody ? updatedList : // $FlowFixMe[incompatible-call]: isBody tells us target will be an HTMLElement here\n updatedList.concat(listScrollParents(getParentNode(target)));\n}","export default function rectToClientRect(rect) {\n return Object.assign({}, rect, {\n left: rect.x,\n top: rect.y,\n right: rect.x + rect.width,\n bottom: rect.y + rect.height\n });\n}","import { viewport } from \"../enums.js\";\nimport getViewportRect from \"./getViewportRect.js\";\nimport getDocumentRect from \"./getDocumentRect.js\";\nimport listScrollParents from \"./listScrollParents.js\";\nimport getOffsetParent from \"./getOffsetParent.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport getComputedStyle from \"./getComputedStyle.js\";\nimport { isElement, isHTMLElement } from \"./instanceOf.js\";\nimport getBoundingClientRect from \"./getBoundingClientRect.js\";\nimport getParentNode from \"./getParentNode.js\";\nimport contains from \"./contains.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport rectToClientRect from \"../utils/rectToClientRect.js\";\nimport { max, min } from \"../utils/math.js\";\n\nfunction getInnerBoundingClientRect(element, strategy) {\n var rect = getBoundingClientRect(element, false, strategy === 'fixed');\n rect.top = rect.top + element.clientTop;\n rect.left = rect.left + element.clientLeft;\n rect.bottom = rect.top + element.clientHeight;\n rect.right = rect.left + element.clientWidth;\n rect.width = element.clientWidth;\n rect.height = element.clientHeight;\n rect.x = rect.left;\n rect.y = rect.top;\n return rect;\n}\n\nfunction getClientRectFromMixedType(element, clippingParent, strategy) {\n return clippingParent === viewport ? rectToClientRect(getViewportRect(element, strategy)) : isElement(clippingParent) ? getInnerBoundingClientRect(clippingParent, strategy) : rectToClientRect(getDocumentRect(getDocumentElement(element)));\n} // A \"clipping parent\" is an overflowable container with the characteristic of\n// clipping (or hiding) overflowing elements with a position different from\n// `initial`\n\n\nfunction getClippingParents(element) {\n var clippingParents = listScrollParents(getParentNode(element));\n var canEscapeClipping = ['absolute', 'fixed'].indexOf(getComputedStyle(element).position) >= 0;\n var clipperElement = canEscapeClipping && isHTMLElement(element) ? getOffsetParent(element) : element;\n\n if (!isElement(clipperElement)) {\n return [];\n } // $FlowFixMe[incompatible-return]: https://github.com/facebook/flow/issues/1414\n\n\n return clippingParents.filter(function (clippingParent) {\n return isElement(clippingParent) && contains(clippingParent, clipperElement) && getNodeName(clippingParent) !== 'body';\n });\n} // Gets the maximum area that the element is visible in due to any number of\n// clipping parents\n\n\nexport default function getClippingRect(element, boundary, rootBoundary, strategy) {\n var mainClippingParents = boundary === 'clippingParents' ? getClippingParents(element) : [].concat(boundary);\n var clippingParents = [].concat(mainClippingParents, [rootBoundary]);\n var firstClippingParent = clippingParents[0];\n var clippingRect = clippingParents.reduce(function (accRect, clippingParent) {\n var rect = getClientRectFromMixedType(element, clippingParent, strategy);\n accRect.top = max(rect.top, accRect.top);\n accRect.right = min(rect.right, accRect.right);\n accRect.bottom = min(rect.bottom, accRect.bottom);\n accRect.left = max(rect.left, accRect.left);\n return accRect;\n }, getClientRectFromMixedType(element, firstClippingParent, strategy));\n clippingRect.width = clippingRect.right - clippingRect.left;\n clippingRect.height = clippingRect.bottom - clippingRect.top;\n clippingRect.x = clippingRect.left;\n clippingRect.y = clippingRect.top;\n return clippingRect;\n}","import getBasePlacement from \"./getBasePlacement.js\";\nimport getVariation from \"./getVariation.js\";\nimport getMainAxisFromPlacement from \"./getMainAxisFromPlacement.js\";\nimport { top, right, bottom, left, start, end } from \"../enums.js\";\nexport default function computeOffsets(_ref) {\n var reference = _ref.reference,\n element = _ref.element,\n placement = _ref.placement;\n var basePlacement = placement ? getBasePlacement(placement) : null;\n var variation = placement ? getVariation(placement) : null;\n var commonX = reference.x + reference.width / 2 - element.width / 2;\n var commonY = reference.y + reference.height / 2 - element.height / 2;\n var offsets;\n\n switch (basePlacement) {\n case top:\n offsets = {\n x: commonX,\n y: reference.y - element.height\n };\n break;\n\n case bottom:\n offsets = {\n x: commonX,\n y: reference.y + reference.height\n };\n break;\n\n case right:\n offsets = {\n x: reference.x + reference.width,\n y: commonY\n };\n break;\n\n case left:\n offsets = {\n x: reference.x - element.width,\n y: commonY\n };\n break;\n\n default:\n offsets = {\n x: reference.x,\n y: reference.y\n };\n }\n\n var mainAxis = basePlacement ? getMainAxisFromPlacement(basePlacement) : null;\n\n if (mainAxis != null) {\n var len = mainAxis === 'y' ? 'height' : 'width';\n\n switch (variation) {\n case start:\n offsets[mainAxis] = offsets[mainAxis] - (reference[len] / 2 - element[len] / 2);\n break;\n\n case end:\n offsets[mainAxis] = offsets[mainAxis] + (reference[len] / 2 - element[len] / 2);\n break;\n\n default:\n }\n }\n\n return offsets;\n}","import getClippingRect from \"../dom-utils/getClippingRect.js\";\nimport getDocumentElement from \"../dom-utils/getDocumentElement.js\";\nimport getBoundingClientRect from \"../dom-utils/getBoundingClientRect.js\";\nimport computeOffsets from \"./computeOffsets.js\";\nimport rectToClientRect from \"./rectToClientRect.js\";\nimport { clippingParents, reference, popper, bottom, top, right, basePlacements, viewport } from \"../enums.js\";\nimport { isElement } from \"../dom-utils/instanceOf.js\";\nimport mergePaddingObject from \"./mergePaddingObject.js\";\nimport expandToHashMap from \"./expandToHashMap.js\"; // eslint-disable-next-line import/no-unused-modules\n\nexport default function detectOverflow(state, options) {\n if (options === void 0) {\n options = {};\n }\n\n var _options = options,\n _options$placement = _options.placement,\n placement = _options$placement === void 0 ? state.placement : _options$placement,\n _options$strategy = _options.strategy,\n strategy = _options$strategy === void 0 ? state.strategy : _options$strategy,\n _options$boundary = _options.boundary,\n boundary = _options$boundary === void 0 ? clippingParents : _options$boundary,\n _options$rootBoundary = _options.rootBoundary,\n rootBoundary = _options$rootBoundary === void 0 ? viewport : _options$rootBoundary,\n _options$elementConte = _options.elementContext,\n elementContext = _options$elementConte === void 0 ? popper : _options$elementConte,\n _options$altBoundary = _options.altBoundary,\n altBoundary = _options$altBoundary === void 0 ? false : _options$altBoundary,\n _options$padding = _options.padding,\n padding = _options$padding === void 0 ? 0 : _options$padding;\n var paddingObject = mergePaddingObject(typeof padding !== 'number' ? padding : expandToHashMap(padding, basePlacements));\n var altContext = elementContext === popper ? reference : popper;\n var popperRect = state.rects.popper;\n var element = state.elements[altBoundary ? altContext : elementContext];\n var clippingClientRect = getClippingRect(isElement(element) ? element : element.contextElement || getDocumentElement(state.elements.popper), boundary, rootBoundary, strategy);\n var referenceClientRect = getBoundingClientRect(state.elements.reference);\n var popperOffsets = computeOffsets({\n reference: referenceClientRect,\n element: popperRect,\n strategy: 'absolute',\n placement: placement\n });\n var popperClientRect = rectToClientRect(Object.assign({}, popperRect, popperOffsets));\n var elementClientRect = elementContext === popper ? popperClientRect : referenceClientRect; // positive = overflowing the clipping rect\n // 0 or negative = within the clipping rect\n\n var overflowOffsets = {\n top: clippingClientRect.top - elementClientRect.top + paddingObject.top,\n bottom: elementClientRect.bottom - clippingClientRect.bottom + paddingObject.bottom,\n left: clippingClientRect.left - elementClientRect.left + paddingObject.left,\n right: elementClientRect.right - clippingClientRect.right + paddingObject.right\n };\n var offsetData = state.modifiersData.offset; // Offsets can be applied only to the popper element\n\n if (elementContext === popper && offsetData) {\n var offset = offsetData[placement];\n Object.keys(overflowOffsets).forEach(function (key) {\n var multiply = [right, bottom].indexOf(key) >= 0 ? 1 : -1;\n var axis = [top, bottom].indexOf(key) >= 0 ? 'y' : 'x';\n overflowOffsets[key] += offset[axis] * multiply;\n });\n }\n\n return overflowOffsets;\n}","import getVariation from \"./getVariation.js\";\nimport { variationPlacements, basePlacements, placements as allPlacements } from \"../enums.js\";\nimport detectOverflow from \"./detectOverflow.js\";\nimport getBasePlacement from \"./getBasePlacement.js\";\nexport default function computeAutoPlacement(state, options) {\n if (options === void 0) {\n options = {};\n }\n\n var _options = options,\n placement = _options.placement,\n boundary = _options.boundary,\n rootBoundary = _options.rootBoundary,\n padding = _options.padding,\n flipVariations = _options.flipVariations,\n _options$allowedAutoP = _options.allowedAutoPlacements,\n allowedAutoPlacements = _options$allowedAutoP === void 0 ? allPlacements : _options$allowedAutoP;\n var variation = getVariation(placement);\n var placements = variation ? flipVariations ? variationPlacements : variationPlacements.filter(function (placement) {\n return getVariation(placement) === variation;\n }) : basePlacements;\n var allowedPlacements = placements.filter(function (placement) {\n return allowedAutoPlacements.indexOf(placement) >= 0;\n });\n\n if (allowedPlacements.length === 0) {\n allowedPlacements = placements;\n } // $FlowFixMe[incompatible-type]: Flow seems to have problems with two array unions...\n\n\n var overflows = allowedPlacements.reduce(function (acc, placement) {\n acc[placement] = detectOverflow(state, {\n placement: placement,\n boundary: boundary,\n rootBoundary: rootBoundary,\n padding: padding\n })[getBasePlacement(placement)];\n return acc;\n }, {});\n return Object.keys(overflows).sort(function (a, b) {\n return overflows[a] - overflows[b];\n });\n}","import getOppositePlacement from \"../utils/getOppositePlacement.js\";\nimport getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getOppositeVariationPlacement from \"../utils/getOppositeVariationPlacement.js\";\nimport detectOverflow from \"../utils/detectOverflow.js\";\nimport computeAutoPlacement from \"../utils/computeAutoPlacement.js\";\nimport { bottom, top, start, right, left, auto } from \"../enums.js\";\nimport getVariation from \"../utils/getVariation.js\"; // eslint-disable-next-line import/no-unused-modules\n\nfunction getExpandedFallbackPlacements(placement) {\n if (getBasePlacement(placement) === auto) {\n return [];\n }\n\n var oppositePlacement = getOppositePlacement(placement);\n return [getOppositeVariationPlacement(placement), oppositePlacement, getOppositeVariationPlacement(oppositePlacement)];\n}\n\nfunction flip(_ref) {\n var state = _ref.state,\n options = _ref.options,\n name = _ref.name;\n\n if (state.modifiersData[name]._skip) {\n return;\n }\n\n var _options$mainAxis = options.mainAxis,\n checkMainAxis = _options$mainAxis === void 0 ? true : _options$mainAxis,\n _options$altAxis = options.altAxis,\n checkAltAxis = _options$altAxis === void 0 ? true : _options$altAxis,\n specifiedFallbackPlacements = options.fallbackPlacements,\n padding = options.padding,\n boundary = options.boundary,\n rootBoundary = options.rootBoundary,\n altBoundary = options.altBoundary,\n _options$flipVariatio = options.flipVariations,\n flipVariations = _options$flipVariatio === void 0 ? true : _options$flipVariatio,\n allowedAutoPlacements = options.allowedAutoPlacements;\n var preferredPlacement = state.options.placement;\n var basePlacement = getBasePlacement(preferredPlacement);\n var isBasePlacement = basePlacement === preferredPlacement;\n var fallbackPlacements = specifiedFallbackPlacements || (isBasePlacement || !flipVariations ? [getOppositePlacement(preferredPlacement)] : getExpandedFallbackPlacements(preferredPlacement));\n var placements = [preferredPlacement].concat(fallbackPlacements).reduce(function (acc, placement) {\n return acc.concat(getBasePlacement(placement) === auto ? computeAutoPlacement(state, {\n placement: placement,\n boundary: boundary,\n rootBoundary: rootBoundary,\n padding: padding,\n flipVariations: flipVariations,\n allowedAutoPlacements: allowedAutoPlacements\n }) : placement);\n }, []);\n var referenceRect = state.rects.reference;\n var popperRect = state.rects.popper;\n var checksMap = new Map();\n var makeFallbackChecks = true;\n var firstFittingPlacement = placements[0];\n\n for (var i = 0; i < placements.length; i++) {\n var placement = placements[i];\n\n var _basePlacement = getBasePlacement(placement);\n\n var isStartVariation = getVariation(placement) === start;\n var isVertical = [top, bottom].indexOf(_basePlacement) >= 0;\n var len = isVertical ? 'width' : 'height';\n var overflow = detectOverflow(state, {\n placement: placement,\n boundary: boundary,\n rootBoundary: rootBoundary,\n altBoundary: altBoundary,\n padding: padding\n });\n var mainVariationSide = isVertical ? isStartVariation ? right : left : isStartVariation ? bottom : top;\n\n if (referenceRect[len] > popperRect[len]) {\n mainVariationSide = getOppositePlacement(mainVariationSide);\n }\n\n var altVariationSide = getOppositePlacement(mainVariationSide);\n var checks = [];\n\n if (checkMainAxis) {\n checks.push(overflow[_basePlacement] <= 0);\n }\n\n if (checkAltAxis) {\n checks.push(overflow[mainVariationSide] <= 0, overflow[altVariationSide] <= 0);\n }\n\n if (checks.every(function (check) {\n return check;\n })) {\n firstFittingPlacement = placement;\n makeFallbackChecks = false;\n break;\n }\n\n checksMap.set(placement, checks);\n }\n\n if (makeFallbackChecks) {\n // `2` may be desired in some cases – research later\n var numberOfChecks = flipVariations ? 3 : 1;\n\n var _loop = function _loop(_i) {\n var fittingPlacement = placements.find(function (placement) {\n var checks = checksMap.get(placement);\n\n if (checks) {\n return checks.slice(0, _i).every(function (check) {\n return check;\n });\n }\n });\n\n if (fittingPlacement) {\n firstFittingPlacement = fittingPlacement;\n return \"break\";\n }\n };\n\n for (var _i = numberOfChecks; _i > 0; _i--) {\n var _ret = _loop(_i);\n\n if (_ret === \"break\") break;\n }\n }\n\n if (state.placement !== firstFittingPlacement) {\n state.modifiersData[name]._skip = true;\n state.placement = firstFittingPlacement;\n state.reset = true;\n }\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'flip',\n enabled: true,\n phase: 'main',\n fn: flip,\n requiresIfExists: ['offset'],\n data: {\n _skip: false\n }\n};","import { top, bottom, left, right } from \"../enums.js\";\nimport detectOverflow from \"../utils/detectOverflow.js\";\n\nfunction getSideOffsets(overflow, rect, preventedOffsets) {\n if (preventedOffsets === void 0) {\n preventedOffsets = {\n x: 0,\n y: 0\n };\n }\n\n return {\n top: overflow.top - rect.height - preventedOffsets.y,\n right: overflow.right - rect.width + preventedOffsets.x,\n bottom: overflow.bottom - rect.height + preventedOffsets.y,\n left: overflow.left - rect.width - preventedOffsets.x\n };\n}\n\nfunction isAnySideFullyClipped(overflow) {\n return [top, right, bottom, left].some(function (side) {\n return overflow[side] >= 0;\n });\n}\n\nfunction hide(_ref) {\n var state = _ref.state,\n name = _ref.name;\n var referenceRect = state.rects.reference;\n var popperRect = state.rects.popper;\n var preventedOffsets = state.modifiersData.preventOverflow;\n var referenceOverflow = detectOverflow(state, {\n elementContext: 'reference'\n });\n var popperAltOverflow = detectOverflow(state, {\n altBoundary: true\n });\n var referenceClippingOffsets = getSideOffsets(referenceOverflow, referenceRect);\n var popperEscapeOffsets = getSideOffsets(popperAltOverflow, popperRect, preventedOffsets);\n var isReferenceHidden = isAnySideFullyClipped(referenceClippingOffsets);\n var hasPopperEscaped = isAnySideFullyClipped(popperEscapeOffsets);\n state.modifiersData[name] = {\n referenceClippingOffsets: referenceClippingOffsets,\n popperEscapeOffsets: popperEscapeOffsets,\n isReferenceHidden: isReferenceHidden,\n hasPopperEscaped: hasPopperEscaped\n };\n state.attributes.popper = Object.assign({}, state.attributes.popper, {\n 'data-popper-reference-hidden': isReferenceHidden,\n 'data-popper-escaped': hasPopperEscaped\n });\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'hide',\n enabled: true,\n phase: 'main',\n requiresIfExists: ['preventOverflow'],\n fn: hide\n};","import getBasePlacement from \"../utils/getBasePlacement.js\";\nimport { top, left, right, placements } from \"../enums.js\"; // eslint-disable-next-line import/no-unused-modules\n\nexport function distanceAndSkiddingToXY(placement, rects, offset) {\n var basePlacement = getBasePlacement(placement);\n var invertDistance = [left, top].indexOf(basePlacement) >= 0 ? -1 : 1;\n\n var _ref = typeof offset === 'function' ? offset(Object.assign({}, rects, {\n placement: placement\n })) : offset,\n skidding = _ref[0],\n distance = _ref[1];\n\n skidding = skidding || 0;\n distance = (distance || 0) * invertDistance;\n return [left, right].indexOf(basePlacement) >= 0 ? {\n x: distance,\n y: skidding\n } : {\n x: skidding,\n y: distance\n };\n}\n\nfunction offset(_ref2) {\n var state = _ref2.state,\n options = _ref2.options,\n name = _ref2.name;\n var _options$offset = options.offset,\n offset = _options$offset === void 0 ? [0, 0] : _options$offset;\n var data = placements.reduce(function (acc, placement) {\n acc[placement] = distanceAndSkiddingToXY(placement, state.rects, offset);\n return acc;\n }, {});\n var _data$state$placement = data[state.placement],\n x = _data$state$placement.x,\n y = _data$state$placement.y;\n\n if (state.modifiersData.popperOffsets != null) {\n state.modifiersData.popperOffsets.x += x;\n state.modifiersData.popperOffsets.y += y;\n }\n\n state.modifiersData[name] = data;\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'offset',\n enabled: true,\n phase: 'main',\n requires: ['popperOffsets'],\n fn: offset\n};","import computeOffsets from \"../utils/computeOffsets.js\";\n\nfunction popperOffsets(_ref) {\n var state = _ref.state,\n name = _ref.name;\n // Offsets are the actual position the popper needs to have to be\n // properly positioned near its reference element\n // This is the most basic placement, and will be adjusted by\n // the modifiers in the next step\n state.modifiersData[name] = computeOffsets({\n reference: state.rects.reference,\n element: state.rects.popper,\n strategy: 'absolute',\n placement: state.placement\n });\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'popperOffsets',\n enabled: true,\n phase: 'read',\n fn: popperOffsets,\n data: {}\n};","export default function getAltAxis(axis) {\n return axis === 'x' ? 'y' : 'x';\n}","import { top, left, right, bottom, start } from \"../enums.js\";\nimport getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getMainAxisFromPlacement from \"../utils/getMainAxisFromPlacement.js\";\nimport getAltAxis from \"../utils/getAltAxis.js\";\nimport { within, withinMaxClamp } from \"../utils/within.js\";\nimport getLayoutRect from \"../dom-utils/getLayoutRect.js\";\nimport getOffsetParent from \"../dom-utils/getOffsetParent.js\";\nimport detectOverflow from \"../utils/detectOverflow.js\";\nimport getVariation from \"../utils/getVariation.js\";\nimport getFreshSideObject from \"../utils/getFreshSideObject.js\";\nimport { min as mathMin, max as mathMax } from \"../utils/math.js\";\n\nfunction preventOverflow(_ref) {\n var state = _ref.state,\n options = _ref.options,\n name = _ref.name;\n var _options$mainAxis = options.mainAxis,\n checkMainAxis = _options$mainAxis === void 0 ? true : _options$mainAxis,\n _options$altAxis = options.altAxis,\n checkAltAxis = _options$altAxis === void 0 ? false : _options$altAxis,\n boundary = options.boundary,\n rootBoundary = options.rootBoundary,\n altBoundary = options.altBoundary,\n padding = options.padding,\n _options$tether = options.tether,\n tether = _options$tether === void 0 ? true : _options$tether,\n _options$tetherOffset = options.tetherOffset,\n tetherOffset = _options$tetherOffset === void 0 ? 0 : _options$tetherOffset;\n var overflow = detectOverflow(state, {\n boundary: boundary,\n rootBoundary: rootBoundary,\n padding: padding,\n altBoundary: altBoundary\n });\n var basePlacement = getBasePlacement(state.placement);\n var variation = getVariation(state.placement);\n var isBasePlacement = !variation;\n var mainAxis = getMainAxisFromPlacement(basePlacement);\n var altAxis = getAltAxis(mainAxis);\n var popperOffsets = state.modifiersData.popperOffsets;\n var referenceRect = state.rects.reference;\n var popperRect = state.rects.popper;\n var tetherOffsetValue = typeof tetherOffset === 'function' ? tetherOffset(Object.assign({}, state.rects, {\n placement: state.placement\n })) : tetherOffset;\n var normalizedTetherOffsetValue = typeof tetherOffsetValue === 'number' ? {\n mainAxis: tetherOffsetValue,\n altAxis: tetherOffsetValue\n } : Object.assign({\n mainAxis: 0,\n altAxis: 0\n }, tetherOffsetValue);\n var offsetModifierState = state.modifiersData.offset ? state.modifiersData.offset[state.placement] : null;\n var data = {\n x: 0,\n y: 0\n };\n\n if (!popperOffsets) {\n return;\n }\n\n if (checkMainAxis) {\n var _offsetModifierState$;\n\n var mainSide = mainAxis === 'y' ? top : left;\n var altSide = mainAxis === 'y' ? bottom : right;\n var len = mainAxis === 'y' ? 'height' : 'width';\n var offset = popperOffsets[mainAxis];\n var min = offset + overflow[mainSide];\n var max = offset - overflow[altSide];\n var additive = tether ? -popperRect[len] / 2 : 0;\n var minLen = variation === start ? referenceRect[len] : popperRect[len];\n var maxLen = variation === start ? -popperRect[len] : -referenceRect[len]; // We need to include the arrow in the calculation so the arrow doesn't go\n // outside the reference bounds\n\n var arrowElement = state.elements.arrow;\n var arrowRect = tether && arrowElement ? getLayoutRect(arrowElement) : {\n width: 0,\n height: 0\n };\n var arrowPaddingObject = state.modifiersData['arrow#persistent'] ? state.modifiersData['arrow#persistent'].padding : getFreshSideObject();\n var arrowPaddingMin = arrowPaddingObject[mainSide];\n var arrowPaddingMax = arrowPaddingObject[altSide]; // If the reference length is smaller than the arrow length, we don't want\n // to include its full size in the calculation. If the reference is small\n // and near the edge of a boundary, the popper can overflow even if the\n // reference is not overflowing as well (e.g. virtual elements with no\n // width or height)\n\n var arrowLen = within(0, referenceRect[len], arrowRect[len]);\n var minOffset = isBasePlacement ? referenceRect[len] / 2 - additive - arrowLen - arrowPaddingMin - normalizedTetherOffsetValue.mainAxis : minLen - arrowLen - arrowPaddingMin - normalizedTetherOffsetValue.mainAxis;\n var maxOffset = isBasePlacement ? -referenceRect[len] / 2 + additive + arrowLen + arrowPaddingMax + normalizedTetherOffsetValue.mainAxis : maxLen + arrowLen + arrowPaddingMax + normalizedTetherOffsetValue.mainAxis;\n var arrowOffsetParent = state.elements.arrow && getOffsetParent(state.elements.arrow);\n var clientOffset = arrowOffsetParent ? mainAxis === 'y' ? arrowOffsetParent.clientTop || 0 : arrowOffsetParent.clientLeft || 0 : 0;\n var offsetModifierValue = (_offsetModifierState$ = offsetModifierState == null ? void 0 : offsetModifierState[mainAxis]) != null ? _offsetModifierState$ : 0;\n var tetherMin = offset + minOffset - offsetModifierValue - clientOffset;\n var tetherMax = offset + maxOffset - offsetModifierValue;\n var preventedOffset = within(tether ? mathMin(min, tetherMin) : min, offset, tether ? mathMax(max, tetherMax) : max);\n popperOffsets[mainAxis] = preventedOffset;\n data[mainAxis] = preventedOffset - offset;\n }\n\n if (checkAltAxis) {\n var _offsetModifierState$2;\n\n var _mainSide = mainAxis === 'x' ? top : left;\n\n var _altSide = mainAxis === 'x' ? bottom : right;\n\n var _offset = popperOffsets[altAxis];\n\n var _len = altAxis === 'y' ? 'height' : 'width';\n\n var _min = _offset + overflow[_mainSide];\n\n var _max = _offset - overflow[_altSide];\n\n var isOriginSide = [top, left].indexOf(basePlacement) !== -1;\n\n var _offsetModifierValue = (_offsetModifierState$2 = offsetModifierState == null ? void 0 : offsetModifierState[altAxis]) != null ? _offsetModifierState$2 : 0;\n\n var _tetherMin = isOriginSide ? _min : _offset - referenceRect[_len] - popperRect[_len] - _offsetModifierValue + normalizedTetherOffsetValue.altAxis;\n\n var _tetherMax = isOriginSide ? _offset + referenceRect[_len] + popperRect[_len] - _offsetModifierValue - normalizedTetherOffsetValue.altAxis : _max;\n\n var _preventedOffset = tether && isOriginSide ? withinMaxClamp(_tetherMin, _offset, _tetherMax) : within(tether ? _tetherMin : _min, _offset, tether ? _tetherMax : _max);\n\n popperOffsets[altAxis] = _preventedOffset;\n data[altAxis] = _preventedOffset - _offset;\n }\n\n state.modifiersData[name] = data;\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'preventOverflow',\n enabled: true,\n phase: 'main',\n fn: preventOverflow,\n requiresIfExists: ['offset']\n};","export default function getHTMLElementScroll(element) {\n return {\n scrollLeft: element.scrollLeft,\n scrollTop: element.scrollTop\n };\n}","import getWindowScroll from \"./getWindowScroll.js\";\nimport getWindow from \"./getWindow.js\";\nimport { isHTMLElement } from \"./instanceOf.js\";\nimport getHTMLElementScroll from \"./getHTMLElementScroll.js\";\nexport default function getNodeScroll(node) {\n if (node === getWindow(node) || !isHTMLElement(node)) {\n return getWindowScroll(node);\n } else {\n return getHTMLElementScroll(node);\n }\n}","import getBoundingClientRect from \"./getBoundingClientRect.js\";\nimport getNodeScroll from \"./getNodeScroll.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport { isHTMLElement } from \"./instanceOf.js\";\nimport getWindowScrollBarX from \"./getWindowScrollBarX.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport isScrollParent from \"./isScrollParent.js\";\nimport { round } from \"../utils/math.js\";\n\nfunction isElementScaled(element) {\n var rect = element.getBoundingClientRect();\n var scaleX = round(rect.width) / element.offsetWidth || 1;\n var scaleY = round(rect.height) / element.offsetHeight || 1;\n return scaleX !== 1 || scaleY !== 1;\n} // Returns the composite rect of an element relative to its offsetParent.\n// Composite means it takes into account transforms as well as layout.\n\n\nexport default function getCompositeRect(elementOrVirtualElement, offsetParent, isFixed) {\n if (isFixed === void 0) {\n isFixed = false;\n }\n\n var isOffsetParentAnElement = isHTMLElement(offsetParent);\n var offsetParentIsScaled = isHTMLElement(offsetParent) && isElementScaled(offsetParent);\n var documentElement = getDocumentElement(offsetParent);\n var rect = getBoundingClientRect(elementOrVirtualElement, offsetParentIsScaled, isFixed);\n var scroll = {\n scrollLeft: 0,\n scrollTop: 0\n };\n var offsets = {\n x: 0,\n y: 0\n };\n\n if (isOffsetParentAnElement || !isOffsetParentAnElement && !isFixed) {\n if (getNodeName(offsetParent) !== 'body' || // https://github.com/popperjs/popper-core/issues/1078\n isScrollParent(documentElement)) {\n scroll = getNodeScroll(offsetParent);\n }\n\n if (isHTMLElement(offsetParent)) {\n offsets = getBoundingClientRect(offsetParent, true);\n offsets.x += offsetParent.clientLeft;\n offsets.y += offsetParent.clientTop;\n } else if (documentElement) {\n offsets.x = getWindowScrollBarX(documentElement);\n }\n }\n\n return {\n x: rect.left + scroll.scrollLeft - offsets.x,\n y: rect.top + scroll.scrollTop - offsets.y,\n width: rect.width,\n height: rect.height\n };\n}","import { modifierPhases } from \"../enums.js\"; // source: https://stackoverflow.com/questions/49875255\n\nfunction order(modifiers) {\n var map = new Map();\n var visited = new Set();\n var result = [];\n modifiers.forEach(function (modifier) {\n map.set(modifier.name, modifier);\n }); // On visiting object, check for its dependencies and visit them recursively\n\n function sort(modifier) {\n visited.add(modifier.name);\n var requires = [].concat(modifier.requires || [], modifier.requiresIfExists || []);\n requires.forEach(function (dep) {\n if (!visited.has(dep)) {\n var depModifier = map.get(dep);\n\n if (depModifier) {\n sort(depModifier);\n }\n }\n });\n result.push(modifier);\n }\n\n modifiers.forEach(function (modifier) {\n if (!visited.has(modifier.name)) {\n // check for visited object\n sort(modifier);\n }\n });\n return result;\n}\n\nexport default function orderModifiers(modifiers) {\n // order based on dependencies\n var orderedModifiers = order(modifiers); // order based on phase\n\n return modifierPhases.reduce(function (acc, phase) {\n return acc.concat(orderedModifiers.filter(function (modifier) {\n return modifier.phase === phase;\n }));\n }, []);\n}","export default function debounce(fn) {\n var pending;\n return function () {\n if (!pending) {\n pending = new Promise(function (resolve) {\n Promise.resolve().then(function () {\n pending = undefined;\n resolve(fn());\n });\n });\n }\n\n return pending;\n };\n}","export default function mergeByName(modifiers) {\n var merged = modifiers.reduce(function (merged, current) {\n var existing = merged[current.name];\n merged[current.name] = existing ? Object.assign({}, existing, current, {\n options: Object.assign({}, existing.options, current.options),\n data: Object.assign({}, existing.data, current.data)\n }) : current;\n return merged;\n }, {}); // IE11 does not support Object.values\n\n return Object.keys(merged).map(function (key) {\n return merged[key];\n });\n}","import getCompositeRect from \"./dom-utils/getCompositeRect.js\";\nimport getLayoutRect from \"./dom-utils/getLayoutRect.js\";\nimport listScrollParents from \"./dom-utils/listScrollParents.js\";\nimport getOffsetParent from \"./dom-utils/getOffsetParent.js\";\nimport orderModifiers from \"./utils/orderModifiers.js\";\nimport debounce from \"./utils/debounce.js\";\nimport mergeByName from \"./utils/mergeByName.js\";\nimport detectOverflow from \"./utils/detectOverflow.js\";\nimport { isElement } from \"./dom-utils/instanceOf.js\";\nvar DEFAULT_OPTIONS = {\n placement: 'bottom',\n modifiers: [],\n strategy: 'absolute'\n};\n\nfunction areValidElements() {\n for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {\n args[_key] = arguments[_key];\n }\n\n return !args.some(function (element) {\n return !(element && typeof element.getBoundingClientRect === 'function');\n });\n}\n\nexport function popperGenerator(generatorOptions) {\n if (generatorOptions === void 0) {\n generatorOptions = {};\n }\n\n var _generatorOptions = generatorOptions,\n _generatorOptions$def = _generatorOptions.defaultModifiers,\n defaultModifiers = _generatorOptions$def === void 0 ? [] : _generatorOptions$def,\n _generatorOptions$def2 = _generatorOptions.defaultOptions,\n defaultOptions = _generatorOptions$def2 === void 0 ? DEFAULT_OPTIONS : _generatorOptions$def2;\n return function createPopper(reference, popper, options) {\n if (options === void 0) {\n options = defaultOptions;\n }\n\n var state = {\n placement: 'bottom',\n orderedModifiers: [],\n options: Object.assign({}, DEFAULT_OPTIONS, defaultOptions),\n modifiersData: {},\n elements: {\n reference: reference,\n popper: popper\n },\n attributes: {},\n styles: {}\n };\n var effectCleanupFns = [];\n var isDestroyed = false;\n var instance = {\n state: state,\n setOptions: function setOptions(setOptionsAction) {\n var options = typeof setOptionsAction === 'function' ? setOptionsAction(state.options) : setOptionsAction;\n cleanupModifierEffects();\n state.options = Object.assign({}, defaultOptions, state.options, options);\n state.scrollParents = {\n reference: isElement(reference) ? listScrollParents(reference) : reference.contextElement ? listScrollParents(reference.contextElement) : [],\n popper: listScrollParents(popper)\n }; // Orders the modifiers based on their dependencies and `phase`\n // properties\n\n var orderedModifiers = orderModifiers(mergeByName([].concat(defaultModifiers, state.options.modifiers))); // Strip out disabled modifiers\n\n state.orderedModifiers = orderedModifiers.filter(function (m) {\n return m.enabled;\n });\n runModifierEffects();\n return instance.update();\n },\n // Sync update – it will always be executed, even if not necessary. This\n // is useful for low frequency updates where sync behavior simplifies the\n // logic.\n // For high frequency updates (e.g. `resize` and `scroll` events), always\n // prefer the async Popper#update method\n forceUpdate: function forceUpdate() {\n if (isDestroyed) {\n return;\n }\n\n var _state$elements = state.elements,\n reference = _state$elements.reference,\n popper = _state$elements.popper; // Don't proceed if `reference` or `popper` are not valid elements\n // anymore\n\n if (!areValidElements(reference, popper)) {\n return;\n } // Store the reference and popper rects to be read by modifiers\n\n\n state.rects = {\n reference: getCompositeRect(reference, getOffsetParent(popper), state.options.strategy === 'fixed'),\n popper: getLayoutRect(popper)\n }; // Modifiers have the ability to reset the current update cycle. The\n // most common use case for this is the `flip` modifier changing the\n // placement, which then needs to re-run all the modifiers, because the\n // logic was previously ran for the previous placement and is therefore\n // stale/incorrect\n\n state.reset = false;\n state.placement = state.options.placement; // On each update cycle, the `modifiersData` property for each modifier\n // is filled with the initial data specified by the modifier. This means\n // it doesn't persist and is fresh on each update.\n // To ensure persistent data, use `${name}#persistent`\n\n state.orderedModifiers.forEach(function (modifier) {\n return state.modifiersData[modifier.name] = Object.assign({}, modifier.data);\n });\n\n for (var index = 0; index < state.orderedModifiers.length; index++) {\n if (state.reset === true) {\n state.reset = false;\n index = -1;\n continue;\n }\n\n var _state$orderedModifie = state.orderedModifiers[index],\n fn = _state$orderedModifie.fn,\n _state$orderedModifie2 = _state$orderedModifie.options,\n _options = _state$orderedModifie2 === void 0 ? {} : _state$orderedModifie2,\n name = _state$orderedModifie.name;\n\n if (typeof fn === 'function') {\n state = fn({\n state: state,\n options: _options,\n name: name,\n instance: instance\n }) || state;\n }\n }\n },\n // Async and optimistically optimized update – it will not be executed if\n // not necessary (debounced to run at most once-per-tick)\n update: debounce(function () {\n return new Promise(function (resolve) {\n instance.forceUpdate();\n resolve(state);\n });\n }),\n destroy: function destroy() {\n cleanupModifierEffects();\n isDestroyed = true;\n }\n };\n\n if (!areValidElements(reference, popper)) {\n return instance;\n }\n\n instance.setOptions(options).then(function (state) {\n if (!isDestroyed && options.onFirstUpdate) {\n options.onFirstUpdate(state);\n }\n }); // Modifiers have the ability to execute arbitrary code before the first\n // update cycle runs. They will be executed in the same order as the update\n // cycle. This is useful when a modifier adds some persistent data that\n // other modifiers need to use, but the modifier is run after the dependent\n // one.\n\n function runModifierEffects() {\n state.orderedModifiers.forEach(function (_ref) {\n var name = _ref.name,\n _ref$options = _ref.options,\n options = _ref$options === void 0 ? {} : _ref$options,\n effect = _ref.effect;\n\n if (typeof effect === 'function') {\n var cleanupFn = effect({\n state: state,\n name: name,\n instance: instance,\n options: options\n });\n\n var noopFn = function noopFn() {};\n\n effectCleanupFns.push(cleanupFn || noopFn);\n }\n });\n }\n\n function cleanupModifierEffects() {\n effectCleanupFns.forEach(function (fn) {\n return fn();\n });\n effectCleanupFns = [];\n }\n\n return instance;\n };\n}\nexport var createPopper = /*#__PURE__*/popperGenerator(); // eslint-disable-next-line import/no-unused-modules\n\nexport { detectOverflow };","import { popperGenerator, detectOverflow } from \"./createPopper.js\";\nimport eventListeners from \"./modifiers/eventListeners.js\";\nimport popperOffsets from \"./modifiers/popperOffsets.js\";\nimport computeStyles from \"./modifiers/computeStyles.js\";\nimport applyStyles from \"./modifiers/applyStyles.js\";\nimport offset from \"./modifiers/offset.js\";\nimport flip from \"./modifiers/flip.js\";\nimport preventOverflow from \"./modifiers/preventOverflow.js\";\nimport arrow from \"./modifiers/arrow.js\";\nimport hide from \"./modifiers/hide.js\";\nvar defaultModifiers = [eventListeners, popperOffsets, computeStyles, applyStyles, offset, flip, preventOverflow, arrow, hide];\nvar createPopper = /*#__PURE__*/popperGenerator({\n defaultModifiers: defaultModifiers\n}); // eslint-disable-next-line import/no-unused-modules\n\nexport { createPopper, popperGenerator, defaultModifiers, detectOverflow }; // eslint-disable-next-line import/no-unused-modules\n\nexport { createPopper as createPopperLite } from \"./popper-lite.js\"; // eslint-disable-next-line import/no-unused-modules\n\nexport * from \"./modifiers/index.js\";","import { generateUtilityClass } from '../generateUtilityClass';\nimport { generateUtilityClasses } from '../generateUtilityClasses';\nconst COMPONENT_NAME = 'Popper';\nexport function getPopperUtilityClass(slot) {\n return generateUtilityClass(COMPONENT_NAME, slot);\n}\nexport const popperClasses = generateUtilityClasses(COMPONENT_NAME, ['root']);","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"anchorEl\", \"children\", \"direction\", \"disablePortal\", \"modifiers\", \"open\", \"placement\", \"popperOptions\", \"popperRef\", \"slotProps\", \"slots\", \"TransitionProps\", \"ownerState\"],\n _excluded2 = [\"anchorEl\", \"children\", \"container\", \"direction\", \"disablePortal\", \"keepMounted\", \"modifiers\", \"open\", \"placement\", \"popperOptions\", \"popperRef\", \"style\", \"transition\", \"slotProps\", \"slots\"];\nimport * as React from 'react';\nimport { chainPropTypes, HTMLElementType, refType, unstable_ownerDocument as ownerDocument, unstable_useEnhancedEffect as useEnhancedEffect, unstable_useForkRef as useForkRef } from '@mui/utils';\nimport { createPopper } from '@popperjs/core';\nimport PropTypes from 'prop-types';\nimport { unstable_composeClasses as composeClasses } from '../composeClasses';\nimport { Portal } from '../Portal';\nimport { getPopperUtilityClass } from './popperClasses';\nimport { useSlotProps } from '../utils';\nimport { useClassNamesOverride } from '../utils/ClassNameConfigurator';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nfunction flipPlacement(placement, direction) {\n if (direction === 'ltr') {\n return placement;\n }\n switch (placement) {\n case 'bottom-end':\n return 'bottom-start';\n case 'bottom-start':\n return 'bottom-end';\n case 'top-end':\n return 'top-start';\n case 'top-start':\n return 'top-end';\n default:\n return placement;\n }\n}\nfunction resolveAnchorEl(anchorEl) {\n return typeof anchorEl === 'function' ? anchorEl() : anchorEl;\n}\nfunction isHTMLElement(element) {\n return element.nodeType !== undefined;\n}\nfunction isVirtualElement(element) {\n return !isHTMLElement(element);\n}\nconst useUtilityClasses = () => {\n const slots = {\n root: ['root']\n };\n return composeClasses(slots, useClassNamesOverride(getPopperUtilityClass));\n};\nconst defaultPopperOptions = {};\nconst PopperTooltip = /*#__PURE__*/React.forwardRef(function PopperTooltip(props, forwardedRef) {\n var _slots$root;\n const {\n anchorEl,\n children,\n direction,\n disablePortal,\n modifiers,\n open,\n placement: initialPlacement,\n popperOptions,\n popperRef: popperRefProp,\n slotProps = {},\n slots = {},\n TransitionProps\n // @ts-ignore internal logic\n // prevent from spreading to DOM, it can come from the parent component e.g. Select.\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const tooltipRef = React.useRef(null);\n const ownRef = useForkRef(tooltipRef, forwardedRef);\n const popperRef = React.useRef(null);\n const handlePopperRef = useForkRef(popperRef, popperRefProp);\n const handlePopperRefRef = React.useRef(handlePopperRef);\n useEnhancedEffect(() => {\n handlePopperRefRef.current = handlePopperRef;\n }, [handlePopperRef]);\n React.useImperativeHandle(popperRefProp, () => popperRef.current, []);\n const rtlPlacement = flipPlacement(initialPlacement, direction);\n /**\n * placement initialized from prop but can change during lifetime if modifiers.flip.\n * modifiers.flip is essentially a flip for controlled/uncontrolled behavior\n */\n const [placement, setPlacement] = React.useState(rtlPlacement);\n const [resolvedAnchorElement, setResolvedAnchorElement] = React.useState(resolveAnchorEl(anchorEl));\n React.useEffect(() => {\n if (popperRef.current) {\n popperRef.current.forceUpdate();\n }\n });\n React.useEffect(() => {\n if (anchorEl) {\n setResolvedAnchorElement(resolveAnchorEl(anchorEl));\n }\n }, [anchorEl]);\n useEnhancedEffect(() => {\n if (!resolvedAnchorElement || !open) {\n return undefined;\n }\n const handlePopperUpdate = data => {\n setPlacement(data.placement);\n };\n if (process.env.NODE_ENV !== 'production') {\n if (resolvedAnchorElement && isHTMLElement(resolvedAnchorElement) && resolvedAnchorElement.nodeType === 1) {\n const box = resolvedAnchorElement.getBoundingClientRect();\n if (process.env.NODE_ENV !== 'test' && box.top === 0 && box.left === 0 && box.right === 0 && box.bottom === 0) {\n console.warn(['MUI: The `anchorEl` prop provided to the component is invalid.', 'The anchor element should be part of the document layout.', \"Make sure the element is present in the document or that it's not display none.\"].join('\\n'));\n }\n }\n }\n let popperModifiers = [{\n name: 'preventOverflow',\n options: {\n altBoundary: disablePortal\n }\n }, {\n name: 'flip',\n options: {\n altBoundary: disablePortal\n }\n }, {\n name: 'onUpdate',\n enabled: true,\n phase: 'afterWrite',\n fn: ({\n state\n }) => {\n handlePopperUpdate(state);\n }\n }];\n if (modifiers != null) {\n popperModifiers = popperModifiers.concat(modifiers);\n }\n if (popperOptions && popperOptions.modifiers != null) {\n popperModifiers = popperModifiers.concat(popperOptions.modifiers);\n }\n const popper = createPopper(resolvedAnchorElement, tooltipRef.current, _extends({\n placement: rtlPlacement\n }, popperOptions, {\n modifiers: popperModifiers\n }));\n handlePopperRefRef.current(popper);\n return () => {\n popper.destroy();\n handlePopperRefRef.current(null);\n };\n }, [resolvedAnchorElement, disablePortal, modifiers, open, popperOptions, rtlPlacement]);\n const childProps = {\n placement: placement\n };\n if (TransitionProps !== null) {\n childProps.TransitionProps = TransitionProps;\n }\n const classes = useUtilityClasses();\n const Root = (_slots$root = slots.root) != null ? _slots$root : 'div';\n const rootProps = useSlotProps({\n elementType: Root,\n externalSlotProps: slotProps.root,\n externalForwardedProps: other,\n additionalProps: {\n role: 'tooltip',\n ref: ownRef\n },\n ownerState: props,\n className: classes.root\n });\n return /*#__PURE__*/_jsx(Root, _extends({}, rootProps, {\n children: typeof children === 'function' ? children(childProps) : children\n }));\n});\n\n/**\n * Poppers rely on the 3rd party library [Popper.js](https://popper.js.org/docs/v2/) for positioning.\n *\n * Demos:\n *\n * - [Popper](https://mui.com/base-ui/react-popper/)\n *\n * API:\n *\n * - [Popper API](https://mui.com/base-ui/react-popper/components-api/#popper)\n */\nconst Popper = /*#__PURE__*/React.forwardRef(function Popper(props, forwardedRef) {\n const {\n anchorEl,\n children,\n container: containerProp,\n direction = 'ltr',\n disablePortal = false,\n keepMounted = false,\n modifiers,\n open,\n placement = 'bottom',\n popperOptions = defaultPopperOptions,\n popperRef,\n style,\n transition = false,\n slotProps = {},\n slots = {}\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded2);\n const [exited, setExited] = React.useState(true);\n const handleEnter = () => {\n setExited(false);\n };\n const handleExited = () => {\n setExited(true);\n };\n if (!keepMounted && !open && (!transition || exited)) {\n return null;\n }\n\n // If the container prop is provided, use that\n // If the anchorEl prop is provided, use its parent body element as the container\n // If neither are provided let the Modal take care of choosing the container\n let container;\n if (containerProp) {\n container = containerProp;\n } else if (anchorEl) {\n const resolvedAnchorEl = resolveAnchorEl(anchorEl);\n container = resolvedAnchorEl && isHTMLElement(resolvedAnchorEl) ? ownerDocument(resolvedAnchorEl).body : ownerDocument(null).body;\n }\n const display = !open && keepMounted && (!transition || exited) ? 'none' : undefined;\n const transitionProps = transition ? {\n in: open,\n onEnter: handleEnter,\n onExited: handleExited\n } : undefined;\n return /*#__PURE__*/_jsx(Portal, {\n disablePortal: disablePortal,\n container: container,\n children: /*#__PURE__*/_jsx(PopperTooltip, _extends({\n anchorEl: anchorEl,\n direction: direction,\n disablePortal: disablePortal,\n modifiers: modifiers,\n ref: forwardedRef,\n open: transition ? !exited : open,\n placement: placement,\n popperOptions: popperOptions,\n popperRef: popperRef,\n slotProps: slotProps,\n slots: slots\n }, other, {\n style: _extends({\n // Prevents scroll issue, waiting for Popper.js to add this style once initiated.\n position: 'fixed',\n // Fix Popper.js display issue\n top: 0,\n left: 0,\n display\n }, style),\n TransitionProps: transitionProps,\n children: children\n }))\n });\n});\nprocess.env.NODE_ENV !== \"production\" ? Popper.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * An HTML element, [virtualElement](https://popper.js.org/docs/v2/virtual-elements/),\n * or a function that returns either.\n * It's used to set the position of the popper.\n * The return value will passed as the reference object of the Popper instance.\n */\n anchorEl: chainPropTypes(PropTypes.oneOfType([HTMLElementType, PropTypes.object, PropTypes.func]), props => {\n if (props.open) {\n const resolvedAnchorEl = resolveAnchorEl(props.anchorEl);\n if (resolvedAnchorEl && isHTMLElement(resolvedAnchorEl) && resolvedAnchorEl.nodeType === 1) {\n const box = resolvedAnchorEl.getBoundingClientRect();\n if (process.env.NODE_ENV !== 'test' && box.top === 0 && box.left === 0 && box.right === 0 && box.bottom === 0) {\n return new Error(['MUI: The `anchorEl` prop provided to the component is invalid.', 'The anchor element should be part of the document layout.', \"Make sure the element is present in the document or that it's not display none.\"].join('\\n'));\n }\n } else if (!resolvedAnchorEl || typeof resolvedAnchorEl.getBoundingClientRect !== 'function' || isVirtualElement(resolvedAnchorEl) && resolvedAnchorEl.contextElement != null && resolvedAnchorEl.contextElement.nodeType !== 1) {\n return new Error(['MUI: The `anchorEl` prop provided to the component is invalid.', 'It should be an HTML element instance or a virtualElement ', '(https://popper.js.org/docs/v2/virtual-elements/).'].join('\\n'));\n }\n }\n return null;\n }),\n /**\n * Popper render function or node.\n */\n children: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.node, PropTypes.func]),\n /**\n * An HTML element or function that returns one.\n * The `container` will have the portal children appended to it.\n *\n * You can also provide a callback, which is called in a React layout effect.\n * This lets you set the container from a ref, and also makes server-side rendering possible.\n *\n * By default, it uses the body of the top-level document object,\n * so it's simply `document.body` most of the time.\n */\n container: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.func]),\n /**\n * Direction of the text.\n * @default 'ltr'\n */\n direction: PropTypes.oneOf(['ltr', 'rtl']),\n /**\n * The `children` will be under the DOM hierarchy of the parent component.\n * @default false\n */\n disablePortal: PropTypes.bool,\n /**\n * Always keep the children in the DOM.\n * This prop can be useful in SEO situation or\n * when you want to maximize the responsiveness of the Popper.\n * @default false\n */\n keepMounted: PropTypes.bool,\n /**\n * Popper.js is based on a \"plugin-like\" architecture,\n * most of its features are fully encapsulated \"modifiers\".\n *\n * A modifier is a function that is called each time Popper.js needs to\n * compute the position of the popper.\n * For this reason, modifiers should be very performant to avoid bottlenecks.\n * To learn how to create a modifier, [read the modifiers documentation](https://popper.js.org/docs/v2/modifiers/).\n */\n modifiers: PropTypes.arrayOf(PropTypes.shape({\n data: PropTypes.object,\n effect: PropTypes.func,\n enabled: PropTypes.bool,\n fn: PropTypes.func,\n name: PropTypes.any,\n options: PropTypes.object,\n phase: PropTypes.oneOf(['afterMain', 'afterRead', 'afterWrite', 'beforeMain', 'beforeRead', 'beforeWrite', 'main', 'read', 'write']),\n requires: PropTypes.arrayOf(PropTypes.string),\n requiresIfExists: PropTypes.arrayOf(PropTypes.string)\n })),\n /**\n * If `true`, the component is shown.\n */\n open: PropTypes.bool.isRequired,\n /**\n * Popper placement.\n * @default 'bottom'\n */\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n /**\n * Options provided to the [`Popper.js`](https://popper.js.org/docs/v2/constructors/#options) instance.\n * @default {}\n */\n popperOptions: PropTypes.shape({\n modifiers: PropTypes.array,\n onFirstUpdate: PropTypes.func,\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n strategy: PropTypes.oneOf(['absolute', 'fixed'])\n }),\n /**\n * A ref that points to the used popper instance.\n */\n popperRef: refType,\n /**\n * The props used for each slot inside the Popper.\n * @default {}\n */\n slotProps: PropTypes.shape({\n root: PropTypes.oneOfType([PropTypes.func, PropTypes.object])\n }),\n /**\n * The components used for each slot inside the Popper.\n * Either a string to use a HTML element or a component.\n * @default {}\n */\n slots: PropTypes.shape({\n root: PropTypes.elementType\n }),\n /**\n * Help supporting a react-transition-group/Transition component.\n * @default false\n */\n transition: PropTypes.bool\n} : void 0;\nexport { Popper };","'use client';\n\nimport * as React from 'react';\nimport { useTheme as useThemeSystem } from '@mui/system';\nimport defaultTheme from './defaultTheme';\nimport THEME_ID from './identifier';\nexport default function useTheme() {\n const theme = useThemeSystem(defaultTheme);\n if (process.env.NODE_ENV !== 'production') {\n // eslint-disable-next-line react-hooks/rules-of-hooks\n React.useDebugValue(theme);\n }\n return theme[THEME_ID] || theme;\n}","export default function _setPrototypeOf(o, p) {\n _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function _setPrototypeOf(o, p) {\n o.__proto__ = p;\n return o;\n };\n return _setPrototypeOf(o, p);\n}","import setPrototypeOf from \"./setPrototypeOf.js\";\nexport default function _inheritsLoose(subClass, superClass) {\n subClass.prototype = Object.create(superClass.prototype);\n subClass.prototype.constructor = subClass;\n setPrototypeOf(subClass, superClass);\n}","export default {\n disabled: false\n};","import PropTypes from 'prop-types';\nexport var timeoutsShape = process.env.NODE_ENV !== 'production' ? PropTypes.oneOfType([PropTypes.number, PropTypes.shape({\n enter: PropTypes.number,\n exit: PropTypes.number,\n appear: PropTypes.number\n}).isRequired]) : null;\nexport var classNamesShape = process.env.NODE_ENV !== 'production' ? PropTypes.oneOfType([PropTypes.string, PropTypes.shape({\n enter: PropTypes.string,\n exit: PropTypes.string,\n active: PropTypes.string\n}), PropTypes.shape({\n enter: PropTypes.string,\n enterDone: PropTypes.string,\n enterActive: PropTypes.string,\n exit: PropTypes.string,\n exitDone: PropTypes.string,\n exitActive: PropTypes.string\n})]) : null;","import React from 'react';\nexport default React.createContext(null);","export var forceReflow = function forceReflow(node) {\n return node.scrollTop;\n};","import _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _inheritsLoose from \"@babel/runtime/helpers/esm/inheritsLoose\";\nimport PropTypes from 'prop-types';\nimport React from 'react';\nimport ReactDOM from 'react-dom';\nimport config from './config';\nimport { timeoutsShape } from './utils/PropTypes';\nimport TransitionGroupContext from './TransitionGroupContext';\nimport { forceReflow } from './utils/reflow';\nexport var UNMOUNTED = 'unmounted';\nexport var EXITED = 'exited';\nexport var ENTERING = 'entering';\nexport var ENTERED = 'entered';\nexport var EXITING = 'exiting';\n/**\n * The Transition component lets you describe a transition from one component\n * state to another _over time_ with a simple declarative API. Most commonly\n * it's used to animate the mounting and unmounting of a component, but can also\n * be used to describe in-place transition states as well.\n *\n * ---\n *\n * **Note**: `Transition` is a platform-agnostic base component. If you're using\n * transitions in CSS, you'll probably want to use\n * [`CSSTransition`](https://reactcommunity.org/react-transition-group/css-transition)\n * instead. It inherits all the features of `Transition`, but contains\n * additional features necessary to play nice with CSS transitions (hence the\n * name of the component).\n *\n * ---\n *\n * By default the `Transition` component does not alter the behavior of the\n * component it renders, it only tracks \"enter\" and \"exit\" states for the\n * components. It's up to you to give meaning and effect to those states. For\n * example we can add styles to a component when it enters or exits:\n *\n * ```jsx\n * import { Transition } from 'react-transition-group';\n *\n * const duration = 300;\n *\n * const defaultStyle = {\n * transition: `opacity ${duration}ms ease-in-out`,\n * opacity: 0,\n * }\n *\n * const transitionStyles = {\n * entering: { opacity: 1 },\n * entered: { opacity: 1 },\n * exiting: { opacity: 0 },\n * exited: { opacity: 0 },\n * };\n *\n * const Fade = ({ in: inProp }) => (\n * \n * {state => (\n *
    \n * I'm a fade Transition!\n *
    \n * )}\n *
    \n * );\n * ```\n *\n * There are 4 main states a Transition can be in:\n * - `'entering'`\n * - `'entered'`\n * - `'exiting'`\n * - `'exited'`\n *\n * Transition state is toggled via the `in` prop. When `true` the component\n * begins the \"Enter\" stage. During this stage, the component will shift from\n * its current transition state, to `'entering'` for the duration of the\n * transition and then to the `'entered'` stage once it's complete. Let's take\n * the following example (we'll use the\n * [useState](https://reactjs.org/docs/hooks-reference.html#usestate) hook):\n *\n * ```jsx\n * function App() {\n * const [inProp, setInProp] = useState(false);\n * return (\n *
    \n * \n * {state => (\n * // ...\n * )}\n * \n * \n *
    \n * );\n * }\n * ```\n *\n * When the button is clicked the component will shift to the `'entering'` state\n * and stay there for 500ms (the value of `timeout`) before it finally switches\n * to `'entered'`.\n *\n * When `in` is `false` the same thing happens except the state moves from\n * `'exiting'` to `'exited'`.\n */\n\nvar Transition = /*#__PURE__*/function (_React$Component) {\n _inheritsLoose(Transition, _React$Component);\n\n function Transition(props, context) {\n var _this;\n\n _this = _React$Component.call(this, props, context) || this;\n var parentGroup = context; // In the context of a TransitionGroup all enters are really appears\n\n var appear = parentGroup && !parentGroup.isMounting ? props.enter : props.appear;\n var initialStatus;\n _this.appearStatus = null;\n\n if (props.in) {\n if (appear) {\n initialStatus = EXITED;\n _this.appearStatus = ENTERING;\n } else {\n initialStatus = ENTERED;\n }\n } else {\n if (props.unmountOnExit || props.mountOnEnter) {\n initialStatus = UNMOUNTED;\n } else {\n initialStatus = EXITED;\n }\n }\n\n _this.state = {\n status: initialStatus\n };\n _this.nextCallback = null;\n return _this;\n }\n\n Transition.getDerivedStateFromProps = function getDerivedStateFromProps(_ref, prevState) {\n var nextIn = _ref.in;\n\n if (nextIn && prevState.status === UNMOUNTED) {\n return {\n status: EXITED\n };\n }\n\n return null;\n } // getSnapshotBeforeUpdate(prevProps) {\n // let nextStatus = null\n // if (prevProps !== this.props) {\n // const { status } = this.state\n // if (this.props.in) {\n // if (status !== ENTERING && status !== ENTERED) {\n // nextStatus = ENTERING\n // }\n // } else {\n // if (status === ENTERING || status === ENTERED) {\n // nextStatus = EXITING\n // }\n // }\n // }\n // return { nextStatus }\n // }\n ;\n\n var _proto = Transition.prototype;\n\n _proto.componentDidMount = function componentDidMount() {\n this.updateStatus(true, this.appearStatus);\n };\n\n _proto.componentDidUpdate = function componentDidUpdate(prevProps) {\n var nextStatus = null;\n\n if (prevProps !== this.props) {\n var status = this.state.status;\n\n if (this.props.in) {\n if (status !== ENTERING && status !== ENTERED) {\n nextStatus = ENTERING;\n }\n } else {\n if (status === ENTERING || status === ENTERED) {\n nextStatus = EXITING;\n }\n }\n }\n\n this.updateStatus(false, nextStatus);\n };\n\n _proto.componentWillUnmount = function componentWillUnmount() {\n this.cancelNextCallback();\n };\n\n _proto.getTimeouts = function getTimeouts() {\n var timeout = this.props.timeout;\n var exit, enter, appear;\n exit = enter = appear = timeout;\n\n if (timeout != null && typeof timeout !== 'number') {\n exit = timeout.exit;\n enter = timeout.enter; // TODO: remove fallback for next major\n\n appear = timeout.appear !== undefined ? timeout.appear : enter;\n }\n\n return {\n exit: exit,\n enter: enter,\n appear: appear\n };\n };\n\n _proto.updateStatus = function updateStatus(mounting, nextStatus) {\n if (mounting === void 0) {\n mounting = false;\n }\n\n if (nextStatus !== null) {\n // nextStatus will always be ENTERING or EXITING.\n this.cancelNextCallback();\n\n if (nextStatus === ENTERING) {\n if (this.props.unmountOnExit || this.props.mountOnEnter) {\n var node = this.props.nodeRef ? this.props.nodeRef.current : ReactDOM.findDOMNode(this); // https://github.com/reactjs/react-transition-group/pull/749\n // With unmountOnExit or mountOnEnter, the enter animation should happen at the transition between `exited` and `entering`.\n // To make the animation happen, we have to separate each rendering and avoid being processed as batched.\n\n if (node) forceReflow(node);\n }\n\n this.performEnter(mounting);\n } else {\n this.performExit();\n }\n } else if (this.props.unmountOnExit && this.state.status === EXITED) {\n this.setState({\n status: UNMOUNTED\n });\n }\n };\n\n _proto.performEnter = function performEnter(mounting) {\n var _this2 = this;\n\n var enter = this.props.enter;\n var appearing = this.context ? this.context.isMounting : mounting;\n\n var _ref2 = this.props.nodeRef ? [appearing] : [ReactDOM.findDOMNode(this), appearing],\n maybeNode = _ref2[0],\n maybeAppearing = _ref2[1];\n\n var timeouts = this.getTimeouts();\n var enterTimeout = appearing ? timeouts.appear : timeouts.enter; // no enter animation skip right to ENTERED\n // if we are mounting and running this it means appear _must_ be set\n\n if (!mounting && !enter || config.disabled) {\n this.safeSetState({\n status: ENTERED\n }, function () {\n _this2.props.onEntered(maybeNode);\n });\n return;\n }\n\n this.props.onEnter(maybeNode, maybeAppearing);\n this.safeSetState({\n status: ENTERING\n }, function () {\n _this2.props.onEntering(maybeNode, maybeAppearing);\n\n _this2.onTransitionEnd(enterTimeout, function () {\n _this2.safeSetState({\n status: ENTERED\n }, function () {\n _this2.props.onEntered(maybeNode, maybeAppearing);\n });\n });\n });\n };\n\n _proto.performExit = function performExit() {\n var _this3 = this;\n\n var exit = this.props.exit;\n var timeouts = this.getTimeouts();\n var maybeNode = this.props.nodeRef ? undefined : ReactDOM.findDOMNode(this); // no exit animation skip right to EXITED\n\n if (!exit || config.disabled) {\n this.safeSetState({\n status: EXITED\n }, function () {\n _this3.props.onExited(maybeNode);\n });\n return;\n }\n\n this.props.onExit(maybeNode);\n this.safeSetState({\n status: EXITING\n }, function () {\n _this3.props.onExiting(maybeNode);\n\n _this3.onTransitionEnd(timeouts.exit, function () {\n _this3.safeSetState({\n status: EXITED\n }, function () {\n _this3.props.onExited(maybeNode);\n });\n });\n });\n };\n\n _proto.cancelNextCallback = function cancelNextCallback() {\n if (this.nextCallback !== null) {\n this.nextCallback.cancel();\n this.nextCallback = null;\n }\n };\n\n _proto.safeSetState = function safeSetState(nextState, callback) {\n // This shouldn't be necessary, but there are weird race conditions with\n // setState callbacks and unmounting in testing, so always make sure that\n // we can cancel any pending setState callbacks after we unmount.\n callback = this.setNextCallback(callback);\n this.setState(nextState, callback);\n };\n\n _proto.setNextCallback = function setNextCallback(callback) {\n var _this4 = this;\n\n var active = true;\n\n this.nextCallback = function (event) {\n if (active) {\n active = false;\n _this4.nextCallback = null;\n callback(event);\n }\n };\n\n this.nextCallback.cancel = function () {\n active = false;\n };\n\n return this.nextCallback;\n };\n\n _proto.onTransitionEnd = function onTransitionEnd(timeout, handler) {\n this.setNextCallback(handler);\n var node = this.props.nodeRef ? this.props.nodeRef.current : ReactDOM.findDOMNode(this);\n var doesNotHaveTimeoutOrListener = timeout == null && !this.props.addEndListener;\n\n if (!node || doesNotHaveTimeoutOrListener) {\n setTimeout(this.nextCallback, 0);\n return;\n }\n\n if (this.props.addEndListener) {\n var _ref3 = this.props.nodeRef ? [this.nextCallback] : [node, this.nextCallback],\n maybeNode = _ref3[0],\n maybeNextCallback = _ref3[1];\n\n this.props.addEndListener(maybeNode, maybeNextCallback);\n }\n\n if (timeout != null) {\n setTimeout(this.nextCallback, timeout);\n }\n };\n\n _proto.render = function render() {\n var status = this.state.status;\n\n if (status === UNMOUNTED) {\n return null;\n }\n\n var _this$props = this.props,\n children = _this$props.children,\n _in = _this$props.in,\n _mountOnEnter = _this$props.mountOnEnter,\n _unmountOnExit = _this$props.unmountOnExit,\n _appear = _this$props.appear,\n _enter = _this$props.enter,\n _exit = _this$props.exit,\n _timeout = _this$props.timeout,\n _addEndListener = _this$props.addEndListener,\n _onEnter = _this$props.onEnter,\n _onEntering = _this$props.onEntering,\n _onEntered = _this$props.onEntered,\n _onExit = _this$props.onExit,\n _onExiting = _this$props.onExiting,\n _onExited = _this$props.onExited,\n _nodeRef = _this$props.nodeRef,\n childProps = _objectWithoutPropertiesLoose(_this$props, [\"children\", \"in\", \"mountOnEnter\", \"unmountOnExit\", \"appear\", \"enter\", \"exit\", \"timeout\", \"addEndListener\", \"onEnter\", \"onEntering\", \"onEntered\", \"onExit\", \"onExiting\", \"onExited\", \"nodeRef\"]);\n\n return (\n /*#__PURE__*/\n // allows for nested Transitions\n React.createElement(TransitionGroupContext.Provider, {\n value: null\n }, typeof children === 'function' ? children(status, childProps) : React.cloneElement(React.Children.only(children), childProps))\n );\n };\n\n return Transition;\n}(React.Component);\n\nTransition.contextType = TransitionGroupContext;\nTransition.propTypes = process.env.NODE_ENV !== \"production\" ? {\n /**\n * A React reference to DOM element that need to transition:\n * https://stackoverflow.com/a/51127130/4671932\n *\n * - When `nodeRef` prop is used, `node` is not passed to callback functions\n * (e.g. `onEnter`) because user already has direct access to the node.\n * - When changing `key` prop of `Transition` in a `TransitionGroup` a new\n * `nodeRef` need to be provided to `Transition` with changed `key` prop\n * (see\n * [test/CSSTransition-test.js](https://github.com/reactjs/react-transition-group/blob/13435f897b3ab71f6e19d724f145596f5910581c/test/CSSTransition-test.js#L362-L437)).\n */\n nodeRef: PropTypes.shape({\n current: typeof Element === 'undefined' ? PropTypes.any : function (propValue, key, componentName, location, propFullName, secret) {\n var value = propValue[key];\n return PropTypes.instanceOf(value && 'ownerDocument' in value ? value.ownerDocument.defaultView.Element : Element)(propValue, key, componentName, location, propFullName, secret);\n }\n }),\n\n /**\n * A `function` child can be used instead of a React element. This function is\n * called with the current transition status (`'entering'`, `'entered'`,\n * `'exiting'`, `'exited'`), which can be used to apply context\n * specific props to a component.\n *\n * ```jsx\n * \n * {state => (\n * \n * )}\n * \n * ```\n */\n children: PropTypes.oneOfType([PropTypes.func.isRequired, PropTypes.element.isRequired]).isRequired,\n\n /**\n * Show the component; triggers the enter or exit states\n */\n in: PropTypes.bool,\n\n /**\n * By default the child component is mounted immediately along with\n * the parent `Transition` component. If you want to \"lazy mount\" the component on the\n * first `in={true}` you can set `mountOnEnter`. After the first enter transition the component will stay\n * mounted, even on \"exited\", unless you also specify `unmountOnExit`.\n */\n mountOnEnter: PropTypes.bool,\n\n /**\n * By default the child component stays mounted after it reaches the `'exited'` state.\n * Set `unmountOnExit` if you'd prefer to unmount the component after it finishes exiting.\n */\n unmountOnExit: PropTypes.bool,\n\n /**\n * By default the child component does not perform the enter transition when\n * it first mounts, regardless of the value of `in`. If you want this\n * behavior, set both `appear` and `in` to `true`.\n *\n * > **Note**: there are no special appear states like `appearing`/`appeared`, this prop\n * > only adds an additional enter transition. However, in the\n * > `` component that first enter transition does result in\n * > additional `.appear-*` classes, that way you can choose to style it\n * > differently.\n */\n appear: PropTypes.bool,\n\n /**\n * Enable or disable enter transitions.\n */\n enter: PropTypes.bool,\n\n /**\n * Enable or disable exit transitions.\n */\n exit: PropTypes.bool,\n\n /**\n * The duration of the transition, in milliseconds.\n * Required unless `addEndListener` is provided.\n *\n * You may specify a single timeout for all transitions:\n *\n * ```jsx\n * timeout={500}\n * ```\n *\n * or individually:\n *\n * ```jsx\n * timeout={{\n * appear: 500,\n * enter: 300,\n * exit: 500,\n * }}\n * ```\n *\n * - `appear` defaults to the value of `enter`\n * - `enter` defaults to `0`\n * - `exit` defaults to `0`\n *\n * @type {number | { enter?: number, exit?: number, appear?: number }}\n */\n timeout: function timeout(props) {\n var pt = timeoutsShape;\n if (!props.addEndListener) pt = pt.isRequired;\n\n for (var _len = arguments.length, args = new Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) {\n args[_key - 1] = arguments[_key];\n }\n\n return pt.apply(void 0, [props].concat(args));\n },\n\n /**\n * Add a custom transition end trigger. Called with the transitioning\n * DOM node and a `done` callback. Allows for more fine grained transition end\n * logic. Timeouts are still used as a fallback if provided.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * ```jsx\n * addEndListener={(node, done) => {\n * // use the css transitionend event to mark the finish of a transition\n * node.addEventListener('transitionend', done, false);\n * }}\n * ```\n */\n addEndListener: PropTypes.func,\n\n /**\n * Callback fired before the \"entering\" status is applied. An extra parameter\n * `isAppearing` is supplied to indicate if the enter stage is occurring on the initial mount\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement, isAppearing: bool) -> void\n */\n onEnter: PropTypes.func,\n\n /**\n * Callback fired after the \"entering\" status is applied. An extra parameter\n * `isAppearing` is supplied to indicate if the enter stage is occurring on the initial mount\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement, isAppearing: bool)\n */\n onEntering: PropTypes.func,\n\n /**\n * Callback fired after the \"entered\" status is applied. An extra parameter\n * `isAppearing` is supplied to indicate if the enter stage is occurring on the initial mount\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement, isAppearing: bool) -> void\n */\n onEntered: PropTypes.func,\n\n /**\n * Callback fired before the \"exiting\" status is applied.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement) -> void\n */\n onExit: PropTypes.func,\n\n /**\n * Callback fired after the \"exiting\" status is applied.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement) -> void\n */\n onExiting: PropTypes.func,\n\n /**\n * Callback fired after the \"exited\" status is applied.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed\n *\n * @type Function(node: HtmlElement) -> void\n */\n onExited: PropTypes.func\n} : {}; // Name the function so it is clearer in the documentation\n\nfunction noop() {}\n\nTransition.defaultProps = {\n in: false,\n mountOnEnter: false,\n unmountOnExit: false,\n appear: false,\n enter: true,\n exit: true,\n onEnter: noop,\n onEntering: noop,\n onEntered: noop,\n onExit: noop,\n onExiting: noop,\n onExited: noop\n};\nTransition.UNMOUNTED = UNMOUNTED;\nTransition.EXITED = EXITED;\nTransition.ENTERING = ENTERING;\nTransition.ENTERED = ENTERED;\nTransition.EXITING = EXITING;\nexport default Transition;","export const reflow = node => node.scrollTop;\nexport function getTransitionProps(props, options) {\n var _style$transitionDura, _style$transitionTimi;\n const {\n timeout,\n easing,\n style = {}\n } = props;\n return {\n duration: (_style$transitionDura = style.transitionDuration) != null ? _style$transitionDura : typeof timeout === 'number' ? timeout : timeout[options.mode] || 0,\n easing: (_style$transitionTimi = style.transitionTimingFunction) != null ? _style$transitionTimi : typeof easing === 'object' ? easing[options.mode] : easing,\n delay: style.transitionDelay\n };\n}","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"addEndListener\", \"appear\", \"children\", \"easing\", \"in\", \"onEnter\", \"onEntered\", \"onEntering\", \"onExit\", \"onExited\", \"onExiting\", \"style\", \"timeout\", \"TransitionComponent\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport { elementAcceptingRef, unstable_useTimeout as useTimeout } from '@mui/utils';\nimport { Transition } from 'react-transition-group';\nimport useTheme from '../styles/useTheme';\nimport { getTransitionProps, reflow } from '../transitions/utils';\nimport useForkRef from '../utils/useForkRef';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nfunction getScale(value) {\n return `scale(${value}, ${value ** 2})`;\n}\nconst styles = {\n entering: {\n opacity: 1,\n transform: getScale(1)\n },\n entered: {\n opacity: 1,\n transform: 'none'\n }\n};\n\n/*\n TODO v6: remove\n Conditionally apply a workaround for the CSS transition bug in Safari 15.4 / WebKit browsers.\n */\nconst isWebKit154 = typeof navigator !== 'undefined' && /^((?!chrome|android).)*(safari|mobile)/i.test(navigator.userAgent) && /(os |version\\/)15(.|_)4/i.test(navigator.userAgent);\n\n/**\n * The Grow transition is used by the [Tooltip](/material-ui/react-tooltip/) and\n * [Popover](/material-ui/react-popover/) components.\n * It uses [react-transition-group](https://github.com/reactjs/react-transition-group) internally.\n */\nconst Grow = /*#__PURE__*/React.forwardRef(function Grow(props, ref) {\n const {\n addEndListener,\n appear = true,\n children,\n easing,\n in: inProp,\n onEnter,\n onEntered,\n onEntering,\n onExit,\n onExited,\n onExiting,\n style,\n timeout = 'auto',\n // eslint-disable-next-line react/prop-types\n TransitionComponent = Transition\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const timer = useTimeout();\n const autoTimeout = React.useRef();\n const theme = useTheme();\n const nodeRef = React.useRef(null);\n const handleRef = useForkRef(nodeRef, children.ref, ref);\n const normalizedTransitionCallback = callback => maybeIsAppearing => {\n if (callback) {\n const node = nodeRef.current;\n\n // onEnterXxx and onExitXxx callbacks have a different arguments.length value.\n if (maybeIsAppearing === undefined) {\n callback(node);\n } else {\n callback(node, maybeIsAppearing);\n }\n }\n };\n const handleEntering = normalizedTransitionCallback(onEntering);\n const handleEnter = normalizedTransitionCallback((node, isAppearing) => {\n reflow(node); // So the animation always start from the start.\n\n const {\n duration: transitionDuration,\n delay,\n easing: transitionTimingFunction\n } = getTransitionProps({\n style,\n timeout,\n easing\n }, {\n mode: 'enter'\n });\n let duration;\n if (timeout === 'auto') {\n duration = theme.transitions.getAutoHeightDuration(node.clientHeight);\n autoTimeout.current = duration;\n } else {\n duration = transitionDuration;\n }\n node.style.transition = [theme.transitions.create('opacity', {\n duration,\n delay\n }), theme.transitions.create('transform', {\n duration: isWebKit154 ? duration : duration * 0.666,\n delay,\n easing: transitionTimingFunction\n })].join(',');\n if (onEnter) {\n onEnter(node, isAppearing);\n }\n });\n const handleEntered = normalizedTransitionCallback(onEntered);\n const handleExiting = normalizedTransitionCallback(onExiting);\n const handleExit = normalizedTransitionCallback(node => {\n const {\n duration: transitionDuration,\n delay,\n easing: transitionTimingFunction\n } = getTransitionProps({\n style,\n timeout,\n easing\n }, {\n mode: 'exit'\n });\n let duration;\n if (timeout === 'auto') {\n duration = theme.transitions.getAutoHeightDuration(node.clientHeight);\n autoTimeout.current = duration;\n } else {\n duration = transitionDuration;\n }\n node.style.transition = [theme.transitions.create('opacity', {\n duration,\n delay\n }), theme.transitions.create('transform', {\n duration: isWebKit154 ? duration : duration * 0.666,\n delay: isWebKit154 ? delay : delay || duration * 0.333,\n easing: transitionTimingFunction\n })].join(',');\n node.style.opacity = 0;\n node.style.transform = getScale(0.75);\n if (onExit) {\n onExit(node);\n }\n });\n const handleExited = normalizedTransitionCallback(onExited);\n const handleAddEndListener = next => {\n if (timeout === 'auto') {\n timer.start(autoTimeout.current || 0, next);\n }\n if (addEndListener) {\n // Old call signature before `react-transition-group` implemented `nodeRef`\n addEndListener(nodeRef.current, next);\n }\n };\n return /*#__PURE__*/_jsx(TransitionComponent, _extends({\n appear: appear,\n in: inProp,\n nodeRef: nodeRef,\n onEnter: handleEnter,\n onEntered: handleEntered,\n onEntering: handleEntering,\n onExit: handleExit,\n onExited: handleExited,\n onExiting: handleExiting,\n addEndListener: handleAddEndListener,\n timeout: timeout === 'auto' ? null : timeout\n }, other, {\n children: (state, childProps) => {\n return /*#__PURE__*/React.cloneElement(children, _extends({\n style: _extends({\n opacity: 0,\n transform: getScale(0.75),\n visibility: state === 'exited' && !inProp ? 'hidden' : undefined\n }, styles[state], style, children.props.style),\n ref: handleRef\n }, childProps));\n }\n }));\n});\nprocess.env.NODE_ENV !== \"production\" ? Grow.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the d.ts file and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * Add a custom transition end trigger. Called with the transitioning DOM\n * node and a done callback. Allows for more fine grained transition end\n * logic. Note: Timeouts are still used as a fallback if provided.\n */\n addEndListener: PropTypes.func,\n /**\n * Perform the enter transition when it first mounts if `in` is also `true`.\n * Set this to `false` to disable this behavior.\n * @default true\n */\n appear: PropTypes.bool,\n /**\n * A single child content element.\n */\n children: elementAcceptingRef.isRequired,\n /**\n * The transition timing function.\n * You may specify a single easing or a object containing enter and exit values.\n */\n easing: PropTypes.oneOfType([PropTypes.shape({\n enter: PropTypes.string,\n exit: PropTypes.string\n }), PropTypes.string]),\n /**\n * If `true`, the component will transition in.\n */\n in: PropTypes.bool,\n /**\n * @ignore\n */\n onEnter: PropTypes.func,\n /**\n * @ignore\n */\n onEntered: PropTypes.func,\n /**\n * @ignore\n */\n onEntering: PropTypes.func,\n /**\n * @ignore\n */\n onExit: PropTypes.func,\n /**\n * @ignore\n */\n onExited: PropTypes.func,\n /**\n * @ignore\n */\n onExiting: PropTypes.func,\n /**\n * @ignore\n */\n style: PropTypes.object,\n /**\n * The duration for the transition, in milliseconds.\n * You may specify a single timeout for all transitions, or individually with an object.\n *\n * Set to 'auto' to automatically calculate transition time based on height.\n * @default 'auto'\n */\n timeout: PropTypes.oneOfType([PropTypes.oneOf(['auto']), PropTypes.number, PropTypes.shape({\n appear: PropTypes.number,\n enter: PropTypes.number,\n exit: PropTypes.number\n })])\n} : void 0;\nGrow.muiSupportAuto = true;\nexport default Grow;","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"anchorEl\", \"component\", \"components\", \"componentsProps\", \"container\", \"disablePortal\", \"keepMounted\", \"modifiers\", \"open\", \"placement\", \"popperOptions\", \"popperRef\", \"transition\", \"slots\", \"slotProps\"];\nimport { Popper as BasePopper } from '@mui/base/Popper';\nimport { useThemeWithoutDefault as useTheme } from '@mui/system';\nimport { HTMLElementType, refType } from '@mui/utils';\nimport PropTypes from 'prop-types';\nimport * as React from 'react';\nimport { styled, useThemeProps } from '../styles';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nconst PopperRoot = styled(BasePopper, {\n name: 'MuiPopper',\n slot: 'Root',\n overridesResolver: (props, styles) => styles.root\n})({});\n\n/**\n *\n * Demos:\n *\n * - [Autocomplete](https://mui.com/material-ui/react-autocomplete/)\n * - [Menu](https://mui.com/material-ui/react-menu/)\n * - [Popper](https://mui.com/material-ui/react-popper/)\n *\n * API:\n *\n * - [Popper API](https://mui.com/material-ui/api/popper/)\n */\nconst Popper = /*#__PURE__*/React.forwardRef(function Popper(inProps, ref) {\n var _slots$root;\n const theme = useTheme();\n const props = useThemeProps({\n props: inProps,\n name: 'MuiPopper'\n });\n const {\n anchorEl,\n component,\n components,\n componentsProps,\n container,\n disablePortal,\n keepMounted,\n modifiers,\n open,\n placement,\n popperOptions,\n popperRef,\n transition,\n slots,\n slotProps\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const RootComponent = (_slots$root = slots == null ? void 0 : slots.root) != null ? _slots$root : components == null ? void 0 : components.Root;\n const otherProps = _extends({\n anchorEl,\n container,\n disablePortal,\n keepMounted,\n modifiers,\n open,\n placement,\n popperOptions,\n popperRef,\n transition\n }, other);\n return /*#__PURE__*/_jsx(PopperRoot, _extends({\n as: component,\n direction: theme == null ? void 0 : theme.direction,\n slots: {\n root: RootComponent\n },\n slotProps: slotProps != null ? slotProps : componentsProps\n }, otherProps, {\n ref: ref\n }));\n});\nprocess.env.NODE_ENV !== \"production\" ? Popper.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * An HTML element, [virtualElement](https://popper.js.org/docs/v2/virtual-elements/),\n * or a function that returns either.\n * It's used to set the position of the popper.\n * The return value will passed as the reference object of the Popper instance.\n */\n anchorEl: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.object, PropTypes.func]),\n /**\n * Popper render function or node.\n */\n children: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.node, PropTypes.func]),\n /**\n * The component used for the root node.\n * Either a string to use a HTML element or a component.\n */\n component: PropTypes.elementType,\n /**\n * The components used for each slot inside the Popper.\n * Either a string to use a HTML element or a component.\n * @default {}\n */\n components: PropTypes.shape({\n Root: PropTypes.elementType\n }),\n /**\n * The props used for each slot inside the Popper.\n * @default {}\n */\n componentsProps: PropTypes.shape({\n root: PropTypes.oneOfType([PropTypes.func, PropTypes.object])\n }),\n /**\n * An HTML element or function that returns one.\n * The `container` will have the portal children appended to it.\n *\n * You can also provide a callback, which is called in a React layout effect.\n * This lets you set the container from a ref, and also makes server-side rendering possible.\n *\n * By default, it uses the body of the top-level document object,\n * so it's simply `document.body` most of the time.\n */\n container: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.func]),\n /**\n * The `children` will be under the DOM hierarchy of the parent component.\n * @default false\n */\n disablePortal: PropTypes.bool,\n /**\n * Always keep the children in the DOM.\n * This prop can be useful in SEO situation or\n * when you want to maximize the responsiveness of the Popper.\n * @default false\n */\n keepMounted: PropTypes.bool,\n /**\n * Popper.js is based on a \"plugin-like\" architecture,\n * most of its features are fully encapsulated \"modifiers\".\n *\n * A modifier is a function that is called each time Popper.js needs to\n * compute the position of the popper.\n * For this reason, modifiers should be very performant to avoid bottlenecks.\n * To learn how to create a modifier, [read the modifiers documentation](https://popper.js.org/docs/v2/modifiers/).\n */\n modifiers: PropTypes.arrayOf(PropTypes.shape({\n data: PropTypes.object,\n effect: PropTypes.func,\n enabled: PropTypes.bool,\n fn: PropTypes.func,\n name: PropTypes.any,\n options: PropTypes.object,\n phase: PropTypes.oneOf(['afterMain', 'afterRead', 'afterWrite', 'beforeMain', 'beforeRead', 'beforeWrite', 'main', 'read', 'write']),\n requires: PropTypes.arrayOf(PropTypes.string),\n requiresIfExists: PropTypes.arrayOf(PropTypes.string)\n })),\n /**\n * If `true`, the component is shown.\n */\n open: PropTypes.bool.isRequired,\n /**\n * Popper placement.\n * @default 'bottom'\n */\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n /**\n * Options provided to the [`Popper.js`](https://popper.js.org/docs/v2/constructors/#options) instance.\n * @default {}\n */\n popperOptions: PropTypes.shape({\n modifiers: PropTypes.array,\n onFirstUpdate: PropTypes.func,\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n strategy: PropTypes.oneOf(['absolute', 'fixed'])\n }),\n /**\n * A ref that points to the used popper instance.\n */\n popperRef: refType,\n /**\n * The props used for each slot inside the Popper.\n * @default {}\n */\n slotProps: PropTypes.shape({\n root: PropTypes.oneOfType([PropTypes.func, PropTypes.object])\n }),\n /**\n * The components used for each slot inside the Popper.\n * Either a string to use a HTML element or a component.\n * @default {}\n */\n slots: PropTypes.shape({\n root: PropTypes.elementType\n }),\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Help supporting a react-transition-group/Transition component.\n * @default false\n */\n transition: PropTypes.bool\n} : void 0;\nexport default Popper;","import generateUtilityClasses from '@mui/utils/generateUtilityClasses';\nimport generateUtilityClass from '@mui/utils/generateUtilityClass';\nexport function getTooltipUtilityClass(slot) {\n return generateUtilityClass('MuiTooltip', slot);\n}\nconst tooltipClasses = generateUtilityClasses('MuiTooltip', ['popper', 'popperInteractive', 'popperArrow', 'popperClose', 'tooltip', 'tooltipArrow', 'touch', 'tooltipPlacementLeft', 'tooltipPlacementRight', 'tooltipPlacementTop', 'tooltipPlacementBottom', 'arrow']);\nexport default tooltipClasses;","'use client';\n\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nconst _excluded = [\"arrow\", \"children\", \"classes\", \"components\", \"componentsProps\", \"describeChild\", \"disableFocusListener\", \"disableHoverListener\", \"disableInteractive\", \"disableTouchListener\", \"enterDelay\", \"enterNextDelay\", \"enterTouchDelay\", \"followCursor\", \"id\", \"leaveDelay\", \"leaveTouchDelay\", \"onClose\", \"onOpen\", \"open\", \"placement\", \"PopperComponent\", \"PopperProps\", \"slotProps\", \"slots\", \"title\", \"TransitionComponent\", \"TransitionProps\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport clsx from 'clsx';\nimport { elementAcceptingRef, unstable_useTimeout as useTimeout, unstable_Timeout as Timeout } from '@mui/utils';\nimport { unstable_composeClasses as composeClasses, appendOwnerState } from '@mui/base';\nimport { alpha } from '@mui/system';\nimport styled from '../styles/styled';\nimport useTheme from '../styles/useTheme';\nimport useThemeProps from '../styles/useThemeProps';\nimport capitalize from '../utils/capitalize';\nimport Grow from '../Grow';\nimport Popper from '../Popper';\nimport useEventCallback from '../utils/useEventCallback';\nimport useForkRef from '../utils/useForkRef';\nimport useId from '../utils/useId';\nimport useIsFocusVisible from '../utils/useIsFocusVisible';\nimport useControlled from '../utils/useControlled';\nimport tooltipClasses, { getTooltipUtilityClass } from './tooltipClasses';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nimport { jsxs as _jsxs } from \"react/jsx-runtime\";\nfunction round(value) {\n return Math.round(value * 1e5) / 1e5;\n}\nconst useUtilityClasses = ownerState => {\n const {\n classes,\n disableInteractive,\n arrow,\n touch,\n placement\n } = ownerState;\n const slots = {\n popper: ['popper', !disableInteractive && 'popperInteractive', arrow && 'popperArrow'],\n tooltip: ['tooltip', arrow && 'tooltipArrow', touch && 'touch', `tooltipPlacement${capitalize(placement.split('-')[0])}`],\n arrow: ['arrow']\n };\n return composeClasses(slots, getTooltipUtilityClass, classes);\n};\nconst TooltipPopper = styled(Popper, {\n name: 'MuiTooltip',\n slot: 'Popper',\n overridesResolver: (props, styles) => {\n const {\n ownerState\n } = props;\n return [styles.popper, !ownerState.disableInteractive && styles.popperInteractive, ownerState.arrow && styles.popperArrow, !ownerState.open && styles.popperClose];\n }\n})(({\n theme,\n ownerState,\n open\n}) => _extends({\n zIndex: (theme.vars || theme).zIndex.tooltip,\n pointerEvents: 'none'\n}, !ownerState.disableInteractive && {\n pointerEvents: 'auto'\n}, !open && {\n pointerEvents: 'none'\n}, ownerState.arrow && {\n [`&[data-popper-placement*=\"bottom\"] .${tooltipClasses.arrow}`]: {\n top: 0,\n marginTop: '-0.71em',\n '&::before': {\n transformOrigin: '0 100%'\n }\n },\n [`&[data-popper-placement*=\"top\"] .${tooltipClasses.arrow}`]: {\n bottom: 0,\n marginBottom: '-0.71em',\n '&::before': {\n transformOrigin: '100% 0'\n }\n },\n [`&[data-popper-placement*=\"right\"] .${tooltipClasses.arrow}`]: _extends({}, !ownerState.isRtl ? {\n left: 0,\n marginLeft: '-0.71em'\n } : {\n right: 0,\n marginRight: '-0.71em'\n }, {\n height: '1em',\n width: '0.71em',\n '&::before': {\n transformOrigin: '100% 100%'\n }\n }),\n [`&[data-popper-placement*=\"left\"] .${tooltipClasses.arrow}`]: _extends({}, !ownerState.isRtl ? {\n right: 0,\n marginRight: '-0.71em'\n } : {\n left: 0,\n marginLeft: '-0.71em'\n }, {\n height: '1em',\n width: '0.71em',\n '&::before': {\n transformOrigin: '0 0'\n }\n })\n}));\nconst TooltipTooltip = styled('div', {\n name: 'MuiTooltip',\n slot: 'Tooltip',\n overridesResolver: (props, styles) => {\n const {\n ownerState\n } = props;\n return [styles.tooltip, ownerState.touch && styles.touch, ownerState.arrow && styles.tooltipArrow, styles[`tooltipPlacement${capitalize(ownerState.placement.split('-')[0])}`]];\n }\n})(({\n theme,\n ownerState\n}) => _extends({\n backgroundColor: theme.vars ? theme.vars.palette.Tooltip.bg : alpha(theme.palette.grey[700], 0.92),\n borderRadius: (theme.vars || theme).shape.borderRadius,\n color: (theme.vars || theme).palette.common.white,\n fontFamily: theme.typography.fontFamily,\n padding: '4px 8px',\n fontSize: theme.typography.pxToRem(11),\n maxWidth: 300,\n margin: 2,\n wordWrap: 'break-word',\n fontWeight: theme.typography.fontWeightMedium\n}, ownerState.arrow && {\n position: 'relative',\n margin: 0\n}, ownerState.touch && {\n padding: '8px 16px',\n fontSize: theme.typography.pxToRem(14),\n lineHeight: `${round(16 / 14)}em`,\n fontWeight: theme.typography.fontWeightRegular\n}, {\n [`.${tooltipClasses.popper}[data-popper-placement*=\"left\"] &`]: _extends({\n transformOrigin: 'right center'\n }, !ownerState.isRtl ? _extends({\n marginRight: '14px'\n }, ownerState.touch && {\n marginRight: '24px'\n }) : _extends({\n marginLeft: '14px'\n }, ownerState.touch && {\n marginLeft: '24px'\n })),\n [`.${tooltipClasses.popper}[data-popper-placement*=\"right\"] &`]: _extends({\n transformOrigin: 'left center'\n }, !ownerState.isRtl ? _extends({\n marginLeft: '14px'\n }, ownerState.touch && {\n marginLeft: '24px'\n }) : _extends({\n marginRight: '14px'\n }, ownerState.touch && {\n marginRight: '24px'\n })),\n [`.${tooltipClasses.popper}[data-popper-placement*=\"top\"] &`]: _extends({\n transformOrigin: 'center bottom',\n marginBottom: '14px'\n }, ownerState.touch && {\n marginBottom: '24px'\n }),\n [`.${tooltipClasses.popper}[data-popper-placement*=\"bottom\"] &`]: _extends({\n transformOrigin: 'center top',\n marginTop: '14px'\n }, ownerState.touch && {\n marginTop: '24px'\n })\n}));\nconst TooltipArrow = styled('span', {\n name: 'MuiTooltip',\n slot: 'Arrow',\n overridesResolver: (props, styles) => styles.arrow\n})(({\n theme\n}) => ({\n overflow: 'hidden',\n position: 'absolute',\n width: '1em',\n height: '0.71em' /* = width / sqrt(2) = (length of the hypotenuse) */,\n boxSizing: 'border-box',\n color: theme.vars ? theme.vars.palette.Tooltip.bg : alpha(theme.palette.grey[700], 0.9),\n '&::before': {\n content: '\"\"',\n margin: 'auto',\n display: 'block',\n width: '100%',\n height: '100%',\n backgroundColor: 'currentColor',\n transform: 'rotate(45deg)'\n }\n}));\nlet hystersisOpen = false;\nconst hystersisTimer = new Timeout();\nlet cursorPosition = {\n x: 0,\n y: 0\n};\nexport function testReset() {\n hystersisOpen = false;\n hystersisTimer.clear();\n}\nfunction composeEventHandler(handler, eventHandler) {\n return event => {\n if (eventHandler) {\n eventHandler(event);\n }\n handler(event);\n };\n}\n\n// TODO v6: Remove PopperComponent, PopperProps, TransitionComponent and TransitionProps.\nconst Tooltip = /*#__PURE__*/React.forwardRef(function Tooltip(inProps, ref) {\n var _ref, _slots$popper, _ref2, _ref3, _slots$transition, _ref4, _slots$tooltip, _ref5, _slots$arrow, _slotProps$popper, _ref6, _slotProps$popper2, _slotProps$transition, _slotProps$tooltip, _ref7, _slotProps$tooltip2, _slotProps$arrow, _ref8, _slotProps$arrow2;\n const props = useThemeProps({\n props: inProps,\n name: 'MuiTooltip'\n });\n const {\n arrow = false,\n children: childrenProp,\n components = {},\n componentsProps = {},\n describeChild = false,\n disableFocusListener = false,\n disableHoverListener = false,\n disableInteractive: disableInteractiveProp = false,\n disableTouchListener = false,\n enterDelay = 100,\n enterNextDelay = 0,\n enterTouchDelay = 700,\n followCursor = false,\n id: idProp,\n leaveDelay = 0,\n leaveTouchDelay = 1500,\n onClose,\n onOpen,\n open: openProp,\n placement = 'bottom',\n PopperComponent: PopperComponentProp,\n PopperProps = {},\n slotProps = {},\n slots = {},\n title,\n TransitionComponent: TransitionComponentProp = Grow,\n TransitionProps\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n\n // to prevent runtime errors, developers will need to provide a child as a React element anyway.\n const children = /*#__PURE__*/React.isValidElement(childrenProp) ? childrenProp : /*#__PURE__*/_jsx(\"span\", {\n children: childrenProp\n });\n const theme = useTheme();\n const isRtl = theme.direction === 'rtl';\n const [childNode, setChildNode] = React.useState();\n const [arrowRef, setArrowRef] = React.useState(null);\n const ignoreNonTouchEvents = React.useRef(false);\n const disableInteractive = disableInteractiveProp || followCursor;\n const closeTimer = useTimeout();\n const enterTimer = useTimeout();\n const leaveTimer = useTimeout();\n const touchTimer = useTimeout();\n const [openState, setOpenState] = useControlled({\n controlled: openProp,\n default: false,\n name: 'Tooltip',\n state: 'open'\n });\n let open = openState;\n if (process.env.NODE_ENV !== 'production') {\n // eslint-disable-next-line react-hooks/rules-of-hooks\n const {\n current: isControlled\n } = React.useRef(openProp !== undefined);\n\n // eslint-disable-next-line react-hooks/rules-of-hooks\n React.useEffect(() => {\n if (childNode && childNode.disabled && !isControlled && title !== '' && childNode.tagName.toLowerCase() === 'button') {\n console.error(['MUI: You are providing a disabled `button` child to the Tooltip component.', 'A disabled element does not fire events.', \"Tooltip needs to listen to the child element's events to display the title.\", '', 'Add a simple wrapper element, such as a `span`.'].join('\\n'));\n }\n }, [title, childNode, isControlled]);\n }\n const id = useId(idProp);\n const prevUserSelect = React.useRef();\n const stopTouchInteraction = useEventCallback(() => {\n if (prevUserSelect.current !== undefined) {\n document.body.style.WebkitUserSelect = prevUserSelect.current;\n prevUserSelect.current = undefined;\n }\n touchTimer.clear();\n });\n React.useEffect(() => stopTouchInteraction, [stopTouchInteraction]);\n const handleOpen = event => {\n hystersisTimer.clear();\n hystersisOpen = true;\n\n // The mouseover event will trigger for every nested element in the tooltip.\n // We can skip rerendering when the tooltip is already open.\n // We are using the mouseover event instead of the mouseenter event to fix a hide/show issue.\n setOpenState(true);\n if (onOpen && !open) {\n onOpen(event);\n }\n };\n const handleClose = useEventCallback(\n /**\n * @param {React.SyntheticEvent | Event} event\n */\n event => {\n hystersisTimer.start(800 + leaveDelay, () => {\n hystersisOpen = false;\n });\n setOpenState(false);\n if (onClose && open) {\n onClose(event);\n }\n closeTimer.start(theme.transitions.duration.shortest, () => {\n ignoreNonTouchEvents.current = false;\n });\n });\n const handleEnter = event => {\n if (ignoreNonTouchEvents.current && event.type !== 'touchstart') {\n return;\n }\n\n // Remove the title ahead of time.\n // We don't want to wait for the next render commit.\n // We would risk displaying two tooltips at the same time (native + this one).\n if (childNode) {\n childNode.removeAttribute('title');\n }\n enterTimer.clear();\n leaveTimer.clear();\n if (enterDelay || hystersisOpen && enterNextDelay) {\n enterTimer.start(hystersisOpen ? enterNextDelay : enterDelay, () => {\n handleOpen(event);\n });\n } else {\n handleOpen(event);\n }\n };\n const handleLeave = event => {\n enterTimer.clear();\n leaveTimer.start(leaveDelay, () => {\n handleClose(event);\n });\n };\n const {\n isFocusVisibleRef,\n onBlur: handleBlurVisible,\n onFocus: handleFocusVisible,\n ref: focusVisibleRef\n } = useIsFocusVisible();\n // We don't necessarily care about the focusVisible state (which is safe to access via ref anyway).\n // We just need to re-render the Tooltip if the focus-visible state changes.\n const [, setChildIsFocusVisible] = React.useState(false);\n const handleBlur = event => {\n handleBlurVisible(event);\n if (isFocusVisibleRef.current === false) {\n setChildIsFocusVisible(false);\n handleLeave(event);\n }\n };\n const handleFocus = event => {\n // Workaround for https://github.com/facebook/react/issues/7769\n // The autoFocus of React might trigger the event before the componentDidMount.\n // We need to account for this eventuality.\n if (!childNode) {\n setChildNode(event.currentTarget);\n }\n handleFocusVisible(event);\n if (isFocusVisibleRef.current === true) {\n setChildIsFocusVisible(true);\n handleEnter(event);\n }\n };\n const detectTouchStart = event => {\n ignoreNonTouchEvents.current = true;\n const childrenProps = children.props;\n if (childrenProps.onTouchStart) {\n childrenProps.onTouchStart(event);\n }\n };\n const handleMouseOver = handleEnter;\n const handleMouseLeave = handleLeave;\n const handleTouchStart = event => {\n detectTouchStart(event);\n leaveTimer.clear();\n closeTimer.clear();\n stopTouchInteraction();\n prevUserSelect.current = document.body.style.WebkitUserSelect;\n // Prevent iOS text selection on long-tap.\n document.body.style.WebkitUserSelect = 'none';\n touchTimer.start(enterTouchDelay, () => {\n document.body.style.WebkitUserSelect = prevUserSelect.current;\n handleEnter(event);\n });\n };\n const handleTouchEnd = event => {\n if (children.props.onTouchEnd) {\n children.props.onTouchEnd(event);\n }\n stopTouchInteraction();\n leaveTimer.start(leaveTouchDelay, () => {\n handleClose(event);\n });\n };\n React.useEffect(() => {\n if (!open) {\n return undefined;\n }\n\n /**\n * @param {KeyboardEvent} nativeEvent\n */\n function handleKeyDown(nativeEvent) {\n // IE11, Edge (prior to using Bink?) use 'Esc'\n if (nativeEvent.key === 'Escape' || nativeEvent.key === 'Esc') {\n handleClose(nativeEvent);\n }\n }\n document.addEventListener('keydown', handleKeyDown);\n return () => {\n document.removeEventListener('keydown', handleKeyDown);\n };\n }, [handleClose, open]);\n const handleRef = useForkRef(children.ref, focusVisibleRef, setChildNode, ref);\n\n // There is no point in displaying an empty tooltip.\n // So we exclude all falsy values, except 0, which is valid.\n if (!title && title !== 0) {\n open = false;\n }\n const popperRef = React.useRef();\n const handleMouseMove = event => {\n const childrenProps = children.props;\n if (childrenProps.onMouseMove) {\n childrenProps.onMouseMove(event);\n }\n cursorPosition = {\n x: event.clientX,\n y: event.clientY\n };\n if (popperRef.current) {\n popperRef.current.update();\n }\n };\n const nameOrDescProps = {};\n const titleIsString = typeof title === 'string';\n if (describeChild) {\n nameOrDescProps.title = !open && titleIsString && !disableHoverListener ? title : null;\n nameOrDescProps['aria-describedby'] = open ? id : null;\n } else {\n nameOrDescProps['aria-label'] = titleIsString ? title : null;\n nameOrDescProps['aria-labelledby'] = open && !titleIsString ? id : null;\n }\n const childrenProps = _extends({}, nameOrDescProps, other, children.props, {\n className: clsx(other.className, children.props.className),\n onTouchStart: detectTouchStart,\n ref: handleRef\n }, followCursor ? {\n onMouseMove: handleMouseMove\n } : {});\n if (process.env.NODE_ENV !== 'production') {\n childrenProps['data-mui-internal-clone-element'] = true;\n\n // eslint-disable-next-line react-hooks/rules-of-hooks\n React.useEffect(() => {\n if (childNode && !childNode.getAttribute('data-mui-internal-clone-element')) {\n console.error(['MUI: The `children` component of the Tooltip is not forwarding its props correctly.', 'Please make sure that props are spread on the same element that the ref is applied to.'].join('\\n'));\n }\n }, [childNode]);\n }\n const interactiveWrapperListeners = {};\n if (!disableTouchListener) {\n childrenProps.onTouchStart = handleTouchStart;\n childrenProps.onTouchEnd = handleTouchEnd;\n }\n if (!disableHoverListener) {\n childrenProps.onMouseOver = composeEventHandler(handleMouseOver, childrenProps.onMouseOver);\n childrenProps.onMouseLeave = composeEventHandler(handleMouseLeave, childrenProps.onMouseLeave);\n if (!disableInteractive) {\n interactiveWrapperListeners.onMouseOver = handleMouseOver;\n interactiveWrapperListeners.onMouseLeave = handleMouseLeave;\n }\n }\n if (!disableFocusListener) {\n childrenProps.onFocus = composeEventHandler(handleFocus, childrenProps.onFocus);\n childrenProps.onBlur = composeEventHandler(handleBlur, childrenProps.onBlur);\n if (!disableInteractive) {\n interactiveWrapperListeners.onFocus = handleFocus;\n interactiveWrapperListeners.onBlur = handleBlur;\n }\n }\n if (process.env.NODE_ENV !== 'production') {\n if (children.props.title) {\n console.error(['MUI: You have provided a `title` prop to the child of .', `Remove this title prop \\`${children.props.title}\\` or the Tooltip component.`].join('\\n'));\n }\n }\n const popperOptions = React.useMemo(() => {\n var _PopperProps$popperOp;\n let tooltipModifiers = [{\n name: 'arrow',\n enabled: Boolean(arrowRef),\n options: {\n element: arrowRef,\n padding: 4\n }\n }];\n if ((_PopperProps$popperOp = PopperProps.popperOptions) != null && _PopperProps$popperOp.modifiers) {\n tooltipModifiers = tooltipModifiers.concat(PopperProps.popperOptions.modifiers);\n }\n return _extends({}, PopperProps.popperOptions, {\n modifiers: tooltipModifiers\n });\n }, [arrowRef, PopperProps]);\n const ownerState = _extends({}, props, {\n isRtl,\n arrow,\n disableInteractive,\n placement,\n PopperComponentProp,\n touch: ignoreNonTouchEvents.current\n });\n const classes = useUtilityClasses(ownerState);\n const PopperComponent = (_ref = (_slots$popper = slots.popper) != null ? _slots$popper : components.Popper) != null ? _ref : TooltipPopper;\n const TransitionComponent = (_ref2 = (_ref3 = (_slots$transition = slots.transition) != null ? _slots$transition : components.Transition) != null ? _ref3 : TransitionComponentProp) != null ? _ref2 : Grow;\n const TooltipComponent = (_ref4 = (_slots$tooltip = slots.tooltip) != null ? _slots$tooltip : components.Tooltip) != null ? _ref4 : TooltipTooltip;\n const ArrowComponent = (_ref5 = (_slots$arrow = slots.arrow) != null ? _slots$arrow : components.Arrow) != null ? _ref5 : TooltipArrow;\n const popperProps = appendOwnerState(PopperComponent, _extends({}, PopperProps, (_slotProps$popper = slotProps.popper) != null ? _slotProps$popper : componentsProps.popper, {\n className: clsx(classes.popper, PopperProps == null ? void 0 : PopperProps.className, (_ref6 = (_slotProps$popper2 = slotProps.popper) != null ? _slotProps$popper2 : componentsProps.popper) == null ? void 0 : _ref6.className)\n }), ownerState);\n const transitionProps = appendOwnerState(TransitionComponent, _extends({}, TransitionProps, (_slotProps$transition = slotProps.transition) != null ? _slotProps$transition : componentsProps.transition), ownerState);\n const tooltipProps = appendOwnerState(TooltipComponent, _extends({}, (_slotProps$tooltip = slotProps.tooltip) != null ? _slotProps$tooltip : componentsProps.tooltip, {\n className: clsx(classes.tooltip, (_ref7 = (_slotProps$tooltip2 = slotProps.tooltip) != null ? _slotProps$tooltip2 : componentsProps.tooltip) == null ? void 0 : _ref7.className)\n }), ownerState);\n const tooltipArrowProps = appendOwnerState(ArrowComponent, _extends({}, (_slotProps$arrow = slotProps.arrow) != null ? _slotProps$arrow : componentsProps.arrow, {\n className: clsx(classes.arrow, (_ref8 = (_slotProps$arrow2 = slotProps.arrow) != null ? _slotProps$arrow2 : componentsProps.arrow) == null ? void 0 : _ref8.className)\n }), ownerState);\n return /*#__PURE__*/_jsxs(React.Fragment, {\n children: [/*#__PURE__*/React.cloneElement(children, childrenProps), /*#__PURE__*/_jsx(PopperComponent, _extends({\n as: PopperComponentProp != null ? PopperComponentProp : Popper,\n placement: placement,\n anchorEl: followCursor ? {\n getBoundingClientRect: () => ({\n top: cursorPosition.y,\n left: cursorPosition.x,\n right: cursorPosition.x,\n bottom: cursorPosition.y,\n width: 0,\n height: 0\n })\n } : childNode,\n popperRef: popperRef,\n open: childNode ? open : false,\n id: id,\n transition: true\n }, interactiveWrapperListeners, popperProps, {\n popperOptions: popperOptions,\n children: ({\n TransitionProps: TransitionPropsInner\n }) => /*#__PURE__*/_jsx(TransitionComponent, _extends({\n timeout: theme.transitions.duration.shorter\n }, TransitionPropsInner, transitionProps, {\n children: /*#__PURE__*/_jsxs(TooltipComponent, _extends({}, tooltipProps, {\n children: [title, arrow ? /*#__PURE__*/_jsx(ArrowComponent, _extends({}, tooltipArrowProps, {\n ref: setArrowRef\n })) : null]\n }))\n }))\n }))]\n });\n});\nprocess.env.NODE_ENV !== \"production\" ? Tooltip.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the d.ts file and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * If `true`, adds an arrow to the tooltip.\n * @default false\n */\n arrow: PropTypes.bool,\n /**\n * Tooltip reference element.\n */\n children: elementAcceptingRef.isRequired,\n /**\n * Override or extend the styles applied to the component.\n */\n classes: PropTypes.object,\n /**\n * @ignore\n */\n className: PropTypes.string,\n /**\n * The components used for each slot inside.\n *\n * This prop is an alias for the `slots` prop.\n * It's recommended to use the `slots` prop instead.\n *\n * @default {}\n */\n components: PropTypes.shape({\n Arrow: PropTypes.elementType,\n Popper: PropTypes.elementType,\n Tooltip: PropTypes.elementType,\n Transition: PropTypes.elementType\n }),\n /**\n * The extra props for the slot components.\n * You can override the existing props or add new ones.\n *\n * This prop is an alias for the `slotProps` prop.\n * It's recommended to use the `slotProps` prop instead, as `componentsProps` will be deprecated in the future.\n *\n * @default {}\n */\n componentsProps: PropTypes.shape({\n arrow: PropTypes.object,\n popper: PropTypes.object,\n tooltip: PropTypes.object,\n transition: PropTypes.object\n }),\n /**\n * Set to `true` if the `title` acts as an accessible description.\n * By default the `title` acts as an accessible label for the child.\n * @default false\n */\n describeChild: PropTypes.bool,\n /**\n * Do not respond to focus-visible events.\n * @default false\n */\n disableFocusListener: PropTypes.bool,\n /**\n * Do not respond to hover events.\n * @default false\n */\n disableHoverListener: PropTypes.bool,\n /**\n * Makes a tooltip not interactive, i.e. it will close when the user\n * hovers over the tooltip before the `leaveDelay` is expired.\n * @default false\n */\n disableInteractive: PropTypes.bool,\n /**\n * Do not respond to long press touch events.\n * @default false\n */\n disableTouchListener: PropTypes.bool,\n /**\n * The number of milliseconds to wait before showing the tooltip.\n * This prop won't impact the enter touch delay (`enterTouchDelay`).\n * @default 100\n */\n enterDelay: PropTypes.number,\n /**\n * The number of milliseconds to wait before showing the tooltip when one was already recently opened.\n * @default 0\n */\n enterNextDelay: PropTypes.number,\n /**\n * The number of milliseconds a user must touch the element before showing the tooltip.\n * @default 700\n */\n enterTouchDelay: PropTypes.number,\n /**\n * If `true`, the tooltip follow the cursor over the wrapped element.\n * @default false\n */\n followCursor: PropTypes.bool,\n /**\n * This prop is used to help implement the accessibility logic.\n * If you don't provide this prop. It falls back to a randomly generated id.\n */\n id: PropTypes.string,\n /**\n * The number of milliseconds to wait before hiding the tooltip.\n * This prop won't impact the leave touch delay (`leaveTouchDelay`).\n * @default 0\n */\n leaveDelay: PropTypes.number,\n /**\n * The number of milliseconds after the user stops touching an element before hiding the tooltip.\n * @default 1500\n */\n leaveTouchDelay: PropTypes.number,\n /**\n * Callback fired when the component requests to be closed.\n *\n * @param {React.SyntheticEvent} event The event source of the callback.\n */\n onClose: PropTypes.func,\n /**\n * Callback fired when the component requests to be open.\n *\n * @param {React.SyntheticEvent} event The event source of the callback.\n */\n onOpen: PropTypes.func,\n /**\n * If `true`, the component is shown.\n */\n open: PropTypes.bool,\n /**\n * Tooltip placement.\n * @default 'bottom'\n */\n placement: PropTypes.oneOf(['bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n /**\n * The component used for the popper.\n * @default Popper\n */\n PopperComponent: PropTypes.elementType,\n /**\n * Props applied to the [`Popper`](/material-ui/api/popper/) element.\n * @default {}\n */\n PopperProps: PropTypes.object,\n /**\n * The extra props for the slot components.\n * You can override the existing props or add new ones.\n *\n * This prop is an alias for the `componentsProps` prop, which will be deprecated in the future.\n *\n * @default {}\n */\n slotProps: PropTypes.shape({\n arrow: PropTypes.object,\n popper: PropTypes.object,\n tooltip: PropTypes.object,\n transition: PropTypes.object\n }),\n /**\n * The components used for each slot inside.\n *\n * This prop is an alias for the `components` prop, which will be deprecated in the future.\n *\n * @default {}\n */\n slots: PropTypes.shape({\n arrow: PropTypes.elementType,\n popper: PropTypes.elementType,\n tooltip: PropTypes.elementType,\n transition: PropTypes.elementType\n }),\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Tooltip title. Zero-length titles string, undefined, null and false are never displayed.\n */\n title: PropTypes.node,\n /**\n * The component used for the transition.\n * [Follow this guide](/material-ui/transitions/#transitioncomponent-prop) to learn more about the requirements for this component.\n * @default Grow\n */\n TransitionComponent: PropTypes.elementType,\n /**\n * Props applied to the transition element.\n * By default, the element is based on this [`Transition`](http://reactcommunity.org/react-transition-group/transition/) component.\n */\n TransitionProps: PropTypes.object\n} : void 0;\nexport default Tooltip;","import '@/components/mui/menu-item.component.css';\nimport ArrowRightIcon from '@mui/icons-material/ArrowRight';\nimport {\n ListItemIcon as MuiListItemIcon,\n ListItemText as MuiListItemText,\n MenuItem as MuiMenuItem,\n} from '@mui/material';\nimport Tooltip from '@mui/material/Tooltip';\nimport { Localized, ReferencedItem, SingleColumnMenu } from 'platform-bible-utils';\nimport { MouseEvent, PropsWithChildren } from 'react';\n\ntype MenuItemInfoBase = {\n /** Text (displayable in the UI) as the name of the menu item */\n label: string;\n /** Text to display when the mouse hovers over the menu item */\n tooltip?: string;\n};\n\nexport type Command = MenuItemInfoBase & {\n /** Command to execute (string.string) */\n command: string;\n};\n\ntype SubMenu = MenuItemInfoBase & {\n /** Command to execute (string.string) */\n items: MenuItemInfo[];\n};\n\nexport interface CommandHandler {\n (command: Command): void;\n}\n\nexport type MenuPropsBase = {\n /*\n * The JSON defining the menu whose items are to be rendered. This will typically be one of the\n * menus in the \"defs\" in a Platform.Bible menu (see PlatformMenus). The schema for this is\n * menuDocumentSchema (at the end of menus.model.ts). Note that while this is a\n * \"SingleColumnMenu\", somewhat bizarrely, a MultiColumnMenu is a SingleColumnMenu, so it really\n * could be a MultiColumnMenu, in which case, column had better be defined so it can be used\n * to filter out the actual groups and items to display on the column.\n */\n menuDefinition: Localized;\n\n commandHandler: CommandHandler;\n\n /**\n * Additional action to perform when any menu item is clicked. Allows the caller to handle event\n * (e.g., to close the menu).\n */\n onClick?: (event: MouseEvent) => void;\n};\n\nexport type MenuItemListProps = MenuPropsBase & {\n /** Optional unique (column) identifier */\n columnId?: ReferencedItem;\n};\n\nexport type MenuItemProps = Omit &\n PropsWithChildren<{\n /** Optional unique identifier */\n id?: string;\n\n onClick: (event: MouseEvent) => void;\n }>;\n\ntype MenuItemInfo = (Command | SubMenu) & {\n /**\n * If specified, menu item will be inset if it does not have a leading icon.\n *\n * @default true\n */\n allowForLeadingIcons?: boolean;\n /**\n * If specified, the path to the icon image to display on the leading side of the menu text.\n *\n * @default undefined (no leading icon will be shown)\n */\n iconPathBefore?: string;\n /**\n * If specified, the path to the icon image to display on the trailing side of the menu text.\n *\n * @default undefined (no trailing icon will be shown)\n */\n iconPathAfter?: string;\n /**\n * If true, list item is focused during the first mount\n *\n * @default false\n */\n hasAutoFocus?: boolean;\n\n /** Additional css classes to help with unique styling of the menu item */\n className?: string;\n\n /**\n * If true, the menu item will appear disabled and it will not respond to clicks or mouse hovers.\n *\n * @default false\n */\n isDisabled?: boolean;\n\n /**\n * If true, compact vertical padding designed for keyboard and mouse input is used.\n *\n * @default true\n */\n isDense?: boolean;\n\n /**\n * If true, a right-arrow icon will be displayed (iconPathAfter, if specified, will be ignored).\n *\n * @default false\n */\n isSubMenuParent?: boolean;\n\n /**\n * If true, the left and right padding is removed\n *\n * @default false\n */\n hasDisabledGutters?: boolean;\n\n /**\n * If true, a 1px light border is added to bottom of menu item\n *\n * @default false\n */\n hasDivider?: boolean;\n\n /** Help identify which element has keyboard focus */\n focusVisibleClassName?: string;\n\n /** If it's a submenu, it should have the items property */\n items?: MenuItemInfo[];\n};\n\nfunction getIcon(icon: string | undefined, menuLabel: string, leading: boolean) {\n return icon ? (\n \n {`${leading\n \n ) : undefined;\n}\n\nexport default function MenuItem(props: MenuItemProps) {\n const {\n onClick,\n label,\n tooltip,\n allowForLeadingIcons = true,\n iconPathBefore = undefined,\n iconPathAfter = undefined,\n hasAutoFocus = false,\n className,\n isDisabled = false,\n isDense = true,\n isSubMenuParent = false,\n hasDisabledGutters = false,\n hasDivider = false,\n focusVisibleClassName,\n id,\n children,\n } = props;\n\n const menuItem = (\n \n {label ? (\n <>\n {getIcon(iconPathBefore, label, true)}\n \n {isSubMenuParent ? (\n \n \n \n ) : (\n getIcon(iconPathAfter, label, false)\n )}\n \n ) : (\n children\n )}\n \n );\n\n return tooltip ? (\n \n
    {menuItem}
    \n
    \n ) : (\n menuItem\n );\n}\n","import MenuItem, {\n MenuItemListProps,\n MenuItemProps,\n MenuPropsBase,\n} from '@/components/mui/menu-item.component';\nimport { Menu } from '@mui/material';\nimport {\n Localized,\n MenuGroupDetailsInSubMenu,\n MenuItemContainingCommand,\n MenuItemContainingSubmenu,\n OrderedExtensibleContainer,\n ReferencedItem,\n SingleColumnMenu,\n} from 'platform-bible-utils';\nimport { MouseEvent, useMemo, useState } from 'react';\n\n/**\n * All the exported types in this file should be regarded as \"internal\" (i.e., they should not be\n * exposed via index.ts).\n */\n\nexport type GroupedMenuPropsBase = MenuPropsBase & {\n /** Optional unique (column) identifier */\n columnId?: ReferencedItem;\n};\n\nexport type GroupedMenuItemListProps = MenuItemListProps & {\n /**\n * If the menuDefinition includes \"top-level\" groups (i.e., those that belong to a column as\n * opposed to those that belong to a submenu) that should not be included in the list, then this\n * array specifies which groups to include. Likewise, for a submenu, this list indicates which\n * groups are pertinent for that submenu. So then for a context menu this property need not be\n * specified since it is a top-level menu based on a \"true\" SingleColumnMenu (i.e., one that is\n * not a MultiColumnMenu).\n */\n includedGroups?: {\n id: string;\n group: Localized;\n }[];\n};\n\ninterface ItemInfo {\n item: Localized;\n isLastItemInGroup: boolean;\n}\n\ntype SubMenuProps = MenuPropsBase & {\n parentMenuItem: Localized;\n parentItemProps: Omit, 'iconPathAfter'>;\n};\n\nfunction getAllGroups(menuDefinition: Localized) {\n const groupEntries = Object.entries(menuDefinition.groups);\n // Convert array of entries to array of objects with id and group properties\n return groupEntries.map(([key, value]) => ({ id: key, group: value }));\n}\n\nfunction SubMenu(props: SubMenuProps) {\n const [anchorEl, setAnchorEl] = useState(undefined);\n\n const { parentMenuItem, parentItemProps, menuDefinition } = props;\n\n const handleParentMenuItemClick = (event: MouseEvent) => {\n setAnchorEl(event.currentTarget);\n };\n\n const handleClose = () => {\n setAnchorEl(undefined);\n };\n\n const renderSubMenuItems = () => {\n let includedGroups = getAllGroups(menuDefinition).filter((g) => 'menuItem' in g.group);\n\n // Ensure valid parent menu was provided. (If not, submenu will contain all groups!)\n if (!parentMenuItem?.id) throw new Error('A valid parent menu item is required for submenus.');\n\n // When laying out a submenu, only include groups associated with the provided parent menu.\n // Note: without the (annoying) redundant check that the included groups\n // have the menuItem field, TS doesn't think it exists.\n includedGroups = includedGroups.filter(\n (group) => 'menuItem' in group.group && group.group.menuItem === parentMenuItem.id,\n );\n\n return ;\n };\n\n return (\n <>\n \n \n {renderSubMenuItems()}\n \n \n );\n}\n\nconst getOrderedGroupItems = (\n groupId: string,\n allItems: Localized[],\n) => {\n // Filter items that belong to the specified group\n const itemsForGroup = allItems.filter((item) => item.group === groupId);\n // Sort items based on order\n const sortedItems = itemsForGroup.sort((a, b) => (a.order || 0) - (b.order || 0));\n return sortedItems;\n};\n\n/**\n * This component is internal; it does not need to be exposed to the outside world since it is not\n * useful on its own. It is used to generate and lay out the MenuItems that appear either on a\n * top-level menu (in a GridMenu or ContextMenu) or in a submenu.\n */\nexport default function GroupedMenuItemList(menuProps: GroupedMenuItemListProps) {\n const { menuDefinition, onClick, commandHandler, includedGroups } = menuProps;\n\n const { items, allowForLeadingIcons } = useMemo(() => {\n const groupsToInclude =\n includedGroups && includedGroups.length > 0\n ? includedGroups\n : // We're apparently laying out a single-column menu (presumably a context menu). In this\n // case, all groups should be included except ones that belong to a submenu.\n getAllGroups(menuDefinition).filter((g) => !('menuItem' in g.group));\n\n const sortedGroups = Object.values(groupsToInclude).sort(\n (a, b) => (a.group.order || 0) - (b.group.order || 0),\n );\n\n const itemArray: ItemInfo[] = [];\n\n sortedGroups.forEach((group) => {\n getOrderedGroupItems(group.id, menuDefinition.items).forEach((item) =>\n itemArray.push({ item, isLastItemInGroup: false }),\n );\n if (itemArray.length > 0) itemArray[itemArray.length - 1].isLastItemInGroup = true;\n });\n\n // No divider after last item in final group.\n if (itemArray.length > 0) itemArray[itemArray.length - 1].isLastItemInGroup = false;\n\n const allowSpaceForLeadingIcons = itemArray.some(\n (i) => 'iconPathBefore' in i.item && i.item.iconPathBefore,\n );\n\n return { items: itemArray, allowForLeadingIcons: allowSpaceForLeadingIcons };\n }, [includedGroups, menuDefinition]);\n\n // Create props for MenuItem component including setting hasDivider for the last item in a group\n const createMenuItemProps = ({ item, isLastItemInGroup }: ItemInfo) => {\n const menuItemProps = {\n className: 'papi-menu-item',\n label: item.label,\n tooltip: item.tooltip,\n iconPathBefore: 'iconPathBefore' in item ? item.iconPathBefore : undefined,\n iconPathAfter: 'iconPathAfter' in item ? item.iconPathAfter : undefined,\n hasDivider: isLastItemInGroup, // Set hasDivider to true for the last item in a group\n allowForLeadingIcons,\n };\n\n return menuItemProps;\n };\n\n const [firstItem] = items;\n\n if (!firstItem) return
    ;\n\n const divKey = firstItem.item.group;\n\n return (\n
    \n {items.map((itemInfo, index) => {\n const { item } = itemInfo;\n const menuItemProps = createMenuItemProps(itemInfo);\n if ('command' in item) {\n const key = item.group + index;\n return (\n ) => {\n onClick?.(event);\n commandHandler(item);\n }}\n {...menuItemProps}\n />\n );\n }\n return (\n \n );\n })}\n
    \n );\n}\n","import GroupedMenuItemList from '@/components/mui/grouped-menu-item-list.component';\nimport { MenuItemListProps } from '@/components/mui/menu-item.component';\nimport { MultiColumnMenu } from 'platform-bible-utils';\n\n/**\n * This component is internal; it does not need to be exposed to the outside world since it is not\n * useful on its own. Use either GridMenu or ContextMenu.\n */\nexport default function TopLevelMenu(props: MenuItemListProps) {\n const { menuDefinition, columnId } = props;\n\n const groupEntries = Object.entries(menuDefinition.groups);\n // Convert array of entries to array of objects with id and group properties\n const groups = groupEntries.map(([key, value]) => ({ id: key, group: value }));\n let includedGroups = groups.filter((g) => 'column' in g.group);\n\n // Check if column is provided and menuDefinition is a MultiColumnMenu\n if (\n columnId &&\n 'columns' in menuDefinition &&\n // Without this type assertion, TS doesn't know what columns is.\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n (menuDefinition as MultiColumnMenu).columns[columnId]\n ) {\n // When laying out a single column in a MultiColumnMenu, only include groups associated with\n // the provided column. Note: without the (annoying) redundant check that the included groups\n // have the colum field, TS doesn't think it exists.\n includedGroups = includedGroups.filter(\n (g) => 'column' in g.group && g.group.column === columnId,\n );\n }\n\n return ;\n}\n","import '@/components/mui/grid-menu.component.css';\nimport { GroupedMenuPropsBase } from '@/components/mui/grouped-menu-item-list.component';\nimport { CommandHandler } from '@/components/mui/menu-item.component';\nimport TopLevelMenu from '@/components/mui/top-level-menu.component';\nimport { Grid, List } from '@mui/material';\nimport {\n Localized,\n MenuColumnWithHeader,\n MultiColumnMenu,\n ReferencedItem,\n} from 'platform-bible-utils';\nimport { useMemo } from 'react';\n\ntype ColumnInfo = {\n /*\n * The ID (`${string}.${string}`) of a specific menu column.\n */\n id: ReferencedItem;\n\n /*\n * Metadata (label, order, etc.) for a specific menu column.\n */\n metadata: Localized;\n};\n\ntype MenuColumnProps = ColumnInfo &\n GroupedMenuPropsBase & {\n /** Additional css classes to help with unique styling of the menu column */\n className?: string;\n };\n\nexport type GridMenuInfo = {\n /** The menu object containing information about the columns, groups, and items to display. */\n multiColumnMenu: Localized;\n};\n\nexport type GridMenuProps = GridMenuInfo & {\n /** Optional unique identifier */\n id?: string;\n\n commandHandler: CommandHandler;\n\n /** Additional css classes to help with unique styling of the grid menu */\n className?: string;\n};\n\nfunction MenuColumn({\n commandHandler,\n menuDefinition,\n id,\n metadata,\n onClick,\n className,\n}: MenuColumnProps) {\n return (\n \n

    \n {metadata.label}\n

    \n {/* It would seem as though this List component were unnecessary, since it only contains one\n thing, but the \"dense\" property does affect the layout of the items (in a way I don't fully\n understand). There might be a better way. */}\n \n \n \n \n );\n}\n\nexport default function GridMenu({\n commandHandler,\n className,\n multiColumnMenu,\n id,\n}: GridMenuProps) {\n const { columns } = multiColumnMenu;\n\n const sortedColumns = useMemo(() => {\n const columnNumbers = new Map();\n Object.getOwnPropertyNames(columns).forEach((columnName: string) => {\n // We know for sure there is a (boolean) property 'isExtensible' that we are not interested in.\n if (columnName === 'isExtensible') return;\n // TS doesn't allow `columnName` above to be a ReferencedItem even though the type says it is\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const columnId = columnName as ReferencedItem;\n const column = columns[columnId];\n // As of right now (and hopefully forever after), all remaining properties of the\n // ColumnsWithHeaders object are columns whose property names are the IDs of the columns.\n // This is an additional (redundant) sanity check. Specifically we're interested in\n // MenuColumnWithHeader objects, which TypeScript now \"knows\" we have, but at runtime all we\n // can check for is that it's an object with a valid numeric order field. That's likely good\n // enough.\n if (\n typeof column === 'object' &&\n typeof column.order === 'number' &&\n !Number.isNaN(column.order)\n )\n columnNumbers.set(column.order, { id: columnId, metadata: column });\n else\n console.warn(\n `Property ${columnName} (${typeof column}) on menu ${id} is not a valid column and is being ignored. This might indicate data corruption`,\n );\n });\n\n // Extract values and sort them based on the 'order' property\n return Array.from(columnNumbers.values()).sort((a, b) => {\n return (a.metadata.order || 0) - (b.metadata.order || 0);\n });\n }, [columns, id]);\n\n // We might need something like this if we need to be able to prevent empty columns\n // sortedColumns.filter((c) => multiColumnMenu.groups.some((g) => 'column' in g && (g as .column)...\n\n return (\n \n {sortedColumns.map((col, index) => (\n \n ))}\n \n );\n}\n","import { useEffect, useRef, useState } from 'react';\n\nexport type UsePromiseOptions = {\n /**\n * Whether to leave the value as the most recent resolved promise value or set it back to\n * defaultValue while running the promise again. Defaults to true\n */\n preserveValue?: boolean;\n};\n\n/** Set up defaults for options for usePromise hook */\nfunction getUsePromiseOptionsDefaults(options: UsePromiseOptions): UsePromiseOptions {\n return {\n preserveValue: true,\n ...options,\n };\n}\n\n/**\n * Awaits a promise and returns a loading value while the promise is unresolved\n *\n * @param promiseFactoryCallback A function that returns the promise to await. If this callback is\n * undefined, the current value will be returned (defaultValue unless it was previously changed\n * and `options.preserveValue` is true), and there will be no loading.\n *\n * WARNING: MUST BE STABLE - const or wrapped in useCallback. The reference must not be updated\n * every render\n * @param defaultValue The initial value to return while first awaiting the promise. If\n * `options.preserveValue` is false, this value is also shown while awaiting the promise on\n * subsequent calls.\n *\n * Note: this parameter is internally assigned to a `ref`, so changing it will not cause any hooks\n * to re-run with its new value. This means that, if the `promiseFactoryCallback` changes and\n * `options.preserveValue` is `false`, the returned value will be set to the current\n * `defaultValue`. However, the returned value will not be updated if`defaultValue` changes.\n * @param options Various options for adjusting how this hook runs the `promiseFactoryCallback`\n *\n * Note: this parameter is internally assigned to a `ref`, so changing it will not cause any hooks\n * to re-run with its new value. However, the latest `options.preserveValue` will always be used\n * appropriately to determine whether to preserve the returned value when changing the\n * `promiseFactoryCallback`\n * @returns `[value, isLoading]`\n *\n * - `value`: the current value for the promise, either the defaultValue or the resolved promise value\n * - `isLoading`: whether the promise is waiting to be resolved\n */\nconst usePromise = (\n promiseFactoryCallback: (() => Promise) | undefined,\n defaultValue: T,\n options: UsePromiseOptions = {},\n): [value: T, isLoading: boolean] => {\n // Use defaultValue as a ref so it doesn't update dependency arrays\n const defaultValueRef = useRef(defaultValue);\n defaultValueRef.current = defaultValue;\n // Use options as a ref so it doesn't update dependency arrays\n const optionsDefaultedRef = useRef(options);\n optionsDefaultedRef.current = getUsePromiseOptionsDefaults(optionsDefaultedRef.current);\n\n const [value, setValue] = useState(() => defaultValueRef.current);\n const [isLoading, setIsLoading] = useState(true);\n useEffect(() => {\n let promiseIsCurrent = true;\n // If a promiseFactoryCallback was provided, we are loading. Otherwise, there is no loading to do\n setIsLoading(!!promiseFactoryCallback);\n (async () => {\n // If there is a callback to run, run it\n if (promiseFactoryCallback) {\n const result = await promiseFactoryCallback();\n // If the promise was not already replaced, update the value\n if (promiseIsCurrent) {\n setValue(() => result);\n setIsLoading(false);\n }\n }\n })();\n\n return () => {\n // Mark this promise as old and not to be used\n promiseIsCurrent = false;\n if (!optionsDefaultedRef.current.preserveValue) setValue(() => defaultValueRef.current);\n };\n }, [promiseFactoryCallback]);\n\n return [value, isLoading];\n};\nexport default usePromise;\n","\"use client\";\n\nimport createSvgIcon from './utils/createSvgIcon';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nexport default createSvgIcon( /*#__PURE__*/_jsx(\"path\", {\n d: \"M3 18h18v-2H3zm0-5h18v-2H3zm0-7v2h18V6z\"\n}), 'Menu');","import GridMenu from '@/components/mui/grid-menu.component';\nimport { Command, CommandHandler } from '@/components/mui/menu-item.component';\nimport usePromise from '@/hooks/use-promise.hook';\nimport { Menu as MenuIcon } from '@mui/icons-material';\nimport { Drawer, IconButton } from '@mui/material';\nimport { Localized, MultiColumnMenu } from 'platform-bible-utils';\nimport {\n MouseEvent,\n MutableRefObject,\n PropsWithChildren,\n useCallback,\n useEffect,\n useState,\n} from 'react';\n\nexport interface MultiColumnMenuProvider {\n (isSupportAndDevelopment: boolean): Promise>;\n}\n\nexport type HamburgerMenuButtonProps = PropsWithChildren & {\n /** The handler to use for menu commands (and eventually toolbar commands). */\n commandHandler: CommandHandler;\n\n /**\n * Optional reference to the \"div\" container that determines the where the menu should appear. If\n * not defined, then (1,1) used.\n */\n containerRef?: MutableRefObject;\n\n /**\n * The delegate to use to get the menu data. If not specified or if it returns undefined, the data\n * in normalMenu or fullMenu property will be used.\n */\n menuProvider?: MultiColumnMenuProvider;\n\n /**\n * The menu data to show when the menu is opened if the menuProvider property is not defined.\n * (This allows for a default or test-only static menu to be used.)\n */\n normalMenu?: Localized;\n\n /**\n * The menu data to show for \"full\" menu (when opened with the SHIFT key pressed) if the\n * menuProvider property is not defined. (This allows for a default or test-only static menu to be\n * used.)\n */\n fullMenu?: Localized;\n\n /** Additional css class(es) to help with unique styling of the sub-components */\n className?: string;\n\n /** Value to use as prefix for ARIA labels on interactive sub-components */\n ariaLabelPrefix?: string;\n};\n\nexport default function HamburgerMenuButton({\n menuProvider,\n normalMenu,\n fullMenu,\n commandHandler,\n containerRef,\n className,\n ariaLabelPrefix,\n children,\n}: HamburgerMenuButtonProps) {\n const [isMenuOpen, setMenuOpen] = useState(false);\n const [showFullMenu, setShowFullMenu] = useState(false);\n\n const handleMenuItemClick = useCallback(() => {\n if (isMenuOpen) setMenuOpen(false);\n setShowFullMenu(false);\n }, [isMenuOpen]);\n\n const handleMenuButtonClick = useCallback((e: MouseEvent) => {\n e.stopPropagation();\n setMenuOpen((prevIsOpen) => {\n const isOpening = !prevIsOpen;\n if (isOpening && e.shiftKey) setShowFullMenu(true);\n else if (!isOpening) setShowFullMenu(false);\n return isOpening;\n });\n }, []);\n\n const menuCommandHandler = useCallback(\n (command: Command) => {\n handleMenuItemClick();\n return commandHandler(command);\n },\n [commandHandler, handleMenuItemClick],\n );\n\n const [offset, setOffset] = useState({ top: 1, left: 1 });\n\n useEffect(() => {\n if (isMenuOpen) {\n const node = containerRef?.current;\n if (node) {\n const rect = node.getBoundingClientRect();\n const scrollTop = window.scrollY;\n const scrollLeft = window.scrollX;\n const top = rect.top + scrollTop + node.clientHeight;\n const left = rect.left + scrollLeft;\n setOffset({ top, left });\n }\n }\n }, [isMenuOpen, containerRef]);\n\n const [normalMenuData] = usePromise(\n useCallback(async () => {\n return menuProvider?.(false) ?? normalMenu;\n // isMenuOpen needs to be included for the menu contents to reevaluate when reopened\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [menuProvider, normalMenu, isMenuOpen]),\n normalMenu,\n );\n\n const [fullMenuData] = usePromise(\n useCallback(async () => {\n return menuProvider?.(true) ?? fullMenu ?? normalMenuData;\n // isMenuOpen needs to be included for the menu contents to reevaluate when reopened\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [menuProvider, fullMenu, normalMenuData, isMenuOpen]),\n fullMenu ?? normalMenuData,\n );\n\n const menu = showFullMenu && fullMenuData ? fullMenuData : normalMenuData;\n\n return (\n <>\n \n {children ?? }\n \n \n {menu ? (\n \n ) : undefined}\n \n \n );\n}\n","import '@/components/mui/icon-button.component.css';\nimport { IconButton as MuiIconButton } from '@mui/material';\nimport { MouseEventHandler, PropsWithChildren } from 'react';\n\nexport type IconButtonProps = PropsWithChildren<{\n /** Optional unique identifier */\n id?: string;\n /**\n * Required. Used as both the tooltip (aka, title) and the aria-label (used for accessibility,\n * testing, etc.), unless a distinct tooltip is supplied.\n */\n label: string;\n /**\n * Enabled status of button\n *\n * @default false\n */\n isDisabled?: boolean;\n /** Optional tooltip to display if different from the aria-label. */\n tooltip?: string;\n /** If true, no tooltip will be displayed. */\n isTooltipSuppressed?: boolean;\n /**\n * If given, uses a negative margin to counteract the padding on one side (this is often helpful\n * for aligning the left or right side of the icon with content above or below, without ruining\n * the border size and shape).\n *\n * @default false\n */\n adjustMarginToAlignToEdge?: 'end' | 'start' | false;\n /**\n * The size of the component. small is equivalent to the dense button styling.\n *\n * @default false\n */\n size: 'small' | 'medium' | 'large';\n /** Additional css classes to help with unique styling of the button */\n className?: string;\n /** Optional click handler */\n onClick?: MouseEventHandler;\n}>;\n\n/**\n * Iconic button a user can click to do something\n *\n * Thanks to MUI for heavy inspiration and documentation\n * https://mui.com/material-ui/getting-started/overview/\n */\nfunction IconButton({\n id,\n label,\n isDisabled = false,\n tooltip,\n isTooltipSuppressed = false,\n adjustMarginToAlignToEdge = false,\n size = 'medium',\n className,\n onClick,\n children,\n}: IconButtonProps) {\n return (\n \n {children /* the icon to display */}\n \n );\n}\n\nexport default IconButton;\n","import { cn } from '@/utils/shadcn-ui.util';\nimport { LoaderCircle, LucideProps } from 'lucide-react';\nimport { forwardRef } from 'react';\n\nexport type SpinnerProps = LucideProps;\n\nconst Spinner = forwardRef(({ className, ...props }, ref) => {\n return (\n \n );\n});\n\nSpinner.displayName = 'Spinner';\n\nexport default Spinner;\n","import { Input as ShadInput } from '@/components/shadcn-ui/input';\nimport { Label as ShadLabel } from '@/components/shadcn-ui/label';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { ChangeEventHandler, FocusEventHandler } from 'react';\n\nexport type TextFieldProps = {\n /** Optional unique identifier */\n id?: string;\n /**\n * If `true`, the component is disabled.\n *\n * @default false\n */\n isDisabled?: boolean;\n /**\n * If `true`, the label is displayed in an error state.\n *\n * @default false\n */\n hasError?: boolean;\n /**\n * If `true`, the input will take up the full width of its container.\n *\n * @default false\n */\n isFullWidth?: boolean;\n /** Text that gives the user instructions on what contents the TextField expects */\n helperText?: string;\n /** The title of the TextField */\n label?: string;\n /** The short hint displayed in the `input` before the user enters a value. */\n placeholder?: string;\n /**\n * If `true`, the label is displayed as required and the `input` element is required.\n *\n * @default false\n */\n isRequired?: boolean;\n /** Additional css classes to help with unique styling of the text field */\n className?: string;\n /** Starting value for the text field if it is not controlled */\n defaultValue?: string | number;\n /** Value of the text field if controlled */\n value?: string | number;\n /** Triggers when content of textfield is changed */\n onChange?: ChangeEventHandler;\n /** Triggers when textfield gets focus */\n onFocus?: FocusEventHandler;\n /** Triggers when textfield loses focus */\n onBlur?: FocusEventHandler;\n};\n\n/**\n * Text input field\n *\n * Thanks to Shadcn for heavy inspiration and documentation\n * https://ui.shadcn.com/docs/components/input#with-label\n */\nfunction TextField({\n id,\n isDisabled = false,\n hasError = false,\n isFullWidth = false,\n helperText,\n label,\n placeholder,\n isRequired = false,\n className,\n defaultValue,\n value,\n onChange,\n onFocus,\n onBlur,\n}: TextFieldProps) {\n return (\n
    \n {`${label}${isRequired ? '*' : ''}`}\n \n

    {helperText}

    \n
    \n );\n}\n\nexport default TextField;\n","import HamburgerMenuButton, {\n MultiColumnMenuProvider,\n} from '@/components/mui/hamburger-menu-button.component';\nimport { CommandHandler } from '@/components/mui/menu-item.component';\nimport '@/components/mui/toolbar.component.css';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { AppBar, Toolbar as MuiToolbar } from '@mui/material';\nimport { PropsWithChildren, useRef } from 'react';\n\nexport type ToolbarProps = PropsWithChildren<{\n /** The handler to use for menu commands (and eventually toolbar commands). */\n commandHandler: CommandHandler;\n\n /**\n * The optional delegate to use to get the menu data. If not specified, the \"hamburger\" menu will\n * not display.\n */\n menuProvider?: MultiColumnMenuProvider;\n\n /** Optional unique identifier */\n id?: string;\n\n /** Additional css classes to help with unique styling of the toolbar */\n className?: string;\n}>;\n\nexport default function Toolbar({\n menuProvider,\n commandHandler,\n className,\n id,\n children,\n}: ToolbarProps) {\n // This ref will always be defined\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const containerRef = useRef(undefined!);\n\n return (\n
    \n \n \n {menuProvider ? (\n \n ) : undefined}\n {children ?
    {children}
    : undefined}\n \n
    \n
    \n );\n}\n","import React from 'react';\nimport { cva, type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst alertVariants = cva(\n 'tw-relative tw-w-full tw-rounded-lg tw-border tw-p-4 [&>svg~*]:tw-pl-7 [&>svg+div]:tw-translate-y-[-3px] [&>svg]:tw-absolute [&>svg]:tw-left-4 [&>svg]:tw-top-4 [&>svg]:tw-text-foreground',\n {\n variants: {\n variant: {\n default: 'tw-bg-background tw-text-foreground',\n destructive:\n 'tw-border-destructive/50 tw-text-destructive dark:tw-border-destructive [&>svg]:tw-text-destructive',\n },\n },\n defaultVariants: {\n variant: 'default',\n },\n },\n);\n\nconst Alert = React.forwardRef<\n HTMLDivElement,\n React.HTMLAttributes & VariantProps\n>(({ className, variant, ...props }, ref) => (\n
    \n));\nAlert.displayName = 'Alert';\n\nconst AlertTitle = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n {/* added because of https://github.com/jsx-eslint/eslint-plugin-jsx-a11y/blob/main/docs/rules/heading-has-content.md */}\n {props.children}{' '}\n \n ),\n);\nAlertTitle.displayName = 'AlertTitle';\n\nconst AlertDescription = React.forwardRef<\n HTMLParagraphElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n
    \n));\nAlertDescription.displayName = 'AlertDescription';\n\nexport { Alert, AlertTitle, AlertDescription };\n","import React from 'react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Card = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nCard.displayName = 'Card';\n\nconst CardHeader = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nCardHeader.displayName = 'CardHeader';\n\nconst CardTitle = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n {/* added because of https://github.com/jsx-eslint/eslint-plugin-jsx-a11y/blob/main/docs/rules/heading-has-content.md */}\n {props.children}\n \n ),\n);\nCardTitle.displayName = 'CardTitle';\n\nconst CardDescription = React.forwardRef<\n HTMLParagraphElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n

    \n));\nCardDescription.displayName = 'CardDescription';\n\nconst CardContent = React.forwardRef>(\n ({ className, ...props }, ref) => (\n

    \n ),\n);\nCardContent.displayName = 'CardContent';\n\nconst CardFooter = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nCardFooter.displayName = 'CardFooter';\n\nexport { Card, CardHeader, CardFooter, CardTitle, CardDescription, CardContent };\n","import { ComponentProps } from 'react';\nimport { toast as sonner, Toaster } from 'sonner';\n\ntype SonnerProps = ComponentProps;\n\nfunction Sonner({ ...props }: SonnerProps) {\n return (\n \n );\n}\n\n// The re-export of the sonner function was added manually\nexport { Sonner, sonner };\n","import React from 'react';\nimport * as SliderPrimitive from '@radix-ui/react-slider';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Slider = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n \n \n \n));\nSlider.displayName = SliderPrimitive.Root.displayName;\n\nexport { Slider };\n","import React from 'react';\nimport * as SwitchPrimitives from '@radix-ui/react-switch';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Switch = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n));\nSwitch.displayName = SwitchPrimitives.Root.displayName;\n\nexport { Switch };\n","import React from 'react';\nimport * as TabsPrimitive from '@radix-ui/react-tabs';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport const Tabs = TabsPrimitive.Root;\n\nexport type TabsListProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport type TabsTriggerProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport type TabsContentProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport const TabsList = React.forwardRef<\n React.ElementRef,\n TabsListProps\n>(({ className, ...props }, ref) => (\n \n));\nTabsList.displayName = TabsPrimitive.List.displayName;\n\nexport const TabsTrigger = React.forwardRef<\n React.ElementRef,\n TabsTriggerProps\n>(({ className, ...props }, ref) => (\n \n));\nTabsTrigger.displayName = TabsPrimitive.Trigger.displayName;\n\nexport const TabsContent = React.forwardRef<\n React.ElementRef,\n TabsContentProps\n>(({ className, ...props }, ref) => (\n \n));\nTabsContent.displayName = TabsPrimitive.Content.displayName;\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Download } from 'lucide-react';\n\ntype InstallButtonProps = {\n /** The installing boolean value determines the state of the button. */\n isInstalling: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n /** Optional text for the button. */\n buttonText?: string;\n} & ButtonProps;\n\n/**\n * The InstallButton component is a button designed for initiating installs. It includes visuals for\n * active installing and idle states.\n *\n * @param isInstalling The installing boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @param buttonText Optional text for the button.\n * @returns A install button.\n */\nexport default function InstallButton({\n isInstalling,\n handleClick,\n buttonText,\n className,\n ...props\n}: InstallButtonProps) {\n return (\n \n {isInstalling ? (\n \n ) : (\n <>\n \n {buttonText}\n \n )}\n \n );\n}\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\n\ntype EnableButtonProps = {\n /** The enabling boolean value determines the state of the button. */\n isEnabling: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n} & ButtonProps;\n\n/**\n * The EnableButton component is a button designed for initiating enabling of downloads. It includes\n * visuals for active enabling and idle states.\n *\n * @param isEnabling The enabling boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @returns A button that can be used to enable.\n */\nexport default function EnableButton({\n isEnabling,\n handleClick,\n className,\n ...props\n}: EnableButtonProps) {\n return (\n \n {isEnabling ? (\n <>\n \n Enabling...\n \n ) : (\n 'Enable'\n )}\n \n );\n}\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\n\ntype DisableButtonProps = {\n /** The disabling boolean value determines the state of the button. */\n isDisabling: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n} & ButtonProps;\n\n/**\n * The DisableButton component is a button designed for initiating disabling of downloads. It\n * includes visuals for active disabling and idle states.\n *\n * @param isDisabling The disabling boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @returns A button that can be used to disable.\n */\nexport default function DisableButton({\n isDisabling,\n handleClick,\n className,\n ...props\n}: DisableButtonProps) {\n return (\n \n {isDisabling ? (\n <>\n \n Disabling...\n \n ) : (\n 'Disable'\n )}\n \n );\n}\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\n\ntype UpdateButtonProps = {\n /** The updating boolean value determines the state of the button. */\n isUpdating: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n} & ButtonProps;\n\n/**\n * The UpdateButton component is a button designed for initiating updates for downloaded extensions.\n * It includes visuals for active updating and idle states.\n *\n * @param isUpdating The updating boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @returns A button that can be used to update.\n */\nexport default function UpdateButton({\n isUpdating,\n handleClick,\n className,\n ...props\n}: UpdateButtonProps) {\n return (\n \n {isUpdating ? (\n <>\n \n Updating...\n \n ) : (\n 'Update'\n )}\n \n );\n}\n","import { cn } from '@/utils/shadcn-ui.util';\nimport Markdown, { MarkdownToJSX } from 'markdown-to-jsx';\nimport { useMemo } from 'react';\n\ninterface MarkdownRendererProps {\n /** Optional unique identifier */\n id?: string;\n /** The markdown string to render */\n markdown: string;\n className?: string;\n /**\n * The [`target` attribute for `a` html\n * tags](https://developer.mozilla.org/en-US/docs/Web/HTML/Element/a#target). Defaults to not\n * adding a `target` to `a` tags\n */\n anchorTarget?: string;\n}\n\n/**\n * This component renders markdown content given a markdown string. It uses typography styles from\n * the platform.\n *\n * @param markdown The markdown string to render.\n * @param id Optional unique identifier\n * @returns A div containing the rendered markdown content.\n */\nexport default function MarkdownRenderer({\n id,\n markdown,\n className,\n anchorTarget,\n}: MarkdownRendererProps) {\n const options: MarkdownToJSX.Options = useMemo(\n () => ({\n overrides: {\n a: {\n props: {\n target: anchorTarget,\n },\n },\n },\n }),\n [anchorTarget],\n );\n return (\n
    \n {markdown}\n
    \n );\n}\n","import { Filter, ChevronDown } from 'lucide-react';\nimport { forwardRef } from 'react';\nimport { Button } from '@/components/shadcn-ui/button';\n\n/**\n * The FilterButton component is a button designed for initiating filtering of data. It is designed\n * to be used with the dropdown menu. It uses forwardRef to pass the button to the dropdown trigger\n * asChild.\n *\n * @returns A button that can be used to filter.\n */\nconst FilterButton = forwardRef((props, ref) => {\n return (\n \n \n Filter\n \n \n );\n});\n\nexport default FilterButton;\n","import {\n DropdownMenu,\n DropdownMenuTrigger,\n DropdownMenuContent,\n DropdownMenuLabel,\n DropdownMenuGroup,\n DropdownMenuCheckboxItem,\n DropdownMenuRadioItem,\n DropdownMenuSeparator,\n} from '@/components/shadcn-ui/dropdown-menu';\nimport FilterButton from './buttons/filter-button.component';\n\nexport enum DropdownMenuItemType {\n Check,\n Radio,\n}\n\nexport type DropdownItem = {\n /** The label is the text that will be displayed on the dropdown item. */\n label: string;\n /** The itemType determines the DropdownMenuItemType type as either Check or Radio. */\n itemType: DropdownMenuItemType;\n /** The onClick function is called when the item is clicked. */\n onClick: () => void;\n};\n\nexport type DropdownGroup = {\n /**\n * The label is the text that will be displayed on the dropdown group. It is used to categorize\n * the items in the group.\n */\n label: string;\n /** The items array contains the items that will be displayed in the dropdown group */\n items: DropdownItem[];\n};\n\nexport type FilterDropdownProps = {\n /** Object unique identifier */\n id?: string;\n /** The groups array contains the groups that will be displayed in the dropdown */\n groups: DropdownGroup[];\n}; // TODO: extend the props later\n\n/**\n * The FilterDropdown component is a dropdown designed for filtering content. It includes groups of\n * items that can be checkboxes or radio items.\n *\n * @param id Optional unique identifier\n * @param groups The groups array contains the groups that will be displayed in the dropdown\n * @returns A filter dropdown.\n */\nexport default function FilterDropdown({ id, groups }: FilterDropdownProps) {\n return (\n
    \n {/* TODO: remove this once the DropDown Menu shadcn has an id prop */}\n \n \n \n \n \n {groups.map((group) => (\n
    \n {group.label}\n \n {group.items.map((item) => (\n
    \n {item.itemType === DropdownMenuItemType.Check ? (\n \n {item.label}\n \n ) : (\n \n {item.label}\n \n )}\n
    \n ))}\n
    \n \n
    \n ))}\n
    \n
    \n
    \n );\n}\n","interface NoExtensionsFoundProps {\n /** Optional unique identifier */\n id?: string;\n /** The message to display */\n message: string;\n}\n/**\n * This component displays a message to the user when no extensions are found in the marketplace.\n *\n * @param id Optional unique identifier\n * @param message The message to display.\n * @returns {JSX.Element} - Returns the message component that displays the message to the user.\n */\nexport default function NoExtensionsFound({ id, message }: NoExtensionsFoundProps) {\n return (\n
    \n
    \n

    {message}

    \n
    \n
    \n );\n}\n","import { CircleHelp, Link as LucideLink, User } from 'lucide-react';\nimport { NumberFormat } from 'platform-bible-utils';\n\n/** Interface that stores the parameters passed to the More Info component */\ninterface MoreInfoProps {\n /** Optional unique identifier */\n id?: string;\n /** The category of the extension */\n category: string;\n /** The number of downloads for the extension */\n downloads: Record;\n /** The languages supported by the extension */\n languages: string[];\n /** The URL to the more info page of the extension */\n moreInfoUrl: string;\n}\n/**\n * This component displays the more info section of the extension which includes the category,\n * number of downloads, languages, and links to the website and support\n *\n * @param id Optional unique identifier\n * @param category The category of the extension\n * @param downloads The number of downloads for the extension\n * @param languages The languages supported by the extension\n * @param moreInfoUrl The URL to the more info page of the extension\n * @returns {JSX.Element} - Returns the more info component that displays the category, number of\n * downloads, languages, and links to the website and support\n */\nexport default function MoreInfo({\n id,\n category,\n downloads,\n languages,\n moreInfoUrl,\n}: MoreInfoProps) {\n /**\n * This constant formats the number of downloads into a more readable format.\n *\n * @example 1000 -> 1K\n *\n * @example 1000000 -> 1M\n *\n * @returns The formatted number of downloads\n */\n const numberFormatted = new NumberFormat('en', {\n notation: 'compact',\n compactDisplay: 'short',\n }).format(Object.values(downloads).reduce((a: number, b: number) => a + b, 0));\n\n /** This function scrolls the window to the bottom of the page. */\n const handleScrollToBottom = () => {\n window.scrollTo(0, document.body.scrollHeight);\n };\n\n return (\n \n
    \n
    \n {category}\n
    \n CATEGORY\n
    \n
    \n
    \n
    \n \n {numberFormatted}\n
    \n USERS\n
    \n
    \n
    \n
    \n {languages.slice(0, 3).map((locale) => (\n \n {locale.toUpperCase()}\n \n ))}\n
    \n {languages.length > 3 && (\n handleScrollToBottom()}\n className=\"tw-text-xs tw-text-gray-500 tw-underline\"\n >\n +{languages.length - 3} more languages\n \n )}\n
    \n
    \n
    \n \n Website\n \n \n \n Support\n \n \n
    \n
    \n );\n}\n","import { useState } from 'react';\n\nexport type VersionInformation = {\n /** Date the version was published */\n date: string;\n /** Description of the changes in the version */\n description: string;\n};\n\n/** Type to store the version history information */\nexport type VersionHistoryType = Record;\n\n/** Interface that stores the parameters passed to the Version History component */\ninterface VersionHistoryProps {\n /** Optional unique identifier */\n id?: string;\n /** Object containing the versions mapped with their information */\n versionHistory: VersionHistoryType;\n}\n\n/**\n * Component to render the version history information shown in the footer component. Lists the 5\n * most recent versions, with the options to show all versions by pressing a button.\n *\n * @param versionHistory Object containing the versions mapped with their information\n * @param id Optional unique identifier\n * @returns Rendered version history for the Footer component\n */\nexport default function VersionHistory({ id, versionHistory }: VersionHistoryProps) {\n const [showAllVersions, setShowAllVersions] = useState(false);\n const currentDate = new Date();\n\n /**\n * Function to format the time string for the version history in the form of 'X year(s) ago'.\n *\n * @param dateString ISO Date string to determine the time string from\n * @returns Formatted time string\n */\n function formatTimeString(dateString: string) {\n const date = new Date(dateString);\n const dateDiff = new Date(currentDate.getTime() - date.getTime());\n const yearDiff = dateDiff.getUTCFullYear() - 1970;\n const monthDiff = dateDiff.getUTCMonth();\n const dayDiff = dateDiff.getUTCDate() - 1;\n\n // Determines how long ago the version was published\n let timeString = '';\n if (yearDiff > 0) {\n timeString = `${yearDiff.toString()} year${yearDiff === 1 ? '' : 's'} ago`;\n } else if (monthDiff > 0) {\n timeString = `${monthDiff.toString()} month${monthDiff === 1 ? '' : 's'} ago`;\n } else if (dayDiff === 0) {\n timeString = 'today';\n } else {\n timeString = `${dayDiff.toString()} day${dayDiff === 1 ? '' : 's'} ago`;\n }\n\n return timeString;\n }\n\n // Sorts the version history by version number\n const sortedEntries = Object.entries(versionHistory).sort((a, b) => b[0].localeCompare(a[0]));\n\n return (\n
    \n

    What`s New

    \n
      \n {(showAllVersions ? sortedEntries : sortedEntries.slice(0, 5)).map((entry) => (\n
      \n
      \n
    • \n {entry[1].description}\n
    • \n
      \n
      \n
      Version {entry[0]}
      \n
      {formatTimeString(entry[1].date)}
      \n
      \n
      \n ))}\n
    \n {sortedEntries.length > 5 && (\n setShowAllVersions(!showAllVersions)}\n className=\"tw-text-xs tw-text-gray-500 tw-underline\"\n >\n {showAllVersions ? 'Show Less Version History' : 'Show All Version History'}\n \n )}\n
    \n );\n}\n","import { useMemo } from 'react';\nimport { formatBytes } from 'platform-bible-utils';\nimport VersionHistory, { VersionHistoryType } from './version-history.component';\n\n/** Interface to store the parameters passed to the Footer component */\ninterface FooterProps {\n /** Optional unique identifier */\n id?: string;\n /** Name of the publisher */\n publisherDisplayName: string;\n /** Size of the extension file in bytes */\n fileSize: number;\n /** List of language codes supported by the extension */\n locales: string[];\n /** Object containing the version history mapped with their information */\n versionHistory: VersionHistoryType;\n}\n\n/**\n * Component to render the footer for the extension details which contains information on the\n * publisher, version history, languages, and file size.\n *\n * @param id Optional unique identifier\n * @param publisherDisplayName Name of the publisher\n * @param fileSize Size of the extension file in bytes\n * @param locales List of language codes supported by the extension\n * @param versionHistory Object containing the version history mapped with their information\n * @returns The rendered Footer component\n */\nexport default function Footer({\n id,\n publisherDisplayName,\n fileSize,\n locales,\n versionHistory,\n}: FooterProps) {\n /** Formats the file size into a human-readable format */\n const formattedFileSize = useMemo(() => formatBytes(fileSize), [fileSize]);\n\n /**\n * This function gets the display names of the languages based on the language codes.\n *\n * @param codes The list of language codes\n * @returns The list of language names\n */\n const getLanguageNames = (codes: string[]) => {\n const displayNames = new Intl.DisplayNames(navigator.language, { type: 'language' });\n return codes.map((code) => displayNames.of(code));\n };\n\n const languageNames = getLanguageNames(locales);\n\n return (\n
    \n
    \n \n
    \n
    \n

    Information

    \n
    \n

    \n Publisher\n {publisherDisplayName}\n Size\n {formattedFileSize}\n

    \n
    \n

    \n Languages\n {languageNames.join(', ')}\n

    \n
    \n
    \n
    \n
    \n
    \n );\n}\n","import { PlatformEvent, PlatformEventHandler } from 'platform-bible-utils';\nimport { useEffect } from 'react';\n\n/**\n * Adds an event handler to an event so the event handler runs when the event is emitted. Use\n * `papi.network.getNetworkEvent` to use a networked event with this hook.\n *\n * @param event The event to subscribe to.\n *\n * - If event is a `PlatformEvent`, that event will be used\n * - If event is undefined, the callback will not be subscribed. Useful if the event is not yet\n * available for example\n *\n * @param eventHandler The callback to run when the event is emitted\n *\n * WARNING: MUST BE STABLE - const or wrapped in useCallback. The reference must not be updated\n * every render\n */\nconst useEvent = (\n event: PlatformEvent | undefined,\n eventHandler: PlatformEventHandler,\n) => {\n useEffect(() => {\n // Do nothing if the event is not provided (in case the event is not yet available, for example)\n if (!event) return () => {};\n\n const unsubscriber = event(eventHandler);\n return () => {\n unsubscriber();\n };\n }, [event, eventHandler]);\n};\nexport default useEvent;\n","import { useCallback, useEffect } from 'react';\nimport { PlatformEvent, PlatformEventAsync, PlatformEventHandler } from 'platform-bible-utils';\nimport usePromise from './use-promise.hook';\n\nconst noopUnsubscriber = () => false;\n\n/**\n * Adds an event handler to an asynchronously subscribing/unsubscribing event so the event handler\n * runs when the event is emitted. Use `papi.network.getNetworkEvent` to use a networked event with\n * this hook.\n *\n * @param event The asynchronously (un)subscribing event to subscribe to.\n *\n * - If event is a `PlatformEvent` or `PlatformEventAsync`, that event will be used\n * - If event is undefined, the callback will not be subscribed. Useful if the event is not yet\n * available for example\n *\n * @param eventHandler The callback to run when the event is emitted\n *\n * WARNING: MUST BE STABLE - const or wrapped in useCallback. The reference must not be updated\n * every render\n */\nconst useEventAsync = (\n event: PlatformEvent | PlatformEventAsync | undefined,\n eventHandler: PlatformEventHandler,\n) => {\n // Subscribe to the event asynchronously\n const [unsubscribe] = usePromise(\n useCallback(async () => {\n // Do nothing if the event is not provided (in case the event is not yet available, for example)\n if (!event) return noopUnsubscriber;\n\n // Wrap subscribe and unsubscribe in promises to allow normal events to be used as well\n const unsub = await Promise.resolve(event(eventHandler));\n return async () => unsub();\n }, [eventHandler, event]),\n noopUnsubscriber,\n // We want the unsubscriber to return to default value immediately upon changing subscription\n // So the useEffect below will unsubscribe asap\n { preserveValue: false },\n );\n\n // Unsubscribe from the event asynchronously (but we aren't awaiting the unsub)\n useEffect(() => {\n return () => {\n if (unsubscribe !== noopUnsubscriber) {\n unsubscribe();\n }\n };\n }, [unsubscribe]);\n};\n\nexport default useEventAsync;\n"],"names":["twMergeCustom","extendTailwindMerge","cn","inputs","clsx","Input","React","className","type","props","ref","jsx","BookChapterInput","forwardRef","handleSearch","handleKeyDown","handleOnClick","handleSubmit","jsxs","ShadInput","event","e","History","P","R","t","s","n","N","B","O","S","K","g","k","x","T","X","V","w","L","G","A","H","C","I","y","q","U","m","l","h","c","E","D","i","a","o","u","v","f","d","b","p","J","DropdownMenu","DropdownMenuPrimitive","DropdownMenuTrigger","DropdownMenuGroup","DropdownMenuPortal","DropdownMenuSub","DropdownMenuRadioGroup","DropdownMenuSubTrigger","inset","children","ChevronRight","DropdownMenuSubContent","DropdownMenuContent","sideOffset","DropdownMenuItem","DropdownMenuCheckboxItem","checked","Check","DropdownMenuRadioItem","Circle","DropdownMenuLabel","DropdownMenuSeparator","DropdownMenuShortcut","BookMenuItem","bookId","handleSelectBook","isSelected","handleHighlightBook","bookType","ShadDropdownMenuItem","Canon","ChapterSelect","handleSelectChapter","endChapter","activeChapter","highlightedChapter","handleHighlightedChapter","chapters","_","handleMouse","useCallback","chapterNumber","chapter","GoToMenuItem","handleSort","handleLocationHistory","handleBookmarks","ShadDropdownMenuLabel","ArrowDownWideNarrow","Clock","Bookmark","ALL_BOOK_IDS","BOOK_TYPE_LABELS","BOOK_TYPE_ARRAY","SCROLL_OFFSET","SEARCH_QUERY_FORMATS","fetchGroupedBooks","fetchEndChapter","getChaptersForBook","getAllEnglishNames","isValidBookEnglishName","bookName","getBookIdFromEnglishName","formattedBookName","BookChapterControl","scrRef","searchQuery","setSearchQuery","useState","selectedBookId","setSelectedBookId","setHighlightedChapter","highlightedBookId","setHighlightedBookId","isContentOpen","setIsContentOpen","isContentOpenDelayed","setIsContentOpenDelayed","inputRef","useRef","contentRef","menuItemRef","fetchFilteredBooks","englishNameLowerCase","normalizedQuery","handleSearchInput","searchString","shouldPreventAutoClosing","controlMenuState","open","updateReference","shouldClose","verse","handleInputSubmit","format","matches","book","englishName","handleKeyDownInput","handleKeyDownContent","key","handleKeyDownMenuItem","chapterOffSet","useEffect","useLayoutEffect","scrollTimeout","scrollPosition","ShadDropdownMenu","ShadDropdownMenuTrigger","ShadDropdownMenuContent","bookTypeIndex","element","ShadDropdownMenuSeparator","buttonVariants","cva","Button","variant","size","asChild","Comp","Slot","labelVariants","Label","LabelPrimitive","RadioGroup","RadioGroupPrimitive","RadioGroupItem","Popover","PopoverPrimitive","PopoverTrigger","PopoverContent","align","DialogPortal","DialogPrimitive","DialogOverlay","DialogContent","DialogTitle","DialogDescription","Command","CommandPrimitive","CommandInput","Search","CommandList","CommandEmpty","CommandGroup","CommandSeparator","CommandItem","getOptionLabelDefault","option","ComboBox","id","options","buttonClassName","popoverContentClassName","value","onChange","getOptionLabel","buttonPlaceholder","textPlaceholder","commandEmptyMessage","buttonVariant","dir","isDisabled","setOpen","ChevronsUpDown","ChapterRangeSelector","startChapter","handleSelectStartChapter","handleSelectEndChapter","chapterCount","chapterOptions","useMemo","index","onChangeStartChapter","onChangeEndChapter","Fragment","BookSelectionMode","BOOK_SELECTOR_STRING_KEYS","localizeString","strings","BookSelector","handleBookSelectionModeChange","currentBookName","onSelectBooks","selectedBookIds","localizedStrings","currentBookText","chooseText","chooseBooksText","bookSelectionMode","setBookSelectionMode","onSelectionModeChange","newMode","DataTableViewOptions","table","FilterIcon","column","Select","SelectPrimitive","SelectGroup","SelectValue","SelectTrigger","ChevronDown","SelectScrollUpButton","ChevronUp","SelectScrollDownButton","SelectContent","position","SelectLabel","SelectItem","SelectSeparator","DataTablePagination","pageSize","ArrowLeftIcon","ChevronLeftIcon","ChevronRightIcon","ArrowRightIcon","Table","stickyHeader","TableHeader","TableBody","TableFooter","TableRow","TableHead","TableCell","TableCaption","DataTable","columns","data","enablePagination","showPaginationControls","showColumnVisibilityControls","onRowClickHandler","sorting","setSorting","columnFilters","setColumnFilters","columnVisibility","setColumnVisibility","rowSelection","setRowSelection","useReactTable","getCoreRowModel","getPaginationRowModel","getSortedRowModel","getFilteredRowModel","headerGroup","header","flexRender","_a","row","cell","OccurrencesTable","occurrenceData","setScriptureReference","referenceHeaderText","occurrenceHeaderText","occurrences","uniqueOccurrences","occurrence","uniqueOccurrence","deepEqual","Checkbox","CheckboxPrimitive","getLinesFromUSFM","text","getNumberFromUSFM","regex","match","getBookNumFromId","getStatusForItem","item","approvedItems","unapprovedItems","toggleVariants","Toggle","TogglePrimitive","ToggleGroupContext","ToggleGroup","ToggleGroupPrimitive","ToggleGroupItem","context","getSortingIcon","sortDirection","ArrowUpIcon","ArrowDownIcon","ArrowUpDownIcon","inventoryItemColumn","itemLabel","inventoryAdditionalItemColumn","additionalItemLabel","additionalItemIndex","inventoryCountColumn","countLabel","statusChangeHandler","changedItems","newStatus","onApprovedItemsChange","onUnapprovedItemsChange","newApprovedItems","validItem","newUnapprovedItems","unapprovedItem","inventoryStatusColumn","statusLabel","status","CircleCheckIcon","CircleXIcon","CircleHelpIcon","INVENTORY_STRING_KEYS","filterItemData","itemData","statusFilter","textFilter","filteredItemData","createTableData","scriptureRef","itemRegex","tableData","currentBook","currentChapter","currentVerse","line","items","itemIndex","existingItem","tableEntry","newReference","substring","newItem","Inventory","scriptureReference","extractItems","additionalItemsLabels","scope","onScopeChange","allItemsText","approvedItemsText","unapprovedItemsText","unknownItemsText","scopeBookText","scopeChapterText","scopeVerseText","filterText","showAdditionalItemsText","showAdditionalItems","setShowAdditionalItems","setStatusFilter","setTextFilter","selectedItem","setSelectedItem","reducedTableData","newTableData","firstItem","existingEntry","newTableEntry","filteredTableData","allColumns","numberOfAdditionalItems","additionalColumns","_b","rowClickHandler","newSelection","handleScopeChange","handleStatusFilterChange","SearchBar","onSearch","placeholder","isFullWidth","handleInputChange","VerticalTabs","TabsPrimitive","VerticalTabsList","VerticalTabsTrigger","VerticalTabsContent","TabNavigationContentSearch","tabList","searchPlaceholder","headerTitle","isSearchBarFullWidth","direction","tab","Separator","orientation","decorative","SeparatorPrimitive","Sheet","SheetPrimitive","SheetPortal","SheetOverlay","sheetVariants","SheetContent","side","SheetTitle","SheetDescription","Skeleton","TooltipProvider","TooltipPrimitive","Tooltip","TooltipTrigger","TooltipContent","MOBILE_BREAKPOINT","useIsMobile","isMobile","setIsMobile","mql","SIDEBAR_COOKIE_NAME","SIDEBAR_COOKIE_MAX_AGE","SIDEBAR_WIDTH","SIDEBAR_WIDTH_MOBILE","SIDEBAR_WIDTH_ICON","SIDEBAR_KEYBOARD_SHORTCUT","SidebarContext","useSidebar","SidebarProvider","defaultOpen","openProp","setOpenProp","style","openMobile","setOpenMobile","_open","_setOpen","isOpen","openState","toggleSidebar","state","contextValue","Sidebar","collapsible","SidebarTrigger","onClick","PanelLeft","SidebarRail","SidebarInset","SidebarInput","SidebarHeader","SidebarFooter","SidebarSeparator","SidebarContent","SidebarGroup","SidebarGroupLabel","SidebarGroupAction","SidebarGroupContent","SidebarMenu","SidebarMenuItem","sidebarMenuButtonVariants","SidebarMenuButton","isActive","tooltip","button","SidebarMenuAction","showOnHover","SidebarMenuBadge","SidebarMenuSkeleton","showIcon","width","SidebarMenuSub","SidebarMenuSubItem","SidebarMenuSubButton","SettingsSidebar","extensionLabels","projectOptions","handleSelectSidebarItem","selectedSidebarItem","extensionsSidebarGroupLabel","projectsSidebarGroupLabel","handleSelectItem","projectId","getProjectNameFromProjectId","project","getIsActive","label","selectedProjectName","SettingsSidebarContentSearch","scrBookColId","scrRefColId","typeColId","detailsColId","defaultScrRefColumnName","defaultScrBookGroupName","defaultTypeColumnName","defaultDetailsColumnName","getColumns","colInfo","showSourceColumn","showSrcCol","info","formatScrRef","compareScrRefs","toRefOrRange","scriptureSelection","offsetStart","offsetEnd","scrRefToBBBCCCVVV","getRowKey","ScriptureResultsViewer","sources","showColumnHeaders","scriptureReferenceColumnName","scriptureBookGroupName","typeColumnName","detailsColumnName","onRowSelected","grouping","setGrouping","scriptureResults","source","getExpandedRowModel","getGroupedRowModel","selectedRows","keys","selectedRow","scrBookGroupName","typeGroupName","groupingOptions","handleSelectChange","selectedGrouping","handleRowClick","getEvenOrOddBandingStyle","getIndent","groupingState","rowIndex","ChevronLeft","DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS","getLocalizeKeyForScrollGroupId","ScrollGroupSelector","availableScrollGroupIds","scrollGroupId","onChangeScrollGroupId","localizedStringsDefaulted","localizedStringKey","localizedStringValue","newScrollGroupString","scrollGroupOptionId","SettingsList","SettingsListItem","primary","secondary","isLoading","loadingMessage","SettingsListHeader","includeSeparator","Checklist","listItems","selectedListItems","handleSelectListItem","createLabel","_interopRequireDefault","obj","module","chainPropTypes","propType1","propType2","args","_extends","target","isPlainObject","prototype","deepClone","output","deepmerge","r","z","reactIs_production_min","hasSymbol","REACT_ELEMENT_TYPE","REACT_PORTAL_TYPE","REACT_FRAGMENT_TYPE","REACT_STRICT_MODE_TYPE","REACT_PROFILER_TYPE","REACT_PROVIDER_TYPE","REACT_CONTEXT_TYPE","REACT_ASYNC_MODE_TYPE","REACT_CONCURRENT_MODE_TYPE","REACT_FORWARD_REF_TYPE","REACT_SUSPENSE_TYPE","REACT_SUSPENSE_LIST_TYPE","REACT_MEMO_TYPE","REACT_LAZY_TYPE","REACT_BLOCK_TYPE","REACT_FUNDAMENTAL_TYPE","REACT_RESPONDER_TYPE","REACT_SCOPE_TYPE","isValidElementType","typeOf","object","$$typeof","$$typeofType","AsyncMode","ConcurrentMode","ContextConsumer","ContextProvider","Element","ForwardRef","Lazy","Memo","Portal","Profiler","StrictMode","Suspense","hasWarnedAboutDeprecatedIsAsyncMode","isAsyncMode","isConcurrentMode","isContextConsumer","isContextProvider","isElement","isForwardRef","isFragment","isLazy","isMemo","isPortal","isProfiler","isStrictMode","isSuspense","reactIs_development","reactIsModule","require$$0","require$$1","getOwnPropertySymbols","hasOwnProperty","propIsEnumerable","toObject","val","shouldUseNative","test1","test2","order2","test3","letter","objectAssign","from","to","symbols","ReactPropTypesSecret","ReactPropTypesSecret_1","has","printWarning","loggedTypeFailures","message","checkPropTypes","typeSpecs","values","location","componentName","getStack","typeSpecName","error","err","ex","stack","checkPropTypes_1","ReactIs","assign","require$$2","require$$3","require$$4","emptyFunctionThatReturnsNull","factoryWithTypeCheckers","isValidElement","throwOnDirectAccess","ITERATOR_SYMBOL","FAUX_ITERATOR_SYMBOL","getIteratorFn","maybeIterable","iteratorFn","ANONYMOUS","ReactPropTypes","createPrimitiveTypeChecker","createAnyTypeChecker","createArrayOfTypeChecker","createElementTypeChecker","createElementTypeTypeChecker","createInstanceTypeChecker","createNodeChecker","createObjectOfTypeChecker","createEnumTypeChecker","createUnionTypeChecker","createShapeTypeChecker","createStrictShapeTypeChecker","is","PropTypeError","createChainableTypeChecker","validate","manualPropTypeCallCache","manualPropTypeWarningCount","checkType","isRequired","propName","propFullName","secret","cacheKey","chainedCheckType","expectedType","propValue","propType","getPropType","preciseType","getPreciseType","typeChecker","expectedClass","expectedClassName","actualClassName","getClassName","expectedValues","valuesString","arrayOfTypeCheckers","checker","getPostfixForTypeWarning","expectedTypes","checkerResult","expectedTypesMessage","isNode","invalidValidatorError","shapeTypes","allKeys","iterator","step","entry","isSymbol","emptyFunction","emptyFunctionWithReset","factoryWithThrowingShims","shim","getShim","propTypesModule","isClassComponent","elementType","acceptingRef","safePropName","warningHint","elementAcceptingRef","PropTypes","elementAcceptingRef$1","specialProperty","exactProp","propTypes","unsupportedProps","prop","formatMuiErrorMessage","code","url","REACT_SERVER_CONTEXT_TYPE","REACT_OFFSCREEN_TYPE","enableScopeAPI","enableCacheElement","enableTransitionTracing","enableLegacyHidden","enableDebugTracing","REACT_MODULE_REFERENCE","SuspenseList","hasWarnedAboutDeprecatedIsConcurrentMode","isSuspenseList","fnNameMatchRegex","getFunctionName","fn","getFunctionComponentName","Component","fallback","getWrappedName","outerType","innerType","wrapperName","functionName","getDisplayName","HTMLElementType","refType","refType$1","capitalize","string","_formatMuiErrorMessage","createChainedFunction","funcs","acc","func","debounce","wait","timeout","debounced","later","deprecatedPropType","validator","reason","componentNameSafe","propFullNameSafe","isMuiElement","muiNames","_muiName","_element$type","ownerDocument","node","ownerWindow","requirePropFactory","componentNameInError","prevPropTypes","requiredProp","defaultTypeChecker","typeCheckerResult","setRef","useEnhancedEffect","useEnhancedEffect$1","globalId","useGlobalId","idOverride","defaultId","setDefaultId","maybeReactUseId","useId","reactId","unsupportedProp","useControlled","controlled","defaultProp","name","isControlled","valueState","setValue","defaultValue","setValueIfUncontrolled","newValue","useEventCallback","useForkRef","refs","instance","UNINITIALIZED","useLazyRef","init","initArg","EMPTY","useOnMount","Timeout","delay","useTimeout","hadKeyboardEvent","hadFocusVisibleRecently","hadFocusVisibleRecentlyTimeout","inputTypesWhitelist","focusTriggersKeyboardModality","tagName","handlePointerDown","handleVisibilityChange","prepare","doc","isFocusVisible","useIsFocusVisible","isFocusVisibleRef","handleBlurVisible","handleFocusVisible","resolveProps","defaultProps","defaultSlotProps","slotProps","slotPropName","composeClasses","slots","getUtilityClass","classes","slot","utilityClass","defaultGenerator","createClassNameGenerator","generate","generator","ClassNameGenerator","ClassNameGenerator$1","globalStateClasses","generateUtilityClass","globalStatePrefix","globalStateClass","generateUtilityClasses","result","clamp","min","max","_objectWithoutPropertiesLoose","excluded","sourceKeys","_excluded","sortBreakpointsValues","breakpointsAsArray","breakpoint1","breakpoint2","createBreakpoints","breakpoints","unit","other","sortedValues","up","down","between","start","end","endIndex","only","not","keyIndex","shape","shape$1","responsivePropType","responsivePropType$1","merge","defaultBreakpoints","handleBreakpoints","styleFromPropValue","theme","themeBreakpoints","breakpoint","mediaKey","cssKey","createEmptyBreakpointObject","breakpointsInput","_breakpointsInput$key","breakpointStyleKey","removeUnusedBreakpoints","breakpointKeys","breakpointOutput","getPath","path","checkVars","getStyleValue","themeMapping","transform","propValueFinal","userValue","cssProperty","themeKey","memoize","cache","arg","properties","directions","aliases","getCssProperties","property","marginKeys","paddingKeys","spacingKeys","createUnaryUnit","_getPath","themeSpacing","abs","createUnarySpacing","getValue","transformer","transformed","getStyleFromPropValue","cssProperties","resolveCssProperty","margin","padding","createSpacing","spacingInput","spacing","argsInput","argument","compose","styles","handlers","borderTransform","createBorderStyle","border","borderTop","borderRight","borderBottom","borderLeft","borderColor","borderTopColor","borderRightColor","borderBottomColor","borderLeftColor","outline","outlineColor","borderRadius","gap","columnGap","rowGap","gridColumn","gridRow","gridAutoFlow","gridAutoColumns","gridAutoRows","gridTemplateColumns","gridTemplateRows","gridTemplateAreas","gridArea","paletteTransform","color","bgcolor","backgroundColor","sizingTransform","maxWidth","_props$theme","_props$theme2","breakpointsValues","minWidth","height","maxHeight","minHeight","boxSizing","defaultSxConfig","defaultSxConfig$1","objectsHaveSameKeys","objects","union","callIfFn","maybeFn","unstable_createStyleFunctionSx","getThemeValue","config","styleFunctionSx","_theme$unstable_sxCon","sx","traverse","sxInput","sxObject","emptyBreakpoints","breakpointsKeys","css","styleKey","styleFunctionSx$1","applyStyles","createTheme","paletteInput","shapeInput","muiTheme","isObjectEmpty","useTheme","defaultTheme","contextTheme","ThemeContext","systemDefaultTheme","useThemeWithoutDefault","_excluded2","_excluded3","isEmpty","isStringTag","tag","shouldForwardProp","lowercaseFirstLetter","resolveTheme","themeId","defaultOverridesResolver","processStyleArg","callableStyle","_ref","ownerState","resolvedStylesArg","resolvedStyle","variants","isMatch","createStyled","input","rootShouldForwardProp","slotShouldForwardProp","systemSx","inputOptions","processStyles","componentSlot","inputSkipVariantsResolver","inputSkipSx","overridesResolver","skipVariantsResolver","skipSx","shouldForwardPropOption","defaultStyledResolver","styledEngineStyled","transformStyleArg","stylesArg","muiStyledResolver","styleArg","expressions","transformedStyleArg","expressionsWithDefaultTheme","styleOverrides","resolvedStyleOverrides","slotKey","slotStyle","_theme$components","themeVariants","numOfCustomFnsApplied","placeholders","displayName","getThemeProps","params","useThemeProps","clampWrapper","hexToRgb","re","colors","decomposeColor","marker","colorSpace","recomposeColor","hslToRgb","rgb","getLuminance","getContrastRatio","foreground","background","lumA","lumB","alpha","darken","coefficient","lighten","createMixins","mixins","common","common$1","grey","grey$1","purple","purple$1","red","red$1","orange","orange$1","blue","blue$1","lightBlue","lightBlue$1","green","green$1","light","dark","addLightOrDark","intent","shade","tonalOffset","tonalOffsetLight","tonalOffsetDark","getDefaultPrimary","mode","getDefaultSecondary","getDefaultError","getDefaultInfo","getDefaultSuccess","getDefaultWarning","createPalette","palette","contrastThreshold","success","warning","getContrastText","contrastText","contrast","augmentColor","mainShade","lightShade","darkShade","modes","round","caseAllCaps","defaultFontFamily","createTypography","typography","fontFamily","fontSize","fontWeightLight","fontWeightRegular","fontWeightMedium","fontWeightBold","htmlFontSize","allVariants","pxToRem2","coef","pxToRem","buildVariant","fontWeight","lineHeight","letterSpacing","casing","shadowKeyUmbraOpacity","shadowKeyPenumbraOpacity","shadowAmbientShadowOpacity","createShadow","px","shadows","shadows$1","easing","duration","formatMs","milliseconds","getAutoHeightDuration","constant","createTransitions","inputTransitions","mergedEasing","mergedDuration","durationOption","easingOption","isString","isNumber","animatedProp","zIndex","zIndex$1","mixinsInput","transitionsInput","typographyInput","systemTheme","systemCreateTheme","stateClasses","component","child","stateClass","defaultTheme$1","THEME_ID","systemUseThemeProps","styled","styled$1","getSvgIconUtilityClass","useUtilityClasses","SvgIconRoot","_theme$transitions","_theme$transitions$cr","_theme$transitions2","_theme$typography","_theme$typography$pxT","_theme$typography2","_theme$typography2$px","_theme$typography3","_theme$typography3$px","_palette$ownerState$c","_palette","_palette2","_palette3","SvgIcon","inProps","htmlColor","inheritViewBox","titleAccess","viewBox","hasSvgAsChild","more","_jsxs","_jsx","SvgIcon$1","createSvgIcon","unstable_ClassNameGenerator","exports","_utils","ArrowRight","default_1","_createSvgIcon","_jsxRuntime","isHostComponent","appendOwnerState","otherProps","defaultContextValue","ClassNameConfiguratorContext","useClassNamesOverride","disableDefaultClasses","extractEventHandlers","excludeKeys","resolveComponentProps","componentProps","slotState","omitEventHandlers","mergeSlotProps","parameters","getSlotProps","additionalProps","externalSlotProps","externalForwardedProps","joinedClasses","mergedStyle","eventHandlers","componentsPropsWithoutEventHandlers","otherPropsWithoutEventHandlers","internalSlotProps","useSlotProps","_parameters$additiona","skipResolvingSlotProps","rest","resolvedComponentsProps","mergedProps","internalRef","GLOBAL_CLASS_PREFIX","buildStateClass","buildSlotClass","getContainer","container","forwardedRef","disablePortal","mountNode","setMountNode","handleRef","newProps","ReactDOM","top","bottom","right","left","auto","basePlacements","clippingParents","viewport","popper","reference","variationPlacements","placement","placements","beforeRead","read","afterRead","beforeMain","main","afterMain","beforeWrite","write","afterWrite","modifierPhases","getNodeName","getWindow","OwnElement","isHTMLElement","isShadowRoot","attributes","effect","_ref2","initialStyles","styleProperties","attribute","applyStyles$1","getBasePlacement","getUAString","uaData","isLayoutViewport","getBoundingClientRect","includeScale","isFixedStrategy","clientRect","scaleX","scaleY","visualViewport","addVisualOffsets","getLayoutRect","contains","parent","rootNode","next","getComputedStyle","isTableElement","getDocumentElement","getParentNode","getTrueOffsetParent","getContainingBlock","isFirefox","isIE","elementCss","currentNode","getOffsetParent","window","offsetParent","getMainAxisFromPlacement","within","mathMax","mathMin","withinMaxClamp","getFreshSideObject","mergePaddingObject","paddingObject","expandToHashMap","hashMap","toPaddingObject","arrow","_state$modifiersData$","arrowElement","popperOffsets","basePlacement","axis","isVertical","len","arrowRect","minProp","maxProp","endDiff","startDiff","arrowOffsetParent","clientSize","centerToReference","center","offset","axisProp","_options$element","arrow$1","getVariation","unsetSides","roundOffsetsByDPR","win","dpr","mapToStyles","_Object$assign2","popperRect","variation","offsets","gpuAcceleration","adaptive","roundOffsets","isFixed","_offsets$x","_offsets$y","_ref3","hasX","hasY","sideX","sideY","heightProp","widthProp","offsetY","offsetX","commonStyles","_ref4","_Object$assign","computeStyles","_ref5","_options$gpuAccelerat","_options$adaptive","_options$roundOffsets","computeStyles$1","passive","_options$scroll","scroll","_options$resize","resize","scrollParents","scrollParent","eventListeners","hash","getOppositePlacement","matched","getOppositeVariationPlacement","getWindowScroll","scrollLeft","scrollTop","getWindowScrollBarX","getViewportRect","strategy","html","layoutViewport","getDocumentRect","_element$ownerDocumen","winScroll","body","isScrollParent","_getComputedStyle","overflow","overflowX","overflowY","getScrollParent","listScrollParents","list","isBody","updatedList","rectToClientRect","rect","getInnerBoundingClientRect","getClientRectFromMixedType","clippingParent","getClippingParents","canEscapeClipping","clipperElement","getClippingRect","boundary","rootBoundary","mainClippingParents","firstClippingParent","clippingRect","accRect","computeOffsets","commonX","commonY","mainAxis","detectOverflow","_options","_options$placement","_options$strategy","_options$boundary","_options$rootBoundary","_options$elementConte","elementContext","_options$altBoundary","altBoundary","_options$padding","altContext","clippingClientRect","referenceClientRect","popperClientRect","elementClientRect","overflowOffsets","offsetData","multiply","computeAutoPlacement","flipVariations","_options$allowedAutoP","allowedAutoPlacements","allPlacements","allowedPlacements","overflows","getExpandedFallbackPlacements","oppositePlacement","flip","_options$mainAxis","checkMainAxis","_options$altAxis","checkAltAxis","specifiedFallbackPlacements","_options$flipVariatio","preferredPlacement","isBasePlacement","fallbackPlacements","referenceRect","checksMap","makeFallbackChecks","firstFittingPlacement","_basePlacement","isStartVariation","mainVariationSide","altVariationSide","checks","check","numberOfChecks","_loop","_i","fittingPlacement","_ret","flip$1","getSideOffsets","preventedOffsets","isAnySideFullyClipped","hide","referenceOverflow","popperAltOverflow","referenceClippingOffsets","popperEscapeOffsets","isReferenceHidden","hasPopperEscaped","hide$1","distanceAndSkiddingToXY","rects","invertDistance","skidding","distance","_options$offset","_data$state$placement","offset$1","popperOffsets$1","getAltAxis","preventOverflow","_options$tether","tether","_options$tetherOffset","tetherOffset","altAxis","tetherOffsetValue","normalizedTetherOffsetValue","offsetModifierState","_offsetModifierState$","mainSide","altSide","additive","minLen","maxLen","arrowPaddingObject","arrowPaddingMin","arrowPaddingMax","arrowLen","minOffset","maxOffset","clientOffset","offsetModifierValue","tetherMin","tetherMax","preventedOffset","_offsetModifierState$2","_mainSide","_altSide","_offset","_len","_min","_max","isOriginSide","_offsetModifierValue","_tetherMin","_tetherMax","_preventedOffset","preventOverflow$1","getHTMLElementScroll","getNodeScroll","isElementScaled","getCompositeRect","elementOrVirtualElement","isOffsetParentAnElement","offsetParentIsScaled","documentElement","order","modifiers","map","visited","modifier","sort","requires","dep","depModifier","orderModifiers","orderedModifiers","phase","pending","resolve","mergeByName","merged","current","existing","DEFAULT_OPTIONS","areValidElements","_key","popperGenerator","generatorOptions","_generatorOptions","_generatorOptions$def","defaultModifiers","_generatorOptions$def2","defaultOptions","effectCleanupFns","isDestroyed","setOptionsAction","cleanupModifierEffects","runModifierEffects","_state$elements","_state$orderedModifie","_state$orderedModifie2","_ref$options","cleanupFn","noopFn","createPopper","COMPONENT_NAME","getPopperUtilityClass","flipPlacement","resolveAnchorEl","anchorEl","isVirtualElement","defaultPopperOptions","PopperTooltip","_slots$root","initialPlacement","popperOptions","popperRefProp","TransitionProps","tooltipRef","ownRef","popperRef","handlePopperRef","handlePopperRefRef","rtlPlacement","setPlacement","resolvedAnchorElement","setResolvedAnchorElement","handlePopperUpdate","box","popperModifiers","childProps","Root","rootProps","Popper","containerProp","keepMounted","transition","exited","setExited","handleEnter","handleExited","resolvedAnchorEl","display","transitionProps","useThemeSystem","_setPrototypeOf","_inheritsLoose","subClass","superClass","setPrototypeOf","timeoutsShape","TransitionGroupContext","forceReflow","UNMOUNTED","EXITED","ENTERING","ENTERED","EXITING","Transition","_React$Component","_this","parentGroup","appear","initialStatus","prevState","nextIn","_proto","prevProps","nextStatus","exit","enter","mounting","_this2","appearing","maybeNode","maybeAppearing","timeouts","enterTimeout","_this3","nextState","callback","_this4","active","handler","doesNotHaveTimeoutOrListener","maybeNextCallback","_this$props","pt","noop","Transition$1","reflow","getTransitionProps","_style$transitionDura","_style$transitionTimi","getScale","isWebKit154","Grow","addEndListener","inProp","onEnter","onEntered","onEntering","onExit","onExited","onExiting","TransitionComponent","timer","autoTimeout","nodeRef","normalizedTransitionCallback","maybeIsAppearing","handleEntering","isAppearing","transitionDuration","transitionTimingFunction","handleEntered","handleExiting","handleExit","handleAddEndListener","Grow$1","PopperRoot","BasePopper","components","componentsProps","RootComponent","Popper$1","getTooltipUtilityClass","tooltipClasses","tooltipClasses$1","disableInteractive","touch","TooltipPopper","TooltipTooltip","TooltipArrow","hystersisOpen","hystersisTimer","cursorPosition","composeEventHandler","eventHandler","_slots$popper","_slots$transition","_slots$tooltip","_slots$arrow","_slotProps$popper","_ref6","_slotProps$popper2","_slotProps$transition","_slotProps$tooltip","_ref7","_slotProps$tooltip2","_slotProps$arrow","_ref8","_slotProps$arrow2","childrenProp","describeChild","disableFocusListener","disableHoverListener","disableInteractiveProp","disableTouchListener","enterDelay","enterNextDelay","enterTouchDelay","followCursor","idProp","leaveDelay","leaveTouchDelay","onClose","onOpen","PopperComponentProp","PopperProps","title","TransitionComponentProp","isRtl","childNode","setChildNode","arrowRef","setArrowRef","ignoreNonTouchEvents","closeTimer","enterTimer","leaveTimer","touchTimer","setOpenState","prevUserSelect","stopTouchInteraction","handleOpen","handleClose","handleLeave","focusVisibleRef","setChildIsFocusVisible","handleBlur","handleFocus","detectTouchStart","childrenProps","handleMouseOver","handleMouseLeave","handleTouchStart","handleTouchEnd","nativeEvent","handleMouseMove","nameOrDescProps","titleIsString","interactiveWrapperListeners","_PopperProps$popperOp","tooltipModifiers","PopperComponent","TooltipComponent","ArrowComponent","popperProps","tooltipProps","tooltipArrowProps","TransitionPropsInner","Tooltip$1","getIcon","icon","menuLabel","leading","MuiListItemIcon","MenuItem","allowForLeadingIcons","iconPathBefore","iconPathAfter","hasAutoFocus","isDense","isSubMenuParent","hasDisabledGutters","hasDivider","focusVisibleClassName","menuItem","MuiMenuItem","MuiListItemText","getAllGroups","menuDefinition","SubMenu","setAnchorEl","parentMenuItem","parentItemProps","handleParentMenuItemClick","renderSubMenuItems","includedGroups","group","GroupedMenuItemList","Menu","getOrderedGroupItems","groupId","allItems","menuProps","commandHandler","groupsToInclude","sortedGroups","itemArray","allowSpaceForLeadingIcons","createMenuItemProps","isLastItemInGroup","divKey","itemInfo","menuItemProps","TopLevelMenu","columnId","MenuColumn","metadata","Grid","List","GridMenu","multiColumnMenu","sortedColumns","columnNumbers","columnName","col","getUsePromiseOptionsDefaults","usePromise","promiseFactoryCallback","defaultValueRef","optionsDefaultedRef","setIsLoading","promiseIsCurrent","MenuIcon","HamburgerMenuButton","menuProvider","normalMenu","fullMenu","containerRef","ariaLabelPrefix","isMenuOpen","setMenuOpen","showFullMenu","setShowFullMenu","handleMenuItemClick","handleMenuButtonClick","prevIsOpen","isOpening","menuCommandHandler","command","setOffset","normalMenuData","fullMenuData","menu","IconButton","Drawer","isTooltipSuppressed","adjustMarginToAlignToEdge","MuiIconButton","Spinner","LoaderCircle","TextField","hasError","helperText","onFocus","onBlur","ShadLabel","Toolbar","AppBar","MuiToolbar","alertVariants","Alert","AlertTitle","AlertDescription","Card","CardHeader","CardTitle","CardDescription","CardContent","CardFooter","Sonner","Toaster","Slider","SliderPrimitive","Switch","SwitchPrimitives","Tabs","TabsList","TabsTrigger","TabsContent","InstallButton","isInstalling","handleClick","buttonText","Download","EnableButton","isEnabling","DisableButton","isDisabling","UpdateButton","isUpdating","MarkdownRenderer","markdown","anchorTarget","Markdown","FilterButton","Filter","DropdownMenuItemType","DropdownMenuItemType2","FilterDropdown","groups","NoExtensionsFound","MoreInfo","category","downloads","languages","moreInfoUrl","numberFormatted","NumberFormat","handleScrollToBottom","User","locale","LucideLink","CircleHelp","VersionHistory","versionHistory","showAllVersions","setShowAllVersions","currentDate","formatTimeString","dateString","date","dateDiff","yearDiff","monthDiff","dayDiff","timeString","sortedEntries","Footer","publisherDisplayName","fileSize","locales","formattedFileSize","formatBytes","languageNames","codes","displayNames","useEvent","unsubscriber","noopUnsubscriber","useEventAsync","unsubscribe","unsub"],"mappings":"28CAGA,MAAMA,GAAgBC,GAAAA,oBAAoB,CAAE,OAAQ,KAAO,CAAA,EAyDpD,SAASC,KAAMC,EAAsB,CACnC,OAAAH,GAAcI,GAAAA,KAAKD,CAAM,CAAC,CACnC,CCzDO,MAAME,GAAQC,EAAM,WACzB,CAAC,CAAE,UAAAC,EAAW,KAAAC,EAAM,GAAGC,CAAA,EAASC,IAE5BC,EAAA,IAAC,QAAA,CACC,KAAAH,EACA,UAAWN,EACT,sbACAK,CACF,EACA,IAAAG,EAEC,GAAGD,CAAA,CAAA,CAIZ,EACAJ,GAAM,YAAc,QCNpB,MAAMO,GAAmBC,EAAA,WACvB,CACE,CAAE,aAAAC,EAAc,cAAAC,EAAe,cAAAC,EAAe,aAAAC,EAAc,GAAGR,CAAM,EACrEC,IAGEQ,EAAA,KAAC,MAAI,CAAA,UAAU,cACb,SAAA,CAAAP,EAAA,IAACQ,GAAA,CACE,GAAGV,EACJ,KAAK,OACL,UAAU,0JACV,SAAWW,GAAUN,EAAaM,EAAM,OAAO,KAAK,EACpD,UAAYC,GAAM,CACZA,EAAE,MAAQ,SACCJ,IAEfF,EAAcM,CAAC,CACjB,EACA,QAASL,EACT,IAAAN,CAAA,CACF,EACAC,EAAA,IAACW,EAAA,QAAA,CACC,UAAU,8HACV,QAAS,IAAM,CAEb,QAAQ,IAAI,iBAAiB,CAC/B,CAAA,CACF,CACF,CAAA,CAAA,CAGN,EC9CA,IAAIC,GAAI,OAAO,eACXC,GAAI,CAACC,EAAGJ,EAAGK,IAAML,KAAKI,EAAIF,GAAEE,EAAGJ,EAAG,CAAE,WAAY,GAAI,aAAc,GAAI,SAAU,GAAI,MAAOK,CAAC,CAAE,EAAID,EAAEJ,CAAC,EAAIK,EACzGC,GAAI,CAACF,EAAGJ,EAAGK,IAAMF,GAAEC,EAAG,OAAOJ,GAAK,SAAWA,EAAI,GAAKA,EAAGK,CAAC,EAW9D,MAAME,GAAI,CACR,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MAEA,MAEA,MAEA,MAEA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,MAEA,MAEA,MAEA,MAEA,MACA,MACA,MACA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,KACF,EAAGC,GAAI,CACL,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,KACF,EAAGC,GAAI,CACL,UACA,SACA,YACA,UACA,cACA,SACA,SACA,OACA,WACA,WACA,UACA,UACA,eACA,eACA,OACA,WACA,kBACA,MACA,SACA,WACA,eACA,gBACA,SACA,WACA,eACA,UACA,kBACA,QACA,OACA,OACA,UACA,QACA,QACA,QACA,WACA,YACA,SACA,YACA,UACA,UACA,OACA,OACA,OACA,OACA,SACA,gBACA,gBACA,YACA,YACA,cACA,aACA,kBACA,kBACA,YACA,YACA,QACA,WACA,UACA,QACA,UACA,UACA,SACA,SACA,SACA,OACA,aACA,QACA,SACA,eACA,oBACA,0BACA,SACA,qBACA,sBACA,UACA,qBACA,cACA,cACA,cACA,cACA,mBACA,mBACA,qBACA,YACA,OACA,oBAGA,uBACA,uBACA,sBACA,yB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WC,EAAS,EC1DzF,MAAMC,GAAkB,CAEtB,OAAQ,CACN,SAAU,UACV,UAAWzC,EACZ,EACD,UAAW,CACT,SAAU,UACV,UAAWA,EACZ,EACD,YAAa,CACX,SAAU,UACV,UAAWA,EACZ,EACD,aAAc,CACZ,SAAU,UACV,UAAWA,EACZ,EACD,WAAY,CACV,SAAU,UACV,UAAWA,EACZ,EACD,YAAa,CACX,SAAU,SACX,EACD,eAAgB,CACd,SAAU,SACX,EACD,iBAAkB,CAChB,SAAU,SACX,EACD,kBAAmB,CACjB,SAAU,SACX,EACD,gBAAiB,CACf,SAAU,SACX,EACD,QAAS,CACP,SAAU,UACV,UAAWA,EACZ,EACD,aAAc,CACZ,SAAU,SACX,EACD,aAAc,CACZ,SAAU,qBACV,MAAOc,EACR,EAED,MAAO,CACL,SAAU,UACV,UAAWa,EACZ,EACD,QAAS,CACP,SAAU,UACV,YAAa,kBACb,UAAWA,EACZ,EACD,gBAAiB,CACf,SAAU,UACV,UAAWA,EACZ,EAED,EAAG,CACD,MAAOpC,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,QAAS,CACP,MAAOA,EACR,EACD,WAAY,CACV,MAAOA,EACR,EACD,aAAc,CACZ,MAAOA,EACR,EACD,cAAe,CACb,MAAOA,EACR,EACD,YAAa,CACX,MAAOA,EACR,EACD,SAAU,CACR,MAAOA,EACR,EACD,SAAU,CACR,MAAOA,EACR,EACD,cAAe,CACb,MAAOA,EACR,EACD,mBAAoB,CAClB,MAAOA,EACR,EACD,iBAAkB,CAChB,MAAOA,EACR,EACD,aAAc,CACZ,MAAOA,EACR,EACD,kBAAmB,CACjB,MAAOA,EACR,EACD,gBAAiB,CACf,MAAOA,EACR,EACD,EAAG,CACD,MAAOD,EACR,EACD,GAAI,C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;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","x_google_ignoreList":[3,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,83,84,85,86,87,88,89,90,91,92,93,94,95,96,97,98,99,100,101,102,103,104,105,106,107,108,109,110,111,112,113,114,115,116,117,118,119,120,121,122,123,124,125,126,127,128,129,130,131,132,133,134,135,136,137,138,139,140,141,142,143,144,145,146,147,148,149,150,151,152,153,154,155,156,157,158,159,160,161,162,163,164,165,166,167,168,169,170,171,172,173,174,175,176,177,178,179,180,181,182,183,184,185,186,187,188,189,190,191,192,193,194,195,196,197,198,199,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,228]} \ No newline at end of file +{"version":3,"file":"index.cjs","sources":["../src/utils/shadcn-ui.util.ts","../src/components/shadcn-ui/input.tsx","../src/components/advanced/book-chapter-control/book-chapter-input.component.tsx","../../../node_modules/@sillsdev/scripture/dist/index.es.js","../src/components/shadcn-ui/dropdown-menu.tsx","../src/components/advanced/book-chapter-control/book-menu-item.component.tsx","../src/components/advanced/book-chapter-control/chapter-select.component.tsx","../src/components/advanced/book-chapter-control/go-to-menu-item.component.tsx","../src/components/advanced/book-chapter-control/book-chapter-control.component.tsx","../src/components/shadcn-ui/button.tsx","../src/components/shadcn-ui/label.tsx","../src/components/shadcn-ui/radio-group.tsx","../src/components/shadcn-ui/popover.tsx","../src/components/shadcn-ui/dialog.tsx","../src/components/shadcn-ui/command.tsx","../src/components/basics/combo-box.component.tsx","../src/components/basics/chapter-range-selector.component.tsx","../src/components/advanced/book-selector.component.tsx","../src/components/advanced/data-table/data-table-column-toggle.component.tsx","../src/components/shadcn-ui/select.tsx","../src/components/advanced/data-table/data-table-pagination.component.tsx","../src/components/shadcn-ui/table.tsx","../src/components/advanced/data-table/data-table.component.tsx","../src/components/advanced/inventory/occurrences-table.component.tsx","../src/components/shadcn-ui/checkbox.tsx","../src/components/advanced/inventory/inventory-utils.ts","../src/components/shadcn-ui/toggle.tsx","../src/components/shadcn-ui/toggle-group.tsx","../src/components/advanced/inventory/inventory-columns.tsx","../src/components/advanced/inventory/inventory.component.tsx","../src/components/basics/search-bar.component.tsx","../src/components/basics/tabs-vertical.tsx","../src/components/advanced/tab-navigation-content-search.component.tsx","../src/components/shadcn-ui/separator.tsx","../src/components/shadcn-ui/sheet.tsx","../src/components/shadcn-ui/skeleton.tsx","../src/components/shadcn-ui/tooltip.tsx","../src/components/hooks/use-mobile.tsx","../src/components/shadcn-ui/sidebar.tsx","../src/components/advanced/settings-components/settings-sidebar.component.tsx","../src/components/advanced/settings-components/settings-sidebar-content-search.component.tsx","../src/components/advanced/scripture-results-viewer/scripture-results-viewer.component.tsx","../src/components/advanced/scroll-group-selector.component.tsx","../src/components/advanced/settings-components/settings-list.component.tsx","../src/components/basics/checklist.component.tsx","../../../node_modules/@babel/runtime/helpers/interopRequireDefault.js","../../../node_modules/@mui/utils/chainPropTypes/chainPropTypes.js","../../../node_modules/@babel/runtime/helpers/esm/extends.js","../../../node_modules/@mui/utils/deepmerge/deepmerge.js","../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.production.min.js","../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.development.js","../../../node_modules/prop-types/node_modules/react-is/index.js","../../../node_modules/object-assign/index.js","../../../node_modules/prop-types/lib/ReactPropTypesSecret.js","../../../node_modules/prop-types/lib/has.js","../../../node_modules/prop-types/checkPropTypes.js","../../../node_modules/prop-types/factoryWithTypeCheckers.js","../../../node_modules/prop-types/factoryWithThrowingShims.js","../../../node_modules/prop-types/index.js","../../../node_modules/@mui/utils/elementAcceptingRef/elementAcceptingRef.js","../../../node_modules/@mui/utils/exactProp/exactProp.js","../../../node_modules/@mui/utils/formatMuiErrorMessage/formatMuiErrorMessage.js","../../../node_modules/react-is/cjs/react-is.production.min.js","../../../node_modules/react-is/cjs/react-is.development.js","../../../node_modules/react-is/index.js","../../../node_modules/@mui/utils/getDisplayName/getDisplayName.js","../../../node_modules/@mui/utils/HTMLElementType/HTMLElementType.js","../../../node_modules/@mui/utils/refType/refType.js","../../../node_modules/@mui/utils/capitalize/capitalize.js","../../../node_modules/@mui/utils/createChainedFunction/createChainedFunction.js","../../../node_modules/@mui/utils/debounce/debounce.js","../../../node_modules/@mui/utils/deprecatedPropType/deprecatedPropType.js","../../../node_modules/@mui/utils/isMuiElement/isMuiElement.js","../../../node_modules/@mui/utils/ownerDocument/ownerDocument.js","../../../node_modules/@mui/utils/ownerWindow/ownerWindow.js","../../../node_modules/@mui/utils/requirePropFactory/requirePropFactory.js","../../../node_modules/@mui/utils/setRef/setRef.js","../../../node_modules/@mui/utils/useEnhancedEffect/useEnhancedEffect.js","../../../node_modules/@mui/utils/useId/useId.js","../../../node_modules/@mui/utils/unsupportedProp/unsupportedProp.js","../../../node_modules/@mui/utils/useControlled/useControlled.js","../../../node_modules/@mui/utils/useEventCallback/useEventCallback.js","../../../node_modules/@mui/utils/useForkRef/useForkRef.js","../../../node_modules/@mui/utils/useLazyRef/useLazyRef.js","../../../node_modules/@mui/utils/useOnMount/useOnMount.js","../../../node_modules/@mui/utils/useTimeout/useTimeout.js","../../../node_modules/@mui/utils/useIsFocusVisible/useIsFocusVisible.js","../../../node_modules/@mui/utils/resolveProps/resolveProps.js","../../../node_modules/@mui/utils/composeClasses/composeClasses.js","../../../node_modules/@mui/utils/ClassNameGenerator/ClassNameGenerator.js","../../../node_modules/@mui/utils/generateUtilityClass/generateUtilityClass.js","../../../node_modules/@mui/utils/generateUtilityClasses/generateUtilityClasses.js","../../../node_modules/@mui/utils/clamp/clamp.js","../../../node_modules/@babel/runtime/helpers/esm/objectWithoutPropertiesLoose.js","../../../node_modules/@mui/system/esm/createTheme/createBreakpoints.js","../../../node_modules/@mui/system/esm/createTheme/shape.js","../../../node_modules/@mui/system/esm/responsivePropType.js","../../../node_modules/@mui/system/esm/merge.js","../../../node_modules/@mui/system/esm/breakpoints.js","../../../node_modules/@mui/system/esm/style.js","../../../node_modules/@mui/system/esm/memoize.js","../../../node_modules/@mui/system/esm/spacing.js","../../../node_modules/@mui/system/esm/createTheme/createSpacing.js","../../../node_modules/@mui/system/esm/compose.js","../../../node_modules/@mui/system/esm/borders.js","../../../node_modules/@mui/system/esm/cssGrid.js","../../../node_modules/@mui/system/esm/palette.js","../../../node_modules/@mui/system/esm/sizing.js","../../../node_modules/@mui/system/esm/styleFunctionSx/defaultSxConfig.js","../../../node_modules/@mui/system/esm/styleFunctionSx/styleFunctionSx.js","../../../node_modules/@mui/system/esm/createTheme/applyStyles.js","../../../node_modules/@mui/system/esm/createTheme/createTheme.js","../../../node_modules/@mui/system/esm/useThemeWithoutDefault.js","../../../node_modules/@mui/system/esm/useTheme.js","../../../node_modules/@mui/system/esm/createStyled.js","../../../node_modules/@mui/system/esm/useThemeProps/getThemeProps.js","../../../node_modules/@mui/system/esm/useThemeProps/useThemeProps.js","../../../node_modules/@mui/system/esm/colorManipulator.js","../../../node_modules/@mui/material/styles/createMixins.js","../../../node_modules/@mui/material/colors/common.js","../../../node_modules/@mui/material/colors/grey.js","../../../node_modules/@mui/material/colors/purple.js","../../../node_modules/@mui/material/colors/red.js","../../../node_modules/@mui/material/colors/orange.js","../../../node_modules/@mui/material/colors/blue.js","../../../node_modules/@mui/material/colors/lightBlue.js","../../../node_modules/@mui/material/colors/green.js","../../../node_modules/@mui/material/styles/createPalette.js","../../../node_modules/@mui/material/styles/createTypography.js","../../../node_modules/@mui/material/styles/shadows.js","../../../node_modules/@mui/material/styles/createTransitions.js","../../../node_modules/@mui/material/styles/zIndex.js","../../../node_modules/@mui/material/styles/createTheme.js","../../../node_modules/@mui/material/styles/defaultTheme.js","../../../node_modules/@mui/material/styles/identifier.js","../../../node_modules/@mui/material/styles/useThemeProps.js","../../../node_modules/@mui/material/styles/styled.js","../../../node_modules/@mui/material/SvgIcon/svgIconClasses.js","../../../node_modules/@mui/material/SvgIcon/SvgIcon.js","../../../node_modules/@mui/material/utils/createSvgIcon.js","../../../node_modules/@mui/material/utils/index.js","../../../node_modules/@mui/icons-material/utils/createSvgIcon.js","../../../node_modules/@mui/icons-material/ArrowRight.js","../../../node_modules/@mui/base/utils/isHostComponent.js","../../../node_modules/@mui/base/utils/appendOwnerState.js","../../../node_modules/@mui/base/utils/ClassNameConfigurator.js","../../../node_modules/@mui/base/utils/extractEventHandlers.js","../../../node_modules/@mui/base/utils/resolveComponentProps.js","../../../node_modules/@mui/base/utils/omitEventHandlers.js","../../../node_modules/@mui/base/utils/mergeSlotProps.js","../../../node_modules/@mui/base/utils/useSlotProps.js","../../../node_modules/@mui/base/generateUtilityClass/index.js","../../../node_modules/@mui/base/generateUtilityClasses/index.js","../../../node_modules/@mui/base/Portal/Portal.js","../../../node_modules/@popperjs/core/lib/enums.js","../../../node_modules/@popperjs/core/lib/dom-utils/getNodeName.js","../../../node_modules/@popperjs/core/lib/dom-utils/getWindow.js","../../../node_modules/@popperjs/core/lib/dom-utils/instanceOf.js","../../../node_modules/@popperjs/core/lib/modifiers/applyStyles.js","../../../node_modules/@popperjs/core/lib/utils/getBasePlacement.js","../../../node_modules/@popperjs/core/lib/utils/math.js","../../../node_modules/@popperjs/core/lib/utils/userAgent.js","../../../node_modules/@popperjs/core/lib/dom-utils/isLayoutViewport.js","../../../node_modules/@popperjs/core/lib/dom-utils/getBoundingClientRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/getLayoutRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/contains.js","../../../node_modules/@popperjs/core/lib/dom-utils/getComputedStyle.js","../../../node_modules/@popperjs/core/lib/dom-utils/isTableElement.js","../../../node_modules/@popperjs/core/lib/dom-utils/getDocumentElement.js","../../../node_modules/@popperjs/core/lib/dom-utils/getParentNode.js","../../../node_modules/@popperjs/core/lib/dom-utils/getOffsetParent.js","../../../node_modules/@popperjs/core/lib/utils/getMainAxisFromPlacement.js","../../../node_modules/@popperjs/core/lib/utils/within.js","../../../node_modules/@popperjs/core/lib/utils/getFreshSideObject.js","../../../node_modules/@popperjs/core/lib/utils/mergePaddingObject.js","../../../node_modules/@popperjs/core/lib/utils/expandToHashMap.js","../../../node_modules/@popperjs/core/lib/modifiers/arrow.js","../../../node_modules/@popperjs/core/lib/utils/getVariation.js","../../../node_modules/@popperjs/core/lib/modifiers/computeStyles.js","../../../node_modules/@popperjs/core/lib/modifiers/eventListeners.js","../../../node_modules/@popperjs/core/lib/utils/getOppositePlacement.js","../../../node_modules/@popperjs/core/lib/utils/getOppositeVariationPlacement.js","../../../node_modules/@popperjs/core/lib/dom-utils/getWindowScroll.js","../../../node_modules/@popperjs/core/lib/dom-utils/getWindowScrollBarX.js","../../../node_modules/@popperjs/core/lib/dom-utils/getViewportRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/getDocumentRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/isScrollParent.js","../../../node_modules/@popperjs/core/lib/dom-utils/getScrollParent.js","../../../node_modules/@popperjs/core/lib/dom-utils/listScrollParents.js","../../../node_modules/@popperjs/core/lib/utils/rectToClientRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/getClippingRect.js","../../../node_modules/@popperjs/core/lib/utils/computeOffsets.js","../../../node_modules/@popperjs/core/lib/utils/detectOverflow.js","../../../node_modules/@popperjs/core/lib/utils/computeAutoPlacement.js","../../../node_modules/@popperjs/core/lib/modifiers/flip.js","../../../node_modules/@popperjs/core/lib/modifiers/hide.js","../../../node_modules/@popperjs/core/lib/modifiers/offset.js","../../../node_modules/@popperjs/core/lib/modifiers/popperOffsets.js","../../../node_modules/@popperjs/core/lib/utils/getAltAxis.js","../../../node_modules/@popperjs/core/lib/modifiers/preventOverflow.js","../../../node_modules/@popperjs/core/lib/dom-utils/getHTMLElementScroll.js","../../../node_modules/@popperjs/core/lib/dom-utils/getNodeScroll.js","../../../node_modules/@popperjs/core/lib/dom-utils/getCompositeRect.js","../../../node_modules/@popperjs/core/lib/utils/orderModifiers.js","../../../node_modules/@popperjs/core/lib/utils/debounce.js","../../../node_modules/@popperjs/core/lib/utils/mergeByName.js","../../../node_modules/@popperjs/core/lib/createPopper.js","../../../node_modules/@popperjs/core/lib/popper.js","../../../node_modules/@mui/base/Popper/popperClasses.js","../../../node_modules/@mui/base/Popper/Popper.js","../../../node_modules/@mui/material/styles/useTheme.js","../../../node_modules/@babel/runtime/helpers/esm/setPrototypeOf.js","../../../node_modules/@babel/runtime/helpers/esm/inheritsLoose.js","../../../node_modules/react-transition-group/esm/config.js","../../../node_modules/react-transition-group/esm/utils/PropTypes.js","../../../node_modules/react-transition-group/esm/TransitionGroupContext.js","../../../node_modules/react-transition-group/esm/utils/reflow.js","../../../node_modules/react-transition-group/esm/Transition.js","../../../node_modules/@mui/material/transitions/utils.js","../../../node_modules/@mui/material/Grow/Grow.js","../../../node_modules/@mui/material/Popper/Popper.js","../../../node_modules/@mui/material/Tooltip/tooltipClasses.js","../../../node_modules/@mui/material/Tooltip/Tooltip.js","../src/components/mui/menu-item.component.tsx","../src/components/mui/grouped-menu-item-list.component.tsx","../src/components/mui/top-level-menu.component.tsx","../src/components/mui/grid-menu.component.tsx","../src/hooks/use-promise.hook.ts","../../../node_modules/@mui/icons-material/esm/Menu.js","../src/components/mui/hamburger-menu-button.component.tsx","../src/components/mui/icon-button.component.tsx","../src/components/basics/spinner.component.tsx","../src/components/basics/text-field.component.tsx","../src/components/mui/toolbar.component.tsx","../src/components/shadcn-ui/alert.tsx","../src/components/shadcn-ui/card.tsx","../src/components/shadcn-ui/sonner.tsx","../src/components/shadcn-ui/slider.tsx","../src/components/shadcn-ui/switch.tsx","../src/components/shadcn-ui/tabs.tsx","../src/components/advanced/extension-marketplace/buttons/install-button.component.tsx","../src/components/advanced/extension-marketplace/buttons/enable-button.component.tsx","../src/components/advanced/extension-marketplace/buttons/disable-button.component.tsx","../src/components/advanced/extension-marketplace/buttons/update-button.component.tsx","../src/components/advanced/extension-marketplace/markdown-renderer.component.tsx","../src/components/advanced/extension-marketplace/buttons/filter-button.component.tsx","../src/components/advanced/extension-marketplace/filter-dropdown.component.tsx","../src/components/advanced/extension-marketplace/no-extensions-found.component.tsx","../src/components/advanced/extension-marketplace/more-info.component.tsx","../src/components/advanced/extension-marketplace/version-history.component.tsx","../src/components/advanced/extension-marketplace/footer.component.tsx","../src/hooks/use-event.hook.ts","../src/hooks/use-event-async.hook.ts"],"sourcesContent":["import { type ClassValue, clsx } from 'clsx';\nimport { extendTailwindMerge } from 'tailwind-merge';\n\nconst twMergeCustom = extendTailwindMerge({ prefix: 'tw-' });\n\n/**\n * Tailwind and CSS class application helper function. Uses\n * [`clsx`](https://www.npmjs.com/package/clsx) to make it easy to apply classes conditionally using\n * object syntax, and uses [`tailwind-merge`](https://www.npmjs.com/package/tailwind-merge) to make\n * it easy to merge/overwrite Tailwind classes in a programmer-logic-friendly way.\n *\n * Note: `tailwind-merge` is configured to use the prefix `tw-`, so you must use the same prefix\n * with any Tailwind classes you use with this function to successfully overwrite other Tailwind\n * classes. `platform-bible-react` is configured to use `tw-` as its Tailwind prefix, so any\n * Tailwind classes you pass into `platform-bible-react` components will be compared using the `tw-`\n * prefix.\n *\n * This function was popularized by\n * [shadcn/ui](https://ui.shadcn.com/docs/installation/manual#add-a-cn-helper). See [ByteGrad's\n * explanation video](https://www.youtube.com/watch?v=re2JFITR7TI) for more information.\n *\n * @example\n *\n * ```typescript\n * const borderShouldBeBlue = true;\n * const textShouldBeRed = true;\n * const heightShouldBe20 = false;\n * const classString = cn(\n * 'tw-bg-primary tw-h-10 tw-text-primary-foreground',\n * 'tw-bg-secondary',\n * {\n * 'tw-border-blue-500': borderShouldBeBlue,\n * 'tw-text-red-500': textShouldBeRed,\n * 'tw-h-20': heightShouldBe20,\n * },\n * 'some-class',\n * );\n * ```\n *\n * The resulting `classString` is `'tw-h-10 tw-bg-secondary tw-border-blue-500 tw-text-red-500\n * some-class'`\n *\n * - Notice that `'tw-bg-secondary'`, specified later, overwrote `'tw-bg-primary'`, specified earlier,\n * because they are Tailwind classes that affect the same css property\n * - Notice that `'tw-text-red-500'`, specified later, overwrote `'tw-text-primary-foreground'`,\n * specified earlier, because they are Tailwind classes that affect the same css property\n * - Notice that `'tw-h-20'`, specified later, did not overwrite `'tw-h-10'`, specified earlier,\n * because `'tw-h-20'` is part of a conditional class object and its value evaluated to `false`;\n * therefore it was not applied\n * - Notice that `'some-class'` was applied. This function is not limited only to Tailwind classes.\n *\n *\n * @param inputs Class strings or `clsx` conditional class objects to merge. Tailwind classes\n * specified later in the arguments overwrite similar Tailwind classes specified earlier in the\n * arguments\n * @returns Class string containing all applicable classes from the arguments based on the rules\n * described above\n */\n// shadcn/ui uses this export in its boilerplate code\n// eslint-disable-next-line import/prefer-default-export\nexport function cn(...inputs: ClassValue[]) {\n return twMergeCustom(clsx(inputs));\n}\n","import React from 'react';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport interface InputProps extends React.InputHTMLAttributes {}\n\nexport const Input = React.forwardRef(\n ({ className, type, ...props }, ref) => {\n return (\n \n );\n },\n);\nInput.displayName = 'Input';\n","import { FocusEventHandler, forwardRef, KeyboardEvent, MouseEventHandler } from 'react';\nimport { History } from 'lucide-react';\nimport { Input as ShadInput } from '@/components/shadcn-ui/input';\n\nexport type BookChapterInputProps = {\n handleSearch: (searchString: string) => void;\n handleKeyDown: (event: KeyboardEvent) => void;\n handleOnClick: MouseEventHandler;\n handleSubmit: () => void;\n onFocus?: FocusEventHandler;\n value: string;\n placeholder: string;\n};\n\n// Shadcn Input sets type to \"button\"- HAVE to prop spread before setting type\nconst BookChapterInput = forwardRef(\n (\n { handleSearch, handleKeyDown, handleOnClick, handleSubmit, ...props }: BookChapterInputProps,\n ref,\n ) => {\n return (\n
    \n handleSearch(event.target.value)}\n onKeyDown={(e) => {\n if (e.key === 'Enter') {\n handleSubmit();\n }\n handleKeyDown(e);\n }}\n onClick={handleOnClick}\n ref={ref}\n />\n {\n // eslint-disable-next-line no-console\n console.log('back in history');\n }}\n />\n
    \n );\n },\n);\n\nexport default BookChapterInput;\n","var P = Object.defineProperty;\nvar R = (t, e, s) => e in t ? P(t, e, { enumerable: !0, configurable: !0, writable: !0, value: s }) : t[e] = s;\nvar n = (t, e, s) => R(t, typeof e != \"symbol\" ? e + \"\" : e, s);\nclass _ {\n constructor() {\n n(this, \"books\");\n n(this, \"firstSelectedBookNum\");\n n(this, \"lastSelectedBookNum\");\n n(this, \"count\");\n n(this, \"selectedBookNumbers\");\n n(this, \"selectedBookIds\");\n }\n}\nconst N = [\n \"GEN\",\n \"EXO\",\n \"LEV\",\n \"NUM\",\n \"DEU\",\n \"JOS\",\n \"JDG\",\n \"RUT\",\n \"1SA\",\n \"2SA\",\n // 10\n \"1KI\",\n \"2KI\",\n \"1CH\",\n \"2CH\",\n \"EZR\",\n \"NEH\",\n \"EST\",\n \"JOB\",\n \"PSA\",\n \"PRO\",\n // 20\n \"ECC\",\n \"SNG\",\n \"ISA\",\n \"JER\",\n \"LAM\",\n \"EZK\",\n \"DAN\",\n \"HOS\",\n \"JOL\",\n \"AMO\",\n // 30\n \"OBA\",\n \"JON\",\n \"MIC\",\n \"NAM\",\n \"HAB\",\n \"ZEP\",\n \"HAG\",\n \"ZEC\",\n \"MAL\",\n \"MAT\",\n // 40\n \"MRK\",\n \"LUK\",\n \"JHN\",\n \"ACT\",\n \"ROM\",\n \"1CO\",\n \"2CO\",\n \"GAL\",\n \"EPH\",\n \"PHP\",\n // 50\n \"COL\",\n \"1TH\",\n \"2TH\",\n \"1TI\",\n \"2TI\",\n \"TIT\",\n \"PHM\",\n \"HEB\",\n \"JAS\",\n \"1PE\",\n // 60\n \"2PE\",\n \"1JN\",\n \"2JN\",\n \"3JN\",\n \"JUD\",\n \"REV\",\n \"TOB\",\n \"JDT\",\n \"ESG\",\n \"WIS\",\n // 70\n \"SIR\",\n \"BAR\",\n \"LJE\",\n \"S3Y\",\n \"SUS\",\n \"BEL\",\n \"1MA\",\n \"2MA\",\n \"3MA\",\n \"4MA\",\n // 80\n \"1ES\",\n \"2ES\",\n \"MAN\",\n \"PS2\",\n \"ODA\",\n \"PSS\",\n \"JSA\",\n // actual variant text for JOS, now in LXA text\n \"JDB\",\n // actual variant text for JDG, now in LXA text\n \"TBS\",\n // actual variant text for TOB, now in LXA text\n \"SST\",\n // actual variant text for SUS, now in LXA text // 90\n \"DNT\",\n // actual variant text for DAN, now in LXA text\n \"BLT\",\n // actual variant text for BEL, now in LXA text\n \"XXA\",\n \"XXB\",\n \"XXC\",\n \"XXD\",\n \"XXE\",\n \"XXF\",\n \"XXG\",\n \"FRT\",\n // 100\n \"BAK\",\n \"OTH\",\n \"3ES\",\n // Used previously but really should be 2ES\n \"EZA\",\n // Used to be called 4ES, but not actually in any known project\n \"5EZ\",\n // Used to be called 5ES, but not actually in any known project\n \"6EZ\",\n // Used to be called 6ES, but not actually in any known project\n \"INT\",\n \"CNC\",\n \"GLO\",\n \"TDX\",\n // 110\n \"NDX\",\n \"DAG\",\n \"PS3\",\n \"2BA\",\n \"LBA\",\n \"JUB\",\n \"ENO\",\n \"1MQ\",\n \"2MQ\",\n \"3MQ\",\n // 120\n \"REP\",\n \"4BA\",\n \"LAO\"\n], B = [\n \"XXA\",\n \"XXB\",\n \"XXC\",\n \"XXD\",\n \"XXE\",\n \"XXF\",\n \"XXG\",\n \"FRT\",\n \"BAK\",\n \"OTH\",\n \"INT\",\n \"CNC\",\n \"GLO\",\n \"TDX\",\n \"NDX\"\n], O = [\n \"Genesis\",\n \"Exodus\",\n \"Leviticus\",\n \"Numbers\",\n \"Deuteronomy\",\n \"Joshua\",\n \"Judges\",\n \"Ruth\",\n \"1 Samuel\",\n \"2 Samuel\",\n \"1 Kings\",\n \"2 Kings\",\n \"1 Chronicles\",\n \"2 Chronicles\",\n \"Ezra\",\n \"Nehemiah\",\n \"Esther (Hebrew)\",\n \"Job\",\n \"Psalms\",\n \"Proverbs\",\n \"Ecclesiastes\",\n \"Song of Songs\",\n \"Isaiah\",\n \"Jeremiah\",\n \"Lamentations\",\n \"Ezekiel\",\n \"Daniel (Hebrew)\",\n \"Hosea\",\n \"Joel\",\n \"Amos\",\n \"Obadiah\",\n \"Jonah\",\n \"Micah\",\n \"Nahum\",\n \"Habakkuk\",\n \"Zephaniah\",\n \"Haggai\",\n \"Zechariah\",\n \"Malachi\",\n \"Matthew\",\n \"Mark\",\n \"Luke\",\n \"John\",\n \"Acts\",\n \"Romans\",\n \"1 Corinthians\",\n \"2 Corinthians\",\n \"Galatians\",\n \"Ephesians\",\n \"Philippians\",\n \"Colossians\",\n \"1 Thessalonians\",\n \"2 Thessalonians\",\n \"1 Timothy\",\n \"2 Timothy\",\n \"Titus\",\n \"Philemon\",\n \"Hebrews\",\n \"James\",\n \"1 Peter\",\n \"2 Peter\",\n \"1 John\",\n \"2 John\",\n \"3 John\",\n \"Jude\",\n \"Revelation\",\n \"Tobit\",\n \"Judith\",\n \"Esther Greek\",\n \"Wisdom of Solomon\",\n \"Sirach (Ecclesiasticus)\",\n \"Baruch\",\n \"Letter of Jeremiah\",\n \"Song of 3 Young Men\",\n \"Susanna\",\n \"Bel and the Dragon\",\n \"1 Maccabees\",\n \"2 Maccabees\",\n \"3 Maccabees\",\n \"4 Maccabees\",\n \"1 Esdras (Greek)\",\n \"2 Esdras (Latin)\",\n \"Prayer of Manasseh\",\n \"Psalm 151\",\n \"Odes\",\n \"Psalms of Solomon\",\n // WARNING, if you change the spelling of the *obsolete* tag be sure to update\n // IsObsolete routine\n \"Joshua A. *obsolete*\",\n \"Judges B. *obsolete*\",\n \"Tobit S. *obsolete*\",\n \"Susanna Th. *obsolete*\",\n \"Daniel Th. *obsolete*\",\n \"Bel Th. *obsolete*\",\n \"Extra A\",\n \"Extra B\",\n \"Extra C\",\n \"Extra D\",\n \"Extra E\",\n \"Extra F\",\n \"Extra G\",\n \"Front Matter\",\n \"Back Matter\",\n \"Other Matter\",\n \"3 Ezra *obsolete*\",\n \"Apocalypse of Ezra\",\n \"5 Ezra (Latin Prologue)\",\n \"6 Ezra (Latin Epilogue)\",\n \"Introduction\",\n \"Concordance \",\n \"Glossary \",\n \"Topical Index\",\n \"Names Index\",\n \"Daniel Greek\",\n \"Psalms 152-155\",\n \"2 Baruch (Apocalypse)\",\n \"Letter of Baruch\",\n \"Jubilees\",\n \"Enoch\",\n \"1 Meqabyan\",\n \"2 Meqabyan\",\n \"3 Meqabyan\",\n \"Reproof (Proverbs 25-31)\",\n \"4 Baruch (Rest of Baruch)\",\n \"Laodiceans\"\n], S = K();\nfunction g(t, e = !0) {\n return e && (t = t.toUpperCase()), t in S ? S[t] : 0;\n}\nfunction k(t) {\n return g(t) > 0;\n}\nfunction x(t) {\n const e = typeof t == \"string\" ? g(t) : t;\n return e >= 40 && e <= 66;\n}\nfunction T(t) {\n return (typeof t == \"string\" ? g(t) : t) <= 39;\n}\nfunction X(t) {\n return t <= 66;\n}\nfunction V(t) {\n const e = typeof t == \"string\" ? g(t) : t;\n return w(e) && !X(e);\n}\nfunction* L() {\n for (let t = 1; t <= N.length; t++) yield t;\n}\nconst G = 1, A = N.length;\nfunction H() {\n return [\"XXA\", \"XXB\", \"XXC\", \"XXD\", \"XXE\", \"XXF\", \"XXG\"];\n}\nfunction C(t, e = \"***\") {\n const s = t - 1;\n return s < 0 || s >= N.length ? e : N[s];\n}\nfunction I(t) {\n return t <= 0 || t > A ? \"******\" : O[t - 1];\n}\nfunction y(t) {\n return I(g(t));\n}\nfunction w(t) {\n const e = typeof t == \"number\" ? C(t) : t;\n return k(e) && !B.includes(e);\n}\nfunction q(t) {\n const e = typeof t == \"number\" ? C(t) : t;\n return k(e) && B.includes(e);\n}\nfunction U(t) {\n return O[t - 1].includes(\"*obsolete*\");\n}\nfunction K() {\n const t = {};\n for (let e = 0; e < N.length; e++)\n t[N[e]] = e + 1;\n return t;\n}\nconst m = {\n allBookIds: N,\n nonCanonicalIds: B,\n bookIdToNumber: g,\n isBookIdValid: k,\n isBookNT: x,\n isBookOT: T,\n isBookOTNT: X,\n isBookDC: V,\n allBookNumbers: L,\n firstBook: G,\n lastBook: A,\n extraBooks: H,\n bookNumberToId: C,\n bookNumberToEnglishName: I,\n bookIdToEnglishName: y,\n isCanonical: w,\n isExtraMaterial: q,\n isObsolete: U\n};\nvar l = /* @__PURE__ */ ((t) => (t[t.Unknown = 0] = \"Unknown\", t[t.Original = 1] = \"Original\", t[t.Septuagint = 2] = \"Septuagint\", t[t.Vulgate = 3] = \"Vulgate\", t[t.English = 4] = \"English\", t[t.RussianProtestant = 5] = \"RussianProtestant\", t[t.RussianOrthodox = 6] = \"RussianOrthodox\", t))(l || {});\nconst h = class h {\n // private versInfo: Versification;\n constructor(e) {\n n(this, \"name\");\n n(this, \"fullPath\");\n n(this, \"isPresent\");\n n(this, \"hasVerseSegments\");\n n(this, \"isCustomized\");\n n(this, \"baseVersification\");\n n(this, \"scriptureBooks\");\n n(this, \"_type\");\n if (e == null)\n throw new Error(\"Argument undefined\");\n typeof e == \"string\" ? (this.name = e, this._type = l[e]) : (this._type = e, this.name = l[e]);\n }\n get type() {\n return this._type;\n }\n equals(e) {\n return !e.type || !this.type ? !1 : e.type === this.type;\n }\n};\nn(h, \"Original\", new h(l.Original)), n(h, \"Septuagint\", new h(l.Septuagint)), n(h, \"Vulgate\", new h(l.Vulgate)), n(h, \"English\", new h(l.English)), n(h, \"RussianProtestant\", new h(l.RussianProtestant)), n(h, \"RussianOrthodox\", new h(l.RussianOrthodox));\nlet c = h;\nfunction E(t, e) {\n const s = e[0];\n for (let r = 1; r < e.length; r++)\n t = t.split(e[r]).join(s);\n return t.split(s);\n}\nvar D = /* @__PURE__ */ ((t) => (t[t.Valid = 0] = \"Valid\", t[t.UnknownVersification = 1] = \"UnknownVersification\", t[t.OutOfRange = 2] = \"OutOfRange\", t[t.VerseOutOfOrder = 3] = \"VerseOutOfOrder\", t[t.VerseRepeated = 4] = \"VerseRepeated\", t))(D || {});\nconst i = class i {\n constructor(e, s, r, a) {\n /** Not yet implemented. */\n n(this, \"firstChapter\");\n /** Not yet implemented. */\n n(this, \"lastChapter\");\n /** Not yet implemented. */\n n(this, \"lastVerse\");\n /** Not yet implemented. */\n n(this, \"hasSegmentsDefined\");\n /** Not yet implemented. */\n n(this, \"text\");\n /** Not yet implemented. */\n n(this, \"BBBCCCVVVS\");\n /** Not yet implemented. */\n n(this, \"longHashCode\");\n /** The versification of the reference. */\n n(this, \"versification\");\n n(this, \"rtlMark\", \"‏\");\n n(this, \"_bookNum\", 0);\n n(this, \"_chapterNum\", 0);\n n(this, \"_verseNum\", 0);\n n(this, \"_verse\");\n if (r == null && a == null)\n if (e != null && typeof e == \"string\") {\n const o = e, u = s != null && s instanceof c ? s : void 0;\n this.setEmpty(u), this.parse(o);\n } else if (e != null && typeof e == \"number\") {\n const o = s != null && s instanceof c ? s : void 0;\n this.setEmpty(o), this._verseNum = e % i.chapterDigitShifter, this._chapterNum = Math.floor(\n e % i.bookDigitShifter / i.chapterDigitShifter\n ), this._bookNum = Math.floor(e / i.bookDigitShifter);\n } else if (s == null)\n if (e != null && e instanceof i) {\n const o = e;\n this._bookNum = o.bookNum, this._chapterNum = o.chapterNum, this._verseNum = o.verseNum, this._verse = o.verse, this.versification = o.versification;\n } else {\n if (e == null) return;\n const o = e instanceof c ? e : i.defaultVersification;\n this.setEmpty(o);\n }\n else\n throw new Error(\"VerseRef constructor not supported.\");\n else if (e != null && s != null && r != null)\n if (typeof e == \"string\" && typeof s == \"string\" && typeof r == \"string\")\n this.setEmpty(a), this.updateInternal(e, s, r);\n else if (typeof e == \"number\" && typeof s == \"number\" && typeof r == \"number\")\n this._bookNum = e, this._chapterNum = s, this._verseNum = r, this.versification = a ?? i.defaultVersification;\n else\n throw new Error(\"VerseRef constructor not supported.\");\n else\n throw new Error(\"VerseRef constructor not supported.\");\n }\n /**\n * Determines if the verse string is in a valid format (does not consider versification).\n */\n static isVerseParseable(e) {\n return e.length > 0 && \"0123456789\".includes(e[0]) && !e.endsWith(this.verseRangeSeparator) && !e.endsWith(this.verseSequenceIndicator);\n }\n /**\n * Tries to parse the specified string into a verse reference.\n * @param str - The string to attempt to parse.\n * @returns success: `true` if the specified string was successfully parsed, `false` otherwise.\n * @returns verseRef: The result of the parse if successful, or empty VerseRef if it failed\n */\n static tryParse(e) {\n let s;\n try {\n return s = new i(e), { success: !0, verseRef: s };\n } catch (r) {\n if (r instanceof v)\n return s = new i(), { success: !1, verseRef: s };\n throw r;\n }\n }\n /**\n * Gets the reference as a comparable integer where the book, chapter, and verse each occupy 3\n * digits.\n * @param bookNum - Book number (this is 1-based, not an index).\n * @param chapterNum - Chapter number.\n * @param verseNum - Verse number.\n * @returns The reference as a comparable integer where the book, chapter, and verse each occupy 3\n * digits.\n */\n static getBBBCCCVVV(e, s, r) {\n return e % i.bcvMaxValue * i.bookDigitShifter + (s >= 0 ? s % i.bcvMaxValue * i.chapterDigitShifter : 0) + (r >= 0 ? r % i.bcvMaxValue : 0);\n }\n /**\n * Deserializes a serialized VerseRef.\n * @param serializedVerseRef - Serialized VerseRef to create from.\n * @returns the deserialized VerseRef.\n */\n static fromJSON(e) {\n const { book: s, chapterNum: r, verseNum: a, verse: o, versificationStr: u } = e, f = o || a.toString();\n let d;\n return u && (d = new c(u)), s ? new i(s, r.toString(), f, d) : new i();\n }\n /**\n * Parses a verse string and gets the leading numeric portion as a number.\n * @param verseStr - verse string to parse\n * @returns true if the entire string could be parsed as a single, simple verse number (1-999);\n * false if the verse string represented a verse bridge, contained segment letters, or was invalid\n */\n static tryGetVerseNum(e) {\n let s;\n if (!e)\n return s = -1, { success: !0, vNum: s };\n s = 0;\n let r;\n for (let a = 0; a < e.length; a++) {\n if (r = e[a], r < \"0\" || r > \"9\")\n return a === 0 && (s = -1), { success: !1, vNum: s };\n if (s = s * 10 + +r - 0, s > i.bcvMaxValue)\n return s = -1, { success: !1, vNum: s };\n }\n return { success: !0, vNum: s };\n }\n /**\n * Checks to see if a VerseRef hasn't been set - all values are the default.\n */\n get isDefault() {\n return this.bookNum === 0 && this.chapterNum === 0 && this.verseNum === 0 && this.versification == null;\n }\n /**\n * Gets whether the verse contains multiple verses.\n */\n get hasMultiple() {\n return this._verse != null && (this._verse.includes(i.verseRangeSeparator) || this._verse.includes(i.verseSequenceIndicator));\n }\n /**\n * Gets or sets the book of the reference. Book is the 3-letter abbreviation in capital letters,\n * e.g. `'MAT'`.\n */\n get book() {\n return m.bookNumberToId(this.bookNum, \"\");\n }\n set book(e) {\n this.bookNum = m.bookIdToNumber(e);\n }\n /**\n * Gets or sets the chapter of the reference,. e.g. `'3'`.\n */\n get chapter() {\n return this.isDefault || this._chapterNum < 0 ? \"\" : this._chapterNum.toString();\n }\n set chapter(e) {\n const s = +e;\n this._chapterNum = Number.isInteger(s) ? s : -1;\n }\n /**\n * Gets or sets the verse of the reference, including range, segments, and sequences, e.g. `'4'`,\n * or `'4b-5a, 7'`.\n */\n get verse() {\n return this._verse != null ? this._verse : this.isDefault || this._verseNum < 0 ? \"\" : this._verseNum.toString();\n }\n set verse(e) {\n const { success: s, vNum: r } = i.tryGetVerseNum(e);\n this._verse = s ? void 0 : e.replace(this.rtlMark, \"\"), this._verseNum = r, !(this._verseNum >= 0) && ({ vNum: this._verseNum } = i.tryGetVerseNum(this._verse));\n }\n /**\n * Get or set Book based on book number, e.g. `42`.\n */\n get bookNum() {\n return this._bookNum;\n }\n set bookNum(e) {\n if (e <= 0 || e > m.lastBook)\n throw new v(\n \"BookNum must be greater than zero and less than or equal to last book\"\n );\n this._bookNum = e;\n }\n /**\n * Gets or sets the chapter number, e.g. `3`. `-1` if not valid.\n */\n get chapterNum() {\n return this._chapterNum;\n }\n set chapterNum(e) {\n this.chapterNum = e;\n }\n /**\n * Gets or sets verse start number, e.g. `4`. `-1` if not valid.\n */\n get verseNum() {\n return this._verseNum;\n }\n set verseNum(e) {\n this._verseNum = e;\n }\n /**\n * String representing the versification (should ONLY be used for serialization/deserialization).\n *\n * @remarks This is for backwards compatibility when ScrVers was an enumeration.\n */\n get versificationStr() {\n var e;\n return (e = this.versification) == null ? void 0 : e.name;\n }\n set versificationStr(e) {\n this.versification = this.versification != null ? new c(e) : void 0;\n }\n /**\n * Determines if the reference is valid.\n */\n get valid() {\n return this.validStatus === 0;\n }\n /**\n * Get the valid status for this reference.\n */\n get validStatus() {\n return this.validateVerse(i.verseRangeSeparators, i.verseSequenceIndicators);\n }\n /**\n * Gets the reference as a comparable integer where the book,\n * chapter, and verse each occupy three digits and the verse is 0.\n */\n get BBBCCC() {\n return i.getBBBCCCVVV(this._bookNum, this._chapterNum, 0);\n }\n /**\n * Gets the reference as a comparable integer where the book,\n * chapter, and verse each occupy three digits. If verse is not null\n * (i.e., this reference represents a complex reference with verse\n * segments or bridge) this cannot be used for an exact comparison.\n */\n get BBBCCCVVV() {\n return i.getBBBCCCVVV(this._bookNum, this._chapterNum, this._verseNum);\n }\n /**\n * Gets whether the verse is defined as an excluded verse in the versification.\n * Does not handle verse ranges.\n */\n // eslint-disable-next-line @typescript-eslint/class-literal-property-style\n get isExcluded() {\n return !1;\n }\n /**\n * Parses the reference in the specified string.\n * Optionally versification can follow reference as in GEN 3:11/4\n * Throw an exception if\n * - invalid book name\n * - chapter number is missing or not a number\n * - verse number is missing or does not start with a number\n * - versification is invalid\n * @param verseStr - string to parse e.g. 'MAT 3:11'\n */\n parse(e) {\n if (e = e.replace(this.rtlMark, \"\"), e.includes(\"/\")) {\n const o = e.split(\"/\");\n if (e = o[0], o.length > 1)\n try {\n const u = +o[1].trim();\n this.versification = new c(l[u]);\n } catch {\n throw new v(\"Invalid reference : \" + e);\n }\n }\n const s = e.trim().split(\" \");\n if (s.length !== 2)\n throw new v(\"Invalid reference : \" + e);\n const r = s[1].split(\":\"), a = +r[0];\n if (r.length !== 2 || m.bookIdToNumber(s[0]) === 0 || !Number.isInteger(a) || a < 0 || !i.isVerseParseable(r[1]))\n throw new v(\"Invalid reference : \" + e);\n this.updateInternal(s[0], r[0], r[1]);\n }\n /**\n * Simplifies this verse ref so that it has no bridging of verses or\n * verse segments like `'1a'`.\n */\n simplify() {\n this._verse = void 0;\n }\n /**\n * Makes a clone of the reference.\n *\n * @returns The cloned VerseRef.\n */\n clone() {\n return new i(this);\n }\n toString() {\n const e = this.book;\n return e === \"\" ? \"\" : `${e} ${this.chapter}:${this.verse}`;\n }\n toJSON() {\n let e = this.verse;\n (e === \"\" || e === this.verseNum.toString()) && (e = void 0);\n const s = {\n book: this.book,\n chapterNum: this.chapterNum,\n verseNum: this.verseNum,\n verse: e,\n versificationStr: this.versificationStr\n };\n return e || delete s.verse, s;\n }\n /**\n * Compares this `VerseRef` with supplied one.\n * @param verseRef - object to compare this one to.\n * @returns `true` if this `VerseRef` is equal to the supplied one, `false` otherwise.\n */\n equals(e) {\n return e instanceof i ? e._bookNum === this._bookNum && e._chapterNum === this._chapterNum && e._verseNum === this._verseNum && e.verse === this.verse && (e.versification == null && this.versification == null || e.versification != null && this.versification != null && e.versification.equals(this.versification)) : !1;\n }\n /**\n * Enumerate all individual verses contained in a VerseRef.\n * Verse ranges are indicated by \"-\" and consecutive verses by \",\"s.\n * Examples:\n * GEN 1:2 returns GEN 1:2\n * GEN 1:1a-3b,5 returns GEN 1:1a, GEN 1:2, GEN 1:3b, GEN 1:5\n * GEN 1:2a-2c returns //! ??????\n *\n * @param specifiedVersesOnly - if set to true return only verses that are\n * explicitly specified only, not verses within a range. Defaults to `false`.\n * @param verseRangeSeparators - Verse range separators.\n * Defaults to `VerseRef.verseRangeSeparators`.\n * @param verseSequenceSeparators - Verse sequence separators.\n * Defaults to `VerseRef.verseSequenceIndicators`.\n * @returns An array of all single verse references in this VerseRef.\n */\n allVerses(e = !1, s = i.verseRangeSeparators, r = i.verseSequenceIndicators) {\n if (this._verse == null || this.chapterNum <= 0)\n return [this.clone()];\n const a = [], o = E(this._verse, r);\n for (const u of o.map((f) => E(f, s))) {\n const f = this.clone();\n f.verse = u[0];\n const d = f.verseNum;\n if (a.push(f), u.length > 1) {\n const b = this.clone();\n if (b.verse = u[1], !e)\n for (let p = d + 1; p < b.verseNum; p++) {\n const J = new i(\n this._bookNum,\n this._chapterNum,\n p,\n this.versification\n );\n this.isExcluded || a.push(J);\n }\n a.push(b);\n }\n }\n return a;\n }\n /**\n * Validates a verse number using the supplied separators rather than the defaults.\n */\n validateVerse(e, s) {\n if (!this.verse)\n return this.internalValid;\n let r = 0;\n for (const a of this.allVerses(!0, e, s)) {\n const o = a.internalValid;\n if (o !== 0)\n return o;\n const u = a.BBBCCCVVV;\n if (r > u)\n return 3;\n if (r === u)\n return 4;\n r = u;\n }\n return 0;\n }\n /**\n * Gets whether a single verse reference is valid.\n */\n get internalValid() {\n return this.versification == null ? 1 : this._bookNum <= 0 || this._bookNum > m.lastBook ? 2 : (m.isCanonical(this._bookNum), 0);\n }\n setEmpty(e = i.defaultVersification) {\n this._bookNum = 0, this._chapterNum = -1, this._verse = void 0, this.versification = e;\n }\n updateInternal(e, s, r) {\n this.bookNum = m.bookIdToNumber(e), this.chapter = s, this.verse = r;\n }\n};\nn(i, \"defaultVersification\", c.English), n(i, \"verseRangeSeparator\", \"-\"), n(i, \"verseSequenceIndicator\", \",\"), n(i, \"verseRangeSeparators\", [i.verseRangeSeparator]), n(i, \"verseSequenceIndicators\", [i.verseSequenceIndicator]), n(i, \"chapterDigitShifter\", 1e3), n(i, \"bookDigitShifter\", i.chapterDigitShifter * i.chapterDigitShifter), n(i, \"bcvMaxValue\", i.chapterDigitShifter - 1), /**\n * The valid status of the VerseRef.\n */\nn(i, \"ValidStatusType\", D);\nlet M = i;\nclass v extends Error {\n}\nexport {\n _ as BookSet,\n m as Canon,\n c as ScrVers,\n l as ScrVersType,\n M as VerseRef,\n v as VerseRefException\n};\n//# sourceMappingURL=index.es.js.map\n","import React from 'react';\nimport * as DropdownMenuPrimitive from '@radix-ui/react-dropdown-menu';\nimport { Check, ChevronRight, Circle } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport const DropdownMenu = DropdownMenuPrimitive.Root;\n\nexport const DropdownMenuTrigger = DropdownMenuPrimitive.Trigger;\n\nexport const DropdownMenuGroup = DropdownMenuPrimitive.Group;\n\nexport const DropdownMenuPortal = DropdownMenuPrimitive.Portal;\n\nexport const DropdownMenuSub = DropdownMenuPrimitive.Sub;\n\nexport const DropdownMenuRadioGroup = DropdownMenuPrimitive.RadioGroup;\n\nexport type DropdownMenuSubTriggerProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.SubTrigger\n> & {\n className?: string;\n inset?: boolean;\n};\n\nexport type DropdownMenuSubContentProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.SubContent\n> & {\n className?: string;\n};\n\nexport type DropdownMenuContentProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Content\n> & {\n className?: string;\n sideOffset?: number;\n};\n\nexport type DropdownMenuItemProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Item\n> & {\n className?: string;\n inset?: boolean;\n};\n\nexport type DropdownMenuCheckboxItemProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.CheckboxItem\n> & {\n className?: string;\n checked?: boolean;\n};\n\nexport type DropdownMenuRadioItemProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.RadioItem\n> & {\n className?: string;\n};\n\nexport type DropdownMenuLabelProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Label\n> & {\n className?: string;\n inset?: boolean;\n};\n\nexport type DropdownMenuSeparatorProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Separator\n> & {\n className?: string;\n};\n\nexport type DropdownMenuShortcutProps = React.HTMLAttributes & {\n className?: string;\n};\n\nexport const DropdownMenuSubTrigger = React.forwardRef<\n React.ElementRef,\n DropdownMenuSubTriggerProps\n>(({ className, inset, children, ...props }, ref) => (\n \n {children}\n \n \n));\nDropdownMenuSubTrigger.displayName = DropdownMenuPrimitive.SubTrigger.displayName;\n\nexport const DropdownMenuSubContent = React.forwardRef<\n React.ElementRef,\n DropdownMenuSubContentProps\n>(({ className, ...props }, ref) => (\n \n));\nDropdownMenuSubContent.displayName = DropdownMenuPrimitive.SubContent.displayName;\n\nexport const DropdownMenuContent = React.forwardRef<\n React.ElementRef,\n DropdownMenuContentProps\n>(({ className, sideOffset = 4, ...props }, ref) => (\n \n \n \n));\nDropdownMenuContent.displayName = DropdownMenuPrimitive.Content.displayName;\n\n/**\n * TODO: fix: direction is not automatically handled by this component, so that shortcuts are\n * display always to the right\n */\nexport const DropdownMenuItem = React.forwardRef<\n React.ElementRef,\n DropdownMenuItemProps\n>(({ className, inset, ...props }, ref) => (\n \n));\nDropdownMenuItem.displayName = DropdownMenuPrimitive.Item.displayName;\n\nexport const DropdownMenuCheckboxItem = React.forwardRef<\n React.ElementRef,\n DropdownMenuCheckboxItemProps\n>(({ className, children, checked, ...props }, ref) => (\n \n \n \n \n \n \n {children}\n \n));\nDropdownMenuCheckboxItem.displayName = DropdownMenuPrimitive.CheckboxItem.displayName;\n\nexport const DropdownMenuRadioItem = React.forwardRef<\n React.ElementRef,\n DropdownMenuRadioItemProps\n>(({ className, children, ...props }, ref) => (\n \n \n \n \n \n \n {children}\n \n));\nDropdownMenuRadioItem.displayName = DropdownMenuPrimitive.RadioItem.displayName;\n\nexport const DropdownMenuLabel = React.forwardRef<\n React.ElementRef,\n DropdownMenuLabelProps\n>(({ className, inset, ...props }, ref) => (\n \n));\nDropdownMenuLabel.displayName = DropdownMenuPrimitive.Label.displayName;\n\nexport const DropdownMenuSeparator = React.forwardRef<\n React.ElementRef,\n DropdownMenuSeparatorProps\n>(({ className, ...props }, ref) => (\n \n));\nDropdownMenuSeparator.displayName = DropdownMenuPrimitive.Separator.displayName;\n\nexport function DropdownMenuShortcut({ className, ...props }: DropdownMenuShortcutProps) {\n return (\n \n );\n}\nDropdownMenuShortcut.displayName = 'DropdownMenuShortcut';\n","import { Canon } from '@sillsdev/scripture';\nimport { PropsWithChildren, KeyboardEvent, forwardRef } from 'react';\nimport { DropdownMenuItem as ShadDropdownMenuItem } from '@/components/shadcn-ui/dropdown-menu';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport type BookType = 'OT' | 'NT' | 'DC';\n\ntype BookMenuItemProps = PropsWithChildren<{\n /** String id of book */\n bookId: string;\n /** Callback to run when a book menu item is selected */\n handleSelectBook: () => void;\n /** Indicates if this menu item is currently selected */\n isSelected: boolean;\n /** Function that is called upon highlighting a book in the dropdown menu */\n handleHighlightBook: () => void;\n /**\n * Function that is called on pressing a key\n *\n * @param event Event that contains information about the key stroke\n */\n handleKeyDown: (event: KeyboardEvent) => void;\n /**\n * Type of book associated with this menu item, coordinates color labels ? Mock up has the labels\n * coordinated to genre\n */\n bookType: BookType;\n}>;\n\nconst BookMenuItem = forwardRef(\n (\n {\n bookId,\n handleSelectBook,\n isSelected,\n handleHighlightBook,\n handleKeyDown,\n bookType,\n children,\n }: BookMenuItemProps,\n ref,\n ) => {\n return (\n {\n // preventDefault() here prevents the entire dropdown menu from closing when selecting this item\n event.preventDefault();\n handleSelectBook();\n }}\n onKeyDown={(event: KeyboardEvent) => {\n handleKeyDown(event);\n }}\n onFocus={handleHighlightBook}\n onMouseMove={handleHighlightBook}\n >\n \n {Canon.bookIdToEnglishName(bookId)}\n \n {isSelected &&
    {children}
    }\n \n );\n },\n);\n\nexport default BookMenuItem;\n","import { cn } from '@/utils/shadcn-ui.util';\nimport { useCallback } from 'react';\n\nexport type ChapterSelectProps = {\n /**\n * Callback to run when a chapter div is selected\n *\n * @param chapterNumber Number of the chapter that has been selected\n */\n handleSelectChapter: (chapterNumber: number) => void;\n /** The highest chapter number in the book (of course equal to number of chapters in the book) */\n endChapter: number;\n /** The chapter number that is currently selected */\n activeChapter: number;\n /** The chapter number that is currently highlighted using keyboard or mouse navigation */\n highlightedChapter: number;\n /**\n * Callback to run when a chapter is highlighted by the user\n *\n * @param chapterNumber The chapter that is highlighted\n */\n handleHighlightedChapter: (chapterNumber: number) => void;\n};\n\nfunction ChapterSelect({\n handleSelectChapter,\n endChapter,\n activeChapter,\n highlightedChapter,\n handleHighlightedChapter,\n}: ChapterSelectProps) {\n const chapters = Array.from({ length: endChapter }, (_, i) => i + 1);\n\n const handleMouse = useCallback(\n (chapterNumber: number) => {\n handleHighlightedChapter(chapterNumber);\n },\n [handleHighlightedChapter],\n );\n\n return (\n
    \n {chapters.map((chapter) => (\n {\n event.preventDefault();\n event.stopPropagation();\n handleSelectChapter(chapter);\n }}\n role=\"button\"\n onKeyDown={(event) => {\n if (event.key === 'Enter') {\n handleSelectChapter(chapter);\n }\n }}\n tabIndex={0}\n onMouseMove={() => handleMouse(chapter)}\n >\n {chapter}\n
    \n ))}\n
    \n );\n}\n\nexport default ChapterSelect;\n","import { DropdownMenuLabel as ShadDropdownMenuLabel } from '@/components/shadcn-ui/dropdown-menu';\nimport { Bookmark, Clock, ArrowDownWideNarrow } from 'lucide-react';\n\nexport type GoToMenuItemProps = {\n handleSort: () => void;\n handleLocationHistory: () => void;\n handleBookmarks: () => void;\n};\n\nfunction GoToMenuItem({ handleSort, handleLocationHistory, handleBookmarks }: GoToMenuItemProps) {\n return (\n \n

    Go To

    \n
    \n \n \n \n
    \n
    \n );\n}\n\nexport default GoToMenuItem;\n","import BookChapterInput from '@/components/advanced/book-chapter-control/book-chapter-input.component';\nimport BookMenuItem, {\n BookType,\n} from '@/components/advanced/book-chapter-control/book-menu-item.component';\nimport ChapterSelect from '@/components/advanced/book-chapter-control/chapter-select.component';\nimport GoToMenuItem from '@/components/advanced/book-chapter-control/go-to-menu-item.component';\nimport {\n DropdownMenu as ShadDropdownMenu,\n DropdownMenuContent as ShadDropdownMenuContent,\n DropdownMenuLabel as ShadDropdownMenuLabel,\n DropdownMenuSeparator as ShadDropdownMenuSeparator,\n DropdownMenuTrigger as ShadDropdownMenuTrigger,\n} from '@/components/shadcn-ui/dropdown-menu';\nimport { Canon } from '@sillsdev/scripture';\nimport { ScriptureReference, getChaptersForBook } from 'platform-bible-utils';\nimport {\n KeyboardEvent as ReactKeyboardEvent,\n useCallback,\n useEffect,\n useLayoutEffect,\n useRef,\n useState,\n} from 'react';\n\ntype BookTypeLabels = {\n [bookType in BookType]: string;\n};\ntype BookChapterControlProps = {\n scrRef: ScriptureReference;\n handleSubmit: (scrRef: ScriptureReference) => void;\n};\n\nconst ALL_BOOK_IDS = Canon.allBookIds;\nconst BOOK_TYPE_LABELS: BookTypeLabels = {\n OT: 'Old Testament',\n NT: 'New Testament',\n DC: 'Deuterocanon',\n};\nconst BOOK_TYPE_ARRAY: BookType[] = ['OT', 'NT', 'DC'];\n// This is the height of three menu items to offset scrolling to the selected menu item\n// If you use menuItemRef.clientHeight- includes height of chapter div which is too big\nconst SCROLL_OFFSET = 32 + 32 + 32;\nconst SEARCH_QUERY_FORMATS = [\n /^(\\w+)$/i, // Matches a single word (book name or id)\n /^(\\w+)(?:\\s(\\d+))$/i, // Matches a word followed by a chapter number\n /^(\\w+)(?:\\s(\\d+):(\\d+))$/i, // Matches a word followed by a chapter and verse number\n];\nconst fetchGroupedBooks = (bookType: BookType) => {\n const groupedBooks = {\n OT: ALL_BOOK_IDS.filter((bookId) => Canon.isBookOT(bookId)),\n NT: ALL_BOOK_IDS.filter((bookId) => Canon.isBookNT(bookId)),\n DC: ALL_BOOK_IDS.filter((bookId) => Canon.isBookDC(bookId)),\n };\n return groupedBooks[bookType];\n};\nconst fetchEndChapter = (bookId: string) => {\n // getChaptersForBook returns -1 if not found in scrBookData\n // scrBookData only includes OT and NT, so all DC will return -1\n return getChaptersForBook(Canon.bookIdToNumber(bookId));\n};\n\n/**\n * Gets all of the English names from book ids\n *\n * @returns String[]\n */\nfunction getAllEnglishNames(): string[] {\n const allEnglishNames = ALL_BOOK_IDS.map((bookId) => {\n return Canon.bookIdToEnglishName(bookId);\n });\n return allEnglishNames;\n}\n\n/**\n * Determines if bookName is in allEnglishNames\n *\n * @param bookName Book English name\n * @returns True if bookName is included, false otherwise\n */\nfunction isValidBookEnglishName(bookName: string): boolean {\n return getAllEnglishNames().includes(bookName);\n}\n\n/**\n * Gets a bookId from given English name\n *\n * @param bookName Book English name\n * @returns BookId of provided bookName, undefined otherwise\n */\nfunction getBookIdFromEnglishName(bookName: string): string | undefined {\n // Convert bookName to lowercase and then capitalize the first letter\n const formattedBookName = bookName.toLowerCase().replace(/^\\w/, (c) => c.toUpperCase());\n\n if (isValidBookEnglishName(formattedBookName)) {\n const matchingBookId = ALL_BOOK_IDS.find((bookId) => {\n return Canon.bookIdToEnglishName(bookId) === formattedBookName;\n });\n return matchingBookId;\n }\n\n return undefined;\n}\n\nfunction BookChapterControl({ scrRef, handleSubmit }: BookChapterControlProps) {\n const [searchQuery, setSearchQuery] = useState('');\n const [selectedBookId, setSelectedBookId] = useState(\n Canon.bookNumberToId(scrRef.bookNum),\n );\n const [highlightedChapter, setHighlightedChapter] = useState(scrRef.chapterNum ?? 0);\n const [highlightedBookId, setHighlightedBookId] = useState(\n Canon.bookNumberToId(scrRef.bookNum),\n );\n const [isContentOpen, setIsContentOpen] = useState(false);\n const [isContentOpenDelayed, setIsContentOpenDelayed] = useState(isContentOpen);\n\n // This ref will always be defined\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const inputRef = useRef(undefined!);\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const contentRef = useRef(undefined!);\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const menuItemRef = useRef(undefined!);\n\n const fetchFilteredBooks = useCallback(\n (bookType: BookType) => {\n return fetchGroupedBooks(bookType).filter((bookId: string) => {\n const englishNameLowerCase = Canon.bookIdToEnglishName(bookId).toLowerCase();\n const normalizedQuery = searchQuery.replace(/[^a-zA-Z]/g, '').toLowerCase();\n return (\n englishNameLowerCase.includes(normalizedQuery) || // Match book name\n bookId.toLowerCase().includes(normalizedQuery) // Match book ID\n );\n });\n },\n [searchQuery],\n );\n\n const handleSearchInput = (searchString: string) => {\n setSearchQuery(searchString);\n };\n\n /**\n * Whether to prevent radix's logic from closing the dropdown. This is important because radix\n * tries to close the dropdown when the input first focuses, and we don't want it to do that. But\n * we don't want to prevent the dropdown from closing when we click away from the input, so we\n * don't want to just keep it open if the input is focused\n */\n const shouldPreventAutoClosing = useRef(false);\n\n const controlMenuState = useCallback((open: boolean) => {\n if (shouldPreventAutoClosing.current) {\n shouldPreventAutoClosing.current = false;\n return;\n }\n setIsContentOpen(open);\n }, []);\n\n const updateReference = useCallback(\n (bookId: string, shouldClose: boolean, chapter?: number, verse?: number) => {\n setHighlightedChapter(\n Canon.bookNumberToId(scrRef.bookNum) !== bookId ? 1 : scrRef.chapterNum,\n );\n\n if (shouldClose || fetchEndChapter(bookId) === -1) {\n handleSubmit({\n bookNum: Canon.bookIdToNumber(bookId),\n chapterNum: chapter || 1,\n verseNum: verse || 1,\n });\n\n setIsContentOpen(false);\n setSearchQuery('');\n return;\n }\n\n setSelectedBookId(selectedBookId !== bookId ? bookId : '');\n setIsContentOpen(!shouldClose);\n },\n [handleSubmit, scrRef.bookNum, scrRef.chapterNum, selectedBookId],\n );\n\n const handleSelectChapter = (chapterNumber: number) => {\n if (chapterNumber <= 0 || chapterNumber > fetchEndChapter(selectedBookId)) {\n return;\n }\n updateReference(selectedBookId, true, chapterNumber);\n };\n\n const handleInputSubmit = useCallback(() => {\n SEARCH_QUERY_FORMATS.forEach((format) => {\n const matches = searchQuery.match(format);\n if (matches) {\n // Book should be a bookId or an english name\n const [book, chapter = undefined, verse = undefined] = matches.slice(1);\n const englishName = getBookIdFromEnglishName(book);\n\n if (Canon.isBookIdValid(book) || englishName) {\n updateReference(\n englishName ?? book,\n true,\n chapter ? parseInt(chapter, 10) : 1,\n verse ? parseInt(verse, 10) : 1,\n );\n }\n }\n });\n }, [updateReference, searchQuery]);\n\n const handleKeyDownInput = useCallback(\n (event: ReactKeyboardEvent) => {\n if (!isContentOpen) {\n setIsContentOpen(true);\n } else if (event.key === 'ArrowDown' || event.key === 'ArrowUp') {\n if (\n typeof menuItemRef !== 'undefined' &&\n // Ref uses null\n // eslint-disable-next-line no-null/no-null\n menuItemRef.current !== null\n ) {\n menuItemRef.current.focus();\n } else if (\n typeof contentRef !== 'undefined' &&\n // Ref uses null\n // eslint-disable-next-line no-null/no-null\n contentRef.current !== null\n ) {\n contentRef.current.focus();\n }\n event.preventDefault();\n }\n },\n [isContentOpen],\n );\n\n const handleKeyDownContent = (event: ReactKeyboardEvent) => {\n // When the dropdown menu has focus, key strokes should give focus to the input component,\n // unless they're navigation keys (arrows and enter)\n const { key } = event;\n if (\n key === 'ArrowRight' ||\n key === 'ArrowLeft' ||\n key === 'ArrowDown' ||\n key === 'ArrowUp' ||\n key === 'Enter'\n ) {\n return;\n }\n\n inputRef.current.dispatchEvent(new KeyboardEvent('keydown', { key }));\n inputRef.current.focus();\n };\n\n const handleKeyDownMenuItem = (event: ReactKeyboardEvent) => {\n const { key } = event;\n if (highlightedBookId === selectedBookId) {\n if (key === 'Enter') {\n event.preventDefault();\n updateReference(selectedBookId, true, highlightedChapter);\n return;\n }\n\n let chapterOffSet = 0;\n if (key === 'ArrowRight') {\n if (highlightedChapter < fetchEndChapter(highlightedBookId)) {\n chapterOffSet = 1;\n } else {\n event.preventDefault();\n return;\n }\n } else if (key === 'ArrowLeft') {\n if (highlightedChapter > 1) {\n chapterOffSet = -1;\n } else {\n event.preventDefault();\n return;\n }\n } else if (key === 'ArrowDown') {\n chapterOffSet = 6;\n } else if (key === 'ArrowUp') {\n chapterOffSet = -6;\n }\n if (\n highlightedChapter + chapterOffSet <= 0 ||\n highlightedChapter + chapterOffSet > fetchEndChapter(highlightedBookId)\n ) {\n setHighlightedChapter(0);\n } else if (chapterOffSet !== 0) {\n setHighlightedChapter(highlightedChapter + chapterOffSet);\n event.preventDefault();\n }\n }\n };\n\n useEffect(() => {\n if (selectedBookId === highlightedBookId) {\n if (selectedBookId === Canon.bookNumberToId(scrRef.bookNum)) {\n setHighlightedChapter(scrRef.chapterNum);\n } else {\n setHighlightedChapter(1);\n }\n } else {\n setHighlightedChapter(0);\n }\n }, [highlightedBookId, scrRef.bookNum, scrRef.chapterNum, selectedBookId]);\n\n // The purpose of these useLayoutEffects and timeout is to delay the scroll just\n // enough so that the refs are defined and available when they are used after the timeout\n useLayoutEffect(() => {\n setIsContentOpenDelayed(isContentOpen);\n }, [isContentOpen]);\n\n useLayoutEffect(() => {\n const scrollTimeout = setTimeout(() => {\n if (isContentOpenDelayed && contentRef.current && menuItemRef.current) {\n const menuItemOffsetTop = menuItemRef.current.offsetTop;\n const scrollPosition = menuItemOffsetTop - SCROLL_OFFSET;\n contentRef.current.scrollTo({ top: scrollPosition, behavior: 'instant' });\n }\n }, 10);\n return () => {\n clearTimeout(scrollTimeout);\n };\n }, [isContentOpenDelayed]);\n\n return (\n
    \n \n \n {\n setSelectedBookId(Canon.bookNumberToId(scrRef.bookNum));\n setHighlightedBookId(Canon.bookNumberToId(scrRef.bookNum));\n setHighlightedChapter(scrRef.chapterNum > 0 ? scrRef.chapterNum : 0);\n setIsContentOpen(true);\n inputRef.current.focus();\n }}\n onFocus={() => {\n // Radix thinks we want to close because the input is being focused. Prevent that\n shouldPreventAutoClosing.current = true;\n }}\n handleSubmit={handleInputSubmit}\n placeholder={`${Canon.bookNumberToEnglishName(scrRef.bookNum)} ${scrRef.chapterNum}:${scrRef.verseNum}`}\n />\n \n \n console.log('sorting')}\n handleLocationHistory={() => console.log('location history')}\n handleBookmarks={() => console.log('bookmarks')}\n />\n {BOOK_TYPE_ARRAY.map(\n (bookType, bookTypeIndex) =>\n fetchFilteredBooks(bookType).length > 0 && (\n
    \n \n {BOOK_TYPE_LABELS[bookType]}\n \n\n {fetchFilteredBooks(bookType).map((bookId) => (\n
    \n updateReference(bookId, false)}\n isSelected={selectedBookId === bookId}\n handleHighlightBook={() => setHighlightedBookId(bookId)}\n handleKeyDown={handleKeyDownMenuItem}\n bookType={bookType}\n ref={(element: HTMLDivElement) => {\n if (selectedBookId === bookId) menuItemRef.current = element;\n }}\n >\n {\n setHighlightedChapter(chapterNumber);\n }}\n />\n \n
    \n ))}\n {BOOK_TYPE_ARRAY.length - 1 !== bookTypeIndex ? (\n \n ) : undefined}\n
    \n ),\n )}\n \n
    \n
    \n );\n}\n\nexport default BookChapterControl;\n","import React from 'react';\nimport { Slot } from '@radix-ui/react-slot';\nimport { cva, type VariantProps } from 'class-variance-authority';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport const buttonVariants = cva(\n 'pr-twp tw-inline-flex tw-items-center tw-justify-center tw-whitespace-nowrap tw-rounded-md tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-colors focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50',\n {\n variants: {\n variant: {\n default: 'tw-bg-primary tw-text-primary-foreground hover:tw-bg-primary/90',\n destructive: 'tw-bg-destructive tw-text-destructive-foreground hover:tw-bg-destructive/90',\n outline:\n 'tw-border tw-border-input tw-bg-background hover:tw-bg-accent hover:tw-text-accent-foreground',\n secondary: 'tw-bg-secondary tw-text-secondary-foreground hover:tw-bg-secondary/80',\n ghost: 'hover:tw-bg-accent hover:tw-text-accent-foreground',\n link: 'tw-text-primary tw-underline-offset-4 hover:tw-underline',\n },\n size: {\n default: 'tw-h-10 tw-px-4 tw-py-2',\n sm: 'tw-h-9 tw-rounded-md tw-px-3',\n lg: 'tw-h-11 tw-rounded-md tw-px-8',\n icon: 'tw-h-10 tw-w-10',\n },\n },\n defaultVariants: {\n variant: 'default',\n size: 'default',\n },\n },\n);\n\nexport interface ButtonProps\n extends React.ButtonHTMLAttributes,\n VariantProps {\n asChild?: boolean;\n}\n\nexport const Button = React.forwardRef(\n ({ className, variant, size, asChild = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'button';\n return (\n \n );\n },\n);\nButton.displayName = 'Button';\n","import React from 'react';\nimport * as LabelPrimitive from '@radix-ui/react-label';\nimport { cva, type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst labelVariants = cva(\n 'tw-text-sm tw-font-medium tw-leading-none peer-disabled:tw-cursor-not-allowed peer-disabled:tw-opacity-70',\n);\n\nexport const Label = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef & VariantProps\n>(({ className, ...props }, ref) => (\n \n));\nLabel.displayName = LabelPrimitive.Root.displayName;\n","import React from 'react';\nimport * as RadioGroupPrimitive from '@radix-ui/react-radio-group';\nimport { Circle } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst RadioGroup = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => {\n return (\n \n );\n});\nRadioGroup.displayName = RadioGroupPrimitive.Root.displayName;\n\nconst RadioGroupItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => {\n return (\n \n \n \n \n \n );\n});\nRadioGroupItem.displayName = RadioGroupPrimitive.Item.displayName;\n\nexport { RadioGroup, RadioGroupItem };\n","import React from 'react';\nimport * as PopoverPrimitive from '@radix-ui/react-popover';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Popover = PopoverPrimitive.Root;\n\nconst PopoverTrigger = PopoverPrimitive.Trigger;\n\nconst PopoverContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, align = 'center', sideOffset = 4, ...props }, ref) => (\n \n \n \n));\nPopoverContent.displayName = PopoverPrimitive.Content.displayName;\n\nexport { Popover, PopoverTrigger, PopoverContent };\n","import React from 'react';\nimport * as DialogPrimitive from '@radix-ui/react-dialog';\nimport { X } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Dialog = DialogPrimitive.Root;\n\nconst DialogTrigger = DialogPrimitive.Trigger;\n\nconst DialogPortal = DialogPrimitive.Portal;\n\nconst DialogClose = DialogPrimitive.Close;\n\nconst DialogOverlay = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nDialogOverlay.displayName = DialogPrimitive.Overlay.displayName;\n\nconst DialogContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, ...props }, ref) => (\n \n \n \n {children}\n \n \n Close\n \n \n \n));\nDialogContent.displayName = DialogPrimitive.Content.displayName;\n\nfunction DialogHeader({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nDialogHeader.displayName = 'DialogHeader';\n\nfunction DialogFooter({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nDialogFooter.displayName = 'DialogFooter';\n\nconst DialogTitle = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nDialogTitle.displayName = DialogPrimitive.Title.displayName;\n\nconst DialogDescription = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nDialogDescription.displayName = DialogPrimitive.Description.displayName;\n\nexport {\n Dialog,\n DialogPortal,\n DialogOverlay,\n DialogClose,\n DialogTrigger,\n DialogContent,\n DialogHeader,\n DialogFooter,\n DialogTitle,\n DialogDescription,\n};\n","import React from 'react';\nimport { type DialogProps } from '@radix-ui/react-dialog';\nimport { Command as CommandPrimitive } from 'cmdk';\nimport { Search } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Dialog, DialogContent } from '@/components/shadcn-ui/dialog';\n\nconst Command = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nCommand.displayName = CommandPrimitive.displayName;\n\ninterface CommandDialogProps extends DialogProps {}\n\nfunction CommandDialog({ children, ...props }: CommandDialogProps) {\n return (\n \n \n \n {children}\n \n \n \n );\n}\n\nconst CommandInput = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n
    \n \n \n
    \n));\n\nCommandInput.displayName = CommandPrimitive.Input.displayName;\n\nconst CommandList = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\n\nCommandList.displayName = CommandPrimitive.List.displayName;\n\nconst CommandEmpty = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>((props, ref) => (\n \n));\n\nCommandEmpty.displayName = CommandPrimitive.Empty.displayName;\n\nconst CommandGroup = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\n\nCommandGroup.displayName = CommandPrimitive.Group.displayName;\n\nconst CommandSeparator = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nCommandSeparator.displayName = CommandPrimitive.Separator.displayName;\n\nconst CommandItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\n\nCommandItem.displayName = CommandPrimitive.Item.displayName;\n\nfunction CommandShortcut({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nCommandShortcut.displayName = 'CommandShortcut';\n\nexport {\n Command,\n CommandDialog,\n CommandInput,\n CommandList,\n CommandEmpty,\n CommandGroup,\n CommandItem,\n CommandShortcut,\n CommandSeparator,\n};\n","import { useState } from 'react';\nimport { Check, ChevronsUpDown } from 'lucide-react';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport { Popover, PopoverContent, PopoverTrigger } from '@/components/shadcn-ui/popover';\nimport {\n Command,\n CommandEmpty,\n CommandInput,\n CommandItem,\n CommandList,\n} from '@/components/shadcn-ui/command';\nimport { PopoverProps } from '@radix-ui/react-popover';\n\nexport type ComboBoxLabelOption = { label: string };\nexport type ComboBoxOption = string | number | ComboBoxLabelOption;\n\nexport type ComboBoxProps = {\n /** Optional unique identifier */\n id?: string;\n /** Text label title for combobox */\n /** List of available options for the dropdown menu */\n options?: readonly T[];\n /** Additional css classes to help with unique styling of the combo box button */\n buttonClassName?: string;\n /** Additional css classes to help with unique styling of the combo box popover */\n popoverContentClassName?: string;\n /**\n * The selected value that the combo box currently holds. Must be shallow equal to one of the\n * options entries.\n */\n value?: T;\n /** Triggers when content of textfield is changed */\n onChange?: (newValue: T) => void;\n /** Used to determine the string value for a given option. */\n getOptionLabel?: (option: ComboBoxOption) => string;\n /** Text displayed on button if `value` is undefined */\n buttonPlaceholder?: string;\n /** Placeholder text for text field */\n textPlaceholder?: string;\n /** Text to display when no options match input */\n commandEmptyMessage?: string;\n /** Variant of button */\n buttonVariant?: ButtonProps['variant'];\n /** Text direction ltr or rtl */\n dir?: Direction;\n /** Optional boolean to set if trigger should be disabled */\n isDisabled?: boolean;\n} & PopoverProps;\n\ntype Direction = 'ltr' | 'rtl';\n\nfunction getOptionLabelDefault(option: ComboBoxOption): string {\n if (typeof option === 'string') {\n return option;\n }\n if (typeof option === 'number') {\n return option.toString();\n }\n return option.label;\n}\n\n/**\n * Autocomplete input and command palette with a list of suggestions.\n *\n * Thanks to Shadcn for heavy inspiration and documentation\n * https://ui.shadcn.com/docs/components/combobox\n */\nfunction ComboBox({\n id,\n options = [],\n buttonClassName,\n popoverContentClassName,\n value,\n onChange = () => {},\n getOptionLabel = getOptionLabelDefault,\n buttonPlaceholder = '',\n textPlaceholder = '',\n commandEmptyMessage = 'No option found',\n buttonVariant = 'outline',\n dir = 'ltr',\n isDisabled = false,\n ...props\n}: ComboBoxProps) {\n const [open, setOpen] = useState(false);\n\n return (\n \n \n \n \n {value ? getOptionLabel(value) : buttonPlaceholder}\n \n \n \n \n \n \n \n {commandEmptyMessage}\n \n {options.map((option) => (\n {\n onChange(option);\n setOpen(false);\n }}\n >\n \n {getOptionLabel(option)}\n \n ))}\n \n \n \n \n );\n}\n\nexport default ComboBox;\n","import { useMemo } from 'react';\nimport ComboBox from '@/components/basics/combo-box.component';\nimport { Label } from '@/components/shadcn-ui/label';\n\nexport type ChapterRangeSelectorProps = {\n startChapter: number;\n endChapter: number;\n handleSelectStartChapter: (chapter: number) => void;\n handleSelectEndChapter: (chapter: number) => void;\n isDisabled?: boolean;\n chapterCount: number;\n};\n\nexport default function ChapterRangeSelector({\n startChapter,\n endChapter,\n handleSelectStartChapter,\n handleSelectEndChapter,\n isDisabled = false,\n chapterCount,\n}: ChapterRangeSelectorProps) {\n const chapterOptions = useMemo(\n () => Array.from({ length: chapterCount }, (_, index) => index + 1),\n [chapterCount],\n );\n\n const onChangeStartChapter = (value: number) => {\n handleSelectStartChapter(value);\n if (value > endChapter) {\n handleSelectEndChapter(value);\n }\n };\n\n const onChangeEndChapter = (value: number) => {\n handleSelectEndChapter(value);\n if (value < startChapter) {\n handleSelectStartChapter(value);\n }\n };\n\n return (\n <>\n \n option.toString()}\n value={startChapter}\n />\n\n \n option.toString()}\n value={endChapter}\n />\n \n );\n}\n","import { Button } from '@/components/shadcn-ui/button';\nimport { Label } from '@/components/shadcn-ui/label';\nimport { RadioGroup, RadioGroupItem } from '@/components/shadcn-ui/radio-group';\nimport { Canon } from '@sillsdev/scripture';\nimport { LocalizedStringValue } from 'platform-bible-utils';\nimport { useState } from 'react';\nimport ChapterRangeSelector, {\n ChapterRangeSelectorProps,\n} from '../basics/chapter-range-selector.component';\n\nexport enum BookSelectionMode {\n CURRENT_BOOK = 'current book',\n CHOOSE_BOOKS = 'choose books',\n}\n\n/**\n * Object containing all keys used for localization in this component. If you're using this\n * component in an extension, you can pass it into the useLocalizedStrings hook to easily obtain the\n * localized strings and pass them into the localizedStrings prop of this component\n */\nexport const BOOK_SELECTOR_STRING_KEYS = Object.freeze([\n '%webView_bookSelector_currentBook%',\n '%webView_bookSelector_choose%',\n '%webView_bookSelector_chooseBooks%',\n] as const);\n\nexport type BookSelectorLocalizedStrings = {\n [localizedInventoryKey in (typeof BOOK_SELECTOR_STRING_KEYS)[number]]?: LocalizedStringValue;\n};\n\n/**\n * Gets the localized value for the provided key\n *\n * @param strings Object containing localized string\n * @param key Key for a localized string\n * @returns The localized value for the provided key, if available. Returns the key if no localized\n * value is available\n */\nconst localizeString = (\n strings: BookSelectorLocalizedStrings,\n key: keyof BookSelectorLocalizedStrings,\n) => {\n return strings[key] ?? key;\n};\n\ntype BookSelectorProps = ChapterRangeSelectorProps & {\n handleBookSelectionModeChange: (newMode: BookSelectionMode) => void;\n currentBookName: string;\n onSelectBooks: () => void;\n selectedBookIds: string[];\n localizedStrings: BookSelectorLocalizedStrings;\n};\n\nexport default function BookSelector({\n handleBookSelectionModeChange,\n currentBookName,\n onSelectBooks,\n selectedBookIds,\n chapterCount,\n endChapter,\n handleSelectEndChapter,\n startChapter,\n handleSelectStartChapter,\n localizedStrings,\n}: BookSelectorProps) {\n const currentBookText = localizeString(localizedStrings, '%webView_bookSelector_currentBook%');\n const chooseText = localizeString(localizedStrings, '%webView_bookSelector_choose%');\n const chooseBooksText = localizeString(localizedStrings, '%webView_bookSelector_chooseBooks%');\n\n const [bookSelectionMode, setBookSelectionMode] = useState(\n BookSelectionMode.CURRENT_BOOK,\n );\n\n const onSelectionModeChange = (newMode: BookSelectionMode) => {\n setBookSelectionMode(newMode);\n handleBookSelectionModeChange(newMode);\n };\n\n return (\n onSelectionModeChange(value as BookSelectionMode)}\n >\n
    \n
    \n
    \n \n \n
    \n \n
    \n \n
    \n
    \n
    \n
    \n \n \n
    \n \n onSelectBooks()}\n >\n {chooseText}\n \n
    \n
    \n \n );\n}\n","import { DropdownMenuTrigger } from '@radix-ui/react-dropdown-menu';\nimport { FilterIcon } from 'lucide-react';\nimport { Table } from '@tanstack/react-table';\n\nimport { Button } from '@/components/shadcn-ui/button';\nimport {\n DropdownMenu,\n DropdownMenuCheckboxItem,\n DropdownMenuContent,\n DropdownMenuLabel,\n DropdownMenuSeparator,\n} from '@/components/shadcn-ui/dropdown-menu';\n\ninterface DataTableViewOptionsProps {\n table: Table;\n}\n\nfunction DataTableViewOptions({ table }: DataTableViewOptionsProps) {\n return (\n \n \n \n \n \n Toggle columns\n \n {table\n .getAllColumns()\n .filter((column) => column.getCanHide())\n .map((column) => {\n return (\n column.toggleVisibility(!!value)}\n >\n {column.id}\n \n );\n })}\n \n \n );\n}\n\nexport default DataTableViewOptions;\n","import React from 'react';\nimport * as SelectPrimitive from '@radix-ui/react-select';\nimport { Check, ChevronDown, ChevronUp } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Select = SelectPrimitive.Root;\n\nconst SelectGroup = SelectPrimitive.Group;\n\nconst SelectValue = SelectPrimitive.Value;\n\nconst SelectTrigger = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, ...props }, ref) => (\n span]:tw-line-clamp-1',\n className,\n )}\n {...props}\n >\n {children}\n \n \n \n \n));\nSelectTrigger.displayName = SelectPrimitive.Trigger.displayName;\n\nconst SelectScrollUpButton = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n));\nSelectScrollUpButton.displayName = SelectPrimitive.ScrollUpButton.displayName;\n\nconst SelectScrollDownButton = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n));\nSelectScrollDownButton.displayName = SelectPrimitive.ScrollDownButton.displayName;\n\nconst SelectContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, position = 'popper', ...props }, ref) => (\n \n \n \n \n {children}\n \n \n \n \n));\nSelectContent.displayName = SelectPrimitive.Content.displayName;\n\nconst SelectLabel = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSelectLabel.displayName = SelectPrimitive.Label.displayName;\n\nconst SelectItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, ...props }, ref) => (\n \n \n \n \n \n \n\n {children}\n \n));\nSelectItem.displayName = SelectPrimitive.Item.displayName;\n\nconst SelectSeparator = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSelectSeparator.displayName = SelectPrimitive.Separator.displayName;\n\nexport {\n Select,\n SelectGroup,\n SelectValue,\n SelectTrigger,\n SelectContent,\n SelectLabel,\n SelectItem,\n SelectSeparator,\n SelectScrollUpButton,\n SelectScrollDownButton,\n};\n","import { ChevronLeftIcon, ChevronRightIcon, ArrowLeftIcon, ArrowRightIcon } from 'lucide-react';\nimport { Table } from '@tanstack/react-table';\n\nimport { Button } from '@/components/shadcn-ui/button';\nimport {\n Select,\n SelectContent,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\n\ninterface DataTablePaginationProps {\n table: Table;\n}\n\nfunction DataTablePagination({ table }: DataTablePaginationProps) {\n return (\n
    \n
    \n
    \n {table.getFilteredSelectedRowModel().rows.length} of{' '}\n {table.getFilteredRowModel().rows.length} row(s) selected\n
    \n
    \n

    Rows per page

    \n {\n table.setPageSize(Number(value));\n }}\n >\n \n \n \n \n {[10, 20, 30, 40, 50].map((pageSize) => (\n \n {pageSize}\n \n ))}\n \n \n
    \n
    \n Page {table.getState().pagination.pageIndex + 1} of {table.getPageCount()}\n
    \n
    \n table.setPageIndex(0)}\n disabled={!table.getCanPreviousPage()}\n >\n Go to first page\n \n \n table.previousPage()}\n disabled={!table.getCanPreviousPage()}\n >\n Go to previous page\n \n \n table.nextPage()}\n disabled={!table.getCanNextPage()}\n >\n Go to next page\n \n \n table.setPageIndex(table.getPageCount() - 1)}\n disabled={!table.getCanNextPage()}\n >\n Go to last page\n \n \n
    \n
    \n
    \n );\n}\n\nexport default DataTablePagination;\n","import React from 'react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Table = React.forwardRef<\n HTMLTableElement,\n React.HTMLAttributes & { stickyHeader?: boolean }\n>(({ className, stickyHeader, ...props }, ref) => (\n
    \n \n
    \n));\nTable.displayName = 'Table';\n\nconst TableHeader = React.forwardRef<\n HTMLTableSectionElement,\n React.HTMLAttributes & { stickyHeader?: boolean }\n>(({ className, stickyHeader, ...props }, ref) => (\n \n));\nTableHeader.displayName = 'TableHeader';\n\nconst TableBody = React.forwardRef<\n HTMLTableSectionElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableBody.displayName = 'TableBody';\n\nconst TableFooter = React.forwardRef<\n HTMLTableSectionElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n tr]:last:tw-border-b-0', className)}\n {...props}\n />\n));\nTableFooter.displayName = 'TableFooter';\n\nconst TableRow = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nTableRow.displayName = 'TableRow';\n\nconst TableHead = React.forwardRef<\n HTMLTableCellElement,\n React.ThHTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableHead.displayName = 'TableHead';\n\nconst TableCell = React.forwardRef<\n HTMLTableCellElement,\n React.TdHTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableCell.displayName = 'TableCell';\n\nconst TableCaption = React.forwardRef<\n HTMLTableCaptionElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableCaption.displayName = 'TableCaption';\n\nexport { Table, TableHeader, TableBody, TableFooter, TableHead, TableRow, TableCell, TableCaption };\n","import { useState } from 'react';\n\nimport {\n ColumnFiltersState,\n flexRender,\n getCoreRowModel,\n getFilteredRowModel,\n getPaginationRowModel,\n getSortedRowModel,\n SortingState,\n ColumnDef as TSColumnDef,\n Row as TSRow,\n RowSelectionState as TSRowSelectionState,\n SortDirection as TSSortDirection,\n Table as TSTable,\n useReactTable,\n VisibilityState,\n} from '@tanstack/react-table';\n\nimport DataTableViewOptions from '@/components/advanced/data-table/data-table-column-toggle.component';\nimport DataTablePagination from '@/components/advanced/data-table/data-table-pagination.component';\nimport { Button } from '@/components/shadcn-ui/button';\nimport {\n Table,\n TableBody,\n TableCell,\n TableHead,\n TableHeader,\n TableRow,\n} from '@/components/shadcn-ui/table';\n\nexport type ColumnDef = TSColumnDef;\nexport type RowContents = TSRow;\nexport type TableContents = TSTable;\nexport type SortDirection = TSSortDirection;\nexport type RowSelectionState = TSRowSelectionState;\n\ninterface DataTableProps {\n columns: ColumnDef[];\n data: TData[];\n enablePagination?: boolean;\n showPaginationControls?: boolean;\n showColumnVisibilityControls?: boolean;\n stickyHeader?: boolean;\n onRowClickHandler?: (row: RowContents, table: TableContents) => void;\n}\n\n/**\n * Feature-rich table component that infuses our basic shadcn-based Table component with features\n * from TanStack's React Table library\n */\nfunction DataTable({\n columns,\n data,\n enablePagination = false,\n showPaginationControls = false,\n showColumnVisibilityControls = false,\n stickyHeader = false,\n onRowClickHandler = () => {},\n}: DataTableProps) {\n const [sorting, setSorting] = useState([]);\n const [columnFilters, setColumnFilters] = useState([]);\n const [columnVisibility, setColumnVisibility] = useState({});\n const [rowSelection, setRowSelection] = useState({});\n\n const table = useReactTable({\n data,\n columns,\n getCoreRowModel: getCoreRowModel(),\n ...(enablePagination && { getPaginationRowModel: getPaginationRowModel() }),\n onSortingChange: setSorting,\n getSortedRowModel: getSortedRowModel(),\n onColumnFiltersChange: setColumnFilters,\n getFilteredRowModel: getFilteredRowModel(),\n onColumnVisibilityChange: setColumnVisibility,\n onRowSelectionChange: setRowSelection,\n state: {\n sorting,\n columnFilters,\n columnVisibility,\n rowSelection,\n },\n });\n\n return (\n
    \n {showColumnVisibilityControls && }\n \n \n {table.getHeaderGroups().map((headerGroup) => (\n \n {headerGroup.headers.map((header) => {\n return (\n \n {header.isPlaceholder\n ? undefined\n : flexRender(header.column.columnDef.header, header.getContext())}\n \n );\n })}\n \n ))}\n \n \n {table.getRowModel().rows?.length ? (\n table.getRowModel().rows.map((row) => (\n onRowClickHandler(row, table)}\n key={row.id}\n data-state={row.getIsSelected() && 'selected'}\n >\n {row.getVisibleCells().map((cell) => (\n \n {flexRender(cell.column.columnDef.cell, cell.getContext())}\n \n ))}\n \n ))\n ) : (\n \n \n No results.\n \n \n )}\n \n
    \n {enablePagination && (\n
    \n table.previousPage()}\n disabled={!table.getCanPreviousPage()}\n >\n Previous\n \n table.nextPage()}\n disabled={!table.getCanNextPage()}\n >\n Next\n \n
    \n )}\n {enablePagination && showPaginationControls && }\n
    \n );\n}\n\nexport default DataTable;\n","import {\n Table,\n TableBody,\n TableCell,\n TableHead,\n TableHeader,\n TableRow,\n} from '@/components/shadcn-ui/table';\nimport { Canon } from '@sillsdev/scripture';\nimport { deepEqual, LanguageStrings, ScriptureReference } from 'platform-bible-utils';\nimport { useMemo } from 'react';\nimport { InventoryItemOccurrence } from './inventory-utils';\n\n/** Props for the OccurrencesTable component */\ntype OccurrencesTableProps = {\n /** Data that contains scriptures references and snippets of scripture */\n occurrenceData: InventoryItemOccurrence[];\n /** Callback function that is executed when the scripture reference is changed */\n setScriptureReference: (scriptureReference: ScriptureReference) => void;\n /**\n * Object with all localized strings that the OccurrencesTable needs to work well across multiple\n * languages\n */\n localizedStrings: LanguageStrings;\n};\n\n/**\n * Table that shows occurrences of specified inventory item(s). The first column shows the related\n * scripture reference. The second column shows the snippet of scripture that contains the specified\n * inventory item\n */\nfunction OccurrencesTable({\n occurrenceData,\n setScriptureReference,\n localizedStrings,\n}: OccurrencesTableProps) {\n const referenceHeaderText =\n localizedStrings['%webView_inventory_occurrences_table_header_reference%'];\n const occurrenceHeaderText =\n localizedStrings['%webView_inventory_occurrences_table_header_occurrence%'];\n\n const occurrences: InventoryItemOccurrence[] = useMemo(() => {\n const uniqueOccurrences: InventoryItemOccurrence[] = [];\n\n occurrenceData.forEach((occurrence) => {\n if (!uniqueOccurrences.some((uniqueOccurrence) => deepEqual(uniqueOccurrence, occurrence))) {\n uniqueOccurrences.push(occurrence);\n }\n });\n\n return uniqueOccurrences;\n }, [occurrenceData]);\n\n return (\n \n \n \n {referenceHeaderText}\n {occurrenceHeaderText}\n \n \n \n {occurrences.length > 0 &&\n occurrences.map((occurrence) => (\n {\n setScriptureReference(occurrence.reference);\n }}\n >\n {`${Canon.bookNumberToEnglishName(occurrence.reference.bookNum)} ${occurrence.reference.chapterNum}:${occurrence.reference.verseNum}`}\n {occurrence.text}\n \n ))}\n \n
    \n );\n}\n\nexport default OccurrencesTable;\n","import React from 'react';\nimport * as CheckboxPrimitive from '@radix-ui/react-checkbox';\nimport { Check } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Checkbox = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n \n \n));\nCheckbox.displayName = CheckboxPrimitive.Root.displayName;\n\nexport default Checkbox;\n","import { Canon } from '@sillsdev/scripture';\nimport { ScriptureReference } from 'platform-bible-utils';\n\n/* #region Types */\n\n/**\n * Status of items that appear in inventories. 'approved' and 'unapproved' items are defined in the\n * project's `Settings.xml`. All other items are defined as 'unknown'\n */\nexport type Status = 'approved' | 'unapproved' | 'unknown';\n\n/** Occurrence of item in inventory. Primarily used by table that shows occurrences */\nexport type InventoryItemOccurrence = {\n /** Reference to scripture where the item appears */\n reference: ScriptureReference;\n /** Snippet of scripture that contains the occurrence */\n text: string;\n};\n\n/** Data structure that contains all information on an item that is shown in an inventory */\nexport type InventoryTableData = {\n /**\n * The item (e.g. a character in the characters inventory, a marker in the marker inventory) In\n * most cases the array will only have one element. In case of additional items (e.g. the\n * preceding marker in the markers check), the primary item should be stored in the first index.\n * To show additional items in the inventory, make sure to configure the `additionalItemsLabels`\n * prop for the Inventory component\n */\n items: string[];\n /** The number of times this item occurs in the selected scope */\n count: number;\n /** The status of this item (see documentation for `Status` type for more information) */\n status: Status;\n /** Occurrences of this item in the scripture text for the selected scope */\n occurrences: InventoryItemOccurrence[];\n};\n\n/* #endregion */\n\n/* #region Functions */\n\n/**\n * Splits USFM string into shorter line-like segments\n *\n * @param text A single (likely very large) USFM string\n * @returns An array containing the input text, split into shorter segments\n */\nexport const getLinesFromUSFM = (text: string) => {\n // Splits on (CR)LF, CR, \\v, \\c and \\id\n return text.split(/(?:\\r?\\n|\\r)|(?=(?:\\\\(?:v|c|id)))/g);\n};\n\n/**\n * Extracts chapter or verse number from USFM strings that start with a \\c or \\v marker\n *\n * @param text USFM string that is expected to start with \\c or \\v marker\n * @returns Chapter or verse number if one is found. Else returns 0.\n */\nexport const getNumberFromUSFM = (text: string): number | undefined => {\n // Captures all digits that follow \\v or \\c markers followed by whitespace located at the start of a string\n const regex = /^\\\\[vc]\\s+(\\d+)/;\n const match = text.match(regex);\n\n if (match) {\n return +match[1];\n }\n return undefined;\n};\n\n/**\n * Gets book ID from USFM string that starts with the \\id marker, and returns book number for it\n *\n * @param text USFM string that is expected to start with \\id marker\n * @returns Book number corresponding to the \\id marker in the input text. Returns 0 if no marker is\n * found or the marker is not valid\n */\nexport const getBookNumFromId = (text: string): number => {\n // Captures all digits that follow an \\id marker followed by whitespace located at the start of a string\n const match = text.match(/^\\\\id\\s+([A-Za-z]+)/);\n if (match) {\n return Canon.bookIdToNumber(match[1]);\n }\n return 0;\n};\n\n/**\n * Gets the status for an item, typically used in the Inventory component\n *\n * @param item The item for which the status is being requested\n * @param approvedItems Array of approved items, typically as defined in `Settings.xml`\n * @param unapprovedItems Array of unapproved items, typically as defined in `Settings.xml`\n * @returns The status for the specified item\n */\nexport const getStatusForItem = (\n item: string,\n approvedItems: string[],\n unapprovedItems: string[],\n): Status => {\n if (unapprovedItems.includes(item)) return 'unapproved';\n if (approvedItems.includes(item)) return 'approved';\n return 'unknown';\n};\n\n/* #endregion */\n","import React from 'react';\nimport * as TogglePrimitive from '@radix-ui/react-toggle';\nimport { cva, type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst toggleVariants = cva(\n 'pr-twp tw-inline-flex tw-items-center tw-justify-center tw-rounded-md tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-colors hover:tw-bg-muted hover:tw-text-muted-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50 data-[state=on]:tw-bg-accent data-[state=on]:tw-text-accent-foreground',\n {\n variants: {\n variant: {\n default: 'tw-bg-transparent',\n outline:\n 'tw-border tw-border-input tw-bg-transparent hover:tw-bg-accent hover:tw-text-accent-foreground',\n },\n size: {\n default: 'tw-h-10 tw-px-3',\n sm: 'tw-h-9 tw-px-2.5',\n lg: 'tw-h-11 tw-px-5',\n },\n },\n defaultVariants: {\n variant: 'default',\n size: 'default',\n },\n },\n);\n\nconst Toggle = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef & VariantProps\n>(({ className, variant, size, ...props }, ref) => (\n \n));\n\nToggle.displayName = TogglePrimitive.Root.displayName;\n\nexport { Toggle, toggleVariants };\n","import React from 'react';\nimport * as ToggleGroupPrimitive from '@radix-ui/react-toggle-group';\nimport { type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { toggleVariants } from '@/components/shadcn-ui/toggle';\n\nconst ToggleGroupContext = React.createContext>({\n size: 'default',\n variant: 'default',\n});\n\nconst ToggleGroup = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef &\n VariantProps\n>(({ className, variant, size, children, ...props }, ref) => (\n \n \n {children}\n \n \n));\n\nToggleGroup.displayName = ToggleGroupPrimitive.Root.displayName;\n\nconst ToggleGroupItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef &\n VariantProps\n>(({ className, children, variant, size, ...props }, ref) => {\n const context = React.useContext(ToggleGroupContext);\n\n return (\n \n {children}\n \n );\n});\n\nToggleGroupItem.displayName = ToggleGroupPrimitive.Item.displayName;\n\nexport { ToggleGroup, ToggleGroupItem };\n","import { ColumnDef, SortDirection } from '@/components/advanced/data-table/data-table.component';\nimport { Button } from '@/components/shadcn-ui/button';\nimport { ToggleGroup, ToggleGroupItem } from '@/components/shadcn-ui/toggle-group';\nimport {\n ArrowDownIcon,\n ArrowUpDownIcon,\n ArrowUpIcon,\n CircleCheckIcon,\n CircleHelpIcon,\n CircleXIcon,\n} from 'lucide-react';\nimport { ReactNode } from 'react';\nimport { InventoryTableData, Status } from './inventory-utils';\n\n/**\n * Gets an icon that indicates the current sorting direction based on the provided input\n *\n * @param sortDirection Sorting direction. Can be ascending ('asc'), descending ('desc') or false (\n * i.e. not sorted)\n * @returns The appropriate sorting icon for the provided sorting direction\n */\nconst getSortingIcon = (sortDirection: false | SortDirection): ReactNode => {\n if (sortDirection === 'asc') {\n return ;\n }\n if (sortDirection === 'desc') {\n return ;\n }\n return ;\n};\n\n/**\n * Function that creates the item column for inventories\n *\n * @param itemLabel Localized label for the item column (e.g. 'Character', 'Repeated Word', etc.)\n * @returns Column that shows the inventory items. Should be used with the DataTable component\n */\nexport const inventoryItemColumn = (itemLabel: string): ColumnDef => {\n return {\n accessorKey: 'item',\n accessorFn: (row: InventoryTableData) => row.items[0],\n header: ({ column }) => (\n \n ),\n };\n};\n\n/**\n * Function that creates the additional item columns for inventories\n *\n * @param additionalItemLabel Localized label for the additional item column (e.g. 'Preceding\n * Marker')\n * @param additionalItemIndex Index that locates the desired item in the items array of the\n * inventory\n * @returns Column that shows additional inventory items. Should be used with the DataTable\n * component\n */\nexport const inventoryAdditionalItemColumn = (\n additionalItemLabel: string,\n additionalItemIndex: number,\n): ColumnDef => {\n return {\n accessorKey: `item${additionalItemIndex}`,\n accessorFn: (row: InventoryTableData) => row.items[additionalItemIndex],\n header: ({ column }) => (\n \n ),\n };\n};\n\n/**\n * Function that creates the count column for inventories. Should be used with the DataTable\n * component.\n *\n * @param itemLabel Localized label for the count column\n * @returns Column that shows the number of occurrences of the related inventory items\n */\nexport const inventoryCountColumn = (countLabel: string): ColumnDef => {\n return {\n accessorKey: 'count',\n header: ({ column }) => (\n
    \n \n
    \n ),\n cell: ({ row }) =>
    {row.getValue('count')}
    ,\n };\n};\n\n/**\n * Function that updates project settings when status for item(s) changes\n *\n * @param changedItems Array of items for which the status is being updated\n * @param newStatus The status that the items are being given\n * @param approvedItems Array of currently approved items\n * @param onApprovedItemsChange Callback function that stores the updated list of approved items\n * @param unapprovedItems Array of currently unapproved items\n * @param onUnapprovedItemsChange Callback function that stores the updated list of unapproved items\n */\nconst statusChangeHandler = (\n changedItems: string[],\n newStatus: Status,\n approvedItems: string[],\n onApprovedItemsChange: (items: string[]) => void,\n unapprovedItems: string[],\n onUnapprovedItemsChange: (items: string[]) => void,\n) => {\n let newApprovedItems: string[] = [...approvedItems];\n changedItems.forEach((item) => {\n if (newStatus === 'approved') {\n if (!newApprovedItems.includes(item)) {\n newApprovedItems.push(item);\n }\n } else {\n newApprovedItems = newApprovedItems.filter((validItem) => validItem !== item);\n }\n });\n onApprovedItemsChange(newApprovedItems);\n\n let newUnapprovedItems: string[] = [...unapprovedItems];\n changedItems.forEach((item) => {\n if (newStatus === 'unapproved') {\n if (!newUnapprovedItems.includes(item)) {\n newUnapprovedItems.push(item);\n }\n } else {\n newUnapprovedItems = newUnapprovedItems.filter((unapprovedItem) => unapprovedItem !== item);\n }\n });\n onUnapprovedItemsChange(newUnapprovedItems);\n};\n\n/**\n * Function that creates the status column for inventories. Should be used with the DataTable\n * component.\n *\n * @param statusLabel Localized label for the status column\n * @param approvedItems Array of approved items, typically as defined in `Settings.xml`\n * @param onApprovedItemsChange Callback function that stores the updated list of approved items\n * @param unapprovedItems Array of unapproved items, typically as defined in `Settings.xml`\n * @param onUnapprovedItemsChange Callback function that stores the updated list of unapproved items\n * @returns Column that shows the status buttons for the related inventory item. The button for the\n * current status of the item is selected\n */\nexport const inventoryStatusColumn = (\n statusLabel: string,\n approvedItems: string[],\n onApprovedItemsChange: (items: string[]) => void,\n unapprovedItems: string[],\n onUnapprovedItemsChange: (items: string[]) => void,\n): ColumnDef => {\n return {\n accessorKey: 'status',\n header: ({ column }) => {\n return (\n
    \n \n
    \n );\n },\n cell: ({ row }) => {\n const status: Status = row.getValue('status');\n const item: string = row.getValue('item');\n return (\n \n \n statusChangeHandler(\n [item],\n 'approved',\n approvedItems,\n onApprovedItemsChange,\n unapprovedItems,\n onUnapprovedItemsChange,\n )\n }\n value=\"approved\"\n >\n \n \n \n statusChangeHandler(\n [item],\n 'unapproved',\n approvedItems,\n onApprovedItemsChange,\n unapprovedItems,\n onUnapprovedItemsChange,\n )\n }\n value=\"unapproved\"\n >\n \n \n \n statusChangeHandler(\n [item],\n 'unknown',\n approvedItems,\n onApprovedItemsChange,\n unapprovedItems,\n onUnapprovedItemsChange,\n )\n }\n value=\"unknown\"\n >\n \n \n \n );\n },\n };\n};\n","import DataTable, {\n ColumnDef,\n RowContents,\n RowSelectionState,\n TableContents,\n} from '@/components/advanced/data-table/data-table.component';\nimport OccurrencesTable from '@/components/advanced/inventory/occurrences-table.component';\nimport Checkbox from '@/components/shadcn-ui/checkbox';\nimport { Input } from '@/components/shadcn-ui/input';\nimport { Label } from '@/components/shadcn-ui/label';\nimport {\n Select,\n SelectContent,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\nimport {\n deepEqual,\n LocalizedStringValue,\n ScriptureReference,\n substring,\n} from 'platform-bible-utils';\nimport { useEffect, useMemo, useState } from 'react';\nimport {\n getBookNumFromId,\n getLinesFromUSFM,\n getNumberFromUSFM,\n getStatusForItem,\n InventoryItemOccurrence,\n InventoryTableData,\n Status,\n} from './inventory-utils';\nimport { inventoryAdditionalItemColumn } from './inventory-columns';\n\n/**\n * Object containing all keys used for localization in this component. If you're using this\n * component in an extension, you can pass it into the useLocalizedStrings hook to easily obtain the\n * localized strings and pass them into the localizedStrings prop of this component\n */\nexport const INVENTORY_STRING_KEYS = Object.freeze([\n '%webView_inventory_all%',\n '%webView_inventory_approved%',\n '%webView_inventory_unapproved%',\n '%webView_inventory_unknown%',\n '%webView_inventory_scope_currentBook%',\n '%webView_inventory_scope_chapter%',\n '%webView_inventory_scope_verse%',\n '%webView_inventory_filter_text%',\n '%webView_inventory_show_additional_items%',\n '%webView_inventory_occurrences_table_header_reference%',\n '%webView_inventory_occurrences_table_header_occurrence%',\n] as const);\n\nexport type InventoryLocalizedStrings = {\n [localizedInventoryKey in (typeof INVENTORY_STRING_KEYS)[number]]?: LocalizedStringValue;\n};\n\n/** Scope of scripture that the inventory can operate on */\nexport type Scope = 'book' | 'chapter' | 'verse';\n\n/** Status values that the status filter can select from */\ntype StatusFilter = Status | 'all';\n\n/** Text labels for the inventory columns and the control components of additional inventory items */\ntype AdditionalItemsLabels = {\n checkboxText?: string;\n tableHeaders?: string[];\n};\n\n/**\n * Filters data that is shown in the DataTable section of the Inventory\n *\n * @param itemData All inventory items and their related information\n * @param statusFilter Allows filtering by status (i.e. show all items, or only items that are\n * 'approved', 'unapproved' or 'unknown')\n * @param textFilter Allows filtering by text. All items that include the filter text will be\n * selected.\n * @returns Array of items and their related information that are matched by the specified filters\n */\nconst filterItemData = (\n itemData: InventoryTableData[],\n statusFilter: StatusFilter,\n textFilter: string,\n): InventoryTableData[] => {\n let filteredItemData: InventoryTableData[] = itemData;\n\n if (statusFilter !== 'all') {\n filteredItemData = filteredItemData.filter(\n (item) =>\n (statusFilter === 'approved' && item.status === 'approved') ||\n (statusFilter === 'unapproved' && item.status === 'unapproved') ||\n (statusFilter === 'unknown' && item.status === 'unknown'),\n );\n }\n\n if (textFilter !== '')\n filteredItemData = filteredItemData.filter((item) => item.items[0].includes(textFilter));\n\n return filteredItemData;\n};\n\n/**\n * Turns array of strings into array of inventory items, along with their count and status\n *\n * @param text The source scripture text that is searched for inventory items\n * @param scriptureRef The scripture reference that the application is currently set to\n * @param approvedItems Array of approved items, typically as defined in `Settings.xml`\n * @param unapprovedItems Array of unapproved items, typically as defined in `Settings.xml`\n * @param itemRegex Regular expression that describes what items this Inventory should extract from\n * the provided scripture text\n * @returns Array of inventory items, along with their count and status\n */\nconst createTableData = (\n text: string | undefined,\n scriptureRef: ScriptureReference,\n approvedItems: string[],\n unapprovedItems: string[],\n itemRegex: RegExp,\n): InventoryTableData[] => {\n if (!text) return [];\n\n const tableData: InventoryTableData[] = [];\n\n let currentBook: number | undefined = scriptureRef.bookNum;\n let currentChapter: number | undefined = scriptureRef.chapterNum;\n let currentVerse: number | undefined = scriptureRef.verseNum;\n\n const lines = getLinesFromUSFM(text);\n\n lines.forEach((line: string) => {\n if (line.startsWith('\\\\id')) {\n currentBook = getBookNumFromId(line);\n currentChapter = 0;\n currentVerse = 0;\n }\n if (line.startsWith('\\\\c')) {\n currentChapter = getNumberFromUSFM(line);\n currentVerse = 0;\n }\n if (line.startsWith('\\\\v')) {\n currentVerse = getNumberFromUSFM(line);\n if (currentChapter === 0) {\n currentChapter = scriptureRef.chapterNum;\n }\n }\n\n let match: RegExpExecArray | undefined = itemRegex.exec(line) ?? undefined;\n while (match) {\n const items: string[] = [];\n match.forEach((item) => items.push(item));\n const itemIndex = match.index;\n const existingItem = tableData.find((tableEntry) => deepEqual(tableEntry.items, items));\n const newReference: InventoryItemOccurrence = {\n reference: {\n bookNum: currentBook !== undefined ? currentBook : -1,\n chapterNum: currentChapter !== undefined ? currentChapter : -1,\n verseNum: currentVerse !== undefined ? currentVerse : -1,\n },\n text: substring(line, Math.max(0, itemIndex - 25), Math.min(itemIndex + 25, line.length)),\n };\n if (existingItem) {\n existingItem.count += 1;\n existingItem.occurrences.push(newReference);\n } else {\n const newItem: InventoryTableData = {\n items,\n count: 1,\n status: getStatusForItem(items[0], approvedItems, unapprovedItems),\n occurrences: [newReference],\n };\n tableData.push(newItem);\n }\n\n match = itemRegex.exec(line) ?? undefined;\n }\n });\n\n return tableData;\n};\n\n/**\n * Gets the localized value for the provided key\n *\n * @param strings Object containing localized string\n * @param key Key for a localized string\n * @returns The localized value for the provided key, if available. Returns the key if no localized\n * value is available\n */\nconst localizeString = (\n strings: InventoryLocalizedStrings,\n key: keyof InventoryLocalizedStrings,\n) => {\n return strings[key] ?? key;\n};\n\n/** Props for the Inventory component */\ntype InventoryProps = {\n /** The scripture reference that the application is currently set to */\n scriptureReference: ScriptureReference;\n /** Callback function that is executed when the scripture reference is changed */\n setScriptureReference: (scriptureReference: ScriptureReference) => void;\n /**\n * Object with all localized strings that the Inventory needs to work well across multiple\n * languages. When using this component with Platform.Bible, you can import\n * `INVENTORY_STRING_KEYS` from this library, pass it in to the Platform's localization hook, and\n * pass the localized keys that are returned by the hook into this prop.\n */\n localizedStrings: InventoryLocalizedStrings;\n /**\n * The logic that finds the desired items in the source text. This can either be a Regular\n * expression that captures one or multiple items (preferred), or a custom function that builds\n * and return an InventoryDataTable[] manually. Note: In case the logic captures more than one\n * item (i.e. InventoryTableData.items has a length greater than 1), you must provide text labels\n * for the related columns and control elements to show by setting the `additionalItemsLabels`\n * prop\n */\n extractItems:\n | RegExp\n | ((\n text: string | undefined,\n scriptureRef: ScriptureReference,\n approvedItems: string[],\n unapprovedItems: string[],\n ) => InventoryTableData[]);\n /**\n * Text labels for control elements and additional column headers in case your Inventory has more\n * than one item to show (e.g. The 'Preceding Marker' in the Markers Inventory)\n */\n additionalItemsLabels?: AdditionalItemsLabels;\n /** Array of approved items, typically as defined in `Settings.xml` */\n approvedItems: string[];\n /** Array of unapproved items, typically as defined in `Settings.xml` */\n unapprovedItems: string[];\n /** The source scripture text that is searched for in inventory items */\n text: string | undefined;\n /** Scope of scripture that the inventory will operate on */\n scope: Scope;\n /** Callback function that is executed when the scope is changed from the Inventory */\n onScopeChange: (scope: Scope) => void;\n /**\n * Column definitions for the Inventory data table. The most commonly used column definitions are\n * pre-configured for your convenience and can be imported (e.g. inventoryItemColumn,\n * inventoryAdditionalItemColumn inventoryCountColumn, and inventoryStatusColumn). If you need any\n * other columns you can add these yourself\n */\n columns: ColumnDef[];\n};\n\n/** Inventory component that is used to view and control the status of provided project settings */\nexport default function Inventory({\n scriptureReference,\n setScriptureReference,\n localizedStrings,\n extractItems,\n additionalItemsLabels,\n approvedItems,\n unapprovedItems,\n text,\n scope,\n onScopeChange,\n columns,\n}: InventoryProps) {\n const allItemsText = localizeString(localizedStrings, '%webView_inventory_all%');\n const approvedItemsText = localizeString(localizedStrings, '%webView_inventory_approved%');\n const unapprovedItemsText = localizeString(localizedStrings, '%webView_inventory_unapproved%');\n const unknownItemsText = localizeString(localizedStrings, '%webView_inventory_unknown%');\n const scopeBookText = localizeString(localizedStrings, '%webView_inventory_scope_currentBook%');\n const scopeChapterText = localizeString(localizedStrings, '%webView_inventory_scope_chapter%');\n const scopeVerseText = localizeString(localizedStrings, '%webView_inventory_scope_verse%');\n const filterText = localizeString(localizedStrings, '%webView_inventory_filter_text%');\n const showAdditionalItemsText = localizeString(\n localizedStrings,\n '%webView_inventory_show_additional_items%',\n );\n\n const [showAdditionalItems, setShowAdditionalItems] = useState(false);\n const [statusFilter, setStatusFilter] = useState('all');\n const [textFilter, setTextFilter] = useState('');\n const [selectedItem, setSelectedItem] = useState([]);\n\n const tableData: InventoryTableData[] = useMemo(() => {\n if (!text) return [];\n if (extractItems instanceof RegExp)\n return createTableData(\n text,\n scriptureReference,\n approvedItems,\n unapprovedItems,\n extractItems,\n );\n return extractItems(text, scriptureReference, approvedItems, unapprovedItems);\n }, [text, extractItems, scriptureReference, approvedItems, unapprovedItems]);\n\n const reducedTableData: InventoryTableData[] = useMemo(() => {\n if (showAdditionalItems) return tableData;\n\n const newTableData: InventoryTableData[] = [];\n\n tableData.forEach((tableEntry) => {\n const firstItem = tableEntry.items[0];\n\n const existingEntry = newTableData.find(\n (newTableEntry) => newTableEntry.items[0] === firstItem,\n );\n\n if (existingEntry) {\n existingEntry.count += tableEntry.count;\n existingEntry.occurrences = existingEntry.occurrences.concat(tableEntry.occurrences);\n } else {\n newTableData.push({\n items: [firstItem],\n count: tableEntry.count,\n occurrences: tableEntry.occurrences,\n status: tableEntry.status,\n });\n }\n });\n\n return newTableData;\n }, [showAdditionalItems, tableData]);\n\n const filteredTableData: InventoryTableData[] = useMemo(() => {\n return filterItemData(reducedTableData, statusFilter, textFilter);\n }, [reducedTableData, statusFilter, textFilter]);\n\n const allColumns: ColumnDef[] = useMemo(() => {\n if (!showAdditionalItems) return columns;\n\n const numberOfAdditionalItems = additionalItemsLabels?.tableHeaders?.length;\n if (!numberOfAdditionalItems) return columns;\n\n const additionalColumns: ColumnDef[] = [];\n\n for (let index = 0; index < numberOfAdditionalItems; index++) {\n additionalColumns.push(\n inventoryAdditionalItemColumn(\n additionalItemsLabels?.tableHeaders?.[index] || 'Additional Item',\n index + 1,\n ),\n );\n }\n\n return [...additionalColumns, ...columns];\n }, [additionalItemsLabels?.tableHeaders, columns, showAdditionalItems]);\n\n useEffect(() => {\n setSelectedItem([]);\n }, [filteredTableData]);\n\n const rowClickHandler = (\n row: RowContents,\n table: TableContents,\n ) => {\n table.setRowSelection(() => {\n const newSelection: RowSelectionState = {};\n newSelection[row.index] = true;\n return newSelection;\n });\n\n setSelectedItem(row.original.items);\n };\n\n const handleScopeChange = (value: string) => {\n if (value === 'book' || value === 'chapter' || value === 'verse') {\n onScopeChange(value);\n } else {\n throw new Error(`Invalid scope value: ${value}`);\n }\n };\n\n const handleStatusFilterChange = (value: string) => {\n if (value === 'all' || value === 'approved' || value === 'unapproved' || value === 'unknown') {\n setStatusFilter(value);\n } else {\n throw new Error(`Invalid status filter value: ${value}`);\n }\n };\n\n const occurrenceData: InventoryItemOccurrence[] = useMemo(() => {\n if (reducedTableData.length === 0 || selectedItem.length === 0) return [];\n const occurrence = reducedTableData.filter((tableEntry: InventoryTableData) => {\n return deepEqual(\n showAdditionalItems ? tableEntry.items : [tableEntry.items[0]],\n selectedItem,\n );\n });\n if (occurrence.length > 1) throw new Error('Selected item is not unique');\n return occurrence[0].occurrences;\n }, [selectedItem, showAdditionalItems, reducedTableData]);\n\n return (\n
    \n
    \n handleStatusFilterChange(value)}\n defaultValue={statusFilter}\n >\n \n \n \n \n {allItemsText}\n {approvedItemsText}\n {unapprovedItemsText}\n {unknownItemsText}\n \n \n \n {\n setTextFilter(event.target.value);\n }}\n />\n {additionalItemsLabels && (\n
    \n {\n setSelectedItem([]);\n setShowAdditionalItems(checked);\n }}\n />\n \n
    \n )}\n
    \n
    \n \n
    \n {occurrenceData.length > 0 && (\n
    \n \n
    \n )}\n
    \n );\n}\n","import { Input } from '@/components/shadcn-ui/input';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { useState } from 'react';\n\nexport type SearchBarProps = {\n className?: string;\n /**\n * Callback fired to handle the search query when button pressed\n *\n * @param searchQuery\n */\n onSearch: (searchQuery: string) => void;\n\n /** Optional string that appears in the search bar without a search string */\n placeholder?: string;\n\n /** Optional boolean to set the input base to full width */\n isFullWidth?: boolean;\n};\n\nexport default function SearchBar({\n className,\n onSearch,\n placeholder,\n isFullWidth,\n}: SearchBarProps) {\n const [searchQuery, setSearchQuery] = useState('');\n\n const handleInputChange = (searchString: string) => {\n setSearchQuery(searchString);\n onSearch(searchString);\n };\n\n return (\n handleInputChange(e.target.value)}\n />\n );\n}\n","// adapted from: https://github.com/shadcn-ui/ui/discussions/752\n\n'use client';\n\nimport { TabsContentProps, TabsListProps, TabsTriggerProps } from '@/components/shadcn-ui/tabs';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport * as TabsPrimitive from '@radix-ui/react-tabs';\nimport React from 'react';\n\nexport type VerticalTabsProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport type LeftTabsTriggerProps = TabsTriggerProps & {\n value: string;\n ref?: React.Ref;\n};\n\nexport const VerticalTabs = React.forwardRef<\n React.ElementRef,\n VerticalTabsProps\n>(({ className, ...props }, ref) => (\n \n));\n\nVerticalTabs.displayName = TabsPrimitive.List.displayName;\n\nexport const VerticalTabsList = React.forwardRef<\n React.ElementRef,\n TabsListProps\n>(({ className, ...props }, ref) => (\n \n));\nVerticalTabsList.displayName = TabsPrimitive.List.displayName;\n\nexport const VerticalTabsTrigger = React.forwardRef<\n React.ElementRef,\n LeftTabsTriggerProps\n>(({ className, ...props }, ref) => (\n \n));\n\nexport const VerticalTabsContent = React.forwardRef<\n React.ElementRef,\n TabsContentProps\n>(({ className, ...props }, ref) => (\n \n));\nVerticalTabsContent.displayName = TabsPrimitive.Content.displayName;\n","import SearchBar from '@/components/basics/search-bar.component';\nimport {\n VerticalTabs,\n VerticalTabsContent,\n VerticalTabsList,\n VerticalTabsTrigger,\n} from '@/components/basics/tabs-vertical';\nimport { ReactNode } from 'react';\n\nexport type TabKeyValueContent = {\n key: string;\n value: string;\n content: ReactNode;\n};\n\nexport type TabNavigationContentSearchProps = {\n /** List of values and keys for each tab this component should provide */\n tabList: TabKeyValueContent[];\n\n /** Handler to run when the value of the search bar changes */\n onSearch: (searchQuery: string) => void;\n\n /** Optional placeholder for the search bar */\n searchPlaceholder?: string;\n\n /** Optional title to include in the header */\n headerTitle?: string;\n\n /** Optional flag to make the search bar appear full width */\n isSearchBarFullWidth?: boolean;\n\n /** Text direction ltr or rtl */\n direction?: 'ltr' | 'rtl';\n};\n\nexport default function TabNavigationContentSearch({\n tabList,\n onSearch,\n searchPlaceholder,\n headerTitle,\n isSearchBarFullWidth = false,\n direction = 'ltr',\n}: TabNavigationContentSearchProps) {\n return (\n
    \n
    \n {headerTitle ?

    {headerTitle}

    : ''}\n \n
    \n \n \n {tabList.map((tab) => (\n \n {tab.value}\n \n ))}\n \n {tabList.map((tab) => (\n \n {tab.content}\n \n ))}\n \n
    \n );\n}\n","import React from 'react';\nimport * as SeparatorPrimitive from '@radix-ui/react-separator';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Separator = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, orientation = 'horizontal', decorative = true, ...props }, ref) => (\n \n));\nSeparator.displayName = SeparatorPrimitive.Root.displayName;\n\nexport { Separator };\n","'use client';\n\nimport * as React from 'react';\nimport * as SheetPrimitive from '@radix-ui/react-dialog';\nimport { cva, type VariantProps } from 'class-variance-authority';\nimport { X } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Sheet = SheetPrimitive.Root;\n\nconst SheetTrigger = SheetPrimitive.Trigger;\n\nconst SheetClose = SheetPrimitive.Close;\n\nconst SheetPortal = SheetPrimitive.Portal;\n\nconst SheetOverlay = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSheetOverlay.displayName = SheetPrimitive.Overlay.displayName;\n\nconst sheetVariants = cva(\n 'pr-twp tw-fixed tw-z-50 tw-gap-4 tw-bg-background tw-p-6 tw-shadow-lg tw-transition tw-ease-in-out data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-duration-300 data-[state=open]:tw-duration-500',\n {\n variants: {\n side: {\n top: 'tw-inset-x-0 tw-top-0 tw-border-b data-[state=closed]:tw-slide-out-to-top data-[state=open]:tw-slide-in-from-top',\n bottom:\n 'tw-inset-x-0 tw-bottom-0 tw-border-t data-[state=closed]:tw-slide-out-to-bottom data-[state=open]:tw-slide-in-from-bottom',\n left: 'tw-inset-y-0 tw-left-0 tw-h-full tw-w-3/4 tw-border-r data-[state=closed]:tw-slide-out-to-left data-[state=open]:tw-slide-in-from-left sm:tw-max-w-sm',\n right:\n 'tw-inset-y-0 tw-right-0 tw-h-full tw-w-3/4 tw- tw-border-l data-[state=closed]:tw-slide-out-to-right data-[state=open]:tw-slide-in-from-right sm:tw-max-w-sm',\n },\n },\n defaultVariants: {\n side: 'right',\n },\n },\n);\n\ninterface SheetContentProps\n extends React.ComponentPropsWithoutRef,\n VariantProps {}\n\nconst SheetContent = React.forwardRef<\n React.ElementRef,\n SheetContentProps\n>(({ side = 'right', className, children, ...props }, ref) => (\n \n \n \n {children}\n \n \n Close\n \n \n \n));\nSheetContent.displayName = SheetPrimitive.Content.displayName;\n\nfunction SheetHeader({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nSheetHeader.displayName = 'SheetHeader';\n\nfunction SheetFooter({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nSheetFooter.displayName = 'SheetFooter';\n\nconst SheetTitle = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSheetTitle.displayName = SheetPrimitive.Title.displayName;\n\nconst SheetDescription = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSheetDescription.displayName = SheetPrimitive.Description.displayName;\n\nexport {\n Sheet,\n SheetPortal,\n SheetOverlay,\n SheetTrigger,\n SheetClose,\n SheetContent,\n SheetHeader,\n SheetFooter,\n SheetTitle,\n SheetDescription,\n};\n","import React from 'react';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nfunction Skeleton({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\n\nexport { Skeleton };\n","import React from 'react';\nimport * as TooltipPrimitive from '@radix-ui/react-tooltip';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst TooltipProvider = TooltipPrimitive.Provider;\n\nconst Tooltip = TooltipPrimitive.Root;\n\nconst TooltipTrigger = TooltipPrimitive.Trigger;\n\nconst TooltipContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, sideOffset = 4, ...props }, ref) => (\n \n));\nTooltipContent.displayName = TooltipPrimitive.Content.displayName;\n\nexport { Tooltip, TooltipTrigger, TooltipContent, TooltipProvider };\n","import * as React from 'react';\n\nconst MOBILE_BREAKPOINT = 768;\n\nexport default function useIsMobile() {\n const [isMobile, setIsMobile] = React.useState(undefined);\n\n React.useEffect(() => {\n const mql = window.matchMedia(`(max-width: ${MOBILE_BREAKPOINT - 1}px)`);\n const onChange = () => {\n setIsMobile(window.innerWidth < MOBILE_BREAKPOINT);\n };\n mql.addEventListener('change', onChange);\n setIsMobile(window.innerWidth < MOBILE_BREAKPOINT);\n return () => mql.removeEventListener('change', onChange);\n }, []);\n\n return !!isMobile;\n}\n","import React from 'react';\nimport { Slot } from '@radix-ui/react-slot';\nimport { VariantProps, cva } from 'class-variance-authority';\nimport { PanelLeft } from 'lucide-react';\n\nimport { Button } from '@/components/shadcn-ui/button';\nimport { Input } from '@/components/shadcn-ui/input';\nimport { Separator } from '@/components/shadcn-ui/separator';\nimport { Sheet, SheetContent } from '@/components/shadcn-ui/sheet';\nimport { Skeleton } from '@/components/shadcn-ui/skeleton';\nimport {\n Tooltip,\n TooltipContent,\n TooltipProvider,\n TooltipTrigger,\n} from '@/components/shadcn-ui/tooltip';\nimport useIsMobile from '@/components/hooks/use-mobile';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst SIDEBAR_COOKIE_NAME = 'sidebar:state';\nconst SIDEBAR_COOKIE_MAX_AGE = 60 * 60 * 24 * 7;\nconst SIDEBAR_WIDTH = '16rem';\nconst SIDEBAR_WIDTH_MOBILE = '18rem';\nconst SIDEBAR_WIDTH_ICON = '3rem';\nconst SIDEBAR_KEYBOARD_SHORTCUT = 'b';\n\ntype SidebarContextProps = {\n state: 'expanded' | 'collapsed';\n open: boolean;\n setOpen: (open: boolean) => void;\n openMobile: boolean;\n setOpenMobile: (open: boolean) => void;\n isMobile: boolean;\n toggleSidebar: () => void;\n};\n\nconst SidebarContext = React.createContext(undefined);\n\nfunction useSidebar() {\n const context = React.useContext(SidebarContext);\n if (!context) {\n throw new Error('useSidebar must be used within a SidebarProvider.');\n }\n\n return context;\n}\n\nconst SidebarProvider = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & {\n defaultOpen?: boolean;\n open?: boolean;\n onOpenChange?: (open: boolean) => void;\n }\n>(\n (\n {\n defaultOpen = true,\n open: openProp,\n onOpenChange: setOpenProp,\n className,\n style,\n children,\n ...props\n },\n ref,\n ) => {\n const isMobile = useIsMobile();\n const [openMobile, setOpenMobile] = React.useState(false);\n\n // This is the internal state of the sidebar.\n // We use openProp and setOpenProp for control from outside the component.\n const [_open, _setOpen] = React.useState(defaultOpen);\n const isOpen = openProp ?? _open;\n const setOpen = React.useCallback(\n (value: boolean | ((value: boolean) => boolean)) => {\n const openState = typeof value === 'function' ? value(isOpen) : value;\n if (setOpenProp) {\n setOpenProp(openState);\n } else {\n _setOpen(openState);\n }\n\n // This sets the cookie to keep the sidebar state.\n document.cookie = `${SIDEBAR_COOKIE_NAME}=${openState}; path=/; max-age=${SIDEBAR_COOKIE_MAX_AGE}`;\n },\n [setOpenProp, isOpen],\n );\n\n // Helper to toggle the sidebar.\n const toggleSidebar = React.useCallback(() => {\n return isMobile ? setOpenMobile((open) => !open) : setOpen((open) => !open);\n }, [isMobile, setOpen, setOpenMobile]);\n\n // Adds a keyboard shortcut to toggle the sidebar.\n React.useEffect(() => {\n const handleKeyDown = (event: KeyboardEvent) => {\n if (event.key === SIDEBAR_KEYBOARD_SHORTCUT && (event.metaKey || event.ctrlKey)) {\n event.preventDefault();\n toggleSidebar();\n }\n };\n\n window.addEventListener('keydown', handleKeyDown);\n return () => window.removeEventListener('keydown', handleKeyDown);\n }, [toggleSidebar]);\n\n // We add a state so that we can do data-state=\"expanded\" or \"collapsed\".\n // This makes it easier to style the sidebar with Tailwind classes.\n const state = isOpen ? 'expanded' : 'collapsed';\n\n const contextValue = React.useMemo(\n () => ({\n state,\n open: isOpen,\n setOpen,\n isMobile,\n openMobile,\n setOpenMobile,\n toggleSidebar,\n }),\n [state, isOpen, setOpen, isMobile, openMobile, setOpenMobile, toggleSidebar],\n );\n\n return (\n \n \n \n {children}\n
    \n \n \n );\n },\n);\nSidebarProvider.displayName = 'SidebarProvider';\n\nconst Sidebar = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & {\n side?: 'left' | 'right';\n variant?: 'sidebar' | 'floating' | 'inset';\n collapsible?: 'offcanvas' | 'icon' | 'none';\n }\n>(\n (\n {\n side = 'left',\n variant = 'sidebar',\n collapsible = 'offcanvas',\n className,\n children,\n ...props\n },\n ref,\n ) => {\n const { isMobile, state, openMobile, setOpenMobile } = useSidebar();\n\n if (collapsible === 'none') {\n return (\n \n {children}\n
    \n );\n }\n\n if (isMobile) {\n return (\n \n button]:tw-hidden\"\n style={\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n {\n '--sidebar-width': SIDEBAR_WIDTH_MOBILE,\n } as React.CSSProperties\n }\n side={side}\n >\n
    {children}
    \n \n
    \n );\n }\n\n return (\n \n {/* This is what handles the sidebar gap on desktop */}\n \n \n \n {children}\n
    \n
    \n
    \n );\n },\n);\nSidebar.displayName = 'Sidebar';\n\nconst SidebarTrigger = React.forwardRef<\n React.ElementRef,\n React.ComponentProps\n>(({ className, onClick, ...props }, ref) => {\n const { toggleSidebar } = useSidebar();\n\n return (\n {\n onClick?.(event);\n toggleSidebar();\n }}\n {...props}\n >\n \n Toggle Sidebar\n \n );\n});\nSidebarTrigger.displayName = 'SidebarTrigger';\n\nconst SidebarRail = React.forwardRef>(\n ({ className, ...props }, ref) => {\n const { toggleSidebar } = useSidebar();\n\n return (\n \n );\n },\n);\nSidebarRail.displayName = 'SidebarRail';\n\nconst SidebarInset = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarInset.displayName = 'SidebarInset';\n\nconst SidebarInput = React.forwardRef<\n React.ElementRef,\n React.ComponentProps\n>(({ className, ...props }, ref) => {\n return (\n \n );\n});\nSidebarInput.displayName = 'SidebarInput';\n\nconst SidebarHeader = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarHeader.displayName = 'SidebarHeader';\n\nconst SidebarFooter = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarFooter.displayName = 'SidebarFooter';\n\nconst SidebarSeparator = React.forwardRef<\n React.ElementRef,\n React.ComponentProps\n>(({ className, ...props }, ref) => {\n return (\n \n );\n});\nSidebarSeparator.displayName = 'SidebarSeparator';\n\nconst SidebarContent = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarContent.displayName = 'SidebarContent';\n\nconst SidebarGroup = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarGroup.displayName = 'SidebarGroup';\n\nconst SidebarGroupLabel = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & { asChild?: boolean }\n>(({ className, asChild = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'div';\n\n return (\n svg]:tw-size-4 [&>svg]:tw-shrink-0',\n 'group-data-[collapsible=icon]:tw--mt-8 group-data-[collapsible=icon]:tw-opacity-0',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarGroupLabel.displayName = 'SidebarGroupLabel';\n\nconst SidebarGroupAction = React.forwardRef<\n HTMLButtonElement,\n React.ComponentProps<'button'> & { asChild?: boolean }\n>(({ className, asChild = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'button';\n\n return (\n svg]:tw-size-4 [&>svg]:tw-shrink-0',\n // Increases the hit area of the button on mobile.\n 'after:tw-absolute after:tw--inset-2 after:md:tw-hidden',\n 'group-data-[collapsible=icon]:tw-hidden',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarGroupAction.displayName = 'SidebarGroupAction';\n\nconst SidebarGroupContent = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarGroupContent.displayName = 'SidebarGroupContent';\n\nconst SidebarMenu = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenu.displayName = 'SidebarMenu';\n\nconst SidebarMenuItem = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenuItem.displayName = 'SidebarMenuItem';\n\nconst sidebarMenuButtonVariants = cva(\n // Removed data-[active=true]:tw-bg-sidebar-accent\n 'tw-peer/menu-button tw-flex tw-w-full tw-items-center tw-gap-2 tw-overflow-hidden tw-rounded-md tw-p-2 tw-text-left tw-text-sm tw-outline-none tw-ring-sidebar-ring tw-transition-[width,height,padding] hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground focus-visible:tw-ring-2 active:tw-bg-sidebar-accent active:tw-text-sidebar-accent-foreground disabled:tw-pointer-events-none disabled:tw-opacity-50 tw-group-has-[[data-sidebar=menu-action]]/menu-item:pr-8 aria-disabled:tw-pointer-events-none aria-disabled:tw-opacity-50 data-[active=true]:tw-font-medium data-[active=true]:tw-text-sidebar-accent-foreground data-[state=open]:hover:tw-bg-sidebar-accent data-[state=open]:hover:tw-text-sidebar-accent-foreground group-data-[collapsible=icon]:tw-!size-8 group-data-[collapsible=icon]:tw-!p-2 [&>span:last-child]:tw-truncate [&>svg]:tw-size-4 [&>svg]:tw-shrink-0',\n {\n variants: {\n variant: {\n default: 'hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground',\n outline:\n 'tw-bg-background tw-shadow-[0_0_0_1px_hsl(var(--sidebar-border))] hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground hover:tw-shadow-[0_0_0_1px_hsl(var(--sidebar-accent))]',\n },\n size: {\n default: 'tw-h-8 tw-text-sm',\n sm: 'tw-h-7 tw-text-xs',\n lg: 'tw-h-12 tw-text-sm group-data-[collapsible=icon]:tw-!p-0',\n },\n },\n defaultVariants: {\n variant: 'default',\n size: 'default',\n },\n },\n);\n\nconst SidebarMenuButton = React.forwardRef<\n HTMLButtonElement,\n React.ComponentProps<'button'> & {\n asChild?: boolean;\n isActive?: boolean;\n tooltip?: string | React.ComponentProps;\n } & VariantProps\n>(\n (\n {\n asChild = false,\n isActive = false,\n variant = 'default',\n size = 'default',\n tooltip,\n className,\n ...props\n },\n ref,\n ) => {\n const Comp = asChild ? Slot : 'button';\n const { isMobile, state } = useSidebar();\n\n const button = (\n \n );\n\n if (!tooltip) {\n return button;\n }\n\n if (typeof tooltip === 'string') {\n // eslint-disable-next-line no-param-reassign\n tooltip = {\n children: tooltip,\n };\n }\n\n return (\n \n {button}\n \n );\n },\n);\nSidebarMenuButton.displayName = 'SidebarMenuButton';\n\nconst SidebarMenuAction = React.forwardRef<\n HTMLButtonElement,\n React.ComponentProps<'button'> & {\n asChild?: boolean;\n showOnHover?: boolean;\n }\n>(({ className, asChild = false, showOnHover = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'button';\n\n return (\n svg]:tw-size-4 [&>svg]:tw-shrink-0',\n // Increases the hit area of the button on mobile.\n 'after:tw-absolute after:tw--inset-2 after:md:tw-hidden',\n 'tw-peer-data-[size=sm]/menu-button:top-1',\n 'tw-peer-data-[size=default]/menu-button:top-1.5',\n 'tw-peer-data-[size=lg]/menu-button:top-2.5',\n 'group-data-[collapsible=icon]:tw-hidden',\n showOnHover &&\n 'tw-group-focus-within/menu-item:opacity-100 tw-group-hover/menu-item:opacity-100 tw-peer-data-[active=true]/menu-button:text-sidebar-accent-foreground data-[state=open]:tw-opacity-100 md:tw-opacity-0',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarMenuAction.displayName = 'SidebarMenuAction';\n\nconst SidebarMenuBadge = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenuBadge.displayName = 'SidebarMenuBadge';\n\nconst SidebarMenuSkeleton = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & {\n showIcon?: boolean;\n }\n>(({ className, showIcon = false, ...props }, ref) => {\n // Random width between 50 to 90%.\n const width = React.useMemo(() => {\n return `${Math.floor(Math.random() * 40) + 50}%`;\n }, []);\n\n return (\n \n {showIcon && (\n \n )}\n \n
    \n );\n});\nSidebarMenuSkeleton.displayName = 'SidebarMenuSkeleton';\n\nconst SidebarMenuSub = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenuSub.displayName = 'SidebarMenuSub';\n\nconst SidebarMenuSubItem = React.forwardRef>(\n ({ ...props }, ref) =>
  • ,\n);\nSidebarMenuSubItem.displayName = 'SidebarMenuSubItem';\n\nconst SidebarMenuSubButton = React.forwardRef<\n HTMLAnchorElement,\n React.ComponentProps<'a'> & {\n asChild?: boolean;\n size?: 'sm' | 'md';\n isActive?: boolean;\n }\n>(({ asChild = false, size = 'md', isActive, className, ...props }, ref) => {\n const Comp = asChild ? Slot : 'a';\n\n return (\n span:last-child]:tw-truncate [&>svg]:tw-size-4 [&>svg]:tw-shrink-0 [&>svg]:tw-text-sidebar-accent-foreground',\n 'data-[active=true]:tw-bg-sidebar-accent data-[active=true]:tw-text-sidebar-accent-foreground',\n size === 'sm' && 'tw-text-xs',\n size === 'md' && 'tw-text-sm',\n 'group-data-[collapsible=icon]:tw-hidden',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarMenuSubButton.displayName = 'SidebarMenuSubButton';\n\nexport {\n Sidebar,\n SidebarContent,\n SidebarFooter,\n SidebarGroup,\n SidebarGroupAction,\n SidebarGroupContent,\n SidebarGroupLabel,\n SidebarHeader,\n SidebarInput,\n SidebarInset,\n SidebarMenu,\n SidebarMenuAction,\n SidebarMenuBadge,\n SidebarMenuButton,\n SidebarMenuItem,\n SidebarMenuSkeleton,\n SidebarMenuSub,\n SidebarMenuSubButton,\n SidebarMenuSubItem,\n SidebarProvider,\n SidebarRail,\n SidebarSeparator,\n SidebarTrigger,\n useSidebar,\n};\n","import ComboBox, { ComboBoxOption } from '@/components/basics/combo-box.component';\nimport {\n Sidebar,\n SidebarContent,\n SidebarGroup,\n SidebarGroupLabel,\n SidebarGroupContent,\n SidebarMenu,\n SidebarMenuItem,\n SidebarMenuButton,\n} from '@/components/shadcn-ui/sidebar';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { useCallback } from 'react';\n\nexport type SelectedSettingsSidebarItem = {\n label: string;\n projectId?: string;\n};\n\nexport type ProjectOptions = { projectId: string; projectName: string };\n\nexport type SettingsSidebarProps = {\n /** Optional id for testing */\n id?: string;\n\n /** Extension labels from contribution */\n extensionLabels: string[];\n\n /** Project names and ids */\n projectOptions: ProjectOptions[];\n\n /** Handler for selecting a sidebar item */\n handleSelectSidebarItem: (key: string, projectId?: string) => void;\n\n /** The current selected value in the sidebar */\n selectedSidebarItem: SelectedSettingsSidebarItem;\n\n /** Label for the group of extensions setting groups */\n extensionsSidebarGroupLabel: string;\n\n /** Label for the group of projects settings */\n projectsSidebarGroupLabel: string;\n\n /** Placeholder for the button */\n buttonPlaceholder: string;\n};\n\nexport default function SettingsSidebar({\n id,\n extensionLabels,\n projectOptions,\n handleSelectSidebarItem,\n selectedSidebarItem,\n extensionsSidebarGroupLabel,\n projectsSidebarGroupLabel,\n buttonPlaceholder,\n}: SettingsSidebarProps) {\n const handleSelectItem = useCallback(\n (item: string, projectId?: string) => {\n handleSelectSidebarItem(item, projectId);\n },\n [handleSelectSidebarItem],\n );\n\n const getProjectNameFromProjectId = useCallback(\n (projectId: string) => {\n const project = projectOptions.find((option) => option.projectId === projectId);\n return project ? project.projectName : projectId;\n },\n [projectOptions],\n );\n\n const getIsActive: (label: string) => boolean = useCallback(\n (label: string) => !selectedSidebarItem.projectId && label === selectedSidebarItem.label,\n [selectedSidebarItem],\n );\n\n return (\n \n \n \n \n {extensionsSidebarGroupLabel}\n \n \n \n {extensionLabels.map((label) => (\n \n handleSelectItem(label, undefined)}\n isActive={getIsActive(label)}\n >\n {label}\n \n \n ))}\n \n \n \n \n \n {projectsSidebarGroupLabel}\n \n \n option.projectId)}\n getOptionLabel={(projectId: ComboBoxOption) => {\n // This function expects a ComboBoxOption, but we know it is a string\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n return getProjectNameFromProjectId(projectId as string);\n }}\n buttonPlaceholder={buttonPlaceholder}\n onChange={(projectId: string) => {\n const selectedProjectName = getProjectNameFromProjectId(projectId);\n handleSelectItem(selectedProjectName, projectId);\n }}\n value={selectedSidebarItem?.projectId ?? undefined}\n />\n \n \n \n \n );\n}\n","import { SidebarInset, SidebarProvider } from '@/components/shadcn-ui/sidebar';\nimport { PropsWithChildren } from 'react';\nimport SearchBar from '@/components/basics/search-bar.component';\nimport SettingsSidebar, { SettingsSidebarProps } from './settings-sidebar.component';\n\nexport type SettingsSidebarContentSearchProps = SettingsSidebarProps &\n PropsWithChildren & {\n /** Optional id for testing */\n id?: string;\n\n /** Text direction ltr or rtl */\n direction?: 'ltr' | 'rtl';\n\n /** Handler to run when the value of the search bar changes */\n onSearch: (searchQuery: string) => void;\n };\n\nexport default function SettingsSidebarContentSearch({\n id,\n direction = 'ltr',\n extensionLabels,\n projectOptions,\n children,\n handleSelectSidebarItem,\n selectedSidebarItem,\n onSearch,\n extensionsSidebarGroupLabel,\n projectsSidebarGroupLabel,\n buttonPlaceholder,\n}: SettingsSidebarContentSearchProps) {\n return (\n
    \n
    \n \n
    \n \n \n {children}\n \n
    \n );\n}\n","import { Button } from '@/components/shadcn-ui/button';\nimport {\n Select,\n SelectContent,\n SelectGroup,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\nimport {\n Table,\n TableBody,\n TableCell,\n TableHead,\n TableHeader,\n TableRow,\n} from '@/components/shadcn-ui/table';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Canon } from '@sillsdev/scripture';\nimport {\n Cell,\n ColumnDef,\n flexRender,\n getCoreRowModel,\n getExpandedRowModel,\n getGroupedRowModel,\n getSortedRowModel,\n GroupingState,\n Row,\n RowSelectionState,\n SortingState,\n useReactTable,\n} from '@tanstack/react-table';\nimport '@/components/advanced/scripture-results-viewer/scripture-results-viewer.component.css';\nimport {\n compareScrRefs,\n formatScrRef,\n ScriptureSelection,\n scrRefToBBBCCCVVV,\n} from 'platform-bible-utils';\nimport { MouseEvent, useEffect, useMemo, useState } from 'react';\nimport { ChevronDown, ChevronLeft, ChevronRight } from 'lucide-react';\n\n/**\n * Information (e.g., a checking error or some other type of \"transient\" annotation) about something\n * noteworthy at a specific place in an instance of the Scriptures.\n */\nexport type ScriptureItemDetail = ScriptureSelection & {\n /**\n * Text of the error, note, etc. In the future, we might want to support something more than just\n * text so that a JSX element could be provided with a link or some other controls related to the\n * issue being reported.\n */\n detail: string;\n};\n\n/**\n * A uniquely identifiable source of results that can be displayed in the ScriptureResultsViewer.\n * Generally, the source will be a particular Scripture check, but there may be other types of\n * sources.\n */\nexport type ResultsSource = {\n /**\n * Uniquely identifies the source.\n *\n * @type {string}\n */\n id: string;\n\n /**\n * Name (potentially localized) of the source, suitable for display in the UI.\n *\n * @type {string}\n */\n displayName: string;\n};\n\nexport type ScriptureSrcItemDetail = ScriptureItemDetail & {\n /** Source/type of detail. Can be used for grouping. */\n source: ResultsSource;\n};\n\n/**\n * Represents a set of results keyed by Scripture reference. Generally, the source will be a\n * particular Scripture check, but this type also allows for other types of uniquely identifiable\n * sources.\n */\nexport type ResultsSet = {\n /**\n * The backing source associated with this set of results.\n *\n * @type {ResultsSource}\n */\n source: ResultsSource;\n\n /**\n * Array of Scripture item details (messages keyed by Scripture reference).\n *\n * @type {ScriptureItemDetail[]}\n */\n data: ScriptureItemDetail[];\n};\n\nconst scrBookColId = 'scrBook';\nconst scrRefColId = 'scrRef';\nconst typeColId = 'source';\nconst detailsColId = 'details';\n\nconst defaultScrRefColumnName = 'Scripture Reference';\nconst defaultScrBookGroupName = 'Scripture Book';\nconst defaultTypeColumnName = 'Type';\nconst defaultDetailsColumnName = 'Details';\n\nexport type ScriptureResultsViewerColumnInfo = {\n /** Optional header to display for the Reference column. Default value: 'Scripture Reference'. */\n scriptureReferenceColumnName?: string;\n\n /** Optional text to display to refer to the Scripture book group. Default value: 'Scripture Book'. */\n scriptureBookGroupName?: string;\n\n /** Optional header to display for the Type column. Default value: 'Type'. */\n typeColumnName?: string;\n\n /** Optional header to display for the Details column. Default value: 'Details' */\n detailsColumnName?: string;\n};\n\nexport type ScriptureResultsViewerProps = ScriptureResultsViewerColumnInfo & {\n /** Groups of ScriptureItemDetail objects from particular sources (e.g., Scripture checks) */\n sources: ResultsSet[];\n\n /** Flag indicating whether to display column headers. Default is false. */\n showColumnHeaders?: boolean;\n\n /** Flag indicating whether to display source column. Default is false. */\n showSourceColumn?: boolean;\n\n /** Callback function to notify when a row is selected */\n onRowSelected?: (selectedRow: ScriptureSrcItemDetail | undefined) => void;\n\n /** Text direction ltr or rtl */\n direction?: 'ltr' | 'rtl';\n};\n\nfunction getColumns(\n colInfo?: ScriptureResultsViewerColumnInfo,\n showSourceColumn?: boolean,\n): ColumnDef[] {\n const showSrcCol = showSourceColumn ?? false;\n return [\n {\n accessorFn: (row) =>\n `${Canon.bookNumberToId(row.start.bookNum)} ${row.start.chapterNum}:${row.start.verseNum}`,\n id: scrBookColId,\n header: colInfo?.scriptureReferenceColumnName ?? defaultScrRefColumnName,\n cell: (info) => {\n const row = info.row.original;\n if (info.row.getIsGrouped()) {\n return Canon.bookNumberToEnglishName(row.start.bookNum);\n }\n return info.row.groupingColumnId === scrBookColId ? formatScrRef(row.start) : undefined;\n },\n getGroupingValue: (row) => row.start.bookNum,\n sortingFn: (a, b) => {\n return compareScrRefs(a.original.start, b.original.start);\n },\n enableGrouping: true,\n },\n {\n accessorFn: (row) => formatScrRef(row.start),\n id: scrRefColId,\n header: undefined,\n cell: (info) => {\n const row = info.row.original;\n return info.row.getIsGrouped() ? undefined : formatScrRef(row.start);\n },\n sortingFn: (a, b) => {\n return compareScrRefs(a.original.start, b.original.start);\n },\n enableGrouping: false,\n },\n {\n accessorFn: (row) => row.source.displayName,\n id: typeColId,\n header: showSrcCol ? (colInfo?.typeColumnName ?? defaultTypeColumnName) : undefined,\n cell: (info) => (showSrcCol || info.row.getIsGrouped() ? info.getValue() : undefined),\n getGroupingValue: (row) => row.source.id,\n sortingFn: (a, b) =>\n a.original.source.displayName.localeCompare(b.original.source.displayName),\n enableGrouping: true,\n },\n {\n accessorFn: (row) => row.detail,\n id: detailsColId,\n header: colInfo?.detailsColumnName ?? defaultDetailsColumnName,\n cell: (info) => info.getValue(),\n enableGrouping: false,\n },\n ];\n}\n\nconst toRefOrRange = (scriptureSelection: ScriptureSelection) => {\n if (!('offset' in scriptureSelection.start))\n throw new Error('No offset available in range start');\n if (scriptureSelection.end && !('offset' in scriptureSelection.end))\n throw new Error('No offset available in range end');\n const { offset: offsetStart } = scriptureSelection.start;\n let offsetEnd: number = 0;\n if (scriptureSelection.end) ({ offset: offsetEnd } = scriptureSelection.end);\n if (\n !scriptureSelection.end ||\n compareScrRefs(scriptureSelection.start, scriptureSelection.end) === 0\n )\n return `${scrRefToBBBCCCVVV(scriptureSelection.start)}+${offsetStart}`;\n return `${scrRefToBBBCCCVVV(scriptureSelection.start)}+${offsetStart}-${scrRefToBBBCCCVVV(scriptureSelection.end)}+${offsetEnd}`;\n};\n\nconst getRowKey = (row: ScriptureSrcItemDetail) =>\n `${toRefOrRange({ start: row.start, end: row.end })} ${row.source.displayName} ${row.detail}`;\n\n/**\n * Component to display a combined list of detailed items from one or more sources, where the items\n * are keyed primarily by Scripture reference. This is particularly useful for displaying a list of\n * results from Scripture checks, but more generally could be used to display any \"results\" from any\n * source(s). The component allows for grouping by Scripture book, source, or both. By default, it\n * displays somewhat \"tree-like\" which allows it to be more horizontally compact and intuitive. But\n * it also has the option of displaying as a traditional table with column headings (with or without\n * the source column showing).\n */\nexport default function ScriptureResultsViewer({\n sources,\n showColumnHeaders = false,\n showSourceColumn = false,\n scriptureReferenceColumnName,\n scriptureBookGroupName,\n typeColumnName,\n detailsColumnName,\n onRowSelected,\n direction = 'ltr',\n}: ScriptureResultsViewerProps) {\n const [grouping, setGrouping] = useState([]);\n const [sorting, setSorting] = useState([{ id: scrBookColId, desc: false }]);\n const [rowSelection, setRowSelection] = useState({});\n\n const scriptureResults = useMemo(\n () =>\n sources.flatMap((source) => {\n return source.data.map((item) => ({\n ...item,\n source: source.source,\n }));\n }),\n [sources],\n );\n\n const columns = useMemo(\n () =>\n getColumns(\n {\n scriptureReferenceColumnName,\n typeColumnName,\n detailsColumnName,\n },\n showSourceColumn,\n ),\n [scriptureReferenceColumnName, typeColumnName, detailsColumnName, showSourceColumn],\n );\n\n useEffect(() => {\n // Ensure sorting is applied correctly when grouped by type\n if (grouping.includes(typeColId)) {\n setSorting([\n { id: typeColId, desc: false },\n { id: scrBookColId, desc: false },\n ]);\n } else {\n setSorting([{ id: scrBookColId, desc: false }]);\n }\n }, [grouping]);\n\n const table = useReactTable({\n data: scriptureResults,\n columns,\n state: {\n grouping,\n sorting,\n rowSelection,\n },\n onGroupingChange: setGrouping,\n onSortingChange: setSorting,\n onRowSelectionChange: setRowSelection,\n getExpandedRowModel: getExpandedRowModel(),\n getGroupedRowModel: getGroupedRowModel(),\n getCoreRowModel: getCoreRowModel(),\n getSortedRowModel: getSortedRowModel(),\n getRowId: getRowKey,\n autoResetExpanded: false,\n enableMultiRowSelection: false,\n enableSubRowSelection: false,\n });\n\n useEffect(() => {\n if (onRowSelected) {\n const selectedRows = table.getSelectedRowModel().rowsById;\n const keys = Object.keys(selectedRows);\n if (keys.length === 1) {\n const selectedRow = scriptureResults.find((row) => getRowKey(row) === keys[0]) || undefined;\n if (selectedRow) onRowSelected(selectedRow);\n }\n }\n }, [rowSelection, scriptureResults, onRowSelected, table]);\n\n // Define possible grouping options\n const scrBookGroupName = scriptureBookGroupName ?? defaultScrBookGroupName;\n const typeGroupName = typeColumnName ?? defaultTypeColumnName;\n\n const groupingOptions = [\n { label: 'No Grouping', value: [] },\n { label: `Group by ${scrBookGroupName}`, value: [scrBookColId] },\n { label: `Group by ${typeGroupName}`, value: [typeColId] },\n {\n label: `Group by ${scrBookGroupName} and ${typeGroupName}`,\n value: [scrBookColId, typeColId],\n },\n {\n label: `Group by ${typeGroupName} and ${scrBookGroupName}`,\n value: [typeColId, scrBookColId],\n },\n ];\n\n const handleSelectChange = (selectedGrouping: string) => {\n setGrouping(JSON.parse(selectedGrouping));\n };\n\n const handleRowClick = (row: Row, event: MouseEvent) => {\n if (!row.getIsGrouped() && !row.getIsSelected()) {\n row.getToggleSelectedHandler()(event);\n }\n };\n\n const getEvenOrOddBandingStyle = (row: Row, index: number) => {\n if (row.getIsGrouped()) return '';\n // UX has now said they don't think they want banding. I'm leaving in the code to\n // set even and odd styles, but there's nothing in the CSS to style them differently.\n // The \"even\" style used to also have tw-bg-neutral-300 (along with even) to create\n // a visual banding effect. That could be added back in if UX changes the decision.\n return cn('banded-row', index % 2 === 0 ? 'even' : 'odd');\n };\n\n const getIndent = (\n groupingState: GroupingState,\n row: Row,\n cell: Cell,\n ) => {\n if (groupingState?.length === 0 || row.depth < cell.column.getGroupedIndex()) return undefined;\n if (row.getIsGrouped()) {\n switch (row.depth) {\n case 1:\n return 'tw-ps-4';\n default:\n return undefined;\n }\n }\n switch (row.depth) {\n case 1:\n return 'tw-ps-8';\n case 2:\n return 'tw-ps-12';\n default:\n return undefined;\n }\n };\n\n return (\n
    \n {!showColumnHeaders && (\n {\n handleSelectChange(value);\n }}\n >\n \n \n \n \n \n {groupingOptions.map((option) => (\n \n {option.label}\n \n ))}\n \n \n \n )}\n \n {showColumnHeaders && (\n \n {table.getHeaderGroups().map((headerGroup) => (\n \n {headerGroup.headers\n .filter((h) => h.column.columnDef.header)\n .map((header) => (\n /* For sticky column headers to work, we probably need to change the default definition of the shadcn Table component. See https://github.com/shadcn-ui/ui/issues/1151 */\n \n {header.isPlaceholder ? undefined : (\n
    \n {header.column.getCanGroup() ? (\n \n {header.column.getIsGrouped() ? `🛑` : `👊 `}\n \n ) : undefined}{' '}\n {flexRender(header.column.columnDef.header, header.getContext())}\n
    \n )}\n
    \n ))}\n
    \n ))}\n
    \n )}\n \n {table.getRowModel().rows.map((row, rowIndex) => {\n return (\n handleRowClick(row, event)}\n >\n {row.getVisibleCells().map((cell) => {\n if (\n cell.getIsPlaceholder() ||\n (cell.column.columnDef.enableGrouping &&\n !cell.getIsGrouped() &&\n (cell.column.columnDef.id !== typeColId || !showSourceColumn))\n )\n return undefined;\n return (\n \n {(() => {\n if (cell.getIsGrouped()) {\n return (\n \n {row.getIsExpanded() && }\n {!row.getIsExpanded() &&\n (direction === 'ltr' ? : )}{' '}\n {flexRender(cell.column.columnDef.cell, cell.getContext())} (\n {row.subRows.length})\n \n );\n }\n\n // if (cell.getIsAggregated()) {\n // flexRender(\n // cell.column.columnDef.aggregatedCell ?? cell.column.columnDef.cell,\n // cell.getContext(),\n // );\n // }\n\n return flexRender(cell.column.columnDef.cell, cell.getContext());\n })()}\n \n );\n })}\n \n );\n })}\n \n
    \n
    \n );\n}\n","import {\n getLocalizeKeyForScrollGroupId,\n LanguageStrings,\n ScrollGroupId,\n} from 'platform-bible-utils';\nimport {\n Select,\n SelectContent,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\n\nconst DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS = {\n [getLocalizeKeyForScrollGroupId('undefined')]: 'Ø',\n [getLocalizeKeyForScrollGroupId(0)]: 'A',\n [getLocalizeKeyForScrollGroupId(1)]: 'B',\n [getLocalizeKeyForScrollGroupId(2)]: 'C',\n [getLocalizeKeyForScrollGroupId(3)]: 'D',\n [getLocalizeKeyForScrollGroupId(4)]: 'E',\n [getLocalizeKeyForScrollGroupId(5)]: 'F',\n [getLocalizeKeyForScrollGroupId(6)]: 'G',\n [getLocalizeKeyForScrollGroupId(7)]: 'H',\n [getLocalizeKeyForScrollGroupId(8)]: 'I',\n [getLocalizeKeyForScrollGroupId(9)]: 'J',\n [getLocalizeKeyForScrollGroupId(10)]: 'K',\n [getLocalizeKeyForScrollGroupId(11)]: 'L',\n [getLocalizeKeyForScrollGroupId(12)]: 'M',\n [getLocalizeKeyForScrollGroupId(13)]: 'N',\n [getLocalizeKeyForScrollGroupId(14)]: 'O',\n [getLocalizeKeyForScrollGroupId(15)]: 'P',\n [getLocalizeKeyForScrollGroupId(16)]: 'Q',\n [getLocalizeKeyForScrollGroupId(17)]: 'R',\n [getLocalizeKeyForScrollGroupId(18)]: 'S',\n [getLocalizeKeyForScrollGroupId(19)]: 'T',\n [getLocalizeKeyForScrollGroupId(20)]: 'U',\n [getLocalizeKeyForScrollGroupId(21)]: 'V',\n [getLocalizeKeyForScrollGroupId(22)]: 'W',\n [getLocalizeKeyForScrollGroupId(23)]: 'X',\n [getLocalizeKeyForScrollGroupId(24)]: 'Y',\n [getLocalizeKeyForScrollGroupId(25)]: 'Z',\n};\n\nexport type ScrollGroupSelectorProps = {\n /**\n * List of scroll group ids to show to the user. Either a {@link ScrollGroupId} or `undefined` for\n * no scroll group\n */\n availableScrollGroupIds: (ScrollGroupId | undefined)[];\n /** Currently selected scroll group id. `undefined` for no scroll group */\n scrollGroupId: ScrollGroupId | undefined;\n /** Callback function run when the user tries to change the scroll group id */\n onChangeScrollGroupId: (newScrollGroupId: ScrollGroupId | undefined) => void;\n /**\n * Localized strings to use for displaying scroll group ids. Must be an object whose keys are\n * `getLocalizeKeyForScrollGroupId(scrollGroupId)` for all scroll group ids (and `undefined` if\n * included) in {@link ScrollGroupSelectorProps.availableScrollGroupIds} and whose values are the\n * localized strings to use for those scroll group ids.\n *\n * Defaults to English localizations of English alphabet for scroll groups 0-25 (e.g. 0 is A) and\n * Ø for `undefined`. Will fill in any that are not provided with these English localizations.\n * Also, if any values match the keys, the English localization will be used. This is useful in\n * case you want to pass in a temporary version of the localized strings while your localized\n * strings load.\n *\n * @example\n *\n * ```typescript\n * const myScrollGroupIdLocalizedStrings = {\n * [getLocalizeKeyForScrollGroupId('undefined')]: 'Ø',\n * [getLocalizeKeyForScrollGroupId(0)]: 'A',\n * [getLocalizeKeyForScrollGroupId(1)]: 'B',\n * [getLocalizeKeyForScrollGroupId(2)]: 'C',\n * [getLocalizeKeyForScrollGroupId(3)]: 'D',\n * [getLocalizeKeyForScrollGroupId(4)]: 'E',\n * };\n * ```\n *\n * @example\n *\n * ```tsx\n * const availableScrollGroupIds = [undefined, 0, 1, 2, 3, 4];\n *\n * const localizeKeys = getLocalizeKeysForScrollGroupIds();\n *\n * const [localizedStrings] = useLocalizedStrings(localizeKeys);\n *\n * ...\n *\n * \n * ```\n */\n localizedStrings?: LanguageStrings;\n};\n\n/** Selector component for choosing a scroll group */\nexport default function ScrollGroupSelector({\n availableScrollGroupIds,\n scrollGroupId,\n onChangeScrollGroupId,\n localizedStrings = {},\n}: ScrollGroupSelectorProps) {\n const localizedStringsDefaulted = {\n ...DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS,\n ...Object.fromEntries(\n Object.entries(localizedStrings).map(\n ([localizedStringKey, localizedStringValue]: [string, string]) => [\n localizedStringKey,\n localizedStringKey === localizedStringValue &&\n localizedStringKey in DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS\n ? DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS[localizedStringKey]\n : localizedStringValue,\n ],\n ),\n ),\n };\n return (\n \n onChangeScrollGroupId(\n newScrollGroupString === 'undefined' ? undefined : parseInt(newScrollGroupString, 10),\n )\n }\n >\n \n \n \n \n {availableScrollGroupIds.map((scrollGroupOptionId) => (\n \n {localizedStringsDefaulted[getLocalizeKeyForScrollGroupId(scrollGroupOptionId)]}\n \n ))}\n \n \n );\n}\n","import { PropsWithChildren } from 'react';\nimport { Separator } from '@/components/shadcn-ui/separator';\n\n/** Props for the SettingsList component, currently just children */\ntype SettingsListProps = PropsWithChildren;\n\n/**\n * SettingsList component is a wrapper for list items. Rendered with a formatted div\n *\n * @param children To populate the list with\n * @returns Formatted div encompassing the children\n */\nexport function SettingsList({ children }: SettingsListProps) {\n return
    {children}
    ;\n}\n\n/** Props for SettingsListItem component */\ntype SettingsListItemProps = PropsWithChildren & {\n /** Primary text of the list item */\n primary: string;\n\n /** Optional text of the list item */\n secondary?: string | undefined;\n\n /** Optional boolean to display a message if the children aren't loaded yet. Defaults to false */\n isLoading?: boolean;\n\n /** Optional message to display if isLoading */\n loadingMessage?: string;\n};\n\n/**\n * SettingsListItem component is a common list item. Rendered with a formatted div\n *\n * @param primary Primary text of the list item\n * @param secondary Optional secondary text of the list item\n * @param isLoading Optional, to display a message if the action component isn't generated yet,\n * defaults to false\n * @param children The action component(s) to provide for this item\n * @param loadingMessage Optional, message to display if isLoading\n * @returns Formatted div encompassing the list item content\n */\nexport function SettingsListItem({\n primary,\n secondary,\n children,\n isLoading = false,\n loadingMessage,\n}: SettingsListItemProps) {\n return (\n
    \n
    \n

    {primary}

    \n

    \n {secondary}\n

    \n
    \n\n {isLoading ? (\n

    {loadingMessage}

    \n ) : (\n
    {children}
    \n )}\n
    \n );\n}\n\n/** Props for SettingsListHeader component */\ntype SettingsListHeaderProps = {\n /** The primary text of the list header */\n primary: string;\n\n /** Optional secondary text of the list header */\n secondary?: string | undefined;\n\n /** Optional boolean to include a separator underneath the secondary text. Defaults to false */\n includeSeparator?: boolean;\n};\n\n/**\n * SettingsListHeader component displays text above the list\n *\n * @param primary The primary text of the list header\n * @param secondary Optional secondary text of the list header\n * @param includeSeparator Optional boolean to include a separator underneath the secondary text.\n * Defaults to false\n * @returns Formatted div with list header content\n */\nexport function SettingsListHeader({\n primary,\n secondary,\n includeSeparator = false,\n}: SettingsListHeaderProps) {\n return (\n
    \n
    \n

    {primary}

    \n

    {secondary}

    \n
    \n {includeSeparator ? : ''}\n
    \n );\n}\n","import Checkbox from '@/components/shadcn-ui/checkbox';\nimport { Label } from '@/components/shadcn-ui/label';\n\nexport type ChecklistProps = {\n /** Optional string representing the id attribute of the Checklist */\n id?: string;\n /** Optional string representing CSS class name(s) for styling */\n className?: string;\n /** Array of strings representing the checkable items */\n listItems: string[];\n /** Array of strings representing the checked items */\n selectedListItems: string[];\n /**\n * Function that is called when a checkbox item is selected or deselected\n *\n * @param item The string description for this item\n * @param selected True if selected, false if not selected\n */\n handleSelectListItem: (item: string, selected: boolean) => void;\n\n /**\n * Optional function creates a label for a provided checkable item\n *\n * @param item The item for which a label is to be created\n * @returns A string representing the label text for the checkbox associated with that item\n */\n createLabel?: (item: string) => string;\n};\n\n/** Renders a list of checkboxes. Each checkbox corresponds to an item from the `listItems` array. */\nexport default function Checklist({\n id,\n className,\n listItems,\n selectedListItems,\n handleSelectListItem,\n createLabel,\n}: ChecklistProps) {\n return (\n
    \n {listItems.map((item) => (\n
    \n handleSelectListItem(item, value)}\n />\n \n
    \n ))}\n
    \n );\n}\n","function _interopRequireDefault(obj) {\n return obj && obj.__esModule ? obj : {\n \"default\": obj\n };\n}\nmodule.exports = _interopRequireDefault, module.exports.__esModule = true, module.exports[\"default\"] = module.exports;","export default function chainPropTypes(propType1, propType2) {\n if (process.env.NODE_ENV === 'production') {\n return () => null;\n }\n return function validate(...args) {\n return propType1(...args) || propType2(...args);\n };\n}","export default function _extends() {\n _extends = Object.assign ? Object.assign.bind() : function (target) {\n for (var i = 1; i < arguments.length; i++) {\n var source = arguments[i];\n for (var key in source) {\n if (Object.prototype.hasOwnProperty.call(source, key)) {\n target[key] = source[key];\n }\n }\n }\n return target;\n };\n return _extends.apply(this, arguments);\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\n// https://github.com/sindresorhus/is-plain-obj/blob/main/index.js\nexport function isPlainObject(item) {\n if (typeof item !== 'object' || item === null) {\n return false;\n }\n const prototype = Object.getPrototypeOf(item);\n return (prototype === null || prototype === Object.prototype || Object.getPrototypeOf(prototype) === null) && !(Symbol.toStringTag in item) && !(Symbol.iterator in item);\n}\nfunction deepClone(source) {\n if (!isPlainObject(source)) {\n return source;\n }\n const output = {};\n Object.keys(source).forEach(key => {\n output[key] = deepClone(source[key]);\n });\n return output;\n}\nexport default function deepmerge(target, source, options = {\n clone: true\n}) {\n const output = options.clone ? _extends({}, target) : target;\n if (isPlainObject(target) && isPlainObject(source)) {\n Object.keys(source).forEach(key => {\n // Avoid prototype pollution\n if (key === '__proto__') {\n return;\n }\n if (isPlainObject(source[key]) && key in target && isPlainObject(target[key])) {\n // Since `output` is a clone of `target` and we have narrowed `target` in this block we can cast to the same type.\n output[key] = deepmerge(target[key], source[key], options);\n } else if (options.clone) {\n output[key] = isPlainObject(source[key]) ? deepClone(source[key]) : source[key];\n } else {\n output[key] = source[key];\n }\n });\n }\n return output;\n}","/** @license React v16.13.1\n * react-is.production.min.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';var b=\"function\"===typeof Symbol&&Symbol.for,c=b?Symbol.for(\"react.element\"):60103,d=b?Symbol.for(\"react.portal\"):60106,e=b?Symbol.for(\"react.fragment\"):60107,f=b?Symbol.for(\"react.strict_mode\"):60108,g=b?Symbol.for(\"react.profiler\"):60114,h=b?Symbol.for(\"react.provider\"):60109,k=b?Symbol.for(\"react.context\"):60110,l=b?Symbol.for(\"react.async_mode\"):60111,m=b?Symbol.for(\"react.concurrent_mode\"):60111,n=b?Symbol.for(\"react.forward_ref\"):60112,p=b?Symbol.for(\"react.suspense\"):60113,q=b?\nSymbol.for(\"react.suspense_list\"):60120,r=b?Symbol.for(\"react.memo\"):60115,t=b?Symbol.for(\"react.lazy\"):60116,v=b?Symbol.for(\"react.block\"):60121,w=b?Symbol.for(\"react.fundamental\"):60117,x=b?Symbol.for(\"react.responder\"):60118,y=b?Symbol.for(\"react.scope\"):60119;\nfunction z(a){if(\"object\"===typeof a&&null!==a){var u=a.$$typeof;switch(u){case c:switch(a=a.type,a){case l:case m:case e:case g:case f:case p:return a;default:switch(a=a&&a.$$typeof,a){case k:case n:case t:case r:case h:return a;default:return u}}case d:return u}}}function A(a){return z(a)===m}exports.AsyncMode=l;exports.ConcurrentMode=m;exports.ContextConsumer=k;exports.ContextProvider=h;exports.Element=c;exports.ForwardRef=n;exports.Fragment=e;exports.Lazy=t;exports.Memo=r;exports.Portal=d;\nexports.Profiler=g;exports.StrictMode=f;exports.Suspense=p;exports.isAsyncMode=function(a){return A(a)||z(a)===l};exports.isConcurrentMode=A;exports.isContextConsumer=function(a){return z(a)===k};exports.isContextProvider=function(a){return z(a)===h};exports.isElement=function(a){return\"object\"===typeof a&&null!==a&&a.$$typeof===c};exports.isForwardRef=function(a){return z(a)===n};exports.isFragment=function(a){return z(a)===e};exports.isLazy=function(a){return z(a)===t};\nexports.isMemo=function(a){return z(a)===r};exports.isPortal=function(a){return z(a)===d};exports.isProfiler=function(a){return z(a)===g};exports.isStrictMode=function(a){return z(a)===f};exports.isSuspense=function(a){return z(a)===p};\nexports.isValidElementType=function(a){return\"string\"===typeof a||\"function\"===typeof a||a===e||a===m||a===g||a===f||a===p||a===q||\"object\"===typeof a&&null!==a&&(a.$$typeof===t||a.$$typeof===r||a.$$typeof===h||a.$$typeof===k||a.$$typeof===n||a.$$typeof===w||a.$$typeof===x||a.$$typeof===y||a.$$typeof===v)};exports.typeOf=z;\n","/** @license React v16.13.1\n * react-is.development.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\n\n\nif (process.env.NODE_ENV !== \"production\") {\n (function() {\n'use strict';\n\n// The Symbol used to tag the ReactElement-like types. If there is no native Symbol\n// nor polyfill, then a plain number is used for performance.\nvar hasSymbol = typeof Symbol === 'function' && Symbol.for;\nvar REACT_ELEMENT_TYPE = hasSymbol ? Symbol.for('react.element') : 0xeac7;\nvar REACT_PORTAL_TYPE = hasSymbol ? Symbol.for('react.portal') : 0xeaca;\nvar REACT_FRAGMENT_TYPE = hasSymbol ? Symbol.for('react.fragment') : 0xeacb;\nvar REACT_STRICT_MODE_TYPE = hasSymbol ? Symbol.for('react.strict_mode') : 0xeacc;\nvar REACT_PROFILER_TYPE = hasSymbol ? Symbol.for('react.profiler') : 0xead2;\nvar REACT_PROVIDER_TYPE = hasSymbol ? Symbol.for('react.provider') : 0xeacd;\nvar REACT_CONTEXT_TYPE = hasSymbol ? Symbol.for('react.context') : 0xeace; // TODO: We don't use AsyncMode or ConcurrentMode anymore. They were temporary\n// (unstable) APIs that have been removed. Can we remove the symbols?\n\nvar REACT_ASYNC_MODE_TYPE = hasSymbol ? Symbol.for('react.async_mode') : 0xeacf;\nvar REACT_CONCURRENT_MODE_TYPE = hasSymbol ? Symbol.for('react.concurrent_mode') : 0xeacf;\nvar REACT_FORWARD_REF_TYPE = hasSymbol ? Symbol.for('react.forward_ref') : 0xead0;\nvar REACT_SUSPENSE_TYPE = hasSymbol ? Symbol.for('react.suspense') : 0xead1;\nvar REACT_SUSPENSE_LIST_TYPE = hasSymbol ? Symbol.for('react.suspense_list') : 0xead8;\nvar REACT_MEMO_TYPE = hasSymbol ? Symbol.for('react.memo') : 0xead3;\nvar REACT_LAZY_TYPE = hasSymbol ? Symbol.for('react.lazy') : 0xead4;\nvar REACT_BLOCK_TYPE = hasSymbol ? Symbol.for('react.block') : 0xead9;\nvar REACT_FUNDAMENTAL_TYPE = hasSymbol ? Symbol.for('react.fundamental') : 0xead5;\nvar REACT_RESPONDER_TYPE = hasSymbol ? Symbol.for('react.responder') : 0xead6;\nvar REACT_SCOPE_TYPE = hasSymbol ? Symbol.for('react.scope') : 0xead7;\n\nfunction isValidElementType(type) {\n return typeof type === 'string' || typeof type === 'function' || // Note: its typeof might be other than 'symbol' or 'number' if it's a polyfill.\n type === REACT_FRAGMENT_TYPE || type === REACT_CONCURRENT_MODE_TYPE || type === REACT_PROFILER_TYPE || type === REACT_STRICT_MODE_TYPE || type === REACT_SUSPENSE_TYPE || type === REACT_SUSPENSE_LIST_TYPE || typeof type === 'object' && type !== null && (type.$$typeof === REACT_LAZY_TYPE || type.$$typeof === REACT_MEMO_TYPE || type.$$typeof === REACT_PROVIDER_TYPE || type.$$typeof === REACT_CONTEXT_TYPE || type.$$typeof === REACT_FORWARD_REF_TYPE || type.$$typeof === REACT_FUNDAMENTAL_TYPE || type.$$typeof === REACT_RESPONDER_TYPE || type.$$typeof === REACT_SCOPE_TYPE || type.$$typeof === REACT_BLOCK_TYPE);\n}\n\nfunction typeOf(object) {\n if (typeof object === 'object' && object !== null) {\n var $$typeof = object.$$typeof;\n\n switch ($$typeof) {\n case REACT_ELEMENT_TYPE:\n var type = object.type;\n\n switch (type) {\n case REACT_ASYNC_MODE_TYPE:\n case REACT_CONCURRENT_MODE_TYPE:\n case REACT_FRAGMENT_TYPE:\n case REACT_PROFILER_TYPE:\n case REACT_STRICT_MODE_TYPE:\n case REACT_SUSPENSE_TYPE:\n return type;\n\n default:\n var $$typeofType = type && type.$$typeof;\n\n switch ($$typeofType) {\n case REACT_CONTEXT_TYPE:\n case REACT_FORWARD_REF_TYPE:\n case REACT_LAZY_TYPE:\n case REACT_MEMO_TYPE:\n case REACT_PROVIDER_TYPE:\n return $$typeofType;\n\n default:\n return $$typeof;\n }\n\n }\n\n case REACT_PORTAL_TYPE:\n return $$typeof;\n }\n }\n\n return undefined;\n} // AsyncMode is deprecated along with isAsyncMode\n\nvar AsyncMode = REACT_ASYNC_MODE_TYPE;\nvar ConcurrentMode = REACT_CONCURRENT_MODE_TYPE;\nvar ContextConsumer = REACT_CONTEXT_TYPE;\nvar ContextProvider = REACT_PROVIDER_TYPE;\nvar Element = REACT_ELEMENT_TYPE;\nvar ForwardRef = REACT_FORWARD_REF_TYPE;\nvar Fragment = REACT_FRAGMENT_TYPE;\nvar Lazy = REACT_LAZY_TYPE;\nvar Memo = REACT_MEMO_TYPE;\nvar Portal = REACT_PORTAL_TYPE;\nvar Profiler = REACT_PROFILER_TYPE;\nvar StrictMode = REACT_STRICT_MODE_TYPE;\nvar Suspense = REACT_SUSPENSE_TYPE;\nvar hasWarnedAboutDeprecatedIsAsyncMode = false; // AsyncMode should be deprecated\n\nfunction isAsyncMode(object) {\n {\n if (!hasWarnedAboutDeprecatedIsAsyncMode) {\n hasWarnedAboutDeprecatedIsAsyncMode = true; // Using console['warn'] to evade Babel and ESLint\n\n console['warn']('The ReactIs.isAsyncMode() alias has been deprecated, ' + 'and will be removed in React 17+. Update your code to use ' + 'ReactIs.isConcurrentMode() instead. It has the exact same API.');\n }\n }\n\n return isConcurrentMode(object) || typeOf(object) === REACT_ASYNC_MODE_TYPE;\n}\nfunction isConcurrentMode(object) {\n return typeOf(object) === REACT_CONCURRENT_MODE_TYPE;\n}\nfunction isContextConsumer(object) {\n return typeOf(object) === REACT_CONTEXT_TYPE;\n}\nfunction isContextProvider(object) {\n return typeOf(object) === REACT_PROVIDER_TYPE;\n}\nfunction isElement(object) {\n return typeof object === 'object' && object !== null && object.$$typeof === REACT_ELEMENT_TYPE;\n}\nfunction isForwardRef(object) {\n return typeOf(object) === REACT_FORWARD_REF_TYPE;\n}\nfunction isFragment(object) {\n return typeOf(object) === REACT_FRAGMENT_TYPE;\n}\nfunction isLazy(object) {\n return typeOf(object) === REACT_LAZY_TYPE;\n}\nfunction isMemo(object) {\n return typeOf(object) === REACT_MEMO_TYPE;\n}\nfunction isPortal(object) {\n return typeOf(object) === REACT_PORTAL_TYPE;\n}\nfunction isProfiler(object) {\n return typeOf(object) === REACT_PROFILER_TYPE;\n}\nfunction isStrictMode(object) {\n return typeOf(object) === REACT_STRICT_MODE_TYPE;\n}\nfunction isSuspense(object) {\n return typeOf(object) === REACT_SUSPENSE_TYPE;\n}\n\nexports.AsyncMode = AsyncMode;\nexports.ConcurrentMode = ConcurrentMode;\nexports.ContextConsumer = ContextConsumer;\nexports.ContextProvider = ContextProvider;\nexports.Element = Element;\nexports.ForwardRef = ForwardRef;\nexports.Fragment = Fragment;\nexports.Lazy = Lazy;\nexports.Memo = Memo;\nexports.Portal = Portal;\nexports.Profiler = Profiler;\nexports.StrictMode = StrictMode;\nexports.Suspense = Suspense;\nexports.isAsyncMode = isAsyncMode;\nexports.isConcurrentMode = isConcurrentMode;\nexports.isContextConsumer = isContextConsumer;\nexports.isContextProvider = isContextProvider;\nexports.isElement = isElement;\nexports.isForwardRef = isForwardRef;\nexports.isFragment = isFragment;\nexports.isLazy = isLazy;\nexports.isMemo = isMemo;\nexports.isPortal = isPortal;\nexports.isProfiler = isProfiler;\nexports.isStrictMode = isStrictMode;\nexports.isSuspense = isSuspense;\nexports.isValidElementType = isValidElementType;\nexports.typeOf = typeOf;\n })();\n}\n","'use strict';\n\nif (process.env.NODE_ENV === 'production') {\n module.exports = require('./cjs/react-is.production.min.js');\n} else {\n module.exports = require('./cjs/react-is.development.js');\n}\n","/*\nobject-assign\n(c) Sindre Sorhus\n@license MIT\n*/\n\n'use strict';\n/* eslint-disable no-unused-vars */\nvar getOwnPropertySymbols = Object.getOwnPropertySymbols;\nvar hasOwnProperty = Object.prototype.hasOwnProperty;\nvar propIsEnumerable = Object.prototype.propertyIsEnumerable;\n\nfunction toObject(val) {\n\tif (val === null || val === undefined) {\n\t\tthrow new TypeError('Object.assign cannot be called with null or undefined');\n\t}\n\n\treturn Object(val);\n}\n\nfunction shouldUseNative() {\n\ttry {\n\t\tif (!Object.assign) {\n\t\t\treturn false;\n\t\t}\n\n\t\t// Detect buggy property enumeration order in older V8 versions.\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=4118\n\t\tvar test1 = new String('abc'); // eslint-disable-line no-new-wrappers\n\t\ttest1[5] = 'de';\n\t\tif (Object.getOwnPropertyNames(test1)[0] === '5') {\n\t\t\treturn false;\n\t\t}\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=3056\n\t\tvar test2 = {};\n\t\tfor (var i = 0; i < 10; i++) {\n\t\t\ttest2['_' + String.fromCharCode(i)] = i;\n\t\t}\n\t\tvar order2 = Object.getOwnPropertyNames(test2).map(function (n) {\n\t\t\treturn test2[n];\n\t\t});\n\t\tif (order2.join('') !== '0123456789') {\n\t\t\treturn false;\n\t\t}\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=3056\n\t\tvar test3 = {};\n\t\t'abcdefghijklmnopqrst'.split('').forEach(function (letter) {\n\t\t\ttest3[letter] = letter;\n\t\t});\n\t\tif (Object.keys(Object.assign({}, test3)).join('') !==\n\t\t\t\t'abcdefghijklmnopqrst') {\n\t\t\treturn false;\n\t\t}\n\n\t\treturn true;\n\t} catch (err) {\n\t\t// We don't expect any of the above to throw, but better to be safe.\n\t\treturn false;\n\t}\n}\n\nmodule.exports = shouldUseNative() ? Object.assign : function (target, source) {\n\tvar from;\n\tvar to = toObject(target);\n\tvar symbols;\n\n\tfor (var s = 1; s < arguments.length; s++) {\n\t\tfrom = Object(arguments[s]);\n\n\t\tfor (var key in from) {\n\t\t\tif (hasOwnProperty.call(from, key)) {\n\t\t\t\tto[key] = from[key];\n\t\t\t}\n\t\t}\n\n\t\tif (getOwnPropertySymbols) {\n\t\t\tsymbols = getOwnPropertySymbols(from);\n\t\t\tfor (var i = 0; i < symbols.length; i++) {\n\t\t\t\tif (propIsEnumerable.call(from, symbols[i])) {\n\t\t\t\t\tto[symbols[i]] = from[symbols[i]];\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\n\treturn to;\n};\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar ReactPropTypesSecret = 'SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED';\n\nmodule.exports = ReactPropTypesSecret;\n","module.exports = Function.call.bind(Object.prototype.hasOwnProperty);\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar printWarning = function() {};\n\nif (process.env.NODE_ENV !== 'production') {\n var ReactPropTypesSecret = require('./lib/ReactPropTypesSecret');\n var loggedTypeFailures = {};\n var has = require('./lib/has');\n\n printWarning = function(text) {\n var message = 'Warning: ' + text;\n if (typeof console !== 'undefined') {\n console.error(message);\n }\n try {\n // --- Welcome to debugging React ---\n // This error was thrown as a convenience so that you can use this stack\n // to find the callsite that caused this warning to fire.\n throw new Error(message);\n } catch (x) { /**/ }\n };\n}\n\n/**\n * Assert that the values match with the type specs.\n * Error messages are memorized and will only be shown once.\n *\n * @param {object} typeSpecs Map of name to a ReactPropType\n * @param {object} values Runtime values that need to be type-checked\n * @param {string} location e.g. \"prop\", \"context\", \"child context\"\n * @param {string} componentName Name of the component for error messages.\n * @param {?Function} getStack Returns the component stack.\n * @private\n */\nfunction checkPropTypes(typeSpecs, values, location, componentName, getStack) {\n if (process.env.NODE_ENV !== 'production') {\n for (var typeSpecName in typeSpecs) {\n if (has(typeSpecs, typeSpecName)) {\n var error;\n // Prop type validation may throw. In case they do, we don't want to\n // fail the render phase where it didn't fail before. So we log it.\n // After these have been cleaned up, we'll let them throw.\n try {\n // This is intentionally an invariant that gets caught. It's the same\n // behavior as without this statement except with a better message.\n if (typeof typeSpecs[typeSpecName] !== 'function') {\n var err = Error(\n (componentName || 'React class') + ': ' + location + ' type `' + typeSpecName + '` is invalid; ' +\n 'it must be a function, usually from the `prop-types` package, but received `' + typeof typeSpecs[typeSpecName] + '`.' +\n 'This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.'\n );\n err.name = 'Invariant Violation';\n throw err;\n }\n error = typeSpecs[typeSpecName](values, typeSpecName, componentName, location, null, ReactPropTypesSecret);\n } catch (ex) {\n error = ex;\n }\n if (error && !(error instanceof Error)) {\n printWarning(\n (componentName || 'React class') + ': type specification of ' +\n location + ' `' + typeSpecName + '` is invalid; the type checker ' +\n 'function must return `null` or an `Error` but returned a ' + typeof error + '. ' +\n 'You may have forgotten to pass an argument to the type checker ' +\n 'creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and ' +\n 'shape all require an argument).'\n );\n }\n if (error instanceof Error && !(error.message in loggedTypeFailures)) {\n // Only monitor this failure once because there tends to be a lot of the\n // same error.\n loggedTypeFailures[error.message] = true;\n\n var stack = getStack ? getStack() : '';\n\n printWarning(\n 'Failed ' + location + ' type: ' + error.message + (stack != null ? stack : '')\n );\n }\n }\n }\n }\n}\n\n/**\n * Resets warning cache when testing.\n *\n * @private\n */\ncheckPropTypes.resetWarningCache = function() {\n if (process.env.NODE_ENV !== 'production') {\n loggedTypeFailures = {};\n }\n}\n\nmodule.exports = checkPropTypes;\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar ReactIs = require('react-is');\nvar assign = require('object-assign');\n\nvar ReactPropTypesSecret = require('./lib/ReactPropTypesSecret');\nvar has = require('./lib/has');\nvar checkPropTypes = require('./checkPropTypes');\n\nvar printWarning = function() {};\n\nif (process.env.NODE_ENV !== 'production') {\n printWarning = function(text) {\n var message = 'Warning: ' + text;\n if (typeof console !== 'undefined') {\n console.error(message);\n }\n try {\n // --- Welcome to debugging React ---\n // This error was thrown as a convenience so that you can use this stack\n // to find the callsite that caused this warning to fire.\n throw new Error(message);\n } catch (x) {}\n };\n}\n\nfunction emptyFunctionThatReturnsNull() {\n return null;\n}\n\nmodule.exports = function(isValidElement, throwOnDirectAccess) {\n /* global Symbol */\n var ITERATOR_SYMBOL = typeof Symbol === 'function' && Symbol.iterator;\n var FAUX_ITERATOR_SYMBOL = '@@iterator'; // Before Symbol spec.\n\n /**\n * Returns the iterator method function contained on the iterable object.\n *\n * Be sure to invoke the function with the iterable as context:\n *\n * var iteratorFn = getIteratorFn(myIterable);\n * if (iteratorFn) {\n * var iterator = iteratorFn.call(myIterable);\n * ...\n * }\n *\n * @param {?object} maybeIterable\n * @return {?function}\n */\n function getIteratorFn(maybeIterable) {\n var iteratorFn = maybeIterable && (ITERATOR_SYMBOL && maybeIterable[ITERATOR_SYMBOL] || maybeIterable[FAUX_ITERATOR_SYMBOL]);\n if (typeof iteratorFn === 'function') {\n return iteratorFn;\n }\n }\n\n /**\n * Collection of methods that allow declaration and validation of props that are\n * supplied to React components. Example usage:\n *\n * var Props = require('ReactPropTypes');\n * var MyArticle = React.createClass({\n * propTypes: {\n * // An optional string prop named \"description\".\n * description: Props.string,\n *\n * // A required enum prop named \"category\".\n * category: Props.oneOf(['News','Photos']).isRequired,\n *\n * // A prop named \"dialog\" that requires an instance of Dialog.\n * dialog: Props.instanceOf(Dialog).isRequired\n * },\n * render: function() { ... }\n * });\n *\n * A more formal specification of how these methods are used:\n *\n * type := array|bool|func|object|number|string|oneOf([...])|instanceOf(...)\n * decl := ReactPropTypes.{type}(.isRequired)?\n *\n * Each and every declaration produces a function with the same signature. This\n * allows the creation of custom validation functions. For example:\n *\n * var MyLink = React.createClass({\n * propTypes: {\n * // An optional string or URI prop named \"href\".\n * href: function(props, propName, componentName) {\n * var propValue = props[propName];\n * if (propValue != null && typeof propValue !== 'string' &&\n * !(propValue instanceof URI)) {\n * return new Error(\n * 'Expected a string or an URI for ' + propName + ' in ' +\n * componentName\n * );\n * }\n * }\n * },\n * render: function() {...}\n * });\n *\n * @internal\n */\n\n var ANONYMOUS = '<>';\n\n // Important!\n // Keep this list in sync with production version in `./factoryWithThrowingShims.js`.\n var ReactPropTypes = {\n array: createPrimitiveTypeChecker('array'),\n bigint: createPrimitiveTypeChecker('bigint'),\n bool: createPrimitiveTypeChecker('boolean'),\n func: createPrimitiveTypeChecker('function'),\n number: createPrimitiveTypeChecker('number'),\n object: createPrimitiveTypeChecker('object'),\n string: createPrimitiveTypeChecker('string'),\n symbol: createPrimitiveTypeChecker('symbol'),\n\n any: createAnyTypeChecker(),\n arrayOf: createArrayOfTypeChecker,\n element: createElementTypeChecker(),\n elementType: createElementTypeTypeChecker(),\n instanceOf: createInstanceTypeChecker,\n node: createNodeChecker(),\n objectOf: createObjectOfTypeChecker,\n oneOf: createEnumTypeChecker,\n oneOfType: createUnionTypeChecker,\n shape: createShapeTypeChecker,\n exact: createStrictShapeTypeChecker,\n };\n\n /**\n * inlined Object.is polyfill to avoid requiring consumers ship their own\n * https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object/is\n */\n /*eslint-disable no-self-compare*/\n function is(x, y) {\n // SameValue algorithm\n if (x === y) {\n // Steps 1-5, 7-10\n // Steps 6.b-6.e: +0 != -0\n return x !== 0 || 1 / x === 1 / y;\n } else {\n // Step 6.a: NaN == NaN\n return x !== x && y !== y;\n }\n }\n /*eslint-enable no-self-compare*/\n\n /**\n * We use an Error-like object for backward compatibility as people may call\n * PropTypes directly and inspect their output. However, we don't use real\n * Errors anymore. We don't inspect their stack anyway, and creating them\n * is prohibitively expensive if they are created too often, such as what\n * happens in oneOfType() for any type before the one that matched.\n */\n function PropTypeError(message, data) {\n this.message = message;\n this.data = data && typeof data === 'object' ? data: {};\n this.stack = '';\n }\n // Make `instanceof Error` still work for returned errors.\n PropTypeError.prototype = Error.prototype;\n\n function createChainableTypeChecker(validate) {\n if (process.env.NODE_ENV !== 'production') {\n var manualPropTypeCallCache = {};\n var manualPropTypeWarningCount = 0;\n }\n function checkType(isRequired, props, propName, componentName, location, propFullName, secret) {\n componentName = componentName || ANONYMOUS;\n propFullName = propFullName || propName;\n\n if (secret !== ReactPropTypesSecret) {\n if (throwOnDirectAccess) {\n // New behavior only for users of `prop-types` package\n var err = new Error(\n 'Calling PropTypes validators directly is not supported by the `prop-types` package. ' +\n 'Use `PropTypes.checkPropTypes()` to call them. ' +\n 'Read more at http://fb.me/use-check-prop-types'\n );\n err.name = 'Invariant Violation';\n throw err;\n } else if (process.env.NODE_ENV !== 'production' && typeof console !== 'undefined') {\n // Old behavior for people using React.PropTypes\n var cacheKey = componentName + ':' + propName;\n if (\n !manualPropTypeCallCache[cacheKey] &&\n // Avoid spamming the console because they are often not actionable except for lib authors\n manualPropTypeWarningCount < 3\n ) {\n printWarning(\n 'You are manually calling a React.PropTypes validation ' +\n 'function for the `' + propFullName + '` prop on `' + componentName + '`. This is deprecated ' +\n 'and will throw in the standalone `prop-types` package. ' +\n 'You may be seeing this warning due to a third-party PropTypes ' +\n 'library. See https://fb.me/react-warning-dont-call-proptypes ' + 'for details.'\n );\n manualPropTypeCallCache[cacheKey] = true;\n manualPropTypeWarningCount++;\n }\n }\n }\n if (props[propName] == null) {\n if (isRequired) {\n if (props[propName] === null) {\n return new PropTypeError('The ' + location + ' `' + propFullName + '` is marked as required ' + ('in `' + componentName + '`, but its value is `null`.'));\n }\n return new PropTypeError('The ' + location + ' `' + propFullName + '` is marked as required in ' + ('`' + componentName + '`, but its value is `undefined`.'));\n }\n return null;\n } else {\n return validate(props, propName, componentName, location, propFullName);\n }\n }\n\n var chainedCheckType = checkType.bind(null, false);\n chainedCheckType.isRequired = checkType.bind(null, true);\n\n return chainedCheckType;\n }\n\n function createPrimitiveTypeChecker(expectedType) {\n function validate(props, propName, componentName, location, propFullName, secret) {\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== expectedType) {\n // `propValue` being instance of, say, date/regexp, pass the 'object'\n // check, but we can offer a more precise error message here rather than\n // 'of type `object`'.\n var preciseType = getPreciseType(propValue);\n\n return new PropTypeError(\n 'Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + preciseType + '` supplied to `' + componentName + '`, expected ') + ('`' + expectedType + '`.'),\n {expectedType: expectedType}\n );\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createAnyTypeChecker() {\n return createChainableTypeChecker(emptyFunctionThatReturnsNull);\n }\n\n function createArrayOfTypeChecker(typeChecker) {\n function validate(props, propName, componentName, location, propFullName) {\n if (typeof typeChecker !== 'function') {\n return new PropTypeError('Property `' + propFullName + '` of component `' + componentName + '` has invalid PropType notation inside arrayOf.');\n }\n var propValue = props[propName];\n if (!Array.isArray(propValue)) {\n var propType = getPropType(propValue);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected an array.'));\n }\n for (var i = 0; i < propValue.length; i++) {\n var error = typeChecker(propValue, i, componentName, location, propFullName + '[' + i + ']', ReactPropTypesSecret);\n if (error instanceof Error) {\n return error;\n }\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createElementTypeChecker() {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n if (!isValidElement(propValue)) {\n var propType = getPropType(propValue);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected a single ReactElement.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createElementTypeTypeChecker() {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n if (!ReactIs.isValidElementType(propValue)) {\n var propType = getPropType(propValue);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected a single ReactElement type.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createInstanceTypeChecker(expectedClass) {\n function validate(props, propName, componentName, location, propFullName) {\n if (!(props[propName] instanceof expectedClass)) {\n var expectedClassName = expectedClass.name || ANONYMOUS;\n var actualClassName = getClassName(props[propName]);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + actualClassName + '` supplied to `' + componentName + '`, expected ') + ('instance of `' + expectedClassName + '`.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createEnumTypeChecker(expectedValues) {\n if (!Array.isArray(expectedValues)) {\n if (process.env.NODE_ENV !== 'production') {\n if (arguments.length > 1) {\n printWarning(\n 'Invalid arguments supplied to oneOf, expected an array, got ' + arguments.length + ' arguments. ' +\n 'A common mistake is to write oneOf(x, y, z) instead of oneOf([x, y, z]).'\n );\n } else {\n printWarning('Invalid argument supplied to oneOf, expected an array.');\n }\n }\n return emptyFunctionThatReturnsNull;\n }\n\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n for (var i = 0; i < expectedValues.length; i++) {\n if (is(propValue, expectedValues[i])) {\n return null;\n }\n }\n\n var valuesString = JSON.stringify(expectedValues, function replacer(key, value) {\n var type = getPreciseType(value);\n if (type === 'symbol') {\n return String(value);\n }\n return value;\n });\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of value `' + String(propValue) + '` ' + ('supplied to `' + componentName + '`, expected one of ' + valuesString + '.'));\n }\n return createChainableTypeChecker(validate);\n }\n\n function createObjectOfTypeChecker(typeChecker) {\n function validate(props, propName, componentName, location, propFullName) {\n if (typeof typeChecker !== 'function') {\n return new PropTypeError('Property `' + propFullName + '` of component `' + componentName + '` has invalid PropType notation inside objectOf.');\n }\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== 'object') {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected an object.'));\n }\n for (var key in propValue) {\n if (has(propValue, key)) {\n var error = typeChecker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret);\n if (error instanceof Error) {\n return error;\n }\n }\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createUnionTypeChecker(arrayOfTypeCheckers) {\n if (!Array.isArray(arrayOfTypeCheckers)) {\n process.env.NODE_ENV !== 'production' ? printWarning('Invalid argument supplied to oneOfType, expected an instance of array.') : void 0;\n return emptyFunctionThatReturnsNull;\n }\n\n for (var i = 0; i < arrayOfTypeCheckers.length; i++) {\n var checker = arrayOfTypeCheckers[i];\n if (typeof checker !== 'function') {\n printWarning(\n 'Invalid argument supplied to oneOfType. Expected an array of check functions, but ' +\n 'received ' + getPostfixForTypeWarning(checker) + ' at index ' + i + '.'\n );\n return emptyFunctionThatReturnsNull;\n }\n }\n\n function validate(props, propName, componentName, location, propFullName) {\n var expectedTypes = [];\n for (var i = 0; i < arrayOfTypeCheckers.length; i++) {\n var checker = arrayOfTypeCheckers[i];\n var checkerResult = checker(props, propName, componentName, location, propFullName, ReactPropTypesSecret);\n if (checkerResult == null) {\n return null;\n }\n if (checkerResult.data && has(checkerResult.data, 'expectedType')) {\n expectedTypes.push(checkerResult.data.expectedType);\n }\n }\n var expectedTypesMessage = (expectedTypes.length > 0) ? ', expected one of type [' + expectedTypes.join(', ') + ']': '';\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` supplied to ' + ('`' + componentName + '`' + expectedTypesMessage + '.'));\n }\n return createChainableTypeChecker(validate);\n }\n\n function createNodeChecker() {\n function validate(props, propName, componentName, location, propFullName) {\n if (!isNode(props[propName])) {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` supplied to ' + ('`' + componentName + '`, expected a ReactNode.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function invalidValidatorError(componentName, location, propFullName, key, type) {\n return new PropTypeError(\n (componentName || 'React class') + ': ' + location + ' type `' + propFullName + '.' + key + '` is invalid; ' +\n 'it must be a function, usually from the `prop-types` package, but received `' + type + '`.'\n );\n }\n\n function createShapeTypeChecker(shapeTypes) {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== 'object') {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type `' + propType + '` ' + ('supplied to `' + componentName + '`, expected `object`.'));\n }\n for (var key in shapeTypes) {\n var checker = shapeTypes[key];\n if (typeof checker !== 'function') {\n return invalidValidatorError(componentName, location, propFullName, key, getPreciseType(checker));\n }\n var error = checker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret);\n if (error) {\n return error;\n }\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createStrictShapeTypeChecker(shapeTypes) {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== 'object') {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type `' + propType + '` ' + ('supplied to `' + componentName + '`, expected `object`.'));\n }\n // We need to check all keys in case some are required but missing from props.\n var allKeys = assign({}, props[propName], shapeTypes);\n for (var key in allKeys) {\n var checker = shapeTypes[key];\n if (has(shapeTypes, key) && typeof checker !== 'function') {\n return invalidValidatorError(componentName, location, propFullName, key, getPreciseType(checker));\n }\n if (!checker) {\n return new PropTypeError(\n 'Invalid ' + location + ' `' + propFullName + '` key `' + key + '` supplied to `' + componentName + '`.' +\n '\\nBad object: ' + JSON.stringify(props[propName], null, ' ') +\n '\\nValid keys: ' + JSON.stringify(Object.keys(shapeTypes), null, ' ')\n );\n }\n var error = checker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret);\n if (error) {\n return error;\n }\n }\n return null;\n }\n\n return createChainableTypeChecker(validate);\n }\n\n function isNode(propValue) {\n switch (typeof propValue) {\n case 'number':\n case 'string':\n case 'undefined':\n return true;\n case 'boolean':\n return !propValue;\n case 'object':\n if (Array.isArray(propValue)) {\n return propValue.every(isNode);\n }\n if (propValue === null || isValidElement(propValue)) {\n return true;\n }\n\n var iteratorFn = getIteratorFn(propValue);\n if (iteratorFn) {\n var iterator = iteratorFn.call(propValue);\n var step;\n if (iteratorFn !== propValue.entries) {\n while (!(step = iterator.next()).done) {\n if (!isNode(step.value)) {\n return false;\n }\n }\n } else {\n // Iterator will provide entry [k,v] tuples rather than values.\n while (!(step = iterator.next()).done) {\n var entry = step.value;\n if (entry) {\n if (!isNode(entry[1])) {\n return false;\n }\n }\n }\n }\n } else {\n return false;\n }\n\n return true;\n default:\n return false;\n }\n }\n\n function isSymbol(propType, propValue) {\n // Native Symbol.\n if (propType === 'symbol') {\n return true;\n }\n\n // falsy value can't be a Symbol\n if (!propValue) {\n return false;\n }\n\n // 19.4.3.5 Symbol.prototype[@@toStringTag] === 'Symbol'\n if (propValue['@@toStringTag'] === 'Symbol') {\n return true;\n }\n\n // Fallback for non-spec compliant Symbols which are polyfilled.\n if (typeof Symbol === 'function' && propValue instanceof Symbol) {\n return true;\n }\n\n return false;\n }\n\n // Equivalent of `typeof` but with special handling for array and regexp.\n function getPropType(propValue) {\n var propType = typeof propValue;\n if (Array.isArray(propValue)) {\n return 'array';\n }\n if (propValue instanceof RegExp) {\n // Old webkits (at least until Android 4.0) return 'function' rather than\n // 'object' for typeof a RegExp. We'll normalize this here so that /bla/\n // passes PropTypes.object.\n return 'object';\n }\n if (isSymbol(propType, propValue)) {\n return 'symbol';\n }\n return propType;\n }\n\n // This handles more types than `getPropType`. Only used for error messages.\n // See `createPrimitiveTypeChecker`.\n function getPreciseType(propValue) {\n if (typeof propValue === 'undefined' || propValue === null) {\n return '' + propValue;\n }\n var propType = getPropType(propValue);\n if (propType === 'object') {\n if (propValue instanceof Date) {\n return 'date';\n } else if (propValue instanceof RegExp) {\n return 'regexp';\n }\n }\n return propType;\n }\n\n // Returns a string that is postfixed to a warning about an invalid type.\n // For example, \"undefined\" or \"of type array\"\n function getPostfixForTypeWarning(value) {\n var type = getPreciseType(value);\n switch (type) {\n case 'array':\n case 'object':\n return 'an ' + type;\n case 'boolean':\n case 'date':\n case 'regexp':\n return 'a ' + type;\n default:\n return type;\n }\n }\n\n // Returns class name of the object, if any.\n function getClassName(propValue) {\n if (!propValue.constructor || !propValue.constructor.name) {\n return ANONYMOUS;\n }\n return propValue.constructor.name;\n }\n\n ReactPropTypes.checkPropTypes = checkPropTypes;\n ReactPropTypes.resetWarningCache = checkPropTypes.resetWarningCache;\n ReactPropTypes.PropTypes = ReactPropTypes;\n\n return ReactPropTypes;\n};\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar ReactPropTypesSecret = require('./lib/ReactPropTypesSecret');\n\nfunction emptyFunction() {}\nfunction emptyFunctionWithReset() {}\nemptyFunctionWithReset.resetWarningCache = emptyFunction;\n\nmodule.exports = function() {\n function shim(props, propName, componentName, location, propFullName, secret) {\n if (secret === ReactPropTypesSecret) {\n // It is still safe when called from React.\n return;\n }\n var err = new Error(\n 'Calling PropTypes validators directly is not supported by the `prop-types` package. ' +\n 'Use PropTypes.checkPropTypes() to call them. ' +\n 'Read more at http://fb.me/use-check-prop-types'\n );\n err.name = 'Invariant Violation';\n throw err;\n };\n shim.isRequired = shim;\n function getShim() {\n return shim;\n };\n // Important!\n // Keep this list in sync with production version in `./factoryWithTypeCheckers.js`.\n var ReactPropTypes = {\n array: shim,\n bigint: shim,\n bool: shim,\n func: shim,\n number: shim,\n object: shim,\n string: shim,\n symbol: shim,\n\n any: shim,\n arrayOf: getShim,\n element: shim,\n elementType: shim,\n instanceOf: getShim,\n node: shim,\n objectOf: getShim,\n oneOf: getShim,\n oneOfType: getShim,\n shape: getShim,\n exact: getShim,\n\n checkPropTypes: emptyFunctionWithReset,\n resetWarningCache: emptyFunction\n };\n\n ReactPropTypes.PropTypes = ReactPropTypes;\n\n return ReactPropTypes;\n};\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\nif (process.env.NODE_ENV !== 'production') {\n var ReactIs = require('react-is');\n\n // By explicitly using `prop-types` you are opting into new development behavior.\n // http://fb.me/prop-types-in-prod\n var throwOnDirectAccess = true;\n module.exports = require('./factoryWithTypeCheckers')(ReactIs.isElement, throwOnDirectAccess);\n} else {\n // By explicitly using `prop-types` you are opting into new production behavior.\n // http://fb.me/prop-types-in-prod\n module.exports = require('./factoryWithThrowingShims')();\n}\n","import PropTypes from 'prop-types';\nimport chainPropTypes from '../chainPropTypes';\nfunction isClassComponent(elementType) {\n // elementType.prototype?.isReactComponent\n const {\n prototype = {}\n } = elementType;\n return Boolean(prototype.isReactComponent);\n}\nfunction acceptingRef(props, propName, componentName, location, propFullName) {\n const element = props[propName];\n const safePropName = propFullName || propName;\n if (element == null ||\n // When server-side rendering React doesn't warn either.\n // This is not an accurate check for SSR.\n // This is only in place for Emotion compat.\n // TODO: Revisit once https://github.com/facebook/react/issues/20047 is resolved.\n typeof window === 'undefined') {\n return null;\n }\n let warningHint;\n const elementType = element.type;\n /**\n * Blacklisting instead of whitelisting\n *\n * Blacklisting will miss some components, such as React.Fragment. Those will at least\n * trigger a warning in React.\n * We can't whitelist because there is no safe way to detect React.forwardRef\n * or class components. \"Safe\" means there's no public API.\n *\n */\n if (typeof elementType === 'function' && !isClassComponent(elementType)) {\n warningHint = 'Did you accidentally use a plain function component for an element instead?';\n }\n if (warningHint !== undefined) {\n return new Error(`Invalid ${location} \\`${safePropName}\\` supplied to \\`${componentName}\\`. ` + `Expected an element that can hold a ref. ${warningHint} ` + 'For more information see https://mui.com/r/caveat-with-refs-guide');\n }\n return null;\n}\nconst elementAcceptingRef = chainPropTypes(PropTypes.element, acceptingRef);\nelementAcceptingRef.isRequired = chainPropTypes(PropTypes.element.isRequired, acceptingRef);\nexport default elementAcceptingRef;","import _extends from \"@babel/runtime/helpers/esm/extends\";\n// This module is based on https://github.com/airbnb/prop-types-exact repository.\n// However, in order to reduce the number of dependencies and to remove some extra safe checks\n// the module was forked.\n\nconst specialProperty = 'exact-prop: \\u200b';\nexport default function exactProp(propTypes) {\n if (process.env.NODE_ENV === 'production') {\n return propTypes;\n }\n return _extends({}, propTypes, {\n [specialProperty]: props => {\n const unsupportedProps = Object.keys(props).filter(prop => !propTypes.hasOwnProperty(prop));\n if (unsupportedProps.length > 0) {\n return new Error(`The following props are not supported: ${unsupportedProps.map(prop => `\\`${prop}\\``).join(', ')}. Please remove them.`);\n }\n return null;\n }\n });\n}","/**\n * WARNING: Don't import this directly.\n * Use `MuiError` from `@mui/internal-babel-macros/MuiError.macro` instead.\n * @param {number} code\n */\nexport default function formatMuiErrorMessage(code) {\n // Apply babel-plugin-transform-template-literals in loose mode\n // loose mode is safe if we're concatenating primitives\n // see https://babeljs.io/docs/en/babel-plugin-transform-template-literals#loose\n /* eslint-disable prefer-template */\n let url = 'https://mui.com/production-error/?code=' + code;\n for (let i = 1; i < arguments.length; i += 1) {\n // rest params over-transpile for this case\n // eslint-disable-next-line prefer-rest-params\n url += '&args[]=' + encodeURIComponent(arguments[i]);\n }\n return 'Minified MUI error #' + code + '; visit ' + url + ' for the full message.';\n /* eslint-enable prefer-template */\n}","/**\n * @license React\n * react-is.production.min.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n'use strict';var b=Symbol.for(\"react.element\"),c=Symbol.for(\"react.portal\"),d=Symbol.for(\"react.fragment\"),e=Symbol.for(\"react.strict_mode\"),f=Symbol.for(\"react.profiler\"),g=Symbol.for(\"react.provider\"),h=Symbol.for(\"react.context\"),k=Symbol.for(\"react.server_context\"),l=Symbol.for(\"react.forward_ref\"),m=Symbol.for(\"react.suspense\"),n=Symbol.for(\"react.suspense_list\"),p=Symbol.for(\"react.memo\"),q=Symbol.for(\"react.lazy\"),t=Symbol.for(\"react.offscreen\"),u;u=Symbol.for(\"react.module.reference\");\nfunction v(a){if(\"object\"===typeof a&&null!==a){var r=a.$$typeof;switch(r){case b:switch(a=a.type,a){case d:case f:case e:case m:case n:return a;default:switch(a=a&&a.$$typeof,a){case k:case h:case l:case q:case p:case g:return a;default:return r}}case c:return r}}}exports.ContextConsumer=h;exports.ContextProvider=g;exports.Element=b;exports.ForwardRef=l;exports.Fragment=d;exports.Lazy=q;exports.Memo=p;exports.Portal=c;exports.Profiler=f;exports.StrictMode=e;exports.Suspense=m;\nexports.SuspenseList=n;exports.isAsyncMode=function(){return!1};exports.isConcurrentMode=function(){return!1};exports.isContextConsumer=function(a){return v(a)===h};exports.isContextProvider=function(a){return v(a)===g};exports.isElement=function(a){return\"object\"===typeof a&&null!==a&&a.$$typeof===b};exports.isForwardRef=function(a){return v(a)===l};exports.isFragment=function(a){return v(a)===d};exports.isLazy=function(a){return v(a)===q};exports.isMemo=function(a){return v(a)===p};\nexports.isPortal=function(a){return v(a)===c};exports.isProfiler=function(a){return v(a)===f};exports.isStrictMode=function(a){return v(a)===e};exports.isSuspense=function(a){return v(a)===m};exports.isSuspenseList=function(a){return v(a)===n};\nexports.isValidElementType=function(a){return\"string\"===typeof a||\"function\"===typeof a||a===d||a===f||a===e||a===m||a===n||a===t||\"object\"===typeof a&&null!==a&&(a.$$typeof===q||a.$$typeof===p||a.$$typeof===g||a.$$typeof===h||a.$$typeof===l||a.$$typeof===u||void 0!==a.getModuleId)?!0:!1};exports.typeOf=v;\n","/**\n * @license React\n * react-is.development.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nif (process.env.NODE_ENV !== \"production\") {\n (function() {\n'use strict';\n\n// ATTENTION\n// When adding new symbols to this file,\n// Please consider also adding to 'react-devtools-shared/src/backend/ReactSymbols'\n// The Symbol used to tag the ReactElement-like types.\nvar REACT_ELEMENT_TYPE = Symbol.for('react.element');\nvar REACT_PORTAL_TYPE = Symbol.for('react.portal');\nvar REACT_FRAGMENT_TYPE = Symbol.for('react.fragment');\nvar REACT_STRICT_MODE_TYPE = Symbol.for('react.strict_mode');\nvar REACT_PROFILER_TYPE = Symbol.for('react.profiler');\nvar REACT_PROVIDER_TYPE = Symbol.for('react.provider');\nvar REACT_CONTEXT_TYPE = Symbol.for('react.context');\nvar REACT_SERVER_CONTEXT_TYPE = Symbol.for('react.server_context');\nvar REACT_FORWARD_REF_TYPE = Symbol.for('react.forward_ref');\nvar REACT_SUSPENSE_TYPE = Symbol.for('react.suspense');\nvar REACT_SUSPENSE_LIST_TYPE = Symbol.for('react.suspense_list');\nvar REACT_MEMO_TYPE = Symbol.for('react.memo');\nvar REACT_LAZY_TYPE = Symbol.for('react.lazy');\nvar REACT_OFFSCREEN_TYPE = Symbol.for('react.offscreen');\n\n// -----------------------------------------------------------------------------\n\nvar enableScopeAPI = false; // Experimental Create Event Handle API.\nvar enableCacheElement = false;\nvar enableTransitionTracing = false; // No known bugs, but needs performance testing\n\nvar enableLegacyHidden = false; // Enables unstable_avoidThisFallback feature in Fiber\n// stuff. Intended to enable React core members to more easily debug scheduling\n// issues in DEV builds.\n\nvar enableDebugTracing = false; // Track which Fiber(s) schedule render work.\n\nvar REACT_MODULE_REFERENCE;\n\n{\n REACT_MODULE_REFERENCE = Symbol.for('react.module.reference');\n}\n\nfunction isValidElementType(type) {\n if (typeof type === 'string' || typeof type === 'function') {\n return true;\n } // Note: typeof might be other than 'symbol' or 'number' (e.g. if it's a polyfill).\n\n\n if (type === REACT_FRAGMENT_TYPE || type === REACT_PROFILER_TYPE || enableDebugTracing || type === REACT_STRICT_MODE_TYPE || type === REACT_SUSPENSE_TYPE || type === REACT_SUSPENSE_LIST_TYPE || enableLegacyHidden || type === REACT_OFFSCREEN_TYPE || enableScopeAPI || enableCacheElement || enableTransitionTracing ) {\n return true;\n }\n\n if (typeof type === 'object' && type !== null) {\n if (type.$$typeof === REACT_LAZY_TYPE || type.$$typeof === REACT_MEMO_TYPE || type.$$typeof === REACT_PROVIDER_TYPE || type.$$typeof === REACT_CONTEXT_TYPE || type.$$typeof === REACT_FORWARD_REF_TYPE || // This needs to include all possible module reference object\n // types supported by any Flight configuration anywhere since\n // we don't know which Flight build this will end up being used\n // with.\n type.$$typeof === REACT_MODULE_REFERENCE || type.getModuleId !== undefined) {\n return true;\n }\n }\n\n return false;\n}\n\nfunction typeOf(object) {\n if (typeof object === 'object' && object !== null) {\n var $$typeof = object.$$typeof;\n\n switch ($$typeof) {\n case REACT_ELEMENT_TYPE:\n var type = object.type;\n\n switch (type) {\n case REACT_FRAGMENT_TYPE:\n case REACT_PROFILER_TYPE:\n case REACT_STRICT_MODE_TYPE:\n case REACT_SUSPENSE_TYPE:\n case REACT_SUSPENSE_LIST_TYPE:\n return type;\n\n default:\n var $$typeofType = type && type.$$typeof;\n\n switch ($$typeofType) {\n case REACT_SERVER_CONTEXT_TYPE:\n case REACT_CONTEXT_TYPE:\n case REACT_FORWARD_REF_TYPE:\n case REACT_LAZY_TYPE:\n case REACT_MEMO_TYPE:\n case REACT_PROVIDER_TYPE:\n return $$typeofType;\n\n default:\n return $$typeof;\n }\n\n }\n\n case REACT_PORTAL_TYPE:\n return $$typeof;\n }\n }\n\n return undefined;\n}\nvar ContextConsumer = REACT_CONTEXT_TYPE;\nvar ContextProvider = REACT_PROVIDER_TYPE;\nvar Element = REACT_ELEMENT_TYPE;\nvar ForwardRef = REACT_FORWARD_REF_TYPE;\nvar Fragment = REACT_FRAGMENT_TYPE;\nvar Lazy = REACT_LAZY_TYPE;\nvar Memo = REACT_MEMO_TYPE;\nvar Portal = REACT_PORTAL_TYPE;\nvar Profiler = REACT_PROFILER_TYPE;\nvar StrictMode = REACT_STRICT_MODE_TYPE;\nvar Suspense = REACT_SUSPENSE_TYPE;\nvar SuspenseList = REACT_SUSPENSE_LIST_TYPE;\nvar hasWarnedAboutDeprecatedIsAsyncMode = false;\nvar hasWarnedAboutDeprecatedIsConcurrentMode = false; // AsyncMode should be deprecated\n\nfunction isAsyncMode(object) {\n {\n if (!hasWarnedAboutDeprecatedIsAsyncMode) {\n hasWarnedAboutDeprecatedIsAsyncMode = true; // Using console['warn'] to evade Babel and ESLint\n\n console['warn']('The ReactIs.isAsyncMode() alias has been deprecated, ' + 'and will be removed in React 18+.');\n }\n }\n\n return false;\n}\nfunction isConcurrentMode(object) {\n {\n if (!hasWarnedAboutDeprecatedIsConcurrentMode) {\n hasWarnedAboutDeprecatedIsConcurrentMode = true; // Using console['warn'] to evade Babel and ESLint\n\n console['warn']('The ReactIs.isConcurrentMode() alias has been deprecated, ' + 'and will be removed in React 18+.');\n }\n }\n\n return false;\n}\nfunction isContextConsumer(object) {\n return typeOf(object) === REACT_CONTEXT_TYPE;\n}\nfunction isContextProvider(object) {\n return typeOf(object) === REACT_PROVIDER_TYPE;\n}\nfunction isElement(object) {\n return typeof object === 'object' && object !== null && object.$$typeof === REACT_ELEMENT_TYPE;\n}\nfunction isForwardRef(object) {\n return typeOf(object) === REACT_FORWARD_REF_TYPE;\n}\nfunction isFragment(object) {\n return typeOf(object) === REACT_FRAGMENT_TYPE;\n}\nfunction isLazy(object) {\n return typeOf(object) === REACT_LAZY_TYPE;\n}\nfunction isMemo(object) {\n return typeOf(object) === REACT_MEMO_TYPE;\n}\nfunction isPortal(object) {\n return typeOf(object) === REACT_PORTAL_TYPE;\n}\nfunction isProfiler(object) {\n return typeOf(object) === REACT_PROFILER_TYPE;\n}\nfunction isStrictMode(object) {\n return typeOf(object) === REACT_STRICT_MODE_TYPE;\n}\nfunction isSuspense(object) {\n return typeOf(object) === REACT_SUSPENSE_TYPE;\n}\nfunction isSuspenseList(object) {\n return typeOf(object) === REACT_SUSPENSE_LIST_TYPE;\n}\n\nexports.ContextConsumer = ContextConsumer;\nexports.ContextProvider = ContextProvider;\nexports.Element = Element;\nexports.ForwardRef = ForwardRef;\nexports.Fragment = Fragment;\nexports.Lazy = Lazy;\nexports.Memo = Memo;\nexports.Portal = Portal;\nexports.Profiler = Profiler;\nexports.StrictMode = StrictMode;\nexports.Suspense = Suspense;\nexports.SuspenseList = SuspenseList;\nexports.isAsyncMode = isAsyncMode;\nexports.isConcurrentMode = isConcurrentMode;\nexports.isContextConsumer = isContextConsumer;\nexports.isContextProvider = isContextProvider;\nexports.isElement = isElement;\nexports.isForwardRef = isForwardRef;\nexports.isFragment = isFragment;\nexports.isLazy = isLazy;\nexports.isMemo = isMemo;\nexports.isPortal = isPortal;\nexports.isProfiler = isProfiler;\nexports.isStrictMode = isStrictMode;\nexports.isSuspense = isSuspense;\nexports.isSuspenseList = isSuspenseList;\nexports.isValidElementType = isValidElementType;\nexports.typeOf = typeOf;\n })();\n}\n","'use strict';\n\nif (process.env.NODE_ENV === 'production') {\n module.exports = require('./cjs/react-is.production.min.js');\n} else {\n module.exports = require('./cjs/react-is.development.js');\n}\n","import { ForwardRef, Memo } from 'react-is';\n\n// Simplified polyfill for IE11 support\n// https://github.com/JamesMGreene/Function.name/blob/58b314d4a983110c3682f1228f845d39ccca1817/Function.name.js#L3\nconst fnNameMatchRegex = /^\\s*function(?:\\s|\\s*\\/\\*.*\\*\\/\\s*)+([^(\\s/]*)\\s*/;\nexport function getFunctionName(fn) {\n const match = `${fn}`.match(fnNameMatchRegex);\n const name = match && match[1];\n return name || '';\n}\nfunction getFunctionComponentName(Component, fallback = '') {\n return Component.displayName || Component.name || getFunctionName(Component) || fallback;\n}\nfunction getWrappedName(outerType, innerType, wrapperName) {\n const functionName = getFunctionComponentName(innerType);\n return outerType.displayName || (functionName !== '' ? `${wrapperName}(${functionName})` : wrapperName);\n}\n\n/**\n * cherry-pick from\n * https://github.com/facebook/react/blob/769b1f270e1251d9dbdce0fcbd9e92e502d059b8/packages/shared/getComponentName.js\n * originally forked from recompose/getDisplayName with added IE11 support\n */\nexport default function getDisplayName(Component) {\n if (Component == null) {\n return undefined;\n }\n if (typeof Component === 'string') {\n return Component;\n }\n if (typeof Component === 'function') {\n return getFunctionComponentName(Component, 'Component');\n }\n\n // TypeScript can't have components as objects but they exist in the form of `memo` or `Suspense`\n if (typeof Component === 'object') {\n switch (Component.$$typeof) {\n case ForwardRef:\n return getWrappedName(Component, Component.render, 'ForwardRef');\n case Memo:\n return getWrappedName(Component, Component.type, 'memo');\n default:\n return undefined;\n }\n }\n return undefined;\n}","export default function HTMLElementType(props, propName, componentName, location, propFullName) {\n if (process.env.NODE_ENV === 'production') {\n return null;\n }\n const propValue = props[propName];\n const safePropName = propFullName || propName;\n if (propValue == null) {\n return null;\n }\n if (propValue && propValue.nodeType !== 1) {\n return new Error(`Invalid ${location} \\`${safePropName}\\` supplied to \\`${componentName}\\`. ` + `Expected an HTMLElement.`);\n }\n return null;\n}","import PropTypes from 'prop-types';\nconst refType = PropTypes.oneOfType([PropTypes.func, PropTypes.object]);\nexport default refType;","import _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\n// It should to be noted that this function isn't equivalent to `text-transform: capitalize`.\n//\n// A strict capitalization should uppercase the first letter of each word in the sentence.\n// We only handle the first word.\nexport default function capitalize(string) {\n if (typeof string !== 'string') {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: \\`capitalize(string)\\` expects a string argument.` : _formatMuiErrorMessage(7));\n }\n return string.charAt(0).toUpperCase() + string.slice(1);\n}","/**\n * Safe chained function.\n *\n * Will only create a new function if needed,\n * otherwise will pass back existing functions or null.\n */\nexport default function createChainedFunction(...funcs) {\n return funcs.reduce((acc, func) => {\n if (func == null) {\n return acc;\n }\n return function chainedFunction(...args) {\n acc.apply(this, args);\n func.apply(this, args);\n };\n }, () => {});\n}","// Corresponds to 10 frames at 60 Hz.\n// A few bytes payload overhead when lodash/debounce is ~3 kB and debounce ~300 B.\nexport default function debounce(func, wait = 166) {\n let timeout;\n function debounced(...args) {\n const later = () => {\n // @ts-ignore\n func.apply(this, args);\n };\n clearTimeout(timeout);\n timeout = setTimeout(later, wait);\n }\n debounced.clear = () => {\n clearTimeout(timeout);\n };\n return debounced;\n}","export default function deprecatedPropType(validator, reason) {\n if (process.env.NODE_ENV === 'production') {\n return () => null;\n }\n return (props, propName, componentName, location, propFullName) => {\n const componentNameSafe = componentName || '<>';\n const propFullNameSafe = propFullName || propName;\n if (typeof props[propName] !== 'undefined') {\n return new Error(`The ${location} \\`${propFullNameSafe}\\` of ` + `\\`${componentNameSafe}\\` is deprecated. ${reason}`);\n }\n return null;\n };\n}","import * as React from 'react';\nexport default function isMuiElement(element, muiNames) {\n var _muiName, _element$type;\n return /*#__PURE__*/React.isValidElement(element) && muiNames.indexOf( // For server components `muiName` is avaialble in element.type._payload.value.muiName\n // relevant info - https://github.com/facebook/react/blob/2807d781a08db8e9873687fccc25c0f12b4fb3d4/packages/react/src/ReactLazy.js#L45\n // eslint-disable-next-line no-underscore-dangle\n (_muiName = element.type.muiName) != null ? _muiName : (_element$type = element.type) == null || (_element$type = _element$type._payload) == null || (_element$type = _element$type.value) == null ? void 0 : _element$type.muiName) !== -1;\n}","export default function ownerDocument(node) {\n return node && node.ownerDocument || document;\n}","import ownerDocument from '../ownerDocument';\nexport default function ownerWindow(node) {\n const doc = ownerDocument(node);\n return doc.defaultView || window;\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nexport default function requirePropFactory(componentNameInError, Component) {\n if (process.env.NODE_ENV === 'production') {\n return () => null;\n }\n\n // eslint-disable-next-line react/forbid-foreign-prop-types\n const prevPropTypes = Component ? _extends({}, Component.propTypes) : null;\n const requireProp = requiredProp => (props, propName, componentName, location, propFullName, ...args) => {\n const propFullNameSafe = propFullName || propName;\n const defaultTypeChecker = prevPropTypes == null ? void 0 : prevPropTypes[propFullNameSafe];\n if (defaultTypeChecker) {\n const typeCheckerResult = defaultTypeChecker(props, propName, componentName, location, propFullName, ...args);\n if (typeCheckerResult) {\n return typeCheckerResult;\n }\n }\n if (typeof props[propName] !== 'undefined' && !props[requiredProp]) {\n return new Error(`The prop \\`${propFullNameSafe}\\` of ` + `\\`${componentNameInError}\\` can only be used together with the \\`${requiredProp}\\` prop.`);\n }\n return null;\n };\n return requireProp;\n}","/**\n * TODO v5: consider making it private\n *\n * passes {value} to {ref}\n *\n * WARNING: Be sure to only call this inside a callback that is passed as a ref.\n * Otherwise, make sure to cleanup the previous {ref} if it changes. See\n * https://github.com/mui/material-ui/issues/13539\n *\n * Useful if you want to expose the ref of an inner component to the public API\n * while still using it inside the component.\n * @param ref A ref callback or ref object. If anything falsy, this is a no-op.\n */\nexport default function setRef(ref, value) {\n if (typeof ref === 'function') {\n ref(value);\n } else if (ref) {\n ref.current = value;\n }\n}","'use client';\n\nimport * as React from 'react';\n\n/**\n * A version of `React.useLayoutEffect` that does not show a warning when server-side rendering.\n * This is useful for effects that are only needed for client-side rendering but not for SSR.\n *\n * Before you use this hook, make sure to read https://gist.github.com/gaearon/e7d97cdf38a2907924ea12e4ebdf3c85\n * and confirm it doesn't apply to your use-case.\n */\nconst useEnhancedEffect = typeof window !== 'undefined' ? React.useLayoutEffect : React.useEffect;\nexport default useEnhancedEffect;","'use client';\n\nimport * as React from 'react';\nlet globalId = 0;\nfunction useGlobalId(idOverride) {\n const [defaultId, setDefaultId] = React.useState(idOverride);\n const id = idOverride || defaultId;\n React.useEffect(() => {\n if (defaultId == null) {\n // Fallback to this default id when possible.\n // Use the incrementing value for client-side rendering only.\n // We can't use it server-side.\n // If you want to use random values please consider the Birthday Problem: https://en.wikipedia.org/wiki/Birthday_problem\n globalId += 1;\n setDefaultId(`mui-${globalId}`);\n }\n }, [defaultId]);\n return id;\n}\n\n// downstream bundlers may remove unnecessary concatenation, but won't remove toString call -- Workaround for https://github.com/webpack/webpack/issues/14814\nconst maybeReactUseId = React['useId'.toString()];\n/**\n *\n * @example
    \n * @param idOverride\n * @returns {string}\n */\nexport default function useId(idOverride) {\n if (maybeReactUseId !== undefined) {\n const reactId = maybeReactUseId();\n return idOverride != null ? idOverride : reactId;\n }\n // eslint-disable-next-line react-hooks/rules-of-hooks -- `React.useId` is invariant at runtime.\n return useGlobalId(idOverride);\n}","export default function unsupportedProp(props, propName, componentName, location, propFullName) {\n if (process.env.NODE_ENV === 'production') {\n return null;\n }\n const propFullNameSafe = propFullName || propName;\n if (typeof props[propName] !== 'undefined') {\n return new Error(`The prop \\`${propFullNameSafe}\\` is not supported. Please remove it.`);\n }\n return null;\n}","'use client';\n\n/* eslint-disable react-hooks/rules-of-hooks, react-hooks/exhaustive-deps */\nimport * as React from 'react';\nexport default function useControlled({\n controlled,\n default: defaultProp,\n name,\n state = 'value'\n}) {\n // isControlled is ignored in the hook dependency lists as it should never change.\n const {\n current: isControlled\n } = React.useRef(controlled !== undefined);\n const [valueState, setValue] = React.useState(defaultProp);\n const value = isControlled ? controlled : valueState;\n if (process.env.NODE_ENV !== 'production') {\n React.useEffect(() => {\n if (isControlled !== (controlled !== undefined)) {\n console.error([`MUI: A component is changing the ${isControlled ? '' : 'un'}controlled ${state} state of ${name} to be ${isControlled ? 'un' : ''}controlled.`, 'Elements should not switch from uncontrolled to controlled (or vice versa).', `Decide between using a controlled or uncontrolled ${name} ` + 'element for the lifetime of the component.', \"The nature of the state is determined during the first render. It's considered controlled if the value is not `undefined`.\", 'More info: https://fb.me/react-controlled-components'].join('\\n'));\n }\n }, [state, name, controlled]);\n const {\n current: defaultValue\n } = React.useRef(defaultProp);\n React.useEffect(() => {\n if (!isControlled && defaultValue !== defaultProp) {\n console.error([`MUI: A component is changing the default ${state} state of an uncontrolled ${name} after being initialized. ` + `To suppress this warning opt to use a controlled ${name}.`].join('\\n'));\n }\n }, [JSON.stringify(defaultProp)]);\n }\n const setValueIfUncontrolled = React.useCallback(newValue => {\n if (!isControlled) {\n setValue(newValue);\n }\n }, []);\n return [value, setValueIfUncontrolled];\n}","'use client';\n\nimport * as React from 'react';\nimport useEnhancedEffect from '../useEnhancedEffect';\n\n/**\n * Inspired by https://github.com/facebook/react/issues/14099#issuecomment-440013892\n * See RFC in https://github.com/reactjs/rfcs/pull/220\n */\n\nfunction useEventCallback(fn) {\n const ref = React.useRef(fn);\n useEnhancedEffect(() => {\n ref.current = fn;\n });\n return React.useRef((...args) =>\n // @ts-expect-error hide `this`\n (0, ref.current)(...args)).current;\n}\nexport default useEventCallback;","'use client';\n\nimport * as React from 'react';\nimport setRef from '../setRef';\nexport default function useForkRef(...refs) {\n /**\n * This will create a new function if the refs passed to this hook change and are all defined.\n * This means react will call the old forkRef with `null` and the new forkRef\n * with the ref. Cleanup naturally emerges from this behavior.\n */\n return React.useMemo(() => {\n if (refs.every(ref => ref == null)) {\n return null;\n }\n return instance => {\n refs.forEach(ref => {\n setRef(ref, instance);\n });\n };\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, refs);\n}","'use client';\n\nimport * as React from 'react';\nconst UNINITIALIZED = {};\n\n/**\n * A React.useRef() that is initialized lazily with a function. Note that it accepts an optional\n * initialization argument, so the initialization function doesn't need to be an inline closure.\n *\n * @usage\n * const ref = useLazyRef(sortColumns, columns)\n */\nexport default function useLazyRef(init, initArg) {\n const ref = React.useRef(UNINITIALIZED);\n if (ref.current === UNINITIALIZED) {\n ref.current = init(initArg);\n }\n return ref;\n}","'use client';\n\nimport * as React from 'react';\nconst EMPTY = [];\n\n/**\n * A React.useEffect equivalent that runs once, when the component is mounted.\n */\nexport default function useOnMount(fn) {\n /* eslint-disable react-hooks/exhaustive-deps */\n React.useEffect(fn, EMPTY);\n /* eslint-enable react-hooks/exhaustive-deps */\n}","'use client';\n\nimport useLazyRef from '../useLazyRef/useLazyRef';\nimport useOnMount from '../useOnMount/useOnMount';\nexport class Timeout {\n constructor() {\n this.currentId = null;\n this.clear = () => {\n if (this.currentId !== null) {\n clearTimeout(this.currentId);\n this.currentId = null;\n }\n };\n this.disposeEffect = () => {\n return this.clear;\n };\n }\n static create() {\n return new Timeout();\n }\n /**\n * Executes `fn` after `delay`, clearing any previously scheduled call.\n */\n start(delay, fn) {\n this.clear();\n this.currentId = setTimeout(() => {\n this.currentId = null;\n fn();\n }, delay);\n }\n}\nexport default function useTimeout() {\n const timeout = useLazyRef(Timeout.create).current;\n useOnMount(timeout.disposeEffect);\n return timeout;\n}","'use client';\n\n// based on https://github.com/WICG/focus-visible/blob/v4.1.5/src/focus-visible.js\nimport * as React from 'react';\nimport { Timeout } from '../useTimeout/useTimeout';\nlet hadKeyboardEvent = true;\nlet hadFocusVisibleRecently = false;\nconst hadFocusVisibleRecentlyTimeout = new Timeout();\nconst inputTypesWhitelist = {\n text: true,\n search: true,\n url: true,\n tel: true,\n email: true,\n password: true,\n number: true,\n date: true,\n month: true,\n week: true,\n time: true,\n datetime: true,\n 'datetime-local': true\n};\n\n/**\n * Computes whether the given element should automatically trigger the\n * `focus-visible` class being added, i.e. whether it should always match\n * `:focus-visible` when focused.\n * @param {Element} node\n * @returns {boolean}\n */\nfunction focusTriggersKeyboardModality(node) {\n const {\n type,\n tagName\n } = node;\n if (tagName === 'INPUT' && inputTypesWhitelist[type] && !node.readOnly) {\n return true;\n }\n if (tagName === 'TEXTAREA' && !node.readOnly) {\n return true;\n }\n if (node.isContentEditable) {\n return true;\n }\n return false;\n}\n\n/**\n * Keep track of our keyboard modality state with `hadKeyboardEvent`.\n * If the most recent user interaction was via the keyboard;\n * and the key press did not include a meta, alt/option, or control key;\n * then the modality is keyboard. Otherwise, the modality is not keyboard.\n * @param {KeyboardEvent} event\n */\nfunction handleKeyDown(event) {\n if (event.metaKey || event.altKey || event.ctrlKey) {\n return;\n }\n hadKeyboardEvent = true;\n}\n\n/**\n * If at any point a user clicks with a pointing device, ensure that we change\n * the modality away from keyboard.\n * This avoids the situation where a user presses a key on an already focused\n * element, and then clicks on a different element, focusing it with a\n * pointing device, while we still think we're in keyboard modality.\n */\nfunction handlePointerDown() {\n hadKeyboardEvent = false;\n}\nfunction handleVisibilityChange() {\n if (this.visibilityState === 'hidden') {\n // If the tab becomes active again, the browser will handle calling focus\n // on the element (Safari actually calls it twice).\n // If this tab change caused a blur on an element with focus-visible,\n // re-apply the class when the user switches back to the tab.\n if (hadFocusVisibleRecently) {\n hadKeyboardEvent = true;\n }\n }\n}\nfunction prepare(doc) {\n doc.addEventListener('keydown', handleKeyDown, true);\n doc.addEventListener('mousedown', handlePointerDown, true);\n doc.addEventListener('pointerdown', handlePointerDown, true);\n doc.addEventListener('touchstart', handlePointerDown, true);\n doc.addEventListener('visibilitychange', handleVisibilityChange, true);\n}\nexport function teardown(doc) {\n doc.removeEventListener('keydown', handleKeyDown, true);\n doc.removeEventListener('mousedown', handlePointerDown, true);\n doc.removeEventListener('pointerdown', handlePointerDown, true);\n doc.removeEventListener('touchstart', handlePointerDown, true);\n doc.removeEventListener('visibilitychange', handleVisibilityChange, true);\n}\nfunction isFocusVisible(event) {\n const {\n target\n } = event;\n try {\n return target.matches(':focus-visible');\n } catch (error) {\n // Browsers not implementing :focus-visible will throw a SyntaxError.\n // We use our own heuristic for those browsers.\n // Rethrow might be better if it's not the expected error but do we really\n // want to crash if focus-visible malfunctioned?\n }\n\n // No need for validFocusTarget check. The user does that by attaching it to\n // focusable events only.\n return hadKeyboardEvent || focusTriggersKeyboardModality(target);\n}\nexport default function useIsFocusVisible() {\n const ref = React.useCallback(node => {\n if (node != null) {\n prepare(node.ownerDocument);\n }\n }, []);\n const isFocusVisibleRef = React.useRef(false);\n\n /**\n * Should be called if a blur event is fired\n */\n function handleBlurVisible() {\n // checking against potential state variable does not suffice if we focus and blur synchronously.\n // React wouldn't have time to trigger a re-render so `focusVisible` would be stale.\n // Ideally we would adjust `isFocusVisible(event)` to look at `relatedTarget` for blur events.\n // This doesn't work in IE11 due to https://github.com/facebook/react/issues/3751\n // TODO: check again if React releases their internal changes to focus event handling (https://github.com/facebook/react/pull/19186).\n if (isFocusVisibleRef.current) {\n // To detect a tab/window switch, we look for a blur event followed\n // rapidly by a visibility change.\n // If we don't see a visibility change within 100ms, it's probably a\n // regular focus change.\n hadFocusVisibleRecently = true;\n hadFocusVisibleRecentlyTimeout.start(100, () => {\n hadFocusVisibleRecently = false;\n });\n isFocusVisibleRef.current = false;\n return true;\n }\n return false;\n }\n\n /**\n * Should be called if a blur event is fired\n */\n function handleFocusVisible(event) {\n if (isFocusVisible(event)) {\n isFocusVisibleRef.current = true;\n return true;\n }\n return false;\n }\n return {\n isFocusVisibleRef,\n onFocus: handleFocusVisible,\n onBlur: handleBlurVisible,\n ref\n };\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\n/**\n * Add keys, values of `defaultProps` that does not exist in `props`\n * @param {object} defaultProps\n * @param {object} props\n * @returns {object} resolved props\n */\nexport default function resolveProps(defaultProps, props) {\n const output = _extends({}, props);\n Object.keys(defaultProps).forEach(propName => {\n if (propName.toString().match(/^(components|slots)$/)) {\n output[propName] = _extends({}, defaultProps[propName], output[propName]);\n } else if (propName.toString().match(/^(componentsProps|slotProps)$/)) {\n const defaultSlotProps = defaultProps[propName] || {};\n const slotProps = props[propName];\n output[propName] = {};\n if (!slotProps || !Object.keys(slotProps)) {\n // Reduce the iteration if the slot props is empty\n output[propName] = defaultSlotProps;\n } else if (!defaultSlotProps || !Object.keys(defaultSlotProps)) {\n // Reduce the iteration if the default slot props is empty\n output[propName] = slotProps;\n } else {\n output[propName] = _extends({}, slotProps);\n Object.keys(defaultSlotProps).forEach(slotPropName => {\n output[propName][slotPropName] = resolveProps(defaultSlotProps[slotPropName], slotProps[slotPropName]);\n });\n }\n } else if (output[propName] === undefined) {\n output[propName] = defaultProps[propName];\n }\n });\n return output;\n}","export default function composeClasses(slots, getUtilityClass, classes = undefined) {\n const output = {};\n Object.keys(slots).forEach(\n // `Object.keys(slots)` can't be wider than `T` because we infer `T` from `slots`.\n // @ts-expect-error https://github.com/microsoft/TypeScript/pull/12253#issuecomment-263132208\n slot => {\n output[slot] = slots[slot].reduce((acc, key) => {\n if (key) {\n const utilityClass = getUtilityClass(key);\n if (utilityClass !== '') {\n acc.push(utilityClass);\n }\n if (classes && classes[key]) {\n acc.push(classes[key]);\n }\n }\n return acc;\n }, []).join(' ');\n });\n return output;\n}","const defaultGenerator = componentName => componentName;\nconst createClassNameGenerator = () => {\n let generate = defaultGenerator;\n return {\n configure(generator) {\n generate = generator;\n },\n generate(componentName) {\n return generate(componentName);\n },\n reset() {\n generate = defaultGenerator;\n }\n };\n};\nconst ClassNameGenerator = createClassNameGenerator();\nexport default ClassNameGenerator;","import ClassNameGenerator from '../ClassNameGenerator';\nexport const globalStateClasses = {\n active: 'active',\n checked: 'checked',\n completed: 'completed',\n disabled: 'disabled',\n error: 'error',\n expanded: 'expanded',\n focused: 'focused',\n focusVisible: 'focusVisible',\n open: 'open',\n readOnly: 'readOnly',\n required: 'required',\n selected: 'selected'\n};\nexport default function generateUtilityClass(componentName, slot, globalStatePrefix = 'Mui') {\n const globalStateClass = globalStateClasses[slot];\n return globalStateClass ? `${globalStatePrefix}-${globalStateClass}` : `${ClassNameGenerator.generate(componentName)}-${slot}`;\n}\nexport function isGlobalState(slot) {\n return globalStateClasses[slot] !== undefined;\n}","import generateUtilityClass from '../generateUtilityClass';\nexport default function generateUtilityClasses(componentName, slots, globalStatePrefix = 'Mui') {\n const result = {};\n slots.forEach(slot => {\n result[slot] = generateUtilityClass(componentName, slot, globalStatePrefix);\n });\n return result;\n}","function clamp(val, min = Number.MIN_SAFE_INTEGER, max = Number.MAX_SAFE_INTEGER) {\n return Math.max(min, Math.min(val, max));\n}\nexport default clamp;","export default function _objectWithoutPropertiesLoose(source, excluded) {\n if (source == null) return {};\n var target = {};\n var sourceKeys = Object.keys(source);\n var key, i;\n for (i = 0; i < sourceKeys.length; i++) {\n key = sourceKeys[i];\n if (excluded.indexOf(key) >= 0) continue;\n target[key] = source[key];\n }\n return target;\n}","import _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nconst _excluded = [\"values\", \"unit\", \"step\"];\n// Sorted ASC by size. That's important.\n// It can't be configured as it's used statically for propTypes.\nexport const breakpointKeys = ['xs', 'sm', 'md', 'lg', 'xl'];\nconst sortBreakpointsValues = values => {\n const breakpointsAsArray = Object.keys(values).map(key => ({\n key,\n val: values[key]\n })) || [];\n // Sort in ascending order\n breakpointsAsArray.sort((breakpoint1, breakpoint2) => breakpoint1.val - breakpoint2.val);\n return breakpointsAsArray.reduce((acc, obj) => {\n return _extends({}, acc, {\n [obj.key]: obj.val\n });\n }, {});\n};\n\n// Keep in mind that @media is inclusive by the CSS specification.\nexport default function createBreakpoints(breakpoints) {\n const {\n // The breakpoint **start** at this value.\n // For instance with the first breakpoint xs: [xs, sm).\n values = {\n xs: 0,\n // phone\n sm: 600,\n // tablet\n md: 900,\n // small laptop\n lg: 1200,\n // desktop\n xl: 1536 // large screen\n },\n unit = 'px',\n step = 5\n } = breakpoints,\n other = _objectWithoutPropertiesLoose(breakpoints, _excluded);\n const sortedValues = sortBreakpointsValues(values);\n const keys = Object.keys(sortedValues);\n function up(key) {\n const value = typeof values[key] === 'number' ? values[key] : key;\n return `@media (min-width:${value}${unit})`;\n }\n function down(key) {\n const value = typeof values[key] === 'number' ? values[key] : key;\n return `@media (max-width:${value - step / 100}${unit})`;\n }\n function between(start, end) {\n const endIndex = keys.indexOf(end);\n return `@media (min-width:${typeof values[start] === 'number' ? values[start] : start}${unit}) and ` + `(max-width:${(endIndex !== -1 && typeof values[keys[endIndex]] === 'number' ? values[keys[endIndex]] : end) - step / 100}${unit})`;\n }\n function only(key) {\n if (keys.indexOf(key) + 1 < keys.length) {\n return between(key, keys[keys.indexOf(key) + 1]);\n }\n return up(key);\n }\n function not(key) {\n // handle first and last key separately, for better readability\n const keyIndex = keys.indexOf(key);\n if (keyIndex === 0) {\n return up(keys[1]);\n }\n if (keyIndex === keys.length - 1) {\n return down(keys[keyIndex]);\n }\n return between(key, keys[keys.indexOf(key) + 1]).replace('@media', '@media not all and');\n }\n return _extends({\n keys,\n values: sortedValues,\n up,\n down,\n between,\n only,\n not,\n unit\n }, other);\n}","const shape = {\n borderRadius: 4\n};\nexport default shape;","import PropTypes from 'prop-types';\nconst responsivePropType = process.env.NODE_ENV !== 'production' ? PropTypes.oneOfType([PropTypes.number, PropTypes.string, PropTypes.object, PropTypes.array]) : {};\nexport default responsivePropType;","import deepmerge from '@mui/utils/deepmerge';\nfunction merge(acc, item) {\n if (!item) {\n return acc;\n }\n return deepmerge(acc, item, {\n clone: false // No need to clone deep, it's way faster.\n });\n}\nexport default merge;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport PropTypes from 'prop-types';\nimport deepmerge from '@mui/utils/deepmerge';\nimport merge from './merge';\n\n// The breakpoint **start** at this value.\n// For instance with the first breakpoint xs: [xs, sm[.\nexport const values = {\n xs: 0,\n // phone\n sm: 600,\n // tablet\n md: 900,\n // small laptop\n lg: 1200,\n // desktop\n xl: 1536 // large screen\n};\nconst defaultBreakpoints = {\n // Sorted ASC by size. That's important.\n // It can't be configured as it's used statically for propTypes.\n keys: ['xs', 'sm', 'md', 'lg', 'xl'],\n up: key => `@media (min-width:${values[key]}px)`\n};\nexport function handleBreakpoints(props, propValue, styleFromPropValue) {\n const theme = props.theme || {};\n if (Array.isArray(propValue)) {\n const themeBreakpoints = theme.breakpoints || defaultBreakpoints;\n return propValue.reduce((acc, item, index) => {\n acc[themeBreakpoints.up(themeBreakpoints.keys[index])] = styleFromPropValue(propValue[index]);\n return acc;\n }, {});\n }\n if (typeof propValue === 'object') {\n const themeBreakpoints = theme.breakpoints || defaultBreakpoints;\n return Object.keys(propValue).reduce((acc, breakpoint) => {\n // key is breakpoint\n if (Object.keys(themeBreakpoints.values || values).indexOf(breakpoint) !== -1) {\n const mediaKey = themeBreakpoints.up(breakpoint);\n acc[mediaKey] = styleFromPropValue(propValue[breakpoint], breakpoint);\n } else {\n const cssKey = breakpoint;\n acc[cssKey] = propValue[cssKey];\n }\n return acc;\n }, {});\n }\n const output = styleFromPropValue(propValue);\n return output;\n}\nfunction breakpoints(styleFunction) {\n // false positive\n // eslint-disable-next-line react/function-component-definition\n const newStyleFunction = props => {\n const theme = props.theme || {};\n const base = styleFunction(props);\n const themeBreakpoints = theme.breakpoints || defaultBreakpoints;\n const extended = themeBreakpoints.keys.reduce((acc, key) => {\n if (props[key]) {\n acc = acc || {};\n acc[themeBreakpoints.up(key)] = styleFunction(_extends({\n theme\n }, props[key]));\n }\n return acc;\n }, null);\n return merge(base, extended);\n };\n newStyleFunction.propTypes = process.env.NODE_ENV !== 'production' ? _extends({}, styleFunction.propTypes, {\n xs: PropTypes.object,\n sm: PropTypes.object,\n md: PropTypes.object,\n lg: PropTypes.object,\n xl: PropTypes.object\n }) : {};\n newStyleFunction.filterProps = ['xs', 'sm', 'md', 'lg', 'xl', ...styleFunction.filterProps];\n return newStyleFunction;\n}\nexport function createEmptyBreakpointObject(breakpointsInput = {}) {\n var _breakpointsInput$key;\n const breakpointsInOrder = (_breakpointsInput$key = breakpointsInput.keys) == null ? void 0 : _breakpointsInput$key.reduce((acc, key) => {\n const breakpointStyleKey = breakpointsInput.up(key);\n acc[breakpointStyleKey] = {};\n return acc;\n }, {});\n return breakpointsInOrder || {};\n}\nexport function removeUnusedBreakpoints(breakpointKeys, style) {\n return breakpointKeys.reduce((acc, key) => {\n const breakpointOutput = acc[key];\n const isBreakpointUnused = !breakpointOutput || Object.keys(breakpointOutput).length === 0;\n if (isBreakpointUnused) {\n delete acc[key];\n }\n return acc;\n }, style);\n}\nexport function mergeBreakpointsInOrder(breakpointsInput, ...styles) {\n const emptyBreakpoints = createEmptyBreakpointObject(breakpointsInput);\n const mergedOutput = [emptyBreakpoints, ...styles].reduce((prev, next) => deepmerge(prev, next), {});\n return removeUnusedBreakpoints(Object.keys(emptyBreakpoints), mergedOutput);\n}\n\n// compute base for responsive values; e.g.,\n// [1,2,3] => {xs: true, sm: true, md: true}\n// {xs: 1, sm: 2, md: 3} => {xs: true, sm: true, md: true}\nexport function computeBreakpointsBase(breakpointValues, themeBreakpoints) {\n // fixed value\n if (typeof breakpointValues !== 'object') {\n return {};\n }\n const base = {};\n const breakpointsKeys = Object.keys(themeBreakpoints);\n if (Array.isArray(breakpointValues)) {\n breakpointsKeys.forEach((breakpoint, i) => {\n if (i < breakpointValues.length) {\n base[breakpoint] = true;\n }\n });\n } else {\n breakpointsKeys.forEach(breakpoint => {\n if (breakpointValues[breakpoint] != null) {\n base[breakpoint] = true;\n }\n });\n }\n return base;\n}\nexport function resolveBreakpointValues({\n values: breakpointValues,\n breakpoints: themeBreakpoints,\n base: customBase\n}) {\n const base = customBase || computeBreakpointsBase(breakpointValues, themeBreakpoints);\n const keys = Object.keys(base);\n if (keys.length === 0) {\n return breakpointValues;\n }\n let previous;\n return keys.reduce((acc, breakpoint, i) => {\n if (Array.isArray(breakpointValues)) {\n acc[breakpoint] = breakpointValues[i] != null ? breakpointValues[i] : breakpointValues[previous];\n previous = i;\n } else if (typeof breakpointValues === 'object') {\n acc[breakpoint] = breakpointValues[breakpoint] != null ? breakpointValues[breakpoint] : breakpointValues[previous];\n previous = breakpoint;\n } else {\n acc[breakpoint] = breakpointValues;\n }\n return acc;\n }, {});\n}\nexport default breakpoints;","import capitalize from '@mui/utils/capitalize';\nimport responsivePropType from './responsivePropType';\nimport { handleBreakpoints } from './breakpoints';\nexport function getPath(obj, path, checkVars = true) {\n if (!path || typeof path !== 'string') {\n return null;\n }\n\n // Check if CSS variables are used\n if (obj && obj.vars && checkVars) {\n const val = `vars.${path}`.split('.').reduce((acc, item) => acc && acc[item] ? acc[item] : null, obj);\n if (val != null) {\n return val;\n }\n }\n return path.split('.').reduce((acc, item) => {\n if (acc && acc[item] != null) {\n return acc[item];\n }\n return null;\n }, obj);\n}\nexport function getStyleValue(themeMapping, transform, propValueFinal, userValue = propValueFinal) {\n let value;\n if (typeof themeMapping === 'function') {\n value = themeMapping(propValueFinal);\n } else if (Array.isArray(themeMapping)) {\n value = themeMapping[propValueFinal] || userValue;\n } else {\n value = getPath(themeMapping, propValueFinal) || userValue;\n }\n if (transform) {\n value = transform(value, userValue, themeMapping);\n }\n return value;\n}\nfunction style(options) {\n const {\n prop,\n cssProperty = options.prop,\n themeKey,\n transform\n } = options;\n\n // false positive\n // eslint-disable-next-line react/function-component-definition\n const fn = props => {\n if (props[prop] == null) {\n return null;\n }\n const propValue = props[prop];\n const theme = props.theme;\n const themeMapping = getPath(theme, themeKey) || {};\n const styleFromPropValue = propValueFinal => {\n let value = getStyleValue(themeMapping, transform, propValueFinal);\n if (propValueFinal === value && typeof propValueFinal === 'string') {\n // Haven't found value\n value = getStyleValue(themeMapping, transform, `${prop}${propValueFinal === 'default' ? '' : capitalize(propValueFinal)}`, propValueFinal);\n }\n if (cssProperty === false) {\n return value;\n }\n return {\n [cssProperty]: value\n };\n };\n return handleBreakpoints(props, propValue, styleFromPropValue);\n };\n fn.propTypes = process.env.NODE_ENV !== 'production' ? {\n [prop]: responsivePropType\n } : {};\n fn.filterProps = [prop];\n return fn;\n}\nexport default style;","export default function memoize(fn) {\n const cache = {};\n return arg => {\n if (cache[arg] === undefined) {\n cache[arg] = fn(arg);\n }\n return cache[arg];\n };\n}","import responsivePropType from './responsivePropType';\nimport { handleBreakpoints } from './breakpoints';\nimport { getPath } from './style';\nimport merge from './merge';\nimport memoize from './memoize';\nconst properties = {\n m: 'margin',\n p: 'padding'\n};\nconst directions = {\n t: 'Top',\n r: 'Right',\n b: 'Bottom',\n l: 'Left',\n x: ['Left', 'Right'],\n y: ['Top', 'Bottom']\n};\nconst aliases = {\n marginX: 'mx',\n marginY: 'my',\n paddingX: 'px',\n paddingY: 'py'\n};\n\n// memoize() impact:\n// From 300,000 ops/sec\n// To 350,000 ops/sec\nconst getCssProperties = memoize(prop => {\n // It's not a shorthand notation.\n if (prop.length > 2) {\n if (aliases[prop]) {\n prop = aliases[prop];\n } else {\n return [prop];\n }\n }\n const [a, b] = prop.split('');\n const property = properties[a];\n const direction = directions[b] || '';\n return Array.isArray(direction) ? direction.map(dir => property + dir) : [property + direction];\n});\nexport const marginKeys = ['m', 'mt', 'mr', 'mb', 'ml', 'mx', 'my', 'margin', 'marginTop', 'marginRight', 'marginBottom', 'marginLeft', 'marginX', 'marginY', 'marginInline', 'marginInlineStart', 'marginInlineEnd', 'marginBlock', 'marginBlockStart', 'marginBlockEnd'];\nexport const paddingKeys = ['p', 'pt', 'pr', 'pb', 'pl', 'px', 'py', 'padding', 'paddingTop', 'paddingRight', 'paddingBottom', 'paddingLeft', 'paddingX', 'paddingY', 'paddingInline', 'paddingInlineStart', 'paddingInlineEnd', 'paddingBlock', 'paddingBlockStart', 'paddingBlockEnd'];\nconst spacingKeys = [...marginKeys, ...paddingKeys];\nexport function createUnaryUnit(theme, themeKey, defaultValue, propName) {\n var _getPath;\n const themeSpacing = (_getPath = getPath(theme, themeKey, false)) != null ? _getPath : defaultValue;\n if (typeof themeSpacing === 'number') {\n return abs => {\n if (typeof abs === 'string') {\n return abs;\n }\n if (process.env.NODE_ENV !== 'production') {\n if (typeof abs !== 'number') {\n console.error(`MUI: Expected ${propName} argument to be a number or a string, got ${abs}.`);\n }\n }\n return themeSpacing * abs;\n };\n }\n if (Array.isArray(themeSpacing)) {\n return abs => {\n if (typeof abs === 'string') {\n return abs;\n }\n if (process.env.NODE_ENV !== 'production') {\n if (!Number.isInteger(abs)) {\n console.error([`MUI: The \\`theme.${themeKey}\\` array type cannot be combined with non integer values.` + `You should either use an integer value that can be used as index, or define the \\`theme.${themeKey}\\` as a number.`].join('\\n'));\n } else if (abs > themeSpacing.length - 1) {\n console.error([`MUI: The value provided (${abs}) overflows.`, `The supported values are: ${JSON.stringify(themeSpacing)}.`, `${abs} > ${themeSpacing.length - 1}, you need to add the missing values.`].join('\\n'));\n }\n }\n return themeSpacing[abs];\n };\n }\n if (typeof themeSpacing === 'function') {\n return themeSpacing;\n }\n if (process.env.NODE_ENV !== 'production') {\n console.error([`MUI: The \\`theme.${themeKey}\\` value (${themeSpacing}) is invalid.`, 'It should be a number, an array or a function.'].join('\\n'));\n }\n return () => undefined;\n}\nexport function createUnarySpacing(theme) {\n return createUnaryUnit(theme, 'spacing', 8, 'spacing');\n}\nexport function getValue(transformer, propValue) {\n if (typeof propValue === 'string' || propValue == null) {\n return propValue;\n }\n const abs = Math.abs(propValue);\n const transformed = transformer(abs);\n if (propValue >= 0) {\n return transformed;\n }\n if (typeof transformed === 'number') {\n return -transformed;\n }\n return `-${transformed}`;\n}\nexport function getStyleFromPropValue(cssProperties, transformer) {\n return propValue => cssProperties.reduce((acc, cssProperty) => {\n acc[cssProperty] = getValue(transformer, propValue);\n return acc;\n }, {});\n}\nfunction resolveCssProperty(props, keys, prop, transformer) {\n // Using a hash computation over an array iteration could be faster, but with only 28 items,\n // it's doesn't worth the bundle size.\n if (keys.indexOf(prop) === -1) {\n return null;\n }\n const cssProperties = getCssProperties(prop);\n const styleFromPropValue = getStyleFromPropValue(cssProperties, transformer);\n const propValue = props[prop];\n return handleBreakpoints(props, propValue, styleFromPropValue);\n}\nfunction style(props, keys) {\n const transformer = createUnarySpacing(props.theme);\n return Object.keys(props).map(prop => resolveCssProperty(props, keys, prop, transformer)).reduce(merge, {});\n}\nexport function margin(props) {\n return style(props, marginKeys);\n}\nmargin.propTypes = process.env.NODE_ENV !== 'production' ? marginKeys.reduce((obj, key) => {\n obj[key] = responsivePropType;\n return obj;\n}, {}) : {};\nmargin.filterProps = marginKeys;\nexport function padding(props) {\n return style(props, paddingKeys);\n}\npadding.propTypes = process.env.NODE_ENV !== 'production' ? paddingKeys.reduce((obj, key) => {\n obj[key] = responsivePropType;\n return obj;\n}, {}) : {};\npadding.filterProps = paddingKeys;\nfunction spacing(props) {\n return style(props, spacingKeys);\n}\nspacing.propTypes = process.env.NODE_ENV !== 'production' ? spacingKeys.reduce((obj, key) => {\n obj[key] = responsivePropType;\n return obj;\n}, {}) : {};\nspacing.filterProps = spacingKeys;\nexport default spacing;","import { createUnarySpacing } from '../spacing';\n\n// The different signatures imply different meaning for their arguments that can't be expressed structurally.\n// We express the difference with variable names.\n\nexport default function createSpacing(spacingInput = 8) {\n // Already transformed.\n if (spacingInput.mui) {\n return spacingInput;\n }\n\n // Material Design layouts are visually balanced. Most measurements align to an 8dp grid, which aligns both spacing and the overall layout.\n // Smaller components, such as icons, can align to a 4dp grid.\n // https://m2.material.io/design/layout/understanding-layout.html\n const transform = createUnarySpacing({\n spacing: spacingInput\n });\n const spacing = (...argsInput) => {\n if (process.env.NODE_ENV !== 'production') {\n if (!(argsInput.length <= 4)) {\n console.error(`MUI: Too many arguments provided, expected between 0 and 4, got ${argsInput.length}`);\n }\n }\n const args = argsInput.length === 0 ? [1] : argsInput;\n return args.map(argument => {\n const output = transform(argument);\n return typeof output === 'number' ? `${output}px` : output;\n }).join(' ');\n };\n spacing.mui = true;\n return spacing;\n}","import merge from './merge';\nfunction compose(...styles) {\n const handlers = styles.reduce((acc, style) => {\n style.filterProps.forEach(prop => {\n acc[prop] = style;\n });\n return acc;\n }, {});\n\n // false positive\n // eslint-disable-next-line react/function-component-definition\n const fn = props => {\n return Object.keys(props).reduce((acc, prop) => {\n if (handlers[prop]) {\n return merge(acc, handlers[prop](props));\n }\n return acc;\n }, {});\n };\n fn.propTypes = process.env.NODE_ENV !== 'production' ? styles.reduce((acc, style) => Object.assign(acc, style.propTypes), {}) : {};\n fn.filterProps = styles.reduce((acc, style) => acc.concat(style.filterProps), []);\n return fn;\n}\nexport default compose;","import responsivePropType from './responsivePropType';\nimport style from './style';\nimport compose from './compose';\nimport { createUnaryUnit, getValue } from './spacing';\nimport { handleBreakpoints } from './breakpoints';\nexport function borderTransform(value) {\n if (typeof value !== 'number') {\n return value;\n }\n return `${value}px solid`;\n}\nfunction createBorderStyle(prop, transform) {\n return style({\n prop,\n themeKey: 'borders',\n transform\n });\n}\nexport const border = createBorderStyle('border', borderTransform);\nexport const borderTop = createBorderStyle('borderTop', borderTransform);\nexport const borderRight = createBorderStyle('borderRight', borderTransform);\nexport const borderBottom = createBorderStyle('borderBottom', borderTransform);\nexport const borderLeft = createBorderStyle('borderLeft', borderTransform);\nexport const borderColor = createBorderStyle('borderColor');\nexport const borderTopColor = createBorderStyle('borderTopColor');\nexport const borderRightColor = createBorderStyle('borderRightColor');\nexport const borderBottomColor = createBorderStyle('borderBottomColor');\nexport const borderLeftColor = createBorderStyle('borderLeftColor');\nexport const outline = createBorderStyle('outline', borderTransform);\nexport const outlineColor = createBorderStyle('outlineColor');\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const borderRadius = props => {\n if (props.borderRadius !== undefined && props.borderRadius !== null) {\n const transformer = createUnaryUnit(props.theme, 'shape.borderRadius', 4, 'borderRadius');\n const styleFromPropValue = propValue => ({\n borderRadius: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.borderRadius, styleFromPropValue);\n }\n return null;\n};\nborderRadius.propTypes = process.env.NODE_ENV !== 'production' ? {\n borderRadius: responsivePropType\n} : {};\nborderRadius.filterProps = ['borderRadius'];\nconst borders = compose(border, borderTop, borderRight, borderBottom, borderLeft, borderColor, borderTopColor, borderRightColor, borderBottomColor, borderLeftColor, borderRadius, outline, outlineColor);\nexport default borders;","import style from './style';\nimport compose from './compose';\nimport { createUnaryUnit, getValue } from './spacing';\nimport { handleBreakpoints } from './breakpoints';\nimport responsivePropType from './responsivePropType';\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const gap = props => {\n if (props.gap !== undefined && props.gap !== null) {\n const transformer = createUnaryUnit(props.theme, 'spacing', 8, 'gap');\n const styleFromPropValue = propValue => ({\n gap: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.gap, styleFromPropValue);\n }\n return null;\n};\ngap.propTypes = process.env.NODE_ENV !== 'production' ? {\n gap: responsivePropType\n} : {};\ngap.filterProps = ['gap'];\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const columnGap = props => {\n if (props.columnGap !== undefined && props.columnGap !== null) {\n const transformer = createUnaryUnit(props.theme, 'spacing', 8, 'columnGap');\n const styleFromPropValue = propValue => ({\n columnGap: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.columnGap, styleFromPropValue);\n }\n return null;\n};\ncolumnGap.propTypes = process.env.NODE_ENV !== 'production' ? {\n columnGap: responsivePropType\n} : {};\ncolumnGap.filterProps = ['columnGap'];\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const rowGap = props => {\n if (props.rowGap !== undefined && props.rowGap !== null) {\n const transformer = createUnaryUnit(props.theme, 'spacing', 8, 'rowGap');\n const styleFromPropValue = propValue => ({\n rowGap: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.rowGap, styleFromPropValue);\n }\n return null;\n};\nrowGap.propTypes = process.env.NODE_ENV !== 'production' ? {\n rowGap: responsivePropType\n} : {};\nrowGap.filterProps = ['rowGap'];\nexport const gridColumn = style({\n prop: 'gridColumn'\n});\nexport const gridRow = style({\n prop: 'gridRow'\n});\nexport const gridAutoFlow = style({\n prop: 'gridAutoFlow'\n});\nexport const gridAutoColumns = style({\n prop: 'gridAutoColumns'\n});\nexport const gridAutoRows = style({\n prop: 'gridAutoRows'\n});\nexport const gridTemplateColumns = style({\n prop: 'gridTemplateColumns'\n});\nexport const gridTemplateRows = style({\n prop: 'gridTemplateRows'\n});\nexport const gridTemplateAreas = style({\n prop: 'gridTemplateAreas'\n});\nexport const gridArea = style({\n prop: 'gridArea'\n});\nconst grid = compose(gap, columnGap, rowGap, gridColumn, gridRow, gridAutoFlow, gridAutoColumns, gridAutoRows, gridTemplateColumns, gridTemplateRows, gridTemplateAreas, gridArea);\nexport default grid;","import style from './style';\nimport compose from './compose';\nexport function paletteTransform(value, userValue) {\n if (userValue === 'grey') {\n return userValue;\n }\n return value;\n}\nexport const color = style({\n prop: 'color',\n themeKey: 'palette',\n transform: paletteTransform\n});\nexport const bgcolor = style({\n prop: 'bgcolor',\n cssProperty: 'backgroundColor',\n themeKey: 'palette',\n transform: paletteTransform\n});\nexport const backgroundColor = style({\n prop: 'backgroundColor',\n themeKey: 'palette',\n transform: paletteTransform\n});\nconst palette = compose(color, bgcolor, backgroundColor);\nexport default palette;","import style from './style';\nimport compose from './compose';\nimport { handleBreakpoints, values as breakpointsValues } from './breakpoints';\nexport function sizingTransform(value) {\n return value <= 1 && value !== 0 ? `${value * 100}%` : value;\n}\nexport const width = style({\n prop: 'width',\n transform: sizingTransform\n});\nexport const maxWidth = props => {\n if (props.maxWidth !== undefined && props.maxWidth !== null) {\n const styleFromPropValue = propValue => {\n var _props$theme, _props$theme2;\n const breakpoint = ((_props$theme = props.theme) == null || (_props$theme = _props$theme.breakpoints) == null || (_props$theme = _props$theme.values) == null ? void 0 : _props$theme[propValue]) || breakpointsValues[propValue];\n if (!breakpoint) {\n return {\n maxWidth: sizingTransform(propValue)\n };\n }\n if (((_props$theme2 = props.theme) == null || (_props$theme2 = _props$theme2.breakpoints) == null ? void 0 : _props$theme2.unit) !== 'px') {\n return {\n maxWidth: `${breakpoint}${props.theme.breakpoints.unit}`\n };\n }\n return {\n maxWidth: breakpoint\n };\n };\n return handleBreakpoints(props, props.maxWidth, styleFromPropValue);\n }\n return null;\n};\nmaxWidth.filterProps = ['maxWidth'];\nexport const minWidth = style({\n prop: 'minWidth',\n transform: sizingTransform\n});\nexport const height = style({\n prop: 'height',\n transform: sizingTransform\n});\nexport const maxHeight = style({\n prop: 'maxHeight',\n transform: sizingTransform\n});\nexport const minHeight = style({\n prop: 'minHeight',\n transform: sizingTransform\n});\nexport const sizeWidth = style({\n prop: 'size',\n cssProperty: 'width',\n transform: sizingTransform\n});\nexport const sizeHeight = style({\n prop: 'size',\n cssProperty: 'height',\n transform: sizingTransform\n});\nexport const boxSizing = style({\n prop: 'boxSizing'\n});\nconst sizing = compose(width, maxWidth, minWidth, height, maxHeight, minHeight, boxSizing);\nexport default sizing;","import { padding, margin } from '../spacing';\nimport { borderRadius, borderTransform } from '../borders';\nimport { gap, rowGap, columnGap } from '../cssGrid';\nimport { paletteTransform } from '../palette';\nimport { maxWidth, sizingTransform } from '../sizing';\nconst defaultSxConfig = {\n // borders\n border: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderTop: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderRight: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderBottom: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderLeft: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderColor: {\n themeKey: 'palette'\n },\n borderTopColor: {\n themeKey: 'palette'\n },\n borderRightColor: {\n themeKey: 'palette'\n },\n borderBottomColor: {\n themeKey: 'palette'\n },\n borderLeftColor: {\n themeKey: 'palette'\n },\n outline: {\n themeKey: 'borders',\n transform: borderTransform\n },\n outlineColor: {\n themeKey: 'palette'\n },\n borderRadius: {\n themeKey: 'shape.borderRadius',\n style: borderRadius\n },\n // palette\n color: {\n themeKey: 'palette',\n transform: paletteTransform\n },\n bgcolor: {\n themeKey: 'palette',\n cssProperty: 'backgroundColor',\n transform: paletteTransform\n },\n backgroundColor: {\n themeKey: 'palette',\n transform: paletteTransform\n },\n // spacing\n p: {\n style: padding\n },\n pt: {\n style: padding\n },\n pr: {\n style: padding\n },\n pb: {\n style: padding\n },\n pl: {\n style: padding\n },\n px: {\n style: padding\n },\n py: {\n style: padding\n },\n padding: {\n style: padding\n },\n paddingTop: {\n style: padding\n },\n paddingRight: {\n style: padding\n },\n paddingBottom: {\n style: padding\n },\n paddingLeft: {\n style: padding\n },\n paddingX: {\n style: padding\n },\n paddingY: {\n style: padding\n },\n paddingInline: {\n style: padding\n },\n paddingInlineStart: {\n style: padding\n },\n paddingInlineEnd: {\n style: padding\n },\n paddingBlock: {\n style: padding\n },\n paddingBlockStart: {\n style: padding\n },\n paddingBlockEnd: {\n style: padding\n },\n m: {\n style: margin\n },\n mt: {\n style: margin\n },\n mr: {\n style: margin\n },\n mb: {\n style: margin\n },\n ml: {\n style: margin\n },\n mx: {\n style: margin\n },\n my: {\n style: margin\n },\n margin: {\n style: margin\n },\n marginTop: {\n style: margin\n },\n marginRight: {\n style: margin\n },\n marginBottom: {\n style: margin\n },\n marginLeft: {\n style: margin\n },\n marginX: {\n style: margin\n },\n marginY: {\n style: margin\n },\n marginInline: {\n style: margin\n },\n marginInlineStart: {\n style: margin\n },\n marginInlineEnd: {\n style: margin\n },\n marginBlock: {\n style: margin\n },\n marginBlockStart: {\n style: margin\n },\n marginBlockEnd: {\n style: margin\n },\n // display\n displayPrint: {\n cssProperty: false,\n transform: value => ({\n '@media print': {\n display: value\n }\n })\n },\n display: {},\n overflow: {},\n textOverflow: {},\n visibility: {},\n whiteSpace: {},\n // flexbox\n flexBasis: {},\n flexDirection: {},\n flexWrap: {},\n justifyContent: {},\n alignItems: {},\n alignContent: {},\n order: {},\n flex: {},\n flexGrow: {},\n flexShrink: {},\n alignSelf: {},\n justifyItems: {},\n justifySelf: {},\n // grid\n gap: {\n style: gap\n },\n rowGap: {\n style: rowGap\n },\n columnGap: {\n style: columnGap\n },\n gridColumn: {},\n gridRow: {},\n gridAutoFlow: {},\n gridAutoColumns: {},\n gridAutoRows: {},\n gridTemplateColumns: {},\n gridTemplateRows: {},\n gridTemplateAreas: {},\n gridArea: {},\n // positions\n position: {},\n zIndex: {\n themeKey: 'zIndex'\n },\n top: {},\n right: {},\n bottom: {},\n left: {},\n // shadows\n boxShadow: {\n themeKey: 'shadows'\n },\n // sizing\n width: {\n transform: sizingTransform\n },\n maxWidth: {\n style: maxWidth\n },\n minWidth: {\n transform: sizingTransform\n },\n height: {\n transform: sizingTransform\n },\n maxHeight: {\n transform: sizingTransform\n },\n minHeight: {\n transform: sizingTransform\n },\n boxSizing: {},\n // typography\n fontFamily: {\n themeKey: 'typography'\n },\n fontSize: {\n themeKey: 'typography'\n },\n fontStyle: {\n themeKey: 'typography'\n },\n fontWeight: {\n themeKey: 'typography'\n },\n letterSpacing: {},\n textTransform: {},\n lineHeight: {},\n textAlign: {},\n typography: {\n cssProperty: false,\n themeKey: 'typography'\n }\n};\nexport default defaultSxConfig;","import capitalize from '@mui/utils/capitalize';\nimport merge from '../merge';\nimport { getPath, getStyleValue as getValue } from '../style';\nimport { handleBreakpoints, createEmptyBreakpointObject, removeUnusedBreakpoints } from '../breakpoints';\nimport defaultSxConfig from './defaultSxConfig';\nfunction objectsHaveSameKeys(...objects) {\n const allKeys = objects.reduce((keys, object) => keys.concat(Object.keys(object)), []);\n const union = new Set(allKeys);\n return objects.every(object => union.size === Object.keys(object).length);\n}\nfunction callIfFn(maybeFn, arg) {\n return typeof maybeFn === 'function' ? maybeFn(arg) : maybeFn;\n}\n\n// eslint-disable-next-line @typescript-eslint/naming-convention\nexport function unstable_createStyleFunctionSx() {\n function getThemeValue(prop, val, theme, config) {\n const props = {\n [prop]: val,\n theme\n };\n const options = config[prop];\n if (!options) {\n return {\n [prop]: val\n };\n }\n const {\n cssProperty = prop,\n themeKey,\n transform,\n style\n } = options;\n if (val == null) {\n return null;\n }\n\n // TODO v6: remove, see https://github.com/mui/material-ui/pull/38123\n if (themeKey === 'typography' && val === 'inherit') {\n return {\n [prop]: val\n };\n }\n const themeMapping = getPath(theme, themeKey) || {};\n if (style) {\n return style(props);\n }\n const styleFromPropValue = propValueFinal => {\n let value = getValue(themeMapping, transform, propValueFinal);\n if (propValueFinal === value && typeof propValueFinal === 'string') {\n // Haven't found value\n value = getValue(themeMapping, transform, `${prop}${propValueFinal === 'default' ? '' : capitalize(propValueFinal)}`, propValueFinal);\n }\n if (cssProperty === false) {\n return value;\n }\n return {\n [cssProperty]: value\n };\n };\n return handleBreakpoints(props, val, styleFromPropValue);\n }\n function styleFunctionSx(props) {\n var _theme$unstable_sxCon;\n const {\n sx,\n theme = {}\n } = props || {};\n if (!sx) {\n return null; // Emotion & styled-components will neglect null\n }\n const config = (_theme$unstable_sxCon = theme.unstable_sxConfig) != null ? _theme$unstable_sxCon : defaultSxConfig;\n\n /*\n * Receive `sxInput` as object or callback\n * and then recursively check keys & values to create media query object styles.\n * (the result will be used in `styled`)\n */\n function traverse(sxInput) {\n let sxObject = sxInput;\n if (typeof sxInput === 'function') {\n sxObject = sxInput(theme);\n } else if (typeof sxInput !== 'object') {\n // value\n return sxInput;\n }\n if (!sxObject) {\n return null;\n }\n const emptyBreakpoints = createEmptyBreakpointObject(theme.breakpoints);\n const breakpointsKeys = Object.keys(emptyBreakpoints);\n let css = emptyBreakpoints;\n Object.keys(sxObject).forEach(styleKey => {\n const value = callIfFn(sxObject[styleKey], theme);\n if (value !== null && value !== undefined) {\n if (typeof value === 'object') {\n if (config[styleKey]) {\n css = merge(css, getThemeValue(styleKey, value, theme, config));\n } else {\n const breakpointsValues = handleBreakpoints({\n theme\n }, value, x => ({\n [styleKey]: x\n }));\n if (objectsHaveSameKeys(breakpointsValues, value)) {\n css[styleKey] = styleFunctionSx({\n sx: value,\n theme\n });\n } else {\n css = merge(css, breakpointsValues);\n }\n }\n } else {\n css = merge(css, getThemeValue(styleKey, value, theme, config));\n }\n }\n });\n return removeUnusedBreakpoints(breakpointsKeys, css);\n }\n return Array.isArray(sx) ? sx.map(traverse) : traverse(sx);\n }\n return styleFunctionSx;\n}\nconst styleFunctionSx = unstable_createStyleFunctionSx();\nstyleFunctionSx.filterProps = ['sx'];\nexport default styleFunctionSx;","/**\n * A universal utility to style components with multiple color modes. Always use it from the theme object.\n * It works with:\n * - [Basic theme](https://mui.com/material-ui/customization/dark-mode/)\n * - [CSS theme variables](https://mui.com/material-ui/experimental-api/css-theme-variables/overview/)\n * - Zero-runtime engine\n *\n * Tips: Use an array over object spread and place `theme.applyStyles()` last.\n *\n * ✅ [{ background: '#e5e5e5' }, theme.applyStyles('dark', { background: '#1c1c1c' })]\n *\n * 🚫 { background: '#e5e5e5', ...theme.applyStyles('dark', { background: '#1c1c1c' })}\n *\n * @example\n * 1. using with `styled`:\n * ```jsx\n * const Component = styled('div')(({ theme }) => [\n * { background: '#e5e5e5' },\n * theme.applyStyles('dark', {\n * background: '#1c1c1c',\n * color: '#fff',\n * }),\n * ]);\n * ```\n *\n * @example\n * 2. using with `sx` prop:\n * ```jsx\n * [\n * { background: '#e5e5e5' },\n * theme.applyStyles('dark', {\n * background: '#1c1c1c',\n * color: '#fff',\n * }),\n * ]}\n * />\n * ```\n *\n * @example\n * 3. theming a component:\n * ```jsx\n * extendTheme({\n * components: {\n * MuiButton: {\n * styleOverrides: {\n * root: ({ theme }) => [\n * { background: '#e5e5e5' },\n * theme.applyStyles('dark', {\n * background: '#1c1c1c',\n * color: '#fff',\n * }),\n * ],\n * },\n * }\n * }\n * })\n *```\n */\nexport default function applyStyles(key, styles) {\n // @ts-expect-error this is 'any' type\n const theme = this;\n if (theme.vars && typeof theme.getColorSchemeSelector === 'function') {\n // If CssVarsProvider is used as a provider,\n // returns '* :where([data-mui-color-scheme=\"light|dark\"]) &'\n const selector = theme.getColorSchemeSelector(key).replace(/(\\[[^\\]]+\\])/, '*:where($1)');\n return {\n [selector]: styles\n };\n }\n if (theme.palette.mode === key) {\n return styles;\n }\n return {};\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"breakpoints\", \"palette\", \"spacing\", \"shape\"];\nimport deepmerge from '@mui/utils/deepmerge';\nimport createBreakpoints from './createBreakpoints';\nimport shape from './shape';\nimport createSpacing from './createSpacing';\nimport styleFunctionSx from '../styleFunctionSx/styleFunctionSx';\nimport defaultSxConfig from '../styleFunctionSx/defaultSxConfig';\nimport applyStyles from './applyStyles';\nfunction createTheme(options = {}, ...args) {\n const {\n breakpoints: breakpointsInput = {},\n palette: paletteInput = {},\n spacing: spacingInput,\n shape: shapeInput = {}\n } = options,\n other = _objectWithoutPropertiesLoose(options, _excluded);\n const breakpoints = createBreakpoints(breakpointsInput);\n const spacing = createSpacing(spacingInput);\n let muiTheme = deepmerge({\n breakpoints,\n direction: 'ltr',\n components: {},\n // Inject component definitions.\n palette: _extends({\n mode: 'light'\n }, paletteInput),\n spacing,\n shape: _extends({}, shape, shapeInput)\n }, other);\n muiTheme.applyStyles = applyStyles;\n muiTheme = args.reduce((acc, argument) => deepmerge(acc, argument), muiTheme);\n muiTheme.unstable_sxConfig = _extends({}, defaultSxConfig, other == null ? void 0 : other.unstable_sxConfig);\n muiTheme.unstable_sx = function sx(props) {\n return styleFunctionSx({\n sx: props,\n theme: this\n });\n };\n return muiTheme;\n}\nexport default createTheme;","'use client';\n\nimport * as React from 'react';\nimport { ThemeContext } from '@mui/styled-engine';\nfunction isObjectEmpty(obj) {\n return Object.keys(obj).length === 0;\n}\nfunction useTheme(defaultTheme = null) {\n const contextTheme = React.useContext(ThemeContext);\n return !contextTheme || isObjectEmpty(contextTheme) ? defaultTheme : contextTheme;\n}\nexport default useTheme;","'use client';\n\nimport createTheme from './createTheme';\nimport useThemeWithoutDefault from './useThemeWithoutDefault';\nexport const systemDefaultTheme = createTheme();\nfunction useTheme(defaultTheme = systemDefaultTheme) {\n return useThemeWithoutDefault(defaultTheme);\n}\nexport default useTheme;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"ownerState\"],\n _excluded2 = [\"variants\"],\n _excluded3 = [\"name\", \"slot\", \"skipVariantsResolver\", \"skipSx\", \"overridesResolver\"];\n/* eslint-disable no-underscore-dangle */\nimport styledEngineStyled, { internal_processStyles as processStyles } from '@mui/styled-engine';\nimport { isPlainObject } from '@mui/utils/deepmerge';\nimport capitalize from '@mui/utils/capitalize';\nimport getDisplayName from '@mui/utils/getDisplayName';\nimport createTheme from './createTheme';\nimport styleFunctionSx from './styleFunctionSx';\nfunction isEmpty(obj) {\n return Object.keys(obj).length === 0;\n}\n\n// https://github.com/emotion-js/emotion/blob/26ded6109fcd8ca9875cc2ce4564fee678a3f3c5/packages/styled/src/utils.js#L40\nfunction isStringTag(tag) {\n return typeof tag === 'string' &&\n // 96 is one less than the char code\n // for \"a\" so this is checking that\n // it's a lowercase character\n tag.charCodeAt(0) > 96;\n}\n\n// Update /system/styled/#api in case if this changes\nexport function shouldForwardProp(prop) {\n return prop !== 'ownerState' && prop !== 'theme' && prop !== 'sx' && prop !== 'as';\n}\nexport const systemDefaultTheme = createTheme();\nconst lowercaseFirstLetter = string => {\n if (!string) {\n return string;\n }\n return string.charAt(0).toLowerCase() + string.slice(1);\n};\nfunction resolveTheme({\n defaultTheme,\n theme,\n themeId\n}) {\n return isEmpty(theme) ? defaultTheme : theme[themeId] || theme;\n}\nfunction defaultOverridesResolver(slot) {\n if (!slot) {\n return null;\n }\n return (props, styles) => styles[slot];\n}\nfunction processStyleArg(callableStyle, _ref) {\n let {\n ownerState\n } = _ref,\n props = _objectWithoutPropertiesLoose(_ref, _excluded);\n const resolvedStylesArg = typeof callableStyle === 'function' ? callableStyle(_extends({\n ownerState\n }, props)) : callableStyle;\n if (Array.isArray(resolvedStylesArg)) {\n return resolvedStylesArg.flatMap(resolvedStyle => processStyleArg(resolvedStyle, _extends({\n ownerState\n }, props)));\n }\n if (!!resolvedStylesArg && typeof resolvedStylesArg === 'object' && Array.isArray(resolvedStylesArg.variants)) {\n const {\n variants = []\n } = resolvedStylesArg,\n otherStyles = _objectWithoutPropertiesLoose(resolvedStylesArg, _excluded2);\n let result = otherStyles;\n variants.forEach(variant => {\n let isMatch = true;\n if (typeof variant.props === 'function') {\n isMatch = variant.props(_extends({\n ownerState\n }, props, ownerState));\n } else {\n Object.keys(variant.props).forEach(key => {\n if ((ownerState == null ? void 0 : ownerState[key]) !== variant.props[key] && props[key] !== variant.props[key]) {\n isMatch = false;\n }\n });\n }\n if (isMatch) {\n if (!Array.isArray(result)) {\n result = [result];\n }\n result.push(typeof variant.style === 'function' ? variant.style(_extends({\n ownerState\n }, props, ownerState)) : variant.style);\n }\n });\n return result;\n }\n return resolvedStylesArg;\n}\nexport default function createStyled(input = {}) {\n const {\n themeId,\n defaultTheme = systemDefaultTheme,\n rootShouldForwardProp = shouldForwardProp,\n slotShouldForwardProp = shouldForwardProp\n } = input;\n const systemSx = props => {\n return styleFunctionSx(_extends({}, props, {\n theme: resolveTheme(_extends({}, props, {\n defaultTheme,\n themeId\n }))\n }));\n };\n systemSx.__mui_systemSx = true;\n return (tag, inputOptions = {}) => {\n // Filter out the `sx` style function from the previous styled component to prevent unnecessary styles generated by the composite components.\n processStyles(tag, styles => styles.filter(style => !(style != null && style.__mui_systemSx)));\n const {\n name: componentName,\n slot: componentSlot,\n skipVariantsResolver: inputSkipVariantsResolver,\n skipSx: inputSkipSx,\n // TODO v6: remove `lowercaseFirstLetter()` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n overridesResolver = defaultOverridesResolver(lowercaseFirstLetter(componentSlot))\n } = inputOptions,\n options = _objectWithoutPropertiesLoose(inputOptions, _excluded3);\n\n // if skipVariantsResolver option is defined, take the value, otherwise, true for root and false for other slots.\n const skipVariantsResolver = inputSkipVariantsResolver !== undefined ? inputSkipVariantsResolver :\n // TODO v6: remove `Root` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n componentSlot && componentSlot !== 'Root' && componentSlot !== 'root' || false;\n const skipSx = inputSkipSx || false;\n let label;\n if (process.env.NODE_ENV !== 'production') {\n if (componentName) {\n // TODO v6: remove `lowercaseFirstLetter()` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n label = `${componentName}-${lowercaseFirstLetter(componentSlot || 'Root')}`;\n }\n }\n let shouldForwardPropOption = shouldForwardProp;\n\n // TODO v6: remove `Root` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n if (componentSlot === 'Root' || componentSlot === 'root') {\n shouldForwardPropOption = rootShouldForwardProp;\n } else if (componentSlot) {\n // any other slot specified\n shouldForwardPropOption = slotShouldForwardProp;\n } else if (isStringTag(tag)) {\n // for string (html) tag, preserve the behavior in emotion & styled-components.\n shouldForwardPropOption = undefined;\n }\n const defaultStyledResolver = styledEngineStyled(tag, _extends({\n shouldForwardProp: shouldForwardPropOption,\n label\n }, options));\n const transformStyleArg = stylesArg => {\n // On the server Emotion doesn't use React.forwardRef for creating components, so the created\n // component stays as a function. This condition makes sure that we do not interpolate functions\n // which are basically components used as a selectors.\n if (typeof stylesArg === 'function' && stylesArg.__emotion_real !== stylesArg || isPlainObject(stylesArg)) {\n return props => processStyleArg(stylesArg, _extends({}, props, {\n theme: resolveTheme({\n theme: props.theme,\n defaultTheme,\n themeId\n })\n }));\n }\n return stylesArg;\n };\n const muiStyledResolver = (styleArg, ...expressions) => {\n let transformedStyleArg = transformStyleArg(styleArg);\n const expressionsWithDefaultTheme = expressions ? expressions.map(transformStyleArg) : [];\n if (componentName && overridesResolver) {\n expressionsWithDefaultTheme.push(props => {\n const theme = resolveTheme(_extends({}, props, {\n defaultTheme,\n themeId\n }));\n if (!theme.components || !theme.components[componentName] || !theme.components[componentName].styleOverrides) {\n return null;\n }\n const styleOverrides = theme.components[componentName].styleOverrides;\n const resolvedStyleOverrides = {};\n // TODO: v7 remove iteration and use `resolveStyleArg(styleOverrides[slot])` directly\n Object.entries(styleOverrides).forEach(([slotKey, slotStyle]) => {\n resolvedStyleOverrides[slotKey] = processStyleArg(slotStyle, _extends({}, props, {\n theme\n }));\n });\n return overridesResolver(props, resolvedStyleOverrides);\n });\n }\n if (componentName && !skipVariantsResolver) {\n expressionsWithDefaultTheme.push(props => {\n var _theme$components;\n const theme = resolveTheme(_extends({}, props, {\n defaultTheme,\n themeId\n }));\n const themeVariants = theme == null || (_theme$components = theme.components) == null || (_theme$components = _theme$components[componentName]) == null ? void 0 : _theme$components.variants;\n return processStyleArg({\n variants: themeVariants\n }, _extends({}, props, {\n theme\n }));\n });\n }\n if (!skipSx) {\n expressionsWithDefaultTheme.push(systemSx);\n }\n const numOfCustomFnsApplied = expressionsWithDefaultTheme.length - expressions.length;\n if (Array.isArray(styleArg) && numOfCustomFnsApplied > 0) {\n const placeholders = new Array(numOfCustomFnsApplied).fill('');\n // If the type is array, than we need to add placeholders in the template for the overrides, variants and the sx styles.\n transformedStyleArg = [...styleArg, ...placeholders];\n transformedStyleArg.raw = [...styleArg.raw, ...placeholders];\n }\n const Component = defaultStyledResolver(transformedStyleArg, ...expressionsWithDefaultTheme);\n if (process.env.NODE_ENV !== 'production') {\n let displayName;\n if (componentName) {\n displayName = `${componentName}${capitalize(componentSlot || '')}`;\n }\n if (displayName === undefined) {\n displayName = `Styled(${getDisplayName(tag)})`;\n }\n Component.displayName = displayName;\n }\n if (tag.muiName) {\n Component.muiName = tag.muiName;\n }\n return Component;\n };\n if (defaultStyledResolver.withConfig) {\n muiStyledResolver.withConfig = defaultStyledResolver.withConfig;\n }\n return muiStyledResolver;\n };\n}","import resolveProps from '@mui/utils/resolveProps';\nexport default function getThemeProps(params) {\n const {\n theme,\n name,\n props\n } = params;\n if (!theme || !theme.components || !theme.components[name] || !theme.components[name].defaultProps) {\n return props;\n }\n return resolveProps(theme.components[name].defaultProps, props);\n}","'use client';\n\nimport getThemeProps from './getThemeProps';\nimport useTheme from '../useTheme';\nexport default function useThemeProps({\n props,\n name,\n defaultTheme,\n themeId\n}) {\n let theme = useTheme(defaultTheme);\n if (themeId) {\n theme = theme[themeId] || theme;\n }\n const mergedProps = getThemeProps({\n theme,\n name,\n props\n });\n return mergedProps;\n}","import _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\n/* eslint-disable @typescript-eslint/naming-convention */\nimport clamp from '@mui/utils/clamp';\n/**\n * Returns a number whose value is limited to the given range.\n * @param {number} value The value to be clamped\n * @param {number} min The lower boundary of the output range\n * @param {number} max The upper boundary of the output range\n * @returns {number} A number in the range [min, max]\n */\nfunction clampWrapper(value, min = 0, max = 1) {\n if (process.env.NODE_ENV !== 'production') {\n if (value < min || value > max) {\n console.error(`MUI: The value provided ${value} is out of range [${min}, ${max}].`);\n }\n }\n return clamp(value, min, max);\n}\n\n/**\n * Converts a color from CSS hex format to CSS rgb format.\n * @param {string} color - Hex color, i.e. #nnn or #nnnnnn\n * @returns {string} A CSS rgb color string\n */\nexport function hexToRgb(color) {\n color = color.slice(1);\n const re = new RegExp(`.{1,${color.length >= 6 ? 2 : 1}}`, 'g');\n let colors = color.match(re);\n if (colors && colors[0].length === 1) {\n colors = colors.map(n => n + n);\n }\n return colors ? `rgb${colors.length === 4 ? 'a' : ''}(${colors.map((n, index) => {\n return index < 3 ? parseInt(n, 16) : Math.round(parseInt(n, 16) / 255 * 1000) / 1000;\n }).join(', ')})` : '';\n}\nfunction intToHex(int) {\n const hex = int.toString(16);\n return hex.length === 1 ? `0${hex}` : hex;\n}\n\n/**\n * Returns an object with the type and values of a color.\n *\n * Note: Does not support rgb % values.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @returns {object} - A MUI color object: {type: string, values: number[]}\n */\nexport function decomposeColor(color) {\n // Idempotent\n if (color.type) {\n return color;\n }\n if (color.charAt(0) === '#') {\n return decomposeColor(hexToRgb(color));\n }\n const marker = color.indexOf('(');\n const type = color.substring(0, marker);\n if (['rgb', 'rgba', 'hsl', 'hsla', 'color'].indexOf(type) === -1) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: Unsupported \\`${color}\\` color.\nThe following formats are supported: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color().` : _formatMuiErrorMessage(9, color));\n }\n let values = color.substring(marker + 1, color.length - 1);\n let colorSpace;\n if (type === 'color') {\n values = values.split(' ');\n colorSpace = values.shift();\n if (values.length === 4 && values[3].charAt(0) === '/') {\n values[3] = values[3].slice(1);\n }\n if (['srgb', 'display-p3', 'a98-rgb', 'prophoto-rgb', 'rec-2020'].indexOf(colorSpace) === -1) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: unsupported \\`${colorSpace}\\` color space.\nThe following color spaces are supported: srgb, display-p3, a98-rgb, prophoto-rgb, rec-2020.` : _formatMuiErrorMessage(10, colorSpace));\n }\n } else {\n values = values.split(',');\n }\n values = values.map(value => parseFloat(value));\n return {\n type,\n values,\n colorSpace\n };\n}\n\n/**\n * Returns a channel created from the input color.\n *\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @returns {string} - The channel for the color, that can be used in rgba or hsla colors\n */\nexport const colorChannel = color => {\n const decomposedColor = decomposeColor(color);\n return decomposedColor.values.slice(0, 3).map((val, idx) => decomposedColor.type.indexOf('hsl') !== -1 && idx !== 0 ? `${val}%` : val).join(' ');\n};\nexport const private_safeColorChannel = (color, warning) => {\n try {\n return colorChannel(color);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n};\n\n/**\n * Converts a color object with type and values to a string.\n * @param {object} color - Decomposed color\n * @param {string} color.type - One of: 'rgb', 'rgba', 'hsl', 'hsla', 'color'\n * @param {array} color.values - [n,n,n] or [n,n,n,n]\n * @returns {string} A CSS color string\n */\nexport function recomposeColor(color) {\n const {\n type,\n colorSpace\n } = color;\n let {\n values\n } = color;\n if (type.indexOf('rgb') !== -1) {\n // Only convert the first 3 values to int (i.e. not alpha)\n values = values.map((n, i) => i < 3 ? parseInt(n, 10) : n);\n } else if (type.indexOf('hsl') !== -1) {\n values[1] = `${values[1]}%`;\n values[2] = `${values[2]}%`;\n }\n if (type.indexOf('color') !== -1) {\n values = `${colorSpace} ${values.join(' ')}`;\n } else {\n values = `${values.join(', ')}`;\n }\n return `${type}(${values})`;\n}\n\n/**\n * Converts a color from CSS rgb format to CSS hex format.\n * @param {string} color - RGB color, i.e. rgb(n, n, n)\n * @returns {string} A CSS rgb color string, i.e. #nnnnnn\n */\nexport function rgbToHex(color) {\n // Idempotent\n if (color.indexOf('#') === 0) {\n return color;\n }\n const {\n values\n } = decomposeColor(color);\n return `#${values.map((n, i) => intToHex(i === 3 ? Math.round(255 * n) : n)).join('')}`;\n}\n\n/**\n * Converts a color from hsl format to rgb format.\n * @param {string} color - HSL color values\n * @returns {string} rgb color values\n */\nexport function hslToRgb(color) {\n color = decomposeColor(color);\n const {\n values\n } = color;\n const h = values[0];\n const s = values[1] / 100;\n const l = values[2] / 100;\n const a = s * Math.min(l, 1 - l);\n const f = (n, k = (n + h / 30) % 12) => l - a * Math.max(Math.min(k - 3, 9 - k, 1), -1);\n let type = 'rgb';\n const rgb = [Math.round(f(0) * 255), Math.round(f(8) * 255), Math.round(f(4) * 255)];\n if (color.type === 'hsla') {\n type += 'a';\n rgb.push(values[3]);\n }\n return recomposeColor({\n type,\n values: rgb\n });\n}\n/**\n * The relative brightness of any point in a color space,\n * normalized to 0 for darkest black and 1 for lightest white.\n *\n * Formula: https://www.w3.org/TR/WCAG20-TECHS/G17.html#G17-tests\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @returns {number} The relative brightness of the color in the range 0 - 1\n */\nexport function getLuminance(color) {\n color = decomposeColor(color);\n let rgb = color.type === 'hsl' || color.type === 'hsla' ? decomposeColor(hslToRgb(color)).values : color.values;\n rgb = rgb.map(val => {\n if (color.type !== 'color') {\n val /= 255; // normalized\n }\n return val <= 0.03928 ? val / 12.92 : ((val + 0.055) / 1.055) ** 2.4;\n });\n\n // Truncate at 3 digits\n return Number((0.2126 * rgb[0] + 0.7152 * rgb[1] + 0.0722 * rgb[2]).toFixed(3));\n}\n\n/**\n * Calculates the contrast ratio between two colors.\n *\n * Formula: https://www.w3.org/TR/WCAG20-TECHS/G17.html#G17-tests\n * @param {string} foreground - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla()\n * @param {string} background - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla()\n * @returns {number} A contrast ratio value in the range 0 - 21.\n */\nexport function getContrastRatio(foreground, background) {\n const lumA = getLuminance(foreground);\n const lumB = getLuminance(background);\n return (Math.max(lumA, lumB) + 0.05) / (Math.min(lumA, lumB) + 0.05);\n}\n\n/**\n * Sets the absolute transparency of a color.\n * Any existing alpha values are overwritten.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} value - value to set the alpha channel to in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function alpha(color, value) {\n color = decomposeColor(color);\n value = clampWrapper(value);\n if (color.type === 'rgb' || color.type === 'hsl') {\n color.type += 'a';\n }\n if (color.type === 'color') {\n color.values[3] = `/${value}`;\n } else {\n color.values[3] = value;\n }\n return recomposeColor(color);\n}\nexport function private_safeAlpha(color, value, warning) {\n try {\n return alpha(color, value);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Darkens a color.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} coefficient - multiplier in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function darken(color, coefficient) {\n color = decomposeColor(color);\n coefficient = clampWrapper(coefficient);\n if (color.type.indexOf('hsl') !== -1) {\n color.values[2] *= 1 - coefficient;\n } else if (color.type.indexOf('rgb') !== -1 || color.type.indexOf('color') !== -1) {\n for (let i = 0; i < 3; i += 1) {\n color.values[i] *= 1 - coefficient;\n }\n }\n return recomposeColor(color);\n}\nexport function private_safeDarken(color, coefficient, warning) {\n try {\n return darken(color, coefficient);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Lightens a color.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} coefficient - multiplier in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function lighten(color, coefficient) {\n color = decomposeColor(color);\n coefficient = clampWrapper(coefficient);\n if (color.type.indexOf('hsl') !== -1) {\n color.values[2] += (100 - color.values[2]) * coefficient;\n } else if (color.type.indexOf('rgb') !== -1) {\n for (let i = 0; i < 3; i += 1) {\n color.values[i] += (255 - color.values[i]) * coefficient;\n }\n } else if (color.type.indexOf('color') !== -1) {\n for (let i = 0; i < 3; i += 1) {\n color.values[i] += (1 - color.values[i]) * coefficient;\n }\n }\n return recomposeColor(color);\n}\nexport function private_safeLighten(color, coefficient, warning) {\n try {\n return lighten(color, coefficient);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Darken or lighten a color, depending on its luminance.\n * Light colors are darkened, dark colors are lightened.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} coefficient=0.15 - multiplier in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function emphasize(color, coefficient = 0.15) {\n return getLuminance(color) > 0.5 ? darken(color, coefficient) : lighten(color, coefficient);\n}\nexport function private_safeEmphasize(color, coefficient, warning) {\n try {\n return emphasize(color, coefficient);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Blend a transparent overlay color with a background color, resulting in a single\n * RGB color.\n * @param {string} background - CSS color\n * @param {string} overlay - CSS color\n * @param {number} opacity - Opacity multiplier in the range 0 - 1\n * @param {number} [gamma=1.0] - Gamma correction factor. For gamma-correct blending, 2.2 is usual.\n */\nexport function blend(background, overlay, opacity, gamma = 1.0) {\n const blendChannel = (b, o) => Math.round((b ** (1 / gamma) * (1 - opacity) + o ** (1 / gamma) * opacity) ** gamma);\n const backgroundColor = decomposeColor(background);\n const overlayColor = decomposeColor(overlay);\n const rgb = [blendChannel(backgroundColor.values[0], overlayColor.values[0]), blendChannel(backgroundColor.values[1], overlayColor.values[1]), blendChannel(backgroundColor.values[2], overlayColor.values[2])];\n return recomposeColor({\n type: 'rgb',\n values: rgb\n });\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nexport default function createMixins(breakpoints, mixins) {\n return _extends({\n toolbar: {\n minHeight: 56,\n [breakpoints.up('xs')]: {\n '@media (orientation: landscape)': {\n minHeight: 48\n }\n },\n [breakpoints.up('sm')]: {\n minHeight: 64\n }\n }\n }, mixins);\n}","const common = {\n black: '#000',\n white: '#fff'\n};\nexport default common;","const grey = {\n 50: '#fafafa',\n 100: '#f5f5f5',\n 200: '#eeeeee',\n 300: '#e0e0e0',\n 400: '#bdbdbd',\n 500: '#9e9e9e',\n 600: '#757575',\n 700: '#616161',\n 800: '#424242',\n 900: '#212121',\n A100: '#f5f5f5',\n A200: '#eeeeee',\n A400: '#bdbdbd',\n A700: '#616161'\n};\nexport default grey;","const purple = {\n 50: '#f3e5f5',\n 100: '#e1bee7',\n 200: '#ce93d8',\n 300: '#ba68c8',\n 400: '#ab47bc',\n 500: '#9c27b0',\n 600: '#8e24aa',\n 700: '#7b1fa2',\n 800: '#6a1b9a',\n 900: '#4a148c',\n A100: '#ea80fc',\n A200: '#e040fb',\n A400: '#d500f9',\n A700: '#aa00ff'\n};\nexport default purple;","const red = {\n 50: '#ffebee',\n 100: '#ffcdd2',\n 200: '#ef9a9a',\n 300: '#e57373',\n 400: '#ef5350',\n 500: '#f44336',\n 600: '#e53935',\n 700: '#d32f2f',\n 800: '#c62828',\n 900: '#b71c1c',\n A100: '#ff8a80',\n A200: '#ff5252',\n A400: '#ff1744',\n A700: '#d50000'\n};\nexport default red;","const orange = {\n 50: '#fff3e0',\n 100: '#ffe0b2',\n 200: '#ffcc80',\n 300: '#ffb74d',\n 400: '#ffa726',\n 500: '#ff9800',\n 600: '#fb8c00',\n 700: '#f57c00',\n 800: '#ef6c00',\n 900: '#e65100',\n A100: '#ffd180',\n A200: '#ffab40',\n A400: '#ff9100',\n A700: '#ff6d00'\n};\nexport default orange;","const blue = {\n 50: '#e3f2fd',\n 100: '#bbdefb',\n 200: '#90caf9',\n 300: '#64b5f6',\n 400: '#42a5f5',\n 500: '#2196f3',\n 600: '#1e88e5',\n 700: '#1976d2',\n 800: '#1565c0',\n 900: '#0d47a1',\n A100: '#82b1ff',\n A200: '#448aff',\n A400: '#2979ff',\n A700: '#2962ff'\n};\nexport default blue;","const lightBlue = {\n 50: '#e1f5fe',\n 100: '#b3e5fc',\n 200: '#81d4fa',\n 300: '#4fc3f7',\n 400: '#29b6f6',\n 500: '#03a9f4',\n 600: '#039be5',\n 700: '#0288d1',\n 800: '#0277bd',\n 900: '#01579b',\n A100: '#80d8ff',\n A200: '#40c4ff',\n A400: '#00b0ff',\n A700: '#0091ea'\n};\nexport default lightBlue;","const green = {\n 50: '#e8f5e9',\n 100: '#c8e6c9',\n 200: '#a5d6a7',\n 300: '#81c784',\n 400: '#66bb6a',\n 500: '#4caf50',\n 600: '#43a047',\n 700: '#388e3c',\n 800: '#2e7d32',\n 900: '#1b5e20',\n A100: '#b9f6ca',\n A200: '#69f0ae',\n A400: '#00e676',\n A700: '#00c853'\n};\nexport default green;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\nconst _excluded = [\"mode\", \"contrastThreshold\", \"tonalOffset\"];\nimport { deepmerge } from '@mui/utils';\nimport { darken, getContrastRatio, lighten } from '@mui/system';\nimport common from '../colors/common';\nimport grey from '../colors/grey';\nimport purple from '../colors/purple';\nimport red from '../colors/red';\nimport orange from '../colors/orange';\nimport blue from '../colors/blue';\nimport lightBlue from '../colors/lightBlue';\nimport green from '../colors/green';\nexport const light = {\n // The colors used to style the text.\n text: {\n // The most important text.\n primary: 'rgba(0, 0, 0, 0.87)',\n // Secondary text.\n secondary: 'rgba(0, 0, 0, 0.6)',\n // Disabled text have even lower visual prominence.\n disabled: 'rgba(0, 0, 0, 0.38)'\n },\n // The color used to divide different elements.\n divider: 'rgba(0, 0, 0, 0.12)',\n // The background colors used to style the surfaces.\n // Consistency between these values is important.\n background: {\n paper: common.white,\n default: common.white\n },\n // The colors used to style the action elements.\n action: {\n // The color of an active action like an icon button.\n active: 'rgba(0, 0, 0, 0.54)',\n // The color of an hovered action.\n hover: 'rgba(0, 0, 0, 0.04)',\n hoverOpacity: 0.04,\n // The color of a selected action.\n selected: 'rgba(0, 0, 0, 0.08)',\n selectedOpacity: 0.08,\n // The color of a disabled action.\n disabled: 'rgba(0, 0, 0, 0.26)',\n // The background color of a disabled action.\n disabledBackground: 'rgba(0, 0, 0, 0.12)',\n disabledOpacity: 0.38,\n focus: 'rgba(0, 0, 0, 0.12)',\n focusOpacity: 0.12,\n activatedOpacity: 0.12\n }\n};\nexport const dark = {\n text: {\n primary: common.white,\n secondary: 'rgba(255, 255, 255, 0.7)',\n disabled: 'rgba(255, 255, 255, 0.5)',\n icon: 'rgba(255, 255, 255, 0.5)'\n },\n divider: 'rgba(255, 255, 255, 0.12)',\n background: {\n paper: '#121212',\n default: '#121212'\n },\n action: {\n active: common.white,\n hover: 'rgba(255, 255, 255, 0.08)',\n hoverOpacity: 0.08,\n selected: 'rgba(255, 255, 255, 0.16)',\n selectedOpacity: 0.16,\n disabled: 'rgba(255, 255, 255, 0.3)',\n disabledBackground: 'rgba(255, 255, 255, 0.12)',\n disabledOpacity: 0.38,\n focus: 'rgba(255, 255, 255, 0.12)',\n focusOpacity: 0.12,\n activatedOpacity: 0.24\n }\n};\nfunction addLightOrDark(intent, direction, shade, tonalOffset) {\n const tonalOffsetLight = tonalOffset.light || tonalOffset;\n const tonalOffsetDark = tonalOffset.dark || tonalOffset * 1.5;\n if (!intent[direction]) {\n if (intent.hasOwnProperty(shade)) {\n intent[direction] = intent[shade];\n } else if (direction === 'light') {\n intent.light = lighten(intent.main, tonalOffsetLight);\n } else if (direction === 'dark') {\n intent.dark = darken(intent.main, tonalOffsetDark);\n }\n }\n}\nfunction getDefaultPrimary(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: blue[200],\n light: blue[50],\n dark: blue[400]\n };\n }\n return {\n main: blue[700],\n light: blue[400],\n dark: blue[800]\n };\n}\nfunction getDefaultSecondary(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: purple[200],\n light: purple[50],\n dark: purple[400]\n };\n }\n return {\n main: purple[500],\n light: purple[300],\n dark: purple[700]\n };\n}\nfunction getDefaultError(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: red[500],\n light: red[300],\n dark: red[700]\n };\n }\n return {\n main: red[700],\n light: red[400],\n dark: red[800]\n };\n}\nfunction getDefaultInfo(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: lightBlue[400],\n light: lightBlue[300],\n dark: lightBlue[700]\n };\n }\n return {\n main: lightBlue[700],\n light: lightBlue[500],\n dark: lightBlue[900]\n };\n}\nfunction getDefaultSuccess(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: green[400],\n light: green[300],\n dark: green[700]\n };\n }\n return {\n main: green[800],\n light: green[500],\n dark: green[900]\n };\n}\nfunction getDefaultWarning(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: orange[400],\n light: orange[300],\n dark: orange[700]\n };\n }\n return {\n main: '#ed6c02',\n // closest to orange[800] that pass 3:1.\n light: orange[500],\n dark: orange[900]\n };\n}\nexport default function createPalette(palette) {\n const {\n mode = 'light',\n contrastThreshold = 3,\n tonalOffset = 0.2\n } = palette,\n other = _objectWithoutPropertiesLoose(palette, _excluded);\n const primary = palette.primary || getDefaultPrimary(mode);\n const secondary = palette.secondary || getDefaultSecondary(mode);\n const error = palette.error || getDefaultError(mode);\n const info = palette.info || getDefaultInfo(mode);\n const success = palette.success || getDefaultSuccess(mode);\n const warning = palette.warning || getDefaultWarning(mode);\n\n // Use the same logic as\n // Bootstrap: https://github.com/twbs/bootstrap/blob/1d6e3710dd447de1a200f29e8fa521f8a0908f70/scss/_functions.scss#L59\n // and material-components-web https://github.com/material-components/material-components-web/blob/ac46b8863c4dab9fc22c4c662dc6bd1b65dd652f/packages/mdc-theme/_functions.scss#L54\n function getContrastText(background) {\n const contrastText = getContrastRatio(background, dark.text.primary) >= contrastThreshold ? dark.text.primary : light.text.primary;\n if (process.env.NODE_ENV !== 'production') {\n const contrast = getContrastRatio(background, contrastText);\n if (contrast < 3) {\n console.error([`MUI: The contrast ratio of ${contrast}:1 for ${contrastText} on ${background}`, 'falls below the WCAG recommended absolute minimum contrast ratio of 3:1.', 'https://www.w3.org/TR/2008/REC-WCAG20-20081211/#visual-audio-contrast-contrast'].join('\\n'));\n }\n }\n return contrastText;\n }\n const augmentColor = ({\n color,\n name,\n mainShade = 500,\n lightShade = 300,\n darkShade = 700\n }) => {\n color = _extends({}, color);\n if (!color.main && color[mainShade]) {\n color.main = color[mainShade];\n }\n if (!color.hasOwnProperty('main')) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: The color${name ? ` (${name})` : ''} provided to augmentColor(color) is invalid.\nThe color object needs to have a \\`main\\` property or a \\`${mainShade}\\` property.` : _formatMuiErrorMessage(11, name ? ` (${name})` : '', mainShade));\n }\n if (typeof color.main !== 'string') {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: The color${name ? ` (${name})` : ''} provided to augmentColor(color) is invalid.\n\\`color.main\\` should be a string, but \\`${JSON.stringify(color.main)}\\` was provided instead.\n\nDid you intend to use one of the following approaches?\n\nimport { green } from \"@mui/material/colors\";\n\nconst theme1 = createTheme({ palette: {\n primary: green,\n} });\n\nconst theme2 = createTheme({ palette: {\n primary: { main: green[500] },\n} });` : _formatMuiErrorMessage(12, name ? ` (${name})` : '', JSON.stringify(color.main)));\n }\n addLightOrDark(color, 'light', lightShade, tonalOffset);\n addLightOrDark(color, 'dark', darkShade, tonalOffset);\n if (!color.contrastText) {\n color.contrastText = getContrastText(color.main);\n }\n return color;\n };\n const modes = {\n dark,\n light\n };\n if (process.env.NODE_ENV !== 'production') {\n if (!modes[mode]) {\n console.error(`MUI: The palette mode \\`${mode}\\` is not supported.`);\n }\n }\n const paletteOutput = deepmerge(_extends({\n // A collection of common colors.\n common: _extends({}, common),\n // prevent mutable object.\n // The palette mode, can be light or dark.\n mode,\n // The colors used to represent primary interface elements for a user.\n primary: augmentColor({\n color: primary,\n name: 'primary'\n }),\n // The colors used to represent secondary interface elements for a user.\n secondary: augmentColor({\n color: secondary,\n name: 'secondary',\n mainShade: 'A400',\n lightShade: 'A200',\n darkShade: 'A700'\n }),\n // The colors used to represent interface elements that the user should be made aware of.\n error: augmentColor({\n color: error,\n name: 'error'\n }),\n // The colors used to represent potentially dangerous actions or important messages.\n warning: augmentColor({\n color: warning,\n name: 'warning'\n }),\n // The colors used to present information to the user that is neutral and not necessarily important.\n info: augmentColor({\n color: info,\n name: 'info'\n }),\n // The colors used to indicate the successful completion of an action that user triggered.\n success: augmentColor({\n color: success,\n name: 'success'\n }),\n // The grey colors.\n grey,\n // Used by `getContrastText()` to maximize the contrast between\n // the background and the text.\n contrastThreshold,\n // Takes a background color and returns the text color that maximizes the contrast.\n getContrastText,\n // Generate a rich color object.\n augmentColor,\n // Used by the functions below to shift a color's luminance by approximately\n // two indexes within its tonal palette.\n // E.g., shift from Red 500 to Red 300 or Red 700.\n tonalOffset\n }, modes[mode]), other);\n return paletteOutput;\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"fontFamily\", \"fontSize\", \"fontWeightLight\", \"fontWeightRegular\", \"fontWeightMedium\", \"fontWeightBold\", \"htmlFontSize\", \"allVariants\", \"pxToRem\"];\nimport { deepmerge } from '@mui/utils';\nfunction round(value) {\n return Math.round(value * 1e5) / 1e5;\n}\nconst caseAllCaps = {\n textTransform: 'uppercase'\n};\nconst defaultFontFamily = '\"Roboto\", \"Helvetica\", \"Arial\", sans-serif';\n\n/**\n * @see @link{https://m2.material.io/design/typography/the-type-system.html}\n * @see @link{https://m2.material.io/design/typography/understanding-typography.html}\n */\nexport default function createTypography(palette, typography) {\n const _ref = typeof typography === 'function' ? typography(palette) : typography,\n {\n fontFamily = defaultFontFamily,\n // The default font size of the Material Specification.\n fontSize = 14,\n // px\n fontWeightLight = 300,\n fontWeightRegular = 400,\n fontWeightMedium = 500,\n fontWeightBold = 700,\n // Tell MUI what's the font-size on the html element.\n // 16px is the default font-size used by browsers.\n htmlFontSize = 16,\n // Apply the CSS properties to all the variants.\n allVariants,\n pxToRem: pxToRem2\n } = _ref,\n other = _objectWithoutPropertiesLoose(_ref, _excluded);\n if (process.env.NODE_ENV !== 'production') {\n if (typeof fontSize !== 'number') {\n console.error('MUI: `fontSize` is required to be a number.');\n }\n if (typeof htmlFontSize !== 'number') {\n console.error('MUI: `htmlFontSize` is required to be a number.');\n }\n }\n const coef = fontSize / 14;\n const pxToRem = pxToRem2 || (size => `${size / htmlFontSize * coef}rem`);\n const buildVariant = (fontWeight, size, lineHeight, letterSpacing, casing) => _extends({\n fontFamily,\n fontWeight,\n fontSize: pxToRem(size),\n // Unitless following https://meyerweb.com/eric/thoughts/2006/02/08/unitless-line-heights/\n lineHeight\n }, fontFamily === defaultFontFamily ? {\n letterSpacing: `${round(letterSpacing / size)}em`\n } : {}, casing, allVariants);\n const variants = {\n h1: buildVariant(fontWeightLight, 96, 1.167, -1.5),\n h2: buildVariant(fontWeightLight, 60, 1.2, -0.5),\n h3: buildVariant(fontWeightRegular, 48, 1.167, 0),\n h4: buildVariant(fontWeightRegular, 34, 1.235, 0.25),\n h5: buildVariant(fontWeightRegular, 24, 1.334, 0),\n h6: buildVariant(fontWeightMedium, 20, 1.6, 0.15),\n subtitle1: buildVariant(fontWeightRegular, 16, 1.75, 0.15),\n subtitle2: buildVariant(fontWeightMedium, 14, 1.57, 0.1),\n body1: buildVariant(fontWeightRegular, 16, 1.5, 0.15),\n body2: buildVariant(fontWeightRegular, 14, 1.43, 0.15),\n button: buildVariant(fontWeightMedium, 14, 1.75, 0.4, caseAllCaps),\n caption: buildVariant(fontWeightRegular, 12, 1.66, 0.4),\n overline: buildVariant(fontWeightRegular, 12, 2.66, 1, caseAllCaps),\n // TODO v6: Remove handling of 'inherit' variant from the theme as it is already handled in Material UI's Typography component. Also, remember to remove the associated types.\n inherit: {\n fontFamily: 'inherit',\n fontWeight: 'inherit',\n fontSize: 'inherit',\n lineHeight: 'inherit',\n letterSpacing: 'inherit'\n }\n };\n return deepmerge(_extends({\n htmlFontSize,\n pxToRem,\n fontFamily,\n fontSize,\n fontWeightLight,\n fontWeightRegular,\n fontWeightMedium,\n fontWeightBold\n }, variants), other, {\n clone: false // No need to clone deep\n });\n}","const shadowKeyUmbraOpacity = 0.2;\nconst shadowKeyPenumbraOpacity = 0.14;\nconst shadowAmbientShadowOpacity = 0.12;\nfunction createShadow(...px) {\n return [`${px[0]}px ${px[1]}px ${px[2]}px ${px[3]}px rgba(0,0,0,${shadowKeyUmbraOpacity})`, `${px[4]}px ${px[5]}px ${px[6]}px ${px[7]}px rgba(0,0,0,${shadowKeyPenumbraOpacity})`, `${px[8]}px ${px[9]}px ${px[10]}px ${px[11]}px rgba(0,0,0,${shadowAmbientShadowOpacity})`].join(',');\n}\n\n// Values from https://github.com/material-components/material-components-web/blob/be8747f94574669cb5e7add1a7c54fa41a89cec7/packages/mdc-elevation/_variables.scss\nconst shadows = ['none', createShadow(0, 2, 1, -1, 0, 1, 1, 0, 0, 1, 3, 0), createShadow(0, 3, 1, -2, 0, 2, 2, 0, 0, 1, 5, 0), createShadow(0, 3, 3, -2, 0, 3, 4, 0, 0, 1, 8, 0), createShadow(0, 2, 4, -1, 0, 4, 5, 0, 0, 1, 10, 0), createShadow(0, 3, 5, -1, 0, 5, 8, 0, 0, 1, 14, 0), createShadow(0, 3, 5, -1, 0, 6, 10, 0, 0, 1, 18, 0), createShadow(0, 4, 5, -2, 0, 7, 10, 1, 0, 2, 16, 1), createShadow(0, 5, 5, -3, 0, 8, 10, 1, 0, 3, 14, 2), createShadow(0, 5, 6, -3, 0, 9, 12, 1, 0, 3, 16, 2), createShadow(0, 6, 6, -3, 0, 10, 14, 1, 0, 4, 18, 3), createShadow(0, 6, 7, -4, 0, 11, 15, 1, 0, 4, 20, 3), createShadow(0, 7, 8, -4, 0, 12, 17, 2, 0, 5, 22, 4), createShadow(0, 7, 8, -4, 0, 13, 19, 2, 0, 5, 24, 4), createShadow(0, 7, 9, -4, 0, 14, 21, 2, 0, 5, 26, 4), createShadow(0, 8, 9, -5, 0, 15, 22, 2, 0, 6, 28, 5), createShadow(0, 8, 10, -5, 0, 16, 24, 2, 0, 6, 30, 5), createShadow(0, 8, 11, -5, 0, 17, 26, 2, 0, 6, 32, 5), createShadow(0, 9, 11, -5, 0, 18, 28, 2, 0, 7, 34, 6), createShadow(0, 9, 12, -6, 0, 19, 29, 2, 0, 7, 36, 6), createShadow(0, 10, 13, -6, 0, 20, 31, 3, 0, 8, 38, 7), createShadow(0, 10, 13, -6, 0, 21, 33, 3, 0, 8, 40, 7), createShadow(0, 10, 14, -6, 0, 22, 35, 3, 0, 8, 42, 7), createShadow(0, 11, 14, -7, 0, 23, 36, 3, 0, 9, 44, 8), createShadow(0, 11, 15, -7, 0, 24, 38, 3, 0, 9, 46, 8)];\nexport default shadows;","import _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nconst _excluded = [\"duration\", \"easing\", \"delay\"];\n// Follow https://material.google.com/motion/duration-easing.html#duration-easing-natural-easing-curves\n// to learn the context in which each easing should be used.\nexport const easing = {\n // This is the most common easing curve.\n easeInOut: 'cubic-bezier(0.4, 0, 0.2, 1)',\n // Objects enter the screen at full velocity from off-screen and\n // slowly decelerate to a resting point.\n easeOut: 'cubic-bezier(0.0, 0, 0.2, 1)',\n // Objects leave the screen at full velocity. They do not decelerate when off-screen.\n easeIn: 'cubic-bezier(0.4, 0, 1, 1)',\n // The sharp curve is used by objects that may return to the screen at any time.\n sharp: 'cubic-bezier(0.4, 0, 0.6, 1)'\n};\n\n// Follow https://m2.material.io/guidelines/motion/duration-easing.html#duration-easing-common-durations\n// to learn when use what timing\nexport const duration = {\n shortest: 150,\n shorter: 200,\n short: 250,\n // most basic recommended timing\n standard: 300,\n // this is to be used in complex animations\n complex: 375,\n // recommended when something is entering screen\n enteringScreen: 225,\n // recommended when something is leaving screen\n leavingScreen: 195\n};\nfunction formatMs(milliseconds) {\n return `${Math.round(milliseconds)}ms`;\n}\nfunction getAutoHeightDuration(height) {\n if (!height) {\n return 0;\n }\n const constant = height / 36;\n\n // https://www.wolframalpha.com/input/?i=(4+%2B+15+*+(x+%2F+36+)+**+0.25+%2B+(x+%2F+36)+%2F+5)+*+10\n return Math.round((4 + 15 * constant ** 0.25 + constant / 5) * 10);\n}\nexport default function createTransitions(inputTransitions) {\n const mergedEasing = _extends({}, easing, inputTransitions.easing);\n const mergedDuration = _extends({}, duration, inputTransitions.duration);\n const create = (props = ['all'], options = {}) => {\n const {\n duration: durationOption = mergedDuration.standard,\n easing: easingOption = mergedEasing.easeInOut,\n delay = 0\n } = options,\n other = _objectWithoutPropertiesLoose(options, _excluded);\n if (process.env.NODE_ENV !== 'production') {\n const isString = value => typeof value === 'string';\n // IE11 support, replace with Number.isNaN\n // eslint-disable-next-line no-restricted-globals\n const isNumber = value => !isNaN(parseFloat(value));\n if (!isString(props) && !Array.isArray(props)) {\n console.error('MUI: Argument \"props\" must be a string or Array.');\n }\n if (!isNumber(durationOption) && !isString(durationOption)) {\n console.error(`MUI: Argument \"duration\" must be a number or a string but found ${durationOption}.`);\n }\n if (!isString(easingOption)) {\n console.error('MUI: Argument \"easing\" must be a string.');\n }\n if (!isNumber(delay) && !isString(delay)) {\n console.error('MUI: Argument \"delay\" must be a number or a string.');\n }\n if (typeof options !== 'object') {\n console.error(['MUI: Secong argument of transition.create must be an object.', \"Arguments should be either `create('prop1', options)` or `create(['prop1', 'prop2'], options)`\"].join('\\n'));\n }\n if (Object.keys(other).length !== 0) {\n console.error(`MUI: Unrecognized argument(s) [${Object.keys(other).join(',')}].`);\n }\n }\n return (Array.isArray(props) ? props : [props]).map(animatedProp => `${animatedProp} ${typeof durationOption === 'string' ? durationOption : formatMs(durationOption)} ${easingOption} ${typeof delay === 'string' ? delay : formatMs(delay)}`).join(',');\n };\n return _extends({\n getAutoHeightDuration,\n create\n }, inputTransitions, {\n easing: mergedEasing,\n duration: mergedDuration\n });\n}","// We need to centralize the zIndex definitions as they work\n// like global values in the browser.\nconst zIndex = {\n mobileStepper: 1000,\n fab: 1050,\n speedDial: 1050,\n appBar: 1100,\n drawer: 1200,\n modal: 1300,\n snackbar: 1400,\n tooltip: 1500\n};\nexport default zIndex;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\nconst _excluded = [\"breakpoints\", \"mixins\", \"spacing\", \"palette\", \"transitions\", \"typography\", \"shape\"];\nimport { deepmerge } from '@mui/utils';\nimport { createTheme as systemCreateTheme, unstable_defaultSxConfig as defaultSxConfig, unstable_styleFunctionSx as styleFunctionSx } from '@mui/system';\nimport generateUtilityClass from '@mui/utils/generateUtilityClass';\nimport createMixins from './createMixins';\nimport createPalette from './createPalette';\nimport createTypography from './createTypography';\nimport shadows from './shadows';\nimport createTransitions from './createTransitions';\nimport zIndex from './zIndex';\nfunction createTheme(options = {}, ...args) {\n const {\n mixins: mixinsInput = {},\n palette: paletteInput = {},\n transitions: transitionsInput = {},\n typography: typographyInput = {}\n } = options,\n other = _objectWithoutPropertiesLoose(options, _excluded);\n if (options.vars) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: \\`vars\\` is a private field used for CSS variables support.\nPlease use another name.` : _formatMuiErrorMessage(18));\n }\n const palette = createPalette(paletteInput);\n const systemTheme = systemCreateTheme(options);\n let muiTheme = deepmerge(systemTheme, {\n mixins: createMixins(systemTheme.breakpoints, mixinsInput),\n palette,\n // Don't use [...shadows] until you've verified its transpiled code is not invoking the iterator protocol.\n shadows: shadows.slice(),\n typography: createTypography(palette, typographyInput),\n transitions: createTransitions(transitionsInput),\n zIndex: _extends({}, zIndex)\n });\n muiTheme = deepmerge(muiTheme, other);\n muiTheme = args.reduce((acc, argument) => deepmerge(acc, argument), muiTheme);\n if (process.env.NODE_ENV !== 'production') {\n // TODO v6: Refactor to use globalStateClassesMapping from @mui/utils once `readOnly` state class is used in Rating component.\n const stateClasses = ['active', 'checked', 'completed', 'disabled', 'error', 'expanded', 'focused', 'focusVisible', 'required', 'selected'];\n const traverse = (node, component) => {\n let key;\n\n // eslint-disable-next-line guard-for-in, no-restricted-syntax\n for (key in node) {\n const child = node[key];\n if (stateClasses.indexOf(key) !== -1 && Object.keys(child).length > 0) {\n if (process.env.NODE_ENV !== 'production') {\n const stateClass = generateUtilityClass('', key);\n console.error([`MUI: The \\`${component}\\` component increases ` + `the CSS specificity of the \\`${key}\\` internal state.`, 'You can not override it like this: ', JSON.stringify(node, null, 2), '', `Instead, you need to use the '&.${stateClass}' syntax:`, JSON.stringify({\n root: {\n [`&.${stateClass}`]: child\n }\n }, null, 2), '', 'https://mui.com/r/state-classes-guide'].join('\\n'));\n }\n // Remove the style to prevent global conflicts.\n node[key] = {};\n }\n }\n };\n Object.keys(muiTheme.components).forEach(component => {\n const styleOverrides = muiTheme.components[component].styleOverrides;\n if (styleOverrides && component.indexOf('Mui') === 0) {\n traverse(styleOverrides, component);\n }\n });\n }\n muiTheme.unstable_sxConfig = _extends({}, defaultSxConfig, other == null ? void 0 : other.unstable_sxConfig);\n muiTheme.unstable_sx = function sx(props) {\n return styleFunctionSx({\n sx: props,\n theme: this\n });\n };\n return muiTheme;\n}\nlet warnedOnce = false;\nexport function createMuiTheme(...args) {\n if (process.env.NODE_ENV !== 'production') {\n if (!warnedOnce) {\n warnedOnce = true;\n console.error(['MUI: the createMuiTheme function was renamed to createTheme.', '', \"You should use `import { createTheme } from '@mui/material/styles'`\"].join('\\n'));\n }\n }\n return createTheme(...args);\n}\nexport default createTheme;","'use client';\n\nimport createTheme from './createTheme';\nconst defaultTheme = createTheme();\nexport default defaultTheme;","export default '$$material';","'use client';\n\nimport { useThemeProps as systemUseThemeProps } from '@mui/system';\nimport defaultTheme from './defaultTheme';\nimport THEME_ID from './identifier';\nexport default function useThemeProps({\n props,\n name\n}) {\n return systemUseThemeProps({\n props,\n name,\n defaultTheme,\n themeId: THEME_ID\n });\n}","'use client';\n\nimport { createStyled, shouldForwardProp } from '@mui/system';\nimport defaultTheme from './defaultTheme';\nimport THEME_ID from './identifier';\nexport const rootShouldForwardProp = prop => shouldForwardProp(prop) && prop !== 'classes';\nexport const slotShouldForwardProp = shouldForwardProp;\nconst styled = createStyled({\n themeId: THEME_ID,\n defaultTheme,\n rootShouldForwardProp\n});\nexport default styled;","import generateUtilityClasses from '@mui/utils/generateUtilityClasses';\nimport generateUtilityClass from '@mui/utils/generateUtilityClass';\nexport function getSvgIconUtilityClass(slot) {\n return generateUtilityClass('MuiSvgIcon', slot);\n}\nconst svgIconClasses = generateUtilityClasses('MuiSvgIcon', ['root', 'colorPrimary', 'colorSecondary', 'colorAction', 'colorError', 'colorDisabled', 'fontSizeInherit', 'fontSizeSmall', 'fontSizeMedium', 'fontSizeLarge']);\nexport default svgIconClasses;","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"children\", \"className\", \"color\", \"component\", \"fontSize\", \"htmlColor\", \"inheritViewBox\", \"titleAccess\", \"viewBox\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport clsx from 'clsx';\nimport { unstable_composeClasses as composeClasses } from '@mui/base/composeClasses';\nimport capitalize from '../utils/capitalize';\nimport useThemeProps from '../styles/useThemeProps';\nimport styled from '../styles/styled';\nimport { getSvgIconUtilityClass } from './svgIconClasses';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nimport { jsxs as _jsxs } from \"react/jsx-runtime\";\nconst useUtilityClasses = ownerState => {\n const {\n color,\n fontSize,\n classes\n } = ownerState;\n const slots = {\n root: ['root', color !== 'inherit' && `color${capitalize(color)}`, `fontSize${capitalize(fontSize)}`]\n };\n return composeClasses(slots, getSvgIconUtilityClass, classes);\n};\nconst SvgIconRoot = styled('svg', {\n name: 'MuiSvgIcon',\n slot: 'Root',\n overridesResolver: (props, styles) => {\n const {\n ownerState\n } = props;\n return [styles.root, ownerState.color !== 'inherit' && styles[`color${capitalize(ownerState.color)}`], styles[`fontSize${capitalize(ownerState.fontSize)}`]];\n }\n})(({\n theme,\n ownerState\n}) => {\n var _theme$transitions, _theme$transitions$cr, _theme$transitions2, _theme$typography, _theme$typography$pxT, _theme$typography2, _theme$typography2$px, _theme$typography3, _theme$typography3$px, _palette$ownerState$c, _palette, _palette2, _palette3;\n return {\n userSelect: 'none',\n width: '1em',\n height: '1em',\n display: 'inline-block',\n // the will define the property that has `currentColor`\n // e.g. heroicons uses fill=\"none\" and stroke=\"currentColor\"\n fill: ownerState.hasSvgAsChild ? undefined : 'currentColor',\n flexShrink: 0,\n transition: (_theme$transitions = theme.transitions) == null || (_theme$transitions$cr = _theme$transitions.create) == null ? void 0 : _theme$transitions$cr.call(_theme$transitions, 'fill', {\n duration: (_theme$transitions2 = theme.transitions) == null || (_theme$transitions2 = _theme$transitions2.duration) == null ? void 0 : _theme$transitions2.shorter\n }),\n fontSize: {\n inherit: 'inherit',\n small: ((_theme$typography = theme.typography) == null || (_theme$typography$pxT = _theme$typography.pxToRem) == null ? void 0 : _theme$typography$pxT.call(_theme$typography, 20)) || '1.25rem',\n medium: ((_theme$typography2 = theme.typography) == null || (_theme$typography2$px = _theme$typography2.pxToRem) == null ? void 0 : _theme$typography2$px.call(_theme$typography2, 24)) || '1.5rem',\n large: ((_theme$typography3 = theme.typography) == null || (_theme$typography3$px = _theme$typography3.pxToRem) == null ? void 0 : _theme$typography3$px.call(_theme$typography3, 35)) || '2.1875rem'\n }[ownerState.fontSize],\n // TODO v5 deprecate, v6 remove for sx\n color: (_palette$ownerState$c = (_palette = (theme.vars || theme).palette) == null || (_palette = _palette[ownerState.color]) == null ? void 0 : _palette.main) != null ? _palette$ownerState$c : {\n action: (_palette2 = (theme.vars || theme).palette) == null || (_palette2 = _palette2.action) == null ? void 0 : _palette2.active,\n disabled: (_palette3 = (theme.vars || theme).palette) == null || (_palette3 = _palette3.action) == null ? void 0 : _palette3.disabled,\n inherit: undefined\n }[ownerState.color]\n };\n});\nconst SvgIcon = /*#__PURE__*/React.forwardRef(function SvgIcon(inProps, ref) {\n const props = useThemeProps({\n props: inProps,\n name: 'MuiSvgIcon'\n });\n const {\n children,\n className,\n color = 'inherit',\n component = 'svg',\n fontSize = 'medium',\n htmlColor,\n inheritViewBox = false,\n titleAccess,\n viewBox = '0 0 24 24'\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const hasSvgAsChild = /*#__PURE__*/React.isValidElement(children) && children.type === 'svg';\n const ownerState = _extends({}, props, {\n color,\n component,\n fontSize,\n instanceFontSize: inProps.fontSize,\n inheritViewBox,\n viewBox,\n hasSvgAsChild\n });\n const more = {};\n if (!inheritViewBox) {\n more.viewBox = viewBox;\n }\n const classes = useUtilityClasses(ownerState);\n return /*#__PURE__*/_jsxs(SvgIconRoot, _extends({\n as: component,\n className: clsx(classes.root, className),\n focusable: \"false\",\n color: htmlColor,\n \"aria-hidden\": titleAccess ? undefined : true,\n role: titleAccess ? 'img' : undefined,\n ref: ref\n }, more, other, hasSvgAsChild && children.props, {\n ownerState: ownerState,\n children: [hasSvgAsChild ? children.props.children : children, titleAccess ? /*#__PURE__*/_jsx(\"title\", {\n children: titleAccess\n }) : null]\n }));\n});\nprocess.env.NODE_ENV !== \"production\" ? SvgIcon.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the d.ts file and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * Node passed into the SVG element.\n */\n children: PropTypes.node,\n /**\n * Override or extend the styles applied to the component.\n */\n classes: PropTypes.object,\n /**\n * @ignore\n */\n className: PropTypes.string,\n /**\n * The color of the component.\n * It supports both default and custom theme colors, which can be added as shown in the\n * [palette customization guide](https://mui.com/material-ui/customization/palette/#custom-colors).\n * You can use the `htmlColor` prop to apply a color attribute to the SVG element.\n * @default 'inherit'\n */\n color: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.oneOf(['inherit', 'action', 'disabled', 'primary', 'secondary', 'error', 'info', 'success', 'warning']), PropTypes.string]),\n /**\n * The component used for the root node.\n * Either a string to use a HTML element or a component.\n */\n component: PropTypes.elementType,\n /**\n * The fontSize applied to the icon. Defaults to 24px, but can be configure to inherit font size.\n * @default 'medium'\n */\n fontSize: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.oneOf(['inherit', 'large', 'medium', 'small']), PropTypes.string]),\n /**\n * Applies a color attribute to the SVG element.\n */\n htmlColor: PropTypes.string,\n /**\n * If `true`, the root node will inherit the custom `component`'s viewBox and the `viewBox`\n * prop will be ignored.\n * Useful when you want to reference a custom `component` and have `SvgIcon` pass that\n * `component`'s viewBox to the root node.\n * @default false\n */\n inheritViewBox: PropTypes.bool,\n /**\n * The shape-rendering attribute. The behavior of the different options is described on the\n * [MDN Web Docs](https://developer.mozilla.org/en-US/docs/Web/SVG/Attribute/shape-rendering).\n * If you are having issues with blurry icons you should investigate this prop.\n */\n shapeRendering: PropTypes.string,\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Provides a human-readable title for the element that contains it.\n * https://www.w3.org/TR/SVG-access/#Equivalent\n */\n titleAccess: PropTypes.string,\n /**\n * Allows you to redefine what the coordinates without units mean inside an SVG element.\n * For example, if the SVG element is 500 (width) by 200 (height),\n * and you pass viewBox=\"0 0 50 20\",\n * this means that the coordinates inside the SVG will go from the top left corner (0,0)\n * to bottom right (50,20) and each unit will be worth 10px.\n * @default '0 0 24 24'\n */\n viewBox: PropTypes.string\n} : void 0;\nSvgIcon.muiName = 'SvgIcon';\nexport default SvgIcon;","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport * as React from 'react';\nimport SvgIcon from '../SvgIcon';\n\n/**\n * Private module reserved for @mui packages.\n */\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nexport default function createSvgIcon(path, displayName) {\n function Component(props, ref) {\n return /*#__PURE__*/_jsx(SvgIcon, _extends({\n \"data-testid\": `${displayName}Icon`,\n ref: ref\n }, props, {\n children: path\n }));\n }\n if (process.env.NODE_ENV !== 'production') {\n // Need to set `displayName` on the inner component for React.memo.\n // React prior to 16.14 ignores `displayName` on the wrapper.\n Component.displayName = `${displayName}Icon`;\n }\n Component.muiName = SvgIcon.muiName;\n return /*#__PURE__*/React.memo( /*#__PURE__*/React.forwardRef(Component));\n}","'use client';\n\nimport { unstable_ClassNameGenerator as ClassNameGenerator } from '@mui/base/ClassNameGenerator';\nexport { default as capitalize } from './capitalize';\nexport { default as createChainedFunction } from './createChainedFunction';\nexport { default as createSvgIcon } from './createSvgIcon';\nexport { default as debounce } from './debounce';\nexport { default as deprecatedPropType } from './deprecatedPropType';\nexport { default as isMuiElement } from './isMuiElement';\nexport { default as ownerDocument } from './ownerDocument';\nexport { default as ownerWindow } from './ownerWindow';\nexport { default as requirePropFactory } from './requirePropFactory';\nexport { default as setRef } from './setRef';\nexport { default as unstable_useEnhancedEffect } from './useEnhancedEffect';\nexport { default as unstable_useId } from './useId';\nexport { default as unsupportedProp } from './unsupportedProp';\nexport { default as useControlled } from './useControlled';\nexport { default as useEventCallback } from './useEventCallback';\nexport { default as useForkRef } from './useForkRef';\nexport { default as useIsFocusVisible } from './useIsFocusVisible';\n// TODO: remove this export once ClassNameGenerator is stable\n// eslint-disable-next-line @typescript-eslint/naming-convention\nexport const unstable_ClassNameGenerator = {\n configure: generator => {\n if (process.env.NODE_ENV !== 'production') {\n console.warn(['MUI: `ClassNameGenerator` import from `@mui/material/utils` is outdated and might cause unexpected issues.', '', \"You should use `import { unstable_ClassNameGenerator } from '@mui/material/className'` instead\", '', 'The detail of the issue: https://github.com/mui/material-ui/issues/30011#issuecomment-1024993401', '', 'The updated documentation: https://mui.com/guides/classname-generator/'].join('\\n'));\n }\n ClassNameGenerator.configure(generator);\n }\n};","\"use strict\";\n'use client';\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nObject.defineProperty(exports, \"default\", {\n enumerable: true,\n get: function () {\n return _utils.createSvgIcon;\n }\n});\nvar _utils = require(\"@mui/material/utils\");","\"use strict\";\n\"use client\";\n\nvar _interopRequireDefault = require(\"@babel/runtime/helpers/interopRequireDefault\");\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = void 0;\nvar _createSvgIcon = _interopRequireDefault(require(\"./utils/createSvgIcon\"));\nvar _jsxRuntime = require(\"react/jsx-runtime\");\nvar _default = exports.default = (0, _createSvgIcon.default)( /*#__PURE__*/(0, _jsxRuntime.jsx)(\"path\", {\n d: \"m10 17 5-5-5-5z\"\n}), 'ArrowRight');","/**\n * Determines if a given element is a DOM element name (i.e. not a React component).\n */\nexport function isHostComponent(element) {\n return typeof element === 'string';\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport { isHostComponent } from './isHostComponent';\n\n/**\n * Type of the ownerState based on the type of an element it applies to.\n * This resolves to the provided OwnerState for React components and `undefined` for host components.\n * Falls back to `OwnerState | undefined` when the exact type can't be determined in development time.\n */\n\n/**\n * Appends the ownerState object to the props, merging with the existing one if necessary.\n *\n * @param elementType Type of the element that owns the `existingProps`. If the element is a DOM node or undefined, `ownerState` is not applied.\n * @param otherProps Props of the element.\n * @param ownerState\n */\nexport function appendOwnerState(elementType, otherProps, ownerState) {\n if (elementType === undefined || isHostComponent(elementType)) {\n return otherProps;\n }\n return _extends({}, otherProps, {\n ownerState: _extends({}, otherProps.ownerState, ownerState)\n });\n}","'use client';\n\nimport * as React from 'react';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nconst defaultContextValue = {\n disableDefaultClasses: false\n};\nconst ClassNameConfiguratorContext = /*#__PURE__*/React.createContext(defaultContextValue);\n/**\n * @ignore - internal hook.\n *\n * Wraps the `generateUtilityClass` function and controls how the classes are generated.\n * Currently it only affects whether the classes are applied or not.\n *\n * @returns Function to be called with the `generateUtilityClass` function specific to a component to generate the classes.\n */\nexport function useClassNamesOverride(generateUtilityClass) {\n const {\n disableDefaultClasses\n } = React.useContext(ClassNameConfiguratorContext);\n return slot => {\n if (disableDefaultClasses) {\n return '';\n }\n return generateUtilityClass(slot);\n };\n}\n\n/**\n * Allows to configure the components within to not apply any built-in classes.\n */\nexport function ClassNameConfigurator(props) {\n const {\n disableDefaultClasses,\n children\n } = props;\n const contextValue = React.useMemo(() => ({\n disableDefaultClasses: disableDefaultClasses != null ? disableDefaultClasses : false\n }), [disableDefaultClasses]);\n return /*#__PURE__*/_jsx(ClassNameConfiguratorContext.Provider, {\n value: contextValue,\n children: children\n });\n}","/**\n * Extracts event handlers from a given object.\n * A prop is considered an event handler if it is a function and its name starts with `on`.\n *\n * @param object An object to extract event handlers from.\n * @param excludeKeys An array of keys to exclude from the returned object.\n */\nexport function extractEventHandlers(object, excludeKeys = []) {\n if (object === undefined) {\n return {};\n }\n const result = {};\n Object.keys(object).filter(prop => prop.match(/^on[A-Z]/) && typeof object[prop] === 'function' && !excludeKeys.includes(prop)).forEach(prop => {\n result[prop] = object[prop];\n });\n return result;\n}","/**\n * If `componentProps` is a function, calls it with the provided `ownerState`.\n * Otherwise, just returns `componentProps`.\n */\nexport function resolveComponentProps(componentProps, ownerState, slotState) {\n if (typeof componentProps === 'function') {\n return componentProps(ownerState, slotState);\n }\n return componentProps;\n}","/**\n * Removes event handlers from the given object.\n * A field is considered an event handler if it is a function with a name beginning with `on`.\n *\n * @param object Object to remove event handlers from.\n * @returns Object with event handlers removed.\n */\nexport function omitEventHandlers(object) {\n if (object === undefined) {\n return {};\n }\n const result = {};\n Object.keys(object).filter(prop => !(prop.match(/^on[A-Z]/) && typeof object[prop] === 'function')).forEach(prop => {\n result[prop] = object[prop];\n });\n return result;\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport clsx from 'clsx';\nimport { extractEventHandlers } from './extractEventHandlers';\nimport { omitEventHandlers } from './omitEventHandlers';\n/**\n * Merges the slot component internal props (usually coming from a hook)\n * with the externally provided ones.\n *\n * The merge order is (the latter overrides the former):\n * 1. The internal props (specified as a getter function to work with get*Props hook result)\n * 2. Additional props (specified internally on a Base UI component)\n * 3. External props specified on the owner component. These should only be used on a root slot.\n * 4. External props specified in the `slotProps.*` prop.\n * 5. The `className` prop - combined from all the above.\n * @param parameters\n * @returns\n */\nexport function mergeSlotProps(parameters) {\n const {\n getSlotProps,\n additionalProps,\n externalSlotProps,\n externalForwardedProps,\n className\n } = parameters;\n if (!getSlotProps) {\n // The simpler case - getSlotProps is not defined, so no internal event handlers are defined,\n // so we can simply merge all the props without having to worry about extracting event handlers.\n const joinedClasses = clsx(additionalProps == null ? void 0 : additionalProps.className, className, externalForwardedProps == null ? void 0 : externalForwardedProps.className, externalSlotProps == null ? void 0 : externalSlotProps.className);\n const mergedStyle = _extends({}, additionalProps == null ? void 0 : additionalProps.style, externalForwardedProps == null ? void 0 : externalForwardedProps.style, externalSlotProps == null ? void 0 : externalSlotProps.style);\n const props = _extends({}, additionalProps, externalForwardedProps, externalSlotProps);\n if (joinedClasses.length > 0) {\n props.className = joinedClasses;\n }\n if (Object.keys(mergedStyle).length > 0) {\n props.style = mergedStyle;\n }\n return {\n props,\n internalRef: undefined\n };\n }\n\n // In this case, getSlotProps is responsible for calling the external event handlers.\n // We don't need to include them in the merged props because of this.\n\n const eventHandlers = extractEventHandlers(_extends({}, externalForwardedProps, externalSlotProps));\n const componentsPropsWithoutEventHandlers = omitEventHandlers(externalSlotProps);\n const otherPropsWithoutEventHandlers = omitEventHandlers(externalForwardedProps);\n const internalSlotProps = getSlotProps(eventHandlers);\n\n // The order of classes is important here.\n // Emotion (that we use in libraries consuming Base UI) depends on this order\n // to properly override style. It requires the most important classes to be last\n // (see https://github.com/mui/material-ui/pull/33205) for the related discussion.\n const joinedClasses = clsx(internalSlotProps == null ? void 0 : internalSlotProps.className, additionalProps == null ? void 0 : additionalProps.className, className, externalForwardedProps == null ? void 0 : externalForwardedProps.className, externalSlotProps == null ? void 0 : externalSlotProps.className);\n const mergedStyle = _extends({}, internalSlotProps == null ? void 0 : internalSlotProps.style, additionalProps == null ? void 0 : additionalProps.style, externalForwardedProps == null ? void 0 : externalForwardedProps.style, externalSlotProps == null ? void 0 : externalSlotProps.style);\n const props = _extends({}, internalSlotProps, additionalProps, otherPropsWithoutEventHandlers, componentsPropsWithoutEventHandlers);\n if (joinedClasses.length > 0) {\n props.className = joinedClasses;\n }\n if (Object.keys(mergedStyle).length > 0) {\n props.style = mergedStyle;\n }\n return {\n props,\n internalRef: internalSlotProps.ref\n };\n}","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"elementType\", \"externalSlotProps\", \"ownerState\", \"skipResolvingSlotProps\"];\nimport { unstable_useForkRef as useForkRef } from '@mui/utils';\nimport { appendOwnerState } from './appendOwnerState';\nimport { mergeSlotProps } from './mergeSlotProps';\nimport { resolveComponentProps } from './resolveComponentProps';\n/**\n * @ignore - do not document.\n * Builds the props to be passed into the slot of an unstyled component.\n * It merges the internal props of the component with the ones supplied by the user, allowing to customize the behavior.\n * If the slot component is not a host component, it also merges in the `ownerState`.\n *\n * @param parameters.getSlotProps - A function that returns the props to be passed to the slot component.\n */\nexport function useSlotProps(parameters) {\n var _parameters$additiona;\n const {\n elementType,\n externalSlotProps,\n ownerState,\n skipResolvingSlotProps = false\n } = parameters,\n rest = _objectWithoutPropertiesLoose(parameters, _excluded);\n const resolvedComponentsProps = skipResolvingSlotProps ? {} : resolveComponentProps(externalSlotProps, ownerState);\n const {\n props: mergedProps,\n internalRef\n } = mergeSlotProps(_extends({}, rest, {\n externalSlotProps: resolvedComponentsProps\n }));\n const ref = useForkRef(internalRef, resolvedComponentsProps == null ? void 0 : resolvedComponentsProps.ref, (_parameters$additiona = parameters.additionalProps) == null ? void 0 : _parameters$additiona.ref);\n const props = appendOwnerState(elementType, _extends({}, mergedProps, {\n ref\n }), ownerState);\n return props;\n}","import { globalStateClasses } from '@mui/utils/generateUtilityClass';\nconst GLOBAL_CLASS_PREFIX = 'base';\nfunction buildStateClass(state) {\n return `${GLOBAL_CLASS_PREFIX}--${state}`;\n}\nfunction buildSlotClass(componentName, slot) {\n return `${GLOBAL_CLASS_PREFIX}-${componentName}-${slot}`;\n}\nexport function generateUtilityClass(componentName, slot) {\n const globalStateClass = globalStateClasses[slot];\n return globalStateClass ? buildStateClass(globalStateClass) : buildSlotClass(componentName, slot);\n}\nexport function isGlobalState(slot) {\n return globalStateClasses[slot] !== undefined;\n}","import { generateUtilityClass } from '../generateUtilityClass';\nexport function generateUtilityClasses(componentName, slots) {\n const result = {};\n slots.forEach(slot => {\n result[slot] = generateUtilityClass(componentName, slot);\n });\n return result;\n}","'use client';\n\nimport * as React from 'react';\nimport * as ReactDOM from 'react-dom';\nimport PropTypes from 'prop-types';\nimport { exactProp, HTMLElementType, unstable_useEnhancedEffect as useEnhancedEffect, unstable_useForkRef as useForkRef, unstable_setRef as setRef } from '@mui/utils';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nfunction getContainer(container) {\n return typeof container === 'function' ? container() : container;\n}\n\n/**\n * Portals provide a first-class way to render children into a DOM node\n * that exists outside the DOM hierarchy of the parent component.\n *\n * Demos:\n *\n * - [Portal](https://mui.com/base-ui/react-portal/)\n *\n * API:\n *\n * - [Portal API](https://mui.com/base-ui/react-portal/components-api/#portal)\n */\nconst Portal = /*#__PURE__*/React.forwardRef(function Portal(props, forwardedRef) {\n const {\n children,\n container,\n disablePortal = false\n } = props;\n const [mountNode, setMountNode] = React.useState(null);\n // @ts-expect-error TODO upstream fix\n const handleRef = useForkRef( /*#__PURE__*/React.isValidElement(children) ? children.ref : null, forwardedRef);\n useEnhancedEffect(() => {\n if (!disablePortal) {\n setMountNode(getContainer(container) || document.body);\n }\n }, [container, disablePortal]);\n useEnhancedEffect(() => {\n if (mountNode && !disablePortal) {\n setRef(forwardedRef, mountNode);\n return () => {\n setRef(forwardedRef, null);\n };\n }\n return undefined;\n }, [forwardedRef, mountNode, disablePortal]);\n if (disablePortal) {\n if ( /*#__PURE__*/React.isValidElement(children)) {\n const newProps = {\n ref: handleRef\n };\n return /*#__PURE__*/React.cloneElement(children, newProps);\n }\n return /*#__PURE__*/_jsx(React.Fragment, {\n children: children\n });\n }\n return /*#__PURE__*/_jsx(React.Fragment, {\n children: mountNode ? /*#__PURE__*/ReactDOM.createPortal(children, mountNode) : mountNode\n });\n});\nprocess.env.NODE_ENV !== \"production\" ? Portal.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * The children to render into the `container`.\n */\n children: PropTypes.node,\n /**\n * An HTML element or function that returns one.\n * The `container` will have the portal children appended to it.\n *\n * You can also provide a callback, which is called in a React layout effect.\n * This lets you set the container from a ref, and also makes server-side rendering possible.\n *\n * By default, it uses the body of the top-level document object,\n * so it's simply `document.body` most of the time.\n */\n container: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.func]),\n /**\n * The `children` will be under the DOM hierarchy of the parent component.\n * @default false\n */\n disablePortal: PropTypes.bool\n} : void 0;\nif (process.env.NODE_ENV !== 'production') {\n // eslint-disable-next-line\n Portal['propTypes' + ''] = exactProp(Portal.propTypes);\n}\nexport { Portal };","export var top = 'top';\nexport var bottom = 'bottom';\nexport var right = 'right';\nexport var left = 'left';\nexport var auto = 'auto';\nexport var basePlacements = [top, bottom, right, left];\nexport var start = 'start';\nexport var end = 'end';\nexport var clippingParents = 'clippingParents';\nexport var viewport = 'viewport';\nexport var popper = 'popper';\nexport var reference = 'reference';\nexport var variationPlacements = /*#__PURE__*/basePlacements.reduce(function (acc, placement) {\n return acc.concat([placement + \"-\" + start, placement + \"-\" + end]);\n}, []);\nexport var placements = /*#__PURE__*/[].concat(basePlacements, [auto]).reduce(function (acc, placement) {\n return acc.concat([placement, placement + \"-\" + start, placement + \"-\" + end]);\n}, []); // modifiers that need to read the DOM\n\nexport var beforeRead = 'beforeRead';\nexport var read = 'read';\nexport var afterRead = 'afterRead'; // pure-logic modifiers\n\nexport var beforeMain = 'beforeMain';\nexport var main = 'main';\nexport var afterMain = 'afterMain'; // modifier with the purpose to write to the DOM (or write into a framework state)\n\nexport var beforeWrite = 'beforeWrite';\nexport var write = 'write';\nexport var afterWrite = 'afterWrite';\nexport var modifierPhases = [beforeRead, read, afterRead, beforeMain, main, afterMain, beforeWrite, write, afterWrite];","export default function getNodeName(element) {\n return element ? (element.nodeName || '').toLowerCase() : null;\n}","export default function getWindow(node) {\n if (node == null) {\n return window;\n }\n\n if (node.toString() !== '[object Window]') {\n var ownerDocument = node.ownerDocument;\n return ownerDocument ? ownerDocument.defaultView || window : window;\n }\n\n return node;\n}","import getWindow from \"./getWindow.js\";\n\nfunction isElement(node) {\n var OwnElement = getWindow(node).Element;\n return node instanceof OwnElement || node instanceof Element;\n}\n\nfunction isHTMLElement(node) {\n var OwnElement = getWindow(node).HTMLElement;\n return node instanceof OwnElement || node instanceof HTMLElement;\n}\n\nfunction isShadowRoot(node) {\n // IE 11 has no ShadowRoot\n if (typeof ShadowRoot === 'undefined') {\n return false;\n }\n\n var OwnElement = getWindow(node).ShadowRoot;\n return node instanceof OwnElement || node instanceof ShadowRoot;\n}\n\nexport { isElement, isHTMLElement, isShadowRoot };","import getNodeName from \"../dom-utils/getNodeName.js\";\nimport { isHTMLElement } from \"../dom-utils/instanceOf.js\"; // This modifier takes the styles prepared by the `computeStyles` modifier\n// and applies them to the HTMLElements such as popper and arrow\n\nfunction applyStyles(_ref) {\n var state = _ref.state;\n Object.keys(state.elements).forEach(function (name) {\n var style = state.styles[name] || {};\n var attributes = state.attributes[name] || {};\n var element = state.elements[name]; // arrow is optional + virtual elements\n\n if (!isHTMLElement(element) || !getNodeName(element)) {\n return;\n } // Flow doesn't support to extend this property, but it's the most\n // effective way to apply styles to an HTMLElement\n // $FlowFixMe[cannot-write]\n\n\n Object.assign(element.style, style);\n Object.keys(attributes).forEach(function (name) {\n var value = attributes[name];\n\n if (value === false) {\n element.removeAttribute(name);\n } else {\n element.setAttribute(name, value === true ? '' : value);\n }\n });\n });\n}\n\nfunction effect(_ref2) {\n var state = _ref2.state;\n var initialStyles = {\n popper: {\n position: state.options.strategy,\n left: '0',\n top: '0',\n margin: '0'\n },\n arrow: {\n position: 'absolute'\n },\n reference: {}\n };\n Object.assign(state.elements.popper.style, initialStyles.popper);\n state.styles = initialStyles;\n\n if (state.elements.arrow) {\n Object.assign(state.elements.arrow.style, initialStyles.arrow);\n }\n\n return function () {\n Object.keys(state.elements).forEach(function (name) {\n var element = state.elements[name];\n var attributes = state.attributes[name] || {};\n var styleProperties = Object.keys(state.styles.hasOwnProperty(name) ? state.styles[name] : initialStyles[name]); // Set all values to an empty string to unset them\n\n var style = styleProperties.reduce(function (style, property) {\n style[property] = '';\n return style;\n }, {}); // arrow is optional + virtual elements\n\n if (!isHTMLElement(element) || !getNodeName(element)) {\n return;\n }\n\n Object.assign(element.style, style);\n Object.keys(attributes).forEach(function (attribute) {\n element.removeAttribute(attribute);\n });\n });\n };\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'applyStyles',\n enabled: true,\n phase: 'write',\n fn: applyStyles,\n effect: effect,\n requires: ['computeStyles']\n};","import { auto } from \"../enums.js\";\nexport default function getBasePlacement(placement) {\n return placement.split('-')[0];\n}","export var max = Math.max;\nexport var min = Math.min;\nexport var round = Math.round;","export default function getUAString() {\n var uaData = navigator.userAgentData;\n\n if (uaData != null && uaData.brands && Array.isArray(uaData.brands)) {\n return uaData.brands.map(function (item) {\n return item.brand + \"/\" + item.version;\n }).join(' ');\n }\n\n return navigator.userAgent;\n}","import getUAString from \"../utils/userAgent.js\";\nexport default function isLayoutViewport() {\n return !/^((?!chrome|android).)*safari/i.test(getUAString());\n}","import { isElement, isHTMLElement } from \"./instanceOf.js\";\nimport { round } from \"../utils/math.js\";\nimport getWindow from \"./getWindow.js\";\nimport isLayoutViewport from \"./isLayoutViewport.js\";\nexport default function getBoundingClientRect(element, includeScale, isFixedStrategy) {\n if (includeScale === void 0) {\n includeScale = false;\n }\n\n if (isFixedStrategy === void 0) {\n isFixedStrategy = false;\n }\n\n var clientRect = element.getBoundingClientRect();\n var scaleX = 1;\n var scaleY = 1;\n\n if (includeScale && isHTMLElement(element)) {\n scaleX = element.offsetWidth > 0 ? round(clientRect.width) / element.offsetWidth || 1 : 1;\n scaleY = element.offsetHeight > 0 ? round(clientRect.height) / element.offsetHeight || 1 : 1;\n }\n\n var _ref = isElement(element) ? getWindow(element) : window,\n visualViewport = _ref.visualViewport;\n\n var addVisualOffsets = !isLayoutViewport() && isFixedStrategy;\n var x = (clientRect.left + (addVisualOffsets && visualViewport ? visualViewport.offsetLeft : 0)) / scaleX;\n var y = (clientRect.top + (addVisualOffsets && visualViewport ? visualViewport.offsetTop : 0)) / scaleY;\n var width = clientRect.width / scaleX;\n var height = clientRect.height / scaleY;\n return {\n width: width,\n height: height,\n top: y,\n right: x + width,\n bottom: y + height,\n left: x,\n x: x,\n y: y\n };\n}","import getBoundingClientRect from \"./getBoundingClientRect.js\"; // Returns the layout rect of an element relative to its offsetParent. Layout\n// means it doesn't take into account transforms.\n\nexport default function getLayoutRect(element) {\n var clientRect = getBoundingClientRect(element); // Use the clientRect sizes if it's not been transformed.\n // Fixes https://github.com/popperjs/popper-core/issues/1223\n\n var width = element.offsetWidth;\n var height = element.offsetHeight;\n\n if (Math.abs(clientRect.width - width) <= 1) {\n width = clientRect.width;\n }\n\n if (Math.abs(clientRect.height - height) <= 1) {\n height = clientRect.height;\n }\n\n return {\n x: element.offsetLeft,\n y: element.offsetTop,\n width: width,\n height: height\n };\n}","import { isShadowRoot } from \"./instanceOf.js\";\nexport default function contains(parent, child) {\n var rootNode = child.getRootNode && child.getRootNode(); // First, attempt with faster native method\n\n if (parent.contains(child)) {\n return true;\n } // then fallback to custom implementation with Shadow DOM support\n else if (rootNode && isShadowRoot(rootNode)) {\n var next = child;\n\n do {\n if (next && parent.isSameNode(next)) {\n return true;\n } // $FlowFixMe[prop-missing]: need a better way to handle this...\n\n\n next = next.parentNode || next.host;\n } while (next);\n } // Give up, the result is false\n\n\n return false;\n}","import getWindow from \"./getWindow.js\";\nexport default function getComputedStyle(element) {\n return getWindow(element).getComputedStyle(element);\n}","import getNodeName from \"./getNodeName.js\";\nexport default function isTableElement(element) {\n return ['table', 'td', 'th'].indexOf(getNodeName(element)) >= 0;\n}","import { isElement } from \"./instanceOf.js\";\nexport default function getDocumentElement(element) {\n // $FlowFixMe[incompatible-return]: assume body is always available\n return ((isElement(element) ? element.ownerDocument : // $FlowFixMe[prop-missing]\n element.document) || window.document).documentElement;\n}","import getNodeName from \"./getNodeName.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport { isShadowRoot } from \"./instanceOf.js\";\nexport default function getParentNode(element) {\n if (getNodeName(element) === 'html') {\n return element;\n }\n\n return (// this is a quicker (but less type safe) way to save quite some bytes from the bundle\n // $FlowFixMe[incompatible-return]\n // $FlowFixMe[prop-missing]\n element.assignedSlot || // step into the shadow DOM of the parent of a slotted node\n element.parentNode || ( // DOM Element detected\n isShadowRoot(element) ? element.host : null) || // ShadowRoot detected\n // $FlowFixMe[incompatible-call]: HTMLElement is a Node\n getDocumentElement(element) // fallback\n\n );\n}","import getWindow from \"./getWindow.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport getComputedStyle from \"./getComputedStyle.js\";\nimport { isHTMLElement, isShadowRoot } from \"./instanceOf.js\";\nimport isTableElement from \"./isTableElement.js\";\nimport getParentNode from \"./getParentNode.js\";\nimport getUAString from \"../utils/userAgent.js\";\n\nfunction getTrueOffsetParent(element) {\n if (!isHTMLElement(element) || // https://github.com/popperjs/popper-core/issues/837\n getComputedStyle(element).position === 'fixed') {\n return null;\n }\n\n return element.offsetParent;\n} // `.offsetParent` reports `null` for fixed elements, while absolute elements\n// return the containing block\n\n\nfunction getContainingBlock(element) {\n var isFirefox = /firefox/i.test(getUAString());\n var isIE = /Trident/i.test(getUAString());\n\n if (isIE && isHTMLElement(element)) {\n // In IE 9, 10 and 11 fixed elements containing block is always established by the viewport\n var elementCss = getComputedStyle(element);\n\n if (elementCss.position === 'fixed') {\n return null;\n }\n }\n\n var currentNode = getParentNode(element);\n\n if (isShadowRoot(currentNode)) {\n currentNode = currentNode.host;\n }\n\n while (isHTMLElement(currentNode) && ['html', 'body'].indexOf(getNodeName(currentNode)) < 0) {\n var css = getComputedStyle(currentNode); // This is non-exhaustive but covers the most common CSS properties that\n // create a containing block.\n // https://developer.mozilla.org/en-US/docs/Web/CSS/Containing_block#identifying_the_containing_block\n\n if (css.transform !== 'none' || css.perspective !== 'none' || css.contain === 'paint' || ['transform', 'perspective'].indexOf(css.willChange) !== -1 || isFirefox && css.willChange === 'filter' || isFirefox && css.filter && css.filter !== 'none') {\n return currentNode;\n } else {\n currentNode = currentNode.parentNode;\n }\n }\n\n return null;\n} // Gets the closest ancestor positioned element. Handles some edge cases,\n// such as table ancestors and cross browser bugs.\n\n\nexport default function getOffsetParent(element) {\n var window = getWindow(element);\n var offsetParent = getTrueOffsetParent(element);\n\n while (offsetParent && isTableElement(offsetParent) && getComputedStyle(offsetParent).position === 'static') {\n offsetParent = getTrueOffsetParent(offsetParent);\n }\n\n if (offsetParent && (getNodeName(offsetParent) === 'html' || getNodeName(offsetParent) === 'body' && getComputedStyle(offsetParent).position === 'static')) {\n return window;\n }\n\n return offsetParent || getContainingBlock(element) || window;\n}","export default function getMainAxisFromPlacement(placement) {\n return ['top', 'bottom'].indexOf(placement) >= 0 ? 'x' : 'y';\n}","import { max as mathMax, min as mathMin } from \"./math.js\";\nexport function within(min, value, max) {\n return mathMax(min, mathMin(value, max));\n}\nexport function withinMaxClamp(min, value, max) {\n var v = within(min, value, max);\n return v > max ? max : v;\n}","export default function getFreshSideObject() {\n return {\n top: 0,\n right: 0,\n bottom: 0,\n left: 0\n };\n}","import getFreshSideObject from \"./getFreshSideObject.js\";\nexport default function mergePaddingObject(paddingObject) {\n return Object.assign({}, getFreshSideObject(), paddingObject);\n}","export default function expandToHashMap(value, keys) {\n return keys.reduce(function (hashMap, key) {\n hashMap[key] = value;\n return hashMap;\n }, {});\n}","import getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getLayoutRect from \"../dom-utils/getLayoutRect.js\";\nimport contains from \"../dom-utils/contains.js\";\nimport getOffsetParent from \"../dom-utils/getOffsetParent.js\";\nimport getMainAxisFromPlacement from \"../utils/getMainAxisFromPlacement.js\";\nimport { within } from \"../utils/within.js\";\nimport mergePaddingObject from \"../utils/mergePaddingObject.js\";\nimport expandToHashMap from \"../utils/expandToHashMap.js\";\nimport { left, right, basePlacements, top, bottom } from \"../enums.js\"; // eslint-disable-next-line import/no-unused-modules\n\nvar toPaddingObject = function toPaddingObject(padding, state) {\n padding = typeof padding === 'function' ? padding(Object.assign({}, state.rects, {\n placement: state.placement\n })) : padding;\n return mergePaddingObject(typeof padding !== 'number' ? padding : expandToHashMap(padding, basePlacements));\n};\n\nfunction arrow(_ref) {\n var _state$modifiersData$;\n\n var state = _ref.state,\n name = _ref.name,\n options = _ref.options;\n var arrowElement = state.elements.arrow;\n var popperOffsets = state.modifiersData.popperOffsets;\n var basePlacement = getBasePlacement(state.placement);\n var axis = getMainAxisFromPlacement(basePlacement);\n var isVertical = [left, right].indexOf(basePlacement) >= 0;\n var len = isVertical ? 'height' : 'width';\n\n if (!arrowElement || !popperOffsets) {\n return;\n }\n\n var paddingObject = toPaddingObject(options.padding, state);\n var arrowRect = getLayoutRect(arrowElement);\n var minProp = axis === 'y' ? top : left;\n var maxProp = axis === 'y' ? bottom : right;\n var endDiff = state.rects.reference[len] + state.rects.reference[axis] - popperOffsets[axis] - state.rects.popper[len];\n var startDiff = popperOffsets[axis] - state.rects.reference[axis];\n var arrowOffsetParent = getOffsetParent(arrowElement);\n var clientSize = arrowOffsetParent ? axis === 'y' ? arrowOffsetParent.clientHeight || 0 : arrowOffsetParent.clientWidth || 0 : 0;\n var centerToReference = endDiff / 2 - startDiff / 2; // Make sure the arrow doesn't overflow the popper if the center point is\n // outside of the popper bounds\n\n var min = paddingObject[minProp];\n var max = clientSize - arrowRect[len] - paddingObject[maxProp];\n var center = clientSize / 2 - arrowRect[len] / 2 + centerToReference;\n var offset = within(min, center, max); // Prevents breaking syntax highlighting...\n\n var axisProp = axis;\n state.modifiersData[name] = (_state$modifiersData$ = {}, _state$modifiersData$[axisProp] = offset, _state$modifiersData$.centerOffset = offset - center, _state$modifiersData$);\n}\n\nfunction effect(_ref2) {\n var state = _ref2.state,\n options = _ref2.options;\n var _options$element = options.element,\n arrowElement = _options$element === void 0 ? '[data-popper-arrow]' : _options$element;\n\n if (arrowElement == null) {\n return;\n } // CSS selector\n\n\n if (typeof arrowElement === 'string') {\n arrowElement = state.elements.popper.querySelector(arrowElement);\n\n if (!arrowElement) {\n return;\n }\n }\n\n if (!contains(state.elements.popper, arrowElement)) {\n return;\n }\n\n state.elements.arrow = arrowElement;\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'arrow',\n enabled: true,\n phase: 'main',\n fn: arrow,\n effect: effect,\n requires: ['popperOffsets'],\n requiresIfExists: ['preventOverflow']\n};","export default function getVariation(placement) {\n return placement.split('-')[1];\n}","import { top, left, right, bottom, end } from \"../enums.js\";\nimport getOffsetParent from \"../dom-utils/getOffsetParent.js\";\nimport getWindow from \"../dom-utils/getWindow.js\";\nimport getDocumentElement from \"../dom-utils/getDocumentElement.js\";\nimport getComputedStyle from \"../dom-utils/getComputedStyle.js\";\nimport getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getVariation from \"../utils/getVariation.js\";\nimport { round } from \"../utils/math.js\"; // eslint-disable-next-line import/no-unused-modules\n\nvar unsetSides = {\n top: 'auto',\n right: 'auto',\n bottom: 'auto',\n left: 'auto'\n}; // Round the offsets to the nearest suitable subpixel based on the DPR.\n// Zooming can change the DPR, but it seems to report a value that will\n// cleanly divide the values into the appropriate subpixels.\n\nfunction roundOffsetsByDPR(_ref, win) {\n var x = _ref.x,\n y = _ref.y;\n var dpr = win.devicePixelRatio || 1;\n return {\n x: round(x * dpr) / dpr || 0,\n y: round(y * dpr) / dpr || 0\n };\n}\n\nexport function mapToStyles(_ref2) {\n var _Object$assign2;\n\n var popper = _ref2.popper,\n popperRect = _ref2.popperRect,\n placement = _ref2.placement,\n variation = _ref2.variation,\n offsets = _ref2.offsets,\n position = _ref2.position,\n gpuAcceleration = _ref2.gpuAcceleration,\n adaptive = _ref2.adaptive,\n roundOffsets = _ref2.roundOffsets,\n isFixed = _ref2.isFixed;\n var _offsets$x = offsets.x,\n x = _offsets$x === void 0 ? 0 : _offsets$x,\n _offsets$y = offsets.y,\n y = _offsets$y === void 0 ? 0 : _offsets$y;\n\n var _ref3 = typeof roundOffsets === 'function' ? roundOffsets({\n x: x,\n y: y\n }) : {\n x: x,\n y: y\n };\n\n x = _ref3.x;\n y = _ref3.y;\n var hasX = offsets.hasOwnProperty('x');\n var hasY = offsets.hasOwnProperty('y');\n var sideX = left;\n var sideY = top;\n var win = window;\n\n if (adaptive) {\n var offsetParent = getOffsetParent(popper);\n var heightProp = 'clientHeight';\n var widthProp = 'clientWidth';\n\n if (offsetParent === getWindow(popper)) {\n offsetParent = getDocumentElement(popper);\n\n if (getComputedStyle(offsetParent).position !== 'static' && position === 'absolute') {\n heightProp = 'scrollHeight';\n widthProp = 'scrollWidth';\n }\n } // $FlowFixMe[incompatible-cast]: force type refinement, we compare offsetParent with window above, but Flow doesn't detect it\n\n\n offsetParent = offsetParent;\n\n if (placement === top || (placement === left || placement === right) && variation === end) {\n sideY = bottom;\n var offsetY = isFixed && offsetParent === win && win.visualViewport ? win.visualViewport.height : // $FlowFixMe[prop-missing]\n offsetParent[heightProp];\n y -= offsetY - popperRect.height;\n y *= gpuAcceleration ? 1 : -1;\n }\n\n if (placement === left || (placement === top || placement === bottom) && variation === end) {\n sideX = right;\n var offsetX = isFixed && offsetParent === win && win.visualViewport ? win.visualViewport.width : // $FlowFixMe[prop-missing]\n offsetParent[widthProp];\n x -= offsetX - popperRect.width;\n x *= gpuAcceleration ? 1 : -1;\n }\n }\n\n var commonStyles = Object.assign({\n position: position\n }, adaptive && unsetSides);\n\n var _ref4 = roundOffsets === true ? roundOffsetsByDPR({\n x: x,\n y: y\n }, getWindow(popper)) : {\n x: x,\n y: y\n };\n\n x = _ref4.x;\n y = _ref4.y;\n\n if (gpuAcceleration) {\n var _Object$assign;\n\n return Object.assign({}, commonStyles, (_Object$assign = {}, _Object$assign[sideY] = hasY ? '0' : '', _Object$assign[sideX] = hasX ? '0' : '', _Object$assign.transform = (win.devicePixelRatio || 1) <= 1 ? \"translate(\" + x + \"px, \" + y + \"px)\" : \"translate3d(\" + x + \"px, \" + y + \"px, 0)\", _Object$assign));\n }\n\n return Object.assign({}, commonStyles, (_Object$assign2 = {}, _Object$assign2[sideY] = hasY ? y + \"px\" : '', _Object$assign2[sideX] = hasX ? x + \"px\" : '', _Object$assign2.transform = '', _Object$assign2));\n}\n\nfunction computeStyles(_ref5) {\n var state = _ref5.state,\n options = _ref5.options;\n var _options$gpuAccelerat = options.gpuAcceleration,\n gpuAcceleration = _options$gpuAccelerat === void 0 ? true : _options$gpuAccelerat,\n _options$adaptive = options.adaptive,\n adaptive = _options$adaptive === void 0 ? true : _options$adaptive,\n _options$roundOffsets = options.roundOffsets,\n roundOffsets = _options$roundOffsets === void 0 ? true : _options$roundOffsets;\n var commonStyles = {\n placement: getBasePlacement(state.placement),\n variation: getVariation(state.placement),\n popper: state.elements.popper,\n popperRect: state.rects.popper,\n gpuAcceleration: gpuAcceleration,\n isFixed: state.options.strategy === 'fixed'\n };\n\n if (state.modifiersData.popperOffsets != null) {\n state.styles.popper = Object.assign({}, state.styles.popper, mapToStyles(Object.assign({}, commonStyles, {\n offsets: state.modifiersData.popperOffsets,\n position: state.options.strategy,\n adaptive: adaptive,\n roundOffsets: roundOffsets\n })));\n }\n\n if (state.modifiersData.arrow != null) {\n state.styles.arrow = Object.assign({}, state.styles.arrow, mapToStyles(Object.assign({}, commonStyles, {\n offsets: state.modifiersData.arrow,\n position: 'absolute',\n adaptive: false,\n roundOffsets: roundOffsets\n })));\n }\n\n state.attributes.popper = Object.assign({}, state.attributes.popper, {\n 'data-popper-placement': state.placement\n });\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'computeStyles',\n enabled: true,\n phase: 'beforeWrite',\n fn: computeStyles,\n data: {}\n};","import getWindow from \"../dom-utils/getWindow.js\"; // eslint-disable-next-line import/no-unused-modules\n\nvar passive = {\n passive: true\n};\n\nfunction effect(_ref) {\n var state = _ref.state,\n instance = _ref.instance,\n options = _ref.options;\n var _options$scroll = options.scroll,\n scroll = _options$scroll === void 0 ? true : _options$scroll,\n _options$resize = options.resize,\n resize = _options$resize === void 0 ? true : _options$resize;\n var window = getWindow(state.elements.popper);\n var scrollParents = [].concat(state.scrollParents.reference, state.scrollParents.popper);\n\n if (scroll) {\n scrollParents.forEach(function (scrollParent) {\n scrollParent.addEventListener('scroll', instance.update, passive);\n });\n }\n\n if (resize) {\n window.addEventListener('resize', instance.update, passive);\n }\n\n return function () {\n if (scroll) {\n scrollParents.forEach(function (scrollParent) {\n scrollParent.removeEventListener('scroll', instance.update, passive);\n });\n }\n\n if (resize) {\n window.removeEventListener('resize', instance.update, passive);\n }\n };\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'eventListeners',\n enabled: true,\n phase: 'write',\n fn: function fn() {},\n effect: effect,\n data: {}\n};","var hash = {\n left: 'right',\n right: 'left',\n bottom: 'top',\n top: 'bottom'\n};\nexport default function getOppositePlacement(placement) {\n return placement.replace(/left|right|bottom|top/g, function (matched) {\n return hash[matched];\n });\n}","var hash = {\n start: 'end',\n end: 'start'\n};\nexport default function getOppositeVariationPlacement(placement) {\n return placement.replace(/start|end/g, function (matched) {\n return hash[matched];\n });\n}","import getWindow from \"./getWindow.js\";\nexport default function getWindowScroll(node) {\n var win = getWindow(node);\n var scrollLeft = win.pageXOffset;\n var scrollTop = win.pageYOffset;\n return {\n scrollLeft: scrollLeft,\n scrollTop: scrollTop\n };\n}","import getBoundingClientRect from \"./getBoundingClientRect.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport getWindowScroll from \"./getWindowScroll.js\";\nexport default function getWindowScrollBarX(element) {\n // If has a CSS width greater than the viewport, then this will be\n // incorrect for RTL.\n // Popper 1 is broken in this case and never had a bug report so let's assume\n // it's not an issue. I don't think anyone ever specifies width on \n // anyway.\n // Browsers where the left scrollbar doesn't cause an issue report `0` for\n // this (e.g. Edge 2019, IE11, Safari)\n return getBoundingClientRect(getDocumentElement(element)).left + getWindowScroll(element).scrollLeft;\n}","import getWindow from \"./getWindow.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport getWindowScrollBarX from \"./getWindowScrollBarX.js\";\nimport isLayoutViewport from \"./isLayoutViewport.js\";\nexport default function getViewportRect(element, strategy) {\n var win = getWindow(element);\n var html = getDocumentElement(element);\n var visualViewport = win.visualViewport;\n var width = html.clientWidth;\n var height = html.clientHeight;\n var x = 0;\n var y = 0;\n\n if (visualViewport) {\n width = visualViewport.width;\n height = visualViewport.height;\n var layoutViewport = isLayoutViewport();\n\n if (layoutViewport || !layoutViewport && strategy === 'fixed') {\n x = visualViewport.offsetLeft;\n y = visualViewport.offsetTop;\n }\n }\n\n return {\n width: width,\n height: height,\n x: x + getWindowScrollBarX(element),\n y: y\n };\n}","import getDocumentElement from \"./getDocumentElement.js\";\nimport getComputedStyle from \"./getComputedStyle.js\";\nimport getWindowScrollBarX from \"./getWindowScrollBarX.js\";\nimport getWindowScroll from \"./getWindowScroll.js\";\nimport { max } from \"../utils/math.js\"; // Gets the entire size of the scrollable document area, even extending outside\n// of the `` and `` rect bounds if horizontally scrollable\n\nexport default function getDocumentRect(element) {\n var _element$ownerDocumen;\n\n var html = getDocumentElement(element);\n var winScroll = getWindowScroll(element);\n var body = (_element$ownerDocumen = element.ownerDocument) == null ? void 0 : _element$ownerDocumen.body;\n var width = max(html.scrollWidth, html.clientWidth, body ? body.scrollWidth : 0, body ? body.clientWidth : 0);\n var height = max(html.scrollHeight, html.clientHeight, body ? body.scrollHeight : 0, body ? body.clientHeight : 0);\n var x = -winScroll.scrollLeft + getWindowScrollBarX(element);\n var y = -winScroll.scrollTop;\n\n if (getComputedStyle(body || html).direction === 'rtl') {\n x += max(html.clientWidth, body ? body.clientWidth : 0) - width;\n }\n\n return {\n width: width,\n height: height,\n x: x,\n y: y\n };\n}","import getComputedStyle from \"./getComputedStyle.js\";\nexport default function isScrollParent(element) {\n // Firefox wants us to check `-x` and `-y` variations as well\n var _getComputedStyle = getComputedStyle(element),\n overflow = _getComputedStyle.overflow,\n overflowX = _getComputedStyle.overflowX,\n overflowY = _getComputedStyle.overflowY;\n\n return /auto|scroll|overlay|hidden/.test(overflow + overflowY + overflowX);\n}","import getParentNode from \"./getParentNode.js\";\nimport isScrollParent from \"./isScrollParent.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport { isHTMLElement } from \"./instanceOf.js\";\nexport default function getScrollParent(node) {\n if (['html', 'body', '#document'].indexOf(getNodeName(node)) >= 0) {\n // $FlowFixMe[incompatible-return]: assume body is always available\n return node.ownerDocument.body;\n }\n\n if (isHTMLElement(node) && isScrollParent(node)) {\n return node;\n }\n\n return getScrollParent(getParentNode(node));\n}","import getScrollParent from \"./getScrollParent.js\";\nimport getParentNode from \"./getParentNode.js\";\nimport getWindow from \"./getWindow.js\";\nimport isScrollParent from \"./isScrollParent.js\";\n/*\ngiven a DOM element, return the list of all scroll parents, up the list of ancesors\nuntil we get to the top window object. This list is what we attach scroll listeners\nto, because if any of these parent elements scroll, we'll need to re-calculate the\nreference element's position.\n*/\n\nexport default function listScrollParents(element, list) {\n var _element$ownerDocumen;\n\n if (list === void 0) {\n list = [];\n }\n\n var scrollParent = getScrollParent(element);\n var isBody = scrollParent === ((_element$ownerDocumen = element.ownerDocument) == null ? void 0 : _element$ownerDocumen.body);\n var win = getWindow(scrollParent);\n var target = isBody ? [win].concat(win.visualViewport || [], isScrollParent(scrollParent) ? scrollParent : []) : scrollParent;\n var updatedList = list.concat(target);\n return isBody ? updatedList : // $FlowFixMe[incompatible-call]: isBody tells us target will be an HTMLElement here\n updatedList.concat(listScrollParents(getParentNode(target)));\n}","export default function rectToClientRect(rect) {\n return Object.assign({}, rect, {\n left: rect.x,\n top: rect.y,\n right: rect.x + rect.width,\n bottom: rect.y + rect.height\n });\n}","import { viewport } from \"../enums.js\";\nimport getViewportRect from \"./getViewportRect.js\";\nimport getDocumentRect from \"./getDocumentRect.js\";\nimport listScrollParents from \"./listScrollParents.js\";\nimport getOffsetParent from \"./getOffsetParent.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport getComputedStyle from \"./getComputedStyle.js\";\nimport { isElement, isHTMLElement } from \"./instanceOf.js\";\nimport getBoundingClientRect from \"./getBoundingClientRect.js\";\nimport getParentNode from \"./getParentNode.js\";\nimport contains from \"./contains.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport rectToClientRect from \"../utils/rectToClientRect.js\";\nimport { max, min } from \"../utils/math.js\";\n\nfunction getInnerBoundingClientRect(element, strategy) {\n var rect = getBoundingClientRect(element, false, strategy === 'fixed');\n rect.top = rect.top + element.clientTop;\n rect.left = rect.left + element.clientLeft;\n rect.bottom = rect.top + element.clientHeight;\n rect.right = rect.left + element.clientWidth;\n rect.width = element.clientWidth;\n rect.height = element.clientHeight;\n rect.x = rect.left;\n rect.y = rect.top;\n return rect;\n}\n\nfunction getClientRectFromMixedType(element, clippingParent, strategy) {\n return clippingParent === viewport ? rectToClientRect(getViewportRect(element, strategy)) : isElement(clippingParent) ? getInnerBoundingClientRect(clippingParent, strategy) : rectToClientRect(getDocumentRect(getDocumentElement(element)));\n} // A \"clipping parent\" is an overflowable container with the characteristic of\n// clipping (or hiding) overflowing elements with a position different from\n// `initial`\n\n\nfunction getClippingParents(element) {\n var clippingParents = listScrollParents(getParentNode(element));\n var canEscapeClipping = ['absolute', 'fixed'].indexOf(getComputedStyle(element).position) >= 0;\n var clipperElement = canEscapeClipping && isHTMLElement(element) ? getOffsetParent(element) : element;\n\n if (!isElement(clipperElement)) {\n return [];\n } // $FlowFixMe[incompatible-return]: https://github.com/facebook/flow/issues/1414\n\n\n return clippingParents.filter(function (clippingParent) {\n return isElement(clippingParent) && contains(clippingParent, clipperElement) && getNodeName(clippingParent) !== 'body';\n });\n} // Gets the maximum area that the element is visible in due to any number of\n// clipping parents\n\n\nexport default function getClippingRect(element, boundary, rootBoundary, strategy) {\n var mainClippingParents = boundary === 'clippingParents' ? getClippingParents(element) : [].concat(boundary);\n var clippingParents = [].concat(mainClippingParents, [rootBoundary]);\n var firstClippingParent = clippingParents[0];\n var clippingRect = clippingParents.reduce(function (accRect, clippingParent) {\n var rect = getClientRectFromMixedType(element, clippingParent, strategy);\n accRect.top = max(rect.top, accRect.top);\n accRect.right = min(rect.right, accRect.right);\n accRect.bottom = min(rect.bottom, accRect.bottom);\n accRect.left = max(rect.left, accRect.left);\n return accRect;\n }, getClientRectFromMixedType(element, firstClippingParent, strategy));\n clippingRect.width = clippingRect.right - clippingRect.left;\n clippingRect.height = clippingRect.bottom - clippingRect.top;\n clippingRect.x = clippingRect.left;\n clippingRect.y = clippingRect.top;\n return clippingRect;\n}","import getBasePlacement from \"./getBasePlacement.js\";\nimport getVariation from \"./getVariation.js\";\nimport getMainAxisFromPlacement from \"./getMainAxisFromPlacement.js\";\nimport { top, right, bottom, left, start, end } from \"../enums.js\";\nexport default function computeOffsets(_ref) {\n var reference = _ref.reference,\n element = _ref.element,\n placement = _ref.placement;\n var basePlacement = placement ? getBasePlacement(placement) : null;\n var variation = placement ? getVariation(placement) : null;\n var commonX = reference.x + reference.width / 2 - element.width / 2;\n var commonY = reference.y + reference.height / 2 - element.height / 2;\n var offsets;\n\n switch (basePlacement) {\n case top:\n offsets = {\n x: commonX,\n y: reference.y - element.height\n };\n break;\n\n case bottom:\n offsets = {\n x: commonX,\n y: reference.y + reference.height\n };\n break;\n\n case right:\n offsets = {\n x: reference.x + reference.width,\n y: commonY\n };\n break;\n\n case left:\n offsets = {\n x: reference.x - element.width,\n y: commonY\n };\n break;\n\n default:\n offsets = {\n x: reference.x,\n y: reference.y\n };\n }\n\n var mainAxis = basePlacement ? getMainAxisFromPlacement(basePlacement) : null;\n\n if (mainAxis != null) {\n var len = mainAxis === 'y' ? 'height' : 'width';\n\n switch (variation) {\n case start:\n offsets[mainAxis] = offsets[mainAxis] - (reference[len] / 2 - element[len] / 2);\n break;\n\n case end:\n offsets[mainAxis] = offsets[mainAxis] + (reference[len] / 2 - element[len] / 2);\n break;\n\n default:\n }\n }\n\n return offsets;\n}","import getClippingRect from \"../dom-utils/getClippingRect.js\";\nimport getDocumentElement from \"../dom-utils/getDocumentElement.js\";\nimport getBoundingClientRect from \"../dom-utils/getBoundingClientRect.js\";\nimport computeOffsets from \"./computeOffsets.js\";\nimport rectToClientRect from \"./rectToClientRect.js\";\nimport { clippingParents, reference, popper, bottom, top, right, basePlacements, viewport } from \"../enums.js\";\nimport { isElement } from \"../dom-utils/instanceOf.js\";\nimport mergePaddingObject from \"./mergePaddingObject.js\";\nimport expandToHashMap from \"./expandToHashMap.js\"; // eslint-disable-next-line import/no-unused-modules\n\nexport default function detectOverflow(state, options) {\n if (options === void 0) {\n options = {};\n }\n\n var _options = options,\n _options$placement = _options.placement,\n placement = _options$placement === void 0 ? state.placement : _options$placement,\n _options$strategy = _options.strategy,\n strategy = _options$strategy === void 0 ? state.strategy : _options$strategy,\n _options$boundary = _options.boundary,\n boundary = _options$boundary === void 0 ? clippingParents : _options$boundary,\n _options$rootBoundary = _options.rootBoundary,\n rootBoundary = _options$rootBoundary === void 0 ? viewport : _options$rootBoundary,\n _options$elementConte = _options.elementContext,\n elementContext = _options$elementConte === void 0 ? popper : _options$elementConte,\n _options$altBoundary = _options.altBoundary,\n altBoundary = _options$altBoundary === void 0 ? false : _options$altBoundary,\n _options$padding = _options.padding,\n padding = _options$padding === void 0 ? 0 : _options$padding;\n var paddingObject = mergePaddingObject(typeof padding !== 'number' ? padding : expandToHashMap(padding, basePlacements));\n var altContext = elementContext === popper ? reference : popper;\n var popperRect = state.rects.popper;\n var element = state.elements[altBoundary ? altContext : elementContext];\n var clippingClientRect = getClippingRect(isElement(element) ? element : element.contextElement || getDocumentElement(state.elements.popper), boundary, rootBoundary, strategy);\n var referenceClientRect = getBoundingClientRect(state.elements.reference);\n var popperOffsets = computeOffsets({\n reference: referenceClientRect,\n element: popperRect,\n strategy: 'absolute',\n placement: placement\n });\n var popperClientRect = rectToClientRect(Object.assign({}, popperRect, popperOffsets));\n var elementClientRect = elementContext === popper ? popperClientRect : referenceClientRect; // positive = overflowing the clipping rect\n // 0 or negative = within the clipping rect\n\n var overflowOffsets = {\n top: clippingClientRect.top - elementClientRect.top + paddingObject.top,\n bottom: elementClientRect.bottom - clippingClientRect.bottom + paddingObject.bottom,\n left: clippingClientRect.left - elementClientRect.left + paddingObject.left,\n right: elementClientRect.right - clippingClientRect.right + paddingObject.right\n };\n var offsetData = state.modifiersData.offset; // Offsets can be applied only to the popper element\n\n if (elementContext === popper && offsetData) {\n var offset = offsetData[placement];\n Object.keys(overflowOffsets).forEach(function (key) {\n var multiply = [right, bottom].indexOf(key) >= 0 ? 1 : -1;\n var axis = [top, bottom].indexOf(key) >= 0 ? 'y' : 'x';\n overflowOffsets[key] += offset[axis] * multiply;\n });\n }\n\n return overflowOffsets;\n}","import getVariation from \"./getVariation.js\";\nimport { variationPlacements, basePlacements, placements as allPlacements } from \"../enums.js\";\nimport detectOverflow from \"./detectOverflow.js\";\nimport getBasePlacement from \"./getBasePlacement.js\";\nexport default function computeAutoPlacement(state, options) {\n if (options === void 0) {\n options = {};\n }\n\n var _options = options,\n placement = _options.placement,\n boundary = _options.boundary,\n rootBoundary = _options.rootBoundary,\n padding = _options.padding,\n flipVariations = _options.flipVariations,\n _options$allowedAutoP = _options.allowedAutoPlacements,\n allowedAutoPlacements = _options$allowedAutoP === void 0 ? allPlacements : _options$allowedAutoP;\n var variation = getVariation(placement);\n var placements = variation ? flipVariations ? variationPlacements : variationPlacements.filter(function (placement) {\n return getVariation(placement) === variation;\n }) : basePlacements;\n var allowedPlacements = placements.filter(function (placement) {\n return allowedAutoPlacements.indexOf(placement) >= 0;\n });\n\n if (allowedPlacements.length === 0) {\n allowedPlacements = placements;\n } // $FlowFixMe[incompatible-type]: Flow seems to have problems with two array unions...\n\n\n var overflows = allowedPlacements.reduce(function (acc, placement) {\n acc[placement] = detectOverflow(state, {\n placement: placement,\n boundary: boundary,\n rootBoundary: rootBoundary,\n padding: padding\n })[getBasePlacement(placement)];\n return acc;\n }, {});\n return Object.keys(overflows).sort(function (a, b) {\n return overflows[a] - overflows[b];\n });\n}","import getOppositePlacement from \"../utils/getOppositePlacement.js\";\nimport getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getOppositeVariationPlacement from \"../utils/getOppositeVariationPlacement.js\";\nimport detectOverflow from \"../utils/detectOverflow.js\";\nimport computeAutoPlacement from \"../utils/computeAutoPlacement.js\";\nimport { bottom, top, start, right, left, auto } from \"../enums.js\";\nimport getVariation from \"../utils/getVariation.js\"; // eslint-disable-next-line import/no-unused-modules\n\nfunction getExpandedFallbackPlacements(placement) {\n if (getBasePlacement(placement) === auto) {\n return [];\n }\n\n var oppositePlacement = getOppositePlacement(placement);\n return [getOppositeVariationPlacement(placement), oppositePlacement, getOppositeVariationPlacement(oppositePlacement)];\n}\n\nfunction flip(_ref) {\n var state = _ref.state,\n options = _ref.options,\n name = _ref.name;\n\n if (state.modifiersData[name]._skip) {\n return;\n }\n\n var _options$mainAxis = options.mainAxis,\n checkMainAxis = _options$mainAxis === void 0 ? true : _options$mainAxis,\n _options$altAxis = options.altAxis,\n checkAltAxis = _options$altAxis === void 0 ? true : _options$altAxis,\n specifiedFallbackPlacements = options.fallbackPlacements,\n padding = options.padding,\n boundary = options.boundary,\n rootBoundary = options.rootBoundary,\n altBoundary = options.altBoundary,\n _options$flipVariatio = options.flipVariations,\n flipVariations = _options$flipVariatio === void 0 ? true : _options$flipVariatio,\n allowedAutoPlacements = options.allowedAutoPlacements;\n var preferredPlacement = state.options.placement;\n var basePlacement = getBasePlacement(preferredPlacement);\n var isBasePlacement = basePlacement === preferredPlacement;\n var fallbackPlacements = specifiedFallbackPlacements || (isBasePlacement || !flipVariations ? [getOppositePlacement(preferredPlacement)] : getExpandedFallbackPlacements(preferredPlacement));\n var placements = [preferredPlacement].concat(fallbackPlacements).reduce(function (acc, placement) {\n return acc.concat(getBasePlacement(placement) === auto ? computeAutoPlacement(state, {\n placement: placement,\n boundary: boundary,\n rootBoundary: rootBoundary,\n padding: padding,\n flipVariations: flipVariations,\n allowedAutoPlacements: allowedAutoPlacements\n }) : placement);\n }, []);\n var referenceRect = state.rects.reference;\n var popperRect = state.rects.popper;\n var checksMap = new Map();\n var makeFallbackChecks = true;\n var firstFittingPlacement = placements[0];\n\n for (var i = 0; i < placements.length; i++) {\n var placement = placements[i];\n\n var _basePlacement = getBasePlacement(placement);\n\n var isStartVariation = getVariation(placement) === start;\n var isVertical = [top, bottom].indexOf(_basePlacement) >= 0;\n var len = isVertical ? 'width' : 'height';\n var overflow = detectOverflow(state, {\n placement: placement,\n boundary: boundary,\n rootBoundary: rootBoundary,\n altBoundary: altBoundary,\n padding: padding\n });\n var mainVariationSide = isVertical ? isStartVariation ? right : left : isStartVariation ? bottom : top;\n\n if (referenceRect[len] > popperRect[len]) {\n mainVariationSide = getOppositePlacement(mainVariationSide);\n }\n\n var altVariationSide = getOppositePlacement(mainVariationSide);\n var checks = [];\n\n if (checkMainAxis) {\n checks.push(overflow[_basePlacement] <= 0);\n }\n\n if (checkAltAxis) {\n checks.push(overflow[mainVariationSide] <= 0, overflow[altVariationSide] <= 0);\n }\n\n if (checks.every(function (check) {\n return check;\n })) {\n firstFittingPlacement = placement;\n makeFallbackChecks = false;\n break;\n }\n\n checksMap.set(placement, checks);\n }\n\n if (makeFallbackChecks) {\n // `2` may be desired in some cases – research later\n var numberOfChecks = flipVariations ? 3 : 1;\n\n var _loop = function _loop(_i) {\n var fittingPlacement = placements.find(function (placement) {\n var checks = checksMap.get(placement);\n\n if (checks) {\n return checks.slice(0, _i).every(function (check) {\n return check;\n });\n }\n });\n\n if (fittingPlacement) {\n firstFittingPlacement = fittingPlacement;\n return \"break\";\n }\n };\n\n for (var _i = numberOfChecks; _i > 0; _i--) {\n var _ret = _loop(_i);\n\n if (_ret === \"break\") break;\n }\n }\n\n if (state.placement !== firstFittingPlacement) {\n state.modifiersData[name]._skip = true;\n state.placement = firstFittingPlacement;\n state.reset = true;\n }\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'flip',\n enabled: true,\n phase: 'main',\n fn: flip,\n requiresIfExists: ['offset'],\n data: {\n _skip: false\n }\n};","import { top, bottom, left, right } from \"../enums.js\";\nimport detectOverflow from \"../utils/detectOverflow.js\";\n\nfunction getSideOffsets(overflow, rect, preventedOffsets) {\n if (preventedOffsets === void 0) {\n preventedOffsets = {\n x: 0,\n y: 0\n };\n }\n\n return {\n top: overflow.top - rect.height - preventedOffsets.y,\n right: overflow.right - rect.width + preventedOffsets.x,\n bottom: overflow.bottom - rect.height + preventedOffsets.y,\n left: overflow.left - rect.width - preventedOffsets.x\n };\n}\n\nfunction isAnySideFullyClipped(overflow) {\n return [top, right, bottom, left].some(function (side) {\n return overflow[side] >= 0;\n });\n}\n\nfunction hide(_ref) {\n var state = _ref.state,\n name = _ref.name;\n var referenceRect = state.rects.reference;\n var popperRect = state.rects.popper;\n var preventedOffsets = state.modifiersData.preventOverflow;\n var referenceOverflow = detectOverflow(state, {\n elementContext: 'reference'\n });\n var popperAltOverflow = detectOverflow(state, {\n altBoundary: true\n });\n var referenceClippingOffsets = getSideOffsets(referenceOverflow, referenceRect);\n var popperEscapeOffsets = getSideOffsets(popperAltOverflow, popperRect, preventedOffsets);\n var isReferenceHidden = isAnySideFullyClipped(referenceClippingOffsets);\n var hasPopperEscaped = isAnySideFullyClipped(popperEscapeOffsets);\n state.modifiersData[name] = {\n referenceClippingOffsets: referenceClippingOffsets,\n popperEscapeOffsets: popperEscapeOffsets,\n isReferenceHidden: isReferenceHidden,\n hasPopperEscaped: hasPopperEscaped\n };\n state.attributes.popper = Object.assign({}, state.attributes.popper, {\n 'data-popper-reference-hidden': isReferenceHidden,\n 'data-popper-escaped': hasPopperEscaped\n });\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'hide',\n enabled: true,\n phase: 'main',\n requiresIfExists: ['preventOverflow'],\n fn: hide\n};","import getBasePlacement from \"../utils/getBasePlacement.js\";\nimport { top, left, right, placements } from \"../enums.js\"; // eslint-disable-next-line import/no-unused-modules\n\nexport function distanceAndSkiddingToXY(placement, rects, offset) {\n var basePlacement = getBasePlacement(placement);\n var invertDistance = [left, top].indexOf(basePlacement) >= 0 ? -1 : 1;\n\n var _ref = typeof offset === 'function' ? offset(Object.assign({}, rects, {\n placement: placement\n })) : offset,\n skidding = _ref[0],\n distance = _ref[1];\n\n skidding = skidding || 0;\n distance = (distance || 0) * invertDistance;\n return [left, right].indexOf(basePlacement) >= 0 ? {\n x: distance,\n y: skidding\n } : {\n x: skidding,\n y: distance\n };\n}\n\nfunction offset(_ref2) {\n var state = _ref2.state,\n options = _ref2.options,\n name = _ref2.name;\n var _options$offset = options.offset,\n offset = _options$offset === void 0 ? [0, 0] : _options$offset;\n var data = placements.reduce(function (acc, placement) {\n acc[placement] = distanceAndSkiddingToXY(placement, state.rects, offset);\n return acc;\n }, {});\n var _data$state$placement = data[state.placement],\n x = _data$state$placement.x,\n y = _data$state$placement.y;\n\n if (state.modifiersData.popperOffsets != null) {\n state.modifiersData.popperOffsets.x += x;\n state.modifiersData.popperOffsets.y += y;\n }\n\n state.modifiersData[name] = data;\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'offset',\n enabled: true,\n phase: 'main',\n requires: ['popperOffsets'],\n fn: offset\n};","import computeOffsets from \"../utils/computeOffsets.js\";\n\nfunction popperOffsets(_ref) {\n var state = _ref.state,\n name = _ref.name;\n // Offsets are the actual position the popper needs to have to be\n // properly positioned near its reference element\n // This is the most basic placement, and will be adjusted by\n // the modifiers in the next step\n state.modifiersData[name] = computeOffsets({\n reference: state.rects.reference,\n element: state.rects.popper,\n strategy: 'absolute',\n placement: state.placement\n });\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'popperOffsets',\n enabled: true,\n phase: 'read',\n fn: popperOffsets,\n data: {}\n};","export default function getAltAxis(axis) {\n return axis === 'x' ? 'y' : 'x';\n}","import { top, left, right, bottom, start } from \"../enums.js\";\nimport getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getMainAxisFromPlacement from \"../utils/getMainAxisFromPlacement.js\";\nimport getAltAxis from \"../utils/getAltAxis.js\";\nimport { within, withinMaxClamp } from \"../utils/within.js\";\nimport getLayoutRect from \"../dom-utils/getLayoutRect.js\";\nimport getOffsetParent from \"../dom-utils/getOffsetParent.js\";\nimport detectOverflow from \"../utils/detectOverflow.js\";\nimport getVariation from \"../utils/getVariation.js\";\nimport getFreshSideObject from \"../utils/getFreshSideObject.js\";\nimport { min as mathMin, max as mathMax } from \"../utils/math.js\";\n\nfunction preventOverflow(_ref) {\n var state = _ref.state,\n options = _ref.options,\n name = _ref.name;\n var _options$mainAxis = options.mainAxis,\n checkMainAxis = _options$mainAxis === void 0 ? true : _options$mainAxis,\n _options$altAxis = options.altAxis,\n checkAltAxis = _options$altAxis === void 0 ? false : _options$altAxis,\n boundary = options.boundary,\n rootBoundary = options.rootBoundary,\n altBoundary = options.altBoundary,\n padding = options.padding,\n _options$tether = options.tether,\n tether = _options$tether === void 0 ? true : _options$tether,\n _options$tetherOffset = options.tetherOffset,\n tetherOffset = _options$tetherOffset === void 0 ? 0 : _options$tetherOffset;\n var overflow = detectOverflow(state, {\n boundary: boundary,\n rootBoundary: rootBoundary,\n padding: padding,\n altBoundary: altBoundary\n });\n var basePlacement = getBasePlacement(state.placement);\n var variation = getVariation(state.placement);\n var isBasePlacement = !variation;\n var mainAxis = getMainAxisFromPlacement(basePlacement);\n var altAxis = getAltAxis(mainAxis);\n var popperOffsets = state.modifiersData.popperOffsets;\n var referenceRect = state.rects.reference;\n var popperRect = state.rects.popper;\n var tetherOffsetValue = typeof tetherOffset === 'function' ? tetherOffset(Object.assign({}, state.rects, {\n placement: state.placement\n })) : tetherOffset;\n var normalizedTetherOffsetValue = typeof tetherOffsetValue === 'number' ? {\n mainAxis: tetherOffsetValue,\n altAxis: tetherOffsetValue\n } : Object.assign({\n mainAxis: 0,\n altAxis: 0\n }, tetherOffsetValue);\n var offsetModifierState = state.modifiersData.offset ? state.modifiersData.offset[state.placement] : null;\n var data = {\n x: 0,\n y: 0\n };\n\n if (!popperOffsets) {\n return;\n }\n\n if (checkMainAxis) {\n var _offsetModifierState$;\n\n var mainSide = mainAxis === 'y' ? top : left;\n var altSide = mainAxis === 'y' ? bottom : right;\n var len = mainAxis === 'y' ? 'height' : 'width';\n var offset = popperOffsets[mainAxis];\n var min = offset + overflow[mainSide];\n var max = offset - overflow[altSide];\n var additive = tether ? -popperRect[len] / 2 : 0;\n var minLen = variation === start ? referenceRect[len] : popperRect[len];\n var maxLen = variation === start ? -popperRect[len] : -referenceRect[len]; // We need to include the arrow in the calculation so the arrow doesn't go\n // outside the reference bounds\n\n var arrowElement = state.elements.arrow;\n var arrowRect = tether && arrowElement ? getLayoutRect(arrowElement) : {\n width: 0,\n height: 0\n };\n var arrowPaddingObject = state.modifiersData['arrow#persistent'] ? state.modifiersData['arrow#persistent'].padding : getFreshSideObject();\n var arrowPaddingMin = arrowPaddingObject[mainSide];\n var arrowPaddingMax = arrowPaddingObject[altSide]; // If the reference length is smaller than the arrow length, we don't want\n // to include its full size in the calculation. If the reference is small\n // and near the edge of a boundary, the popper can overflow even if the\n // reference is not overflowing as well (e.g. virtual elements with no\n // width or height)\n\n var arrowLen = within(0, referenceRect[len], arrowRect[len]);\n var minOffset = isBasePlacement ? referenceRect[len] / 2 - additive - arrowLen - arrowPaddingMin - normalizedTetherOffsetValue.mainAxis : minLen - arrowLen - arrowPaddingMin - normalizedTetherOffsetValue.mainAxis;\n var maxOffset = isBasePlacement ? -referenceRect[len] / 2 + additive + arrowLen + arrowPaddingMax + normalizedTetherOffsetValue.mainAxis : maxLen + arrowLen + arrowPaddingMax + normalizedTetherOffsetValue.mainAxis;\n var arrowOffsetParent = state.elements.arrow && getOffsetParent(state.elements.arrow);\n var clientOffset = arrowOffsetParent ? mainAxis === 'y' ? arrowOffsetParent.clientTop || 0 : arrowOffsetParent.clientLeft || 0 : 0;\n var offsetModifierValue = (_offsetModifierState$ = offsetModifierState == null ? void 0 : offsetModifierState[mainAxis]) != null ? _offsetModifierState$ : 0;\n var tetherMin = offset + minOffset - offsetModifierValue - clientOffset;\n var tetherMax = offset + maxOffset - offsetModifierValue;\n var preventedOffset = within(tether ? mathMin(min, tetherMin) : min, offset, tether ? mathMax(max, tetherMax) : max);\n popperOffsets[mainAxis] = preventedOffset;\n data[mainAxis] = preventedOffset - offset;\n }\n\n if (checkAltAxis) {\n var _offsetModifierState$2;\n\n var _mainSide = mainAxis === 'x' ? top : left;\n\n var _altSide = mainAxis === 'x' ? bottom : right;\n\n var _offset = popperOffsets[altAxis];\n\n var _len = altAxis === 'y' ? 'height' : 'width';\n\n var _min = _offset + overflow[_mainSide];\n\n var _max = _offset - overflow[_altSide];\n\n var isOriginSide = [top, left].indexOf(basePlacement) !== -1;\n\n var _offsetModifierValue = (_offsetModifierState$2 = offsetModifierState == null ? void 0 : offsetModifierState[altAxis]) != null ? _offsetModifierState$2 : 0;\n\n var _tetherMin = isOriginSide ? _min : _offset - referenceRect[_len] - popperRect[_len] - _offsetModifierValue + normalizedTetherOffsetValue.altAxis;\n\n var _tetherMax = isOriginSide ? _offset + referenceRect[_len] + popperRect[_len] - _offsetModifierValue - normalizedTetherOffsetValue.altAxis : _max;\n\n var _preventedOffset = tether && isOriginSide ? withinMaxClamp(_tetherMin, _offset, _tetherMax) : within(tether ? _tetherMin : _min, _offset, tether ? _tetherMax : _max);\n\n popperOffsets[altAxis] = _preventedOffset;\n data[altAxis] = _preventedOffset - _offset;\n }\n\n state.modifiersData[name] = data;\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'preventOverflow',\n enabled: true,\n phase: 'main',\n fn: preventOverflow,\n requiresIfExists: ['offset']\n};","export default function getHTMLElementScroll(element) {\n return {\n scrollLeft: element.scrollLeft,\n scrollTop: element.scrollTop\n };\n}","import getWindowScroll from \"./getWindowScroll.js\";\nimport getWindow from \"./getWindow.js\";\nimport { isHTMLElement } from \"./instanceOf.js\";\nimport getHTMLElementScroll from \"./getHTMLElementScroll.js\";\nexport default function getNodeScroll(node) {\n if (node === getWindow(node) || !isHTMLElement(node)) {\n return getWindowScroll(node);\n } else {\n return getHTMLElementScroll(node);\n }\n}","import getBoundingClientRect from \"./getBoundingClientRect.js\";\nimport getNodeScroll from \"./getNodeScroll.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport { isHTMLElement } from \"./instanceOf.js\";\nimport getWindowScrollBarX from \"./getWindowScrollBarX.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport isScrollParent from \"./isScrollParent.js\";\nimport { round } from \"../utils/math.js\";\n\nfunction isElementScaled(element) {\n var rect = element.getBoundingClientRect();\n var scaleX = round(rect.width) / element.offsetWidth || 1;\n var scaleY = round(rect.height) / element.offsetHeight || 1;\n return scaleX !== 1 || scaleY !== 1;\n} // Returns the composite rect of an element relative to its offsetParent.\n// Composite means it takes into account transforms as well as layout.\n\n\nexport default function getCompositeRect(elementOrVirtualElement, offsetParent, isFixed) {\n if (isFixed === void 0) {\n isFixed = false;\n }\n\n var isOffsetParentAnElement = isHTMLElement(offsetParent);\n var offsetParentIsScaled = isHTMLElement(offsetParent) && isElementScaled(offsetParent);\n var documentElement = getDocumentElement(offsetParent);\n var rect = getBoundingClientRect(elementOrVirtualElement, offsetParentIsScaled, isFixed);\n var scroll = {\n scrollLeft: 0,\n scrollTop: 0\n };\n var offsets = {\n x: 0,\n y: 0\n };\n\n if (isOffsetParentAnElement || !isOffsetParentAnElement && !isFixed) {\n if (getNodeName(offsetParent) !== 'body' || // https://github.com/popperjs/popper-core/issues/1078\n isScrollParent(documentElement)) {\n scroll = getNodeScroll(offsetParent);\n }\n\n if (isHTMLElement(offsetParent)) {\n offsets = getBoundingClientRect(offsetParent, true);\n offsets.x += offsetParent.clientLeft;\n offsets.y += offsetParent.clientTop;\n } else if (documentElement) {\n offsets.x = getWindowScrollBarX(documentElement);\n }\n }\n\n return {\n x: rect.left + scroll.scrollLeft - offsets.x,\n y: rect.top + scroll.scrollTop - offsets.y,\n width: rect.width,\n height: rect.height\n };\n}","import { modifierPhases } from \"../enums.js\"; // source: https://stackoverflow.com/questions/49875255\n\nfunction order(modifiers) {\n var map = new Map();\n var visited = new Set();\n var result = [];\n modifiers.forEach(function (modifier) {\n map.set(modifier.name, modifier);\n }); // On visiting object, check for its dependencies and visit them recursively\n\n function sort(modifier) {\n visited.add(modifier.name);\n var requires = [].concat(modifier.requires || [], modifier.requiresIfExists || []);\n requires.forEach(function (dep) {\n if (!visited.has(dep)) {\n var depModifier = map.get(dep);\n\n if (depModifier) {\n sort(depModifier);\n }\n }\n });\n result.push(modifier);\n }\n\n modifiers.forEach(function (modifier) {\n if (!visited.has(modifier.name)) {\n // check for visited object\n sort(modifier);\n }\n });\n return result;\n}\n\nexport default function orderModifiers(modifiers) {\n // order based on dependencies\n var orderedModifiers = order(modifiers); // order based on phase\n\n return modifierPhases.reduce(function (acc, phase) {\n return acc.concat(orderedModifiers.filter(function (modifier) {\n return modifier.phase === phase;\n }));\n }, []);\n}","export default function debounce(fn) {\n var pending;\n return function () {\n if (!pending) {\n pending = new Promise(function (resolve) {\n Promise.resolve().then(function () {\n pending = undefined;\n resolve(fn());\n });\n });\n }\n\n return pending;\n };\n}","export default function mergeByName(modifiers) {\n var merged = modifiers.reduce(function (merged, current) {\n var existing = merged[current.name];\n merged[current.name] = existing ? Object.assign({}, existing, current, {\n options: Object.assign({}, existing.options, current.options),\n data: Object.assign({}, existing.data, current.data)\n }) : current;\n return merged;\n }, {}); // IE11 does not support Object.values\n\n return Object.keys(merged).map(function (key) {\n return merged[key];\n });\n}","import getCompositeRect from \"./dom-utils/getCompositeRect.js\";\nimport getLayoutRect from \"./dom-utils/getLayoutRect.js\";\nimport listScrollParents from \"./dom-utils/listScrollParents.js\";\nimport getOffsetParent from \"./dom-utils/getOffsetParent.js\";\nimport orderModifiers from \"./utils/orderModifiers.js\";\nimport debounce from \"./utils/debounce.js\";\nimport mergeByName from \"./utils/mergeByName.js\";\nimport detectOverflow from \"./utils/detectOverflow.js\";\nimport { isElement } from \"./dom-utils/instanceOf.js\";\nvar DEFAULT_OPTIONS = {\n placement: 'bottom',\n modifiers: [],\n strategy: 'absolute'\n};\n\nfunction areValidElements() {\n for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {\n args[_key] = arguments[_key];\n }\n\n return !args.some(function (element) {\n return !(element && typeof element.getBoundingClientRect === 'function');\n });\n}\n\nexport function popperGenerator(generatorOptions) {\n if (generatorOptions === void 0) {\n generatorOptions = {};\n }\n\n var _generatorOptions = generatorOptions,\n _generatorOptions$def = _generatorOptions.defaultModifiers,\n defaultModifiers = _generatorOptions$def === void 0 ? [] : _generatorOptions$def,\n _generatorOptions$def2 = _generatorOptions.defaultOptions,\n defaultOptions = _generatorOptions$def2 === void 0 ? DEFAULT_OPTIONS : _generatorOptions$def2;\n return function createPopper(reference, popper, options) {\n if (options === void 0) {\n options = defaultOptions;\n }\n\n var state = {\n placement: 'bottom',\n orderedModifiers: [],\n options: Object.assign({}, DEFAULT_OPTIONS, defaultOptions),\n modifiersData: {},\n elements: {\n reference: reference,\n popper: popper\n },\n attributes: {},\n styles: {}\n };\n var effectCleanupFns = [];\n var isDestroyed = false;\n var instance = {\n state: state,\n setOptions: function setOptions(setOptionsAction) {\n var options = typeof setOptionsAction === 'function' ? setOptionsAction(state.options) : setOptionsAction;\n cleanupModifierEffects();\n state.options = Object.assign({}, defaultOptions, state.options, options);\n state.scrollParents = {\n reference: isElement(reference) ? listScrollParents(reference) : reference.contextElement ? listScrollParents(reference.contextElement) : [],\n popper: listScrollParents(popper)\n }; // Orders the modifiers based on their dependencies and `phase`\n // properties\n\n var orderedModifiers = orderModifiers(mergeByName([].concat(defaultModifiers, state.options.modifiers))); // Strip out disabled modifiers\n\n state.orderedModifiers = orderedModifiers.filter(function (m) {\n return m.enabled;\n });\n runModifierEffects();\n return instance.update();\n },\n // Sync update – it will always be executed, even if not necessary. This\n // is useful for low frequency updates where sync behavior simplifies the\n // logic.\n // For high frequency updates (e.g. `resize` and `scroll` events), always\n // prefer the async Popper#update method\n forceUpdate: function forceUpdate() {\n if (isDestroyed) {\n return;\n }\n\n var _state$elements = state.elements,\n reference = _state$elements.reference,\n popper = _state$elements.popper; // Don't proceed if `reference` or `popper` are not valid elements\n // anymore\n\n if (!areValidElements(reference, popper)) {\n return;\n } // Store the reference and popper rects to be read by modifiers\n\n\n state.rects = {\n reference: getCompositeRect(reference, getOffsetParent(popper), state.options.strategy === 'fixed'),\n popper: getLayoutRect(popper)\n }; // Modifiers have the ability to reset the current update cycle. The\n // most common use case for this is the `flip` modifier changing the\n // placement, which then needs to re-run all the modifiers, because the\n // logic was previously ran for the previous placement and is therefore\n // stale/incorrect\n\n state.reset = false;\n state.placement = state.options.placement; // On each update cycle, the `modifiersData` property for each modifier\n // is filled with the initial data specified by the modifier. This means\n // it doesn't persist and is fresh on each update.\n // To ensure persistent data, use `${name}#persistent`\n\n state.orderedModifiers.forEach(function (modifier) {\n return state.modifiersData[modifier.name] = Object.assign({}, modifier.data);\n });\n\n for (var index = 0; index < state.orderedModifiers.length; index++) {\n if (state.reset === true) {\n state.reset = false;\n index = -1;\n continue;\n }\n\n var _state$orderedModifie = state.orderedModifiers[index],\n fn = _state$orderedModifie.fn,\n _state$orderedModifie2 = _state$orderedModifie.options,\n _options = _state$orderedModifie2 === void 0 ? {} : _state$orderedModifie2,\n name = _state$orderedModifie.name;\n\n if (typeof fn === 'function') {\n state = fn({\n state: state,\n options: _options,\n name: name,\n instance: instance\n }) || state;\n }\n }\n },\n // Async and optimistically optimized update – it will not be executed if\n // not necessary (debounced to run at most once-per-tick)\n update: debounce(function () {\n return new Promise(function (resolve) {\n instance.forceUpdate();\n resolve(state);\n });\n }),\n destroy: function destroy() {\n cleanupModifierEffects();\n isDestroyed = true;\n }\n };\n\n if (!areValidElements(reference, popper)) {\n return instance;\n }\n\n instance.setOptions(options).then(function (state) {\n if (!isDestroyed && options.onFirstUpdate) {\n options.onFirstUpdate(state);\n }\n }); // Modifiers have the ability to execute arbitrary code before the first\n // update cycle runs. They will be executed in the same order as the update\n // cycle. This is useful when a modifier adds some persistent data that\n // other modifiers need to use, but the modifier is run after the dependent\n // one.\n\n function runModifierEffects() {\n state.orderedModifiers.forEach(function (_ref) {\n var name = _ref.name,\n _ref$options = _ref.options,\n options = _ref$options === void 0 ? {} : _ref$options,\n effect = _ref.effect;\n\n if (typeof effect === 'function') {\n var cleanupFn = effect({\n state: state,\n name: name,\n instance: instance,\n options: options\n });\n\n var noopFn = function noopFn() {};\n\n effectCleanupFns.push(cleanupFn || noopFn);\n }\n });\n }\n\n function cleanupModifierEffects() {\n effectCleanupFns.forEach(function (fn) {\n return fn();\n });\n effectCleanupFns = [];\n }\n\n return instance;\n };\n}\nexport var createPopper = /*#__PURE__*/popperGenerator(); // eslint-disable-next-line import/no-unused-modules\n\nexport { detectOverflow };","import { popperGenerator, detectOverflow } from \"./createPopper.js\";\nimport eventListeners from \"./modifiers/eventListeners.js\";\nimport popperOffsets from \"./modifiers/popperOffsets.js\";\nimport computeStyles from \"./modifiers/computeStyles.js\";\nimport applyStyles from \"./modifiers/applyStyles.js\";\nimport offset from \"./modifiers/offset.js\";\nimport flip from \"./modifiers/flip.js\";\nimport preventOverflow from \"./modifiers/preventOverflow.js\";\nimport arrow from \"./modifiers/arrow.js\";\nimport hide from \"./modifiers/hide.js\";\nvar defaultModifiers = [eventListeners, popperOffsets, computeStyles, applyStyles, offset, flip, preventOverflow, arrow, hide];\nvar createPopper = /*#__PURE__*/popperGenerator({\n defaultModifiers: defaultModifiers\n}); // eslint-disable-next-line import/no-unused-modules\n\nexport { createPopper, popperGenerator, defaultModifiers, detectOverflow }; // eslint-disable-next-line import/no-unused-modules\n\nexport { createPopper as createPopperLite } from \"./popper-lite.js\"; // eslint-disable-next-line import/no-unused-modules\n\nexport * from \"./modifiers/index.js\";","import { generateUtilityClass } from '../generateUtilityClass';\nimport { generateUtilityClasses } from '../generateUtilityClasses';\nconst COMPONENT_NAME = 'Popper';\nexport function getPopperUtilityClass(slot) {\n return generateUtilityClass(COMPONENT_NAME, slot);\n}\nexport const popperClasses = generateUtilityClasses(COMPONENT_NAME, ['root']);","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"anchorEl\", \"children\", \"direction\", \"disablePortal\", \"modifiers\", \"open\", \"placement\", \"popperOptions\", \"popperRef\", \"slotProps\", \"slots\", \"TransitionProps\", \"ownerState\"],\n _excluded2 = [\"anchorEl\", \"children\", \"container\", \"direction\", \"disablePortal\", \"keepMounted\", \"modifiers\", \"open\", \"placement\", \"popperOptions\", \"popperRef\", \"style\", \"transition\", \"slotProps\", \"slots\"];\nimport * as React from 'react';\nimport { chainPropTypes, HTMLElementType, refType, unstable_ownerDocument as ownerDocument, unstable_useEnhancedEffect as useEnhancedEffect, unstable_useForkRef as useForkRef } from '@mui/utils';\nimport { createPopper } from '@popperjs/core';\nimport PropTypes from 'prop-types';\nimport { unstable_composeClasses as composeClasses } from '../composeClasses';\nimport { Portal } from '../Portal';\nimport { getPopperUtilityClass } from './popperClasses';\nimport { useSlotProps } from '../utils';\nimport { useClassNamesOverride } from '../utils/ClassNameConfigurator';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nfunction flipPlacement(placement, direction) {\n if (direction === 'ltr') {\n return placement;\n }\n switch (placement) {\n case 'bottom-end':\n return 'bottom-start';\n case 'bottom-start':\n return 'bottom-end';\n case 'top-end':\n return 'top-start';\n case 'top-start':\n return 'top-end';\n default:\n return placement;\n }\n}\nfunction resolveAnchorEl(anchorEl) {\n return typeof anchorEl === 'function' ? anchorEl() : anchorEl;\n}\nfunction isHTMLElement(element) {\n return element.nodeType !== undefined;\n}\nfunction isVirtualElement(element) {\n return !isHTMLElement(element);\n}\nconst useUtilityClasses = () => {\n const slots = {\n root: ['root']\n };\n return composeClasses(slots, useClassNamesOverride(getPopperUtilityClass));\n};\nconst defaultPopperOptions = {};\nconst PopperTooltip = /*#__PURE__*/React.forwardRef(function PopperTooltip(props, forwardedRef) {\n var _slots$root;\n const {\n anchorEl,\n children,\n direction,\n disablePortal,\n modifiers,\n open,\n placement: initialPlacement,\n popperOptions,\n popperRef: popperRefProp,\n slotProps = {},\n slots = {},\n TransitionProps\n // @ts-ignore internal logic\n // prevent from spreading to DOM, it can come from the parent component e.g. Select.\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const tooltipRef = React.useRef(null);\n const ownRef = useForkRef(tooltipRef, forwardedRef);\n const popperRef = React.useRef(null);\n const handlePopperRef = useForkRef(popperRef, popperRefProp);\n const handlePopperRefRef = React.useRef(handlePopperRef);\n useEnhancedEffect(() => {\n handlePopperRefRef.current = handlePopperRef;\n }, [handlePopperRef]);\n React.useImperativeHandle(popperRefProp, () => popperRef.current, []);\n const rtlPlacement = flipPlacement(initialPlacement, direction);\n /**\n * placement initialized from prop but can change during lifetime if modifiers.flip.\n * modifiers.flip is essentially a flip for controlled/uncontrolled behavior\n */\n const [placement, setPlacement] = React.useState(rtlPlacement);\n const [resolvedAnchorElement, setResolvedAnchorElement] = React.useState(resolveAnchorEl(anchorEl));\n React.useEffect(() => {\n if (popperRef.current) {\n popperRef.current.forceUpdate();\n }\n });\n React.useEffect(() => {\n if (anchorEl) {\n setResolvedAnchorElement(resolveAnchorEl(anchorEl));\n }\n }, [anchorEl]);\n useEnhancedEffect(() => {\n if (!resolvedAnchorElement || !open) {\n return undefined;\n }\n const handlePopperUpdate = data => {\n setPlacement(data.placement);\n };\n if (process.env.NODE_ENV !== 'production') {\n if (resolvedAnchorElement && isHTMLElement(resolvedAnchorElement) && resolvedAnchorElement.nodeType === 1) {\n const box = resolvedAnchorElement.getBoundingClientRect();\n if (process.env.NODE_ENV !== 'test' && box.top === 0 && box.left === 0 && box.right === 0 && box.bottom === 0) {\n console.warn(['MUI: The `anchorEl` prop provided to the component is invalid.', 'The anchor element should be part of the document layout.', \"Make sure the element is present in the document or that it's not display none.\"].join('\\n'));\n }\n }\n }\n let popperModifiers = [{\n name: 'preventOverflow',\n options: {\n altBoundary: disablePortal\n }\n }, {\n name: 'flip',\n options: {\n altBoundary: disablePortal\n }\n }, {\n name: 'onUpdate',\n enabled: true,\n phase: 'afterWrite',\n fn: ({\n state\n }) => {\n handlePopperUpdate(state);\n }\n }];\n if (modifiers != null) {\n popperModifiers = popperModifiers.concat(modifiers);\n }\n if (popperOptions && popperOptions.modifiers != null) {\n popperModifiers = popperModifiers.concat(popperOptions.modifiers);\n }\n const popper = createPopper(resolvedAnchorElement, tooltipRef.current, _extends({\n placement: rtlPlacement\n }, popperOptions, {\n modifiers: popperModifiers\n }));\n handlePopperRefRef.current(popper);\n return () => {\n popper.destroy();\n handlePopperRefRef.current(null);\n };\n }, [resolvedAnchorElement, disablePortal, modifiers, open, popperOptions, rtlPlacement]);\n const childProps = {\n placement: placement\n };\n if (TransitionProps !== null) {\n childProps.TransitionProps = TransitionProps;\n }\n const classes = useUtilityClasses();\n const Root = (_slots$root = slots.root) != null ? _slots$root : 'div';\n const rootProps = useSlotProps({\n elementType: Root,\n externalSlotProps: slotProps.root,\n externalForwardedProps: other,\n additionalProps: {\n role: 'tooltip',\n ref: ownRef\n },\n ownerState: props,\n className: classes.root\n });\n return /*#__PURE__*/_jsx(Root, _extends({}, rootProps, {\n children: typeof children === 'function' ? children(childProps) : children\n }));\n});\n\n/**\n * Poppers rely on the 3rd party library [Popper.js](https://popper.js.org/docs/v2/) for positioning.\n *\n * Demos:\n *\n * - [Popper](https://mui.com/base-ui/react-popper/)\n *\n * API:\n *\n * - [Popper API](https://mui.com/base-ui/react-popper/components-api/#popper)\n */\nconst Popper = /*#__PURE__*/React.forwardRef(function Popper(props, forwardedRef) {\n const {\n anchorEl,\n children,\n container: containerProp,\n direction = 'ltr',\n disablePortal = false,\n keepMounted = false,\n modifiers,\n open,\n placement = 'bottom',\n popperOptions = defaultPopperOptions,\n popperRef,\n style,\n transition = false,\n slotProps = {},\n slots = {}\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded2);\n const [exited, setExited] = React.useState(true);\n const handleEnter = () => {\n setExited(false);\n };\n const handleExited = () => {\n setExited(true);\n };\n if (!keepMounted && !open && (!transition || exited)) {\n return null;\n }\n\n // If the container prop is provided, use that\n // If the anchorEl prop is provided, use its parent body element as the container\n // If neither are provided let the Modal take care of choosing the container\n let container;\n if (containerProp) {\n container = containerProp;\n } else if (anchorEl) {\n const resolvedAnchorEl = resolveAnchorEl(anchorEl);\n container = resolvedAnchorEl && isHTMLElement(resolvedAnchorEl) ? ownerDocument(resolvedAnchorEl).body : ownerDocument(null).body;\n }\n const display = !open && keepMounted && (!transition || exited) ? 'none' : undefined;\n const transitionProps = transition ? {\n in: open,\n onEnter: handleEnter,\n onExited: handleExited\n } : undefined;\n return /*#__PURE__*/_jsx(Portal, {\n disablePortal: disablePortal,\n container: container,\n children: /*#__PURE__*/_jsx(PopperTooltip, _extends({\n anchorEl: anchorEl,\n direction: direction,\n disablePortal: disablePortal,\n modifiers: modifiers,\n ref: forwardedRef,\n open: transition ? !exited : open,\n placement: placement,\n popperOptions: popperOptions,\n popperRef: popperRef,\n slotProps: slotProps,\n slots: slots\n }, other, {\n style: _extends({\n // Prevents scroll issue, waiting for Popper.js to add this style once initiated.\n position: 'fixed',\n // Fix Popper.js display issue\n top: 0,\n left: 0,\n display\n }, style),\n TransitionProps: transitionProps,\n children: children\n }))\n });\n});\nprocess.env.NODE_ENV !== \"production\" ? Popper.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * An HTML element, [virtualElement](https://popper.js.org/docs/v2/virtual-elements/),\n * or a function that returns either.\n * It's used to set the position of the popper.\n * The return value will passed as the reference object of the Popper instance.\n */\n anchorEl: chainPropTypes(PropTypes.oneOfType([HTMLElementType, PropTypes.object, PropTypes.func]), props => {\n if (props.open) {\n const resolvedAnchorEl = resolveAnchorEl(props.anchorEl);\n if (resolvedAnchorEl && isHTMLElement(resolvedAnchorEl) && resolvedAnchorEl.nodeType === 1) {\n const box = resolvedAnchorEl.getBoundingClientRect();\n if (process.env.NODE_ENV !== 'test' && box.top === 0 && box.left === 0 && box.right === 0 && box.bottom === 0) {\n return new Error(['MUI: The `anchorEl` prop provided to the component is invalid.', 'The anchor element should be part of the document layout.', \"Make sure the element is present in the document or that it's not display none.\"].join('\\n'));\n }\n } else if (!resolvedAnchorEl || typeof resolvedAnchorEl.getBoundingClientRect !== 'function' || isVirtualElement(resolvedAnchorEl) && resolvedAnchorEl.contextElement != null && resolvedAnchorEl.contextElement.nodeType !== 1) {\n return new Error(['MUI: The `anchorEl` prop provided to the component is invalid.', 'It should be an HTML element instance or a virtualElement ', '(https://popper.js.org/docs/v2/virtual-elements/).'].join('\\n'));\n }\n }\n return null;\n }),\n /**\n * Popper render function or node.\n */\n children: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.node, PropTypes.func]),\n /**\n * An HTML element or function that returns one.\n * The `container` will have the portal children appended to it.\n *\n * You can also provide a callback, which is called in a React layout effect.\n * This lets you set the container from a ref, and also makes server-side rendering possible.\n *\n * By default, it uses the body of the top-level document object,\n * so it's simply `document.body` most of the time.\n */\n container: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.func]),\n /**\n * Direction of the text.\n * @default 'ltr'\n */\n direction: PropTypes.oneOf(['ltr', 'rtl']),\n /**\n * The `children` will be under the DOM hierarchy of the parent component.\n * @default false\n */\n disablePortal: PropTypes.bool,\n /**\n * Always keep the children in the DOM.\n * This prop can be useful in SEO situation or\n * when you want to maximize the responsiveness of the Popper.\n * @default false\n */\n keepMounted: PropTypes.bool,\n /**\n * Popper.js is based on a \"plugin-like\" architecture,\n * most of its features are fully encapsulated \"modifiers\".\n *\n * A modifier is a function that is called each time Popper.js needs to\n * compute the position of the popper.\n * For this reason, modifiers should be very performant to avoid bottlenecks.\n * To learn how to create a modifier, [read the modifiers documentation](https://popper.js.org/docs/v2/modifiers/).\n */\n modifiers: PropTypes.arrayOf(PropTypes.shape({\n data: PropTypes.object,\n effect: PropTypes.func,\n enabled: PropTypes.bool,\n fn: PropTypes.func,\n name: PropTypes.any,\n options: PropTypes.object,\n phase: PropTypes.oneOf(['afterMain', 'afterRead', 'afterWrite', 'beforeMain', 'beforeRead', 'beforeWrite', 'main', 'read', 'write']),\n requires: PropTypes.arrayOf(PropTypes.string),\n requiresIfExists: PropTypes.arrayOf(PropTypes.string)\n })),\n /**\n * If `true`, the component is shown.\n */\n open: PropTypes.bool.isRequired,\n /**\n * Popper placement.\n * @default 'bottom'\n */\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n /**\n * Options provided to the [`Popper.js`](https://popper.js.org/docs/v2/constructors/#options) instance.\n * @default {}\n */\n popperOptions: PropTypes.shape({\n modifiers: PropTypes.array,\n onFirstUpdate: PropTypes.func,\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n strategy: PropTypes.oneOf(['absolute', 'fixed'])\n }),\n /**\n * A ref that points to the used popper instance.\n */\n popperRef: refType,\n /**\n * The props used for each slot inside the Popper.\n * @default {}\n */\n slotProps: PropTypes.shape({\n root: PropTypes.oneOfType([PropTypes.func, PropTypes.object])\n }),\n /**\n * The components used for each slot inside the Popper.\n * Either a string to use a HTML element or a component.\n * @default {}\n */\n slots: PropTypes.shape({\n root: PropTypes.elementType\n }),\n /**\n * Help supporting a react-transition-group/Transition component.\n * @default false\n */\n transition: PropTypes.bool\n} : void 0;\nexport { Popper };","'use client';\n\nimport * as React from 'react';\nimport { useTheme as useThemeSystem } from '@mui/system';\nimport defaultTheme from './defaultTheme';\nimport THEME_ID from './identifier';\nexport default function useTheme() {\n const theme = useThemeSystem(defaultTheme);\n if (process.env.NODE_ENV !== 'production') {\n // eslint-disable-next-line react-hooks/rules-of-hooks\n React.useDebugValue(theme);\n }\n return theme[THEME_ID] || theme;\n}","export default function _setPrototypeOf(o, p) {\n _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function _setPrototypeOf(o, p) {\n o.__proto__ = p;\n return o;\n };\n return _setPrototypeOf(o, p);\n}","import setPrototypeOf from \"./setPrototypeOf.js\";\nexport default function _inheritsLoose(subClass, superClass) {\n subClass.prototype = Object.create(superClass.prototype);\n subClass.prototype.constructor = subClass;\n setPrototypeOf(subClass, superClass);\n}","export default {\n disabled: false\n};","import PropTypes from 'prop-types';\nexport var timeoutsShape = process.env.NODE_ENV !== 'production' ? PropTypes.oneOfType([PropTypes.number, PropTypes.shape({\n enter: PropTypes.number,\n exit: PropTypes.number,\n appear: PropTypes.number\n}).isRequired]) : null;\nexport var classNamesShape = process.env.NODE_ENV !== 'production' ? PropTypes.oneOfType([PropTypes.string, PropTypes.shape({\n enter: PropTypes.string,\n exit: PropTypes.string,\n active: PropTypes.string\n}), PropTypes.shape({\n enter: PropTypes.string,\n enterDone: PropTypes.string,\n enterActive: PropTypes.string,\n exit: PropTypes.string,\n exitDone: PropTypes.string,\n exitActive: PropTypes.string\n})]) : null;","import React from 'react';\nexport default React.createContext(null);","export var forceReflow = function forceReflow(node) {\n return node.scrollTop;\n};","import _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _inheritsLoose from \"@babel/runtime/helpers/esm/inheritsLoose\";\nimport PropTypes from 'prop-types';\nimport React from 'react';\nimport ReactDOM from 'react-dom';\nimport config from './config';\nimport { timeoutsShape } from './utils/PropTypes';\nimport TransitionGroupContext from './TransitionGroupContext';\nimport { forceReflow } from './utils/reflow';\nexport var UNMOUNTED = 'unmounted';\nexport var EXITED = 'exited';\nexport var ENTERING = 'entering';\nexport var ENTERED = 'entered';\nexport var EXITING = 'exiting';\n/**\n * The Transition component lets you describe a transition from one component\n * state to another _over time_ with a simple declarative API. Most commonly\n * it's used to animate the mounting and unmounting of a component, but can also\n * be used to describe in-place transition states as well.\n *\n * ---\n *\n * **Note**: `Transition` is a platform-agnostic base component. If you're using\n * transitions in CSS, you'll probably want to use\n * [`CSSTransition`](https://reactcommunity.org/react-transition-group/css-transition)\n * instead. It inherits all the features of `Transition`, but contains\n * additional features necessary to play nice with CSS transitions (hence the\n * name of the component).\n *\n * ---\n *\n * By default the `Transition` component does not alter the behavior of the\n * component it renders, it only tracks \"enter\" and \"exit\" states for the\n * components. It's up to you to give meaning and effect to those states. For\n * example we can add styles to a component when it enters or exits:\n *\n * ```jsx\n * import { Transition } from 'react-transition-group';\n *\n * const duration = 300;\n *\n * const defaultStyle = {\n * transition: `opacity ${duration}ms ease-in-out`,\n * opacity: 0,\n * }\n *\n * const transitionStyles = {\n * entering: { opacity: 1 },\n * entered: { opacity: 1 },\n * exiting: { opacity: 0 },\n * exited: { opacity: 0 },\n * };\n *\n * const Fade = ({ in: inProp }) => (\n * \n * {state => (\n *
    \n * I'm a fade Transition!\n *
    \n * )}\n *
    \n * );\n * ```\n *\n * There are 4 main states a Transition can be in:\n * - `'entering'`\n * - `'entered'`\n * - `'exiting'`\n * - `'exited'`\n *\n * Transition state is toggled via the `in` prop. When `true` the component\n * begins the \"Enter\" stage. During this stage, the component will shift from\n * its current transition state, to `'entering'` for the duration of the\n * transition and then to the `'entered'` stage once it's complete. Let's take\n * the following example (we'll use the\n * [useState](https://reactjs.org/docs/hooks-reference.html#usestate) hook):\n *\n * ```jsx\n * function App() {\n * const [inProp, setInProp] = useState(false);\n * return (\n *
    \n * \n * {state => (\n * // ...\n * )}\n * \n * \n *
    \n * );\n * }\n * ```\n *\n * When the button is clicked the component will shift to the `'entering'` state\n * and stay there for 500ms (the value of `timeout`) before it finally switches\n * to `'entered'`.\n *\n * When `in` is `false` the same thing happens except the state moves from\n * `'exiting'` to `'exited'`.\n */\n\nvar Transition = /*#__PURE__*/function (_React$Component) {\n _inheritsLoose(Transition, _React$Component);\n\n function Transition(props, context) {\n var _this;\n\n _this = _React$Component.call(this, props, context) || this;\n var parentGroup = context; // In the context of a TransitionGroup all enters are really appears\n\n var appear = parentGroup && !parentGroup.isMounting ? props.enter : props.appear;\n var initialStatus;\n _this.appearStatus = null;\n\n if (props.in) {\n if (appear) {\n initialStatus = EXITED;\n _this.appearStatus = ENTERING;\n } else {\n initialStatus = ENTERED;\n }\n } else {\n if (props.unmountOnExit || props.mountOnEnter) {\n initialStatus = UNMOUNTED;\n } else {\n initialStatus = EXITED;\n }\n }\n\n _this.state = {\n status: initialStatus\n };\n _this.nextCallback = null;\n return _this;\n }\n\n Transition.getDerivedStateFromProps = function getDerivedStateFromProps(_ref, prevState) {\n var nextIn = _ref.in;\n\n if (nextIn && prevState.status === UNMOUNTED) {\n return {\n status: EXITED\n };\n }\n\n return null;\n } // getSnapshotBeforeUpdate(prevProps) {\n // let nextStatus = null\n // if (prevProps !== this.props) {\n // const { status } = this.state\n // if (this.props.in) {\n // if (status !== ENTERING && status !== ENTERED) {\n // nextStatus = ENTERING\n // }\n // } else {\n // if (status === ENTERING || status === ENTERED) {\n // nextStatus = EXITING\n // }\n // }\n // }\n // return { nextStatus }\n // }\n ;\n\n var _proto = Transition.prototype;\n\n _proto.componentDidMount = function componentDidMount() {\n this.updateStatus(true, this.appearStatus);\n };\n\n _proto.componentDidUpdate = function componentDidUpdate(prevProps) {\n var nextStatus = null;\n\n if (prevProps !== this.props) {\n var status = this.state.status;\n\n if (this.props.in) {\n if (status !== ENTERING && status !== ENTERED) {\n nextStatus = ENTERING;\n }\n } else {\n if (status === ENTERING || status === ENTERED) {\n nextStatus = EXITING;\n }\n }\n }\n\n this.updateStatus(false, nextStatus);\n };\n\n _proto.componentWillUnmount = function componentWillUnmount() {\n this.cancelNextCallback();\n };\n\n _proto.getTimeouts = function getTimeouts() {\n var timeout = this.props.timeout;\n var exit, enter, appear;\n exit = enter = appear = timeout;\n\n if (timeout != null && typeof timeout !== 'number') {\n exit = timeout.exit;\n enter = timeout.enter; // TODO: remove fallback for next major\n\n appear = timeout.appear !== undefined ? timeout.appear : enter;\n }\n\n return {\n exit: exit,\n enter: enter,\n appear: appear\n };\n };\n\n _proto.updateStatus = function updateStatus(mounting, nextStatus) {\n if (mounting === void 0) {\n mounting = false;\n }\n\n if (nextStatus !== null) {\n // nextStatus will always be ENTERING or EXITING.\n this.cancelNextCallback();\n\n if (nextStatus === ENTERING) {\n if (this.props.unmountOnExit || this.props.mountOnEnter) {\n var node = this.props.nodeRef ? this.props.nodeRef.current : ReactDOM.findDOMNode(this); // https://github.com/reactjs/react-transition-group/pull/749\n // With unmountOnExit or mountOnEnter, the enter animation should happen at the transition between `exited` and `entering`.\n // To make the animation happen, we have to separate each rendering and avoid being processed as batched.\n\n if (node) forceReflow(node);\n }\n\n this.performEnter(mounting);\n } else {\n this.performExit();\n }\n } else if (this.props.unmountOnExit && this.state.status === EXITED) {\n this.setState({\n status: UNMOUNTED\n });\n }\n };\n\n _proto.performEnter = function performEnter(mounting) {\n var _this2 = this;\n\n var enter = this.props.enter;\n var appearing = this.context ? this.context.isMounting : mounting;\n\n var _ref2 = this.props.nodeRef ? [appearing] : [ReactDOM.findDOMNode(this), appearing],\n maybeNode = _ref2[0],\n maybeAppearing = _ref2[1];\n\n var timeouts = this.getTimeouts();\n var enterTimeout = appearing ? timeouts.appear : timeouts.enter; // no enter animation skip right to ENTERED\n // if we are mounting and running this it means appear _must_ be set\n\n if (!mounting && !enter || config.disabled) {\n this.safeSetState({\n status: ENTERED\n }, function () {\n _this2.props.onEntered(maybeNode);\n });\n return;\n }\n\n this.props.onEnter(maybeNode, maybeAppearing);\n this.safeSetState({\n status: ENTERING\n }, function () {\n _this2.props.onEntering(maybeNode, maybeAppearing);\n\n _this2.onTransitionEnd(enterTimeout, function () {\n _this2.safeSetState({\n status: ENTERED\n }, function () {\n _this2.props.onEntered(maybeNode, maybeAppearing);\n });\n });\n });\n };\n\n _proto.performExit = function performExit() {\n var _this3 = this;\n\n var exit = this.props.exit;\n var timeouts = this.getTimeouts();\n var maybeNode = this.props.nodeRef ? undefined : ReactDOM.findDOMNode(this); // no exit animation skip right to EXITED\n\n if (!exit || config.disabled) {\n this.safeSetState({\n status: EXITED\n }, function () {\n _this3.props.onExited(maybeNode);\n });\n return;\n }\n\n this.props.onExit(maybeNode);\n this.safeSetState({\n status: EXITING\n }, function () {\n _this3.props.onExiting(maybeNode);\n\n _this3.onTransitionEnd(timeouts.exit, function () {\n _this3.safeSetState({\n status: EXITED\n }, function () {\n _this3.props.onExited(maybeNode);\n });\n });\n });\n };\n\n _proto.cancelNextCallback = function cancelNextCallback() {\n if (this.nextCallback !== null) {\n this.nextCallback.cancel();\n this.nextCallback = null;\n }\n };\n\n _proto.safeSetState = function safeSetState(nextState, callback) {\n // This shouldn't be necessary, but there are weird race conditions with\n // setState callbacks and unmounting in testing, so always make sure that\n // we can cancel any pending setState callbacks after we unmount.\n callback = this.setNextCallback(callback);\n this.setState(nextState, callback);\n };\n\n _proto.setNextCallback = function setNextCallback(callback) {\n var _this4 = this;\n\n var active = true;\n\n this.nextCallback = function (event) {\n if (active) {\n active = false;\n _this4.nextCallback = null;\n callback(event);\n }\n };\n\n this.nextCallback.cancel = function () {\n active = false;\n };\n\n return this.nextCallback;\n };\n\n _proto.onTransitionEnd = function onTransitionEnd(timeout, handler) {\n this.setNextCallback(handler);\n var node = this.props.nodeRef ? this.props.nodeRef.current : ReactDOM.findDOMNode(this);\n var doesNotHaveTimeoutOrListener = timeout == null && !this.props.addEndListener;\n\n if (!node || doesNotHaveTimeoutOrListener) {\n setTimeout(this.nextCallback, 0);\n return;\n }\n\n if (this.props.addEndListener) {\n var _ref3 = this.props.nodeRef ? [this.nextCallback] : [node, this.nextCallback],\n maybeNode = _ref3[0],\n maybeNextCallback = _ref3[1];\n\n this.props.addEndListener(maybeNode, maybeNextCallback);\n }\n\n if (timeout != null) {\n setTimeout(this.nextCallback, timeout);\n }\n };\n\n _proto.render = function render() {\n var status = this.state.status;\n\n if (status === UNMOUNTED) {\n return null;\n }\n\n var _this$props = this.props,\n children = _this$props.children,\n _in = _this$props.in,\n _mountOnEnter = _this$props.mountOnEnter,\n _unmountOnExit = _this$props.unmountOnExit,\n _appear = _this$props.appear,\n _enter = _this$props.enter,\n _exit = _this$props.exit,\n _timeout = _this$props.timeout,\n _addEndListener = _this$props.addEndListener,\n _onEnter = _this$props.onEnter,\n _onEntering = _this$props.onEntering,\n _onEntered = _this$props.onEntered,\n _onExit = _this$props.onExit,\n _onExiting = _this$props.onExiting,\n _onExited = _this$props.onExited,\n _nodeRef = _this$props.nodeRef,\n childProps = _objectWithoutPropertiesLoose(_this$props, [\"children\", \"in\", \"mountOnEnter\", \"unmountOnExit\", \"appear\", \"enter\", \"exit\", \"timeout\", \"addEndListener\", \"onEnter\", \"onEntering\", \"onEntered\", \"onExit\", \"onExiting\", \"onExited\", \"nodeRef\"]);\n\n return (\n /*#__PURE__*/\n // allows for nested Transitions\n React.createElement(TransitionGroupContext.Provider, {\n value: null\n }, typeof children === 'function' ? children(status, childProps) : React.cloneElement(React.Children.only(children), childProps))\n );\n };\n\n return Transition;\n}(React.Component);\n\nTransition.contextType = TransitionGroupContext;\nTransition.propTypes = process.env.NODE_ENV !== \"production\" ? {\n /**\n * A React reference to DOM element that need to transition:\n * https://stackoverflow.com/a/51127130/4671932\n *\n * - When `nodeRef` prop is used, `node` is not passed to callback functions\n * (e.g. `onEnter`) because user already has direct access to the node.\n * - When changing `key` prop of `Transition` in a `TransitionGroup` a new\n * `nodeRef` need to be provided to `Transition` with changed `key` prop\n * (see\n * [test/CSSTransition-test.js](https://github.com/reactjs/react-transition-group/blob/13435f897b3ab71f6e19d724f145596f5910581c/test/CSSTransition-test.js#L362-L437)).\n */\n nodeRef: PropTypes.shape({\n current: typeof Element === 'undefined' ? PropTypes.any : function (propValue, key, componentName, location, propFullName, secret) {\n var value = propValue[key];\n return PropTypes.instanceOf(value && 'ownerDocument' in value ? value.ownerDocument.defaultView.Element : Element)(propValue, key, componentName, location, propFullName, secret);\n }\n }),\n\n /**\n * A `function` child can be used instead of a React element. This function is\n * called with the current transition status (`'entering'`, `'entered'`,\n * `'exiting'`, `'exited'`), which can be used to apply context\n * specific props to a component.\n *\n * ```jsx\n * \n * {state => (\n * \n * )}\n * \n * ```\n */\n children: PropTypes.oneOfType([PropTypes.func.isRequired, PropTypes.element.isRequired]).isRequired,\n\n /**\n * Show the component; triggers the enter or exit states\n */\n in: PropTypes.bool,\n\n /**\n * By default the child component is mounted immediately along with\n * the parent `Transition` component. If you want to \"lazy mount\" the component on the\n * first `in={true}` you can set `mountOnEnter`. After the first enter transition the component will stay\n * mounted, even on \"exited\", unless you also specify `unmountOnExit`.\n */\n mountOnEnter: PropTypes.bool,\n\n /**\n * By default the child component stays mounted after it reaches the `'exited'` state.\n * Set `unmountOnExit` if you'd prefer to unmount the component after it finishes exiting.\n */\n unmountOnExit: PropTypes.bool,\n\n /**\n * By default the child component does not perform the enter transition when\n * it first mounts, regardless of the value of `in`. If you want this\n * behavior, set both `appear` and `in` to `true`.\n *\n * > **Note**: there are no special appear states like `appearing`/`appeared`, this prop\n * > only adds an additional enter transition. However, in the\n * > `` component that first enter transition does result in\n * > additional `.appear-*` classes, that way you can choose to style it\n * > differently.\n */\n appear: PropTypes.bool,\n\n /**\n * Enable or disable enter transitions.\n */\n enter: PropTypes.bool,\n\n /**\n * Enable or disable exit transitions.\n */\n exit: PropTypes.bool,\n\n /**\n * The duration of the transition, in milliseconds.\n * Required unless `addEndListener` is provided.\n *\n * You may specify a single timeout for all transitions:\n *\n * ```jsx\n * timeout={500}\n * ```\n *\n * or individually:\n *\n * ```jsx\n * timeout={{\n * appear: 500,\n * enter: 300,\n * exit: 500,\n * }}\n * ```\n *\n * - `appear` defaults to the value of `enter`\n * - `enter` defaults to `0`\n * - `exit` defaults to `0`\n *\n * @type {number | { enter?: number, exit?: number, appear?: number }}\n */\n timeout: function timeout(props) {\n var pt = timeoutsShape;\n if (!props.addEndListener) pt = pt.isRequired;\n\n for (var _len = arguments.length, args = new Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) {\n args[_key - 1] = arguments[_key];\n }\n\n return pt.apply(void 0, [props].concat(args));\n },\n\n /**\n * Add a custom transition end trigger. Called with the transitioning\n * DOM node and a `done` callback. Allows for more fine grained transition end\n * logic. Timeouts are still used as a fallback if provided.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * ```jsx\n * addEndListener={(node, done) => {\n * // use the css transitionend event to mark the finish of a transition\n * node.addEventListener('transitionend', done, false);\n * }}\n * ```\n */\n addEndListener: PropTypes.func,\n\n /**\n * Callback fired before the \"entering\" status is applied. An extra parameter\n * `isAppearing` is supplied to indicate if the enter stage is occurring on the initial mount\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement, isAppearing: bool) -> void\n */\n onEnter: PropTypes.func,\n\n /**\n * Callback fired after the \"entering\" status is applied. An extra parameter\n * `isAppearing` is supplied to indicate if the enter stage is occurring on the initial mount\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement, isAppearing: bool)\n */\n onEntering: PropTypes.func,\n\n /**\n * Callback fired after the \"entered\" status is applied. An extra parameter\n * `isAppearing` is supplied to indicate if the enter stage is occurring on the initial mount\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement, isAppearing: bool) -> void\n */\n onEntered: PropTypes.func,\n\n /**\n * Callback fired before the \"exiting\" status is applied.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement) -> void\n */\n onExit: PropTypes.func,\n\n /**\n * Callback fired after the \"exiting\" status is applied.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement) -> void\n */\n onExiting: PropTypes.func,\n\n /**\n * Callback fired after the \"exited\" status is applied.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed\n *\n * @type Function(node: HtmlElement) -> void\n */\n onExited: PropTypes.func\n} : {}; // Name the function so it is clearer in the documentation\n\nfunction noop() {}\n\nTransition.defaultProps = {\n in: false,\n mountOnEnter: false,\n unmountOnExit: false,\n appear: false,\n enter: true,\n exit: true,\n onEnter: noop,\n onEntering: noop,\n onEntered: noop,\n onExit: noop,\n onExiting: noop,\n onExited: noop\n};\nTransition.UNMOUNTED = UNMOUNTED;\nTransition.EXITED = EXITED;\nTransition.ENTERING = ENTERING;\nTransition.ENTERED = ENTERED;\nTransition.EXITING = EXITING;\nexport default Transition;","export const reflow = node => node.scrollTop;\nexport function getTransitionProps(props, options) {\n var _style$transitionDura, _style$transitionTimi;\n const {\n timeout,\n easing,\n style = {}\n } = props;\n return {\n duration: (_style$transitionDura = style.transitionDuration) != null ? _style$transitionDura : typeof timeout === 'number' ? timeout : timeout[options.mode] || 0,\n easing: (_style$transitionTimi = style.transitionTimingFunction) != null ? _style$transitionTimi : typeof easing === 'object' ? easing[options.mode] : easing,\n delay: style.transitionDelay\n };\n}","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"addEndListener\", \"appear\", \"children\", \"easing\", \"in\", \"onEnter\", \"onEntered\", \"onEntering\", \"onExit\", \"onExited\", \"onExiting\", \"style\", \"timeout\", \"TransitionComponent\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport { elementAcceptingRef, unstable_useTimeout as useTimeout } from '@mui/utils';\nimport { Transition } from 'react-transition-group';\nimport useTheme from '../styles/useTheme';\nimport { getTransitionProps, reflow } from '../transitions/utils';\nimport useForkRef from '../utils/useForkRef';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nfunction getScale(value) {\n return `scale(${value}, ${value ** 2})`;\n}\nconst styles = {\n entering: {\n opacity: 1,\n transform: getScale(1)\n },\n entered: {\n opacity: 1,\n transform: 'none'\n }\n};\n\n/*\n TODO v6: remove\n Conditionally apply a workaround for the CSS transition bug in Safari 15.4 / WebKit browsers.\n */\nconst isWebKit154 = typeof navigator !== 'undefined' && /^((?!chrome|android).)*(safari|mobile)/i.test(navigator.userAgent) && /(os |version\\/)15(.|_)4/i.test(navigator.userAgent);\n\n/**\n * The Grow transition is used by the [Tooltip](/material-ui/react-tooltip/) and\n * [Popover](/material-ui/react-popover/) components.\n * It uses [react-transition-group](https://github.com/reactjs/react-transition-group) internally.\n */\nconst Grow = /*#__PURE__*/React.forwardRef(function Grow(props, ref) {\n const {\n addEndListener,\n appear = true,\n children,\n easing,\n in: inProp,\n onEnter,\n onEntered,\n onEntering,\n onExit,\n onExited,\n onExiting,\n style,\n timeout = 'auto',\n // eslint-disable-next-line react/prop-types\n TransitionComponent = Transition\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const timer = useTimeout();\n const autoTimeout = React.useRef();\n const theme = useTheme();\n const nodeRef = React.useRef(null);\n const handleRef = useForkRef(nodeRef, children.ref, ref);\n const normalizedTransitionCallback = callback => maybeIsAppearing => {\n if (callback) {\n const node = nodeRef.current;\n\n // onEnterXxx and onExitXxx callbacks have a different arguments.length value.\n if (maybeIsAppearing === undefined) {\n callback(node);\n } else {\n callback(node, maybeIsAppearing);\n }\n }\n };\n const handleEntering = normalizedTransitionCallback(onEntering);\n const handleEnter = normalizedTransitionCallback((node, isAppearing) => {\n reflow(node); // So the animation always start from the start.\n\n const {\n duration: transitionDuration,\n delay,\n easing: transitionTimingFunction\n } = getTransitionProps({\n style,\n timeout,\n easing\n }, {\n mode: 'enter'\n });\n let duration;\n if (timeout === 'auto') {\n duration = theme.transitions.getAutoHeightDuration(node.clientHeight);\n autoTimeout.current = duration;\n } else {\n duration = transitionDuration;\n }\n node.style.transition = [theme.transitions.create('opacity', {\n duration,\n delay\n }), theme.transitions.create('transform', {\n duration: isWebKit154 ? duration : duration * 0.666,\n delay,\n easing: transitionTimingFunction\n })].join(',');\n if (onEnter) {\n onEnter(node, isAppearing);\n }\n });\n const handleEntered = normalizedTransitionCallback(onEntered);\n const handleExiting = normalizedTransitionCallback(onExiting);\n const handleExit = normalizedTransitionCallback(node => {\n const {\n duration: transitionDuration,\n delay,\n easing: transitionTimingFunction\n } = getTransitionProps({\n style,\n timeout,\n easing\n }, {\n mode: 'exit'\n });\n let duration;\n if (timeout === 'auto') {\n duration = theme.transitions.getAutoHeightDuration(node.clientHeight);\n autoTimeout.current = duration;\n } else {\n duration = transitionDuration;\n }\n node.style.transition = [theme.transitions.create('opacity', {\n duration,\n delay\n }), theme.transitions.create('transform', {\n duration: isWebKit154 ? duration : duration * 0.666,\n delay: isWebKit154 ? delay : delay || duration * 0.333,\n easing: transitionTimingFunction\n })].join(',');\n node.style.opacity = 0;\n node.style.transform = getScale(0.75);\n if (onExit) {\n onExit(node);\n }\n });\n const handleExited = normalizedTransitionCallback(onExited);\n const handleAddEndListener = next => {\n if (timeout === 'auto') {\n timer.start(autoTimeout.current || 0, next);\n }\n if (addEndListener) {\n // Old call signature before `react-transition-group` implemented `nodeRef`\n addEndListener(nodeRef.current, next);\n }\n };\n return /*#__PURE__*/_jsx(TransitionComponent, _extends({\n appear: appear,\n in: inProp,\n nodeRef: nodeRef,\n onEnter: handleEnter,\n onEntered: handleEntered,\n onEntering: handleEntering,\n onExit: handleExit,\n onExited: handleExited,\n onExiting: handleExiting,\n addEndListener: handleAddEndListener,\n timeout: timeout === 'auto' ? null : timeout\n }, other, {\n children: (state, childProps) => {\n return /*#__PURE__*/React.cloneElement(children, _extends({\n style: _extends({\n opacity: 0,\n transform: getScale(0.75),\n visibility: state === 'exited' && !inProp ? 'hidden' : undefined\n }, styles[state], style, children.props.style),\n ref: handleRef\n }, childProps));\n }\n }));\n});\nprocess.env.NODE_ENV !== \"production\" ? Grow.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the d.ts file and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * Add a custom transition end trigger. Called with the transitioning DOM\n * node and a done callback. Allows for more fine grained transition end\n * logic. Note: Timeouts are still used as a fallback if provided.\n */\n addEndListener: PropTypes.func,\n /**\n * Perform the enter transition when it first mounts if `in` is also `true`.\n * Set this to `false` to disable this behavior.\n * @default true\n */\n appear: PropTypes.bool,\n /**\n * A single child content element.\n */\n children: elementAcceptingRef.isRequired,\n /**\n * The transition timing function.\n * You may specify a single easing or a object containing enter and exit values.\n */\n easing: PropTypes.oneOfType([PropTypes.shape({\n enter: PropTypes.string,\n exit: PropTypes.string\n }), PropTypes.string]),\n /**\n * If `true`, the component will transition in.\n */\n in: PropTypes.bool,\n /**\n * @ignore\n */\n onEnter: PropTypes.func,\n /**\n * @ignore\n */\n onEntered: PropTypes.func,\n /**\n * @ignore\n */\n onEntering: PropTypes.func,\n /**\n * @ignore\n */\n onExit: PropTypes.func,\n /**\n * @ignore\n */\n onExited: PropTypes.func,\n /**\n * @ignore\n */\n onExiting: PropTypes.func,\n /**\n * @ignore\n */\n style: PropTypes.object,\n /**\n * The duration for the transition, in milliseconds.\n * You may specify a single timeout for all transitions, or individually with an object.\n *\n * Set to 'auto' to automatically calculate transition time based on height.\n * @default 'auto'\n */\n timeout: PropTypes.oneOfType([PropTypes.oneOf(['auto']), PropTypes.number, PropTypes.shape({\n appear: PropTypes.number,\n enter: PropTypes.number,\n exit: PropTypes.number\n })])\n} : void 0;\nGrow.muiSupportAuto = true;\nexport default Grow;","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"anchorEl\", \"component\", \"components\", \"componentsProps\", \"container\", \"disablePortal\", \"keepMounted\", \"modifiers\", \"open\", \"placement\", \"popperOptions\", \"popperRef\", \"transition\", \"slots\", \"slotProps\"];\nimport { Popper as BasePopper } from '@mui/base/Popper';\nimport { useThemeWithoutDefault as useTheme } from '@mui/system';\nimport { HTMLElementType, refType } from '@mui/utils';\nimport PropTypes from 'prop-types';\nimport * as React from 'react';\nimport { styled, useThemeProps } from '../styles';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nconst PopperRoot = styled(BasePopper, {\n name: 'MuiPopper',\n slot: 'Root',\n overridesResolver: (props, styles) => styles.root\n})({});\n\n/**\n *\n * Demos:\n *\n * - [Autocomplete](https://mui.com/material-ui/react-autocomplete/)\n * - [Menu](https://mui.com/material-ui/react-menu/)\n * - [Popper](https://mui.com/material-ui/react-popper/)\n *\n * API:\n *\n * - [Popper API](https://mui.com/material-ui/api/popper/)\n */\nconst Popper = /*#__PURE__*/React.forwardRef(function Popper(inProps, ref) {\n var _slots$root;\n const theme = useTheme();\n const props = useThemeProps({\n props: inProps,\n name: 'MuiPopper'\n });\n const {\n anchorEl,\n component,\n components,\n componentsProps,\n container,\n disablePortal,\n keepMounted,\n modifiers,\n open,\n placement,\n popperOptions,\n popperRef,\n transition,\n slots,\n slotProps\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const RootComponent = (_slots$root = slots == null ? void 0 : slots.root) != null ? _slots$root : components == null ? void 0 : components.Root;\n const otherProps = _extends({\n anchorEl,\n container,\n disablePortal,\n keepMounted,\n modifiers,\n open,\n placement,\n popperOptions,\n popperRef,\n transition\n }, other);\n return /*#__PURE__*/_jsx(PopperRoot, _extends({\n as: component,\n direction: theme == null ? void 0 : theme.direction,\n slots: {\n root: RootComponent\n },\n slotProps: slotProps != null ? slotProps : componentsProps\n }, otherProps, {\n ref: ref\n }));\n});\nprocess.env.NODE_ENV !== \"production\" ? Popper.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * An HTML element, [virtualElement](https://popper.js.org/docs/v2/virtual-elements/),\n * or a function that returns either.\n * It's used to set the position of the popper.\n * The return value will passed as the reference object of the Popper instance.\n */\n anchorEl: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.object, PropTypes.func]),\n /**\n * Popper render function or node.\n */\n children: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.node, PropTypes.func]),\n /**\n * The component used for the root node.\n * Either a string to use a HTML element or a component.\n */\n component: PropTypes.elementType,\n /**\n * The components used for each slot inside the Popper.\n * Either a string to use a HTML element or a component.\n * @default {}\n */\n components: PropTypes.shape({\n Root: PropTypes.elementType\n }),\n /**\n * The props used for each slot inside the Popper.\n * @default {}\n */\n componentsProps: PropTypes.shape({\n root: PropTypes.oneOfType([PropTypes.func, PropTypes.object])\n }),\n /**\n * An HTML element or function that returns one.\n * The `container` will have the portal children appended to it.\n *\n * You can also provide a callback, which is called in a React layout effect.\n * This lets you set the container from a ref, and also makes server-side rendering possible.\n *\n * By default, it uses the body of the top-level document object,\n * so it's simply `document.body` most of the time.\n */\n container: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.func]),\n /**\n * The `children` will be under the DOM hierarchy of the parent component.\n * @default false\n */\n disablePortal: PropTypes.bool,\n /**\n * Always keep the children in the DOM.\n * This prop can be useful in SEO situation or\n * when you want to maximize the responsiveness of the Popper.\n * @default false\n */\n keepMounted: PropTypes.bool,\n /**\n * Popper.js is based on a \"plugin-like\" architecture,\n * most of its features are fully encapsulated \"modifiers\".\n *\n * A modifier is a function that is called each time Popper.js needs to\n * compute the position of the popper.\n * For this reason, modifiers should be very performant to avoid bottlenecks.\n * To learn how to create a modifier, [read the modifiers documentation](https://popper.js.org/docs/v2/modifiers/).\n */\n modifiers: PropTypes.arrayOf(PropTypes.shape({\n data: PropTypes.object,\n effect: PropTypes.func,\n enabled: PropTypes.bool,\n fn: PropTypes.func,\n name: PropTypes.any,\n options: PropTypes.object,\n phase: PropTypes.oneOf(['afterMain', 'afterRead', 'afterWrite', 'beforeMain', 'beforeRead', 'beforeWrite', 'main', 'read', 'write']),\n requires: PropTypes.arrayOf(PropTypes.string),\n requiresIfExists: PropTypes.arrayOf(PropTypes.string)\n })),\n /**\n * If `true`, the component is shown.\n */\n open: PropTypes.bool.isRequired,\n /**\n * Popper placement.\n * @default 'bottom'\n */\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n /**\n * Options provided to the [`Popper.js`](https://popper.js.org/docs/v2/constructors/#options) instance.\n * @default {}\n */\n popperOptions: PropTypes.shape({\n modifiers: PropTypes.array,\n onFirstUpdate: PropTypes.func,\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n strategy: PropTypes.oneOf(['absolute', 'fixed'])\n }),\n /**\n * A ref that points to the used popper instance.\n */\n popperRef: refType,\n /**\n * The props used for each slot inside the Popper.\n * @default {}\n */\n slotProps: PropTypes.shape({\n root: PropTypes.oneOfType([PropTypes.func, PropTypes.object])\n }),\n /**\n * The components used for each slot inside the Popper.\n * Either a string to use a HTML element or a component.\n * @default {}\n */\n slots: PropTypes.shape({\n root: PropTypes.elementType\n }),\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Help supporting a react-transition-group/Transition component.\n * @default false\n */\n transition: PropTypes.bool\n} : void 0;\nexport default Popper;","import generateUtilityClasses from '@mui/utils/generateUtilityClasses';\nimport generateUtilityClass from '@mui/utils/generateUtilityClass';\nexport function getTooltipUtilityClass(slot) {\n return generateUtilityClass('MuiTooltip', slot);\n}\nconst tooltipClasses = generateUtilityClasses('MuiTooltip', ['popper', 'popperInteractive', 'popperArrow', 'popperClose', 'tooltip', 'tooltipArrow', 'touch', 'tooltipPlacementLeft', 'tooltipPlacementRight', 'tooltipPlacementTop', 'tooltipPlacementBottom', 'arrow']);\nexport default tooltipClasses;","'use client';\n\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nconst _excluded = [\"arrow\", \"children\", \"classes\", \"components\", \"componentsProps\", \"describeChild\", \"disableFocusListener\", \"disableHoverListener\", \"disableInteractive\", \"disableTouchListener\", \"enterDelay\", \"enterNextDelay\", \"enterTouchDelay\", \"followCursor\", \"id\", \"leaveDelay\", \"leaveTouchDelay\", \"onClose\", \"onOpen\", \"open\", \"placement\", \"PopperComponent\", \"PopperProps\", \"slotProps\", \"slots\", \"title\", \"TransitionComponent\", \"TransitionProps\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport clsx from 'clsx';\nimport { elementAcceptingRef, unstable_useTimeout as useTimeout, unstable_Timeout as Timeout } from '@mui/utils';\nimport { unstable_composeClasses as composeClasses, appendOwnerState } from '@mui/base';\nimport { alpha } from '@mui/system';\nimport styled from '../styles/styled';\nimport useTheme from '../styles/useTheme';\nimport useThemeProps from '../styles/useThemeProps';\nimport capitalize from '../utils/capitalize';\nimport Grow from '../Grow';\nimport Popper from '../Popper';\nimport useEventCallback from '../utils/useEventCallback';\nimport useForkRef from '../utils/useForkRef';\nimport useId from '../utils/useId';\nimport useIsFocusVisible from '../utils/useIsFocusVisible';\nimport useControlled from '../utils/useControlled';\nimport tooltipClasses, { getTooltipUtilityClass } from './tooltipClasses';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nimport { jsxs as _jsxs } from \"react/jsx-runtime\";\nfunction round(value) {\n return Math.round(value * 1e5) / 1e5;\n}\nconst useUtilityClasses = ownerState => {\n const {\n classes,\n disableInteractive,\n arrow,\n touch,\n placement\n } = ownerState;\n const slots = {\n popper: ['popper', !disableInteractive && 'popperInteractive', arrow && 'popperArrow'],\n tooltip: ['tooltip', arrow && 'tooltipArrow', touch && 'touch', `tooltipPlacement${capitalize(placement.split('-')[0])}`],\n arrow: ['arrow']\n };\n return composeClasses(slots, getTooltipUtilityClass, classes);\n};\nconst TooltipPopper = styled(Popper, {\n name: 'MuiTooltip',\n slot: 'Popper',\n overridesResolver: (props, styles) => {\n const {\n ownerState\n } = props;\n return [styles.popper, !ownerState.disableInteractive && styles.popperInteractive, ownerState.arrow && styles.popperArrow, !ownerState.open && styles.popperClose];\n }\n})(({\n theme,\n ownerState,\n open\n}) => _extends({\n zIndex: (theme.vars || theme).zIndex.tooltip,\n pointerEvents: 'none'\n}, !ownerState.disableInteractive && {\n pointerEvents: 'auto'\n}, !open && {\n pointerEvents: 'none'\n}, ownerState.arrow && {\n [`&[data-popper-placement*=\"bottom\"] .${tooltipClasses.arrow}`]: {\n top: 0,\n marginTop: '-0.71em',\n '&::before': {\n transformOrigin: '0 100%'\n }\n },\n [`&[data-popper-placement*=\"top\"] .${tooltipClasses.arrow}`]: {\n bottom: 0,\n marginBottom: '-0.71em',\n '&::before': {\n transformOrigin: '100% 0'\n }\n },\n [`&[data-popper-placement*=\"right\"] .${tooltipClasses.arrow}`]: _extends({}, !ownerState.isRtl ? {\n left: 0,\n marginLeft: '-0.71em'\n } : {\n right: 0,\n marginRight: '-0.71em'\n }, {\n height: '1em',\n width: '0.71em',\n '&::before': {\n transformOrigin: '100% 100%'\n }\n }),\n [`&[data-popper-placement*=\"left\"] .${tooltipClasses.arrow}`]: _extends({}, !ownerState.isRtl ? {\n right: 0,\n marginRight: '-0.71em'\n } : {\n left: 0,\n marginLeft: '-0.71em'\n }, {\n height: '1em',\n width: '0.71em',\n '&::before': {\n transformOrigin: '0 0'\n }\n })\n}));\nconst TooltipTooltip = styled('div', {\n name: 'MuiTooltip',\n slot: 'Tooltip',\n overridesResolver: (props, styles) => {\n const {\n ownerState\n } = props;\n return [styles.tooltip, ownerState.touch && styles.touch, ownerState.arrow && styles.tooltipArrow, styles[`tooltipPlacement${capitalize(ownerState.placement.split('-')[0])}`]];\n }\n})(({\n theme,\n ownerState\n}) => _extends({\n backgroundColor: theme.vars ? theme.vars.palette.Tooltip.bg : alpha(theme.palette.grey[700], 0.92),\n borderRadius: (theme.vars || theme).shape.borderRadius,\n color: (theme.vars || theme).palette.common.white,\n fontFamily: theme.typography.fontFamily,\n padding: '4px 8px',\n fontSize: theme.typography.pxToRem(11),\n maxWidth: 300,\n margin: 2,\n wordWrap: 'break-word',\n fontWeight: theme.typography.fontWeightMedium\n}, ownerState.arrow && {\n position: 'relative',\n margin: 0\n}, ownerState.touch && {\n padding: '8px 16px',\n fontSize: theme.typography.pxToRem(14),\n lineHeight: `${round(16 / 14)}em`,\n fontWeight: theme.typography.fontWeightRegular\n}, {\n [`.${tooltipClasses.popper}[data-popper-placement*=\"left\"] &`]: _extends({\n transformOrigin: 'right center'\n }, !ownerState.isRtl ? _extends({\n marginRight: '14px'\n }, ownerState.touch && {\n marginRight: '24px'\n }) : _extends({\n marginLeft: '14px'\n }, ownerState.touch && {\n marginLeft: '24px'\n })),\n [`.${tooltipClasses.popper}[data-popper-placement*=\"right\"] &`]: _extends({\n transformOrigin: 'left center'\n }, !ownerState.isRtl ? _extends({\n marginLeft: '14px'\n }, ownerState.touch && {\n marginLeft: '24px'\n }) : _extends({\n marginRight: '14px'\n }, ownerState.touch && {\n marginRight: '24px'\n })),\n [`.${tooltipClasses.popper}[data-popper-placement*=\"top\"] &`]: _extends({\n transformOrigin: 'center bottom',\n marginBottom: '14px'\n }, ownerState.touch && {\n marginBottom: '24px'\n }),\n [`.${tooltipClasses.popper}[data-popper-placement*=\"bottom\"] &`]: _extends({\n transformOrigin: 'center top',\n marginTop: '14px'\n }, ownerState.touch && {\n marginTop: '24px'\n })\n}));\nconst TooltipArrow = styled('span', {\n name: 'MuiTooltip',\n slot: 'Arrow',\n overridesResolver: (props, styles) => styles.arrow\n})(({\n theme\n}) => ({\n overflow: 'hidden',\n position: 'absolute',\n width: '1em',\n height: '0.71em' /* = width / sqrt(2) = (length of the hypotenuse) */,\n boxSizing: 'border-box',\n color: theme.vars ? theme.vars.palette.Tooltip.bg : alpha(theme.palette.grey[700], 0.9),\n '&::before': {\n content: '\"\"',\n margin: 'auto',\n display: 'block',\n width: '100%',\n height: '100%',\n backgroundColor: 'currentColor',\n transform: 'rotate(45deg)'\n }\n}));\nlet hystersisOpen = false;\nconst hystersisTimer = new Timeout();\nlet cursorPosition = {\n x: 0,\n y: 0\n};\nexport function testReset() {\n hystersisOpen = false;\n hystersisTimer.clear();\n}\nfunction composeEventHandler(handler, eventHandler) {\n return event => {\n if (eventHandler) {\n eventHandler(event);\n }\n handler(event);\n };\n}\n\n// TODO v6: Remove PopperComponent, PopperProps, TransitionComponent and TransitionProps.\nconst Tooltip = /*#__PURE__*/React.forwardRef(function Tooltip(inProps, ref) {\n var _ref, _slots$popper, _ref2, _ref3, _slots$transition, _ref4, _slots$tooltip, _ref5, _slots$arrow, _slotProps$popper, _ref6, _slotProps$popper2, _slotProps$transition, _slotProps$tooltip, _ref7, _slotProps$tooltip2, _slotProps$arrow, _ref8, _slotProps$arrow2;\n const props = useThemeProps({\n props: inProps,\n name: 'MuiTooltip'\n });\n const {\n arrow = false,\n children: childrenProp,\n components = {},\n componentsProps = {},\n describeChild = false,\n disableFocusListener = false,\n disableHoverListener = false,\n disableInteractive: disableInteractiveProp = false,\n disableTouchListener = false,\n enterDelay = 100,\n enterNextDelay = 0,\n enterTouchDelay = 700,\n followCursor = false,\n id: idProp,\n leaveDelay = 0,\n leaveTouchDelay = 1500,\n onClose,\n onOpen,\n open: openProp,\n placement = 'bottom',\n PopperComponent: PopperComponentProp,\n PopperProps = {},\n slotProps = {},\n slots = {},\n title,\n TransitionComponent: TransitionComponentProp = Grow,\n TransitionProps\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n\n // to prevent runtime errors, developers will need to provide a child as a React element anyway.\n const children = /*#__PURE__*/React.isValidElement(childrenProp) ? childrenProp : /*#__PURE__*/_jsx(\"span\", {\n children: childrenProp\n });\n const theme = useTheme();\n const isRtl = theme.direction === 'rtl';\n const [childNode, setChildNode] = React.useState();\n const [arrowRef, setArrowRef] = React.useState(null);\n const ignoreNonTouchEvents = React.useRef(false);\n const disableInteractive = disableInteractiveProp || followCursor;\n const closeTimer = useTimeout();\n const enterTimer = useTimeout();\n const leaveTimer = useTimeout();\n const touchTimer = useTimeout();\n const [openState, setOpenState] = useControlled({\n controlled: openProp,\n default: false,\n name: 'Tooltip',\n state: 'open'\n });\n let open = openState;\n if (process.env.NODE_ENV !== 'production') {\n // eslint-disable-next-line react-hooks/rules-of-hooks\n const {\n current: isControlled\n } = React.useRef(openProp !== undefined);\n\n // eslint-disable-next-line react-hooks/rules-of-hooks\n React.useEffect(() => {\n if (childNode && childNode.disabled && !isControlled && title !== '' && childNode.tagName.toLowerCase() === 'button') {\n console.error(['MUI: You are providing a disabled `button` child to the Tooltip component.', 'A disabled element does not fire events.', \"Tooltip needs to listen to the child element's events to display the title.\", '', 'Add a simple wrapper element, such as a `span`.'].join('\\n'));\n }\n }, [title, childNode, isControlled]);\n }\n const id = useId(idProp);\n const prevUserSelect = React.useRef();\n const stopTouchInteraction = useEventCallback(() => {\n if (prevUserSelect.current !== undefined) {\n document.body.style.WebkitUserSelect = prevUserSelect.current;\n prevUserSelect.current = undefined;\n }\n touchTimer.clear();\n });\n React.useEffect(() => stopTouchInteraction, [stopTouchInteraction]);\n const handleOpen = event => {\n hystersisTimer.clear();\n hystersisOpen = true;\n\n // The mouseover event will trigger for every nested element in the tooltip.\n // We can skip rerendering when the tooltip is already open.\n // We are using the mouseover event instead of the mouseenter event to fix a hide/show issue.\n setOpenState(true);\n if (onOpen && !open) {\n onOpen(event);\n }\n };\n const handleClose = useEventCallback(\n /**\n * @param {React.SyntheticEvent | Event} event\n */\n event => {\n hystersisTimer.start(800 + leaveDelay, () => {\n hystersisOpen = false;\n });\n setOpenState(false);\n if (onClose && open) {\n onClose(event);\n }\n closeTimer.start(theme.transitions.duration.shortest, () => {\n ignoreNonTouchEvents.current = false;\n });\n });\n const handleEnter = event => {\n if (ignoreNonTouchEvents.current && event.type !== 'touchstart') {\n return;\n }\n\n // Remove the title ahead of time.\n // We don't want to wait for the next render commit.\n // We would risk displaying two tooltips at the same time (native + this one).\n if (childNode) {\n childNode.removeAttribute('title');\n }\n enterTimer.clear();\n leaveTimer.clear();\n if (enterDelay || hystersisOpen && enterNextDelay) {\n enterTimer.start(hystersisOpen ? enterNextDelay : enterDelay, () => {\n handleOpen(event);\n });\n } else {\n handleOpen(event);\n }\n };\n const handleLeave = event => {\n enterTimer.clear();\n leaveTimer.start(leaveDelay, () => {\n handleClose(event);\n });\n };\n const {\n isFocusVisibleRef,\n onBlur: handleBlurVisible,\n onFocus: handleFocusVisible,\n ref: focusVisibleRef\n } = useIsFocusVisible();\n // We don't necessarily care about the focusVisible state (which is safe to access via ref anyway).\n // We just need to re-render the Tooltip if the focus-visible state changes.\n const [, setChildIsFocusVisible] = React.useState(false);\n const handleBlur = event => {\n handleBlurVisible(event);\n if (isFocusVisibleRef.current === false) {\n setChildIsFocusVisible(false);\n handleLeave(event);\n }\n };\n const handleFocus = event => {\n // Workaround for https://github.com/facebook/react/issues/7769\n // The autoFocus of React might trigger the event before the componentDidMount.\n // We need to account for this eventuality.\n if (!childNode) {\n setChildNode(event.currentTarget);\n }\n handleFocusVisible(event);\n if (isFocusVisibleRef.current === true) {\n setChildIsFocusVisible(true);\n handleEnter(event);\n }\n };\n const detectTouchStart = event => {\n ignoreNonTouchEvents.current = true;\n const childrenProps = children.props;\n if (childrenProps.onTouchStart) {\n childrenProps.onTouchStart(event);\n }\n };\n const handleMouseOver = handleEnter;\n const handleMouseLeave = handleLeave;\n const handleTouchStart = event => {\n detectTouchStart(event);\n leaveTimer.clear();\n closeTimer.clear();\n stopTouchInteraction();\n prevUserSelect.current = document.body.style.WebkitUserSelect;\n // Prevent iOS text selection on long-tap.\n document.body.style.WebkitUserSelect = 'none';\n touchTimer.start(enterTouchDelay, () => {\n document.body.style.WebkitUserSelect = prevUserSelect.current;\n handleEnter(event);\n });\n };\n const handleTouchEnd = event => {\n if (children.props.onTouchEnd) {\n children.props.onTouchEnd(event);\n }\n stopTouchInteraction();\n leaveTimer.start(leaveTouchDelay, () => {\n handleClose(event);\n });\n };\n React.useEffect(() => {\n if (!open) {\n return undefined;\n }\n\n /**\n * @param {KeyboardEvent} nativeEvent\n */\n function handleKeyDown(nativeEvent) {\n // IE11, Edge (prior to using Bink?) use 'Esc'\n if (nativeEvent.key === 'Escape' || nativeEvent.key === 'Esc') {\n handleClose(nativeEvent);\n }\n }\n document.addEventListener('keydown', handleKeyDown);\n return () => {\n document.removeEventListener('keydown', handleKeyDown);\n };\n }, [handleClose, open]);\n const handleRef = useForkRef(children.ref, focusVisibleRef, setChildNode, ref);\n\n // There is no point in displaying an empty tooltip.\n // So we exclude all falsy values, except 0, which is valid.\n if (!title && title !== 0) {\n open = false;\n }\n const popperRef = React.useRef();\n const handleMouseMove = event => {\n const childrenProps = children.props;\n if (childrenProps.onMouseMove) {\n childrenProps.onMouseMove(event);\n }\n cursorPosition = {\n x: event.clientX,\n y: event.clientY\n };\n if (popperRef.current) {\n popperRef.current.update();\n }\n };\n const nameOrDescProps = {};\n const titleIsString = typeof title === 'string';\n if (describeChild) {\n nameOrDescProps.title = !open && titleIsString && !disableHoverListener ? title : null;\n nameOrDescProps['aria-describedby'] = open ? id : null;\n } else {\n nameOrDescProps['aria-label'] = titleIsString ? title : null;\n nameOrDescProps['aria-labelledby'] = open && !titleIsString ? id : null;\n }\n const childrenProps = _extends({}, nameOrDescProps, other, children.props, {\n className: clsx(other.className, children.props.className),\n onTouchStart: detectTouchStart,\n ref: handleRef\n }, followCursor ? {\n onMouseMove: handleMouseMove\n } : {});\n if (process.env.NODE_ENV !== 'production') {\n childrenProps['data-mui-internal-clone-element'] = true;\n\n // eslint-disable-next-line react-hooks/rules-of-hooks\n React.useEffect(() => {\n if (childNode && !childNode.getAttribute('data-mui-internal-clone-element')) {\n console.error(['MUI: The `children` component of the Tooltip is not forwarding its props correctly.', 'Please make sure that props are spread on the same element that the ref is applied to.'].join('\\n'));\n }\n }, [childNode]);\n }\n const interactiveWrapperListeners = {};\n if (!disableTouchListener) {\n childrenProps.onTouchStart = handleTouchStart;\n childrenProps.onTouchEnd = handleTouchEnd;\n }\n if (!disableHoverListener) {\n childrenProps.onMouseOver = composeEventHandler(handleMouseOver, childrenProps.onMouseOver);\n childrenProps.onMouseLeave = composeEventHandler(handleMouseLeave, childrenProps.onMouseLeave);\n if (!disableInteractive) {\n interactiveWrapperListeners.onMouseOver = handleMouseOver;\n interactiveWrapperListeners.onMouseLeave = handleMouseLeave;\n }\n }\n if (!disableFocusListener) {\n childrenProps.onFocus = composeEventHandler(handleFocus, childrenProps.onFocus);\n childrenProps.onBlur = composeEventHandler(handleBlur, childrenProps.onBlur);\n if (!disableInteractive) {\n interactiveWrapperListeners.onFocus = handleFocus;\n interactiveWrapperListeners.onBlur = handleBlur;\n }\n }\n if (process.env.NODE_ENV !== 'production') {\n if (children.props.title) {\n console.error(['MUI: You have provided a `title` prop to the child of .', `Remove this title prop \\`${children.props.title}\\` or the Tooltip component.`].join('\\n'));\n }\n }\n const popperOptions = React.useMemo(() => {\n var _PopperProps$popperOp;\n let tooltipModifiers = [{\n name: 'arrow',\n enabled: Boolean(arrowRef),\n options: {\n element: arrowRef,\n padding: 4\n }\n }];\n if ((_PopperProps$popperOp = PopperProps.popperOptions) != null && _PopperProps$popperOp.modifiers) {\n tooltipModifiers = tooltipModifiers.concat(PopperProps.popperOptions.modifiers);\n }\n return _extends({}, PopperProps.popperOptions, {\n modifiers: tooltipModifiers\n });\n }, [arrowRef, PopperProps]);\n const ownerState = _extends({}, props, {\n isRtl,\n arrow,\n disableInteractive,\n placement,\n PopperComponentProp,\n touch: ignoreNonTouchEvents.current\n });\n const classes = useUtilityClasses(ownerState);\n const PopperComponent = (_ref = (_slots$popper = slots.popper) != null ? _slots$popper : components.Popper) != null ? _ref : TooltipPopper;\n const TransitionComponent = (_ref2 = (_ref3 = (_slots$transition = slots.transition) != null ? _slots$transition : components.Transition) != null ? _ref3 : TransitionComponentProp) != null ? _ref2 : Grow;\n const TooltipComponent = (_ref4 = (_slots$tooltip = slots.tooltip) != null ? _slots$tooltip : components.Tooltip) != null ? _ref4 : TooltipTooltip;\n const ArrowComponent = (_ref5 = (_slots$arrow = slots.arrow) != null ? _slots$arrow : components.Arrow) != null ? _ref5 : TooltipArrow;\n const popperProps = appendOwnerState(PopperComponent, _extends({}, PopperProps, (_slotProps$popper = slotProps.popper) != null ? _slotProps$popper : componentsProps.popper, {\n className: clsx(classes.popper, PopperProps == null ? void 0 : PopperProps.className, (_ref6 = (_slotProps$popper2 = slotProps.popper) != null ? _slotProps$popper2 : componentsProps.popper) == null ? void 0 : _ref6.className)\n }), ownerState);\n const transitionProps = appendOwnerState(TransitionComponent, _extends({}, TransitionProps, (_slotProps$transition = slotProps.transition) != null ? _slotProps$transition : componentsProps.transition), ownerState);\n const tooltipProps = appendOwnerState(TooltipComponent, _extends({}, (_slotProps$tooltip = slotProps.tooltip) != null ? _slotProps$tooltip : componentsProps.tooltip, {\n className: clsx(classes.tooltip, (_ref7 = (_slotProps$tooltip2 = slotProps.tooltip) != null ? _slotProps$tooltip2 : componentsProps.tooltip) == null ? void 0 : _ref7.className)\n }), ownerState);\n const tooltipArrowProps = appendOwnerState(ArrowComponent, _extends({}, (_slotProps$arrow = slotProps.arrow) != null ? _slotProps$arrow : componentsProps.arrow, {\n className: clsx(classes.arrow, (_ref8 = (_slotProps$arrow2 = slotProps.arrow) != null ? _slotProps$arrow2 : componentsProps.arrow) == null ? void 0 : _ref8.className)\n }), ownerState);\n return /*#__PURE__*/_jsxs(React.Fragment, {\n children: [/*#__PURE__*/React.cloneElement(children, childrenProps), /*#__PURE__*/_jsx(PopperComponent, _extends({\n as: PopperComponentProp != null ? PopperComponentProp : Popper,\n placement: placement,\n anchorEl: followCursor ? {\n getBoundingClientRect: () => ({\n top: cursorPosition.y,\n left: cursorPosition.x,\n right: cursorPosition.x,\n bottom: cursorPosition.y,\n width: 0,\n height: 0\n })\n } : childNode,\n popperRef: popperRef,\n open: childNode ? open : false,\n id: id,\n transition: true\n }, interactiveWrapperListeners, popperProps, {\n popperOptions: popperOptions,\n children: ({\n TransitionProps: TransitionPropsInner\n }) => /*#__PURE__*/_jsx(TransitionComponent, _extends({\n timeout: theme.transitions.duration.shorter\n }, TransitionPropsInner, transitionProps, {\n children: /*#__PURE__*/_jsxs(TooltipComponent, _extends({}, tooltipProps, {\n children: [title, arrow ? /*#__PURE__*/_jsx(ArrowComponent, _extends({}, tooltipArrowProps, {\n ref: setArrowRef\n })) : null]\n }))\n }))\n }))]\n });\n});\nprocess.env.NODE_ENV !== \"production\" ? Tooltip.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the d.ts file and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * If `true`, adds an arrow to the tooltip.\n * @default false\n */\n arrow: PropTypes.bool,\n /**\n * Tooltip reference element.\n */\n children: elementAcceptingRef.isRequired,\n /**\n * Override or extend the styles applied to the component.\n */\n classes: PropTypes.object,\n /**\n * @ignore\n */\n className: PropTypes.string,\n /**\n * The components used for each slot inside.\n *\n * This prop is an alias for the `slots` prop.\n * It's recommended to use the `slots` prop instead.\n *\n * @default {}\n */\n components: PropTypes.shape({\n Arrow: PropTypes.elementType,\n Popper: PropTypes.elementType,\n Tooltip: PropTypes.elementType,\n Transition: PropTypes.elementType\n }),\n /**\n * The extra props for the slot components.\n * You can override the existing props or add new ones.\n *\n * This prop is an alias for the `slotProps` prop.\n * It's recommended to use the `slotProps` prop instead, as `componentsProps` will be deprecated in the future.\n *\n * @default {}\n */\n componentsProps: PropTypes.shape({\n arrow: PropTypes.object,\n popper: PropTypes.object,\n tooltip: PropTypes.object,\n transition: PropTypes.object\n }),\n /**\n * Set to `true` if the `title` acts as an accessible description.\n * By default the `title` acts as an accessible label for the child.\n * @default false\n */\n describeChild: PropTypes.bool,\n /**\n * Do not respond to focus-visible events.\n * @default false\n */\n disableFocusListener: PropTypes.bool,\n /**\n * Do not respond to hover events.\n * @default false\n */\n disableHoverListener: PropTypes.bool,\n /**\n * Makes a tooltip not interactive, i.e. it will close when the user\n * hovers over the tooltip before the `leaveDelay` is expired.\n * @default false\n */\n disableInteractive: PropTypes.bool,\n /**\n * Do not respond to long press touch events.\n * @default false\n */\n disableTouchListener: PropTypes.bool,\n /**\n * The number of milliseconds to wait before showing the tooltip.\n * This prop won't impact the enter touch delay (`enterTouchDelay`).\n * @default 100\n */\n enterDelay: PropTypes.number,\n /**\n * The number of milliseconds to wait before showing the tooltip when one was already recently opened.\n * @default 0\n */\n enterNextDelay: PropTypes.number,\n /**\n * The number of milliseconds a user must touch the element before showing the tooltip.\n * @default 700\n */\n enterTouchDelay: PropTypes.number,\n /**\n * If `true`, the tooltip follow the cursor over the wrapped element.\n * @default false\n */\n followCursor: PropTypes.bool,\n /**\n * This prop is used to help implement the accessibility logic.\n * If you don't provide this prop. It falls back to a randomly generated id.\n */\n id: PropTypes.string,\n /**\n * The number of milliseconds to wait before hiding the tooltip.\n * This prop won't impact the leave touch delay (`leaveTouchDelay`).\n * @default 0\n */\n leaveDelay: PropTypes.number,\n /**\n * The number of milliseconds after the user stops touching an element before hiding the tooltip.\n * @default 1500\n */\n leaveTouchDelay: PropTypes.number,\n /**\n * Callback fired when the component requests to be closed.\n *\n * @param {React.SyntheticEvent} event The event source of the callback.\n */\n onClose: PropTypes.func,\n /**\n * Callback fired when the component requests to be open.\n *\n * @param {React.SyntheticEvent} event The event source of the callback.\n */\n onOpen: PropTypes.func,\n /**\n * If `true`, the component is shown.\n */\n open: PropTypes.bool,\n /**\n * Tooltip placement.\n * @default 'bottom'\n */\n placement: PropTypes.oneOf(['bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n /**\n * The component used for the popper.\n * @default Popper\n */\n PopperComponent: PropTypes.elementType,\n /**\n * Props applied to the [`Popper`](/material-ui/api/popper/) element.\n * @default {}\n */\n PopperProps: PropTypes.object,\n /**\n * The extra props for the slot components.\n * You can override the existing props or add new ones.\n *\n * This prop is an alias for the `componentsProps` prop, which will be deprecated in the future.\n *\n * @default {}\n */\n slotProps: PropTypes.shape({\n arrow: PropTypes.object,\n popper: PropTypes.object,\n tooltip: PropTypes.object,\n transition: PropTypes.object\n }),\n /**\n * The components used for each slot inside.\n *\n * This prop is an alias for the `components` prop, which will be deprecated in the future.\n *\n * @default {}\n */\n slots: PropTypes.shape({\n arrow: PropTypes.elementType,\n popper: PropTypes.elementType,\n tooltip: PropTypes.elementType,\n transition: PropTypes.elementType\n }),\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Tooltip title. Zero-length titles string, undefined, null and false are never displayed.\n */\n title: PropTypes.node,\n /**\n * The component used for the transition.\n * [Follow this guide](/material-ui/transitions/#transitioncomponent-prop) to learn more about the requirements for this component.\n * @default Grow\n */\n TransitionComponent: PropTypes.elementType,\n /**\n * Props applied to the transition element.\n * By default, the element is based on this [`Transition`](http://reactcommunity.org/react-transition-group/transition/) component.\n */\n TransitionProps: PropTypes.object\n} : void 0;\nexport default Tooltip;","import '@/components/mui/menu-item.component.css';\nimport ArrowRightIcon from '@mui/icons-material/ArrowRight';\nimport {\n ListItemIcon as MuiListItemIcon,\n ListItemText as MuiListItemText,\n MenuItem as MuiMenuItem,\n} from '@mui/material';\nimport Tooltip from '@mui/material/Tooltip';\nimport { Localized, ReferencedItem, SingleColumnMenu } from 'platform-bible-utils';\nimport { MouseEvent, PropsWithChildren } from 'react';\n\ntype MenuItemInfoBase = {\n /** Text (displayable in the UI) as the name of the menu item */\n label: string;\n /** Text to display when the mouse hovers over the menu item */\n tooltip?: string;\n};\n\nexport type Command = MenuItemInfoBase & {\n /** Command to execute (string.string) */\n command: string;\n};\n\ntype SubMenu = MenuItemInfoBase & {\n /** Command to execute (string.string) */\n items: MenuItemInfo[];\n};\n\nexport interface CommandHandler {\n (command: Command): void;\n}\n\nexport type MenuPropsBase = {\n /*\n * The JSON defining the menu whose items are to be rendered. This will typically be one of the\n * menus in the \"defs\" in a Platform.Bible menu (see PlatformMenus). The schema for this is\n * menuDocumentSchema (at the end of menus.model.ts). Note that while this is a\n * \"SingleColumnMenu\", somewhat bizarrely, a MultiColumnMenu is a SingleColumnMenu, so it really\n * could be a MultiColumnMenu, in which case, column had better be defined so it can be used\n * to filter out the actual groups and items to display on the column.\n */\n menuDefinition: Localized;\n\n commandHandler: CommandHandler;\n\n /**\n * Additional action to perform when any menu item is clicked. Allows the caller to handle event\n * (e.g., to close the menu).\n */\n onClick?: (event: MouseEvent) => void;\n};\n\nexport type MenuItemListProps = MenuPropsBase & {\n /** Optional unique (column) identifier */\n columnId?: ReferencedItem;\n};\n\nexport type MenuItemProps = Omit &\n PropsWithChildren<{\n /** Optional unique identifier */\n id?: string;\n\n onClick: (event: MouseEvent) => void;\n }>;\n\ntype MenuItemInfo = (Command | SubMenu) & {\n /**\n * If specified, menu item will be inset if it does not have a leading icon.\n *\n * @default true\n */\n allowForLeadingIcons?: boolean;\n /**\n * If specified, the path to the icon image to display on the leading side of the menu text.\n *\n * @default undefined (no leading icon will be shown)\n */\n iconPathBefore?: string;\n /**\n * If specified, the path to the icon image to display on the trailing side of the menu text.\n *\n * @default undefined (no trailing icon will be shown)\n */\n iconPathAfter?: string;\n /**\n * If true, list item is focused during the first mount\n *\n * @default false\n */\n hasAutoFocus?: boolean;\n\n /** Additional css classes to help with unique styling of the menu item */\n className?: string;\n\n /**\n * If true, the menu item will appear disabled and it will not respond to clicks or mouse hovers.\n *\n * @default false\n */\n isDisabled?: boolean;\n\n /**\n * If true, compact vertical padding designed for keyboard and mouse input is used.\n *\n * @default true\n */\n isDense?: boolean;\n\n /**\n * If true, a right-arrow icon will be displayed (iconPathAfter, if specified, will be ignored).\n *\n * @default false\n */\n isSubMenuParent?: boolean;\n\n /**\n * If true, the left and right padding is removed\n *\n * @default false\n */\n hasDisabledGutters?: boolean;\n\n /**\n * If true, a 1px light border is added to bottom of menu item\n *\n * @default false\n */\n hasDivider?: boolean;\n\n /** Help identify which element has keyboard focus */\n focusVisibleClassName?: string;\n\n /** If it's a submenu, it should have the items property */\n items?: MenuItemInfo[];\n};\n\nfunction getIcon(icon: string | undefined, menuLabel: string, leading: boolean) {\n return icon ? (\n \n {`${leading\n \n ) : undefined;\n}\n\nexport default function MenuItem(props: MenuItemProps) {\n const {\n onClick,\n label,\n tooltip,\n allowForLeadingIcons = true,\n iconPathBefore = undefined,\n iconPathAfter = undefined,\n hasAutoFocus = false,\n className,\n isDisabled = false,\n isDense = true,\n isSubMenuParent = false,\n hasDisabledGutters = false,\n hasDivider = false,\n focusVisibleClassName,\n id,\n children,\n } = props;\n\n const menuItem = (\n \n {label ? (\n <>\n {getIcon(iconPathBefore, label, true)}\n \n {isSubMenuParent ? (\n \n \n \n ) : (\n getIcon(iconPathAfter, label, false)\n )}\n \n ) : (\n children\n )}\n \n );\n\n return tooltip ? (\n \n
    {menuItem}
    \n
    \n ) : (\n menuItem\n );\n}\n","import MenuItem, {\n MenuItemListProps,\n MenuItemProps,\n MenuPropsBase,\n} from '@/components/mui/menu-item.component';\nimport { Menu } from '@mui/material';\nimport {\n Localized,\n MenuGroupDetailsInSubMenu,\n MenuItemContainingCommand,\n MenuItemContainingSubmenu,\n OrderedExtensibleContainer,\n ReferencedItem,\n SingleColumnMenu,\n} from 'platform-bible-utils';\nimport { MouseEvent, useMemo, useState } from 'react';\n\n/**\n * All the exported types in this file should be regarded as \"internal\" (i.e., they should not be\n * exposed via index.ts).\n */\n\nexport type GroupedMenuPropsBase = MenuPropsBase & {\n /** Optional unique (column) identifier */\n columnId?: ReferencedItem;\n};\n\nexport type GroupedMenuItemListProps = MenuItemListProps & {\n /**\n * If the menuDefinition includes \"top-level\" groups (i.e., those that belong to a column as\n * opposed to those that belong to a submenu) that should not be included in the list, then this\n * array specifies which groups to include. Likewise, for a submenu, this list indicates which\n * groups are pertinent for that submenu. So then for a context menu this property need not be\n * specified since it is a top-level menu based on a \"true\" SingleColumnMenu (i.e., one that is\n * not a MultiColumnMenu).\n */\n includedGroups?: {\n id: string;\n group: Localized;\n }[];\n};\n\ninterface ItemInfo {\n item: Localized;\n isLastItemInGroup: boolean;\n}\n\ntype SubMenuProps = MenuPropsBase & {\n parentMenuItem: Localized;\n parentItemProps: Omit, 'iconPathAfter'>;\n};\n\nfunction getAllGroups(menuDefinition: Localized) {\n const groupEntries = Object.entries(menuDefinition.groups);\n // Convert array of entries to array of objects with id and group properties\n return groupEntries.map(([key, value]) => ({ id: key, group: value }));\n}\n\nfunction SubMenu(props: SubMenuProps) {\n const [anchorEl, setAnchorEl] = useState(undefined);\n\n const { parentMenuItem, parentItemProps, menuDefinition } = props;\n\n const handleParentMenuItemClick = (event: MouseEvent) => {\n setAnchorEl(event.currentTarget);\n };\n\n const handleClose = () => {\n setAnchorEl(undefined);\n };\n\n const renderSubMenuItems = () => {\n let includedGroups = getAllGroups(menuDefinition).filter((g) => 'menuItem' in g.group);\n\n // Ensure valid parent menu was provided. (If not, submenu will contain all groups!)\n if (!parentMenuItem?.id) throw new Error('A valid parent menu item is required for submenus.');\n\n // When laying out a submenu, only include groups associated with the provided parent menu.\n // Note: without the (annoying) redundant check that the included groups\n // have the menuItem field, TS doesn't think it exists.\n includedGroups = includedGroups.filter(\n (group) => 'menuItem' in group.group && group.group.menuItem === parentMenuItem.id,\n );\n\n return ;\n };\n\n return (\n <>\n \n \n {renderSubMenuItems()}\n \n \n );\n}\n\nconst getOrderedGroupItems = (\n groupId: string,\n allItems: Localized[],\n) => {\n // Filter items that belong to the specified group\n const itemsForGroup = allItems.filter((item) => item.group === groupId);\n // Sort items based on order\n const sortedItems = itemsForGroup.sort((a, b) => (a.order || 0) - (b.order || 0));\n return sortedItems;\n};\n\n/**\n * This component is internal; it does not need to be exposed to the outside world since it is not\n * useful on its own. It is used to generate and lay out the MenuItems that appear either on a\n * top-level menu (in a GridMenu or ContextMenu) or in a submenu.\n */\nexport default function GroupedMenuItemList(menuProps: GroupedMenuItemListProps) {\n const { menuDefinition, onClick, commandHandler, includedGroups } = menuProps;\n\n const { items, allowForLeadingIcons } = useMemo(() => {\n const groupsToInclude =\n includedGroups && includedGroups.length > 0\n ? includedGroups\n : // We're apparently laying out a single-column menu (presumably a context menu). In this\n // case, all groups should be included except ones that belong to a submenu.\n getAllGroups(menuDefinition).filter((g) => !('menuItem' in g.group));\n\n const sortedGroups = Object.values(groupsToInclude).sort(\n (a, b) => (a.group.order || 0) - (b.group.order || 0),\n );\n\n const itemArray: ItemInfo[] = [];\n\n sortedGroups.forEach((group) => {\n getOrderedGroupItems(group.id, menuDefinition.items).forEach((item) =>\n itemArray.push({ item, isLastItemInGroup: false }),\n );\n if (itemArray.length > 0) itemArray[itemArray.length - 1].isLastItemInGroup = true;\n });\n\n // No divider after last item in final group.\n if (itemArray.length > 0) itemArray[itemArray.length - 1].isLastItemInGroup = false;\n\n const allowSpaceForLeadingIcons = itemArray.some(\n (i) => 'iconPathBefore' in i.item && i.item.iconPathBefore,\n );\n\n return { items: itemArray, allowForLeadingIcons: allowSpaceForLeadingIcons };\n }, [includedGroups, menuDefinition]);\n\n // Create props for MenuItem component including setting hasDivider for the last item in a group\n const createMenuItemProps = ({ item, isLastItemInGroup }: ItemInfo) => {\n const menuItemProps = {\n className: 'papi-menu-item',\n label: item.label,\n tooltip: item.tooltip,\n iconPathBefore: 'iconPathBefore' in item ? item.iconPathBefore : undefined,\n iconPathAfter: 'iconPathAfter' in item ? item.iconPathAfter : undefined,\n hasDivider: isLastItemInGroup, // Set hasDivider to true for the last item in a group\n allowForLeadingIcons,\n };\n\n return menuItemProps;\n };\n\n const [firstItem] = items;\n\n if (!firstItem) return
    ;\n\n const divKey = firstItem.item.group;\n\n return (\n
    \n {items.map((itemInfo, index) => {\n const { item } = itemInfo;\n const menuItemProps = createMenuItemProps(itemInfo);\n if ('command' in item) {\n const key = item.group + index;\n return (\n ) => {\n onClick?.(event);\n commandHandler(item);\n }}\n {...menuItemProps}\n />\n );\n }\n return (\n \n );\n })}\n
    \n );\n}\n","import GroupedMenuItemList from '@/components/mui/grouped-menu-item-list.component';\nimport { MenuItemListProps } from '@/components/mui/menu-item.component';\nimport { MultiColumnMenu } from 'platform-bible-utils';\n\n/**\n * This component is internal; it does not need to be exposed to the outside world since it is not\n * useful on its own. Use either GridMenu or ContextMenu.\n */\nexport default function TopLevelMenu(props: MenuItemListProps) {\n const { menuDefinition, columnId } = props;\n\n const groupEntries = Object.entries(menuDefinition.groups);\n // Convert array of entries to array of objects with id and group properties\n const groups = groupEntries.map(([key, value]) => ({ id: key, group: value }));\n let includedGroups = groups.filter((g) => 'column' in g.group);\n\n // Check if column is provided and menuDefinition is a MultiColumnMenu\n if (\n columnId &&\n 'columns' in menuDefinition &&\n // Without this type assertion, TS doesn't know what columns is.\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n (menuDefinition as MultiColumnMenu).columns[columnId]\n ) {\n // When laying out a single column in a MultiColumnMenu, only include groups associated with\n // the provided column. Note: without the (annoying) redundant check that the included groups\n // have the colum field, TS doesn't think it exists.\n includedGroups = includedGroups.filter(\n (g) => 'column' in g.group && g.group.column === columnId,\n );\n }\n\n return ;\n}\n","import '@/components/mui/grid-menu.component.css';\nimport { GroupedMenuPropsBase } from '@/components/mui/grouped-menu-item-list.component';\nimport { CommandHandler } from '@/components/mui/menu-item.component';\nimport TopLevelMenu from '@/components/mui/top-level-menu.component';\nimport { Grid, List } from '@mui/material';\nimport {\n Localized,\n MenuColumnWithHeader,\n MultiColumnMenu,\n ReferencedItem,\n} from 'platform-bible-utils';\nimport { useMemo } from 'react';\n\ntype ColumnInfo = {\n /*\n * The ID (`${string}.${string}`) of a specific menu column.\n */\n id: ReferencedItem;\n\n /*\n * Metadata (label, order, etc.) for a specific menu column.\n */\n metadata: Localized;\n};\n\ntype MenuColumnProps = ColumnInfo &\n GroupedMenuPropsBase & {\n /** Additional css classes to help with unique styling of the menu column */\n className?: string;\n };\n\nexport type GridMenuInfo = {\n /** The menu object containing information about the columns, groups, and items to display. */\n multiColumnMenu: Localized;\n};\n\nexport type GridMenuProps = GridMenuInfo & {\n /** Optional unique identifier */\n id?: string;\n\n commandHandler: CommandHandler;\n\n /** Additional css classes to help with unique styling of the grid menu */\n className?: string;\n};\n\nfunction MenuColumn({\n commandHandler,\n menuDefinition,\n id,\n metadata,\n onClick,\n className,\n}: MenuColumnProps) {\n return (\n \n

    \n {metadata.label}\n

    \n {/* It would seem as though this List component were unnecessary, since it only contains one\n thing, but the \"dense\" property does affect the layout of the items (in a way I don't fully\n understand). There might be a better way. */}\n \n \n \n \n );\n}\n\nexport default function GridMenu({\n commandHandler,\n className,\n multiColumnMenu,\n id,\n}: GridMenuProps) {\n const { columns } = multiColumnMenu;\n\n const sortedColumns = useMemo(() => {\n const columnNumbers = new Map();\n Object.getOwnPropertyNames(columns).forEach((columnName: string) => {\n // We know for sure there is a (boolean) property 'isExtensible' that we are not interested in.\n if (columnName === 'isExtensible') return;\n // TS doesn't allow `columnName` above to be a ReferencedItem even though the type says it is\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const columnId = columnName as ReferencedItem;\n const column = columns[columnId];\n // As of right now (and hopefully forever after), all remaining properties of the\n // ColumnsWithHeaders object are columns whose property names are the IDs of the columns.\n // This is an additional (redundant) sanity check. Specifically we're interested in\n // MenuColumnWithHeader objects, which TypeScript now \"knows\" we have, but at runtime all we\n // can check for is that it's an object with a valid numeric order field. That's likely good\n // enough.\n if (\n typeof column === 'object' &&\n typeof column.order === 'number' &&\n !Number.isNaN(column.order)\n )\n columnNumbers.set(column.order, { id: columnId, metadata: column });\n else\n console.warn(\n `Property ${columnName} (${typeof column}) on menu ${id} is not a valid column and is being ignored. This might indicate data corruption`,\n );\n });\n\n // Extract values and sort them based on the 'order' property\n return Array.from(columnNumbers.values()).sort((a, b) => {\n return (a.metadata.order || 0) - (b.metadata.order || 0);\n });\n }, [columns, id]);\n\n // We might need something like this if we need to be able to prevent empty columns\n // sortedColumns.filter((c) => multiColumnMenu.groups.some((g) => 'column' in g && (g as .column)...\n\n return (\n \n {sortedColumns.map((col, index) => (\n \n ))}\n \n );\n}\n","import { useEffect, useRef, useState } from 'react';\n\nexport type UsePromiseOptions = {\n /**\n * Whether to leave the value as the most recent resolved promise value or set it back to\n * defaultValue while running the promise again. Defaults to true\n */\n preserveValue?: boolean;\n};\n\n/** Set up defaults for options for usePromise hook */\nfunction getUsePromiseOptionsDefaults(options: UsePromiseOptions): UsePromiseOptions {\n return {\n preserveValue: true,\n ...options,\n };\n}\n\n/**\n * Awaits a promise and returns a loading value while the promise is unresolved\n *\n * @param promiseFactoryCallback A function that returns the promise to await. If this callback is\n * undefined, the current value will be returned (defaultValue unless it was previously changed\n * and `options.preserveValue` is true), and there will be no loading.\n *\n * WARNING: MUST BE STABLE - const or wrapped in useCallback. The reference must not be updated\n * every render\n * @param defaultValue The initial value to return while first awaiting the promise. If\n * `options.preserveValue` is false, this value is also shown while awaiting the promise on\n * subsequent calls.\n *\n * Note: this parameter is internally assigned to a `ref`, so changing it will not cause any hooks\n * to re-run with its new value. This means that, if the `promiseFactoryCallback` changes and\n * `options.preserveValue` is `false`, the returned value will be set to the current\n * `defaultValue`. However, the returned value will not be updated if`defaultValue` changes.\n * @param options Various options for adjusting how this hook runs the `promiseFactoryCallback`\n *\n * Note: this parameter is internally assigned to a `ref`, so changing it will not cause any hooks\n * to re-run with its new value. However, the latest `options.preserveValue` will always be used\n * appropriately to determine whether to preserve the returned value when changing the\n * `promiseFactoryCallback`\n * @returns `[value, isLoading]`\n *\n * - `value`: the current value for the promise, either the defaultValue or the resolved promise value\n * - `isLoading`: whether the promise is waiting to be resolved\n */\nconst usePromise = (\n promiseFactoryCallback: (() => Promise) | undefined,\n defaultValue: T,\n options: UsePromiseOptions = {},\n): [value: T, isLoading: boolean] => {\n // Use defaultValue as a ref so it doesn't update dependency arrays\n const defaultValueRef = useRef(defaultValue);\n defaultValueRef.current = defaultValue;\n // Use options as a ref so it doesn't update dependency arrays\n const optionsDefaultedRef = useRef(options);\n optionsDefaultedRef.current = getUsePromiseOptionsDefaults(optionsDefaultedRef.current);\n\n const [value, setValue] = useState(() => defaultValueRef.current);\n const [isLoading, setIsLoading] = useState(true);\n useEffect(() => {\n let promiseIsCurrent = true;\n // If a promiseFactoryCallback was provided, we are loading. Otherwise, there is no loading to do\n setIsLoading(!!promiseFactoryCallback);\n (async () => {\n // If there is a callback to run, run it\n if (promiseFactoryCallback) {\n const result = await promiseFactoryCallback();\n // If the promise was not already replaced, update the value\n if (promiseIsCurrent) {\n setValue(() => result);\n setIsLoading(false);\n }\n }\n })();\n\n return () => {\n // Mark this promise as old and not to be used\n promiseIsCurrent = false;\n if (!optionsDefaultedRef.current.preserveValue) setValue(() => defaultValueRef.current);\n };\n }, [promiseFactoryCallback]);\n\n return [value, isLoading];\n};\nexport default usePromise;\n","\"use client\";\n\nimport createSvgIcon from './utils/createSvgIcon';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nexport default createSvgIcon( /*#__PURE__*/_jsx(\"path\", {\n d: \"M3 18h18v-2H3zm0-5h18v-2H3zm0-7v2h18V6z\"\n}), 'Menu');","import GridMenu from '@/components/mui/grid-menu.component';\nimport { Command, CommandHandler } from '@/components/mui/menu-item.component';\nimport usePromise from '@/hooks/use-promise.hook';\nimport { Menu as MenuIcon } from '@mui/icons-material';\nimport { Drawer, IconButton } from '@mui/material';\nimport { Localized, MultiColumnMenu } from 'platform-bible-utils';\nimport {\n MouseEvent,\n MutableRefObject,\n PropsWithChildren,\n useCallback,\n useEffect,\n useState,\n} from 'react';\n\nexport interface MultiColumnMenuProvider {\n (isSupportAndDevelopment: boolean): Promise>;\n}\n\nexport type HamburgerMenuButtonProps = PropsWithChildren & {\n /** The handler to use for menu commands (and eventually toolbar commands). */\n commandHandler: CommandHandler;\n\n /**\n * Optional reference to the \"div\" container that determines the where the menu should appear. If\n * not defined, then (1,1) used.\n */\n containerRef?: MutableRefObject;\n\n /**\n * The delegate to use to get the menu data. If not specified or if it returns undefined, the data\n * in normalMenu or fullMenu property will be used.\n */\n menuProvider?: MultiColumnMenuProvider;\n\n /**\n * The menu data to show when the menu is opened if the menuProvider property is not defined.\n * (This allows for a default or test-only static menu to be used.)\n */\n normalMenu?: Localized;\n\n /**\n * The menu data to show for \"full\" menu (when opened with the SHIFT key pressed) if the\n * menuProvider property is not defined. (This allows for a default or test-only static menu to be\n * used.)\n */\n fullMenu?: Localized;\n\n /** Additional css class(es) to help with unique styling of the sub-components */\n className?: string;\n\n /** Value to use as prefix for ARIA labels on interactive sub-components */\n ariaLabelPrefix?: string;\n};\n\nexport default function HamburgerMenuButton({\n menuProvider,\n normalMenu,\n fullMenu,\n commandHandler,\n containerRef,\n className,\n ariaLabelPrefix,\n children,\n}: HamburgerMenuButtonProps) {\n const [isMenuOpen, setMenuOpen] = useState(false);\n const [showFullMenu, setShowFullMenu] = useState(false);\n\n const handleMenuItemClick = useCallback(() => {\n if (isMenuOpen) setMenuOpen(false);\n setShowFullMenu(false);\n }, [isMenuOpen]);\n\n const handleMenuButtonClick = useCallback((e: MouseEvent) => {\n e.stopPropagation();\n setMenuOpen((prevIsOpen) => {\n const isOpening = !prevIsOpen;\n if (isOpening && e.shiftKey) setShowFullMenu(true);\n else if (!isOpening) setShowFullMenu(false);\n return isOpening;\n });\n }, []);\n\n const menuCommandHandler = useCallback(\n (command: Command) => {\n handleMenuItemClick();\n return commandHandler(command);\n },\n [commandHandler, handleMenuItemClick],\n );\n\n const [offset, setOffset] = useState({ top: 1, left: 1 });\n\n useEffect(() => {\n if (isMenuOpen) {\n const node = containerRef?.current;\n if (node) {\n const rect = node.getBoundingClientRect();\n const scrollTop = window.scrollY;\n const scrollLeft = window.scrollX;\n const top = rect.top + scrollTop + node.clientHeight;\n const left = rect.left + scrollLeft;\n setOffset({ top, left });\n }\n }\n }, [isMenuOpen, containerRef]);\n\n const [normalMenuData] = usePromise(\n useCallback(async () => {\n return menuProvider?.(false) ?? normalMenu;\n // isMenuOpen needs to be included for the menu contents to reevaluate when reopened\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [menuProvider, normalMenu, isMenuOpen]),\n normalMenu,\n );\n\n const [fullMenuData] = usePromise(\n useCallback(async () => {\n return menuProvider?.(true) ?? fullMenu ?? normalMenuData;\n // isMenuOpen needs to be included for the menu contents to reevaluate when reopened\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [menuProvider, fullMenu, normalMenuData, isMenuOpen]),\n fullMenu ?? normalMenuData,\n );\n\n const menu = showFullMenu && fullMenuData ? fullMenuData : normalMenuData;\n\n return (\n <>\n \n {children ?? }\n \n \n {menu ? (\n \n ) : undefined}\n \n \n );\n}\n","import '@/components/mui/icon-button.component.css';\nimport { IconButton as MuiIconButton } from '@mui/material';\nimport { MouseEventHandler, PropsWithChildren } from 'react';\n\nexport type IconButtonProps = PropsWithChildren<{\n /** Optional unique identifier */\n id?: string;\n /**\n * Required. Used as both the tooltip (aka, title) and the aria-label (used for accessibility,\n * testing, etc.), unless a distinct tooltip is supplied.\n */\n label: string;\n /**\n * Enabled status of button\n *\n * @default false\n */\n isDisabled?: boolean;\n /** Optional tooltip to display if different from the aria-label. */\n tooltip?: string;\n /** If true, no tooltip will be displayed. */\n isTooltipSuppressed?: boolean;\n /**\n * If given, uses a negative margin to counteract the padding on one side (this is often helpful\n * for aligning the left or right side of the icon with content above or below, without ruining\n * the border size and shape).\n *\n * @default false\n */\n adjustMarginToAlignToEdge?: 'end' | 'start' | false;\n /**\n * The size of the component. small is equivalent to the dense button styling.\n *\n * @default false\n */\n size: 'small' | 'medium' | 'large';\n /** Additional css classes to help with unique styling of the button */\n className?: string;\n /** Optional click handler */\n onClick?: MouseEventHandler;\n}>;\n\n/**\n * Iconic button a user can click to do something\n *\n * Thanks to MUI for heavy inspiration and documentation\n * https://mui.com/material-ui/getting-started/overview/\n */\nfunction IconButton({\n id,\n label,\n isDisabled = false,\n tooltip,\n isTooltipSuppressed = false,\n adjustMarginToAlignToEdge = false,\n size = 'medium',\n className,\n onClick,\n children,\n}: IconButtonProps) {\n return (\n \n {children /* the icon to display */}\n \n );\n}\n\nexport default IconButton;\n","import { cn } from '@/utils/shadcn-ui.util';\nimport { LoaderCircle, LucideProps } from 'lucide-react';\nimport { forwardRef } from 'react';\n\nexport type SpinnerProps = LucideProps;\n\nconst Spinner = forwardRef(({ className, ...props }, ref) => {\n return (\n \n );\n});\n\nSpinner.displayName = 'Spinner';\n\nexport default Spinner;\n","import { Input as ShadInput } from '@/components/shadcn-ui/input';\nimport { Label as ShadLabel } from '@/components/shadcn-ui/label';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { ChangeEventHandler, FocusEventHandler } from 'react';\n\nexport type TextFieldProps = {\n /** Optional unique identifier */\n id?: string;\n /**\n * If `true`, the component is disabled.\n *\n * @default false\n */\n isDisabled?: boolean;\n /**\n * If `true`, the label is displayed in an error state.\n *\n * @default false\n */\n hasError?: boolean;\n /**\n * If `true`, the input will take up the full width of its container.\n *\n * @default false\n */\n isFullWidth?: boolean;\n /** Text that gives the user instructions on what contents the TextField expects */\n helperText?: string;\n /** The title of the TextField */\n label?: string;\n /** The short hint displayed in the `input` before the user enters a value. */\n placeholder?: string;\n /**\n * If `true`, the label is displayed as required and the `input` element is required.\n *\n * @default false\n */\n isRequired?: boolean;\n /** Additional css classes to help with unique styling of the text field */\n className?: string;\n /** Starting value for the text field if it is not controlled */\n defaultValue?: string | number;\n /** Value of the text field if controlled */\n value?: string | number;\n /** Triggers when content of textfield is changed */\n onChange?: ChangeEventHandler;\n /** Triggers when textfield gets focus */\n onFocus?: FocusEventHandler;\n /** Triggers when textfield loses focus */\n onBlur?: FocusEventHandler;\n};\n\n/**\n * Text input field\n *\n * Thanks to Shadcn for heavy inspiration and documentation\n * https://ui.shadcn.com/docs/components/input#with-label\n */\nfunction TextField({\n id,\n isDisabled = false,\n hasError = false,\n isFullWidth = false,\n helperText,\n label,\n placeholder,\n isRequired = false,\n className,\n defaultValue,\n value,\n onChange,\n onFocus,\n onBlur,\n}: TextFieldProps) {\n return (\n
    \n {`${label}${isRequired ? '*' : ''}`}\n \n

    {helperText}

    \n
    \n );\n}\n\nexport default TextField;\n","import HamburgerMenuButton, {\n MultiColumnMenuProvider,\n} from '@/components/mui/hamburger-menu-button.component';\nimport { CommandHandler } from '@/components/mui/menu-item.component';\nimport '@/components/mui/toolbar.component.css';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { AppBar, Toolbar as MuiToolbar } from '@mui/material';\nimport { PropsWithChildren, useRef } from 'react';\n\nexport type ToolbarProps = PropsWithChildren<{\n /** The handler to use for menu commands (and eventually toolbar commands). */\n commandHandler: CommandHandler;\n\n /**\n * The optional delegate to use to get the menu data. If not specified, the \"hamburger\" menu will\n * not display.\n */\n menuProvider?: MultiColumnMenuProvider;\n\n /** Optional unique identifier */\n id?: string;\n\n /** Additional css classes to help with unique styling of the toolbar */\n className?: string;\n}>;\n\nexport default function Toolbar({\n menuProvider,\n commandHandler,\n className,\n id,\n children,\n}: ToolbarProps) {\n // This ref will always be defined\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const containerRef = useRef(undefined!);\n\n return (\n
    \n \n \n {menuProvider ? (\n \n ) : undefined}\n {children ?
    {children}
    : undefined}\n \n
    \n
    \n );\n}\n","import React from 'react';\nimport { cva, type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst alertVariants = cva(\n 'tw-relative tw-w-full tw-rounded-lg tw-border tw-p-4 [&>svg~*]:tw-pl-7 [&>svg+div]:tw-translate-y-[-3px] [&>svg]:tw-absolute [&>svg]:tw-left-4 [&>svg]:tw-top-4 [&>svg]:tw-text-foreground',\n {\n variants: {\n variant: {\n default: 'tw-bg-background tw-text-foreground',\n destructive:\n 'tw-border-destructive/50 tw-text-destructive dark:tw-border-destructive [&>svg]:tw-text-destructive',\n },\n },\n defaultVariants: {\n variant: 'default',\n },\n },\n);\n\nconst Alert = React.forwardRef<\n HTMLDivElement,\n React.HTMLAttributes & VariantProps\n>(({ className, variant, ...props }, ref) => (\n
    \n));\nAlert.displayName = 'Alert';\n\nconst AlertTitle = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n {/* added because of https://github.com/jsx-eslint/eslint-plugin-jsx-a11y/blob/main/docs/rules/heading-has-content.md */}\n {props.children}{' '}\n \n ),\n);\nAlertTitle.displayName = 'AlertTitle';\n\nconst AlertDescription = React.forwardRef<\n HTMLParagraphElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n
    \n));\nAlertDescription.displayName = 'AlertDescription';\n\nexport { Alert, AlertTitle, AlertDescription };\n","import React from 'react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Card = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nCard.displayName = 'Card';\n\nconst CardHeader = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nCardHeader.displayName = 'CardHeader';\n\nconst CardTitle = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n {/* added because of https://github.com/jsx-eslint/eslint-plugin-jsx-a11y/blob/main/docs/rules/heading-has-content.md */}\n {props.children}\n \n ),\n);\nCardTitle.displayName = 'CardTitle';\n\nconst CardDescription = React.forwardRef<\n HTMLParagraphElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n

    \n));\nCardDescription.displayName = 'CardDescription';\n\nconst CardContent = React.forwardRef>(\n ({ className, ...props }, ref) => (\n

    \n ),\n);\nCardContent.displayName = 'CardContent';\n\nconst CardFooter = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nCardFooter.displayName = 'CardFooter';\n\nexport { Card, CardHeader, CardFooter, CardTitle, CardDescription, CardContent };\n","import { ComponentProps } from 'react';\nimport { toast as sonner, Toaster } from 'sonner';\n\ntype SonnerProps = ComponentProps;\n\nfunction Sonner({ ...props }: SonnerProps) {\n return (\n \n );\n}\n\n// The re-export of the sonner function was added manually\nexport { Sonner, sonner };\n","import React from 'react';\nimport * as SliderPrimitive from '@radix-ui/react-slider';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Slider = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n \n \n \n));\nSlider.displayName = SliderPrimitive.Root.displayName;\n\nexport { Slider };\n","import React from 'react';\nimport * as SwitchPrimitives from '@radix-ui/react-switch';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Switch = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n));\nSwitch.displayName = SwitchPrimitives.Root.displayName;\n\nexport { Switch };\n","import React from 'react';\nimport * as TabsPrimitive from '@radix-ui/react-tabs';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport const Tabs = TabsPrimitive.Root;\n\nexport type TabsListProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport type TabsTriggerProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport type TabsContentProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport const TabsList = React.forwardRef<\n React.ElementRef,\n TabsListProps\n>(({ className, ...props }, ref) => (\n \n));\nTabsList.displayName = TabsPrimitive.List.displayName;\n\nexport const TabsTrigger = React.forwardRef<\n React.ElementRef,\n TabsTriggerProps\n>(({ className, ...props }, ref) => (\n \n));\nTabsTrigger.displayName = TabsPrimitive.Trigger.displayName;\n\nexport const TabsContent = React.forwardRef<\n React.ElementRef,\n TabsContentProps\n>(({ className, ...props }, ref) => (\n \n));\nTabsContent.displayName = TabsPrimitive.Content.displayName;\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Download } from 'lucide-react';\n\ntype InstallButtonProps = {\n /** The installing boolean value determines the state of the button. */\n isInstalling: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n /** Optional text for the button. */\n buttonText?: string;\n} & ButtonProps;\n\n/**\n * The InstallButton component is a button designed for initiating installs. It includes visuals for\n * active installing and idle states.\n *\n * @param isInstalling The installing boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @param buttonText Optional text for the button.\n * @returns A install button.\n */\nexport default function InstallButton({\n isInstalling,\n handleClick,\n buttonText,\n className,\n ...props\n}: InstallButtonProps) {\n return (\n \n {isInstalling ? (\n \n ) : (\n <>\n \n {buttonText}\n \n )}\n \n );\n}\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\n\ntype EnableButtonProps = {\n /** The enabling boolean value determines the state of the button. */\n isEnabling: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n} & ButtonProps;\n\n/**\n * The EnableButton component is a button designed for initiating enabling of downloads. It includes\n * visuals for active enabling and idle states.\n *\n * @param isEnabling The enabling boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @returns A button that can be used to enable.\n */\nexport default function EnableButton({\n isEnabling,\n handleClick,\n className,\n ...props\n}: EnableButtonProps) {\n return (\n \n {isEnabling ? (\n <>\n \n Enabling...\n \n ) : (\n 'Enable'\n )}\n \n );\n}\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\n\ntype DisableButtonProps = {\n /** The disabling boolean value determines the state of the button. */\n isDisabling: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n} & ButtonProps;\n\n/**\n * The DisableButton component is a button designed for initiating disabling of downloads. It\n * includes visuals for active disabling and idle states.\n *\n * @param isDisabling The disabling boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @returns A button that can be used to disable.\n */\nexport default function DisableButton({\n isDisabling,\n handleClick,\n className,\n ...props\n}: DisableButtonProps) {\n return (\n \n {isDisabling ? (\n <>\n \n Disabling...\n \n ) : (\n 'Disable'\n )}\n \n );\n}\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\n\ntype UpdateButtonProps = {\n /** The updating boolean value determines the state of the button. */\n isUpdating: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n} & ButtonProps;\n\n/**\n * The UpdateButton component is a button designed for initiating updates for downloaded extensions.\n * It includes visuals for active updating and idle states.\n *\n * @param isUpdating The updating boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @returns A button that can be used to update.\n */\nexport default function UpdateButton({\n isUpdating,\n handleClick,\n className,\n ...props\n}: UpdateButtonProps) {\n return (\n \n {isUpdating ? (\n <>\n \n Updating...\n \n ) : (\n 'Update'\n )}\n \n );\n}\n","import { cn } from '@/utils/shadcn-ui.util';\nimport Markdown, { MarkdownToJSX } from 'markdown-to-jsx';\nimport { useMemo } from 'react';\n\ninterface MarkdownRendererProps {\n /** Optional unique identifier */\n id?: string;\n /** The markdown string to render */\n markdown: string;\n className?: string;\n /**\n * The [`target` attribute for `a` html\n * tags](https://developer.mozilla.org/en-US/docs/Web/HTML/Element/a#target). Defaults to not\n * adding a `target` to `a` tags\n */\n anchorTarget?: string;\n}\n\n/**\n * This component renders markdown content given a markdown string. It uses typography styles from\n * the platform.\n *\n * @param markdown The markdown string to render.\n * @param id Optional unique identifier\n * @returns A div containing the rendered markdown content.\n */\nexport default function MarkdownRenderer({\n id,\n markdown,\n className,\n anchorTarget,\n}: MarkdownRendererProps) {\n const options: MarkdownToJSX.Options = useMemo(\n () => ({\n overrides: {\n a: {\n props: {\n target: anchorTarget,\n },\n },\n },\n }),\n [anchorTarget],\n );\n return (\n
    \n {markdown}\n
    \n );\n}\n","import { Filter, ChevronDown } from 'lucide-react';\nimport { forwardRef } from 'react';\nimport { Button } from '@/components/shadcn-ui/button';\n\n/**\n * The FilterButton component is a button designed for initiating filtering of data. It is designed\n * to be used with the dropdown menu. It uses forwardRef to pass the button to the dropdown trigger\n * asChild.\n *\n * @returns A button that can be used to filter.\n */\nconst FilterButton = forwardRef((props, ref) => {\n return (\n \n \n Filter\n \n \n );\n});\n\nexport default FilterButton;\n","import {\n DropdownMenu,\n DropdownMenuTrigger,\n DropdownMenuContent,\n DropdownMenuLabel,\n DropdownMenuGroup,\n DropdownMenuCheckboxItem,\n DropdownMenuRadioItem,\n DropdownMenuSeparator,\n} from '@/components/shadcn-ui/dropdown-menu';\nimport FilterButton from './buttons/filter-button.component';\n\nexport enum DropdownMenuItemType {\n Check,\n Radio,\n}\n\nexport type DropdownItem = {\n /** The label is the text that will be displayed on the dropdown item. */\n label: string;\n /** The itemType determines the DropdownMenuItemType type as either Check or Radio. */\n itemType: DropdownMenuItemType;\n /** The onClick function is called when the item is clicked. */\n onClick: () => void;\n};\n\nexport type DropdownGroup = {\n /**\n * The label is the text that will be displayed on the dropdown group. It is used to categorize\n * the items in the group.\n */\n label: string;\n /** The items array contains the items that will be displayed in the dropdown group */\n items: DropdownItem[];\n};\n\nexport type FilterDropdownProps = {\n /** Object unique identifier */\n id?: string;\n /** The groups array contains the groups that will be displayed in the dropdown */\n groups: DropdownGroup[];\n}; // TODO: extend the props later\n\n/**\n * The FilterDropdown component is a dropdown designed for filtering content. It includes groups of\n * items that can be checkboxes or radio items.\n *\n * @param id Optional unique identifier\n * @param groups The groups array contains the groups that will be displayed in the dropdown\n * @returns A filter dropdown.\n */\nexport default function FilterDropdown({ id, groups }: FilterDropdownProps) {\n return (\n
    \n {/* TODO: remove this once the DropDown Menu shadcn has an id prop */}\n \n \n \n \n \n {groups.map((group) => (\n
    \n {group.label}\n \n {group.items.map((item) => (\n
    \n {item.itemType === DropdownMenuItemType.Check ? (\n \n {item.label}\n \n ) : (\n \n {item.label}\n \n )}\n
    \n ))}\n
    \n \n
    \n ))}\n
    \n
    \n
    \n );\n}\n","interface NoExtensionsFoundProps {\n /** Optional unique identifier */\n id?: string;\n /** The message to display */\n message: string;\n}\n/**\n * This component displays a message to the user when no extensions are found in the marketplace.\n *\n * @param id Optional unique identifier\n * @param message The message to display.\n * @returns {JSX.Element} - Returns the message component that displays the message to the user.\n */\nexport default function NoExtensionsFound({ id, message }: NoExtensionsFoundProps) {\n return (\n
    \n
    \n

    {message}

    \n
    \n
    \n );\n}\n","import { CircleHelp, Link as LucideLink, User } from 'lucide-react';\nimport { NumberFormat } from 'platform-bible-utils';\n\n/** Interface that stores the parameters passed to the More Info component */\ninterface MoreInfoProps {\n /** Optional unique identifier */\n id?: string;\n /** The category of the extension */\n category: string;\n /** The number of downloads for the extension */\n downloads: Record;\n /** The languages supported by the extension */\n languages: string[];\n /** The URL to the more info page of the extension */\n moreInfoUrl: string;\n}\n/**\n * This component displays the more info section of the extension which includes the category,\n * number of downloads, languages, and links to the website and support\n *\n * @param id Optional unique identifier\n * @param category The category of the extension\n * @param downloads The number of downloads for the extension\n * @param languages The languages supported by the extension\n * @param moreInfoUrl The URL to the more info page of the extension\n * @returns {JSX.Element} - Returns the more info component that displays the category, number of\n * downloads, languages, and links to the website and support\n */\nexport default function MoreInfo({\n id,\n category,\n downloads,\n languages,\n moreInfoUrl,\n}: MoreInfoProps) {\n /**\n * This constant formats the number of downloads into a more readable format.\n *\n * @example 1000 -> 1K\n *\n * @example 1000000 -> 1M\n *\n * @returns The formatted number of downloads\n */\n const numberFormatted = new NumberFormat('en', {\n notation: 'compact',\n compactDisplay: 'short',\n }).format(Object.values(downloads).reduce((a: number, b: number) => a + b, 0));\n\n /** This function scrolls the window to the bottom of the page. */\n const handleScrollToBottom = () => {\n window.scrollTo(0, document.body.scrollHeight);\n };\n\n return (\n \n
    \n
    \n {category}\n
    \n CATEGORY\n
    \n
    \n
    \n
    \n \n {numberFormatted}\n
    \n USERS\n
    \n
    \n
    \n
    \n {languages.slice(0, 3).map((locale) => (\n \n {locale.toUpperCase()}\n \n ))}\n
    \n {languages.length > 3 && (\n handleScrollToBottom()}\n className=\"tw-text-xs tw-text-gray-500 tw-underline\"\n >\n +{languages.length - 3} more languages\n \n )}\n
    \n
    \n
    \n \n Website\n \n \n \n Support\n \n \n
    \n
    \n );\n}\n","import { useState } from 'react';\n\nexport type VersionInformation = {\n /** Date the version was published */\n date: string;\n /** Description of the changes in the version */\n description: string;\n};\n\n/** Type to store the version history information */\nexport type VersionHistoryType = Record;\n\n/** Interface that stores the parameters passed to the Version History component */\ninterface VersionHistoryProps {\n /** Optional unique identifier */\n id?: string;\n /** Object containing the versions mapped with their information */\n versionHistory: VersionHistoryType;\n}\n\n/**\n * Component to render the version history information shown in the footer component. Lists the 5\n * most recent versions, with the options to show all versions by pressing a button.\n *\n * @param versionHistory Object containing the versions mapped with their information\n * @param id Optional unique identifier\n * @returns Rendered version history for the Footer component\n */\nexport default function VersionHistory({ id, versionHistory }: VersionHistoryProps) {\n const [showAllVersions, setShowAllVersions] = useState(false);\n const currentDate = new Date();\n\n /**\n * Function to format the time string for the version history in the form of 'X year(s) ago'.\n *\n * @param dateString ISO Date string to determine the time string from\n * @returns Formatted time string\n */\n function formatTimeString(dateString: string) {\n const date = new Date(dateString);\n const dateDiff = new Date(currentDate.getTime() - date.getTime());\n const yearDiff = dateDiff.getUTCFullYear() - 1970;\n const monthDiff = dateDiff.getUTCMonth();\n const dayDiff = dateDiff.getUTCDate() - 1;\n\n // Determines how long ago the version was published\n let timeString = '';\n if (yearDiff > 0) {\n timeString = `${yearDiff.toString()} year${yearDiff === 1 ? '' : 's'} ago`;\n } else if (monthDiff > 0) {\n timeString = `${monthDiff.toString()} month${monthDiff === 1 ? '' : 's'} ago`;\n } else if (dayDiff === 0) {\n timeString = 'today';\n } else {\n timeString = `${dayDiff.toString()} day${dayDiff === 1 ? '' : 's'} ago`;\n }\n\n return timeString;\n }\n\n // Sorts the version history by version number\n const sortedEntries = Object.entries(versionHistory).sort((a, b) => b[0].localeCompare(a[0]));\n\n return (\n
    \n

    What`s New

    \n
      \n {(showAllVersions ? sortedEntries : sortedEntries.slice(0, 5)).map((entry) => (\n
      \n
      \n
    • \n {entry[1].description}\n
    • \n
      \n
      \n
      Version {entry[0]}
      \n
      {formatTimeString(entry[1].date)}
      \n
      \n
      \n ))}\n
    \n {sortedEntries.length > 5 && (\n setShowAllVersions(!showAllVersions)}\n className=\"tw-text-xs tw-text-gray-500 tw-underline\"\n >\n {showAllVersions ? 'Show Less Version History' : 'Show All Version History'}\n \n )}\n
    \n );\n}\n","import { useMemo } from 'react';\nimport { formatBytes } from 'platform-bible-utils';\nimport VersionHistory, { VersionHistoryType } from './version-history.component';\n\n/** Interface to store the parameters passed to the Footer component */\ninterface FooterProps {\n /** Optional unique identifier */\n id?: string;\n /** Name of the publisher */\n publisherDisplayName: string;\n /** Size of the extension file in bytes */\n fileSize: number;\n /** List of language codes supported by the extension */\n locales: string[];\n /** Object containing the version history mapped with their information */\n versionHistory: VersionHistoryType;\n}\n\n/**\n * Component to render the footer for the extension details which contains information on the\n * publisher, version history, languages, and file size.\n *\n * @param id Optional unique identifier\n * @param publisherDisplayName Name of the publisher\n * @param fileSize Size of the extension file in bytes\n * @param locales List of language codes supported by the extension\n * @param versionHistory Object containing the version history mapped with their information\n * @returns The rendered Footer component\n */\nexport default function Footer({\n id,\n publisherDisplayName,\n fileSize,\n locales,\n versionHistory,\n}: FooterProps) {\n /** Formats the file size into a human-readable format */\n const formattedFileSize = useMemo(() => formatBytes(fileSize), [fileSize]);\n\n /**\n * This function gets the display names of the languages based on the language codes.\n *\n * @param codes The list of language codes\n * @returns The list of language names\n */\n const getLanguageNames = (codes: string[]) => {\n const displayNames = new Intl.DisplayNames(navigator.language, { type: 'language' });\n return codes.map((code) => displayNames.of(code));\n };\n\n const languageNames = getLanguageNames(locales);\n\n return (\n
    \n
    \n \n
    \n
    \n

    Information

    \n
    \n

    \n Publisher\n {publisherDisplayName}\n Size\n {formattedFileSize}\n

    \n
    \n

    \n Languages\n {languageNames.join(', ')}\n

    \n
    \n
    \n
    \n
    \n
    \n );\n}\n","import { PlatformEvent, PlatformEventHandler } from 'platform-bible-utils';\nimport { useEffect } from 'react';\n\n/**\n * Adds an event handler to an event so the event handler runs when the event is emitted. Use\n * `papi.network.getNetworkEvent` to use a networked event with this hook.\n *\n * @param event The event to subscribe to.\n *\n * - If event is a `PlatformEvent`, that event will be used\n * - If event is undefined, the callback will not be subscribed. Useful if the event is not yet\n * available for example\n *\n * @param eventHandler The callback to run when the event is emitted\n *\n * WARNING: MUST BE STABLE - const or wrapped in useCallback. The reference must not be updated\n * every render\n */\nconst useEvent = (\n event: PlatformEvent | undefined,\n eventHandler: PlatformEventHandler,\n) => {\n useEffect(() => {\n // Do nothing if the event is not provided (in case the event is not yet available, for example)\n if (!event) return () => {};\n\n const unsubscriber = event(eventHandler);\n return () => {\n unsubscriber();\n };\n }, [event, eventHandler]);\n};\nexport default useEvent;\n","import { useCallback, useEffect } from 'react';\nimport { PlatformEvent, PlatformEventAsync, PlatformEventHandler } from 'platform-bible-utils';\nimport usePromise from './use-promise.hook';\n\nconst noopUnsubscriber = () => false;\n\n/**\n * Adds an event handler to an asynchronously subscribing/unsubscribing event so the event handler\n * runs when the event is emitted. Use `papi.network.getNetworkEvent` to use a networked event with\n * this hook.\n *\n * @param event The asynchronously (un)subscribing event to subscribe to.\n *\n * - If event is a `PlatformEvent` or `PlatformEventAsync`, that event will be used\n * - If event is undefined, the callback will not be subscribed. Useful if the event is not yet\n * available for example\n *\n * @param eventHandler The callback to run when the event is emitted\n *\n * WARNING: MUST BE STABLE - const or wrapped in useCallback. The reference must not be updated\n * every render\n */\nconst useEventAsync = (\n event: PlatformEvent | PlatformEventAsync | undefined,\n eventHandler: PlatformEventHandler,\n) => {\n // Subscribe to the event asynchronously\n const [unsubscribe] = usePromise(\n useCallback(async () => {\n // Do nothing if the event is not provided (in case the event is not yet available, for example)\n if (!event) return noopUnsubscriber;\n\n // Wrap subscribe and unsubscribe in promises to allow normal events to be used as well\n const unsub = await Promise.resolve(event(eventHandler));\n return async () => unsub();\n }, [eventHandler, event]),\n noopUnsubscriber,\n // We want the unsubscriber to return to default value immediately upon changing subscription\n // So the useEffect below will unsubscribe asap\n { preserveValue: false },\n );\n\n // Unsubscribe from the event asynchronously (but we aren't awaiting the unsub)\n useEffect(() => {\n return () => {\n if (unsubscribe !== noopUnsubscriber) {\n unsubscribe();\n }\n };\n }, [unsubscribe]);\n};\n\nexport default useEventAsync;\n"],"names":["twMergeCustom","extendTailwindMerge","cn","inputs","clsx","Input","React","className","type","props","ref","jsx","BookChapterInput","forwardRef","handleSearch","handleKeyDown","handleOnClick","handleSubmit","jsxs","ShadInput","event","e","History","P","R","t","s","n","N","B","O","S","K","g","k","x","T","X","V","w","L","G","A","H","C","I","y","q","U","m","l","h","c","E","D","i","a","o","u","v","f","d","b","p","J","DropdownMenu","DropdownMenuPrimitive","DropdownMenuTrigger","DropdownMenuGroup","DropdownMenuPortal","DropdownMenuSub","DropdownMenuRadioGroup","DropdownMenuSubTrigger","inset","children","ChevronRight","DropdownMenuSubContent","DropdownMenuContent","sideOffset","DropdownMenuItem","DropdownMenuCheckboxItem","checked","Check","DropdownMenuRadioItem","Circle","DropdownMenuLabel","DropdownMenuSeparator","DropdownMenuShortcut","BookMenuItem","bookId","handleSelectBook","isSelected","handleHighlightBook","bookType","ShadDropdownMenuItem","Canon","ChapterSelect","handleSelectChapter","endChapter","activeChapter","highlightedChapter","handleHighlightedChapter","chapters","_","handleMouse","useCallback","chapterNumber","chapter","GoToMenuItem","handleSort","handleLocationHistory","handleBookmarks","ShadDropdownMenuLabel","ArrowDownWideNarrow","Clock","Bookmark","ALL_BOOK_IDS","BOOK_TYPE_LABELS","BOOK_TYPE_ARRAY","SCROLL_OFFSET","SEARCH_QUERY_FORMATS","fetchGroupedBooks","fetchEndChapter","getChaptersForBook","getAllEnglishNames","isValidBookEnglishName","bookName","getBookIdFromEnglishName","formattedBookName","BookChapterControl","scrRef","searchQuery","setSearchQuery","useState","selectedBookId","setSelectedBookId","setHighlightedChapter","highlightedBookId","setHighlightedBookId","isContentOpen","setIsContentOpen","isContentOpenDelayed","setIsContentOpenDelayed","inputRef","useRef","contentRef","menuItemRef","fetchFilteredBooks","englishNameLowerCase","normalizedQuery","handleSearchInput","searchString","shouldPreventAutoClosing","controlMenuState","open","updateReference","shouldClose","verse","handleInputSubmit","format","matches","book","englishName","handleKeyDownInput","handleKeyDownContent","key","handleKeyDownMenuItem","chapterOffSet","useEffect","useLayoutEffect","scrollTimeout","scrollPosition","ShadDropdownMenu","ShadDropdownMenuTrigger","ShadDropdownMenuContent","bookTypeIndex","element","ShadDropdownMenuSeparator","buttonVariants","cva","Button","variant","size","asChild","Comp","Slot","labelVariants","Label","LabelPrimitive","RadioGroup","RadioGroupPrimitive","RadioGroupItem","Popover","PopoverPrimitive","PopoverTrigger","PopoverContent","align","DialogPortal","DialogPrimitive","DialogOverlay","DialogContent","DialogTitle","DialogDescription","Command","CommandPrimitive","CommandInput","Search","CommandList","CommandEmpty","CommandGroup","CommandSeparator","CommandItem","getOptionLabelDefault","option","ComboBox","id","options","buttonClassName","popoverContentClassName","value","onChange","getOptionLabel","buttonPlaceholder","textPlaceholder","commandEmptyMessage","buttonVariant","dir","isDisabled","setOpen","ChevronsUpDown","ChapterRangeSelector","startChapter","handleSelectStartChapter","handleSelectEndChapter","chapterCount","chapterOptions","useMemo","index","onChangeStartChapter","onChangeEndChapter","Fragment","BookSelectionMode","BOOK_SELECTOR_STRING_KEYS","localizeString","strings","BookSelector","handleBookSelectionModeChange","currentBookName","onSelectBooks","selectedBookIds","localizedStrings","currentBookText","chooseText","chooseBooksText","bookSelectionMode","setBookSelectionMode","onSelectionModeChange","newMode","DataTableViewOptions","table","FilterIcon","column","Select","SelectPrimitive","SelectGroup","SelectValue","SelectTrigger","ChevronDown","SelectScrollUpButton","ChevronUp","SelectScrollDownButton","SelectContent","position","SelectLabel","SelectItem","SelectSeparator","DataTablePagination","pageSize","ArrowLeftIcon","ChevronLeftIcon","ChevronRightIcon","ArrowRightIcon","Table","stickyHeader","TableHeader","TableBody","TableFooter","TableRow","TableHead","TableCell","TableCaption","DataTable","columns","data","enablePagination","showPaginationControls","showColumnVisibilityControls","onRowClickHandler","sorting","setSorting","columnFilters","setColumnFilters","columnVisibility","setColumnVisibility","rowSelection","setRowSelection","useReactTable","getCoreRowModel","getPaginationRowModel","getSortedRowModel","getFilteredRowModel","headerGroup","header","flexRender","_a","row","cell","OccurrencesTable","occurrenceData","setScriptureReference","referenceHeaderText","occurrenceHeaderText","occurrences","uniqueOccurrences","occurrence","uniqueOccurrence","deepEqual","Checkbox","CheckboxPrimitive","getLinesFromUSFM","text","getNumberFromUSFM","regex","match","getBookNumFromId","getStatusForItem","item","approvedItems","unapprovedItems","toggleVariants","Toggle","TogglePrimitive","ToggleGroupContext","ToggleGroup","ToggleGroupPrimitive","ToggleGroupItem","context","getSortingIcon","sortDirection","ArrowUpIcon","ArrowDownIcon","ArrowUpDownIcon","inventoryItemColumn","itemLabel","inventoryAdditionalItemColumn","additionalItemLabel","additionalItemIndex","inventoryCountColumn","countLabel","statusChangeHandler","changedItems","newStatus","onApprovedItemsChange","onUnapprovedItemsChange","newApprovedItems","validItem","newUnapprovedItems","unapprovedItem","inventoryStatusColumn","statusLabel","status","CircleCheckIcon","CircleXIcon","CircleHelpIcon","INVENTORY_STRING_KEYS","filterItemData","itemData","statusFilter","textFilter","filteredItemData","createTableData","scriptureRef","itemRegex","tableData","currentBook","currentChapter","currentVerse","line","items","itemIndex","existingItem","tableEntry","newReference","substring","newItem","Inventory","scriptureReference","extractItems","additionalItemsLabels","scope","onScopeChange","allItemsText","approvedItemsText","unapprovedItemsText","unknownItemsText","scopeBookText","scopeChapterText","scopeVerseText","filterText","showAdditionalItemsText","showAdditionalItems","setShowAdditionalItems","setStatusFilter","setTextFilter","selectedItem","setSelectedItem","reducedTableData","newTableData","firstItem","existingEntry","newTableEntry","filteredTableData","allColumns","numberOfAdditionalItems","additionalColumns","_b","rowClickHandler","newSelection","handleScopeChange","handleStatusFilterChange","SearchBar","onSearch","placeholder","isFullWidth","handleInputChange","VerticalTabs","TabsPrimitive","VerticalTabsList","VerticalTabsTrigger","VerticalTabsContent","TabNavigationContentSearch","tabList","searchPlaceholder","headerTitle","isSearchBarFullWidth","direction","tab","Separator","orientation","decorative","SeparatorPrimitive","Sheet","SheetPrimitive","SheetPortal","SheetOverlay","sheetVariants","SheetContent","side","SheetTitle","SheetDescription","Skeleton","TooltipProvider","TooltipPrimitive","Tooltip","TooltipTrigger","TooltipContent","MOBILE_BREAKPOINT","useIsMobile","isMobile","setIsMobile","mql","SIDEBAR_COOKIE_NAME","SIDEBAR_COOKIE_MAX_AGE","SIDEBAR_WIDTH","SIDEBAR_WIDTH_MOBILE","SIDEBAR_WIDTH_ICON","SIDEBAR_KEYBOARD_SHORTCUT","SidebarContext","useSidebar","SidebarProvider","defaultOpen","openProp","setOpenProp","style","openMobile","setOpenMobile","_open","_setOpen","isOpen","openState","toggleSidebar","state","contextValue","Sidebar","collapsible","SidebarTrigger","onClick","PanelLeft","SidebarRail","SidebarInset","SidebarInput","SidebarHeader","SidebarFooter","SidebarSeparator","SidebarContent","SidebarGroup","SidebarGroupLabel","SidebarGroupAction","SidebarGroupContent","SidebarMenu","SidebarMenuItem","sidebarMenuButtonVariants","SidebarMenuButton","isActive","tooltip","button","SidebarMenuAction","showOnHover","SidebarMenuBadge","SidebarMenuSkeleton","showIcon","width","SidebarMenuSub","SidebarMenuSubItem","SidebarMenuSubButton","SettingsSidebar","extensionLabels","projectOptions","handleSelectSidebarItem","selectedSidebarItem","extensionsSidebarGroupLabel","projectsSidebarGroupLabel","handleSelectItem","projectId","getProjectNameFromProjectId","project","getIsActive","label","selectedProjectName","SettingsSidebarContentSearch","scrBookColId","scrRefColId","typeColId","detailsColId","defaultScrRefColumnName","defaultScrBookGroupName","defaultTypeColumnName","defaultDetailsColumnName","getColumns","colInfo","showSourceColumn","showSrcCol","info","formatScrRef","compareScrRefs","toRefOrRange","scriptureSelection","offsetStart","offsetEnd","scrRefToBBBCCCVVV","getRowKey","ScriptureResultsViewer","sources","showColumnHeaders","scriptureReferenceColumnName","scriptureBookGroupName","typeColumnName","detailsColumnName","onRowSelected","grouping","setGrouping","scriptureResults","source","getExpandedRowModel","getGroupedRowModel","selectedRows","keys","selectedRow","scrBookGroupName","typeGroupName","groupingOptions","handleSelectChange","selectedGrouping","handleRowClick","getEvenOrOddBandingStyle","getIndent","groupingState","rowIndex","ChevronLeft","DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS","getLocalizeKeyForScrollGroupId","ScrollGroupSelector","availableScrollGroupIds","scrollGroupId","onChangeScrollGroupId","localizedStringsDefaulted","localizedStringKey","localizedStringValue","newScrollGroupString","scrollGroupOptionId","SettingsList","SettingsListItem","primary","secondary","isLoading","loadingMessage","SettingsListHeader","includeSeparator","Checklist","listItems","selectedListItems","handleSelectListItem","createLabel","_interopRequireDefault","obj","module","chainPropTypes","propType1","propType2","args","_extends","target","isPlainObject","prototype","deepClone","output","deepmerge","r","z","reactIs_production_min","hasSymbol","REACT_ELEMENT_TYPE","REACT_PORTAL_TYPE","REACT_FRAGMENT_TYPE","REACT_STRICT_MODE_TYPE","REACT_PROFILER_TYPE","REACT_PROVIDER_TYPE","REACT_CONTEXT_TYPE","REACT_ASYNC_MODE_TYPE","REACT_CONCURRENT_MODE_TYPE","REACT_FORWARD_REF_TYPE","REACT_SUSPENSE_TYPE","REACT_SUSPENSE_LIST_TYPE","REACT_MEMO_TYPE","REACT_LAZY_TYPE","REACT_BLOCK_TYPE","REACT_FUNDAMENTAL_TYPE","REACT_RESPONDER_TYPE","REACT_SCOPE_TYPE","isValidElementType","typeOf","object","$$typeof","$$typeofType","AsyncMode","ConcurrentMode","ContextConsumer","ContextProvider","Element","ForwardRef","Lazy","Memo","Portal","Profiler","StrictMode","Suspense","hasWarnedAboutDeprecatedIsAsyncMode","isAsyncMode","isConcurrentMode","isContextConsumer","isContextProvider","isElement","isForwardRef","isFragment","isLazy","isMemo","isPortal","isProfiler","isStrictMode","isSuspense","reactIs_development","reactIsModule","require$$0","require$$1","getOwnPropertySymbols","hasOwnProperty","propIsEnumerable","toObject","val","shouldUseNative","test1","test2","order2","test3","letter","objectAssign","from","to","symbols","ReactPropTypesSecret","ReactPropTypesSecret_1","has","printWarning","loggedTypeFailures","message","checkPropTypes","typeSpecs","values","location","componentName","getStack","typeSpecName","error","err","ex","stack","checkPropTypes_1","ReactIs","assign","require$$2","require$$3","require$$4","emptyFunctionThatReturnsNull","factoryWithTypeCheckers","isValidElement","throwOnDirectAccess","ITERATOR_SYMBOL","FAUX_ITERATOR_SYMBOL","getIteratorFn","maybeIterable","iteratorFn","ANONYMOUS","ReactPropTypes","createPrimitiveTypeChecker","createAnyTypeChecker","createArrayOfTypeChecker","createElementTypeChecker","createElementTypeTypeChecker","createInstanceTypeChecker","createNodeChecker","createObjectOfTypeChecker","createEnumTypeChecker","createUnionTypeChecker","createShapeTypeChecker","createStrictShapeTypeChecker","is","PropTypeError","createChainableTypeChecker","validate","manualPropTypeCallCache","manualPropTypeWarningCount","checkType","isRequired","propName","propFullName","secret","cacheKey","chainedCheckType","expectedType","propValue","propType","getPropType","preciseType","getPreciseType","typeChecker","expectedClass","expectedClassName","actualClassName","getClassName","expectedValues","valuesString","arrayOfTypeCheckers","checker","getPostfixForTypeWarning","expectedTypes","checkerResult","expectedTypesMessage","isNode","invalidValidatorError","shapeTypes","allKeys","iterator","step","entry","isSymbol","emptyFunction","emptyFunctionWithReset","factoryWithThrowingShims","shim","getShim","propTypesModule","isClassComponent","elementType","acceptingRef","safePropName","warningHint","elementAcceptingRef","PropTypes","elementAcceptingRef$1","specialProperty","exactProp","propTypes","unsupportedProps","prop","formatMuiErrorMessage","code","url","REACT_SERVER_CONTEXT_TYPE","REACT_OFFSCREEN_TYPE","enableScopeAPI","enableCacheElement","enableTransitionTracing","enableLegacyHidden","enableDebugTracing","REACT_MODULE_REFERENCE","SuspenseList","hasWarnedAboutDeprecatedIsConcurrentMode","isSuspenseList","fnNameMatchRegex","getFunctionName","fn","getFunctionComponentName","Component","fallback","getWrappedName","outerType","innerType","wrapperName","functionName","getDisplayName","HTMLElementType","refType","refType$1","capitalize","string","_formatMuiErrorMessage","createChainedFunction","funcs","acc","func","debounce","wait","timeout","debounced","later","deprecatedPropType","validator","reason","componentNameSafe","propFullNameSafe","isMuiElement","muiNames","_muiName","_element$type","ownerDocument","node","ownerWindow","requirePropFactory","componentNameInError","prevPropTypes","requiredProp","defaultTypeChecker","typeCheckerResult","setRef","useEnhancedEffect","useEnhancedEffect$1","globalId","useGlobalId","idOverride","defaultId","setDefaultId","maybeReactUseId","useId","reactId","unsupportedProp","useControlled","controlled","defaultProp","name","isControlled","valueState","setValue","defaultValue","setValueIfUncontrolled","newValue","useEventCallback","useForkRef","refs","instance","UNINITIALIZED","useLazyRef","init","initArg","EMPTY","useOnMount","Timeout","delay","useTimeout","hadKeyboardEvent","hadFocusVisibleRecently","hadFocusVisibleRecentlyTimeout","inputTypesWhitelist","focusTriggersKeyboardModality","tagName","handlePointerDown","handleVisibilityChange","prepare","doc","isFocusVisible","useIsFocusVisible","isFocusVisibleRef","handleBlurVisible","handleFocusVisible","resolveProps","defaultProps","defaultSlotProps","slotProps","slotPropName","composeClasses","slots","getUtilityClass","classes","slot","utilityClass","defaultGenerator","createClassNameGenerator","generate","generator","ClassNameGenerator","ClassNameGenerator$1","globalStateClasses","generateUtilityClass","globalStatePrefix","globalStateClass","generateUtilityClasses","result","clamp","min","max","_objectWithoutPropertiesLoose","excluded","sourceKeys","_excluded","sortBreakpointsValues","breakpointsAsArray","breakpoint1","breakpoint2","createBreakpoints","breakpoints","unit","other","sortedValues","up","down","between","start","end","endIndex","only","not","keyIndex","shape","shape$1","responsivePropType","responsivePropType$1","merge","defaultBreakpoints","handleBreakpoints","styleFromPropValue","theme","themeBreakpoints","breakpoint","mediaKey","cssKey","createEmptyBreakpointObject","breakpointsInput","_breakpointsInput$key","breakpointStyleKey","removeUnusedBreakpoints","breakpointKeys","breakpointOutput","getPath","path","checkVars","getStyleValue","themeMapping","transform","propValueFinal","userValue","cssProperty","themeKey","memoize","cache","arg","properties","directions","aliases","getCssProperties","property","marginKeys","paddingKeys","spacingKeys","createUnaryUnit","_getPath","themeSpacing","abs","createUnarySpacing","getValue","transformer","transformed","getStyleFromPropValue","cssProperties","resolveCssProperty","margin","padding","createSpacing","spacingInput","spacing","argsInput","argument","compose","styles","handlers","borderTransform","createBorderStyle","border","borderTop","borderRight","borderBottom","borderLeft","borderColor","borderTopColor","borderRightColor","borderBottomColor","borderLeftColor","outline","outlineColor","borderRadius","gap","columnGap","rowGap","gridColumn","gridRow","gridAutoFlow","gridAutoColumns","gridAutoRows","gridTemplateColumns","gridTemplateRows","gridTemplateAreas","gridArea","paletteTransform","color","bgcolor","backgroundColor","sizingTransform","maxWidth","_props$theme","_props$theme2","breakpointsValues","minWidth","height","maxHeight","minHeight","boxSizing","defaultSxConfig","defaultSxConfig$1","objectsHaveSameKeys","objects","union","callIfFn","maybeFn","unstable_createStyleFunctionSx","getThemeValue","config","styleFunctionSx","_theme$unstable_sxCon","sx","traverse","sxInput","sxObject","emptyBreakpoints","breakpointsKeys","css","styleKey","styleFunctionSx$1","applyStyles","createTheme","paletteInput","shapeInput","muiTheme","isObjectEmpty","useTheme","defaultTheme","contextTheme","ThemeContext","systemDefaultTheme","useThemeWithoutDefault","_excluded2","_excluded3","isEmpty","isStringTag","tag","shouldForwardProp","lowercaseFirstLetter","resolveTheme","themeId","defaultOverridesResolver","processStyleArg","callableStyle","_ref","ownerState","resolvedStylesArg","resolvedStyle","variants","isMatch","createStyled","input","rootShouldForwardProp","slotShouldForwardProp","systemSx","inputOptions","processStyles","componentSlot","inputSkipVariantsResolver","inputSkipSx","overridesResolver","skipVariantsResolver","skipSx","shouldForwardPropOption","defaultStyledResolver","styledEngineStyled","transformStyleArg","stylesArg","muiStyledResolver","styleArg","expressions","transformedStyleArg","expressionsWithDefaultTheme","styleOverrides","resolvedStyleOverrides","slotKey","slotStyle","_theme$components","themeVariants","numOfCustomFnsApplied","placeholders","displayName","getThemeProps","params","useThemeProps","clampWrapper","hexToRgb","re","colors","decomposeColor","marker","colorSpace","recomposeColor","hslToRgb","rgb","getLuminance","getContrastRatio","foreground","background","lumA","lumB","alpha","darken","coefficient","lighten","createMixins","mixins","common","common$1","grey","grey$1","purple","purple$1","red","red$1","orange","orange$1","blue","blue$1","lightBlue","lightBlue$1","green","green$1","light","dark","addLightOrDark","intent","shade","tonalOffset","tonalOffsetLight","tonalOffsetDark","getDefaultPrimary","mode","getDefaultSecondary","getDefaultError","getDefaultInfo","getDefaultSuccess","getDefaultWarning","createPalette","palette","contrastThreshold","success","warning","getContrastText","contrastText","contrast","augmentColor","mainShade","lightShade","darkShade","modes","round","caseAllCaps","defaultFontFamily","createTypography","typography","fontFamily","fontSize","fontWeightLight","fontWeightRegular","fontWeightMedium","fontWeightBold","htmlFontSize","allVariants","pxToRem2","coef","pxToRem","buildVariant","fontWeight","lineHeight","letterSpacing","casing","shadowKeyUmbraOpacity","shadowKeyPenumbraOpacity","shadowAmbientShadowOpacity","createShadow","px","shadows","shadows$1","easing","duration","formatMs","milliseconds","getAutoHeightDuration","constant","createTransitions","inputTransitions","mergedEasing","mergedDuration","durationOption","easingOption","isString","isNumber","animatedProp","zIndex","zIndex$1","mixinsInput","transitionsInput","typographyInput","systemTheme","systemCreateTheme","stateClasses","component","child","stateClass","defaultTheme$1","THEME_ID","systemUseThemeProps","styled","styled$1","getSvgIconUtilityClass","useUtilityClasses","SvgIconRoot","_theme$transitions","_theme$transitions$cr","_theme$transitions2","_theme$typography","_theme$typography$pxT","_theme$typography2","_theme$typography2$px","_theme$typography3","_theme$typography3$px","_palette$ownerState$c","_palette","_palette2","_palette3","SvgIcon","inProps","htmlColor","inheritViewBox","titleAccess","viewBox","hasSvgAsChild","more","_jsxs","_jsx","SvgIcon$1","createSvgIcon","unstable_ClassNameGenerator","exports","_utils","ArrowRight","default_1","_createSvgIcon","_jsxRuntime","isHostComponent","appendOwnerState","otherProps","defaultContextValue","ClassNameConfiguratorContext","useClassNamesOverride","disableDefaultClasses","extractEventHandlers","excludeKeys","resolveComponentProps","componentProps","slotState","omitEventHandlers","mergeSlotProps","parameters","getSlotProps","additionalProps","externalSlotProps","externalForwardedProps","joinedClasses","mergedStyle","eventHandlers","componentsPropsWithoutEventHandlers","otherPropsWithoutEventHandlers","internalSlotProps","useSlotProps","_parameters$additiona","skipResolvingSlotProps","rest","resolvedComponentsProps","mergedProps","internalRef","GLOBAL_CLASS_PREFIX","buildStateClass","buildSlotClass","getContainer","container","forwardedRef","disablePortal","mountNode","setMountNode","handleRef","newProps","ReactDOM","top","bottom","right","left","auto","basePlacements","clippingParents","viewport","popper","reference","variationPlacements","placement","placements","beforeRead","read","afterRead","beforeMain","main","afterMain","beforeWrite","write","afterWrite","modifierPhases","getNodeName","getWindow","OwnElement","isHTMLElement","isShadowRoot","attributes","effect","_ref2","initialStyles","styleProperties","attribute","applyStyles$1","getBasePlacement","getUAString","uaData","isLayoutViewport","getBoundingClientRect","includeScale","isFixedStrategy","clientRect","scaleX","scaleY","visualViewport","addVisualOffsets","getLayoutRect","contains","parent","rootNode","next","getComputedStyle","isTableElement","getDocumentElement","getParentNode","getTrueOffsetParent","getContainingBlock","isFirefox","isIE","elementCss","currentNode","getOffsetParent","window","offsetParent","getMainAxisFromPlacement","within","mathMax","mathMin","withinMaxClamp","getFreshSideObject","mergePaddingObject","paddingObject","expandToHashMap","hashMap","toPaddingObject","arrow","_state$modifiersData$","arrowElement","popperOffsets","basePlacement","axis","isVertical","len","arrowRect","minProp","maxProp","endDiff","startDiff","arrowOffsetParent","clientSize","centerToReference","center","offset","axisProp","_options$element","arrow$1","getVariation","unsetSides","roundOffsetsByDPR","win","dpr","mapToStyles","_Object$assign2","popperRect","variation","offsets","gpuAcceleration","adaptive","roundOffsets","isFixed","_offsets$x","_offsets$y","_ref3","hasX","hasY","sideX","sideY","heightProp","widthProp","offsetY","offsetX","commonStyles","_ref4","_Object$assign","computeStyles","_ref5","_options$gpuAccelerat","_options$adaptive","_options$roundOffsets","computeStyles$1","passive","_options$scroll","scroll","_options$resize","resize","scrollParents","scrollParent","eventListeners","hash","getOppositePlacement","matched","getOppositeVariationPlacement","getWindowScroll","scrollLeft","scrollTop","getWindowScrollBarX","getViewportRect","strategy","html","layoutViewport","getDocumentRect","_element$ownerDocumen","winScroll","body","isScrollParent","_getComputedStyle","overflow","overflowX","overflowY","getScrollParent","listScrollParents","list","isBody","updatedList","rectToClientRect","rect","getInnerBoundingClientRect","getClientRectFromMixedType","clippingParent","getClippingParents","canEscapeClipping","clipperElement","getClippingRect","boundary","rootBoundary","mainClippingParents","firstClippingParent","clippingRect","accRect","computeOffsets","commonX","commonY","mainAxis","detectOverflow","_options","_options$placement","_options$strategy","_options$boundary","_options$rootBoundary","_options$elementConte","elementContext","_options$altBoundary","altBoundary","_options$padding","altContext","clippingClientRect","referenceClientRect","popperClientRect","elementClientRect","overflowOffsets","offsetData","multiply","computeAutoPlacement","flipVariations","_options$allowedAutoP","allowedAutoPlacements","allPlacements","allowedPlacements","overflows","getExpandedFallbackPlacements","oppositePlacement","flip","_options$mainAxis","checkMainAxis","_options$altAxis","checkAltAxis","specifiedFallbackPlacements","_options$flipVariatio","preferredPlacement","isBasePlacement","fallbackPlacements","referenceRect","checksMap","makeFallbackChecks","firstFittingPlacement","_basePlacement","isStartVariation","mainVariationSide","altVariationSide","checks","check","numberOfChecks","_loop","_i","fittingPlacement","_ret","flip$1","getSideOffsets","preventedOffsets","isAnySideFullyClipped","hide","referenceOverflow","popperAltOverflow","referenceClippingOffsets","popperEscapeOffsets","isReferenceHidden","hasPopperEscaped","hide$1","distanceAndSkiddingToXY","rects","invertDistance","skidding","distance","_options$offset","_data$state$placement","offset$1","popperOffsets$1","getAltAxis","preventOverflow","_options$tether","tether","_options$tetherOffset","tetherOffset","altAxis","tetherOffsetValue","normalizedTetherOffsetValue","offsetModifierState","_offsetModifierState$","mainSide","altSide","additive","minLen","maxLen","arrowPaddingObject","arrowPaddingMin","arrowPaddingMax","arrowLen","minOffset","maxOffset","clientOffset","offsetModifierValue","tetherMin","tetherMax","preventedOffset","_offsetModifierState$2","_mainSide","_altSide","_offset","_len","_min","_max","isOriginSide","_offsetModifierValue","_tetherMin","_tetherMax","_preventedOffset","preventOverflow$1","getHTMLElementScroll","getNodeScroll","isElementScaled","getCompositeRect","elementOrVirtualElement","isOffsetParentAnElement","offsetParentIsScaled","documentElement","order","modifiers","map","visited","modifier","sort","requires","dep","depModifier","orderModifiers","orderedModifiers","phase","pending","resolve","mergeByName","merged","current","existing","DEFAULT_OPTIONS","areValidElements","_key","popperGenerator","generatorOptions","_generatorOptions","_generatorOptions$def","defaultModifiers","_generatorOptions$def2","defaultOptions","effectCleanupFns","isDestroyed","setOptionsAction","cleanupModifierEffects","runModifierEffects","_state$elements","_state$orderedModifie","_state$orderedModifie2","_ref$options","cleanupFn","noopFn","createPopper","COMPONENT_NAME","getPopperUtilityClass","flipPlacement","resolveAnchorEl","anchorEl","isVirtualElement","defaultPopperOptions","PopperTooltip","_slots$root","initialPlacement","popperOptions","popperRefProp","TransitionProps","tooltipRef","ownRef","popperRef","handlePopperRef","handlePopperRefRef","rtlPlacement","setPlacement","resolvedAnchorElement","setResolvedAnchorElement","handlePopperUpdate","box","popperModifiers","childProps","Root","rootProps","Popper","containerProp","keepMounted","transition","exited","setExited","handleEnter","handleExited","resolvedAnchorEl","display","transitionProps","useThemeSystem","_setPrototypeOf","_inheritsLoose","subClass","superClass","setPrototypeOf","timeoutsShape","TransitionGroupContext","forceReflow","UNMOUNTED","EXITED","ENTERING","ENTERED","EXITING","Transition","_React$Component","_this","parentGroup","appear","initialStatus","prevState","nextIn","_proto","prevProps","nextStatus","exit","enter","mounting","_this2","appearing","maybeNode","maybeAppearing","timeouts","enterTimeout","_this3","nextState","callback","_this4","active","handler","doesNotHaveTimeoutOrListener","maybeNextCallback","_this$props","pt","noop","Transition$1","reflow","getTransitionProps","_style$transitionDura","_style$transitionTimi","getScale","isWebKit154","Grow","addEndListener","inProp","onEnter","onEntered","onEntering","onExit","onExited","onExiting","TransitionComponent","timer","autoTimeout","nodeRef","normalizedTransitionCallback","maybeIsAppearing","handleEntering","isAppearing","transitionDuration","transitionTimingFunction","handleEntered","handleExiting","handleExit","handleAddEndListener","Grow$1","PopperRoot","BasePopper","components","componentsProps","RootComponent","Popper$1","getTooltipUtilityClass","tooltipClasses","tooltipClasses$1","disableInteractive","touch","TooltipPopper","TooltipTooltip","TooltipArrow","hystersisOpen","hystersisTimer","cursorPosition","composeEventHandler","eventHandler","_slots$popper","_slots$transition","_slots$tooltip","_slots$arrow","_slotProps$popper","_ref6","_slotProps$popper2","_slotProps$transition","_slotProps$tooltip","_ref7","_slotProps$tooltip2","_slotProps$arrow","_ref8","_slotProps$arrow2","childrenProp","describeChild","disableFocusListener","disableHoverListener","disableInteractiveProp","disableTouchListener","enterDelay","enterNextDelay","enterTouchDelay","followCursor","idProp","leaveDelay","leaveTouchDelay","onClose","onOpen","PopperComponentProp","PopperProps","title","TransitionComponentProp","isRtl","childNode","setChildNode","arrowRef","setArrowRef","ignoreNonTouchEvents","closeTimer","enterTimer","leaveTimer","touchTimer","setOpenState","prevUserSelect","stopTouchInteraction","handleOpen","handleClose","handleLeave","focusVisibleRef","setChildIsFocusVisible","handleBlur","handleFocus","detectTouchStart","childrenProps","handleMouseOver","handleMouseLeave","handleTouchStart","handleTouchEnd","nativeEvent","handleMouseMove","nameOrDescProps","titleIsString","interactiveWrapperListeners","_PopperProps$popperOp","tooltipModifiers","PopperComponent","TooltipComponent","ArrowComponent","popperProps","tooltipProps","tooltipArrowProps","TransitionPropsInner","Tooltip$1","getIcon","icon","menuLabel","leading","MuiListItemIcon","MenuItem","allowForLeadingIcons","iconPathBefore","iconPathAfter","hasAutoFocus","isDense","isSubMenuParent","hasDisabledGutters","hasDivider","focusVisibleClassName","menuItem","MuiMenuItem","MuiListItemText","getAllGroups","menuDefinition","SubMenu","setAnchorEl","parentMenuItem","parentItemProps","handleParentMenuItemClick","renderSubMenuItems","includedGroups","group","GroupedMenuItemList","Menu","getOrderedGroupItems","groupId","allItems","menuProps","commandHandler","groupsToInclude","sortedGroups","itemArray","allowSpaceForLeadingIcons","createMenuItemProps","isLastItemInGroup","divKey","itemInfo","menuItemProps","TopLevelMenu","columnId","MenuColumn","metadata","Grid","List","GridMenu","multiColumnMenu","sortedColumns","columnNumbers","columnName","col","getUsePromiseOptionsDefaults","usePromise","promiseFactoryCallback","defaultValueRef","optionsDefaultedRef","setIsLoading","promiseIsCurrent","MenuIcon","HamburgerMenuButton","menuProvider","normalMenu","fullMenu","containerRef","ariaLabelPrefix","isMenuOpen","setMenuOpen","showFullMenu","setShowFullMenu","handleMenuItemClick","handleMenuButtonClick","prevIsOpen","isOpening","menuCommandHandler","command","setOffset","normalMenuData","fullMenuData","menu","IconButton","Drawer","isTooltipSuppressed","adjustMarginToAlignToEdge","MuiIconButton","Spinner","LoaderCircle","TextField","hasError","helperText","onFocus","onBlur","ShadLabel","Toolbar","AppBar","MuiToolbar","alertVariants","Alert","AlertTitle","AlertDescription","Card","CardHeader","CardTitle","CardDescription","CardContent","CardFooter","Sonner","Toaster","Slider","SliderPrimitive","Switch","SwitchPrimitives","Tabs","TabsList","TabsTrigger","TabsContent","InstallButton","isInstalling","handleClick","buttonText","Download","EnableButton","isEnabling","DisableButton","isDisabling","UpdateButton","isUpdating","MarkdownRenderer","markdown","anchorTarget","Markdown","FilterButton","Filter","DropdownMenuItemType","DropdownMenuItemType2","FilterDropdown","groups","NoExtensionsFound","MoreInfo","category","downloads","languages","moreInfoUrl","numberFormatted","NumberFormat","handleScrollToBottom","User","locale","LucideLink","CircleHelp","VersionHistory","versionHistory","showAllVersions","setShowAllVersions","currentDate","formatTimeString","dateString","date","dateDiff","yearDiff","monthDiff","dayDiff","timeString","sortedEntries","Footer","publisherDisplayName","fileSize","locales","formattedFileSize","formatBytes","languageNames","codes","displayNames","useEvent","unsubscriber","noopUnsubscriber","useEventAsync","unsubscribe","unsub"],"mappings":"28CAGA,MAAMA,GAAgBC,GAAAA,oBAAoB,CAAE,OAAQ,KAAO,CAAA,EAyDpD,SAASC,KAAMC,EAAsB,CACnC,OAAAH,GAAcI,GAAAA,KAAKD,CAAM,CAAC,CACnC,CCzDO,MAAME,GAAQC,EAAM,WACzB,CAAC,CAAE,UAAAC,EAAW,KAAAC,EAAM,GAAGC,CAAA,EAASC,IAE5BC,EAAA,IAAC,QAAA,CACC,KAAAH,EACA,UAAWN,EACT,sbACAK,CACF,EACA,IAAAG,EAEC,GAAGD,CAAA,CAAA,CAIZ,EACAJ,GAAM,YAAc,QCNpB,MAAMO,GAAmBC,EAAA,WACvB,CACE,CAAE,aAAAC,EAAc,cAAAC,EAAe,cAAAC,EAAe,aAAAC,EAAc,GAAGR,CAAM,EACrEC,IAGEQ,EAAA,KAAC,MAAI,CAAA,UAAU,cACb,SAAA,CAAAP,EAAA,IAACQ,GAAA,CACE,GAAGV,EACJ,KAAK,OACL,UAAU,0JACV,SAAWW,GAAUN,EAAaM,EAAM,OAAO,KAAK,EACpD,UAAYC,GAAM,CACZA,EAAE,MAAQ,SACCJ,IAEfF,EAAcM,CAAC,CACjB,EACA,QAASL,EACT,IAAAN,CAAA,CACF,EACAC,EAAA,IAACW,EAAA,QAAA,CACC,UAAU,8HACV,QAAS,IAAM,CAEb,QAAQ,IAAI,iBAAiB,CAC/B,CAAA,CACF,CACF,CAAA,CAAA,CAGN,EC9CA,IAAIC,GAAI,OAAO,eACXC,GAAI,CAACC,EAAGJ,EAAGK,IAAML,KAAKI,EAAIF,GAAEE,EAAGJ,EAAG,CAAE,WAAY,GAAI,aAAc,GAAI,SAAU,GAAI,MAAOK,CAAC,CAAE,EAAID,EAAEJ,CAAC,EAAIK,EACzGC,GAAI,CAACF,EAAGJ,EAAGK,IAAMF,GAAEC,EAAG,OAAOJ,GAAK,SAAWA,EAAI,GAAKA,EAAGK,CAAC,EAW9D,MAAME,GAAI,CACR,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MAEA,MAEA,MAEA,MAEA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,MAEA,MAEA,MAEA,MAEA,MACA,MACA,MACA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,KACF,EAAGC,GAAI,CACL,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,KACF,EAAGC,GAAI,CACL,UACA,SACA,YACA,UACA,cACA,SACA,SACA,OACA,WACA,WACA,UACA,UACA,eACA,eACA,OACA,WACA,kBACA,MACA,SACA,WACA,eACA,gBACA,SACA,WACA,eACA,UACA,kBACA,QACA,OACA,OACA,UACA,QACA,QACA,QACA,WACA,YACA,SACA,YACA,UACA,UACA,OACA,OACA,OACA,OACA,SACA,gBACA,gBACA,YACA,YACA,cACA,aACA,kBACA,kBACA,YACA,YACA,QACA,WACA,UACA,QACA,UACA,UACA,SACA,SACA,SACA,OACA,aACA,QACA,SACA,eACA,oBACA,0BACA,SACA,qBACA,sBACA,UACA,qBACA,cACA,cACA,cACA,cACA,mBACA,mBACA,qBACA,YACA,OACA,oBAGA,uBACA,uBACA,sBACA,yBACA,wBACA,qBACA,UACA,UACA,UACA,UACA,UACA,UACA,UACA,eACA,cACA,eACA,oBACA,qBACA,0BACA,0BACA,eACA,eACA,YACA,gBACA,cACA,eACA,iBACA,wBACA,mBACA,WACA,QACA,aACA,aACA,aACA,2BACA,4BACA,YACF,EAAGC,GAAIC,KACP,SAASC,GAAER,EAAGJ,EAAI,GAAI,CACpB,OAAOA,IAAMI,EAAIA,EAAE,YAAa,GAAGA,KAAKM,GAAIA,GAAEN,CAAC,EAAI,CACrD,CACA,SAASS,GAAET,EAAG,CACZ,OAAOQ,GAAER,CAAC,EAAI,CAChB,CACA,SAASU,GAAEV,EAAG,CACZ,MAAMJ,EAAI,OAAOI,GAAK,SAAWQ,GAAER,CAAC,EAAIA,EACxC,OAAOJ,GAAK,IAAMA,GAAK,EACzB,CACA,SAASe,GAAEX,EAAG,CACZ,OAAQ,OAAOA,GAAK,SAAWQ,GAAER,C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V,UAAWa,EACZ,EACD,QAAS,CACP,SAAU,UACV,YAAa,kBACb,UAAWA,EACZ,EACD,gBAAiB,CACf,SAAU,UACV,UAAWA,EACZ,EAED,EAAG,CACD,MAAOpC,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,QAAS,CACP,MAAOA,EACR,EACD,WAAY,CACV,MAAOA,EACR,EACD,aAAc,CACZ,MAAOA,EACR,EACD,cAAe,CACb,MAAOA,EACR,EACD,YAAa,CACX,MAAOA,EACR,EACD,SAAU,CACR,MAAOA,EACR,EACD,SAAU,CACR,MAAOA,EACR,EACD,cAAe,CACb,MAAOA,EACR,EACD,mBAAoB,CAClB,MAAOA,EACR,EACD,iBAAkB,CAChB,MAAOA,EACR,EACD,aAAc,CACZ,MAAOA,EACR,EACD,kBAAmB,CACjB,MAAOA,EACR,EACD,gBAAiB,CACf,MAAOA,EACR,EACD,EAAG,CACD,MAAOD,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,OAAQ,CACN,MAAOA,EACR,EACD,UAAW,CACT,MAAOA,EACR,EACD,YAAa,CACX,MAAOA,EACR,EACD,aAAc,CACZ,MAAOA,EACR,EACD,WAAY,CACV,MAAOA,EACR,EACD,QAAS,CACP,MAAOA,EACR,EACD,QAAS,CACP,MAAOA,EACR,EACD,aAAc,CACZ,MAAOA,EACR,EACD,kBAAmB,CACjB,MAAOA,EACR,EACD,gBAAiB,CACf,MAAOA,EACR,EACD,YAAa,CACX,MAAOA,EACR,EACD,iBAAkB,CAChB,MAAOA,EACR,EACD,eAAgB,C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;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","x_google_ignoreList":[3,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,83,84,85,86,87,88,89,90,91,92,93,94,95,96,97,98,99,100,101,102,103,104,105,106,107,108,109,110,111,112,113,114,115,116,117,118,119,120,121,122,123,124,125,126,127,128,129,130,131,132,133,134,135,136,137,138,139,140,141,142,143,144,145,146,147,148,149,150,151,152,153,154,155,156,157,158,159,160,161,162,163,164,165,166,167,168,169,170,171,172,173,174,175,176,177,178,179,180,181,182,183,184,185,186,187,188,189,190,191,192,193,194,195,196,197,198,199,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,228]} \ No newline at end of file diff --git a/lib/platform-bible-react/dist/index.d.ts b/lib/platform-bible-react/dist/index.d.ts index 99def22981..79c9164391 100644 --- a/lib/platform-bible-react/dist/index.d.ts +++ b/lib/platform-bible-react/dist/index.d.ts @@ -455,8 +455,10 @@ export type SettingsSidebarProps = { extensionsSidebarGroupLabel: string; /** Label for the group of projects settings */ projectsSidebarGroupLabel: string; + /** Placeholder for the button */ + buttonPlaceholder: string; }; -export function SettingsSidebar({ id, extensionLabels, projectOptions, handleSelectSidebarItem, selectedSidebarItem, extensionsSidebarGroupLabel, projectsSidebarGroupLabel, }: SettingsSidebarProps): import("react/jsx-runtime").JSX.Element; +export function SettingsSidebar({ id, extensionLabels, projectOptions, handleSelectSidebarItem, selectedSidebarItem, extensionsSidebarGroupLabel, projectsSidebarGroupLabel, buttonPlaceholder, }: SettingsSidebarProps): import("react/jsx-runtime").JSX.Element; export type SettingsSidebarContentSearchProps = SettingsSidebarProps & React$1.PropsWithChildren & { /** Optional id for testing */ id?: string; @@ -465,7 +467,7 @@ export type SettingsSidebarContentSearchProps = SettingsSidebarProps & React$1.P /** Handler to run when the value of the search bar changes */ onSearch: (searchQuery: string) => void; }; -export function SettingsSidebarContentSearch({ id, direction, extensionLabels, projectOptions, children, handleSelectSidebarItem, selectedSidebarItem, onSearch, extensionsSidebarGroupLabel, projectsSidebarGroupLabel, }: SettingsSidebarContentSearchProps): import("react/jsx-runtime").JSX.Element; +export function SettingsSidebarContentSearch({ id, direction, extensionLabels, projectOptions, children, handleSelectSidebarItem, selectedSidebarItem, onSearch, extensionsSidebarGroupLabel, projectsSidebarGroupLabel, buttonPlaceholder, }: SettingsSidebarContentSearchProps): import("react/jsx-runtime").JSX.Element; /** * Information (e.g., a checking error or some other type of "transient" annotation) about something * noteworthy at a specific place in an instance of the Scriptures. diff --git a/lib/platform-bible-react/dist/index.js b/lib/platform-bible-react/dist/index.js index 44518f1b19..c4f03a1502 100644 --- a/lib/platform-bible-react/dist/index.js +++ b/lib/platform-bible-react/dist/index.js @@ -777,18 +777,18 @@ const Tt = class nt { l.verse = i[0]; const c = l.verseNum; if (o.push(l), i.length > 1) { - const p = this.clone(); - if (p.verse = i[1], !e) - for (let d = c + 1; d < p.verseNum; d++) { - const m = new nt( + const d = this.clone(); + if (d.verse = i[1], !e) + for (let p = c + 1; p < d.verseNum; p++) { + const f = new nt( this._bookNum, this._chapterNum, - d, + p, this.versification ); - this.isExcluded || o.push(m); + this.isExcluded || o.push(f); } - o.push(p); + o.push(d); } } return o; @@ -1093,9 +1093,9 @@ function yc(t) { function gh({ scrRef: t, handleSubmit: e }) { const [n, r] = ut(""), [o, a] = ut( ot.bookNumberToId(t.bookNum) - ), [i, l] = ut(t.chapterNum ?? 0), [c, p] = ut( + ), [i, l] = ut(t.chapterNum ?? 0), [c, d] = ut( ot.bookNumberToId(t.bookNum) - ), [d, m] = ut(!1), [w, g] = ut(d), v = ge(void 0), f = ge(void 0), h = ge(void 0), E = Et( + ), [p, f] = ut(!1), [w, g] = ut(p), v = ge(void 0), m = ge(void 0), h = ge(void 0), E = Et( (k) => gc(k).filter((B) => { const D = ot.bookIdToEnglishName(B).toLowerCase(), J = n.replace(/[^a-zA-Z]/g, "").toLowerCase(); return D.includes(J) || // Match book name @@ -1109,7 +1109,7 @@ function gh({ scrRef: t, handleSubmit: e }) { C.current = !1; return; } - m(k); + f(k); }, []), b = Et( (k, B, D, J) => { if (l( @@ -1119,10 +1119,10 @@ function gh({ scrRef: t, handleSubmit: e }) { bookNum: ot.bookIdToNumber(k), chapterNum: D || 1, verseNum: J || 1 - }), m(!1), r(""); + }), f(!1), r(""); return; } - a(o !== k ? k : ""), m(!B); + a(o !== k ? k : ""), f(!B); }, [e, t.bookNum, t.chapterNum, o] ), I = (k) => { @@ -1142,13 +1142,13 @@ function gh({ scrRef: t, handleSubmit: e }) { }); }, [b, n]), H = Et( (k) => { - d ? (k.key === "ArrowDown" || k.key === "ArrowUp") && (typeof h < "u" && // Ref uses null + p ? (k.key === "ArrowDown" || k.key === "ArrowUp") && (typeof h < "u" && // Ref uses null // eslint-disable-next-line no-null/no-null - h.current !== null ? h.current.focus() : typeof f < "u" && // Ref uses null + h.current !== null ? h.current.focus() : typeof m < "u" && // Ref uses null // eslint-disable-next-line no-null/no-null - f.current !== null && f.current.focus(), k.preventDefault()) : m(!0); + m.current !== null && m.current.focus(), k.preventDefault()) : f(!0); }, - [d] + [p] ), O = (k) => { const { key: B } = k; B === "ArrowRight" || B === "ArrowLeft" || B === "ArrowDown" || B === "ArrowUp" || B === "Enter" || (v.current.dispatchEvent(new KeyboardEvent("keydown", { key: B })), v.current.focus()); @@ -1182,18 +1182,18 @@ function gh({ scrRef: t, handleSubmit: e }) { return ae(() => { o === c ? o === ot.bookNumberToId(t.bookNum) ? l(t.chapterNum) : l(1) : l(0); }, [c, t.bookNum, t.chapterNum, o]), ta(() => { - g(d); - }, [d]), ta(() => { + g(p); + }, [p]), ta(() => { const k = setTimeout(() => { - if (w && f.current && h.current) { + if (w && m.current && h.current) { const D = h.current.offsetTop - mc; - f.current.scrollTo({ top: D, behavior: "instant" }); + m.current.scrollTo({ top: D, behavior: "instant" }); } }, 10); return () => { clearTimeout(k); }; - }, [w]), /* @__PURE__ */ s("div", { className: "pr-twp tw-flex", children: /* @__PURE__ */ N(fo, { modal: !1, open: d, onOpenChange: S, children: [ + }, [w]), /* @__PURE__ */ s("div", { className: "pr-twp tw-flex", children: /* @__PURE__ */ N(fo, { modal: !1, open: p, onOpenChange: S, children: [ /* @__PURE__ */ s(mi, { asChild: !0, children: /* @__PURE__ */ s( Wl, { @@ -1202,7 +1202,7 @@ function gh({ scrRef: t, handleSubmit: e }) { handleSearch: _, handleKeyDown: H, handleOnClick: () => { - a(ot.bookNumberToId(t.bookNum)), p(ot.bookNumberToId(t.bookNum)), l(t.chapterNum > 0 ? t.chapterNum : 0), m(!0), v.current.focus(); + a(ot.bookNumberToId(t.bookNum)), d(ot.bookNumberToId(t.bookNum)), l(t.chapterNum > 0 ? t.chapterNum : 0), f(!0), v.current.focus(); }, onFocus: () => { C.current = !0; @@ -1218,7 +1218,7 @@ function gh({ scrRef: t, handleSubmit: e }) { style: { width: "233px", maxHeight: "500px", zIndex: "250" }, onKeyDown: O, align: "start", - ref: f, + ref: m, children: [ /* @__PURE__ */ s( wc, @@ -1237,7 +1237,7 @@ function gh({ scrRef: t, handleSubmit: e }) { bookId: D, handleSelectBook: () => b(D, !1), isSelected: o === D, - handleHighlightBook: () => p(D), + handleHighlightBook: () => d(D), handleKeyDown: $, bookType: k, ref: (J) => { @@ -1470,18 +1470,18 @@ function qr({ getOptionLabel: i = Pc, buttonPlaceholder: l = "", textPlaceholder: c = "", - commandEmptyMessage: p = "No option found", - buttonVariant: d = "outline", - dir: m = "ltr", + commandEmptyMessage: d = "No option found", + buttonVariant: p = "outline", + dir: f = "ltr", isDisabled: w = !1, ...g }) { - const [v, f] = ut(!1); - return /* @__PURE__ */ N(kc, { open: v, onOpenChange: f, ...g, children: [ + const [v, m] = ut(!1); + return /* @__PURE__ */ N(kc, { open: v, onOpenChange: m, ...g, children: [ /* @__PURE__ */ s(Ec, { asChild: !0, children: /* @__PURE__ */ N( gt, { - variant: d, + variant: p, role: "combobox", "aria-expanded": v, id: t, @@ -1493,15 +1493,15 @@ function qr({ ] } ) }), - /* @__PURE__ */ s(vi, { className: x("tw-w-[200px] tw-p-0", r), dir: m, children: /* @__PURE__ */ N(xi, { children: [ - /* @__PURE__ */ s(Ni, { dir: m, placeholder: c, className: "tw-text-inherit" }), - /* @__PURE__ */ s(Ei, { children: p }), + /* @__PURE__ */ s(vi, { className: x("tw-w-[200px] tw-p-0", r), dir: f, children: /* @__PURE__ */ N(xi, { children: [ + /* @__PURE__ */ s(Ni, { dir: f, placeholder: c, className: "tw-text-inherit" }), + /* @__PURE__ */ s(Ei, { children: d }), /* @__PURE__ */ s(ki, { children: e.map((h) => /* @__PURE__ */ N( Si, { value: i(h), onSelect: () => { - a(h), f(!1); + a(h), m(!1); }, children: [ /* @__PURE__ */ s( @@ -1529,7 +1529,7 @@ function $c({ chapterCount: a }) { const i = It( - () => Array.from({ length: a }, (p, d) => d + 1), + () => Array.from({ length: a }, (d, p) => p + 1), [a] ); return /* @__PURE__ */ N(ie, { children: [ @@ -1538,12 +1538,12 @@ function $c({ qr, { isDisabled: o, - onChange: (p) => { - n(p), p > e && r(p); + onChange: (d) => { + n(d), d > e && r(d); }, buttonClassName: "tw-ml-2 tw-mr-2 tw-w-20", options: i, - getOptionLabel: (p) => p.toString(), + getOptionLabel: (d) => d.toString(), value: t }, "start chapter" @@ -1553,12 +1553,12 @@ function $c({ qr, { isDisabled: o, - onChange: (p) => { - r(p), p < t && n(p); + onChange: (d) => { + r(d), d < t && n(d); }, buttonClassName: "tw-ml-2 tw-w-20", options: i, - getOptionLabel: (p) => p.toString(), + getOptionLabel: (d) => d.toString(), value: e }, "end chapter" @@ -1581,12 +1581,12 @@ function vh({ handleSelectEndChapter: i, startChapter: l, handleSelectStartChapter: c, - localizedStrings: p + localizedStrings: d }) { - const d = _r(p, "%webView_bookSelector_currentBook%"), m = _r(p, "%webView_bookSelector_choose%"), w = _r(p, "%webView_bookSelector_chooseBooks%"), [g, v] = ut( + const p = _r(d, "%webView_bookSelector_currentBook%"), f = _r(d, "%webView_bookSelector_choose%"), w = _r(d, "%webView_bookSelector_chooseBooks%"), [g, v] = ut( "current book" /* CURRENT_BOOK */ - ), f = (h) => { + ), m = (h) => { v(h), t(h); }; return /* @__PURE__ */ s( @@ -1594,7 +1594,7 @@ function vh({ { className: "pr-twp tw-flex", value: g, - onValueChange: (h) => f(h), + onValueChange: (h) => m(h), children: /* @__PURE__ */ N("div", { className: "tw-flex tw-w-full tw-flex-col tw-gap-4", children: [ /* @__PURE__ */ N("div", { className: "tw-grid tw-grid-cols-[25%,25%,50%]", children: [ /* @__PURE__ */ N("div", { className: "tw-flex tw-items-center", children: [ @@ -1602,7 +1602,7 @@ function vh({ value: "current book" /* CURRENT_BOOK */ }), - /* @__PURE__ */ s(Xt, { className: "tw-ml-1", children: d }) + /* @__PURE__ */ s(Xt, { className: "tw-ml-1", children: p }) ] }), /* @__PURE__ */ s(Xt, { className: "tw-flex tw-items-center", children: e }), /* @__PURE__ */ s("div", { className: "tw-flex tw-items-center tw-justify-end", children: /* @__PURE__ */ s( @@ -1631,7 +1631,7 @@ function vh({ { disabled: g === "current book", onClick: () => n(), - children: m + children: f } ) ] }) @@ -1938,32 +1938,32 @@ function Lc({ } }) { var h; - const [l, c] = ut([]), [p, d] = ut([]), [m, w] = ut({}), [g, v] = ut({}), f = ei({ + const [l, c] = ut([]), [d, p] = ut([]), [f, w] = ut({}), [g, v] = ut({}), m = ei({ data: e, columns: t, getCoreRowModel: ni(), ...n && { getPaginationRowModel: _l() }, onSortingChange: c, getSortedRowModel: ri(), - onColumnFiltersChange: d, + onColumnFiltersChange: p, getFilteredRowModel: Pl(), onColumnVisibilityChange: w, onRowSelectionChange: v, state: { sorting: l, - columnFilters: p, - columnVisibility: m, + columnFilters: d, + columnVisibility: f, rowSelection: g } }); return /* @__PURE__ */ N("div", { className: "pr-twp", children: [ - o && /* @__PURE__ */ s(Ac, { table: f }), + o && /* @__PURE__ */ s(Ac, { table: m }), /* @__PURE__ */ N(ar, { stickyHeader: a, children: [ - /* @__PURE__ */ s(ir, { stickyHeader: a, children: f.getHeaderGroups().map((E) => /* @__PURE__ */ s(oe, { children: E.headers.map((_) => /* @__PURE__ */ s(vn, { children: _.isPlaceholder ? void 0 : dn(_.column.columnDef.header, _.getContext()) }, _.id)) }, E.id)) }), - /* @__PURE__ */ s(sr, { children: (h = f.getRowModel().rows) != null && h.length ? f.getRowModel().rows.map((E) => /* @__PURE__ */ s( + /* @__PURE__ */ s(ir, { stickyHeader: a, children: m.getHeaderGroups().map((E) => /* @__PURE__ */ s(oe, { children: E.headers.map((_) => /* @__PURE__ */ s(vn, { children: _.isPlaceholder ? void 0 : dn(_.column.columnDef.header, _.getContext()) }, _.id)) }, E.id)) }), + /* @__PURE__ */ s(sr, { children: (h = m.getRowModel().rows) != null && h.length ? m.getRowModel().rows.map((E) => /* @__PURE__ */ s( oe, { - onClick: () => i(E, f), + onClick: () => i(E, m), "data-state": E.getIsSelected() && "selected", children: E.getVisibleCells().map((_) => /* @__PURE__ */ s(je, { children: dn(_.column.columnDef.cell, _.getContext()) }, _.id)) }, @@ -1976,8 +1976,8 @@ function Lc({ { variant: "outline", size: "sm", - onClick: () => f.previousPage(), - disabled: !f.getCanPreviousPage(), + onClick: () => m.previousPage(), + disabled: !m.getCanPreviousPage(), children: "Previous" } ), @@ -1986,13 +1986,13 @@ function Lc({ { variant: "outline", size: "sm", - onClick: () => f.nextPage(), - disabled: !f.getCanNextPage(), + onClick: () => m.nextPage(), + disabled: !m.getCanNextPage(), children: "Next" } ) ] }), - n && r && /* @__PURE__ */ s(jc, { table: f }) + n && r && /* @__PURE__ */ s(jc, { table: m }) ] }); } function Fc({ @@ -2142,11 +2142,11 @@ const lr = (t) => t === "asc" ? /* @__PURE__ */ s(ul, { className: "tw-ms-2 tw-h }), Pr = (t, e, n, r, o, a) => { let i = [...n]; t.forEach((c) => { - e === "approved" ? i.includes(c) || i.push(c) : i = i.filter((p) => p !== c); + e === "approved" ? i.includes(c) || i.push(c) : i = i.filter((d) => d !== c); }), r(i); let l = [...o]; t.forEach((c) => { - e === "unapproved" ? l.includes(c) || l.push(c) : l = l.filter((p) => p !== c); + e === "unapproved" ? l.includes(c) || l.push(c) : l = l.filter((d) => d !== c); }), a(l); }, Nh = (t, e, n, r, o) => ({ accessorKey: "status", @@ -2226,32 +2226,32 @@ const lr = (t) => t === "asc" ? /* @__PURE__ */ s(ul, { className: "tw-ms-2 tw-h return []; const a = []; let i = e.bookNum, l = e.chapterNum, c = e.verseNum; - return Uc(t).forEach((d) => { - d.startsWith("\\id") && (i = Gc(d), l = 0, c = 0), d.startsWith("\\c") && (l = oa(d), c = 0), d.startsWith("\\v") && (c = oa(d), l === 0 && (l = e.chapterNum)); - let m = o.exec(d) ?? void 0; - for (; m; ) { + return Uc(t).forEach((p) => { + p.startsWith("\\id") && (i = Gc(p), l = 0, c = 0), p.startsWith("\\c") && (l = oa(p), c = 0), p.startsWith("\\v") && (c = oa(p), l === 0 && (l = e.chapterNum)); + let f = o.exec(p) ?? void 0; + for (; f; ) { const w = []; - m.forEach((h) => w.push(h)); - const g = m.index, v = a.find((h) => co(h.items, w)), f = { + f.forEach((h) => w.push(h)); + const g = f.index, v = a.find((h) => co(h.items, w)), m = { reference: { bookNum: i !== void 0 ? i : -1, chapterNum: l !== void 0 ? l : -1, verseNum: c !== void 0 ? c : -1 }, - text: Cl(d, Math.max(0, g - 25), Math.min(g + 25, d.length)) + text: Cl(p, Math.max(0, g - 25), Math.min(g + 25, p.length)) }; if (v) - v.count += 1, v.occurrences.push(f); + v.count += 1, v.occurrences.push(m); else { const h = { items: w, count: 1, status: Hc(w[0], n, r), - occurrences: [f] + occurrences: [m] }; a.push(h); } - m = o.exec(d) ?? void 0; + f = o.exec(p) ?? void 0; } }), a; }, Jt = (t, e) => t[e] ?? e; @@ -2265,10 +2265,10 @@ function Eh({ unapprovedItems: i, text: l, scope: c, - onScopeChange: p, - columns: d + onScopeChange: d, + columns: p }) { - const m = Jt(n, "%webView_inventory_all%"), w = Jt(n, "%webView_inventory_approved%"), g = Jt(n, "%webView_inventory_unapproved%"), v = Jt(n, "%webView_inventory_unknown%"), f = Jt(n, "%webView_inventory_scope_currentBook%"), h = Jt(n, "%webView_inventory_scope_chapter%"), E = Jt(n, "%webView_inventory_scope_verse%"), _ = Jt(n, "%webView_inventory_filter_text%"), C = Jt( + const f = Jt(n, "%webView_inventory_all%"), w = Jt(n, "%webView_inventory_approved%"), g = Jt(n, "%webView_inventory_unapproved%"), v = Jt(n, "%webView_inventory_unknown%"), m = Jt(n, "%webView_inventory_scope_currentBook%"), h = Jt(n, "%webView_inventory_scope_chapter%"), E = Jt(n, "%webView_inventory_scope_verse%"), _ = Jt(n, "%webView_inventory_filter_text%"), C = Jt( n, "%webView_inventory_show_additional_items%" ), [S, b] = ut(!1), [I, z] = ut("all"), [H, O] = ut(""), [$, k] = ut([]), B = It(() => l ? r instanceof RegExp ? qc( @@ -2295,10 +2295,10 @@ function Eh({ }, [S, B]), J = It(() => Wc(D, I, H), [D, I, H]), q = It(() => { var L, F; if (!S) - return d; + return p; const y = (L = o == null ? void 0 : o.tableHeaders) == null ? void 0 : L.length; if (!y) - return d; + return p; const R = []; for (let V = 0; V < y; V++) R.push( @@ -2307,8 +2307,8 @@ function Eh({ V + 1 ) ); - return [...R, ...d]; - }, [o == null ? void 0 : o.tableHeaders, d, S]); + return [...R, ...p]; + }, [o == null ? void 0 : o.tableHeaders, p, S]); ae(() => { k([]); }, [J]); @@ -2319,7 +2319,7 @@ function Eh({ }), k(y.original.items); }, tt = (y) => { if (y === "book" || y === "chapter" || y === "verse") - p(y); + d(y); else throw new Error(`Invalid scope value: ${y}`); }, at = (y) => { @@ -2348,7 +2348,7 @@ function Eh({ children: [ /* @__PURE__ */ s(De, { className: "tw-m-1", children: /* @__PURE__ */ s(bn, { placeholder: "Select filter" }) }), /* @__PURE__ */ N(Be, { children: [ - /* @__PURE__ */ s(Gt, { value: "all", children: m }), + /* @__PURE__ */ s(Gt, { value: "all", children: f }), /* @__PURE__ */ s(Gt, { value: "approved", children: w }), /* @__PURE__ */ s(Gt, { value: "unapproved", children: g }), /* @__PURE__ */ s(Gt, { value: "unknown", children: v }) @@ -2359,7 +2359,7 @@ function Eh({ /* @__PURE__ */ N(gn, { onValueChange: (y) => tt(y), defaultValue: c, children: [ /* @__PURE__ */ s(De, { className: "tw-m-1", children: /* @__PURE__ */ s(bn, { placeholder: "Select scope" }) }), /* @__PURE__ */ N(Be, { children: [ - /* @__PURE__ */ s(Gt, { value: "book", children: f }), + /* @__PURE__ */ s(Gt, { value: "book", children: m }), /* @__PURE__ */ s(Gt, { value: "chapter", children: h }), /* @__PURE__ */ s(Gt, { value: "verse", children: E }) ] }) @@ -2622,30 +2622,30 @@ const Vi = T.forwardRef( children: a, ...i }, l) => { - const c = ad(), [p, d] = T.useState(!1), [m, w] = T.useState(t), g = e ?? m, v = T.useCallback( + const c = ad(), [d, p] = T.useState(!1), [f, w] = T.useState(t), g = e ?? f, v = T.useCallback( (_) => { const C = typeof _ == "function" ? _(g) : _; n ? n(C) : w(C), document.cookie = `${id}=${C}; path=/; max-age=${sd}`; }, [n, g] - ), f = T.useCallback(() => c ? d((_) => !_) : v((_) => !_), [c, v, d]); + ), m = T.useCallback(() => c ? p((_) => !_) : v((_) => !_), [c, v, p]); T.useEffect(() => { const _ = (C) => { - C.key === pd && (C.metaKey || C.ctrlKey) && (C.preventDefault(), f()); + C.key === pd && (C.metaKey || C.ctrlKey) && (C.preventDefault(), m()); }; return window.addEventListener("keydown", _), () => window.removeEventListener("keydown", _); - }, [f]); + }, [m]); const h = g ? "expanded" : "collapsed", E = T.useMemo( () => ({ state: h, open: g, setOpen: v, isMobile: c, - openMobile: p, - setOpenMobile: d, - toggleSidebar: f + openMobile: d, + setOpenMobile: p, + toggleSidebar: m }), - [h, g, v, c, p, d, f] + [h, g, v, c, d, p, m] ); return /* @__PURE__ */ s(ji.Provider, { value: E, children: /* @__PURE__ */ s(nd, { delayDuration: 0, children: /* @__PURE__ */ s( "div", @@ -2680,7 +2680,7 @@ const zi = T.forwardRef( children: o, ...a }, i) => { - const { isMobile: l, state: c, openMobile: p, setOpenMobile: d } = cr(); + const { isMobile: l, state: c, openMobile: d, setOpenMobile: p } = cr(); return n === "none" ? /* @__PURE__ */ s( "div", { @@ -2692,7 +2692,7 @@ const zi = T.forwardRef( ...a, children: o } - ) : l ? /* @__PURE__ */ s(Jc, { open: p, onOpenChange: d, ...a, children: /* @__PURE__ */ s( + ) : l ? /* @__PURE__ */ s(Jc, { open: d, onOpenChange: p, ...a, children: /* @__PURE__ */ s( Di, { "data-sidebar": "sidebar", @@ -2992,7 +2992,7 @@ const vd = Xe( className: a, ...i }, l) => { - const c = t ? He : "button", { isMobile: p, state: d } = cr(), m = /* @__PURE__ */ s( + const c = t ? He : "button", { isMobile: d, state: p } = cr(), f = /* @__PURE__ */ s( c, { ref: l, @@ -3006,17 +3006,17 @@ const vd = Xe( return o ? (typeof o == "string" && (o = { children: o }), /* @__PURE__ */ N(rd, { children: [ - /* @__PURE__ */ s(od, { asChild: !0, children: m }), + /* @__PURE__ */ s(od, { asChild: !0, children: f }), /* @__PURE__ */ s( Bi, { side: "right", align: "center", - hidden: d !== "collapsed" || p, + hidden: p !== "collapsed" || d, ...o } ) - ] })) : m; + ] })) : f; } ); Hi.displayName = "SidebarMenuButton"; @@ -3135,21 +3135,22 @@ function Td({ handleSelectSidebarItem: r, selectedSidebarItem: o, extensionsSidebarGroupLabel: a, - projectsSidebarGroupLabel: i + projectsSidebarGroupLabel: i, + buttonPlaceholder: l }) { - const l = Et( - (d, m) => { - r(d, m); + const c = Et( + (f, w) => { + r(f, w); }, [r] - ), c = Et( - (d) => { - const m = n.find((w) => w.projectId === d); - return m ? m.projectName : d; + ), d = Et( + (f) => { + const w = n.find((g) => g.projectId === f); + return w ? w.projectName : f; }, [n] ), p = Et( - (d) => !o.projectId && d === o.label, + (f) => !o.projectId && f === o.label, [o] ); return /* @__PURE__ */ s( @@ -3162,18 +3163,18 @@ function Td({ children: /* @__PURE__ */ N(Fi, { children: [ /* @__PURE__ */ N(Kr, { children: [ /* @__PURE__ */ s(Jr, { className: "tw-text-sm tw-text-gray-400", children: a }), - /* @__PURE__ */ s(Zr, { children: /* @__PURE__ */ s(Ui, { children: e.map((d) => /* @__PURE__ */ s(Gi, { children: /* @__PURE__ */ s( + /* @__PURE__ */ s(Zr, { children: /* @__PURE__ */ s(Ui, { children: e.map((f) => /* @__PURE__ */ s(Gi, { children: /* @__PURE__ */ s( Hi, { className: x( "tw-rounded tw-py-2 tw-text-sm tw-text-gray-500 hover:tw-bg-white hover:tw-text-gray-900 hover:tw-shadow-sm active:tw-bg-white", - { "tw-bg-white tw-text-gray-900 tw-shadow-sm": p(d) } + { "tw-bg-white tw-text-gray-900 tw-shadow-sm": p(f) } ), - onClick: () => l(d, void 0), - isActive: p(d), - children: /* @__PURE__ */ s("span", { className: "tw-pl-3", children: d }) + onClick: () => c(f, void 0), + isActive: p(f), + children: /* @__PURE__ */ s("span", { className: "tw-pl-3", children: f }) } - ) }, d)) }) }) + ) }, f)) }) }) ] }), /* @__PURE__ */ N(Kr, { children: [ /* @__PURE__ */ s(Jr, { className: "tw-text-sm tw-text-gray-400", children: i }), @@ -3181,12 +3182,12 @@ function Td({ qr, { popoverContentClassName: "tw-z-[1000]", - options: n.flatMap((d) => d.projectId), - getOptionLabel: (d) => c(d), - buttonPlaceholder: "Type or select project", - onChange: (d) => { - const m = c(d); - l(m, d); + options: n.flatMap((f) => f.projectId), + getOptionLabel: (f) => d(f), + buttonPlaceholder: l, + onChange: (f) => { + const w = d(f); + c(w, f); }, value: (o == null ? void 0 : o.projectId) ?? void 0 } @@ -3206,10 +3207,11 @@ function Th({ selectedSidebarItem: i, onSearch: l, extensionsSidebarGroupLabel: c, - projectsSidebarGroupLabel: p + projectsSidebarGroupLabel: d, + buttonPlaceholder: p }) { - return /* @__PURE__ */ N("div", { className: "tw-flex tw-h-full tw-flex-col tw-p-3 tw-pb-2", children: [ - /* @__PURE__ */ s("div", { className: "tw-flex tw-items-center tw-justify-center tw-py-4", children: /* @__PURE__ */ s( + return /* @__PURE__ */ N("div", { className: "tw-box-border tw-flex tw-h-full tw-flex-col tw-p-3", children: [ + /* @__PURE__ */ s("div", { className: "tw-box-border tw-flex tw-items-center tw-justify-center tw-py-4", children: /* @__PURE__ */ s( Pi, { className: "tw-w-9/12", @@ -3217,20 +3219,29 @@ function Th({ placeholder: "Search app settings, extension settings, and project settings" } ) }), - /* @__PURE__ */ N(Vi, { dir: e, id: t, className: "tw-h-full tw-flex-1 tw-gap-4", children: [ - /* @__PURE__ */ s( - Td, - { - extensionLabels: n, - projectOptions: r, - handleSelectSidebarItem: a, - selectedSidebarItem: i, - extensionsSidebarGroupLabel: c, - projectsSidebarGroupLabel: p - } - ), - /* @__PURE__ */ s(Li, { className: "tw-overflow-y-auto", children: o }) - ] }) + /* @__PURE__ */ N( + Vi, + { + dir: e, + id: t, + className: "tw-h-full tw-flex-1 tw-gap-4 tw-overflow-auto", + children: [ + /* @__PURE__ */ s( + Td, + { + extensionLabels: n, + projectOptions: r, + handleSelectSidebarItem: a, + selectedSidebarItem: i, + extensionsSidebarGroupLabel: c, + projectsSidebarGroupLabel: d, + buttonPlaceholder: p + } + ), + /* @__PURE__ */ s(Li, { className: "tw-overflow-y-auto", children: o }) + ] + } + ) ] }); } const ne = "scrBook", Cd = "scrRef", we = "source", Od = "details", Rd = "Scripture Reference", _d = "Scripture Book", Xi = "Type", Pd = "Details"; @@ -3298,7 +3309,7 @@ function Ch({ onRowSelected: l, direction: c = "ltr" }) { - const [p, d] = ut([]), [m, w] = ut([{ id: ne, desc: !1 }]), [g, v] = ut({}), f = It( + const [d, p] = ut([]), [f, w] = ut([{ id: ne, desc: !1 }]), [g, v] = ut({}), m = It( () => t.flatMap((O) => O.data.map(($) => ({ ...$, source: O.source @@ -3316,20 +3327,20 @@ function Ch({ [r, a, i, n] ); ae(() => { - p.includes(we) ? w([ + d.includes(we) ? w([ { id: we, desc: !1 }, { id: ne, desc: !1 } ]) : w([{ id: ne, desc: !1 }]); - }, [p]); + }, [d]); const E = ei({ - data: f, + data: m, columns: h, state: { - grouping: p, - sorting: m, + grouping: d, + sorting: f, rowSelection: g }, - onGroupingChange: d, + onGroupingChange: p, onSortingChange: w, onRowSelectionChange: v, getExpandedRowModel: $l(), @@ -3345,11 +3356,11 @@ function Ch({ if (l) { const O = E.getSelectedRowModel().rowsById, $ = Object.keys(O); if ($.length === 1) { - const k = f.find((B) => ia(B) === $[0]) || void 0; + const k = m.find((B) => ia(B) === $[0]) || void 0; k && l(k); } } - }, [g, f, l, E]); + }, [g, m, l, E]); const _ = o ?? _d, C = a ?? Xi, S = [ { label: "No Grouping", value: [] }, { label: `Group by ${_}`, value: [ne] }, @@ -3363,7 +3374,7 @@ function Ch({ value: [we, ne] } ], b = (O) => { - d(JSON.parse(O)); + p(JSON.parse(O)); }, I = (O, $) => { !O.getIsGrouped() && !O.getIsSelected() && O.getToggleSelectedHandler()($); }, z = (O, $) => O.getIsGrouped() ? "" : x("banded-row", $ % 2 === 0 ? "even" : "odd"), H = (O, $, k) => { @@ -3389,7 +3400,7 @@ function Ch({ !e && /* @__PURE__ */ N( gn, { - value: JSON.stringify(p), + value: JSON.stringify(d), onValueChange: (O) => { b(O); }, @@ -3431,7 +3442,7 @@ function Ch({ className: x( k.column.columnDef.id, "tw-p-[1px]", - H(p, O, k) + H(d, O, k) ), children: (() => k.getIsGrouped() ? /* @__PURE__ */ N( gt, @@ -3667,7 +3678,7 @@ function Bd() { if (sa) return it; sa = 1; - var t = typeof Symbol == "function" && Symbol.for, e = t ? Symbol.for("react.element") : 60103, n = t ? Symbol.for("react.portal") : 60106, r = t ? Symbol.for("react.fragment") : 60107, o = t ? Symbol.for("react.strict_mode") : 60108, a = t ? Symbol.for("react.profiler") : 60114, i = t ? Symbol.for("react.provider") : 60109, l = t ? Symbol.for("react.context") : 60110, c = t ? Symbol.for("react.async_mode") : 60111, p = t ? Symbol.for("react.concurrent_mode") : 60111, d = t ? Symbol.for("react.forward_ref") : 60112, m = t ? Symbol.for("react.suspense") : 60113, w = t ? Symbol.for("react.suspense_list") : 60120, g = t ? Symbol.for("react.memo") : 60115, v = t ? Symbol.for("react.lazy") : 60116, f = t ? Symbol.for("react.block") : 60121, h = t ? Symbol.for("react.fundamental") : 60117, E = t ? Symbol.for("react.responder") : 60118, _ = t ? Symbol.for("react.scope") : 60119; + var t = typeof Symbol == "function" && Symbol.for, e = t ? Symbol.for("react.element") : 60103, n = t ? Symbol.for("react.portal") : 60106, r = t ? Symbol.for("react.fragment") : 60107, o = t ? Symbol.for("react.strict_mode") : 60108, a = t ? Symbol.for("react.profiler") : 60114, i = t ? Symbol.for("react.provider") : 60109, l = t ? Symbol.for("react.context") : 60110, c = t ? Symbol.for("react.async_mode") : 60111, d = t ? Symbol.for("react.concurrent_mode") : 60111, p = t ? Symbol.for("react.forward_ref") : 60112, f = t ? Symbol.for("react.suspense") : 60113, w = t ? Symbol.for("react.suspense_list") : 60120, g = t ? Symbol.for("react.memo") : 60115, v = t ? Symbol.for("react.lazy") : 60116, m = t ? Symbol.for("react.block") : 60121, h = t ? Symbol.for("react.fundamental") : 60117, E = t ? Symbol.for("react.responder") : 60118, _ = t ? Symbol.for("react.scope") : 60119; function C(b) { if (typeof b == "object" && b !== null) { var I = b.$$typeof; @@ -3675,16 +3686,16 @@ function Bd() { case e: switch (b = b.type, b) { case c: - case p: + case d: case r: case a: case o: - case m: + case f: return b; default: switch (b = b && b.$$typeof, b) { case l: - case d: + case p: case v: case g: case i: @@ -3699,9 +3710,9 @@ function Bd() { } } function S(b) { - return C(b) === p; + return C(b) === d; } - return it.AsyncMode = c, it.ConcurrentMode = p, it.ContextConsumer = l, it.ContextProvider = i, it.Element = e, it.ForwardRef = d, it.Fragment = r, it.Lazy = v, it.Memo = g, it.Portal = n, it.Profiler = a, it.StrictMode = o, it.Suspense = m, it.isAsyncMode = function(b) { + return it.AsyncMode = c, it.ConcurrentMode = d, it.ContextConsumer = l, it.ContextProvider = i, it.Element = e, it.ForwardRef = p, it.Fragment = r, it.Lazy = v, it.Memo = g, it.Portal = n, it.Profiler = a, it.StrictMode = o, it.Suspense = f, it.isAsyncMode = function(b) { return S(b) || C(b) === c; }, it.isConcurrentMode = S, it.isContextConsumer = function(b) { return C(b) === l; @@ -3710,7 +3721,7 @@ function Bd() { }, it.isElement = function(b) { return typeof b == "object" && b !== null && b.$$typeof === e; }, it.isForwardRef = function(b) { - return C(b) === d; + return C(b) === p; }, it.isFragment = function(b) { return C(b) === r; }, it.isLazy = function(b) { @@ -3724,9 +3735,9 @@ function Bd() { }, it.isStrictMode = function(b) { return C(b) === o; }, it.isSuspense = function(b) { - return C(b) === m; + return C(b) === f; }, it.isValidElementType = function(b) { - return typeof b == "string" || typeof b == "function" || b === r || b === p || b === a || b === o || b === m || b === w || typeof b == "object" && b !== null && (b.$$typeof === v || b.$$typeof === g || b.$$typeof === i || b.$$typeof === l || b.$$typeof === d || b.$$typeof === h || b.$$typeof === E || b.$$typeof === _ || b.$$typeof === f); + return typeof b == "string" || typeof b == "function" || b === r || b === d || b === a || b === o || b === f || b === w || typeof b == "object" && b !== null && (b.$$typeof === v || b.$$typeof === g || b.$$typeof === i || b.$$typeof === l || b.$$typeof === p || b.$$typeof === h || b.$$typeof === E || b.$$typeof === _ || b.$$typeof === m); }, it.typeOf = C, it; } var st = {}; @@ -3741,10 +3752,10 @@ var st = {}; var la; function jd() { return la || (la = 1, process.env.NODE_ENV !== "production" && function() { - var t = typeof Symbol == "function" && Symbol.for, e = t ? Symbol.for("react.element") : 60103, n = t ? Symbol.for("react.portal") : 60106, r = t ? Symbol.for("react.fragment") : 60107, o = t ? Symbol.for("react.strict_mode") : 60108, a = t ? Symbol.for("react.profiler") : 60114, i = t ? Symbol.for("react.provider") : 60109, l = t ? Symbol.for("react.context") : 60110, c = t ? Symbol.for("react.async_mode") : 60111, p = t ? Symbol.for("react.concurrent_mode") : 60111, d = t ? Symbol.for("react.forward_ref") : 60112, m = t ? Symbol.for("react.suspense") : 60113, w = t ? Symbol.for("react.suspense_list") : 60120, g = t ? Symbol.for("react.memo") : 60115, v = t ? Symbol.for("react.lazy") : 60116, f = t ? Symbol.for("react.block") : 60121, h = t ? Symbol.for("react.fundamental") : 60117, E = t ? Symbol.for("react.responder") : 60118, _ = t ? Symbol.for("react.scope") : 60119; + var t = typeof Symbol == "function" && Symbol.for, e = t ? Symbol.for("react.element") : 60103, n = t ? Symbol.for("react.portal") : 60106, r = t ? Symbol.for("react.fragment") : 60107, o = t ? Symbol.for("react.strict_mode") : 60108, a = t ? Symbol.for("react.profiler") : 60114, i = t ? Symbol.for("react.provider") : 60109, l = t ? Symbol.for("react.context") : 60110, c = t ? Symbol.for("react.async_mode") : 60111, d = t ? Symbol.for("react.concurrent_mode") : 60111, p = t ? Symbol.for("react.forward_ref") : 60112, f = t ? Symbol.for("react.suspense") : 60113, w = t ? Symbol.for("react.suspense_list") : 60120, g = t ? Symbol.for("react.memo") : 60115, v = t ? Symbol.for("react.lazy") : 60116, m = t ? Symbol.for("react.block") : 60121, h = t ? Symbol.for("react.fundamental") : 60117, E = t ? Symbol.for("react.responder") : 60118, _ = t ? Symbol.for("react.scope") : 60119; function C(A) { return typeof A == "string" || typeof A == "function" || // Note: its typeof might be other than 'symbol' or 'number' if it's a polyfill. - A === r || A === p || A === a || A === o || A === m || A === w || typeof A == "object" && A !== null && (A.$$typeof === v || A.$$typeof === g || A.$$typeof === i || A.$$typeof === l || A.$$typeof === d || A.$$typeof === h || A.$$typeof === E || A.$$typeof === _ || A.$$typeof === f); + A === r || A === d || A === a || A === o || A === f || A === w || typeof A == "object" && A !== null && (A.$$typeof === v || A.$$typeof === g || A.$$typeof === i || A.$$typeof === l || A.$$typeof === p || A.$$typeof === h || A.$$typeof === E || A.$$typeof === _ || A.$$typeof === m); } function S(A) { if (typeof A == "object" && A !== null) { @@ -3754,17 +3765,17 @@ function jd() { var j = A.type; switch (j) { case c: - case p: + case d: case r: case a: case o: - case m: + case f: return j; default: var xt = j && j.$$typeof; switch (xt) { case l: - case d: + case p: case v: case g: case i: @@ -3778,12 +3789,12 @@ function jd() { } } } - var b = c, I = p, z = l, H = i, O = e, $ = d, k = r, B = v, D = g, J = n, q = a, U = o, tt = m, at = !1; + var b = c, I = d, z = l, H = i, O = e, $ = p, k = r, B = v, D = g, J = n, q = a, U = o, tt = f, at = !1; function rt(A) { return at || (at = !0, console.warn("The ReactIs.isAsyncMode() alias has been deprecated, and will be removed in React 17+. Update your code to use ReactIs.isConcurrentMode() instead. It has the exact same API.")), y(A) || S(A) === c; } function y(A) { - return S(A) === p; + return S(A) === d; } function R(A) { return S(A) === l; @@ -3795,7 +3806,7 @@ function jd() { return typeof A == "object" && A !== null && A.$$typeof === e; } function V(A) { - return S(A) === d; + return S(A) === p; } function W(A) { return S(A) === r; @@ -3816,7 +3827,7 @@ function jd() { return S(A) === o; } function dt(A) { - return S(A) === m; + return S(A) === f; } st.AsyncMode = b, st.ConcurrentMode = I, st.ContextConsumer = z, st.ContextProvider = H, st.Element = O, st.ForwardRef = $, st.Fragment = k, st.Lazy = B, st.Memo = D, st.Portal = J, st.Profiler = q, st.StrictMode = U, st.Suspense = tt, st.isAsyncMode = rt, st.isConcurrentMode = y, st.isContextConsumer = R, st.isContextProvider = L, st.isElement = F, st.isForwardRef = V, st.isFragment = W, st.isLazy = X, st.isMemo = Y, st.isPortal = G, st.isProfiler = K, st.isStrictMode = Z, st.isSuspense = dt, st.isValidElementType = C, st.typeOf = S; }()), st; @@ -3850,28 +3861,28 @@ function Vd() { return !1; for (var i = {}, l = 0; l < 10; l++) i["_" + String.fromCharCode(l)] = l; - var c = Object.getOwnPropertyNames(i).map(function(d) { - return i[d]; + var c = Object.getOwnPropertyNames(i).map(function(p) { + return i[p]; }); if (c.join("") !== "0123456789") return !1; - var p = {}; - return "abcdefghijklmnopqrst".split("").forEach(function(d) { - p[d] = d; - }), Object.keys(Object.assign({}, p)).join("") === "abcdefghijklmnopqrst"; + var d = {}; + return "abcdefghijklmnopqrst".split("").forEach(function(p) { + d[p] = p; + }), Object.keys(Object.assign({}, d)).join("") === "abcdefghijklmnopqrst"; } catch { return !1; } } return Mr = o() ? Object.assign : function(a, i) { - for (var l, c = r(a), p, d = 1; d < arguments.length; d++) { - l = Object(arguments[d]); - for (var m in l) - e.call(l, m) && (c[m] = l[m]); + for (var l, c = r(a), d, p = 1; p < arguments.length; p++) { + l = Object(arguments[p]); + for (var f in l) + e.call(l, f) && (c[f] = l[f]); if (t) { - p = t(l); - for (var w = 0; w < p.length; w++) - n.call(l, p[w]) && (c[p[w]] = l[p[w]]); + d = t(l); + for (var w = 0; w < d.length; w++) + n.call(l, d[w]) && (c[d[w]] = l[d[w]]); } } return c; @@ -3907,29 +3918,29 @@ function zd() { } }; } - function o(a, i, l, c, p) { + function o(a, i, l, c, d) { if (process.env.NODE_ENV !== "production") { - for (var d in a) - if (r(a, d)) { - var m; + for (var p in a) + if (r(a, p)) { + var f; try { - if (typeof a[d] != "function") { + if (typeof a[p] != "function") { var w = Error( - (c || "React class") + ": " + l + " type `" + d + "` is invalid; it must be a function, usually from the `prop-types` package, but received `" + typeof a[d] + "`.This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`." + (c || "React class") + ": " + l + " type `" + p + "` is invalid; it must be a function, usually from the `prop-types` package, but received `" + typeof a[p] + "`.This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`." ); throw w.name = "Invariant Violation", w; } - m = a[d](i, d, c, l, null, e); + f = a[p](i, p, c, l, null, e); } catch (v) { - m = v; + f = v; } - if (m && !(m instanceof Error) && t( - (c || "React class") + ": type specification of " + l + " `" + d + "` is invalid; the type checker function must return `null` or an `Error` but returned a " + typeof m + ". You may have forgotten to pass an argument to the type checker creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and shape all require an argument)." - ), m instanceof Error && !(m.message in n)) { - n[m.message] = !0; - var g = p ? p() : ""; + if (f && !(f instanceof Error) && t( + (c || "React class") + ": type specification of " + l + " `" + p + "` is invalid; the type checker function must return `null` or an `Error` but returned a " + typeof f + ". You may have forgotten to pass an argument to the type checker creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and shape all require an argument)." + ), f instanceof Error && !(f.message in n)) { + n[f.message] = !0; + var g = d ? d() : ""; t( - "Failed " + l + " type: " + m.message + (g ?? "") + "Failed " + l + " type: " + f.message + (g ?? "") ); } } @@ -3958,9 +3969,9 @@ function Ld() { return null; } return Vr = function(l, c) { - var p = typeof Symbol == "function" && Symbol.iterator, d = "@@iterator"; - function m(y) { - var R = y && (p && y[p] || y[d]); + var d = typeof Symbol == "function" && Symbol.iterator, p = "@@iterator"; + function f(y) { + var R = y && (d && y[d] || y[p]); if (typeof R == "function") return R; } @@ -3988,10 +3999,10 @@ function Ld() { function v(y, R) { return y === R ? y !== 0 || 1 / y === 1 / R : y !== y && R !== R; } - function f(y, R) { + function m(y, R) { this.message = y, this.data = R && typeof R == "object" ? R : {}, this.stack = ""; } - f.prototype = Error.prototype; + m.prototype = Error.prototype; function h(y) { if (process.env.NODE_ENV !== "production") var R = {}, L = 0; @@ -4010,7 +4021,7 @@ function Ld() { ), R[Nt] = !0, L++); } } - return X[Y] == null ? W ? X[Y] === null ? new f("The " + K + " `" + Z + "` is marked as required " + ("in `" + G + "`, but its value is `null`.")) : new f("The " + K + " `" + Z + "` is marked as required in " + ("`" + G + "`, but its value is `undefined`.")) : null : y(X, Y, G, K, Z); + return X[Y] == null ? W ? X[Y] === null ? new m("The " + K + " `" + Z + "` is marked as required " + ("in `" + G + "`, but its value is `null`.")) : new m("The " + K + " `" + Z + "` is marked as required in " + ("`" + G + "`, but its value is `undefined`.")) : null : y(X, Y, G, K, Z); } var V = F.bind(null, !1); return V.isRequired = F.bind(null, !0), V; @@ -4020,7 +4031,7 @@ function Ld() { var G = L[F], K = U(G); if (K !== y) { var Z = tt(G); - return new f( + return new m( "Invalid " + W + " `" + X + "` of type " + ("`" + Z + "` supplied to `" + V + "`, expected ") + ("`" + y + "`."), { expectedType: y } ); @@ -4035,11 +4046,11 @@ function Ld() { function C(y) { function R(L, F, V, W, X) { if (typeof y != "function") - return new f("Property `" + X + "` of component `" + V + "` has invalid PropType notation inside arrayOf."); + return new m("Property `" + X + "` of component `" + V + "` has invalid PropType notation inside arrayOf."); var Y = L[F]; if (!Array.isArray(Y)) { var G = U(Y); - return new f("Invalid " + W + " `" + X + "` of type " + ("`" + G + "` supplied to `" + V + "`, expected an array.")); + return new m("Invalid " + W + " `" + X + "` of type " + ("`" + G + "` supplied to `" + V + "`, expected an array.")); } for (var K = 0; K < Y.length; K++) { var Z = y(Y, K, V, W, X + "[" + K + "]", n); @@ -4055,7 +4066,7 @@ function Ld() { var X = R[L]; if (!l(X)) { var Y = U(X); - return new f("Invalid " + V + " `" + W + "` of type " + ("`" + Y + "` supplied to `" + F + "`, expected a single ReactElement.")); + return new m("Invalid " + V + " `" + W + "` of type " + ("`" + Y + "` supplied to `" + F + "`, expected a single ReactElement.")); } return null; } @@ -4066,7 +4077,7 @@ function Ld() { var X = R[L]; if (!t.isValidElementType(X)) { var Y = U(X); - return new f("Invalid " + V + " `" + W + "` of type " + ("`" + Y + "` supplied to `" + F + "`, expected a single ReactElement type.")); + return new m("Invalid " + V + " `" + W + "` of type " + ("`" + Y + "` supplied to `" + F + "`, expected a single ReactElement type.")); } return null; } @@ -4076,7 +4087,7 @@ function Ld() { function R(L, F, V, W, X) { if (!(L[F] instanceof y)) { var Y = y.name || w, G = rt(L[F]); - return new f("Invalid " + W + " `" + X + "` of type " + ("`" + G + "` supplied to `" + V + "`, expected ") + ("instance of `" + Y + "`.")); + return new m("Invalid " + W + " `" + X + "` of type " + ("`" + G + "` supplied to `" + V + "`, expected ") + ("instance of `" + Y + "`.")); } return null; } @@ -4095,17 +4106,17 @@ function Ld() { var Nt = tt(A); return Nt === "symbol" ? String(A) : A; }); - return new f("Invalid " + W + " `" + X + "` of value `" + String(Y) + "` " + ("supplied to `" + V + "`, expected one of " + K + ".")); + return new m("Invalid " + W + " `" + X + "` of value `" + String(Y) + "` " + ("supplied to `" + V + "`, expected one of " + K + ".")); } return h(R); } function H(y) { function R(L, F, V, W, X) { if (typeof y != "function") - return new f("Property `" + X + "` of component `" + V + "` has invalid PropType notation inside objectOf."); + return new m("Property `" + X + "` of component `" + V + "` has invalid PropType notation inside objectOf."); var Y = L[F], G = U(Y); if (G !== "object") - return new f("Invalid " + W + " `" + X + "` of type " + ("`" + G + "` supplied to `" + V + "`, expected an object.")); + return new m("Invalid " + W + " `" + X + "` of type " + ("`" + G + "` supplied to `" + V + "`, expected an object.")); for (var K in Y) if (r(Y, K)) { var Z = y(Y, K, V, W, X + "." + K, n); @@ -4134,18 +4145,18 @@ function Ld() { A.data && r(A.data, "expectedType") && K.push(A.data.expectedType); } var Nt = K.length > 0 ? ", expected one of type [" + K.join(", ") + "]" : ""; - return new f("Invalid " + Y + " `" + G + "` supplied to " + ("`" + X + "`" + Nt + ".")); + return new m("Invalid " + Y + " `" + G + "` supplied to " + ("`" + X + "`" + Nt + ".")); } return h(F); } function $() { function y(R, L, F, V, W) { - return J(R[L]) ? null : new f("Invalid " + V + " `" + W + "` supplied to " + ("`" + F + "`, expected a ReactNode.")); + return J(R[L]) ? null : new m("Invalid " + V + " `" + W + "` supplied to " + ("`" + F + "`, expected a ReactNode.")); } return h(y); } function k(y, R, L, F, V) { - return new f( + return new m( (y || "React class") + ": " + R + " type `" + L + "." + F + "` is invalid; it must be a function, usually from the `prop-types` package, but received `" + V + "`." ); } @@ -4153,7 +4164,7 @@ function Ld() { function R(L, F, V, W, X) { var Y = L[F], G = U(Y); if (G !== "object") - return new f("Invalid " + W + " `" + X + "` of type `" + G + "` " + ("supplied to `" + V + "`, expected `object`.")); + return new m("Invalid " + W + " `" + X + "` of type `" + G + "` " + ("supplied to `" + V + "`, expected `object`.")); for (var K in y) { var Z = y[K]; if (typeof Z != "function") @@ -4170,14 +4181,14 @@ function Ld() { function R(L, F, V, W, X) { var Y = L[F], G = U(Y); if (G !== "object") - return new f("Invalid " + W + " `" + X + "` of type `" + G + "` " + ("supplied to `" + V + "`, expected `object`.")); + return new m("Invalid " + W + " `" + X + "` of type `" + G + "` " + ("supplied to `" + V + "`, expected `object`.")); var K = e({}, L[F], y); for (var Z in K) { var dt = y[Z]; if (r(y, Z) && typeof dt != "function") return k(V, W, X, Z, tt(dt)); if (!dt) - return new f( + return new m( "Invalid " + W + " `" + X + "` key `" + Z + "` supplied to `" + V + "`.\nBad object: " + JSON.stringify(L[F], null, " ") + ` Valid keys: ` + JSON.stringify(Object.keys(y), null, " ") ); @@ -4202,7 +4213,7 @@ Valid keys: ` + JSON.stringify(Object.keys(y), null, " ") return y.every(J); if (y === null || l(y)) return !0; - var R = m(y); + var R = f(y); if (R) { var L = R.call(y), F; if (R !== y.entries) { @@ -4272,8 +4283,8 @@ function Fd() { function n() { } return n.resetWarningCache = e, zr = function() { - function r(i, l, c, p, d, m) { - if (m !== t) { + function r(i, l, c, d, p, f) { + if (f !== t) { var w = new Error( "Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types" ); @@ -4367,9 +4378,9 @@ function qd() { if (ha) return lt; ha = 1; - var t = Symbol.for("react.element"), e = Symbol.for("react.portal"), n = Symbol.for("react.fragment"), r = Symbol.for("react.strict_mode"), o = Symbol.for("react.profiler"), a = Symbol.for("react.provider"), i = Symbol.for("react.context"), l = Symbol.for("react.server_context"), c = Symbol.for("react.forward_ref"), p = Symbol.for("react.suspense"), d = Symbol.for("react.suspense_list"), m = Symbol.for("react.memo"), w = Symbol.for("react.lazy"), g = Symbol.for("react.offscreen"), v; + var t = Symbol.for("react.element"), e = Symbol.for("react.portal"), n = Symbol.for("react.fragment"), r = Symbol.for("react.strict_mode"), o = Symbol.for("react.profiler"), a = Symbol.for("react.provider"), i = Symbol.for("react.context"), l = Symbol.for("react.server_context"), c = Symbol.for("react.forward_ref"), d = Symbol.for("react.suspense"), p = Symbol.for("react.suspense_list"), f = Symbol.for("react.memo"), w = Symbol.for("react.lazy"), g = Symbol.for("react.offscreen"), v; v = Symbol.for("react.module.reference"); - function f(h) { + function m(h) { if (typeof h == "object" && h !== null) { var E = h.$$typeof; switch (E) { @@ -4378,8 +4389,8 @@ function qd() { case n: case o: case r: - case p: case d: + case p: return h; default: switch (h = h && h.$$typeof, h) { @@ -4387,7 +4398,7 @@ function qd() { case i: case c: case w: - case m: + case f: case a: return h; default: @@ -4399,37 +4410,37 @@ function qd() { } } } - return lt.ContextConsumer = i, lt.ContextProvider = a, lt.Element = t, lt.ForwardRef = c, lt.Fragment = n, lt.Lazy = w, lt.Memo = m, lt.Portal = e, lt.Profiler = o, lt.StrictMode = r, lt.Suspense = p, lt.SuspenseList = d, lt.isAsyncMode = function() { + return lt.ContextConsumer = i, lt.ContextProvider = a, lt.Element = t, lt.ForwardRef = c, lt.Fragment = n, lt.Lazy = w, lt.Memo = f, lt.Portal = e, lt.Profiler = o, lt.StrictMode = r, lt.Suspense = d, lt.SuspenseList = p, lt.isAsyncMode = function() { return !1; }, lt.isConcurrentMode = function() { return !1; }, lt.isContextConsumer = function(h) { - return f(h) === i; + return m(h) === i; }, lt.isContextProvider = function(h) { - return f(h) === a; + return m(h) === a; }, lt.isElement = function(h) { return typeof h == "object" && h !== null && h.$$typeof === t; }, lt.isForwardRef = function(h) { - return f(h) === c; + return m(h) === c; }, lt.isFragment = function(h) { - return f(h) === n; + return m(h) === n; }, lt.isLazy = function(h) { - return f(h) === w; + return m(h) === w; }, lt.isMemo = function(h) { - return f(h) === m; + return m(h) === f; }, lt.isPortal = function(h) { - return f(h) === e; + return m(h) === e; }, lt.isProfiler = function(h) { - return f(h) === o; + return m(h) === o; }, lt.isStrictMode = function(h) { - return f(h) === r; + return m(h) === r; }, lt.isSuspense = function(h) { - return f(h) === p; + return m(h) === d; }, lt.isSuspenseList = function(h) { - return f(h) === d; + return m(h) === p; }, lt.isValidElementType = function(h) { - return typeof h == "string" || typeof h == "function" || h === n || h === o || h === r || h === p || h === d || h === g || typeof h == "object" && h !== null && (h.$$typeof === w || h.$$typeof === m || h.$$typeof === a || h.$$typeof === i || h.$$typeof === c || h.$$typeof === v || h.getModuleId !== void 0); - }, lt.typeOf = f, lt; + return typeof h == "string" || typeof h == "function" || h === n || h === o || h === r || h === d || h === p || h === g || typeof h == "object" && h !== null && (h.$$typeof === w || h.$$typeof === f || h.$$typeof === a || h.$$typeof === i || h.$$typeof === c || h.$$typeof === v || h.getModuleId !== void 0); + }, lt.typeOf = m, lt; } var ct = {}; /** @@ -4444,10 +4455,10 @@ var ct = {}; var ga; function Kd() { return ga || (ga = 1, process.env.NODE_ENV !== "production" && function() { - var t = Symbol.for("react.element"), e = Symbol.for("react.portal"), n = Symbol.for("react.fragment"), r = Symbol.for("react.strict_mode"), o = Symbol.for("react.profiler"), a = Symbol.for("react.provider"), i = Symbol.for("react.context"), l = Symbol.for("react.server_context"), c = Symbol.for("react.forward_ref"), p = Symbol.for("react.suspense"), d = Symbol.for("react.suspense_list"), m = Symbol.for("react.memo"), w = Symbol.for("react.lazy"), g = Symbol.for("react.offscreen"), v = !1, f = !1, h = !1, E = !1, _ = !1, C; + var t = Symbol.for("react.element"), e = Symbol.for("react.portal"), n = Symbol.for("react.fragment"), r = Symbol.for("react.strict_mode"), o = Symbol.for("react.profiler"), a = Symbol.for("react.provider"), i = Symbol.for("react.context"), l = Symbol.for("react.server_context"), c = Symbol.for("react.forward_ref"), d = Symbol.for("react.suspense"), p = Symbol.for("react.suspense_list"), f = Symbol.for("react.memo"), w = Symbol.for("react.lazy"), g = Symbol.for("react.offscreen"), v = !1, m = !1, h = !1, E = !1, _ = !1, C; C = Symbol.for("react.module.reference"); function S(j) { - return !!(typeof j == "string" || typeof j == "function" || j === n || j === o || _ || j === r || j === p || j === d || E || j === g || v || f || h || typeof j == "object" && j !== null && (j.$$typeof === w || j.$$typeof === m || j.$$typeof === a || j.$$typeof === i || j.$$typeof === c || // This needs to include all possible module reference object + return !!(typeof j == "string" || typeof j == "function" || j === n || j === o || _ || j === r || j === d || j === p || E || j === g || v || m || h || typeof j == "object" && j !== null && (j.$$typeof === w || j.$$typeof === f || j.$$typeof === a || j.$$typeof === i || j.$$typeof === c || // This needs to include all possible module reference object // types supported by any Flight configuration anywhere since // we don't know which Flight build this will end up being used // with. @@ -4463,8 +4474,8 @@ function Kd() { case n: case o: case r: - case p: case d: + case p: return Ft; default: var ce = Ft && Ft.$$typeof; @@ -4473,7 +4484,7 @@ function Kd() { case i: case c: case w: - case m: + case f: case a: return ce; default: @@ -4485,7 +4496,7 @@ function Kd() { } } } - var I = i, z = a, H = t, O = c, $ = n, k = w, B = m, D = e, J = o, q = r, U = p, tt = d, at = !1, rt = !1; + var I = i, z = a, H = t, O = c, $ = n, k = w, B = f, D = e, J = o, q = r, U = d, tt = p, at = !1, rt = !1; function y(j) { return at || (at = !0, console.warn("The ReactIs.isAsyncMode() alias has been deprecated, and will be removed in React 18+.")), !1; } @@ -4511,7 +4522,7 @@ function Kd() { return b(j) === w; } function G(j) { - return b(j) === m; + return b(j) === f; } function K(j) { return b(j) === e; @@ -4523,10 +4534,10 @@ function Kd() { return b(j) === r; } function A(j) { - return b(j) === p; + return b(j) === d; } function Nt(j) { - return b(j) === d; + return b(j) === p; } ct.ContextConsumer = I, ct.ContextProvider = z, ct.Element = H, ct.ForwardRef = O, ct.Fragment = $, ct.Lazy = k, ct.Memo = B, ct.Portal = D, ct.Profiler = J, ct.StrictMode = q, ct.Suspense = U, ct.SuspenseList = tt, ct.isAsyncMode = y, ct.isConcurrentMode = R, ct.isContextConsumer = L, ct.isContextProvider = F, ct.isElement = V, ct.isForwardRef = W, ct.isFragment = X, ct.isLazy = Y, ct.isMemo = G, ct.isPortal = K, ct.isProfiler = Z, ct.isStrictMode = dt, ct.isSuspense = A, ct.isSuspenseList = Nt, ct.isValidElementType = S, ct.typeOf = b; }()), ct; @@ -4617,14 +4628,14 @@ function ip(t, e) { if (process.env.NODE_ENV === "production") return () => null; const n = e ? P({}, e.propTypes) : null; - return (o) => (a, i, l, c, p, ...d) => { - const m = p || i, w = n == null ? void 0 : n[m]; + return (o) => (a, i, l, c, d, ...p) => { + const f = d || i, w = n == null ? void 0 : n[f]; if (w) { - const g = w(a, i, l, c, p, ...d); + const g = w(a, i, l, c, d, ...p); if (g) return g; } - return typeof a[i] < "u" && !a[o] ? new Error(`The prop \`${m}\` of \`${t}\` can only be used together with the \`${o}\` prop.`) : null; + return typeof a[i] < "u" && !a[o] ? new Error(`The prop \`${f}\` of \`${t}\` can only be used together with the \`${o}\` prop.`) : null; }; } function Wn(t, e) { @@ -4667,15 +4678,15 @@ function rs({ `)); }, [r, n, t]); const { - current: p + current: d } = M.useRef(e); M.useEffect(() => { - !o && p !== e && console.error([`MUI: A component is changing the default ${r} state of an uncontrolled ${n} after being initialized. To suppress this warning opt to use a controlled ${n}.`].join(` + !o && d !== e && console.error([`MUI: A component is changing the default ${r} state of an uncontrolled ${n} after being initialized. To suppress this warning opt to use a controlled ${n}.`].join(` `)); }, [JSON.stringify(e)]); } - const c = M.useCallback((p) => { - o || i(p); + const c = M.useCallback((d) => { + o || i(d); }, []); return [l, c]; } @@ -4902,25 +4913,25 @@ function Sp(t) { function c(w) { return `@media (max-width:${(typeof e[w] == "number" ? e[w] : w) - r / 100}${n})`; } - function p(w, g) { + function d(w, g) { const v = i.indexOf(g); return `@media (min-width:${typeof e[w] == "number" ? e[w] : w}${n}) and (max-width:${(v !== -1 && typeof e[i[v]] == "number" ? e[i[v]] : g) - r / 100}${n})`; } - function d(w) { - return i.indexOf(w) + 1 < i.length ? p(w, i[i.indexOf(w) + 1]) : l(w); + function p(w) { + return i.indexOf(w) + 1 < i.length ? d(w, i[i.indexOf(w) + 1]) : l(w); } - function m(w) { + function f(w) { const g = i.indexOf(w); - return g === 0 ? l(i[1]) : g === i.length - 1 ? c(i[g]) : p(w, i[i.indexOf(w) + 1]).replace("@media", "@media not all and"); + return g === 0 ? l(i[1]) : g === i.length - 1 ? c(i[g]) : d(w, i[i.indexOf(w) + 1]).replace("@media", "@media not all and"); } return P({ keys: i, values: a, up: l, down: c, - between: p, - only: d, - not: m, + between: d, + only: p, + not: f, unit: n }, o); } @@ -5007,10 +5018,10 @@ function yt(t) { } = t, a = (i) => { if (i[e] == null) return null; - const l = i[e], c = i.theme, p = ur(c, r) || {}; - return Qt(i, l, (m) => { - let w = qn(p, o, m); - return m === w && typeof m == "string" && (w = qn(p, o, `${e}${m === "default" ? "" : Wt(m)}`, m)), n === !1 ? w : { + const l = i[e], c = i.theme, d = ur(c, r) || {}; + return Qt(i, l, (f) => { + let w = qn(d, o, f); + return f === w && typeof f == "string" && (w = qn(d, o, `${e}${f === "default" ? "" : Wt(f)}`, f)), n === !1 ? w : { [n]: w }; }); @@ -5562,21 +5573,21 @@ function bu() { }; const { cssProperty: c = n, - themeKey: p, - transform: d, - style: m + themeKey: d, + transform: p, + style: f } = l; if (r == null) return null; - if (p === "typography" && r === "inherit") + if (d === "typography" && r === "inherit") return { [n]: r }; - const w = ur(o, p) || {}; - return m ? m(i) : Qt(i, r, (v) => { - let f = qn(w, d, v); - return v === f && typeof v == "string" && (f = qn(w, d, `${n}${v === "default" ? "" : Wt(v)}`, v)), c === !1 ? f : { - [c]: f + const w = ur(o, d) || {}; + return f ? f(i) : Qt(i, r, (v) => { + let m = qn(w, p, v); + return v === m && typeof v == "string" && (m = qn(w, p, `${n}${v === "default" ? "" : Wt(v)}`, v)), c === !1 ? m : { + [c]: m }; }); } @@ -5590,35 +5601,35 @@ function bu() { return null; const i = (r = a.unstable_sxConfig) != null ? r : Eo; function l(c) { - let p = c; + let d = c; if (typeof c == "function") - p = c(a); + d = c(a); else if (typeof c != "object") return c; - if (!p) + if (!d) return null; - const d = Rp(a.breakpoints), m = Object.keys(d); - let w = d; - return Object.keys(p).forEach((g) => { - const v = gu(p[g], a); + const p = Rp(a.breakpoints), f = Object.keys(p); + let w = p; + return Object.keys(d).forEach((g) => { + const v = gu(d[g], a); if (v != null) if (typeof v == "object") if (i[g]) w = un(w, t(g, v, a, i)); else { - const f = Qt({ + const m = Qt({ theme: a }, v, (h) => ({ [g]: h })); - hu(f, v) ? w[g] = e({ + hu(m, v) ? w[g] = e({ sx: v, theme: a - }) : w = un(w, f); + }) : w = un(w, m); } else w = un(w, t(g, v, a, i)); - }), _p(m, w); + }), _p(f, w); } return Array.isArray(o) ? o.map(l) : l(o); } @@ -5641,7 +5652,7 @@ function To(t = {}, ...e) { spacing: o, shape: a = {} } = t, i = kt(t, yu), l = Sp(n), c = jp(o); - let p = Zt({ + let d = Zt({ breakpoints: l, direction: "ltr", components: {}, @@ -5652,12 +5663,12 @@ function To(t = {}, ...e) { spacing: c, shape: P({}, Cp, a) }, i); - return p.applyStyles = vu, p = e.reduce((d, m) => Zt(d, m), p), p.unstable_sxConfig = P({}, Eo, i == null ? void 0 : i.unstable_sxConfig), p.unstable_sx = function(m) { + return d.applyStyles = vu, d = e.reduce((p, f) => Zt(p, f), d), d.unstable_sxConfig = P({}, Eo, i == null ? void 0 : i.unstable_sxConfig), d.unstable_sx = function(f) { return So({ - sx: m, + sx: f, theme: this }); - }, p; + }, d; } function xu(t) { return Object.keys(t).length === 0; @@ -5711,12 +5722,12 @@ function Hn(t, e) { } = o; let l = kt(o, Eu); return a.forEach((c) => { - let p = !0; - typeof c.props == "function" ? p = c.props(P({ + let d = !0; + typeof c.props == "function" ? d = c.props(P({ ownerState: n - }, r, n)) : Object.keys(c.props).forEach((d) => { - (n == null ? void 0 : n[d]) !== c.props[d] && r[d] !== c.props[d] && (p = !1); - }), p && (Array.isArray(l) || (l = [l]), l.push(typeof c.style == "function" ? c.style(P({ + }, r, n)) : Object.keys(c.props).forEach((p) => { + (n == null ? void 0 : n[p]) !== c.props[p] && r[p] !== c.props[p] && (d = !1); + }), d && (Array.isArray(l) || (l = [l]), l.push(typeof c.style == "function" ? c.style(P({ ownerState: n }, r, n)) : c.style)); }), l; @@ -5739,21 +5750,21 @@ function _u(t = {}) { Dl(i, (b) => b.filter((I) => !(I != null && I.__mui_systemSx))); const { name: c, - slot: p, - skipVariantsResolver: d, - skipSx: m, + slot: d, + skipVariantsResolver: p, + skipSx: f, // TODO v6: remove `lowercaseFirstLetter()` in the next major release // For more details: https://github.com/mui/material-ui/pull/37908 - overridesResolver: w = Ru(Ta(p)) - } = l, g = kt(l, Su), v = d !== void 0 ? d : ( + overridesResolver: w = Ru(Ta(d)) + } = l, g = kt(l, Su), v = p !== void 0 ? p : ( // TODO v6: remove `Root` in the next major release // For more details: https://github.com/mui/material-ui/pull/37908 - p && p !== "Root" && p !== "root" || !1 - ), f = m || !1; + d && d !== "Root" && d !== "root" || !1 + ), m = f || !1; let h; - process.env.NODE_ENV !== "production" && c && (h = `${c}-${Ta(p || "Root")}`); + process.env.NODE_ENV !== "production" && c && (h = `${c}-${Ta(d || "Root")}`); let E = Gn; - p === "Root" || p === "root" ? E = r : p ? E = o : Cu(i) && (E = void 0); + d === "Root" || d === "root" ? E = r : d ? E = o : Cu(i) && (E = void 0); const _ = Al(i, P({ shouldForwardProp: E, label: h @@ -5790,7 +5801,7 @@ function _u(t = {}) { }, P({}, k, { theme: D })); - }), f || H.push(a); + }), m || H.push(a); const O = H.length - I.length; if (Array.isArray(b) && O > 0) { const k = new Array(O).fill(""); @@ -5799,7 +5810,7 @@ function _u(t = {}) { const $ = _(z, ...H); if (process.env.NODE_ENV !== "production") { let k; - c && (k = `${c}${Wt(p || "")}`), k === void 0 && (k = `Styled(${Qd(i)})`), $.displayName = k; + c && (k = `${c}${Wt(d || "")}`), k === void 0 && (k = `Styled(${Qd(i)})`), $.displayName = k; } return i.muiName && ($.muiName = i.muiName), $; }; @@ -5872,7 +5883,7 @@ function Au(t) { t = Ne(t); const { values: e - } = t, n = e[0], r = e[1] / 100, o = e[2] / 100, a = r * Math.min(o, 1 - o), i = (p, d = (p + n / 30) % 12) => o - a * Math.max(Math.min(d - 3, 9 - d, 1), -1); + } = t, n = e[0], r = e[1] / 100, o = e[2] / 100, a = r * Math.min(o, 1 - o), i = (d, p = (d + n / 30) % 12) => o - a * Math.max(Math.min(p - 3, 9 - p, 1), -1); let l = "rgb"; const c = [Math.round(i(0) * 255), Math.round(i(8) * 255), Math.round(i(4) * 255)]; return t.type === "hsla" && (l += "a", c.push(e[3])), yr({ @@ -6173,29 +6184,29 @@ function tw(t) { mode: e = "light", contrastThreshold: n = 3, tonalOffset: r = 0.2 - } = t, o = kt(t, Yu), a = t.primary || Wu(e), i = t.secondary || qu(e), l = t.error || Ku(e), c = t.info || Ju(e), p = t.success || Zu(e), d = t.warning || Qu(e); - function m(f) { - const h = Oa(f, Fr.text.primary) >= n ? Fr.text.primary : Ra.text.primary; + } = t, o = kt(t, Yu), a = t.primary || Wu(e), i = t.secondary || qu(e), l = t.error || Ku(e), c = t.info || Ju(e), d = t.success || Zu(e), p = t.warning || Qu(e); + function f(m) { + const h = Oa(m, Fr.text.primary) >= n ? Fr.text.primary : Ra.text.primary; if (process.env.NODE_ENV !== "production") { - const E = Oa(f, h); - E < 3 && console.error([`MUI: The contrast ratio of ${E}:1 for ${h} on ${f}`, "falls below the WCAG recommended absolute minimum contrast ratio of 3:1.", "https://www.w3.org/TR/2008/REC-WCAG20-20081211/#visual-audio-contrast-contrast"].join(` + const E = Oa(m, h); + E < 3 && console.error([`MUI: The contrast ratio of ${E}:1 for ${h} on ${m}`, "falls below the WCAG recommended absolute minimum contrast ratio of 3:1.", "https://www.w3.org/TR/2008/REC-WCAG20-20081211/#visual-audio-contrast-contrast"].join(` `)); } return h; } const w = ({ - color: f, + color: m, name: h, mainShade: E = 500, lightShade: _ = 300, darkShade: C = 700 }) => { - if (f = P({}, f), !f.main && f[E] && (f.main = f[E]), !f.hasOwnProperty("main")) + if (m = P({}, m), !m.main && m[E] && (m.main = m[E]), !m.hasOwnProperty("main")) throw new Error(process.env.NODE_ENV !== "production" ? `MUI: The color${h ? ` (${h})` : ""} provided to augmentColor(color) is invalid. The color object needs to have a \`main\` property or a \`${E}\` property.` : Ve(11, h ? ` (${h})` : "", E)); - if (typeof f.main != "string") + if (typeof m.main != "string") throw new Error(process.env.NODE_ENV !== "production" ? `MUI: The color${h ? ` (${h})` : ""} provided to augmentColor(color) is invalid. -\`color.main\` should be a string, but \`${JSON.stringify(f.main)}\` was provided instead. +\`color.main\` should be a string, but \`${JSON.stringify(m.main)}\` was provided instead. Did you intend to use one of the following approaches? @@ -6207,8 +6218,8 @@ const theme1 = createTheme({ palette: { const theme2 = createTheme({ palette: { primary: { main: green[500] }, -} });` : Ve(12, h ? ` (${h})` : "", JSON.stringify(f.main))); - return _a(f, "light", _, r), _a(f, "dark", C, r), f.contrastText || (f.contrastText = m(f.main)), f; +} });` : Ve(12, h ? ` (${h})` : "", JSON.stringify(m.main))); + return _a(m, "light", _, r), _a(m, "dark", C, r), m.contrastText || (m.contrastText = f(m.main)), m; }, g = { dark: Fr, light: Ra @@ -6239,7 +6250,7 @@ const theme2 = createTheme({ palette: { }), // The colors used to represent potentially dangerous actions or important messages. warning: w({ - color: d, + color: p, name: "warning" }), // The colors used to present information to the user that is neutral and not necessarily important. @@ -6249,7 +6260,7 @@ const theme2 = createTheme({ palette: { }), // The colors used to indicate the successful completion of an action that user triggered. success: w({ - color: p, + color: d, name: "success" }), // The grey colors. @@ -6258,7 +6269,7 @@ const theme2 = createTheme({ palette: { // the background and the text. contrastThreshold: n, // Takes a background color and returns the text color that maximizes the contrast. - getContrastText: m, + getContrastText: f, // Generate a rich color object. augmentColor: w, // Used by the functions below to shift a color's luminance by approximately @@ -6286,13 +6297,13 @@ function rw(t, e) { fontWeightBold: c = 700, // Tell MUI what's the font-size on the html element. // 16px is the default font-size used by browsers. - htmlFontSize: p = 16, + htmlFontSize: d = 16, // Apply the CSS properties to all the variants. - allVariants: d, - pxToRem: m + allVariants: p, + pxToRem: f } = n, w = kt(n, ew); - process.env.NODE_ENV !== "production" && (typeof o != "number" && console.error("MUI: `fontSize` is required to be a number."), typeof p != "number" && console.error("MUI: `htmlFontSize` is required to be a number.")); - const g = o / 14, v = m || ((E) => `${E / p * g}rem`), f = (E, _, C, S, b) => P({ + process.env.NODE_ENV !== "production" && (typeof o != "number" && console.error("MUI: `fontSize` is required to be a number."), typeof d != "number" && console.error("MUI: `htmlFontSize` is required to be a number.")); + const g = o / 14, v = f || ((E) => `${E / d * g}rem`), m = (E, _, C, S, b) => P({ fontFamily: r, fontWeight: E, fontSize: v(_), @@ -6300,20 +6311,20 @@ function rw(t, e) { lineHeight: C }, r === $a ? { letterSpacing: `${nw(S / _)}em` - } : {}, b, d), h = { - h1: f(a, 96, 1.167, -1.5), - h2: f(a, 60, 1.2, -0.5), - h3: f(i, 48, 1.167, 0), - h4: f(i, 34, 1.235, 0.25), - h5: f(i, 24, 1.334, 0), - h6: f(l, 20, 1.6, 0.15), - subtitle1: f(i, 16, 1.75, 0.15), - subtitle2: f(l, 14, 1.57, 0.1), - body1: f(i, 16, 1.5, 0.15), - body2: f(i, 14, 1.43, 0.15), - button: f(l, 14, 1.75, 0.4, Pa), - caption: f(i, 12, 1.66, 0.4), - overline: f(i, 12, 2.66, 1, Pa), + } : {}, b, p), h = { + h1: m(a, 96, 1.167, -1.5), + h2: m(a, 60, 1.2, -0.5), + h3: m(i, 48, 1.167, 0), + h4: m(i, 34, 1.235, 0.25), + h5: m(i, 24, 1.334, 0), + h6: m(l, 20, 1.6, 0.15), + subtitle1: m(i, 16, 1.75, 0.15), + subtitle2: m(l, 14, 1.57, 0.1), + body1: m(i, 16, 1.5, 0.15), + body2: m(i, 14, 1.43, 0.15), + button: m(l, 14, 1.75, 0.4, Pa), + caption: m(i, 12, 1.66, 0.4), + overline: m(i, 12, 2.66, 1, Pa), // TODO v6: Remove handling of 'inherit' variant from the theme as it is already handled in Material UI's Typography component. Also, remember to remove the associated types. inherit: { fontFamily: "inherit", @@ -6324,7 +6335,7 @@ function rw(t, e) { } }; return Zt(P({ - htmlFontSize: p, + htmlFontSize: d, pxToRem: v, fontFamily: r, fontSize: o, @@ -6382,13 +6393,13 @@ function ww(t) { duration: i = n.standard, easing: l = e.easeInOut, delay: c = 0 - } = a, p = kt(a, cw); + } = a, d = kt(a, cw); if (process.env.NODE_ENV !== "production") { - const d = (w) => typeof w == "string", m = (w) => !isNaN(parseFloat(w)); - !d(o) && !Array.isArray(o) && console.error('MUI: Argument "props" must be a string or Array.'), !m(i) && !d(i) && console.error(`MUI: Argument "duration" must be a number or a string but found ${i}.`), d(l) || console.error('MUI: Argument "easing" must be a string.'), !m(c) && !d(c) && console.error('MUI: Argument "delay" must be a number or a string.'), typeof a != "object" && console.error(["MUI: Secong argument of transition.create must be an object.", "Arguments should be either `create('prop1', options)` or `create(['prop1', 'prop2'], options)`"].join(` -`)), Object.keys(p).length !== 0 && console.error(`MUI: Unrecognized argument(s) [${Object.keys(p).join(",")}].`); + const p = (w) => typeof w == "string", f = (w) => !isNaN(parseFloat(w)); + !p(o) && !Array.isArray(o) && console.error('MUI: Argument "props" must be a string or Array.'), !f(i) && !p(i) && console.error(`MUI: Argument "duration" must be a number or a string but found ${i}.`), p(l) || console.error('MUI: Argument "easing" must be a string.'), !f(c) && !p(c) && console.error('MUI: Argument "delay" must be a number or a string.'), typeof a != "object" && console.error(["MUI: Secong argument of transition.create must be an object.", "Arguments should be either `create('prop1', options)` or `create(['prop1', 'prop2'], options)`"].join(` +`)), Object.keys(d).length !== 0 && console.error(`MUI: Unrecognized argument(s) [${Object.keys(d).join(",")}].`); } - return (Array.isArray(o) ? o : [o]).map((d) => `${d} ${typeof i == "string" ? i : Ia(i)} ${l} ${typeof c == "string" ? c : Ia(c)}`).join(","); + return (Array.isArray(o) ? o : [o]).map((p) => `${p} ${typeof i == "string" ? i : Ia(i)} ${l} ${typeof c == "string" ? c : Ia(c)}`).join(","); } }, t, { easing: e, @@ -6415,7 +6426,7 @@ function gw(t = {}, ...e) { if (t.vars) throw new Error(process.env.NODE_ENV !== "production" ? "MUI: `vars` is a private field used for CSS variables support.\nPlease use another name." : Ve(18)); const l = tw(r), c = To(t); - let p = Zt(c, { + let d = Zt(c, { mixins: Bu(c.breakpoints, n), palette: l, // Don't use [...shadows] until you've verified its transpiled code is not invoking the iterator protocol. @@ -6424,17 +6435,17 @@ function gw(t = {}, ...e) { transitions: ww(o), zIndex: P({}, mw) }); - if (p = Zt(p, i), p = e.reduce((d, m) => Zt(d, m), p), process.env.NODE_ENV !== "production") { - const d = ["active", "checked", "completed", "disabled", "error", "expanded", "focused", "focusVisible", "required", "selected"], m = (w, g) => { + if (d = Zt(d, i), d = e.reduce((p, f) => Zt(p, f), d), process.env.NODE_ENV !== "production") { + const p = ["active", "checked", "completed", "disabled", "error", "expanded", "focused", "focusVisible", "required", "selected"], f = (w, g) => { let v; for (v in w) { - const f = w[v]; - if (d.indexOf(v) !== -1 && Object.keys(f).length > 0) { + const m = w[v]; + if (p.indexOf(v) !== -1 && Object.keys(m).length > 0) { if (process.env.NODE_ENV !== "production") { const h = pr("", v); console.error([`MUI: The \`${g}\` component increases the CSS specificity of the \`${v}\` internal state.`, "You can not override it like this: ", JSON.stringify(w, null, 2), "", `Instead, you need to use the '&.${h}' syntax:`, JSON.stringify({ root: { - [`&.${h}`]: f + [`&.${h}`]: m } }, null, 2), "", "https://mui.com/r/state-classes-guide"].join(` `)); @@ -6443,17 +6454,17 @@ function gw(t = {}, ...e) { } } }; - Object.keys(p.components).forEach((w) => { - const g = p.components[w].styleOverrides; - g && w.indexOf("Mui") === 0 && m(g, w); + Object.keys(d.components).forEach((w) => { + const g = d.components[w].styleOverrides; + g && w.indexOf("Mui") === 0 && f(g, w); }); } - return p.unstable_sxConfig = P({}, Eo, i == null ? void 0 : i.unstable_sxConfig), p.unstable_sx = function(m) { + return d.unstable_sxConfig = P({}, Eo, i == null ? void 0 : i.unstable_sxConfig), d.unstable_sx = function(f) { return So({ - sx: m, + sx: f, theme: this }); - }, p; + }, d; } const bw = gw(), Oo = bw, Ro = "$$material"; function _o({ @@ -6498,7 +6509,7 @@ const Nw = ["children", "className", "color", "component", "fontSize", "htmlColo theme: t, ownerState: e }) => { - var n, r, o, a, i, l, c, p, d, m, w, g, v; + var n, r, o, a, i, l, c, d, p, f, w, g, v; return { userSelect: "none", width: "1em", @@ -6515,10 +6526,10 @@ const Nw = ["children", "className", "color", "component", "fontSize", "htmlColo inherit: "inherit", small: ((a = t.typography) == null || (i = a.pxToRem) == null ? void 0 : i.call(a, 20)) || "1.25rem", medium: ((l = t.typography) == null || (c = l.pxToRem) == null ? void 0 : c.call(l, 24)) || "1.5rem", - large: ((p = t.typography) == null || (d = p.pxToRem) == null ? void 0 : d.call(p, 35)) || "2.1875rem" + large: ((d = t.typography) == null || (p = d.pxToRem) == null ? void 0 : p.call(d, 35)) || "2.1875rem" }[e.fontSize], // TODO v5 deprecate, v6 remove for sx - color: (m = (w = (t.vars || t).palette) == null || (w = w[e.color]) == null ? void 0 : w.main) != null ? m : { + color: (f = (w = (t.vars || t).palette) == null || (w = w[e.color]) == null ? void 0 : w.main) != null ? f : { action: (g = (t.vars || t).palette) == null || (g = g.action) == null ? void 0 : g.active, disabled: (v = (t.vars || t).palette) == null || (v = v.action) == null ? void 0 : v.disabled, inherit: void 0 @@ -6534,33 +6545,33 @@ const Nw = ["children", "className", "color", "component", "fontSize", "htmlColo color: i = "inherit", component: l = "svg", fontSize: c = "medium", - htmlColor: p, - inheritViewBox: d = !1, - titleAccess: m, + htmlColor: d, + inheritViewBox: p = !1, + titleAccess: f, viewBox: w = "0 0 24 24" - } = r, g = kt(r, Nw), v = /* @__PURE__ */ M.isValidElement(o) && o.type === "svg", f = P({}, r, { + } = r, g = kt(r, Nw), v = /* @__PURE__ */ M.isValidElement(o) && o.type === "svg", m = P({}, r, { color: i, component: l, fontSize: c, instanceFontSize: e.fontSize, - inheritViewBox: d, + inheritViewBox: p, viewBox: w, hasSvgAsChild: v }), h = {}; - d || (h.viewBox = w); - const E = kw(f); + p || (h.viewBox = w); + const E = kw(m); return /* @__PURE__ */ N(Ew, P({ as: l, className: be(E.root, a), focusable: "false", - color: p, - "aria-hidden": m ? void 0 : !0, - role: m ? "img" : void 0, + color: d, + "aria-hidden": f ? void 0 : !0, + role: f ? "img" : void 0, ref: n }, h, g, v && o.props, { - ownerState: f, - children: [v ? o.props.children : o, m ? /* @__PURE__ */ s("title", { - children: m + ownerState: m, + children: [v ? o.props.children : o, f ? /* @__PURE__ */ s("title", { + children: f }) : null] })); }); @@ -6743,16 +6754,16 @@ function jw(t) { className: a } = t; if (!e) { - const g = be(n == null ? void 0 : n.className, a, o == null ? void 0 : o.className, r == null ? void 0 : r.className), v = P({}, n == null ? void 0 : n.style, o == null ? void 0 : o.style, r == null ? void 0 : r.style), f = P({}, n, o, r); - return g.length > 0 && (f.className = g), Object.keys(v).length > 0 && (f.style = v), { - props: f, + const g = be(n == null ? void 0 : n.className, a, o == null ? void 0 : o.className, r == null ? void 0 : r.className), v = P({}, n == null ? void 0 : n.style, o == null ? void 0 : o.style, r == null ? void 0 : r.style), m = P({}, n, o, r); + return g.length > 0 && (m.className = g), Object.keys(v).length > 0 && (m.style = v), { + props: m, internalRef: void 0 }; } - const i = Dw(P({}, o, r)), l = Da(r), c = Da(o), p = e(i), d = be(p == null ? void 0 : p.className, n == null ? void 0 : n.className, a, o == null ? void 0 : o.className, r == null ? void 0 : r.className), m = P({}, p == null ? void 0 : p.style, n == null ? void 0 : n.style, o == null ? void 0 : o.style, r == null ? void 0 : r.style), w = P({}, p, n, c, l); - return d.length > 0 && (w.className = d), Object.keys(m).length > 0 && (w.style = m), { + const i = Dw(P({}, o, r)), l = Da(r), c = Da(o), d = e(i), p = be(d == null ? void 0 : d.className, n == null ? void 0 : n.className, a, o == null ? void 0 : o.className, r == null ? void 0 : r.className), f = P({}, d == null ? void 0 : d.style, n == null ? void 0 : n.style, o == null ? void 0 : o.style, r == null ? void 0 : r.style), w = P({}, d, n, c, l); + return p.length > 0 && (w.className = p), Object.keys(f).length > 0 && (w.style = f), { props: w, - internalRef: p.ref + internalRef: d.ref }; } const Vw = ["elementType", "externalSlotProps", "ownerState", "skipResolvingSlotProps"]; @@ -6765,12 +6776,12 @@ function zw(t) { skipResolvingSlotProps: a = !1 } = t, i = kt(t, Vw), l = a ? {} : Bw(r, o), { props: c, - internalRef: p + internalRef: d } = jw(P({}, i, { externalSlotProps: l - })), d = xe(p, l == null ? void 0 : l.ref, (e = t.additionalProps) == null ? void 0 : e.ref); + })), p = xe(d, l == null ? void 0 : l.ref, (e = t.additionalProps) == null ? void 0 : e.ref); return ln(n, P({}, c, { - ref: d + ref: p }), o); } const gs = "base"; @@ -6808,10 +6819,10 @@ const Kn = /* @__PURE__ */ M.forwardRef(function(e, n) { }; }, [n, i, a]), a) { if (/* @__PURE__ */ M.isValidElement(r)) { - const p = { + const d = { ref: c }; - return /* @__PURE__ */ M.cloneElement(r, p); + return /* @__PURE__ */ M.cloneElement(r, d); } return /* @__PURE__ */ s(M.Fragment, { children: r @@ -6904,8 +6915,8 @@ function of(t) { }; return Object.assign(e.elements.popper.style, n.popper), e.styles = n, e.elements.arrow && Object.assign(e.elements.arrow.style, n.arrow), function() { Object.keys(e.elements).forEach(function(r) { - var o = e.elements[r], a = e.attributes[r] || {}, i = Object.keys(e.styles.hasOwnProperty(r) ? e.styles[r] : n[r]), l = i.reduce(function(c, p) { - return c[p] = "", c; + var o = e.elements[r], a = e.attributes[r] || {}, i = Object.keys(e.styles.hasOwnProperty(r) ? e.styles[r] : n[r]), l = i.reduce(function(c, d) { + return c[d] = "", c; }, {}); !jt(o) || !qt(o) || (Object.assign(o.style, l), Object.keys(a).forEach(function(c) { o.removeAttribute(c); @@ -6938,16 +6949,16 @@ function Ue(t, e, n) { e === void 0 && (e = !1), n === void 0 && (n = !1); var r = t.getBoundingClientRect(), o = 1, a = 1; e && jt(t) && (o = t.offsetWidth > 0 && Fe(r.width) / t.offsetWidth || 1, a = t.offsetHeight > 0 && Fe(r.height) / t.offsetHeight || 1); - var i = ke(t) ? Mt(t) : window, l = i.visualViewport, c = !xs() && n, p = (r.left + (c && l ? l.offsetLeft : 0)) / o, d = (r.top + (c && l ? l.offsetTop : 0)) / a, m = r.width / o, w = r.height / a; + var i = ke(t) ? Mt(t) : window, l = i.visualViewport, c = !xs() && n, d = (r.left + (c && l ? l.offsetLeft : 0)) / o, p = (r.top + (c && l ? l.offsetTop : 0)) / a, f = r.width / o, w = r.height / a; return { - width: m, + width: f, height: w, - top: d, - right: p + m, - bottom: d + w, - left: p, - x: p, - y: d + top: p, + right: d + f, + bottom: p + w, + left: d, + x: d, + y: p }; } function Ao(t) { @@ -7054,9 +7065,9 @@ var df = function(e, n) { })) : e, Es(typeof e != "number" ? e : Ss(e, _n)); }; function pf(t) { - var e, n = t.state, r = t.name, o = t.options, a = n.elements.arrow, i = n.modifiersData.popperOffsets, l = Yt(n.placement), c = Mo(l), p = [Ot, zt].indexOf(l) >= 0, d = p ? "height" : "width"; + var e, n = t.state, r = t.name, o = t.options, a = n.elements.arrow, i = n.modifiersData.popperOffsets, l = Yt(n.placement), c = Mo(l), d = [Ot, zt].indexOf(l) >= 0, p = d ? "height" : "width"; if (!(!a || !i)) { - var m = df(o.padding, n), w = Ao(a), g = c === "y" ? Ct : Ot, v = c === "y" ? Vt : zt, f = n.rects.reference[d] + n.rects.reference[c] - i[c] - n.rects.popper[d], h = i[c] - n.rects.reference[c], E = Pn(a), _ = E ? c === "y" ? E.clientHeight || 0 : E.clientWidth || 0 : 0, C = f / 2 - h / 2, S = m[g], b = _ - w[d] - m[v], I = _ / 2 - w[d] / 2 + C, z = wn(S, I, b), H = c; + var f = df(o.padding, n), w = Ao(a), g = c === "y" ? Ct : Ot, v = c === "y" ? Vt : zt, m = n.rects.reference[p] + n.rects.reference[c] - i[c] - n.rects.popper[p], h = i[c] - n.rects.reference[c], E = Pn(a), _ = E ? c === "y" ? E.clientHeight || 0 : E.clientWidth || 0 : 0, C = m / 2 - h / 2, S = f[g], b = _ - w[p] - f[v], I = _ / 2 - w[p] / 2 + C, z = wn(S, I, b), H = c; n.modifiersData[r] = (e = {}, e[H] = z, e.centerOffset = z - I, e); } } @@ -7090,28 +7101,28 @@ function mf(t, e) { }; } function Va(t) { - var e, n = t.popper, r = t.popperRect, o = t.placement, a = t.variation, i = t.offsets, l = t.position, c = t.gpuAcceleration, p = t.adaptive, d = t.roundOffsets, m = t.isFixed, w = i.x, g = w === void 0 ? 0 : w, v = i.y, f = v === void 0 ? 0 : v, h = typeof d == "function" ? d({ + var e, n = t.popper, r = t.popperRect, o = t.placement, a = t.variation, i = t.offsets, l = t.position, c = t.gpuAcceleration, d = t.adaptive, p = t.roundOffsets, f = t.isFixed, w = i.x, g = w === void 0 ? 0 : w, v = i.y, m = v === void 0 ? 0 : v, h = typeof p == "function" ? p({ x: g, - y: f + y: m }) : { x: g, - y: f + y: m }; - g = h.x, f = h.y; + g = h.x, m = h.y; var E = i.hasOwnProperty("x"), _ = i.hasOwnProperty("y"), C = Ot, S = Ct, b = window; - if (p) { + if (d) { var I = Pn(n), z = "clientHeight", H = "clientWidth"; if (I === Mt(n) && (I = le(n), te(I).position !== "static" && l === "absolute" && (z = "scrollHeight", H = "scrollWidth")), I = I, o === Ct || (o === Ot || o === zt) && a === Nn) { S = Vt; - var O = m && I === b && b.visualViewport ? b.visualViewport.height : ( + var O = f && I === b && b.visualViewport ? b.visualViewport.height : ( // $FlowFixMe[prop-missing] I[z] ); - f -= O - r.height, f *= c ? 1 : -1; + m -= O - r.height, m *= c ? 1 : -1; } if (o === Ot || (o === Ct || o === Vt) && a === Nn) { C = zt; - var $ = m && I === b && b.visualViewport ? b.visualViewport.width : ( + var $ = f && I === b && b.visualViewport ? b.visualViewport.width : ( // $FlowFixMe[prop-missing] I[H] ); @@ -7120,21 +7131,21 @@ function Va(t) { } var k = Object.assign({ position: l - }, p && ff), B = d === !0 ? mf({ + }, d && ff), B = p === !0 ? mf({ x: g, - y: f + y: m }, Mt(n)) : { x: g, - y: f + y: m }; - if (g = B.x, f = B.y, c) { + if (g = B.x, m = B.y, c) { var D; - return Object.assign({}, k, (D = {}, D[S] = _ ? "0" : "", D[C] = E ? "0" : "", D.transform = (b.devicePixelRatio || 1) <= 1 ? "translate(" + g + "px, " + f + "px)" : "translate3d(" + g + "px, " + f + "px, 0)", D)); + return Object.assign({}, k, (D = {}, D[S] = _ ? "0" : "", D[C] = E ? "0" : "", D.transform = (b.devicePixelRatio || 1) <= 1 ? "translate(" + g + "px, " + m + "px)" : "translate3d(" + g + "px, " + m + "px, 0)", D)); } - return Object.assign({}, k, (e = {}, e[S] = _ ? f + "px" : "", e[C] = E ? g + "px" : "", e.transform = "", e)); + return Object.assign({}, k, (e = {}, e[S] = _ ? m + "px" : "", e[C] = E ? g + "px" : "", e.transform = "", e)); } function hf(t) { - var e = t.state, n = t.options, r = n.gpuAcceleration, o = r === void 0 ? !0 : r, a = n.adaptive, i = a === void 0 ? !0 : a, l = n.roundOffsets, c = l === void 0 ? !0 : l, p = { + var e = t.state, n = t.options, r = n.gpuAcceleration, o = r === void 0 ? !0 : r, a = n.adaptive, i = a === void 0 ? !0 : a, l = n.roundOffsets, c = l === void 0 ? !0 : l, d = { placement: Yt(e.placement), variation: Ge(e.placement), popper: e.elements.popper, @@ -7142,12 +7153,12 @@ function hf(t) { gpuAcceleration: o, isFixed: e.options.strategy === "fixed" }; - e.modifiersData.popperOffsets != null && (e.styles.popper = Object.assign({}, e.styles.popper, Va(Object.assign({}, p, { + e.modifiersData.popperOffsets != null && (e.styles.popper = Object.assign({}, e.styles.popper, Va(Object.assign({}, d, { offsets: e.modifiersData.popperOffsets, position: e.options.strategy, adaptive: i, roundOffsets: c - })))), e.modifiersData.arrow != null && (e.styles.arrow = Object.assign({}, e.styles.arrow, Va(Object.assign({}, p, { + })))), e.modifiersData.arrow != null && (e.styles.arrow = Object.assign({}, e.styles.arrow, Va(Object.assign({}, d, { offsets: e.modifiersData.arrow, position: "absolute", adaptive: !1, @@ -7167,12 +7178,12 @@ var zn = { passive: !0 }; function bf(t) { - var e = t.state, n = t.instance, r = t.options, o = r.scroll, a = o === void 0 ? !0 : o, i = r.resize, l = i === void 0 ? !0 : i, c = Mt(e.elements.popper), p = [].concat(e.scrollParents.reference, e.scrollParents.popper); - return a && p.forEach(function(d) { - d.addEventListener("scroll", n.update, zn); + var e = t.state, n = t.instance, r = t.options, o = r.scroll, a = o === void 0 ? !0 : o, i = r.resize, l = i === void 0 ? !0 : i, c = Mt(e.elements.popper), d = [].concat(e.scrollParents.reference, e.scrollParents.popper); + return a && d.forEach(function(p) { + p.addEventListener("scroll", n.update, zn); }), l && c.addEventListener("resize", n.update, zn), function() { - a && p.forEach(function(d) { - d.removeEventListener("scroll", n.update, zn); + a && d.forEach(function(p) { + p.removeEventListener("scroll", n.update, zn); }), l && c.removeEventListener("resize", n.update, zn); }; } @@ -7219,8 +7230,8 @@ function Nf(t, e) { var n = Mt(t), r = le(t), o = n.visualViewport, a = r.clientWidth, i = r.clientHeight, l = 0, c = 0; if (o) { a = o.width, i = o.height; - var p = xs(); - (p || !p && e === "fixed") && (l = o.offsetLeft, c = o.offsetTop); + var d = xs(); + (d || !d && e === "fixed") && (l = o.offsetLeft, c = o.offsetTop); } return { width: a, @@ -7276,9 +7287,9 @@ function Sf(t) { }) : []; } function Tf(t, e, n, r) { - var o = e === "clippingParents" ? Sf(t) : [].concat(e), a = [].concat(o, [n]), i = a[0], l = a.reduce(function(c, p) { - var d = La(t, p, r); - return c.top = ve(d.top, c.top), c.right = Jn(d.right, c.right), c.bottom = Jn(d.bottom, c.bottom), c.left = ve(d.left, c.left), c; + var o = e === "clippingParents" ? Sf(t) : [].concat(e), a = [].concat(o, [n]), i = a[0], l = a.reduce(function(c, d) { + var p = La(t, d, r); + return c.top = ve(p.top, c.top), c.right = Jn(p.right, c.right), c.bottom = Jn(p.bottom, c.bottom), c.left = ve(p.left, c.left), c; }, La(t, i, r)); return l.width = l.right - l.left, l.height = l.bottom - l.top, l.x = l.left, l.y = l.top, l; } @@ -7315,15 +7326,15 @@ function Cs(t) { y: e.y }; } - var p = o ? Mo(o) : null; - if (p != null) { - var d = p === "y" ? "height" : "width"; + var d = o ? Mo(o) : null; + if (d != null) { + var p = d === "y" ? "height" : "width"; switch (a) { case Le: - c[p] = c[p] - (e[d] / 2 - n[d] / 2); + c[d] = c[d] - (e[p] / 2 - n[p] / 2); break; case Nn: - c[p] = c[p] + (e[d] / 2 - n[d] / 2); + c[d] = c[d] + (e[p] / 2 - n[p] / 2); break; } } @@ -7331,7 +7342,7 @@ function Cs(t) { } function kn(t, e) { e === void 0 && (e = {}); - var n = e, r = n.placement, o = r === void 0 ? t.placement : r, a = n.strategy, i = a === void 0 ? t.strategy : a, l = n.boundary, c = l === void 0 ? Hw : l, p = n.rootBoundary, d = p === void 0 ? vs : p, m = n.elementContext, w = m === void 0 ? rn : m, g = n.altBoundary, v = g === void 0 ? !1 : g, f = n.padding, h = f === void 0 ? 0 : f, E = Es(typeof h != "number" ? h : Ss(h, _n)), _ = w === rn ? Xw : rn, C = t.rects.popper, S = t.elements[v ? _ : w], b = Tf(ke(S) ? S : S.contextElement || le(t.elements.popper), c, d, i), I = Ue(t.elements.reference), z = Cs({ + var n = e, r = n.placement, o = r === void 0 ? t.placement : r, a = n.strategy, i = a === void 0 ? t.strategy : a, l = n.boundary, c = l === void 0 ? Hw : l, d = n.rootBoundary, p = d === void 0 ? vs : d, f = n.elementContext, w = f === void 0 ? rn : f, g = n.altBoundary, v = g === void 0 ? !1 : g, m = n.padding, h = m === void 0 ? 0 : m, E = Es(typeof h != "number" ? h : Ss(h, _n)), _ = w === rn ? Xw : rn, C = t.rects.popper, S = t.elements[v ? _ : w], b = Tf(ke(S) ? S : S.contextElement || le(t.elements.popper), c, p, i), I = Ue(t.elements.reference), z = Cs({ reference: I, element: C, strategy: "absolute", @@ -7353,22 +7364,22 @@ function kn(t, e) { } function Cf(t, e) { e === void 0 && (e = {}); - var n = e, r = n.placement, o = n.boundary, a = n.rootBoundary, i = n.padding, l = n.flipVariations, c = n.allowedAutoPlacements, p = c === void 0 ? ys : c, d = Ge(r), m = d ? l ? Ba : Ba.filter(function(v) { - return Ge(v) === d; - }) : _n, w = m.filter(function(v) { - return p.indexOf(v) >= 0; + var n = e, r = n.placement, o = n.boundary, a = n.rootBoundary, i = n.padding, l = n.flipVariations, c = n.allowedAutoPlacements, d = c === void 0 ? ys : c, p = Ge(r), f = p ? l ? Ba : Ba.filter(function(v) { + return Ge(v) === p; + }) : _n, w = f.filter(function(v) { + return d.indexOf(v) >= 0; }); - w.length === 0 && (w = m); - var g = w.reduce(function(v, f) { - return v[f] = kn(t, { - placement: f, + w.length === 0 && (w = f); + var g = w.reduce(function(v, m) { + return v[m] = kn(t, { + placement: m, boundary: o, rootBoundary: a, padding: i - })[Yt(f)], v; + })[Yt(m)], v; }, {}); - return Object.keys(g).sort(function(v, f) { - return g[v] - g[f]; + return Object.keys(g).sort(function(v, m) { + return g[v] - g[m]; }); } function Of(t) { @@ -7380,22 +7391,22 @@ function Of(t) { function Rf(t) { var e = t.state, n = t.options, r = t.name; if (!e.modifiersData[r]._skip) { - for (var o = n.mainAxis, a = o === void 0 ? !0 : o, i = n.altAxis, l = i === void 0 ? !0 : i, c = n.fallbackPlacements, p = n.padding, d = n.boundary, m = n.rootBoundary, w = n.altBoundary, g = n.flipVariations, v = g === void 0 ? !0 : g, f = n.allowedAutoPlacements, h = e.options.placement, E = Yt(h), _ = E === h, C = c || (_ || !v ? [Xn(h)] : Of(h)), S = [h].concat(C).reduce(function(V, W) { + for (var o = n.mainAxis, a = o === void 0 ? !0 : o, i = n.altAxis, l = i === void 0 ? !0 : i, c = n.fallbackPlacements, d = n.padding, p = n.boundary, f = n.rootBoundary, w = n.altBoundary, g = n.flipVariations, v = g === void 0 ? !0 : g, m = n.allowedAutoPlacements, h = e.options.placement, E = Yt(h), _ = E === h, C = c || (_ || !v ? [Xn(h)] : Of(h)), S = [h].concat(C).reduce(function(V, W) { return V.concat(Yt(W) === $o ? Cf(e, { placement: W, - boundary: d, - rootBoundary: m, - padding: p, + boundary: p, + rootBoundary: f, + padding: d, flipVariations: v, - allowedAutoPlacements: f + allowedAutoPlacements: m }) : W); }, []), b = e.rects.reference, I = e.rects.popper, z = /* @__PURE__ */ new Map(), H = !0, O = S[0], $ = 0; $ < S.length; $++) { var k = S[$], B = Yt(k), D = Ge(k) === Le, J = [Ct, Vt].indexOf(B) >= 0, q = J ? "width" : "height", U = kn(e, { placement: k, - boundary: d, - rootBoundary: m, + boundary: p, + rootBoundary: f, altBoundary: w, - padding: p + padding: d }), tt = J ? D ? zt : Ot : D ? Vt : Ct; b[q] > I[q] && (tt = Xn(tt)); var at = Xn(tt), rt = []; @@ -7457,15 +7468,15 @@ function Pf(t) { elementContext: "reference" }), l = kn(e, { altBoundary: !0 - }), c = Fa(i, r), p = Fa(l, o, a), d = Ua(c), m = Ua(p); + }), c = Fa(i, r), d = Fa(l, o, a), p = Ua(c), f = Ua(d); e.modifiersData[n] = { referenceClippingOffsets: c, - popperEscapeOffsets: p, - isReferenceHidden: d, - hasPopperEscaped: m + popperEscapeOffsets: d, + isReferenceHidden: p, + hasPopperEscaped: f }, e.attributes.popper = Object.assign({}, e.attributes.popper, { - "data-popper-reference-hidden": d, - "data-popper-escaped": m + "data-popper-reference-hidden": p, + "data-popper-escaped": f }); } const $f = { @@ -7488,10 +7499,10 @@ function If(t, e, n) { }; } function Af(t) { - var e = t.state, n = t.options, r = t.name, o = n.offset, a = o === void 0 ? [0, 0] : o, i = ys.reduce(function(d, m) { - return d[m] = If(m, e.rects, a), d; - }, {}), l = i[e.placement], c = l.x, p = l.y; - e.modifiersData.popperOffsets != null && (e.modifiersData.popperOffsets.x += c, e.modifiersData.popperOffsets.y += p), e.modifiersData[r] = i; + var e = t.state, n = t.options, r = t.name, o = n.offset, a = o === void 0 ? [0, 0] : o, i = ys.reduce(function(p, f) { + return p[f] = If(f, e.rects, a), p; + }, {}), l = i[e.placement], c = l.x, d = l.y; + e.modifiersData.popperOffsets != null && (e.modifiersData.popperOffsets.x += c, e.modifiersData.popperOffsets.y += d), e.modifiersData[r] = i; } const Mf = { name: "offset", @@ -7520,14 +7531,14 @@ function jf(t) { return t === "x" ? "y" : "x"; } function Vf(t) { - var e = t.state, n = t.options, r = t.name, o = n.mainAxis, a = o === void 0 ? !0 : o, i = n.altAxis, l = i === void 0 ? !1 : i, c = n.boundary, p = n.rootBoundary, d = n.altBoundary, m = n.padding, w = n.tether, g = w === void 0 ? !0 : w, v = n.tetherOffset, f = v === void 0 ? 0 : v, h = kn(e, { + var e = t.state, n = t.options, r = t.name, o = n.mainAxis, a = o === void 0 ? !0 : o, i = n.altAxis, l = i === void 0 ? !1 : i, c = n.boundary, d = n.rootBoundary, p = n.altBoundary, f = n.padding, w = n.tether, g = w === void 0 ? !0 : w, v = n.tetherOffset, m = v === void 0 ? 0 : v, h = kn(e, { boundary: c, - rootBoundary: p, - padding: m, - altBoundary: d - }), E = Yt(e.placement), _ = Ge(e.placement), C = !_, S = Mo(E), b = jf(S), I = e.modifiersData.popperOffsets, z = e.rects.reference, H = e.rects.popper, O = typeof f == "function" ? f(Object.assign({}, e.rects, { + rootBoundary: d, + padding: f, + altBoundary: p + }), E = Yt(e.placement), _ = Ge(e.placement), C = !_, S = Mo(E), b = jf(S), I = e.modifiersData.popperOffsets, z = e.rects.reference, H = e.rects.popper, O = typeof m == "function" ? m(Object.assign({}, e.rects, { placement: e.placement - })) : f, $ = typeof O == "number" ? { + })) : m, $ = typeof O == "number" ? { mainAxis: O, altAxis: O } : Object.assign({ @@ -7653,9 +7664,9 @@ function Ha() { function qf(t) { t === void 0 && (t = {}); var e = t, n = e.defaultModifiers, r = n === void 0 ? [] : n, o = e.defaultOptions, a = o === void 0 ? Ga : o; - return function(l, c, p) { - p === void 0 && (p = a); - var d = { + return function(l, c, d) { + d === void 0 && (d = a); + var p = { placement: "bottom", orderedModifiers: [], options: Object.assign({}, Ga, a), @@ -7666,16 +7677,16 @@ function qf(t) { }, attributes: {}, styles: {} - }, m = [], w = !1, g = { - state: d, + }, f = [], w = !1, g = { + state: p, setOptions: function(E) { - var _ = typeof E == "function" ? E(d.options) : E; - f(), d.options = Object.assign({}, a, d.options, _), d.scrollParents = { + var _ = typeof E == "function" ? E(p.options) : E; + m(), p.options = Object.assign({}, a, p.options, _), p.scrollParents = { reference: ke(l) ? fn(l) : l.contextElement ? fn(l.contextElement) : [], popper: fn(c) }; - var C = Xf(Wf([].concat(r, d.options.modifiers))); - return d.orderedModifiers = C.filter(function(S) { + var C = Xf(Wf([].concat(r, p.options.modifiers))); + return p.orderedModifiers = C.filter(function(S) { return S.enabled; }), v(), g.update(); }, @@ -7686,26 +7697,26 @@ function qf(t) { // prefer the async Popper#update method forceUpdate: function() { if (!w) { - var E = d.elements, _ = E.reference, C = E.popper; + var E = p.elements, _ = E.reference, C = E.popper; if (Ha(_, C)) { - d.rects = { - reference: Gf(_, Pn(C), d.options.strategy === "fixed"), + p.rects = { + reference: Gf(_, Pn(C), p.options.strategy === "fixed"), popper: Ao(C) - }, d.reset = !1, d.placement = d.options.placement, d.orderedModifiers.forEach(function($) { - return d.modifiersData[$.name] = Object.assign({}, $.data); + }, p.reset = !1, p.placement = p.options.placement, p.orderedModifiers.forEach(function($) { + return p.modifiersData[$.name] = Object.assign({}, $.data); }); - for (var S = 0; S < d.orderedModifiers.length; S++) { - if (d.reset === !0) { - d.reset = !1, S = -1; + for (var S = 0; S < p.orderedModifiers.length; S++) { + if (p.reset === !0) { + p.reset = !1, S = -1; continue; } - var b = d.orderedModifiers[S], I = b.fn, z = b.options, H = z === void 0 ? {} : z, O = b.name; - typeof I == "function" && (d = I({ - state: d, + var b = p.orderedModifiers[S], I = b.fn, z = b.options, H = z === void 0 ? {} : z, O = b.name; + typeof I == "function" && (p = I({ + state: p, options: H, name: O, instance: g - }) || d); + }) || p); } } } @@ -7714,37 +7725,37 @@ function qf(t) { // not necessary (debounced to run at most once-per-tick) update: Yf(function() { return new Promise(function(h) { - g.forceUpdate(), h(d); + g.forceUpdate(), h(p); }); }), destroy: function() { - f(), w = !0; + m(), w = !0; } }; if (!Ha(l, c)) return g; - g.setOptions(p).then(function(h) { - !w && p.onFirstUpdate && p.onFirstUpdate(h); + g.setOptions(d).then(function(h) { + !w && d.onFirstUpdate && d.onFirstUpdate(h); }); function v() { - d.orderedModifiers.forEach(function(h) { + p.orderedModifiers.forEach(function(h) { var E = h.name, _ = h.options, C = _ === void 0 ? {} : _, S = h.effect; if (typeof S == "function") { var b = S({ - state: d, + state: p, name: E, instance: g, options: C }), I = function() { }; - m.push(b || I); + f.push(b || I); } }); } - function f() { - m.forEach(function(h) { + function m() { + f.forEach(function(h) { return h(); - }), m = []; + }), f = []; } return g; }; @@ -7793,26 +7804,26 @@ const rm = () => xo({ direction: i, disablePortal: l, modifiers: c, - open: p, - placement: d, - popperOptions: m, + open: d, + placement: p, + popperOptions: f, popperRef: w, slotProps: g = {}, slots: v = {}, - TransitionProps: f + TransitionProps: m // @ts-ignore internal logic // prevent from spreading to DOM, it can come from the parent component e.g. Select. } = e, h = kt(e, Qf), E = M.useRef(null), _ = xe(E, n), C = M.useRef(null), S = xe(C, w), b = M.useRef(S); ze(() => { b.current = S; }, [S]), M.useImperativeHandle(w, () => C.current, []); - const I = em(d, i), [z, H] = M.useState(I), [O, $] = M.useState(Zn(o)); + const I = em(p, i), [z, H] = M.useState(I), [O, $] = M.useState(Zn(o)); M.useEffect(() => { C.current && C.current.forceUpdate(); }), M.useEffect(() => { o && $(Zn(o)); }, [o]), ze(() => { - if (!O || !p) + if (!O || !d) return; const q = (at) => { H(at.placement); @@ -7842,20 +7853,20 @@ const rm = () => xo({ q(at); } }]; - c != null && (U = U.concat(c)), m && m.modifiers != null && (U = U.concat(m.modifiers)); + c != null && (U = U.concat(c)), f && f.modifiers != null && (U = U.concat(f.modifiers)); const tt = Jf(O, E.current, P({ placement: I - }, m, { + }, f, { modifiers: U })); return b.current(tt), () => { tt.destroy(), b.current(null); }; - }, [O, l, c, p, m, I]); + }, [O, l, c, d, f, I]); const k = { placement: z }; - f !== null && (k.TransitionProps = f); + m !== null && (k.TransitionProps = m); const B = rm(), D = (r = v.root) != null ? r : "div", J = zw({ elementType: D, externalSlotProps: g.root, @@ -7878,13 +7889,13 @@ const rm = () => xo({ direction: i = "ltr", disablePortal: l = !1, keepMounted: c = !1, - modifiers: p, - open: d, - placement: m = "bottom", + modifiers: d, + open: p, + placement: f = "bottom", popperOptions: w = om, popperRef: g, style: v, - transition: f = !1, + transition: m = !1, slotProps: h = {}, slots: E = {} } = e, _ = kt(e, tm), [C, S] = M.useState(!0), b = () => { @@ -7892,7 +7903,7 @@ const rm = () => xo({ }, I = () => { S(!0); }; - if (!c && !d && (!f || C)) + if (!c && !p && (!m || C)) return null; let z; if (a) @@ -7901,8 +7912,8 @@ const rm = () => xo({ const $ = Zn(r); z = $ && Nr($) ? Yn($).body : Yn(null).body; } - const H = !d && c && (!f || C) ? "none" : void 0, O = f ? { - in: d, + const H = !p && c && (!m || C) ? "none" : void 0, O = m ? { + in: p, onEnter: b, onExited: I } : void 0; @@ -7913,10 +7924,10 @@ const rm = () => xo({ anchorEl: r, direction: i, disablePortal: l, - modifiers: p, + modifiers: d, ref: n, - open: f ? !C : d, - placement: m, + open: m ? !C : p, + placement: f, popperOptions: w, popperRef: g, slotProps: h, @@ -8141,23 +8152,23 @@ var lm = function(e) { status: cn }); }, n.performEnter = function(o) { - var a = this, i = this.props.enter, l = this.context ? this.context.isMounting : o, c = this.props.nodeRef ? [l] : [Bn.findDOMNode(this), l], p = c[0], d = c[1], m = this.getTimeouts(), w = l ? m.appear : m.enter; + var a = this, i = this.props.enter, l = this.context ? this.context.isMounting : o, c = this.props.nodeRef ? [l] : [Bn.findDOMNode(this), l], d = c[0], p = c[1], f = this.getTimeouts(), w = l ? f.appear : f.enter; if (!o && !i || Xa.disabled) { this.safeSetState({ status: Ae }, function() { - a.props.onEntered(p); + a.props.onEntered(d); }); return; } - this.props.onEnter(p, d), this.safeSetState({ + this.props.onEnter(d, p), this.safeSetState({ status: me }, function() { - a.props.onEntering(p, d), a.onTransitionEnd(w, function() { + a.props.onEntering(d, p), a.onTransitionEnd(w, function() { a.safeSetState({ status: Ae }, function() { - a.props.onEntered(p, d); + a.props.onEntered(d, p); }); }); }); @@ -8201,8 +8212,8 @@ var lm = function(e) { return; } if (this.props.addEndListener) { - var c = this.props.nodeRef ? [this.nextCallback] : [i, this.nextCallback], p = c[0], d = c[1]; - this.props.addEndListener(p, d); + var c = this.props.nodeRef ? [this.nextCallback] : [i, this.nextCallback], d = c[0], p = c[1]; + this.props.addEndListener(d, p); } o != null && setTimeout(this.nextCallback, o); }, n.render = function() { @@ -8446,13 +8457,13 @@ const um = { easing: i, in: l, onEnter: c, - onEntered: p, - onEntering: d, - onExit: m, + onEntered: d, + onEntering: p, + onExit: f, onExited: w, onExiting: g, style: v, - timeout: f = "auto", + timeout: m = "auto", // eslint-disable-next-line react/prop-types TransitionComponent: h = cm } = e, E = kt(e, pm), _ = sn(), C = M.useRef(), S = _s(), b = M.useRef(null), I = xe(b, a.ref, n), z = (q) => (U) => { @@ -8460,7 +8471,7 @@ const um = { const tt = b.current; U === void 0 ? q(tt) : q(tt, U); } - }, H = z(d), O = z((q, U) => { + }, H = z(p), O = z((q, U) => { dm(q); const { duration: tt, @@ -8468,13 +8479,13 @@ const um = { easing: rt } = Ya({ style: v, - timeout: f, + timeout: m, easing: i }, { mode: "enter" }); let y; - f === "auto" ? (y = S.transitions.getAutoHeightDuration(q.clientHeight), C.current = y) : y = tt, q.style.transition = [S.transitions.create("opacity", { + m === "auto" ? (y = S.transitions.getAutoHeightDuration(q.clientHeight), C.current = y) : y = tt, q.style.transition = [S.transitions.create("opacity", { duration: y, delay: at }), S.transitions.create("transform", { @@ -8482,27 +8493,27 @@ const um = { delay: at, easing: rt })].join(","), c && c(q, U); - }), $ = z(p), k = z(g), B = z((q) => { + }), $ = z(d), k = z(g), B = z((q) => { const { duration: U, delay: tt, easing: at } = Ya({ style: v, - timeout: f, + timeout: m, easing: i }, { mode: "exit" }); let rt; - f === "auto" ? (rt = S.transitions.getAutoHeightDuration(q.clientHeight), C.current = rt) : rt = U, q.style.transition = [S.transitions.create("opacity", { + m === "auto" ? (rt = S.transitions.getAutoHeightDuration(q.clientHeight), C.current = rt) : rt = U, q.style.transition = [S.transitions.create("opacity", { duration: rt, delay: tt }), S.transitions.create("transform", { duration: Ur ? rt : rt * 0.666, delay: Ur ? tt : tt || rt * 0.333, easing: at - })].join(","), q.style.opacity = 0, q.style.transform = so(0.75), m && m(q); + })].join(","), q.style.opacity = 0, q.style.transform = so(0.75), f && f(q); }), D = z(w); return /* @__PURE__ */ s(h, P({ appear: o, @@ -8515,9 +8526,9 @@ const um = { onExited: D, onExiting: k, addEndListener: (q) => { - f === "auto" && _.start(C.current || 0, q), r && r(b.current, q); + m === "auto" && _.start(C.current || 0, q), r && r(b.current, q); }, - timeout: f === "auto" ? null : f + timeout: m === "auto" ? null : m }, E, { children: (q, U) => /* @__PURE__ */ M.cloneElement(a, P({ style: P({ @@ -8617,13 +8628,13 @@ const Wa = Vo, wm = ["anchorEl", "component", "components", "componentsProps", " anchorEl: i, component: l, components: c, - componentsProps: p, - container: d, - disablePortal: m, + componentsProps: d, + container: p, + disablePortal: f, keepMounted: w, modifiers: g, open: v, - placement: f, + placement: m, popperOptions: h, popperRef: E, transition: _, @@ -8631,12 +8642,12 @@ const Wa = Vo, wm = ["anchorEl", "component", "components", "componentsProps", " slotProps: S } = a, b = kt(a, wm), I = (r = C == null ? void 0 : C.root) != null ? r : c == null ? void 0 : c.Root, z = P({ anchorEl: i, - container: d, - disablePortal: m, + container: p, + disablePortal: f, keepMounted: w, modifiers: g, open: v, - placement: f, + placement: m, popperOptions: h, popperRef: E, transition: _ @@ -8647,7 +8658,7 @@ const Wa = Vo, wm = ["anchorEl", "component", "components", "componentsProps", " slots: { root: I }, - slotProps: S ?? p + slotProps: S ?? d }, z, { ref: n })); @@ -8962,7 +8973,7 @@ function Fn(t, e) { }; } const As = /* @__PURE__ */ M.forwardRef(function(e, n) { - var r, o, a, i, l, c, p, d, m, w, g, v, f, h, E, _, C, S, b; + var r, o, a, i, l, c, d, p, f, w, g, v, m, h, E, _, C, S, b; const I = _o({ props: e, name: "MuiTooltip" @@ -9113,9 +9124,9 @@ const As = /* @__PURE__ */ M.forwardRef(function(e, n) { placement: X, PopperComponentProp: Y, touch: de.current - }), Cr = vm(Qe), Ko = (r = (o = Z.popper) != null ? o : O.Popper) != null ? r : ym, Jo = (a = (i = (l = Z.transition) != null ? l : O.Transition) != null ? i : A) != null ? a : Wa, Zo = (c = (p = Z.tooltip) != null ? p : O.Tooltip) != null ? c : xm, Qo = (d = (m = Z.arrow) != null ? m : O.Arrow) != null ? d : Nm, Xs = ln(Ko, P({}, G, (w = K.popper) != null ? w : $.popper, { + }), Cr = vm(Qe), Ko = (r = (o = Z.popper) != null ? o : O.Popper) != null ? r : ym, Jo = (a = (i = (l = Z.transition) != null ? l : O.Transition) != null ? i : A) != null ? a : Wa, Zo = (c = (d = Z.tooltip) != null ? d : O.Tooltip) != null ? c : xm, Qo = (p = (f = Z.arrow) != null ? f : O.Arrow) != null ? p : Nm, Xs = ln(Ko, P({}, G, (w = K.popper) != null ? w : $.popper, { className: be(Cr.popper, G == null ? void 0 : G.className, (g = (v = K.popper) != null ? v : $.popper) == null ? void 0 : g.className) - }), Qe), Ys = ln(Jo, P({}, Nt, (f = K.transition) != null ? f : $.transition), Qe), Ws = ln(Zo, P({}, (h = K.tooltip) != null ? h : $.tooltip, { + }), Qe), Ys = ln(Jo, P({}, Nt, (m = K.transition) != null ? m : $.transition), Qe), Ws = ln(Zo, P({}, (h = K.tooltip) != null ? h : $.tooltip, { className: be(Cr.tooltip, (E = (_ = K.tooltip) != null ? _ : $.tooltip) == null ? void 0 : E.className) }), Qe), qs = ln(Qo, P({}, (C = K.arrow) != null ? C : $.arrow, { className: be(Cr.arrow, (S = (b = K.arrow) != null ? b : $.arrow) == null ? void 0 : S.className) @@ -9361,13 +9372,13 @@ function Ms(t) { iconPathAfter: i = void 0, hasAutoFocus: l = !1, className: c, - isDisabled: p = !1, - isDense: d = !0, - isSubMenuParent: m = !1, + isDisabled: d = !1, + isDense: p = !0, + isSubMenuParent: f = !1, hasDisabledGutters: w = !1, hasDivider: g = !1, focusVisibleClassName: v, - id: f, + id: m, children: h } = t, E = /* @__PURE__ */ s( Bl, @@ -9375,17 +9386,17 @@ function Ms(t) { sx: { lineHeight: 0.8 }, autoFocus: l, className: c, - disabled: p, - dense: d, + disabled: d, + dense: p, disableGutters: w, divider: g, focusVisibleClassName: v, onClick: e, - id: f, + id: m, children: n ? /* @__PURE__ */ N(ie, { children: [ Ka(a, n, !0), /* @__PURE__ */ s(jl, { primary: n, inset: !a && o }), - m ? /* @__PURE__ */ s(ii, { className: "papi-menu-icon-trailing", children: /* @__PURE__ */ s(hs, {}) }) : Ka(i, n, !1) + f ? /* @__PURE__ */ s(ii, { className: "papi-menu-icon-trailing", children: /* @__PURE__ */ s(hs, {}) }) : Ka(i, n, !1) ] }) : h } ); @@ -9395,17 +9406,17 @@ function Ds(t) { return Object.entries(t.groups).map(([n, r]) => ({ id: n, group: r })); } function Em(t) { - const [e, n] = ut(void 0), { parentMenuItem: r, parentItemProps: o, menuDefinition: a } = t, i = (p) => { - n(p.currentTarget); + const [e, n] = ut(void 0), { parentMenuItem: r, parentItemProps: o, menuDefinition: a } = t, i = (d) => { + n(d.currentTarget); }, l = () => { n(void 0); }, c = () => { - let p = Ds(a).filter((d) => "menuItem" in d.group); + let d = Ds(a).filter((p) => "menuItem" in p.group); if (!(r != null && r.id)) throw new Error("A valid parent menu item is required for submenus."); - return p = p.filter( - (d) => "menuItem" in d.group && d.group.menuItem === r.id - ), /* @__PURE__ */ s(Bs, { ...t, includedGroups: p }); + return d = d.filter( + (p) => "menuItem" in p.group && p.group.menuItem === r.id + ), /* @__PURE__ */ s(Bs, { ...t, includedGroups: d }); }; return /* @__PURE__ */ N(ie, { children: [ /* @__PURE__ */ s(Ms, { onClick: i, ...o, isSubMenuParent: !0 }), @@ -9432,44 +9443,44 @@ function Em(t) { const Sm = (t, e) => e.filter((o) => o.group === t).sort((o, a) => (o.order || 0) - (a.order || 0)); function Bs(t) { const { menuDefinition: e, onClick: n, commandHandler: r, includedGroups: o } = t, { items: a, allowForLeadingIcons: i } = It(() => { - const d = o && o.length > 0 ? o : ( + const p = o && o.length > 0 ? o : ( // We're apparently laying out a single-column menu (presumably a context menu). In this // case, all groups should be included except ones that belong to a submenu. Ds(e).filter((v) => !("menuItem" in v.group)) - ), m = Object.values(d).sort( - (v, f) => (v.group.order || 0) - (f.group.order || 0) + ), f = Object.values(p).sort( + (v, m) => (v.group.order || 0) - (m.group.order || 0) ), w = []; - m.forEach((v) => { + f.forEach((v) => { Sm(v.id, e.items).forEach( - (f) => w.push({ item: f, isLastItemInGroup: !1 }) + (m) => w.push({ item: m, isLastItemInGroup: !1 }) ), w.length > 0 && (w[w.length - 1].isLastItemInGroup = !0); }), w.length > 0 && (w[w.length - 1].isLastItemInGroup = !1); const g = w.some( (v) => "iconPathBefore" in v.item && v.item.iconPathBefore ); return { items: w, allowForLeadingIcons: g }; - }, [o, e]), l = ({ item: d, isLastItemInGroup: m }) => ({ + }, [o, e]), l = ({ item: p, isLastItemInGroup: f }) => ({ className: "papi-menu-item", - label: d.label, - tooltip: d.tooltip, - iconPathBefore: "iconPathBefore" in d ? d.iconPathBefore : void 0, - iconPathAfter: "iconPathAfter" in d ? d.iconPathAfter : void 0, - hasDivider: m, + label: p.label, + tooltip: p.tooltip, + iconPathBefore: "iconPathBefore" in p ? p.iconPathBefore : void 0, + iconPathAfter: "iconPathAfter" in p ? p.iconPathAfter : void 0, + hasDivider: f, // Set hasDivider to true for the last item in a group allowForLeadingIcons: i }), [c] = a; if (!c) return /* @__PURE__ */ s("div", {}); - const p = c.item.group; - return /* @__PURE__ */ s("div", { role: "menu", "aria-label": p, children: a.map((d, m) => { - const { item: w } = d, g = l(d); + const d = c.item.group; + return /* @__PURE__ */ s("div", { role: "menu", "aria-label": d, children: a.map((p, f) => { + const { item: w } = p, g = l(p); if ("command" in w) { - const v = w.group + m; + const v = w.group + f; return /* @__PURE__ */ s( Ms, { - onClick: (f) => { - n == null || n(f), r(w); + onClick: (m) => { + n == null || n(m), r(w); }, ...g }, @@ -9483,9 +9494,9 @@ function Bs(t) { parentItemProps: g, ...t }, - p + w.id + d + w.id ); - }) }, p); + }) }, d); } function Tm(t) { const { menuDefinition: e, columnId: n } = t; @@ -9539,9 +9550,9 @@ function Om({ return Object.getOwnPropertyNames(o).forEach((l) => { if (l === "isExtensible") return; - const c = l, p = o[c]; - typeof p == "object" && typeof p.order == "number" && !Number.isNaN(p.order) ? i.set(p.order, { id: c, metadata: p }) : console.warn( - `Property ${l} (${typeof p}) on menu ${r} is not a valid column and is being ignored. This might indicate data corruption` + const c = l, d = o[c]; + typeof d == "object" && typeof d.order == "number" && !Number.isNaN(d.order) ? i.set(d.order, { id: c, metadata: d }) : console.warn( + `Property ${l} (${typeof d}) on menu ${r} is not a valid column and is being ignored. This might indicate data corruption` ); }), Array.from(i.values()).sort((l, c) => (l.metadata.order || 0) - (c.metadata.order || 0)); }, [o, r]); @@ -9581,14 +9592,14 @@ const lo = (t, e, n = {}) => { o.current = Rm(o.current); const [a, i] = ut(() => r.current), [l, c] = ut(!0); return ae(() => { - let p = !0; + let d = !0; return c(!!t), (async () => { if (t) { - const d = await t(); - p && (i(() => d), c(!1)); + const p = await t(); + d && (i(() => p), c(!1)); } })(), () => { - p = !1, o.current.preserveValue || i(() => r.current); + d = !1, o.current.preserveValue || i(() => r.current); }; }, [t]), [a, l]; }, _m = ms(/* @__PURE__ */ s("path", { @@ -9604,17 +9615,17 @@ function Pm({ ariaLabelPrefix: i, children: l }) { - const [c, p] = ut(!1), [d, m] = ut(!1), w = Et(() => { - c && p(!1), m(!1); + const [c, d] = ut(!1), [p, f] = ut(!1), w = Et(() => { + c && d(!1), f(!1); }, [c]), g = Et((S) => { - S.stopPropagation(), p((b) => { + S.stopPropagation(), d((b) => { const I = !b; - return I && S.shiftKey ? m(!0) : I || m(!1), I; + return I && S.shiftKey ? f(!0) : I || f(!1), I; }); }, []), v = Et( (S) => (w(), r(S)), [r, w] - ), [f, h] = ut({ top: 1, left: 1 }); + ), [m, h] = ut({ top: 1, left: 1 }); ae(() => { if (c) { const S = o == null ? void 0 : o.current; @@ -9630,7 +9641,7 @@ function Pm({ ), [_] = lo( Et(async () => (t == null ? void 0 : t(!0)) ?? n ?? E, [t, n, E, c]), n ?? E - ), C = d && _ ? _ : E; + ), C = p && _ ? _ : E; return /* @__PURE__ */ N(ie, { children: [ /* @__PURE__ */ s( li, @@ -9658,8 +9669,8 @@ function Pm({ PaperProps: { className: "papi-menu-drawer-paper", style: { - top: f.top, - left: f.left + top: m.top, + left: m.left } }, children: C ? /* @__PURE__ */ s( @@ -9685,7 +9696,7 @@ function Ih({ size: i = "medium", className: l, onClick: c, - children: p + children: d }) { return /* @__PURE__ */ s( li, @@ -9698,7 +9709,7 @@ function Ih({ title: o ? void 0 : r ?? e, className: `papi-icon-button ${l ?? ""}`, onClick: c, - children: p + children: d } ); } @@ -9714,9 +9725,9 @@ function Ah({ placeholder: i, isRequired: l = !1, className: c, - defaultValue: p, - value: d, - onChange: m, + defaultValue: d, + value: p, + onChange: f, onFocus: w, onBlur: g }) { @@ -9740,9 +9751,9 @@ function Ah({ placeholder: i, required: l, className: x(c, { "tw-border-red-600": n }), - defaultValue: p, - value: d, - onChange: m, + defaultValue: d, + value: p, + onChange: f, onFocus: w, onBlur: g } @@ -10203,9 +10214,9 @@ function Hh({ function qm({ id: t, versionHistory: e }) { const [n, r] = ut(!1), o = /* @__PURE__ */ new Date(); function a(l) { - const c = new Date(l), p = new Date(o.getTime() - c.getTime()), d = p.getUTCFullYear() - 1970, m = p.getUTCMonth(), w = p.getUTCDate() - 1; + const c = new Date(l), d = new Date(o.getTime() - c.getTime()), p = d.getUTCFullYear() - 1970, f = d.getUTCMonth(), w = d.getUTCDate() - 1; let g = ""; - return d > 0 ? g = `${d.toString()} year${d === 1 ? "" : "s"} ago` : m > 0 ? g = `${m.toString()} month${m === 1 ? "" : "s"} ago` : w === 0 ? g = "today" : g = `${w.toString()} day${w === 1 ? "" : "s"} ago`, g; + return p > 0 ? g = `${p.toString()} year${p === 1 ? "" : "s"} ago` : f > 0 ? g = `${f.toString()} month${f === 1 ? "" : "s"} ago` : w === 0 ? g = "today" : g = `${w.toString()} day${w === 1 ? "" : "s"} ago`, g; } const i = Object.entries(e).sort((l, c) => c[0].localeCompare(l[0])); return /* @__PURE__ */ N("div", { id: t, children: [ @@ -10239,8 +10250,8 @@ function Xh({ versionHistory: o }) { const a = It(() => Rl(n), [n]), l = ((c) => { - const p = new Intl.DisplayNames(navigator.language, { type: "language" }); - return c.map((d) => p.of(d)); + const d = new Intl.DisplayNames(navigator.language, { type: "language" }); + return c.map((p) => d.of(p)); })(r); return /* @__PURE__ */ s("div", { id: t, className: "tw-border-t tw-pb-4 tw-pt-4", children: /* @__PURE__ */ N("div", { className: "tw-md:flex-row tw-md:space-x-8 tw-flex tw-flex-col tw-space-x-0", children: [ /* @__PURE__ */ s(qm, { versionHistory: o }), @@ -13824,32 +13835,6 @@ video:where(.pr-twp,.pr-twp *) { .banded-row[data-state='selected']:hover { cursor: default; } -.papi-icon-button { - border: 0; - border-radius: 3em; - cursor: pointer; - display: inline-block; -} - -.papi-icon-button.primary { - background-color: #1ea7fd; - color: white; -} - -.papi-icon-button.secondary { - background-color: transparent; - color: #333; -} - -.papi-icon-button.paratext { - background-color: darkgreen; - color: greenyellow; -} - -.papi-icon-button.paratext.bright { - background-color: greenyellow; - color: darkgreen; -} .papi-multi-column-menu { background-color: rgb(222, 222, 222); display: flex; @@ -13884,6 +13869,32 @@ video:where(.pr-twp,.pr-twp *) { color: rgb(76, 106, 76); background-color: rgb(214, 255, 152); } +.papi-icon-button { + border: 0; + border-radius: 3em; + cursor: pointer; + display: inline-block; +} + +.papi-icon-button.primary { + background-color: #1ea7fd; + color: white; +} + +.papi-icon-button.secondary { + background-color: transparent; + color: #333; +} + +.papi-icon-button.paratext { + background-color: darkgreen; + color: greenyellow; +} + +.papi-icon-button.paratext.bright { + background-color: greenyellow; + color: darkgreen; +} .papi-menu-item { background-color: transparent; } diff --git a/lib/platform-bible-react/dist/index.js.map b/lib/platform-bible-react/dist/index.js.map index 46da395ba6..0a5ac9a783 100644 --- a/lib/platform-bible-react/dist/index.js.map +++ b/lib/platform-bible-react/dist/index.js.map @@ -1 +1 @@ -{"version":3,"file":"index.js","sources":["../src/utils/shadcn-ui.util.ts","../src/components/shadcn-ui/input.tsx","../src/components/advanced/book-chapter-control/book-chapter-input.component.tsx","../../../node_modules/@sillsdev/scripture/dist/index.es.js","../src/components/shadcn-ui/dropdown-menu.tsx","../src/components/advanced/book-chapter-control/book-menu-item.component.tsx","../src/components/advanced/book-chapter-control/chapter-select.component.tsx","../src/components/advanced/book-chapter-control/go-to-menu-item.component.tsx","../src/components/advanced/book-chapter-control/book-chapter-control.component.tsx","../src/components/shadcn-ui/button.tsx","../src/components/shadcn-ui/label.tsx","../src/components/shadcn-ui/radio-group.tsx","../src/components/shadcn-ui/popover.tsx","../src/components/shadcn-ui/dialog.tsx","../src/components/shadcn-ui/command.tsx","../src/components/basics/combo-box.component.tsx","../src/components/basics/chapter-range-selector.component.tsx","../src/components/advanced/book-selector.component.tsx","../src/components/advanced/data-table/data-table-column-toggle.component.tsx","../src/components/shadcn-ui/select.tsx","../src/components/advanced/data-table/data-table-pagination.component.tsx","../src/components/shadcn-ui/table.tsx","../src/components/advanced/data-table/data-table.component.tsx","../src/components/advanced/inventory/occurrences-table.component.tsx","../src/components/shadcn-ui/checkbox.tsx","../src/components/advanced/inventory/inventory-utils.ts","../src/components/shadcn-ui/toggle.tsx","../src/components/shadcn-ui/toggle-group.tsx","../src/components/advanced/inventory/inventory-columns.tsx","../src/components/advanced/inventory/inventory.component.tsx","../src/components/basics/search-bar.component.tsx","../src/components/basics/tabs-vertical.tsx","../src/components/advanced/tab-navigation-content-search.component.tsx","../src/components/shadcn-ui/separator.tsx","../src/components/shadcn-ui/sheet.tsx","../src/components/shadcn-ui/skeleton.tsx","../src/components/shadcn-ui/tooltip.tsx","../src/components/hooks/use-mobile.tsx","../src/components/shadcn-ui/sidebar.tsx","../src/components/advanced/settings-components/settings-sidebar.component.tsx","../src/components/advanced/settings-components/settings-sidebar-content-search.component.tsx","../src/components/advanced/scripture-results-viewer/scripture-results-viewer.component.tsx","../src/components/advanced/scroll-group-selector.component.tsx","../src/components/advanced/settings-components/settings-list.component.tsx","../src/components/basics/checklist.component.tsx","../../../node_modules/@babel/runtime/helpers/interopRequireDefault.js","../../../node_modules/@mui/utils/chainPropTypes/chainPropTypes.js","../../../node_modules/@babel/runtime/helpers/esm/extends.js","../../../node_modules/@mui/utils/deepmerge/deepmerge.js","../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.production.min.js","../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.development.js","../../../node_modules/prop-types/node_modules/react-is/index.js","../../../node_modules/object-assign/index.js","../../../node_modules/prop-types/lib/ReactPropTypesSecret.js","../../../node_modules/prop-types/lib/has.js","../../../node_modules/prop-types/checkPropTypes.js","../../../node_modules/prop-types/factoryWithTypeCheckers.js","../../../node_modules/prop-types/factoryWithThrowingShims.js","../../../node_modules/prop-types/index.js","../../../node_modules/@mui/utils/elementAcceptingRef/elementAcceptingRef.js","../../../node_modules/@mui/utils/exactProp/exactProp.js","../../../node_modules/@mui/utils/formatMuiErrorMessage/formatMuiErrorMessage.js","../../../node_modules/react-is/cjs/react-is.production.min.js","../../../node_modules/react-is/cjs/react-is.development.js","../../../node_modules/react-is/index.js","../../../node_modules/@mui/utils/getDisplayName/getDisplayName.js","../../../node_modules/@mui/utils/HTMLElementType/HTMLElementType.js","../../../node_modules/@mui/utils/refType/refType.js","../../../node_modules/@mui/utils/capitalize/capitalize.js","../../../node_modules/@mui/utils/createChainedFunction/createChainedFunction.js","../../../node_modules/@mui/utils/debounce/debounce.js","../../../node_modules/@mui/utils/deprecatedPropType/deprecatedPropType.js","../../../node_modules/@mui/utils/isMuiElement/isMuiElement.js","../../../node_modules/@mui/utils/ownerDocument/ownerDocument.js","../../../node_modules/@mui/utils/ownerWindow/ownerWindow.js","../../../node_modules/@mui/utils/requirePropFactory/requirePropFactory.js","../../../node_modules/@mui/utils/setRef/setRef.js","../../../node_modules/@mui/utils/useEnhancedEffect/useEnhancedEffect.js","../../../node_modules/@mui/utils/useId/useId.js","../../../node_modules/@mui/utils/unsupportedProp/unsupportedProp.js","../../../node_modules/@mui/utils/useControlled/useControlled.js","../../../node_modules/@mui/utils/useEventCallback/useEventCallback.js","../../../node_modules/@mui/utils/useForkRef/useForkRef.js","../../../node_modules/@mui/utils/useLazyRef/useLazyRef.js","../../../node_modules/@mui/utils/useOnMount/useOnMount.js","../../../node_modules/@mui/utils/useTimeout/useTimeout.js","../../../node_modules/@mui/utils/useIsFocusVisible/useIsFocusVisible.js","../../../node_modules/@mui/utils/resolveProps/resolveProps.js","../../../node_modules/@mui/utils/composeClasses/composeClasses.js","../../../node_modules/@mui/utils/ClassNameGenerator/ClassNameGenerator.js","../../../node_modules/@mui/utils/generateUtilityClass/generateUtilityClass.js","../../../node_modules/@mui/utils/generateUtilityClasses/generateUtilityClasses.js","../../../node_modules/@mui/utils/clamp/clamp.js","../../../node_modules/@babel/runtime/helpers/esm/objectWithoutPropertiesLoose.js","../../../node_modules/@mui/system/esm/createTheme/createBreakpoints.js","../../../node_modules/@mui/system/esm/createTheme/shape.js","../../../node_modules/@mui/system/esm/responsivePropType.js","../../../node_modules/@mui/system/esm/merge.js","../../../node_modules/@mui/system/esm/breakpoints.js","../../../node_modules/@mui/system/esm/style.js","../../../node_modules/@mui/system/esm/memoize.js","../../../node_modules/@mui/system/esm/spacing.js","../../../node_modules/@mui/system/esm/createTheme/createSpacing.js","../../../node_modules/@mui/system/esm/compose.js","../../../node_modules/@mui/system/esm/borders.js","../../../node_modules/@mui/system/esm/cssGrid.js","../../../node_modules/@mui/system/esm/palette.js","../../../node_modules/@mui/system/esm/sizing.js","../../../node_modules/@mui/system/esm/styleFunctionSx/defaultSxConfig.js","../../../node_modules/@mui/system/esm/styleFunctionSx/styleFunctionSx.js","../../../node_modules/@mui/system/esm/createTheme/applyStyles.js","../../../node_modules/@mui/system/esm/createTheme/createTheme.js","../../../node_modules/@mui/system/esm/useThemeWithoutDefault.js","../../../node_modules/@mui/system/esm/useTheme.js","../../../node_modules/@mui/system/esm/createStyled.js","../../../node_modules/@mui/system/esm/useThemeProps/getThemeProps.js","../../../node_modules/@mui/system/esm/useThemeProps/useThemeProps.js","../../../node_modules/@mui/system/esm/colorManipulator.js","../../../node_modules/@mui/material/styles/createMixins.js","../../../node_modules/@mui/material/colors/common.js","../../../node_modules/@mui/material/colors/grey.js","../../../node_modules/@mui/material/colors/purple.js","../../../node_modules/@mui/material/colors/red.js","../../../node_modules/@mui/material/colors/orange.js","../../../node_modules/@mui/material/colors/blue.js","../../../node_modules/@mui/material/colors/lightBlue.js","../../../node_modules/@mui/material/colors/green.js","../../../node_modules/@mui/material/styles/createPalette.js","../../../node_modules/@mui/material/styles/createTypography.js","../../../node_modules/@mui/material/styles/shadows.js","../../../node_modules/@mui/material/styles/createTransitions.js","../../../node_modules/@mui/material/styles/zIndex.js","../../../node_modules/@mui/material/styles/createTheme.js","../../../node_modules/@mui/material/styles/defaultTheme.js","../../../node_modules/@mui/material/styles/identifier.js","../../../node_modules/@mui/material/styles/useThemeProps.js","../../../node_modules/@mui/material/styles/styled.js","../../../node_modules/@mui/material/SvgIcon/svgIconClasses.js","../../../node_modules/@mui/material/SvgIcon/SvgIcon.js","../../../node_modules/@mui/material/utils/createSvgIcon.js","../../../node_modules/@mui/material/utils/index.js","../../../node_modules/@mui/icons-material/utils/createSvgIcon.js","../../../node_modules/@mui/icons-material/ArrowRight.js","../../../node_modules/@mui/base/utils/isHostComponent.js","../../../node_modules/@mui/base/utils/appendOwnerState.js","../../../node_modules/@mui/base/utils/ClassNameConfigurator.js","../../../node_modules/@mui/base/utils/extractEventHandlers.js","../../../node_modules/@mui/base/utils/resolveComponentProps.js","../../../node_modules/@mui/base/utils/omitEventHandlers.js","../../../node_modules/@mui/base/utils/mergeSlotProps.js","../../../node_modules/@mui/base/utils/useSlotProps.js","../../../node_modules/@mui/base/generateUtilityClass/index.js","../../../node_modules/@mui/base/generateUtilityClasses/index.js","../../../node_modules/@mui/base/Portal/Portal.js","../../../node_modules/@popperjs/core/lib/enums.js","../../../node_modules/@popperjs/core/lib/dom-utils/getNodeName.js","../../../node_modules/@popperjs/core/lib/dom-utils/getWindow.js","../../../node_modules/@popperjs/core/lib/dom-utils/instanceOf.js","../../../node_modules/@popperjs/core/lib/modifiers/applyStyles.js","../../../node_modules/@popperjs/core/lib/utils/getBasePlacement.js","../../../node_modules/@popperjs/core/lib/utils/math.js","../../../node_modules/@popperjs/core/lib/utils/userAgent.js","../../../node_modules/@popperjs/core/lib/dom-utils/isLayoutViewport.js","../../../node_modules/@popperjs/core/lib/dom-utils/getBoundingClientRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/getLayoutRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/contains.js","../../../node_modules/@popperjs/core/lib/dom-utils/getComputedStyle.js","../../../node_modules/@popperjs/core/lib/dom-utils/isTableElement.js","../../../node_modules/@popperjs/core/lib/dom-utils/getDocumentElement.js","../../../node_modules/@popperjs/core/lib/dom-utils/getParentNode.js","../../../node_modules/@popperjs/core/lib/dom-utils/getOffsetParent.js","../../../node_modules/@popperjs/core/lib/utils/getMainAxisFromPlacement.js","../../../node_modules/@popperjs/core/lib/utils/within.js","../../../node_modules/@popperjs/core/lib/utils/getFreshSideObject.js","../../../node_modules/@popperjs/core/lib/utils/mergePaddingObject.js","../../../node_modules/@popperjs/core/lib/utils/expandToHashMap.js","../../../node_modules/@popperjs/core/lib/modifiers/arrow.js","../../../node_modules/@popperjs/core/lib/utils/getVariation.js","../../../node_modules/@popperjs/core/lib/modifiers/computeStyles.js","../../../node_modules/@popperjs/core/lib/modifiers/eventListeners.js","../../../node_modules/@popperjs/core/lib/utils/getOppositePlacement.js","../../../node_modules/@popperjs/core/lib/utils/getOppositeVariationPlacement.js","../../../node_modules/@popperjs/core/lib/dom-utils/getWindowScroll.js","../../../node_modules/@popperjs/core/lib/dom-utils/getWindowScrollBarX.js","../../../node_modules/@popperjs/core/lib/dom-utils/getViewportRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/getDocumentRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/isScrollParent.js","../../../node_modules/@popperjs/core/lib/dom-utils/getScrollParent.js","../../../node_modules/@popperjs/core/lib/dom-utils/listScrollParents.js","../../../node_modules/@popperjs/core/lib/utils/rectToClientRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/getClippingRect.js","../../../node_modules/@popperjs/core/lib/utils/computeOffsets.js","../../../node_modules/@popperjs/core/lib/utils/detectOverflow.js","../../../node_modules/@popperjs/core/lib/utils/computeAutoPlacement.js","../../../node_modules/@popperjs/core/lib/modifiers/flip.js","../../../node_modules/@popperjs/core/lib/modifiers/hide.js","../../../node_modules/@popperjs/core/lib/modifiers/offset.js","../../../node_modules/@popperjs/core/lib/modifiers/popperOffsets.js","../../../node_modules/@popperjs/core/lib/utils/getAltAxis.js","../../../node_modules/@popperjs/core/lib/modifiers/preventOverflow.js","../../../node_modules/@popperjs/core/lib/dom-utils/getHTMLElementScroll.js","../../../node_modules/@popperjs/core/lib/dom-utils/getNodeScroll.js","../../../node_modules/@popperjs/core/lib/dom-utils/getCompositeRect.js","../../../node_modules/@popperjs/core/lib/utils/orderModifiers.js","../../../node_modules/@popperjs/core/lib/utils/debounce.js","../../../node_modules/@popperjs/core/lib/utils/mergeByName.js","../../../node_modules/@popperjs/core/lib/createPopper.js","../../../node_modules/@popperjs/core/lib/popper.js","../../../node_modules/@mui/base/Popper/popperClasses.js","../../../node_modules/@mui/base/Popper/Popper.js","../../../node_modules/@mui/material/styles/useTheme.js","../../../node_modules/@babel/runtime/helpers/esm/setPrototypeOf.js","../../../node_modules/@babel/runtime/helpers/esm/inheritsLoose.js","../../../node_modules/react-transition-group/esm/config.js","../../../node_modules/react-transition-group/esm/utils/PropTypes.js","../../../node_modules/react-transition-group/esm/TransitionGroupContext.js","../../../node_modules/react-transition-group/esm/utils/reflow.js","../../../node_modules/react-transition-group/esm/Transition.js","../../../node_modules/@mui/material/transitions/utils.js","../../../node_modules/@mui/material/Grow/Grow.js","../../../node_modules/@mui/material/Popper/Popper.js","../../../node_modules/@mui/material/Tooltip/tooltipClasses.js","../../../node_modules/@mui/material/Tooltip/Tooltip.js","../src/components/mui/menu-item.component.tsx","../src/components/mui/grouped-menu-item-list.component.tsx","../src/components/mui/top-level-menu.component.tsx","../src/components/mui/grid-menu.component.tsx","../src/hooks/use-promise.hook.ts","../../../node_modules/@mui/icons-material/esm/Menu.js","../src/components/mui/hamburger-menu-button.component.tsx","../src/components/mui/icon-button.component.tsx","../src/components/basics/spinner.component.tsx","../src/components/basics/text-field.component.tsx","../src/components/mui/toolbar.component.tsx","../src/components/shadcn-ui/alert.tsx","../src/components/shadcn-ui/card.tsx","../src/components/shadcn-ui/sonner.tsx","../src/components/shadcn-ui/slider.tsx","../src/components/shadcn-ui/switch.tsx","../src/components/shadcn-ui/tabs.tsx","../src/components/advanced/extension-marketplace/buttons/install-button.component.tsx","../src/components/advanced/extension-marketplace/buttons/enable-button.component.tsx","../src/components/advanced/extension-marketplace/buttons/disable-button.component.tsx","../src/components/advanced/extension-marketplace/buttons/update-button.component.tsx","../src/components/advanced/extension-marketplace/markdown-renderer.component.tsx","../src/components/advanced/extension-marketplace/buttons/filter-button.component.tsx","../src/components/advanced/extension-marketplace/filter-dropdown.component.tsx","../src/components/advanced/extension-marketplace/no-extensions-found.component.tsx","../src/components/advanced/extension-marketplace/more-info.component.tsx","../src/components/advanced/extension-marketplace/version-history.component.tsx","../src/components/advanced/extension-marketplace/footer.component.tsx","../src/hooks/use-event.hook.ts","../src/hooks/use-event-async.hook.ts"],"sourcesContent":["import { type ClassValue, clsx } from 'clsx';\nimport { extendTailwindMerge } from 'tailwind-merge';\n\nconst twMergeCustom = extendTailwindMerge({ prefix: 'tw-' });\n\n/**\n * Tailwind and CSS class application helper function. Uses\n * [`clsx`](https://www.npmjs.com/package/clsx) to make it easy to apply classes conditionally using\n * object syntax, and uses [`tailwind-merge`](https://www.npmjs.com/package/tailwind-merge) to make\n * it easy to merge/overwrite Tailwind classes in a programmer-logic-friendly way.\n *\n * Note: `tailwind-merge` is configured to use the prefix `tw-`, so you must use the same prefix\n * with any Tailwind classes you use with this function to successfully overwrite other Tailwind\n * classes. `platform-bible-react` is configured to use `tw-` as its Tailwind prefix, so any\n * Tailwind classes you pass into `platform-bible-react` components will be compared using the `tw-`\n * prefix.\n *\n * This function was popularized by\n * [shadcn/ui](https://ui.shadcn.com/docs/installation/manual#add-a-cn-helper). See [ByteGrad's\n * explanation video](https://www.youtube.com/watch?v=re2JFITR7TI) for more information.\n *\n * @example\n *\n * ```typescript\n * const borderShouldBeBlue = true;\n * const textShouldBeRed = true;\n * const heightShouldBe20 = false;\n * const classString = cn(\n * 'tw-bg-primary tw-h-10 tw-text-primary-foreground',\n * 'tw-bg-secondary',\n * {\n * 'tw-border-blue-500': borderShouldBeBlue,\n * 'tw-text-red-500': textShouldBeRed,\n * 'tw-h-20': heightShouldBe20,\n * },\n * 'some-class',\n * );\n * ```\n *\n * The resulting `classString` is `'tw-h-10 tw-bg-secondary tw-border-blue-500 tw-text-red-500\n * some-class'`\n *\n * - Notice that `'tw-bg-secondary'`, specified later, overwrote `'tw-bg-primary'`, specified earlier,\n * because they are Tailwind classes that affect the same css property\n * - Notice that `'tw-text-red-500'`, specified later, overwrote `'tw-text-primary-foreground'`,\n * specified earlier, because they are Tailwind classes that affect the same css property\n * - Notice that `'tw-h-20'`, specified later, did not overwrite `'tw-h-10'`, specified earlier,\n * because `'tw-h-20'` is part of a conditional class object and its value evaluated to `false`;\n * therefore it was not applied\n * - Notice that `'some-class'` was applied. This function is not limited only to Tailwind classes.\n *\n *\n * @param inputs Class strings or `clsx` conditional class objects to merge. Tailwind classes\n * specified later in the arguments overwrite similar Tailwind classes specified earlier in the\n * arguments\n * @returns Class string containing all applicable classes from the arguments based on the rules\n * described above\n */\n// shadcn/ui uses this export in its boilerplate code\n// eslint-disable-next-line import/prefer-default-export\nexport function cn(...inputs: ClassValue[]) {\n return twMergeCustom(clsx(inputs));\n}\n","import React from 'react';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport interface InputProps extends React.InputHTMLAttributes {}\n\nexport const Input = React.forwardRef(\n ({ className, type, ...props }, ref) => {\n return (\n \n );\n },\n);\nInput.displayName = 'Input';\n","import { FocusEventHandler, forwardRef, KeyboardEvent, MouseEventHandler } from 'react';\nimport { History } from 'lucide-react';\nimport { Input as ShadInput } from '@/components/shadcn-ui/input';\n\nexport type BookChapterInputProps = {\n handleSearch: (searchString: string) => void;\n handleKeyDown: (event: KeyboardEvent) => void;\n handleOnClick: MouseEventHandler;\n handleSubmit: () => void;\n onFocus?: FocusEventHandler;\n value: string;\n placeholder: string;\n};\n\n// Shadcn Input sets type to \"button\"- HAVE to prop spread before setting type\nconst BookChapterInput = forwardRef(\n (\n { handleSearch, handleKeyDown, handleOnClick, handleSubmit, ...props }: BookChapterInputProps,\n ref,\n ) => {\n return (\n
    \n handleSearch(event.target.value)}\n onKeyDown={(e) => {\n if (e.key === 'Enter') {\n handleSubmit();\n }\n handleKeyDown(e);\n }}\n onClick={handleOnClick}\n ref={ref}\n />\n {\n // eslint-disable-next-line no-console\n console.log('back in history');\n }}\n />\n
    \n );\n },\n);\n\nexport default BookChapterInput;\n","var P = Object.defineProperty;\nvar R = (t, e, s) => e in t ? P(t, e, { enumerable: !0, configurable: !0, writable: !0, value: s }) : t[e] = s;\nvar n = (t, e, s) => R(t, typeof e != \"symbol\" ? e + \"\" : e, s);\nclass _ {\n constructor() {\n n(this, \"books\");\n n(this, \"firstSelectedBookNum\");\n n(this, \"lastSelectedBookNum\");\n n(this, \"count\");\n n(this, \"selectedBookNumbers\");\n n(this, \"selectedBookIds\");\n }\n}\nconst N = [\n \"GEN\",\n \"EXO\",\n \"LEV\",\n \"NUM\",\n \"DEU\",\n \"JOS\",\n \"JDG\",\n \"RUT\",\n \"1SA\",\n \"2SA\",\n // 10\n \"1KI\",\n \"2KI\",\n \"1CH\",\n \"2CH\",\n \"EZR\",\n \"NEH\",\n \"EST\",\n \"JOB\",\n \"PSA\",\n \"PRO\",\n // 20\n \"ECC\",\n \"SNG\",\n \"ISA\",\n \"JER\",\n \"LAM\",\n \"EZK\",\n \"DAN\",\n \"HOS\",\n \"JOL\",\n \"AMO\",\n // 30\n \"OBA\",\n \"JON\",\n \"MIC\",\n \"NAM\",\n \"HAB\",\n \"ZEP\",\n \"HAG\",\n \"ZEC\",\n \"MAL\",\n \"MAT\",\n // 40\n \"MRK\",\n \"LUK\",\n \"JHN\",\n \"ACT\",\n \"ROM\",\n \"1CO\",\n \"2CO\",\n \"GAL\",\n \"EPH\",\n \"PHP\",\n // 50\n \"COL\",\n \"1TH\",\n \"2TH\",\n \"1TI\",\n \"2TI\",\n \"TIT\",\n \"PHM\",\n \"HEB\",\n \"JAS\",\n \"1PE\",\n // 60\n \"2PE\",\n \"1JN\",\n \"2JN\",\n \"3JN\",\n \"JUD\",\n \"REV\",\n \"TOB\",\n \"JDT\",\n \"ESG\",\n \"WIS\",\n // 70\n \"SIR\",\n \"BAR\",\n \"LJE\",\n \"S3Y\",\n \"SUS\",\n \"BEL\",\n \"1MA\",\n \"2MA\",\n \"3MA\",\n \"4MA\",\n // 80\n \"1ES\",\n \"2ES\",\n \"MAN\",\n \"PS2\",\n \"ODA\",\n \"PSS\",\n \"JSA\",\n // actual variant text for JOS, now in LXA text\n \"JDB\",\n // actual variant text for JDG, now in LXA text\n \"TBS\",\n // actual variant text for TOB, now in LXA text\n \"SST\",\n // actual variant text for SUS, now in LXA text // 90\n \"DNT\",\n // actual variant text for DAN, now in LXA text\n \"BLT\",\n // actual variant text for BEL, now in LXA text\n \"XXA\",\n \"XXB\",\n \"XXC\",\n \"XXD\",\n \"XXE\",\n \"XXF\",\n \"XXG\",\n \"FRT\",\n // 100\n \"BAK\",\n \"OTH\",\n \"3ES\",\n // Used previously but really should be 2ES\n \"EZA\",\n // Used to be called 4ES, but not actually in any known project\n \"5EZ\",\n // Used to be called 5ES, but not actually in any known project\n \"6EZ\",\n // Used to be called 6ES, but not actually in any known project\n \"INT\",\n \"CNC\",\n \"GLO\",\n \"TDX\",\n // 110\n \"NDX\",\n \"DAG\",\n \"PS3\",\n \"2BA\",\n \"LBA\",\n \"JUB\",\n \"ENO\",\n \"1MQ\",\n \"2MQ\",\n \"3MQ\",\n // 120\n \"REP\",\n \"4BA\",\n \"LAO\"\n], B = [\n \"XXA\",\n \"XXB\",\n \"XXC\",\n \"XXD\",\n \"XXE\",\n \"XXF\",\n \"XXG\",\n \"FRT\",\n \"BAK\",\n \"OTH\",\n \"INT\",\n \"CNC\",\n \"GLO\",\n \"TDX\",\n \"NDX\"\n], O = [\n \"Genesis\",\n \"Exodus\",\n \"Leviticus\",\n \"Numbers\",\n \"Deuteronomy\",\n \"Joshua\",\n \"Judges\",\n \"Ruth\",\n \"1 Samuel\",\n \"2 Samuel\",\n \"1 Kings\",\n \"2 Kings\",\n \"1 Chronicles\",\n \"2 Chronicles\",\n \"Ezra\",\n \"Nehemiah\",\n \"Esther (Hebrew)\",\n \"Job\",\n \"Psalms\",\n \"Proverbs\",\n \"Ecclesiastes\",\n \"Song of Songs\",\n \"Isaiah\",\n \"Jeremiah\",\n \"Lamentations\",\n \"Ezekiel\",\n \"Daniel (Hebrew)\",\n \"Hosea\",\n \"Joel\",\n \"Amos\",\n \"Obadiah\",\n \"Jonah\",\n \"Micah\",\n \"Nahum\",\n \"Habakkuk\",\n \"Zephaniah\",\n \"Haggai\",\n \"Zechariah\",\n \"Malachi\",\n \"Matthew\",\n \"Mark\",\n \"Luke\",\n \"John\",\n \"Acts\",\n \"Romans\",\n \"1 Corinthians\",\n \"2 Corinthians\",\n \"Galatians\",\n \"Ephesians\",\n \"Philippians\",\n \"Colossians\",\n \"1 Thessalonians\",\n \"2 Thessalonians\",\n \"1 Timothy\",\n \"2 Timothy\",\n \"Titus\",\n \"Philemon\",\n \"Hebrews\",\n \"James\",\n \"1 Peter\",\n \"2 Peter\",\n \"1 John\",\n \"2 John\",\n \"3 John\",\n \"Jude\",\n \"Revelation\",\n \"Tobit\",\n \"Judith\",\n \"Esther Greek\",\n \"Wisdom of Solomon\",\n \"Sirach (Ecclesiasticus)\",\n \"Baruch\",\n \"Letter of Jeremiah\",\n \"Song of 3 Young Men\",\n \"Susanna\",\n \"Bel and the Dragon\",\n \"1 Maccabees\",\n \"2 Maccabees\",\n \"3 Maccabees\",\n \"4 Maccabees\",\n \"1 Esdras (Greek)\",\n \"2 Esdras (Latin)\",\n \"Prayer of Manasseh\",\n \"Psalm 151\",\n \"Odes\",\n \"Psalms of Solomon\",\n // WARNING, if you change the spelling of the *obsolete* tag be sure to update\n // IsObsolete routine\n \"Joshua A. *obsolete*\",\n \"Judges B. *obsolete*\",\n \"Tobit S. *obsolete*\",\n \"Susanna Th. *obsolete*\",\n \"Daniel Th. *obsolete*\",\n \"Bel Th. *obsolete*\",\n \"Extra A\",\n \"Extra B\",\n \"Extra C\",\n \"Extra D\",\n \"Extra E\",\n \"Extra F\",\n \"Extra G\",\n \"Front Matter\",\n \"Back Matter\",\n \"Other Matter\",\n \"3 Ezra *obsolete*\",\n \"Apocalypse of Ezra\",\n \"5 Ezra (Latin Prologue)\",\n \"6 Ezra (Latin Epilogue)\",\n \"Introduction\",\n \"Concordance \",\n \"Glossary \",\n \"Topical Index\",\n \"Names Index\",\n \"Daniel Greek\",\n \"Psalms 152-155\",\n \"2 Baruch (Apocalypse)\",\n \"Letter of Baruch\",\n \"Jubilees\",\n \"Enoch\",\n \"1 Meqabyan\",\n \"2 Meqabyan\",\n \"3 Meqabyan\",\n \"Reproof (Proverbs 25-31)\",\n \"4 Baruch (Rest of Baruch)\",\n \"Laodiceans\"\n], S = K();\nfunction g(t, e = !0) {\n return e && (t = t.toUpperCase()), t in S ? S[t] : 0;\n}\nfunction k(t) {\n return g(t) > 0;\n}\nfunction x(t) {\n const e = typeof t == \"string\" ? g(t) : t;\n return e >= 40 && e <= 66;\n}\nfunction T(t) {\n return (typeof t == \"string\" ? g(t) : t) <= 39;\n}\nfunction X(t) {\n return t <= 66;\n}\nfunction V(t) {\n const e = typeof t == \"string\" ? g(t) : t;\n return w(e) && !X(e);\n}\nfunction* L() {\n for (let t = 1; t <= N.length; t++) yield t;\n}\nconst G = 1, A = N.length;\nfunction H() {\n return [\"XXA\", \"XXB\", \"XXC\", \"XXD\", \"XXE\", \"XXF\", \"XXG\"];\n}\nfunction C(t, e = \"***\") {\n const s = t - 1;\n return s < 0 || s >= N.length ? e : N[s];\n}\nfunction I(t) {\n return t <= 0 || t > A ? \"******\" : O[t - 1];\n}\nfunction y(t) {\n return I(g(t));\n}\nfunction w(t) {\n const e = typeof t == \"number\" ? C(t) : t;\n return k(e) && !B.includes(e);\n}\nfunction q(t) {\n const e = typeof t == \"number\" ? C(t) : t;\n return k(e) && B.includes(e);\n}\nfunction U(t) {\n return O[t - 1].includes(\"*obsolete*\");\n}\nfunction K() {\n const t = {};\n for (let e = 0; e < N.length; e++)\n t[N[e]] = e + 1;\n return t;\n}\nconst m = {\n allBookIds: N,\n nonCanonicalIds: B,\n bookIdToNumber: g,\n isBookIdValid: k,\n isBookNT: x,\n isBookOT: T,\n isBookOTNT: X,\n isBookDC: V,\n allBookNumbers: L,\n firstBook: G,\n lastBook: A,\n extraBooks: H,\n bookNumberToId: C,\n bookNumberToEnglishName: I,\n bookIdToEnglishName: y,\n isCanonical: w,\n isExtraMaterial: q,\n isObsolete: U\n};\nvar l = /* @__PURE__ */ ((t) => (t[t.Unknown = 0] = \"Unknown\", t[t.Original = 1] = \"Original\", t[t.Septuagint = 2] = \"Septuagint\", t[t.Vulgate = 3] = \"Vulgate\", t[t.English = 4] = \"English\", t[t.RussianProtestant = 5] = \"RussianProtestant\", t[t.RussianOrthodox = 6] = \"RussianOrthodox\", t))(l || {});\nconst h = class h {\n // private versInfo: Versification;\n constructor(e) {\n n(this, \"name\");\n n(this, \"fullPath\");\n n(this, \"isPresent\");\n n(this, \"hasVerseSegments\");\n n(this, \"isCustomized\");\n n(this, \"baseVersification\");\n n(this, \"scriptureBooks\");\n n(this, \"_type\");\n if (e == null)\n throw new Error(\"Argument undefined\");\n typeof e == \"string\" ? (this.name = e, this._type = l[e]) : (this._type = e, this.name = l[e]);\n }\n get type() {\n return this._type;\n }\n equals(e) {\n return !e.type || !this.type ? !1 : e.type === this.type;\n }\n};\nn(h, \"Original\", new h(l.Original)), n(h, \"Septuagint\", new h(l.Septuagint)), n(h, \"Vulgate\", new h(l.Vulgate)), n(h, \"English\", new h(l.English)), n(h, \"RussianProtestant\", new h(l.RussianProtestant)), n(h, \"RussianOrthodox\", new h(l.RussianOrthodox));\nlet c = h;\nfunction E(t, e) {\n const s = e[0];\n for (let r = 1; r < e.length; r++)\n t = t.split(e[r]).join(s);\n return t.split(s);\n}\nvar D = /* @__PURE__ */ ((t) => (t[t.Valid = 0] = \"Valid\", t[t.UnknownVersification = 1] = \"UnknownVersification\", t[t.OutOfRange = 2] = \"OutOfRange\", t[t.VerseOutOfOrder = 3] = \"VerseOutOfOrder\", t[t.VerseRepeated = 4] = \"VerseRepeated\", t))(D || {});\nconst i = class i {\n constructor(e, s, r, a) {\n /** Not yet implemented. */\n n(this, \"firstChapter\");\n /** Not yet implemented. */\n n(this, \"lastChapter\");\n /** Not yet implemented. */\n n(this, \"lastVerse\");\n /** Not yet implemented. */\n n(this, \"hasSegmentsDefined\");\n /** Not yet implemented. */\n n(this, \"text\");\n /** Not yet implemented. */\n n(this, \"BBBCCCVVVS\");\n /** Not yet implemented. */\n n(this, \"longHashCode\");\n /** The versification of the reference. */\n n(this, \"versification\");\n n(this, \"rtlMark\", \"‏\");\n n(this, \"_bookNum\", 0);\n n(this, \"_chapterNum\", 0);\n n(this, \"_verseNum\", 0);\n n(this, \"_verse\");\n if (r == null && a == null)\n if (e != null && typeof e == \"string\") {\n const o = e, u = s != null && s instanceof c ? s : void 0;\n this.setEmpty(u), this.parse(o);\n } else if (e != null && typeof e == \"number\") {\n const o = s != null && s instanceof c ? s : void 0;\n this.setEmpty(o), this._verseNum = e % i.chapterDigitShifter, this._chapterNum = Math.floor(\n e % i.bookDigitShifter / i.chapterDigitShifter\n ), this._bookNum = Math.floor(e / i.bookDigitShifter);\n } else if (s == null)\n if (e != null && e instanceof i) {\n const o = e;\n this._bookNum = o.bookNum, this._chapterNum = o.chapterNum, this._verseNum = o.verseNum, this._verse = o.verse, this.versification = o.versification;\n } else {\n if (e == null) return;\n const o = e instanceof c ? e : i.defaultVersification;\n this.setEmpty(o);\n }\n else\n throw new Error(\"VerseRef constructor not supported.\");\n else if (e != null && s != null && r != null)\n if (typeof e == \"string\" && typeof s == \"string\" && typeof r == \"string\")\n this.setEmpty(a), this.updateInternal(e, s, r);\n else if (typeof e == \"number\" && typeof s == \"number\" && typeof r == \"number\")\n this._bookNum = e, this._chapterNum = s, this._verseNum = r, this.versification = a ?? i.defaultVersification;\n else\n throw new Error(\"VerseRef constructor not supported.\");\n else\n throw new Error(\"VerseRef constructor not supported.\");\n }\n /**\n * Determines if the verse string is in a valid format (does not consider versification).\n */\n static isVerseParseable(e) {\n return e.length > 0 && \"0123456789\".includes(e[0]) && !e.endsWith(this.verseRangeSeparator) && !e.endsWith(this.verseSequenceIndicator);\n }\n /**\n * Tries to parse the specified string into a verse reference.\n * @param str - The string to attempt to parse.\n * @returns success: `true` if the specified string was successfully parsed, `false` otherwise.\n * @returns verseRef: The result of the parse if successful, or empty VerseRef if it failed\n */\n static tryParse(e) {\n let s;\n try {\n return s = new i(e), { success: !0, verseRef: s };\n } catch (r) {\n if (r instanceof v)\n return s = new i(), { success: !1, verseRef: s };\n throw r;\n }\n }\n /**\n * Gets the reference as a comparable integer where the book, chapter, and verse each occupy 3\n * digits.\n * @param bookNum - Book number (this is 1-based, not an index).\n * @param chapterNum - Chapter number.\n * @param verseNum - Verse number.\n * @returns The reference as a comparable integer where the book, chapter, and verse each occupy 3\n * digits.\n */\n static getBBBCCCVVV(e, s, r) {\n return e % i.bcvMaxValue * i.bookDigitShifter + (s >= 0 ? s % i.bcvMaxValue * i.chapterDigitShifter : 0) + (r >= 0 ? r % i.bcvMaxValue : 0);\n }\n /**\n * Deserializes a serialized VerseRef.\n * @param serializedVerseRef - Serialized VerseRef to create from.\n * @returns the deserialized VerseRef.\n */\n static fromJSON(e) {\n const { book: s, chapterNum: r, verseNum: a, verse: o, versificationStr: u } = e, f = o || a.toString();\n let d;\n return u && (d = new c(u)), s ? new i(s, r.toString(), f, d) : new i();\n }\n /**\n * Parses a verse string and gets the leading numeric portion as a number.\n * @param verseStr - verse string to parse\n * @returns true if the entire string could be parsed as a single, simple verse number (1-999);\n * false if the verse string represented a verse bridge, contained segment letters, or was invalid\n */\n static tryGetVerseNum(e) {\n let s;\n if (!e)\n return s = -1, { success: !0, vNum: s };\n s = 0;\n let r;\n for (let a = 0; a < e.length; a++) {\n if (r = e[a], r < \"0\" || r > \"9\")\n return a === 0 && (s = -1), { success: !1, vNum: s };\n if (s = s * 10 + +r - 0, s > i.bcvMaxValue)\n return s = -1, { success: !1, vNum: s };\n }\n return { success: !0, vNum: s };\n }\n /**\n * Checks to see if a VerseRef hasn't been set - all values are the default.\n */\n get isDefault() {\n return this.bookNum === 0 && this.chapterNum === 0 && this.verseNum === 0 && this.versification == null;\n }\n /**\n * Gets whether the verse contains multiple verses.\n */\n get hasMultiple() {\n return this._verse != null && (this._verse.includes(i.verseRangeSeparator) || this._verse.includes(i.verseSequenceIndicator));\n }\n /**\n * Gets or sets the book of the reference. Book is the 3-letter abbreviation in capital letters,\n * e.g. `'MAT'`.\n */\n get book() {\n return m.bookNumberToId(this.bookNum, \"\");\n }\n set book(e) {\n this.bookNum = m.bookIdToNumber(e);\n }\n /**\n * Gets or sets the chapter of the reference,. e.g. `'3'`.\n */\n get chapter() {\n return this.isDefault || this._chapterNum < 0 ? \"\" : this._chapterNum.toString();\n }\n set chapter(e) {\n const s = +e;\n this._chapterNum = Number.isInteger(s) ? s : -1;\n }\n /**\n * Gets or sets the verse of the reference, including range, segments, and sequences, e.g. `'4'`,\n * or `'4b-5a, 7'`.\n */\n get verse() {\n return this._verse != null ? this._verse : this.isDefault || this._verseNum < 0 ? \"\" : this._verseNum.toString();\n }\n set verse(e) {\n const { success: s, vNum: r } = i.tryGetVerseNum(e);\n this._verse = s ? void 0 : e.replace(this.rtlMark, \"\"), this._verseNum = r, !(this._verseNum >= 0) && ({ vNum: this._verseNum } = i.tryGetVerseNum(this._verse));\n }\n /**\n * Get or set Book based on book number, e.g. `42`.\n */\n get bookNum() {\n return this._bookNum;\n }\n set bookNum(e) {\n if (e <= 0 || e > m.lastBook)\n throw new v(\n \"BookNum must be greater than zero and less than or equal to last book\"\n );\n this._bookNum = e;\n }\n /**\n * Gets or sets the chapter number, e.g. `3`. `-1` if not valid.\n */\n get chapterNum() {\n return this._chapterNum;\n }\n set chapterNum(e) {\n this.chapterNum = e;\n }\n /**\n * Gets or sets verse start number, e.g. `4`. `-1` if not valid.\n */\n get verseNum() {\n return this._verseNum;\n }\n set verseNum(e) {\n this._verseNum = e;\n }\n /**\n * String representing the versification (should ONLY be used for serialization/deserialization).\n *\n * @remarks This is for backwards compatibility when ScrVers was an enumeration.\n */\n get versificationStr() {\n var e;\n return (e = this.versification) == null ? void 0 : e.name;\n }\n set versificationStr(e) {\n this.versification = this.versification != null ? new c(e) : void 0;\n }\n /**\n * Determines if the reference is valid.\n */\n get valid() {\n return this.validStatus === 0;\n }\n /**\n * Get the valid status for this reference.\n */\n get validStatus() {\n return this.validateVerse(i.verseRangeSeparators, i.verseSequenceIndicators);\n }\n /**\n * Gets the reference as a comparable integer where the book,\n * chapter, and verse each occupy three digits and the verse is 0.\n */\n get BBBCCC() {\n return i.getBBBCCCVVV(this._bookNum, this._chapterNum, 0);\n }\n /**\n * Gets the reference as a comparable integer where the book,\n * chapter, and verse each occupy three digits. If verse is not null\n * (i.e., this reference represents a complex reference with verse\n * segments or bridge) this cannot be used for an exact comparison.\n */\n get BBBCCCVVV() {\n return i.getBBBCCCVVV(this._bookNum, this._chapterNum, this._verseNum);\n }\n /**\n * Gets whether the verse is defined as an excluded verse in the versification.\n * Does not handle verse ranges.\n */\n // eslint-disable-next-line @typescript-eslint/class-literal-property-style\n get isExcluded() {\n return !1;\n }\n /**\n * Parses the reference in the specified string.\n * Optionally versification can follow reference as in GEN 3:11/4\n * Throw an exception if\n * - invalid book name\n * - chapter number is missing or not a number\n * - verse number is missing or does not start with a number\n * - versification is invalid\n * @param verseStr - string to parse e.g. 'MAT 3:11'\n */\n parse(e) {\n if (e = e.replace(this.rtlMark, \"\"), e.includes(\"/\")) {\n const o = e.split(\"/\");\n if (e = o[0], o.length > 1)\n try {\n const u = +o[1].trim();\n this.versification = new c(l[u]);\n } catch {\n throw new v(\"Invalid reference : \" + e);\n }\n }\n const s = e.trim().split(\" \");\n if (s.length !== 2)\n throw new v(\"Invalid reference : \" + e);\n const r = s[1].split(\":\"), a = +r[0];\n if (r.length !== 2 || m.bookIdToNumber(s[0]) === 0 || !Number.isInteger(a) || a < 0 || !i.isVerseParseable(r[1]))\n throw new v(\"Invalid reference : \" + e);\n this.updateInternal(s[0], r[0], r[1]);\n }\n /**\n * Simplifies this verse ref so that it has no bridging of verses or\n * verse segments like `'1a'`.\n */\n simplify() {\n this._verse = void 0;\n }\n /**\n * Makes a clone of the reference.\n *\n * @returns The cloned VerseRef.\n */\n clone() {\n return new i(this);\n }\n toString() {\n const e = this.book;\n return e === \"\" ? \"\" : `${e} ${this.chapter}:${this.verse}`;\n }\n toJSON() {\n let e = this.verse;\n (e === \"\" || e === this.verseNum.toString()) && (e = void 0);\n const s = {\n book: this.book,\n chapterNum: this.chapterNum,\n verseNum: this.verseNum,\n verse: e,\n versificationStr: this.versificationStr\n };\n return e || delete s.verse, s;\n }\n /**\n * Compares this `VerseRef` with supplied one.\n * @param verseRef - object to compare this one to.\n * @returns `true` if this `VerseRef` is equal to the supplied one, `false` otherwise.\n */\n equals(e) {\n return e instanceof i ? e._bookNum === this._bookNum && e._chapterNum === this._chapterNum && e._verseNum === this._verseNum && e.verse === this.verse && (e.versification == null && this.versification == null || e.versification != null && this.versification != null && e.versification.equals(this.versification)) : !1;\n }\n /**\n * Enumerate all individual verses contained in a VerseRef.\n * Verse ranges are indicated by \"-\" and consecutive verses by \",\"s.\n * Examples:\n * GEN 1:2 returns GEN 1:2\n * GEN 1:1a-3b,5 returns GEN 1:1a, GEN 1:2, GEN 1:3b, GEN 1:5\n * GEN 1:2a-2c returns //! ??????\n *\n * @param specifiedVersesOnly - if set to true return only verses that are\n * explicitly specified only, not verses within a range. Defaults to `false`.\n * @param verseRangeSeparators - Verse range separators.\n * Defaults to `VerseRef.verseRangeSeparators`.\n * @param verseSequenceSeparators - Verse sequence separators.\n * Defaults to `VerseRef.verseSequenceIndicators`.\n * @returns An array of all single verse references in this VerseRef.\n */\n allVerses(e = !1, s = i.verseRangeSeparators, r = i.verseSequenceIndicators) {\n if (this._verse == null || this.chapterNum <= 0)\n return [this.clone()];\n const a = [], o = E(this._verse, r);\n for (const u of o.map((f) => E(f, s))) {\n const f = this.clone();\n f.verse = u[0];\n const d = f.verseNum;\n if (a.push(f), u.length > 1) {\n const b = this.clone();\n if (b.verse = u[1], !e)\n for (let p = d + 1; p < b.verseNum; p++) {\n const J = new i(\n this._bookNum,\n this._chapterNum,\n p,\n this.versification\n );\n this.isExcluded || a.push(J);\n }\n a.push(b);\n }\n }\n return a;\n }\n /**\n * Validates a verse number using the supplied separators rather than the defaults.\n */\n validateVerse(e, s) {\n if (!this.verse)\n return this.internalValid;\n let r = 0;\n for (const a of this.allVerses(!0, e, s)) {\n const o = a.internalValid;\n if (o !== 0)\n return o;\n const u = a.BBBCCCVVV;\n if (r > u)\n return 3;\n if (r === u)\n return 4;\n r = u;\n }\n return 0;\n }\n /**\n * Gets whether a single verse reference is valid.\n */\n get internalValid() {\n return this.versification == null ? 1 : this._bookNum <= 0 || this._bookNum > m.lastBook ? 2 : (m.isCanonical(this._bookNum), 0);\n }\n setEmpty(e = i.defaultVersification) {\n this._bookNum = 0, this._chapterNum = -1, this._verse = void 0, this.versification = e;\n }\n updateInternal(e, s, r) {\n this.bookNum = m.bookIdToNumber(e), this.chapter = s, this.verse = r;\n }\n};\nn(i, \"defaultVersification\", c.English), n(i, \"verseRangeSeparator\", \"-\"), n(i, \"verseSequenceIndicator\", \",\"), n(i, \"verseRangeSeparators\", [i.verseRangeSeparator]), n(i, \"verseSequenceIndicators\", [i.verseSequenceIndicator]), n(i, \"chapterDigitShifter\", 1e3), n(i, \"bookDigitShifter\", i.chapterDigitShifter * i.chapterDigitShifter), n(i, \"bcvMaxValue\", i.chapterDigitShifter - 1), /**\n * The valid status of the VerseRef.\n */\nn(i, \"ValidStatusType\", D);\nlet M = i;\nclass v extends Error {\n}\nexport {\n _ as BookSet,\n m as Canon,\n c as ScrVers,\n l as ScrVersType,\n M as VerseRef,\n v as VerseRefException\n};\n//# sourceMappingURL=index.es.js.map\n","import React from 'react';\nimport * as DropdownMenuPrimitive from '@radix-ui/react-dropdown-menu';\nimport { Check, ChevronRight, Circle } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport const DropdownMenu = DropdownMenuPrimitive.Root;\n\nexport const DropdownMenuTrigger = DropdownMenuPrimitive.Trigger;\n\nexport const DropdownMenuGroup = DropdownMenuPrimitive.Group;\n\nexport const DropdownMenuPortal = DropdownMenuPrimitive.Portal;\n\nexport const DropdownMenuSub = DropdownMenuPrimitive.Sub;\n\nexport const DropdownMenuRadioGroup = DropdownMenuPrimitive.RadioGroup;\n\nexport type DropdownMenuSubTriggerProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.SubTrigger\n> & {\n className?: string;\n inset?: boolean;\n};\n\nexport type DropdownMenuSubContentProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.SubContent\n> & {\n className?: string;\n};\n\nexport type DropdownMenuContentProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Content\n> & {\n className?: string;\n sideOffset?: number;\n};\n\nexport type DropdownMenuItemProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Item\n> & {\n className?: string;\n inset?: boolean;\n};\n\nexport type DropdownMenuCheckboxItemProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.CheckboxItem\n> & {\n className?: string;\n checked?: boolean;\n};\n\nexport type DropdownMenuRadioItemProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.RadioItem\n> & {\n className?: string;\n};\n\nexport type DropdownMenuLabelProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Label\n> & {\n className?: string;\n inset?: boolean;\n};\n\nexport type DropdownMenuSeparatorProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Separator\n> & {\n className?: string;\n};\n\nexport type DropdownMenuShortcutProps = React.HTMLAttributes & {\n className?: string;\n};\n\nexport const DropdownMenuSubTrigger = React.forwardRef<\n React.ElementRef,\n DropdownMenuSubTriggerProps\n>(({ className, inset, children, ...props }, ref) => (\n \n {children}\n \n \n));\nDropdownMenuSubTrigger.displayName = DropdownMenuPrimitive.SubTrigger.displayName;\n\nexport const DropdownMenuSubContent = React.forwardRef<\n React.ElementRef,\n DropdownMenuSubContentProps\n>(({ className, ...props }, ref) => (\n \n));\nDropdownMenuSubContent.displayName = DropdownMenuPrimitive.SubContent.displayName;\n\nexport const DropdownMenuContent = React.forwardRef<\n React.ElementRef,\n DropdownMenuContentProps\n>(({ className, sideOffset = 4, ...props }, ref) => (\n \n \n \n));\nDropdownMenuContent.displayName = DropdownMenuPrimitive.Content.displayName;\n\n/**\n * TODO: fix: direction is not automatically handled by this component, so that shortcuts are\n * display always to the right\n */\nexport const DropdownMenuItem = React.forwardRef<\n React.ElementRef,\n DropdownMenuItemProps\n>(({ className, inset, ...props }, ref) => (\n \n));\nDropdownMenuItem.displayName = DropdownMenuPrimitive.Item.displayName;\n\nexport const DropdownMenuCheckboxItem = React.forwardRef<\n React.ElementRef,\n DropdownMenuCheckboxItemProps\n>(({ className, children, checked, ...props }, ref) => (\n \n \n \n \n \n \n {children}\n \n));\nDropdownMenuCheckboxItem.displayName = DropdownMenuPrimitive.CheckboxItem.displayName;\n\nexport const DropdownMenuRadioItem = React.forwardRef<\n React.ElementRef,\n DropdownMenuRadioItemProps\n>(({ className, children, ...props }, ref) => (\n \n \n \n \n \n \n {children}\n \n));\nDropdownMenuRadioItem.displayName = DropdownMenuPrimitive.RadioItem.displayName;\n\nexport const DropdownMenuLabel = React.forwardRef<\n React.ElementRef,\n DropdownMenuLabelProps\n>(({ className, inset, ...props }, ref) => (\n \n));\nDropdownMenuLabel.displayName = DropdownMenuPrimitive.Label.displayName;\n\nexport const DropdownMenuSeparator = React.forwardRef<\n React.ElementRef,\n DropdownMenuSeparatorProps\n>(({ className, ...props }, ref) => (\n \n));\nDropdownMenuSeparator.displayName = DropdownMenuPrimitive.Separator.displayName;\n\nexport function DropdownMenuShortcut({ className, ...props }: DropdownMenuShortcutProps) {\n return (\n \n );\n}\nDropdownMenuShortcut.displayName = 'DropdownMenuShortcut';\n","import { Canon } from '@sillsdev/scripture';\nimport { PropsWithChildren, KeyboardEvent, forwardRef } from 'react';\nimport { DropdownMenuItem as ShadDropdownMenuItem } from '@/components/shadcn-ui/dropdown-menu';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport type BookType = 'OT' | 'NT' | 'DC';\n\ntype BookMenuItemProps = PropsWithChildren<{\n /** String id of book */\n bookId: string;\n /** Callback to run when a book menu item is selected */\n handleSelectBook: () => void;\n /** Indicates if this menu item is currently selected */\n isSelected: boolean;\n /** Function that is called upon highlighting a book in the dropdown menu */\n handleHighlightBook: () => void;\n /**\n * Function that is called on pressing a key\n *\n * @param event Event that contains information about the key stroke\n */\n handleKeyDown: (event: KeyboardEvent) => void;\n /**\n * Type of book associated with this menu item, coordinates color labels ? Mock up has the labels\n * coordinated to genre\n */\n bookType: BookType;\n}>;\n\nconst BookMenuItem = forwardRef(\n (\n {\n bookId,\n handleSelectBook,\n isSelected,\n handleHighlightBook,\n handleKeyDown,\n bookType,\n children,\n }: BookMenuItemProps,\n ref,\n ) => {\n return (\n {\n // preventDefault() here prevents the entire dropdown menu from closing when selecting this item\n event.preventDefault();\n handleSelectBook();\n }}\n onKeyDown={(event: KeyboardEvent) => {\n handleKeyDown(event);\n }}\n onFocus={handleHighlightBook}\n onMouseMove={handleHighlightBook}\n >\n \n {Canon.bookIdToEnglishName(bookId)}\n \n {isSelected &&
    {children}
    }\n \n );\n },\n);\n\nexport default BookMenuItem;\n","import { cn } from '@/utils/shadcn-ui.util';\nimport { useCallback } from 'react';\n\nexport type ChapterSelectProps = {\n /**\n * Callback to run when a chapter div is selected\n *\n * @param chapterNumber Number of the chapter that has been selected\n */\n handleSelectChapter: (chapterNumber: number) => void;\n /** The highest chapter number in the book (of course equal to number of chapters in the book) */\n endChapter: number;\n /** The chapter number that is currently selected */\n activeChapter: number;\n /** The chapter number that is currently highlighted using keyboard or mouse navigation */\n highlightedChapter: number;\n /**\n * Callback to run when a chapter is highlighted by the user\n *\n * @param chapterNumber The chapter that is highlighted\n */\n handleHighlightedChapter: (chapterNumber: number) => void;\n};\n\nfunction ChapterSelect({\n handleSelectChapter,\n endChapter,\n activeChapter,\n highlightedChapter,\n handleHighlightedChapter,\n}: ChapterSelectProps) {\n const chapters = Array.from({ length: endChapter }, (_, i) => i + 1);\n\n const handleMouse = useCallback(\n (chapterNumber: number) => {\n handleHighlightedChapter(chapterNumber);\n },\n [handleHighlightedChapter],\n );\n\n return (\n
    \n {chapters.map((chapter) => (\n {\n event.preventDefault();\n event.stopPropagation();\n handleSelectChapter(chapter);\n }}\n role=\"button\"\n onKeyDown={(event) => {\n if (event.key === 'Enter') {\n handleSelectChapter(chapter);\n }\n }}\n tabIndex={0}\n onMouseMove={() => handleMouse(chapter)}\n >\n {chapter}\n
    \n ))}\n
    \n );\n}\n\nexport default ChapterSelect;\n","import { DropdownMenuLabel as ShadDropdownMenuLabel } from '@/components/shadcn-ui/dropdown-menu';\nimport { Bookmark, Clock, ArrowDownWideNarrow } from 'lucide-react';\n\nexport type GoToMenuItemProps = {\n handleSort: () => void;\n handleLocationHistory: () => void;\n handleBookmarks: () => void;\n};\n\nfunction GoToMenuItem({ handleSort, handleLocationHistory, handleBookmarks }: GoToMenuItemProps) {\n return (\n \n

    Go To

    \n
    \n \n \n \n
    \n
    \n );\n}\n\nexport default GoToMenuItem;\n","import BookChapterInput from '@/components/advanced/book-chapter-control/book-chapter-input.component';\nimport BookMenuItem, {\n BookType,\n} from '@/components/advanced/book-chapter-control/book-menu-item.component';\nimport ChapterSelect from '@/components/advanced/book-chapter-control/chapter-select.component';\nimport GoToMenuItem from '@/components/advanced/book-chapter-control/go-to-menu-item.component';\nimport {\n DropdownMenu as ShadDropdownMenu,\n DropdownMenuContent as ShadDropdownMenuContent,\n DropdownMenuLabel as ShadDropdownMenuLabel,\n DropdownMenuSeparator as ShadDropdownMenuSeparator,\n DropdownMenuTrigger as ShadDropdownMenuTrigger,\n} from '@/components/shadcn-ui/dropdown-menu';\nimport { Canon } from '@sillsdev/scripture';\nimport { ScriptureReference, getChaptersForBook } from 'platform-bible-utils';\nimport {\n KeyboardEvent as ReactKeyboardEvent,\n useCallback,\n useEffect,\n useLayoutEffect,\n useRef,\n useState,\n} from 'react';\n\ntype BookTypeLabels = {\n [bookType in BookType]: string;\n};\ntype BookChapterControlProps = {\n scrRef: ScriptureReference;\n handleSubmit: (scrRef: ScriptureReference) => void;\n};\n\nconst ALL_BOOK_IDS = Canon.allBookIds;\nconst BOOK_TYPE_LABELS: BookTypeLabels = {\n OT: 'Old Testament',\n NT: 'New Testament',\n DC: 'Deuterocanon',\n};\nconst BOOK_TYPE_ARRAY: BookType[] = ['OT', 'NT', 'DC'];\n// This is the height of three menu items to offset scrolling to the selected menu item\n// If you use menuItemRef.clientHeight- includes height of chapter div which is too big\nconst SCROLL_OFFSET = 32 + 32 + 32;\nconst SEARCH_QUERY_FORMATS = [\n /^(\\w+)$/i, // Matches a single word (book name or id)\n /^(\\w+)(?:\\s(\\d+))$/i, // Matches a word followed by a chapter number\n /^(\\w+)(?:\\s(\\d+):(\\d+))$/i, // Matches a word followed by a chapter and verse number\n];\nconst fetchGroupedBooks = (bookType: BookType) => {\n const groupedBooks = {\n OT: ALL_BOOK_IDS.filter((bookId) => Canon.isBookOT(bookId)),\n NT: ALL_BOOK_IDS.filter((bookId) => Canon.isBookNT(bookId)),\n DC: ALL_BOOK_IDS.filter((bookId) => Canon.isBookDC(bookId)),\n };\n return groupedBooks[bookType];\n};\nconst fetchEndChapter = (bookId: string) => {\n // getChaptersForBook returns -1 if not found in scrBookData\n // scrBookData only includes OT and NT, so all DC will return -1\n return getChaptersForBook(Canon.bookIdToNumber(bookId));\n};\n\n/**\n * Gets all of the English names from book ids\n *\n * @returns String[]\n */\nfunction getAllEnglishNames(): string[] {\n const allEnglishNames = ALL_BOOK_IDS.map((bookId) => {\n return Canon.bookIdToEnglishName(bookId);\n });\n return allEnglishNames;\n}\n\n/**\n * Determines if bookName is in allEnglishNames\n *\n * @param bookName Book English name\n * @returns True if bookName is included, false otherwise\n */\nfunction isValidBookEnglishName(bookName: string): boolean {\n return getAllEnglishNames().includes(bookName);\n}\n\n/**\n * Gets a bookId from given English name\n *\n * @param bookName Book English name\n * @returns BookId of provided bookName, undefined otherwise\n */\nfunction getBookIdFromEnglishName(bookName: string): string | undefined {\n // Convert bookName to lowercase and then capitalize the first letter\n const formattedBookName = bookName.toLowerCase().replace(/^\\w/, (c) => c.toUpperCase());\n\n if (isValidBookEnglishName(formattedBookName)) {\n const matchingBookId = ALL_BOOK_IDS.find((bookId) => {\n return Canon.bookIdToEnglishName(bookId) === formattedBookName;\n });\n return matchingBookId;\n }\n\n return undefined;\n}\n\nfunction BookChapterControl({ scrRef, handleSubmit }: BookChapterControlProps) {\n const [searchQuery, setSearchQuery] = useState('');\n const [selectedBookId, setSelectedBookId] = useState(\n Canon.bookNumberToId(scrRef.bookNum),\n );\n const [highlightedChapter, setHighlightedChapter] = useState(scrRef.chapterNum ?? 0);\n const [highlightedBookId, setHighlightedBookId] = useState(\n Canon.bookNumberToId(scrRef.bookNum),\n );\n const [isContentOpen, setIsContentOpen] = useState(false);\n const [isContentOpenDelayed, setIsContentOpenDelayed] = useState(isContentOpen);\n\n // This ref will always be defined\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const inputRef = useRef(undefined!);\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const contentRef = useRef(undefined!);\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const menuItemRef = useRef(undefined!);\n\n const fetchFilteredBooks = useCallback(\n (bookType: BookType) => {\n return fetchGroupedBooks(bookType).filter((bookId: string) => {\n const englishNameLowerCase = Canon.bookIdToEnglishName(bookId).toLowerCase();\n const normalizedQuery = searchQuery.replace(/[^a-zA-Z]/g, '').toLowerCase();\n return (\n englishNameLowerCase.includes(normalizedQuery) || // Match book name\n bookId.toLowerCase().includes(normalizedQuery) // Match book ID\n );\n });\n },\n [searchQuery],\n );\n\n const handleSearchInput = (searchString: string) => {\n setSearchQuery(searchString);\n };\n\n /**\n * Whether to prevent radix's logic from closing the dropdown. This is important because radix\n * tries to close the dropdown when the input first focuses, and we don't want it to do that. But\n * we don't want to prevent the dropdown from closing when we click away from the input, so we\n * don't want to just keep it open if the input is focused\n */\n const shouldPreventAutoClosing = useRef(false);\n\n const controlMenuState = useCallback((open: boolean) => {\n if (shouldPreventAutoClosing.current) {\n shouldPreventAutoClosing.current = false;\n return;\n }\n setIsContentOpen(open);\n }, []);\n\n const updateReference = useCallback(\n (bookId: string, shouldClose: boolean, chapter?: number, verse?: number) => {\n setHighlightedChapter(\n Canon.bookNumberToId(scrRef.bookNum) !== bookId ? 1 : scrRef.chapterNum,\n );\n\n if (shouldClose || fetchEndChapter(bookId) === -1) {\n handleSubmit({\n bookNum: Canon.bookIdToNumber(bookId),\n chapterNum: chapter || 1,\n verseNum: verse || 1,\n });\n\n setIsContentOpen(false);\n setSearchQuery('');\n return;\n }\n\n setSelectedBookId(selectedBookId !== bookId ? bookId : '');\n setIsContentOpen(!shouldClose);\n },\n [handleSubmit, scrRef.bookNum, scrRef.chapterNum, selectedBookId],\n );\n\n const handleSelectChapter = (chapterNumber: number) => {\n if (chapterNumber <= 0 || chapterNumber > fetchEndChapter(selectedBookId)) {\n return;\n }\n updateReference(selectedBookId, true, chapterNumber);\n };\n\n const handleInputSubmit = useCallback(() => {\n SEARCH_QUERY_FORMATS.forEach((format) => {\n const matches = searchQuery.match(format);\n if (matches) {\n // Book should be a bookId or an english name\n const [book, chapter = undefined, verse = undefined] = matches.slice(1);\n const englishName = getBookIdFromEnglishName(book);\n\n if (Canon.isBookIdValid(book) || englishName) {\n updateReference(\n englishName ?? book,\n true,\n chapter ? parseInt(chapter, 10) : 1,\n verse ? parseInt(verse, 10) : 1,\n );\n }\n }\n });\n }, [updateReference, searchQuery]);\n\n const handleKeyDownInput = useCallback(\n (event: ReactKeyboardEvent) => {\n if (!isContentOpen) {\n setIsContentOpen(true);\n } else if (event.key === 'ArrowDown' || event.key === 'ArrowUp') {\n if (\n typeof menuItemRef !== 'undefined' &&\n // Ref uses null\n // eslint-disable-next-line no-null/no-null\n menuItemRef.current !== null\n ) {\n menuItemRef.current.focus();\n } else if (\n typeof contentRef !== 'undefined' &&\n // Ref uses null\n // eslint-disable-next-line no-null/no-null\n contentRef.current !== null\n ) {\n contentRef.current.focus();\n }\n event.preventDefault();\n }\n },\n [isContentOpen],\n );\n\n const handleKeyDownContent = (event: ReactKeyboardEvent) => {\n // When the dropdown menu has focus, key strokes should give focus to the input component,\n // unless they're navigation keys (arrows and enter)\n const { key } = event;\n if (\n key === 'ArrowRight' ||\n key === 'ArrowLeft' ||\n key === 'ArrowDown' ||\n key === 'ArrowUp' ||\n key === 'Enter'\n ) {\n return;\n }\n\n inputRef.current.dispatchEvent(new KeyboardEvent('keydown', { key }));\n inputRef.current.focus();\n };\n\n const handleKeyDownMenuItem = (event: ReactKeyboardEvent) => {\n const { key } = event;\n if (highlightedBookId === selectedBookId) {\n if (key === 'Enter') {\n event.preventDefault();\n updateReference(selectedBookId, true, highlightedChapter);\n return;\n }\n\n let chapterOffSet = 0;\n if (key === 'ArrowRight') {\n if (highlightedChapter < fetchEndChapter(highlightedBookId)) {\n chapterOffSet = 1;\n } else {\n event.preventDefault();\n return;\n }\n } else if (key === 'ArrowLeft') {\n if (highlightedChapter > 1) {\n chapterOffSet = -1;\n } else {\n event.preventDefault();\n return;\n }\n } else if (key === 'ArrowDown') {\n chapterOffSet = 6;\n } else if (key === 'ArrowUp') {\n chapterOffSet = -6;\n }\n if (\n highlightedChapter + chapterOffSet <= 0 ||\n highlightedChapter + chapterOffSet > fetchEndChapter(highlightedBookId)\n ) {\n setHighlightedChapter(0);\n } else if (chapterOffSet !== 0) {\n setHighlightedChapter(highlightedChapter + chapterOffSet);\n event.preventDefault();\n }\n }\n };\n\n useEffect(() => {\n if (selectedBookId === highlightedBookId) {\n if (selectedBookId === Canon.bookNumberToId(scrRef.bookNum)) {\n setHighlightedChapter(scrRef.chapterNum);\n } else {\n setHighlightedChapter(1);\n }\n } else {\n setHighlightedChapter(0);\n }\n }, [highlightedBookId, scrRef.bookNum, scrRef.chapterNum, selectedBookId]);\n\n // The purpose of these useLayoutEffects and timeout is to delay the scroll just\n // enough so that the refs are defined and available when they are used after the timeout\n useLayoutEffect(() => {\n setIsContentOpenDelayed(isContentOpen);\n }, [isContentOpen]);\n\n useLayoutEffect(() => {\n const scrollTimeout = setTimeout(() => {\n if (isContentOpenDelayed && contentRef.current && menuItemRef.current) {\n const menuItemOffsetTop = menuItemRef.current.offsetTop;\n const scrollPosition = menuItemOffsetTop - SCROLL_OFFSET;\n contentRef.current.scrollTo({ top: scrollPosition, behavior: 'instant' });\n }\n }, 10);\n return () => {\n clearTimeout(scrollTimeout);\n };\n }, [isContentOpenDelayed]);\n\n return (\n
    \n \n \n {\n setSelectedBookId(Canon.bookNumberToId(scrRef.bookNum));\n setHighlightedBookId(Canon.bookNumberToId(scrRef.bookNum));\n setHighlightedChapter(scrRef.chapterNum > 0 ? scrRef.chapterNum : 0);\n setIsContentOpen(true);\n inputRef.current.focus();\n }}\n onFocus={() => {\n // Radix thinks we want to close because the input is being focused. Prevent that\n shouldPreventAutoClosing.current = true;\n }}\n handleSubmit={handleInputSubmit}\n placeholder={`${Canon.bookNumberToEnglishName(scrRef.bookNum)} ${scrRef.chapterNum}:${scrRef.verseNum}`}\n />\n \n \n console.log('sorting')}\n handleLocationHistory={() => console.log('location history')}\n handleBookmarks={() => console.log('bookmarks')}\n />\n {BOOK_TYPE_ARRAY.map(\n (bookType, bookTypeIndex) =>\n fetchFilteredBooks(bookType).length > 0 && (\n
    \n \n {BOOK_TYPE_LABELS[bookType]}\n \n\n {fetchFilteredBooks(bookType).map((bookId) => (\n
    \n updateReference(bookId, false)}\n isSelected={selectedBookId === bookId}\n handleHighlightBook={() => setHighlightedBookId(bookId)}\n handleKeyDown={handleKeyDownMenuItem}\n bookType={bookType}\n ref={(element: HTMLDivElement) => {\n if (selectedBookId === bookId) menuItemRef.current = element;\n }}\n >\n {\n setHighlightedChapter(chapterNumber);\n }}\n />\n \n
    \n ))}\n {BOOK_TYPE_ARRAY.length - 1 !== bookTypeIndex ? (\n \n ) : undefined}\n
    \n ),\n )}\n \n
    \n
    \n );\n}\n\nexport default BookChapterControl;\n","import React from 'react';\nimport { Slot } from '@radix-ui/react-slot';\nimport { cva, type VariantProps } from 'class-variance-authority';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport const buttonVariants = cva(\n 'pr-twp tw-inline-flex tw-items-center tw-justify-center tw-whitespace-nowrap tw-rounded-md tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-colors focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50',\n {\n variants: {\n variant: {\n default: 'tw-bg-primary tw-text-primary-foreground hover:tw-bg-primary/90',\n destructive: 'tw-bg-destructive tw-text-destructive-foreground hover:tw-bg-destructive/90',\n outline:\n 'tw-border tw-border-input tw-bg-background hover:tw-bg-accent hover:tw-text-accent-foreground',\n secondary: 'tw-bg-secondary tw-text-secondary-foreground hover:tw-bg-secondary/80',\n ghost: 'hover:tw-bg-accent hover:tw-text-accent-foreground',\n link: 'tw-text-primary tw-underline-offset-4 hover:tw-underline',\n },\n size: {\n default: 'tw-h-10 tw-px-4 tw-py-2',\n sm: 'tw-h-9 tw-rounded-md tw-px-3',\n lg: 'tw-h-11 tw-rounded-md tw-px-8',\n icon: 'tw-h-10 tw-w-10',\n },\n },\n defaultVariants: {\n variant: 'default',\n size: 'default',\n },\n },\n);\n\nexport interface ButtonProps\n extends React.ButtonHTMLAttributes,\n VariantProps {\n asChild?: boolean;\n}\n\nexport const Button = React.forwardRef(\n ({ className, variant, size, asChild = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'button';\n return (\n \n );\n },\n);\nButton.displayName = 'Button';\n","import React from 'react';\nimport * as LabelPrimitive from '@radix-ui/react-label';\nimport { cva, type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst labelVariants = cva(\n 'tw-text-sm tw-font-medium tw-leading-none peer-disabled:tw-cursor-not-allowed peer-disabled:tw-opacity-70',\n);\n\nexport const Label = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef & VariantProps\n>(({ className, ...props }, ref) => (\n \n));\nLabel.displayName = LabelPrimitive.Root.displayName;\n","import React from 'react';\nimport * as RadioGroupPrimitive from '@radix-ui/react-radio-group';\nimport { Circle } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst RadioGroup = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => {\n return (\n \n );\n});\nRadioGroup.displayName = RadioGroupPrimitive.Root.displayName;\n\nconst RadioGroupItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => {\n return (\n \n \n \n \n \n );\n});\nRadioGroupItem.displayName = RadioGroupPrimitive.Item.displayName;\n\nexport { RadioGroup, RadioGroupItem };\n","import React from 'react';\nimport * as PopoverPrimitive from '@radix-ui/react-popover';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Popover = PopoverPrimitive.Root;\n\nconst PopoverTrigger = PopoverPrimitive.Trigger;\n\nconst PopoverContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, align = 'center', sideOffset = 4, ...props }, ref) => (\n \n \n \n));\nPopoverContent.displayName = PopoverPrimitive.Content.displayName;\n\nexport { Popover, PopoverTrigger, PopoverContent };\n","import React from 'react';\nimport * as DialogPrimitive from '@radix-ui/react-dialog';\nimport { X } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Dialog = DialogPrimitive.Root;\n\nconst DialogTrigger = DialogPrimitive.Trigger;\n\nconst DialogPortal = DialogPrimitive.Portal;\n\nconst DialogClose = DialogPrimitive.Close;\n\nconst DialogOverlay = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nDialogOverlay.displayName = DialogPrimitive.Overlay.displayName;\n\nconst DialogContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, ...props }, ref) => (\n \n \n \n {children}\n \n \n Close\n \n \n \n));\nDialogContent.displayName = DialogPrimitive.Content.displayName;\n\nfunction DialogHeader({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nDialogHeader.displayName = 'DialogHeader';\n\nfunction DialogFooter({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nDialogFooter.displayName = 'DialogFooter';\n\nconst DialogTitle = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nDialogTitle.displayName = DialogPrimitive.Title.displayName;\n\nconst DialogDescription = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nDialogDescription.displayName = DialogPrimitive.Description.displayName;\n\nexport {\n Dialog,\n DialogPortal,\n DialogOverlay,\n DialogClose,\n DialogTrigger,\n DialogContent,\n DialogHeader,\n DialogFooter,\n DialogTitle,\n DialogDescription,\n};\n","import React from 'react';\nimport { type DialogProps } from '@radix-ui/react-dialog';\nimport { Command as CommandPrimitive } from 'cmdk';\nimport { Search } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Dialog, DialogContent } from '@/components/shadcn-ui/dialog';\n\nconst Command = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nCommand.displayName = CommandPrimitive.displayName;\n\ninterface CommandDialogProps extends DialogProps {}\n\nfunction CommandDialog({ children, ...props }: CommandDialogProps) {\n return (\n \n \n \n {children}\n \n \n \n );\n}\n\nconst CommandInput = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n
    \n \n \n
    \n));\n\nCommandInput.displayName = CommandPrimitive.Input.displayName;\n\nconst CommandList = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\n\nCommandList.displayName = CommandPrimitive.List.displayName;\n\nconst CommandEmpty = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>((props, ref) => (\n \n));\n\nCommandEmpty.displayName = CommandPrimitive.Empty.displayName;\n\nconst CommandGroup = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\n\nCommandGroup.displayName = CommandPrimitive.Group.displayName;\n\nconst CommandSeparator = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nCommandSeparator.displayName = CommandPrimitive.Separator.displayName;\n\nconst CommandItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\n\nCommandItem.displayName = CommandPrimitive.Item.displayName;\n\nfunction CommandShortcut({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nCommandShortcut.displayName = 'CommandShortcut';\n\nexport {\n Command,\n CommandDialog,\n CommandInput,\n CommandList,\n CommandEmpty,\n CommandGroup,\n CommandItem,\n CommandShortcut,\n CommandSeparator,\n};\n","import { useState } from 'react';\nimport { Check, ChevronsUpDown } from 'lucide-react';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport { Popover, PopoverContent, PopoverTrigger } from '@/components/shadcn-ui/popover';\nimport {\n Command,\n CommandEmpty,\n CommandInput,\n CommandItem,\n CommandList,\n} from '@/components/shadcn-ui/command';\nimport { PopoverProps } from '@radix-ui/react-popover';\n\nexport type ComboBoxLabelOption = { label: string };\nexport type ComboBoxOption = string | number | ComboBoxLabelOption;\n\nexport type ComboBoxProps = {\n /** Optional unique identifier */\n id?: string;\n /** Text label title for combobox */\n /** List of available options for the dropdown menu */\n options?: readonly T[];\n /** Additional css classes to help with unique styling of the combo box button */\n buttonClassName?: string;\n /** Additional css classes to help with unique styling of the combo box popover */\n popoverContentClassName?: string;\n /**\n * The selected value that the combo box currently holds. Must be shallow equal to one of the\n * options entries.\n */\n value?: T;\n /** Triggers when content of textfield is changed */\n onChange?: (newValue: T) => void;\n /** Used to determine the string value for a given option. */\n getOptionLabel?: (option: ComboBoxOption) => string;\n /** Text displayed on button if `value` is undefined */\n buttonPlaceholder?: string;\n /** Placeholder text for text field */\n textPlaceholder?: string;\n /** Text to display when no options match input */\n commandEmptyMessage?: string;\n /** Variant of button */\n buttonVariant?: ButtonProps['variant'];\n /** Text direction ltr or rtl */\n dir?: Direction;\n /** Optional boolean to set if trigger should be disabled */\n isDisabled?: boolean;\n} & PopoverProps;\n\ntype Direction = 'ltr' | 'rtl';\n\nfunction getOptionLabelDefault(option: ComboBoxOption): string {\n if (typeof option === 'string') {\n return option;\n }\n if (typeof option === 'number') {\n return option.toString();\n }\n return option.label;\n}\n\n/**\n * Autocomplete input and command palette with a list of suggestions.\n *\n * Thanks to Shadcn for heavy inspiration and documentation\n * https://ui.shadcn.com/docs/components/combobox\n */\nfunction ComboBox({\n id,\n options = [],\n buttonClassName,\n popoverContentClassName,\n value,\n onChange = () => {},\n getOptionLabel = getOptionLabelDefault,\n buttonPlaceholder = '',\n textPlaceholder = '',\n commandEmptyMessage = 'No option found',\n buttonVariant = 'outline',\n dir = 'ltr',\n isDisabled = false,\n ...props\n}: ComboBoxProps) {\n const [open, setOpen] = useState(false);\n\n return (\n \n \n \n \n {value ? getOptionLabel(value) : buttonPlaceholder}\n \n \n \n \n \n \n \n {commandEmptyMessage}\n \n {options.map((option) => (\n {\n onChange(option);\n setOpen(false);\n }}\n >\n \n {getOptionLabel(option)}\n \n ))}\n \n \n \n \n );\n}\n\nexport default ComboBox;\n","import { useMemo } from 'react';\nimport ComboBox from '@/components/basics/combo-box.component';\nimport { Label } from '@/components/shadcn-ui/label';\n\nexport type ChapterRangeSelectorProps = {\n startChapter: number;\n endChapter: number;\n handleSelectStartChapter: (chapter: number) => void;\n handleSelectEndChapter: (chapter: number) => void;\n isDisabled?: boolean;\n chapterCount: number;\n};\n\nexport default function ChapterRangeSelector({\n startChapter,\n endChapter,\n handleSelectStartChapter,\n handleSelectEndChapter,\n isDisabled = false,\n chapterCount,\n}: ChapterRangeSelectorProps) {\n const chapterOptions = useMemo(\n () => Array.from({ length: chapterCount }, (_, index) => index + 1),\n [chapterCount],\n );\n\n const onChangeStartChapter = (value: number) => {\n handleSelectStartChapter(value);\n if (value > endChapter) {\n handleSelectEndChapter(value);\n }\n };\n\n const onChangeEndChapter = (value: number) => {\n handleSelectEndChapter(value);\n if (value < startChapter) {\n handleSelectStartChapter(value);\n }\n };\n\n return (\n <>\n \n option.toString()}\n value={startChapter}\n />\n\n \n option.toString()}\n value={endChapter}\n />\n \n );\n}\n","import { Button } from '@/components/shadcn-ui/button';\nimport { Label } from '@/components/shadcn-ui/label';\nimport { RadioGroup, RadioGroupItem } from '@/components/shadcn-ui/radio-group';\nimport { Canon } from '@sillsdev/scripture';\nimport { LocalizedStringValue } from 'platform-bible-utils';\nimport { useState } from 'react';\nimport ChapterRangeSelector, {\n ChapterRangeSelectorProps,\n} from '../basics/chapter-range-selector.component';\n\nexport enum BookSelectionMode {\n CURRENT_BOOK = 'current book',\n CHOOSE_BOOKS = 'choose books',\n}\n\n/**\n * Object containing all keys used for localization in this component. If you're using this\n * component in an extension, you can pass it into the useLocalizedStrings hook to easily obtain the\n * localized strings and pass them into the localizedStrings prop of this component\n */\nexport const BOOK_SELECTOR_STRING_KEYS = Object.freeze([\n '%webView_bookSelector_currentBook%',\n '%webView_bookSelector_choose%',\n '%webView_bookSelector_chooseBooks%',\n] as const);\n\nexport type BookSelectorLocalizedStrings = {\n [localizedInventoryKey in (typeof BOOK_SELECTOR_STRING_KEYS)[number]]?: LocalizedStringValue;\n};\n\n/**\n * Gets the localized value for the provided key\n *\n * @param strings Object containing localized string\n * @param key Key for a localized string\n * @returns The localized value for the provided key, if available. Returns the key if no localized\n * value is available\n */\nconst localizeString = (\n strings: BookSelectorLocalizedStrings,\n key: keyof BookSelectorLocalizedStrings,\n) => {\n return strings[key] ?? key;\n};\n\ntype BookSelectorProps = ChapterRangeSelectorProps & {\n handleBookSelectionModeChange: (newMode: BookSelectionMode) => void;\n currentBookName: string;\n onSelectBooks: () => void;\n selectedBookIds: string[];\n localizedStrings: BookSelectorLocalizedStrings;\n};\n\nexport default function BookSelector({\n handleBookSelectionModeChange,\n currentBookName,\n onSelectBooks,\n selectedBookIds,\n chapterCount,\n endChapter,\n handleSelectEndChapter,\n startChapter,\n handleSelectStartChapter,\n localizedStrings,\n}: BookSelectorProps) {\n const currentBookText = localizeString(localizedStrings, '%webView_bookSelector_currentBook%');\n const chooseText = localizeString(localizedStrings, '%webView_bookSelector_choose%');\n const chooseBooksText = localizeString(localizedStrings, '%webView_bookSelector_chooseBooks%');\n\n const [bookSelectionMode, setBookSelectionMode] = useState(\n BookSelectionMode.CURRENT_BOOK,\n );\n\n const onSelectionModeChange = (newMode: BookSelectionMode) => {\n setBookSelectionMode(newMode);\n handleBookSelectionModeChange(newMode);\n };\n\n return (\n onSelectionModeChange(value as BookSelectionMode)}\n >\n
    \n
    \n
    \n \n \n
    \n \n
    \n \n
    \n
    \n
    \n
    \n \n \n
    \n \n onSelectBooks()}\n >\n {chooseText}\n \n
    \n
    \n \n );\n}\n","import { DropdownMenuTrigger } from '@radix-ui/react-dropdown-menu';\nimport { FilterIcon } from 'lucide-react';\nimport { Table } from '@tanstack/react-table';\n\nimport { Button } from '@/components/shadcn-ui/button';\nimport {\n DropdownMenu,\n DropdownMenuCheckboxItem,\n DropdownMenuContent,\n DropdownMenuLabel,\n DropdownMenuSeparator,\n} from '@/components/shadcn-ui/dropdown-menu';\n\ninterface DataTableViewOptionsProps {\n table: Table;\n}\n\nfunction DataTableViewOptions({ table }: DataTableViewOptionsProps) {\n return (\n \n \n \n \n \n Toggle columns\n \n {table\n .getAllColumns()\n .filter((column) => column.getCanHide())\n .map((column) => {\n return (\n column.toggleVisibility(!!value)}\n >\n {column.id}\n \n );\n })}\n \n \n );\n}\n\nexport default DataTableViewOptions;\n","import React from 'react';\nimport * as SelectPrimitive from '@radix-ui/react-select';\nimport { Check, ChevronDown, ChevronUp } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Select = SelectPrimitive.Root;\n\nconst SelectGroup = SelectPrimitive.Group;\n\nconst SelectValue = SelectPrimitive.Value;\n\nconst SelectTrigger = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, ...props }, ref) => (\n span]:tw-line-clamp-1',\n className,\n )}\n {...props}\n >\n {children}\n \n \n \n \n));\nSelectTrigger.displayName = SelectPrimitive.Trigger.displayName;\n\nconst SelectScrollUpButton = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n));\nSelectScrollUpButton.displayName = SelectPrimitive.ScrollUpButton.displayName;\n\nconst SelectScrollDownButton = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n));\nSelectScrollDownButton.displayName = SelectPrimitive.ScrollDownButton.displayName;\n\nconst SelectContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, position = 'popper', ...props }, ref) => (\n \n \n \n \n {children}\n \n \n \n \n));\nSelectContent.displayName = SelectPrimitive.Content.displayName;\n\nconst SelectLabel = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSelectLabel.displayName = SelectPrimitive.Label.displayName;\n\nconst SelectItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, ...props }, ref) => (\n \n \n \n \n \n \n\n {children}\n \n));\nSelectItem.displayName = SelectPrimitive.Item.displayName;\n\nconst SelectSeparator = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSelectSeparator.displayName = SelectPrimitive.Separator.displayName;\n\nexport {\n Select,\n SelectGroup,\n SelectValue,\n SelectTrigger,\n SelectContent,\n SelectLabel,\n SelectItem,\n SelectSeparator,\n SelectScrollUpButton,\n SelectScrollDownButton,\n};\n","import { ChevronLeftIcon, ChevronRightIcon, ArrowLeftIcon, ArrowRightIcon } from 'lucide-react';\nimport { Table } from '@tanstack/react-table';\n\nimport { Button } from '@/components/shadcn-ui/button';\nimport {\n Select,\n SelectContent,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\n\ninterface DataTablePaginationProps {\n table: Table;\n}\n\nfunction DataTablePagination({ table }: DataTablePaginationProps) {\n return (\n
    \n
    \n
    \n {table.getFilteredSelectedRowModel().rows.length} of{' '}\n {table.getFilteredRowModel().rows.length} row(s) selected\n
    \n
    \n

    Rows per page

    \n {\n table.setPageSize(Number(value));\n }}\n >\n \n \n \n \n {[10, 20, 30, 40, 50].map((pageSize) => (\n \n {pageSize}\n \n ))}\n \n \n
    \n
    \n Page {table.getState().pagination.pageIndex + 1} of {table.getPageCount()}\n
    \n
    \n table.setPageIndex(0)}\n disabled={!table.getCanPreviousPage()}\n >\n Go to first page\n \n \n table.previousPage()}\n disabled={!table.getCanPreviousPage()}\n >\n Go to previous page\n \n \n table.nextPage()}\n disabled={!table.getCanNextPage()}\n >\n Go to next page\n \n \n table.setPageIndex(table.getPageCount() - 1)}\n disabled={!table.getCanNextPage()}\n >\n Go to last page\n \n \n
    \n
    \n
    \n );\n}\n\nexport default DataTablePagination;\n","import React from 'react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Table = React.forwardRef<\n HTMLTableElement,\n React.HTMLAttributes & { stickyHeader?: boolean }\n>(({ className, stickyHeader, ...props }, ref) => (\n
    \n \n
    \n));\nTable.displayName = 'Table';\n\nconst TableHeader = React.forwardRef<\n HTMLTableSectionElement,\n React.HTMLAttributes & { stickyHeader?: boolean }\n>(({ className, stickyHeader, ...props }, ref) => (\n \n));\nTableHeader.displayName = 'TableHeader';\n\nconst TableBody = React.forwardRef<\n HTMLTableSectionElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableBody.displayName = 'TableBody';\n\nconst TableFooter = React.forwardRef<\n HTMLTableSectionElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n tr]:last:tw-border-b-0', className)}\n {...props}\n />\n));\nTableFooter.displayName = 'TableFooter';\n\nconst TableRow = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nTableRow.displayName = 'TableRow';\n\nconst TableHead = React.forwardRef<\n HTMLTableCellElement,\n React.ThHTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableHead.displayName = 'TableHead';\n\nconst TableCell = React.forwardRef<\n HTMLTableCellElement,\n React.TdHTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableCell.displayName = 'TableCell';\n\nconst TableCaption = React.forwardRef<\n HTMLTableCaptionElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableCaption.displayName = 'TableCaption';\n\nexport { Table, TableHeader, TableBody, TableFooter, TableHead, TableRow, TableCell, TableCaption };\n","import { useState } from 'react';\n\nimport {\n ColumnFiltersState,\n flexRender,\n getCoreRowModel,\n getFilteredRowModel,\n getPaginationRowModel,\n getSortedRowModel,\n SortingState,\n ColumnDef as TSColumnDef,\n Row as TSRow,\n RowSelectionState as TSRowSelectionState,\n SortDirection as TSSortDirection,\n Table as TSTable,\n useReactTable,\n VisibilityState,\n} from '@tanstack/react-table';\n\nimport DataTableViewOptions from '@/components/advanced/data-table/data-table-column-toggle.component';\nimport DataTablePagination from '@/components/advanced/data-table/data-table-pagination.component';\nimport { Button } from '@/components/shadcn-ui/button';\nimport {\n Table,\n TableBody,\n TableCell,\n TableHead,\n TableHeader,\n TableRow,\n} from '@/components/shadcn-ui/table';\n\nexport type ColumnDef = TSColumnDef;\nexport type RowContents = TSRow;\nexport type TableContents = TSTable;\nexport type SortDirection = TSSortDirection;\nexport type RowSelectionState = TSRowSelectionState;\n\ninterface DataTableProps {\n columns: ColumnDef[];\n data: TData[];\n enablePagination?: boolean;\n showPaginationControls?: boolean;\n showColumnVisibilityControls?: boolean;\n stickyHeader?: boolean;\n onRowClickHandler?: (row: RowContents, table: TableContents) => void;\n}\n\n/**\n * Feature-rich table component that infuses our basic shadcn-based Table component with features\n * from TanStack's React Table library\n */\nfunction DataTable({\n columns,\n data,\n enablePagination = false,\n showPaginationControls = false,\n showColumnVisibilityControls = false,\n stickyHeader = false,\n onRowClickHandler = () => {},\n}: DataTableProps) {\n const [sorting, setSorting] = useState([]);\n const [columnFilters, setColumnFilters] = useState([]);\n const [columnVisibility, setColumnVisibility] = useState({});\n const [rowSelection, setRowSelection] = useState({});\n\n const table = useReactTable({\n data,\n columns,\n getCoreRowModel: getCoreRowModel(),\n ...(enablePagination && { getPaginationRowModel: getPaginationRowModel() }),\n onSortingChange: setSorting,\n getSortedRowModel: getSortedRowModel(),\n onColumnFiltersChange: setColumnFilters,\n getFilteredRowModel: getFilteredRowModel(),\n onColumnVisibilityChange: setColumnVisibility,\n onRowSelectionChange: setRowSelection,\n state: {\n sorting,\n columnFilters,\n columnVisibility,\n rowSelection,\n },\n });\n\n return (\n
    \n {showColumnVisibilityControls && }\n \n \n {table.getHeaderGroups().map((headerGroup) => (\n \n {headerGroup.headers.map((header) => {\n return (\n \n {header.isPlaceholder\n ? undefined\n : flexRender(header.column.columnDef.header, header.getContext())}\n \n );\n })}\n \n ))}\n \n \n {table.getRowModel().rows?.length ? (\n table.getRowModel().rows.map((row) => (\n onRowClickHandler(row, table)}\n key={row.id}\n data-state={row.getIsSelected() && 'selected'}\n >\n {row.getVisibleCells().map((cell) => (\n \n {flexRender(cell.column.columnDef.cell, cell.getContext())}\n \n ))}\n \n ))\n ) : (\n \n \n No results.\n \n \n )}\n \n
    \n {enablePagination && (\n
    \n table.previousPage()}\n disabled={!table.getCanPreviousPage()}\n >\n Previous\n \n table.nextPage()}\n disabled={!table.getCanNextPage()}\n >\n Next\n \n
    \n )}\n {enablePagination && showPaginationControls && }\n
    \n );\n}\n\nexport default DataTable;\n","import {\n Table,\n TableBody,\n TableCell,\n TableHead,\n TableHeader,\n TableRow,\n} from '@/components/shadcn-ui/table';\nimport { Canon } from '@sillsdev/scripture';\nimport { deepEqual, LanguageStrings, ScriptureReference } from 'platform-bible-utils';\nimport { useMemo } from 'react';\nimport { InventoryItemOccurrence } from './inventory-utils';\n\n/** Props for the OccurrencesTable component */\ntype OccurrencesTableProps = {\n /** Data that contains scriptures references and snippets of scripture */\n occurrenceData: InventoryItemOccurrence[];\n /** Callback function that is executed when the scripture reference is changed */\n setScriptureReference: (scriptureReference: ScriptureReference) => void;\n /**\n * Object with all localized strings that the OccurrencesTable needs to work well across multiple\n * languages\n */\n localizedStrings: LanguageStrings;\n};\n\n/**\n * Table that shows occurrences of specified inventory item(s). The first column shows the related\n * scripture reference. The second column shows the snippet of scripture that contains the specified\n * inventory item\n */\nfunction OccurrencesTable({\n occurrenceData,\n setScriptureReference,\n localizedStrings,\n}: OccurrencesTableProps) {\n const referenceHeaderText =\n localizedStrings['%webView_inventory_occurrences_table_header_reference%'];\n const occurrenceHeaderText =\n localizedStrings['%webView_inventory_occurrences_table_header_occurrence%'];\n\n const occurrences: InventoryItemOccurrence[] = useMemo(() => {\n const uniqueOccurrences: InventoryItemOccurrence[] = [];\n\n occurrenceData.forEach((occurrence) => {\n if (!uniqueOccurrences.some((uniqueOccurrence) => deepEqual(uniqueOccurrence, occurrence))) {\n uniqueOccurrences.push(occurrence);\n }\n });\n\n return uniqueOccurrences;\n }, [occurrenceData]);\n\n return (\n \n \n \n {referenceHeaderText}\n {occurrenceHeaderText}\n \n \n \n {occurrences.length > 0 &&\n occurrences.map((occurrence) => (\n {\n setScriptureReference(occurrence.reference);\n }}\n >\n {`${Canon.bookNumberToEnglishName(occurrence.reference.bookNum)} ${occurrence.reference.chapterNum}:${occurrence.reference.verseNum}`}\n {occurrence.text}\n \n ))}\n \n
    \n );\n}\n\nexport default OccurrencesTable;\n","import React from 'react';\nimport * as CheckboxPrimitive from '@radix-ui/react-checkbox';\nimport { Check } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Checkbox = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n \n \n));\nCheckbox.displayName = CheckboxPrimitive.Root.displayName;\n\nexport default Checkbox;\n","import { Canon } from '@sillsdev/scripture';\nimport { ScriptureReference } from 'platform-bible-utils';\n\n/* #region Types */\n\n/**\n * Status of items that appear in inventories. 'approved' and 'unapproved' items are defined in the\n * project's `Settings.xml`. All other items are defined as 'unknown'\n */\nexport type Status = 'approved' | 'unapproved' | 'unknown';\n\n/** Occurrence of item in inventory. Primarily used by table that shows occurrences */\nexport type InventoryItemOccurrence = {\n /** Reference to scripture where the item appears */\n reference: ScriptureReference;\n /** Snippet of scripture that contains the occurrence */\n text: string;\n};\n\n/** Data structure that contains all information on an item that is shown in an inventory */\nexport type InventoryTableData = {\n /**\n * The item (e.g. a character in the characters inventory, a marker in the marker inventory) In\n * most cases the array will only have one element. In case of additional items (e.g. the\n * preceding marker in the markers check), the primary item should be stored in the first index.\n * To show additional items in the inventory, make sure to configure the `additionalItemsLabels`\n * prop for the Inventory component\n */\n items: string[];\n /** The number of times this item occurs in the selected scope */\n count: number;\n /** The status of this item (see documentation for `Status` type for more information) */\n status: Status;\n /** Occurrences of this item in the scripture text for the selected scope */\n occurrences: InventoryItemOccurrence[];\n};\n\n/* #endregion */\n\n/* #region Functions */\n\n/**\n * Splits USFM string into shorter line-like segments\n *\n * @param text A single (likely very large) USFM string\n * @returns An array containing the input text, split into shorter segments\n */\nexport const getLinesFromUSFM = (text: string) => {\n // Splits on (CR)LF, CR, \\v, \\c and \\id\n return text.split(/(?:\\r?\\n|\\r)|(?=(?:\\\\(?:v|c|id)))/g);\n};\n\n/**\n * Extracts chapter or verse number from USFM strings that start with a \\c or \\v marker\n *\n * @param text USFM string that is expected to start with \\c or \\v marker\n * @returns Chapter or verse number if one is found. Else returns 0.\n */\nexport const getNumberFromUSFM = (text: string): number | undefined => {\n // Captures all digits that follow \\v or \\c markers followed by whitespace located at the start of a string\n const regex = /^\\\\[vc]\\s+(\\d+)/;\n const match = text.match(regex);\n\n if (match) {\n return +match[1];\n }\n return undefined;\n};\n\n/**\n * Gets book ID from USFM string that starts with the \\id marker, and returns book number for it\n *\n * @param text USFM string that is expected to start with \\id marker\n * @returns Book number corresponding to the \\id marker in the input text. Returns 0 if no marker is\n * found or the marker is not valid\n */\nexport const getBookNumFromId = (text: string): number => {\n // Captures all digits that follow an \\id marker followed by whitespace located at the start of a string\n const match = text.match(/^\\\\id\\s+([A-Za-z]+)/);\n if (match) {\n return Canon.bookIdToNumber(match[1]);\n }\n return 0;\n};\n\n/**\n * Gets the status for an item, typically used in the Inventory component\n *\n * @param item The item for which the status is being requested\n * @param approvedItems Array of approved items, typically as defined in `Settings.xml`\n * @param unapprovedItems Array of unapproved items, typically as defined in `Settings.xml`\n * @returns The status for the specified item\n */\nexport const getStatusForItem = (\n item: string,\n approvedItems: string[],\n unapprovedItems: string[],\n): Status => {\n if (unapprovedItems.includes(item)) return 'unapproved';\n if (approvedItems.includes(item)) return 'approved';\n return 'unknown';\n};\n\n/* #endregion */\n","import React from 'react';\nimport * as TogglePrimitive from '@radix-ui/react-toggle';\nimport { cva, type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst toggleVariants = cva(\n 'pr-twp tw-inline-flex tw-items-center tw-justify-center tw-rounded-md tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-colors hover:tw-bg-muted hover:tw-text-muted-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50 data-[state=on]:tw-bg-accent data-[state=on]:tw-text-accent-foreground',\n {\n variants: {\n variant: {\n default: 'tw-bg-transparent',\n outline:\n 'tw-border tw-border-input tw-bg-transparent hover:tw-bg-accent hover:tw-text-accent-foreground',\n },\n size: {\n default: 'tw-h-10 tw-px-3',\n sm: 'tw-h-9 tw-px-2.5',\n lg: 'tw-h-11 tw-px-5',\n },\n },\n defaultVariants: {\n variant: 'default',\n size: 'default',\n },\n },\n);\n\nconst Toggle = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef & VariantProps\n>(({ className, variant, size, ...props }, ref) => (\n \n));\n\nToggle.displayName = TogglePrimitive.Root.displayName;\n\nexport { Toggle, toggleVariants };\n","import React from 'react';\nimport * as ToggleGroupPrimitive from '@radix-ui/react-toggle-group';\nimport { type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { toggleVariants } from '@/components/shadcn-ui/toggle';\n\nconst ToggleGroupContext = React.createContext>({\n size: 'default',\n variant: 'default',\n});\n\nconst ToggleGroup = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef &\n VariantProps\n>(({ className, variant, size, children, ...props }, ref) => (\n \n \n {children}\n \n \n));\n\nToggleGroup.displayName = ToggleGroupPrimitive.Root.displayName;\n\nconst ToggleGroupItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef &\n VariantProps\n>(({ className, children, variant, size, ...props }, ref) => {\n const context = React.useContext(ToggleGroupContext);\n\n return (\n \n {children}\n \n );\n});\n\nToggleGroupItem.displayName = ToggleGroupPrimitive.Item.displayName;\n\nexport { ToggleGroup, ToggleGroupItem };\n","import { ColumnDef, SortDirection } from '@/components/advanced/data-table/data-table.component';\nimport { Button } from '@/components/shadcn-ui/button';\nimport { ToggleGroup, ToggleGroupItem } from '@/components/shadcn-ui/toggle-group';\nimport {\n ArrowDownIcon,\n ArrowUpDownIcon,\n ArrowUpIcon,\n CircleCheckIcon,\n CircleHelpIcon,\n CircleXIcon,\n} from 'lucide-react';\nimport { ReactNode } from 'react';\nimport { InventoryTableData, Status } from './inventory-utils';\n\n/**\n * Gets an icon that indicates the current sorting direction based on the provided input\n *\n * @param sortDirection Sorting direction. Can be ascending ('asc'), descending ('desc') or false (\n * i.e. not sorted)\n * @returns The appropriate sorting icon for the provided sorting direction\n */\nconst getSortingIcon = (sortDirection: false | SortDirection): ReactNode => {\n if (sortDirection === 'asc') {\n return ;\n }\n if (sortDirection === 'desc') {\n return ;\n }\n return ;\n};\n\n/**\n * Function that creates the item column for inventories\n *\n * @param itemLabel Localized label for the item column (e.g. 'Character', 'Repeated Word', etc.)\n * @returns Column that shows the inventory items. Should be used with the DataTable component\n */\nexport const inventoryItemColumn = (itemLabel: string): ColumnDef => {\n return {\n accessorKey: 'item',\n accessorFn: (row: InventoryTableData) => row.items[0],\n header: ({ column }) => (\n \n ),\n };\n};\n\n/**\n * Function that creates the additional item columns for inventories\n *\n * @param additionalItemLabel Localized label for the additional item column (e.g. 'Preceding\n * Marker')\n * @param additionalItemIndex Index that locates the desired item in the items array of the\n * inventory\n * @returns Column that shows additional inventory items. Should be used with the DataTable\n * component\n */\nexport const inventoryAdditionalItemColumn = (\n additionalItemLabel: string,\n additionalItemIndex: number,\n): ColumnDef => {\n return {\n accessorKey: `item${additionalItemIndex}`,\n accessorFn: (row: InventoryTableData) => row.items[additionalItemIndex],\n header: ({ column }) => (\n \n ),\n };\n};\n\n/**\n * Function that creates the count column for inventories. Should be used with the DataTable\n * component.\n *\n * @param itemLabel Localized label for the count column\n * @returns Column that shows the number of occurrences of the related inventory items\n */\nexport const inventoryCountColumn = (countLabel: string): ColumnDef => {\n return {\n accessorKey: 'count',\n header: ({ column }) => (\n
    \n \n
    \n ),\n cell: ({ row }) =>
    {row.getValue('count')}
    ,\n };\n};\n\n/**\n * Function that updates project settings when status for item(s) changes\n *\n * @param changedItems Array of items for which the status is being updated\n * @param newStatus The status that the items are being given\n * @param approvedItems Array of currently approved items\n * @param onApprovedItemsChange Callback function that stores the updated list of approved items\n * @param unapprovedItems Array of currently unapproved items\n * @param onUnapprovedItemsChange Callback function that stores the updated list of unapproved items\n */\nconst statusChangeHandler = (\n changedItems: string[],\n newStatus: Status,\n approvedItems: string[],\n onApprovedItemsChange: (items: string[]) => void,\n unapprovedItems: string[],\n onUnapprovedItemsChange: (items: string[]) => void,\n) => {\n let newApprovedItems: string[] = [...approvedItems];\n changedItems.forEach((item) => {\n if (newStatus === 'approved') {\n if (!newApprovedItems.includes(item)) {\n newApprovedItems.push(item);\n }\n } else {\n newApprovedItems = newApprovedItems.filter((validItem) => validItem !== item);\n }\n });\n onApprovedItemsChange(newApprovedItems);\n\n let newUnapprovedItems: string[] = [...unapprovedItems];\n changedItems.forEach((item) => {\n if (newStatus === 'unapproved') {\n if (!newUnapprovedItems.includes(item)) {\n newUnapprovedItems.push(item);\n }\n } else {\n newUnapprovedItems = newUnapprovedItems.filter((unapprovedItem) => unapprovedItem !== item);\n }\n });\n onUnapprovedItemsChange(newUnapprovedItems);\n};\n\n/**\n * Function that creates the status column for inventories. Should be used with the DataTable\n * component.\n *\n * @param statusLabel Localized label for the status column\n * @param approvedItems Array of approved items, typically as defined in `Settings.xml`\n * @param onApprovedItemsChange Callback function that stores the updated list of approved items\n * @param unapprovedItems Array of unapproved items, typically as defined in `Settings.xml`\n * @param onUnapprovedItemsChange Callback function that stores the updated list of unapproved items\n * @returns Column that shows the status buttons for the related inventory item. The button for the\n * current status of the item is selected\n */\nexport const inventoryStatusColumn = (\n statusLabel: string,\n approvedItems: string[],\n onApprovedItemsChange: (items: string[]) => void,\n unapprovedItems: string[],\n onUnapprovedItemsChange: (items: string[]) => void,\n): ColumnDef => {\n return {\n accessorKey: 'status',\n header: ({ column }) => {\n return (\n
    \n \n
    \n );\n },\n cell: ({ row }) => {\n const status: Status = row.getValue('status');\n const item: string = row.getValue('item');\n return (\n \n \n statusChangeHandler(\n [item],\n 'approved',\n approvedItems,\n onApprovedItemsChange,\n unapprovedItems,\n onUnapprovedItemsChange,\n )\n }\n value=\"approved\"\n >\n \n \n \n statusChangeHandler(\n [item],\n 'unapproved',\n approvedItems,\n onApprovedItemsChange,\n unapprovedItems,\n onUnapprovedItemsChange,\n )\n }\n value=\"unapproved\"\n >\n \n \n \n statusChangeHandler(\n [item],\n 'unknown',\n approvedItems,\n onApprovedItemsChange,\n unapprovedItems,\n onUnapprovedItemsChange,\n )\n }\n value=\"unknown\"\n >\n \n \n \n );\n },\n };\n};\n","import DataTable, {\n ColumnDef,\n RowContents,\n RowSelectionState,\n TableContents,\n} from '@/components/advanced/data-table/data-table.component';\nimport OccurrencesTable from '@/components/advanced/inventory/occurrences-table.component';\nimport Checkbox from '@/components/shadcn-ui/checkbox';\nimport { Input } from '@/components/shadcn-ui/input';\nimport { Label } from '@/components/shadcn-ui/label';\nimport {\n Select,\n SelectContent,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\nimport {\n deepEqual,\n LocalizedStringValue,\n ScriptureReference,\n substring,\n} from 'platform-bible-utils';\nimport { useEffect, useMemo, useState } from 'react';\nimport {\n getBookNumFromId,\n getLinesFromUSFM,\n getNumberFromUSFM,\n getStatusForItem,\n InventoryItemOccurrence,\n InventoryTableData,\n Status,\n} from './inventory-utils';\nimport { inventoryAdditionalItemColumn } from './inventory-columns';\n\n/**\n * Object containing all keys used for localization in this component. If you're using this\n * component in an extension, you can pass it into the useLocalizedStrings hook to easily obtain the\n * localized strings and pass them into the localizedStrings prop of this component\n */\nexport const INVENTORY_STRING_KEYS = Object.freeze([\n '%webView_inventory_all%',\n '%webView_inventory_approved%',\n '%webView_inventory_unapproved%',\n '%webView_inventory_unknown%',\n '%webView_inventory_scope_currentBook%',\n '%webView_inventory_scope_chapter%',\n '%webView_inventory_scope_verse%',\n '%webView_inventory_filter_text%',\n '%webView_inventory_show_additional_items%',\n '%webView_inventory_occurrences_table_header_reference%',\n '%webView_inventory_occurrences_table_header_occurrence%',\n] as const);\n\nexport type InventoryLocalizedStrings = {\n [localizedInventoryKey in (typeof INVENTORY_STRING_KEYS)[number]]?: LocalizedStringValue;\n};\n\n/** Scope of scripture that the inventory can operate on */\nexport type Scope = 'book' | 'chapter' | 'verse';\n\n/** Status values that the status filter can select from */\ntype StatusFilter = Status | 'all';\n\n/** Text labels for the inventory columns and the control components of additional inventory items */\ntype AdditionalItemsLabels = {\n checkboxText?: string;\n tableHeaders?: string[];\n};\n\n/**\n * Filters data that is shown in the DataTable section of the Inventory\n *\n * @param itemData All inventory items and their related information\n * @param statusFilter Allows filtering by status (i.e. show all items, or only items that are\n * 'approved', 'unapproved' or 'unknown')\n * @param textFilter Allows filtering by text. All items that include the filter text will be\n * selected.\n * @returns Array of items and their related information that are matched by the specified filters\n */\nconst filterItemData = (\n itemData: InventoryTableData[],\n statusFilter: StatusFilter,\n textFilter: string,\n): InventoryTableData[] => {\n let filteredItemData: InventoryTableData[] = itemData;\n\n if (statusFilter !== 'all') {\n filteredItemData = filteredItemData.filter(\n (item) =>\n (statusFilter === 'approved' && item.status === 'approved') ||\n (statusFilter === 'unapproved' && item.status === 'unapproved') ||\n (statusFilter === 'unknown' && item.status === 'unknown'),\n );\n }\n\n if (textFilter !== '')\n filteredItemData = filteredItemData.filter((item) => item.items[0].includes(textFilter));\n\n return filteredItemData;\n};\n\n/**\n * Turns array of strings into array of inventory items, along with their count and status\n *\n * @param text The source scripture text that is searched for inventory items\n * @param scriptureRef The scripture reference that the application is currently set to\n * @param approvedItems Array of approved items, typically as defined in `Settings.xml`\n * @param unapprovedItems Array of unapproved items, typically as defined in `Settings.xml`\n * @param itemRegex Regular expression that describes what items this Inventory should extract from\n * the provided scripture text\n * @returns Array of inventory items, along with their count and status\n */\nconst createTableData = (\n text: string | undefined,\n scriptureRef: ScriptureReference,\n approvedItems: string[],\n unapprovedItems: string[],\n itemRegex: RegExp,\n): InventoryTableData[] => {\n if (!text) return [];\n\n const tableData: InventoryTableData[] = [];\n\n let currentBook: number | undefined = scriptureRef.bookNum;\n let currentChapter: number | undefined = scriptureRef.chapterNum;\n let currentVerse: number | undefined = scriptureRef.verseNum;\n\n const lines = getLinesFromUSFM(text);\n\n lines.forEach((line: string) => {\n if (line.startsWith('\\\\id')) {\n currentBook = getBookNumFromId(line);\n currentChapter = 0;\n currentVerse = 0;\n }\n if (line.startsWith('\\\\c')) {\n currentChapter = getNumberFromUSFM(line);\n currentVerse = 0;\n }\n if (line.startsWith('\\\\v')) {\n currentVerse = getNumberFromUSFM(line);\n if (currentChapter === 0) {\n currentChapter = scriptureRef.chapterNum;\n }\n }\n\n let match: RegExpExecArray | undefined = itemRegex.exec(line) ?? undefined;\n while (match) {\n const items: string[] = [];\n match.forEach((item) => items.push(item));\n const itemIndex = match.index;\n const existingItem = tableData.find((tableEntry) => deepEqual(tableEntry.items, items));\n const newReference: InventoryItemOccurrence = {\n reference: {\n bookNum: currentBook !== undefined ? currentBook : -1,\n chapterNum: currentChapter !== undefined ? currentChapter : -1,\n verseNum: currentVerse !== undefined ? currentVerse : -1,\n },\n text: substring(line, Math.max(0, itemIndex - 25), Math.min(itemIndex + 25, line.length)),\n };\n if (existingItem) {\n existingItem.count += 1;\n existingItem.occurrences.push(newReference);\n } else {\n const newItem: InventoryTableData = {\n items,\n count: 1,\n status: getStatusForItem(items[0], approvedItems, unapprovedItems),\n occurrences: [newReference],\n };\n tableData.push(newItem);\n }\n\n match = itemRegex.exec(line) ?? undefined;\n }\n });\n\n return tableData;\n};\n\n/**\n * Gets the localized value for the provided key\n *\n * @param strings Object containing localized string\n * @param key Key for a localized string\n * @returns The localized value for the provided key, if available. Returns the key if no localized\n * value is available\n */\nconst localizeString = (\n strings: InventoryLocalizedStrings,\n key: keyof InventoryLocalizedStrings,\n) => {\n return strings[key] ?? key;\n};\n\n/** Props for the Inventory component */\ntype InventoryProps = {\n /** The scripture reference that the application is currently set to */\n scriptureReference: ScriptureReference;\n /** Callback function that is executed when the scripture reference is changed */\n setScriptureReference: (scriptureReference: ScriptureReference) => void;\n /**\n * Object with all localized strings that the Inventory needs to work well across multiple\n * languages. When using this component with Platform.Bible, you can import\n * `INVENTORY_STRING_KEYS` from this library, pass it in to the Platform's localization hook, and\n * pass the localized keys that are returned by the hook into this prop.\n */\n localizedStrings: InventoryLocalizedStrings;\n /**\n * The logic that finds the desired items in the source text. This can either be a Regular\n * expression that captures one or multiple items (preferred), or a custom function that builds\n * and return an InventoryDataTable[] manually. Note: In case the logic captures more than one\n * item (i.e. InventoryTableData.items has a length greater than 1), you must provide text labels\n * for the related columns and control elements to show by setting the `additionalItemsLabels`\n * prop\n */\n extractItems:\n | RegExp\n | ((\n text: string | undefined,\n scriptureRef: ScriptureReference,\n approvedItems: string[],\n unapprovedItems: string[],\n ) => InventoryTableData[]);\n /**\n * Text labels for control elements and additional column headers in case your Inventory has more\n * than one item to show (e.g. The 'Preceding Marker' in the Markers Inventory)\n */\n additionalItemsLabels?: AdditionalItemsLabels;\n /** Array of approved items, typically as defined in `Settings.xml` */\n approvedItems: string[];\n /** Array of unapproved items, typically as defined in `Settings.xml` */\n unapprovedItems: string[];\n /** The source scripture text that is searched for in inventory items */\n text: string | undefined;\n /** Scope of scripture that the inventory will operate on */\n scope: Scope;\n /** Callback function that is executed when the scope is changed from the Inventory */\n onScopeChange: (scope: Scope) => void;\n /**\n * Column definitions for the Inventory data table. The most commonly used column definitions are\n * pre-configured for your convenience and can be imported (e.g. inventoryItemColumn,\n * inventoryAdditionalItemColumn inventoryCountColumn, and inventoryStatusColumn). If you need any\n * other columns you can add these yourself\n */\n columns: ColumnDef[];\n};\n\n/** Inventory component that is used to view and control the status of provided project settings */\nexport default function Inventory({\n scriptureReference,\n setScriptureReference,\n localizedStrings,\n extractItems,\n additionalItemsLabels,\n approvedItems,\n unapprovedItems,\n text,\n scope,\n onScopeChange,\n columns,\n}: InventoryProps) {\n const allItemsText = localizeString(localizedStrings, '%webView_inventory_all%');\n const approvedItemsText = localizeString(localizedStrings, '%webView_inventory_approved%');\n const unapprovedItemsText = localizeString(localizedStrings, '%webView_inventory_unapproved%');\n const unknownItemsText = localizeString(localizedStrings, '%webView_inventory_unknown%');\n const scopeBookText = localizeString(localizedStrings, '%webView_inventory_scope_currentBook%');\n const scopeChapterText = localizeString(localizedStrings, '%webView_inventory_scope_chapter%');\n const scopeVerseText = localizeString(localizedStrings, '%webView_inventory_scope_verse%');\n const filterText = localizeString(localizedStrings, '%webView_inventory_filter_text%');\n const showAdditionalItemsText = localizeString(\n localizedStrings,\n '%webView_inventory_show_additional_items%',\n );\n\n const [showAdditionalItems, setShowAdditionalItems] = useState(false);\n const [statusFilter, setStatusFilter] = useState('all');\n const [textFilter, setTextFilter] = useState('');\n const [selectedItem, setSelectedItem] = useState([]);\n\n const tableData: InventoryTableData[] = useMemo(() => {\n if (!text) return [];\n if (extractItems instanceof RegExp)\n return createTableData(\n text,\n scriptureReference,\n approvedItems,\n unapprovedItems,\n extractItems,\n );\n return extractItems(text, scriptureReference, approvedItems, unapprovedItems);\n }, [text, extractItems, scriptureReference, approvedItems, unapprovedItems]);\n\n const reducedTableData: InventoryTableData[] = useMemo(() => {\n if (showAdditionalItems) return tableData;\n\n const newTableData: InventoryTableData[] = [];\n\n tableData.forEach((tableEntry) => {\n const firstItem = tableEntry.items[0];\n\n const existingEntry = newTableData.find(\n (newTableEntry) => newTableEntry.items[0] === firstItem,\n );\n\n if (existingEntry) {\n existingEntry.count += tableEntry.count;\n existingEntry.occurrences = existingEntry.occurrences.concat(tableEntry.occurrences);\n } else {\n newTableData.push({\n items: [firstItem],\n count: tableEntry.count,\n occurrences: tableEntry.occurrences,\n status: tableEntry.status,\n });\n }\n });\n\n return newTableData;\n }, [showAdditionalItems, tableData]);\n\n const filteredTableData: InventoryTableData[] = useMemo(() => {\n return filterItemData(reducedTableData, statusFilter, textFilter);\n }, [reducedTableData, statusFilter, textFilter]);\n\n const allColumns: ColumnDef[] = useMemo(() => {\n if (!showAdditionalItems) return columns;\n\n const numberOfAdditionalItems = additionalItemsLabels?.tableHeaders?.length;\n if (!numberOfAdditionalItems) return columns;\n\n const additionalColumns: ColumnDef[] = [];\n\n for (let index = 0; index < numberOfAdditionalItems; index++) {\n additionalColumns.push(\n inventoryAdditionalItemColumn(\n additionalItemsLabels?.tableHeaders?.[index] || 'Additional Item',\n index + 1,\n ),\n );\n }\n\n return [...additionalColumns, ...columns];\n }, [additionalItemsLabels?.tableHeaders, columns, showAdditionalItems]);\n\n useEffect(() => {\n setSelectedItem([]);\n }, [filteredTableData]);\n\n const rowClickHandler = (\n row: RowContents,\n table: TableContents,\n ) => {\n table.setRowSelection(() => {\n const newSelection: RowSelectionState = {};\n newSelection[row.index] = true;\n return newSelection;\n });\n\n setSelectedItem(row.original.items);\n };\n\n const handleScopeChange = (value: string) => {\n if (value === 'book' || value === 'chapter' || value === 'verse') {\n onScopeChange(value);\n } else {\n throw new Error(`Invalid scope value: ${value}`);\n }\n };\n\n const handleStatusFilterChange = (value: string) => {\n if (value === 'all' || value === 'approved' || value === 'unapproved' || value === 'unknown') {\n setStatusFilter(value);\n } else {\n throw new Error(`Invalid status filter value: ${value}`);\n }\n };\n\n const occurrenceData: InventoryItemOccurrence[] = useMemo(() => {\n if (reducedTableData.length === 0 || selectedItem.length === 0) return [];\n const occurrence = reducedTableData.filter((tableEntry: InventoryTableData) => {\n return deepEqual(\n showAdditionalItems ? tableEntry.items : [tableEntry.items[0]],\n selectedItem,\n );\n });\n if (occurrence.length > 1) throw new Error('Selected item is not unique');\n return occurrence[0].occurrences;\n }, [selectedItem, showAdditionalItems, reducedTableData]);\n\n return (\n
    \n
    \n handleStatusFilterChange(value)}\n defaultValue={statusFilter}\n >\n \n \n \n \n {allItemsText}\n {approvedItemsText}\n {unapprovedItemsText}\n {unknownItemsText}\n \n \n \n {\n setTextFilter(event.target.value);\n }}\n />\n {additionalItemsLabels && (\n
    \n {\n setSelectedItem([]);\n setShowAdditionalItems(checked);\n }}\n />\n \n
    \n )}\n
    \n
    \n \n
    \n {occurrenceData.length > 0 && (\n
    \n \n
    \n )}\n
    \n );\n}\n","import { Input } from '@/components/shadcn-ui/input';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { useState } from 'react';\n\nexport type SearchBarProps = {\n className?: string;\n /**\n * Callback fired to handle the search query when button pressed\n *\n * @param searchQuery\n */\n onSearch: (searchQuery: string) => void;\n\n /** Optional string that appears in the search bar without a search string */\n placeholder?: string;\n\n /** Optional boolean to set the input base to full width */\n isFullWidth?: boolean;\n};\n\nexport default function SearchBar({\n className,\n onSearch,\n placeholder,\n isFullWidth,\n}: SearchBarProps) {\n const [searchQuery, setSearchQuery] = useState('');\n\n const handleInputChange = (searchString: string) => {\n setSearchQuery(searchString);\n onSearch(searchString);\n };\n\n return (\n handleInputChange(e.target.value)}\n />\n );\n}\n","// adapted from: https://github.com/shadcn-ui/ui/discussions/752\n\n'use client';\n\nimport { TabsContentProps, TabsListProps, TabsTriggerProps } from '@/components/shadcn-ui/tabs';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport * as TabsPrimitive from '@radix-ui/react-tabs';\nimport React from 'react';\n\nexport type VerticalTabsProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport type LeftTabsTriggerProps = TabsTriggerProps & {\n value: string;\n ref?: React.Ref;\n};\n\nexport const VerticalTabs = React.forwardRef<\n React.ElementRef,\n VerticalTabsProps\n>(({ className, ...props }, ref) => (\n \n));\n\nVerticalTabs.displayName = TabsPrimitive.List.displayName;\n\nexport const VerticalTabsList = React.forwardRef<\n React.ElementRef,\n TabsListProps\n>(({ className, ...props }, ref) => (\n \n));\nVerticalTabsList.displayName = TabsPrimitive.List.displayName;\n\nexport const VerticalTabsTrigger = React.forwardRef<\n React.ElementRef,\n LeftTabsTriggerProps\n>(({ className, ...props }, ref) => (\n \n));\n\nexport const VerticalTabsContent = React.forwardRef<\n React.ElementRef,\n TabsContentProps\n>(({ className, ...props }, ref) => (\n \n));\nVerticalTabsContent.displayName = TabsPrimitive.Content.displayName;\n","import SearchBar from '@/components/basics/search-bar.component';\nimport {\n VerticalTabs,\n VerticalTabsContent,\n VerticalTabsList,\n VerticalTabsTrigger,\n} from '@/components/basics/tabs-vertical';\nimport { ReactNode } from 'react';\n\nexport type TabKeyValueContent = {\n key: string;\n value: string;\n content: ReactNode;\n};\n\nexport type TabNavigationContentSearchProps = {\n /** List of values and keys for each tab this component should provide */\n tabList: TabKeyValueContent[];\n\n /** Handler to run when the value of the search bar changes */\n onSearch: (searchQuery: string) => void;\n\n /** Optional placeholder for the search bar */\n searchPlaceholder?: string;\n\n /** Optional title to include in the header */\n headerTitle?: string;\n\n /** Optional flag to make the search bar appear full width */\n isSearchBarFullWidth?: boolean;\n\n /** Text direction ltr or rtl */\n direction?: 'ltr' | 'rtl';\n};\n\nexport default function TabNavigationContentSearch({\n tabList,\n onSearch,\n searchPlaceholder,\n headerTitle,\n isSearchBarFullWidth = false,\n direction = 'ltr',\n}: TabNavigationContentSearchProps) {\n return (\n
    \n
    \n {headerTitle ?

    {headerTitle}

    : ''}\n \n
    \n \n \n {tabList.map((tab) => (\n \n {tab.value}\n \n ))}\n \n {tabList.map((tab) => (\n \n {tab.content}\n \n ))}\n \n
    \n );\n}\n","import React from 'react';\nimport * as SeparatorPrimitive from '@radix-ui/react-separator';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Separator = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, orientation = 'horizontal', decorative = true, ...props }, ref) => (\n \n));\nSeparator.displayName = SeparatorPrimitive.Root.displayName;\n\nexport { Separator };\n","'use client';\n\nimport * as React from 'react';\nimport * as SheetPrimitive from '@radix-ui/react-dialog';\nimport { cva, type VariantProps } from 'class-variance-authority';\nimport { X } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Sheet = SheetPrimitive.Root;\n\nconst SheetTrigger = SheetPrimitive.Trigger;\n\nconst SheetClose = SheetPrimitive.Close;\n\nconst SheetPortal = SheetPrimitive.Portal;\n\nconst SheetOverlay = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSheetOverlay.displayName = SheetPrimitive.Overlay.displayName;\n\nconst sheetVariants = cva(\n 'pr-twp tw-fixed tw-z-50 tw-gap-4 tw-bg-background tw-p-6 tw-shadow-lg tw-transition tw-ease-in-out data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-duration-300 data-[state=open]:tw-duration-500',\n {\n variants: {\n side: {\n top: 'tw-inset-x-0 tw-top-0 tw-border-b data-[state=closed]:tw-slide-out-to-top data-[state=open]:tw-slide-in-from-top',\n bottom:\n 'tw-inset-x-0 tw-bottom-0 tw-border-t data-[state=closed]:tw-slide-out-to-bottom data-[state=open]:tw-slide-in-from-bottom',\n left: 'tw-inset-y-0 tw-left-0 tw-h-full tw-w-3/4 tw-border-r data-[state=closed]:tw-slide-out-to-left data-[state=open]:tw-slide-in-from-left sm:tw-max-w-sm',\n right:\n 'tw-inset-y-0 tw-right-0 tw-h-full tw-w-3/4 tw- tw-border-l data-[state=closed]:tw-slide-out-to-right data-[state=open]:tw-slide-in-from-right sm:tw-max-w-sm',\n },\n },\n defaultVariants: {\n side: 'right',\n },\n },\n);\n\ninterface SheetContentProps\n extends React.ComponentPropsWithoutRef,\n VariantProps {}\n\nconst SheetContent = React.forwardRef<\n React.ElementRef,\n SheetContentProps\n>(({ side = 'right', className, children, ...props }, ref) => (\n \n \n \n {children}\n \n \n Close\n \n \n \n));\nSheetContent.displayName = SheetPrimitive.Content.displayName;\n\nfunction SheetHeader({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nSheetHeader.displayName = 'SheetHeader';\n\nfunction SheetFooter({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nSheetFooter.displayName = 'SheetFooter';\n\nconst SheetTitle = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSheetTitle.displayName = SheetPrimitive.Title.displayName;\n\nconst SheetDescription = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSheetDescription.displayName = SheetPrimitive.Description.displayName;\n\nexport {\n Sheet,\n SheetPortal,\n SheetOverlay,\n SheetTrigger,\n SheetClose,\n SheetContent,\n SheetHeader,\n SheetFooter,\n SheetTitle,\n SheetDescription,\n};\n","import React from 'react';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nfunction Skeleton({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\n\nexport { Skeleton };\n","import React from 'react';\nimport * as TooltipPrimitive from '@radix-ui/react-tooltip';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst TooltipProvider = TooltipPrimitive.Provider;\n\nconst Tooltip = TooltipPrimitive.Root;\n\nconst TooltipTrigger = TooltipPrimitive.Trigger;\n\nconst TooltipContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, sideOffset = 4, ...props }, ref) => (\n \n));\nTooltipContent.displayName = TooltipPrimitive.Content.displayName;\n\nexport { Tooltip, TooltipTrigger, TooltipContent, TooltipProvider };\n","import * as React from 'react';\n\nconst MOBILE_BREAKPOINT = 768;\n\nexport default function useIsMobile() {\n const [isMobile, setIsMobile] = React.useState(undefined);\n\n React.useEffect(() => {\n const mql = window.matchMedia(`(max-width: ${MOBILE_BREAKPOINT - 1}px)`);\n const onChange = () => {\n setIsMobile(window.innerWidth < MOBILE_BREAKPOINT);\n };\n mql.addEventListener('change', onChange);\n setIsMobile(window.innerWidth < MOBILE_BREAKPOINT);\n return () => mql.removeEventListener('change', onChange);\n }, []);\n\n return !!isMobile;\n}\n","import React from 'react';\nimport { Slot } from '@radix-ui/react-slot';\nimport { VariantProps, cva } from 'class-variance-authority';\nimport { PanelLeft } from 'lucide-react';\n\nimport { Button } from '@/components/shadcn-ui/button';\nimport { Input } from '@/components/shadcn-ui/input';\nimport { Separator } from '@/components/shadcn-ui/separator';\nimport { Sheet, SheetContent } from '@/components/shadcn-ui/sheet';\nimport { Skeleton } from '@/components/shadcn-ui/skeleton';\nimport {\n Tooltip,\n TooltipContent,\n TooltipProvider,\n TooltipTrigger,\n} from '@/components/shadcn-ui/tooltip';\nimport useIsMobile from '@/components/hooks/use-mobile';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst SIDEBAR_COOKIE_NAME = 'sidebar:state';\nconst SIDEBAR_COOKIE_MAX_AGE = 60 * 60 * 24 * 7;\nconst SIDEBAR_WIDTH = '16rem';\nconst SIDEBAR_WIDTH_MOBILE = '18rem';\nconst SIDEBAR_WIDTH_ICON = '3rem';\nconst SIDEBAR_KEYBOARD_SHORTCUT = 'b';\n\ntype SidebarContextProps = {\n state: 'expanded' | 'collapsed';\n open: boolean;\n setOpen: (open: boolean) => void;\n openMobile: boolean;\n setOpenMobile: (open: boolean) => void;\n isMobile: boolean;\n toggleSidebar: () => void;\n};\n\nconst SidebarContext = React.createContext(undefined);\n\nfunction useSidebar() {\n const context = React.useContext(SidebarContext);\n if (!context) {\n throw new Error('useSidebar must be used within a SidebarProvider.');\n }\n\n return context;\n}\n\nconst SidebarProvider = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & {\n defaultOpen?: boolean;\n open?: boolean;\n onOpenChange?: (open: boolean) => void;\n }\n>(\n (\n {\n defaultOpen = true,\n open: openProp,\n onOpenChange: setOpenProp,\n className,\n style,\n children,\n ...props\n },\n ref,\n ) => {\n const isMobile = useIsMobile();\n const [openMobile, setOpenMobile] = React.useState(false);\n\n // This is the internal state of the sidebar.\n // We use openProp and setOpenProp for control from outside the component.\n const [_open, _setOpen] = React.useState(defaultOpen);\n const isOpen = openProp ?? _open;\n const setOpen = React.useCallback(\n (value: boolean | ((value: boolean) => boolean)) => {\n const openState = typeof value === 'function' ? value(isOpen) : value;\n if (setOpenProp) {\n setOpenProp(openState);\n } else {\n _setOpen(openState);\n }\n\n // This sets the cookie to keep the sidebar state.\n document.cookie = `${SIDEBAR_COOKIE_NAME}=${openState}; path=/; max-age=${SIDEBAR_COOKIE_MAX_AGE}`;\n },\n [setOpenProp, isOpen],\n );\n\n // Helper to toggle the sidebar.\n const toggleSidebar = React.useCallback(() => {\n return isMobile ? setOpenMobile((open) => !open) : setOpen((open) => !open);\n }, [isMobile, setOpen, setOpenMobile]);\n\n // Adds a keyboard shortcut to toggle the sidebar.\n React.useEffect(() => {\n const handleKeyDown = (event: KeyboardEvent) => {\n if (event.key === SIDEBAR_KEYBOARD_SHORTCUT && (event.metaKey || event.ctrlKey)) {\n event.preventDefault();\n toggleSidebar();\n }\n };\n\n window.addEventListener('keydown', handleKeyDown);\n return () => window.removeEventListener('keydown', handleKeyDown);\n }, [toggleSidebar]);\n\n // We add a state so that we can do data-state=\"expanded\" or \"collapsed\".\n // This makes it easier to style the sidebar with Tailwind classes.\n const state = isOpen ? 'expanded' : 'collapsed';\n\n const contextValue = React.useMemo(\n () => ({\n state,\n open: isOpen,\n setOpen,\n isMobile,\n openMobile,\n setOpenMobile,\n toggleSidebar,\n }),\n [state, isOpen, setOpen, isMobile, openMobile, setOpenMobile, toggleSidebar],\n );\n\n return (\n \n \n \n {children}\n
    \n \n \n );\n },\n);\nSidebarProvider.displayName = 'SidebarProvider';\n\nconst Sidebar = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & {\n side?: 'left' | 'right';\n variant?: 'sidebar' | 'floating' | 'inset';\n collapsible?: 'offcanvas' | 'icon' | 'none';\n }\n>(\n (\n {\n side = 'left',\n variant = 'sidebar',\n collapsible = 'offcanvas',\n className,\n children,\n ...props\n },\n ref,\n ) => {\n const { isMobile, state, openMobile, setOpenMobile } = useSidebar();\n\n if (collapsible === 'none') {\n return (\n \n {children}\n
    \n );\n }\n\n if (isMobile) {\n return (\n \n button]:tw-hidden\"\n style={\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n {\n '--sidebar-width': SIDEBAR_WIDTH_MOBILE,\n } as React.CSSProperties\n }\n side={side}\n >\n
    {children}
    \n \n
    \n );\n }\n\n return (\n \n {/* This is what handles the sidebar gap on desktop */}\n \n \n \n {children}\n
    \n
    \n
    \n );\n },\n);\nSidebar.displayName = 'Sidebar';\n\nconst SidebarTrigger = React.forwardRef<\n React.ElementRef,\n React.ComponentProps\n>(({ className, onClick, ...props }, ref) => {\n const { toggleSidebar } = useSidebar();\n\n return (\n {\n onClick?.(event);\n toggleSidebar();\n }}\n {...props}\n >\n \n Toggle Sidebar\n \n );\n});\nSidebarTrigger.displayName = 'SidebarTrigger';\n\nconst SidebarRail = React.forwardRef>(\n ({ className, ...props }, ref) => {\n const { toggleSidebar } = useSidebar();\n\n return (\n \n );\n },\n);\nSidebarRail.displayName = 'SidebarRail';\n\nconst SidebarInset = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarInset.displayName = 'SidebarInset';\n\nconst SidebarInput = React.forwardRef<\n React.ElementRef,\n React.ComponentProps\n>(({ className, ...props }, ref) => {\n return (\n \n );\n});\nSidebarInput.displayName = 'SidebarInput';\n\nconst SidebarHeader = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarHeader.displayName = 'SidebarHeader';\n\nconst SidebarFooter = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarFooter.displayName = 'SidebarFooter';\n\nconst SidebarSeparator = React.forwardRef<\n React.ElementRef,\n React.ComponentProps\n>(({ className, ...props }, ref) => {\n return (\n \n );\n});\nSidebarSeparator.displayName = 'SidebarSeparator';\n\nconst SidebarContent = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarContent.displayName = 'SidebarContent';\n\nconst SidebarGroup = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarGroup.displayName = 'SidebarGroup';\n\nconst SidebarGroupLabel = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & { asChild?: boolean }\n>(({ className, asChild = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'div';\n\n return (\n svg]:tw-size-4 [&>svg]:tw-shrink-0',\n 'group-data-[collapsible=icon]:tw--mt-8 group-data-[collapsible=icon]:tw-opacity-0',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarGroupLabel.displayName = 'SidebarGroupLabel';\n\nconst SidebarGroupAction = React.forwardRef<\n HTMLButtonElement,\n React.ComponentProps<'button'> & { asChild?: boolean }\n>(({ className, asChild = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'button';\n\n return (\n svg]:tw-size-4 [&>svg]:tw-shrink-0',\n // Increases the hit area of the button on mobile.\n 'after:tw-absolute after:tw--inset-2 after:md:tw-hidden',\n 'group-data-[collapsible=icon]:tw-hidden',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarGroupAction.displayName = 'SidebarGroupAction';\n\nconst SidebarGroupContent = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarGroupContent.displayName = 'SidebarGroupContent';\n\nconst SidebarMenu = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenu.displayName = 'SidebarMenu';\n\nconst SidebarMenuItem = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenuItem.displayName = 'SidebarMenuItem';\n\nconst sidebarMenuButtonVariants = cva(\n // Removed data-[active=true]:tw-bg-sidebar-accent\n 'tw-peer/menu-button tw-flex tw-w-full tw-items-center tw-gap-2 tw-overflow-hidden tw-rounded-md tw-p-2 tw-text-left tw-text-sm tw-outline-none tw-ring-sidebar-ring tw-transition-[width,height,padding] hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground focus-visible:tw-ring-2 active:tw-bg-sidebar-accent active:tw-text-sidebar-accent-foreground disabled:tw-pointer-events-none disabled:tw-opacity-50 tw-group-has-[[data-sidebar=menu-action]]/menu-item:pr-8 aria-disabled:tw-pointer-events-none aria-disabled:tw-opacity-50 data-[active=true]:tw-font-medium data-[active=true]:tw-text-sidebar-accent-foreground data-[state=open]:hover:tw-bg-sidebar-accent data-[state=open]:hover:tw-text-sidebar-accent-foreground group-data-[collapsible=icon]:tw-!size-8 group-data-[collapsible=icon]:tw-!p-2 [&>span:last-child]:tw-truncate [&>svg]:tw-size-4 [&>svg]:tw-shrink-0',\n {\n variants: {\n variant: {\n default: 'hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground',\n outline:\n 'tw-bg-background tw-shadow-[0_0_0_1px_hsl(var(--sidebar-border))] hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground hover:tw-shadow-[0_0_0_1px_hsl(var(--sidebar-accent))]',\n },\n size: {\n default: 'tw-h-8 tw-text-sm',\n sm: 'tw-h-7 tw-text-xs',\n lg: 'tw-h-12 tw-text-sm group-data-[collapsible=icon]:tw-!p-0',\n },\n },\n defaultVariants: {\n variant: 'default',\n size: 'default',\n },\n },\n);\n\nconst SidebarMenuButton = React.forwardRef<\n HTMLButtonElement,\n React.ComponentProps<'button'> & {\n asChild?: boolean;\n isActive?: boolean;\n tooltip?: string | React.ComponentProps;\n } & VariantProps\n>(\n (\n {\n asChild = false,\n isActive = false,\n variant = 'default',\n size = 'default',\n tooltip,\n className,\n ...props\n },\n ref,\n ) => {\n const Comp = asChild ? Slot : 'button';\n const { isMobile, state } = useSidebar();\n\n const button = (\n \n );\n\n if (!tooltip) {\n return button;\n }\n\n if (typeof tooltip === 'string') {\n // eslint-disable-next-line no-param-reassign\n tooltip = {\n children: tooltip,\n };\n }\n\n return (\n \n {button}\n \n );\n },\n);\nSidebarMenuButton.displayName = 'SidebarMenuButton';\n\nconst SidebarMenuAction = React.forwardRef<\n HTMLButtonElement,\n React.ComponentProps<'button'> & {\n asChild?: boolean;\n showOnHover?: boolean;\n }\n>(({ className, asChild = false, showOnHover = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'button';\n\n return (\n svg]:tw-size-4 [&>svg]:tw-shrink-0',\n // Increases the hit area of the button on mobile.\n 'after:tw-absolute after:tw--inset-2 after:md:tw-hidden',\n 'tw-peer-data-[size=sm]/menu-button:top-1',\n 'tw-peer-data-[size=default]/menu-button:top-1.5',\n 'tw-peer-data-[size=lg]/menu-button:top-2.5',\n 'group-data-[collapsible=icon]:tw-hidden',\n showOnHover &&\n 'tw-group-focus-within/menu-item:opacity-100 tw-group-hover/menu-item:opacity-100 tw-peer-data-[active=true]/menu-button:text-sidebar-accent-foreground data-[state=open]:tw-opacity-100 md:tw-opacity-0',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarMenuAction.displayName = 'SidebarMenuAction';\n\nconst SidebarMenuBadge = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenuBadge.displayName = 'SidebarMenuBadge';\n\nconst SidebarMenuSkeleton = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & {\n showIcon?: boolean;\n }\n>(({ className, showIcon = false, ...props }, ref) => {\n // Random width between 50 to 90%.\n const width = React.useMemo(() => {\n return `${Math.floor(Math.random() * 40) + 50}%`;\n }, []);\n\n return (\n \n {showIcon && (\n \n )}\n \n
    \n );\n});\nSidebarMenuSkeleton.displayName = 'SidebarMenuSkeleton';\n\nconst SidebarMenuSub = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenuSub.displayName = 'SidebarMenuSub';\n\nconst SidebarMenuSubItem = React.forwardRef>(\n ({ ...props }, ref) =>
  • ,\n);\nSidebarMenuSubItem.displayName = 'SidebarMenuSubItem';\n\nconst SidebarMenuSubButton = React.forwardRef<\n HTMLAnchorElement,\n React.ComponentProps<'a'> & {\n asChild?: boolean;\n size?: 'sm' | 'md';\n isActive?: boolean;\n }\n>(({ asChild = false, size = 'md', isActive, className, ...props }, ref) => {\n const Comp = asChild ? Slot : 'a';\n\n return (\n span:last-child]:tw-truncate [&>svg]:tw-size-4 [&>svg]:tw-shrink-0 [&>svg]:tw-text-sidebar-accent-foreground',\n 'data-[active=true]:tw-bg-sidebar-accent data-[active=true]:tw-text-sidebar-accent-foreground',\n size === 'sm' && 'tw-text-xs',\n size === 'md' && 'tw-text-sm',\n 'group-data-[collapsible=icon]:tw-hidden',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarMenuSubButton.displayName = 'SidebarMenuSubButton';\n\nexport {\n Sidebar,\n SidebarContent,\n SidebarFooter,\n SidebarGroup,\n SidebarGroupAction,\n SidebarGroupContent,\n SidebarGroupLabel,\n SidebarHeader,\n SidebarInput,\n SidebarInset,\n SidebarMenu,\n SidebarMenuAction,\n SidebarMenuBadge,\n SidebarMenuButton,\n SidebarMenuItem,\n SidebarMenuSkeleton,\n SidebarMenuSub,\n SidebarMenuSubButton,\n SidebarMenuSubItem,\n SidebarProvider,\n SidebarRail,\n SidebarSeparator,\n SidebarTrigger,\n useSidebar,\n};\n","import ComboBox, { ComboBoxOption } from '@/components/basics/combo-box.component';\nimport {\n Sidebar,\n SidebarContent,\n SidebarGroup,\n SidebarGroupLabel,\n SidebarGroupContent,\n SidebarMenu,\n SidebarMenuItem,\n SidebarMenuButton,\n} from '@/components/shadcn-ui/sidebar';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { useCallback } from 'react';\n\nexport type SelectedSettingsSidebarItem = {\n label: string;\n projectId?: string;\n};\n\nexport type ProjectOptions = { projectId: string; projectName: string };\n\nexport type SettingsSidebarProps = {\n /** Optional id for testing */\n id?: string;\n\n /** Extension labels from contribution */\n extensionLabels: string[];\n\n /** Project names and ids */\n projectOptions: ProjectOptions[];\n\n /** Handler for selecting a sidebar item */\n handleSelectSidebarItem: (key: string, projectId?: string) => void;\n\n /** The current selected value in the sidebar */\n selectedSidebarItem: SelectedSettingsSidebarItem;\n\n /** Label for the group of extensions setting groups */\n extensionsSidebarGroupLabel: string;\n\n /** Label for the group of projects settings */\n projectsSidebarGroupLabel: string;\n};\n\nexport default function SettingsSidebar({\n id,\n extensionLabels,\n projectOptions,\n handleSelectSidebarItem,\n selectedSidebarItem,\n extensionsSidebarGroupLabel,\n projectsSidebarGroupLabel,\n}: SettingsSidebarProps) {\n const handleSelectItem = useCallback(\n (item: string, projectId?: string) => {\n handleSelectSidebarItem(item, projectId);\n },\n [handleSelectSidebarItem],\n );\n\n const getProjectNameFromProjectId = useCallback(\n (projectId: string) => {\n const project = projectOptions.find((option) => option.projectId === projectId);\n return project ? project.projectName : projectId;\n },\n [projectOptions],\n );\n\n const getIsActive: (label: string) => boolean = useCallback(\n (label: string) => !selectedSidebarItem.projectId && label === selectedSidebarItem.label,\n [selectedSidebarItem],\n );\n\n return (\n \n \n \n \n {extensionsSidebarGroupLabel}\n \n \n \n {extensionLabels.map((label) => (\n \n handleSelectItem(label, undefined)}\n isActive={getIsActive(label)}\n >\n {label}\n \n \n ))}\n \n \n \n \n \n {projectsSidebarGroupLabel}\n \n \n option.projectId)}\n getOptionLabel={(projectId: ComboBoxOption) => {\n // This function expects a ComboBoxOption, but we know it is a string\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n return getProjectNameFromProjectId(projectId as string);\n }}\n buttonPlaceholder=\"Type or select project\"\n onChange={(projectId: string) => {\n const selectedProjectName = getProjectNameFromProjectId(projectId);\n handleSelectItem(selectedProjectName, projectId);\n }}\n value={selectedSidebarItem?.projectId ?? undefined}\n />\n \n \n \n \n );\n}\n","import { SidebarInset, SidebarProvider } from '@/components/shadcn-ui/sidebar';\nimport { PropsWithChildren } from 'react';\nimport SearchBar from '@/components/basics/search-bar.component';\nimport SettingsSidebar, { SettingsSidebarProps } from './settings-sidebar.component';\n\nexport type SettingsSidebarContentSearchProps = SettingsSidebarProps &\n PropsWithChildren & {\n /** Optional id for testing */\n id?: string;\n\n /** Text direction ltr or rtl */\n direction?: 'ltr' | 'rtl';\n\n /** Handler to run when the value of the search bar changes */\n onSearch: (searchQuery: string) => void;\n };\n\nexport default function SettingsSidebarContentSearch({\n id,\n direction = 'ltr',\n extensionLabels,\n projectOptions,\n children,\n handleSelectSidebarItem,\n selectedSidebarItem,\n onSearch,\n extensionsSidebarGroupLabel,\n projectsSidebarGroupLabel,\n}: SettingsSidebarContentSearchProps) {\n return (\n
    \n
    \n \n
    \n \n \n {children}\n \n
    \n );\n}\n","import { Button } from '@/components/shadcn-ui/button';\nimport {\n Select,\n SelectContent,\n SelectGroup,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\nimport {\n Table,\n TableBody,\n TableCell,\n TableHead,\n TableHeader,\n TableRow,\n} from '@/components/shadcn-ui/table';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Canon } from '@sillsdev/scripture';\nimport {\n Cell,\n ColumnDef,\n flexRender,\n getCoreRowModel,\n getExpandedRowModel,\n getGroupedRowModel,\n getSortedRowModel,\n GroupingState,\n Row,\n RowSelectionState,\n SortingState,\n useReactTable,\n} from '@tanstack/react-table';\nimport '@/components/advanced/scripture-results-viewer/scripture-results-viewer.component.css';\nimport {\n compareScrRefs,\n formatScrRef,\n ScriptureSelection,\n scrRefToBBBCCCVVV,\n} from 'platform-bible-utils';\nimport { MouseEvent, useEffect, useMemo, useState } from 'react';\nimport { ChevronDown, ChevronLeft, ChevronRight } from 'lucide-react';\n\n/**\n * Information (e.g., a checking error or some other type of \"transient\" annotation) about something\n * noteworthy at a specific place in an instance of the Scriptures.\n */\nexport type ScriptureItemDetail = ScriptureSelection & {\n /**\n * Text of the error, note, etc. In the future, we might want to support something more than just\n * text so that a JSX element could be provided with a link or some other controls related to the\n * issue being reported.\n */\n detail: string;\n};\n\n/**\n * A uniquely identifiable source of results that can be displayed in the ScriptureResultsViewer.\n * Generally, the source will be a particular Scripture check, but there may be other types of\n * sources.\n */\nexport type ResultsSource = {\n /**\n * Uniquely identifies the source.\n *\n * @type {string}\n */\n id: string;\n\n /**\n * Name (potentially localized) of the source, suitable for display in the UI.\n *\n * @type {string}\n */\n displayName: string;\n};\n\nexport type ScriptureSrcItemDetail = ScriptureItemDetail & {\n /** Source/type of detail. Can be used for grouping. */\n source: ResultsSource;\n};\n\n/**\n * Represents a set of results keyed by Scripture reference. Generally, the source will be a\n * particular Scripture check, but this type also allows for other types of uniquely identifiable\n * sources.\n */\nexport type ResultsSet = {\n /**\n * The backing source associated with this set of results.\n *\n * @type {ResultsSource}\n */\n source: ResultsSource;\n\n /**\n * Array of Scripture item details (messages keyed by Scripture reference).\n *\n * @type {ScriptureItemDetail[]}\n */\n data: ScriptureItemDetail[];\n};\n\nconst scrBookColId = 'scrBook';\nconst scrRefColId = 'scrRef';\nconst typeColId = 'source';\nconst detailsColId = 'details';\n\nconst defaultScrRefColumnName = 'Scripture Reference';\nconst defaultScrBookGroupName = 'Scripture Book';\nconst defaultTypeColumnName = 'Type';\nconst defaultDetailsColumnName = 'Details';\n\nexport type ScriptureResultsViewerColumnInfo = {\n /** Optional header to display for the Reference column. Default value: 'Scripture Reference'. */\n scriptureReferenceColumnName?: string;\n\n /** Optional text to display to refer to the Scripture book group. Default value: 'Scripture Book'. */\n scriptureBookGroupName?: string;\n\n /** Optional header to display for the Type column. Default value: 'Type'. */\n typeColumnName?: string;\n\n /** Optional header to display for the Details column. Default value: 'Details' */\n detailsColumnName?: string;\n};\n\nexport type ScriptureResultsViewerProps = ScriptureResultsViewerColumnInfo & {\n /** Groups of ScriptureItemDetail objects from particular sources (e.g., Scripture checks) */\n sources: ResultsSet[];\n\n /** Flag indicating whether to display column headers. Default is false. */\n showColumnHeaders?: boolean;\n\n /** Flag indicating whether to display source column. Default is false. */\n showSourceColumn?: boolean;\n\n /** Callback function to notify when a row is selected */\n onRowSelected?: (selectedRow: ScriptureSrcItemDetail | undefined) => void;\n\n /** Text direction ltr or rtl */\n direction?: 'ltr' | 'rtl';\n};\n\nfunction getColumns(\n colInfo?: ScriptureResultsViewerColumnInfo,\n showSourceColumn?: boolean,\n): ColumnDef[] {\n const showSrcCol = showSourceColumn ?? false;\n return [\n {\n accessorFn: (row) =>\n `${Canon.bookNumberToId(row.start.bookNum)} ${row.start.chapterNum}:${row.start.verseNum}`,\n id: scrBookColId,\n header: colInfo?.scriptureReferenceColumnName ?? defaultScrRefColumnName,\n cell: (info) => {\n const row = info.row.original;\n if (info.row.getIsGrouped()) {\n return Canon.bookNumberToEnglishName(row.start.bookNum);\n }\n return info.row.groupingColumnId === scrBookColId ? formatScrRef(row.start) : undefined;\n },\n getGroupingValue: (row) => row.start.bookNum,\n sortingFn: (a, b) => {\n return compareScrRefs(a.original.start, b.original.start);\n },\n enableGrouping: true,\n },\n {\n accessorFn: (row) => formatScrRef(row.start),\n id: scrRefColId,\n header: undefined,\n cell: (info) => {\n const row = info.row.original;\n return info.row.getIsGrouped() ? undefined : formatScrRef(row.start);\n },\n sortingFn: (a, b) => {\n return compareScrRefs(a.original.start, b.original.start);\n },\n enableGrouping: false,\n },\n {\n accessorFn: (row) => row.source.displayName,\n id: typeColId,\n header: showSrcCol ? (colInfo?.typeColumnName ?? defaultTypeColumnName) : undefined,\n cell: (info) => (showSrcCol || info.row.getIsGrouped() ? info.getValue() : undefined),\n getGroupingValue: (row) => row.source.id,\n sortingFn: (a, b) =>\n a.original.source.displayName.localeCompare(b.original.source.displayName),\n enableGrouping: true,\n },\n {\n accessorFn: (row) => row.detail,\n id: detailsColId,\n header: colInfo?.detailsColumnName ?? defaultDetailsColumnName,\n cell: (info) => info.getValue(),\n enableGrouping: false,\n },\n ];\n}\n\nconst toRefOrRange = (scriptureSelection: ScriptureSelection) => {\n if (!('offset' in scriptureSelection.start))\n throw new Error('No offset available in range start');\n if (scriptureSelection.end && !('offset' in scriptureSelection.end))\n throw new Error('No offset available in range end');\n const { offset: offsetStart } = scriptureSelection.start;\n let offsetEnd: number = 0;\n if (scriptureSelection.end) ({ offset: offsetEnd } = scriptureSelection.end);\n if (\n !scriptureSelection.end ||\n compareScrRefs(scriptureSelection.start, scriptureSelection.end) === 0\n )\n return `${scrRefToBBBCCCVVV(scriptureSelection.start)}+${offsetStart}`;\n return `${scrRefToBBBCCCVVV(scriptureSelection.start)}+${offsetStart}-${scrRefToBBBCCCVVV(scriptureSelection.end)}+${offsetEnd}`;\n};\n\nconst getRowKey = (row: ScriptureSrcItemDetail) =>\n `${toRefOrRange({ start: row.start, end: row.end })} ${row.source.displayName} ${row.detail}`;\n\n/**\n * Component to display a combined list of detailed items from one or more sources, where the items\n * are keyed primarily by Scripture reference. This is particularly useful for displaying a list of\n * results from Scripture checks, but more generally could be used to display any \"results\" from any\n * source(s). The component allows for grouping by Scripture book, source, or both. By default, it\n * displays somewhat \"tree-like\" which allows it to be more horizontally compact and intuitive. But\n * it also has the option of displaying as a traditional table with column headings (with or without\n * the source column showing).\n */\nexport default function ScriptureResultsViewer({\n sources,\n showColumnHeaders = false,\n showSourceColumn = false,\n scriptureReferenceColumnName,\n scriptureBookGroupName,\n typeColumnName,\n detailsColumnName,\n onRowSelected,\n direction = 'ltr',\n}: ScriptureResultsViewerProps) {\n const [grouping, setGrouping] = useState([]);\n const [sorting, setSorting] = useState([{ id: scrBookColId, desc: false }]);\n const [rowSelection, setRowSelection] = useState({});\n\n const scriptureResults = useMemo(\n () =>\n sources.flatMap((source) => {\n return source.data.map((item) => ({\n ...item,\n source: source.source,\n }));\n }),\n [sources],\n );\n\n const columns = useMemo(\n () =>\n getColumns(\n {\n scriptureReferenceColumnName,\n typeColumnName,\n detailsColumnName,\n },\n showSourceColumn,\n ),\n [scriptureReferenceColumnName, typeColumnName, detailsColumnName, showSourceColumn],\n );\n\n useEffect(() => {\n // Ensure sorting is applied correctly when grouped by type\n if (grouping.includes(typeColId)) {\n setSorting([\n { id: typeColId, desc: false },\n { id: scrBookColId, desc: false },\n ]);\n } else {\n setSorting([{ id: scrBookColId, desc: false }]);\n }\n }, [grouping]);\n\n const table = useReactTable({\n data: scriptureResults,\n columns,\n state: {\n grouping,\n sorting,\n rowSelection,\n },\n onGroupingChange: setGrouping,\n onSortingChange: setSorting,\n onRowSelectionChange: setRowSelection,\n getExpandedRowModel: getExpandedRowModel(),\n getGroupedRowModel: getGroupedRowModel(),\n getCoreRowModel: getCoreRowModel(),\n getSortedRowModel: getSortedRowModel(),\n getRowId: getRowKey,\n autoResetExpanded: false,\n enableMultiRowSelection: false,\n enableSubRowSelection: false,\n });\n\n useEffect(() => {\n if (onRowSelected) {\n const selectedRows = table.getSelectedRowModel().rowsById;\n const keys = Object.keys(selectedRows);\n if (keys.length === 1) {\n const selectedRow = scriptureResults.find((row) => getRowKey(row) === keys[0]) || undefined;\n if (selectedRow) onRowSelected(selectedRow);\n }\n }\n }, [rowSelection, scriptureResults, onRowSelected, table]);\n\n // Define possible grouping options\n const scrBookGroupName = scriptureBookGroupName ?? defaultScrBookGroupName;\n const typeGroupName = typeColumnName ?? defaultTypeColumnName;\n\n const groupingOptions = [\n { label: 'No Grouping', value: [] },\n { label: `Group by ${scrBookGroupName}`, value: [scrBookColId] },\n { label: `Group by ${typeGroupName}`, value: [typeColId] },\n {\n label: `Group by ${scrBookGroupName} and ${typeGroupName}`,\n value: [scrBookColId, typeColId],\n },\n {\n label: `Group by ${typeGroupName} and ${scrBookGroupName}`,\n value: [typeColId, scrBookColId],\n },\n ];\n\n const handleSelectChange = (selectedGrouping: string) => {\n setGrouping(JSON.parse(selectedGrouping));\n };\n\n const handleRowClick = (row: Row, event: MouseEvent) => {\n if (!row.getIsGrouped() && !row.getIsSelected()) {\n row.getToggleSelectedHandler()(event);\n }\n };\n\n const getEvenOrOddBandingStyle = (row: Row, index: number) => {\n if (row.getIsGrouped()) return '';\n // UX has now said they don't think they want banding. I'm leaving in the code to\n // set even and odd styles, but there's nothing in the CSS to style them differently.\n // The \"even\" style used to also have tw-bg-neutral-300 (along with even) to create\n // a visual banding effect. That could be added back in if UX changes the decision.\n return cn('banded-row', index % 2 === 0 ? 'even' : 'odd');\n };\n\n const getIndent = (\n groupingState: GroupingState,\n row: Row,\n cell: Cell,\n ) => {\n if (groupingState?.length === 0 || row.depth < cell.column.getGroupedIndex()) return undefined;\n if (row.getIsGrouped()) {\n switch (row.depth) {\n case 1:\n return 'tw-ps-4';\n default:\n return undefined;\n }\n }\n switch (row.depth) {\n case 1:\n return 'tw-ps-8';\n case 2:\n return 'tw-ps-12';\n default:\n return undefined;\n }\n };\n\n return (\n
    \n {!showColumnHeaders && (\n {\n handleSelectChange(value);\n }}\n >\n \n \n \n \n \n {groupingOptions.map((option) => (\n \n {option.label}\n \n ))}\n \n \n \n )}\n \n {showColumnHeaders && (\n \n {table.getHeaderGroups().map((headerGroup) => (\n \n {headerGroup.headers\n .filter((h) => h.column.columnDef.header)\n .map((header) => (\n /* For sticky column headers to work, we probably need to change the default definition of the shadcn Table component. See https://github.com/shadcn-ui/ui/issues/1151 */\n \n {header.isPlaceholder ? undefined : (\n
    \n {header.column.getCanGroup() ? (\n \n {header.column.getIsGrouped() ? `🛑` : `👊 `}\n \n ) : undefined}{' '}\n {flexRender(header.column.columnDef.header, header.getContext())}\n
    \n )}\n
    \n ))}\n
    \n ))}\n
    \n )}\n \n {table.getRowModel().rows.map((row, rowIndex) => {\n return (\n handleRowClick(row, event)}\n >\n {row.getVisibleCells().map((cell) => {\n if (\n cell.getIsPlaceholder() ||\n (cell.column.columnDef.enableGrouping &&\n !cell.getIsGrouped() &&\n (cell.column.columnDef.id !== typeColId || !showSourceColumn))\n )\n return undefined;\n return (\n \n {(() => {\n if (cell.getIsGrouped()) {\n return (\n \n {row.getIsExpanded() && }\n {!row.getIsExpanded() &&\n (direction === 'ltr' ? : )}{' '}\n {flexRender(cell.column.columnDef.cell, cell.getContext())} (\n {row.subRows.length})\n \n );\n }\n\n // if (cell.getIsAggregated()) {\n // flexRender(\n // cell.column.columnDef.aggregatedCell ?? cell.column.columnDef.cell,\n // cell.getContext(),\n // );\n // }\n\n return flexRender(cell.column.columnDef.cell, cell.getContext());\n })()}\n \n );\n })}\n \n );\n })}\n \n
    \n
    \n );\n}\n","import {\n getLocalizeKeyForScrollGroupId,\n LanguageStrings,\n ScrollGroupId,\n} from 'platform-bible-utils';\nimport {\n Select,\n SelectContent,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\n\nconst DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS = {\n [getLocalizeKeyForScrollGroupId('undefined')]: 'Ø',\n [getLocalizeKeyForScrollGroupId(0)]: 'A',\n [getLocalizeKeyForScrollGroupId(1)]: 'B',\n [getLocalizeKeyForScrollGroupId(2)]: 'C',\n [getLocalizeKeyForScrollGroupId(3)]: 'D',\n [getLocalizeKeyForScrollGroupId(4)]: 'E',\n [getLocalizeKeyForScrollGroupId(5)]: 'F',\n [getLocalizeKeyForScrollGroupId(6)]: 'G',\n [getLocalizeKeyForScrollGroupId(7)]: 'H',\n [getLocalizeKeyForScrollGroupId(8)]: 'I',\n [getLocalizeKeyForScrollGroupId(9)]: 'J',\n [getLocalizeKeyForScrollGroupId(10)]: 'K',\n [getLocalizeKeyForScrollGroupId(11)]: 'L',\n [getLocalizeKeyForScrollGroupId(12)]: 'M',\n [getLocalizeKeyForScrollGroupId(13)]: 'N',\n [getLocalizeKeyForScrollGroupId(14)]: 'O',\n [getLocalizeKeyForScrollGroupId(15)]: 'P',\n [getLocalizeKeyForScrollGroupId(16)]: 'Q',\n [getLocalizeKeyForScrollGroupId(17)]: 'R',\n [getLocalizeKeyForScrollGroupId(18)]: 'S',\n [getLocalizeKeyForScrollGroupId(19)]: 'T',\n [getLocalizeKeyForScrollGroupId(20)]: 'U',\n [getLocalizeKeyForScrollGroupId(21)]: 'V',\n [getLocalizeKeyForScrollGroupId(22)]: 'W',\n [getLocalizeKeyForScrollGroupId(23)]: 'X',\n [getLocalizeKeyForScrollGroupId(24)]: 'Y',\n [getLocalizeKeyForScrollGroupId(25)]: 'Z',\n};\n\nexport type ScrollGroupSelectorProps = {\n /**\n * List of scroll group ids to show to the user. Either a {@link ScrollGroupId} or `undefined` for\n * no scroll group\n */\n availableScrollGroupIds: (ScrollGroupId | undefined)[];\n /** Currently selected scroll group id. `undefined` for no scroll group */\n scrollGroupId: ScrollGroupId | undefined;\n /** Callback function run when the user tries to change the scroll group id */\n onChangeScrollGroupId: (newScrollGroupId: ScrollGroupId | undefined) => void;\n /**\n * Localized strings to use for displaying scroll group ids. Must be an object whose keys are\n * `getLocalizeKeyForScrollGroupId(scrollGroupId)` for all scroll group ids (and `undefined` if\n * included) in {@link ScrollGroupSelectorProps.availableScrollGroupIds} and whose values are the\n * localized strings to use for those scroll group ids.\n *\n * Defaults to English localizations of English alphabet for scroll groups 0-25 (e.g. 0 is A) and\n * Ø for `undefined`. Will fill in any that are not provided with these English localizations.\n * Also, if any values match the keys, the English localization will be used. This is useful in\n * case you want to pass in a temporary version of the localized strings while your localized\n * strings load.\n *\n * @example\n *\n * ```typescript\n * const myScrollGroupIdLocalizedStrings = {\n * [getLocalizeKeyForScrollGroupId('undefined')]: 'Ø',\n * [getLocalizeKeyForScrollGroupId(0)]: 'A',\n * [getLocalizeKeyForScrollGroupId(1)]: 'B',\n * [getLocalizeKeyForScrollGroupId(2)]: 'C',\n * [getLocalizeKeyForScrollGroupId(3)]: 'D',\n * [getLocalizeKeyForScrollGroupId(4)]: 'E',\n * };\n * ```\n *\n * @example\n *\n * ```tsx\n * const availableScrollGroupIds = [undefined, 0, 1, 2, 3, 4];\n *\n * const localizeKeys = getLocalizeKeysForScrollGroupIds();\n *\n * const [localizedStrings] = useLocalizedStrings(localizeKeys);\n *\n * ...\n *\n * \n * ```\n */\n localizedStrings?: LanguageStrings;\n};\n\n/** Selector component for choosing a scroll group */\nexport default function ScrollGroupSelector({\n availableScrollGroupIds,\n scrollGroupId,\n onChangeScrollGroupId,\n localizedStrings = {},\n}: ScrollGroupSelectorProps) {\n const localizedStringsDefaulted = {\n ...DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS,\n ...Object.fromEntries(\n Object.entries(localizedStrings).map(\n ([localizedStringKey, localizedStringValue]: [string, string]) => [\n localizedStringKey,\n localizedStringKey === localizedStringValue &&\n localizedStringKey in DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS\n ? DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS[localizedStringKey]\n : localizedStringValue,\n ],\n ),\n ),\n };\n return (\n \n onChangeScrollGroupId(\n newScrollGroupString === 'undefined' ? undefined : parseInt(newScrollGroupString, 10),\n )\n }\n >\n \n \n \n \n {availableScrollGroupIds.map((scrollGroupOptionId) => (\n \n {localizedStringsDefaulted[getLocalizeKeyForScrollGroupId(scrollGroupOptionId)]}\n \n ))}\n \n \n );\n}\n","import { PropsWithChildren } from 'react';\nimport { Separator } from '@/components/shadcn-ui/separator';\n\n/** Props for the SettingsList component, currently just children */\ntype SettingsListProps = PropsWithChildren;\n\n/**\n * SettingsList component is a wrapper for list items. Rendered with a formatted div\n *\n * @param children To populate the list with\n * @returns Formatted div encompassing the children\n */\nexport function SettingsList({ children }: SettingsListProps) {\n return
    {children}
    ;\n}\n\n/** Props for SettingsListItem component */\ntype SettingsListItemProps = PropsWithChildren & {\n /** Primary text of the list item */\n primary: string;\n\n /** Optional text of the list item */\n secondary?: string | undefined;\n\n /** Optional boolean to display a message if the children aren't loaded yet. Defaults to false */\n isLoading?: boolean;\n\n /** Optional message to display if isLoading */\n loadingMessage?: string;\n};\n\n/**\n * SettingsListItem component is a common list item. Rendered with a formatted div\n *\n * @param primary Primary text of the list item\n * @param secondary Optional secondary text of the list item\n * @param isLoading Optional, to display a message if the action component isn't generated yet,\n * defaults to false\n * @param children The action component(s) to provide for this item\n * @param loadingMessage Optional, message to display if isLoading\n * @returns Formatted div encompassing the list item content\n */\nexport function SettingsListItem({\n primary,\n secondary,\n children,\n isLoading = false,\n loadingMessage,\n}: SettingsListItemProps) {\n return (\n
    \n
    \n

    {primary}

    \n

    \n {secondary}\n

    \n
    \n\n {isLoading ? (\n

    {loadingMessage}

    \n ) : (\n
    {children}
    \n )}\n
    \n );\n}\n\n/** Props for SettingsListHeader component */\ntype SettingsListHeaderProps = {\n /** The primary text of the list header */\n primary: string;\n\n /** Optional secondary text of the list header */\n secondary?: string | undefined;\n\n /** Optional boolean to include a separator underneath the secondary text. Defaults to false */\n includeSeparator?: boolean;\n};\n\n/**\n * SettingsListHeader component displays text above the list\n *\n * @param primary The primary text of the list header\n * @param secondary Optional secondary text of the list header\n * @param includeSeparator Optional boolean to include a separator underneath the secondary text.\n * Defaults to false\n * @returns Formatted div with list header content\n */\nexport function SettingsListHeader({\n primary,\n secondary,\n includeSeparator = false,\n}: SettingsListHeaderProps) {\n return (\n
    \n
    \n

    {primary}

    \n

    {secondary}

    \n
    \n {includeSeparator ? : ''}\n
    \n );\n}\n","import Checkbox from '@/components/shadcn-ui/checkbox';\nimport { Label } from '@/components/shadcn-ui/label';\n\nexport type ChecklistProps = {\n /** Optional string representing the id attribute of the Checklist */\n id?: string;\n /** Optional string representing CSS class name(s) for styling */\n className?: string;\n /** Array of strings representing the checkable items */\n listItems: string[];\n /** Array of strings representing the checked items */\n selectedListItems: string[];\n /**\n * Function that is called when a checkbox item is selected or deselected\n *\n * @param item The string description for this item\n * @param selected True if selected, false if not selected\n */\n handleSelectListItem: (item: string, selected: boolean) => void;\n\n /**\n * Optional function creates a label for a provided checkable item\n *\n * @param item The item for which a label is to be created\n * @returns A string representing the label text for the checkbox associated with that item\n */\n createLabel?: (item: string) => string;\n};\n\n/** Renders a list of checkboxes. Each checkbox corresponds to an item from the `listItems` array. */\nexport default function Checklist({\n id,\n className,\n listItems,\n selectedListItems,\n handleSelectListItem,\n createLabel,\n}: ChecklistProps) {\n return (\n
    \n {listItems.map((item) => (\n
    \n handleSelectListItem(item, value)}\n />\n \n
    \n ))}\n
    \n );\n}\n","function _interopRequireDefault(obj) {\n return obj && obj.__esModule ? obj : {\n \"default\": obj\n };\n}\nmodule.exports = _interopRequireDefault, module.exports.__esModule = true, module.exports[\"default\"] = module.exports;","export default function chainPropTypes(propType1, propType2) {\n if (process.env.NODE_ENV === 'production') {\n return () => null;\n }\n return function validate(...args) {\n return propType1(...args) || propType2(...args);\n };\n}","export default function _extends() {\n _extends = Object.assign ? Object.assign.bind() : function (target) {\n for (var i = 1; i < arguments.length; i++) {\n var source = arguments[i];\n for (var key in source) {\n if (Object.prototype.hasOwnProperty.call(source, key)) {\n target[key] = source[key];\n }\n }\n }\n return target;\n };\n return _extends.apply(this, arguments);\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\n// https://github.com/sindresorhus/is-plain-obj/blob/main/index.js\nexport function isPlainObject(item) {\n if (typeof item !== 'object' || item === null) {\n return false;\n }\n const prototype = Object.getPrototypeOf(item);\n return (prototype === null || prototype === Object.prototype || Object.getPrototypeOf(prototype) === null) && !(Symbol.toStringTag in item) && !(Symbol.iterator in item);\n}\nfunction deepClone(source) {\n if (!isPlainObject(source)) {\n return source;\n }\n const output = {};\n Object.keys(source).forEach(key => {\n output[key] = deepClone(source[key]);\n });\n return output;\n}\nexport default function deepmerge(target, source, options = {\n clone: true\n}) {\n const output = options.clone ? _extends({}, target) : target;\n if (isPlainObject(target) && isPlainObject(source)) {\n Object.keys(source).forEach(key => {\n // Avoid prototype pollution\n if (key === '__proto__') {\n return;\n }\n if (isPlainObject(source[key]) && key in target && isPlainObject(target[key])) {\n // Since `output` is a clone of `target` and we have narrowed `target` in this block we can cast to the same type.\n output[key] = deepmerge(target[key], source[key], options);\n } else if (options.clone) {\n output[key] = isPlainObject(source[key]) ? deepClone(source[key]) : source[key];\n } else {\n output[key] = source[key];\n }\n });\n }\n return output;\n}","/** @license React v16.13.1\n * react-is.production.min.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';var b=\"function\"===typeof Symbol&&Symbol.for,c=b?Symbol.for(\"react.element\"):60103,d=b?Symbol.for(\"react.portal\"):60106,e=b?Symbol.for(\"react.fragment\"):60107,f=b?Symbol.for(\"react.strict_mode\"):60108,g=b?Symbol.for(\"react.profiler\"):60114,h=b?Symbol.for(\"react.provider\"):60109,k=b?Symbol.for(\"react.context\"):60110,l=b?Symbol.for(\"react.async_mode\"):60111,m=b?Symbol.for(\"react.concurrent_mode\"):60111,n=b?Symbol.for(\"react.forward_ref\"):60112,p=b?Symbol.for(\"react.suspense\"):60113,q=b?\nSymbol.for(\"react.suspense_list\"):60120,r=b?Symbol.for(\"react.memo\"):60115,t=b?Symbol.for(\"react.lazy\"):60116,v=b?Symbol.for(\"react.block\"):60121,w=b?Symbol.for(\"react.fundamental\"):60117,x=b?Symbol.for(\"react.responder\"):60118,y=b?Symbol.for(\"react.scope\"):60119;\nfunction z(a){if(\"object\"===typeof a&&null!==a){var u=a.$$typeof;switch(u){case c:switch(a=a.type,a){case l:case m:case e:case g:case f:case p:return a;default:switch(a=a&&a.$$typeof,a){case k:case n:case t:case r:case h:return a;default:return u}}case d:return u}}}function A(a){return z(a)===m}exports.AsyncMode=l;exports.ConcurrentMode=m;exports.ContextConsumer=k;exports.ContextProvider=h;exports.Element=c;exports.ForwardRef=n;exports.Fragment=e;exports.Lazy=t;exports.Memo=r;exports.Portal=d;\nexports.Profiler=g;exports.StrictMode=f;exports.Suspense=p;exports.isAsyncMode=function(a){return A(a)||z(a)===l};exports.isConcurrentMode=A;exports.isContextConsumer=function(a){return z(a)===k};exports.isContextProvider=function(a){return z(a)===h};exports.isElement=function(a){return\"object\"===typeof a&&null!==a&&a.$$typeof===c};exports.isForwardRef=function(a){return z(a)===n};exports.isFragment=function(a){return z(a)===e};exports.isLazy=function(a){return z(a)===t};\nexports.isMemo=function(a){return z(a)===r};exports.isPortal=function(a){return z(a)===d};exports.isProfiler=function(a){return z(a)===g};exports.isStrictMode=function(a){return z(a)===f};exports.isSuspense=function(a){return z(a)===p};\nexports.isValidElementType=function(a){return\"string\"===typeof a||\"function\"===typeof a||a===e||a===m||a===g||a===f||a===p||a===q||\"object\"===typeof a&&null!==a&&(a.$$typeof===t||a.$$typeof===r||a.$$typeof===h||a.$$typeof===k||a.$$typeof===n||a.$$typeof===w||a.$$typeof===x||a.$$typeof===y||a.$$typeof===v)};exports.typeOf=z;\n","/** @license React v16.13.1\n * react-is.development.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\n\n\nif (process.env.NODE_ENV !== \"production\") {\n (function() {\n'use strict';\n\n// The Symbol used to tag the ReactElement-like types. If there is no native Symbol\n// nor polyfill, then a plain number is used for performance.\nvar hasSymbol = typeof Symbol === 'function' && Symbol.for;\nvar REACT_ELEMENT_TYPE = hasSymbol ? Symbol.for('react.element') : 0xeac7;\nvar REACT_PORTAL_TYPE = hasSymbol ? Symbol.for('react.portal') : 0xeaca;\nvar REACT_FRAGMENT_TYPE = hasSymbol ? Symbol.for('react.fragment') : 0xeacb;\nvar REACT_STRICT_MODE_TYPE = hasSymbol ? Symbol.for('react.strict_mode') : 0xeacc;\nvar REACT_PROFILER_TYPE = hasSymbol ? Symbol.for('react.profiler') : 0xead2;\nvar REACT_PROVIDER_TYPE = hasSymbol ? Symbol.for('react.provider') : 0xeacd;\nvar REACT_CONTEXT_TYPE = hasSymbol ? Symbol.for('react.context') : 0xeace; // TODO: We don't use AsyncMode or ConcurrentMode anymore. They were temporary\n// (unstable) APIs that have been removed. Can we remove the symbols?\n\nvar REACT_ASYNC_MODE_TYPE = hasSymbol ? Symbol.for('react.async_mode') : 0xeacf;\nvar REACT_CONCURRENT_MODE_TYPE = hasSymbol ? Symbol.for('react.concurrent_mode') : 0xeacf;\nvar REACT_FORWARD_REF_TYPE = hasSymbol ? Symbol.for('react.forward_ref') : 0xead0;\nvar REACT_SUSPENSE_TYPE = hasSymbol ? Symbol.for('react.suspense') : 0xead1;\nvar REACT_SUSPENSE_LIST_TYPE = hasSymbol ? Symbol.for('react.suspense_list') : 0xead8;\nvar REACT_MEMO_TYPE = hasSymbol ? Symbol.for('react.memo') : 0xead3;\nvar REACT_LAZY_TYPE = hasSymbol ? Symbol.for('react.lazy') : 0xead4;\nvar REACT_BLOCK_TYPE = hasSymbol ? Symbol.for('react.block') : 0xead9;\nvar REACT_FUNDAMENTAL_TYPE = hasSymbol ? Symbol.for('react.fundamental') : 0xead5;\nvar REACT_RESPONDER_TYPE = hasSymbol ? Symbol.for('react.responder') : 0xead6;\nvar REACT_SCOPE_TYPE = hasSymbol ? Symbol.for('react.scope') : 0xead7;\n\nfunction isValidElementType(type) {\n return typeof type === 'string' || typeof type === 'function' || // Note: its typeof might be other than 'symbol' or 'number' if it's a polyfill.\n type === REACT_FRAGMENT_TYPE || type === REACT_CONCURRENT_MODE_TYPE || type === REACT_PROFILER_TYPE || type === REACT_STRICT_MODE_TYPE || type === REACT_SUSPENSE_TYPE || type === REACT_SUSPENSE_LIST_TYPE || typeof type === 'object' && type !== null && (type.$$typeof === REACT_LAZY_TYPE || type.$$typeof === REACT_MEMO_TYPE || type.$$typeof === REACT_PROVIDER_TYPE || type.$$typeof === REACT_CONTEXT_TYPE || type.$$typeof === REACT_FORWARD_REF_TYPE || type.$$typeof === REACT_FUNDAMENTAL_TYPE || type.$$typeof === REACT_RESPONDER_TYPE || type.$$typeof === REACT_SCOPE_TYPE || type.$$typeof === REACT_BLOCK_TYPE);\n}\n\nfunction typeOf(object) {\n if (typeof object === 'object' && object !== null) {\n var $$typeof = object.$$typeof;\n\n switch ($$typeof) {\n case REACT_ELEMENT_TYPE:\n var type = object.type;\n\n switch (type) {\n case REACT_ASYNC_MODE_TYPE:\n case REACT_CONCURRENT_MODE_TYPE:\n case REACT_FRAGMENT_TYPE:\n case REACT_PROFILER_TYPE:\n case REACT_STRICT_MODE_TYPE:\n case REACT_SUSPENSE_TYPE:\n return type;\n\n default:\n var $$typeofType = type && type.$$typeof;\n\n switch ($$typeofType) {\n case REACT_CONTEXT_TYPE:\n case REACT_FORWARD_REF_TYPE:\n case REACT_LAZY_TYPE:\n case REACT_MEMO_TYPE:\n case REACT_PROVIDER_TYPE:\n return $$typeofType;\n\n default:\n return $$typeof;\n }\n\n }\n\n case REACT_PORTAL_TYPE:\n return $$typeof;\n }\n }\n\n return undefined;\n} // AsyncMode is deprecated along with isAsyncMode\n\nvar AsyncMode = REACT_ASYNC_MODE_TYPE;\nvar ConcurrentMode = REACT_CONCURRENT_MODE_TYPE;\nvar ContextConsumer = REACT_CONTEXT_TYPE;\nvar ContextProvider = REACT_PROVIDER_TYPE;\nvar Element = REACT_ELEMENT_TYPE;\nvar ForwardRef = REACT_FORWARD_REF_TYPE;\nvar Fragment = REACT_FRAGMENT_TYPE;\nvar Lazy = REACT_LAZY_TYPE;\nvar Memo = REACT_MEMO_TYPE;\nvar Portal = REACT_PORTAL_TYPE;\nvar Profiler = REACT_PROFILER_TYPE;\nvar StrictMode = REACT_STRICT_MODE_TYPE;\nvar Suspense = REACT_SUSPENSE_TYPE;\nvar hasWarnedAboutDeprecatedIsAsyncMode = false; // AsyncMode should be deprecated\n\nfunction isAsyncMode(object) {\n {\n if (!hasWarnedAboutDeprecatedIsAsyncMode) {\n hasWarnedAboutDeprecatedIsAsyncMode = true; // Using console['warn'] to evade Babel and ESLint\n\n console['warn']('The ReactIs.isAsyncMode() alias has been deprecated, ' + 'and will be removed in React 17+. Update your code to use ' + 'ReactIs.isConcurrentMode() instead. It has the exact same API.');\n }\n }\n\n return isConcurrentMode(object) || typeOf(object) === REACT_ASYNC_MODE_TYPE;\n}\nfunction isConcurrentMode(object) {\n return typeOf(object) === REACT_CONCURRENT_MODE_TYPE;\n}\nfunction isContextConsumer(object) {\n return typeOf(object) === REACT_CONTEXT_TYPE;\n}\nfunction isContextProvider(object) {\n return typeOf(object) === REACT_PROVIDER_TYPE;\n}\nfunction isElement(object) {\n return typeof object === 'object' && object !== null && object.$$typeof === REACT_ELEMENT_TYPE;\n}\nfunction isForwardRef(object) {\n return typeOf(object) === REACT_FORWARD_REF_TYPE;\n}\nfunction isFragment(object) {\n return typeOf(object) === REACT_FRAGMENT_TYPE;\n}\nfunction isLazy(object) {\n return typeOf(object) === REACT_LAZY_TYPE;\n}\nfunction isMemo(object) {\n return typeOf(object) === REACT_MEMO_TYPE;\n}\nfunction isPortal(object) {\n return typeOf(object) === REACT_PORTAL_TYPE;\n}\nfunction isProfiler(object) {\n return typeOf(object) === REACT_PROFILER_TYPE;\n}\nfunction isStrictMode(object) {\n return typeOf(object) === REACT_STRICT_MODE_TYPE;\n}\nfunction isSuspense(object) {\n return typeOf(object) === REACT_SUSPENSE_TYPE;\n}\n\nexports.AsyncMode = AsyncMode;\nexports.ConcurrentMode = ConcurrentMode;\nexports.ContextConsumer = ContextConsumer;\nexports.ContextProvider = ContextProvider;\nexports.Element = Element;\nexports.ForwardRef = ForwardRef;\nexports.Fragment = Fragment;\nexports.Lazy = Lazy;\nexports.Memo = Memo;\nexports.Portal = Portal;\nexports.Profiler = Profiler;\nexports.StrictMode = StrictMode;\nexports.Suspense = Suspense;\nexports.isAsyncMode = isAsyncMode;\nexports.isConcurrentMode = isConcurrentMode;\nexports.isContextConsumer = isContextConsumer;\nexports.isContextProvider = isContextProvider;\nexports.isElement = isElement;\nexports.isForwardRef = isForwardRef;\nexports.isFragment = isFragment;\nexports.isLazy = isLazy;\nexports.isMemo = isMemo;\nexports.isPortal = isPortal;\nexports.isProfiler = isProfiler;\nexports.isStrictMode = isStrictMode;\nexports.isSuspense = isSuspense;\nexports.isValidElementType = isValidElementType;\nexports.typeOf = typeOf;\n })();\n}\n","'use strict';\n\nif (process.env.NODE_ENV === 'production') {\n module.exports = require('./cjs/react-is.production.min.js');\n} else {\n module.exports = require('./cjs/react-is.development.js');\n}\n","/*\nobject-assign\n(c) Sindre Sorhus\n@license MIT\n*/\n\n'use strict';\n/* eslint-disable no-unused-vars */\nvar getOwnPropertySymbols = Object.getOwnPropertySymbols;\nvar hasOwnProperty = Object.prototype.hasOwnProperty;\nvar propIsEnumerable = Object.prototype.propertyIsEnumerable;\n\nfunction toObject(val) {\n\tif (val === null || val === undefined) {\n\t\tthrow new TypeError('Object.assign cannot be called with null or undefined');\n\t}\n\n\treturn Object(val);\n}\n\nfunction shouldUseNative() {\n\ttry {\n\t\tif (!Object.assign) {\n\t\t\treturn false;\n\t\t}\n\n\t\t// Detect buggy property enumeration order in older V8 versions.\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=4118\n\t\tvar test1 = new String('abc'); // eslint-disable-line no-new-wrappers\n\t\ttest1[5] = 'de';\n\t\tif (Object.getOwnPropertyNames(test1)[0] === '5') {\n\t\t\treturn false;\n\t\t}\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=3056\n\t\tvar test2 = {};\n\t\tfor (var i = 0; i < 10; i++) {\n\t\t\ttest2['_' + String.fromCharCode(i)] = i;\n\t\t}\n\t\tvar order2 = Object.getOwnPropertyNames(test2).map(function (n) {\n\t\t\treturn test2[n];\n\t\t});\n\t\tif (order2.join('') !== '0123456789') {\n\t\t\treturn false;\n\t\t}\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=3056\n\t\tvar test3 = {};\n\t\t'abcdefghijklmnopqrst'.split('').forEach(function (letter) {\n\t\t\ttest3[letter] = letter;\n\t\t});\n\t\tif (Object.keys(Object.assign({}, test3)).join('') !==\n\t\t\t\t'abcdefghijklmnopqrst') {\n\t\t\treturn false;\n\t\t}\n\n\t\treturn true;\n\t} catch (err) {\n\t\t// We don't expect any of the above to throw, but better to be safe.\n\t\treturn false;\n\t}\n}\n\nmodule.exports = shouldUseNative() ? Object.assign : function (target, source) {\n\tvar from;\n\tvar to = toObject(target);\n\tvar symbols;\n\n\tfor (var s = 1; s < arguments.length; s++) {\n\t\tfrom = Object(arguments[s]);\n\n\t\tfor (var key in from) {\n\t\t\tif (hasOwnProperty.call(from, key)) {\n\t\t\t\tto[key] = from[key];\n\t\t\t}\n\t\t}\n\n\t\tif (getOwnPropertySymbols) {\n\t\t\tsymbols = getOwnPropertySymbols(from);\n\t\t\tfor (var i = 0; i < symbols.length; i++) {\n\t\t\t\tif (propIsEnumerable.call(from, symbols[i])) {\n\t\t\t\t\tto[symbols[i]] = from[symbols[i]];\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\n\treturn to;\n};\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar ReactPropTypesSecret = 'SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED';\n\nmodule.exports = ReactPropTypesSecret;\n","module.exports = Function.call.bind(Object.prototype.hasOwnProperty);\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar printWarning = function() {};\n\nif (process.env.NODE_ENV !== 'production') {\n var ReactPropTypesSecret = require('./lib/ReactPropTypesSecret');\n var loggedTypeFailures = {};\n var has = require('./lib/has');\n\n printWarning = function(text) {\n var message = 'Warning: ' + text;\n if (typeof console !== 'undefined') {\n console.error(message);\n }\n try {\n // --- Welcome to debugging React ---\n // This error was thrown as a convenience so that you can use this stack\n // to find the callsite that caused this warning to fire.\n throw new Error(message);\n } catch (x) { /**/ }\n };\n}\n\n/**\n * Assert that the values match with the type specs.\n * Error messages are memorized and will only be shown once.\n *\n * @param {object} typeSpecs Map of name to a ReactPropType\n * @param {object} values Runtime values that need to be type-checked\n * @param {string} location e.g. \"prop\", \"context\", \"child context\"\n * @param {string} componentName Name of the component for error messages.\n * @param {?Function} getStack Returns the component stack.\n * @private\n */\nfunction checkPropTypes(typeSpecs, values, location, componentName, getStack) {\n if (process.env.NODE_ENV !== 'production') {\n for (var typeSpecName in typeSpecs) {\n if (has(typeSpecs, typeSpecName)) {\n var error;\n // Prop type validation may throw. In case they do, we don't want to\n // fail the render phase where it didn't fail before. So we log it.\n // After these have been cleaned up, we'll let them throw.\n try {\n // This is intentionally an invariant that gets caught. It's the same\n // behavior as without this statement except with a better message.\n if (typeof typeSpecs[typeSpecName] !== 'function') {\n var err = Error(\n (componentName || 'React class') + ': ' + location + ' type `' + typeSpecName + '` is invalid; ' +\n 'it must be a function, usually from the `prop-types` package, but received `' + typeof typeSpecs[typeSpecName] + '`.' +\n 'This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.'\n );\n err.name = 'Invariant Violation';\n throw err;\n }\n error = typeSpecs[typeSpecName](values, typeSpecName, componentName, location, null, ReactPropTypesSecret);\n } catch (ex) {\n error = ex;\n }\n if (error && !(error instanceof Error)) {\n printWarning(\n (componentName || 'React class') + ': type specification of ' +\n location + ' `' + typeSpecName + '` is invalid; the type checker ' +\n 'function must return `null` or an `Error` but returned a ' + typeof error + '. ' +\n 'You may have forgotten to pass an argument to the type checker ' +\n 'creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and ' +\n 'shape all require an argument).'\n );\n }\n if (error instanceof Error && !(error.message in loggedTypeFailures)) {\n // Only monitor this failure once because there tends to be a lot of the\n // same error.\n loggedTypeFailures[error.message] = true;\n\n var stack = getStack ? getStack() : '';\n\n printWarning(\n 'Failed ' + location + ' type: ' + error.message + (stack != null ? stack : '')\n );\n }\n }\n }\n }\n}\n\n/**\n * Resets warning cache when testing.\n *\n * @private\n */\ncheckPropTypes.resetWarningCache = function() {\n if (process.env.NODE_ENV !== 'production') {\n loggedTypeFailures = {};\n }\n}\n\nmodule.exports = checkPropTypes;\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar ReactIs = require('react-is');\nvar assign = require('object-assign');\n\nvar ReactPropTypesSecret = require('./lib/ReactPropTypesSecret');\nvar has = require('./lib/has');\nvar checkPropTypes = require('./checkPropTypes');\n\nvar printWarning = function() {};\n\nif (process.env.NODE_ENV !== 'production') {\n printWarning = function(text) {\n var message = 'Warning: ' + text;\n if (typeof console !== 'undefined') {\n console.error(message);\n }\n try {\n // --- Welcome to debugging React ---\n // This error was thrown as a convenience so that you can use this stack\n // to find the callsite that caused this warning to fire.\n throw new Error(message);\n } catch (x) {}\n };\n}\n\nfunction emptyFunctionThatReturnsNull() {\n return null;\n}\n\nmodule.exports = function(isValidElement, throwOnDirectAccess) {\n /* global Symbol */\n var ITERATOR_SYMBOL = typeof Symbol === 'function' && Symbol.iterator;\n var FAUX_ITERATOR_SYMBOL = '@@iterator'; // Before Symbol spec.\n\n /**\n * Returns the iterator method function contained on the iterable object.\n *\n * Be sure to invoke the function with the iterable as context:\n *\n * var iteratorFn = getIteratorFn(myIterable);\n * if (iteratorFn) {\n * var iterator = iteratorFn.call(myIterable);\n * ...\n * }\n *\n * @param {?object} maybeIterable\n * @return {?function}\n */\n function getIteratorFn(maybeIterable) {\n var iteratorFn = maybeIterable && (ITERATOR_SYMBOL && maybeIterable[ITERATOR_SYMBOL] || maybeIterable[FAUX_ITERATOR_SYMBOL]);\n if (typeof iteratorFn === 'function') {\n return iteratorFn;\n }\n }\n\n /**\n * Collection of methods that allow declaration and validation of props that are\n * supplied to React components. Example usage:\n *\n * var Props = require('ReactPropTypes');\n * var MyArticle = React.createClass({\n * propTypes: {\n * // An optional string prop named \"description\".\n * description: Props.string,\n *\n * // A required enum prop named \"category\".\n * category: Props.oneOf(['News','Photos']).isRequired,\n *\n * // A prop named \"dialog\" that requires an instance of Dialog.\n * dialog: Props.instanceOf(Dialog).isRequired\n * },\n * render: function() { ... }\n * });\n *\n * A more formal specification of how these methods are used:\n *\n * type := array|bool|func|object|number|string|oneOf([...])|instanceOf(...)\n * decl := ReactPropTypes.{type}(.isRequired)?\n *\n * Each and every declaration produces a function with the same signature. This\n * allows the creation of custom validation functions. For example:\n *\n * var MyLink = React.createClass({\n * propTypes: {\n * // An optional string or URI prop named \"href\".\n * href: function(props, propName, componentName) {\n * var propValue = props[propName];\n * if (propValue != null && typeof propValue !== 'string' &&\n * !(propValue instanceof URI)) {\n * return new Error(\n * 'Expected a string or an URI for ' + propName + ' in ' +\n * componentName\n * );\n * }\n * }\n * },\n * render: function() {...}\n * });\n *\n * @internal\n */\n\n var ANONYMOUS = '<>';\n\n // Important!\n // Keep this list in sync with production version in `./factoryWithThrowingShims.js`.\n var ReactPropTypes = {\n array: createPrimitiveTypeChecker('array'),\n bigint: createPrimitiveTypeChecker('bigint'),\n bool: createPrimitiveTypeChecker('boolean'),\n func: createPrimitiveTypeChecker('function'),\n number: createPrimitiveTypeChecker('number'),\n object: createPrimitiveTypeChecker('object'),\n string: createPrimitiveTypeChecker('string'),\n symbol: createPrimitiveTypeChecker('symbol'),\n\n any: createAnyTypeChecker(),\n arrayOf: createArrayOfTypeChecker,\n element: createElementTypeChecker(),\n elementType: createElementTypeTypeChecker(),\n instanceOf: createInstanceTypeChecker,\n node: createNodeChecker(),\n objectOf: createObjectOfTypeChecker,\n oneOf: createEnumTypeChecker,\n oneOfType: createUnionTypeChecker,\n shape: createShapeTypeChecker,\n exact: createStrictShapeTypeChecker,\n };\n\n /**\n * inlined Object.is polyfill to avoid requiring consumers ship their own\n * https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object/is\n */\n /*eslint-disable no-self-compare*/\n function is(x, y) {\n // SameValue algorithm\n if (x === y) {\n // Steps 1-5, 7-10\n // Steps 6.b-6.e: +0 != -0\n return x !== 0 || 1 / x === 1 / y;\n } else {\n // Step 6.a: NaN == NaN\n return x !== x && y !== y;\n }\n }\n /*eslint-enable no-self-compare*/\n\n /**\n * We use an Error-like object for backward compatibility as people may call\n * PropTypes directly and inspect their output. However, we don't use real\n * Errors anymore. We don't inspect their stack anyway, and creating them\n * is prohibitively expensive if they are created too often, such as what\n * happens in oneOfType() for any type before the one that matched.\n */\n function PropTypeError(message, data) {\n this.message = message;\n this.data = data && typeof data === 'object' ? data: {};\n this.stack = '';\n }\n // Make `instanceof Error` still work for returned errors.\n PropTypeError.prototype = Error.prototype;\n\n function createChainableTypeChecker(validate) {\n if (process.env.NODE_ENV !== 'production') {\n var manualPropTypeCallCache = {};\n var manualPropTypeWarningCount = 0;\n }\n function checkType(isRequired, props, propName, componentName, location, propFullName, secret) {\n componentName = componentName || ANONYMOUS;\n propFullName = propFullName || propName;\n\n if (secret !== ReactPropTypesSecret) {\n if (throwOnDirectAccess) {\n // New behavior only for users of `prop-types` package\n var err = new Error(\n 'Calling PropTypes validators directly is not supported by the `prop-types` package. ' +\n 'Use `PropTypes.checkPropTypes()` to call them. ' +\n 'Read more at http://fb.me/use-check-prop-types'\n );\n err.name = 'Invariant Violation';\n throw err;\n } else if (process.env.NODE_ENV !== 'production' && typeof console !== 'undefined') {\n // Old behavior for people using React.PropTypes\n var cacheKey = componentName + ':' + propName;\n if (\n !manualPropTypeCallCache[cacheKey] &&\n // Avoid spamming the console because they are often not actionable except for lib authors\n manualPropTypeWarningCount < 3\n ) {\n printWarning(\n 'You are manually calling a React.PropTypes validation ' +\n 'function for the `' + propFullName + '` prop on `' + componentName + '`. This is deprecated ' +\n 'and will throw in the standalone `prop-types` package. ' +\n 'You may be seeing this warning due to a third-party PropTypes ' +\n 'library. See https://fb.me/react-warning-dont-call-proptypes ' + 'for details.'\n );\n manualPropTypeCallCache[cacheKey] = true;\n manualPropTypeWarningCount++;\n }\n }\n }\n if (props[propName] == null) {\n if (isRequired) {\n if (props[propName] === null) {\n return new PropTypeError('The ' + location + ' `' + propFullName + '` is marked as required ' + ('in `' + componentName + '`, but its value is `null`.'));\n }\n return new PropTypeError('The ' + location + ' `' + propFullName + '` is marked as required in ' + ('`' + componentName + '`, but its value is `undefined`.'));\n }\n return null;\n } else {\n return validate(props, propName, componentName, location, propFullName);\n }\n }\n\n var chainedCheckType = checkType.bind(null, false);\n chainedCheckType.isRequired = checkType.bind(null, true);\n\n return chainedCheckType;\n }\n\n function createPrimitiveTypeChecker(expectedType) {\n function validate(props, propName, componentName, location, propFullName, secret) {\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== expectedType) {\n // `propValue` being instance of, say, date/regexp, pass the 'object'\n // check, but we can offer a more precise error message here rather than\n // 'of type `object`'.\n var preciseType = getPreciseType(propValue);\n\n return new PropTypeError(\n 'Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + preciseType + '` supplied to `' + componentName + '`, expected ') + ('`' + expectedType + '`.'),\n {expectedType: expectedType}\n );\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createAnyTypeChecker() {\n return createChainableTypeChecker(emptyFunctionThatReturnsNull);\n }\n\n function createArrayOfTypeChecker(typeChecker) {\n function validate(props, propName, componentName, location, propFullName) {\n if (typeof typeChecker !== 'function') {\n return new PropTypeError('Property `' + propFullName + '` of component `' + componentName + '` has invalid PropType notation inside arrayOf.');\n }\n var propValue = props[propName];\n if (!Array.isArray(propValue)) {\n var propType = getPropType(propValue);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected an array.'));\n }\n for (var i = 0; i < propValue.length; i++) {\n var error = typeChecker(propValue, i, componentName, location, propFullName + '[' + i + ']', ReactPropTypesSecret);\n if (error instanceof Error) {\n return error;\n }\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createElementTypeChecker() {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n if (!isValidElement(propValue)) {\n var propType = getPropType(propValue);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected a single ReactElement.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createElementTypeTypeChecker() {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n if (!ReactIs.isValidElementType(propValue)) {\n var propType = getPropType(propValue);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected a single ReactElement type.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createInstanceTypeChecker(expectedClass) {\n function validate(props, propName, componentName, location, propFullName) {\n if (!(props[propName] instanceof expectedClass)) {\n var expectedClassName = expectedClass.name || ANONYMOUS;\n var actualClassName = getClassName(props[propName]);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + actualClassName + '` supplied to `' + componentName + '`, expected ') + ('instance of `' + expectedClassName + '`.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createEnumTypeChecker(expectedValues) {\n if (!Array.isArray(expectedValues)) {\n if (process.env.NODE_ENV !== 'production') {\n if (arguments.length > 1) {\n printWarning(\n 'Invalid arguments supplied to oneOf, expected an array, got ' + arguments.length + ' arguments. ' +\n 'A common mistake is to write oneOf(x, y, z) instead of oneOf([x, y, z]).'\n );\n } else {\n printWarning('Invalid argument supplied to oneOf, expected an array.');\n }\n }\n return emptyFunctionThatReturnsNull;\n }\n\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n for (var i = 0; i < expectedValues.length; i++) {\n if (is(propValue, expectedValues[i])) {\n return null;\n }\n }\n\n var valuesString = JSON.stringify(expectedValues, function replacer(key, value) {\n var type = getPreciseType(value);\n if (type === 'symbol') {\n return String(value);\n }\n return value;\n });\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of value `' + String(propValue) + '` ' + ('supplied to `' + componentName + '`, expected one of ' + valuesString + '.'));\n }\n return createChainableTypeChecker(validate);\n }\n\n function createObjectOfTypeChecker(typeChecker) {\n function validate(props, propName, componentName, location, propFullName) {\n if (typeof typeChecker !== 'function') {\n return new PropTypeError('Property `' + propFullName + '` of component `' + componentName + '` has invalid PropType notation inside objectOf.');\n }\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== 'object') {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected an object.'));\n }\n for (var key in propValue) {\n if (has(propValue, key)) {\n var error = typeChecker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret);\n if (error instanceof Error) {\n return error;\n }\n }\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createUnionTypeChecker(arrayOfTypeCheckers) {\n if (!Array.isArray(arrayOfTypeCheckers)) {\n process.env.NODE_ENV !== 'production' ? printWarning('Invalid argument supplied to oneOfType, expected an instance of array.') : void 0;\n return emptyFunctionThatReturnsNull;\n }\n\n for (var i = 0; i < arrayOfTypeCheckers.length; i++) {\n var checker = arrayOfTypeCheckers[i];\n if (typeof checker !== 'function') {\n printWarning(\n 'Invalid argument supplied to oneOfType. Expected an array of check functions, but ' +\n 'received ' + getPostfixForTypeWarning(checker) + ' at index ' + i + '.'\n );\n return emptyFunctionThatReturnsNull;\n }\n }\n\n function validate(props, propName, componentName, location, propFullName) {\n var expectedTypes = [];\n for (var i = 0; i < arrayOfTypeCheckers.length; i++) {\n var checker = arrayOfTypeCheckers[i];\n var checkerResult = checker(props, propName, componentName, location, propFullName, ReactPropTypesSecret);\n if (checkerResult == null) {\n return null;\n }\n if (checkerResult.data && has(checkerResult.data, 'expectedType')) {\n expectedTypes.push(checkerResult.data.expectedType);\n }\n }\n var expectedTypesMessage = (expectedTypes.length > 0) ? ', expected one of type [' + expectedTypes.join(', ') + ']': '';\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` supplied to ' + ('`' + componentName + '`' + expectedTypesMessage + '.'));\n }\n return createChainableTypeChecker(validate);\n }\n\n function createNodeChecker() {\n function validate(props, propName, componentName, location, propFullName) {\n if (!isNode(props[propName])) {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` supplied to ' + ('`' + componentName + '`, expected a ReactNode.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function invalidValidatorError(componentName, location, propFullName, key, type) {\n return new PropTypeError(\n (componentName || 'React class') + ': ' + location + ' type `' + propFullName + '.' + key + '` is invalid; ' +\n 'it must be a function, usually from the `prop-types` package, but received `' + type + '`.'\n );\n }\n\n function createShapeTypeChecker(shapeTypes) {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== 'object') {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type `' + propType + '` ' + ('supplied to `' + componentName + '`, expected `object`.'));\n }\n for (var key in shapeTypes) {\n var checker = shapeTypes[key];\n if (typeof checker !== 'function') {\n return invalidValidatorError(componentName, location, propFullName, key, getPreciseType(checker));\n }\n var error = checker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret);\n if (error) {\n return error;\n }\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createStrictShapeTypeChecker(shapeTypes) {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== 'object') {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type `' + propType + '` ' + ('supplied to `' + componentName + '`, expected `object`.'));\n }\n // We need to check all keys in case some are required but missing from props.\n var allKeys = assign({}, props[propName], shapeTypes);\n for (var key in allKeys) {\n var checker = shapeTypes[key];\n if (has(shapeTypes, key) && typeof checker !== 'function') {\n return invalidValidatorError(componentName, location, propFullName, key, getPreciseType(checker));\n }\n if (!checker) {\n return new PropTypeError(\n 'Invalid ' + location + ' `' + propFullName + '` key `' + key + '` supplied to `' + componentName + '`.' +\n '\\nBad object: ' + JSON.stringify(props[propName], null, ' ') +\n '\\nValid keys: ' + JSON.stringify(Object.keys(shapeTypes), null, ' ')\n );\n }\n var error = checker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret);\n if (error) {\n return error;\n }\n }\n return null;\n }\n\n return createChainableTypeChecker(validate);\n }\n\n function isNode(propValue) {\n switch (typeof propValue) {\n case 'number':\n case 'string':\n case 'undefined':\n return true;\n case 'boolean':\n return !propValue;\n case 'object':\n if (Array.isArray(propValue)) {\n return propValue.every(isNode);\n }\n if (propValue === null || isValidElement(propValue)) {\n return true;\n }\n\n var iteratorFn = getIteratorFn(propValue);\n if (iteratorFn) {\n var iterator = iteratorFn.call(propValue);\n var step;\n if (iteratorFn !== propValue.entries) {\n while (!(step = iterator.next()).done) {\n if (!isNode(step.value)) {\n return false;\n }\n }\n } else {\n // Iterator will provide entry [k,v] tuples rather than values.\n while (!(step = iterator.next()).done) {\n var entry = step.value;\n if (entry) {\n if (!isNode(entry[1])) {\n return false;\n }\n }\n }\n }\n } else {\n return false;\n }\n\n return true;\n default:\n return false;\n }\n }\n\n function isSymbol(propType, propValue) {\n // Native Symbol.\n if (propType === 'symbol') {\n return true;\n }\n\n // falsy value can't be a Symbol\n if (!propValue) {\n return false;\n }\n\n // 19.4.3.5 Symbol.prototype[@@toStringTag] === 'Symbol'\n if (propValue['@@toStringTag'] === 'Symbol') {\n return true;\n }\n\n // Fallback for non-spec compliant Symbols which are polyfilled.\n if (typeof Symbol === 'function' && propValue instanceof Symbol) {\n return true;\n }\n\n return false;\n }\n\n // Equivalent of `typeof` but with special handling for array and regexp.\n function getPropType(propValue) {\n var propType = typeof propValue;\n if (Array.isArray(propValue)) {\n return 'array';\n }\n if (propValue instanceof RegExp) {\n // Old webkits (at least until Android 4.0) return 'function' rather than\n // 'object' for typeof a RegExp. We'll normalize this here so that /bla/\n // passes PropTypes.object.\n return 'object';\n }\n if (isSymbol(propType, propValue)) {\n return 'symbol';\n }\n return propType;\n }\n\n // This handles more types than `getPropType`. Only used for error messages.\n // See `createPrimitiveTypeChecker`.\n function getPreciseType(propValue) {\n if (typeof propValue === 'undefined' || propValue === null) {\n return '' + propValue;\n }\n var propType = getPropType(propValue);\n if (propType === 'object') {\n if (propValue instanceof Date) {\n return 'date';\n } else if (propValue instanceof RegExp) {\n return 'regexp';\n }\n }\n return propType;\n }\n\n // Returns a string that is postfixed to a warning about an invalid type.\n // For example, \"undefined\" or \"of type array\"\n function getPostfixForTypeWarning(value) {\n var type = getPreciseType(value);\n switch (type) {\n case 'array':\n case 'object':\n return 'an ' + type;\n case 'boolean':\n case 'date':\n case 'regexp':\n return 'a ' + type;\n default:\n return type;\n }\n }\n\n // Returns class name of the object, if any.\n function getClassName(propValue) {\n if (!propValue.constructor || !propValue.constructor.name) {\n return ANONYMOUS;\n }\n return propValue.constructor.name;\n }\n\n ReactPropTypes.checkPropTypes = checkPropTypes;\n ReactPropTypes.resetWarningCache = checkPropTypes.resetWarningCache;\n ReactPropTypes.PropTypes = ReactPropTypes;\n\n return ReactPropTypes;\n};\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar ReactPropTypesSecret = require('./lib/ReactPropTypesSecret');\n\nfunction emptyFunction() {}\nfunction emptyFunctionWithReset() {}\nemptyFunctionWithReset.resetWarningCache = emptyFunction;\n\nmodule.exports = function() {\n function shim(props, propName, componentName, location, propFullName, secret) {\n if (secret === ReactPropTypesSecret) {\n // It is still safe when called from React.\n return;\n }\n var err = new Error(\n 'Calling PropTypes validators directly is not supported by the `prop-types` package. ' +\n 'Use PropTypes.checkPropTypes() to call them. ' +\n 'Read more at http://fb.me/use-check-prop-types'\n );\n err.name = 'Invariant Violation';\n throw err;\n };\n shim.isRequired = shim;\n function getShim() {\n return shim;\n };\n // Important!\n // Keep this list in sync with production version in `./factoryWithTypeCheckers.js`.\n var ReactPropTypes = {\n array: shim,\n bigint: shim,\n bool: shim,\n func: shim,\n number: shim,\n object: shim,\n string: shim,\n symbol: shim,\n\n any: shim,\n arrayOf: getShim,\n element: shim,\n elementType: shim,\n instanceOf: getShim,\n node: shim,\n objectOf: getShim,\n oneOf: getShim,\n oneOfType: getShim,\n shape: getShim,\n exact: getShim,\n\n checkPropTypes: emptyFunctionWithReset,\n resetWarningCache: emptyFunction\n };\n\n ReactPropTypes.PropTypes = ReactPropTypes;\n\n return ReactPropTypes;\n};\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\nif (process.env.NODE_ENV !== 'production') {\n var ReactIs = require('react-is');\n\n // By explicitly using `prop-types` you are opting into new development behavior.\n // http://fb.me/prop-types-in-prod\n var throwOnDirectAccess = true;\n module.exports = require('./factoryWithTypeCheckers')(ReactIs.isElement, throwOnDirectAccess);\n} else {\n // By explicitly using `prop-types` you are opting into new production behavior.\n // http://fb.me/prop-types-in-prod\n module.exports = require('./factoryWithThrowingShims')();\n}\n","import PropTypes from 'prop-types';\nimport chainPropTypes from '../chainPropTypes';\nfunction isClassComponent(elementType) {\n // elementType.prototype?.isReactComponent\n const {\n prototype = {}\n } = elementType;\n return Boolean(prototype.isReactComponent);\n}\nfunction acceptingRef(props, propName, componentName, location, propFullName) {\n const element = props[propName];\n const safePropName = propFullName || propName;\n if (element == null ||\n // When server-side rendering React doesn't warn either.\n // This is not an accurate check for SSR.\n // This is only in place for Emotion compat.\n // TODO: Revisit once https://github.com/facebook/react/issues/20047 is resolved.\n typeof window === 'undefined') {\n return null;\n }\n let warningHint;\n const elementType = element.type;\n /**\n * Blacklisting instead of whitelisting\n *\n * Blacklisting will miss some components, such as React.Fragment. Those will at least\n * trigger a warning in React.\n * We can't whitelist because there is no safe way to detect React.forwardRef\n * or class components. \"Safe\" means there's no public API.\n *\n */\n if (typeof elementType === 'function' && !isClassComponent(elementType)) {\n warningHint = 'Did you accidentally use a plain function component for an element instead?';\n }\n if (warningHint !== undefined) {\n return new Error(`Invalid ${location} \\`${safePropName}\\` supplied to \\`${componentName}\\`. ` + `Expected an element that can hold a ref. ${warningHint} ` + 'For more information see https://mui.com/r/caveat-with-refs-guide');\n }\n return null;\n}\nconst elementAcceptingRef = chainPropTypes(PropTypes.element, acceptingRef);\nelementAcceptingRef.isRequired = chainPropTypes(PropTypes.element.isRequired, acceptingRef);\nexport default elementAcceptingRef;","import _extends from \"@babel/runtime/helpers/esm/extends\";\n// This module is based on https://github.com/airbnb/prop-types-exact repository.\n// However, in order to reduce the number of dependencies and to remove some extra safe checks\n// the module was forked.\n\nconst specialProperty = 'exact-prop: \\u200b';\nexport default function exactProp(propTypes) {\n if (process.env.NODE_ENV === 'production') {\n return propTypes;\n }\n return _extends({}, propTypes, {\n [specialProperty]: props => {\n const unsupportedProps = Object.keys(props).filter(prop => !propTypes.hasOwnProperty(prop));\n if (unsupportedProps.length > 0) {\n return new Error(`The following props are not supported: ${unsupportedProps.map(prop => `\\`${prop}\\``).join(', ')}. Please remove them.`);\n }\n return null;\n }\n });\n}","/**\n * WARNING: Don't import this directly.\n * Use `MuiError` from `@mui/internal-babel-macros/MuiError.macro` instead.\n * @param {number} code\n */\nexport default function formatMuiErrorMessage(code) {\n // Apply babel-plugin-transform-template-literals in loose mode\n // loose mode is safe if we're concatenating primitives\n // see https://babeljs.io/docs/en/babel-plugin-transform-template-literals#loose\n /* eslint-disable prefer-template */\n let url = 'https://mui.com/production-error/?code=' + code;\n for (let i = 1; i < arguments.length; i += 1) {\n // rest params over-transpile for this case\n // eslint-disable-next-line prefer-rest-params\n url += '&args[]=' + encodeURIComponent(arguments[i]);\n }\n return 'Minified MUI error #' + code + '; visit ' + url + ' for the full message.';\n /* eslint-enable prefer-template */\n}","/**\n * @license React\n * react-is.production.min.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n'use strict';var b=Symbol.for(\"react.element\"),c=Symbol.for(\"react.portal\"),d=Symbol.for(\"react.fragment\"),e=Symbol.for(\"react.strict_mode\"),f=Symbol.for(\"react.profiler\"),g=Symbol.for(\"react.provider\"),h=Symbol.for(\"react.context\"),k=Symbol.for(\"react.server_context\"),l=Symbol.for(\"react.forward_ref\"),m=Symbol.for(\"react.suspense\"),n=Symbol.for(\"react.suspense_list\"),p=Symbol.for(\"react.memo\"),q=Symbol.for(\"react.lazy\"),t=Symbol.for(\"react.offscreen\"),u;u=Symbol.for(\"react.module.reference\");\nfunction v(a){if(\"object\"===typeof a&&null!==a){var r=a.$$typeof;switch(r){case b:switch(a=a.type,a){case d:case f:case e:case m:case n:return a;default:switch(a=a&&a.$$typeof,a){case k:case h:case l:case q:case p:case g:return a;default:return r}}case c:return r}}}exports.ContextConsumer=h;exports.ContextProvider=g;exports.Element=b;exports.ForwardRef=l;exports.Fragment=d;exports.Lazy=q;exports.Memo=p;exports.Portal=c;exports.Profiler=f;exports.StrictMode=e;exports.Suspense=m;\nexports.SuspenseList=n;exports.isAsyncMode=function(){return!1};exports.isConcurrentMode=function(){return!1};exports.isContextConsumer=function(a){return v(a)===h};exports.isContextProvider=function(a){return v(a)===g};exports.isElement=function(a){return\"object\"===typeof a&&null!==a&&a.$$typeof===b};exports.isForwardRef=function(a){return v(a)===l};exports.isFragment=function(a){return v(a)===d};exports.isLazy=function(a){return v(a)===q};exports.isMemo=function(a){return v(a)===p};\nexports.isPortal=function(a){return v(a)===c};exports.isProfiler=function(a){return v(a)===f};exports.isStrictMode=function(a){return v(a)===e};exports.isSuspense=function(a){return v(a)===m};exports.isSuspenseList=function(a){return v(a)===n};\nexports.isValidElementType=function(a){return\"string\"===typeof a||\"function\"===typeof a||a===d||a===f||a===e||a===m||a===n||a===t||\"object\"===typeof a&&null!==a&&(a.$$typeof===q||a.$$typeof===p||a.$$typeof===g||a.$$typeof===h||a.$$typeof===l||a.$$typeof===u||void 0!==a.getModuleId)?!0:!1};exports.typeOf=v;\n","/**\n * @license React\n * react-is.development.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nif (process.env.NODE_ENV !== \"production\") {\n (function() {\n'use strict';\n\n// ATTENTION\n// When adding new symbols to this file,\n// Please consider also adding to 'react-devtools-shared/src/backend/ReactSymbols'\n// The Symbol used to tag the ReactElement-like types.\nvar REACT_ELEMENT_TYPE = Symbol.for('react.element');\nvar REACT_PORTAL_TYPE = Symbol.for('react.portal');\nvar REACT_FRAGMENT_TYPE = Symbol.for('react.fragment');\nvar REACT_STRICT_MODE_TYPE = Symbol.for('react.strict_mode');\nvar REACT_PROFILER_TYPE = Symbol.for('react.profiler');\nvar REACT_PROVIDER_TYPE = Symbol.for('react.provider');\nvar REACT_CONTEXT_TYPE = Symbol.for('react.context');\nvar REACT_SERVER_CONTEXT_TYPE = Symbol.for('react.server_context');\nvar REACT_FORWARD_REF_TYPE = Symbol.for('react.forward_ref');\nvar REACT_SUSPENSE_TYPE = Symbol.for('react.suspense');\nvar REACT_SUSPENSE_LIST_TYPE = Symbol.for('react.suspense_list');\nvar REACT_MEMO_TYPE = Symbol.for('react.memo');\nvar REACT_LAZY_TYPE = Symbol.for('react.lazy');\nvar REACT_OFFSCREEN_TYPE = Symbol.for('react.offscreen');\n\n// -----------------------------------------------------------------------------\n\nvar enableScopeAPI = false; // Experimental Create Event Handle API.\nvar enableCacheElement = false;\nvar enableTransitionTracing = false; // No known bugs, but needs performance testing\n\nvar enableLegacyHidden = false; // Enables unstable_avoidThisFallback feature in Fiber\n// stuff. Intended to enable React core members to more easily debug scheduling\n// issues in DEV builds.\n\nvar enableDebugTracing = false; // Track which Fiber(s) schedule render work.\n\nvar REACT_MODULE_REFERENCE;\n\n{\n REACT_MODULE_REFERENCE = Symbol.for('react.module.reference');\n}\n\nfunction isValidElementType(type) {\n if (typeof type === 'string' || typeof type === 'function') {\n return true;\n } // Note: typeof might be other than 'symbol' or 'number' (e.g. if it's a polyfill).\n\n\n if (type === REACT_FRAGMENT_TYPE || type === REACT_PROFILER_TYPE || enableDebugTracing || type === REACT_STRICT_MODE_TYPE || type === REACT_SUSPENSE_TYPE || type === REACT_SUSPENSE_LIST_TYPE || enableLegacyHidden || type === REACT_OFFSCREEN_TYPE || enableScopeAPI || enableCacheElement || enableTransitionTracing ) {\n return true;\n }\n\n if (typeof type === 'object' && type !== null) {\n if (type.$$typeof === REACT_LAZY_TYPE || type.$$typeof === REACT_MEMO_TYPE || type.$$typeof === REACT_PROVIDER_TYPE || type.$$typeof === REACT_CONTEXT_TYPE || type.$$typeof === REACT_FORWARD_REF_TYPE || // This needs to include all possible module reference object\n // types supported by any Flight configuration anywhere since\n // we don't know which Flight build this will end up being used\n // with.\n type.$$typeof === REACT_MODULE_REFERENCE || type.getModuleId !== undefined) {\n return true;\n }\n }\n\n return false;\n}\n\nfunction typeOf(object) {\n if (typeof object === 'object' && object !== null) {\n var $$typeof = object.$$typeof;\n\n switch ($$typeof) {\n case REACT_ELEMENT_TYPE:\n var type = object.type;\n\n switch (type) {\n case REACT_FRAGMENT_TYPE:\n case REACT_PROFILER_TYPE:\n case REACT_STRICT_MODE_TYPE:\n case REACT_SUSPENSE_TYPE:\n case REACT_SUSPENSE_LIST_TYPE:\n return type;\n\n default:\n var $$typeofType = type && type.$$typeof;\n\n switch ($$typeofType) {\n case REACT_SERVER_CONTEXT_TYPE:\n case REACT_CONTEXT_TYPE:\n case REACT_FORWARD_REF_TYPE:\n case REACT_LAZY_TYPE:\n case REACT_MEMO_TYPE:\n case REACT_PROVIDER_TYPE:\n return $$typeofType;\n\n default:\n return $$typeof;\n }\n\n }\n\n case REACT_PORTAL_TYPE:\n return $$typeof;\n }\n }\n\n return undefined;\n}\nvar ContextConsumer = REACT_CONTEXT_TYPE;\nvar ContextProvider = REACT_PROVIDER_TYPE;\nvar Element = REACT_ELEMENT_TYPE;\nvar ForwardRef = REACT_FORWARD_REF_TYPE;\nvar Fragment = REACT_FRAGMENT_TYPE;\nvar Lazy = REACT_LAZY_TYPE;\nvar Memo = REACT_MEMO_TYPE;\nvar Portal = REACT_PORTAL_TYPE;\nvar Profiler = REACT_PROFILER_TYPE;\nvar StrictMode = REACT_STRICT_MODE_TYPE;\nvar Suspense = REACT_SUSPENSE_TYPE;\nvar SuspenseList = REACT_SUSPENSE_LIST_TYPE;\nvar hasWarnedAboutDeprecatedIsAsyncMode = false;\nvar hasWarnedAboutDeprecatedIsConcurrentMode = false; // AsyncMode should be deprecated\n\nfunction isAsyncMode(object) {\n {\n if (!hasWarnedAboutDeprecatedIsAsyncMode) {\n hasWarnedAboutDeprecatedIsAsyncMode = true; // Using console['warn'] to evade Babel and ESLint\n\n console['warn']('The ReactIs.isAsyncMode() alias has been deprecated, ' + 'and will be removed in React 18+.');\n }\n }\n\n return false;\n}\nfunction isConcurrentMode(object) {\n {\n if (!hasWarnedAboutDeprecatedIsConcurrentMode) {\n hasWarnedAboutDeprecatedIsConcurrentMode = true; // Using console['warn'] to evade Babel and ESLint\n\n console['warn']('The ReactIs.isConcurrentMode() alias has been deprecated, ' + 'and will be removed in React 18+.');\n }\n }\n\n return false;\n}\nfunction isContextConsumer(object) {\n return typeOf(object) === REACT_CONTEXT_TYPE;\n}\nfunction isContextProvider(object) {\n return typeOf(object) === REACT_PROVIDER_TYPE;\n}\nfunction isElement(object) {\n return typeof object === 'object' && object !== null && object.$$typeof === REACT_ELEMENT_TYPE;\n}\nfunction isForwardRef(object) {\n return typeOf(object) === REACT_FORWARD_REF_TYPE;\n}\nfunction isFragment(object) {\n return typeOf(object) === REACT_FRAGMENT_TYPE;\n}\nfunction isLazy(object) {\n return typeOf(object) === REACT_LAZY_TYPE;\n}\nfunction isMemo(object) {\n return typeOf(object) === REACT_MEMO_TYPE;\n}\nfunction isPortal(object) {\n return typeOf(object) === REACT_PORTAL_TYPE;\n}\nfunction isProfiler(object) {\n return typeOf(object) === REACT_PROFILER_TYPE;\n}\nfunction isStrictMode(object) {\n return typeOf(object) === REACT_STRICT_MODE_TYPE;\n}\nfunction isSuspense(object) {\n return typeOf(object) === REACT_SUSPENSE_TYPE;\n}\nfunction isSuspenseList(object) {\n return typeOf(object) === REACT_SUSPENSE_LIST_TYPE;\n}\n\nexports.ContextConsumer = ContextConsumer;\nexports.ContextProvider = ContextProvider;\nexports.Element = Element;\nexports.ForwardRef = ForwardRef;\nexports.Fragment = Fragment;\nexports.Lazy = Lazy;\nexports.Memo = Memo;\nexports.Portal = Portal;\nexports.Profiler = Profiler;\nexports.StrictMode = StrictMode;\nexports.Suspense = Suspense;\nexports.SuspenseList = SuspenseList;\nexports.isAsyncMode = isAsyncMode;\nexports.isConcurrentMode = isConcurrentMode;\nexports.isContextConsumer = isContextConsumer;\nexports.isContextProvider = isContextProvider;\nexports.isElement = isElement;\nexports.isForwardRef = isForwardRef;\nexports.isFragment = isFragment;\nexports.isLazy = isLazy;\nexports.isMemo = isMemo;\nexports.isPortal = isPortal;\nexports.isProfiler = isProfiler;\nexports.isStrictMode = isStrictMode;\nexports.isSuspense = isSuspense;\nexports.isSuspenseList = isSuspenseList;\nexports.isValidElementType = isValidElementType;\nexports.typeOf = typeOf;\n })();\n}\n","'use strict';\n\nif (process.env.NODE_ENV === 'production') {\n module.exports = require('./cjs/react-is.production.min.js');\n} else {\n module.exports = require('./cjs/react-is.development.js');\n}\n","import { ForwardRef, Memo } from 'react-is';\n\n// Simplified polyfill for IE11 support\n// https://github.com/JamesMGreene/Function.name/blob/58b314d4a983110c3682f1228f845d39ccca1817/Function.name.js#L3\nconst fnNameMatchRegex = /^\\s*function(?:\\s|\\s*\\/\\*.*\\*\\/\\s*)+([^(\\s/]*)\\s*/;\nexport function getFunctionName(fn) {\n const match = `${fn}`.match(fnNameMatchRegex);\n const name = match && match[1];\n return name || '';\n}\nfunction getFunctionComponentName(Component, fallback = '') {\n return Component.displayName || Component.name || getFunctionName(Component) || fallback;\n}\nfunction getWrappedName(outerType, innerType, wrapperName) {\n const functionName = getFunctionComponentName(innerType);\n return outerType.displayName || (functionName !== '' ? `${wrapperName}(${functionName})` : wrapperName);\n}\n\n/**\n * cherry-pick from\n * https://github.com/facebook/react/blob/769b1f270e1251d9dbdce0fcbd9e92e502d059b8/packages/shared/getComponentName.js\n * originally forked from recompose/getDisplayName with added IE11 support\n */\nexport default function getDisplayName(Component) {\n if (Component == null) {\n return undefined;\n }\n if (typeof Component === 'string') {\n return Component;\n }\n if (typeof Component === 'function') {\n return getFunctionComponentName(Component, 'Component');\n }\n\n // TypeScript can't have components as objects but they exist in the form of `memo` or `Suspense`\n if (typeof Component === 'object') {\n switch (Component.$$typeof) {\n case ForwardRef:\n return getWrappedName(Component, Component.render, 'ForwardRef');\n case Memo:\n return getWrappedName(Component, Component.type, 'memo');\n default:\n return undefined;\n }\n }\n return undefined;\n}","export default function HTMLElementType(props, propName, componentName, location, propFullName) {\n if (process.env.NODE_ENV === 'production') {\n return null;\n }\n const propValue = props[propName];\n const safePropName = propFullName || propName;\n if (propValue == null) {\n return null;\n }\n if (propValue && propValue.nodeType !== 1) {\n return new Error(`Invalid ${location} \\`${safePropName}\\` supplied to \\`${componentName}\\`. ` + `Expected an HTMLElement.`);\n }\n return null;\n}","import PropTypes from 'prop-types';\nconst refType = PropTypes.oneOfType([PropTypes.func, PropTypes.object]);\nexport default refType;","import _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\n// It should to be noted that this function isn't equivalent to `text-transform: capitalize`.\n//\n// A strict capitalization should uppercase the first letter of each word in the sentence.\n// We only handle the first word.\nexport default function capitalize(string) {\n if (typeof string !== 'string') {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: \\`capitalize(string)\\` expects a string argument.` : _formatMuiErrorMessage(7));\n }\n return string.charAt(0).toUpperCase() + string.slice(1);\n}","/**\n * Safe chained function.\n *\n * Will only create a new function if needed,\n * otherwise will pass back existing functions or null.\n */\nexport default function createChainedFunction(...funcs) {\n return funcs.reduce((acc, func) => {\n if (func == null) {\n return acc;\n }\n return function chainedFunction(...args) {\n acc.apply(this, args);\n func.apply(this, args);\n };\n }, () => {});\n}","// Corresponds to 10 frames at 60 Hz.\n// A few bytes payload overhead when lodash/debounce is ~3 kB and debounce ~300 B.\nexport default function debounce(func, wait = 166) {\n let timeout;\n function debounced(...args) {\n const later = () => {\n // @ts-ignore\n func.apply(this, args);\n };\n clearTimeout(timeout);\n timeout = setTimeout(later, wait);\n }\n debounced.clear = () => {\n clearTimeout(timeout);\n };\n return debounced;\n}","export default function deprecatedPropType(validator, reason) {\n if (process.env.NODE_ENV === 'production') {\n return () => null;\n }\n return (props, propName, componentName, location, propFullName) => {\n const componentNameSafe = componentName || '<>';\n const propFullNameSafe = propFullName || propName;\n if (typeof props[propName] !== 'undefined') {\n return new Error(`The ${location} \\`${propFullNameSafe}\\` of ` + `\\`${componentNameSafe}\\` is deprecated. ${reason}`);\n }\n return null;\n };\n}","import * as React from 'react';\nexport default function isMuiElement(element, muiNames) {\n var _muiName, _element$type;\n return /*#__PURE__*/React.isValidElement(element) && muiNames.indexOf( // For server components `muiName` is avaialble in element.type._payload.value.muiName\n // relevant info - https://github.com/facebook/react/blob/2807d781a08db8e9873687fccc25c0f12b4fb3d4/packages/react/src/ReactLazy.js#L45\n // eslint-disable-next-line no-underscore-dangle\n (_muiName = element.type.muiName) != null ? _muiName : (_element$type = element.type) == null || (_element$type = _element$type._payload) == null || (_element$type = _element$type.value) == null ? void 0 : _element$type.muiName) !== -1;\n}","export default function ownerDocument(node) {\n return node && node.ownerDocument || document;\n}","import ownerDocument from '../ownerDocument';\nexport default function ownerWindow(node) {\n const doc = ownerDocument(node);\n return doc.defaultView || window;\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nexport default function requirePropFactory(componentNameInError, Component) {\n if (process.env.NODE_ENV === 'production') {\n return () => null;\n }\n\n // eslint-disable-next-line react/forbid-foreign-prop-types\n const prevPropTypes = Component ? _extends({}, Component.propTypes) : null;\n const requireProp = requiredProp => (props, propName, componentName, location, propFullName, ...args) => {\n const propFullNameSafe = propFullName || propName;\n const defaultTypeChecker = prevPropTypes == null ? void 0 : prevPropTypes[propFullNameSafe];\n if (defaultTypeChecker) {\n const typeCheckerResult = defaultTypeChecker(props, propName, componentName, location, propFullName, ...args);\n if (typeCheckerResult) {\n return typeCheckerResult;\n }\n }\n if (typeof props[propName] !== 'undefined' && !props[requiredProp]) {\n return new Error(`The prop \\`${propFullNameSafe}\\` of ` + `\\`${componentNameInError}\\` can only be used together with the \\`${requiredProp}\\` prop.`);\n }\n return null;\n };\n return requireProp;\n}","/**\n * TODO v5: consider making it private\n *\n * passes {value} to {ref}\n *\n * WARNING: Be sure to only call this inside a callback that is passed as a ref.\n * Otherwise, make sure to cleanup the previous {ref} if it changes. See\n * https://github.com/mui/material-ui/issues/13539\n *\n * Useful if you want to expose the ref of an inner component to the public API\n * while still using it inside the component.\n * @param ref A ref callback or ref object. If anything falsy, this is a no-op.\n */\nexport default function setRef(ref, value) {\n if (typeof ref === 'function') {\n ref(value);\n } else if (ref) {\n ref.current = value;\n }\n}","'use client';\n\nimport * as React from 'react';\n\n/**\n * A version of `React.useLayoutEffect` that does not show a warning when server-side rendering.\n * This is useful for effects that are only needed for client-side rendering but not for SSR.\n *\n * Before you use this hook, make sure to read https://gist.github.com/gaearon/e7d97cdf38a2907924ea12e4ebdf3c85\n * and confirm it doesn't apply to your use-case.\n */\nconst useEnhancedEffect = typeof window !== 'undefined' ? React.useLayoutEffect : React.useEffect;\nexport default useEnhancedEffect;","'use client';\n\nimport * as React from 'react';\nlet globalId = 0;\nfunction useGlobalId(idOverride) {\n const [defaultId, setDefaultId] = React.useState(idOverride);\n const id = idOverride || defaultId;\n React.useEffect(() => {\n if (defaultId == null) {\n // Fallback to this default id when possible.\n // Use the incrementing value for client-side rendering only.\n // We can't use it server-side.\n // If you want to use random values please consider the Birthday Problem: https://en.wikipedia.org/wiki/Birthday_problem\n globalId += 1;\n setDefaultId(`mui-${globalId}`);\n }\n }, [defaultId]);\n return id;\n}\n\n// downstream bundlers may remove unnecessary concatenation, but won't remove toString call -- Workaround for https://github.com/webpack/webpack/issues/14814\nconst maybeReactUseId = React['useId'.toString()];\n/**\n *\n * @example
    \n * @param idOverride\n * @returns {string}\n */\nexport default function useId(idOverride) {\n if (maybeReactUseId !== undefined) {\n const reactId = maybeReactUseId();\n return idOverride != null ? idOverride : reactId;\n }\n // eslint-disable-next-line react-hooks/rules-of-hooks -- `React.useId` is invariant at runtime.\n return useGlobalId(idOverride);\n}","export default function unsupportedProp(props, propName, componentName, location, propFullName) {\n if (process.env.NODE_ENV === 'production') {\n return null;\n }\n const propFullNameSafe = propFullName || propName;\n if (typeof props[propName] !== 'undefined') {\n return new Error(`The prop \\`${propFullNameSafe}\\` is not supported. Please remove it.`);\n }\n return null;\n}","'use client';\n\n/* eslint-disable react-hooks/rules-of-hooks, react-hooks/exhaustive-deps */\nimport * as React from 'react';\nexport default function useControlled({\n controlled,\n default: defaultProp,\n name,\n state = 'value'\n}) {\n // isControlled is ignored in the hook dependency lists as it should never change.\n const {\n current: isControlled\n } = React.useRef(controlled !== undefined);\n const [valueState, setValue] = React.useState(defaultProp);\n const value = isControlled ? controlled : valueState;\n if (process.env.NODE_ENV !== 'production') {\n React.useEffect(() => {\n if (isControlled !== (controlled !== undefined)) {\n console.error([`MUI: A component is changing the ${isControlled ? '' : 'un'}controlled ${state} state of ${name} to be ${isControlled ? 'un' : ''}controlled.`, 'Elements should not switch from uncontrolled to controlled (or vice versa).', `Decide between using a controlled or uncontrolled ${name} ` + 'element for the lifetime of the component.', \"The nature of the state is determined during the first render. It's considered controlled if the value is not `undefined`.\", 'More info: https://fb.me/react-controlled-components'].join('\\n'));\n }\n }, [state, name, controlled]);\n const {\n current: defaultValue\n } = React.useRef(defaultProp);\n React.useEffect(() => {\n if (!isControlled && defaultValue !== defaultProp) {\n console.error([`MUI: A component is changing the default ${state} state of an uncontrolled ${name} after being initialized. ` + `To suppress this warning opt to use a controlled ${name}.`].join('\\n'));\n }\n }, [JSON.stringify(defaultProp)]);\n }\n const setValueIfUncontrolled = React.useCallback(newValue => {\n if (!isControlled) {\n setValue(newValue);\n }\n }, []);\n return [value, setValueIfUncontrolled];\n}","'use client';\n\nimport * as React from 'react';\nimport useEnhancedEffect from '../useEnhancedEffect';\n\n/**\n * Inspired by https://github.com/facebook/react/issues/14099#issuecomment-440013892\n * See RFC in https://github.com/reactjs/rfcs/pull/220\n */\n\nfunction useEventCallback(fn) {\n const ref = React.useRef(fn);\n useEnhancedEffect(() => {\n ref.current = fn;\n });\n return React.useRef((...args) =>\n // @ts-expect-error hide `this`\n (0, ref.current)(...args)).current;\n}\nexport default useEventCallback;","'use client';\n\nimport * as React from 'react';\nimport setRef from '../setRef';\nexport default function useForkRef(...refs) {\n /**\n * This will create a new function if the refs passed to this hook change and are all defined.\n * This means react will call the old forkRef with `null` and the new forkRef\n * with the ref. Cleanup naturally emerges from this behavior.\n */\n return React.useMemo(() => {\n if (refs.every(ref => ref == null)) {\n return null;\n }\n return instance => {\n refs.forEach(ref => {\n setRef(ref, instance);\n });\n };\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, refs);\n}","'use client';\n\nimport * as React from 'react';\nconst UNINITIALIZED = {};\n\n/**\n * A React.useRef() that is initialized lazily with a function. Note that it accepts an optional\n * initialization argument, so the initialization function doesn't need to be an inline closure.\n *\n * @usage\n * const ref = useLazyRef(sortColumns, columns)\n */\nexport default function useLazyRef(init, initArg) {\n const ref = React.useRef(UNINITIALIZED);\n if (ref.current === UNINITIALIZED) {\n ref.current = init(initArg);\n }\n return ref;\n}","'use client';\n\nimport * as React from 'react';\nconst EMPTY = [];\n\n/**\n * A React.useEffect equivalent that runs once, when the component is mounted.\n */\nexport default function useOnMount(fn) {\n /* eslint-disable react-hooks/exhaustive-deps */\n React.useEffect(fn, EMPTY);\n /* eslint-enable react-hooks/exhaustive-deps */\n}","'use client';\n\nimport useLazyRef from '../useLazyRef/useLazyRef';\nimport useOnMount from '../useOnMount/useOnMount';\nexport class Timeout {\n constructor() {\n this.currentId = null;\n this.clear = () => {\n if (this.currentId !== null) {\n clearTimeout(this.currentId);\n this.currentId = null;\n }\n };\n this.disposeEffect = () => {\n return this.clear;\n };\n }\n static create() {\n return new Timeout();\n }\n /**\n * Executes `fn` after `delay`, clearing any previously scheduled call.\n */\n start(delay, fn) {\n this.clear();\n this.currentId = setTimeout(() => {\n this.currentId = null;\n fn();\n }, delay);\n }\n}\nexport default function useTimeout() {\n const timeout = useLazyRef(Timeout.create).current;\n useOnMount(timeout.disposeEffect);\n return timeout;\n}","'use client';\n\n// based on https://github.com/WICG/focus-visible/blob/v4.1.5/src/focus-visible.js\nimport * as React from 'react';\nimport { Timeout } from '../useTimeout/useTimeout';\nlet hadKeyboardEvent = true;\nlet hadFocusVisibleRecently = false;\nconst hadFocusVisibleRecentlyTimeout = new Timeout();\nconst inputTypesWhitelist = {\n text: true,\n search: true,\n url: true,\n tel: true,\n email: true,\n password: true,\n number: true,\n date: true,\n month: true,\n week: true,\n time: true,\n datetime: true,\n 'datetime-local': true\n};\n\n/**\n * Computes whether the given element should automatically trigger the\n * `focus-visible` class being added, i.e. whether it should always match\n * `:focus-visible` when focused.\n * @param {Element} node\n * @returns {boolean}\n */\nfunction focusTriggersKeyboardModality(node) {\n const {\n type,\n tagName\n } = node;\n if (tagName === 'INPUT' && inputTypesWhitelist[type] && !node.readOnly) {\n return true;\n }\n if (tagName === 'TEXTAREA' && !node.readOnly) {\n return true;\n }\n if (node.isContentEditable) {\n return true;\n }\n return false;\n}\n\n/**\n * Keep track of our keyboard modality state with `hadKeyboardEvent`.\n * If the most recent user interaction was via the keyboard;\n * and the key press did not include a meta, alt/option, or control key;\n * then the modality is keyboard. Otherwise, the modality is not keyboard.\n * @param {KeyboardEvent} event\n */\nfunction handleKeyDown(event) {\n if (event.metaKey || event.altKey || event.ctrlKey) {\n return;\n }\n hadKeyboardEvent = true;\n}\n\n/**\n * If at any point a user clicks with a pointing device, ensure that we change\n * the modality away from keyboard.\n * This avoids the situation where a user presses a key on an already focused\n * element, and then clicks on a different element, focusing it with a\n * pointing device, while we still think we're in keyboard modality.\n */\nfunction handlePointerDown() {\n hadKeyboardEvent = false;\n}\nfunction handleVisibilityChange() {\n if (this.visibilityState === 'hidden') {\n // If the tab becomes active again, the browser will handle calling focus\n // on the element (Safari actually calls it twice).\n // If this tab change caused a blur on an element with focus-visible,\n // re-apply the class when the user switches back to the tab.\n if (hadFocusVisibleRecently) {\n hadKeyboardEvent = true;\n }\n }\n}\nfunction prepare(doc) {\n doc.addEventListener('keydown', handleKeyDown, true);\n doc.addEventListener('mousedown', handlePointerDown, true);\n doc.addEventListener('pointerdown', handlePointerDown, true);\n doc.addEventListener('touchstart', handlePointerDown, true);\n doc.addEventListener('visibilitychange', handleVisibilityChange, true);\n}\nexport function teardown(doc) {\n doc.removeEventListener('keydown', handleKeyDown, true);\n doc.removeEventListener('mousedown', handlePointerDown, true);\n doc.removeEventListener('pointerdown', handlePointerDown, true);\n doc.removeEventListener('touchstart', handlePointerDown, true);\n doc.removeEventListener('visibilitychange', handleVisibilityChange, true);\n}\nfunction isFocusVisible(event) {\n const {\n target\n } = event;\n try {\n return target.matches(':focus-visible');\n } catch (error) {\n // Browsers not implementing :focus-visible will throw a SyntaxError.\n // We use our own heuristic for those browsers.\n // Rethrow might be better if it's not the expected error but do we really\n // want to crash if focus-visible malfunctioned?\n }\n\n // No need for validFocusTarget check. The user does that by attaching it to\n // focusable events only.\n return hadKeyboardEvent || focusTriggersKeyboardModality(target);\n}\nexport default function useIsFocusVisible() {\n const ref = React.useCallback(node => {\n if (node != null) {\n prepare(node.ownerDocument);\n }\n }, []);\n const isFocusVisibleRef = React.useRef(false);\n\n /**\n * Should be called if a blur event is fired\n */\n function handleBlurVisible() {\n // checking against potential state variable does not suffice if we focus and blur synchronously.\n // React wouldn't have time to trigger a re-render so `focusVisible` would be stale.\n // Ideally we would adjust `isFocusVisible(event)` to look at `relatedTarget` for blur events.\n // This doesn't work in IE11 due to https://github.com/facebook/react/issues/3751\n // TODO: check again if React releases their internal changes to focus event handling (https://github.com/facebook/react/pull/19186).\n if (isFocusVisibleRef.current) {\n // To detect a tab/window switch, we look for a blur event followed\n // rapidly by a visibility change.\n // If we don't see a visibility change within 100ms, it's probably a\n // regular focus change.\n hadFocusVisibleRecently = true;\n hadFocusVisibleRecentlyTimeout.start(100, () => {\n hadFocusVisibleRecently = false;\n });\n isFocusVisibleRef.current = false;\n return true;\n }\n return false;\n }\n\n /**\n * Should be called if a blur event is fired\n */\n function handleFocusVisible(event) {\n if (isFocusVisible(event)) {\n isFocusVisibleRef.current = true;\n return true;\n }\n return false;\n }\n return {\n isFocusVisibleRef,\n onFocus: handleFocusVisible,\n onBlur: handleBlurVisible,\n ref\n };\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\n/**\n * Add keys, values of `defaultProps` that does not exist in `props`\n * @param {object} defaultProps\n * @param {object} props\n * @returns {object} resolved props\n */\nexport default function resolveProps(defaultProps, props) {\n const output = _extends({}, props);\n Object.keys(defaultProps).forEach(propName => {\n if (propName.toString().match(/^(components|slots)$/)) {\n output[propName] = _extends({}, defaultProps[propName], output[propName]);\n } else if (propName.toString().match(/^(componentsProps|slotProps)$/)) {\n const defaultSlotProps = defaultProps[propName] || {};\n const slotProps = props[propName];\n output[propName] = {};\n if (!slotProps || !Object.keys(slotProps)) {\n // Reduce the iteration if the slot props is empty\n output[propName] = defaultSlotProps;\n } else if (!defaultSlotProps || !Object.keys(defaultSlotProps)) {\n // Reduce the iteration if the default slot props is empty\n output[propName] = slotProps;\n } else {\n output[propName] = _extends({}, slotProps);\n Object.keys(defaultSlotProps).forEach(slotPropName => {\n output[propName][slotPropName] = resolveProps(defaultSlotProps[slotPropName], slotProps[slotPropName]);\n });\n }\n } else if (output[propName] === undefined) {\n output[propName] = defaultProps[propName];\n }\n });\n return output;\n}","export default function composeClasses(slots, getUtilityClass, classes = undefined) {\n const output = {};\n Object.keys(slots).forEach(\n // `Object.keys(slots)` can't be wider than `T` because we infer `T` from `slots`.\n // @ts-expect-error https://github.com/microsoft/TypeScript/pull/12253#issuecomment-263132208\n slot => {\n output[slot] = slots[slot].reduce((acc, key) => {\n if (key) {\n const utilityClass = getUtilityClass(key);\n if (utilityClass !== '') {\n acc.push(utilityClass);\n }\n if (classes && classes[key]) {\n acc.push(classes[key]);\n }\n }\n return acc;\n }, []).join(' ');\n });\n return output;\n}","const defaultGenerator = componentName => componentName;\nconst createClassNameGenerator = () => {\n let generate = defaultGenerator;\n return {\n configure(generator) {\n generate = generator;\n },\n generate(componentName) {\n return generate(componentName);\n },\n reset() {\n generate = defaultGenerator;\n }\n };\n};\nconst ClassNameGenerator = createClassNameGenerator();\nexport default ClassNameGenerator;","import ClassNameGenerator from '../ClassNameGenerator';\nexport const globalStateClasses = {\n active: 'active',\n checked: 'checked',\n completed: 'completed',\n disabled: 'disabled',\n error: 'error',\n expanded: 'expanded',\n focused: 'focused',\n focusVisible: 'focusVisible',\n open: 'open',\n readOnly: 'readOnly',\n required: 'required',\n selected: 'selected'\n};\nexport default function generateUtilityClass(componentName, slot, globalStatePrefix = 'Mui') {\n const globalStateClass = globalStateClasses[slot];\n return globalStateClass ? `${globalStatePrefix}-${globalStateClass}` : `${ClassNameGenerator.generate(componentName)}-${slot}`;\n}\nexport function isGlobalState(slot) {\n return globalStateClasses[slot] !== undefined;\n}","import generateUtilityClass from '../generateUtilityClass';\nexport default function generateUtilityClasses(componentName, slots, globalStatePrefix = 'Mui') {\n const result = {};\n slots.forEach(slot => {\n result[slot] = generateUtilityClass(componentName, slot, globalStatePrefix);\n });\n return result;\n}","function clamp(val, min = Number.MIN_SAFE_INTEGER, max = Number.MAX_SAFE_INTEGER) {\n return Math.max(min, Math.min(val, max));\n}\nexport default clamp;","export default function _objectWithoutPropertiesLoose(source, excluded) {\n if (source == null) return {};\n var target = {};\n var sourceKeys = Object.keys(source);\n var key, i;\n for (i = 0; i < sourceKeys.length; i++) {\n key = sourceKeys[i];\n if (excluded.indexOf(key) >= 0) continue;\n target[key] = source[key];\n }\n return target;\n}","import _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nconst _excluded = [\"values\", \"unit\", \"step\"];\n// Sorted ASC by size. That's important.\n// It can't be configured as it's used statically for propTypes.\nexport const breakpointKeys = ['xs', 'sm', 'md', 'lg', 'xl'];\nconst sortBreakpointsValues = values => {\n const breakpointsAsArray = Object.keys(values).map(key => ({\n key,\n val: values[key]\n })) || [];\n // Sort in ascending order\n breakpointsAsArray.sort((breakpoint1, breakpoint2) => breakpoint1.val - breakpoint2.val);\n return breakpointsAsArray.reduce((acc, obj) => {\n return _extends({}, acc, {\n [obj.key]: obj.val\n });\n }, {});\n};\n\n// Keep in mind that @media is inclusive by the CSS specification.\nexport default function createBreakpoints(breakpoints) {\n const {\n // The breakpoint **start** at this value.\n // For instance with the first breakpoint xs: [xs, sm).\n values = {\n xs: 0,\n // phone\n sm: 600,\n // tablet\n md: 900,\n // small laptop\n lg: 1200,\n // desktop\n xl: 1536 // large screen\n },\n unit = 'px',\n step = 5\n } = breakpoints,\n other = _objectWithoutPropertiesLoose(breakpoints, _excluded);\n const sortedValues = sortBreakpointsValues(values);\n const keys = Object.keys(sortedValues);\n function up(key) {\n const value = typeof values[key] === 'number' ? values[key] : key;\n return `@media (min-width:${value}${unit})`;\n }\n function down(key) {\n const value = typeof values[key] === 'number' ? values[key] : key;\n return `@media (max-width:${value - step / 100}${unit})`;\n }\n function between(start, end) {\n const endIndex = keys.indexOf(end);\n return `@media (min-width:${typeof values[start] === 'number' ? values[start] : start}${unit}) and ` + `(max-width:${(endIndex !== -1 && typeof values[keys[endIndex]] === 'number' ? values[keys[endIndex]] : end) - step / 100}${unit})`;\n }\n function only(key) {\n if (keys.indexOf(key) + 1 < keys.length) {\n return between(key, keys[keys.indexOf(key) + 1]);\n }\n return up(key);\n }\n function not(key) {\n // handle first and last key separately, for better readability\n const keyIndex = keys.indexOf(key);\n if (keyIndex === 0) {\n return up(keys[1]);\n }\n if (keyIndex === keys.length - 1) {\n return down(keys[keyIndex]);\n }\n return between(key, keys[keys.indexOf(key) + 1]).replace('@media', '@media not all and');\n }\n return _extends({\n keys,\n values: sortedValues,\n up,\n down,\n between,\n only,\n not,\n unit\n }, other);\n}","const shape = {\n borderRadius: 4\n};\nexport default shape;","import PropTypes from 'prop-types';\nconst responsivePropType = process.env.NODE_ENV !== 'production' ? PropTypes.oneOfType([PropTypes.number, PropTypes.string, PropTypes.object, PropTypes.array]) : {};\nexport default responsivePropType;","import deepmerge from '@mui/utils/deepmerge';\nfunction merge(acc, item) {\n if (!item) {\n return acc;\n }\n return deepmerge(acc, item, {\n clone: false // No need to clone deep, it's way faster.\n });\n}\nexport default merge;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport PropTypes from 'prop-types';\nimport deepmerge from '@mui/utils/deepmerge';\nimport merge from './merge';\n\n// The breakpoint **start** at this value.\n// For instance with the first breakpoint xs: [xs, sm[.\nexport const values = {\n xs: 0,\n // phone\n sm: 600,\n // tablet\n md: 900,\n // small laptop\n lg: 1200,\n // desktop\n xl: 1536 // large screen\n};\nconst defaultBreakpoints = {\n // Sorted ASC by size. That's important.\n // It can't be configured as it's used statically for propTypes.\n keys: ['xs', 'sm', 'md', 'lg', 'xl'],\n up: key => `@media (min-width:${values[key]}px)`\n};\nexport function handleBreakpoints(props, propValue, styleFromPropValue) {\n const theme = props.theme || {};\n if (Array.isArray(propValue)) {\n const themeBreakpoints = theme.breakpoints || defaultBreakpoints;\n return propValue.reduce((acc, item, index) => {\n acc[themeBreakpoints.up(themeBreakpoints.keys[index])] = styleFromPropValue(propValue[index]);\n return acc;\n }, {});\n }\n if (typeof propValue === 'object') {\n const themeBreakpoints = theme.breakpoints || defaultBreakpoints;\n return Object.keys(propValue).reduce((acc, breakpoint) => {\n // key is breakpoint\n if (Object.keys(themeBreakpoints.values || values).indexOf(breakpoint) !== -1) {\n const mediaKey = themeBreakpoints.up(breakpoint);\n acc[mediaKey] = styleFromPropValue(propValue[breakpoint], breakpoint);\n } else {\n const cssKey = breakpoint;\n acc[cssKey] = propValue[cssKey];\n }\n return acc;\n }, {});\n }\n const output = styleFromPropValue(propValue);\n return output;\n}\nfunction breakpoints(styleFunction) {\n // false positive\n // eslint-disable-next-line react/function-component-definition\n const newStyleFunction = props => {\n const theme = props.theme || {};\n const base = styleFunction(props);\n const themeBreakpoints = theme.breakpoints || defaultBreakpoints;\n const extended = themeBreakpoints.keys.reduce((acc, key) => {\n if (props[key]) {\n acc = acc || {};\n acc[themeBreakpoints.up(key)] = styleFunction(_extends({\n theme\n }, props[key]));\n }\n return acc;\n }, null);\n return merge(base, extended);\n };\n newStyleFunction.propTypes = process.env.NODE_ENV !== 'production' ? _extends({}, styleFunction.propTypes, {\n xs: PropTypes.object,\n sm: PropTypes.object,\n md: PropTypes.object,\n lg: PropTypes.object,\n xl: PropTypes.object\n }) : {};\n newStyleFunction.filterProps = ['xs', 'sm', 'md', 'lg', 'xl', ...styleFunction.filterProps];\n return newStyleFunction;\n}\nexport function createEmptyBreakpointObject(breakpointsInput = {}) {\n var _breakpointsInput$key;\n const breakpointsInOrder = (_breakpointsInput$key = breakpointsInput.keys) == null ? void 0 : _breakpointsInput$key.reduce((acc, key) => {\n const breakpointStyleKey = breakpointsInput.up(key);\n acc[breakpointStyleKey] = {};\n return acc;\n }, {});\n return breakpointsInOrder || {};\n}\nexport function removeUnusedBreakpoints(breakpointKeys, style) {\n return breakpointKeys.reduce((acc, key) => {\n const breakpointOutput = acc[key];\n const isBreakpointUnused = !breakpointOutput || Object.keys(breakpointOutput).length === 0;\n if (isBreakpointUnused) {\n delete acc[key];\n }\n return acc;\n }, style);\n}\nexport function mergeBreakpointsInOrder(breakpointsInput, ...styles) {\n const emptyBreakpoints = createEmptyBreakpointObject(breakpointsInput);\n const mergedOutput = [emptyBreakpoints, ...styles].reduce((prev, next) => deepmerge(prev, next), {});\n return removeUnusedBreakpoints(Object.keys(emptyBreakpoints), mergedOutput);\n}\n\n// compute base for responsive values; e.g.,\n// [1,2,3] => {xs: true, sm: true, md: true}\n// {xs: 1, sm: 2, md: 3} => {xs: true, sm: true, md: true}\nexport function computeBreakpointsBase(breakpointValues, themeBreakpoints) {\n // fixed value\n if (typeof breakpointValues !== 'object') {\n return {};\n }\n const base = {};\n const breakpointsKeys = Object.keys(themeBreakpoints);\n if (Array.isArray(breakpointValues)) {\n breakpointsKeys.forEach((breakpoint, i) => {\n if (i < breakpointValues.length) {\n base[breakpoint] = true;\n }\n });\n } else {\n breakpointsKeys.forEach(breakpoint => {\n if (breakpointValues[breakpoint] != null) {\n base[breakpoint] = true;\n }\n });\n }\n return base;\n}\nexport function resolveBreakpointValues({\n values: breakpointValues,\n breakpoints: themeBreakpoints,\n base: customBase\n}) {\n const base = customBase || computeBreakpointsBase(breakpointValues, themeBreakpoints);\n const keys = Object.keys(base);\n if (keys.length === 0) {\n return breakpointValues;\n }\n let previous;\n return keys.reduce((acc, breakpoint, i) => {\n if (Array.isArray(breakpointValues)) {\n acc[breakpoint] = breakpointValues[i] != null ? breakpointValues[i] : breakpointValues[previous];\n previous = i;\n } else if (typeof breakpointValues === 'object') {\n acc[breakpoint] = breakpointValues[breakpoint] != null ? breakpointValues[breakpoint] : breakpointValues[previous];\n previous = breakpoint;\n } else {\n acc[breakpoint] = breakpointValues;\n }\n return acc;\n }, {});\n}\nexport default breakpoints;","import capitalize from '@mui/utils/capitalize';\nimport responsivePropType from './responsivePropType';\nimport { handleBreakpoints } from './breakpoints';\nexport function getPath(obj, path, checkVars = true) {\n if (!path || typeof path !== 'string') {\n return null;\n }\n\n // Check if CSS variables are used\n if (obj && obj.vars && checkVars) {\n const val = `vars.${path}`.split('.').reduce((acc, item) => acc && acc[item] ? acc[item] : null, obj);\n if (val != null) {\n return val;\n }\n }\n return path.split('.').reduce((acc, item) => {\n if (acc && acc[item] != null) {\n return acc[item];\n }\n return null;\n }, obj);\n}\nexport function getStyleValue(themeMapping, transform, propValueFinal, userValue = propValueFinal) {\n let value;\n if (typeof themeMapping === 'function') {\n value = themeMapping(propValueFinal);\n } else if (Array.isArray(themeMapping)) {\n value = themeMapping[propValueFinal] || userValue;\n } else {\n value = getPath(themeMapping, propValueFinal) || userValue;\n }\n if (transform) {\n value = transform(value, userValue, themeMapping);\n }\n return value;\n}\nfunction style(options) {\n const {\n prop,\n cssProperty = options.prop,\n themeKey,\n transform\n } = options;\n\n // false positive\n // eslint-disable-next-line react/function-component-definition\n const fn = props => {\n if (props[prop] == null) {\n return null;\n }\n const propValue = props[prop];\n const theme = props.theme;\n const themeMapping = getPath(theme, themeKey) || {};\n const styleFromPropValue = propValueFinal => {\n let value = getStyleValue(themeMapping, transform, propValueFinal);\n if (propValueFinal === value && typeof propValueFinal === 'string') {\n // Haven't found value\n value = getStyleValue(themeMapping, transform, `${prop}${propValueFinal === 'default' ? '' : capitalize(propValueFinal)}`, propValueFinal);\n }\n if (cssProperty === false) {\n return value;\n }\n return {\n [cssProperty]: value\n };\n };\n return handleBreakpoints(props, propValue, styleFromPropValue);\n };\n fn.propTypes = process.env.NODE_ENV !== 'production' ? {\n [prop]: responsivePropType\n } : {};\n fn.filterProps = [prop];\n return fn;\n}\nexport default style;","export default function memoize(fn) {\n const cache = {};\n return arg => {\n if (cache[arg] === undefined) {\n cache[arg] = fn(arg);\n }\n return cache[arg];\n };\n}","import responsivePropType from './responsivePropType';\nimport { handleBreakpoints } from './breakpoints';\nimport { getPath } from './style';\nimport merge from './merge';\nimport memoize from './memoize';\nconst properties = {\n m: 'margin',\n p: 'padding'\n};\nconst directions = {\n t: 'Top',\n r: 'Right',\n b: 'Bottom',\n l: 'Left',\n x: ['Left', 'Right'],\n y: ['Top', 'Bottom']\n};\nconst aliases = {\n marginX: 'mx',\n marginY: 'my',\n paddingX: 'px',\n paddingY: 'py'\n};\n\n// memoize() impact:\n// From 300,000 ops/sec\n// To 350,000 ops/sec\nconst getCssProperties = memoize(prop => {\n // It's not a shorthand notation.\n if (prop.length > 2) {\n if (aliases[prop]) {\n prop = aliases[prop];\n } else {\n return [prop];\n }\n }\n const [a, b] = prop.split('');\n const property = properties[a];\n const direction = directions[b] || '';\n return Array.isArray(direction) ? direction.map(dir => property + dir) : [property + direction];\n});\nexport const marginKeys = ['m', 'mt', 'mr', 'mb', 'ml', 'mx', 'my', 'margin', 'marginTop', 'marginRight', 'marginBottom', 'marginLeft', 'marginX', 'marginY', 'marginInline', 'marginInlineStart', 'marginInlineEnd', 'marginBlock', 'marginBlockStart', 'marginBlockEnd'];\nexport const paddingKeys = ['p', 'pt', 'pr', 'pb', 'pl', 'px', 'py', 'padding', 'paddingTop', 'paddingRight', 'paddingBottom', 'paddingLeft', 'paddingX', 'paddingY', 'paddingInline', 'paddingInlineStart', 'paddingInlineEnd', 'paddingBlock', 'paddingBlockStart', 'paddingBlockEnd'];\nconst spacingKeys = [...marginKeys, ...paddingKeys];\nexport function createUnaryUnit(theme, themeKey, defaultValue, propName) {\n var _getPath;\n const themeSpacing = (_getPath = getPath(theme, themeKey, false)) != null ? _getPath : defaultValue;\n if (typeof themeSpacing === 'number') {\n return abs => {\n if (typeof abs === 'string') {\n return abs;\n }\n if (process.env.NODE_ENV !== 'production') {\n if (typeof abs !== 'number') {\n console.error(`MUI: Expected ${propName} argument to be a number or a string, got ${abs}.`);\n }\n }\n return themeSpacing * abs;\n };\n }\n if (Array.isArray(themeSpacing)) {\n return abs => {\n if (typeof abs === 'string') {\n return abs;\n }\n if (process.env.NODE_ENV !== 'production') {\n if (!Number.isInteger(abs)) {\n console.error([`MUI: The \\`theme.${themeKey}\\` array type cannot be combined with non integer values.` + `You should either use an integer value that can be used as index, or define the \\`theme.${themeKey}\\` as a number.`].join('\\n'));\n } else if (abs > themeSpacing.length - 1) {\n console.error([`MUI: The value provided (${abs}) overflows.`, `The supported values are: ${JSON.stringify(themeSpacing)}.`, `${abs} > ${themeSpacing.length - 1}, you need to add the missing values.`].join('\\n'));\n }\n }\n return themeSpacing[abs];\n };\n }\n if (typeof themeSpacing === 'function') {\n return themeSpacing;\n }\n if (process.env.NODE_ENV !== 'production') {\n console.error([`MUI: The \\`theme.${themeKey}\\` value (${themeSpacing}) is invalid.`, 'It should be a number, an array or a function.'].join('\\n'));\n }\n return () => undefined;\n}\nexport function createUnarySpacing(theme) {\n return createUnaryUnit(theme, 'spacing', 8, 'spacing');\n}\nexport function getValue(transformer, propValue) {\n if (typeof propValue === 'string' || propValue == null) {\n return propValue;\n }\n const abs = Math.abs(propValue);\n const transformed = transformer(abs);\n if (propValue >= 0) {\n return transformed;\n }\n if (typeof transformed === 'number') {\n return -transformed;\n }\n return `-${transformed}`;\n}\nexport function getStyleFromPropValue(cssProperties, transformer) {\n return propValue => cssProperties.reduce((acc, cssProperty) => {\n acc[cssProperty] = getValue(transformer, propValue);\n return acc;\n }, {});\n}\nfunction resolveCssProperty(props, keys, prop, transformer) {\n // Using a hash computation over an array iteration could be faster, but with only 28 items,\n // it's doesn't worth the bundle size.\n if (keys.indexOf(prop) === -1) {\n return null;\n }\n const cssProperties = getCssProperties(prop);\n const styleFromPropValue = getStyleFromPropValue(cssProperties, transformer);\n const propValue = props[prop];\n return handleBreakpoints(props, propValue, styleFromPropValue);\n}\nfunction style(props, keys) {\n const transformer = createUnarySpacing(props.theme);\n return Object.keys(props).map(prop => resolveCssProperty(props, keys, prop, transformer)).reduce(merge, {});\n}\nexport function margin(props) {\n return style(props, marginKeys);\n}\nmargin.propTypes = process.env.NODE_ENV !== 'production' ? marginKeys.reduce((obj, key) => {\n obj[key] = responsivePropType;\n return obj;\n}, {}) : {};\nmargin.filterProps = marginKeys;\nexport function padding(props) {\n return style(props, paddingKeys);\n}\npadding.propTypes = process.env.NODE_ENV !== 'production' ? paddingKeys.reduce((obj, key) => {\n obj[key] = responsivePropType;\n return obj;\n}, {}) : {};\npadding.filterProps = paddingKeys;\nfunction spacing(props) {\n return style(props, spacingKeys);\n}\nspacing.propTypes = process.env.NODE_ENV !== 'production' ? spacingKeys.reduce((obj, key) => {\n obj[key] = responsivePropType;\n return obj;\n}, {}) : {};\nspacing.filterProps = spacingKeys;\nexport default spacing;","import { createUnarySpacing } from '../spacing';\n\n// The different signatures imply different meaning for their arguments that can't be expressed structurally.\n// We express the difference with variable names.\n\nexport default function createSpacing(spacingInput = 8) {\n // Already transformed.\n if (spacingInput.mui) {\n return spacingInput;\n }\n\n // Material Design layouts are visually balanced. Most measurements align to an 8dp grid, which aligns both spacing and the overall layout.\n // Smaller components, such as icons, can align to a 4dp grid.\n // https://m2.material.io/design/layout/understanding-layout.html\n const transform = createUnarySpacing({\n spacing: spacingInput\n });\n const spacing = (...argsInput) => {\n if (process.env.NODE_ENV !== 'production') {\n if (!(argsInput.length <= 4)) {\n console.error(`MUI: Too many arguments provided, expected between 0 and 4, got ${argsInput.length}`);\n }\n }\n const args = argsInput.length === 0 ? [1] : argsInput;\n return args.map(argument => {\n const output = transform(argument);\n return typeof output === 'number' ? `${output}px` : output;\n }).join(' ');\n };\n spacing.mui = true;\n return spacing;\n}","import merge from './merge';\nfunction compose(...styles) {\n const handlers = styles.reduce((acc, style) => {\n style.filterProps.forEach(prop => {\n acc[prop] = style;\n });\n return acc;\n }, {});\n\n // false positive\n // eslint-disable-next-line react/function-component-definition\n const fn = props => {\n return Object.keys(props).reduce((acc, prop) => {\n if (handlers[prop]) {\n return merge(acc, handlers[prop](props));\n }\n return acc;\n }, {});\n };\n fn.propTypes = process.env.NODE_ENV !== 'production' ? styles.reduce((acc, style) => Object.assign(acc, style.propTypes), {}) : {};\n fn.filterProps = styles.reduce((acc, style) => acc.concat(style.filterProps), []);\n return fn;\n}\nexport default compose;","import responsivePropType from './responsivePropType';\nimport style from './style';\nimport compose from './compose';\nimport { createUnaryUnit, getValue } from './spacing';\nimport { handleBreakpoints } from './breakpoints';\nexport function borderTransform(value) {\n if (typeof value !== 'number') {\n return value;\n }\n return `${value}px solid`;\n}\nfunction createBorderStyle(prop, transform) {\n return style({\n prop,\n themeKey: 'borders',\n transform\n });\n}\nexport const border = createBorderStyle('border', borderTransform);\nexport const borderTop = createBorderStyle('borderTop', borderTransform);\nexport const borderRight = createBorderStyle('borderRight', borderTransform);\nexport const borderBottom = createBorderStyle('borderBottom', borderTransform);\nexport const borderLeft = createBorderStyle('borderLeft', borderTransform);\nexport const borderColor = createBorderStyle('borderColor');\nexport const borderTopColor = createBorderStyle('borderTopColor');\nexport const borderRightColor = createBorderStyle('borderRightColor');\nexport const borderBottomColor = createBorderStyle('borderBottomColor');\nexport const borderLeftColor = createBorderStyle('borderLeftColor');\nexport const outline = createBorderStyle('outline', borderTransform);\nexport const outlineColor = createBorderStyle('outlineColor');\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const borderRadius = props => {\n if (props.borderRadius !== undefined && props.borderRadius !== null) {\n const transformer = createUnaryUnit(props.theme, 'shape.borderRadius', 4, 'borderRadius');\n const styleFromPropValue = propValue => ({\n borderRadius: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.borderRadius, styleFromPropValue);\n }\n return null;\n};\nborderRadius.propTypes = process.env.NODE_ENV !== 'production' ? {\n borderRadius: responsivePropType\n} : {};\nborderRadius.filterProps = ['borderRadius'];\nconst borders = compose(border, borderTop, borderRight, borderBottom, borderLeft, borderColor, borderTopColor, borderRightColor, borderBottomColor, borderLeftColor, borderRadius, outline, outlineColor);\nexport default borders;","import style from './style';\nimport compose from './compose';\nimport { createUnaryUnit, getValue } from './spacing';\nimport { handleBreakpoints } from './breakpoints';\nimport responsivePropType from './responsivePropType';\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const gap = props => {\n if (props.gap !== undefined && props.gap !== null) {\n const transformer = createUnaryUnit(props.theme, 'spacing', 8, 'gap');\n const styleFromPropValue = propValue => ({\n gap: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.gap, styleFromPropValue);\n }\n return null;\n};\ngap.propTypes = process.env.NODE_ENV !== 'production' ? {\n gap: responsivePropType\n} : {};\ngap.filterProps = ['gap'];\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const columnGap = props => {\n if (props.columnGap !== undefined && props.columnGap !== null) {\n const transformer = createUnaryUnit(props.theme, 'spacing', 8, 'columnGap');\n const styleFromPropValue = propValue => ({\n columnGap: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.columnGap, styleFromPropValue);\n }\n return null;\n};\ncolumnGap.propTypes = process.env.NODE_ENV !== 'production' ? {\n columnGap: responsivePropType\n} : {};\ncolumnGap.filterProps = ['columnGap'];\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const rowGap = props => {\n if (props.rowGap !== undefined && props.rowGap !== null) {\n const transformer = createUnaryUnit(props.theme, 'spacing', 8, 'rowGap');\n const styleFromPropValue = propValue => ({\n rowGap: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.rowGap, styleFromPropValue);\n }\n return null;\n};\nrowGap.propTypes = process.env.NODE_ENV !== 'production' ? {\n rowGap: responsivePropType\n} : {};\nrowGap.filterProps = ['rowGap'];\nexport const gridColumn = style({\n prop: 'gridColumn'\n});\nexport const gridRow = style({\n prop: 'gridRow'\n});\nexport const gridAutoFlow = style({\n prop: 'gridAutoFlow'\n});\nexport const gridAutoColumns = style({\n prop: 'gridAutoColumns'\n});\nexport const gridAutoRows = style({\n prop: 'gridAutoRows'\n});\nexport const gridTemplateColumns = style({\n prop: 'gridTemplateColumns'\n});\nexport const gridTemplateRows = style({\n prop: 'gridTemplateRows'\n});\nexport const gridTemplateAreas = style({\n prop: 'gridTemplateAreas'\n});\nexport const gridArea = style({\n prop: 'gridArea'\n});\nconst grid = compose(gap, columnGap, rowGap, gridColumn, gridRow, gridAutoFlow, gridAutoColumns, gridAutoRows, gridTemplateColumns, gridTemplateRows, gridTemplateAreas, gridArea);\nexport default grid;","import style from './style';\nimport compose from './compose';\nexport function paletteTransform(value, userValue) {\n if (userValue === 'grey') {\n return userValue;\n }\n return value;\n}\nexport const color = style({\n prop: 'color',\n themeKey: 'palette',\n transform: paletteTransform\n});\nexport const bgcolor = style({\n prop: 'bgcolor',\n cssProperty: 'backgroundColor',\n themeKey: 'palette',\n transform: paletteTransform\n});\nexport const backgroundColor = style({\n prop: 'backgroundColor',\n themeKey: 'palette',\n transform: paletteTransform\n});\nconst palette = compose(color, bgcolor, backgroundColor);\nexport default palette;","import style from './style';\nimport compose from './compose';\nimport { handleBreakpoints, values as breakpointsValues } from './breakpoints';\nexport function sizingTransform(value) {\n return value <= 1 && value !== 0 ? `${value * 100}%` : value;\n}\nexport const width = style({\n prop: 'width',\n transform: sizingTransform\n});\nexport const maxWidth = props => {\n if (props.maxWidth !== undefined && props.maxWidth !== null) {\n const styleFromPropValue = propValue => {\n var _props$theme, _props$theme2;\n const breakpoint = ((_props$theme = props.theme) == null || (_props$theme = _props$theme.breakpoints) == null || (_props$theme = _props$theme.values) == null ? void 0 : _props$theme[propValue]) || breakpointsValues[propValue];\n if (!breakpoint) {\n return {\n maxWidth: sizingTransform(propValue)\n };\n }\n if (((_props$theme2 = props.theme) == null || (_props$theme2 = _props$theme2.breakpoints) == null ? void 0 : _props$theme2.unit) !== 'px') {\n return {\n maxWidth: `${breakpoint}${props.theme.breakpoints.unit}`\n };\n }\n return {\n maxWidth: breakpoint\n };\n };\n return handleBreakpoints(props, props.maxWidth, styleFromPropValue);\n }\n return null;\n};\nmaxWidth.filterProps = ['maxWidth'];\nexport const minWidth = style({\n prop: 'minWidth',\n transform: sizingTransform\n});\nexport const height = style({\n prop: 'height',\n transform: sizingTransform\n});\nexport const maxHeight = style({\n prop: 'maxHeight',\n transform: sizingTransform\n});\nexport const minHeight = style({\n prop: 'minHeight',\n transform: sizingTransform\n});\nexport const sizeWidth = style({\n prop: 'size',\n cssProperty: 'width',\n transform: sizingTransform\n});\nexport const sizeHeight = style({\n prop: 'size',\n cssProperty: 'height',\n transform: sizingTransform\n});\nexport const boxSizing = style({\n prop: 'boxSizing'\n});\nconst sizing = compose(width, maxWidth, minWidth, height, maxHeight, minHeight, boxSizing);\nexport default sizing;","import { padding, margin } from '../spacing';\nimport { borderRadius, borderTransform } from '../borders';\nimport { gap, rowGap, columnGap } from '../cssGrid';\nimport { paletteTransform } from '../palette';\nimport { maxWidth, sizingTransform } from '../sizing';\nconst defaultSxConfig = {\n // borders\n border: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderTop: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderRight: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderBottom: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderLeft: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderColor: {\n themeKey: 'palette'\n },\n borderTopColor: {\n themeKey: 'palette'\n },\n borderRightColor: {\n themeKey: 'palette'\n },\n borderBottomColor: {\n themeKey: 'palette'\n },\n borderLeftColor: {\n themeKey: 'palette'\n },\n outline: {\n themeKey: 'borders',\n transform: borderTransform\n },\n outlineColor: {\n themeKey: 'palette'\n },\n borderRadius: {\n themeKey: 'shape.borderRadius',\n style: borderRadius\n },\n // palette\n color: {\n themeKey: 'palette',\n transform: paletteTransform\n },\n bgcolor: {\n themeKey: 'palette',\n cssProperty: 'backgroundColor',\n transform: paletteTransform\n },\n backgroundColor: {\n themeKey: 'palette',\n transform: paletteTransform\n },\n // spacing\n p: {\n style: padding\n },\n pt: {\n style: padding\n },\n pr: {\n style: padding\n },\n pb: {\n style: padding\n },\n pl: {\n style: padding\n },\n px: {\n style: padding\n },\n py: {\n style: padding\n },\n padding: {\n style: padding\n },\n paddingTop: {\n style: padding\n },\n paddingRight: {\n style: padding\n },\n paddingBottom: {\n style: padding\n },\n paddingLeft: {\n style: padding\n },\n paddingX: {\n style: padding\n },\n paddingY: {\n style: padding\n },\n paddingInline: {\n style: padding\n },\n paddingInlineStart: {\n style: padding\n },\n paddingInlineEnd: {\n style: padding\n },\n paddingBlock: {\n style: padding\n },\n paddingBlockStart: {\n style: padding\n },\n paddingBlockEnd: {\n style: padding\n },\n m: {\n style: margin\n },\n mt: {\n style: margin\n },\n mr: {\n style: margin\n },\n mb: {\n style: margin\n },\n ml: {\n style: margin\n },\n mx: {\n style: margin\n },\n my: {\n style: margin\n },\n margin: {\n style: margin\n },\n marginTop: {\n style: margin\n },\n marginRight: {\n style: margin\n },\n marginBottom: {\n style: margin\n },\n marginLeft: {\n style: margin\n },\n marginX: {\n style: margin\n },\n marginY: {\n style: margin\n },\n marginInline: {\n style: margin\n },\n marginInlineStart: {\n style: margin\n },\n marginInlineEnd: {\n style: margin\n },\n marginBlock: {\n style: margin\n },\n marginBlockStart: {\n style: margin\n },\n marginBlockEnd: {\n style: margin\n },\n // display\n displayPrint: {\n cssProperty: false,\n transform: value => ({\n '@media print': {\n display: value\n }\n })\n },\n display: {},\n overflow: {},\n textOverflow: {},\n visibility: {},\n whiteSpace: {},\n // flexbox\n flexBasis: {},\n flexDirection: {},\n flexWrap: {},\n justifyContent: {},\n alignItems: {},\n alignContent: {},\n order: {},\n flex: {},\n flexGrow: {},\n flexShrink: {},\n alignSelf: {},\n justifyItems: {},\n justifySelf: {},\n // grid\n gap: {\n style: gap\n },\n rowGap: {\n style: rowGap\n },\n columnGap: {\n style: columnGap\n },\n gridColumn: {},\n gridRow: {},\n gridAutoFlow: {},\n gridAutoColumns: {},\n gridAutoRows: {},\n gridTemplateColumns: {},\n gridTemplateRows: {},\n gridTemplateAreas: {},\n gridArea: {},\n // positions\n position: {},\n zIndex: {\n themeKey: 'zIndex'\n },\n top: {},\n right: {},\n bottom: {},\n left: {},\n // shadows\n boxShadow: {\n themeKey: 'shadows'\n },\n // sizing\n width: {\n transform: sizingTransform\n },\n maxWidth: {\n style: maxWidth\n },\n minWidth: {\n transform: sizingTransform\n },\n height: {\n transform: sizingTransform\n },\n maxHeight: {\n transform: sizingTransform\n },\n minHeight: {\n transform: sizingTransform\n },\n boxSizing: {},\n // typography\n fontFamily: {\n themeKey: 'typography'\n },\n fontSize: {\n themeKey: 'typography'\n },\n fontStyle: {\n themeKey: 'typography'\n },\n fontWeight: {\n themeKey: 'typography'\n },\n letterSpacing: {},\n textTransform: {},\n lineHeight: {},\n textAlign: {},\n typography: {\n cssProperty: false,\n themeKey: 'typography'\n }\n};\nexport default defaultSxConfig;","import capitalize from '@mui/utils/capitalize';\nimport merge from '../merge';\nimport { getPath, getStyleValue as getValue } from '../style';\nimport { handleBreakpoints, createEmptyBreakpointObject, removeUnusedBreakpoints } from '../breakpoints';\nimport defaultSxConfig from './defaultSxConfig';\nfunction objectsHaveSameKeys(...objects) {\n const allKeys = objects.reduce((keys, object) => keys.concat(Object.keys(object)), []);\n const union = new Set(allKeys);\n return objects.every(object => union.size === Object.keys(object).length);\n}\nfunction callIfFn(maybeFn, arg) {\n return typeof maybeFn === 'function' ? maybeFn(arg) : maybeFn;\n}\n\n// eslint-disable-next-line @typescript-eslint/naming-convention\nexport function unstable_createStyleFunctionSx() {\n function getThemeValue(prop, val, theme, config) {\n const props = {\n [prop]: val,\n theme\n };\n const options = config[prop];\n if (!options) {\n return {\n [prop]: val\n };\n }\n const {\n cssProperty = prop,\n themeKey,\n transform,\n style\n } = options;\n if (val == null) {\n return null;\n }\n\n // TODO v6: remove, see https://github.com/mui/material-ui/pull/38123\n if (themeKey === 'typography' && val === 'inherit') {\n return {\n [prop]: val\n };\n }\n const themeMapping = getPath(theme, themeKey) || {};\n if (style) {\n return style(props);\n }\n const styleFromPropValue = propValueFinal => {\n let value = getValue(themeMapping, transform, propValueFinal);\n if (propValueFinal === value && typeof propValueFinal === 'string') {\n // Haven't found value\n value = getValue(themeMapping, transform, `${prop}${propValueFinal === 'default' ? '' : capitalize(propValueFinal)}`, propValueFinal);\n }\n if (cssProperty === false) {\n return value;\n }\n return {\n [cssProperty]: value\n };\n };\n return handleBreakpoints(props, val, styleFromPropValue);\n }\n function styleFunctionSx(props) {\n var _theme$unstable_sxCon;\n const {\n sx,\n theme = {}\n } = props || {};\n if (!sx) {\n return null; // Emotion & styled-components will neglect null\n }\n const config = (_theme$unstable_sxCon = theme.unstable_sxConfig) != null ? _theme$unstable_sxCon : defaultSxConfig;\n\n /*\n * Receive `sxInput` as object or callback\n * and then recursively check keys & values to create media query object styles.\n * (the result will be used in `styled`)\n */\n function traverse(sxInput) {\n let sxObject = sxInput;\n if (typeof sxInput === 'function') {\n sxObject = sxInput(theme);\n } else if (typeof sxInput !== 'object') {\n // value\n return sxInput;\n }\n if (!sxObject) {\n return null;\n }\n const emptyBreakpoints = createEmptyBreakpointObject(theme.breakpoints);\n const breakpointsKeys = Object.keys(emptyBreakpoints);\n let css = emptyBreakpoints;\n Object.keys(sxObject).forEach(styleKey => {\n const value = callIfFn(sxObject[styleKey], theme);\n if (value !== null && value !== undefined) {\n if (typeof value === 'object') {\n if (config[styleKey]) {\n css = merge(css, getThemeValue(styleKey, value, theme, config));\n } else {\n const breakpointsValues = handleBreakpoints({\n theme\n }, value, x => ({\n [styleKey]: x\n }));\n if (objectsHaveSameKeys(breakpointsValues, value)) {\n css[styleKey] = styleFunctionSx({\n sx: value,\n theme\n });\n } else {\n css = merge(css, breakpointsValues);\n }\n }\n } else {\n css = merge(css, getThemeValue(styleKey, value, theme, config));\n }\n }\n });\n return removeUnusedBreakpoints(breakpointsKeys, css);\n }\n return Array.isArray(sx) ? sx.map(traverse) : traverse(sx);\n }\n return styleFunctionSx;\n}\nconst styleFunctionSx = unstable_createStyleFunctionSx();\nstyleFunctionSx.filterProps = ['sx'];\nexport default styleFunctionSx;","/**\n * A universal utility to style components with multiple color modes. Always use it from the theme object.\n * It works with:\n * - [Basic theme](https://mui.com/material-ui/customization/dark-mode/)\n * - [CSS theme variables](https://mui.com/material-ui/experimental-api/css-theme-variables/overview/)\n * - Zero-runtime engine\n *\n * Tips: Use an array over object spread and place `theme.applyStyles()` last.\n *\n * ✅ [{ background: '#e5e5e5' }, theme.applyStyles('dark', { background: '#1c1c1c' })]\n *\n * 🚫 { background: '#e5e5e5', ...theme.applyStyles('dark', { background: '#1c1c1c' })}\n *\n * @example\n * 1. using with `styled`:\n * ```jsx\n * const Component = styled('div')(({ theme }) => [\n * { background: '#e5e5e5' },\n * theme.applyStyles('dark', {\n * background: '#1c1c1c',\n * color: '#fff',\n * }),\n * ]);\n * ```\n *\n * @example\n * 2. using with `sx` prop:\n * ```jsx\n * [\n * { background: '#e5e5e5' },\n * theme.applyStyles('dark', {\n * background: '#1c1c1c',\n * color: '#fff',\n * }),\n * ]}\n * />\n * ```\n *\n * @example\n * 3. theming a component:\n * ```jsx\n * extendTheme({\n * components: {\n * MuiButton: {\n * styleOverrides: {\n * root: ({ theme }) => [\n * { background: '#e5e5e5' },\n * theme.applyStyles('dark', {\n * background: '#1c1c1c',\n * color: '#fff',\n * }),\n * ],\n * },\n * }\n * }\n * })\n *```\n */\nexport default function applyStyles(key, styles) {\n // @ts-expect-error this is 'any' type\n const theme = this;\n if (theme.vars && typeof theme.getColorSchemeSelector === 'function') {\n // If CssVarsProvider is used as a provider,\n // returns '* :where([data-mui-color-scheme=\"light|dark\"]) &'\n const selector = theme.getColorSchemeSelector(key).replace(/(\\[[^\\]]+\\])/, '*:where($1)');\n return {\n [selector]: styles\n };\n }\n if (theme.palette.mode === key) {\n return styles;\n }\n return {};\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"breakpoints\", \"palette\", \"spacing\", \"shape\"];\nimport deepmerge from '@mui/utils/deepmerge';\nimport createBreakpoints from './createBreakpoints';\nimport shape from './shape';\nimport createSpacing from './createSpacing';\nimport styleFunctionSx from '../styleFunctionSx/styleFunctionSx';\nimport defaultSxConfig from '../styleFunctionSx/defaultSxConfig';\nimport applyStyles from './applyStyles';\nfunction createTheme(options = {}, ...args) {\n const {\n breakpoints: breakpointsInput = {},\n palette: paletteInput = {},\n spacing: spacingInput,\n shape: shapeInput = {}\n } = options,\n other = _objectWithoutPropertiesLoose(options, _excluded);\n const breakpoints = createBreakpoints(breakpointsInput);\n const spacing = createSpacing(spacingInput);\n let muiTheme = deepmerge({\n breakpoints,\n direction: 'ltr',\n components: {},\n // Inject component definitions.\n palette: _extends({\n mode: 'light'\n }, paletteInput),\n spacing,\n shape: _extends({}, shape, shapeInput)\n }, other);\n muiTheme.applyStyles = applyStyles;\n muiTheme = args.reduce((acc, argument) => deepmerge(acc, argument), muiTheme);\n muiTheme.unstable_sxConfig = _extends({}, defaultSxConfig, other == null ? void 0 : other.unstable_sxConfig);\n muiTheme.unstable_sx = function sx(props) {\n return styleFunctionSx({\n sx: props,\n theme: this\n });\n };\n return muiTheme;\n}\nexport default createTheme;","'use client';\n\nimport * as React from 'react';\nimport { ThemeContext } from '@mui/styled-engine';\nfunction isObjectEmpty(obj) {\n return Object.keys(obj).length === 0;\n}\nfunction useTheme(defaultTheme = null) {\n const contextTheme = React.useContext(ThemeContext);\n return !contextTheme || isObjectEmpty(contextTheme) ? defaultTheme : contextTheme;\n}\nexport default useTheme;","'use client';\n\nimport createTheme from './createTheme';\nimport useThemeWithoutDefault from './useThemeWithoutDefault';\nexport const systemDefaultTheme = createTheme();\nfunction useTheme(defaultTheme = systemDefaultTheme) {\n return useThemeWithoutDefault(defaultTheme);\n}\nexport default useTheme;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"ownerState\"],\n _excluded2 = [\"variants\"],\n _excluded3 = [\"name\", \"slot\", \"skipVariantsResolver\", \"skipSx\", \"overridesResolver\"];\n/* eslint-disable no-underscore-dangle */\nimport styledEngineStyled, { internal_processStyles as processStyles } from '@mui/styled-engine';\nimport { isPlainObject } from '@mui/utils/deepmerge';\nimport capitalize from '@mui/utils/capitalize';\nimport getDisplayName from '@mui/utils/getDisplayName';\nimport createTheme from './createTheme';\nimport styleFunctionSx from './styleFunctionSx';\nfunction isEmpty(obj) {\n return Object.keys(obj).length === 0;\n}\n\n// https://github.com/emotion-js/emotion/blob/26ded6109fcd8ca9875cc2ce4564fee678a3f3c5/packages/styled/src/utils.js#L40\nfunction isStringTag(tag) {\n return typeof tag === 'string' &&\n // 96 is one less than the char code\n // for \"a\" so this is checking that\n // it's a lowercase character\n tag.charCodeAt(0) > 96;\n}\n\n// Update /system/styled/#api in case if this changes\nexport function shouldForwardProp(prop) {\n return prop !== 'ownerState' && prop !== 'theme' && prop !== 'sx' && prop !== 'as';\n}\nexport const systemDefaultTheme = createTheme();\nconst lowercaseFirstLetter = string => {\n if (!string) {\n return string;\n }\n return string.charAt(0).toLowerCase() + string.slice(1);\n};\nfunction resolveTheme({\n defaultTheme,\n theme,\n themeId\n}) {\n return isEmpty(theme) ? defaultTheme : theme[themeId] || theme;\n}\nfunction defaultOverridesResolver(slot) {\n if (!slot) {\n return null;\n }\n return (props, styles) => styles[slot];\n}\nfunction processStyleArg(callableStyle, _ref) {\n let {\n ownerState\n } = _ref,\n props = _objectWithoutPropertiesLoose(_ref, _excluded);\n const resolvedStylesArg = typeof callableStyle === 'function' ? callableStyle(_extends({\n ownerState\n }, props)) : callableStyle;\n if (Array.isArray(resolvedStylesArg)) {\n return resolvedStylesArg.flatMap(resolvedStyle => processStyleArg(resolvedStyle, _extends({\n ownerState\n }, props)));\n }\n if (!!resolvedStylesArg && typeof resolvedStylesArg === 'object' && Array.isArray(resolvedStylesArg.variants)) {\n const {\n variants = []\n } = resolvedStylesArg,\n otherStyles = _objectWithoutPropertiesLoose(resolvedStylesArg, _excluded2);\n let result = otherStyles;\n variants.forEach(variant => {\n let isMatch = true;\n if (typeof variant.props === 'function') {\n isMatch = variant.props(_extends({\n ownerState\n }, props, ownerState));\n } else {\n Object.keys(variant.props).forEach(key => {\n if ((ownerState == null ? void 0 : ownerState[key]) !== variant.props[key] && props[key] !== variant.props[key]) {\n isMatch = false;\n }\n });\n }\n if (isMatch) {\n if (!Array.isArray(result)) {\n result = [result];\n }\n result.push(typeof variant.style === 'function' ? variant.style(_extends({\n ownerState\n }, props, ownerState)) : variant.style);\n }\n });\n return result;\n }\n return resolvedStylesArg;\n}\nexport default function createStyled(input = {}) {\n const {\n themeId,\n defaultTheme = systemDefaultTheme,\n rootShouldForwardProp = shouldForwardProp,\n slotShouldForwardProp = shouldForwardProp\n } = input;\n const systemSx = props => {\n return styleFunctionSx(_extends({}, props, {\n theme: resolveTheme(_extends({}, props, {\n defaultTheme,\n themeId\n }))\n }));\n };\n systemSx.__mui_systemSx = true;\n return (tag, inputOptions = {}) => {\n // Filter out the `sx` style function from the previous styled component to prevent unnecessary styles generated by the composite components.\n processStyles(tag, styles => styles.filter(style => !(style != null && style.__mui_systemSx)));\n const {\n name: componentName,\n slot: componentSlot,\n skipVariantsResolver: inputSkipVariantsResolver,\n skipSx: inputSkipSx,\n // TODO v6: remove `lowercaseFirstLetter()` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n overridesResolver = defaultOverridesResolver(lowercaseFirstLetter(componentSlot))\n } = inputOptions,\n options = _objectWithoutPropertiesLoose(inputOptions, _excluded3);\n\n // if skipVariantsResolver option is defined, take the value, otherwise, true for root and false for other slots.\n const skipVariantsResolver = inputSkipVariantsResolver !== undefined ? inputSkipVariantsResolver :\n // TODO v6: remove `Root` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n componentSlot && componentSlot !== 'Root' && componentSlot !== 'root' || false;\n const skipSx = inputSkipSx || false;\n let label;\n if (process.env.NODE_ENV !== 'production') {\n if (componentName) {\n // TODO v6: remove `lowercaseFirstLetter()` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n label = `${componentName}-${lowercaseFirstLetter(componentSlot || 'Root')}`;\n }\n }\n let shouldForwardPropOption = shouldForwardProp;\n\n // TODO v6: remove `Root` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n if (componentSlot === 'Root' || componentSlot === 'root') {\n shouldForwardPropOption = rootShouldForwardProp;\n } else if (componentSlot) {\n // any other slot specified\n shouldForwardPropOption = slotShouldForwardProp;\n } else if (isStringTag(tag)) {\n // for string (html) tag, preserve the behavior in emotion & styled-components.\n shouldForwardPropOption = undefined;\n }\n const defaultStyledResolver = styledEngineStyled(tag, _extends({\n shouldForwardProp: shouldForwardPropOption,\n label\n }, options));\n const transformStyleArg = stylesArg => {\n // On the server Emotion doesn't use React.forwardRef for creating components, so the created\n // component stays as a function. This condition makes sure that we do not interpolate functions\n // which are basically components used as a selectors.\n if (typeof stylesArg === 'function' && stylesArg.__emotion_real !== stylesArg || isPlainObject(stylesArg)) {\n return props => processStyleArg(stylesArg, _extends({}, props, {\n theme: resolveTheme({\n theme: props.theme,\n defaultTheme,\n themeId\n })\n }));\n }\n return stylesArg;\n };\n const muiStyledResolver = (styleArg, ...expressions) => {\n let transformedStyleArg = transformStyleArg(styleArg);\n const expressionsWithDefaultTheme = expressions ? expressions.map(transformStyleArg) : [];\n if (componentName && overridesResolver) {\n expressionsWithDefaultTheme.push(props => {\n const theme = resolveTheme(_extends({}, props, {\n defaultTheme,\n themeId\n }));\n if (!theme.components || !theme.components[componentName] || !theme.components[componentName].styleOverrides) {\n return null;\n }\n const styleOverrides = theme.components[componentName].styleOverrides;\n const resolvedStyleOverrides = {};\n // TODO: v7 remove iteration and use `resolveStyleArg(styleOverrides[slot])` directly\n Object.entries(styleOverrides).forEach(([slotKey, slotStyle]) => {\n resolvedStyleOverrides[slotKey] = processStyleArg(slotStyle, _extends({}, props, {\n theme\n }));\n });\n return overridesResolver(props, resolvedStyleOverrides);\n });\n }\n if (componentName && !skipVariantsResolver) {\n expressionsWithDefaultTheme.push(props => {\n var _theme$components;\n const theme = resolveTheme(_extends({}, props, {\n defaultTheme,\n themeId\n }));\n const themeVariants = theme == null || (_theme$components = theme.components) == null || (_theme$components = _theme$components[componentName]) == null ? void 0 : _theme$components.variants;\n return processStyleArg({\n variants: themeVariants\n }, _extends({}, props, {\n theme\n }));\n });\n }\n if (!skipSx) {\n expressionsWithDefaultTheme.push(systemSx);\n }\n const numOfCustomFnsApplied = expressionsWithDefaultTheme.length - expressions.length;\n if (Array.isArray(styleArg) && numOfCustomFnsApplied > 0) {\n const placeholders = new Array(numOfCustomFnsApplied).fill('');\n // If the type is array, than we need to add placeholders in the template for the overrides, variants and the sx styles.\n transformedStyleArg = [...styleArg, ...placeholders];\n transformedStyleArg.raw = [...styleArg.raw, ...placeholders];\n }\n const Component = defaultStyledResolver(transformedStyleArg, ...expressionsWithDefaultTheme);\n if (process.env.NODE_ENV !== 'production') {\n let displayName;\n if (componentName) {\n displayName = `${componentName}${capitalize(componentSlot || '')}`;\n }\n if (displayName === undefined) {\n displayName = `Styled(${getDisplayName(tag)})`;\n }\n Component.displayName = displayName;\n }\n if (tag.muiName) {\n Component.muiName = tag.muiName;\n }\n return Component;\n };\n if (defaultStyledResolver.withConfig) {\n muiStyledResolver.withConfig = defaultStyledResolver.withConfig;\n }\n return muiStyledResolver;\n };\n}","import resolveProps from '@mui/utils/resolveProps';\nexport default function getThemeProps(params) {\n const {\n theme,\n name,\n props\n } = params;\n if (!theme || !theme.components || !theme.components[name] || !theme.components[name].defaultProps) {\n return props;\n }\n return resolveProps(theme.components[name].defaultProps, props);\n}","'use client';\n\nimport getThemeProps from './getThemeProps';\nimport useTheme from '../useTheme';\nexport default function useThemeProps({\n props,\n name,\n defaultTheme,\n themeId\n}) {\n let theme = useTheme(defaultTheme);\n if (themeId) {\n theme = theme[themeId] || theme;\n }\n const mergedProps = getThemeProps({\n theme,\n name,\n props\n });\n return mergedProps;\n}","import _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\n/* eslint-disable @typescript-eslint/naming-convention */\nimport clamp from '@mui/utils/clamp';\n/**\n * Returns a number whose value is limited to the given range.\n * @param {number} value The value to be clamped\n * @param {number} min The lower boundary of the output range\n * @param {number} max The upper boundary of the output range\n * @returns {number} A number in the range [min, max]\n */\nfunction clampWrapper(value, min = 0, max = 1) {\n if (process.env.NODE_ENV !== 'production') {\n if (value < min || value > max) {\n console.error(`MUI: The value provided ${value} is out of range [${min}, ${max}].`);\n }\n }\n return clamp(value, min, max);\n}\n\n/**\n * Converts a color from CSS hex format to CSS rgb format.\n * @param {string} color - Hex color, i.e. #nnn or #nnnnnn\n * @returns {string} A CSS rgb color string\n */\nexport function hexToRgb(color) {\n color = color.slice(1);\n const re = new RegExp(`.{1,${color.length >= 6 ? 2 : 1}}`, 'g');\n let colors = color.match(re);\n if (colors && colors[0].length === 1) {\n colors = colors.map(n => n + n);\n }\n return colors ? `rgb${colors.length === 4 ? 'a' : ''}(${colors.map((n, index) => {\n return index < 3 ? parseInt(n, 16) : Math.round(parseInt(n, 16) / 255 * 1000) / 1000;\n }).join(', ')})` : '';\n}\nfunction intToHex(int) {\n const hex = int.toString(16);\n return hex.length === 1 ? `0${hex}` : hex;\n}\n\n/**\n * Returns an object with the type and values of a color.\n *\n * Note: Does not support rgb % values.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @returns {object} - A MUI color object: {type: string, values: number[]}\n */\nexport function decomposeColor(color) {\n // Idempotent\n if (color.type) {\n return color;\n }\n if (color.charAt(0) === '#') {\n return decomposeColor(hexToRgb(color));\n }\n const marker = color.indexOf('(');\n const type = color.substring(0, marker);\n if (['rgb', 'rgba', 'hsl', 'hsla', 'color'].indexOf(type) === -1) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: Unsupported \\`${color}\\` color.\nThe following formats are supported: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color().` : _formatMuiErrorMessage(9, color));\n }\n let values = color.substring(marker + 1, color.length - 1);\n let colorSpace;\n if (type === 'color') {\n values = values.split(' ');\n colorSpace = values.shift();\n if (values.length === 4 && values[3].charAt(0) === '/') {\n values[3] = values[3].slice(1);\n }\n if (['srgb', 'display-p3', 'a98-rgb', 'prophoto-rgb', 'rec-2020'].indexOf(colorSpace) === -1) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: unsupported \\`${colorSpace}\\` color space.\nThe following color spaces are supported: srgb, display-p3, a98-rgb, prophoto-rgb, rec-2020.` : _formatMuiErrorMessage(10, colorSpace));\n }\n } else {\n values = values.split(',');\n }\n values = values.map(value => parseFloat(value));\n return {\n type,\n values,\n colorSpace\n };\n}\n\n/**\n * Returns a channel created from the input color.\n *\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @returns {string} - The channel for the color, that can be used in rgba or hsla colors\n */\nexport const colorChannel = color => {\n const decomposedColor = decomposeColor(color);\n return decomposedColor.values.slice(0, 3).map((val, idx) => decomposedColor.type.indexOf('hsl') !== -1 && idx !== 0 ? `${val}%` : val).join(' ');\n};\nexport const private_safeColorChannel = (color, warning) => {\n try {\n return colorChannel(color);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n};\n\n/**\n * Converts a color object with type and values to a string.\n * @param {object} color - Decomposed color\n * @param {string} color.type - One of: 'rgb', 'rgba', 'hsl', 'hsla', 'color'\n * @param {array} color.values - [n,n,n] or [n,n,n,n]\n * @returns {string} A CSS color string\n */\nexport function recomposeColor(color) {\n const {\n type,\n colorSpace\n } = color;\n let {\n values\n } = color;\n if (type.indexOf('rgb') !== -1) {\n // Only convert the first 3 values to int (i.e. not alpha)\n values = values.map((n, i) => i < 3 ? parseInt(n, 10) : n);\n } else if (type.indexOf('hsl') !== -1) {\n values[1] = `${values[1]}%`;\n values[2] = `${values[2]}%`;\n }\n if (type.indexOf('color') !== -1) {\n values = `${colorSpace} ${values.join(' ')}`;\n } else {\n values = `${values.join(', ')}`;\n }\n return `${type}(${values})`;\n}\n\n/**\n * Converts a color from CSS rgb format to CSS hex format.\n * @param {string} color - RGB color, i.e. rgb(n, n, n)\n * @returns {string} A CSS rgb color string, i.e. #nnnnnn\n */\nexport function rgbToHex(color) {\n // Idempotent\n if (color.indexOf('#') === 0) {\n return color;\n }\n const {\n values\n } = decomposeColor(color);\n return `#${values.map((n, i) => intToHex(i === 3 ? Math.round(255 * n) : n)).join('')}`;\n}\n\n/**\n * Converts a color from hsl format to rgb format.\n * @param {string} color - HSL color values\n * @returns {string} rgb color values\n */\nexport function hslToRgb(color) {\n color = decomposeColor(color);\n const {\n values\n } = color;\n const h = values[0];\n const s = values[1] / 100;\n const l = values[2] / 100;\n const a = s * Math.min(l, 1 - l);\n const f = (n, k = (n + h / 30) % 12) => l - a * Math.max(Math.min(k - 3, 9 - k, 1), -1);\n let type = 'rgb';\n const rgb = [Math.round(f(0) * 255), Math.round(f(8) * 255), Math.round(f(4) * 255)];\n if (color.type === 'hsla') {\n type += 'a';\n rgb.push(values[3]);\n }\n return recomposeColor({\n type,\n values: rgb\n });\n}\n/**\n * The relative brightness of any point in a color space,\n * normalized to 0 for darkest black and 1 for lightest white.\n *\n * Formula: https://www.w3.org/TR/WCAG20-TECHS/G17.html#G17-tests\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @returns {number} The relative brightness of the color in the range 0 - 1\n */\nexport function getLuminance(color) {\n color = decomposeColor(color);\n let rgb = color.type === 'hsl' || color.type === 'hsla' ? decomposeColor(hslToRgb(color)).values : color.values;\n rgb = rgb.map(val => {\n if (color.type !== 'color') {\n val /= 255; // normalized\n }\n return val <= 0.03928 ? val / 12.92 : ((val + 0.055) / 1.055) ** 2.4;\n });\n\n // Truncate at 3 digits\n return Number((0.2126 * rgb[0] + 0.7152 * rgb[1] + 0.0722 * rgb[2]).toFixed(3));\n}\n\n/**\n * Calculates the contrast ratio between two colors.\n *\n * Formula: https://www.w3.org/TR/WCAG20-TECHS/G17.html#G17-tests\n * @param {string} foreground - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla()\n * @param {string} background - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla()\n * @returns {number} A contrast ratio value in the range 0 - 21.\n */\nexport function getContrastRatio(foreground, background) {\n const lumA = getLuminance(foreground);\n const lumB = getLuminance(background);\n return (Math.max(lumA, lumB) + 0.05) / (Math.min(lumA, lumB) + 0.05);\n}\n\n/**\n * Sets the absolute transparency of a color.\n * Any existing alpha values are overwritten.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} value - value to set the alpha channel to in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function alpha(color, value) {\n color = decomposeColor(color);\n value = clampWrapper(value);\n if (color.type === 'rgb' || color.type === 'hsl') {\n color.type += 'a';\n }\n if (color.type === 'color') {\n color.values[3] = `/${value}`;\n } else {\n color.values[3] = value;\n }\n return recomposeColor(color);\n}\nexport function private_safeAlpha(color, value, warning) {\n try {\n return alpha(color, value);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Darkens a color.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} coefficient - multiplier in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function darken(color, coefficient) {\n color = decomposeColor(color);\n coefficient = clampWrapper(coefficient);\n if (color.type.indexOf('hsl') !== -1) {\n color.values[2] *= 1 - coefficient;\n } else if (color.type.indexOf('rgb') !== -1 || color.type.indexOf('color') !== -1) {\n for (let i = 0; i < 3; i += 1) {\n color.values[i] *= 1 - coefficient;\n }\n }\n return recomposeColor(color);\n}\nexport function private_safeDarken(color, coefficient, warning) {\n try {\n return darken(color, coefficient);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Lightens a color.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} coefficient - multiplier in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function lighten(color, coefficient) {\n color = decomposeColor(color);\n coefficient = clampWrapper(coefficient);\n if (color.type.indexOf('hsl') !== -1) {\n color.values[2] += (100 - color.values[2]) * coefficient;\n } else if (color.type.indexOf('rgb') !== -1) {\n for (let i = 0; i < 3; i += 1) {\n color.values[i] += (255 - color.values[i]) * coefficient;\n }\n } else if (color.type.indexOf('color') !== -1) {\n for (let i = 0; i < 3; i += 1) {\n color.values[i] += (1 - color.values[i]) * coefficient;\n }\n }\n return recomposeColor(color);\n}\nexport function private_safeLighten(color, coefficient, warning) {\n try {\n return lighten(color, coefficient);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Darken or lighten a color, depending on its luminance.\n * Light colors are darkened, dark colors are lightened.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} coefficient=0.15 - multiplier in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function emphasize(color, coefficient = 0.15) {\n return getLuminance(color) > 0.5 ? darken(color, coefficient) : lighten(color, coefficient);\n}\nexport function private_safeEmphasize(color, coefficient, warning) {\n try {\n return emphasize(color, coefficient);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Blend a transparent overlay color with a background color, resulting in a single\n * RGB color.\n * @param {string} background - CSS color\n * @param {string} overlay - CSS color\n * @param {number} opacity - Opacity multiplier in the range 0 - 1\n * @param {number} [gamma=1.0] - Gamma correction factor. For gamma-correct blending, 2.2 is usual.\n */\nexport function blend(background, overlay, opacity, gamma = 1.0) {\n const blendChannel = (b, o) => Math.round((b ** (1 / gamma) * (1 - opacity) + o ** (1 / gamma) * opacity) ** gamma);\n const backgroundColor = decomposeColor(background);\n const overlayColor = decomposeColor(overlay);\n const rgb = [blendChannel(backgroundColor.values[0], overlayColor.values[0]), blendChannel(backgroundColor.values[1], overlayColor.values[1]), blendChannel(backgroundColor.values[2], overlayColor.values[2])];\n return recomposeColor({\n type: 'rgb',\n values: rgb\n });\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nexport default function createMixins(breakpoints, mixins) {\n return _extends({\n toolbar: {\n minHeight: 56,\n [breakpoints.up('xs')]: {\n '@media (orientation: landscape)': {\n minHeight: 48\n }\n },\n [breakpoints.up('sm')]: {\n minHeight: 64\n }\n }\n }, mixins);\n}","const common = {\n black: '#000',\n white: '#fff'\n};\nexport default common;","const grey = {\n 50: '#fafafa',\n 100: '#f5f5f5',\n 200: '#eeeeee',\n 300: '#e0e0e0',\n 400: '#bdbdbd',\n 500: '#9e9e9e',\n 600: '#757575',\n 700: '#616161',\n 800: '#424242',\n 900: '#212121',\n A100: '#f5f5f5',\n A200: '#eeeeee',\n A400: '#bdbdbd',\n A700: '#616161'\n};\nexport default grey;","const purple = {\n 50: '#f3e5f5',\n 100: '#e1bee7',\n 200: '#ce93d8',\n 300: '#ba68c8',\n 400: '#ab47bc',\n 500: '#9c27b0',\n 600: '#8e24aa',\n 700: '#7b1fa2',\n 800: '#6a1b9a',\n 900: '#4a148c',\n A100: '#ea80fc',\n A200: '#e040fb',\n A400: '#d500f9',\n A700: '#aa00ff'\n};\nexport default purple;","const red = {\n 50: '#ffebee',\n 100: '#ffcdd2',\n 200: '#ef9a9a',\n 300: '#e57373',\n 400: '#ef5350',\n 500: '#f44336',\n 600: '#e53935',\n 700: '#d32f2f',\n 800: '#c62828',\n 900: '#b71c1c',\n A100: '#ff8a80',\n A200: '#ff5252',\n A400: '#ff1744',\n A700: '#d50000'\n};\nexport default red;","const orange = {\n 50: '#fff3e0',\n 100: '#ffe0b2',\n 200: '#ffcc80',\n 300: '#ffb74d',\n 400: '#ffa726',\n 500: '#ff9800',\n 600: '#fb8c00',\n 700: '#f57c00',\n 800: '#ef6c00',\n 900: '#e65100',\n A100: '#ffd180',\n A200: '#ffab40',\n A400: '#ff9100',\n A700: '#ff6d00'\n};\nexport default orange;","const blue = {\n 50: '#e3f2fd',\n 100: '#bbdefb',\n 200: '#90caf9',\n 300: '#64b5f6',\n 400: '#42a5f5',\n 500: '#2196f3',\n 600: '#1e88e5',\n 700: '#1976d2',\n 800: '#1565c0',\n 900: '#0d47a1',\n A100: '#82b1ff',\n A200: '#448aff',\n A400: '#2979ff',\n A700: '#2962ff'\n};\nexport default blue;","const lightBlue = {\n 50: '#e1f5fe',\n 100: '#b3e5fc',\n 200: '#81d4fa',\n 300: '#4fc3f7',\n 400: '#29b6f6',\n 500: '#03a9f4',\n 600: '#039be5',\n 700: '#0288d1',\n 800: '#0277bd',\n 900: '#01579b',\n A100: '#80d8ff',\n A200: '#40c4ff',\n A400: '#00b0ff',\n A700: '#0091ea'\n};\nexport default lightBlue;","const green = {\n 50: '#e8f5e9',\n 100: '#c8e6c9',\n 200: '#a5d6a7',\n 300: '#81c784',\n 400: '#66bb6a',\n 500: '#4caf50',\n 600: '#43a047',\n 700: '#388e3c',\n 800: '#2e7d32',\n 900: '#1b5e20',\n A100: '#b9f6ca',\n A200: '#69f0ae',\n A400: '#00e676',\n A700: '#00c853'\n};\nexport default green;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\nconst _excluded = [\"mode\", \"contrastThreshold\", \"tonalOffset\"];\nimport { deepmerge } from '@mui/utils';\nimport { darken, getContrastRatio, lighten } from '@mui/system';\nimport common from '../colors/common';\nimport grey from '../colors/grey';\nimport purple from '../colors/purple';\nimport red from '../colors/red';\nimport orange from '../colors/orange';\nimport blue from '../colors/blue';\nimport lightBlue from '../colors/lightBlue';\nimport green from '../colors/green';\nexport const light = {\n // The colors used to style the text.\n text: {\n // The most important text.\n primary: 'rgba(0, 0, 0, 0.87)',\n // Secondary text.\n secondary: 'rgba(0, 0, 0, 0.6)',\n // Disabled text have even lower visual prominence.\n disabled: 'rgba(0, 0, 0, 0.38)'\n },\n // The color used to divide different elements.\n divider: 'rgba(0, 0, 0, 0.12)',\n // The background colors used to style the surfaces.\n // Consistency between these values is important.\n background: {\n paper: common.white,\n default: common.white\n },\n // The colors used to style the action elements.\n action: {\n // The color of an active action like an icon button.\n active: 'rgba(0, 0, 0, 0.54)',\n // The color of an hovered action.\n hover: 'rgba(0, 0, 0, 0.04)',\n hoverOpacity: 0.04,\n // The color of a selected action.\n selected: 'rgba(0, 0, 0, 0.08)',\n selectedOpacity: 0.08,\n // The color of a disabled action.\n disabled: 'rgba(0, 0, 0, 0.26)',\n // The background color of a disabled action.\n disabledBackground: 'rgba(0, 0, 0, 0.12)',\n disabledOpacity: 0.38,\n focus: 'rgba(0, 0, 0, 0.12)',\n focusOpacity: 0.12,\n activatedOpacity: 0.12\n }\n};\nexport const dark = {\n text: {\n primary: common.white,\n secondary: 'rgba(255, 255, 255, 0.7)',\n disabled: 'rgba(255, 255, 255, 0.5)',\n icon: 'rgba(255, 255, 255, 0.5)'\n },\n divider: 'rgba(255, 255, 255, 0.12)',\n background: {\n paper: '#121212',\n default: '#121212'\n },\n action: {\n active: common.white,\n hover: 'rgba(255, 255, 255, 0.08)',\n hoverOpacity: 0.08,\n selected: 'rgba(255, 255, 255, 0.16)',\n selectedOpacity: 0.16,\n disabled: 'rgba(255, 255, 255, 0.3)',\n disabledBackground: 'rgba(255, 255, 255, 0.12)',\n disabledOpacity: 0.38,\n focus: 'rgba(255, 255, 255, 0.12)',\n focusOpacity: 0.12,\n activatedOpacity: 0.24\n }\n};\nfunction addLightOrDark(intent, direction, shade, tonalOffset) {\n const tonalOffsetLight = tonalOffset.light || tonalOffset;\n const tonalOffsetDark = tonalOffset.dark || tonalOffset * 1.5;\n if (!intent[direction]) {\n if (intent.hasOwnProperty(shade)) {\n intent[direction] = intent[shade];\n } else if (direction === 'light') {\n intent.light = lighten(intent.main, tonalOffsetLight);\n } else if (direction === 'dark') {\n intent.dark = darken(intent.main, tonalOffsetDark);\n }\n }\n}\nfunction getDefaultPrimary(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: blue[200],\n light: blue[50],\n dark: blue[400]\n };\n }\n return {\n main: blue[700],\n light: blue[400],\n dark: blue[800]\n };\n}\nfunction getDefaultSecondary(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: purple[200],\n light: purple[50],\n dark: purple[400]\n };\n }\n return {\n main: purple[500],\n light: purple[300],\n dark: purple[700]\n };\n}\nfunction getDefaultError(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: red[500],\n light: red[300],\n dark: red[700]\n };\n }\n return {\n main: red[700],\n light: red[400],\n dark: red[800]\n };\n}\nfunction getDefaultInfo(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: lightBlue[400],\n light: lightBlue[300],\n dark: lightBlue[700]\n };\n }\n return {\n main: lightBlue[700],\n light: lightBlue[500],\n dark: lightBlue[900]\n };\n}\nfunction getDefaultSuccess(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: green[400],\n light: green[300],\n dark: green[700]\n };\n }\n return {\n main: green[800],\n light: green[500],\n dark: green[900]\n };\n}\nfunction getDefaultWarning(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: orange[400],\n light: orange[300],\n dark: orange[700]\n };\n }\n return {\n main: '#ed6c02',\n // closest to orange[800] that pass 3:1.\n light: orange[500],\n dark: orange[900]\n };\n}\nexport default function createPalette(palette) {\n const {\n mode = 'light',\n contrastThreshold = 3,\n tonalOffset = 0.2\n } = palette,\n other = _objectWithoutPropertiesLoose(palette, _excluded);\n const primary = palette.primary || getDefaultPrimary(mode);\n const secondary = palette.secondary || getDefaultSecondary(mode);\n const error = palette.error || getDefaultError(mode);\n const info = palette.info || getDefaultInfo(mode);\n const success = palette.success || getDefaultSuccess(mode);\n const warning = palette.warning || getDefaultWarning(mode);\n\n // Use the same logic as\n // Bootstrap: https://github.com/twbs/bootstrap/blob/1d6e3710dd447de1a200f29e8fa521f8a0908f70/scss/_functions.scss#L59\n // and material-components-web https://github.com/material-components/material-components-web/blob/ac46b8863c4dab9fc22c4c662dc6bd1b65dd652f/packages/mdc-theme/_functions.scss#L54\n function getContrastText(background) {\n const contrastText = getContrastRatio(background, dark.text.primary) >= contrastThreshold ? dark.text.primary : light.text.primary;\n if (process.env.NODE_ENV !== 'production') {\n const contrast = getContrastRatio(background, contrastText);\n if (contrast < 3) {\n console.error([`MUI: The contrast ratio of ${contrast}:1 for ${contrastText} on ${background}`, 'falls below the WCAG recommended absolute minimum contrast ratio of 3:1.', 'https://www.w3.org/TR/2008/REC-WCAG20-20081211/#visual-audio-contrast-contrast'].join('\\n'));\n }\n }\n return contrastText;\n }\n const augmentColor = ({\n color,\n name,\n mainShade = 500,\n lightShade = 300,\n darkShade = 700\n }) => {\n color = _extends({}, color);\n if (!color.main && color[mainShade]) {\n color.main = color[mainShade];\n }\n if (!color.hasOwnProperty('main')) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: The color${name ? ` (${name})` : ''} provided to augmentColor(color) is invalid.\nThe color object needs to have a \\`main\\` property or a \\`${mainShade}\\` property.` : _formatMuiErrorMessage(11, name ? ` (${name})` : '', mainShade));\n }\n if (typeof color.main !== 'string') {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: The color${name ? ` (${name})` : ''} provided to augmentColor(color) is invalid.\n\\`color.main\\` should be a string, but \\`${JSON.stringify(color.main)}\\` was provided instead.\n\nDid you intend to use one of the following approaches?\n\nimport { green } from \"@mui/material/colors\";\n\nconst theme1 = createTheme({ palette: {\n primary: green,\n} });\n\nconst theme2 = createTheme({ palette: {\n primary: { main: green[500] },\n} });` : _formatMuiErrorMessage(12, name ? ` (${name})` : '', JSON.stringify(color.main)));\n }\n addLightOrDark(color, 'light', lightShade, tonalOffset);\n addLightOrDark(color, 'dark', darkShade, tonalOffset);\n if (!color.contrastText) {\n color.contrastText = getContrastText(color.main);\n }\n return color;\n };\n const modes = {\n dark,\n light\n };\n if (process.env.NODE_ENV !== 'production') {\n if (!modes[mode]) {\n console.error(`MUI: The palette mode \\`${mode}\\` is not supported.`);\n }\n }\n const paletteOutput = deepmerge(_extends({\n // A collection of common colors.\n common: _extends({}, common),\n // prevent mutable object.\n // The palette mode, can be light or dark.\n mode,\n // The colors used to represent primary interface elements for a user.\n primary: augmentColor({\n color: primary,\n name: 'primary'\n }),\n // The colors used to represent secondary interface elements for a user.\n secondary: augmentColor({\n color: secondary,\n name: 'secondary',\n mainShade: 'A400',\n lightShade: 'A200',\n darkShade: 'A700'\n }),\n // The colors used to represent interface elements that the user should be made aware of.\n error: augmentColor({\n color: error,\n name: 'error'\n }),\n // The colors used to represent potentially dangerous actions or important messages.\n warning: augmentColor({\n color: warning,\n name: 'warning'\n }),\n // The colors used to present information to the user that is neutral and not necessarily important.\n info: augmentColor({\n color: info,\n name: 'info'\n }),\n // The colors used to indicate the successful completion of an action that user triggered.\n success: augmentColor({\n color: success,\n name: 'success'\n }),\n // The grey colors.\n grey,\n // Used by `getContrastText()` to maximize the contrast between\n // the background and the text.\n contrastThreshold,\n // Takes a background color and returns the text color that maximizes the contrast.\n getContrastText,\n // Generate a rich color object.\n augmentColor,\n // Used by the functions below to shift a color's luminance by approximately\n // two indexes within its tonal palette.\n // E.g., shift from Red 500 to Red 300 or Red 700.\n tonalOffset\n }, modes[mode]), other);\n return paletteOutput;\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"fontFamily\", \"fontSize\", \"fontWeightLight\", \"fontWeightRegular\", \"fontWeightMedium\", \"fontWeightBold\", \"htmlFontSize\", \"allVariants\", \"pxToRem\"];\nimport { deepmerge } from '@mui/utils';\nfunction round(value) {\n return Math.round(value * 1e5) / 1e5;\n}\nconst caseAllCaps = {\n textTransform: 'uppercase'\n};\nconst defaultFontFamily = '\"Roboto\", \"Helvetica\", \"Arial\", sans-serif';\n\n/**\n * @see @link{https://m2.material.io/design/typography/the-type-system.html}\n * @see @link{https://m2.material.io/design/typography/understanding-typography.html}\n */\nexport default function createTypography(palette, typography) {\n const _ref = typeof typography === 'function' ? typography(palette) : typography,\n {\n fontFamily = defaultFontFamily,\n // The default font size of the Material Specification.\n fontSize = 14,\n // px\n fontWeightLight = 300,\n fontWeightRegular = 400,\n fontWeightMedium = 500,\n fontWeightBold = 700,\n // Tell MUI what's the font-size on the html element.\n // 16px is the default font-size used by browsers.\n htmlFontSize = 16,\n // Apply the CSS properties to all the variants.\n allVariants,\n pxToRem: pxToRem2\n } = _ref,\n other = _objectWithoutPropertiesLoose(_ref, _excluded);\n if (process.env.NODE_ENV !== 'production') {\n if (typeof fontSize !== 'number') {\n console.error('MUI: `fontSize` is required to be a number.');\n }\n if (typeof htmlFontSize !== 'number') {\n console.error('MUI: `htmlFontSize` is required to be a number.');\n }\n }\n const coef = fontSize / 14;\n const pxToRem = pxToRem2 || (size => `${size / htmlFontSize * coef}rem`);\n const buildVariant = (fontWeight, size, lineHeight, letterSpacing, casing) => _extends({\n fontFamily,\n fontWeight,\n fontSize: pxToRem(size),\n // Unitless following https://meyerweb.com/eric/thoughts/2006/02/08/unitless-line-heights/\n lineHeight\n }, fontFamily === defaultFontFamily ? {\n letterSpacing: `${round(letterSpacing / size)}em`\n } : {}, casing, allVariants);\n const variants = {\n h1: buildVariant(fontWeightLight, 96, 1.167, -1.5),\n h2: buildVariant(fontWeightLight, 60, 1.2, -0.5),\n h3: buildVariant(fontWeightRegular, 48, 1.167, 0),\n h4: buildVariant(fontWeightRegular, 34, 1.235, 0.25),\n h5: buildVariant(fontWeightRegular, 24, 1.334, 0),\n h6: buildVariant(fontWeightMedium, 20, 1.6, 0.15),\n subtitle1: buildVariant(fontWeightRegular, 16, 1.75, 0.15),\n subtitle2: buildVariant(fontWeightMedium, 14, 1.57, 0.1),\n body1: buildVariant(fontWeightRegular, 16, 1.5, 0.15),\n body2: buildVariant(fontWeightRegular, 14, 1.43, 0.15),\n button: buildVariant(fontWeightMedium, 14, 1.75, 0.4, caseAllCaps),\n caption: buildVariant(fontWeightRegular, 12, 1.66, 0.4),\n overline: buildVariant(fontWeightRegular, 12, 2.66, 1, caseAllCaps),\n // TODO v6: Remove handling of 'inherit' variant from the theme as it is already handled in Material UI's Typography component. Also, remember to remove the associated types.\n inherit: {\n fontFamily: 'inherit',\n fontWeight: 'inherit',\n fontSize: 'inherit',\n lineHeight: 'inherit',\n letterSpacing: 'inherit'\n }\n };\n return deepmerge(_extends({\n htmlFontSize,\n pxToRem,\n fontFamily,\n fontSize,\n fontWeightLight,\n fontWeightRegular,\n fontWeightMedium,\n fontWeightBold\n }, variants), other, {\n clone: false // No need to clone deep\n });\n}","const shadowKeyUmbraOpacity = 0.2;\nconst shadowKeyPenumbraOpacity = 0.14;\nconst shadowAmbientShadowOpacity = 0.12;\nfunction createShadow(...px) {\n return [`${px[0]}px ${px[1]}px ${px[2]}px ${px[3]}px rgba(0,0,0,${shadowKeyUmbraOpacity})`, `${px[4]}px ${px[5]}px ${px[6]}px ${px[7]}px rgba(0,0,0,${shadowKeyPenumbraOpacity})`, `${px[8]}px ${px[9]}px ${px[10]}px ${px[11]}px rgba(0,0,0,${shadowAmbientShadowOpacity})`].join(',');\n}\n\n// Values from https://github.com/material-components/material-components-web/blob/be8747f94574669cb5e7add1a7c54fa41a89cec7/packages/mdc-elevation/_variables.scss\nconst shadows = ['none', createShadow(0, 2, 1, -1, 0, 1, 1, 0, 0, 1, 3, 0), createShadow(0, 3, 1, -2, 0, 2, 2, 0, 0, 1, 5, 0), createShadow(0, 3, 3, -2, 0, 3, 4, 0, 0, 1, 8, 0), createShadow(0, 2, 4, -1, 0, 4, 5, 0, 0, 1, 10, 0), createShadow(0, 3, 5, -1, 0, 5, 8, 0, 0, 1, 14, 0), createShadow(0, 3, 5, -1, 0, 6, 10, 0, 0, 1, 18, 0), createShadow(0, 4, 5, -2, 0, 7, 10, 1, 0, 2, 16, 1), createShadow(0, 5, 5, -3, 0, 8, 10, 1, 0, 3, 14, 2), createShadow(0, 5, 6, -3, 0, 9, 12, 1, 0, 3, 16, 2), createShadow(0, 6, 6, -3, 0, 10, 14, 1, 0, 4, 18, 3), createShadow(0, 6, 7, -4, 0, 11, 15, 1, 0, 4, 20, 3), createShadow(0, 7, 8, -4, 0, 12, 17, 2, 0, 5, 22, 4), createShadow(0, 7, 8, -4, 0, 13, 19, 2, 0, 5, 24, 4), createShadow(0, 7, 9, -4, 0, 14, 21, 2, 0, 5, 26, 4), createShadow(0, 8, 9, -5, 0, 15, 22, 2, 0, 6, 28, 5), createShadow(0, 8, 10, -5, 0, 16, 24, 2, 0, 6, 30, 5), createShadow(0, 8, 11, -5, 0, 17, 26, 2, 0, 6, 32, 5), createShadow(0, 9, 11, -5, 0, 18, 28, 2, 0, 7, 34, 6), createShadow(0, 9, 12, -6, 0, 19, 29, 2, 0, 7, 36, 6), createShadow(0, 10, 13, -6, 0, 20, 31, 3, 0, 8, 38, 7), createShadow(0, 10, 13, -6, 0, 21, 33, 3, 0, 8, 40, 7), createShadow(0, 10, 14, -6, 0, 22, 35, 3, 0, 8, 42, 7), createShadow(0, 11, 14, -7, 0, 23, 36, 3, 0, 9, 44, 8), createShadow(0, 11, 15, -7, 0, 24, 38, 3, 0, 9, 46, 8)];\nexport default shadows;","import _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nconst _excluded = [\"duration\", \"easing\", \"delay\"];\n// Follow https://material.google.com/motion/duration-easing.html#duration-easing-natural-easing-curves\n// to learn the context in which each easing should be used.\nexport const easing = {\n // This is the most common easing curve.\n easeInOut: 'cubic-bezier(0.4, 0, 0.2, 1)',\n // Objects enter the screen at full velocity from off-screen and\n // slowly decelerate to a resting point.\n easeOut: 'cubic-bezier(0.0, 0, 0.2, 1)',\n // Objects leave the screen at full velocity. They do not decelerate when off-screen.\n easeIn: 'cubic-bezier(0.4, 0, 1, 1)',\n // The sharp curve is used by objects that may return to the screen at any time.\n sharp: 'cubic-bezier(0.4, 0, 0.6, 1)'\n};\n\n// Follow https://m2.material.io/guidelines/motion/duration-easing.html#duration-easing-common-durations\n// to learn when use what timing\nexport const duration = {\n shortest: 150,\n shorter: 200,\n short: 250,\n // most basic recommended timing\n standard: 300,\n // this is to be used in complex animations\n complex: 375,\n // recommended when something is entering screen\n enteringScreen: 225,\n // recommended when something is leaving screen\n leavingScreen: 195\n};\nfunction formatMs(milliseconds) {\n return `${Math.round(milliseconds)}ms`;\n}\nfunction getAutoHeightDuration(height) {\n if (!height) {\n return 0;\n }\n const constant = height / 36;\n\n // https://www.wolframalpha.com/input/?i=(4+%2B+15+*+(x+%2F+36+)+**+0.25+%2B+(x+%2F+36)+%2F+5)+*+10\n return Math.round((4 + 15 * constant ** 0.25 + constant / 5) * 10);\n}\nexport default function createTransitions(inputTransitions) {\n const mergedEasing = _extends({}, easing, inputTransitions.easing);\n const mergedDuration = _extends({}, duration, inputTransitions.duration);\n const create = (props = ['all'], options = {}) => {\n const {\n duration: durationOption = mergedDuration.standard,\n easing: easingOption = mergedEasing.easeInOut,\n delay = 0\n } = options,\n other = _objectWithoutPropertiesLoose(options, _excluded);\n if (process.env.NODE_ENV !== 'production') {\n const isString = value => typeof value === 'string';\n // IE11 support, replace with Number.isNaN\n // eslint-disable-next-line no-restricted-globals\n const isNumber = value => !isNaN(parseFloat(value));\n if (!isString(props) && !Array.isArray(props)) {\n console.error('MUI: Argument \"props\" must be a string or Array.');\n }\n if (!isNumber(durationOption) && !isString(durationOption)) {\n console.error(`MUI: Argument \"duration\" must be a number or a string but found ${durationOption}.`);\n }\n if (!isString(easingOption)) {\n console.error('MUI: Argument \"easing\" must be a string.');\n }\n if (!isNumber(delay) && !isString(delay)) {\n console.error('MUI: Argument \"delay\" must be a number or a string.');\n }\n if (typeof options !== 'object') {\n console.error(['MUI: Secong argument of transition.create must be an object.', \"Arguments should be either `create('prop1', options)` or `create(['prop1', 'prop2'], options)`\"].join('\\n'));\n }\n if (Object.keys(other).length !== 0) {\n console.error(`MUI: Unrecognized argument(s) [${Object.keys(other).join(',')}].`);\n }\n }\n return (Array.isArray(props) ? props : [props]).map(animatedProp => `${animatedProp} ${typeof durationOption === 'string' ? durationOption : formatMs(durationOption)} ${easingOption} ${typeof delay === 'string' ? delay : formatMs(delay)}`).join(',');\n };\n return _extends({\n getAutoHeightDuration,\n create\n }, inputTransitions, {\n easing: mergedEasing,\n duration: mergedDuration\n });\n}","// We need to centralize the zIndex definitions as they work\n// like global values in the browser.\nconst zIndex = {\n mobileStepper: 1000,\n fab: 1050,\n speedDial: 1050,\n appBar: 1100,\n drawer: 1200,\n modal: 1300,\n snackbar: 1400,\n tooltip: 1500\n};\nexport default zIndex;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\nconst _excluded = [\"breakpoints\", \"mixins\", \"spacing\", \"palette\", \"transitions\", \"typography\", \"shape\"];\nimport { deepmerge } from '@mui/utils';\nimport { createTheme as systemCreateTheme, unstable_defaultSxConfig as defaultSxConfig, unstable_styleFunctionSx as styleFunctionSx } from '@mui/system';\nimport generateUtilityClass from '@mui/utils/generateUtilityClass';\nimport createMixins from './createMixins';\nimport createPalette from './createPalette';\nimport createTypography from './createTypography';\nimport shadows from './shadows';\nimport createTransitions from './createTransitions';\nimport zIndex from './zIndex';\nfunction createTheme(options = {}, ...args) {\n const {\n mixins: mixinsInput = {},\n palette: paletteInput = {},\n transitions: transitionsInput = {},\n typography: typographyInput = {}\n } = options,\n other = _objectWithoutPropertiesLoose(options, _excluded);\n if (options.vars) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: \\`vars\\` is a private field used for CSS variables support.\nPlease use another name.` : _formatMuiErrorMessage(18));\n }\n const palette = createPalette(paletteInput);\n const systemTheme = systemCreateTheme(options);\n let muiTheme = deepmerge(systemTheme, {\n mixins: createMixins(systemTheme.breakpoints, mixinsInput),\n palette,\n // Don't use [...shadows] until you've verified its transpiled code is not invoking the iterator protocol.\n shadows: shadows.slice(),\n typography: createTypography(palette, typographyInput),\n transitions: createTransitions(transitionsInput),\n zIndex: _extends({}, zIndex)\n });\n muiTheme = deepmerge(muiTheme, other);\n muiTheme = args.reduce((acc, argument) => deepmerge(acc, argument), muiTheme);\n if (process.env.NODE_ENV !== 'production') {\n // TODO v6: Refactor to use globalStateClassesMapping from @mui/utils once `readOnly` state class is used in Rating component.\n const stateClasses = ['active', 'checked', 'completed', 'disabled', 'error', 'expanded', 'focused', 'focusVisible', 'required', 'selected'];\n const traverse = (node, component) => {\n let key;\n\n // eslint-disable-next-line guard-for-in, no-restricted-syntax\n for (key in node) {\n const child = node[key];\n if (stateClasses.indexOf(key) !== -1 && Object.keys(child).length > 0) {\n if (process.env.NODE_ENV !== 'production') {\n const stateClass = generateUtilityClass('', key);\n console.error([`MUI: The \\`${component}\\` component increases ` + `the CSS specificity of the \\`${key}\\` internal state.`, 'You can not override it like this: ', JSON.stringify(node, null, 2), '', `Instead, you need to use the '&.${stateClass}' syntax:`, JSON.stringify({\n root: {\n [`&.${stateClass}`]: child\n }\n }, null, 2), '', 'https://mui.com/r/state-classes-guide'].join('\\n'));\n }\n // Remove the style to prevent global conflicts.\n node[key] = {};\n }\n }\n };\n Object.keys(muiTheme.components).forEach(component => {\n const styleOverrides = muiTheme.components[component].styleOverrides;\n if (styleOverrides && component.indexOf('Mui') === 0) {\n traverse(styleOverrides, component);\n }\n });\n }\n muiTheme.unstable_sxConfig = _extends({}, defaultSxConfig, other == null ? void 0 : other.unstable_sxConfig);\n muiTheme.unstable_sx = function sx(props) {\n return styleFunctionSx({\n sx: props,\n theme: this\n });\n };\n return muiTheme;\n}\nlet warnedOnce = false;\nexport function createMuiTheme(...args) {\n if (process.env.NODE_ENV !== 'production') {\n if (!warnedOnce) {\n warnedOnce = true;\n console.error(['MUI: the createMuiTheme function was renamed to createTheme.', '', \"You should use `import { createTheme } from '@mui/material/styles'`\"].join('\\n'));\n }\n }\n return createTheme(...args);\n}\nexport default createTheme;","'use client';\n\nimport createTheme from './createTheme';\nconst defaultTheme = createTheme();\nexport default defaultTheme;","export default '$$material';","'use client';\n\nimport { useThemeProps as systemUseThemeProps } from '@mui/system';\nimport defaultTheme from './defaultTheme';\nimport THEME_ID from './identifier';\nexport default function useThemeProps({\n props,\n name\n}) {\n return systemUseThemeProps({\n props,\n name,\n defaultTheme,\n themeId: THEME_ID\n });\n}","'use client';\n\nimport { createStyled, shouldForwardProp } from '@mui/system';\nimport defaultTheme from './defaultTheme';\nimport THEME_ID from './identifier';\nexport const rootShouldForwardProp = prop => shouldForwardProp(prop) && prop !== 'classes';\nexport const slotShouldForwardProp = shouldForwardProp;\nconst styled = createStyled({\n themeId: THEME_ID,\n defaultTheme,\n rootShouldForwardProp\n});\nexport default styled;","import generateUtilityClasses from '@mui/utils/generateUtilityClasses';\nimport generateUtilityClass from '@mui/utils/generateUtilityClass';\nexport function getSvgIconUtilityClass(slot) {\n return generateUtilityClass('MuiSvgIcon', slot);\n}\nconst svgIconClasses = generateUtilityClasses('MuiSvgIcon', ['root', 'colorPrimary', 'colorSecondary', 'colorAction', 'colorError', 'colorDisabled', 'fontSizeInherit', 'fontSizeSmall', 'fontSizeMedium', 'fontSizeLarge']);\nexport default svgIconClasses;","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"children\", \"className\", \"color\", \"component\", \"fontSize\", \"htmlColor\", \"inheritViewBox\", \"titleAccess\", \"viewBox\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport clsx from 'clsx';\nimport { unstable_composeClasses as composeClasses } from '@mui/base/composeClasses';\nimport capitalize from '../utils/capitalize';\nimport useThemeProps from '../styles/useThemeProps';\nimport styled from '../styles/styled';\nimport { getSvgIconUtilityClass } from './svgIconClasses';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nimport { jsxs as _jsxs } from \"react/jsx-runtime\";\nconst useUtilityClasses = ownerState => {\n const {\n color,\n fontSize,\n classes\n } = ownerState;\n const slots = {\n root: ['root', color !== 'inherit' && `color${capitalize(color)}`, `fontSize${capitalize(fontSize)}`]\n };\n return composeClasses(slots, getSvgIconUtilityClass, classes);\n};\nconst SvgIconRoot = styled('svg', {\n name: 'MuiSvgIcon',\n slot: 'Root',\n overridesResolver: (props, styles) => {\n const {\n ownerState\n } = props;\n return [styles.root, ownerState.color !== 'inherit' && styles[`color${capitalize(ownerState.color)}`], styles[`fontSize${capitalize(ownerState.fontSize)}`]];\n }\n})(({\n theme,\n ownerState\n}) => {\n var _theme$transitions, _theme$transitions$cr, _theme$transitions2, _theme$typography, _theme$typography$pxT, _theme$typography2, _theme$typography2$px, _theme$typography3, _theme$typography3$px, _palette$ownerState$c, _palette, _palette2, _palette3;\n return {\n userSelect: 'none',\n width: '1em',\n height: '1em',\n display: 'inline-block',\n // the will define the property that has `currentColor`\n // e.g. heroicons uses fill=\"none\" and stroke=\"currentColor\"\n fill: ownerState.hasSvgAsChild ? undefined : 'currentColor',\n flexShrink: 0,\n transition: (_theme$transitions = theme.transitions) == null || (_theme$transitions$cr = _theme$transitions.create) == null ? void 0 : _theme$transitions$cr.call(_theme$transitions, 'fill', {\n duration: (_theme$transitions2 = theme.transitions) == null || (_theme$transitions2 = _theme$transitions2.duration) == null ? void 0 : _theme$transitions2.shorter\n }),\n fontSize: {\n inherit: 'inherit',\n small: ((_theme$typography = theme.typography) == null || (_theme$typography$pxT = _theme$typography.pxToRem) == null ? void 0 : _theme$typography$pxT.call(_theme$typography, 20)) || '1.25rem',\n medium: ((_theme$typography2 = theme.typography) == null || (_theme$typography2$px = _theme$typography2.pxToRem) == null ? void 0 : _theme$typography2$px.call(_theme$typography2, 24)) || '1.5rem',\n large: ((_theme$typography3 = theme.typography) == null || (_theme$typography3$px = _theme$typography3.pxToRem) == null ? void 0 : _theme$typography3$px.call(_theme$typography3, 35)) || '2.1875rem'\n }[ownerState.fontSize],\n // TODO v5 deprecate, v6 remove for sx\n color: (_palette$ownerState$c = (_palette = (theme.vars || theme).palette) == null || (_palette = _palette[ownerState.color]) == null ? void 0 : _palette.main) != null ? _palette$ownerState$c : {\n action: (_palette2 = (theme.vars || theme).palette) == null || (_palette2 = _palette2.action) == null ? void 0 : _palette2.active,\n disabled: (_palette3 = (theme.vars || theme).palette) == null || (_palette3 = _palette3.action) == null ? void 0 : _palette3.disabled,\n inherit: undefined\n }[ownerState.color]\n };\n});\nconst SvgIcon = /*#__PURE__*/React.forwardRef(function SvgIcon(inProps, ref) {\n const props = useThemeProps({\n props: inProps,\n name: 'MuiSvgIcon'\n });\n const {\n children,\n className,\n color = 'inherit',\n component = 'svg',\n fontSize = 'medium',\n htmlColor,\n inheritViewBox = false,\n titleAccess,\n viewBox = '0 0 24 24'\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const hasSvgAsChild = /*#__PURE__*/React.isValidElement(children) && children.type === 'svg';\n const ownerState = _extends({}, props, {\n color,\n component,\n fontSize,\n instanceFontSize: inProps.fontSize,\n inheritViewBox,\n viewBox,\n hasSvgAsChild\n });\n const more = {};\n if (!inheritViewBox) {\n more.viewBox = viewBox;\n }\n const classes = useUtilityClasses(ownerState);\n return /*#__PURE__*/_jsxs(SvgIconRoot, _extends({\n as: component,\n className: clsx(classes.root, className),\n focusable: \"false\",\n color: htmlColor,\n \"aria-hidden\": titleAccess ? undefined : true,\n role: titleAccess ? 'img' : undefined,\n ref: ref\n }, more, other, hasSvgAsChild && children.props, {\n ownerState: ownerState,\n children: [hasSvgAsChild ? children.props.children : children, titleAccess ? /*#__PURE__*/_jsx(\"title\", {\n children: titleAccess\n }) : null]\n }));\n});\nprocess.env.NODE_ENV !== \"production\" ? SvgIcon.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the d.ts file and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * Node passed into the SVG element.\n */\n children: PropTypes.node,\n /**\n * Override or extend the styles applied to the component.\n */\n classes: PropTypes.object,\n /**\n * @ignore\n */\n className: PropTypes.string,\n /**\n * The color of the component.\n * It supports both default and custom theme colors, which can be added as shown in the\n * [palette customization guide](https://mui.com/material-ui/customization/palette/#custom-colors).\n * You can use the `htmlColor` prop to apply a color attribute to the SVG element.\n * @default 'inherit'\n */\n color: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.oneOf(['inherit', 'action', 'disabled', 'primary', 'secondary', 'error', 'info', 'success', 'warning']), PropTypes.string]),\n /**\n * The component used for the root node.\n * Either a string to use a HTML element or a component.\n */\n component: PropTypes.elementType,\n /**\n * The fontSize applied to the icon. Defaults to 24px, but can be configure to inherit font size.\n * @default 'medium'\n */\n fontSize: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.oneOf(['inherit', 'large', 'medium', 'small']), PropTypes.string]),\n /**\n * Applies a color attribute to the SVG element.\n */\n htmlColor: PropTypes.string,\n /**\n * If `true`, the root node will inherit the custom `component`'s viewBox and the `viewBox`\n * prop will be ignored.\n * Useful when you want to reference a custom `component` and have `SvgIcon` pass that\n * `component`'s viewBox to the root node.\n * @default false\n */\n inheritViewBox: PropTypes.bool,\n /**\n * The shape-rendering attribute. The behavior of the different options is described on the\n * [MDN Web Docs](https://developer.mozilla.org/en-US/docs/Web/SVG/Attribute/shape-rendering).\n * If you are having issues with blurry icons you should investigate this prop.\n */\n shapeRendering: PropTypes.string,\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Provides a human-readable title for the element that contains it.\n * https://www.w3.org/TR/SVG-access/#Equivalent\n */\n titleAccess: PropTypes.string,\n /**\n * Allows you to redefine what the coordinates without units mean inside an SVG element.\n * For example, if the SVG element is 500 (width) by 200 (height),\n * and you pass viewBox=\"0 0 50 20\",\n * this means that the coordinates inside the SVG will go from the top left corner (0,0)\n * to bottom right (50,20) and each unit will be worth 10px.\n * @default '0 0 24 24'\n */\n viewBox: PropTypes.string\n} : void 0;\nSvgIcon.muiName = 'SvgIcon';\nexport default SvgIcon;","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport * as React from 'react';\nimport SvgIcon from '../SvgIcon';\n\n/**\n * Private module reserved for @mui packages.\n */\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nexport default function createSvgIcon(path, displayName) {\n function Component(props, ref) {\n return /*#__PURE__*/_jsx(SvgIcon, _extends({\n \"data-testid\": `${displayName}Icon`,\n ref: ref\n }, props, {\n children: path\n }));\n }\n if (process.env.NODE_ENV !== 'production') {\n // Need to set `displayName` on the inner component for React.memo.\n // React prior to 16.14 ignores `displayName` on the wrapper.\n Component.displayName = `${displayName}Icon`;\n }\n Component.muiName = SvgIcon.muiName;\n return /*#__PURE__*/React.memo( /*#__PURE__*/React.forwardRef(Component));\n}","'use client';\n\nimport { unstable_ClassNameGenerator as ClassNameGenerator } from '@mui/base/ClassNameGenerator';\nexport { default as capitalize } from './capitalize';\nexport { default as createChainedFunction } from './createChainedFunction';\nexport { default as createSvgIcon } from './createSvgIcon';\nexport { default as debounce } from './debounce';\nexport { default as deprecatedPropType } from './deprecatedPropType';\nexport { default as isMuiElement } from './isMuiElement';\nexport { default as ownerDocument } from './ownerDocument';\nexport { default as ownerWindow } from './ownerWindow';\nexport { default as requirePropFactory } from './requirePropFactory';\nexport { default as setRef } from './setRef';\nexport { default as unstable_useEnhancedEffect } from './useEnhancedEffect';\nexport { default as unstable_useId } from './useId';\nexport { default as unsupportedProp } from './unsupportedProp';\nexport { default as useControlled } from './useControlled';\nexport { default as useEventCallback } from './useEventCallback';\nexport { default as useForkRef } from './useForkRef';\nexport { default as useIsFocusVisible } from './useIsFocusVisible';\n// TODO: remove this export once ClassNameGenerator is stable\n// eslint-disable-next-line @typescript-eslint/naming-convention\nexport const unstable_ClassNameGenerator = {\n configure: generator => {\n if (process.env.NODE_ENV !== 'production') {\n console.warn(['MUI: `ClassNameGenerator` import from `@mui/material/utils` is outdated and might cause unexpected issues.', '', \"You should use `import { unstable_ClassNameGenerator } from '@mui/material/className'` instead\", '', 'The detail of the issue: https://github.com/mui/material-ui/issues/30011#issuecomment-1024993401', '', 'The updated documentation: https://mui.com/guides/classname-generator/'].join('\\n'));\n }\n ClassNameGenerator.configure(generator);\n }\n};","\"use strict\";\n'use client';\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nObject.defineProperty(exports, \"default\", {\n enumerable: true,\n get: function () {\n return _utils.createSvgIcon;\n }\n});\nvar _utils = require(\"@mui/material/utils\");","\"use strict\";\n\"use client\";\n\nvar _interopRequireDefault = require(\"@babel/runtime/helpers/interopRequireDefault\");\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = void 0;\nvar _createSvgIcon = _interopRequireDefault(require(\"./utils/createSvgIcon\"));\nvar _jsxRuntime = require(\"react/jsx-runtime\");\nvar _default = exports.default = (0, _createSvgIcon.default)( /*#__PURE__*/(0, _jsxRuntime.jsx)(\"path\", {\n d: \"m10 17 5-5-5-5z\"\n}), 'ArrowRight');","/**\n * Determines if a given element is a DOM element name (i.e. not a React component).\n */\nexport function isHostComponent(element) {\n return typeof element === 'string';\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport { isHostComponent } from './isHostComponent';\n\n/**\n * Type of the ownerState based on the type of an element it applies to.\n * This resolves to the provided OwnerState for React components and `undefined` for host components.\n * Falls back to `OwnerState | undefined` when the exact type can't be determined in development time.\n */\n\n/**\n * Appends the ownerState object to the props, merging with the existing one if necessary.\n *\n * @param elementType Type of the element that owns the `existingProps`. If the element is a DOM node or undefined, `ownerState` is not applied.\n * @param otherProps Props of the element.\n * @param ownerState\n */\nexport function appendOwnerState(elementType, otherProps, ownerState) {\n if (elementType === undefined || isHostComponent(elementType)) {\n return otherProps;\n }\n return _extends({}, otherProps, {\n ownerState: _extends({}, otherProps.ownerState, ownerState)\n });\n}","'use client';\n\nimport * as React from 'react';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nconst defaultContextValue = {\n disableDefaultClasses: false\n};\nconst ClassNameConfiguratorContext = /*#__PURE__*/React.createContext(defaultContextValue);\n/**\n * @ignore - internal hook.\n *\n * Wraps the `generateUtilityClass` function and controls how the classes are generated.\n * Currently it only affects whether the classes are applied or not.\n *\n * @returns Function to be called with the `generateUtilityClass` function specific to a component to generate the classes.\n */\nexport function useClassNamesOverride(generateUtilityClass) {\n const {\n disableDefaultClasses\n } = React.useContext(ClassNameConfiguratorContext);\n return slot => {\n if (disableDefaultClasses) {\n return '';\n }\n return generateUtilityClass(slot);\n };\n}\n\n/**\n * Allows to configure the components within to not apply any built-in classes.\n */\nexport function ClassNameConfigurator(props) {\n const {\n disableDefaultClasses,\n children\n } = props;\n const contextValue = React.useMemo(() => ({\n disableDefaultClasses: disableDefaultClasses != null ? disableDefaultClasses : false\n }), [disableDefaultClasses]);\n return /*#__PURE__*/_jsx(ClassNameConfiguratorContext.Provider, {\n value: contextValue,\n children: children\n });\n}","/**\n * Extracts event handlers from a given object.\n * A prop is considered an event handler if it is a function and its name starts with `on`.\n *\n * @param object An object to extract event handlers from.\n * @param excludeKeys An array of keys to exclude from the returned object.\n */\nexport function extractEventHandlers(object, excludeKeys = []) {\n if (object === undefined) {\n return {};\n }\n const result = {};\n Object.keys(object).filter(prop => prop.match(/^on[A-Z]/) && typeof object[prop] === 'function' && !excludeKeys.includes(prop)).forEach(prop => {\n result[prop] = object[prop];\n });\n return result;\n}","/**\n * If `componentProps` is a function, calls it with the provided `ownerState`.\n * Otherwise, just returns `componentProps`.\n */\nexport function resolveComponentProps(componentProps, ownerState, slotState) {\n if (typeof componentProps === 'function') {\n return componentProps(ownerState, slotState);\n }\n return componentProps;\n}","/**\n * Removes event handlers from the given object.\n * A field is considered an event handler if it is a function with a name beginning with `on`.\n *\n * @param object Object to remove event handlers from.\n * @returns Object with event handlers removed.\n */\nexport function omitEventHandlers(object) {\n if (object === undefined) {\n return {};\n }\n const result = {};\n Object.keys(object).filter(prop => !(prop.match(/^on[A-Z]/) && typeof object[prop] === 'function')).forEach(prop => {\n result[prop] = object[prop];\n });\n return result;\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport clsx from 'clsx';\nimport { extractEventHandlers } from './extractEventHandlers';\nimport { omitEventHandlers } from './omitEventHandlers';\n/**\n * Merges the slot component internal props (usually coming from a hook)\n * with the externally provided ones.\n *\n * The merge order is (the latter overrides the former):\n * 1. The internal props (specified as a getter function to work with get*Props hook result)\n * 2. Additional props (specified internally on a Base UI component)\n * 3. External props specified on the owner component. These should only be used on a root slot.\n * 4. External props specified in the `slotProps.*` prop.\n * 5. The `className` prop - combined from all the above.\n * @param parameters\n * @returns\n */\nexport function mergeSlotProps(parameters) {\n const {\n getSlotProps,\n additionalProps,\n externalSlotProps,\n externalForwardedProps,\n className\n } = parameters;\n if (!getSlotProps) {\n // The simpler case - getSlotProps is not defined, so no internal event handlers are defined,\n // so we can simply merge all the props without having to worry about extracting event handlers.\n const joinedClasses = clsx(additionalProps == null ? void 0 : additionalProps.className, className, externalForwardedProps == null ? void 0 : externalForwardedProps.className, externalSlotProps == null ? void 0 : externalSlotProps.className);\n const mergedStyle = _extends({}, additionalProps == null ? void 0 : additionalProps.style, externalForwardedProps == null ? void 0 : externalForwardedProps.style, externalSlotProps == null ? void 0 : externalSlotProps.style);\n const props = _extends({}, additionalProps, externalForwardedProps, externalSlotProps);\n if (joinedClasses.length > 0) {\n props.className = joinedClasses;\n }\n if (Object.keys(mergedStyle).length > 0) {\n props.style = mergedStyle;\n }\n return {\n props,\n internalRef: undefined\n };\n }\n\n // In this case, getSlotProps is responsible for calling the external event handlers.\n // We don't need to include them in the merged props because of this.\n\n const eventHandlers = extractEventHandlers(_extends({}, externalForwardedProps, externalSlotProps));\n const componentsPropsWithoutEventHandlers = omitEventHandlers(externalSlotProps);\n const otherPropsWithoutEventHandlers = omitEventHandlers(externalForwardedProps);\n const internalSlotProps = getSlotProps(eventHandlers);\n\n // The order of classes is important here.\n // Emotion (that we use in libraries consuming Base UI) depends on this order\n // to properly override style. It requires the most important classes to be last\n // (see https://github.com/mui/material-ui/pull/33205) for the related discussion.\n const joinedClasses = clsx(internalSlotProps == null ? void 0 : internalSlotProps.className, additionalProps == null ? void 0 : additionalProps.className, className, externalForwardedProps == null ? void 0 : externalForwardedProps.className, externalSlotProps == null ? void 0 : externalSlotProps.className);\n const mergedStyle = _extends({}, internalSlotProps == null ? void 0 : internalSlotProps.style, additionalProps == null ? void 0 : additionalProps.style, externalForwardedProps == null ? void 0 : externalForwardedProps.style, externalSlotProps == null ? void 0 : externalSlotProps.style);\n const props = _extends({}, internalSlotProps, additionalProps, otherPropsWithoutEventHandlers, componentsPropsWithoutEventHandlers);\n if (joinedClasses.length > 0) {\n props.className = joinedClasses;\n }\n if (Object.keys(mergedStyle).length > 0) {\n props.style = mergedStyle;\n }\n return {\n props,\n internalRef: internalSlotProps.ref\n };\n}","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"elementType\", \"externalSlotProps\", \"ownerState\", \"skipResolvingSlotProps\"];\nimport { unstable_useForkRef as useForkRef } from '@mui/utils';\nimport { appendOwnerState } from './appendOwnerState';\nimport { mergeSlotProps } from './mergeSlotProps';\nimport { resolveComponentProps } from './resolveComponentProps';\n/**\n * @ignore - do not document.\n * Builds the props to be passed into the slot of an unstyled component.\n * It merges the internal props of the component with the ones supplied by the user, allowing to customize the behavior.\n * If the slot component is not a host component, it also merges in the `ownerState`.\n *\n * @param parameters.getSlotProps - A function that returns the props to be passed to the slot component.\n */\nexport function useSlotProps(parameters) {\n var _parameters$additiona;\n const {\n elementType,\n externalSlotProps,\n ownerState,\n skipResolvingSlotProps = false\n } = parameters,\n rest = _objectWithoutPropertiesLoose(parameters, _excluded);\n const resolvedComponentsProps = skipResolvingSlotProps ? {} : resolveComponentProps(externalSlotProps, ownerState);\n const {\n props: mergedProps,\n internalRef\n } = mergeSlotProps(_extends({}, rest, {\n externalSlotProps: resolvedComponentsProps\n }));\n const ref = useForkRef(internalRef, resolvedComponentsProps == null ? void 0 : resolvedComponentsProps.ref, (_parameters$additiona = parameters.additionalProps) == null ? void 0 : _parameters$additiona.ref);\n const props = appendOwnerState(elementType, _extends({}, mergedProps, {\n ref\n }), ownerState);\n return props;\n}","import { globalStateClasses } from '@mui/utils/generateUtilityClass';\nconst GLOBAL_CLASS_PREFIX = 'base';\nfunction buildStateClass(state) {\n return `${GLOBAL_CLASS_PREFIX}--${state}`;\n}\nfunction buildSlotClass(componentName, slot) {\n return `${GLOBAL_CLASS_PREFIX}-${componentName}-${slot}`;\n}\nexport function generateUtilityClass(componentName, slot) {\n const globalStateClass = globalStateClasses[slot];\n return globalStateClass ? buildStateClass(globalStateClass) : buildSlotClass(componentName, slot);\n}\nexport function isGlobalState(slot) {\n return globalStateClasses[slot] !== undefined;\n}","import { generateUtilityClass } from '../generateUtilityClass';\nexport function generateUtilityClasses(componentName, slots) {\n const result = {};\n slots.forEach(slot => {\n result[slot] = generateUtilityClass(componentName, slot);\n });\n return result;\n}","'use client';\n\nimport * as React from 'react';\nimport * as ReactDOM from 'react-dom';\nimport PropTypes from 'prop-types';\nimport { exactProp, HTMLElementType, unstable_useEnhancedEffect as useEnhancedEffect, unstable_useForkRef as useForkRef, unstable_setRef as setRef } from '@mui/utils';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nfunction getContainer(container) {\n return typeof container === 'function' ? container() : container;\n}\n\n/**\n * Portals provide a first-class way to render children into a DOM node\n * that exists outside the DOM hierarchy of the parent component.\n *\n * Demos:\n *\n * - [Portal](https://mui.com/base-ui/react-portal/)\n *\n * API:\n *\n * - [Portal API](https://mui.com/base-ui/react-portal/components-api/#portal)\n */\nconst Portal = /*#__PURE__*/React.forwardRef(function Portal(props, forwardedRef) {\n const {\n children,\n container,\n disablePortal = false\n } = props;\n const [mountNode, setMountNode] = React.useState(null);\n // @ts-expect-error TODO upstream fix\n const handleRef = useForkRef( /*#__PURE__*/React.isValidElement(children) ? children.ref : null, forwardedRef);\n useEnhancedEffect(() => {\n if (!disablePortal) {\n setMountNode(getContainer(container) || document.body);\n }\n }, [container, disablePortal]);\n useEnhancedEffect(() => {\n if (mountNode && !disablePortal) {\n setRef(forwardedRef, mountNode);\n return () => {\n setRef(forwardedRef, null);\n };\n }\n return undefined;\n }, [forwardedRef, mountNode, disablePortal]);\n if (disablePortal) {\n if ( /*#__PURE__*/React.isValidElement(children)) {\n const newProps = {\n ref: handleRef\n };\n return /*#__PURE__*/React.cloneElement(children, newProps);\n }\n return /*#__PURE__*/_jsx(React.Fragment, {\n children: children\n });\n }\n return /*#__PURE__*/_jsx(React.Fragment, {\n children: mountNode ? /*#__PURE__*/ReactDOM.createPortal(children, mountNode) : mountNode\n });\n});\nprocess.env.NODE_ENV !== \"production\" ? Portal.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * The children to render into the `container`.\n */\n children: PropTypes.node,\n /**\n * An HTML element or function that returns one.\n * The `container` will have the portal children appended to it.\n *\n * You can also provide a callback, which is called in a React layout effect.\n * This lets you set the container from a ref, and also makes server-side rendering possible.\n *\n * By default, it uses the body of the top-level document object,\n * so it's simply `document.body` most of the time.\n */\n container: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.func]),\n /**\n * The `children` will be under the DOM hierarchy of the parent component.\n * @default false\n */\n disablePortal: PropTypes.bool\n} : void 0;\nif (process.env.NODE_ENV !== 'production') {\n // eslint-disable-next-line\n Portal['propTypes' + ''] = exactProp(Portal.propTypes);\n}\nexport { Portal };","export var top = 'top';\nexport var bottom = 'bottom';\nexport var right = 'right';\nexport var left = 'left';\nexport var auto = 'auto';\nexport var basePlacements = [top, bottom, right, left];\nexport var start = 'start';\nexport var end = 'end';\nexport var clippingParents = 'clippingParents';\nexport var viewport = 'viewport';\nexport var popper = 'popper';\nexport var reference = 'reference';\nexport var variationPlacements = /*#__PURE__*/basePlacements.reduce(function (acc, placement) {\n return acc.concat([placement + \"-\" + start, placement + \"-\" + end]);\n}, []);\nexport var placements = /*#__PURE__*/[].concat(basePlacements, [auto]).reduce(function (acc, placement) {\n return acc.concat([placement, placement + \"-\" + start, placement + \"-\" + end]);\n}, []); // modifiers that need to read the DOM\n\nexport var beforeRead = 'beforeRead';\nexport var read = 'read';\nexport var afterRead = 'afterRead'; // pure-logic modifiers\n\nexport var beforeMain = 'beforeMain';\nexport var main = 'main';\nexport var afterMain = 'afterMain'; // modifier with the purpose to write to the DOM (or write into a framework state)\n\nexport var beforeWrite = 'beforeWrite';\nexport var write = 'write';\nexport var afterWrite = 'afterWrite';\nexport var modifierPhases = [beforeRead, read, afterRead, beforeMain, main, afterMain, beforeWrite, write, afterWrite];","export default function getNodeName(element) {\n return element ? (element.nodeName || '').toLowerCase() : null;\n}","export default function getWindow(node) {\n if (node == null) {\n return window;\n }\n\n if (node.toString() !== '[object Window]') {\n var ownerDocument = node.ownerDocument;\n return ownerDocument ? ownerDocument.defaultView || window : window;\n }\n\n return node;\n}","import getWindow from \"./getWindow.js\";\n\nfunction isElement(node) {\n var OwnElement = getWindow(node).Element;\n return node instanceof OwnElement || node instanceof Element;\n}\n\nfunction isHTMLElement(node) {\n var OwnElement = getWindow(node).HTMLElement;\n return node instanceof OwnElement || node instanceof HTMLElement;\n}\n\nfunction isShadowRoot(node) {\n // IE 11 has no ShadowRoot\n if (typeof ShadowRoot === 'undefined') {\n return false;\n }\n\n var OwnElement = getWindow(node).ShadowRoot;\n return node instanceof OwnElement || node instanceof ShadowRoot;\n}\n\nexport { isElement, isHTMLElement, isShadowRoot };","import getNodeName from \"../dom-utils/getNodeName.js\";\nimport { isHTMLElement } from \"../dom-utils/instanceOf.js\"; // This modifier takes the styles prepared by the `computeStyles` modifier\n// and applies them to the HTMLElements such as popper and arrow\n\nfunction applyStyles(_ref) {\n var state = _ref.state;\n Object.keys(state.elements).forEach(function (name) {\n var style = state.styles[name] || {};\n var attributes = state.attributes[name] || {};\n var element = state.elements[name]; // arrow is optional + virtual elements\n\n if (!isHTMLElement(element) || !getNodeName(element)) {\n return;\n } // Flow doesn't support to extend this property, but it's the most\n // effective way to apply styles to an HTMLElement\n // $FlowFixMe[cannot-write]\n\n\n Object.assign(element.style, style);\n Object.keys(attributes).forEach(function (name) {\n var value = attributes[name];\n\n if (value === false) {\n element.removeAttribute(name);\n } else {\n element.setAttribute(name, value === true ? '' : value);\n }\n });\n });\n}\n\nfunction effect(_ref2) {\n var state = _ref2.state;\n var initialStyles = {\n popper: {\n position: state.options.strategy,\n left: '0',\n top: '0',\n margin: '0'\n },\n arrow: {\n position: 'absolute'\n },\n reference: {}\n };\n Object.assign(state.elements.popper.style, initialStyles.popper);\n state.styles = initialStyles;\n\n if (state.elements.arrow) {\n Object.assign(state.elements.arrow.style, initialStyles.arrow);\n }\n\n return function () {\n Object.keys(state.elements).forEach(function (name) {\n var element = state.elements[name];\n var attributes = state.attributes[name] || {};\n var styleProperties = Object.keys(state.styles.hasOwnProperty(name) ? state.styles[name] : initialStyles[name]); // Set all values to an empty string to unset them\n\n var style = styleProperties.reduce(function (style, property) {\n style[property] = '';\n return style;\n }, {}); // arrow is optional + virtual elements\n\n if (!isHTMLElement(element) || !getNodeName(element)) {\n return;\n }\n\n Object.assign(element.style, style);\n Object.keys(attributes).forEach(function (attribute) {\n element.removeAttribute(attribute);\n });\n });\n };\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'applyStyles',\n enabled: true,\n phase: 'write',\n fn: applyStyles,\n effect: effect,\n requires: ['computeStyles']\n};","import { auto } from \"../enums.js\";\nexport default function getBasePlacement(placement) {\n return placement.split('-')[0];\n}","export var max = Math.max;\nexport var min = Math.min;\nexport var round = Math.round;","export default function getUAString() {\n var uaData = navigator.userAgentData;\n\n if (uaData != null && uaData.brands && Array.isArray(uaData.brands)) {\n return uaData.brands.map(function (item) {\n return item.brand + \"/\" + item.version;\n }).join(' ');\n }\n\n return navigator.userAgent;\n}","import getUAString from \"../utils/userAgent.js\";\nexport default function isLayoutViewport() {\n return !/^((?!chrome|android).)*safari/i.test(getUAString());\n}","import { isElement, isHTMLElement } from \"./instanceOf.js\";\nimport { round } from \"../utils/math.js\";\nimport getWindow from \"./getWindow.js\";\nimport isLayoutViewport from \"./isLayoutViewport.js\";\nexport default function getBoundingClientRect(element, includeScale, isFixedStrategy) {\n if (includeScale === void 0) {\n includeScale = false;\n }\n\n if (isFixedStrategy === void 0) {\n isFixedStrategy = false;\n }\n\n var clientRect = element.getBoundingClientRect();\n var scaleX = 1;\n var scaleY = 1;\n\n if (includeScale && isHTMLElement(element)) {\n scaleX = element.offsetWidth > 0 ? round(clientRect.width) / element.offsetWidth || 1 : 1;\n scaleY = element.offsetHeight > 0 ? round(clientRect.height) / element.offsetHeight || 1 : 1;\n }\n\n var _ref = isElement(element) ? getWindow(element) : window,\n visualViewport = _ref.visualViewport;\n\n var addVisualOffsets = !isLayoutViewport() && isFixedStrategy;\n var x = (clientRect.left + (addVisualOffsets && visualViewport ? visualViewport.offsetLeft : 0)) / scaleX;\n var y = (clientRect.top + (addVisualOffsets && visualViewport ? visualViewport.offsetTop : 0)) / scaleY;\n var width = clientRect.width / scaleX;\n var height = clientRect.height / scaleY;\n return {\n width: width,\n height: height,\n top: y,\n right: x + width,\n bottom: y + height,\n left: x,\n x: x,\n y: y\n };\n}","import getBoundingClientRect from \"./getBoundingClientRect.js\"; // Returns the layout rect of an element relative to its offsetParent. Layout\n// means it doesn't take into account transforms.\n\nexport default function getLayoutRect(element) {\n var clientRect = getBoundingClientRect(element); // Use the clientRect sizes if it's not been transformed.\n // Fixes https://github.com/popperjs/popper-core/issues/1223\n\n var width = element.offsetWidth;\n var height = element.offsetHeight;\n\n if (Math.abs(clientRect.width - width) <= 1) {\n width = clientRect.width;\n }\n\n if (Math.abs(clientRect.height - height) <= 1) {\n height = clientRect.height;\n }\n\n return {\n x: element.offsetLeft,\n y: element.offsetTop,\n width: width,\n height: height\n };\n}","import { isShadowRoot } from \"./instanceOf.js\";\nexport default function contains(parent, child) {\n var rootNode = child.getRootNode && child.getRootNode(); // First, attempt with faster native method\n\n if (parent.contains(child)) {\n return true;\n } // then fallback to custom implementation with Shadow DOM support\n else if (rootNode && isShadowRoot(rootNode)) {\n var next = child;\n\n do {\n if (next && parent.isSameNode(next)) {\n return true;\n } // $FlowFixMe[prop-missing]: need a better way to handle this...\n\n\n next = next.parentNode || next.host;\n } while (next);\n } // Give up, the result is false\n\n\n return false;\n}","import getWindow from \"./getWindow.js\";\nexport default function getComputedStyle(element) {\n return getWindow(element).getComputedStyle(element);\n}","import getNodeName from \"./getNodeName.js\";\nexport default function isTableElement(element) {\n return ['table', 'td', 'th'].indexOf(getNodeName(element)) >= 0;\n}","import { isElement } from \"./instanceOf.js\";\nexport default function getDocumentElement(element) {\n // $FlowFixMe[incompatible-return]: assume body is always available\n return ((isElement(element) ? element.ownerDocument : // $FlowFixMe[prop-missing]\n element.document) || window.document).documentElement;\n}","import getNodeName from \"./getNodeName.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport { isShadowRoot } from \"./instanceOf.js\";\nexport default function getParentNode(element) {\n if (getNodeName(element) === 'html') {\n return element;\n }\n\n return (// this is a quicker (but less type safe) way to save quite some bytes from the bundle\n // $FlowFixMe[incompatible-return]\n // $FlowFixMe[prop-missing]\n element.assignedSlot || // step into the shadow DOM of the parent of a slotted node\n element.parentNode || ( // DOM Element detected\n isShadowRoot(element) ? element.host : null) || // ShadowRoot detected\n // $FlowFixMe[incompatible-call]: HTMLElement is a Node\n getDocumentElement(element) // fallback\n\n );\n}","import getWindow from \"./getWindow.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport getComputedStyle from \"./getComputedStyle.js\";\nimport { isHTMLElement, isShadowRoot } from \"./instanceOf.js\";\nimport isTableElement from \"./isTableElement.js\";\nimport getParentNode from \"./getParentNode.js\";\nimport getUAString from \"../utils/userAgent.js\";\n\nfunction getTrueOffsetParent(element) {\n if (!isHTMLElement(element) || // https://github.com/popperjs/popper-core/issues/837\n getComputedStyle(element).position === 'fixed') {\n return null;\n }\n\n return element.offsetParent;\n} // `.offsetParent` reports `null` for fixed elements, while absolute elements\n// return the containing block\n\n\nfunction getContainingBlock(element) {\n var isFirefox = /firefox/i.test(getUAString());\n var isIE = /Trident/i.test(getUAString());\n\n if (isIE && isHTMLElement(element)) {\n // In IE 9, 10 and 11 fixed elements containing block is always established by the viewport\n var elementCss = getComputedStyle(element);\n\n if (elementCss.position === 'fixed') {\n return null;\n }\n }\n\n var currentNode = getParentNode(element);\n\n if (isShadowRoot(currentNode)) {\n currentNode = currentNode.host;\n }\n\n while (isHTMLElement(currentNode) && ['html', 'body'].indexOf(getNodeName(currentNode)) < 0) {\n var css = getComputedStyle(currentNode); // This is non-exhaustive but covers the most common CSS properties that\n // create a containing block.\n // https://developer.mozilla.org/en-US/docs/Web/CSS/Containing_block#identifying_the_containing_block\n\n if (css.transform !== 'none' || css.perspective !== 'none' || css.contain === 'paint' || ['transform', 'perspective'].indexOf(css.willChange) !== -1 || isFirefox && css.willChange === 'filter' || isFirefox && css.filter && css.filter !== 'none') {\n return currentNode;\n } else {\n currentNode = currentNode.parentNode;\n }\n }\n\n return null;\n} // Gets the closest ancestor positioned element. Handles some edge cases,\n// such as table ancestors and cross browser bugs.\n\n\nexport default function getOffsetParent(element) {\n var window = getWindow(element);\n var offsetParent = getTrueOffsetParent(element);\n\n while (offsetParent && isTableElement(offsetParent) && getComputedStyle(offsetParent).position === 'static') {\n offsetParent = getTrueOffsetParent(offsetParent);\n }\n\n if (offsetParent && (getNodeName(offsetParent) === 'html' || getNodeName(offsetParent) === 'body' && getComputedStyle(offsetParent).position === 'static')) {\n return window;\n }\n\n return offsetParent || getContainingBlock(element) || window;\n}","export default function getMainAxisFromPlacement(placement) {\n return ['top', 'bottom'].indexOf(placement) >= 0 ? 'x' : 'y';\n}","import { max as mathMax, min as mathMin } from \"./math.js\";\nexport function within(min, value, max) {\n return mathMax(min, mathMin(value, max));\n}\nexport function withinMaxClamp(min, value, max) {\n var v = within(min, value, max);\n return v > max ? max : v;\n}","export default function getFreshSideObject() {\n return {\n top: 0,\n right: 0,\n bottom: 0,\n left: 0\n };\n}","import getFreshSideObject from \"./getFreshSideObject.js\";\nexport default function mergePaddingObject(paddingObject) {\n return Object.assign({}, getFreshSideObject(), paddingObject);\n}","export default function expandToHashMap(value, keys) {\n return keys.reduce(function (hashMap, key) {\n hashMap[key] = value;\n return hashMap;\n }, {});\n}","import getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getLayoutRect from \"../dom-utils/getLayoutRect.js\";\nimport contains from \"../dom-utils/contains.js\";\nimport getOffsetParent from \"../dom-utils/getOffsetParent.js\";\nimport getMainAxisFromPlacement from \"../utils/getMainAxisFromPlacement.js\";\nimport { within } from \"../utils/within.js\";\nimport mergePaddingObject from \"../utils/mergePaddingObject.js\";\nimport expandToHashMap from \"../utils/expandToHashMap.js\";\nimport { left, right, basePlacements, top, bottom } from \"../enums.js\"; // eslint-disable-next-line import/no-unused-modules\n\nvar toPaddingObject = function toPaddingObject(padding, state) {\n padding = typeof padding === 'function' ? padding(Object.assign({}, state.rects, {\n placement: state.placement\n })) : padding;\n return mergePaddingObject(typeof padding !== 'number' ? padding : expandToHashMap(padding, basePlacements));\n};\n\nfunction arrow(_ref) {\n var _state$modifiersData$;\n\n var state = _ref.state,\n name = _ref.name,\n options = _ref.options;\n var arrowElement = state.elements.arrow;\n var popperOffsets = state.modifiersData.popperOffsets;\n var basePlacement = getBasePlacement(state.placement);\n var axis = getMainAxisFromPlacement(basePlacement);\n var isVertical = [left, right].indexOf(basePlacement) >= 0;\n var len = isVertical ? 'height' : 'width';\n\n if (!arrowElement || !popperOffsets) {\n return;\n }\n\n var paddingObject = toPaddingObject(options.padding, state);\n var arrowRect = getLayoutRect(arrowElement);\n var minProp = axis === 'y' ? top : left;\n var maxProp = axis === 'y' ? bottom : right;\n var endDiff = state.rects.reference[len] + state.rects.reference[axis] - popperOffsets[axis] - state.rects.popper[len];\n var startDiff = popperOffsets[axis] - state.rects.reference[axis];\n var arrowOffsetParent = getOffsetParent(arrowElement);\n var clientSize = arrowOffsetParent ? axis === 'y' ? arrowOffsetParent.clientHeight || 0 : arrowOffsetParent.clientWidth || 0 : 0;\n var centerToReference = endDiff / 2 - startDiff / 2; // Make sure the arrow doesn't overflow the popper if the center point is\n // outside of the popper bounds\n\n var min = paddingObject[minProp];\n var max = clientSize - arrowRect[len] - paddingObject[maxProp];\n var center = clientSize / 2 - arrowRect[len] / 2 + centerToReference;\n var offset = within(min, center, max); // Prevents breaking syntax highlighting...\n\n var axisProp = axis;\n state.modifiersData[name] = (_state$modifiersData$ = {}, _state$modifiersData$[axisProp] = offset, _state$modifiersData$.centerOffset = offset - center, _state$modifiersData$);\n}\n\nfunction effect(_ref2) {\n var state = _ref2.state,\n options = _ref2.options;\n var _options$element = options.element,\n arrowElement = _options$element === void 0 ? '[data-popper-arrow]' : _options$element;\n\n if (arrowElement == null) {\n return;\n } // CSS selector\n\n\n if (typeof arrowElement === 'string') {\n arrowElement = state.elements.popper.querySelector(arrowElement);\n\n if (!arrowElement) {\n return;\n }\n }\n\n if (!contains(state.elements.popper, arrowElement)) {\n return;\n }\n\n state.elements.arrow = arrowElement;\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'arrow',\n enabled: true,\n phase: 'main',\n fn: arrow,\n effect: effect,\n requires: ['popperOffsets'],\n requiresIfExists: ['preventOverflow']\n};","export default function getVariation(placement) {\n return placement.split('-')[1];\n}","import { top, left, right, bottom, end } from \"../enums.js\";\nimport getOffsetParent from \"../dom-utils/getOffsetParent.js\";\nimport getWindow from \"../dom-utils/getWindow.js\";\nimport getDocumentElement from \"../dom-utils/getDocumentElement.js\";\nimport getComputedStyle from \"../dom-utils/getComputedStyle.js\";\nimport getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getVariation from \"../utils/getVariation.js\";\nimport { round } from \"../utils/math.js\"; // eslint-disable-next-line import/no-unused-modules\n\nvar unsetSides = {\n top: 'auto',\n right: 'auto',\n bottom: 'auto',\n left: 'auto'\n}; // Round the offsets to the nearest suitable subpixel based on the DPR.\n// Zooming can change the DPR, but it seems to report a value that will\n// cleanly divide the values into the appropriate subpixels.\n\nfunction roundOffsetsByDPR(_ref, win) {\n var x = _ref.x,\n y = _ref.y;\n var dpr = win.devicePixelRatio || 1;\n return {\n x: round(x * dpr) / dpr || 0,\n y: round(y * dpr) / dpr || 0\n };\n}\n\nexport function mapToStyles(_ref2) {\n var _Object$assign2;\n\n var popper = _ref2.popper,\n popperRect = _ref2.popperRect,\n placement = _ref2.placement,\n variation = _ref2.variation,\n offsets = _ref2.offsets,\n position = _ref2.position,\n gpuAcceleration = _ref2.gpuAcceleration,\n adaptive = _ref2.adaptive,\n roundOffsets = _ref2.roundOffsets,\n isFixed = _ref2.isFixed;\n var _offsets$x = offsets.x,\n x = _offsets$x === void 0 ? 0 : _offsets$x,\n _offsets$y = offsets.y,\n y = _offsets$y === void 0 ? 0 : _offsets$y;\n\n var _ref3 = typeof roundOffsets === 'function' ? roundOffsets({\n x: x,\n y: y\n }) : {\n x: x,\n y: y\n };\n\n x = _ref3.x;\n y = _ref3.y;\n var hasX = offsets.hasOwnProperty('x');\n var hasY = offsets.hasOwnProperty('y');\n var sideX = left;\n var sideY = top;\n var win = window;\n\n if (adaptive) {\n var offsetParent = getOffsetParent(popper);\n var heightProp = 'clientHeight';\n var widthProp = 'clientWidth';\n\n if (offsetParent === getWindow(popper)) {\n offsetParent = getDocumentElement(popper);\n\n if (getComputedStyle(offsetParent).position !== 'static' && position === 'absolute') {\n heightProp = 'scrollHeight';\n widthProp = 'scrollWidth';\n }\n } // $FlowFixMe[incompatible-cast]: force type refinement, we compare offsetParent with window above, but Flow doesn't detect it\n\n\n offsetParent = offsetParent;\n\n if (placement === top || (placement === left || placement === right) && variation === end) {\n sideY = bottom;\n var offsetY = isFixed && offsetParent === win && win.visualViewport ? win.visualViewport.height : // $FlowFixMe[prop-missing]\n offsetParent[heightProp];\n y -= offsetY - popperRect.height;\n y *= gpuAcceleration ? 1 : -1;\n }\n\n if (placement === left || (placement === top || placement === bottom) && variation === end) {\n sideX = right;\n var offsetX = isFixed && offsetParent === win && win.visualViewport ? win.visualViewport.width : // $FlowFixMe[prop-missing]\n offsetParent[widthProp];\n x -= offsetX - popperRect.width;\n x *= gpuAcceleration ? 1 : -1;\n }\n }\n\n var commonStyles = Object.assign({\n position: position\n }, adaptive && unsetSides);\n\n var _ref4 = roundOffsets === true ? roundOffsetsByDPR({\n x: x,\n y: y\n }, getWindow(popper)) : {\n x: x,\n y: y\n };\n\n x = _ref4.x;\n y = _ref4.y;\n\n if (gpuAcceleration) {\n var _Object$assign;\n\n return Object.assign({}, commonStyles, (_Object$assign = {}, _Object$assign[sideY] = hasY ? '0' : '', _Object$assign[sideX] = hasX ? '0' : '', _Object$assign.transform = (win.devicePixelRatio || 1) <= 1 ? \"translate(\" + x + \"px, \" + y + \"px)\" : \"translate3d(\" + x + \"px, \" + y + \"px, 0)\", _Object$assign));\n }\n\n return Object.assign({}, commonStyles, (_Object$assign2 = {}, _Object$assign2[sideY] = hasY ? y + \"px\" : '', _Object$assign2[sideX] = hasX ? x + \"px\" : '', _Object$assign2.transform = '', _Object$assign2));\n}\n\nfunction computeStyles(_ref5) {\n var state = _ref5.state,\n options = _ref5.options;\n var _options$gpuAccelerat = options.gpuAcceleration,\n gpuAcceleration = _options$gpuAccelerat === void 0 ? true : _options$gpuAccelerat,\n _options$adaptive = options.adaptive,\n adaptive = _options$adaptive === void 0 ? true : _options$adaptive,\n _options$roundOffsets = options.roundOffsets,\n roundOffsets = _options$roundOffsets === void 0 ? true : _options$roundOffsets;\n var commonStyles = {\n placement: getBasePlacement(state.placement),\n variation: getVariation(state.placement),\n popper: state.elements.popper,\n popperRect: state.rects.popper,\n gpuAcceleration: gpuAcceleration,\n isFixed: state.options.strategy === 'fixed'\n };\n\n if (state.modifiersData.popperOffsets != null) {\n state.styles.popper = Object.assign({}, state.styles.popper, mapToStyles(Object.assign({}, commonStyles, {\n offsets: state.modifiersData.popperOffsets,\n position: state.options.strategy,\n adaptive: adaptive,\n roundOffsets: roundOffsets\n })));\n }\n\n if (state.modifiersData.arrow != null) {\n state.styles.arrow = Object.assign({}, state.styles.arrow, mapToStyles(Object.assign({}, commonStyles, {\n offsets: state.modifiersData.arrow,\n position: 'absolute',\n adaptive: false,\n roundOffsets: roundOffsets\n })));\n }\n\n state.attributes.popper = Object.assign({}, state.attributes.popper, {\n 'data-popper-placement': state.placement\n });\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'computeStyles',\n enabled: true,\n phase: 'beforeWrite',\n fn: computeStyles,\n data: {}\n};","import getWindow from \"../dom-utils/getWindow.js\"; // eslint-disable-next-line import/no-unused-modules\n\nvar passive = {\n passive: true\n};\n\nfunction effect(_ref) {\n var state = _ref.state,\n instance = _ref.instance,\n options = _ref.options;\n var _options$scroll = options.scroll,\n scroll = _options$scroll === void 0 ? true : _options$scroll,\n _options$resize = options.resize,\n resize = _options$resize === void 0 ? true : _options$resize;\n var window = getWindow(state.elements.popper);\n var scrollParents = [].concat(state.scrollParents.reference, state.scrollParents.popper);\n\n if (scroll) {\n scrollParents.forEach(function (scrollParent) {\n scrollParent.addEventListener('scroll', instance.update, passive);\n });\n }\n\n if (resize) {\n window.addEventListener('resize', instance.update, passive);\n }\n\n return function () {\n if (scroll) {\n scrollParents.forEach(function (scrollParent) {\n scrollParent.removeEventListener('scroll', instance.update, passive);\n });\n }\n\n if (resize) {\n window.removeEventListener('resize', instance.update, passive);\n }\n };\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'eventListeners',\n enabled: true,\n phase: 'write',\n fn: function fn() {},\n effect: effect,\n data: {}\n};","var hash = {\n left: 'right',\n right: 'left',\n bottom: 'top',\n top: 'bottom'\n};\nexport default function getOppositePlacement(placement) {\n return placement.replace(/left|right|bottom|top/g, function (matched) {\n return hash[matched];\n });\n}","var hash = {\n start: 'end',\n end: 'start'\n};\nexport default function getOppositeVariationPlacement(placement) {\n return placement.replace(/start|end/g, function (matched) {\n return hash[matched];\n });\n}","import getWindow from \"./getWindow.js\";\nexport default function getWindowScroll(node) {\n var win = getWindow(node);\n var scrollLeft = win.pageXOffset;\n var scrollTop = win.pageYOffset;\n return {\n scrollLeft: scrollLeft,\n scrollTop: scrollTop\n };\n}","import getBoundingClientRect from \"./getBoundingClientRect.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport getWindowScroll from \"./getWindowScroll.js\";\nexport default function getWindowScrollBarX(element) {\n // If has a CSS width greater than the viewport, then this will be\n // incorrect for RTL.\n // Popper 1 is broken in this case and never had a bug report so let's assume\n // it's not an issue. I don't think anyone ever specifies width on \n // anyway.\n // Browsers where the left scrollbar doesn't cause an issue report `0` for\n // this (e.g. Edge 2019, IE11, Safari)\n return getBoundingClientRect(getDocumentElement(element)).left + getWindowScroll(element).scrollLeft;\n}","import getWindow from \"./getWindow.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport getWindowScrollBarX from \"./getWindowScrollBarX.js\";\nimport isLayoutViewport from \"./isLayoutViewport.js\";\nexport default function getViewportRect(element, strategy) {\n var win = getWindow(element);\n var html = getDocumentElement(element);\n var visualViewport = win.visualViewport;\n var width = html.clientWidth;\n var height = html.clientHeight;\n var x = 0;\n var y = 0;\n\n if (visualViewport) {\n width = visualViewport.width;\n height = visualViewport.height;\n var layoutViewport = isLayoutViewport();\n\n if (layoutViewport || !layoutViewport && strategy === 'fixed') {\n x = visualViewport.offsetLeft;\n y = visualViewport.offsetTop;\n }\n }\n\n return {\n width: width,\n height: height,\n x: x + getWindowScrollBarX(element),\n y: y\n };\n}","import getDocumentElement from \"./getDocumentElement.js\";\nimport getComputedStyle from \"./getComputedStyle.js\";\nimport getWindowScrollBarX from \"./getWindowScrollBarX.js\";\nimport getWindowScroll from \"./getWindowScroll.js\";\nimport { max } from \"../utils/math.js\"; // Gets the entire size of the scrollable document area, even extending outside\n// of the `` and `` rect bounds if horizontally scrollable\n\nexport default function getDocumentRect(element) {\n var _element$ownerDocumen;\n\n var html = getDocumentElement(element);\n var winScroll = getWindowScroll(element);\n var body = (_element$ownerDocumen = element.ownerDocument) == null ? void 0 : _element$ownerDocumen.body;\n var width = max(html.scrollWidth, html.clientWidth, body ? body.scrollWidth : 0, body ? body.clientWidth : 0);\n var height = max(html.scrollHeight, html.clientHeight, body ? body.scrollHeight : 0, body ? body.clientHeight : 0);\n var x = -winScroll.scrollLeft + getWindowScrollBarX(element);\n var y = -winScroll.scrollTop;\n\n if (getComputedStyle(body || html).direction === 'rtl') {\n x += max(html.clientWidth, body ? body.clientWidth : 0) - width;\n }\n\n return {\n width: width,\n height: height,\n x: x,\n y: y\n };\n}","import getComputedStyle from \"./getComputedStyle.js\";\nexport default function isScrollParent(element) {\n // Firefox wants us to check `-x` and `-y` variations as well\n var _getComputedStyle = getComputedStyle(element),\n overflow = _getComputedStyle.overflow,\n overflowX = _getComputedStyle.overflowX,\n overflowY = _getComputedStyle.overflowY;\n\n return /auto|scroll|overlay|hidden/.test(overflow + overflowY + overflowX);\n}","import getParentNode from \"./getParentNode.js\";\nimport isScrollParent from \"./isScrollParent.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport { isHTMLElement } from \"./instanceOf.js\";\nexport default function getScrollParent(node) {\n if (['html', 'body', '#document'].indexOf(getNodeName(node)) >= 0) {\n // $FlowFixMe[incompatible-return]: assume body is always available\n return node.ownerDocument.body;\n }\n\n if (isHTMLElement(node) && isScrollParent(node)) {\n return node;\n }\n\n return getScrollParent(getParentNode(node));\n}","import getScrollParent from \"./getScrollParent.js\";\nimport getParentNode from \"./getParentNode.js\";\nimport getWindow from \"./getWindow.js\";\nimport isScrollParent from \"./isScrollParent.js\";\n/*\ngiven a DOM element, return the list of all scroll parents, up the list of ancesors\nuntil we get to the top window object. This list is what we attach scroll listeners\nto, because if any of these parent elements scroll, we'll need to re-calculate the\nreference element's position.\n*/\n\nexport default function listScrollParents(element, list) {\n var _element$ownerDocumen;\n\n if (list === void 0) {\n list = [];\n }\n\n var scrollParent = getScrollParent(element);\n var isBody = scrollParent === ((_element$ownerDocumen = element.ownerDocument) == null ? void 0 : _element$ownerDocumen.body);\n var win = getWindow(scrollParent);\n var target = isBody ? [win].concat(win.visualViewport || [], isScrollParent(scrollParent) ? scrollParent : []) : scrollParent;\n var updatedList = list.concat(target);\n return isBody ? updatedList : // $FlowFixMe[incompatible-call]: isBody tells us target will be an HTMLElement here\n updatedList.concat(listScrollParents(getParentNode(target)));\n}","export default function rectToClientRect(rect) {\n return Object.assign({}, rect, {\n left: rect.x,\n top: rect.y,\n right: rect.x + rect.width,\n bottom: rect.y + rect.height\n });\n}","import { viewport } from \"../enums.js\";\nimport getViewportRect from \"./getViewportRect.js\";\nimport getDocumentRect from \"./getDocumentRect.js\";\nimport listScrollParents from \"./listScrollParents.js\";\nimport getOffsetParent from \"./getOffsetParent.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport getComputedStyle from \"./getComputedStyle.js\";\nimport { isElement, isHTMLElement } from \"./instanceOf.js\";\nimport getBoundingClientRect from \"./getBoundingClientRect.js\";\nimport getParentNode from \"./getParentNode.js\";\nimport contains from \"./contains.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport rectToClientRect from \"../utils/rectToClientRect.js\";\nimport { max, min } from \"../utils/math.js\";\n\nfunction getInnerBoundingClientRect(element, strategy) {\n var rect = getBoundingClientRect(element, false, strategy === 'fixed');\n rect.top = rect.top + element.clientTop;\n rect.left = rect.left + element.clientLeft;\n rect.bottom = rect.top + element.clientHeight;\n rect.right = rect.left + element.clientWidth;\n rect.width = element.clientWidth;\n rect.height = element.clientHeight;\n rect.x = rect.left;\n rect.y = rect.top;\n return rect;\n}\n\nfunction getClientRectFromMixedType(element, clippingParent, strategy) {\n return clippingParent === viewport ? rectToClientRect(getViewportRect(element, strategy)) : isElement(clippingParent) ? getInnerBoundingClientRect(clippingParent, strategy) : rectToClientRect(getDocumentRect(getDocumentElement(element)));\n} // A \"clipping parent\" is an overflowable container with the characteristic of\n// clipping (or hiding) overflowing elements with a position different from\n// `initial`\n\n\nfunction getClippingParents(element) {\n var clippingParents = listScrollParents(getParentNode(element));\n var canEscapeClipping = ['absolute', 'fixed'].indexOf(getComputedStyle(element).position) >= 0;\n var clipperElement = canEscapeClipping && isHTMLElement(element) ? getOffsetParent(element) : element;\n\n if (!isElement(clipperElement)) {\n return [];\n } // $FlowFixMe[incompatible-return]: https://github.com/facebook/flow/issues/1414\n\n\n return clippingParents.filter(function (clippingParent) {\n return isElement(clippingParent) && contains(clippingParent, clipperElement) && getNodeName(clippingParent) !== 'body';\n });\n} // Gets the maximum area that the element is visible in due to any number of\n// clipping parents\n\n\nexport default function getClippingRect(element, boundary, rootBoundary, strategy) {\n var mainClippingParents = boundary === 'clippingParents' ? getClippingParents(element) : [].concat(boundary);\n var clippingParents = [].concat(mainClippingParents, [rootBoundary]);\n var firstClippingParent = clippingParents[0];\n var clippingRect = clippingParents.reduce(function (accRect, clippingParent) {\n var rect = getClientRectFromMixedType(element, clippingParent, strategy);\n accRect.top = max(rect.top, accRect.top);\n accRect.right = min(rect.right, accRect.right);\n accRect.bottom = min(rect.bottom, accRect.bottom);\n accRect.left = max(rect.left, accRect.left);\n return accRect;\n }, getClientRectFromMixedType(element, firstClippingParent, strategy));\n clippingRect.width = clippingRect.right - clippingRect.left;\n clippingRect.height = clippingRect.bottom - clippingRect.top;\n clippingRect.x = clippingRect.left;\n clippingRect.y = clippingRect.top;\n return clippingRect;\n}","import getBasePlacement from \"./getBasePlacement.js\";\nimport getVariation from \"./getVariation.js\";\nimport getMainAxisFromPlacement from \"./getMainAxisFromPlacement.js\";\nimport { top, right, bottom, left, start, end } from \"../enums.js\";\nexport default function computeOffsets(_ref) {\n var reference = _ref.reference,\n element = _ref.element,\n placement = _ref.placement;\n var basePlacement = placement ? getBasePlacement(placement) : null;\n var variation = placement ? getVariation(placement) : null;\n var commonX = reference.x + reference.width / 2 - element.width / 2;\n var commonY = reference.y + reference.height / 2 - element.height / 2;\n var offsets;\n\n switch (basePlacement) {\n case top:\n offsets = {\n x: commonX,\n y: reference.y - element.height\n };\n break;\n\n case bottom:\n offsets = {\n x: commonX,\n y: reference.y + reference.height\n };\n break;\n\n case right:\n offsets = {\n x: reference.x + reference.width,\n y: commonY\n };\n break;\n\n case left:\n offsets = {\n x: reference.x - element.width,\n y: commonY\n };\n break;\n\n default:\n offsets = {\n x: reference.x,\n y: reference.y\n };\n }\n\n var mainAxis = basePlacement ? getMainAxisFromPlacement(basePlacement) : null;\n\n if (mainAxis != null) {\n var len = mainAxis === 'y' ? 'height' : 'width';\n\n switch (variation) {\n case start:\n offsets[mainAxis] = offsets[mainAxis] - (reference[len] / 2 - element[len] / 2);\n break;\n\n case end:\n offsets[mainAxis] = offsets[mainAxis] + (reference[len] / 2 - element[len] / 2);\n break;\n\n default:\n }\n }\n\n return offsets;\n}","import getClippingRect from \"../dom-utils/getClippingRect.js\";\nimport getDocumentElement from \"../dom-utils/getDocumentElement.js\";\nimport getBoundingClientRect from \"../dom-utils/getBoundingClientRect.js\";\nimport computeOffsets from \"./computeOffsets.js\";\nimport rectToClientRect from \"./rectToClientRect.js\";\nimport { clippingParents, reference, popper, bottom, top, right, basePlacements, viewport } from \"../enums.js\";\nimport { isElement } from \"../dom-utils/instanceOf.js\";\nimport mergePaddingObject from \"./mergePaddingObject.js\";\nimport expandToHashMap from \"./expandToHashMap.js\"; // eslint-disable-next-line import/no-unused-modules\n\nexport default function detectOverflow(state, options) {\n if (options === void 0) {\n options = {};\n }\n\n var _options = options,\n _options$placement = _options.placement,\n placement = _options$placement === void 0 ? state.placement : _options$placement,\n _options$strategy = _options.strategy,\n strategy = _options$strategy === void 0 ? state.strategy : _options$strategy,\n _options$boundary = _options.boundary,\n boundary = _options$boundary === void 0 ? clippingParents : _options$boundary,\n _options$rootBoundary = _options.rootBoundary,\n rootBoundary = _options$rootBoundary === void 0 ? viewport : _options$rootBoundary,\n _options$elementConte = _options.elementContext,\n elementContext = _options$elementConte === void 0 ? popper : _options$elementConte,\n _options$altBoundary = _options.altBoundary,\n altBoundary = _options$altBoundary === void 0 ? false : _options$altBoundary,\n _options$padding = _options.padding,\n padding = _options$padding === void 0 ? 0 : _options$padding;\n var paddingObject = mergePaddingObject(typeof padding !== 'number' ? padding : expandToHashMap(padding, basePlacements));\n var altContext = elementContext === popper ? reference : popper;\n var popperRect = state.rects.popper;\n var element = state.elements[altBoundary ? altContext : elementContext];\n var clippingClientRect = getClippingRect(isElement(element) ? element : element.contextElement || getDocumentElement(state.elements.popper), boundary, rootBoundary, strategy);\n var referenceClientRect = getBoundingClientRect(state.elements.reference);\n var popperOffsets = computeOffsets({\n reference: referenceClientRect,\n element: popperRect,\n strategy: 'absolute',\n placement: placement\n });\n var popperClientRect = rectToClientRect(Object.assign({}, popperRect, popperOffsets));\n var elementClientRect = elementContext === popper ? popperClientRect : referenceClientRect; // positive = overflowing the clipping rect\n // 0 or negative = within the clipping rect\n\n var overflowOffsets = {\n top: clippingClientRect.top - elementClientRect.top + paddingObject.top,\n bottom: elementClientRect.bottom - clippingClientRect.bottom + paddingObject.bottom,\n left: clippingClientRect.left - elementClientRect.left + paddingObject.left,\n right: elementClientRect.right - clippingClientRect.right + paddingObject.right\n };\n var offsetData = state.modifiersData.offset; // Offsets can be applied only to the popper element\n\n if (elementContext === popper && offsetData) {\n var offset = offsetData[placement];\n Object.keys(overflowOffsets).forEach(function (key) {\n var multiply = [right, bottom].indexOf(key) >= 0 ? 1 : -1;\n var axis = [top, bottom].indexOf(key) >= 0 ? 'y' : 'x';\n overflowOffsets[key] += offset[axis] * multiply;\n });\n }\n\n return overflowOffsets;\n}","import getVariation from \"./getVariation.js\";\nimport { variationPlacements, basePlacements, placements as allPlacements } from \"../enums.js\";\nimport detectOverflow from \"./detectOverflow.js\";\nimport getBasePlacement from \"./getBasePlacement.js\";\nexport default function computeAutoPlacement(state, options) {\n if (options === void 0) {\n options = {};\n }\n\n var _options = options,\n placement = _options.placement,\n boundary = _options.boundary,\n rootBoundary = _options.rootBoundary,\n padding = _options.padding,\n flipVariations = _options.flipVariations,\n _options$allowedAutoP = _options.allowedAutoPlacements,\n allowedAutoPlacements = _options$allowedAutoP === void 0 ? allPlacements : _options$allowedAutoP;\n var variation = getVariation(placement);\n var placements = variation ? flipVariations ? variationPlacements : variationPlacements.filter(function (placement) {\n return getVariation(placement) === variation;\n }) : basePlacements;\n var allowedPlacements = placements.filter(function (placement) {\n return allowedAutoPlacements.indexOf(placement) >= 0;\n });\n\n if (allowedPlacements.length === 0) {\n allowedPlacements = placements;\n } // $FlowFixMe[incompatible-type]: Flow seems to have problems with two array unions...\n\n\n var overflows = allowedPlacements.reduce(function (acc, placement) {\n acc[placement] = detectOverflow(state, {\n placement: placement,\n boundary: boundary,\n rootBoundary: rootBoundary,\n padding: padding\n })[getBasePlacement(placement)];\n return acc;\n }, {});\n return Object.keys(overflows).sort(function (a, b) {\n return overflows[a] - overflows[b];\n });\n}","import getOppositePlacement from \"../utils/getOppositePlacement.js\";\nimport getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getOppositeVariationPlacement from \"../utils/getOppositeVariationPlacement.js\";\nimport detectOverflow from \"../utils/detectOverflow.js\";\nimport computeAutoPlacement from \"../utils/computeAutoPlacement.js\";\nimport { bottom, top, start, right, left, auto } from \"../enums.js\";\nimport getVariation from \"../utils/getVariation.js\"; // eslint-disable-next-line import/no-unused-modules\n\nfunction getExpandedFallbackPlacements(placement) {\n if (getBasePlacement(placement) === auto) {\n return [];\n }\n\n var oppositePlacement = getOppositePlacement(placement);\n return [getOppositeVariationPlacement(placement), oppositePlacement, getOppositeVariationPlacement(oppositePlacement)];\n}\n\nfunction flip(_ref) {\n var state = _ref.state,\n options = _ref.options,\n name = _ref.name;\n\n if (state.modifiersData[name]._skip) {\n return;\n }\n\n var _options$mainAxis = options.mainAxis,\n checkMainAxis = _options$mainAxis === void 0 ? true : _options$mainAxis,\n _options$altAxis = options.altAxis,\n checkAltAxis = _options$altAxis === void 0 ? true : _options$altAxis,\n specifiedFallbackPlacements = options.fallbackPlacements,\n padding = options.padding,\n boundary = options.boundary,\n rootBoundary = options.rootBoundary,\n altBoundary = options.altBoundary,\n _options$flipVariatio = options.flipVariations,\n flipVariations = _options$flipVariatio === void 0 ? true : _options$flipVariatio,\n allowedAutoPlacements = options.allowedAutoPlacements;\n var preferredPlacement = state.options.placement;\n var basePlacement = getBasePlacement(preferredPlacement);\n var isBasePlacement = basePlacement === preferredPlacement;\n var fallbackPlacements = specifiedFallbackPlacements || (isBasePlacement || !flipVariations ? [getOppositePlacement(preferredPlacement)] : getExpandedFallbackPlacements(preferredPlacement));\n var placements = [preferredPlacement].concat(fallbackPlacements).reduce(function (acc, placement) {\n return acc.concat(getBasePlacement(placement) === auto ? computeAutoPlacement(state, {\n placement: placement,\n boundary: boundary,\n rootBoundary: rootBoundary,\n padding: padding,\n flipVariations: flipVariations,\n allowedAutoPlacements: allowedAutoPlacements\n }) : placement);\n }, []);\n var referenceRect = state.rects.reference;\n var popperRect = state.rects.popper;\n var checksMap = new Map();\n var makeFallbackChecks = true;\n var firstFittingPlacement = placements[0];\n\n for (var i = 0; i < placements.length; i++) {\n var placement = placements[i];\n\n var _basePlacement = getBasePlacement(placement);\n\n var isStartVariation = getVariation(placement) === start;\n var isVertical = [top, bottom].indexOf(_basePlacement) >= 0;\n var len = isVertical ? 'width' : 'height';\n var overflow = detectOverflow(state, {\n placement: placement,\n boundary: boundary,\n rootBoundary: rootBoundary,\n altBoundary: altBoundary,\n padding: padding\n });\n var mainVariationSide = isVertical ? isStartVariation ? right : left : isStartVariation ? bottom : top;\n\n if (referenceRect[len] > popperRect[len]) {\n mainVariationSide = getOppositePlacement(mainVariationSide);\n }\n\n var altVariationSide = getOppositePlacement(mainVariationSide);\n var checks = [];\n\n if (checkMainAxis) {\n checks.push(overflow[_basePlacement] <= 0);\n }\n\n if (checkAltAxis) {\n checks.push(overflow[mainVariationSide] <= 0, overflow[altVariationSide] <= 0);\n }\n\n if (checks.every(function (check) {\n return check;\n })) {\n firstFittingPlacement = placement;\n makeFallbackChecks = false;\n break;\n }\n\n checksMap.set(placement, checks);\n }\n\n if (makeFallbackChecks) {\n // `2` may be desired in some cases – research later\n var numberOfChecks = flipVariations ? 3 : 1;\n\n var _loop = function _loop(_i) {\n var fittingPlacement = placements.find(function (placement) {\n var checks = checksMap.get(placement);\n\n if (checks) {\n return checks.slice(0, _i).every(function (check) {\n return check;\n });\n }\n });\n\n if (fittingPlacement) {\n firstFittingPlacement = fittingPlacement;\n return \"break\";\n }\n };\n\n for (var _i = numberOfChecks; _i > 0; _i--) {\n var _ret = _loop(_i);\n\n if (_ret === \"break\") break;\n }\n }\n\n if (state.placement !== firstFittingPlacement) {\n state.modifiersData[name]._skip = true;\n state.placement = firstFittingPlacement;\n state.reset = true;\n }\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'flip',\n enabled: true,\n phase: 'main',\n fn: flip,\n requiresIfExists: ['offset'],\n data: {\n _skip: false\n }\n};","import { top, bottom, left, right } from \"../enums.js\";\nimport detectOverflow from \"../utils/detectOverflow.js\";\n\nfunction getSideOffsets(overflow, rect, preventedOffsets) {\n if (preventedOffsets === void 0) {\n preventedOffsets = {\n x: 0,\n y: 0\n };\n }\n\n return {\n top: overflow.top - rect.height - preventedOffsets.y,\n right: overflow.right - rect.width + preventedOffsets.x,\n bottom: overflow.bottom - rect.height + preventedOffsets.y,\n left: overflow.left - rect.width - preventedOffsets.x\n };\n}\n\nfunction isAnySideFullyClipped(overflow) {\n return [top, right, bottom, left].some(function (side) {\n return overflow[side] >= 0;\n });\n}\n\nfunction hide(_ref) {\n var state = _ref.state,\n name = _ref.name;\n var referenceRect = state.rects.reference;\n var popperRect = state.rects.popper;\n var preventedOffsets = state.modifiersData.preventOverflow;\n var referenceOverflow = detectOverflow(state, {\n elementContext: 'reference'\n });\n var popperAltOverflow = detectOverflow(state, {\n altBoundary: true\n });\n var referenceClippingOffsets = getSideOffsets(referenceOverflow, referenceRect);\n var popperEscapeOffsets = getSideOffsets(popperAltOverflow, popperRect, preventedOffsets);\n var isReferenceHidden = isAnySideFullyClipped(referenceClippingOffsets);\n var hasPopperEscaped = isAnySideFullyClipped(popperEscapeOffsets);\n state.modifiersData[name] = {\n referenceClippingOffsets: referenceClippingOffsets,\n popperEscapeOffsets: popperEscapeOffsets,\n isReferenceHidden: isReferenceHidden,\n hasPopperEscaped: hasPopperEscaped\n };\n state.attributes.popper = Object.assign({}, state.attributes.popper, {\n 'data-popper-reference-hidden': isReferenceHidden,\n 'data-popper-escaped': hasPopperEscaped\n });\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'hide',\n enabled: true,\n phase: 'main',\n requiresIfExists: ['preventOverflow'],\n fn: hide\n};","import getBasePlacement from \"../utils/getBasePlacement.js\";\nimport { top, left, right, placements } from \"../enums.js\"; // eslint-disable-next-line import/no-unused-modules\n\nexport function distanceAndSkiddingToXY(placement, rects, offset) {\n var basePlacement = getBasePlacement(placement);\n var invertDistance = [left, top].indexOf(basePlacement) >= 0 ? -1 : 1;\n\n var _ref = typeof offset === 'function' ? offset(Object.assign({}, rects, {\n placement: placement\n })) : offset,\n skidding = _ref[0],\n distance = _ref[1];\n\n skidding = skidding || 0;\n distance = (distance || 0) * invertDistance;\n return [left, right].indexOf(basePlacement) >= 0 ? {\n x: distance,\n y: skidding\n } : {\n x: skidding,\n y: distance\n };\n}\n\nfunction offset(_ref2) {\n var state = _ref2.state,\n options = _ref2.options,\n name = _ref2.name;\n var _options$offset = options.offset,\n offset = _options$offset === void 0 ? [0, 0] : _options$offset;\n var data = placements.reduce(function (acc, placement) {\n acc[placement] = distanceAndSkiddingToXY(placement, state.rects, offset);\n return acc;\n }, {});\n var _data$state$placement = data[state.placement],\n x = _data$state$placement.x,\n y = _data$state$placement.y;\n\n if (state.modifiersData.popperOffsets != null) {\n state.modifiersData.popperOffsets.x += x;\n state.modifiersData.popperOffsets.y += y;\n }\n\n state.modifiersData[name] = data;\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'offset',\n enabled: true,\n phase: 'main',\n requires: ['popperOffsets'],\n fn: offset\n};","import computeOffsets from \"../utils/computeOffsets.js\";\n\nfunction popperOffsets(_ref) {\n var state = _ref.state,\n name = _ref.name;\n // Offsets are the actual position the popper needs to have to be\n // properly positioned near its reference element\n // This is the most basic placement, and will be adjusted by\n // the modifiers in the next step\n state.modifiersData[name] = computeOffsets({\n reference: state.rects.reference,\n element: state.rects.popper,\n strategy: 'absolute',\n placement: state.placement\n });\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'popperOffsets',\n enabled: true,\n phase: 'read',\n fn: popperOffsets,\n data: {}\n};","export default function getAltAxis(axis) {\n return axis === 'x' ? 'y' : 'x';\n}","import { top, left, right, bottom, start } from \"../enums.js\";\nimport getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getMainAxisFromPlacement from \"../utils/getMainAxisFromPlacement.js\";\nimport getAltAxis from \"../utils/getAltAxis.js\";\nimport { within, withinMaxClamp } from \"../utils/within.js\";\nimport getLayoutRect from \"../dom-utils/getLayoutRect.js\";\nimport getOffsetParent from \"../dom-utils/getOffsetParent.js\";\nimport detectOverflow from \"../utils/detectOverflow.js\";\nimport getVariation from \"../utils/getVariation.js\";\nimport getFreshSideObject from \"../utils/getFreshSideObject.js\";\nimport { min as mathMin, max as mathMax } from \"../utils/math.js\";\n\nfunction preventOverflow(_ref) {\n var state = _ref.state,\n options = _ref.options,\n name = _ref.name;\n var _options$mainAxis = options.mainAxis,\n checkMainAxis = _options$mainAxis === void 0 ? true : _options$mainAxis,\n _options$altAxis = options.altAxis,\n checkAltAxis = _options$altAxis === void 0 ? false : _options$altAxis,\n boundary = options.boundary,\n rootBoundary = options.rootBoundary,\n altBoundary = options.altBoundary,\n padding = options.padding,\n _options$tether = options.tether,\n tether = _options$tether === void 0 ? true : _options$tether,\n _options$tetherOffset = options.tetherOffset,\n tetherOffset = _options$tetherOffset === void 0 ? 0 : _options$tetherOffset;\n var overflow = detectOverflow(state, {\n boundary: boundary,\n rootBoundary: rootBoundary,\n padding: padding,\n altBoundary: altBoundary\n });\n var basePlacement = getBasePlacement(state.placement);\n var variation = getVariation(state.placement);\n var isBasePlacement = !variation;\n var mainAxis = getMainAxisFromPlacement(basePlacement);\n var altAxis = getAltAxis(mainAxis);\n var popperOffsets = state.modifiersData.popperOffsets;\n var referenceRect = state.rects.reference;\n var popperRect = state.rects.popper;\n var tetherOffsetValue = typeof tetherOffset === 'function' ? tetherOffset(Object.assign({}, state.rects, {\n placement: state.placement\n })) : tetherOffset;\n var normalizedTetherOffsetValue = typeof tetherOffsetValue === 'number' ? {\n mainAxis: tetherOffsetValue,\n altAxis: tetherOffsetValue\n } : Object.assign({\n mainAxis: 0,\n altAxis: 0\n }, tetherOffsetValue);\n var offsetModifierState = state.modifiersData.offset ? state.modifiersData.offset[state.placement] : null;\n var data = {\n x: 0,\n y: 0\n };\n\n if (!popperOffsets) {\n return;\n }\n\n if (checkMainAxis) {\n var _offsetModifierState$;\n\n var mainSide = mainAxis === 'y' ? top : left;\n var altSide = mainAxis === 'y' ? bottom : right;\n var len = mainAxis === 'y' ? 'height' : 'width';\n var offset = popperOffsets[mainAxis];\n var min = offset + overflow[mainSide];\n var max = offset - overflow[altSide];\n var additive = tether ? -popperRect[len] / 2 : 0;\n var minLen = variation === start ? referenceRect[len] : popperRect[len];\n var maxLen = variation === start ? -popperRect[len] : -referenceRect[len]; // We need to include the arrow in the calculation so the arrow doesn't go\n // outside the reference bounds\n\n var arrowElement = state.elements.arrow;\n var arrowRect = tether && arrowElement ? getLayoutRect(arrowElement) : {\n width: 0,\n height: 0\n };\n var arrowPaddingObject = state.modifiersData['arrow#persistent'] ? state.modifiersData['arrow#persistent'].padding : getFreshSideObject();\n var arrowPaddingMin = arrowPaddingObject[mainSide];\n var arrowPaddingMax = arrowPaddingObject[altSide]; // If the reference length is smaller than the arrow length, we don't want\n // to include its full size in the calculation. If the reference is small\n // and near the edge of a boundary, the popper can overflow even if the\n // reference is not overflowing as well (e.g. virtual elements with no\n // width or height)\n\n var arrowLen = within(0, referenceRect[len], arrowRect[len]);\n var minOffset = isBasePlacement ? referenceRect[len] / 2 - additive - arrowLen - arrowPaddingMin - normalizedTetherOffsetValue.mainAxis : minLen - arrowLen - arrowPaddingMin - normalizedTetherOffsetValue.mainAxis;\n var maxOffset = isBasePlacement ? -referenceRect[len] / 2 + additive + arrowLen + arrowPaddingMax + normalizedTetherOffsetValue.mainAxis : maxLen + arrowLen + arrowPaddingMax + normalizedTetherOffsetValue.mainAxis;\n var arrowOffsetParent = state.elements.arrow && getOffsetParent(state.elements.arrow);\n var clientOffset = arrowOffsetParent ? mainAxis === 'y' ? arrowOffsetParent.clientTop || 0 : arrowOffsetParent.clientLeft || 0 : 0;\n var offsetModifierValue = (_offsetModifierState$ = offsetModifierState == null ? void 0 : offsetModifierState[mainAxis]) != null ? _offsetModifierState$ : 0;\n var tetherMin = offset + minOffset - offsetModifierValue - clientOffset;\n var tetherMax = offset + maxOffset - offsetModifierValue;\n var preventedOffset = within(tether ? mathMin(min, tetherMin) : min, offset, tether ? mathMax(max, tetherMax) : max);\n popperOffsets[mainAxis] = preventedOffset;\n data[mainAxis] = preventedOffset - offset;\n }\n\n if (checkAltAxis) {\n var _offsetModifierState$2;\n\n var _mainSide = mainAxis === 'x' ? top : left;\n\n var _altSide = mainAxis === 'x' ? bottom : right;\n\n var _offset = popperOffsets[altAxis];\n\n var _len = altAxis === 'y' ? 'height' : 'width';\n\n var _min = _offset + overflow[_mainSide];\n\n var _max = _offset - overflow[_altSide];\n\n var isOriginSide = [top, left].indexOf(basePlacement) !== -1;\n\n var _offsetModifierValue = (_offsetModifierState$2 = offsetModifierState == null ? void 0 : offsetModifierState[altAxis]) != null ? _offsetModifierState$2 : 0;\n\n var _tetherMin = isOriginSide ? _min : _offset - referenceRect[_len] - popperRect[_len] - _offsetModifierValue + normalizedTetherOffsetValue.altAxis;\n\n var _tetherMax = isOriginSide ? _offset + referenceRect[_len] + popperRect[_len] - _offsetModifierValue - normalizedTetherOffsetValue.altAxis : _max;\n\n var _preventedOffset = tether && isOriginSide ? withinMaxClamp(_tetherMin, _offset, _tetherMax) : within(tether ? _tetherMin : _min, _offset, tether ? _tetherMax : _max);\n\n popperOffsets[altAxis] = _preventedOffset;\n data[altAxis] = _preventedOffset - _offset;\n }\n\n state.modifiersData[name] = data;\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'preventOverflow',\n enabled: true,\n phase: 'main',\n fn: preventOverflow,\n requiresIfExists: ['offset']\n};","export default function getHTMLElementScroll(element) {\n return {\n scrollLeft: element.scrollLeft,\n scrollTop: element.scrollTop\n };\n}","import getWindowScroll from \"./getWindowScroll.js\";\nimport getWindow from \"./getWindow.js\";\nimport { isHTMLElement } from \"./instanceOf.js\";\nimport getHTMLElementScroll from \"./getHTMLElementScroll.js\";\nexport default function getNodeScroll(node) {\n if (node === getWindow(node) || !isHTMLElement(node)) {\n return getWindowScroll(node);\n } else {\n return getHTMLElementScroll(node);\n }\n}","import getBoundingClientRect from \"./getBoundingClientRect.js\";\nimport getNodeScroll from \"./getNodeScroll.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport { isHTMLElement } from \"./instanceOf.js\";\nimport getWindowScrollBarX from \"./getWindowScrollBarX.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport isScrollParent from \"./isScrollParent.js\";\nimport { round } from \"../utils/math.js\";\n\nfunction isElementScaled(element) {\n var rect = element.getBoundingClientRect();\n var scaleX = round(rect.width) / element.offsetWidth || 1;\n var scaleY = round(rect.height) / element.offsetHeight || 1;\n return scaleX !== 1 || scaleY !== 1;\n} // Returns the composite rect of an element relative to its offsetParent.\n// Composite means it takes into account transforms as well as layout.\n\n\nexport default function getCompositeRect(elementOrVirtualElement, offsetParent, isFixed) {\n if (isFixed === void 0) {\n isFixed = false;\n }\n\n var isOffsetParentAnElement = isHTMLElement(offsetParent);\n var offsetParentIsScaled = isHTMLElement(offsetParent) && isElementScaled(offsetParent);\n var documentElement = getDocumentElement(offsetParent);\n var rect = getBoundingClientRect(elementOrVirtualElement, offsetParentIsScaled, isFixed);\n var scroll = {\n scrollLeft: 0,\n scrollTop: 0\n };\n var offsets = {\n x: 0,\n y: 0\n };\n\n if (isOffsetParentAnElement || !isOffsetParentAnElement && !isFixed) {\n if (getNodeName(offsetParent) !== 'body' || // https://github.com/popperjs/popper-core/issues/1078\n isScrollParent(documentElement)) {\n scroll = getNodeScroll(offsetParent);\n }\n\n if (isHTMLElement(offsetParent)) {\n offsets = getBoundingClientRect(offsetParent, true);\n offsets.x += offsetParent.clientLeft;\n offsets.y += offsetParent.clientTop;\n } else if (documentElement) {\n offsets.x = getWindowScrollBarX(documentElement);\n }\n }\n\n return {\n x: rect.left + scroll.scrollLeft - offsets.x,\n y: rect.top + scroll.scrollTop - offsets.y,\n width: rect.width,\n height: rect.height\n };\n}","import { modifierPhases } from \"../enums.js\"; // source: https://stackoverflow.com/questions/49875255\n\nfunction order(modifiers) {\n var map = new Map();\n var visited = new Set();\n var result = [];\n modifiers.forEach(function (modifier) {\n map.set(modifier.name, modifier);\n }); // On visiting object, check for its dependencies and visit them recursively\n\n function sort(modifier) {\n visited.add(modifier.name);\n var requires = [].concat(modifier.requires || [], modifier.requiresIfExists || []);\n requires.forEach(function (dep) {\n if (!visited.has(dep)) {\n var depModifier = map.get(dep);\n\n if (depModifier) {\n sort(depModifier);\n }\n }\n });\n result.push(modifier);\n }\n\n modifiers.forEach(function (modifier) {\n if (!visited.has(modifier.name)) {\n // check for visited object\n sort(modifier);\n }\n });\n return result;\n}\n\nexport default function orderModifiers(modifiers) {\n // order based on dependencies\n var orderedModifiers = order(modifiers); // order based on phase\n\n return modifierPhases.reduce(function (acc, phase) {\n return acc.concat(orderedModifiers.filter(function (modifier) {\n return modifier.phase === phase;\n }));\n }, []);\n}","export default function debounce(fn) {\n var pending;\n return function () {\n if (!pending) {\n pending = new Promise(function (resolve) {\n Promise.resolve().then(function () {\n pending = undefined;\n resolve(fn());\n });\n });\n }\n\n return pending;\n };\n}","export default function mergeByName(modifiers) {\n var merged = modifiers.reduce(function (merged, current) {\n var existing = merged[current.name];\n merged[current.name] = existing ? Object.assign({}, existing, current, {\n options: Object.assign({}, existing.options, current.options),\n data: Object.assign({}, existing.data, current.data)\n }) : current;\n return merged;\n }, {}); // IE11 does not support Object.values\n\n return Object.keys(merged).map(function (key) {\n return merged[key];\n });\n}","import getCompositeRect from \"./dom-utils/getCompositeRect.js\";\nimport getLayoutRect from \"./dom-utils/getLayoutRect.js\";\nimport listScrollParents from \"./dom-utils/listScrollParents.js\";\nimport getOffsetParent from \"./dom-utils/getOffsetParent.js\";\nimport orderModifiers from \"./utils/orderModifiers.js\";\nimport debounce from \"./utils/debounce.js\";\nimport mergeByName from \"./utils/mergeByName.js\";\nimport detectOverflow from \"./utils/detectOverflow.js\";\nimport { isElement } from \"./dom-utils/instanceOf.js\";\nvar DEFAULT_OPTIONS = {\n placement: 'bottom',\n modifiers: [],\n strategy: 'absolute'\n};\n\nfunction areValidElements() {\n for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {\n args[_key] = arguments[_key];\n }\n\n return !args.some(function (element) {\n return !(element && typeof element.getBoundingClientRect === 'function');\n });\n}\n\nexport function popperGenerator(generatorOptions) {\n if (generatorOptions === void 0) {\n generatorOptions = {};\n }\n\n var _generatorOptions = generatorOptions,\n _generatorOptions$def = _generatorOptions.defaultModifiers,\n defaultModifiers = _generatorOptions$def === void 0 ? [] : _generatorOptions$def,\n _generatorOptions$def2 = _generatorOptions.defaultOptions,\n defaultOptions = _generatorOptions$def2 === void 0 ? DEFAULT_OPTIONS : _generatorOptions$def2;\n return function createPopper(reference, popper, options) {\n if (options === void 0) {\n options = defaultOptions;\n }\n\n var state = {\n placement: 'bottom',\n orderedModifiers: [],\n options: Object.assign({}, DEFAULT_OPTIONS, defaultOptions),\n modifiersData: {},\n elements: {\n reference: reference,\n popper: popper\n },\n attributes: {},\n styles: {}\n };\n var effectCleanupFns = [];\n var isDestroyed = false;\n var instance = {\n state: state,\n setOptions: function setOptions(setOptionsAction) {\n var options = typeof setOptionsAction === 'function' ? setOptionsAction(state.options) : setOptionsAction;\n cleanupModifierEffects();\n state.options = Object.assign({}, defaultOptions, state.options, options);\n state.scrollParents = {\n reference: isElement(reference) ? listScrollParents(reference) : reference.contextElement ? listScrollParents(reference.contextElement) : [],\n popper: listScrollParents(popper)\n }; // Orders the modifiers based on their dependencies and `phase`\n // properties\n\n var orderedModifiers = orderModifiers(mergeByName([].concat(defaultModifiers, state.options.modifiers))); // Strip out disabled modifiers\n\n state.orderedModifiers = orderedModifiers.filter(function (m) {\n return m.enabled;\n });\n runModifierEffects();\n return instance.update();\n },\n // Sync update – it will always be executed, even if not necessary. This\n // is useful for low frequency updates where sync behavior simplifies the\n // logic.\n // For high frequency updates (e.g. `resize` and `scroll` events), always\n // prefer the async Popper#update method\n forceUpdate: function forceUpdate() {\n if (isDestroyed) {\n return;\n }\n\n var _state$elements = state.elements,\n reference = _state$elements.reference,\n popper = _state$elements.popper; // Don't proceed if `reference` or `popper` are not valid elements\n // anymore\n\n if (!areValidElements(reference, popper)) {\n return;\n } // Store the reference and popper rects to be read by modifiers\n\n\n state.rects = {\n reference: getCompositeRect(reference, getOffsetParent(popper), state.options.strategy === 'fixed'),\n popper: getLayoutRect(popper)\n }; // Modifiers have the ability to reset the current update cycle. The\n // most common use case for this is the `flip` modifier changing the\n // placement, which then needs to re-run all the modifiers, because the\n // logic was previously ran for the previous placement and is therefore\n // stale/incorrect\n\n state.reset = false;\n state.placement = state.options.placement; // On each update cycle, the `modifiersData` property for each modifier\n // is filled with the initial data specified by the modifier. This means\n // it doesn't persist and is fresh on each update.\n // To ensure persistent data, use `${name}#persistent`\n\n state.orderedModifiers.forEach(function (modifier) {\n return state.modifiersData[modifier.name] = Object.assign({}, modifier.data);\n });\n\n for (var index = 0; index < state.orderedModifiers.length; index++) {\n if (state.reset === true) {\n state.reset = false;\n index = -1;\n continue;\n }\n\n var _state$orderedModifie = state.orderedModifiers[index],\n fn = _state$orderedModifie.fn,\n _state$orderedModifie2 = _state$orderedModifie.options,\n _options = _state$orderedModifie2 === void 0 ? {} : _state$orderedModifie2,\n name = _state$orderedModifie.name;\n\n if (typeof fn === 'function') {\n state = fn({\n state: state,\n options: _options,\n name: name,\n instance: instance\n }) || state;\n }\n }\n },\n // Async and optimistically optimized update – it will not be executed if\n // not necessary (debounced to run at most once-per-tick)\n update: debounce(function () {\n return new Promise(function (resolve) {\n instance.forceUpdate();\n resolve(state);\n });\n }),\n destroy: function destroy() {\n cleanupModifierEffects();\n isDestroyed = true;\n }\n };\n\n if (!areValidElements(reference, popper)) {\n return instance;\n }\n\n instance.setOptions(options).then(function (state) {\n if (!isDestroyed && options.onFirstUpdate) {\n options.onFirstUpdate(state);\n }\n }); // Modifiers have the ability to execute arbitrary code before the first\n // update cycle runs. They will be executed in the same order as the update\n // cycle. This is useful when a modifier adds some persistent data that\n // other modifiers need to use, but the modifier is run after the dependent\n // one.\n\n function runModifierEffects() {\n state.orderedModifiers.forEach(function (_ref) {\n var name = _ref.name,\n _ref$options = _ref.options,\n options = _ref$options === void 0 ? {} : _ref$options,\n effect = _ref.effect;\n\n if (typeof effect === 'function') {\n var cleanupFn = effect({\n state: state,\n name: name,\n instance: instance,\n options: options\n });\n\n var noopFn = function noopFn() {};\n\n effectCleanupFns.push(cleanupFn || noopFn);\n }\n });\n }\n\n function cleanupModifierEffects() {\n effectCleanupFns.forEach(function (fn) {\n return fn();\n });\n effectCleanupFns = [];\n }\n\n return instance;\n };\n}\nexport var createPopper = /*#__PURE__*/popperGenerator(); // eslint-disable-next-line import/no-unused-modules\n\nexport { detectOverflow };","import { popperGenerator, detectOverflow } from \"./createPopper.js\";\nimport eventListeners from \"./modifiers/eventListeners.js\";\nimport popperOffsets from \"./modifiers/popperOffsets.js\";\nimport computeStyles from \"./modifiers/computeStyles.js\";\nimport applyStyles from \"./modifiers/applyStyles.js\";\nimport offset from \"./modifiers/offset.js\";\nimport flip from \"./modifiers/flip.js\";\nimport preventOverflow from \"./modifiers/preventOverflow.js\";\nimport arrow from \"./modifiers/arrow.js\";\nimport hide from \"./modifiers/hide.js\";\nvar defaultModifiers = [eventListeners, popperOffsets, computeStyles, applyStyles, offset, flip, preventOverflow, arrow, hide];\nvar createPopper = /*#__PURE__*/popperGenerator({\n defaultModifiers: defaultModifiers\n}); // eslint-disable-next-line import/no-unused-modules\n\nexport { createPopper, popperGenerator, defaultModifiers, detectOverflow }; // eslint-disable-next-line import/no-unused-modules\n\nexport { createPopper as createPopperLite } from \"./popper-lite.js\"; // eslint-disable-next-line import/no-unused-modules\n\nexport * from \"./modifiers/index.js\";","import { generateUtilityClass } from '../generateUtilityClass';\nimport { generateUtilityClasses } from '../generateUtilityClasses';\nconst COMPONENT_NAME = 'Popper';\nexport function getPopperUtilityClass(slot) {\n return generateUtilityClass(COMPONENT_NAME, slot);\n}\nexport const popperClasses = generateUtilityClasses(COMPONENT_NAME, ['root']);","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"anchorEl\", \"children\", \"direction\", \"disablePortal\", \"modifiers\", \"open\", \"placement\", \"popperOptions\", \"popperRef\", \"slotProps\", \"slots\", \"TransitionProps\", \"ownerState\"],\n _excluded2 = [\"anchorEl\", \"children\", \"container\", \"direction\", \"disablePortal\", \"keepMounted\", \"modifiers\", \"open\", \"placement\", \"popperOptions\", \"popperRef\", \"style\", \"transition\", \"slotProps\", \"slots\"];\nimport * as React from 'react';\nimport { chainPropTypes, HTMLElementType, refType, unstable_ownerDocument as ownerDocument, unstable_useEnhancedEffect as useEnhancedEffect, unstable_useForkRef as useForkRef } from '@mui/utils';\nimport { createPopper } from '@popperjs/core';\nimport PropTypes from 'prop-types';\nimport { unstable_composeClasses as composeClasses } from '../composeClasses';\nimport { Portal } from '../Portal';\nimport { getPopperUtilityClass } from './popperClasses';\nimport { useSlotProps } from '../utils';\nimport { useClassNamesOverride } from '../utils/ClassNameConfigurator';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nfunction flipPlacement(placement, direction) {\n if (direction === 'ltr') {\n return placement;\n }\n switch (placement) {\n case 'bottom-end':\n return 'bottom-start';\n case 'bottom-start':\n return 'bottom-end';\n case 'top-end':\n return 'top-start';\n case 'top-start':\n return 'top-end';\n default:\n return placement;\n }\n}\nfunction resolveAnchorEl(anchorEl) {\n return typeof anchorEl === 'function' ? anchorEl() : anchorEl;\n}\nfunction isHTMLElement(element) {\n return element.nodeType !== undefined;\n}\nfunction isVirtualElement(element) {\n return !isHTMLElement(element);\n}\nconst useUtilityClasses = () => {\n const slots = {\n root: ['root']\n };\n return composeClasses(slots, useClassNamesOverride(getPopperUtilityClass));\n};\nconst defaultPopperOptions = {};\nconst PopperTooltip = /*#__PURE__*/React.forwardRef(function PopperTooltip(props, forwardedRef) {\n var _slots$root;\n const {\n anchorEl,\n children,\n direction,\n disablePortal,\n modifiers,\n open,\n placement: initialPlacement,\n popperOptions,\n popperRef: popperRefProp,\n slotProps = {},\n slots = {},\n TransitionProps\n // @ts-ignore internal logic\n // prevent from spreading to DOM, it can come from the parent component e.g. Select.\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const tooltipRef = React.useRef(null);\n const ownRef = useForkRef(tooltipRef, forwardedRef);\n const popperRef = React.useRef(null);\n const handlePopperRef = useForkRef(popperRef, popperRefProp);\n const handlePopperRefRef = React.useRef(handlePopperRef);\n useEnhancedEffect(() => {\n handlePopperRefRef.current = handlePopperRef;\n }, [handlePopperRef]);\n React.useImperativeHandle(popperRefProp, () => popperRef.current, []);\n const rtlPlacement = flipPlacement(initialPlacement, direction);\n /**\n * placement initialized from prop but can change during lifetime if modifiers.flip.\n * modifiers.flip is essentially a flip for controlled/uncontrolled behavior\n */\n const [placement, setPlacement] = React.useState(rtlPlacement);\n const [resolvedAnchorElement, setResolvedAnchorElement] = React.useState(resolveAnchorEl(anchorEl));\n React.useEffect(() => {\n if (popperRef.current) {\n popperRef.current.forceUpdate();\n }\n });\n React.useEffect(() => {\n if (anchorEl) {\n setResolvedAnchorElement(resolveAnchorEl(anchorEl));\n }\n }, [anchorEl]);\n useEnhancedEffect(() => {\n if (!resolvedAnchorElement || !open) {\n return undefined;\n }\n const handlePopperUpdate = data => {\n setPlacement(data.placement);\n };\n if (process.env.NODE_ENV !== 'production') {\n if (resolvedAnchorElement && isHTMLElement(resolvedAnchorElement) && resolvedAnchorElement.nodeType === 1) {\n const box = resolvedAnchorElement.getBoundingClientRect();\n if (process.env.NODE_ENV !== 'test' && box.top === 0 && box.left === 0 && box.right === 0 && box.bottom === 0) {\n console.warn(['MUI: The `anchorEl` prop provided to the component is invalid.', 'The anchor element should be part of the document layout.', \"Make sure the element is present in the document or that it's not display none.\"].join('\\n'));\n }\n }\n }\n let popperModifiers = [{\n name: 'preventOverflow',\n options: {\n altBoundary: disablePortal\n }\n }, {\n name: 'flip',\n options: {\n altBoundary: disablePortal\n }\n }, {\n name: 'onUpdate',\n enabled: true,\n phase: 'afterWrite',\n fn: ({\n state\n }) => {\n handlePopperUpdate(state);\n }\n }];\n if (modifiers != null) {\n popperModifiers = popperModifiers.concat(modifiers);\n }\n if (popperOptions && popperOptions.modifiers != null) {\n popperModifiers = popperModifiers.concat(popperOptions.modifiers);\n }\n const popper = createPopper(resolvedAnchorElement, tooltipRef.current, _extends({\n placement: rtlPlacement\n }, popperOptions, {\n modifiers: popperModifiers\n }));\n handlePopperRefRef.current(popper);\n return () => {\n popper.destroy();\n handlePopperRefRef.current(null);\n };\n }, [resolvedAnchorElement, disablePortal, modifiers, open, popperOptions, rtlPlacement]);\n const childProps = {\n placement: placement\n };\n if (TransitionProps !== null) {\n childProps.TransitionProps = TransitionProps;\n }\n const classes = useUtilityClasses();\n const Root = (_slots$root = slots.root) != null ? _slots$root : 'div';\n const rootProps = useSlotProps({\n elementType: Root,\n externalSlotProps: slotProps.root,\n externalForwardedProps: other,\n additionalProps: {\n role: 'tooltip',\n ref: ownRef\n },\n ownerState: props,\n className: classes.root\n });\n return /*#__PURE__*/_jsx(Root, _extends({}, rootProps, {\n children: typeof children === 'function' ? children(childProps) : children\n }));\n});\n\n/**\n * Poppers rely on the 3rd party library [Popper.js](https://popper.js.org/docs/v2/) for positioning.\n *\n * Demos:\n *\n * - [Popper](https://mui.com/base-ui/react-popper/)\n *\n * API:\n *\n * - [Popper API](https://mui.com/base-ui/react-popper/components-api/#popper)\n */\nconst Popper = /*#__PURE__*/React.forwardRef(function Popper(props, forwardedRef) {\n const {\n anchorEl,\n children,\n container: containerProp,\n direction = 'ltr',\n disablePortal = false,\n keepMounted = false,\n modifiers,\n open,\n placement = 'bottom',\n popperOptions = defaultPopperOptions,\n popperRef,\n style,\n transition = false,\n slotProps = {},\n slots = {}\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded2);\n const [exited, setExited] = React.useState(true);\n const handleEnter = () => {\n setExited(false);\n };\n const handleExited = () => {\n setExited(true);\n };\n if (!keepMounted && !open && (!transition || exited)) {\n return null;\n }\n\n // If the container prop is provided, use that\n // If the anchorEl prop is provided, use its parent body element as the container\n // If neither are provided let the Modal take care of choosing the container\n let container;\n if (containerProp) {\n container = containerProp;\n } else if (anchorEl) {\n const resolvedAnchorEl = resolveAnchorEl(anchorEl);\n container = resolvedAnchorEl && isHTMLElement(resolvedAnchorEl) ? ownerDocument(resolvedAnchorEl).body : ownerDocument(null).body;\n }\n const display = !open && keepMounted && (!transition || exited) ? 'none' : undefined;\n const transitionProps = transition ? {\n in: open,\n onEnter: handleEnter,\n onExited: handleExited\n } : undefined;\n return /*#__PURE__*/_jsx(Portal, {\n disablePortal: disablePortal,\n container: container,\n children: /*#__PURE__*/_jsx(PopperTooltip, _extends({\n anchorEl: anchorEl,\n direction: direction,\n disablePortal: disablePortal,\n modifiers: modifiers,\n ref: forwardedRef,\n open: transition ? !exited : open,\n placement: placement,\n popperOptions: popperOptions,\n popperRef: popperRef,\n slotProps: slotProps,\n slots: slots\n }, other, {\n style: _extends({\n // Prevents scroll issue, waiting for Popper.js to add this style once initiated.\n position: 'fixed',\n // Fix Popper.js display issue\n top: 0,\n left: 0,\n display\n }, style),\n TransitionProps: transitionProps,\n children: children\n }))\n });\n});\nprocess.env.NODE_ENV !== \"production\" ? Popper.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * An HTML element, [virtualElement](https://popper.js.org/docs/v2/virtual-elements/),\n * or a function that returns either.\n * It's used to set the position of the popper.\n * The return value will passed as the reference object of the Popper instance.\n */\n anchorEl: chainPropTypes(PropTypes.oneOfType([HTMLElementType, PropTypes.object, PropTypes.func]), props => {\n if (props.open) {\n const resolvedAnchorEl = resolveAnchorEl(props.anchorEl);\n if (resolvedAnchorEl && isHTMLElement(resolvedAnchorEl) && resolvedAnchorEl.nodeType === 1) {\n const box = resolvedAnchorEl.getBoundingClientRect();\n if (process.env.NODE_ENV !== 'test' && box.top === 0 && box.left === 0 && box.right === 0 && box.bottom === 0) {\n return new Error(['MUI: The `anchorEl` prop provided to the component is invalid.', 'The anchor element should be part of the document layout.', \"Make sure the element is present in the document or that it's not display none.\"].join('\\n'));\n }\n } else if (!resolvedAnchorEl || typeof resolvedAnchorEl.getBoundingClientRect !== 'function' || isVirtualElement(resolvedAnchorEl) && resolvedAnchorEl.contextElement != null && resolvedAnchorEl.contextElement.nodeType !== 1) {\n return new Error(['MUI: The `anchorEl` prop provided to the component is invalid.', 'It should be an HTML element instance or a virtualElement ', '(https://popper.js.org/docs/v2/virtual-elements/).'].join('\\n'));\n }\n }\n return null;\n }),\n /**\n * Popper render function or node.\n */\n children: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.node, PropTypes.func]),\n /**\n * An HTML element or function that returns one.\n * The `container` will have the portal children appended to it.\n *\n * You can also provide a callback, which is called in a React layout effect.\n * This lets you set the container from a ref, and also makes server-side rendering possible.\n *\n * By default, it uses the body of the top-level document object,\n * so it's simply `document.body` most of the time.\n */\n container: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.func]),\n /**\n * Direction of the text.\n * @default 'ltr'\n */\n direction: PropTypes.oneOf(['ltr', 'rtl']),\n /**\n * The `children` will be under the DOM hierarchy of the parent component.\n * @default false\n */\n disablePortal: PropTypes.bool,\n /**\n * Always keep the children in the DOM.\n * This prop can be useful in SEO situation or\n * when you want to maximize the responsiveness of the Popper.\n * @default false\n */\n keepMounted: PropTypes.bool,\n /**\n * Popper.js is based on a \"plugin-like\" architecture,\n * most of its features are fully encapsulated \"modifiers\".\n *\n * A modifier is a function that is called each time Popper.js needs to\n * compute the position of the popper.\n * For this reason, modifiers should be very performant to avoid bottlenecks.\n * To learn how to create a modifier, [read the modifiers documentation](https://popper.js.org/docs/v2/modifiers/).\n */\n modifiers: PropTypes.arrayOf(PropTypes.shape({\n data: PropTypes.object,\n effect: PropTypes.func,\n enabled: PropTypes.bool,\n fn: PropTypes.func,\n name: PropTypes.any,\n options: PropTypes.object,\n phase: PropTypes.oneOf(['afterMain', 'afterRead', 'afterWrite', 'beforeMain', 'beforeRead', 'beforeWrite', 'main', 'read', 'write']),\n requires: PropTypes.arrayOf(PropTypes.string),\n requiresIfExists: PropTypes.arrayOf(PropTypes.string)\n })),\n /**\n * If `true`, the component is shown.\n */\n open: PropTypes.bool.isRequired,\n /**\n * Popper placement.\n * @default 'bottom'\n */\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n /**\n * Options provided to the [`Popper.js`](https://popper.js.org/docs/v2/constructors/#options) instance.\n * @default {}\n */\n popperOptions: PropTypes.shape({\n modifiers: PropTypes.array,\n onFirstUpdate: PropTypes.func,\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n strategy: PropTypes.oneOf(['absolute', 'fixed'])\n }),\n /**\n * A ref that points to the used popper instance.\n */\n popperRef: refType,\n /**\n * The props used for each slot inside the Popper.\n * @default {}\n */\n slotProps: PropTypes.shape({\n root: PropTypes.oneOfType([PropTypes.func, PropTypes.object])\n }),\n /**\n * The components used for each slot inside the Popper.\n * Either a string to use a HTML element or a component.\n * @default {}\n */\n slots: PropTypes.shape({\n root: PropTypes.elementType\n }),\n /**\n * Help supporting a react-transition-group/Transition component.\n * @default false\n */\n transition: PropTypes.bool\n} : void 0;\nexport { Popper };","'use client';\n\nimport * as React from 'react';\nimport { useTheme as useThemeSystem } from '@mui/system';\nimport defaultTheme from './defaultTheme';\nimport THEME_ID from './identifier';\nexport default function useTheme() {\n const theme = useThemeSystem(defaultTheme);\n if (process.env.NODE_ENV !== 'production') {\n // eslint-disable-next-line react-hooks/rules-of-hooks\n React.useDebugValue(theme);\n }\n return theme[THEME_ID] || theme;\n}","export default function _setPrototypeOf(o, p) {\n _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function _setPrototypeOf(o, p) {\n o.__proto__ = p;\n return o;\n };\n return _setPrototypeOf(o, p);\n}","import setPrototypeOf from \"./setPrototypeOf.js\";\nexport default function _inheritsLoose(subClass, superClass) {\n subClass.prototype = Object.create(superClass.prototype);\n subClass.prototype.constructor = subClass;\n setPrototypeOf(subClass, superClass);\n}","export default {\n disabled: false\n};","import PropTypes from 'prop-types';\nexport var timeoutsShape = process.env.NODE_ENV !== 'production' ? PropTypes.oneOfType([PropTypes.number, PropTypes.shape({\n enter: PropTypes.number,\n exit: PropTypes.number,\n appear: PropTypes.number\n}).isRequired]) : null;\nexport var classNamesShape = process.env.NODE_ENV !== 'production' ? PropTypes.oneOfType([PropTypes.string, PropTypes.shape({\n enter: PropTypes.string,\n exit: PropTypes.string,\n active: PropTypes.string\n}), PropTypes.shape({\n enter: PropTypes.string,\n enterDone: PropTypes.string,\n enterActive: PropTypes.string,\n exit: PropTypes.string,\n exitDone: PropTypes.string,\n exitActive: PropTypes.string\n})]) : null;","import React from 'react';\nexport default React.createContext(null);","export var forceReflow = function forceReflow(node) {\n return node.scrollTop;\n};","import _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _inheritsLoose from \"@babel/runtime/helpers/esm/inheritsLoose\";\nimport PropTypes from 'prop-types';\nimport React from 'react';\nimport ReactDOM from 'react-dom';\nimport config from './config';\nimport { timeoutsShape } from './utils/PropTypes';\nimport TransitionGroupContext from './TransitionGroupContext';\nimport { forceReflow } from './utils/reflow';\nexport var UNMOUNTED = 'unmounted';\nexport var EXITED = 'exited';\nexport var ENTERING = 'entering';\nexport var ENTERED = 'entered';\nexport var EXITING = 'exiting';\n/**\n * The Transition component lets you describe a transition from one component\n * state to another _over time_ with a simple declarative API. Most commonly\n * it's used to animate the mounting and unmounting of a component, but can also\n * be used to describe in-place transition states as well.\n *\n * ---\n *\n * **Note**: `Transition` is a platform-agnostic base component. If you're using\n * transitions in CSS, you'll probably want to use\n * [`CSSTransition`](https://reactcommunity.org/react-transition-group/css-transition)\n * instead. It inherits all the features of `Transition`, but contains\n * additional features necessary to play nice with CSS transitions (hence the\n * name of the component).\n *\n * ---\n *\n * By default the `Transition` component does not alter the behavior of the\n * component it renders, it only tracks \"enter\" and \"exit\" states for the\n * components. It's up to you to give meaning and effect to those states. For\n * example we can add styles to a component when it enters or exits:\n *\n * ```jsx\n * import { Transition } from 'react-transition-group';\n *\n * const duration = 300;\n *\n * const defaultStyle = {\n * transition: `opacity ${duration}ms ease-in-out`,\n * opacity: 0,\n * }\n *\n * const transitionStyles = {\n * entering: { opacity: 1 },\n * entered: { opacity: 1 },\n * exiting: { opacity: 0 },\n * exited: { opacity: 0 },\n * };\n *\n * const Fade = ({ in: inProp }) => (\n * \n * {state => (\n *
    \n * I'm a fade Transition!\n *
    \n * )}\n *
    \n * );\n * ```\n *\n * There are 4 main states a Transition can be in:\n * - `'entering'`\n * - `'entered'`\n * - `'exiting'`\n * - `'exited'`\n *\n * Transition state is toggled via the `in` prop. When `true` the component\n * begins the \"Enter\" stage. During this stage, the component will shift from\n * its current transition state, to `'entering'` for the duration of the\n * transition and then to the `'entered'` stage once it's complete. Let's take\n * the following example (we'll use the\n * [useState](https://reactjs.org/docs/hooks-reference.html#usestate) hook):\n *\n * ```jsx\n * function App() {\n * const [inProp, setInProp] = useState(false);\n * return (\n *
    \n * \n * {state => (\n * // ...\n * )}\n * \n * \n *
    \n * );\n * }\n * ```\n *\n * When the button is clicked the component will shift to the `'entering'` state\n * and stay there for 500ms (the value of `timeout`) before it finally switches\n * to `'entered'`.\n *\n * When `in` is `false` the same thing happens except the state moves from\n * `'exiting'` to `'exited'`.\n */\n\nvar Transition = /*#__PURE__*/function (_React$Component) {\n _inheritsLoose(Transition, _React$Component);\n\n function Transition(props, context) {\n var _this;\n\n _this = _React$Component.call(this, props, context) || this;\n var parentGroup = context; // In the context of a TransitionGroup all enters are really appears\n\n var appear = parentGroup && !parentGroup.isMounting ? props.enter : props.appear;\n var initialStatus;\n _this.appearStatus = null;\n\n if (props.in) {\n if (appear) {\n initialStatus = EXITED;\n _this.appearStatus = ENTERING;\n } else {\n initialStatus = ENTERED;\n }\n } else {\n if (props.unmountOnExit || props.mountOnEnter) {\n initialStatus = UNMOUNTED;\n } else {\n initialStatus = EXITED;\n }\n }\n\n _this.state = {\n status: initialStatus\n };\n _this.nextCallback = null;\n return _this;\n }\n\n Transition.getDerivedStateFromProps = function getDerivedStateFromProps(_ref, prevState) {\n var nextIn = _ref.in;\n\n if (nextIn && prevState.status === UNMOUNTED) {\n return {\n status: EXITED\n };\n }\n\n return null;\n } // getSnapshotBeforeUpdate(prevProps) {\n // let nextStatus = null\n // if (prevProps !== this.props) {\n // const { status } = this.state\n // if (this.props.in) {\n // if (status !== ENTERING && status !== ENTERED) {\n // nextStatus = ENTERING\n // }\n // } else {\n // if (status === ENTERING || status === ENTERED) {\n // nextStatus = EXITING\n // }\n // }\n // }\n // return { nextStatus }\n // }\n ;\n\n var _proto = Transition.prototype;\n\n _proto.componentDidMount = function componentDidMount() {\n this.updateStatus(true, this.appearStatus);\n };\n\n _proto.componentDidUpdate = function componentDidUpdate(prevProps) {\n var nextStatus = null;\n\n if (prevProps !== this.props) {\n var status = this.state.status;\n\n if (this.props.in) {\n if (status !== ENTERING && status !== ENTERED) {\n nextStatus = ENTERING;\n }\n } else {\n if (status === ENTERING || status === ENTERED) {\n nextStatus = EXITING;\n }\n }\n }\n\n this.updateStatus(false, nextStatus);\n };\n\n _proto.componentWillUnmount = function componentWillUnmount() {\n this.cancelNextCallback();\n };\n\n _proto.getTimeouts = function getTimeouts() {\n var timeout = this.props.timeout;\n var exit, enter, appear;\n exit = enter = appear = timeout;\n\n if (timeout != null && typeof timeout !== 'number') {\n exit = timeout.exit;\n enter = timeout.enter; // TODO: remove fallback for next major\n\n appear = timeout.appear !== undefined ? timeout.appear : enter;\n }\n\n return {\n exit: exit,\n enter: enter,\n appear: appear\n };\n };\n\n _proto.updateStatus = function updateStatus(mounting, nextStatus) {\n if (mounting === void 0) {\n mounting = false;\n }\n\n if (nextStatus !== null) {\n // nextStatus will always be ENTERING or EXITING.\n this.cancelNextCallback();\n\n if (nextStatus === ENTERING) {\n if (this.props.unmountOnExit || this.props.mountOnEnter) {\n var node = this.props.nodeRef ? this.props.nodeRef.current : ReactDOM.findDOMNode(this); // https://github.com/reactjs/react-transition-group/pull/749\n // With unmountOnExit or mountOnEnter, the enter animation should happen at the transition between `exited` and `entering`.\n // To make the animation happen, we have to separate each rendering and avoid being processed as batched.\n\n if (node) forceReflow(node);\n }\n\n this.performEnter(mounting);\n } else {\n this.performExit();\n }\n } else if (this.props.unmountOnExit && this.state.status === EXITED) {\n this.setState({\n status: UNMOUNTED\n });\n }\n };\n\n _proto.performEnter = function performEnter(mounting) {\n var _this2 = this;\n\n var enter = this.props.enter;\n var appearing = this.context ? this.context.isMounting : mounting;\n\n var _ref2 = this.props.nodeRef ? [appearing] : [ReactDOM.findDOMNode(this), appearing],\n maybeNode = _ref2[0],\n maybeAppearing = _ref2[1];\n\n var timeouts = this.getTimeouts();\n var enterTimeout = appearing ? timeouts.appear : timeouts.enter; // no enter animation skip right to ENTERED\n // if we are mounting and running this it means appear _must_ be set\n\n if (!mounting && !enter || config.disabled) {\n this.safeSetState({\n status: ENTERED\n }, function () {\n _this2.props.onEntered(maybeNode);\n });\n return;\n }\n\n this.props.onEnter(maybeNode, maybeAppearing);\n this.safeSetState({\n status: ENTERING\n }, function () {\n _this2.props.onEntering(maybeNode, maybeAppearing);\n\n _this2.onTransitionEnd(enterTimeout, function () {\n _this2.safeSetState({\n status: ENTERED\n }, function () {\n _this2.props.onEntered(maybeNode, maybeAppearing);\n });\n });\n });\n };\n\n _proto.performExit = function performExit() {\n var _this3 = this;\n\n var exit = this.props.exit;\n var timeouts = this.getTimeouts();\n var maybeNode = this.props.nodeRef ? undefined : ReactDOM.findDOMNode(this); // no exit animation skip right to EXITED\n\n if (!exit || config.disabled) {\n this.safeSetState({\n status: EXITED\n }, function () {\n _this3.props.onExited(maybeNode);\n });\n return;\n }\n\n this.props.onExit(maybeNode);\n this.safeSetState({\n status: EXITING\n }, function () {\n _this3.props.onExiting(maybeNode);\n\n _this3.onTransitionEnd(timeouts.exit, function () {\n _this3.safeSetState({\n status: EXITED\n }, function () {\n _this3.props.onExited(maybeNode);\n });\n });\n });\n };\n\n _proto.cancelNextCallback = function cancelNextCallback() {\n if (this.nextCallback !== null) {\n this.nextCallback.cancel();\n this.nextCallback = null;\n }\n };\n\n _proto.safeSetState = function safeSetState(nextState, callback) {\n // This shouldn't be necessary, but there are weird race conditions with\n // setState callbacks and unmounting in testing, so always make sure that\n // we can cancel any pending setState callbacks after we unmount.\n callback = this.setNextCallback(callback);\n this.setState(nextState, callback);\n };\n\n _proto.setNextCallback = function setNextCallback(callback) {\n var _this4 = this;\n\n var active = true;\n\n this.nextCallback = function (event) {\n if (active) {\n active = false;\n _this4.nextCallback = null;\n callback(event);\n }\n };\n\n this.nextCallback.cancel = function () {\n active = false;\n };\n\n return this.nextCallback;\n };\n\n _proto.onTransitionEnd = function onTransitionEnd(timeout, handler) {\n this.setNextCallback(handler);\n var node = this.props.nodeRef ? this.props.nodeRef.current : ReactDOM.findDOMNode(this);\n var doesNotHaveTimeoutOrListener = timeout == null && !this.props.addEndListener;\n\n if (!node || doesNotHaveTimeoutOrListener) {\n setTimeout(this.nextCallback, 0);\n return;\n }\n\n if (this.props.addEndListener) {\n var _ref3 = this.props.nodeRef ? [this.nextCallback] : [node, this.nextCallback],\n maybeNode = _ref3[0],\n maybeNextCallback = _ref3[1];\n\n this.props.addEndListener(maybeNode, maybeNextCallback);\n }\n\n if (timeout != null) {\n setTimeout(this.nextCallback, timeout);\n }\n };\n\n _proto.render = function render() {\n var status = this.state.status;\n\n if (status === UNMOUNTED) {\n return null;\n }\n\n var _this$props = this.props,\n children = _this$props.children,\n _in = _this$props.in,\n _mountOnEnter = _this$props.mountOnEnter,\n _unmountOnExit = _this$props.unmountOnExit,\n _appear = _this$props.appear,\n _enter = _this$props.enter,\n _exit = _this$props.exit,\n _timeout = _this$props.timeout,\n _addEndListener = _this$props.addEndListener,\n _onEnter = _this$props.onEnter,\n _onEntering = _this$props.onEntering,\n _onEntered = _this$props.onEntered,\n _onExit = _this$props.onExit,\n _onExiting = _this$props.onExiting,\n _onExited = _this$props.onExited,\n _nodeRef = _this$props.nodeRef,\n childProps = _objectWithoutPropertiesLoose(_this$props, [\"children\", \"in\", \"mountOnEnter\", \"unmountOnExit\", \"appear\", \"enter\", \"exit\", \"timeout\", \"addEndListener\", \"onEnter\", \"onEntering\", \"onEntered\", \"onExit\", \"onExiting\", \"onExited\", \"nodeRef\"]);\n\n return (\n /*#__PURE__*/\n // allows for nested Transitions\n React.createElement(TransitionGroupContext.Provider, {\n value: null\n }, typeof children === 'function' ? children(status, childProps) : React.cloneElement(React.Children.only(children), childProps))\n );\n };\n\n return Transition;\n}(React.Component);\n\nTransition.contextType = TransitionGroupContext;\nTransition.propTypes = process.env.NODE_ENV !== \"production\" ? {\n /**\n * A React reference to DOM element that need to transition:\n * https://stackoverflow.com/a/51127130/4671932\n *\n * - When `nodeRef` prop is used, `node` is not passed to callback functions\n * (e.g. `onEnter`) because user already has direct access to the node.\n * - When changing `key` prop of `Transition` in a `TransitionGroup` a new\n * `nodeRef` need to be provided to `Transition` with changed `key` prop\n * (see\n * [test/CSSTransition-test.js](https://github.com/reactjs/react-transition-group/blob/13435f897b3ab71f6e19d724f145596f5910581c/test/CSSTransition-test.js#L362-L437)).\n */\n nodeRef: PropTypes.shape({\n current: typeof Element === 'undefined' ? PropTypes.any : function (propValue, key, componentName, location, propFullName, secret) {\n var value = propValue[key];\n return PropTypes.instanceOf(value && 'ownerDocument' in value ? value.ownerDocument.defaultView.Element : Element)(propValue, key, componentName, location, propFullName, secret);\n }\n }),\n\n /**\n * A `function` child can be used instead of a React element. This function is\n * called with the current transition status (`'entering'`, `'entered'`,\n * `'exiting'`, `'exited'`), which can be used to apply context\n * specific props to a component.\n *\n * ```jsx\n * \n * {state => (\n * \n * )}\n * \n * ```\n */\n children: PropTypes.oneOfType([PropTypes.func.isRequired, PropTypes.element.isRequired]).isRequired,\n\n /**\n * Show the component; triggers the enter or exit states\n */\n in: PropTypes.bool,\n\n /**\n * By default the child component is mounted immediately along with\n * the parent `Transition` component. If you want to \"lazy mount\" the component on the\n * first `in={true}` you can set `mountOnEnter`. After the first enter transition the component will stay\n * mounted, even on \"exited\", unless you also specify `unmountOnExit`.\n */\n mountOnEnter: PropTypes.bool,\n\n /**\n * By default the child component stays mounted after it reaches the `'exited'` state.\n * Set `unmountOnExit` if you'd prefer to unmount the component after it finishes exiting.\n */\n unmountOnExit: PropTypes.bool,\n\n /**\n * By default the child component does not perform the enter transition when\n * it first mounts, regardless of the value of `in`. If you want this\n * behavior, set both `appear` and `in` to `true`.\n *\n * > **Note**: there are no special appear states like `appearing`/`appeared`, this prop\n * > only adds an additional enter transition. However, in the\n * > `` component that first enter transition does result in\n * > additional `.appear-*` classes, that way you can choose to style it\n * > differently.\n */\n appear: PropTypes.bool,\n\n /**\n * Enable or disable enter transitions.\n */\n enter: PropTypes.bool,\n\n /**\n * Enable or disable exit transitions.\n */\n exit: PropTypes.bool,\n\n /**\n * The duration of the transition, in milliseconds.\n * Required unless `addEndListener` is provided.\n *\n * You may specify a single timeout for all transitions:\n *\n * ```jsx\n * timeout={500}\n * ```\n *\n * or individually:\n *\n * ```jsx\n * timeout={{\n * appear: 500,\n * enter: 300,\n * exit: 500,\n * }}\n * ```\n *\n * - `appear` defaults to the value of `enter`\n * - `enter` defaults to `0`\n * - `exit` defaults to `0`\n *\n * @type {number | { enter?: number, exit?: number, appear?: number }}\n */\n timeout: function timeout(props) {\n var pt = timeoutsShape;\n if (!props.addEndListener) pt = pt.isRequired;\n\n for (var _len = arguments.length, args = new Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) {\n args[_key - 1] = arguments[_key];\n }\n\n return pt.apply(void 0, [props].concat(args));\n },\n\n /**\n * Add a custom transition end trigger. Called with the transitioning\n * DOM node and a `done` callback. Allows for more fine grained transition end\n * logic. Timeouts are still used as a fallback if provided.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * ```jsx\n * addEndListener={(node, done) => {\n * // use the css transitionend event to mark the finish of a transition\n * node.addEventListener('transitionend', done, false);\n * }}\n * ```\n */\n addEndListener: PropTypes.func,\n\n /**\n * Callback fired before the \"entering\" status is applied. An extra parameter\n * `isAppearing` is supplied to indicate if the enter stage is occurring on the initial mount\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement, isAppearing: bool) -> void\n */\n onEnter: PropTypes.func,\n\n /**\n * Callback fired after the \"entering\" status is applied. An extra parameter\n * `isAppearing` is supplied to indicate if the enter stage is occurring on the initial mount\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement, isAppearing: bool)\n */\n onEntering: PropTypes.func,\n\n /**\n * Callback fired after the \"entered\" status is applied. An extra parameter\n * `isAppearing` is supplied to indicate if the enter stage is occurring on the initial mount\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement, isAppearing: bool) -> void\n */\n onEntered: PropTypes.func,\n\n /**\n * Callback fired before the \"exiting\" status is applied.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement) -> void\n */\n onExit: PropTypes.func,\n\n /**\n * Callback fired after the \"exiting\" status is applied.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement) -> void\n */\n onExiting: PropTypes.func,\n\n /**\n * Callback fired after the \"exited\" status is applied.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed\n *\n * @type Function(node: HtmlElement) -> void\n */\n onExited: PropTypes.func\n} : {}; // Name the function so it is clearer in the documentation\n\nfunction noop() {}\n\nTransition.defaultProps = {\n in: false,\n mountOnEnter: false,\n unmountOnExit: false,\n appear: false,\n enter: true,\n exit: true,\n onEnter: noop,\n onEntering: noop,\n onEntered: noop,\n onExit: noop,\n onExiting: noop,\n onExited: noop\n};\nTransition.UNMOUNTED = UNMOUNTED;\nTransition.EXITED = EXITED;\nTransition.ENTERING = ENTERING;\nTransition.ENTERED = ENTERED;\nTransition.EXITING = EXITING;\nexport default Transition;","export const reflow = node => node.scrollTop;\nexport function getTransitionProps(props, options) {\n var _style$transitionDura, _style$transitionTimi;\n const {\n timeout,\n easing,\n style = {}\n } = props;\n return {\n duration: (_style$transitionDura = style.transitionDuration) != null ? _style$transitionDura : typeof timeout === 'number' ? timeout : timeout[options.mode] || 0,\n easing: (_style$transitionTimi = style.transitionTimingFunction) != null ? _style$transitionTimi : typeof easing === 'object' ? easing[options.mode] : easing,\n delay: style.transitionDelay\n };\n}","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"addEndListener\", \"appear\", \"children\", \"easing\", \"in\", \"onEnter\", \"onEntered\", \"onEntering\", \"onExit\", \"onExited\", \"onExiting\", \"style\", \"timeout\", \"TransitionComponent\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport { elementAcceptingRef, unstable_useTimeout as useTimeout } from '@mui/utils';\nimport { Transition } from 'react-transition-group';\nimport useTheme from '../styles/useTheme';\nimport { getTransitionProps, reflow } from '../transitions/utils';\nimport useForkRef from '../utils/useForkRef';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nfunction getScale(value) {\n return `scale(${value}, ${value ** 2})`;\n}\nconst styles = {\n entering: {\n opacity: 1,\n transform: getScale(1)\n },\n entered: {\n opacity: 1,\n transform: 'none'\n }\n};\n\n/*\n TODO v6: remove\n Conditionally apply a workaround for the CSS transition bug in Safari 15.4 / WebKit browsers.\n */\nconst isWebKit154 = typeof navigator !== 'undefined' && /^((?!chrome|android).)*(safari|mobile)/i.test(navigator.userAgent) && /(os |version\\/)15(.|_)4/i.test(navigator.userAgent);\n\n/**\n * The Grow transition is used by the [Tooltip](/material-ui/react-tooltip/) and\n * [Popover](/material-ui/react-popover/) components.\n * It uses [react-transition-group](https://github.com/reactjs/react-transition-group) internally.\n */\nconst Grow = /*#__PURE__*/React.forwardRef(function Grow(props, ref) {\n const {\n addEndListener,\n appear = true,\n children,\n easing,\n in: inProp,\n onEnter,\n onEntered,\n onEntering,\n onExit,\n onExited,\n onExiting,\n style,\n timeout = 'auto',\n // eslint-disable-next-line react/prop-types\n TransitionComponent = Transition\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const timer = useTimeout();\n const autoTimeout = React.useRef();\n const theme = useTheme();\n const nodeRef = React.useRef(null);\n const handleRef = useForkRef(nodeRef, children.ref, ref);\n const normalizedTransitionCallback = callback => maybeIsAppearing => {\n if (callback) {\n const node = nodeRef.current;\n\n // onEnterXxx and onExitXxx callbacks have a different arguments.length value.\n if (maybeIsAppearing === undefined) {\n callback(node);\n } else {\n callback(node, maybeIsAppearing);\n }\n }\n };\n const handleEntering = normalizedTransitionCallback(onEntering);\n const handleEnter = normalizedTransitionCallback((node, isAppearing) => {\n reflow(node); // So the animation always start from the start.\n\n const {\n duration: transitionDuration,\n delay,\n easing: transitionTimingFunction\n } = getTransitionProps({\n style,\n timeout,\n easing\n }, {\n mode: 'enter'\n });\n let duration;\n if (timeout === 'auto') {\n duration = theme.transitions.getAutoHeightDuration(node.clientHeight);\n autoTimeout.current = duration;\n } else {\n duration = transitionDuration;\n }\n node.style.transition = [theme.transitions.create('opacity', {\n duration,\n delay\n }), theme.transitions.create('transform', {\n duration: isWebKit154 ? duration : duration * 0.666,\n delay,\n easing: transitionTimingFunction\n })].join(',');\n if (onEnter) {\n onEnter(node, isAppearing);\n }\n });\n const handleEntered = normalizedTransitionCallback(onEntered);\n const handleExiting = normalizedTransitionCallback(onExiting);\n const handleExit = normalizedTransitionCallback(node => {\n const {\n duration: transitionDuration,\n delay,\n easing: transitionTimingFunction\n } = getTransitionProps({\n style,\n timeout,\n easing\n }, {\n mode: 'exit'\n });\n let duration;\n if (timeout === 'auto') {\n duration = theme.transitions.getAutoHeightDuration(node.clientHeight);\n autoTimeout.current = duration;\n } else {\n duration = transitionDuration;\n }\n node.style.transition = [theme.transitions.create('opacity', {\n duration,\n delay\n }), theme.transitions.create('transform', {\n duration: isWebKit154 ? duration : duration * 0.666,\n delay: isWebKit154 ? delay : delay || duration * 0.333,\n easing: transitionTimingFunction\n })].join(',');\n node.style.opacity = 0;\n node.style.transform = getScale(0.75);\n if (onExit) {\n onExit(node);\n }\n });\n const handleExited = normalizedTransitionCallback(onExited);\n const handleAddEndListener = next => {\n if (timeout === 'auto') {\n timer.start(autoTimeout.current || 0, next);\n }\n if (addEndListener) {\n // Old call signature before `react-transition-group` implemented `nodeRef`\n addEndListener(nodeRef.current, next);\n }\n };\n return /*#__PURE__*/_jsx(TransitionComponent, _extends({\n appear: appear,\n in: inProp,\n nodeRef: nodeRef,\n onEnter: handleEnter,\n onEntered: handleEntered,\n onEntering: handleEntering,\n onExit: handleExit,\n onExited: handleExited,\n onExiting: handleExiting,\n addEndListener: handleAddEndListener,\n timeout: timeout === 'auto' ? null : timeout\n }, other, {\n children: (state, childProps) => {\n return /*#__PURE__*/React.cloneElement(children, _extends({\n style: _extends({\n opacity: 0,\n transform: getScale(0.75),\n visibility: state === 'exited' && !inProp ? 'hidden' : undefined\n }, styles[state], style, children.props.style),\n ref: handleRef\n }, childProps));\n }\n }));\n});\nprocess.env.NODE_ENV !== \"production\" ? Grow.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the d.ts file and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * Add a custom transition end trigger. Called with the transitioning DOM\n * node and a done callback. Allows for more fine grained transition end\n * logic. Note: Timeouts are still used as a fallback if provided.\n */\n addEndListener: PropTypes.func,\n /**\n * Perform the enter transition when it first mounts if `in` is also `true`.\n * Set this to `false` to disable this behavior.\n * @default true\n */\n appear: PropTypes.bool,\n /**\n * A single child content element.\n */\n children: elementAcceptingRef.isRequired,\n /**\n * The transition timing function.\n * You may specify a single easing or a object containing enter and exit values.\n */\n easing: PropTypes.oneOfType([PropTypes.shape({\n enter: PropTypes.string,\n exit: PropTypes.string\n }), PropTypes.string]),\n /**\n * If `true`, the component will transition in.\n */\n in: PropTypes.bool,\n /**\n * @ignore\n */\n onEnter: PropTypes.func,\n /**\n * @ignore\n */\n onEntered: PropTypes.func,\n /**\n * @ignore\n */\n onEntering: PropTypes.func,\n /**\n * @ignore\n */\n onExit: PropTypes.func,\n /**\n * @ignore\n */\n onExited: PropTypes.func,\n /**\n * @ignore\n */\n onExiting: PropTypes.func,\n /**\n * @ignore\n */\n style: PropTypes.object,\n /**\n * The duration for the transition, in milliseconds.\n * You may specify a single timeout for all transitions, or individually with an object.\n *\n * Set to 'auto' to automatically calculate transition time based on height.\n * @default 'auto'\n */\n timeout: PropTypes.oneOfType([PropTypes.oneOf(['auto']), PropTypes.number, PropTypes.shape({\n appear: PropTypes.number,\n enter: PropTypes.number,\n exit: PropTypes.number\n })])\n} : void 0;\nGrow.muiSupportAuto = true;\nexport default Grow;","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"anchorEl\", \"component\", \"components\", \"componentsProps\", \"container\", \"disablePortal\", \"keepMounted\", \"modifiers\", \"open\", \"placement\", \"popperOptions\", \"popperRef\", \"transition\", \"slots\", \"slotProps\"];\nimport { Popper as BasePopper } from '@mui/base/Popper';\nimport { useThemeWithoutDefault as useTheme } from '@mui/system';\nimport { HTMLElementType, refType } from '@mui/utils';\nimport PropTypes from 'prop-types';\nimport * as React from 'react';\nimport { styled, useThemeProps } from '../styles';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nconst PopperRoot = styled(BasePopper, {\n name: 'MuiPopper',\n slot: 'Root',\n overridesResolver: (props, styles) => styles.root\n})({});\n\n/**\n *\n * Demos:\n *\n * - [Autocomplete](https://mui.com/material-ui/react-autocomplete/)\n * - [Menu](https://mui.com/material-ui/react-menu/)\n * - [Popper](https://mui.com/material-ui/react-popper/)\n *\n * API:\n *\n * - [Popper API](https://mui.com/material-ui/api/popper/)\n */\nconst Popper = /*#__PURE__*/React.forwardRef(function Popper(inProps, ref) {\n var _slots$root;\n const theme = useTheme();\n const props = useThemeProps({\n props: inProps,\n name: 'MuiPopper'\n });\n const {\n anchorEl,\n component,\n components,\n componentsProps,\n container,\n disablePortal,\n keepMounted,\n modifiers,\n open,\n placement,\n popperOptions,\n popperRef,\n transition,\n slots,\n slotProps\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const RootComponent = (_slots$root = slots == null ? void 0 : slots.root) != null ? _slots$root : components == null ? void 0 : components.Root;\n const otherProps = _extends({\n anchorEl,\n container,\n disablePortal,\n keepMounted,\n modifiers,\n open,\n placement,\n popperOptions,\n popperRef,\n transition\n }, other);\n return /*#__PURE__*/_jsx(PopperRoot, _extends({\n as: component,\n direction: theme == null ? void 0 : theme.direction,\n slots: {\n root: RootComponent\n },\n slotProps: slotProps != null ? slotProps : componentsProps\n }, otherProps, {\n ref: ref\n }));\n});\nprocess.env.NODE_ENV !== \"production\" ? Popper.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * An HTML element, [virtualElement](https://popper.js.org/docs/v2/virtual-elements/),\n * or a function that returns either.\n * It's used to set the position of the popper.\n * The return value will passed as the reference object of the Popper instance.\n */\n anchorEl: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.object, PropTypes.func]),\n /**\n * Popper render function or node.\n */\n children: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.node, PropTypes.func]),\n /**\n * The component used for the root node.\n * Either a string to use a HTML element or a component.\n */\n component: PropTypes.elementType,\n /**\n * The components used for each slot inside the Popper.\n * Either a string to use a HTML element or a component.\n * @default {}\n */\n components: PropTypes.shape({\n Root: PropTypes.elementType\n }),\n /**\n * The props used for each slot inside the Popper.\n * @default {}\n */\n componentsProps: PropTypes.shape({\n root: PropTypes.oneOfType([PropTypes.func, PropTypes.object])\n }),\n /**\n * An HTML element or function that returns one.\n * The `container` will have the portal children appended to it.\n *\n * You can also provide a callback, which is called in a React layout effect.\n * This lets you set the container from a ref, and also makes server-side rendering possible.\n *\n * By default, it uses the body of the top-level document object,\n * so it's simply `document.body` most of the time.\n */\n container: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.func]),\n /**\n * The `children` will be under the DOM hierarchy of the parent component.\n * @default false\n */\n disablePortal: PropTypes.bool,\n /**\n * Always keep the children in the DOM.\n * This prop can be useful in SEO situation or\n * when you want to maximize the responsiveness of the Popper.\n * @default false\n */\n keepMounted: PropTypes.bool,\n /**\n * Popper.js is based on a \"plugin-like\" architecture,\n * most of its features are fully encapsulated \"modifiers\".\n *\n * A modifier is a function that is called each time Popper.js needs to\n * compute the position of the popper.\n * For this reason, modifiers should be very performant to avoid bottlenecks.\n * To learn how to create a modifier, [read the modifiers documentation](https://popper.js.org/docs/v2/modifiers/).\n */\n modifiers: PropTypes.arrayOf(PropTypes.shape({\n data: PropTypes.object,\n effect: PropTypes.func,\n enabled: PropTypes.bool,\n fn: PropTypes.func,\n name: PropTypes.any,\n options: PropTypes.object,\n phase: PropTypes.oneOf(['afterMain', 'afterRead', 'afterWrite', 'beforeMain', 'beforeRead', 'beforeWrite', 'main', 'read', 'write']),\n requires: PropTypes.arrayOf(PropTypes.string),\n requiresIfExists: PropTypes.arrayOf(PropTypes.string)\n })),\n /**\n * If `true`, the component is shown.\n */\n open: PropTypes.bool.isRequired,\n /**\n * Popper placement.\n * @default 'bottom'\n */\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n /**\n * Options provided to the [`Popper.js`](https://popper.js.org/docs/v2/constructors/#options) instance.\n * @default {}\n */\n popperOptions: PropTypes.shape({\n modifiers: PropTypes.array,\n onFirstUpdate: PropTypes.func,\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n strategy: PropTypes.oneOf(['absolute', 'fixed'])\n }),\n /**\n * A ref that points to the used popper instance.\n */\n popperRef: refType,\n /**\n * The props used for each slot inside the Popper.\n * @default {}\n */\n slotProps: PropTypes.shape({\n root: PropTypes.oneOfType([PropTypes.func, PropTypes.object])\n }),\n /**\n * The components used for each slot inside the Popper.\n * Either a string to use a HTML element or a component.\n * @default {}\n */\n slots: PropTypes.shape({\n root: PropTypes.elementType\n }),\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Help supporting a react-transition-group/Transition component.\n * @default false\n */\n transition: PropTypes.bool\n} : void 0;\nexport default Popper;","import generateUtilityClasses from '@mui/utils/generateUtilityClasses';\nimport generateUtilityClass from '@mui/utils/generateUtilityClass';\nexport function getTooltipUtilityClass(slot) {\n return generateUtilityClass('MuiTooltip', slot);\n}\nconst tooltipClasses = generateUtilityClasses('MuiTooltip', ['popper', 'popperInteractive', 'popperArrow', 'popperClose', 'tooltip', 'tooltipArrow', 'touch', 'tooltipPlacementLeft', 'tooltipPlacementRight', 'tooltipPlacementTop', 'tooltipPlacementBottom', 'arrow']);\nexport default tooltipClasses;","'use client';\n\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nconst _excluded = [\"arrow\", \"children\", \"classes\", \"components\", \"componentsProps\", \"describeChild\", \"disableFocusListener\", \"disableHoverListener\", \"disableInteractive\", \"disableTouchListener\", \"enterDelay\", \"enterNextDelay\", \"enterTouchDelay\", \"followCursor\", \"id\", \"leaveDelay\", \"leaveTouchDelay\", \"onClose\", \"onOpen\", \"open\", \"placement\", \"PopperComponent\", \"PopperProps\", \"slotProps\", \"slots\", \"title\", \"TransitionComponent\", \"TransitionProps\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport clsx from 'clsx';\nimport { elementAcceptingRef, unstable_useTimeout as useTimeout, unstable_Timeout as Timeout } from '@mui/utils';\nimport { unstable_composeClasses as composeClasses, appendOwnerState } from '@mui/base';\nimport { alpha } from '@mui/system';\nimport styled from '../styles/styled';\nimport useTheme from '../styles/useTheme';\nimport useThemeProps from '../styles/useThemeProps';\nimport capitalize from '../utils/capitalize';\nimport Grow from '../Grow';\nimport Popper from '../Popper';\nimport useEventCallback from '../utils/useEventCallback';\nimport useForkRef from '../utils/useForkRef';\nimport useId from '../utils/useId';\nimport useIsFocusVisible from '../utils/useIsFocusVisible';\nimport useControlled from '../utils/useControlled';\nimport tooltipClasses, { getTooltipUtilityClass } from './tooltipClasses';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nimport { jsxs as _jsxs } from \"react/jsx-runtime\";\nfunction round(value) {\n return Math.round(value * 1e5) / 1e5;\n}\nconst useUtilityClasses = ownerState => {\n const {\n classes,\n disableInteractive,\n arrow,\n touch,\n placement\n } = ownerState;\n const slots = {\n popper: ['popper', !disableInteractive && 'popperInteractive', arrow && 'popperArrow'],\n tooltip: ['tooltip', arrow && 'tooltipArrow', touch && 'touch', `tooltipPlacement${capitalize(placement.split('-')[0])}`],\n arrow: ['arrow']\n };\n return composeClasses(slots, getTooltipUtilityClass, classes);\n};\nconst TooltipPopper = styled(Popper, {\n name: 'MuiTooltip',\n slot: 'Popper',\n overridesResolver: (props, styles) => {\n const {\n ownerState\n } = props;\n return [styles.popper, !ownerState.disableInteractive && styles.popperInteractive, ownerState.arrow && styles.popperArrow, !ownerState.open && styles.popperClose];\n }\n})(({\n theme,\n ownerState,\n open\n}) => _extends({\n zIndex: (theme.vars || theme).zIndex.tooltip,\n pointerEvents: 'none'\n}, !ownerState.disableInteractive && {\n pointerEvents: 'auto'\n}, !open && {\n pointerEvents: 'none'\n}, ownerState.arrow && {\n [`&[data-popper-placement*=\"bottom\"] .${tooltipClasses.arrow}`]: {\n top: 0,\n marginTop: '-0.71em',\n '&::before': {\n transformOrigin: '0 100%'\n }\n },\n [`&[data-popper-placement*=\"top\"] .${tooltipClasses.arrow}`]: {\n bottom: 0,\n marginBottom: '-0.71em',\n '&::before': {\n transformOrigin: '100% 0'\n }\n },\n [`&[data-popper-placement*=\"right\"] .${tooltipClasses.arrow}`]: _extends({}, !ownerState.isRtl ? {\n left: 0,\n marginLeft: '-0.71em'\n } : {\n right: 0,\n marginRight: '-0.71em'\n }, {\n height: '1em',\n width: '0.71em',\n '&::before': {\n transformOrigin: '100% 100%'\n }\n }),\n [`&[data-popper-placement*=\"left\"] .${tooltipClasses.arrow}`]: _extends({}, !ownerState.isRtl ? {\n right: 0,\n marginRight: '-0.71em'\n } : {\n left: 0,\n marginLeft: '-0.71em'\n }, {\n height: '1em',\n width: '0.71em',\n '&::before': {\n transformOrigin: '0 0'\n }\n })\n}));\nconst TooltipTooltip = styled('div', {\n name: 'MuiTooltip',\n slot: 'Tooltip',\n overridesResolver: (props, styles) => {\n const {\n ownerState\n } = props;\n return [styles.tooltip, ownerState.touch && styles.touch, ownerState.arrow && styles.tooltipArrow, styles[`tooltipPlacement${capitalize(ownerState.placement.split('-')[0])}`]];\n }\n})(({\n theme,\n ownerState\n}) => _extends({\n backgroundColor: theme.vars ? theme.vars.palette.Tooltip.bg : alpha(theme.palette.grey[700], 0.92),\n borderRadius: (theme.vars || theme).shape.borderRadius,\n color: (theme.vars || theme).palette.common.white,\n fontFamily: theme.typography.fontFamily,\n padding: '4px 8px',\n fontSize: theme.typography.pxToRem(11),\n maxWidth: 300,\n margin: 2,\n wordWrap: 'break-word',\n fontWeight: theme.typography.fontWeightMedium\n}, ownerState.arrow && {\n position: 'relative',\n margin: 0\n}, ownerState.touch && {\n padding: '8px 16px',\n fontSize: theme.typography.pxToRem(14),\n lineHeight: `${round(16 / 14)}em`,\n fontWeight: theme.typography.fontWeightRegular\n}, {\n [`.${tooltipClasses.popper}[data-popper-placement*=\"left\"] &`]: _extends({\n transformOrigin: 'right center'\n }, !ownerState.isRtl ? _extends({\n marginRight: '14px'\n }, ownerState.touch && {\n marginRight: '24px'\n }) : _extends({\n marginLeft: '14px'\n }, ownerState.touch && {\n marginLeft: '24px'\n })),\n [`.${tooltipClasses.popper}[data-popper-placement*=\"right\"] &`]: _extends({\n transformOrigin: 'left center'\n }, !ownerState.isRtl ? _extends({\n marginLeft: '14px'\n }, ownerState.touch && {\n marginLeft: '24px'\n }) : _extends({\n marginRight: '14px'\n }, ownerState.touch && {\n marginRight: '24px'\n })),\n [`.${tooltipClasses.popper}[data-popper-placement*=\"top\"] &`]: _extends({\n transformOrigin: 'center bottom',\n marginBottom: '14px'\n }, ownerState.touch && {\n marginBottom: '24px'\n }),\n [`.${tooltipClasses.popper}[data-popper-placement*=\"bottom\"] &`]: _extends({\n transformOrigin: 'center top',\n marginTop: '14px'\n }, ownerState.touch && {\n marginTop: '24px'\n })\n}));\nconst TooltipArrow = styled('span', {\n name: 'MuiTooltip',\n slot: 'Arrow',\n overridesResolver: (props, styles) => styles.arrow\n})(({\n theme\n}) => ({\n overflow: 'hidden',\n position: 'absolute',\n width: '1em',\n height: '0.71em' /* = width / sqrt(2) = (length of the hypotenuse) */,\n boxSizing: 'border-box',\n color: theme.vars ? theme.vars.palette.Tooltip.bg : alpha(theme.palette.grey[700], 0.9),\n '&::before': {\n content: '\"\"',\n margin: 'auto',\n display: 'block',\n width: '100%',\n height: '100%',\n backgroundColor: 'currentColor',\n transform: 'rotate(45deg)'\n }\n}));\nlet hystersisOpen = false;\nconst hystersisTimer = new Timeout();\nlet cursorPosition = {\n x: 0,\n y: 0\n};\nexport function testReset() {\n hystersisOpen = false;\n hystersisTimer.clear();\n}\nfunction composeEventHandler(handler, eventHandler) {\n return event => {\n if (eventHandler) {\n eventHandler(event);\n }\n handler(event);\n };\n}\n\n// TODO v6: Remove PopperComponent, PopperProps, TransitionComponent and TransitionProps.\nconst Tooltip = /*#__PURE__*/React.forwardRef(function Tooltip(inProps, ref) {\n var _ref, _slots$popper, _ref2, _ref3, _slots$transition, _ref4, _slots$tooltip, _ref5, _slots$arrow, _slotProps$popper, _ref6, _slotProps$popper2, _slotProps$transition, _slotProps$tooltip, _ref7, _slotProps$tooltip2, _slotProps$arrow, _ref8, _slotProps$arrow2;\n const props = useThemeProps({\n props: inProps,\n name: 'MuiTooltip'\n });\n const {\n arrow = false,\n children: childrenProp,\n components = {},\n componentsProps = {},\n describeChild = false,\n disableFocusListener = false,\n disableHoverListener = false,\n disableInteractive: disableInteractiveProp = false,\n disableTouchListener = false,\n enterDelay = 100,\n enterNextDelay = 0,\n enterTouchDelay = 700,\n followCursor = false,\n id: idProp,\n leaveDelay = 0,\n leaveTouchDelay = 1500,\n onClose,\n onOpen,\n open: openProp,\n placement = 'bottom',\n PopperComponent: PopperComponentProp,\n PopperProps = {},\n slotProps = {},\n slots = {},\n title,\n TransitionComponent: TransitionComponentProp = Grow,\n TransitionProps\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n\n // to prevent runtime errors, developers will need to provide a child as a React element anyway.\n const children = /*#__PURE__*/React.isValidElement(childrenProp) ? childrenProp : /*#__PURE__*/_jsx(\"span\", {\n children: childrenProp\n });\n const theme = useTheme();\n const isRtl = theme.direction === 'rtl';\n const [childNode, setChildNode] = React.useState();\n const [arrowRef, setArrowRef] = React.useState(null);\n const ignoreNonTouchEvents = React.useRef(false);\n const disableInteractive = disableInteractiveProp || followCursor;\n const closeTimer = useTimeout();\n const enterTimer = useTimeout();\n const leaveTimer = useTimeout();\n const touchTimer = useTimeout();\n const [openState, setOpenState] = useControlled({\n controlled: openProp,\n default: false,\n name: 'Tooltip',\n state: 'open'\n });\n let open = openState;\n if (process.env.NODE_ENV !== 'production') {\n // eslint-disable-next-line react-hooks/rules-of-hooks\n const {\n current: isControlled\n } = React.useRef(openProp !== undefined);\n\n // eslint-disable-next-line react-hooks/rules-of-hooks\n React.useEffect(() => {\n if (childNode && childNode.disabled && !isControlled && title !== '' && childNode.tagName.toLowerCase() === 'button') {\n console.error(['MUI: You are providing a disabled `button` child to the Tooltip component.', 'A disabled element does not fire events.', \"Tooltip needs to listen to the child element's events to display the title.\", '', 'Add a simple wrapper element, such as a `span`.'].join('\\n'));\n }\n }, [title, childNode, isControlled]);\n }\n const id = useId(idProp);\n const prevUserSelect = React.useRef();\n const stopTouchInteraction = useEventCallback(() => {\n if (prevUserSelect.current !== undefined) {\n document.body.style.WebkitUserSelect = prevUserSelect.current;\n prevUserSelect.current = undefined;\n }\n touchTimer.clear();\n });\n React.useEffect(() => stopTouchInteraction, [stopTouchInteraction]);\n const handleOpen = event => {\n hystersisTimer.clear();\n hystersisOpen = true;\n\n // The mouseover event will trigger for every nested element in the tooltip.\n // We can skip rerendering when the tooltip is already open.\n // We are using the mouseover event instead of the mouseenter event to fix a hide/show issue.\n setOpenState(true);\n if (onOpen && !open) {\n onOpen(event);\n }\n };\n const handleClose = useEventCallback(\n /**\n * @param {React.SyntheticEvent | Event} event\n */\n event => {\n hystersisTimer.start(800 + leaveDelay, () => {\n hystersisOpen = false;\n });\n setOpenState(false);\n if (onClose && open) {\n onClose(event);\n }\n closeTimer.start(theme.transitions.duration.shortest, () => {\n ignoreNonTouchEvents.current = false;\n });\n });\n const handleEnter = event => {\n if (ignoreNonTouchEvents.current && event.type !== 'touchstart') {\n return;\n }\n\n // Remove the title ahead of time.\n // We don't want to wait for the next render commit.\n // We would risk displaying two tooltips at the same time (native + this one).\n if (childNode) {\n childNode.removeAttribute('title');\n }\n enterTimer.clear();\n leaveTimer.clear();\n if (enterDelay || hystersisOpen && enterNextDelay) {\n enterTimer.start(hystersisOpen ? enterNextDelay : enterDelay, () => {\n handleOpen(event);\n });\n } else {\n handleOpen(event);\n }\n };\n const handleLeave = event => {\n enterTimer.clear();\n leaveTimer.start(leaveDelay, () => {\n handleClose(event);\n });\n };\n const {\n isFocusVisibleRef,\n onBlur: handleBlurVisible,\n onFocus: handleFocusVisible,\n ref: focusVisibleRef\n } = useIsFocusVisible();\n // We don't necessarily care about the focusVisible state (which is safe to access via ref anyway).\n // We just need to re-render the Tooltip if the focus-visible state changes.\n const [, setChildIsFocusVisible] = React.useState(false);\n const handleBlur = event => {\n handleBlurVisible(event);\n if (isFocusVisibleRef.current === false) {\n setChildIsFocusVisible(false);\n handleLeave(event);\n }\n };\n const handleFocus = event => {\n // Workaround for https://github.com/facebook/react/issues/7769\n // The autoFocus of React might trigger the event before the componentDidMount.\n // We need to account for this eventuality.\n if (!childNode) {\n setChildNode(event.currentTarget);\n }\n handleFocusVisible(event);\n if (isFocusVisibleRef.current === true) {\n setChildIsFocusVisible(true);\n handleEnter(event);\n }\n };\n const detectTouchStart = event => {\n ignoreNonTouchEvents.current = true;\n const childrenProps = children.props;\n if (childrenProps.onTouchStart) {\n childrenProps.onTouchStart(event);\n }\n };\n const handleMouseOver = handleEnter;\n const handleMouseLeave = handleLeave;\n const handleTouchStart = event => {\n detectTouchStart(event);\n leaveTimer.clear();\n closeTimer.clear();\n stopTouchInteraction();\n prevUserSelect.current = document.body.style.WebkitUserSelect;\n // Prevent iOS text selection on long-tap.\n document.body.style.WebkitUserSelect = 'none';\n touchTimer.start(enterTouchDelay, () => {\n document.body.style.WebkitUserSelect = prevUserSelect.current;\n handleEnter(event);\n });\n };\n const handleTouchEnd = event => {\n if (children.props.onTouchEnd) {\n children.props.onTouchEnd(event);\n }\n stopTouchInteraction();\n leaveTimer.start(leaveTouchDelay, () => {\n handleClose(event);\n });\n };\n React.useEffect(() => {\n if (!open) {\n return undefined;\n }\n\n /**\n * @param {KeyboardEvent} nativeEvent\n */\n function handleKeyDown(nativeEvent) {\n // IE11, Edge (prior to using Bink?) use 'Esc'\n if (nativeEvent.key === 'Escape' || nativeEvent.key === 'Esc') {\n handleClose(nativeEvent);\n }\n }\n document.addEventListener('keydown', handleKeyDown);\n return () => {\n document.removeEventListener('keydown', handleKeyDown);\n };\n }, [handleClose, open]);\n const handleRef = useForkRef(children.ref, focusVisibleRef, setChildNode, ref);\n\n // There is no point in displaying an empty tooltip.\n // So we exclude all falsy values, except 0, which is valid.\n if (!title && title !== 0) {\n open = false;\n }\n const popperRef = React.useRef();\n const handleMouseMove = event => {\n const childrenProps = children.props;\n if (childrenProps.onMouseMove) {\n childrenProps.onMouseMove(event);\n }\n cursorPosition = {\n x: event.clientX,\n y: event.clientY\n };\n if (popperRef.current) {\n popperRef.current.update();\n }\n };\n const nameOrDescProps = {};\n const titleIsString = typeof title === 'string';\n if (describeChild) {\n nameOrDescProps.title = !open && titleIsString && !disableHoverListener ? title : null;\n nameOrDescProps['aria-describedby'] = open ? id : null;\n } else {\n nameOrDescProps['aria-label'] = titleIsString ? title : null;\n nameOrDescProps['aria-labelledby'] = open && !titleIsString ? id : null;\n }\n const childrenProps = _extends({}, nameOrDescProps, other, children.props, {\n className: clsx(other.className, children.props.className),\n onTouchStart: detectTouchStart,\n ref: handleRef\n }, followCursor ? {\n onMouseMove: handleMouseMove\n } : {});\n if (process.env.NODE_ENV !== 'production') {\n childrenProps['data-mui-internal-clone-element'] = true;\n\n // eslint-disable-next-line react-hooks/rules-of-hooks\n React.useEffect(() => {\n if (childNode && !childNode.getAttribute('data-mui-internal-clone-element')) {\n console.error(['MUI: The `children` component of the Tooltip is not forwarding its props correctly.', 'Please make sure that props are spread on the same element that the ref is applied to.'].join('\\n'));\n }\n }, [childNode]);\n }\n const interactiveWrapperListeners = {};\n if (!disableTouchListener) {\n childrenProps.onTouchStart = handleTouchStart;\n childrenProps.onTouchEnd = handleTouchEnd;\n }\n if (!disableHoverListener) {\n childrenProps.onMouseOver = composeEventHandler(handleMouseOver, childrenProps.onMouseOver);\n childrenProps.onMouseLeave = composeEventHandler(handleMouseLeave, childrenProps.onMouseLeave);\n if (!disableInteractive) {\n interactiveWrapperListeners.onMouseOver = handleMouseOver;\n interactiveWrapperListeners.onMouseLeave = handleMouseLeave;\n }\n }\n if (!disableFocusListener) {\n childrenProps.onFocus = composeEventHandler(handleFocus, childrenProps.onFocus);\n childrenProps.onBlur = composeEventHandler(handleBlur, childrenProps.onBlur);\n if (!disableInteractive) {\n interactiveWrapperListeners.onFocus = handleFocus;\n interactiveWrapperListeners.onBlur = handleBlur;\n }\n }\n if (process.env.NODE_ENV !== 'production') {\n if (children.props.title) {\n console.error(['MUI: You have provided a `title` prop to the child of .', `Remove this title prop \\`${children.props.title}\\` or the Tooltip component.`].join('\\n'));\n }\n }\n const popperOptions = React.useMemo(() => {\n var _PopperProps$popperOp;\n let tooltipModifiers = [{\n name: 'arrow',\n enabled: Boolean(arrowRef),\n options: {\n element: arrowRef,\n padding: 4\n }\n }];\n if ((_PopperProps$popperOp = PopperProps.popperOptions) != null && _PopperProps$popperOp.modifiers) {\n tooltipModifiers = tooltipModifiers.concat(PopperProps.popperOptions.modifiers);\n }\n return _extends({}, PopperProps.popperOptions, {\n modifiers: tooltipModifiers\n });\n }, [arrowRef, PopperProps]);\n const ownerState = _extends({}, props, {\n isRtl,\n arrow,\n disableInteractive,\n placement,\n PopperComponentProp,\n touch: ignoreNonTouchEvents.current\n });\n const classes = useUtilityClasses(ownerState);\n const PopperComponent = (_ref = (_slots$popper = slots.popper) != null ? _slots$popper : components.Popper) != null ? _ref : TooltipPopper;\n const TransitionComponent = (_ref2 = (_ref3 = (_slots$transition = slots.transition) != null ? _slots$transition : components.Transition) != null ? _ref3 : TransitionComponentProp) != null ? _ref2 : Grow;\n const TooltipComponent = (_ref4 = (_slots$tooltip = slots.tooltip) != null ? _slots$tooltip : components.Tooltip) != null ? _ref4 : TooltipTooltip;\n const ArrowComponent = (_ref5 = (_slots$arrow = slots.arrow) != null ? _slots$arrow : components.Arrow) != null ? _ref5 : TooltipArrow;\n const popperProps = appendOwnerState(PopperComponent, _extends({}, PopperProps, (_slotProps$popper = slotProps.popper) != null ? _slotProps$popper : componentsProps.popper, {\n className: clsx(classes.popper, PopperProps == null ? void 0 : PopperProps.className, (_ref6 = (_slotProps$popper2 = slotProps.popper) != null ? _slotProps$popper2 : componentsProps.popper) == null ? void 0 : _ref6.className)\n }), ownerState);\n const transitionProps = appendOwnerState(TransitionComponent, _extends({}, TransitionProps, (_slotProps$transition = slotProps.transition) != null ? _slotProps$transition : componentsProps.transition), ownerState);\n const tooltipProps = appendOwnerState(TooltipComponent, _extends({}, (_slotProps$tooltip = slotProps.tooltip) != null ? _slotProps$tooltip : componentsProps.tooltip, {\n className: clsx(classes.tooltip, (_ref7 = (_slotProps$tooltip2 = slotProps.tooltip) != null ? _slotProps$tooltip2 : componentsProps.tooltip) == null ? void 0 : _ref7.className)\n }), ownerState);\n const tooltipArrowProps = appendOwnerState(ArrowComponent, _extends({}, (_slotProps$arrow = slotProps.arrow) != null ? _slotProps$arrow : componentsProps.arrow, {\n className: clsx(classes.arrow, (_ref8 = (_slotProps$arrow2 = slotProps.arrow) != null ? _slotProps$arrow2 : componentsProps.arrow) == null ? void 0 : _ref8.className)\n }), ownerState);\n return /*#__PURE__*/_jsxs(React.Fragment, {\n children: [/*#__PURE__*/React.cloneElement(children, childrenProps), /*#__PURE__*/_jsx(PopperComponent, _extends({\n as: PopperComponentProp != null ? PopperComponentProp : Popper,\n placement: placement,\n anchorEl: followCursor ? {\n getBoundingClientRect: () => ({\n top: cursorPosition.y,\n left: cursorPosition.x,\n right: cursorPosition.x,\n bottom: cursorPosition.y,\n width: 0,\n height: 0\n })\n } : childNode,\n popperRef: popperRef,\n open: childNode ? open : false,\n id: id,\n transition: true\n }, interactiveWrapperListeners, popperProps, {\n popperOptions: popperOptions,\n children: ({\n TransitionProps: TransitionPropsInner\n }) => /*#__PURE__*/_jsx(TransitionComponent, _extends({\n timeout: theme.transitions.duration.shorter\n }, TransitionPropsInner, transitionProps, {\n children: /*#__PURE__*/_jsxs(TooltipComponent, _extends({}, tooltipProps, {\n children: [title, arrow ? /*#__PURE__*/_jsx(ArrowComponent, _extends({}, tooltipArrowProps, {\n ref: setArrowRef\n })) : null]\n }))\n }))\n }))]\n });\n});\nprocess.env.NODE_ENV !== \"production\" ? Tooltip.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the d.ts file and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * If `true`, adds an arrow to the tooltip.\n * @default false\n */\n arrow: PropTypes.bool,\n /**\n * Tooltip reference element.\n */\n children: elementAcceptingRef.isRequired,\n /**\n * Override or extend the styles applied to the component.\n */\n classes: PropTypes.object,\n /**\n * @ignore\n */\n className: PropTypes.string,\n /**\n * The components used for each slot inside.\n *\n * This prop is an alias for the `slots` prop.\n * It's recommended to use the `slots` prop instead.\n *\n * @default {}\n */\n components: PropTypes.shape({\n Arrow: PropTypes.elementType,\n Popper: PropTypes.elementType,\n Tooltip: PropTypes.elementType,\n Transition: PropTypes.elementType\n }),\n /**\n * The extra props for the slot components.\n * You can override the existing props or add new ones.\n *\n * This prop is an alias for the `slotProps` prop.\n * It's recommended to use the `slotProps` prop instead, as `componentsProps` will be deprecated in the future.\n *\n * @default {}\n */\n componentsProps: PropTypes.shape({\n arrow: PropTypes.object,\n popper: PropTypes.object,\n tooltip: PropTypes.object,\n transition: PropTypes.object\n }),\n /**\n * Set to `true` if the `title` acts as an accessible description.\n * By default the `title` acts as an accessible label for the child.\n * @default false\n */\n describeChild: PropTypes.bool,\n /**\n * Do not respond to focus-visible events.\n * @default false\n */\n disableFocusListener: PropTypes.bool,\n /**\n * Do not respond to hover events.\n * @default false\n */\n disableHoverListener: PropTypes.bool,\n /**\n * Makes a tooltip not interactive, i.e. it will close when the user\n * hovers over the tooltip before the `leaveDelay` is expired.\n * @default false\n */\n disableInteractive: PropTypes.bool,\n /**\n * Do not respond to long press touch events.\n * @default false\n */\n disableTouchListener: PropTypes.bool,\n /**\n * The number of milliseconds to wait before showing the tooltip.\n * This prop won't impact the enter touch delay (`enterTouchDelay`).\n * @default 100\n */\n enterDelay: PropTypes.number,\n /**\n * The number of milliseconds to wait before showing the tooltip when one was already recently opened.\n * @default 0\n */\n enterNextDelay: PropTypes.number,\n /**\n * The number of milliseconds a user must touch the element before showing the tooltip.\n * @default 700\n */\n enterTouchDelay: PropTypes.number,\n /**\n * If `true`, the tooltip follow the cursor over the wrapped element.\n * @default false\n */\n followCursor: PropTypes.bool,\n /**\n * This prop is used to help implement the accessibility logic.\n * If you don't provide this prop. It falls back to a randomly generated id.\n */\n id: PropTypes.string,\n /**\n * The number of milliseconds to wait before hiding the tooltip.\n * This prop won't impact the leave touch delay (`leaveTouchDelay`).\n * @default 0\n */\n leaveDelay: PropTypes.number,\n /**\n * The number of milliseconds after the user stops touching an element before hiding the tooltip.\n * @default 1500\n */\n leaveTouchDelay: PropTypes.number,\n /**\n * Callback fired when the component requests to be closed.\n *\n * @param {React.SyntheticEvent} event The event source of the callback.\n */\n onClose: PropTypes.func,\n /**\n * Callback fired when the component requests to be open.\n *\n * @param {React.SyntheticEvent} event The event source of the callback.\n */\n onOpen: PropTypes.func,\n /**\n * If `true`, the component is shown.\n */\n open: PropTypes.bool,\n /**\n * Tooltip placement.\n * @default 'bottom'\n */\n placement: PropTypes.oneOf(['bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n /**\n * The component used for the popper.\n * @default Popper\n */\n PopperComponent: PropTypes.elementType,\n /**\n * Props applied to the [`Popper`](/material-ui/api/popper/) element.\n * @default {}\n */\n PopperProps: PropTypes.object,\n /**\n * The extra props for the slot components.\n * You can override the existing props or add new ones.\n *\n * This prop is an alias for the `componentsProps` prop, which will be deprecated in the future.\n *\n * @default {}\n */\n slotProps: PropTypes.shape({\n arrow: PropTypes.object,\n popper: PropTypes.object,\n tooltip: PropTypes.object,\n transition: PropTypes.object\n }),\n /**\n * The components used for each slot inside.\n *\n * This prop is an alias for the `components` prop, which will be deprecated in the future.\n *\n * @default {}\n */\n slots: PropTypes.shape({\n arrow: PropTypes.elementType,\n popper: PropTypes.elementType,\n tooltip: PropTypes.elementType,\n transition: PropTypes.elementType\n }),\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Tooltip title. Zero-length titles string, undefined, null and false are never displayed.\n */\n title: PropTypes.node,\n /**\n * The component used for the transition.\n * [Follow this guide](/material-ui/transitions/#transitioncomponent-prop) to learn more about the requirements for this component.\n * @default Grow\n */\n TransitionComponent: PropTypes.elementType,\n /**\n * Props applied to the transition element.\n * By default, the element is based on this [`Transition`](http://reactcommunity.org/react-transition-group/transition/) component.\n */\n TransitionProps: PropTypes.object\n} : void 0;\nexport default Tooltip;","import '@/components/mui/menu-item.component.css';\nimport ArrowRightIcon from '@mui/icons-material/ArrowRight';\nimport {\n ListItemIcon as MuiListItemIcon,\n ListItemText as MuiListItemText,\n MenuItem as MuiMenuItem,\n} from '@mui/material';\nimport Tooltip from '@mui/material/Tooltip';\nimport { Localized, ReferencedItem, SingleColumnMenu } from 'platform-bible-utils';\nimport { MouseEvent, PropsWithChildren } from 'react';\n\ntype MenuItemInfoBase = {\n /** Text (displayable in the UI) as the name of the menu item */\n label: string;\n /** Text to display when the mouse hovers over the menu item */\n tooltip?: string;\n};\n\nexport type Command = MenuItemInfoBase & {\n /** Command to execute (string.string) */\n command: string;\n};\n\ntype SubMenu = MenuItemInfoBase & {\n /** Command to execute (string.string) */\n items: MenuItemInfo[];\n};\n\nexport interface CommandHandler {\n (command: Command): void;\n}\n\nexport type MenuPropsBase = {\n /*\n * The JSON defining the menu whose items are to be rendered. This will typically be one of the\n * menus in the \"defs\" in a Platform.Bible menu (see PlatformMenus). The schema for this is\n * menuDocumentSchema (at the end of menus.model.ts). Note that while this is a\n * \"SingleColumnMenu\", somewhat bizarrely, a MultiColumnMenu is a SingleColumnMenu, so it really\n * could be a MultiColumnMenu, in which case, column had better be defined so it can be used\n * to filter out the actual groups and items to display on the column.\n */\n menuDefinition: Localized;\n\n commandHandler: CommandHandler;\n\n /**\n * Additional action to perform when any menu item is clicked. Allows the caller to handle event\n * (e.g., to close the menu).\n */\n onClick?: (event: MouseEvent) => void;\n};\n\nexport type MenuItemListProps = MenuPropsBase & {\n /** Optional unique (column) identifier */\n columnId?: ReferencedItem;\n};\n\nexport type MenuItemProps = Omit &\n PropsWithChildren<{\n /** Optional unique identifier */\n id?: string;\n\n onClick: (event: MouseEvent) => void;\n }>;\n\ntype MenuItemInfo = (Command | SubMenu) & {\n /**\n * If specified, menu item will be inset if it does not have a leading icon.\n *\n * @default true\n */\n allowForLeadingIcons?: boolean;\n /**\n * If specified, the path to the icon image to display on the leading side of the menu text.\n *\n * @default undefined (no leading icon will be shown)\n */\n iconPathBefore?: string;\n /**\n * If specified, the path to the icon image to display on the trailing side of the menu text.\n *\n * @default undefined (no trailing icon will be shown)\n */\n iconPathAfter?: string;\n /**\n * If true, list item is focused during the first mount\n *\n * @default false\n */\n hasAutoFocus?: boolean;\n\n /** Additional css classes to help with unique styling of the menu item */\n className?: string;\n\n /**\n * If true, the menu item will appear disabled and it will not respond to clicks or mouse hovers.\n *\n * @default false\n */\n isDisabled?: boolean;\n\n /**\n * If true, compact vertical padding designed for keyboard and mouse input is used.\n *\n * @default true\n */\n isDense?: boolean;\n\n /**\n * If true, a right-arrow icon will be displayed (iconPathAfter, if specified, will be ignored).\n *\n * @default false\n */\n isSubMenuParent?: boolean;\n\n /**\n * If true, the left and right padding is removed\n *\n * @default false\n */\n hasDisabledGutters?: boolean;\n\n /**\n * If true, a 1px light border is added to bottom of menu item\n *\n * @default false\n */\n hasDivider?: boolean;\n\n /** Help identify which element has keyboard focus */\n focusVisibleClassName?: string;\n\n /** If it's a submenu, it should have the items property */\n items?: MenuItemInfo[];\n};\n\nfunction getIcon(icon: string | undefined, menuLabel: string, leading: boolean) {\n return icon ? (\n \n {`${leading\n \n ) : undefined;\n}\n\nexport default function MenuItem(props: MenuItemProps) {\n const {\n onClick,\n label,\n tooltip,\n allowForLeadingIcons = true,\n iconPathBefore = undefined,\n iconPathAfter = undefined,\n hasAutoFocus = false,\n className,\n isDisabled = false,\n isDense = true,\n isSubMenuParent = false,\n hasDisabledGutters = false,\n hasDivider = false,\n focusVisibleClassName,\n id,\n children,\n } = props;\n\n const menuItem = (\n \n {label ? (\n <>\n {getIcon(iconPathBefore, label, true)}\n \n {isSubMenuParent ? (\n \n \n \n ) : (\n getIcon(iconPathAfter, label, false)\n )}\n \n ) : (\n children\n )}\n \n );\n\n return tooltip ? (\n \n
    {menuItem}
    \n
    \n ) : (\n menuItem\n );\n}\n","import MenuItem, {\n MenuItemListProps,\n MenuItemProps,\n MenuPropsBase,\n} from '@/components/mui/menu-item.component';\nimport { Menu } from '@mui/material';\nimport {\n Localized,\n MenuGroupDetailsInSubMenu,\n MenuItemContainingCommand,\n MenuItemContainingSubmenu,\n OrderedExtensibleContainer,\n ReferencedItem,\n SingleColumnMenu,\n} from 'platform-bible-utils';\nimport { MouseEvent, useMemo, useState } from 'react';\n\n/**\n * All the exported types in this file should be regarded as \"internal\" (i.e., they should not be\n * exposed via index.ts).\n */\n\nexport type GroupedMenuPropsBase = MenuPropsBase & {\n /** Optional unique (column) identifier */\n columnId?: ReferencedItem;\n};\n\nexport type GroupedMenuItemListProps = MenuItemListProps & {\n /**\n * If the menuDefinition includes \"top-level\" groups (i.e., those that belong to a column as\n * opposed to those that belong to a submenu) that should not be included in the list, then this\n * array specifies which groups to include. Likewise, for a submenu, this list indicates which\n * groups are pertinent for that submenu. So then for a context menu this property need not be\n * specified since it is a top-level menu based on a \"true\" SingleColumnMenu (i.e., one that is\n * not a MultiColumnMenu).\n */\n includedGroups?: {\n id: string;\n group: Localized;\n }[];\n};\n\ninterface ItemInfo {\n item: Localized;\n isLastItemInGroup: boolean;\n}\n\ntype SubMenuProps = MenuPropsBase & {\n parentMenuItem: Localized;\n parentItemProps: Omit, 'iconPathAfter'>;\n};\n\nfunction getAllGroups(menuDefinition: Localized) {\n const groupEntries = Object.entries(menuDefinition.groups);\n // Convert array of entries to array of objects with id and group properties\n return groupEntries.map(([key, value]) => ({ id: key, group: value }));\n}\n\nfunction SubMenu(props: SubMenuProps) {\n const [anchorEl, setAnchorEl] = useState(undefined);\n\n const { parentMenuItem, parentItemProps, menuDefinition } = props;\n\n const handleParentMenuItemClick = (event: MouseEvent) => {\n setAnchorEl(event.currentTarget);\n };\n\n const handleClose = () => {\n setAnchorEl(undefined);\n };\n\n const renderSubMenuItems = () => {\n let includedGroups = getAllGroups(menuDefinition).filter((g) => 'menuItem' in g.group);\n\n // Ensure valid parent menu was provided. (If not, submenu will contain all groups!)\n if (!parentMenuItem?.id) throw new Error('A valid parent menu item is required for submenus.');\n\n // When laying out a submenu, only include groups associated with the provided parent menu.\n // Note: without the (annoying) redundant check that the included groups\n // have the menuItem field, TS doesn't think it exists.\n includedGroups = includedGroups.filter(\n (group) => 'menuItem' in group.group && group.group.menuItem === parentMenuItem.id,\n );\n\n return ;\n };\n\n return (\n <>\n \n \n {renderSubMenuItems()}\n \n \n );\n}\n\nconst getOrderedGroupItems = (\n groupId: string,\n allItems: Localized[],\n) => {\n // Filter items that belong to the specified group\n const itemsForGroup = allItems.filter((item) => item.group === groupId);\n // Sort items based on order\n const sortedItems = itemsForGroup.sort((a, b) => (a.order || 0) - (b.order || 0));\n return sortedItems;\n};\n\n/**\n * This component is internal; it does not need to be exposed to the outside world since it is not\n * useful on its own. It is used to generate and lay out the MenuItems that appear either on a\n * top-level menu (in a GridMenu or ContextMenu) or in a submenu.\n */\nexport default function GroupedMenuItemList(menuProps: GroupedMenuItemListProps) {\n const { menuDefinition, onClick, commandHandler, includedGroups } = menuProps;\n\n const { items, allowForLeadingIcons } = useMemo(() => {\n const groupsToInclude =\n includedGroups && includedGroups.length > 0\n ? includedGroups\n : // We're apparently laying out a single-column menu (presumably a context menu). In this\n // case, all groups should be included except ones that belong to a submenu.\n getAllGroups(menuDefinition).filter((g) => !('menuItem' in g.group));\n\n const sortedGroups = Object.values(groupsToInclude).sort(\n (a, b) => (a.group.order || 0) - (b.group.order || 0),\n );\n\n const itemArray: ItemInfo[] = [];\n\n sortedGroups.forEach((group) => {\n getOrderedGroupItems(group.id, menuDefinition.items).forEach((item) =>\n itemArray.push({ item, isLastItemInGroup: false }),\n );\n if (itemArray.length > 0) itemArray[itemArray.length - 1].isLastItemInGroup = true;\n });\n\n // No divider after last item in final group.\n if (itemArray.length > 0) itemArray[itemArray.length - 1].isLastItemInGroup = false;\n\n const allowSpaceForLeadingIcons = itemArray.some(\n (i) => 'iconPathBefore' in i.item && i.item.iconPathBefore,\n );\n\n return { items: itemArray, allowForLeadingIcons: allowSpaceForLeadingIcons };\n }, [includedGroups, menuDefinition]);\n\n // Create props for MenuItem component including setting hasDivider for the last item in a group\n const createMenuItemProps = ({ item, isLastItemInGroup }: ItemInfo) => {\n const menuItemProps = {\n className: 'papi-menu-item',\n label: item.label,\n tooltip: item.tooltip,\n iconPathBefore: 'iconPathBefore' in item ? item.iconPathBefore : undefined,\n iconPathAfter: 'iconPathAfter' in item ? item.iconPathAfter : undefined,\n hasDivider: isLastItemInGroup, // Set hasDivider to true for the last item in a group\n allowForLeadingIcons,\n };\n\n return menuItemProps;\n };\n\n const [firstItem] = items;\n\n if (!firstItem) return
    ;\n\n const divKey = firstItem.item.group;\n\n return (\n
    \n {items.map((itemInfo, index) => {\n const { item } = itemInfo;\n const menuItemProps = createMenuItemProps(itemInfo);\n if ('command' in item) {\n const key = item.group + index;\n return (\n ) => {\n onClick?.(event);\n commandHandler(item);\n }}\n {...menuItemProps}\n />\n );\n }\n return (\n \n );\n })}\n
    \n );\n}\n","import GroupedMenuItemList from '@/components/mui/grouped-menu-item-list.component';\nimport { MenuItemListProps } from '@/components/mui/menu-item.component';\nimport { MultiColumnMenu } from 'platform-bible-utils';\n\n/**\n * This component is internal; it does not need to be exposed to the outside world since it is not\n * useful on its own. Use either GridMenu or ContextMenu.\n */\nexport default function TopLevelMenu(props: MenuItemListProps) {\n const { menuDefinition, columnId } = props;\n\n const groupEntries = Object.entries(menuDefinition.groups);\n // Convert array of entries to array of objects with id and group properties\n const groups = groupEntries.map(([key, value]) => ({ id: key, group: value }));\n let includedGroups = groups.filter((g) => 'column' in g.group);\n\n // Check if column is provided and menuDefinition is a MultiColumnMenu\n if (\n columnId &&\n 'columns' in menuDefinition &&\n // Without this type assertion, TS doesn't know what columns is.\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n (menuDefinition as MultiColumnMenu).columns[columnId]\n ) {\n // When laying out a single column in a MultiColumnMenu, only include groups associated with\n // the provided column. Note: without the (annoying) redundant check that the included groups\n // have the colum field, TS doesn't think it exists.\n includedGroups = includedGroups.filter(\n (g) => 'column' in g.group && g.group.column === columnId,\n );\n }\n\n return ;\n}\n","import '@/components/mui/grid-menu.component.css';\nimport { GroupedMenuPropsBase } from '@/components/mui/grouped-menu-item-list.component';\nimport { CommandHandler } from '@/components/mui/menu-item.component';\nimport TopLevelMenu from '@/components/mui/top-level-menu.component';\nimport { Grid, List } from '@mui/material';\nimport {\n Localized,\n MenuColumnWithHeader,\n MultiColumnMenu,\n ReferencedItem,\n} from 'platform-bible-utils';\nimport { useMemo } from 'react';\n\ntype ColumnInfo = {\n /*\n * The ID (`${string}.${string}`) of a specific menu column.\n */\n id: ReferencedItem;\n\n /*\n * Metadata (label, order, etc.) for a specific menu column.\n */\n metadata: Localized;\n};\n\ntype MenuColumnProps = ColumnInfo &\n GroupedMenuPropsBase & {\n /** Additional css classes to help with unique styling of the menu column */\n className?: string;\n };\n\nexport type GridMenuInfo = {\n /** The menu object containing information about the columns, groups, and items to display. */\n multiColumnMenu: Localized;\n};\n\nexport type GridMenuProps = GridMenuInfo & {\n /** Optional unique identifier */\n id?: string;\n\n commandHandler: CommandHandler;\n\n /** Additional css classes to help with unique styling of the grid menu */\n className?: string;\n};\n\nfunction MenuColumn({\n commandHandler,\n menuDefinition,\n id,\n metadata,\n onClick,\n className,\n}: MenuColumnProps) {\n return (\n \n

    \n {metadata.label}\n

    \n {/* It would seem as though this List component were unnecessary, since it only contains one\n thing, but the \"dense\" property does affect the layout of the items (in a way I don't fully\n understand). There might be a better way. */}\n \n \n \n \n );\n}\n\nexport default function GridMenu({\n commandHandler,\n className,\n multiColumnMenu,\n id,\n}: GridMenuProps) {\n const { columns } = multiColumnMenu;\n\n const sortedColumns = useMemo(() => {\n const columnNumbers = new Map();\n Object.getOwnPropertyNames(columns).forEach((columnName: string) => {\n // We know for sure there is a (boolean) property 'isExtensible' that we are not interested in.\n if (columnName === 'isExtensible') return;\n // TS doesn't allow `columnName` above to be a ReferencedItem even though the type says it is\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const columnId = columnName as ReferencedItem;\n const column = columns[columnId];\n // As of right now (and hopefully forever after), all remaining properties of the\n // ColumnsWithHeaders object are columns whose property names are the IDs of the columns.\n // This is an additional (redundant) sanity check. Specifically we're interested in\n // MenuColumnWithHeader objects, which TypeScript now \"knows\" we have, but at runtime all we\n // can check for is that it's an object with a valid numeric order field. That's likely good\n // enough.\n if (\n typeof column === 'object' &&\n typeof column.order === 'number' &&\n !Number.isNaN(column.order)\n )\n columnNumbers.set(column.order, { id: columnId, metadata: column });\n else\n console.warn(\n `Property ${columnName} (${typeof column}) on menu ${id} is not a valid column and is being ignored. This might indicate data corruption`,\n );\n });\n\n // Extract values and sort them based on the 'order' property\n return Array.from(columnNumbers.values()).sort((a, b) => {\n return (a.metadata.order || 0) - (b.metadata.order || 0);\n });\n }, [columns, id]);\n\n // We might need something like this if we need to be able to prevent empty columns\n // sortedColumns.filter((c) => multiColumnMenu.groups.some((g) => 'column' in g && (g as .column)...\n\n return (\n \n {sortedColumns.map((col, index) => (\n \n ))}\n \n );\n}\n","import { useEffect, useRef, useState } from 'react';\n\nexport type UsePromiseOptions = {\n /**\n * Whether to leave the value as the most recent resolved promise value or set it back to\n * defaultValue while running the promise again. Defaults to true\n */\n preserveValue?: boolean;\n};\n\n/** Set up defaults for options for usePromise hook */\nfunction getUsePromiseOptionsDefaults(options: UsePromiseOptions): UsePromiseOptions {\n return {\n preserveValue: true,\n ...options,\n };\n}\n\n/**\n * Awaits a promise and returns a loading value while the promise is unresolved\n *\n * @param promiseFactoryCallback A function that returns the promise to await. If this callback is\n * undefined, the current value will be returned (defaultValue unless it was previously changed\n * and `options.preserveValue` is true), and there will be no loading.\n *\n * WARNING: MUST BE STABLE - const or wrapped in useCallback. The reference must not be updated\n * every render\n * @param defaultValue The initial value to return while first awaiting the promise. If\n * `options.preserveValue` is false, this value is also shown while awaiting the promise on\n * subsequent calls.\n *\n * Note: this parameter is internally assigned to a `ref`, so changing it will not cause any hooks\n * to re-run with its new value. This means that, if the `promiseFactoryCallback` changes and\n * `options.preserveValue` is `false`, the returned value will be set to the current\n * `defaultValue`. However, the returned value will not be updated if`defaultValue` changes.\n * @param options Various options for adjusting how this hook runs the `promiseFactoryCallback`\n *\n * Note: this parameter is internally assigned to a `ref`, so changing it will not cause any hooks\n * to re-run with its new value. However, the latest `options.preserveValue` will always be used\n * appropriately to determine whether to preserve the returned value when changing the\n * `promiseFactoryCallback`\n * @returns `[value, isLoading]`\n *\n * - `value`: the current value for the promise, either the defaultValue or the resolved promise value\n * - `isLoading`: whether the promise is waiting to be resolved\n */\nconst usePromise = (\n promiseFactoryCallback: (() => Promise) | undefined,\n defaultValue: T,\n options: UsePromiseOptions = {},\n): [value: T, isLoading: boolean] => {\n // Use defaultValue as a ref so it doesn't update dependency arrays\n const defaultValueRef = useRef(defaultValue);\n defaultValueRef.current = defaultValue;\n // Use options as a ref so it doesn't update dependency arrays\n const optionsDefaultedRef = useRef(options);\n optionsDefaultedRef.current = getUsePromiseOptionsDefaults(optionsDefaultedRef.current);\n\n const [value, setValue] = useState(() => defaultValueRef.current);\n const [isLoading, setIsLoading] = useState(true);\n useEffect(() => {\n let promiseIsCurrent = true;\n // If a promiseFactoryCallback was provided, we are loading. Otherwise, there is no loading to do\n setIsLoading(!!promiseFactoryCallback);\n (async () => {\n // If there is a callback to run, run it\n if (promiseFactoryCallback) {\n const result = await promiseFactoryCallback();\n // If the promise was not already replaced, update the value\n if (promiseIsCurrent) {\n setValue(() => result);\n setIsLoading(false);\n }\n }\n })();\n\n return () => {\n // Mark this promise as old and not to be used\n promiseIsCurrent = false;\n if (!optionsDefaultedRef.current.preserveValue) setValue(() => defaultValueRef.current);\n };\n }, [promiseFactoryCallback]);\n\n return [value, isLoading];\n};\nexport default usePromise;\n","\"use client\";\n\nimport createSvgIcon from './utils/createSvgIcon';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nexport default createSvgIcon( /*#__PURE__*/_jsx(\"path\", {\n d: \"M3 18h18v-2H3zm0-5h18v-2H3zm0-7v2h18V6z\"\n}), 'Menu');","import GridMenu from '@/components/mui/grid-menu.component';\nimport { Command, CommandHandler } from '@/components/mui/menu-item.component';\nimport usePromise from '@/hooks/use-promise.hook';\nimport { Menu as MenuIcon } from '@mui/icons-material';\nimport { Drawer, IconButton } from '@mui/material';\nimport { Localized, MultiColumnMenu } from 'platform-bible-utils';\nimport {\n MouseEvent,\n MutableRefObject,\n PropsWithChildren,\n useCallback,\n useEffect,\n useState,\n} from 'react';\n\nexport interface MultiColumnMenuProvider {\n (isSupportAndDevelopment: boolean): Promise>;\n}\n\nexport type HamburgerMenuButtonProps = PropsWithChildren & {\n /** The handler to use for menu commands (and eventually toolbar commands). */\n commandHandler: CommandHandler;\n\n /**\n * Optional reference to the \"div\" container that determines the where the menu should appear. If\n * not defined, then (1,1) used.\n */\n containerRef?: MutableRefObject;\n\n /**\n * The delegate to use to get the menu data. If not specified or if it returns undefined, the data\n * in normalMenu or fullMenu property will be used.\n */\n menuProvider?: MultiColumnMenuProvider;\n\n /**\n * The menu data to show when the menu is opened if the menuProvider property is not defined.\n * (This allows for a default or test-only static menu to be used.)\n */\n normalMenu?: Localized;\n\n /**\n * The menu data to show for \"full\" menu (when opened with the SHIFT key pressed) if the\n * menuProvider property is not defined. (This allows for a default or test-only static menu to be\n * used.)\n */\n fullMenu?: Localized;\n\n /** Additional css class(es) to help with unique styling of the sub-components */\n className?: string;\n\n /** Value to use as prefix for ARIA labels on interactive sub-components */\n ariaLabelPrefix?: string;\n};\n\nexport default function HamburgerMenuButton({\n menuProvider,\n normalMenu,\n fullMenu,\n commandHandler,\n containerRef,\n className,\n ariaLabelPrefix,\n children,\n}: HamburgerMenuButtonProps) {\n const [isMenuOpen, setMenuOpen] = useState(false);\n const [showFullMenu, setShowFullMenu] = useState(false);\n\n const handleMenuItemClick = useCallback(() => {\n if (isMenuOpen) setMenuOpen(false);\n setShowFullMenu(false);\n }, [isMenuOpen]);\n\n const handleMenuButtonClick = useCallback((e: MouseEvent) => {\n e.stopPropagation();\n setMenuOpen((prevIsOpen) => {\n const isOpening = !prevIsOpen;\n if (isOpening && e.shiftKey) setShowFullMenu(true);\n else if (!isOpening) setShowFullMenu(false);\n return isOpening;\n });\n }, []);\n\n const menuCommandHandler = useCallback(\n (command: Command) => {\n handleMenuItemClick();\n return commandHandler(command);\n },\n [commandHandler, handleMenuItemClick],\n );\n\n const [offset, setOffset] = useState({ top: 1, left: 1 });\n\n useEffect(() => {\n if (isMenuOpen) {\n const node = containerRef?.current;\n if (node) {\n const rect = node.getBoundingClientRect();\n const scrollTop = window.scrollY;\n const scrollLeft = window.scrollX;\n const top = rect.top + scrollTop + node.clientHeight;\n const left = rect.left + scrollLeft;\n setOffset({ top, left });\n }\n }\n }, [isMenuOpen, containerRef]);\n\n const [normalMenuData] = usePromise(\n useCallback(async () => {\n return menuProvider?.(false) ?? normalMenu;\n // isMenuOpen needs to be included for the menu contents to reevaluate when reopened\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [menuProvider, normalMenu, isMenuOpen]),\n normalMenu,\n );\n\n const [fullMenuData] = usePromise(\n useCallback(async () => {\n return menuProvider?.(true) ?? fullMenu ?? normalMenuData;\n // isMenuOpen needs to be included for the menu contents to reevaluate when reopened\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [menuProvider, fullMenu, normalMenuData, isMenuOpen]),\n fullMenu ?? normalMenuData,\n );\n\n const menu = showFullMenu && fullMenuData ? fullMenuData : normalMenuData;\n\n return (\n <>\n \n {children ?? }\n \n \n {menu ? (\n \n ) : undefined}\n \n \n );\n}\n","import '@/components/mui/icon-button.component.css';\nimport { IconButton as MuiIconButton } from '@mui/material';\nimport { MouseEventHandler, PropsWithChildren } from 'react';\n\nexport type IconButtonProps = PropsWithChildren<{\n /** Optional unique identifier */\n id?: string;\n /**\n * Required. Used as both the tooltip (aka, title) and the aria-label (used for accessibility,\n * testing, etc.), unless a distinct tooltip is supplied.\n */\n label: string;\n /**\n * Enabled status of button\n *\n * @default false\n */\n isDisabled?: boolean;\n /** Optional tooltip to display if different from the aria-label. */\n tooltip?: string;\n /** If true, no tooltip will be displayed. */\n isTooltipSuppressed?: boolean;\n /**\n * If given, uses a negative margin to counteract the padding on one side (this is often helpful\n * for aligning the left or right side of the icon with content above or below, without ruining\n * the border size and shape).\n *\n * @default false\n */\n adjustMarginToAlignToEdge?: 'end' | 'start' | false;\n /**\n * The size of the component. small is equivalent to the dense button styling.\n *\n * @default false\n */\n size: 'small' | 'medium' | 'large';\n /** Additional css classes to help with unique styling of the button */\n className?: string;\n /** Optional click handler */\n onClick?: MouseEventHandler;\n}>;\n\n/**\n * Iconic button a user can click to do something\n *\n * Thanks to MUI for heavy inspiration and documentation\n * https://mui.com/material-ui/getting-started/overview/\n */\nfunction IconButton({\n id,\n label,\n isDisabled = false,\n tooltip,\n isTooltipSuppressed = false,\n adjustMarginToAlignToEdge = false,\n size = 'medium',\n className,\n onClick,\n children,\n}: IconButtonProps) {\n return (\n \n {children /* the icon to display */}\n \n );\n}\n\nexport default IconButton;\n","import { cn } from '@/utils/shadcn-ui.util';\nimport { LoaderCircle, LucideProps } from 'lucide-react';\nimport { forwardRef } from 'react';\n\nexport type SpinnerProps = LucideProps;\n\nconst Spinner = forwardRef(({ className, ...props }, ref) => {\n return (\n \n );\n});\n\nSpinner.displayName = 'Spinner';\n\nexport default Spinner;\n","import { Input as ShadInput } from '@/components/shadcn-ui/input';\nimport { Label as ShadLabel } from '@/components/shadcn-ui/label';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { ChangeEventHandler, FocusEventHandler } from 'react';\n\nexport type TextFieldProps = {\n /** Optional unique identifier */\n id?: string;\n /**\n * If `true`, the component is disabled.\n *\n * @default false\n */\n isDisabled?: boolean;\n /**\n * If `true`, the label is displayed in an error state.\n *\n * @default false\n */\n hasError?: boolean;\n /**\n * If `true`, the input will take up the full width of its container.\n *\n * @default false\n */\n isFullWidth?: boolean;\n /** Text that gives the user instructions on what contents the TextField expects */\n helperText?: string;\n /** The title of the TextField */\n label?: string;\n /** The short hint displayed in the `input` before the user enters a value. */\n placeholder?: string;\n /**\n * If `true`, the label is displayed as required and the `input` element is required.\n *\n * @default false\n */\n isRequired?: boolean;\n /** Additional css classes to help with unique styling of the text field */\n className?: string;\n /** Starting value for the text field if it is not controlled */\n defaultValue?: string | number;\n /** Value of the text field if controlled */\n value?: string | number;\n /** Triggers when content of textfield is changed */\n onChange?: ChangeEventHandler;\n /** Triggers when textfield gets focus */\n onFocus?: FocusEventHandler;\n /** Triggers when textfield loses focus */\n onBlur?: FocusEventHandler;\n};\n\n/**\n * Text input field\n *\n * Thanks to Shadcn for heavy inspiration and documentation\n * https://ui.shadcn.com/docs/components/input#with-label\n */\nfunction TextField({\n id,\n isDisabled = false,\n hasError = false,\n isFullWidth = false,\n helperText,\n label,\n placeholder,\n isRequired = false,\n className,\n defaultValue,\n value,\n onChange,\n onFocus,\n onBlur,\n}: TextFieldProps) {\n return (\n
    \n {`${label}${isRequired ? '*' : ''}`}\n \n

    {helperText}

    \n
    \n );\n}\n\nexport default TextField;\n","import HamburgerMenuButton, {\n MultiColumnMenuProvider,\n} from '@/components/mui/hamburger-menu-button.component';\nimport { CommandHandler } from '@/components/mui/menu-item.component';\nimport '@/components/mui/toolbar.component.css';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { AppBar, Toolbar as MuiToolbar } from '@mui/material';\nimport { PropsWithChildren, useRef } from 'react';\n\nexport type ToolbarProps = PropsWithChildren<{\n /** The handler to use for menu commands (and eventually toolbar commands). */\n commandHandler: CommandHandler;\n\n /**\n * The optional delegate to use to get the menu data. If not specified, the \"hamburger\" menu will\n * not display.\n */\n menuProvider?: MultiColumnMenuProvider;\n\n /** Optional unique identifier */\n id?: string;\n\n /** Additional css classes to help with unique styling of the toolbar */\n className?: string;\n}>;\n\nexport default function Toolbar({\n menuProvider,\n commandHandler,\n className,\n id,\n children,\n}: ToolbarProps) {\n // This ref will always be defined\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const containerRef = useRef(undefined!);\n\n return (\n
    \n \n \n {menuProvider ? (\n \n ) : undefined}\n {children ?
    {children}
    : undefined}\n \n
    \n
    \n );\n}\n","import React from 'react';\nimport { cva, type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst alertVariants = cva(\n 'tw-relative tw-w-full tw-rounded-lg tw-border tw-p-4 [&>svg~*]:tw-pl-7 [&>svg+div]:tw-translate-y-[-3px] [&>svg]:tw-absolute [&>svg]:tw-left-4 [&>svg]:tw-top-4 [&>svg]:tw-text-foreground',\n {\n variants: {\n variant: {\n default: 'tw-bg-background tw-text-foreground',\n destructive:\n 'tw-border-destructive/50 tw-text-destructive dark:tw-border-destructive [&>svg]:tw-text-destructive',\n },\n },\n defaultVariants: {\n variant: 'default',\n },\n },\n);\n\nconst Alert = React.forwardRef<\n HTMLDivElement,\n React.HTMLAttributes & VariantProps\n>(({ className, variant, ...props }, ref) => (\n
    \n));\nAlert.displayName = 'Alert';\n\nconst AlertTitle = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n {/* added because of https://github.com/jsx-eslint/eslint-plugin-jsx-a11y/blob/main/docs/rules/heading-has-content.md */}\n {props.children}{' '}\n \n ),\n);\nAlertTitle.displayName = 'AlertTitle';\n\nconst AlertDescription = React.forwardRef<\n HTMLParagraphElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n
    \n));\nAlertDescription.displayName = 'AlertDescription';\n\nexport { Alert, AlertTitle, AlertDescription };\n","import React from 'react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Card = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nCard.displayName = 'Card';\n\nconst CardHeader = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nCardHeader.displayName = 'CardHeader';\n\nconst CardTitle = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n {/* added because of https://github.com/jsx-eslint/eslint-plugin-jsx-a11y/blob/main/docs/rules/heading-has-content.md */}\n {props.children}\n \n ),\n);\nCardTitle.displayName = 'CardTitle';\n\nconst CardDescription = React.forwardRef<\n HTMLParagraphElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n

    \n));\nCardDescription.displayName = 'CardDescription';\n\nconst CardContent = React.forwardRef>(\n ({ className, ...props }, ref) => (\n

    \n ),\n);\nCardContent.displayName = 'CardContent';\n\nconst CardFooter = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nCardFooter.displayName = 'CardFooter';\n\nexport { Card, CardHeader, CardFooter, CardTitle, CardDescription, CardContent };\n","import { ComponentProps } from 'react';\nimport { toast as sonner, Toaster } from 'sonner';\n\ntype SonnerProps = ComponentProps;\n\nfunction Sonner({ ...props }: SonnerProps) {\n return (\n \n );\n}\n\n// The re-export of the sonner function was added manually\nexport { Sonner, sonner };\n","import React from 'react';\nimport * as SliderPrimitive from '@radix-ui/react-slider';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Slider = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n \n \n \n));\nSlider.displayName = SliderPrimitive.Root.displayName;\n\nexport { Slider };\n","import React from 'react';\nimport * as SwitchPrimitives from '@radix-ui/react-switch';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Switch = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n));\nSwitch.displayName = SwitchPrimitives.Root.displayName;\n\nexport { Switch };\n","import React from 'react';\nimport * as TabsPrimitive from '@radix-ui/react-tabs';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport const Tabs = TabsPrimitive.Root;\n\nexport type TabsListProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport type TabsTriggerProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport type TabsContentProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport const TabsList = React.forwardRef<\n React.ElementRef,\n TabsListProps\n>(({ className, ...props }, ref) => (\n \n));\nTabsList.displayName = TabsPrimitive.List.displayName;\n\nexport const TabsTrigger = React.forwardRef<\n React.ElementRef,\n TabsTriggerProps\n>(({ className, ...props }, ref) => (\n \n));\nTabsTrigger.displayName = TabsPrimitive.Trigger.displayName;\n\nexport const TabsContent = React.forwardRef<\n React.ElementRef,\n TabsContentProps\n>(({ className, ...props }, ref) => (\n \n));\nTabsContent.displayName = TabsPrimitive.Content.displayName;\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Download } from 'lucide-react';\n\ntype InstallButtonProps = {\n /** The installing boolean value determines the state of the button. */\n isInstalling: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n /** Optional text for the button. */\n buttonText?: string;\n} & ButtonProps;\n\n/**\n * The InstallButton component is a button designed for initiating installs. It includes visuals for\n * active installing and idle states.\n *\n * @param isInstalling The installing boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @param buttonText Optional text for the button.\n * @returns A install button.\n */\nexport default function InstallButton({\n isInstalling,\n handleClick,\n buttonText,\n className,\n ...props\n}: InstallButtonProps) {\n return (\n \n {isInstalling ? (\n \n ) : (\n <>\n \n {buttonText}\n \n )}\n \n );\n}\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\n\ntype EnableButtonProps = {\n /** The enabling boolean value determines the state of the button. */\n isEnabling: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n} & ButtonProps;\n\n/**\n * The EnableButton component is a button designed for initiating enabling of downloads. It includes\n * visuals for active enabling and idle states.\n *\n * @param isEnabling The enabling boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @returns A button that can be used to enable.\n */\nexport default function EnableButton({\n isEnabling,\n handleClick,\n className,\n ...props\n}: EnableButtonProps) {\n return (\n \n {isEnabling ? (\n <>\n \n Enabling...\n \n ) : (\n 'Enable'\n )}\n \n );\n}\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\n\ntype DisableButtonProps = {\n /** The disabling boolean value determines the state of the button. */\n isDisabling: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n} & ButtonProps;\n\n/**\n * The DisableButton component is a button designed for initiating disabling of downloads. It\n * includes visuals for active disabling and idle states.\n *\n * @param isDisabling The disabling boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @returns A button that can be used to disable.\n */\nexport default function DisableButton({\n isDisabling,\n handleClick,\n className,\n ...props\n}: DisableButtonProps) {\n return (\n \n {isDisabling ? (\n <>\n \n Disabling...\n \n ) : (\n 'Disable'\n )}\n \n );\n}\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\n\ntype UpdateButtonProps = {\n /** The updating boolean value determines the state of the button. */\n isUpdating: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n} & ButtonProps;\n\n/**\n * The UpdateButton component is a button designed for initiating updates for downloaded extensions.\n * It includes visuals for active updating and idle states.\n *\n * @param isUpdating The updating boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @returns A button that can be used to update.\n */\nexport default function UpdateButton({\n isUpdating,\n handleClick,\n className,\n ...props\n}: UpdateButtonProps) {\n return (\n \n {isUpdating ? (\n <>\n \n Updating...\n \n ) : (\n 'Update'\n )}\n \n );\n}\n","import { cn } from '@/utils/shadcn-ui.util';\nimport Markdown, { MarkdownToJSX } from 'markdown-to-jsx';\nimport { useMemo } from 'react';\n\ninterface MarkdownRendererProps {\n /** Optional unique identifier */\n id?: string;\n /** The markdown string to render */\n markdown: string;\n className?: string;\n /**\n * The [`target` attribute for `a` html\n * tags](https://developer.mozilla.org/en-US/docs/Web/HTML/Element/a#target). Defaults to not\n * adding a `target` to `a` tags\n */\n anchorTarget?: string;\n}\n\n/**\n * This component renders markdown content given a markdown string. It uses typography styles from\n * the platform.\n *\n * @param markdown The markdown string to render.\n * @param id Optional unique identifier\n * @returns A div containing the rendered markdown content.\n */\nexport default function MarkdownRenderer({\n id,\n markdown,\n className,\n anchorTarget,\n}: MarkdownRendererProps) {\n const options: MarkdownToJSX.Options = useMemo(\n () => ({\n overrides: {\n a: {\n props: {\n target: anchorTarget,\n },\n },\n },\n }),\n [anchorTarget],\n );\n return (\n
    \n {markdown}\n
    \n );\n}\n","import { Filter, ChevronDown } from 'lucide-react';\nimport { forwardRef } from 'react';\nimport { Button } from '@/components/shadcn-ui/button';\n\n/**\n * The FilterButton component is a button designed for initiating filtering of data. It is designed\n * to be used with the dropdown menu. It uses forwardRef to pass the button to the dropdown trigger\n * asChild.\n *\n * @returns A button that can be used to filter.\n */\nconst FilterButton = forwardRef((props, ref) => {\n return (\n \n \n Filter\n \n \n );\n});\n\nexport default FilterButton;\n","import {\n DropdownMenu,\n DropdownMenuTrigger,\n DropdownMenuContent,\n DropdownMenuLabel,\n DropdownMenuGroup,\n DropdownMenuCheckboxItem,\n DropdownMenuRadioItem,\n DropdownMenuSeparator,\n} from '@/components/shadcn-ui/dropdown-menu';\nimport FilterButton from './buttons/filter-button.component';\n\nexport enum DropdownMenuItemType {\n Check,\n Radio,\n}\n\nexport type DropdownItem = {\n /** The label is the text that will be displayed on the dropdown item. */\n label: string;\n /** The itemType determines the DropdownMenuItemType type as either Check or Radio. */\n itemType: DropdownMenuItemType;\n /** The onClick function is called when the item is clicked. */\n onClick: () => void;\n};\n\nexport type DropdownGroup = {\n /**\n * The label is the text that will be displayed on the dropdown group. It is used to categorize\n * the items in the group.\n */\n label: string;\n /** The items array contains the items that will be displayed in the dropdown group */\n items: DropdownItem[];\n};\n\nexport type FilterDropdownProps = {\n /** Object unique identifier */\n id?: string;\n /** The groups array contains the groups that will be displayed in the dropdown */\n groups: DropdownGroup[];\n}; // TODO: extend the props later\n\n/**\n * The FilterDropdown component is a dropdown designed for filtering content. It includes groups of\n * items that can be checkboxes or radio items.\n *\n * @param id Optional unique identifier\n * @param groups The groups array contains the groups that will be displayed in the dropdown\n * @returns A filter dropdown.\n */\nexport default function FilterDropdown({ id, groups }: FilterDropdownProps) {\n return (\n
    \n {/* TODO: remove this once the DropDown Menu shadcn has an id prop */}\n \n \n \n \n \n {groups.map((group) => (\n
    \n {group.label}\n \n {group.items.map((item) => (\n
    \n {item.itemType === DropdownMenuItemType.Check ? (\n \n {item.label}\n \n ) : (\n \n {item.label}\n \n )}\n
    \n ))}\n
    \n \n
    \n ))}\n
    \n
    \n
    \n );\n}\n","interface NoExtensionsFoundProps {\n /** Optional unique identifier */\n id?: string;\n /** The message to display */\n message: string;\n}\n/**\n * This component displays a message to the user when no extensions are found in the marketplace.\n *\n * @param id Optional unique identifier\n * @param message The message to display.\n * @returns {JSX.Element} - Returns the message component that displays the message to the user.\n */\nexport default function NoExtensionsFound({ id, message }: NoExtensionsFoundProps) {\n return (\n
    \n
    \n

    {message}

    \n
    \n
    \n );\n}\n","import { CircleHelp, Link as LucideLink, User } from 'lucide-react';\nimport { NumberFormat } from 'platform-bible-utils';\n\n/** Interface that stores the parameters passed to the More Info component */\ninterface MoreInfoProps {\n /** Optional unique identifier */\n id?: string;\n /** The category of the extension */\n category: string;\n /** The number of downloads for the extension */\n downloads: Record;\n /** The languages supported by the extension */\n languages: string[];\n /** The URL to the more info page of the extension */\n moreInfoUrl: string;\n}\n/**\n * This component displays the more info section of the extension which includes the category,\n * number of downloads, languages, and links to the website and support\n *\n * @param id Optional unique identifier\n * @param category The category of the extension\n * @param downloads The number of downloads for the extension\n * @param languages The languages supported by the extension\n * @param moreInfoUrl The URL to the more info page of the extension\n * @returns {JSX.Element} - Returns the more info component that displays the category, number of\n * downloads, languages, and links to the website and support\n */\nexport default function MoreInfo({\n id,\n category,\n downloads,\n languages,\n moreInfoUrl,\n}: MoreInfoProps) {\n /**\n * This constant formats the number of downloads into a more readable format.\n *\n * @example 1000 -> 1K\n *\n * @example 1000000 -> 1M\n *\n * @returns The formatted number of downloads\n */\n const numberFormatted = new NumberFormat('en', {\n notation: 'compact',\n compactDisplay: 'short',\n }).format(Object.values(downloads).reduce((a: number, b: number) => a + b, 0));\n\n /** This function scrolls the window to the bottom of the page. */\n const handleScrollToBottom = () => {\n window.scrollTo(0, document.body.scrollHeight);\n };\n\n return (\n \n
    \n
    \n {category}\n
    \n CATEGORY\n
    \n
    \n
    \n
    \n \n {numberFormatted}\n
    \n USERS\n
    \n
    \n
    \n
    \n {languages.slice(0, 3).map((locale) => (\n \n {locale.toUpperCase()}\n \n ))}\n
    \n {languages.length > 3 && (\n handleScrollToBottom()}\n className=\"tw-text-xs tw-text-gray-500 tw-underline\"\n >\n +{languages.length - 3} more languages\n \n )}\n
    \n
    \n
    \n \n Website\n \n \n \n Support\n \n \n
    \n
    \n );\n}\n","import { useState } from 'react';\n\nexport type VersionInformation = {\n /** Date the version was published */\n date: string;\n /** Description of the changes in the version */\n description: string;\n};\n\n/** Type to store the version history information */\nexport type VersionHistoryType = Record;\n\n/** Interface that stores the parameters passed to the Version History component */\ninterface VersionHistoryProps {\n /** Optional unique identifier */\n id?: string;\n /** Object containing the versions mapped with their information */\n versionHistory: VersionHistoryType;\n}\n\n/**\n * Component to render the version history information shown in the footer component. Lists the 5\n * most recent versions, with the options to show all versions by pressing a button.\n *\n * @param versionHistory Object containing the versions mapped with their information\n * @param id Optional unique identifier\n * @returns Rendered version history for the Footer component\n */\nexport default function VersionHistory({ id, versionHistory }: VersionHistoryProps) {\n const [showAllVersions, setShowAllVersions] = useState(false);\n const currentDate = new Date();\n\n /**\n * Function to format the time string for the version history in the form of 'X year(s) ago'.\n *\n * @param dateString ISO Date string to determine the time string from\n * @returns Formatted time string\n */\n function formatTimeString(dateString: string) {\n const date = new Date(dateString);\n const dateDiff = new Date(currentDate.getTime() - date.getTime());\n const yearDiff = dateDiff.getUTCFullYear() - 1970;\n const monthDiff = dateDiff.getUTCMonth();\n const dayDiff = dateDiff.getUTCDate() - 1;\n\n // Determines how long ago the version was published\n let timeString = '';\n if (yearDiff > 0) {\n timeString = `${yearDiff.toString()} year${yearDiff === 1 ? '' : 's'} ago`;\n } else if (monthDiff > 0) {\n timeString = `${monthDiff.toString()} month${monthDiff === 1 ? '' : 's'} ago`;\n } else if (dayDiff === 0) {\n timeString = 'today';\n } else {\n timeString = `${dayDiff.toString()} day${dayDiff === 1 ? '' : 's'} ago`;\n }\n\n return timeString;\n }\n\n // Sorts the version history by version number\n const sortedEntries = Object.entries(versionHistory).sort((a, b) => b[0].localeCompare(a[0]));\n\n return (\n
    \n

    What`s New

    \n
      \n {(showAllVersions ? sortedEntries : sortedEntries.slice(0, 5)).map((entry) => (\n
      \n
      \n
    • \n {entry[1].description}\n
    • \n
      \n
      \n
      Version {entry[0]}
      \n
      {formatTimeString(entry[1].date)}
      \n
      \n
      \n ))}\n
    \n {sortedEntries.length > 5 && (\n setShowAllVersions(!showAllVersions)}\n className=\"tw-text-xs tw-text-gray-500 tw-underline\"\n >\n {showAllVersions ? 'Show Less Version History' : 'Show All Version History'}\n \n )}\n
    \n );\n}\n","import { useMemo } from 'react';\nimport { formatBytes } from 'platform-bible-utils';\nimport VersionHistory, { VersionHistoryType } from './version-history.component';\n\n/** Interface to store the parameters passed to the Footer component */\ninterface FooterProps {\n /** Optional unique identifier */\n id?: string;\n /** Name of the publisher */\n publisherDisplayName: string;\n /** Size of the extension file in bytes */\n fileSize: number;\n /** List of language codes supported by the extension */\n locales: string[];\n /** Object containing the version history mapped with their information */\n versionHistory: VersionHistoryType;\n}\n\n/**\n * Component to render the footer for the extension details which contains information on the\n * publisher, version history, languages, and file size.\n *\n * @param id Optional unique identifier\n * @param publisherDisplayName Name of the publisher\n * @param fileSize Size of the extension file in bytes\n * @param locales List of language codes supported by the extension\n * @param versionHistory Object containing the version history mapped with their information\n * @returns The rendered Footer component\n */\nexport default function Footer({\n id,\n publisherDisplayName,\n fileSize,\n locales,\n versionHistory,\n}: FooterProps) {\n /** Formats the file size into a human-readable format */\n const formattedFileSize = useMemo(() => formatBytes(fileSize), [fileSize]);\n\n /**\n * This function gets the display names of the languages based on the language codes.\n *\n * @param codes The list of language codes\n * @returns The list of language names\n */\n const getLanguageNames = (codes: string[]) => {\n const displayNames = new Intl.DisplayNames(navigator.language, { type: 'language' });\n return codes.map((code) => displayNames.of(code));\n };\n\n const languageNames = getLanguageNames(locales);\n\n return (\n
    \n
    \n \n
    \n
    \n

    Information

    \n
    \n

    \n Publisher\n {publisherDisplayName}\n Size\n {formattedFileSize}\n

    \n
    \n

    \n Languages\n {languageNames.join(', ')}\n

    \n
    \n
    \n
    \n
    \n
    \n );\n}\n","import { PlatformEvent, PlatformEventHandler } from 'platform-bible-utils';\nimport { useEffect } from 'react';\n\n/**\n * Adds an event handler to an event so the event handler runs when the event is emitted. Use\n * `papi.network.getNetworkEvent` to use a networked event with this hook.\n *\n * @param event The event to subscribe to.\n *\n * - If event is a `PlatformEvent`, that event will be used\n * - If event is undefined, the callback will not be subscribed. Useful if the event is not yet\n * available for example\n *\n * @param eventHandler The callback to run when the event is emitted\n *\n * WARNING: MUST BE STABLE - const or wrapped in useCallback. The reference must not be updated\n * every render\n */\nconst useEvent = (\n event: PlatformEvent | undefined,\n eventHandler: PlatformEventHandler,\n) => {\n useEffect(() => {\n // Do nothing if the event is not provided (in case the event is not yet available, for example)\n if (!event) return () => {};\n\n const unsubscriber = event(eventHandler);\n return () => {\n unsubscriber();\n };\n }, [event, eventHandler]);\n};\nexport default useEvent;\n","import { useCallback, useEffect } from 'react';\nimport { PlatformEvent, PlatformEventAsync, PlatformEventHandler } from 'platform-bible-utils';\nimport usePromise from './use-promise.hook';\n\nconst noopUnsubscriber = () => false;\n\n/**\n * Adds an event handler to an asynchronously subscribing/unsubscribing event so the event handler\n * runs when the event is emitted. Use `papi.network.getNetworkEvent` to use a networked event with\n * this hook.\n *\n * @param event The asynchronously (un)subscribing event to subscribe to.\n *\n * - If event is a `PlatformEvent` or `PlatformEventAsync`, that event will be used\n * - If event is undefined, the callback will not be subscribed. Useful if the event is not yet\n * available for example\n *\n * @param eventHandler The callback to run when the event is emitted\n *\n * WARNING: MUST BE STABLE - const or wrapped in useCallback. The reference must not be updated\n * every render\n */\nconst useEventAsync = (\n event: PlatformEvent | PlatformEventAsync | undefined,\n eventHandler: PlatformEventHandler,\n) => {\n // Subscribe to the event asynchronously\n const [unsubscribe] = usePromise(\n useCallback(async () => {\n // Do nothing if the event is not provided (in case the event is not yet available, for example)\n if (!event) return noopUnsubscriber;\n\n // Wrap subscribe and unsubscribe in promises to allow normal events to be used as well\n const unsub = await Promise.resolve(event(eventHandler));\n return async () => unsub();\n }, [eventHandler, event]),\n noopUnsubscriber,\n // We want the unsubscriber to return to default value immediately upon changing subscription\n // So the useEffect below will unsubscribe asap\n { preserveValue: false },\n );\n\n // Unsubscribe from the event asynchronously (but we aren't awaiting the unsub)\n useEffect(() => {\n return () => {\n if (unsubscribe !== noopUnsubscriber) {\n unsubscribe();\n }\n };\n }, [unsubscribe]);\n};\n\nexport default useEventAsync;\n"],"names":["twMergeCustom","extendTailwindMerge","cn","inputs","clsx","Input","React","className","type","props","ref","jsx","BookChapterInput","forwardRef","handleSearch","handleKeyDown","handleOnClick","handleSubmit","jsxs","ShadInput","event","e","History","P","R","s","n","N","B","O","S","K","g","k","x","T","X","V","w","L","G","A","H","C","I","y","q","U","m","l","h","c","E","D","i","a","o","u","v","f","d","b","p","J","DropdownMenu","DropdownMenuPrimitive","DropdownMenuTrigger","DropdownMenuGroup","DropdownMenuPortal","DropdownMenuSub","DropdownMenuRadioGroup","DropdownMenuSubTrigger","inset","children","ChevronRight","DropdownMenuSubContent","DropdownMenuContent","sideOffset","DropdownMenuItem","DropdownMenuCheckboxItem","checked","Check","DropdownMenuRadioItem","Circle","DropdownMenuLabel","DropdownMenuSeparator","DropdownMenuShortcut","BookMenuItem","bookId","handleSelectBook","isSelected","handleHighlightBook","bookType","ShadDropdownMenuItem","Canon","ChapterSelect","handleSelectChapter","endChapter","activeChapter","highlightedChapter","handleHighlightedChapter","chapters","_","handleMouse","useCallback","chapterNumber","chapter","GoToMenuItem","handleSort","handleLocationHistory","handleBookmarks","ShadDropdownMenuLabel","ArrowDownWideNarrow","Clock","Bookmark","ALL_BOOK_IDS","BOOK_TYPE_LABELS","BOOK_TYPE_ARRAY","SCROLL_OFFSET","SEARCH_QUERY_FORMATS","fetchGroupedBooks","fetchEndChapter","getChaptersForBook","getAllEnglishNames","isValidBookEnglishName","bookName","getBookIdFromEnglishName","formattedBookName","BookChapterControl","scrRef","searchQuery","setSearchQuery","useState","selectedBookId","setSelectedBookId","setHighlightedChapter","highlightedBookId","setHighlightedBookId","isContentOpen","setIsContentOpen","isContentOpenDelayed","setIsContentOpenDelayed","inputRef","useRef","contentRef","menuItemRef","fetchFilteredBooks","englishNameLowerCase","normalizedQuery","handleSearchInput","searchString","shouldPreventAutoClosing","controlMenuState","open","updateReference","shouldClose","verse","handleInputSubmit","format","matches","book","englishName","handleKeyDownInput","handleKeyDownContent","key","handleKeyDownMenuItem","chapterOffSet","useEffect","useLayoutEffect","scrollTimeout","scrollPosition","ShadDropdownMenu","ShadDropdownMenuTrigger","ShadDropdownMenuContent","bookTypeIndex","element","ShadDropdownMenuSeparator","buttonVariants","cva","Button","variant","size","asChild","Slot","labelVariants","Label","LabelPrimitive","RadioGroup","RadioGroupPrimitive","RadioGroupItem","Popover","PopoverPrimitive","PopoverTrigger","PopoverContent","align","DialogPortal","DialogPrimitive","DialogOverlay","DialogContent","DialogTitle","DialogDescription","Command","CommandPrimitive","CommandInput","Search","CommandList","CommandEmpty","CommandGroup","CommandSeparator","CommandItem","getOptionLabelDefault","option","ComboBox","id","options","buttonClassName","popoverContentClassName","value","onChange","getOptionLabel","buttonPlaceholder","textPlaceholder","commandEmptyMessage","buttonVariant","dir","isDisabled","setOpen","ChevronsUpDown","ChapterRangeSelector","startChapter","handleSelectStartChapter","handleSelectEndChapter","chapterCount","chapterOptions","useMemo","index","Fragment","BookSelectionMode","BOOK_SELECTOR_STRING_KEYS","localizeString","strings","BookSelector","handleBookSelectionModeChange","currentBookName","onSelectBooks","selectedBookIds","localizedStrings","currentBookText","chooseText","chooseBooksText","bookSelectionMode","setBookSelectionMode","onSelectionModeChange","newMode","DataTableViewOptions","table","FilterIcon","column","Select","SelectPrimitive","SelectGroup","SelectValue","SelectTrigger","ChevronDown","SelectScrollUpButton","ChevronUp","SelectScrollDownButton","SelectContent","position","SelectLabel","SelectItem","SelectSeparator","DataTablePagination","pageSize","ArrowLeftIcon","ChevronLeftIcon","ChevronRightIcon","ArrowRightIcon","Table","stickyHeader","TableHeader","TableBody","TableFooter","TableRow","TableHead","TableCell","TableCaption","DataTable","columns","data","enablePagination","showPaginationControls","showColumnVisibilityControls","onRowClickHandler","sorting","setSorting","columnFilters","setColumnFilters","columnVisibility","setColumnVisibility","rowSelection","setRowSelection","useReactTable","getCoreRowModel","getPaginationRowModel","getSortedRowModel","getFilteredRowModel","headerGroup","header","flexRender","_a","row","cell","OccurrencesTable","occurrenceData","setScriptureReference","referenceHeaderText","occurrenceHeaderText","occurrences","uniqueOccurrences","occurrence","uniqueOccurrence","deepEqual","Checkbox","CheckboxPrimitive","getLinesFromUSFM","text","getNumberFromUSFM","regex","match","getBookNumFromId","getStatusForItem","item","approvedItems","unapprovedItems","toggleVariants","Toggle","TogglePrimitive","ToggleGroupContext","ToggleGroup","ToggleGroupPrimitive","ToggleGroupItem","context","getSortingIcon","sortDirection","ArrowUpIcon","ArrowDownIcon","ArrowUpDownIcon","inventoryItemColumn","itemLabel","inventoryAdditionalItemColumn","additionalItemLabel","additionalItemIndex","inventoryCountColumn","countLabel","statusChangeHandler","changedItems","newStatus","onApprovedItemsChange","onUnapprovedItemsChange","newApprovedItems","validItem","newUnapprovedItems","unapprovedItem","inventoryStatusColumn","statusLabel","status","CircleCheckIcon","CircleXIcon","CircleHelpIcon","INVENTORY_STRING_KEYS","filterItemData","itemData","statusFilter","textFilter","filteredItemData","createTableData","scriptureRef","itemRegex","tableData","currentBook","currentChapter","currentVerse","line","items","itemIndex","existingItem","tableEntry","newReference","substring","newItem","Inventory","scriptureReference","extractItems","additionalItemsLabels","scope","onScopeChange","allItemsText","approvedItemsText","unapprovedItemsText","unknownItemsText","scopeBookText","scopeChapterText","scopeVerseText","filterText","showAdditionalItemsText","showAdditionalItems","setShowAdditionalItems","setStatusFilter","setTextFilter","selectedItem","setSelectedItem","reducedTableData","newTableData","firstItem","existingEntry","newTableEntry","filteredTableData","allColumns","numberOfAdditionalItems","additionalColumns","_b","rowClickHandler","newSelection","handleScopeChange","handleStatusFilterChange","SearchBar","onSearch","placeholder","isFullWidth","handleInputChange","VerticalTabs","TabsPrimitive","VerticalTabsList","VerticalTabsTrigger","VerticalTabsContent","TabNavigationContentSearch","tabList","searchPlaceholder","headerTitle","isSearchBarFullWidth","direction","tab","Separator","orientation","decorative","SeparatorPrimitive","Sheet","SheetPrimitive","SheetPortal","SheetOverlay","sheetVariants","SheetContent","side","SheetTitle","SheetDescription","Skeleton","TooltipProvider","TooltipPrimitive","Tooltip","TooltipTrigger","TooltipContent","MOBILE_BREAKPOINT","useIsMobile","isMobile","setIsMobile","mql","SIDEBAR_COOKIE_NAME","SIDEBAR_COOKIE_MAX_AGE","SIDEBAR_WIDTH","SIDEBAR_WIDTH_MOBILE","SIDEBAR_WIDTH_ICON","SIDEBAR_KEYBOARD_SHORTCUT","SidebarContext","useSidebar","SidebarProvider","defaultOpen","openProp","setOpenProp","style","openMobile","setOpenMobile","_open","_setOpen","isOpen","openState","toggleSidebar","state","contextValue","Sidebar","collapsible","SidebarTrigger","onClick","PanelLeft","SidebarRail","SidebarInset","SidebarInput","SidebarHeader","SidebarFooter","SidebarSeparator","SidebarContent","SidebarGroup","SidebarGroupLabel","SidebarGroupAction","SidebarGroupContent","SidebarMenu","SidebarMenuItem","sidebarMenuButtonVariants","SidebarMenuButton","isActive","tooltip","Comp","button","SidebarMenuAction","showOnHover","SidebarMenuBadge","SidebarMenuSkeleton","showIcon","width","SidebarMenuSub","SidebarMenuSubItem","SidebarMenuSubButton","SettingsSidebar","extensionLabels","projectOptions","handleSelectSidebarItem","selectedSidebarItem","extensionsSidebarGroupLabel","projectsSidebarGroupLabel","handleSelectItem","projectId","getProjectNameFromProjectId","project","getIsActive","label","selectedProjectName","SettingsSidebarContentSearch","scrBookColId","scrRefColId","typeColId","detailsColId","defaultScrRefColumnName","defaultScrBookGroupName","defaultTypeColumnName","defaultDetailsColumnName","getColumns","colInfo","showSourceColumn","showSrcCol","info","formatScrRef","compareScrRefs","toRefOrRange","scriptureSelection","offsetStart","offsetEnd","scrRefToBBBCCCVVV","getRowKey","ScriptureResultsViewer","sources","showColumnHeaders","scriptureReferenceColumnName","scriptureBookGroupName","typeColumnName","detailsColumnName","onRowSelected","grouping","setGrouping","scriptureResults","source","getExpandedRowModel","getGroupedRowModel","selectedRows","keys","selectedRow","scrBookGroupName","typeGroupName","groupingOptions","handleSelectChange","selectedGrouping","handleRowClick","getEvenOrOddBandingStyle","getIndent","groupingState","rowIndex","ChevronLeft","DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS","getLocalizeKeyForScrollGroupId","ScrollGroupSelector","availableScrollGroupIds","scrollGroupId","onChangeScrollGroupId","localizedStringsDefaulted","localizedStringKey","localizedStringValue","newScrollGroupString","scrollGroupOptionId","SettingsList","SettingsListItem","primary","secondary","isLoading","loadingMessage","SettingsListHeader","includeSeparator","Checklist","listItems","selectedListItems","handleSelectListItem","createLabel","_interopRequireDefault","obj","module","chainPropTypes","propType1","propType2","args","_extends","target","isPlainObject","prototype","deepClone","output","deepmerge","r","t","z","reactIs_production_min","hasSymbol","REACT_ELEMENT_TYPE","REACT_PORTAL_TYPE","REACT_FRAGMENT_TYPE","REACT_STRICT_MODE_TYPE","REACT_PROFILER_TYPE","REACT_PROVIDER_TYPE","REACT_CONTEXT_TYPE","REACT_ASYNC_MODE_TYPE","REACT_CONCURRENT_MODE_TYPE","REACT_FORWARD_REF_TYPE","REACT_SUSPENSE_TYPE","REACT_SUSPENSE_LIST_TYPE","REACT_MEMO_TYPE","REACT_LAZY_TYPE","REACT_BLOCK_TYPE","REACT_FUNDAMENTAL_TYPE","REACT_RESPONDER_TYPE","REACT_SCOPE_TYPE","isValidElementType","typeOf","object","$$typeof","$$typeofType","AsyncMode","ConcurrentMode","ContextConsumer","ContextProvider","Element","ForwardRef","Lazy","Memo","Portal","Profiler","StrictMode","Suspense","hasWarnedAboutDeprecatedIsAsyncMode","isAsyncMode","isConcurrentMode","isContextConsumer","isContextProvider","isElement","isForwardRef","isFragment","isLazy","isMemo","isPortal","isProfiler","isStrictMode","isSuspense","reactIs_development","reactIsModule","require$$0","require$$1","getOwnPropertySymbols","hasOwnProperty","propIsEnumerable","toObject","val","shouldUseNative","test1","test2","order2","test3","letter","objectAssign","from","to","symbols","ReactPropTypesSecret","ReactPropTypesSecret_1","has","printWarning","loggedTypeFailures","message","checkPropTypes","typeSpecs","values","location","componentName","getStack","typeSpecName","error","err","ex","stack","checkPropTypes_1","ReactIs","assign","require$$2","require$$3","require$$4","emptyFunctionThatReturnsNull","factoryWithTypeCheckers","isValidElement","throwOnDirectAccess","ITERATOR_SYMBOL","FAUX_ITERATOR_SYMBOL","getIteratorFn","maybeIterable","iteratorFn","ANONYMOUS","ReactPropTypes","createPrimitiveTypeChecker","createAnyTypeChecker","createArrayOfTypeChecker","createElementTypeChecker","createElementTypeTypeChecker","createInstanceTypeChecker","createNodeChecker","createObjectOfTypeChecker","createEnumTypeChecker","createUnionTypeChecker","createShapeTypeChecker","createStrictShapeTypeChecker","is","PropTypeError","createChainableTypeChecker","validate","manualPropTypeCallCache","manualPropTypeWarningCount","checkType","isRequired","propName","propFullName","secret","cacheKey","chainedCheckType","expectedType","propValue","propType","getPropType","preciseType","getPreciseType","typeChecker","expectedClass","expectedClassName","actualClassName","getClassName","expectedValues","valuesString","arrayOfTypeCheckers","checker","getPostfixForTypeWarning","expectedTypes","checkerResult","expectedTypesMessage","isNode","invalidValidatorError","shapeTypes","allKeys","iterator","step","entry","isSymbol","emptyFunction","emptyFunctionWithReset","factoryWithThrowingShims","shim","getShim","propTypesModule","isClassComponent","elementType","acceptingRef","safePropName","warningHint","elementAcceptingRef","PropTypes","elementAcceptingRef$1","specialProperty","exactProp","propTypes","unsupportedProps","prop","formatMuiErrorMessage","code","url","REACT_SERVER_CONTEXT_TYPE","REACT_OFFSCREEN_TYPE","enableScopeAPI","enableCacheElement","enableTransitionTracing","enableLegacyHidden","enableDebugTracing","REACT_MODULE_REFERENCE","SuspenseList","hasWarnedAboutDeprecatedIsConcurrentMode","isSuspenseList","fnNameMatchRegex","getFunctionName","fn","getFunctionComponentName","Component","fallback","getWrappedName","outerType","innerType","wrapperName","functionName","getDisplayName","HTMLElementType","refType","refType$1","capitalize","string","_formatMuiErrorMessage","createChainedFunction","funcs","acc","func","debounce","wait","timeout","debounced","later","deprecatedPropType","validator","reason","componentNameSafe","propFullNameSafe","isMuiElement","muiNames","_muiName","_element$type","ownerDocument","node","ownerWindow","requirePropFactory","componentNameInError","prevPropTypes","requiredProp","defaultTypeChecker","typeCheckerResult","setRef","useEnhancedEffect","useEnhancedEffect$1","globalId","useGlobalId","idOverride","defaultId","setDefaultId","maybeReactUseId","useId","reactId","unsupportedProp","useControlled","controlled","defaultProp","name","isControlled","valueState","setValue","defaultValue","setValueIfUncontrolled","newValue","useEventCallback","useForkRef","refs","instance","UNINITIALIZED","useLazyRef","init","initArg","EMPTY","useOnMount","Timeout","delay","useTimeout","hadKeyboardEvent","hadFocusVisibleRecently","hadFocusVisibleRecentlyTimeout","inputTypesWhitelist","focusTriggersKeyboardModality","tagName","handlePointerDown","handleVisibilityChange","prepare","doc","isFocusVisible","useIsFocusVisible","isFocusVisibleRef","handleBlurVisible","handleFocusVisible","resolveProps","defaultProps","defaultSlotProps","slotProps","slotPropName","composeClasses","slots","getUtilityClass","classes","slot","utilityClass","defaultGenerator","createClassNameGenerator","generate","generator","ClassNameGenerator","ClassNameGenerator$1","globalStateClasses","generateUtilityClass","globalStatePrefix","globalStateClass","generateUtilityClasses","result","clamp","min","max","_objectWithoutPropertiesLoose","excluded","sourceKeys","_excluded","sortBreakpointsValues","breakpointsAsArray","breakpoint1","breakpoint2","createBreakpoints","breakpoints","unit","other","sortedValues","up","down","between","start","end","endIndex","only","not","keyIndex","shape","shape$1","responsivePropType","responsivePropType$1","merge","defaultBreakpoints","handleBreakpoints","styleFromPropValue","theme","themeBreakpoints","breakpoint","mediaKey","cssKey","createEmptyBreakpointObject","breakpointsInput","_breakpointsInput$key","breakpointStyleKey","removeUnusedBreakpoints","breakpointKeys","breakpointOutput","getPath","path","checkVars","getStyleValue","themeMapping","transform","propValueFinal","userValue","cssProperty","themeKey","memoize","cache","arg","properties","directions","aliases","getCssProperties","property","marginKeys","paddingKeys","spacingKeys","createUnaryUnit","_getPath","themeSpacing","abs","createUnarySpacing","getValue","transformer","transformed","getStyleFromPropValue","cssProperties","resolveCssProperty","margin","padding","createSpacing","spacingInput","spacing","argsInput","argument","compose","styles","handlers","borderTransform","createBorderStyle","border","borderTop","borderRight","borderBottom","borderLeft","borderColor","borderTopColor","borderRightColor","borderBottomColor","borderLeftColor","outline","outlineColor","borderRadius","gap","columnGap","rowGap","gridColumn","gridRow","gridAutoFlow","gridAutoColumns","gridAutoRows","gridTemplateColumns","gridTemplateRows","gridTemplateAreas","gridArea","paletteTransform","color","bgcolor","backgroundColor","sizingTransform","maxWidth","_props$theme","_props$theme2","breakpointsValues","minWidth","height","maxHeight","minHeight","boxSizing","defaultSxConfig","defaultSxConfig$1","objectsHaveSameKeys","objects","union","callIfFn","maybeFn","unstable_createStyleFunctionSx","getThemeValue","config","styleFunctionSx","_theme$unstable_sxCon","sx","traverse","sxInput","sxObject","emptyBreakpoints","breakpointsKeys","css","styleKey","styleFunctionSx$1","applyStyles","createTheme","paletteInput","shapeInput","muiTheme","isObjectEmpty","useTheme","defaultTheme","contextTheme","ThemeContext","systemDefaultTheme","useThemeWithoutDefault","_excluded2","_excluded3","isEmpty","isStringTag","tag","shouldForwardProp","lowercaseFirstLetter","resolveTheme","themeId","defaultOverridesResolver","processStyleArg","callableStyle","_ref","ownerState","resolvedStylesArg","resolvedStyle","variants","isMatch","createStyled","input","rootShouldForwardProp","slotShouldForwardProp","systemSx","inputOptions","processStyles","componentSlot","inputSkipVariantsResolver","inputSkipSx","overridesResolver","skipVariantsResolver","skipSx","shouldForwardPropOption","defaultStyledResolver","styledEngineStyled","transformStyleArg","stylesArg","muiStyledResolver","styleArg","expressions","transformedStyleArg","expressionsWithDefaultTheme","styleOverrides","resolvedStyleOverrides","slotKey","slotStyle","_theme$components","themeVariants","numOfCustomFnsApplied","placeholders","displayName","getThemeProps","params","useThemeProps","clampWrapper","hexToRgb","re","colors","decomposeColor","marker","colorSpace","recomposeColor","hslToRgb","rgb","getLuminance","getContrastRatio","foreground","background","lumA","lumB","alpha","darken","coefficient","lighten","createMixins","mixins","common","common$1","grey","grey$1","purple","purple$1","red","red$1","orange","orange$1","blue","blue$1","lightBlue","lightBlue$1","green","green$1","light","dark","addLightOrDark","intent","shade","tonalOffset","tonalOffsetLight","tonalOffsetDark","getDefaultPrimary","mode","getDefaultSecondary","getDefaultError","getDefaultInfo","getDefaultSuccess","getDefaultWarning","createPalette","palette","contrastThreshold","success","warning","getContrastText","contrastText","contrast","augmentColor","mainShade","lightShade","darkShade","modes","round","caseAllCaps","defaultFontFamily","createTypography","typography","fontFamily","fontSize","fontWeightLight","fontWeightRegular","fontWeightMedium","fontWeightBold","htmlFontSize","allVariants","pxToRem2","coef","pxToRem","buildVariant","fontWeight","lineHeight","letterSpacing","casing","shadowKeyUmbraOpacity","shadowKeyPenumbraOpacity","shadowAmbientShadowOpacity","createShadow","px","shadows","shadows$1","easing","duration","formatMs","milliseconds","getAutoHeightDuration","constant","createTransitions","inputTransitions","mergedEasing","mergedDuration","durationOption","easingOption","isString","isNumber","animatedProp","zIndex","zIndex$1","mixinsInput","transitionsInput","typographyInput","systemTheme","systemCreateTheme","stateClasses","component","child","stateClass","defaultTheme$1","THEME_ID","systemUseThemeProps","styled","styled$1","getSvgIconUtilityClass","useUtilityClasses","SvgIconRoot","_theme$transitions","_theme$transitions$cr","_theme$transitions2","_theme$typography","_theme$typography$pxT","_theme$typography2","_theme$typography2$px","_theme$typography3","_theme$typography3$px","_palette$ownerState$c","_palette","_palette2","_palette3","SvgIcon","inProps","htmlColor","inheritViewBox","titleAccess","viewBox","hasSvgAsChild","more","_jsxs","_jsx","SvgIcon$1","createSvgIcon","unstable_ClassNameGenerator","exports","_utils","ArrowRight","default_1","_createSvgIcon","_jsxRuntime","isHostComponent","appendOwnerState","otherProps","defaultContextValue","ClassNameConfiguratorContext","useClassNamesOverride","disableDefaultClasses","extractEventHandlers","excludeKeys","resolveComponentProps","componentProps","slotState","omitEventHandlers","mergeSlotProps","parameters","getSlotProps","additionalProps","externalSlotProps","externalForwardedProps","joinedClasses","mergedStyle","eventHandlers","componentsPropsWithoutEventHandlers","otherPropsWithoutEventHandlers","internalSlotProps","useSlotProps","_parameters$additiona","skipResolvingSlotProps","rest","resolvedComponentsProps","mergedProps","internalRef","GLOBAL_CLASS_PREFIX","buildStateClass","buildSlotClass","getContainer","container","forwardedRef","disablePortal","mountNode","setMountNode","handleRef","newProps","ReactDOM","top","bottom","right","left","auto","basePlacements","clippingParents","viewport","popper","reference","variationPlacements","placement","placements","beforeRead","read","afterRead","beforeMain","main","afterMain","beforeWrite","write","afterWrite","modifierPhases","getNodeName","getWindow","OwnElement","isHTMLElement","isShadowRoot","attributes","effect","_ref2","initialStyles","styleProperties","attribute","applyStyles$1","getBasePlacement","getUAString","uaData","isLayoutViewport","getBoundingClientRect","includeScale","isFixedStrategy","clientRect","scaleX","scaleY","visualViewport","addVisualOffsets","getLayoutRect","contains","parent","rootNode","next","getComputedStyle","isTableElement","getDocumentElement","getParentNode","getTrueOffsetParent","getContainingBlock","isFirefox","isIE","elementCss","currentNode","getOffsetParent","window","offsetParent","getMainAxisFromPlacement","within","mathMax","mathMin","withinMaxClamp","getFreshSideObject","mergePaddingObject","paddingObject","expandToHashMap","hashMap","toPaddingObject","arrow","_state$modifiersData$","arrowElement","popperOffsets","basePlacement","axis","isVertical","len","arrowRect","minProp","maxProp","endDiff","startDiff","arrowOffsetParent","clientSize","centerToReference","center","offset","axisProp","_options$element","arrow$1","getVariation","unsetSides","roundOffsetsByDPR","win","dpr","mapToStyles","_Object$assign2","popperRect","variation","offsets","gpuAcceleration","adaptive","roundOffsets","isFixed","_offsets$x","_offsets$y","_ref3","hasX","hasY","sideX","sideY","heightProp","widthProp","offsetY","offsetX","commonStyles","_ref4","_Object$assign","computeStyles","_ref5","_options$gpuAccelerat","_options$adaptive","_options$roundOffsets","computeStyles$1","passive","_options$scroll","scroll","_options$resize","resize","scrollParents","scrollParent","eventListeners","hash","getOppositePlacement","matched","getOppositeVariationPlacement","getWindowScroll","scrollLeft","scrollTop","getWindowScrollBarX","getViewportRect","strategy","html","layoutViewport","getDocumentRect","_element$ownerDocumen","winScroll","body","isScrollParent","_getComputedStyle","overflow","overflowX","overflowY","getScrollParent","listScrollParents","list","isBody","updatedList","rectToClientRect","rect","getInnerBoundingClientRect","getClientRectFromMixedType","clippingParent","getClippingParents","canEscapeClipping","clipperElement","getClippingRect","boundary","rootBoundary","mainClippingParents","firstClippingParent","clippingRect","accRect","computeOffsets","commonX","commonY","mainAxis","detectOverflow","_options","_options$placement","_options$strategy","_options$boundary","_options$rootBoundary","_options$elementConte","elementContext","_options$altBoundary","altBoundary","_options$padding","altContext","clippingClientRect","referenceClientRect","popperClientRect","elementClientRect","overflowOffsets","offsetData","multiply","computeAutoPlacement","flipVariations","_options$allowedAutoP","allowedAutoPlacements","allPlacements","allowedPlacements","overflows","getExpandedFallbackPlacements","oppositePlacement","flip","_options$mainAxis","checkMainAxis","_options$altAxis","checkAltAxis","specifiedFallbackPlacements","_options$flipVariatio","preferredPlacement","isBasePlacement","fallbackPlacements","referenceRect","checksMap","makeFallbackChecks","firstFittingPlacement","_basePlacement","isStartVariation","mainVariationSide","altVariationSide","checks","check","numberOfChecks","_loop","_i","fittingPlacement","_ret","flip$1","getSideOffsets","preventedOffsets","isAnySideFullyClipped","hide","referenceOverflow","popperAltOverflow","referenceClippingOffsets","popperEscapeOffsets","isReferenceHidden","hasPopperEscaped","hide$1","distanceAndSkiddingToXY","rects","invertDistance","skidding","distance","_options$offset","_data$state$placement","offset$1","popperOffsets$1","getAltAxis","preventOverflow","_options$tether","tether","_options$tetherOffset","tetherOffset","altAxis","tetherOffsetValue","normalizedTetherOffsetValue","offsetModifierState","_offsetModifierState$","mainSide","altSide","additive","minLen","maxLen","arrowPaddingObject","arrowPaddingMin","arrowPaddingMax","arrowLen","minOffset","maxOffset","clientOffset","offsetModifierValue","tetherMin","tetherMax","preventedOffset","_offsetModifierState$2","_mainSide","_altSide","_offset","_len","_min","_max","isOriginSide","_offsetModifierValue","_tetherMin","_tetherMax","_preventedOffset","preventOverflow$1","getHTMLElementScroll","getNodeScroll","isElementScaled","getCompositeRect","elementOrVirtualElement","isOffsetParentAnElement","offsetParentIsScaled","documentElement","order","modifiers","map","visited","modifier","sort","requires","dep","depModifier","orderModifiers","orderedModifiers","phase","pending","resolve","mergeByName","merged","current","existing","DEFAULT_OPTIONS","areValidElements","_key","popperGenerator","generatorOptions","_generatorOptions","_generatorOptions$def","defaultModifiers","_generatorOptions$def2","defaultOptions","effectCleanupFns","isDestroyed","setOptionsAction","cleanupModifierEffects","runModifierEffects","_state$elements","_state$orderedModifie","_state$orderedModifie2","_ref$options","cleanupFn","noopFn","createPopper","COMPONENT_NAME","getPopperUtilityClass","flipPlacement","resolveAnchorEl","anchorEl","isVirtualElement","defaultPopperOptions","PopperTooltip","_slots$root","initialPlacement","popperOptions","popperRefProp","TransitionProps","tooltipRef","ownRef","popperRef","handlePopperRef","handlePopperRefRef","rtlPlacement","setPlacement","resolvedAnchorElement","setResolvedAnchorElement","handlePopperUpdate","box","popperModifiers","childProps","Root","rootProps","Popper","containerProp","keepMounted","transition","exited","setExited","handleEnter","handleExited","resolvedAnchorEl","display","transitionProps","useThemeSystem","_setPrototypeOf","_inheritsLoose","subClass","superClass","setPrototypeOf","timeoutsShape","TransitionGroupContext","forceReflow","UNMOUNTED","EXITED","ENTERING","ENTERED","EXITING","Transition","_React$Component","_this","parentGroup","appear","initialStatus","prevState","nextIn","_proto","prevProps","nextStatus","exit","enter","mounting","_this2","appearing","maybeNode","maybeAppearing","timeouts","enterTimeout","_this3","nextState","callback","_this4","active","handler","doesNotHaveTimeoutOrListener","maybeNextCallback","_this$props","pt","noop","Transition$1","reflow","getTransitionProps","_style$transitionDura","_style$transitionTimi","getScale","isWebKit154","Grow","addEndListener","inProp","onEnter","onEntered","onEntering","onExit","onExited","onExiting","TransitionComponent","timer","autoTimeout","nodeRef","normalizedTransitionCallback","maybeIsAppearing","handleEntering","isAppearing","transitionDuration","transitionTimingFunction","handleEntered","handleExiting","handleExit","Grow$1","PopperRoot","BasePopper","components","componentsProps","RootComponent","Popper$1","getTooltipUtilityClass","tooltipClasses","tooltipClasses$1","disableInteractive","touch","TooltipPopper","TooltipTooltip","TooltipArrow","hystersisOpen","hystersisTimer","cursorPosition","composeEventHandler","eventHandler","_slots$popper","_slots$transition","_slots$tooltip","_slots$arrow","_slotProps$popper","_ref6","_slotProps$popper2","_slotProps$transition","_slotProps$tooltip","_ref7","_slotProps$tooltip2","_slotProps$arrow","_ref8","_slotProps$arrow2","childrenProp","describeChild","disableFocusListener","disableHoverListener","disableInteractiveProp","disableTouchListener","enterDelay","enterNextDelay","enterTouchDelay","followCursor","idProp","leaveDelay","leaveTouchDelay","onClose","onOpen","PopperComponentProp","PopperProps","title","TransitionComponentProp","isRtl","childNode","setChildNode","arrowRef","setArrowRef","ignoreNonTouchEvents","closeTimer","enterTimer","leaveTimer","touchTimer","setOpenState","prevUserSelect","stopTouchInteraction","handleOpen","handleClose","handleLeave","focusVisibleRef","setChildIsFocusVisible","handleBlur","handleFocus","detectTouchStart","childrenProps","handleMouseOver","handleMouseLeave","handleTouchStart","handleTouchEnd","nativeEvent","handleMouseMove","nameOrDescProps","titleIsString","interactiveWrapperListeners","_PopperProps$popperOp","tooltipModifiers","PopperComponent","TooltipComponent","ArrowComponent","popperProps","tooltipProps","tooltipArrowProps","TransitionPropsInner","Tooltip$1","getIcon","icon","menuLabel","leading","MuiListItemIcon","MenuItem","allowForLeadingIcons","iconPathBefore","iconPathAfter","hasAutoFocus","isDense","isSubMenuParent","hasDisabledGutters","hasDivider","focusVisibleClassName","menuItem","MuiMenuItem","MuiListItemText","getAllGroups","menuDefinition","SubMenu","setAnchorEl","parentMenuItem","parentItemProps","handleParentMenuItemClick","renderSubMenuItems","includedGroups","group","GroupedMenuItemList","Menu","getOrderedGroupItems","groupId","allItems","menuProps","commandHandler","groupsToInclude","sortedGroups","itemArray","allowSpaceForLeadingIcons","createMenuItemProps","isLastItemInGroup","divKey","itemInfo","menuItemProps","TopLevelMenu","columnId","MenuColumn","metadata","Grid","List","GridMenu","multiColumnMenu","sortedColumns","columnNumbers","columnName","col","getUsePromiseOptionsDefaults","usePromise","promiseFactoryCallback","defaultValueRef","optionsDefaultedRef","setIsLoading","promiseIsCurrent","MenuIcon","HamburgerMenuButton","menuProvider","normalMenu","fullMenu","containerRef","ariaLabelPrefix","isMenuOpen","setMenuOpen","showFullMenu","setShowFullMenu","handleMenuItemClick","handleMenuButtonClick","prevIsOpen","isOpening","menuCommandHandler","command","setOffset","normalMenuData","fullMenuData","menu","IconButton","Drawer","isTooltipSuppressed","adjustMarginToAlignToEdge","MuiIconButton","Spinner","LoaderCircle","TextField","hasError","helperText","onFocus","onBlur","ShadLabel","Toolbar","AppBar","MuiToolbar","alertVariants","Alert","AlertTitle","AlertDescription","Card","CardHeader","CardTitle","CardDescription","CardContent","CardFooter","Sonner","Toaster","Slider","SliderPrimitive","Switch","SwitchPrimitives","Tabs","TabsList","TabsTrigger","TabsContent","InstallButton","isInstalling","handleClick","buttonText","Download","EnableButton","isEnabling","DisableButton","isDisabling","UpdateButton","isUpdating","MarkdownRenderer","markdown","anchorTarget","Markdown","FilterButton","Filter","DropdownMenuItemType","DropdownMenuItemType2","FilterDropdown","groups","NoExtensionsFound","MoreInfo","category","downloads","languages","moreInfoUrl","numberFormatted","NumberFormat","handleScrollToBottom","User","locale","LucideLink","CircleHelp","VersionHistory","versionHistory","showAllVersions","setShowAllVersions","currentDate","formatTimeString","dateString","date","dateDiff","yearDiff","monthDiff","dayDiff","timeString","sortedEntries","Footer","publisherDisplayName","fileSize","locales","formattedFileSize","formatBytes","languageNames","codes","displayNames","useEvent","unsubscriber","noopUnsubscriber","useEventAsync","unsubscribe","unsub"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;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;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","x_google_ignoreList":[3,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,83,84,85,86,87,88,89,90,91,92,93,94,95,96,97,98,99,100,101,102,103,104,105,106,107,108,109,110,111,112,113,114,115,116,117,118,119,120,121,122,123,124,125,126,127,128,129,130,131,132,133,134,135,136,137,138,139,140,141,142,143,144,145,146,147,148,149,150,151,152,153,154,155,156,157,158,159,160,161,162,163,164,165,166,167,168,169,170,171,172,173,174,175,176,177,178,179,180,181,182,183,184,185,186,187,188,189,190,191,192,193,194,195,196,197,198,199,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,228]} \ No newline at end of file +{"version":3,"file":"index.js","sources":["../src/utils/shadcn-ui.util.ts","../src/components/shadcn-ui/input.tsx","../src/components/advanced/book-chapter-control/book-chapter-input.component.tsx","../../../node_modules/@sillsdev/scripture/dist/index.es.js","../src/components/shadcn-ui/dropdown-menu.tsx","../src/components/advanced/book-chapter-control/book-menu-item.component.tsx","../src/components/advanced/book-chapter-control/chapter-select.component.tsx","../src/components/advanced/book-chapter-control/go-to-menu-item.component.tsx","../src/components/advanced/book-chapter-control/book-chapter-control.component.tsx","../src/components/shadcn-ui/button.tsx","../src/components/shadcn-ui/label.tsx","../src/components/shadcn-ui/radio-group.tsx","../src/components/shadcn-ui/popover.tsx","../src/components/shadcn-ui/dialog.tsx","../src/components/shadcn-ui/command.tsx","../src/components/basics/combo-box.component.tsx","../src/components/basics/chapter-range-selector.component.tsx","../src/components/advanced/book-selector.component.tsx","../src/components/advanced/data-table/data-table-column-toggle.component.tsx","../src/components/shadcn-ui/select.tsx","../src/components/advanced/data-table/data-table-pagination.component.tsx","../src/components/shadcn-ui/table.tsx","../src/components/advanced/data-table/data-table.component.tsx","../src/components/advanced/inventory/occurrences-table.component.tsx","../src/components/shadcn-ui/checkbox.tsx","../src/components/advanced/inventory/inventory-utils.ts","../src/components/shadcn-ui/toggle.tsx","../src/components/shadcn-ui/toggle-group.tsx","../src/components/advanced/inventory/inventory-columns.tsx","../src/components/advanced/inventory/inventory.component.tsx","../src/components/basics/search-bar.component.tsx","../src/components/basics/tabs-vertical.tsx","../src/components/advanced/tab-navigation-content-search.component.tsx","../src/components/shadcn-ui/separator.tsx","../src/components/shadcn-ui/sheet.tsx","../src/components/shadcn-ui/skeleton.tsx","../src/components/shadcn-ui/tooltip.tsx","../src/components/hooks/use-mobile.tsx","../src/components/shadcn-ui/sidebar.tsx","../src/components/advanced/settings-components/settings-sidebar.component.tsx","../src/components/advanced/settings-components/settings-sidebar-content-search.component.tsx","../src/components/advanced/scripture-results-viewer/scripture-results-viewer.component.tsx","../src/components/advanced/scroll-group-selector.component.tsx","../src/components/advanced/settings-components/settings-list.component.tsx","../src/components/basics/checklist.component.tsx","../../../node_modules/@babel/runtime/helpers/interopRequireDefault.js","../../../node_modules/@mui/utils/chainPropTypes/chainPropTypes.js","../../../node_modules/@babel/runtime/helpers/esm/extends.js","../../../node_modules/@mui/utils/deepmerge/deepmerge.js","../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.production.min.js","../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.development.js","../../../node_modules/prop-types/node_modules/react-is/index.js","../../../node_modules/object-assign/index.js","../../../node_modules/prop-types/lib/ReactPropTypesSecret.js","../../../node_modules/prop-types/lib/has.js","../../../node_modules/prop-types/checkPropTypes.js","../../../node_modules/prop-types/factoryWithTypeCheckers.js","../../../node_modules/prop-types/factoryWithThrowingShims.js","../../../node_modules/prop-types/index.js","../../../node_modules/@mui/utils/elementAcceptingRef/elementAcceptingRef.js","../../../node_modules/@mui/utils/exactProp/exactProp.js","../../../node_modules/@mui/utils/formatMuiErrorMessage/formatMuiErrorMessage.js","../../../node_modules/react-is/cjs/react-is.production.min.js","../../../node_modules/react-is/cjs/react-is.development.js","../../../node_modules/react-is/index.js","../../../node_modules/@mui/utils/getDisplayName/getDisplayName.js","../../../node_modules/@mui/utils/HTMLElementType/HTMLElementType.js","../../../node_modules/@mui/utils/refType/refType.js","../../../node_modules/@mui/utils/capitalize/capitalize.js","../../../node_modules/@mui/utils/createChainedFunction/createChainedFunction.js","../../../node_modules/@mui/utils/debounce/debounce.js","../../../node_modules/@mui/utils/deprecatedPropType/deprecatedPropType.js","../../../node_modules/@mui/utils/isMuiElement/isMuiElement.js","../../../node_modules/@mui/utils/ownerDocument/ownerDocument.js","../../../node_modules/@mui/utils/ownerWindow/ownerWindow.js","../../../node_modules/@mui/utils/requirePropFactory/requirePropFactory.js","../../../node_modules/@mui/utils/setRef/setRef.js","../../../node_modules/@mui/utils/useEnhancedEffect/useEnhancedEffect.js","../../../node_modules/@mui/utils/useId/useId.js","../../../node_modules/@mui/utils/unsupportedProp/unsupportedProp.js","../../../node_modules/@mui/utils/useControlled/useControlled.js","../../../node_modules/@mui/utils/useEventCallback/useEventCallback.js","../../../node_modules/@mui/utils/useForkRef/useForkRef.js","../../../node_modules/@mui/utils/useLazyRef/useLazyRef.js","../../../node_modules/@mui/utils/useOnMount/useOnMount.js","../../../node_modules/@mui/utils/useTimeout/useTimeout.js","../../../node_modules/@mui/utils/useIsFocusVisible/useIsFocusVisible.js","../../../node_modules/@mui/utils/resolveProps/resolveProps.js","../../../node_modules/@mui/utils/composeClasses/composeClasses.js","../../../node_modules/@mui/utils/ClassNameGenerator/ClassNameGenerator.js","../../../node_modules/@mui/utils/generateUtilityClass/generateUtilityClass.js","../../../node_modules/@mui/utils/generateUtilityClasses/generateUtilityClasses.js","../../../node_modules/@mui/utils/clamp/clamp.js","../../../node_modules/@babel/runtime/helpers/esm/objectWithoutPropertiesLoose.js","../../../node_modules/@mui/system/esm/createTheme/createBreakpoints.js","../../../node_modules/@mui/system/esm/createTheme/shape.js","../../../node_modules/@mui/system/esm/responsivePropType.js","../../../node_modules/@mui/system/esm/merge.js","../../../node_modules/@mui/system/esm/breakpoints.js","../../../node_modules/@mui/system/esm/style.js","../../../node_modules/@mui/system/esm/memoize.js","../../../node_modules/@mui/system/esm/spacing.js","../../../node_modules/@mui/system/esm/createTheme/createSpacing.js","../../../node_modules/@mui/system/esm/compose.js","../../../node_modules/@mui/system/esm/borders.js","../../../node_modules/@mui/system/esm/cssGrid.js","../../../node_modules/@mui/system/esm/palette.js","../../../node_modules/@mui/system/esm/sizing.js","../../../node_modules/@mui/system/esm/styleFunctionSx/defaultSxConfig.js","../../../node_modules/@mui/system/esm/styleFunctionSx/styleFunctionSx.js","../../../node_modules/@mui/system/esm/createTheme/applyStyles.js","../../../node_modules/@mui/system/esm/createTheme/createTheme.js","../../../node_modules/@mui/system/esm/useThemeWithoutDefault.js","../../../node_modules/@mui/system/esm/useTheme.js","../../../node_modules/@mui/system/esm/createStyled.js","../../../node_modules/@mui/system/esm/useThemeProps/getThemeProps.js","../../../node_modules/@mui/system/esm/useThemeProps/useThemeProps.js","../../../node_modules/@mui/system/esm/colorManipulator.js","../../../node_modules/@mui/material/styles/createMixins.js","../../../node_modules/@mui/material/colors/common.js","../../../node_modules/@mui/material/colors/grey.js","../../../node_modules/@mui/material/colors/purple.js","../../../node_modules/@mui/material/colors/red.js","../../../node_modules/@mui/material/colors/orange.js","../../../node_modules/@mui/material/colors/blue.js","../../../node_modules/@mui/material/colors/lightBlue.js","../../../node_modules/@mui/material/colors/green.js","../../../node_modules/@mui/material/styles/createPalette.js","../../../node_modules/@mui/material/styles/createTypography.js","../../../node_modules/@mui/material/styles/shadows.js","../../../node_modules/@mui/material/styles/createTransitions.js","../../../node_modules/@mui/material/styles/zIndex.js","../../../node_modules/@mui/material/styles/createTheme.js","../../../node_modules/@mui/material/styles/defaultTheme.js","../../../node_modules/@mui/material/styles/identifier.js","../../../node_modules/@mui/material/styles/useThemeProps.js","../../../node_modules/@mui/material/styles/styled.js","../../../node_modules/@mui/material/SvgIcon/svgIconClasses.js","../../../node_modules/@mui/material/SvgIcon/SvgIcon.js","../../../node_modules/@mui/material/utils/createSvgIcon.js","../../../node_modules/@mui/material/utils/index.js","../../../node_modules/@mui/icons-material/utils/createSvgIcon.js","../../../node_modules/@mui/icons-material/ArrowRight.js","../../../node_modules/@mui/base/utils/isHostComponent.js","../../../node_modules/@mui/base/utils/appendOwnerState.js","../../../node_modules/@mui/base/utils/ClassNameConfigurator.js","../../../node_modules/@mui/base/utils/extractEventHandlers.js","../../../node_modules/@mui/base/utils/resolveComponentProps.js","../../../node_modules/@mui/base/utils/omitEventHandlers.js","../../../node_modules/@mui/base/utils/mergeSlotProps.js","../../../node_modules/@mui/base/utils/useSlotProps.js","../../../node_modules/@mui/base/generateUtilityClass/index.js","../../../node_modules/@mui/base/generateUtilityClasses/index.js","../../../node_modules/@mui/base/Portal/Portal.js","../../../node_modules/@popperjs/core/lib/enums.js","../../../node_modules/@popperjs/core/lib/dom-utils/getNodeName.js","../../../node_modules/@popperjs/core/lib/dom-utils/getWindow.js","../../../node_modules/@popperjs/core/lib/dom-utils/instanceOf.js","../../../node_modules/@popperjs/core/lib/modifiers/applyStyles.js","../../../node_modules/@popperjs/core/lib/utils/getBasePlacement.js","../../../node_modules/@popperjs/core/lib/utils/math.js","../../../node_modules/@popperjs/core/lib/utils/userAgent.js","../../../node_modules/@popperjs/core/lib/dom-utils/isLayoutViewport.js","../../../node_modules/@popperjs/core/lib/dom-utils/getBoundingClientRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/getLayoutRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/contains.js","../../../node_modules/@popperjs/core/lib/dom-utils/getComputedStyle.js","../../../node_modules/@popperjs/core/lib/dom-utils/isTableElement.js","../../../node_modules/@popperjs/core/lib/dom-utils/getDocumentElement.js","../../../node_modules/@popperjs/core/lib/dom-utils/getParentNode.js","../../../node_modules/@popperjs/core/lib/dom-utils/getOffsetParent.js","../../../node_modules/@popperjs/core/lib/utils/getMainAxisFromPlacement.js","../../../node_modules/@popperjs/core/lib/utils/within.js","../../../node_modules/@popperjs/core/lib/utils/getFreshSideObject.js","../../../node_modules/@popperjs/core/lib/utils/mergePaddingObject.js","../../../node_modules/@popperjs/core/lib/utils/expandToHashMap.js","../../../node_modules/@popperjs/core/lib/modifiers/arrow.js","../../../node_modules/@popperjs/core/lib/utils/getVariation.js","../../../node_modules/@popperjs/core/lib/modifiers/computeStyles.js","../../../node_modules/@popperjs/core/lib/modifiers/eventListeners.js","../../../node_modules/@popperjs/core/lib/utils/getOppositePlacement.js","../../../node_modules/@popperjs/core/lib/utils/getOppositeVariationPlacement.js","../../../node_modules/@popperjs/core/lib/dom-utils/getWindowScroll.js","../../../node_modules/@popperjs/core/lib/dom-utils/getWindowScrollBarX.js","../../../node_modules/@popperjs/core/lib/dom-utils/getViewportRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/getDocumentRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/isScrollParent.js","../../../node_modules/@popperjs/core/lib/dom-utils/getScrollParent.js","../../../node_modules/@popperjs/core/lib/dom-utils/listScrollParents.js","../../../node_modules/@popperjs/core/lib/utils/rectToClientRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/getClippingRect.js","../../../node_modules/@popperjs/core/lib/utils/computeOffsets.js","../../../node_modules/@popperjs/core/lib/utils/detectOverflow.js","../../../node_modules/@popperjs/core/lib/utils/computeAutoPlacement.js","../../../node_modules/@popperjs/core/lib/modifiers/flip.js","../../../node_modules/@popperjs/core/lib/modifiers/hide.js","../../../node_modules/@popperjs/core/lib/modifiers/offset.js","../../../node_modules/@popperjs/core/lib/modifiers/popperOffsets.js","../../../node_modules/@popperjs/core/lib/utils/getAltAxis.js","../../../node_modules/@popperjs/core/lib/modifiers/preventOverflow.js","../../../node_modules/@popperjs/core/lib/dom-utils/getHTMLElementScroll.js","../../../node_modules/@popperjs/core/lib/dom-utils/getNodeScroll.js","../../../node_modules/@popperjs/core/lib/dom-utils/getCompositeRect.js","../../../node_modules/@popperjs/core/lib/utils/orderModifiers.js","../../../node_modules/@popperjs/core/lib/utils/debounce.js","../../../node_modules/@popperjs/core/lib/utils/mergeByName.js","../../../node_modules/@popperjs/core/lib/createPopper.js","../../../node_modules/@popperjs/core/lib/popper.js","../../../node_modules/@mui/base/Popper/popperClasses.js","../../../node_modules/@mui/base/Popper/Popper.js","../../../node_modules/@mui/material/styles/useTheme.js","../../../node_modules/@babel/runtime/helpers/esm/setPrototypeOf.js","../../../node_modules/@babel/runtime/helpers/esm/inheritsLoose.js","../../../node_modules/react-transition-group/esm/config.js","../../../node_modules/react-transition-group/esm/utils/PropTypes.js","../../../node_modules/react-transition-group/esm/TransitionGroupContext.js","../../../node_modules/react-transition-group/esm/utils/reflow.js","../../../node_modules/react-transition-group/esm/Transition.js","../../../node_modules/@mui/material/transitions/utils.js","../../../node_modules/@mui/material/Grow/Grow.js","../../../node_modules/@mui/material/Popper/Popper.js","../../../node_modules/@mui/material/Tooltip/tooltipClasses.js","../../../node_modules/@mui/material/Tooltip/Tooltip.js","../src/components/mui/menu-item.component.tsx","../src/components/mui/grouped-menu-item-list.component.tsx","../src/components/mui/top-level-menu.component.tsx","../src/components/mui/grid-menu.component.tsx","../src/hooks/use-promise.hook.ts","../../../node_modules/@mui/icons-material/esm/Menu.js","../src/components/mui/hamburger-menu-button.component.tsx","../src/components/mui/icon-button.component.tsx","../src/components/basics/spinner.component.tsx","../src/components/basics/text-field.component.tsx","../src/components/mui/toolbar.component.tsx","../src/components/shadcn-ui/alert.tsx","../src/components/shadcn-ui/card.tsx","../src/components/shadcn-ui/sonner.tsx","../src/components/shadcn-ui/slider.tsx","../src/components/shadcn-ui/switch.tsx","../src/components/shadcn-ui/tabs.tsx","../src/components/advanced/extension-marketplace/buttons/install-button.component.tsx","../src/components/advanced/extension-marketplace/buttons/enable-button.component.tsx","../src/components/advanced/extension-marketplace/buttons/disable-button.component.tsx","../src/components/advanced/extension-marketplace/buttons/update-button.component.tsx","../src/components/advanced/extension-marketplace/markdown-renderer.component.tsx","../src/components/advanced/extension-marketplace/buttons/filter-button.component.tsx","../src/components/advanced/extension-marketplace/filter-dropdown.component.tsx","../src/components/advanced/extension-marketplace/no-extensions-found.component.tsx","../src/components/advanced/extension-marketplace/more-info.component.tsx","../src/components/advanced/extension-marketplace/version-history.component.tsx","../src/components/advanced/extension-marketplace/footer.component.tsx","../src/hooks/use-event.hook.ts","../src/hooks/use-event-async.hook.ts"],"sourcesContent":["import { type ClassValue, clsx } from 'clsx';\nimport { extendTailwindMerge } from 'tailwind-merge';\n\nconst twMergeCustom = extendTailwindMerge({ prefix: 'tw-' });\n\n/**\n * Tailwind and CSS class application helper function. Uses\n * [`clsx`](https://www.npmjs.com/package/clsx) to make it easy to apply classes conditionally using\n * object syntax, and uses [`tailwind-merge`](https://www.npmjs.com/package/tailwind-merge) to make\n * it easy to merge/overwrite Tailwind classes in a programmer-logic-friendly way.\n *\n * Note: `tailwind-merge` is configured to use the prefix `tw-`, so you must use the same prefix\n * with any Tailwind classes you use with this function to successfully overwrite other Tailwind\n * classes. `platform-bible-react` is configured to use `tw-` as its Tailwind prefix, so any\n * Tailwind classes you pass into `platform-bible-react` components will be compared using the `tw-`\n * prefix.\n *\n * This function was popularized by\n * [shadcn/ui](https://ui.shadcn.com/docs/installation/manual#add-a-cn-helper). See [ByteGrad's\n * explanation video](https://www.youtube.com/watch?v=re2JFITR7TI) for more information.\n *\n * @example\n *\n * ```typescript\n * const borderShouldBeBlue = true;\n * const textShouldBeRed = true;\n * const heightShouldBe20 = false;\n * const classString = cn(\n * 'tw-bg-primary tw-h-10 tw-text-primary-foreground',\n * 'tw-bg-secondary',\n * {\n * 'tw-border-blue-500': borderShouldBeBlue,\n * 'tw-text-red-500': textShouldBeRed,\n * 'tw-h-20': heightShouldBe20,\n * },\n * 'some-class',\n * );\n * ```\n *\n * The resulting `classString` is `'tw-h-10 tw-bg-secondary tw-border-blue-500 tw-text-red-500\n * some-class'`\n *\n * - Notice that `'tw-bg-secondary'`, specified later, overwrote `'tw-bg-primary'`, specified earlier,\n * because they are Tailwind classes that affect the same css property\n * - Notice that `'tw-text-red-500'`, specified later, overwrote `'tw-text-primary-foreground'`,\n * specified earlier, because they are Tailwind classes that affect the same css property\n * - Notice that `'tw-h-20'`, specified later, did not overwrite `'tw-h-10'`, specified earlier,\n * because `'tw-h-20'` is part of a conditional class object and its value evaluated to `false`;\n * therefore it was not applied\n * - Notice that `'some-class'` was applied. This function is not limited only to Tailwind classes.\n *\n *\n * @param inputs Class strings or `clsx` conditional class objects to merge. Tailwind classes\n * specified later in the arguments overwrite similar Tailwind classes specified earlier in the\n * arguments\n * @returns Class string containing all applicable classes from the arguments based on the rules\n * described above\n */\n// shadcn/ui uses this export in its boilerplate code\n// eslint-disable-next-line import/prefer-default-export\nexport function cn(...inputs: ClassValue[]) {\n return twMergeCustom(clsx(inputs));\n}\n","import React from 'react';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport interface InputProps extends React.InputHTMLAttributes {}\n\nexport const Input = React.forwardRef(\n ({ className, type, ...props }, ref) => {\n return (\n \n );\n },\n);\nInput.displayName = 'Input';\n","import { FocusEventHandler, forwardRef, KeyboardEvent, MouseEventHandler } from 'react';\nimport { History } from 'lucide-react';\nimport { Input as ShadInput } from '@/components/shadcn-ui/input';\n\nexport type BookChapterInputProps = {\n handleSearch: (searchString: string) => void;\n handleKeyDown: (event: KeyboardEvent) => void;\n handleOnClick: MouseEventHandler;\n handleSubmit: () => void;\n onFocus?: FocusEventHandler;\n value: string;\n placeholder: string;\n};\n\n// Shadcn Input sets type to \"button\"- HAVE to prop spread before setting type\nconst BookChapterInput = forwardRef(\n (\n { handleSearch, handleKeyDown, handleOnClick, handleSubmit, ...props }: BookChapterInputProps,\n ref,\n ) => {\n return (\n
    \n handleSearch(event.target.value)}\n onKeyDown={(e) => {\n if (e.key === 'Enter') {\n handleSubmit();\n }\n handleKeyDown(e);\n }}\n onClick={handleOnClick}\n ref={ref}\n />\n {\n // eslint-disable-next-line no-console\n console.log('back in history');\n }}\n />\n
    \n );\n },\n);\n\nexport default BookChapterInput;\n","var P = Object.defineProperty;\nvar R = (t, e, s) => e in t ? P(t, e, { enumerable: !0, configurable: !0, writable: !0, value: s }) : t[e] = s;\nvar n = (t, e, s) => R(t, typeof e != \"symbol\" ? e + \"\" : e, s);\nclass _ {\n constructor() {\n n(this, \"books\");\n n(this, \"firstSelectedBookNum\");\n n(this, \"lastSelectedBookNum\");\n n(this, \"count\");\n n(this, \"selectedBookNumbers\");\n n(this, \"selectedBookIds\");\n }\n}\nconst N = [\n \"GEN\",\n \"EXO\",\n \"LEV\",\n \"NUM\",\n \"DEU\",\n \"JOS\",\n \"JDG\",\n \"RUT\",\n \"1SA\",\n \"2SA\",\n // 10\n \"1KI\",\n \"2KI\",\n \"1CH\",\n \"2CH\",\n \"EZR\",\n \"NEH\",\n \"EST\",\n \"JOB\",\n \"PSA\",\n \"PRO\",\n // 20\n \"ECC\",\n \"SNG\",\n \"ISA\",\n \"JER\",\n \"LAM\",\n \"EZK\",\n \"DAN\",\n \"HOS\",\n \"JOL\",\n \"AMO\",\n // 30\n \"OBA\",\n \"JON\",\n \"MIC\",\n \"NAM\",\n \"HAB\",\n \"ZEP\",\n \"HAG\",\n \"ZEC\",\n \"MAL\",\n \"MAT\",\n // 40\n \"MRK\",\n \"LUK\",\n \"JHN\",\n \"ACT\",\n \"ROM\",\n \"1CO\",\n \"2CO\",\n \"GAL\",\n \"EPH\",\n \"PHP\",\n // 50\n \"COL\",\n \"1TH\",\n \"2TH\",\n \"1TI\",\n \"2TI\",\n \"TIT\",\n \"PHM\",\n \"HEB\",\n \"JAS\",\n \"1PE\",\n // 60\n \"2PE\",\n \"1JN\",\n \"2JN\",\n \"3JN\",\n \"JUD\",\n \"REV\",\n \"TOB\",\n \"JDT\",\n \"ESG\",\n \"WIS\",\n // 70\n \"SIR\",\n \"BAR\",\n \"LJE\",\n \"S3Y\",\n \"SUS\",\n \"BEL\",\n \"1MA\",\n \"2MA\",\n \"3MA\",\n \"4MA\",\n // 80\n \"1ES\",\n \"2ES\",\n \"MAN\",\n \"PS2\",\n \"ODA\",\n \"PSS\",\n \"JSA\",\n // actual variant text for JOS, now in LXA text\n \"JDB\",\n // actual variant text for JDG, now in LXA text\n \"TBS\",\n // actual variant text for TOB, now in LXA text\n \"SST\",\n // actual variant text for SUS, now in LXA text // 90\n \"DNT\",\n // actual variant text for DAN, now in LXA text\n \"BLT\",\n // actual variant text for BEL, now in LXA text\n \"XXA\",\n \"XXB\",\n \"XXC\",\n \"XXD\",\n \"XXE\",\n \"XXF\",\n \"XXG\",\n \"FRT\",\n // 100\n \"BAK\",\n \"OTH\",\n \"3ES\",\n // Used previously but really should be 2ES\n \"EZA\",\n // Used to be called 4ES, but not actually in any known project\n \"5EZ\",\n // Used to be called 5ES, but not actually in any known project\n \"6EZ\",\n // Used to be called 6ES, but not actually in any known project\n \"INT\",\n \"CNC\",\n \"GLO\",\n \"TDX\",\n // 110\n \"NDX\",\n \"DAG\",\n \"PS3\",\n \"2BA\",\n \"LBA\",\n \"JUB\",\n \"ENO\",\n \"1MQ\",\n \"2MQ\",\n \"3MQ\",\n // 120\n \"REP\",\n \"4BA\",\n \"LAO\"\n], B = [\n \"XXA\",\n \"XXB\",\n \"XXC\",\n \"XXD\",\n \"XXE\",\n \"XXF\",\n \"XXG\",\n \"FRT\",\n \"BAK\",\n \"OTH\",\n \"INT\",\n \"CNC\",\n \"GLO\",\n \"TDX\",\n \"NDX\"\n], O = [\n \"Genesis\",\n \"Exodus\",\n \"Leviticus\",\n \"Numbers\",\n \"Deuteronomy\",\n \"Joshua\",\n \"Judges\",\n \"Ruth\",\n \"1 Samuel\",\n \"2 Samuel\",\n \"1 Kings\",\n \"2 Kings\",\n \"1 Chronicles\",\n \"2 Chronicles\",\n \"Ezra\",\n \"Nehemiah\",\n \"Esther (Hebrew)\",\n \"Job\",\n \"Psalms\",\n \"Proverbs\",\n \"Ecclesiastes\",\n \"Song of Songs\",\n \"Isaiah\",\n \"Jeremiah\",\n \"Lamentations\",\n \"Ezekiel\",\n \"Daniel (Hebrew)\",\n \"Hosea\",\n \"Joel\",\n \"Amos\",\n \"Obadiah\",\n \"Jonah\",\n \"Micah\",\n \"Nahum\",\n \"Habakkuk\",\n \"Zephaniah\",\n \"Haggai\",\n \"Zechariah\",\n \"Malachi\",\n \"Matthew\",\n \"Mark\",\n \"Luke\",\n \"John\",\n \"Acts\",\n \"Romans\",\n \"1 Corinthians\",\n \"2 Corinthians\",\n \"Galatians\",\n \"Ephesians\",\n \"Philippians\",\n \"Colossians\",\n \"1 Thessalonians\",\n \"2 Thessalonians\",\n \"1 Timothy\",\n \"2 Timothy\",\n \"Titus\",\n \"Philemon\",\n \"Hebrews\",\n \"James\",\n \"1 Peter\",\n \"2 Peter\",\n \"1 John\",\n \"2 John\",\n \"3 John\",\n \"Jude\",\n \"Revelation\",\n \"Tobit\",\n \"Judith\",\n \"Esther Greek\",\n \"Wisdom of Solomon\",\n \"Sirach (Ecclesiasticus)\",\n \"Baruch\",\n \"Letter of Jeremiah\",\n \"Song of 3 Young Men\",\n \"Susanna\",\n \"Bel and the Dragon\",\n \"1 Maccabees\",\n \"2 Maccabees\",\n \"3 Maccabees\",\n \"4 Maccabees\",\n \"1 Esdras (Greek)\",\n \"2 Esdras (Latin)\",\n \"Prayer of Manasseh\",\n \"Psalm 151\",\n \"Odes\",\n \"Psalms of Solomon\",\n // WARNING, if you change the spelling of the *obsolete* tag be sure to update\n // IsObsolete routine\n \"Joshua A. *obsolete*\",\n \"Judges B. *obsolete*\",\n \"Tobit S. *obsolete*\",\n \"Susanna Th. *obsolete*\",\n \"Daniel Th. *obsolete*\",\n \"Bel Th. *obsolete*\",\n \"Extra A\",\n \"Extra B\",\n \"Extra C\",\n \"Extra D\",\n \"Extra E\",\n \"Extra F\",\n \"Extra G\",\n \"Front Matter\",\n \"Back Matter\",\n \"Other Matter\",\n \"3 Ezra *obsolete*\",\n \"Apocalypse of Ezra\",\n \"5 Ezra (Latin Prologue)\",\n \"6 Ezra (Latin Epilogue)\",\n \"Introduction\",\n \"Concordance \",\n \"Glossary \",\n \"Topical Index\",\n \"Names Index\",\n \"Daniel Greek\",\n \"Psalms 152-155\",\n \"2 Baruch (Apocalypse)\",\n \"Letter of Baruch\",\n \"Jubilees\",\n \"Enoch\",\n \"1 Meqabyan\",\n \"2 Meqabyan\",\n \"3 Meqabyan\",\n \"Reproof (Proverbs 25-31)\",\n \"4 Baruch (Rest of Baruch)\",\n \"Laodiceans\"\n], S = K();\nfunction g(t, e = !0) {\n return e && (t = t.toUpperCase()), t in S ? S[t] : 0;\n}\nfunction k(t) {\n return g(t) > 0;\n}\nfunction x(t) {\n const e = typeof t == \"string\" ? g(t) : t;\n return e >= 40 && e <= 66;\n}\nfunction T(t) {\n return (typeof t == \"string\" ? g(t) : t) <= 39;\n}\nfunction X(t) {\n return t <= 66;\n}\nfunction V(t) {\n const e = typeof t == \"string\" ? g(t) : t;\n return w(e) && !X(e);\n}\nfunction* L() {\n for (let t = 1; t <= N.length; t++) yield t;\n}\nconst G = 1, A = N.length;\nfunction H() {\n return [\"XXA\", \"XXB\", \"XXC\", \"XXD\", \"XXE\", \"XXF\", \"XXG\"];\n}\nfunction C(t, e = \"***\") {\n const s = t - 1;\n return s < 0 || s >= N.length ? e : N[s];\n}\nfunction I(t) {\n return t <= 0 || t > A ? \"******\" : O[t - 1];\n}\nfunction y(t) {\n return I(g(t));\n}\nfunction w(t) {\n const e = typeof t == \"number\" ? C(t) : t;\n return k(e) && !B.includes(e);\n}\nfunction q(t) {\n const e = typeof t == \"number\" ? C(t) : t;\n return k(e) && B.includes(e);\n}\nfunction U(t) {\n return O[t - 1].includes(\"*obsolete*\");\n}\nfunction K() {\n const t = {};\n for (let e = 0; e < N.length; e++)\n t[N[e]] = e + 1;\n return t;\n}\nconst m = {\n allBookIds: N,\n nonCanonicalIds: B,\n bookIdToNumber: g,\n isBookIdValid: k,\n isBookNT: x,\n isBookOT: T,\n isBookOTNT: X,\n isBookDC: V,\n allBookNumbers: L,\n firstBook: G,\n lastBook: A,\n extraBooks: H,\n bookNumberToId: C,\n bookNumberToEnglishName: I,\n bookIdToEnglishName: y,\n isCanonical: w,\n isExtraMaterial: q,\n isObsolete: U\n};\nvar l = /* @__PURE__ */ ((t) => (t[t.Unknown = 0] = \"Unknown\", t[t.Original = 1] = \"Original\", t[t.Septuagint = 2] = \"Septuagint\", t[t.Vulgate = 3] = \"Vulgate\", t[t.English = 4] = \"English\", t[t.RussianProtestant = 5] = \"RussianProtestant\", t[t.RussianOrthodox = 6] = \"RussianOrthodox\", t))(l || {});\nconst h = class h {\n // private versInfo: Versification;\n constructor(e) {\n n(this, \"name\");\n n(this, \"fullPath\");\n n(this, \"isPresent\");\n n(this, \"hasVerseSegments\");\n n(this, \"isCustomized\");\n n(this, \"baseVersification\");\n n(this, \"scriptureBooks\");\n n(this, \"_type\");\n if (e == null)\n throw new Error(\"Argument undefined\");\n typeof e == \"string\" ? (this.name = e, this._type = l[e]) : (this._type = e, this.name = l[e]);\n }\n get type() {\n return this._type;\n }\n equals(e) {\n return !e.type || !this.type ? !1 : e.type === this.type;\n }\n};\nn(h, \"Original\", new h(l.Original)), n(h, \"Septuagint\", new h(l.Septuagint)), n(h, \"Vulgate\", new h(l.Vulgate)), n(h, \"English\", new h(l.English)), n(h, \"RussianProtestant\", new h(l.RussianProtestant)), n(h, \"RussianOrthodox\", new h(l.RussianOrthodox));\nlet c = h;\nfunction E(t, e) {\n const s = e[0];\n for (let r = 1; r < e.length; r++)\n t = t.split(e[r]).join(s);\n return t.split(s);\n}\nvar D = /* @__PURE__ */ ((t) => (t[t.Valid = 0] = \"Valid\", t[t.UnknownVersification = 1] = \"UnknownVersification\", t[t.OutOfRange = 2] = \"OutOfRange\", t[t.VerseOutOfOrder = 3] = \"VerseOutOfOrder\", t[t.VerseRepeated = 4] = \"VerseRepeated\", t))(D || {});\nconst i = class i {\n constructor(e, s, r, a) {\n /** Not yet implemented. */\n n(this, \"firstChapter\");\n /** Not yet implemented. */\n n(this, \"lastChapter\");\n /** Not yet implemented. */\n n(this, \"lastVerse\");\n /** Not yet implemented. */\n n(this, \"hasSegmentsDefined\");\n /** Not yet implemented. */\n n(this, \"text\");\n /** Not yet implemented. */\n n(this, \"BBBCCCVVVS\");\n /** Not yet implemented. */\n n(this, \"longHashCode\");\n /** The versification of the reference. */\n n(this, \"versification\");\n n(this, \"rtlMark\", \"‏\");\n n(this, \"_bookNum\", 0);\n n(this, \"_chapterNum\", 0);\n n(this, \"_verseNum\", 0);\n n(this, \"_verse\");\n if (r == null && a == null)\n if (e != null && typeof e == \"string\") {\n const o = e, u = s != null && s instanceof c ? s : void 0;\n this.setEmpty(u), this.parse(o);\n } else if (e != null && typeof e == \"number\") {\n const o = s != null && s instanceof c ? s : void 0;\n this.setEmpty(o), this._verseNum = e % i.chapterDigitShifter, this._chapterNum = Math.floor(\n e % i.bookDigitShifter / i.chapterDigitShifter\n ), this._bookNum = Math.floor(e / i.bookDigitShifter);\n } else if (s == null)\n if (e != null && e instanceof i) {\n const o = e;\n this._bookNum = o.bookNum, this._chapterNum = o.chapterNum, this._verseNum = o.verseNum, this._verse = o.verse, this.versification = o.versification;\n } else {\n if (e == null) return;\n const o = e instanceof c ? e : i.defaultVersification;\n this.setEmpty(o);\n }\n else\n throw new Error(\"VerseRef constructor not supported.\");\n else if (e != null && s != null && r != null)\n if (typeof e == \"string\" && typeof s == \"string\" && typeof r == \"string\")\n this.setEmpty(a), this.updateInternal(e, s, r);\n else if (typeof e == \"number\" && typeof s == \"number\" && typeof r == \"number\")\n this._bookNum = e, this._chapterNum = s, this._verseNum = r, this.versification = a ?? i.defaultVersification;\n else\n throw new Error(\"VerseRef constructor not supported.\");\n else\n throw new Error(\"VerseRef constructor not supported.\");\n }\n /**\n * Determines if the verse string is in a valid format (does not consider versification).\n */\n static isVerseParseable(e) {\n return e.length > 0 && \"0123456789\".includes(e[0]) && !e.endsWith(this.verseRangeSeparator) && !e.endsWith(this.verseSequenceIndicator);\n }\n /**\n * Tries to parse the specified string into a verse reference.\n * @param str - The string to attempt to parse.\n * @returns success: `true` if the specified string was successfully parsed, `false` otherwise.\n * @returns verseRef: The result of the parse if successful, or empty VerseRef if it failed\n */\n static tryParse(e) {\n let s;\n try {\n return s = new i(e), { success: !0, verseRef: s };\n } catch (r) {\n if (r instanceof v)\n return s = new i(), { success: !1, verseRef: s };\n throw r;\n }\n }\n /**\n * Gets the reference as a comparable integer where the book, chapter, and verse each occupy 3\n * digits.\n * @param bookNum - Book number (this is 1-based, not an index).\n * @param chapterNum - Chapter number.\n * @param verseNum - Verse number.\n * @returns The reference as a comparable integer where the book, chapter, and verse each occupy 3\n * digits.\n */\n static getBBBCCCVVV(e, s, r) {\n return e % i.bcvMaxValue * i.bookDigitShifter + (s >= 0 ? s % i.bcvMaxValue * i.chapterDigitShifter : 0) + (r >= 0 ? r % i.bcvMaxValue : 0);\n }\n /**\n * Deserializes a serialized VerseRef.\n * @param serializedVerseRef - Serialized VerseRef to create from.\n * @returns the deserialized VerseRef.\n */\n static fromJSON(e) {\n const { book: s, chapterNum: r, verseNum: a, verse: o, versificationStr: u } = e, f = o || a.toString();\n let d;\n return u && (d = new c(u)), s ? new i(s, r.toString(), f, d) : new i();\n }\n /**\n * Parses a verse string and gets the leading numeric portion as a number.\n * @param verseStr - verse string to parse\n * @returns true if the entire string could be parsed as a single, simple verse number (1-999);\n * false if the verse string represented a verse bridge, contained segment letters, or was invalid\n */\n static tryGetVerseNum(e) {\n let s;\n if (!e)\n return s = -1, { success: !0, vNum: s };\n s = 0;\n let r;\n for (let a = 0; a < e.length; a++) {\n if (r = e[a], r < \"0\" || r > \"9\")\n return a === 0 && (s = -1), { success: !1, vNum: s };\n if (s = s * 10 + +r - 0, s > i.bcvMaxValue)\n return s = -1, { success: !1, vNum: s };\n }\n return { success: !0, vNum: s };\n }\n /**\n * Checks to see if a VerseRef hasn't been set - all values are the default.\n */\n get isDefault() {\n return this.bookNum === 0 && this.chapterNum === 0 && this.verseNum === 0 && this.versification == null;\n }\n /**\n * Gets whether the verse contains multiple verses.\n */\n get hasMultiple() {\n return this._verse != null && (this._verse.includes(i.verseRangeSeparator) || this._verse.includes(i.verseSequenceIndicator));\n }\n /**\n * Gets or sets the book of the reference. Book is the 3-letter abbreviation in capital letters,\n * e.g. `'MAT'`.\n */\n get book() {\n return m.bookNumberToId(this.bookNum, \"\");\n }\n set book(e) {\n this.bookNum = m.bookIdToNumber(e);\n }\n /**\n * Gets or sets the chapter of the reference,. e.g. `'3'`.\n */\n get chapter() {\n return this.isDefault || this._chapterNum < 0 ? \"\" : this._chapterNum.toString();\n }\n set chapter(e) {\n const s = +e;\n this._chapterNum = Number.isInteger(s) ? s : -1;\n }\n /**\n * Gets or sets the verse of the reference, including range, segments, and sequences, e.g. `'4'`,\n * or `'4b-5a, 7'`.\n */\n get verse() {\n return this._verse != null ? this._verse : this.isDefault || this._verseNum < 0 ? \"\" : this._verseNum.toString();\n }\n set verse(e) {\n const { success: s, vNum: r } = i.tryGetVerseNum(e);\n this._verse = s ? void 0 : e.replace(this.rtlMark, \"\"), this._verseNum = r, !(this._verseNum >= 0) && ({ vNum: this._verseNum } = i.tryGetVerseNum(this._verse));\n }\n /**\n * Get or set Book based on book number, e.g. `42`.\n */\n get bookNum() {\n return this._bookNum;\n }\n set bookNum(e) {\n if (e <= 0 || e > m.lastBook)\n throw new v(\n \"BookNum must be greater than zero and less than or equal to last book\"\n );\n this._bookNum = e;\n }\n /**\n * Gets or sets the chapter number, e.g. `3`. `-1` if not valid.\n */\n get chapterNum() {\n return this._chapterNum;\n }\n set chapterNum(e) {\n this.chapterNum = e;\n }\n /**\n * Gets or sets verse start number, e.g. `4`. `-1` if not valid.\n */\n get verseNum() {\n return this._verseNum;\n }\n set verseNum(e) {\n this._verseNum = e;\n }\n /**\n * String representing the versification (should ONLY be used for serialization/deserialization).\n *\n * @remarks This is for backwards compatibility when ScrVers was an enumeration.\n */\n get versificationStr() {\n var e;\n return (e = this.versification) == null ? void 0 : e.name;\n }\n set versificationStr(e) {\n this.versification = this.versification != null ? new c(e) : void 0;\n }\n /**\n * Determines if the reference is valid.\n */\n get valid() {\n return this.validStatus === 0;\n }\n /**\n * Get the valid status for this reference.\n */\n get validStatus() {\n return this.validateVerse(i.verseRangeSeparators, i.verseSequenceIndicators);\n }\n /**\n * Gets the reference as a comparable integer where the book,\n * chapter, and verse each occupy three digits and the verse is 0.\n */\n get BBBCCC() {\n return i.getBBBCCCVVV(this._bookNum, this._chapterNum, 0);\n }\n /**\n * Gets the reference as a comparable integer where the book,\n * chapter, and verse each occupy three digits. If verse is not null\n * (i.e., this reference represents a complex reference with verse\n * segments or bridge) this cannot be used for an exact comparison.\n */\n get BBBCCCVVV() {\n return i.getBBBCCCVVV(this._bookNum, this._chapterNum, this._verseNum);\n }\n /**\n * Gets whether the verse is defined as an excluded verse in the versification.\n * Does not handle verse ranges.\n */\n // eslint-disable-next-line @typescript-eslint/class-literal-property-style\n get isExcluded() {\n return !1;\n }\n /**\n * Parses the reference in the specified string.\n * Optionally versification can follow reference as in GEN 3:11/4\n * Throw an exception if\n * - invalid book name\n * - chapter number is missing or not a number\n * - verse number is missing or does not start with a number\n * - versification is invalid\n * @param verseStr - string to parse e.g. 'MAT 3:11'\n */\n parse(e) {\n if (e = e.replace(this.rtlMark, \"\"), e.includes(\"/\")) {\n const o = e.split(\"/\");\n if (e = o[0], o.length > 1)\n try {\n const u = +o[1].trim();\n this.versification = new c(l[u]);\n } catch {\n throw new v(\"Invalid reference : \" + e);\n }\n }\n const s = e.trim().split(\" \");\n if (s.length !== 2)\n throw new v(\"Invalid reference : \" + e);\n const r = s[1].split(\":\"), a = +r[0];\n if (r.length !== 2 || m.bookIdToNumber(s[0]) === 0 || !Number.isInteger(a) || a < 0 || !i.isVerseParseable(r[1]))\n throw new v(\"Invalid reference : \" + e);\n this.updateInternal(s[0], r[0], r[1]);\n }\n /**\n * Simplifies this verse ref so that it has no bridging of verses or\n * verse segments like `'1a'`.\n */\n simplify() {\n this._verse = void 0;\n }\n /**\n * Makes a clone of the reference.\n *\n * @returns The cloned VerseRef.\n */\n clone() {\n return new i(this);\n }\n toString() {\n const e = this.book;\n return e === \"\" ? \"\" : `${e} ${this.chapter}:${this.verse}`;\n }\n toJSON() {\n let e = this.verse;\n (e === \"\" || e === this.verseNum.toString()) && (e = void 0);\n const s = {\n book: this.book,\n chapterNum: this.chapterNum,\n verseNum: this.verseNum,\n verse: e,\n versificationStr: this.versificationStr\n };\n return e || delete s.verse, s;\n }\n /**\n * Compares this `VerseRef` with supplied one.\n * @param verseRef - object to compare this one to.\n * @returns `true` if this `VerseRef` is equal to the supplied one, `false` otherwise.\n */\n equals(e) {\n return e instanceof i ? e._bookNum === this._bookNum && e._chapterNum === this._chapterNum && e._verseNum === this._verseNum && e.verse === this.verse && (e.versification == null && this.versification == null || e.versification != null && this.versification != null && e.versification.equals(this.versification)) : !1;\n }\n /**\n * Enumerate all individual verses contained in a VerseRef.\n * Verse ranges are indicated by \"-\" and consecutive verses by \",\"s.\n * Examples:\n * GEN 1:2 returns GEN 1:2\n * GEN 1:1a-3b,5 returns GEN 1:1a, GEN 1:2, GEN 1:3b, GEN 1:5\n * GEN 1:2a-2c returns //! ??????\n *\n * @param specifiedVersesOnly - if set to true return only verses that are\n * explicitly specified only, not verses within a range. Defaults to `false`.\n * @param verseRangeSeparators - Verse range separators.\n * Defaults to `VerseRef.verseRangeSeparators`.\n * @param verseSequenceSeparators - Verse sequence separators.\n * Defaults to `VerseRef.verseSequenceIndicators`.\n * @returns An array of all single verse references in this VerseRef.\n */\n allVerses(e = !1, s = i.verseRangeSeparators, r = i.verseSequenceIndicators) {\n if (this._verse == null || this.chapterNum <= 0)\n return [this.clone()];\n const a = [], o = E(this._verse, r);\n for (const u of o.map((f) => E(f, s))) {\n const f = this.clone();\n f.verse = u[0];\n const d = f.verseNum;\n if (a.push(f), u.length > 1) {\n const b = this.clone();\n if (b.verse = u[1], !e)\n for (let p = d + 1; p < b.verseNum; p++) {\n const J = new i(\n this._bookNum,\n this._chapterNum,\n p,\n this.versification\n );\n this.isExcluded || a.push(J);\n }\n a.push(b);\n }\n }\n return a;\n }\n /**\n * Validates a verse number using the supplied separators rather than the defaults.\n */\n validateVerse(e, s) {\n if (!this.verse)\n return this.internalValid;\n let r = 0;\n for (const a of this.allVerses(!0, e, s)) {\n const o = a.internalValid;\n if (o !== 0)\n return o;\n const u = a.BBBCCCVVV;\n if (r > u)\n return 3;\n if (r === u)\n return 4;\n r = u;\n }\n return 0;\n }\n /**\n * Gets whether a single verse reference is valid.\n */\n get internalValid() {\n return this.versification == null ? 1 : this._bookNum <= 0 || this._bookNum > m.lastBook ? 2 : (m.isCanonical(this._bookNum), 0);\n }\n setEmpty(e = i.defaultVersification) {\n this._bookNum = 0, this._chapterNum = -1, this._verse = void 0, this.versification = e;\n }\n updateInternal(e, s, r) {\n this.bookNum = m.bookIdToNumber(e), this.chapter = s, this.verse = r;\n }\n};\nn(i, \"defaultVersification\", c.English), n(i, \"verseRangeSeparator\", \"-\"), n(i, \"verseSequenceIndicator\", \",\"), n(i, \"verseRangeSeparators\", [i.verseRangeSeparator]), n(i, \"verseSequenceIndicators\", [i.verseSequenceIndicator]), n(i, \"chapterDigitShifter\", 1e3), n(i, \"bookDigitShifter\", i.chapterDigitShifter * i.chapterDigitShifter), n(i, \"bcvMaxValue\", i.chapterDigitShifter - 1), /**\n * The valid status of the VerseRef.\n */\nn(i, \"ValidStatusType\", D);\nlet M = i;\nclass v extends Error {\n}\nexport {\n _ as BookSet,\n m as Canon,\n c as ScrVers,\n l as ScrVersType,\n M as VerseRef,\n v as VerseRefException\n};\n//# sourceMappingURL=index.es.js.map\n","import React from 'react';\nimport * as DropdownMenuPrimitive from '@radix-ui/react-dropdown-menu';\nimport { Check, ChevronRight, Circle } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport const DropdownMenu = DropdownMenuPrimitive.Root;\n\nexport const DropdownMenuTrigger = DropdownMenuPrimitive.Trigger;\n\nexport const DropdownMenuGroup = DropdownMenuPrimitive.Group;\n\nexport const DropdownMenuPortal = DropdownMenuPrimitive.Portal;\n\nexport const DropdownMenuSub = DropdownMenuPrimitive.Sub;\n\nexport const DropdownMenuRadioGroup = DropdownMenuPrimitive.RadioGroup;\n\nexport type DropdownMenuSubTriggerProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.SubTrigger\n> & {\n className?: string;\n inset?: boolean;\n};\n\nexport type DropdownMenuSubContentProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.SubContent\n> & {\n className?: string;\n};\n\nexport type DropdownMenuContentProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Content\n> & {\n className?: string;\n sideOffset?: number;\n};\n\nexport type DropdownMenuItemProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Item\n> & {\n className?: string;\n inset?: boolean;\n};\n\nexport type DropdownMenuCheckboxItemProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.CheckboxItem\n> & {\n className?: string;\n checked?: boolean;\n};\n\nexport type DropdownMenuRadioItemProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.RadioItem\n> & {\n className?: string;\n};\n\nexport type DropdownMenuLabelProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Label\n> & {\n className?: string;\n inset?: boolean;\n};\n\nexport type DropdownMenuSeparatorProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Separator\n> & {\n className?: string;\n};\n\nexport type DropdownMenuShortcutProps = React.HTMLAttributes & {\n className?: string;\n};\n\nexport const DropdownMenuSubTrigger = React.forwardRef<\n React.ElementRef,\n DropdownMenuSubTriggerProps\n>(({ className, inset, children, ...props }, ref) => (\n \n {children}\n \n \n));\nDropdownMenuSubTrigger.displayName = DropdownMenuPrimitive.SubTrigger.displayName;\n\nexport const DropdownMenuSubContent = React.forwardRef<\n React.ElementRef,\n DropdownMenuSubContentProps\n>(({ className, ...props }, ref) => (\n \n));\nDropdownMenuSubContent.displayName = DropdownMenuPrimitive.SubContent.displayName;\n\nexport const DropdownMenuContent = React.forwardRef<\n React.ElementRef,\n DropdownMenuContentProps\n>(({ className, sideOffset = 4, ...props }, ref) => (\n \n \n \n));\nDropdownMenuContent.displayName = DropdownMenuPrimitive.Content.displayName;\n\n/**\n * TODO: fix: direction is not automatically handled by this component, so that shortcuts are\n * display always to the right\n */\nexport const DropdownMenuItem = React.forwardRef<\n React.ElementRef,\n DropdownMenuItemProps\n>(({ className, inset, ...props }, ref) => (\n \n));\nDropdownMenuItem.displayName = DropdownMenuPrimitive.Item.displayName;\n\nexport const DropdownMenuCheckboxItem = React.forwardRef<\n React.ElementRef,\n DropdownMenuCheckboxItemProps\n>(({ className, children, checked, ...props }, ref) => (\n \n \n \n \n \n \n {children}\n \n));\nDropdownMenuCheckboxItem.displayName = DropdownMenuPrimitive.CheckboxItem.displayName;\n\nexport const DropdownMenuRadioItem = React.forwardRef<\n React.ElementRef,\n DropdownMenuRadioItemProps\n>(({ className, children, ...props }, ref) => (\n \n \n \n \n \n \n {children}\n \n));\nDropdownMenuRadioItem.displayName = DropdownMenuPrimitive.RadioItem.displayName;\n\nexport const DropdownMenuLabel = React.forwardRef<\n React.ElementRef,\n DropdownMenuLabelProps\n>(({ className, inset, ...props }, ref) => (\n \n));\nDropdownMenuLabel.displayName = DropdownMenuPrimitive.Label.displayName;\n\nexport const DropdownMenuSeparator = React.forwardRef<\n React.ElementRef,\n DropdownMenuSeparatorProps\n>(({ className, ...props }, ref) => (\n \n));\nDropdownMenuSeparator.displayName = DropdownMenuPrimitive.Separator.displayName;\n\nexport function DropdownMenuShortcut({ className, ...props }: DropdownMenuShortcutProps) {\n return (\n \n );\n}\nDropdownMenuShortcut.displayName = 'DropdownMenuShortcut';\n","import { Canon } from '@sillsdev/scripture';\nimport { PropsWithChildren, KeyboardEvent, forwardRef } from 'react';\nimport { DropdownMenuItem as ShadDropdownMenuItem } from '@/components/shadcn-ui/dropdown-menu';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport type BookType = 'OT' | 'NT' | 'DC';\n\ntype BookMenuItemProps = PropsWithChildren<{\n /** String id of book */\n bookId: string;\n /** Callback to run when a book menu item is selected */\n handleSelectBook: () => void;\n /** Indicates if this menu item is currently selected */\n isSelected: boolean;\n /** Function that is called upon highlighting a book in the dropdown menu */\n handleHighlightBook: () => void;\n /**\n * Function that is called on pressing a key\n *\n * @param event Event that contains information about the key stroke\n */\n handleKeyDown: (event: KeyboardEvent) => void;\n /**\n * Type of book associated with this menu item, coordinates color labels ? Mock up has the labels\n * coordinated to genre\n */\n bookType: BookType;\n}>;\n\nconst BookMenuItem = forwardRef(\n (\n {\n bookId,\n handleSelectBook,\n isSelected,\n handleHighlightBook,\n handleKeyDown,\n bookType,\n children,\n }: BookMenuItemProps,\n ref,\n ) => {\n return (\n {\n // preventDefault() here prevents the entire dropdown menu from closing when selecting this item\n event.preventDefault();\n handleSelectBook();\n }}\n onKeyDown={(event: KeyboardEvent) => {\n handleKeyDown(event);\n }}\n onFocus={handleHighlightBook}\n onMouseMove={handleHighlightBook}\n >\n \n {Canon.bookIdToEnglishName(bookId)}\n \n {isSelected &&
    {children}
    }\n \n );\n },\n);\n\nexport default BookMenuItem;\n","import { cn } from '@/utils/shadcn-ui.util';\nimport { useCallback } from 'react';\n\nexport type ChapterSelectProps = {\n /**\n * Callback to run when a chapter div is selected\n *\n * @param chapterNumber Number of the chapter that has been selected\n */\n handleSelectChapter: (chapterNumber: number) => void;\n /** The highest chapter number in the book (of course equal to number of chapters in the book) */\n endChapter: number;\n /** The chapter number that is currently selected */\n activeChapter: number;\n /** The chapter number that is currently highlighted using keyboard or mouse navigation */\n highlightedChapter: number;\n /**\n * Callback to run when a chapter is highlighted by the user\n *\n * @param chapterNumber The chapter that is highlighted\n */\n handleHighlightedChapter: (chapterNumber: number) => void;\n};\n\nfunction ChapterSelect({\n handleSelectChapter,\n endChapter,\n activeChapter,\n highlightedChapter,\n handleHighlightedChapter,\n}: ChapterSelectProps) {\n const chapters = Array.from({ length: endChapter }, (_, i) => i + 1);\n\n const handleMouse = useCallback(\n (chapterNumber: number) => {\n handleHighlightedChapter(chapterNumber);\n },\n [handleHighlightedChapter],\n );\n\n return (\n
    \n {chapters.map((chapter) => (\n {\n event.preventDefault();\n event.stopPropagation();\n handleSelectChapter(chapter);\n }}\n role=\"button\"\n onKeyDown={(event) => {\n if (event.key === 'Enter') {\n handleSelectChapter(chapter);\n }\n }}\n tabIndex={0}\n onMouseMove={() => handleMouse(chapter)}\n >\n {chapter}\n
    \n ))}\n
    \n );\n}\n\nexport default ChapterSelect;\n","import { DropdownMenuLabel as ShadDropdownMenuLabel } from '@/components/shadcn-ui/dropdown-menu';\nimport { Bookmark, Clock, ArrowDownWideNarrow } from 'lucide-react';\n\nexport type GoToMenuItemProps = {\n handleSort: () => void;\n handleLocationHistory: () => void;\n handleBookmarks: () => void;\n};\n\nfunction GoToMenuItem({ handleSort, handleLocationHistory, handleBookmarks }: GoToMenuItemProps) {\n return (\n \n

    Go To

    \n
    \n \n \n \n
    \n
    \n );\n}\n\nexport default GoToMenuItem;\n","import BookChapterInput from '@/components/advanced/book-chapter-control/book-chapter-input.component';\nimport BookMenuItem, {\n BookType,\n} from '@/components/advanced/book-chapter-control/book-menu-item.component';\nimport ChapterSelect from '@/components/advanced/book-chapter-control/chapter-select.component';\nimport GoToMenuItem from '@/components/advanced/book-chapter-control/go-to-menu-item.component';\nimport {\n DropdownMenu as ShadDropdownMenu,\n DropdownMenuContent as ShadDropdownMenuContent,\n DropdownMenuLabel as ShadDropdownMenuLabel,\n DropdownMenuSeparator as ShadDropdownMenuSeparator,\n DropdownMenuTrigger as ShadDropdownMenuTrigger,\n} from '@/components/shadcn-ui/dropdown-menu';\nimport { Canon } from '@sillsdev/scripture';\nimport { ScriptureReference, getChaptersForBook } from 'platform-bible-utils';\nimport {\n KeyboardEvent as ReactKeyboardEvent,\n useCallback,\n useEffect,\n useLayoutEffect,\n useRef,\n useState,\n} from 'react';\n\ntype BookTypeLabels = {\n [bookType in BookType]: string;\n};\ntype BookChapterControlProps = {\n scrRef: ScriptureReference;\n handleSubmit: (scrRef: ScriptureReference) => void;\n};\n\nconst ALL_BOOK_IDS = Canon.allBookIds;\nconst BOOK_TYPE_LABELS: BookTypeLabels = {\n OT: 'Old Testament',\n NT: 'New Testament',\n DC: 'Deuterocanon',\n};\nconst BOOK_TYPE_ARRAY: BookType[] = ['OT', 'NT', 'DC'];\n// This is the height of three menu items to offset scrolling to the selected menu item\n// If you use menuItemRef.clientHeight- includes height of chapter div which is too big\nconst SCROLL_OFFSET = 32 + 32 + 32;\nconst SEARCH_QUERY_FORMATS = [\n /^(\\w+)$/i, // Matches a single word (book name or id)\n /^(\\w+)(?:\\s(\\d+))$/i, // Matches a word followed by a chapter number\n /^(\\w+)(?:\\s(\\d+):(\\d+))$/i, // Matches a word followed by a chapter and verse number\n];\nconst fetchGroupedBooks = (bookType: BookType) => {\n const groupedBooks = {\n OT: ALL_BOOK_IDS.filter((bookId) => Canon.isBookOT(bookId)),\n NT: ALL_BOOK_IDS.filter((bookId) => Canon.isBookNT(bookId)),\n DC: ALL_BOOK_IDS.filter((bookId) => Canon.isBookDC(bookId)),\n };\n return groupedBooks[bookType];\n};\nconst fetchEndChapter = (bookId: string) => {\n // getChaptersForBook returns -1 if not found in scrBookData\n // scrBookData only includes OT and NT, so all DC will return -1\n return getChaptersForBook(Canon.bookIdToNumber(bookId));\n};\n\n/**\n * Gets all of the English names from book ids\n *\n * @returns String[]\n */\nfunction getAllEnglishNames(): string[] {\n const allEnglishNames = ALL_BOOK_IDS.map((bookId) => {\n return Canon.bookIdToEnglishName(bookId);\n });\n return allEnglishNames;\n}\n\n/**\n * Determines if bookName is in allEnglishNames\n *\n * @param bookName Book English name\n * @returns True if bookName is included, false otherwise\n */\nfunction isValidBookEnglishName(bookName: string): boolean {\n return getAllEnglishNames().includes(bookName);\n}\n\n/**\n * Gets a bookId from given English name\n *\n * @param bookName Book English name\n * @returns BookId of provided bookName, undefined otherwise\n */\nfunction getBookIdFromEnglishName(bookName: string): string | undefined {\n // Convert bookName to lowercase and then capitalize the first letter\n const formattedBookName = bookName.toLowerCase().replace(/^\\w/, (c) => c.toUpperCase());\n\n if (isValidBookEnglishName(formattedBookName)) {\n const matchingBookId = ALL_BOOK_IDS.find((bookId) => {\n return Canon.bookIdToEnglishName(bookId) === formattedBookName;\n });\n return matchingBookId;\n }\n\n return undefined;\n}\n\nfunction BookChapterControl({ scrRef, handleSubmit }: BookChapterControlProps) {\n const [searchQuery, setSearchQuery] = useState('');\n const [selectedBookId, setSelectedBookId] = useState(\n Canon.bookNumberToId(scrRef.bookNum),\n );\n const [highlightedChapter, setHighlightedChapter] = useState(scrRef.chapterNum ?? 0);\n const [highlightedBookId, setHighlightedBookId] = useState(\n Canon.bookNumberToId(scrRef.bookNum),\n );\n const [isContentOpen, setIsContentOpen] = useState(false);\n const [isContentOpenDelayed, setIsContentOpenDelayed] = useState(isContentOpen);\n\n // This ref will always be defined\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const inputRef = useRef(undefined!);\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const contentRef = useRef(undefined!);\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const menuItemRef = useRef(undefined!);\n\n const fetchFilteredBooks = useCallback(\n (bookType: BookType) => {\n return fetchGroupedBooks(bookType).filter((bookId: string) => {\n const englishNameLowerCase = Canon.bookIdToEnglishName(bookId).toLowerCase();\n const normalizedQuery = searchQuery.replace(/[^a-zA-Z]/g, '').toLowerCase();\n return (\n englishNameLowerCase.includes(normalizedQuery) || // Match book name\n bookId.toLowerCase().includes(normalizedQuery) // Match book ID\n );\n });\n },\n [searchQuery],\n );\n\n const handleSearchInput = (searchString: string) => {\n setSearchQuery(searchString);\n };\n\n /**\n * Whether to prevent radix's logic from closing the dropdown. This is important because radix\n * tries to close the dropdown when the input first focuses, and we don't want it to do that. But\n * we don't want to prevent the dropdown from closing when we click away from the input, so we\n * don't want to just keep it open if the input is focused\n */\n const shouldPreventAutoClosing = useRef(false);\n\n const controlMenuState = useCallback((open: boolean) => {\n if (shouldPreventAutoClosing.current) {\n shouldPreventAutoClosing.current = false;\n return;\n }\n setIsContentOpen(open);\n }, []);\n\n const updateReference = useCallback(\n (bookId: string, shouldClose: boolean, chapter?: number, verse?: number) => {\n setHighlightedChapter(\n Canon.bookNumberToId(scrRef.bookNum) !== bookId ? 1 : scrRef.chapterNum,\n );\n\n if (shouldClose || fetchEndChapter(bookId) === -1) {\n handleSubmit({\n bookNum: Canon.bookIdToNumber(bookId),\n chapterNum: chapter || 1,\n verseNum: verse || 1,\n });\n\n setIsContentOpen(false);\n setSearchQuery('');\n return;\n }\n\n setSelectedBookId(selectedBookId !== bookId ? bookId : '');\n setIsContentOpen(!shouldClose);\n },\n [handleSubmit, scrRef.bookNum, scrRef.chapterNum, selectedBookId],\n );\n\n const handleSelectChapter = (chapterNumber: number) => {\n if (chapterNumber <= 0 || chapterNumber > fetchEndChapter(selectedBookId)) {\n return;\n }\n updateReference(selectedBookId, true, chapterNumber);\n };\n\n const handleInputSubmit = useCallback(() => {\n SEARCH_QUERY_FORMATS.forEach((format) => {\n const matches = searchQuery.match(format);\n if (matches) {\n // Book should be a bookId or an english name\n const [book, chapter = undefined, verse = undefined] = matches.slice(1);\n const englishName = getBookIdFromEnglishName(book);\n\n if (Canon.isBookIdValid(book) || englishName) {\n updateReference(\n englishName ?? book,\n true,\n chapter ? parseInt(chapter, 10) : 1,\n verse ? parseInt(verse, 10) : 1,\n );\n }\n }\n });\n }, [updateReference, searchQuery]);\n\n const handleKeyDownInput = useCallback(\n (event: ReactKeyboardEvent) => {\n if (!isContentOpen) {\n setIsContentOpen(true);\n } else if (event.key === 'ArrowDown' || event.key === 'ArrowUp') {\n if (\n typeof menuItemRef !== 'undefined' &&\n // Ref uses null\n // eslint-disable-next-line no-null/no-null\n menuItemRef.current !== null\n ) {\n menuItemRef.current.focus();\n } else if (\n typeof contentRef !== 'undefined' &&\n // Ref uses null\n // eslint-disable-next-line no-null/no-null\n contentRef.current !== null\n ) {\n contentRef.current.focus();\n }\n event.preventDefault();\n }\n },\n [isContentOpen],\n );\n\n const handleKeyDownContent = (event: ReactKeyboardEvent) => {\n // When the dropdown menu has focus, key strokes should give focus to the input component,\n // unless they're navigation keys (arrows and enter)\n const { key } = event;\n if (\n key === 'ArrowRight' ||\n key === 'ArrowLeft' ||\n key === 'ArrowDown' ||\n key === 'ArrowUp' ||\n key === 'Enter'\n ) {\n return;\n }\n\n inputRef.current.dispatchEvent(new KeyboardEvent('keydown', { key }));\n inputRef.current.focus();\n };\n\n const handleKeyDownMenuItem = (event: ReactKeyboardEvent) => {\n const { key } = event;\n if (highlightedBookId === selectedBookId) {\n if (key === 'Enter') {\n event.preventDefault();\n updateReference(selectedBookId, true, highlightedChapter);\n return;\n }\n\n let chapterOffSet = 0;\n if (key === 'ArrowRight') {\n if (highlightedChapter < fetchEndChapter(highlightedBookId)) {\n chapterOffSet = 1;\n } else {\n event.preventDefault();\n return;\n }\n } else if (key === 'ArrowLeft') {\n if (highlightedChapter > 1) {\n chapterOffSet = -1;\n } else {\n event.preventDefault();\n return;\n }\n } else if (key === 'ArrowDown') {\n chapterOffSet = 6;\n } else if (key === 'ArrowUp') {\n chapterOffSet = -6;\n }\n if (\n highlightedChapter + chapterOffSet <= 0 ||\n highlightedChapter + chapterOffSet > fetchEndChapter(highlightedBookId)\n ) {\n setHighlightedChapter(0);\n } else if (chapterOffSet !== 0) {\n setHighlightedChapter(highlightedChapter + chapterOffSet);\n event.preventDefault();\n }\n }\n };\n\n useEffect(() => {\n if (selectedBookId === highlightedBookId) {\n if (selectedBookId === Canon.bookNumberToId(scrRef.bookNum)) {\n setHighlightedChapter(scrRef.chapterNum);\n } else {\n setHighlightedChapter(1);\n }\n } else {\n setHighlightedChapter(0);\n }\n }, [highlightedBookId, scrRef.bookNum, scrRef.chapterNum, selectedBookId]);\n\n // The purpose of these useLayoutEffects and timeout is to delay the scroll just\n // enough so that the refs are defined and available when they are used after the timeout\n useLayoutEffect(() => {\n setIsContentOpenDelayed(isContentOpen);\n }, [isContentOpen]);\n\n useLayoutEffect(() => {\n const scrollTimeout = setTimeout(() => {\n if (isContentOpenDelayed && contentRef.current && menuItemRef.current) {\n const menuItemOffsetTop = menuItemRef.current.offsetTop;\n const scrollPosition = menuItemOffsetTop - SCROLL_OFFSET;\n contentRef.current.scrollTo({ top: scrollPosition, behavior: 'instant' });\n }\n }, 10);\n return () => {\n clearTimeout(scrollTimeout);\n };\n }, [isContentOpenDelayed]);\n\n return (\n
    \n \n \n {\n setSelectedBookId(Canon.bookNumberToId(scrRef.bookNum));\n setHighlightedBookId(Canon.bookNumberToId(scrRef.bookNum));\n setHighlightedChapter(scrRef.chapterNum > 0 ? scrRef.chapterNum : 0);\n setIsContentOpen(true);\n inputRef.current.focus();\n }}\n onFocus={() => {\n // Radix thinks we want to close because the input is being focused. Prevent that\n shouldPreventAutoClosing.current = true;\n }}\n handleSubmit={handleInputSubmit}\n placeholder={`${Canon.bookNumberToEnglishName(scrRef.bookNum)} ${scrRef.chapterNum}:${scrRef.verseNum}`}\n />\n \n \n console.log('sorting')}\n handleLocationHistory={() => console.log('location history')}\n handleBookmarks={() => console.log('bookmarks')}\n />\n {BOOK_TYPE_ARRAY.map(\n (bookType, bookTypeIndex) =>\n fetchFilteredBooks(bookType).length > 0 && (\n
    \n \n {BOOK_TYPE_LABELS[bookType]}\n \n\n {fetchFilteredBooks(bookType).map((bookId) => (\n
    \n updateReference(bookId, false)}\n isSelected={selectedBookId === bookId}\n handleHighlightBook={() => setHighlightedBookId(bookId)}\n handleKeyDown={handleKeyDownMenuItem}\n bookType={bookType}\n ref={(element: HTMLDivElement) => {\n if (selectedBookId === bookId) menuItemRef.current = element;\n }}\n >\n {\n setHighlightedChapter(chapterNumber);\n }}\n />\n \n
    \n ))}\n {BOOK_TYPE_ARRAY.length - 1 !== bookTypeIndex ? (\n \n ) : undefined}\n
    \n ),\n )}\n \n
    \n
    \n );\n}\n\nexport default BookChapterControl;\n","import React from 'react';\nimport { Slot } from '@radix-ui/react-slot';\nimport { cva, type VariantProps } from 'class-variance-authority';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport const buttonVariants = cva(\n 'pr-twp tw-inline-flex tw-items-center tw-justify-center tw-whitespace-nowrap tw-rounded-md tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-colors focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50',\n {\n variants: {\n variant: {\n default: 'tw-bg-primary tw-text-primary-foreground hover:tw-bg-primary/90',\n destructive: 'tw-bg-destructive tw-text-destructive-foreground hover:tw-bg-destructive/90',\n outline:\n 'tw-border tw-border-input tw-bg-background hover:tw-bg-accent hover:tw-text-accent-foreground',\n secondary: 'tw-bg-secondary tw-text-secondary-foreground hover:tw-bg-secondary/80',\n ghost: 'hover:tw-bg-accent hover:tw-text-accent-foreground',\n link: 'tw-text-primary tw-underline-offset-4 hover:tw-underline',\n },\n size: {\n default: 'tw-h-10 tw-px-4 tw-py-2',\n sm: 'tw-h-9 tw-rounded-md tw-px-3',\n lg: 'tw-h-11 tw-rounded-md tw-px-8',\n icon: 'tw-h-10 tw-w-10',\n },\n },\n defaultVariants: {\n variant: 'default',\n size: 'default',\n },\n },\n);\n\nexport interface ButtonProps\n extends React.ButtonHTMLAttributes,\n VariantProps {\n asChild?: boolean;\n}\n\nexport const Button = React.forwardRef(\n ({ className, variant, size, asChild = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'button';\n return (\n \n );\n },\n);\nButton.displayName = 'Button';\n","import React from 'react';\nimport * as LabelPrimitive from '@radix-ui/react-label';\nimport { cva, type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst labelVariants = cva(\n 'tw-text-sm tw-font-medium tw-leading-none peer-disabled:tw-cursor-not-allowed peer-disabled:tw-opacity-70',\n);\n\nexport const Label = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef & VariantProps\n>(({ className, ...props }, ref) => (\n \n));\nLabel.displayName = LabelPrimitive.Root.displayName;\n","import React from 'react';\nimport * as RadioGroupPrimitive from '@radix-ui/react-radio-group';\nimport { Circle } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst RadioGroup = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => {\n return (\n \n );\n});\nRadioGroup.displayName = RadioGroupPrimitive.Root.displayName;\n\nconst RadioGroupItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => {\n return (\n \n \n \n \n \n );\n});\nRadioGroupItem.displayName = RadioGroupPrimitive.Item.displayName;\n\nexport { RadioGroup, RadioGroupItem };\n","import React from 'react';\nimport * as PopoverPrimitive from '@radix-ui/react-popover';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Popover = PopoverPrimitive.Root;\n\nconst PopoverTrigger = PopoverPrimitive.Trigger;\n\nconst PopoverContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, align = 'center', sideOffset = 4, ...props }, ref) => (\n \n \n \n));\nPopoverContent.displayName = PopoverPrimitive.Content.displayName;\n\nexport { Popover, PopoverTrigger, PopoverContent };\n","import React from 'react';\nimport * as DialogPrimitive from '@radix-ui/react-dialog';\nimport { X } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Dialog = DialogPrimitive.Root;\n\nconst DialogTrigger = DialogPrimitive.Trigger;\n\nconst DialogPortal = DialogPrimitive.Portal;\n\nconst DialogClose = DialogPrimitive.Close;\n\nconst DialogOverlay = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nDialogOverlay.displayName = DialogPrimitive.Overlay.displayName;\n\nconst DialogContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, ...props }, ref) => (\n \n \n \n {children}\n \n \n Close\n \n \n \n));\nDialogContent.displayName = DialogPrimitive.Content.displayName;\n\nfunction DialogHeader({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nDialogHeader.displayName = 'DialogHeader';\n\nfunction DialogFooter({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nDialogFooter.displayName = 'DialogFooter';\n\nconst DialogTitle = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nDialogTitle.displayName = DialogPrimitive.Title.displayName;\n\nconst DialogDescription = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nDialogDescription.displayName = DialogPrimitive.Description.displayName;\n\nexport {\n Dialog,\n DialogPortal,\n DialogOverlay,\n DialogClose,\n DialogTrigger,\n DialogContent,\n DialogHeader,\n DialogFooter,\n DialogTitle,\n DialogDescription,\n};\n","import React from 'react';\nimport { type DialogProps } from '@radix-ui/react-dialog';\nimport { Command as CommandPrimitive } from 'cmdk';\nimport { Search } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Dialog, DialogContent } from '@/components/shadcn-ui/dialog';\n\nconst Command = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nCommand.displayName = CommandPrimitive.displayName;\n\ninterface CommandDialogProps extends DialogProps {}\n\nfunction CommandDialog({ children, ...props }: CommandDialogProps) {\n return (\n \n \n \n {children}\n \n \n \n );\n}\n\nconst CommandInput = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n
    \n \n \n
    \n));\n\nCommandInput.displayName = CommandPrimitive.Input.displayName;\n\nconst CommandList = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\n\nCommandList.displayName = CommandPrimitive.List.displayName;\n\nconst CommandEmpty = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>((props, ref) => (\n \n));\n\nCommandEmpty.displayName = CommandPrimitive.Empty.displayName;\n\nconst CommandGroup = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\n\nCommandGroup.displayName = CommandPrimitive.Group.displayName;\n\nconst CommandSeparator = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nCommandSeparator.displayName = CommandPrimitive.Separator.displayName;\n\nconst CommandItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\n\nCommandItem.displayName = CommandPrimitive.Item.displayName;\n\nfunction CommandShortcut({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nCommandShortcut.displayName = 'CommandShortcut';\n\nexport {\n Command,\n CommandDialog,\n CommandInput,\n CommandList,\n CommandEmpty,\n CommandGroup,\n CommandItem,\n CommandShortcut,\n CommandSeparator,\n};\n","import { useState } from 'react';\nimport { Check, ChevronsUpDown } from 'lucide-react';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport { Popover, PopoverContent, PopoverTrigger } from '@/components/shadcn-ui/popover';\nimport {\n Command,\n CommandEmpty,\n CommandInput,\n CommandItem,\n CommandList,\n} from '@/components/shadcn-ui/command';\nimport { PopoverProps } from '@radix-ui/react-popover';\n\nexport type ComboBoxLabelOption = { label: string };\nexport type ComboBoxOption = string | number | ComboBoxLabelOption;\n\nexport type ComboBoxProps = {\n /** Optional unique identifier */\n id?: string;\n /** Text label title for combobox */\n /** List of available options for the dropdown menu */\n options?: readonly T[];\n /** Additional css classes to help with unique styling of the combo box button */\n buttonClassName?: string;\n /** Additional css classes to help with unique styling of the combo box popover */\n popoverContentClassName?: string;\n /**\n * The selected value that the combo box currently holds. Must be shallow equal to one of the\n * options entries.\n */\n value?: T;\n /** Triggers when content of textfield is changed */\n onChange?: (newValue: T) => void;\n /** Used to determine the string value for a given option. */\n getOptionLabel?: (option: ComboBoxOption) => string;\n /** Text displayed on button if `value` is undefined */\n buttonPlaceholder?: string;\n /** Placeholder text for text field */\n textPlaceholder?: string;\n /** Text to display when no options match input */\n commandEmptyMessage?: string;\n /** Variant of button */\n buttonVariant?: ButtonProps['variant'];\n /** Text direction ltr or rtl */\n dir?: Direction;\n /** Optional boolean to set if trigger should be disabled */\n isDisabled?: boolean;\n} & PopoverProps;\n\ntype Direction = 'ltr' | 'rtl';\n\nfunction getOptionLabelDefault(option: ComboBoxOption): string {\n if (typeof option === 'string') {\n return option;\n }\n if (typeof option === 'number') {\n return option.toString();\n }\n return option.label;\n}\n\n/**\n * Autocomplete input and command palette with a list of suggestions.\n *\n * Thanks to Shadcn for heavy inspiration and documentation\n * https://ui.shadcn.com/docs/components/combobox\n */\nfunction ComboBox({\n id,\n options = [],\n buttonClassName,\n popoverContentClassName,\n value,\n onChange = () => {},\n getOptionLabel = getOptionLabelDefault,\n buttonPlaceholder = '',\n textPlaceholder = '',\n commandEmptyMessage = 'No option found',\n buttonVariant = 'outline',\n dir = 'ltr',\n isDisabled = false,\n ...props\n}: ComboBoxProps) {\n const [open, setOpen] = useState(false);\n\n return (\n \n \n \n \n {value ? getOptionLabel(value) : buttonPlaceholder}\n \n \n \n \n \n \n \n {commandEmptyMessage}\n \n {options.map((option) => (\n {\n onChange(option);\n setOpen(false);\n }}\n >\n \n {getOptionLabel(option)}\n \n ))}\n \n \n \n \n );\n}\n\nexport default ComboBox;\n","import { useMemo } from 'react';\nimport ComboBox from '@/components/basics/combo-box.component';\nimport { Label } from '@/components/shadcn-ui/label';\n\nexport type ChapterRangeSelectorProps = {\n startChapter: number;\n endChapter: number;\n handleSelectStartChapter: (chapter: number) => void;\n handleSelectEndChapter: (chapter: number) => void;\n isDisabled?: boolean;\n chapterCount: number;\n};\n\nexport default function ChapterRangeSelector({\n startChapter,\n endChapter,\n handleSelectStartChapter,\n handleSelectEndChapter,\n isDisabled = false,\n chapterCount,\n}: ChapterRangeSelectorProps) {\n const chapterOptions = useMemo(\n () => Array.from({ length: chapterCount }, (_, index) => index + 1),\n [chapterCount],\n );\n\n const onChangeStartChapter = (value: number) => {\n handleSelectStartChapter(value);\n if (value > endChapter) {\n handleSelectEndChapter(value);\n }\n };\n\n const onChangeEndChapter = (value: number) => {\n handleSelectEndChapter(value);\n if (value < startChapter) {\n handleSelectStartChapter(value);\n }\n };\n\n return (\n <>\n \n option.toString()}\n value={startChapter}\n />\n\n \n option.toString()}\n value={endChapter}\n />\n \n );\n}\n","import { Button } from '@/components/shadcn-ui/button';\nimport { Label } from '@/components/shadcn-ui/label';\nimport { RadioGroup, RadioGroupItem } from '@/components/shadcn-ui/radio-group';\nimport { Canon } from '@sillsdev/scripture';\nimport { LocalizedStringValue } from 'platform-bible-utils';\nimport { useState } from 'react';\nimport ChapterRangeSelector, {\n ChapterRangeSelectorProps,\n} from '../basics/chapter-range-selector.component';\n\nexport enum BookSelectionMode {\n CURRENT_BOOK = 'current book',\n CHOOSE_BOOKS = 'choose books',\n}\n\n/**\n * Object containing all keys used for localization in this component. If you're using this\n * component in an extension, you can pass it into the useLocalizedStrings hook to easily obtain the\n * localized strings and pass them into the localizedStrings prop of this component\n */\nexport const BOOK_SELECTOR_STRING_KEYS = Object.freeze([\n '%webView_bookSelector_currentBook%',\n '%webView_bookSelector_choose%',\n '%webView_bookSelector_chooseBooks%',\n] as const);\n\nexport type BookSelectorLocalizedStrings = {\n [localizedInventoryKey in (typeof BOOK_SELECTOR_STRING_KEYS)[number]]?: LocalizedStringValue;\n};\n\n/**\n * Gets the localized value for the provided key\n *\n * @param strings Object containing localized string\n * @param key Key for a localized string\n * @returns The localized value for the provided key, if available. Returns the key if no localized\n * value is available\n */\nconst localizeString = (\n strings: BookSelectorLocalizedStrings,\n key: keyof BookSelectorLocalizedStrings,\n) => {\n return strings[key] ?? key;\n};\n\ntype BookSelectorProps = ChapterRangeSelectorProps & {\n handleBookSelectionModeChange: (newMode: BookSelectionMode) => void;\n currentBookName: string;\n onSelectBooks: () => void;\n selectedBookIds: string[];\n localizedStrings: BookSelectorLocalizedStrings;\n};\n\nexport default function BookSelector({\n handleBookSelectionModeChange,\n currentBookName,\n onSelectBooks,\n selectedBookIds,\n chapterCount,\n endChapter,\n handleSelectEndChapter,\n startChapter,\n handleSelectStartChapter,\n localizedStrings,\n}: BookSelectorProps) {\n const currentBookText = localizeString(localizedStrings, '%webView_bookSelector_currentBook%');\n const chooseText = localizeString(localizedStrings, '%webView_bookSelector_choose%');\n const chooseBooksText = localizeString(localizedStrings, '%webView_bookSelector_chooseBooks%');\n\n const [bookSelectionMode, setBookSelectionMode] = useState(\n BookSelectionMode.CURRENT_BOOK,\n );\n\n const onSelectionModeChange = (newMode: BookSelectionMode) => {\n setBookSelectionMode(newMode);\n handleBookSelectionModeChange(newMode);\n };\n\n return (\n onSelectionModeChange(value as BookSelectionMode)}\n >\n
    \n
    \n
    \n \n \n
    \n \n
    \n \n
    \n
    \n
    \n
    \n \n \n
    \n \n onSelectBooks()}\n >\n {chooseText}\n \n
    \n
    \n \n );\n}\n","import { DropdownMenuTrigger } from '@radix-ui/react-dropdown-menu';\nimport { FilterIcon } from 'lucide-react';\nimport { Table } from '@tanstack/react-table';\n\nimport { Button } from '@/components/shadcn-ui/button';\nimport {\n DropdownMenu,\n DropdownMenuCheckboxItem,\n DropdownMenuContent,\n DropdownMenuLabel,\n DropdownMenuSeparator,\n} from '@/components/shadcn-ui/dropdown-menu';\n\ninterface DataTableViewOptionsProps {\n table: Table;\n}\n\nfunction DataTableViewOptions({ table }: DataTableViewOptionsProps) {\n return (\n \n \n \n \n \n Toggle columns\n \n {table\n .getAllColumns()\n .filter((column) => column.getCanHide())\n .map((column) => {\n return (\n column.toggleVisibility(!!value)}\n >\n {column.id}\n \n );\n })}\n \n \n );\n}\n\nexport default DataTableViewOptions;\n","import React from 'react';\nimport * as SelectPrimitive from '@radix-ui/react-select';\nimport { Check, ChevronDown, ChevronUp } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Select = SelectPrimitive.Root;\n\nconst SelectGroup = SelectPrimitive.Group;\n\nconst SelectValue = SelectPrimitive.Value;\n\nconst SelectTrigger = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, ...props }, ref) => (\n span]:tw-line-clamp-1',\n className,\n )}\n {...props}\n >\n {children}\n \n \n \n \n));\nSelectTrigger.displayName = SelectPrimitive.Trigger.displayName;\n\nconst SelectScrollUpButton = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n));\nSelectScrollUpButton.displayName = SelectPrimitive.ScrollUpButton.displayName;\n\nconst SelectScrollDownButton = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n));\nSelectScrollDownButton.displayName = SelectPrimitive.ScrollDownButton.displayName;\n\nconst SelectContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, position = 'popper', ...props }, ref) => (\n \n \n \n \n {children}\n \n \n \n \n));\nSelectContent.displayName = SelectPrimitive.Content.displayName;\n\nconst SelectLabel = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSelectLabel.displayName = SelectPrimitive.Label.displayName;\n\nconst SelectItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, ...props }, ref) => (\n \n \n \n \n \n \n\n {children}\n \n));\nSelectItem.displayName = SelectPrimitive.Item.displayName;\n\nconst SelectSeparator = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSelectSeparator.displayName = SelectPrimitive.Separator.displayName;\n\nexport {\n Select,\n SelectGroup,\n SelectValue,\n SelectTrigger,\n SelectContent,\n SelectLabel,\n SelectItem,\n SelectSeparator,\n SelectScrollUpButton,\n SelectScrollDownButton,\n};\n","import { ChevronLeftIcon, ChevronRightIcon, ArrowLeftIcon, ArrowRightIcon } from 'lucide-react';\nimport { Table } from '@tanstack/react-table';\n\nimport { Button } from '@/components/shadcn-ui/button';\nimport {\n Select,\n SelectContent,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\n\ninterface DataTablePaginationProps {\n table: Table;\n}\n\nfunction DataTablePagination({ table }: DataTablePaginationProps) {\n return (\n
    \n
    \n
    \n {table.getFilteredSelectedRowModel().rows.length} of{' '}\n {table.getFilteredRowModel().rows.length} row(s) selected\n
    \n
    \n

    Rows per page

    \n {\n table.setPageSize(Number(value));\n }}\n >\n \n \n \n \n {[10, 20, 30, 40, 50].map((pageSize) => (\n \n {pageSize}\n \n ))}\n \n \n
    \n
    \n Page {table.getState().pagination.pageIndex + 1} of {table.getPageCount()}\n
    \n
    \n table.setPageIndex(0)}\n disabled={!table.getCanPreviousPage()}\n >\n Go to first page\n \n \n table.previousPage()}\n disabled={!table.getCanPreviousPage()}\n >\n Go to previous page\n \n \n table.nextPage()}\n disabled={!table.getCanNextPage()}\n >\n Go to next page\n \n \n table.setPageIndex(table.getPageCount() - 1)}\n disabled={!table.getCanNextPage()}\n >\n Go to last page\n \n \n
    \n
    \n
    \n );\n}\n\nexport default DataTablePagination;\n","import React from 'react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Table = React.forwardRef<\n HTMLTableElement,\n React.HTMLAttributes & { stickyHeader?: boolean }\n>(({ className, stickyHeader, ...props }, ref) => (\n
    \n \n
    \n));\nTable.displayName = 'Table';\n\nconst TableHeader = React.forwardRef<\n HTMLTableSectionElement,\n React.HTMLAttributes & { stickyHeader?: boolean }\n>(({ className, stickyHeader, ...props }, ref) => (\n \n));\nTableHeader.displayName = 'TableHeader';\n\nconst TableBody = React.forwardRef<\n HTMLTableSectionElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableBody.displayName = 'TableBody';\n\nconst TableFooter = React.forwardRef<\n HTMLTableSectionElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n tr]:last:tw-border-b-0', className)}\n {...props}\n />\n));\nTableFooter.displayName = 'TableFooter';\n\nconst TableRow = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nTableRow.displayName = 'TableRow';\n\nconst TableHead = React.forwardRef<\n HTMLTableCellElement,\n React.ThHTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableHead.displayName = 'TableHead';\n\nconst TableCell = React.forwardRef<\n HTMLTableCellElement,\n React.TdHTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableCell.displayName = 'TableCell';\n\nconst TableCaption = React.forwardRef<\n HTMLTableCaptionElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableCaption.displayName = 'TableCaption';\n\nexport { Table, TableHeader, TableBody, TableFooter, TableHead, TableRow, TableCell, TableCaption };\n","import { useState } from 'react';\n\nimport {\n ColumnFiltersState,\n flexRender,\n getCoreRowModel,\n getFilteredRowModel,\n getPaginationRowModel,\n getSortedRowModel,\n SortingState,\n ColumnDef as TSColumnDef,\n Row as TSRow,\n RowSelectionState as TSRowSelectionState,\n SortDirection as TSSortDirection,\n Table as TSTable,\n useReactTable,\n VisibilityState,\n} from '@tanstack/react-table';\n\nimport DataTableViewOptions from '@/components/advanced/data-table/data-table-column-toggle.component';\nimport DataTablePagination from '@/components/advanced/data-table/data-table-pagination.component';\nimport { Button } from '@/components/shadcn-ui/button';\nimport {\n Table,\n TableBody,\n TableCell,\n TableHead,\n TableHeader,\n TableRow,\n} from '@/components/shadcn-ui/table';\n\nexport type ColumnDef = TSColumnDef;\nexport type RowContents = TSRow;\nexport type TableContents = TSTable;\nexport type SortDirection = TSSortDirection;\nexport type RowSelectionState = TSRowSelectionState;\n\ninterface DataTableProps {\n columns: ColumnDef[];\n data: TData[];\n enablePagination?: boolean;\n showPaginationControls?: boolean;\n showColumnVisibilityControls?: boolean;\n stickyHeader?: boolean;\n onRowClickHandler?: (row: RowContents, table: TableContents) => void;\n}\n\n/**\n * Feature-rich table component that infuses our basic shadcn-based Table component with features\n * from TanStack's React Table library\n */\nfunction DataTable({\n columns,\n data,\n enablePagination = false,\n showPaginationControls = false,\n showColumnVisibilityControls = false,\n stickyHeader = false,\n onRowClickHandler = () => {},\n}: DataTableProps) {\n const [sorting, setSorting] = useState([]);\n const [columnFilters, setColumnFilters] = useState([]);\n const [columnVisibility, setColumnVisibility] = useState({});\n const [rowSelection, setRowSelection] = useState({});\n\n const table = useReactTable({\n data,\n columns,\n getCoreRowModel: getCoreRowModel(),\n ...(enablePagination && { getPaginationRowModel: getPaginationRowModel() }),\n onSortingChange: setSorting,\n getSortedRowModel: getSortedRowModel(),\n onColumnFiltersChange: setColumnFilters,\n getFilteredRowModel: getFilteredRowModel(),\n onColumnVisibilityChange: setColumnVisibility,\n onRowSelectionChange: setRowSelection,\n state: {\n sorting,\n columnFilters,\n columnVisibility,\n rowSelection,\n },\n });\n\n return (\n
    \n {showColumnVisibilityControls && }\n \n \n {table.getHeaderGroups().map((headerGroup) => (\n \n {headerGroup.headers.map((header) => {\n return (\n \n {header.isPlaceholder\n ? undefined\n : flexRender(header.column.columnDef.header, header.getContext())}\n \n );\n })}\n \n ))}\n \n \n {table.getRowModel().rows?.length ? (\n table.getRowModel().rows.map((row) => (\n onRowClickHandler(row, table)}\n key={row.id}\n data-state={row.getIsSelected() && 'selected'}\n >\n {row.getVisibleCells().map((cell) => (\n \n {flexRender(cell.column.columnDef.cell, cell.getContext())}\n \n ))}\n \n ))\n ) : (\n \n \n No results.\n \n \n )}\n \n
    \n {enablePagination && (\n
    \n table.previousPage()}\n disabled={!table.getCanPreviousPage()}\n >\n Previous\n \n table.nextPage()}\n disabled={!table.getCanNextPage()}\n >\n Next\n \n
    \n )}\n {enablePagination && showPaginationControls && }\n
    \n );\n}\n\nexport default DataTable;\n","import {\n Table,\n TableBody,\n TableCell,\n TableHead,\n TableHeader,\n TableRow,\n} from '@/components/shadcn-ui/table';\nimport { Canon } from '@sillsdev/scripture';\nimport { deepEqual, LanguageStrings, ScriptureReference } from 'platform-bible-utils';\nimport { useMemo } from 'react';\nimport { InventoryItemOccurrence } from './inventory-utils';\n\n/** Props for the OccurrencesTable component */\ntype OccurrencesTableProps = {\n /** Data that contains scriptures references and snippets of scripture */\n occurrenceData: InventoryItemOccurrence[];\n /** Callback function that is executed when the scripture reference is changed */\n setScriptureReference: (scriptureReference: ScriptureReference) => void;\n /**\n * Object with all localized strings that the OccurrencesTable needs to work well across multiple\n * languages\n */\n localizedStrings: LanguageStrings;\n};\n\n/**\n * Table that shows occurrences of specified inventory item(s). The first column shows the related\n * scripture reference. The second column shows the snippet of scripture that contains the specified\n * inventory item\n */\nfunction OccurrencesTable({\n occurrenceData,\n setScriptureReference,\n localizedStrings,\n}: OccurrencesTableProps) {\n const referenceHeaderText =\n localizedStrings['%webView_inventory_occurrences_table_header_reference%'];\n const occurrenceHeaderText =\n localizedStrings['%webView_inventory_occurrences_table_header_occurrence%'];\n\n const occurrences: InventoryItemOccurrence[] = useMemo(() => {\n const uniqueOccurrences: InventoryItemOccurrence[] = [];\n\n occurrenceData.forEach((occurrence) => {\n if (!uniqueOccurrences.some((uniqueOccurrence) => deepEqual(uniqueOccurrence, occurrence))) {\n uniqueOccurrences.push(occurrence);\n }\n });\n\n return uniqueOccurrences;\n }, [occurrenceData]);\n\n return (\n \n \n \n {referenceHeaderText}\n {occurrenceHeaderText}\n \n \n \n {occurrences.length > 0 &&\n occurrences.map((occurrence) => (\n {\n setScriptureReference(occurrence.reference);\n }}\n >\n {`${Canon.bookNumberToEnglishName(occurrence.reference.bookNum)} ${occurrence.reference.chapterNum}:${occurrence.reference.verseNum}`}\n {occurrence.text}\n \n ))}\n \n
    \n );\n}\n\nexport default OccurrencesTable;\n","import React from 'react';\nimport * as CheckboxPrimitive from '@radix-ui/react-checkbox';\nimport { Check } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Checkbox = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n \n \n));\nCheckbox.displayName = CheckboxPrimitive.Root.displayName;\n\nexport default Checkbox;\n","import { Canon } from '@sillsdev/scripture';\nimport { ScriptureReference } from 'platform-bible-utils';\n\n/* #region Types */\n\n/**\n * Status of items that appear in inventories. 'approved' and 'unapproved' items are defined in the\n * project's `Settings.xml`. All other items are defined as 'unknown'\n */\nexport type Status = 'approved' | 'unapproved' | 'unknown';\n\n/** Occurrence of item in inventory. Primarily used by table that shows occurrences */\nexport type InventoryItemOccurrence = {\n /** Reference to scripture where the item appears */\n reference: ScriptureReference;\n /** Snippet of scripture that contains the occurrence */\n text: string;\n};\n\n/** Data structure that contains all information on an item that is shown in an inventory */\nexport type InventoryTableData = {\n /**\n * The item (e.g. a character in the characters inventory, a marker in the marker inventory) In\n * most cases the array will only have one element. In case of additional items (e.g. the\n * preceding marker in the markers check), the primary item should be stored in the first index.\n * To show additional items in the inventory, make sure to configure the `additionalItemsLabels`\n * prop for the Inventory component\n */\n items: string[];\n /** The number of times this item occurs in the selected scope */\n count: number;\n /** The status of this item (see documentation for `Status` type for more information) */\n status: Status;\n /** Occurrences of this item in the scripture text for the selected scope */\n occurrences: InventoryItemOccurrence[];\n};\n\n/* #endregion */\n\n/* #region Functions */\n\n/**\n * Splits USFM string into shorter line-like segments\n *\n * @param text A single (likely very large) USFM string\n * @returns An array containing the input text, split into shorter segments\n */\nexport const getLinesFromUSFM = (text: string) => {\n // Splits on (CR)LF, CR, \\v, \\c and \\id\n return text.split(/(?:\\r?\\n|\\r)|(?=(?:\\\\(?:v|c|id)))/g);\n};\n\n/**\n * Extracts chapter or verse number from USFM strings that start with a \\c or \\v marker\n *\n * @param text USFM string that is expected to start with \\c or \\v marker\n * @returns Chapter or verse number if one is found. Else returns 0.\n */\nexport const getNumberFromUSFM = (text: string): number | undefined => {\n // Captures all digits that follow \\v or \\c markers followed by whitespace located at the start of a string\n const regex = /^\\\\[vc]\\s+(\\d+)/;\n const match = text.match(regex);\n\n if (match) {\n return +match[1];\n }\n return undefined;\n};\n\n/**\n * Gets book ID from USFM string that starts with the \\id marker, and returns book number for it\n *\n * @param text USFM string that is expected to start with \\id marker\n * @returns Book number corresponding to the \\id marker in the input text. Returns 0 if no marker is\n * found or the marker is not valid\n */\nexport const getBookNumFromId = (text: string): number => {\n // Captures all digits that follow an \\id marker followed by whitespace located at the start of a string\n const match = text.match(/^\\\\id\\s+([A-Za-z]+)/);\n if (match) {\n return Canon.bookIdToNumber(match[1]);\n }\n return 0;\n};\n\n/**\n * Gets the status for an item, typically used in the Inventory component\n *\n * @param item The item for which the status is being requested\n * @param approvedItems Array of approved items, typically as defined in `Settings.xml`\n * @param unapprovedItems Array of unapproved items, typically as defined in `Settings.xml`\n * @returns The status for the specified item\n */\nexport const getStatusForItem = (\n item: string,\n approvedItems: string[],\n unapprovedItems: string[],\n): Status => {\n if (unapprovedItems.includes(item)) return 'unapproved';\n if (approvedItems.includes(item)) return 'approved';\n return 'unknown';\n};\n\n/* #endregion */\n","import React from 'react';\nimport * as TogglePrimitive from '@radix-ui/react-toggle';\nimport { cva, type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst toggleVariants = cva(\n 'pr-twp tw-inline-flex tw-items-center tw-justify-center tw-rounded-md tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-colors hover:tw-bg-muted hover:tw-text-muted-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50 data-[state=on]:tw-bg-accent data-[state=on]:tw-text-accent-foreground',\n {\n variants: {\n variant: {\n default: 'tw-bg-transparent',\n outline:\n 'tw-border tw-border-input tw-bg-transparent hover:tw-bg-accent hover:tw-text-accent-foreground',\n },\n size: {\n default: 'tw-h-10 tw-px-3',\n sm: 'tw-h-9 tw-px-2.5',\n lg: 'tw-h-11 tw-px-5',\n },\n },\n defaultVariants: {\n variant: 'default',\n size: 'default',\n },\n },\n);\n\nconst Toggle = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef & VariantProps\n>(({ className, variant, size, ...props }, ref) => (\n \n));\n\nToggle.displayName = TogglePrimitive.Root.displayName;\n\nexport { Toggle, toggleVariants };\n","import React from 'react';\nimport * as ToggleGroupPrimitive from '@radix-ui/react-toggle-group';\nimport { type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { toggleVariants } from '@/components/shadcn-ui/toggle';\n\nconst ToggleGroupContext = React.createContext>({\n size: 'default',\n variant: 'default',\n});\n\nconst ToggleGroup = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef &\n VariantProps\n>(({ className, variant, size, children, ...props }, ref) => (\n \n \n {children}\n \n \n));\n\nToggleGroup.displayName = ToggleGroupPrimitive.Root.displayName;\n\nconst ToggleGroupItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef &\n VariantProps\n>(({ className, children, variant, size, ...props }, ref) => {\n const context = React.useContext(ToggleGroupContext);\n\n return (\n \n {children}\n \n );\n});\n\nToggleGroupItem.displayName = ToggleGroupPrimitive.Item.displayName;\n\nexport { ToggleGroup, ToggleGroupItem };\n","import { ColumnDef, SortDirection } from '@/components/advanced/data-table/data-table.component';\nimport { Button } from '@/components/shadcn-ui/button';\nimport { ToggleGroup, ToggleGroupItem } from '@/components/shadcn-ui/toggle-group';\nimport {\n ArrowDownIcon,\n ArrowUpDownIcon,\n ArrowUpIcon,\n CircleCheckIcon,\n CircleHelpIcon,\n CircleXIcon,\n} from 'lucide-react';\nimport { ReactNode } from 'react';\nimport { InventoryTableData, Status } from './inventory-utils';\n\n/**\n * Gets an icon that indicates the current sorting direction based on the provided input\n *\n * @param sortDirection Sorting direction. Can be ascending ('asc'), descending ('desc') or false (\n * i.e. not sorted)\n * @returns The appropriate sorting icon for the provided sorting direction\n */\nconst getSortingIcon = (sortDirection: false | SortDirection): ReactNode => {\n if (sortDirection === 'asc') {\n return ;\n }\n if (sortDirection === 'desc') {\n return ;\n }\n return ;\n};\n\n/**\n * Function that creates the item column for inventories\n *\n * @param itemLabel Localized label for the item column (e.g. 'Character', 'Repeated Word', etc.)\n * @returns Column that shows the inventory items. Should be used with the DataTable component\n */\nexport const inventoryItemColumn = (itemLabel: string): ColumnDef => {\n return {\n accessorKey: 'item',\n accessorFn: (row: InventoryTableData) => row.items[0],\n header: ({ column }) => (\n \n ),\n };\n};\n\n/**\n * Function that creates the additional item columns for inventories\n *\n * @param additionalItemLabel Localized label for the additional item column (e.g. 'Preceding\n * Marker')\n * @param additionalItemIndex Index that locates the desired item in the items array of the\n * inventory\n * @returns Column that shows additional inventory items. Should be used with the DataTable\n * component\n */\nexport const inventoryAdditionalItemColumn = (\n additionalItemLabel: string,\n additionalItemIndex: number,\n): ColumnDef => {\n return {\n accessorKey: `item${additionalItemIndex}`,\n accessorFn: (row: InventoryTableData) => row.items[additionalItemIndex],\n header: ({ column }) => (\n \n ),\n };\n};\n\n/**\n * Function that creates the count column for inventories. Should be used with the DataTable\n * component.\n *\n * @param itemLabel Localized label for the count column\n * @returns Column that shows the number of occurrences of the related inventory items\n */\nexport const inventoryCountColumn = (countLabel: string): ColumnDef => {\n return {\n accessorKey: 'count',\n header: ({ column }) => (\n
    \n \n
    \n ),\n cell: ({ row }) =>
    {row.getValue('count')}
    ,\n };\n};\n\n/**\n * Function that updates project settings when status for item(s) changes\n *\n * @param changedItems Array of items for which the status is being updated\n * @param newStatus The status that the items are being given\n * @param approvedItems Array of currently approved items\n * @param onApprovedItemsChange Callback function that stores the updated list of approved items\n * @param unapprovedItems Array of currently unapproved items\n * @param onUnapprovedItemsChange Callback function that stores the updated list of unapproved items\n */\nconst statusChangeHandler = (\n changedItems: string[],\n newStatus: Status,\n approvedItems: string[],\n onApprovedItemsChange: (items: string[]) => void,\n unapprovedItems: string[],\n onUnapprovedItemsChange: (items: string[]) => void,\n) => {\n let newApprovedItems: string[] = [...approvedItems];\n changedItems.forEach((item) => {\n if (newStatus === 'approved') {\n if (!newApprovedItems.includes(item)) {\n newApprovedItems.push(item);\n }\n } else {\n newApprovedItems = newApprovedItems.filter((validItem) => validItem !== item);\n }\n });\n onApprovedItemsChange(newApprovedItems);\n\n let newUnapprovedItems: string[] = [...unapprovedItems];\n changedItems.forEach((item) => {\n if (newStatus === 'unapproved') {\n if (!newUnapprovedItems.includes(item)) {\n newUnapprovedItems.push(item);\n }\n } else {\n newUnapprovedItems = newUnapprovedItems.filter((unapprovedItem) => unapprovedItem !== item);\n }\n });\n onUnapprovedItemsChange(newUnapprovedItems);\n};\n\n/**\n * Function that creates the status column for inventories. Should be used with the DataTable\n * component.\n *\n * @param statusLabel Localized label for the status column\n * @param approvedItems Array of approved items, typically as defined in `Settings.xml`\n * @param onApprovedItemsChange Callback function that stores the updated list of approved items\n * @param unapprovedItems Array of unapproved items, typically as defined in `Settings.xml`\n * @param onUnapprovedItemsChange Callback function that stores the updated list of unapproved items\n * @returns Column that shows the status buttons for the related inventory item. The button for the\n * current status of the item is selected\n */\nexport const inventoryStatusColumn = (\n statusLabel: string,\n approvedItems: string[],\n onApprovedItemsChange: (items: string[]) => void,\n unapprovedItems: string[],\n onUnapprovedItemsChange: (items: string[]) => void,\n): ColumnDef => {\n return {\n accessorKey: 'status',\n header: ({ column }) => {\n return (\n
    \n \n
    \n );\n },\n cell: ({ row }) => {\n const status: Status = row.getValue('status');\n const item: string = row.getValue('item');\n return (\n \n \n statusChangeHandler(\n [item],\n 'approved',\n approvedItems,\n onApprovedItemsChange,\n unapprovedItems,\n onUnapprovedItemsChange,\n )\n }\n value=\"approved\"\n >\n \n \n \n statusChangeHandler(\n [item],\n 'unapproved',\n approvedItems,\n onApprovedItemsChange,\n unapprovedItems,\n onUnapprovedItemsChange,\n )\n }\n value=\"unapproved\"\n >\n \n \n \n statusChangeHandler(\n [item],\n 'unknown',\n approvedItems,\n onApprovedItemsChange,\n unapprovedItems,\n onUnapprovedItemsChange,\n )\n }\n value=\"unknown\"\n >\n \n \n \n );\n },\n };\n};\n","import DataTable, {\n ColumnDef,\n RowContents,\n RowSelectionState,\n TableContents,\n} from '@/components/advanced/data-table/data-table.component';\nimport OccurrencesTable from '@/components/advanced/inventory/occurrences-table.component';\nimport Checkbox from '@/components/shadcn-ui/checkbox';\nimport { Input } from '@/components/shadcn-ui/input';\nimport { Label } from '@/components/shadcn-ui/label';\nimport {\n Select,\n SelectContent,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\nimport {\n deepEqual,\n LocalizedStringValue,\n ScriptureReference,\n substring,\n} from 'platform-bible-utils';\nimport { useEffect, useMemo, useState } from 'react';\nimport {\n getBookNumFromId,\n getLinesFromUSFM,\n getNumberFromUSFM,\n getStatusForItem,\n InventoryItemOccurrence,\n InventoryTableData,\n Status,\n} from './inventory-utils';\nimport { inventoryAdditionalItemColumn } from './inventory-columns';\n\n/**\n * Object containing all keys used for localization in this component. If you're using this\n * component in an extension, you can pass it into the useLocalizedStrings hook to easily obtain the\n * localized strings and pass them into the localizedStrings prop of this component\n */\nexport const INVENTORY_STRING_KEYS = Object.freeze([\n '%webView_inventory_all%',\n '%webView_inventory_approved%',\n '%webView_inventory_unapproved%',\n '%webView_inventory_unknown%',\n '%webView_inventory_scope_currentBook%',\n '%webView_inventory_scope_chapter%',\n '%webView_inventory_scope_verse%',\n '%webView_inventory_filter_text%',\n '%webView_inventory_show_additional_items%',\n '%webView_inventory_occurrences_table_header_reference%',\n '%webView_inventory_occurrences_table_header_occurrence%',\n] as const);\n\nexport type InventoryLocalizedStrings = {\n [localizedInventoryKey in (typeof INVENTORY_STRING_KEYS)[number]]?: LocalizedStringValue;\n};\n\n/** Scope of scripture that the inventory can operate on */\nexport type Scope = 'book' | 'chapter' | 'verse';\n\n/** Status values that the status filter can select from */\ntype StatusFilter = Status | 'all';\n\n/** Text labels for the inventory columns and the control components of additional inventory items */\ntype AdditionalItemsLabels = {\n checkboxText?: string;\n tableHeaders?: string[];\n};\n\n/**\n * Filters data that is shown in the DataTable section of the Inventory\n *\n * @param itemData All inventory items and their related information\n * @param statusFilter Allows filtering by status (i.e. show all items, or only items that are\n * 'approved', 'unapproved' or 'unknown')\n * @param textFilter Allows filtering by text. All items that include the filter text will be\n * selected.\n * @returns Array of items and their related information that are matched by the specified filters\n */\nconst filterItemData = (\n itemData: InventoryTableData[],\n statusFilter: StatusFilter,\n textFilter: string,\n): InventoryTableData[] => {\n let filteredItemData: InventoryTableData[] = itemData;\n\n if (statusFilter !== 'all') {\n filteredItemData = filteredItemData.filter(\n (item) =>\n (statusFilter === 'approved' && item.status === 'approved') ||\n (statusFilter === 'unapproved' && item.status === 'unapproved') ||\n (statusFilter === 'unknown' && item.status === 'unknown'),\n );\n }\n\n if (textFilter !== '')\n filteredItemData = filteredItemData.filter((item) => item.items[0].includes(textFilter));\n\n return filteredItemData;\n};\n\n/**\n * Turns array of strings into array of inventory items, along with their count and status\n *\n * @param text The source scripture text that is searched for inventory items\n * @param scriptureRef The scripture reference that the application is currently set to\n * @param approvedItems Array of approved items, typically as defined in `Settings.xml`\n * @param unapprovedItems Array of unapproved items, typically as defined in `Settings.xml`\n * @param itemRegex Regular expression that describes what items this Inventory should extract from\n * the provided scripture text\n * @returns Array of inventory items, along with their count and status\n */\nconst createTableData = (\n text: string | undefined,\n scriptureRef: ScriptureReference,\n approvedItems: string[],\n unapprovedItems: string[],\n itemRegex: RegExp,\n): InventoryTableData[] => {\n if (!text) return [];\n\n const tableData: InventoryTableData[] = [];\n\n let currentBook: number | undefined = scriptureRef.bookNum;\n let currentChapter: number | undefined = scriptureRef.chapterNum;\n let currentVerse: number | undefined = scriptureRef.verseNum;\n\n const lines = getLinesFromUSFM(text);\n\n lines.forEach((line: string) => {\n if (line.startsWith('\\\\id')) {\n currentBook = getBookNumFromId(line);\n currentChapter = 0;\n currentVerse = 0;\n }\n if (line.startsWith('\\\\c')) {\n currentChapter = getNumberFromUSFM(line);\n currentVerse = 0;\n }\n if (line.startsWith('\\\\v')) {\n currentVerse = getNumberFromUSFM(line);\n if (currentChapter === 0) {\n currentChapter = scriptureRef.chapterNum;\n }\n }\n\n let match: RegExpExecArray | undefined = itemRegex.exec(line) ?? undefined;\n while (match) {\n const items: string[] = [];\n match.forEach((item) => items.push(item));\n const itemIndex = match.index;\n const existingItem = tableData.find((tableEntry) => deepEqual(tableEntry.items, items));\n const newReference: InventoryItemOccurrence = {\n reference: {\n bookNum: currentBook !== undefined ? currentBook : -1,\n chapterNum: currentChapter !== undefined ? currentChapter : -1,\n verseNum: currentVerse !== undefined ? currentVerse : -1,\n },\n text: substring(line, Math.max(0, itemIndex - 25), Math.min(itemIndex + 25, line.length)),\n };\n if (existingItem) {\n existingItem.count += 1;\n existingItem.occurrences.push(newReference);\n } else {\n const newItem: InventoryTableData = {\n items,\n count: 1,\n status: getStatusForItem(items[0], approvedItems, unapprovedItems),\n occurrences: [newReference],\n };\n tableData.push(newItem);\n }\n\n match = itemRegex.exec(line) ?? undefined;\n }\n });\n\n return tableData;\n};\n\n/**\n * Gets the localized value for the provided key\n *\n * @param strings Object containing localized string\n * @param key Key for a localized string\n * @returns The localized value for the provided key, if available. Returns the key if no localized\n * value is available\n */\nconst localizeString = (\n strings: InventoryLocalizedStrings,\n key: keyof InventoryLocalizedStrings,\n) => {\n return strings[key] ?? key;\n};\n\n/** Props for the Inventory component */\ntype InventoryProps = {\n /** The scripture reference that the application is currently set to */\n scriptureReference: ScriptureReference;\n /** Callback function that is executed when the scripture reference is changed */\n setScriptureReference: (scriptureReference: ScriptureReference) => void;\n /**\n * Object with all localized strings that the Inventory needs to work well across multiple\n * languages. When using this component with Platform.Bible, you can import\n * `INVENTORY_STRING_KEYS` from this library, pass it in to the Platform's localization hook, and\n * pass the localized keys that are returned by the hook into this prop.\n */\n localizedStrings: InventoryLocalizedStrings;\n /**\n * The logic that finds the desired items in the source text. This can either be a Regular\n * expression that captures one or multiple items (preferred), or a custom function that builds\n * and return an InventoryDataTable[] manually. Note: In case the logic captures more than one\n * item (i.e. InventoryTableData.items has a length greater than 1), you must provide text labels\n * for the related columns and control elements to show by setting the `additionalItemsLabels`\n * prop\n */\n extractItems:\n | RegExp\n | ((\n text: string | undefined,\n scriptureRef: ScriptureReference,\n approvedItems: string[],\n unapprovedItems: string[],\n ) => InventoryTableData[]);\n /**\n * Text labels for control elements and additional column headers in case your Inventory has more\n * than one item to show (e.g. The 'Preceding Marker' in the Markers Inventory)\n */\n additionalItemsLabels?: AdditionalItemsLabels;\n /** Array of approved items, typically as defined in `Settings.xml` */\n approvedItems: string[];\n /** Array of unapproved items, typically as defined in `Settings.xml` */\n unapprovedItems: string[];\n /** The source scripture text that is searched for in inventory items */\n text: string | undefined;\n /** Scope of scripture that the inventory will operate on */\n scope: Scope;\n /** Callback function that is executed when the scope is changed from the Inventory */\n onScopeChange: (scope: Scope) => void;\n /**\n * Column definitions for the Inventory data table. The most commonly used column definitions are\n * pre-configured for your convenience and can be imported (e.g. inventoryItemColumn,\n * inventoryAdditionalItemColumn inventoryCountColumn, and inventoryStatusColumn). If you need any\n * other columns you can add these yourself\n */\n columns: ColumnDef[];\n};\n\n/** Inventory component that is used to view and control the status of provided project settings */\nexport default function Inventory({\n scriptureReference,\n setScriptureReference,\n localizedStrings,\n extractItems,\n additionalItemsLabels,\n approvedItems,\n unapprovedItems,\n text,\n scope,\n onScopeChange,\n columns,\n}: InventoryProps) {\n const allItemsText = localizeString(localizedStrings, '%webView_inventory_all%');\n const approvedItemsText = localizeString(localizedStrings, '%webView_inventory_approved%');\n const unapprovedItemsText = localizeString(localizedStrings, '%webView_inventory_unapproved%');\n const unknownItemsText = localizeString(localizedStrings, '%webView_inventory_unknown%');\n const scopeBookText = localizeString(localizedStrings, '%webView_inventory_scope_currentBook%');\n const scopeChapterText = localizeString(localizedStrings, '%webView_inventory_scope_chapter%');\n const scopeVerseText = localizeString(localizedStrings, '%webView_inventory_scope_verse%');\n const filterText = localizeString(localizedStrings, '%webView_inventory_filter_text%');\n const showAdditionalItemsText = localizeString(\n localizedStrings,\n '%webView_inventory_show_additional_items%',\n );\n\n const [showAdditionalItems, setShowAdditionalItems] = useState(false);\n const [statusFilter, setStatusFilter] = useState('all');\n const [textFilter, setTextFilter] = useState('');\n const [selectedItem, setSelectedItem] = useState([]);\n\n const tableData: InventoryTableData[] = useMemo(() => {\n if (!text) return [];\n if (extractItems instanceof RegExp)\n return createTableData(\n text,\n scriptureReference,\n approvedItems,\n unapprovedItems,\n extractItems,\n );\n return extractItems(text, scriptureReference, approvedItems, unapprovedItems);\n }, [text, extractItems, scriptureReference, approvedItems, unapprovedItems]);\n\n const reducedTableData: InventoryTableData[] = useMemo(() => {\n if (showAdditionalItems) return tableData;\n\n const newTableData: InventoryTableData[] = [];\n\n tableData.forEach((tableEntry) => {\n const firstItem = tableEntry.items[0];\n\n const existingEntry = newTableData.find(\n (newTableEntry) => newTableEntry.items[0] === firstItem,\n );\n\n if (existingEntry) {\n existingEntry.count += tableEntry.count;\n existingEntry.occurrences = existingEntry.occurrences.concat(tableEntry.occurrences);\n } else {\n newTableData.push({\n items: [firstItem],\n count: tableEntry.count,\n occurrences: tableEntry.occurrences,\n status: tableEntry.status,\n });\n }\n });\n\n return newTableData;\n }, [showAdditionalItems, tableData]);\n\n const filteredTableData: InventoryTableData[] = useMemo(() => {\n return filterItemData(reducedTableData, statusFilter, textFilter);\n }, [reducedTableData, statusFilter, textFilter]);\n\n const allColumns: ColumnDef[] = useMemo(() => {\n if (!showAdditionalItems) return columns;\n\n const numberOfAdditionalItems = additionalItemsLabels?.tableHeaders?.length;\n if (!numberOfAdditionalItems) return columns;\n\n const additionalColumns: ColumnDef[] = [];\n\n for (let index = 0; index < numberOfAdditionalItems; index++) {\n additionalColumns.push(\n inventoryAdditionalItemColumn(\n additionalItemsLabels?.tableHeaders?.[index] || 'Additional Item',\n index + 1,\n ),\n );\n }\n\n return [...additionalColumns, ...columns];\n }, [additionalItemsLabels?.tableHeaders, columns, showAdditionalItems]);\n\n useEffect(() => {\n setSelectedItem([]);\n }, [filteredTableData]);\n\n const rowClickHandler = (\n row: RowContents,\n table: TableContents,\n ) => {\n table.setRowSelection(() => {\n const newSelection: RowSelectionState = {};\n newSelection[row.index] = true;\n return newSelection;\n });\n\n setSelectedItem(row.original.items);\n };\n\n const handleScopeChange = (value: string) => {\n if (value === 'book' || value === 'chapter' || value === 'verse') {\n onScopeChange(value);\n } else {\n throw new Error(`Invalid scope value: ${value}`);\n }\n };\n\n const handleStatusFilterChange = (value: string) => {\n if (value === 'all' || value === 'approved' || value === 'unapproved' || value === 'unknown') {\n setStatusFilter(value);\n } else {\n throw new Error(`Invalid status filter value: ${value}`);\n }\n };\n\n const occurrenceData: InventoryItemOccurrence[] = useMemo(() => {\n if (reducedTableData.length === 0 || selectedItem.length === 0) return [];\n const occurrence = reducedTableData.filter((tableEntry: InventoryTableData) => {\n return deepEqual(\n showAdditionalItems ? tableEntry.items : [tableEntry.items[0]],\n selectedItem,\n );\n });\n if (occurrence.length > 1) throw new Error('Selected item is not unique');\n return occurrence[0].occurrences;\n }, [selectedItem, showAdditionalItems, reducedTableData]);\n\n return (\n
    \n
    \n handleStatusFilterChange(value)}\n defaultValue={statusFilter}\n >\n \n \n \n \n {allItemsText}\n {approvedItemsText}\n {unapprovedItemsText}\n {unknownItemsText}\n \n \n \n {\n setTextFilter(event.target.value);\n }}\n />\n {additionalItemsLabels && (\n
    \n {\n setSelectedItem([]);\n setShowAdditionalItems(checked);\n }}\n />\n \n
    \n )}\n
    \n
    \n \n
    \n {occurrenceData.length > 0 && (\n
    \n \n
    \n )}\n
    \n );\n}\n","import { Input } from '@/components/shadcn-ui/input';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { useState } from 'react';\n\nexport type SearchBarProps = {\n className?: string;\n /**\n * Callback fired to handle the search query when button pressed\n *\n * @param searchQuery\n */\n onSearch: (searchQuery: string) => void;\n\n /** Optional string that appears in the search bar without a search string */\n placeholder?: string;\n\n /** Optional boolean to set the input base to full width */\n isFullWidth?: boolean;\n};\n\nexport default function SearchBar({\n className,\n onSearch,\n placeholder,\n isFullWidth,\n}: SearchBarProps) {\n const [searchQuery, setSearchQuery] = useState('');\n\n const handleInputChange = (searchString: string) => {\n setSearchQuery(searchString);\n onSearch(searchString);\n };\n\n return (\n handleInputChange(e.target.value)}\n />\n );\n}\n","// adapted from: https://github.com/shadcn-ui/ui/discussions/752\n\n'use client';\n\nimport { TabsContentProps, TabsListProps, TabsTriggerProps } from '@/components/shadcn-ui/tabs';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport * as TabsPrimitive from '@radix-ui/react-tabs';\nimport React from 'react';\n\nexport type VerticalTabsProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport type LeftTabsTriggerProps = TabsTriggerProps & {\n value: string;\n ref?: React.Ref;\n};\n\nexport const VerticalTabs = React.forwardRef<\n React.ElementRef,\n VerticalTabsProps\n>(({ className, ...props }, ref) => (\n \n));\n\nVerticalTabs.displayName = TabsPrimitive.List.displayName;\n\nexport const VerticalTabsList = React.forwardRef<\n React.ElementRef,\n TabsListProps\n>(({ className, ...props }, ref) => (\n \n));\nVerticalTabsList.displayName = TabsPrimitive.List.displayName;\n\nexport const VerticalTabsTrigger = React.forwardRef<\n React.ElementRef,\n LeftTabsTriggerProps\n>(({ className, ...props }, ref) => (\n \n));\n\nexport const VerticalTabsContent = React.forwardRef<\n React.ElementRef,\n TabsContentProps\n>(({ className, ...props }, ref) => (\n \n));\nVerticalTabsContent.displayName = TabsPrimitive.Content.displayName;\n","import SearchBar from '@/components/basics/search-bar.component';\nimport {\n VerticalTabs,\n VerticalTabsContent,\n VerticalTabsList,\n VerticalTabsTrigger,\n} from '@/components/basics/tabs-vertical';\nimport { ReactNode } from 'react';\n\nexport type TabKeyValueContent = {\n key: string;\n value: string;\n content: ReactNode;\n};\n\nexport type TabNavigationContentSearchProps = {\n /** List of values and keys for each tab this component should provide */\n tabList: TabKeyValueContent[];\n\n /** Handler to run when the value of the search bar changes */\n onSearch: (searchQuery: string) => void;\n\n /** Optional placeholder for the search bar */\n searchPlaceholder?: string;\n\n /** Optional title to include in the header */\n headerTitle?: string;\n\n /** Optional flag to make the search bar appear full width */\n isSearchBarFullWidth?: boolean;\n\n /** Text direction ltr or rtl */\n direction?: 'ltr' | 'rtl';\n};\n\nexport default function TabNavigationContentSearch({\n tabList,\n onSearch,\n searchPlaceholder,\n headerTitle,\n isSearchBarFullWidth = false,\n direction = 'ltr',\n}: TabNavigationContentSearchProps) {\n return (\n
    \n
    \n {headerTitle ?

    {headerTitle}

    : ''}\n \n
    \n \n \n {tabList.map((tab) => (\n \n {tab.value}\n \n ))}\n \n {tabList.map((tab) => (\n \n {tab.content}\n \n ))}\n \n
    \n );\n}\n","import React from 'react';\nimport * as SeparatorPrimitive from '@radix-ui/react-separator';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Separator = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, orientation = 'horizontal', decorative = true, ...props }, ref) => (\n \n));\nSeparator.displayName = SeparatorPrimitive.Root.displayName;\n\nexport { Separator };\n","'use client';\n\nimport * as React from 'react';\nimport * as SheetPrimitive from '@radix-ui/react-dialog';\nimport { cva, type VariantProps } from 'class-variance-authority';\nimport { X } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Sheet = SheetPrimitive.Root;\n\nconst SheetTrigger = SheetPrimitive.Trigger;\n\nconst SheetClose = SheetPrimitive.Close;\n\nconst SheetPortal = SheetPrimitive.Portal;\n\nconst SheetOverlay = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSheetOverlay.displayName = SheetPrimitive.Overlay.displayName;\n\nconst sheetVariants = cva(\n 'pr-twp tw-fixed tw-z-50 tw-gap-4 tw-bg-background tw-p-6 tw-shadow-lg tw-transition tw-ease-in-out data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-duration-300 data-[state=open]:tw-duration-500',\n {\n variants: {\n side: {\n top: 'tw-inset-x-0 tw-top-0 tw-border-b data-[state=closed]:tw-slide-out-to-top data-[state=open]:tw-slide-in-from-top',\n bottom:\n 'tw-inset-x-0 tw-bottom-0 tw-border-t data-[state=closed]:tw-slide-out-to-bottom data-[state=open]:tw-slide-in-from-bottom',\n left: 'tw-inset-y-0 tw-left-0 tw-h-full tw-w-3/4 tw-border-r data-[state=closed]:tw-slide-out-to-left data-[state=open]:tw-slide-in-from-left sm:tw-max-w-sm',\n right:\n 'tw-inset-y-0 tw-right-0 tw-h-full tw-w-3/4 tw- tw-border-l data-[state=closed]:tw-slide-out-to-right data-[state=open]:tw-slide-in-from-right sm:tw-max-w-sm',\n },\n },\n defaultVariants: {\n side: 'right',\n },\n },\n);\n\ninterface SheetContentProps\n extends React.ComponentPropsWithoutRef,\n VariantProps {}\n\nconst SheetContent = React.forwardRef<\n React.ElementRef,\n SheetContentProps\n>(({ side = 'right', className, children, ...props }, ref) => (\n \n \n \n {children}\n \n \n Close\n \n \n \n));\nSheetContent.displayName = SheetPrimitive.Content.displayName;\n\nfunction SheetHeader({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nSheetHeader.displayName = 'SheetHeader';\n\nfunction SheetFooter({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nSheetFooter.displayName = 'SheetFooter';\n\nconst SheetTitle = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSheetTitle.displayName = SheetPrimitive.Title.displayName;\n\nconst SheetDescription = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSheetDescription.displayName = SheetPrimitive.Description.displayName;\n\nexport {\n Sheet,\n SheetPortal,\n SheetOverlay,\n SheetTrigger,\n SheetClose,\n SheetContent,\n SheetHeader,\n SheetFooter,\n SheetTitle,\n SheetDescription,\n};\n","import React from 'react';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nfunction Skeleton({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\n\nexport { Skeleton };\n","import React from 'react';\nimport * as TooltipPrimitive from '@radix-ui/react-tooltip';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst TooltipProvider = TooltipPrimitive.Provider;\n\nconst Tooltip = TooltipPrimitive.Root;\n\nconst TooltipTrigger = TooltipPrimitive.Trigger;\n\nconst TooltipContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, sideOffset = 4, ...props }, ref) => (\n \n));\nTooltipContent.displayName = TooltipPrimitive.Content.displayName;\n\nexport { Tooltip, TooltipTrigger, TooltipContent, TooltipProvider };\n","import * as React from 'react';\n\nconst MOBILE_BREAKPOINT = 768;\n\nexport default function useIsMobile() {\n const [isMobile, setIsMobile] = React.useState(undefined);\n\n React.useEffect(() => {\n const mql = window.matchMedia(`(max-width: ${MOBILE_BREAKPOINT - 1}px)`);\n const onChange = () => {\n setIsMobile(window.innerWidth < MOBILE_BREAKPOINT);\n };\n mql.addEventListener('change', onChange);\n setIsMobile(window.innerWidth < MOBILE_BREAKPOINT);\n return () => mql.removeEventListener('change', onChange);\n }, []);\n\n return !!isMobile;\n}\n","import React from 'react';\nimport { Slot } from '@radix-ui/react-slot';\nimport { VariantProps, cva } from 'class-variance-authority';\nimport { PanelLeft } from 'lucide-react';\n\nimport { Button } from '@/components/shadcn-ui/button';\nimport { Input } from '@/components/shadcn-ui/input';\nimport { Separator } from '@/components/shadcn-ui/separator';\nimport { Sheet, SheetContent } from '@/components/shadcn-ui/sheet';\nimport { Skeleton } from '@/components/shadcn-ui/skeleton';\nimport {\n Tooltip,\n TooltipContent,\n TooltipProvider,\n TooltipTrigger,\n} from '@/components/shadcn-ui/tooltip';\nimport useIsMobile from '@/components/hooks/use-mobile';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst SIDEBAR_COOKIE_NAME = 'sidebar:state';\nconst SIDEBAR_COOKIE_MAX_AGE = 60 * 60 * 24 * 7;\nconst SIDEBAR_WIDTH = '16rem';\nconst SIDEBAR_WIDTH_MOBILE = '18rem';\nconst SIDEBAR_WIDTH_ICON = '3rem';\nconst SIDEBAR_KEYBOARD_SHORTCUT = 'b';\n\ntype SidebarContextProps = {\n state: 'expanded' | 'collapsed';\n open: boolean;\n setOpen: (open: boolean) => void;\n openMobile: boolean;\n setOpenMobile: (open: boolean) => void;\n isMobile: boolean;\n toggleSidebar: () => void;\n};\n\nconst SidebarContext = React.createContext(undefined);\n\nfunction useSidebar() {\n const context = React.useContext(SidebarContext);\n if (!context) {\n throw new Error('useSidebar must be used within a SidebarProvider.');\n }\n\n return context;\n}\n\nconst SidebarProvider = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & {\n defaultOpen?: boolean;\n open?: boolean;\n onOpenChange?: (open: boolean) => void;\n }\n>(\n (\n {\n defaultOpen = true,\n open: openProp,\n onOpenChange: setOpenProp,\n className,\n style,\n children,\n ...props\n },\n ref,\n ) => {\n const isMobile = useIsMobile();\n const [openMobile, setOpenMobile] = React.useState(false);\n\n // This is the internal state of the sidebar.\n // We use openProp and setOpenProp for control from outside the component.\n const [_open, _setOpen] = React.useState(defaultOpen);\n const isOpen = openProp ?? _open;\n const setOpen = React.useCallback(\n (value: boolean | ((value: boolean) => boolean)) => {\n const openState = typeof value === 'function' ? value(isOpen) : value;\n if (setOpenProp) {\n setOpenProp(openState);\n } else {\n _setOpen(openState);\n }\n\n // This sets the cookie to keep the sidebar state.\n document.cookie = `${SIDEBAR_COOKIE_NAME}=${openState}; path=/; max-age=${SIDEBAR_COOKIE_MAX_AGE}`;\n },\n [setOpenProp, isOpen],\n );\n\n // Helper to toggle the sidebar.\n const toggleSidebar = React.useCallback(() => {\n return isMobile ? setOpenMobile((open) => !open) : setOpen((open) => !open);\n }, [isMobile, setOpen, setOpenMobile]);\n\n // Adds a keyboard shortcut to toggle the sidebar.\n React.useEffect(() => {\n const handleKeyDown = (event: KeyboardEvent) => {\n if (event.key === SIDEBAR_KEYBOARD_SHORTCUT && (event.metaKey || event.ctrlKey)) {\n event.preventDefault();\n toggleSidebar();\n }\n };\n\n window.addEventListener('keydown', handleKeyDown);\n return () => window.removeEventListener('keydown', handleKeyDown);\n }, [toggleSidebar]);\n\n // We add a state so that we can do data-state=\"expanded\" or \"collapsed\".\n // This makes it easier to style the sidebar with Tailwind classes.\n const state = isOpen ? 'expanded' : 'collapsed';\n\n const contextValue = React.useMemo(\n () => ({\n state,\n open: isOpen,\n setOpen,\n isMobile,\n openMobile,\n setOpenMobile,\n toggleSidebar,\n }),\n [state, isOpen, setOpen, isMobile, openMobile, setOpenMobile, toggleSidebar],\n );\n\n return (\n \n \n \n {children}\n
    \n \n \n );\n },\n);\nSidebarProvider.displayName = 'SidebarProvider';\n\nconst Sidebar = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & {\n side?: 'left' | 'right';\n variant?: 'sidebar' | 'floating' | 'inset';\n collapsible?: 'offcanvas' | 'icon' | 'none';\n }\n>(\n (\n {\n side = 'left',\n variant = 'sidebar',\n collapsible = 'offcanvas',\n className,\n children,\n ...props\n },\n ref,\n ) => {\n const { isMobile, state, openMobile, setOpenMobile } = useSidebar();\n\n if (collapsible === 'none') {\n return (\n \n {children}\n
    \n );\n }\n\n if (isMobile) {\n return (\n \n button]:tw-hidden\"\n style={\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n {\n '--sidebar-width': SIDEBAR_WIDTH_MOBILE,\n } as React.CSSProperties\n }\n side={side}\n >\n
    {children}
    \n \n
    \n );\n }\n\n return (\n \n {/* This is what handles the sidebar gap on desktop */}\n \n \n \n {children}\n
    \n
    \n
    \n );\n },\n);\nSidebar.displayName = 'Sidebar';\n\nconst SidebarTrigger = React.forwardRef<\n React.ElementRef,\n React.ComponentProps\n>(({ className, onClick, ...props }, ref) => {\n const { toggleSidebar } = useSidebar();\n\n return (\n {\n onClick?.(event);\n toggleSidebar();\n }}\n {...props}\n >\n \n Toggle Sidebar\n \n );\n});\nSidebarTrigger.displayName = 'SidebarTrigger';\n\nconst SidebarRail = React.forwardRef>(\n ({ className, ...props }, ref) => {\n const { toggleSidebar } = useSidebar();\n\n return (\n \n );\n },\n);\nSidebarRail.displayName = 'SidebarRail';\n\nconst SidebarInset = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarInset.displayName = 'SidebarInset';\n\nconst SidebarInput = React.forwardRef<\n React.ElementRef,\n React.ComponentProps\n>(({ className, ...props }, ref) => {\n return (\n \n );\n});\nSidebarInput.displayName = 'SidebarInput';\n\nconst SidebarHeader = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarHeader.displayName = 'SidebarHeader';\n\nconst SidebarFooter = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarFooter.displayName = 'SidebarFooter';\n\nconst SidebarSeparator = React.forwardRef<\n React.ElementRef,\n React.ComponentProps\n>(({ className, ...props }, ref) => {\n return (\n \n );\n});\nSidebarSeparator.displayName = 'SidebarSeparator';\n\nconst SidebarContent = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarContent.displayName = 'SidebarContent';\n\nconst SidebarGroup = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarGroup.displayName = 'SidebarGroup';\n\nconst SidebarGroupLabel = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & { asChild?: boolean }\n>(({ className, asChild = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'div';\n\n return (\n svg]:tw-size-4 [&>svg]:tw-shrink-0',\n 'group-data-[collapsible=icon]:tw--mt-8 group-data-[collapsible=icon]:tw-opacity-0',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarGroupLabel.displayName = 'SidebarGroupLabel';\n\nconst SidebarGroupAction = React.forwardRef<\n HTMLButtonElement,\n React.ComponentProps<'button'> & { asChild?: boolean }\n>(({ className, asChild = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'button';\n\n return (\n svg]:tw-size-4 [&>svg]:tw-shrink-0',\n // Increases the hit area of the button on mobile.\n 'after:tw-absolute after:tw--inset-2 after:md:tw-hidden',\n 'group-data-[collapsible=icon]:tw-hidden',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarGroupAction.displayName = 'SidebarGroupAction';\n\nconst SidebarGroupContent = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarGroupContent.displayName = 'SidebarGroupContent';\n\nconst SidebarMenu = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenu.displayName = 'SidebarMenu';\n\nconst SidebarMenuItem = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenuItem.displayName = 'SidebarMenuItem';\n\nconst sidebarMenuButtonVariants = cva(\n // Removed data-[active=true]:tw-bg-sidebar-accent\n 'tw-peer/menu-button tw-flex tw-w-full tw-items-center tw-gap-2 tw-overflow-hidden tw-rounded-md tw-p-2 tw-text-left tw-text-sm tw-outline-none tw-ring-sidebar-ring tw-transition-[width,height,padding] hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground focus-visible:tw-ring-2 active:tw-bg-sidebar-accent active:tw-text-sidebar-accent-foreground disabled:tw-pointer-events-none disabled:tw-opacity-50 tw-group-has-[[data-sidebar=menu-action]]/menu-item:pr-8 aria-disabled:tw-pointer-events-none aria-disabled:tw-opacity-50 data-[active=true]:tw-font-medium data-[active=true]:tw-text-sidebar-accent-foreground data-[state=open]:hover:tw-bg-sidebar-accent data-[state=open]:hover:tw-text-sidebar-accent-foreground group-data-[collapsible=icon]:tw-!size-8 group-data-[collapsible=icon]:tw-!p-2 [&>span:last-child]:tw-truncate [&>svg]:tw-size-4 [&>svg]:tw-shrink-0',\n {\n variants: {\n variant: {\n default: 'hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground',\n outline:\n 'tw-bg-background tw-shadow-[0_0_0_1px_hsl(var(--sidebar-border))] hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground hover:tw-shadow-[0_0_0_1px_hsl(var(--sidebar-accent))]',\n },\n size: {\n default: 'tw-h-8 tw-text-sm',\n sm: 'tw-h-7 tw-text-xs',\n lg: 'tw-h-12 tw-text-sm group-data-[collapsible=icon]:tw-!p-0',\n },\n },\n defaultVariants: {\n variant: 'default',\n size: 'default',\n },\n },\n);\n\nconst SidebarMenuButton = React.forwardRef<\n HTMLButtonElement,\n React.ComponentProps<'button'> & {\n asChild?: boolean;\n isActive?: boolean;\n tooltip?: string | React.ComponentProps;\n } & VariantProps\n>(\n (\n {\n asChild = false,\n isActive = false,\n variant = 'default',\n size = 'default',\n tooltip,\n className,\n ...props\n },\n ref,\n ) => {\n const Comp = asChild ? Slot : 'button';\n const { isMobile, state } = useSidebar();\n\n const button = (\n \n );\n\n if (!tooltip) {\n return button;\n }\n\n if (typeof tooltip === 'string') {\n // eslint-disable-next-line no-param-reassign\n tooltip = {\n children: tooltip,\n };\n }\n\n return (\n \n {button}\n \n );\n },\n);\nSidebarMenuButton.displayName = 'SidebarMenuButton';\n\nconst SidebarMenuAction = React.forwardRef<\n HTMLButtonElement,\n React.ComponentProps<'button'> & {\n asChild?: boolean;\n showOnHover?: boolean;\n }\n>(({ className, asChild = false, showOnHover = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'button';\n\n return (\n svg]:tw-size-4 [&>svg]:tw-shrink-0',\n // Increases the hit area of the button on mobile.\n 'after:tw-absolute after:tw--inset-2 after:md:tw-hidden',\n 'tw-peer-data-[size=sm]/menu-button:top-1',\n 'tw-peer-data-[size=default]/menu-button:top-1.5',\n 'tw-peer-data-[size=lg]/menu-button:top-2.5',\n 'group-data-[collapsible=icon]:tw-hidden',\n showOnHover &&\n 'tw-group-focus-within/menu-item:opacity-100 tw-group-hover/menu-item:opacity-100 tw-peer-data-[active=true]/menu-button:text-sidebar-accent-foreground data-[state=open]:tw-opacity-100 md:tw-opacity-0',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarMenuAction.displayName = 'SidebarMenuAction';\n\nconst SidebarMenuBadge = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenuBadge.displayName = 'SidebarMenuBadge';\n\nconst SidebarMenuSkeleton = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & {\n showIcon?: boolean;\n }\n>(({ className, showIcon = false, ...props }, ref) => {\n // Random width between 50 to 90%.\n const width = React.useMemo(() => {\n return `${Math.floor(Math.random() * 40) + 50}%`;\n }, []);\n\n return (\n \n {showIcon && (\n \n )}\n \n
    \n );\n});\nSidebarMenuSkeleton.displayName = 'SidebarMenuSkeleton';\n\nconst SidebarMenuSub = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenuSub.displayName = 'SidebarMenuSub';\n\nconst SidebarMenuSubItem = React.forwardRef>(\n ({ ...props }, ref) =>
  • ,\n);\nSidebarMenuSubItem.displayName = 'SidebarMenuSubItem';\n\nconst SidebarMenuSubButton = React.forwardRef<\n HTMLAnchorElement,\n React.ComponentProps<'a'> & {\n asChild?: boolean;\n size?: 'sm' | 'md';\n isActive?: boolean;\n }\n>(({ asChild = false, size = 'md', isActive, className, ...props }, ref) => {\n const Comp = asChild ? Slot : 'a';\n\n return (\n span:last-child]:tw-truncate [&>svg]:tw-size-4 [&>svg]:tw-shrink-0 [&>svg]:tw-text-sidebar-accent-foreground',\n 'data-[active=true]:tw-bg-sidebar-accent data-[active=true]:tw-text-sidebar-accent-foreground',\n size === 'sm' && 'tw-text-xs',\n size === 'md' && 'tw-text-sm',\n 'group-data-[collapsible=icon]:tw-hidden',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarMenuSubButton.displayName = 'SidebarMenuSubButton';\n\nexport {\n Sidebar,\n SidebarContent,\n SidebarFooter,\n SidebarGroup,\n SidebarGroupAction,\n SidebarGroupContent,\n SidebarGroupLabel,\n SidebarHeader,\n SidebarInput,\n SidebarInset,\n SidebarMenu,\n SidebarMenuAction,\n SidebarMenuBadge,\n SidebarMenuButton,\n SidebarMenuItem,\n SidebarMenuSkeleton,\n SidebarMenuSub,\n SidebarMenuSubButton,\n SidebarMenuSubItem,\n SidebarProvider,\n SidebarRail,\n SidebarSeparator,\n SidebarTrigger,\n useSidebar,\n};\n","import ComboBox, { ComboBoxOption } from '@/components/basics/combo-box.component';\nimport {\n Sidebar,\n SidebarContent,\n SidebarGroup,\n SidebarGroupLabel,\n SidebarGroupContent,\n SidebarMenu,\n SidebarMenuItem,\n SidebarMenuButton,\n} from '@/components/shadcn-ui/sidebar';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { useCallback } from 'react';\n\nexport type SelectedSettingsSidebarItem = {\n label: string;\n projectId?: string;\n};\n\nexport type ProjectOptions = { projectId: string; projectName: string };\n\nexport type SettingsSidebarProps = {\n /** Optional id for testing */\n id?: string;\n\n /** Extension labels from contribution */\n extensionLabels: string[];\n\n /** Project names and ids */\n projectOptions: ProjectOptions[];\n\n /** Handler for selecting a sidebar item */\n handleSelectSidebarItem: (key: string, projectId?: string) => void;\n\n /** The current selected value in the sidebar */\n selectedSidebarItem: SelectedSettingsSidebarItem;\n\n /** Label for the group of extensions setting groups */\n extensionsSidebarGroupLabel: string;\n\n /** Label for the group of projects settings */\n projectsSidebarGroupLabel: string;\n\n /** Placeholder for the button */\n buttonPlaceholder: string;\n};\n\nexport default function SettingsSidebar({\n id,\n extensionLabels,\n projectOptions,\n handleSelectSidebarItem,\n selectedSidebarItem,\n extensionsSidebarGroupLabel,\n projectsSidebarGroupLabel,\n buttonPlaceholder,\n}: SettingsSidebarProps) {\n const handleSelectItem = useCallback(\n (item: string, projectId?: string) => {\n handleSelectSidebarItem(item, projectId);\n },\n [handleSelectSidebarItem],\n );\n\n const getProjectNameFromProjectId = useCallback(\n (projectId: string) => {\n const project = projectOptions.find((option) => option.projectId === projectId);\n return project ? project.projectName : projectId;\n },\n [projectOptions],\n );\n\n const getIsActive: (label: string) => boolean = useCallback(\n (label: string) => !selectedSidebarItem.projectId && label === selectedSidebarItem.label,\n [selectedSidebarItem],\n );\n\n return (\n \n \n \n \n {extensionsSidebarGroupLabel}\n \n \n \n {extensionLabels.map((label) => (\n \n handleSelectItem(label, undefined)}\n isActive={getIsActive(label)}\n >\n {label}\n \n \n ))}\n \n \n \n \n \n {projectsSidebarGroupLabel}\n \n \n option.projectId)}\n getOptionLabel={(projectId: ComboBoxOption) => {\n // This function expects a ComboBoxOption, but we know it is a string\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n return getProjectNameFromProjectId(projectId as string);\n }}\n buttonPlaceholder={buttonPlaceholder}\n onChange={(projectId: string) => {\n const selectedProjectName = getProjectNameFromProjectId(projectId);\n handleSelectItem(selectedProjectName, projectId);\n }}\n value={selectedSidebarItem?.projectId ?? undefined}\n />\n \n \n \n \n );\n}\n","import { SidebarInset, SidebarProvider } from '@/components/shadcn-ui/sidebar';\nimport { PropsWithChildren } from 'react';\nimport SearchBar from '@/components/basics/search-bar.component';\nimport SettingsSidebar, { SettingsSidebarProps } from './settings-sidebar.component';\n\nexport type SettingsSidebarContentSearchProps = SettingsSidebarProps &\n PropsWithChildren & {\n /** Optional id for testing */\n id?: string;\n\n /** Text direction ltr or rtl */\n direction?: 'ltr' | 'rtl';\n\n /** Handler to run when the value of the search bar changes */\n onSearch: (searchQuery: string) => void;\n };\n\nexport default function SettingsSidebarContentSearch({\n id,\n direction = 'ltr',\n extensionLabels,\n projectOptions,\n children,\n handleSelectSidebarItem,\n selectedSidebarItem,\n onSearch,\n extensionsSidebarGroupLabel,\n projectsSidebarGroupLabel,\n buttonPlaceholder,\n}: SettingsSidebarContentSearchProps) {\n return (\n
    \n
    \n \n
    \n \n \n {children}\n \n
    \n );\n}\n","import { Button } from '@/components/shadcn-ui/button';\nimport {\n Select,\n SelectContent,\n SelectGroup,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\nimport {\n Table,\n TableBody,\n TableCell,\n TableHead,\n TableHeader,\n TableRow,\n} from '@/components/shadcn-ui/table';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Canon } from '@sillsdev/scripture';\nimport {\n Cell,\n ColumnDef,\n flexRender,\n getCoreRowModel,\n getExpandedRowModel,\n getGroupedRowModel,\n getSortedRowModel,\n GroupingState,\n Row,\n RowSelectionState,\n SortingState,\n useReactTable,\n} from '@tanstack/react-table';\nimport '@/components/advanced/scripture-results-viewer/scripture-results-viewer.component.css';\nimport {\n compareScrRefs,\n formatScrRef,\n ScriptureSelection,\n scrRefToBBBCCCVVV,\n} from 'platform-bible-utils';\nimport { MouseEvent, useEffect, useMemo, useState } from 'react';\nimport { ChevronDown, ChevronLeft, ChevronRight } from 'lucide-react';\n\n/**\n * Information (e.g., a checking error or some other type of \"transient\" annotation) about something\n * noteworthy at a specific place in an instance of the Scriptures.\n */\nexport type ScriptureItemDetail = ScriptureSelection & {\n /**\n * Text of the error, note, etc. In the future, we might want to support something more than just\n * text so that a JSX element could be provided with a link or some other controls related to the\n * issue being reported.\n */\n detail: string;\n};\n\n/**\n * A uniquely identifiable source of results that can be displayed in the ScriptureResultsViewer.\n * Generally, the source will be a particular Scripture check, but there may be other types of\n * sources.\n */\nexport type ResultsSource = {\n /**\n * Uniquely identifies the source.\n *\n * @type {string}\n */\n id: string;\n\n /**\n * Name (potentially localized) of the source, suitable for display in the UI.\n *\n * @type {string}\n */\n displayName: string;\n};\n\nexport type ScriptureSrcItemDetail = ScriptureItemDetail & {\n /** Source/type of detail. Can be used for grouping. */\n source: ResultsSource;\n};\n\n/**\n * Represents a set of results keyed by Scripture reference. Generally, the source will be a\n * particular Scripture check, but this type also allows for other types of uniquely identifiable\n * sources.\n */\nexport type ResultsSet = {\n /**\n * The backing source associated with this set of results.\n *\n * @type {ResultsSource}\n */\n source: ResultsSource;\n\n /**\n * Array of Scripture item details (messages keyed by Scripture reference).\n *\n * @type {ScriptureItemDetail[]}\n */\n data: ScriptureItemDetail[];\n};\n\nconst scrBookColId = 'scrBook';\nconst scrRefColId = 'scrRef';\nconst typeColId = 'source';\nconst detailsColId = 'details';\n\nconst defaultScrRefColumnName = 'Scripture Reference';\nconst defaultScrBookGroupName = 'Scripture Book';\nconst defaultTypeColumnName = 'Type';\nconst defaultDetailsColumnName = 'Details';\n\nexport type ScriptureResultsViewerColumnInfo = {\n /** Optional header to display for the Reference column. Default value: 'Scripture Reference'. */\n scriptureReferenceColumnName?: string;\n\n /** Optional text to display to refer to the Scripture book group. Default value: 'Scripture Book'. */\n scriptureBookGroupName?: string;\n\n /** Optional header to display for the Type column. Default value: 'Type'. */\n typeColumnName?: string;\n\n /** Optional header to display for the Details column. Default value: 'Details' */\n detailsColumnName?: string;\n};\n\nexport type ScriptureResultsViewerProps = ScriptureResultsViewerColumnInfo & {\n /** Groups of ScriptureItemDetail objects from particular sources (e.g., Scripture checks) */\n sources: ResultsSet[];\n\n /** Flag indicating whether to display column headers. Default is false. */\n showColumnHeaders?: boolean;\n\n /** Flag indicating whether to display source column. Default is false. */\n showSourceColumn?: boolean;\n\n /** Callback function to notify when a row is selected */\n onRowSelected?: (selectedRow: ScriptureSrcItemDetail | undefined) => void;\n\n /** Text direction ltr or rtl */\n direction?: 'ltr' | 'rtl';\n};\n\nfunction getColumns(\n colInfo?: ScriptureResultsViewerColumnInfo,\n showSourceColumn?: boolean,\n): ColumnDef[] {\n const showSrcCol = showSourceColumn ?? false;\n return [\n {\n accessorFn: (row) =>\n `${Canon.bookNumberToId(row.start.bookNum)} ${row.start.chapterNum}:${row.start.verseNum}`,\n id: scrBookColId,\n header: colInfo?.scriptureReferenceColumnName ?? defaultScrRefColumnName,\n cell: (info) => {\n const row = info.row.original;\n if (info.row.getIsGrouped()) {\n return Canon.bookNumberToEnglishName(row.start.bookNum);\n }\n return info.row.groupingColumnId === scrBookColId ? formatScrRef(row.start) : undefined;\n },\n getGroupingValue: (row) => row.start.bookNum,\n sortingFn: (a, b) => {\n return compareScrRefs(a.original.start, b.original.start);\n },\n enableGrouping: true,\n },\n {\n accessorFn: (row) => formatScrRef(row.start),\n id: scrRefColId,\n header: undefined,\n cell: (info) => {\n const row = info.row.original;\n return info.row.getIsGrouped() ? undefined : formatScrRef(row.start);\n },\n sortingFn: (a, b) => {\n return compareScrRefs(a.original.start, b.original.start);\n },\n enableGrouping: false,\n },\n {\n accessorFn: (row) => row.source.displayName,\n id: typeColId,\n header: showSrcCol ? (colInfo?.typeColumnName ?? defaultTypeColumnName) : undefined,\n cell: (info) => (showSrcCol || info.row.getIsGrouped() ? info.getValue() : undefined),\n getGroupingValue: (row) => row.source.id,\n sortingFn: (a, b) =>\n a.original.source.displayName.localeCompare(b.original.source.displayName),\n enableGrouping: true,\n },\n {\n accessorFn: (row) => row.detail,\n id: detailsColId,\n header: colInfo?.detailsColumnName ?? defaultDetailsColumnName,\n cell: (info) => info.getValue(),\n enableGrouping: false,\n },\n ];\n}\n\nconst toRefOrRange = (scriptureSelection: ScriptureSelection) => {\n if (!('offset' in scriptureSelection.start))\n throw new Error('No offset available in range start');\n if (scriptureSelection.end && !('offset' in scriptureSelection.end))\n throw new Error('No offset available in range end');\n const { offset: offsetStart } = scriptureSelection.start;\n let offsetEnd: number = 0;\n if (scriptureSelection.end) ({ offset: offsetEnd } = scriptureSelection.end);\n if (\n !scriptureSelection.end ||\n compareScrRefs(scriptureSelection.start, scriptureSelection.end) === 0\n )\n return `${scrRefToBBBCCCVVV(scriptureSelection.start)}+${offsetStart}`;\n return `${scrRefToBBBCCCVVV(scriptureSelection.start)}+${offsetStart}-${scrRefToBBBCCCVVV(scriptureSelection.end)}+${offsetEnd}`;\n};\n\nconst getRowKey = (row: ScriptureSrcItemDetail) =>\n `${toRefOrRange({ start: row.start, end: row.end })} ${row.source.displayName} ${row.detail}`;\n\n/**\n * Component to display a combined list of detailed items from one or more sources, where the items\n * are keyed primarily by Scripture reference. This is particularly useful for displaying a list of\n * results from Scripture checks, but more generally could be used to display any \"results\" from any\n * source(s). The component allows for grouping by Scripture book, source, or both. By default, it\n * displays somewhat \"tree-like\" which allows it to be more horizontally compact and intuitive. But\n * it also has the option of displaying as a traditional table with column headings (with or without\n * the source column showing).\n */\nexport default function ScriptureResultsViewer({\n sources,\n showColumnHeaders = false,\n showSourceColumn = false,\n scriptureReferenceColumnName,\n scriptureBookGroupName,\n typeColumnName,\n detailsColumnName,\n onRowSelected,\n direction = 'ltr',\n}: ScriptureResultsViewerProps) {\n const [grouping, setGrouping] = useState([]);\n const [sorting, setSorting] = useState([{ id: scrBookColId, desc: false }]);\n const [rowSelection, setRowSelection] = useState({});\n\n const scriptureResults = useMemo(\n () =>\n sources.flatMap((source) => {\n return source.data.map((item) => ({\n ...item,\n source: source.source,\n }));\n }),\n [sources],\n );\n\n const columns = useMemo(\n () =>\n getColumns(\n {\n scriptureReferenceColumnName,\n typeColumnName,\n detailsColumnName,\n },\n showSourceColumn,\n ),\n [scriptureReferenceColumnName, typeColumnName, detailsColumnName, showSourceColumn],\n );\n\n useEffect(() => {\n // Ensure sorting is applied correctly when grouped by type\n if (grouping.includes(typeColId)) {\n setSorting([\n { id: typeColId, desc: false },\n { id: scrBookColId, desc: false },\n ]);\n } else {\n setSorting([{ id: scrBookColId, desc: false }]);\n }\n }, [grouping]);\n\n const table = useReactTable({\n data: scriptureResults,\n columns,\n state: {\n grouping,\n sorting,\n rowSelection,\n },\n onGroupingChange: setGrouping,\n onSortingChange: setSorting,\n onRowSelectionChange: setRowSelection,\n getExpandedRowModel: getExpandedRowModel(),\n getGroupedRowModel: getGroupedRowModel(),\n getCoreRowModel: getCoreRowModel(),\n getSortedRowModel: getSortedRowModel(),\n getRowId: getRowKey,\n autoResetExpanded: false,\n enableMultiRowSelection: false,\n enableSubRowSelection: false,\n });\n\n useEffect(() => {\n if (onRowSelected) {\n const selectedRows = table.getSelectedRowModel().rowsById;\n const keys = Object.keys(selectedRows);\n if (keys.length === 1) {\n const selectedRow = scriptureResults.find((row) => getRowKey(row) === keys[0]) || undefined;\n if (selectedRow) onRowSelected(selectedRow);\n }\n }\n }, [rowSelection, scriptureResults, onRowSelected, table]);\n\n // Define possible grouping options\n const scrBookGroupName = scriptureBookGroupName ?? defaultScrBookGroupName;\n const typeGroupName = typeColumnName ?? defaultTypeColumnName;\n\n const groupingOptions = [\n { label: 'No Grouping', value: [] },\n { label: `Group by ${scrBookGroupName}`, value: [scrBookColId] },\n { label: `Group by ${typeGroupName}`, value: [typeColId] },\n {\n label: `Group by ${scrBookGroupName} and ${typeGroupName}`,\n value: [scrBookColId, typeColId],\n },\n {\n label: `Group by ${typeGroupName} and ${scrBookGroupName}`,\n value: [typeColId, scrBookColId],\n },\n ];\n\n const handleSelectChange = (selectedGrouping: string) => {\n setGrouping(JSON.parse(selectedGrouping));\n };\n\n const handleRowClick = (row: Row, event: MouseEvent) => {\n if (!row.getIsGrouped() && !row.getIsSelected()) {\n row.getToggleSelectedHandler()(event);\n }\n };\n\n const getEvenOrOddBandingStyle = (row: Row, index: number) => {\n if (row.getIsGrouped()) return '';\n // UX has now said they don't think they want banding. I'm leaving in the code to\n // set even and odd styles, but there's nothing in the CSS to style them differently.\n // The \"even\" style used to also have tw-bg-neutral-300 (along with even) to create\n // a visual banding effect. That could be added back in if UX changes the decision.\n return cn('banded-row', index % 2 === 0 ? 'even' : 'odd');\n };\n\n const getIndent = (\n groupingState: GroupingState,\n row: Row,\n cell: Cell,\n ) => {\n if (groupingState?.length === 0 || row.depth < cell.column.getGroupedIndex()) return undefined;\n if (row.getIsGrouped()) {\n switch (row.depth) {\n case 1:\n return 'tw-ps-4';\n default:\n return undefined;\n }\n }\n switch (row.depth) {\n case 1:\n return 'tw-ps-8';\n case 2:\n return 'tw-ps-12';\n default:\n return undefined;\n }\n };\n\n return (\n
    \n {!showColumnHeaders && (\n {\n handleSelectChange(value);\n }}\n >\n \n \n \n \n \n {groupingOptions.map((option) => (\n \n {option.label}\n \n ))}\n \n \n \n )}\n \n {showColumnHeaders && (\n \n {table.getHeaderGroups().map((headerGroup) => (\n \n {headerGroup.headers\n .filter((h) => h.column.columnDef.header)\n .map((header) => (\n /* For sticky column headers to work, we probably need to change the default definition of the shadcn Table component. See https://github.com/shadcn-ui/ui/issues/1151 */\n \n {header.isPlaceholder ? undefined : (\n
    \n {header.column.getCanGroup() ? (\n \n {header.column.getIsGrouped() ? `🛑` : `👊 `}\n \n ) : undefined}{' '}\n {flexRender(header.column.columnDef.header, header.getContext())}\n
    \n )}\n
    \n ))}\n
    \n ))}\n
    \n )}\n \n {table.getRowModel().rows.map((row, rowIndex) => {\n return (\n handleRowClick(row, event)}\n >\n {row.getVisibleCells().map((cell) => {\n if (\n cell.getIsPlaceholder() ||\n (cell.column.columnDef.enableGrouping &&\n !cell.getIsGrouped() &&\n (cell.column.columnDef.id !== typeColId || !showSourceColumn))\n )\n return undefined;\n return (\n \n {(() => {\n if (cell.getIsGrouped()) {\n return (\n \n {row.getIsExpanded() && }\n {!row.getIsExpanded() &&\n (direction === 'ltr' ? : )}{' '}\n {flexRender(cell.column.columnDef.cell, cell.getContext())} (\n {row.subRows.length})\n \n );\n }\n\n // if (cell.getIsAggregated()) {\n // flexRender(\n // cell.column.columnDef.aggregatedCell ?? cell.column.columnDef.cell,\n // cell.getContext(),\n // );\n // }\n\n return flexRender(cell.column.columnDef.cell, cell.getContext());\n })()}\n \n );\n })}\n \n );\n })}\n \n
    \n
    \n );\n}\n","import {\n getLocalizeKeyForScrollGroupId,\n LanguageStrings,\n ScrollGroupId,\n} from 'platform-bible-utils';\nimport {\n Select,\n SelectContent,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\n\nconst DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS = {\n [getLocalizeKeyForScrollGroupId('undefined')]: 'Ø',\n [getLocalizeKeyForScrollGroupId(0)]: 'A',\n [getLocalizeKeyForScrollGroupId(1)]: 'B',\n [getLocalizeKeyForScrollGroupId(2)]: 'C',\n [getLocalizeKeyForScrollGroupId(3)]: 'D',\n [getLocalizeKeyForScrollGroupId(4)]: 'E',\n [getLocalizeKeyForScrollGroupId(5)]: 'F',\n [getLocalizeKeyForScrollGroupId(6)]: 'G',\n [getLocalizeKeyForScrollGroupId(7)]: 'H',\n [getLocalizeKeyForScrollGroupId(8)]: 'I',\n [getLocalizeKeyForScrollGroupId(9)]: 'J',\n [getLocalizeKeyForScrollGroupId(10)]: 'K',\n [getLocalizeKeyForScrollGroupId(11)]: 'L',\n [getLocalizeKeyForScrollGroupId(12)]: 'M',\n [getLocalizeKeyForScrollGroupId(13)]: 'N',\n [getLocalizeKeyForScrollGroupId(14)]: 'O',\n [getLocalizeKeyForScrollGroupId(15)]: 'P',\n [getLocalizeKeyForScrollGroupId(16)]: 'Q',\n [getLocalizeKeyForScrollGroupId(17)]: 'R',\n [getLocalizeKeyForScrollGroupId(18)]: 'S',\n [getLocalizeKeyForScrollGroupId(19)]: 'T',\n [getLocalizeKeyForScrollGroupId(20)]: 'U',\n [getLocalizeKeyForScrollGroupId(21)]: 'V',\n [getLocalizeKeyForScrollGroupId(22)]: 'W',\n [getLocalizeKeyForScrollGroupId(23)]: 'X',\n [getLocalizeKeyForScrollGroupId(24)]: 'Y',\n [getLocalizeKeyForScrollGroupId(25)]: 'Z',\n};\n\nexport type ScrollGroupSelectorProps = {\n /**\n * List of scroll group ids to show to the user. Either a {@link ScrollGroupId} or `undefined` for\n * no scroll group\n */\n availableScrollGroupIds: (ScrollGroupId | undefined)[];\n /** Currently selected scroll group id. `undefined` for no scroll group */\n scrollGroupId: ScrollGroupId | undefined;\n /** Callback function run when the user tries to change the scroll group id */\n onChangeScrollGroupId: (newScrollGroupId: ScrollGroupId | undefined) => void;\n /**\n * Localized strings to use for displaying scroll group ids. Must be an object whose keys are\n * `getLocalizeKeyForScrollGroupId(scrollGroupId)` for all scroll group ids (and `undefined` if\n * included) in {@link ScrollGroupSelectorProps.availableScrollGroupIds} and whose values are the\n * localized strings to use for those scroll group ids.\n *\n * Defaults to English localizations of English alphabet for scroll groups 0-25 (e.g. 0 is A) and\n * Ø for `undefined`. Will fill in any that are not provided with these English localizations.\n * Also, if any values match the keys, the English localization will be used. This is useful in\n * case you want to pass in a temporary version of the localized strings while your localized\n * strings load.\n *\n * @example\n *\n * ```typescript\n * const myScrollGroupIdLocalizedStrings = {\n * [getLocalizeKeyForScrollGroupId('undefined')]: 'Ø',\n * [getLocalizeKeyForScrollGroupId(0)]: 'A',\n * [getLocalizeKeyForScrollGroupId(1)]: 'B',\n * [getLocalizeKeyForScrollGroupId(2)]: 'C',\n * [getLocalizeKeyForScrollGroupId(3)]: 'D',\n * [getLocalizeKeyForScrollGroupId(4)]: 'E',\n * };\n * ```\n *\n * @example\n *\n * ```tsx\n * const availableScrollGroupIds = [undefined, 0, 1, 2, 3, 4];\n *\n * const localizeKeys = getLocalizeKeysForScrollGroupIds();\n *\n * const [localizedStrings] = useLocalizedStrings(localizeKeys);\n *\n * ...\n *\n * \n * ```\n */\n localizedStrings?: LanguageStrings;\n};\n\n/** Selector component for choosing a scroll group */\nexport default function ScrollGroupSelector({\n availableScrollGroupIds,\n scrollGroupId,\n onChangeScrollGroupId,\n localizedStrings = {},\n}: ScrollGroupSelectorProps) {\n const localizedStringsDefaulted = {\n ...DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS,\n ...Object.fromEntries(\n Object.entries(localizedStrings).map(\n ([localizedStringKey, localizedStringValue]: [string, string]) => [\n localizedStringKey,\n localizedStringKey === localizedStringValue &&\n localizedStringKey in DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS\n ? DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS[localizedStringKey]\n : localizedStringValue,\n ],\n ),\n ),\n };\n return (\n \n onChangeScrollGroupId(\n newScrollGroupString === 'undefined' ? undefined : parseInt(newScrollGroupString, 10),\n )\n }\n >\n \n \n \n \n {availableScrollGroupIds.map((scrollGroupOptionId) => (\n \n {localizedStringsDefaulted[getLocalizeKeyForScrollGroupId(scrollGroupOptionId)]}\n \n ))}\n \n \n );\n}\n","import { PropsWithChildren } from 'react';\nimport { Separator } from '@/components/shadcn-ui/separator';\n\n/** Props for the SettingsList component, currently just children */\ntype SettingsListProps = PropsWithChildren;\n\n/**\n * SettingsList component is a wrapper for list items. Rendered with a formatted div\n *\n * @param children To populate the list with\n * @returns Formatted div encompassing the children\n */\nexport function SettingsList({ children }: SettingsListProps) {\n return
    {children}
    ;\n}\n\n/** Props for SettingsListItem component */\ntype SettingsListItemProps = PropsWithChildren & {\n /** Primary text of the list item */\n primary: string;\n\n /** Optional text of the list item */\n secondary?: string | undefined;\n\n /** Optional boolean to display a message if the children aren't loaded yet. Defaults to false */\n isLoading?: boolean;\n\n /** Optional message to display if isLoading */\n loadingMessage?: string;\n};\n\n/**\n * SettingsListItem component is a common list item. Rendered with a formatted div\n *\n * @param primary Primary text of the list item\n * @param secondary Optional secondary text of the list item\n * @param isLoading Optional, to display a message if the action component isn't generated yet,\n * defaults to false\n * @param children The action component(s) to provide for this item\n * @param loadingMessage Optional, message to display if isLoading\n * @returns Formatted div encompassing the list item content\n */\nexport function SettingsListItem({\n primary,\n secondary,\n children,\n isLoading = false,\n loadingMessage,\n}: SettingsListItemProps) {\n return (\n
    \n
    \n

    {primary}

    \n

    \n {secondary}\n

    \n
    \n\n {isLoading ? (\n

    {loadingMessage}

    \n ) : (\n
    {children}
    \n )}\n
    \n );\n}\n\n/** Props for SettingsListHeader component */\ntype SettingsListHeaderProps = {\n /** The primary text of the list header */\n primary: string;\n\n /** Optional secondary text of the list header */\n secondary?: string | undefined;\n\n /** Optional boolean to include a separator underneath the secondary text. Defaults to false */\n includeSeparator?: boolean;\n};\n\n/**\n * SettingsListHeader component displays text above the list\n *\n * @param primary The primary text of the list header\n * @param secondary Optional secondary text of the list header\n * @param includeSeparator Optional boolean to include a separator underneath the secondary text.\n * Defaults to false\n * @returns Formatted div with list header content\n */\nexport function SettingsListHeader({\n primary,\n secondary,\n includeSeparator = false,\n}: SettingsListHeaderProps) {\n return (\n
    \n
    \n

    {primary}

    \n

    {secondary}

    \n
    \n {includeSeparator ? : ''}\n
    \n );\n}\n","import Checkbox from '@/components/shadcn-ui/checkbox';\nimport { Label } from '@/components/shadcn-ui/label';\n\nexport type ChecklistProps = {\n /** Optional string representing the id attribute of the Checklist */\n id?: string;\n /** Optional string representing CSS class name(s) for styling */\n className?: string;\n /** Array of strings representing the checkable items */\n listItems: string[];\n /** Array of strings representing the checked items */\n selectedListItems: string[];\n /**\n * Function that is called when a checkbox item is selected or deselected\n *\n * @param item The string description for this item\n * @param selected True if selected, false if not selected\n */\n handleSelectListItem: (item: string, selected: boolean) => void;\n\n /**\n * Optional function creates a label for a provided checkable item\n *\n * @param item The item for which a label is to be created\n * @returns A string representing the label text for the checkbox associated with that item\n */\n createLabel?: (item: string) => string;\n};\n\n/** Renders a list of checkboxes. Each checkbox corresponds to an item from the `listItems` array. */\nexport default function Checklist({\n id,\n className,\n listItems,\n selectedListItems,\n handleSelectListItem,\n createLabel,\n}: ChecklistProps) {\n return (\n
    \n {listItems.map((item) => (\n
    \n handleSelectListItem(item, value)}\n />\n \n
    \n ))}\n
    \n );\n}\n","function _interopRequireDefault(obj) {\n return obj && obj.__esModule ? obj : {\n \"default\": obj\n };\n}\nmodule.exports = _interopRequireDefault, module.exports.__esModule = true, module.exports[\"default\"] = module.exports;","export default function chainPropTypes(propType1, propType2) {\n if (process.env.NODE_ENV === 'production') {\n return () => null;\n }\n return function validate(...args) {\n return propType1(...args) || propType2(...args);\n };\n}","export default function _extends() {\n _extends = Object.assign ? Object.assign.bind() : function (target) {\n for (var i = 1; i < arguments.length; i++) {\n var source = arguments[i];\n for (var key in source) {\n if (Object.prototype.hasOwnProperty.call(source, key)) {\n target[key] = source[key];\n }\n }\n }\n return target;\n };\n return _extends.apply(this, arguments);\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\n// https://github.com/sindresorhus/is-plain-obj/blob/main/index.js\nexport function isPlainObject(item) {\n if (typeof item !== 'object' || item === null) {\n return false;\n }\n const prototype = Object.getPrototypeOf(item);\n return (prototype === null || prototype === Object.prototype || Object.getPrototypeOf(prototype) === null) && !(Symbol.toStringTag in item) && !(Symbol.iterator in item);\n}\nfunction deepClone(source) {\n if (!isPlainObject(source)) {\n return source;\n }\n const output = {};\n Object.keys(source).forEach(key => {\n output[key] = deepClone(source[key]);\n });\n return output;\n}\nexport default function deepmerge(target, source, options = {\n clone: true\n}) {\n const output = options.clone ? _extends({}, target) : target;\n if (isPlainObject(target) && isPlainObject(source)) {\n Object.keys(source).forEach(key => {\n // Avoid prototype pollution\n if (key === '__proto__') {\n return;\n }\n if (isPlainObject(source[key]) && key in target && isPlainObject(target[key])) {\n // Since `output` is a clone of `target` and we have narrowed `target` in this block we can cast to the same type.\n output[key] = deepmerge(target[key], source[key], options);\n } else if (options.clone) {\n output[key] = isPlainObject(source[key]) ? deepClone(source[key]) : source[key];\n } else {\n output[key] = source[key];\n }\n });\n }\n return output;\n}","/** @license React v16.13.1\n * react-is.production.min.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';var b=\"function\"===typeof Symbol&&Symbol.for,c=b?Symbol.for(\"react.element\"):60103,d=b?Symbol.for(\"react.portal\"):60106,e=b?Symbol.for(\"react.fragment\"):60107,f=b?Symbol.for(\"react.strict_mode\"):60108,g=b?Symbol.for(\"react.profiler\"):60114,h=b?Symbol.for(\"react.provider\"):60109,k=b?Symbol.for(\"react.context\"):60110,l=b?Symbol.for(\"react.async_mode\"):60111,m=b?Symbol.for(\"react.concurrent_mode\"):60111,n=b?Symbol.for(\"react.forward_ref\"):60112,p=b?Symbol.for(\"react.suspense\"):60113,q=b?\nSymbol.for(\"react.suspense_list\"):60120,r=b?Symbol.for(\"react.memo\"):60115,t=b?Symbol.for(\"react.lazy\"):60116,v=b?Symbol.for(\"react.block\"):60121,w=b?Symbol.for(\"react.fundamental\"):60117,x=b?Symbol.for(\"react.responder\"):60118,y=b?Symbol.for(\"react.scope\"):60119;\nfunction z(a){if(\"object\"===typeof a&&null!==a){var u=a.$$typeof;switch(u){case c:switch(a=a.type,a){case l:case m:case e:case g:case f:case p:return a;default:switch(a=a&&a.$$typeof,a){case k:case n:case t:case r:case h:return a;default:return u}}case d:return u}}}function A(a){return z(a)===m}exports.AsyncMode=l;exports.ConcurrentMode=m;exports.ContextConsumer=k;exports.ContextProvider=h;exports.Element=c;exports.ForwardRef=n;exports.Fragment=e;exports.Lazy=t;exports.Memo=r;exports.Portal=d;\nexports.Profiler=g;exports.StrictMode=f;exports.Suspense=p;exports.isAsyncMode=function(a){return A(a)||z(a)===l};exports.isConcurrentMode=A;exports.isContextConsumer=function(a){return z(a)===k};exports.isContextProvider=function(a){return z(a)===h};exports.isElement=function(a){return\"object\"===typeof a&&null!==a&&a.$$typeof===c};exports.isForwardRef=function(a){return z(a)===n};exports.isFragment=function(a){return z(a)===e};exports.isLazy=function(a){return z(a)===t};\nexports.isMemo=function(a){return z(a)===r};exports.isPortal=function(a){return z(a)===d};exports.isProfiler=function(a){return z(a)===g};exports.isStrictMode=function(a){return z(a)===f};exports.isSuspense=function(a){return z(a)===p};\nexports.isValidElementType=function(a){return\"string\"===typeof a||\"function\"===typeof a||a===e||a===m||a===g||a===f||a===p||a===q||\"object\"===typeof a&&null!==a&&(a.$$typeof===t||a.$$typeof===r||a.$$typeof===h||a.$$typeof===k||a.$$typeof===n||a.$$typeof===w||a.$$typeof===x||a.$$typeof===y||a.$$typeof===v)};exports.typeOf=z;\n","/** @license React v16.13.1\n * react-is.development.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\n\n\nif (process.env.NODE_ENV !== \"production\") {\n (function() {\n'use strict';\n\n// The Symbol used to tag the ReactElement-like types. If there is no native Symbol\n// nor polyfill, then a plain number is used for performance.\nvar hasSymbol = typeof Symbol === 'function' && Symbol.for;\nvar REACT_ELEMENT_TYPE = hasSymbol ? Symbol.for('react.element') : 0xeac7;\nvar REACT_PORTAL_TYPE = hasSymbol ? Symbol.for('react.portal') : 0xeaca;\nvar REACT_FRAGMENT_TYPE = hasSymbol ? Symbol.for('react.fragment') : 0xeacb;\nvar REACT_STRICT_MODE_TYPE = hasSymbol ? Symbol.for('react.strict_mode') : 0xeacc;\nvar REACT_PROFILER_TYPE = hasSymbol ? Symbol.for('react.profiler') : 0xead2;\nvar REACT_PROVIDER_TYPE = hasSymbol ? Symbol.for('react.provider') : 0xeacd;\nvar REACT_CONTEXT_TYPE = hasSymbol ? Symbol.for('react.context') : 0xeace; // TODO: We don't use AsyncMode or ConcurrentMode anymore. They were temporary\n// (unstable) APIs that have been removed. Can we remove the symbols?\n\nvar REACT_ASYNC_MODE_TYPE = hasSymbol ? Symbol.for('react.async_mode') : 0xeacf;\nvar REACT_CONCURRENT_MODE_TYPE = hasSymbol ? Symbol.for('react.concurrent_mode') : 0xeacf;\nvar REACT_FORWARD_REF_TYPE = hasSymbol ? Symbol.for('react.forward_ref') : 0xead0;\nvar REACT_SUSPENSE_TYPE = hasSymbol ? Symbol.for('react.suspense') : 0xead1;\nvar REACT_SUSPENSE_LIST_TYPE = hasSymbol ? Symbol.for('react.suspense_list') : 0xead8;\nvar REACT_MEMO_TYPE = hasSymbol ? Symbol.for('react.memo') : 0xead3;\nvar REACT_LAZY_TYPE = hasSymbol ? Symbol.for('react.lazy') : 0xead4;\nvar REACT_BLOCK_TYPE = hasSymbol ? Symbol.for('react.block') : 0xead9;\nvar REACT_FUNDAMENTAL_TYPE = hasSymbol ? Symbol.for('react.fundamental') : 0xead5;\nvar REACT_RESPONDER_TYPE = hasSymbol ? Symbol.for('react.responder') : 0xead6;\nvar REACT_SCOPE_TYPE = hasSymbol ? Symbol.for('react.scope') : 0xead7;\n\nfunction isValidElementType(type) {\n return typeof type === 'string' || typeof type === 'function' || // Note: its typeof might be other than 'symbol' or 'number' if it's a polyfill.\n type === REACT_FRAGMENT_TYPE || type === REACT_CONCURRENT_MODE_TYPE || type === REACT_PROFILER_TYPE || type === REACT_STRICT_MODE_TYPE || type === REACT_SUSPENSE_TYPE || type === REACT_SUSPENSE_LIST_TYPE || typeof type === 'object' && type !== null && (type.$$typeof === REACT_LAZY_TYPE || type.$$typeof === REACT_MEMO_TYPE || type.$$typeof === REACT_PROVIDER_TYPE || type.$$typeof === REACT_CONTEXT_TYPE || type.$$typeof === REACT_FORWARD_REF_TYPE || type.$$typeof === REACT_FUNDAMENTAL_TYPE || type.$$typeof === REACT_RESPONDER_TYPE || type.$$typeof === REACT_SCOPE_TYPE || type.$$typeof === REACT_BLOCK_TYPE);\n}\n\nfunction typeOf(object) {\n if (typeof object === 'object' && object !== null) {\n var $$typeof = object.$$typeof;\n\n switch ($$typeof) {\n case REACT_ELEMENT_TYPE:\n var type = object.type;\n\n switch (type) {\n case REACT_ASYNC_MODE_TYPE:\n case REACT_CONCURRENT_MODE_TYPE:\n case REACT_FRAGMENT_TYPE:\n case REACT_PROFILER_TYPE:\n case REACT_STRICT_MODE_TYPE:\n case REACT_SUSPENSE_TYPE:\n return type;\n\n default:\n var $$typeofType = type && type.$$typeof;\n\n switch ($$typeofType) {\n case REACT_CONTEXT_TYPE:\n case REACT_FORWARD_REF_TYPE:\n case REACT_LAZY_TYPE:\n case REACT_MEMO_TYPE:\n case REACT_PROVIDER_TYPE:\n return $$typeofType;\n\n default:\n return $$typeof;\n }\n\n }\n\n case REACT_PORTAL_TYPE:\n return $$typeof;\n }\n }\n\n return undefined;\n} // AsyncMode is deprecated along with isAsyncMode\n\nvar AsyncMode = REACT_ASYNC_MODE_TYPE;\nvar ConcurrentMode = REACT_CONCURRENT_MODE_TYPE;\nvar ContextConsumer = REACT_CONTEXT_TYPE;\nvar ContextProvider = REACT_PROVIDER_TYPE;\nvar Element = REACT_ELEMENT_TYPE;\nvar ForwardRef = REACT_FORWARD_REF_TYPE;\nvar Fragment = REACT_FRAGMENT_TYPE;\nvar Lazy = REACT_LAZY_TYPE;\nvar Memo = REACT_MEMO_TYPE;\nvar Portal = REACT_PORTAL_TYPE;\nvar Profiler = REACT_PROFILER_TYPE;\nvar StrictMode = REACT_STRICT_MODE_TYPE;\nvar Suspense = REACT_SUSPENSE_TYPE;\nvar hasWarnedAboutDeprecatedIsAsyncMode = false; // AsyncMode should be deprecated\n\nfunction isAsyncMode(object) {\n {\n if (!hasWarnedAboutDeprecatedIsAsyncMode) {\n hasWarnedAboutDeprecatedIsAsyncMode = true; // Using console['warn'] to evade Babel and ESLint\n\n console['warn']('The ReactIs.isAsyncMode() alias has been deprecated, ' + 'and will be removed in React 17+. Update your code to use ' + 'ReactIs.isConcurrentMode() instead. It has the exact same API.');\n }\n }\n\n return isConcurrentMode(object) || typeOf(object) === REACT_ASYNC_MODE_TYPE;\n}\nfunction isConcurrentMode(object) {\n return typeOf(object) === REACT_CONCURRENT_MODE_TYPE;\n}\nfunction isContextConsumer(object) {\n return typeOf(object) === REACT_CONTEXT_TYPE;\n}\nfunction isContextProvider(object) {\n return typeOf(object) === REACT_PROVIDER_TYPE;\n}\nfunction isElement(object) {\n return typeof object === 'object' && object !== null && object.$$typeof === REACT_ELEMENT_TYPE;\n}\nfunction isForwardRef(object) {\n return typeOf(object) === REACT_FORWARD_REF_TYPE;\n}\nfunction isFragment(object) {\n return typeOf(object) === REACT_FRAGMENT_TYPE;\n}\nfunction isLazy(object) {\n return typeOf(object) === REACT_LAZY_TYPE;\n}\nfunction isMemo(object) {\n return typeOf(object) === REACT_MEMO_TYPE;\n}\nfunction isPortal(object) {\n return typeOf(object) === REACT_PORTAL_TYPE;\n}\nfunction isProfiler(object) {\n return typeOf(object) === REACT_PROFILER_TYPE;\n}\nfunction isStrictMode(object) {\n return typeOf(object) === REACT_STRICT_MODE_TYPE;\n}\nfunction isSuspense(object) {\n return typeOf(object) === REACT_SUSPENSE_TYPE;\n}\n\nexports.AsyncMode = AsyncMode;\nexports.ConcurrentMode = ConcurrentMode;\nexports.ContextConsumer = ContextConsumer;\nexports.ContextProvider = ContextProvider;\nexports.Element = Element;\nexports.ForwardRef = ForwardRef;\nexports.Fragment = Fragment;\nexports.Lazy = Lazy;\nexports.Memo = Memo;\nexports.Portal = Portal;\nexports.Profiler = Profiler;\nexports.StrictMode = StrictMode;\nexports.Suspense = Suspense;\nexports.isAsyncMode = isAsyncMode;\nexports.isConcurrentMode = isConcurrentMode;\nexports.isContextConsumer = isContextConsumer;\nexports.isContextProvider = isContextProvider;\nexports.isElement = isElement;\nexports.isForwardRef = isForwardRef;\nexports.isFragment = isFragment;\nexports.isLazy = isLazy;\nexports.isMemo = isMemo;\nexports.isPortal = isPortal;\nexports.isProfiler = isProfiler;\nexports.isStrictMode = isStrictMode;\nexports.isSuspense = isSuspense;\nexports.isValidElementType = isValidElementType;\nexports.typeOf = typeOf;\n })();\n}\n","'use strict';\n\nif (process.env.NODE_ENV === 'production') {\n module.exports = require('./cjs/react-is.production.min.js');\n} else {\n module.exports = require('./cjs/react-is.development.js');\n}\n","/*\nobject-assign\n(c) Sindre Sorhus\n@license MIT\n*/\n\n'use strict';\n/* eslint-disable no-unused-vars */\nvar getOwnPropertySymbols = Object.getOwnPropertySymbols;\nvar hasOwnProperty = Object.prototype.hasOwnProperty;\nvar propIsEnumerable = Object.prototype.propertyIsEnumerable;\n\nfunction toObject(val) {\n\tif (val === null || val === undefined) {\n\t\tthrow new TypeError('Object.assign cannot be called with null or undefined');\n\t}\n\n\treturn Object(val);\n}\n\nfunction shouldUseNative() {\n\ttry {\n\t\tif (!Object.assign) {\n\t\t\treturn false;\n\t\t}\n\n\t\t// Detect buggy property enumeration order in older V8 versions.\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=4118\n\t\tvar test1 = new String('abc'); // eslint-disable-line no-new-wrappers\n\t\ttest1[5] = 'de';\n\t\tif (Object.getOwnPropertyNames(test1)[0] === '5') {\n\t\t\treturn false;\n\t\t}\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=3056\n\t\tvar test2 = {};\n\t\tfor (var i = 0; i < 10; i++) {\n\t\t\ttest2['_' + String.fromCharCode(i)] = i;\n\t\t}\n\t\tvar order2 = Object.getOwnPropertyNames(test2).map(function (n) {\n\t\t\treturn test2[n];\n\t\t});\n\t\tif (order2.join('') !== '0123456789') {\n\t\t\treturn false;\n\t\t}\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=3056\n\t\tvar test3 = {};\n\t\t'abcdefghijklmnopqrst'.split('').forEach(function (letter) {\n\t\t\ttest3[letter] = letter;\n\t\t});\n\t\tif (Object.keys(Object.assign({}, test3)).join('') !==\n\t\t\t\t'abcdefghijklmnopqrst') {\n\t\t\treturn false;\n\t\t}\n\n\t\treturn true;\n\t} catch (err) {\n\t\t// We don't expect any of the above to throw, but better to be safe.\n\t\treturn false;\n\t}\n}\n\nmodule.exports = shouldUseNative() ? Object.assign : function (target, source) {\n\tvar from;\n\tvar to = toObject(target);\n\tvar symbols;\n\n\tfor (var s = 1; s < arguments.length; s++) {\n\t\tfrom = Object(arguments[s]);\n\n\t\tfor (var key in from) {\n\t\t\tif (hasOwnProperty.call(from, key)) {\n\t\t\t\tto[key] = from[key];\n\t\t\t}\n\t\t}\n\n\t\tif (getOwnPropertySymbols) {\n\t\t\tsymbols = getOwnPropertySymbols(from);\n\t\t\tfor (var i = 0; i < symbols.length; i++) {\n\t\t\t\tif (propIsEnumerable.call(from, symbols[i])) {\n\t\t\t\t\tto[symbols[i]] = from[symbols[i]];\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\n\treturn to;\n};\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar ReactPropTypesSecret = 'SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED';\n\nmodule.exports = ReactPropTypesSecret;\n","module.exports = Function.call.bind(Object.prototype.hasOwnProperty);\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar printWarning = function() {};\n\nif (process.env.NODE_ENV !== 'production') {\n var ReactPropTypesSecret = require('./lib/ReactPropTypesSecret');\n var loggedTypeFailures = {};\n var has = require('./lib/has');\n\n printWarning = function(text) {\n var message = 'Warning: ' + text;\n if (typeof console !== 'undefined') {\n console.error(message);\n }\n try {\n // --- Welcome to debugging React ---\n // This error was thrown as a convenience so that you can use this stack\n // to find the callsite that caused this warning to fire.\n throw new Error(message);\n } catch (x) { /**/ }\n };\n}\n\n/**\n * Assert that the values match with the type specs.\n * Error messages are memorized and will only be shown once.\n *\n * @param {object} typeSpecs Map of name to a ReactPropType\n * @param {object} values Runtime values that need to be type-checked\n * @param {string} location e.g. \"prop\", \"context\", \"child context\"\n * @param {string} componentName Name of the component for error messages.\n * @param {?Function} getStack Returns the component stack.\n * @private\n */\nfunction checkPropTypes(typeSpecs, values, location, componentName, getStack) {\n if (process.env.NODE_ENV !== 'production') {\n for (var typeSpecName in typeSpecs) {\n if (has(typeSpecs, typeSpecName)) {\n var error;\n // Prop type validation may throw. In case they do, we don't want to\n // fail the render phase where it didn't fail before. So we log it.\n // After these have been cleaned up, we'll let them throw.\n try {\n // This is intentionally an invariant that gets caught. It's the same\n // behavior as without this statement except with a better message.\n if (typeof typeSpecs[typeSpecName] !== 'function') {\n var err = Error(\n (componentName || 'React class') + ': ' + location + ' type `' + typeSpecName + '` is invalid; ' +\n 'it must be a function, usually from the `prop-types` package, but received `' + typeof typeSpecs[typeSpecName] + '`.' +\n 'This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.'\n );\n err.name = 'Invariant Violation';\n throw err;\n }\n error = typeSpecs[typeSpecName](values, typeSpecName, componentName, location, null, ReactPropTypesSecret);\n } catch (ex) {\n error = ex;\n }\n if (error && !(error instanceof Error)) {\n printWarning(\n (componentName || 'React class') + ': type specification of ' +\n location + ' `' + typeSpecName + '` is invalid; the type checker ' +\n 'function must return `null` or an `Error` but returned a ' + typeof error + '. ' +\n 'You may have forgotten to pass an argument to the type checker ' +\n 'creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and ' +\n 'shape all require an argument).'\n );\n }\n if (error instanceof Error && !(error.message in loggedTypeFailures)) {\n // Only monitor this failure once because there tends to be a lot of the\n // same error.\n loggedTypeFailures[error.message] = true;\n\n var stack = getStack ? getStack() : '';\n\n printWarning(\n 'Failed ' + location + ' type: ' + error.message + (stack != null ? stack : '')\n );\n }\n }\n }\n }\n}\n\n/**\n * Resets warning cache when testing.\n *\n * @private\n */\ncheckPropTypes.resetWarningCache = function() {\n if (process.env.NODE_ENV !== 'production') {\n loggedTypeFailures = {};\n }\n}\n\nmodule.exports = checkPropTypes;\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar ReactIs = require('react-is');\nvar assign = require('object-assign');\n\nvar ReactPropTypesSecret = require('./lib/ReactPropTypesSecret');\nvar has = require('./lib/has');\nvar checkPropTypes = require('./checkPropTypes');\n\nvar printWarning = function() {};\n\nif (process.env.NODE_ENV !== 'production') {\n printWarning = function(text) {\n var message = 'Warning: ' + text;\n if (typeof console !== 'undefined') {\n console.error(message);\n }\n try {\n // --- Welcome to debugging React ---\n // This error was thrown as a convenience so that you can use this stack\n // to find the callsite that caused this warning to fire.\n throw new Error(message);\n } catch (x) {}\n };\n}\n\nfunction emptyFunctionThatReturnsNull() {\n return null;\n}\n\nmodule.exports = function(isValidElement, throwOnDirectAccess) {\n /* global Symbol */\n var ITERATOR_SYMBOL = typeof Symbol === 'function' && Symbol.iterator;\n var FAUX_ITERATOR_SYMBOL = '@@iterator'; // Before Symbol spec.\n\n /**\n * Returns the iterator method function contained on the iterable object.\n *\n * Be sure to invoke the function with the iterable as context:\n *\n * var iteratorFn = getIteratorFn(myIterable);\n * if (iteratorFn) {\n * var iterator = iteratorFn.call(myIterable);\n * ...\n * }\n *\n * @param {?object} maybeIterable\n * @return {?function}\n */\n function getIteratorFn(maybeIterable) {\n var iteratorFn = maybeIterable && (ITERATOR_SYMBOL && maybeIterable[ITERATOR_SYMBOL] || maybeIterable[FAUX_ITERATOR_SYMBOL]);\n if (typeof iteratorFn === 'function') {\n return iteratorFn;\n }\n }\n\n /**\n * Collection of methods that allow declaration and validation of props that are\n * supplied to React components. Example usage:\n *\n * var Props = require('ReactPropTypes');\n * var MyArticle = React.createClass({\n * propTypes: {\n * // An optional string prop named \"description\".\n * description: Props.string,\n *\n * // A required enum prop named \"category\".\n * category: Props.oneOf(['News','Photos']).isRequired,\n *\n * // A prop named \"dialog\" that requires an instance of Dialog.\n * dialog: Props.instanceOf(Dialog).isRequired\n * },\n * render: function() { ... }\n * });\n *\n * A more formal specification of how these methods are used:\n *\n * type := array|bool|func|object|number|string|oneOf([...])|instanceOf(...)\n * decl := ReactPropTypes.{type}(.isRequired)?\n *\n * Each and every declaration produces a function with the same signature. This\n * allows the creation of custom validation functions. For example:\n *\n * var MyLink = React.createClass({\n * propTypes: {\n * // An optional string or URI prop named \"href\".\n * href: function(props, propName, componentName) {\n * var propValue = props[propName];\n * if (propValue != null && typeof propValue !== 'string' &&\n * !(propValue instanceof URI)) {\n * return new Error(\n * 'Expected a string or an URI for ' + propName + ' in ' +\n * componentName\n * );\n * }\n * }\n * },\n * render: function() {...}\n * });\n *\n * @internal\n */\n\n var ANONYMOUS = '<>';\n\n // Important!\n // Keep this list in sync with production version in `./factoryWithThrowingShims.js`.\n var ReactPropTypes = {\n array: createPrimitiveTypeChecker('array'),\n bigint: createPrimitiveTypeChecker('bigint'),\n bool: createPrimitiveTypeChecker('boolean'),\n func: createPrimitiveTypeChecker('function'),\n number: createPrimitiveTypeChecker('number'),\n object: createPrimitiveTypeChecker('object'),\n string: createPrimitiveTypeChecker('string'),\n symbol: createPrimitiveTypeChecker('symbol'),\n\n any: createAnyTypeChecker(),\n arrayOf: createArrayOfTypeChecker,\n element: createElementTypeChecker(),\n elementType: createElementTypeTypeChecker(),\n instanceOf: createInstanceTypeChecker,\n node: createNodeChecker(),\n objectOf: createObjectOfTypeChecker,\n oneOf: createEnumTypeChecker,\n oneOfType: createUnionTypeChecker,\n shape: createShapeTypeChecker,\n exact: createStrictShapeTypeChecker,\n };\n\n /**\n * inlined Object.is polyfill to avoid requiring consumers ship their own\n * https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object/is\n */\n /*eslint-disable no-self-compare*/\n function is(x, y) {\n // SameValue algorithm\n if (x === y) {\n // Steps 1-5, 7-10\n // Steps 6.b-6.e: +0 != -0\n return x !== 0 || 1 / x === 1 / y;\n } else {\n // Step 6.a: NaN == NaN\n return x !== x && y !== y;\n }\n }\n /*eslint-enable no-self-compare*/\n\n /**\n * We use an Error-like object for backward compatibility as people may call\n * PropTypes directly and inspect their output. However, we don't use real\n * Errors anymore. We don't inspect their stack anyway, and creating them\n * is prohibitively expensive if they are created too often, such as what\n * happens in oneOfType() for any type before the one that matched.\n */\n function PropTypeError(message, data) {\n this.message = message;\n this.data = data && typeof data === 'object' ? data: {};\n this.stack = '';\n }\n // Make `instanceof Error` still work for returned errors.\n PropTypeError.prototype = Error.prototype;\n\n function createChainableTypeChecker(validate) {\n if (process.env.NODE_ENV !== 'production') {\n var manualPropTypeCallCache = {};\n var manualPropTypeWarningCount = 0;\n }\n function checkType(isRequired, props, propName, componentName, location, propFullName, secret) {\n componentName = componentName || ANONYMOUS;\n propFullName = propFullName || propName;\n\n if (secret !== ReactPropTypesSecret) {\n if (throwOnDirectAccess) {\n // New behavior only for users of `prop-types` package\n var err = new Error(\n 'Calling PropTypes validators directly is not supported by the `prop-types` package. ' +\n 'Use `PropTypes.checkPropTypes()` to call them. ' +\n 'Read more at http://fb.me/use-check-prop-types'\n );\n err.name = 'Invariant Violation';\n throw err;\n } else if (process.env.NODE_ENV !== 'production' && typeof console !== 'undefined') {\n // Old behavior for people using React.PropTypes\n var cacheKey = componentName + ':' + propName;\n if (\n !manualPropTypeCallCache[cacheKey] &&\n // Avoid spamming the console because they are often not actionable except for lib authors\n manualPropTypeWarningCount < 3\n ) {\n printWarning(\n 'You are manually calling a React.PropTypes validation ' +\n 'function for the `' + propFullName + '` prop on `' + componentName + '`. This is deprecated ' +\n 'and will throw in the standalone `prop-types` package. ' +\n 'You may be seeing this warning due to a third-party PropTypes ' +\n 'library. See https://fb.me/react-warning-dont-call-proptypes ' + 'for details.'\n );\n manualPropTypeCallCache[cacheKey] = true;\n manualPropTypeWarningCount++;\n }\n }\n }\n if (props[propName] == null) {\n if (isRequired) {\n if (props[propName] === null) {\n return new PropTypeError('The ' + location + ' `' + propFullName + '` is marked as required ' + ('in `' + componentName + '`, but its value is `null`.'));\n }\n return new PropTypeError('The ' + location + ' `' + propFullName + '` is marked as required in ' + ('`' + componentName + '`, but its value is `undefined`.'));\n }\n return null;\n } else {\n return validate(props, propName, componentName, location, propFullName);\n }\n }\n\n var chainedCheckType = checkType.bind(null, false);\n chainedCheckType.isRequired = checkType.bind(null, true);\n\n return chainedCheckType;\n }\n\n function createPrimitiveTypeChecker(expectedType) {\n function validate(props, propName, componentName, location, propFullName, secret) {\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== expectedType) {\n // `propValue` being instance of, say, date/regexp, pass the 'object'\n // check, but we can offer a more precise error message here rather than\n // 'of type `object`'.\n var preciseType = getPreciseType(propValue);\n\n return new PropTypeError(\n 'Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + preciseType + '` supplied to `' + componentName + '`, expected ') + ('`' + expectedType + '`.'),\n {expectedType: expectedType}\n );\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createAnyTypeChecker() {\n return createChainableTypeChecker(emptyFunctionThatReturnsNull);\n }\n\n function createArrayOfTypeChecker(typeChecker) {\n function validate(props, propName, componentName, location, propFullName) {\n if (typeof typeChecker !== 'function') {\n return new PropTypeError('Property `' + propFullName + '` of component `' + componentName + '` has invalid PropType notation inside arrayOf.');\n }\n var propValue = props[propName];\n if (!Array.isArray(propValue)) {\n var propType = getPropType(propValue);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected an array.'));\n }\n for (var i = 0; i < propValue.length; i++) {\n var error = typeChecker(propValue, i, componentName, location, propFullName + '[' + i + ']', ReactPropTypesSecret);\n if (error instanceof Error) {\n return error;\n }\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createElementTypeChecker() {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n if (!isValidElement(propValue)) {\n var propType = getPropType(propValue);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected a single ReactElement.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createElementTypeTypeChecker() {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n if (!ReactIs.isValidElementType(propValue)) {\n var propType = getPropType(propValue);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected a single ReactElement type.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createInstanceTypeChecker(expectedClass) {\n function validate(props, propName, componentName, location, propFullName) {\n if (!(props[propName] instanceof expectedClass)) {\n var expectedClassName = expectedClass.name || ANONYMOUS;\n var actualClassName = getClassName(props[propName]);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + actualClassName + '` supplied to `' + componentName + '`, expected ') + ('instance of `' + expectedClassName + '`.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createEnumTypeChecker(expectedValues) {\n if (!Array.isArray(expectedValues)) {\n if (process.env.NODE_ENV !== 'production') {\n if (arguments.length > 1) {\n printWarning(\n 'Invalid arguments supplied to oneOf, expected an array, got ' + arguments.length + ' arguments. ' +\n 'A common mistake is to write oneOf(x, y, z) instead of oneOf([x, y, z]).'\n );\n } else {\n printWarning('Invalid argument supplied to oneOf, expected an array.');\n }\n }\n return emptyFunctionThatReturnsNull;\n }\n\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n for (var i = 0; i < expectedValues.length; i++) {\n if (is(propValue, expectedValues[i])) {\n return null;\n }\n }\n\n var valuesString = JSON.stringify(expectedValues, function replacer(key, value) {\n var type = getPreciseType(value);\n if (type === 'symbol') {\n return String(value);\n }\n return value;\n });\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of value `' + String(propValue) + '` ' + ('supplied to `' + componentName + '`, expected one of ' + valuesString + '.'));\n }\n return createChainableTypeChecker(validate);\n }\n\n function createObjectOfTypeChecker(typeChecker) {\n function validate(props, propName, componentName, location, propFullName) {\n if (typeof typeChecker !== 'function') {\n return new PropTypeError('Property `' + propFullName + '` of component `' + componentName + '` has invalid PropType notation inside objectOf.');\n }\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== 'object') {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected an object.'));\n }\n for (var key in propValue) {\n if (has(propValue, key)) {\n var error = typeChecker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret);\n if (error instanceof Error) {\n return error;\n }\n }\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createUnionTypeChecker(arrayOfTypeCheckers) {\n if (!Array.isArray(arrayOfTypeCheckers)) {\n process.env.NODE_ENV !== 'production' ? printWarning('Invalid argument supplied to oneOfType, expected an instance of array.') : void 0;\n return emptyFunctionThatReturnsNull;\n }\n\n for (var i = 0; i < arrayOfTypeCheckers.length; i++) {\n var checker = arrayOfTypeCheckers[i];\n if (typeof checker !== 'function') {\n printWarning(\n 'Invalid argument supplied to oneOfType. Expected an array of check functions, but ' +\n 'received ' + getPostfixForTypeWarning(checker) + ' at index ' + i + '.'\n );\n return emptyFunctionThatReturnsNull;\n }\n }\n\n function validate(props, propName, componentName, location, propFullName) {\n var expectedTypes = [];\n for (var i = 0; i < arrayOfTypeCheckers.length; i++) {\n var checker = arrayOfTypeCheckers[i];\n var checkerResult = checker(props, propName, componentName, location, propFullName, ReactPropTypesSecret);\n if (checkerResult == null) {\n return null;\n }\n if (checkerResult.data && has(checkerResult.data, 'expectedType')) {\n expectedTypes.push(checkerResult.data.expectedType);\n }\n }\n var expectedTypesMessage = (expectedTypes.length > 0) ? ', expected one of type [' + expectedTypes.join(', ') + ']': '';\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` supplied to ' + ('`' + componentName + '`' + expectedTypesMessage + '.'));\n }\n return createChainableTypeChecker(validate);\n }\n\n function createNodeChecker() {\n function validate(props, propName, componentName, location, propFullName) {\n if (!isNode(props[propName])) {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` supplied to ' + ('`' + componentName + '`, expected a ReactNode.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function invalidValidatorError(componentName, location, propFullName, key, type) {\n return new PropTypeError(\n (componentName || 'React class') + ': ' + location + ' type `' + propFullName + '.' + key + '` is invalid; ' +\n 'it must be a function, usually from the `prop-types` package, but received `' + type + '`.'\n );\n }\n\n function createShapeTypeChecker(shapeTypes) {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== 'object') {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type `' + propType + '` ' + ('supplied to `' + componentName + '`, expected `object`.'));\n }\n for (var key in shapeTypes) {\n var checker = shapeTypes[key];\n if (typeof checker !== 'function') {\n return invalidValidatorError(componentName, location, propFullName, key, getPreciseType(checker));\n }\n var error = checker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret);\n if (error) {\n return error;\n }\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createStrictShapeTypeChecker(shapeTypes) {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== 'object') {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type `' + propType + '` ' + ('supplied to `' + componentName + '`, expected `object`.'));\n }\n // We need to check all keys in case some are required but missing from props.\n var allKeys = assign({}, props[propName], shapeTypes);\n for (var key in allKeys) {\n var checker = shapeTypes[key];\n if (has(shapeTypes, key) && typeof checker !== 'function') {\n return invalidValidatorError(componentName, location, propFullName, key, getPreciseType(checker));\n }\n if (!checker) {\n return new PropTypeError(\n 'Invalid ' + location + ' `' + propFullName + '` key `' + key + '` supplied to `' + componentName + '`.' +\n '\\nBad object: ' + JSON.stringify(props[propName], null, ' ') +\n '\\nValid keys: ' + JSON.stringify(Object.keys(shapeTypes), null, ' ')\n );\n }\n var error = checker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret);\n if (error) {\n return error;\n }\n }\n return null;\n }\n\n return createChainableTypeChecker(validate);\n }\n\n function isNode(propValue) {\n switch (typeof propValue) {\n case 'number':\n case 'string':\n case 'undefined':\n return true;\n case 'boolean':\n return !propValue;\n case 'object':\n if (Array.isArray(propValue)) {\n return propValue.every(isNode);\n }\n if (propValue === null || isValidElement(propValue)) {\n return true;\n }\n\n var iteratorFn = getIteratorFn(propValue);\n if (iteratorFn) {\n var iterator = iteratorFn.call(propValue);\n var step;\n if (iteratorFn !== propValue.entries) {\n while (!(step = iterator.next()).done) {\n if (!isNode(step.value)) {\n return false;\n }\n }\n } else {\n // Iterator will provide entry [k,v] tuples rather than values.\n while (!(step = iterator.next()).done) {\n var entry = step.value;\n if (entry) {\n if (!isNode(entry[1])) {\n return false;\n }\n }\n }\n }\n } else {\n return false;\n }\n\n return true;\n default:\n return false;\n }\n }\n\n function isSymbol(propType, propValue) {\n // Native Symbol.\n if (propType === 'symbol') {\n return true;\n }\n\n // falsy value can't be a Symbol\n if (!propValue) {\n return false;\n }\n\n // 19.4.3.5 Symbol.prototype[@@toStringTag] === 'Symbol'\n if (propValue['@@toStringTag'] === 'Symbol') {\n return true;\n }\n\n // Fallback for non-spec compliant Symbols which are polyfilled.\n if (typeof Symbol === 'function' && propValue instanceof Symbol) {\n return true;\n }\n\n return false;\n }\n\n // Equivalent of `typeof` but with special handling for array and regexp.\n function getPropType(propValue) {\n var propType = typeof propValue;\n if (Array.isArray(propValue)) {\n return 'array';\n }\n if (propValue instanceof RegExp) {\n // Old webkits (at least until Android 4.0) return 'function' rather than\n // 'object' for typeof a RegExp. We'll normalize this here so that /bla/\n // passes PropTypes.object.\n return 'object';\n }\n if (isSymbol(propType, propValue)) {\n return 'symbol';\n }\n return propType;\n }\n\n // This handles more types than `getPropType`. Only used for error messages.\n // See `createPrimitiveTypeChecker`.\n function getPreciseType(propValue) {\n if (typeof propValue === 'undefined' || propValue === null) {\n return '' + propValue;\n }\n var propType = getPropType(propValue);\n if (propType === 'object') {\n if (propValue instanceof Date) {\n return 'date';\n } else if (propValue instanceof RegExp) {\n return 'regexp';\n }\n }\n return propType;\n }\n\n // Returns a string that is postfixed to a warning about an invalid type.\n // For example, \"undefined\" or \"of type array\"\n function getPostfixForTypeWarning(value) {\n var type = getPreciseType(value);\n switch (type) {\n case 'array':\n case 'object':\n return 'an ' + type;\n case 'boolean':\n case 'date':\n case 'regexp':\n return 'a ' + type;\n default:\n return type;\n }\n }\n\n // Returns class name of the object, if any.\n function getClassName(propValue) {\n if (!propValue.constructor || !propValue.constructor.name) {\n return ANONYMOUS;\n }\n return propValue.constructor.name;\n }\n\n ReactPropTypes.checkPropTypes = checkPropTypes;\n ReactPropTypes.resetWarningCache = checkPropTypes.resetWarningCache;\n ReactPropTypes.PropTypes = ReactPropTypes;\n\n return ReactPropTypes;\n};\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar ReactPropTypesSecret = require('./lib/ReactPropTypesSecret');\n\nfunction emptyFunction() {}\nfunction emptyFunctionWithReset() {}\nemptyFunctionWithReset.resetWarningCache = emptyFunction;\n\nmodule.exports = function() {\n function shim(props, propName, componentName, location, propFullName, secret) {\n if (secret === ReactPropTypesSecret) {\n // It is still safe when called from React.\n return;\n }\n var err = new Error(\n 'Calling PropTypes validators directly is not supported by the `prop-types` package. ' +\n 'Use PropTypes.checkPropTypes() to call them. ' +\n 'Read more at http://fb.me/use-check-prop-types'\n );\n err.name = 'Invariant Violation';\n throw err;\n };\n shim.isRequired = shim;\n function getShim() {\n return shim;\n };\n // Important!\n // Keep this list in sync with production version in `./factoryWithTypeCheckers.js`.\n var ReactPropTypes = {\n array: shim,\n bigint: shim,\n bool: shim,\n func: shim,\n number: shim,\n object: shim,\n string: shim,\n symbol: shim,\n\n any: shim,\n arrayOf: getShim,\n element: shim,\n elementType: shim,\n instanceOf: getShim,\n node: shim,\n objectOf: getShim,\n oneOf: getShim,\n oneOfType: getShim,\n shape: getShim,\n exact: getShim,\n\n checkPropTypes: emptyFunctionWithReset,\n resetWarningCache: emptyFunction\n };\n\n ReactPropTypes.PropTypes = ReactPropTypes;\n\n return ReactPropTypes;\n};\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\nif (process.env.NODE_ENV !== 'production') {\n var ReactIs = require('react-is');\n\n // By explicitly using `prop-types` you are opting into new development behavior.\n // http://fb.me/prop-types-in-prod\n var throwOnDirectAccess = true;\n module.exports = require('./factoryWithTypeCheckers')(ReactIs.isElement, throwOnDirectAccess);\n} else {\n // By explicitly using `prop-types` you are opting into new production behavior.\n // http://fb.me/prop-types-in-prod\n module.exports = require('./factoryWithThrowingShims')();\n}\n","import PropTypes from 'prop-types';\nimport chainPropTypes from '../chainPropTypes';\nfunction isClassComponent(elementType) {\n // elementType.prototype?.isReactComponent\n const {\n prototype = {}\n } = elementType;\n return Boolean(prototype.isReactComponent);\n}\nfunction acceptingRef(props, propName, componentName, location, propFullName) {\n const element = props[propName];\n const safePropName = propFullName || propName;\n if (element == null ||\n // When server-side rendering React doesn't warn either.\n // This is not an accurate check for SSR.\n // This is only in place for Emotion compat.\n // TODO: Revisit once https://github.com/facebook/react/issues/20047 is resolved.\n typeof window === 'undefined') {\n return null;\n }\n let warningHint;\n const elementType = element.type;\n /**\n * Blacklisting instead of whitelisting\n *\n * Blacklisting will miss some components, such as React.Fragment. Those will at least\n * trigger a warning in React.\n * We can't whitelist because there is no safe way to detect React.forwardRef\n * or class components. \"Safe\" means there's no public API.\n *\n */\n if (typeof elementType === 'function' && !isClassComponent(elementType)) {\n warningHint = 'Did you accidentally use a plain function component for an element instead?';\n }\n if (warningHint !== undefined) {\n return new Error(`Invalid ${location} \\`${safePropName}\\` supplied to \\`${componentName}\\`. ` + `Expected an element that can hold a ref. ${warningHint} ` + 'For more information see https://mui.com/r/caveat-with-refs-guide');\n }\n return null;\n}\nconst elementAcceptingRef = chainPropTypes(PropTypes.element, acceptingRef);\nelementAcceptingRef.isRequired = chainPropTypes(PropTypes.element.isRequired, acceptingRef);\nexport default elementAcceptingRef;","import _extends from \"@babel/runtime/helpers/esm/extends\";\n// This module is based on https://github.com/airbnb/prop-types-exact repository.\n// However, in order to reduce the number of dependencies and to remove some extra safe checks\n// the module was forked.\n\nconst specialProperty = 'exact-prop: \\u200b';\nexport default function exactProp(propTypes) {\n if (process.env.NODE_ENV === 'production') {\n return propTypes;\n }\n return _extends({}, propTypes, {\n [specialProperty]: props => {\n const unsupportedProps = Object.keys(props).filter(prop => !propTypes.hasOwnProperty(prop));\n if (unsupportedProps.length > 0) {\n return new Error(`The following props are not supported: ${unsupportedProps.map(prop => `\\`${prop}\\``).join(', ')}. Please remove them.`);\n }\n return null;\n }\n });\n}","/**\n * WARNING: Don't import this directly.\n * Use `MuiError` from `@mui/internal-babel-macros/MuiError.macro` instead.\n * @param {number} code\n */\nexport default function formatMuiErrorMessage(code) {\n // Apply babel-plugin-transform-template-literals in loose mode\n // loose mode is safe if we're concatenating primitives\n // see https://babeljs.io/docs/en/babel-plugin-transform-template-literals#loose\n /* eslint-disable prefer-template */\n let url = 'https://mui.com/production-error/?code=' + code;\n for (let i = 1; i < arguments.length; i += 1) {\n // rest params over-transpile for this case\n // eslint-disable-next-line prefer-rest-params\n url += '&args[]=' + encodeURIComponent(arguments[i]);\n }\n return 'Minified MUI error #' + code + '; visit ' + url + ' for the full message.';\n /* eslint-enable prefer-template */\n}","/**\n * @license React\n * react-is.production.min.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n'use strict';var b=Symbol.for(\"react.element\"),c=Symbol.for(\"react.portal\"),d=Symbol.for(\"react.fragment\"),e=Symbol.for(\"react.strict_mode\"),f=Symbol.for(\"react.profiler\"),g=Symbol.for(\"react.provider\"),h=Symbol.for(\"react.context\"),k=Symbol.for(\"react.server_context\"),l=Symbol.for(\"react.forward_ref\"),m=Symbol.for(\"react.suspense\"),n=Symbol.for(\"react.suspense_list\"),p=Symbol.for(\"react.memo\"),q=Symbol.for(\"react.lazy\"),t=Symbol.for(\"react.offscreen\"),u;u=Symbol.for(\"react.module.reference\");\nfunction v(a){if(\"object\"===typeof a&&null!==a){var r=a.$$typeof;switch(r){case b:switch(a=a.type,a){case d:case f:case e:case m:case n:return a;default:switch(a=a&&a.$$typeof,a){case k:case h:case l:case q:case p:case g:return a;default:return r}}case c:return r}}}exports.ContextConsumer=h;exports.ContextProvider=g;exports.Element=b;exports.ForwardRef=l;exports.Fragment=d;exports.Lazy=q;exports.Memo=p;exports.Portal=c;exports.Profiler=f;exports.StrictMode=e;exports.Suspense=m;\nexports.SuspenseList=n;exports.isAsyncMode=function(){return!1};exports.isConcurrentMode=function(){return!1};exports.isContextConsumer=function(a){return v(a)===h};exports.isContextProvider=function(a){return v(a)===g};exports.isElement=function(a){return\"object\"===typeof a&&null!==a&&a.$$typeof===b};exports.isForwardRef=function(a){return v(a)===l};exports.isFragment=function(a){return v(a)===d};exports.isLazy=function(a){return v(a)===q};exports.isMemo=function(a){return v(a)===p};\nexports.isPortal=function(a){return v(a)===c};exports.isProfiler=function(a){return v(a)===f};exports.isStrictMode=function(a){return v(a)===e};exports.isSuspense=function(a){return v(a)===m};exports.isSuspenseList=function(a){return v(a)===n};\nexports.isValidElementType=function(a){return\"string\"===typeof a||\"function\"===typeof a||a===d||a===f||a===e||a===m||a===n||a===t||\"object\"===typeof a&&null!==a&&(a.$$typeof===q||a.$$typeof===p||a.$$typeof===g||a.$$typeof===h||a.$$typeof===l||a.$$typeof===u||void 0!==a.getModuleId)?!0:!1};exports.typeOf=v;\n","/**\n * @license React\n * react-is.development.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nif (process.env.NODE_ENV !== \"production\") {\n (function() {\n'use strict';\n\n// ATTENTION\n// When adding new symbols to this file,\n// Please consider also adding to 'react-devtools-shared/src/backend/ReactSymbols'\n// The Symbol used to tag the ReactElement-like types.\nvar REACT_ELEMENT_TYPE = Symbol.for('react.element');\nvar REACT_PORTAL_TYPE = Symbol.for('react.portal');\nvar REACT_FRAGMENT_TYPE = Symbol.for('react.fragment');\nvar REACT_STRICT_MODE_TYPE = Symbol.for('react.strict_mode');\nvar REACT_PROFILER_TYPE = Symbol.for('react.profiler');\nvar REACT_PROVIDER_TYPE = Symbol.for('react.provider');\nvar REACT_CONTEXT_TYPE = Symbol.for('react.context');\nvar REACT_SERVER_CONTEXT_TYPE = Symbol.for('react.server_context');\nvar REACT_FORWARD_REF_TYPE = Symbol.for('react.forward_ref');\nvar REACT_SUSPENSE_TYPE = Symbol.for('react.suspense');\nvar REACT_SUSPENSE_LIST_TYPE = Symbol.for('react.suspense_list');\nvar REACT_MEMO_TYPE = Symbol.for('react.memo');\nvar REACT_LAZY_TYPE = Symbol.for('react.lazy');\nvar REACT_OFFSCREEN_TYPE = Symbol.for('react.offscreen');\n\n// -----------------------------------------------------------------------------\n\nvar enableScopeAPI = false; // Experimental Create Event Handle API.\nvar enableCacheElement = false;\nvar enableTransitionTracing = false; // No known bugs, but needs performance testing\n\nvar enableLegacyHidden = false; // Enables unstable_avoidThisFallback feature in Fiber\n// stuff. Intended to enable React core members to more easily debug scheduling\n// issues in DEV builds.\n\nvar enableDebugTracing = false; // Track which Fiber(s) schedule render work.\n\nvar REACT_MODULE_REFERENCE;\n\n{\n REACT_MODULE_REFERENCE = Symbol.for('react.module.reference');\n}\n\nfunction isValidElementType(type) {\n if (typeof type === 'string' || typeof type === 'function') {\n return true;\n } // Note: typeof might be other than 'symbol' or 'number' (e.g. if it's a polyfill).\n\n\n if (type === REACT_FRAGMENT_TYPE || type === REACT_PROFILER_TYPE || enableDebugTracing || type === REACT_STRICT_MODE_TYPE || type === REACT_SUSPENSE_TYPE || type === REACT_SUSPENSE_LIST_TYPE || enableLegacyHidden || type === REACT_OFFSCREEN_TYPE || enableScopeAPI || enableCacheElement || enableTransitionTracing ) {\n return true;\n }\n\n if (typeof type === 'object' && type !== null) {\n if (type.$$typeof === REACT_LAZY_TYPE || type.$$typeof === REACT_MEMO_TYPE || type.$$typeof === REACT_PROVIDER_TYPE || type.$$typeof === REACT_CONTEXT_TYPE || type.$$typeof === REACT_FORWARD_REF_TYPE || // This needs to include all possible module reference object\n // types supported by any Flight configuration anywhere since\n // we don't know which Flight build this will end up being used\n // with.\n type.$$typeof === REACT_MODULE_REFERENCE || type.getModuleId !== undefined) {\n return true;\n }\n }\n\n return false;\n}\n\nfunction typeOf(object) {\n if (typeof object === 'object' && object !== null) {\n var $$typeof = object.$$typeof;\n\n switch ($$typeof) {\n case REACT_ELEMENT_TYPE:\n var type = object.type;\n\n switch (type) {\n case REACT_FRAGMENT_TYPE:\n case REACT_PROFILER_TYPE:\n case REACT_STRICT_MODE_TYPE:\n case REACT_SUSPENSE_TYPE:\n case REACT_SUSPENSE_LIST_TYPE:\n return type;\n\n default:\n var $$typeofType = type && type.$$typeof;\n\n switch ($$typeofType) {\n case REACT_SERVER_CONTEXT_TYPE:\n case REACT_CONTEXT_TYPE:\n case REACT_FORWARD_REF_TYPE:\n case REACT_LAZY_TYPE:\n case REACT_MEMO_TYPE:\n case REACT_PROVIDER_TYPE:\n return $$typeofType;\n\n default:\n return $$typeof;\n }\n\n }\n\n case REACT_PORTAL_TYPE:\n return $$typeof;\n }\n }\n\n return undefined;\n}\nvar ContextConsumer = REACT_CONTEXT_TYPE;\nvar ContextProvider = REACT_PROVIDER_TYPE;\nvar Element = REACT_ELEMENT_TYPE;\nvar ForwardRef = REACT_FORWARD_REF_TYPE;\nvar Fragment = REACT_FRAGMENT_TYPE;\nvar Lazy = REACT_LAZY_TYPE;\nvar Memo = REACT_MEMO_TYPE;\nvar Portal = REACT_PORTAL_TYPE;\nvar Profiler = REACT_PROFILER_TYPE;\nvar StrictMode = REACT_STRICT_MODE_TYPE;\nvar Suspense = REACT_SUSPENSE_TYPE;\nvar SuspenseList = REACT_SUSPENSE_LIST_TYPE;\nvar hasWarnedAboutDeprecatedIsAsyncMode = false;\nvar hasWarnedAboutDeprecatedIsConcurrentMode = false; // AsyncMode should be deprecated\n\nfunction isAsyncMode(object) {\n {\n if (!hasWarnedAboutDeprecatedIsAsyncMode) {\n hasWarnedAboutDeprecatedIsAsyncMode = true; // Using console['warn'] to evade Babel and ESLint\n\n console['warn']('The ReactIs.isAsyncMode() alias has been deprecated, ' + 'and will be removed in React 18+.');\n }\n }\n\n return false;\n}\nfunction isConcurrentMode(object) {\n {\n if (!hasWarnedAboutDeprecatedIsConcurrentMode) {\n hasWarnedAboutDeprecatedIsConcurrentMode = true; // Using console['warn'] to evade Babel and ESLint\n\n console['warn']('The ReactIs.isConcurrentMode() alias has been deprecated, ' + 'and will be removed in React 18+.');\n }\n }\n\n return false;\n}\nfunction isContextConsumer(object) {\n return typeOf(object) === REACT_CONTEXT_TYPE;\n}\nfunction isContextProvider(object) {\n return typeOf(object) === REACT_PROVIDER_TYPE;\n}\nfunction isElement(object) {\n return typeof object === 'object' && object !== null && object.$$typeof === REACT_ELEMENT_TYPE;\n}\nfunction isForwardRef(object) {\n return typeOf(object) === REACT_FORWARD_REF_TYPE;\n}\nfunction isFragment(object) {\n return typeOf(object) === REACT_FRAGMENT_TYPE;\n}\nfunction isLazy(object) {\n return typeOf(object) === REACT_LAZY_TYPE;\n}\nfunction isMemo(object) {\n return typeOf(object) === REACT_MEMO_TYPE;\n}\nfunction isPortal(object) {\n return typeOf(object) === REACT_PORTAL_TYPE;\n}\nfunction isProfiler(object) {\n return typeOf(object) === REACT_PROFILER_TYPE;\n}\nfunction isStrictMode(object) {\n return typeOf(object) === REACT_STRICT_MODE_TYPE;\n}\nfunction isSuspense(object) {\n return typeOf(object) === REACT_SUSPENSE_TYPE;\n}\nfunction isSuspenseList(object) {\n return typeOf(object) === REACT_SUSPENSE_LIST_TYPE;\n}\n\nexports.ContextConsumer = ContextConsumer;\nexports.ContextProvider = ContextProvider;\nexports.Element = Element;\nexports.ForwardRef = ForwardRef;\nexports.Fragment = Fragment;\nexports.Lazy = Lazy;\nexports.Memo = Memo;\nexports.Portal = Portal;\nexports.Profiler = Profiler;\nexports.StrictMode = StrictMode;\nexports.Suspense = Suspense;\nexports.SuspenseList = SuspenseList;\nexports.isAsyncMode = isAsyncMode;\nexports.isConcurrentMode = isConcurrentMode;\nexports.isContextConsumer = isContextConsumer;\nexports.isContextProvider = isContextProvider;\nexports.isElement = isElement;\nexports.isForwardRef = isForwardRef;\nexports.isFragment = isFragment;\nexports.isLazy = isLazy;\nexports.isMemo = isMemo;\nexports.isPortal = isPortal;\nexports.isProfiler = isProfiler;\nexports.isStrictMode = isStrictMode;\nexports.isSuspense = isSuspense;\nexports.isSuspenseList = isSuspenseList;\nexports.isValidElementType = isValidElementType;\nexports.typeOf = typeOf;\n })();\n}\n","'use strict';\n\nif (process.env.NODE_ENV === 'production') {\n module.exports = require('./cjs/react-is.production.min.js');\n} else {\n module.exports = require('./cjs/react-is.development.js');\n}\n","import { ForwardRef, Memo } from 'react-is';\n\n// Simplified polyfill for IE11 support\n// https://github.com/JamesMGreene/Function.name/blob/58b314d4a983110c3682f1228f845d39ccca1817/Function.name.js#L3\nconst fnNameMatchRegex = /^\\s*function(?:\\s|\\s*\\/\\*.*\\*\\/\\s*)+([^(\\s/]*)\\s*/;\nexport function getFunctionName(fn) {\n const match = `${fn}`.match(fnNameMatchRegex);\n const name = match && match[1];\n return name || '';\n}\nfunction getFunctionComponentName(Component, fallback = '') {\n return Component.displayName || Component.name || getFunctionName(Component) || fallback;\n}\nfunction getWrappedName(outerType, innerType, wrapperName) {\n const functionName = getFunctionComponentName(innerType);\n return outerType.displayName || (functionName !== '' ? `${wrapperName}(${functionName})` : wrapperName);\n}\n\n/**\n * cherry-pick from\n * https://github.com/facebook/react/blob/769b1f270e1251d9dbdce0fcbd9e92e502d059b8/packages/shared/getComponentName.js\n * originally forked from recompose/getDisplayName with added IE11 support\n */\nexport default function getDisplayName(Component) {\n if (Component == null) {\n return undefined;\n }\n if (typeof Component === 'string') {\n return Component;\n }\n if (typeof Component === 'function') {\n return getFunctionComponentName(Component, 'Component');\n }\n\n // TypeScript can't have components as objects but they exist in the form of `memo` or `Suspense`\n if (typeof Component === 'object') {\n switch (Component.$$typeof) {\n case ForwardRef:\n return getWrappedName(Component, Component.render, 'ForwardRef');\n case Memo:\n return getWrappedName(Component, Component.type, 'memo');\n default:\n return undefined;\n }\n }\n return undefined;\n}","export default function HTMLElementType(props, propName, componentName, location, propFullName) {\n if (process.env.NODE_ENV === 'production') {\n return null;\n }\n const propValue = props[propName];\n const safePropName = propFullName || propName;\n if (propValue == null) {\n return null;\n }\n if (propValue && propValue.nodeType !== 1) {\n return new Error(`Invalid ${location} \\`${safePropName}\\` supplied to \\`${componentName}\\`. ` + `Expected an HTMLElement.`);\n }\n return null;\n}","import PropTypes from 'prop-types';\nconst refType = PropTypes.oneOfType([PropTypes.func, PropTypes.object]);\nexport default refType;","import _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\n// It should to be noted that this function isn't equivalent to `text-transform: capitalize`.\n//\n// A strict capitalization should uppercase the first letter of each word in the sentence.\n// We only handle the first word.\nexport default function capitalize(string) {\n if (typeof string !== 'string') {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: \\`capitalize(string)\\` expects a string argument.` : _formatMuiErrorMessage(7));\n }\n return string.charAt(0).toUpperCase() + string.slice(1);\n}","/**\n * Safe chained function.\n *\n * Will only create a new function if needed,\n * otherwise will pass back existing functions or null.\n */\nexport default function createChainedFunction(...funcs) {\n return funcs.reduce((acc, func) => {\n if (func == null) {\n return acc;\n }\n return function chainedFunction(...args) {\n acc.apply(this, args);\n func.apply(this, args);\n };\n }, () => {});\n}","// Corresponds to 10 frames at 60 Hz.\n// A few bytes payload overhead when lodash/debounce is ~3 kB and debounce ~300 B.\nexport default function debounce(func, wait = 166) {\n let timeout;\n function debounced(...args) {\n const later = () => {\n // @ts-ignore\n func.apply(this, args);\n };\n clearTimeout(timeout);\n timeout = setTimeout(later, wait);\n }\n debounced.clear = () => {\n clearTimeout(timeout);\n };\n return debounced;\n}","export default function deprecatedPropType(validator, reason) {\n if (process.env.NODE_ENV === 'production') {\n return () => null;\n }\n return (props, propName, componentName, location, propFullName) => {\n const componentNameSafe = componentName || '<>';\n const propFullNameSafe = propFullName || propName;\n if (typeof props[propName] !== 'undefined') {\n return new Error(`The ${location} \\`${propFullNameSafe}\\` of ` + `\\`${componentNameSafe}\\` is deprecated. ${reason}`);\n }\n return null;\n };\n}","import * as React from 'react';\nexport default function isMuiElement(element, muiNames) {\n var _muiName, _element$type;\n return /*#__PURE__*/React.isValidElement(element) && muiNames.indexOf( // For server components `muiName` is avaialble in element.type._payload.value.muiName\n // relevant info - https://github.com/facebook/react/blob/2807d781a08db8e9873687fccc25c0f12b4fb3d4/packages/react/src/ReactLazy.js#L45\n // eslint-disable-next-line no-underscore-dangle\n (_muiName = element.type.muiName) != null ? _muiName : (_element$type = element.type) == null || (_element$type = _element$type._payload) == null || (_element$type = _element$type.value) == null ? void 0 : _element$type.muiName) !== -1;\n}","export default function ownerDocument(node) {\n return node && node.ownerDocument || document;\n}","import ownerDocument from '../ownerDocument';\nexport default function ownerWindow(node) {\n const doc = ownerDocument(node);\n return doc.defaultView || window;\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nexport default function requirePropFactory(componentNameInError, Component) {\n if (process.env.NODE_ENV === 'production') {\n return () => null;\n }\n\n // eslint-disable-next-line react/forbid-foreign-prop-types\n const prevPropTypes = Component ? _extends({}, Component.propTypes) : null;\n const requireProp = requiredProp => (props, propName, componentName, location, propFullName, ...args) => {\n const propFullNameSafe = propFullName || propName;\n const defaultTypeChecker = prevPropTypes == null ? void 0 : prevPropTypes[propFullNameSafe];\n if (defaultTypeChecker) {\n const typeCheckerResult = defaultTypeChecker(props, propName, componentName, location, propFullName, ...args);\n if (typeCheckerResult) {\n return typeCheckerResult;\n }\n }\n if (typeof props[propName] !== 'undefined' && !props[requiredProp]) {\n return new Error(`The prop \\`${propFullNameSafe}\\` of ` + `\\`${componentNameInError}\\` can only be used together with the \\`${requiredProp}\\` prop.`);\n }\n return null;\n };\n return requireProp;\n}","/**\n * TODO v5: consider making it private\n *\n * passes {value} to {ref}\n *\n * WARNING: Be sure to only call this inside a callback that is passed as a ref.\n * Otherwise, make sure to cleanup the previous {ref} if it changes. See\n * https://github.com/mui/material-ui/issues/13539\n *\n * Useful if you want to expose the ref of an inner component to the public API\n * while still using it inside the component.\n * @param ref A ref callback or ref object. If anything falsy, this is a no-op.\n */\nexport default function setRef(ref, value) {\n if (typeof ref === 'function') {\n ref(value);\n } else if (ref) {\n ref.current = value;\n }\n}","'use client';\n\nimport * as React from 'react';\n\n/**\n * A version of `React.useLayoutEffect` that does not show a warning when server-side rendering.\n * This is useful for effects that are only needed for client-side rendering but not for SSR.\n *\n * Before you use this hook, make sure to read https://gist.github.com/gaearon/e7d97cdf38a2907924ea12e4ebdf3c85\n * and confirm it doesn't apply to your use-case.\n */\nconst useEnhancedEffect = typeof window !== 'undefined' ? React.useLayoutEffect : React.useEffect;\nexport default useEnhancedEffect;","'use client';\n\nimport * as React from 'react';\nlet globalId = 0;\nfunction useGlobalId(idOverride) {\n const [defaultId, setDefaultId] = React.useState(idOverride);\n const id = idOverride || defaultId;\n React.useEffect(() => {\n if (defaultId == null) {\n // Fallback to this default id when possible.\n // Use the incrementing value for client-side rendering only.\n // We can't use it server-side.\n // If you want to use random values please consider the Birthday Problem: https://en.wikipedia.org/wiki/Birthday_problem\n globalId += 1;\n setDefaultId(`mui-${globalId}`);\n }\n }, [defaultId]);\n return id;\n}\n\n// downstream bundlers may remove unnecessary concatenation, but won't remove toString call -- Workaround for https://github.com/webpack/webpack/issues/14814\nconst maybeReactUseId = React['useId'.toString()];\n/**\n *\n * @example
    \n * @param idOverride\n * @returns {string}\n */\nexport default function useId(idOverride) {\n if (maybeReactUseId !== undefined) {\n const reactId = maybeReactUseId();\n return idOverride != null ? idOverride : reactId;\n }\n // eslint-disable-next-line react-hooks/rules-of-hooks -- `React.useId` is invariant at runtime.\n return useGlobalId(idOverride);\n}","export default function unsupportedProp(props, propName, componentName, location, propFullName) {\n if (process.env.NODE_ENV === 'production') {\n return null;\n }\n const propFullNameSafe = propFullName || propName;\n if (typeof props[propName] !== 'undefined') {\n return new Error(`The prop \\`${propFullNameSafe}\\` is not supported. Please remove it.`);\n }\n return null;\n}","'use client';\n\n/* eslint-disable react-hooks/rules-of-hooks, react-hooks/exhaustive-deps */\nimport * as React from 'react';\nexport default function useControlled({\n controlled,\n default: defaultProp,\n name,\n state = 'value'\n}) {\n // isControlled is ignored in the hook dependency lists as it should never change.\n const {\n current: isControlled\n } = React.useRef(controlled !== undefined);\n const [valueState, setValue] = React.useState(defaultProp);\n const value = isControlled ? controlled : valueState;\n if (process.env.NODE_ENV !== 'production') {\n React.useEffect(() => {\n if (isControlled !== (controlled !== undefined)) {\n console.error([`MUI: A component is changing the ${isControlled ? '' : 'un'}controlled ${state} state of ${name} to be ${isControlled ? 'un' : ''}controlled.`, 'Elements should not switch from uncontrolled to controlled (or vice versa).', `Decide between using a controlled or uncontrolled ${name} ` + 'element for the lifetime of the component.', \"The nature of the state is determined during the first render. It's considered controlled if the value is not `undefined`.\", 'More info: https://fb.me/react-controlled-components'].join('\\n'));\n }\n }, [state, name, controlled]);\n const {\n current: defaultValue\n } = React.useRef(defaultProp);\n React.useEffect(() => {\n if (!isControlled && defaultValue !== defaultProp) {\n console.error([`MUI: A component is changing the default ${state} state of an uncontrolled ${name} after being initialized. ` + `To suppress this warning opt to use a controlled ${name}.`].join('\\n'));\n }\n }, [JSON.stringify(defaultProp)]);\n }\n const setValueIfUncontrolled = React.useCallback(newValue => {\n if (!isControlled) {\n setValue(newValue);\n }\n }, []);\n return [value, setValueIfUncontrolled];\n}","'use client';\n\nimport * as React from 'react';\nimport useEnhancedEffect from '../useEnhancedEffect';\n\n/**\n * Inspired by https://github.com/facebook/react/issues/14099#issuecomment-440013892\n * See RFC in https://github.com/reactjs/rfcs/pull/220\n */\n\nfunction useEventCallback(fn) {\n const ref = React.useRef(fn);\n useEnhancedEffect(() => {\n ref.current = fn;\n });\n return React.useRef((...args) =>\n // @ts-expect-error hide `this`\n (0, ref.current)(...args)).current;\n}\nexport default useEventCallback;","'use client';\n\nimport * as React from 'react';\nimport setRef from '../setRef';\nexport default function useForkRef(...refs) {\n /**\n * This will create a new function if the refs passed to this hook change and are all defined.\n * This means react will call the old forkRef with `null` and the new forkRef\n * with the ref. Cleanup naturally emerges from this behavior.\n */\n return React.useMemo(() => {\n if (refs.every(ref => ref == null)) {\n return null;\n }\n return instance => {\n refs.forEach(ref => {\n setRef(ref, instance);\n });\n };\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, refs);\n}","'use client';\n\nimport * as React from 'react';\nconst UNINITIALIZED = {};\n\n/**\n * A React.useRef() that is initialized lazily with a function. Note that it accepts an optional\n * initialization argument, so the initialization function doesn't need to be an inline closure.\n *\n * @usage\n * const ref = useLazyRef(sortColumns, columns)\n */\nexport default function useLazyRef(init, initArg) {\n const ref = React.useRef(UNINITIALIZED);\n if (ref.current === UNINITIALIZED) {\n ref.current = init(initArg);\n }\n return ref;\n}","'use client';\n\nimport * as React from 'react';\nconst EMPTY = [];\n\n/**\n * A React.useEffect equivalent that runs once, when the component is mounted.\n */\nexport default function useOnMount(fn) {\n /* eslint-disable react-hooks/exhaustive-deps */\n React.useEffect(fn, EMPTY);\n /* eslint-enable react-hooks/exhaustive-deps */\n}","'use client';\n\nimport useLazyRef from '../useLazyRef/useLazyRef';\nimport useOnMount from '../useOnMount/useOnMount';\nexport class Timeout {\n constructor() {\n this.currentId = null;\n this.clear = () => {\n if (this.currentId !== null) {\n clearTimeout(this.currentId);\n this.currentId = null;\n }\n };\n this.disposeEffect = () => {\n return this.clear;\n };\n }\n static create() {\n return new Timeout();\n }\n /**\n * Executes `fn` after `delay`, clearing any previously scheduled call.\n */\n start(delay, fn) {\n this.clear();\n this.currentId = setTimeout(() => {\n this.currentId = null;\n fn();\n }, delay);\n }\n}\nexport default function useTimeout() {\n const timeout = useLazyRef(Timeout.create).current;\n useOnMount(timeout.disposeEffect);\n return timeout;\n}","'use client';\n\n// based on https://github.com/WICG/focus-visible/blob/v4.1.5/src/focus-visible.js\nimport * as React from 'react';\nimport { Timeout } from '../useTimeout/useTimeout';\nlet hadKeyboardEvent = true;\nlet hadFocusVisibleRecently = false;\nconst hadFocusVisibleRecentlyTimeout = new Timeout();\nconst inputTypesWhitelist = {\n text: true,\n search: true,\n url: true,\n tel: true,\n email: true,\n password: true,\n number: true,\n date: true,\n month: true,\n week: true,\n time: true,\n datetime: true,\n 'datetime-local': true\n};\n\n/**\n * Computes whether the given element should automatically trigger the\n * `focus-visible` class being added, i.e. whether it should always match\n * `:focus-visible` when focused.\n * @param {Element} node\n * @returns {boolean}\n */\nfunction focusTriggersKeyboardModality(node) {\n const {\n type,\n tagName\n } = node;\n if (tagName === 'INPUT' && inputTypesWhitelist[type] && !node.readOnly) {\n return true;\n }\n if (tagName === 'TEXTAREA' && !node.readOnly) {\n return true;\n }\n if (node.isContentEditable) {\n return true;\n }\n return false;\n}\n\n/**\n * Keep track of our keyboard modality state with `hadKeyboardEvent`.\n * If the most recent user interaction was via the keyboard;\n * and the key press did not include a meta, alt/option, or control key;\n * then the modality is keyboard. Otherwise, the modality is not keyboard.\n * @param {KeyboardEvent} event\n */\nfunction handleKeyDown(event) {\n if (event.metaKey || event.altKey || event.ctrlKey) {\n return;\n }\n hadKeyboardEvent = true;\n}\n\n/**\n * If at any point a user clicks with a pointing device, ensure that we change\n * the modality away from keyboard.\n * This avoids the situation where a user presses a key on an already focused\n * element, and then clicks on a different element, focusing it with a\n * pointing device, while we still think we're in keyboard modality.\n */\nfunction handlePointerDown() {\n hadKeyboardEvent = false;\n}\nfunction handleVisibilityChange() {\n if (this.visibilityState === 'hidden') {\n // If the tab becomes active again, the browser will handle calling focus\n // on the element (Safari actually calls it twice).\n // If this tab change caused a blur on an element with focus-visible,\n // re-apply the class when the user switches back to the tab.\n if (hadFocusVisibleRecently) {\n hadKeyboardEvent = true;\n }\n }\n}\nfunction prepare(doc) {\n doc.addEventListener('keydown', handleKeyDown, true);\n doc.addEventListener('mousedown', handlePointerDown, true);\n doc.addEventListener('pointerdown', handlePointerDown, true);\n doc.addEventListener('touchstart', handlePointerDown, true);\n doc.addEventListener('visibilitychange', handleVisibilityChange, true);\n}\nexport function teardown(doc) {\n doc.removeEventListener('keydown', handleKeyDown, true);\n doc.removeEventListener('mousedown', handlePointerDown, true);\n doc.removeEventListener('pointerdown', handlePointerDown, true);\n doc.removeEventListener('touchstart', handlePointerDown, true);\n doc.removeEventListener('visibilitychange', handleVisibilityChange, true);\n}\nfunction isFocusVisible(event) {\n const {\n target\n } = event;\n try {\n return target.matches(':focus-visible');\n } catch (error) {\n // Browsers not implementing :focus-visible will throw a SyntaxError.\n // We use our own heuristic for those browsers.\n // Rethrow might be better if it's not the expected error but do we really\n // want to crash if focus-visible malfunctioned?\n }\n\n // No need for validFocusTarget check. The user does that by attaching it to\n // focusable events only.\n return hadKeyboardEvent || focusTriggersKeyboardModality(target);\n}\nexport default function useIsFocusVisible() {\n const ref = React.useCallback(node => {\n if (node != null) {\n prepare(node.ownerDocument);\n }\n }, []);\n const isFocusVisibleRef = React.useRef(false);\n\n /**\n * Should be called if a blur event is fired\n */\n function handleBlurVisible() {\n // checking against potential state variable does not suffice if we focus and blur synchronously.\n // React wouldn't have time to trigger a re-render so `focusVisible` would be stale.\n // Ideally we would adjust `isFocusVisible(event)` to look at `relatedTarget` for blur events.\n // This doesn't work in IE11 due to https://github.com/facebook/react/issues/3751\n // TODO: check again if React releases their internal changes to focus event handling (https://github.com/facebook/react/pull/19186).\n if (isFocusVisibleRef.current) {\n // To detect a tab/window switch, we look for a blur event followed\n // rapidly by a visibility change.\n // If we don't see a visibility change within 100ms, it's probably a\n // regular focus change.\n hadFocusVisibleRecently = true;\n hadFocusVisibleRecentlyTimeout.start(100, () => {\n hadFocusVisibleRecently = false;\n });\n isFocusVisibleRef.current = false;\n return true;\n }\n return false;\n }\n\n /**\n * Should be called if a blur event is fired\n */\n function handleFocusVisible(event) {\n if (isFocusVisible(event)) {\n isFocusVisibleRef.current = true;\n return true;\n }\n return false;\n }\n return {\n isFocusVisibleRef,\n onFocus: handleFocusVisible,\n onBlur: handleBlurVisible,\n ref\n };\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\n/**\n * Add keys, values of `defaultProps` that does not exist in `props`\n * @param {object} defaultProps\n * @param {object} props\n * @returns {object} resolved props\n */\nexport default function resolveProps(defaultProps, props) {\n const output = _extends({}, props);\n Object.keys(defaultProps).forEach(propName => {\n if (propName.toString().match(/^(components|slots)$/)) {\n output[propName] = _extends({}, defaultProps[propName], output[propName]);\n } else if (propName.toString().match(/^(componentsProps|slotProps)$/)) {\n const defaultSlotProps = defaultProps[propName] || {};\n const slotProps = props[propName];\n output[propName] = {};\n if (!slotProps || !Object.keys(slotProps)) {\n // Reduce the iteration if the slot props is empty\n output[propName] = defaultSlotProps;\n } else if (!defaultSlotProps || !Object.keys(defaultSlotProps)) {\n // Reduce the iteration if the default slot props is empty\n output[propName] = slotProps;\n } else {\n output[propName] = _extends({}, slotProps);\n Object.keys(defaultSlotProps).forEach(slotPropName => {\n output[propName][slotPropName] = resolveProps(defaultSlotProps[slotPropName], slotProps[slotPropName]);\n });\n }\n } else if (output[propName] === undefined) {\n output[propName] = defaultProps[propName];\n }\n });\n return output;\n}","export default function composeClasses(slots, getUtilityClass, classes = undefined) {\n const output = {};\n Object.keys(slots).forEach(\n // `Object.keys(slots)` can't be wider than `T` because we infer `T` from `slots`.\n // @ts-expect-error https://github.com/microsoft/TypeScript/pull/12253#issuecomment-263132208\n slot => {\n output[slot] = slots[slot].reduce((acc, key) => {\n if (key) {\n const utilityClass = getUtilityClass(key);\n if (utilityClass !== '') {\n acc.push(utilityClass);\n }\n if (classes && classes[key]) {\n acc.push(classes[key]);\n }\n }\n return acc;\n }, []).join(' ');\n });\n return output;\n}","const defaultGenerator = componentName => componentName;\nconst createClassNameGenerator = () => {\n let generate = defaultGenerator;\n return {\n configure(generator) {\n generate = generator;\n },\n generate(componentName) {\n return generate(componentName);\n },\n reset() {\n generate = defaultGenerator;\n }\n };\n};\nconst ClassNameGenerator = createClassNameGenerator();\nexport default ClassNameGenerator;","import ClassNameGenerator from '../ClassNameGenerator';\nexport const globalStateClasses = {\n active: 'active',\n checked: 'checked',\n completed: 'completed',\n disabled: 'disabled',\n error: 'error',\n expanded: 'expanded',\n focused: 'focused',\n focusVisible: 'focusVisible',\n open: 'open',\n readOnly: 'readOnly',\n required: 'required',\n selected: 'selected'\n};\nexport default function generateUtilityClass(componentName, slot, globalStatePrefix = 'Mui') {\n const globalStateClass = globalStateClasses[slot];\n return globalStateClass ? `${globalStatePrefix}-${globalStateClass}` : `${ClassNameGenerator.generate(componentName)}-${slot}`;\n}\nexport function isGlobalState(slot) {\n return globalStateClasses[slot] !== undefined;\n}","import generateUtilityClass from '../generateUtilityClass';\nexport default function generateUtilityClasses(componentName, slots, globalStatePrefix = 'Mui') {\n const result = {};\n slots.forEach(slot => {\n result[slot] = generateUtilityClass(componentName, slot, globalStatePrefix);\n });\n return result;\n}","function clamp(val, min = Number.MIN_SAFE_INTEGER, max = Number.MAX_SAFE_INTEGER) {\n return Math.max(min, Math.min(val, max));\n}\nexport default clamp;","export default function _objectWithoutPropertiesLoose(source, excluded) {\n if (source == null) return {};\n var target = {};\n var sourceKeys = Object.keys(source);\n var key, i;\n for (i = 0; i < sourceKeys.length; i++) {\n key = sourceKeys[i];\n if (excluded.indexOf(key) >= 0) continue;\n target[key] = source[key];\n }\n return target;\n}","import _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nconst _excluded = [\"values\", \"unit\", \"step\"];\n// Sorted ASC by size. That's important.\n// It can't be configured as it's used statically for propTypes.\nexport const breakpointKeys = ['xs', 'sm', 'md', 'lg', 'xl'];\nconst sortBreakpointsValues = values => {\n const breakpointsAsArray = Object.keys(values).map(key => ({\n key,\n val: values[key]\n })) || [];\n // Sort in ascending order\n breakpointsAsArray.sort((breakpoint1, breakpoint2) => breakpoint1.val - breakpoint2.val);\n return breakpointsAsArray.reduce((acc, obj) => {\n return _extends({}, acc, {\n [obj.key]: obj.val\n });\n }, {});\n};\n\n// Keep in mind that @media is inclusive by the CSS specification.\nexport default function createBreakpoints(breakpoints) {\n const {\n // The breakpoint **start** at this value.\n // For instance with the first breakpoint xs: [xs, sm).\n values = {\n xs: 0,\n // phone\n sm: 600,\n // tablet\n md: 900,\n // small laptop\n lg: 1200,\n // desktop\n xl: 1536 // large screen\n },\n unit = 'px',\n step = 5\n } = breakpoints,\n other = _objectWithoutPropertiesLoose(breakpoints, _excluded);\n const sortedValues = sortBreakpointsValues(values);\n const keys = Object.keys(sortedValues);\n function up(key) {\n const value = typeof values[key] === 'number' ? values[key] : key;\n return `@media (min-width:${value}${unit})`;\n }\n function down(key) {\n const value = typeof values[key] === 'number' ? values[key] : key;\n return `@media (max-width:${value - step / 100}${unit})`;\n }\n function between(start, end) {\n const endIndex = keys.indexOf(end);\n return `@media (min-width:${typeof values[start] === 'number' ? values[start] : start}${unit}) and ` + `(max-width:${(endIndex !== -1 && typeof values[keys[endIndex]] === 'number' ? values[keys[endIndex]] : end) - step / 100}${unit})`;\n }\n function only(key) {\n if (keys.indexOf(key) + 1 < keys.length) {\n return between(key, keys[keys.indexOf(key) + 1]);\n }\n return up(key);\n }\n function not(key) {\n // handle first and last key separately, for better readability\n const keyIndex = keys.indexOf(key);\n if (keyIndex === 0) {\n return up(keys[1]);\n }\n if (keyIndex === keys.length - 1) {\n return down(keys[keyIndex]);\n }\n return between(key, keys[keys.indexOf(key) + 1]).replace('@media', '@media not all and');\n }\n return _extends({\n keys,\n values: sortedValues,\n up,\n down,\n between,\n only,\n not,\n unit\n }, other);\n}","const shape = {\n borderRadius: 4\n};\nexport default shape;","import PropTypes from 'prop-types';\nconst responsivePropType = process.env.NODE_ENV !== 'production' ? PropTypes.oneOfType([PropTypes.number, PropTypes.string, PropTypes.object, PropTypes.array]) : {};\nexport default responsivePropType;","import deepmerge from '@mui/utils/deepmerge';\nfunction merge(acc, item) {\n if (!item) {\n return acc;\n }\n return deepmerge(acc, item, {\n clone: false // No need to clone deep, it's way faster.\n });\n}\nexport default merge;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport PropTypes from 'prop-types';\nimport deepmerge from '@mui/utils/deepmerge';\nimport merge from './merge';\n\n// The breakpoint **start** at this value.\n// For instance with the first breakpoint xs: [xs, sm[.\nexport const values = {\n xs: 0,\n // phone\n sm: 600,\n // tablet\n md: 900,\n // small laptop\n lg: 1200,\n // desktop\n xl: 1536 // large screen\n};\nconst defaultBreakpoints = {\n // Sorted ASC by size. That's important.\n // It can't be configured as it's used statically for propTypes.\n keys: ['xs', 'sm', 'md', 'lg', 'xl'],\n up: key => `@media (min-width:${values[key]}px)`\n};\nexport function handleBreakpoints(props, propValue, styleFromPropValue) {\n const theme = props.theme || {};\n if (Array.isArray(propValue)) {\n const themeBreakpoints = theme.breakpoints || defaultBreakpoints;\n return propValue.reduce((acc, item, index) => {\n acc[themeBreakpoints.up(themeBreakpoints.keys[index])] = styleFromPropValue(propValue[index]);\n return acc;\n }, {});\n }\n if (typeof propValue === 'object') {\n const themeBreakpoints = theme.breakpoints || defaultBreakpoints;\n return Object.keys(propValue).reduce((acc, breakpoint) => {\n // key is breakpoint\n if (Object.keys(themeBreakpoints.values || values).indexOf(breakpoint) !== -1) {\n const mediaKey = themeBreakpoints.up(breakpoint);\n acc[mediaKey] = styleFromPropValue(propValue[breakpoint], breakpoint);\n } else {\n const cssKey = breakpoint;\n acc[cssKey] = propValue[cssKey];\n }\n return acc;\n }, {});\n }\n const output = styleFromPropValue(propValue);\n return output;\n}\nfunction breakpoints(styleFunction) {\n // false positive\n // eslint-disable-next-line react/function-component-definition\n const newStyleFunction = props => {\n const theme = props.theme || {};\n const base = styleFunction(props);\n const themeBreakpoints = theme.breakpoints || defaultBreakpoints;\n const extended = themeBreakpoints.keys.reduce((acc, key) => {\n if (props[key]) {\n acc = acc || {};\n acc[themeBreakpoints.up(key)] = styleFunction(_extends({\n theme\n }, props[key]));\n }\n return acc;\n }, null);\n return merge(base, extended);\n };\n newStyleFunction.propTypes = process.env.NODE_ENV !== 'production' ? _extends({}, styleFunction.propTypes, {\n xs: PropTypes.object,\n sm: PropTypes.object,\n md: PropTypes.object,\n lg: PropTypes.object,\n xl: PropTypes.object\n }) : {};\n newStyleFunction.filterProps = ['xs', 'sm', 'md', 'lg', 'xl', ...styleFunction.filterProps];\n return newStyleFunction;\n}\nexport function createEmptyBreakpointObject(breakpointsInput = {}) {\n var _breakpointsInput$key;\n const breakpointsInOrder = (_breakpointsInput$key = breakpointsInput.keys) == null ? void 0 : _breakpointsInput$key.reduce((acc, key) => {\n const breakpointStyleKey = breakpointsInput.up(key);\n acc[breakpointStyleKey] = {};\n return acc;\n }, {});\n return breakpointsInOrder || {};\n}\nexport function removeUnusedBreakpoints(breakpointKeys, style) {\n return breakpointKeys.reduce((acc, key) => {\n const breakpointOutput = acc[key];\n const isBreakpointUnused = !breakpointOutput || Object.keys(breakpointOutput).length === 0;\n if (isBreakpointUnused) {\n delete acc[key];\n }\n return acc;\n }, style);\n}\nexport function mergeBreakpointsInOrder(breakpointsInput, ...styles) {\n const emptyBreakpoints = createEmptyBreakpointObject(breakpointsInput);\n const mergedOutput = [emptyBreakpoints, ...styles].reduce((prev, next) => deepmerge(prev, next), {});\n return removeUnusedBreakpoints(Object.keys(emptyBreakpoints), mergedOutput);\n}\n\n// compute base for responsive values; e.g.,\n// [1,2,3] => {xs: true, sm: true, md: true}\n// {xs: 1, sm: 2, md: 3} => {xs: true, sm: true, md: true}\nexport function computeBreakpointsBase(breakpointValues, themeBreakpoints) {\n // fixed value\n if (typeof breakpointValues !== 'object') {\n return {};\n }\n const base = {};\n const breakpointsKeys = Object.keys(themeBreakpoints);\n if (Array.isArray(breakpointValues)) {\n breakpointsKeys.forEach((breakpoint, i) => {\n if (i < breakpointValues.length) {\n base[breakpoint] = true;\n }\n });\n } else {\n breakpointsKeys.forEach(breakpoint => {\n if (breakpointValues[breakpoint] != null) {\n base[breakpoint] = true;\n }\n });\n }\n return base;\n}\nexport function resolveBreakpointValues({\n values: breakpointValues,\n breakpoints: themeBreakpoints,\n base: customBase\n}) {\n const base = customBase || computeBreakpointsBase(breakpointValues, themeBreakpoints);\n const keys = Object.keys(base);\n if (keys.length === 0) {\n return breakpointValues;\n }\n let previous;\n return keys.reduce((acc, breakpoint, i) => {\n if (Array.isArray(breakpointValues)) {\n acc[breakpoint] = breakpointValues[i] != null ? breakpointValues[i] : breakpointValues[previous];\n previous = i;\n } else if (typeof breakpointValues === 'object') {\n acc[breakpoint] = breakpointValues[breakpoint] != null ? breakpointValues[breakpoint] : breakpointValues[previous];\n previous = breakpoint;\n } else {\n acc[breakpoint] = breakpointValues;\n }\n return acc;\n }, {});\n}\nexport default breakpoints;","import capitalize from '@mui/utils/capitalize';\nimport responsivePropType from './responsivePropType';\nimport { handleBreakpoints } from './breakpoints';\nexport function getPath(obj, path, checkVars = true) {\n if (!path || typeof path !== 'string') {\n return null;\n }\n\n // Check if CSS variables are used\n if (obj && obj.vars && checkVars) {\n const val = `vars.${path}`.split('.').reduce((acc, item) => acc && acc[item] ? acc[item] : null, obj);\n if (val != null) {\n return val;\n }\n }\n return path.split('.').reduce((acc, item) => {\n if (acc && acc[item] != null) {\n return acc[item];\n }\n return null;\n }, obj);\n}\nexport function getStyleValue(themeMapping, transform, propValueFinal, userValue = propValueFinal) {\n let value;\n if (typeof themeMapping === 'function') {\n value = themeMapping(propValueFinal);\n } else if (Array.isArray(themeMapping)) {\n value = themeMapping[propValueFinal] || userValue;\n } else {\n value = getPath(themeMapping, propValueFinal) || userValue;\n }\n if (transform) {\n value = transform(value, userValue, themeMapping);\n }\n return value;\n}\nfunction style(options) {\n const {\n prop,\n cssProperty = options.prop,\n themeKey,\n transform\n } = options;\n\n // false positive\n // eslint-disable-next-line react/function-component-definition\n const fn = props => {\n if (props[prop] == null) {\n return null;\n }\n const propValue = props[prop];\n const theme = props.theme;\n const themeMapping = getPath(theme, themeKey) || {};\n const styleFromPropValue = propValueFinal => {\n let value = getStyleValue(themeMapping, transform, propValueFinal);\n if (propValueFinal === value && typeof propValueFinal === 'string') {\n // Haven't found value\n value = getStyleValue(themeMapping, transform, `${prop}${propValueFinal === 'default' ? '' : capitalize(propValueFinal)}`, propValueFinal);\n }\n if (cssProperty === false) {\n return value;\n }\n return {\n [cssProperty]: value\n };\n };\n return handleBreakpoints(props, propValue, styleFromPropValue);\n };\n fn.propTypes = process.env.NODE_ENV !== 'production' ? {\n [prop]: responsivePropType\n } : {};\n fn.filterProps = [prop];\n return fn;\n}\nexport default style;","export default function memoize(fn) {\n const cache = {};\n return arg => {\n if (cache[arg] === undefined) {\n cache[arg] = fn(arg);\n }\n return cache[arg];\n };\n}","import responsivePropType from './responsivePropType';\nimport { handleBreakpoints } from './breakpoints';\nimport { getPath } from './style';\nimport merge from './merge';\nimport memoize from './memoize';\nconst properties = {\n m: 'margin',\n p: 'padding'\n};\nconst directions = {\n t: 'Top',\n r: 'Right',\n b: 'Bottom',\n l: 'Left',\n x: ['Left', 'Right'],\n y: ['Top', 'Bottom']\n};\nconst aliases = {\n marginX: 'mx',\n marginY: 'my',\n paddingX: 'px',\n paddingY: 'py'\n};\n\n// memoize() impact:\n// From 300,000 ops/sec\n// To 350,000 ops/sec\nconst getCssProperties = memoize(prop => {\n // It's not a shorthand notation.\n if (prop.length > 2) {\n if (aliases[prop]) {\n prop = aliases[prop];\n } else {\n return [prop];\n }\n }\n const [a, b] = prop.split('');\n const property = properties[a];\n const direction = directions[b] || '';\n return Array.isArray(direction) ? direction.map(dir => property + dir) : [property + direction];\n});\nexport const marginKeys = ['m', 'mt', 'mr', 'mb', 'ml', 'mx', 'my', 'margin', 'marginTop', 'marginRight', 'marginBottom', 'marginLeft', 'marginX', 'marginY', 'marginInline', 'marginInlineStart', 'marginInlineEnd', 'marginBlock', 'marginBlockStart', 'marginBlockEnd'];\nexport const paddingKeys = ['p', 'pt', 'pr', 'pb', 'pl', 'px', 'py', 'padding', 'paddingTop', 'paddingRight', 'paddingBottom', 'paddingLeft', 'paddingX', 'paddingY', 'paddingInline', 'paddingInlineStart', 'paddingInlineEnd', 'paddingBlock', 'paddingBlockStart', 'paddingBlockEnd'];\nconst spacingKeys = [...marginKeys, ...paddingKeys];\nexport function createUnaryUnit(theme, themeKey, defaultValue, propName) {\n var _getPath;\n const themeSpacing = (_getPath = getPath(theme, themeKey, false)) != null ? _getPath : defaultValue;\n if (typeof themeSpacing === 'number') {\n return abs => {\n if (typeof abs === 'string') {\n return abs;\n }\n if (process.env.NODE_ENV !== 'production') {\n if (typeof abs !== 'number') {\n console.error(`MUI: Expected ${propName} argument to be a number or a string, got ${abs}.`);\n }\n }\n return themeSpacing * abs;\n };\n }\n if (Array.isArray(themeSpacing)) {\n return abs => {\n if (typeof abs === 'string') {\n return abs;\n }\n if (process.env.NODE_ENV !== 'production') {\n if (!Number.isInteger(abs)) {\n console.error([`MUI: The \\`theme.${themeKey}\\` array type cannot be combined with non integer values.` + `You should either use an integer value that can be used as index, or define the \\`theme.${themeKey}\\` as a number.`].join('\\n'));\n } else if (abs > themeSpacing.length - 1) {\n console.error([`MUI: The value provided (${abs}) overflows.`, `The supported values are: ${JSON.stringify(themeSpacing)}.`, `${abs} > ${themeSpacing.length - 1}, you need to add the missing values.`].join('\\n'));\n }\n }\n return themeSpacing[abs];\n };\n }\n if (typeof themeSpacing === 'function') {\n return themeSpacing;\n }\n if (process.env.NODE_ENV !== 'production') {\n console.error([`MUI: The \\`theme.${themeKey}\\` value (${themeSpacing}) is invalid.`, 'It should be a number, an array or a function.'].join('\\n'));\n }\n return () => undefined;\n}\nexport function createUnarySpacing(theme) {\n return createUnaryUnit(theme, 'spacing', 8, 'spacing');\n}\nexport function getValue(transformer, propValue) {\n if (typeof propValue === 'string' || propValue == null) {\n return propValue;\n }\n const abs = Math.abs(propValue);\n const transformed = transformer(abs);\n if (propValue >= 0) {\n return transformed;\n }\n if (typeof transformed === 'number') {\n return -transformed;\n }\n return `-${transformed}`;\n}\nexport function getStyleFromPropValue(cssProperties, transformer) {\n return propValue => cssProperties.reduce((acc, cssProperty) => {\n acc[cssProperty] = getValue(transformer, propValue);\n return acc;\n }, {});\n}\nfunction resolveCssProperty(props, keys, prop, transformer) {\n // Using a hash computation over an array iteration could be faster, but with only 28 items,\n // it's doesn't worth the bundle size.\n if (keys.indexOf(prop) === -1) {\n return null;\n }\n const cssProperties = getCssProperties(prop);\n const styleFromPropValue = getStyleFromPropValue(cssProperties, transformer);\n const propValue = props[prop];\n return handleBreakpoints(props, propValue, styleFromPropValue);\n}\nfunction style(props, keys) {\n const transformer = createUnarySpacing(props.theme);\n return Object.keys(props).map(prop => resolveCssProperty(props, keys, prop, transformer)).reduce(merge, {});\n}\nexport function margin(props) {\n return style(props, marginKeys);\n}\nmargin.propTypes = process.env.NODE_ENV !== 'production' ? marginKeys.reduce((obj, key) => {\n obj[key] = responsivePropType;\n return obj;\n}, {}) : {};\nmargin.filterProps = marginKeys;\nexport function padding(props) {\n return style(props, paddingKeys);\n}\npadding.propTypes = process.env.NODE_ENV !== 'production' ? paddingKeys.reduce((obj, key) => {\n obj[key] = responsivePropType;\n return obj;\n}, {}) : {};\npadding.filterProps = paddingKeys;\nfunction spacing(props) {\n return style(props, spacingKeys);\n}\nspacing.propTypes = process.env.NODE_ENV !== 'production' ? spacingKeys.reduce((obj, key) => {\n obj[key] = responsivePropType;\n return obj;\n}, {}) : {};\nspacing.filterProps = spacingKeys;\nexport default spacing;","import { createUnarySpacing } from '../spacing';\n\n// The different signatures imply different meaning for their arguments that can't be expressed structurally.\n// We express the difference with variable names.\n\nexport default function createSpacing(spacingInput = 8) {\n // Already transformed.\n if (spacingInput.mui) {\n return spacingInput;\n }\n\n // Material Design layouts are visually balanced. Most measurements align to an 8dp grid, which aligns both spacing and the overall layout.\n // Smaller components, such as icons, can align to a 4dp grid.\n // https://m2.material.io/design/layout/understanding-layout.html\n const transform = createUnarySpacing({\n spacing: spacingInput\n });\n const spacing = (...argsInput) => {\n if (process.env.NODE_ENV !== 'production') {\n if (!(argsInput.length <= 4)) {\n console.error(`MUI: Too many arguments provided, expected between 0 and 4, got ${argsInput.length}`);\n }\n }\n const args = argsInput.length === 0 ? [1] : argsInput;\n return args.map(argument => {\n const output = transform(argument);\n return typeof output === 'number' ? `${output}px` : output;\n }).join(' ');\n };\n spacing.mui = true;\n return spacing;\n}","import merge from './merge';\nfunction compose(...styles) {\n const handlers = styles.reduce((acc, style) => {\n style.filterProps.forEach(prop => {\n acc[prop] = style;\n });\n return acc;\n }, {});\n\n // false positive\n // eslint-disable-next-line react/function-component-definition\n const fn = props => {\n return Object.keys(props).reduce((acc, prop) => {\n if (handlers[prop]) {\n return merge(acc, handlers[prop](props));\n }\n return acc;\n }, {});\n };\n fn.propTypes = process.env.NODE_ENV !== 'production' ? styles.reduce((acc, style) => Object.assign(acc, style.propTypes), {}) : {};\n fn.filterProps = styles.reduce((acc, style) => acc.concat(style.filterProps), []);\n return fn;\n}\nexport default compose;","import responsivePropType from './responsivePropType';\nimport style from './style';\nimport compose from './compose';\nimport { createUnaryUnit, getValue } from './spacing';\nimport { handleBreakpoints } from './breakpoints';\nexport function borderTransform(value) {\n if (typeof value !== 'number') {\n return value;\n }\n return `${value}px solid`;\n}\nfunction createBorderStyle(prop, transform) {\n return style({\n prop,\n themeKey: 'borders',\n transform\n });\n}\nexport const border = createBorderStyle('border', borderTransform);\nexport const borderTop = createBorderStyle('borderTop', borderTransform);\nexport const borderRight = createBorderStyle('borderRight', borderTransform);\nexport const borderBottom = createBorderStyle('borderBottom', borderTransform);\nexport const borderLeft = createBorderStyle('borderLeft', borderTransform);\nexport const borderColor = createBorderStyle('borderColor');\nexport const borderTopColor = createBorderStyle('borderTopColor');\nexport const borderRightColor = createBorderStyle('borderRightColor');\nexport const borderBottomColor = createBorderStyle('borderBottomColor');\nexport const borderLeftColor = createBorderStyle('borderLeftColor');\nexport const outline = createBorderStyle('outline', borderTransform);\nexport const outlineColor = createBorderStyle('outlineColor');\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const borderRadius = props => {\n if (props.borderRadius !== undefined && props.borderRadius !== null) {\n const transformer = createUnaryUnit(props.theme, 'shape.borderRadius', 4, 'borderRadius');\n const styleFromPropValue = propValue => ({\n borderRadius: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.borderRadius, styleFromPropValue);\n }\n return null;\n};\nborderRadius.propTypes = process.env.NODE_ENV !== 'production' ? {\n borderRadius: responsivePropType\n} : {};\nborderRadius.filterProps = ['borderRadius'];\nconst borders = compose(border, borderTop, borderRight, borderBottom, borderLeft, borderColor, borderTopColor, borderRightColor, borderBottomColor, borderLeftColor, borderRadius, outline, outlineColor);\nexport default borders;","import style from './style';\nimport compose from './compose';\nimport { createUnaryUnit, getValue } from './spacing';\nimport { handleBreakpoints } from './breakpoints';\nimport responsivePropType from './responsivePropType';\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const gap = props => {\n if (props.gap !== undefined && props.gap !== null) {\n const transformer = createUnaryUnit(props.theme, 'spacing', 8, 'gap');\n const styleFromPropValue = propValue => ({\n gap: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.gap, styleFromPropValue);\n }\n return null;\n};\ngap.propTypes = process.env.NODE_ENV !== 'production' ? {\n gap: responsivePropType\n} : {};\ngap.filterProps = ['gap'];\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const columnGap = props => {\n if (props.columnGap !== undefined && props.columnGap !== null) {\n const transformer = createUnaryUnit(props.theme, 'spacing', 8, 'columnGap');\n const styleFromPropValue = propValue => ({\n columnGap: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.columnGap, styleFromPropValue);\n }\n return null;\n};\ncolumnGap.propTypes = process.env.NODE_ENV !== 'production' ? {\n columnGap: responsivePropType\n} : {};\ncolumnGap.filterProps = ['columnGap'];\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const rowGap = props => {\n if (props.rowGap !== undefined && props.rowGap !== null) {\n const transformer = createUnaryUnit(props.theme, 'spacing', 8, 'rowGap');\n const styleFromPropValue = propValue => ({\n rowGap: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.rowGap, styleFromPropValue);\n }\n return null;\n};\nrowGap.propTypes = process.env.NODE_ENV !== 'production' ? {\n rowGap: responsivePropType\n} : {};\nrowGap.filterProps = ['rowGap'];\nexport const gridColumn = style({\n prop: 'gridColumn'\n});\nexport const gridRow = style({\n prop: 'gridRow'\n});\nexport const gridAutoFlow = style({\n prop: 'gridAutoFlow'\n});\nexport const gridAutoColumns = style({\n prop: 'gridAutoColumns'\n});\nexport const gridAutoRows = style({\n prop: 'gridAutoRows'\n});\nexport const gridTemplateColumns = style({\n prop: 'gridTemplateColumns'\n});\nexport const gridTemplateRows = style({\n prop: 'gridTemplateRows'\n});\nexport const gridTemplateAreas = style({\n prop: 'gridTemplateAreas'\n});\nexport const gridArea = style({\n prop: 'gridArea'\n});\nconst grid = compose(gap, columnGap, rowGap, gridColumn, gridRow, gridAutoFlow, gridAutoColumns, gridAutoRows, gridTemplateColumns, gridTemplateRows, gridTemplateAreas, gridArea);\nexport default grid;","import style from './style';\nimport compose from './compose';\nexport function paletteTransform(value, userValue) {\n if (userValue === 'grey') {\n return userValue;\n }\n return value;\n}\nexport const color = style({\n prop: 'color',\n themeKey: 'palette',\n transform: paletteTransform\n});\nexport const bgcolor = style({\n prop: 'bgcolor',\n cssProperty: 'backgroundColor',\n themeKey: 'palette',\n transform: paletteTransform\n});\nexport const backgroundColor = style({\n prop: 'backgroundColor',\n themeKey: 'palette',\n transform: paletteTransform\n});\nconst palette = compose(color, bgcolor, backgroundColor);\nexport default palette;","import style from './style';\nimport compose from './compose';\nimport { handleBreakpoints, values as breakpointsValues } from './breakpoints';\nexport function sizingTransform(value) {\n return value <= 1 && value !== 0 ? `${value * 100}%` : value;\n}\nexport const width = style({\n prop: 'width',\n transform: sizingTransform\n});\nexport const maxWidth = props => {\n if (props.maxWidth !== undefined && props.maxWidth !== null) {\n const styleFromPropValue = propValue => {\n var _props$theme, _props$theme2;\n const breakpoint = ((_props$theme = props.theme) == null || (_props$theme = _props$theme.breakpoints) == null || (_props$theme = _props$theme.values) == null ? void 0 : _props$theme[propValue]) || breakpointsValues[propValue];\n if (!breakpoint) {\n return {\n maxWidth: sizingTransform(propValue)\n };\n }\n if (((_props$theme2 = props.theme) == null || (_props$theme2 = _props$theme2.breakpoints) == null ? void 0 : _props$theme2.unit) !== 'px') {\n return {\n maxWidth: `${breakpoint}${props.theme.breakpoints.unit}`\n };\n }\n return {\n maxWidth: breakpoint\n };\n };\n return handleBreakpoints(props, props.maxWidth, styleFromPropValue);\n }\n return null;\n};\nmaxWidth.filterProps = ['maxWidth'];\nexport const minWidth = style({\n prop: 'minWidth',\n transform: sizingTransform\n});\nexport const height = style({\n prop: 'height',\n transform: sizingTransform\n});\nexport const maxHeight = style({\n prop: 'maxHeight',\n transform: sizingTransform\n});\nexport const minHeight = style({\n prop: 'minHeight',\n transform: sizingTransform\n});\nexport const sizeWidth = style({\n prop: 'size',\n cssProperty: 'width',\n transform: sizingTransform\n});\nexport const sizeHeight = style({\n prop: 'size',\n cssProperty: 'height',\n transform: sizingTransform\n});\nexport const boxSizing = style({\n prop: 'boxSizing'\n});\nconst sizing = compose(width, maxWidth, minWidth, height, maxHeight, minHeight, boxSizing);\nexport default sizing;","import { padding, margin } from '../spacing';\nimport { borderRadius, borderTransform } from '../borders';\nimport { gap, rowGap, columnGap } from '../cssGrid';\nimport { paletteTransform } from '../palette';\nimport { maxWidth, sizingTransform } from '../sizing';\nconst defaultSxConfig = {\n // borders\n border: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderTop: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderRight: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderBottom: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderLeft: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderColor: {\n themeKey: 'palette'\n },\n borderTopColor: {\n themeKey: 'palette'\n },\n borderRightColor: {\n themeKey: 'palette'\n },\n borderBottomColor: {\n themeKey: 'palette'\n },\n borderLeftColor: {\n themeKey: 'palette'\n },\n outline: {\n themeKey: 'borders',\n transform: borderTransform\n },\n outlineColor: {\n themeKey: 'palette'\n },\n borderRadius: {\n themeKey: 'shape.borderRadius',\n style: borderRadius\n },\n // palette\n color: {\n themeKey: 'palette',\n transform: paletteTransform\n },\n bgcolor: {\n themeKey: 'palette',\n cssProperty: 'backgroundColor',\n transform: paletteTransform\n },\n backgroundColor: {\n themeKey: 'palette',\n transform: paletteTransform\n },\n // spacing\n p: {\n style: padding\n },\n pt: {\n style: padding\n },\n pr: {\n style: padding\n },\n pb: {\n style: padding\n },\n pl: {\n style: padding\n },\n px: {\n style: padding\n },\n py: {\n style: padding\n },\n padding: {\n style: padding\n },\n paddingTop: {\n style: padding\n },\n paddingRight: {\n style: padding\n },\n paddingBottom: {\n style: padding\n },\n paddingLeft: {\n style: padding\n },\n paddingX: {\n style: padding\n },\n paddingY: {\n style: padding\n },\n paddingInline: {\n style: padding\n },\n paddingInlineStart: {\n style: padding\n },\n paddingInlineEnd: {\n style: padding\n },\n paddingBlock: {\n style: padding\n },\n paddingBlockStart: {\n style: padding\n },\n paddingBlockEnd: {\n style: padding\n },\n m: {\n style: margin\n },\n mt: {\n style: margin\n },\n mr: {\n style: margin\n },\n mb: {\n style: margin\n },\n ml: {\n style: margin\n },\n mx: {\n style: margin\n },\n my: {\n style: margin\n },\n margin: {\n style: margin\n },\n marginTop: {\n style: margin\n },\n marginRight: {\n style: margin\n },\n marginBottom: {\n style: margin\n },\n marginLeft: {\n style: margin\n },\n marginX: {\n style: margin\n },\n marginY: {\n style: margin\n },\n marginInline: {\n style: margin\n },\n marginInlineStart: {\n style: margin\n },\n marginInlineEnd: {\n style: margin\n },\n marginBlock: {\n style: margin\n },\n marginBlockStart: {\n style: margin\n },\n marginBlockEnd: {\n style: margin\n },\n // display\n displayPrint: {\n cssProperty: false,\n transform: value => ({\n '@media print': {\n display: value\n }\n })\n },\n display: {},\n overflow: {},\n textOverflow: {},\n visibility: {},\n whiteSpace: {},\n // flexbox\n flexBasis: {},\n flexDirection: {},\n flexWrap: {},\n justifyContent: {},\n alignItems: {},\n alignContent: {},\n order: {},\n flex: {},\n flexGrow: {},\n flexShrink: {},\n alignSelf: {},\n justifyItems: {},\n justifySelf: {},\n // grid\n gap: {\n style: gap\n },\n rowGap: {\n style: rowGap\n },\n columnGap: {\n style: columnGap\n },\n gridColumn: {},\n gridRow: {},\n gridAutoFlow: {},\n gridAutoColumns: {},\n gridAutoRows: {},\n gridTemplateColumns: {},\n gridTemplateRows: {},\n gridTemplateAreas: {},\n gridArea: {},\n // positions\n position: {},\n zIndex: {\n themeKey: 'zIndex'\n },\n top: {},\n right: {},\n bottom: {},\n left: {},\n // shadows\n boxShadow: {\n themeKey: 'shadows'\n },\n // sizing\n width: {\n transform: sizingTransform\n },\n maxWidth: {\n style: maxWidth\n },\n minWidth: {\n transform: sizingTransform\n },\n height: {\n transform: sizingTransform\n },\n maxHeight: {\n transform: sizingTransform\n },\n minHeight: {\n transform: sizingTransform\n },\n boxSizing: {},\n // typography\n fontFamily: {\n themeKey: 'typography'\n },\n fontSize: {\n themeKey: 'typography'\n },\n fontStyle: {\n themeKey: 'typography'\n },\n fontWeight: {\n themeKey: 'typography'\n },\n letterSpacing: {},\n textTransform: {},\n lineHeight: {},\n textAlign: {},\n typography: {\n cssProperty: false,\n themeKey: 'typography'\n }\n};\nexport default defaultSxConfig;","import capitalize from '@mui/utils/capitalize';\nimport merge from '../merge';\nimport { getPath, getStyleValue as getValue } from '../style';\nimport { handleBreakpoints, createEmptyBreakpointObject, removeUnusedBreakpoints } from '../breakpoints';\nimport defaultSxConfig from './defaultSxConfig';\nfunction objectsHaveSameKeys(...objects) {\n const allKeys = objects.reduce((keys, object) => keys.concat(Object.keys(object)), []);\n const union = new Set(allKeys);\n return objects.every(object => union.size === Object.keys(object).length);\n}\nfunction callIfFn(maybeFn, arg) {\n return typeof maybeFn === 'function' ? maybeFn(arg) : maybeFn;\n}\n\n// eslint-disable-next-line @typescript-eslint/naming-convention\nexport function unstable_createStyleFunctionSx() {\n function getThemeValue(prop, val, theme, config) {\n const props = {\n [prop]: val,\n theme\n };\n const options = config[prop];\n if (!options) {\n return {\n [prop]: val\n };\n }\n const {\n cssProperty = prop,\n themeKey,\n transform,\n style\n } = options;\n if (val == null) {\n return null;\n }\n\n // TODO v6: remove, see https://github.com/mui/material-ui/pull/38123\n if (themeKey === 'typography' && val === 'inherit') {\n return {\n [prop]: val\n };\n }\n const themeMapping = getPath(theme, themeKey) || {};\n if (style) {\n return style(props);\n }\n const styleFromPropValue = propValueFinal => {\n let value = getValue(themeMapping, transform, propValueFinal);\n if (propValueFinal === value && typeof propValueFinal === 'string') {\n // Haven't found value\n value = getValue(themeMapping, transform, `${prop}${propValueFinal === 'default' ? '' : capitalize(propValueFinal)}`, propValueFinal);\n }\n if (cssProperty === false) {\n return value;\n }\n return {\n [cssProperty]: value\n };\n };\n return handleBreakpoints(props, val, styleFromPropValue);\n }\n function styleFunctionSx(props) {\n var _theme$unstable_sxCon;\n const {\n sx,\n theme = {}\n } = props || {};\n if (!sx) {\n return null; // Emotion & styled-components will neglect null\n }\n const config = (_theme$unstable_sxCon = theme.unstable_sxConfig) != null ? _theme$unstable_sxCon : defaultSxConfig;\n\n /*\n * Receive `sxInput` as object or callback\n * and then recursively check keys & values to create media query object styles.\n * (the result will be used in `styled`)\n */\n function traverse(sxInput) {\n let sxObject = sxInput;\n if (typeof sxInput === 'function') {\n sxObject = sxInput(theme);\n } else if (typeof sxInput !== 'object') {\n // value\n return sxInput;\n }\n if (!sxObject) {\n return null;\n }\n const emptyBreakpoints = createEmptyBreakpointObject(theme.breakpoints);\n const breakpointsKeys = Object.keys(emptyBreakpoints);\n let css = emptyBreakpoints;\n Object.keys(sxObject).forEach(styleKey => {\n const value = callIfFn(sxObject[styleKey], theme);\n if (value !== null && value !== undefined) {\n if (typeof value === 'object') {\n if (config[styleKey]) {\n css = merge(css, getThemeValue(styleKey, value, theme, config));\n } else {\n const breakpointsValues = handleBreakpoints({\n theme\n }, value, x => ({\n [styleKey]: x\n }));\n if (objectsHaveSameKeys(breakpointsValues, value)) {\n css[styleKey] = styleFunctionSx({\n sx: value,\n theme\n });\n } else {\n css = merge(css, breakpointsValues);\n }\n }\n } else {\n css = merge(css, getThemeValue(styleKey, value, theme, config));\n }\n }\n });\n return removeUnusedBreakpoints(breakpointsKeys, css);\n }\n return Array.isArray(sx) ? sx.map(traverse) : traverse(sx);\n }\n return styleFunctionSx;\n}\nconst styleFunctionSx = unstable_createStyleFunctionSx();\nstyleFunctionSx.filterProps = ['sx'];\nexport default styleFunctionSx;","/**\n * A universal utility to style components with multiple color modes. Always use it from the theme object.\n * It works with:\n * - [Basic theme](https://mui.com/material-ui/customization/dark-mode/)\n * - [CSS theme variables](https://mui.com/material-ui/experimental-api/css-theme-variables/overview/)\n * - Zero-runtime engine\n *\n * Tips: Use an array over object spread and place `theme.applyStyles()` last.\n *\n * ✅ [{ background: '#e5e5e5' }, theme.applyStyles('dark', { background: '#1c1c1c' })]\n *\n * 🚫 { background: '#e5e5e5', ...theme.applyStyles('dark', { background: '#1c1c1c' })}\n *\n * @example\n * 1. using with `styled`:\n * ```jsx\n * const Component = styled('div')(({ theme }) => [\n * { background: '#e5e5e5' },\n * theme.applyStyles('dark', {\n * background: '#1c1c1c',\n * color: '#fff',\n * }),\n * ]);\n * ```\n *\n * @example\n * 2. using with `sx` prop:\n * ```jsx\n * [\n * { background: '#e5e5e5' },\n * theme.applyStyles('dark', {\n * background: '#1c1c1c',\n * color: '#fff',\n * }),\n * ]}\n * />\n * ```\n *\n * @example\n * 3. theming a component:\n * ```jsx\n * extendTheme({\n * components: {\n * MuiButton: {\n * styleOverrides: {\n * root: ({ theme }) => [\n * { background: '#e5e5e5' },\n * theme.applyStyles('dark', {\n * background: '#1c1c1c',\n * color: '#fff',\n * }),\n * ],\n * },\n * }\n * }\n * })\n *```\n */\nexport default function applyStyles(key, styles) {\n // @ts-expect-error this is 'any' type\n const theme = this;\n if (theme.vars && typeof theme.getColorSchemeSelector === 'function') {\n // If CssVarsProvider is used as a provider,\n // returns '* :where([data-mui-color-scheme=\"light|dark\"]) &'\n const selector = theme.getColorSchemeSelector(key).replace(/(\\[[^\\]]+\\])/, '*:where($1)');\n return {\n [selector]: styles\n };\n }\n if (theme.palette.mode === key) {\n return styles;\n }\n return {};\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"breakpoints\", \"palette\", \"spacing\", \"shape\"];\nimport deepmerge from '@mui/utils/deepmerge';\nimport createBreakpoints from './createBreakpoints';\nimport shape from './shape';\nimport createSpacing from './createSpacing';\nimport styleFunctionSx from '../styleFunctionSx/styleFunctionSx';\nimport defaultSxConfig from '../styleFunctionSx/defaultSxConfig';\nimport applyStyles from './applyStyles';\nfunction createTheme(options = {}, ...args) {\n const {\n breakpoints: breakpointsInput = {},\n palette: paletteInput = {},\n spacing: spacingInput,\n shape: shapeInput = {}\n } = options,\n other = _objectWithoutPropertiesLoose(options, _excluded);\n const breakpoints = createBreakpoints(breakpointsInput);\n const spacing = createSpacing(spacingInput);\n let muiTheme = deepmerge({\n breakpoints,\n direction: 'ltr',\n components: {},\n // Inject component definitions.\n palette: _extends({\n mode: 'light'\n }, paletteInput),\n spacing,\n shape: _extends({}, shape, shapeInput)\n }, other);\n muiTheme.applyStyles = applyStyles;\n muiTheme = args.reduce((acc, argument) => deepmerge(acc, argument), muiTheme);\n muiTheme.unstable_sxConfig = _extends({}, defaultSxConfig, other == null ? void 0 : other.unstable_sxConfig);\n muiTheme.unstable_sx = function sx(props) {\n return styleFunctionSx({\n sx: props,\n theme: this\n });\n };\n return muiTheme;\n}\nexport default createTheme;","'use client';\n\nimport * as React from 'react';\nimport { ThemeContext } from '@mui/styled-engine';\nfunction isObjectEmpty(obj) {\n return Object.keys(obj).length === 0;\n}\nfunction useTheme(defaultTheme = null) {\n const contextTheme = React.useContext(ThemeContext);\n return !contextTheme || isObjectEmpty(contextTheme) ? defaultTheme : contextTheme;\n}\nexport default useTheme;","'use client';\n\nimport createTheme from './createTheme';\nimport useThemeWithoutDefault from './useThemeWithoutDefault';\nexport const systemDefaultTheme = createTheme();\nfunction useTheme(defaultTheme = systemDefaultTheme) {\n return useThemeWithoutDefault(defaultTheme);\n}\nexport default useTheme;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"ownerState\"],\n _excluded2 = [\"variants\"],\n _excluded3 = [\"name\", \"slot\", \"skipVariantsResolver\", \"skipSx\", \"overridesResolver\"];\n/* eslint-disable no-underscore-dangle */\nimport styledEngineStyled, { internal_processStyles as processStyles } from '@mui/styled-engine';\nimport { isPlainObject } from '@mui/utils/deepmerge';\nimport capitalize from '@mui/utils/capitalize';\nimport getDisplayName from '@mui/utils/getDisplayName';\nimport createTheme from './createTheme';\nimport styleFunctionSx from './styleFunctionSx';\nfunction isEmpty(obj) {\n return Object.keys(obj).length === 0;\n}\n\n// https://github.com/emotion-js/emotion/blob/26ded6109fcd8ca9875cc2ce4564fee678a3f3c5/packages/styled/src/utils.js#L40\nfunction isStringTag(tag) {\n return typeof tag === 'string' &&\n // 96 is one less than the char code\n // for \"a\" so this is checking that\n // it's a lowercase character\n tag.charCodeAt(0) > 96;\n}\n\n// Update /system/styled/#api in case if this changes\nexport function shouldForwardProp(prop) {\n return prop !== 'ownerState' && prop !== 'theme' && prop !== 'sx' && prop !== 'as';\n}\nexport const systemDefaultTheme = createTheme();\nconst lowercaseFirstLetter = string => {\n if (!string) {\n return string;\n }\n return string.charAt(0).toLowerCase() + string.slice(1);\n};\nfunction resolveTheme({\n defaultTheme,\n theme,\n themeId\n}) {\n return isEmpty(theme) ? defaultTheme : theme[themeId] || theme;\n}\nfunction defaultOverridesResolver(slot) {\n if (!slot) {\n return null;\n }\n return (props, styles) => styles[slot];\n}\nfunction processStyleArg(callableStyle, _ref) {\n let {\n ownerState\n } = _ref,\n props = _objectWithoutPropertiesLoose(_ref, _excluded);\n const resolvedStylesArg = typeof callableStyle === 'function' ? callableStyle(_extends({\n ownerState\n }, props)) : callableStyle;\n if (Array.isArray(resolvedStylesArg)) {\n return resolvedStylesArg.flatMap(resolvedStyle => processStyleArg(resolvedStyle, _extends({\n ownerState\n }, props)));\n }\n if (!!resolvedStylesArg && typeof resolvedStylesArg === 'object' && Array.isArray(resolvedStylesArg.variants)) {\n const {\n variants = []\n } = resolvedStylesArg,\n otherStyles = _objectWithoutPropertiesLoose(resolvedStylesArg, _excluded2);\n let result = otherStyles;\n variants.forEach(variant => {\n let isMatch = true;\n if (typeof variant.props === 'function') {\n isMatch = variant.props(_extends({\n ownerState\n }, props, ownerState));\n } else {\n Object.keys(variant.props).forEach(key => {\n if ((ownerState == null ? void 0 : ownerState[key]) !== variant.props[key] && props[key] !== variant.props[key]) {\n isMatch = false;\n }\n });\n }\n if (isMatch) {\n if (!Array.isArray(result)) {\n result = [result];\n }\n result.push(typeof variant.style === 'function' ? variant.style(_extends({\n ownerState\n }, props, ownerState)) : variant.style);\n }\n });\n return result;\n }\n return resolvedStylesArg;\n}\nexport default function createStyled(input = {}) {\n const {\n themeId,\n defaultTheme = systemDefaultTheme,\n rootShouldForwardProp = shouldForwardProp,\n slotShouldForwardProp = shouldForwardProp\n } = input;\n const systemSx = props => {\n return styleFunctionSx(_extends({}, props, {\n theme: resolveTheme(_extends({}, props, {\n defaultTheme,\n themeId\n }))\n }));\n };\n systemSx.__mui_systemSx = true;\n return (tag, inputOptions = {}) => {\n // Filter out the `sx` style function from the previous styled component to prevent unnecessary styles generated by the composite components.\n processStyles(tag, styles => styles.filter(style => !(style != null && style.__mui_systemSx)));\n const {\n name: componentName,\n slot: componentSlot,\n skipVariantsResolver: inputSkipVariantsResolver,\n skipSx: inputSkipSx,\n // TODO v6: remove `lowercaseFirstLetter()` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n overridesResolver = defaultOverridesResolver(lowercaseFirstLetter(componentSlot))\n } = inputOptions,\n options = _objectWithoutPropertiesLoose(inputOptions, _excluded3);\n\n // if skipVariantsResolver option is defined, take the value, otherwise, true for root and false for other slots.\n const skipVariantsResolver = inputSkipVariantsResolver !== undefined ? inputSkipVariantsResolver :\n // TODO v6: remove `Root` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n componentSlot && componentSlot !== 'Root' && componentSlot !== 'root' || false;\n const skipSx = inputSkipSx || false;\n let label;\n if (process.env.NODE_ENV !== 'production') {\n if (componentName) {\n // TODO v6: remove `lowercaseFirstLetter()` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n label = `${componentName}-${lowercaseFirstLetter(componentSlot || 'Root')}`;\n }\n }\n let shouldForwardPropOption = shouldForwardProp;\n\n // TODO v6: remove `Root` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n if (componentSlot === 'Root' || componentSlot === 'root') {\n shouldForwardPropOption = rootShouldForwardProp;\n } else if (componentSlot) {\n // any other slot specified\n shouldForwardPropOption = slotShouldForwardProp;\n } else if (isStringTag(tag)) {\n // for string (html) tag, preserve the behavior in emotion & styled-components.\n shouldForwardPropOption = undefined;\n }\n const defaultStyledResolver = styledEngineStyled(tag, _extends({\n shouldForwardProp: shouldForwardPropOption,\n label\n }, options));\n const transformStyleArg = stylesArg => {\n // On the server Emotion doesn't use React.forwardRef for creating components, so the created\n // component stays as a function. This condition makes sure that we do not interpolate functions\n // which are basically components used as a selectors.\n if (typeof stylesArg === 'function' && stylesArg.__emotion_real !== stylesArg || isPlainObject(stylesArg)) {\n return props => processStyleArg(stylesArg, _extends({}, props, {\n theme: resolveTheme({\n theme: props.theme,\n defaultTheme,\n themeId\n })\n }));\n }\n return stylesArg;\n };\n const muiStyledResolver = (styleArg, ...expressions) => {\n let transformedStyleArg = transformStyleArg(styleArg);\n const expressionsWithDefaultTheme = expressions ? expressions.map(transformStyleArg) : [];\n if (componentName && overridesResolver) {\n expressionsWithDefaultTheme.push(props => {\n const theme = resolveTheme(_extends({}, props, {\n defaultTheme,\n themeId\n }));\n if (!theme.components || !theme.components[componentName] || !theme.components[componentName].styleOverrides) {\n return null;\n }\n const styleOverrides = theme.components[componentName].styleOverrides;\n const resolvedStyleOverrides = {};\n // TODO: v7 remove iteration and use `resolveStyleArg(styleOverrides[slot])` directly\n Object.entries(styleOverrides).forEach(([slotKey, slotStyle]) => {\n resolvedStyleOverrides[slotKey] = processStyleArg(slotStyle, _extends({}, props, {\n theme\n }));\n });\n return overridesResolver(props, resolvedStyleOverrides);\n });\n }\n if (componentName && !skipVariantsResolver) {\n expressionsWithDefaultTheme.push(props => {\n var _theme$components;\n const theme = resolveTheme(_extends({}, props, {\n defaultTheme,\n themeId\n }));\n const themeVariants = theme == null || (_theme$components = theme.components) == null || (_theme$components = _theme$components[componentName]) == null ? void 0 : _theme$components.variants;\n return processStyleArg({\n variants: themeVariants\n }, _extends({}, props, {\n theme\n }));\n });\n }\n if (!skipSx) {\n expressionsWithDefaultTheme.push(systemSx);\n }\n const numOfCustomFnsApplied = expressionsWithDefaultTheme.length - expressions.length;\n if (Array.isArray(styleArg) && numOfCustomFnsApplied > 0) {\n const placeholders = new Array(numOfCustomFnsApplied).fill('');\n // If the type is array, than we need to add placeholders in the template for the overrides, variants and the sx styles.\n transformedStyleArg = [...styleArg, ...placeholders];\n transformedStyleArg.raw = [...styleArg.raw, ...placeholders];\n }\n const Component = defaultStyledResolver(transformedStyleArg, ...expressionsWithDefaultTheme);\n if (process.env.NODE_ENV !== 'production') {\n let displayName;\n if (componentName) {\n displayName = `${componentName}${capitalize(componentSlot || '')}`;\n }\n if (displayName === undefined) {\n displayName = `Styled(${getDisplayName(tag)})`;\n }\n Component.displayName = displayName;\n }\n if (tag.muiName) {\n Component.muiName = tag.muiName;\n }\n return Component;\n };\n if (defaultStyledResolver.withConfig) {\n muiStyledResolver.withConfig = defaultStyledResolver.withConfig;\n }\n return muiStyledResolver;\n };\n}","import resolveProps from '@mui/utils/resolveProps';\nexport default function getThemeProps(params) {\n const {\n theme,\n name,\n props\n } = params;\n if (!theme || !theme.components || !theme.components[name] || !theme.components[name].defaultProps) {\n return props;\n }\n return resolveProps(theme.components[name].defaultProps, props);\n}","'use client';\n\nimport getThemeProps from './getThemeProps';\nimport useTheme from '../useTheme';\nexport default function useThemeProps({\n props,\n name,\n defaultTheme,\n themeId\n}) {\n let theme = useTheme(defaultTheme);\n if (themeId) {\n theme = theme[themeId] || theme;\n }\n const mergedProps = getThemeProps({\n theme,\n name,\n props\n });\n return mergedProps;\n}","import _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\n/* eslint-disable @typescript-eslint/naming-convention */\nimport clamp from '@mui/utils/clamp';\n/**\n * Returns a number whose value is limited to the given range.\n * @param {number} value The value to be clamped\n * @param {number} min The lower boundary of the output range\n * @param {number} max The upper boundary of the output range\n * @returns {number} A number in the range [min, max]\n */\nfunction clampWrapper(value, min = 0, max = 1) {\n if (process.env.NODE_ENV !== 'production') {\n if (value < min || value > max) {\n console.error(`MUI: The value provided ${value} is out of range [${min}, ${max}].`);\n }\n }\n return clamp(value, min, max);\n}\n\n/**\n * Converts a color from CSS hex format to CSS rgb format.\n * @param {string} color - Hex color, i.e. #nnn or #nnnnnn\n * @returns {string} A CSS rgb color string\n */\nexport function hexToRgb(color) {\n color = color.slice(1);\n const re = new RegExp(`.{1,${color.length >= 6 ? 2 : 1}}`, 'g');\n let colors = color.match(re);\n if (colors && colors[0].length === 1) {\n colors = colors.map(n => n + n);\n }\n return colors ? `rgb${colors.length === 4 ? 'a' : ''}(${colors.map((n, index) => {\n return index < 3 ? parseInt(n, 16) : Math.round(parseInt(n, 16) / 255 * 1000) / 1000;\n }).join(', ')})` : '';\n}\nfunction intToHex(int) {\n const hex = int.toString(16);\n return hex.length === 1 ? `0${hex}` : hex;\n}\n\n/**\n * Returns an object with the type and values of a color.\n *\n * Note: Does not support rgb % values.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @returns {object} - A MUI color object: {type: string, values: number[]}\n */\nexport function decomposeColor(color) {\n // Idempotent\n if (color.type) {\n return color;\n }\n if (color.charAt(0) === '#') {\n return decomposeColor(hexToRgb(color));\n }\n const marker = color.indexOf('(');\n const type = color.substring(0, marker);\n if (['rgb', 'rgba', 'hsl', 'hsla', 'color'].indexOf(type) === -1) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: Unsupported \\`${color}\\` color.\nThe following formats are supported: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color().` : _formatMuiErrorMessage(9, color));\n }\n let values = color.substring(marker + 1, color.length - 1);\n let colorSpace;\n if (type === 'color') {\n values = values.split(' ');\n colorSpace = values.shift();\n if (values.length === 4 && values[3].charAt(0) === '/') {\n values[3] = values[3].slice(1);\n }\n if (['srgb', 'display-p3', 'a98-rgb', 'prophoto-rgb', 'rec-2020'].indexOf(colorSpace) === -1) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: unsupported \\`${colorSpace}\\` color space.\nThe following color spaces are supported: srgb, display-p3, a98-rgb, prophoto-rgb, rec-2020.` : _formatMuiErrorMessage(10, colorSpace));\n }\n } else {\n values = values.split(',');\n }\n values = values.map(value => parseFloat(value));\n return {\n type,\n values,\n colorSpace\n };\n}\n\n/**\n * Returns a channel created from the input color.\n *\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @returns {string} - The channel for the color, that can be used in rgba or hsla colors\n */\nexport const colorChannel = color => {\n const decomposedColor = decomposeColor(color);\n return decomposedColor.values.slice(0, 3).map((val, idx) => decomposedColor.type.indexOf('hsl') !== -1 && idx !== 0 ? `${val}%` : val).join(' ');\n};\nexport const private_safeColorChannel = (color, warning) => {\n try {\n return colorChannel(color);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n};\n\n/**\n * Converts a color object with type and values to a string.\n * @param {object} color - Decomposed color\n * @param {string} color.type - One of: 'rgb', 'rgba', 'hsl', 'hsla', 'color'\n * @param {array} color.values - [n,n,n] or [n,n,n,n]\n * @returns {string} A CSS color string\n */\nexport function recomposeColor(color) {\n const {\n type,\n colorSpace\n } = color;\n let {\n values\n } = color;\n if (type.indexOf('rgb') !== -1) {\n // Only convert the first 3 values to int (i.e. not alpha)\n values = values.map((n, i) => i < 3 ? parseInt(n, 10) : n);\n } else if (type.indexOf('hsl') !== -1) {\n values[1] = `${values[1]}%`;\n values[2] = `${values[2]}%`;\n }\n if (type.indexOf('color') !== -1) {\n values = `${colorSpace} ${values.join(' ')}`;\n } else {\n values = `${values.join(', ')}`;\n }\n return `${type}(${values})`;\n}\n\n/**\n * Converts a color from CSS rgb format to CSS hex format.\n * @param {string} color - RGB color, i.e. rgb(n, n, n)\n * @returns {string} A CSS rgb color string, i.e. #nnnnnn\n */\nexport function rgbToHex(color) {\n // Idempotent\n if (color.indexOf('#') === 0) {\n return color;\n }\n const {\n values\n } = decomposeColor(color);\n return `#${values.map((n, i) => intToHex(i === 3 ? Math.round(255 * n) : n)).join('')}`;\n}\n\n/**\n * Converts a color from hsl format to rgb format.\n * @param {string} color - HSL color values\n * @returns {string} rgb color values\n */\nexport function hslToRgb(color) {\n color = decomposeColor(color);\n const {\n values\n } = color;\n const h = values[0];\n const s = values[1] / 100;\n const l = values[2] / 100;\n const a = s * Math.min(l, 1 - l);\n const f = (n, k = (n + h / 30) % 12) => l - a * Math.max(Math.min(k - 3, 9 - k, 1), -1);\n let type = 'rgb';\n const rgb = [Math.round(f(0) * 255), Math.round(f(8) * 255), Math.round(f(4) * 255)];\n if (color.type === 'hsla') {\n type += 'a';\n rgb.push(values[3]);\n }\n return recomposeColor({\n type,\n values: rgb\n });\n}\n/**\n * The relative brightness of any point in a color space,\n * normalized to 0 for darkest black and 1 for lightest white.\n *\n * Formula: https://www.w3.org/TR/WCAG20-TECHS/G17.html#G17-tests\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @returns {number} The relative brightness of the color in the range 0 - 1\n */\nexport function getLuminance(color) {\n color = decomposeColor(color);\n let rgb = color.type === 'hsl' || color.type === 'hsla' ? decomposeColor(hslToRgb(color)).values : color.values;\n rgb = rgb.map(val => {\n if (color.type !== 'color') {\n val /= 255; // normalized\n }\n return val <= 0.03928 ? val / 12.92 : ((val + 0.055) / 1.055) ** 2.4;\n });\n\n // Truncate at 3 digits\n return Number((0.2126 * rgb[0] + 0.7152 * rgb[1] + 0.0722 * rgb[2]).toFixed(3));\n}\n\n/**\n * Calculates the contrast ratio between two colors.\n *\n * Formula: https://www.w3.org/TR/WCAG20-TECHS/G17.html#G17-tests\n * @param {string} foreground - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla()\n * @param {string} background - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla()\n * @returns {number} A contrast ratio value in the range 0 - 21.\n */\nexport function getContrastRatio(foreground, background) {\n const lumA = getLuminance(foreground);\n const lumB = getLuminance(background);\n return (Math.max(lumA, lumB) + 0.05) / (Math.min(lumA, lumB) + 0.05);\n}\n\n/**\n * Sets the absolute transparency of a color.\n * Any existing alpha values are overwritten.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} value - value to set the alpha channel to in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function alpha(color, value) {\n color = decomposeColor(color);\n value = clampWrapper(value);\n if (color.type === 'rgb' || color.type === 'hsl') {\n color.type += 'a';\n }\n if (color.type === 'color') {\n color.values[3] = `/${value}`;\n } else {\n color.values[3] = value;\n }\n return recomposeColor(color);\n}\nexport function private_safeAlpha(color, value, warning) {\n try {\n return alpha(color, value);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Darkens a color.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} coefficient - multiplier in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function darken(color, coefficient) {\n color = decomposeColor(color);\n coefficient = clampWrapper(coefficient);\n if (color.type.indexOf('hsl') !== -1) {\n color.values[2] *= 1 - coefficient;\n } else if (color.type.indexOf('rgb') !== -1 || color.type.indexOf('color') !== -1) {\n for (let i = 0; i < 3; i += 1) {\n color.values[i] *= 1 - coefficient;\n }\n }\n return recomposeColor(color);\n}\nexport function private_safeDarken(color, coefficient, warning) {\n try {\n return darken(color, coefficient);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Lightens a color.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} coefficient - multiplier in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function lighten(color, coefficient) {\n color = decomposeColor(color);\n coefficient = clampWrapper(coefficient);\n if (color.type.indexOf('hsl') !== -1) {\n color.values[2] += (100 - color.values[2]) * coefficient;\n } else if (color.type.indexOf('rgb') !== -1) {\n for (let i = 0; i < 3; i += 1) {\n color.values[i] += (255 - color.values[i]) * coefficient;\n }\n } else if (color.type.indexOf('color') !== -1) {\n for (let i = 0; i < 3; i += 1) {\n color.values[i] += (1 - color.values[i]) * coefficient;\n }\n }\n return recomposeColor(color);\n}\nexport function private_safeLighten(color, coefficient, warning) {\n try {\n return lighten(color, coefficient);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Darken or lighten a color, depending on its luminance.\n * Light colors are darkened, dark colors are lightened.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} coefficient=0.15 - multiplier in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function emphasize(color, coefficient = 0.15) {\n return getLuminance(color) > 0.5 ? darken(color, coefficient) : lighten(color, coefficient);\n}\nexport function private_safeEmphasize(color, coefficient, warning) {\n try {\n return emphasize(color, coefficient);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Blend a transparent overlay color with a background color, resulting in a single\n * RGB color.\n * @param {string} background - CSS color\n * @param {string} overlay - CSS color\n * @param {number} opacity - Opacity multiplier in the range 0 - 1\n * @param {number} [gamma=1.0] - Gamma correction factor. For gamma-correct blending, 2.2 is usual.\n */\nexport function blend(background, overlay, opacity, gamma = 1.0) {\n const blendChannel = (b, o) => Math.round((b ** (1 / gamma) * (1 - opacity) + o ** (1 / gamma) * opacity) ** gamma);\n const backgroundColor = decomposeColor(background);\n const overlayColor = decomposeColor(overlay);\n const rgb = [blendChannel(backgroundColor.values[0], overlayColor.values[0]), blendChannel(backgroundColor.values[1], overlayColor.values[1]), blendChannel(backgroundColor.values[2], overlayColor.values[2])];\n return recomposeColor({\n type: 'rgb',\n values: rgb\n });\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nexport default function createMixins(breakpoints, mixins) {\n return _extends({\n toolbar: {\n minHeight: 56,\n [breakpoints.up('xs')]: {\n '@media (orientation: landscape)': {\n minHeight: 48\n }\n },\n [breakpoints.up('sm')]: {\n minHeight: 64\n }\n }\n }, mixins);\n}","const common = {\n black: '#000',\n white: '#fff'\n};\nexport default common;","const grey = {\n 50: '#fafafa',\n 100: '#f5f5f5',\n 200: '#eeeeee',\n 300: '#e0e0e0',\n 400: '#bdbdbd',\n 500: '#9e9e9e',\n 600: '#757575',\n 700: '#616161',\n 800: '#424242',\n 900: '#212121',\n A100: '#f5f5f5',\n A200: '#eeeeee',\n A400: '#bdbdbd',\n A700: '#616161'\n};\nexport default grey;","const purple = {\n 50: '#f3e5f5',\n 100: '#e1bee7',\n 200: '#ce93d8',\n 300: '#ba68c8',\n 400: '#ab47bc',\n 500: '#9c27b0',\n 600: '#8e24aa',\n 700: '#7b1fa2',\n 800: '#6a1b9a',\n 900: '#4a148c',\n A100: '#ea80fc',\n A200: '#e040fb',\n A400: '#d500f9',\n A700: '#aa00ff'\n};\nexport default purple;","const red = {\n 50: '#ffebee',\n 100: '#ffcdd2',\n 200: '#ef9a9a',\n 300: '#e57373',\n 400: '#ef5350',\n 500: '#f44336',\n 600: '#e53935',\n 700: '#d32f2f',\n 800: '#c62828',\n 900: '#b71c1c',\n A100: '#ff8a80',\n A200: '#ff5252',\n A400: '#ff1744',\n A700: '#d50000'\n};\nexport default red;","const orange = {\n 50: '#fff3e0',\n 100: '#ffe0b2',\n 200: '#ffcc80',\n 300: '#ffb74d',\n 400: '#ffa726',\n 500: '#ff9800',\n 600: '#fb8c00',\n 700: '#f57c00',\n 800: '#ef6c00',\n 900: '#e65100',\n A100: '#ffd180',\n A200: '#ffab40',\n A400: '#ff9100',\n A700: '#ff6d00'\n};\nexport default orange;","const blue = {\n 50: '#e3f2fd',\n 100: '#bbdefb',\n 200: '#90caf9',\n 300: '#64b5f6',\n 400: '#42a5f5',\n 500: '#2196f3',\n 600: '#1e88e5',\n 700: '#1976d2',\n 800: '#1565c0',\n 900: '#0d47a1',\n A100: '#82b1ff',\n A200: '#448aff',\n A400: '#2979ff',\n A700: '#2962ff'\n};\nexport default blue;","const lightBlue = {\n 50: '#e1f5fe',\n 100: '#b3e5fc',\n 200: '#81d4fa',\n 300: '#4fc3f7',\n 400: '#29b6f6',\n 500: '#03a9f4',\n 600: '#039be5',\n 700: '#0288d1',\n 800: '#0277bd',\n 900: '#01579b',\n A100: '#80d8ff',\n A200: '#40c4ff',\n A400: '#00b0ff',\n A700: '#0091ea'\n};\nexport default lightBlue;","const green = {\n 50: '#e8f5e9',\n 100: '#c8e6c9',\n 200: '#a5d6a7',\n 300: '#81c784',\n 400: '#66bb6a',\n 500: '#4caf50',\n 600: '#43a047',\n 700: '#388e3c',\n 800: '#2e7d32',\n 900: '#1b5e20',\n A100: '#b9f6ca',\n A200: '#69f0ae',\n A400: '#00e676',\n A700: '#00c853'\n};\nexport default green;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\nconst _excluded = [\"mode\", \"contrastThreshold\", \"tonalOffset\"];\nimport { deepmerge } from '@mui/utils';\nimport { darken, getContrastRatio, lighten } from '@mui/system';\nimport common from '../colors/common';\nimport grey from '../colors/grey';\nimport purple from '../colors/purple';\nimport red from '../colors/red';\nimport orange from '../colors/orange';\nimport blue from '../colors/blue';\nimport lightBlue from '../colors/lightBlue';\nimport green from '../colors/green';\nexport const light = {\n // The colors used to style the text.\n text: {\n // The most important text.\n primary: 'rgba(0, 0, 0, 0.87)',\n // Secondary text.\n secondary: 'rgba(0, 0, 0, 0.6)',\n // Disabled text have even lower visual prominence.\n disabled: 'rgba(0, 0, 0, 0.38)'\n },\n // The color used to divide different elements.\n divider: 'rgba(0, 0, 0, 0.12)',\n // The background colors used to style the surfaces.\n // Consistency between these values is important.\n background: {\n paper: common.white,\n default: common.white\n },\n // The colors used to style the action elements.\n action: {\n // The color of an active action like an icon button.\n active: 'rgba(0, 0, 0, 0.54)',\n // The color of an hovered action.\n hover: 'rgba(0, 0, 0, 0.04)',\n hoverOpacity: 0.04,\n // The color of a selected action.\n selected: 'rgba(0, 0, 0, 0.08)',\n selectedOpacity: 0.08,\n // The color of a disabled action.\n disabled: 'rgba(0, 0, 0, 0.26)',\n // The background color of a disabled action.\n disabledBackground: 'rgba(0, 0, 0, 0.12)',\n disabledOpacity: 0.38,\n focus: 'rgba(0, 0, 0, 0.12)',\n focusOpacity: 0.12,\n activatedOpacity: 0.12\n }\n};\nexport const dark = {\n text: {\n primary: common.white,\n secondary: 'rgba(255, 255, 255, 0.7)',\n disabled: 'rgba(255, 255, 255, 0.5)',\n icon: 'rgba(255, 255, 255, 0.5)'\n },\n divider: 'rgba(255, 255, 255, 0.12)',\n background: {\n paper: '#121212',\n default: '#121212'\n },\n action: {\n active: common.white,\n hover: 'rgba(255, 255, 255, 0.08)',\n hoverOpacity: 0.08,\n selected: 'rgba(255, 255, 255, 0.16)',\n selectedOpacity: 0.16,\n disabled: 'rgba(255, 255, 255, 0.3)',\n disabledBackground: 'rgba(255, 255, 255, 0.12)',\n disabledOpacity: 0.38,\n focus: 'rgba(255, 255, 255, 0.12)',\n focusOpacity: 0.12,\n activatedOpacity: 0.24\n }\n};\nfunction addLightOrDark(intent, direction, shade, tonalOffset) {\n const tonalOffsetLight = tonalOffset.light || tonalOffset;\n const tonalOffsetDark = tonalOffset.dark || tonalOffset * 1.5;\n if (!intent[direction]) {\n if (intent.hasOwnProperty(shade)) {\n intent[direction] = intent[shade];\n } else if (direction === 'light') {\n intent.light = lighten(intent.main, tonalOffsetLight);\n } else if (direction === 'dark') {\n intent.dark = darken(intent.main, tonalOffsetDark);\n }\n }\n}\nfunction getDefaultPrimary(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: blue[200],\n light: blue[50],\n dark: blue[400]\n };\n }\n return {\n main: blue[700],\n light: blue[400],\n dark: blue[800]\n };\n}\nfunction getDefaultSecondary(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: purple[200],\n light: purple[50],\n dark: purple[400]\n };\n }\n return {\n main: purple[500],\n light: purple[300],\n dark: purple[700]\n };\n}\nfunction getDefaultError(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: red[500],\n light: red[300],\n dark: red[700]\n };\n }\n return {\n main: red[700],\n light: red[400],\n dark: red[800]\n };\n}\nfunction getDefaultInfo(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: lightBlue[400],\n light: lightBlue[300],\n dark: lightBlue[700]\n };\n }\n return {\n main: lightBlue[700],\n light: lightBlue[500],\n dark: lightBlue[900]\n };\n}\nfunction getDefaultSuccess(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: green[400],\n light: green[300],\n dark: green[700]\n };\n }\n return {\n main: green[800],\n light: green[500],\n dark: green[900]\n };\n}\nfunction getDefaultWarning(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: orange[400],\n light: orange[300],\n dark: orange[700]\n };\n }\n return {\n main: '#ed6c02',\n // closest to orange[800] that pass 3:1.\n light: orange[500],\n dark: orange[900]\n };\n}\nexport default function createPalette(palette) {\n const {\n mode = 'light',\n contrastThreshold = 3,\n tonalOffset = 0.2\n } = palette,\n other = _objectWithoutPropertiesLoose(palette, _excluded);\n const primary = palette.primary || getDefaultPrimary(mode);\n const secondary = palette.secondary || getDefaultSecondary(mode);\n const error = palette.error || getDefaultError(mode);\n const info = palette.info || getDefaultInfo(mode);\n const success = palette.success || getDefaultSuccess(mode);\n const warning = palette.warning || getDefaultWarning(mode);\n\n // Use the same logic as\n // Bootstrap: https://github.com/twbs/bootstrap/blob/1d6e3710dd447de1a200f29e8fa521f8a0908f70/scss/_functions.scss#L59\n // and material-components-web https://github.com/material-components/material-components-web/blob/ac46b8863c4dab9fc22c4c662dc6bd1b65dd652f/packages/mdc-theme/_functions.scss#L54\n function getContrastText(background) {\n const contrastText = getContrastRatio(background, dark.text.primary) >= contrastThreshold ? dark.text.primary : light.text.primary;\n if (process.env.NODE_ENV !== 'production') {\n const contrast = getContrastRatio(background, contrastText);\n if (contrast < 3) {\n console.error([`MUI: The contrast ratio of ${contrast}:1 for ${contrastText} on ${background}`, 'falls below the WCAG recommended absolute minimum contrast ratio of 3:1.', 'https://www.w3.org/TR/2008/REC-WCAG20-20081211/#visual-audio-contrast-contrast'].join('\\n'));\n }\n }\n return contrastText;\n }\n const augmentColor = ({\n color,\n name,\n mainShade = 500,\n lightShade = 300,\n darkShade = 700\n }) => {\n color = _extends({}, color);\n if (!color.main && color[mainShade]) {\n color.main = color[mainShade];\n }\n if (!color.hasOwnProperty('main')) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: The color${name ? ` (${name})` : ''} provided to augmentColor(color) is invalid.\nThe color object needs to have a \\`main\\` property or a \\`${mainShade}\\` property.` : _formatMuiErrorMessage(11, name ? ` (${name})` : '', mainShade));\n }\n if (typeof color.main !== 'string') {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: The color${name ? ` (${name})` : ''} provided to augmentColor(color) is invalid.\n\\`color.main\\` should be a string, but \\`${JSON.stringify(color.main)}\\` was provided instead.\n\nDid you intend to use one of the following approaches?\n\nimport { green } from \"@mui/material/colors\";\n\nconst theme1 = createTheme({ palette: {\n primary: green,\n} });\n\nconst theme2 = createTheme({ palette: {\n primary: { main: green[500] },\n} });` : _formatMuiErrorMessage(12, name ? ` (${name})` : '', JSON.stringify(color.main)));\n }\n addLightOrDark(color, 'light', lightShade, tonalOffset);\n addLightOrDark(color, 'dark', darkShade, tonalOffset);\n if (!color.contrastText) {\n color.contrastText = getContrastText(color.main);\n }\n return color;\n };\n const modes = {\n dark,\n light\n };\n if (process.env.NODE_ENV !== 'production') {\n if (!modes[mode]) {\n console.error(`MUI: The palette mode \\`${mode}\\` is not supported.`);\n }\n }\n const paletteOutput = deepmerge(_extends({\n // A collection of common colors.\n common: _extends({}, common),\n // prevent mutable object.\n // The palette mode, can be light or dark.\n mode,\n // The colors used to represent primary interface elements for a user.\n primary: augmentColor({\n color: primary,\n name: 'primary'\n }),\n // The colors used to represent secondary interface elements for a user.\n secondary: augmentColor({\n color: secondary,\n name: 'secondary',\n mainShade: 'A400',\n lightShade: 'A200',\n darkShade: 'A700'\n }),\n // The colors used to represent interface elements that the user should be made aware of.\n error: augmentColor({\n color: error,\n name: 'error'\n }),\n // The colors used to represent potentially dangerous actions or important messages.\n warning: augmentColor({\n color: warning,\n name: 'warning'\n }),\n // The colors used to present information to the user that is neutral and not necessarily important.\n info: augmentColor({\n color: info,\n name: 'info'\n }),\n // The colors used to indicate the successful completion of an action that user triggered.\n success: augmentColor({\n color: success,\n name: 'success'\n }),\n // The grey colors.\n grey,\n // Used by `getContrastText()` to maximize the contrast between\n // the background and the text.\n contrastThreshold,\n // Takes a background color and returns the text color that maximizes the contrast.\n getContrastText,\n // Generate a rich color object.\n augmentColor,\n // Used by the functions below to shift a color's luminance by approximately\n // two indexes within its tonal palette.\n // E.g., shift from Red 500 to Red 300 or Red 700.\n tonalOffset\n }, modes[mode]), other);\n return paletteOutput;\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"fontFamily\", \"fontSize\", \"fontWeightLight\", \"fontWeightRegular\", \"fontWeightMedium\", \"fontWeightBold\", \"htmlFontSize\", \"allVariants\", \"pxToRem\"];\nimport { deepmerge } from '@mui/utils';\nfunction round(value) {\n return Math.round(value * 1e5) / 1e5;\n}\nconst caseAllCaps = {\n textTransform: 'uppercase'\n};\nconst defaultFontFamily = '\"Roboto\", \"Helvetica\", \"Arial\", sans-serif';\n\n/**\n * @see @link{https://m2.material.io/design/typography/the-type-system.html}\n * @see @link{https://m2.material.io/design/typography/understanding-typography.html}\n */\nexport default function createTypography(palette, typography) {\n const _ref = typeof typography === 'function' ? typography(palette) : typography,\n {\n fontFamily = defaultFontFamily,\n // The default font size of the Material Specification.\n fontSize = 14,\n // px\n fontWeightLight = 300,\n fontWeightRegular = 400,\n fontWeightMedium = 500,\n fontWeightBold = 700,\n // Tell MUI what's the font-size on the html element.\n // 16px is the default font-size used by browsers.\n htmlFontSize = 16,\n // Apply the CSS properties to all the variants.\n allVariants,\n pxToRem: pxToRem2\n } = _ref,\n other = _objectWithoutPropertiesLoose(_ref, _excluded);\n if (process.env.NODE_ENV !== 'production') {\n if (typeof fontSize !== 'number') {\n console.error('MUI: `fontSize` is required to be a number.');\n }\n if (typeof htmlFontSize !== 'number') {\n console.error('MUI: `htmlFontSize` is required to be a number.');\n }\n }\n const coef = fontSize / 14;\n const pxToRem = pxToRem2 || (size => `${size / htmlFontSize * coef}rem`);\n const buildVariant = (fontWeight, size, lineHeight, letterSpacing, casing) => _extends({\n fontFamily,\n fontWeight,\n fontSize: pxToRem(size),\n // Unitless following https://meyerweb.com/eric/thoughts/2006/02/08/unitless-line-heights/\n lineHeight\n }, fontFamily === defaultFontFamily ? {\n letterSpacing: `${round(letterSpacing / size)}em`\n } : {}, casing, allVariants);\n const variants = {\n h1: buildVariant(fontWeightLight, 96, 1.167, -1.5),\n h2: buildVariant(fontWeightLight, 60, 1.2, -0.5),\n h3: buildVariant(fontWeightRegular, 48, 1.167, 0),\n h4: buildVariant(fontWeightRegular, 34, 1.235, 0.25),\n h5: buildVariant(fontWeightRegular, 24, 1.334, 0),\n h6: buildVariant(fontWeightMedium, 20, 1.6, 0.15),\n subtitle1: buildVariant(fontWeightRegular, 16, 1.75, 0.15),\n subtitle2: buildVariant(fontWeightMedium, 14, 1.57, 0.1),\n body1: buildVariant(fontWeightRegular, 16, 1.5, 0.15),\n body2: buildVariant(fontWeightRegular, 14, 1.43, 0.15),\n button: buildVariant(fontWeightMedium, 14, 1.75, 0.4, caseAllCaps),\n caption: buildVariant(fontWeightRegular, 12, 1.66, 0.4),\n overline: buildVariant(fontWeightRegular, 12, 2.66, 1, caseAllCaps),\n // TODO v6: Remove handling of 'inherit' variant from the theme as it is already handled in Material UI's Typography component. Also, remember to remove the associated types.\n inherit: {\n fontFamily: 'inherit',\n fontWeight: 'inherit',\n fontSize: 'inherit',\n lineHeight: 'inherit',\n letterSpacing: 'inherit'\n }\n };\n return deepmerge(_extends({\n htmlFontSize,\n pxToRem,\n fontFamily,\n fontSize,\n fontWeightLight,\n fontWeightRegular,\n fontWeightMedium,\n fontWeightBold\n }, variants), other, {\n clone: false // No need to clone deep\n });\n}","const shadowKeyUmbraOpacity = 0.2;\nconst shadowKeyPenumbraOpacity = 0.14;\nconst shadowAmbientShadowOpacity = 0.12;\nfunction createShadow(...px) {\n return [`${px[0]}px ${px[1]}px ${px[2]}px ${px[3]}px rgba(0,0,0,${shadowKeyUmbraOpacity})`, `${px[4]}px ${px[5]}px ${px[6]}px ${px[7]}px rgba(0,0,0,${shadowKeyPenumbraOpacity})`, `${px[8]}px ${px[9]}px ${px[10]}px ${px[11]}px rgba(0,0,0,${shadowAmbientShadowOpacity})`].join(',');\n}\n\n// Values from https://github.com/material-components/material-components-web/blob/be8747f94574669cb5e7add1a7c54fa41a89cec7/packages/mdc-elevation/_variables.scss\nconst shadows = ['none', createShadow(0, 2, 1, -1, 0, 1, 1, 0, 0, 1, 3, 0), createShadow(0, 3, 1, -2, 0, 2, 2, 0, 0, 1, 5, 0), createShadow(0, 3, 3, -2, 0, 3, 4, 0, 0, 1, 8, 0), createShadow(0, 2, 4, -1, 0, 4, 5, 0, 0, 1, 10, 0), createShadow(0, 3, 5, -1, 0, 5, 8, 0, 0, 1, 14, 0), createShadow(0, 3, 5, -1, 0, 6, 10, 0, 0, 1, 18, 0), createShadow(0, 4, 5, -2, 0, 7, 10, 1, 0, 2, 16, 1), createShadow(0, 5, 5, -3, 0, 8, 10, 1, 0, 3, 14, 2), createShadow(0, 5, 6, -3, 0, 9, 12, 1, 0, 3, 16, 2), createShadow(0, 6, 6, -3, 0, 10, 14, 1, 0, 4, 18, 3), createShadow(0, 6, 7, -4, 0, 11, 15, 1, 0, 4, 20, 3), createShadow(0, 7, 8, -4, 0, 12, 17, 2, 0, 5, 22, 4), createShadow(0, 7, 8, -4, 0, 13, 19, 2, 0, 5, 24, 4), createShadow(0, 7, 9, -4, 0, 14, 21, 2, 0, 5, 26, 4), createShadow(0, 8, 9, -5, 0, 15, 22, 2, 0, 6, 28, 5), createShadow(0, 8, 10, -5, 0, 16, 24, 2, 0, 6, 30, 5), createShadow(0, 8, 11, -5, 0, 17, 26, 2, 0, 6, 32, 5), createShadow(0, 9, 11, -5, 0, 18, 28, 2, 0, 7, 34, 6), createShadow(0, 9, 12, -6, 0, 19, 29, 2, 0, 7, 36, 6), createShadow(0, 10, 13, -6, 0, 20, 31, 3, 0, 8, 38, 7), createShadow(0, 10, 13, -6, 0, 21, 33, 3, 0, 8, 40, 7), createShadow(0, 10, 14, -6, 0, 22, 35, 3, 0, 8, 42, 7), createShadow(0, 11, 14, -7, 0, 23, 36, 3, 0, 9, 44, 8), createShadow(0, 11, 15, -7, 0, 24, 38, 3, 0, 9, 46, 8)];\nexport default shadows;","import _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nconst _excluded = [\"duration\", \"easing\", \"delay\"];\n// Follow https://material.google.com/motion/duration-easing.html#duration-easing-natural-easing-curves\n// to learn the context in which each easing should be used.\nexport const easing = {\n // This is the most common easing curve.\n easeInOut: 'cubic-bezier(0.4, 0, 0.2, 1)',\n // Objects enter the screen at full velocity from off-screen and\n // slowly decelerate to a resting point.\n easeOut: 'cubic-bezier(0.0, 0, 0.2, 1)',\n // Objects leave the screen at full velocity. They do not decelerate when off-screen.\n easeIn: 'cubic-bezier(0.4, 0, 1, 1)',\n // The sharp curve is used by objects that may return to the screen at any time.\n sharp: 'cubic-bezier(0.4, 0, 0.6, 1)'\n};\n\n// Follow https://m2.material.io/guidelines/motion/duration-easing.html#duration-easing-common-durations\n// to learn when use what timing\nexport const duration = {\n shortest: 150,\n shorter: 200,\n short: 250,\n // most basic recommended timing\n standard: 300,\n // this is to be used in complex animations\n complex: 375,\n // recommended when something is entering screen\n enteringScreen: 225,\n // recommended when something is leaving screen\n leavingScreen: 195\n};\nfunction formatMs(milliseconds) {\n return `${Math.round(milliseconds)}ms`;\n}\nfunction getAutoHeightDuration(height) {\n if (!height) {\n return 0;\n }\n const constant = height / 36;\n\n // https://www.wolframalpha.com/input/?i=(4+%2B+15+*+(x+%2F+36+)+**+0.25+%2B+(x+%2F+36)+%2F+5)+*+10\n return Math.round((4 + 15 * constant ** 0.25 + constant / 5) * 10);\n}\nexport default function createTransitions(inputTransitions) {\n const mergedEasing = _extends({}, easing, inputTransitions.easing);\n const mergedDuration = _extends({}, duration, inputTransitions.duration);\n const create = (props = ['all'], options = {}) => {\n const {\n duration: durationOption = mergedDuration.standard,\n easing: easingOption = mergedEasing.easeInOut,\n delay = 0\n } = options,\n other = _objectWithoutPropertiesLoose(options, _excluded);\n if (process.env.NODE_ENV !== 'production') {\n const isString = value => typeof value === 'string';\n // IE11 support, replace with Number.isNaN\n // eslint-disable-next-line no-restricted-globals\n const isNumber = value => !isNaN(parseFloat(value));\n if (!isString(props) && !Array.isArray(props)) {\n console.error('MUI: Argument \"props\" must be a string or Array.');\n }\n if (!isNumber(durationOption) && !isString(durationOption)) {\n console.error(`MUI: Argument \"duration\" must be a number or a string but found ${durationOption}.`);\n }\n if (!isString(easingOption)) {\n console.error('MUI: Argument \"easing\" must be a string.');\n }\n if (!isNumber(delay) && !isString(delay)) {\n console.error('MUI: Argument \"delay\" must be a number or a string.');\n }\n if (typeof options !== 'object') {\n console.error(['MUI: Secong argument of transition.create must be an object.', \"Arguments should be either `create('prop1', options)` or `create(['prop1', 'prop2'], options)`\"].join('\\n'));\n }\n if (Object.keys(other).length !== 0) {\n console.error(`MUI: Unrecognized argument(s) [${Object.keys(other).join(',')}].`);\n }\n }\n return (Array.isArray(props) ? props : [props]).map(animatedProp => `${animatedProp} ${typeof durationOption === 'string' ? durationOption : formatMs(durationOption)} ${easingOption} ${typeof delay === 'string' ? delay : formatMs(delay)}`).join(',');\n };\n return _extends({\n getAutoHeightDuration,\n create\n }, inputTransitions, {\n easing: mergedEasing,\n duration: mergedDuration\n });\n}","// We need to centralize the zIndex definitions as they work\n// like global values in the browser.\nconst zIndex = {\n mobileStepper: 1000,\n fab: 1050,\n speedDial: 1050,\n appBar: 1100,\n drawer: 1200,\n modal: 1300,\n snackbar: 1400,\n tooltip: 1500\n};\nexport default zIndex;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\nconst _excluded = [\"breakpoints\", \"mixins\", \"spacing\", \"palette\", \"transitions\", \"typography\", \"shape\"];\nimport { deepmerge } from '@mui/utils';\nimport { createTheme as systemCreateTheme, unstable_defaultSxConfig as defaultSxConfig, unstable_styleFunctionSx as styleFunctionSx } from '@mui/system';\nimport generateUtilityClass from '@mui/utils/generateUtilityClass';\nimport createMixins from './createMixins';\nimport createPalette from './createPalette';\nimport createTypography from './createTypography';\nimport shadows from './shadows';\nimport createTransitions from './createTransitions';\nimport zIndex from './zIndex';\nfunction createTheme(options = {}, ...args) {\n const {\n mixins: mixinsInput = {},\n palette: paletteInput = {},\n transitions: transitionsInput = {},\n typography: typographyInput = {}\n } = options,\n other = _objectWithoutPropertiesLoose(options, _excluded);\n if (options.vars) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: \\`vars\\` is a private field used for CSS variables support.\nPlease use another name.` : _formatMuiErrorMessage(18));\n }\n const palette = createPalette(paletteInput);\n const systemTheme = systemCreateTheme(options);\n let muiTheme = deepmerge(systemTheme, {\n mixins: createMixins(systemTheme.breakpoints, mixinsInput),\n palette,\n // Don't use [...shadows] until you've verified its transpiled code is not invoking the iterator protocol.\n shadows: shadows.slice(),\n typography: createTypography(palette, typographyInput),\n transitions: createTransitions(transitionsInput),\n zIndex: _extends({}, zIndex)\n });\n muiTheme = deepmerge(muiTheme, other);\n muiTheme = args.reduce((acc, argument) => deepmerge(acc, argument), muiTheme);\n if (process.env.NODE_ENV !== 'production') {\n // TODO v6: Refactor to use globalStateClassesMapping from @mui/utils once `readOnly` state class is used in Rating component.\n const stateClasses = ['active', 'checked', 'completed', 'disabled', 'error', 'expanded', 'focused', 'focusVisible', 'required', 'selected'];\n const traverse = (node, component) => {\n let key;\n\n // eslint-disable-next-line guard-for-in, no-restricted-syntax\n for (key in node) {\n const child = node[key];\n if (stateClasses.indexOf(key) !== -1 && Object.keys(child).length > 0) {\n if (process.env.NODE_ENV !== 'production') {\n const stateClass = generateUtilityClass('', key);\n console.error([`MUI: The \\`${component}\\` component increases ` + `the CSS specificity of the \\`${key}\\` internal state.`, 'You can not override it like this: ', JSON.stringify(node, null, 2), '', `Instead, you need to use the '&.${stateClass}' syntax:`, JSON.stringify({\n root: {\n [`&.${stateClass}`]: child\n }\n }, null, 2), '', 'https://mui.com/r/state-classes-guide'].join('\\n'));\n }\n // Remove the style to prevent global conflicts.\n node[key] = {};\n }\n }\n };\n Object.keys(muiTheme.components).forEach(component => {\n const styleOverrides = muiTheme.components[component].styleOverrides;\n if (styleOverrides && component.indexOf('Mui') === 0) {\n traverse(styleOverrides, component);\n }\n });\n }\n muiTheme.unstable_sxConfig = _extends({}, defaultSxConfig, other == null ? void 0 : other.unstable_sxConfig);\n muiTheme.unstable_sx = function sx(props) {\n return styleFunctionSx({\n sx: props,\n theme: this\n });\n };\n return muiTheme;\n}\nlet warnedOnce = false;\nexport function createMuiTheme(...args) {\n if (process.env.NODE_ENV !== 'production') {\n if (!warnedOnce) {\n warnedOnce = true;\n console.error(['MUI: the createMuiTheme function was renamed to createTheme.', '', \"You should use `import { createTheme } from '@mui/material/styles'`\"].join('\\n'));\n }\n }\n return createTheme(...args);\n}\nexport default createTheme;","'use client';\n\nimport createTheme from './createTheme';\nconst defaultTheme = createTheme();\nexport default defaultTheme;","export default '$$material';","'use client';\n\nimport { useThemeProps as systemUseThemeProps } from '@mui/system';\nimport defaultTheme from './defaultTheme';\nimport THEME_ID from './identifier';\nexport default function useThemeProps({\n props,\n name\n}) {\n return systemUseThemeProps({\n props,\n name,\n defaultTheme,\n themeId: THEME_ID\n });\n}","'use client';\n\nimport { createStyled, shouldForwardProp } from '@mui/system';\nimport defaultTheme from './defaultTheme';\nimport THEME_ID from './identifier';\nexport const rootShouldForwardProp = prop => shouldForwardProp(prop) && prop !== 'classes';\nexport const slotShouldForwardProp = shouldForwardProp;\nconst styled = createStyled({\n themeId: THEME_ID,\n defaultTheme,\n rootShouldForwardProp\n});\nexport default styled;","import generateUtilityClasses from '@mui/utils/generateUtilityClasses';\nimport generateUtilityClass from '@mui/utils/generateUtilityClass';\nexport function getSvgIconUtilityClass(slot) {\n return generateUtilityClass('MuiSvgIcon', slot);\n}\nconst svgIconClasses = generateUtilityClasses('MuiSvgIcon', ['root', 'colorPrimary', 'colorSecondary', 'colorAction', 'colorError', 'colorDisabled', 'fontSizeInherit', 'fontSizeSmall', 'fontSizeMedium', 'fontSizeLarge']);\nexport default svgIconClasses;","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"children\", \"className\", \"color\", \"component\", \"fontSize\", \"htmlColor\", \"inheritViewBox\", \"titleAccess\", \"viewBox\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport clsx from 'clsx';\nimport { unstable_composeClasses as composeClasses } from '@mui/base/composeClasses';\nimport capitalize from '../utils/capitalize';\nimport useThemeProps from '../styles/useThemeProps';\nimport styled from '../styles/styled';\nimport { getSvgIconUtilityClass } from './svgIconClasses';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nimport { jsxs as _jsxs } from \"react/jsx-runtime\";\nconst useUtilityClasses = ownerState => {\n const {\n color,\n fontSize,\n classes\n } = ownerState;\n const slots = {\n root: ['root', color !== 'inherit' && `color${capitalize(color)}`, `fontSize${capitalize(fontSize)}`]\n };\n return composeClasses(slots, getSvgIconUtilityClass, classes);\n};\nconst SvgIconRoot = styled('svg', {\n name: 'MuiSvgIcon',\n slot: 'Root',\n overridesResolver: (props, styles) => {\n const {\n ownerState\n } = props;\n return [styles.root, ownerState.color !== 'inherit' && styles[`color${capitalize(ownerState.color)}`], styles[`fontSize${capitalize(ownerState.fontSize)}`]];\n }\n})(({\n theme,\n ownerState\n}) => {\n var _theme$transitions, _theme$transitions$cr, _theme$transitions2, _theme$typography, _theme$typography$pxT, _theme$typography2, _theme$typography2$px, _theme$typography3, _theme$typography3$px, _palette$ownerState$c, _palette, _palette2, _palette3;\n return {\n userSelect: 'none',\n width: '1em',\n height: '1em',\n display: 'inline-block',\n // the will define the property that has `currentColor`\n // e.g. heroicons uses fill=\"none\" and stroke=\"currentColor\"\n fill: ownerState.hasSvgAsChild ? undefined : 'currentColor',\n flexShrink: 0,\n transition: (_theme$transitions = theme.transitions) == null || (_theme$transitions$cr = _theme$transitions.create) == null ? void 0 : _theme$transitions$cr.call(_theme$transitions, 'fill', {\n duration: (_theme$transitions2 = theme.transitions) == null || (_theme$transitions2 = _theme$transitions2.duration) == null ? void 0 : _theme$transitions2.shorter\n }),\n fontSize: {\n inherit: 'inherit',\n small: ((_theme$typography = theme.typography) == null || (_theme$typography$pxT = _theme$typography.pxToRem) == null ? void 0 : _theme$typography$pxT.call(_theme$typography, 20)) || '1.25rem',\n medium: ((_theme$typography2 = theme.typography) == null || (_theme$typography2$px = _theme$typography2.pxToRem) == null ? void 0 : _theme$typography2$px.call(_theme$typography2, 24)) || '1.5rem',\n large: ((_theme$typography3 = theme.typography) == null || (_theme$typography3$px = _theme$typography3.pxToRem) == null ? void 0 : _theme$typography3$px.call(_theme$typography3, 35)) || '2.1875rem'\n }[ownerState.fontSize],\n // TODO v5 deprecate, v6 remove for sx\n color: (_palette$ownerState$c = (_palette = (theme.vars || theme).palette) == null || (_palette = _palette[ownerState.color]) == null ? void 0 : _palette.main) != null ? _palette$ownerState$c : {\n action: (_palette2 = (theme.vars || theme).palette) == null || (_palette2 = _palette2.action) == null ? void 0 : _palette2.active,\n disabled: (_palette3 = (theme.vars || theme).palette) == null || (_palette3 = _palette3.action) == null ? void 0 : _palette3.disabled,\n inherit: undefined\n }[ownerState.color]\n };\n});\nconst SvgIcon = /*#__PURE__*/React.forwardRef(function SvgIcon(inProps, ref) {\n const props = useThemeProps({\n props: inProps,\n name: 'MuiSvgIcon'\n });\n const {\n children,\n className,\n color = 'inherit',\n component = 'svg',\n fontSize = 'medium',\n htmlColor,\n inheritViewBox = false,\n titleAccess,\n viewBox = '0 0 24 24'\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const hasSvgAsChild = /*#__PURE__*/React.isValidElement(children) && children.type === 'svg';\n const ownerState = _extends({}, props, {\n color,\n component,\n fontSize,\n instanceFontSize: inProps.fontSize,\n inheritViewBox,\n viewBox,\n hasSvgAsChild\n });\n const more = {};\n if (!inheritViewBox) {\n more.viewBox = viewBox;\n }\n const classes = useUtilityClasses(ownerState);\n return /*#__PURE__*/_jsxs(SvgIconRoot, _extends({\n as: component,\n className: clsx(classes.root, className),\n focusable: \"false\",\n color: htmlColor,\n \"aria-hidden\": titleAccess ? undefined : true,\n role: titleAccess ? 'img' : undefined,\n ref: ref\n }, more, other, hasSvgAsChild && children.props, {\n ownerState: ownerState,\n children: [hasSvgAsChild ? children.props.children : children, titleAccess ? /*#__PURE__*/_jsx(\"title\", {\n children: titleAccess\n }) : null]\n }));\n});\nprocess.env.NODE_ENV !== \"production\" ? SvgIcon.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the d.ts file and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * Node passed into the SVG element.\n */\n children: PropTypes.node,\n /**\n * Override or extend the styles applied to the component.\n */\n classes: PropTypes.object,\n /**\n * @ignore\n */\n className: PropTypes.string,\n /**\n * The color of the component.\n * It supports both default and custom theme colors, which can be added as shown in the\n * [palette customization guide](https://mui.com/material-ui/customization/palette/#custom-colors).\n * You can use the `htmlColor` prop to apply a color attribute to the SVG element.\n * @default 'inherit'\n */\n color: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.oneOf(['inherit', 'action', 'disabled', 'primary', 'secondary', 'error', 'info', 'success', 'warning']), PropTypes.string]),\n /**\n * The component used for the root node.\n * Either a string to use a HTML element or a component.\n */\n component: PropTypes.elementType,\n /**\n * The fontSize applied to the icon. Defaults to 24px, but can be configure to inherit font size.\n * @default 'medium'\n */\n fontSize: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.oneOf(['inherit', 'large', 'medium', 'small']), PropTypes.string]),\n /**\n * Applies a color attribute to the SVG element.\n */\n htmlColor: PropTypes.string,\n /**\n * If `true`, the root node will inherit the custom `component`'s viewBox and the `viewBox`\n * prop will be ignored.\n * Useful when you want to reference a custom `component` and have `SvgIcon` pass that\n * `component`'s viewBox to the root node.\n * @default false\n */\n inheritViewBox: PropTypes.bool,\n /**\n * The shape-rendering attribute. The behavior of the different options is described on the\n * [MDN Web Docs](https://developer.mozilla.org/en-US/docs/Web/SVG/Attribute/shape-rendering).\n * If you are having issues with blurry icons you should investigate this prop.\n */\n shapeRendering: PropTypes.string,\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Provides a human-readable title for the element that contains it.\n * https://www.w3.org/TR/SVG-access/#Equivalent\n */\n titleAccess: PropTypes.string,\n /**\n * Allows you to redefine what the coordinates without units mean inside an SVG element.\n * For example, if the SVG element is 500 (width) by 200 (height),\n * and you pass viewBox=\"0 0 50 20\",\n * this means that the coordinates inside the SVG will go from the top left corner (0,0)\n * to bottom right (50,20) and each unit will be worth 10px.\n * @default '0 0 24 24'\n */\n viewBox: PropTypes.string\n} : void 0;\nSvgIcon.muiName = 'SvgIcon';\nexport default SvgIcon;","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport * as React from 'react';\nimport SvgIcon from '../SvgIcon';\n\n/**\n * Private module reserved for @mui packages.\n */\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nexport default function createSvgIcon(path, displayName) {\n function Component(props, ref) {\n return /*#__PURE__*/_jsx(SvgIcon, _extends({\n \"data-testid\": `${displayName}Icon`,\n ref: ref\n }, props, {\n children: path\n }));\n }\n if (process.env.NODE_ENV !== 'production') {\n // Need to set `displayName` on the inner component for React.memo.\n // React prior to 16.14 ignores `displayName` on the wrapper.\n Component.displayName = `${displayName}Icon`;\n }\n Component.muiName = SvgIcon.muiName;\n return /*#__PURE__*/React.memo( /*#__PURE__*/React.forwardRef(Component));\n}","'use client';\n\nimport { unstable_ClassNameGenerator as ClassNameGenerator } from '@mui/base/ClassNameGenerator';\nexport { default as capitalize } from './capitalize';\nexport { default as createChainedFunction } from './createChainedFunction';\nexport { default as createSvgIcon } from './createSvgIcon';\nexport { default as debounce } from './debounce';\nexport { default as deprecatedPropType } from './deprecatedPropType';\nexport { default as isMuiElement } from './isMuiElement';\nexport { default as ownerDocument } from './ownerDocument';\nexport { default as ownerWindow } from './ownerWindow';\nexport { default as requirePropFactory } from './requirePropFactory';\nexport { default as setRef } from './setRef';\nexport { default as unstable_useEnhancedEffect } from './useEnhancedEffect';\nexport { default as unstable_useId } from './useId';\nexport { default as unsupportedProp } from './unsupportedProp';\nexport { default as useControlled } from './useControlled';\nexport { default as useEventCallback } from './useEventCallback';\nexport { default as useForkRef } from './useForkRef';\nexport { default as useIsFocusVisible } from './useIsFocusVisible';\n// TODO: remove this export once ClassNameGenerator is stable\n// eslint-disable-next-line @typescript-eslint/naming-convention\nexport const unstable_ClassNameGenerator = {\n configure: generator => {\n if (process.env.NODE_ENV !== 'production') {\n console.warn(['MUI: `ClassNameGenerator` import from `@mui/material/utils` is outdated and might cause unexpected issues.', '', \"You should use `import { unstable_ClassNameGenerator } from '@mui/material/className'` instead\", '', 'The detail of the issue: https://github.com/mui/material-ui/issues/30011#issuecomment-1024993401', '', 'The updated documentation: https://mui.com/guides/classname-generator/'].join('\\n'));\n }\n ClassNameGenerator.configure(generator);\n }\n};","\"use strict\";\n'use client';\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nObject.defineProperty(exports, \"default\", {\n enumerable: true,\n get: function () {\n return _utils.createSvgIcon;\n }\n});\nvar _utils = require(\"@mui/material/utils\");","\"use strict\";\n\"use client\";\n\nvar _interopRequireDefault = require(\"@babel/runtime/helpers/interopRequireDefault\");\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = void 0;\nvar _createSvgIcon = _interopRequireDefault(require(\"./utils/createSvgIcon\"));\nvar _jsxRuntime = require(\"react/jsx-runtime\");\nvar _default = exports.default = (0, _createSvgIcon.default)( /*#__PURE__*/(0, _jsxRuntime.jsx)(\"path\", {\n d: \"m10 17 5-5-5-5z\"\n}), 'ArrowRight');","/**\n * Determines if a given element is a DOM element name (i.e. not a React component).\n */\nexport function isHostComponent(element) {\n return typeof element === 'string';\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport { isHostComponent } from './isHostComponent';\n\n/**\n * Type of the ownerState based on the type of an element it applies to.\n * This resolves to the provided OwnerState for React components and `undefined` for host components.\n * Falls back to `OwnerState | undefined` when the exact type can't be determined in development time.\n */\n\n/**\n * Appends the ownerState object to the props, merging with the existing one if necessary.\n *\n * @param elementType Type of the element that owns the `existingProps`. If the element is a DOM node or undefined, `ownerState` is not applied.\n * @param otherProps Props of the element.\n * @param ownerState\n */\nexport function appendOwnerState(elementType, otherProps, ownerState) {\n if (elementType === undefined || isHostComponent(elementType)) {\n return otherProps;\n }\n return _extends({}, otherProps, {\n ownerState: _extends({}, otherProps.ownerState, ownerState)\n });\n}","'use client';\n\nimport * as React from 'react';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nconst defaultContextValue = {\n disableDefaultClasses: false\n};\nconst ClassNameConfiguratorContext = /*#__PURE__*/React.createContext(defaultContextValue);\n/**\n * @ignore - internal hook.\n *\n * Wraps the `generateUtilityClass` function and controls how the classes are generated.\n * Currently it only affects whether the classes are applied or not.\n *\n * @returns Function to be called with the `generateUtilityClass` function specific to a component to generate the classes.\n */\nexport function useClassNamesOverride(generateUtilityClass) {\n const {\n disableDefaultClasses\n } = React.useContext(ClassNameConfiguratorContext);\n return slot => {\n if (disableDefaultClasses) {\n return '';\n }\n return generateUtilityClass(slot);\n };\n}\n\n/**\n * Allows to configure the components within to not apply any built-in classes.\n */\nexport function ClassNameConfigurator(props) {\n const {\n disableDefaultClasses,\n children\n } = props;\n const contextValue = React.useMemo(() => ({\n disableDefaultClasses: disableDefaultClasses != null ? disableDefaultClasses : false\n }), [disableDefaultClasses]);\n return /*#__PURE__*/_jsx(ClassNameConfiguratorContext.Provider, {\n value: contextValue,\n children: children\n });\n}","/**\n * Extracts event handlers from a given object.\n * A prop is considered an event handler if it is a function and its name starts with `on`.\n *\n * @param object An object to extract event handlers from.\n * @param excludeKeys An array of keys to exclude from the returned object.\n */\nexport function extractEventHandlers(object, excludeKeys = []) {\n if (object === undefined) {\n return {};\n }\n const result = {};\n Object.keys(object).filter(prop => prop.match(/^on[A-Z]/) && typeof object[prop] === 'function' && !excludeKeys.includes(prop)).forEach(prop => {\n result[prop] = object[prop];\n });\n return result;\n}","/**\n * If `componentProps` is a function, calls it with the provided `ownerState`.\n * Otherwise, just returns `componentProps`.\n */\nexport function resolveComponentProps(componentProps, ownerState, slotState) {\n if (typeof componentProps === 'function') {\n return componentProps(ownerState, slotState);\n }\n return componentProps;\n}","/**\n * Removes event handlers from the given object.\n * A field is considered an event handler if it is a function with a name beginning with `on`.\n *\n * @param object Object to remove event handlers from.\n * @returns Object with event handlers removed.\n */\nexport function omitEventHandlers(object) {\n if (object === undefined) {\n return {};\n }\n const result = {};\n Object.keys(object).filter(prop => !(prop.match(/^on[A-Z]/) && typeof object[prop] === 'function')).forEach(prop => {\n result[prop] = object[prop];\n });\n return result;\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport clsx from 'clsx';\nimport { extractEventHandlers } from './extractEventHandlers';\nimport { omitEventHandlers } from './omitEventHandlers';\n/**\n * Merges the slot component internal props (usually coming from a hook)\n * with the externally provided ones.\n *\n * The merge order is (the latter overrides the former):\n * 1. The internal props (specified as a getter function to work with get*Props hook result)\n * 2. Additional props (specified internally on a Base UI component)\n * 3. External props specified on the owner component. These should only be used on a root slot.\n * 4. External props specified in the `slotProps.*` prop.\n * 5. The `className` prop - combined from all the above.\n * @param parameters\n * @returns\n */\nexport function mergeSlotProps(parameters) {\n const {\n getSlotProps,\n additionalProps,\n externalSlotProps,\n externalForwardedProps,\n className\n } = parameters;\n if (!getSlotProps) {\n // The simpler case - getSlotProps is not defined, so no internal event handlers are defined,\n // so we can simply merge all the props without having to worry about extracting event handlers.\n const joinedClasses = clsx(additionalProps == null ? void 0 : additionalProps.className, className, externalForwardedProps == null ? void 0 : externalForwardedProps.className, externalSlotProps == null ? void 0 : externalSlotProps.className);\n const mergedStyle = _extends({}, additionalProps == null ? void 0 : additionalProps.style, externalForwardedProps == null ? void 0 : externalForwardedProps.style, externalSlotProps == null ? void 0 : externalSlotProps.style);\n const props = _extends({}, additionalProps, externalForwardedProps, externalSlotProps);\n if (joinedClasses.length > 0) {\n props.className = joinedClasses;\n }\n if (Object.keys(mergedStyle).length > 0) {\n props.style = mergedStyle;\n }\n return {\n props,\n internalRef: undefined\n };\n }\n\n // In this case, getSlotProps is responsible for calling the external event handlers.\n // We don't need to include them in the merged props because of this.\n\n const eventHandlers = extractEventHandlers(_extends({}, externalForwardedProps, externalSlotProps));\n const componentsPropsWithoutEventHandlers = omitEventHandlers(externalSlotProps);\n const otherPropsWithoutEventHandlers = omitEventHandlers(externalForwardedProps);\n const internalSlotProps = getSlotProps(eventHandlers);\n\n // The order of classes is important here.\n // Emotion (that we use in libraries consuming Base UI) depends on this order\n // to properly override style. It requires the most important classes to be last\n // (see https://github.com/mui/material-ui/pull/33205) for the related discussion.\n const joinedClasses = clsx(internalSlotProps == null ? void 0 : internalSlotProps.className, additionalProps == null ? void 0 : additionalProps.className, className, externalForwardedProps == null ? void 0 : externalForwardedProps.className, externalSlotProps == null ? void 0 : externalSlotProps.className);\n const mergedStyle = _extends({}, internalSlotProps == null ? void 0 : internalSlotProps.style, additionalProps == null ? void 0 : additionalProps.style, externalForwardedProps == null ? void 0 : externalForwardedProps.style, externalSlotProps == null ? void 0 : externalSlotProps.style);\n const props = _extends({}, internalSlotProps, additionalProps, otherPropsWithoutEventHandlers, componentsPropsWithoutEventHandlers);\n if (joinedClasses.length > 0) {\n props.className = joinedClasses;\n }\n if (Object.keys(mergedStyle).length > 0) {\n props.style = mergedStyle;\n }\n return {\n props,\n internalRef: internalSlotProps.ref\n };\n}","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"elementType\", \"externalSlotProps\", \"ownerState\", \"skipResolvingSlotProps\"];\nimport { unstable_useForkRef as useForkRef } from '@mui/utils';\nimport { appendOwnerState } from './appendOwnerState';\nimport { mergeSlotProps } from './mergeSlotProps';\nimport { resolveComponentProps } from './resolveComponentProps';\n/**\n * @ignore - do not document.\n * Builds the props to be passed into the slot of an unstyled component.\n * It merges the internal props of the component with the ones supplied by the user, allowing to customize the behavior.\n * If the slot component is not a host component, it also merges in the `ownerState`.\n *\n * @param parameters.getSlotProps - A function that returns the props to be passed to the slot component.\n */\nexport function useSlotProps(parameters) {\n var _parameters$additiona;\n const {\n elementType,\n externalSlotProps,\n ownerState,\n skipResolvingSlotProps = false\n } = parameters,\n rest = _objectWithoutPropertiesLoose(parameters, _excluded);\n const resolvedComponentsProps = skipResolvingSlotProps ? {} : resolveComponentProps(externalSlotProps, ownerState);\n const {\n props: mergedProps,\n internalRef\n } = mergeSlotProps(_extends({}, rest, {\n externalSlotProps: resolvedComponentsProps\n }));\n const ref = useForkRef(internalRef, resolvedComponentsProps == null ? void 0 : resolvedComponentsProps.ref, (_parameters$additiona = parameters.additionalProps) == null ? void 0 : _parameters$additiona.ref);\n const props = appendOwnerState(elementType, _extends({}, mergedProps, {\n ref\n }), ownerState);\n return props;\n}","import { globalStateClasses } from '@mui/utils/generateUtilityClass';\nconst GLOBAL_CLASS_PREFIX = 'base';\nfunction buildStateClass(state) {\n return `${GLOBAL_CLASS_PREFIX}--${state}`;\n}\nfunction buildSlotClass(componentName, slot) {\n return `${GLOBAL_CLASS_PREFIX}-${componentName}-${slot}`;\n}\nexport function generateUtilityClass(componentName, slot) {\n const globalStateClass = globalStateClasses[slot];\n return globalStateClass ? buildStateClass(globalStateClass) : buildSlotClass(componentName, slot);\n}\nexport function isGlobalState(slot) {\n return globalStateClasses[slot] !== undefined;\n}","import { generateUtilityClass } from '../generateUtilityClass';\nexport function generateUtilityClasses(componentName, slots) {\n const result = {};\n slots.forEach(slot => {\n result[slot] = generateUtilityClass(componentName, slot);\n });\n return result;\n}","'use client';\n\nimport * as React from 'react';\nimport * as ReactDOM from 'react-dom';\nimport PropTypes from 'prop-types';\nimport { exactProp, HTMLElementType, unstable_useEnhancedEffect as useEnhancedEffect, unstable_useForkRef as useForkRef, unstable_setRef as setRef } from '@mui/utils';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nfunction getContainer(container) {\n return typeof container === 'function' ? container() : container;\n}\n\n/**\n * Portals provide a first-class way to render children into a DOM node\n * that exists outside the DOM hierarchy of the parent component.\n *\n * Demos:\n *\n * - [Portal](https://mui.com/base-ui/react-portal/)\n *\n * API:\n *\n * - [Portal API](https://mui.com/base-ui/react-portal/components-api/#portal)\n */\nconst Portal = /*#__PURE__*/React.forwardRef(function Portal(props, forwardedRef) {\n const {\n children,\n container,\n disablePortal = false\n } = props;\n const [mountNode, setMountNode] = React.useState(null);\n // @ts-expect-error TODO upstream fix\n const handleRef = useForkRef( /*#__PURE__*/React.isValidElement(children) ? children.ref : null, forwardedRef);\n useEnhancedEffect(() => {\n if (!disablePortal) {\n setMountNode(getContainer(container) || document.body);\n }\n }, [container, disablePortal]);\n useEnhancedEffect(() => {\n if (mountNode && !disablePortal) {\n setRef(forwardedRef, mountNode);\n return () => {\n setRef(forwardedRef, null);\n };\n }\n return undefined;\n }, [forwardedRef, mountNode, disablePortal]);\n if (disablePortal) {\n if ( /*#__PURE__*/React.isValidElement(children)) {\n const newProps = {\n ref: handleRef\n };\n return /*#__PURE__*/React.cloneElement(children, newProps);\n }\n return /*#__PURE__*/_jsx(React.Fragment, {\n children: children\n });\n }\n return /*#__PURE__*/_jsx(React.Fragment, {\n children: mountNode ? /*#__PURE__*/ReactDOM.createPortal(children, mountNode) : mountNode\n });\n});\nprocess.env.NODE_ENV !== \"production\" ? Portal.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * The children to render into the `container`.\n */\n children: PropTypes.node,\n /**\n * An HTML element or function that returns one.\n * The `container` will have the portal children appended to it.\n *\n * You can also provide a callback, which is called in a React layout effect.\n * This lets you set the container from a ref, and also makes server-side rendering possible.\n *\n * By default, it uses the body of the top-level document object,\n * so it's simply `document.body` most of the time.\n */\n container: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.func]),\n /**\n * The `children` will be under the DOM hierarchy of the parent component.\n * @default false\n */\n disablePortal: PropTypes.bool\n} : void 0;\nif (process.env.NODE_ENV !== 'production') {\n // eslint-disable-next-line\n Portal['propTypes' + ''] = exactProp(Portal.propTypes);\n}\nexport { Portal };","export var top = 'top';\nexport var bottom = 'bottom';\nexport var right = 'right';\nexport var left = 'left';\nexport var auto = 'auto';\nexport var basePlacements = [top, bottom, right, left];\nexport var start = 'start';\nexport var end = 'end';\nexport var clippingParents = 'clippingParents';\nexport var viewport = 'viewport';\nexport var popper = 'popper';\nexport var reference = 'reference';\nexport var variationPlacements = /*#__PURE__*/basePlacements.reduce(function (acc, placement) {\n return acc.concat([placement + \"-\" + start, placement + \"-\" + end]);\n}, []);\nexport var placements = /*#__PURE__*/[].concat(basePlacements, [auto]).reduce(function (acc, placement) {\n return acc.concat([placement, placement + \"-\" + start, placement + \"-\" + end]);\n}, []); // modifiers that need to read the DOM\n\nexport var beforeRead = 'beforeRead';\nexport var read = 'read';\nexport var afterRead = 'afterRead'; // pure-logic modifiers\n\nexport var beforeMain = 'beforeMain';\nexport var main = 'main';\nexport var afterMain = 'afterMain'; // modifier with the purpose to write to the DOM (or write into a framework state)\n\nexport var beforeWrite = 'beforeWrite';\nexport var write = 'write';\nexport var afterWrite = 'afterWrite';\nexport var modifierPhases = [beforeRead, read, afterRead, beforeMain, main, afterMain, beforeWrite, write, afterWrite];","export default function getNodeName(element) {\n return element ? (element.nodeName || '').toLowerCase() : null;\n}","export default function getWindow(node) {\n if (node == null) {\n return window;\n }\n\n if (node.toString() !== '[object Window]') {\n var ownerDocument = node.ownerDocument;\n return ownerDocument ? ownerDocument.defaultView || window : window;\n }\n\n return node;\n}","import getWindow from \"./getWindow.js\";\n\nfunction isElement(node) {\n var OwnElement = getWindow(node).Element;\n return node instanceof OwnElement || node instanceof Element;\n}\n\nfunction isHTMLElement(node) {\n var OwnElement = getWindow(node).HTMLElement;\n return node instanceof OwnElement || node instanceof HTMLElement;\n}\n\nfunction isShadowRoot(node) {\n // IE 11 has no ShadowRoot\n if (typeof ShadowRoot === 'undefined') {\n return false;\n }\n\n var OwnElement = getWindow(node).ShadowRoot;\n return node instanceof OwnElement || node instanceof ShadowRoot;\n}\n\nexport { isElement, isHTMLElement, isShadowRoot };","import getNodeName from \"../dom-utils/getNodeName.js\";\nimport { isHTMLElement } from \"../dom-utils/instanceOf.js\"; // This modifier takes the styles prepared by the `computeStyles` modifier\n// and applies them to the HTMLElements such as popper and arrow\n\nfunction applyStyles(_ref) {\n var state = _ref.state;\n Object.keys(state.elements).forEach(function (name) {\n var style = state.styles[name] || {};\n var attributes = state.attributes[name] || {};\n var element = state.elements[name]; // arrow is optional + virtual elements\n\n if (!isHTMLElement(element) || !getNodeName(element)) {\n return;\n } // Flow doesn't support to extend this property, but it's the most\n // effective way to apply styles to an HTMLElement\n // $FlowFixMe[cannot-write]\n\n\n Object.assign(element.style, style);\n Object.keys(attributes).forEach(function (name) {\n var value = attributes[name];\n\n if (value === false) {\n element.removeAttribute(name);\n } else {\n element.setAttribute(name, value === true ? '' : value);\n }\n });\n });\n}\n\nfunction effect(_ref2) {\n var state = _ref2.state;\n var initialStyles = {\n popper: {\n position: state.options.strategy,\n left: '0',\n top: '0',\n margin: '0'\n },\n arrow: {\n position: 'absolute'\n },\n reference: {}\n };\n Object.assign(state.elements.popper.style, initialStyles.popper);\n state.styles = initialStyles;\n\n if (state.elements.arrow) {\n Object.assign(state.elements.arrow.style, initialStyles.arrow);\n }\n\n return function () {\n Object.keys(state.elements).forEach(function (name) {\n var element = state.elements[name];\n var attributes = state.attributes[name] || {};\n var styleProperties = Object.keys(state.styles.hasOwnProperty(name) ? state.styles[name] : initialStyles[name]); // Set all values to an empty string to unset them\n\n var style = styleProperties.reduce(function (style, property) {\n style[property] = '';\n return style;\n }, {}); // arrow is optional + virtual elements\n\n if (!isHTMLElement(element) || !getNodeName(element)) {\n return;\n }\n\n Object.assign(element.style, style);\n Object.keys(attributes).forEach(function (attribute) {\n element.removeAttribute(attribute);\n });\n });\n };\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'applyStyles',\n enabled: true,\n phase: 'write',\n fn: applyStyles,\n effect: effect,\n requires: ['computeStyles']\n};","import { auto } from \"../enums.js\";\nexport default function getBasePlacement(placement) {\n return placement.split('-')[0];\n}","export var max = Math.max;\nexport var min = Math.min;\nexport var round = Math.round;","export default function getUAString() {\n var uaData = navigator.userAgentData;\n\n if (uaData != null && uaData.brands && Array.isArray(uaData.brands)) {\n return uaData.brands.map(function (item) {\n return item.brand + \"/\" + item.version;\n }).join(' ');\n }\n\n return navigator.userAgent;\n}","import getUAString from \"../utils/userAgent.js\";\nexport default function isLayoutViewport() {\n return !/^((?!chrome|android).)*safari/i.test(getUAString());\n}","import { isElement, isHTMLElement } from \"./instanceOf.js\";\nimport { round } from \"../utils/math.js\";\nimport getWindow from \"./getWindow.js\";\nimport isLayoutViewport from \"./isLayoutViewport.js\";\nexport default function getBoundingClientRect(element, includeScale, isFixedStrategy) {\n if (includeScale === void 0) {\n includeScale = false;\n }\n\n if (isFixedStrategy === void 0) {\n isFixedStrategy = false;\n }\n\n var clientRect = element.getBoundingClientRect();\n var scaleX = 1;\n var scaleY = 1;\n\n if (includeScale && isHTMLElement(element)) {\n scaleX = element.offsetWidth > 0 ? round(clientRect.width) / element.offsetWidth || 1 : 1;\n scaleY = element.offsetHeight > 0 ? round(clientRect.height) / element.offsetHeight || 1 : 1;\n }\n\n var _ref = isElement(element) ? getWindow(element) : window,\n visualViewport = _ref.visualViewport;\n\n var addVisualOffsets = !isLayoutViewport() && isFixedStrategy;\n var x = (clientRect.left + (addVisualOffsets && visualViewport ? visualViewport.offsetLeft : 0)) / scaleX;\n var y = (clientRect.top + (addVisualOffsets && visualViewport ? visualViewport.offsetTop : 0)) / scaleY;\n var width = clientRect.width / scaleX;\n var height = clientRect.height / scaleY;\n return {\n width: width,\n height: height,\n top: y,\n right: x + width,\n bottom: y + height,\n left: x,\n x: x,\n y: y\n };\n}","import getBoundingClientRect from \"./getBoundingClientRect.js\"; // Returns the layout rect of an element relative to its offsetParent. Layout\n// means it doesn't take into account transforms.\n\nexport default function getLayoutRect(element) {\n var clientRect = getBoundingClientRect(element); // Use the clientRect sizes if it's not been transformed.\n // Fixes https://github.com/popperjs/popper-core/issues/1223\n\n var width = element.offsetWidth;\n var height = element.offsetHeight;\n\n if (Math.abs(clientRect.width - width) <= 1) {\n width = clientRect.width;\n }\n\n if (Math.abs(clientRect.height - height) <= 1) {\n height = clientRect.height;\n }\n\n return {\n x: element.offsetLeft,\n y: element.offsetTop,\n width: width,\n height: height\n };\n}","import { isShadowRoot } from \"./instanceOf.js\";\nexport default function contains(parent, child) {\n var rootNode = child.getRootNode && child.getRootNode(); // First, attempt with faster native method\n\n if (parent.contains(child)) {\n return true;\n } // then fallback to custom implementation with Shadow DOM support\n else if (rootNode && isShadowRoot(rootNode)) {\n var next = child;\n\n do {\n if (next && parent.isSameNode(next)) {\n return true;\n } // $FlowFixMe[prop-missing]: need a better way to handle this...\n\n\n next = next.parentNode || next.host;\n } while (next);\n } // Give up, the result is false\n\n\n return false;\n}","import getWindow from \"./getWindow.js\";\nexport default function getComputedStyle(element) {\n return getWindow(element).getComputedStyle(element);\n}","import getNodeName from \"./getNodeName.js\";\nexport default function isTableElement(element) {\n return ['table', 'td', 'th'].indexOf(getNodeName(element)) >= 0;\n}","import { isElement } from \"./instanceOf.js\";\nexport default function getDocumentElement(element) {\n // $FlowFixMe[incompatible-return]: assume body is always available\n return ((isElement(element) ? element.ownerDocument : // $FlowFixMe[prop-missing]\n element.document) || window.document).documentElement;\n}","import getNodeName from \"./getNodeName.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport { isShadowRoot } from \"./instanceOf.js\";\nexport default function getParentNode(element) {\n if (getNodeName(element) === 'html') {\n return element;\n }\n\n return (// this is a quicker (but less type safe) way to save quite some bytes from the bundle\n // $FlowFixMe[incompatible-return]\n // $FlowFixMe[prop-missing]\n element.assignedSlot || // step into the shadow DOM of the parent of a slotted node\n element.parentNode || ( // DOM Element detected\n isShadowRoot(element) ? element.host : null) || // ShadowRoot detected\n // $FlowFixMe[incompatible-call]: HTMLElement is a Node\n getDocumentElement(element) // fallback\n\n );\n}","import getWindow from \"./getWindow.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport getComputedStyle from \"./getComputedStyle.js\";\nimport { isHTMLElement, isShadowRoot } from \"./instanceOf.js\";\nimport isTableElement from \"./isTableElement.js\";\nimport getParentNode from \"./getParentNode.js\";\nimport getUAString from \"../utils/userAgent.js\";\n\nfunction getTrueOffsetParent(element) {\n if (!isHTMLElement(element) || // https://github.com/popperjs/popper-core/issues/837\n getComputedStyle(element).position === 'fixed') {\n return null;\n }\n\n return element.offsetParent;\n} // `.offsetParent` reports `null` for fixed elements, while absolute elements\n// return the containing block\n\n\nfunction getContainingBlock(element) {\n var isFirefox = /firefox/i.test(getUAString());\n var isIE = /Trident/i.test(getUAString());\n\n if (isIE && isHTMLElement(element)) {\n // In IE 9, 10 and 11 fixed elements containing block is always established by the viewport\n var elementCss = getComputedStyle(element);\n\n if (elementCss.position === 'fixed') {\n return null;\n }\n }\n\n var currentNode = getParentNode(element);\n\n if (isShadowRoot(currentNode)) {\n currentNode = currentNode.host;\n }\n\n while (isHTMLElement(currentNode) && ['html', 'body'].indexOf(getNodeName(currentNode)) < 0) {\n var css = getComputedStyle(currentNode); // This is non-exhaustive but covers the most common CSS properties that\n // create a containing block.\n // https://developer.mozilla.org/en-US/docs/Web/CSS/Containing_block#identifying_the_containing_block\n\n if (css.transform !== 'none' || css.perspective !== 'none' || css.contain === 'paint' || ['transform', 'perspective'].indexOf(css.willChange) !== -1 || isFirefox && css.willChange === 'filter' || isFirefox && css.filter && css.filter !== 'none') {\n return currentNode;\n } else {\n currentNode = currentNode.parentNode;\n }\n }\n\n return null;\n} // Gets the closest ancestor positioned element. Handles some edge cases,\n// such as table ancestors and cross browser bugs.\n\n\nexport default function getOffsetParent(element) {\n var window = getWindow(element);\n var offsetParent = getTrueOffsetParent(element);\n\n while (offsetParent && isTableElement(offsetParent) && getComputedStyle(offsetParent).position === 'static') {\n offsetParent = getTrueOffsetParent(offsetParent);\n }\n\n if (offsetParent && (getNodeName(offsetParent) === 'html' || getNodeName(offsetParent) === 'body' && getComputedStyle(offsetParent).position === 'static')) {\n return window;\n }\n\n return offsetParent || getContainingBlock(element) || window;\n}","export default function getMainAxisFromPlacement(placement) {\n return ['top', 'bottom'].indexOf(placement) >= 0 ? 'x' : 'y';\n}","import { max as mathMax, min as mathMin } from \"./math.js\";\nexport function within(min, value, max) {\n return mathMax(min, mathMin(value, max));\n}\nexport function withinMaxClamp(min, value, max) {\n var v = within(min, value, max);\n return v > max ? max : v;\n}","export default function getFreshSideObject() {\n return {\n top: 0,\n right: 0,\n bottom: 0,\n left: 0\n };\n}","import getFreshSideObject from \"./getFreshSideObject.js\";\nexport default function mergePaddingObject(paddingObject) {\n return Object.assign({}, getFreshSideObject(), paddingObject);\n}","export default function expandToHashMap(value, keys) {\n return keys.reduce(function (hashMap, key) {\n hashMap[key] = value;\n return hashMap;\n }, {});\n}","import getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getLayoutRect from \"../dom-utils/getLayoutRect.js\";\nimport contains from \"../dom-utils/contains.js\";\nimport getOffsetParent from \"../dom-utils/getOffsetParent.js\";\nimport getMainAxisFromPlacement from \"../utils/getMainAxisFromPlacement.js\";\nimport { within } from \"../utils/within.js\";\nimport mergePaddingObject from \"../utils/mergePaddingObject.js\";\nimport expandToHashMap from \"../utils/expandToHashMap.js\";\nimport { left, right, basePlacements, top, bottom } from \"../enums.js\"; // eslint-disable-next-line import/no-unused-modules\n\nvar toPaddingObject = function toPaddingObject(padding, state) {\n padding = typeof padding === 'function' ? padding(Object.assign({}, state.rects, {\n placement: state.placement\n })) : padding;\n return mergePaddingObject(typeof padding !== 'number' ? padding : expandToHashMap(padding, basePlacements));\n};\n\nfunction arrow(_ref) {\n var _state$modifiersData$;\n\n var state = _ref.state,\n name = _ref.name,\n options = _ref.options;\n var arrowElement = state.elements.arrow;\n var popperOffsets = state.modifiersData.popperOffsets;\n var basePlacement = getBasePlacement(state.placement);\n var axis = getMainAxisFromPlacement(basePlacement);\n var isVertical = [left, right].indexOf(basePlacement) >= 0;\n var len = isVertical ? 'height' : 'width';\n\n if (!arrowElement || !popperOffsets) {\n return;\n }\n\n var paddingObject = toPaddingObject(options.padding, state);\n var arrowRect = getLayoutRect(arrowElement);\n var minProp = axis === 'y' ? top : left;\n var maxProp = axis === 'y' ? bottom : right;\n var endDiff = state.rects.reference[len] + state.rects.reference[axis] - popperOffsets[axis] - state.rects.popper[len];\n var startDiff = popperOffsets[axis] - state.rects.reference[axis];\n var arrowOffsetParent = getOffsetParent(arrowElement);\n var clientSize = arrowOffsetParent ? axis === 'y' ? arrowOffsetParent.clientHeight || 0 : arrowOffsetParent.clientWidth || 0 : 0;\n var centerToReference = endDiff / 2 - startDiff / 2; // Make sure the arrow doesn't overflow the popper if the center point is\n // outside of the popper bounds\n\n var min = paddingObject[minProp];\n var max = clientSize - arrowRect[len] - paddingObject[maxProp];\n var center = clientSize / 2 - arrowRect[len] / 2 + centerToReference;\n var offset = within(min, center, max); // Prevents breaking syntax highlighting...\n\n var axisProp = axis;\n state.modifiersData[name] = (_state$modifiersData$ = {}, _state$modifiersData$[axisProp] = offset, _state$modifiersData$.centerOffset = offset - center, _state$modifiersData$);\n}\n\nfunction effect(_ref2) {\n var state = _ref2.state,\n options = _ref2.options;\n var _options$element = options.element,\n arrowElement = _options$element === void 0 ? '[data-popper-arrow]' : _options$element;\n\n if (arrowElement == null) {\n return;\n } // CSS selector\n\n\n if (typeof arrowElement === 'string') {\n arrowElement = state.elements.popper.querySelector(arrowElement);\n\n if (!arrowElement) {\n return;\n }\n }\n\n if (!contains(state.elements.popper, arrowElement)) {\n return;\n }\n\n state.elements.arrow = arrowElement;\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'arrow',\n enabled: true,\n phase: 'main',\n fn: arrow,\n effect: effect,\n requires: ['popperOffsets'],\n requiresIfExists: ['preventOverflow']\n};","export default function getVariation(placement) {\n return placement.split('-')[1];\n}","import { top, left, right, bottom, end } from \"../enums.js\";\nimport getOffsetParent from \"../dom-utils/getOffsetParent.js\";\nimport getWindow from \"../dom-utils/getWindow.js\";\nimport getDocumentElement from \"../dom-utils/getDocumentElement.js\";\nimport getComputedStyle from \"../dom-utils/getComputedStyle.js\";\nimport getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getVariation from \"../utils/getVariation.js\";\nimport { round } from \"../utils/math.js\"; // eslint-disable-next-line import/no-unused-modules\n\nvar unsetSides = {\n top: 'auto',\n right: 'auto',\n bottom: 'auto',\n left: 'auto'\n}; // Round the offsets to the nearest suitable subpixel based on the DPR.\n// Zooming can change the DPR, but it seems to report a value that will\n// cleanly divide the values into the appropriate subpixels.\n\nfunction roundOffsetsByDPR(_ref, win) {\n var x = _ref.x,\n y = _ref.y;\n var dpr = win.devicePixelRatio || 1;\n return {\n x: round(x * dpr) / dpr || 0,\n y: round(y * dpr) / dpr || 0\n };\n}\n\nexport function mapToStyles(_ref2) {\n var _Object$assign2;\n\n var popper = _ref2.popper,\n popperRect = _ref2.popperRect,\n placement = _ref2.placement,\n variation = _ref2.variation,\n offsets = _ref2.offsets,\n position = _ref2.position,\n gpuAcceleration = _ref2.gpuAcceleration,\n adaptive = _ref2.adaptive,\n roundOffsets = _ref2.roundOffsets,\n isFixed = _ref2.isFixed;\n var _offsets$x = offsets.x,\n x = _offsets$x === void 0 ? 0 : _offsets$x,\n _offsets$y = offsets.y,\n y = _offsets$y === void 0 ? 0 : _offsets$y;\n\n var _ref3 = typeof roundOffsets === 'function' ? roundOffsets({\n x: x,\n y: y\n }) : {\n x: x,\n y: y\n };\n\n x = _ref3.x;\n y = _ref3.y;\n var hasX = offsets.hasOwnProperty('x');\n var hasY = offsets.hasOwnProperty('y');\n var sideX = left;\n var sideY = top;\n var win = window;\n\n if (adaptive) {\n var offsetParent = getOffsetParent(popper);\n var heightProp = 'clientHeight';\n var widthProp = 'clientWidth';\n\n if (offsetParent === getWindow(popper)) {\n offsetParent = getDocumentElement(popper);\n\n if (getComputedStyle(offsetParent).position !== 'static' && position === 'absolute') {\n heightProp = 'scrollHeight';\n widthProp = 'scrollWidth';\n }\n } // $FlowFixMe[incompatible-cast]: force type refinement, we compare offsetParent with window above, but Flow doesn't detect it\n\n\n offsetParent = offsetParent;\n\n if (placement === top || (placement === left || placement === right) && variation === end) {\n sideY = bottom;\n var offsetY = isFixed && offsetParent === win && win.visualViewport ? win.visualViewport.height : // $FlowFixMe[prop-missing]\n offsetParent[heightProp];\n y -= offsetY - popperRect.height;\n y *= gpuAcceleration ? 1 : -1;\n }\n\n if (placement === left || (placement === top || placement === bottom) && variation === end) {\n sideX = right;\n var offsetX = isFixed && offsetParent === win && win.visualViewport ? win.visualViewport.width : // $FlowFixMe[prop-missing]\n offsetParent[widthProp];\n x -= offsetX - popperRect.width;\n x *= gpuAcceleration ? 1 : -1;\n }\n }\n\n var commonStyles = Object.assign({\n position: position\n }, adaptive && unsetSides);\n\n var _ref4 = roundOffsets === true ? roundOffsetsByDPR({\n x: x,\n y: y\n }, getWindow(popper)) : {\n x: x,\n y: y\n };\n\n x = _ref4.x;\n y = _ref4.y;\n\n if (gpuAcceleration) {\n var _Object$assign;\n\n return Object.assign({}, commonStyles, (_Object$assign = {}, _Object$assign[sideY] = hasY ? '0' : '', _Object$assign[sideX] = hasX ? '0' : '', _Object$assign.transform = (win.devicePixelRatio || 1) <= 1 ? \"translate(\" + x + \"px, \" + y + \"px)\" : \"translate3d(\" + x + \"px, \" + y + \"px, 0)\", _Object$assign));\n }\n\n return Object.assign({}, commonStyles, (_Object$assign2 = {}, _Object$assign2[sideY] = hasY ? y + \"px\" : '', _Object$assign2[sideX] = hasX ? x + \"px\" : '', _Object$assign2.transform = '', _Object$assign2));\n}\n\nfunction computeStyles(_ref5) {\n var state = _ref5.state,\n options = _ref5.options;\n var _options$gpuAccelerat = options.gpuAcceleration,\n gpuAcceleration = _options$gpuAccelerat === void 0 ? true : _options$gpuAccelerat,\n _options$adaptive = options.adaptive,\n adaptive = _options$adaptive === void 0 ? true : _options$adaptive,\n _options$roundOffsets = options.roundOffsets,\n roundOffsets = _options$roundOffsets === void 0 ? true : _options$roundOffsets;\n var commonStyles = {\n placement: getBasePlacement(state.placement),\n variation: getVariation(state.placement),\n popper: state.elements.popper,\n popperRect: state.rects.popper,\n gpuAcceleration: gpuAcceleration,\n isFixed: state.options.strategy === 'fixed'\n };\n\n if (state.modifiersData.popperOffsets != null) {\n state.styles.popper = Object.assign({}, state.styles.popper, mapToStyles(Object.assign({}, commonStyles, {\n offsets: state.modifiersData.popperOffsets,\n position: state.options.strategy,\n adaptive: adaptive,\n roundOffsets: roundOffsets\n })));\n }\n\n if (state.modifiersData.arrow != null) {\n state.styles.arrow = Object.assign({}, state.styles.arrow, mapToStyles(Object.assign({}, commonStyles, {\n offsets: state.modifiersData.arrow,\n position: 'absolute',\n adaptive: false,\n roundOffsets: roundOffsets\n })));\n }\n\n state.attributes.popper = Object.assign({}, state.attributes.popper, {\n 'data-popper-placement': state.placement\n });\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'computeStyles',\n enabled: true,\n phase: 'beforeWrite',\n fn: computeStyles,\n data: {}\n};","import getWindow from \"../dom-utils/getWindow.js\"; // eslint-disable-next-line import/no-unused-modules\n\nvar passive = {\n passive: true\n};\n\nfunction effect(_ref) {\n var state = _ref.state,\n instance = _ref.instance,\n options = _ref.options;\n var _options$scroll = options.scroll,\n scroll = _options$scroll === void 0 ? true : _options$scroll,\n _options$resize = options.resize,\n resize = _options$resize === void 0 ? true : _options$resize;\n var window = getWindow(state.elements.popper);\n var scrollParents = [].concat(state.scrollParents.reference, state.scrollParents.popper);\n\n if (scroll) {\n scrollParents.forEach(function (scrollParent) {\n scrollParent.addEventListener('scroll', instance.update, passive);\n });\n }\n\n if (resize) {\n window.addEventListener('resize', instance.update, passive);\n }\n\n return function () {\n if (scroll) {\n scrollParents.forEach(function (scrollParent) {\n scrollParent.removeEventListener('scroll', instance.update, passive);\n });\n }\n\n if (resize) {\n window.removeEventListener('resize', instance.update, passive);\n }\n };\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'eventListeners',\n enabled: true,\n phase: 'write',\n fn: function fn() {},\n effect: effect,\n data: {}\n};","var hash = {\n left: 'right',\n right: 'left',\n bottom: 'top',\n top: 'bottom'\n};\nexport default function getOppositePlacement(placement) {\n return placement.replace(/left|right|bottom|top/g, function (matched) {\n return hash[matched];\n });\n}","var hash = {\n start: 'end',\n end: 'start'\n};\nexport default function getOppositeVariationPlacement(placement) {\n return placement.replace(/start|end/g, function (matched) {\n return hash[matched];\n });\n}","import getWindow from \"./getWindow.js\";\nexport default function getWindowScroll(node) {\n var win = getWindow(node);\n var scrollLeft = win.pageXOffset;\n var scrollTop = win.pageYOffset;\n return {\n scrollLeft: scrollLeft,\n scrollTop: scrollTop\n };\n}","import getBoundingClientRect from \"./getBoundingClientRect.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport getWindowScroll from \"./getWindowScroll.js\";\nexport default function getWindowScrollBarX(element) {\n // If has a CSS width greater than the viewport, then this will be\n // incorrect for RTL.\n // Popper 1 is broken in this case and never had a bug report so let's assume\n // it's not an issue. I don't think anyone ever specifies width on \n // anyway.\n // Browsers where the left scrollbar doesn't cause an issue report `0` for\n // this (e.g. Edge 2019, IE11, Safari)\n return getBoundingClientRect(getDocumentElement(element)).left + getWindowScroll(element).scrollLeft;\n}","import getWindow from \"./getWindow.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport getWindowScrollBarX from \"./getWindowScrollBarX.js\";\nimport isLayoutViewport from \"./isLayoutViewport.js\";\nexport default function getViewportRect(element, strategy) {\n var win = getWindow(element);\n var html = getDocumentElement(element);\n var visualViewport = win.visualViewport;\n var width = html.clientWidth;\n var height = html.clientHeight;\n var x = 0;\n var y = 0;\n\n if (visualViewport) {\n width = visualViewport.width;\n height = visualViewport.height;\n var layoutViewport = isLayoutViewport();\n\n if (layoutViewport || !layoutViewport && strategy === 'fixed') {\n x = visualViewport.offsetLeft;\n y = visualViewport.offsetTop;\n }\n }\n\n return {\n width: width,\n height: height,\n x: x + getWindowScrollBarX(element),\n y: y\n };\n}","import getDocumentElement from \"./getDocumentElement.js\";\nimport getComputedStyle from \"./getComputedStyle.js\";\nimport getWindowScrollBarX from \"./getWindowScrollBarX.js\";\nimport getWindowScroll from \"./getWindowScroll.js\";\nimport { max } from \"../utils/math.js\"; // Gets the entire size of the scrollable document area, even extending outside\n// of the `` and `` rect bounds if horizontally scrollable\n\nexport default function getDocumentRect(element) {\n var _element$ownerDocumen;\n\n var html = getDocumentElement(element);\n var winScroll = getWindowScroll(element);\n var body = (_element$ownerDocumen = element.ownerDocument) == null ? void 0 : _element$ownerDocumen.body;\n var width = max(html.scrollWidth, html.clientWidth, body ? body.scrollWidth : 0, body ? body.clientWidth : 0);\n var height = max(html.scrollHeight, html.clientHeight, body ? body.scrollHeight : 0, body ? body.clientHeight : 0);\n var x = -winScroll.scrollLeft + getWindowScrollBarX(element);\n var y = -winScroll.scrollTop;\n\n if (getComputedStyle(body || html).direction === 'rtl') {\n x += max(html.clientWidth, body ? body.clientWidth : 0) - width;\n }\n\n return {\n width: width,\n height: height,\n x: x,\n y: y\n };\n}","import getComputedStyle from \"./getComputedStyle.js\";\nexport default function isScrollParent(element) {\n // Firefox wants us to check `-x` and `-y` variations as well\n var _getComputedStyle = getComputedStyle(element),\n overflow = _getComputedStyle.overflow,\n overflowX = _getComputedStyle.overflowX,\n overflowY = _getComputedStyle.overflowY;\n\n return /auto|scroll|overlay|hidden/.test(overflow + overflowY + overflowX);\n}","import getParentNode from \"./getParentNode.js\";\nimport isScrollParent from \"./isScrollParent.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport { isHTMLElement } from \"./instanceOf.js\";\nexport default function getScrollParent(node) {\n if (['html', 'body', '#document'].indexOf(getNodeName(node)) >= 0) {\n // $FlowFixMe[incompatible-return]: assume body is always available\n return node.ownerDocument.body;\n }\n\n if (isHTMLElement(node) && isScrollParent(node)) {\n return node;\n }\n\n return getScrollParent(getParentNode(node));\n}","import getScrollParent from \"./getScrollParent.js\";\nimport getParentNode from \"./getParentNode.js\";\nimport getWindow from \"./getWindow.js\";\nimport isScrollParent from \"./isScrollParent.js\";\n/*\ngiven a DOM element, return the list of all scroll parents, up the list of ancesors\nuntil we get to the top window object. This list is what we attach scroll listeners\nto, because if any of these parent elements scroll, we'll need to re-calculate the\nreference element's position.\n*/\n\nexport default function listScrollParents(element, list) {\n var _element$ownerDocumen;\n\n if (list === void 0) {\n list = [];\n }\n\n var scrollParent = getScrollParent(element);\n var isBody = scrollParent === ((_element$ownerDocumen = element.ownerDocument) == null ? void 0 : _element$ownerDocumen.body);\n var win = getWindow(scrollParent);\n var target = isBody ? [win].concat(win.visualViewport || [], isScrollParent(scrollParent) ? scrollParent : []) : scrollParent;\n var updatedList = list.concat(target);\n return isBody ? updatedList : // $FlowFixMe[incompatible-call]: isBody tells us target will be an HTMLElement here\n updatedList.concat(listScrollParents(getParentNode(target)));\n}","export default function rectToClientRect(rect) {\n return Object.assign({}, rect, {\n left: rect.x,\n top: rect.y,\n right: rect.x + rect.width,\n bottom: rect.y + rect.height\n });\n}","import { viewport } from \"../enums.js\";\nimport getViewportRect from \"./getViewportRect.js\";\nimport getDocumentRect from \"./getDocumentRect.js\";\nimport listScrollParents from \"./listScrollParents.js\";\nimport getOffsetParent from \"./getOffsetParent.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport getComputedStyle from \"./getComputedStyle.js\";\nimport { isElement, isHTMLElement } from \"./instanceOf.js\";\nimport getBoundingClientRect from \"./getBoundingClientRect.js\";\nimport getParentNode from \"./getParentNode.js\";\nimport contains from \"./contains.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport rectToClientRect from \"../utils/rectToClientRect.js\";\nimport { max, min } from \"../utils/math.js\";\n\nfunction getInnerBoundingClientRect(element, strategy) {\n var rect = getBoundingClientRect(element, false, strategy === 'fixed');\n rect.top = rect.top + element.clientTop;\n rect.left = rect.left + element.clientLeft;\n rect.bottom = rect.top + element.clientHeight;\n rect.right = rect.left + element.clientWidth;\n rect.width = element.clientWidth;\n rect.height = element.clientHeight;\n rect.x = rect.left;\n rect.y = rect.top;\n return rect;\n}\n\nfunction getClientRectFromMixedType(element, clippingParent, strategy) {\n return clippingParent === viewport ? rectToClientRect(getViewportRect(element, strategy)) : isElement(clippingParent) ? getInnerBoundingClientRect(clippingParent, strategy) : rectToClientRect(getDocumentRect(getDocumentElement(element)));\n} // A \"clipping parent\" is an overflowable container with the characteristic of\n// clipping (or hiding) overflowing elements with a position different from\n// `initial`\n\n\nfunction getClippingParents(element) {\n var clippingParents = listScrollParents(getParentNode(element));\n var canEscapeClipping = ['absolute', 'fixed'].indexOf(getComputedStyle(element).position) >= 0;\n var clipperElement = canEscapeClipping && isHTMLElement(element) ? getOffsetParent(element) : element;\n\n if (!isElement(clipperElement)) {\n return [];\n } // $FlowFixMe[incompatible-return]: https://github.com/facebook/flow/issues/1414\n\n\n return clippingParents.filter(function (clippingParent) {\n return isElement(clippingParent) && contains(clippingParent, clipperElement) && getNodeName(clippingParent) !== 'body';\n });\n} // Gets the maximum area that the element is visible in due to any number of\n// clipping parents\n\n\nexport default function getClippingRect(element, boundary, rootBoundary, strategy) {\n var mainClippingParents = boundary === 'clippingParents' ? getClippingParents(element) : [].concat(boundary);\n var clippingParents = [].concat(mainClippingParents, [rootBoundary]);\n var firstClippingParent = clippingParents[0];\n var clippingRect = clippingParents.reduce(function (accRect, clippingParent) {\n var rect = getClientRectFromMixedType(element, clippingParent, strategy);\n accRect.top = max(rect.top, accRect.top);\n accRect.right = min(rect.right, accRect.right);\n accRect.bottom = min(rect.bottom, accRect.bottom);\n accRect.left = max(rect.left, accRect.left);\n return accRect;\n }, getClientRectFromMixedType(element, firstClippingParent, strategy));\n clippingRect.width = clippingRect.right - clippingRect.left;\n clippingRect.height = clippingRect.bottom - clippingRect.top;\n clippingRect.x = clippingRect.left;\n clippingRect.y = clippingRect.top;\n return clippingRect;\n}","import getBasePlacement from \"./getBasePlacement.js\";\nimport getVariation from \"./getVariation.js\";\nimport getMainAxisFromPlacement from \"./getMainAxisFromPlacement.js\";\nimport { top, right, bottom, left, start, end } from \"../enums.js\";\nexport default function computeOffsets(_ref) {\n var reference = _ref.reference,\n element = _ref.element,\n placement = _ref.placement;\n var basePlacement = placement ? getBasePlacement(placement) : null;\n var variation = placement ? getVariation(placement) : null;\n var commonX = reference.x + reference.width / 2 - element.width / 2;\n var commonY = reference.y + reference.height / 2 - element.height / 2;\n var offsets;\n\n switch (basePlacement) {\n case top:\n offsets = {\n x: commonX,\n y: reference.y - element.height\n };\n break;\n\n case bottom:\n offsets = {\n x: commonX,\n y: reference.y + reference.height\n };\n break;\n\n case right:\n offsets = {\n x: reference.x + reference.width,\n y: commonY\n };\n break;\n\n case left:\n offsets = {\n x: reference.x - element.width,\n y: commonY\n };\n break;\n\n default:\n offsets = {\n x: reference.x,\n y: reference.y\n };\n }\n\n var mainAxis = basePlacement ? getMainAxisFromPlacement(basePlacement) : null;\n\n if (mainAxis != null) {\n var len = mainAxis === 'y' ? 'height' : 'width';\n\n switch (variation) {\n case start:\n offsets[mainAxis] = offsets[mainAxis] - (reference[len] / 2 - element[len] / 2);\n break;\n\n case end:\n offsets[mainAxis] = offsets[mainAxis] + (reference[len] / 2 - element[len] / 2);\n break;\n\n default:\n }\n }\n\n return offsets;\n}","import getClippingRect from \"../dom-utils/getClippingRect.js\";\nimport getDocumentElement from \"../dom-utils/getDocumentElement.js\";\nimport getBoundingClientRect from \"../dom-utils/getBoundingClientRect.js\";\nimport computeOffsets from \"./computeOffsets.js\";\nimport rectToClientRect from \"./rectToClientRect.js\";\nimport { clippingParents, reference, popper, bottom, top, right, basePlacements, viewport } from \"../enums.js\";\nimport { isElement } from \"../dom-utils/instanceOf.js\";\nimport mergePaddingObject from \"./mergePaddingObject.js\";\nimport expandToHashMap from \"./expandToHashMap.js\"; // eslint-disable-next-line import/no-unused-modules\n\nexport default function detectOverflow(state, options) {\n if (options === void 0) {\n options = {};\n }\n\n var _options = options,\n _options$placement = _options.placement,\n placement = _options$placement === void 0 ? state.placement : _options$placement,\n _options$strategy = _options.strategy,\n strategy = _options$strategy === void 0 ? state.strategy : _options$strategy,\n _options$boundary = _options.boundary,\n boundary = _options$boundary === void 0 ? clippingParents : _options$boundary,\n _options$rootBoundary = _options.rootBoundary,\n rootBoundary = _options$rootBoundary === void 0 ? viewport : _options$rootBoundary,\n _options$elementConte = _options.elementContext,\n elementContext = _options$elementConte === void 0 ? popper : _options$elementConte,\n _options$altBoundary = _options.altBoundary,\n altBoundary = _options$altBoundary === void 0 ? false : _options$altBoundary,\n _options$padding = _options.padding,\n padding = _options$padding === void 0 ? 0 : _options$padding;\n var paddingObject = mergePaddingObject(typeof padding !== 'number' ? padding : expandToHashMap(padding, basePlacements));\n var altContext = elementContext === popper ? reference : popper;\n var popperRect = state.rects.popper;\n var element = state.elements[altBoundary ? altContext : elementContext];\n var clippingClientRect = getClippingRect(isElement(element) ? element : element.contextElement || getDocumentElement(state.elements.popper), boundary, rootBoundary, strategy);\n var referenceClientRect = getBoundingClientRect(state.elements.reference);\n var popperOffsets = computeOffsets({\n reference: referenceClientRect,\n element: popperRect,\n strategy: 'absolute',\n placement: placement\n });\n var popperClientRect = rectToClientRect(Object.assign({}, popperRect, popperOffsets));\n var elementClientRect = elementContext === popper ? popperClientRect : referenceClientRect; // positive = overflowing the clipping rect\n // 0 or negative = within the clipping rect\n\n var overflowOffsets = {\n top: clippingClientRect.top - elementClientRect.top + paddingObject.top,\n bottom: elementClientRect.bottom - clippingClientRect.bottom + paddingObject.bottom,\n left: clippingClientRect.left - elementClientRect.left + paddingObject.left,\n right: elementClientRect.right - clippingClientRect.right + paddingObject.right\n };\n var offsetData = state.modifiersData.offset; // Offsets can be applied only to the popper element\n\n if (elementContext === popper && offsetData) {\n var offset = offsetData[placement];\n Object.keys(overflowOffsets).forEach(function (key) {\n var multiply = [right, bottom].indexOf(key) >= 0 ? 1 : -1;\n var axis = [top, bottom].indexOf(key) >= 0 ? 'y' : 'x';\n overflowOffsets[key] += offset[axis] * multiply;\n });\n }\n\n return overflowOffsets;\n}","import getVariation from \"./getVariation.js\";\nimport { variationPlacements, basePlacements, placements as allPlacements } from \"../enums.js\";\nimport detectOverflow from \"./detectOverflow.js\";\nimport getBasePlacement from \"./getBasePlacement.js\";\nexport default function computeAutoPlacement(state, options) {\n if (options === void 0) {\n options = {};\n }\n\n var _options = options,\n placement = _options.placement,\n boundary = _options.boundary,\n rootBoundary = _options.rootBoundary,\n padding = _options.padding,\n flipVariations = _options.flipVariations,\n _options$allowedAutoP = _options.allowedAutoPlacements,\n allowedAutoPlacements = _options$allowedAutoP === void 0 ? allPlacements : _options$allowedAutoP;\n var variation = getVariation(placement);\n var placements = variation ? flipVariations ? variationPlacements : variationPlacements.filter(function (placement) {\n return getVariation(placement) === variation;\n }) : basePlacements;\n var allowedPlacements = placements.filter(function (placement) {\n return allowedAutoPlacements.indexOf(placement) >= 0;\n });\n\n if (allowedPlacements.length === 0) {\n allowedPlacements = placements;\n } // $FlowFixMe[incompatible-type]: Flow seems to have problems with two array unions...\n\n\n var overflows = allowedPlacements.reduce(function (acc, placement) {\n acc[placement] = detectOverflow(state, {\n placement: placement,\n boundary: boundary,\n rootBoundary: rootBoundary,\n padding: padding\n })[getBasePlacement(placement)];\n return acc;\n }, {});\n return Object.keys(overflows).sort(function (a, b) {\n return overflows[a] - overflows[b];\n });\n}","import getOppositePlacement from \"../utils/getOppositePlacement.js\";\nimport getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getOppositeVariationPlacement from \"../utils/getOppositeVariationPlacement.js\";\nimport detectOverflow from \"../utils/detectOverflow.js\";\nimport computeAutoPlacement from \"../utils/computeAutoPlacement.js\";\nimport { bottom, top, start, right, left, auto } from \"../enums.js\";\nimport getVariation from \"../utils/getVariation.js\"; // eslint-disable-next-line import/no-unused-modules\n\nfunction getExpandedFallbackPlacements(placement) {\n if (getBasePlacement(placement) === auto) {\n return [];\n }\n\n var oppositePlacement = getOppositePlacement(placement);\n return [getOppositeVariationPlacement(placement), oppositePlacement, getOppositeVariationPlacement(oppositePlacement)];\n}\n\nfunction flip(_ref) {\n var state = _ref.state,\n options = _ref.options,\n name = _ref.name;\n\n if (state.modifiersData[name]._skip) {\n return;\n }\n\n var _options$mainAxis = options.mainAxis,\n checkMainAxis = _options$mainAxis === void 0 ? true : _options$mainAxis,\n _options$altAxis = options.altAxis,\n checkAltAxis = _options$altAxis === void 0 ? true : _options$altAxis,\n specifiedFallbackPlacements = options.fallbackPlacements,\n padding = options.padding,\n boundary = options.boundary,\n rootBoundary = options.rootBoundary,\n altBoundary = options.altBoundary,\n _options$flipVariatio = options.flipVariations,\n flipVariations = _options$flipVariatio === void 0 ? true : _options$flipVariatio,\n allowedAutoPlacements = options.allowedAutoPlacements;\n var preferredPlacement = state.options.placement;\n var basePlacement = getBasePlacement(preferredPlacement);\n var isBasePlacement = basePlacement === preferredPlacement;\n var fallbackPlacements = specifiedFallbackPlacements || (isBasePlacement || !flipVariations ? [getOppositePlacement(preferredPlacement)] : getExpandedFallbackPlacements(preferredPlacement));\n var placements = [preferredPlacement].concat(fallbackPlacements).reduce(function (acc, placement) {\n return acc.concat(getBasePlacement(placement) === auto ? computeAutoPlacement(state, {\n placement: placement,\n boundary: boundary,\n rootBoundary: rootBoundary,\n padding: padding,\n flipVariations: flipVariations,\n allowedAutoPlacements: allowedAutoPlacements\n }) : placement);\n }, []);\n var referenceRect = state.rects.reference;\n var popperRect = state.rects.popper;\n var checksMap = new Map();\n var makeFallbackChecks = true;\n var firstFittingPlacement = placements[0];\n\n for (var i = 0; i < placements.length; i++) {\n var placement = placements[i];\n\n var _basePlacement = getBasePlacement(placement);\n\n var isStartVariation = getVariation(placement) === start;\n var isVertical = [top, bottom].indexOf(_basePlacement) >= 0;\n var len = isVertical ? 'width' : 'height';\n var overflow = detectOverflow(state, {\n placement: placement,\n boundary: boundary,\n rootBoundary: rootBoundary,\n altBoundary: altBoundary,\n padding: padding\n });\n var mainVariationSide = isVertical ? isStartVariation ? right : left : isStartVariation ? bottom : top;\n\n if (referenceRect[len] > popperRect[len]) {\n mainVariationSide = getOppositePlacement(mainVariationSide);\n }\n\n var altVariationSide = getOppositePlacement(mainVariationSide);\n var checks = [];\n\n if (checkMainAxis) {\n checks.push(overflow[_basePlacement] <= 0);\n }\n\n if (checkAltAxis) {\n checks.push(overflow[mainVariationSide] <= 0, overflow[altVariationSide] <= 0);\n }\n\n if (checks.every(function (check) {\n return check;\n })) {\n firstFittingPlacement = placement;\n makeFallbackChecks = false;\n break;\n }\n\n checksMap.set(placement, checks);\n }\n\n if (makeFallbackChecks) {\n // `2` may be desired in some cases – research later\n var numberOfChecks = flipVariations ? 3 : 1;\n\n var _loop = function _loop(_i) {\n var fittingPlacement = placements.find(function (placement) {\n var checks = checksMap.get(placement);\n\n if (checks) {\n return checks.slice(0, _i).every(function (check) {\n return check;\n });\n }\n });\n\n if (fittingPlacement) {\n firstFittingPlacement = fittingPlacement;\n return \"break\";\n }\n };\n\n for (var _i = numberOfChecks; _i > 0; _i--) {\n var _ret = _loop(_i);\n\n if (_ret === \"break\") break;\n }\n }\n\n if (state.placement !== firstFittingPlacement) {\n state.modifiersData[name]._skip = true;\n state.placement = firstFittingPlacement;\n state.reset = true;\n }\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'flip',\n enabled: true,\n phase: 'main',\n fn: flip,\n requiresIfExists: ['offset'],\n data: {\n _skip: false\n }\n};","import { top, bottom, left, right } from \"../enums.js\";\nimport detectOverflow from \"../utils/detectOverflow.js\";\n\nfunction getSideOffsets(overflow, rect, preventedOffsets) {\n if (preventedOffsets === void 0) {\n preventedOffsets = {\n x: 0,\n y: 0\n };\n }\n\n return {\n top: overflow.top - rect.height - preventedOffsets.y,\n right: overflow.right - rect.width + preventedOffsets.x,\n bottom: overflow.bottom - rect.height + preventedOffsets.y,\n left: overflow.left - rect.width - preventedOffsets.x\n };\n}\n\nfunction isAnySideFullyClipped(overflow) {\n return [top, right, bottom, left].some(function (side) {\n return overflow[side] >= 0;\n });\n}\n\nfunction hide(_ref) {\n var state = _ref.state,\n name = _ref.name;\n var referenceRect = state.rects.reference;\n var popperRect = state.rects.popper;\n var preventedOffsets = state.modifiersData.preventOverflow;\n var referenceOverflow = detectOverflow(state, {\n elementContext: 'reference'\n });\n var popperAltOverflow = detectOverflow(state, {\n altBoundary: true\n });\n var referenceClippingOffsets = getSideOffsets(referenceOverflow, referenceRect);\n var popperEscapeOffsets = getSideOffsets(popperAltOverflow, popperRect, preventedOffsets);\n var isReferenceHidden = isAnySideFullyClipped(referenceClippingOffsets);\n var hasPopperEscaped = isAnySideFullyClipped(popperEscapeOffsets);\n state.modifiersData[name] = {\n referenceClippingOffsets: referenceClippingOffsets,\n popperEscapeOffsets: popperEscapeOffsets,\n isReferenceHidden: isReferenceHidden,\n hasPopperEscaped: hasPopperEscaped\n };\n state.attributes.popper = Object.assign({}, state.attributes.popper, {\n 'data-popper-reference-hidden': isReferenceHidden,\n 'data-popper-escaped': hasPopperEscaped\n });\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'hide',\n enabled: true,\n phase: 'main',\n requiresIfExists: ['preventOverflow'],\n fn: hide\n};","import getBasePlacement from \"../utils/getBasePlacement.js\";\nimport { top, left, right, placements } from \"../enums.js\"; // eslint-disable-next-line import/no-unused-modules\n\nexport function distanceAndSkiddingToXY(placement, rects, offset) {\n var basePlacement = getBasePlacement(placement);\n var invertDistance = [left, top].indexOf(basePlacement) >= 0 ? -1 : 1;\n\n var _ref = typeof offset === 'function' ? offset(Object.assign({}, rects, {\n placement: placement\n })) : offset,\n skidding = _ref[0],\n distance = _ref[1];\n\n skidding = skidding || 0;\n distance = (distance || 0) * invertDistance;\n return [left, right].indexOf(basePlacement) >= 0 ? {\n x: distance,\n y: skidding\n } : {\n x: skidding,\n y: distance\n };\n}\n\nfunction offset(_ref2) {\n var state = _ref2.state,\n options = _ref2.options,\n name = _ref2.name;\n var _options$offset = options.offset,\n offset = _options$offset === void 0 ? [0, 0] : _options$offset;\n var data = placements.reduce(function (acc, placement) {\n acc[placement] = distanceAndSkiddingToXY(placement, state.rects, offset);\n return acc;\n }, {});\n var _data$state$placement = data[state.placement],\n x = _data$state$placement.x,\n y = _data$state$placement.y;\n\n if (state.modifiersData.popperOffsets != null) {\n state.modifiersData.popperOffsets.x += x;\n state.modifiersData.popperOffsets.y += y;\n }\n\n state.modifiersData[name] = data;\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'offset',\n enabled: true,\n phase: 'main',\n requires: ['popperOffsets'],\n fn: offset\n};","import computeOffsets from \"../utils/computeOffsets.js\";\n\nfunction popperOffsets(_ref) {\n var state = _ref.state,\n name = _ref.name;\n // Offsets are the actual position the popper needs to have to be\n // properly positioned near its reference element\n // This is the most basic placement, and will be adjusted by\n // the modifiers in the next step\n state.modifiersData[name] = computeOffsets({\n reference: state.rects.reference,\n element: state.rects.popper,\n strategy: 'absolute',\n placement: state.placement\n });\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'popperOffsets',\n enabled: true,\n phase: 'read',\n fn: popperOffsets,\n data: {}\n};","export default function getAltAxis(axis) {\n return axis === 'x' ? 'y' : 'x';\n}","import { top, left, right, bottom, start } from \"../enums.js\";\nimport getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getMainAxisFromPlacement from \"../utils/getMainAxisFromPlacement.js\";\nimport getAltAxis from \"../utils/getAltAxis.js\";\nimport { within, withinMaxClamp } from \"../utils/within.js\";\nimport getLayoutRect from \"../dom-utils/getLayoutRect.js\";\nimport getOffsetParent from \"../dom-utils/getOffsetParent.js\";\nimport detectOverflow from \"../utils/detectOverflow.js\";\nimport getVariation from \"../utils/getVariation.js\";\nimport getFreshSideObject from \"../utils/getFreshSideObject.js\";\nimport { min as mathMin, max as mathMax } from \"../utils/math.js\";\n\nfunction preventOverflow(_ref) {\n var state = _ref.state,\n options = _ref.options,\n name = _ref.name;\n var _options$mainAxis = options.mainAxis,\n checkMainAxis = _options$mainAxis === void 0 ? true : _options$mainAxis,\n _options$altAxis = options.altAxis,\n checkAltAxis = _options$altAxis === void 0 ? false : _options$altAxis,\n boundary = options.boundary,\n rootBoundary = options.rootBoundary,\n altBoundary = options.altBoundary,\n padding = options.padding,\n _options$tether = options.tether,\n tether = _options$tether === void 0 ? true : _options$tether,\n _options$tetherOffset = options.tetherOffset,\n tetherOffset = _options$tetherOffset === void 0 ? 0 : _options$tetherOffset;\n var overflow = detectOverflow(state, {\n boundary: boundary,\n rootBoundary: rootBoundary,\n padding: padding,\n altBoundary: altBoundary\n });\n var basePlacement = getBasePlacement(state.placement);\n var variation = getVariation(state.placement);\n var isBasePlacement = !variation;\n var mainAxis = getMainAxisFromPlacement(basePlacement);\n var altAxis = getAltAxis(mainAxis);\n var popperOffsets = state.modifiersData.popperOffsets;\n var referenceRect = state.rects.reference;\n var popperRect = state.rects.popper;\n var tetherOffsetValue = typeof tetherOffset === 'function' ? tetherOffset(Object.assign({}, state.rects, {\n placement: state.placement\n })) : tetherOffset;\n var normalizedTetherOffsetValue = typeof tetherOffsetValue === 'number' ? {\n mainAxis: tetherOffsetValue,\n altAxis: tetherOffsetValue\n } : Object.assign({\n mainAxis: 0,\n altAxis: 0\n }, tetherOffsetValue);\n var offsetModifierState = state.modifiersData.offset ? state.modifiersData.offset[state.placement] : null;\n var data = {\n x: 0,\n y: 0\n };\n\n if (!popperOffsets) {\n return;\n }\n\n if (checkMainAxis) {\n var _offsetModifierState$;\n\n var mainSide = mainAxis === 'y' ? top : left;\n var altSide = mainAxis === 'y' ? bottom : right;\n var len = mainAxis === 'y' ? 'height' : 'width';\n var offset = popperOffsets[mainAxis];\n var min = offset + overflow[mainSide];\n var max = offset - overflow[altSide];\n var additive = tether ? -popperRect[len] / 2 : 0;\n var minLen = variation === start ? referenceRect[len] : popperRect[len];\n var maxLen = variation === start ? -popperRect[len] : -referenceRect[len]; // We need to include the arrow in the calculation so the arrow doesn't go\n // outside the reference bounds\n\n var arrowElement = state.elements.arrow;\n var arrowRect = tether && arrowElement ? getLayoutRect(arrowElement) : {\n width: 0,\n height: 0\n };\n var arrowPaddingObject = state.modifiersData['arrow#persistent'] ? state.modifiersData['arrow#persistent'].padding : getFreshSideObject();\n var arrowPaddingMin = arrowPaddingObject[mainSide];\n var arrowPaddingMax = arrowPaddingObject[altSide]; // If the reference length is smaller than the arrow length, we don't want\n // to include its full size in the calculation. If the reference is small\n // and near the edge of a boundary, the popper can overflow even if the\n // reference is not overflowing as well (e.g. virtual elements with no\n // width or height)\n\n var arrowLen = within(0, referenceRect[len], arrowRect[len]);\n var minOffset = isBasePlacement ? referenceRect[len] / 2 - additive - arrowLen - arrowPaddingMin - normalizedTetherOffsetValue.mainAxis : minLen - arrowLen - arrowPaddingMin - normalizedTetherOffsetValue.mainAxis;\n var maxOffset = isBasePlacement ? -referenceRect[len] / 2 + additive + arrowLen + arrowPaddingMax + normalizedTetherOffsetValue.mainAxis : maxLen + arrowLen + arrowPaddingMax + normalizedTetherOffsetValue.mainAxis;\n var arrowOffsetParent = state.elements.arrow && getOffsetParent(state.elements.arrow);\n var clientOffset = arrowOffsetParent ? mainAxis === 'y' ? arrowOffsetParent.clientTop || 0 : arrowOffsetParent.clientLeft || 0 : 0;\n var offsetModifierValue = (_offsetModifierState$ = offsetModifierState == null ? void 0 : offsetModifierState[mainAxis]) != null ? _offsetModifierState$ : 0;\n var tetherMin = offset + minOffset - offsetModifierValue - clientOffset;\n var tetherMax = offset + maxOffset - offsetModifierValue;\n var preventedOffset = within(tether ? mathMin(min, tetherMin) : min, offset, tether ? mathMax(max, tetherMax) : max);\n popperOffsets[mainAxis] = preventedOffset;\n data[mainAxis] = preventedOffset - offset;\n }\n\n if (checkAltAxis) {\n var _offsetModifierState$2;\n\n var _mainSide = mainAxis === 'x' ? top : left;\n\n var _altSide = mainAxis === 'x' ? bottom : right;\n\n var _offset = popperOffsets[altAxis];\n\n var _len = altAxis === 'y' ? 'height' : 'width';\n\n var _min = _offset + overflow[_mainSide];\n\n var _max = _offset - overflow[_altSide];\n\n var isOriginSide = [top, left].indexOf(basePlacement) !== -1;\n\n var _offsetModifierValue = (_offsetModifierState$2 = offsetModifierState == null ? void 0 : offsetModifierState[altAxis]) != null ? _offsetModifierState$2 : 0;\n\n var _tetherMin = isOriginSide ? _min : _offset - referenceRect[_len] - popperRect[_len] - _offsetModifierValue + normalizedTetherOffsetValue.altAxis;\n\n var _tetherMax = isOriginSide ? _offset + referenceRect[_len] + popperRect[_len] - _offsetModifierValue - normalizedTetherOffsetValue.altAxis : _max;\n\n var _preventedOffset = tether && isOriginSide ? withinMaxClamp(_tetherMin, _offset, _tetherMax) : within(tether ? _tetherMin : _min, _offset, tether ? _tetherMax : _max);\n\n popperOffsets[altAxis] = _preventedOffset;\n data[altAxis] = _preventedOffset - _offset;\n }\n\n state.modifiersData[name] = data;\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'preventOverflow',\n enabled: true,\n phase: 'main',\n fn: preventOverflow,\n requiresIfExists: ['offset']\n};","export default function getHTMLElementScroll(element) {\n return {\n scrollLeft: element.scrollLeft,\n scrollTop: element.scrollTop\n };\n}","import getWindowScroll from \"./getWindowScroll.js\";\nimport getWindow from \"./getWindow.js\";\nimport { isHTMLElement } from \"./instanceOf.js\";\nimport getHTMLElementScroll from \"./getHTMLElementScroll.js\";\nexport default function getNodeScroll(node) {\n if (node === getWindow(node) || !isHTMLElement(node)) {\n return getWindowScroll(node);\n } else {\n return getHTMLElementScroll(node);\n }\n}","import getBoundingClientRect from \"./getBoundingClientRect.js\";\nimport getNodeScroll from \"./getNodeScroll.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport { isHTMLElement } from \"./instanceOf.js\";\nimport getWindowScrollBarX from \"./getWindowScrollBarX.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport isScrollParent from \"./isScrollParent.js\";\nimport { round } from \"../utils/math.js\";\n\nfunction isElementScaled(element) {\n var rect = element.getBoundingClientRect();\n var scaleX = round(rect.width) / element.offsetWidth || 1;\n var scaleY = round(rect.height) / element.offsetHeight || 1;\n return scaleX !== 1 || scaleY !== 1;\n} // Returns the composite rect of an element relative to its offsetParent.\n// Composite means it takes into account transforms as well as layout.\n\n\nexport default function getCompositeRect(elementOrVirtualElement, offsetParent, isFixed) {\n if (isFixed === void 0) {\n isFixed = false;\n }\n\n var isOffsetParentAnElement = isHTMLElement(offsetParent);\n var offsetParentIsScaled = isHTMLElement(offsetParent) && isElementScaled(offsetParent);\n var documentElement = getDocumentElement(offsetParent);\n var rect = getBoundingClientRect(elementOrVirtualElement, offsetParentIsScaled, isFixed);\n var scroll = {\n scrollLeft: 0,\n scrollTop: 0\n };\n var offsets = {\n x: 0,\n y: 0\n };\n\n if (isOffsetParentAnElement || !isOffsetParentAnElement && !isFixed) {\n if (getNodeName(offsetParent) !== 'body' || // https://github.com/popperjs/popper-core/issues/1078\n isScrollParent(documentElement)) {\n scroll = getNodeScroll(offsetParent);\n }\n\n if (isHTMLElement(offsetParent)) {\n offsets = getBoundingClientRect(offsetParent, true);\n offsets.x += offsetParent.clientLeft;\n offsets.y += offsetParent.clientTop;\n } else if (documentElement) {\n offsets.x = getWindowScrollBarX(documentElement);\n }\n }\n\n return {\n x: rect.left + scroll.scrollLeft - offsets.x,\n y: rect.top + scroll.scrollTop - offsets.y,\n width: rect.width,\n height: rect.height\n };\n}","import { modifierPhases } from \"../enums.js\"; // source: https://stackoverflow.com/questions/49875255\n\nfunction order(modifiers) {\n var map = new Map();\n var visited = new Set();\n var result = [];\n modifiers.forEach(function (modifier) {\n map.set(modifier.name, modifier);\n }); // On visiting object, check for its dependencies and visit them recursively\n\n function sort(modifier) {\n visited.add(modifier.name);\n var requires = [].concat(modifier.requires || [], modifier.requiresIfExists || []);\n requires.forEach(function (dep) {\n if (!visited.has(dep)) {\n var depModifier = map.get(dep);\n\n if (depModifier) {\n sort(depModifier);\n }\n }\n });\n result.push(modifier);\n }\n\n modifiers.forEach(function (modifier) {\n if (!visited.has(modifier.name)) {\n // check for visited object\n sort(modifier);\n }\n });\n return result;\n}\n\nexport default function orderModifiers(modifiers) {\n // order based on dependencies\n var orderedModifiers = order(modifiers); // order based on phase\n\n return modifierPhases.reduce(function (acc, phase) {\n return acc.concat(orderedModifiers.filter(function (modifier) {\n return modifier.phase === phase;\n }));\n }, []);\n}","export default function debounce(fn) {\n var pending;\n return function () {\n if (!pending) {\n pending = new Promise(function (resolve) {\n Promise.resolve().then(function () {\n pending = undefined;\n resolve(fn());\n });\n });\n }\n\n return pending;\n };\n}","export default function mergeByName(modifiers) {\n var merged = modifiers.reduce(function (merged, current) {\n var existing = merged[current.name];\n merged[current.name] = existing ? Object.assign({}, existing, current, {\n options: Object.assign({}, existing.options, current.options),\n data: Object.assign({}, existing.data, current.data)\n }) : current;\n return merged;\n }, {}); // IE11 does not support Object.values\n\n return Object.keys(merged).map(function (key) {\n return merged[key];\n });\n}","import getCompositeRect from \"./dom-utils/getCompositeRect.js\";\nimport getLayoutRect from \"./dom-utils/getLayoutRect.js\";\nimport listScrollParents from \"./dom-utils/listScrollParents.js\";\nimport getOffsetParent from \"./dom-utils/getOffsetParent.js\";\nimport orderModifiers from \"./utils/orderModifiers.js\";\nimport debounce from \"./utils/debounce.js\";\nimport mergeByName from \"./utils/mergeByName.js\";\nimport detectOverflow from \"./utils/detectOverflow.js\";\nimport { isElement } from \"./dom-utils/instanceOf.js\";\nvar DEFAULT_OPTIONS = {\n placement: 'bottom',\n modifiers: [],\n strategy: 'absolute'\n};\n\nfunction areValidElements() {\n for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {\n args[_key] = arguments[_key];\n }\n\n return !args.some(function (element) {\n return !(element && typeof element.getBoundingClientRect === 'function');\n });\n}\n\nexport function popperGenerator(generatorOptions) {\n if (generatorOptions === void 0) {\n generatorOptions = {};\n }\n\n var _generatorOptions = generatorOptions,\n _generatorOptions$def = _generatorOptions.defaultModifiers,\n defaultModifiers = _generatorOptions$def === void 0 ? [] : _generatorOptions$def,\n _generatorOptions$def2 = _generatorOptions.defaultOptions,\n defaultOptions = _generatorOptions$def2 === void 0 ? DEFAULT_OPTIONS : _generatorOptions$def2;\n return function createPopper(reference, popper, options) {\n if (options === void 0) {\n options = defaultOptions;\n }\n\n var state = {\n placement: 'bottom',\n orderedModifiers: [],\n options: Object.assign({}, DEFAULT_OPTIONS, defaultOptions),\n modifiersData: {},\n elements: {\n reference: reference,\n popper: popper\n },\n attributes: {},\n styles: {}\n };\n var effectCleanupFns = [];\n var isDestroyed = false;\n var instance = {\n state: state,\n setOptions: function setOptions(setOptionsAction) {\n var options = typeof setOptionsAction === 'function' ? setOptionsAction(state.options) : setOptionsAction;\n cleanupModifierEffects();\n state.options = Object.assign({}, defaultOptions, state.options, options);\n state.scrollParents = {\n reference: isElement(reference) ? listScrollParents(reference) : reference.contextElement ? listScrollParents(reference.contextElement) : [],\n popper: listScrollParents(popper)\n }; // Orders the modifiers based on their dependencies and `phase`\n // properties\n\n var orderedModifiers = orderModifiers(mergeByName([].concat(defaultModifiers, state.options.modifiers))); // Strip out disabled modifiers\n\n state.orderedModifiers = orderedModifiers.filter(function (m) {\n return m.enabled;\n });\n runModifierEffects();\n return instance.update();\n },\n // Sync update – it will always be executed, even if not necessary. This\n // is useful for low frequency updates where sync behavior simplifies the\n // logic.\n // For high frequency updates (e.g. `resize` and `scroll` events), always\n // prefer the async Popper#update method\n forceUpdate: function forceUpdate() {\n if (isDestroyed) {\n return;\n }\n\n var _state$elements = state.elements,\n reference = _state$elements.reference,\n popper = _state$elements.popper; // Don't proceed if `reference` or `popper` are not valid elements\n // anymore\n\n if (!areValidElements(reference, popper)) {\n return;\n } // Store the reference and popper rects to be read by modifiers\n\n\n state.rects = {\n reference: getCompositeRect(reference, getOffsetParent(popper), state.options.strategy === 'fixed'),\n popper: getLayoutRect(popper)\n }; // Modifiers have the ability to reset the current update cycle. The\n // most common use case for this is the `flip` modifier changing the\n // placement, which then needs to re-run all the modifiers, because the\n // logic was previously ran for the previous placement and is therefore\n // stale/incorrect\n\n state.reset = false;\n state.placement = state.options.placement; // On each update cycle, the `modifiersData` property for each modifier\n // is filled with the initial data specified by the modifier. This means\n // it doesn't persist and is fresh on each update.\n // To ensure persistent data, use `${name}#persistent`\n\n state.orderedModifiers.forEach(function (modifier) {\n return state.modifiersData[modifier.name] = Object.assign({}, modifier.data);\n });\n\n for (var index = 0; index < state.orderedModifiers.length; index++) {\n if (state.reset === true) {\n state.reset = false;\n index = -1;\n continue;\n }\n\n var _state$orderedModifie = state.orderedModifiers[index],\n fn = _state$orderedModifie.fn,\n _state$orderedModifie2 = _state$orderedModifie.options,\n _options = _state$orderedModifie2 === void 0 ? {} : _state$orderedModifie2,\n name = _state$orderedModifie.name;\n\n if (typeof fn === 'function') {\n state = fn({\n state: state,\n options: _options,\n name: name,\n instance: instance\n }) || state;\n }\n }\n },\n // Async and optimistically optimized update – it will not be executed if\n // not necessary (debounced to run at most once-per-tick)\n update: debounce(function () {\n return new Promise(function (resolve) {\n instance.forceUpdate();\n resolve(state);\n });\n }),\n destroy: function destroy() {\n cleanupModifierEffects();\n isDestroyed = true;\n }\n };\n\n if (!areValidElements(reference, popper)) {\n return instance;\n }\n\n instance.setOptions(options).then(function (state) {\n if (!isDestroyed && options.onFirstUpdate) {\n options.onFirstUpdate(state);\n }\n }); // Modifiers have the ability to execute arbitrary code before the first\n // update cycle runs. They will be executed in the same order as the update\n // cycle. This is useful when a modifier adds some persistent data that\n // other modifiers need to use, but the modifier is run after the dependent\n // one.\n\n function runModifierEffects() {\n state.orderedModifiers.forEach(function (_ref) {\n var name = _ref.name,\n _ref$options = _ref.options,\n options = _ref$options === void 0 ? {} : _ref$options,\n effect = _ref.effect;\n\n if (typeof effect === 'function') {\n var cleanupFn = effect({\n state: state,\n name: name,\n instance: instance,\n options: options\n });\n\n var noopFn = function noopFn() {};\n\n effectCleanupFns.push(cleanupFn || noopFn);\n }\n });\n }\n\n function cleanupModifierEffects() {\n effectCleanupFns.forEach(function (fn) {\n return fn();\n });\n effectCleanupFns = [];\n }\n\n return instance;\n };\n}\nexport var createPopper = /*#__PURE__*/popperGenerator(); // eslint-disable-next-line import/no-unused-modules\n\nexport { detectOverflow };","import { popperGenerator, detectOverflow } from \"./createPopper.js\";\nimport eventListeners from \"./modifiers/eventListeners.js\";\nimport popperOffsets from \"./modifiers/popperOffsets.js\";\nimport computeStyles from \"./modifiers/computeStyles.js\";\nimport applyStyles from \"./modifiers/applyStyles.js\";\nimport offset from \"./modifiers/offset.js\";\nimport flip from \"./modifiers/flip.js\";\nimport preventOverflow from \"./modifiers/preventOverflow.js\";\nimport arrow from \"./modifiers/arrow.js\";\nimport hide from \"./modifiers/hide.js\";\nvar defaultModifiers = [eventListeners, popperOffsets, computeStyles, applyStyles, offset, flip, preventOverflow, arrow, hide];\nvar createPopper = /*#__PURE__*/popperGenerator({\n defaultModifiers: defaultModifiers\n}); // eslint-disable-next-line import/no-unused-modules\n\nexport { createPopper, popperGenerator, defaultModifiers, detectOverflow }; // eslint-disable-next-line import/no-unused-modules\n\nexport { createPopper as createPopperLite } from \"./popper-lite.js\"; // eslint-disable-next-line import/no-unused-modules\n\nexport * from \"./modifiers/index.js\";","import { generateUtilityClass } from '../generateUtilityClass';\nimport { generateUtilityClasses } from '../generateUtilityClasses';\nconst COMPONENT_NAME = 'Popper';\nexport function getPopperUtilityClass(slot) {\n return generateUtilityClass(COMPONENT_NAME, slot);\n}\nexport const popperClasses = generateUtilityClasses(COMPONENT_NAME, ['root']);","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"anchorEl\", \"children\", \"direction\", \"disablePortal\", \"modifiers\", \"open\", \"placement\", \"popperOptions\", \"popperRef\", \"slotProps\", \"slots\", \"TransitionProps\", \"ownerState\"],\n _excluded2 = [\"anchorEl\", \"children\", \"container\", \"direction\", \"disablePortal\", \"keepMounted\", \"modifiers\", \"open\", \"placement\", \"popperOptions\", \"popperRef\", \"style\", \"transition\", \"slotProps\", \"slots\"];\nimport * as React from 'react';\nimport { chainPropTypes, HTMLElementType, refType, unstable_ownerDocument as ownerDocument, unstable_useEnhancedEffect as useEnhancedEffect, unstable_useForkRef as useForkRef } from '@mui/utils';\nimport { createPopper } from '@popperjs/core';\nimport PropTypes from 'prop-types';\nimport { unstable_composeClasses as composeClasses } from '../composeClasses';\nimport { Portal } from '../Portal';\nimport { getPopperUtilityClass } from './popperClasses';\nimport { useSlotProps } from '../utils';\nimport { useClassNamesOverride } from '../utils/ClassNameConfigurator';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nfunction flipPlacement(placement, direction) {\n if (direction === 'ltr') {\n return placement;\n }\n switch (placement) {\n case 'bottom-end':\n return 'bottom-start';\n case 'bottom-start':\n return 'bottom-end';\n case 'top-end':\n return 'top-start';\n case 'top-start':\n return 'top-end';\n default:\n return placement;\n }\n}\nfunction resolveAnchorEl(anchorEl) {\n return typeof anchorEl === 'function' ? anchorEl() : anchorEl;\n}\nfunction isHTMLElement(element) {\n return element.nodeType !== undefined;\n}\nfunction isVirtualElement(element) {\n return !isHTMLElement(element);\n}\nconst useUtilityClasses = () => {\n const slots = {\n root: ['root']\n };\n return composeClasses(slots, useClassNamesOverride(getPopperUtilityClass));\n};\nconst defaultPopperOptions = {};\nconst PopperTooltip = /*#__PURE__*/React.forwardRef(function PopperTooltip(props, forwardedRef) {\n var _slots$root;\n const {\n anchorEl,\n children,\n direction,\n disablePortal,\n modifiers,\n open,\n placement: initialPlacement,\n popperOptions,\n popperRef: popperRefProp,\n slotProps = {},\n slots = {},\n TransitionProps\n // @ts-ignore internal logic\n // prevent from spreading to DOM, it can come from the parent component e.g. Select.\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const tooltipRef = React.useRef(null);\n const ownRef = useForkRef(tooltipRef, forwardedRef);\n const popperRef = React.useRef(null);\n const handlePopperRef = useForkRef(popperRef, popperRefProp);\n const handlePopperRefRef = React.useRef(handlePopperRef);\n useEnhancedEffect(() => {\n handlePopperRefRef.current = handlePopperRef;\n }, [handlePopperRef]);\n React.useImperativeHandle(popperRefProp, () => popperRef.current, []);\n const rtlPlacement = flipPlacement(initialPlacement, direction);\n /**\n * placement initialized from prop but can change during lifetime if modifiers.flip.\n * modifiers.flip is essentially a flip for controlled/uncontrolled behavior\n */\n const [placement, setPlacement] = React.useState(rtlPlacement);\n const [resolvedAnchorElement, setResolvedAnchorElement] = React.useState(resolveAnchorEl(anchorEl));\n React.useEffect(() => {\n if (popperRef.current) {\n popperRef.current.forceUpdate();\n }\n });\n React.useEffect(() => {\n if (anchorEl) {\n setResolvedAnchorElement(resolveAnchorEl(anchorEl));\n }\n }, [anchorEl]);\n useEnhancedEffect(() => {\n if (!resolvedAnchorElement || !open) {\n return undefined;\n }\n const handlePopperUpdate = data => {\n setPlacement(data.placement);\n };\n if (process.env.NODE_ENV !== 'production') {\n if (resolvedAnchorElement && isHTMLElement(resolvedAnchorElement) && resolvedAnchorElement.nodeType === 1) {\n const box = resolvedAnchorElement.getBoundingClientRect();\n if (process.env.NODE_ENV !== 'test' && box.top === 0 && box.left === 0 && box.right === 0 && box.bottom === 0) {\n console.warn(['MUI: The `anchorEl` prop provided to the component is invalid.', 'The anchor element should be part of the document layout.', \"Make sure the element is present in the document or that it's not display none.\"].join('\\n'));\n }\n }\n }\n let popperModifiers = [{\n name: 'preventOverflow',\n options: {\n altBoundary: disablePortal\n }\n }, {\n name: 'flip',\n options: {\n altBoundary: disablePortal\n }\n }, {\n name: 'onUpdate',\n enabled: true,\n phase: 'afterWrite',\n fn: ({\n state\n }) => {\n handlePopperUpdate(state);\n }\n }];\n if (modifiers != null) {\n popperModifiers = popperModifiers.concat(modifiers);\n }\n if (popperOptions && popperOptions.modifiers != null) {\n popperModifiers = popperModifiers.concat(popperOptions.modifiers);\n }\n const popper = createPopper(resolvedAnchorElement, tooltipRef.current, _extends({\n placement: rtlPlacement\n }, popperOptions, {\n modifiers: popperModifiers\n }));\n handlePopperRefRef.current(popper);\n return () => {\n popper.destroy();\n handlePopperRefRef.current(null);\n };\n }, [resolvedAnchorElement, disablePortal, modifiers, open, popperOptions, rtlPlacement]);\n const childProps = {\n placement: placement\n };\n if (TransitionProps !== null) {\n childProps.TransitionProps = TransitionProps;\n }\n const classes = useUtilityClasses();\n const Root = (_slots$root = slots.root) != null ? _slots$root : 'div';\n const rootProps = useSlotProps({\n elementType: Root,\n externalSlotProps: slotProps.root,\n externalForwardedProps: other,\n additionalProps: {\n role: 'tooltip',\n ref: ownRef\n },\n ownerState: props,\n className: classes.root\n });\n return /*#__PURE__*/_jsx(Root, _extends({}, rootProps, {\n children: typeof children === 'function' ? children(childProps) : children\n }));\n});\n\n/**\n * Poppers rely on the 3rd party library [Popper.js](https://popper.js.org/docs/v2/) for positioning.\n *\n * Demos:\n *\n * - [Popper](https://mui.com/base-ui/react-popper/)\n *\n * API:\n *\n * - [Popper API](https://mui.com/base-ui/react-popper/components-api/#popper)\n */\nconst Popper = /*#__PURE__*/React.forwardRef(function Popper(props, forwardedRef) {\n const {\n anchorEl,\n children,\n container: containerProp,\n direction = 'ltr',\n disablePortal = false,\n keepMounted = false,\n modifiers,\n open,\n placement = 'bottom',\n popperOptions = defaultPopperOptions,\n popperRef,\n style,\n transition = false,\n slotProps = {},\n slots = {}\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded2);\n const [exited, setExited] = React.useState(true);\n const handleEnter = () => {\n setExited(false);\n };\n const handleExited = () => {\n setExited(true);\n };\n if (!keepMounted && !open && (!transition || exited)) {\n return null;\n }\n\n // If the container prop is provided, use that\n // If the anchorEl prop is provided, use its parent body element as the container\n // If neither are provided let the Modal take care of choosing the container\n let container;\n if (containerProp) {\n container = containerProp;\n } else if (anchorEl) {\n const resolvedAnchorEl = resolveAnchorEl(anchorEl);\n container = resolvedAnchorEl && isHTMLElement(resolvedAnchorEl) ? ownerDocument(resolvedAnchorEl).body : ownerDocument(null).body;\n }\n const display = !open && keepMounted && (!transition || exited) ? 'none' : undefined;\n const transitionProps = transition ? {\n in: open,\n onEnter: handleEnter,\n onExited: handleExited\n } : undefined;\n return /*#__PURE__*/_jsx(Portal, {\n disablePortal: disablePortal,\n container: container,\n children: /*#__PURE__*/_jsx(PopperTooltip, _extends({\n anchorEl: anchorEl,\n direction: direction,\n disablePortal: disablePortal,\n modifiers: modifiers,\n ref: forwardedRef,\n open: transition ? !exited : open,\n placement: placement,\n popperOptions: popperOptions,\n popperRef: popperRef,\n slotProps: slotProps,\n slots: slots\n }, other, {\n style: _extends({\n // Prevents scroll issue, waiting for Popper.js to add this style once initiated.\n position: 'fixed',\n // Fix Popper.js display issue\n top: 0,\n left: 0,\n display\n }, style),\n TransitionProps: transitionProps,\n children: children\n }))\n });\n});\nprocess.env.NODE_ENV !== \"production\" ? Popper.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * An HTML element, [virtualElement](https://popper.js.org/docs/v2/virtual-elements/),\n * or a function that returns either.\n * It's used to set the position of the popper.\n * The return value will passed as the reference object of the Popper instance.\n */\n anchorEl: chainPropTypes(PropTypes.oneOfType([HTMLElementType, PropTypes.object, PropTypes.func]), props => {\n if (props.open) {\n const resolvedAnchorEl = resolveAnchorEl(props.anchorEl);\n if (resolvedAnchorEl && isHTMLElement(resolvedAnchorEl) && resolvedAnchorEl.nodeType === 1) {\n const box = resolvedAnchorEl.getBoundingClientRect();\n if (process.env.NODE_ENV !== 'test' && box.top === 0 && box.left === 0 && box.right === 0 && box.bottom === 0) {\n return new Error(['MUI: The `anchorEl` prop provided to the component is invalid.', 'The anchor element should be part of the document layout.', \"Make sure the element is present in the document or that it's not display none.\"].join('\\n'));\n }\n } else if (!resolvedAnchorEl || typeof resolvedAnchorEl.getBoundingClientRect !== 'function' || isVirtualElement(resolvedAnchorEl) && resolvedAnchorEl.contextElement != null && resolvedAnchorEl.contextElement.nodeType !== 1) {\n return new Error(['MUI: The `anchorEl` prop provided to the component is invalid.', 'It should be an HTML element instance or a virtualElement ', '(https://popper.js.org/docs/v2/virtual-elements/).'].join('\\n'));\n }\n }\n return null;\n }),\n /**\n * Popper render function or node.\n */\n children: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.node, PropTypes.func]),\n /**\n * An HTML element or function that returns one.\n * The `container` will have the portal children appended to it.\n *\n * You can also provide a callback, which is called in a React layout effect.\n * This lets you set the container from a ref, and also makes server-side rendering possible.\n *\n * By default, it uses the body of the top-level document object,\n * so it's simply `document.body` most of the time.\n */\n container: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.func]),\n /**\n * Direction of the text.\n * @default 'ltr'\n */\n direction: PropTypes.oneOf(['ltr', 'rtl']),\n /**\n * The `children` will be under the DOM hierarchy of the parent component.\n * @default false\n */\n disablePortal: PropTypes.bool,\n /**\n * Always keep the children in the DOM.\n * This prop can be useful in SEO situation or\n * when you want to maximize the responsiveness of the Popper.\n * @default false\n */\n keepMounted: PropTypes.bool,\n /**\n * Popper.js is based on a \"plugin-like\" architecture,\n * most of its features are fully encapsulated \"modifiers\".\n *\n * A modifier is a function that is called each time Popper.js needs to\n * compute the position of the popper.\n * For this reason, modifiers should be very performant to avoid bottlenecks.\n * To learn how to create a modifier, [read the modifiers documentation](https://popper.js.org/docs/v2/modifiers/).\n */\n modifiers: PropTypes.arrayOf(PropTypes.shape({\n data: PropTypes.object,\n effect: PropTypes.func,\n enabled: PropTypes.bool,\n fn: PropTypes.func,\n name: PropTypes.any,\n options: PropTypes.object,\n phase: PropTypes.oneOf(['afterMain', 'afterRead', 'afterWrite', 'beforeMain', 'beforeRead', 'beforeWrite', 'main', 'read', 'write']),\n requires: PropTypes.arrayOf(PropTypes.string),\n requiresIfExists: PropTypes.arrayOf(PropTypes.string)\n })),\n /**\n * If `true`, the component is shown.\n */\n open: PropTypes.bool.isRequired,\n /**\n * Popper placement.\n * @default 'bottom'\n */\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n /**\n * Options provided to the [`Popper.js`](https://popper.js.org/docs/v2/constructors/#options) instance.\n * @default {}\n */\n popperOptions: PropTypes.shape({\n modifiers: PropTypes.array,\n onFirstUpdate: PropTypes.func,\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n strategy: PropTypes.oneOf(['absolute', 'fixed'])\n }),\n /**\n * A ref that points to the used popper instance.\n */\n popperRef: refType,\n /**\n * The props used for each slot inside the Popper.\n * @default {}\n */\n slotProps: PropTypes.shape({\n root: PropTypes.oneOfType([PropTypes.func, PropTypes.object])\n }),\n /**\n * The components used for each slot inside the Popper.\n * Either a string to use a HTML element or a component.\n * @default {}\n */\n slots: PropTypes.shape({\n root: PropTypes.elementType\n }),\n /**\n * Help supporting a react-transition-group/Transition component.\n * @default false\n */\n transition: PropTypes.bool\n} : void 0;\nexport { Popper };","'use client';\n\nimport * as React from 'react';\nimport { useTheme as useThemeSystem } from '@mui/system';\nimport defaultTheme from './defaultTheme';\nimport THEME_ID from './identifier';\nexport default function useTheme() {\n const theme = useThemeSystem(defaultTheme);\n if (process.env.NODE_ENV !== 'production') {\n // eslint-disable-next-line react-hooks/rules-of-hooks\n React.useDebugValue(theme);\n }\n return theme[THEME_ID] || theme;\n}","export default function _setPrototypeOf(o, p) {\n _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function _setPrototypeOf(o, p) {\n o.__proto__ = p;\n return o;\n };\n return _setPrototypeOf(o, p);\n}","import setPrototypeOf from \"./setPrototypeOf.js\";\nexport default function _inheritsLoose(subClass, superClass) {\n subClass.prototype = Object.create(superClass.prototype);\n subClass.prototype.constructor = subClass;\n setPrototypeOf(subClass, superClass);\n}","export default {\n disabled: false\n};","import PropTypes from 'prop-types';\nexport var timeoutsShape = process.env.NODE_ENV !== 'production' ? PropTypes.oneOfType([PropTypes.number, PropTypes.shape({\n enter: PropTypes.number,\n exit: PropTypes.number,\n appear: PropTypes.number\n}).isRequired]) : null;\nexport var classNamesShape = process.env.NODE_ENV !== 'production' ? PropTypes.oneOfType([PropTypes.string, PropTypes.shape({\n enter: PropTypes.string,\n exit: PropTypes.string,\n active: PropTypes.string\n}), PropTypes.shape({\n enter: PropTypes.string,\n enterDone: PropTypes.string,\n enterActive: PropTypes.string,\n exit: PropTypes.string,\n exitDone: PropTypes.string,\n exitActive: PropTypes.string\n})]) : null;","import React from 'react';\nexport default React.createContext(null);","export var forceReflow = function forceReflow(node) {\n return node.scrollTop;\n};","import _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _inheritsLoose from \"@babel/runtime/helpers/esm/inheritsLoose\";\nimport PropTypes from 'prop-types';\nimport React from 'react';\nimport ReactDOM from 'react-dom';\nimport config from './config';\nimport { timeoutsShape } from './utils/PropTypes';\nimport TransitionGroupContext from './TransitionGroupContext';\nimport { forceReflow } from './utils/reflow';\nexport var UNMOUNTED = 'unmounted';\nexport var EXITED = 'exited';\nexport var ENTERING = 'entering';\nexport var ENTERED = 'entered';\nexport var EXITING = 'exiting';\n/**\n * The Transition component lets you describe a transition from one component\n * state to another _over time_ with a simple declarative API. Most commonly\n * it's used to animate the mounting and unmounting of a component, but can also\n * be used to describe in-place transition states as well.\n *\n * ---\n *\n * **Note**: `Transition` is a platform-agnostic base component. If you're using\n * transitions in CSS, you'll probably want to use\n * [`CSSTransition`](https://reactcommunity.org/react-transition-group/css-transition)\n * instead. It inherits all the features of `Transition`, but contains\n * additional features necessary to play nice with CSS transitions (hence the\n * name of the component).\n *\n * ---\n *\n * By default the `Transition` component does not alter the behavior of the\n * component it renders, it only tracks \"enter\" and \"exit\" states for the\n * components. It's up to you to give meaning and effect to those states. For\n * example we can add styles to a component when it enters or exits:\n *\n * ```jsx\n * import { Transition } from 'react-transition-group';\n *\n * const duration = 300;\n *\n * const defaultStyle = {\n * transition: `opacity ${duration}ms ease-in-out`,\n * opacity: 0,\n * }\n *\n * const transitionStyles = {\n * entering: { opacity: 1 },\n * entered: { opacity: 1 },\n * exiting: { opacity: 0 },\n * exited: { opacity: 0 },\n * };\n *\n * const Fade = ({ in: inProp }) => (\n * \n * {state => (\n *
    \n * I'm a fade Transition!\n *
    \n * )}\n *
    \n * );\n * ```\n *\n * There are 4 main states a Transition can be in:\n * - `'entering'`\n * - `'entered'`\n * - `'exiting'`\n * - `'exited'`\n *\n * Transition state is toggled via the `in` prop. When `true` the component\n * begins the \"Enter\" stage. During this stage, the component will shift from\n * its current transition state, to `'entering'` for the duration of the\n * transition and then to the `'entered'` stage once it's complete. Let's take\n * the following example (we'll use the\n * [useState](https://reactjs.org/docs/hooks-reference.html#usestate) hook):\n *\n * ```jsx\n * function App() {\n * const [inProp, setInProp] = useState(false);\n * return (\n *
    \n * \n * {state => (\n * // ...\n * )}\n * \n * \n *
    \n * );\n * }\n * ```\n *\n * When the button is clicked the component will shift to the `'entering'` state\n * and stay there for 500ms (the value of `timeout`) before it finally switches\n * to `'entered'`.\n *\n * When `in` is `false` the same thing happens except the state moves from\n * `'exiting'` to `'exited'`.\n */\n\nvar Transition = /*#__PURE__*/function (_React$Component) {\n _inheritsLoose(Transition, _React$Component);\n\n function Transition(props, context) {\n var _this;\n\n _this = _React$Component.call(this, props, context) || this;\n var parentGroup = context; // In the context of a TransitionGroup all enters are really appears\n\n var appear = parentGroup && !parentGroup.isMounting ? props.enter : props.appear;\n var initialStatus;\n _this.appearStatus = null;\n\n if (props.in) {\n if (appear) {\n initialStatus = EXITED;\n _this.appearStatus = ENTERING;\n } else {\n initialStatus = ENTERED;\n }\n } else {\n if (props.unmountOnExit || props.mountOnEnter) {\n initialStatus = UNMOUNTED;\n } else {\n initialStatus = EXITED;\n }\n }\n\n _this.state = {\n status: initialStatus\n };\n _this.nextCallback = null;\n return _this;\n }\n\n Transition.getDerivedStateFromProps = function getDerivedStateFromProps(_ref, prevState) {\n var nextIn = _ref.in;\n\n if (nextIn && prevState.status === UNMOUNTED) {\n return {\n status: EXITED\n };\n }\n\n return null;\n } // getSnapshotBeforeUpdate(prevProps) {\n // let nextStatus = null\n // if (prevProps !== this.props) {\n // const { status } = this.state\n // if (this.props.in) {\n // if (status !== ENTERING && status !== ENTERED) {\n // nextStatus = ENTERING\n // }\n // } else {\n // if (status === ENTERING || status === ENTERED) {\n // nextStatus = EXITING\n // }\n // }\n // }\n // return { nextStatus }\n // }\n ;\n\n var _proto = Transition.prototype;\n\n _proto.componentDidMount = function componentDidMount() {\n this.updateStatus(true, this.appearStatus);\n };\n\n _proto.componentDidUpdate = function componentDidUpdate(prevProps) {\n var nextStatus = null;\n\n if (prevProps !== this.props) {\n var status = this.state.status;\n\n if (this.props.in) {\n if (status !== ENTERING && status !== ENTERED) {\n nextStatus = ENTERING;\n }\n } else {\n if (status === ENTERING || status === ENTERED) {\n nextStatus = EXITING;\n }\n }\n }\n\n this.updateStatus(false, nextStatus);\n };\n\n _proto.componentWillUnmount = function componentWillUnmount() {\n this.cancelNextCallback();\n };\n\n _proto.getTimeouts = function getTimeouts() {\n var timeout = this.props.timeout;\n var exit, enter, appear;\n exit = enter = appear = timeout;\n\n if (timeout != null && typeof timeout !== 'number') {\n exit = timeout.exit;\n enter = timeout.enter; // TODO: remove fallback for next major\n\n appear = timeout.appear !== undefined ? timeout.appear : enter;\n }\n\n return {\n exit: exit,\n enter: enter,\n appear: appear\n };\n };\n\n _proto.updateStatus = function updateStatus(mounting, nextStatus) {\n if (mounting === void 0) {\n mounting = false;\n }\n\n if (nextStatus !== null) {\n // nextStatus will always be ENTERING or EXITING.\n this.cancelNextCallback();\n\n if (nextStatus === ENTERING) {\n if (this.props.unmountOnExit || this.props.mountOnEnter) {\n var node = this.props.nodeRef ? this.props.nodeRef.current : ReactDOM.findDOMNode(this); // https://github.com/reactjs/react-transition-group/pull/749\n // With unmountOnExit or mountOnEnter, the enter animation should happen at the transition between `exited` and `entering`.\n // To make the animation happen, we have to separate each rendering and avoid being processed as batched.\n\n if (node) forceReflow(node);\n }\n\n this.performEnter(mounting);\n } else {\n this.performExit();\n }\n } else if (this.props.unmountOnExit && this.state.status === EXITED) {\n this.setState({\n status: UNMOUNTED\n });\n }\n };\n\n _proto.performEnter = function performEnter(mounting) {\n var _this2 = this;\n\n var enter = this.props.enter;\n var appearing = this.context ? this.context.isMounting : mounting;\n\n var _ref2 = this.props.nodeRef ? [appearing] : [ReactDOM.findDOMNode(this), appearing],\n maybeNode = _ref2[0],\n maybeAppearing = _ref2[1];\n\n var timeouts = this.getTimeouts();\n var enterTimeout = appearing ? timeouts.appear : timeouts.enter; // no enter animation skip right to ENTERED\n // if we are mounting and running this it means appear _must_ be set\n\n if (!mounting && !enter || config.disabled) {\n this.safeSetState({\n status: ENTERED\n }, function () {\n _this2.props.onEntered(maybeNode);\n });\n return;\n }\n\n this.props.onEnter(maybeNode, maybeAppearing);\n this.safeSetState({\n status: ENTERING\n }, function () {\n _this2.props.onEntering(maybeNode, maybeAppearing);\n\n _this2.onTransitionEnd(enterTimeout, function () {\n _this2.safeSetState({\n status: ENTERED\n }, function () {\n _this2.props.onEntered(maybeNode, maybeAppearing);\n });\n });\n });\n };\n\n _proto.performExit = function performExit() {\n var _this3 = this;\n\n var exit = this.props.exit;\n var timeouts = this.getTimeouts();\n var maybeNode = this.props.nodeRef ? undefined : ReactDOM.findDOMNode(this); // no exit animation skip right to EXITED\n\n if (!exit || config.disabled) {\n this.safeSetState({\n status: EXITED\n }, function () {\n _this3.props.onExited(maybeNode);\n });\n return;\n }\n\n this.props.onExit(maybeNode);\n this.safeSetState({\n status: EXITING\n }, function () {\n _this3.props.onExiting(maybeNode);\n\n _this3.onTransitionEnd(timeouts.exit, function () {\n _this3.safeSetState({\n status: EXITED\n }, function () {\n _this3.props.onExited(maybeNode);\n });\n });\n });\n };\n\n _proto.cancelNextCallback = function cancelNextCallback() {\n if (this.nextCallback !== null) {\n this.nextCallback.cancel();\n this.nextCallback = null;\n }\n };\n\n _proto.safeSetState = function safeSetState(nextState, callback) {\n // This shouldn't be necessary, but there are weird race conditions with\n // setState callbacks and unmounting in testing, so always make sure that\n // we can cancel any pending setState callbacks after we unmount.\n callback = this.setNextCallback(callback);\n this.setState(nextState, callback);\n };\n\n _proto.setNextCallback = function setNextCallback(callback) {\n var _this4 = this;\n\n var active = true;\n\n this.nextCallback = function (event) {\n if (active) {\n active = false;\n _this4.nextCallback = null;\n callback(event);\n }\n };\n\n this.nextCallback.cancel = function () {\n active = false;\n };\n\n return this.nextCallback;\n };\n\n _proto.onTransitionEnd = function onTransitionEnd(timeout, handler) {\n this.setNextCallback(handler);\n var node = this.props.nodeRef ? this.props.nodeRef.current : ReactDOM.findDOMNode(this);\n var doesNotHaveTimeoutOrListener = timeout == null && !this.props.addEndListener;\n\n if (!node || doesNotHaveTimeoutOrListener) {\n setTimeout(this.nextCallback, 0);\n return;\n }\n\n if (this.props.addEndListener) {\n var _ref3 = this.props.nodeRef ? [this.nextCallback] : [node, this.nextCallback],\n maybeNode = _ref3[0],\n maybeNextCallback = _ref3[1];\n\n this.props.addEndListener(maybeNode, maybeNextCallback);\n }\n\n if (timeout != null) {\n setTimeout(this.nextCallback, timeout);\n }\n };\n\n _proto.render = function render() {\n var status = this.state.status;\n\n if (status === UNMOUNTED) {\n return null;\n }\n\n var _this$props = this.props,\n children = _this$props.children,\n _in = _this$props.in,\n _mountOnEnter = _this$props.mountOnEnter,\n _unmountOnExit = _this$props.unmountOnExit,\n _appear = _this$props.appear,\n _enter = _this$props.enter,\n _exit = _this$props.exit,\n _timeout = _this$props.timeout,\n _addEndListener = _this$props.addEndListener,\n _onEnter = _this$props.onEnter,\n _onEntering = _this$props.onEntering,\n _onEntered = _this$props.onEntered,\n _onExit = _this$props.onExit,\n _onExiting = _this$props.onExiting,\n _onExited = _this$props.onExited,\n _nodeRef = _this$props.nodeRef,\n childProps = _objectWithoutPropertiesLoose(_this$props, [\"children\", \"in\", \"mountOnEnter\", \"unmountOnExit\", \"appear\", \"enter\", \"exit\", \"timeout\", \"addEndListener\", \"onEnter\", \"onEntering\", \"onEntered\", \"onExit\", \"onExiting\", \"onExited\", \"nodeRef\"]);\n\n return (\n /*#__PURE__*/\n // allows for nested Transitions\n React.createElement(TransitionGroupContext.Provider, {\n value: null\n }, typeof children === 'function' ? children(status, childProps) : React.cloneElement(React.Children.only(children), childProps))\n );\n };\n\n return Transition;\n}(React.Component);\n\nTransition.contextType = TransitionGroupContext;\nTransition.propTypes = process.env.NODE_ENV !== \"production\" ? {\n /**\n * A React reference to DOM element that need to transition:\n * https://stackoverflow.com/a/51127130/4671932\n *\n * - When `nodeRef` prop is used, `node` is not passed to callback functions\n * (e.g. `onEnter`) because user already has direct access to the node.\n * - When changing `key` prop of `Transition` in a `TransitionGroup` a new\n * `nodeRef` need to be provided to `Transition` with changed `key` prop\n * (see\n * [test/CSSTransition-test.js](https://github.com/reactjs/react-transition-group/blob/13435f897b3ab71f6e19d724f145596f5910581c/test/CSSTransition-test.js#L362-L437)).\n */\n nodeRef: PropTypes.shape({\n current: typeof Element === 'undefined' ? PropTypes.any : function (propValue, key, componentName, location, propFullName, secret) {\n var value = propValue[key];\n return PropTypes.instanceOf(value && 'ownerDocument' in value ? value.ownerDocument.defaultView.Element : Element)(propValue, key, componentName, location, propFullName, secret);\n }\n }),\n\n /**\n * A `function` child can be used instead of a React element. This function is\n * called with the current transition status (`'entering'`, `'entered'`,\n * `'exiting'`, `'exited'`), which can be used to apply context\n * specific props to a component.\n *\n * ```jsx\n * \n * {state => (\n * \n * )}\n * \n * ```\n */\n children: PropTypes.oneOfType([PropTypes.func.isRequired, PropTypes.element.isRequired]).isRequired,\n\n /**\n * Show the component; triggers the enter or exit states\n */\n in: PropTypes.bool,\n\n /**\n * By default the child component is mounted immediately along with\n * the parent `Transition` component. If you want to \"lazy mount\" the component on the\n * first `in={true}` you can set `mountOnEnter`. After the first enter transition the component will stay\n * mounted, even on \"exited\", unless you also specify `unmountOnExit`.\n */\n mountOnEnter: PropTypes.bool,\n\n /**\n * By default the child component stays mounted after it reaches the `'exited'` state.\n * Set `unmountOnExit` if you'd prefer to unmount the component after it finishes exiting.\n */\n unmountOnExit: PropTypes.bool,\n\n /**\n * By default the child component does not perform the enter transition when\n * it first mounts, regardless of the value of `in`. If you want this\n * behavior, set both `appear` and `in` to `true`.\n *\n * > **Note**: there are no special appear states like `appearing`/`appeared`, this prop\n * > only adds an additional enter transition. However, in the\n * > `` component that first enter transition does result in\n * > additional `.appear-*` classes, that way you can choose to style it\n * > differently.\n */\n appear: PropTypes.bool,\n\n /**\n * Enable or disable enter transitions.\n */\n enter: PropTypes.bool,\n\n /**\n * Enable or disable exit transitions.\n */\n exit: PropTypes.bool,\n\n /**\n * The duration of the transition, in milliseconds.\n * Required unless `addEndListener` is provided.\n *\n * You may specify a single timeout for all transitions:\n *\n * ```jsx\n * timeout={500}\n * ```\n *\n * or individually:\n *\n * ```jsx\n * timeout={{\n * appear: 500,\n * enter: 300,\n * exit: 500,\n * }}\n * ```\n *\n * - `appear` defaults to the value of `enter`\n * - `enter` defaults to `0`\n * - `exit` defaults to `0`\n *\n * @type {number | { enter?: number, exit?: number, appear?: number }}\n */\n timeout: function timeout(props) {\n var pt = timeoutsShape;\n if (!props.addEndListener) pt = pt.isRequired;\n\n for (var _len = arguments.length, args = new Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) {\n args[_key - 1] = arguments[_key];\n }\n\n return pt.apply(void 0, [props].concat(args));\n },\n\n /**\n * Add a custom transition end trigger. Called with the transitioning\n * DOM node and a `done` callback. Allows for more fine grained transition end\n * logic. Timeouts are still used as a fallback if provided.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * ```jsx\n * addEndListener={(node, done) => {\n * // use the css transitionend event to mark the finish of a transition\n * node.addEventListener('transitionend', done, false);\n * }}\n * ```\n */\n addEndListener: PropTypes.func,\n\n /**\n * Callback fired before the \"entering\" status is applied. An extra parameter\n * `isAppearing` is supplied to indicate if the enter stage is occurring on the initial mount\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement, isAppearing: bool) -> void\n */\n onEnter: PropTypes.func,\n\n /**\n * Callback fired after the \"entering\" status is applied. An extra parameter\n * `isAppearing` is supplied to indicate if the enter stage is occurring on the initial mount\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement, isAppearing: bool)\n */\n onEntering: PropTypes.func,\n\n /**\n * Callback fired after the \"entered\" status is applied. An extra parameter\n * `isAppearing` is supplied to indicate if the enter stage is occurring on the initial mount\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement, isAppearing: bool) -> void\n */\n onEntered: PropTypes.func,\n\n /**\n * Callback fired before the \"exiting\" status is applied.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement) -> void\n */\n onExit: PropTypes.func,\n\n /**\n * Callback fired after the \"exiting\" status is applied.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement) -> void\n */\n onExiting: PropTypes.func,\n\n /**\n * Callback fired after the \"exited\" status is applied.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed\n *\n * @type Function(node: HtmlElement) -> void\n */\n onExited: PropTypes.func\n} : {}; // Name the function so it is clearer in the documentation\n\nfunction noop() {}\n\nTransition.defaultProps = {\n in: false,\n mountOnEnter: false,\n unmountOnExit: false,\n appear: false,\n enter: true,\n exit: true,\n onEnter: noop,\n onEntering: noop,\n onEntered: noop,\n onExit: noop,\n onExiting: noop,\n onExited: noop\n};\nTransition.UNMOUNTED = UNMOUNTED;\nTransition.EXITED = EXITED;\nTransition.ENTERING = ENTERING;\nTransition.ENTERED = ENTERED;\nTransition.EXITING = EXITING;\nexport default Transition;","export const reflow = node => node.scrollTop;\nexport function getTransitionProps(props, options) {\n var _style$transitionDura, _style$transitionTimi;\n const {\n timeout,\n easing,\n style = {}\n } = props;\n return {\n duration: (_style$transitionDura = style.transitionDuration) != null ? _style$transitionDura : typeof timeout === 'number' ? timeout : timeout[options.mode] || 0,\n easing: (_style$transitionTimi = style.transitionTimingFunction) != null ? _style$transitionTimi : typeof easing === 'object' ? easing[options.mode] : easing,\n delay: style.transitionDelay\n };\n}","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"addEndListener\", \"appear\", \"children\", \"easing\", \"in\", \"onEnter\", \"onEntered\", \"onEntering\", \"onExit\", \"onExited\", \"onExiting\", \"style\", \"timeout\", \"TransitionComponent\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport { elementAcceptingRef, unstable_useTimeout as useTimeout } from '@mui/utils';\nimport { Transition } from 'react-transition-group';\nimport useTheme from '../styles/useTheme';\nimport { getTransitionProps, reflow } from '../transitions/utils';\nimport useForkRef from '../utils/useForkRef';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nfunction getScale(value) {\n return `scale(${value}, ${value ** 2})`;\n}\nconst styles = {\n entering: {\n opacity: 1,\n transform: getScale(1)\n },\n entered: {\n opacity: 1,\n transform: 'none'\n }\n};\n\n/*\n TODO v6: remove\n Conditionally apply a workaround for the CSS transition bug in Safari 15.4 / WebKit browsers.\n */\nconst isWebKit154 = typeof navigator !== 'undefined' && /^((?!chrome|android).)*(safari|mobile)/i.test(navigator.userAgent) && /(os |version\\/)15(.|_)4/i.test(navigator.userAgent);\n\n/**\n * The Grow transition is used by the [Tooltip](/material-ui/react-tooltip/) and\n * [Popover](/material-ui/react-popover/) components.\n * It uses [react-transition-group](https://github.com/reactjs/react-transition-group) internally.\n */\nconst Grow = /*#__PURE__*/React.forwardRef(function Grow(props, ref) {\n const {\n addEndListener,\n appear = true,\n children,\n easing,\n in: inProp,\n onEnter,\n onEntered,\n onEntering,\n onExit,\n onExited,\n onExiting,\n style,\n timeout = 'auto',\n // eslint-disable-next-line react/prop-types\n TransitionComponent = Transition\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const timer = useTimeout();\n const autoTimeout = React.useRef();\n const theme = useTheme();\n const nodeRef = React.useRef(null);\n const handleRef = useForkRef(nodeRef, children.ref, ref);\n const normalizedTransitionCallback = callback => maybeIsAppearing => {\n if (callback) {\n const node = nodeRef.current;\n\n // onEnterXxx and onExitXxx callbacks have a different arguments.length value.\n if (maybeIsAppearing === undefined) {\n callback(node);\n } else {\n callback(node, maybeIsAppearing);\n }\n }\n };\n const handleEntering = normalizedTransitionCallback(onEntering);\n const handleEnter = normalizedTransitionCallback((node, isAppearing) => {\n reflow(node); // So the animation always start from the start.\n\n const {\n duration: transitionDuration,\n delay,\n easing: transitionTimingFunction\n } = getTransitionProps({\n style,\n timeout,\n easing\n }, {\n mode: 'enter'\n });\n let duration;\n if (timeout === 'auto') {\n duration = theme.transitions.getAutoHeightDuration(node.clientHeight);\n autoTimeout.current = duration;\n } else {\n duration = transitionDuration;\n }\n node.style.transition = [theme.transitions.create('opacity', {\n duration,\n delay\n }), theme.transitions.create('transform', {\n duration: isWebKit154 ? duration : duration * 0.666,\n delay,\n easing: transitionTimingFunction\n })].join(',');\n if (onEnter) {\n onEnter(node, isAppearing);\n }\n });\n const handleEntered = normalizedTransitionCallback(onEntered);\n const handleExiting = normalizedTransitionCallback(onExiting);\n const handleExit = normalizedTransitionCallback(node => {\n const {\n duration: transitionDuration,\n delay,\n easing: transitionTimingFunction\n } = getTransitionProps({\n style,\n timeout,\n easing\n }, {\n mode: 'exit'\n });\n let duration;\n if (timeout === 'auto') {\n duration = theme.transitions.getAutoHeightDuration(node.clientHeight);\n autoTimeout.current = duration;\n } else {\n duration = transitionDuration;\n }\n node.style.transition = [theme.transitions.create('opacity', {\n duration,\n delay\n }), theme.transitions.create('transform', {\n duration: isWebKit154 ? duration : duration * 0.666,\n delay: isWebKit154 ? delay : delay || duration * 0.333,\n easing: transitionTimingFunction\n })].join(',');\n node.style.opacity = 0;\n node.style.transform = getScale(0.75);\n if (onExit) {\n onExit(node);\n }\n });\n const handleExited = normalizedTransitionCallback(onExited);\n const handleAddEndListener = next => {\n if (timeout === 'auto') {\n timer.start(autoTimeout.current || 0, next);\n }\n if (addEndListener) {\n // Old call signature before `react-transition-group` implemented `nodeRef`\n addEndListener(nodeRef.current, next);\n }\n };\n return /*#__PURE__*/_jsx(TransitionComponent, _extends({\n appear: appear,\n in: inProp,\n nodeRef: nodeRef,\n onEnter: handleEnter,\n onEntered: handleEntered,\n onEntering: handleEntering,\n onExit: handleExit,\n onExited: handleExited,\n onExiting: handleExiting,\n addEndListener: handleAddEndListener,\n timeout: timeout === 'auto' ? null : timeout\n }, other, {\n children: (state, childProps) => {\n return /*#__PURE__*/React.cloneElement(children, _extends({\n style: _extends({\n opacity: 0,\n transform: getScale(0.75),\n visibility: state === 'exited' && !inProp ? 'hidden' : undefined\n }, styles[state], style, children.props.style),\n ref: handleRef\n }, childProps));\n }\n }));\n});\nprocess.env.NODE_ENV !== \"production\" ? Grow.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the d.ts file and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * Add a custom transition end trigger. Called with the transitioning DOM\n * node and a done callback. Allows for more fine grained transition end\n * logic. Note: Timeouts are still used as a fallback if provided.\n */\n addEndListener: PropTypes.func,\n /**\n * Perform the enter transition when it first mounts if `in` is also `true`.\n * Set this to `false` to disable this behavior.\n * @default true\n */\n appear: PropTypes.bool,\n /**\n * A single child content element.\n */\n children: elementAcceptingRef.isRequired,\n /**\n * The transition timing function.\n * You may specify a single easing or a object containing enter and exit values.\n */\n easing: PropTypes.oneOfType([PropTypes.shape({\n enter: PropTypes.string,\n exit: PropTypes.string\n }), PropTypes.string]),\n /**\n * If `true`, the component will transition in.\n */\n in: PropTypes.bool,\n /**\n * @ignore\n */\n onEnter: PropTypes.func,\n /**\n * @ignore\n */\n onEntered: PropTypes.func,\n /**\n * @ignore\n */\n onEntering: PropTypes.func,\n /**\n * @ignore\n */\n onExit: PropTypes.func,\n /**\n * @ignore\n */\n onExited: PropTypes.func,\n /**\n * @ignore\n */\n onExiting: PropTypes.func,\n /**\n * @ignore\n */\n style: PropTypes.object,\n /**\n * The duration for the transition, in milliseconds.\n * You may specify a single timeout for all transitions, or individually with an object.\n *\n * Set to 'auto' to automatically calculate transition time based on height.\n * @default 'auto'\n */\n timeout: PropTypes.oneOfType([PropTypes.oneOf(['auto']), PropTypes.number, PropTypes.shape({\n appear: PropTypes.number,\n enter: PropTypes.number,\n exit: PropTypes.number\n })])\n} : void 0;\nGrow.muiSupportAuto = true;\nexport default Grow;","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"anchorEl\", \"component\", \"components\", \"componentsProps\", \"container\", \"disablePortal\", \"keepMounted\", \"modifiers\", \"open\", \"placement\", \"popperOptions\", \"popperRef\", \"transition\", \"slots\", \"slotProps\"];\nimport { Popper as BasePopper } from '@mui/base/Popper';\nimport { useThemeWithoutDefault as useTheme } from '@mui/system';\nimport { HTMLElementType, refType } from '@mui/utils';\nimport PropTypes from 'prop-types';\nimport * as React from 'react';\nimport { styled, useThemeProps } from '../styles';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nconst PopperRoot = styled(BasePopper, {\n name: 'MuiPopper',\n slot: 'Root',\n overridesResolver: (props, styles) => styles.root\n})({});\n\n/**\n *\n * Demos:\n *\n * - [Autocomplete](https://mui.com/material-ui/react-autocomplete/)\n * - [Menu](https://mui.com/material-ui/react-menu/)\n * - [Popper](https://mui.com/material-ui/react-popper/)\n *\n * API:\n *\n * - [Popper API](https://mui.com/material-ui/api/popper/)\n */\nconst Popper = /*#__PURE__*/React.forwardRef(function Popper(inProps, ref) {\n var _slots$root;\n const theme = useTheme();\n const props = useThemeProps({\n props: inProps,\n name: 'MuiPopper'\n });\n const {\n anchorEl,\n component,\n components,\n componentsProps,\n container,\n disablePortal,\n keepMounted,\n modifiers,\n open,\n placement,\n popperOptions,\n popperRef,\n transition,\n slots,\n slotProps\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const RootComponent = (_slots$root = slots == null ? void 0 : slots.root) != null ? _slots$root : components == null ? void 0 : components.Root;\n const otherProps = _extends({\n anchorEl,\n container,\n disablePortal,\n keepMounted,\n modifiers,\n open,\n placement,\n popperOptions,\n popperRef,\n transition\n }, other);\n return /*#__PURE__*/_jsx(PopperRoot, _extends({\n as: component,\n direction: theme == null ? void 0 : theme.direction,\n slots: {\n root: RootComponent\n },\n slotProps: slotProps != null ? slotProps : componentsProps\n }, otherProps, {\n ref: ref\n }));\n});\nprocess.env.NODE_ENV !== \"production\" ? Popper.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * An HTML element, [virtualElement](https://popper.js.org/docs/v2/virtual-elements/),\n * or a function that returns either.\n * It's used to set the position of the popper.\n * The return value will passed as the reference object of the Popper instance.\n */\n anchorEl: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.object, PropTypes.func]),\n /**\n * Popper render function or node.\n */\n children: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.node, PropTypes.func]),\n /**\n * The component used for the root node.\n * Either a string to use a HTML element or a component.\n */\n component: PropTypes.elementType,\n /**\n * The components used for each slot inside the Popper.\n * Either a string to use a HTML element or a component.\n * @default {}\n */\n components: PropTypes.shape({\n Root: PropTypes.elementType\n }),\n /**\n * The props used for each slot inside the Popper.\n * @default {}\n */\n componentsProps: PropTypes.shape({\n root: PropTypes.oneOfType([PropTypes.func, PropTypes.object])\n }),\n /**\n * An HTML element or function that returns one.\n * The `container` will have the portal children appended to it.\n *\n * You can also provide a callback, which is called in a React layout effect.\n * This lets you set the container from a ref, and also makes server-side rendering possible.\n *\n * By default, it uses the body of the top-level document object,\n * so it's simply `document.body` most of the time.\n */\n container: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.func]),\n /**\n * The `children` will be under the DOM hierarchy of the parent component.\n * @default false\n */\n disablePortal: PropTypes.bool,\n /**\n * Always keep the children in the DOM.\n * This prop can be useful in SEO situation or\n * when you want to maximize the responsiveness of the Popper.\n * @default false\n */\n keepMounted: PropTypes.bool,\n /**\n * Popper.js is based on a \"plugin-like\" architecture,\n * most of its features are fully encapsulated \"modifiers\".\n *\n * A modifier is a function that is called each time Popper.js needs to\n * compute the position of the popper.\n * For this reason, modifiers should be very performant to avoid bottlenecks.\n * To learn how to create a modifier, [read the modifiers documentation](https://popper.js.org/docs/v2/modifiers/).\n */\n modifiers: PropTypes.arrayOf(PropTypes.shape({\n data: PropTypes.object,\n effect: PropTypes.func,\n enabled: PropTypes.bool,\n fn: PropTypes.func,\n name: PropTypes.any,\n options: PropTypes.object,\n phase: PropTypes.oneOf(['afterMain', 'afterRead', 'afterWrite', 'beforeMain', 'beforeRead', 'beforeWrite', 'main', 'read', 'write']),\n requires: PropTypes.arrayOf(PropTypes.string),\n requiresIfExists: PropTypes.arrayOf(PropTypes.string)\n })),\n /**\n * If `true`, the component is shown.\n */\n open: PropTypes.bool.isRequired,\n /**\n * Popper placement.\n * @default 'bottom'\n */\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n /**\n * Options provided to the [`Popper.js`](https://popper.js.org/docs/v2/constructors/#options) instance.\n * @default {}\n */\n popperOptions: PropTypes.shape({\n modifiers: PropTypes.array,\n onFirstUpdate: PropTypes.func,\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n strategy: PropTypes.oneOf(['absolute', 'fixed'])\n }),\n /**\n * A ref that points to the used popper instance.\n */\n popperRef: refType,\n /**\n * The props used for each slot inside the Popper.\n * @default {}\n */\n slotProps: PropTypes.shape({\n root: PropTypes.oneOfType([PropTypes.func, PropTypes.object])\n }),\n /**\n * The components used for each slot inside the Popper.\n * Either a string to use a HTML element or a component.\n * @default {}\n */\n slots: PropTypes.shape({\n root: PropTypes.elementType\n }),\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Help supporting a react-transition-group/Transition component.\n * @default false\n */\n transition: PropTypes.bool\n} : void 0;\nexport default Popper;","import generateUtilityClasses from '@mui/utils/generateUtilityClasses';\nimport generateUtilityClass from '@mui/utils/generateUtilityClass';\nexport function getTooltipUtilityClass(slot) {\n return generateUtilityClass('MuiTooltip', slot);\n}\nconst tooltipClasses = generateUtilityClasses('MuiTooltip', ['popper', 'popperInteractive', 'popperArrow', 'popperClose', 'tooltip', 'tooltipArrow', 'touch', 'tooltipPlacementLeft', 'tooltipPlacementRight', 'tooltipPlacementTop', 'tooltipPlacementBottom', 'arrow']);\nexport default tooltipClasses;","'use client';\n\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nconst _excluded = [\"arrow\", \"children\", \"classes\", \"components\", \"componentsProps\", \"describeChild\", \"disableFocusListener\", \"disableHoverListener\", \"disableInteractive\", \"disableTouchListener\", \"enterDelay\", \"enterNextDelay\", \"enterTouchDelay\", \"followCursor\", \"id\", \"leaveDelay\", \"leaveTouchDelay\", \"onClose\", \"onOpen\", \"open\", \"placement\", \"PopperComponent\", \"PopperProps\", \"slotProps\", \"slots\", \"title\", \"TransitionComponent\", \"TransitionProps\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport clsx from 'clsx';\nimport { elementAcceptingRef, unstable_useTimeout as useTimeout, unstable_Timeout as Timeout } from '@mui/utils';\nimport { unstable_composeClasses as composeClasses, appendOwnerState } from '@mui/base';\nimport { alpha } from '@mui/system';\nimport styled from '../styles/styled';\nimport useTheme from '../styles/useTheme';\nimport useThemeProps from '../styles/useThemeProps';\nimport capitalize from '../utils/capitalize';\nimport Grow from '../Grow';\nimport Popper from '../Popper';\nimport useEventCallback from '../utils/useEventCallback';\nimport useForkRef from '../utils/useForkRef';\nimport useId from '../utils/useId';\nimport useIsFocusVisible from '../utils/useIsFocusVisible';\nimport useControlled from '../utils/useControlled';\nimport tooltipClasses, { getTooltipUtilityClass } from './tooltipClasses';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nimport { jsxs as _jsxs } from \"react/jsx-runtime\";\nfunction round(value) {\n return Math.round(value * 1e5) / 1e5;\n}\nconst useUtilityClasses = ownerState => {\n const {\n classes,\n disableInteractive,\n arrow,\n touch,\n placement\n } = ownerState;\n const slots = {\n popper: ['popper', !disableInteractive && 'popperInteractive', arrow && 'popperArrow'],\n tooltip: ['tooltip', arrow && 'tooltipArrow', touch && 'touch', `tooltipPlacement${capitalize(placement.split('-')[0])}`],\n arrow: ['arrow']\n };\n return composeClasses(slots, getTooltipUtilityClass, classes);\n};\nconst TooltipPopper = styled(Popper, {\n name: 'MuiTooltip',\n slot: 'Popper',\n overridesResolver: (props, styles) => {\n const {\n ownerState\n } = props;\n return [styles.popper, !ownerState.disableInteractive && styles.popperInteractive, ownerState.arrow && styles.popperArrow, !ownerState.open && styles.popperClose];\n }\n})(({\n theme,\n ownerState,\n open\n}) => _extends({\n zIndex: (theme.vars || theme).zIndex.tooltip,\n pointerEvents: 'none'\n}, !ownerState.disableInteractive && {\n pointerEvents: 'auto'\n}, !open && {\n pointerEvents: 'none'\n}, ownerState.arrow && {\n [`&[data-popper-placement*=\"bottom\"] .${tooltipClasses.arrow}`]: {\n top: 0,\n marginTop: '-0.71em',\n '&::before': {\n transformOrigin: '0 100%'\n }\n },\n [`&[data-popper-placement*=\"top\"] .${tooltipClasses.arrow}`]: {\n bottom: 0,\n marginBottom: '-0.71em',\n '&::before': {\n transformOrigin: '100% 0'\n }\n },\n [`&[data-popper-placement*=\"right\"] .${tooltipClasses.arrow}`]: _extends({}, !ownerState.isRtl ? {\n left: 0,\n marginLeft: '-0.71em'\n } : {\n right: 0,\n marginRight: '-0.71em'\n }, {\n height: '1em',\n width: '0.71em',\n '&::before': {\n transformOrigin: '100% 100%'\n }\n }),\n [`&[data-popper-placement*=\"left\"] .${tooltipClasses.arrow}`]: _extends({}, !ownerState.isRtl ? {\n right: 0,\n marginRight: '-0.71em'\n } : {\n left: 0,\n marginLeft: '-0.71em'\n }, {\n height: '1em',\n width: '0.71em',\n '&::before': {\n transformOrigin: '0 0'\n }\n })\n}));\nconst TooltipTooltip = styled('div', {\n name: 'MuiTooltip',\n slot: 'Tooltip',\n overridesResolver: (props, styles) => {\n const {\n ownerState\n } = props;\n return [styles.tooltip, ownerState.touch && styles.touch, ownerState.arrow && styles.tooltipArrow, styles[`tooltipPlacement${capitalize(ownerState.placement.split('-')[0])}`]];\n }\n})(({\n theme,\n ownerState\n}) => _extends({\n backgroundColor: theme.vars ? theme.vars.palette.Tooltip.bg : alpha(theme.palette.grey[700], 0.92),\n borderRadius: (theme.vars || theme).shape.borderRadius,\n color: (theme.vars || theme).palette.common.white,\n fontFamily: theme.typography.fontFamily,\n padding: '4px 8px',\n fontSize: theme.typography.pxToRem(11),\n maxWidth: 300,\n margin: 2,\n wordWrap: 'break-word',\n fontWeight: theme.typography.fontWeightMedium\n}, ownerState.arrow && {\n position: 'relative',\n margin: 0\n}, ownerState.touch && {\n padding: '8px 16px',\n fontSize: theme.typography.pxToRem(14),\n lineHeight: `${round(16 / 14)}em`,\n fontWeight: theme.typography.fontWeightRegular\n}, {\n [`.${tooltipClasses.popper}[data-popper-placement*=\"left\"] &`]: _extends({\n transformOrigin: 'right center'\n }, !ownerState.isRtl ? _extends({\n marginRight: '14px'\n }, ownerState.touch && {\n marginRight: '24px'\n }) : _extends({\n marginLeft: '14px'\n }, ownerState.touch && {\n marginLeft: '24px'\n })),\n [`.${tooltipClasses.popper}[data-popper-placement*=\"right\"] &`]: _extends({\n transformOrigin: 'left center'\n }, !ownerState.isRtl ? _extends({\n marginLeft: '14px'\n }, ownerState.touch && {\n marginLeft: '24px'\n }) : _extends({\n marginRight: '14px'\n }, ownerState.touch && {\n marginRight: '24px'\n })),\n [`.${tooltipClasses.popper}[data-popper-placement*=\"top\"] &`]: _extends({\n transformOrigin: 'center bottom',\n marginBottom: '14px'\n }, ownerState.touch && {\n marginBottom: '24px'\n }),\n [`.${tooltipClasses.popper}[data-popper-placement*=\"bottom\"] &`]: _extends({\n transformOrigin: 'center top',\n marginTop: '14px'\n }, ownerState.touch && {\n marginTop: '24px'\n })\n}));\nconst TooltipArrow = styled('span', {\n name: 'MuiTooltip',\n slot: 'Arrow',\n overridesResolver: (props, styles) => styles.arrow\n})(({\n theme\n}) => ({\n overflow: 'hidden',\n position: 'absolute',\n width: '1em',\n height: '0.71em' /* = width / sqrt(2) = (length of the hypotenuse) */,\n boxSizing: 'border-box',\n color: theme.vars ? theme.vars.palette.Tooltip.bg : alpha(theme.palette.grey[700], 0.9),\n '&::before': {\n content: '\"\"',\n margin: 'auto',\n display: 'block',\n width: '100%',\n height: '100%',\n backgroundColor: 'currentColor',\n transform: 'rotate(45deg)'\n }\n}));\nlet hystersisOpen = false;\nconst hystersisTimer = new Timeout();\nlet cursorPosition = {\n x: 0,\n y: 0\n};\nexport function testReset() {\n hystersisOpen = false;\n hystersisTimer.clear();\n}\nfunction composeEventHandler(handler, eventHandler) {\n return event => {\n if (eventHandler) {\n eventHandler(event);\n }\n handler(event);\n };\n}\n\n// TODO v6: Remove PopperComponent, PopperProps, TransitionComponent and TransitionProps.\nconst Tooltip = /*#__PURE__*/React.forwardRef(function Tooltip(inProps, ref) {\n var _ref, _slots$popper, _ref2, _ref3, _slots$transition, _ref4, _slots$tooltip, _ref5, _slots$arrow, _slotProps$popper, _ref6, _slotProps$popper2, _slotProps$transition, _slotProps$tooltip, _ref7, _slotProps$tooltip2, _slotProps$arrow, _ref8, _slotProps$arrow2;\n const props = useThemeProps({\n props: inProps,\n name: 'MuiTooltip'\n });\n const {\n arrow = false,\n children: childrenProp,\n components = {},\n componentsProps = {},\n describeChild = false,\n disableFocusListener = false,\n disableHoverListener = false,\n disableInteractive: disableInteractiveProp = false,\n disableTouchListener = false,\n enterDelay = 100,\n enterNextDelay = 0,\n enterTouchDelay = 700,\n followCursor = false,\n id: idProp,\n leaveDelay = 0,\n leaveTouchDelay = 1500,\n onClose,\n onOpen,\n open: openProp,\n placement = 'bottom',\n PopperComponent: PopperComponentProp,\n PopperProps = {},\n slotProps = {},\n slots = {},\n title,\n TransitionComponent: TransitionComponentProp = Grow,\n TransitionProps\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n\n // to prevent runtime errors, developers will need to provide a child as a React element anyway.\n const children = /*#__PURE__*/React.isValidElement(childrenProp) ? childrenProp : /*#__PURE__*/_jsx(\"span\", {\n children: childrenProp\n });\n const theme = useTheme();\n const isRtl = theme.direction === 'rtl';\n const [childNode, setChildNode] = React.useState();\n const [arrowRef, setArrowRef] = React.useState(null);\n const ignoreNonTouchEvents = React.useRef(false);\n const disableInteractive = disableInteractiveProp || followCursor;\n const closeTimer = useTimeout();\n const enterTimer = useTimeout();\n const leaveTimer = useTimeout();\n const touchTimer = useTimeout();\n const [openState, setOpenState] = useControlled({\n controlled: openProp,\n default: false,\n name: 'Tooltip',\n state: 'open'\n });\n let open = openState;\n if (process.env.NODE_ENV !== 'production') {\n // eslint-disable-next-line react-hooks/rules-of-hooks\n const {\n current: isControlled\n } = React.useRef(openProp !== undefined);\n\n // eslint-disable-next-line react-hooks/rules-of-hooks\n React.useEffect(() => {\n if (childNode && childNode.disabled && !isControlled && title !== '' && childNode.tagName.toLowerCase() === 'button') {\n console.error(['MUI: You are providing a disabled `button` child to the Tooltip component.', 'A disabled element does not fire events.', \"Tooltip needs to listen to the child element's events to display the title.\", '', 'Add a simple wrapper element, such as a `span`.'].join('\\n'));\n }\n }, [title, childNode, isControlled]);\n }\n const id = useId(idProp);\n const prevUserSelect = React.useRef();\n const stopTouchInteraction = useEventCallback(() => {\n if (prevUserSelect.current !== undefined) {\n document.body.style.WebkitUserSelect = prevUserSelect.current;\n prevUserSelect.current = undefined;\n }\n touchTimer.clear();\n });\n React.useEffect(() => stopTouchInteraction, [stopTouchInteraction]);\n const handleOpen = event => {\n hystersisTimer.clear();\n hystersisOpen = true;\n\n // The mouseover event will trigger for every nested element in the tooltip.\n // We can skip rerendering when the tooltip is already open.\n // We are using the mouseover event instead of the mouseenter event to fix a hide/show issue.\n setOpenState(true);\n if (onOpen && !open) {\n onOpen(event);\n }\n };\n const handleClose = useEventCallback(\n /**\n * @param {React.SyntheticEvent | Event} event\n */\n event => {\n hystersisTimer.start(800 + leaveDelay, () => {\n hystersisOpen = false;\n });\n setOpenState(false);\n if (onClose && open) {\n onClose(event);\n }\n closeTimer.start(theme.transitions.duration.shortest, () => {\n ignoreNonTouchEvents.current = false;\n });\n });\n const handleEnter = event => {\n if (ignoreNonTouchEvents.current && event.type !== 'touchstart') {\n return;\n }\n\n // Remove the title ahead of time.\n // We don't want to wait for the next render commit.\n // We would risk displaying two tooltips at the same time (native + this one).\n if (childNode) {\n childNode.removeAttribute('title');\n }\n enterTimer.clear();\n leaveTimer.clear();\n if (enterDelay || hystersisOpen && enterNextDelay) {\n enterTimer.start(hystersisOpen ? enterNextDelay : enterDelay, () => {\n handleOpen(event);\n });\n } else {\n handleOpen(event);\n }\n };\n const handleLeave = event => {\n enterTimer.clear();\n leaveTimer.start(leaveDelay, () => {\n handleClose(event);\n });\n };\n const {\n isFocusVisibleRef,\n onBlur: handleBlurVisible,\n onFocus: handleFocusVisible,\n ref: focusVisibleRef\n } = useIsFocusVisible();\n // We don't necessarily care about the focusVisible state (which is safe to access via ref anyway).\n // We just need to re-render the Tooltip if the focus-visible state changes.\n const [, setChildIsFocusVisible] = React.useState(false);\n const handleBlur = event => {\n handleBlurVisible(event);\n if (isFocusVisibleRef.current === false) {\n setChildIsFocusVisible(false);\n handleLeave(event);\n }\n };\n const handleFocus = event => {\n // Workaround for https://github.com/facebook/react/issues/7769\n // The autoFocus of React might trigger the event before the componentDidMount.\n // We need to account for this eventuality.\n if (!childNode) {\n setChildNode(event.currentTarget);\n }\n handleFocusVisible(event);\n if (isFocusVisibleRef.current === true) {\n setChildIsFocusVisible(true);\n handleEnter(event);\n }\n };\n const detectTouchStart = event => {\n ignoreNonTouchEvents.current = true;\n const childrenProps = children.props;\n if (childrenProps.onTouchStart) {\n childrenProps.onTouchStart(event);\n }\n };\n const handleMouseOver = handleEnter;\n const handleMouseLeave = handleLeave;\n const handleTouchStart = event => {\n detectTouchStart(event);\n leaveTimer.clear();\n closeTimer.clear();\n stopTouchInteraction();\n prevUserSelect.current = document.body.style.WebkitUserSelect;\n // Prevent iOS text selection on long-tap.\n document.body.style.WebkitUserSelect = 'none';\n touchTimer.start(enterTouchDelay, () => {\n document.body.style.WebkitUserSelect = prevUserSelect.current;\n handleEnter(event);\n });\n };\n const handleTouchEnd = event => {\n if (children.props.onTouchEnd) {\n children.props.onTouchEnd(event);\n }\n stopTouchInteraction();\n leaveTimer.start(leaveTouchDelay, () => {\n handleClose(event);\n });\n };\n React.useEffect(() => {\n if (!open) {\n return undefined;\n }\n\n /**\n * @param {KeyboardEvent} nativeEvent\n */\n function handleKeyDown(nativeEvent) {\n // IE11, Edge (prior to using Bink?) use 'Esc'\n if (nativeEvent.key === 'Escape' || nativeEvent.key === 'Esc') {\n handleClose(nativeEvent);\n }\n }\n document.addEventListener('keydown', handleKeyDown);\n return () => {\n document.removeEventListener('keydown', handleKeyDown);\n };\n }, [handleClose, open]);\n const handleRef = useForkRef(children.ref, focusVisibleRef, setChildNode, ref);\n\n // There is no point in displaying an empty tooltip.\n // So we exclude all falsy values, except 0, which is valid.\n if (!title && title !== 0) {\n open = false;\n }\n const popperRef = React.useRef();\n const handleMouseMove = event => {\n const childrenProps = children.props;\n if (childrenProps.onMouseMove) {\n childrenProps.onMouseMove(event);\n }\n cursorPosition = {\n x: event.clientX,\n y: event.clientY\n };\n if (popperRef.current) {\n popperRef.current.update();\n }\n };\n const nameOrDescProps = {};\n const titleIsString = typeof title === 'string';\n if (describeChild) {\n nameOrDescProps.title = !open && titleIsString && !disableHoverListener ? title : null;\n nameOrDescProps['aria-describedby'] = open ? id : null;\n } else {\n nameOrDescProps['aria-label'] = titleIsString ? title : null;\n nameOrDescProps['aria-labelledby'] = open && !titleIsString ? id : null;\n }\n const childrenProps = _extends({}, nameOrDescProps, other, children.props, {\n className: clsx(other.className, children.props.className),\n onTouchStart: detectTouchStart,\n ref: handleRef\n }, followCursor ? {\n onMouseMove: handleMouseMove\n } : {});\n if (process.env.NODE_ENV !== 'production') {\n childrenProps['data-mui-internal-clone-element'] = true;\n\n // eslint-disable-next-line react-hooks/rules-of-hooks\n React.useEffect(() => {\n if (childNode && !childNode.getAttribute('data-mui-internal-clone-element')) {\n console.error(['MUI: The `children` component of the Tooltip is not forwarding its props correctly.', 'Please make sure that props are spread on the same element that the ref is applied to.'].join('\\n'));\n }\n }, [childNode]);\n }\n const interactiveWrapperListeners = {};\n if (!disableTouchListener) {\n childrenProps.onTouchStart = handleTouchStart;\n childrenProps.onTouchEnd = handleTouchEnd;\n }\n if (!disableHoverListener) {\n childrenProps.onMouseOver = composeEventHandler(handleMouseOver, childrenProps.onMouseOver);\n childrenProps.onMouseLeave = composeEventHandler(handleMouseLeave, childrenProps.onMouseLeave);\n if (!disableInteractive) {\n interactiveWrapperListeners.onMouseOver = handleMouseOver;\n interactiveWrapperListeners.onMouseLeave = handleMouseLeave;\n }\n }\n if (!disableFocusListener) {\n childrenProps.onFocus = composeEventHandler(handleFocus, childrenProps.onFocus);\n childrenProps.onBlur = composeEventHandler(handleBlur, childrenProps.onBlur);\n if (!disableInteractive) {\n interactiveWrapperListeners.onFocus = handleFocus;\n interactiveWrapperListeners.onBlur = handleBlur;\n }\n }\n if (process.env.NODE_ENV !== 'production') {\n if (children.props.title) {\n console.error(['MUI: You have provided a `title` prop to the child of .', `Remove this title prop \\`${children.props.title}\\` or the Tooltip component.`].join('\\n'));\n }\n }\n const popperOptions = React.useMemo(() => {\n var _PopperProps$popperOp;\n let tooltipModifiers = [{\n name: 'arrow',\n enabled: Boolean(arrowRef),\n options: {\n element: arrowRef,\n padding: 4\n }\n }];\n if ((_PopperProps$popperOp = PopperProps.popperOptions) != null && _PopperProps$popperOp.modifiers) {\n tooltipModifiers = tooltipModifiers.concat(PopperProps.popperOptions.modifiers);\n }\n return _extends({}, PopperProps.popperOptions, {\n modifiers: tooltipModifiers\n });\n }, [arrowRef, PopperProps]);\n const ownerState = _extends({}, props, {\n isRtl,\n arrow,\n disableInteractive,\n placement,\n PopperComponentProp,\n touch: ignoreNonTouchEvents.current\n });\n const classes = useUtilityClasses(ownerState);\n const PopperComponent = (_ref = (_slots$popper = slots.popper) != null ? _slots$popper : components.Popper) != null ? _ref : TooltipPopper;\n const TransitionComponent = (_ref2 = (_ref3 = (_slots$transition = slots.transition) != null ? _slots$transition : components.Transition) != null ? _ref3 : TransitionComponentProp) != null ? _ref2 : Grow;\n const TooltipComponent = (_ref4 = (_slots$tooltip = slots.tooltip) != null ? _slots$tooltip : components.Tooltip) != null ? _ref4 : TooltipTooltip;\n const ArrowComponent = (_ref5 = (_slots$arrow = slots.arrow) != null ? _slots$arrow : components.Arrow) != null ? _ref5 : TooltipArrow;\n const popperProps = appendOwnerState(PopperComponent, _extends({}, PopperProps, (_slotProps$popper = slotProps.popper) != null ? _slotProps$popper : componentsProps.popper, {\n className: clsx(classes.popper, PopperProps == null ? void 0 : PopperProps.className, (_ref6 = (_slotProps$popper2 = slotProps.popper) != null ? _slotProps$popper2 : componentsProps.popper) == null ? void 0 : _ref6.className)\n }), ownerState);\n const transitionProps = appendOwnerState(TransitionComponent, _extends({}, TransitionProps, (_slotProps$transition = slotProps.transition) != null ? _slotProps$transition : componentsProps.transition), ownerState);\n const tooltipProps = appendOwnerState(TooltipComponent, _extends({}, (_slotProps$tooltip = slotProps.tooltip) != null ? _slotProps$tooltip : componentsProps.tooltip, {\n className: clsx(classes.tooltip, (_ref7 = (_slotProps$tooltip2 = slotProps.tooltip) != null ? _slotProps$tooltip2 : componentsProps.tooltip) == null ? void 0 : _ref7.className)\n }), ownerState);\n const tooltipArrowProps = appendOwnerState(ArrowComponent, _extends({}, (_slotProps$arrow = slotProps.arrow) != null ? _slotProps$arrow : componentsProps.arrow, {\n className: clsx(classes.arrow, (_ref8 = (_slotProps$arrow2 = slotProps.arrow) != null ? _slotProps$arrow2 : componentsProps.arrow) == null ? void 0 : _ref8.className)\n }), ownerState);\n return /*#__PURE__*/_jsxs(React.Fragment, {\n children: [/*#__PURE__*/React.cloneElement(children, childrenProps), /*#__PURE__*/_jsx(PopperComponent, _extends({\n as: PopperComponentProp != null ? PopperComponentProp : Popper,\n placement: placement,\n anchorEl: followCursor ? {\n getBoundingClientRect: () => ({\n top: cursorPosition.y,\n left: cursorPosition.x,\n right: cursorPosition.x,\n bottom: cursorPosition.y,\n width: 0,\n height: 0\n })\n } : childNode,\n popperRef: popperRef,\n open: childNode ? open : false,\n id: id,\n transition: true\n }, interactiveWrapperListeners, popperProps, {\n popperOptions: popperOptions,\n children: ({\n TransitionProps: TransitionPropsInner\n }) => /*#__PURE__*/_jsx(TransitionComponent, _extends({\n timeout: theme.transitions.duration.shorter\n }, TransitionPropsInner, transitionProps, {\n children: /*#__PURE__*/_jsxs(TooltipComponent, _extends({}, tooltipProps, {\n children: [title, arrow ? /*#__PURE__*/_jsx(ArrowComponent, _extends({}, tooltipArrowProps, {\n ref: setArrowRef\n })) : null]\n }))\n }))\n }))]\n });\n});\nprocess.env.NODE_ENV !== \"production\" ? Tooltip.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the d.ts file and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * If `true`, adds an arrow to the tooltip.\n * @default false\n */\n arrow: PropTypes.bool,\n /**\n * Tooltip reference element.\n */\n children: elementAcceptingRef.isRequired,\n /**\n * Override or extend the styles applied to the component.\n */\n classes: PropTypes.object,\n /**\n * @ignore\n */\n className: PropTypes.string,\n /**\n * The components used for each slot inside.\n *\n * This prop is an alias for the `slots` prop.\n * It's recommended to use the `slots` prop instead.\n *\n * @default {}\n */\n components: PropTypes.shape({\n Arrow: PropTypes.elementType,\n Popper: PropTypes.elementType,\n Tooltip: PropTypes.elementType,\n Transition: PropTypes.elementType\n }),\n /**\n * The extra props for the slot components.\n * You can override the existing props or add new ones.\n *\n * This prop is an alias for the `slotProps` prop.\n * It's recommended to use the `slotProps` prop instead, as `componentsProps` will be deprecated in the future.\n *\n * @default {}\n */\n componentsProps: PropTypes.shape({\n arrow: PropTypes.object,\n popper: PropTypes.object,\n tooltip: PropTypes.object,\n transition: PropTypes.object\n }),\n /**\n * Set to `true` if the `title` acts as an accessible description.\n * By default the `title` acts as an accessible label for the child.\n * @default false\n */\n describeChild: PropTypes.bool,\n /**\n * Do not respond to focus-visible events.\n * @default false\n */\n disableFocusListener: PropTypes.bool,\n /**\n * Do not respond to hover events.\n * @default false\n */\n disableHoverListener: PropTypes.bool,\n /**\n * Makes a tooltip not interactive, i.e. it will close when the user\n * hovers over the tooltip before the `leaveDelay` is expired.\n * @default false\n */\n disableInteractive: PropTypes.bool,\n /**\n * Do not respond to long press touch events.\n * @default false\n */\n disableTouchListener: PropTypes.bool,\n /**\n * The number of milliseconds to wait before showing the tooltip.\n * This prop won't impact the enter touch delay (`enterTouchDelay`).\n * @default 100\n */\n enterDelay: PropTypes.number,\n /**\n * The number of milliseconds to wait before showing the tooltip when one was already recently opened.\n * @default 0\n */\n enterNextDelay: PropTypes.number,\n /**\n * The number of milliseconds a user must touch the element before showing the tooltip.\n * @default 700\n */\n enterTouchDelay: PropTypes.number,\n /**\n * If `true`, the tooltip follow the cursor over the wrapped element.\n * @default false\n */\n followCursor: PropTypes.bool,\n /**\n * This prop is used to help implement the accessibility logic.\n * If you don't provide this prop. It falls back to a randomly generated id.\n */\n id: PropTypes.string,\n /**\n * The number of milliseconds to wait before hiding the tooltip.\n * This prop won't impact the leave touch delay (`leaveTouchDelay`).\n * @default 0\n */\n leaveDelay: PropTypes.number,\n /**\n * The number of milliseconds after the user stops touching an element before hiding the tooltip.\n * @default 1500\n */\n leaveTouchDelay: PropTypes.number,\n /**\n * Callback fired when the component requests to be closed.\n *\n * @param {React.SyntheticEvent} event The event source of the callback.\n */\n onClose: PropTypes.func,\n /**\n * Callback fired when the component requests to be open.\n *\n * @param {React.SyntheticEvent} event The event source of the callback.\n */\n onOpen: PropTypes.func,\n /**\n * If `true`, the component is shown.\n */\n open: PropTypes.bool,\n /**\n * Tooltip placement.\n * @default 'bottom'\n */\n placement: PropTypes.oneOf(['bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n /**\n * The component used for the popper.\n * @default Popper\n */\n PopperComponent: PropTypes.elementType,\n /**\n * Props applied to the [`Popper`](/material-ui/api/popper/) element.\n * @default {}\n */\n PopperProps: PropTypes.object,\n /**\n * The extra props for the slot components.\n * You can override the existing props or add new ones.\n *\n * This prop is an alias for the `componentsProps` prop, which will be deprecated in the future.\n *\n * @default {}\n */\n slotProps: PropTypes.shape({\n arrow: PropTypes.object,\n popper: PropTypes.object,\n tooltip: PropTypes.object,\n transition: PropTypes.object\n }),\n /**\n * The components used for each slot inside.\n *\n * This prop is an alias for the `components` prop, which will be deprecated in the future.\n *\n * @default {}\n */\n slots: PropTypes.shape({\n arrow: PropTypes.elementType,\n popper: PropTypes.elementType,\n tooltip: PropTypes.elementType,\n transition: PropTypes.elementType\n }),\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Tooltip title. Zero-length titles string, undefined, null and false are never displayed.\n */\n title: PropTypes.node,\n /**\n * The component used for the transition.\n * [Follow this guide](/material-ui/transitions/#transitioncomponent-prop) to learn more about the requirements for this component.\n * @default Grow\n */\n TransitionComponent: PropTypes.elementType,\n /**\n * Props applied to the transition element.\n * By default, the element is based on this [`Transition`](http://reactcommunity.org/react-transition-group/transition/) component.\n */\n TransitionProps: PropTypes.object\n} : void 0;\nexport default Tooltip;","import '@/components/mui/menu-item.component.css';\nimport ArrowRightIcon from '@mui/icons-material/ArrowRight';\nimport {\n ListItemIcon as MuiListItemIcon,\n ListItemText as MuiListItemText,\n MenuItem as MuiMenuItem,\n} from '@mui/material';\nimport Tooltip from '@mui/material/Tooltip';\nimport { Localized, ReferencedItem, SingleColumnMenu } from 'platform-bible-utils';\nimport { MouseEvent, PropsWithChildren } from 'react';\n\ntype MenuItemInfoBase = {\n /** Text (displayable in the UI) as the name of the menu item */\n label: string;\n /** Text to display when the mouse hovers over the menu item */\n tooltip?: string;\n};\n\nexport type Command = MenuItemInfoBase & {\n /** Command to execute (string.string) */\n command: string;\n};\n\ntype SubMenu = MenuItemInfoBase & {\n /** Command to execute (string.string) */\n items: MenuItemInfo[];\n};\n\nexport interface CommandHandler {\n (command: Command): void;\n}\n\nexport type MenuPropsBase = {\n /*\n * The JSON defining the menu whose items are to be rendered. This will typically be one of the\n * menus in the \"defs\" in a Platform.Bible menu (see PlatformMenus). The schema for this is\n * menuDocumentSchema (at the end of menus.model.ts). Note that while this is a\n * \"SingleColumnMenu\", somewhat bizarrely, a MultiColumnMenu is a SingleColumnMenu, so it really\n * could be a MultiColumnMenu, in which case, column had better be defined so it can be used\n * to filter out the actual groups and items to display on the column.\n */\n menuDefinition: Localized;\n\n commandHandler: CommandHandler;\n\n /**\n * Additional action to perform when any menu item is clicked. Allows the caller to handle event\n * (e.g., to close the menu).\n */\n onClick?: (event: MouseEvent) => void;\n};\n\nexport type MenuItemListProps = MenuPropsBase & {\n /** Optional unique (column) identifier */\n columnId?: ReferencedItem;\n};\n\nexport type MenuItemProps = Omit &\n PropsWithChildren<{\n /** Optional unique identifier */\n id?: string;\n\n onClick: (event: MouseEvent) => void;\n }>;\n\ntype MenuItemInfo = (Command | SubMenu) & {\n /**\n * If specified, menu item will be inset if it does not have a leading icon.\n *\n * @default true\n */\n allowForLeadingIcons?: boolean;\n /**\n * If specified, the path to the icon image to display on the leading side of the menu text.\n *\n * @default undefined (no leading icon will be shown)\n */\n iconPathBefore?: string;\n /**\n * If specified, the path to the icon image to display on the trailing side of the menu text.\n *\n * @default undefined (no trailing icon will be shown)\n */\n iconPathAfter?: string;\n /**\n * If true, list item is focused during the first mount\n *\n * @default false\n */\n hasAutoFocus?: boolean;\n\n /** Additional css classes to help with unique styling of the menu item */\n className?: string;\n\n /**\n * If true, the menu item will appear disabled and it will not respond to clicks or mouse hovers.\n *\n * @default false\n */\n isDisabled?: boolean;\n\n /**\n * If true, compact vertical padding designed for keyboard and mouse input is used.\n *\n * @default true\n */\n isDense?: boolean;\n\n /**\n * If true, a right-arrow icon will be displayed (iconPathAfter, if specified, will be ignored).\n *\n * @default false\n */\n isSubMenuParent?: boolean;\n\n /**\n * If true, the left and right padding is removed\n *\n * @default false\n */\n hasDisabledGutters?: boolean;\n\n /**\n * If true, a 1px light border is added to bottom of menu item\n *\n * @default false\n */\n hasDivider?: boolean;\n\n /** Help identify which element has keyboard focus */\n focusVisibleClassName?: string;\n\n /** If it's a submenu, it should have the items property */\n items?: MenuItemInfo[];\n};\n\nfunction getIcon(icon: string | undefined, menuLabel: string, leading: boolean) {\n return icon ? (\n \n {`${leading\n \n ) : undefined;\n}\n\nexport default function MenuItem(props: MenuItemProps) {\n const {\n onClick,\n label,\n tooltip,\n allowForLeadingIcons = true,\n iconPathBefore = undefined,\n iconPathAfter = undefined,\n hasAutoFocus = false,\n className,\n isDisabled = false,\n isDense = true,\n isSubMenuParent = false,\n hasDisabledGutters = false,\n hasDivider = false,\n focusVisibleClassName,\n id,\n children,\n } = props;\n\n const menuItem = (\n \n {label ? (\n <>\n {getIcon(iconPathBefore, label, true)}\n \n {isSubMenuParent ? (\n \n \n \n ) : (\n getIcon(iconPathAfter, label, false)\n )}\n \n ) : (\n children\n )}\n \n );\n\n return tooltip ? (\n \n
    {menuItem}
    \n
    \n ) : (\n menuItem\n );\n}\n","import MenuItem, {\n MenuItemListProps,\n MenuItemProps,\n MenuPropsBase,\n} from '@/components/mui/menu-item.component';\nimport { Menu } from '@mui/material';\nimport {\n Localized,\n MenuGroupDetailsInSubMenu,\n MenuItemContainingCommand,\n MenuItemContainingSubmenu,\n OrderedExtensibleContainer,\n ReferencedItem,\n SingleColumnMenu,\n} from 'platform-bible-utils';\nimport { MouseEvent, useMemo, useState } from 'react';\n\n/**\n * All the exported types in this file should be regarded as \"internal\" (i.e., they should not be\n * exposed via index.ts).\n */\n\nexport type GroupedMenuPropsBase = MenuPropsBase & {\n /** Optional unique (column) identifier */\n columnId?: ReferencedItem;\n};\n\nexport type GroupedMenuItemListProps = MenuItemListProps & {\n /**\n * If the menuDefinition includes \"top-level\" groups (i.e., those that belong to a column as\n * opposed to those that belong to a submenu) that should not be included in the list, then this\n * array specifies which groups to include. Likewise, for a submenu, this list indicates which\n * groups are pertinent for that submenu. So then for a context menu this property need not be\n * specified since it is a top-level menu based on a \"true\" SingleColumnMenu (i.e., one that is\n * not a MultiColumnMenu).\n */\n includedGroups?: {\n id: string;\n group: Localized;\n }[];\n};\n\ninterface ItemInfo {\n item: Localized;\n isLastItemInGroup: boolean;\n}\n\ntype SubMenuProps = MenuPropsBase & {\n parentMenuItem: Localized;\n parentItemProps: Omit, 'iconPathAfter'>;\n};\n\nfunction getAllGroups(menuDefinition: Localized) {\n const groupEntries = Object.entries(menuDefinition.groups);\n // Convert array of entries to array of objects with id and group properties\n return groupEntries.map(([key, value]) => ({ id: key, group: value }));\n}\n\nfunction SubMenu(props: SubMenuProps) {\n const [anchorEl, setAnchorEl] = useState(undefined);\n\n const { parentMenuItem, parentItemProps, menuDefinition } = props;\n\n const handleParentMenuItemClick = (event: MouseEvent) => {\n setAnchorEl(event.currentTarget);\n };\n\n const handleClose = () => {\n setAnchorEl(undefined);\n };\n\n const renderSubMenuItems = () => {\n let includedGroups = getAllGroups(menuDefinition).filter((g) => 'menuItem' in g.group);\n\n // Ensure valid parent menu was provided. (If not, submenu will contain all groups!)\n if (!parentMenuItem?.id) throw new Error('A valid parent menu item is required for submenus.');\n\n // When laying out a submenu, only include groups associated with the provided parent menu.\n // Note: without the (annoying) redundant check that the included groups\n // have the menuItem field, TS doesn't think it exists.\n includedGroups = includedGroups.filter(\n (group) => 'menuItem' in group.group && group.group.menuItem === parentMenuItem.id,\n );\n\n return ;\n };\n\n return (\n <>\n \n \n {renderSubMenuItems()}\n \n \n );\n}\n\nconst getOrderedGroupItems = (\n groupId: string,\n allItems: Localized[],\n) => {\n // Filter items that belong to the specified group\n const itemsForGroup = allItems.filter((item) => item.group === groupId);\n // Sort items based on order\n const sortedItems = itemsForGroup.sort((a, b) => (a.order || 0) - (b.order || 0));\n return sortedItems;\n};\n\n/**\n * This component is internal; it does not need to be exposed to the outside world since it is not\n * useful on its own. It is used to generate and lay out the MenuItems that appear either on a\n * top-level menu (in a GridMenu or ContextMenu) or in a submenu.\n */\nexport default function GroupedMenuItemList(menuProps: GroupedMenuItemListProps) {\n const { menuDefinition, onClick, commandHandler, includedGroups } = menuProps;\n\n const { items, allowForLeadingIcons } = useMemo(() => {\n const groupsToInclude =\n includedGroups && includedGroups.length > 0\n ? includedGroups\n : // We're apparently laying out a single-column menu (presumably a context menu). In this\n // case, all groups should be included except ones that belong to a submenu.\n getAllGroups(menuDefinition).filter((g) => !('menuItem' in g.group));\n\n const sortedGroups = Object.values(groupsToInclude).sort(\n (a, b) => (a.group.order || 0) - (b.group.order || 0),\n );\n\n const itemArray: ItemInfo[] = [];\n\n sortedGroups.forEach((group) => {\n getOrderedGroupItems(group.id, menuDefinition.items).forEach((item) =>\n itemArray.push({ item, isLastItemInGroup: false }),\n );\n if (itemArray.length > 0) itemArray[itemArray.length - 1].isLastItemInGroup = true;\n });\n\n // No divider after last item in final group.\n if (itemArray.length > 0) itemArray[itemArray.length - 1].isLastItemInGroup = false;\n\n const allowSpaceForLeadingIcons = itemArray.some(\n (i) => 'iconPathBefore' in i.item && i.item.iconPathBefore,\n );\n\n return { items: itemArray, allowForLeadingIcons: allowSpaceForLeadingIcons };\n }, [includedGroups, menuDefinition]);\n\n // Create props for MenuItem component including setting hasDivider for the last item in a group\n const createMenuItemProps = ({ item, isLastItemInGroup }: ItemInfo) => {\n const menuItemProps = {\n className: 'papi-menu-item',\n label: item.label,\n tooltip: item.tooltip,\n iconPathBefore: 'iconPathBefore' in item ? item.iconPathBefore : undefined,\n iconPathAfter: 'iconPathAfter' in item ? item.iconPathAfter : undefined,\n hasDivider: isLastItemInGroup, // Set hasDivider to true for the last item in a group\n allowForLeadingIcons,\n };\n\n return menuItemProps;\n };\n\n const [firstItem] = items;\n\n if (!firstItem) return
    ;\n\n const divKey = firstItem.item.group;\n\n return (\n
    \n {items.map((itemInfo, index) => {\n const { item } = itemInfo;\n const menuItemProps = createMenuItemProps(itemInfo);\n if ('command' in item) {\n const key = item.group + index;\n return (\n ) => {\n onClick?.(event);\n commandHandler(item);\n }}\n {...menuItemProps}\n />\n );\n }\n return (\n \n );\n })}\n
    \n );\n}\n","import GroupedMenuItemList from '@/components/mui/grouped-menu-item-list.component';\nimport { MenuItemListProps } from '@/components/mui/menu-item.component';\nimport { MultiColumnMenu } from 'platform-bible-utils';\n\n/**\n * This component is internal; it does not need to be exposed to the outside world since it is not\n * useful on its own. Use either GridMenu or ContextMenu.\n */\nexport default function TopLevelMenu(props: MenuItemListProps) {\n const { menuDefinition, columnId } = props;\n\n const groupEntries = Object.entries(menuDefinition.groups);\n // Convert array of entries to array of objects with id and group properties\n const groups = groupEntries.map(([key, value]) => ({ id: key, group: value }));\n let includedGroups = groups.filter((g) => 'column' in g.group);\n\n // Check if column is provided and menuDefinition is a MultiColumnMenu\n if (\n columnId &&\n 'columns' in menuDefinition &&\n // Without this type assertion, TS doesn't know what columns is.\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n (menuDefinition as MultiColumnMenu).columns[columnId]\n ) {\n // When laying out a single column in a MultiColumnMenu, only include groups associated with\n // the provided column. Note: without the (annoying) redundant check that the included groups\n // have the colum field, TS doesn't think it exists.\n includedGroups = includedGroups.filter(\n (g) => 'column' in g.group && g.group.column === columnId,\n );\n }\n\n return ;\n}\n","import '@/components/mui/grid-menu.component.css';\nimport { GroupedMenuPropsBase } from '@/components/mui/grouped-menu-item-list.component';\nimport { CommandHandler } from '@/components/mui/menu-item.component';\nimport TopLevelMenu from '@/components/mui/top-level-menu.component';\nimport { Grid, List } from '@mui/material';\nimport {\n Localized,\n MenuColumnWithHeader,\n MultiColumnMenu,\n ReferencedItem,\n} from 'platform-bible-utils';\nimport { useMemo } from 'react';\n\ntype ColumnInfo = {\n /*\n * The ID (`${string}.${string}`) of a specific menu column.\n */\n id: ReferencedItem;\n\n /*\n * Metadata (label, order, etc.) for a specific menu column.\n */\n metadata: Localized;\n};\n\ntype MenuColumnProps = ColumnInfo &\n GroupedMenuPropsBase & {\n /** Additional css classes to help with unique styling of the menu column */\n className?: string;\n };\n\nexport type GridMenuInfo = {\n /** The menu object containing information about the columns, groups, and items to display. */\n multiColumnMenu: Localized;\n};\n\nexport type GridMenuProps = GridMenuInfo & {\n /** Optional unique identifier */\n id?: string;\n\n commandHandler: CommandHandler;\n\n /** Additional css classes to help with unique styling of the grid menu */\n className?: string;\n};\n\nfunction MenuColumn({\n commandHandler,\n menuDefinition,\n id,\n metadata,\n onClick,\n className,\n}: MenuColumnProps) {\n return (\n \n

    \n {metadata.label}\n

    \n {/* It would seem as though this List component were unnecessary, since it only contains one\n thing, but the \"dense\" property does affect the layout of the items (in a way I don't fully\n understand). There might be a better way. */}\n \n \n \n \n );\n}\n\nexport default function GridMenu({\n commandHandler,\n className,\n multiColumnMenu,\n id,\n}: GridMenuProps) {\n const { columns } = multiColumnMenu;\n\n const sortedColumns = useMemo(() => {\n const columnNumbers = new Map();\n Object.getOwnPropertyNames(columns).forEach((columnName: string) => {\n // We know for sure there is a (boolean) property 'isExtensible' that we are not interested in.\n if (columnName === 'isExtensible') return;\n // TS doesn't allow `columnName` above to be a ReferencedItem even though the type says it is\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const columnId = columnName as ReferencedItem;\n const column = columns[columnId];\n // As of right now (and hopefully forever after), all remaining properties of the\n // ColumnsWithHeaders object are columns whose property names are the IDs of the columns.\n // This is an additional (redundant) sanity check. Specifically we're interested in\n // MenuColumnWithHeader objects, which TypeScript now \"knows\" we have, but at runtime all we\n // can check for is that it's an object with a valid numeric order field. That's likely good\n // enough.\n if (\n typeof column === 'object' &&\n typeof column.order === 'number' &&\n !Number.isNaN(column.order)\n )\n columnNumbers.set(column.order, { id: columnId, metadata: column });\n else\n console.warn(\n `Property ${columnName} (${typeof column}) on menu ${id} is not a valid column and is being ignored. This might indicate data corruption`,\n );\n });\n\n // Extract values and sort them based on the 'order' property\n return Array.from(columnNumbers.values()).sort((a, b) => {\n return (a.metadata.order || 0) - (b.metadata.order || 0);\n });\n }, [columns, id]);\n\n // We might need something like this if we need to be able to prevent empty columns\n // sortedColumns.filter((c) => multiColumnMenu.groups.some((g) => 'column' in g && (g as .column)...\n\n return (\n \n {sortedColumns.map((col, index) => (\n \n ))}\n \n );\n}\n","import { useEffect, useRef, useState } from 'react';\n\nexport type UsePromiseOptions = {\n /**\n * Whether to leave the value as the most recent resolved promise value or set it back to\n * defaultValue while running the promise again. Defaults to true\n */\n preserveValue?: boolean;\n};\n\n/** Set up defaults for options for usePromise hook */\nfunction getUsePromiseOptionsDefaults(options: UsePromiseOptions): UsePromiseOptions {\n return {\n preserveValue: true,\n ...options,\n };\n}\n\n/**\n * Awaits a promise and returns a loading value while the promise is unresolved\n *\n * @param promiseFactoryCallback A function that returns the promise to await. If this callback is\n * undefined, the current value will be returned (defaultValue unless it was previously changed\n * and `options.preserveValue` is true), and there will be no loading.\n *\n * WARNING: MUST BE STABLE - const or wrapped in useCallback. The reference must not be updated\n * every render\n * @param defaultValue The initial value to return while first awaiting the promise. If\n * `options.preserveValue` is false, this value is also shown while awaiting the promise on\n * subsequent calls.\n *\n * Note: this parameter is internally assigned to a `ref`, so changing it will not cause any hooks\n * to re-run with its new value. This means that, if the `promiseFactoryCallback` changes and\n * `options.preserveValue` is `false`, the returned value will be set to the current\n * `defaultValue`. However, the returned value will not be updated if`defaultValue` changes.\n * @param options Various options for adjusting how this hook runs the `promiseFactoryCallback`\n *\n * Note: this parameter is internally assigned to a `ref`, so changing it will not cause any hooks\n * to re-run with its new value. However, the latest `options.preserveValue` will always be used\n * appropriately to determine whether to preserve the returned value when changing the\n * `promiseFactoryCallback`\n * @returns `[value, isLoading]`\n *\n * - `value`: the current value for the promise, either the defaultValue or the resolved promise value\n * - `isLoading`: whether the promise is waiting to be resolved\n */\nconst usePromise = (\n promiseFactoryCallback: (() => Promise) | undefined,\n defaultValue: T,\n options: UsePromiseOptions = {},\n): [value: T, isLoading: boolean] => {\n // Use defaultValue as a ref so it doesn't update dependency arrays\n const defaultValueRef = useRef(defaultValue);\n defaultValueRef.current = defaultValue;\n // Use options as a ref so it doesn't update dependency arrays\n const optionsDefaultedRef = useRef(options);\n optionsDefaultedRef.current = getUsePromiseOptionsDefaults(optionsDefaultedRef.current);\n\n const [value, setValue] = useState(() => defaultValueRef.current);\n const [isLoading, setIsLoading] = useState(true);\n useEffect(() => {\n let promiseIsCurrent = true;\n // If a promiseFactoryCallback was provided, we are loading. Otherwise, there is no loading to do\n setIsLoading(!!promiseFactoryCallback);\n (async () => {\n // If there is a callback to run, run it\n if (promiseFactoryCallback) {\n const result = await promiseFactoryCallback();\n // If the promise was not already replaced, update the value\n if (promiseIsCurrent) {\n setValue(() => result);\n setIsLoading(false);\n }\n }\n })();\n\n return () => {\n // Mark this promise as old and not to be used\n promiseIsCurrent = false;\n if (!optionsDefaultedRef.current.preserveValue) setValue(() => defaultValueRef.current);\n };\n }, [promiseFactoryCallback]);\n\n return [value, isLoading];\n};\nexport default usePromise;\n","\"use client\";\n\nimport createSvgIcon from './utils/createSvgIcon';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nexport default createSvgIcon( /*#__PURE__*/_jsx(\"path\", {\n d: \"M3 18h18v-2H3zm0-5h18v-2H3zm0-7v2h18V6z\"\n}), 'Menu');","import GridMenu from '@/components/mui/grid-menu.component';\nimport { Command, CommandHandler } from '@/components/mui/menu-item.component';\nimport usePromise from '@/hooks/use-promise.hook';\nimport { Menu as MenuIcon } from '@mui/icons-material';\nimport { Drawer, IconButton } from '@mui/material';\nimport { Localized, MultiColumnMenu } from 'platform-bible-utils';\nimport {\n MouseEvent,\n MutableRefObject,\n PropsWithChildren,\n useCallback,\n useEffect,\n useState,\n} from 'react';\n\nexport interface MultiColumnMenuProvider {\n (isSupportAndDevelopment: boolean): Promise>;\n}\n\nexport type HamburgerMenuButtonProps = PropsWithChildren & {\n /** The handler to use for menu commands (and eventually toolbar commands). */\n commandHandler: CommandHandler;\n\n /**\n * Optional reference to the \"div\" container that determines the where the menu should appear. If\n * not defined, then (1,1) used.\n */\n containerRef?: MutableRefObject;\n\n /**\n * The delegate to use to get the menu data. If not specified or if it returns undefined, the data\n * in normalMenu or fullMenu property will be used.\n */\n menuProvider?: MultiColumnMenuProvider;\n\n /**\n * The menu data to show when the menu is opened if the menuProvider property is not defined.\n * (This allows for a default or test-only static menu to be used.)\n */\n normalMenu?: Localized;\n\n /**\n * The menu data to show for \"full\" menu (when opened with the SHIFT key pressed) if the\n * menuProvider property is not defined. (This allows for a default or test-only static menu to be\n * used.)\n */\n fullMenu?: Localized;\n\n /** Additional css class(es) to help with unique styling of the sub-components */\n className?: string;\n\n /** Value to use as prefix for ARIA labels on interactive sub-components */\n ariaLabelPrefix?: string;\n};\n\nexport default function HamburgerMenuButton({\n menuProvider,\n normalMenu,\n fullMenu,\n commandHandler,\n containerRef,\n className,\n ariaLabelPrefix,\n children,\n}: HamburgerMenuButtonProps) {\n const [isMenuOpen, setMenuOpen] = useState(false);\n const [showFullMenu, setShowFullMenu] = useState(false);\n\n const handleMenuItemClick = useCallback(() => {\n if (isMenuOpen) setMenuOpen(false);\n setShowFullMenu(false);\n }, [isMenuOpen]);\n\n const handleMenuButtonClick = useCallback((e: MouseEvent) => {\n e.stopPropagation();\n setMenuOpen((prevIsOpen) => {\n const isOpening = !prevIsOpen;\n if (isOpening && e.shiftKey) setShowFullMenu(true);\n else if (!isOpening) setShowFullMenu(false);\n return isOpening;\n });\n }, []);\n\n const menuCommandHandler = useCallback(\n (command: Command) => {\n handleMenuItemClick();\n return commandHandler(command);\n },\n [commandHandler, handleMenuItemClick],\n );\n\n const [offset, setOffset] = useState({ top: 1, left: 1 });\n\n useEffect(() => {\n if (isMenuOpen) {\n const node = containerRef?.current;\n if (node) {\n const rect = node.getBoundingClientRect();\n const scrollTop = window.scrollY;\n const scrollLeft = window.scrollX;\n const top = rect.top + scrollTop + node.clientHeight;\n const left = rect.left + scrollLeft;\n setOffset({ top, left });\n }\n }\n }, [isMenuOpen, containerRef]);\n\n const [normalMenuData] = usePromise(\n useCallback(async () => {\n return menuProvider?.(false) ?? normalMenu;\n // isMenuOpen needs to be included for the menu contents to reevaluate when reopened\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [menuProvider, normalMenu, isMenuOpen]),\n normalMenu,\n );\n\n const [fullMenuData] = usePromise(\n useCallback(async () => {\n return menuProvider?.(true) ?? fullMenu ?? normalMenuData;\n // isMenuOpen needs to be included for the menu contents to reevaluate when reopened\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [menuProvider, fullMenu, normalMenuData, isMenuOpen]),\n fullMenu ?? normalMenuData,\n );\n\n const menu = showFullMenu && fullMenuData ? fullMenuData : normalMenuData;\n\n return (\n <>\n \n {children ?? }\n \n \n {menu ? (\n \n ) : undefined}\n \n \n );\n}\n","import '@/components/mui/icon-button.component.css';\nimport { IconButton as MuiIconButton } from '@mui/material';\nimport { MouseEventHandler, PropsWithChildren } from 'react';\n\nexport type IconButtonProps = PropsWithChildren<{\n /** Optional unique identifier */\n id?: string;\n /**\n * Required. Used as both the tooltip (aka, title) and the aria-label (used for accessibility,\n * testing, etc.), unless a distinct tooltip is supplied.\n */\n label: string;\n /**\n * Enabled status of button\n *\n * @default false\n */\n isDisabled?: boolean;\n /** Optional tooltip to display if different from the aria-label. */\n tooltip?: string;\n /** If true, no tooltip will be displayed. */\n isTooltipSuppressed?: boolean;\n /**\n * If given, uses a negative margin to counteract the padding on one side (this is often helpful\n * for aligning the left or right side of the icon with content above or below, without ruining\n * the border size and shape).\n *\n * @default false\n */\n adjustMarginToAlignToEdge?: 'end' | 'start' | false;\n /**\n * The size of the component. small is equivalent to the dense button styling.\n *\n * @default false\n */\n size: 'small' | 'medium' | 'large';\n /** Additional css classes to help with unique styling of the button */\n className?: string;\n /** Optional click handler */\n onClick?: MouseEventHandler;\n}>;\n\n/**\n * Iconic button a user can click to do something\n *\n * Thanks to MUI for heavy inspiration and documentation\n * https://mui.com/material-ui/getting-started/overview/\n */\nfunction IconButton({\n id,\n label,\n isDisabled = false,\n tooltip,\n isTooltipSuppressed = false,\n adjustMarginToAlignToEdge = false,\n size = 'medium',\n className,\n onClick,\n children,\n}: IconButtonProps) {\n return (\n \n {children /* the icon to display */}\n \n );\n}\n\nexport default IconButton;\n","import { cn } from '@/utils/shadcn-ui.util';\nimport { LoaderCircle, LucideProps } from 'lucide-react';\nimport { forwardRef } from 'react';\n\nexport type SpinnerProps = LucideProps;\n\nconst Spinner = forwardRef(({ className, ...props }, ref) => {\n return (\n \n );\n});\n\nSpinner.displayName = 'Spinner';\n\nexport default Spinner;\n","import { Input as ShadInput } from '@/components/shadcn-ui/input';\nimport { Label as ShadLabel } from '@/components/shadcn-ui/label';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { ChangeEventHandler, FocusEventHandler } from 'react';\n\nexport type TextFieldProps = {\n /** Optional unique identifier */\n id?: string;\n /**\n * If `true`, the component is disabled.\n *\n * @default false\n */\n isDisabled?: boolean;\n /**\n * If `true`, the label is displayed in an error state.\n *\n * @default false\n */\n hasError?: boolean;\n /**\n * If `true`, the input will take up the full width of its container.\n *\n * @default false\n */\n isFullWidth?: boolean;\n /** Text that gives the user instructions on what contents the TextField expects */\n helperText?: string;\n /** The title of the TextField */\n label?: string;\n /** The short hint displayed in the `input` before the user enters a value. */\n placeholder?: string;\n /**\n * If `true`, the label is displayed as required and the `input` element is required.\n *\n * @default false\n */\n isRequired?: boolean;\n /** Additional css classes to help with unique styling of the text field */\n className?: string;\n /** Starting value for the text field if it is not controlled */\n defaultValue?: string | number;\n /** Value of the text field if controlled */\n value?: string | number;\n /** Triggers when content of textfield is changed */\n onChange?: ChangeEventHandler;\n /** Triggers when textfield gets focus */\n onFocus?: FocusEventHandler;\n /** Triggers when textfield loses focus */\n onBlur?: FocusEventHandler;\n};\n\n/**\n * Text input field\n *\n * Thanks to Shadcn for heavy inspiration and documentation\n * https://ui.shadcn.com/docs/components/input#with-label\n */\nfunction TextField({\n id,\n isDisabled = false,\n hasError = false,\n isFullWidth = false,\n helperText,\n label,\n placeholder,\n isRequired = false,\n className,\n defaultValue,\n value,\n onChange,\n onFocus,\n onBlur,\n}: TextFieldProps) {\n return (\n
    \n {`${label}${isRequired ? '*' : ''}`}\n \n

    {helperText}

    \n
    \n );\n}\n\nexport default TextField;\n","import HamburgerMenuButton, {\n MultiColumnMenuProvider,\n} from '@/components/mui/hamburger-menu-button.component';\nimport { CommandHandler } from '@/components/mui/menu-item.component';\nimport '@/components/mui/toolbar.component.css';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { AppBar, Toolbar as MuiToolbar } from '@mui/material';\nimport { PropsWithChildren, useRef } from 'react';\n\nexport type ToolbarProps = PropsWithChildren<{\n /** The handler to use for menu commands (and eventually toolbar commands). */\n commandHandler: CommandHandler;\n\n /**\n * The optional delegate to use to get the menu data. If not specified, the \"hamburger\" menu will\n * not display.\n */\n menuProvider?: MultiColumnMenuProvider;\n\n /** Optional unique identifier */\n id?: string;\n\n /** Additional css classes to help with unique styling of the toolbar */\n className?: string;\n}>;\n\nexport default function Toolbar({\n menuProvider,\n commandHandler,\n className,\n id,\n children,\n}: ToolbarProps) {\n // This ref will always be defined\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const containerRef = useRef(undefined!);\n\n return (\n
    \n \n \n {menuProvider ? (\n \n ) : undefined}\n {children ?
    {children}
    : undefined}\n \n
    \n
    \n );\n}\n","import React from 'react';\nimport { cva, type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst alertVariants = cva(\n 'tw-relative tw-w-full tw-rounded-lg tw-border tw-p-4 [&>svg~*]:tw-pl-7 [&>svg+div]:tw-translate-y-[-3px] [&>svg]:tw-absolute [&>svg]:tw-left-4 [&>svg]:tw-top-4 [&>svg]:tw-text-foreground',\n {\n variants: {\n variant: {\n default: 'tw-bg-background tw-text-foreground',\n destructive:\n 'tw-border-destructive/50 tw-text-destructive dark:tw-border-destructive [&>svg]:tw-text-destructive',\n },\n },\n defaultVariants: {\n variant: 'default',\n },\n },\n);\n\nconst Alert = React.forwardRef<\n HTMLDivElement,\n React.HTMLAttributes & VariantProps\n>(({ className, variant, ...props }, ref) => (\n
    \n));\nAlert.displayName = 'Alert';\n\nconst AlertTitle = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n {/* added because of https://github.com/jsx-eslint/eslint-plugin-jsx-a11y/blob/main/docs/rules/heading-has-content.md */}\n {props.children}{' '}\n \n ),\n);\nAlertTitle.displayName = 'AlertTitle';\n\nconst AlertDescription = React.forwardRef<\n HTMLParagraphElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n
    \n));\nAlertDescription.displayName = 'AlertDescription';\n\nexport { Alert, AlertTitle, AlertDescription };\n","import React from 'react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Card = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nCard.displayName = 'Card';\n\nconst CardHeader = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nCardHeader.displayName = 'CardHeader';\n\nconst CardTitle = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n {/* added because of https://github.com/jsx-eslint/eslint-plugin-jsx-a11y/blob/main/docs/rules/heading-has-content.md */}\n {props.children}\n \n ),\n);\nCardTitle.displayName = 'CardTitle';\n\nconst CardDescription = React.forwardRef<\n HTMLParagraphElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n

    \n));\nCardDescription.displayName = 'CardDescription';\n\nconst CardContent = React.forwardRef>(\n ({ className, ...props }, ref) => (\n

    \n ),\n);\nCardContent.displayName = 'CardContent';\n\nconst CardFooter = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nCardFooter.displayName = 'CardFooter';\n\nexport { Card, CardHeader, CardFooter, CardTitle, CardDescription, CardContent };\n","import { ComponentProps } from 'react';\nimport { toast as sonner, Toaster } from 'sonner';\n\ntype SonnerProps = ComponentProps;\n\nfunction Sonner({ ...props }: SonnerProps) {\n return (\n \n );\n}\n\n// The re-export of the sonner function was added manually\nexport { Sonner, sonner };\n","import React from 'react';\nimport * as SliderPrimitive from '@radix-ui/react-slider';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Slider = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n \n \n \n));\nSlider.displayName = SliderPrimitive.Root.displayName;\n\nexport { Slider };\n","import React from 'react';\nimport * as SwitchPrimitives from '@radix-ui/react-switch';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Switch = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n));\nSwitch.displayName = SwitchPrimitives.Root.displayName;\n\nexport { Switch };\n","import React from 'react';\nimport * as TabsPrimitive from '@radix-ui/react-tabs';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport const Tabs = TabsPrimitive.Root;\n\nexport type TabsListProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport type TabsTriggerProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport type TabsContentProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport const TabsList = React.forwardRef<\n React.ElementRef,\n TabsListProps\n>(({ className, ...props }, ref) => (\n \n));\nTabsList.displayName = TabsPrimitive.List.displayName;\n\nexport const TabsTrigger = React.forwardRef<\n React.ElementRef,\n TabsTriggerProps\n>(({ className, ...props }, ref) => (\n \n));\nTabsTrigger.displayName = TabsPrimitive.Trigger.displayName;\n\nexport const TabsContent = React.forwardRef<\n React.ElementRef,\n TabsContentProps\n>(({ className, ...props }, ref) => (\n \n));\nTabsContent.displayName = TabsPrimitive.Content.displayName;\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Download } from 'lucide-react';\n\ntype InstallButtonProps = {\n /** The installing boolean value determines the state of the button. */\n isInstalling: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n /** Optional text for the button. */\n buttonText?: string;\n} & ButtonProps;\n\n/**\n * The InstallButton component is a button designed for initiating installs. It includes visuals for\n * active installing and idle states.\n *\n * @param isInstalling The installing boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @param buttonText Optional text for the button.\n * @returns A install button.\n */\nexport default function InstallButton({\n isInstalling,\n handleClick,\n buttonText,\n className,\n ...props\n}: InstallButtonProps) {\n return (\n \n {isInstalling ? (\n \n ) : (\n <>\n \n {buttonText}\n \n )}\n \n );\n}\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\n\ntype EnableButtonProps = {\n /** The enabling boolean value determines the state of the button. */\n isEnabling: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n} & ButtonProps;\n\n/**\n * The EnableButton component is a button designed for initiating enabling of downloads. It includes\n * visuals for active enabling and idle states.\n *\n * @param isEnabling The enabling boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @returns A button that can be used to enable.\n */\nexport default function EnableButton({\n isEnabling,\n handleClick,\n className,\n ...props\n}: EnableButtonProps) {\n return (\n \n {isEnabling ? (\n <>\n \n Enabling...\n \n ) : (\n 'Enable'\n )}\n \n );\n}\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\n\ntype DisableButtonProps = {\n /** The disabling boolean value determines the state of the button. */\n isDisabling: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n} & ButtonProps;\n\n/**\n * The DisableButton component is a button designed for initiating disabling of downloads. It\n * includes visuals for active disabling and idle states.\n *\n * @param isDisabling The disabling boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @returns A button that can be used to disable.\n */\nexport default function DisableButton({\n isDisabling,\n handleClick,\n className,\n ...props\n}: DisableButtonProps) {\n return (\n \n {isDisabling ? (\n <>\n \n Disabling...\n \n ) : (\n 'Disable'\n )}\n \n );\n}\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\n\ntype UpdateButtonProps = {\n /** The updating boolean value determines the state of the button. */\n isUpdating: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n} & ButtonProps;\n\n/**\n * The UpdateButton component is a button designed for initiating updates for downloaded extensions.\n * It includes visuals for active updating and idle states.\n *\n * @param isUpdating The updating boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @returns A button that can be used to update.\n */\nexport default function UpdateButton({\n isUpdating,\n handleClick,\n className,\n ...props\n}: UpdateButtonProps) {\n return (\n \n {isUpdating ? (\n <>\n \n Updating...\n \n ) : (\n 'Update'\n )}\n \n );\n}\n","import { cn } from '@/utils/shadcn-ui.util';\nimport Markdown, { MarkdownToJSX } from 'markdown-to-jsx';\nimport { useMemo } from 'react';\n\ninterface MarkdownRendererProps {\n /** Optional unique identifier */\n id?: string;\n /** The markdown string to render */\n markdown: string;\n className?: string;\n /**\n * The [`target` attribute for `a` html\n * tags](https://developer.mozilla.org/en-US/docs/Web/HTML/Element/a#target). Defaults to not\n * adding a `target` to `a` tags\n */\n anchorTarget?: string;\n}\n\n/**\n * This component renders markdown content given a markdown string. It uses typography styles from\n * the platform.\n *\n * @param markdown The markdown string to render.\n * @param id Optional unique identifier\n * @returns A div containing the rendered markdown content.\n */\nexport default function MarkdownRenderer({\n id,\n markdown,\n className,\n anchorTarget,\n}: MarkdownRendererProps) {\n const options: MarkdownToJSX.Options = useMemo(\n () => ({\n overrides: {\n a: {\n props: {\n target: anchorTarget,\n },\n },\n },\n }),\n [anchorTarget],\n );\n return (\n
    \n {markdown}\n
    \n );\n}\n","import { Filter, ChevronDown } from 'lucide-react';\nimport { forwardRef } from 'react';\nimport { Button } from '@/components/shadcn-ui/button';\n\n/**\n * The FilterButton component is a button designed for initiating filtering of data. It is designed\n * to be used with the dropdown menu. It uses forwardRef to pass the button to the dropdown trigger\n * asChild.\n *\n * @returns A button that can be used to filter.\n */\nconst FilterButton = forwardRef((props, ref) => {\n return (\n \n \n Filter\n \n \n );\n});\n\nexport default FilterButton;\n","import {\n DropdownMenu,\n DropdownMenuTrigger,\n DropdownMenuContent,\n DropdownMenuLabel,\n DropdownMenuGroup,\n DropdownMenuCheckboxItem,\n DropdownMenuRadioItem,\n DropdownMenuSeparator,\n} from '@/components/shadcn-ui/dropdown-menu';\nimport FilterButton from './buttons/filter-button.component';\n\nexport enum DropdownMenuItemType {\n Check,\n Radio,\n}\n\nexport type DropdownItem = {\n /** The label is the text that will be displayed on the dropdown item. */\n label: string;\n /** The itemType determines the DropdownMenuItemType type as either Check or Radio. */\n itemType: DropdownMenuItemType;\n /** The onClick function is called when the item is clicked. */\n onClick: () => void;\n};\n\nexport type DropdownGroup = {\n /**\n * The label is the text that will be displayed on the dropdown group. It is used to categorize\n * the items in the group.\n */\n label: string;\n /** The items array contains the items that will be displayed in the dropdown group */\n items: DropdownItem[];\n};\n\nexport type FilterDropdownProps = {\n /** Object unique identifier */\n id?: string;\n /** The groups array contains the groups that will be displayed in the dropdown */\n groups: DropdownGroup[];\n}; // TODO: extend the props later\n\n/**\n * The FilterDropdown component is a dropdown designed for filtering content. It includes groups of\n * items that can be checkboxes or radio items.\n *\n * @param id Optional unique identifier\n * @param groups The groups array contains the groups that will be displayed in the dropdown\n * @returns A filter dropdown.\n */\nexport default function FilterDropdown({ id, groups }: FilterDropdownProps) {\n return (\n
    \n {/* TODO: remove this once the DropDown Menu shadcn has an id prop */}\n \n \n \n \n \n {groups.map((group) => (\n
    \n {group.label}\n \n {group.items.map((item) => (\n
    \n {item.itemType === DropdownMenuItemType.Check ? (\n \n {item.label}\n \n ) : (\n \n {item.label}\n \n )}\n
    \n ))}\n
    \n \n
    \n ))}\n
    \n
    \n
    \n );\n}\n","interface NoExtensionsFoundProps {\n /** Optional unique identifier */\n id?: string;\n /** The message to display */\n message: string;\n}\n/**\n * This component displays a message to the user when no extensions are found in the marketplace.\n *\n * @param id Optional unique identifier\n * @param message The message to display.\n * @returns {JSX.Element} - Returns the message component that displays the message to the user.\n */\nexport default function NoExtensionsFound({ id, message }: NoExtensionsFoundProps) {\n return (\n
    \n
    \n

    {message}

    \n
    \n
    \n );\n}\n","import { CircleHelp, Link as LucideLink, User } from 'lucide-react';\nimport { NumberFormat } from 'platform-bible-utils';\n\n/** Interface that stores the parameters passed to the More Info component */\ninterface MoreInfoProps {\n /** Optional unique identifier */\n id?: string;\n /** The category of the extension */\n category: string;\n /** The number of downloads for the extension */\n downloads: Record;\n /** The languages supported by the extension */\n languages: string[];\n /** The URL to the more info page of the extension */\n moreInfoUrl: string;\n}\n/**\n * This component displays the more info section of the extension which includes the category,\n * number of downloads, languages, and links to the website and support\n *\n * @param id Optional unique identifier\n * @param category The category of the extension\n * @param downloads The number of downloads for the extension\n * @param languages The languages supported by the extension\n * @param moreInfoUrl The URL to the more info page of the extension\n * @returns {JSX.Element} - Returns the more info component that displays the category, number of\n * downloads, languages, and links to the website and support\n */\nexport default function MoreInfo({\n id,\n category,\n downloads,\n languages,\n moreInfoUrl,\n}: MoreInfoProps) {\n /**\n * This constant formats the number of downloads into a more readable format.\n *\n * @example 1000 -> 1K\n *\n * @example 1000000 -> 1M\n *\n * @returns The formatted number of downloads\n */\n const numberFormatted = new NumberFormat('en', {\n notation: 'compact',\n compactDisplay: 'short',\n }).format(Object.values(downloads).reduce((a: number, b: number) => a + b, 0));\n\n /** This function scrolls the window to the bottom of the page. */\n const handleScrollToBottom = () => {\n window.scrollTo(0, document.body.scrollHeight);\n };\n\n return (\n \n
    \n
    \n {category}\n
    \n CATEGORY\n
    \n
    \n
    \n
    \n \n {numberFormatted}\n
    \n USERS\n
    \n
    \n
    \n
    \n {languages.slice(0, 3).map((locale) => (\n \n {locale.toUpperCase()}\n \n ))}\n
    \n {languages.length > 3 && (\n handleScrollToBottom()}\n className=\"tw-text-xs tw-text-gray-500 tw-underline\"\n >\n +{languages.length - 3} more languages\n \n )}\n
    \n
    \n
    \n \n Website\n \n \n \n Support\n \n \n
    \n
    \n );\n}\n","import { useState } from 'react';\n\nexport type VersionInformation = {\n /** Date the version was published */\n date: string;\n /** Description of the changes in the version */\n description: string;\n};\n\n/** Type to store the version history information */\nexport type VersionHistoryType = Record;\n\n/** Interface that stores the parameters passed to the Version History component */\ninterface VersionHistoryProps {\n /** Optional unique identifier */\n id?: string;\n /** Object containing the versions mapped with their information */\n versionHistory: VersionHistoryType;\n}\n\n/**\n * Component to render the version history information shown in the footer component. Lists the 5\n * most recent versions, with the options to show all versions by pressing a button.\n *\n * @param versionHistory Object containing the versions mapped with their information\n * @param id Optional unique identifier\n * @returns Rendered version history for the Footer component\n */\nexport default function VersionHistory({ id, versionHistory }: VersionHistoryProps) {\n const [showAllVersions, setShowAllVersions] = useState(false);\n const currentDate = new Date();\n\n /**\n * Function to format the time string for the version history in the form of 'X year(s) ago'.\n *\n * @param dateString ISO Date string to determine the time string from\n * @returns Formatted time string\n */\n function formatTimeString(dateString: string) {\n const date = new Date(dateString);\n const dateDiff = new Date(currentDate.getTime() - date.getTime());\n const yearDiff = dateDiff.getUTCFullYear() - 1970;\n const monthDiff = dateDiff.getUTCMonth();\n const dayDiff = dateDiff.getUTCDate() - 1;\n\n // Determines how long ago the version was published\n let timeString = '';\n if (yearDiff > 0) {\n timeString = `${yearDiff.toString()} year${yearDiff === 1 ? '' : 's'} ago`;\n } else if (monthDiff > 0) {\n timeString = `${monthDiff.toString()} month${monthDiff === 1 ? '' : 's'} ago`;\n } else if (dayDiff === 0) {\n timeString = 'today';\n } else {\n timeString = `${dayDiff.toString()} day${dayDiff === 1 ? '' : 's'} ago`;\n }\n\n return timeString;\n }\n\n // Sorts the version history by version number\n const sortedEntries = Object.entries(versionHistory).sort((a, b) => b[0].localeCompare(a[0]));\n\n return (\n
    \n

    What`s New

    \n
      \n {(showAllVersions ? sortedEntries : sortedEntries.slice(0, 5)).map((entry) => (\n
      \n
      \n
    • \n {entry[1].description}\n
    • \n
      \n
      \n
      Version {entry[0]}
      \n
      {formatTimeString(entry[1].date)}
      \n
      \n
      \n ))}\n
    \n {sortedEntries.length > 5 && (\n setShowAllVersions(!showAllVersions)}\n className=\"tw-text-xs tw-text-gray-500 tw-underline\"\n >\n {showAllVersions ? 'Show Less Version History' : 'Show All Version History'}\n \n )}\n
    \n );\n}\n","import { useMemo } from 'react';\nimport { formatBytes } from 'platform-bible-utils';\nimport VersionHistory, { VersionHistoryType } from './version-history.component';\n\n/** Interface to store the parameters passed to the Footer component */\ninterface FooterProps {\n /** Optional unique identifier */\n id?: string;\n /** Name of the publisher */\n publisherDisplayName: string;\n /** Size of the extension file in bytes */\n fileSize: number;\n /** List of language codes supported by the extension */\n locales: string[];\n /** Object containing the version history mapped with their information */\n versionHistory: VersionHistoryType;\n}\n\n/**\n * Component to render the footer for the extension details which contains information on the\n * publisher, version history, languages, and file size.\n *\n * @param id Optional unique identifier\n * @param publisherDisplayName Name of the publisher\n * @param fileSize Size of the extension file in bytes\n * @param locales List of language codes supported by the extension\n * @param versionHistory Object containing the version history mapped with their information\n * @returns The rendered Footer component\n */\nexport default function Footer({\n id,\n publisherDisplayName,\n fileSize,\n locales,\n versionHistory,\n}: FooterProps) {\n /** Formats the file size into a human-readable format */\n const formattedFileSize = useMemo(() => formatBytes(fileSize), [fileSize]);\n\n /**\n * This function gets the display names of the languages based on the language codes.\n *\n * @param codes The list of language codes\n * @returns The list of language names\n */\n const getLanguageNames = (codes: string[]) => {\n const displayNames = new Intl.DisplayNames(navigator.language, { type: 'language' });\n return codes.map((code) => displayNames.of(code));\n };\n\n const languageNames = getLanguageNames(locales);\n\n return (\n
    \n
    \n \n
    \n
    \n

    Information

    \n
    \n

    \n Publisher\n {publisherDisplayName}\n Size\n {formattedFileSize}\n

    \n
    \n

    \n Languages\n {languageNames.join(', ')}\n

    \n
    \n
    \n
    \n
    \n
    \n );\n}\n","import { PlatformEvent, PlatformEventHandler } from 'platform-bible-utils';\nimport { useEffect } from 'react';\n\n/**\n * Adds an event handler to an event so the event handler runs when the event is emitted. Use\n * `papi.network.getNetworkEvent` to use a networked event with this hook.\n *\n * @param event The event to subscribe to.\n *\n * - If event is a `PlatformEvent`, that event will be used\n * - If event is undefined, the callback will not be subscribed. Useful if the event is not yet\n * available for example\n *\n * @param eventHandler The callback to run when the event is emitted\n *\n * WARNING: MUST BE STABLE - const or wrapped in useCallback. The reference must not be updated\n * every render\n */\nconst useEvent = (\n event: PlatformEvent | undefined,\n eventHandler: PlatformEventHandler,\n) => {\n useEffect(() => {\n // Do nothing if the event is not provided (in case the event is not yet available, for example)\n if (!event) return () => {};\n\n const unsubscriber = event(eventHandler);\n return () => {\n unsubscriber();\n };\n }, [event, eventHandler]);\n};\nexport default useEvent;\n","import { useCallback, useEffect } from 'react';\nimport { PlatformEvent, PlatformEventAsync, PlatformEventHandler } from 'platform-bible-utils';\nimport usePromise from './use-promise.hook';\n\nconst noopUnsubscriber = () => false;\n\n/**\n * Adds an event handler to an asynchronously subscribing/unsubscribing event so the event handler\n * runs when the event is emitted. Use `papi.network.getNetworkEvent` to use a networked event with\n * this hook.\n *\n * @param event The asynchronously (un)subscribing event to subscribe to.\n *\n * - If event is a `PlatformEvent` or `PlatformEventAsync`, that event will be used\n * - If event is undefined, the callback will not be subscribed. Useful if the event is not yet\n * available for example\n *\n * @param eventHandler The callback to run when the event is emitted\n *\n * WARNING: MUST BE STABLE - const or wrapped in useCallback. The reference must not be updated\n * every render\n */\nconst useEventAsync = (\n event: PlatformEvent | PlatformEventAsync | undefined,\n eventHandler: PlatformEventHandler,\n) => {\n // Subscribe to the event asynchronously\n const [unsubscribe] = usePromise(\n useCallback(async () => {\n // Do nothing if the event is not provided (in case the event is not yet available, for example)\n if (!event) return noopUnsubscriber;\n\n // Wrap subscribe and unsubscribe in promises to allow normal events to be used as well\n const unsub = await Promise.resolve(event(eventHandler));\n return async () => unsub();\n }, [eventHandler, event]),\n noopUnsubscriber,\n // We want the unsubscriber to return to default value immediately upon changing subscription\n // So the useEffect below will unsubscribe asap\n { preserveValue: false },\n );\n\n // Unsubscribe from the event asynchronously (but we aren't awaiting the unsub)\n useEffect(() => {\n return () => {\n if (unsubscribe !== noopUnsubscriber) {\n unsubscribe();\n }\n };\n }, [unsubscribe]);\n};\n\nexport default useEventAsync;\n"],"names":["twMergeCustom","extendTailwindMerge","cn","inputs","clsx","Input","React","className","type","props","ref","jsx","BookChapterInput","forwardRef","handleSearch","handleKeyDown","handleOnClick","handleSubmit","jsxs","ShadInput","event","e","History","P","R","s","n","N","B","O","S","K","g","k","x","T","X","V","w","L","G","A","H","C","I","y","q","U","m","l","h","c","E","D","i","a","o","u","v","f","d","b","J","DropdownMenu","DropdownMenuPrimitive","DropdownMenuTrigger","DropdownMenuGroup","DropdownMenuPortal","DropdownMenuSub","DropdownMenuRadioGroup","DropdownMenuSubTrigger","inset","children","ChevronRight","DropdownMenuSubContent","DropdownMenuContent","sideOffset","DropdownMenuItem","DropdownMenuCheckboxItem","checked","Check","DropdownMenuRadioItem","Circle","DropdownMenuLabel","DropdownMenuSeparator","DropdownMenuShortcut","BookMenuItem","bookId","handleSelectBook","isSelected","handleHighlightBook","bookType","ShadDropdownMenuItem","Canon","ChapterSelect","handleSelectChapter","endChapter","activeChapter","highlightedChapter","handleHighlightedChapter","chapters","_","handleMouse","useCallback","chapterNumber","chapter","GoToMenuItem","handleSort","handleLocationHistory","handleBookmarks","ShadDropdownMenuLabel","ArrowDownWideNarrow","Clock","Bookmark","ALL_BOOK_IDS","BOOK_TYPE_LABELS","BOOK_TYPE_ARRAY","SCROLL_OFFSET","SEARCH_QUERY_FORMATS","fetchGroupedBooks","fetchEndChapter","getChaptersForBook","getAllEnglishNames","isValidBookEnglishName","bookName","getBookIdFromEnglishName","formattedBookName","BookChapterControl","scrRef","searchQuery","setSearchQuery","useState","selectedBookId","setSelectedBookId","setHighlightedChapter","highlightedBookId","setHighlightedBookId","isContentOpen","setIsContentOpen","isContentOpenDelayed","setIsContentOpenDelayed","inputRef","useRef","contentRef","menuItemRef","fetchFilteredBooks","englishNameLowerCase","normalizedQuery","handleSearchInput","searchString","shouldPreventAutoClosing","controlMenuState","open","updateReference","shouldClose","verse","handleInputSubmit","format","matches","book","englishName","handleKeyDownInput","handleKeyDownContent","key","handleKeyDownMenuItem","chapterOffSet","useEffect","useLayoutEffect","scrollTimeout","scrollPosition","ShadDropdownMenu","ShadDropdownMenuTrigger","ShadDropdownMenuContent","bookTypeIndex","element","ShadDropdownMenuSeparator","buttonVariants","cva","Button","variant","size","asChild","Slot","labelVariants","Label","LabelPrimitive","RadioGroup","RadioGroupPrimitive","RadioGroupItem","Popover","PopoverPrimitive","PopoverTrigger","PopoverContent","align","DialogPortal","DialogPrimitive","DialogOverlay","DialogContent","DialogTitle","DialogDescription","Command","CommandPrimitive","CommandInput","Search","CommandList","CommandEmpty","CommandGroup","CommandSeparator","CommandItem","getOptionLabelDefault","option","ComboBox","id","options","buttonClassName","popoverContentClassName","value","onChange","getOptionLabel","buttonPlaceholder","textPlaceholder","commandEmptyMessage","buttonVariant","dir","isDisabled","setOpen","ChevronsUpDown","ChapterRangeSelector","startChapter","handleSelectStartChapter","handleSelectEndChapter","chapterCount","chapterOptions","useMemo","index","Fragment","BookSelectionMode","BOOK_SELECTOR_STRING_KEYS","localizeString","strings","BookSelector","handleBookSelectionModeChange","currentBookName","onSelectBooks","selectedBookIds","localizedStrings","currentBookText","chooseText","chooseBooksText","bookSelectionMode","setBookSelectionMode","onSelectionModeChange","newMode","DataTableViewOptions","table","FilterIcon","column","Select","SelectPrimitive","SelectGroup","SelectValue","SelectTrigger","ChevronDown","SelectScrollUpButton","ChevronUp","SelectScrollDownButton","SelectContent","position","SelectLabel","SelectItem","SelectSeparator","DataTablePagination","pageSize","ArrowLeftIcon","ChevronLeftIcon","ChevronRightIcon","ArrowRightIcon","Table","stickyHeader","TableHeader","TableBody","TableFooter","TableRow","TableHead","TableCell","TableCaption","DataTable","columns","data","enablePagination","showPaginationControls","showColumnVisibilityControls","onRowClickHandler","sorting","setSorting","columnFilters","setColumnFilters","columnVisibility","setColumnVisibility","rowSelection","setRowSelection","useReactTable","getCoreRowModel","getPaginationRowModel","getSortedRowModel","getFilteredRowModel","headerGroup","header","flexRender","_a","row","cell","OccurrencesTable","occurrenceData","setScriptureReference","referenceHeaderText","occurrenceHeaderText","occurrences","uniqueOccurrences","occurrence","uniqueOccurrence","deepEqual","Checkbox","CheckboxPrimitive","getLinesFromUSFM","text","getNumberFromUSFM","regex","match","getBookNumFromId","getStatusForItem","item","approvedItems","unapprovedItems","toggleVariants","Toggle","TogglePrimitive","ToggleGroupContext","ToggleGroup","ToggleGroupPrimitive","ToggleGroupItem","context","getSortingIcon","sortDirection","ArrowUpIcon","ArrowDownIcon","ArrowUpDownIcon","inventoryItemColumn","itemLabel","inventoryAdditionalItemColumn","additionalItemLabel","additionalItemIndex","inventoryCountColumn","countLabel","statusChangeHandler","changedItems","newStatus","onApprovedItemsChange","onUnapprovedItemsChange","newApprovedItems","validItem","newUnapprovedItems","unapprovedItem","inventoryStatusColumn","statusLabel","status","CircleCheckIcon","CircleXIcon","CircleHelpIcon","INVENTORY_STRING_KEYS","filterItemData","itemData","statusFilter","textFilter","filteredItemData","createTableData","scriptureRef","itemRegex","tableData","currentBook","currentChapter","currentVerse","line","items","itemIndex","existingItem","tableEntry","newReference","substring","newItem","Inventory","scriptureReference","extractItems","additionalItemsLabels","scope","onScopeChange","allItemsText","approvedItemsText","unapprovedItemsText","unknownItemsText","scopeBookText","scopeChapterText","scopeVerseText","filterText","showAdditionalItemsText","showAdditionalItems","setShowAdditionalItems","setStatusFilter","setTextFilter","selectedItem","setSelectedItem","reducedTableData","newTableData","firstItem","existingEntry","newTableEntry","filteredTableData","allColumns","numberOfAdditionalItems","additionalColumns","_b","rowClickHandler","newSelection","handleScopeChange","handleStatusFilterChange","SearchBar","onSearch","placeholder","isFullWidth","handleInputChange","VerticalTabs","TabsPrimitive","VerticalTabsList","VerticalTabsTrigger","VerticalTabsContent","TabNavigationContentSearch","tabList","searchPlaceholder","headerTitle","isSearchBarFullWidth","direction","tab","Separator","orientation","decorative","SeparatorPrimitive","Sheet","SheetPrimitive","SheetPortal","SheetOverlay","sheetVariants","SheetContent","side","SheetTitle","SheetDescription","Skeleton","TooltipProvider","TooltipPrimitive","Tooltip","TooltipTrigger","TooltipContent","MOBILE_BREAKPOINT","useIsMobile","isMobile","setIsMobile","mql","SIDEBAR_COOKIE_NAME","SIDEBAR_COOKIE_MAX_AGE","SIDEBAR_WIDTH","SIDEBAR_WIDTH_MOBILE","SIDEBAR_WIDTH_ICON","SIDEBAR_KEYBOARD_SHORTCUT","SidebarContext","useSidebar","SidebarProvider","defaultOpen","openProp","setOpenProp","style","openMobile","setOpenMobile","_open","_setOpen","isOpen","openState","toggleSidebar","state","contextValue","Sidebar","collapsible","SidebarTrigger","onClick","PanelLeft","SidebarRail","SidebarInset","SidebarInput","SidebarHeader","SidebarFooter","SidebarSeparator","SidebarContent","SidebarGroup","SidebarGroupLabel","SidebarGroupAction","SidebarGroupContent","SidebarMenu","SidebarMenuItem","sidebarMenuButtonVariants","SidebarMenuButton","isActive","tooltip","Comp","button","SidebarMenuAction","showOnHover","SidebarMenuBadge","SidebarMenuSkeleton","showIcon","width","SidebarMenuSub","SidebarMenuSubItem","SidebarMenuSubButton","SettingsSidebar","extensionLabels","projectOptions","handleSelectSidebarItem","selectedSidebarItem","extensionsSidebarGroupLabel","projectsSidebarGroupLabel","handleSelectItem","projectId","getProjectNameFromProjectId","project","getIsActive","label","selectedProjectName","SettingsSidebarContentSearch","scrBookColId","scrRefColId","typeColId","detailsColId","defaultScrRefColumnName","defaultScrBookGroupName","defaultTypeColumnName","defaultDetailsColumnName","getColumns","colInfo","showSourceColumn","showSrcCol","info","formatScrRef","compareScrRefs","toRefOrRange","scriptureSelection","offsetStart","offsetEnd","scrRefToBBBCCCVVV","getRowKey","ScriptureResultsViewer","sources","showColumnHeaders","scriptureReferenceColumnName","scriptureBookGroupName","typeColumnName","detailsColumnName","onRowSelected","grouping","setGrouping","scriptureResults","source","getExpandedRowModel","getGroupedRowModel","selectedRows","keys","selectedRow","scrBookGroupName","typeGroupName","groupingOptions","handleSelectChange","selectedGrouping","handleRowClick","getEvenOrOddBandingStyle","getIndent","groupingState","rowIndex","ChevronLeft","DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS","getLocalizeKeyForScrollGroupId","ScrollGroupSelector","availableScrollGroupIds","scrollGroupId","onChangeScrollGroupId","localizedStringsDefaulted","localizedStringKey","localizedStringValue","newScrollGroupString","scrollGroupOptionId","SettingsList","SettingsListItem","primary","secondary","isLoading","loadingMessage","SettingsListHeader","includeSeparator","Checklist","listItems","selectedListItems","handleSelectListItem","createLabel","_interopRequireDefault","obj","module","chainPropTypes","propType1","propType2","args","_extends","target","isPlainObject","prototype","deepClone","output","deepmerge","p","r","t","z","reactIs_production_min","hasSymbol","REACT_ELEMENT_TYPE","REACT_PORTAL_TYPE","REACT_FRAGMENT_TYPE","REACT_STRICT_MODE_TYPE","REACT_PROFILER_TYPE","REACT_PROVIDER_TYPE","REACT_CONTEXT_TYPE","REACT_ASYNC_MODE_TYPE","REACT_CONCURRENT_MODE_TYPE","REACT_FORWARD_REF_TYPE","REACT_SUSPENSE_TYPE","REACT_SUSPENSE_LIST_TYPE","REACT_MEMO_TYPE","REACT_LAZY_TYPE","REACT_BLOCK_TYPE","REACT_FUNDAMENTAL_TYPE","REACT_RESPONDER_TYPE","REACT_SCOPE_TYPE","isValidElementType","typeOf","object","$$typeof","$$typeofType","AsyncMode","ConcurrentMode","ContextConsumer","ContextProvider","Element","ForwardRef","Lazy","Memo","Portal","Profiler","StrictMode","Suspense","hasWarnedAboutDeprecatedIsAsyncMode","isAsyncMode","isConcurrentMode","isContextConsumer","isContextProvider","isElement","isForwardRef","isFragment","isLazy","isMemo","isPortal","isProfiler","isStrictMode","isSuspense","reactIs_development","reactIsModule","require$$0","require$$1","getOwnPropertySymbols","hasOwnProperty","propIsEnumerable","toObject","val","shouldUseNative","test1","test2","order2","test3","letter","objectAssign","from","to","symbols","ReactPropTypesSecret","ReactPropTypesSecret_1","has","printWarning","loggedTypeFailures","message","checkPropTypes","typeSpecs","values","location","componentName","getStack","typeSpecName","error","err","ex","stack","checkPropTypes_1","ReactIs","assign","require$$2","require$$3","require$$4","emptyFunctionThatReturnsNull","factoryWithTypeCheckers","isValidElement","throwOnDirectAccess","ITERATOR_SYMBOL","FAUX_ITERATOR_SYMBOL","getIteratorFn","maybeIterable","iteratorFn","ANONYMOUS","ReactPropTypes","createPrimitiveTypeChecker","createAnyTypeChecker","createArrayOfTypeChecker","createElementTypeChecker","createElementTypeTypeChecker","createInstanceTypeChecker","createNodeChecker","createObjectOfTypeChecker","createEnumTypeChecker","createUnionTypeChecker","createShapeTypeChecker","createStrictShapeTypeChecker","is","PropTypeError","createChainableTypeChecker","validate","manualPropTypeCallCache","manualPropTypeWarningCount","checkType","isRequired","propName","propFullName","secret","cacheKey","chainedCheckType","expectedType","propValue","propType","getPropType","preciseType","getPreciseType","typeChecker","expectedClass","expectedClassName","actualClassName","getClassName","expectedValues","valuesString","arrayOfTypeCheckers","checker","getPostfixForTypeWarning","expectedTypes","checkerResult","expectedTypesMessage","isNode","invalidValidatorError","shapeTypes","allKeys","iterator","step","entry","isSymbol","emptyFunction","emptyFunctionWithReset","factoryWithThrowingShims","shim","getShim","propTypesModule","isClassComponent","elementType","acceptingRef","safePropName","warningHint","elementAcceptingRef","PropTypes","elementAcceptingRef$1","specialProperty","exactProp","propTypes","unsupportedProps","prop","formatMuiErrorMessage","code","url","REACT_SERVER_CONTEXT_TYPE","REACT_OFFSCREEN_TYPE","enableScopeAPI","enableCacheElement","enableTransitionTracing","enableLegacyHidden","enableDebugTracing","REACT_MODULE_REFERENCE","SuspenseList","hasWarnedAboutDeprecatedIsConcurrentMode","isSuspenseList","fnNameMatchRegex","getFunctionName","fn","getFunctionComponentName","Component","fallback","getWrappedName","outerType","innerType","wrapperName","functionName","getDisplayName","HTMLElementType","refType","refType$1","capitalize","string","_formatMuiErrorMessage","createChainedFunction","funcs","acc","func","debounce","wait","timeout","debounced","later","deprecatedPropType","validator","reason","componentNameSafe","propFullNameSafe","isMuiElement","muiNames","_muiName","_element$type","ownerDocument","node","ownerWindow","requirePropFactory","componentNameInError","prevPropTypes","requiredProp","defaultTypeChecker","typeCheckerResult","setRef","useEnhancedEffect","useEnhancedEffect$1","globalId","useGlobalId","idOverride","defaultId","setDefaultId","maybeReactUseId","useId","reactId","unsupportedProp","useControlled","controlled","defaultProp","name","isControlled","valueState","setValue","defaultValue","setValueIfUncontrolled","newValue","useEventCallback","useForkRef","refs","instance","UNINITIALIZED","useLazyRef","init","initArg","EMPTY","useOnMount","Timeout","delay","useTimeout","hadKeyboardEvent","hadFocusVisibleRecently","hadFocusVisibleRecentlyTimeout","inputTypesWhitelist","focusTriggersKeyboardModality","tagName","handlePointerDown","handleVisibilityChange","prepare","doc","isFocusVisible","useIsFocusVisible","isFocusVisibleRef","handleBlurVisible","handleFocusVisible","resolveProps","defaultProps","defaultSlotProps","slotProps","slotPropName","composeClasses","slots","getUtilityClass","classes","slot","utilityClass","defaultGenerator","createClassNameGenerator","generate","generator","ClassNameGenerator","ClassNameGenerator$1","globalStateClasses","generateUtilityClass","globalStatePrefix","globalStateClass","generateUtilityClasses","result","clamp","min","max","_objectWithoutPropertiesLoose","excluded","sourceKeys","_excluded","sortBreakpointsValues","breakpointsAsArray","breakpoint1","breakpoint2","createBreakpoints","breakpoints","unit","other","sortedValues","up","down","between","start","end","endIndex","only","not","keyIndex","shape","shape$1","responsivePropType","responsivePropType$1","merge","defaultBreakpoints","handleBreakpoints","styleFromPropValue","theme","themeBreakpoints","breakpoint","mediaKey","cssKey","createEmptyBreakpointObject","breakpointsInput","_breakpointsInput$key","breakpointStyleKey","removeUnusedBreakpoints","breakpointKeys","breakpointOutput","getPath","path","checkVars","getStyleValue","themeMapping","transform","propValueFinal","userValue","cssProperty","themeKey","memoize","cache","arg","properties","directions","aliases","getCssProperties","property","marginKeys","paddingKeys","spacingKeys","createUnaryUnit","_getPath","themeSpacing","abs","createUnarySpacing","getValue","transformer","transformed","getStyleFromPropValue","cssProperties","resolveCssProperty","margin","padding","createSpacing","spacingInput","spacing","argsInput","argument","compose","styles","handlers","borderTransform","createBorderStyle","border","borderTop","borderRight","borderBottom","borderLeft","borderColor","borderTopColor","borderRightColor","borderBottomColor","borderLeftColor","outline","outlineColor","borderRadius","gap","columnGap","rowGap","gridColumn","gridRow","gridAutoFlow","gridAutoColumns","gridAutoRows","gridTemplateColumns","gridTemplateRows","gridTemplateAreas","gridArea","paletteTransform","color","bgcolor","backgroundColor","sizingTransform","maxWidth","_props$theme","_props$theme2","breakpointsValues","minWidth","height","maxHeight","minHeight","boxSizing","defaultSxConfig","defaultSxConfig$1","objectsHaveSameKeys","objects","union","callIfFn","maybeFn","unstable_createStyleFunctionSx","getThemeValue","config","styleFunctionSx","_theme$unstable_sxCon","sx","traverse","sxInput","sxObject","emptyBreakpoints","breakpointsKeys","css","styleKey","styleFunctionSx$1","applyStyles","createTheme","paletteInput","shapeInput","muiTheme","isObjectEmpty","useTheme","defaultTheme","contextTheme","ThemeContext","systemDefaultTheme","useThemeWithoutDefault","_excluded2","_excluded3","isEmpty","isStringTag","tag","shouldForwardProp","lowercaseFirstLetter","resolveTheme","themeId","defaultOverridesResolver","processStyleArg","callableStyle","_ref","ownerState","resolvedStylesArg","resolvedStyle","variants","isMatch","createStyled","input","rootShouldForwardProp","slotShouldForwardProp","systemSx","inputOptions","processStyles","componentSlot","inputSkipVariantsResolver","inputSkipSx","overridesResolver","skipVariantsResolver","skipSx","shouldForwardPropOption","defaultStyledResolver","styledEngineStyled","transformStyleArg","stylesArg","muiStyledResolver","styleArg","expressions","transformedStyleArg","expressionsWithDefaultTheme","styleOverrides","resolvedStyleOverrides","slotKey","slotStyle","_theme$components","themeVariants","numOfCustomFnsApplied","placeholders","displayName","getThemeProps","params","useThemeProps","clampWrapper","hexToRgb","re","colors","decomposeColor","marker","colorSpace","recomposeColor","hslToRgb","rgb","getLuminance","getContrastRatio","foreground","background","lumA","lumB","alpha","darken","coefficient","lighten","createMixins","mixins","common","common$1","grey","grey$1","purple","purple$1","red","red$1","orange","orange$1","blue","blue$1","lightBlue","lightBlue$1","green","green$1","light","dark","addLightOrDark","intent","shade","tonalOffset","tonalOffsetLight","tonalOffsetDark","getDefaultPrimary","mode","getDefaultSecondary","getDefaultError","getDefaultInfo","getDefaultSuccess","getDefaultWarning","createPalette","palette","contrastThreshold","success","warning","getContrastText","contrastText","contrast","augmentColor","mainShade","lightShade","darkShade","modes","round","caseAllCaps","defaultFontFamily","createTypography","typography","fontFamily","fontSize","fontWeightLight","fontWeightRegular","fontWeightMedium","fontWeightBold","htmlFontSize","allVariants","pxToRem2","coef","pxToRem","buildVariant","fontWeight","lineHeight","letterSpacing","casing","shadowKeyUmbraOpacity","shadowKeyPenumbraOpacity","shadowAmbientShadowOpacity","createShadow","px","shadows","shadows$1","easing","duration","formatMs","milliseconds","getAutoHeightDuration","constant","createTransitions","inputTransitions","mergedEasing","mergedDuration","durationOption","easingOption","isString","isNumber","animatedProp","zIndex","zIndex$1","mixinsInput","transitionsInput","typographyInput","systemTheme","systemCreateTheme","stateClasses","component","child","stateClass","defaultTheme$1","THEME_ID","systemUseThemeProps","styled","styled$1","getSvgIconUtilityClass","useUtilityClasses","SvgIconRoot","_theme$transitions","_theme$transitions$cr","_theme$transitions2","_theme$typography","_theme$typography$pxT","_theme$typography2","_theme$typography2$px","_theme$typography3","_theme$typography3$px","_palette$ownerState$c","_palette","_palette2","_palette3","SvgIcon","inProps","htmlColor","inheritViewBox","titleAccess","viewBox","hasSvgAsChild","more","_jsxs","_jsx","SvgIcon$1","createSvgIcon","unstable_ClassNameGenerator","exports","_utils","ArrowRight","default_1","_createSvgIcon","_jsxRuntime","isHostComponent","appendOwnerState","otherProps","defaultContextValue","ClassNameConfiguratorContext","useClassNamesOverride","disableDefaultClasses","extractEventHandlers","excludeKeys","resolveComponentProps","componentProps","slotState","omitEventHandlers","mergeSlotProps","parameters","getSlotProps","additionalProps","externalSlotProps","externalForwardedProps","joinedClasses","mergedStyle","eventHandlers","componentsPropsWithoutEventHandlers","otherPropsWithoutEventHandlers","internalSlotProps","useSlotProps","_parameters$additiona","skipResolvingSlotProps","rest","resolvedComponentsProps","mergedProps","internalRef","GLOBAL_CLASS_PREFIX","buildStateClass","buildSlotClass","getContainer","container","forwardedRef","disablePortal","mountNode","setMountNode","handleRef","newProps","ReactDOM","top","bottom","right","left","auto","basePlacements","clippingParents","viewport","popper","reference","variationPlacements","placement","placements","beforeRead","read","afterRead","beforeMain","main","afterMain","beforeWrite","write","afterWrite","modifierPhases","getNodeName","getWindow","OwnElement","isHTMLElement","isShadowRoot","attributes","effect","_ref2","initialStyles","styleProperties","attribute","applyStyles$1","getBasePlacement","getUAString","uaData","isLayoutViewport","getBoundingClientRect","includeScale","isFixedStrategy","clientRect","scaleX","scaleY","visualViewport","addVisualOffsets","getLayoutRect","contains","parent","rootNode","next","getComputedStyle","isTableElement","getDocumentElement","getParentNode","getTrueOffsetParent","getContainingBlock","isFirefox","isIE","elementCss","currentNode","getOffsetParent","window","offsetParent","getMainAxisFromPlacement","within","mathMax","mathMin","withinMaxClamp","getFreshSideObject","mergePaddingObject","paddingObject","expandToHashMap","hashMap","toPaddingObject","arrow","_state$modifiersData$","arrowElement","popperOffsets","basePlacement","axis","isVertical","len","arrowRect","minProp","maxProp","endDiff","startDiff","arrowOffsetParent","clientSize","centerToReference","center","offset","axisProp","_options$element","arrow$1","getVariation","unsetSides","roundOffsetsByDPR","win","dpr","mapToStyles","_Object$assign2","popperRect","variation","offsets","gpuAcceleration","adaptive","roundOffsets","isFixed","_offsets$x","_offsets$y","_ref3","hasX","hasY","sideX","sideY","heightProp","widthProp","offsetY","offsetX","commonStyles","_ref4","_Object$assign","computeStyles","_ref5","_options$gpuAccelerat","_options$adaptive","_options$roundOffsets","computeStyles$1","passive","_options$scroll","scroll","_options$resize","resize","scrollParents","scrollParent","eventListeners","hash","getOppositePlacement","matched","getOppositeVariationPlacement","getWindowScroll","scrollLeft","scrollTop","getWindowScrollBarX","getViewportRect","strategy","html","layoutViewport","getDocumentRect","_element$ownerDocumen","winScroll","body","isScrollParent","_getComputedStyle","overflow","overflowX","overflowY","getScrollParent","listScrollParents","list","isBody","updatedList","rectToClientRect","rect","getInnerBoundingClientRect","getClientRectFromMixedType","clippingParent","getClippingParents","canEscapeClipping","clipperElement","getClippingRect","boundary","rootBoundary","mainClippingParents","firstClippingParent","clippingRect","accRect","computeOffsets","commonX","commonY","mainAxis","detectOverflow","_options","_options$placement","_options$strategy","_options$boundary","_options$rootBoundary","_options$elementConte","elementContext","_options$altBoundary","altBoundary","_options$padding","altContext","clippingClientRect","referenceClientRect","popperClientRect","elementClientRect","overflowOffsets","offsetData","multiply","computeAutoPlacement","flipVariations","_options$allowedAutoP","allowedAutoPlacements","allPlacements","allowedPlacements","overflows","getExpandedFallbackPlacements","oppositePlacement","flip","_options$mainAxis","checkMainAxis","_options$altAxis","checkAltAxis","specifiedFallbackPlacements","_options$flipVariatio","preferredPlacement","isBasePlacement","fallbackPlacements","referenceRect","checksMap","makeFallbackChecks","firstFittingPlacement","_basePlacement","isStartVariation","mainVariationSide","altVariationSide","checks","check","numberOfChecks","_loop","_i","fittingPlacement","_ret","flip$1","getSideOffsets","preventedOffsets","isAnySideFullyClipped","hide","referenceOverflow","popperAltOverflow","referenceClippingOffsets","popperEscapeOffsets","isReferenceHidden","hasPopperEscaped","hide$1","distanceAndSkiddingToXY","rects","invertDistance","skidding","distance","_options$offset","_data$state$placement","offset$1","popperOffsets$1","getAltAxis","preventOverflow","_options$tether","tether","_options$tetherOffset","tetherOffset","altAxis","tetherOffsetValue","normalizedTetherOffsetValue","offsetModifierState","_offsetModifierState$","mainSide","altSide","additive","minLen","maxLen","arrowPaddingObject","arrowPaddingMin","arrowPaddingMax","arrowLen","minOffset","maxOffset","clientOffset","offsetModifierValue","tetherMin","tetherMax","preventedOffset","_offsetModifierState$2","_mainSide","_altSide","_offset","_len","_min","_max","isOriginSide","_offsetModifierValue","_tetherMin","_tetherMax","_preventedOffset","preventOverflow$1","getHTMLElementScroll","getNodeScroll","isElementScaled","getCompositeRect","elementOrVirtualElement","isOffsetParentAnElement","offsetParentIsScaled","documentElement","order","modifiers","map","visited","modifier","sort","requires","dep","depModifier","orderModifiers","orderedModifiers","phase","pending","resolve","mergeByName","merged","current","existing","DEFAULT_OPTIONS","areValidElements","_key","popperGenerator","generatorOptions","_generatorOptions","_generatorOptions$def","defaultModifiers","_generatorOptions$def2","defaultOptions","effectCleanupFns","isDestroyed","setOptionsAction","cleanupModifierEffects","runModifierEffects","_state$elements","_state$orderedModifie","_state$orderedModifie2","_ref$options","cleanupFn","noopFn","createPopper","COMPONENT_NAME","getPopperUtilityClass","flipPlacement","resolveAnchorEl","anchorEl","isVirtualElement","defaultPopperOptions","PopperTooltip","_slots$root","initialPlacement","popperOptions","popperRefProp","TransitionProps","tooltipRef","ownRef","popperRef","handlePopperRef","handlePopperRefRef","rtlPlacement","setPlacement","resolvedAnchorElement","setResolvedAnchorElement","handlePopperUpdate","box","popperModifiers","childProps","Root","rootProps","Popper","containerProp","keepMounted","transition","exited","setExited","handleEnter","handleExited","resolvedAnchorEl","display","transitionProps","useThemeSystem","_setPrototypeOf","_inheritsLoose","subClass","superClass","setPrototypeOf","timeoutsShape","TransitionGroupContext","forceReflow","UNMOUNTED","EXITED","ENTERING","ENTERED","EXITING","Transition","_React$Component","_this","parentGroup","appear","initialStatus","prevState","nextIn","_proto","prevProps","nextStatus","exit","enter","mounting","_this2","appearing","maybeNode","maybeAppearing","timeouts","enterTimeout","_this3","nextState","callback","_this4","active","handler","doesNotHaveTimeoutOrListener","maybeNextCallback","_this$props","pt","noop","Transition$1","reflow","getTransitionProps","_style$transitionDura","_style$transitionTimi","getScale","isWebKit154","Grow","addEndListener","inProp","onEnter","onEntered","onEntering","onExit","onExited","onExiting","TransitionComponent","timer","autoTimeout","nodeRef","normalizedTransitionCallback","maybeIsAppearing","handleEntering","isAppearing","transitionDuration","transitionTimingFunction","handleEntered","handleExiting","handleExit","Grow$1","PopperRoot","BasePopper","components","componentsProps","RootComponent","Popper$1","getTooltipUtilityClass","tooltipClasses","tooltipClasses$1","disableInteractive","touch","TooltipPopper","TooltipTooltip","TooltipArrow","hystersisOpen","hystersisTimer","cursorPosition","composeEventHandler","eventHandler","_slots$popper","_slots$transition","_slots$tooltip","_slots$arrow","_slotProps$popper","_ref6","_slotProps$popper2","_slotProps$transition","_slotProps$tooltip","_ref7","_slotProps$tooltip2","_slotProps$arrow","_ref8","_slotProps$arrow2","childrenProp","describeChild","disableFocusListener","disableHoverListener","disableInteractiveProp","disableTouchListener","enterDelay","enterNextDelay","enterTouchDelay","followCursor","idProp","leaveDelay","leaveTouchDelay","onClose","onOpen","PopperComponentProp","PopperProps","title","TransitionComponentProp","isRtl","childNode","setChildNode","arrowRef","setArrowRef","ignoreNonTouchEvents","closeTimer","enterTimer","leaveTimer","touchTimer","setOpenState","prevUserSelect","stopTouchInteraction","handleOpen","handleClose","handleLeave","focusVisibleRef","setChildIsFocusVisible","handleBlur","handleFocus","detectTouchStart","childrenProps","handleMouseOver","handleMouseLeave","handleTouchStart","handleTouchEnd","nativeEvent","handleMouseMove","nameOrDescProps","titleIsString","interactiveWrapperListeners","_PopperProps$popperOp","tooltipModifiers","PopperComponent","TooltipComponent","ArrowComponent","popperProps","tooltipProps","tooltipArrowProps","TransitionPropsInner","Tooltip$1","getIcon","icon","menuLabel","leading","MuiListItemIcon","MenuItem","allowForLeadingIcons","iconPathBefore","iconPathAfter","hasAutoFocus","isDense","isSubMenuParent","hasDisabledGutters","hasDivider","focusVisibleClassName","menuItem","MuiMenuItem","MuiListItemText","getAllGroups","menuDefinition","SubMenu","setAnchorEl","parentMenuItem","parentItemProps","handleParentMenuItemClick","renderSubMenuItems","includedGroups","group","GroupedMenuItemList","Menu","getOrderedGroupItems","groupId","allItems","menuProps","commandHandler","groupsToInclude","sortedGroups","itemArray","allowSpaceForLeadingIcons","createMenuItemProps","isLastItemInGroup","divKey","itemInfo","menuItemProps","TopLevelMenu","columnId","MenuColumn","metadata","Grid","List","GridMenu","multiColumnMenu","sortedColumns","columnNumbers","columnName","col","getUsePromiseOptionsDefaults","usePromise","promiseFactoryCallback","defaultValueRef","optionsDefaultedRef","setIsLoading","promiseIsCurrent","MenuIcon","HamburgerMenuButton","menuProvider","normalMenu","fullMenu","containerRef","ariaLabelPrefix","isMenuOpen","setMenuOpen","showFullMenu","setShowFullMenu","handleMenuItemClick","handleMenuButtonClick","prevIsOpen","isOpening","menuCommandHandler","command","setOffset","normalMenuData","fullMenuData","menu","IconButton","Drawer","isTooltipSuppressed","adjustMarginToAlignToEdge","MuiIconButton","Spinner","LoaderCircle","TextField","hasError","helperText","onFocus","onBlur","ShadLabel","Toolbar","AppBar","MuiToolbar","alertVariants","Alert","AlertTitle","AlertDescription","Card","CardHeader","CardTitle","CardDescription","CardContent","CardFooter","Sonner","Toaster","Slider","SliderPrimitive","Switch","SwitchPrimitives","Tabs","TabsList","TabsTrigger","TabsContent","InstallButton","isInstalling","handleClick","buttonText","Download","EnableButton","isEnabling","DisableButton","isDisabling","UpdateButton","isUpdating","MarkdownRenderer","markdown","anchorTarget","Markdown","FilterButton","Filter","DropdownMenuItemType","DropdownMenuItemType2","FilterDropdown","groups","NoExtensionsFound","MoreInfo","category","downloads","languages","moreInfoUrl","numberFormatted","NumberFormat","handleScrollToBottom","User","locale","LucideLink","CircleHelp","VersionHistory","versionHistory","showAllVersions","setShowAllVersions","currentDate","formatTimeString","dateString","date","dateDiff","yearDiff","monthDiff","dayDiff","timeString","sortedEntries","Footer","publisherDisplayName","fileSize","locales","formattedFileSize","formatBytes","languageNames","codes","displayNames","useEvent","unsubscriber","noopUnsubscriber","useEventAsync","unsubscribe","unsub"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAGA,MAAMA,KAAgBC,GAAoB,EAAE,QAAQ,MAAO,CAAA;AAyDpD,SAASC,KAAMC,GAAsB;AACnC,SAAAH,GAAcI,GAAKD,CAAM,CAAC;AACnC;ACzDO,MAAME,KAAQC,EAAM;AAAA,EACzB,CAAC,EAAE,WAAAC,GAAW,MAAAC,GAAM,GAAGC,EAAA,GAASC,MAE5B,gBAAAC;AAAA,IAAC;AAAA,IAAA;AAAA,MACC,MAAAH;AAAA,MACA,WAAWN;AAAA,QACT;AAAA,QACAK;AAAA,MACF;AAAA,MACA,KAAAG;AAAA,MAEC,GAAGD;AAAA,IAAA;AAAA,EAAA;AAIZ;AACAJ,GAAM,cAAc;ACNpB,MAAMO,KAAmBC;AAAA,EACvB,CACE,EAAE,cAAAC,GAAc,eAAAC,GAAe,eAAAC,GAAe,cAAAC,GAAc,GAAGR,EAAM,GACrEC,MAGE,gBAAAQ,EAAC,OAAI,EAAA,WAAU,eACb,UAAA;AAAA,IAAA,gBAAAP;AAAA,MAACQ;AAAAA,MAAA;AAAA,QACE,GAAGV;AAAA,QACJ,MAAK;AAAA,QACL,WAAU;AAAA,QACV,UAAU,CAACW,MAAUN,EAAaM,EAAM,OAAO,KAAK;AAAA,QACpD,WAAW,CAACC,MAAM;AACZ,UAAAA,EAAE,QAAQ,WACCJ,KAEfF,EAAcM,CAAC;AAAA,QACjB;AAAA,QACA,SAASL;AAAA,QACT,KAAAN;AAAA,MAAA;AAAA,IACF;AAAA,IACA,gBAAAC;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55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,83,84,85,86,87,88,89,90,91,92,93,94,95,96,97,98,99,100,101,102,103,104,105,106,107,108,109,110,111,112,113,114,115,116,117,118,119,120,121,122,123,124,125,126,127,128,129,130,131,132,133,134,135,136,137,138,139,140,141,142,143,144,145,146,147,148,149,150,151,152,153,154,155,156,157,158,159,160,161,162,163,164,165,166,167,168,169,170,171,172,173,174,175,176,177,178,179,180,181,182,183,184,185,186,187,188,189,190,191,192,193,194,195,196,197,198,199,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,228]} \ No newline at end of file diff --git a/lib/platform-bible-react/src/components/advanced/settings-components/settings-sidebar-content-search.component.tsx b/lib/platform-bible-react/src/components/advanced/settings-components/settings-sidebar-content-search.component.tsx index 237eae2eae..99b5ed5099 100644 --- a/lib/platform-bible-react/src/components/advanced/settings-components/settings-sidebar-content-search.component.tsx +++ b/lib/platform-bible-react/src/components/advanced/settings-components/settings-sidebar-content-search.component.tsx @@ -26,17 +26,22 @@ export default function SettingsSidebarContentSearch({ onSearch, extensionsSidebarGroupLabel, projectsSidebarGroupLabel, + buttonPlaceholder, }: SettingsSidebarContentSearchProps) { return ( -
    -
    +
    +
    - + {children} diff --git a/lib/platform-bible-react/src/components/advanced/settings-components/settings-sidebar.component.tsx b/lib/platform-bible-react/src/components/advanced/settings-components/settings-sidebar.component.tsx index 2747ad1eb7..aac254c988 100644 --- a/lib/platform-bible-react/src/components/advanced/settings-components/settings-sidebar.component.tsx +++ b/lib/platform-bible-react/src/components/advanced/settings-components/settings-sidebar.component.tsx @@ -40,6 +40,9 @@ export type SettingsSidebarProps = { /** Label for the group of projects settings */ projectsSidebarGroupLabel: string; + + /** Placeholder for the button */ + buttonPlaceholder: string; }; export default function SettingsSidebar({ @@ -50,6 +53,7 @@ export default function SettingsSidebar({ selectedSidebarItem, extensionsSidebarGroupLabel, projectsSidebarGroupLabel, + buttonPlaceholder, }: SettingsSidebarProps) { const handleSelectItem = useCallback( (item: string, projectId?: string) => { @@ -115,7 +119,7 @@ export default function SettingsSidebar({ // eslint-disable-next-line no-type-assertion/no-type-assertion return getProjectNameFromProjectId(projectId as string); }} - buttonPlaceholder="Type or select project" + buttonPlaceholder={buttonPlaceholder} onChange={(projectId: string) => { const selectedProjectName = getProjectNameFromProjectId(projectId); handleSelectItem(selectedProjectName, projectId); diff --git a/src/extension-host/data/menu.data.json b/src/extension-host/data/menu.data.json index 6657d47d5e..08d244dd6e 100644 --- a/src/extension-host/data/menu.data.json +++ b/src/extension-host/data/menu.data.json @@ -78,7 +78,7 @@ "command": "platform.assignments" }, { - "label": "%webview_openProjectSettings%", + "label": "%webView_openProjectSettings%", "localizeNotes": "Web view main menu > Project > Open Project Settings...", "group": "platform.projectTop", "order": 3, diff --git a/src/renderer/components/settings-tabs/settings-tab.component.scss b/src/renderer/components/settings-tabs/settings-tab.component.scss index 1264c138f1..4ab526ac35 100644 --- a/src/renderer/components/settings-tabs/settings-tab.component.scss +++ b/src/renderer/components/settings-tabs/settings-tab.component.scss @@ -1,6 +1,7 @@ .settings-tab { padding: 2%; - height: inherit; + height: 100%; + box-sizing: border-box; } .project-settings-tab { @@ -18,4 +19,5 @@ .sidebar-container { height: 100%; + box-sizing: border-box; } diff --git a/src/renderer/components/settings-tabs/settings-tab.component.tsx b/src/renderer/components/settings-tabs/settings-tab.component.tsx index ad0ec22a42..c7a2b57be7 100644 --- a/src/renderer/components/settings-tabs/settings-tab.component.tsx +++ b/src/renderer/components/settings-tabs/settings-tab.component.tsx @@ -41,9 +41,12 @@ const LOCALIZE_SETTING_KEYS: LocalizeKey[] = [ '%settings_defaultMessage_noSettingsForThisProject%', '%settings_sidebar_extensionsLabel%', '%settings_sidebar_projectsLabel%', + '%settings_sidebar_projectsComboBoxPlaceholder%', ]; export default function SettingsTab({ projectIdToLimitSettings }: SettingsTabProps) { + const [localizedStrings] = useLocalizedStrings(useMemo(() => LOCALIZE_SETTING_KEYS, [])); + const [selectedSidebarItem, setSelectedSidebarItem] = useState({ label: '', projectId: undefined, @@ -54,8 +57,6 @@ export default function SettingsTab({ projectIdToLimitSettings }: SettingsTabPro setSearchQuery(newSearchTerm); }; - const [localizedStrings] = useLocalizedStrings(useMemo(() => LOCALIZE_SETTING_KEYS, [])); - const [settingsContributions, isLoadingSettingsContributions] = usePromise( useCallback(async () => { const contributions = (await settingsService.getLocalizedSettingsContributionInfo()) @@ -191,8 +192,9 @@ export default function SettingsTab({ projectIdToLimitSettings }: SettingsTabPro onSearch={handleSearchInput} extensionsSidebarGroupLabel={localizedStrings['%settings_sidebar_extensionsLabel%']} projectsSidebarGroupLabel={localizedStrings['%settings_sidebar_projectsLabel%']} + buttonPlaceholder={localizedStrings['%settings_sidebar_projectsComboBoxPlaceholder%']} > -
    +
    {selectedSidebarItem.projectId ? renderProjectSettingsList(selectedSidebarItem.projectId) : settingsContributions[selectedSidebarItem.label]?.map((group) => ( From 28cf4b153cd4c7cec4bab5c21fa24338f4702fad Mon Sep 17 00:00:00 2001 From: Jolie Rabideau Date: Tue, 26 Nov 2024 17:12:58 -0500 Subject: [PATCH 08/18] Fix combobox story error --- src/stories/basics/combo-box.stories.tsx | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/stories/basics/combo-box.stories.tsx b/src/stories/basics/combo-box.stories.tsx index e65329aad8..4561c20da5 100644 --- a/src/stories/basics/combo-box.stories.tsx +++ b/src/stories/basics/combo-box.stories.tsx @@ -7,7 +7,7 @@ const meta: Meta = { tags: ['autodocs'], argTypes: { options: { control: 'object' }, - className: { control: 'text' }, + buttonClassName: { control: 'text' }, }, }; export default meta; @@ -26,12 +26,12 @@ export const Placeholder: Story = { export const Paratext: Story = { args: { - className: 'paratext', + buttonClassName: 'paratext', }, }; export const ParatextBright: Story = { args: { - className: 'paratext bright', + buttonClassName: 'paratext bright', }, }; From 4f028e4aa3c77d33128cc653af87e06f39611b4c Mon Sep 17 00:00:00 2001 From: Jolie Rabideau Date: Tue, 26 Nov 2024 18:09:45 -0500 Subject: [PATCH 09/18] Fix filtering by project interfaces bug --- src/shared/services/project-settings.service.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/shared/services/project-settings.service.ts b/src/shared/services/project-settings.service.ts index c3d369f0ab..e31eb0cf68 100644 --- a/src/shared/services/project-settings.service.ts +++ b/src/shared/services/project-settings.service.ts @@ -45,7 +45,7 @@ export function filterProjectSettingsContributionsByProjectInterfaces( Object.entries(contribution.properties).forEach(([key, property]) => { const { includeProjectInterfaces, excludeProjectInterfaces } = property; - if (includeProjectInterfaces && excludeProjectInterfaces) { + if (includeProjectInterfaces || excludeProjectInterfaces) { if ( areProjectInterfacesIncluded( projectInterfaces, From fc2f2bdb10a7b08f95e9fc1a41380cc361e0277b Mon Sep 17 00:00:00 2001 From: Jolie Rabideau Date: Wed, 27 Nov 2024 11:53:17 -0500 Subject: [PATCH 10/18] Fix loading project list bug, hide card when search has no results --- ...oject-or-other-settings-list.component.tsx | 13 ++++-- .../settings-tabs/settings-tab.component.tsx | 41 +++++++++++-------- 2 files changed, 32 insertions(+), 22 deletions(-) diff --git a/src/renderer/components/settings-tabs/settings-components/project-or-other-settings-list.component.tsx b/src/renderer/components/settings-tabs/settings-components/project-or-other-settings-list.component.tsx index 38f498a0f3..38125e9354 100644 --- a/src/renderer/components/settings-tabs/settings-components/project-or-other-settings-list.component.tsx +++ b/src/renderer/components/settings-tabs/settings-components/project-or-other-settings-list.component.tsx @@ -36,16 +36,21 @@ export default function ProjectOrOtherSettingsList({ | Localized => { const filteredProperties: Localized | Localized = Object.fromEntries( - Object.entries(settingProperties).filter( - ([, property]) => - property.label.toLowerCase().includes(searchQuery.toLowerCase()) || - property.description?.toLowerCase().includes(searchQuery.toLowerCase()), + Object.entries(settingProperties).filter(([, property]) => + property.label.toLowerCase().includes(searchQuery.toLowerCase()), ), ); return filteredProperties; }, [searchQuery, settingProperties]); + const hasFilteredProperties = useMemo( + () => Object.keys(filteredSettingsProperties).length > 0, + [filteredSettingsProperties], + ); + + if (!hasFilteredProperties) return undefined; + return ( diff --git a/src/renderer/components/settings-tabs/settings-tab.component.tsx b/src/renderer/components/settings-tabs/settings-tab.component.tsx index c7a2b57be7..b786f4d8b6 100644 --- a/src/renderer/components/settings-tabs/settings-tab.component.tsx +++ b/src/renderer/components/settings-tabs/settings-tab.component.tsx @@ -1,6 +1,5 @@ import { useCallback, useMemo, useState } from 'react'; import { - ProjectOptions, SelectedSettingsSidebarItem, SettingsSidebarContentSearch, usePromise, @@ -97,26 +96,27 @@ export default function SettingsTab({ projectIdToLimitSettings }: SettingsTabPro useMemo(() => undefined, []), ); - const [filteredProjectSettingsContributions] = usePromise( - useCallback(async () => { - if (!projectIdToLimitSettings && !selectedSidebarItem.projectId) return undefined; + const [filteredProjectSettingsContributions, isLoadingFilteredProjectSettingsContributions] = + usePromise( + useCallback(async () => { + if (!projectIdToLimitSettings && !selectedSidebarItem.projectId) return undefined; - const projectId = projectIdToLimitSettings || selectedSidebarItem.projectId; + const projectId = projectIdToLimitSettings || selectedSidebarItem.projectId; - const projectInterfacesFromProjectId = - // We check for a valid projectId above - // eslint-disable-next-line no-type-assertion/no-type-assertion - (await projectLookupService.getMetadataForProject(projectId!)).projectInterfaces; + const projectInterfacesFromProjectId = + // We check for a valid projectId above + // eslint-disable-next-line no-type-assertion/no-type-assertion + (await projectLookupService.getMetadataForProject(projectId!)).projectInterfaces; - return filterProjectSettingsContributionsByProjectInterfaces( - projectSettingsContributions, - projectInterfacesFromProjectId, - ); - }, [projectIdToLimitSettings, selectedSidebarItem.projectId, projectSettingsContributions]), - useMemo(() => undefined, []), - ); + return filterProjectSettingsContributionsByProjectInterfaces( + projectSettingsContributions, + projectInterfacesFromProjectId, + ); + }, [projectIdToLimitSettings, selectedSidebarItem.projectId, projectSettingsContributions]), + useMemo(() => undefined, []), + ); - const [allProjectOptions]: [ProjectOptions[], boolean] = usePromise( + const [allProjectOptions, isLoadingAllProjectOptions] = usePromise( useCallback(async () => { const allProjectIdsFromMetadata = await getAllProjectIdsFromMetadata(); @@ -170,7 +170,12 @@ export default function SettingsTab({ projectIdToLimitSettings }: SettingsTabPro ); } - if (isLoadingSettingsContributions || isLoadingProjectSettingsContributions) + if ( + isLoadingSettingsContributions || + isLoadingProjectSettingsContributions || + isLoadingAllProjectOptions || + isLoadingFilteredProjectSettingsContributions + ) return (
    {localizedStrings['%settings_defaultMessage_loadingSettings%']} From 01f52bd2016e5ef0168ef7a809d81212b10f0aca Mon Sep 17 00:00:00 2001 From: Jolie Rabideau Date: Mon, 2 Dec 2024 15:04:24 -0500 Subject: [PATCH 11/18] First round code review- remove unnecessary props, update type names, add missing localized string --- assets/localization/en.json | 1 + lib/platform-bible-react/dist/index.cjs | 84 +-- lib/platform-bible-react/dist/index.cjs.map | 2 +- lib/platform-bible-react/dist/index.d.ts | 16 +- lib/platform-bible-react/dist/index.js | 651 +++++++++--------- lib/platform-bible-react/dist/index.js.map | 2 +- ...tings-sidebar-content-search.component.tsx | 14 +- .../settings-sidebar.component.tsx | 14 +- .../basics/search-bar.component.tsx | 1 + .../src/components/hooks/use-mobile.tsx | 2 +- lib/platform-bible-react/src/index.ts | 2 +- .../settings-tabs/settings-tab.component.tsx | 6 +- 12 files changed, 392 insertions(+), 403 deletions(-) diff --git a/assets/localization/en.json b/assets/localization/en.json index 2f2469f32e..295e8be60d 100644 --- a/assets/localization/en.json +++ b/assets/localization/en.json @@ -51,6 +51,7 @@ "%selectProject_title%": "Select Project", "%settings_defaultMessage_loadingOneSetting%": "Loading setting", "%settings_defaultMessage_loadingSettings%": "Loading settings...", + "%settings_defaultMessage_noSettings%": "No settings", "%settings_defaultMessage_noSettingComponent%": "No setting component", "%settings_defaultMessage_noSettingsForThisProject%": "No settings available for this project.", "%settings_defaultSearchText_searchProject%": "Search Project Settings...", diff --git a/lib/platform-bible-react/dist/index.cjs b/lib/platform-bible-react/dist/index.cjs index 210d6a85b9..0aced6c971 100644 --- a/lib/platform-bible-react/dist/index.cjs +++ b/lib/platform-bible-react/dist/index.cjs @@ -1,4 +1,4 @@ -"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const a=require("react/jsx-runtime"),g=require("react"),Q=require("lucide-react"),ot=require("clsx"),ml=require("tailwind-merge"),Za=require("@radix-ui/react-dropdown-menu"),W=require("platform-bible-utils"),Ht=require("@radix-ui/react-slot"),Xt=require("class-variance-authority"),hl=require("@radix-ui/react-label"),gl=require("@radix-ui/react-radio-group"),bl=require("@radix-ui/react-popover"),Re=require("cmdk"),vl=require("@radix-ui/react-dialog"),Se=require("@tanstack/react-table"),xl=require("@radix-ui/react-select"),yl=require("@radix-ui/react-checkbox"),Nl=require("@radix-ui/react-toggle-group"),kl=require("@radix-ui/react-toggle"),Sl=require("@radix-ui/react-tabs"),El=require("@radix-ui/react-separator"),jl=require("@radix-ui/react-tooltip"),Gr=require("@mui/styled-engine"),Me=require("@mui/material"),ln=require("react-dom"),Qa=require("sonner"),Cl=require("@radix-ui/react-slider"),Tl=require("@radix-ui/react-switch"),Rl=require("markdown-to-jsx");function ke(e){const t=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(e){for(const n in e)if(n!=="default"){const r=Object.getOwnPropertyDescriptor(e,n);Object.defineProperty(t,n,r.get?r:{enumerable:!0,get:()=>e[n]})}}return t.default=e,Object.freeze(t)}const M=ke(g),pe=ke(Za),es=ke(hl),bn=ke(gl),vn=ke(bl),be=ke(vl),ge=ke(xl),Ur=ke(yl),rr=ke(Nl),ts=ke(kl),Oe=ke(Sl),ns=ke(El),Sn=ke(jl),Ol=ke(ln),cn=ke(Cl),qr=ke(Tl);const _l=ml.extendTailwindMerge({prefix:"tw-"});function N(...e){return _l(ot.clsx(e))}const St=g.forwardRef(({className:e,type:t,...n},r)=>a.jsx("input",{type:t,className:N("pr-twp tw-flex tw-h-10 tw-rounded-md tw-border tw-border-input tw-bg-background tw-px-3 tw-py-2 tw-text-sm tw-ring-offset-background file:tw-border-0 file:tw-bg-transparent file:tw-text-sm file:tw-font-medium file:tw-text-foreground placeholder:tw-text-muted-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-cursor-not-allowed disabled:tw-opacity-50",e),ref:r,...n}));St.displayName="Input";const Pl=g.forwardRef(({handleSearch:e,handleKeyDown:t,handleOnClick:n,handleSubmit:r,...o},s)=>a.jsxs("div",{className:"tw-relative",children:[a.jsx(St,{...o,type:"text",className:"tw-box-border tw-gap-2.5 tw-rounded-lg tw-border tw-border-solid tw-bg-background tw-py-2 tw-pl-4 tw-pr-3 tw-font-medium tw-shadow-none tw-outline-none",onChange:i=>e(i.target.value),onKeyDown:i=>{i.key==="Enter"&&r(),t(i)},onClick:n,ref:s}),a.jsx(Q.History,{className:"tw-absolute tw-right-3 tw-top-1/2 tw-h-4 tw-w-4 tw--translate-y-1/2 tw-transform tw-cursor-pointer tw-text-muted-foreground",onClick:()=>{console.log("back in history")}})]}));var Il=Object.defineProperty,Ml=(e,t,n)=>t in e?Il(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,ne=(e,t,n)=>Ml(e,typeof t!="symbol"?t+"":t,n);const gt=["GEN","EXO","LEV","NUM","DEU","JOS","JDG","RUT","1SA","2SA","1KI","2KI","1CH","2CH","EZR","NEH","EST","JOB","PSA","PRO","ECC","SNG","ISA","JER","LAM","EZK","DAN","HOS","JOL","AMO","OBA","JON","MIC","NAM","HAB","ZEP","HAG","ZEC","MAL","MAT","MRK","LUK","JHN","ACT","ROM","1CO","2CO","GAL","EPH","PHP","COL","1TH","2TH","1TI","2TI","TIT","PHM","HEB","JAS","1PE","2PE","1JN","2JN","3JN","JUD","REV","TOB","JDT","ESG","WIS","SIR","BAR","LJE","S3Y","SUS","BEL","1MA","2MA","3MA","4MA","1ES","2ES","MAN","PS2","ODA","PSS","JSA","JDB","TBS","SST","DNT","BLT","XXA","XXB","XXC","XXD","XXE","XXF","XXG","FRT","BAK","OTH","3ES","EZA","5EZ","6EZ","INT","CNC","GLO","TDX","NDX","DAG","PS3","2BA","LBA","JUB","ENO","1MQ","2MQ","3MQ","REP","4BA","LAO"],ao=["XXA","XXB","XXC","XXD","XXE","XXF","XXG","FRT","BAK","OTH","INT","CNC","GLO","TDX","NDX"],rs=["Genesis","Exodus","Leviticus","Numbers","Deuteronomy","Joshua","Judges","Ruth","1 Samuel","2 Samuel","1 Kings","2 Kings","1 Chronicles","2 Chronicles","Ezra","Nehemiah","Esther (Hebrew)","Job","Psalms","Proverbs","Ecclesiastes","Song of Songs","Isaiah","Jeremiah","Lamentations","Ezekiel","Daniel (Hebrew)","Hosea","Joel","Amos","Obadiah","Jonah","Micah","Nahum","Habakkuk","Zephaniah","Haggai","Zechariah","Malachi","Matthew","Mark","Luke","John","Acts","Romans","1 Corinthians","2 Corinthians","Galatians","Ephesians","Philippians","Colossians","1 Thessalonians","2 Thessalonians","1 Timothy","2 Timothy","Titus","Philemon","Hebrews","James","1 Peter","2 Peter","1 John","2 John","3 John","Jude","Revelation","Tobit","Judith","Esther Greek","Wisdom of Solomon","Sirach (Ecclesiasticus)","Baruch","Letter of Jeremiah","Song of 3 Young Men","Susanna","Bel and the Dragon","1 Maccabees","2 Maccabees","3 Maccabees","4 Maccabees","1 Esdras (Greek)","2 Esdras (Latin)","Prayer of Manasseh","Psalm 151","Odes","Psalms of Solomon","Joshua A. *obsolete*","Judges B. *obsolete*","Tobit S. *obsolete*","Susanna Th. *obsolete*","Daniel Th. *obsolete*","Bel Th. *obsolete*","Extra A","Extra B","Extra C","Extra D","Extra E","Extra F","Extra G","Front Matter","Back Matter","Other Matter","3 Ezra *obsolete*","Apocalypse of Ezra","5 Ezra (Latin Prologue)","6 Ezra (Latin Epilogue)","Introduction","Concordance ","Glossary ","Topical Index","Names Index","Daniel Greek","Psalms 152-155","2 Baruch (Apocalypse)","Letter of Baruch","Jubilees","Enoch","1 Meqabyan","2 Meqabyan","3 Meqabyan","Reproof (Proverbs 25-31)","4 Baruch (Rest of Baruch)","Laodiceans"],ra=Ul();function Yt(e,t=!0){return t&&(e=e.toUpperCase()),e in ra?ra[e]:0}function so(e){return Yt(e)>0}function $l(e){const t=typeof e=="string"?Yt(e):e;return t>=40&&t<=66}function Dl(e){return(typeof e=="string"?Yt(e):e)<=39}function os(e){return e<=66}function Al(e){const t=typeof e=="string"?Yt(e):e;return is(t)&&!os(t)}function*Bl(){for(let e=1;e<=gt.length;e++)yield e}const Vl=1,as=gt.length;function zl(){return["XXA","XXB","XXC","XXD","XXE","XXF","XXG"]}function io(e,t="***"){const n=e-1;return n<0||n>=gt.length?t:gt[n]}function ss(e){return e<=0||e>as?"******":rs[e-1]}function Ll(e){return ss(Yt(e))}function is(e){const t=typeof e=="number"?io(e):e;return so(t)&&!ao.includes(t)}function Fl(e){const t=typeof e=="number"?io(e):e;return so(t)&&ao.includes(t)}function Gl(e){return rs[e-1].includes("*obsolete*")}function Ul(){const e={};for(let t=0;t(e[e.Unknown=0]="Unknown",e[e.Original=1]="Original",e[e.Septuagint=2]="Septuagint",e[e.Vulgate=3]="Vulgate",e[e.English=4]="English",e[e.RussianProtestant=5]="RussianProtestant",e[e.RussianOrthodox=6]="RussianOrthodox",e))(He||{});const Pe=class{constructor(t){if(ne(this,"name"),ne(this,"fullPath"),ne(this,"isPresent"),ne(this,"hasVerseSegments"),ne(this,"isCustomized"),ne(this,"baseVersification"),ne(this,"scriptureBooks"),ne(this,"_type"),t==null)throw new Error("Argument undefined");typeof t=="string"?(this.name=t,this._type=He[t]):(this._type=t,this.name=He[t])}get type(){return this._type}equals(t){return!t.type||!this.type?!1:t.type===this.type}};ne(Pe,"Original",new Pe(He.Original)),ne(Pe,"Septuagint",new Pe(He.Septuagint)),ne(Pe,"Vulgate",new Pe(He.Vulgate)),ne(Pe,"English",new Pe(He.English)),ne(Pe,"RussianProtestant",new Pe(He.RussianProtestant)),ne(Pe,"RussianOrthodox",new Pe(He.RussianOrthodox));let ut=Pe;function oa(e,t){const n=t[0];for(let r=1;r(e[e.Valid=0]="Valid",e[e.UnknownVersification=1]="UnknownVersification",e[e.OutOfRange=2]="OutOfRange",e[e.VerseOutOfOrder=3]="VerseOutOfOrder",e[e.VerseRepeated=4]="VerseRepeated",e))(ls||{});const je=class re{constructor(t,n,r,o){if(ne(this,"firstChapter"),ne(this,"lastChapter"),ne(this,"lastVerse"),ne(this,"hasSegmentsDefined"),ne(this,"text"),ne(this,"BBBCCCVVVS"),ne(this,"longHashCode"),ne(this,"versification"),ne(this,"rtlMark","‏"),ne(this,"_bookNum",0),ne(this,"_chapterNum",0),ne(this,"_verseNum",0),ne(this,"_verse"),r==null&&o==null)if(t!=null&&typeof t=="string"){const s=t,i=n!=null&&n instanceof ut?n:void 0;this.setEmpty(i),this.parse(s)}else if(t!=null&&typeof t=="number"){const s=n!=null&&n instanceof ut?n:void 0;this.setEmpty(s),this._verseNum=t%re.chapterDigitShifter,this._chapterNum=Math.floor(t%re.bookDigitShifter/re.chapterDigitShifter),this._bookNum=Math.floor(t/re.bookDigitShifter)}else if(n==null)if(t!=null&&t instanceof re){const s=t;this._bookNum=s.bookNum,this._chapterNum=s.chapterNum,this._verseNum=s.verseNum,this._verse=s.verse,this.versification=s.versification}else{if(t==null)return;const s=t instanceof ut?t:re.defaultVersification;this.setEmpty(s)}else throw new Error("VerseRef constructor not supported.");else if(t!=null&&n!=null&&r!=null)if(typeof t=="string"&&typeof n=="string"&&typeof r=="string")this.setEmpty(o),this.updateInternal(t,n,r);else if(typeof t=="number"&&typeof n=="number"&&typeof r=="number")this._bookNum=t,this._chapterNum=n,this._verseNum=r,this.versification=o??re.defaultVersification;else throw new Error("VerseRef constructor not supported.");else throw new Error("VerseRef constructor not supported.")}static isVerseParseable(t){return t.length>0&&"0123456789".includes(t[0])&&!t.endsWith(this.verseRangeSeparator)&&!t.endsWith(this.verseSequenceIndicator)}static tryParse(t){let n;try{return n=new re(t),{success:!0,verseRef:n}}catch(r){if(r instanceof nn)return n=new re,{success:!1,verseRef:n};throw r}}static getBBBCCCVVV(t,n,r){return t%re.bcvMaxValue*re.bookDigitShifter+(n>=0?n%re.bcvMaxValue*re.chapterDigitShifter:0)+(r>=0?r%re.bcvMaxValue:0)}static fromJSON(t){const{book:n,chapterNum:r,verseNum:o,verse:s,versificationStr:i}=t,l=s||o.toString();let c;return i&&(c=new ut(i)),n?new re(n,r.toString(),l,c):new re}static tryGetVerseNum(t){let n;if(!t)return n=-1,{success:!0,vNum:n};n=0;let r;for(let o=0;o"9")return o===0&&(n=-1),{success:!1,vNum:n};if(n=n*10+ +r-0,n>re.bcvMaxValue)return n=-1,{success:!1,vNum:n}}return{success:!0,vNum:n}}get isDefault(){return this.bookNum===0&&this.chapterNum===0&&this.verseNum===0&&this.versification==null}get hasMultiple(){return this._verse!=null&&(this._verse.includes(re.verseRangeSeparator)||this._verse.includes(re.verseSequenceIndicator))}get book(){return ae.bookNumberToId(this.bookNum,"")}set book(t){this.bookNum=ae.bookIdToNumber(t)}get chapter(){return this.isDefault||this._chapterNum<0?"":this._chapterNum.toString()}set chapter(t){const n=+t;this._chapterNum=Number.isInteger(n)?n:-1}get verse(){return this._verse!=null?this._verse:this.isDefault||this._verseNum<0?"":this._verseNum.toString()}set verse(t){const{success:n,vNum:r}=re.tryGetVerseNum(t);this._verse=n?void 0:t.replace(this.rtlMark,""),this._verseNum=r,!(this._verseNum>=0)&&({vNum:this._verseNum}=re.tryGetVerseNum(this._verse))}get bookNum(){return this._bookNum}set bookNum(t){if(t<=0||t>ae.lastBook)throw new nn("BookNum must be greater than zero and less than or equal to last book");this._bookNum=t}get chapterNum(){return this._chapterNum}set chapterNum(t){this.chapterNum=t}get verseNum(){return this._verseNum}set verseNum(t){this._verseNum=t}get versificationStr(){var t;return(t=this.versification)==null?void 0:t.name}set versificationStr(t){this.versification=this.versification!=null?new ut(t):void 0}get valid(){return this.validStatus===0}get validStatus(){return this.validateVerse(re.verseRangeSeparators,re.verseSequenceIndicators)}get BBBCCC(){return re.getBBBCCCVVV(this._bookNum,this._chapterNum,0)}get BBBCCCVVV(){return re.getBBBCCCVVV(this._bookNum,this._chapterNum,this._verseNum)}get isExcluded(){return!1}parse(t){if(t=t.replace(this.rtlMark,""),t.includes("/")){const s=t.split("/");if(t=s[0],s.length>1)try{const i=+s[1].trim();this.versification=new ut(He[i])}catch{throw new nn("Invalid reference : "+t)}}const n=t.trim().split(" ");if(n.length!==2)throw new nn("Invalid reference : "+t);const r=n[1].split(":"),o=+r[0];if(r.length!==2||ae.bookIdToNumber(n[0])===0||!Number.isInteger(o)||o<0||!re.isVerseParseable(r[1]))throw new nn("Invalid reference : "+t);this.updateInternal(n[0],r[0],r[1])}simplify(){this._verse=void 0}clone(){return new re(this)}toString(){const t=this.book;return t===""?"":`${t} ${this.chapter}:${this.verse}`}toJSON(){let t=this.verse;(t===""||t===this.verseNum.toString())&&(t=void 0);const n={book:this.book,chapterNum:this.chapterNum,verseNum:this.verseNum,verse:t,versificationStr:this.versificationStr};return t||delete n.verse,n}equals(t){return t instanceof re?t._bookNum===this._bookNum&&t._chapterNum===this._chapterNum&&t._verseNum===this._verseNum&&t.verse===this.verse&&(t.versification==null&&this.versification==null||t.versification!=null&&this.versification!=null&&t.versification.equals(this.versification)):!1}allVerses(t=!1,n=re.verseRangeSeparators,r=re.verseSequenceIndicators){if(this._verse==null||this.chapterNum<=0)return[this.clone()];const o=[],s=oa(this._verse,r);for(const i of s.map(l=>oa(l,n))){const l=this.clone();l.verse=i[0];const c=l.verseNum;if(o.push(l),i.length>1){const d=this.clone();if(d.verse=i[1],!t)for(let u=c+1;ui)return 3;if(r===i)return 4;r=i}return 0}get internalValid(){return this.versification==null?1:this._bookNum<=0||this._bookNum>ae.lastBook?2:(ae.isCanonical(this._bookNum),0)}setEmpty(t=re.defaultVersification){this._bookNum=0,this._chapterNum=-1,this._verse=void 0,this.versification=t}updateInternal(t,n,r){this.bookNum=ae.bookIdToNumber(t),this.chapter=n,this.verse=r}};ne(je,"defaultVersification",ut.English),ne(je,"verseRangeSeparator","-"),ne(je,"verseSequenceIndicator",","),ne(je,"verseRangeSeparators",[je.verseRangeSeparator]),ne(je,"verseSequenceIndicators",[je.verseSequenceIndicator]),ne(je,"chapterDigitShifter",1e3),ne(je,"bookDigitShifter",je.chapterDigitShifter*je.chapterDigitShifter),ne(je,"bcvMaxValue",je.chapterDigitShifter-1),ne(je,"ValidStatusType",ls);class nn extends Error{}const or=pe.Root,lo=pe.Trigger,cs=pe.Group,ql=pe.Portal,Hl=pe.Sub,Xl=pe.RadioGroup,ds=g.forwardRef(({className:e,inset:t,children:n,...r},o)=>a.jsxs(pe.SubTrigger,{ref:o,className:N("tw-flex tw-cursor-default tw-select-none tw-items-center tw-rounded-sm tw-px-2 tw-py-1.5 tw-text-sm tw-outline-none focus:tw-bg-accent data-[state=open]:tw-bg-accent",t&&"tw-pl-8",e),...r,children:[n,a.jsx(Q.ChevronRight,{className:"tw-ml-auto tw-h-4 tw-w-4"})]}));ds.displayName=pe.SubTrigger.displayName;const us=g.forwardRef(({className:e,...t},n)=>a.jsx(pe.SubContent,{ref:n,className:N("tw-z-50 tw-min-w-[8rem] tw-overflow-hidden tw-rounded-md tw-border tw-bg-popover tw-p-1 tw-text-popover-foreground tw-shadow-lg data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0 data-[state=closed]:tw-zoom-out-95 data-[state=open]:tw-zoom-in-95 data-[side=bottom]:tw-slide-in-from-top-2 data-[side=left]:tw-slide-in-from-right-2 data-[side=right]:tw-slide-in-from-left-2 data-[side=top]:tw-slide-in-from-bottom-2",e),...t}));us.displayName=pe.SubContent.displayName;const En=g.forwardRef(({className:e,sideOffset:t=4,...n},r)=>a.jsx(pe.Portal,{children:a.jsx(pe.Content,{ref:r,sideOffset:t,className:N("pr-twp tw-z-50 tw-min-w-[8rem] tw-overflow-hidden tw-rounded-md tw-border tw-bg-popover tw-p-1 tw-text-popover-foreground tw-shadow-md data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0 data-[state=closed]:tw-zoom-out-95 data-[state=open]:tw-zoom-in-95 data-[side=bottom]:tw-slide-in-from-top-2 data-[side=left]:tw-slide-in-from-right-2 data-[side=right]:tw-slide-in-from-left-2 data-[side=top]:tw-slide-in-from-bottom-2",e),...n})}));En.displayName=pe.Content.displayName;const co=g.forwardRef(({className:e,inset:t,...n},r)=>a.jsx(pe.Item,{ref:r,className:N("tw-cursor-default tw-select-none tw-items-center tw-rounded-sm tw-px-2 tw-py-1.5 tw-text-sm tw-outline-none tw-transition-colors focus:tw-bg-accent data-[disabled]:tw-pointer-events-none data-[disabled]:tw-opacity-50",t&&"tw-pl-8",e),...n}));co.displayName=pe.Item.displayName;const ar=g.forwardRef(({className:e,children:t,checked:n,...r},o)=>a.jsxs(pe.CheckboxItem,{ref:o,className:N("tw-relative tw-flex tw-cursor-default tw-select-none tw-items-center tw-rounded-sm tw-py-1.5 tw-pl-8 tw-pr-2 tw-text-sm tw-outline-none tw-transition-colors focus:tw-bg-accent focus:tw-text-accent-foreground data-[disabled]:tw-pointer-events-none data-[disabled]:tw-opacity-50",e),checked:n,...r,children:[a.jsx("span",{className:"tw-absolute tw-left-2 tw-flex tw-h-3.5 tw-w-3.5 tw-items-center tw-justify-center",children:a.jsx(pe.ItemIndicator,{children:a.jsx(Q.Check,{className:"tw-h-4 tw-w-4"})})}),t]}));ar.displayName=pe.CheckboxItem.displayName;const uo=g.forwardRef(({className:e,children:t,...n},r)=>a.jsxs(pe.RadioItem,{ref:r,className:N("tw-relative tw-flex tw-cursor-default tw-select-none tw-items-center tw-rounded-sm tw-py-1.5 tw-pl-8 tw-pr-2 tw-text-sm tw-outline-none tw-transition-colors focus:tw-bg-accent focus:tw-text-accent-foreground data-[disabled]:tw-pointer-events-none data-[disabled]:tw-opacity-50",e),...n,children:[a.jsx("span",{className:"tw-absolute tw-left-2 tw-flex tw-h-3.5 tw-w-3.5 tw-items-center tw-justify-center",children:a.jsx(pe.ItemIndicator,{children:a.jsx(Q.Circle,{className:"tw-h-2 tw-w-2 tw-fill-current"})})}),t]}));uo.displayName=pe.RadioItem.displayName;const Wt=g.forwardRef(({className:e,inset:t,...n},r)=>a.jsx(pe.Label,{ref:r,className:N("tw-px-2 tw-py-1.5 tw-text-sm tw-font-semibold",t&&"tw-pl-8",e),...n}));Wt.displayName=pe.Label.displayName;const jn=g.forwardRef(({className:e,...t},n)=>a.jsx(pe.Separator,{ref:n,className:N("tw--mx-1 tw-my-1 tw-h-px tw-bg-muted",e),...t}));jn.displayName=pe.Separator.displayName;function ps({className:e,...t}){return a.jsx("span",{className:N("tw-ml-auto tw-text-xs tw-tracking-widest tw-opacity-60",e),...t})}ps.displayName="DropdownMenuShortcut";const Yl=g.forwardRef(({bookId:e,handleSelectBook:t,isSelected:n,handleHighlightBook:r,handleKeyDown:o,bookType:s,children:i},l)=>a.jsxs(co,{ref:l,textValue:e,className:N("tw-mx-1 tw-px-1 tw-font-normal tw-text-foreground/80",{"tw-bg-amber-50 tw-text-yellow-900 data-[highlighted]:tw-bg-amber-100":n}),onSelect:c=>{c.preventDefault(),t()},onKeyDown:c=>{o(c)},onFocus:r,onMouseMove:r,children:[a.jsx("span",{className:N("tw-border-b-0 tw-border-l-2 tw-border-r-0 tw-border-t-0 tw-border-solid tw-px-2",{"tw-font-bold":n,"tw-border-l-red-200":s.toLowerCase()==="ot","tw-border-l-purple-200":s.toLowerCase()==="nt","tw-border-l-indigo-200":s.toLowerCase()==="dc"}),children:ae.bookIdToEnglishName(e)}),n&&a.jsx("div",{children:i})]},e));function Wl({handleSelectChapter:e,endChapter:t,activeChapter:n,highlightedChapter:r,handleHighlightedChapter:o}){const s=Array.from({length:t},(l,c)=>c+1),i=g.useCallback(l=>{o(l)},[o]);return a.jsx("div",{className:N("tw-flex tw-flex-wrap tw-items-start tw-justify-start tw-self-stretch"),children:s.map(l=>a.jsx("div",{className:N("tw-box-content tw-flex tw-h-4 tw-w-4 tw-cursor-pointer tw-items-center tw-justify-end tw-rounded-md tw-p-2 tw-text-amber-800",{"tw-font-semibold tw-text-amber-900":l===n,"tw-bg-amber-200":l===r}),onClick:c=>{c.preventDefault(),c.stopPropagation(),e(l)},role:"button",onKeyDown:c=>{c.key==="Enter"&&e(l)},tabIndex:0,onMouseMove:()=>i(l),children:l},l))})}function Kl({handleSort:e,handleLocationHistory:t,handleBookmarks:n}){return a.jsxs(Wt,{className:"tw-flex tw-justify-between",children:[a.jsx("p",{className:"tw-inline-block tw-align-middle",children:"Go To"}),a.jsxs("div",{className:"tw-flex tw-items-center",children:[a.jsx(Q.ArrowDownWideNarrow,{onClick:e,className:"tw-m-2 tw-h-4 tw-w-4 tw-cursor-pointer tw-gap-2"}),a.jsx(Q.Clock,{onClick:t,className:"tw-m-2 tw-h-4 tw-w-4 tw-cursor-pointer tw-gap-2"}),a.jsx(Q.Bookmark,{onClick:n,className:"tw-m-2 tw-h-4 tw-w-4 tw-cursor-pointer tw-gap-2"})]})]})}const wn=ae.allBookIds,Jl={OT:"Old Testament",NT:"New Testament",DC:"Deuterocanon"},aa=["OT","NT","DC"],Zl=32+32+32,Ql=[/^(\w+)$/i,/^(\w+)(?:\s(\d+))$/i,/^(\w+)(?:\s(\d+):(\d+))$/i],ec=e=>({OT:wn.filter(n=>ae.isBookOT(n)),NT:wn.filter(n=>ae.isBookNT(n)),DC:wn.filter(n=>ae.isBookDC(n))})[e],rn=e=>W.getChaptersForBook(ae.bookIdToNumber(e));function tc(){return wn.map(t=>ae.bookIdToEnglishName(t))}function nc(e){return tc().includes(e)}function rc(e){const t=e.toLowerCase().replace(/^\w/,n=>n.toUpperCase());if(nc(t))return wn.find(r=>ae.bookIdToEnglishName(r)===t)}function oc({scrRef:e,handleSubmit:t}){const[n,r]=g.useState(""),[o,s]=g.useState(ae.bookNumberToId(e.bookNum)),[i,l]=g.useState(e.chapterNum??0),[c,d]=g.useState(ae.bookNumberToId(e.bookNum)),[u,f]=g.useState(!1),[w,b]=g.useState(u),x=g.useRef(void 0),m=g.useRef(void 0),h=g.useRef(void 0),S=g.useCallback(k=>ec(k).filter(D=>{const $=ae.bookIdToEnglishName(D).toLowerCase(),J=n.replace(/[^a-zA-Z]/g,"").toLowerCase();return $.includes(J)||D.toLowerCase().includes(J)}),[n]),R=k=>{r(k)},j=g.useRef(!1),E=g.useCallback(k=>{if(j.current){j.current=!1;return}f(k)},[]),v=g.useCallback((k,D,$,J)=>{if(l(ae.bookNumberToId(e.bookNum)!==k?1:e.chapterNum),D||rn(k)===-1){t({bookNum:ae.bookIdToNumber(k),chapterNum:$||1,verseNum:J||1}),f(!1),r("");return}s(o!==k?k:""),f(!D)},[t,e.bookNum,e.chapterNum,o]),P=k=>{k<=0||k>rn(o)||v(o,!0,k)},V=g.useCallback(()=>{Ql.forEach(k=>{const D=n.match(k);if(D){const[$,J=void 0,Y=void 0]=D.slice(1),F=rc($);(ae.isBookIdValid($)||F)&&v(F??$,!0,J?parseInt(J,10):1,Y?parseInt(Y,10):1)}})},[v,n]),U=g.useCallback(k=>{u?(k.key==="ArrowDown"||k.key==="ArrowUp")&&(typeof h<"u"&&h.current!==null?h.current.focus():typeof m<"u"&&m.current!==null&&m.current.focus(),k.preventDefault()):f(!0)},[u]),C=k=>{const{key:D}=k;D==="ArrowRight"||D==="ArrowLeft"||D==="ArrowDown"||D==="ArrowUp"||D==="Enter"||(x.current.dispatchEvent(new KeyboardEvent("keydown",{key:D})),x.current.focus())},_=k=>{const{key:D}=k;if(c===o){if(D==="Enter"){k.preventDefault(),v(o,!0,i);return}let $=0;if(D==="ArrowRight")if(i1)$=-1;else{k.preventDefault();return}else D==="ArrowDown"?$=6:D==="ArrowUp"&&($=-6);i+$<=0||i+$>rn(c)?l(0):$!==0&&(l(i+$),k.preventDefault())}};return g.useEffect(()=>{o===c?o===ae.bookNumberToId(e.bookNum)?l(e.chapterNum):l(1):l(0)},[c,e.bookNum,e.chapterNum,o]),g.useLayoutEffect(()=>{b(u)},[u]),g.useLayoutEffect(()=>{const k=setTimeout(()=>{if(w&&m.current&&h.current){const $=h.current.offsetTop-Zl;m.current.scrollTo({top:$,behavior:"instant"})}},10);return()=>{clearTimeout(k)}},[w]),a.jsx("div",{className:"pr-twp tw-flex",children:a.jsxs(or,{modal:!1,open:u,onOpenChange:E,children:[a.jsx(lo,{asChild:!0,children:a.jsx(Pl,{ref:x,value:n,handleSearch:R,handleKeyDown:U,handleOnClick:()=>{s(ae.bookNumberToId(e.bookNum)),d(ae.bookNumberToId(e.bookNum)),l(e.chapterNum>0?e.chapterNum:0),f(!0),x.current.focus()},onFocus:()=>{j.current=!0},handleSubmit:V,placeholder:`${ae.bookNumberToEnglishName(e.bookNum)} ${e.chapterNum}:${e.verseNum}`})}),a.jsxs(En,{className:"tw-m-1 tw-overflow-y-auto tw-p-0 tw-font-normal tw-text-foreground/80",style:{width:"233px",maxHeight:"500px",zIndex:"250"},onKeyDown:C,align:"start",ref:m,children:[a.jsx(Kl,{handleSort:()=>console.log("sorting"),handleLocationHistory:()=>console.log("location history"),handleBookmarks:()=>console.log("bookmarks")}),aa.map((k,D)=>S(k).length>0&&a.jsxs("div",{children:[a.jsx(Wt,{className:"tw-font-semibold tw-text-foreground/80",children:Jl[k]}),S(k).map($=>a.jsx("div",{children:a.jsx(Yl,{bookId:$,handleSelectBook:()=>v($,!1),isSelected:o===$,handleHighlightBook:()=>d($),handleKeyDown:_,bookType:k,ref:J=>{o===$&&(h.current=J)},children:a.jsx(Wl,{handleSelectChapter:P,endChapter:rn($),activeChapter:e.bookNum===ae.bookIdToNumber($)?e.chapterNum:0,highlightedChapter:i,handleHighlightedChapter:J=>{l(J)}})})},$)),aa.length-1!==D?a.jsx(jn,{}):void 0]},k))]})]})})}const ws=Xt.cva("pr-twp tw-inline-flex tw-items-center tw-justify-center tw-whitespace-nowrap tw-rounded-md tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-colors focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50",{variants:{variant:{default:"tw-bg-primary tw-text-primary-foreground hover:tw-bg-primary/90",destructive:"tw-bg-destructive tw-text-destructive-foreground hover:tw-bg-destructive/90",outline:"tw-border tw-border-input tw-bg-background hover:tw-bg-accent hover:tw-text-accent-foreground",secondary:"tw-bg-secondary tw-text-secondary-foreground hover:tw-bg-secondary/80",ghost:"hover:tw-bg-accent hover:tw-text-accent-foreground",link:"tw-text-primary tw-underline-offset-4 hover:tw-underline"},size:{default:"tw-h-10 tw-px-4 tw-py-2",sm:"tw-h-9 tw-rounded-md tw-px-3",lg:"tw-h-11 tw-rounded-md tw-px-8",icon:"tw-h-10 tw-w-10"}},defaultVariants:{variant:"default",size:"default"}}),fe=g.forwardRef(({className:e,variant:t,size:n,asChild:r=!1,...o},s)=>{const i=r?Ht.Slot:"button";return a.jsx(i,{className:N(ws({variant:t,size:n,className:e})),ref:s,...o})});fe.displayName="Button";const ac=Xt.cva("tw-text-sm tw-font-medium tw-leading-none peer-disabled:tw-cursor-not-allowed peer-disabled:tw-opacity-70"),qe=g.forwardRef(({className:e,...t},n)=>a.jsx(es.Root,{ref:n,className:N("pr-twp",ac(),e),...t}));qe.displayName=es.Root.displayName;const po=g.forwardRef(({className:e,...t},n)=>a.jsx(bn.Root,{className:N("pr-twp tw-grid tw-gap-2",e),...t,ref:n}));po.displayName=bn.Root.displayName;const Yn=g.forwardRef(({className:e,...t},n)=>a.jsx(bn.Item,{ref:n,className:N("pr-twp tw-aspect-square tw-h-4 tw-w-4 tw-rounded-full tw-border tw-border-primary tw-text-primary tw-ring-offset-background focus:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-cursor-not-allowed disabled:tw-opacity-50",e),...t,children:a.jsx(bn.Indicator,{className:"tw-flex tw-items-center tw-justify-center",children:a.jsx(Q.Circle,{className:"tw-h-2.5 tw-w-2.5 tw-fill-current tw-text-current"})})}));Yn.displayName=bn.Item.displayName;const sc=vn.Root,ic=vn.Trigger,fs=g.forwardRef(({className:e,align:t="center",sideOffset:n=4,...r},o)=>a.jsx(vn.Portal,{children:a.jsx(vn.Content,{ref:o,align:t,sideOffset:n,className:N("pr-twp tw-z-50 tw-w-72 tw-rounded-md tw-border tw-bg-popover tw-p-4 tw-text-popover-foreground tw-shadow-md tw-outline-none data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0 data-[state=closed]:tw-zoom-out-95 data-[state=open]:tw-zoom-in-95 data-[side=bottom]:tw-slide-in-from-top-2 data-[side=left]:tw-slide-in-from-right-2 data-[side=right]:tw-slide-in-from-left-2 data-[side=top]:tw-slide-in-from-bottom-2",e),...r})}));fs.displayName=vn.Content.displayName;const lc=be.Portal,ms=g.forwardRef(({className:e,...t},n)=>a.jsx(be.Overlay,{ref:n,className:N("tw-fixed tw-inset-0 tw-z-50 tw-bg-black/80 data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0",e),...t}));ms.displayName=be.Overlay.displayName;const cc=g.forwardRef(({className:e,children:t,...n},r)=>a.jsxs(lc,{children:[a.jsx(ms,{}),a.jsxs(be.Content,{ref:r,className:N("tw-fixed tw-left-[50%] tw-top-[50%] tw-z-50 tw-grid tw-w-full tw-max-w-lg tw-translate-x-[-50%] tw-translate-y-[-50%] tw-gap-4 tw-border tw-bg-background tw-p-6 tw-shadow-lg tw-duration-200 data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0 data-[state=closed]:tw-zoom-out-95 data-[state=open]:tw-zoom-in-95 data-[state=closed]:tw-slide-out-to-left-1/2 data-[state=closed]:tw-slide-out-to-top-[48%] data-[state=open]:tw-slide-in-from-left-1/2 data-[state=open]:tw-slide-in-from-top-[48%] sm:tw-rounded-lg",e),...n,children:[t,a.jsxs(be.Close,{className:"tw-absolute tw-right-4 tw-top-4 tw-rounded-sm tw-opacity-70 tw-ring-offset-background tw-transition-opacity hover:tw-opacity-100 focus:tw-outline-none focus:tw-ring-2 focus:tw-ring-ring focus:tw-ring-offset-2 disabled:tw-pointer-events-none data-[state=open]:tw-bg-accent data-[state=open]:tw-text-muted-foreground",children:[a.jsx(Q.X,{className:"tw-h-4 tw-w-4"}),a.jsx("span",{className:"tw-sr-only",children:"Close"})]})]})]}));cc.displayName=be.Content.displayName;const dc=g.forwardRef(({className:e,...t},n)=>a.jsx(be.Title,{ref:n,className:N("tw-text-lg tw-font-semibold tw-leading-none tw-tracking-tight",e),...t}));dc.displayName=be.Title.displayName;const uc=g.forwardRef(({className:e,...t},n)=>a.jsx(be.Description,{ref:n,className:N("tw-text-sm tw-text-muted-foreground",e),...t}));uc.displayName=be.Description.displayName;const hs=g.forwardRef(({className:e,...t},n)=>a.jsx(Re.Command,{ref:n,className:N("tw-flex tw-h-full tw-w-full tw-flex-col tw-overflow-hidden tw-rounded-md tw-bg-popover tw-text-popover-foreground",e),...t}));hs.displayName=Re.Command.displayName;const gs=g.forwardRef(({className:e,...t},n)=>a.jsxs("div",{className:"tw-flex tw-items-center tw-border-b tw-px-3",children:[a.jsx(Q.Search,{className:"tw-me-2 tw-h-4 tw-w-4 tw-shrink-0 tw-opacity-50"}),a.jsx(Re.Command.Input,{ref:n,className:N("tw-flex tw-h-11 tw-w-full tw-rounded-md tw-bg-transparent tw-py-3 tw-text-sm tw-outline-none placeholder:tw-text-muted-foreground disabled:tw-cursor-not-allowed disabled:tw-opacity-50",e),...t})]}));gs.displayName=Re.Command.Input.displayName;const bs=g.forwardRef(({className:e,...t},n)=>a.jsx(Re.Command.List,{ref:n,className:N("tw-max-h-[300px] tw-overflow-y-auto tw-overflow-x-hidden",e),...t}));bs.displayName=Re.Command.List.displayName;const vs=g.forwardRef((e,t)=>a.jsx(Re.Command.Empty,{ref:t,className:"tw-py-6 tw-text-center tw-text-sm",...e}));vs.displayName=Re.Command.Empty.displayName;const pc=g.forwardRef(({className:e,...t},n)=>a.jsx(Re.Command.Group,{ref:n,className:N("tw-overflow-hidden tw-p-1 tw-text-foreground [&_[cmdk-group-heading]]:tw-px-2 [&_[cmdk-group-heading]]:tw-py-1.5 [&_[cmdk-group-heading]]:tw-text-xs [&_[cmdk-group-heading]]:tw-font-medium [&_[cmdk-group-heading]]:tw-text-muted-foreground",e),...t}));pc.displayName=Re.Command.Group.displayName;const wc=g.forwardRef(({className:e,...t},n)=>a.jsx(Re.Command.Separator,{ref:n,className:N("tw--mx-1 tw-h-px tw-bg-border",e),...t}));wc.displayName=Re.Command.Separator.displayName;const xs=g.forwardRef(({className:e,...t},n)=>a.jsx(Re.Command.Item,{ref:n,className:N("tw-relative tw-flex tw-cursor-default tw-select-none tw-items-center tw-rounded-sm tw-px-2 tw-py-1.5 tw-text-sm tw-outline-none data-[disabled=true]:tw-pointer-events-none data-[selected=true]:tw-bg-accent data-[selected=true]:tw-text-accent-foreground data-[disabled=true]:tw-opacity-50",e),...t}));xs.displayName=Re.Command.Item.displayName;function fc(e){return typeof e=="string"?e:typeof e=="number"?e.toString():e.label}function Wn({id:e,options:t=[],buttonClassName:n,popoverContentClassName:r,value:o,onChange:s=()=>{},getOptionLabel:i=fc,buttonPlaceholder:l="",textPlaceholder:c="",commandEmptyMessage:d="No option found",buttonVariant:u="outline",dir:f="ltr",isDisabled:w=!1,...b}){const[x,m]=g.useState(!1);return a.jsxs(sc,{open:x,onOpenChange:m,...b,children:[a.jsx(ic,{asChild:!0,children:a.jsxs(fe,{variant:u,role:"combobox","aria-expanded":x,id:e,className:N("tw-w-[200px] tw-justify-between",n),disabled:w,children:[a.jsx("span",{className:"tw-overflow-hidden tw-text-ellipsis tw-whitespace-nowrap",children:o?i(o):l}),a.jsx(Q.ChevronsUpDown,{className:"tw-ms-2 tw-h-4 tw-w-4 tw-shrink-0 tw-opacity-50"})]})}),a.jsx(fs,{className:N("tw-w-[200px] tw-p-0",r),dir:f,children:a.jsxs(hs,{children:[a.jsx(gs,{dir:f,placeholder:c,className:"tw-text-inherit"}),a.jsx(vs,{children:d}),a.jsx(bs,{children:t.map(h=>a.jsxs(xs,{value:i(h),onSelect:()=>{s(h),m(!1)},children:[a.jsx(Q.Check,{className:N("tw-me-2 tw-h-4 tw-w-4",{"tw-opacity-0":!o||i(o)!==i(h)})}),i(h)]},i(h)))})]})})]})}function ys({startChapter:e,endChapter:t,handleSelectStartChapter:n,handleSelectEndChapter:r,isDisabled:o=!1,chapterCount:s}){const i=g.useMemo(()=>Array.from({length:s},(d,u)=>u+1),[s]),l=d=>{n(d),d>t&&r(d)},c=d=>{r(d),dd.toString(),value:e},"start chapter"),a.jsx(qe,{htmlFor:"end-chapters-combobox",children:"to"}),a.jsx(Wn,{isDisabled:o,onChange:c,buttonClassName:"tw-ml-2 tw-w-20",options:i,getOptionLabel:d=>d.toString(),value:t},"end chapter")]})}var Ns=(e=>(e.CURRENT_BOOK="current book",e.CHOOSE_BOOKS="choose books",e))(Ns||{});const mc=Object.freeze(["%webView_bookSelector_currentBook%","%webView_bookSelector_choose%","%webView_bookSelector_chooseBooks%"]),Tr=(e,t)=>e[t]??t;function hc({handleBookSelectionModeChange:e,currentBookName:t,onSelectBooks:n,selectedBookIds:r,chapterCount:o,endChapter:s,handleSelectEndChapter:i,startChapter:l,handleSelectStartChapter:c,localizedStrings:d}){const u=Tr(d,"%webView_bookSelector_currentBook%"),f=Tr(d,"%webView_bookSelector_choose%"),w=Tr(d,"%webView_bookSelector_chooseBooks%"),[b,x]=g.useState("current book"),m=h=>{x(h),e(h)};return a.jsx(po,{className:"pr-twp tw-flex",value:b,onValueChange:h=>m(h),children:a.jsxs("div",{className:"tw-flex tw-w-full tw-flex-col tw-gap-4",children:[a.jsxs("div",{className:"tw-grid tw-grid-cols-[25%,25%,50%]",children:[a.jsxs("div",{className:"tw-flex tw-items-center",children:[a.jsx(Yn,{value:"current book"}),a.jsx(qe,{className:"tw-ml-1",children:u})]}),a.jsx(qe,{className:"tw-flex tw-items-center",children:t}),a.jsx("div",{className:"tw-flex tw-items-center tw-justify-end",children:a.jsx(ys,{isDisabled:b==="choose books",handleSelectStartChapter:c,handleSelectEndChapter:i,chapterCount:o,startChapter:l,endChapter:s})})]}),a.jsxs("div",{className:"tw-grid tw-grid-cols-[25%,50%,25%]",children:[a.jsxs("div",{className:"tw-flex tw-items-center",children:[a.jsx(Yn,{value:"choose books"}),a.jsx(qe,{className:"tw-ml-1",children:w})]}),a.jsx(qe,{className:"tw-flex tw-items-center",children:r.map(h=>ae.bookIdToEnglishName(h)).join(", ")}),a.jsx(fe,{disabled:b==="current book",onClick:()=>n(),children:f})]})]})})}function gc({table:e}){return a.jsxs(or,{children:[a.jsx(Za.DropdownMenuTrigger,{asChild:!0,children:a.jsxs(fe,{variant:"outline",size:"sm",className:"tw-ml-auto tw-hidden tw-h-8 lg:tw-flex",children:[a.jsx(Q.FilterIcon,{className:"tw-mr-2 tw-h-4 tw-w-4"}),"View"]})}),a.jsxs(En,{align:"end",className:"tw-w-[150px]",children:[a.jsx(Wt,{children:"Toggle columns"}),a.jsx(jn,{}),e.getAllColumns().filter(t=>t.getCanHide()).map(t=>a.jsx(ar,{className:"tw-capitalize",checked:t.getIsVisible(),onCheckedChange:n=>t.toggleVisibility(!!n),children:t.id},t.id))]})]})}const At=ge.Root,ks=ge.Group,Bt=ge.Value,bt=g.forwardRef(({className:e,children:t,...n},r)=>a.jsxs(ge.Trigger,{ref:r,className:N("tw-flex tw-h-10 tw-w-full tw-items-center tw-justify-between tw-rounded-md tw-border tw-border-input tw-bg-background tw-px-3 tw-py-2 tw-text-sm tw-ring-offset-background placeholder:tw-text-muted-foreground focus:tw-outline-none focus:tw-ring-2 focus:tw-ring-ring focus:tw-ring-offset-2 disabled:tw-cursor-not-allowed disabled:tw-opacity-50 [&>span]:tw-line-clamp-1",e),...n,children:[t,a.jsx(ge.Icon,{asChild:!0,children:a.jsx(Q.ChevronDown,{className:"tw-h-4 tw-w-4 tw-opacity-50"})})]}));bt.displayName=ge.Trigger.displayName;const wo=g.forwardRef(({className:e,...t},n)=>a.jsx(ge.ScrollUpButton,{ref:n,className:N("tw-flex tw-cursor-default tw-items-center tw-justify-center tw-py-1",e),...t,children:a.jsx(Q.ChevronUp,{className:"tw-h-4 tw-w-4"})}));wo.displayName=ge.ScrollUpButton.displayName;const fo=g.forwardRef(({className:e,...t},n)=>a.jsx(ge.ScrollDownButton,{ref:n,className:N("tw-flex tw-cursor-default tw-items-center tw-justify-center tw-py-1",e),...t,children:a.jsx(Q.ChevronDown,{className:"tw-h-4 tw-w-4"})}));fo.displayName=ge.ScrollDownButton.displayName;const vt=g.forwardRef(({className:e,children:t,position:n="popper",...r},o)=>a.jsx(ge.Portal,{children:a.jsxs(ge.Content,{ref:o,className:N("pr-twp tw-relative tw-z-50 tw-max-h-96 tw-min-w-[8rem] tw-overflow-hidden tw-rounded-md tw-border tw-bg-popover tw-text-popover-foreground tw-shadow-md data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0 data-[state=closed]:tw-zoom-out-95 data-[state=open]:tw-zoom-in-95 data-[side=bottom]:tw-slide-in-from-top-2 data-[side=left]:tw-slide-in-from-right-2 data-[side=right]:tw-slide-in-from-left-2 data-[side=top]:tw-slide-in-from-bottom-2",n==="popper"&&"data-[side=bottom]:tw-translate-y-1 data-[side=left]:tw--translate-x-1 data-[side=right]:tw-translate-x-1 data-[side=top]:tw--translate-y-1",e),position:n,...r,children:[a.jsx(wo,{}),a.jsx(ge.Viewport,{className:N("tw-p-1",n==="popper"&&"tw-h-[var(--radix-select-trigger-height)] tw-w-full tw-min-w-[var(--radix-select-trigger-width)]"),children:t}),a.jsx(fo,{})]})}));vt.displayName=ge.Content.displayName;const Ss=g.forwardRef(({className:e,...t},n)=>a.jsx(ge.Label,{ref:n,className:N("tw-py-1.5 tw-pl-8 tw-pr-2 tw-text-sm tw-font-semibold",e),...t}));Ss.displayName=ge.Label.displayName;const Ae=g.forwardRef(({className:e,children:t,...n},r)=>a.jsxs(ge.Item,{ref:r,className:N("tw-relative tw-flex tw-w-full tw-cursor-default tw-select-none tw-items-center tw-rounded-sm tw-py-1.5 tw-pl-8 tw-pr-2 tw-text-sm tw-outline-none focus:tw-bg-accent focus:tw-text-accent-foreground data-[disabled]:tw-pointer-events-none data-[disabled]:tw-opacity-50",e),...n,children:[a.jsx("span",{className:"tw-absolute tw-left-2 tw-flex tw-h-3.5 tw-w-3.5 tw-items-center tw-justify-center",children:a.jsx(ge.ItemIndicator,{children:a.jsx(Q.Check,{className:"tw-h-4 tw-w-4"})})}),a.jsx(ge.ItemText,{children:t})]}));Ae.displayName=ge.Item.displayName;const Es=g.forwardRef(({className:e,...t},n)=>a.jsx(ge.Separator,{ref:n,className:N("tw--mx-1 tw-my-1 tw-h-px tw-bg-muted",e),...t}));Es.displayName=ge.Separator.displayName;function bc({table:e}){return a.jsx("div",{className:"tw-flex tw-items-center tw-justify-between tw-px-2 tw-pb-3 tw-pt-3",children:a.jsxs("div",{className:"tw-flex tw-items-center tw-space-x-6 lg:tw-space-x-8",children:[a.jsxs("div",{className:"tw-flex-1 tw-text-sm tw-text-muted-foreground",children:[e.getFilteredSelectedRowModel().rows.length," of"," ",e.getFilteredRowModel().rows.length," row(s) selected"]}),a.jsxs("div",{className:"tw-flex tw-items-center tw-space-x-2",children:[a.jsx("p",{className:"tw-text-nowrap tw-text-sm tw-font-medium",children:"Rows per page"}),a.jsxs(At,{value:`${e.getState().pagination.pageSize}`,onValueChange:t=>{e.setPageSize(Number(t))},children:[a.jsx(bt,{className:"tw-h-8 tw-w-[70px]",children:a.jsx(Bt,{placeholder:e.getState().pagination.pageSize})}),a.jsx(vt,{side:"top",children:[10,20,30,40,50].map(t=>a.jsx(Ae,{value:`${t}`,children:t},t))})]})]}),a.jsxs("div",{className:"tw-flex tw-w-[100px] tw-items-center tw-justify-center tw-text-sm tw-font-medium",children:["Page ",e.getState().pagination.pageIndex+1," of ",e.getPageCount()]}),a.jsxs("div",{className:"tw-flex tw-items-center tw-space-x-2",children:[a.jsxs(fe,{variant:"outline",size:"icon",className:"tw-hidden tw-h-8 tw-w-8 tw-p-0 lg:tw-flex",onClick:()=>e.setPageIndex(0),disabled:!e.getCanPreviousPage(),children:[a.jsx("span",{className:"tw-sr-only",children:"Go to first page"}),a.jsx(Q.ArrowLeftIcon,{className:"tw-h-4 tw-w-4"})]}),a.jsxs(fe,{variant:"outline",size:"icon",className:"tw-h-8 tw-w-8 tw-p-0",onClick:()=>e.previousPage(),disabled:!e.getCanPreviousPage(),children:[a.jsx("span",{className:"tw-sr-only",children:"Go to previous page"}),a.jsx(Q.ChevronLeftIcon,{className:"tw-h-4 tw-w-4"})]}),a.jsxs(fe,{variant:"outline",size:"icon",className:"tw-h-8 tw-w-8 tw-p-0",onClick:()=>e.nextPage(),disabled:!e.getCanNextPage(),children:[a.jsx("span",{className:"tw-sr-only",children:"Go to next page"}),a.jsx(Q.ChevronRightIcon,{className:"tw-h-4 tw-w-4"})]}),a.jsxs(fe,{variant:"outline",size:"icon",className:"tw-hidden tw-h-8 tw-w-8 tw-p-0 lg:tw-flex",onClick:()=>e.setPageIndex(e.getPageCount()-1),disabled:!e.getCanNextPage(),children:[a.jsx("span",{className:"tw-sr-only",children:"Go to last page"}),a.jsx(Q.ArrowRightIcon,{className:"tw-h-4 tw-w-4"})]})]})]})})}const Cn=g.forwardRef(({className:e,stickyHeader:t,...n},r)=>a.jsx("div",{className:N("pr-twp tw-relative tw-w-full",{"tw-overflow-auto":!t}),children:a.jsx("table",{ref:r,className:N("tw-w-full tw-caption-bottom tw-text-sm",e),...n})}));Cn.displayName="Table";const Tn=g.forwardRef(({className:e,stickyHeader:t,...n},r)=>a.jsx("thead",{ref:r,className:N({"tw-sticky tw-top-[-1px] tw-bg-background tw-drop-shadow-sm":t},"[&_tr]:tw-border-b",e),...n}));Tn.displayName="TableHeader";const Rn=g.forwardRef(({className:e,...t},n)=>a.jsx("tbody",{ref:n,className:N("[&_tr:last-child]:tw-border-0",e),...t}));Rn.displayName="TableBody";const js=g.forwardRef(({className:e,...t},n)=>a.jsx("tfoot",{ref:n,className:N("tw-border-t tw-bg-muted/50 tw-font-medium [&>tr]:last:tw-border-b-0",e),...t}));js.displayName="TableFooter";const Ze=g.forwardRef(({className:e,...t},n)=>a.jsx("tr",{ref:n,className:N("tw-border-b tw-transition-colors hover:tw-bg-muted/50 data-[state=selected]:tw-bg-muted",e),...t}));Ze.displayName="TableRow";const Vt=g.forwardRef(({className:e,...t},n)=>a.jsx("th",{ref:n,className:N("tw-h-12 tw-px-4 tw-text-start tw-align-middle tw-font-medium tw-text-muted-foreground [&:has([role=checkbox])]:tw-pe-0",e),...t}));Vt.displayName="TableHead";const xt=g.forwardRef(({className:e,...t},n)=>a.jsx("td",{ref:n,className:N("tw-p-4 tw-align-middle [&:has([role=checkbox])]:tw-pe-0",e),...t}));xt.displayName="TableCell";const Cs=g.forwardRef(({className:e,...t},n)=>a.jsx("caption",{ref:n,className:N("tw-mt-4 tw-text-sm tw-text-muted-foreground",e),...t}));Cs.displayName="TableCaption";function Ts({columns:e,data:t,enablePagination:n=!1,showPaginationControls:r=!1,showColumnVisibilityControls:o=!1,stickyHeader:s=!1,onRowClickHandler:i=()=>{}}){var h;const[l,c]=g.useState([]),[d,u]=g.useState([]),[f,w]=g.useState({}),[b,x]=g.useState({}),m=Se.useReactTable({data:t,columns:e,getCoreRowModel:Se.getCoreRowModel(),...n&&{getPaginationRowModel:Se.getPaginationRowModel()},onSortingChange:c,getSortedRowModel:Se.getSortedRowModel(),onColumnFiltersChange:u,getFilteredRowModel:Se.getFilteredRowModel(),onColumnVisibilityChange:w,onRowSelectionChange:x,state:{sorting:l,columnFilters:d,columnVisibility:f,rowSelection:b}});return a.jsxs("div",{className:"pr-twp",children:[o&&a.jsx(gc,{table:m}),a.jsxs(Cn,{stickyHeader:s,children:[a.jsx(Tn,{stickyHeader:s,children:m.getHeaderGroups().map(S=>a.jsx(Ze,{children:S.headers.map(R=>a.jsx(Vt,{children:R.isPlaceholder?void 0:Se.flexRender(R.column.columnDef.header,R.getContext())},R.id))},S.id))}),a.jsx(Rn,{children:(h=m.getRowModel().rows)!=null&&h.length?m.getRowModel().rows.map(S=>a.jsx(Ze,{onClick:()=>i(S,m),"data-state":S.getIsSelected()&&"selected",children:S.getVisibleCells().map(R=>a.jsx(xt,{children:Se.flexRender(R.column.columnDef.cell,R.getContext())},R.id))},S.id)):a.jsx(Ze,{children:a.jsx(xt,{colSpan:e.length,className:"tw-h-24 tw-text-center",children:"No results."})})})]}),n&&a.jsxs("div",{className:"tw-flex tw-items-center tw-justify-end tw-space-x-2 tw-py-4",children:[a.jsx(fe,{variant:"outline",size:"sm",onClick:()=>m.previousPage(),disabled:!m.getCanPreviousPage(),children:"Previous"}),a.jsx(fe,{variant:"outline",size:"sm",onClick:()=>m.nextPage(),disabled:!m.getCanNextPage(),children:"Next"})]}),n&&r&&a.jsx(bc,{table:m})]})}function vc({occurrenceData:e,setScriptureReference:t,localizedStrings:n}){const r=n["%webView_inventory_occurrences_table_header_reference%"],o=n["%webView_inventory_occurrences_table_header_occurrence%"],s=g.useMemo(()=>{const i=[];return e.forEach(l=>{i.some(c=>W.deepEqual(c,l))||i.push(l)}),i},[e]);return a.jsxs(Cn,{stickyHeader:!0,children:[a.jsx(Tn,{stickyHeader:!0,children:a.jsxs(Ze,{children:[a.jsx(Vt,{children:r}),a.jsx(Vt,{children:o})]})}),a.jsx(Rn,{children:s.length>0&&s.map(i=>a.jsxs(Ze,{onClick:()=>{t(i.reference)},children:[a.jsx(xt,{children:`${ae.bookNumberToEnglishName(i.reference.bookNum)} ${i.reference.chapterNum}:${i.reference.verseNum}`}),a.jsx(xt,{children:i.text})]},`${i.reference.bookNum} ${i.reference.chapterNum}:${i.reference.verseNum}-${i.text}`))})]})}const sr=g.forwardRef(({className:e,...t},n)=>a.jsx(Ur.Root,{ref:n,className:N("tw-peer pr-twp tw-h-4 tw-w-4 tw-shrink-0 tw-rounded-sm tw-border tw-border-primary tw-ring-offset-background focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-cursor-not-allowed disabled:tw-opacity-50 data-[state=checked]:tw-bg-primary data-[state=checked]:tw-text-primary-foreground",e),...t,children:a.jsx(Ur.Indicator,{className:N("tw-flex tw-items-center tw-justify-center tw-text-current"),children:a.jsx(Q.Check,{className:"tw-h-4 tw-w-4"})})}));sr.displayName=Ur.Root.displayName;const Rs=e=>e.split(/(?:\r?\n|\r)|(?=(?:\\(?:v|c|id)))/g),Hr=e=>{const t=/^\\[vc]\s+(\d+)/,n=e.match(t);if(n)return+n[1]},Os=e=>{const t=e.match(/^\\id\s+([A-Za-z]+)/);return t?ae.bookIdToNumber(t[1]):0},_s=(e,t,n)=>n.includes(e)?"unapproved":t.includes(e)?"approved":"unknown",Ps=Xt.cva("pr-twp tw-inline-flex tw-items-center tw-justify-center tw-rounded-md tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-colors hover:tw-bg-muted hover:tw-text-muted-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50 data-[state=on]:tw-bg-accent data-[state=on]:tw-text-accent-foreground",{variants:{variant:{default:"tw-bg-transparent",outline:"tw-border tw-border-input tw-bg-transparent hover:tw-bg-accent hover:tw-text-accent-foreground"},size:{default:"tw-h-10 tw-px-3",sm:"tw-h-9 tw-px-2.5",lg:"tw-h-11 tw-px-5"}},defaultVariants:{variant:"default",size:"default"}}),xc=g.forwardRef(({className:e,variant:t,size:n,...r},o)=>a.jsx(ts.Root,{ref:o,className:N(Ps({variant:t,size:n,className:e})),...r}));xc.displayName=ts.Root.displayName;const Is=g.createContext({size:"default",variant:"default"}),mo=g.forwardRef(({className:e,variant:t,size:n,children:r,...o},s)=>a.jsx(rr.Root,{ref:s,className:N("pr-twp tw-flex tw-items-center tw-justify-center tw-gap-1",e),...o,children:a.jsx(Is.Provider,{value:{variant:t,size:n},children:r})}));mo.displayName=rr.Root.displayName;const fn=g.forwardRef(({className:e,children:t,variant:n,size:r,...o},s)=>{const i=g.useContext(Is);return a.jsx(rr.Item,{ref:s,className:N(Ps({variant:i.variant||n,size:i.size||r}),e),...o,children:t})});fn.displayName=rr.Item.displayName;const ir=e=>e==="asc"?a.jsx(Q.ArrowUpIcon,{className:"tw-ms-2 tw-h-4 tw-w-4"}):e==="desc"?a.jsx(Q.ArrowDownIcon,{className:"tw-ms-2 tw-h-4 tw-w-4"}):a.jsx(Q.ArrowUpDownIcon,{className:"tw-ms-2 tw-h-4 tw-w-4"}),yc=e=>({accessorKey:"item",accessorFn:t=>t.items[0],header:({column:t})=>a.jsxs(fe,{variant:"ghost",onClick:()=>t.toggleSorting(void 0),children:[e,ir(t.getIsSorted())]})}),Nc=(e,t)=>({accessorKey:`item${t}`,accessorFn:n=>n.items[t],header:({column:n})=>a.jsxs(fe,{variant:"ghost",onClick:()=>n.toggleSorting(void 0),children:[e,ir(n.getIsSorted())]})}),kc=e=>({accessorKey:"count",header:({column:t})=>a.jsx("div",{className:"tw-flex tw-justify-end tw-tabular-nums",children:a.jsxs(fe,{variant:"ghost",onClick:()=>t.toggleSorting(void 0),children:[e,ir(t.getIsSorted())]})}),cell:({row:t})=>a.jsx("div",{className:"tw-flex tw-justify-end",children:t.getValue("count")})}),Rr=(e,t,n,r,o,s)=>{let i=[...n];e.forEach(c=>{t==="approved"?i.includes(c)||i.push(c):i=i.filter(d=>d!==c)}),r(i);let l=[...o];e.forEach(c=>{t==="unapproved"?l.includes(c)||l.push(c):l=l.filter(d=>d!==c)}),s(l)},Sc=(e,t,n,r,o)=>({accessorKey:"status",header:({column:s})=>a.jsx("div",{className:"tw-flex tw-justify-center",children:a.jsxs(fe,{variant:"ghost",onClick:()=>s.toggleSorting(void 0),children:[e,ir(s.getIsSorted())]})}),cell:({row:s})=>{const i=s.getValue("status"),l=s.getValue("item");return a.jsxs(mo,{value:i,variant:"outline",type:"single",children:[a.jsx(fn,{onClick:()=>Rr([l],"approved",t,n,r,o),value:"approved",children:a.jsx(Q.CircleCheckIcon,{})}),a.jsx(fn,{onClick:()=>Rr([l],"unapproved",t,n,r,o),value:"unapproved",children:a.jsx(Q.CircleXIcon,{})}),a.jsx(fn,{onClick:()=>Rr([l],"unknown",t,n,r,o),value:"unknown",children:a.jsx(Q.CircleHelpIcon,{})})]})}}),Ec=Object.freeze(["%webView_inventory_all%","%webView_inventory_approved%","%webView_inventory_unapproved%","%webView_inventory_unknown%","%webView_inventory_scope_currentBook%","%webView_inventory_scope_chapter%","%webView_inventory_scope_verse%","%webView_inventory_filter_text%","%webView_inventory_show_additional_items%","%webView_inventory_occurrences_table_header_reference%","%webView_inventory_occurrences_table_header_occurrence%"]),jc=(e,t,n)=>{let r=e;return t!=="all"&&(r=r.filter(o=>t==="approved"&&o.status==="approved"||t==="unapproved"&&o.status==="unapproved"||t==="unknown"&&o.status==="unknown")),n!==""&&(r=r.filter(o=>o.items[0].includes(n))),r},Cc=(e,t,n,r,o)=>{if(!e)return[];const s=[];let i=t.bookNum,l=t.chapterNum,c=t.verseNum;return Rs(e).forEach(u=>{u.startsWith("\\id")&&(i=Os(u),l=0,c=0),u.startsWith("\\c")&&(l=Hr(u),c=0),u.startsWith("\\v")&&(c=Hr(u),l===0&&(l=t.chapterNum));let f=o.exec(u)??void 0;for(;f;){const w=[];f.forEach(h=>w.push(h));const b=f.index,x=s.find(h=>W.deepEqual(h.items,w)),m={reference:{bookNum:i!==void 0?i:-1,chapterNum:l!==void 0?l:-1,verseNum:c!==void 0?c:-1},text:W.substring(u,Math.max(0,b-25),Math.min(b+25,u.length))};if(x)x.count+=1,x.occurrences.push(m);else{const h={items:w,count:1,status:_s(w[0],n,r),occurrences:[m]};s.push(h)}f=o.exec(u)??void 0}}),s},Je=(e,t)=>e[t]??t;function Tc({scriptureReference:e,setScriptureReference:t,localizedStrings:n,extractItems:r,additionalItemsLabels:o,approvedItems:s,unapprovedItems:i,text:l,scope:c,onScopeChange:d,columns:u}){const f=Je(n,"%webView_inventory_all%"),w=Je(n,"%webView_inventory_approved%"),b=Je(n,"%webView_inventory_unapproved%"),x=Je(n,"%webView_inventory_unknown%"),m=Je(n,"%webView_inventory_scope_currentBook%"),h=Je(n,"%webView_inventory_scope_chapter%"),S=Je(n,"%webView_inventory_scope_verse%"),R=Je(n,"%webView_inventory_filter_text%"),j=Je(n,"%webView_inventory_show_additional_items%"),[E,v]=g.useState(!1),[P,V]=g.useState("all"),[U,C]=g.useState(""),[_,k]=g.useState([]),D=g.useMemo(()=>l?r instanceof RegExp?Cc(l,e,s,i,r):r(l,e,s,i):[],[l,r,e,s,i]),$=g.useMemo(()=>{if(E)return D;const y=[];return D.forEach(T=>{const z=T.items[0],L=y.find(B=>B.items[0]===z);L?(L.count+=T.count,L.occurrences=L.occurrences.concat(T.occurrences)):y.push({items:[z],count:T.count,occurrences:T.occurrences,status:T.status})}),y},[E,D]),J=g.useMemo(()=>jc($,P,U),[$,P,U]),Y=g.useMemo(()=>{var z,L;if(!E)return u;const y=(z=o==null?void 0:o.tableHeaders)==null?void 0:z.length;if(!y)return u;const T=[];for(let B=0;B{k([])},[J]);const F=(y,T)=>{T.setRowSelection(()=>{const z={};return z[y.index]=!0,z}),k(y.original.items)},te=y=>{if(y==="book"||y==="chapter"||y==="verse")d(y);else throw new Error(`Invalid scope value: ${y}`)},se=y=>{if(y==="all"||y==="approved"||y==="unapproved"||y==="unknown")V(y);else throw new Error(`Invalid status filter value: ${y}`)},oe=g.useMemo(()=>{if($.length===0||_.length===0)return[];const y=$.filter(T=>W.deepEqual(E?T.items:[T.items[0]],_));if(y.length>1)throw new Error("Selected item is not unique");return y[0].occurrences},[_,E,$]);return a.jsxs("div",{className:"pr-twp tw-flex tw-h-full tw-flex-col",children:[a.jsxs("div",{className:"tw-flex tw-items-stretch",children:[a.jsxs(At,{onValueChange:y=>se(y),defaultValue:P,children:[a.jsx(bt,{className:"tw-m-1",children:a.jsx(Bt,{placeholder:"Select filter"})}),a.jsxs(vt,{children:[a.jsx(Ae,{value:"all",children:f}),a.jsx(Ae,{value:"approved",children:w}),a.jsx(Ae,{value:"unapproved",children:b}),a.jsx(Ae,{value:"unknown",children:x})]})]}),a.jsxs(At,{onValueChange:y=>te(y),defaultValue:c,children:[a.jsx(bt,{className:"tw-m-1",children:a.jsx(Bt,{placeholder:"Select scope"})}),a.jsxs(vt,{children:[a.jsx(Ae,{value:"book",children:m}),a.jsx(Ae,{value:"chapter",children:h}),a.jsx(Ae,{value:"verse",children:S})]})]}),a.jsx(St,{className:"tw-m-1 tw-rounded-md tw-border",placeholder:R,value:U,onChange:y=>{C(y.target.value)}}),o&&a.jsxs("div",{className:"tw-m-1 tw-flex tw-items-center tw-rounded-md tw-border",children:[a.jsx(sr,{className:"tw-m-1",checked:E,onCheckedChange:y=>{k([]),v(y)}}),a.jsx(qe,{className:"tw-m-1 tw-flex-shrink-0 tw-whitespace-nowrap",children:(o==null?void 0:o.checkboxText)??j})]})]}),a.jsx("div",{className:"tw-m-1 tw-flex-1 tw-overflow-auto tw-rounded-md tw-border",children:a.jsx(Ts,{columns:Y,data:J,onRowClickHandler:F,stickyHeader:!0})}),oe.length>0&&a.jsx("div",{className:"tw-m-1 tw-flex-1 tw-overflow-auto tw-rounded-md tw-border",children:a.jsx(vc,{occurrenceData:oe,setScriptureReference:t,localizedStrings:n})})]})}function ho({className:e,onSearch:t,placeholder:n,isFullWidth:r}){const[o,s]=g.useState(""),i=l=>{s(l),t(l)};return a.jsx(St,{className:N("tw-flex tw-h-10 tw-rounded-md tw-border tw-border-input tw-bg-background tw-px-3 tw-py-2 tw-text-sm tw-ring-offset-background file:tw-border-0 file:tw-bg-transparent file:tw-text-sm file:tw-font-medium placeholder:tw-text-muted-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-[color:hsl(240,5%,64.9%)] focus-visible:tw-ring-offset-2 disabled:tw-cursor-not-allowed disabled:tw-opacity-50",{"tw-w-full":r},e),placeholder:n,value:o,onChange:l=>i(l.target.value)})}const go=g.forwardRef(({className:e,...t},n)=>a.jsx(Oe.Root,{orientation:"vertical",ref:n,className:N("tw-flex tw-gap-1 tw-rounded-md tw-text-muted-foreground",e),...t}));go.displayName=Oe.List.displayName;const bo=g.forwardRef(({className:e,...t},n)=>a.jsx(Oe.List,{ref:n,className:N("tw-flex-fit tw-mlk-items-center tw-w-[124px] tw-justify-center tw-rounded-md tw-bg-muted tw-p-1 tw-text-muted-foreground",e),...t}));bo.displayName=Oe.List.displayName;const Ms=g.forwardRef(({className:e,...t},n)=>a.jsx(Oe.Trigger,{ref:n,...t,className:N("overflow-clip tw-inline-flex tw-w-[116px] tw-cursor-pointer tw-items-center tw-justify-center tw-break-words tw-rounded-sm tw-border-0 tw-bg-muted tw-px-3 tw-py-1.5 tw-text-sm tw-font-medium tw-text-inherit tw-ring-offset-background tw-transition-all hover:tw-text-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50 data-[state=active]:tw-bg-background data-[state=active]:tw-text-foreground data-[state=active]:tw-shadow-sm",e)})),vo=g.forwardRef(({className:e,...t},n)=>a.jsx(Oe.Content,{ref:n,className:N("tw-ms-5 tw-flex-grow tw-text-foreground tw-ring-offset-background focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2",e),...t}));vo.displayName=Oe.Content.displayName;function Rc({tabList:e,onSearch:t,searchPlaceholder:n,headerTitle:r,isSearchBarFullWidth:o=!1,direction:s="ltr"}){return a.jsxs("div",{className:"pr-twp",children:[a.jsxs("div",{className:"tw-sticky tw-top-0 tw-space-y-2 tw-pb-2",children:[r?a.jsx("h1",{children:r}):"",a.jsx(ho,{isFullWidth:o,onSearch:t,placeholder:n})]}),a.jsxs(go,{dir:s,children:[a.jsx(bo,{children:e.map(i=>a.jsx(Ms,{value:i.value,children:i.value},i.key))}),e.map(i=>a.jsx(vo,{value:i.value,children:i.content},i.key))]})]})}const lr=g.forwardRef(({className:e,orientation:t="horizontal",decorative:n=!0,...r},o)=>a.jsx(ns.Root,{ref:o,decorative:n,orientation:t,className:N("pr-twp tw-shrink-0 tw-bg-border",t==="horizontal"?"tw-h-[1px] tw-w-full":"tw-h-full tw-w-[1px]",e),...r}));lr.displayName=ns.Root.displayName;const Oc=be.Root,_c=be.Portal,$s=M.forwardRef(({className:e,...t},n)=>a.jsx(be.Overlay,{className:N("tw-fixed tw-inset-0 tw-z-50 tw-bg-black/80 data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0",e),...t,ref:n}));$s.displayName=be.Overlay.displayName;const Pc=Xt.cva("pr-twp tw-fixed tw-z-50 tw-gap-4 tw-bg-background tw-p-6 tw-shadow-lg tw-transition tw-ease-in-out data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-duration-300 data-[state=open]:tw-duration-500",{variants:{side:{top:"tw-inset-x-0 tw-top-0 tw-border-b data-[state=closed]:tw-slide-out-to-top data-[state=open]:tw-slide-in-from-top",bottom:"tw-inset-x-0 tw-bottom-0 tw-border-t data-[state=closed]:tw-slide-out-to-bottom data-[state=open]:tw-slide-in-from-bottom",left:"tw-inset-y-0 tw-left-0 tw-h-full tw-w-3/4 tw-border-r data-[state=closed]:tw-slide-out-to-left data-[state=open]:tw-slide-in-from-left sm:tw-max-w-sm",right:"tw-inset-y-0 tw-right-0 tw-h-full tw-w-3/4 tw- tw-border-l data-[state=closed]:tw-slide-out-to-right data-[state=open]:tw-slide-in-from-right sm:tw-max-w-sm"}},defaultVariants:{side:"right"}}),Ds=M.forwardRef(({side:e="right",className:t,children:n,...r},o)=>a.jsxs(_c,{children:[a.jsx($s,{}),a.jsxs(be.Content,{ref:o,className:N(Pc({side:e}),t),...r,children:[n,a.jsxs(be.Close,{className:"tw-absolute tw-right-4 tw-top-4 tw-rounded-sm tw-opacity-70 tw-ring-offset-background tw-transition-opacity hover:tw-opacity-100 focus:tw-outline-none focus:tw-ring-2 focus:tw-ring-ring focus:tw-ring-offset-2 disabled:tw-pointer-events-none data-[state=open]:tw-bg-secondary",children:[a.jsx(Q.X,{className:"tw-h-4 tw-w-4"}),a.jsx("span",{className:"tw-sr-only",children:"Close"})]})]})]}));Ds.displayName=be.Content.displayName;const Ic=M.forwardRef(({className:e,...t},n)=>a.jsx(be.Title,{ref:n,className:N("tw-text-lg tw-font-semibold tw-text-foreground",e),...t}));Ic.displayName=be.Title.displayName;const Mc=M.forwardRef(({className:e,...t},n)=>a.jsx(be.Description,{ref:n,className:N("tw-text-sm tw-text-muted-foreground",e),...t}));Mc.displayName=be.Description.displayName;function sa({className:e,...t}){return a.jsx("div",{className:N("pr-twp tw-animate-pulse tw-rounded-md tw-bg-muted",e),...t})}const $c=Sn.Provider,Dc=Sn.Root,Ac=Sn.Trigger,As=g.forwardRef(({className:e,sideOffset:t=4,...n},r)=>a.jsx(Sn.Content,{ref:r,sideOffset:t,className:N("pr-twp tw-z-50 tw-overflow-hidden tw-rounded-md tw-border tw-bg-popover tw-px-3 tw-py-1.5 tw-text-sm tw-text-popover-foreground tw-shadow-md tw-animate-in tw-fade-in-0 tw-zoom-in-95 data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=closed]:tw-zoom-out-95 data-[side=bottom]:tw-slide-in-from-top-2 data-[side=left]:tw-slide-in-from-right-2 data-[side=right]:tw-slide-in-from-left-2 data-[side=top]:tw-slide-in-from-bottom-2",e),...n}));As.displayName=Sn.Content.displayName;const Or=768;function Bc(){const[e,t]=M.useState(void 0);return M.useEffect(()=>{const n=window.matchMedia(`(max-width: ${Or-1}px)`),r=()=>{t(window.innerWidthn.removeEventListener("change",r)},[]),!!e}const Vc="sidebar:state",zc=60*60*24*7,Lc="16rem",Fc="18rem",Gc="3rem",Uc="b",Bs=g.createContext(void 0);function cr(){const e=g.useContext(Bs);if(!e)throw new Error("useSidebar must be used within a SidebarProvider.");return e}const Vs=g.forwardRef(({defaultOpen:e=!0,open:t,onOpenChange:n,className:r,style:o,children:s,...i},l)=>{const c=Bc(),[d,u]=g.useState(!1),[f,w]=g.useState(e),b=t??f,x=g.useCallback(R=>{const j=typeof R=="function"?R(b):R;n?n(j):w(j),document.cookie=`${Vc}=${j}; path=/; max-age=${zc}`},[n,b]),m=g.useCallback(()=>c?u(R=>!R):x(R=>!R),[c,x,u]);g.useEffect(()=>{const R=j=>{j.key===Uc&&(j.metaKey||j.ctrlKey)&&(j.preventDefault(),m())};return window.addEventListener("keydown",R),()=>window.removeEventListener("keydown",R)},[m]);const h=b?"expanded":"collapsed",S=g.useMemo(()=>({state:h,open:b,setOpen:x,isMobile:c,openMobile:d,setOpenMobile:u,toggleSidebar:m}),[h,b,x,c,d,u,m]);return a.jsx(Bs.Provider,{value:S,children:a.jsx($c,{delayDuration:0,children:a.jsx("div",{style:{"--sidebar-width":Lc,"--sidebar-width-icon":Gc,...o},className:N("tw-group/sidebar-wrapper pr-twp tw-flex tw-w-full has-[[data-variant=inset]]:tw-bg-sidebar",r),ref:l,...i,children:s})})})});Vs.displayName="SidebarProvider";const zs=g.forwardRef(({side:e="left",variant:t="sidebar",collapsible:n="offcanvas",className:r,children:o,...s},i)=>{const{isMobile:l,state:c,openMobile:d,setOpenMobile:u}=cr();return n==="none"?a.jsx("div",{className:N("tw-flex tw-h-full tw-w-[--sidebar-width] tw-flex-col tw-bg-sidebar tw-text-sidebar-foreground",r),ref:i,...s,children:o}):l?a.jsx(Oc,{open:d,onOpenChange:u,...s,children:a.jsx(Ds,{"data-sidebar":"sidebar","data-mobile":"true",className:"tw-w-[--sidebar-width] tw-bg-sidebar tw-p-0 tw-text-sidebar-foreground [&>button]:tw-hidden",style:{"--sidebar-width":Fc},side:e,children:a.jsx("div",{className:"tw-flex tw-h-full tw-w-full tw-flex-col",children:o})})}):a.jsxs("div",{ref:i,className:"tw-group tw-peer tw-hidden tw-text-sidebar-foreground md:tw-block","data-state":c,"data-collapsible":c==="collapsed"?n:"","data-variant":t,"data-side":e,children:[a.jsx("div",{className:N("tw-relative tw-h-svh tw-w-[--sidebar-width] tw-bg-transparent tw-transition-[width] tw-duration-200 tw-ease-linear","group-data-[collapsible=offcanvas]:tw-w-0","group-data-[side=right]:tw-rotate-180",t==="floating"||t==="inset"?"group-data-[collapsible=icon]:tw-w-[calc(var(--sidebar-width-icon)_+_theme(spacing.4))]":"group-data-[collapsible=icon]:tw-w-[--sidebar-width-icon]")}),a.jsx("div",{className:N("tw-absolute tw-inset-y-0 tw-z-10 tw-hidden tw-h-svh tw-w-[--sidebar-width] tw-transition-[left,right,width] tw-duration-200 tw-ease-linear md:tw-flex",e==="left"?"tw-left-0 group-data-[collapsible=offcanvas]:tw-left-[calc(var(--sidebar-width)*-1)]":"tw-right-0 group-data-[collapsible=offcanvas]:tw-right-[calc(var(--sidebar-width)*-1)]",t==="floating"||t==="inset"?"tw-p-2 group-data-[collapsible=icon]:tw-w-[calc(var(--sidebar-width-icon)_+_theme(spacing.4)_+2px)]":"group-data-[collapsible=icon]:tw-w-[--sidebar-width-icon] group-data-[side=left]:tw-border-r group-data-[side=right]:tw-border-l",r),...s,children:a.jsx("div",{"data-sidebar":"sidebar",className:"tw-flex tw-h-full tw-w-full tw-flex-col tw-bg-sidebar group-data-[variant=floating]:tw-rounded-lg group-data-[variant=floating]:tw-border group-data-[variant=floating]:tw-border-sidebar-border group-data-[variant=floating]:tw-shadow",children:o})})]})});zs.displayName="Sidebar";const qc=g.forwardRef(({className:e,onClick:t,...n},r)=>{const{toggleSidebar:o}=cr();return a.jsxs(fe,{ref:r,"data-sidebar":"trigger",variant:"ghost",size:"icon",className:N("tw-h-7 tw-w-7",e),onClick:s=>{t==null||t(s),o()},...n,children:[a.jsx(Q.PanelLeft,{}),a.jsx("span",{className:"tw-sr-only",children:"Toggle Sidebar"})]})});qc.displayName="SidebarTrigger";const Hc=g.forwardRef(({className:e,...t},n)=>{const{toggleSidebar:r}=cr();return a.jsx("button",{type:"button",ref:n,"data-sidebar":"rail","aria-label":"Toggle Sidebar",tabIndex:-1,onClick:r,title:"Toggle Sidebar",className:N("tw-absolute tw-inset-y-0 tw-z-20 tw-hidden tw-w-4 tw--translate-x-1/2 tw-transition-all tw-ease-linear after:tw-absolute after:tw-inset-y-0 after:tw-left-1/2 after:tw-w-[2px] hover:after:tw-bg-sidebar-border group-data-[side=left]:tw--right-4 group-data-[side=right]:tw-left-0 sm:tw-flex","[[data-side=left]_&]:tw-cursor-w-resize [[data-side=right]_&]:tw-cursor-e-resize","[[data-side=left][data-state=collapsed]_&]:tw-cursor-e-resize [[data-side=right][data-state=collapsed]_&]:tw-cursor-w-resize","group-data-[collapsible=offcanvas]:tw-translate-x-0 group-data-[collapsible=offcanvas]:after:tw-left-full group-data-[collapsible=offcanvas]:hover:tw-bg-sidebar","[[data-side=left][data-collapsible=offcanvas]_&]:tw--right-2","[[data-side=right][data-collapsible=offcanvas]_&]:tw--left-2",e),...t})});Hc.displayName="SidebarRail";const Ls=g.forwardRef(({className:e,...t},n)=>a.jsx("main",{ref:n,className:N("tw-relative tw-flex tw-flex-1 tw-flex-col tw-bg-background","peer-data-[variant=inset]:tw-min-h-[calc(100svh-theme(spacing.4))] md:peer-data-[variant=inset]:tw-m-2 md:peer-data-[state=collapsed]:peer-data-[variant=inset]:tw-ml-2 md:peer-data-[variant=inset]:tw-ml-0 md:peer-data-[variant=inset]:tw-rounded-xl md:peer-data-[variant=inset]:tw-shadow",e),...t}));Ls.displayName="SidebarInset";const Xc=g.forwardRef(({className:e,...t},n)=>a.jsx(St,{ref:n,"data-sidebar":"input",className:N("tw-h-8 tw-w-full tw-bg-background tw-shadow-none focus-visible:tw-ring-2 focus-visible:tw-ring-sidebar-ring",e),...t}));Xc.displayName="SidebarInput";const Yc=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,"data-sidebar":"header",className:N("tw-flex tw-flex-col tw-gap-2 tw-p-2",e),...t}));Yc.displayName="SidebarHeader";const Wc=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,"data-sidebar":"footer",className:N("tw-flex tw-flex-col tw-gap-2 tw-p-2",e),...t}));Wc.displayName="SidebarFooter";const Kc=g.forwardRef(({className:e,...t},n)=>a.jsx(lr,{ref:n,"data-sidebar":"separator",className:N("tw-mx-2 tw-w-auto tw-bg-sidebar-border",e),...t}));Kc.displayName="SidebarSeparator";const Fs=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,"data-sidebar":"content",className:N("tw-flex tw-min-h-0 tw-flex-1 tw-flex-col tw-gap-2 tw-overflow-auto group-data-[collapsible=icon]:tw-overflow-hidden",e),...t}));Fs.displayName="SidebarContent";const Xr=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,"data-sidebar":"group",className:N("tw-relative tw-flex tw-w-full tw-min-w-0 tw-flex-col tw-p-2",e),...t}));Xr.displayName="SidebarGroup";const Yr=g.forwardRef(({className:e,asChild:t=!1,...n},r)=>{const o=t?Ht.Slot:"div";return a.jsx(o,{ref:r,"data-sidebar":"group-label",className:N("tw-flex tw-h-8 tw-shrink-0 tw-items-center tw-rounded-md tw-px-2 tw-text-xs tw-font-medium tw-text-sidebar-foreground/70 tw-outline-none tw-ring-sidebar-ring tw-transition-[margin,opa] tw-duration-200 tw-ease-linear focus-visible:tw-ring-2 [&>svg]:tw-size-4 [&>svg]:tw-shrink-0","group-data-[collapsible=icon]:tw--mt-8 group-data-[collapsible=icon]:tw-opacity-0",e),...n})});Yr.displayName="SidebarGroupLabel";const Jc=g.forwardRef(({className:e,asChild:t=!1,...n},r)=>{const o=t?Ht.Slot:"button";return a.jsx(o,{ref:r,"data-sidebar":"group-action",className:N("tw-absolute tw-right-3 tw-top-3.5 tw-flex tw-aspect-square tw-w-5 tw-items-center tw-justify-center tw-rounded-md tw-p-0 tw-text-sidebar-foreground tw-outline-none tw-ring-sidebar-ring tw-transition-transform hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground focus-visible:tw-ring-2 [&>svg]:tw-size-4 [&>svg]:tw-shrink-0","after:tw-absolute after:tw--inset-2 after:md:tw-hidden","group-data-[collapsible=icon]:tw-hidden",e),...n})});Jc.displayName="SidebarGroupAction";const Wr=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,"data-sidebar":"group-content",className:N("tw-w-full tw-text-sm",e),...t}));Wr.displayName="SidebarGroupContent";const Gs=g.forwardRef(({className:e,...t},n)=>a.jsx("ul",{ref:n,"data-sidebar":"menu",className:N("tw-flex tw-w-full tw-min-w-0 tw-flex-col tw-gap-1",e),...t}));Gs.displayName="SidebarMenu";const Us=g.forwardRef(({className:e,...t},n)=>a.jsx("li",{ref:n,"data-sidebar":"menu-item",className:N("tw-group/menu-item tw-relative",e),...t}));Us.displayName="SidebarMenuItem";const Zc=Xt.cva("tw-peer/menu-button tw-flex tw-w-full tw-items-center tw-gap-2 tw-overflow-hidden tw-rounded-md tw-p-2 tw-text-left tw-text-sm tw-outline-none tw-ring-sidebar-ring tw-transition-[width,height,padding] hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground focus-visible:tw-ring-2 active:tw-bg-sidebar-accent active:tw-text-sidebar-accent-foreground disabled:tw-pointer-events-none disabled:tw-opacity-50 tw-group-has-[[data-sidebar=menu-action]]/menu-item:pr-8 aria-disabled:tw-pointer-events-none aria-disabled:tw-opacity-50 data-[active=true]:tw-font-medium data-[active=true]:tw-text-sidebar-accent-foreground data-[state=open]:hover:tw-bg-sidebar-accent data-[state=open]:hover:tw-text-sidebar-accent-foreground group-data-[collapsible=icon]:tw-!size-8 group-data-[collapsible=icon]:tw-!p-2 [&>span:last-child]:tw-truncate [&>svg]:tw-size-4 [&>svg]:tw-shrink-0",{variants:{variant:{default:"hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground",outline:"tw-bg-background tw-shadow-[0_0_0_1px_hsl(var(--sidebar-border))] hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground hover:tw-shadow-[0_0_0_1px_hsl(var(--sidebar-accent))]"},size:{default:"tw-h-8 tw-text-sm",sm:"tw-h-7 tw-text-xs",lg:"tw-h-12 tw-text-sm group-data-[collapsible=icon]:tw-!p-0"}},defaultVariants:{variant:"default",size:"default"}}),qs=g.forwardRef(({asChild:e=!1,isActive:t=!1,variant:n="default",size:r="default",tooltip:o,className:s,...i},l)=>{const c=e?Ht.Slot:"button",{isMobile:d,state:u}=cr(),f=a.jsx(c,{ref:l,"data-sidebar":"menu-button","data-size":r,"data-active":t,className:N(Zc({variant:n,size:r}),s),...i});return o?(typeof o=="string"&&(o={children:o}),a.jsxs(Dc,{children:[a.jsx(Ac,{asChild:!0,children:f}),a.jsx(As,{side:"right",align:"center",hidden:u!=="collapsed"||d,...o})]})):f});qs.displayName="SidebarMenuButton";const Qc=g.forwardRef(({className:e,asChild:t=!1,showOnHover:n=!1,...r},o)=>{const s=t?Ht.Slot:"button";return a.jsx(s,{ref:o,"data-sidebar":"menu-action",className:N("tw-peer-hover/menu-button:text-sidebar-accent-foreground tw-absolute tw-right-1 tw-top-1.5 tw-flex tw-aspect-square tw-w-5 tw-items-center tw-justify-center tw-rounded-md tw-p-0 tw-text-sidebar-foreground tw-outline-none tw-ring-sidebar-ring tw-transition-transform hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground focus-visible:tw-ring-2 [&>svg]:tw-size-4 [&>svg]:tw-shrink-0","after:tw-absolute after:tw--inset-2 after:md:tw-hidden","tw-peer-data-[size=sm]/menu-button:top-1","tw-peer-data-[size=default]/menu-button:top-1.5","tw-peer-data-[size=lg]/menu-button:top-2.5","group-data-[collapsible=icon]:tw-hidden",n&&"tw-group-focus-within/menu-item:opacity-100 tw-group-hover/menu-item:opacity-100 tw-peer-data-[active=true]/menu-button:text-sidebar-accent-foreground data-[state=open]:tw-opacity-100 md:tw-opacity-0",e),...r})});Qc.displayName="SidebarMenuAction";const ed=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,"data-sidebar":"menu-badge",className:N("tw-pointer-events-none tw-absolute tw-right-1 tw-flex tw-h-5 tw-min-w-5 tw-select-none tw-items-center tw-justify-center tw-rounded-md tw-px-1 tw-text-xs tw-font-medium tw-tabular-nums tw-text-sidebar-foreground","tw-peer-hover/menu-button:text-sidebar-accent-foreground tw-peer-data-[active=true]/menu-button:text-sidebar-accent-foreground","tw-peer-data-[size=sm]/menu-button:top-1","tw-peer-data-[size=default]/menu-button:top-1.5","tw-peer-data-[size=lg]/menu-button:top-2.5","group-data-[collapsible=icon]:tw-hidden",e),...t}));ed.displayName="SidebarMenuBadge";const td=g.forwardRef(({className:e,showIcon:t=!1,...n},r)=>{const o=g.useMemo(()=>`${Math.floor(Math.random()*40)+50}%`,[]);return a.jsxs("div",{ref:r,"data-sidebar":"menu-skeleton",className:N("tw-flex tw-h-8 tw-items-center tw-gap-2 tw-rounded-md tw-px-2",e),...n,children:[t&&a.jsx(sa,{className:"tw-size-4 tw-rounded-md","data-sidebar":"menu-skeleton-icon"}),a.jsx(sa,{className:"tw-h-4 tw-max-w-[--skeleton-width] tw-flex-1","data-sidebar":"menu-skeleton-text",style:{"--skeleton-width":o}})]})});td.displayName="SidebarMenuSkeleton";const nd=g.forwardRef(({className:e,...t},n)=>a.jsx("ul",{ref:n,"data-sidebar":"menu-sub",className:N("tw-mx-3.5 tw-flex tw-min-w-0 tw-translate-x-px tw-flex-col tw-gap-1 tw-border-l tw-border-sidebar-border tw-px-2.5 tw-py-0.5","group-data-[collapsible=icon]:tw-hidden",e),...t}));nd.displayName="SidebarMenuSub";const rd=g.forwardRef(({...e},t)=>a.jsx("li",{ref:t,...e}));rd.displayName="SidebarMenuSubItem";const od=g.forwardRef(({asChild:e=!1,size:t="md",isActive:n,className:r,...o},s)=>{const i=e?Ht.Slot:"a";return a.jsx(i,{ref:s,"data-sidebar":"menu-sub-button","data-size":t,"data-active":n,className:N("tw-flex tw-h-7 tw-min-w-0 tw--translate-x-px tw-items-center tw-gap-2 tw-overflow-hidden tw-rounded-md tw-px-2 tw-text-sidebar-foreground tw-outline-none tw-ring-sidebar-ring hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground focus-visible:tw-ring-2 active:tw-bg-sidebar-accent active:tw-text-sidebar-accent-foreground disabled:tw-pointer-events-none disabled:tw-opacity-50 aria-disabled:tw-pointer-events-none aria-disabled:tw-opacity-50 [&>span:last-child]:tw-truncate [&>svg]:tw-size-4 [&>svg]:tw-shrink-0 [&>svg]:tw-text-sidebar-accent-foreground","data-[active=true]:tw-bg-sidebar-accent data-[active=true]:tw-text-sidebar-accent-foreground",t==="sm"&&"tw-text-xs",t==="md"&&"tw-text-sm","group-data-[collapsible=icon]:tw-hidden",r),...o})});od.displayName="SidebarMenuSubButton";function Hs({id:e,extensionLabels:t,projectOptions:n,handleSelectSidebarItem:r,selectedSidebarItem:o,extensionsSidebarGroupLabel:s,projectsSidebarGroupLabel:i,buttonPlaceholder:l}){const c=g.useCallback((f,w)=>{r(f,w)},[r]),d=g.useCallback(f=>{const w=n.find(b=>b.projectId===f);return w?w.projectName:f},[n]),u=g.useCallback(f=>!o.projectId&&f===o.label,[o]);return a.jsx(zs,{id:e,collapsible:"none",variant:"inset",className:"tw-w-96 tw-gap-2 tw-overflow-y-auto tw-rounded tw-bg-slate-100",children:a.jsxs(Fs,{children:[a.jsxs(Xr,{children:[a.jsx(Yr,{className:"tw-text-sm tw-text-gray-400",children:s}),a.jsx(Wr,{children:a.jsx(Gs,{children:t.map(f=>a.jsx(Us,{children:a.jsx(qs,{className:N("tw-rounded tw-py-2 tw-text-sm tw-text-gray-500 hover:tw-bg-white hover:tw-text-gray-900 hover:tw-shadow-sm active:tw-bg-white",{"tw-bg-white tw-text-gray-900 tw-shadow-sm":u(f)}),onClick:()=>c(f,void 0),isActive:u(f),children:a.jsx("span",{className:"tw-pl-3",children:f})})},f))})})]}),a.jsxs(Xr,{children:[a.jsx(Yr,{className:"tw-text-sm tw-text-gray-400",children:i}),a.jsx(Wr,{className:"tw-pl-3",children:a.jsx(Wn,{popoverContentClassName:"tw-z-[1000]",options:n.flatMap(f=>f.projectId),getOptionLabel:f=>d(f),buttonPlaceholder:l,onChange:f=>{const w=d(f);c(w,f)},value:(o==null?void 0:o.projectId)??void 0})})]})]})})}function ad({id:e,direction:t="ltr",extensionLabels:n,projectOptions:r,children:o,handleSelectSidebarItem:s,selectedSidebarItem:i,onSearch:l,extensionsSidebarGroupLabel:c,projectsSidebarGroupLabel:d,buttonPlaceholder:u}){return a.jsxs("div",{className:"tw-box-border tw-flex tw-h-full tw-flex-col tw-p-3",children:[a.jsx("div",{className:"tw-box-border tw-flex tw-items-center tw-justify-center tw-py-4",children:a.jsx(ho,{className:"tw-w-9/12",onSearch:l,placeholder:"Search app settings, extension settings, and project settings"})}),a.jsxs(Vs,{dir:t,id:e,className:"tw-h-full tw-flex-1 tw-gap-4 tw-overflow-auto",children:[a.jsx(Hs,{extensionLabels:n,projectOptions:r,handleSelectSidebarItem:s,selectedSidebarItem:i,extensionsSidebarGroupLabel:c,projectsSidebarGroupLabel:d,buttonPlaceholder:u}),a.jsx(Ls,{className:"tw-overflow-y-auto",children:o})]})]})}const rt="scrBook",sd="scrRef",pt="source",id="details",ld="Scripture Reference",cd="Scripture Book",Xs="Type",dd="Details";function ud(e,t){const n=t??!1;return[{accessorFn:r=>`${ae.bookNumberToId(r.start.bookNum)} ${r.start.chapterNum}:${r.start.verseNum}`,id:rt,header:(e==null?void 0:e.scriptureReferenceColumnName)??ld,cell:r=>{const o=r.row.original;return r.row.getIsGrouped()?ae.bookNumberToEnglishName(o.start.bookNum):r.row.groupingColumnId===rt?W.formatScrRef(o.start):void 0},getGroupingValue:r=>r.start.bookNum,sortingFn:(r,o)=>W.compareScrRefs(r.original.start,o.original.start),enableGrouping:!0},{accessorFn:r=>W.formatScrRef(r.start),id:sd,header:void 0,cell:r=>{const o=r.row.original;return r.row.getIsGrouped()?void 0:W.formatScrRef(o.start)},sortingFn:(r,o)=>W.compareScrRefs(r.original.start,o.original.start),enableGrouping:!1},{accessorFn:r=>r.source.displayName,id:pt,header:n?(e==null?void 0:e.typeColumnName)??Xs:void 0,cell:r=>n||r.row.getIsGrouped()?r.getValue():void 0,getGroupingValue:r=>r.source.id,sortingFn:(r,o)=>r.original.source.displayName.localeCompare(o.original.source.displayName),enableGrouping:!0},{accessorFn:r=>r.detail,id,header:(e==null?void 0:e.detailsColumnName)??dd,cell:r=>r.getValue(),enableGrouping:!1}]}const pd=e=>{if(!("offset"in e.start))throw new Error("No offset available in range start");if(e.end&&!("offset"in e.end))throw new Error("No offset available in range end");const{offset:t}=e.start;let n=0;return e.end&&({offset:n}=e.end),!e.end||W.compareScrRefs(e.start,e.end)===0?`${W.scrRefToBBBCCCVVV(e.start)}+${t}`:`${W.scrRefToBBBCCCVVV(e.start)}+${t}-${W.scrRefToBBBCCCVVV(e.end)}+${n}`},ia=e=>`${pd({start:e.start,end:e.end})} ${e.source.displayName} ${e.detail}`;function wd({sources:e,showColumnHeaders:t=!1,showSourceColumn:n=!1,scriptureReferenceColumnName:r,scriptureBookGroupName:o,typeColumnName:s,detailsColumnName:i,onRowSelected:l,direction:c="ltr"}){const[d,u]=g.useState([]),[f,w]=g.useState([{id:rt,desc:!1}]),[b,x]=g.useState({}),m=g.useMemo(()=>e.flatMap(C=>C.data.map(_=>({..._,source:C.source}))),[e]),h=g.useMemo(()=>ud({scriptureReferenceColumnName:r,typeColumnName:s,detailsColumnName:i},n),[r,s,i,n]);g.useEffect(()=>{d.includes(pt)?w([{id:pt,desc:!1},{id:rt,desc:!1}]):w([{id:rt,desc:!1}])},[d]);const S=Se.useReactTable({data:m,columns:h,state:{grouping:d,sorting:f,rowSelection:b},onGroupingChange:u,onSortingChange:w,onRowSelectionChange:x,getExpandedRowModel:Se.getExpandedRowModel(),getGroupedRowModel:Se.getGroupedRowModel(),getCoreRowModel:Se.getCoreRowModel(),getSortedRowModel:Se.getSortedRowModel(),getRowId:ia,autoResetExpanded:!1,enableMultiRowSelection:!1,enableSubRowSelection:!1});g.useEffect(()=>{if(l){const C=S.getSelectedRowModel().rowsById,_=Object.keys(C);if(_.length===1){const k=m.find(D=>ia(D)===_[0])||void 0;k&&l(k)}}},[b,m,l,S]);const R=o??cd,j=s??Xs,E=[{label:"No Grouping",value:[]},{label:`Group by ${R}`,value:[rt]},{label:`Group by ${j}`,value:[pt]},{label:`Group by ${R} and ${j}`,value:[rt,pt]},{label:`Group by ${j} and ${R}`,value:[pt,rt]}],v=C=>{u(JSON.parse(C))},P=(C,_)=>{!C.getIsGrouped()&&!C.getIsSelected()&&C.getToggleSelectedHandler()(_)},V=(C,_)=>C.getIsGrouped()?"":N("banded-row",_%2===0?"even":"odd"),U=(C,_,k)=>{if(!((C==null?void 0:C.length)===0||_.depth{v(C)},children:[a.jsx(bt,{className:"tw-mb-1 tw-mt-2",children:a.jsx(Bt,{})}),a.jsx(vt,{position:"item-aligned",children:a.jsx(ks,{children:E.map(C=>a.jsx(Ae,{value:JSON.stringify(C.value),children:C.label},C.label))})})]}),a.jsxs(Cn,{className:"tw-relative tw-flex tw-flex-col tw-overflow-y-auto tw-p-0",children:[t&&a.jsx(Tn,{children:S.getHeaderGroups().map(C=>a.jsx(Ze,{children:C.headers.filter(_=>_.column.columnDef.header).map(_=>a.jsx(Vt,{colSpan:_.colSpan,className:"top-0 tw-sticky",children:_.isPlaceholder?void 0:a.jsxs("div",{children:[_.column.getCanGroup()?a.jsx(fe,{variant:"ghost",title:`Toggle grouping by ${_.column.columnDef.header}`,onClick:_.column.getToggleGroupingHandler(),type:"button",children:_.column.getIsGrouped()?"🛑":"👊 "}):void 0," ",Se.flexRender(_.column.columnDef.header,_.getContext())]})},_.id))},C.id))}),a.jsx(Rn,{children:S.getRowModel().rows.map((C,_)=>a.jsx(Ze,{"data-state":C.getIsSelected()?"selected":"",className:N(V(C,_)),onClick:k=>P(C,k),children:C.getVisibleCells().map(k=>{if(!(k.getIsPlaceholder()||k.column.columnDef.enableGrouping&&!k.getIsGrouped()&&(k.column.columnDef.id!==pt||!n)))return a.jsx(xt,{className:N(k.column.columnDef.id,"tw-p-[1px]",U(d,C,k)),children:(()=>k.getIsGrouped()?a.jsxs(fe,{variant:"link",onClick:C.getToggleExpandedHandler(),type:"button",children:[C.getIsExpanded()&&a.jsx(Q.ChevronDown,{}),!C.getIsExpanded()&&(c==="ltr"?a.jsx(Q.ChevronRight,{}):a.jsx(Q.ChevronLeft,{}))," ",Se.flexRender(k.column.columnDef.cell,k.getContext())," (",C.subRows.length,")"]}):Se.flexRender(k.column.columnDef.cell,k.getContext()))()},k.id)})},C.id))})]})]})}const _r={[W.getLocalizeKeyForScrollGroupId("undefined")]:"Ø",[W.getLocalizeKeyForScrollGroupId(0)]:"A",[W.getLocalizeKeyForScrollGroupId(1)]:"B",[W.getLocalizeKeyForScrollGroupId(2)]:"C",[W.getLocalizeKeyForScrollGroupId(3)]:"D",[W.getLocalizeKeyForScrollGroupId(4)]:"E",[W.getLocalizeKeyForScrollGroupId(5)]:"F",[W.getLocalizeKeyForScrollGroupId(6)]:"G",[W.getLocalizeKeyForScrollGroupId(7)]:"H",[W.getLocalizeKeyForScrollGroupId(8)]:"I",[W.getLocalizeKeyForScrollGroupId(9)]:"J",[W.getLocalizeKeyForScrollGroupId(10)]:"K",[W.getLocalizeKeyForScrollGroupId(11)]:"L",[W.getLocalizeKeyForScrollGroupId(12)]:"M",[W.getLocalizeKeyForScrollGroupId(13)]:"N",[W.getLocalizeKeyForScrollGroupId(14)]:"O",[W.getLocalizeKeyForScrollGroupId(15)]:"P",[W.getLocalizeKeyForScrollGroupId(16)]:"Q",[W.getLocalizeKeyForScrollGroupId(17)]:"R",[W.getLocalizeKeyForScrollGroupId(18)]:"S",[W.getLocalizeKeyForScrollGroupId(19)]:"T",[W.getLocalizeKeyForScrollGroupId(20)]:"U",[W.getLocalizeKeyForScrollGroupId(21)]:"V",[W.getLocalizeKeyForScrollGroupId(22)]:"W",[W.getLocalizeKeyForScrollGroupId(23)]:"X",[W.getLocalizeKeyForScrollGroupId(24)]:"Y",[W.getLocalizeKeyForScrollGroupId(25)]:"Z"};function fd({availableScrollGroupIds:e,scrollGroupId:t,onChangeScrollGroupId:n,localizedStrings:r={}}){const o={..._r,...Object.fromEntries(Object.entries(r).map(([s,i])=>[s,s===i&&s in _r?_r[s]:i]))};return a.jsxs(At,{value:`${t}`,onValueChange:s=>n(s==="undefined"?void 0:parseInt(s,10)),children:[a.jsx(bt,{className:"pr-twp tw-w-auto",children:a.jsx(Bt,{placeholder:o[W.getLocalizeKeyForScrollGroupId(t)]??t})}),a.jsx(vt,{style:{zIndex:250},children:e.map(s=>a.jsx(Ae,{value:`${s}`,children:o[W.getLocalizeKeyForScrollGroupId(s)]},`${s}`))})]})}function md({children:e}){return a.jsx("div",{className:"pr-twp tw-grid",children:e})}function hd({primary:e,secondary:t,children:n,isLoading:r=!1,loadingMessage:o}){return a.jsxs("div",{className:"tw-flex tw-items-center tw-justify-between tw-space-x-4 tw-py-2",children:[a.jsxs("div",{children:[a.jsx("p",{className:"tw-text-sm tw-font-medium tw-leading-none",children:e}),a.jsx("p",{className:"tw-whitespace-normal tw-break-words tw-text-sm tw-text-muted-foreground",children:t})]}),r?a.jsx("p",{className:"tw-text-sm tw-text-muted-foreground",children:o}):a.jsx("div",{children:n})]})}function gd({primary:e,secondary:t,includeSeparator:n=!1}){return a.jsxs("div",{className:"tw-space-y-4 tw-py-2",children:[a.jsxs("div",{children:[a.jsx("h3",{className:"tw-text-lg tw-font-medium",children:e}),a.jsx("p",{className:"tw-text-sm tw-text-muted-foreground",children:t})]}),n?a.jsx(lr,{}):""]})}function bd({id:e,className:t,listItems:n,selectedListItems:r,handleSelectListItem:o,createLabel:s}){return a.jsx("div",{id:e,className:t,children:n.map(i=>a.jsxs("div",{className:"tw-m-2 tw-flex tw-items-center",children:[a.jsx(sr,{className:"tw-mr-2 tw-align-middle",checked:r.includes(i),onCheckedChange:l=>o(i,l)}),a.jsx(qe,{children:s?s(i):i})]},i))})}function vd(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}function xd(e){if(e.__esModule)return e;var t=e.default;if(typeof t=="function"){var n=function r(){return this instanceof r?Reflect.construct(t,arguments,this.constructor):t.apply(this,arguments)};n.prototype=t.prototype}else n={};return Object.defineProperty(n,"__esModule",{value:!0}),Object.keys(e).forEach(function(r){var o=Object.getOwnPropertyDescriptor(e,r);Object.defineProperty(n,r,o.get?o:{enumerable:!0,get:function(){return e[r]}})}),n}var xo={},Ys={exports:{}};(function(e){function t(n){return n&&n.__esModule?n:{default:n}}e.exports=t,e.exports.__esModule=!0,e.exports.default=e.exports})(Ys);var yd=Ys.exports,Pr={};function yo(e,t){return process.env.NODE_ENV==="production"?()=>null:function(...r){return e(...r)||t(...r)}}function O(){return O=Object.assign?Object.assign.bind():function(e){for(var t=1;t{t[n]=Ws(e[n])}),t}function Qe(e,t,n={clone:!0}){const r=n.clone?O({},e):e;return mt(e)&&mt(t)&&Object.keys(t).forEach(o=>{o!=="__proto__"&&(mt(t[o])&&o in e&&mt(e[o])?r[o]=Qe(e[o],t[o],n):n.clone?r[o]=mt(t[o])?Ws(t[o]):t[o]:r[o]=t[o])}),r}var Kr={exports:{}},zn={exports:{}},ie={};/** @license React v16.13.1 +"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const a=require("react/jsx-runtime"),g=require("react"),Q=require("lucide-react"),ot=require("clsx"),ml=require("tailwind-merge"),Za=require("@radix-ui/react-dropdown-menu"),W=require("platform-bible-utils"),Ht=require("@radix-ui/react-slot"),Xt=require("class-variance-authority"),hl=require("@radix-ui/react-label"),gl=require("@radix-ui/react-radio-group"),bl=require("@radix-ui/react-popover"),Re=require("cmdk"),vl=require("@radix-ui/react-dialog"),Se=require("@tanstack/react-table"),xl=require("@radix-ui/react-select"),yl=require("@radix-ui/react-checkbox"),Nl=require("@radix-ui/react-toggle-group"),kl=require("@radix-ui/react-toggle"),Sl=require("@radix-ui/react-tabs"),El=require("@radix-ui/react-separator"),jl=require("@radix-ui/react-tooltip"),Gr=require("@mui/styled-engine"),Me=require("@mui/material"),ln=require("react-dom"),Qa=require("sonner"),Cl=require("@radix-ui/react-slider"),Tl=require("@radix-ui/react-switch"),Rl=require("markdown-to-jsx");function ke(e){const t=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(e){for(const n in e)if(n!=="default"){const r=Object.getOwnPropertyDescriptor(e,n);Object.defineProperty(t,n,r.get?r:{enumerable:!0,get:()=>e[n]})}}return t.default=e,Object.freeze(t)}const M=ke(g),pe=ke(Za),es=ke(hl),bn=ke(gl),vn=ke(bl),be=ke(vl),ge=ke(xl),Ur=ke(yl),rr=ke(Nl),ts=ke(kl),Oe=ke(Sl),ns=ke(El),Sn=ke(jl),Ol=ke(ln),cn=ke(Cl),qr=ke(Tl);const _l=ml.extendTailwindMerge({prefix:"tw-"});function N(...e){return _l(ot.clsx(e))}const St=g.forwardRef(({className:e,type:t,...n},r)=>a.jsx("input",{type:t,className:N("pr-twp tw-flex tw-h-10 tw-rounded-md tw-border tw-border-input tw-bg-background tw-px-3 tw-py-2 tw-text-sm tw-ring-offset-background file:tw-border-0 file:tw-bg-transparent file:tw-text-sm file:tw-font-medium file:tw-text-foreground placeholder:tw-text-muted-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-cursor-not-allowed disabled:tw-opacity-50",e),ref:r,...n}));St.displayName="Input";const Pl=g.forwardRef(({handleSearch:e,handleKeyDown:t,handleOnClick:n,handleSubmit:r,...o},s)=>a.jsxs("div",{className:"tw-relative",children:[a.jsx(St,{...o,type:"text",className:"tw-box-border tw-gap-2.5 tw-rounded-lg tw-border tw-border-solid tw-bg-background tw-py-2 tw-pl-4 tw-pr-3 tw-font-medium tw-shadow-none tw-outline-none",onChange:i=>e(i.target.value),onKeyDown:i=>{i.key==="Enter"&&r(),t(i)},onClick:n,ref:s}),a.jsx(Q.History,{className:"tw-absolute tw-right-3 tw-top-1/2 tw-h-4 tw-w-4 tw--translate-y-1/2 tw-transform tw-cursor-pointer tw-text-muted-foreground",onClick:()=>{console.log("back in history")}})]}));var Il=Object.defineProperty,Ml=(e,t,n)=>t in e?Il(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,ne=(e,t,n)=>Ml(e,typeof t!="symbol"?t+"":t,n);const gt=["GEN","EXO","LEV","NUM","DEU","JOS","JDG","RUT","1SA","2SA","1KI","2KI","1CH","2CH","EZR","NEH","EST","JOB","PSA","PRO","ECC","SNG","ISA","JER","LAM","EZK","DAN","HOS","JOL","AMO","OBA","JON","MIC","NAM","HAB","ZEP","HAG","ZEC","MAL","MAT","MRK","LUK","JHN","ACT","ROM","1CO","2CO","GAL","EPH","PHP","COL","1TH","2TH","1TI","2TI","TIT","PHM","HEB","JAS","1PE","2PE","1JN","2JN","3JN","JUD","REV","TOB","JDT","ESG","WIS","SIR","BAR","LJE","S3Y","SUS","BEL","1MA","2MA","3MA","4MA","1ES","2ES","MAN","PS2","ODA","PSS","JSA","JDB","TBS","SST","DNT","BLT","XXA","XXB","XXC","XXD","XXE","XXF","XXG","FRT","BAK","OTH","3ES","EZA","5EZ","6EZ","INT","CNC","GLO","TDX","NDX","DAG","PS3","2BA","LBA","JUB","ENO","1MQ","2MQ","3MQ","REP","4BA","LAO"],ao=["XXA","XXB","XXC","XXD","XXE","XXF","XXG","FRT","BAK","OTH","INT","CNC","GLO","TDX","NDX"],rs=["Genesis","Exodus","Leviticus","Numbers","Deuteronomy","Joshua","Judges","Ruth","1 Samuel","2 Samuel","1 Kings","2 Kings","1 Chronicles","2 Chronicles","Ezra","Nehemiah","Esther (Hebrew)","Job","Psalms","Proverbs","Ecclesiastes","Song of Songs","Isaiah","Jeremiah","Lamentations","Ezekiel","Daniel (Hebrew)","Hosea","Joel","Amos","Obadiah","Jonah","Micah","Nahum","Habakkuk","Zephaniah","Haggai","Zechariah","Malachi","Matthew","Mark","Luke","John","Acts","Romans","1 Corinthians","2 Corinthians","Galatians","Ephesians","Philippians","Colossians","1 Thessalonians","2 Thessalonians","1 Timothy","2 Timothy","Titus","Philemon","Hebrews","James","1 Peter","2 Peter","1 John","2 John","3 John","Jude","Revelation","Tobit","Judith","Esther Greek","Wisdom of Solomon","Sirach (Ecclesiasticus)","Baruch","Letter of Jeremiah","Song of 3 Young Men","Susanna","Bel and the Dragon","1 Maccabees","2 Maccabees","3 Maccabees","4 Maccabees","1 Esdras (Greek)","2 Esdras (Latin)","Prayer of Manasseh","Psalm 151","Odes","Psalms of Solomon","Joshua A. *obsolete*","Judges B. *obsolete*","Tobit S. *obsolete*","Susanna Th. *obsolete*","Daniel Th. *obsolete*","Bel Th. *obsolete*","Extra A","Extra B","Extra C","Extra D","Extra E","Extra F","Extra G","Front Matter","Back Matter","Other Matter","3 Ezra *obsolete*","Apocalypse of Ezra","5 Ezra (Latin Prologue)","6 Ezra (Latin Epilogue)","Introduction","Concordance ","Glossary ","Topical Index","Names Index","Daniel Greek","Psalms 152-155","2 Baruch (Apocalypse)","Letter of Baruch","Jubilees","Enoch","1 Meqabyan","2 Meqabyan","3 Meqabyan","Reproof (Proverbs 25-31)","4 Baruch (Rest of Baruch)","Laodiceans"],ra=Ul();function Yt(e,t=!0){return t&&(e=e.toUpperCase()),e in ra?ra[e]:0}function so(e){return Yt(e)>0}function $l(e){const t=typeof e=="string"?Yt(e):e;return t>=40&&t<=66}function Dl(e){return(typeof e=="string"?Yt(e):e)<=39}function os(e){return e<=66}function Al(e){const t=typeof e=="string"?Yt(e):e;return is(t)&&!os(t)}function*Bl(){for(let e=1;e<=gt.length;e++)yield e}const Vl=1,as=gt.length;function zl(){return["XXA","XXB","XXC","XXD","XXE","XXF","XXG"]}function io(e,t="***"){const n=e-1;return n<0||n>=gt.length?t:gt[n]}function ss(e){return e<=0||e>as?"******":rs[e-1]}function Ll(e){return ss(Yt(e))}function is(e){const t=typeof e=="number"?io(e):e;return so(t)&&!ao.includes(t)}function Fl(e){const t=typeof e=="number"?io(e):e;return so(t)&&ao.includes(t)}function Gl(e){return rs[e-1].includes("*obsolete*")}function Ul(){const e={};for(let t=0;t(e[e.Unknown=0]="Unknown",e[e.Original=1]="Original",e[e.Septuagint=2]="Septuagint",e[e.Vulgate=3]="Vulgate",e[e.English=4]="English",e[e.RussianProtestant=5]="RussianProtestant",e[e.RussianOrthodox=6]="RussianOrthodox",e))(He||{});const Pe=class{constructor(t){if(ne(this,"name"),ne(this,"fullPath"),ne(this,"isPresent"),ne(this,"hasVerseSegments"),ne(this,"isCustomized"),ne(this,"baseVersification"),ne(this,"scriptureBooks"),ne(this,"_type"),t==null)throw new Error("Argument undefined");typeof t=="string"?(this.name=t,this._type=He[t]):(this._type=t,this.name=He[t])}get type(){return this._type}equals(t){return!t.type||!this.type?!1:t.type===this.type}};ne(Pe,"Original",new Pe(He.Original)),ne(Pe,"Septuagint",new Pe(He.Septuagint)),ne(Pe,"Vulgate",new Pe(He.Vulgate)),ne(Pe,"English",new Pe(He.English)),ne(Pe,"RussianProtestant",new Pe(He.RussianProtestant)),ne(Pe,"RussianOrthodox",new Pe(He.RussianOrthodox));let ut=Pe;function oa(e,t){const n=t[0];for(let r=1;r(e[e.Valid=0]="Valid",e[e.UnknownVersification=1]="UnknownVersification",e[e.OutOfRange=2]="OutOfRange",e[e.VerseOutOfOrder=3]="VerseOutOfOrder",e[e.VerseRepeated=4]="VerseRepeated",e))(ls||{});const je=class re{constructor(t,n,r,o){if(ne(this,"firstChapter"),ne(this,"lastChapter"),ne(this,"lastVerse"),ne(this,"hasSegmentsDefined"),ne(this,"text"),ne(this,"BBBCCCVVVS"),ne(this,"longHashCode"),ne(this,"versification"),ne(this,"rtlMark","‏"),ne(this,"_bookNum",0),ne(this,"_chapterNum",0),ne(this,"_verseNum",0),ne(this,"_verse"),r==null&&o==null)if(t!=null&&typeof t=="string"){const s=t,i=n!=null&&n instanceof ut?n:void 0;this.setEmpty(i),this.parse(s)}else if(t!=null&&typeof t=="number"){const s=n!=null&&n instanceof ut?n:void 0;this.setEmpty(s),this._verseNum=t%re.chapterDigitShifter,this._chapterNum=Math.floor(t%re.bookDigitShifter/re.chapterDigitShifter),this._bookNum=Math.floor(t/re.bookDigitShifter)}else if(n==null)if(t!=null&&t instanceof re){const s=t;this._bookNum=s.bookNum,this._chapterNum=s.chapterNum,this._verseNum=s.verseNum,this._verse=s.verse,this.versification=s.versification}else{if(t==null)return;const s=t instanceof ut?t:re.defaultVersification;this.setEmpty(s)}else throw new Error("VerseRef constructor not supported.");else if(t!=null&&n!=null&&r!=null)if(typeof t=="string"&&typeof n=="string"&&typeof r=="string")this.setEmpty(o),this.updateInternal(t,n,r);else if(typeof t=="number"&&typeof n=="number"&&typeof r=="number")this._bookNum=t,this._chapterNum=n,this._verseNum=r,this.versification=o??re.defaultVersification;else throw new Error("VerseRef constructor not supported.");else throw new Error("VerseRef constructor not supported.")}static isVerseParseable(t){return t.length>0&&"0123456789".includes(t[0])&&!t.endsWith(this.verseRangeSeparator)&&!t.endsWith(this.verseSequenceIndicator)}static tryParse(t){let n;try{return n=new re(t),{success:!0,verseRef:n}}catch(r){if(r instanceof nn)return n=new re,{success:!1,verseRef:n};throw r}}static getBBBCCCVVV(t,n,r){return t%re.bcvMaxValue*re.bookDigitShifter+(n>=0?n%re.bcvMaxValue*re.chapterDigitShifter:0)+(r>=0?r%re.bcvMaxValue:0)}static fromJSON(t){const{book:n,chapterNum:r,verseNum:o,verse:s,versificationStr:i}=t,l=s||o.toString();let c;return i&&(c=new ut(i)),n?new re(n,r.toString(),l,c):new re}static tryGetVerseNum(t){let n;if(!t)return n=-1,{success:!0,vNum:n};n=0;let r;for(let o=0;o"9")return o===0&&(n=-1),{success:!1,vNum:n};if(n=n*10+ +r-0,n>re.bcvMaxValue)return n=-1,{success:!1,vNum:n}}return{success:!0,vNum:n}}get isDefault(){return this.bookNum===0&&this.chapterNum===0&&this.verseNum===0&&this.versification==null}get hasMultiple(){return this._verse!=null&&(this._verse.includes(re.verseRangeSeparator)||this._verse.includes(re.verseSequenceIndicator))}get book(){return ae.bookNumberToId(this.bookNum,"")}set book(t){this.bookNum=ae.bookIdToNumber(t)}get chapter(){return this.isDefault||this._chapterNum<0?"":this._chapterNum.toString()}set chapter(t){const n=+t;this._chapterNum=Number.isInteger(n)?n:-1}get verse(){return this._verse!=null?this._verse:this.isDefault||this._verseNum<0?"":this._verseNum.toString()}set verse(t){const{success:n,vNum:r}=re.tryGetVerseNum(t);this._verse=n?void 0:t.replace(this.rtlMark,""),this._verseNum=r,!(this._verseNum>=0)&&({vNum:this._verseNum}=re.tryGetVerseNum(this._verse))}get bookNum(){return this._bookNum}set bookNum(t){if(t<=0||t>ae.lastBook)throw new nn("BookNum must be greater than zero and less than or equal to last book");this._bookNum=t}get chapterNum(){return this._chapterNum}set chapterNum(t){this.chapterNum=t}get verseNum(){return this._verseNum}set verseNum(t){this._verseNum=t}get versificationStr(){var t;return(t=this.versification)==null?void 0:t.name}set versificationStr(t){this.versification=this.versification!=null?new ut(t):void 0}get valid(){return this.validStatus===0}get validStatus(){return this.validateVerse(re.verseRangeSeparators,re.verseSequenceIndicators)}get BBBCCC(){return re.getBBBCCCVVV(this._bookNum,this._chapterNum,0)}get BBBCCCVVV(){return re.getBBBCCCVVV(this._bookNum,this._chapterNum,this._verseNum)}get isExcluded(){return!1}parse(t){if(t=t.replace(this.rtlMark,""),t.includes("/")){const s=t.split("/");if(t=s[0],s.length>1)try{const i=+s[1].trim();this.versification=new ut(He[i])}catch{throw new nn("Invalid reference : "+t)}}const n=t.trim().split(" ");if(n.length!==2)throw new nn("Invalid reference : "+t);const r=n[1].split(":"),o=+r[0];if(r.length!==2||ae.bookIdToNumber(n[0])===0||!Number.isInteger(o)||o<0||!re.isVerseParseable(r[1]))throw new nn("Invalid reference : "+t);this.updateInternal(n[0],r[0],r[1])}simplify(){this._verse=void 0}clone(){return new re(this)}toString(){const t=this.book;return t===""?"":`${t} ${this.chapter}:${this.verse}`}toJSON(){let t=this.verse;(t===""||t===this.verseNum.toString())&&(t=void 0);const n={book:this.book,chapterNum:this.chapterNum,verseNum:this.verseNum,verse:t,versificationStr:this.versificationStr};return t||delete n.verse,n}equals(t){return t instanceof re?t._bookNum===this._bookNum&&t._chapterNum===this._chapterNum&&t._verseNum===this._verseNum&&t.verse===this.verse&&(t.versification==null&&this.versification==null||t.versification!=null&&this.versification!=null&&t.versification.equals(this.versification)):!1}allVerses(t=!1,n=re.verseRangeSeparators,r=re.verseSequenceIndicators){if(this._verse==null||this.chapterNum<=0)return[this.clone()];const o=[],s=oa(this._verse,r);for(const i of s.map(l=>oa(l,n))){const l=this.clone();l.verse=i[0];const c=l.verseNum;if(o.push(l),i.length>1){const d=this.clone();if(d.verse=i[1],!t)for(let u=c+1;ui)return 3;if(r===i)return 4;r=i}return 0}get internalValid(){return this.versification==null?1:this._bookNum<=0||this._bookNum>ae.lastBook?2:(ae.isCanonical(this._bookNum),0)}setEmpty(t=re.defaultVersification){this._bookNum=0,this._chapterNum=-1,this._verse=void 0,this.versification=t}updateInternal(t,n,r){this.bookNum=ae.bookIdToNumber(t),this.chapter=n,this.verse=r}};ne(je,"defaultVersification",ut.English),ne(je,"verseRangeSeparator","-"),ne(je,"verseSequenceIndicator",","),ne(je,"verseRangeSeparators",[je.verseRangeSeparator]),ne(je,"verseSequenceIndicators",[je.verseSequenceIndicator]),ne(je,"chapterDigitShifter",1e3),ne(je,"bookDigitShifter",je.chapterDigitShifter*je.chapterDigitShifter),ne(je,"bcvMaxValue",je.chapterDigitShifter-1),ne(je,"ValidStatusType",ls);class nn extends Error{}const or=pe.Root,lo=pe.Trigger,cs=pe.Group,ql=pe.Portal,Hl=pe.Sub,Xl=pe.RadioGroup,ds=g.forwardRef(({className:e,inset:t,children:n,...r},o)=>a.jsxs(pe.SubTrigger,{ref:o,className:N("tw-flex tw-cursor-default tw-select-none tw-items-center tw-rounded-sm tw-px-2 tw-py-1.5 tw-text-sm tw-outline-none focus:tw-bg-accent data-[state=open]:tw-bg-accent",t&&"tw-pl-8",e),...r,children:[n,a.jsx(Q.ChevronRight,{className:"tw-ml-auto tw-h-4 tw-w-4"})]}));ds.displayName=pe.SubTrigger.displayName;const us=g.forwardRef(({className:e,...t},n)=>a.jsx(pe.SubContent,{ref:n,className:N("tw-z-50 tw-min-w-[8rem] tw-overflow-hidden tw-rounded-md tw-border tw-bg-popover tw-p-1 tw-text-popover-foreground tw-shadow-lg data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0 data-[state=closed]:tw-zoom-out-95 data-[state=open]:tw-zoom-in-95 data-[side=bottom]:tw-slide-in-from-top-2 data-[side=left]:tw-slide-in-from-right-2 data-[side=right]:tw-slide-in-from-left-2 data-[side=top]:tw-slide-in-from-bottom-2",e),...t}));us.displayName=pe.SubContent.displayName;const En=g.forwardRef(({className:e,sideOffset:t=4,...n},r)=>a.jsx(pe.Portal,{children:a.jsx(pe.Content,{ref:r,sideOffset:t,className:N("pr-twp tw-z-50 tw-min-w-[8rem] tw-overflow-hidden tw-rounded-md tw-border tw-bg-popover tw-p-1 tw-text-popover-foreground tw-shadow-md data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0 data-[state=closed]:tw-zoom-out-95 data-[state=open]:tw-zoom-in-95 data-[side=bottom]:tw-slide-in-from-top-2 data-[side=left]:tw-slide-in-from-right-2 data-[side=right]:tw-slide-in-from-left-2 data-[side=top]:tw-slide-in-from-bottom-2",e),...n})}));En.displayName=pe.Content.displayName;const co=g.forwardRef(({className:e,inset:t,...n},r)=>a.jsx(pe.Item,{ref:r,className:N("tw-cursor-default tw-select-none tw-items-center tw-rounded-sm tw-px-2 tw-py-1.5 tw-text-sm tw-outline-none tw-transition-colors focus:tw-bg-accent data-[disabled]:tw-pointer-events-none data-[disabled]:tw-opacity-50",t&&"tw-pl-8",e),...n}));co.displayName=pe.Item.displayName;const ar=g.forwardRef(({className:e,children:t,checked:n,...r},o)=>a.jsxs(pe.CheckboxItem,{ref:o,className:N("tw-relative tw-flex tw-cursor-default tw-select-none tw-items-center tw-rounded-sm tw-py-1.5 tw-pl-8 tw-pr-2 tw-text-sm tw-outline-none tw-transition-colors focus:tw-bg-accent focus:tw-text-accent-foreground data-[disabled]:tw-pointer-events-none data-[disabled]:tw-opacity-50",e),checked:n,...r,children:[a.jsx("span",{className:"tw-absolute tw-left-2 tw-flex tw-h-3.5 tw-w-3.5 tw-items-center tw-justify-center",children:a.jsx(pe.ItemIndicator,{children:a.jsx(Q.Check,{className:"tw-h-4 tw-w-4"})})}),t]}));ar.displayName=pe.CheckboxItem.displayName;const uo=g.forwardRef(({className:e,children:t,...n},r)=>a.jsxs(pe.RadioItem,{ref:r,className:N("tw-relative tw-flex tw-cursor-default tw-select-none tw-items-center tw-rounded-sm tw-py-1.5 tw-pl-8 tw-pr-2 tw-text-sm tw-outline-none tw-transition-colors focus:tw-bg-accent focus:tw-text-accent-foreground data-[disabled]:tw-pointer-events-none data-[disabled]:tw-opacity-50",e),...n,children:[a.jsx("span",{className:"tw-absolute tw-left-2 tw-flex tw-h-3.5 tw-w-3.5 tw-items-center tw-justify-center",children:a.jsx(pe.ItemIndicator,{children:a.jsx(Q.Circle,{className:"tw-h-2 tw-w-2 tw-fill-current"})})}),t]}));uo.displayName=pe.RadioItem.displayName;const Wt=g.forwardRef(({className:e,inset:t,...n},r)=>a.jsx(pe.Label,{ref:r,className:N("tw-px-2 tw-py-1.5 tw-text-sm tw-font-semibold",t&&"tw-pl-8",e),...n}));Wt.displayName=pe.Label.displayName;const jn=g.forwardRef(({className:e,...t},n)=>a.jsx(pe.Separator,{ref:n,className:N("tw--mx-1 tw-my-1 tw-h-px tw-bg-muted",e),...t}));jn.displayName=pe.Separator.displayName;function ps({className:e,...t}){return a.jsx("span",{className:N("tw-ml-auto tw-text-xs tw-tracking-widest tw-opacity-60",e),...t})}ps.displayName="DropdownMenuShortcut";const Yl=g.forwardRef(({bookId:e,handleSelectBook:t,isSelected:n,handleHighlightBook:r,handleKeyDown:o,bookType:s,children:i},l)=>a.jsxs(co,{ref:l,textValue:e,className:N("tw-mx-1 tw-px-1 tw-font-normal tw-text-foreground/80",{"tw-bg-amber-50 tw-text-yellow-900 data-[highlighted]:tw-bg-amber-100":n}),onSelect:c=>{c.preventDefault(),t()},onKeyDown:c=>{o(c)},onFocus:r,onMouseMove:r,children:[a.jsx("span",{className:N("tw-border-b-0 tw-border-l-2 tw-border-r-0 tw-border-t-0 tw-border-solid tw-px-2",{"tw-font-bold":n,"tw-border-l-red-200":s.toLowerCase()==="ot","tw-border-l-purple-200":s.toLowerCase()==="nt","tw-border-l-indigo-200":s.toLowerCase()==="dc"}),children:ae.bookIdToEnglishName(e)}),n&&a.jsx("div",{children:i})]},e));function Wl({handleSelectChapter:e,endChapter:t,activeChapter:n,highlightedChapter:r,handleHighlightedChapter:o}){const s=Array.from({length:t},(l,c)=>c+1),i=g.useCallback(l=>{o(l)},[o]);return a.jsx("div",{className:N("tw-flex tw-flex-wrap tw-items-start tw-justify-start tw-self-stretch"),children:s.map(l=>a.jsx("div",{className:N("tw-box-content tw-flex tw-h-4 tw-w-4 tw-cursor-pointer tw-items-center tw-justify-end tw-rounded-md tw-p-2 tw-text-amber-800",{"tw-font-semibold tw-text-amber-900":l===n,"tw-bg-amber-200":l===r}),onClick:c=>{c.preventDefault(),c.stopPropagation(),e(l)},role:"button",onKeyDown:c=>{c.key==="Enter"&&e(l)},tabIndex:0,onMouseMove:()=>i(l),children:l},l))})}function Kl({handleSort:e,handleLocationHistory:t,handleBookmarks:n}){return a.jsxs(Wt,{className:"tw-flex tw-justify-between",children:[a.jsx("p",{className:"tw-inline-block tw-align-middle",children:"Go To"}),a.jsxs("div",{className:"tw-flex tw-items-center",children:[a.jsx(Q.ArrowDownWideNarrow,{onClick:e,className:"tw-m-2 tw-h-4 tw-w-4 tw-cursor-pointer tw-gap-2"}),a.jsx(Q.Clock,{onClick:t,className:"tw-m-2 tw-h-4 tw-w-4 tw-cursor-pointer tw-gap-2"}),a.jsx(Q.Bookmark,{onClick:n,className:"tw-m-2 tw-h-4 tw-w-4 tw-cursor-pointer tw-gap-2"})]})]})}const wn=ae.allBookIds,Jl={OT:"Old Testament",NT:"New Testament",DC:"Deuterocanon"},aa=["OT","NT","DC"],Zl=32+32+32,Ql=[/^(\w+)$/i,/^(\w+)(?:\s(\d+))$/i,/^(\w+)(?:\s(\d+):(\d+))$/i],ec=e=>({OT:wn.filter(n=>ae.isBookOT(n)),NT:wn.filter(n=>ae.isBookNT(n)),DC:wn.filter(n=>ae.isBookDC(n))})[e],rn=e=>W.getChaptersForBook(ae.bookIdToNumber(e));function tc(){return wn.map(t=>ae.bookIdToEnglishName(t))}function nc(e){return tc().includes(e)}function rc(e){const t=e.toLowerCase().replace(/^\w/,n=>n.toUpperCase());if(nc(t))return wn.find(r=>ae.bookIdToEnglishName(r)===t)}function oc({scrRef:e,handleSubmit:t}){const[n,r]=g.useState(""),[o,s]=g.useState(ae.bookNumberToId(e.bookNum)),[i,l]=g.useState(e.chapterNum??0),[c,d]=g.useState(ae.bookNumberToId(e.bookNum)),[u,f]=g.useState(!1),[w,b]=g.useState(u),x=g.useRef(void 0),m=g.useRef(void 0),h=g.useRef(void 0),S=g.useCallback(k=>ec(k).filter(D=>{const $=ae.bookIdToEnglishName(D).toLowerCase(),J=n.replace(/[^a-zA-Z]/g,"").toLowerCase();return $.includes(J)||D.toLowerCase().includes(J)}),[n]),R=k=>{r(k)},j=g.useRef(!1),E=g.useCallback(k=>{if(j.current){j.current=!1;return}f(k)},[]),v=g.useCallback((k,D,$,J)=>{if(l(ae.bookNumberToId(e.bookNum)!==k?1:e.chapterNum),D||rn(k)===-1){t({bookNum:ae.bookIdToNumber(k),chapterNum:$||1,verseNum:J||1}),f(!1),r("");return}s(o!==k?k:""),f(!D)},[t,e.bookNum,e.chapterNum,o]),P=k=>{k<=0||k>rn(o)||v(o,!0,k)},V=g.useCallback(()=>{Ql.forEach(k=>{const D=n.match(k);if(D){const[$,J=void 0,Y=void 0]=D.slice(1),F=rc($);(ae.isBookIdValid($)||F)&&v(F??$,!0,J?parseInt(J,10):1,Y?parseInt(Y,10):1)}})},[v,n]),U=g.useCallback(k=>{u?(k.key==="ArrowDown"||k.key==="ArrowUp")&&(typeof h<"u"&&h.current!==null?h.current.focus():typeof m<"u"&&m.current!==null&&m.current.focus(),k.preventDefault()):f(!0)},[u]),C=k=>{const{key:D}=k;D==="ArrowRight"||D==="ArrowLeft"||D==="ArrowDown"||D==="ArrowUp"||D==="Enter"||(x.current.dispatchEvent(new KeyboardEvent("keydown",{key:D})),x.current.focus())},_=k=>{const{key:D}=k;if(c===o){if(D==="Enter"){k.preventDefault(),v(o,!0,i);return}let $=0;if(D==="ArrowRight")if(i1)$=-1;else{k.preventDefault();return}else D==="ArrowDown"?$=6:D==="ArrowUp"&&($=-6);i+$<=0||i+$>rn(c)?l(0):$!==0&&(l(i+$),k.preventDefault())}};return g.useEffect(()=>{o===c?o===ae.bookNumberToId(e.bookNum)?l(e.chapterNum):l(1):l(0)},[c,e.bookNum,e.chapterNum,o]),g.useLayoutEffect(()=>{b(u)},[u]),g.useLayoutEffect(()=>{const k=setTimeout(()=>{if(w&&m.current&&h.current){const $=h.current.offsetTop-Zl;m.current.scrollTo({top:$,behavior:"instant"})}},10);return()=>{clearTimeout(k)}},[w]),a.jsx("div",{className:"pr-twp tw-flex",children:a.jsxs(or,{modal:!1,open:u,onOpenChange:E,children:[a.jsx(lo,{asChild:!0,children:a.jsx(Pl,{ref:x,value:n,handleSearch:R,handleKeyDown:U,handleOnClick:()=>{s(ae.bookNumberToId(e.bookNum)),d(ae.bookNumberToId(e.bookNum)),l(e.chapterNum>0?e.chapterNum:0),f(!0),x.current.focus()},onFocus:()=>{j.current=!0},handleSubmit:V,placeholder:`${ae.bookNumberToEnglishName(e.bookNum)} ${e.chapterNum}:${e.verseNum}`})}),a.jsxs(En,{className:"tw-m-1 tw-overflow-y-auto tw-p-0 tw-font-normal tw-text-foreground/80",style:{width:"233px",maxHeight:"500px",zIndex:"250"},onKeyDown:C,align:"start",ref:m,children:[a.jsx(Kl,{handleSort:()=>console.log("sorting"),handleLocationHistory:()=>console.log("location history"),handleBookmarks:()=>console.log("bookmarks")}),aa.map((k,D)=>S(k).length>0&&a.jsxs("div",{children:[a.jsx(Wt,{className:"tw-font-semibold tw-text-foreground/80",children:Jl[k]}),S(k).map($=>a.jsx("div",{children:a.jsx(Yl,{bookId:$,handleSelectBook:()=>v($,!1),isSelected:o===$,handleHighlightBook:()=>d($),handleKeyDown:_,bookType:k,ref:J=>{o===$&&(h.current=J)},children:a.jsx(Wl,{handleSelectChapter:P,endChapter:rn($),activeChapter:e.bookNum===ae.bookIdToNumber($)?e.chapterNum:0,highlightedChapter:i,handleHighlightedChapter:J=>{l(J)}})})},$)),aa.length-1!==D?a.jsx(jn,{}):void 0]},k))]})]})})}const ws=Xt.cva("pr-twp tw-inline-flex tw-items-center tw-justify-center tw-whitespace-nowrap tw-rounded-md tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-colors focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50",{variants:{variant:{default:"tw-bg-primary tw-text-primary-foreground hover:tw-bg-primary/90",destructive:"tw-bg-destructive tw-text-destructive-foreground hover:tw-bg-destructive/90",outline:"tw-border tw-border-input tw-bg-background hover:tw-bg-accent hover:tw-text-accent-foreground",secondary:"tw-bg-secondary tw-text-secondary-foreground hover:tw-bg-secondary/80",ghost:"hover:tw-bg-accent hover:tw-text-accent-foreground",link:"tw-text-primary tw-underline-offset-4 hover:tw-underline"},size:{default:"tw-h-10 tw-px-4 tw-py-2",sm:"tw-h-9 tw-rounded-md tw-px-3",lg:"tw-h-11 tw-rounded-md tw-px-8",icon:"tw-h-10 tw-w-10"}},defaultVariants:{variant:"default",size:"default"}}),fe=g.forwardRef(({className:e,variant:t,size:n,asChild:r=!1,...o},s)=>{const i=r?Ht.Slot:"button";return a.jsx(i,{className:N(ws({variant:t,size:n,className:e})),ref:s,...o})});fe.displayName="Button";const ac=Xt.cva("tw-text-sm tw-font-medium tw-leading-none peer-disabled:tw-cursor-not-allowed peer-disabled:tw-opacity-70"),qe=g.forwardRef(({className:e,...t},n)=>a.jsx(es.Root,{ref:n,className:N("pr-twp",ac(),e),...t}));qe.displayName=es.Root.displayName;const po=g.forwardRef(({className:e,...t},n)=>a.jsx(bn.Root,{className:N("pr-twp tw-grid tw-gap-2",e),...t,ref:n}));po.displayName=bn.Root.displayName;const Yn=g.forwardRef(({className:e,...t},n)=>a.jsx(bn.Item,{ref:n,className:N("pr-twp tw-aspect-square tw-h-4 tw-w-4 tw-rounded-full tw-border tw-border-primary tw-text-primary tw-ring-offset-background focus:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-cursor-not-allowed disabled:tw-opacity-50",e),...t,children:a.jsx(bn.Indicator,{className:"tw-flex tw-items-center tw-justify-center",children:a.jsx(Q.Circle,{className:"tw-h-2.5 tw-w-2.5 tw-fill-current tw-text-current"})})}));Yn.displayName=bn.Item.displayName;const sc=vn.Root,ic=vn.Trigger,fs=g.forwardRef(({className:e,align:t="center",sideOffset:n=4,...r},o)=>a.jsx(vn.Portal,{children:a.jsx(vn.Content,{ref:o,align:t,sideOffset:n,className:N("pr-twp tw-z-50 tw-w-72 tw-rounded-md tw-border tw-bg-popover tw-p-4 tw-text-popover-foreground tw-shadow-md tw-outline-none data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0 data-[state=closed]:tw-zoom-out-95 data-[state=open]:tw-zoom-in-95 data-[side=bottom]:tw-slide-in-from-top-2 data-[side=left]:tw-slide-in-from-right-2 data-[side=right]:tw-slide-in-from-left-2 data-[side=top]:tw-slide-in-from-bottom-2",e),...r})}));fs.displayName=vn.Content.displayName;const lc=be.Portal,ms=g.forwardRef(({className:e,...t},n)=>a.jsx(be.Overlay,{ref:n,className:N("tw-fixed tw-inset-0 tw-z-50 tw-bg-black/80 data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0",e),...t}));ms.displayName=be.Overlay.displayName;const cc=g.forwardRef(({className:e,children:t,...n},r)=>a.jsxs(lc,{children:[a.jsx(ms,{}),a.jsxs(be.Content,{ref:r,className:N("tw-fixed tw-left-[50%] tw-top-[50%] tw-z-50 tw-grid tw-w-full tw-max-w-lg tw-translate-x-[-50%] tw-translate-y-[-50%] tw-gap-4 tw-border tw-bg-background tw-p-6 tw-shadow-lg tw-duration-200 data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0 data-[state=closed]:tw-zoom-out-95 data-[state=open]:tw-zoom-in-95 data-[state=closed]:tw-slide-out-to-left-1/2 data-[state=closed]:tw-slide-out-to-top-[48%] data-[state=open]:tw-slide-in-from-left-1/2 data-[state=open]:tw-slide-in-from-top-[48%] sm:tw-rounded-lg",e),...n,children:[t,a.jsxs(be.Close,{className:"tw-absolute tw-right-4 tw-top-4 tw-rounded-sm tw-opacity-70 tw-ring-offset-background tw-transition-opacity hover:tw-opacity-100 focus:tw-outline-none focus:tw-ring-2 focus:tw-ring-ring focus:tw-ring-offset-2 disabled:tw-pointer-events-none data-[state=open]:tw-bg-accent data-[state=open]:tw-text-muted-foreground",children:[a.jsx(Q.X,{className:"tw-h-4 tw-w-4"}),a.jsx("span",{className:"tw-sr-only",children:"Close"})]})]})]}));cc.displayName=be.Content.displayName;const dc=g.forwardRef(({className:e,...t},n)=>a.jsx(be.Title,{ref:n,className:N("tw-text-lg tw-font-semibold tw-leading-none tw-tracking-tight",e),...t}));dc.displayName=be.Title.displayName;const uc=g.forwardRef(({className:e,...t},n)=>a.jsx(be.Description,{ref:n,className:N("tw-text-sm tw-text-muted-foreground",e),...t}));uc.displayName=be.Description.displayName;const hs=g.forwardRef(({className:e,...t},n)=>a.jsx(Re.Command,{ref:n,className:N("tw-flex tw-h-full tw-w-full tw-flex-col tw-overflow-hidden tw-rounded-md tw-bg-popover tw-text-popover-foreground",e),...t}));hs.displayName=Re.Command.displayName;const gs=g.forwardRef(({className:e,...t},n)=>a.jsxs("div",{className:"tw-flex tw-items-center tw-border-b tw-px-3",children:[a.jsx(Q.Search,{className:"tw-me-2 tw-h-4 tw-w-4 tw-shrink-0 tw-opacity-50"}),a.jsx(Re.Command.Input,{ref:n,className:N("tw-flex tw-h-11 tw-w-full tw-rounded-md tw-bg-transparent tw-py-3 tw-text-sm tw-outline-none placeholder:tw-text-muted-foreground disabled:tw-cursor-not-allowed disabled:tw-opacity-50",e),...t})]}));gs.displayName=Re.Command.Input.displayName;const bs=g.forwardRef(({className:e,...t},n)=>a.jsx(Re.Command.List,{ref:n,className:N("tw-max-h-[300px] tw-overflow-y-auto tw-overflow-x-hidden",e),...t}));bs.displayName=Re.Command.List.displayName;const vs=g.forwardRef((e,t)=>a.jsx(Re.Command.Empty,{ref:t,className:"tw-py-6 tw-text-center tw-text-sm",...e}));vs.displayName=Re.Command.Empty.displayName;const pc=g.forwardRef(({className:e,...t},n)=>a.jsx(Re.Command.Group,{ref:n,className:N("tw-overflow-hidden tw-p-1 tw-text-foreground [&_[cmdk-group-heading]]:tw-px-2 [&_[cmdk-group-heading]]:tw-py-1.5 [&_[cmdk-group-heading]]:tw-text-xs [&_[cmdk-group-heading]]:tw-font-medium [&_[cmdk-group-heading]]:tw-text-muted-foreground",e),...t}));pc.displayName=Re.Command.Group.displayName;const wc=g.forwardRef(({className:e,...t},n)=>a.jsx(Re.Command.Separator,{ref:n,className:N("tw--mx-1 tw-h-px tw-bg-border",e),...t}));wc.displayName=Re.Command.Separator.displayName;const xs=g.forwardRef(({className:e,...t},n)=>a.jsx(Re.Command.Item,{ref:n,className:N("tw-relative tw-flex tw-cursor-default tw-select-none tw-items-center tw-rounded-sm tw-px-2 tw-py-1.5 tw-text-sm tw-outline-none data-[disabled=true]:tw-pointer-events-none data-[selected=true]:tw-bg-accent data-[selected=true]:tw-text-accent-foreground data-[disabled=true]:tw-opacity-50",e),...t}));xs.displayName=Re.Command.Item.displayName;function fc(e){return typeof e=="string"?e:typeof e=="number"?e.toString():e.label}function Wn({id:e,options:t=[],buttonClassName:n,popoverContentClassName:r,value:o,onChange:s=()=>{},getOptionLabel:i=fc,buttonPlaceholder:l="",textPlaceholder:c="",commandEmptyMessage:d="No option found",buttonVariant:u="outline",dir:f="ltr",isDisabled:w=!1,...b}){const[x,m]=g.useState(!1);return a.jsxs(sc,{open:x,onOpenChange:m,...b,children:[a.jsx(ic,{asChild:!0,children:a.jsxs(fe,{variant:u,role:"combobox","aria-expanded":x,id:e,className:N("tw-w-[200px] tw-justify-between",n),disabled:w,children:[a.jsx("span",{className:"tw-overflow-hidden tw-text-ellipsis tw-whitespace-nowrap",children:o?i(o):l}),a.jsx(Q.ChevronsUpDown,{className:"tw-ms-2 tw-h-4 tw-w-4 tw-shrink-0 tw-opacity-50"})]})}),a.jsx(fs,{className:N("tw-w-[200px] tw-p-0",r),dir:f,children:a.jsxs(hs,{children:[a.jsx(gs,{dir:f,placeholder:c,className:"tw-text-inherit"}),a.jsx(vs,{children:d}),a.jsx(bs,{children:t.map(h=>a.jsxs(xs,{value:i(h),onSelect:()=>{s(h),m(!1)},children:[a.jsx(Q.Check,{className:N("tw-me-2 tw-h-4 tw-w-4",{"tw-opacity-0":!o||i(o)!==i(h)})}),i(h)]},i(h)))})]})})]})}function ys({startChapter:e,endChapter:t,handleSelectStartChapter:n,handleSelectEndChapter:r,isDisabled:o=!1,chapterCount:s}){const i=g.useMemo(()=>Array.from({length:s},(d,u)=>u+1),[s]),l=d=>{n(d),d>t&&r(d)},c=d=>{r(d),dd.toString(),value:e},"start chapter"),a.jsx(qe,{htmlFor:"end-chapters-combobox",children:"to"}),a.jsx(Wn,{isDisabled:o,onChange:c,buttonClassName:"tw-ml-2 tw-w-20",options:i,getOptionLabel:d=>d.toString(),value:t},"end chapter")]})}var Ns=(e=>(e.CURRENT_BOOK="current book",e.CHOOSE_BOOKS="choose books",e))(Ns||{});const mc=Object.freeze(["%webView_bookSelector_currentBook%","%webView_bookSelector_choose%","%webView_bookSelector_chooseBooks%"]),Tr=(e,t)=>e[t]??t;function hc({handleBookSelectionModeChange:e,currentBookName:t,onSelectBooks:n,selectedBookIds:r,chapterCount:o,endChapter:s,handleSelectEndChapter:i,startChapter:l,handleSelectStartChapter:c,localizedStrings:d}){const u=Tr(d,"%webView_bookSelector_currentBook%"),f=Tr(d,"%webView_bookSelector_choose%"),w=Tr(d,"%webView_bookSelector_chooseBooks%"),[b,x]=g.useState("current book"),m=h=>{x(h),e(h)};return a.jsx(po,{className:"pr-twp tw-flex",value:b,onValueChange:h=>m(h),children:a.jsxs("div",{className:"tw-flex tw-w-full tw-flex-col tw-gap-4",children:[a.jsxs("div",{className:"tw-grid tw-grid-cols-[25%,25%,50%]",children:[a.jsxs("div",{className:"tw-flex tw-items-center",children:[a.jsx(Yn,{value:"current book"}),a.jsx(qe,{className:"tw-ml-1",children:u})]}),a.jsx(qe,{className:"tw-flex tw-items-center",children:t}),a.jsx("div",{className:"tw-flex tw-items-center tw-justify-end",children:a.jsx(ys,{isDisabled:b==="choose books",handleSelectStartChapter:c,handleSelectEndChapter:i,chapterCount:o,startChapter:l,endChapter:s})})]}),a.jsxs("div",{className:"tw-grid tw-grid-cols-[25%,50%,25%]",children:[a.jsxs("div",{className:"tw-flex tw-items-center",children:[a.jsx(Yn,{value:"choose books"}),a.jsx(qe,{className:"tw-ml-1",children:w})]}),a.jsx(qe,{className:"tw-flex tw-items-center",children:r.map(h=>ae.bookIdToEnglishName(h)).join(", ")}),a.jsx(fe,{disabled:b==="current book",onClick:()=>n(),children:f})]})]})})}function gc({table:e}){return a.jsxs(or,{children:[a.jsx(Za.DropdownMenuTrigger,{asChild:!0,children:a.jsxs(fe,{variant:"outline",size:"sm",className:"tw-ml-auto tw-hidden tw-h-8 lg:tw-flex",children:[a.jsx(Q.FilterIcon,{className:"tw-mr-2 tw-h-4 tw-w-4"}),"View"]})}),a.jsxs(En,{align:"end",className:"tw-w-[150px]",children:[a.jsx(Wt,{children:"Toggle columns"}),a.jsx(jn,{}),e.getAllColumns().filter(t=>t.getCanHide()).map(t=>a.jsx(ar,{className:"tw-capitalize",checked:t.getIsVisible(),onCheckedChange:n=>t.toggleVisibility(!!n),children:t.id},t.id))]})]})}const At=ge.Root,ks=ge.Group,Bt=ge.Value,bt=g.forwardRef(({className:e,children:t,...n},r)=>a.jsxs(ge.Trigger,{ref:r,className:N("tw-flex tw-h-10 tw-w-full tw-items-center tw-justify-between tw-rounded-md tw-border tw-border-input tw-bg-background tw-px-3 tw-py-2 tw-text-sm tw-ring-offset-background placeholder:tw-text-muted-foreground focus:tw-outline-none focus:tw-ring-2 focus:tw-ring-ring focus:tw-ring-offset-2 disabled:tw-cursor-not-allowed disabled:tw-opacity-50 [&>span]:tw-line-clamp-1",e),...n,children:[t,a.jsx(ge.Icon,{asChild:!0,children:a.jsx(Q.ChevronDown,{className:"tw-h-4 tw-w-4 tw-opacity-50"})})]}));bt.displayName=ge.Trigger.displayName;const wo=g.forwardRef(({className:e,...t},n)=>a.jsx(ge.ScrollUpButton,{ref:n,className:N("tw-flex tw-cursor-default tw-items-center tw-justify-center tw-py-1",e),...t,children:a.jsx(Q.ChevronUp,{className:"tw-h-4 tw-w-4"})}));wo.displayName=ge.ScrollUpButton.displayName;const fo=g.forwardRef(({className:e,...t},n)=>a.jsx(ge.ScrollDownButton,{ref:n,className:N("tw-flex tw-cursor-default tw-items-center tw-justify-center tw-py-1",e),...t,children:a.jsx(Q.ChevronDown,{className:"tw-h-4 tw-w-4"})}));fo.displayName=ge.ScrollDownButton.displayName;const vt=g.forwardRef(({className:e,children:t,position:n="popper",...r},o)=>a.jsx(ge.Portal,{children:a.jsxs(ge.Content,{ref:o,className:N("pr-twp tw-relative tw-z-50 tw-max-h-96 tw-min-w-[8rem] tw-overflow-hidden tw-rounded-md tw-border tw-bg-popover tw-text-popover-foreground tw-shadow-md data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0 data-[state=closed]:tw-zoom-out-95 data-[state=open]:tw-zoom-in-95 data-[side=bottom]:tw-slide-in-from-top-2 data-[side=left]:tw-slide-in-from-right-2 data-[side=right]:tw-slide-in-from-left-2 data-[side=top]:tw-slide-in-from-bottom-2",n==="popper"&&"data-[side=bottom]:tw-translate-y-1 data-[side=left]:tw--translate-x-1 data-[side=right]:tw-translate-x-1 data-[side=top]:tw--translate-y-1",e),position:n,...r,children:[a.jsx(wo,{}),a.jsx(ge.Viewport,{className:N("tw-p-1",n==="popper"&&"tw-h-[var(--radix-select-trigger-height)] tw-w-full tw-min-w-[var(--radix-select-trigger-width)]"),children:t}),a.jsx(fo,{})]})}));vt.displayName=ge.Content.displayName;const Ss=g.forwardRef(({className:e,...t},n)=>a.jsx(ge.Label,{ref:n,className:N("tw-py-1.5 tw-pl-8 tw-pr-2 tw-text-sm tw-font-semibold",e),...t}));Ss.displayName=ge.Label.displayName;const Ae=g.forwardRef(({className:e,children:t,...n},r)=>a.jsxs(ge.Item,{ref:r,className:N("tw-relative tw-flex tw-w-full tw-cursor-default tw-select-none tw-items-center tw-rounded-sm tw-py-1.5 tw-pl-8 tw-pr-2 tw-text-sm tw-outline-none focus:tw-bg-accent focus:tw-text-accent-foreground data-[disabled]:tw-pointer-events-none data-[disabled]:tw-opacity-50",e),...n,children:[a.jsx("span",{className:"tw-absolute tw-left-2 tw-flex tw-h-3.5 tw-w-3.5 tw-items-center tw-justify-center",children:a.jsx(ge.ItemIndicator,{children:a.jsx(Q.Check,{className:"tw-h-4 tw-w-4"})})}),a.jsx(ge.ItemText,{children:t})]}));Ae.displayName=ge.Item.displayName;const Es=g.forwardRef(({className:e,...t},n)=>a.jsx(ge.Separator,{ref:n,className:N("tw--mx-1 tw-my-1 tw-h-px tw-bg-muted",e),...t}));Es.displayName=ge.Separator.displayName;function bc({table:e}){return a.jsx("div",{className:"tw-flex tw-items-center tw-justify-between tw-px-2 tw-pb-3 tw-pt-3",children:a.jsxs("div",{className:"tw-flex tw-items-center tw-space-x-6 lg:tw-space-x-8",children:[a.jsxs("div",{className:"tw-flex-1 tw-text-sm tw-text-muted-foreground",children:[e.getFilteredSelectedRowModel().rows.length," of"," ",e.getFilteredRowModel().rows.length," row(s) selected"]}),a.jsxs("div",{className:"tw-flex tw-items-center tw-space-x-2",children:[a.jsx("p",{className:"tw-text-nowrap tw-text-sm tw-font-medium",children:"Rows per page"}),a.jsxs(At,{value:`${e.getState().pagination.pageSize}`,onValueChange:t=>{e.setPageSize(Number(t))},children:[a.jsx(bt,{className:"tw-h-8 tw-w-[70px]",children:a.jsx(Bt,{placeholder:e.getState().pagination.pageSize})}),a.jsx(vt,{side:"top",children:[10,20,30,40,50].map(t=>a.jsx(Ae,{value:`${t}`,children:t},t))})]})]}),a.jsxs("div",{className:"tw-flex tw-w-[100px] tw-items-center tw-justify-center tw-text-sm tw-font-medium",children:["Page ",e.getState().pagination.pageIndex+1," of ",e.getPageCount()]}),a.jsxs("div",{className:"tw-flex tw-items-center tw-space-x-2",children:[a.jsxs(fe,{variant:"outline",size:"icon",className:"tw-hidden tw-h-8 tw-w-8 tw-p-0 lg:tw-flex",onClick:()=>e.setPageIndex(0),disabled:!e.getCanPreviousPage(),children:[a.jsx("span",{className:"tw-sr-only",children:"Go to first page"}),a.jsx(Q.ArrowLeftIcon,{className:"tw-h-4 tw-w-4"})]}),a.jsxs(fe,{variant:"outline",size:"icon",className:"tw-h-8 tw-w-8 tw-p-0",onClick:()=>e.previousPage(),disabled:!e.getCanPreviousPage(),children:[a.jsx("span",{className:"tw-sr-only",children:"Go to previous page"}),a.jsx(Q.ChevronLeftIcon,{className:"tw-h-4 tw-w-4"})]}),a.jsxs(fe,{variant:"outline",size:"icon",className:"tw-h-8 tw-w-8 tw-p-0",onClick:()=>e.nextPage(),disabled:!e.getCanNextPage(),children:[a.jsx("span",{className:"tw-sr-only",children:"Go to next page"}),a.jsx(Q.ChevronRightIcon,{className:"tw-h-4 tw-w-4"})]}),a.jsxs(fe,{variant:"outline",size:"icon",className:"tw-hidden tw-h-8 tw-w-8 tw-p-0 lg:tw-flex",onClick:()=>e.setPageIndex(e.getPageCount()-1),disabled:!e.getCanNextPage(),children:[a.jsx("span",{className:"tw-sr-only",children:"Go to last page"}),a.jsx(Q.ArrowRightIcon,{className:"tw-h-4 tw-w-4"})]})]})]})})}const Cn=g.forwardRef(({className:e,stickyHeader:t,...n},r)=>a.jsx("div",{className:N("pr-twp tw-relative tw-w-full",{"tw-overflow-auto":!t}),children:a.jsx("table",{ref:r,className:N("tw-w-full tw-caption-bottom tw-text-sm",e),...n})}));Cn.displayName="Table";const Tn=g.forwardRef(({className:e,stickyHeader:t,...n},r)=>a.jsx("thead",{ref:r,className:N({"tw-sticky tw-top-[-1px] tw-bg-background tw-drop-shadow-sm":t},"[&_tr]:tw-border-b",e),...n}));Tn.displayName="TableHeader";const Rn=g.forwardRef(({className:e,...t},n)=>a.jsx("tbody",{ref:n,className:N("[&_tr:last-child]:tw-border-0",e),...t}));Rn.displayName="TableBody";const js=g.forwardRef(({className:e,...t},n)=>a.jsx("tfoot",{ref:n,className:N("tw-border-t tw-bg-muted/50 tw-font-medium [&>tr]:last:tw-border-b-0",e),...t}));js.displayName="TableFooter";const Ze=g.forwardRef(({className:e,...t},n)=>a.jsx("tr",{ref:n,className:N("tw-border-b tw-transition-colors hover:tw-bg-muted/50 data-[state=selected]:tw-bg-muted",e),...t}));Ze.displayName="TableRow";const Vt=g.forwardRef(({className:e,...t},n)=>a.jsx("th",{ref:n,className:N("tw-h-12 tw-px-4 tw-text-start tw-align-middle tw-font-medium tw-text-muted-foreground [&:has([role=checkbox])]:tw-pe-0",e),...t}));Vt.displayName="TableHead";const xt=g.forwardRef(({className:e,...t},n)=>a.jsx("td",{ref:n,className:N("tw-p-4 tw-align-middle [&:has([role=checkbox])]:tw-pe-0",e),...t}));xt.displayName="TableCell";const Cs=g.forwardRef(({className:e,...t},n)=>a.jsx("caption",{ref:n,className:N("tw-mt-4 tw-text-sm tw-text-muted-foreground",e),...t}));Cs.displayName="TableCaption";function Ts({columns:e,data:t,enablePagination:n=!1,showPaginationControls:r=!1,showColumnVisibilityControls:o=!1,stickyHeader:s=!1,onRowClickHandler:i=()=>{}}){var h;const[l,c]=g.useState([]),[d,u]=g.useState([]),[f,w]=g.useState({}),[b,x]=g.useState({}),m=Se.useReactTable({data:t,columns:e,getCoreRowModel:Se.getCoreRowModel(),...n&&{getPaginationRowModel:Se.getPaginationRowModel()},onSortingChange:c,getSortedRowModel:Se.getSortedRowModel(),onColumnFiltersChange:u,getFilteredRowModel:Se.getFilteredRowModel(),onColumnVisibilityChange:w,onRowSelectionChange:x,state:{sorting:l,columnFilters:d,columnVisibility:f,rowSelection:b}});return a.jsxs("div",{className:"pr-twp",children:[o&&a.jsx(gc,{table:m}),a.jsxs(Cn,{stickyHeader:s,children:[a.jsx(Tn,{stickyHeader:s,children:m.getHeaderGroups().map(S=>a.jsx(Ze,{children:S.headers.map(R=>a.jsx(Vt,{children:R.isPlaceholder?void 0:Se.flexRender(R.column.columnDef.header,R.getContext())},R.id))},S.id))}),a.jsx(Rn,{children:(h=m.getRowModel().rows)!=null&&h.length?m.getRowModel().rows.map(S=>a.jsx(Ze,{onClick:()=>i(S,m),"data-state":S.getIsSelected()&&"selected",children:S.getVisibleCells().map(R=>a.jsx(xt,{children:Se.flexRender(R.column.columnDef.cell,R.getContext())},R.id))},S.id)):a.jsx(Ze,{children:a.jsx(xt,{colSpan:e.length,className:"tw-h-24 tw-text-center",children:"No results."})})})]}),n&&a.jsxs("div",{className:"tw-flex tw-items-center tw-justify-end tw-space-x-2 tw-py-4",children:[a.jsx(fe,{variant:"outline",size:"sm",onClick:()=>m.previousPage(),disabled:!m.getCanPreviousPage(),children:"Previous"}),a.jsx(fe,{variant:"outline",size:"sm",onClick:()=>m.nextPage(),disabled:!m.getCanNextPage(),children:"Next"})]}),n&&r&&a.jsx(bc,{table:m})]})}function vc({occurrenceData:e,setScriptureReference:t,localizedStrings:n}){const r=n["%webView_inventory_occurrences_table_header_reference%"],o=n["%webView_inventory_occurrences_table_header_occurrence%"],s=g.useMemo(()=>{const i=[];return e.forEach(l=>{i.some(c=>W.deepEqual(c,l))||i.push(l)}),i},[e]);return a.jsxs(Cn,{stickyHeader:!0,children:[a.jsx(Tn,{stickyHeader:!0,children:a.jsxs(Ze,{children:[a.jsx(Vt,{children:r}),a.jsx(Vt,{children:o})]})}),a.jsx(Rn,{children:s.length>0&&s.map(i=>a.jsxs(Ze,{onClick:()=>{t(i.reference)},children:[a.jsx(xt,{children:`${ae.bookNumberToEnglishName(i.reference.bookNum)} ${i.reference.chapterNum}:${i.reference.verseNum}`}),a.jsx(xt,{children:i.text})]},`${i.reference.bookNum} ${i.reference.chapterNum}:${i.reference.verseNum}-${i.text}`))})]})}const sr=g.forwardRef(({className:e,...t},n)=>a.jsx(Ur.Root,{ref:n,className:N("tw-peer pr-twp tw-h-4 tw-w-4 tw-shrink-0 tw-rounded-sm tw-border tw-border-primary tw-ring-offset-background focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-cursor-not-allowed disabled:tw-opacity-50 data-[state=checked]:tw-bg-primary data-[state=checked]:tw-text-primary-foreground",e),...t,children:a.jsx(Ur.Indicator,{className:N("tw-flex tw-items-center tw-justify-center tw-text-current"),children:a.jsx(Q.Check,{className:"tw-h-4 tw-w-4"})})}));sr.displayName=Ur.Root.displayName;const Rs=e=>e.split(/(?:\r?\n|\r)|(?=(?:\\(?:v|c|id)))/g),Hr=e=>{const t=/^\\[vc]\s+(\d+)/,n=e.match(t);if(n)return+n[1]},Os=e=>{const t=e.match(/^\\id\s+([A-Za-z]+)/);return t?ae.bookIdToNumber(t[1]):0},_s=(e,t,n)=>n.includes(e)?"unapproved":t.includes(e)?"approved":"unknown",Ps=Xt.cva("pr-twp tw-inline-flex tw-items-center tw-justify-center tw-rounded-md tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-colors hover:tw-bg-muted hover:tw-text-muted-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50 data-[state=on]:tw-bg-accent data-[state=on]:tw-text-accent-foreground",{variants:{variant:{default:"tw-bg-transparent",outline:"tw-border tw-border-input tw-bg-transparent hover:tw-bg-accent hover:tw-text-accent-foreground"},size:{default:"tw-h-10 tw-px-3",sm:"tw-h-9 tw-px-2.5",lg:"tw-h-11 tw-px-5"}},defaultVariants:{variant:"default",size:"default"}}),xc=g.forwardRef(({className:e,variant:t,size:n,...r},o)=>a.jsx(ts.Root,{ref:o,className:N(Ps({variant:t,size:n,className:e})),...r}));xc.displayName=ts.Root.displayName;const Is=g.createContext({size:"default",variant:"default"}),mo=g.forwardRef(({className:e,variant:t,size:n,children:r,...o},s)=>a.jsx(rr.Root,{ref:s,className:N("pr-twp tw-flex tw-items-center tw-justify-center tw-gap-1",e),...o,children:a.jsx(Is.Provider,{value:{variant:t,size:n},children:r})}));mo.displayName=rr.Root.displayName;const fn=g.forwardRef(({className:e,children:t,variant:n,size:r,...o},s)=>{const i=g.useContext(Is);return a.jsx(rr.Item,{ref:s,className:N(Ps({variant:i.variant||n,size:i.size||r}),e),...o,children:t})});fn.displayName=rr.Item.displayName;const ir=e=>e==="asc"?a.jsx(Q.ArrowUpIcon,{className:"tw-ms-2 tw-h-4 tw-w-4"}):e==="desc"?a.jsx(Q.ArrowDownIcon,{className:"tw-ms-2 tw-h-4 tw-w-4"}):a.jsx(Q.ArrowUpDownIcon,{className:"tw-ms-2 tw-h-4 tw-w-4"}),yc=e=>({accessorKey:"item",accessorFn:t=>t.items[0],header:({column:t})=>a.jsxs(fe,{variant:"ghost",onClick:()=>t.toggleSorting(void 0),children:[e,ir(t.getIsSorted())]})}),Nc=(e,t)=>({accessorKey:`item${t}`,accessorFn:n=>n.items[t],header:({column:n})=>a.jsxs(fe,{variant:"ghost",onClick:()=>n.toggleSorting(void 0),children:[e,ir(n.getIsSorted())]})}),kc=e=>({accessorKey:"count",header:({column:t})=>a.jsx("div",{className:"tw-flex tw-justify-end tw-tabular-nums",children:a.jsxs(fe,{variant:"ghost",onClick:()=>t.toggleSorting(void 0),children:[e,ir(t.getIsSorted())]})}),cell:({row:t})=>a.jsx("div",{className:"tw-flex tw-justify-end",children:t.getValue("count")})}),Rr=(e,t,n,r,o,s)=>{let i=[...n];e.forEach(c=>{t==="approved"?i.includes(c)||i.push(c):i=i.filter(d=>d!==c)}),r(i);let l=[...o];e.forEach(c=>{t==="unapproved"?l.includes(c)||l.push(c):l=l.filter(d=>d!==c)}),s(l)},Sc=(e,t,n,r,o)=>({accessorKey:"status",header:({column:s})=>a.jsx("div",{className:"tw-flex tw-justify-center",children:a.jsxs(fe,{variant:"ghost",onClick:()=>s.toggleSorting(void 0),children:[e,ir(s.getIsSorted())]})}),cell:({row:s})=>{const i=s.getValue("status"),l=s.getValue("item");return a.jsxs(mo,{value:i,variant:"outline",type:"single",children:[a.jsx(fn,{onClick:()=>Rr([l],"approved",t,n,r,o),value:"approved",children:a.jsx(Q.CircleCheckIcon,{})}),a.jsx(fn,{onClick:()=>Rr([l],"unapproved",t,n,r,o),value:"unapproved",children:a.jsx(Q.CircleXIcon,{})}),a.jsx(fn,{onClick:()=>Rr([l],"unknown",t,n,r,o),value:"unknown",children:a.jsx(Q.CircleHelpIcon,{})})]})}}),Ec=Object.freeze(["%webView_inventory_all%","%webView_inventory_approved%","%webView_inventory_unapproved%","%webView_inventory_unknown%","%webView_inventory_scope_currentBook%","%webView_inventory_scope_chapter%","%webView_inventory_scope_verse%","%webView_inventory_filter_text%","%webView_inventory_show_additional_items%","%webView_inventory_occurrences_table_header_reference%","%webView_inventory_occurrences_table_header_occurrence%"]),jc=(e,t,n)=>{let r=e;return t!=="all"&&(r=r.filter(o=>t==="approved"&&o.status==="approved"||t==="unapproved"&&o.status==="unapproved"||t==="unknown"&&o.status==="unknown")),n!==""&&(r=r.filter(o=>o.items[0].includes(n))),r},Cc=(e,t,n,r,o)=>{if(!e)return[];const s=[];let i=t.bookNum,l=t.chapterNum,c=t.verseNum;return Rs(e).forEach(u=>{u.startsWith("\\id")&&(i=Os(u),l=0,c=0),u.startsWith("\\c")&&(l=Hr(u),c=0),u.startsWith("\\v")&&(c=Hr(u),l===0&&(l=t.chapterNum));let f=o.exec(u)??void 0;for(;f;){const w=[];f.forEach(h=>w.push(h));const b=f.index,x=s.find(h=>W.deepEqual(h.items,w)),m={reference:{bookNum:i!==void 0?i:-1,chapterNum:l!==void 0?l:-1,verseNum:c!==void 0?c:-1},text:W.substring(u,Math.max(0,b-25),Math.min(b+25,u.length))};if(x)x.count+=1,x.occurrences.push(m);else{const h={items:w,count:1,status:_s(w[0],n,r),occurrences:[m]};s.push(h)}f=o.exec(u)??void 0}}),s},Je=(e,t)=>e[t]??t;function Tc({scriptureReference:e,setScriptureReference:t,localizedStrings:n,extractItems:r,additionalItemsLabels:o,approvedItems:s,unapprovedItems:i,text:l,scope:c,onScopeChange:d,columns:u}){const f=Je(n,"%webView_inventory_all%"),w=Je(n,"%webView_inventory_approved%"),b=Je(n,"%webView_inventory_unapproved%"),x=Je(n,"%webView_inventory_unknown%"),m=Je(n,"%webView_inventory_scope_currentBook%"),h=Je(n,"%webView_inventory_scope_chapter%"),S=Je(n,"%webView_inventory_scope_verse%"),R=Je(n,"%webView_inventory_filter_text%"),j=Je(n,"%webView_inventory_show_additional_items%"),[E,v]=g.useState(!1),[P,V]=g.useState("all"),[U,C]=g.useState(""),[_,k]=g.useState([]),D=g.useMemo(()=>l?r instanceof RegExp?Cc(l,e,s,i,r):r(l,e,s,i):[],[l,r,e,s,i]),$=g.useMemo(()=>{if(E)return D;const y=[];return D.forEach(T=>{const z=T.items[0],L=y.find(B=>B.items[0]===z);L?(L.count+=T.count,L.occurrences=L.occurrences.concat(T.occurrences)):y.push({items:[z],count:T.count,occurrences:T.occurrences,status:T.status})}),y},[E,D]),J=g.useMemo(()=>jc($,P,U),[$,P,U]),Y=g.useMemo(()=>{var z,L;if(!E)return u;const y=(z=o==null?void 0:o.tableHeaders)==null?void 0:z.length;if(!y)return u;const T=[];for(let B=0;B{k([])},[J]);const F=(y,T)=>{T.setRowSelection(()=>{const z={};return z[y.index]=!0,z}),k(y.original.items)},te=y=>{if(y==="book"||y==="chapter"||y==="verse")d(y);else throw new Error(`Invalid scope value: ${y}`)},se=y=>{if(y==="all"||y==="approved"||y==="unapproved"||y==="unknown")V(y);else throw new Error(`Invalid status filter value: ${y}`)},oe=g.useMemo(()=>{if($.length===0||_.length===0)return[];const y=$.filter(T=>W.deepEqual(E?T.items:[T.items[0]],_));if(y.length>1)throw new Error("Selected item is not unique");return y[0].occurrences},[_,E,$]);return a.jsxs("div",{className:"pr-twp tw-flex tw-h-full tw-flex-col",children:[a.jsxs("div",{className:"tw-flex tw-items-stretch",children:[a.jsxs(At,{onValueChange:y=>se(y),defaultValue:P,children:[a.jsx(bt,{className:"tw-m-1",children:a.jsx(Bt,{placeholder:"Select filter"})}),a.jsxs(vt,{children:[a.jsx(Ae,{value:"all",children:f}),a.jsx(Ae,{value:"approved",children:w}),a.jsx(Ae,{value:"unapproved",children:b}),a.jsx(Ae,{value:"unknown",children:x})]})]}),a.jsxs(At,{onValueChange:y=>te(y),defaultValue:c,children:[a.jsx(bt,{className:"tw-m-1",children:a.jsx(Bt,{placeholder:"Select scope"})}),a.jsxs(vt,{children:[a.jsx(Ae,{value:"book",children:m}),a.jsx(Ae,{value:"chapter",children:h}),a.jsx(Ae,{value:"verse",children:S})]})]}),a.jsx(St,{className:"tw-m-1 tw-rounded-md tw-border",placeholder:R,value:U,onChange:y=>{C(y.target.value)}}),o&&a.jsxs("div",{className:"tw-m-1 tw-flex tw-items-center tw-rounded-md tw-border",children:[a.jsx(sr,{className:"tw-m-1",checked:E,onCheckedChange:y=>{k([]),v(y)}}),a.jsx(qe,{className:"tw-m-1 tw-flex-shrink-0 tw-whitespace-nowrap",children:(o==null?void 0:o.checkboxText)??j})]})]}),a.jsx("div",{className:"tw-m-1 tw-flex-1 tw-overflow-auto tw-rounded-md tw-border",children:a.jsx(Ts,{columns:Y,data:J,onRowClickHandler:F,stickyHeader:!0})}),oe.length>0&&a.jsx("div",{className:"tw-m-1 tw-flex-1 tw-overflow-auto tw-rounded-md tw-border",children:a.jsx(vc,{occurrenceData:oe,setScriptureReference:t,localizedStrings:n})})]})}function ho({className:e,onSearch:t,placeholder:n,isFullWidth:r}){const[o,s]=g.useState(""),i=l=>{s(l),t(l)};return a.jsx(St,{className:N("tw-flex tw-h-10 tw-rounded-md tw-border tw-border-input tw-bg-background tw-px-3 tw-py-2 tw-text-sm tw-ring-offset-background file:tw-border-0 file:tw-bg-transparent file:tw-text-sm file:tw-font-medium placeholder:tw-text-muted-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-[color:hsl(240,5%,64.9%)] focus-visible:tw-ring-offset-2 disabled:tw-cursor-not-allowed disabled:tw-opacity-50",{"tw-w-full":r},e),placeholder:n,value:o,onChange:l=>i(l.target.value)})}const go=g.forwardRef(({className:e,...t},n)=>a.jsx(Oe.Root,{orientation:"vertical",ref:n,className:N("tw-flex tw-gap-1 tw-rounded-md tw-text-muted-foreground",e),...t}));go.displayName=Oe.List.displayName;const bo=g.forwardRef(({className:e,...t},n)=>a.jsx(Oe.List,{ref:n,className:N("tw-flex-fit tw-mlk-items-center tw-w-[124px] tw-justify-center tw-rounded-md tw-bg-muted tw-p-1 tw-text-muted-foreground",e),...t}));bo.displayName=Oe.List.displayName;const Ms=g.forwardRef(({className:e,...t},n)=>a.jsx(Oe.Trigger,{ref:n,...t,className:N("overflow-clip tw-inline-flex tw-w-[116px] tw-cursor-pointer tw-items-center tw-justify-center tw-break-words tw-rounded-sm tw-border-0 tw-bg-muted tw-px-3 tw-py-1.5 tw-text-sm tw-font-medium tw-text-inherit tw-ring-offset-background tw-transition-all hover:tw-text-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50 data-[state=active]:tw-bg-background data-[state=active]:tw-text-foreground data-[state=active]:tw-shadow-sm",e)})),vo=g.forwardRef(({className:e,...t},n)=>a.jsx(Oe.Content,{ref:n,className:N("tw-ms-5 tw-flex-grow tw-text-foreground tw-ring-offset-background focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2",e),...t}));vo.displayName=Oe.Content.displayName;function Rc({tabList:e,onSearch:t,searchPlaceholder:n,headerTitle:r,isSearchBarFullWidth:o=!1,direction:s="ltr"}){return a.jsxs("div",{className:"pr-twp",children:[a.jsxs("div",{className:"tw-sticky tw-top-0 tw-space-y-2 tw-pb-2",children:[r?a.jsx("h1",{children:r}):"",a.jsx(ho,{isFullWidth:o,onSearch:t,placeholder:n})]}),a.jsxs(go,{dir:s,children:[a.jsx(bo,{children:e.map(i=>a.jsx(Ms,{value:i.value,children:i.value},i.key))}),e.map(i=>a.jsx(vo,{value:i.value,children:i.content},i.key))]})]})}const lr=g.forwardRef(({className:e,orientation:t="horizontal",decorative:n=!0,...r},o)=>a.jsx(ns.Root,{ref:o,decorative:n,orientation:t,className:N("pr-twp tw-shrink-0 tw-bg-border",t==="horizontal"?"tw-h-[1px] tw-w-full":"tw-h-full tw-w-[1px]",e),...r}));lr.displayName=ns.Root.displayName;const Oc=be.Root,_c=be.Portal,$s=M.forwardRef(({className:e,...t},n)=>a.jsx(be.Overlay,{className:N("tw-fixed tw-inset-0 tw-z-50 tw-bg-black/80 data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0",e),...t,ref:n}));$s.displayName=be.Overlay.displayName;const Pc=Xt.cva("pr-twp tw-fixed tw-z-50 tw-gap-4 tw-bg-background tw-p-6 tw-shadow-lg tw-transition tw-ease-in-out data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-duration-300 data-[state=open]:tw-duration-500",{variants:{side:{top:"tw-inset-x-0 tw-top-0 tw-border-b data-[state=closed]:tw-slide-out-to-top data-[state=open]:tw-slide-in-from-top",bottom:"tw-inset-x-0 tw-bottom-0 tw-border-t data-[state=closed]:tw-slide-out-to-bottom data-[state=open]:tw-slide-in-from-bottom",left:"tw-inset-y-0 tw-left-0 tw-h-full tw-w-3/4 tw-border-r data-[state=closed]:tw-slide-out-to-left data-[state=open]:tw-slide-in-from-left sm:tw-max-w-sm",right:"tw-inset-y-0 tw-right-0 tw-h-full tw-w-3/4 tw- tw-border-l data-[state=closed]:tw-slide-out-to-right data-[state=open]:tw-slide-in-from-right sm:tw-max-w-sm"}},defaultVariants:{side:"right"}}),Ds=M.forwardRef(({side:e="right",className:t,children:n,...r},o)=>a.jsxs(_c,{children:[a.jsx($s,{}),a.jsxs(be.Content,{ref:o,className:N(Pc({side:e}),t),...r,children:[n,a.jsxs(be.Close,{className:"tw-absolute tw-right-4 tw-top-4 tw-rounded-sm tw-opacity-70 tw-ring-offset-background tw-transition-opacity hover:tw-opacity-100 focus:tw-outline-none focus:tw-ring-2 focus:tw-ring-ring focus:tw-ring-offset-2 disabled:tw-pointer-events-none data-[state=open]:tw-bg-secondary",children:[a.jsx(Q.X,{className:"tw-h-4 tw-w-4"}),a.jsx("span",{className:"tw-sr-only",children:"Close"})]})]})]}));Ds.displayName=be.Content.displayName;const Ic=M.forwardRef(({className:e,...t},n)=>a.jsx(be.Title,{ref:n,className:N("tw-text-lg tw-font-semibold tw-text-foreground",e),...t}));Ic.displayName=be.Title.displayName;const Mc=M.forwardRef(({className:e,...t},n)=>a.jsx(be.Description,{ref:n,className:N("tw-text-sm tw-text-muted-foreground",e),...t}));Mc.displayName=be.Description.displayName;function sa({className:e,...t}){return a.jsx("div",{className:N("pr-twp tw-animate-pulse tw-rounded-md tw-bg-muted",e),...t})}const $c=Sn.Provider,Dc=Sn.Root,Ac=Sn.Trigger,As=g.forwardRef(({className:e,sideOffset:t=4,...n},r)=>a.jsx(Sn.Content,{ref:r,sideOffset:t,className:N("pr-twp tw-z-50 tw-overflow-hidden tw-rounded-md tw-border tw-bg-popover tw-px-3 tw-py-1.5 tw-text-sm tw-text-popover-foreground tw-shadow-md tw-animate-in tw-fade-in-0 tw-zoom-in-95 data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=closed]:tw-zoom-out-95 data-[side=bottom]:tw-slide-in-from-top-2 data-[side=left]:tw-slide-in-from-right-2 data-[side=right]:tw-slide-in-from-left-2 data-[side=top]:tw-slide-in-from-bottom-2",e),...n}));As.displayName=Sn.Content.displayName;const Or=768;function Bc(){const[e,t]=g.useState(void 0);return g.useEffect(()=>{const n=window.matchMedia(`(max-width: ${Or-1}px)`),r=()=>{t(window.innerWidthn.removeEventListener("change",r)},[]),!!e}const Vc="sidebar:state",zc=60*60*24*7,Lc="16rem",Fc="18rem",Gc="3rem",Uc="b",Bs=g.createContext(void 0);function cr(){const e=g.useContext(Bs);if(!e)throw new Error("useSidebar must be used within a SidebarProvider.");return e}const Vs=g.forwardRef(({defaultOpen:e=!0,open:t,onOpenChange:n,className:r,style:o,children:s,...i},l)=>{const c=Bc(),[d,u]=g.useState(!1),[f,w]=g.useState(e),b=t??f,x=g.useCallback(R=>{const j=typeof R=="function"?R(b):R;n?n(j):w(j),document.cookie=`${Vc}=${j}; path=/; max-age=${zc}`},[n,b]),m=g.useCallback(()=>c?u(R=>!R):x(R=>!R),[c,x,u]);g.useEffect(()=>{const R=j=>{j.key===Uc&&(j.metaKey||j.ctrlKey)&&(j.preventDefault(),m())};return window.addEventListener("keydown",R),()=>window.removeEventListener("keydown",R)},[m]);const h=b?"expanded":"collapsed",S=g.useMemo(()=>({state:h,open:b,setOpen:x,isMobile:c,openMobile:d,setOpenMobile:u,toggleSidebar:m}),[h,b,x,c,d,u,m]);return a.jsx(Bs.Provider,{value:S,children:a.jsx($c,{delayDuration:0,children:a.jsx("div",{style:{"--sidebar-width":Lc,"--sidebar-width-icon":Gc,...o},className:N("tw-group/sidebar-wrapper pr-twp tw-flex tw-w-full has-[[data-variant=inset]]:tw-bg-sidebar",r),ref:l,...i,children:s})})})});Vs.displayName="SidebarProvider";const zs=g.forwardRef(({side:e="left",variant:t="sidebar",collapsible:n="offcanvas",className:r,children:o,...s},i)=>{const{isMobile:l,state:c,openMobile:d,setOpenMobile:u}=cr();return n==="none"?a.jsx("div",{className:N("tw-flex tw-h-full tw-w-[--sidebar-width] tw-flex-col tw-bg-sidebar tw-text-sidebar-foreground",r),ref:i,...s,children:o}):l?a.jsx(Oc,{open:d,onOpenChange:u,...s,children:a.jsx(Ds,{"data-sidebar":"sidebar","data-mobile":"true",className:"tw-w-[--sidebar-width] tw-bg-sidebar tw-p-0 tw-text-sidebar-foreground [&>button]:tw-hidden",style:{"--sidebar-width":Fc},side:e,children:a.jsx("div",{className:"tw-flex tw-h-full tw-w-full tw-flex-col",children:o})})}):a.jsxs("div",{ref:i,className:"tw-group tw-peer tw-hidden tw-text-sidebar-foreground md:tw-block","data-state":c,"data-collapsible":c==="collapsed"?n:"","data-variant":t,"data-side":e,children:[a.jsx("div",{className:N("tw-relative tw-h-svh tw-w-[--sidebar-width] tw-bg-transparent tw-transition-[width] tw-duration-200 tw-ease-linear","group-data-[collapsible=offcanvas]:tw-w-0","group-data-[side=right]:tw-rotate-180",t==="floating"||t==="inset"?"group-data-[collapsible=icon]:tw-w-[calc(var(--sidebar-width-icon)_+_theme(spacing.4))]":"group-data-[collapsible=icon]:tw-w-[--sidebar-width-icon]")}),a.jsx("div",{className:N("tw-absolute tw-inset-y-0 tw-z-10 tw-hidden tw-h-svh tw-w-[--sidebar-width] tw-transition-[left,right,width] tw-duration-200 tw-ease-linear md:tw-flex",e==="left"?"tw-left-0 group-data-[collapsible=offcanvas]:tw-left-[calc(var(--sidebar-width)*-1)]":"tw-right-0 group-data-[collapsible=offcanvas]:tw-right-[calc(var(--sidebar-width)*-1)]",t==="floating"||t==="inset"?"tw-p-2 group-data-[collapsible=icon]:tw-w-[calc(var(--sidebar-width-icon)_+_theme(spacing.4)_+2px)]":"group-data-[collapsible=icon]:tw-w-[--sidebar-width-icon] group-data-[side=left]:tw-border-r group-data-[side=right]:tw-border-l",r),...s,children:a.jsx("div",{"data-sidebar":"sidebar",className:"tw-flex tw-h-full tw-w-full tw-flex-col tw-bg-sidebar group-data-[variant=floating]:tw-rounded-lg group-data-[variant=floating]:tw-border group-data-[variant=floating]:tw-border-sidebar-border group-data-[variant=floating]:tw-shadow",children:o})})]})});zs.displayName="Sidebar";const qc=g.forwardRef(({className:e,onClick:t,...n},r)=>{const{toggleSidebar:o}=cr();return a.jsxs(fe,{ref:r,"data-sidebar":"trigger",variant:"ghost",size:"icon",className:N("tw-h-7 tw-w-7",e),onClick:s=>{t==null||t(s),o()},...n,children:[a.jsx(Q.PanelLeft,{}),a.jsx("span",{className:"tw-sr-only",children:"Toggle Sidebar"})]})});qc.displayName="SidebarTrigger";const Hc=g.forwardRef(({className:e,...t},n)=>{const{toggleSidebar:r}=cr();return a.jsx("button",{type:"button",ref:n,"data-sidebar":"rail","aria-label":"Toggle Sidebar",tabIndex:-1,onClick:r,title:"Toggle Sidebar",className:N("tw-absolute tw-inset-y-0 tw-z-20 tw-hidden tw-w-4 tw--translate-x-1/2 tw-transition-all tw-ease-linear after:tw-absolute after:tw-inset-y-0 after:tw-left-1/2 after:tw-w-[2px] hover:after:tw-bg-sidebar-border group-data-[side=left]:tw--right-4 group-data-[side=right]:tw-left-0 sm:tw-flex","[[data-side=left]_&]:tw-cursor-w-resize [[data-side=right]_&]:tw-cursor-e-resize","[[data-side=left][data-state=collapsed]_&]:tw-cursor-e-resize [[data-side=right][data-state=collapsed]_&]:tw-cursor-w-resize","group-data-[collapsible=offcanvas]:tw-translate-x-0 group-data-[collapsible=offcanvas]:after:tw-left-full group-data-[collapsible=offcanvas]:hover:tw-bg-sidebar","[[data-side=left][data-collapsible=offcanvas]_&]:tw--right-2","[[data-side=right][data-collapsible=offcanvas]_&]:tw--left-2",e),...t})});Hc.displayName="SidebarRail";const Ls=g.forwardRef(({className:e,...t},n)=>a.jsx("main",{ref:n,className:N("tw-relative tw-flex tw-flex-1 tw-flex-col tw-bg-background","peer-data-[variant=inset]:tw-min-h-[calc(100svh-theme(spacing.4))] md:peer-data-[variant=inset]:tw-m-2 md:peer-data-[state=collapsed]:peer-data-[variant=inset]:tw-ml-2 md:peer-data-[variant=inset]:tw-ml-0 md:peer-data-[variant=inset]:tw-rounded-xl md:peer-data-[variant=inset]:tw-shadow",e),...t}));Ls.displayName="SidebarInset";const Xc=g.forwardRef(({className:e,...t},n)=>a.jsx(St,{ref:n,"data-sidebar":"input",className:N("tw-h-8 tw-w-full tw-bg-background tw-shadow-none focus-visible:tw-ring-2 focus-visible:tw-ring-sidebar-ring",e),...t}));Xc.displayName="SidebarInput";const Yc=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,"data-sidebar":"header",className:N("tw-flex tw-flex-col tw-gap-2 tw-p-2",e),...t}));Yc.displayName="SidebarHeader";const Wc=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,"data-sidebar":"footer",className:N("tw-flex tw-flex-col tw-gap-2 tw-p-2",e),...t}));Wc.displayName="SidebarFooter";const Kc=g.forwardRef(({className:e,...t},n)=>a.jsx(lr,{ref:n,"data-sidebar":"separator",className:N("tw-mx-2 tw-w-auto tw-bg-sidebar-border",e),...t}));Kc.displayName="SidebarSeparator";const Fs=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,"data-sidebar":"content",className:N("tw-flex tw-min-h-0 tw-flex-1 tw-flex-col tw-gap-2 tw-overflow-auto group-data-[collapsible=icon]:tw-overflow-hidden",e),...t}));Fs.displayName="SidebarContent";const Xr=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,"data-sidebar":"group",className:N("tw-relative tw-flex tw-w-full tw-min-w-0 tw-flex-col tw-p-2",e),...t}));Xr.displayName="SidebarGroup";const Yr=g.forwardRef(({className:e,asChild:t=!1,...n},r)=>{const o=t?Ht.Slot:"div";return a.jsx(o,{ref:r,"data-sidebar":"group-label",className:N("tw-flex tw-h-8 tw-shrink-0 tw-items-center tw-rounded-md tw-px-2 tw-text-xs tw-font-medium tw-text-sidebar-foreground/70 tw-outline-none tw-ring-sidebar-ring tw-transition-[margin,opa] tw-duration-200 tw-ease-linear focus-visible:tw-ring-2 [&>svg]:tw-size-4 [&>svg]:tw-shrink-0","group-data-[collapsible=icon]:tw--mt-8 group-data-[collapsible=icon]:tw-opacity-0",e),...n})});Yr.displayName="SidebarGroupLabel";const Jc=g.forwardRef(({className:e,asChild:t=!1,...n},r)=>{const o=t?Ht.Slot:"button";return a.jsx(o,{ref:r,"data-sidebar":"group-action",className:N("tw-absolute tw-right-3 tw-top-3.5 tw-flex tw-aspect-square tw-w-5 tw-items-center tw-justify-center tw-rounded-md tw-p-0 tw-text-sidebar-foreground tw-outline-none tw-ring-sidebar-ring tw-transition-transform hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground focus-visible:tw-ring-2 [&>svg]:tw-size-4 [&>svg]:tw-shrink-0","after:tw-absolute after:tw--inset-2 after:md:tw-hidden","group-data-[collapsible=icon]:tw-hidden",e),...n})});Jc.displayName="SidebarGroupAction";const Wr=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,"data-sidebar":"group-content",className:N("tw-w-full tw-text-sm",e),...t}));Wr.displayName="SidebarGroupContent";const Gs=g.forwardRef(({className:e,...t},n)=>a.jsx("ul",{ref:n,"data-sidebar":"menu",className:N("tw-flex tw-w-full tw-min-w-0 tw-flex-col tw-gap-1",e),...t}));Gs.displayName="SidebarMenu";const Us=g.forwardRef(({className:e,...t},n)=>a.jsx("li",{ref:n,"data-sidebar":"menu-item",className:N("tw-group/menu-item tw-relative",e),...t}));Us.displayName="SidebarMenuItem";const Zc=Xt.cva("tw-peer/menu-button tw-flex tw-w-full tw-items-center tw-gap-2 tw-overflow-hidden tw-rounded-md tw-p-2 tw-text-left tw-text-sm tw-outline-none tw-ring-sidebar-ring tw-transition-[width,height,padding] hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground focus-visible:tw-ring-2 active:tw-bg-sidebar-accent active:tw-text-sidebar-accent-foreground disabled:tw-pointer-events-none disabled:tw-opacity-50 tw-group-has-[[data-sidebar=menu-action]]/menu-item:pr-8 aria-disabled:tw-pointer-events-none aria-disabled:tw-opacity-50 data-[active=true]:tw-font-medium data-[active=true]:tw-text-sidebar-accent-foreground data-[state=open]:hover:tw-bg-sidebar-accent data-[state=open]:hover:tw-text-sidebar-accent-foreground group-data-[collapsible=icon]:tw-!size-8 group-data-[collapsible=icon]:tw-!p-2 [&>span:last-child]:tw-truncate [&>svg]:tw-size-4 [&>svg]:tw-shrink-0",{variants:{variant:{default:"hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground",outline:"tw-bg-background tw-shadow-[0_0_0_1px_hsl(var(--sidebar-border))] hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground hover:tw-shadow-[0_0_0_1px_hsl(var(--sidebar-accent))]"},size:{default:"tw-h-8 tw-text-sm",sm:"tw-h-7 tw-text-xs",lg:"tw-h-12 tw-text-sm group-data-[collapsible=icon]:tw-!p-0"}},defaultVariants:{variant:"default",size:"default"}}),qs=g.forwardRef(({asChild:e=!1,isActive:t=!1,variant:n="default",size:r="default",tooltip:o,className:s,...i},l)=>{const c=e?Ht.Slot:"button",{isMobile:d,state:u}=cr(),f=a.jsx(c,{ref:l,"data-sidebar":"menu-button","data-size":r,"data-active":t,className:N(Zc({variant:n,size:r}),s),...i});return o?(typeof o=="string"&&(o={children:o}),a.jsxs(Dc,{children:[a.jsx(Ac,{asChild:!0,children:f}),a.jsx(As,{side:"right",align:"center",hidden:u!=="collapsed"||d,...o})]})):f});qs.displayName="SidebarMenuButton";const Qc=g.forwardRef(({className:e,asChild:t=!1,showOnHover:n=!1,...r},o)=>{const s=t?Ht.Slot:"button";return a.jsx(s,{ref:o,"data-sidebar":"menu-action",className:N("tw-peer-hover/menu-button:text-sidebar-accent-foreground tw-absolute tw-right-1 tw-top-1.5 tw-flex tw-aspect-square tw-w-5 tw-items-center tw-justify-center tw-rounded-md tw-p-0 tw-text-sidebar-foreground tw-outline-none tw-ring-sidebar-ring tw-transition-transform hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground focus-visible:tw-ring-2 [&>svg]:tw-size-4 [&>svg]:tw-shrink-0","after:tw-absolute after:tw--inset-2 after:md:tw-hidden","tw-peer-data-[size=sm]/menu-button:top-1","tw-peer-data-[size=default]/menu-button:top-1.5","tw-peer-data-[size=lg]/menu-button:top-2.5","group-data-[collapsible=icon]:tw-hidden",n&&"tw-group-focus-within/menu-item:opacity-100 tw-group-hover/menu-item:opacity-100 tw-peer-data-[active=true]/menu-button:text-sidebar-accent-foreground data-[state=open]:tw-opacity-100 md:tw-opacity-0",e),...r})});Qc.displayName="SidebarMenuAction";const ed=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,"data-sidebar":"menu-badge",className:N("tw-pointer-events-none tw-absolute tw-right-1 tw-flex tw-h-5 tw-min-w-5 tw-select-none tw-items-center tw-justify-center tw-rounded-md tw-px-1 tw-text-xs tw-font-medium tw-tabular-nums tw-text-sidebar-foreground","tw-peer-hover/menu-button:text-sidebar-accent-foreground tw-peer-data-[active=true]/menu-button:text-sidebar-accent-foreground","tw-peer-data-[size=sm]/menu-button:top-1","tw-peer-data-[size=default]/menu-button:top-1.5","tw-peer-data-[size=lg]/menu-button:top-2.5","group-data-[collapsible=icon]:tw-hidden",e),...t}));ed.displayName="SidebarMenuBadge";const td=g.forwardRef(({className:e,showIcon:t=!1,...n},r)=>{const o=g.useMemo(()=>`${Math.floor(Math.random()*40)+50}%`,[]);return a.jsxs("div",{ref:r,"data-sidebar":"menu-skeleton",className:N("tw-flex tw-h-8 tw-items-center tw-gap-2 tw-rounded-md tw-px-2",e),...n,children:[t&&a.jsx(sa,{className:"tw-size-4 tw-rounded-md","data-sidebar":"menu-skeleton-icon"}),a.jsx(sa,{className:"tw-h-4 tw-max-w-[--skeleton-width] tw-flex-1","data-sidebar":"menu-skeleton-text",style:{"--skeleton-width":o}})]})});td.displayName="SidebarMenuSkeleton";const nd=g.forwardRef(({className:e,...t},n)=>a.jsx("ul",{ref:n,"data-sidebar":"menu-sub",className:N("tw-mx-3.5 tw-flex tw-min-w-0 tw-translate-x-px tw-flex-col tw-gap-1 tw-border-l tw-border-sidebar-border tw-px-2.5 tw-py-0.5","group-data-[collapsible=icon]:tw-hidden",e),...t}));nd.displayName="SidebarMenuSub";const rd=g.forwardRef(({...e},t)=>a.jsx("li",{ref:t,...e}));rd.displayName="SidebarMenuSubItem";const od=g.forwardRef(({asChild:e=!1,size:t="md",isActive:n,className:r,...o},s)=>{const i=e?Ht.Slot:"a";return a.jsx(i,{ref:s,"data-sidebar":"menu-sub-button","data-size":t,"data-active":n,className:N("tw-flex tw-h-7 tw-min-w-0 tw--translate-x-px tw-items-center tw-gap-2 tw-overflow-hidden tw-rounded-md tw-px-2 tw-text-sidebar-foreground tw-outline-none tw-ring-sidebar-ring hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground focus-visible:tw-ring-2 active:tw-bg-sidebar-accent active:tw-text-sidebar-accent-foreground disabled:tw-pointer-events-none disabled:tw-opacity-50 aria-disabled:tw-pointer-events-none aria-disabled:tw-opacity-50 [&>span:last-child]:tw-truncate [&>svg]:tw-size-4 [&>svg]:tw-shrink-0 [&>svg]:tw-text-sidebar-accent-foreground","data-[active=true]:tw-bg-sidebar-accent data-[active=true]:tw-text-sidebar-accent-foreground",t==="sm"&&"tw-text-xs",t==="md"&&"tw-text-sm","group-data-[collapsible=icon]:tw-hidden",r),...o})});od.displayName="SidebarMenuSubButton";function Hs({id:e,extensionLabels:t,projectOptions:n,handleSelectSidebarItem:r,selectedSidebarItem:o,extensionsSidebarGroupLabel:s,projectsSidebarGroupLabel:i,buttonPlaceholderText:l}){const c=g.useCallback((f,w)=>{r(f,w)},[r]),d=g.useCallback(f=>{const w=n.find(b=>b.projectId===f);return w?w.projectName:f},[n]),u=g.useCallback(f=>!o.projectId&&f===o.label,[o]);return a.jsx(zs,{id:e,collapsible:"none",variant:"inset",className:"tw-w-96 tw-gap-2 tw-overflow-y-auto tw-rounded tw-bg-slate-100",children:a.jsxs(Fs,{children:[a.jsxs(Xr,{children:[a.jsx(Yr,{className:"tw-text-sm tw-text-gray-400",children:s}),a.jsx(Wr,{children:a.jsx(Gs,{children:t.map(f=>a.jsx(Us,{children:a.jsx(qs,{className:N("tw-rounded tw-py-2 tw-text-sm tw-text-gray-500 hover:tw-bg-white hover:tw-text-gray-900 hover:tw-shadow-sm active:tw-bg-white",{"tw-bg-white tw-text-gray-900 tw-shadow-sm":u(f)}),onClick:()=>c(f),isActive:u(f),children:a.jsx("span",{className:"tw-pl-3",children:f})})},f))})})]}),a.jsxs(Xr,{children:[a.jsx(Yr,{className:"tw-text-sm tw-text-gray-400",children:i}),a.jsx(Wr,{className:"tw-pl-3",children:a.jsx(Wn,{popoverContentClassName:"tw-z-[1000]",options:n.flatMap(f=>f.projectId),getOptionLabel:f=>d(f),buttonPlaceholder:l,onChange:f=>{const w=d(f);c(w,f)},value:(o==null?void 0:o.projectId)??void 0})})]})]})})}function ad({id:e,extensionLabels:t,projectOptions:n,children:r,handleSelectSidebarItem:o,selectedSidebarItem:s,onSearch:i,extensionsSidebarGroupLabel:l,projectsSidebarGroupLabel:c,buttonPlaceholderText:d}){return a.jsxs("div",{className:"tw-box-border tw-flex tw-h-full tw-flex-col tw-p-3",children:[a.jsx("div",{className:"tw-box-border tw-flex tw-items-center tw-justify-center tw-py-4",children:a.jsx(ho,{className:"tw-w-9/12",onSearch:i,placeholder:"Search app settings, extension settings, and project settings"})}),a.jsxs(Vs,{id:e,className:"tw-h-full tw-flex-1 tw-gap-4 tw-overflow-auto",children:[a.jsx(Hs,{extensionLabels:t,projectOptions:n,handleSelectSidebarItem:o,selectedSidebarItem:s,extensionsSidebarGroupLabel:l,projectsSidebarGroupLabel:c,buttonPlaceholderText:d}),a.jsx(Ls,{className:"tw-overflow-y-auto",children:r})]})]})}const rt="scrBook",sd="scrRef",pt="source",id="details",ld="Scripture Reference",cd="Scripture Book",Xs="Type",dd="Details";function ud(e,t){const n=t??!1;return[{accessorFn:r=>`${ae.bookNumberToId(r.start.bookNum)} ${r.start.chapterNum}:${r.start.verseNum}`,id:rt,header:(e==null?void 0:e.scriptureReferenceColumnName)??ld,cell:r=>{const o=r.row.original;return r.row.getIsGrouped()?ae.bookNumberToEnglishName(o.start.bookNum):r.row.groupingColumnId===rt?W.formatScrRef(o.start):void 0},getGroupingValue:r=>r.start.bookNum,sortingFn:(r,o)=>W.compareScrRefs(r.original.start,o.original.start),enableGrouping:!0},{accessorFn:r=>W.formatScrRef(r.start),id:sd,header:void 0,cell:r=>{const o=r.row.original;return r.row.getIsGrouped()?void 0:W.formatScrRef(o.start)},sortingFn:(r,o)=>W.compareScrRefs(r.original.start,o.original.start),enableGrouping:!1},{accessorFn:r=>r.source.displayName,id:pt,header:n?(e==null?void 0:e.typeColumnName)??Xs:void 0,cell:r=>n||r.row.getIsGrouped()?r.getValue():void 0,getGroupingValue:r=>r.source.id,sortingFn:(r,o)=>r.original.source.displayName.localeCompare(o.original.source.displayName),enableGrouping:!0},{accessorFn:r=>r.detail,id,header:(e==null?void 0:e.detailsColumnName)??dd,cell:r=>r.getValue(),enableGrouping:!1}]}const pd=e=>{if(!("offset"in e.start))throw new Error("No offset available in range start");if(e.end&&!("offset"in e.end))throw new Error("No offset available in range end");const{offset:t}=e.start;let n=0;return e.end&&({offset:n}=e.end),!e.end||W.compareScrRefs(e.start,e.end)===0?`${W.scrRefToBBBCCCVVV(e.start)}+${t}`:`${W.scrRefToBBBCCCVVV(e.start)}+${t}-${W.scrRefToBBBCCCVVV(e.end)}+${n}`},ia=e=>`${pd({start:e.start,end:e.end})} ${e.source.displayName} ${e.detail}`;function wd({sources:e,showColumnHeaders:t=!1,showSourceColumn:n=!1,scriptureReferenceColumnName:r,scriptureBookGroupName:o,typeColumnName:s,detailsColumnName:i,onRowSelected:l,direction:c="ltr"}){const[d,u]=g.useState([]),[f,w]=g.useState([{id:rt,desc:!1}]),[b,x]=g.useState({}),m=g.useMemo(()=>e.flatMap(C=>C.data.map(_=>({..._,source:C.source}))),[e]),h=g.useMemo(()=>ud({scriptureReferenceColumnName:r,typeColumnName:s,detailsColumnName:i},n),[r,s,i,n]);g.useEffect(()=>{d.includes(pt)?w([{id:pt,desc:!1},{id:rt,desc:!1}]):w([{id:rt,desc:!1}])},[d]);const S=Se.useReactTable({data:m,columns:h,state:{grouping:d,sorting:f,rowSelection:b},onGroupingChange:u,onSortingChange:w,onRowSelectionChange:x,getExpandedRowModel:Se.getExpandedRowModel(),getGroupedRowModel:Se.getGroupedRowModel(),getCoreRowModel:Se.getCoreRowModel(),getSortedRowModel:Se.getSortedRowModel(),getRowId:ia,autoResetExpanded:!1,enableMultiRowSelection:!1,enableSubRowSelection:!1});g.useEffect(()=>{if(l){const C=S.getSelectedRowModel().rowsById,_=Object.keys(C);if(_.length===1){const k=m.find(D=>ia(D)===_[0])||void 0;k&&l(k)}}},[b,m,l,S]);const R=o??cd,j=s??Xs,E=[{label:"No Grouping",value:[]},{label:`Group by ${R}`,value:[rt]},{label:`Group by ${j}`,value:[pt]},{label:`Group by ${R} and ${j}`,value:[rt,pt]},{label:`Group by ${j} and ${R}`,value:[pt,rt]}],v=C=>{u(JSON.parse(C))},P=(C,_)=>{!C.getIsGrouped()&&!C.getIsSelected()&&C.getToggleSelectedHandler()(_)},V=(C,_)=>C.getIsGrouped()?"":N("banded-row",_%2===0?"even":"odd"),U=(C,_,k)=>{if(!((C==null?void 0:C.length)===0||_.depth{v(C)},children:[a.jsx(bt,{className:"tw-mb-1 tw-mt-2",children:a.jsx(Bt,{})}),a.jsx(vt,{position:"item-aligned",children:a.jsx(ks,{children:E.map(C=>a.jsx(Ae,{value:JSON.stringify(C.value),children:C.label},C.label))})})]}),a.jsxs(Cn,{className:"tw-relative tw-flex tw-flex-col tw-overflow-y-auto tw-p-0",children:[t&&a.jsx(Tn,{children:S.getHeaderGroups().map(C=>a.jsx(Ze,{children:C.headers.filter(_=>_.column.columnDef.header).map(_=>a.jsx(Vt,{colSpan:_.colSpan,className:"top-0 tw-sticky",children:_.isPlaceholder?void 0:a.jsxs("div",{children:[_.column.getCanGroup()?a.jsx(fe,{variant:"ghost",title:`Toggle grouping by ${_.column.columnDef.header}`,onClick:_.column.getToggleGroupingHandler(),type:"button",children:_.column.getIsGrouped()?"🛑":"👊 "}):void 0," ",Se.flexRender(_.column.columnDef.header,_.getContext())]})},_.id))},C.id))}),a.jsx(Rn,{children:S.getRowModel().rows.map((C,_)=>a.jsx(Ze,{"data-state":C.getIsSelected()?"selected":"",className:N(V(C,_)),onClick:k=>P(C,k),children:C.getVisibleCells().map(k=>{if(!(k.getIsPlaceholder()||k.column.columnDef.enableGrouping&&!k.getIsGrouped()&&(k.column.columnDef.id!==pt||!n)))return a.jsx(xt,{className:N(k.column.columnDef.id,"tw-p-[1px]",U(d,C,k)),children:(()=>k.getIsGrouped()?a.jsxs(fe,{variant:"link",onClick:C.getToggleExpandedHandler(),type:"button",children:[C.getIsExpanded()&&a.jsx(Q.ChevronDown,{}),!C.getIsExpanded()&&(c==="ltr"?a.jsx(Q.ChevronRight,{}):a.jsx(Q.ChevronLeft,{}))," ",Se.flexRender(k.column.columnDef.cell,k.getContext())," (",C.subRows.length,")"]}):Se.flexRender(k.column.columnDef.cell,k.getContext()))()},k.id)})},C.id))})]})]})}const _r={[W.getLocalizeKeyForScrollGroupId("undefined")]:"Ø",[W.getLocalizeKeyForScrollGroupId(0)]:"A",[W.getLocalizeKeyForScrollGroupId(1)]:"B",[W.getLocalizeKeyForScrollGroupId(2)]:"C",[W.getLocalizeKeyForScrollGroupId(3)]:"D",[W.getLocalizeKeyForScrollGroupId(4)]:"E",[W.getLocalizeKeyForScrollGroupId(5)]:"F",[W.getLocalizeKeyForScrollGroupId(6)]:"G",[W.getLocalizeKeyForScrollGroupId(7)]:"H",[W.getLocalizeKeyForScrollGroupId(8)]:"I",[W.getLocalizeKeyForScrollGroupId(9)]:"J",[W.getLocalizeKeyForScrollGroupId(10)]:"K",[W.getLocalizeKeyForScrollGroupId(11)]:"L",[W.getLocalizeKeyForScrollGroupId(12)]:"M",[W.getLocalizeKeyForScrollGroupId(13)]:"N",[W.getLocalizeKeyForScrollGroupId(14)]:"O",[W.getLocalizeKeyForScrollGroupId(15)]:"P",[W.getLocalizeKeyForScrollGroupId(16)]:"Q",[W.getLocalizeKeyForScrollGroupId(17)]:"R",[W.getLocalizeKeyForScrollGroupId(18)]:"S",[W.getLocalizeKeyForScrollGroupId(19)]:"T",[W.getLocalizeKeyForScrollGroupId(20)]:"U",[W.getLocalizeKeyForScrollGroupId(21)]:"V",[W.getLocalizeKeyForScrollGroupId(22)]:"W",[W.getLocalizeKeyForScrollGroupId(23)]:"X",[W.getLocalizeKeyForScrollGroupId(24)]:"Y",[W.getLocalizeKeyForScrollGroupId(25)]:"Z"};function fd({availableScrollGroupIds:e,scrollGroupId:t,onChangeScrollGroupId:n,localizedStrings:r={}}){const o={..._r,...Object.fromEntries(Object.entries(r).map(([s,i])=>[s,s===i&&s in _r?_r[s]:i]))};return a.jsxs(At,{value:`${t}`,onValueChange:s=>n(s==="undefined"?void 0:parseInt(s,10)),children:[a.jsx(bt,{className:"pr-twp tw-w-auto",children:a.jsx(Bt,{placeholder:o[W.getLocalizeKeyForScrollGroupId(t)]??t})}),a.jsx(vt,{style:{zIndex:250},children:e.map(s=>a.jsx(Ae,{value:`${s}`,children:o[W.getLocalizeKeyForScrollGroupId(s)]},`${s}`))})]})}function md({children:e}){return a.jsx("div",{className:"pr-twp tw-grid",children:e})}function hd({primary:e,secondary:t,children:n,isLoading:r=!1,loadingMessage:o}){return a.jsxs("div",{className:"tw-flex tw-items-center tw-justify-between tw-space-x-4 tw-py-2",children:[a.jsxs("div",{children:[a.jsx("p",{className:"tw-text-sm tw-font-medium tw-leading-none",children:e}),a.jsx("p",{className:"tw-whitespace-normal tw-break-words tw-text-sm tw-text-muted-foreground",children:t})]}),r?a.jsx("p",{className:"tw-text-sm tw-text-muted-foreground",children:o}):a.jsx("div",{children:n})]})}function gd({primary:e,secondary:t,includeSeparator:n=!1}){return a.jsxs("div",{className:"tw-space-y-4 tw-py-2",children:[a.jsxs("div",{children:[a.jsx("h3",{className:"tw-text-lg tw-font-medium",children:e}),a.jsx("p",{className:"tw-text-sm tw-text-muted-foreground",children:t})]}),n?a.jsx(lr,{}):""]})}function bd({id:e,className:t,listItems:n,selectedListItems:r,handleSelectListItem:o,createLabel:s}){return a.jsx("div",{id:e,className:t,children:n.map(i=>a.jsxs("div",{className:"tw-m-2 tw-flex tw-items-center",children:[a.jsx(sr,{className:"tw-mr-2 tw-align-middle",checked:r.includes(i),onCheckedChange:l=>o(i,l)}),a.jsx(qe,{children:s?s(i):i})]},i))})}function vd(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}function xd(e){if(e.__esModule)return e;var t=e.default;if(typeof t=="function"){var n=function r(){return this instanceof r?Reflect.construct(t,arguments,this.constructor):t.apply(this,arguments)};n.prototype=t.prototype}else n={};return Object.defineProperty(n,"__esModule",{value:!0}),Object.keys(e).forEach(function(r){var o=Object.getOwnPropertyDescriptor(e,r);Object.defineProperty(n,r,o.get?o:{enumerable:!0,get:function(){return e[r]}})}),n}var xo={},Ys={exports:{}};(function(e){function t(n){return n&&n.__esModule?n:{default:n}}e.exports=t,e.exports.__esModule=!0,e.exports.default=e.exports})(Ys);var yd=Ys.exports,Pr={};function yo(e,t){return process.env.NODE_ENV==="production"?()=>null:function(...r){return e(...r)||t(...r)}}function O(){return O=Object.assign?Object.assign.bind():function(e){for(var t=1;t{t[n]=Ws(e[n])}),t}function Qe(e,t,n={clone:!0}){const r=n.clone?O({},e):e;return mt(e)&&mt(t)&&Object.keys(t).forEach(o=>{o!=="__proto__"&&(mt(t[o])&&o in e&&mt(e[o])?r[o]=Qe(e[o],t[o],n):n.clone?r[o]=mt(t[o])?Ws(t[o]):t[o]:r[o]=t[o])}),r}var Kr={exports:{}},zn={exports:{}},ie={};/** @license React v16.13.1 * react-is.production.min.js * * Copyright (c) Facebook, Inc. and its affiliates. @@ -3593,39 +3593,28 @@ video:where(.pr-twp,.pr-twp *) { .banded-row[data-state='selected']:hover { cursor: default; } -.papi-multi-column-menu { - background-color: rgb(222, 222, 222); - display: flex; - flex-direction: column; - padding-left: 3px; - padding-right: 3px; -} - -.papi-menu-column { - font-size: 11pt; - font-weight: 600; - padding-bottom: 2px; +.papi-menu-item { + background-color: transparent; } -.papi-menu-column ul { - padding-top: 0; +.papi-menu-icon-trailing { + margin-left: 10px; + place-content: flex-end; } -.papi-menu-column-header { - background-color: rgb(181, 181, 181); - padding-left: 24px; - margin-top: 0; - margin-bottom: 0; +.papi-menu-item img { + max-width: 24px; + max-height: 24px; } - -.papi-multi-column-menu.paratext { - background-color: rgb(76, 106, 76); - color: rgb(214, 255, 152); +.papi-menu-drawer-paper { + height: fit-content !important; + position: absolute !important; } -.papi-multi-column-menu.paratext.bright { - color: rgb(76, 106, 76); - background-color: rgb(214, 255, 152); +.papi-toolbar-children { + padding: 10px; + display: flex; + gap: 8px; } .papi-icon-button { border: 0; @@ -3653,28 +3642,39 @@ video:where(.pr-twp,.pr-twp *) { background-color: greenyellow; color: darkgreen; } -.papi-menu-item { - background-color: transparent; +.papi-multi-column-menu { + background-color: rgb(222, 222, 222); + display: flex; + flex-direction: column; + padding-left: 3px; + padding-right: 3px; } -.papi-menu-icon-trailing { - margin-left: 10px; - place-content: flex-end; +.papi-menu-column { + font-size: 11pt; + font-weight: 600; + padding-bottom: 2px; } -.papi-menu-item img { - max-width: 24px; - max-height: 24px; +.papi-menu-column ul { + padding-top: 0; } -.papi-menu-drawer-paper { - height: fit-content !important; - position: absolute !important; + +.papi-menu-column-header { + background-color: rgb(181, 181, 181); + padding-left: 24px; + margin-top: 0; + margin-bottom: 0; } -.papi-toolbar-children { - padding: 10px; - display: flex; - gap: 8px; +.papi-multi-column-menu.paratext { + background-color: rgb(76, 106, 76); + color: rgb(214, 255, 152); +} + +.papi-multi-column-menu.paratext.bright { + color: rgb(76, 106, 76); + background-color: rgb(214, 255, 152); } `,"top"); //# sourceMappingURL=index.cjs.map diff --git a/lib/platform-bible-react/dist/index.cjs.map b/lib/platform-bible-react/dist/index.cjs.map index 7842c2b8ae..43c0128dfb 100644 --- a/lib/platform-bible-react/dist/index.cjs.map +++ b/lib/platform-bible-react/dist/index.cjs.map @@ -1 +1 @@ -{"version":3,"file":"index.cjs","sources":["../src/utils/shadcn-ui.util.ts","../src/components/shadcn-ui/input.tsx","../src/components/advanced/book-chapter-control/book-chapter-input.component.tsx","../../../node_modules/@sillsdev/scripture/dist/index.es.js","../src/components/shadcn-ui/dropdown-menu.tsx","../src/components/advanced/book-chapter-control/book-menu-item.component.tsx","../src/components/advanced/book-chapter-control/chapter-select.component.tsx","../src/components/advanced/book-chapter-control/go-to-menu-item.component.tsx","../src/components/advanced/book-chapter-control/book-chapter-control.component.tsx","../src/components/shadcn-ui/button.tsx","../src/components/shadcn-ui/label.tsx","../src/components/shadcn-ui/radio-group.tsx","../src/components/shadcn-ui/popover.tsx","../src/components/shadcn-ui/dialog.tsx","../src/components/shadcn-ui/command.tsx","../src/components/basics/combo-box.component.tsx","../src/components/basics/chapter-range-selector.component.tsx","../src/components/advanced/book-selector.component.tsx","../src/components/advanced/data-table/data-table-column-toggle.component.tsx","../src/components/shadcn-ui/select.tsx","../src/components/advanced/data-table/data-table-pagination.component.tsx","../src/components/shadcn-ui/table.tsx","../src/components/advanced/data-table/data-table.component.tsx","../src/components/advanced/inventory/occurrences-table.component.tsx","../src/components/shadcn-ui/checkbox.tsx","../src/components/advanced/inventory/inventory-utils.ts","../src/components/shadcn-ui/toggle.tsx","../src/components/shadcn-ui/toggle-group.tsx","../src/components/advanced/inventory/inventory-columns.tsx","../src/components/advanced/inventory/inventory.component.tsx","../src/components/basics/search-bar.component.tsx","../src/components/basics/tabs-vertical.tsx","../src/components/advanced/tab-navigation-content-search.component.tsx","../src/components/shadcn-ui/separator.tsx","../src/components/shadcn-ui/sheet.tsx","../src/components/shadcn-ui/skeleton.tsx","../src/components/shadcn-ui/tooltip.tsx","../src/components/hooks/use-mobile.tsx","../src/components/shadcn-ui/sidebar.tsx","../src/components/advanced/settings-components/settings-sidebar.component.tsx","../src/components/advanced/settings-components/settings-sidebar-content-search.component.tsx","../src/components/advanced/scripture-results-viewer/scripture-results-viewer.component.tsx","../src/components/advanced/scroll-group-selector.component.tsx","../src/components/advanced/settings-components/settings-list.component.tsx","../src/components/basics/checklist.component.tsx","../../../node_modules/@babel/runtime/helpers/interopRequireDefault.js","../../../node_modules/@mui/utils/chainPropTypes/chainPropTypes.js","../../../node_modules/@babel/runtime/helpers/esm/extends.js","../../../node_modules/@mui/utils/deepmerge/deepmerge.js","../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.production.min.js","../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.development.js","../../../node_modules/prop-types/node_modules/react-is/index.js","../../../node_modules/object-assign/index.js","../../../node_modules/prop-types/lib/ReactPropTypesSecret.js","../../../node_modules/prop-types/lib/has.js","../../../node_modules/prop-types/checkPropTypes.js","../../../node_modules/prop-types/factoryWithTypeCheckers.js","../../../node_modules/prop-types/factoryWithThrowingShims.js","../../../node_modules/prop-types/index.js","../../../node_modules/@mui/utils/elementAcceptingRef/elementAcceptingRef.js","../../../node_modules/@mui/utils/exactProp/exactProp.js","../../../node_modules/@mui/utils/formatMuiErrorMessage/formatMuiErrorMessage.js","../../../node_modules/react-is/cjs/react-is.production.min.js","../../../node_modules/react-is/cjs/react-is.development.js","../../../node_modules/react-is/index.js","../../../node_modules/@mui/utils/getDisplayName/getDisplayName.js","../../../node_modules/@mui/utils/HTMLElementType/HTMLElementType.js","../../../node_modules/@mui/utils/refType/refType.js","../../../node_modules/@mui/utils/capitalize/capitalize.js","../../../node_modules/@mui/utils/createChainedFunction/createChainedFunction.js","../../../node_modules/@mui/utils/debounce/debounce.js","../../../node_modules/@mui/utils/deprecatedPropType/deprecatedPropType.js","../../../node_modules/@mui/utils/isMuiElement/isMuiElement.js","../../../node_modules/@mui/utils/ownerDocument/ownerDocument.js","../../../node_modules/@mui/utils/ownerWindow/ownerWindow.js","../../../node_modules/@mui/utils/requirePropFactory/requirePropFactory.js","../../../node_modules/@mui/utils/setRef/setRef.js","../../../node_modules/@mui/utils/useEnhancedEffect/useEnhancedEffect.js","../../../node_modules/@mui/utils/useId/useId.js","../../../node_modules/@mui/utils/unsupportedProp/unsupportedProp.js","../../../node_modules/@mui/utils/useControlled/useControlled.js","../../../node_modules/@mui/utils/useEventCallback/useEventCallback.js","../../../node_modules/@mui/utils/useForkRef/useForkRef.js","../../../node_modules/@mui/utils/useLazyRef/useLazyRef.js","../../../node_modules/@mui/utils/useOnMount/useOnMount.js","../../../node_modules/@mui/utils/useTimeout/useTimeout.js","../../../node_modules/@mui/utils/useIsFocusVisible/useIsFocusVisible.js","../../../node_modules/@mui/utils/resolveProps/resolveProps.js","../../../node_modules/@mui/utils/composeClasses/composeClasses.js","../../../node_modules/@mui/utils/ClassNameGenerator/ClassNameGenerator.js","../../../node_modules/@mui/utils/generateUtilityClass/generateUtilityClass.js","../../../node_modules/@mui/utils/generateUtilityClasses/generateUtilityClasses.js","../../../node_modules/@mui/utils/clamp/clamp.js","../../../node_modules/@babel/runtime/helpers/esm/objectWithoutPropertiesLoose.js","../../../node_modules/@mui/system/esm/createTheme/createBreakpoints.js","../../../node_modules/@mui/system/esm/createTheme/shape.js","../../../node_modules/@mui/system/esm/responsivePropType.js","../../../node_modules/@mui/system/esm/merge.js","../../../node_modules/@mui/system/esm/breakpoints.js","../../../node_modules/@mui/system/esm/style.js","../../../node_modules/@mui/system/esm/memoize.js","../../../node_modules/@mui/system/esm/spacing.js","../../../node_modules/@mui/system/esm/createTheme/createSpacing.js","../../../node_modules/@mui/system/esm/compose.js","../../../node_modules/@mui/system/esm/borders.js","../../../node_modules/@mui/system/esm/cssGrid.js","../../../node_modules/@mui/system/esm/palette.js","../../../node_modules/@mui/system/esm/sizing.js","../../../node_modules/@mui/system/esm/styleFunctionSx/defaultSxConfig.js","../../../node_modules/@mui/system/esm/styleFunctionSx/styleFunctionSx.js","../../../node_modules/@mui/system/esm/createTheme/applyStyles.js","../../../node_modules/@mui/system/esm/createTheme/createTheme.js","../../../node_modules/@mui/system/esm/useThemeWithoutDefault.js","../../../node_modules/@mui/system/esm/useTheme.js","../../../node_modules/@mui/system/esm/createStyled.js","../../../node_modules/@mui/system/esm/useThemeProps/getThemeProps.js","../../../node_modules/@mui/system/esm/useThemeProps/useThemeProps.js","../../../node_modules/@mui/system/esm/colorManipulator.js","../../../node_modules/@mui/material/styles/createMixins.js","../../../node_modules/@mui/material/colors/common.js","../../../node_modules/@mui/material/colors/grey.js","../../../node_modules/@mui/material/colors/purple.js","../../../node_modules/@mui/material/colors/red.js","../../../node_modules/@mui/material/colors/orange.js","../../../node_modules/@mui/material/colors/blue.js","../../../node_modules/@mui/material/colors/lightBlue.js","../../../node_modules/@mui/material/colors/green.js","../../../node_modules/@mui/material/styles/createPalette.js","../../../node_modules/@mui/material/styles/createTypography.js","../../../node_modules/@mui/material/styles/shadows.js","../../../node_modules/@mui/material/styles/createTransitions.js","../../../node_modules/@mui/material/styles/zIndex.js","../../../node_modules/@mui/material/styles/createTheme.js","../../../node_modules/@mui/material/styles/defaultTheme.js","../../../node_modules/@mui/material/styles/identifier.js","../../../node_modules/@mui/material/styles/useThemeProps.js","../../../node_modules/@mui/material/styles/styled.js","../../../node_modules/@mui/material/SvgIcon/svgIconClasses.js","../../../node_modules/@mui/material/SvgIcon/SvgIcon.js","../../../node_modules/@mui/material/utils/createSvgIcon.js","../../../node_modules/@mui/material/utils/index.js","../../../node_modules/@mui/icons-material/utils/createSvgIcon.js","../../../node_modules/@mui/icons-material/ArrowRight.js","../../../node_modules/@mui/base/utils/isHostComponent.js","../../../node_modules/@mui/base/utils/appendOwnerState.js","../../../node_modules/@mui/base/utils/ClassNameConfigurator.js","../../../node_modules/@mui/base/utils/extractEventHandlers.js","../../../node_modules/@mui/base/utils/resolveComponentProps.js","../../../node_modules/@mui/base/utils/omitEventHandlers.js","../../../node_modules/@mui/base/utils/mergeSlotProps.js","../../../node_modules/@mui/base/utils/useSlotProps.js","../../../node_modules/@mui/base/generateUtilityClass/index.js","../../../node_modules/@mui/base/generateUtilityClasses/index.js","../../../node_modules/@mui/base/Portal/Portal.js","../../../node_modules/@popperjs/core/lib/enums.js","../../../node_modules/@popperjs/core/lib/dom-utils/getNodeName.js","../../../node_modules/@popperjs/core/lib/dom-utils/getWindow.js","../../../node_modules/@popperjs/core/lib/dom-utils/instanceOf.js","../../../node_modules/@popperjs/core/lib/modifiers/applyStyles.js","../../../node_modules/@popperjs/core/lib/utils/getBasePlacement.js","../../../node_modules/@popperjs/core/lib/utils/math.js","../../../node_modules/@popperjs/core/lib/utils/userAgent.js","../../../node_modules/@popperjs/core/lib/dom-utils/isLayoutViewport.js","../../../node_modules/@popperjs/core/lib/dom-utils/getBoundingClientRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/getLayoutRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/contains.js","../../../node_modules/@popperjs/core/lib/dom-utils/getComputedStyle.js","../../../node_modules/@popperjs/core/lib/dom-utils/isTableElement.js","../../../node_modules/@popperjs/core/lib/dom-utils/getDocumentElement.js","../../../node_modules/@popperjs/core/lib/dom-utils/getParentNode.js","../../../node_modules/@popperjs/core/lib/dom-utils/getOffsetParent.js","../../../node_modules/@popperjs/core/lib/utils/getMainAxisFromPlacement.js","../../../node_modules/@popperjs/core/lib/utils/within.js","../../../node_modules/@popperjs/core/lib/utils/getFreshSideObject.js","../../../node_modules/@popperjs/core/lib/utils/mergePaddingObject.js","../../../node_modules/@popperjs/core/lib/utils/expandToHashMap.js","../../../node_modules/@popperjs/core/lib/modifiers/arrow.js","../../../node_modules/@popperjs/core/lib/utils/getVariation.js","../../../node_modules/@popperjs/core/lib/modifiers/computeStyles.js","../../../node_modules/@popperjs/core/lib/modifiers/eventListeners.js","../../../node_modules/@popperjs/core/lib/utils/getOppositePlacement.js","../../../node_modules/@popperjs/core/lib/utils/getOppositeVariationPlacement.js","../../../node_modules/@popperjs/core/lib/dom-utils/getWindowScroll.js","../../../node_modules/@popperjs/core/lib/dom-utils/getWindowScrollBarX.js","../../../node_modules/@popperjs/core/lib/dom-utils/getViewportRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/getDocumentRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/isScrollParent.js","../../../node_modules/@popperjs/core/lib/dom-utils/getScrollParent.js","../../../node_modules/@popperjs/core/lib/dom-utils/listScrollParents.js","../../../node_modules/@popperjs/core/lib/utils/rectToClientRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/getClippingRect.js","../../../node_modules/@popperjs/core/lib/utils/computeOffsets.js","../../../node_modules/@popperjs/core/lib/utils/detectOverflow.js","../../../node_modules/@popperjs/core/lib/utils/computeAutoPlacement.js","../../../node_modules/@popperjs/core/lib/modifiers/flip.js","../../../node_modules/@popperjs/core/lib/modifiers/hide.js","../../../node_modules/@popperjs/core/lib/modifiers/offset.js","../../../node_modules/@popperjs/core/lib/modifiers/popperOffsets.js","../../../node_modules/@popperjs/core/lib/utils/getAltAxis.js","../../../node_modules/@popperjs/core/lib/modifiers/preventOverflow.js","../../../node_modules/@popperjs/core/lib/dom-utils/getHTMLElementScroll.js","../../../node_modules/@popperjs/core/lib/dom-utils/getNodeScroll.js","../../../node_modules/@popperjs/core/lib/dom-utils/getCompositeRect.js","../../../node_modules/@popperjs/core/lib/utils/orderModifiers.js","../../../node_modules/@popperjs/core/lib/utils/debounce.js","../../../node_modules/@popperjs/core/lib/utils/mergeByName.js","../../../node_modules/@popperjs/core/lib/createPopper.js","../../../node_modules/@popperjs/core/lib/popper.js","../../../node_modules/@mui/base/Popper/popperClasses.js","../../../node_modules/@mui/base/Popper/Popper.js","../../../node_modules/@mui/material/styles/useTheme.js","../../../node_modules/@babel/runtime/helpers/esm/setPrototypeOf.js","../../../node_modules/@babel/runtime/helpers/esm/inheritsLoose.js","../../../node_modules/react-transition-group/esm/config.js","../../../node_modules/react-transition-group/esm/utils/PropTypes.js","../../../node_modules/react-transition-group/esm/TransitionGroupContext.js","../../../node_modules/react-transition-group/esm/utils/reflow.js","../../../node_modules/react-transition-group/esm/Transition.js","../../../node_modules/@mui/material/transitions/utils.js","../../../node_modules/@mui/material/Grow/Grow.js","../../../node_modules/@mui/material/Popper/Popper.js","../../../node_modules/@mui/material/Tooltip/tooltipClasses.js","../../../node_modules/@mui/material/Tooltip/Tooltip.js","../src/components/mui/menu-item.component.tsx","../src/components/mui/grouped-menu-item-list.component.tsx","../src/components/mui/top-level-menu.component.tsx","../src/components/mui/grid-menu.component.tsx","../src/hooks/use-promise.hook.ts","../../../node_modules/@mui/icons-material/esm/Menu.js","../src/components/mui/hamburger-menu-button.component.tsx","../src/components/mui/icon-button.component.tsx","../src/components/basics/spinner.component.tsx","../src/components/basics/text-field.component.tsx","../src/components/mui/toolbar.component.tsx","../src/components/shadcn-ui/alert.tsx","../src/components/shadcn-ui/card.tsx","../src/components/shadcn-ui/sonner.tsx","../src/components/shadcn-ui/slider.tsx","../src/components/shadcn-ui/switch.tsx","../src/components/shadcn-ui/tabs.tsx","../src/components/advanced/extension-marketplace/buttons/install-button.component.tsx","../src/components/advanced/extension-marketplace/buttons/enable-button.component.tsx","../src/components/advanced/extension-marketplace/buttons/disable-button.component.tsx","../src/components/advanced/extension-marketplace/buttons/update-button.component.tsx","../src/components/advanced/extension-marketplace/markdown-renderer.component.tsx","../src/components/advanced/extension-marketplace/buttons/filter-button.component.tsx","../src/components/advanced/extension-marketplace/filter-dropdown.component.tsx","../src/components/advanced/extension-marketplace/no-extensions-found.component.tsx","../src/components/advanced/extension-marketplace/more-info.component.tsx","../src/components/advanced/extension-marketplace/version-history.component.tsx","../src/components/advanced/extension-marketplace/footer.component.tsx","../src/hooks/use-event.hook.ts","../src/hooks/use-event-async.hook.ts"],"sourcesContent":["import { type ClassValue, clsx } from 'clsx';\nimport { extendTailwindMerge } from 'tailwind-merge';\n\nconst twMergeCustom = extendTailwindMerge({ prefix: 'tw-' });\n\n/**\n * Tailwind and CSS class application helper function. Uses\n * [`clsx`](https://www.npmjs.com/package/clsx) to make it easy to apply classes conditionally using\n * object syntax, and uses [`tailwind-merge`](https://www.npmjs.com/package/tailwind-merge) to make\n * it easy to merge/overwrite Tailwind classes in a programmer-logic-friendly way.\n *\n * Note: `tailwind-merge` is configured to use the prefix `tw-`, so you must use the same prefix\n * with any Tailwind classes you use with this function to successfully overwrite other Tailwind\n * classes. `platform-bible-react` is configured to use `tw-` as its Tailwind prefix, so any\n * Tailwind classes you pass into `platform-bible-react` components will be compared using the `tw-`\n * prefix.\n *\n * This function was popularized by\n * [shadcn/ui](https://ui.shadcn.com/docs/installation/manual#add-a-cn-helper). See [ByteGrad's\n * explanation video](https://www.youtube.com/watch?v=re2JFITR7TI) for more information.\n *\n * @example\n *\n * ```typescript\n * const borderShouldBeBlue = true;\n * const textShouldBeRed = true;\n * const heightShouldBe20 = false;\n * const classString = cn(\n * 'tw-bg-primary tw-h-10 tw-text-primary-foreground',\n * 'tw-bg-secondary',\n * {\n * 'tw-border-blue-500': borderShouldBeBlue,\n * 'tw-text-red-500': textShouldBeRed,\n * 'tw-h-20': heightShouldBe20,\n * },\n * 'some-class',\n * );\n * ```\n *\n * The resulting `classString` is `'tw-h-10 tw-bg-secondary tw-border-blue-500 tw-text-red-500\n * some-class'`\n *\n * - Notice that `'tw-bg-secondary'`, specified later, overwrote `'tw-bg-primary'`, specified earlier,\n * because they are Tailwind classes that affect the same css property\n * - Notice that `'tw-text-red-500'`, specified later, overwrote `'tw-text-primary-foreground'`,\n * specified earlier, because they are Tailwind classes that affect the same css property\n * - Notice that `'tw-h-20'`, specified later, did not overwrite `'tw-h-10'`, specified earlier,\n * because `'tw-h-20'` is part of a conditional class object and its value evaluated to `false`;\n * therefore it was not applied\n * - Notice that `'some-class'` was applied. This function is not limited only to Tailwind classes.\n *\n *\n * @param inputs Class strings or `clsx` conditional class objects to merge. Tailwind classes\n * specified later in the arguments overwrite similar Tailwind classes specified earlier in the\n * arguments\n * @returns Class string containing all applicable classes from the arguments based on the rules\n * described above\n */\n// shadcn/ui uses this export in its boilerplate code\n// eslint-disable-next-line import/prefer-default-export\nexport function cn(...inputs: ClassValue[]) {\n return twMergeCustom(clsx(inputs));\n}\n","import React from 'react';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport interface InputProps extends React.InputHTMLAttributes {}\n\nexport const Input = React.forwardRef(\n ({ className, type, ...props }, ref) => {\n return (\n \n );\n },\n);\nInput.displayName = 'Input';\n","import { FocusEventHandler, forwardRef, KeyboardEvent, MouseEventHandler } from 'react';\nimport { History } from 'lucide-react';\nimport { Input as ShadInput } from '@/components/shadcn-ui/input';\n\nexport type BookChapterInputProps = {\n handleSearch: (searchString: string) => void;\n handleKeyDown: (event: KeyboardEvent) => void;\n handleOnClick: MouseEventHandler;\n handleSubmit: () => void;\n onFocus?: FocusEventHandler;\n value: string;\n placeholder: string;\n};\n\n// Shadcn Input sets type to \"button\"- HAVE to prop spread before setting type\nconst BookChapterInput = forwardRef(\n (\n { handleSearch, handleKeyDown, handleOnClick, handleSubmit, ...props }: BookChapterInputProps,\n ref,\n ) => {\n return (\n
    \n handleSearch(event.target.value)}\n onKeyDown={(e) => {\n if (e.key === 'Enter') {\n handleSubmit();\n }\n handleKeyDown(e);\n }}\n onClick={handleOnClick}\n ref={ref}\n />\n {\n // eslint-disable-next-line no-console\n console.log('back in history');\n }}\n />\n
    \n );\n },\n);\n\nexport default BookChapterInput;\n","var P = Object.defineProperty;\nvar R = (t, e, s) => e in t ? P(t, e, { enumerable: !0, configurable: !0, writable: !0, value: s }) : t[e] = s;\nvar n = (t, e, s) => R(t, typeof e != \"symbol\" ? e + \"\" : e, s);\nclass _ {\n constructor() {\n n(this, \"books\");\n n(this, \"firstSelectedBookNum\");\n n(this, \"lastSelectedBookNum\");\n n(this, \"count\");\n n(this, \"selectedBookNumbers\");\n n(this, \"selectedBookIds\");\n }\n}\nconst N = [\n \"GEN\",\n \"EXO\",\n \"LEV\",\n \"NUM\",\n \"DEU\",\n \"JOS\",\n \"JDG\",\n \"RUT\",\n \"1SA\",\n \"2SA\",\n // 10\n \"1KI\",\n \"2KI\",\n \"1CH\",\n \"2CH\",\n \"EZR\",\n \"NEH\",\n \"EST\",\n \"JOB\",\n \"PSA\",\n \"PRO\",\n // 20\n \"ECC\",\n \"SNG\",\n \"ISA\",\n \"JER\",\n \"LAM\",\n \"EZK\",\n \"DAN\",\n \"HOS\",\n \"JOL\",\n \"AMO\",\n // 30\n \"OBA\",\n \"JON\",\n \"MIC\",\n \"NAM\",\n \"HAB\",\n \"ZEP\",\n \"HAG\",\n \"ZEC\",\n \"MAL\",\n \"MAT\",\n // 40\n \"MRK\",\n \"LUK\",\n \"JHN\",\n \"ACT\",\n \"ROM\",\n \"1CO\",\n \"2CO\",\n \"GAL\",\n \"EPH\",\n \"PHP\",\n // 50\n \"COL\",\n \"1TH\",\n \"2TH\",\n \"1TI\",\n \"2TI\",\n \"TIT\",\n \"PHM\",\n \"HEB\",\n \"JAS\",\n \"1PE\",\n // 60\n \"2PE\",\n \"1JN\",\n \"2JN\",\n \"3JN\",\n \"JUD\",\n \"REV\",\n \"TOB\",\n \"JDT\",\n \"ESG\",\n \"WIS\",\n // 70\n \"SIR\",\n \"BAR\",\n \"LJE\",\n \"S3Y\",\n \"SUS\",\n \"BEL\",\n \"1MA\",\n \"2MA\",\n \"3MA\",\n \"4MA\",\n // 80\n \"1ES\",\n \"2ES\",\n \"MAN\",\n \"PS2\",\n \"ODA\",\n \"PSS\",\n \"JSA\",\n // actual variant text for JOS, now in LXA text\n \"JDB\",\n // actual variant text for JDG, now in LXA text\n \"TBS\",\n // actual variant text for TOB, now in LXA text\n \"SST\",\n // actual variant text for SUS, now in LXA text // 90\n \"DNT\",\n // actual variant text for DAN, now in LXA text\n \"BLT\",\n // actual variant text for BEL, now in LXA text\n \"XXA\",\n \"XXB\",\n \"XXC\",\n \"XXD\",\n \"XXE\",\n \"XXF\",\n \"XXG\",\n \"FRT\",\n // 100\n \"BAK\",\n \"OTH\",\n \"3ES\",\n // Used previously but really should be 2ES\n \"EZA\",\n // Used to be called 4ES, but not actually in any known project\n \"5EZ\",\n // Used to be called 5ES, but not actually in any known project\n \"6EZ\",\n // Used to be called 6ES, but not actually in any known project\n \"INT\",\n \"CNC\",\n \"GLO\",\n \"TDX\",\n // 110\n \"NDX\",\n \"DAG\",\n \"PS3\",\n \"2BA\",\n \"LBA\",\n \"JUB\",\n \"ENO\",\n \"1MQ\",\n \"2MQ\",\n \"3MQ\",\n // 120\n \"REP\",\n \"4BA\",\n \"LAO\"\n], B = [\n \"XXA\",\n \"XXB\",\n \"XXC\",\n \"XXD\",\n \"XXE\",\n \"XXF\",\n \"XXG\",\n \"FRT\",\n \"BAK\",\n \"OTH\",\n \"INT\",\n \"CNC\",\n \"GLO\",\n \"TDX\",\n \"NDX\"\n], O = [\n \"Genesis\",\n \"Exodus\",\n \"Leviticus\",\n \"Numbers\",\n \"Deuteronomy\",\n \"Joshua\",\n \"Judges\",\n \"Ruth\",\n \"1 Samuel\",\n \"2 Samuel\",\n \"1 Kings\",\n \"2 Kings\",\n \"1 Chronicles\",\n \"2 Chronicles\",\n \"Ezra\",\n \"Nehemiah\",\n \"Esther (Hebrew)\",\n \"Job\",\n \"Psalms\",\n \"Proverbs\",\n \"Ecclesiastes\",\n \"Song of Songs\",\n \"Isaiah\",\n \"Jeremiah\",\n \"Lamentations\",\n \"Ezekiel\",\n \"Daniel (Hebrew)\",\n \"Hosea\",\n \"Joel\",\n \"Amos\",\n \"Obadiah\",\n \"Jonah\",\n \"Micah\",\n \"Nahum\",\n \"Habakkuk\",\n \"Zephaniah\",\n \"Haggai\",\n \"Zechariah\",\n \"Malachi\",\n \"Matthew\",\n \"Mark\",\n \"Luke\",\n \"John\",\n \"Acts\",\n \"Romans\",\n \"1 Corinthians\",\n \"2 Corinthians\",\n \"Galatians\",\n \"Ephesians\",\n \"Philippians\",\n \"Colossians\",\n \"1 Thessalonians\",\n \"2 Thessalonians\",\n \"1 Timothy\",\n \"2 Timothy\",\n \"Titus\",\n \"Philemon\",\n \"Hebrews\",\n \"James\",\n \"1 Peter\",\n \"2 Peter\",\n \"1 John\",\n \"2 John\",\n \"3 John\",\n \"Jude\",\n \"Revelation\",\n \"Tobit\",\n \"Judith\",\n \"Esther Greek\",\n \"Wisdom of Solomon\",\n \"Sirach (Ecclesiasticus)\",\n \"Baruch\",\n \"Letter of Jeremiah\",\n \"Song of 3 Young Men\",\n \"Susanna\",\n \"Bel and the Dragon\",\n \"1 Maccabees\",\n \"2 Maccabees\",\n \"3 Maccabees\",\n \"4 Maccabees\",\n \"1 Esdras (Greek)\",\n \"2 Esdras (Latin)\",\n \"Prayer of Manasseh\",\n \"Psalm 151\",\n \"Odes\",\n \"Psalms of Solomon\",\n // WARNING, if you change the spelling of the *obsolete* tag be sure to update\n // IsObsolete routine\n \"Joshua A. *obsolete*\",\n \"Judges B. *obsolete*\",\n \"Tobit S. *obsolete*\",\n \"Susanna Th. *obsolete*\",\n \"Daniel Th. *obsolete*\",\n \"Bel Th. *obsolete*\",\n \"Extra A\",\n \"Extra B\",\n \"Extra C\",\n \"Extra D\",\n \"Extra E\",\n \"Extra F\",\n \"Extra G\",\n \"Front Matter\",\n \"Back Matter\",\n \"Other Matter\",\n \"3 Ezra *obsolete*\",\n \"Apocalypse of Ezra\",\n \"5 Ezra (Latin Prologue)\",\n \"6 Ezra (Latin Epilogue)\",\n \"Introduction\",\n \"Concordance \",\n \"Glossary \",\n \"Topical Index\",\n \"Names Index\",\n \"Daniel Greek\",\n \"Psalms 152-155\",\n \"2 Baruch (Apocalypse)\",\n \"Letter of Baruch\",\n \"Jubilees\",\n \"Enoch\",\n \"1 Meqabyan\",\n \"2 Meqabyan\",\n \"3 Meqabyan\",\n \"Reproof (Proverbs 25-31)\",\n \"4 Baruch (Rest of Baruch)\",\n \"Laodiceans\"\n], S = K();\nfunction g(t, e = !0) {\n return e && (t = t.toUpperCase()), t in S ? S[t] : 0;\n}\nfunction k(t) {\n return g(t) > 0;\n}\nfunction x(t) {\n const e = typeof t == \"string\" ? g(t) : t;\n return e >= 40 && e <= 66;\n}\nfunction T(t) {\n return (typeof t == \"string\" ? g(t) : t) <= 39;\n}\nfunction X(t) {\n return t <= 66;\n}\nfunction V(t) {\n const e = typeof t == \"string\" ? g(t) : t;\n return w(e) && !X(e);\n}\nfunction* L() {\n for (let t = 1; t <= N.length; t++) yield t;\n}\nconst G = 1, A = N.length;\nfunction H() {\n return [\"XXA\", \"XXB\", \"XXC\", \"XXD\", \"XXE\", \"XXF\", \"XXG\"];\n}\nfunction C(t, e = \"***\") {\n const s = t - 1;\n return s < 0 || s >= N.length ? e : N[s];\n}\nfunction I(t) {\n return t <= 0 || t > A ? \"******\" : O[t - 1];\n}\nfunction y(t) {\n return I(g(t));\n}\nfunction w(t) {\n const e = typeof t == \"number\" ? C(t) : t;\n return k(e) && !B.includes(e);\n}\nfunction q(t) {\n const e = typeof t == \"number\" ? C(t) : t;\n return k(e) && B.includes(e);\n}\nfunction U(t) {\n return O[t - 1].includes(\"*obsolete*\");\n}\nfunction K() {\n const t = {};\n for (let e = 0; e < N.length; e++)\n t[N[e]] = e + 1;\n return t;\n}\nconst m = {\n allBookIds: N,\n nonCanonicalIds: B,\n bookIdToNumber: g,\n isBookIdValid: k,\n isBookNT: x,\n isBookOT: T,\n isBookOTNT: X,\n isBookDC: V,\n allBookNumbers: L,\n firstBook: G,\n lastBook: A,\n extraBooks: H,\n bookNumberToId: C,\n bookNumberToEnglishName: I,\n bookIdToEnglishName: y,\n isCanonical: w,\n isExtraMaterial: q,\n isObsolete: U\n};\nvar l = /* @__PURE__ */ ((t) => (t[t.Unknown = 0] = \"Unknown\", t[t.Original = 1] = \"Original\", t[t.Septuagint = 2] = \"Septuagint\", t[t.Vulgate = 3] = \"Vulgate\", t[t.English = 4] = \"English\", t[t.RussianProtestant = 5] = \"RussianProtestant\", t[t.RussianOrthodox = 6] = \"RussianOrthodox\", t))(l || {});\nconst h = class h {\n // private versInfo: Versification;\n constructor(e) {\n n(this, \"name\");\n n(this, \"fullPath\");\n n(this, \"isPresent\");\n n(this, \"hasVerseSegments\");\n n(this, \"isCustomized\");\n n(this, \"baseVersification\");\n n(this, \"scriptureBooks\");\n n(this, \"_type\");\n if (e == null)\n throw new Error(\"Argument undefined\");\n typeof e == \"string\" ? (this.name = e, this._type = l[e]) : (this._type = e, this.name = l[e]);\n }\n get type() {\n return this._type;\n }\n equals(e) {\n return !e.type || !this.type ? !1 : e.type === this.type;\n }\n};\nn(h, \"Original\", new h(l.Original)), n(h, \"Septuagint\", new h(l.Septuagint)), n(h, \"Vulgate\", new h(l.Vulgate)), n(h, \"English\", new h(l.English)), n(h, \"RussianProtestant\", new h(l.RussianProtestant)), n(h, \"RussianOrthodox\", new h(l.RussianOrthodox));\nlet c = h;\nfunction E(t, e) {\n const s = e[0];\n for (let r = 1; r < e.length; r++)\n t = t.split(e[r]).join(s);\n return t.split(s);\n}\nvar D = /* @__PURE__ */ ((t) => (t[t.Valid = 0] = \"Valid\", t[t.UnknownVersification = 1] = \"UnknownVersification\", t[t.OutOfRange = 2] = \"OutOfRange\", t[t.VerseOutOfOrder = 3] = \"VerseOutOfOrder\", t[t.VerseRepeated = 4] = \"VerseRepeated\", t))(D || {});\nconst i = class i {\n constructor(e, s, r, a) {\n /** Not yet implemented. */\n n(this, \"firstChapter\");\n /** Not yet implemented. */\n n(this, \"lastChapter\");\n /** Not yet implemented. */\n n(this, \"lastVerse\");\n /** Not yet implemented. */\n n(this, \"hasSegmentsDefined\");\n /** Not yet implemented. */\n n(this, \"text\");\n /** Not yet implemented. */\n n(this, \"BBBCCCVVVS\");\n /** Not yet implemented. */\n n(this, \"longHashCode\");\n /** The versification of the reference. */\n n(this, \"versification\");\n n(this, \"rtlMark\", \"‏\");\n n(this, \"_bookNum\", 0);\n n(this, \"_chapterNum\", 0);\n n(this, \"_verseNum\", 0);\n n(this, \"_verse\");\n if (r == null && a == null)\n if (e != null && typeof e == \"string\") {\n const o = e, u = s != null && s instanceof c ? s : void 0;\n this.setEmpty(u), this.parse(o);\n } else if (e != null && typeof e == \"number\") {\n const o = s != null && s instanceof c ? s : void 0;\n this.setEmpty(o), this._verseNum = e % i.chapterDigitShifter, this._chapterNum = Math.floor(\n e % i.bookDigitShifter / i.chapterDigitShifter\n ), this._bookNum = Math.floor(e / i.bookDigitShifter);\n } else if (s == null)\n if (e != null && e instanceof i) {\n const o = e;\n this._bookNum = o.bookNum, this._chapterNum = o.chapterNum, this._verseNum = o.verseNum, this._verse = o.verse, this.versification = o.versification;\n } else {\n if (e == null) return;\n const o = e instanceof c ? e : i.defaultVersification;\n this.setEmpty(o);\n }\n else\n throw new Error(\"VerseRef constructor not supported.\");\n else if (e != null && s != null && r != null)\n if (typeof e == \"string\" && typeof s == \"string\" && typeof r == \"string\")\n this.setEmpty(a), this.updateInternal(e, s, r);\n else if (typeof e == \"number\" && typeof s == \"number\" && typeof r == \"number\")\n this._bookNum = e, this._chapterNum = s, this._verseNum = r, this.versification = a ?? i.defaultVersification;\n else\n throw new Error(\"VerseRef constructor not supported.\");\n else\n throw new Error(\"VerseRef constructor not supported.\");\n }\n /**\n * Determines if the verse string is in a valid format (does not consider versification).\n */\n static isVerseParseable(e) {\n return e.length > 0 && \"0123456789\".includes(e[0]) && !e.endsWith(this.verseRangeSeparator) && !e.endsWith(this.verseSequenceIndicator);\n }\n /**\n * Tries to parse the specified string into a verse reference.\n * @param str - The string to attempt to parse.\n * @returns success: `true` if the specified string was successfully parsed, `false` otherwise.\n * @returns verseRef: The result of the parse if successful, or empty VerseRef if it failed\n */\n static tryParse(e) {\n let s;\n try {\n return s = new i(e), { success: !0, verseRef: s };\n } catch (r) {\n if (r instanceof v)\n return s = new i(), { success: !1, verseRef: s };\n throw r;\n }\n }\n /**\n * Gets the reference as a comparable integer where the book, chapter, and verse each occupy 3\n * digits.\n * @param bookNum - Book number (this is 1-based, not an index).\n * @param chapterNum - Chapter number.\n * @param verseNum - Verse number.\n * @returns The reference as a comparable integer where the book, chapter, and verse each occupy 3\n * digits.\n */\n static getBBBCCCVVV(e, s, r) {\n return e % i.bcvMaxValue * i.bookDigitShifter + (s >= 0 ? s % i.bcvMaxValue * i.chapterDigitShifter : 0) + (r >= 0 ? r % i.bcvMaxValue : 0);\n }\n /**\n * Deserializes a serialized VerseRef.\n * @param serializedVerseRef - Serialized VerseRef to create from.\n * @returns the deserialized VerseRef.\n */\n static fromJSON(e) {\n const { book: s, chapterNum: r, verseNum: a, verse: o, versificationStr: u } = e, f = o || a.toString();\n let d;\n return u && (d = new c(u)), s ? new i(s, r.toString(), f, d) : new i();\n }\n /**\n * Parses a verse string and gets the leading numeric portion as a number.\n * @param verseStr - verse string to parse\n * @returns true if the entire string could be parsed as a single, simple verse number (1-999);\n * false if the verse string represented a verse bridge, contained segment letters, or was invalid\n */\n static tryGetVerseNum(e) {\n let s;\n if (!e)\n return s = -1, { success: !0, vNum: s };\n s = 0;\n let r;\n for (let a = 0; a < e.length; a++) {\n if (r = e[a], r < \"0\" || r > \"9\")\n return a === 0 && (s = -1), { success: !1, vNum: s };\n if (s = s * 10 + +r - 0, s > i.bcvMaxValue)\n return s = -1, { success: !1, vNum: s };\n }\n return { success: !0, vNum: s };\n }\n /**\n * Checks to see if a VerseRef hasn't been set - all values are the default.\n */\n get isDefault() {\n return this.bookNum === 0 && this.chapterNum === 0 && this.verseNum === 0 && this.versification == null;\n }\n /**\n * Gets whether the verse contains multiple verses.\n */\n get hasMultiple() {\n return this._verse != null && (this._verse.includes(i.verseRangeSeparator) || this._verse.includes(i.verseSequenceIndicator));\n }\n /**\n * Gets or sets the book of the reference. Book is the 3-letter abbreviation in capital letters,\n * e.g. `'MAT'`.\n */\n get book() {\n return m.bookNumberToId(this.bookNum, \"\");\n }\n set book(e) {\n this.bookNum = m.bookIdToNumber(e);\n }\n /**\n * Gets or sets the chapter of the reference,. e.g. `'3'`.\n */\n get chapter() {\n return this.isDefault || this._chapterNum < 0 ? \"\" : this._chapterNum.toString();\n }\n set chapter(e) {\n const s = +e;\n this._chapterNum = Number.isInteger(s) ? s : -1;\n }\n /**\n * Gets or sets the verse of the reference, including range, segments, and sequences, e.g. `'4'`,\n * or `'4b-5a, 7'`.\n */\n get verse() {\n return this._verse != null ? this._verse : this.isDefault || this._verseNum < 0 ? \"\" : this._verseNum.toString();\n }\n set verse(e) {\n const { success: s, vNum: r } = i.tryGetVerseNum(e);\n this._verse = s ? void 0 : e.replace(this.rtlMark, \"\"), this._verseNum = r, !(this._verseNum >= 0) && ({ vNum: this._verseNum } = i.tryGetVerseNum(this._verse));\n }\n /**\n * Get or set Book based on book number, e.g. `42`.\n */\n get bookNum() {\n return this._bookNum;\n }\n set bookNum(e) {\n if (e <= 0 || e > m.lastBook)\n throw new v(\n \"BookNum must be greater than zero and less than or equal to last book\"\n );\n this._bookNum = e;\n }\n /**\n * Gets or sets the chapter number, e.g. `3`. `-1` if not valid.\n */\n get chapterNum() {\n return this._chapterNum;\n }\n set chapterNum(e) {\n this.chapterNum = e;\n }\n /**\n * Gets or sets verse start number, e.g. `4`. `-1` if not valid.\n */\n get verseNum() {\n return this._verseNum;\n }\n set verseNum(e) {\n this._verseNum = e;\n }\n /**\n * String representing the versification (should ONLY be used for serialization/deserialization).\n *\n * @remarks This is for backwards compatibility when ScrVers was an enumeration.\n */\n get versificationStr() {\n var e;\n return (e = this.versification) == null ? void 0 : e.name;\n }\n set versificationStr(e) {\n this.versification = this.versification != null ? new c(e) : void 0;\n }\n /**\n * Determines if the reference is valid.\n */\n get valid() {\n return this.validStatus === 0;\n }\n /**\n * Get the valid status for this reference.\n */\n get validStatus() {\n return this.validateVerse(i.verseRangeSeparators, i.verseSequenceIndicators);\n }\n /**\n * Gets the reference as a comparable integer where the book,\n * chapter, and verse each occupy three digits and the verse is 0.\n */\n get BBBCCC() {\n return i.getBBBCCCVVV(this._bookNum, this._chapterNum, 0);\n }\n /**\n * Gets the reference as a comparable integer where the book,\n * chapter, and verse each occupy three digits. If verse is not null\n * (i.e., this reference represents a complex reference with verse\n * segments or bridge) this cannot be used for an exact comparison.\n */\n get BBBCCCVVV() {\n return i.getBBBCCCVVV(this._bookNum, this._chapterNum, this._verseNum);\n }\n /**\n * Gets whether the verse is defined as an excluded verse in the versification.\n * Does not handle verse ranges.\n */\n // eslint-disable-next-line @typescript-eslint/class-literal-property-style\n get isExcluded() {\n return !1;\n }\n /**\n * Parses the reference in the specified string.\n * Optionally versification can follow reference as in GEN 3:11/4\n * Throw an exception if\n * - invalid book name\n * - chapter number is missing or not a number\n * - verse number is missing or does not start with a number\n * - versification is invalid\n * @param verseStr - string to parse e.g. 'MAT 3:11'\n */\n parse(e) {\n if (e = e.replace(this.rtlMark, \"\"), e.includes(\"/\")) {\n const o = e.split(\"/\");\n if (e = o[0], o.length > 1)\n try {\n const u = +o[1].trim();\n this.versification = new c(l[u]);\n } catch {\n throw new v(\"Invalid reference : \" + e);\n }\n }\n const s = e.trim().split(\" \");\n if (s.length !== 2)\n throw new v(\"Invalid reference : \" + e);\n const r = s[1].split(\":\"), a = +r[0];\n if (r.length !== 2 || m.bookIdToNumber(s[0]) === 0 || !Number.isInteger(a) || a < 0 || !i.isVerseParseable(r[1]))\n throw new v(\"Invalid reference : \" + e);\n this.updateInternal(s[0], r[0], r[1]);\n }\n /**\n * Simplifies this verse ref so that it has no bridging of verses or\n * verse segments like `'1a'`.\n */\n simplify() {\n this._verse = void 0;\n }\n /**\n * Makes a clone of the reference.\n *\n * @returns The cloned VerseRef.\n */\n clone() {\n return new i(this);\n }\n toString() {\n const e = this.book;\n return e === \"\" ? \"\" : `${e} ${this.chapter}:${this.verse}`;\n }\n toJSON() {\n let e = this.verse;\n (e === \"\" || e === this.verseNum.toString()) && (e = void 0);\n const s = {\n book: this.book,\n chapterNum: this.chapterNum,\n verseNum: this.verseNum,\n verse: e,\n versificationStr: this.versificationStr\n };\n return e || delete s.verse, s;\n }\n /**\n * Compares this `VerseRef` with supplied one.\n * @param verseRef - object to compare this one to.\n * @returns `true` if this `VerseRef` is equal to the supplied one, `false` otherwise.\n */\n equals(e) {\n return e instanceof i ? e._bookNum === this._bookNum && e._chapterNum === this._chapterNum && e._verseNum === this._verseNum && e.verse === this.verse && (e.versification == null && this.versification == null || e.versification != null && this.versification != null && e.versification.equals(this.versification)) : !1;\n }\n /**\n * Enumerate all individual verses contained in a VerseRef.\n * Verse ranges are indicated by \"-\" and consecutive verses by \",\"s.\n * Examples:\n * GEN 1:2 returns GEN 1:2\n * GEN 1:1a-3b,5 returns GEN 1:1a, GEN 1:2, GEN 1:3b, GEN 1:5\n * GEN 1:2a-2c returns //! ??????\n *\n * @param specifiedVersesOnly - if set to true return only verses that are\n * explicitly specified only, not verses within a range. Defaults to `false`.\n * @param verseRangeSeparators - Verse range separators.\n * Defaults to `VerseRef.verseRangeSeparators`.\n * @param verseSequenceSeparators - Verse sequence separators.\n * Defaults to `VerseRef.verseSequenceIndicators`.\n * @returns An array of all single verse references in this VerseRef.\n */\n allVerses(e = !1, s = i.verseRangeSeparators, r = i.verseSequenceIndicators) {\n if (this._verse == null || this.chapterNum <= 0)\n return [this.clone()];\n const a = [], o = E(this._verse, r);\n for (const u of o.map((f) => E(f, s))) {\n const f = this.clone();\n f.verse = u[0];\n const d = f.verseNum;\n if (a.push(f), u.length > 1) {\n const b = this.clone();\n if (b.verse = u[1], !e)\n for (let p = d + 1; p < b.verseNum; p++) {\n const J = new i(\n this._bookNum,\n this._chapterNum,\n p,\n this.versification\n );\n this.isExcluded || a.push(J);\n }\n a.push(b);\n }\n }\n return a;\n }\n /**\n * Validates a verse number using the supplied separators rather than the defaults.\n */\n validateVerse(e, s) {\n if (!this.verse)\n return this.internalValid;\n let r = 0;\n for (const a of this.allVerses(!0, e, s)) {\n const o = a.internalValid;\n if (o !== 0)\n return o;\n const u = a.BBBCCCVVV;\n if (r > u)\n return 3;\n if (r === u)\n return 4;\n r = u;\n }\n return 0;\n }\n /**\n * Gets whether a single verse reference is valid.\n */\n get internalValid() {\n return this.versification == null ? 1 : this._bookNum <= 0 || this._bookNum > m.lastBook ? 2 : (m.isCanonical(this._bookNum), 0);\n }\n setEmpty(e = i.defaultVersification) {\n this._bookNum = 0, this._chapterNum = -1, this._verse = void 0, this.versification = e;\n }\n updateInternal(e, s, r) {\n this.bookNum = m.bookIdToNumber(e), this.chapter = s, this.verse = r;\n }\n};\nn(i, \"defaultVersification\", c.English), n(i, \"verseRangeSeparator\", \"-\"), n(i, \"verseSequenceIndicator\", \",\"), n(i, \"verseRangeSeparators\", [i.verseRangeSeparator]), n(i, \"verseSequenceIndicators\", [i.verseSequenceIndicator]), n(i, \"chapterDigitShifter\", 1e3), n(i, \"bookDigitShifter\", i.chapterDigitShifter * i.chapterDigitShifter), n(i, \"bcvMaxValue\", i.chapterDigitShifter - 1), /**\n * The valid status of the VerseRef.\n */\nn(i, \"ValidStatusType\", D);\nlet M = i;\nclass v extends Error {\n}\nexport {\n _ as BookSet,\n m as Canon,\n c as ScrVers,\n l as ScrVersType,\n M as VerseRef,\n v as VerseRefException\n};\n//# sourceMappingURL=index.es.js.map\n","import React from 'react';\nimport * as DropdownMenuPrimitive from '@radix-ui/react-dropdown-menu';\nimport { Check, ChevronRight, Circle } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport const DropdownMenu = DropdownMenuPrimitive.Root;\n\nexport const DropdownMenuTrigger = DropdownMenuPrimitive.Trigger;\n\nexport const DropdownMenuGroup = DropdownMenuPrimitive.Group;\n\nexport const DropdownMenuPortal = DropdownMenuPrimitive.Portal;\n\nexport const DropdownMenuSub = DropdownMenuPrimitive.Sub;\n\nexport const DropdownMenuRadioGroup = DropdownMenuPrimitive.RadioGroup;\n\nexport type DropdownMenuSubTriggerProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.SubTrigger\n> & {\n className?: string;\n inset?: boolean;\n};\n\nexport type DropdownMenuSubContentProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.SubContent\n> & {\n className?: string;\n};\n\nexport type DropdownMenuContentProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Content\n> & {\n className?: string;\n sideOffset?: number;\n};\n\nexport type DropdownMenuItemProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Item\n> & {\n className?: string;\n inset?: boolean;\n};\n\nexport type DropdownMenuCheckboxItemProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.CheckboxItem\n> & {\n className?: string;\n checked?: boolean;\n};\n\nexport type DropdownMenuRadioItemProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.RadioItem\n> & {\n className?: string;\n};\n\nexport type DropdownMenuLabelProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Label\n> & {\n className?: string;\n inset?: boolean;\n};\n\nexport type DropdownMenuSeparatorProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Separator\n> & {\n className?: string;\n};\n\nexport type DropdownMenuShortcutProps = React.HTMLAttributes & {\n className?: string;\n};\n\nexport const DropdownMenuSubTrigger = React.forwardRef<\n React.ElementRef,\n DropdownMenuSubTriggerProps\n>(({ className, inset, children, ...props }, ref) => (\n \n {children}\n \n \n));\nDropdownMenuSubTrigger.displayName = DropdownMenuPrimitive.SubTrigger.displayName;\n\nexport const DropdownMenuSubContent = React.forwardRef<\n React.ElementRef,\n DropdownMenuSubContentProps\n>(({ className, ...props }, ref) => (\n \n));\nDropdownMenuSubContent.displayName = DropdownMenuPrimitive.SubContent.displayName;\n\nexport const DropdownMenuContent = React.forwardRef<\n React.ElementRef,\n DropdownMenuContentProps\n>(({ className, sideOffset = 4, ...props }, ref) => (\n \n \n \n));\nDropdownMenuContent.displayName = DropdownMenuPrimitive.Content.displayName;\n\n/**\n * TODO: fix: direction is not automatically handled by this component, so that shortcuts are\n * display always to the right\n */\nexport const DropdownMenuItem = React.forwardRef<\n React.ElementRef,\n DropdownMenuItemProps\n>(({ className, inset, ...props }, ref) => (\n \n));\nDropdownMenuItem.displayName = DropdownMenuPrimitive.Item.displayName;\n\nexport const DropdownMenuCheckboxItem = React.forwardRef<\n React.ElementRef,\n DropdownMenuCheckboxItemProps\n>(({ className, children, checked, ...props }, ref) => (\n \n \n \n \n \n \n {children}\n \n));\nDropdownMenuCheckboxItem.displayName = DropdownMenuPrimitive.CheckboxItem.displayName;\n\nexport const DropdownMenuRadioItem = React.forwardRef<\n React.ElementRef,\n DropdownMenuRadioItemProps\n>(({ className, children, ...props }, ref) => (\n \n \n \n \n \n \n {children}\n \n));\nDropdownMenuRadioItem.displayName = DropdownMenuPrimitive.RadioItem.displayName;\n\nexport const DropdownMenuLabel = React.forwardRef<\n React.ElementRef,\n DropdownMenuLabelProps\n>(({ className, inset, ...props }, ref) => (\n \n));\nDropdownMenuLabel.displayName = DropdownMenuPrimitive.Label.displayName;\n\nexport const DropdownMenuSeparator = React.forwardRef<\n React.ElementRef,\n DropdownMenuSeparatorProps\n>(({ className, ...props }, ref) => (\n \n));\nDropdownMenuSeparator.displayName = DropdownMenuPrimitive.Separator.displayName;\n\nexport function DropdownMenuShortcut({ className, ...props }: DropdownMenuShortcutProps) {\n return (\n \n );\n}\nDropdownMenuShortcut.displayName = 'DropdownMenuShortcut';\n","import { Canon } from '@sillsdev/scripture';\nimport { PropsWithChildren, KeyboardEvent, forwardRef } from 'react';\nimport { DropdownMenuItem as ShadDropdownMenuItem } from '@/components/shadcn-ui/dropdown-menu';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport type BookType = 'OT' | 'NT' | 'DC';\n\ntype BookMenuItemProps = PropsWithChildren<{\n /** String id of book */\n bookId: string;\n /** Callback to run when a book menu item is selected */\n handleSelectBook: () => void;\n /** Indicates if this menu item is currently selected */\n isSelected: boolean;\n /** Function that is called upon highlighting a book in the dropdown menu */\n handleHighlightBook: () => void;\n /**\n * Function that is called on pressing a key\n *\n * @param event Event that contains information about the key stroke\n */\n handleKeyDown: (event: KeyboardEvent) => void;\n /**\n * Type of book associated with this menu item, coordinates color labels ? Mock up has the labels\n * coordinated to genre\n */\n bookType: BookType;\n}>;\n\nconst BookMenuItem = forwardRef(\n (\n {\n bookId,\n handleSelectBook,\n isSelected,\n handleHighlightBook,\n handleKeyDown,\n bookType,\n children,\n }: BookMenuItemProps,\n ref,\n ) => {\n return (\n {\n // preventDefault() here prevents the entire dropdown menu from closing when selecting this item\n event.preventDefault();\n handleSelectBook();\n }}\n onKeyDown={(event: KeyboardEvent) => {\n handleKeyDown(event);\n }}\n onFocus={handleHighlightBook}\n onMouseMove={handleHighlightBook}\n >\n \n {Canon.bookIdToEnglishName(bookId)}\n \n {isSelected &&
    {children}
    }\n \n );\n },\n);\n\nexport default BookMenuItem;\n","import { cn } from '@/utils/shadcn-ui.util';\nimport { useCallback } from 'react';\n\nexport type ChapterSelectProps = {\n /**\n * Callback to run when a chapter div is selected\n *\n * @param chapterNumber Number of the chapter that has been selected\n */\n handleSelectChapter: (chapterNumber: number) => void;\n /** The highest chapter number in the book (of course equal to number of chapters in the book) */\n endChapter: number;\n /** The chapter number that is currently selected */\n activeChapter: number;\n /** The chapter number that is currently highlighted using keyboard or mouse navigation */\n highlightedChapter: number;\n /**\n * Callback to run when a chapter is highlighted by the user\n *\n * @param chapterNumber The chapter that is highlighted\n */\n handleHighlightedChapter: (chapterNumber: number) => void;\n};\n\nfunction ChapterSelect({\n handleSelectChapter,\n endChapter,\n activeChapter,\n highlightedChapter,\n handleHighlightedChapter,\n}: ChapterSelectProps) {\n const chapters = Array.from({ length: endChapter }, (_, i) => i + 1);\n\n const handleMouse = useCallback(\n (chapterNumber: number) => {\n handleHighlightedChapter(chapterNumber);\n },\n [handleHighlightedChapter],\n );\n\n return (\n
    \n {chapters.map((chapter) => (\n {\n event.preventDefault();\n event.stopPropagation();\n handleSelectChapter(chapter);\n }}\n role=\"button\"\n onKeyDown={(event) => {\n if (event.key === 'Enter') {\n handleSelectChapter(chapter);\n }\n }}\n tabIndex={0}\n onMouseMove={() => handleMouse(chapter)}\n >\n {chapter}\n
    \n ))}\n
    \n );\n}\n\nexport default ChapterSelect;\n","import { DropdownMenuLabel as ShadDropdownMenuLabel } from '@/components/shadcn-ui/dropdown-menu';\nimport { Bookmark, Clock, ArrowDownWideNarrow } from 'lucide-react';\n\nexport type GoToMenuItemProps = {\n handleSort: () => void;\n handleLocationHistory: () => void;\n handleBookmarks: () => void;\n};\n\nfunction GoToMenuItem({ handleSort, handleLocationHistory, handleBookmarks }: GoToMenuItemProps) {\n return (\n \n

    Go To

    \n
    \n \n \n \n
    \n
    \n );\n}\n\nexport default GoToMenuItem;\n","import BookChapterInput from '@/components/advanced/book-chapter-control/book-chapter-input.component';\nimport BookMenuItem, {\n BookType,\n} from '@/components/advanced/book-chapter-control/book-menu-item.component';\nimport ChapterSelect from '@/components/advanced/book-chapter-control/chapter-select.component';\nimport GoToMenuItem from '@/components/advanced/book-chapter-control/go-to-menu-item.component';\nimport {\n DropdownMenu as ShadDropdownMenu,\n DropdownMenuContent as ShadDropdownMenuContent,\n DropdownMenuLabel as ShadDropdownMenuLabel,\n DropdownMenuSeparator as ShadDropdownMenuSeparator,\n DropdownMenuTrigger as ShadDropdownMenuTrigger,\n} from '@/components/shadcn-ui/dropdown-menu';\nimport { Canon } from '@sillsdev/scripture';\nimport { ScriptureReference, getChaptersForBook } from 'platform-bible-utils';\nimport {\n KeyboardEvent as ReactKeyboardEvent,\n useCallback,\n useEffect,\n useLayoutEffect,\n useRef,\n useState,\n} from 'react';\n\ntype BookTypeLabels = {\n [bookType in BookType]: string;\n};\ntype BookChapterControlProps = {\n scrRef: ScriptureReference;\n handleSubmit: (scrRef: ScriptureReference) => void;\n};\n\nconst ALL_BOOK_IDS = Canon.allBookIds;\nconst BOOK_TYPE_LABELS: BookTypeLabels = {\n OT: 'Old Testament',\n NT: 'New Testament',\n DC: 'Deuterocanon',\n};\nconst BOOK_TYPE_ARRAY: BookType[] = ['OT', 'NT', 'DC'];\n// This is the height of three menu items to offset scrolling to the selected menu item\n// If you use menuItemRef.clientHeight- includes height of chapter div which is too big\nconst SCROLL_OFFSET = 32 + 32 + 32;\nconst SEARCH_QUERY_FORMATS = [\n /^(\\w+)$/i, // Matches a single word (book name or id)\n /^(\\w+)(?:\\s(\\d+))$/i, // Matches a word followed by a chapter number\n /^(\\w+)(?:\\s(\\d+):(\\d+))$/i, // Matches a word followed by a chapter and verse number\n];\nconst fetchGroupedBooks = (bookType: BookType) => {\n const groupedBooks = {\n OT: ALL_BOOK_IDS.filter((bookId) => Canon.isBookOT(bookId)),\n NT: ALL_BOOK_IDS.filter((bookId) => Canon.isBookNT(bookId)),\n DC: ALL_BOOK_IDS.filter((bookId) => Canon.isBookDC(bookId)),\n };\n return groupedBooks[bookType];\n};\nconst fetchEndChapter = (bookId: string) => {\n // getChaptersForBook returns -1 if not found in scrBookData\n // scrBookData only includes OT and NT, so all DC will return -1\n return getChaptersForBook(Canon.bookIdToNumber(bookId));\n};\n\n/**\n * Gets all of the English names from book ids\n *\n * @returns String[]\n */\nfunction getAllEnglishNames(): string[] {\n const allEnglishNames = ALL_BOOK_IDS.map((bookId) => {\n return Canon.bookIdToEnglishName(bookId);\n });\n return allEnglishNames;\n}\n\n/**\n * Determines if bookName is in allEnglishNames\n *\n * @param bookName Book English name\n * @returns True if bookName is included, false otherwise\n */\nfunction isValidBookEnglishName(bookName: string): boolean {\n return getAllEnglishNames().includes(bookName);\n}\n\n/**\n * Gets a bookId from given English name\n *\n * @param bookName Book English name\n * @returns BookId of provided bookName, undefined otherwise\n */\nfunction getBookIdFromEnglishName(bookName: string): string | undefined {\n // Convert bookName to lowercase and then capitalize the first letter\n const formattedBookName = bookName.toLowerCase().replace(/^\\w/, (c) => c.toUpperCase());\n\n if (isValidBookEnglishName(formattedBookName)) {\n const matchingBookId = ALL_BOOK_IDS.find((bookId) => {\n return Canon.bookIdToEnglishName(bookId) === formattedBookName;\n });\n return matchingBookId;\n }\n\n return undefined;\n}\n\nfunction BookChapterControl({ scrRef, handleSubmit }: BookChapterControlProps) {\n const [searchQuery, setSearchQuery] = useState('');\n const [selectedBookId, setSelectedBookId] = useState(\n Canon.bookNumberToId(scrRef.bookNum),\n );\n const [highlightedChapter, setHighlightedChapter] = useState(scrRef.chapterNum ?? 0);\n const [highlightedBookId, setHighlightedBookId] = useState(\n Canon.bookNumberToId(scrRef.bookNum),\n );\n const [isContentOpen, setIsContentOpen] = useState(false);\n const [isContentOpenDelayed, setIsContentOpenDelayed] = useState(isContentOpen);\n\n // This ref will always be defined\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const inputRef = useRef(undefined!);\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const contentRef = useRef(undefined!);\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const menuItemRef = useRef(undefined!);\n\n const fetchFilteredBooks = useCallback(\n (bookType: BookType) => {\n return fetchGroupedBooks(bookType).filter((bookId: string) => {\n const englishNameLowerCase = Canon.bookIdToEnglishName(bookId).toLowerCase();\n const normalizedQuery = searchQuery.replace(/[^a-zA-Z]/g, '').toLowerCase();\n return (\n englishNameLowerCase.includes(normalizedQuery) || // Match book name\n bookId.toLowerCase().includes(normalizedQuery) // Match book ID\n );\n });\n },\n [searchQuery],\n );\n\n const handleSearchInput = (searchString: string) => {\n setSearchQuery(searchString);\n };\n\n /**\n * Whether to prevent radix's logic from closing the dropdown. This is important because radix\n * tries to close the dropdown when the input first focuses, and we don't want it to do that. But\n * we don't want to prevent the dropdown from closing when we click away from the input, so we\n * don't want to just keep it open if the input is focused\n */\n const shouldPreventAutoClosing = useRef(false);\n\n const controlMenuState = useCallback((open: boolean) => {\n if (shouldPreventAutoClosing.current) {\n shouldPreventAutoClosing.current = false;\n return;\n }\n setIsContentOpen(open);\n }, []);\n\n const updateReference = useCallback(\n (bookId: string, shouldClose: boolean, chapter?: number, verse?: number) => {\n setHighlightedChapter(\n Canon.bookNumberToId(scrRef.bookNum) !== bookId ? 1 : scrRef.chapterNum,\n );\n\n if (shouldClose || fetchEndChapter(bookId) === -1) {\n handleSubmit({\n bookNum: Canon.bookIdToNumber(bookId),\n chapterNum: chapter || 1,\n verseNum: verse || 1,\n });\n\n setIsContentOpen(false);\n setSearchQuery('');\n return;\n }\n\n setSelectedBookId(selectedBookId !== bookId ? bookId : '');\n setIsContentOpen(!shouldClose);\n },\n [handleSubmit, scrRef.bookNum, scrRef.chapterNum, selectedBookId],\n );\n\n const handleSelectChapter = (chapterNumber: number) => {\n if (chapterNumber <= 0 || chapterNumber > fetchEndChapter(selectedBookId)) {\n return;\n }\n updateReference(selectedBookId, true, chapterNumber);\n };\n\n const handleInputSubmit = useCallback(() => {\n SEARCH_QUERY_FORMATS.forEach((format) => {\n const matches = searchQuery.match(format);\n if (matches) {\n // Book should be a bookId or an english name\n const [book, chapter = undefined, verse = undefined] = matches.slice(1);\n const englishName = getBookIdFromEnglishName(book);\n\n if (Canon.isBookIdValid(book) || englishName) {\n updateReference(\n englishName ?? book,\n true,\n chapter ? parseInt(chapter, 10) : 1,\n verse ? parseInt(verse, 10) : 1,\n );\n }\n }\n });\n }, [updateReference, searchQuery]);\n\n const handleKeyDownInput = useCallback(\n (event: ReactKeyboardEvent) => {\n if (!isContentOpen) {\n setIsContentOpen(true);\n } else if (event.key === 'ArrowDown' || event.key === 'ArrowUp') {\n if (\n typeof menuItemRef !== 'undefined' &&\n // Ref uses null\n // eslint-disable-next-line no-null/no-null\n menuItemRef.current !== null\n ) {\n menuItemRef.current.focus();\n } else if (\n typeof contentRef !== 'undefined' &&\n // Ref uses null\n // eslint-disable-next-line no-null/no-null\n contentRef.current !== null\n ) {\n contentRef.current.focus();\n }\n event.preventDefault();\n }\n },\n [isContentOpen],\n );\n\n const handleKeyDownContent = (event: ReactKeyboardEvent) => {\n // When the dropdown menu has focus, key strokes should give focus to the input component,\n // unless they're navigation keys (arrows and enter)\n const { key } = event;\n if (\n key === 'ArrowRight' ||\n key === 'ArrowLeft' ||\n key === 'ArrowDown' ||\n key === 'ArrowUp' ||\n key === 'Enter'\n ) {\n return;\n }\n\n inputRef.current.dispatchEvent(new KeyboardEvent('keydown', { key }));\n inputRef.current.focus();\n };\n\n const handleKeyDownMenuItem = (event: ReactKeyboardEvent) => {\n const { key } = event;\n if (highlightedBookId === selectedBookId) {\n if (key === 'Enter') {\n event.preventDefault();\n updateReference(selectedBookId, true, highlightedChapter);\n return;\n }\n\n let chapterOffSet = 0;\n if (key === 'ArrowRight') {\n if (highlightedChapter < fetchEndChapter(highlightedBookId)) {\n chapterOffSet = 1;\n } else {\n event.preventDefault();\n return;\n }\n } else if (key === 'ArrowLeft') {\n if (highlightedChapter > 1) {\n chapterOffSet = -1;\n } else {\n event.preventDefault();\n return;\n }\n } else if (key === 'ArrowDown') {\n chapterOffSet = 6;\n } else if (key === 'ArrowUp') {\n chapterOffSet = -6;\n }\n if (\n highlightedChapter + chapterOffSet <= 0 ||\n highlightedChapter + chapterOffSet > fetchEndChapter(highlightedBookId)\n ) {\n setHighlightedChapter(0);\n } else if (chapterOffSet !== 0) {\n setHighlightedChapter(highlightedChapter + chapterOffSet);\n event.preventDefault();\n }\n }\n };\n\n useEffect(() => {\n if (selectedBookId === highlightedBookId) {\n if (selectedBookId === Canon.bookNumberToId(scrRef.bookNum)) {\n setHighlightedChapter(scrRef.chapterNum);\n } else {\n setHighlightedChapter(1);\n }\n } else {\n setHighlightedChapter(0);\n }\n }, [highlightedBookId, scrRef.bookNum, scrRef.chapterNum, selectedBookId]);\n\n // The purpose of these useLayoutEffects and timeout is to delay the scroll just\n // enough so that the refs are defined and available when they are used after the timeout\n useLayoutEffect(() => {\n setIsContentOpenDelayed(isContentOpen);\n }, [isContentOpen]);\n\n useLayoutEffect(() => {\n const scrollTimeout = setTimeout(() => {\n if (isContentOpenDelayed && contentRef.current && menuItemRef.current) {\n const menuItemOffsetTop = menuItemRef.current.offsetTop;\n const scrollPosition = menuItemOffsetTop - SCROLL_OFFSET;\n contentRef.current.scrollTo({ top: scrollPosition, behavior: 'instant' });\n }\n }, 10);\n return () => {\n clearTimeout(scrollTimeout);\n };\n }, [isContentOpenDelayed]);\n\n return (\n
    \n \n \n {\n setSelectedBookId(Canon.bookNumberToId(scrRef.bookNum));\n setHighlightedBookId(Canon.bookNumberToId(scrRef.bookNum));\n setHighlightedChapter(scrRef.chapterNum > 0 ? scrRef.chapterNum : 0);\n setIsContentOpen(true);\n inputRef.current.focus();\n }}\n onFocus={() => {\n // Radix thinks we want to close because the input is being focused. Prevent that\n shouldPreventAutoClosing.current = true;\n }}\n handleSubmit={handleInputSubmit}\n placeholder={`${Canon.bookNumberToEnglishName(scrRef.bookNum)} ${scrRef.chapterNum}:${scrRef.verseNum}`}\n />\n \n \n console.log('sorting')}\n handleLocationHistory={() => console.log('location history')}\n handleBookmarks={() => console.log('bookmarks')}\n />\n {BOOK_TYPE_ARRAY.map(\n (bookType, bookTypeIndex) =>\n fetchFilteredBooks(bookType).length > 0 && (\n
    \n \n {BOOK_TYPE_LABELS[bookType]}\n \n\n {fetchFilteredBooks(bookType).map((bookId) => (\n
    \n updateReference(bookId, false)}\n isSelected={selectedBookId === bookId}\n handleHighlightBook={() => setHighlightedBookId(bookId)}\n handleKeyDown={handleKeyDownMenuItem}\n bookType={bookType}\n ref={(element: HTMLDivElement) => {\n if (selectedBookId === bookId) menuItemRef.current = element;\n }}\n >\n {\n setHighlightedChapter(chapterNumber);\n }}\n />\n \n
    \n ))}\n {BOOK_TYPE_ARRAY.length - 1 !== bookTypeIndex ? (\n \n ) : undefined}\n
    \n ),\n )}\n \n
    \n
    \n );\n}\n\nexport default BookChapterControl;\n","import React from 'react';\nimport { Slot } from '@radix-ui/react-slot';\nimport { cva, type VariantProps } from 'class-variance-authority';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport const buttonVariants = cva(\n 'pr-twp tw-inline-flex tw-items-center tw-justify-center tw-whitespace-nowrap tw-rounded-md tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-colors focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50',\n {\n variants: {\n variant: {\n default: 'tw-bg-primary tw-text-primary-foreground hover:tw-bg-primary/90',\n destructive: 'tw-bg-destructive tw-text-destructive-foreground hover:tw-bg-destructive/90',\n outline:\n 'tw-border tw-border-input tw-bg-background hover:tw-bg-accent hover:tw-text-accent-foreground',\n secondary: 'tw-bg-secondary tw-text-secondary-foreground hover:tw-bg-secondary/80',\n ghost: 'hover:tw-bg-accent hover:tw-text-accent-foreground',\n link: 'tw-text-primary tw-underline-offset-4 hover:tw-underline',\n },\n size: {\n default: 'tw-h-10 tw-px-4 tw-py-2',\n sm: 'tw-h-9 tw-rounded-md tw-px-3',\n lg: 'tw-h-11 tw-rounded-md tw-px-8',\n icon: 'tw-h-10 tw-w-10',\n },\n },\n defaultVariants: {\n variant: 'default',\n size: 'default',\n },\n },\n);\n\nexport interface ButtonProps\n extends React.ButtonHTMLAttributes,\n VariantProps {\n asChild?: boolean;\n}\n\nexport const Button = React.forwardRef(\n ({ className, variant, size, asChild = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'button';\n return (\n \n );\n },\n);\nButton.displayName = 'Button';\n","import React from 'react';\nimport * as LabelPrimitive from '@radix-ui/react-label';\nimport { cva, type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst labelVariants = cva(\n 'tw-text-sm tw-font-medium tw-leading-none peer-disabled:tw-cursor-not-allowed peer-disabled:tw-opacity-70',\n);\n\nexport const Label = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef & VariantProps\n>(({ className, ...props }, ref) => (\n \n));\nLabel.displayName = LabelPrimitive.Root.displayName;\n","import React from 'react';\nimport * as RadioGroupPrimitive from '@radix-ui/react-radio-group';\nimport { Circle } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst RadioGroup = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => {\n return (\n \n );\n});\nRadioGroup.displayName = RadioGroupPrimitive.Root.displayName;\n\nconst RadioGroupItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => {\n return (\n \n \n \n \n \n );\n});\nRadioGroupItem.displayName = RadioGroupPrimitive.Item.displayName;\n\nexport { RadioGroup, RadioGroupItem };\n","import React from 'react';\nimport * as PopoverPrimitive from '@radix-ui/react-popover';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Popover = PopoverPrimitive.Root;\n\nconst PopoverTrigger = PopoverPrimitive.Trigger;\n\nconst PopoverContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, align = 'center', sideOffset = 4, ...props }, ref) => (\n \n \n \n));\nPopoverContent.displayName = PopoverPrimitive.Content.displayName;\n\nexport { Popover, PopoverTrigger, PopoverContent };\n","import React from 'react';\nimport * as DialogPrimitive from '@radix-ui/react-dialog';\nimport { X } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Dialog = DialogPrimitive.Root;\n\nconst DialogTrigger = DialogPrimitive.Trigger;\n\nconst DialogPortal = DialogPrimitive.Portal;\n\nconst DialogClose = DialogPrimitive.Close;\n\nconst DialogOverlay = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nDialogOverlay.displayName = DialogPrimitive.Overlay.displayName;\n\nconst DialogContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, ...props }, ref) => (\n \n \n \n {children}\n \n \n Close\n \n \n \n));\nDialogContent.displayName = DialogPrimitive.Content.displayName;\n\nfunction DialogHeader({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nDialogHeader.displayName = 'DialogHeader';\n\nfunction DialogFooter({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nDialogFooter.displayName = 'DialogFooter';\n\nconst DialogTitle = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nDialogTitle.displayName = DialogPrimitive.Title.displayName;\n\nconst DialogDescription = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nDialogDescription.displayName = DialogPrimitive.Description.displayName;\n\nexport {\n Dialog,\n DialogPortal,\n DialogOverlay,\n DialogClose,\n DialogTrigger,\n DialogContent,\n DialogHeader,\n DialogFooter,\n DialogTitle,\n DialogDescription,\n};\n","import React from 'react';\nimport { type DialogProps } from '@radix-ui/react-dialog';\nimport { Command as CommandPrimitive } from 'cmdk';\nimport { Search } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Dialog, DialogContent } from '@/components/shadcn-ui/dialog';\n\nconst Command = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nCommand.displayName = CommandPrimitive.displayName;\n\ninterface CommandDialogProps extends DialogProps {}\n\nfunction CommandDialog({ children, ...props }: CommandDialogProps) {\n return (\n \n \n \n {children}\n \n \n \n );\n}\n\nconst CommandInput = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n
    \n \n \n
    \n));\n\nCommandInput.displayName = CommandPrimitive.Input.displayName;\n\nconst CommandList = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\n\nCommandList.displayName = CommandPrimitive.List.displayName;\n\nconst CommandEmpty = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>((props, ref) => (\n \n));\n\nCommandEmpty.displayName = CommandPrimitive.Empty.displayName;\n\nconst CommandGroup = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\n\nCommandGroup.displayName = CommandPrimitive.Group.displayName;\n\nconst CommandSeparator = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nCommandSeparator.displayName = CommandPrimitive.Separator.displayName;\n\nconst CommandItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\n\nCommandItem.displayName = CommandPrimitive.Item.displayName;\n\nfunction CommandShortcut({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nCommandShortcut.displayName = 'CommandShortcut';\n\nexport {\n Command,\n CommandDialog,\n CommandInput,\n CommandList,\n CommandEmpty,\n CommandGroup,\n CommandItem,\n CommandShortcut,\n CommandSeparator,\n};\n","import { useState } from 'react';\nimport { Check, ChevronsUpDown } from 'lucide-react';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport { Popover, PopoverContent, PopoverTrigger } from '@/components/shadcn-ui/popover';\nimport {\n Command,\n CommandEmpty,\n CommandInput,\n CommandItem,\n CommandList,\n} from '@/components/shadcn-ui/command';\nimport { PopoverProps } from '@radix-ui/react-popover';\n\nexport type ComboBoxLabelOption = { label: string };\nexport type ComboBoxOption = string | number | ComboBoxLabelOption;\n\nexport type ComboBoxProps = {\n /** Optional unique identifier */\n id?: string;\n /** Text label title for combobox */\n /** List of available options for the dropdown menu */\n options?: readonly T[];\n /** Additional css classes to help with unique styling of the combo box button */\n buttonClassName?: string;\n /** Additional css classes to help with unique styling of the combo box popover */\n popoverContentClassName?: string;\n /**\n * The selected value that the combo box currently holds. Must be shallow equal to one of the\n * options entries.\n */\n value?: T;\n /** Triggers when content of textfield is changed */\n onChange?: (newValue: T) => void;\n /** Used to determine the string value for a given option. */\n getOptionLabel?: (option: ComboBoxOption) => string;\n /** Text displayed on button if `value` is undefined */\n buttonPlaceholder?: string;\n /** Placeholder text for text field */\n textPlaceholder?: string;\n /** Text to display when no options match input */\n commandEmptyMessage?: string;\n /** Variant of button */\n buttonVariant?: ButtonProps['variant'];\n /** Text direction ltr or rtl */\n dir?: Direction;\n /** Optional boolean to set if trigger should be disabled */\n isDisabled?: boolean;\n} & PopoverProps;\n\ntype Direction = 'ltr' | 'rtl';\n\nfunction getOptionLabelDefault(option: ComboBoxOption): string {\n if (typeof option === 'string') {\n return option;\n }\n if (typeof option === 'number') {\n return option.toString();\n }\n return option.label;\n}\n\n/**\n * Autocomplete input and command palette with a list of suggestions.\n *\n * Thanks to Shadcn for heavy inspiration and documentation\n * https://ui.shadcn.com/docs/components/combobox\n */\nfunction ComboBox({\n id,\n options = [],\n buttonClassName,\n popoverContentClassName,\n value,\n onChange = () => {},\n getOptionLabel = getOptionLabelDefault,\n buttonPlaceholder = '',\n textPlaceholder = '',\n commandEmptyMessage = 'No option found',\n buttonVariant = 'outline',\n dir = 'ltr',\n isDisabled = false,\n ...props\n}: ComboBoxProps) {\n const [open, setOpen] = useState(false);\n\n return (\n \n \n \n \n {value ? getOptionLabel(value) : buttonPlaceholder}\n \n \n \n \n \n \n \n {commandEmptyMessage}\n \n {options.map((option) => (\n {\n onChange(option);\n setOpen(false);\n }}\n >\n \n {getOptionLabel(option)}\n \n ))}\n \n \n \n \n );\n}\n\nexport default ComboBox;\n","import { useMemo } from 'react';\nimport ComboBox from '@/components/basics/combo-box.component';\nimport { Label } from '@/components/shadcn-ui/label';\n\nexport type ChapterRangeSelectorProps = {\n startChapter: number;\n endChapter: number;\n handleSelectStartChapter: (chapter: number) => void;\n handleSelectEndChapter: (chapter: number) => void;\n isDisabled?: boolean;\n chapterCount: number;\n};\n\nexport default function ChapterRangeSelector({\n startChapter,\n endChapter,\n handleSelectStartChapter,\n handleSelectEndChapter,\n isDisabled = false,\n chapterCount,\n}: ChapterRangeSelectorProps) {\n const chapterOptions = useMemo(\n () => Array.from({ length: chapterCount }, (_, index) => index + 1),\n [chapterCount],\n );\n\n const onChangeStartChapter = (value: number) => {\n handleSelectStartChapter(value);\n if (value > endChapter) {\n handleSelectEndChapter(value);\n }\n };\n\n const onChangeEndChapter = (value: number) => {\n handleSelectEndChapter(value);\n if (value < startChapter) {\n handleSelectStartChapter(value);\n }\n };\n\n return (\n <>\n \n option.toString()}\n value={startChapter}\n />\n\n \n option.toString()}\n value={endChapter}\n />\n \n );\n}\n","import { Button } from '@/components/shadcn-ui/button';\nimport { Label } from '@/components/shadcn-ui/label';\nimport { RadioGroup, RadioGroupItem } from '@/components/shadcn-ui/radio-group';\nimport { Canon } from '@sillsdev/scripture';\nimport { LocalizedStringValue } from 'platform-bible-utils';\nimport { useState } from 'react';\nimport ChapterRangeSelector, {\n ChapterRangeSelectorProps,\n} from '../basics/chapter-range-selector.component';\n\nexport enum BookSelectionMode {\n CURRENT_BOOK = 'current book',\n CHOOSE_BOOKS = 'choose books',\n}\n\n/**\n * Object containing all keys used for localization in this component. If you're using this\n * component in an extension, you can pass it into the useLocalizedStrings hook to easily obtain the\n * localized strings and pass them into the localizedStrings prop of this component\n */\nexport const BOOK_SELECTOR_STRING_KEYS = Object.freeze([\n '%webView_bookSelector_currentBook%',\n '%webView_bookSelector_choose%',\n '%webView_bookSelector_chooseBooks%',\n] as const);\n\nexport type BookSelectorLocalizedStrings = {\n [localizedInventoryKey in (typeof BOOK_SELECTOR_STRING_KEYS)[number]]?: LocalizedStringValue;\n};\n\n/**\n * Gets the localized value for the provided key\n *\n * @param strings Object containing localized string\n * @param key Key for a localized string\n * @returns The localized value for the provided key, if available. Returns the key if no localized\n * value is available\n */\nconst localizeString = (\n strings: BookSelectorLocalizedStrings,\n key: keyof BookSelectorLocalizedStrings,\n) => {\n return strings[key] ?? key;\n};\n\ntype BookSelectorProps = ChapterRangeSelectorProps & {\n handleBookSelectionModeChange: (newMode: BookSelectionMode) => void;\n currentBookName: string;\n onSelectBooks: () => void;\n selectedBookIds: string[];\n localizedStrings: BookSelectorLocalizedStrings;\n};\n\nexport default function BookSelector({\n handleBookSelectionModeChange,\n currentBookName,\n onSelectBooks,\n selectedBookIds,\n chapterCount,\n endChapter,\n handleSelectEndChapter,\n startChapter,\n handleSelectStartChapter,\n localizedStrings,\n}: BookSelectorProps) {\n const currentBookText = localizeString(localizedStrings, '%webView_bookSelector_currentBook%');\n const chooseText = localizeString(localizedStrings, '%webView_bookSelector_choose%');\n const chooseBooksText = localizeString(localizedStrings, '%webView_bookSelector_chooseBooks%');\n\n const [bookSelectionMode, setBookSelectionMode] = useState(\n BookSelectionMode.CURRENT_BOOK,\n );\n\n const onSelectionModeChange = (newMode: BookSelectionMode) => {\n setBookSelectionMode(newMode);\n handleBookSelectionModeChange(newMode);\n };\n\n return (\n onSelectionModeChange(value as BookSelectionMode)}\n >\n
    \n
    \n
    \n \n \n
    \n \n
    \n \n
    \n
    \n
    \n
    \n \n \n
    \n \n onSelectBooks()}\n >\n {chooseText}\n \n
    \n
    \n \n );\n}\n","import { DropdownMenuTrigger } from '@radix-ui/react-dropdown-menu';\nimport { FilterIcon } from 'lucide-react';\nimport { Table } from '@tanstack/react-table';\n\nimport { Button } from '@/components/shadcn-ui/button';\nimport {\n DropdownMenu,\n DropdownMenuCheckboxItem,\n DropdownMenuContent,\n DropdownMenuLabel,\n DropdownMenuSeparator,\n} from '@/components/shadcn-ui/dropdown-menu';\n\ninterface DataTableViewOptionsProps {\n table: Table;\n}\n\nfunction DataTableViewOptions({ table }: DataTableViewOptionsProps) {\n return (\n \n \n \n \n \n Toggle columns\n \n {table\n .getAllColumns()\n .filter((column) => column.getCanHide())\n .map((column) => {\n return (\n column.toggleVisibility(!!value)}\n >\n {column.id}\n \n );\n })}\n \n \n );\n}\n\nexport default DataTableViewOptions;\n","import React from 'react';\nimport * as SelectPrimitive from '@radix-ui/react-select';\nimport { Check, ChevronDown, ChevronUp } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Select = SelectPrimitive.Root;\n\nconst SelectGroup = SelectPrimitive.Group;\n\nconst SelectValue = SelectPrimitive.Value;\n\nconst SelectTrigger = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, ...props }, ref) => (\n span]:tw-line-clamp-1',\n className,\n )}\n {...props}\n >\n {children}\n \n \n \n \n));\nSelectTrigger.displayName = SelectPrimitive.Trigger.displayName;\n\nconst SelectScrollUpButton = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n));\nSelectScrollUpButton.displayName = SelectPrimitive.ScrollUpButton.displayName;\n\nconst SelectScrollDownButton = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n));\nSelectScrollDownButton.displayName = SelectPrimitive.ScrollDownButton.displayName;\n\nconst SelectContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, position = 'popper', ...props }, ref) => (\n \n \n \n \n {children}\n \n \n \n \n));\nSelectContent.displayName = SelectPrimitive.Content.displayName;\n\nconst SelectLabel = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSelectLabel.displayName = SelectPrimitive.Label.displayName;\n\nconst SelectItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, ...props }, ref) => (\n \n \n \n \n \n \n\n {children}\n \n));\nSelectItem.displayName = SelectPrimitive.Item.displayName;\n\nconst SelectSeparator = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSelectSeparator.displayName = SelectPrimitive.Separator.displayName;\n\nexport {\n Select,\n SelectGroup,\n SelectValue,\n SelectTrigger,\n SelectContent,\n SelectLabel,\n SelectItem,\n SelectSeparator,\n SelectScrollUpButton,\n SelectScrollDownButton,\n};\n","import { ChevronLeftIcon, ChevronRightIcon, ArrowLeftIcon, ArrowRightIcon } from 'lucide-react';\nimport { Table } from '@tanstack/react-table';\n\nimport { Button } from '@/components/shadcn-ui/button';\nimport {\n Select,\n SelectContent,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\n\ninterface DataTablePaginationProps {\n table: Table;\n}\n\nfunction DataTablePagination({ table }: DataTablePaginationProps) {\n return (\n
    \n
    \n
    \n {table.getFilteredSelectedRowModel().rows.length} of{' '}\n {table.getFilteredRowModel().rows.length} row(s) selected\n
    \n
    \n

    Rows per page

    \n {\n table.setPageSize(Number(value));\n }}\n >\n \n \n \n \n {[10, 20, 30, 40, 50].map((pageSize) => (\n \n {pageSize}\n \n ))}\n \n \n
    \n
    \n Page {table.getState().pagination.pageIndex + 1} of {table.getPageCount()}\n
    \n
    \n table.setPageIndex(0)}\n disabled={!table.getCanPreviousPage()}\n >\n Go to first page\n \n \n table.previousPage()}\n disabled={!table.getCanPreviousPage()}\n >\n Go to previous page\n \n \n table.nextPage()}\n disabled={!table.getCanNextPage()}\n >\n Go to next page\n \n \n table.setPageIndex(table.getPageCount() - 1)}\n disabled={!table.getCanNextPage()}\n >\n Go to last page\n \n \n
    \n
    \n
    \n );\n}\n\nexport default DataTablePagination;\n","import React from 'react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Table = React.forwardRef<\n HTMLTableElement,\n React.HTMLAttributes & { stickyHeader?: boolean }\n>(({ className, stickyHeader, ...props }, ref) => (\n
    \n \n
    \n));\nTable.displayName = 'Table';\n\nconst TableHeader = React.forwardRef<\n HTMLTableSectionElement,\n React.HTMLAttributes & { stickyHeader?: boolean }\n>(({ className, stickyHeader, ...props }, ref) => (\n \n));\nTableHeader.displayName = 'TableHeader';\n\nconst TableBody = React.forwardRef<\n HTMLTableSectionElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableBody.displayName = 'TableBody';\n\nconst TableFooter = React.forwardRef<\n HTMLTableSectionElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n tr]:last:tw-border-b-0', className)}\n {...props}\n />\n));\nTableFooter.displayName = 'TableFooter';\n\nconst TableRow = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nTableRow.displayName = 'TableRow';\n\nconst TableHead = React.forwardRef<\n HTMLTableCellElement,\n React.ThHTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableHead.displayName = 'TableHead';\n\nconst TableCell = React.forwardRef<\n HTMLTableCellElement,\n React.TdHTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableCell.displayName = 'TableCell';\n\nconst TableCaption = React.forwardRef<\n HTMLTableCaptionElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableCaption.displayName = 'TableCaption';\n\nexport { Table, TableHeader, TableBody, TableFooter, TableHead, TableRow, TableCell, TableCaption };\n","import { useState } from 'react';\n\nimport {\n ColumnFiltersState,\n flexRender,\n getCoreRowModel,\n getFilteredRowModel,\n getPaginationRowModel,\n getSortedRowModel,\n SortingState,\n ColumnDef as TSColumnDef,\n Row as TSRow,\n RowSelectionState as TSRowSelectionState,\n SortDirection as TSSortDirection,\n Table as TSTable,\n useReactTable,\n VisibilityState,\n} from '@tanstack/react-table';\n\nimport DataTableViewOptions from '@/components/advanced/data-table/data-table-column-toggle.component';\nimport DataTablePagination from '@/components/advanced/data-table/data-table-pagination.component';\nimport { Button } from '@/components/shadcn-ui/button';\nimport {\n Table,\n TableBody,\n TableCell,\n TableHead,\n TableHeader,\n TableRow,\n} from '@/components/shadcn-ui/table';\n\nexport type ColumnDef = TSColumnDef;\nexport type RowContents = TSRow;\nexport type TableContents = TSTable;\nexport type SortDirection = TSSortDirection;\nexport type RowSelectionState = TSRowSelectionState;\n\ninterface DataTableProps {\n columns: ColumnDef[];\n data: TData[];\n enablePagination?: boolean;\n showPaginationControls?: boolean;\n showColumnVisibilityControls?: boolean;\n stickyHeader?: boolean;\n onRowClickHandler?: (row: RowContents, table: TableContents) => void;\n}\n\n/**\n * Feature-rich table component that infuses our basic shadcn-based Table component with features\n * from TanStack's React Table library\n */\nfunction DataTable({\n columns,\n data,\n enablePagination = false,\n showPaginationControls = false,\n showColumnVisibilityControls = false,\n stickyHeader = false,\n onRowClickHandler = () => {},\n}: DataTableProps) {\n const [sorting, setSorting] = useState([]);\n const [columnFilters, setColumnFilters] = useState([]);\n const [columnVisibility, setColumnVisibility] = useState({});\n const [rowSelection, setRowSelection] = useState({});\n\n const table = useReactTable({\n data,\n columns,\n getCoreRowModel: getCoreRowModel(),\n ...(enablePagination && { getPaginationRowModel: getPaginationRowModel() }),\n onSortingChange: setSorting,\n getSortedRowModel: getSortedRowModel(),\n onColumnFiltersChange: setColumnFilters,\n getFilteredRowModel: getFilteredRowModel(),\n onColumnVisibilityChange: setColumnVisibility,\n onRowSelectionChange: setRowSelection,\n state: {\n sorting,\n columnFilters,\n columnVisibility,\n rowSelection,\n },\n });\n\n return (\n
    \n {showColumnVisibilityControls && }\n \n \n {table.getHeaderGroups().map((headerGroup) => (\n \n {headerGroup.headers.map((header) => {\n return (\n \n {header.isPlaceholder\n ? undefined\n : flexRender(header.column.columnDef.header, header.getContext())}\n \n );\n })}\n \n ))}\n \n \n {table.getRowModel().rows?.length ? (\n table.getRowModel().rows.map((row) => (\n onRowClickHandler(row, table)}\n key={row.id}\n data-state={row.getIsSelected() && 'selected'}\n >\n {row.getVisibleCells().map((cell) => (\n \n {flexRender(cell.column.columnDef.cell, cell.getContext())}\n \n ))}\n \n ))\n ) : (\n \n \n No results.\n \n \n )}\n \n
    \n {enablePagination && (\n
    \n table.previousPage()}\n disabled={!table.getCanPreviousPage()}\n >\n Previous\n \n table.nextPage()}\n disabled={!table.getCanNextPage()}\n >\n Next\n \n
    \n )}\n {enablePagination && showPaginationControls && }\n
    \n );\n}\n\nexport default DataTable;\n","import {\n Table,\n TableBody,\n TableCell,\n TableHead,\n TableHeader,\n TableRow,\n} from '@/components/shadcn-ui/table';\nimport { Canon } from '@sillsdev/scripture';\nimport { deepEqual, LanguageStrings, ScriptureReference } from 'platform-bible-utils';\nimport { useMemo } from 'react';\nimport { InventoryItemOccurrence } from './inventory-utils';\n\n/** Props for the OccurrencesTable component */\ntype OccurrencesTableProps = {\n /** Data that contains scriptures references and snippets of scripture */\n occurrenceData: InventoryItemOccurrence[];\n /** Callback function that is executed when the scripture reference is changed */\n setScriptureReference: (scriptureReference: ScriptureReference) => void;\n /**\n * Object with all localized strings that the OccurrencesTable needs to work well across multiple\n * languages\n */\n localizedStrings: LanguageStrings;\n};\n\n/**\n * Table that shows occurrences of specified inventory item(s). The first column shows the related\n * scripture reference. The second column shows the snippet of scripture that contains the specified\n * inventory item\n */\nfunction OccurrencesTable({\n occurrenceData,\n setScriptureReference,\n localizedStrings,\n}: OccurrencesTableProps) {\n const referenceHeaderText =\n localizedStrings['%webView_inventory_occurrences_table_header_reference%'];\n const occurrenceHeaderText =\n localizedStrings['%webView_inventory_occurrences_table_header_occurrence%'];\n\n const occurrences: InventoryItemOccurrence[] = useMemo(() => {\n const uniqueOccurrences: InventoryItemOccurrence[] = [];\n\n occurrenceData.forEach((occurrence) => {\n if (!uniqueOccurrences.some((uniqueOccurrence) => deepEqual(uniqueOccurrence, occurrence))) {\n uniqueOccurrences.push(occurrence);\n }\n });\n\n return uniqueOccurrences;\n }, [occurrenceData]);\n\n return (\n \n \n \n {referenceHeaderText}\n {occurrenceHeaderText}\n \n \n \n {occurrences.length > 0 &&\n occurrences.map((occurrence) => (\n {\n setScriptureReference(occurrence.reference);\n }}\n >\n {`${Canon.bookNumberToEnglishName(occurrence.reference.bookNum)} ${occurrence.reference.chapterNum}:${occurrence.reference.verseNum}`}\n {occurrence.text}\n \n ))}\n \n
    \n );\n}\n\nexport default OccurrencesTable;\n","import React from 'react';\nimport * as CheckboxPrimitive from '@radix-ui/react-checkbox';\nimport { Check } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Checkbox = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n \n \n));\nCheckbox.displayName = CheckboxPrimitive.Root.displayName;\n\nexport default Checkbox;\n","import { Canon } from '@sillsdev/scripture';\nimport { ScriptureReference } from 'platform-bible-utils';\n\n/* #region Types */\n\n/**\n * Status of items that appear in inventories. 'approved' and 'unapproved' items are defined in the\n * project's `Settings.xml`. All other items are defined as 'unknown'\n */\nexport type Status = 'approved' | 'unapproved' | 'unknown';\n\n/** Occurrence of item in inventory. Primarily used by table that shows occurrences */\nexport type InventoryItemOccurrence = {\n /** Reference to scripture where the item appears */\n reference: ScriptureReference;\n /** Snippet of scripture that contains the occurrence */\n text: string;\n};\n\n/** Data structure that contains all information on an item that is shown in an inventory */\nexport type InventoryTableData = {\n /**\n * The item (e.g. a character in the characters inventory, a marker in the marker inventory) In\n * most cases the array will only have one element. In case of additional items (e.g. the\n * preceding marker in the markers check), the primary item should be stored in the first index.\n * To show additional items in the inventory, make sure to configure the `additionalItemsLabels`\n * prop for the Inventory component\n */\n items: string[];\n /** The number of times this item occurs in the selected scope */\n count: number;\n /** The status of this item (see documentation for `Status` type for more information) */\n status: Status;\n /** Occurrences of this item in the scripture text for the selected scope */\n occurrences: InventoryItemOccurrence[];\n};\n\n/* #endregion */\n\n/* #region Functions */\n\n/**\n * Splits USFM string into shorter line-like segments\n *\n * @param text A single (likely very large) USFM string\n * @returns An array containing the input text, split into shorter segments\n */\nexport const getLinesFromUSFM = (text: string) => {\n // Splits on (CR)LF, CR, \\v, \\c and \\id\n return text.split(/(?:\\r?\\n|\\r)|(?=(?:\\\\(?:v|c|id)))/g);\n};\n\n/**\n * Extracts chapter or verse number from USFM strings that start with a \\c or \\v marker\n *\n * @param text USFM string that is expected to start with \\c or \\v marker\n * @returns Chapter or verse number if one is found. Else returns 0.\n */\nexport const getNumberFromUSFM = (text: string): number | undefined => {\n // Captures all digits that follow \\v or \\c markers followed by whitespace located at the start of a string\n const regex = /^\\\\[vc]\\s+(\\d+)/;\n const match = text.match(regex);\n\n if (match) {\n return +match[1];\n }\n return undefined;\n};\n\n/**\n * Gets book ID from USFM string that starts with the \\id marker, and returns book number for it\n *\n * @param text USFM string that is expected to start with \\id marker\n * @returns Book number corresponding to the \\id marker in the input text. Returns 0 if no marker is\n * found or the marker is not valid\n */\nexport const getBookNumFromId = (text: string): number => {\n // Captures all digits that follow an \\id marker followed by whitespace located at the start of a string\n const match = text.match(/^\\\\id\\s+([A-Za-z]+)/);\n if (match) {\n return Canon.bookIdToNumber(match[1]);\n }\n return 0;\n};\n\n/**\n * Gets the status for an item, typically used in the Inventory component\n *\n * @param item The item for which the status is being requested\n * @param approvedItems Array of approved items, typically as defined in `Settings.xml`\n * @param unapprovedItems Array of unapproved items, typically as defined in `Settings.xml`\n * @returns The status for the specified item\n */\nexport const getStatusForItem = (\n item: string,\n approvedItems: string[],\n unapprovedItems: string[],\n): Status => {\n if (unapprovedItems.includes(item)) return 'unapproved';\n if (approvedItems.includes(item)) return 'approved';\n return 'unknown';\n};\n\n/* #endregion */\n","import React from 'react';\nimport * as TogglePrimitive from '@radix-ui/react-toggle';\nimport { cva, type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst toggleVariants = cva(\n 'pr-twp tw-inline-flex tw-items-center tw-justify-center tw-rounded-md tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-colors hover:tw-bg-muted hover:tw-text-muted-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50 data-[state=on]:tw-bg-accent data-[state=on]:tw-text-accent-foreground',\n {\n variants: {\n variant: {\n default: 'tw-bg-transparent',\n outline:\n 'tw-border tw-border-input tw-bg-transparent hover:tw-bg-accent hover:tw-text-accent-foreground',\n },\n size: {\n default: 'tw-h-10 tw-px-3',\n sm: 'tw-h-9 tw-px-2.5',\n lg: 'tw-h-11 tw-px-5',\n },\n },\n defaultVariants: {\n variant: 'default',\n size: 'default',\n },\n },\n);\n\nconst Toggle = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef & VariantProps\n>(({ className, variant, size, ...props }, ref) => (\n \n));\n\nToggle.displayName = TogglePrimitive.Root.displayName;\n\nexport { Toggle, toggleVariants };\n","import React from 'react';\nimport * as ToggleGroupPrimitive from '@radix-ui/react-toggle-group';\nimport { type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { toggleVariants } from '@/components/shadcn-ui/toggle';\n\nconst ToggleGroupContext = React.createContext>({\n size: 'default',\n variant: 'default',\n});\n\nconst ToggleGroup = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef &\n VariantProps\n>(({ className, variant, size, children, ...props }, ref) => (\n \n \n {children}\n \n \n));\n\nToggleGroup.displayName = ToggleGroupPrimitive.Root.displayName;\n\nconst ToggleGroupItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef &\n VariantProps\n>(({ className, children, variant, size, ...props }, ref) => {\n const context = React.useContext(ToggleGroupContext);\n\n return (\n \n {children}\n \n );\n});\n\nToggleGroupItem.displayName = ToggleGroupPrimitive.Item.displayName;\n\nexport { ToggleGroup, ToggleGroupItem };\n","import { ColumnDef, SortDirection } from '@/components/advanced/data-table/data-table.component';\nimport { Button } from '@/components/shadcn-ui/button';\nimport { ToggleGroup, ToggleGroupItem } from '@/components/shadcn-ui/toggle-group';\nimport {\n ArrowDownIcon,\n ArrowUpDownIcon,\n ArrowUpIcon,\n CircleCheckIcon,\n CircleHelpIcon,\n CircleXIcon,\n} from 'lucide-react';\nimport { ReactNode } from 'react';\nimport { InventoryTableData, Status } from './inventory-utils';\n\n/**\n * Gets an icon that indicates the current sorting direction based on the provided input\n *\n * @param sortDirection Sorting direction. Can be ascending ('asc'), descending ('desc') or false (\n * i.e. not sorted)\n * @returns The appropriate sorting icon for the provided sorting direction\n */\nconst getSortingIcon = (sortDirection: false | SortDirection): ReactNode => {\n if (sortDirection === 'asc') {\n return ;\n }\n if (sortDirection === 'desc') {\n return ;\n }\n return ;\n};\n\n/**\n * Function that creates the item column for inventories\n *\n * @param itemLabel Localized label for the item column (e.g. 'Character', 'Repeated Word', etc.)\n * @returns Column that shows the inventory items. Should be used with the DataTable component\n */\nexport const inventoryItemColumn = (itemLabel: string): ColumnDef => {\n return {\n accessorKey: 'item',\n accessorFn: (row: InventoryTableData) => row.items[0],\n header: ({ column }) => (\n \n ),\n };\n};\n\n/**\n * Function that creates the additional item columns for inventories\n *\n * @param additionalItemLabel Localized label for the additional item column (e.g. 'Preceding\n * Marker')\n * @param additionalItemIndex Index that locates the desired item in the items array of the\n * inventory\n * @returns Column that shows additional inventory items. Should be used with the DataTable\n * component\n */\nexport const inventoryAdditionalItemColumn = (\n additionalItemLabel: string,\n additionalItemIndex: number,\n): ColumnDef => {\n return {\n accessorKey: `item${additionalItemIndex}`,\n accessorFn: (row: InventoryTableData) => row.items[additionalItemIndex],\n header: ({ column }) => (\n \n ),\n };\n};\n\n/**\n * Function that creates the count column for inventories. Should be used with the DataTable\n * component.\n *\n * @param itemLabel Localized label for the count column\n * @returns Column that shows the number of occurrences of the related inventory items\n */\nexport const inventoryCountColumn = (countLabel: string): ColumnDef => {\n return {\n accessorKey: 'count',\n header: ({ column }) => (\n
    \n \n
    \n ),\n cell: ({ row }) =>
    {row.getValue('count')}
    ,\n };\n};\n\n/**\n * Function that updates project settings when status for item(s) changes\n *\n * @param changedItems Array of items for which the status is being updated\n * @param newStatus The status that the items are being given\n * @param approvedItems Array of currently approved items\n * @param onApprovedItemsChange Callback function that stores the updated list of approved items\n * @param unapprovedItems Array of currently unapproved items\n * @param onUnapprovedItemsChange Callback function that stores the updated list of unapproved items\n */\nconst statusChangeHandler = (\n changedItems: string[],\n newStatus: Status,\n approvedItems: string[],\n onApprovedItemsChange: (items: string[]) => void,\n unapprovedItems: string[],\n onUnapprovedItemsChange: (items: string[]) => void,\n) => {\n let newApprovedItems: string[] = [...approvedItems];\n changedItems.forEach((item) => {\n if (newStatus === 'approved') {\n if (!newApprovedItems.includes(item)) {\n newApprovedItems.push(item);\n }\n } else {\n newApprovedItems = newApprovedItems.filter((validItem) => validItem !== item);\n }\n });\n onApprovedItemsChange(newApprovedItems);\n\n let newUnapprovedItems: string[] = [...unapprovedItems];\n changedItems.forEach((item) => {\n if (newStatus === 'unapproved') {\n if (!newUnapprovedItems.includes(item)) {\n newUnapprovedItems.push(item);\n }\n } else {\n newUnapprovedItems = newUnapprovedItems.filter((unapprovedItem) => unapprovedItem !== item);\n }\n });\n onUnapprovedItemsChange(newUnapprovedItems);\n};\n\n/**\n * Function that creates the status column for inventories. Should be used with the DataTable\n * component.\n *\n * @param statusLabel Localized label for the status column\n * @param approvedItems Array of approved items, typically as defined in `Settings.xml`\n * @param onApprovedItemsChange Callback function that stores the updated list of approved items\n * @param unapprovedItems Array of unapproved items, typically as defined in `Settings.xml`\n * @param onUnapprovedItemsChange Callback function that stores the updated list of unapproved items\n * @returns Column that shows the status buttons for the related inventory item. The button for the\n * current status of the item is selected\n */\nexport const inventoryStatusColumn = (\n statusLabel: string,\n approvedItems: string[],\n onApprovedItemsChange: (items: string[]) => void,\n unapprovedItems: string[],\n onUnapprovedItemsChange: (items: string[]) => void,\n): ColumnDef => {\n return {\n accessorKey: 'status',\n header: ({ column }) => {\n return (\n
    \n \n
    \n );\n },\n cell: ({ row }) => {\n const status: Status = row.getValue('status');\n const item: string = row.getValue('item');\n return (\n \n \n statusChangeHandler(\n [item],\n 'approved',\n approvedItems,\n onApprovedItemsChange,\n unapprovedItems,\n onUnapprovedItemsChange,\n )\n }\n value=\"approved\"\n >\n \n \n \n statusChangeHandler(\n [item],\n 'unapproved',\n approvedItems,\n onApprovedItemsChange,\n unapprovedItems,\n onUnapprovedItemsChange,\n )\n }\n value=\"unapproved\"\n >\n \n \n \n statusChangeHandler(\n [item],\n 'unknown',\n approvedItems,\n onApprovedItemsChange,\n unapprovedItems,\n onUnapprovedItemsChange,\n )\n }\n value=\"unknown\"\n >\n \n \n \n );\n },\n };\n};\n","import DataTable, {\n ColumnDef,\n RowContents,\n RowSelectionState,\n TableContents,\n} from '@/components/advanced/data-table/data-table.component';\nimport OccurrencesTable from '@/components/advanced/inventory/occurrences-table.component';\nimport Checkbox from '@/components/shadcn-ui/checkbox';\nimport { Input } from '@/components/shadcn-ui/input';\nimport { Label } from '@/components/shadcn-ui/label';\nimport {\n Select,\n SelectContent,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\nimport {\n deepEqual,\n LocalizedStringValue,\n ScriptureReference,\n substring,\n} from 'platform-bible-utils';\nimport { useEffect, useMemo, useState } from 'react';\nimport {\n getBookNumFromId,\n getLinesFromUSFM,\n getNumberFromUSFM,\n getStatusForItem,\n InventoryItemOccurrence,\n InventoryTableData,\n Status,\n} from './inventory-utils';\nimport { inventoryAdditionalItemColumn } from './inventory-columns';\n\n/**\n * Object containing all keys used for localization in this component. If you're using this\n * component in an extension, you can pass it into the useLocalizedStrings hook to easily obtain the\n * localized strings and pass them into the localizedStrings prop of this component\n */\nexport const INVENTORY_STRING_KEYS = Object.freeze([\n '%webView_inventory_all%',\n '%webView_inventory_approved%',\n '%webView_inventory_unapproved%',\n '%webView_inventory_unknown%',\n '%webView_inventory_scope_currentBook%',\n '%webView_inventory_scope_chapter%',\n '%webView_inventory_scope_verse%',\n '%webView_inventory_filter_text%',\n '%webView_inventory_show_additional_items%',\n '%webView_inventory_occurrences_table_header_reference%',\n '%webView_inventory_occurrences_table_header_occurrence%',\n] as const);\n\nexport type InventoryLocalizedStrings = {\n [localizedInventoryKey in (typeof INVENTORY_STRING_KEYS)[number]]?: LocalizedStringValue;\n};\n\n/** Scope of scripture that the inventory can operate on */\nexport type Scope = 'book' | 'chapter' | 'verse';\n\n/** Status values that the status filter can select from */\ntype StatusFilter = Status | 'all';\n\n/** Text labels for the inventory columns and the control components of additional inventory items */\ntype AdditionalItemsLabels = {\n checkboxText?: string;\n tableHeaders?: string[];\n};\n\n/**\n * Filters data that is shown in the DataTable section of the Inventory\n *\n * @param itemData All inventory items and their related information\n * @param statusFilter Allows filtering by status (i.e. show all items, or only items that are\n * 'approved', 'unapproved' or 'unknown')\n * @param textFilter Allows filtering by text. All items that include the filter text will be\n * selected.\n * @returns Array of items and their related information that are matched by the specified filters\n */\nconst filterItemData = (\n itemData: InventoryTableData[],\n statusFilter: StatusFilter,\n textFilter: string,\n): InventoryTableData[] => {\n let filteredItemData: InventoryTableData[] = itemData;\n\n if (statusFilter !== 'all') {\n filteredItemData = filteredItemData.filter(\n (item) =>\n (statusFilter === 'approved' && item.status === 'approved') ||\n (statusFilter === 'unapproved' && item.status === 'unapproved') ||\n (statusFilter === 'unknown' && item.status === 'unknown'),\n );\n }\n\n if (textFilter !== '')\n filteredItemData = filteredItemData.filter((item) => item.items[0].includes(textFilter));\n\n return filteredItemData;\n};\n\n/**\n * Turns array of strings into array of inventory items, along with their count and status\n *\n * @param text The source scripture text that is searched for inventory items\n * @param scriptureRef The scripture reference that the application is currently set to\n * @param approvedItems Array of approved items, typically as defined in `Settings.xml`\n * @param unapprovedItems Array of unapproved items, typically as defined in `Settings.xml`\n * @param itemRegex Regular expression that describes what items this Inventory should extract from\n * the provided scripture text\n * @returns Array of inventory items, along with their count and status\n */\nconst createTableData = (\n text: string | undefined,\n scriptureRef: ScriptureReference,\n approvedItems: string[],\n unapprovedItems: string[],\n itemRegex: RegExp,\n): InventoryTableData[] => {\n if (!text) return [];\n\n const tableData: InventoryTableData[] = [];\n\n let currentBook: number | undefined = scriptureRef.bookNum;\n let currentChapter: number | undefined = scriptureRef.chapterNum;\n let currentVerse: number | undefined = scriptureRef.verseNum;\n\n const lines = getLinesFromUSFM(text);\n\n lines.forEach((line: string) => {\n if (line.startsWith('\\\\id')) {\n currentBook = getBookNumFromId(line);\n currentChapter = 0;\n currentVerse = 0;\n }\n if (line.startsWith('\\\\c')) {\n currentChapter = getNumberFromUSFM(line);\n currentVerse = 0;\n }\n if (line.startsWith('\\\\v')) {\n currentVerse = getNumberFromUSFM(line);\n if (currentChapter === 0) {\n currentChapter = scriptureRef.chapterNum;\n }\n }\n\n let match: RegExpExecArray | undefined = itemRegex.exec(line) ?? undefined;\n while (match) {\n const items: string[] = [];\n match.forEach((item) => items.push(item));\n const itemIndex = match.index;\n const existingItem = tableData.find((tableEntry) => deepEqual(tableEntry.items, items));\n const newReference: InventoryItemOccurrence = {\n reference: {\n bookNum: currentBook !== undefined ? currentBook : -1,\n chapterNum: currentChapter !== undefined ? currentChapter : -1,\n verseNum: currentVerse !== undefined ? currentVerse : -1,\n },\n text: substring(line, Math.max(0, itemIndex - 25), Math.min(itemIndex + 25, line.length)),\n };\n if (existingItem) {\n existingItem.count += 1;\n existingItem.occurrences.push(newReference);\n } else {\n const newItem: InventoryTableData = {\n items,\n count: 1,\n status: getStatusForItem(items[0], approvedItems, unapprovedItems),\n occurrences: [newReference],\n };\n tableData.push(newItem);\n }\n\n match = itemRegex.exec(line) ?? undefined;\n }\n });\n\n return tableData;\n};\n\n/**\n * Gets the localized value for the provided key\n *\n * @param strings Object containing localized string\n * @param key Key for a localized string\n * @returns The localized value for the provided key, if available. Returns the key if no localized\n * value is available\n */\nconst localizeString = (\n strings: InventoryLocalizedStrings,\n key: keyof InventoryLocalizedStrings,\n) => {\n return strings[key] ?? key;\n};\n\n/** Props for the Inventory component */\ntype InventoryProps = {\n /** The scripture reference that the application is currently set to */\n scriptureReference: ScriptureReference;\n /** Callback function that is executed when the scripture reference is changed */\n setScriptureReference: (scriptureReference: ScriptureReference) => void;\n /**\n * Object with all localized strings that the Inventory needs to work well across multiple\n * languages. When using this component with Platform.Bible, you can import\n * `INVENTORY_STRING_KEYS` from this library, pass it in to the Platform's localization hook, and\n * pass the localized keys that are returned by the hook into this prop.\n */\n localizedStrings: InventoryLocalizedStrings;\n /**\n * The logic that finds the desired items in the source text. This can either be a Regular\n * expression that captures one or multiple items (preferred), or a custom function that builds\n * and return an InventoryDataTable[] manually. Note: In case the logic captures more than one\n * item (i.e. InventoryTableData.items has a length greater than 1), you must provide text labels\n * for the related columns and control elements to show by setting the `additionalItemsLabels`\n * prop\n */\n extractItems:\n | RegExp\n | ((\n text: string | undefined,\n scriptureRef: ScriptureReference,\n approvedItems: string[],\n unapprovedItems: string[],\n ) => InventoryTableData[]);\n /**\n * Text labels for control elements and additional column headers in case your Inventory has more\n * than one item to show (e.g. The 'Preceding Marker' in the Markers Inventory)\n */\n additionalItemsLabels?: AdditionalItemsLabels;\n /** Array of approved items, typically as defined in `Settings.xml` */\n approvedItems: string[];\n /** Array of unapproved items, typically as defined in `Settings.xml` */\n unapprovedItems: string[];\n /** The source scripture text that is searched for in inventory items */\n text: string | undefined;\n /** Scope of scripture that the inventory will operate on */\n scope: Scope;\n /** Callback function that is executed when the scope is changed from the Inventory */\n onScopeChange: (scope: Scope) => void;\n /**\n * Column definitions for the Inventory data table. The most commonly used column definitions are\n * pre-configured for your convenience and can be imported (e.g. inventoryItemColumn,\n * inventoryAdditionalItemColumn inventoryCountColumn, and inventoryStatusColumn). If you need any\n * other columns you can add these yourself\n */\n columns: ColumnDef[];\n};\n\n/** Inventory component that is used to view and control the status of provided project settings */\nexport default function Inventory({\n scriptureReference,\n setScriptureReference,\n localizedStrings,\n extractItems,\n additionalItemsLabels,\n approvedItems,\n unapprovedItems,\n text,\n scope,\n onScopeChange,\n columns,\n}: InventoryProps) {\n const allItemsText = localizeString(localizedStrings, '%webView_inventory_all%');\n const approvedItemsText = localizeString(localizedStrings, '%webView_inventory_approved%');\n const unapprovedItemsText = localizeString(localizedStrings, '%webView_inventory_unapproved%');\n const unknownItemsText = localizeString(localizedStrings, '%webView_inventory_unknown%');\n const scopeBookText = localizeString(localizedStrings, '%webView_inventory_scope_currentBook%');\n const scopeChapterText = localizeString(localizedStrings, '%webView_inventory_scope_chapter%');\n const scopeVerseText = localizeString(localizedStrings, '%webView_inventory_scope_verse%');\n const filterText = localizeString(localizedStrings, '%webView_inventory_filter_text%');\n const showAdditionalItemsText = localizeString(\n localizedStrings,\n '%webView_inventory_show_additional_items%',\n );\n\n const [showAdditionalItems, setShowAdditionalItems] = useState(false);\n const [statusFilter, setStatusFilter] = useState('all');\n const [textFilter, setTextFilter] = useState('');\n const [selectedItem, setSelectedItem] = useState([]);\n\n const tableData: InventoryTableData[] = useMemo(() => {\n if (!text) return [];\n if (extractItems instanceof RegExp)\n return createTableData(\n text,\n scriptureReference,\n approvedItems,\n unapprovedItems,\n extractItems,\n );\n return extractItems(text, scriptureReference, approvedItems, unapprovedItems);\n }, [text, extractItems, scriptureReference, approvedItems, unapprovedItems]);\n\n const reducedTableData: InventoryTableData[] = useMemo(() => {\n if (showAdditionalItems) return tableData;\n\n const newTableData: InventoryTableData[] = [];\n\n tableData.forEach((tableEntry) => {\n const firstItem = tableEntry.items[0];\n\n const existingEntry = newTableData.find(\n (newTableEntry) => newTableEntry.items[0] === firstItem,\n );\n\n if (existingEntry) {\n existingEntry.count += tableEntry.count;\n existingEntry.occurrences = existingEntry.occurrences.concat(tableEntry.occurrences);\n } else {\n newTableData.push({\n items: [firstItem],\n count: tableEntry.count,\n occurrences: tableEntry.occurrences,\n status: tableEntry.status,\n });\n }\n });\n\n return newTableData;\n }, [showAdditionalItems, tableData]);\n\n const filteredTableData: InventoryTableData[] = useMemo(() => {\n return filterItemData(reducedTableData, statusFilter, textFilter);\n }, [reducedTableData, statusFilter, textFilter]);\n\n const allColumns: ColumnDef[] = useMemo(() => {\n if (!showAdditionalItems) return columns;\n\n const numberOfAdditionalItems = additionalItemsLabels?.tableHeaders?.length;\n if (!numberOfAdditionalItems) return columns;\n\n const additionalColumns: ColumnDef[] = [];\n\n for (let index = 0; index < numberOfAdditionalItems; index++) {\n additionalColumns.push(\n inventoryAdditionalItemColumn(\n additionalItemsLabels?.tableHeaders?.[index] || 'Additional Item',\n index + 1,\n ),\n );\n }\n\n return [...additionalColumns, ...columns];\n }, [additionalItemsLabels?.tableHeaders, columns, showAdditionalItems]);\n\n useEffect(() => {\n setSelectedItem([]);\n }, [filteredTableData]);\n\n const rowClickHandler = (\n row: RowContents,\n table: TableContents,\n ) => {\n table.setRowSelection(() => {\n const newSelection: RowSelectionState = {};\n newSelection[row.index] = true;\n return newSelection;\n });\n\n setSelectedItem(row.original.items);\n };\n\n const handleScopeChange = (value: string) => {\n if (value === 'book' || value === 'chapter' || value === 'verse') {\n onScopeChange(value);\n } else {\n throw new Error(`Invalid scope value: ${value}`);\n }\n };\n\n const handleStatusFilterChange = (value: string) => {\n if (value === 'all' || value === 'approved' || value === 'unapproved' || value === 'unknown') {\n setStatusFilter(value);\n } else {\n throw new Error(`Invalid status filter value: ${value}`);\n }\n };\n\n const occurrenceData: InventoryItemOccurrence[] = useMemo(() => {\n if (reducedTableData.length === 0 || selectedItem.length === 0) return [];\n const occurrence = reducedTableData.filter((tableEntry: InventoryTableData) => {\n return deepEqual(\n showAdditionalItems ? tableEntry.items : [tableEntry.items[0]],\n selectedItem,\n );\n });\n if (occurrence.length > 1) throw new Error('Selected item is not unique');\n return occurrence[0].occurrences;\n }, [selectedItem, showAdditionalItems, reducedTableData]);\n\n return (\n
    \n
    \n handleStatusFilterChange(value)}\n defaultValue={statusFilter}\n >\n \n \n \n \n {allItemsText}\n {approvedItemsText}\n {unapprovedItemsText}\n {unknownItemsText}\n \n \n \n {\n setTextFilter(event.target.value);\n }}\n />\n {additionalItemsLabels && (\n
    \n {\n setSelectedItem([]);\n setShowAdditionalItems(checked);\n }}\n />\n \n
    \n )}\n
    \n
    \n \n
    \n {occurrenceData.length > 0 && (\n
    \n \n
    \n )}\n
    \n );\n}\n","import { Input } from '@/components/shadcn-ui/input';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { useState } from 'react';\n\nexport type SearchBarProps = {\n className?: string;\n /**\n * Callback fired to handle the search query when button pressed\n *\n * @param searchQuery\n */\n onSearch: (searchQuery: string) => void;\n\n /** Optional string that appears in the search bar without a search string */\n placeholder?: string;\n\n /** Optional boolean to set the input base to full width */\n isFullWidth?: boolean;\n};\n\nexport default function SearchBar({\n className,\n onSearch,\n placeholder,\n isFullWidth,\n}: SearchBarProps) {\n const [searchQuery, setSearchQuery] = useState('');\n\n const handleInputChange = (searchString: string) => {\n setSearchQuery(searchString);\n onSearch(searchString);\n };\n\n return (\n handleInputChange(e.target.value)}\n />\n );\n}\n","// adapted from: https://github.com/shadcn-ui/ui/discussions/752\n\n'use client';\n\nimport { TabsContentProps, TabsListProps, TabsTriggerProps } from '@/components/shadcn-ui/tabs';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport * as TabsPrimitive from '@radix-ui/react-tabs';\nimport React from 'react';\n\nexport type VerticalTabsProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport type LeftTabsTriggerProps = TabsTriggerProps & {\n value: string;\n ref?: React.Ref;\n};\n\nexport const VerticalTabs = React.forwardRef<\n React.ElementRef,\n VerticalTabsProps\n>(({ className, ...props }, ref) => (\n \n));\n\nVerticalTabs.displayName = TabsPrimitive.List.displayName;\n\nexport const VerticalTabsList = React.forwardRef<\n React.ElementRef,\n TabsListProps\n>(({ className, ...props }, ref) => (\n \n));\nVerticalTabsList.displayName = TabsPrimitive.List.displayName;\n\nexport const VerticalTabsTrigger = React.forwardRef<\n React.ElementRef,\n LeftTabsTriggerProps\n>(({ className, ...props }, ref) => (\n \n));\n\nexport const VerticalTabsContent = React.forwardRef<\n React.ElementRef,\n TabsContentProps\n>(({ className, ...props }, ref) => (\n \n));\nVerticalTabsContent.displayName = TabsPrimitive.Content.displayName;\n","import SearchBar from '@/components/basics/search-bar.component';\nimport {\n VerticalTabs,\n VerticalTabsContent,\n VerticalTabsList,\n VerticalTabsTrigger,\n} from '@/components/basics/tabs-vertical';\nimport { ReactNode } from 'react';\n\nexport type TabKeyValueContent = {\n key: string;\n value: string;\n content: ReactNode;\n};\n\nexport type TabNavigationContentSearchProps = {\n /** List of values and keys for each tab this component should provide */\n tabList: TabKeyValueContent[];\n\n /** Handler to run when the value of the search bar changes */\n onSearch: (searchQuery: string) => void;\n\n /** Optional placeholder for the search bar */\n searchPlaceholder?: string;\n\n /** Optional title to include in the header */\n headerTitle?: string;\n\n /** Optional flag to make the search bar appear full width */\n isSearchBarFullWidth?: boolean;\n\n /** Text direction ltr or rtl */\n direction?: 'ltr' | 'rtl';\n};\n\nexport default function TabNavigationContentSearch({\n tabList,\n onSearch,\n searchPlaceholder,\n headerTitle,\n isSearchBarFullWidth = false,\n direction = 'ltr',\n}: TabNavigationContentSearchProps) {\n return (\n
    \n
    \n {headerTitle ?

    {headerTitle}

    : ''}\n \n
    \n \n \n {tabList.map((tab) => (\n \n {tab.value}\n \n ))}\n \n {tabList.map((tab) => (\n \n {tab.content}\n \n ))}\n \n
    \n );\n}\n","import React from 'react';\nimport * as SeparatorPrimitive from '@radix-ui/react-separator';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Separator = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, orientation = 'horizontal', decorative = true, ...props }, ref) => (\n \n));\nSeparator.displayName = SeparatorPrimitive.Root.displayName;\n\nexport { Separator };\n","'use client';\n\nimport * as React from 'react';\nimport * as SheetPrimitive from '@radix-ui/react-dialog';\nimport { cva, type VariantProps } from 'class-variance-authority';\nimport { X } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Sheet = SheetPrimitive.Root;\n\nconst SheetTrigger = SheetPrimitive.Trigger;\n\nconst SheetClose = SheetPrimitive.Close;\n\nconst SheetPortal = SheetPrimitive.Portal;\n\nconst SheetOverlay = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSheetOverlay.displayName = SheetPrimitive.Overlay.displayName;\n\nconst sheetVariants = cva(\n 'pr-twp tw-fixed tw-z-50 tw-gap-4 tw-bg-background tw-p-6 tw-shadow-lg tw-transition tw-ease-in-out data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-duration-300 data-[state=open]:tw-duration-500',\n {\n variants: {\n side: {\n top: 'tw-inset-x-0 tw-top-0 tw-border-b data-[state=closed]:tw-slide-out-to-top data-[state=open]:tw-slide-in-from-top',\n bottom:\n 'tw-inset-x-0 tw-bottom-0 tw-border-t data-[state=closed]:tw-slide-out-to-bottom data-[state=open]:tw-slide-in-from-bottom',\n left: 'tw-inset-y-0 tw-left-0 tw-h-full tw-w-3/4 tw-border-r data-[state=closed]:tw-slide-out-to-left data-[state=open]:tw-slide-in-from-left sm:tw-max-w-sm',\n right:\n 'tw-inset-y-0 tw-right-0 tw-h-full tw-w-3/4 tw- tw-border-l data-[state=closed]:tw-slide-out-to-right data-[state=open]:tw-slide-in-from-right sm:tw-max-w-sm',\n },\n },\n defaultVariants: {\n side: 'right',\n },\n },\n);\n\ninterface SheetContentProps\n extends React.ComponentPropsWithoutRef,\n VariantProps {}\n\nconst SheetContent = React.forwardRef<\n React.ElementRef,\n SheetContentProps\n>(({ side = 'right', className, children, ...props }, ref) => (\n \n \n \n {children}\n \n \n Close\n \n \n \n));\nSheetContent.displayName = SheetPrimitive.Content.displayName;\n\nfunction SheetHeader({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nSheetHeader.displayName = 'SheetHeader';\n\nfunction SheetFooter({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nSheetFooter.displayName = 'SheetFooter';\n\nconst SheetTitle = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSheetTitle.displayName = SheetPrimitive.Title.displayName;\n\nconst SheetDescription = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSheetDescription.displayName = SheetPrimitive.Description.displayName;\n\nexport {\n Sheet,\n SheetPortal,\n SheetOverlay,\n SheetTrigger,\n SheetClose,\n SheetContent,\n SheetHeader,\n SheetFooter,\n SheetTitle,\n SheetDescription,\n};\n","import React from 'react';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nfunction Skeleton({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\n\nexport { Skeleton };\n","import React from 'react';\nimport * as TooltipPrimitive from '@radix-ui/react-tooltip';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst TooltipProvider = TooltipPrimitive.Provider;\n\nconst Tooltip = TooltipPrimitive.Root;\n\nconst TooltipTrigger = TooltipPrimitive.Trigger;\n\nconst TooltipContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, sideOffset = 4, ...props }, ref) => (\n \n));\nTooltipContent.displayName = TooltipPrimitive.Content.displayName;\n\nexport { Tooltip, TooltipTrigger, TooltipContent, TooltipProvider };\n","import * as React from 'react';\n\nconst MOBILE_BREAKPOINT = 768;\n\nexport default function useIsMobile() {\n const [isMobile, setIsMobile] = React.useState(undefined);\n\n React.useEffect(() => {\n const mql = window.matchMedia(`(max-width: ${MOBILE_BREAKPOINT - 1}px)`);\n const onChange = () => {\n setIsMobile(window.innerWidth < MOBILE_BREAKPOINT);\n };\n mql.addEventListener('change', onChange);\n setIsMobile(window.innerWidth < MOBILE_BREAKPOINT);\n return () => mql.removeEventListener('change', onChange);\n }, []);\n\n return !!isMobile;\n}\n","import React from 'react';\nimport { Slot } from '@radix-ui/react-slot';\nimport { VariantProps, cva } from 'class-variance-authority';\nimport { PanelLeft } from 'lucide-react';\n\nimport { Button } from '@/components/shadcn-ui/button';\nimport { Input } from '@/components/shadcn-ui/input';\nimport { Separator } from '@/components/shadcn-ui/separator';\nimport { Sheet, SheetContent } from '@/components/shadcn-ui/sheet';\nimport { Skeleton } from '@/components/shadcn-ui/skeleton';\nimport {\n Tooltip,\n TooltipContent,\n TooltipProvider,\n TooltipTrigger,\n} from '@/components/shadcn-ui/tooltip';\nimport useIsMobile from '@/components/hooks/use-mobile';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst SIDEBAR_COOKIE_NAME = 'sidebar:state';\nconst SIDEBAR_COOKIE_MAX_AGE = 60 * 60 * 24 * 7;\nconst SIDEBAR_WIDTH = '16rem';\nconst SIDEBAR_WIDTH_MOBILE = '18rem';\nconst SIDEBAR_WIDTH_ICON = '3rem';\nconst SIDEBAR_KEYBOARD_SHORTCUT = 'b';\n\ntype SidebarContextProps = {\n state: 'expanded' | 'collapsed';\n open: boolean;\n setOpen: (open: boolean) => void;\n openMobile: boolean;\n setOpenMobile: (open: boolean) => void;\n isMobile: boolean;\n toggleSidebar: () => void;\n};\n\nconst SidebarContext = React.createContext(undefined);\n\nfunction useSidebar() {\n const context = React.useContext(SidebarContext);\n if (!context) {\n throw new Error('useSidebar must be used within a SidebarProvider.');\n }\n\n return context;\n}\n\nconst SidebarProvider = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & {\n defaultOpen?: boolean;\n open?: boolean;\n onOpenChange?: (open: boolean) => void;\n }\n>(\n (\n {\n defaultOpen = true,\n open: openProp,\n onOpenChange: setOpenProp,\n className,\n style,\n children,\n ...props\n },\n ref,\n ) => {\n const isMobile = useIsMobile();\n const [openMobile, setOpenMobile] = React.useState(false);\n\n // This is the internal state of the sidebar.\n // We use openProp and setOpenProp for control from outside the component.\n const [_open, _setOpen] = React.useState(defaultOpen);\n const isOpen = openProp ?? _open;\n const setOpen = React.useCallback(\n (value: boolean | ((value: boolean) => boolean)) => {\n const openState = typeof value === 'function' ? value(isOpen) : value;\n if (setOpenProp) {\n setOpenProp(openState);\n } else {\n _setOpen(openState);\n }\n\n // This sets the cookie to keep the sidebar state.\n document.cookie = `${SIDEBAR_COOKIE_NAME}=${openState}; path=/; max-age=${SIDEBAR_COOKIE_MAX_AGE}`;\n },\n [setOpenProp, isOpen],\n );\n\n // Helper to toggle the sidebar.\n const toggleSidebar = React.useCallback(() => {\n return isMobile ? setOpenMobile((open) => !open) : setOpen((open) => !open);\n }, [isMobile, setOpen, setOpenMobile]);\n\n // Adds a keyboard shortcut to toggle the sidebar.\n React.useEffect(() => {\n const handleKeyDown = (event: KeyboardEvent) => {\n if (event.key === SIDEBAR_KEYBOARD_SHORTCUT && (event.metaKey || event.ctrlKey)) {\n event.preventDefault();\n toggleSidebar();\n }\n };\n\n window.addEventListener('keydown', handleKeyDown);\n return () => window.removeEventListener('keydown', handleKeyDown);\n }, [toggleSidebar]);\n\n // We add a state so that we can do data-state=\"expanded\" or \"collapsed\".\n // This makes it easier to style the sidebar with Tailwind classes.\n const state = isOpen ? 'expanded' : 'collapsed';\n\n const contextValue = React.useMemo(\n () => ({\n state,\n open: isOpen,\n setOpen,\n isMobile,\n openMobile,\n setOpenMobile,\n toggleSidebar,\n }),\n [state, isOpen, setOpen, isMobile, openMobile, setOpenMobile, toggleSidebar],\n );\n\n return (\n \n \n \n {children}\n
    \n \n \n );\n },\n);\nSidebarProvider.displayName = 'SidebarProvider';\n\nconst Sidebar = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & {\n side?: 'left' | 'right';\n variant?: 'sidebar' | 'floating' | 'inset';\n collapsible?: 'offcanvas' | 'icon' | 'none';\n }\n>(\n (\n {\n side = 'left',\n variant = 'sidebar',\n collapsible = 'offcanvas',\n className,\n children,\n ...props\n },\n ref,\n ) => {\n const { isMobile, state, openMobile, setOpenMobile } = useSidebar();\n\n if (collapsible === 'none') {\n return (\n \n {children}\n
    \n );\n }\n\n if (isMobile) {\n return (\n \n button]:tw-hidden\"\n style={\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n {\n '--sidebar-width': SIDEBAR_WIDTH_MOBILE,\n } as React.CSSProperties\n }\n side={side}\n >\n
    {children}
    \n \n
    \n );\n }\n\n return (\n \n {/* This is what handles the sidebar gap on desktop */}\n \n \n \n {children}\n
    \n
    \n
    \n );\n },\n);\nSidebar.displayName = 'Sidebar';\n\nconst SidebarTrigger = React.forwardRef<\n React.ElementRef,\n React.ComponentProps\n>(({ className, onClick, ...props }, ref) => {\n const { toggleSidebar } = useSidebar();\n\n return (\n {\n onClick?.(event);\n toggleSidebar();\n }}\n {...props}\n >\n \n Toggle Sidebar\n \n );\n});\nSidebarTrigger.displayName = 'SidebarTrigger';\n\nconst SidebarRail = React.forwardRef>(\n ({ className, ...props }, ref) => {\n const { toggleSidebar } = useSidebar();\n\n return (\n \n );\n },\n);\nSidebarRail.displayName = 'SidebarRail';\n\nconst SidebarInset = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarInset.displayName = 'SidebarInset';\n\nconst SidebarInput = React.forwardRef<\n React.ElementRef,\n React.ComponentProps\n>(({ className, ...props }, ref) => {\n return (\n \n );\n});\nSidebarInput.displayName = 'SidebarInput';\n\nconst SidebarHeader = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarHeader.displayName = 'SidebarHeader';\n\nconst SidebarFooter = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarFooter.displayName = 'SidebarFooter';\n\nconst SidebarSeparator = React.forwardRef<\n React.ElementRef,\n React.ComponentProps\n>(({ className, ...props }, ref) => {\n return (\n \n );\n});\nSidebarSeparator.displayName = 'SidebarSeparator';\n\nconst SidebarContent = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarContent.displayName = 'SidebarContent';\n\nconst SidebarGroup = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarGroup.displayName = 'SidebarGroup';\n\nconst SidebarGroupLabel = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & { asChild?: boolean }\n>(({ className, asChild = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'div';\n\n return (\n svg]:tw-size-4 [&>svg]:tw-shrink-0',\n 'group-data-[collapsible=icon]:tw--mt-8 group-data-[collapsible=icon]:tw-opacity-0',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarGroupLabel.displayName = 'SidebarGroupLabel';\n\nconst SidebarGroupAction = React.forwardRef<\n HTMLButtonElement,\n React.ComponentProps<'button'> & { asChild?: boolean }\n>(({ className, asChild = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'button';\n\n return (\n svg]:tw-size-4 [&>svg]:tw-shrink-0',\n // Increases the hit area of the button on mobile.\n 'after:tw-absolute after:tw--inset-2 after:md:tw-hidden',\n 'group-data-[collapsible=icon]:tw-hidden',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarGroupAction.displayName = 'SidebarGroupAction';\n\nconst SidebarGroupContent = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarGroupContent.displayName = 'SidebarGroupContent';\n\nconst SidebarMenu = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenu.displayName = 'SidebarMenu';\n\nconst SidebarMenuItem = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenuItem.displayName = 'SidebarMenuItem';\n\nconst sidebarMenuButtonVariants = cva(\n // Removed data-[active=true]:tw-bg-sidebar-accent\n 'tw-peer/menu-button tw-flex tw-w-full tw-items-center tw-gap-2 tw-overflow-hidden tw-rounded-md tw-p-2 tw-text-left tw-text-sm tw-outline-none tw-ring-sidebar-ring tw-transition-[width,height,padding] hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground focus-visible:tw-ring-2 active:tw-bg-sidebar-accent active:tw-text-sidebar-accent-foreground disabled:tw-pointer-events-none disabled:tw-opacity-50 tw-group-has-[[data-sidebar=menu-action]]/menu-item:pr-8 aria-disabled:tw-pointer-events-none aria-disabled:tw-opacity-50 data-[active=true]:tw-font-medium data-[active=true]:tw-text-sidebar-accent-foreground data-[state=open]:hover:tw-bg-sidebar-accent data-[state=open]:hover:tw-text-sidebar-accent-foreground group-data-[collapsible=icon]:tw-!size-8 group-data-[collapsible=icon]:tw-!p-2 [&>span:last-child]:tw-truncate [&>svg]:tw-size-4 [&>svg]:tw-shrink-0',\n {\n variants: {\n variant: {\n default: 'hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground',\n outline:\n 'tw-bg-background tw-shadow-[0_0_0_1px_hsl(var(--sidebar-border))] hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground hover:tw-shadow-[0_0_0_1px_hsl(var(--sidebar-accent))]',\n },\n size: {\n default: 'tw-h-8 tw-text-sm',\n sm: 'tw-h-7 tw-text-xs',\n lg: 'tw-h-12 tw-text-sm group-data-[collapsible=icon]:tw-!p-0',\n },\n },\n defaultVariants: {\n variant: 'default',\n size: 'default',\n },\n },\n);\n\nconst SidebarMenuButton = React.forwardRef<\n HTMLButtonElement,\n React.ComponentProps<'button'> & {\n asChild?: boolean;\n isActive?: boolean;\n tooltip?: string | React.ComponentProps;\n } & VariantProps\n>(\n (\n {\n asChild = false,\n isActive = false,\n variant = 'default',\n size = 'default',\n tooltip,\n className,\n ...props\n },\n ref,\n ) => {\n const Comp = asChild ? Slot : 'button';\n const { isMobile, state } = useSidebar();\n\n const button = (\n \n );\n\n if (!tooltip) {\n return button;\n }\n\n if (typeof tooltip === 'string') {\n // eslint-disable-next-line no-param-reassign\n tooltip = {\n children: tooltip,\n };\n }\n\n return (\n \n {button}\n \n );\n },\n);\nSidebarMenuButton.displayName = 'SidebarMenuButton';\n\nconst SidebarMenuAction = React.forwardRef<\n HTMLButtonElement,\n React.ComponentProps<'button'> & {\n asChild?: boolean;\n showOnHover?: boolean;\n }\n>(({ className, asChild = false, showOnHover = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'button';\n\n return (\n svg]:tw-size-4 [&>svg]:tw-shrink-0',\n // Increases the hit area of the button on mobile.\n 'after:tw-absolute after:tw--inset-2 after:md:tw-hidden',\n 'tw-peer-data-[size=sm]/menu-button:top-1',\n 'tw-peer-data-[size=default]/menu-button:top-1.5',\n 'tw-peer-data-[size=lg]/menu-button:top-2.5',\n 'group-data-[collapsible=icon]:tw-hidden',\n showOnHover &&\n 'tw-group-focus-within/menu-item:opacity-100 tw-group-hover/menu-item:opacity-100 tw-peer-data-[active=true]/menu-button:text-sidebar-accent-foreground data-[state=open]:tw-opacity-100 md:tw-opacity-0',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarMenuAction.displayName = 'SidebarMenuAction';\n\nconst SidebarMenuBadge = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenuBadge.displayName = 'SidebarMenuBadge';\n\nconst SidebarMenuSkeleton = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & {\n showIcon?: boolean;\n }\n>(({ className, showIcon = false, ...props }, ref) => {\n // Random width between 50 to 90%.\n const width = React.useMemo(() => {\n return `${Math.floor(Math.random() * 40) + 50}%`;\n }, []);\n\n return (\n \n {showIcon && (\n \n )}\n \n
    \n );\n});\nSidebarMenuSkeleton.displayName = 'SidebarMenuSkeleton';\n\nconst SidebarMenuSub = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenuSub.displayName = 'SidebarMenuSub';\n\nconst SidebarMenuSubItem = React.forwardRef>(\n ({ ...props }, ref) =>
  • ,\n);\nSidebarMenuSubItem.displayName = 'SidebarMenuSubItem';\n\nconst SidebarMenuSubButton = React.forwardRef<\n HTMLAnchorElement,\n React.ComponentProps<'a'> & {\n asChild?: boolean;\n size?: 'sm' | 'md';\n isActive?: boolean;\n }\n>(({ asChild = false, size = 'md', isActive, className, ...props }, ref) => {\n const Comp = asChild ? Slot : 'a';\n\n return (\n span:last-child]:tw-truncate [&>svg]:tw-size-4 [&>svg]:tw-shrink-0 [&>svg]:tw-text-sidebar-accent-foreground',\n 'data-[active=true]:tw-bg-sidebar-accent data-[active=true]:tw-text-sidebar-accent-foreground',\n size === 'sm' && 'tw-text-xs',\n size === 'md' && 'tw-text-sm',\n 'group-data-[collapsible=icon]:tw-hidden',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarMenuSubButton.displayName = 'SidebarMenuSubButton';\n\nexport {\n Sidebar,\n SidebarContent,\n SidebarFooter,\n SidebarGroup,\n SidebarGroupAction,\n SidebarGroupContent,\n SidebarGroupLabel,\n SidebarHeader,\n SidebarInput,\n SidebarInset,\n SidebarMenu,\n SidebarMenuAction,\n SidebarMenuBadge,\n SidebarMenuButton,\n SidebarMenuItem,\n SidebarMenuSkeleton,\n SidebarMenuSub,\n SidebarMenuSubButton,\n SidebarMenuSubItem,\n SidebarProvider,\n SidebarRail,\n SidebarSeparator,\n SidebarTrigger,\n useSidebar,\n};\n","import ComboBox, { ComboBoxOption } from '@/components/basics/combo-box.component';\nimport {\n Sidebar,\n SidebarContent,\n SidebarGroup,\n SidebarGroupLabel,\n SidebarGroupContent,\n SidebarMenu,\n SidebarMenuItem,\n SidebarMenuButton,\n} from '@/components/shadcn-ui/sidebar';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { useCallback } from 'react';\n\nexport type SelectedSettingsSidebarItem = {\n label: string;\n projectId?: string;\n};\n\nexport type ProjectOptions = { projectId: string; projectName: string };\n\nexport type SettingsSidebarProps = {\n /** Optional id for testing */\n id?: string;\n\n /** Extension labels from contribution */\n extensionLabels: string[];\n\n /** Project names and ids */\n projectOptions: ProjectOptions[];\n\n /** Handler for selecting a sidebar item */\n handleSelectSidebarItem: (key: string, projectId?: string) => void;\n\n /** The current selected value in the sidebar */\n selectedSidebarItem: SelectedSettingsSidebarItem;\n\n /** Label for the group of extensions setting groups */\n extensionsSidebarGroupLabel: string;\n\n /** Label for the group of projects settings */\n projectsSidebarGroupLabel: string;\n\n /** Placeholder for the button */\n buttonPlaceholder: string;\n};\n\nexport default function SettingsSidebar({\n id,\n extensionLabels,\n projectOptions,\n handleSelectSidebarItem,\n selectedSidebarItem,\n extensionsSidebarGroupLabel,\n projectsSidebarGroupLabel,\n buttonPlaceholder,\n}: SettingsSidebarProps) {\n const handleSelectItem = useCallback(\n (item: string, projectId?: string) => {\n handleSelectSidebarItem(item, projectId);\n },\n [handleSelectSidebarItem],\n );\n\n const getProjectNameFromProjectId = useCallback(\n (projectId: string) => {\n const project = projectOptions.find((option) => option.projectId === projectId);\n return project ? project.projectName : projectId;\n },\n [projectOptions],\n );\n\n const getIsActive: (label: string) => boolean = useCallback(\n (label: string) => !selectedSidebarItem.projectId && label === selectedSidebarItem.label,\n [selectedSidebarItem],\n );\n\n return (\n \n \n \n \n {extensionsSidebarGroupLabel}\n \n \n \n {extensionLabels.map((label) => (\n \n handleSelectItem(label, undefined)}\n isActive={getIsActive(label)}\n >\n {label}\n \n \n ))}\n \n \n \n \n \n {projectsSidebarGroupLabel}\n \n \n option.projectId)}\n getOptionLabel={(projectId: ComboBoxOption) => {\n // This function expects a ComboBoxOption, but we know it is a string\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n return getProjectNameFromProjectId(projectId as string);\n }}\n buttonPlaceholder={buttonPlaceholder}\n onChange={(projectId: string) => {\n const selectedProjectName = getProjectNameFromProjectId(projectId);\n handleSelectItem(selectedProjectName, projectId);\n }}\n value={selectedSidebarItem?.projectId ?? undefined}\n />\n \n \n \n \n );\n}\n","import { SidebarInset, SidebarProvider } from '@/components/shadcn-ui/sidebar';\nimport { PropsWithChildren } from 'react';\nimport SearchBar from '@/components/basics/search-bar.component';\nimport SettingsSidebar, { SettingsSidebarProps } from './settings-sidebar.component';\n\nexport type SettingsSidebarContentSearchProps = SettingsSidebarProps &\n PropsWithChildren & {\n /** Optional id for testing */\n id?: string;\n\n /** Text direction ltr or rtl */\n direction?: 'ltr' | 'rtl';\n\n /** Handler to run when the value of the search bar changes */\n onSearch: (searchQuery: string) => void;\n };\n\nexport default function SettingsSidebarContentSearch({\n id,\n direction = 'ltr',\n extensionLabels,\n projectOptions,\n children,\n handleSelectSidebarItem,\n selectedSidebarItem,\n onSearch,\n extensionsSidebarGroupLabel,\n projectsSidebarGroupLabel,\n buttonPlaceholder,\n}: SettingsSidebarContentSearchProps) {\n return (\n
    \n
    \n \n
    \n \n \n {children}\n \n
    \n );\n}\n","import { Button } from '@/components/shadcn-ui/button';\nimport {\n Select,\n SelectContent,\n SelectGroup,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\nimport {\n Table,\n TableBody,\n TableCell,\n TableHead,\n TableHeader,\n TableRow,\n} from '@/components/shadcn-ui/table';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Canon } from '@sillsdev/scripture';\nimport {\n Cell,\n ColumnDef,\n flexRender,\n getCoreRowModel,\n getExpandedRowModel,\n getGroupedRowModel,\n getSortedRowModel,\n GroupingState,\n Row,\n RowSelectionState,\n SortingState,\n useReactTable,\n} from '@tanstack/react-table';\nimport '@/components/advanced/scripture-results-viewer/scripture-results-viewer.component.css';\nimport {\n compareScrRefs,\n formatScrRef,\n ScriptureSelection,\n scrRefToBBBCCCVVV,\n} from 'platform-bible-utils';\nimport { MouseEvent, useEffect, useMemo, useState } from 'react';\nimport { ChevronDown, ChevronLeft, ChevronRight } from 'lucide-react';\n\n/**\n * Information (e.g., a checking error or some other type of \"transient\" annotation) about something\n * noteworthy at a specific place in an instance of the Scriptures.\n */\nexport type ScriptureItemDetail = ScriptureSelection & {\n /**\n * Text of the error, note, etc. In the future, we might want to support something more than just\n * text so that a JSX element could be provided with a link or some other controls related to the\n * issue being reported.\n */\n detail: string;\n};\n\n/**\n * A uniquely identifiable source of results that can be displayed in the ScriptureResultsViewer.\n * Generally, the source will be a particular Scripture check, but there may be other types of\n * sources.\n */\nexport type ResultsSource = {\n /**\n * Uniquely identifies the source.\n *\n * @type {string}\n */\n id: string;\n\n /**\n * Name (potentially localized) of the source, suitable for display in the UI.\n *\n * @type {string}\n */\n displayName: string;\n};\n\nexport type ScriptureSrcItemDetail = ScriptureItemDetail & {\n /** Source/type of detail. Can be used for grouping. */\n source: ResultsSource;\n};\n\n/**\n * Represents a set of results keyed by Scripture reference. Generally, the source will be a\n * particular Scripture check, but this type also allows for other types of uniquely identifiable\n * sources.\n */\nexport type ResultsSet = {\n /**\n * The backing source associated with this set of results.\n *\n * @type {ResultsSource}\n */\n source: ResultsSource;\n\n /**\n * Array of Scripture item details (messages keyed by Scripture reference).\n *\n * @type {ScriptureItemDetail[]}\n */\n data: ScriptureItemDetail[];\n};\n\nconst scrBookColId = 'scrBook';\nconst scrRefColId = 'scrRef';\nconst typeColId = 'source';\nconst detailsColId = 'details';\n\nconst defaultScrRefColumnName = 'Scripture Reference';\nconst defaultScrBookGroupName = 'Scripture Book';\nconst defaultTypeColumnName = 'Type';\nconst defaultDetailsColumnName = 'Details';\n\nexport type ScriptureResultsViewerColumnInfo = {\n /** Optional header to display for the Reference column. Default value: 'Scripture Reference'. */\n scriptureReferenceColumnName?: string;\n\n /** Optional text to display to refer to the Scripture book group. Default value: 'Scripture Book'. */\n scriptureBookGroupName?: string;\n\n /** Optional header to display for the Type column. Default value: 'Type'. */\n typeColumnName?: string;\n\n /** Optional header to display for the Details column. Default value: 'Details' */\n detailsColumnName?: string;\n};\n\nexport type ScriptureResultsViewerProps = ScriptureResultsViewerColumnInfo & {\n /** Groups of ScriptureItemDetail objects from particular sources (e.g., Scripture checks) */\n sources: ResultsSet[];\n\n /** Flag indicating whether to display column headers. Default is false. */\n showColumnHeaders?: boolean;\n\n /** Flag indicating whether to display source column. Default is false. */\n showSourceColumn?: boolean;\n\n /** Callback function to notify when a row is selected */\n onRowSelected?: (selectedRow: ScriptureSrcItemDetail | undefined) => void;\n\n /** Text direction ltr or rtl */\n direction?: 'ltr' | 'rtl';\n};\n\nfunction getColumns(\n colInfo?: ScriptureResultsViewerColumnInfo,\n showSourceColumn?: boolean,\n): ColumnDef[] {\n const showSrcCol = showSourceColumn ?? false;\n return [\n {\n accessorFn: (row) =>\n `${Canon.bookNumberToId(row.start.bookNum)} ${row.start.chapterNum}:${row.start.verseNum}`,\n id: scrBookColId,\n header: colInfo?.scriptureReferenceColumnName ?? defaultScrRefColumnName,\n cell: (info) => {\n const row = info.row.original;\n if (info.row.getIsGrouped()) {\n return Canon.bookNumberToEnglishName(row.start.bookNum);\n }\n return info.row.groupingColumnId === scrBookColId ? formatScrRef(row.start) : undefined;\n },\n getGroupingValue: (row) => row.start.bookNum,\n sortingFn: (a, b) => {\n return compareScrRefs(a.original.start, b.original.start);\n },\n enableGrouping: true,\n },\n {\n accessorFn: (row) => formatScrRef(row.start),\n id: scrRefColId,\n header: undefined,\n cell: (info) => {\n const row = info.row.original;\n return info.row.getIsGrouped() ? undefined : formatScrRef(row.start);\n },\n sortingFn: (a, b) => {\n return compareScrRefs(a.original.start, b.original.start);\n },\n enableGrouping: false,\n },\n {\n accessorFn: (row) => row.source.displayName,\n id: typeColId,\n header: showSrcCol ? (colInfo?.typeColumnName ?? defaultTypeColumnName) : undefined,\n cell: (info) => (showSrcCol || info.row.getIsGrouped() ? info.getValue() : undefined),\n getGroupingValue: (row) => row.source.id,\n sortingFn: (a, b) =>\n a.original.source.displayName.localeCompare(b.original.source.displayName),\n enableGrouping: true,\n },\n {\n accessorFn: (row) => row.detail,\n id: detailsColId,\n header: colInfo?.detailsColumnName ?? defaultDetailsColumnName,\n cell: (info) => info.getValue(),\n enableGrouping: false,\n },\n ];\n}\n\nconst toRefOrRange = (scriptureSelection: ScriptureSelection) => {\n if (!('offset' in scriptureSelection.start))\n throw new Error('No offset available in range start');\n if (scriptureSelection.end && !('offset' in scriptureSelection.end))\n throw new Error('No offset available in range end');\n const { offset: offsetStart } = scriptureSelection.start;\n let offsetEnd: number = 0;\n if (scriptureSelection.end) ({ offset: offsetEnd } = scriptureSelection.end);\n if (\n !scriptureSelection.end ||\n compareScrRefs(scriptureSelection.start, scriptureSelection.end) === 0\n )\n return `${scrRefToBBBCCCVVV(scriptureSelection.start)}+${offsetStart}`;\n return `${scrRefToBBBCCCVVV(scriptureSelection.start)}+${offsetStart}-${scrRefToBBBCCCVVV(scriptureSelection.end)}+${offsetEnd}`;\n};\n\nconst getRowKey = (row: ScriptureSrcItemDetail) =>\n `${toRefOrRange({ start: row.start, end: row.end })} ${row.source.displayName} ${row.detail}`;\n\n/**\n * Component to display a combined list of detailed items from one or more sources, where the items\n * are keyed primarily by Scripture reference. This is particularly useful for displaying a list of\n * results from Scripture checks, but more generally could be used to display any \"results\" from any\n * source(s). The component allows for grouping by Scripture book, source, or both. By default, it\n * displays somewhat \"tree-like\" which allows it to be more horizontally compact and intuitive. But\n * it also has the option of displaying as a traditional table with column headings (with or without\n * the source column showing).\n */\nexport default function ScriptureResultsViewer({\n sources,\n showColumnHeaders = false,\n showSourceColumn = false,\n scriptureReferenceColumnName,\n scriptureBookGroupName,\n typeColumnName,\n detailsColumnName,\n onRowSelected,\n direction = 'ltr',\n}: ScriptureResultsViewerProps) {\n const [grouping, setGrouping] = useState([]);\n const [sorting, setSorting] = useState([{ id: scrBookColId, desc: false }]);\n const [rowSelection, setRowSelection] = useState({});\n\n const scriptureResults = useMemo(\n () =>\n sources.flatMap((source) => {\n return source.data.map((item) => ({\n ...item,\n source: source.source,\n }));\n }),\n [sources],\n );\n\n const columns = useMemo(\n () =>\n getColumns(\n {\n scriptureReferenceColumnName,\n typeColumnName,\n detailsColumnName,\n },\n showSourceColumn,\n ),\n [scriptureReferenceColumnName, typeColumnName, detailsColumnName, showSourceColumn],\n );\n\n useEffect(() => {\n // Ensure sorting is applied correctly when grouped by type\n if (grouping.includes(typeColId)) {\n setSorting([\n { id: typeColId, desc: false },\n { id: scrBookColId, desc: false },\n ]);\n } else {\n setSorting([{ id: scrBookColId, desc: false }]);\n }\n }, [grouping]);\n\n const table = useReactTable({\n data: scriptureResults,\n columns,\n state: {\n grouping,\n sorting,\n rowSelection,\n },\n onGroupingChange: setGrouping,\n onSortingChange: setSorting,\n onRowSelectionChange: setRowSelection,\n getExpandedRowModel: getExpandedRowModel(),\n getGroupedRowModel: getGroupedRowModel(),\n getCoreRowModel: getCoreRowModel(),\n getSortedRowModel: getSortedRowModel(),\n getRowId: getRowKey,\n autoResetExpanded: false,\n enableMultiRowSelection: false,\n enableSubRowSelection: false,\n });\n\n useEffect(() => {\n if (onRowSelected) {\n const selectedRows = table.getSelectedRowModel().rowsById;\n const keys = Object.keys(selectedRows);\n if (keys.length === 1) {\n const selectedRow = scriptureResults.find((row) => getRowKey(row) === keys[0]) || undefined;\n if (selectedRow) onRowSelected(selectedRow);\n }\n }\n }, [rowSelection, scriptureResults, onRowSelected, table]);\n\n // Define possible grouping options\n const scrBookGroupName = scriptureBookGroupName ?? defaultScrBookGroupName;\n const typeGroupName = typeColumnName ?? defaultTypeColumnName;\n\n const groupingOptions = [\n { label: 'No Grouping', value: [] },\n { label: `Group by ${scrBookGroupName}`, value: [scrBookColId] },\n { label: `Group by ${typeGroupName}`, value: [typeColId] },\n {\n label: `Group by ${scrBookGroupName} and ${typeGroupName}`,\n value: [scrBookColId, typeColId],\n },\n {\n label: `Group by ${typeGroupName} and ${scrBookGroupName}`,\n value: [typeColId, scrBookColId],\n },\n ];\n\n const handleSelectChange = (selectedGrouping: string) => {\n setGrouping(JSON.parse(selectedGrouping));\n };\n\n const handleRowClick = (row: Row, event: MouseEvent) => {\n if (!row.getIsGrouped() && !row.getIsSelected()) {\n row.getToggleSelectedHandler()(event);\n }\n };\n\n const getEvenOrOddBandingStyle = (row: Row, index: number) => {\n if (row.getIsGrouped()) return '';\n // UX has now said they don't think they want banding. I'm leaving in the code to\n // set even and odd styles, but there's nothing in the CSS to style them differently.\n // The \"even\" style used to also have tw-bg-neutral-300 (along with even) to create\n // a visual banding effect. That could be added back in if UX changes the decision.\n return cn('banded-row', index % 2 === 0 ? 'even' : 'odd');\n };\n\n const getIndent = (\n groupingState: GroupingState,\n row: Row,\n cell: Cell,\n ) => {\n if (groupingState?.length === 0 || row.depth < cell.column.getGroupedIndex()) return undefined;\n if (row.getIsGrouped()) {\n switch (row.depth) {\n case 1:\n return 'tw-ps-4';\n default:\n return undefined;\n }\n }\n switch (row.depth) {\n case 1:\n return 'tw-ps-8';\n case 2:\n return 'tw-ps-12';\n default:\n return undefined;\n }\n };\n\n return (\n
    \n {!showColumnHeaders && (\n {\n handleSelectChange(value);\n }}\n >\n \n \n \n \n \n {groupingOptions.map((option) => (\n \n {option.label}\n \n ))}\n \n \n \n )}\n \n {showColumnHeaders && (\n \n {table.getHeaderGroups().map((headerGroup) => (\n \n {headerGroup.headers\n .filter((h) => h.column.columnDef.header)\n .map((header) => (\n /* For sticky column headers to work, we probably need to change the default definition of the shadcn Table component. See https://github.com/shadcn-ui/ui/issues/1151 */\n \n {header.isPlaceholder ? undefined : (\n
    \n {header.column.getCanGroup() ? (\n \n {header.column.getIsGrouped() ? `🛑` : `👊 `}\n \n ) : undefined}{' '}\n {flexRender(header.column.columnDef.header, header.getContext())}\n
    \n )}\n
    \n ))}\n
    \n ))}\n
    \n )}\n \n {table.getRowModel().rows.map((row, rowIndex) => {\n return (\n handleRowClick(row, event)}\n >\n {row.getVisibleCells().map((cell) => {\n if (\n cell.getIsPlaceholder() ||\n (cell.column.columnDef.enableGrouping &&\n !cell.getIsGrouped() &&\n (cell.column.columnDef.id !== typeColId || !showSourceColumn))\n )\n return undefined;\n return (\n \n {(() => {\n if (cell.getIsGrouped()) {\n return (\n \n {row.getIsExpanded() && }\n {!row.getIsExpanded() &&\n (direction === 'ltr' ? : )}{' '}\n {flexRender(cell.column.columnDef.cell, cell.getContext())} (\n {row.subRows.length})\n \n );\n }\n\n // if (cell.getIsAggregated()) {\n // flexRender(\n // cell.column.columnDef.aggregatedCell ?? cell.column.columnDef.cell,\n // cell.getContext(),\n // );\n // }\n\n return flexRender(cell.column.columnDef.cell, cell.getContext());\n })()}\n \n );\n })}\n \n );\n })}\n \n
    \n
    \n );\n}\n","import {\n getLocalizeKeyForScrollGroupId,\n LanguageStrings,\n ScrollGroupId,\n} from 'platform-bible-utils';\nimport {\n Select,\n SelectContent,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\n\nconst DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS = {\n [getLocalizeKeyForScrollGroupId('undefined')]: 'Ø',\n [getLocalizeKeyForScrollGroupId(0)]: 'A',\n [getLocalizeKeyForScrollGroupId(1)]: 'B',\n [getLocalizeKeyForScrollGroupId(2)]: 'C',\n [getLocalizeKeyForScrollGroupId(3)]: 'D',\n [getLocalizeKeyForScrollGroupId(4)]: 'E',\n [getLocalizeKeyForScrollGroupId(5)]: 'F',\n [getLocalizeKeyForScrollGroupId(6)]: 'G',\n [getLocalizeKeyForScrollGroupId(7)]: 'H',\n [getLocalizeKeyForScrollGroupId(8)]: 'I',\n [getLocalizeKeyForScrollGroupId(9)]: 'J',\n [getLocalizeKeyForScrollGroupId(10)]: 'K',\n [getLocalizeKeyForScrollGroupId(11)]: 'L',\n [getLocalizeKeyForScrollGroupId(12)]: 'M',\n [getLocalizeKeyForScrollGroupId(13)]: 'N',\n [getLocalizeKeyForScrollGroupId(14)]: 'O',\n [getLocalizeKeyForScrollGroupId(15)]: 'P',\n [getLocalizeKeyForScrollGroupId(16)]: 'Q',\n [getLocalizeKeyForScrollGroupId(17)]: 'R',\n [getLocalizeKeyForScrollGroupId(18)]: 'S',\n [getLocalizeKeyForScrollGroupId(19)]: 'T',\n [getLocalizeKeyForScrollGroupId(20)]: 'U',\n [getLocalizeKeyForScrollGroupId(21)]: 'V',\n [getLocalizeKeyForScrollGroupId(22)]: 'W',\n [getLocalizeKeyForScrollGroupId(23)]: 'X',\n [getLocalizeKeyForScrollGroupId(24)]: 'Y',\n [getLocalizeKeyForScrollGroupId(25)]: 'Z',\n};\n\nexport type ScrollGroupSelectorProps = {\n /**\n * List of scroll group ids to show to the user. Either a {@link ScrollGroupId} or `undefined` for\n * no scroll group\n */\n availableScrollGroupIds: (ScrollGroupId | undefined)[];\n /** Currently selected scroll group id. `undefined` for no scroll group */\n scrollGroupId: ScrollGroupId | undefined;\n /** Callback function run when the user tries to change the scroll group id */\n onChangeScrollGroupId: (newScrollGroupId: ScrollGroupId | undefined) => void;\n /**\n * Localized strings to use for displaying scroll group ids. Must be an object whose keys are\n * `getLocalizeKeyForScrollGroupId(scrollGroupId)` for all scroll group ids (and `undefined` if\n * included) in {@link ScrollGroupSelectorProps.availableScrollGroupIds} and whose values are the\n * localized strings to use for those scroll group ids.\n *\n * Defaults to English localizations of English alphabet for scroll groups 0-25 (e.g. 0 is A) and\n * Ø for `undefined`. Will fill in any that are not provided with these English localizations.\n * Also, if any values match the keys, the English localization will be used. This is useful in\n * case you want to pass in a temporary version of the localized strings while your localized\n * strings load.\n *\n * @example\n *\n * ```typescript\n * const myScrollGroupIdLocalizedStrings = {\n * [getLocalizeKeyForScrollGroupId('undefined')]: 'Ø',\n * [getLocalizeKeyForScrollGroupId(0)]: 'A',\n * [getLocalizeKeyForScrollGroupId(1)]: 'B',\n * [getLocalizeKeyForScrollGroupId(2)]: 'C',\n * [getLocalizeKeyForScrollGroupId(3)]: 'D',\n * [getLocalizeKeyForScrollGroupId(4)]: 'E',\n * };\n * ```\n *\n * @example\n *\n * ```tsx\n * const availableScrollGroupIds = [undefined, 0, 1, 2, 3, 4];\n *\n * const localizeKeys = getLocalizeKeysForScrollGroupIds();\n *\n * const [localizedStrings] = useLocalizedStrings(localizeKeys);\n *\n * ...\n *\n * \n * ```\n */\n localizedStrings?: LanguageStrings;\n};\n\n/** Selector component for choosing a scroll group */\nexport default function ScrollGroupSelector({\n availableScrollGroupIds,\n scrollGroupId,\n onChangeScrollGroupId,\n localizedStrings = {},\n}: ScrollGroupSelectorProps) {\n const localizedStringsDefaulted = {\n ...DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS,\n ...Object.fromEntries(\n Object.entries(localizedStrings).map(\n ([localizedStringKey, localizedStringValue]: [string, string]) => [\n localizedStringKey,\n localizedStringKey === localizedStringValue &&\n localizedStringKey in DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS\n ? DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS[localizedStringKey]\n : localizedStringValue,\n ],\n ),\n ),\n };\n return (\n \n onChangeScrollGroupId(\n newScrollGroupString === 'undefined' ? undefined : parseInt(newScrollGroupString, 10),\n )\n }\n >\n \n \n \n \n {availableScrollGroupIds.map((scrollGroupOptionId) => (\n \n {localizedStringsDefaulted[getLocalizeKeyForScrollGroupId(scrollGroupOptionId)]}\n \n ))}\n \n \n );\n}\n","import { PropsWithChildren } from 'react';\nimport { Separator } from '@/components/shadcn-ui/separator';\n\n/** Props for the SettingsList component, currently just children */\ntype SettingsListProps = PropsWithChildren;\n\n/**\n * SettingsList component is a wrapper for list items. Rendered with a formatted div\n *\n * @param children To populate the list with\n * @returns Formatted div encompassing the children\n */\nexport function SettingsList({ children }: SettingsListProps) {\n return
    {children}
    ;\n}\n\n/** Props for SettingsListItem component */\ntype SettingsListItemProps = PropsWithChildren & {\n /** Primary text of the list item */\n primary: string;\n\n /** Optional text of the list item */\n secondary?: string | undefined;\n\n /** Optional boolean to display a message if the children aren't loaded yet. Defaults to false */\n isLoading?: boolean;\n\n /** Optional message to display if isLoading */\n loadingMessage?: string;\n};\n\n/**\n * SettingsListItem component is a common list item. Rendered with a formatted div\n *\n * @param primary Primary text of the list item\n * @param secondary Optional secondary text of the list item\n * @param isLoading Optional, to display a message if the action component isn't generated yet,\n * defaults to false\n * @param children The action component(s) to provide for this item\n * @param loadingMessage Optional, message to display if isLoading\n * @returns Formatted div encompassing the list item content\n */\nexport function SettingsListItem({\n primary,\n secondary,\n children,\n isLoading = false,\n loadingMessage,\n}: SettingsListItemProps) {\n return (\n
    \n
    \n

    {primary}

    \n

    \n {secondary}\n

    \n
    \n\n {isLoading ? (\n

    {loadingMessage}

    \n ) : (\n
    {children}
    \n )}\n
    \n );\n}\n\n/** Props for SettingsListHeader component */\ntype SettingsListHeaderProps = {\n /** The primary text of the list header */\n primary: string;\n\n /** Optional secondary text of the list header */\n secondary?: string | undefined;\n\n /** Optional boolean to include a separator underneath the secondary text. Defaults to false */\n includeSeparator?: boolean;\n};\n\n/**\n * SettingsListHeader component displays text above the list\n *\n * @param primary The primary text of the list header\n * @param secondary Optional secondary text of the list header\n * @param includeSeparator Optional boolean to include a separator underneath the secondary text.\n * Defaults to false\n * @returns Formatted div with list header content\n */\nexport function SettingsListHeader({\n primary,\n secondary,\n includeSeparator = false,\n}: SettingsListHeaderProps) {\n return (\n
    \n
    \n

    {primary}

    \n

    {secondary}

    \n
    \n {includeSeparator ? : ''}\n
    \n );\n}\n","import Checkbox from '@/components/shadcn-ui/checkbox';\nimport { Label } from '@/components/shadcn-ui/label';\n\nexport type ChecklistProps = {\n /** Optional string representing the id attribute of the Checklist */\n id?: string;\n /** Optional string representing CSS class name(s) for styling */\n className?: string;\n /** Array of strings representing the checkable items */\n listItems: string[];\n /** Array of strings representing the checked items */\n selectedListItems: string[];\n /**\n * Function that is called when a checkbox item is selected or deselected\n *\n * @param item The string description for this item\n * @param selected True if selected, false if not selected\n */\n handleSelectListItem: (item: string, selected: boolean) => void;\n\n /**\n * Optional function creates a label for a provided checkable item\n *\n * @param item The item for which a label is to be created\n * @returns A string representing the label text for the checkbox associated with that item\n */\n createLabel?: (item: string) => string;\n};\n\n/** Renders a list of checkboxes. Each checkbox corresponds to an item from the `listItems` array. */\nexport default function Checklist({\n id,\n className,\n listItems,\n selectedListItems,\n handleSelectListItem,\n createLabel,\n}: ChecklistProps) {\n return (\n
    \n {listItems.map((item) => (\n
    \n handleSelectListItem(item, value)}\n />\n \n
    \n ))}\n
    \n );\n}\n","function _interopRequireDefault(obj) {\n return obj && obj.__esModule ? obj : {\n \"default\": obj\n };\n}\nmodule.exports = _interopRequireDefault, module.exports.__esModule = true, module.exports[\"default\"] = module.exports;","export default function chainPropTypes(propType1, propType2) {\n if (process.env.NODE_ENV === 'production') {\n return () => null;\n }\n return function validate(...args) {\n return propType1(...args) || propType2(...args);\n };\n}","export default function _extends() {\n _extends = Object.assign ? Object.assign.bind() : function (target) {\n for (var i = 1; i < arguments.length; i++) {\n var source = arguments[i];\n for (var key in source) {\n if (Object.prototype.hasOwnProperty.call(source, key)) {\n target[key] = source[key];\n }\n }\n }\n return target;\n };\n return _extends.apply(this, arguments);\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\n// https://github.com/sindresorhus/is-plain-obj/blob/main/index.js\nexport function isPlainObject(item) {\n if (typeof item !== 'object' || item === null) {\n return false;\n }\n const prototype = Object.getPrototypeOf(item);\n return (prototype === null || prototype === Object.prototype || Object.getPrototypeOf(prototype) === null) && !(Symbol.toStringTag in item) && !(Symbol.iterator in item);\n}\nfunction deepClone(source) {\n if (!isPlainObject(source)) {\n return source;\n }\n const output = {};\n Object.keys(source).forEach(key => {\n output[key] = deepClone(source[key]);\n });\n return output;\n}\nexport default function deepmerge(target, source, options = {\n clone: true\n}) {\n const output = options.clone ? _extends({}, target) : target;\n if (isPlainObject(target) && isPlainObject(source)) {\n Object.keys(source).forEach(key => {\n // Avoid prototype pollution\n if (key === '__proto__') {\n return;\n }\n if (isPlainObject(source[key]) && key in target && isPlainObject(target[key])) {\n // Since `output` is a clone of `target` and we have narrowed `target` in this block we can cast to the same type.\n output[key] = deepmerge(target[key], source[key], options);\n } else if (options.clone) {\n output[key] = isPlainObject(source[key]) ? deepClone(source[key]) : source[key];\n } else {\n output[key] = source[key];\n }\n });\n }\n return output;\n}","/** @license React v16.13.1\n * react-is.production.min.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';var b=\"function\"===typeof Symbol&&Symbol.for,c=b?Symbol.for(\"react.element\"):60103,d=b?Symbol.for(\"react.portal\"):60106,e=b?Symbol.for(\"react.fragment\"):60107,f=b?Symbol.for(\"react.strict_mode\"):60108,g=b?Symbol.for(\"react.profiler\"):60114,h=b?Symbol.for(\"react.provider\"):60109,k=b?Symbol.for(\"react.context\"):60110,l=b?Symbol.for(\"react.async_mode\"):60111,m=b?Symbol.for(\"react.concurrent_mode\"):60111,n=b?Symbol.for(\"react.forward_ref\"):60112,p=b?Symbol.for(\"react.suspense\"):60113,q=b?\nSymbol.for(\"react.suspense_list\"):60120,r=b?Symbol.for(\"react.memo\"):60115,t=b?Symbol.for(\"react.lazy\"):60116,v=b?Symbol.for(\"react.block\"):60121,w=b?Symbol.for(\"react.fundamental\"):60117,x=b?Symbol.for(\"react.responder\"):60118,y=b?Symbol.for(\"react.scope\"):60119;\nfunction z(a){if(\"object\"===typeof a&&null!==a){var u=a.$$typeof;switch(u){case c:switch(a=a.type,a){case l:case m:case e:case g:case f:case p:return a;default:switch(a=a&&a.$$typeof,a){case k:case n:case t:case r:case h:return a;default:return u}}case d:return u}}}function A(a){return z(a)===m}exports.AsyncMode=l;exports.ConcurrentMode=m;exports.ContextConsumer=k;exports.ContextProvider=h;exports.Element=c;exports.ForwardRef=n;exports.Fragment=e;exports.Lazy=t;exports.Memo=r;exports.Portal=d;\nexports.Profiler=g;exports.StrictMode=f;exports.Suspense=p;exports.isAsyncMode=function(a){return A(a)||z(a)===l};exports.isConcurrentMode=A;exports.isContextConsumer=function(a){return z(a)===k};exports.isContextProvider=function(a){return z(a)===h};exports.isElement=function(a){return\"object\"===typeof a&&null!==a&&a.$$typeof===c};exports.isForwardRef=function(a){return z(a)===n};exports.isFragment=function(a){return z(a)===e};exports.isLazy=function(a){return z(a)===t};\nexports.isMemo=function(a){return z(a)===r};exports.isPortal=function(a){return z(a)===d};exports.isProfiler=function(a){return z(a)===g};exports.isStrictMode=function(a){return z(a)===f};exports.isSuspense=function(a){return z(a)===p};\nexports.isValidElementType=function(a){return\"string\"===typeof a||\"function\"===typeof a||a===e||a===m||a===g||a===f||a===p||a===q||\"object\"===typeof a&&null!==a&&(a.$$typeof===t||a.$$typeof===r||a.$$typeof===h||a.$$typeof===k||a.$$typeof===n||a.$$typeof===w||a.$$typeof===x||a.$$typeof===y||a.$$typeof===v)};exports.typeOf=z;\n","/** @license React v16.13.1\n * react-is.development.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\n\n\nif (process.env.NODE_ENV !== \"production\") {\n (function() {\n'use strict';\n\n// The Symbol used to tag the ReactElement-like types. If there is no native Symbol\n// nor polyfill, then a plain number is used for performance.\nvar hasSymbol = typeof Symbol === 'function' && Symbol.for;\nvar REACT_ELEMENT_TYPE = hasSymbol ? Symbol.for('react.element') : 0xeac7;\nvar REACT_PORTAL_TYPE = hasSymbol ? Symbol.for('react.portal') : 0xeaca;\nvar REACT_FRAGMENT_TYPE = hasSymbol ? Symbol.for('react.fragment') : 0xeacb;\nvar REACT_STRICT_MODE_TYPE = hasSymbol ? Symbol.for('react.strict_mode') : 0xeacc;\nvar REACT_PROFILER_TYPE = hasSymbol ? Symbol.for('react.profiler') : 0xead2;\nvar REACT_PROVIDER_TYPE = hasSymbol ? Symbol.for('react.provider') : 0xeacd;\nvar REACT_CONTEXT_TYPE = hasSymbol ? Symbol.for('react.context') : 0xeace; // TODO: We don't use AsyncMode or ConcurrentMode anymore. They were temporary\n// (unstable) APIs that have been removed. Can we remove the symbols?\n\nvar REACT_ASYNC_MODE_TYPE = hasSymbol ? Symbol.for('react.async_mode') : 0xeacf;\nvar REACT_CONCURRENT_MODE_TYPE = hasSymbol ? Symbol.for('react.concurrent_mode') : 0xeacf;\nvar REACT_FORWARD_REF_TYPE = hasSymbol ? Symbol.for('react.forward_ref') : 0xead0;\nvar REACT_SUSPENSE_TYPE = hasSymbol ? Symbol.for('react.suspense') : 0xead1;\nvar REACT_SUSPENSE_LIST_TYPE = hasSymbol ? Symbol.for('react.suspense_list') : 0xead8;\nvar REACT_MEMO_TYPE = hasSymbol ? Symbol.for('react.memo') : 0xead3;\nvar REACT_LAZY_TYPE = hasSymbol ? Symbol.for('react.lazy') : 0xead4;\nvar REACT_BLOCK_TYPE = hasSymbol ? Symbol.for('react.block') : 0xead9;\nvar REACT_FUNDAMENTAL_TYPE = hasSymbol ? Symbol.for('react.fundamental') : 0xead5;\nvar REACT_RESPONDER_TYPE = hasSymbol ? Symbol.for('react.responder') : 0xead6;\nvar REACT_SCOPE_TYPE = hasSymbol ? Symbol.for('react.scope') : 0xead7;\n\nfunction isValidElementType(type) {\n return typeof type === 'string' || typeof type === 'function' || // Note: its typeof might be other than 'symbol' or 'number' if it's a polyfill.\n type === REACT_FRAGMENT_TYPE || type === REACT_CONCURRENT_MODE_TYPE || type === REACT_PROFILER_TYPE || type === REACT_STRICT_MODE_TYPE || type === REACT_SUSPENSE_TYPE || type === REACT_SUSPENSE_LIST_TYPE || typeof type === 'object' && type !== null && (type.$$typeof === REACT_LAZY_TYPE || type.$$typeof === REACT_MEMO_TYPE || type.$$typeof === REACT_PROVIDER_TYPE || type.$$typeof === REACT_CONTEXT_TYPE || type.$$typeof === REACT_FORWARD_REF_TYPE || type.$$typeof === REACT_FUNDAMENTAL_TYPE || type.$$typeof === REACT_RESPONDER_TYPE || type.$$typeof === REACT_SCOPE_TYPE || type.$$typeof === REACT_BLOCK_TYPE);\n}\n\nfunction typeOf(object) {\n if (typeof object === 'object' && object !== null) {\n var $$typeof = object.$$typeof;\n\n switch ($$typeof) {\n case REACT_ELEMENT_TYPE:\n var type = object.type;\n\n switch (type) {\n case REACT_ASYNC_MODE_TYPE:\n case REACT_CONCURRENT_MODE_TYPE:\n case REACT_FRAGMENT_TYPE:\n case REACT_PROFILER_TYPE:\n case REACT_STRICT_MODE_TYPE:\n case REACT_SUSPENSE_TYPE:\n return type;\n\n default:\n var $$typeofType = type && type.$$typeof;\n\n switch ($$typeofType) {\n case REACT_CONTEXT_TYPE:\n case REACT_FORWARD_REF_TYPE:\n case REACT_LAZY_TYPE:\n case REACT_MEMO_TYPE:\n case REACT_PROVIDER_TYPE:\n return $$typeofType;\n\n default:\n return $$typeof;\n }\n\n }\n\n case REACT_PORTAL_TYPE:\n return $$typeof;\n }\n }\n\n return undefined;\n} // AsyncMode is deprecated along with isAsyncMode\n\nvar AsyncMode = REACT_ASYNC_MODE_TYPE;\nvar ConcurrentMode = REACT_CONCURRENT_MODE_TYPE;\nvar ContextConsumer = REACT_CONTEXT_TYPE;\nvar ContextProvider = REACT_PROVIDER_TYPE;\nvar Element = REACT_ELEMENT_TYPE;\nvar ForwardRef = REACT_FORWARD_REF_TYPE;\nvar Fragment = REACT_FRAGMENT_TYPE;\nvar Lazy = REACT_LAZY_TYPE;\nvar Memo = REACT_MEMO_TYPE;\nvar Portal = REACT_PORTAL_TYPE;\nvar Profiler = REACT_PROFILER_TYPE;\nvar StrictMode = REACT_STRICT_MODE_TYPE;\nvar Suspense = REACT_SUSPENSE_TYPE;\nvar hasWarnedAboutDeprecatedIsAsyncMode = false; // AsyncMode should be deprecated\n\nfunction isAsyncMode(object) {\n {\n if (!hasWarnedAboutDeprecatedIsAsyncMode) {\n hasWarnedAboutDeprecatedIsAsyncMode = true; // Using console['warn'] to evade Babel and ESLint\n\n console['warn']('The ReactIs.isAsyncMode() alias has been deprecated, ' + 'and will be removed in React 17+. Update your code to use ' + 'ReactIs.isConcurrentMode() instead. It has the exact same API.');\n }\n }\n\n return isConcurrentMode(object) || typeOf(object) === REACT_ASYNC_MODE_TYPE;\n}\nfunction isConcurrentMode(object) {\n return typeOf(object) === REACT_CONCURRENT_MODE_TYPE;\n}\nfunction isContextConsumer(object) {\n return typeOf(object) === REACT_CONTEXT_TYPE;\n}\nfunction isContextProvider(object) {\n return typeOf(object) === REACT_PROVIDER_TYPE;\n}\nfunction isElement(object) {\n return typeof object === 'object' && object !== null && object.$$typeof === REACT_ELEMENT_TYPE;\n}\nfunction isForwardRef(object) {\n return typeOf(object) === REACT_FORWARD_REF_TYPE;\n}\nfunction isFragment(object) {\n return typeOf(object) === REACT_FRAGMENT_TYPE;\n}\nfunction isLazy(object) {\n return typeOf(object) === REACT_LAZY_TYPE;\n}\nfunction isMemo(object) {\n return typeOf(object) === REACT_MEMO_TYPE;\n}\nfunction isPortal(object) {\n return typeOf(object) === REACT_PORTAL_TYPE;\n}\nfunction isProfiler(object) {\n return typeOf(object) === REACT_PROFILER_TYPE;\n}\nfunction isStrictMode(object) {\n return typeOf(object) === REACT_STRICT_MODE_TYPE;\n}\nfunction isSuspense(object) {\n return typeOf(object) === REACT_SUSPENSE_TYPE;\n}\n\nexports.AsyncMode = AsyncMode;\nexports.ConcurrentMode = ConcurrentMode;\nexports.ContextConsumer = ContextConsumer;\nexports.ContextProvider = ContextProvider;\nexports.Element = Element;\nexports.ForwardRef = ForwardRef;\nexports.Fragment = Fragment;\nexports.Lazy = Lazy;\nexports.Memo = Memo;\nexports.Portal = Portal;\nexports.Profiler = Profiler;\nexports.StrictMode = StrictMode;\nexports.Suspense = Suspense;\nexports.isAsyncMode = isAsyncMode;\nexports.isConcurrentMode = isConcurrentMode;\nexports.isContextConsumer = isContextConsumer;\nexports.isContextProvider = isContextProvider;\nexports.isElement = isElement;\nexports.isForwardRef = isForwardRef;\nexports.isFragment = isFragment;\nexports.isLazy = isLazy;\nexports.isMemo = isMemo;\nexports.isPortal = isPortal;\nexports.isProfiler = isProfiler;\nexports.isStrictMode = isStrictMode;\nexports.isSuspense = isSuspense;\nexports.isValidElementType = isValidElementType;\nexports.typeOf = typeOf;\n })();\n}\n","'use strict';\n\nif (process.env.NODE_ENV === 'production') {\n module.exports = require('./cjs/react-is.production.min.js');\n} else {\n module.exports = require('./cjs/react-is.development.js');\n}\n","/*\nobject-assign\n(c) Sindre Sorhus\n@license MIT\n*/\n\n'use strict';\n/* eslint-disable no-unused-vars */\nvar getOwnPropertySymbols = Object.getOwnPropertySymbols;\nvar hasOwnProperty = Object.prototype.hasOwnProperty;\nvar propIsEnumerable = Object.prototype.propertyIsEnumerable;\n\nfunction toObject(val) {\n\tif (val === null || val === undefined) {\n\t\tthrow new TypeError('Object.assign cannot be called with null or undefined');\n\t}\n\n\treturn Object(val);\n}\n\nfunction shouldUseNative() {\n\ttry {\n\t\tif (!Object.assign) {\n\t\t\treturn false;\n\t\t}\n\n\t\t// Detect buggy property enumeration order in older V8 versions.\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=4118\n\t\tvar test1 = new String('abc'); // eslint-disable-line no-new-wrappers\n\t\ttest1[5] = 'de';\n\t\tif (Object.getOwnPropertyNames(test1)[0] === '5') {\n\t\t\treturn false;\n\t\t}\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=3056\n\t\tvar test2 = {};\n\t\tfor (var i = 0; i < 10; i++) {\n\t\t\ttest2['_' + String.fromCharCode(i)] = i;\n\t\t}\n\t\tvar order2 = Object.getOwnPropertyNames(test2).map(function (n) {\n\t\t\treturn test2[n];\n\t\t});\n\t\tif (order2.join('') !== '0123456789') {\n\t\t\treturn false;\n\t\t}\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=3056\n\t\tvar test3 = {};\n\t\t'abcdefghijklmnopqrst'.split('').forEach(function (letter) {\n\t\t\ttest3[letter] = letter;\n\t\t});\n\t\tif (Object.keys(Object.assign({}, test3)).join('') !==\n\t\t\t\t'abcdefghijklmnopqrst') {\n\t\t\treturn false;\n\t\t}\n\n\t\treturn true;\n\t} catch (err) {\n\t\t// We don't expect any of the above to throw, but better to be safe.\n\t\treturn false;\n\t}\n}\n\nmodule.exports = shouldUseNative() ? Object.assign : function (target, source) {\n\tvar from;\n\tvar to = toObject(target);\n\tvar symbols;\n\n\tfor (var s = 1; s < arguments.length; s++) {\n\t\tfrom = Object(arguments[s]);\n\n\t\tfor (var key in from) {\n\t\t\tif (hasOwnProperty.call(from, key)) {\n\t\t\t\tto[key] = from[key];\n\t\t\t}\n\t\t}\n\n\t\tif (getOwnPropertySymbols) {\n\t\t\tsymbols = getOwnPropertySymbols(from);\n\t\t\tfor (var i = 0; i < symbols.length; i++) {\n\t\t\t\tif (propIsEnumerable.call(from, symbols[i])) {\n\t\t\t\t\tto[symbols[i]] = from[symbols[i]];\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\n\treturn to;\n};\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar ReactPropTypesSecret = 'SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED';\n\nmodule.exports = ReactPropTypesSecret;\n","module.exports = Function.call.bind(Object.prototype.hasOwnProperty);\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar printWarning = function() {};\n\nif (process.env.NODE_ENV !== 'production') {\n var ReactPropTypesSecret = require('./lib/ReactPropTypesSecret');\n var loggedTypeFailures = {};\n var has = require('./lib/has');\n\n printWarning = function(text) {\n var message = 'Warning: ' + text;\n if (typeof console !== 'undefined') {\n console.error(message);\n }\n try {\n // --- Welcome to debugging React ---\n // This error was thrown as a convenience so that you can use this stack\n // to find the callsite that caused this warning to fire.\n throw new Error(message);\n } catch (x) { /**/ }\n };\n}\n\n/**\n * Assert that the values match with the type specs.\n * Error messages are memorized and will only be shown once.\n *\n * @param {object} typeSpecs Map of name to a ReactPropType\n * @param {object} values Runtime values that need to be type-checked\n * @param {string} location e.g. \"prop\", \"context\", \"child context\"\n * @param {string} componentName Name of the component for error messages.\n * @param {?Function} getStack Returns the component stack.\n * @private\n */\nfunction checkPropTypes(typeSpecs, values, location, componentName, getStack) {\n if (process.env.NODE_ENV !== 'production') {\n for (var typeSpecName in typeSpecs) {\n if (has(typeSpecs, typeSpecName)) {\n var error;\n // Prop type validation may throw. In case they do, we don't want to\n // fail the render phase where it didn't fail before. So we log it.\n // After these have been cleaned up, we'll let them throw.\n try {\n // This is intentionally an invariant that gets caught. It's the same\n // behavior as without this statement except with a better message.\n if (typeof typeSpecs[typeSpecName] !== 'function') {\n var err = Error(\n (componentName || 'React class') + ': ' + location + ' type `' + typeSpecName + '` is invalid; ' +\n 'it must be a function, usually from the `prop-types` package, but received `' + typeof typeSpecs[typeSpecName] + '`.' +\n 'This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.'\n );\n err.name = 'Invariant Violation';\n throw err;\n }\n error = typeSpecs[typeSpecName](values, typeSpecName, componentName, location, null, ReactPropTypesSecret);\n } catch (ex) {\n error = ex;\n }\n if (error && !(error instanceof Error)) {\n printWarning(\n (componentName || 'React class') + ': type specification of ' +\n location + ' `' + typeSpecName + '` is invalid; the type checker ' +\n 'function must return `null` or an `Error` but returned a ' + typeof error + '. ' +\n 'You may have forgotten to pass an argument to the type checker ' +\n 'creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and ' +\n 'shape all require an argument).'\n );\n }\n if (error instanceof Error && !(error.message in loggedTypeFailures)) {\n // Only monitor this failure once because there tends to be a lot of the\n // same error.\n loggedTypeFailures[error.message] = true;\n\n var stack = getStack ? getStack() : '';\n\n printWarning(\n 'Failed ' + location + ' type: ' + error.message + (stack != null ? stack : '')\n );\n }\n }\n }\n }\n}\n\n/**\n * Resets warning cache when testing.\n *\n * @private\n */\ncheckPropTypes.resetWarningCache = function() {\n if (process.env.NODE_ENV !== 'production') {\n loggedTypeFailures = {};\n }\n}\n\nmodule.exports = checkPropTypes;\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar ReactIs = require('react-is');\nvar assign = require('object-assign');\n\nvar ReactPropTypesSecret = require('./lib/ReactPropTypesSecret');\nvar has = require('./lib/has');\nvar checkPropTypes = require('./checkPropTypes');\n\nvar printWarning = function() {};\n\nif (process.env.NODE_ENV !== 'production') {\n printWarning = function(text) {\n var message = 'Warning: ' + text;\n if (typeof console !== 'undefined') {\n console.error(message);\n }\n try {\n // --- Welcome to debugging React ---\n // This error was thrown as a convenience so that you can use this stack\n // to find the callsite that caused this warning to fire.\n throw new Error(message);\n } catch (x) {}\n };\n}\n\nfunction emptyFunctionThatReturnsNull() {\n return null;\n}\n\nmodule.exports = function(isValidElement, throwOnDirectAccess) {\n /* global Symbol */\n var ITERATOR_SYMBOL = typeof Symbol === 'function' && Symbol.iterator;\n var FAUX_ITERATOR_SYMBOL = '@@iterator'; // Before Symbol spec.\n\n /**\n * Returns the iterator method function contained on the iterable object.\n *\n * Be sure to invoke the function with the iterable as context:\n *\n * var iteratorFn = getIteratorFn(myIterable);\n * if (iteratorFn) {\n * var iterator = iteratorFn.call(myIterable);\n * ...\n * }\n *\n * @param {?object} maybeIterable\n * @return {?function}\n */\n function getIteratorFn(maybeIterable) {\n var iteratorFn = maybeIterable && (ITERATOR_SYMBOL && maybeIterable[ITERATOR_SYMBOL] || maybeIterable[FAUX_ITERATOR_SYMBOL]);\n if (typeof iteratorFn === 'function') {\n return iteratorFn;\n }\n }\n\n /**\n * Collection of methods that allow declaration and validation of props that are\n * supplied to React components. Example usage:\n *\n * var Props = require('ReactPropTypes');\n * var MyArticle = React.createClass({\n * propTypes: {\n * // An optional string prop named \"description\".\n * description: Props.string,\n *\n * // A required enum prop named \"category\".\n * category: Props.oneOf(['News','Photos']).isRequired,\n *\n * // A prop named \"dialog\" that requires an instance of Dialog.\n * dialog: Props.instanceOf(Dialog).isRequired\n * },\n * render: function() { ... }\n * });\n *\n * A more formal specification of how these methods are used:\n *\n * type := array|bool|func|object|number|string|oneOf([...])|instanceOf(...)\n * decl := ReactPropTypes.{type}(.isRequired)?\n *\n * Each and every declaration produces a function with the same signature. This\n * allows the creation of custom validation functions. For example:\n *\n * var MyLink = React.createClass({\n * propTypes: {\n * // An optional string or URI prop named \"href\".\n * href: function(props, propName, componentName) {\n * var propValue = props[propName];\n * if (propValue != null && typeof propValue !== 'string' &&\n * !(propValue instanceof URI)) {\n * return new Error(\n * 'Expected a string or an URI for ' + propName + ' in ' +\n * componentName\n * );\n * }\n * }\n * },\n * render: function() {...}\n * });\n *\n * @internal\n */\n\n var ANONYMOUS = '<>';\n\n // Important!\n // Keep this list in sync with production version in `./factoryWithThrowingShims.js`.\n var ReactPropTypes = {\n array: createPrimitiveTypeChecker('array'),\n bigint: createPrimitiveTypeChecker('bigint'),\n bool: createPrimitiveTypeChecker('boolean'),\n func: createPrimitiveTypeChecker('function'),\n number: createPrimitiveTypeChecker('number'),\n object: createPrimitiveTypeChecker('object'),\n string: createPrimitiveTypeChecker('string'),\n symbol: createPrimitiveTypeChecker('symbol'),\n\n any: createAnyTypeChecker(),\n arrayOf: createArrayOfTypeChecker,\n element: createElementTypeChecker(),\n elementType: createElementTypeTypeChecker(),\n instanceOf: createInstanceTypeChecker,\n node: createNodeChecker(),\n objectOf: createObjectOfTypeChecker,\n oneOf: createEnumTypeChecker,\n oneOfType: createUnionTypeChecker,\n shape: createShapeTypeChecker,\n exact: createStrictShapeTypeChecker,\n };\n\n /**\n * inlined Object.is polyfill to avoid requiring consumers ship their own\n * https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object/is\n */\n /*eslint-disable no-self-compare*/\n function is(x, y) {\n // SameValue algorithm\n if (x === y) {\n // Steps 1-5, 7-10\n // Steps 6.b-6.e: +0 != -0\n return x !== 0 || 1 / x === 1 / y;\n } else {\n // Step 6.a: NaN == NaN\n return x !== x && y !== y;\n }\n }\n /*eslint-enable no-self-compare*/\n\n /**\n * We use an Error-like object for backward compatibility as people may call\n * PropTypes directly and inspect their output. However, we don't use real\n * Errors anymore. We don't inspect their stack anyway, and creating them\n * is prohibitively expensive if they are created too often, such as what\n * happens in oneOfType() for any type before the one that matched.\n */\n function PropTypeError(message, data) {\n this.message = message;\n this.data = data && typeof data === 'object' ? data: {};\n this.stack = '';\n }\n // Make `instanceof Error` still work for returned errors.\n PropTypeError.prototype = Error.prototype;\n\n function createChainableTypeChecker(validate) {\n if (process.env.NODE_ENV !== 'production') {\n var manualPropTypeCallCache = {};\n var manualPropTypeWarningCount = 0;\n }\n function checkType(isRequired, props, propName, componentName, location, propFullName, secret) {\n componentName = componentName || ANONYMOUS;\n propFullName = propFullName || propName;\n\n if (secret !== ReactPropTypesSecret) {\n if (throwOnDirectAccess) {\n // New behavior only for users of `prop-types` package\n var err = new Error(\n 'Calling PropTypes validators directly is not supported by the `prop-types` package. ' +\n 'Use `PropTypes.checkPropTypes()` to call them. ' +\n 'Read more at http://fb.me/use-check-prop-types'\n );\n err.name = 'Invariant Violation';\n throw err;\n } else if (process.env.NODE_ENV !== 'production' && typeof console !== 'undefined') {\n // Old behavior for people using React.PropTypes\n var cacheKey = componentName + ':' + propName;\n if (\n !manualPropTypeCallCache[cacheKey] &&\n // Avoid spamming the console because they are often not actionable except for lib authors\n manualPropTypeWarningCount < 3\n ) {\n printWarning(\n 'You are manually calling a React.PropTypes validation ' +\n 'function for the `' + propFullName + '` prop on `' + componentName + '`. This is deprecated ' +\n 'and will throw in the standalone `prop-types` package. ' +\n 'You may be seeing this warning due to a third-party PropTypes ' +\n 'library. See https://fb.me/react-warning-dont-call-proptypes ' + 'for details.'\n );\n manualPropTypeCallCache[cacheKey] = true;\n manualPropTypeWarningCount++;\n }\n }\n }\n if (props[propName] == null) {\n if (isRequired) {\n if (props[propName] === null) {\n return new PropTypeError('The ' + location + ' `' + propFullName + '` is marked as required ' + ('in `' + componentName + '`, but its value is `null`.'));\n }\n return new PropTypeError('The ' + location + ' `' + propFullName + '` is marked as required in ' + ('`' + componentName + '`, but its value is `undefined`.'));\n }\n return null;\n } else {\n return validate(props, propName, componentName, location, propFullName);\n }\n }\n\n var chainedCheckType = checkType.bind(null, false);\n chainedCheckType.isRequired = checkType.bind(null, true);\n\n return chainedCheckType;\n }\n\n function createPrimitiveTypeChecker(expectedType) {\n function validate(props, propName, componentName, location, propFullName, secret) {\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== expectedType) {\n // `propValue` being instance of, say, date/regexp, pass the 'object'\n // check, but we can offer a more precise error message here rather than\n // 'of type `object`'.\n var preciseType = getPreciseType(propValue);\n\n return new PropTypeError(\n 'Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + preciseType + '` supplied to `' + componentName + '`, expected ') + ('`' + expectedType + '`.'),\n {expectedType: expectedType}\n );\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createAnyTypeChecker() {\n return createChainableTypeChecker(emptyFunctionThatReturnsNull);\n }\n\n function createArrayOfTypeChecker(typeChecker) {\n function validate(props, propName, componentName, location, propFullName) {\n if (typeof typeChecker !== 'function') {\n return new PropTypeError('Property `' + propFullName + '` of component `' + componentName + '` has invalid PropType notation inside arrayOf.');\n }\n var propValue = props[propName];\n if (!Array.isArray(propValue)) {\n var propType = getPropType(propValue);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected an array.'));\n }\n for (var i = 0; i < propValue.length; i++) {\n var error = typeChecker(propValue, i, componentName, location, propFullName + '[' + i + ']', ReactPropTypesSecret);\n if (error instanceof Error) {\n return error;\n }\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createElementTypeChecker() {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n if (!isValidElement(propValue)) {\n var propType = getPropType(propValue);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected a single ReactElement.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createElementTypeTypeChecker() {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n if (!ReactIs.isValidElementType(propValue)) {\n var propType = getPropType(propValue);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected a single ReactElement type.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createInstanceTypeChecker(expectedClass) {\n function validate(props, propName, componentName, location, propFullName) {\n if (!(props[propName] instanceof expectedClass)) {\n var expectedClassName = expectedClass.name || ANONYMOUS;\n var actualClassName = getClassName(props[propName]);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + actualClassName + '` supplied to `' + componentName + '`, expected ') + ('instance of `' + expectedClassName + '`.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createEnumTypeChecker(expectedValues) {\n if (!Array.isArray(expectedValues)) {\n if (process.env.NODE_ENV !== 'production') {\n if (arguments.length > 1) {\n printWarning(\n 'Invalid arguments supplied to oneOf, expected an array, got ' + arguments.length + ' arguments. ' +\n 'A common mistake is to write oneOf(x, y, z) instead of oneOf([x, y, z]).'\n );\n } else {\n printWarning('Invalid argument supplied to oneOf, expected an array.');\n }\n }\n return emptyFunctionThatReturnsNull;\n }\n\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n for (var i = 0; i < expectedValues.length; i++) {\n if (is(propValue, expectedValues[i])) {\n return null;\n }\n }\n\n var valuesString = JSON.stringify(expectedValues, function replacer(key, value) {\n var type = getPreciseType(value);\n if (type === 'symbol') {\n return String(value);\n }\n return value;\n });\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of value `' + String(propValue) + '` ' + ('supplied to `' + componentName + '`, expected one of ' + valuesString + '.'));\n }\n return createChainableTypeChecker(validate);\n }\n\n function createObjectOfTypeChecker(typeChecker) {\n function validate(props, propName, componentName, location, propFullName) {\n if (typeof typeChecker !== 'function') {\n return new PropTypeError('Property `' + propFullName + '` of component `' + componentName + '` has invalid PropType notation inside objectOf.');\n }\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== 'object') {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected an object.'));\n }\n for (var key in propValue) {\n if (has(propValue, key)) {\n var error = typeChecker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret);\n if (error instanceof Error) {\n return error;\n }\n }\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createUnionTypeChecker(arrayOfTypeCheckers) {\n if (!Array.isArray(arrayOfTypeCheckers)) {\n process.env.NODE_ENV !== 'production' ? printWarning('Invalid argument supplied to oneOfType, expected an instance of array.') : void 0;\n return emptyFunctionThatReturnsNull;\n }\n\n for (var i = 0; i < arrayOfTypeCheckers.length; i++) {\n var checker = arrayOfTypeCheckers[i];\n if (typeof checker !== 'function') {\n printWarning(\n 'Invalid argument supplied to oneOfType. Expected an array of check functions, but ' +\n 'received ' + getPostfixForTypeWarning(checker) + ' at index ' + i + '.'\n );\n return emptyFunctionThatReturnsNull;\n }\n }\n\n function validate(props, propName, componentName, location, propFullName) {\n var expectedTypes = [];\n for (var i = 0; i < arrayOfTypeCheckers.length; i++) {\n var checker = arrayOfTypeCheckers[i];\n var checkerResult = checker(props, propName, componentName, location, propFullName, ReactPropTypesSecret);\n if (checkerResult == null) {\n return null;\n }\n if (checkerResult.data && has(checkerResult.data, 'expectedType')) {\n expectedTypes.push(checkerResult.data.expectedType);\n }\n }\n var expectedTypesMessage = (expectedTypes.length > 0) ? ', expected one of type [' + expectedTypes.join(', ') + ']': '';\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` supplied to ' + ('`' + componentName + '`' + expectedTypesMessage + '.'));\n }\n return createChainableTypeChecker(validate);\n }\n\n function createNodeChecker() {\n function validate(props, propName, componentName, location, propFullName) {\n if (!isNode(props[propName])) {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` supplied to ' + ('`' + componentName + '`, expected a ReactNode.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function invalidValidatorError(componentName, location, propFullName, key, type) {\n return new PropTypeError(\n (componentName || 'React class') + ': ' + location + ' type `' + propFullName + '.' + key + '` is invalid; ' +\n 'it must be a function, usually from the `prop-types` package, but received `' + type + '`.'\n );\n }\n\n function createShapeTypeChecker(shapeTypes) {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== 'object') {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type `' + propType + '` ' + ('supplied to `' + componentName + '`, expected `object`.'));\n }\n for (var key in shapeTypes) {\n var checker = shapeTypes[key];\n if (typeof checker !== 'function') {\n return invalidValidatorError(componentName, location, propFullName, key, getPreciseType(checker));\n }\n var error = checker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret);\n if (error) {\n return error;\n }\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createStrictShapeTypeChecker(shapeTypes) {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== 'object') {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type `' + propType + '` ' + ('supplied to `' + componentName + '`, expected `object`.'));\n }\n // We need to check all keys in case some are required but missing from props.\n var allKeys = assign({}, props[propName], shapeTypes);\n for (var key in allKeys) {\n var checker = shapeTypes[key];\n if (has(shapeTypes, key) && typeof checker !== 'function') {\n return invalidValidatorError(componentName, location, propFullName, key, getPreciseType(checker));\n }\n if (!checker) {\n return new PropTypeError(\n 'Invalid ' + location + ' `' + propFullName + '` key `' + key + '` supplied to `' + componentName + '`.' +\n '\\nBad object: ' + JSON.stringify(props[propName], null, ' ') +\n '\\nValid keys: ' + JSON.stringify(Object.keys(shapeTypes), null, ' ')\n );\n }\n var error = checker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret);\n if (error) {\n return error;\n }\n }\n return null;\n }\n\n return createChainableTypeChecker(validate);\n }\n\n function isNode(propValue) {\n switch (typeof propValue) {\n case 'number':\n case 'string':\n case 'undefined':\n return true;\n case 'boolean':\n return !propValue;\n case 'object':\n if (Array.isArray(propValue)) {\n return propValue.every(isNode);\n }\n if (propValue === null || isValidElement(propValue)) {\n return true;\n }\n\n var iteratorFn = getIteratorFn(propValue);\n if (iteratorFn) {\n var iterator = iteratorFn.call(propValue);\n var step;\n if (iteratorFn !== propValue.entries) {\n while (!(step = iterator.next()).done) {\n if (!isNode(step.value)) {\n return false;\n }\n }\n } else {\n // Iterator will provide entry [k,v] tuples rather than values.\n while (!(step = iterator.next()).done) {\n var entry = step.value;\n if (entry) {\n if (!isNode(entry[1])) {\n return false;\n }\n }\n }\n }\n } else {\n return false;\n }\n\n return true;\n default:\n return false;\n }\n }\n\n function isSymbol(propType, propValue) {\n // Native Symbol.\n if (propType === 'symbol') {\n return true;\n }\n\n // falsy value can't be a Symbol\n if (!propValue) {\n return false;\n }\n\n // 19.4.3.5 Symbol.prototype[@@toStringTag] === 'Symbol'\n if (propValue['@@toStringTag'] === 'Symbol') {\n return true;\n }\n\n // Fallback for non-spec compliant Symbols which are polyfilled.\n if (typeof Symbol === 'function' && propValue instanceof Symbol) {\n return true;\n }\n\n return false;\n }\n\n // Equivalent of `typeof` but with special handling for array and regexp.\n function getPropType(propValue) {\n var propType = typeof propValue;\n if (Array.isArray(propValue)) {\n return 'array';\n }\n if (propValue instanceof RegExp) {\n // Old webkits (at least until Android 4.0) return 'function' rather than\n // 'object' for typeof a RegExp. We'll normalize this here so that /bla/\n // passes PropTypes.object.\n return 'object';\n }\n if (isSymbol(propType, propValue)) {\n return 'symbol';\n }\n return propType;\n }\n\n // This handles more types than `getPropType`. Only used for error messages.\n // See `createPrimitiveTypeChecker`.\n function getPreciseType(propValue) {\n if (typeof propValue === 'undefined' || propValue === null) {\n return '' + propValue;\n }\n var propType = getPropType(propValue);\n if (propType === 'object') {\n if (propValue instanceof Date) {\n return 'date';\n } else if (propValue instanceof RegExp) {\n return 'regexp';\n }\n }\n return propType;\n }\n\n // Returns a string that is postfixed to a warning about an invalid type.\n // For example, \"undefined\" or \"of type array\"\n function getPostfixForTypeWarning(value) {\n var type = getPreciseType(value);\n switch (type) {\n case 'array':\n case 'object':\n return 'an ' + type;\n case 'boolean':\n case 'date':\n case 'regexp':\n return 'a ' + type;\n default:\n return type;\n }\n }\n\n // Returns class name of the object, if any.\n function getClassName(propValue) {\n if (!propValue.constructor || !propValue.constructor.name) {\n return ANONYMOUS;\n }\n return propValue.constructor.name;\n }\n\n ReactPropTypes.checkPropTypes = checkPropTypes;\n ReactPropTypes.resetWarningCache = checkPropTypes.resetWarningCache;\n ReactPropTypes.PropTypes = ReactPropTypes;\n\n return ReactPropTypes;\n};\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar ReactPropTypesSecret = require('./lib/ReactPropTypesSecret');\n\nfunction emptyFunction() {}\nfunction emptyFunctionWithReset() {}\nemptyFunctionWithReset.resetWarningCache = emptyFunction;\n\nmodule.exports = function() {\n function shim(props, propName, componentName, location, propFullName, secret) {\n if (secret === ReactPropTypesSecret) {\n // It is still safe when called from React.\n return;\n }\n var err = new Error(\n 'Calling PropTypes validators directly is not supported by the `prop-types` package. ' +\n 'Use PropTypes.checkPropTypes() to call them. ' +\n 'Read more at http://fb.me/use-check-prop-types'\n );\n err.name = 'Invariant Violation';\n throw err;\n };\n shim.isRequired = shim;\n function getShim() {\n return shim;\n };\n // Important!\n // Keep this list in sync with production version in `./factoryWithTypeCheckers.js`.\n var ReactPropTypes = {\n array: shim,\n bigint: shim,\n bool: shim,\n func: shim,\n number: shim,\n object: shim,\n string: shim,\n symbol: shim,\n\n any: shim,\n arrayOf: getShim,\n element: shim,\n elementType: shim,\n instanceOf: getShim,\n node: shim,\n objectOf: getShim,\n oneOf: getShim,\n oneOfType: getShim,\n shape: getShim,\n exact: getShim,\n\n checkPropTypes: emptyFunctionWithReset,\n resetWarningCache: emptyFunction\n };\n\n ReactPropTypes.PropTypes = ReactPropTypes;\n\n return ReactPropTypes;\n};\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\nif (process.env.NODE_ENV !== 'production') {\n var ReactIs = require('react-is');\n\n // By explicitly using `prop-types` you are opting into new development behavior.\n // http://fb.me/prop-types-in-prod\n var throwOnDirectAccess = true;\n module.exports = require('./factoryWithTypeCheckers')(ReactIs.isElement, throwOnDirectAccess);\n} else {\n // By explicitly using `prop-types` you are opting into new production behavior.\n // http://fb.me/prop-types-in-prod\n module.exports = require('./factoryWithThrowingShims')();\n}\n","import PropTypes from 'prop-types';\nimport chainPropTypes from '../chainPropTypes';\nfunction isClassComponent(elementType) {\n // elementType.prototype?.isReactComponent\n const {\n prototype = {}\n } = elementType;\n return Boolean(prototype.isReactComponent);\n}\nfunction acceptingRef(props, propName, componentName, location, propFullName) {\n const element = props[propName];\n const safePropName = propFullName || propName;\n if (element == null ||\n // When server-side rendering React doesn't warn either.\n // This is not an accurate check for SSR.\n // This is only in place for Emotion compat.\n // TODO: Revisit once https://github.com/facebook/react/issues/20047 is resolved.\n typeof window === 'undefined') {\n return null;\n }\n let warningHint;\n const elementType = element.type;\n /**\n * Blacklisting instead of whitelisting\n *\n * Blacklisting will miss some components, such as React.Fragment. Those will at least\n * trigger a warning in React.\n * We can't whitelist because there is no safe way to detect React.forwardRef\n * or class components. \"Safe\" means there's no public API.\n *\n */\n if (typeof elementType === 'function' && !isClassComponent(elementType)) {\n warningHint = 'Did you accidentally use a plain function component for an element instead?';\n }\n if (warningHint !== undefined) {\n return new Error(`Invalid ${location} \\`${safePropName}\\` supplied to \\`${componentName}\\`. ` + `Expected an element that can hold a ref. ${warningHint} ` + 'For more information see https://mui.com/r/caveat-with-refs-guide');\n }\n return null;\n}\nconst elementAcceptingRef = chainPropTypes(PropTypes.element, acceptingRef);\nelementAcceptingRef.isRequired = chainPropTypes(PropTypes.element.isRequired, acceptingRef);\nexport default elementAcceptingRef;","import _extends from \"@babel/runtime/helpers/esm/extends\";\n// This module is based on https://github.com/airbnb/prop-types-exact repository.\n// However, in order to reduce the number of dependencies and to remove some extra safe checks\n// the module was forked.\n\nconst specialProperty = 'exact-prop: \\u200b';\nexport default function exactProp(propTypes) {\n if (process.env.NODE_ENV === 'production') {\n return propTypes;\n }\n return _extends({}, propTypes, {\n [specialProperty]: props => {\n const unsupportedProps = Object.keys(props).filter(prop => !propTypes.hasOwnProperty(prop));\n if (unsupportedProps.length > 0) {\n return new Error(`The following props are not supported: ${unsupportedProps.map(prop => `\\`${prop}\\``).join(', ')}. Please remove them.`);\n }\n return null;\n }\n });\n}","/**\n * WARNING: Don't import this directly.\n * Use `MuiError` from `@mui/internal-babel-macros/MuiError.macro` instead.\n * @param {number} code\n */\nexport default function formatMuiErrorMessage(code) {\n // Apply babel-plugin-transform-template-literals in loose mode\n // loose mode is safe if we're concatenating primitives\n // see https://babeljs.io/docs/en/babel-plugin-transform-template-literals#loose\n /* eslint-disable prefer-template */\n let url = 'https://mui.com/production-error/?code=' + code;\n for (let i = 1; i < arguments.length; i += 1) {\n // rest params over-transpile for this case\n // eslint-disable-next-line prefer-rest-params\n url += '&args[]=' + encodeURIComponent(arguments[i]);\n }\n return 'Minified MUI error #' + code + '; visit ' + url + ' for the full message.';\n /* eslint-enable prefer-template */\n}","/**\n * @license React\n * react-is.production.min.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n'use strict';var b=Symbol.for(\"react.element\"),c=Symbol.for(\"react.portal\"),d=Symbol.for(\"react.fragment\"),e=Symbol.for(\"react.strict_mode\"),f=Symbol.for(\"react.profiler\"),g=Symbol.for(\"react.provider\"),h=Symbol.for(\"react.context\"),k=Symbol.for(\"react.server_context\"),l=Symbol.for(\"react.forward_ref\"),m=Symbol.for(\"react.suspense\"),n=Symbol.for(\"react.suspense_list\"),p=Symbol.for(\"react.memo\"),q=Symbol.for(\"react.lazy\"),t=Symbol.for(\"react.offscreen\"),u;u=Symbol.for(\"react.module.reference\");\nfunction v(a){if(\"object\"===typeof a&&null!==a){var r=a.$$typeof;switch(r){case b:switch(a=a.type,a){case d:case f:case e:case m:case n:return a;default:switch(a=a&&a.$$typeof,a){case k:case h:case l:case q:case p:case g:return a;default:return r}}case c:return r}}}exports.ContextConsumer=h;exports.ContextProvider=g;exports.Element=b;exports.ForwardRef=l;exports.Fragment=d;exports.Lazy=q;exports.Memo=p;exports.Portal=c;exports.Profiler=f;exports.StrictMode=e;exports.Suspense=m;\nexports.SuspenseList=n;exports.isAsyncMode=function(){return!1};exports.isConcurrentMode=function(){return!1};exports.isContextConsumer=function(a){return v(a)===h};exports.isContextProvider=function(a){return v(a)===g};exports.isElement=function(a){return\"object\"===typeof a&&null!==a&&a.$$typeof===b};exports.isForwardRef=function(a){return v(a)===l};exports.isFragment=function(a){return v(a)===d};exports.isLazy=function(a){return v(a)===q};exports.isMemo=function(a){return v(a)===p};\nexports.isPortal=function(a){return v(a)===c};exports.isProfiler=function(a){return v(a)===f};exports.isStrictMode=function(a){return v(a)===e};exports.isSuspense=function(a){return v(a)===m};exports.isSuspenseList=function(a){return v(a)===n};\nexports.isValidElementType=function(a){return\"string\"===typeof a||\"function\"===typeof a||a===d||a===f||a===e||a===m||a===n||a===t||\"object\"===typeof a&&null!==a&&(a.$$typeof===q||a.$$typeof===p||a.$$typeof===g||a.$$typeof===h||a.$$typeof===l||a.$$typeof===u||void 0!==a.getModuleId)?!0:!1};exports.typeOf=v;\n","/**\n * @license React\n * react-is.development.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nif (process.env.NODE_ENV !== \"production\") {\n (function() {\n'use strict';\n\n// ATTENTION\n// When adding new symbols to this file,\n// Please consider also adding to 'react-devtools-shared/src/backend/ReactSymbols'\n// The Symbol used to tag the ReactElement-like types.\nvar REACT_ELEMENT_TYPE = Symbol.for('react.element');\nvar REACT_PORTAL_TYPE = Symbol.for('react.portal');\nvar REACT_FRAGMENT_TYPE = Symbol.for('react.fragment');\nvar REACT_STRICT_MODE_TYPE = Symbol.for('react.strict_mode');\nvar REACT_PROFILER_TYPE = Symbol.for('react.profiler');\nvar REACT_PROVIDER_TYPE = Symbol.for('react.provider');\nvar REACT_CONTEXT_TYPE = Symbol.for('react.context');\nvar REACT_SERVER_CONTEXT_TYPE = Symbol.for('react.server_context');\nvar REACT_FORWARD_REF_TYPE = Symbol.for('react.forward_ref');\nvar REACT_SUSPENSE_TYPE = Symbol.for('react.suspense');\nvar REACT_SUSPENSE_LIST_TYPE = Symbol.for('react.suspense_list');\nvar REACT_MEMO_TYPE = Symbol.for('react.memo');\nvar REACT_LAZY_TYPE = Symbol.for('react.lazy');\nvar REACT_OFFSCREEN_TYPE = Symbol.for('react.offscreen');\n\n// -----------------------------------------------------------------------------\n\nvar enableScopeAPI = false; // Experimental Create Event Handle API.\nvar enableCacheElement = false;\nvar enableTransitionTracing = false; // No known bugs, but needs performance testing\n\nvar enableLegacyHidden = false; // Enables unstable_avoidThisFallback feature in Fiber\n// stuff. Intended to enable React core members to more easily debug scheduling\n// issues in DEV builds.\n\nvar enableDebugTracing = false; // Track which Fiber(s) schedule render work.\n\nvar REACT_MODULE_REFERENCE;\n\n{\n REACT_MODULE_REFERENCE = Symbol.for('react.module.reference');\n}\n\nfunction isValidElementType(type) {\n if (typeof type === 'string' || typeof type === 'function') {\n return true;\n } // Note: typeof might be other than 'symbol' or 'number' (e.g. if it's a polyfill).\n\n\n if (type === REACT_FRAGMENT_TYPE || type === REACT_PROFILER_TYPE || enableDebugTracing || type === REACT_STRICT_MODE_TYPE || type === REACT_SUSPENSE_TYPE || type === REACT_SUSPENSE_LIST_TYPE || enableLegacyHidden || type === REACT_OFFSCREEN_TYPE || enableScopeAPI || enableCacheElement || enableTransitionTracing ) {\n return true;\n }\n\n if (typeof type === 'object' && type !== null) {\n if (type.$$typeof === REACT_LAZY_TYPE || type.$$typeof === REACT_MEMO_TYPE || type.$$typeof === REACT_PROVIDER_TYPE || type.$$typeof === REACT_CONTEXT_TYPE || type.$$typeof === REACT_FORWARD_REF_TYPE || // This needs to include all possible module reference object\n // types supported by any Flight configuration anywhere since\n // we don't know which Flight build this will end up being used\n // with.\n type.$$typeof === REACT_MODULE_REFERENCE || type.getModuleId !== undefined) {\n return true;\n }\n }\n\n return false;\n}\n\nfunction typeOf(object) {\n if (typeof object === 'object' && object !== null) {\n var $$typeof = object.$$typeof;\n\n switch ($$typeof) {\n case REACT_ELEMENT_TYPE:\n var type = object.type;\n\n switch (type) {\n case REACT_FRAGMENT_TYPE:\n case REACT_PROFILER_TYPE:\n case REACT_STRICT_MODE_TYPE:\n case REACT_SUSPENSE_TYPE:\n case REACT_SUSPENSE_LIST_TYPE:\n return type;\n\n default:\n var $$typeofType = type && type.$$typeof;\n\n switch ($$typeofType) {\n case REACT_SERVER_CONTEXT_TYPE:\n case REACT_CONTEXT_TYPE:\n case REACT_FORWARD_REF_TYPE:\n case REACT_LAZY_TYPE:\n case REACT_MEMO_TYPE:\n case REACT_PROVIDER_TYPE:\n return $$typeofType;\n\n default:\n return $$typeof;\n }\n\n }\n\n case REACT_PORTAL_TYPE:\n return $$typeof;\n }\n }\n\n return undefined;\n}\nvar ContextConsumer = REACT_CONTEXT_TYPE;\nvar ContextProvider = REACT_PROVIDER_TYPE;\nvar Element = REACT_ELEMENT_TYPE;\nvar ForwardRef = REACT_FORWARD_REF_TYPE;\nvar Fragment = REACT_FRAGMENT_TYPE;\nvar Lazy = REACT_LAZY_TYPE;\nvar Memo = REACT_MEMO_TYPE;\nvar Portal = REACT_PORTAL_TYPE;\nvar Profiler = REACT_PROFILER_TYPE;\nvar StrictMode = REACT_STRICT_MODE_TYPE;\nvar Suspense = REACT_SUSPENSE_TYPE;\nvar SuspenseList = REACT_SUSPENSE_LIST_TYPE;\nvar hasWarnedAboutDeprecatedIsAsyncMode = false;\nvar hasWarnedAboutDeprecatedIsConcurrentMode = false; // AsyncMode should be deprecated\n\nfunction isAsyncMode(object) {\n {\n if (!hasWarnedAboutDeprecatedIsAsyncMode) {\n hasWarnedAboutDeprecatedIsAsyncMode = true; // Using console['warn'] to evade Babel and ESLint\n\n console['warn']('The ReactIs.isAsyncMode() alias has been deprecated, ' + 'and will be removed in React 18+.');\n }\n }\n\n return false;\n}\nfunction isConcurrentMode(object) {\n {\n if (!hasWarnedAboutDeprecatedIsConcurrentMode) {\n hasWarnedAboutDeprecatedIsConcurrentMode = true; // Using console['warn'] to evade Babel and ESLint\n\n console['warn']('The ReactIs.isConcurrentMode() alias has been deprecated, ' + 'and will be removed in React 18+.');\n }\n }\n\n return false;\n}\nfunction isContextConsumer(object) {\n return typeOf(object) === REACT_CONTEXT_TYPE;\n}\nfunction isContextProvider(object) {\n return typeOf(object) === REACT_PROVIDER_TYPE;\n}\nfunction isElement(object) {\n return typeof object === 'object' && object !== null && object.$$typeof === REACT_ELEMENT_TYPE;\n}\nfunction isForwardRef(object) {\n return typeOf(object) === REACT_FORWARD_REF_TYPE;\n}\nfunction isFragment(object) {\n return typeOf(object) === REACT_FRAGMENT_TYPE;\n}\nfunction isLazy(object) {\n return typeOf(object) === REACT_LAZY_TYPE;\n}\nfunction isMemo(object) {\n return typeOf(object) === REACT_MEMO_TYPE;\n}\nfunction isPortal(object) {\n return typeOf(object) === REACT_PORTAL_TYPE;\n}\nfunction isProfiler(object) {\n return typeOf(object) === REACT_PROFILER_TYPE;\n}\nfunction isStrictMode(object) {\n return typeOf(object) === REACT_STRICT_MODE_TYPE;\n}\nfunction isSuspense(object) {\n return typeOf(object) === REACT_SUSPENSE_TYPE;\n}\nfunction isSuspenseList(object) {\n return typeOf(object) === REACT_SUSPENSE_LIST_TYPE;\n}\n\nexports.ContextConsumer = ContextConsumer;\nexports.ContextProvider = ContextProvider;\nexports.Element = Element;\nexports.ForwardRef = ForwardRef;\nexports.Fragment = Fragment;\nexports.Lazy = Lazy;\nexports.Memo = Memo;\nexports.Portal = Portal;\nexports.Profiler = Profiler;\nexports.StrictMode = StrictMode;\nexports.Suspense = Suspense;\nexports.SuspenseList = SuspenseList;\nexports.isAsyncMode = isAsyncMode;\nexports.isConcurrentMode = isConcurrentMode;\nexports.isContextConsumer = isContextConsumer;\nexports.isContextProvider = isContextProvider;\nexports.isElement = isElement;\nexports.isForwardRef = isForwardRef;\nexports.isFragment = isFragment;\nexports.isLazy = isLazy;\nexports.isMemo = isMemo;\nexports.isPortal = isPortal;\nexports.isProfiler = isProfiler;\nexports.isStrictMode = isStrictMode;\nexports.isSuspense = isSuspense;\nexports.isSuspenseList = isSuspenseList;\nexports.isValidElementType = isValidElementType;\nexports.typeOf = typeOf;\n })();\n}\n","'use strict';\n\nif (process.env.NODE_ENV === 'production') {\n module.exports = require('./cjs/react-is.production.min.js');\n} else {\n module.exports = require('./cjs/react-is.development.js');\n}\n","import { ForwardRef, Memo } from 'react-is';\n\n// Simplified polyfill for IE11 support\n// https://github.com/JamesMGreene/Function.name/blob/58b314d4a983110c3682f1228f845d39ccca1817/Function.name.js#L3\nconst fnNameMatchRegex = /^\\s*function(?:\\s|\\s*\\/\\*.*\\*\\/\\s*)+([^(\\s/]*)\\s*/;\nexport function getFunctionName(fn) {\n const match = `${fn}`.match(fnNameMatchRegex);\n const name = match && match[1];\n return name || '';\n}\nfunction getFunctionComponentName(Component, fallback = '') {\n return Component.displayName || Component.name || getFunctionName(Component) || fallback;\n}\nfunction getWrappedName(outerType, innerType, wrapperName) {\n const functionName = getFunctionComponentName(innerType);\n return outerType.displayName || (functionName !== '' ? `${wrapperName}(${functionName})` : wrapperName);\n}\n\n/**\n * cherry-pick from\n * https://github.com/facebook/react/blob/769b1f270e1251d9dbdce0fcbd9e92e502d059b8/packages/shared/getComponentName.js\n * originally forked from recompose/getDisplayName with added IE11 support\n */\nexport default function getDisplayName(Component) {\n if (Component == null) {\n return undefined;\n }\n if (typeof Component === 'string') {\n return Component;\n }\n if (typeof Component === 'function') {\n return getFunctionComponentName(Component, 'Component');\n }\n\n // TypeScript can't have components as objects but they exist in the form of `memo` or `Suspense`\n if (typeof Component === 'object') {\n switch (Component.$$typeof) {\n case ForwardRef:\n return getWrappedName(Component, Component.render, 'ForwardRef');\n case Memo:\n return getWrappedName(Component, Component.type, 'memo');\n default:\n return undefined;\n }\n }\n return undefined;\n}","export default function HTMLElementType(props, propName, componentName, location, propFullName) {\n if (process.env.NODE_ENV === 'production') {\n return null;\n }\n const propValue = props[propName];\n const safePropName = propFullName || propName;\n if (propValue == null) {\n return null;\n }\n if (propValue && propValue.nodeType !== 1) {\n return new Error(`Invalid ${location} \\`${safePropName}\\` supplied to \\`${componentName}\\`. ` + `Expected an HTMLElement.`);\n }\n return null;\n}","import PropTypes from 'prop-types';\nconst refType = PropTypes.oneOfType([PropTypes.func, PropTypes.object]);\nexport default refType;","import _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\n// It should to be noted that this function isn't equivalent to `text-transform: capitalize`.\n//\n// A strict capitalization should uppercase the first letter of each word in the sentence.\n// We only handle the first word.\nexport default function capitalize(string) {\n if (typeof string !== 'string') {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: \\`capitalize(string)\\` expects a string argument.` : _formatMuiErrorMessage(7));\n }\n return string.charAt(0).toUpperCase() + string.slice(1);\n}","/**\n * Safe chained function.\n *\n * Will only create a new function if needed,\n * otherwise will pass back existing functions or null.\n */\nexport default function createChainedFunction(...funcs) {\n return funcs.reduce((acc, func) => {\n if (func == null) {\n return acc;\n }\n return function chainedFunction(...args) {\n acc.apply(this, args);\n func.apply(this, args);\n };\n }, () => {});\n}","// Corresponds to 10 frames at 60 Hz.\n// A few bytes payload overhead when lodash/debounce is ~3 kB and debounce ~300 B.\nexport default function debounce(func, wait = 166) {\n let timeout;\n function debounced(...args) {\n const later = () => {\n // @ts-ignore\n func.apply(this, args);\n };\n clearTimeout(timeout);\n timeout = setTimeout(later, wait);\n }\n debounced.clear = () => {\n clearTimeout(timeout);\n };\n return debounced;\n}","export default function deprecatedPropType(validator, reason) {\n if (process.env.NODE_ENV === 'production') {\n return () => null;\n }\n return (props, propName, componentName, location, propFullName) => {\n const componentNameSafe = componentName || '<>';\n const propFullNameSafe = propFullName || propName;\n if (typeof props[propName] !== 'undefined') {\n return new Error(`The ${location} \\`${propFullNameSafe}\\` of ` + `\\`${componentNameSafe}\\` is deprecated. ${reason}`);\n }\n return null;\n };\n}","import * as React from 'react';\nexport default function isMuiElement(element, muiNames) {\n var _muiName, _element$type;\n return /*#__PURE__*/React.isValidElement(element) && muiNames.indexOf( // For server components `muiName` is avaialble in element.type._payload.value.muiName\n // relevant info - https://github.com/facebook/react/blob/2807d781a08db8e9873687fccc25c0f12b4fb3d4/packages/react/src/ReactLazy.js#L45\n // eslint-disable-next-line no-underscore-dangle\n (_muiName = element.type.muiName) != null ? _muiName : (_element$type = element.type) == null || (_element$type = _element$type._payload) == null || (_element$type = _element$type.value) == null ? void 0 : _element$type.muiName) !== -1;\n}","export default function ownerDocument(node) {\n return node && node.ownerDocument || document;\n}","import ownerDocument from '../ownerDocument';\nexport default function ownerWindow(node) {\n const doc = ownerDocument(node);\n return doc.defaultView || window;\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nexport default function requirePropFactory(componentNameInError, Component) {\n if (process.env.NODE_ENV === 'production') {\n return () => null;\n }\n\n // eslint-disable-next-line react/forbid-foreign-prop-types\n const prevPropTypes = Component ? _extends({}, Component.propTypes) : null;\n const requireProp = requiredProp => (props, propName, componentName, location, propFullName, ...args) => {\n const propFullNameSafe = propFullName || propName;\n const defaultTypeChecker = prevPropTypes == null ? void 0 : prevPropTypes[propFullNameSafe];\n if (defaultTypeChecker) {\n const typeCheckerResult = defaultTypeChecker(props, propName, componentName, location, propFullName, ...args);\n if (typeCheckerResult) {\n return typeCheckerResult;\n }\n }\n if (typeof props[propName] !== 'undefined' && !props[requiredProp]) {\n return new Error(`The prop \\`${propFullNameSafe}\\` of ` + `\\`${componentNameInError}\\` can only be used together with the \\`${requiredProp}\\` prop.`);\n }\n return null;\n };\n return requireProp;\n}","/**\n * TODO v5: consider making it private\n *\n * passes {value} to {ref}\n *\n * WARNING: Be sure to only call this inside a callback that is passed as a ref.\n * Otherwise, make sure to cleanup the previous {ref} if it changes. See\n * https://github.com/mui/material-ui/issues/13539\n *\n * Useful if you want to expose the ref of an inner component to the public API\n * while still using it inside the component.\n * @param ref A ref callback or ref object. If anything falsy, this is a no-op.\n */\nexport default function setRef(ref, value) {\n if (typeof ref === 'function') {\n ref(value);\n } else if (ref) {\n ref.current = value;\n }\n}","'use client';\n\nimport * as React from 'react';\n\n/**\n * A version of `React.useLayoutEffect` that does not show a warning when server-side rendering.\n * This is useful for effects that are only needed for client-side rendering but not for SSR.\n *\n * Before you use this hook, make sure to read https://gist.github.com/gaearon/e7d97cdf38a2907924ea12e4ebdf3c85\n * and confirm it doesn't apply to your use-case.\n */\nconst useEnhancedEffect = typeof window !== 'undefined' ? React.useLayoutEffect : React.useEffect;\nexport default useEnhancedEffect;","'use client';\n\nimport * as React from 'react';\nlet globalId = 0;\nfunction useGlobalId(idOverride) {\n const [defaultId, setDefaultId] = React.useState(idOverride);\n const id = idOverride || defaultId;\n React.useEffect(() => {\n if (defaultId == null) {\n // Fallback to this default id when possible.\n // Use the incrementing value for client-side rendering only.\n // We can't use it server-side.\n // If you want to use random values please consider the Birthday Problem: https://en.wikipedia.org/wiki/Birthday_problem\n globalId += 1;\n setDefaultId(`mui-${globalId}`);\n }\n }, [defaultId]);\n return id;\n}\n\n// downstream bundlers may remove unnecessary concatenation, but won't remove toString call -- Workaround for https://github.com/webpack/webpack/issues/14814\nconst maybeReactUseId = React['useId'.toString()];\n/**\n *\n * @example
    \n * @param idOverride\n * @returns {string}\n */\nexport default function useId(idOverride) {\n if (maybeReactUseId !== undefined) {\n const reactId = maybeReactUseId();\n return idOverride != null ? idOverride : reactId;\n }\n // eslint-disable-next-line react-hooks/rules-of-hooks -- `React.useId` is invariant at runtime.\n return useGlobalId(idOverride);\n}","export default function unsupportedProp(props, propName, componentName, location, propFullName) {\n if (process.env.NODE_ENV === 'production') {\n return null;\n }\n const propFullNameSafe = propFullName || propName;\n if (typeof props[propName] !== 'undefined') {\n return new Error(`The prop \\`${propFullNameSafe}\\` is not supported. Please remove it.`);\n }\n return null;\n}","'use client';\n\n/* eslint-disable react-hooks/rules-of-hooks, react-hooks/exhaustive-deps */\nimport * as React from 'react';\nexport default function useControlled({\n controlled,\n default: defaultProp,\n name,\n state = 'value'\n}) {\n // isControlled is ignored in the hook dependency lists as it should never change.\n const {\n current: isControlled\n } = React.useRef(controlled !== undefined);\n const [valueState, setValue] = React.useState(defaultProp);\n const value = isControlled ? controlled : valueState;\n if (process.env.NODE_ENV !== 'production') {\n React.useEffect(() => {\n if (isControlled !== (controlled !== undefined)) {\n console.error([`MUI: A component is changing the ${isControlled ? '' : 'un'}controlled ${state} state of ${name} to be ${isControlled ? 'un' : ''}controlled.`, 'Elements should not switch from uncontrolled to controlled (or vice versa).', `Decide between using a controlled or uncontrolled ${name} ` + 'element for the lifetime of the component.', \"The nature of the state is determined during the first render. It's considered controlled if the value is not `undefined`.\", 'More info: https://fb.me/react-controlled-components'].join('\\n'));\n }\n }, [state, name, controlled]);\n const {\n current: defaultValue\n } = React.useRef(defaultProp);\n React.useEffect(() => {\n if (!isControlled && defaultValue !== defaultProp) {\n console.error([`MUI: A component is changing the default ${state} state of an uncontrolled ${name} after being initialized. ` + `To suppress this warning opt to use a controlled ${name}.`].join('\\n'));\n }\n }, [JSON.stringify(defaultProp)]);\n }\n const setValueIfUncontrolled = React.useCallback(newValue => {\n if (!isControlled) {\n setValue(newValue);\n }\n }, []);\n return [value, setValueIfUncontrolled];\n}","'use client';\n\nimport * as React from 'react';\nimport useEnhancedEffect from '../useEnhancedEffect';\n\n/**\n * Inspired by https://github.com/facebook/react/issues/14099#issuecomment-440013892\n * See RFC in https://github.com/reactjs/rfcs/pull/220\n */\n\nfunction useEventCallback(fn) {\n const ref = React.useRef(fn);\n useEnhancedEffect(() => {\n ref.current = fn;\n });\n return React.useRef((...args) =>\n // @ts-expect-error hide `this`\n (0, ref.current)(...args)).current;\n}\nexport default useEventCallback;","'use client';\n\nimport * as React from 'react';\nimport setRef from '../setRef';\nexport default function useForkRef(...refs) {\n /**\n * This will create a new function if the refs passed to this hook change and are all defined.\n * This means react will call the old forkRef with `null` and the new forkRef\n * with the ref. Cleanup naturally emerges from this behavior.\n */\n return React.useMemo(() => {\n if (refs.every(ref => ref == null)) {\n return null;\n }\n return instance => {\n refs.forEach(ref => {\n setRef(ref, instance);\n });\n };\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, refs);\n}","'use client';\n\nimport * as React from 'react';\nconst UNINITIALIZED = {};\n\n/**\n * A React.useRef() that is initialized lazily with a function. Note that it accepts an optional\n * initialization argument, so the initialization function doesn't need to be an inline closure.\n *\n * @usage\n * const ref = useLazyRef(sortColumns, columns)\n */\nexport default function useLazyRef(init, initArg) {\n const ref = React.useRef(UNINITIALIZED);\n if (ref.current === UNINITIALIZED) {\n ref.current = init(initArg);\n }\n return ref;\n}","'use client';\n\nimport * as React from 'react';\nconst EMPTY = [];\n\n/**\n * A React.useEffect equivalent that runs once, when the component is mounted.\n */\nexport default function useOnMount(fn) {\n /* eslint-disable react-hooks/exhaustive-deps */\n React.useEffect(fn, EMPTY);\n /* eslint-enable react-hooks/exhaustive-deps */\n}","'use client';\n\nimport useLazyRef from '../useLazyRef/useLazyRef';\nimport useOnMount from '../useOnMount/useOnMount';\nexport class Timeout {\n constructor() {\n this.currentId = null;\n this.clear = () => {\n if (this.currentId !== null) {\n clearTimeout(this.currentId);\n this.currentId = null;\n }\n };\n this.disposeEffect = () => {\n return this.clear;\n };\n }\n static create() {\n return new Timeout();\n }\n /**\n * Executes `fn` after `delay`, clearing any previously scheduled call.\n */\n start(delay, fn) {\n this.clear();\n this.currentId = setTimeout(() => {\n this.currentId = null;\n fn();\n }, delay);\n }\n}\nexport default function useTimeout() {\n const timeout = useLazyRef(Timeout.create).current;\n useOnMount(timeout.disposeEffect);\n return timeout;\n}","'use client';\n\n// based on https://github.com/WICG/focus-visible/blob/v4.1.5/src/focus-visible.js\nimport * as React from 'react';\nimport { Timeout } from '../useTimeout/useTimeout';\nlet hadKeyboardEvent = true;\nlet hadFocusVisibleRecently = false;\nconst hadFocusVisibleRecentlyTimeout = new Timeout();\nconst inputTypesWhitelist = {\n text: true,\n search: true,\n url: true,\n tel: true,\n email: true,\n password: true,\n number: true,\n date: true,\n month: true,\n week: true,\n time: true,\n datetime: true,\n 'datetime-local': true\n};\n\n/**\n * Computes whether the given element should automatically trigger the\n * `focus-visible` class being added, i.e. whether it should always match\n * `:focus-visible` when focused.\n * @param {Element} node\n * @returns {boolean}\n */\nfunction focusTriggersKeyboardModality(node) {\n const {\n type,\n tagName\n } = node;\n if (tagName === 'INPUT' && inputTypesWhitelist[type] && !node.readOnly) {\n return true;\n }\n if (tagName === 'TEXTAREA' && !node.readOnly) {\n return true;\n }\n if (node.isContentEditable) {\n return true;\n }\n return false;\n}\n\n/**\n * Keep track of our keyboard modality state with `hadKeyboardEvent`.\n * If the most recent user interaction was via the keyboard;\n * and the key press did not include a meta, alt/option, or control key;\n * then the modality is keyboard. Otherwise, the modality is not keyboard.\n * @param {KeyboardEvent} event\n */\nfunction handleKeyDown(event) {\n if (event.metaKey || event.altKey || event.ctrlKey) {\n return;\n }\n hadKeyboardEvent = true;\n}\n\n/**\n * If at any point a user clicks with a pointing device, ensure that we change\n * the modality away from keyboard.\n * This avoids the situation where a user presses a key on an already focused\n * element, and then clicks on a different element, focusing it with a\n * pointing device, while we still think we're in keyboard modality.\n */\nfunction handlePointerDown() {\n hadKeyboardEvent = false;\n}\nfunction handleVisibilityChange() {\n if (this.visibilityState === 'hidden') {\n // If the tab becomes active again, the browser will handle calling focus\n // on the element (Safari actually calls it twice).\n // If this tab change caused a blur on an element with focus-visible,\n // re-apply the class when the user switches back to the tab.\n if (hadFocusVisibleRecently) {\n hadKeyboardEvent = true;\n }\n }\n}\nfunction prepare(doc) {\n doc.addEventListener('keydown', handleKeyDown, true);\n doc.addEventListener('mousedown', handlePointerDown, true);\n doc.addEventListener('pointerdown', handlePointerDown, true);\n doc.addEventListener('touchstart', handlePointerDown, true);\n doc.addEventListener('visibilitychange', handleVisibilityChange, true);\n}\nexport function teardown(doc) {\n doc.removeEventListener('keydown', handleKeyDown, true);\n doc.removeEventListener('mousedown', handlePointerDown, true);\n doc.removeEventListener('pointerdown', handlePointerDown, true);\n doc.removeEventListener('touchstart', handlePointerDown, true);\n doc.removeEventListener('visibilitychange', handleVisibilityChange, true);\n}\nfunction isFocusVisible(event) {\n const {\n target\n } = event;\n try {\n return target.matches(':focus-visible');\n } catch (error) {\n // Browsers not implementing :focus-visible will throw a SyntaxError.\n // We use our own heuristic for those browsers.\n // Rethrow might be better if it's not the expected error but do we really\n // want to crash if focus-visible malfunctioned?\n }\n\n // No need for validFocusTarget check. The user does that by attaching it to\n // focusable events only.\n return hadKeyboardEvent || focusTriggersKeyboardModality(target);\n}\nexport default function useIsFocusVisible() {\n const ref = React.useCallback(node => {\n if (node != null) {\n prepare(node.ownerDocument);\n }\n }, []);\n const isFocusVisibleRef = React.useRef(false);\n\n /**\n * Should be called if a blur event is fired\n */\n function handleBlurVisible() {\n // checking against potential state variable does not suffice if we focus and blur synchronously.\n // React wouldn't have time to trigger a re-render so `focusVisible` would be stale.\n // Ideally we would adjust `isFocusVisible(event)` to look at `relatedTarget` for blur events.\n // This doesn't work in IE11 due to https://github.com/facebook/react/issues/3751\n // TODO: check again if React releases their internal changes to focus event handling (https://github.com/facebook/react/pull/19186).\n if (isFocusVisibleRef.current) {\n // To detect a tab/window switch, we look for a blur event followed\n // rapidly by a visibility change.\n // If we don't see a visibility change within 100ms, it's probably a\n // regular focus change.\n hadFocusVisibleRecently = true;\n hadFocusVisibleRecentlyTimeout.start(100, () => {\n hadFocusVisibleRecently = false;\n });\n isFocusVisibleRef.current = false;\n return true;\n }\n return false;\n }\n\n /**\n * Should be called if a blur event is fired\n */\n function handleFocusVisible(event) {\n if (isFocusVisible(event)) {\n isFocusVisibleRef.current = true;\n return true;\n }\n return false;\n }\n return {\n isFocusVisibleRef,\n onFocus: handleFocusVisible,\n onBlur: handleBlurVisible,\n ref\n };\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\n/**\n * Add keys, values of `defaultProps` that does not exist in `props`\n * @param {object} defaultProps\n * @param {object} props\n * @returns {object} resolved props\n */\nexport default function resolveProps(defaultProps, props) {\n const output = _extends({}, props);\n Object.keys(defaultProps).forEach(propName => {\n if (propName.toString().match(/^(components|slots)$/)) {\n output[propName] = _extends({}, defaultProps[propName], output[propName]);\n } else if (propName.toString().match(/^(componentsProps|slotProps)$/)) {\n const defaultSlotProps = defaultProps[propName] || {};\n const slotProps = props[propName];\n output[propName] = {};\n if (!slotProps || !Object.keys(slotProps)) {\n // Reduce the iteration if the slot props is empty\n output[propName] = defaultSlotProps;\n } else if (!defaultSlotProps || !Object.keys(defaultSlotProps)) {\n // Reduce the iteration if the default slot props is empty\n output[propName] = slotProps;\n } else {\n output[propName] = _extends({}, slotProps);\n Object.keys(defaultSlotProps).forEach(slotPropName => {\n output[propName][slotPropName] = resolveProps(defaultSlotProps[slotPropName], slotProps[slotPropName]);\n });\n }\n } else if (output[propName] === undefined) {\n output[propName] = defaultProps[propName];\n }\n });\n return output;\n}","export default function composeClasses(slots, getUtilityClass, classes = undefined) {\n const output = {};\n Object.keys(slots).forEach(\n // `Object.keys(slots)` can't be wider than `T` because we infer `T` from `slots`.\n // @ts-expect-error https://github.com/microsoft/TypeScript/pull/12253#issuecomment-263132208\n slot => {\n output[slot] = slots[slot].reduce((acc, key) => {\n if (key) {\n const utilityClass = getUtilityClass(key);\n if (utilityClass !== '') {\n acc.push(utilityClass);\n }\n if (classes && classes[key]) {\n acc.push(classes[key]);\n }\n }\n return acc;\n }, []).join(' ');\n });\n return output;\n}","const defaultGenerator = componentName => componentName;\nconst createClassNameGenerator = () => {\n let generate = defaultGenerator;\n return {\n configure(generator) {\n generate = generator;\n },\n generate(componentName) {\n return generate(componentName);\n },\n reset() {\n generate = defaultGenerator;\n }\n };\n};\nconst ClassNameGenerator = createClassNameGenerator();\nexport default ClassNameGenerator;","import ClassNameGenerator from '../ClassNameGenerator';\nexport const globalStateClasses = {\n active: 'active',\n checked: 'checked',\n completed: 'completed',\n disabled: 'disabled',\n error: 'error',\n expanded: 'expanded',\n focused: 'focused',\n focusVisible: 'focusVisible',\n open: 'open',\n readOnly: 'readOnly',\n required: 'required',\n selected: 'selected'\n};\nexport default function generateUtilityClass(componentName, slot, globalStatePrefix = 'Mui') {\n const globalStateClass = globalStateClasses[slot];\n return globalStateClass ? `${globalStatePrefix}-${globalStateClass}` : `${ClassNameGenerator.generate(componentName)}-${slot}`;\n}\nexport function isGlobalState(slot) {\n return globalStateClasses[slot] !== undefined;\n}","import generateUtilityClass from '../generateUtilityClass';\nexport default function generateUtilityClasses(componentName, slots, globalStatePrefix = 'Mui') {\n const result = {};\n slots.forEach(slot => {\n result[slot] = generateUtilityClass(componentName, slot, globalStatePrefix);\n });\n return result;\n}","function clamp(val, min = Number.MIN_SAFE_INTEGER, max = Number.MAX_SAFE_INTEGER) {\n return Math.max(min, Math.min(val, max));\n}\nexport default clamp;","export default function _objectWithoutPropertiesLoose(source, excluded) {\n if (source == null) return {};\n var target = {};\n var sourceKeys = Object.keys(source);\n var key, i;\n for (i = 0; i < sourceKeys.length; i++) {\n key = sourceKeys[i];\n if (excluded.indexOf(key) >= 0) continue;\n target[key] = source[key];\n }\n return target;\n}","import _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nconst _excluded = [\"values\", \"unit\", \"step\"];\n// Sorted ASC by size. That's important.\n// It can't be configured as it's used statically for propTypes.\nexport const breakpointKeys = ['xs', 'sm', 'md', 'lg', 'xl'];\nconst sortBreakpointsValues = values => {\n const breakpointsAsArray = Object.keys(values).map(key => ({\n key,\n val: values[key]\n })) || [];\n // Sort in ascending order\n breakpointsAsArray.sort((breakpoint1, breakpoint2) => breakpoint1.val - breakpoint2.val);\n return breakpointsAsArray.reduce((acc, obj) => {\n return _extends({}, acc, {\n [obj.key]: obj.val\n });\n }, {});\n};\n\n// Keep in mind that @media is inclusive by the CSS specification.\nexport default function createBreakpoints(breakpoints) {\n const {\n // The breakpoint **start** at this value.\n // For instance with the first breakpoint xs: [xs, sm).\n values = {\n xs: 0,\n // phone\n sm: 600,\n // tablet\n md: 900,\n // small laptop\n lg: 1200,\n // desktop\n xl: 1536 // large screen\n },\n unit = 'px',\n step = 5\n } = breakpoints,\n other = _objectWithoutPropertiesLoose(breakpoints, _excluded);\n const sortedValues = sortBreakpointsValues(values);\n const keys = Object.keys(sortedValues);\n function up(key) {\n const value = typeof values[key] === 'number' ? values[key] : key;\n return `@media (min-width:${value}${unit})`;\n }\n function down(key) {\n const value = typeof values[key] === 'number' ? values[key] : key;\n return `@media (max-width:${value - step / 100}${unit})`;\n }\n function between(start, end) {\n const endIndex = keys.indexOf(end);\n return `@media (min-width:${typeof values[start] === 'number' ? values[start] : start}${unit}) and ` + `(max-width:${(endIndex !== -1 && typeof values[keys[endIndex]] === 'number' ? values[keys[endIndex]] : end) - step / 100}${unit})`;\n }\n function only(key) {\n if (keys.indexOf(key) + 1 < keys.length) {\n return between(key, keys[keys.indexOf(key) + 1]);\n }\n return up(key);\n }\n function not(key) {\n // handle first and last key separately, for better readability\n const keyIndex = keys.indexOf(key);\n if (keyIndex === 0) {\n return up(keys[1]);\n }\n if (keyIndex === keys.length - 1) {\n return down(keys[keyIndex]);\n }\n return between(key, keys[keys.indexOf(key) + 1]).replace('@media', '@media not all and');\n }\n return _extends({\n keys,\n values: sortedValues,\n up,\n down,\n between,\n only,\n not,\n unit\n }, other);\n}","const shape = {\n borderRadius: 4\n};\nexport default shape;","import PropTypes from 'prop-types';\nconst responsivePropType = process.env.NODE_ENV !== 'production' ? PropTypes.oneOfType([PropTypes.number, PropTypes.string, PropTypes.object, PropTypes.array]) : {};\nexport default responsivePropType;","import deepmerge from '@mui/utils/deepmerge';\nfunction merge(acc, item) {\n if (!item) {\n return acc;\n }\n return deepmerge(acc, item, {\n clone: false // No need to clone deep, it's way faster.\n });\n}\nexport default merge;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport PropTypes from 'prop-types';\nimport deepmerge from '@mui/utils/deepmerge';\nimport merge from './merge';\n\n// The breakpoint **start** at this value.\n// For instance with the first breakpoint xs: [xs, sm[.\nexport const values = {\n xs: 0,\n // phone\n sm: 600,\n // tablet\n md: 900,\n // small laptop\n lg: 1200,\n // desktop\n xl: 1536 // large screen\n};\nconst defaultBreakpoints = {\n // Sorted ASC by size. That's important.\n // It can't be configured as it's used statically for propTypes.\n keys: ['xs', 'sm', 'md', 'lg', 'xl'],\n up: key => `@media (min-width:${values[key]}px)`\n};\nexport function handleBreakpoints(props, propValue, styleFromPropValue) {\n const theme = props.theme || {};\n if (Array.isArray(propValue)) {\n const themeBreakpoints = theme.breakpoints || defaultBreakpoints;\n return propValue.reduce((acc, item, index) => {\n acc[themeBreakpoints.up(themeBreakpoints.keys[index])] = styleFromPropValue(propValue[index]);\n return acc;\n }, {});\n }\n if (typeof propValue === 'object') {\n const themeBreakpoints = theme.breakpoints || defaultBreakpoints;\n return Object.keys(propValue).reduce((acc, breakpoint) => {\n // key is breakpoint\n if (Object.keys(themeBreakpoints.values || values).indexOf(breakpoint) !== -1) {\n const mediaKey = themeBreakpoints.up(breakpoint);\n acc[mediaKey] = styleFromPropValue(propValue[breakpoint], breakpoint);\n } else {\n const cssKey = breakpoint;\n acc[cssKey] = propValue[cssKey];\n }\n return acc;\n }, {});\n }\n const output = styleFromPropValue(propValue);\n return output;\n}\nfunction breakpoints(styleFunction) {\n // false positive\n // eslint-disable-next-line react/function-component-definition\n const newStyleFunction = props => {\n const theme = props.theme || {};\n const base = styleFunction(props);\n const themeBreakpoints = theme.breakpoints || defaultBreakpoints;\n const extended = themeBreakpoints.keys.reduce((acc, key) => {\n if (props[key]) {\n acc = acc || {};\n acc[themeBreakpoints.up(key)] = styleFunction(_extends({\n theme\n }, props[key]));\n }\n return acc;\n }, null);\n return merge(base, extended);\n };\n newStyleFunction.propTypes = process.env.NODE_ENV !== 'production' ? _extends({}, styleFunction.propTypes, {\n xs: PropTypes.object,\n sm: PropTypes.object,\n md: PropTypes.object,\n lg: PropTypes.object,\n xl: PropTypes.object\n }) : {};\n newStyleFunction.filterProps = ['xs', 'sm', 'md', 'lg', 'xl', ...styleFunction.filterProps];\n return newStyleFunction;\n}\nexport function createEmptyBreakpointObject(breakpointsInput = {}) {\n var _breakpointsInput$key;\n const breakpointsInOrder = (_breakpointsInput$key = breakpointsInput.keys) == null ? void 0 : _breakpointsInput$key.reduce((acc, key) => {\n const breakpointStyleKey = breakpointsInput.up(key);\n acc[breakpointStyleKey] = {};\n return acc;\n }, {});\n return breakpointsInOrder || {};\n}\nexport function removeUnusedBreakpoints(breakpointKeys, style) {\n return breakpointKeys.reduce((acc, key) => {\n const breakpointOutput = acc[key];\n const isBreakpointUnused = !breakpointOutput || Object.keys(breakpointOutput).length === 0;\n if (isBreakpointUnused) {\n delete acc[key];\n }\n return acc;\n }, style);\n}\nexport function mergeBreakpointsInOrder(breakpointsInput, ...styles) {\n const emptyBreakpoints = createEmptyBreakpointObject(breakpointsInput);\n const mergedOutput = [emptyBreakpoints, ...styles].reduce((prev, next) => deepmerge(prev, next), {});\n return removeUnusedBreakpoints(Object.keys(emptyBreakpoints), mergedOutput);\n}\n\n// compute base for responsive values; e.g.,\n// [1,2,3] => {xs: true, sm: true, md: true}\n// {xs: 1, sm: 2, md: 3} => {xs: true, sm: true, md: true}\nexport function computeBreakpointsBase(breakpointValues, themeBreakpoints) {\n // fixed value\n if (typeof breakpointValues !== 'object') {\n return {};\n }\n const base = {};\n const breakpointsKeys = Object.keys(themeBreakpoints);\n if (Array.isArray(breakpointValues)) {\n breakpointsKeys.forEach((breakpoint, i) => {\n if (i < breakpointValues.length) {\n base[breakpoint] = true;\n }\n });\n } else {\n breakpointsKeys.forEach(breakpoint => {\n if (breakpointValues[breakpoint] != null) {\n base[breakpoint] = true;\n }\n });\n }\n return base;\n}\nexport function resolveBreakpointValues({\n values: breakpointValues,\n breakpoints: themeBreakpoints,\n base: customBase\n}) {\n const base = customBase || computeBreakpointsBase(breakpointValues, themeBreakpoints);\n const keys = Object.keys(base);\n if (keys.length === 0) {\n return breakpointValues;\n }\n let previous;\n return keys.reduce((acc, breakpoint, i) => {\n if (Array.isArray(breakpointValues)) {\n acc[breakpoint] = breakpointValues[i] != null ? breakpointValues[i] : breakpointValues[previous];\n previous = i;\n } else if (typeof breakpointValues === 'object') {\n acc[breakpoint] = breakpointValues[breakpoint] != null ? breakpointValues[breakpoint] : breakpointValues[previous];\n previous = breakpoint;\n } else {\n acc[breakpoint] = breakpointValues;\n }\n return acc;\n }, {});\n}\nexport default breakpoints;","import capitalize from '@mui/utils/capitalize';\nimport responsivePropType from './responsivePropType';\nimport { handleBreakpoints } from './breakpoints';\nexport function getPath(obj, path, checkVars = true) {\n if (!path || typeof path !== 'string') {\n return null;\n }\n\n // Check if CSS variables are used\n if (obj && obj.vars && checkVars) {\n const val = `vars.${path}`.split('.').reduce((acc, item) => acc && acc[item] ? acc[item] : null, obj);\n if (val != null) {\n return val;\n }\n }\n return path.split('.').reduce((acc, item) => {\n if (acc && acc[item] != null) {\n return acc[item];\n }\n return null;\n }, obj);\n}\nexport function getStyleValue(themeMapping, transform, propValueFinal, userValue = propValueFinal) {\n let value;\n if (typeof themeMapping === 'function') {\n value = themeMapping(propValueFinal);\n } else if (Array.isArray(themeMapping)) {\n value = themeMapping[propValueFinal] || userValue;\n } else {\n value = getPath(themeMapping, propValueFinal) || userValue;\n }\n if (transform) {\n value = transform(value, userValue, themeMapping);\n }\n return value;\n}\nfunction style(options) {\n const {\n prop,\n cssProperty = options.prop,\n themeKey,\n transform\n } = options;\n\n // false positive\n // eslint-disable-next-line react/function-component-definition\n const fn = props => {\n if (props[prop] == null) {\n return null;\n }\n const propValue = props[prop];\n const theme = props.theme;\n const themeMapping = getPath(theme, themeKey) || {};\n const styleFromPropValue = propValueFinal => {\n let value = getStyleValue(themeMapping, transform, propValueFinal);\n if (propValueFinal === value && typeof propValueFinal === 'string') {\n // Haven't found value\n value = getStyleValue(themeMapping, transform, `${prop}${propValueFinal === 'default' ? '' : capitalize(propValueFinal)}`, propValueFinal);\n }\n if (cssProperty === false) {\n return value;\n }\n return {\n [cssProperty]: value\n };\n };\n return handleBreakpoints(props, propValue, styleFromPropValue);\n };\n fn.propTypes = process.env.NODE_ENV !== 'production' ? {\n [prop]: responsivePropType\n } : {};\n fn.filterProps = [prop];\n return fn;\n}\nexport default style;","export default function memoize(fn) {\n const cache = {};\n return arg => {\n if (cache[arg] === undefined) {\n cache[arg] = fn(arg);\n }\n return cache[arg];\n };\n}","import responsivePropType from './responsivePropType';\nimport { handleBreakpoints } from './breakpoints';\nimport { getPath } from './style';\nimport merge from './merge';\nimport memoize from './memoize';\nconst properties = {\n m: 'margin',\n p: 'padding'\n};\nconst directions = {\n t: 'Top',\n r: 'Right',\n b: 'Bottom',\n l: 'Left',\n x: ['Left', 'Right'],\n y: ['Top', 'Bottom']\n};\nconst aliases = {\n marginX: 'mx',\n marginY: 'my',\n paddingX: 'px',\n paddingY: 'py'\n};\n\n// memoize() impact:\n// From 300,000 ops/sec\n// To 350,000 ops/sec\nconst getCssProperties = memoize(prop => {\n // It's not a shorthand notation.\n if (prop.length > 2) {\n if (aliases[prop]) {\n prop = aliases[prop];\n } else {\n return [prop];\n }\n }\n const [a, b] = prop.split('');\n const property = properties[a];\n const direction = directions[b] || '';\n return Array.isArray(direction) ? direction.map(dir => property + dir) : [property + direction];\n});\nexport const marginKeys = ['m', 'mt', 'mr', 'mb', 'ml', 'mx', 'my', 'margin', 'marginTop', 'marginRight', 'marginBottom', 'marginLeft', 'marginX', 'marginY', 'marginInline', 'marginInlineStart', 'marginInlineEnd', 'marginBlock', 'marginBlockStart', 'marginBlockEnd'];\nexport const paddingKeys = ['p', 'pt', 'pr', 'pb', 'pl', 'px', 'py', 'padding', 'paddingTop', 'paddingRight', 'paddingBottom', 'paddingLeft', 'paddingX', 'paddingY', 'paddingInline', 'paddingInlineStart', 'paddingInlineEnd', 'paddingBlock', 'paddingBlockStart', 'paddingBlockEnd'];\nconst spacingKeys = [...marginKeys, ...paddingKeys];\nexport function createUnaryUnit(theme, themeKey, defaultValue, propName) {\n var _getPath;\n const themeSpacing = (_getPath = getPath(theme, themeKey, false)) != null ? _getPath : defaultValue;\n if (typeof themeSpacing === 'number') {\n return abs => {\n if (typeof abs === 'string') {\n return abs;\n }\n if (process.env.NODE_ENV !== 'production') {\n if (typeof abs !== 'number') {\n console.error(`MUI: Expected ${propName} argument to be a number or a string, got ${abs}.`);\n }\n }\n return themeSpacing * abs;\n };\n }\n if (Array.isArray(themeSpacing)) {\n return abs => {\n if (typeof abs === 'string') {\n return abs;\n }\n if (process.env.NODE_ENV !== 'production') {\n if (!Number.isInteger(abs)) {\n console.error([`MUI: The \\`theme.${themeKey}\\` array type cannot be combined with non integer values.` + `You should either use an integer value that can be used as index, or define the \\`theme.${themeKey}\\` as a number.`].join('\\n'));\n } else if (abs > themeSpacing.length - 1) {\n console.error([`MUI: The value provided (${abs}) overflows.`, `The supported values are: ${JSON.stringify(themeSpacing)}.`, `${abs} > ${themeSpacing.length - 1}, you need to add the missing values.`].join('\\n'));\n }\n }\n return themeSpacing[abs];\n };\n }\n if (typeof themeSpacing === 'function') {\n return themeSpacing;\n }\n if (process.env.NODE_ENV !== 'production') {\n console.error([`MUI: The \\`theme.${themeKey}\\` value (${themeSpacing}) is invalid.`, 'It should be a number, an array or a function.'].join('\\n'));\n }\n return () => undefined;\n}\nexport function createUnarySpacing(theme) {\n return createUnaryUnit(theme, 'spacing', 8, 'spacing');\n}\nexport function getValue(transformer, propValue) {\n if (typeof propValue === 'string' || propValue == null) {\n return propValue;\n }\n const abs = Math.abs(propValue);\n const transformed = transformer(abs);\n if (propValue >= 0) {\n return transformed;\n }\n if (typeof transformed === 'number') {\n return -transformed;\n }\n return `-${transformed}`;\n}\nexport function getStyleFromPropValue(cssProperties, transformer) {\n return propValue => cssProperties.reduce((acc, cssProperty) => {\n acc[cssProperty] = getValue(transformer, propValue);\n return acc;\n }, {});\n}\nfunction resolveCssProperty(props, keys, prop, transformer) {\n // Using a hash computation over an array iteration could be faster, but with only 28 items,\n // it's doesn't worth the bundle size.\n if (keys.indexOf(prop) === -1) {\n return null;\n }\n const cssProperties = getCssProperties(prop);\n const styleFromPropValue = getStyleFromPropValue(cssProperties, transformer);\n const propValue = props[prop];\n return handleBreakpoints(props, propValue, styleFromPropValue);\n}\nfunction style(props, keys) {\n const transformer = createUnarySpacing(props.theme);\n return Object.keys(props).map(prop => resolveCssProperty(props, keys, prop, transformer)).reduce(merge, {});\n}\nexport function margin(props) {\n return style(props, marginKeys);\n}\nmargin.propTypes = process.env.NODE_ENV !== 'production' ? marginKeys.reduce((obj, key) => {\n obj[key] = responsivePropType;\n return obj;\n}, {}) : {};\nmargin.filterProps = marginKeys;\nexport function padding(props) {\n return style(props, paddingKeys);\n}\npadding.propTypes = process.env.NODE_ENV !== 'production' ? paddingKeys.reduce((obj, key) => {\n obj[key] = responsivePropType;\n return obj;\n}, {}) : {};\npadding.filterProps = paddingKeys;\nfunction spacing(props) {\n return style(props, spacingKeys);\n}\nspacing.propTypes = process.env.NODE_ENV !== 'production' ? spacingKeys.reduce((obj, key) => {\n obj[key] = responsivePropType;\n return obj;\n}, {}) : {};\nspacing.filterProps = spacingKeys;\nexport default spacing;","import { createUnarySpacing } from '../spacing';\n\n// The different signatures imply different meaning for their arguments that can't be expressed structurally.\n// We express the difference with variable names.\n\nexport default function createSpacing(spacingInput = 8) {\n // Already transformed.\n if (spacingInput.mui) {\n return spacingInput;\n }\n\n // Material Design layouts are visually balanced. Most measurements align to an 8dp grid, which aligns both spacing and the overall layout.\n // Smaller components, such as icons, can align to a 4dp grid.\n // https://m2.material.io/design/layout/understanding-layout.html\n const transform = createUnarySpacing({\n spacing: spacingInput\n });\n const spacing = (...argsInput) => {\n if (process.env.NODE_ENV !== 'production') {\n if (!(argsInput.length <= 4)) {\n console.error(`MUI: Too many arguments provided, expected between 0 and 4, got ${argsInput.length}`);\n }\n }\n const args = argsInput.length === 0 ? [1] : argsInput;\n return args.map(argument => {\n const output = transform(argument);\n return typeof output === 'number' ? `${output}px` : output;\n }).join(' ');\n };\n spacing.mui = true;\n return spacing;\n}","import merge from './merge';\nfunction compose(...styles) {\n const handlers = styles.reduce((acc, style) => {\n style.filterProps.forEach(prop => {\n acc[prop] = style;\n });\n return acc;\n }, {});\n\n // false positive\n // eslint-disable-next-line react/function-component-definition\n const fn = props => {\n return Object.keys(props).reduce((acc, prop) => {\n if (handlers[prop]) {\n return merge(acc, handlers[prop](props));\n }\n return acc;\n }, {});\n };\n fn.propTypes = process.env.NODE_ENV !== 'production' ? styles.reduce((acc, style) => Object.assign(acc, style.propTypes), {}) : {};\n fn.filterProps = styles.reduce((acc, style) => acc.concat(style.filterProps), []);\n return fn;\n}\nexport default compose;","import responsivePropType from './responsivePropType';\nimport style from './style';\nimport compose from './compose';\nimport { createUnaryUnit, getValue } from './spacing';\nimport { handleBreakpoints } from './breakpoints';\nexport function borderTransform(value) {\n if (typeof value !== 'number') {\n return value;\n }\n return `${value}px solid`;\n}\nfunction createBorderStyle(prop, transform) {\n return style({\n prop,\n themeKey: 'borders',\n transform\n });\n}\nexport const border = createBorderStyle('border', borderTransform);\nexport const borderTop = createBorderStyle('borderTop', borderTransform);\nexport const borderRight = createBorderStyle('borderRight', borderTransform);\nexport const borderBottom = createBorderStyle('borderBottom', borderTransform);\nexport const borderLeft = createBorderStyle('borderLeft', borderTransform);\nexport const borderColor = createBorderStyle('borderColor');\nexport const borderTopColor = createBorderStyle('borderTopColor');\nexport const borderRightColor = createBorderStyle('borderRightColor');\nexport const borderBottomColor = createBorderStyle('borderBottomColor');\nexport const borderLeftColor = createBorderStyle('borderLeftColor');\nexport const outline = createBorderStyle('outline', borderTransform);\nexport const outlineColor = createBorderStyle('outlineColor');\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const borderRadius = props => {\n if (props.borderRadius !== undefined && props.borderRadius !== null) {\n const transformer = createUnaryUnit(props.theme, 'shape.borderRadius', 4, 'borderRadius');\n const styleFromPropValue = propValue => ({\n borderRadius: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.borderRadius, styleFromPropValue);\n }\n return null;\n};\nborderRadius.propTypes = process.env.NODE_ENV !== 'production' ? {\n borderRadius: responsivePropType\n} : {};\nborderRadius.filterProps = ['borderRadius'];\nconst borders = compose(border, borderTop, borderRight, borderBottom, borderLeft, borderColor, borderTopColor, borderRightColor, borderBottomColor, borderLeftColor, borderRadius, outline, outlineColor);\nexport default borders;","import style from './style';\nimport compose from './compose';\nimport { createUnaryUnit, getValue } from './spacing';\nimport { handleBreakpoints } from './breakpoints';\nimport responsivePropType from './responsivePropType';\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const gap = props => {\n if (props.gap !== undefined && props.gap !== null) {\n const transformer = createUnaryUnit(props.theme, 'spacing', 8, 'gap');\n const styleFromPropValue = propValue => ({\n gap: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.gap, styleFromPropValue);\n }\n return null;\n};\ngap.propTypes = process.env.NODE_ENV !== 'production' ? {\n gap: responsivePropType\n} : {};\ngap.filterProps = ['gap'];\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const columnGap = props => {\n if (props.columnGap !== undefined && props.columnGap !== null) {\n const transformer = createUnaryUnit(props.theme, 'spacing', 8, 'columnGap');\n const styleFromPropValue = propValue => ({\n columnGap: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.columnGap, styleFromPropValue);\n }\n return null;\n};\ncolumnGap.propTypes = process.env.NODE_ENV !== 'production' ? {\n columnGap: responsivePropType\n} : {};\ncolumnGap.filterProps = ['columnGap'];\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const rowGap = props => {\n if (props.rowGap !== undefined && props.rowGap !== null) {\n const transformer = createUnaryUnit(props.theme, 'spacing', 8, 'rowGap');\n const styleFromPropValue = propValue => ({\n rowGap: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.rowGap, styleFromPropValue);\n }\n return null;\n};\nrowGap.propTypes = process.env.NODE_ENV !== 'production' ? {\n rowGap: responsivePropType\n} : {};\nrowGap.filterProps = ['rowGap'];\nexport const gridColumn = style({\n prop: 'gridColumn'\n});\nexport const gridRow = style({\n prop: 'gridRow'\n});\nexport const gridAutoFlow = style({\n prop: 'gridAutoFlow'\n});\nexport const gridAutoColumns = style({\n prop: 'gridAutoColumns'\n});\nexport const gridAutoRows = style({\n prop: 'gridAutoRows'\n});\nexport const gridTemplateColumns = style({\n prop: 'gridTemplateColumns'\n});\nexport const gridTemplateRows = style({\n prop: 'gridTemplateRows'\n});\nexport const gridTemplateAreas = style({\n prop: 'gridTemplateAreas'\n});\nexport const gridArea = style({\n prop: 'gridArea'\n});\nconst grid = compose(gap, columnGap, rowGap, gridColumn, gridRow, gridAutoFlow, gridAutoColumns, gridAutoRows, gridTemplateColumns, gridTemplateRows, gridTemplateAreas, gridArea);\nexport default grid;","import style from './style';\nimport compose from './compose';\nexport function paletteTransform(value, userValue) {\n if (userValue === 'grey') {\n return userValue;\n }\n return value;\n}\nexport const color = style({\n prop: 'color',\n themeKey: 'palette',\n transform: paletteTransform\n});\nexport const bgcolor = style({\n prop: 'bgcolor',\n cssProperty: 'backgroundColor',\n themeKey: 'palette',\n transform: paletteTransform\n});\nexport const backgroundColor = style({\n prop: 'backgroundColor',\n themeKey: 'palette',\n transform: paletteTransform\n});\nconst palette = compose(color, bgcolor, backgroundColor);\nexport default palette;","import style from './style';\nimport compose from './compose';\nimport { handleBreakpoints, values as breakpointsValues } from './breakpoints';\nexport function sizingTransform(value) {\n return value <= 1 && value !== 0 ? `${value * 100}%` : value;\n}\nexport const width = style({\n prop: 'width',\n transform: sizingTransform\n});\nexport const maxWidth = props => {\n if (props.maxWidth !== undefined && props.maxWidth !== null) {\n const styleFromPropValue = propValue => {\n var _props$theme, _props$theme2;\n const breakpoint = ((_props$theme = props.theme) == null || (_props$theme = _props$theme.breakpoints) == null || (_props$theme = _props$theme.values) == null ? void 0 : _props$theme[propValue]) || breakpointsValues[propValue];\n if (!breakpoint) {\n return {\n maxWidth: sizingTransform(propValue)\n };\n }\n if (((_props$theme2 = props.theme) == null || (_props$theme2 = _props$theme2.breakpoints) == null ? void 0 : _props$theme2.unit) !== 'px') {\n return {\n maxWidth: `${breakpoint}${props.theme.breakpoints.unit}`\n };\n }\n return {\n maxWidth: breakpoint\n };\n };\n return handleBreakpoints(props, props.maxWidth, styleFromPropValue);\n }\n return null;\n};\nmaxWidth.filterProps = ['maxWidth'];\nexport const minWidth = style({\n prop: 'minWidth',\n transform: sizingTransform\n});\nexport const height = style({\n prop: 'height',\n transform: sizingTransform\n});\nexport const maxHeight = style({\n prop: 'maxHeight',\n transform: sizingTransform\n});\nexport const minHeight = style({\n prop: 'minHeight',\n transform: sizingTransform\n});\nexport const sizeWidth = style({\n prop: 'size',\n cssProperty: 'width',\n transform: sizingTransform\n});\nexport const sizeHeight = style({\n prop: 'size',\n cssProperty: 'height',\n transform: sizingTransform\n});\nexport const boxSizing = style({\n prop: 'boxSizing'\n});\nconst sizing = compose(width, maxWidth, minWidth, height, maxHeight, minHeight, boxSizing);\nexport default sizing;","import { padding, margin } from '../spacing';\nimport { borderRadius, borderTransform } from '../borders';\nimport { gap, rowGap, columnGap } from '../cssGrid';\nimport { paletteTransform } from '../palette';\nimport { maxWidth, sizingTransform } from '../sizing';\nconst defaultSxConfig = {\n // borders\n border: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderTop: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderRight: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderBottom: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderLeft: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderColor: {\n themeKey: 'palette'\n },\n borderTopColor: {\n themeKey: 'palette'\n },\n borderRightColor: {\n themeKey: 'palette'\n },\n borderBottomColor: {\n themeKey: 'palette'\n },\n borderLeftColor: {\n themeKey: 'palette'\n },\n outline: {\n themeKey: 'borders',\n transform: borderTransform\n },\n outlineColor: {\n themeKey: 'palette'\n },\n borderRadius: {\n themeKey: 'shape.borderRadius',\n style: borderRadius\n },\n // palette\n color: {\n themeKey: 'palette',\n transform: paletteTransform\n },\n bgcolor: {\n themeKey: 'palette',\n cssProperty: 'backgroundColor',\n transform: paletteTransform\n },\n backgroundColor: {\n themeKey: 'palette',\n transform: paletteTransform\n },\n // spacing\n p: {\n style: padding\n },\n pt: {\n style: padding\n },\n pr: {\n style: padding\n },\n pb: {\n style: padding\n },\n pl: {\n style: padding\n },\n px: {\n style: padding\n },\n py: {\n style: padding\n },\n padding: {\n style: padding\n },\n paddingTop: {\n style: padding\n },\n paddingRight: {\n style: padding\n },\n paddingBottom: {\n style: padding\n },\n paddingLeft: {\n style: padding\n },\n paddingX: {\n style: padding\n },\n paddingY: {\n style: padding\n },\n paddingInline: {\n style: padding\n },\n paddingInlineStart: {\n style: padding\n },\n paddingInlineEnd: {\n style: padding\n },\n paddingBlock: {\n style: padding\n },\n paddingBlockStart: {\n style: padding\n },\n paddingBlockEnd: {\n style: padding\n },\n m: {\n style: margin\n },\n mt: {\n style: margin\n },\n mr: {\n style: margin\n },\n mb: {\n style: margin\n },\n ml: {\n style: margin\n },\n mx: {\n style: margin\n },\n my: {\n style: margin\n },\n margin: {\n style: margin\n },\n marginTop: {\n style: margin\n },\n marginRight: {\n style: margin\n },\n marginBottom: {\n style: margin\n },\n marginLeft: {\n style: margin\n },\n marginX: {\n style: margin\n },\n marginY: {\n style: margin\n },\n marginInline: {\n style: margin\n },\n marginInlineStart: {\n style: margin\n },\n marginInlineEnd: {\n style: margin\n },\n marginBlock: {\n style: margin\n },\n marginBlockStart: {\n style: margin\n },\n marginBlockEnd: {\n style: margin\n },\n // display\n displayPrint: {\n cssProperty: false,\n transform: value => ({\n '@media print': {\n display: value\n }\n })\n },\n display: {},\n overflow: {},\n textOverflow: {},\n visibility: {},\n whiteSpace: {},\n // flexbox\n flexBasis: {},\n flexDirection: {},\n flexWrap: {},\n justifyContent: {},\n alignItems: {},\n alignContent: {},\n order: {},\n flex: {},\n flexGrow: {},\n flexShrink: {},\n alignSelf: {},\n justifyItems: {},\n justifySelf: {},\n // grid\n gap: {\n style: gap\n },\n rowGap: {\n style: rowGap\n },\n columnGap: {\n style: columnGap\n },\n gridColumn: {},\n gridRow: {},\n gridAutoFlow: {},\n gridAutoColumns: {},\n gridAutoRows: {},\n gridTemplateColumns: {},\n gridTemplateRows: {},\n gridTemplateAreas: {},\n gridArea: {},\n // positions\n position: {},\n zIndex: {\n themeKey: 'zIndex'\n },\n top: {},\n right: {},\n bottom: {},\n left: {},\n // shadows\n boxShadow: {\n themeKey: 'shadows'\n },\n // sizing\n width: {\n transform: sizingTransform\n },\n maxWidth: {\n style: maxWidth\n },\n minWidth: {\n transform: sizingTransform\n },\n height: {\n transform: sizingTransform\n },\n maxHeight: {\n transform: sizingTransform\n },\n minHeight: {\n transform: sizingTransform\n },\n boxSizing: {},\n // typography\n fontFamily: {\n themeKey: 'typography'\n },\n fontSize: {\n themeKey: 'typography'\n },\n fontStyle: {\n themeKey: 'typography'\n },\n fontWeight: {\n themeKey: 'typography'\n },\n letterSpacing: {},\n textTransform: {},\n lineHeight: {},\n textAlign: {},\n typography: {\n cssProperty: false,\n themeKey: 'typography'\n }\n};\nexport default defaultSxConfig;","import capitalize from '@mui/utils/capitalize';\nimport merge from '../merge';\nimport { getPath, getStyleValue as getValue } from '../style';\nimport { handleBreakpoints, createEmptyBreakpointObject, removeUnusedBreakpoints } from '../breakpoints';\nimport defaultSxConfig from './defaultSxConfig';\nfunction objectsHaveSameKeys(...objects) {\n const allKeys = objects.reduce((keys, object) => keys.concat(Object.keys(object)), []);\n const union = new Set(allKeys);\n return objects.every(object => union.size === Object.keys(object).length);\n}\nfunction callIfFn(maybeFn, arg) {\n return typeof maybeFn === 'function' ? maybeFn(arg) : maybeFn;\n}\n\n// eslint-disable-next-line @typescript-eslint/naming-convention\nexport function unstable_createStyleFunctionSx() {\n function getThemeValue(prop, val, theme, config) {\n const props = {\n [prop]: val,\n theme\n };\n const options = config[prop];\n if (!options) {\n return {\n [prop]: val\n };\n }\n const {\n cssProperty = prop,\n themeKey,\n transform,\n style\n } = options;\n if (val == null) {\n return null;\n }\n\n // TODO v6: remove, see https://github.com/mui/material-ui/pull/38123\n if (themeKey === 'typography' && val === 'inherit') {\n return {\n [prop]: val\n };\n }\n const themeMapping = getPath(theme, themeKey) || {};\n if (style) {\n return style(props);\n }\n const styleFromPropValue = propValueFinal => {\n let value = getValue(themeMapping, transform, propValueFinal);\n if (propValueFinal === value && typeof propValueFinal === 'string') {\n // Haven't found value\n value = getValue(themeMapping, transform, `${prop}${propValueFinal === 'default' ? '' : capitalize(propValueFinal)}`, propValueFinal);\n }\n if (cssProperty === false) {\n return value;\n }\n return {\n [cssProperty]: value\n };\n };\n return handleBreakpoints(props, val, styleFromPropValue);\n }\n function styleFunctionSx(props) {\n var _theme$unstable_sxCon;\n const {\n sx,\n theme = {}\n } = props || {};\n if (!sx) {\n return null; // Emotion & styled-components will neglect null\n }\n const config = (_theme$unstable_sxCon = theme.unstable_sxConfig) != null ? _theme$unstable_sxCon : defaultSxConfig;\n\n /*\n * Receive `sxInput` as object or callback\n * and then recursively check keys & values to create media query object styles.\n * (the result will be used in `styled`)\n */\n function traverse(sxInput) {\n let sxObject = sxInput;\n if (typeof sxInput === 'function') {\n sxObject = sxInput(theme);\n } else if (typeof sxInput !== 'object') {\n // value\n return sxInput;\n }\n if (!sxObject) {\n return null;\n }\n const emptyBreakpoints = createEmptyBreakpointObject(theme.breakpoints);\n const breakpointsKeys = Object.keys(emptyBreakpoints);\n let css = emptyBreakpoints;\n Object.keys(sxObject).forEach(styleKey => {\n const value = callIfFn(sxObject[styleKey], theme);\n if (value !== null && value !== undefined) {\n if (typeof value === 'object') {\n if (config[styleKey]) {\n css = merge(css, getThemeValue(styleKey, value, theme, config));\n } else {\n const breakpointsValues = handleBreakpoints({\n theme\n }, value, x => ({\n [styleKey]: x\n }));\n if (objectsHaveSameKeys(breakpointsValues, value)) {\n css[styleKey] = styleFunctionSx({\n sx: value,\n theme\n });\n } else {\n css = merge(css, breakpointsValues);\n }\n }\n } else {\n css = merge(css, getThemeValue(styleKey, value, theme, config));\n }\n }\n });\n return removeUnusedBreakpoints(breakpointsKeys, css);\n }\n return Array.isArray(sx) ? sx.map(traverse) : traverse(sx);\n }\n return styleFunctionSx;\n}\nconst styleFunctionSx = unstable_createStyleFunctionSx();\nstyleFunctionSx.filterProps = ['sx'];\nexport default styleFunctionSx;","/**\n * A universal utility to style components with multiple color modes. Always use it from the theme object.\n * It works with:\n * - [Basic theme](https://mui.com/material-ui/customization/dark-mode/)\n * - [CSS theme variables](https://mui.com/material-ui/experimental-api/css-theme-variables/overview/)\n * - Zero-runtime engine\n *\n * Tips: Use an array over object spread and place `theme.applyStyles()` last.\n *\n * ✅ [{ background: '#e5e5e5' }, theme.applyStyles('dark', { background: '#1c1c1c' })]\n *\n * 🚫 { background: '#e5e5e5', ...theme.applyStyles('dark', { background: '#1c1c1c' })}\n *\n * @example\n * 1. using with `styled`:\n * ```jsx\n * const Component = styled('div')(({ theme }) => [\n * { background: '#e5e5e5' },\n * theme.applyStyles('dark', {\n * background: '#1c1c1c',\n * color: '#fff',\n * }),\n * ]);\n * ```\n *\n * @example\n * 2. using with `sx` prop:\n * ```jsx\n * [\n * { background: '#e5e5e5' },\n * theme.applyStyles('dark', {\n * background: '#1c1c1c',\n * color: '#fff',\n * }),\n * ]}\n * />\n * ```\n *\n * @example\n * 3. theming a component:\n * ```jsx\n * extendTheme({\n * components: {\n * MuiButton: {\n * styleOverrides: {\n * root: ({ theme }) => [\n * { background: '#e5e5e5' },\n * theme.applyStyles('dark', {\n * background: '#1c1c1c',\n * color: '#fff',\n * }),\n * ],\n * },\n * }\n * }\n * })\n *```\n */\nexport default function applyStyles(key, styles) {\n // @ts-expect-error this is 'any' type\n const theme = this;\n if (theme.vars && typeof theme.getColorSchemeSelector === 'function') {\n // If CssVarsProvider is used as a provider,\n // returns '* :where([data-mui-color-scheme=\"light|dark\"]) &'\n const selector = theme.getColorSchemeSelector(key).replace(/(\\[[^\\]]+\\])/, '*:where($1)');\n return {\n [selector]: styles\n };\n }\n if (theme.palette.mode === key) {\n return styles;\n }\n return {};\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"breakpoints\", \"palette\", \"spacing\", \"shape\"];\nimport deepmerge from '@mui/utils/deepmerge';\nimport createBreakpoints from './createBreakpoints';\nimport shape from './shape';\nimport createSpacing from './createSpacing';\nimport styleFunctionSx from '../styleFunctionSx/styleFunctionSx';\nimport defaultSxConfig from '../styleFunctionSx/defaultSxConfig';\nimport applyStyles from './applyStyles';\nfunction createTheme(options = {}, ...args) {\n const {\n breakpoints: breakpointsInput = {},\n palette: paletteInput = {},\n spacing: spacingInput,\n shape: shapeInput = {}\n } = options,\n other = _objectWithoutPropertiesLoose(options, _excluded);\n const breakpoints = createBreakpoints(breakpointsInput);\n const spacing = createSpacing(spacingInput);\n let muiTheme = deepmerge({\n breakpoints,\n direction: 'ltr',\n components: {},\n // Inject component definitions.\n palette: _extends({\n mode: 'light'\n }, paletteInput),\n spacing,\n shape: _extends({}, shape, shapeInput)\n }, other);\n muiTheme.applyStyles = applyStyles;\n muiTheme = args.reduce((acc, argument) => deepmerge(acc, argument), muiTheme);\n muiTheme.unstable_sxConfig = _extends({}, defaultSxConfig, other == null ? void 0 : other.unstable_sxConfig);\n muiTheme.unstable_sx = function sx(props) {\n return styleFunctionSx({\n sx: props,\n theme: this\n });\n };\n return muiTheme;\n}\nexport default createTheme;","'use client';\n\nimport * as React from 'react';\nimport { ThemeContext } from '@mui/styled-engine';\nfunction isObjectEmpty(obj) {\n return Object.keys(obj).length === 0;\n}\nfunction useTheme(defaultTheme = null) {\n const contextTheme = React.useContext(ThemeContext);\n return !contextTheme || isObjectEmpty(contextTheme) ? defaultTheme : contextTheme;\n}\nexport default useTheme;","'use client';\n\nimport createTheme from './createTheme';\nimport useThemeWithoutDefault from './useThemeWithoutDefault';\nexport const systemDefaultTheme = createTheme();\nfunction useTheme(defaultTheme = systemDefaultTheme) {\n return useThemeWithoutDefault(defaultTheme);\n}\nexport default useTheme;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"ownerState\"],\n _excluded2 = [\"variants\"],\n _excluded3 = [\"name\", \"slot\", \"skipVariantsResolver\", \"skipSx\", \"overridesResolver\"];\n/* eslint-disable no-underscore-dangle */\nimport styledEngineStyled, { internal_processStyles as processStyles } from '@mui/styled-engine';\nimport { isPlainObject } from '@mui/utils/deepmerge';\nimport capitalize from '@mui/utils/capitalize';\nimport getDisplayName from '@mui/utils/getDisplayName';\nimport createTheme from './createTheme';\nimport styleFunctionSx from './styleFunctionSx';\nfunction isEmpty(obj) {\n return Object.keys(obj).length === 0;\n}\n\n// https://github.com/emotion-js/emotion/blob/26ded6109fcd8ca9875cc2ce4564fee678a3f3c5/packages/styled/src/utils.js#L40\nfunction isStringTag(tag) {\n return typeof tag === 'string' &&\n // 96 is one less than the char code\n // for \"a\" so this is checking that\n // it's a lowercase character\n tag.charCodeAt(0) > 96;\n}\n\n// Update /system/styled/#api in case if this changes\nexport function shouldForwardProp(prop) {\n return prop !== 'ownerState' && prop !== 'theme' && prop !== 'sx' && prop !== 'as';\n}\nexport const systemDefaultTheme = createTheme();\nconst lowercaseFirstLetter = string => {\n if (!string) {\n return string;\n }\n return string.charAt(0).toLowerCase() + string.slice(1);\n};\nfunction resolveTheme({\n defaultTheme,\n theme,\n themeId\n}) {\n return isEmpty(theme) ? defaultTheme : theme[themeId] || theme;\n}\nfunction defaultOverridesResolver(slot) {\n if (!slot) {\n return null;\n }\n return (props, styles) => styles[slot];\n}\nfunction processStyleArg(callableStyle, _ref) {\n let {\n ownerState\n } = _ref,\n props = _objectWithoutPropertiesLoose(_ref, _excluded);\n const resolvedStylesArg = typeof callableStyle === 'function' ? callableStyle(_extends({\n ownerState\n }, props)) : callableStyle;\n if (Array.isArray(resolvedStylesArg)) {\n return resolvedStylesArg.flatMap(resolvedStyle => processStyleArg(resolvedStyle, _extends({\n ownerState\n }, props)));\n }\n if (!!resolvedStylesArg && typeof resolvedStylesArg === 'object' && Array.isArray(resolvedStylesArg.variants)) {\n const {\n variants = []\n } = resolvedStylesArg,\n otherStyles = _objectWithoutPropertiesLoose(resolvedStylesArg, _excluded2);\n let result = otherStyles;\n variants.forEach(variant => {\n let isMatch = true;\n if (typeof variant.props === 'function') {\n isMatch = variant.props(_extends({\n ownerState\n }, props, ownerState));\n } else {\n Object.keys(variant.props).forEach(key => {\n if ((ownerState == null ? void 0 : ownerState[key]) !== variant.props[key] && props[key] !== variant.props[key]) {\n isMatch = false;\n }\n });\n }\n if (isMatch) {\n if (!Array.isArray(result)) {\n result = [result];\n }\n result.push(typeof variant.style === 'function' ? variant.style(_extends({\n ownerState\n }, props, ownerState)) : variant.style);\n }\n });\n return result;\n }\n return resolvedStylesArg;\n}\nexport default function createStyled(input = {}) {\n const {\n themeId,\n defaultTheme = systemDefaultTheme,\n rootShouldForwardProp = shouldForwardProp,\n slotShouldForwardProp = shouldForwardProp\n } = input;\n const systemSx = props => {\n return styleFunctionSx(_extends({}, props, {\n theme: resolveTheme(_extends({}, props, {\n defaultTheme,\n themeId\n }))\n }));\n };\n systemSx.__mui_systemSx = true;\n return (tag, inputOptions = {}) => {\n // Filter out the `sx` style function from the previous styled component to prevent unnecessary styles generated by the composite components.\n processStyles(tag, styles => styles.filter(style => !(style != null && style.__mui_systemSx)));\n const {\n name: componentName,\n slot: componentSlot,\n skipVariantsResolver: inputSkipVariantsResolver,\n skipSx: inputSkipSx,\n // TODO v6: remove `lowercaseFirstLetter()` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n overridesResolver = defaultOverridesResolver(lowercaseFirstLetter(componentSlot))\n } = inputOptions,\n options = _objectWithoutPropertiesLoose(inputOptions, _excluded3);\n\n // if skipVariantsResolver option is defined, take the value, otherwise, true for root and false for other slots.\n const skipVariantsResolver = inputSkipVariantsResolver !== undefined ? inputSkipVariantsResolver :\n // TODO v6: remove `Root` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n componentSlot && componentSlot !== 'Root' && componentSlot !== 'root' || false;\n const skipSx = inputSkipSx || false;\n let label;\n if (process.env.NODE_ENV !== 'production') {\n if (componentName) {\n // TODO v6: remove `lowercaseFirstLetter()` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n label = `${componentName}-${lowercaseFirstLetter(componentSlot || 'Root')}`;\n }\n }\n let shouldForwardPropOption = shouldForwardProp;\n\n // TODO v6: remove `Root` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n if (componentSlot === 'Root' || componentSlot === 'root') {\n shouldForwardPropOption = rootShouldForwardProp;\n } else if (componentSlot) {\n // any other slot specified\n shouldForwardPropOption = slotShouldForwardProp;\n } else if (isStringTag(tag)) {\n // for string (html) tag, preserve the behavior in emotion & styled-components.\n shouldForwardPropOption = undefined;\n }\n const defaultStyledResolver = styledEngineStyled(tag, _extends({\n shouldForwardProp: shouldForwardPropOption,\n label\n }, options));\n const transformStyleArg = stylesArg => {\n // On the server Emotion doesn't use React.forwardRef for creating components, so the created\n // component stays as a function. This condition makes sure that we do not interpolate functions\n // which are basically components used as a selectors.\n if (typeof stylesArg === 'function' && stylesArg.__emotion_real !== stylesArg || isPlainObject(stylesArg)) {\n return props => processStyleArg(stylesArg, _extends({}, props, {\n theme: resolveTheme({\n theme: props.theme,\n defaultTheme,\n themeId\n })\n }));\n }\n return stylesArg;\n };\n const muiStyledResolver = (styleArg, ...expressions) => {\n let transformedStyleArg = transformStyleArg(styleArg);\n const expressionsWithDefaultTheme = expressions ? expressions.map(transformStyleArg) : [];\n if (componentName && overridesResolver) {\n expressionsWithDefaultTheme.push(props => {\n const theme = resolveTheme(_extends({}, props, {\n defaultTheme,\n themeId\n }));\n if (!theme.components || !theme.components[componentName] || !theme.components[componentName].styleOverrides) {\n return null;\n }\n const styleOverrides = theme.components[componentName].styleOverrides;\n const resolvedStyleOverrides = {};\n // TODO: v7 remove iteration and use `resolveStyleArg(styleOverrides[slot])` directly\n Object.entries(styleOverrides).forEach(([slotKey, slotStyle]) => {\n resolvedStyleOverrides[slotKey] = processStyleArg(slotStyle, _extends({}, props, {\n theme\n }));\n });\n return overridesResolver(props, resolvedStyleOverrides);\n });\n }\n if (componentName && !skipVariantsResolver) {\n expressionsWithDefaultTheme.push(props => {\n var _theme$components;\n const theme = resolveTheme(_extends({}, props, {\n defaultTheme,\n themeId\n }));\n const themeVariants = theme == null || (_theme$components = theme.components) == null || (_theme$components = _theme$components[componentName]) == null ? void 0 : _theme$components.variants;\n return processStyleArg({\n variants: themeVariants\n }, _extends({}, props, {\n theme\n }));\n });\n }\n if (!skipSx) {\n expressionsWithDefaultTheme.push(systemSx);\n }\n const numOfCustomFnsApplied = expressionsWithDefaultTheme.length - expressions.length;\n if (Array.isArray(styleArg) && numOfCustomFnsApplied > 0) {\n const placeholders = new Array(numOfCustomFnsApplied).fill('');\n // If the type is array, than we need to add placeholders in the template for the overrides, variants and the sx styles.\n transformedStyleArg = [...styleArg, ...placeholders];\n transformedStyleArg.raw = [...styleArg.raw, ...placeholders];\n }\n const Component = defaultStyledResolver(transformedStyleArg, ...expressionsWithDefaultTheme);\n if (process.env.NODE_ENV !== 'production') {\n let displayName;\n if (componentName) {\n displayName = `${componentName}${capitalize(componentSlot || '')}`;\n }\n if (displayName === undefined) {\n displayName = `Styled(${getDisplayName(tag)})`;\n }\n Component.displayName = displayName;\n }\n if (tag.muiName) {\n Component.muiName = tag.muiName;\n }\n return Component;\n };\n if (defaultStyledResolver.withConfig) {\n muiStyledResolver.withConfig = defaultStyledResolver.withConfig;\n }\n return muiStyledResolver;\n };\n}","import resolveProps from '@mui/utils/resolveProps';\nexport default function getThemeProps(params) {\n const {\n theme,\n name,\n props\n } = params;\n if (!theme || !theme.components || !theme.components[name] || !theme.components[name].defaultProps) {\n return props;\n }\n return resolveProps(theme.components[name].defaultProps, props);\n}","'use client';\n\nimport getThemeProps from './getThemeProps';\nimport useTheme from '../useTheme';\nexport default function useThemeProps({\n props,\n name,\n defaultTheme,\n themeId\n}) {\n let theme = useTheme(defaultTheme);\n if (themeId) {\n theme = theme[themeId] || theme;\n }\n const mergedProps = getThemeProps({\n theme,\n name,\n props\n });\n return mergedProps;\n}","import _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\n/* eslint-disable @typescript-eslint/naming-convention */\nimport clamp from '@mui/utils/clamp';\n/**\n * Returns a number whose value is limited to the given range.\n * @param {number} value The value to be clamped\n * @param {number} min The lower boundary of the output range\n * @param {number} max The upper boundary of the output range\n * @returns {number} A number in the range [min, max]\n */\nfunction clampWrapper(value, min = 0, max = 1) {\n if (process.env.NODE_ENV !== 'production') {\n if (value < min || value > max) {\n console.error(`MUI: The value provided ${value} is out of range [${min}, ${max}].`);\n }\n }\n return clamp(value, min, max);\n}\n\n/**\n * Converts a color from CSS hex format to CSS rgb format.\n * @param {string} color - Hex color, i.e. #nnn or #nnnnnn\n * @returns {string} A CSS rgb color string\n */\nexport function hexToRgb(color) {\n color = color.slice(1);\n const re = new RegExp(`.{1,${color.length >= 6 ? 2 : 1}}`, 'g');\n let colors = color.match(re);\n if (colors && colors[0].length === 1) {\n colors = colors.map(n => n + n);\n }\n return colors ? `rgb${colors.length === 4 ? 'a' : ''}(${colors.map((n, index) => {\n return index < 3 ? parseInt(n, 16) : Math.round(parseInt(n, 16) / 255 * 1000) / 1000;\n }).join(', ')})` : '';\n}\nfunction intToHex(int) {\n const hex = int.toString(16);\n return hex.length === 1 ? `0${hex}` : hex;\n}\n\n/**\n * Returns an object with the type and values of a color.\n *\n * Note: Does not support rgb % values.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @returns {object} - A MUI color object: {type: string, values: number[]}\n */\nexport function decomposeColor(color) {\n // Idempotent\n if (color.type) {\n return color;\n }\n if (color.charAt(0) === '#') {\n return decomposeColor(hexToRgb(color));\n }\n const marker = color.indexOf('(');\n const type = color.substring(0, marker);\n if (['rgb', 'rgba', 'hsl', 'hsla', 'color'].indexOf(type) === -1) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: Unsupported \\`${color}\\` color.\nThe following formats are supported: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color().` : _formatMuiErrorMessage(9, color));\n }\n let values = color.substring(marker + 1, color.length - 1);\n let colorSpace;\n if (type === 'color') {\n values = values.split(' ');\n colorSpace = values.shift();\n if (values.length === 4 && values[3].charAt(0) === '/') {\n values[3] = values[3].slice(1);\n }\n if (['srgb', 'display-p3', 'a98-rgb', 'prophoto-rgb', 'rec-2020'].indexOf(colorSpace) === -1) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: unsupported \\`${colorSpace}\\` color space.\nThe following color spaces are supported: srgb, display-p3, a98-rgb, prophoto-rgb, rec-2020.` : _formatMuiErrorMessage(10, colorSpace));\n }\n } else {\n values = values.split(',');\n }\n values = values.map(value => parseFloat(value));\n return {\n type,\n values,\n colorSpace\n };\n}\n\n/**\n * Returns a channel created from the input color.\n *\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @returns {string} - The channel for the color, that can be used in rgba or hsla colors\n */\nexport const colorChannel = color => {\n const decomposedColor = decomposeColor(color);\n return decomposedColor.values.slice(0, 3).map((val, idx) => decomposedColor.type.indexOf('hsl') !== -1 && idx !== 0 ? `${val}%` : val).join(' ');\n};\nexport const private_safeColorChannel = (color, warning) => {\n try {\n return colorChannel(color);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n};\n\n/**\n * Converts a color object with type and values to a string.\n * @param {object} color - Decomposed color\n * @param {string} color.type - One of: 'rgb', 'rgba', 'hsl', 'hsla', 'color'\n * @param {array} color.values - [n,n,n] or [n,n,n,n]\n * @returns {string} A CSS color string\n */\nexport function recomposeColor(color) {\n const {\n type,\n colorSpace\n } = color;\n let {\n values\n } = color;\n if (type.indexOf('rgb') !== -1) {\n // Only convert the first 3 values to int (i.e. not alpha)\n values = values.map((n, i) => i < 3 ? parseInt(n, 10) : n);\n } else if (type.indexOf('hsl') !== -1) {\n values[1] = `${values[1]}%`;\n values[2] = `${values[2]}%`;\n }\n if (type.indexOf('color') !== -1) {\n values = `${colorSpace} ${values.join(' ')}`;\n } else {\n values = `${values.join(', ')}`;\n }\n return `${type}(${values})`;\n}\n\n/**\n * Converts a color from CSS rgb format to CSS hex format.\n * @param {string} color - RGB color, i.e. rgb(n, n, n)\n * @returns {string} A CSS rgb color string, i.e. #nnnnnn\n */\nexport function rgbToHex(color) {\n // Idempotent\n if (color.indexOf('#') === 0) {\n return color;\n }\n const {\n values\n } = decomposeColor(color);\n return `#${values.map((n, i) => intToHex(i === 3 ? Math.round(255 * n) : n)).join('')}`;\n}\n\n/**\n * Converts a color from hsl format to rgb format.\n * @param {string} color - HSL color values\n * @returns {string} rgb color values\n */\nexport function hslToRgb(color) {\n color = decomposeColor(color);\n const {\n values\n } = color;\n const h = values[0];\n const s = values[1] / 100;\n const l = values[2] / 100;\n const a = s * Math.min(l, 1 - l);\n const f = (n, k = (n + h / 30) % 12) => l - a * Math.max(Math.min(k - 3, 9 - k, 1), -1);\n let type = 'rgb';\n const rgb = [Math.round(f(0) * 255), Math.round(f(8) * 255), Math.round(f(4) * 255)];\n if (color.type === 'hsla') {\n type += 'a';\n rgb.push(values[3]);\n }\n return recomposeColor({\n type,\n values: rgb\n });\n}\n/**\n * The relative brightness of any point in a color space,\n * normalized to 0 for darkest black and 1 for lightest white.\n *\n * Formula: https://www.w3.org/TR/WCAG20-TECHS/G17.html#G17-tests\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @returns {number} The relative brightness of the color in the range 0 - 1\n */\nexport function getLuminance(color) {\n color = decomposeColor(color);\n let rgb = color.type === 'hsl' || color.type === 'hsla' ? decomposeColor(hslToRgb(color)).values : color.values;\n rgb = rgb.map(val => {\n if (color.type !== 'color') {\n val /= 255; // normalized\n }\n return val <= 0.03928 ? val / 12.92 : ((val + 0.055) / 1.055) ** 2.4;\n });\n\n // Truncate at 3 digits\n return Number((0.2126 * rgb[0] + 0.7152 * rgb[1] + 0.0722 * rgb[2]).toFixed(3));\n}\n\n/**\n * Calculates the contrast ratio between two colors.\n *\n * Formula: https://www.w3.org/TR/WCAG20-TECHS/G17.html#G17-tests\n * @param {string} foreground - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla()\n * @param {string} background - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla()\n * @returns {number} A contrast ratio value in the range 0 - 21.\n */\nexport function getContrastRatio(foreground, background) {\n const lumA = getLuminance(foreground);\n const lumB = getLuminance(background);\n return (Math.max(lumA, lumB) + 0.05) / (Math.min(lumA, lumB) + 0.05);\n}\n\n/**\n * Sets the absolute transparency of a color.\n * Any existing alpha values are overwritten.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} value - value to set the alpha channel to in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function alpha(color, value) {\n color = decomposeColor(color);\n value = clampWrapper(value);\n if (color.type === 'rgb' || color.type === 'hsl') {\n color.type += 'a';\n }\n if (color.type === 'color') {\n color.values[3] = `/${value}`;\n } else {\n color.values[3] = value;\n }\n return recomposeColor(color);\n}\nexport function private_safeAlpha(color, value, warning) {\n try {\n return alpha(color, value);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Darkens a color.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} coefficient - multiplier in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function darken(color, coefficient) {\n color = decomposeColor(color);\n coefficient = clampWrapper(coefficient);\n if (color.type.indexOf('hsl') !== -1) {\n color.values[2] *= 1 - coefficient;\n } else if (color.type.indexOf('rgb') !== -1 || color.type.indexOf('color') !== -1) {\n for (let i = 0; i < 3; i += 1) {\n color.values[i] *= 1 - coefficient;\n }\n }\n return recomposeColor(color);\n}\nexport function private_safeDarken(color, coefficient, warning) {\n try {\n return darken(color, coefficient);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Lightens a color.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} coefficient - multiplier in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function lighten(color, coefficient) {\n color = decomposeColor(color);\n coefficient = clampWrapper(coefficient);\n if (color.type.indexOf('hsl') !== -1) {\n color.values[2] += (100 - color.values[2]) * coefficient;\n } else if (color.type.indexOf('rgb') !== -1) {\n for (let i = 0; i < 3; i += 1) {\n color.values[i] += (255 - color.values[i]) * coefficient;\n }\n } else if (color.type.indexOf('color') !== -1) {\n for (let i = 0; i < 3; i += 1) {\n color.values[i] += (1 - color.values[i]) * coefficient;\n }\n }\n return recomposeColor(color);\n}\nexport function private_safeLighten(color, coefficient, warning) {\n try {\n return lighten(color, coefficient);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Darken or lighten a color, depending on its luminance.\n * Light colors are darkened, dark colors are lightened.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} coefficient=0.15 - multiplier in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function emphasize(color, coefficient = 0.15) {\n return getLuminance(color) > 0.5 ? darken(color, coefficient) : lighten(color, coefficient);\n}\nexport function private_safeEmphasize(color, coefficient, warning) {\n try {\n return emphasize(color, coefficient);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Blend a transparent overlay color with a background color, resulting in a single\n * RGB color.\n * @param {string} background - CSS color\n * @param {string} overlay - CSS color\n * @param {number} opacity - Opacity multiplier in the range 0 - 1\n * @param {number} [gamma=1.0] - Gamma correction factor. For gamma-correct blending, 2.2 is usual.\n */\nexport function blend(background, overlay, opacity, gamma = 1.0) {\n const blendChannel = (b, o) => Math.round((b ** (1 / gamma) * (1 - opacity) + o ** (1 / gamma) * opacity) ** gamma);\n const backgroundColor = decomposeColor(background);\n const overlayColor = decomposeColor(overlay);\n const rgb = [blendChannel(backgroundColor.values[0], overlayColor.values[0]), blendChannel(backgroundColor.values[1], overlayColor.values[1]), blendChannel(backgroundColor.values[2], overlayColor.values[2])];\n return recomposeColor({\n type: 'rgb',\n values: rgb\n });\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nexport default function createMixins(breakpoints, mixins) {\n return _extends({\n toolbar: {\n minHeight: 56,\n [breakpoints.up('xs')]: {\n '@media (orientation: landscape)': {\n minHeight: 48\n }\n },\n [breakpoints.up('sm')]: {\n minHeight: 64\n }\n }\n }, mixins);\n}","const common = {\n black: '#000',\n white: '#fff'\n};\nexport default common;","const grey = {\n 50: '#fafafa',\n 100: '#f5f5f5',\n 200: '#eeeeee',\n 300: '#e0e0e0',\n 400: '#bdbdbd',\n 500: '#9e9e9e',\n 600: '#757575',\n 700: '#616161',\n 800: '#424242',\n 900: '#212121',\n A100: '#f5f5f5',\n A200: '#eeeeee',\n A400: '#bdbdbd',\n A700: '#616161'\n};\nexport default grey;","const purple = {\n 50: '#f3e5f5',\n 100: '#e1bee7',\n 200: '#ce93d8',\n 300: '#ba68c8',\n 400: '#ab47bc',\n 500: '#9c27b0',\n 600: '#8e24aa',\n 700: '#7b1fa2',\n 800: '#6a1b9a',\n 900: '#4a148c',\n A100: '#ea80fc',\n A200: '#e040fb',\n A400: '#d500f9',\n A700: '#aa00ff'\n};\nexport default purple;","const red = {\n 50: '#ffebee',\n 100: '#ffcdd2',\n 200: '#ef9a9a',\n 300: '#e57373',\n 400: '#ef5350',\n 500: '#f44336',\n 600: '#e53935',\n 700: '#d32f2f',\n 800: '#c62828',\n 900: '#b71c1c',\n A100: '#ff8a80',\n A200: '#ff5252',\n A400: '#ff1744',\n A700: '#d50000'\n};\nexport default red;","const orange = {\n 50: '#fff3e0',\n 100: '#ffe0b2',\n 200: '#ffcc80',\n 300: '#ffb74d',\n 400: '#ffa726',\n 500: '#ff9800',\n 600: '#fb8c00',\n 700: '#f57c00',\n 800: '#ef6c00',\n 900: '#e65100',\n A100: '#ffd180',\n A200: '#ffab40',\n A400: '#ff9100',\n A700: '#ff6d00'\n};\nexport default orange;","const blue = {\n 50: '#e3f2fd',\n 100: '#bbdefb',\n 200: '#90caf9',\n 300: '#64b5f6',\n 400: '#42a5f5',\n 500: '#2196f3',\n 600: '#1e88e5',\n 700: '#1976d2',\n 800: '#1565c0',\n 900: '#0d47a1',\n A100: '#82b1ff',\n A200: '#448aff',\n A400: '#2979ff',\n A700: '#2962ff'\n};\nexport default blue;","const lightBlue = {\n 50: '#e1f5fe',\n 100: '#b3e5fc',\n 200: '#81d4fa',\n 300: '#4fc3f7',\n 400: '#29b6f6',\n 500: '#03a9f4',\n 600: '#039be5',\n 700: '#0288d1',\n 800: '#0277bd',\n 900: '#01579b',\n A100: '#80d8ff',\n A200: '#40c4ff',\n A400: '#00b0ff',\n A700: '#0091ea'\n};\nexport default lightBlue;","const green = {\n 50: '#e8f5e9',\n 100: '#c8e6c9',\n 200: '#a5d6a7',\n 300: '#81c784',\n 400: '#66bb6a',\n 500: '#4caf50',\n 600: '#43a047',\n 700: '#388e3c',\n 800: '#2e7d32',\n 900: '#1b5e20',\n A100: '#b9f6ca',\n A200: '#69f0ae',\n A400: '#00e676',\n A700: '#00c853'\n};\nexport default green;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\nconst _excluded = [\"mode\", \"contrastThreshold\", \"tonalOffset\"];\nimport { deepmerge } from '@mui/utils';\nimport { darken, getContrastRatio, lighten } from '@mui/system';\nimport common from '../colors/common';\nimport grey from '../colors/grey';\nimport purple from '../colors/purple';\nimport red from '../colors/red';\nimport orange from '../colors/orange';\nimport blue from '../colors/blue';\nimport lightBlue from '../colors/lightBlue';\nimport green from '../colors/green';\nexport const light = {\n // The colors used to style the text.\n text: {\n // The most important text.\n primary: 'rgba(0, 0, 0, 0.87)',\n // Secondary text.\n secondary: 'rgba(0, 0, 0, 0.6)',\n // Disabled text have even lower visual prominence.\n disabled: 'rgba(0, 0, 0, 0.38)'\n },\n // The color used to divide different elements.\n divider: 'rgba(0, 0, 0, 0.12)',\n // The background colors used to style the surfaces.\n // Consistency between these values is important.\n background: {\n paper: common.white,\n default: common.white\n },\n // The colors used to style the action elements.\n action: {\n // The color of an active action like an icon button.\n active: 'rgba(0, 0, 0, 0.54)',\n // The color of an hovered action.\n hover: 'rgba(0, 0, 0, 0.04)',\n hoverOpacity: 0.04,\n // The color of a selected action.\n selected: 'rgba(0, 0, 0, 0.08)',\n selectedOpacity: 0.08,\n // The color of a disabled action.\n disabled: 'rgba(0, 0, 0, 0.26)',\n // The background color of a disabled action.\n disabledBackground: 'rgba(0, 0, 0, 0.12)',\n disabledOpacity: 0.38,\n focus: 'rgba(0, 0, 0, 0.12)',\n focusOpacity: 0.12,\n activatedOpacity: 0.12\n }\n};\nexport const dark = {\n text: {\n primary: common.white,\n secondary: 'rgba(255, 255, 255, 0.7)',\n disabled: 'rgba(255, 255, 255, 0.5)',\n icon: 'rgba(255, 255, 255, 0.5)'\n },\n divider: 'rgba(255, 255, 255, 0.12)',\n background: {\n paper: '#121212',\n default: '#121212'\n },\n action: {\n active: common.white,\n hover: 'rgba(255, 255, 255, 0.08)',\n hoverOpacity: 0.08,\n selected: 'rgba(255, 255, 255, 0.16)',\n selectedOpacity: 0.16,\n disabled: 'rgba(255, 255, 255, 0.3)',\n disabledBackground: 'rgba(255, 255, 255, 0.12)',\n disabledOpacity: 0.38,\n focus: 'rgba(255, 255, 255, 0.12)',\n focusOpacity: 0.12,\n activatedOpacity: 0.24\n }\n};\nfunction addLightOrDark(intent, direction, shade, tonalOffset) {\n const tonalOffsetLight = tonalOffset.light || tonalOffset;\n const tonalOffsetDark = tonalOffset.dark || tonalOffset * 1.5;\n if (!intent[direction]) {\n if (intent.hasOwnProperty(shade)) {\n intent[direction] = intent[shade];\n } else if (direction === 'light') {\n intent.light = lighten(intent.main, tonalOffsetLight);\n } else if (direction === 'dark') {\n intent.dark = darken(intent.main, tonalOffsetDark);\n }\n }\n}\nfunction getDefaultPrimary(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: blue[200],\n light: blue[50],\n dark: blue[400]\n };\n }\n return {\n main: blue[700],\n light: blue[400],\n dark: blue[800]\n };\n}\nfunction getDefaultSecondary(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: purple[200],\n light: purple[50],\n dark: purple[400]\n };\n }\n return {\n main: purple[500],\n light: purple[300],\n dark: purple[700]\n };\n}\nfunction getDefaultError(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: red[500],\n light: red[300],\n dark: red[700]\n };\n }\n return {\n main: red[700],\n light: red[400],\n dark: red[800]\n };\n}\nfunction getDefaultInfo(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: lightBlue[400],\n light: lightBlue[300],\n dark: lightBlue[700]\n };\n }\n return {\n main: lightBlue[700],\n light: lightBlue[500],\n dark: lightBlue[900]\n };\n}\nfunction getDefaultSuccess(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: green[400],\n light: green[300],\n dark: green[700]\n };\n }\n return {\n main: green[800],\n light: green[500],\n dark: green[900]\n };\n}\nfunction getDefaultWarning(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: orange[400],\n light: orange[300],\n dark: orange[700]\n };\n }\n return {\n main: '#ed6c02',\n // closest to orange[800] that pass 3:1.\n light: orange[500],\n dark: orange[900]\n };\n}\nexport default function createPalette(palette) {\n const {\n mode = 'light',\n contrastThreshold = 3,\n tonalOffset = 0.2\n } = palette,\n other = _objectWithoutPropertiesLoose(palette, _excluded);\n const primary = palette.primary || getDefaultPrimary(mode);\n const secondary = palette.secondary || getDefaultSecondary(mode);\n const error = palette.error || getDefaultError(mode);\n const info = palette.info || getDefaultInfo(mode);\n const success = palette.success || getDefaultSuccess(mode);\n const warning = palette.warning || getDefaultWarning(mode);\n\n // Use the same logic as\n // Bootstrap: https://github.com/twbs/bootstrap/blob/1d6e3710dd447de1a200f29e8fa521f8a0908f70/scss/_functions.scss#L59\n // and material-components-web https://github.com/material-components/material-components-web/blob/ac46b8863c4dab9fc22c4c662dc6bd1b65dd652f/packages/mdc-theme/_functions.scss#L54\n function getContrastText(background) {\n const contrastText = getContrastRatio(background, dark.text.primary) >= contrastThreshold ? dark.text.primary : light.text.primary;\n if (process.env.NODE_ENV !== 'production') {\n const contrast = getContrastRatio(background, contrastText);\n if (contrast < 3) {\n console.error([`MUI: The contrast ratio of ${contrast}:1 for ${contrastText} on ${background}`, 'falls below the WCAG recommended absolute minimum contrast ratio of 3:1.', 'https://www.w3.org/TR/2008/REC-WCAG20-20081211/#visual-audio-contrast-contrast'].join('\\n'));\n }\n }\n return contrastText;\n }\n const augmentColor = ({\n color,\n name,\n mainShade = 500,\n lightShade = 300,\n darkShade = 700\n }) => {\n color = _extends({}, color);\n if (!color.main && color[mainShade]) {\n color.main = color[mainShade];\n }\n if (!color.hasOwnProperty('main')) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: The color${name ? ` (${name})` : ''} provided to augmentColor(color) is invalid.\nThe color object needs to have a \\`main\\` property or a \\`${mainShade}\\` property.` : _formatMuiErrorMessage(11, name ? ` (${name})` : '', mainShade));\n }\n if (typeof color.main !== 'string') {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: The color${name ? ` (${name})` : ''} provided to augmentColor(color) is invalid.\n\\`color.main\\` should be a string, but \\`${JSON.stringify(color.main)}\\` was provided instead.\n\nDid you intend to use one of the following approaches?\n\nimport { green } from \"@mui/material/colors\";\n\nconst theme1 = createTheme({ palette: {\n primary: green,\n} });\n\nconst theme2 = createTheme({ palette: {\n primary: { main: green[500] },\n} });` : _formatMuiErrorMessage(12, name ? ` (${name})` : '', JSON.stringify(color.main)));\n }\n addLightOrDark(color, 'light', lightShade, tonalOffset);\n addLightOrDark(color, 'dark', darkShade, tonalOffset);\n if (!color.contrastText) {\n color.contrastText = getContrastText(color.main);\n }\n return color;\n };\n const modes = {\n dark,\n light\n };\n if (process.env.NODE_ENV !== 'production') {\n if (!modes[mode]) {\n console.error(`MUI: The palette mode \\`${mode}\\` is not supported.`);\n }\n }\n const paletteOutput = deepmerge(_extends({\n // A collection of common colors.\n common: _extends({}, common),\n // prevent mutable object.\n // The palette mode, can be light or dark.\n mode,\n // The colors used to represent primary interface elements for a user.\n primary: augmentColor({\n color: primary,\n name: 'primary'\n }),\n // The colors used to represent secondary interface elements for a user.\n secondary: augmentColor({\n color: secondary,\n name: 'secondary',\n mainShade: 'A400',\n lightShade: 'A200',\n darkShade: 'A700'\n }),\n // The colors used to represent interface elements that the user should be made aware of.\n error: augmentColor({\n color: error,\n name: 'error'\n }),\n // The colors used to represent potentially dangerous actions or important messages.\n warning: augmentColor({\n color: warning,\n name: 'warning'\n }),\n // The colors used to present information to the user that is neutral and not necessarily important.\n info: augmentColor({\n color: info,\n name: 'info'\n }),\n // The colors used to indicate the successful completion of an action that user triggered.\n success: augmentColor({\n color: success,\n name: 'success'\n }),\n // The grey colors.\n grey,\n // Used by `getContrastText()` to maximize the contrast between\n // the background and the text.\n contrastThreshold,\n // Takes a background color and returns the text color that maximizes the contrast.\n getContrastText,\n // Generate a rich color object.\n augmentColor,\n // Used by the functions below to shift a color's luminance by approximately\n // two indexes within its tonal palette.\n // E.g., shift from Red 500 to Red 300 or Red 700.\n tonalOffset\n }, modes[mode]), other);\n return paletteOutput;\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"fontFamily\", \"fontSize\", \"fontWeightLight\", \"fontWeightRegular\", \"fontWeightMedium\", \"fontWeightBold\", \"htmlFontSize\", \"allVariants\", \"pxToRem\"];\nimport { deepmerge } from '@mui/utils';\nfunction round(value) {\n return Math.round(value * 1e5) / 1e5;\n}\nconst caseAllCaps = {\n textTransform: 'uppercase'\n};\nconst defaultFontFamily = '\"Roboto\", \"Helvetica\", \"Arial\", sans-serif';\n\n/**\n * @see @link{https://m2.material.io/design/typography/the-type-system.html}\n * @see @link{https://m2.material.io/design/typography/understanding-typography.html}\n */\nexport default function createTypography(palette, typography) {\n const _ref = typeof typography === 'function' ? typography(palette) : typography,\n {\n fontFamily = defaultFontFamily,\n // The default font size of the Material Specification.\n fontSize = 14,\n // px\n fontWeightLight = 300,\n fontWeightRegular = 400,\n fontWeightMedium = 500,\n fontWeightBold = 700,\n // Tell MUI what's the font-size on the html element.\n // 16px is the default font-size used by browsers.\n htmlFontSize = 16,\n // Apply the CSS properties to all the variants.\n allVariants,\n pxToRem: pxToRem2\n } = _ref,\n other = _objectWithoutPropertiesLoose(_ref, _excluded);\n if (process.env.NODE_ENV !== 'production') {\n if (typeof fontSize !== 'number') {\n console.error('MUI: `fontSize` is required to be a number.');\n }\n if (typeof htmlFontSize !== 'number') {\n console.error('MUI: `htmlFontSize` is required to be a number.');\n }\n }\n const coef = fontSize / 14;\n const pxToRem = pxToRem2 || (size => `${size / htmlFontSize * coef}rem`);\n const buildVariant = (fontWeight, size, lineHeight, letterSpacing, casing) => _extends({\n fontFamily,\n fontWeight,\n fontSize: pxToRem(size),\n // Unitless following https://meyerweb.com/eric/thoughts/2006/02/08/unitless-line-heights/\n lineHeight\n }, fontFamily === defaultFontFamily ? {\n letterSpacing: `${round(letterSpacing / size)}em`\n } : {}, casing, allVariants);\n const variants = {\n h1: buildVariant(fontWeightLight, 96, 1.167, -1.5),\n h2: buildVariant(fontWeightLight, 60, 1.2, -0.5),\n h3: buildVariant(fontWeightRegular, 48, 1.167, 0),\n h4: buildVariant(fontWeightRegular, 34, 1.235, 0.25),\n h5: buildVariant(fontWeightRegular, 24, 1.334, 0),\n h6: buildVariant(fontWeightMedium, 20, 1.6, 0.15),\n subtitle1: buildVariant(fontWeightRegular, 16, 1.75, 0.15),\n subtitle2: buildVariant(fontWeightMedium, 14, 1.57, 0.1),\n body1: buildVariant(fontWeightRegular, 16, 1.5, 0.15),\n body2: buildVariant(fontWeightRegular, 14, 1.43, 0.15),\n button: buildVariant(fontWeightMedium, 14, 1.75, 0.4, caseAllCaps),\n caption: buildVariant(fontWeightRegular, 12, 1.66, 0.4),\n overline: buildVariant(fontWeightRegular, 12, 2.66, 1, caseAllCaps),\n // TODO v6: Remove handling of 'inherit' variant from the theme as it is already handled in Material UI's Typography component. Also, remember to remove the associated types.\n inherit: {\n fontFamily: 'inherit',\n fontWeight: 'inherit',\n fontSize: 'inherit',\n lineHeight: 'inherit',\n letterSpacing: 'inherit'\n }\n };\n return deepmerge(_extends({\n htmlFontSize,\n pxToRem,\n fontFamily,\n fontSize,\n fontWeightLight,\n fontWeightRegular,\n fontWeightMedium,\n fontWeightBold\n }, variants), other, {\n clone: false // No need to clone deep\n });\n}","const shadowKeyUmbraOpacity = 0.2;\nconst shadowKeyPenumbraOpacity = 0.14;\nconst shadowAmbientShadowOpacity = 0.12;\nfunction createShadow(...px) {\n return [`${px[0]}px ${px[1]}px ${px[2]}px ${px[3]}px rgba(0,0,0,${shadowKeyUmbraOpacity})`, `${px[4]}px ${px[5]}px ${px[6]}px ${px[7]}px rgba(0,0,0,${shadowKeyPenumbraOpacity})`, `${px[8]}px ${px[9]}px ${px[10]}px ${px[11]}px rgba(0,0,0,${shadowAmbientShadowOpacity})`].join(',');\n}\n\n// Values from https://github.com/material-components/material-components-web/blob/be8747f94574669cb5e7add1a7c54fa41a89cec7/packages/mdc-elevation/_variables.scss\nconst shadows = ['none', createShadow(0, 2, 1, -1, 0, 1, 1, 0, 0, 1, 3, 0), createShadow(0, 3, 1, -2, 0, 2, 2, 0, 0, 1, 5, 0), createShadow(0, 3, 3, -2, 0, 3, 4, 0, 0, 1, 8, 0), createShadow(0, 2, 4, -1, 0, 4, 5, 0, 0, 1, 10, 0), createShadow(0, 3, 5, -1, 0, 5, 8, 0, 0, 1, 14, 0), createShadow(0, 3, 5, -1, 0, 6, 10, 0, 0, 1, 18, 0), createShadow(0, 4, 5, -2, 0, 7, 10, 1, 0, 2, 16, 1), createShadow(0, 5, 5, -3, 0, 8, 10, 1, 0, 3, 14, 2), createShadow(0, 5, 6, -3, 0, 9, 12, 1, 0, 3, 16, 2), createShadow(0, 6, 6, -3, 0, 10, 14, 1, 0, 4, 18, 3), createShadow(0, 6, 7, -4, 0, 11, 15, 1, 0, 4, 20, 3), createShadow(0, 7, 8, -4, 0, 12, 17, 2, 0, 5, 22, 4), createShadow(0, 7, 8, -4, 0, 13, 19, 2, 0, 5, 24, 4), createShadow(0, 7, 9, -4, 0, 14, 21, 2, 0, 5, 26, 4), createShadow(0, 8, 9, -5, 0, 15, 22, 2, 0, 6, 28, 5), createShadow(0, 8, 10, -5, 0, 16, 24, 2, 0, 6, 30, 5), createShadow(0, 8, 11, -5, 0, 17, 26, 2, 0, 6, 32, 5), createShadow(0, 9, 11, -5, 0, 18, 28, 2, 0, 7, 34, 6), createShadow(0, 9, 12, -6, 0, 19, 29, 2, 0, 7, 36, 6), createShadow(0, 10, 13, -6, 0, 20, 31, 3, 0, 8, 38, 7), createShadow(0, 10, 13, -6, 0, 21, 33, 3, 0, 8, 40, 7), createShadow(0, 10, 14, -6, 0, 22, 35, 3, 0, 8, 42, 7), createShadow(0, 11, 14, -7, 0, 23, 36, 3, 0, 9, 44, 8), createShadow(0, 11, 15, -7, 0, 24, 38, 3, 0, 9, 46, 8)];\nexport default shadows;","import _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nconst _excluded = [\"duration\", \"easing\", \"delay\"];\n// Follow https://material.google.com/motion/duration-easing.html#duration-easing-natural-easing-curves\n// to learn the context in which each easing should be used.\nexport const easing = {\n // This is the most common easing curve.\n easeInOut: 'cubic-bezier(0.4, 0, 0.2, 1)',\n // Objects enter the screen at full velocity from off-screen and\n // slowly decelerate to a resting point.\n easeOut: 'cubic-bezier(0.0, 0, 0.2, 1)',\n // Objects leave the screen at full velocity. They do not decelerate when off-screen.\n easeIn: 'cubic-bezier(0.4, 0, 1, 1)',\n // The sharp curve is used by objects that may return to the screen at any time.\n sharp: 'cubic-bezier(0.4, 0, 0.6, 1)'\n};\n\n// Follow https://m2.material.io/guidelines/motion/duration-easing.html#duration-easing-common-durations\n// to learn when use what timing\nexport const duration = {\n shortest: 150,\n shorter: 200,\n short: 250,\n // most basic recommended timing\n standard: 300,\n // this is to be used in complex animations\n complex: 375,\n // recommended when something is entering screen\n enteringScreen: 225,\n // recommended when something is leaving screen\n leavingScreen: 195\n};\nfunction formatMs(milliseconds) {\n return `${Math.round(milliseconds)}ms`;\n}\nfunction getAutoHeightDuration(height) {\n if (!height) {\n return 0;\n }\n const constant = height / 36;\n\n // https://www.wolframalpha.com/input/?i=(4+%2B+15+*+(x+%2F+36+)+**+0.25+%2B+(x+%2F+36)+%2F+5)+*+10\n return Math.round((4 + 15 * constant ** 0.25 + constant / 5) * 10);\n}\nexport default function createTransitions(inputTransitions) {\n const mergedEasing = _extends({}, easing, inputTransitions.easing);\n const mergedDuration = _extends({}, duration, inputTransitions.duration);\n const create = (props = ['all'], options = {}) => {\n const {\n duration: durationOption = mergedDuration.standard,\n easing: easingOption = mergedEasing.easeInOut,\n delay = 0\n } = options,\n other = _objectWithoutPropertiesLoose(options, _excluded);\n if (process.env.NODE_ENV !== 'production') {\n const isString = value => typeof value === 'string';\n // IE11 support, replace with Number.isNaN\n // eslint-disable-next-line no-restricted-globals\n const isNumber = value => !isNaN(parseFloat(value));\n if (!isString(props) && !Array.isArray(props)) {\n console.error('MUI: Argument \"props\" must be a string or Array.');\n }\n if (!isNumber(durationOption) && !isString(durationOption)) {\n console.error(`MUI: Argument \"duration\" must be a number or a string but found ${durationOption}.`);\n }\n if (!isString(easingOption)) {\n console.error('MUI: Argument \"easing\" must be a string.');\n }\n if (!isNumber(delay) && !isString(delay)) {\n console.error('MUI: Argument \"delay\" must be a number or a string.');\n }\n if (typeof options !== 'object') {\n console.error(['MUI: Secong argument of transition.create must be an object.', \"Arguments should be either `create('prop1', options)` or `create(['prop1', 'prop2'], options)`\"].join('\\n'));\n }\n if (Object.keys(other).length !== 0) {\n console.error(`MUI: Unrecognized argument(s) [${Object.keys(other).join(',')}].`);\n }\n }\n return (Array.isArray(props) ? props : [props]).map(animatedProp => `${animatedProp} ${typeof durationOption === 'string' ? durationOption : formatMs(durationOption)} ${easingOption} ${typeof delay === 'string' ? delay : formatMs(delay)}`).join(',');\n };\n return _extends({\n getAutoHeightDuration,\n create\n }, inputTransitions, {\n easing: mergedEasing,\n duration: mergedDuration\n });\n}","// We need to centralize the zIndex definitions as they work\n// like global values in the browser.\nconst zIndex = {\n mobileStepper: 1000,\n fab: 1050,\n speedDial: 1050,\n appBar: 1100,\n drawer: 1200,\n modal: 1300,\n snackbar: 1400,\n tooltip: 1500\n};\nexport default zIndex;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\nconst _excluded = [\"breakpoints\", \"mixins\", \"spacing\", \"palette\", \"transitions\", \"typography\", \"shape\"];\nimport { deepmerge } from '@mui/utils';\nimport { createTheme as systemCreateTheme, unstable_defaultSxConfig as defaultSxConfig, unstable_styleFunctionSx as styleFunctionSx } from '@mui/system';\nimport generateUtilityClass from '@mui/utils/generateUtilityClass';\nimport createMixins from './createMixins';\nimport createPalette from './createPalette';\nimport createTypography from './createTypography';\nimport shadows from './shadows';\nimport createTransitions from './createTransitions';\nimport zIndex from './zIndex';\nfunction createTheme(options = {}, ...args) {\n const {\n mixins: mixinsInput = {},\n palette: paletteInput = {},\n transitions: transitionsInput = {},\n typography: typographyInput = {}\n } = options,\n other = _objectWithoutPropertiesLoose(options, _excluded);\n if (options.vars) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: \\`vars\\` is a private field used for CSS variables support.\nPlease use another name.` : _formatMuiErrorMessage(18));\n }\n const palette = createPalette(paletteInput);\n const systemTheme = systemCreateTheme(options);\n let muiTheme = deepmerge(systemTheme, {\n mixins: createMixins(systemTheme.breakpoints, mixinsInput),\n palette,\n // Don't use [...shadows] until you've verified its transpiled code is not invoking the iterator protocol.\n shadows: shadows.slice(),\n typography: createTypography(palette, typographyInput),\n transitions: createTransitions(transitionsInput),\n zIndex: _extends({}, zIndex)\n });\n muiTheme = deepmerge(muiTheme, other);\n muiTheme = args.reduce((acc, argument) => deepmerge(acc, argument), muiTheme);\n if (process.env.NODE_ENV !== 'production') {\n // TODO v6: Refactor to use globalStateClassesMapping from @mui/utils once `readOnly` state class is used in Rating component.\n const stateClasses = ['active', 'checked', 'completed', 'disabled', 'error', 'expanded', 'focused', 'focusVisible', 'required', 'selected'];\n const traverse = (node, component) => {\n let key;\n\n // eslint-disable-next-line guard-for-in, no-restricted-syntax\n for (key in node) {\n const child = node[key];\n if (stateClasses.indexOf(key) !== -1 && Object.keys(child).length > 0) {\n if (process.env.NODE_ENV !== 'production') {\n const stateClass = generateUtilityClass('', key);\n console.error([`MUI: The \\`${component}\\` component increases ` + `the CSS specificity of the \\`${key}\\` internal state.`, 'You can not override it like this: ', JSON.stringify(node, null, 2), '', `Instead, you need to use the '&.${stateClass}' syntax:`, JSON.stringify({\n root: {\n [`&.${stateClass}`]: child\n }\n }, null, 2), '', 'https://mui.com/r/state-classes-guide'].join('\\n'));\n }\n // Remove the style to prevent global conflicts.\n node[key] = {};\n }\n }\n };\n Object.keys(muiTheme.components).forEach(component => {\n const styleOverrides = muiTheme.components[component].styleOverrides;\n if (styleOverrides && component.indexOf('Mui') === 0) {\n traverse(styleOverrides, component);\n }\n });\n }\n muiTheme.unstable_sxConfig = _extends({}, defaultSxConfig, other == null ? void 0 : other.unstable_sxConfig);\n muiTheme.unstable_sx = function sx(props) {\n return styleFunctionSx({\n sx: props,\n theme: this\n });\n };\n return muiTheme;\n}\nlet warnedOnce = false;\nexport function createMuiTheme(...args) {\n if (process.env.NODE_ENV !== 'production') {\n if (!warnedOnce) {\n warnedOnce = true;\n console.error(['MUI: the createMuiTheme function was renamed to createTheme.', '', \"You should use `import { createTheme } from '@mui/material/styles'`\"].join('\\n'));\n }\n }\n return createTheme(...args);\n}\nexport default createTheme;","'use client';\n\nimport createTheme from './createTheme';\nconst defaultTheme = createTheme();\nexport default defaultTheme;","export default '$$material';","'use client';\n\nimport { useThemeProps as systemUseThemeProps } from '@mui/system';\nimport defaultTheme from './defaultTheme';\nimport THEME_ID from './identifier';\nexport default function useThemeProps({\n props,\n name\n}) {\n return systemUseThemeProps({\n props,\n name,\n defaultTheme,\n themeId: THEME_ID\n });\n}","'use client';\n\nimport { createStyled, shouldForwardProp } from '@mui/system';\nimport defaultTheme from './defaultTheme';\nimport THEME_ID from './identifier';\nexport const rootShouldForwardProp = prop => shouldForwardProp(prop) && prop !== 'classes';\nexport const slotShouldForwardProp = shouldForwardProp;\nconst styled = createStyled({\n themeId: THEME_ID,\n defaultTheme,\n rootShouldForwardProp\n});\nexport default styled;","import generateUtilityClasses from '@mui/utils/generateUtilityClasses';\nimport generateUtilityClass from '@mui/utils/generateUtilityClass';\nexport function getSvgIconUtilityClass(slot) {\n return generateUtilityClass('MuiSvgIcon', slot);\n}\nconst svgIconClasses = generateUtilityClasses('MuiSvgIcon', ['root', 'colorPrimary', 'colorSecondary', 'colorAction', 'colorError', 'colorDisabled', 'fontSizeInherit', 'fontSizeSmall', 'fontSizeMedium', 'fontSizeLarge']);\nexport default svgIconClasses;","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"children\", \"className\", \"color\", \"component\", \"fontSize\", \"htmlColor\", \"inheritViewBox\", \"titleAccess\", \"viewBox\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport clsx from 'clsx';\nimport { unstable_composeClasses as composeClasses } from '@mui/base/composeClasses';\nimport capitalize from '../utils/capitalize';\nimport useThemeProps from '../styles/useThemeProps';\nimport styled from '../styles/styled';\nimport { getSvgIconUtilityClass } from './svgIconClasses';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nimport { jsxs as _jsxs } from \"react/jsx-runtime\";\nconst useUtilityClasses = ownerState => {\n const {\n color,\n fontSize,\n classes\n } = ownerState;\n const slots = {\n root: ['root', color !== 'inherit' && `color${capitalize(color)}`, `fontSize${capitalize(fontSize)}`]\n };\n return composeClasses(slots, getSvgIconUtilityClass, classes);\n};\nconst SvgIconRoot = styled('svg', {\n name: 'MuiSvgIcon',\n slot: 'Root',\n overridesResolver: (props, styles) => {\n const {\n ownerState\n } = props;\n return [styles.root, ownerState.color !== 'inherit' && styles[`color${capitalize(ownerState.color)}`], styles[`fontSize${capitalize(ownerState.fontSize)}`]];\n }\n})(({\n theme,\n ownerState\n}) => {\n var _theme$transitions, _theme$transitions$cr, _theme$transitions2, _theme$typography, _theme$typography$pxT, _theme$typography2, _theme$typography2$px, _theme$typography3, _theme$typography3$px, _palette$ownerState$c, _palette, _palette2, _palette3;\n return {\n userSelect: 'none',\n width: '1em',\n height: '1em',\n display: 'inline-block',\n // the will define the property that has `currentColor`\n // e.g. heroicons uses fill=\"none\" and stroke=\"currentColor\"\n fill: ownerState.hasSvgAsChild ? undefined : 'currentColor',\n flexShrink: 0,\n transition: (_theme$transitions = theme.transitions) == null || (_theme$transitions$cr = _theme$transitions.create) == null ? void 0 : _theme$transitions$cr.call(_theme$transitions, 'fill', {\n duration: (_theme$transitions2 = theme.transitions) == null || (_theme$transitions2 = _theme$transitions2.duration) == null ? void 0 : _theme$transitions2.shorter\n }),\n fontSize: {\n inherit: 'inherit',\n small: ((_theme$typography = theme.typography) == null || (_theme$typography$pxT = _theme$typography.pxToRem) == null ? void 0 : _theme$typography$pxT.call(_theme$typography, 20)) || '1.25rem',\n medium: ((_theme$typography2 = theme.typography) == null || (_theme$typography2$px = _theme$typography2.pxToRem) == null ? void 0 : _theme$typography2$px.call(_theme$typography2, 24)) || '1.5rem',\n large: ((_theme$typography3 = theme.typography) == null || (_theme$typography3$px = _theme$typography3.pxToRem) == null ? void 0 : _theme$typography3$px.call(_theme$typography3, 35)) || '2.1875rem'\n }[ownerState.fontSize],\n // TODO v5 deprecate, v6 remove for sx\n color: (_palette$ownerState$c = (_palette = (theme.vars || theme).palette) == null || (_palette = _palette[ownerState.color]) == null ? void 0 : _palette.main) != null ? _palette$ownerState$c : {\n action: (_palette2 = (theme.vars || theme).palette) == null || (_palette2 = _palette2.action) == null ? void 0 : _palette2.active,\n disabled: (_palette3 = (theme.vars || theme).palette) == null || (_palette3 = _palette3.action) == null ? void 0 : _palette3.disabled,\n inherit: undefined\n }[ownerState.color]\n };\n});\nconst SvgIcon = /*#__PURE__*/React.forwardRef(function SvgIcon(inProps, ref) {\n const props = useThemeProps({\n props: inProps,\n name: 'MuiSvgIcon'\n });\n const {\n children,\n className,\n color = 'inherit',\n component = 'svg',\n fontSize = 'medium',\n htmlColor,\n inheritViewBox = false,\n titleAccess,\n viewBox = '0 0 24 24'\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const hasSvgAsChild = /*#__PURE__*/React.isValidElement(children) && children.type === 'svg';\n const ownerState = _extends({}, props, {\n color,\n component,\n fontSize,\n instanceFontSize: inProps.fontSize,\n inheritViewBox,\n viewBox,\n hasSvgAsChild\n });\n const more = {};\n if (!inheritViewBox) {\n more.viewBox = viewBox;\n }\n const classes = useUtilityClasses(ownerState);\n return /*#__PURE__*/_jsxs(SvgIconRoot, _extends({\n as: component,\n className: clsx(classes.root, className),\n focusable: \"false\",\n color: htmlColor,\n \"aria-hidden\": titleAccess ? undefined : true,\n role: titleAccess ? 'img' : undefined,\n ref: ref\n }, more, other, hasSvgAsChild && children.props, {\n ownerState: ownerState,\n children: [hasSvgAsChild ? children.props.children : children, titleAccess ? /*#__PURE__*/_jsx(\"title\", {\n children: titleAccess\n }) : null]\n }));\n});\nprocess.env.NODE_ENV !== \"production\" ? SvgIcon.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the d.ts file and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * Node passed into the SVG element.\n */\n children: PropTypes.node,\n /**\n * Override or extend the styles applied to the component.\n */\n classes: PropTypes.object,\n /**\n * @ignore\n */\n className: PropTypes.string,\n /**\n * The color of the component.\n * It supports both default and custom theme colors, which can be added as shown in the\n * [palette customization guide](https://mui.com/material-ui/customization/palette/#custom-colors).\n * You can use the `htmlColor` prop to apply a color attribute to the SVG element.\n * @default 'inherit'\n */\n color: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.oneOf(['inherit', 'action', 'disabled', 'primary', 'secondary', 'error', 'info', 'success', 'warning']), PropTypes.string]),\n /**\n * The component used for the root node.\n * Either a string to use a HTML element or a component.\n */\n component: PropTypes.elementType,\n /**\n * The fontSize applied to the icon. Defaults to 24px, but can be configure to inherit font size.\n * @default 'medium'\n */\n fontSize: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.oneOf(['inherit', 'large', 'medium', 'small']), PropTypes.string]),\n /**\n * Applies a color attribute to the SVG element.\n */\n htmlColor: PropTypes.string,\n /**\n * If `true`, the root node will inherit the custom `component`'s viewBox and the `viewBox`\n * prop will be ignored.\n * Useful when you want to reference a custom `component` and have `SvgIcon` pass that\n * `component`'s viewBox to the root node.\n * @default false\n */\n inheritViewBox: PropTypes.bool,\n /**\n * The shape-rendering attribute. The behavior of the different options is described on the\n * [MDN Web Docs](https://developer.mozilla.org/en-US/docs/Web/SVG/Attribute/shape-rendering).\n * If you are having issues with blurry icons you should investigate this prop.\n */\n shapeRendering: PropTypes.string,\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Provides a human-readable title for the element that contains it.\n * https://www.w3.org/TR/SVG-access/#Equivalent\n */\n titleAccess: PropTypes.string,\n /**\n * Allows you to redefine what the coordinates without units mean inside an SVG element.\n * For example, if the SVG element is 500 (width) by 200 (height),\n * and you pass viewBox=\"0 0 50 20\",\n * this means that the coordinates inside the SVG will go from the top left corner (0,0)\n * to bottom right (50,20) and each unit will be worth 10px.\n * @default '0 0 24 24'\n */\n viewBox: PropTypes.string\n} : void 0;\nSvgIcon.muiName = 'SvgIcon';\nexport default SvgIcon;","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport * as React from 'react';\nimport SvgIcon from '../SvgIcon';\n\n/**\n * Private module reserved for @mui packages.\n */\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nexport default function createSvgIcon(path, displayName) {\n function Component(props, ref) {\n return /*#__PURE__*/_jsx(SvgIcon, _extends({\n \"data-testid\": `${displayName}Icon`,\n ref: ref\n }, props, {\n children: path\n }));\n }\n if (process.env.NODE_ENV !== 'production') {\n // Need to set `displayName` on the inner component for React.memo.\n // React prior to 16.14 ignores `displayName` on the wrapper.\n Component.displayName = `${displayName}Icon`;\n }\n Component.muiName = SvgIcon.muiName;\n return /*#__PURE__*/React.memo( /*#__PURE__*/React.forwardRef(Component));\n}","'use client';\n\nimport { unstable_ClassNameGenerator as ClassNameGenerator } from '@mui/base/ClassNameGenerator';\nexport { default as capitalize } from './capitalize';\nexport { default as createChainedFunction } from './createChainedFunction';\nexport { default as createSvgIcon } from './createSvgIcon';\nexport { default as debounce } from './debounce';\nexport { default as deprecatedPropType } from './deprecatedPropType';\nexport { default as isMuiElement } from './isMuiElement';\nexport { default as ownerDocument } from './ownerDocument';\nexport { default as ownerWindow } from './ownerWindow';\nexport { default as requirePropFactory } from './requirePropFactory';\nexport { default as setRef } from './setRef';\nexport { default as unstable_useEnhancedEffect } from './useEnhancedEffect';\nexport { default as unstable_useId } from './useId';\nexport { default as unsupportedProp } from './unsupportedProp';\nexport { default as useControlled } from './useControlled';\nexport { default as useEventCallback } from './useEventCallback';\nexport { default as useForkRef } from './useForkRef';\nexport { default as useIsFocusVisible } from './useIsFocusVisible';\n// TODO: remove this export once ClassNameGenerator is stable\n// eslint-disable-next-line @typescript-eslint/naming-convention\nexport const unstable_ClassNameGenerator = {\n configure: generator => {\n if (process.env.NODE_ENV !== 'production') {\n console.warn(['MUI: `ClassNameGenerator` import from `@mui/material/utils` is outdated and might cause unexpected issues.', '', \"You should use `import { unstable_ClassNameGenerator } from '@mui/material/className'` instead\", '', 'The detail of the issue: https://github.com/mui/material-ui/issues/30011#issuecomment-1024993401', '', 'The updated documentation: https://mui.com/guides/classname-generator/'].join('\\n'));\n }\n ClassNameGenerator.configure(generator);\n }\n};","\"use strict\";\n'use client';\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nObject.defineProperty(exports, \"default\", {\n enumerable: true,\n get: function () {\n return _utils.createSvgIcon;\n }\n});\nvar _utils = require(\"@mui/material/utils\");","\"use strict\";\n\"use client\";\n\nvar _interopRequireDefault = require(\"@babel/runtime/helpers/interopRequireDefault\");\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = void 0;\nvar _createSvgIcon = _interopRequireDefault(require(\"./utils/createSvgIcon\"));\nvar _jsxRuntime = require(\"react/jsx-runtime\");\nvar _default = exports.default = (0, _createSvgIcon.default)( /*#__PURE__*/(0, _jsxRuntime.jsx)(\"path\", {\n d: \"m10 17 5-5-5-5z\"\n}), 'ArrowRight');","/**\n * Determines if a given element is a DOM element name (i.e. not a React component).\n */\nexport function isHostComponent(element) {\n return typeof element === 'string';\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport { isHostComponent } from './isHostComponent';\n\n/**\n * Type of the ownerState based on the type of an element it applies to.\n * This resolves to the provided OwnerState for React components and `undefined` for host components.\n * Falls back to `OwnerState | undefined` when the exact type can't be determined in development time.\n */\n\n/**\n * Appends the ownerState object to the props, merging with the existing one if necessary.\n *\n * @param elementType Type of the element that owns the `existingProps`. If the element is a DOM node or undefined, `ownerState` is not applied.\n * @param otherProps Props of the element.\n * @param ownerState\n */\nexport function appendOwnerState(elementType, otherProps, ownerState) {\n if (elementType === undefined || isHostComponent(elementType)) {\n return otherProps;\n }\n return _extends({}, otherProps, {\n ownerState: _extends({}, otherProps.ownerState, ownerState)\n });\n}","'use client';\n\nimport * as React from 'react';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nconst defaultContextValue = {\n disableDefaultClasses: false\n};\nconst ClassNameConfiguratorContext = /*#__PURE__*/React.createContext(defaultContextValue);\n/**\n * @ignore - internal hook.\n *\n * Wraps the `generateUtilityClass` function and controls how the classes are generated.\n * Currently it only affects whether the classes are applied or not.\n *\n * @returns Function to be called with the `generateUtilityClass` function specific to a component to generate the classes.\n */\nexport function useClassNamesOverride(generateUtilityClass) {\n const {\n disableDefaultClasses\n } = React.useContext(ClassNameConfiguratorContext);\n return slot => {\n if (disableDefaultClasses) {\n return '';\n }\n return generateUtilityClass(slot);\n };\n}\n\n/**\n * Allows to configure the components within to not apply any built-in classes.\n */\nexport function ClassNameConfigurator(props) {\n const {\n disableDefaultClasses,\n children\n } = props;\n const contextValue = React.useMemo(() => ({\n disableDefaultClasses: disableDefaultClasses != null ? disableDefaultClasses : false\n }), [disableDefaultClasses]);\n return /*#__PURE__*/_jsx(ClassNameConfiguratorContext.Provider, {\n value: contextValue,\n children: children\n });\n}","/**\n * Extracts event handlers from a given object.\n * A prop is considered an event handler if it is a function and its name starts with `on`.\n *\n * @param object An object to extract event handlers from.\n * @param excludeKeys An array of keys to exclude from the returned object.\n */\nexport function extractEventHandlers(object, excludeKeys = []) {\n if (object === undefined) {\n return {};\n }\n const result = {};\n Object.keys(object).filter(prop => prop.match(/^on[A-Z]/) && typeof object[prop] === 'function' && !excludeKeys.includes(prop)).forEach(prop => {\n result[prop] = object[prop];\n });\n return result;\n}","/**\n * If `componentProps` is a function, calls it with the provided `ownerState`.\n * Otherwise, just returns `componentProps`.\n */\nexport function resolveComponentProps(componentProps, ownerState, slotState) {\n if (typeof componentProps === 'function') {\n return componentProps(ownerState, slotState);\n }\n return componentProps;\n}","/**\n * Removes event handlers from the given object.\n * A field is considered an event handler if it is a function with a name beginning with `on`.\n *\n * @param object Object to remove event handlers from.\n * @returns Object with event handlers removed.\n */\nexport function omitEventHandlers(object) {\n if (object === undefined) {\n return {};\n }\n const result = {};\n Object.keys(object).filter(prop => !(prop.match(/^on[A-Z]/) && typeof object[prop] === 'function')).forEach(prop => {\n result[prop] = object[prop];\n });\n return result;\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport clsx from 'clsx';\nimport { extractEventHandlers } from './extractEventHandlers';\nimport { omitEventHandlers } from './omitEventHandlers';\n/**\n * Merges the slot component internal props (usually coming from a hook)\n * with the externally provided ones.\n *\n * The merge order is (the latter overrides the former):\n * 1. The internal props (specified as a getter function to work with get*Props hook result)\n * 2. Additional props (specified internally on a Base UI component)\n * 3. External props specified on the owner component. These should only be used on a root slot.\n * 4. External props specified in the `slotProps.*` prop.\n * 5. The `className` prop - combined from all the above.\n * @param parameters\n * @returns\n */\nexport function mergeSlotProps(parameters) {\n const {\n getSlotProps,\n additionalProps,\n externalSlotProps,\n externalForwardedProps,\n className\n } = parameters;\n if (!getSlotProps) {\n // The simpler case - getSlotProps is not defined, so no internal event handlers are defined,\n // so we can simply merge all the props without having to worry about extracting event handlers.\n const joinedClasses = clsx(additionalProps == null ? void 0 : additionalProps.className, className, externalForwardedProps == null ? void 0 : externalForwardedProps.className, externalSlotProps == null ? void 0 : externalSlotProps.className);\n const mergedStyle = _extends({}, additionalProps == null ? void 0 : additionalProps.style, externalForwardedProps == null ? void 0 : externalForwardedProps.style, externalSlotProps == null ? void 0 : externalSlotProps.style);\n const props = _extends({}, additionalProps, externalForwardedProps, externalSlotProps);\n if (joinedClasses.length > 0) {\n props.className = joinedClasses;\n }\n if (Object.keys(mergedStyle).length > 0) {\n props.style = mergedStyle;\n }\n return {\n props,\n internalRef: undefined\n };\n }\n\n // In this case, getSlotProps is responsible for calling the external event handlers.\n // We don't need to include them in the merged props because of this.\n\n const eventHandlers = extractEventHandlers(_extends({}, externalForwardedProps, externalSlotProps));\n const componentsPropsWithoutEventHandlers = omitEventHandlers(externalSlotProps);\n const otherPropsWithoutEventHandlers = omitEventHandlers(externalForwardedProps);\n const internalSlotProps = getSlotProps(eventHandlers);\n\n // The order of classes is important here.\n // Emotion (that we use in libraries consuming Base UI) depends on this order\n // to properly override style. It requires the most important classes to be last\n // (see https://github.com/mui/material-ui/pull/33205) for the related discussion.\n const joinedClasses = clsx(internalSlotProps == null ? void 0 : internalSlotProps.className, additionalProps == null ? void 0 : additionalProps.className, className, externalForwardedProps == null ? void 0 : externalForwardedProps.className, externalSlotProps == null ? void 0 : externalSlotProps.className);\n const mergedStyle = _extends({}, internalSlotProps == null ? void 0 : internalSlotProps.style, additionalProps == null ? void 0 : additionalProps.style, externalForwardedProps == null ? void 0 : externalForwardedProps.style, externalSlotProps == null ? void 0 : externalSlotProps.style);\n const props = _extends({}, internalSlotProps, additionalProps, otherPropsWithoutEventHandlers, componentsPropsWithoutEventHandlers);\n if (joinedClasses.length > 0) {\n props.className = joinedClasses;\n }\n if (Object.keys(mergedStyle).length > 0) {\n props.style = mergedStyle;\n }\n return {\n props,\n internalRef: internalSlotProps.ref\n };\n}","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"elementType\", \"externalSlotProps\", \"ownerState\", \"skipResolvingSlotProps\"];\nimport { unstable_useForkRef as useForkRef } from '@mui/utils';\nimport { appendOwnerState } from './appendOwnerState';\nimport { mergeSlotProps } from './mergeSlotProps';\nimport { resolveComponentProps } from './resolveComponentProps';\n/**\n * @ignore - do not document.\n * Builds the props to be passed into the slot of an unstyled component.\n * It merges the internal props of the component with the ones supplied by the user, allowing to customize the behavior.\n * If the slot component is not a host component, it also merges in the `ownerState`.\n *\n * @param parameters.getSlotProps - A function that returns the props to be passed to the slot component.\n */\nexport function useSlotProps(parameters) {\n var _parameters$additiona;\n const {\n elementType,\n externalSlotProps,\n ownerState,\n skipResolvingSlotProps = false\n } = parameters,\n rest = _objectWithoutPropertiesLoose(parameters, _excluded);\n const resolvedComponentsProps = skipResolvingSlotProps ? {} : resolveComponentProps(externalSlotProps, ownerState);\n const {\n props: mergedProps,\n internalRef\n } = mergeSlotProps(_extends({}, rest, {\n externalSlotProps: resolvedComponentsProps\n }));\n const ref = useForkRef(internalRef, resolvedComponentsProps == null ? void 0 : resolvedComponentsProps.ref, (_parameters$additiona = parameters.additionalProps) == null ? void 0 : _parameters$additiona.ref);\n const props = appendOwnerState(elementType, _extends({}, mergedProps, {\n ref\n }), ownerState);\n return props;\n}","import { globalStateClasses } from '@mui/utils/generateUtilityClass';\nconst GLOBAL_CLASS_PREFIX = 'base';\nfunction buildStateClass(state) {\n return `${GLOBAL_CLASS_PREFIX}--${state}`;\n}\nfunction buildSlotClass(componentName, slot) {\n return `${GLOBAL_CLASS_PREFIX}-${componentName}-${slot}`;\n}\nexport function generateUtilityClass(componentName, slot) {\n const globalStateClass = globalStateClasses[slot];\n return globalStateClass ? buildStateClass(globalStateClass) : buildSlotClass(componentName, slot);\n}\nexport function isGlobalState(slot) {\n return globalStateClasses[slot] !== undefined;\n}","import { generateUtilityClass } from '../generateUtilityClass';\nexport function generateUtilityClasses(componentName, slots) {\n const result = {};\n slots.forEach(slot => {\n result[slot] = generateUtilityClass(componentName, slot);\n });\n return result;\n}","'use client';\n\nimport * as React from 'react';\nimport * as ReactDOM from 'react-dom';\nimport PropTypes from 'prop-types';\nimport { exactProp, HTMLElementType, unstable_useEnhancedEffect as useEnhancedEffect, unstable_useForkRef as useForkRef, unstable_setRef as setRef } from '@mui/utils';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nfunction getContainer(container) {\n return typeof container === 'function' ? container() : container;\n}\n\n/**\n * Portals provide a first-class way to render children into a DOM node\n * that exists outside the DOM hierarchy of the parent component.\n *\n * Demos:\n *\n * - [Portal](https://mui.com/base-ui/react-portal/)\n *\n * API:\n *\n * - [Portal API](https://mui.com/base-ui/react-portal/components-api/#portal)\n */\nconst Portal = /*#__PURE__*/React.forwardRef(function Portal(props, forwardedRef) {\n const {\n children,\n container,\n disablePortal = false\n } = props;\n const [mountNode, setMountNode] = React.useState(null);\n // @ts-expect-error TODO upstream fix\n const handleRef = useForkRef( /*#__PURE__*/React.isValidElement(children) ? children.ref : null, forwardedRef);\n useEnhancedEffect(() => {\n if (!disablePortal) {\n setMountNode(getContainer(container) || document.body);\n }\n }, [container, disablePortal]);\n useEnhancedEffect(() => {\n if (mountNode && !disablePortal) {\n setRef(forwardedRef, mountNode);\n return () => {\n setRef(forwardedRef, null);\n };\n }\n return undefined;\n }, [forwardedRef, mountNode, disablePortal]);\n if (disablePortal) {\n if ( /*#__PURE__*/React.isValidElement(children)) {\n const newProps = {\n ref: handleRef\n };\n return /*#__PURE__*/React.cloneElement(children, newProps);\n }\n return /*#__PURE__*/_jsx(React.Fragment, {\n children: children\n });\n }\n return /*#__PURE__*/_jsx(React.Fragment, {\n children: mountNode ? /*#__PURE__*/ReactDOM.createPortal(children, mountNode) : mountNode\n });\n});\nprocess.env.NODE_ENV !== \"production\" ? Portal.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * The children to render into the `container`.\n */\n children: PropTypes.node,\n /**\n * An HTML element or function that returns one.\n * The `container` will have the portal children appended to it.\n *\n * You can also provide a callback, which is called in a React layout effect.\n * This lets you set the container from a ref, and also makes server-side rendering possible.\n *\n * By default, it uses the body of the top-level document object,\n * so it's simply `document.body` most of the time.\n */\n container: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.func]),\n /**\n * The `children` will be under the DOM hierarchy of the parent component.\n * @default false\n */\n disablePortal: PropTypes.bool\n} : void 0;\nif (process.env.NODE_ENV !== 'production') {\n // eslint-disable-next-line\n Portal['propTypes' + ''] = exactProp(Portal.propTypes);\n}\nexport { Portal };","export var top = 'top';\nexport var bottom = 'bottom';\nexport var right = 'right';\nexport var left = 'left';\nexport var auto = 'auto';\nexport var basePlacements = [top, bottom, right, left];\nexport var start = 'start';\nexport var end = 'end';\nexport var clippingParents = 'clippingParents';\nexport var viewport = 'viewport';\nexport var popper = 'popper';\nexport var reference = 'reference';\nexport var variationPlacements = /*#__PURE__*/basePlacements.reduce(function (acc, placement) {\n return acc.concat([placement + \"-\" + start, placement + \"-\" + end]);\n}, []);\nexport var placements = /*#__PURE__*/[].concat(basePlacements, [auto]).reduce(function (acc, placement) {\n return acc.concat([placement, placement + \"-\" + start, placement + \"-\" + end]);\n}, []); // modifiers that need to read the DOM\n\nexport var beforeRead = 'beforeRead';\nexport var read = 'read';\nexport var afterRead = 'afterRead'; // pure-logic modifiers\n\nexport var beforeMain = 'beforeMain';\nexport var main = 'main';\nexport var afterMain = 'afterMain'; // modifier with the purpose to write to the DOM (or write into a framework state)\n\nexport var beforeWrite = 'beforeWrite';\nexport var write = 'write';\nexport var afterWrite = 'afterWrite';\nexport var modifierPhases = [beforeRead, read, afterRead, beforeMain, main, afterMain, beforeWrite, write, afterWrite];","export default function getNodeName(element) {\n return element ? (element.nodeName || '').toLowerCase() : null;\n}","export default function getWindow(node) {\n if (node == null) {\n return window;\n }\n\n if (node.toString() !== '[object Window]') {\n var ownerDocument = node.ownerDocument;\n return ownerDocument ? ownerDocument.defaultView || window : window;\n }\n\n return node;\n}","import getWindow from \"./getWindow.js\";\n\nfunction isElement(node) {\n var OwnElement = getWindow(node).Element;\n return node instanceof OwnElement || node instanceof Element;\n}\n\nfunction isHTMLElement(node) {\n var OwnElement = getWindow(node).HTMLElement;\n return node instanceof OwnElement || node instanceof HTMLElement;\n}\n\nfunction isShadowRoot(node) {\n // IE 11 has no ShadowRoot\n if (typeof ShadowRoot === 'undefined') {\n return false;\n }\n\n var OwnElement = getWindow(node).ShadowRoot;\n return node instanceof OwnElement || node instanceof ShadowRoot;\n}\n\nexport { isElement, isHTMLElement, isShadowRoot };","import getNodeName from \"../dom-utils/getNodeName.js\";\nimport { isHTMLElement } from \"../dom-utils/instanceOf.js\"; // This modifier takes the styles prepared by the `computeStyles` modifier\n// and applies them to the HTMLElements such as popper and arrow\n\nfunction applyStyles(_ref) {\n var state = _ref.state;\n Object.keys(state.elements).forEach(function (name) {\n var style = state.styles[name] || {};\n var attributes = state.attributes[name] || {};\n var element = state.elements[name]; // arrow is optional + virtual elements\n\n if (!isHTMLElement(element) || !getNodeName(element)) {\n return;\n } // Flow doesn't support to extend this property, but it's the most\n // effective way to apply styles to an HTMLElement\n // $FlowFixMe[cannot-write]\n\n\n Object.assign(element.style, style);\n Object.keys(attributes).forEach(function (name) {\n var value = attributes[name];\n\n if (value === false) {\n element.removeAttribute(name);\n } else {\n element.setAttribute(name, value === true ? '' : value);\n }\n });\n });\n}\n\nfunction effect(_ref2) {\n var state = _ref2.state;\n var initialStyles = {\n popper: {\n position: state.options.strategy,\n left: '0',\n top: '0',\n margin: '0'\n },\n arrow: {\n position: 'absolute'\n },\n reference: {}\n };\n Object.assign(state.elements.popper.style, initialStyles.popper);\n state.styles = initialStyles;\n\n if (state.elements.arrow) {\n Object.assign(state.elements.arrow.style, initialStyles.arrow);\n }\n\n return function () {\n Object.keys(state.elements).forEach(function (name) {\n var element = state.elements[name];\n var attributes = state.attributes[name] || {};\n var styleProperties = Object.keys(state.styles.hasOwnProperty(name) ? state.styles[name] : initialStyles[name]); // Set all values to an empty string to unset them\n\n var style = styleProperties.reduce(function (style, property) {\n style[property] = '';\n return style;\n }, {}); // arrow is optional + virtual elements\n\n if (!isHTMLElement(element) || !getNodeName(element)) {\n return;\n }\n\n Object.assign(element.style, style);\n Object.keys(attributes).forEach(function (attribute) {\n element.removeAttribute(attribute);\n });\n });\n };\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'applyStyles',\n enabled: true,\n phase: 'write',\n fn: applyStyles,\n effect: effect,\n requires: ['computeStyles']\n};","import { auto } from \"../enums.js\";\nexport default function getBasePlacement(placement) {\n return placement.split('-')[0];\n}","export var max = Math.max;\nexport var min = Math.min;\nexport var round = Math.round;","export default function getUAString() {\n var uaData = navigator.userAgentData;\n\n if (uaData != null && uaData.brands && Array.isArray(uaData.brands)) {\n return uaData.brands.map(function (item) {\n return item.brand + \"/\" + item.version;\n }).join(' ');\n }\n\n return navigator.userAgent;\n}","import getUAString from \"../utils/userAgent.js\";\nexport default function isLayoutViewport() {\n return !/^((?!chrome|android).)*safari/i.test(getUAString());\n}","import { isElement, isHTMLElement } from \"./instanceOf.js\";\nimport { round } from \"../utils/math.js\";\nimport getWindow from \"./getWindow.js\";\nimport isLayoutViewport from \"./isLayoutViewport.js\";\nexport default function getBoundingClientRect(element, includeScale, isFixedStrategy) {\n if (includeScale === void 0) {\n includeScale = false;\n }\n\n if (isFixedStrategy === void 0) {\n isFixedStrategy = false;\n }\n\n var clientRect = element.getBoundingClientRect();\n var scaleX = 1;\n var scaleY = 1;\n\n if (includeScale && isHTMLElement(element)) {\n scaleX = element.offsetWidth > 0 ? round(clientRect.width) / element.offsetWidth || 1 : 1;\n scaleY = element.offsetHeight > 0 ? round(clientRect.height) / element.offsetHeight || 1 : 1;\n }\n\n var _ref = isElement(element) ? getWindow(element) : window,\n visualViewport = _ref.visualViewport;\n\n var addVisualOffsets = !isLayoutViewport() && isFixedStrategy;\n var x = (clientRect.left + (addVisualOffsets && visualViewport ? visualViewport.offsetLeft : 0)) / scaleX;\n var y = (clientRect.top + (addVisualOffsets && visualViewport ? visualViewport.offsetTop : 0)) / scaleY;\n var width = clientRect.width / scaleX;\n var height = clientRect.height / scaleY;\n return {\n width: width,\n height: height,\n top: y,\n right: x + width,\n bottom: y + height,\n left: x,\n x: x,\n y: y\n };\n}","import getBoundingClientRect from \"./getBoundingClientRect.js\"; // Returns the layout rect of an element relative to its offsetParent. Layout\n// means it doesn't take into account transforms.\n\nexport default function getLayoutRect(element) {\n var clientRect = getBoundingClientRect(element); // Use the clientRect sizes if it's not been transformed.\n // Fixes https://github.com/popperjs/popper-core/issues/1223\n\n var width = element.offsetWidth;\n var height = element.offsetHeight;\n\n if (Math.abs(clientRect.width - width) <= 1) {\n width = clientRect.width;\n }\n\n if (Math.abs(clientRect.height - height) <= 1) {\n height = clientRect.height;\n }\n\n return {\n x: element.offsetLeft,\n y: element.offsetTop,\n width: width,\n height: height\n };\n}","import { isShadowRoot } from \"./instanceOf.js\";\nexport default function contains(parent, child) {\n var rootNode = child.getRootNode && child.getRootNode(); // First, attempt with faster native method\n\n if (parent.contains(child)) {\n return true;\n } // then fallback to custom implementation with Shadow DOM support\n else if (rootNode && isShadowRoot(rootNode)) {\n var next = child;\n\n do {\n if (next && parent.isSameNode(next)) {\n return true;\n } // $FlowFixMe[prop-missing]: need a better way to handle this...\n\n\n next = next.parentNode || next.host;\n } while (next);\n } // Give up, the result is false\n\n\n return false;\n}","import getWindow from \"./getWindow.js\";\nexport default function getComputedStyle(element) {\n return getWindow(element).getComputedStyle(element);\n}","import getNodeName from \"./getNodeName.js\";\nexport default function isTableElement(element) {\n return ['table', 'td', 'th'].indexOf(getNodeName(element)) >= 0;\n}","import { isElement } from \"./instanceOf.js\";\nexport default function getDocumentElement(element) {\n // $FlowFixMe[incompatible-return]: assume body is always available\n return ((isElement(element) ? element.ownerDocument : // $FlowFixMe[prop-missing]\n element.document) || window.document).documentElement;\n}","import getNodeName from \"./getNodeName.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport { isShadowRoot } from \"./instanceOf.js\";\nexport default function getParentNode(element) {\n if (getNodeName(element) === 'html') {\n return element;\n }\n\n return (// this is a quicker (but less type safe) way to save quite some bytes from the bundle\n // $FlowFixMe[incompatible-return]\n // $FlowFixMe[prop-missing]\n element.assignedSlot || // step into the shadow DOM of the parent of a slotted node\n element.parentNode || ( // DOM Element detected\n isShadowRoot(element) ? element.host : null) || // ShadowRoot detected\n // $FlowFixMe[incompatible-call]: HTMLElement is a Node\n getDocumentElement(element) // fallback\n\n );\n}","import getWindow from \"./getWindow.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport getComputedStyle from \"./getComputedStyle.js\";\nimport { isHTMLElement, isShadowRoot } from \"./instanceOf.js\";\nimport isTableElement from \"./isTableElement.js\";\nimport getParentNode from \"./getParentNode.js\";\nimport getUAString from \"../utils/userAgent.js\";\n\nfunction getTrueOffsetParent(element) {\n if (!isHTMLElement(element) || // https://github.com/popperjs/popper-core/issues/837\n getComputedStyle(element).position === 'fixed') {\n return null;\n }\n\n return element.offsetParent;\n} // `.offsetParent` reports `null` for fixed elements, while absolute elements\n// return the containing block\n\n\nfunction getContainingBlock(element) {\n var isFirefox = /firefox/i.test(getUAString());\n var isIE = /Trident/i.test(getUAString());\n\n if (isIE && isHTMLElement(element)) {\n // In IE 9, 10 and 11 fixed elements containing block is always established by the viewport\n var elementCss = getComputedStyle(element);\n\n if (elementCss.position === 'fixed') {\n return null;\n }\n }\n\n var currentNode = getParentNode(element);\n\n if (isShadowRoot(currentNode)) {\n currentNode = currentNode.host;\n }\n\n while (isHTMLElement(currentNode) && ['html', 'body'].indexOf(getNodeName(currentNode)) < 0) {\n var css = getComputedStyle(currentNode); // This is non-exhaustive but covers the most common CSS properties that\n // create a containing block.\n // https://developer.mozilla.org/en-US/docs/Web/CSS/Containing_block#identifying_the_containing_block\n\n if (css.transform !== 'none' || css.perspective !== 'none' || css.contain === 'paint' || ['transform', 'perspective'].indexOf(css.willChange) !== -1 || isFirefox && css.willChange === 'filter' || isFirefox && css.filter && css.filter !== 'none') {\n return currentNode;\n } else {\n currentNode = currentNode.parentNode;\n }\n }\n\n return null;\n} // Gets the closest ancestor positioned element. Handles some edge cases,\n// such as table ancestors and cross browser bugs.\n\n\nexport default function getOffsetParent(element) {\n var window = getWindow(element);\n var offsetParent = getTrueOffsetParent(element);\n\n while (offsetParent && isTableElement(offsetParent) && getComputedStyle(offsetParent).position === 'static') {\n offsetParent = getTrueOffsetParent(offsetParent);\n }\n\n if (offsetParent && (getNodeName(offsetParent) === 'html' || getNodeName(offsetParent) === 'body' && getComputedStyle(offsetParent).position === 'static')) {\n return window;\n }\n\n return offsetParent || getContainingBlock(element) || window;\n}","export default function getMainAxisFromPlacement(placement) {\n return ['top', 'bottom'].indexOf(placement) >= 0 ? 'x' : 'y';\n}","import { max as mathMax, min as mathMin } from \"./math.js\";\nexport function within(min, value, max) {\n return mathMax(min, mathMin(value, max));\n}\nexport function withinMaxClamp(min, value, max) {\n var v = within(min, value, max);\n return v > max ? max : v;\n}","export default function getFreshSideObject() {\n return {\n top: 0,\n right: 0,\n bottom: 0,\n left: 0\n };\n}","import getFreshSideObject from \"./getFreshSideObject.js\";\nexport default function mergePaddingObject(paddingObject) {\n return Object.assign({}, getFreshSideObject(), paddingObject);\n}","export default function expandToHashMap(value, keys) {\n return keys.reduce(function (hashMap, key) {\n hashMap[key] = value;\n return hashMap;\n }, {});\n}","import getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getLayoutRect from \"../dom-utils/getLayoutRect.js\";\nimport contains from \"../dom-utils/contains.js\";\nimport getOffsetParent from \"../dom-utils/getOffsetParent.js\";\nimport getMainAxisFromPlacement from \"../utils/getMainAxisFromPlacement.js\";\nimport { within } from \"../utils/within.js\";\nimport mergePaddingObject from \"../utils/mergePaddingObject.js\";\nimport expandToHashMap from \"../utils/expandToHashMap.js\";\nimport { left, right, basePlacements, top, bottom } from \"../enums.js\"; // eslint-disable-next-line import/no-unused-modules\n\nvar toPaddingObject = function toPaddingObject(padding, state) {\n padding = typeof padding === 'function' ? padding(Object.assign({}, state.rects, {\n placement: state.placement\n })) : padding;\n return mergePaddingObject(typeof padding !== 'number' ? padding : expandToHashMap(padding, basePlacements));\n};\n\nfunction arrow(_ref) {\n var _state$modifiersData$;\n\n var state = _ref.state,\n name = _ref.name,\n options = _ref.options;\n var arrowElement = state.elements.arrow;\n var popperOffsets = state.modifiersData.popperOffsets;\n var basePlacement = getBasePlacement(state.placement);\n var axis = getMainAxisFromPlacement(basePlacement);\n var isVertical = [left, right].indexOf(basePlacement) >= 0;\n var len = isVertical ? 'height' : 'width';\n\n if (!arrowElement || !popperOffsets) {\n return;\n }\n\n var paddingObject = toPaddingObject(options.padding, state);\n var arrowRect = getLayoutRect(arrowElement);\n var minProp = axis === 'y' ? top : left;\n var maxProp = axis === 'y' ? bottom : right;\n var endDiff = state.rects.reference[len] + state.rects.reference[axis] - popperOffsets[axis] - state.rects.popper[len];\n var startDiff = popperOffsets[axis] - state.rects.reference[axis];\n var arrowOffsetParent = getOffsetParent(arrowElement);\n var clientSize = arrowOffsetParent ? axis === 'y' ? arrowOffsetParent.clientHeight || 0 : arrowOffsetParent.clientWidth || 0 : 0;\n var centerToReference = endDiff / 2 - startDiff / 2; // Make sure the arrow doesn't overflow the popper if the center point is\n // outside of the popper bounds\n\n var min = paddingObject[minProp];\n var max = clientSize - arrowRect[len] - paddingObject[maxProp];\n var center = clientSize / 2 - arrowRect[len] / 2 + centerToReference;\n var offset = within(min, center, max); // Prevents breaking syntax highlighting...\n\n var axisProp = axis;\n state.modifiersData[name] = (_state$modifiersData$ = {}, _state$modifiersData$[axisProp] = offset, _state$modifiersData$.centerOffset = offset - center, _state$modifiersData$);\n}\n\nfunction effect(_ref2) {\n var state = _ref2.state,\n options = _ref2.options;\n var _options$element = options.element,\n arrowElement = _options$element === void 0 ? '[data-popper-arrow]' : _options$element;\n\n if (arrowElement == null) {\n return;\n } // CSS selector\n\n\n if (typeof arrowElement === 'string') {\n arrowElement = state.elements.popper.querySelector(arrowElement);\n\n if (!arrowElement) {\n return;\n }\n }\n\n if (!contains(state.elements.popper, arrowElement)) {\n return;\n }\n\n state.elements.arrow = arrowElement;\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'arrow',\n enabled: true,\n phase: 'main',\n fn: arrow,\n effect: effect,\n requires: ['popperOffsets'],\n requiresIfExists: ['preventOverflow']\n};","export default function getVariation(placement) {\n return placement.split('-')[1];\n}","import { top, left, right, bottom, end } from \"../enums.js\";\nimport getOffsetParent from \"../dom-utils/getOffsetParent.js\";\nimport getWindow from \"../dom-utils/getWindow.js\";\nimport getDocumentElement from \"../dom-utils/getDocumentElement.js\";\nimport getComputedStyle from \"../dom-utils/getComputedStyle.js\";\nimport getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getVariation from \"../utils/getVariation.js\";\nimport { round } from \"../utils/math.js\"; // eslint-disable-next-line import/no-unused-modules\n\nvar unsetSides = {\n top: 'auto',\n right: 'auto',\n bottom: 'auto',\n left: 'auto'\n}; // Round the offsets to the nearest suitable subpixel based on the DPR.\n// Zooming can change the DPR, but it seems to report a value that will\n// cleanly divide the values into the appropriate subpixels.\n\nfunction roundOffsetsByDPR(_ref, win) {\n var x = _ref.x,\n y = _ref.y;\n var dpr = win.devicePixelRatio || 1;\n return {\n x: round(x * dpr) / dpr || 0,\n y: round(y * dpr) / dpr || 0\n };\n}\n\nexport function mapToStyles(_ref2) {\n var _Object$assign2;\n\n var popper = _ref2.popper,\n popperRect = _ref2.popperRect,\n placement = _ref2.placement,\n variation = _ref2.variation,\n offsets = _ref2.offsets,\n position = _ref2.position,\n gpuAcceleration = _ref2.gpuAcceleration,\n adaptive = _ref2.adaptive,\n roundOffsets = _ref2.roundOffsets,\n isFixed = _ref2.isFixed;\n var _offsets$x = offsets.x,\n x = _offsets$x === void 0 ? 0 : _offsets$x,\n _offsets$y = offsets.y,\n y = _offsets$y === void 0 ? 0 : _offsets$y;\n\n var _ref3 = typeof roundOffsets === 'function' ? roundOffsets({\n x: x,\n y: y\n }) : {\n x: x,\n y: y\n };\n\n x = _ref3.x;\n y = _ref3.y;\n var hasX = offsets.hasOwnProperty('x');\n var hasY = offsets.hasOwnProperty('y');\n var sideX = left;\n var sideY = top;\n var win = window;\n\n if (adaptive) {\n var offsetParent = getOffsetParent(popper);\n var heightProp = 'clientHeight';\n var widthProp = 'clientWidth';\n\n if (offsetParent === getWindow(popper)) {\n offsetParent = getDocumentElement(popper);\n\n if (getComputedStyle(offsetParent).position !== 'static' && position === 'absolute') {\n heightProp = 'scrollHeight';\n widthProp = 'scrollWidth';\n }\n } // $FlowFixMe[incompatible-cast]: force type refinement, we compare offsetParent with window above, but Flow doesn't detect it\n\n\n offsetParent = offsetParent;\n\n if (placement === top || (placement === left || placement === right) && variation === end) {\n sideY = bottom;\n var offsetY = isFixed && offsetParent === win && win.visualViewport ? win.visualViewport.height : // $FlowFixMe[prop-missing]\n offsetParent[heightProp];\n y -= offsetY - popperRect.height;\n y *= gpuAcceleration ? 1 : -1;\n }\n\n if (placement === left || (placement === top || placement === bottom) && variation === end) {\n sideX = right;\n var offsetX = isFixed && offsetParent === win && win.visualViewport ? win.visualViewport.width : // $FlowFixMe[prop-missing]\n offsetParent[widthProp];\n x -= offsetX - popperRect.width;\n x *= gpuAcceleration ? 1 : -1;\n }\n }\n\n var commonStyles = Object.assign({\n position: position\n }, adaptive && unsetSides);\n\n var _ref4 = roundOffsets === true ? roundOffsetsByDPR({\n x: x,\n y: y\n }, getWindow(popper)) : {\n x: x,\n y: y\n };\n\n x = _ref4.x;\n y = _ref4.y;\n\n if (gpuAcceleration) {\n var _Object$assign;\n\n return Object.assign({}, commonStyles, (_Object$assign = {}, _Object$assign[sideY] = hasY ? '0' : '', _Object$assign[sideX] = hasX ? '0' : '', _Object$assign.transform = (win.devicePixelRatio || 1) <= 1 ? \"translate(\" + x + \"px, \" + y + \"px)\" : \"translate3d(\" + x + \"px, \" + y + \"px, 0)\", _Object$assign));\n }\n\n return Object.assign({}, commonStyles, (_Object$assign2 = {}, _Object$assign2[sideY] = hasY ? y + \"px\" : '', _Object$assign2[sideX] = hasX ? x + \"px\" : '', _Object$assign2.transform = '', _Object$assign2));\n}\n\nfunction computeStyles(_ref5) {\n var state = _ref5.state,\n options = _ref5.options;\n var _options$gpuAccelerat = options.gpuAcceleration,\n gpuAcceleration = _options$gpuAccelerat === void 0 ? true : _options$gpuAccelerat,\n _options$adaptive = options.adaptive,\n adaptive = _options$adaptive === void 0 ? true : _options$adaptive,\n _options$roundOffsets = options.roundOffsets,\n roundOffsets = _options$roundOffsets === void 0 ? true : _options$roundOffsets;\n var commonStyles = {\n placement: getBasePlacement(state.placement),\n variation: getVariation(state.placement),\n popper: state.elements.popper,\n popperRect: state.rects.popper,\n gpuAcceleration: gpuAcceleration,\n isFixed: state.options.strategy === 'fixed'\n };\n\n if (state.modifiersData.popperOffsets != null) {\n state.styles.popper = Object.assign({}, state.styles.popper, mapToStyles(Object.assign({}, commonStyles, {\n offsets: state.modifiersData.popperOffsets,\n position: state.options.strategy,\n adaptive: adaptive,\n roundOffsets: roundOffsets\n })));\n }\n\n if (state.modifiersData.arrow != null) {\n state.styles.arrow = Object.assign({}, state.styles.arrow, mapToStyles(Object.assign({}, commonStyles, {\n offsets: state.modifiersData.arrow,\n position: 'absolute',\n adaptive: false,\n roundOffsets: roundOffsets\n })));\n }\n\n state.attributes.popper = Object.assign({}, state.attributes.popper, {\n 'data-popper-placement': state.placement\n });\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'computeStyles',\n enabled: true,\n phase: 'beforeWrite',\n fn: computeStyles,\n data: {}\n};","import getWindow from \"../dom-utils/getWindow.js\"; // eslint-disable-next-line import/no-unused-modules\n\nvar passive = {\n passive: true\n};\n\nfunction effect(_ref) {\n var state = _ref.state,\n instance = _ref.instance,\n options = _ref.options;\n var _options$scroll = options.scroll,\n scroll = _options$scroll === void 0 ? true : _options$scroll,\n _options$resize = options.resize,\n resize = _options$resize === void 0 ? true : _options$resize;\n var window = getWindow(state.elements.popper);\n var scrollParents = [].concat(state.scrollParents.reference, state.scrollParents.popper);\n\n if (scroll) {\n scrollParents.forEach(function (scrollParent) {\n scrollParent.addEventListener('scroll', instance.update, passive);\n });\n }\n\n if (resize) {\n window.addEventListener('resize', instance.update, passive);\n }\n\n return function () {\n if (scroll) {\n scrollParents.forEach(function (scrollParent) {\n scrollParent.removeEventListener('scroll', instance.update, passive);\n });\n }\n\n if (resize) {\n window.removeEventListener('resize', instance.update, passive);\n }\n };\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'eventListeners',\n enabled: true,\n phase: 'write',\n fn: function fn() {},\n effect: effect,\n data: {}\n};","var hash = {\n left: 'right',\n right: 'left',\n bottom: 'top',\n top: 'bottom'\n};\nexport default function getOppositePlacement(placement) {\n return placement.replace(/left|right|bottom|top/g, function (matched) {\n return hash[matched];\n });\n}","var hash = {\n start: 'end',\n end: 'start'\n};\nexport default function getOppositeVariationPlacement(placement) {\n return placement.replace(/start|end/g, function (matched) {\n return hash[matched];\n });\n}","import getWindow from \"./getWindow.js\";\nexport default function getWindowScroll(node) {\n var win = getWindow(node);\n var scrollLeft = win.pageXOffset;\n var scrollTop = win.pageYOffset;\n return {\n scrollLeft: scrollLeft,\n scrollTop: scrollTop\n };\n}","import getBoundingClientRect from \"./getBoundingClientRect.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport getWindowScroll from \"./getWindowScroll.js\";\nexport default function getWindowScrollBarX(element) {\n // If has a CSS width greater than the viewport, then this will be\n // incorrect for RTL.\n // Popper 1 is broken in this case and never had a bug report so let's assume\n // it's not an issue. I don't think anyone ever specifies width on \n // anyway.\n // Browsers where the left scrollbar doesn't cause an issue report `0` for\n // this (e.g. Edge 2019, IE11, Safari)\n return getBoundingClientRect(getDocumentElement(element)).left + getWindowScroll(element).scrollLeft;\n}","import getWindow from \"./getWindow.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport getWindowScrollBarX from \"./getWindowScrollBarX.js\";\nimport isLayoutViewport from \"./isLayoutViewport.js\";\nexport default function getViewportRect(element, strategy) {\n var win = getWindow(element);\n var html = getDocumentElement(element);\n var visualViewport = win.visualViewport;\n var width = html.clientWidth;\n var height = html.clientHeight;\n var x = 0;\n var y = 0;\n\n if (visualViewport) {\n width = visualViewport.width;\n height = visualViewport.height;\n var layoutViewport = isLayoutViewport();\n\n if (layoutViewport || !layoutViewport && strategy === 'fixed') {\n x = visualViewport.offsetLeft;\n y = visualViewport.offsetTop;\n }\n }\n\n return {\n width: width,\n height: height,\n x: x + getWindowScrollBarX(element),\n y: y\n };\n}","import getDocumentElement from \"./getDocumentElement.js\";\nimport getComputedStyle from \"./getComputedStyle.js\";\nimport getWindowScrollBarX from \"./getWindowScrollBarX.js\";\nimport getWindowScroll from \"./getWindowScroll.js\";\nimport { max } from \"../utils/math.js\"; // Gets the entire size of the scrollable document area, even extending outside\n// of the `` and `` rect bounds if horizontally scrollable\n\nexport default function getDocumentRect(element) {\n var _element$ownerDocumen;\n\n var html = getDocumentElement(element);\n var winScroll = getWindowScroll(element);\n var body = (_element$ownerDocumen = element.ownerDocument) == null ? void 0 : _element$ownerDocumen.body;\n var width = max(html.scrollWidth, html.clientWidth, body ? body.scrollWidth : 0, body ? body.clientWidth : 0);\n var height = max(html.scrollHeight, html.clientHeight, body ? body.scrollHeight : 0, body ? body.clientHeight : 0);\n var x = -winScroll.scrollLeft + getWindowScrollBarX(element);\n var y = -winScroll.scrollTop;\n\n if (getComputedStyle(body || html).direction === 'rtl') {\n x += max(html.clientWidth, body ? body.clientWidth : 0) - width;\n }\n\n return {\n width: width,\n height: height,\n x: x,\n y: y\n };\n}","import getComputedStyle from \"./getComputedStyle.js\";\nexport default function isScrollParent(element) {\n // Firefox wants us to check `-x` and `-y` variations as well\n var _getComputedStyle = getComputedStyle(element),\n overflow = _getComputedStyle.overflow,\n overflowX = _getComputedStyle.overflowX,\n overflowY = _getComputedStyle.overflowY;\n\n return /auto|scroll|overlay|hidden/.test(overflow + overflowY + overflowX);\n}","import getParentNode from \"./getParentNode.js\";\nimport isScrollParent from \"./isScrollParent.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport { isHTMLElement } from \"./instanceOf.js\";\nexport default function getScrollParent(node) {\n if (['html', 'body', '#document'].indexOf(getNodeName(node)) >= 0) {\n // $FlowFixMe[incompatible-return]: assume body is always available\n return node.ownerDocument.body;\n }\n\n if (isHTMLElement(node) && isScrollParent(node)) {\n return node;\n }\n\n return getScrollParent(getParentNode(node));\n}","import getScrollParent from \"./getScrollParent.js\";\nimport getParentNode from \"./getParentNode.js\";\nimport getWindow from \"./getWindow.js\";\nimport isScrollParent from \"./isScrollParent.js\";\n/*\ngiven a DOM element, return the list of all scroll parents, up the list of ancesors\nuntil we get to the top window object. This list is what we attach scroll listeners\nto, because if any of these parent elements scroll, we'll need to re-calculate the\nreference element's position.\n*/\n\nexport default function listScrollParents(element, list) {\n var _element$ownerDocumen;\n\n if (list === void 0) {\n list = [];\n }\n\n var scrollParent = getScrollParent(element);\n var isBody = scrollParent === ((_element$ownerDocumen = element.ownerDocument) == null ? void 0 : _element$ownerDocumen.body);\n var win = getWindow(scrollParent);\n var target = isBody ? [win].concat(win.visualViewport || [], isScrollParent(scrollParent) ? scrollParent : []) : scrollParent;\n var updatedList = list.concat(target);\n return isBody ? updatedList : // $FlowFixMe[incompatible-call]: isBody tells us target will be an HTMLElement here\n updatedList.concat(listScrollParents(getParentNode(target)));\n}","export default function rectToClientRect(rect) {\n return Object.assign({}, rect, {\n left: rect.x,\n top: rect.y,\n right: rect.x + rect.width,\n bottom: rect.y + rect.height\n });\n}","import { viewport } from \"../enums.js\";\nimport getViewportRect from \"./getViewportRect.js\";\nimport getDocumentRect from \"./getDocumentRect.js\";\nimport listScrollParents from \"./listScrollParents.js\";\nimport getOffsetParent from \"./getOffsetParent.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport getComputedStyle from \"./getComputedStyle.js\";\nimport { isElement, isHTMLElement } from \"./instanceOf.js\";\nimport getBoundingClientRect from \"./getBoundingClientRect.js\";\nimport getParentNode from \"./getParentNode.js\";\nimport contains from \"./contains.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport rectToClientRect from \"../utils/rectToClientRect.js\";\nimport { max, min } from \"../utils/math.js\";\n\nfunction getInnerBoundingClientRect(element, strategy) {\n var rect = getBoundingClientRect(element, false, strategy === 'fixed');\n rect.top = rect.top + element.clientTop;\n rect.left = rect.left + element.clientLeft;\n rect.bottom = rect.top + element.clientHeight;\n rect.right = rect.left + element.clientWidth;\n rect.width = element.clientWidth;\n rect.height = element.clientHeight;\n rect.x = rect.left;\n rect.y = rect.top;\n return rect;\n}\n\nfunction getClientRectFromMixedType(element, clippingParent, strategy) {\n return clippingParent === viewport ? rectToClientRect(getViewportRect(element, strategy)) : isElement(clippingParent) ? getInnerBoundingClientRect(clippingParent, strategy) : rectToClientRect(getDocumentRect(getDocumentElement(element)));\n} // A \"clipping parent\" is an overflowable container with the characteristic of\n// clipping (or hiding) overflowing elements with a position different from\n// `initial`\n\n\nfunction getClippingParents(element) {\n var clippingParents = listScrollParents(getParentNode(element));\n var canEscapeClipping = ['absolute', 'fixed'].indexOf(getComputedStyle(element).position) >= 0;\n var clipperElement = canEscapeClipping && isHTMLElement(element) ? getOffsetParent(element) : element;\n\n if (!isElement(clipperElement)) {\n return [];\n } // $FlowFixMe[incompatible-return]: https://github.com/facebook/flow/issues/1414\n\n\n return clippingParents.filter(function (clippingParent) {\n return isElement(clippingParent) && contains(clippingParent, clipperElement) && getNodeName(clippingParent) !== 'body';\n });\n} // Gets the maximum area that the element is visible in due to any number of\n// clipping parents\n\n\nexport default function getClippingRect(element, boundary, rootBoundary, strategy) {\n var mainClippingParents = boundary === 'clippingParents' ? getClippingParents(element) : [].concat(boundary);\n var clippingParents = [].concat(mainClippingParents, [rootBoundary]);\n var firstClippingParent = clippingParents[0];\n var clippingRect = clippingParents.reduce(function (accRect, clippingParent) {\n var rect = getClientRectFromMixedType(element, clippingParent, strategy);\n accRect.top = max(rect.top, accRect.top);\n accRect.right = min(rect.right, accRect.right);\n accRect.bottom = min(rect.bottom, accRect.bottom);\n accRect.left = max(rect.left, accRect.left);\n return accRect;\n }, getClientRectFromMixedType(element, firstClippingParent, strategy));\n clippingRect.width = clippingRect.right - clippingRect.left;\n clippingRect.height = clippingRect.bottom - clippingRect.top;\n clippingRect.x = clippingRect.left;\n clippingRect.y = clippingRect.top;\n return clippingRect;\n}","import getBasePlacement from \"./getBasePlacement.js\";\nimport getVariation from \"./getVariation.js\";\nimport getMainAxisFromPlacement from \"./getMainAxisFromPlacement.js\";\nimport { top, right, bottom, left, start, end } from \"../enums.js\";\nexport default function computeOffsets(_ref) {\n var reference = _ref.reference,\n element = _ref.element,\n placement = _ref.placement;\n var basePlacement = placement ? getBasePlacement(placement) : null;\n var variation = placement ? getVariation(placement) : null;\n var commonX = reference.x + reference.width / 2 - element.width / 2;\n var commonY = reference.y + reference.height / 2 - element.height / 2;\n var offsets;\n\n switch (basePlacement) {\n case top:\n offsets = {\n x: commonX,\n y: reference.y - element.height\n };\n break;\n\n case bottom:\n offsets = {\n x: commonX,\n y: reference.y + reference.height\n };\n break;\n\n case right:\n offsets = {\n x: reference.x + reference.width,\n y: commonY\n };\n break;\n\n case left:\n offsets = {\n x: reference.x - element.width,\n y: commonY\n };\n break;\n\n default:\n offsets = {\n x: reference.x,\n y: reference.y\n };\n }\n\n var mainAxis = basePlacement ? getMainAxisFromPlacement(basePlacement) : null;\n\n if (mainAxis != null) {\n var len = mainAxis === 'y' ? 'height' : 'width';\n\n switch (variation) {\n case start:\n offsets[mainAxis] = offsets[mainAxis] - (reference[len] / 2 - element[len] / 2);\n break;\n\n case end:\n offsets[mainAxis] = offsets[mainAxis] + (reference[len] / 2 - element[len] / 2);\n break;\n\n default:\n }\n }\n\n return offsets;\n}","import getClippingRect from \"../dom-utils/getClippingRect.js\";\nimport getDocumentElement from \"../dom-utils/getDocumentElement.js\";\nimport getBoundingClientRect from \"../dom-utils/getBoundingClientRect.js\";\nimport computeOffsets from \"./computeOffsets.js\";\nimport rectToClientRect from \"./rectToClientRect.js\";\nimport { clippingParents, reference, popper, bottom, top, right, basePlacements, viewport } from \"../enums.js\";\nimport { isElement } from \"../dom-utils/instanceOf.js\";\nimport mergePaddingObject from \"./mergePaddingObject.js\";\nimport expandToHashMap from \"./expandToHashMap.js\"; // eslint-disable-next-line import/no-unused-modules\n\nexport default function detectOverflow(state, options) {\n if (options === void 0) {\n options = {};\n }\n\n var _options = options,\n _options$placement = _options.placement,\n placement = _options$placement === void 0 ? state.placement : _options$placement,\n _options$strategy = _options.strategy,\n strategy = _options$strategy === void 0 ? state.strategy : _options$strategy,\n _options$boundary = _options.boundary,\n boundary = _options$boundary === void 0 ? clippingParents : _options$boundary,\n _options$rootBoundary = _options.rootBoundary,\n rootBoundary = _options$rootBoundary === void 0 ? viewport : _options$rootBoundary,\n _options$elementConte = _options.elementContext,\n elementContext = _options$elementConte === void 0 ? popper : _options$elementConte,\n _options$altBoundary = _options.altBoundary,\n altBoundary = _options$altBoundary === void 0 ? false : _options$altBoundary,\n _options$padding = _options.padding,\n padding = _options$padding === void 0 ? 0 : _options$padding;\n var paddingObject = mergePaddingObject(typeof padding !== 'number' ? padding : expandToHashMap(padding, basePlacements));\n var altContext = elementContext === popper ? reference : popper;\n var popperRect = state.rects.popper;\n var element = state.elements[altBoundary ? altContext : elementContext];\n var clippingClientRect = getClippingRect(isElement(element) ? element : element.contextElement || getDocumentElement(state.elements.popper), boundary, rootBoundary, strategy);\n var referenceClientRect = getBoundingClientRect(state.elements.reference);\n var popperOffsets = computeOffsets({\n reference: referenceClientRect,\n element: popperRect,\n strategy: 'absolute',\n placement: placement\n });\n var popperClientRect = rectToClientRect(Object.assign({}, popperRect, popperOffsets));\n var elementClientRect = elementContext === popper ? popperClientRect : referenceClientRect; // positive = overflowing the clipping rect\n // 0 or negative = within the clipping rect\n\n var overflowOffsets = {\n top: clippingClientRect.top - elementClientRect.top + paddingObject.top,\n bottom: elementClientRect.bottom - clippingClientRect.bottom + paddingObject.bottom,\n left: clippingClientRect.left - elementClientRect.left + paddingObject.left,\n right: elementClientRect.right - clippingClientRect.right + paddingObject.right\n };\n var offsetData = state.modifiersData.offset; // Offsets can be applied only to the popper element\n\n if (elementContext === popper && offsetData) {\n var offset = offsetData[placement];\n Object.keys(overflowOffsets).forEach(function (key) {\n var multiply = [right, bottom].indexOf(key) >= 0 ? 1 : -1;\n var axis = [top, bottom].indexOf(key) >= 0 ? 'y' : 'x';\n overflowOffsets[key] += offset[axis] * multiply;\n });\n }\n\n return overflowOffsets;\n}","import getVariation from \"./getVariation.js\";\nimport { variationPlacements, basePlacements, placements as allPlacements } from \"../enums.js\";\nimport detectOverflow from \"./detectOverflow.js\";\nimport getBasePlacement from \"./getBasePlacement.js\";\nexport default function computeAutoPlacement(state, options) {\n if (options === void 0) {\n options = {};\n }\n\n var _options = options,\n placement = _options.placement,\n boundary = _options.boundary,\n rootBoundary = _options.rootBoundary,\n padding = _options.padding,\n flipVariations = _options.flipVariations,\n _options$allowedAutoP = _options.allowedAutoPlacements,\n allowedAutoPlacements = _options$allowedAutoP === void 0 ? allPlacements : _options$allowedAutoP;\n var variation = getVariation(placement);\n var placements = variation ? flipVariations ? variationPlacements : variationPlacements.filter(function (placement) {\n return getVariation(placement) === variation;\n }) : basePlacements;\n var allowedPlacements = placements.filter(function (placement) {\n return allowedAutoPlacements.indexOf(placement) >= 0;\n });\n\n if (allowedPlacements.length === 0) {\n allowedPlacements = placements;\n } // $FlowFixMe[incompatible-type]: Flow seems to have problems with two array unions...\n\n\n var overflows = allowedPlacements.reduce(function (acc, placement) {\n acc[placement] = detectOverflow(state, {\n placement: placement,\n boundary: boundary,\n rootBoundary: rootBoundary,\n padding: padding\n })[getBasePlacement(placement)];\n return acc;\n }, {});\n return Object.keys(overflows).sort(function (a, b) {\n return overflows[a] - overflows[b];\n });\n}","import getOppositePlacement from \"../utils/getOppositePlacement.js\";\nimport getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getOppositeVariationPlacement from \"../utils/getOppositeVariationPlacement.js\";\nimport detectOverflow from \"../utils/detectOverflow.js\";\nimport computeAutoPlacement from \"../utils/computeAutoPlacement.js\";\nimport { bottom, top, start, right, left, auto } from \"../enums.js\";\nimport getVariation from \"../utils/getVariation.js\"; // eslint-disable-next-line import/no-unused-modules\n\nfunction getExpandedFallbackPlacements(placement) {\n if (getBasePlacement(placement) === auto) {\n return [];\n }\n\n var oppositePlacement = getOppositePlacement(placement);\n return [getOppositeVariationPlacement(placement), oppositePlacement, getOppositeVariationPlacement(oppositePlacement)];\n}\n\nfunction flip(_ref) {\n var state = _ref.state,\n options = _ref.options,\n name = _ref.name;\n\n if (state.modifiersData[name]._skip) {\n return;\n }\n\n var _options$mainAxis = options.mainAxis,\n checkMainAxis = _options$mainAxis === void 0 ? true : _options$mainAxis,\n _options$altAxis = options.altAxis,\n checkAltAxis = _options$altAxis === void 0 ? true : _options$altAxis,\n specifiedFallbackPlacements = options.fallbackPlacements,\n padding = options.padding,\n boundary = options.boundary,\n rootBoundary = options.rootBoundary,\n altBoundary = options.altBoundary,\n _options$flipVariatio = options.flipVariations,\n flipVariations = _options$flipVariatio === void 0 ? true : _options$flipVariatio,\n allowedAutoPlacements = options.allowedAutoPlacements;\n var preferredPlacement = state.options.placement;\n var basePlacement = getBasePlacement(preferredPlacement);\n var isBasePlacement = basePlacement === preferredPlacement;\n var fallbackPlacements = specifiedFallbackPlacements || (isBasePlacement || !flipVariations ? [getOppositePlacement(preferredPlacement)] : getExpandedFallbackPlacements(preferredPlacement));\n var placements = [preferredPlacement].concat(fallbackPlacements).reduce(function (acc, placement) {\n return acc.concat(getBasePlacement(placement) === auto ? computeAutoPlacement(state, {\n placement: placement,\n boundary: boundary,\n rootBoundary: rootBoundary,\n padding: padding,\n flipVariations: flipVariations,\n allowedAutoPlacements: allowedAutoPlacements\n }) : placement);\n }, []);\n var referenceRect = state.rects.reference;\n var popperRect = state.rects.popper;\n var checksMap = new Map();\n var makeFallbackChecks = true;\n var firstFittingPlacement = placements[0];\n\n for (var i = 0; i < placements.length; i++) {\n var placement = placements[i];\n\n var _basePlacement = getBasePlacement(placement);\n\n var isStartVariation = getVariation(placement) === start;\n var isVertical = [top, bottom].indexOf(_basePlacement) >= 0;\n var len = isVertical ? 'width' : 'height';\n var overflow = detectOverflow(state, {\n placement: placement,\n boundary: boundary,\n rootBoundary: rootBoundary,\n altBoundary: altBoundary,\n padding: padding\n });\n var mainVariationSide = isVertical ? isStartVariation ? right : left : isStartVariation ? bottom : top;\n\n if (referenceRect[len] > popperRect[len]) {\n mainVariationSide = getOppositePlacement(mainVariationSide);\n }\n\n var altVariationSide = getOppositePlacement(mainVariationSide);\n var checks = [];\n\n if (checkMainAxis) {\n checks.push(overflow[_basePlacement] <= 0);\n }\n\n if (checkAltAxis) {\n checks.push(overflow[mainVariationSide] <= 0, overflow[altVariationSide] <= 0);\n }\n\n if (checks.every(function (check) {\n return check;\n })) {\n firstFittingPlacement = placement;\n makeFallbackChecks = false;\n break;\n }\n\n checksMap.set(placement, checks);\n }\n\n if (makeFallbackChecks) {\n // `2` may be desired in some cases – research later\n var numberOfChecks = flipVariations ? 3 : 1;\n\n var _loop = function _loop(_i) {\n var fittingPlacement = placements.find(function (placement) {\n var checks = checksMap.get(placement);\n\n if (checks) {\n return checks.slice(0, _i).every(function (check) {\n return check;\n });\n }\n });\n\n if (fittingPlacement) {\n firstFittingPlacement = fittingPlacement;\n return \"break\";\n }\n };\n\n for (var _i = numberOfChecks; _i > 0; _i--) {\n var _ret = _loop(_i);\n\n if (_ret === \"break\") break;\n }\n }\n\n if (state.placement !== firstFittingPlacement) {\n state.modifiersData[name]._skip = true;\n state.placement = firstFittingPlacement;\n state.reset = true;\n }\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'flip',\n enabled: true,\n phase: 'main',\n fn: flip,\n requiresIfExists: ['offset'],\n data: {\n _skip: false\n }\n};","import { top, bottom, left, right } from \"../enums.js\";\nimport detectOverflow from \"../utils/detectOverflow.js\";\n\nfunction getSideOffsets(overflow, rect, preventedOffsets) {\n if (preventedOffsets === void 0) {\n preventedOffsets = {\n x: 0,\n y: 0\n };\n }\n\n return {\n top: overflow.top - rect.height - preventedOffsets.y,\n right: overflow.right - rect.width + preventedOffsets.x,\n bottom: overflow.bottom - rect.height + preventedOffsets.y,\n left: overflow.left - rect.width - preventedOffsets.x\n };\n}\n\nfunction isAnySideFullyClipped(overflow) {\n return [top, right, bottom, left].some(function (side) {\n return overflow[side] >= 0;\n });\n}\n\nfunction hide(_ref) {\n var state = _ref.state,\n name = _ref.name;\n var referenceRect = state.rects.reference;\n var popperRect = state.rects.popper;\n var preventedOffsets = state.modifiersData.preventOverflow;\n var referenceOverflow = detectOverflow(state, {\n elementContext: 'reference'\n });\n var popperAltOverflow = detectOverflow(state, {\n altBoundary: true\n });\n var referenceClippingOffsets = getSideOffsets(referenceOverflow, referenceRect);\n var popperEscapeOffsets = getSideOffsets(popperAltOverflow, popperRect, preventedOffsets);\n var isReferenceHidden = isAnySideFullyClipped(referenceClippingOffsets);\n var hasPopperEscaped = isAnySideFullyClipped(popperEscapeOffsets);\n state.modifiersData[name] = {\n referenceClippingOffsets: referenceClippingOffsets,\n popperEscapeOffsets: popperEscapeOffsets,\n isReferenceHidden: isReferenceHidden,\n hasPopperEscaped: hasPopperEscaped\n };\n state.attributes.popper = Object.assign({}, state.attributes.popper, {\n 'data-popper-reference-hidden': isReferenceHidden,\n 'data-popper-escaped': hasPopperEscaped\n });\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'hide',\n enabled: true,\n phase: 'main',\n requiresIfExists: ['preventOverflow'],\n fn: hide\n};","import getBasePlacement from \"../utils/getBasePlacement.js\";\nimport { top, left, right, placements } from \"../enums.js\"; // eslint-disable-next-line import/no-unused-modules\n\nexport function distanceAndSkiddingToXY(placement, rects, offset) {\n var basePlacement = getBasePlacement(placement);\n var invertDistance = [left, top].indexOf(basePlacement) >= 0 ? -1 : 1;\n\n var _ref = typeof offset === 'function' ? offset(Object.assign({}, rects, {\n placement: placement\n })) : offset,\n skidding = _ref[0],\n distance = _ref[1];\n\n skidding = skidding || 0;\n distance = (distance || 0) * invertDistance;\n return [left, right].indexOf(basePlacement) >= 0 ? {\n x: distance,\n y: skidding\n } : {\n x: skidding,\n y: distance\n };\n}\n\nfunction offset(_ref2) {\n var state = _ref2.state,\n options = _ref2.options,\n name = _ref2.name;\n var _options$offset = options.offset,\n offset = _options$offset === void 0 ? [0, 0] : _options$offset;\n var data = placements.reduce(function (acc, placement) {\n acc[placement] = distanceAndSkiddingToXY(placement, state.rects, offset);\n return acc;\n }, {});\n var _data$state$placement = data[state.placement],\n x = _data$state$placement.x,\n y = _data$state$placement.y;\n\n if (state.modifiersData.popperOffsets != null) {\n state.modifiersData.popperOffsets.x += x;\n state.modifiersData.popperOffsets.y += y;\n }\n\n state.modifiersData[name] = data;\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'offset',\n enabled: true,\n phase: 'main',\n requires: ['popperOffsets'],\n fn: offset\n};","import computeOffsets from \"../utils/computeOffsets.js\";\n\nfunction popperOffsets(_ref) {\n var state = _ref.state,\n name = _ref.name;\n // Offsets are the actual position the popper needs to have to be\n // properly positioned near its reference element\n // This is the most basic placement, and will be adjusted by\n // the modifiers in the next step\n state.modifiersData[name] = computeOffsets({\n reference: state.rects.reference,\n element: state.rects.popper,\n strategy: 'absolute',\n placement: state.placement\n });\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'popperOffsets',\n enabled: true,\n phase: 'read',\n fn: popperOffsets,\n data: {}\n};","export default function getAltAxis(axis) {\n return axis === 'x' ? 'y' : 'x';\n}","import { top, left, right, bottom, start } from \"../enums.js\";\nimport getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getMainAxisFromPlacement from \"../utils/getMainAxisFromPlacement.js\";\nimport getAltAxis from \"../utils/getAltAxis.js\";\nimport { within, withinMaxClamp } from \"../utils/within.js\";\nimport getLayoutRect from \"../dom-utils/getLayoutRect.js\";\nimport getOffsetParent from \"../dom-utils/getOffsetParent.js\";\nimport detectOverflow from \"../utils/detectOverflow.js\";\nimport getVariation from \"../utils/getVariation.js\";\nimport getFreshSideObject from \"../utils/getFreshSideObject.js\";\nimport { min as mathMin, max as mathMax } from \"../utils/math.js\";\n\nfunction preventOverflow(_ref) {\n var state = _ref.state,\n options = _ref.options,\n name = _ref.name;\n var _options$mainAxis = options.mainAxis,\n checkMainAxis = _options$mainAxis === void 0 ? true : _options$mainAxis,\n _options$altAxis = options.altAxis,\n checkAltAxis = _options$altAxis === void 0 ? false : _options$altAxis,\n boundary = options.boundary,\n rootBoundary = options.rootBoundary,\n altBoundary = options.altBoundary,\n padding = options.padding,\n _options$tether = options.tether,\n tether = _options$tether === void 0 ? true : _options$tether,\n _options$tetherOffset = options.tetherOffset,\n tetherOffset = _options$tetherOffset === void 0 ? 0 : _options$tetherOffset;\n var overflow = detectOverflow(state, {\n boundary: boundary,\n rootBoundary: rootBoundary,\n padding: padding,\n altBoundary: altBoundary\n });\n var basePlacement = getBasePlacement(state.placement);\n var variation = getVariation(state.placement);\n var isBasePlacement = !variation;\n var mainAxis = getMainAxisFromPlacement(basePlacement);\n var altAxis = getAltAxis(mainAxis);\n var popperOffsets = state.modifiersData.popperOffsets;\n var referenceRect = state.rects.reference;\n var popperRect = state.rects.popper;\n var tetherOffsetValue = typeof tetherOffset === 'function' ? tetherOffset(Object.assign({}, state.rects, {\n placement: state.placement\n })) : tetherOffset;\n var normalizedTetherOffsetValue = typeof tetherOffsetValue === 'number' ? {\n mainAxis: tetherOffsetValue,\n altAxis: tetherOffsetValue\n } : Object.assign({\n mainAxis: 0,\n altAxis: 0\n }, tetherOffsetValue);\n var offsetModifierState = state.modifiersData.offset ? state.modifiersData.offset[state.placement] : null;\n var data = {\n x: 0,\n y: 0\n };\n\n if (!popperOffsets) {\n return;\n }\n\n if (checkMainAxis) {\n var _offsetModifierState$;\n\n var mainSide = mainAxis === 'y' ? top : left;\n var altSide = mainAxis === 'y' ? bottom : right;\n var len = mainAxis === 'y' ? 'height' : 'width';\n var offset = popperOffsets[mainAxis];\n var min = offset + overflow[mainSide];\n var max = offset - overflow[altSide];\n var additive = tether ? -popperRect[len] / 2 : 0;\n var minLen = variation === start ? referenceRect[len] : popperRect[len];\n var maxLen = variation === start ? -popperRect[len] : -referenceRect[len]; // We need to include the arrow in the calculation so the arrow doesn't go\n // outside the reference bounds\n\n var arrowElement = state.elements.arrow;\n var arrowRect = tether && arrowElement ? getLayoutRect(arrowElement) : {\n width: 0,\n height: 0\n };\n var arrowPaddingObject = state.modifiersData['arrow#persistent'] ? state.modifiersData['arrow#persistent'].padding : getFreshSideObject();\n var arrowPaddingMin = arrowPaddingObject[mainSide];\n var arrowPaddingMax = arrowPaddingObject[altSide]; // If the reference length is smaller than the arrow length, we don't want\n // to include its full size in the calculation. If the reference is small\n // and near the edge of a boundary, the popper can overflow even if the\n // reference is not overflowing as well (e.g. virtual elements with no\n // width or height)\n\n var arrowLen = within(0, referenceRect[len], arrowRect[len]);\n var minOffset = isBasePlacement ? referenceRect[len] / 2 - additive - arrowLen - arrowPaddingMin - normalizedTetherOffsetValue.mainAxis : minLen - arrowLen - arrowPaddingMin - normalizedTetherOffsetValue.mainAxis;\n var maxOffset = isBasePlacement ? -referenceRect[len] / 2 + additive + arrowLen + arrowPaddingMax + normalizedTetherOffsetValue.mainAxis : maxLen + arrowLen + arrowPaddingMax + normalizedTetherOffsetValue.mainAxis;\n var arrowOffsetParent = state.elements.arrow && getOffsetParent(state.elements.arrow);\n var clientOffset = arrowOffsetParent ? mainAxis === 'y' ? arrowOffsetParent.clientTop || 0 : arrowOffsetParent.clientLeft || 0 : 0;\n var offsetModifierValue = (_offsetModifierState$ = offsetModifierState == null ? void 0 : offsetModifierState[mainAxis]) != null ? _offsetModifierState$ : 0;\n var tetherMin = offset + minOffset - offsetModifierValue - clientOffset;\n var tetherMax = offset + maxOffset - offsetModifierValue;\n var preventedOffset = within(tether ? mathMin(min, tetherMin) : min, offset, tether ? mathMax(max, tetherMax) : max);\n popperOffsets[mainAxis] = preventedOffset;\n data[mainAxis] = preventedOffset - offset;\n }\n\n if (checkAltAxis) {\n var _offsetModifierState$2;\n\n var _mainSide = mainAxis === 'x' ? top : left;\n\n var _altSide = mainAxis === 'x' ? bottom : right;\n\n var _offset = popperOffsets[altAxis];\n\n var _len = altAxis === 'y' ? 'height' : 'width';\n\n var _min = _offset + overflow[_mainSide];\n\n var _max = _offset - overflow[_altSide];\n\n var isOriginSide = [top, left].indexOf(basePlacement) !== -1;\n\n var _offsetModifierValue = (_offsetModifierState$2 = offsetModifierState == null ? void 0 : offsetModifierState[altAxis]) != null ? _offsetModifierState$2 : 0;\n\n var _tetherMin = isOriginSide ? _min : _offset - referenceRect[_len] - popperRect[_len] - _offsetModifierValue + normalizedTetherOffsetValue.altAxis;\n\n var _tetherMax = isOriginSide ? _offset + referenceRect[_len] + popperRect[_len] - _offsetModifierValue - normalizedTetherOffsetValue.altAxis : _max;\n\n var _preventedOffset = tether && isOriginSide ? withinMaxClamp(_tetherMin, _offset, _tetherMax) : within(tether ? _tetherMin : _min, _offset, tether ? _tetherMax : _max);\n\n popperOffsets[altAxis] = _preventedOffset;\n data[altAxis] = _preventedOffset - _offset;\n }\n\n state.modifiersData[name] = data;\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'preventOverflow',\n enabled: true,\n phase: 'main',\n fn: preventOverflow,\n requiresIfExists: ['offset']\n};","export default function getHTMLElementScroll(element) {\n return {\n scrollLeft: element.scrollLeft,\n scrollTop: element.scrollTop\n };\n}","import getWindowScroll from \"./getWindowScroll.js\";\nimport getWindow from \"./getWindow.js\";\nimport { isHTMLElement } from \"./instanceOf.js\";\nimport getHTMLElementScroll from \"./getHTMLElementScroll.js\";\nexport default function getNodeScroll(node) {\n if (node === getWindow(node) || !isHTMLElement(node)) {\n return getWindowScroll(node);\n } else {\n return getHTMLElementScroll(node);\n }\n}","import getBoundingClientRect from \"./getBoundingClientRect.js\";\nimport getNodeScroll from \"./getNodeScroll.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport { isHTMLElement } from \"./instanceOf.js\";\nimport getWindowScrollBarX from \"./getWindowScrollBarX.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport isScrollParent from \"./isScrollParent.js\";\nimport { round } from \"../utils/math.js\";\n\nfunction isElementScaled(element) {\n var rect = element.getBoundingClientRect();\n var scaleX = round(rect.width) / element.offsetWidth || 1;\n var scaleY = round(rect.height) / element.offsetHeight || 1;\n return scaleX !== 1 || scaleY !== 1;\n} // Returns the composite rect of an element relative to its offsetParent.\n// Composite means it takes into account transforms as well as layout.\n\n\nexport default function getCompositeRect(elementOrVirtualElement, offsetParent, isFixed) {\n if (isFixed === void 0) {\n isFixed = false;\n }\n\n var isOffsetParentAnElement = isHTMLElement(offsetParent);\n var offsetParentIsScaled = isHTMLElement(offsetParent) && isElementScaled(offsetParent);\n var documentElement = getDocumentElement(offsetParent);\n var rect = getBoundingClientRect(elementOrVirtualElement, offsetParentIsScaled, isFixed);\n var scroll = {\n scrollLeft: 0,\n scrollTop: 0\n };\n var offsets = {\n x: 0,\n y: 0\n };\n\n if (isOffsetParentAnElement || !isOffsetParentAnElement && !isFixed) {\n if (getNodeName(offsetParent) !== 'body' || // https://github.com/popperjs/popper-core/issues/1078\n isScrollParent(documentElement)) {\n scroll = getNodeScroll(offsetParent);\n }\n\n if (isHTMLElement(offsetParent)) {\n offsets = getBoundingClientRect(offsetParent, true);\n offsets.x += offsetParent.clientLeft;\n offsets.y += offsetParent.clientTop;\n } else if (documentElement) {\n offsets.x = getWindowScrollBarX(documentElement);\n }\n }\n\n return {\n x: rect.left + scroll.scrollLeft - offsets.x,\n y: rect.top + scroll.scrollTop - offsets.y,\n width: rect.width,\n height: rect.height\n };\n}","import { modifierPhases } from \"../enums.js\"; // source: https://stackoverflow.com/questions/49875255\n\nfunction order(modifiers) {\n var map = new Map();\n var visited = new Set();\n var result = [];\n modifiers.forEach(function (modifier) {\n map.set(modifier.name, modifier);\n }); // On visiting object, check for its dependencies and visit them recursively\n\n function sort(modifier) {\n visited.add(modifier.name);\n var requires = [].concat(modifier.requires || [], modifier.requiresIfExists || []);\n requires.forEach(function (dep) {\n if (!visited.has(dep)) {\n var depModifier = map.get(dep);\n\n if (depModifier) {\n sort(depModifier);\n }\n }\n });\n result.push(modifier);\n }\n\n modifiers.forEach(function (modifier) {\n if (!visited.has(modifier.name)) {\n // check for visited object\n sort(modifier);\n }\n });\n return result;\n}\n\nexport default function orderModifiers(modifiers) {\n // order based on dependencies\n var orderedModifiers = order(modifiers); // order based on phase\n\n return modifierPhases.reduce(function (acc, phase) {\n return acc.concat(orderedModifiers.filter(function (modifier) {\n return modifier.phase === phase;\n }));\n }, []);\n}","export default function debounce(fn) {\n var pending;\n return function () {\n if (!pending) {\n pending = new Promise(function (resolve) {\n Promise.resolve().then(function () {\n pending = undefined;\n resolve(fn());\n });\n });\n }\n\n return pending;\n };\n}","export default function mergeByName(modifiers) {\n var merged = modifiers.reduce(function (merged, current) {\n var existing = merged[current.name];\n merged[current.name] = existing ? Object.assign({}, existing, current, {\n options: Object.assign({}, existing.options, current.options),\n data: Object.assign({}, existing.data, current.data)\n }) : current;\n return merged;\n }, {}); // IE11 does not support Object.values\n\n return Object.keys(merged).map(function (key) {\n return merged[key];\n });\n}","import getCompositeRect from \"./dom-utils/getCompositeRect.js\";\nimport getLayoutRect from \"./dom-utils/getLayoutRect.js\";\nimport listScrollParents from \"./dom-utils/listScrollParents.js\";\nimport getOffsetParent from \"./dom-utils/getOffsetParent.js\";\nimport orderModifiers from \"./utils/orderModifiers.js\";\nimport debounce from \"./utils/debounce.js\";\nimport mergeByName from \"./utils/mergeByName.js\";\nimport detectOverflow from \"./utils/detectOverflow.js\";\nimport { isElement } from \"./dom-utils/instanceOf.js\";\nvar DEFAULT_OPTIONS = {\n placement: 'bottom',\n modifiers: [],\n strategy: 'absolute'\n};\n\nfunction areValidElements() {\n for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {\n args[_key] = arguments[_key];\n }\n\n return !args.some(function (element) {\n return !(element && typeof element.getBoundingClientRect === 'function');\n });\n}\n\nexport function popperGenerator(generatorOptions) {\n if (generatorOptions === void 0) {\n generatorOptions = {};\n }\n\n var _generatorOptions = generatorOptions,\n _generatorOptions$def = _generatorOptions.defaultModifiers,\n defaultModifiers = _generatorOptions$def === void 0 ? [] : _generatorOptions$def,\n _generatorOptions$def2 = _generatorOptions.defaultOptions,\n defaultOptions = _generatorOptions$def2 === void 0 ? DEFAULT_OPTIONS : _generatorOptions$def2;\n return function createPopper(reference, popper, options) {\n if (options === void 0) {\n options = defaultOptions;\n }\n\n var state = {\n placement: 'bottom',\n orderedModifiers: [],\n options: Object.assign({}, DEFAULT_OPTIONS, defaultOptions),\n modifiersData: {},\n elements: {\n reference: reference,\n popper: popper\n },\n attributes: {},\n styles: {}\n };\n var effectCleanupFns = [];\n var isDestroyed = false;\n var instance = {\n state: state,\n setOptions: function setOptions(setOptionsAction) {\n var options = typeof setOptionsAction === 'function' ? setOptionsAction(state.options) : setOptionsAction;\n cleanupModifierEffects();\n state.options = Object.assign({}, defaultOptions, state.options, options);\n state.scrollParents = {\n reference: isElement(reference) ? listScrollParents(reference) : reference.contextElement ? listScrollParents(reference.contextElement) : [],\n popper: listScrollParents(popper)\n }; // Orders the modifiers based on their dependencies and `phase`\n // properties\n\n var orderedModifiers = orderModifiers(mergeByName([].concat(defaultModifiers, state.options.modifiers))); // Strip out disabled modifiers\n\n state.orderedModifiers = orderedModifiers.filter(function (m) {\n return m.enabled;\n });\n runModifierEffects();\n return instance.update();\n },\n // Sync update – it will always be executed, even if not necessary. This\n // is useful for low frequency updates where sync behavior simplifies the\n // logic.\n // For high frequency updates (e.g. `resize` and `scroll` events), always\n // prefer the async Popper#update method\n forceUpdate: function forceUpdate() {\n if (isDestroyed) {\n return;\n }\n\n var _state$elements = state.elements,\n reference = _state$elements.reference,\n popper = _state$elements.popper; // Don't proceed if `reference` or `popper` are not valid elements\n // anymore\n\n if (!areValidElements(reference, popper)) {\n return;\n } // Store the reference and popper rects to be read by modifiers\n\n\n state.rects = {\n reference: getCompositeRect(reference, getOffsetParent(popper), state.options.strategy === 'fixed'),\n popper: getLayoutRect(popper)\n }; // Modifiers have the ability to reset the current update cycle. The\n // most common use case for this is the `flip` modifier changing the\n // placement, which then needs to re-run all the modifiers, because the\n // logic was previously ran for the previous placement and is therefore\n // stale/incorrect\n\n state.reset = false;\n state.placement = state.options.placement; // On each update cycle, the `modifiersData` property for each modifier\n // is filled with the initial data specified by the modifier. This means\n // it doesn't persist and is fresh on each update.\n // To ensure persistent data, use `${name}#persistent`\n\n state.orderedModifiers.forEach(function (modifier) {\n return state.modifiersData[modifier.name] = Object.assign({}, modifier.data);\n });\n\n for (var index = 0; index < state.orderedModifiers.length; index++) {\n if (state.reset === true) {\n state.reset = false;\n index = -1;\n continue;\n }\n\n var _state$orderedModifie = state.orderedModifiers[index],\n fn = _state$orderedModifie.fn,\n _state$orderedModifie2 = _state$orderedModifie.options,\n _options = _state$orderedModifie2 === void 0 ? {} : _state$orderedModifie2,\n name = _state$orderedModifie.name;\n\n if (typeof fn === 'function') {\n state = fn({\n state: state,\n options: _options,\n name: name,\n instance: instance\n }) || state;\n }\n }\n },\n // Async and optimistically optimized update – it will not be executed if\n // not necessary (debounced to run at most once-per-tick)\n update: debounce(function () {\n return new Promise(function (resolve) {\n instance.forceUpdate();\n resolve(state);\n });\n }),\n destroy: function destroy() {\n cleanupModifierEffects();\n isDestroyed = true;\n }\n };\n\n if (!areValidElements(reference, popper)) {\n return instance;\n }\n\n instance.setOptions(options).then(function (state) {\n if (!isDestroyed && options.onFirstUpdate) {\n options.onFirstUpdate(state);\n }\n }); // Modifiers have the ability to execute arbitrary code before the first\n // update cycle runs. They will be executed in the same order as the update\n // cycle. This is useful when a modifier adds some persistent data that\n // other modifiers need to use, but the modifier is run after the dependent\n // one.\n\n function runModifierEffects() {\n state.orderedModifiers.forEach(function (_ref) {\n var name = _ref.name,\n _ref$options = _ref.options,\n options = _ref$options === void 0 ? {} : _ref$options,\n effect = _ref.effect;\n\n if (typeof effect === 'function') {\n var cleanupFn = effect({\n state: state,\n name: name,\n instance: instance,\n options: options\n });\n\n var noopFn = function noopFn() {};\n\n effectCleanupFns.push(cleanupFn || noopFn);\n }\n });\n }\n\n function cleanupModifierEffects() {\n effectCleanupFns.forEach(function (fn) {\n return fn();\n });\n effectCleanupFns = [];\n }\n\n return instance;\n };\n}\nexport var createPopper = /*#__PURE__*/popperGenerator(); // eslint-disable-next-line import/no-unused-modules\n\nexport { detectOverflow };","import { popperGenerator, detectOverflow } from \"./createPopper.js\";\nimport eventListeners from \"./modifiers/eventListeners.js\";\nimport popperOffsets from \"./modifiers/popperOffsets.js\";\nimport computeStyles from \"./modifiers/computeStyles.js\";\nimport applyStyles from \"./modifiers/applyStyles.js\";\nimport offset from \"./modifiers/offset.js\";\nimport flip from \"./modifiers/flip.js\";\nimport preventOverflow from \"./modifiers/preventOverflow.js\";\nimport arrow from \"./modifiers/arrow.js\";\nimport hide from \"./modifiers/hide.js\";\nvar defaultModifiers = [eventListeners, popperOffsets, computeStyles, applyStyles, offset, flip, preventOverflow, arrow, hide];\nvar createPopper = /*#__PURE__*/popperGenerator({\n defaultModifiers: defaultModifiers\n}); // eslint-disable-next-line import/no-unused-modules\n\nexport { createPopper, popperGenerator, defaultModifiers, detectOverflow }; // eslint-disable-next-line import/no-unused-modules\n\nexport { createPopper as createPopperLite } from \"./popper-lite.js\"; // eslint-disable-next-line import/no-unused-modules\n\nexport * from \"./modifiers/index.js\";","import { generateUtilityClass } from '../generateUtilityClass';\nimport { generateUtilityClasses } from '../generateUtilityClasses';\nconst COMPONENT_NAME = 'Popper';\nexport function getPopperUtilityClass(slot) {\n return generateUtilityClass(COMPONENT_NAME, slot);\n}\nexport const popperClasses = generateUtilityClasses(COMPONENT_NAME, ['root']);","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"anchorEl\", \"children\", \"direction\", \"disablePortal\", \"modifiers\", \"open\", \"placement\", \"popperOptions\", \"popperRef\", \"slotProps\", \"slots\", \"TransitionProps\", \"ownerState\"],\n _excluded2 = [\"anchorEl\", \"children\", \"container\", \"direction\", \"disablePortal\", \"keepMounted\", \"modifiers\", \"open\", \"placement\", \"popperOptions\", \"popperRef\", \"style\", \"transition\", \"slotProps\", \"slots\"];\nimport * as React from 'react';\nimport { chainPropTypes, HTMLElementType, refType, unstable_ownerDocument as ownerDocument, unstable_useEnhancedEffect as useEnhancedEffect, unstable_useForkRef as useForkRef } from '@mui/utils';\nimport { createPopper } from '@popperjs/core';\nimport PropTypes from 'prop-types';\nimport { unstable_composeClasses as composeClasses } from '../composeClasses';\nimport { Portal } from '../Portal';\nimport { getPopperUtilityClass } from './popperClasses';\nimport { useSlotProps } from '../utils';\nimport { useClassNamesOverride } from '../utils/ClassNameConfigurator';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nfunction flipPlacement(placement, direction) {\n if (direction === 'ltr') {\n return placement;\n }\n switch (placement) {\n case 'bottom-end':\n return 'bottom-start';\n case 'bottom-start':\n return 'bottom-end';\n case 'top-end':\n return 'top-start';\n case 'top-start':\n return 'top-end';\n default:\n return placement;\n }\n}\nfunction resolveAnchorEl(anchorEl) {\n return typeof anchorEl === 'function' ? anchorEl() : anchorEl;\n}\nfunction isHTMLElement(element) {\n return element.nodeType !== undefined;\n}\nfunction isVirtualElement(element) {\n return !isHTMLElement(element);\n}\nconst useUtilityClasses = () => {\n const slots = {\n root: ['root']\n };\n return composeClasses(slots, useClassNamesOverride(getPopperUtilityClass));\n};\nconst defaultPopperOptions = {};\nconst PopperTooltip = /*#__PURE__*/React.forwardRef(function PopperTooltip(props, forwardedRef) {\n var _slots$root;\n const {\n anchorEl,\n children,\n direction,\n disablePortal,\n modifiers,\n open,\n placement: initialPlacement,\n popperOptions,\n popperRef: popperRefProp,\n slotProps = {},\n slots = {},\n TransitionProps\n // @ts-ignore internal logic\n // prevent from spreading to DOM, it can come from the parent component e.g. Select.\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const tooltipRef = React.useRef(null);\n const ownRef = useForkRef(tooltipRef, forwardedRef);\n const popperRef = React.useRef(null);\n const handlePopperRef = useForkRef(popperRef, popperRefProp);\n const handlePopperRefRef = React.useRef(handlePopperRef);\n useEnhancedEffect(() => {\n handlePopperRefRef.current = handlePopperRef;\n }, [handlePopperRef]);\n React.useImperativeHandle(popperRefProp, () => popperRef.current, []);\n const rtlPlacement = flipPlacement(initialPlacement, direction);\n /**\n * placement initialized from prop but can change during lifetime if modifiers.flip.\n * modifiers.flip is essentially a flip for controlled/uncontrolled behavior\n */\n const [placement, setPlacement] = React.useState(rtlPlacement);\n const [resolvedAnchorElement, setResolvedAnchorElement] = React.useState(resolveAnchorEl(anchorEl));\n React.useEffect(() => {\n if (popperRef.current) {\n popperRef.current.forceUpdate();\n }\n });\n React.useEffect(() => {\n if (anchorEl) {\n setResolvedAnchorElement(resolveAnchorEl(anchorEl));\n }\n }, [anchorEl]);\n useEnhancedEffect(() => {\n if (!resolvedAnchorElement || !open) {\n return undefined;\n }\n const handlePopperUpdate = data => {\n setPlacement(data.placement);\n };\n if (process.env.NODE_ENV !== 'production') {\n if (resolvedAnchorElement && isHTMLElement(resolvedAnchorElement) && resolvedAnchorElement.nodeType === 1) {\n const box = resolvedAnchorElement.getBoundingClientRect();\n if (process.env.NODE_ENV !== 'test' && box.top === 0 && box.left === 0 && box.right === 0 && box.bottom === 0) {\n console.warn(['MUI: The `anchorEl` prop provided to the component is invalid.', 'The anchor element should be part of the document layout.', \"Make sure the element is present in the document or that it's not display none.\"].join('\\n'));\n }\n }\n }\n let popperModifiers = [{\n name: 'preventOverflow',\n options: {\n altBoundary: disablePortal\n }\n }, {\n name: 'flip',\n options: {\n altBoundary: disablePortal\n }\n }, {\n name: 'onUpdate',\n enabled: true,\n phase: 'afterWrite',\n fn: ({\n state\n }) => {\n handlePopperUpdate(state);\n }\n }];\n if (modifiers != null) {\n popperModifiers = popperModifiers.concat(modifiers);\n }\n if (popperOptions && popperOptions.modifiers != null) {\n popperModifiers = popperModifiers.concat(popperOptions.modifiers);\n }\n const popper = createPopper(resolvedAnchorElement, tooltipRef.current, _extends({\n placement: rtlPlacement\n }, popperOptions, {\n modifiers: popperModifiers\n }));\n handlePopperRefRef.current(popper);\n return () => {\n popper.destroy();\n handlePopperRefRef.current(null);\n };\n }, [resolvedAnchorElement, disablePortal, modifiers, open, popperOptions, rtlPlacement]);\n const childProps = {\n placement: placement\n };\n if (TransitionProps !== null) {\n childProps.TransitionProps = TransitionProps;\n }\n const classes = useUtilityClasses();\n const Root = (_slots$root = slots.root) != null ? _slots$root : 'div';\n const rootProps = useSlotProps({\n elementType: Root,\n externalSlotProps: slotProps.root,\n externalForwardedProps: other,\n additionalProps: {\n role: 'tooltip',\n ref: ownRef\n },\n ownerState: props,\n className: classes.root\n });\n return /*#__PURE__*/_jsx(Root, _extends({}, rootProps, {\n children: typeof children === 'function' ? children(childProps) : children\n }));\n});\n\n/**\n * Poppers rely on the 3rd party library [Popper.js](https://popper.js.org/docs/v2/) for positioning.\n *\n * Demos:\n *\n * - [Popper](https://mui.com/base-ui/react-popper/)\n *\n * API:\n *\n * - [Popper API](https://mui.com/base-ui/react-popper/components-api/#popper)\n */\nconst Popper = /*#__PURE__*/React.forwardRef(function Popper(props, forwardedRef) {\n const {\n anchorEl,\n children,\n container: containerProp,\n direction = 'ltr',\n disablePortal = false,\n keepMounted = false,\n modifiers,\n open,\n placement = 'bottom',\n popperOptions = defaultPopperOptions,\n popperRef,\n style,\n transition = false,\n slotProps = {},\n slots = {}\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded2);\n const [exited, setExited] = React.useState(true);\n const handleEnter = () => {\n setExited(false);\n };\n const handleExited = () => {\n setExited(true);\n };\n if (!keepMounted && !open && (!transition || exited)) {\n return null;\n }\n\n // If the container prop is provided, use that\n // If the anchorEl prop is provided, use its parent body element as the container\n // If neither are provided let the Modal take care of choosing the container\n let container;\n if (containerProp) {\n container = containerProp;\n } else if (anchorEl) {\n const resolvedAnchorEl = resolveAnchorEl(anchorEl);\n container = resolvedAnchorEl && isHTMLElement(resolvedAnchorEl) ? ownerDocument(resolvedAnchorEl).body : ownerDocument(null).body;\n }\n const display = !open && keepMounted && (!transition || exited) ? 'none' : undefined;\n const transitionProps = transition ? {\n in: open,\n onEnter: handleEnter,\n onExited: handleExited\n } : undefined;\n return /*#__PURE__*/_jsx(Portal, {\n disablePortal: disablePortal,\n container: container,\n children: /*#__PURE__*/_jsx(PopperTooltip, _extends({\n anchorEl: anchorEl,\n direction: direction,\n disablePortal: disablePortal,\n modifiers: modifiers,\n ref: forwardedRef,\n open: transition ? !exited : open,\n placement: placement,\n popperOptions: popperOptions,\n popperRef: popperRef,\n slotProps: slotProps,\n slots: slots\n }, other, {\n style: _extends({\n // Prevents scroll issue, waiting for Popper.js to add this style once initiated.\n position: 'fixed',\n // Fix Popper.js display issue\n top: 0,\n left: 0,\n display\n }, style),\n TransitionProps: transitionProps,\n children: children\n }))\n });\n});\nprocess.env.NODE_ENV !== \"production\" ? Popper.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * An HTML element, [virtualElement](https://popper.js.org/docs/v2/virtual-elements/),\n * or a function that returns either.\n * It's used to set the position of the popper.\n * The return value will passed as the reference object of the Popper instance.\n */\n anchorEl: chainPropTypes(PropTypes.oneOfType([HTMLElementType, PropTypes.object, PropTypes.func]), props => {\n if (props.open) {\n const resolvedAnchorEl = resolveAnchorEl(props.anchorEl);\n if (resolvedAnchorEl && isHTMLElement(resolvedAnchorEl) && resolvedAnchorEl.nodeType === 1) {\n const box = resolvedAnchorEl.getBoundingClientRect();\n if (process.env.NODE_ENV !== 'test' && box.top === 0 && box.left === 0 && box.right === 0 && box.bottom === 0) {\n return new Error(['MUI: The `anchorEl` prop provided to the component is invalid.', 'The anchor element should be part of the document layout.', \"Make sure the element is present in the document or that it's not display none.\"].join('\\n'));\n }\n } else if (!resolvedAnchorEl || typeof resolvedAnchorEl.getBoundingClientRect !== 'function' || isVirtualElement(resolvedAnchorEl) && resolvedAnchorEl.contextElement != null && resolvedAnchorEl.contextElement.nodeType !== 1) {\n return new Error(['MUI: The `anchorEl` prop provided to the component is invalid.', 'It should be an HTML element instance or a virtualElement ', '(https://popper.js.org/docs/v2/virtual-elements/).'].join('\\n'));\n }\n }\n return null;\n }),\n /**\n * Popper render function or node.\n */\n children: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.node, PropTypes.func]),\n /**\n * An HTML element or function that returns one.\n * The `container` will have the portal children appended to it.\n *\n * You can also provide a callback, which is called in a React layout effect.\n * This lets you set the container from a ref, and also makes server-side rendering possible.\n *\n * By default, it uses the body of the top-level document object,\n * so it's simply `document.body` most of the time.\n */\n container: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.func]),\n /**\n * Direction of the text.\n * @default 'ltr'\n */\n direction: PropTypes.oneOf(['ltr', 'rtl']),\n /**\n * The `children` will be under the DOM hierarchy of the parent component.\n * @default false\n */\n disablePortal: PropTypes.bool,\n /**\n * Always keep the children in the DOM.\n * This prop can be useful in SEO situation or\n * when you want to maximize the responsiveness of the Popper.\n * @default false\n */\n keepMounted: PropTypes.bool,\n /**\n * Popper.js is based on a \"plugin-like\" architecture,\n * most of its features are fully encapsulated \"modifiers\".\n *\n * A modifier is a function that is called each time Popper.js needs to\n * compute the position of the popper.\n * For this reason, modifiers should be very performant to avoid bottlenecks.\n * To learn how to create a modifier, [read the modifiers documentation](https://popper.js.org/docs/v2/modifiers/).\n */\n modifiers: PropTypes.arrayOf(PropTypes.shape({\n data: PropTypes.object,\n effect: PropTypes.func,\n enabled: PropTypes.bool,\n fn: PropTypes.func,\n name: PropTypes.any,\n options: PropTypes.object,\n phase: PropTypes.oneOf(['afterMain', 'afterRead', 'afterWrite', 'beforeMain', 'beforeRead', 'beforeWrite', 'main', 'read', 'write']),\n requires: PropTypes.arrayOf(PropTypes.string),\n requiresIfExists: PropTypes.arrayOf(PropTypes.string)\n })),\n /**\n * If `true`, the component is shown.\n */\n open: PropTypes.bool.isRequired,\n /**\n * Popper placement.\n * @default 'bottom'\n */\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n /**\n * Options provided to the [`Popper.js`](https://popper.js.org/docs/v2/constructors/#options) instance.\n * @default {}\n */\n popperOptions: PropTypes.shape({\n modifiers: PropTypes.array,\n onFirstUpdate: PropTypes.func,\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n strategy: PropTypes.oneOf(['absolute', 'fixed'])\n }),\n /**\n * A ref that points to the used popper instance.\n */\n popperRef: refType,\n /**\n * The props used for each slot inside the Popper.\n * @default {}\n */\n slotProps: PropTypes.shape({\n root: PropTypes.oneOfType([PropTypes.func, PropTypes.object])\n }),\n /**\n * The components used for each slot inside the Popper.\n * Either a string to use a HTML element or a component.\n * @default {}\n */\n slots: PropTypes.shape({\n root: PropTypes.elementType\n }),\n /**\n * Help supporting a react-transition-group/Transition component.\n * @default false\n */\n transition: PropTypes.bool\n} : void 0;\nexport { Popper };","'use client';\n\nimport * as React from 'react';\nimport { useTheme as useThemeSystem } from '@mui/system';\nimport defaultTheme from './defaultTheme';\nimport THEME_ID from './identifier';\nexport default function useTheme() {\n const theme = useThemeSystem(defaultTheme);\n if (process.env.NODE_ENV !== 'production') {\n // eslint-disable-next-line react-hooks/rules-of-hooks\n React.useDebugValue(theme);\n }\n return theme[THEME_ID] || theme;\n}","export default function _setPrototypeOf(o, p) {\n _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function _setPrototypeOf(o, p) {\n o.__proto__ = p;\n return o;\n };\n return _setPrototypeOf(o, p);\n}","import setPrototypeOf from \"./setPrototypeOf.js\";\nexport default function _inheritsLoose(subClass, superClass) {\n subClass.prototype = Object.create(superClass.prototype);\n subClass.prototype.constructor = subClass;\n setPrototypeOf(subClass, superClass);\n}","export default {\n disabled: false\n};","import PropTypes from 'prop-types';\nexport var timeoutsShape = process.env.NODE_ENV !== 'production' ? PropTypes.oneOfType([PropTypes.number, PropTypes.shape({\n enter: PropTypes.number,\n exit: PropTypes.number,\n appear: PropTypes.number\n}).isRequired]) : null;\nexport var classNamesShape = process.env.NODE_ENV !== 'production' ? PropTypes.oneOfType([PropTypes.string, PropTypes.shape({\n enter: PropTypes.string,\n exit: PropTypes.string,\n active: PropTypes.string\n}), PropTypes.shape({\n enter: PropTypes.string,\n enterDone: PropTypes.string,\n enterActive: PropTypes.string,\n exit: PropTypes.string,\n exitDone: PropTypes.string,\n exitActive: PropTypes.string\n})]) : null;","import React from 'react';\nexport default React.createContext(null);","export var forceReflow = function forceReflow(node) {\n return node.scrollTop;\n};","import _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _inheritsLoose from \"@babel/runtime/helpers/esm/inheritsLoose\";\nimport PropTypes from 'prop-types';\nimport React from 'react';\nimport ReactDOM from 'react-dom';\nimport config from './config';\nimport { timeoutsShape } from './utils/PropTypes';\nimport TransitionGroupContext from './TransitionGroupContext';\nimport { forceReflow } from './utils/reflow';\nexport var UNMOUNTED = 'unmounted';\nexport var EXITED = 'exited';\nexport var ENTERING = 'entering';\nexport var ENTERED = 'entered';\nexport var EXITING = 'exiting';\n/**\n * The Transition component lets you describe a transition from one component\n * state to another _over time_ with a simple declarative API. Most commonly\n * it's used to animate the mounting and unmounting of a component, but can also\n * be used to describe in-place transition states as well.\n *\n * ---\n *\n * **Note**: `Transition` is a platform-agnostic base component. If you're using\n * transitions in CSS, you'll probably want to use\n * [`CSSTransition`](https://reactcommunity.org/react-transition-group/css-transition)\n * instead. It inherits all the features of `Transition`, but contains\n * additional features necessary to play nice with CSS transitions (hence the\n * name of the component).\n *\n * ---\n *\n * By default the `Transition` component does not alter the behavior of the\n * component it renders, it only tracks \"enter\" and \"exit\" states for the\n * components. It's up to you to give meaning and effect to those states. For\n * example we can add styles to a component when it enters or exits:\n *\n * ```jsx\n * import { Transition } from 'react-transition-group';\n *\n * const duration = 300;\n *\n * const defaultStyle = {\n * transition: `opacity ${duration}ms ease-in-out`,\n * opacity: 0,\n * }\n *\n * const transitionStyles = {\n * entering: { opacity: 1 },\n * entered: { opacity: 1 },\n * exiting: { opacity: 0 },\n * exited: { opacity: 0 },\n * };\n *\n * const Fade = ({ in: inProp }) => (\n * \n * {state => (\n *
    \n * I'm a fade Transition!\n *
    \n * )}\n *
    \n * );\n * ```\n *\n * There are 4 main states a Transition can be in:\n * - `'entering'`\n * - `'entered'`\n * - `'exiting'`\n * - `'exited'`\n *\n * Transition state is toggled via the `in` prop. When `true` the component\n * begins the \"Enter\" stage. During this stage, the component will shift from\n * its current transition state, to `'entering'` for the duration of the\n * transition and then to the `'entered'` stage once it's complete. Let's take\n * the following example (we'll use the\n * [useState](https://reactjs.org/docs/hooks-reference.html#usestate) hook):\n *\n * ```jsx\n * function App() {\n * const [inProp, setInProp] = useState(false);\n * return (\n *
    \n * \n * {state => (\n * // ...\n * )}\n * \n * \n *
    \n * );\n * }\n * ```\n *\n * When the button is clicked the component will shift to the `'entering'` state\n * and stay there for 500ms (the value of `timeout`) before it finally switches\n * to `'entered'`.\n *\n * When `in` is `false` the same thing happens except the state moves from\n * `'exiting'` to `'exited'`.\n */\n\nvar Transition = /*#__PURE__*/function (_React$Component) {\n _inheritsLoose(Transition, _React$Component);\n\n function Transition(props, context) {\n var _this;\n\n _this = _React$Component.call(this, props, context) || this;\n var parentGroup = context; // In the context of a TransitionGroup all enters are really appears\n\n var appear = parentGroup && !parentGroup.isMounting ? props.enter : props.appear;\n var initialStatus;\n _this.appearStatus = null;\n\n if (props.in) {\n if (appear) {\n initialStatus = EXITED;\n _this.appearStatus = ENTERING;\n } else {\n initialStatus = ENTERED;\n }\n } else {\n if (props.unmountOnExit || props.mountOnEnter) {\n initialStatus = UNMOUNTED;\n } else {\n initialStatus = EXITED;\n }\n }\n\n _this.state = {\n status: initialStatus\n };\n _this.nextCallback = null;\n return _this;\n }\n\n Transition.getDerivedStateFromProps = function getDerivedStateFromProps(_ref, prevState) {\n var nextIn = _ref.in;\n\n if (nextIn && prevState.status === UNMOUNTED) {\n return {\n status: EXITED\n };\n }\n\n return null;\n } // getSnapshotBeforeUpdate(prevProps) {\n // let nextStatus = null\n // if (prevProps !== this.props) {\n // const { status } = this.state\n // if (this.props.in) {\n // if (status !== ENTERING && status !== ENTERED) {\n // nextStatus = ENTERING\n // }\n // } else {\n // if (status === ENTERING || status === ENTERED) {\n // nextStatus = EXITING\n // }\n // }\n // }\n // return { nextStatus }\n // }\n ;\n\n var _proto = Transition.prototype;\n\n _proto.componentDidMount = function componentDidMount() {\n this.updateStatus(true, this.appearStatus);\n };\n\n _proto.componentDidUpdate = function componentDidUpdate(prevProps) {\n var nextStatus = null;\n\n if (prevProps !== this.props) {\n var status = this.state.status;\n\n if (this.props.in) {\n if (status !== ENTERING && status !== ENTERED) {\n nextStatus = ENTERING;\n }\n } else {\n if (status === ENTERING || status === ENTERED) {\n nextStatus = EXITING;\n }\n }\n }\n\n this.updateStatus(false, nextStatus);\n };\n\n _proto.componentWillUnmount = function componentWillUnmount() {\n this.cancelNextCallback();\n };\n\n _proto.getTimeouts = function getTimeouts() {\n var timeout = this.props.timeout;\n var exit, enter, appear;\n exit = enter = appear = timeout;\n\n if (timeout != null && typeof timeout !== 'number') {\n exit = timeout.exit;\n enter = timeout.enter; // TODO: remove fallback for next major\n\n appear = timeout.appear !== undefined ? timeout.appear : enter;\n }\n\n return {\n exit: exit,\n enter: enter,\n appear: appear\n };\n };\n\n _proto.updateStatus = function updateStatus(mounting, nextStatus) {\n if (mounting === void 0) {\n mounting = false;\n }\n\n if (nextStatus !== null) {\n // nextStatus will always be ENTERING or EXITING.\n this.cancelNextCallback();\n\n if (nextStatus === ENTERING) {\n if (this.props.unmountOnExit || this.props.mountOnEnter) {\n var node = this.props.nodeRef ? this.props.nodeRef.current : ReactDOM.findDOMNode(this); // https://github.com/reactjs/react-transition-group/pull/749\n // With unmountOnExit or mountOnEnter, the enter animation should happen at the transition between `exited` and `entering`.\n // To make the animation happen, we have to separate each rendering and avoid being processed as batched.\n\n if (node) forceReflow(node);\n }\n\n this.performEnter(mounting);\n } else {\n this.performExit();\n }\n } else if (this.props.unmountOnExit && this.state.status === EXITED) {\n this.setState({\n status: UNMOUNTED\n });\n }\n };\n\n _proto.performEnter = function performEnter(mounting) {\n var _this2 = this;\n\n var enter = this.props.enter;\n var appearing = this.context ? this.context.isMounting : mounting;\n\n var _ref2 = this.props.nodeRef ? [appearing] : [ReactDOM.findDOMNode(this), appearing],\n maybeNode = _ref2[0],\n maybeAppearing = _ref2[1];\n\n var timeouts = this.getTimeouts();\n var enterTimeout = appearing ? timeouts.appear : timeouts.enter; // no enter animation skip right to ENTERED\n // if we are mounting and running this it means appear _must_ be set\n\n if (!mounting && !enter || config.disabled) {\n this.safeSetState({\n status: ENTERED\n }, function () {\n _this2.props.onEntered(maybeNode);\n });\n return;\n }\n\n this.props.onEnter(maybeNode, maybeAppearing);\n this.safeSetState({\n status: ENTERING\n }, function () {\n _this2.props.onEntering(maybeNode, maybeAppearing);\n\n _this2.onTransitionEnd(enterTimeout, function () {\n _this2.safeSetState({\n status: ENTERED\n }, function () {\n _this2.props.onEntered(maybeNode, maybeAppearing);\n });\n });\n });\n };\n\n _proto.performExit = function performExit() {\n var _this3 = this;\n\n var exit = this.props.exit;\n var timeouts = this.getTimeouts();\n var maybeNode = this.props.nodeRef ? undefined : ReactDOM.findDOMNode(this); // no exit animation skip right to EXITED\n\n if (!exit || config.disabled) {\n this.safeSetState({\n status: EXITED\n }, function () {\n _this3.props.onExited(maybeNode);\n });\n return;\n }\n\n this.props.onExit(maybeNode);\n this.safeSetState({\n status: EXITING\n }, function () {\n _this3.props.onExiting(maybeNode);\n\n _this3.onTransitionEnd(timeouts.exit, function () {\n _this3.safeSetState({\n status: EXITED\n }, function () {\n _this3.props.onExited(maybeNode);\n });\n });\n });\n };\n\n _proto.cancelNextCallback = function cancelNextCallback() {\n if (this.nextCallback !== null) {\n this.nextCallback.cancel();\n this.nextCallback = null;\n }\n };\n\n _proto.safeSetState = function safeSetState(nextState, callback) {\n // This shouldn't be necessary, but there are weird race conditions with\n // setState callbacks and unmounting in testing, so always make sure that\n // we can cancel any pending setState callbacks after we unmount.\n callback = this.setNextCallback(callback);\n this.setState(nextState, callback);\n };\n\n _proto.setNextCallback = function setNextCallback(callback) {\n var _this4 = this;\n\n var active = true;\n\n this.nextCallback = function (event) {\n if (active) {\n active = false;\n _this4.nextCallback = null;\n callback(event);\n }\n };\n\n this.nextCallback.cancel = function () {\n active = false;\n };\n\n return this.nextCallback;\n };\n\n _proto.onTransitionEnd = function onTransitionEnd(timeout, handler) {\n this.setNextCallback(handler);\n var node = this.props.nodeRef ? this.props.nodeRef.current : ReactDOM.findDOMNode(this);\n var doesNotHaveTimeoutOrListener = timeout == null && !this.props.addEndListener;\n\n if (!node || doesNotHaveTimeoutOrListener) {\n setTimeout(this.nextCallback, 0);\n return;\n }\n\n if (this.props.addEndListener) {\n var _ref3 = this.props.nodeRef ? [this.nextCallback] : [node, this.nextCallback],\n maybeNode = _ref3[0],\n maybeNextCallback = _ref3[1];\n\n this.props.addEndListener(maybeNode, maybeNextCallback);\n }\n\n if (timeout != null) {\n setTimeout(this.nextCallback, timeout);\n }\n };\n\n _proto.render = function render() {\n var status = this.state.status;\n\n if (status === UNMOUNTED) {\n return null;\n }\n\n var _this$props = this.props,\n children = _this$props.children,\n _in = _this$props.in,\n _mountOnEnter = _this$props.mountOnEnter,\n _unmountOnExit = _this$props.unmountOnExit,\n _appear = _this$props.appear,\n _enter = _this$props.enter,\n _exit = _this$props.exit,\n _timeout = _this$props.timeout,\n _addEndListener = _this$props.addEndListener,\n _onEnter = _this$props.onEnter,\n _onEntering = _this$props.onEntering,\n _onEntered = _this$props.onEntered,\n _onExit = _this$props.onExit,\n _onExiting = _this$props.onExiting,\n _onExited = _this$props.onExited,\n _nodeRef = _this$props.nodeRef,\n childProps = _objectWithoutPropertiesLoose(_this$props, [\"children\", \"in\", \"mountOnEnter\", \"unmountOnExit\", \"appear\", \"enter\", \"exit\", \"timeout\", \"addEndListener\", \"onEnter\", \"onEntering\", \"onEntered\", \"onExit\", \"onExiting\", \"onExited\", \"nodeRef\"]);\n\n return (\n /*#__PURE__*/\n // allows for nested Transitions\n React.createElement(TransitionGroupContext.Provider, {\n value: null\n }, typeof children === 'function' ? children(status, childProps) : React.cloneElement(React.Children.only(children), childProps))\n );\n };\n\n return Transition;\n}(React.Component);\n\nTransition.contextType = TransitionGroupContext;\nTransition.propTypes = process.env.NODE_ENV !== \"production\" ? {\n /**\n * A React reference to DOM element that need to transition:\n * https://stackoverflow.com/a/51127130/4671932\n *\n * - When `nodeRef` prop is used, `node` is not passed to callback functions\n * (e.g. `onEnter`) because user already has direct access to the node.\n * - When changing `key` prop of `Transition` in a `TransitionGroup` a new\n * `nodeRef` need to be provided to `Transition` with changed `key` prop\n * (see\n * [test/CSSTransition-test.js](https://github.com/reactjs/react-transition-group/blob/13435f897b3ab71f6e19d724f145596f5910581c/test/CSSTransition-test.js#L362-L437)).\n */\n nodeRef: PropTypes.shape({\n current: typeof Element === 'undefined' ? PropTypes.any : function (propValue, key, componentName, location, propFullName, secret) {\n var value = propValue[key];\n return PropTypes.instanceOf(value && 'ownerDocument' in value ? value.ownerDocument.defaultView.Element : Element)(propValue, key, componentName, location, propFullName, secret);\n }\n }),\n\n /**\n * A `function` child can be used instead of a React element. This function is\n * called with the current transition status (`'entering'`, `'entered'`,\n * `'exiting'`, `'exited'`), which can be used to apply context\n * specific props to a component.\n *\n * ```jsx\n * \n * {state => (\n * \n * )}\n * \n * ```\n */\n children: PropTypes.oneOfType([PropTypes.func.isRequired, PropTypes.element.isRequired]).isRequired,\n\n /**\n * Show the component; triggers the enter or exit states\n */\n in: PropTypes.bool,\n\n /**\n * By default the child component is mounted immediately along with\n * the parent `Transition` component. If you want to \"lazy mount\" the component on the\n * first `in={true}` you can set `mountOnEnter`. After the first enter transition the component will stay\n * mounted, even on \"exited\", unless you also specify `unmountOnExit`.\n */\n mountOnEnter: PropTypes.bool,\n\n /**\n * By default the child component stays mounted after it reaches the `'exited'` state.\n * Set `unmountOnExit` if you'd prefer to unmount the component after it finishes exiting.\n */\n unmountOnExit: PropTypes.bool,\n\n /**\n * By default the child component does not perform the enter transition when\n * it first mounts, regardless of the value of `in`. If you want this\n * behavior, set both `appear` and `in` to `true`.\n *\n * > **Note**: there are no special appear states like `appearing`/`appeared`, this prop\n * > only adds an additional enter transition. However, in the\n * > `` component that first enter transition does result in\n * > additional `.appear-*` classes, that way you can choose to style it\n * > differently.\n */\n appear: PropTypes.bool,\n\n /**\n * Enable or disable enter transitions.\n */\n enter: PropTypes.bool,\n\n /**\n * Enable or disable exit transitions.\n */\n exit: PropTypes.bool,\n\n /**\n * The duration of the transition, in milliseconds.\n * Required unless `addEndListener` is provided.\n *\n * You may specify a single timeout for all transitions:\n *\n * ```jsx\n * timeout={500}\n * ```\n *\n * or individually:\n *\n * ```jsx\n * timeout={{\n * appear: 500,\n * enter: 300,\n * exit: 500,\n * }}\n * ```\n *\n * - `appear` defaults to the value of `enter`\n * - `enter` defaults to `0`\n * - `exit` defaults to `0`\n *\n * @type {number | { enter?: number, exit?: number, appear?: number }}\n */\n timeout: function timeout(props) {\n var pt = timeoutsShape;\n if (!props.addEndListener) pt = pt.isRequired;\n\n for (var _len = arguments.length, args = new Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) {\n args[_key - 1] = arguments[_key];\n }\n\n return pt.apply(void 0, [props].concat(args));\n },\n\n /**\n * Add a custom transition end trigger. Called with the transitioning\n * DOM node and a `done` callback. Allows for more fine grained transition end\n * logic. Timeouts are still used as a fallback if provided.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * ```jsx\n * addEndListener={(node, done) => {\n * // use the css transitionend event to mark the finish of a transition\n * node.addEventListener('transitionend', done, false);\n * }}\n * ```\n */\n addEndListener: PropTypes.func,\n\n /**\n * Callback fired before the \"entering\" status is applied. An extra parameter\n * `isAppearing` is supplied to indicate if the enter stage is occurring on the initial mount\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement, isAppearing: bool) -> void\n */\n onEnter: PropTypes.func,\n\n /**\n * Callback fired after the \"entering\" status is applied. An extra parameter\n * `isAppearing` is supplied to indicate if the enter stage is occurring on the initial mount\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement, isAppearing: bool)\n */\n onEntering: PropTypes.func,\n\n /**\n * Callback fired after the \"entered\" status is applied. An extra parameter\n * `isAppearing` is supplied to indicate if the enter stage is occurring on the initial mount\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement, isAppearing: bool) -> void\n */\n onEntered: PropTypes.func,\n\n /**\n * Callback fired before the \"exiting\" status is applied.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement) -> void\n */\n onExit: PropTypes.func,\n\n /**\n * Callback fired after the \"exiting\" status is applied.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement) -> void\n */\n onExiting: PropTypes.func,\n\n /**\n * Callback fired after the \"exited\" status is applied.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed\n *\n * @type Function(node: HtmlElement) -> void\n */\n onExited: PropTypes.func\n} : {}; // Name the function so it is clearer in the documentation\n\nfunction noop() {}\n\nTransition.defaultProps = {\n in: false,\n mountOnEnter: false,\n unmountOnExit: false,\n appear: false,\n enter: true,\n exit: true,\n onEnter: noop,\n onEntering: noop,\n onEntered: noop,\n onExit: noop,\n onExiting: noop,\n onExited: noop\n};\nTransition.UNMOUNTED = UNMOUNTED;\nTransition.EXITED = EXITED;\nTransition.ENTERING = ENTERING;\nTransition.ENTERED = ENTERED;\nTransition.EXITING = EXITING;\nexport default Transition;","export const reflow = node => node.scrollTop;\nexport function getTransitionProps(props, options) {\n var _style$transitionDura, _style$transitionTimi;\n const {\n timeout,\n easing,\n style = {}\n } = props;\n return {\n duration: (_style$transitionDura = style.transitionDuration) != null ? _style$transitionDura : typeof timeout === 'number' ? timeout : timeout[options.mode] || 0,\n easing: (_style$transitionTimi = style.transitionTimingFunction) != null ? _style$transitionTimi : typeof easing === 'object' ? easing[options.mode] : easing,\n delay: style.transitionDelay\n };\n}","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"addEndListener\", \"appear\", \"children\", \"easing\", \"in\", \"onEnter\", \"onEntered\", \"onEntering\", \"onExit\", \"onExited\", \"onExiting\", \"style\", \"timeout\", \"TransitionComponent\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport { elementAcceptingRef, unstable_useTimeout as useTimeout } from '@mui/utils';\nimport { Transition } from 'react-transition-group';\nimport useTheme from '../styles/useTheme';\nimport { getTransitionProps, reflow } from '../transitions/utils';\nimport useForkRef from '../utils/useForkRef';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nfunction getScale(value) {\n return `scale(${value}, ${value ** 2})`;\n}\nconst styles = {\n entering: {\n opacity: 1,\n transform: getScale(1)\n },\n entered: {\n opacity: 1,\n transform: 'none'\n }\n};\n\n/*\n TODO v6: remove\n Conditionally apply a workaround for the CSS transition bug in Safari 15.4 / WebKit browsers.\n */\nconst isWebKit154 = typeof navigator !== 'undefined' && /^((?!chrome|android).)*(safari|mobile)/i.test(navigator.userAgent) && /(os |version\\/)15(.|_)4/i.test(navigator.userAgent);\n\n/**\n * The Grow transition is used by the [Tooltip](/material-ui/react-tooltip/) and\n * [Popover](/material-ui/react-popover/) components.\n * It uses [react-transition-group](https://github.com/reactjs/react-transition-group) internally.\n */\nconst Grow = /*#__PURE__*/React.forwardRef(function Grow(props, ref) {\n const {\n addEndListener,\n appear = true,\n children,\n easing,\n in: inProp,\n onEnter,\n onEntered,\n onEntering,\n onExit,\n onExited,\n onExiting,\n style,\n timeout = 'auto',\n // eslint-disable-next-line react/prop-types\n TransitionComponent = Transition\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const timer = useTimeout();\n const autoTimeout = React.useRef();\n const theme = useTheme();\n const nodeRef = React.useRef(null);\n const handleRef = useForkRef(nodeRef, children.ref, ref);\n const normalizedTransitionCallback = callback => maybeIsAppearing => {\n if (callback) {\n const node = nodeRef.current;\n\n // onEnterXxx and onExitXxx callbacks have a different arguments.length value.\n if (maybeIsAppearing === undefined) {\n callback(node);\n } else {\n callback(node, maybeIsAppearing);\n }\n }\n };\n const handleEntering = normalizedTransitionCallback(onEntering);\n const handleEnter = normalizedTransitionCallback((node, isAppearing) => {\n reflow(node); // So the animation always start from the start.\n\n const {\n duration: transitionDuration,\n delay,\n easing: transitionTimingFunction\n } = getTransitionProps({\n style,\n timeout,\n easing\n }, {\n mode: 'enter'\n });\n let duration;\n if (timeout === 'auto') {\n duration = theme.transitions.getAutoHeightDuration(node.clientHeight);\n autoTimeout.current = duration;\n } else {\n duration = transitionDuration;\n }\n node.style.transition = [theme.transitions.create('opacity', {\n duration,\n delay\n }), theme.transitions.create('transform', {\n duration: isWebKit154 ? duration : duration * 0.666,\n delay,\n easing: transitionTimingFunction\n })].join(',');\n if (onEnter) {\n onEnter(node, isAppearing);\n }\n });\n const handleEntered = normalizedTransitionCallback(onEntered);\n const handleExiting = normalizedTransitionCallback(onExiting);\n const handleExit = normalizedTransitionCallback(node => {\n const {\n duration: transitionDuration,\n delay,\n easing: transitionTimingFunction\n } = getTransitionProps({\n style,\n timeout,\n easing\n }, {\n mode: 'exit'\n });\n let duration;\n if (timeout === 'auto') {\n duration = theme.transitions.getAutoHeightDuration(node.clientHeight);\n autoTimeout.current = duration;\n } else {\n duration = transitionDuration;\n }\n node.style.transition = [theme.transitions.create('opacity', {\n duration,\n delay\n }), theme.transitions.create('transform', {\n duration: isWebKit154 ? duration : duration * 0.666,\n delay: isWebKit154 ? delay : delay || duration * 0.333,\n easing: transitionTimingFunction\n })].join(',');\n node.style.opacity = 0;\n node.style.transform = getScale(0.75);\n if (onExit) {\n onExit(node);\n }\n });\n const handleExited = normalizedTransitionCallback(onExited);\n const handleAddEndListener = next => {\n if (timeout === 'auto') {\n timer.start(autoTimeout.current || 0, next);\n }\n if (addEndListener) {\n // Old call signature before `react-transition-group` implemented `nodeRef`\n addEndListener(nodeRef.current, next);\n }\n };\n return /*#__PURE__*/_jsx(TransitionComponent, _extends({\n appear: appear,\n in: inProp,\n nodeRef: nodeRef,\n onEnter: handleEnter,\n onEntered: handleEntered,\n onEntering: handleEntering,\n onExit: handleExit,\n onExited: handleExited,\n onExiting: handleExiting,\n addEndListener: handleAddEndListener,\n timeout: timeout === 'auto' ? null : timeout\n }, other, {\n children: (state, childProps) => {\n return /*#__PURE__*/React.cloneElement(children, _extends({\n style: _extends({\n opacity: 0,\n transform: getScale(0.75),\n visibility: state === 'exited' && !inProp ? 'hidden' : undefined\n }, styles[state], style, children.props.style),\n ref: handleRef\n }, childProps));\n }\n }));\n});\nprocess.env.NODE_ENV !== \"production\" ? Grow.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the d.ts file and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * Add a custom transition end trigger. Called with the transitioning DOM\n * node and a done callback. Allows for more fine grained transition end\n * logic. Note: Timeouts are still used as a fallback if provided.\n */\n addEndListener: PropTypes.func,\n /**\n * Perform the enter transition when it first mounts if `in` is also `true`.\n * Set this to `false` to disable this behavior.\n * @default true\n */\n appear: PropTypes.bool,\n /**\n * A single child content element.\n */\n children: elementAcceptingRef.isRequired,\n /**\n * The transition timing function.\n * You may specify a single easing or a object containing enter and exit values.\n */\n easing: PropTypes.oneOfType([PropTypes.shape({\n enter: PropTypes.string,\n exit: PropTypes.string\n }), PropTypes.string]),\n /**\n * If `true`, the component will transition in.\n */\n in: PropTypes.bool,\n /**\n * @ignore\n */\n onEnter: PropTypes.func,\n /**\n * @ignore\n */\n onEntered: PropTypes.func,\n /**\n * @ignore\n */\n onEntering: PropTypes.func,\n /**\n * @ignore\n */\n onExit: PropTypes.func,\n /**\n * @ignore\n */\n onExited: PropTypes.func,\n /**\n * @ignore\n */\n onExiting: PropTypes.func,\n /**\n * @ignore\n */\n style: PropTypes.object,\n /**\n * The duration for the transition, in milliseconds.\n * You may specify a single timeout for all transitions, or individually with an object.\n *\n * Set to 'auto' to automatically calculate transition time based on height.\n * @default 'auto'\n */\n timeout: PropTypes.oneOfType([PropTypes.oneOf(['auto']), PropTypes.number, PropTypes.shape({\n appear: PropTypes.number,\n enter: PropTypes.number,\n exit: PropTypes.number\n })])\n} : void 0;\nGrow.muiSupportAuto = true;\nexport default Grow;","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"anchorEl\", \"component\", \"components\", \"componentsProps\", \"container\", \"disablePortal\", \"keepMounted\", \"modifiers\", \"open\", \"placement\", \"popperOptions\", \"popperRef\", \"transition\", \"slots\", \"slotProps\"];\nimport { Popper as BasePopper } from '@mui/base/Popper';\nimport { useThemeWithoutDefault as useTheme } from '@mui/system';\nimport { HTMLElementType, refType } from '@mui/utils';\nimport PropTypes from 'prop-types';\nimport * as React from 'react';\nimport { styled, useThemeProps } from '../styles';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nconst PopperRoot = styled(BasePopper, {\n name: 'MuiPopper',\n slot: 'Root',\n overridesResolver: (props, styles) => styles.root\n})({});\n\n/**\n *\n * Demos:\n *\n * - [Autocomplete](https://mui.com/material-ui/react-autocomplete/)\n * - [Menu](https://mui.com/material-ui/react-menu/)\n * - [Popper](https://mui.com/material-ui/react-popper/)\n *\n * API:\n *\n * - [Popper API](https://mui.com/material-ui/api/popper/)\n */\nconst Popper = /*#__PURE__*/React.forwardRef(function Popper(inProps, ref) {\n var _slots$root;\n const theme = useTheme();\n const props = useThemeProps({\n props: inProps,\n name: 'MuiPopper'\n });\n const {\n anchorEl,\n component,\n components,\n componentsProps,\n container,\n disablePortal,\n keepMounted,\n modifiers,\n open,\n placement,\n popperOptions,\n popperRef,\n transition,\n slots,\n slotProps\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const RootComponent = (_slots$root = slots == null ? void 0 : slots.root) != null ? _slots$root : components == null ? void 0 : components.Root;\n const otherProps = _extends({\n anchorEl,\n container,\n disablePortal,\n keepMounted,\n modifiers,\n open,\n placement,\n popperOptions,\n popperRef,\n transition\n }, other);\n return /*#__PURE__*/_jsx(PopperRoot, _extends({\n as: component,\n direction: theme == null ? void 0 : theme.direction,\n slots: {\n root: RootComponent\n },\n slotProps: slotProps != null ? slotProps : componentsProps\n }, otherProps, {\n ref: ref\n }));\n});\nprocess.env.NODE_ENV !== \"production\" ? Popper.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * An HTML element, [virtualElement](https://popper.js.org/docs/v2/virtual-elements/),\n * or a function that returns either.\n * It's used to set the position of the popper.\n * The return value will passed as the reference object of the Popper instance.\n */\n anchorEl: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.object, PropTypes.func]),\n /**\n * Popper render function or node.\n */\n children: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.node, PropTypes.func]),\n /**\n * The component used for the root node.\n * Either a string to use a HTML element or a component.\n */\n component: PropTypes.elementType,\n /**\n * The components used for each slot inside the Popper.\n * Either a string to use a HTML element or a component.\n * @default {}\n */\n components: PropTypes.shape({\n Root: PropTypes.elementType\n }),\n /**\n * The props used for each slot inside the Popper.\n * @default {}\n */\n componentsProps: PropTypes.shape({\n root: PropTypes.oneOfType([PropTypes.func, PropTypes.object])\n }),\n /**\n * An HTML element or function that returns one.\n * The `container` will have the portal children appended to it.\n *\n * You can also provide a callback, which is called in a React layout effect.\n * This lets you set the container from a ref, and also makes server-side rendering possible.\n *\n * By default, it uses the body of the top-level document object,\n * so it's simply `document.body` most of the time.\n */\n container: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.func]),\n /**\n * The `children` will be under the DOM hierarchy of the parent component.\n * @default false\n */\n disablePortal: PropTypes.bool,\n /**\n * Always keep the children in the DOM.\n * This prop can be useful in SEO situation or\n * when you want to maximize the responsiveness of the Popper.\n * @default false\n */\n keepMounted: PropTypes.bool,\n /**\n * Popper.js is based on a \"plugin-like\" architecture,\n * most of its features are fully encapsulated \"modifiers\".\n *\n * A modifier is a function that is called each time Popper.js needs to\n * compute the position of the popper.\n * For this reason, modifiers should be very performant to avoid bottlenecks.\n * To learn how to create a modifier, [read the modifiers documentation](https://popper.js.org/docs/v2/modifiers/).\n */\n modifiers: PropTypes.arrayOf(PropTypes.shape({\n data: PropTypes.object,\n effect: PropTypes.func,\n enabled: PropTypes.bool,\n fn: PropTypes.func,\n name: PropTypes.any,\n options: PropTypes.object,\n phase: PropTypes.oneOf(['afterMain', 'afterRead', 'afterWrite', 'beforeMain', 'beforeRead', 'beforeWrite', 'main', 'read', 'write']),\n requires: PropTypes.arrayOf(PropTypes.string),\n requiresIfExists: PropTypes.arrayOf(PropTypes.string)\n })),\n /**\n * If `true`, the component is shown.\n */\n open: PropTypes.bool.isRequired,\n /**\n * Popper placement.\n * @default 'bottom'\n */\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n /**\n * Options provided to the [`Popper.js`](https://popper.js.org/docs/v2/constructors/#options) instance.\n * @default {}\n */\n popperOptions: PropTypes.shape({\n modifiers: PropTypes.array,\n onFirstUpdate: PropTypes.func,\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n strategy: PropTypes.oneOf(['absolute', 'fixed'])\n }),\n /**\n * A ref that points to the used popper instance.\n */\n popperRef: refType,\n /**\n * The props used for each slot inside the Popper.\n * @default {}\n */\n slotProps: PropTypes.shape({\n root: PropTypes.oneOfType([PropTypes.func, PropTypes.object])\n }),\n /**\n * The components used for each slot inside the Popper.\n * Either a string to use a HTML element or a component.\n * @default {}\n */\n slots: PropTypes.shape({\n root: PropTypes.elementType\n }),\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Help supporting a react-transition-group/Transition component.\n * @default false\n */\n transition: PropTypes.bool\n} : void 0;\nexport default Popper;","import generateUtilityClasses from '@mui/utils/generateUtilityClasses';\nimport generateUtilityClass from '@mui/utils/generateUtilityClass';\nexport function getTooltipUtilityClass(slot) {\n return generateUtilityClass('MuiTooltip', slot);\n}\nconst tooltipClasses = generateUtilityClasses('MuiTooltip', ['popper', 'popperInteractive', 'popperArrow', 'popperClose', 'tooltip', 'tooltipArrow', 'touch', 'tooltipPlacementLeft', 'tooltipPlacementRight', 'tooltipPlacementTop', 'tooltipPlacementBottom', 'arrow']);\nexport default tooltipClasses;","'use client';\n\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nconst _excluded = [\"arrow\", \"children\", \"classes\", \"components\", \"componentsProps\", \"describeChild\", \"disableFocusListener\", \"disableHoverListener\", \"disableInteractive\", \"disableTouchListener\", \"enterDelay\", \"enterNextDelay\", \"enterTouchDelay\", \"followCursor\", \"id\", \"leaveDelay\", \"leaveTouchDelay\", \"onClose\", \"onOpen\", \"open\", \"placement\", \"PopperComponent\", \"PopperProps\", \"slotProps\", \"slots\", \"title\", \"TransitionComponent\", \"TransitionProps\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport clsx from 'clsx';\nimport { elementAcceptingRef, unstable_useTimeout as useTimeout, unstable_Timeout as Timeout } from '@mui/utils';\nimport { unstable_composeClasses as composeClasses, appendOwnerState } from '@mui/base';\nimport { alpha } from '@mui/system';\nimport styled from '../styles/styled';\nimport useTheme from '../styles/useTheme';\nimport useThemeProps from '../styles/useThemeProps';\nimport capitalize from '../utils/capitalize';\nimport Grow from '../Grow';\nimport Popper from '../Popper';\nimport useEventCallback from '../utils/useEventCallback';\nimport useForkRef from '../utils/useForkRef';\nimport useId from '../utils/useId';\nimport useIsFocusVisible from '../utils/useIsFocusVisible';\nimport useControlled from '../utils/useControlled';\nimport tooltipClasses, { getTooltipUtilityClass } from './tooltipClasses';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nimport { jsxs as _jsxs } from \"react/jsx-runtime\";\nfunction round(value) {\n return Math.round(value * 1e5) / 1e5;\n}\nconst useUtilityClasses = ownerState => {\n const {\n classes,\n disableInteractive,\n arrow,\n touch,\n placement\n } = ownerState;\n const slots = {\n popper: ['popper', !disableInteractive && 'popperInteractive', arrow && 'popperArrow'],\n tooltip: ['tooltip', arrow && 'tooltipArrow', touch && 'touch', `tooltipPlacement${capitalize(placement.split('-')[0])}`],\n arrow: ['arrow']\n };\n return composeClasses(slots, getTooltipUtilityClass, classes);\n};\nconst TooltipPopper = styled(Popper, {\n name: 'MuiTooltip',\n slot: 'Popper',\n overridesResolver: (props, styles) => {\n const {\n ownerState\n } = props;\n return [styles.popper, !ownerState.disableInteractive && styles.popperInteractive, ownerState.arrow && styles.popperArrow, !ownerState.open && styles.popperClose];\n }\n})(({\n theme,\n ownerState,\n open\n}) => _extends({\n zIndex: (theme.vars || theme).zIndex.tooltip,\n pointerEvents: 'none'\n}, !ownerState.disableInteractive && {\n pointerEvents: 'auto'\n}, !open && {\n pointerEvents: 'none'\n}, ownerState.arrow && {\n [`&[data-popper-placement*=\"bottom\"] .${tooltipClasses.arrow}`]: {\n top: 0,\n marginTop: '-0.71em',\n '&::before': {\n transformOrigin: '0 100%'\n }\n },\n [`&[data-popper-placement*=\"top\"] .${tooltipClasses.arrow}`]: {\n bottom: 0,\n marginBottom: '-0.71em',\n '&::before': {\n transformOrigin: '100% 0'\n }\n },\n [`&[data-popper-placement*=\"right\"] .${tooltipClasses.arrow}`]: _extends({}, !ownerState.isRtl ? {\n left: 0,\n marginLeft: '-0.71em'\n } : {\n right: 0,\n marginRight: '-0.71em'\n }, {\n height: '1em',\n width: '0.71em',\n '&::before': {\n transformOrigin: '100% 100%'\n }\n }),\n [`&[data-popper-placement*=\"left\"] .${tooltipClasses.arrow}`]: _extends({}, !ownerState.isRtl ? {\n right: 0,\n marginRight: '-0.71em'\n } : {\n left: 0,\n marginLeft: '-0.71em'\n }, {\n height: '1em',\n width: '0.71em',\n '&::before': {\n transformOrigin: '0 0'\n }\n })\n}));\nconst TooltipTooltip = styled('div', {\n name: 'MuiTooltip',\n slot: 'Tooltip',\n overridesResolver: (props, styles) => {\n const {\n ownerState\n } = props;\n return [styles.tooltip, ownerState.touch && styles.touch, ownerState.arrow && styles.tooltipArrow, styles[`tooltipPlacement${capitalize(ownerState.placement.split('-')[0])}`]];\n }\n})(({\n theme,\n ownerState\n}) => _extends({\n backgroundColor: theme.vars ? theme.vars.palette.Tooltip.bg : alpha(theme.palette.grey[700], 0.92),\n borderRadius: (theme.vars || theme).shape.borderRadius,\n color: (theme.vars || theme).palette.common.white,\n fontFamily: theme.typography.fontFamily,\n padding: '4px 8px',\n fontSize: theme.typography.pxToRem(11),\n maxWidth: 300,\n margin: 2,\n wordWrap: 'break-word',\n fontWeight: theme.typography.fontWeightMedium\n}, ownerState.arrow && {\n position: 'relative',\n margin: 0\n}, ownerState.touch && {\n padding: '8px 16px',\n fontSize: theme.typography.pxToRem(14),\n lineHeight: `${round(16 / 14)}em`,\n fontWeight: theme.typography.fontWeightRegular\n}, {\n [`.${tooltipClasses.popper}[data-popper-placement*=\"left\"] &`]: _extends({\n transformOrigin: 'right center'\n }, !ownerState.isRtl ? _extends({\n marginRight: '14px'\n }, ownerState.touch && {\n marginRight: '24px'\n }) : _extends({\n marginLeft: '14px'\n }, ownerState.touch && {\n marginLeft: '24px'\n })),\n [`.${tooltipClasses.popper}[data-popper-placement*=\"right\"] &`]: _extends({\n transformOrigin: 'left center'\n }, !ownerState.isRtl ? _extends({\n marginLeft: '14px'\n }, ownerState.touch && {\n marginLeft: '24px'\n }) : _extends({\n marginRight: '14px'\n }, ownerState.touch && {\n marginRight: '24px'\n })),\n [`.${tooltipClasses.popper}[data-popper-placement*=\"top\"] &`]: _extends({\n transformOrigin: 'center bottom',\n marginBottom: '14px'\n }, ownerState.touch && {\n marginBottom: '24px'\n }),\n [`.${tooltipClasses.popper}[data-popper-placement*=\"bottom\"] &`]: _extends({\n transformOrigin: 'center top',\n marginTop: '14px'\n }, ownerState.touch && {\n marginTop: '24px'\n })\n}));\nconst TooltipArrow = styled('span', {\n name: 'MuiTooltip',\n slot: 'Arrow',\n overridesResolver: (props, styles) => styles.arrow\n})(({\n theme\n}) => ({\n overflow: 'hidden',\n position: 'absolute',\n width: '1em',\n height: '0.71em' /* = width / sqrt(2) = (length of the hypotenuse) */,\n boxSizing: 'border-box',\n color: theme.vars ? theme.vars.palette.Tooltip.bg : alpha(theme.palette.grey[700], 0.9),\n '&::before': {\n content: '\"\"',\n margin: 'auto',\n display: 'block',\n width: '100%',\n height: '100%',\n backgroundColor: 'currentColor',\n transform: 'rotate(45deg)'\n }\n}));\nlet hystersisOpen = false;\nconst hystersisTimer = new Timeout();\nlet cursorPosition = {\n x: 0,\n y: 0\n};\nexport function testReset() {\n hystersisOpen = false;\n hystersisTimer.clear();\n}\nfunction composeEventHandler(handler, eventHandler) {\n return event => {\n if (eventHandler) {\n eventHandler(event);\n }\n handler(event);\n };\n}\n\n// TODO v6: Remove PopperComponent, PopperProps, TransitionComponent and TransitionProps.\nconst Tooltip = /*#__PURE__*/React.forwardRef(function Tooltip(inProps, ref) {\n var _ref, _slots$popper, _ref2, _ref3, _slots$transition, _ref4, _slots$tooltip, _ref5, _slots$arrow, _slotProps$popper, _ref6, _slotProps$popper2, _slotProps$transition, _slotProps$tooltip, _ref7, _slotProps$tooltip2, _slotProps$arrow, _ref8, _slotProps$arrow2;\n const props = useThemeProps({\n props: inProps,\n name: 'MuiTooltip'\n });\n const {\n arrow = false,\n children: childrenProp,\n components = {},\n componentsProps = {},\n describeChild = false,\n disableFocusListener = false,\n disableHoverListener = false,\n disableInteractive: disableInteractiveProp = false,\n disableTouchListener = false,\n enterDelay = 100,\n enterNextDelay = 0,\n enterTouchDelay = 700,\n followCursor = false,\n id: idProp,\n leaveDelay = 0,\n leaveTouchDelay = 1500,\n onClose,\n onOpen,\n open: openProp,\n placement = 'bottom',\n PopperComponent: PopperComponentProp,\n PopperProps = {},\n slotProps = {},\n slots = {},\n title,\n TransitionComponent: TransitionComponentProp = Grow,\n TransitionProps\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n\n // to prevent runtime errors, developers will need to provide a child as a React element anyway.\n const children = /*#__PURE__*/React.isValidElement(childrenProp) ? childrenProp : /*#__PURE__*/_jsx(\"span\", {\n children: childrenProp\n });\n const theme = useTheme();\n const isRtl = theme.direction === 'rtl';\n const [childNode, setChildNode] = React.useState();\n const [arrowRef, setArrowRef] = React.useState(null);\n const ignoreNonTouchEvents = React.useRef(false);\n const disableInteractive = disableInteractiveProp || followCursor;\n const closeTimer = useTimeout();\n const enterTimer = useTimeout();\n const leaveTimer = useTimeout();\n const touchTimer = useTimeout();\n const [openState, setOpenState] = useControlled({\n controlled: openProp,\n default: false,\n name: 'Tooltip',\n state: 'open'\n });\n let open = openState;\n if (process.env.NODE_ENV !== 'production') {\n // eslint-disable-next-line react-hooks/rules-of-hooks\n const {\n current: isControlled\n } = React.useRef(openProp !== undefined);\n\n // eslint-disable-next-line react-hooks/rules-of-hooks\n React.useEffect(() => {\n if (childNode && childNode.disabled && !isControlled && title !== '' && childNode.tagName.toLowerCase() === 'button') {\n console.error(['MUI: You are providing a disabled `button` child to the Tooltip component.', 'A disabled element does not fire events.', \"Tooltip needs to listen to the child element's events to display the title.\", '', 'Add a simple wrapper element, such as a `span`.'].join('\\n'));\n }\n }, [title, childNode, isControlled]);\n }\n const id = useId(idProp);\n const prevUserSelect = React.useRef();\n const stopTouchInteraction = useEventCallback(() => {\n if (prevUserSelect.current !== undefined) {\n document.body.style.WebkitUserSelect = prevUserSelect.current;\n prevUserSelect.current = undefined;\n }\n touchTimer.clear();\n });\n React.useEffect(() => stopTouchInteraction, [stopTouchInteraction]);\n const handleOpen = event => {\n hystersisTimer.clear();\n hystersisOpen = true;\n\n // The mouseover event will trigger for every nested element in the tooltip.\n // We can skip rerendering when the tooltip is already open.\n // We are using the mouseover event instead of the mouseenter event to fix a hide/show issue.\n setOpenState(true);\n if (onOpen && !open) {\n onOpen(event);\n }\n };\n const handleClose = useEventCallback(\n /**\n * @param {React.SyntheticEvent | Event} event\n */\n event => {\n hystersisTimer.start(800 + leaveDelay, () => {\n hystersisOpen = false;\n });\n setOpenState(false);\n if (onClose && open) {\n onClose(event);\n }\n closeTimer.start(theme.transitions.duration.shortest, () => {\n ignoreNonTouchEvents.current = false;\n });\n });\n const handleEnter = event => {\n if (ignoreNonTouchEvents.current && event.type !== 'touchstart') {\n return;\n }\n\n // Remove the title ahead of time.\n // We don't want to wait for the next render commit.\n // We would risk displaying two tooltips at the same time (native + this one).\n if (childNode) {\n childNode.removeAttribute('title');\n }\n enterTimer.clear();\n leaveTimer.clear();\n if (enterDelay || hystersisOpen && enterNextDelay) {\n enterTimer.start(hystersisOpen ? enterNextDelay : enterDelay, () => {\n handleOpen(event);\n });\n } else {\n handleOpen(event);\n }\n };\n const handleLeave = event => {\n enterTimer.clear();\n leaveTimer.start(leaveDelay, () => {\n handleClose(event);\n });\n };\n const {\n isFocusVisibleRef,\n onBlur: handleBlurVisible,\n onFocus: handleFocusVisible,\n ref: focusVisibleRef\n } = useIsFocusVisible();\n // We don't necessarily care about the focusVisible state (which is safe to access via ref anyway).\n // We just need to re-render the Tooltip if the focus-visible state changes.\n const [, setChildIsFocusVisible] = React.useState(false);\n const handleBlur = event => {\n handleBlurVisible(event);\n if (isFocusVisibleRef.current === false) {\n setChildIsFocusVisible(false);\n handleLeave(event);\n }\n };\n const handleFocus = event => {\n // Workaround for https://github.com/facebook/react/issues/7769\n // The autoFocus of React might trigger the event before the componentDidMount.\n // We need to account for this eventuality.\n if (!childNode) {\n setChildNode(event.currentTarget);\n }\n handleFocusVisible(event);\n if (isFocusVisibleRef.current === true) {\n setChildIsFocusVisible(true);\n handleEnter(event);\n }\n };\n const detectTouchStart = event => {\n ignoreNonTouchEvents.current = true;\n const childrenProps = children.props;\n if (childrenProps.onTouchStart) {\n childrenProps.onTouchStart(event);\n }\n };\n const handleMouseOver = handleEnter;\n const handleMouseLeave = handleLeave;\n const handleTouchStart = event => {\n detectTouchStart(event);\n leaveTimer.clear();\n closeTimer.clear();\n stopTouchInteraction();\n prevUserSelect.current = document.body.style.WebkitUserSelect;\n // Prevent iOS text selection on long-tap.\n document.body.style.WebkitUserSelect = 'none';\n touchTimer.start(enterTouchDelay, () => {\n document.body.style.WebkitUserSelect = prevUserSelect.current;\n handleEnter(event);\n });\n };\n const handleTouchEnd = event => {\n if (children.props.onTouchEnd) {\n children.props.onTouchEnd(event);\n }\n stopTouchInteraction();\n leaveTimer.start(leaveTouchDelay, () => {\n handleClose(event);\n });\n };\n React.useEffect(() => {\n if (!open) {\n return undefined;\n }\n\n /**\n * @param {KeyboardEvent} nativeEvent\n */\n function handleKeyDown(nativeEvent) {\n // IE11, Edge (prior to using Bink?) use 'Esc'\n if (nativeEvent.key === 'Escape' || nativeEvent.key === 'Esc') {\n handleClose(nativeEvent);\n }\n }\n document.addEventListener('keydown', handleKeyDown);\n return () => {\n document.removeEventListener('keydown', handleKeyDown);\n };\n }, [handleClose, open]);\n const handleRef = useForkRef(children.ref, focusVisibleRef, setChildNode, ref);\n\n // There is no point in displaying an empty tooltip.\n // So we exclude all falsy values, except 0, which is valid.\n if (!title && title !== 0) {\n open = false;\n }\n const popperRef = React.useRef();\n const handleMouseMove = event => {\n const childrenProps = children.props;\n if (childrenProps.onMouseMove) {\n childrenProps.onMouseMove(event);\n }\n cursorPosition = {\n x: event.clientX,\n y: event.clientY\n };\n if (popperRef.current) {\n popperRef.current.update();\n }\n };\n const nameOrDescProps = {};\n const titleIsString = typeof title === 'string';\n if (describeChild) {\n nameOrDescProps.title = !open && titleIsString && !disableHoverListener ? title : null;\n nameOrDescProps['aria-describedby'] = open ? id : null;\n } else {\n nameOrDescProps['aria-label'] = titleIsString ? title : null;\n nameOrDescProps['aria-labelledby'] = open && !titleIsString ? id : null;\n }\n const childrenProps = _extends({}, nameOrDescProps, other, children.props, {\n className: clsx(other.className, children.props.className),\n onTouchStart: detectTouchStart,\n ref: handleRef\n }, followCursor ? {\n onMouseMove: handleMouseMove\n } : {});\n if (process.env.NODE_ENV !== 'production') {\n childrenProps['data-mui-internal-clone-element'] = true;\n\n // eslint-disable-next-line react-hooks/rules-of-hooks\n React.useEffect(() => {\n if (childNode && !childNode.getAttribute('data-mui-internal-clone-element')) {\n console.error(['MUI: The `children` component of the Tooltip is not forwarding its props correctly.', 'Please make sure that props are spread on the same element that the ref is applied to.'].join('\\n'));\n }\n }, [childNode]);\n }\n const interactiveWrapperListeners = {};\n if (!disableTouchListener) {\n childrenProps.onTouchStart = handleTouchStart;\n childrenProps.onTouchEnd = handleTouchEnd;\n }\n if (!disableHoverListener) {\n childrenProps.onMouseOver = composeEventHandler(handleMouseOver, childrenProps.onMouseOver);\n childrenProps.onMouseLeave = composeEventHandler(handleMouseLeave, childrenProps.onMouseLeave);\n if (!disableInteractive) {\n interactiveWrapperListeners.onMouseOver = handleMouseOver;\n interactiveWrapperListeners.onMouseLeave = handleMouseLeave;\n }\n }\n if (!disableFocusListener) {\n childrenProps.onFocus = composeEventHandler(handleFocus, childrenProps.onFocus);\n childrenProps.onBlur = composeEventHandler(handleBlur, childrenProps.onBlur);\n if (!disableInteractive) {\n interactiveWrapperListeners.onFocus = handleFocus;\n interactiveWrapperListeners.onBlur = handleBlur;\n }\n }\n if (process.env.NODE_ENV !== 'production') {\n if (children.props.title) {\n console.error(['MUI: You have provided a `title` prop to the child of .', `Remove this title prop \\`${children.props.title}\\` or the Tooltip component.`].join('\\n'));\n }\n }\n const popperOptions = React.useMemo(() => {\n var _PopperProps$popperOp;\n let tooltipModifiers = [{\n name: 'arrow',\n enabled: Boolean(arrowRef),\n options: {\n element: arrowRef,\n padding: 4\n }\n }];\n if ((_PopperProps$popperOp = PopperProps.popperOptions) != null && _PopperProps$popperOp.modifiers) {\n tooltipModifiers = tooltipModifiers.concat(PopperProps.popperOptions.modifiers);\n }\n return _extends({}, PopperProps.popperOptions, {\n modifiers: tooltipModifiers\n });\n }, [arrowRef, PopperProps]);\n const ownerState = _extends({}, props, {\n isRtl,\n arrow,\n disableInteractive,\n placement,\n PopperComponentProp,\n touch: ignoreNonTouchEvents.current\n });\n const classes = useUtilityClasses(ownerState);\n const PopperComponent = (_ref = (_slots$popper = slots.popper) != null ? _slots$popper : components.Popper) != null ? _ref : TooltipPopper;\n const TransitionComponent = (_ref2 = (_ref3 = (_slots$transition = slots.transition) != null ? _slots$transition : components.Transition) != null ? _ref3 : TransitionComponentProp) != null ? _ref2 : Grow;\n const TooltipComponent = (_ref4 = (_slots$tooltip = slots.tooltip) != null ? _slots$tooltip : components.Tooltip) != null ? _ref4 : TooltipTooltip;\n const ArrowComponent = (_ref5 = (_slots$arrow = slots.arrow) != null ? _slots$arrow : components.Arrow) != null ? _ref5 : TooltipArrow;\n const popperProps = appendOwnerState(PopperComponent, _extends({}, PopperProps, (_slotProps$popper = slotProps.popper) != null ? _slotProps$popper : componentsProps.popper, {\n className: clsx(classes.popper, PopperProps == null ? void 0 : PopperProps.className, (_ref6 = (_slotProps$popper2 = slotProps.popper) != null ? _slotProps$popper2 : componentsProps.popper) == null ? void 0 : _ref6.className)\n }), ownerState);\n const transitionProps = appendOwnerState(TransitionComponent, _extends({}, TransitionProps, (_slotProps$transition = slotProps.transition) != null ? _slotProps$transition : componentsProps.transition), ownerState);\n const tooltipProps = appendOwnerState(TooltipComponent, _extends({}, (_slotProps$tooltip = slotProps.tooltip) != null ? _slotProps$tooltip : componentsProps.tooltip, {\n className: clsx(classes.tooltip, (_ref7 = (_slotProps$tooltip2 = slotProps.tooltip) != null ? _slotProps$tooltip2 : componentsProps.tooltip) == null ? void 0 : _ref7.className)\n }), ownerState);\n const tooltipArrowProps = appendOwnerState(ArrowComponent, _extends({}, (_slotProps$arrow = slotProps.arrow) != null ? _slotProps$arrow : componentsProps.arrow, {\n className: clsx(classes.arrow, (_ref8 = (_slotProps$arrow2 = slotProps.arrow) != null ? _slotProps$arrow2 : componentsProps.arrow) == null ? void 0 : _ref8.className)\n }), ownerState);\n return /*#__PURE__*/_jsxs(React.Fragment, {\n children: [/*#__PURE__*/React.cloneElement(children, childrenProps), /*#__PURE__*/_jsx(PopperComponent, _extends({\n as: PopperComponentProp != null ? PopperComponentProp : Popper,\n placement: placement,\n anchorEl: followCursor ? {\n getBoundingClientRect: () => ({\n top: cursorPosition.y,\n left: cursorPosition.x,\n right: cursorPosition.x,\n bottom: cursorPosition.y,\n width: 0,\n height: 0\n })\n } : childNode,\n popperRef: popperRef,\n open: childNode ? open : false,\n id: id,\n transition: true\n }, interactiveWrapperListeners, popperProps, {\n popperOptions: popperOptions,\n children: ({\n TransitionProps: TransitionPropsInner\n }) => /*#__PURE__*/_jsx(TransitionComponent, _extends({\n timeout: theme.transitions.duration.shorter\n }, TransitionPropsInner, transitionProps, {\n children: /*#__PURE__*/_jsxs(TooltipComponent, _extends({}, tooltipProps, {\n children: [title, arrow ? /*#__PURE__*/_jsx(ArrowComponent, _extends({}, tooltipArrowProps, {\n ref: setArrowRef\n })) : null]\n }))\n }))\n }))]\n });\n});\nprocess.env.NODE_ENV !== \"production\" ? Tooltip.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the d.ts file and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * If `true`, adds an arrow to the tooltip.\n * @default false\n */\n arrow: PropTypes.bool,\n /**\n * Tooltip reference element.\n */\n children: elementAcceptingRef.isRequired,\n /**\n * Override or extend the styles applied to the component.\n */\n classes: PropTypes.object,\n /**\n * @ignore\n */\n className: PropTypes.string,\n /**\n * The components used for each slot inside.\n *\n * This prop is an alias for the `slots` prop.\n * It's recommended to use the `slots` prop instead.\n *\n * @default {}\n */\n components: PropTypes.shape({\n Arrow: PropTypes.elementType,\n Popper: PropTypes.elementType,\n Tooltip: PropTypes.elementType,\n Transition: PropTypes.elementType\n }),\n /**\n * The extra props for the slot components.\n * You can override the existing props or add new ones.\n *\n * This prop is an alias for the `slotProps` prop.\n * It's recommended to use the `slotProps` prop instead, as `componentsProps` will be deprecated in the future.\n *\n * @default {}\n */\n componentsProps: PropTypes.shape({\n arrow: PropTypes.object,\n popper: PropTypes.object,\n tooltip: PropTypes.object,\n transition: PropTypes.object\n }),\n /**\n * Set to `true` if the `title` acts as an accessible description.\n * By default the `title` acts as an accessible label for the child.\n * @default false\n */\n describeChild: PropTypes.bool,\n /**\n * Do not respond to focus-visible events.\n * @default false\n */\n disableFocusListener: PropTypes.bool,\n /**\n * Do not respond to hover events.\n * @default false\n */\n disableHoverListener: PropTypes.bool,\n /**\n * Makes a tooltip not interactive, i.e. it will close when the user\n * hovers over the tooltip before the `leaveDelay` is expired.\n * @default false\n */\n disableInteractive: PropTypes.bool,\n /**\n * Do not respond to long press touch events.\n * @default false\n */\n disableTouchListener: PropTypes.bool,\n /**\n * The number of milliseconds to wait before showing the tooltip.\n * This prop won't impact the enter touch delay (`enterTouchDelay`).\n * @default 100\n */\n enterDelay: PropTypes.number,\n /**\n * The number of milliseconds to wait before showing the tooltip when one was already recently opened.\n * @default 0\n */\n enterNextDelay: PropTypes.number,\n /**\n * The number of milliseconds a user must touch the element before showing the tooltip.\n * @default 700\n */\n enterTouchDelay: PropTypes.number,\n /**\n * If `true`, the tooltip follow the cursor over the wrapped element.\n * @default false\n */\n followCursor: PropTypes.bool,\n /**\n * This prop is used to help implement the accessibility logic.\n * If you don't provide this prop. It falls back to a randomly generated id.\n */\n id: PropTypes.string,\n /**\n * The number of milliseconds to wait before hiding the tooltip.\n * This prop won't impact the leave touch delay (`leaveTouchDelay`).\n * @default 0\n */\n leaveDelay: PropTypes.number,\n /**\n * The number of milliseconds after the user stops touching an element before hiding the tooltip.\n * @default 1500\n */\n leaveTouchDelay: PropTypes.number,\n /**\n * Callback fired when the component requests to be closed.\n *\n * @param {React.SyntheticEvent} event The event source of the callback.\n */\n onClose: PropTypes.func,\n /**\n * Callback fired when the component requests to be open.\n *\n * @param {React.SyntheticEvent} event The event source of the callback.\n */\n onOpen: PropTypes.func,\n /**\n * If `true`, the component is shown.\n */\n open: PropTypes.bool,\n /**\n * Tooltip placement.\n * @default 'bottom'\n */\n placement: PropTypes.oneOf(['bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n /**\n * The component used for the popper.\n * @default Popper\n */\n PopperComponent: PropTypes.elementType,\n /**\n * Props applied to the [`Popper`](/material-ui/api/popper/) element.\n * @default {}\n */\n PopperProps: PropTypes.object,\n /**\n * The extra props for the slot components.\n * You can override the existing props or add new ones.\n *\n * This prop is an alias for the `componentsProps` prop, which will be deprecated in the future.\n *\n * @default {}\n */\n slotProps: PropTypes.shape({\n arrow: PropTypes.object,\n popper: PropTypes.object,\n tooltip: PropTypes.object,\n transition: PropTypes.object\n }),\n /**\n * The components used for each slot inside.\n *\n * This prop is an alias for the `components` prop, which will be deprecated in the future.\n *\n * @default {}\n */\n slots: PropTypes.shape({\n arrow: PropTypes.elementType,\n popper: PropTypes.elementType,\n tooltip: PropTypes.elementType,\n transition: PropTypes.elementType\n }),\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Tooltip title. Zero-length titles string, undefined, null and false are never displayed.\n */\n title: PropTypes.node,\n /**\n * The component used for the transition.\n * [Follow this guide](/material-ui/transitions/#transitioncomponent-prop) to learn more about the requirements for this component.\n * @default Grow\n */\n TransitionComponent: PropTypes.elementType,\n /**\n * Props applied to the transition element.\n * By default, the element is based on this [`Transition`](http://reactcommunity.org/react-transition-group/transition/) component.\n */\n TransitionProps: PropTypes.object\n} : void 0;\nexport default Tooltip;","import '@/components/mui/menu-item.component.css';\nimport ArrowRightIcon from '@mui/icons-material/ArrowRight';\nimport {\n ListItemIcon as MuiListItemIcon,\n ListItemText as MuiListItemText,\n MenuItem as MuiMenuItem,\n} from '@mui/material';\nimport Tooltip from '@mui/material/Tooltip';\nimport { Localized, ReferencedItem, SingleColumnMenu } from 'platform-bible-utils';\nimport { MouseEvent, PropsWithChildren } from 'react';\n\ntype MenuItemInfoBase = {\n /** Text (displayable in the UI) as the name of the menu item */\n label: string;\n /** Text to display when the mouse hovers over the menu item */\n tooltip?: string;\n};\n\nexport type Command = MenuItemInfoBase & {\n /** Command to execute (string.string) */\n command: string;\n};\n\ntype SubMenu = MenuItemInfoBase & {\n /** Command to execute (string.string) */\n items: MenuItemInfo[];\n};\n\nexport interface CommandHandler {\n (command: Command): void;\n}\n\nexport type MenuPropsBase = {\n /*\n * The JSON defining the menu whose items are to be rendered. This will typically be one of the\n * menus in the \"defs\" in a Platform.Bible menu (see PlatformMenus). The schema for this is\n * menuDocumentSchema (at the end of menus.model.ts). Note that while this is a\n * \"SingleColumnMenu\", somewhat bizarrely, a MultiColumnMenu is a SingleColumnMenu, so it really\n * could be a MultiColumnMenu, in which case, column had better be defined so it can be used\n * to filter out the actual groups and items to display on the column.\n */\n menuDefinition: Localized;\n\n commandHandler: CommandHandler;\n\n /**\n * Additional action to perform when any menu item is clicked. Allows the caller to handle event\n * (e.g., to close the menu).\n */\n onClick?: (event: MouseEvent) => void;\n};\n\nexport type MenuItemListProps = MenuPropsBase & {\n /** Optional unique (column) identifier */\n columnId?: ReferencedItem;\n};\n\nexport type MenuItemProps = Omit &\n PropsWithChildren<{\n /** Optional unique identifier */\n id?: string;\n\n onClick: (event: MouseEvent) => void;\n }>;\n\ntype MenuItemInfo = (Command | SubMenu) & {\n /**\n * If specified, menu item will be inset if it does not have a leading icon.\n *\n * @default true\n */\n allowForLeadingIcons?: boolean;\n /**\n * If specified, the path to the icon image to display on the leading side of the menu text.\n *\n * @default undefined (no leading icon will be shown)\n */\n iconPathBefore?: string;\n /**\n * If specified, the path to the icon image to display on the trailing side of the menu text.\n *\n * @default undefined (no trailing icon will be shown)\n */\n iconPathAfter?: string;\n /**\n * If true, list item is focused during the first mount\n *\n * @default false\n */\n hasAutoFocus?: boolean;\n\n /** Additional css classes to help with unique styling of the menu item */\n className?: string;\n\n /**\n * If true, the menu item will appear disabled and it will not respond to clicks or mouse hovers.\n *\n * @default false\n */\n isDisabled?: boolean;\n\n /**\n * If true, compact vertical padding designed for keyboard and mouse input is used.\n *\n * @default true\n */\n isDense?: boolean;\n\n /**\n * If true, a right-arrow icon will be displayed (iconPathAfter, if specified, will be ignored).\n *\n * @default false\n */\n isSubMenuParent?: boolean;\n\n /**\n * If true, the left and right padding is removed\n *\n * @default false\n */\n hasDisabledGutters?: boolean;\n\n /**\n * If true, a 1px light border is added to bottom of menu item\n *\n * @default false\n */\n hasDivider?: boolean;\n\n /** Help identify which element has keyboard focus */\n focusVisibleClassName?: string;\n\n /** If it's a submenu, it should have the items property */\n items?: MenuItemInfo[];\n};\n\nfunction getIcon(icon: string | undefined, menuLabel: string, leading: boolean) {\n return icon ? (\n \n {`${leading\n \n ) : undefined;\n}\n\nexport default function MenuItem(props: MenuItemProps) {\n const {\n onClick,\n label,\n tooltip,\n allowForLeadingIcons = true,\n iconPathBefore = undefined,\n iconPathAfter = undefined,\n hasAutoFocus = false,\n className,\n isDisabled = false,\n isDense = true,\n isSubMenuParent = false,\n hasDisabledGutters = false,\n hasDivider = false,\n focusVisibleClassName,\n id,\n children,\n } = props;\n\n const menuItem = (\n \n {label ? (\n <>\n {getIcon(iconPathBefore, label, true)}\n \n {isSubMenuParent ? (\n \n \n \n ) : (\n getIcon(iconPathAfter, label, false)\n )}\n \n ) : (\n children\n )}\n \n );\n\n return tooltip ? (\n \n
    {menuItem}
    \n
    \n ) : (\n menuItem\n );\n}\n","import MenuItem, {\n MenuItemListProps,\n MenuItemProps,\n MenuPropsBase,\n} from '@/components/mui/menu-item.component';\nimport { Menu } from '@mui/material';\nimport {\n Localized,\n MenuGroupDetailsInSubMenu,\n MenuItemContainingCommand,\n MenuItemContainingSubmenu,\n OrderedExtensibleContainer,\n ReferencedItem,\n SingleColumnMenu,\n} from 'platform-bible-utils';\nimport { MouseEvent, useMemo, useState } from 'react';\n\n/**\n * All the exported types in this file should be regarded as \"internal\" (i.e., they should not be\n * exposed via index.ts).\n */\n\nexport type GroupedMenuPropsBase = MenuPropsBase & {\n /** Optional unique (column) identifier */\n columnId?: ReferencedItem;\n};\n\nexport type GroupedMenuItemListProps = MenuItemListProps & {\n /**\n * If the menuDefinition includes \"top-level\" groups (i.e., those that belong to a column as\n * opposed to those that belong to a submenu) that should not be included in the list, then this\n * array specifies which groups to include. Likewise, for a submenu, this list indicates which\n * groups are pertinent for that submenu. So then for a context menu this property need not be\n * specified since it is a top-level menu based on a \"true\" SingleColumnMenu (i.e., one that is\n * not a MultiColumnMenu).\n */\n includedGroups?: {\n id: string;\n group: Localized;\n }[];\n};\n\ninterface ItemInfo {\n item: Localized;\n isLastItemInGroup: boolean;\n}\n\ntype SubMenuProps = MenuPropsBase & {\n parentMenuItem: Localized;\n parentItemProps: Omit, 'iconPathAfter'>;\n};\n\nfunction getAllGroups(menuDefinition: Localized) {\n const groupEntries = Object.entries(menuDefinition.groups);\n // Convert array of entries to array of objects with id and group properties\n return groupEntries.map(([key, value]) => ({ id: key, group: value }));\n}\n\nfunction SubMenu(props: SubMenuProps) {\n const [anchorEl, setAnchorEl] = useState(undefined);\n\n const { parentMenuItem, parentItemProps, menuDefinition } = props;\n\n const handleParentMenuItemClick = (event: MouseEvent) => {\n setAnchorEl(event.currentTarget);\n };\n\n const handleClose = () => {\n setAnchorEl(undefined);\n };\n\n const renderSubMenuItems = () => {\n let includedGroups = getAllGroups(menuDefinition).filter((g) => 'menuItem' in g.group);\n\n // Ensure valid parent menu was provided. (If not, submenu will contain all groups!)\n if (!parentMenuItem?.id) throw new Error('A valid parent menu item is required for submenus.');\n\n // When laying out a submenu, only include groups associated with the provided parent menu.\n // Note: without the (annoying) redundant check that the included groups\n // have the menuItem field, TS doesn't think it exists.\n includedGroups = includedGroups.filter(\n (group) => 'menuItem' in group.group && group.group.menuItem === parentMenuItem.id,\n );\n\n return ;\n };\n\n return (\n <>\n \n \n {renderSubMenuItems()}\n \n \n );\n}\n\nconst getOrderedGroupItems = (\n groupId: string,\n allItems: Localized[],\n) => {\n // Filter items that belong to the specified group\n const itemsForGroup = allItems.filter((item) => item.group === groupId);\n // Sort items based on order\n const sortedItems = itemsForGroup.sort((a, b) => (a.order || 0) - (b.order || 0));\n return sortedItems;\n};\n\n/**\n * This component is internal; it does not need to be exposed to the outside world since it is not\n * useful on its own. It is used to generate and lay out the MenuItems that appear either on a\n * top-level menu (in a GridMenu or ContextMenu) or in a submenu.\n */\nexport default function GroupedMenuItemList(menuProps: GroupedMenuItemListProps) {\n const { menuDefinition, onClick, commandHandler, includedGroups } = menuProps;\n\n const { items, allowForLeadingIcons } = useMemo(() => {\n const groupsToInclude =\n includedGroups && includedGroups.length > 0\n ? includedGroups\n : // We're apparently laying out a single-column menu (presumably a context menu). In this\n // case, all groups should be included except ones that belong to a submenu.\n getAllGroups(menuDefinition).filter((g) => !('menuItem' in g.group));\n\n const sortedGroups = Object.values(groupsToInclude).sort(\n (a, b) => (a.group.order || 0) - (b.group.order || 0),\n );\n\n const itemArray: ItemInfo[] = [];\n\n sortedGroups.forEach((group) => {\n getOrderedGroupItems(group.id, menuDefinition.items).forEach((item) =>\n itemArray.push({ item, isLastItemInGroup: false }),\n );\n if (itemArray.length > 0) itemArray[itemArray.length - 1].isLastItemInGroup = true;\n });\n\n // No divider after last item in final group.\n if (itemArray.length > 0) itemArray[itemArray.length - 1].isLastItemInGroup = false;\n\n const allowSpaceForLeadingIcons = itemArray.some(\n (i) => 'iconPathBefore' in i.item && i.item.iconPathBefore,\n );\n\n return { items: itemArray, allowForLeadingIcons: allowSpaceForLeadingIcons };\n }, [includedGroups, menuDefinition]);\n\n // Create props for MenuItem component including setting hasDivider for the last item in a group\n const createMenuItemProps = ({ item, isLastItemInGroup }: ItemInfo) => {\n const menuItemProps = {\n className: 'papi-menu-item',\n label: item.label,\n tooltip: item.tooltip,\n iconPathBefore: 'iconPathBefore' in item ? item.iconPathBefore : undefined,\n iconPathAfter: 'iconPathAfter' in item ? item.iconPathAfter : undefined,\n hasDivider: isLastItemInGroup, // Set hasDivider to true for the last item in a group\n allowForLeadingIcons,\n };\n\n return menuItemProps;\n };\n\n const [firstItem] = items;\n\n if (!firstItem) return
    ;\n\n const divKey = firstItem.item.group;\n\n return (\n
    \n {items.map((itemInfo, index) => {\n const { item } = itemInfo;\n const menuItemProps = createMenuItemProps(itemInfo);\n if ('command' in item) {\n const key = item.group + index;\n return (\n ) => {\n onClick?.(event);\n commandHandler(item);\n }}\n {...menuItemProps}\n />\n );\n }\n return (\n \n );\n })}\n
    \n );\n}\n","import GroupedMenuItemList from '@/components/mui/grouped-menu-item-list.component';\nimport { MenuItemListProps } from '@/components/mui/menu-item.component';\nimport { MultiColumnMenu } from 'platform-bible-utils';\n\n/**\n * This component is internal; it does not need to be exposed to the outside world since it is not\n * useful on its own. Use either GridMenu or ContextMenu.\n */\nexport default function TopLevelMenu(props: MenuItemListProps) {\n const { menuDefinition, columnId } = props;\n\n const groupEntries = Object.entries(menuDefinition.groups);\n // Convert array of entries to array of objects with id and group properties\n const groups = groupEntries.map(([key, value]) => ({ id: key, group: value }));\n let includedGroups = groups.filter((g) => 'column' in g.group);\n\n // Check if column is provided and menuDefinition is a MultiColumnMenu\n if (\n columnId &&\n 'columns' in menuDefinition &&\n // Without this type assertion, TS doesn't know what columns is.\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n (menuDefinition as MultiColumnMenu).columns[columnId]\n ) {\n // When laying out a single column in a MultiColumnMenu, only include groups associated with\n // the provided column. Note: without the (annoying) redundant check that the included groups\n // have the colum field, TS doesn't think it exists.\n includedGroups = includedGroups.filter(\n (g) => 'column' in g.group && g.group.column === columnId,\n );\n }\n\n return ;\n}\n","import '@/components/mui/grid-menu.component.css';\nimport { GroupedMenuPropsBase } from '@/components/mui/grouped-menu-item-list.component';\nimport { CommandHandler } from '@/components/mui/menu-item.component';\nimport TopLevelMenu from '@/components/mui/top-level-menu.component';\nimport { Grid, List } from '@mui/material';\nimport {\n Localized,\n MenuColumnWithHeader,\n MultiColumnMenu,\n ReferencedItem,\n} from 'platform-bible-utils';\nimport { useMemo } from 'react';\n\ntype ColumnInfo = {\n /*\n * The ID (`${string}.${string}`) of a specific menu column.\n */\n id: ReferencedItem;\n\n /*\n * Metadata (label, order, etc.) for a specific menu column.\n */\n metadata: Localized;\n};\n\ntype MenuColumnProps = ColumnInfo &\n GroupedMenuPropsBase & {\n /** Additional css classes to help with unique styling of the menu column */\n className?: string;\n };\n\nexport type GridMenuInfo = {\n /** The menu object containing information about the columns, groups, and items to display. */\n multiColumnMenu: Localized;\n};\n\nexport type GridMenuProps = GridMenuInfo & {\n /** Optional unique identifier */\n id?: string;\n\n commandHandler: CommandHandler;\n\n /** Additional css classes to help with unique styling of the grid menu */\n className?: string;\n};\n\nfunction MenuColumn({\n commandHandler,\n menuDefinition,\n id,\n metadata,\n onClick,\n className,\n}: MenuColumnProps) {\n return (\n \n

    \n {metadata.label}\n

    \n {/* It would seem as though this List component were unnecessary, since it only contains one\n thing, but the \"dense\" property does affect the layout of the items (in a way I don't fully\n understand). There might be a better way. */}\n \n \n \n \n );\n}\n\nexport default function GridMenu({\n commandHandler,\n className,\n multiColumnMenu,\n id,\n}: GridMenuProps) {\n const { columns } = multiColumnMenu;\n\n const sortedColumns = useMemo(() => {\n const columnNumbers = new Map();\n Object.getOwnPropertyNames(columns).forEach((columnName: string) => {\n // We know for sure there is a (boolean) property 'isExtensible' that we are not interested in.\n if (columnName === 'isExtensible') return;\n // TS doesn't allow `columnName` above to be a ReferencedItem even though the type says it is\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const columnId = columnName as ReferencedItem;\n const column = columns[columnId];\n // As of right now (and hopefully forever after), all remaining properties of the\n // ColumnsWithHeaders object are columns whose property names are the IDs of the columns.\n // This is an additional (redundant) sanity check. Specifically we're interested in\n // MenuColumnWithHeader objects, which TypeScript now \"knows\" we have, but at runtime all we\n // can check for is that it's an object with a valid numeric order field. That's likely good\n // enough.\n if (\n typeof column === 'object' &&\n typeof column.order === 'number' &&\n !Number.isNaN(column.order)\n )\n columnNumbers.set(column.order, { id: columnId, metadata: column });\n else\n console.warn(\n `Property ${columnName} (${typeof column}) on menu ${id} is not a valid column and is being ignored. This might indicate data corruption`,\n );\n });\n\n // Extract values and sort them based on the 'order' property\n return Array.from(columnNumbers.values()).sort((a, b) => {\n return (a.metadata.order || 0) - (b.metadata.order || 0);\n });\n }, [columns, id]);\n\n // We might need something like this if we need to be able to prevent empty columns\n // sortedColumns.filter((c) => multiColumnMenu.groups.some((g) => 'column' in g && (g as .column)...\n\n return (\n \n {sortedColumns.map((col, index) => (\n \n ))}\n \n );\n}\n","import { useEffect, useRef, useState } from 'react';\n\nexport type UsePromiseOptions = {\n /**\n * Whether to leave the value as the most recent resolved promise value or set it back to\n * defaultValue while running the promise again. Defaults to true\n */\n preserveValue?: boolean;\n};\n\n/** Set up defaults for options for usePromise hook */\nfunction getUsePromiseOptionsDefaults(options: UsePromiseOptions): UsePromiseOptions {\n return {\n preserveValue: true,\n ...options,\n };\n}\n\n/**\n * Awaits a promise and returns a loading value while the promise is unresolved\n *\n * @param promiseFactoryCallback A function that returns the promise to await. If this callback is\n * undefined, the current value will be returned (defaultValue unless it was previously changed\n * and `options.preserveValue` is true), and there will be no loading.\n *\n * WARNING: MUST BE STABLE - const or wrapped in useCallback. The reference must not be updated\n * every render\n * @param defaultValue The initial value to return while first awaiting the promise. If\n * `options.preserveValue` is false, this value is also shown while awaiting the promise on\n * subsequent calls.\n *\n * Note: this parameter is internally assigned to a `ref`, so changing it will not cause any hooks\n * to re-run with its new value. This means that, if the `promiseFactoryCallback` changes and\n * `options.preserveValue` is `false`, the returned value will be set to the current\n * `defaultValue`. However, the returned value will not be updated if`defaultValue` changes.\n * @param options Various options for adjusting how this hook runs the `promiseFactoryCallback`\n *\n * Note: this parameter is internally assigned to a `ref`, so changing it will not cause any hooks\n * to re-run with its new value. However, the latest `options.preserveValue` will always be used\n * appropriately to determine whether to preserve the returned value when changing the\n * `promiseFactoryCallback`\n * @returns `[value, isLoading]`\n *\n * - `value`: the current value for the promise, either the defaultValue or the resolved promise value\n * - `isLoading`: whether the promise is waiting to be resolved\n */\nconst usePromise = (\n promiseFactoryCallback: (() => Promise) | undefined,\n defaultValue: T,\n options: UsePromiseOptions = {},\n): [value: T, isLoading: boolean] => {\n // Use defaultValue as a ref so it doesn't update dependency arrays\n const defaultValueRef = useRef(defaultValue);\n defaultValueRef.current = defaultValue;\n // Use options as a ref so it doesn't update dependency arrays\n const optionsDefaultedRef = useRef(options);\n optionsDefaultedRef.current = getUsePromiseOptionsDefaults(optionsDefaultedRef.current);\n\n const [value, setValue] = useState(() => defaultValueRef.current);\n const [isLoading, setIsLoading] = useState(true);\n useEffect(() => {\n let promiseIsCurrent = true;\n // If a promiseFactoryCallback was provided, we are loading. Otherwise, there is no loading to do\n setIsLoading(!!promiseFactoryCallback);\n (async () => {\n // If there is a callback to run, run it\n if (promiseFactoryCallback) {\n const result = await promiseFactoryCallback();\n // If the promise was not already replaced, update the value\n if (promiseIsCurrent) {\n setValue(() => result);\n setIsLoading(false);\n }\n }\n })();\n\n return () => {\n // Mark this promise as old and not to be used\n promiseIsCurrent = false;\n if (!optionsDefaultedRef.current.preserveValue) setValue(() => defaultValueRef.current);\n };\n }, [promiseFactoryCallback]);\n\n return [value, isLoading];\n};\nexport default usePromise;\n","\"use client\";\n\nimport createSvgIcon from './utils/createSvgIcon';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nexport default createSvgIcon( /*#__PURE__*/_jsx(\"path\", {\n d: \"M3 18h18v-2H3zm0-5h18v-2H3zm0-7v2h18V6z\"\n}), 'Menu');","import GridMenu from '@/components/mui/grid-menu.component';\nimport { Command, CommandHandler } from '@/components/mui/menu-item.component';\nimport usePromise from '@/hooks/use-promise.hook';\nimport { Menu as MenuIcon } from '@mui/icons-material';\nimport { Drawer, IconButton } from '@mui/material';\nimport { Localized, MultiColumnMenu } from 'platform-bible-utils';\nimport {\n MouseEvent,\n MutableRefObject,\n PropsWithChildren,\n useCallback,\n useEffect,\n useState,\n} from 'react';\n\nexport interface MultiColumnMenuProvider {\n (isSupportAndDevelopment: boolean): Promise>;\n}\n\nexport type HamburgerMenuButtonProps = PropsWithChildren & {\n /** The handler to use for menu commands (and eventually toolbar commands). */\n commandHandler: CommandHandler;\n\n /**\n * Optional reference to the \"div\" container that determines the where the menu should appear. If\n * not defined, then (1,1) used.\n */\n containerRef?: MutableRefObject;\n\n /**\n * The delegate to use to get the menu data. If not specified or if it returns undefined, the data\n * in normalMenu or fullMenu property will be used.\n */\n menuProvider?: MultiColumnMenuProvider;\n\n /**\n * The menu data to show when the menu is opened if the menuProvider property is not defined.\n * (This allows for a default or test-only static menu to be used.)\n */\n normalMenu?: Localized;\n\n /**\n * The menu data to show for \"full\" menu (when opened with the SHIFT key pressed) if the\n * menuProvider property is not defined. (This allows for a default or test-only static menu to be\n * used.)\n */\n fullMenu?: Localized;\n\n /** Additional css class(es) to help with unique styling of the sub-components */\n className?: string;\n\n /** Value to use as prefix for ARIA labels on interactive sub-components */\n ariaLabelPrefix?: string;\n};\n\nexport default function HamburgerMenuButton({\n menuProvider,\n normalMenu,\n fullMenu,\n commandHandler,\n containerRef,\n className,\n ariaLabelPrefix,\n children,\n}: HamburgerMenuButtonProps) {\n const [isMenuOpen, setMenuOpen] = useState(false);\n const [showFullMenu, setShowFullMenu] = useState(false);\n\n const handleMenuItemClick = useCallback(() => {\n if (isMenuOpen) setMenuOpen(false);\n setShowFullMenu(false);\n }, [isMenuOpen]);\n\n const handleMenuButtonClick = useCallback((e: MouseEvent) => {\n e.stopPropagation();\n setMenuOpen((prevIsOpen) => {\n const isOpening = !prevIsOpen;\n if (isOpening && e.shiftKey) setShowFullMenu(true);\n else if (!isOpening) setShowFullMenu(false);\n return isOpening;\n });\n }, []);\n\n const menuCommandHandler = useCallback(\n (command: Command) => {\n handleMenuItemClick();\n return commandHandler(command);\n },\n [commandHandler, handleMenuItemClick],\n );\n\n const [offset, setOffset] = useState({ top: 1, left: 1 });\n\n useEffect(() => {\n if (isMenuOpen) {\n const node = containerRef?.current;\n if (node) {\n const rect = node.getBoundingClientRect();\n const scrollTop = window.scrollY;\n const scrollLeft = window.scrollX;\n const top = rect.top + scrollTop + node.clientHeight;\n const left = rect.left + scrollLeft;\n setOffset({ top, left });\n }\n }\n }, [isMenuOpen, containerRef]);\n\n const [normalMenuData] = usePromise(\n useCallback(async () => {\n return menuProvider?.(false) ?? normalMenu;\n // isMenuOpen needs to be included for the menu contents to reevaluate when reopened\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [menuProvider, normalMenu, isMenuOpen]),\n normalMenu,\n );\n\n const [fullMenuData] = usePromise(\n useCallback(async () => {\n return menuProvider?.(true) ?? fullMenu ?? normalMenuData;\n // isMenuOpen needs to be included for the menu contents to reevaluate when reopened\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [menuProvider, fullMenu, normalMenuData, isMenuOpen]),\n fullMenu ?? normalMenuData,\n );\n\n const menu = showFullMenu && fullMenuData ? fullMenuData : normalMenuData;\n\n return (\n <>\n \n {children ?? }\n \n \n {menu ? (\n \n ) : undefined}\n \n \n );\n}\n","import '@/components/mui/icon-button.component.css';\nimport { IconButton as MuiIconButton } from '@mui/material';\nimport { MouseEventHandler, PropsWithChildren } from 'react';\n\nexport type IconButtonProps = PropsWithChildren<{\n /** Optional unique identifier */\n id?: string;\n /**\n * Required. Used as both the tooltip (aka, title) and the aria-label (used for accessibility,\n * testing, etc.), unless a distinct tooltip is supplied.\n */\n label: string;\n /**\n * Enabled status of button\n *\n * @default false\n */\n isDisabled?: boolean;\n /** Optional tooltip to display if different from the aria-label. */\n tooltip?: string;\n /** If true, no tooltip will be displayed. */\n isTooltipSuppressed?: boolean;\n /**\n * If given, uses a negative margin to counteract the padding on one side (this is often helpful\n * for aligning the left or right side of the icon with content above or below, without ruining\n * the border size and shape).\n *\n * @default false\n */\n adjustMarginToAlignToEdge?: 'end' | 'start' | false;\n /**\n * The size of the component. small is equivalent to the dense button styling.\n *\n * @default false\n */\n size: 'small' | 'medium' | 'large';\n /** Additional css classes to help with unique styling of the button */\n className?: string;\n /** Optional click handler */\n onClick?: MouseEventHandler;\n}>;\n\n/**\n * Iconic button a user can click to do something\n *\n * Thanks to MUI for heavy inspiration and documentation\n * https://mui.com/material-ui/getting-started/overview/\n */\nfunction IconButton({\n id,\n label,\n isDisabled = false,\n tooltip,\n isTooltipSuppressed = false,\n adjustMarginToAlignToEdge = false,\n size = 'medium',\n className,\n onClick,\n children,\n}: IconButtonProps) {\n return (\n \n {children /* the icon to display */}\n \n );\n}\n\nexport default IconButton;\n","import { cn } from '@/utils/shadcn-ui.util';\nimport { LoaderCircle, LucideProps } from 'lucide-react';\nimport { forwardRef } from 'react';\n\nexport type SpinnerProps = LucideProps;\n\nconst Spinner = forwardRef(({ className, ...props }, ref) => {\n return (\n \n );\n});\n\nSpinner.displayName = 'Spinner';\n\nexport default Spinner;\n","import { Input as ShadInput } from '@/components/shadcn-ui/input';\nimport { Label as ShadLabel } from '@/components/shadcn-ui/label';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { ChangeEventHandler, FocusEventHandler } from 'react';\n\nexport type TextFieldProps = {\n /** Optional unique identifier */\n id?: string;\n /**\n * If `true`, the component is disabled.\n *\n * @default false\n */\n isDisabled?: boolean;\n /**\n * If `true`, the label is displayed in an error state.\n *\n * @default false\n */\n hasError?: boolean;\n /**\n * If `true`, the input will take up the full width of its container.\n *\n * @default false\n */\n isFullWidth?: boolean;\n /** Text that gives the user instructions on what contents the TextField expects */\n helperText?: string;\n /** The title of the TextField */\n label?: string;\n /** The short hint displayed in the `input` before the user enters a value. */\n placeholder?: string;\n /**\n * If `true`, the label is displayed as required and the `input` element is required.\n *\n * @default false\n */\n isRequired?: boolean;\n /** Additional css classes to help with unique styling of the text field */\n className?: string;\n /** Starting value for the text field if it is not controlled */\n defaultValue?: string | number;\n /** Value of the text field if controlled */\n value?: string | number;\n /** Triggers when content of textfield is changed */\n onChange?: ChangeEventHandler;\n /** Triggers when textfield gets focus */\n onFocus?: FocusEventHandler;\n /** Triggers when textfield loses focus */\n onBlur?: FocusEventHandler;\n};\n\n/**\n * Text input field\n *\n * Thanks to Shadcn for heavy inspiration and documentation\n * https://ui.shadcn.com/docs/components/input#with-label\n */\nfunction TextField({\n id,\n isDisabled = false,\n hasError = false,\n isFullWidth = false,\n helperText,\n label,\n placeholder,\n isRequired = false,\n className,\n defaultValue,\n value,\n onChange,\n onFocus,\n onBlur,\n}: TextFieldProps) {\n return (\n
    \n {`${label}${isRequired ? '*' : ''}`}\n \n

    {helperText}

    \n
    \n );\n}\n\nexport default TextField;\n","import HamburgerMenuButton, {\n MultiColumnMenuProvider,\n} from '@/components/mui/hamburger-menu-button.component';\nimport { CommandHandler } from '@/components/mui/menu-item.component';\nimport '@/components/mui/toolbar.component.css';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { AppBar, Toolbar as MuiToolbar } from '@mui/material';\nimport { PropsWithChildren, useRef } from 'react';\n\nexport type ToolbarProps = PropsWithChildren<{\n /** The handler to use for menu commands (and eventually toolbar commands). */\n commandHandler: CommandHandler;\n\n /**\n * The optional delegate to use to get the menu data. If not specified, the \"hamburger\" menu will\n * not display.\n */\n menuProvider?: MultiColumnMenuProvider;\n\n /** Optional unique identifier */\n id?: string;\n\n /** Additional css classes to help with unique styling of the toolbar */\n className?: string;\n}>;\n\nexport default function Toolbar({\n menuProvider,\n commandHandler,\n className,\n id,\n children,\n}: ToolbarProps) {\n // This ref will always be defined\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const containerRef = useRef(undefined!);\n\n return (\n
    \n \n \n {menuProvider ? (\n \n ) : undefined}\n {children ?
    {children}
    : undefined}\n \n
    \n
    \n );\n}\n","import React from 'react';\nimport { cva, type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst alertVariants = cva(\n 'tw-relative tw-w-full tw-rounded-lg tw-border tw-p-4 [&>svg~*]:tw-pl-7 [&>svg+div]:tw-translate-y-[-3px] [&>svg]:tw-absolute [&>svg]:tw-left-4 [&>svg]:tw-top-4 [&>svg]:tw-text-foreground',\n {\n variants: {\n variant: {\n default: 'tw-bg-background tw-text-foreground',\n destructive:\n 'tw-border-destructive/50 tw-text-destructive dark:tw-border-destructive [&>svg]:tw-text-destructive',\n },\n },\n defaultVariants: {\n variant: 'default',\n },\n },\n);\n\nconst Alert = React.forwardRef<\n HTMLDivElement,\n React.HTMLAttributes & VariantProps\n>(({ className, variant, ...props }, ref) => (\n
    \n));\nAlert.displayName = 'Alert';\n\nconst AlertTitle = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n {/* added because of https://github.com/jsx-eslint/eslint-plugin-jsx-a11y/blob/main/docs/rules/heading-has-content.md */}\n {props.children}{' '}\n \n ),\n);\nAlertTitle.displayName = 'AlertTitle';\n\nconst AlertDescription = React.forwardRef<\n HTMLParagraphElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n
    \n));\nAlertDescription.displayName = 'AlertDescription';\n\nexport { Alert, AlertTitle, AlertDescription };\n","import React from 'react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Card = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nCard.displayName = 'Card';\n\nconst CardHeader = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nCardHeader.displayName = 'CardHeader';\n\nconst CardTitle = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n {/* added because of https://github.com/jsx-eslint/eslint-plugin-jsx-a11y/blob/main/docs/rules/heading-has-content.md */}\n {props.children}\n \n ),\n);\nCardTitle.displayName = 'CardTitle';\n\nconst CardDescription = React.forwardRef<\n HTMLParagraphElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n

    \n));\nCardDescription.displayName = 'CardDescription';\n\nconst CardContent = React.forwardRef>(\n ({ className, ...props }, ref) => (\n

    \n ),\n);\nCardContent.displayName = 'CardContent';\n\nconst CardFooter = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nCardFooter.displayName = 'CardFooter';\n\nexport { Card, CardHeader, CardFooter, CardTitle, CardDescription, CardContent };\n","import { ComponentProps } from 'react';\nimport { toast as sonner, Toaster } from 'sonner';\n\ntype SonnerProps = ComponentProps;\n\nfunction Sonner({ ...props }: SonnerProps) {\n return (\n \n );\n}\n\n// The re-export of the sonner function was added manually\nexport { Sonner, sonner };\n","import React from 'react';\nimport * as SliderPrimitive from '@radix-ui/react-slider';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Slider = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n \n \n \n));\nSlider.displayName = SliderPrimitive.Root.displayName;\n\nexport { Slider };\n","import React from 'react';\nimport * as SwitchPrimitives from '@radix-ui/react-switch';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Switch = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n));\nSwitch.displayName = SwitchPrimitives.Root.displayName;\n\nexport { Switch };\n","import React from 'react';\nimport * as TabsPrimitive from '@radix-ui/react-tabs';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport const Tabs = TabsPrimitive.Root;\n\nexport type TabsListProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport type TabsTriggerProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport type TabsContentProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport const TabsList = React.forwardRef<\n React.ElementRef,\n TabsListProps\n>(({ className, ...props }, ref) => (\n \n));\nTabsList.displayName = TabsPrimitive.List.displayName;\n\nexport const TabsTrigger = React.forwardRef<\n React.ElementRef,\n TabsTriggerProps\n>(({ className, ...props }, ref) => (\n \n));\nTabsTrigger.displayName = TabsPrimitive.Trigger.displayName;\n\nexport const TabsContent = React.forwardRef<\n React.ElementRef,\n TabsContentProps\n>(({ className, ...props }, ref) => (\n \n));\nTabsContent.displayName = TabsPrimitive.Content.displayName;\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Download } from 'lucide-react';\n\ntype InstallButtonProps = {\n /** The installing boolean value determines the state of the button. */\n isInstalling: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n /** Optional text for the button. */\n buttonText?: string;\n} & ButtonProps;\n\n/**\n * The InstallButton component is a button designed for initiating installs. It includes visuals for\n * active installing and idle states.\n *\n * @param isInstalling The installing boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @param buttonText Optional text for the button.\n * @returns A install button.\n */\nexport default function InstallButton({\n isInstalling,\n handleClick,\n buttonText,\n className,\n ...props\n}: InstallButtonProps) {\n return (\n \n {isInstalling ? (\n \n ) : (\n <>\n \n {buttonText}\n \n )}\n \n );\n}\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\n\ntype EnableButtonProps = {\n /** The enabling boolean value determines the state of the button. */\n isEnabling: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n} & ButtonProps;\n\n/**\n * The EnableButton component is a button designed for initiating enabling of downloads. It includes\n * visuals for active enabling and idle states.\n *\n * @param isEnabling The enabling boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @returns A button that can be used to enable.\n */\nexport default function EnableButton({\n isEnabling,\n handleClick,\n className,\n ...props\n}: EnableButtonProps) {\n return (\n \n {isEnabling ? (\n <>\n \n Enabling...\n \n ) : (\n 'Enable'\n )}\n \n );\n}\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\n\ntype DisableButtonProps = {\n /** The disabling boolean value determines the state of the button. */\n isDisabling: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n} & ButtonProps;\n\n/**\n * The DisableButton component is a button designed for initiating disabling of downloads. It\n * includes visuals for active disabling and idle states.\n *\n * @param isDisabling The disabling boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @returns A button that can be used to disable.\n */\nexport default function DisableButton({\n isDisabling,\n handleClick,\n className,\n ...props\n}: DisableButtonProps) {\n return (\n \n {isDisabling ? (\n <>\n \n Disabling...\n \n ) : (\n 'Disable'\n )}\n \n );\n}\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\n\ntype UpdateButtonProps = {\n /** The updating boolean value determines the state of the button. */\n isUpdating: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n} & ButtonProps;\n\n/**\n * The UpdateButton component is a button designed for initiating updates for downloaded extensions.\n * It includes visuals for active updating and idle states.\n *\n * @param isUpdating The updating boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @returns A button that can be used to update.\n */\nexport default function UpdateButton({\n isUpdating,\n handleClick,\n className,\n ...props\n}: UpdateButtonProps) {\n return (\n \n {isUpdating ? (\n <>\n \n Updating...\n \n ) : (\n 'Update'\n )}\n \n );\n}\n","import { cn } from '@/utils/shadcn-ui.util';\nimport Markdown, { MarkdownToJSX } from 'markdown-to-jsx';\nimport { useMemo } from 'react';\n\ninterface MarkdownRendererProps {\n /** Optional unique identifier */\n id?: string;\n /** The markdown string to render */\n markdown: string;\n className?: string;\n /**\n * The [`target` attribute for `a` html\n * tags](https://developer.mozilla.org/en-US/docs/Web/HTML/Element/a#target). Defaults to not\n * adding a `target` to `a` tags\n */\n anchorTarget?: string;\n}\n\n/**\n * This component renders markdown content given a markdown string. It uses typography styles from\n * the platform.\n *\n * @param markdown The markdown string to render.\n * @param id Optional unique identifier\n * @returns A div containing the rendered markdown content.\n */\nexport default function MarkdownRenderer({\n id,\n markdown,\n className,\n anchorTarget,\n}: MarkdownRendererProps) {\n const options: MarkdownToJSX.Options = useMemo(\n () => ({\n overrides: {\n a: {\n props: {\n target: anchorTarget,\n },\n },\n },\n }),\n [anchorTarget],\n );\n return (\n
    \n {markdown}\n
    \n );\n}\n","import { Filter, ChevronDown } from 'lucide-react';\nimport { forwardRef } from 'react';\nimport { Button } from '@/components/shadcn-ui/button';\n\n/**\n * The FilterButton component is a button designed for initiating filtering of data. It is designed\n * to be used with the dropdown menu. It uses forwardRef to pass the button to the dropdown trigger\n * asChild.\n *\n * @returns A button that can be used to filter.\n */\nconst FilterButton = forwardRef((props, ref) => {\n return (\n \n \n Filter\n \n \n );\n});\n\nexport default FilterButton;\n","import {\n DropdownMenu,\n DropdownMenuTrigger,\n DropdownMenuContent,\n DropdownMenuLabel,\n DropdownMenuGroup,\n DropdownMenuCheckboxItem,\n DropdownMenuRadioItem,\n DropdownMenuSeparator,\n} from '@/components/shadcn-ui/dropdown-menu';\nimport FilterButton from './buttons/filter-button.component';\n\nexport enum DropdownMenuItemType {\n Check,\n Radio,\n}\n\nexport type DropdownItem = {\n /** The label is the text that will be displayed on the dropdown item. */\n label: string;\n /** The itemType determines the DropdownMenuItemType type as either Check or Radio. */\n itemType: DropdownMenuItemType;\n /** The onClick function is called when the item is clicked. */\n onClick: () => void;\n};\n\nexport type DropdownGroup = {\n /**\n * The label is the text that will be displayed on the dropdown group. It is used to categorize\n * the items in the group.\n */\n label: string;\n /** The items array contains the items that will be displayed in the dropdown group */\n items: DropdownItem[];\n};\n\nexport type FilterDropdownProps = {\n /** Object unique identifier */\n id?: string;\n /** The groups array contains the groups that will be displayed in the dropdown */\n groups: DropdownGroup[];\n}; // TODO: extend the props later\n\n/**\n * The FilterDropdown component is a dropdown designed for filtering content. It includes groups of\n * items that can be checkboxes or radio items.\n *\n * @param id Optional unique identifier\n * @param groups The groups array contains the groups that will be displayed in the dropdown\n * @returns A filter dropdown.\n */\nexport default function FilterDropdown({ id, groups }: FilterDropdownProps) {\n return (\n
    \n {/* TODO: remove this once the DropDown Menu shadcn has an id prop */}\n \n \n \n \n \n {groups.map((group) => (\n
    \n {group.label}\n \n {group.items.map((item) => (\n
    \n {item.itemType === DropdownMenuItemType.Check ? (\n \n {item.label}\n \n ) : (\n \n {item.label}\n \n )}\n
    \n ))}\n
    \n \n
    \n ))}\n
    \n
    \n
    \n );\n}\n","interface NoExtensionsFoundProps {\n /** Optional unique identifier */\n id?: string;\n /** The message to display */\n message: string;\n}\n/**\n * This component displays a message to the user when no extensions are found in the marketplace.\n *\n * @param id Optional unique identifier\n * @param message The message to display.\n * @returns {JSX.Element} - Returns the message component that displays the message to the user.\n */\nexport default function NoExtensionsFound({ id, message }: NoExtensionsFoundProps) {\n return (\n
    \n
    \n

    {message}

    \n
    \n
    \n );\n}\n","import { CircleHelp, Link as LucideLink, User } from 'lucide-react';\nimport { NumberFormat } from 'platform-bible-utils';\n\n/** Interface that stores the parameters passed to the More Info component */\ninterface MoreInfoProps {\n /** Optional unique identifier */\n id?: string;\n /** The category of the extension */\n category: string;\n /** The number of downloads for the extension */\n downloads: Record;\n /** The languages supported by the extension */\n languages: string[];\n /** The URL to the more info page of the extension */\n moreInfoUrl: string;\n}\n/**\n * This component displays the more info section of the extension which includes the category,\n * number of downloads, languages, and links to the website and support\n *\n * @param id Optional unique identifier\n * @param category The category of the extension\n * @param downloads The number of downloads for the extension\n * @param languages The languages supported by the extension\n * @param moreInfoUrl The URL to the more info page of the extension\n * @returns {JSX.Element} - Returns the more info component that displays the category, number of\n * downloads, languages, and links to the website and support\n */\nexport default function MoreInfo({\n id,\n category,\n downloads,\n languages,\n moreInfoUrl,\n}: MoreInfoProps) {\n /**\n * This constant formats the number of downloads into a more readable format.\n *\n * @example 1000 -> 1K\n *\n * @example 1000000 -> 1M\n *\n * @returns The formatted number of downloads\n */\n const numberFormatted = new NumberFormat('en', {\n notation: 'compact',\n compactDisplay: 'short',\n }).format(Object.values(downloads).reduce((a: number, b: number) => a + b, 0));\n\n /** This function scrolls the window to the bottom of the page. */\n const handleScrollToBottom = () => {\n window.scrollTo(0, document.body.scrollHeight);\n };\n\n return (\n \n
    \n
    \n {category}\n
    \n CATEGORY\n
    \n
    \n
    \n
    \n \n {numberFormatted}\n
    \n USERS\n
    \n
    \n
    \n
    \n {languages.slice(0, 3).map((locale) => (\n \n {locale.toUpperCase()}\n \n ))}\n
    \n {languages.length > 3 && (\n handleScrollToBottom()}\n className=\"tw-text-xs tw-text-gray-500 tw-underline\"\n >\n +{languages.length - 3} more languages\n \n )}\n
    \n
    \n
    \n \n Website\n \n \n \n Support\n \n \n
    \n
    \n );\n}\n","import { useState } from 'react';\n\nexport type VersionInformation = {\n /** Date the version was published */\n date: string;\n /** Description of the changes in the version */\n description: string;\n};\n\n/** Type to store the version history information */\nexport type VersionHistoryType = Record;\n\n/** Interface that stores the parameters passed to the Version History component */\ninterface VersionHistoryProps {\n /** Optional unique identifier */\n id?: string;\n /** Object containing the versions mapped with their information */\n versionHistory: VersionHistoryType;\n}\n\n/**\n * Component to render the version history information shown in the footer component. Lists the 5\n * most recent versions, with the options to show all versions by pressing a button.\n *\n * @param versionHistory Object containing the versions mapped with their information\n * @param id Optional unique identifier\n * @returns Rendered version history for the Footer component\n */\nexport default function VersionHistory({ id, versionHistory }: VersionHistoryProps) {\n const [showAllVersions, setShowAllVersions] = useState(false);\n const currentDate = new Date();\n\n /**\n * Function to format the time string for the version history in the form of 'X year(s) ago'.\n *\n * @param dateString ISO Date string to determine the time string from\n * @returns Formatted time string\n */\n function formatTimeString(dateString: string) {\n const date = new Date(dateString);\n const dateDiff = new Date(currentDate.getTime() - date.getTime());\n const yearDiff = dateDiff.getUTCFullYear() - 1970;\n const monthDiff = dateDiff.getUTCMonth();\n const dayDiff = dateDiff.getUTCDate() - 1;\n\n // Determines how long ago the version was published\n let timeString = '';\n if (yearDiff > 0) {\n timeString = `${yearDiff.toString()} year${yearDiff === 1 ? '' : 's'} ago`;\n } else if (monthDiff > 0) {\n timeString = `${monthDiff.toString()} month${monthDiff === 1 ? '' : 's'} ago`;\n } else if (dayDiff === 0) {\n timeString = 'today';\n } else {\n timeString = `${dayDiff.toString()} day${dayDiff === 1 ? '' : 's'} ago`;\n }\n\n return timeString;\n }\n\n // Sorts the version history by version number\n const sortedEntries = Object.entries(versionHistory).sort((a, b) => b[0].localeCompare(a[0]));\n\n return (\n
    \n

    What`s New

    \n
      \n {(showAllVersions ? sortedEntries : sortedEntries.slice(0, 5)).map((entry) => (\n
      \n
      \n
    • \n {entry[1].description}\n
    • \n
      \n
      \n
      Version {entry[0]}
      \n
      {formatTimeString(entry[1].date)}
      \n
      \n
      \n ))}\n
    \n {sortedEntries.length > 5 && (\n setShowAllVersions(!showAllVersions)}\n className=\"tw-text-xs tw-text-gray-500 tw-underline\"\n >\n {showAllVersions ? 'Show Less Version History' : 'Show All Version History'}\n \n )}\n
    \n );\n}\n","import { useMemo } from 'react';\nimport { formatBytes } from 'platform-bible-utils';\nimport VersionHistory, { VersionHistoryType } from './version-history.component';\n\n/** Interface to store the parameters passed to the Footer component */\ninterface FooterProps {\n /** Optional unique identifier */\n id?: string;\n /** Name of the publisher */\n publisherDisplayName: string;\n /** Size of the extension file in bytes */\n fileSize: number;\n /** List of language codes supported by the extension */\n locales: string[];\n /** Object containing the version history mapped with their information */\n versionHistory: VersionHistoryType;\n}\n\n/**\n * Component to render the footer for the extension details which contains information on the\n * publisher, version history, languages, and file size.\n *\n * @param id Optional unique identifier\n * @param publisherDisplayName Name of the publisher\n * @param fileSize Size of the extension file in bytes\n * @param locales List of language codes supported by the extension\n * @param versionHistory Object containing the version history mapped with their information\n * @returns The rendered Footer component\n */\nexport default function Footer({\n id,\n publisherDisplayName,\n fileSize,\n locales,\n versionHistory,\n}: FooterProps) {\n /** Formats the file size into a human-readable format */\n const formattedFileSize = useMemo(() => formatBytes(fileSize), [fileSize]);\n\n /**\n * This function gets the display names of the languages based on the language codes.\n *\n * @param codes The list of language codes\n * @returns The list of language names\n */\n const getLanguageNames = (codes: string[]) => {\n const displayNames = new Intl.DisplayNames(navigator.language, { type: 'language' });\n return codes.map((code) => displayNames.of(code));\n };\n\n const languageNames = getLanguageNames(locales);\n\n return (\n
    \n
    \n \n
    \n
    \n

    Information

    \n
    \n

    \n Publisher\n {publisherDisplayName}\n Size\n {formattedFileSize}\n

    \n
    \n

    \n Languages\n {languageNames.join(', ')}\n

    \n
    \n
    \n
    \n
    \n
    \n );\n}\n","import { PlatformEvent, PlatformEventHandler } from 'platform-bible-utils';\nimport { useEffect } from 'react';\n\n/**\n * Adds an event handler to an event so the event handler runs when the event is emitted. Use\n * `papi.network.getNetworkEvent` to use a networked event with this hook.\n *\n * @param event The event to subscribe to.\n *\n * - If event is a `PlatformEvent`, that event will be used\n * - If event is undefined, the callback will not be subscribed. Useful if the event is not yet\n * available for example\n *\n * @param eventHandler The callback to run when the event is emitted\n *\n * WARNING: MUST BE STABLE - const or wrapped in useCallback. The reference must not be updated\n * every render\n */\nconst useEvent = (\n event: PlatformEvent | undefined,\n eventHandler: PlatformEventHandler,\n) => {\n useEffect(() => {\n // Do nothing if the event is not provided (in case the event is not yet available, for example)\n if (!event) return () => {};\n\n const unsubscriber = event(eventHandler);\n return () => {\n unsubscriber();\n };\n }, [event, eventHandler]);\n};\nexport default useEvent;\n","import { useCallback, useEffect } from 'react';\nimport { PlatformEvent, PlatformEventAsync, PlatformEventHandler } from 'platform-bible-utils';\nimport usePromise from './use-promise.hook';\n\nconst noopUnsubscriber = () => false;\n\n/**\n * Adds an event handler to an asynchronously subscribing/unsubscribing event so the event handler\n * runs when the event is emitted. Use `papi.network.getNetworkEvent` to use a networked event with\n * this hook.\n *\n * @param event The asynchronously (un)subscribing event to subscribe to.\n *\n * - If event is a `PlatformEvent` or `PlatformEventAsync`, that event will be used\n * - If event is undefined, the callback will not be subscribed. Useful if the event is not yet\n * available for example\n *\n * @param eventHandler The callback to run when the event is emitted\n *\n * WARNING: MUST BE STABLE - const or wrapped in useCallback. The reference must not be updated\n * every render\n */\nconst useEventAsync = (\n event: PlatformEvent | PlatformEventAsync | undefined,\n eventHandler: PlatformEventHandler,\n) => {\n // Subscribe to the event asynchronously\n const [unsubscribe] = usePromise(\n useCallback(async () => {\n // Do nothing if the event is not provided (in case the event is not yet available, for example)\n if (!event) return noopUnsubscriber;\n\n // Wrap subscribe and unsubscribe in promises to allow normal events to be used as well\n const unsub = await Promise.resolve(event(eventHandler));\n return async () => unsub();\n }, [eventHandler, event]),\n noopUnsubscriber,\n // We want the unsubscriber to return to default value immediately upon changing subscription\n // So the useEffect below will unsubscribe asap\n { preserveValue: false },\n );\n\n // Unsubscribe from the event asynchronously (but we aren't awaiting the unsub)\n useEffect(() => {\n return () => {\n if (unsubscribe !== noopUnsubscriber) {\n unsubscribe();\n }\n };\n }, [unsubscribe]);\n};\n\nexport default useEventAsync;\n"],"names":["twMergeCustom","extendTailwindMerge","cn","inputs","clsx","Input","React","className","type","props","ref","jsx","BookChapterInput","forwardRef","handleSearch","handleKeyDown","handleOnClick","handleSubmit","jsxs","ShadInput","event","e","History","P","R","t","s","n","N","B","O","S","K","g","k","x","T","X","V","w","L","G","A","H","C","I","y","q","U","m","l","h","c","E","D","i","a","o","u","v","f","d","b","p","J","DropdownMenu","DropdownMenuPrimitive","DropdownMenuTrigger","DropdownMenuGroup","DropdownMenuPortal","DropdownMenuSub","DropdownMenuRadioGroup","DropdownMenuSubTrigger","inset","children","ChevronRight","DropdownMenuSubContent","DropdownMenuContent","sideOffset","DropdownMenuItem","DropdownMenuCheckboxItem","checked","Check","DropdownMenuRadioItem","Circle","DropdownMenuLabel","DropdownMenuSeparator","DropdownMenuShortcut","BookMenuItem","bookId","handleSelectBook","isSelected","handleHighlightBook","bookType","ShadDropdownMenuItem","Canon","ChapterSelect","handleSelectChapter","endChapter","activeChapter","highlightedChapter","handleHighlightedChapter","chapters","_","handleMouse","useCallback","chapterNumber","chapter","GoToMenuItem","handleSort","handleLocationHistory","handleBookmarks","ShadDropdownMenuLabel","ArrowDownWideNarrow","Clock","Bookmark","ALL_BOOK_IDS","BOOK_TYPE_LABELS","BOOK_TYPE_ARRAY","SCROLL_OFFSET","SEARCH_QUERY_FORMATS","fetchGroupedBooks","fetchEndChapter","getChaptersForBook","getAllEnglishNames","isValidBookEnglishName","bookName","getBookIdFromEnglishName","formattedBookName","BookChapterControl","scrRef","searchQuery","setSearchQuery","useState","selectedBookId","setSelectedBookId","setHighlightedChapter","highlightedBookId","setHighlightedBookId","isContentOpen","setIsContentOpen","isContentOpenDelayed","setIsContentOpenDelayed","inputRef","useRef","contentRef","menuItemRef","fetchFilteredBooks","englishNameLowerCase","normalizedQuery","handleSearchInput","searchString","shouldPreventAutoClosing","controlMenuState","open","updateReference","shouldClose","verse","handleInputSubmit","format","matches","book","englishName","handleKeyDownInput","handleKeyDownContent","key","handleKeyDownMenuItem","chapterOffSet","useEffect","useLayoutEffect","scrollTimeout","scrollPosition","ShadDropdownMenu","ShadDropdownMenuTrigger","ShadDropdownMenuContent","bookTypeIndex","element","ShadDropdownMenuSeparator","buttonVariants","cva","Button","variant","size","asChild","Comp","Slot","labelVariants","Label","LabelPrimitive","RadioGroup","RadioGroupPrimitive","RadioGroupItem","Popover","PopoverPrimitive","PopoverTrigger","PopoverContent","align","DialogPortal","DialogPrimitive","DialogOverlay","DialogContent","DialogTitle","DialogDescription","Command","CommandPrimitive","CommandInput","Search","CommandList","CommandEmpty","CommandGroup","CommandSeparator","CommandItem","getOptionLabelDefault","option","ComboBox","id","options","buttonClassName","popoverContentClassName","value","onChange","getOptionLabel","buttonPlaceholder","textPlaceholder","commandEmptyMessage","buttonVariant","dir","isDisabled","setOpen","ChevronsUpDown","ChapterRangeSelector","startChapter","handleSelectStartChapter","handleSelectEndChapter","chapterCount","chapterOptions","useMemo","index","onChangeStartChapter","onChangeEndChapter","Fragment","BookSelectionMode","BOOK_SELECTOR_STRING_KEYS","localizeString","strings","BookSelector","handleBookSelectionModeChange","currentBookName","onSelectBooks","selectedBookIds","localizedStrings","currentBookText","chooseText","chooseBooksText","bookSelectionMode","setBookSelectionMode","onSelectionModeChange","newMode","DataTableViewOptions","table","FilterIcon","column","Select","SelectPrimitive","SelectGroup","SelectValue","SelectTrigger","ChevronDown","SelectScrollUpButton","ChevronUp","SelectScrollDownButton","SelectContent","position","SelectLabel","SelectItem","SelectSeparator","DataTablePagination","pageSize","ArrowLeftIcon","ChevronLeftIcon","ChevronRightIcon","ArrowRightIcon","Table","stickyHeader","TableHeader","TableBody","TableFooter","TableRow","TableHead","TableCell","TableCaption","DataTable","columns","data","enablePagination","showPaginationControls","showColumnVisibilityControls","onRowClickHandler","sorting","setSorting","columnFilters","setColumnFilters","columnVisibility","setColumnVisibility","rowSelection","setRowSelection","useReactTable","getCoreRowModel","getPaginationRowModel","getSortedRowModel","getFilteredRowModel","headerGroup","header","flexRender","_a","row","cell","OccurrencesTable","occurrenceData","setScriptureReference","referenceHeaderText","occurrenceHeaderText","occurrences","uniqueOccurrences","occurrence","uniqueOccurrence","deepEqual","Checkbox","CheckboxPrimitive","getLinesFromUSFM","text","getNumberFromUSFM","regex","match","getBookNumFromId","getStatusForItem","item","approvedItems","unapprovedItems","toggleVariants","Toggle","TogglePrimitive","ToggleGroupContext","ToggleGroup","ToggleGroupPrimitive","ToggleGroupItem","context","getSortingIcon","sortDirection","ArrowUpIcon","ArrowDownIcon","ArrowUpDownIcon","inventoryItemColumn","itemLabel","inventoryAdditionalItemColumn","additionalItemLabel","additionalItemIndex","inventoryCountColumn","countLabel","statusChangeHandler","changedItems","newStatus","onApprovedItemsChange","onUnapprovedItemsChange","newApprovedItems","validItem","newUnapprovedItems","unapprovedItem","inventoryStatusColumn","statusLabel","status","CircleCheckIcon","CircleXIcon","CircleHelpIcon","INVENTORY_STRING_KEYS","filterItemData","itemData","statusFilter","textFilter","filteredItemData","createTableData","scriptureRef","itemRegex","tableData","currentBook","currentChapter","currentVerse","line","items","itemIndex","existingItem","tableEntry","newReference","substring","newItem","Inventory","scriptureReference","extractItems","additionalItemsLabels","scope","onScopeChange","allItemsText","approvedItemsText","unapprovedItemsText","unknownItemsText","scopeBookText","scopeChapterText","scopeVerseText","filterText","showAdditionalItemsText","showAdditionalItems","setShowAdditionalItems","setStatusFilter","setTextFilter","selectedItem","setSelectedItem","reducedTableData","newTableData","firstItem","existingEntry","newTableEntry","filteredTableData","allColumns","numberOfAdditionalItems","additionalColumns","_b","rowClickHandler","newSelection","handleScopeChange","handleStatusFilterChange","SearchBar","onSearch","placeholder","isFullWidth","handleInputChange","VerticalTabs","TabsPrimitive","VerticalTabsList","VerticalTabsTrigger","VerticalTabsContent","TabNavigationContentSearch","tabList","searchPlaceholder","headerTitle","isSearchBarFullWidth","direction","tab","Separator","orientation","decorative","SeparatorPrimitive","Sheet","SheetPrimitive","SheetPortal","SheetOverlay","sheetVariants","SheetContent","side","SheetTitle","SheetDescription","Skeleton","TooltipProvider","TooltipPrimitive","Tooltip","TooltipTrigger","TooltipContent","MOBILE_BREAKPOINT","useIsMobile","isMobile","setIsMobile","mql","SIDEBAR_COOKIE_NAME","SIDEBAR_COOKIE_MAX_AGE","SIDEBAR_WIDTH","SIDEBAR_WIDTH_MOBILE","SIDEBAR_WIDTH_ICON","SIDEBAR_KEYBOARD_SHORTCUT","SidebarContext","useSidebar","SidebarProvider","defaultOpen","openProp","setOpenProp","style","openMobile","setOpenMobile","_open","_setOpen","isOpen","openState","toggleSidebar","state","contextValue","Sidebar","collapsible","SidebarTrigger","onClick","PanelLeft","SidebarRail","SidebarInset","SidebarInput","SidebarHeader","SidebarFooter","SidebarSeparator","SidebarContent","SidebarGroup","SidebarGroupLabel","SidebarGroupAction","SidebarGroupContent","SidebarMenu","SidebarMenuItem","sidebarMenuButtonVariants","SidebarMenuButton","isActive","tooltip","button","SidebarMenuAction","showOnHover","SidebarMenuBadge","SidebarMenuSkeleton","showIcon","width","SidebarMenuSub","SidebarMenuSubItem","SidebarMenuSubButton","SettingsSidebar","extensionLabels","projectOptions","handleSelectSidebarItem","selectedSidebarItem","extensionsSidebarGroupLabel","projectsSidebarGroupLabel","handleSelectItem","projectId","getProjectNameFromProjectId","project","getIsActive","label","selectedProjectName","SettingsSidebarContentSearch","scrBookColId","scrRefColId","typeColId","detailsColId","defaultScrRefColumnName","defaultScrBookGroupName","defaultTypeColumnName","defaultDetailsColumnName","getColumns","colInfo","showSourceColumn","showSrcCol","info","formatScrRef","compareScrRefs","toRefOrRange","scriptureSelection","offsetStart","offsetEnd","scrRefToBBBCCCVVV","getRowKey","ScriptureResultsViewer","sources","showColumnHeaders","scriptureReferenceColumnName","scriptureBookGroupName","typeColumnName","detailsColumnName","onRowSelected","grouping","setGrouping","scriptureResults","source","getExpandedRowModel","getGroupedRowModel","selectedRows","keys","selectedRow","scrBookGroupName","typeGroupName","groupingOptions","handleSelectChange","selectedGrouping","handleRowClick","getEvenOrOddBandingStyle","getIndent","groupingState","rowIndex","ChevronLeft","DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS","getLocalizeKeyForScrollGroupId","ScrollGroupSelector","availableScrollGroupIds","scrollGroupId","onChangeScrollGroupId","localizedStringsDefaulted","localizedStringKey","localizedStringValue","newScrollGroupString","scrollGroupOptionId","SettingsList","SettingsListItem","primary","secondary","isLoading","loadingMessage","SettingsListHeader","includeSeparator","Checklist","listItems","selectedListItems","handleSelectListItem","createLabel","_interopRequireDefault","obj","module","chainPropTypes","propType1","propType2","args","_extends","target","isPlainObject","prototype","deepClone","output","deepmerge","r","z","reactIs_production_min","hasSymbol","REACT_ELEMENT_TYPE","REACT_PORTAL_TYPE","REACT_FRAGMENT_TYPE","REACT_STRICT_MODE_TYPE","REACT_PROFILER_TYPE","REACT_PROVIDER_TYPE","REACT_CONTEXT_TYPE","REACT_ASYNC_MODE_TYPE","REACT_CONCURRENT_MODE_TYPE","REACT_FORWARD_REF_TYPE","REACT_SUSPENSE_TYPE","REACT_SUSPENSE_LIST_TYPE","REACT_MEMO_TYPE","REACT_LAZY_TYPE","REACT_BLOCK_TYPE","REACT_FUNDAMENTAL_TYPE","REACT_RESPONDER_TYPE","REACT_SCOPE_TYPE","isValidElementType","typeOf","object","$$typeof","$$typeofType","AsyncMode","ConcurrentMode","ContextConsumer","ContextProvider","Element","ForwardRef","Lazy","Memo","Portal","Profiler","StrictMode","Suspense","hasWarnedAboutDeprecatedIsAsyncMode","isAsyncMode","isConcurrentMode","isContextConsumer","isContextProvider","isElement","isForwardRef","isFragment","isLazy","isMemo","isPortal","isProfiler","isStrictMode","isSuspense","reactIs_development","reactIsModule","require$$0","require$$1","getOwnPropertySymbols","hasOwnProperty","propIsEnumerable","toObject","val","shouldUseNative","test1","test2","order2","test3","letter","objectAssign","from","to","symbols","ReactPropTypesSecret","ReactPropTypesSecret_1","has","printWarning","loggedTypeFailures","message","checkPropTypes","typeSpecs","values","location","componentName","getStack","typeSpecName","error","err","ex","stack","checkPropTypes_1","ReactIs","assign","require$$2","require$$3","require$$4","emptyFunctionThatReturnsNull","factoryWithTypeCheckers","isValidElement","throwOnDirectAccess","ITERATOR_SYMBOL","FAUX_ITERATOR_SYMBOL","getIteratorFn","maybeIterable","iteratorFn","ANONYMOUS","ReactPropTypes","createPrimitiveTypeChecker","createAnyTypeChecker","createArrayOfTypeChecker","createElementTypeChecker","createElementTypeTypeChecker","createInstanceTypeChecker","createNodeChecker","createObjectOfTypeChecker","createEnumTypeChecker","createUnionTypeChecker","createShapeTypeChecker","createStrictShapeTypeChecker","is","PropTypeError","createChainableTypeChecker","validate","manualPropTypeCallCache","manualPropTypeWarningCount","checkType","isRequired","propName","propFullName","secret","cacheKey","chainedCheckType","expectedType","propValue","propType","getPropType","preciseType","getPreciseType","typeChecker","expectedClass","expectedClassName","actualClassName","getClassName","expectedValues","valuesString","arrayOfTypeCheckers","checker","getPostfixForTypeWarning","expectedTypes","checkerResult","expectedTypesMessage","isNode","invalidValidatorError","shapeTypes","allKeys","iterator","step","entry","isSymbol","emptyFunction","emptyFunctionWithReset","factoryWithThrowingShims","shim","getShim","propTypesModule","isClassComponent","elementType","acceptingRef","safePropName","warningHint","elementAcceptingRef","PropTypes","elementAcceptingRef$1","specialProperty","exactProp","propTypes","unsupportedProps","prop","formatMuiErrorMessage","code","url","REACT_SERVER_CONTEXT_TYPE","REACT_OFFSCREEN_TYPE","enableScopeAPI","enableCacheElement","enableTransitionTracing","enableLegacyHidden","enableDebugTracing","REACT_MODULE_REFERENCE","SuspenseList","hasWarnedAboutDeprecatedIsConcurrentMode","isSuspenseList","fnNameMatchRegex","getFunctionName","fn","getFunctionComponentName","Component","fallback","getWrappedName","outerType","innerType","wrapperName","functionName","getDisplayName","HTMLElementType","refType","refType$1","capitalize","string","_formatMuiErrorMessage","createChainedFunction","funcs","acc","func","debounce","wait","timeout","debounced","later","deprecatedPropType","validator","reason","componentNameSafe","propFullNameSafe","isMuiElement","muiNames","_muiName","_element$type","ownerDocument","node","ownerWindow","requirePropFactory","componentNameInError","prevPropTypes","requiredProp","defaultTypeChecker","typeCheckerResult","setRef","useEnhancedEffect","useEnhancedEffect$1","globalId","useGlobalId","idOverride","defaultId","setDefaultId","maybeReactUseId","useId","reactId","unsupportedProp","useControlled","controlled","defaultProp","name","isControlled","valueState","setValue","defaultValue","setValueIfUncontrolled","newValue","useEventCallback","useForkRef","refs","instance","UNINITIALIZED","useLazyRef","init","initArg","EMPTY","useOnMount","Timeout","delay","useTimeout","hadKeyboardEvent","hadFocusVisibleRecently","hadFocusVisibleRecentlyTimeout","inputTypesWhitelist","focusTriggersKeyboardModality","tagName","handlePointerDown","handleVisibilityChange","prepare","doc","isFocusVisible","useIsFocusVisible","isFocusVisibleRef","handleBlurVisible","handleFocusVisible","resolveProps","defaultProps","defaultSlotProps","slotProps","slotPropName","composeClasses","slots","getUtilityClass","classes","slot","utilityClass","defaultGenerator","createClassNameGenerator","generate","generator","ClassNameGenerator","ClassNameGenerator$1","globalStateClasses","generateUtilityClass","globalStatePrefix","globalStateClass","generateUtilityClasses","result","clamp","min","max","_objectWithoutPropertiesLoose","excluded","sourceKeys","_excluded","sortBreakpointsValues","breakpointsAsArray","breakpoint1","breakpoint2","createBreakpoints","breakpoints","unit","other","sortedValues","up","down","between","start","end","endIndex","only","not","keyIndex","shape","shape$1","responsivePropType","responsivePropType$1","merge","defaultBreakpoints","handleBreakpoints","styleFromPropValue","theme","themeBreakpoints","breakpoint","mediaKey","cssKey","createEmptyBreakpointObject","breakpointsInput","_breakpointsInput$key","breakpointStyleKey","removeUnusedBreakpoints","breakpointKeys","breakpointOutput","getPath","path","checkVars","getStyleValue","themeMapping","transform","propValueFinal","userValue","cssProperty","themeKey","memoize","cache","arg","properties","directions","aliases","getCssProperties","property","marginKeys","paddingKeys","spacingKeys","createUnaryUnit","_getPath","themeSpacing","abs","createUnarySpacing","getValue","transformer","transformed","getStyleFromPropValue","cssProperties","resolveCssProperty","margin","padding","createSpacing","spacingInput","spacing","argsInput","argument","compose","styles","handlers","borderTransform","createBorderStyle","border","borderTop","borderRight","borderBottom","borderLeft","borderColor","borderTopColor","borderRightColor","borderBottomColor","borderLeftColor","outline","outlineColor","borderRadius","gap","columnGap","rowGap","gridColumn","gridRow","gridAutoFlow","gridAutoColumns","gridAutoRows","gridTemplateColumns","gridTemplateRows","gridTemplateAreas","gridArea","paletteTransform","color","bgcolor","backgroundColor","sizingTransform","maxWidth","_props$theme","_props$theme2","breakpointsValues","minWidth","height","maxHeight","minHeight","boxSizing","defaultSxConfig","defaultSxConfig$1","objectsHaveSameKeys","objects","union","callIfFn","maybeFn","unstable_createStyleFunctionSx","getThemeValue","config","styleFunctionSx","_theme$unstable_sxCon","sx","traverse","sxInput","sxObject","emptyBreakpoints","breakpointsKeys","css","styleKey","styleFunctionSx$1","applyStyles","createTheme","paletteInput","shapeInput","muiTheme","isObjectEmpty","useTheme","defaultTheme","contextTheme","ThemeContext","systemDefaultTheme","useThemeWithoutDefault","_excluded2","_excluded3","isEmpty","isStringTag","tag","shouldForwardProp","lowercaseFirstLetter","resolveTheme","themeId","defaultOverridesResolver","processStyleArg","callableStyle","_ref","ownerState","resolvedStylesArg","resolvedStyle","variants","isMatch","createStyled","input","rootShouldForwardProp","slotShouldForwardProp","systemSx","inputOptions","processStyles","componentSlot","inputSkipVariantsResolver","inputSkipSx","overridesResolver","skipVariantsResolver","skipSx","shouldForwardPropOption","defaultStyledResolver","styledEngineStyled","transformStyleArg","stylesArg","muiStyledResolver","styleArg","expressions","transformedStyleArg","expressionsWithDefaultTheme","styleOverrides","resolvedStyleOverrides","slotKey","slotStyle","_theme$components","themeVariants","numOfCustomFnsApplied","placeholders","displayName","getThemeProps","params","useThemeProps","clampWrapper","hexToRgb","re","colors","decomposeColor","marker","colorSpace","recomposeColor","hslToRgb","rgb","getLuminance","getContrastRatio","foreground","background","lumA","lumB","alpha","darken","coefficient","lighten","createMixins","mixins","common","common$1","grey","grey$1","purple","purple$1","red","red$1","orange","orange$1","blue","blue$1","lightBlue","lightBlue$1","green","green$1","light","dark","addLightOrDark","intent","shade","tonalOffset","tonalOffsetLight","tonalOffsetDark","getDefaultPrimary","mode","getDefaultSecondary","getDefaultError","getDefaultInfo","getDefaultSuccess","getDefaultWarning","createPalette","palette","contrastThreshold","success","warning","getContrastText","contrastText","contrast","augmentColor","mainShade","lightShade","darkShade","modes","round","caseAllCaps","defaultFontFamily","createTypography","typography","fontFamily","fontSize","fontWeightLight","fontWeightRegular","fontWeightMedium","fontWeightBold","htmlFontSize","allVariants","pxToRem2","coef","pxToRem","buildVariant","fontWeight","lineHeight","letterSpacing","casing","shadowKeyUmbraOpacity","shadowKeyPenumbraOpacity","shadowAmbientShadowOpacity","createShadow","px","shadows","shadows$1","easing","duration","formatMs","milliseconds","getAutoHeightDuration","constant","createTransitions","inputTransitions","mergedEasing","mergedDuration","durationOption","easingOption","isString","isNumber","animatedProp","zIndex","zIndex$1","mixinsInput","transitionsInput","typographyInput","systemTheme","systemCreateTheme","stateClasses","component","child","stateClass","defaultTheme$1","THEME_ID","systemUseThemeProps","styled","styled$1","getSvgIconUtilityClass","useUtilityClasses","SvgIconRoot","_theme$transitions","_theme$transitions$cr","_theme$transitions2","_theme$typography","_theme$typography$pxT","_theme$typography2","_theme$typography2$px","_theme$typography3","_theme$typography3$px","_palette$ownerState$c","_palette","_palette2","_palette3","SvgIcon","inProps","htmlColor","inheritViewBox","titleAccess","viewBox","hasSvgAsChild","more","_jsxs","_jsx","SvgIcon$1","createSvgIcon","unstable_ClassNameGenerator","exports","_utils","ArrowRight","default_1","_createSvgIcon","_jsxRuntime","isHostComponent","appendOwnerState","otherProps","defaultContextValue","ClassNameConfiguratorContext","useClassNamesOverride","disableDefaultClasses","extractEventHandlers","excludeKeys","resolveComponentProps","componentProps","slotState","omitEventHandlers","mergeSlotProps","parameters","getSlotProps","additionalProps","externalSlotProps","externalForwardedProps","joinedClasses","mergedStyle","eventHandlers","componentsPropsWithoutEventHandlers","otherPropsWithoutEventHandlers","internalSlotProps","useSlotProps","_parameters$additiona","skipResolvingSlotProps","rest","resolvedComponentsProps","mergedProps","internalRef","GLOBAL_CLASS_PREFIX","buildStateClass","buildSlotClass","getContainer","container","forwardedRef","disablePortal","mountNode","setMountNode","handleRef","newProps","ReactDOM","top","bottom","right","left","auto","basePlacements","clippingParents","viewport","popper","reference","variationPlacements","placement","placements","beforeRead","read","afterRead","beforeMain","main","afterMain","beforeWrite","write","afterWrite","modifierPhases","getNodeName","getWindow","OwnElement","isHTMLElement","isShadowRoot","attributes","effect","_ref2","initialStyles","styleProperties","attribute","applyStyles$1","getBasePlacement","getUAString","uaData","isLayoutViewport","getBoundingClientRect","includeScale","isFixedStrategy","clientRect","scaleX","scaleY","visualViewport","addVisualOffsets","getLayoutRect","contains","parent","rootNode","next","getComputedStyle","isTableElement","getDocumentElement","getParentNode","getTrueOffsetParent","getContainingBlock","isFirefox","isIE","elementCss","currentNode","getOffsetParent","window","offsetParent","getMainAxisFromPlacement","within","mathMax","mathMin","withinMaxClamp","getFreshSideObject","mergePaddingObject","paddingObject","expandToHashMap","hashMap","toPaddingObject","arrow","_state$modifiersData$","arrowElement","popperOffsets","basePlacement","axis","isVertical","len","arrowRect","minProp","maxProp","endDiff","startDiff","arrowOffsetParent","clientSize","centerToReference","center","offset","axisProp","_options$element","arrow$1","getVariation","unsetSides","roundOffsetsByDPR","win","dpr","mapToStyles","_Object$assign2","popperRect","variation","offsets","gpuAcceleration","adaptive","roundOffsets","isFixed","_offsets$x","_offsets$y","_ref3","hasX","hasY","sideX","sideY","heightProp","widthProp","offsetY","offsetX","commonStyles","_ref4","_Object$assign","computeStyles","_ref5","_options$gpuAccelerat","_options$adaptive","_options$roundOffsets","computeStyles$1","passive","_options$scroll","scroll","_options$resize","resize","scrollParents","scrollParent","eventListeners","hash","getOppositePlacement","matched","getOppositeVariationPlacement","getWindowScroll","scrollLeft","scrollTop","getWindowScrollBarX","getViewportRect","strategy","html","layoutViewport","getDocumentRect","_element$ownerDocumen","winScroll","body","isScrollParent","_getComputedStyle","overflow","overflowX","overflowY","getScrollParent","listScrollParents","list","isBody","updatedList","rectToClientRect","rect","getInnerBoundingClientRect","getClientRectFromMixedType","clippingParent","getClippingParents","canEscapeClipping","clipperElement","getClippingRect","boundary","rootBoundary","mainClippingParents","firstClippingParent","clippingRect","accRect","computeOffsets","commonX","commonY","mainAxis","detectOverflow","_options","_options$placement","_options$strategy","_options$boundary","_options$rootBoundary","_options$elementConte","elementContext","_options$altBoundary","altBoundary","_options$padding","altContext","clippingClientRect","referenceClientRect","popperClientRect","elementClientRect","overflowOffsets","offsetData","multiply","computeAutoPlacement","flipVariations","_options$allowedAutoP","allowedAutoPlacements","allPlacements","allowedPlacements","overflows","getExpandedFallbackPlacements","oppositePlacement","flip","_options$mainAxis","checkMainAxis","_options$altAxis","checkAltAxis","specifiedFallbackPlacements","_options$flipVariatio","preferredPlacement","isBasePlacement","fallbackPlacements","referenceRect","checksMap","makeFallbackChecks","firstFittingPlacement","_basePlacement","isStartVariation","mainVariationSide","altVariationSide","checks","check","numberOfChecks","_loop","_i","fittingPlacement","_ret","flip$1","getSideOffsets","preventedOffsets","isAnySideFullyClipped","hide","referenceOverflow","popperAltOverflow","referenceClippingOffsets","popperEscapeOffsets","isReferenceHidden","hasPopperEscaped","hide$1","distanceAndSkiddingToXY","rects","invertDistance","skidding","distance","_options$offset","_data$state$placement","offset$1","popperOffsets$1","getAltAxis","preventOverflow","_options$tether","tether","_options$tetherOffset","tetherOffset","altAxis","tetherOffsetValue","normalizedTetherOffsetValue","offsetModifierState","_offsetModifierState$","mainSide","altSide","additive","minLen","maxLen","arrowPaddingObject","arrowPaddingMin","arrowPaddingMax","arrowLen","minOffset","maxOffset","clientOffset","offsetModifierValue","tetherMin","tetherMax","preventedOffset","_offsetModifierState$2","_mainSide","_altSide","_offset","_len","_min","_max","isOriginSide","_offsetModifierValue","_tetherMin","_tetherMax","_preventedOffset","preventOverflow$1","getHTMLElementScroll","getNodeScroll","isElementScaled","getCompositeRect","elementOrVirtualElement","isOffsetParentAnElement","offsetParentIsScaled","documentElement","order","modifiers","map","visited","modifier","sort","requires","dep","depModifier","orderModifiers","orderedModifiers","phase","pending","resolve","mergeByName","merged","current","existing","DEFAULT_OPTIONS","areValidElements","_key","popperGenerator","generatorOptions","_generatorOptions","_generatorOptions$def","defaultModifiers","_generatorOptions$def2","defaultOptions","effectCleanupFns","isDestroyed","setOptionsAction","cleanupModifierEffects","runModifierEffects","_state$elements","_state$orderedModifie","_state$orderedModifie2","_ref$options","cleanupFn","noopFn","createPopper","COMPONENT_NAME","getPopperUtilityClass","flipPlacement","resolveAnchorEl","anchorEl","isVirtualElement","defaultPopperOptions","PopperTooltip","_slots$root","initialPlacement","popperOptions","popperRefProp","TransitionProps","tooltipRef","ownRef","popperRef","handlePopperRef","handlePopperRefRef","rtlPlacement","setPlacement","resolvedAnchorElement","setResolvedAnchorElement","handlePopperUpdate","box","popperModifiers","childProps","Root","rootProps","Popper","containerProp","keepMounted","transition","exited","setExited","handleEnter","handleExited","resolvedAnchorEl","display","transitionProps","useThemeSystem","_setPrototypeOf","_inheritsLoose","subClass","superClass","setPrototypeOf","timeoutsShape","TransitionGroupContext","forceReflow","UNMOUNTED","EXITED","ENTERING","ENTERED","EXITING","Transition","_React$Component","_this","parentGroup","appear","initialStatus","prevState","nextIn","_proto","prevProps","nextStatus","exit","enter","mounting","_this2","appearing","maybeNode","maybeAppearing","timeouts","enterTimeout","_this3","nextState","callback","_this4","active","handler","doesNotHaveTimeoutOrListener","maybeNextCallback","_this$props","pt","noop","Transition$1","reflow","getTransitionProps","_style$transitionDura","_style$transitionTimi","getScale","isWebKit154","Grow","addEndListener","inProp","onEnter","onEntered","onEntering","onExit","onExited","onExiting","TransitionComponent","timer","autoTimeout","nodeRef","normalizedTransitionCallback","maybeIsAppearing","handleEntering","isAppearing","transitionDuration","transitionTimingFunction","handleEntered","handleExiting","handleExit","handleAddEndListener","Grow$1","PopperRoot","BasePopper","components","componentsProps","RootComponent","Popper$1","getTooltipUtilityClass","tooltipClasses","tooltipClasses$1","disableInteractive","touch","TooltipPopper","TooltipTooltip","TooltipArrow","hystersisOpen","hystersisTimer","cursorPosition","composeEventHandler","eventHandler","_slots$popper","_slots$transition","_slots$tooltip","_slots$arrow","_slotProps$popper","_ref6","_slotProps$popper2","_slotProps$transition","_slotProps$tooltip","_ref7","_slotProps$tooltip2","_slotProps$arrow","_ref8","_slotProps$arrow2","childrenProp","describeChild","disableFocusListener","disableHoverListener","disableInteractiveProp","disableTouchListener","enterDelay","enterNextDelay","enterTouchDelay","followCursor","idProp","leaveDelay","leaveTouchDelay","onClose","onOpen","PopperComponentProp","PopperProps","title","TransitionComponentProp","isRtl","childNode","setChildNode","arrowRef","setArrowRef","ignoreNonTouchEvents","closeTimer","enterTimer","leaveTimer","touchTimer","setOpenState","prevUserSelect","stopTouchInteraction","handleOpen","handleClose","handleLeave","focusVisibleRef","setChildIsFocusVisible","handleBlur","handleFocus","detectTouchStart","childrenProps","handleMouseOver","handleMouseLeave","handleTouchStart","handleTouchEnd","nativeEvent","handleMouseMove","nameOrDescProps","titleIsString","interactiveWrapperListeners","_PopperProps$popperOp","tooltipModifiers","PopperComponent","TooltipComponent","ArrowComponent","popperProps","tooltipProps","tooltipArrowProps","TransitionPropsInner","Tooltip$1","getIcon","icon","menuLabel","leading","MuiListItemIcon","MenuItem","allowForLeadingIcons","iconPathBefore","iconPathAfter","hasAutoFocus","isDense","isSubMenuParent","hasDisabledGutters","hasDivider","focusVisibleClassName","menuItem","MuiMenuItem","MuiListItemText","getAllGroups","menuDefinition","SubMenu","setAnchorEl","parentMenuItem","parentItemProps","handleParentMenuItemClick","renderSubMenuItems","includedGroups","group","GroupedMenuItemList","Menu","getOrderedGroupItems","groupId","allItems","menuProps","commandHandler","groupsToInclude","sortedGroups","itemArray","allowSpaceForLeadingIcons","createMenuItemProps","isLastItemInGroup","divKey","itemInfo","menuItemProps","TopLevelMenu","columnId","MenuColumn","metadata","Grid","List","GridMenu","multiColumnMenu","sortedColumns","columnNumbers","columnName","col","getUsePromiseOptionsDefaults","usePromise","promiseFactoryCallback","defaultValueRef","optionsDefaultedRef","setIsLoading","promiseIsCurrent","MenuIcon","HamburgerMenuButton","menuProvider","normalMenu","fullMenu","containerRef","ariaLabelPrefix","isMenuOpen","setMenuOpen","showFullMenu","setShowFullMenu","handleMenuItemClick","handleMenuButtonClick","prevIsOpen","isOpening","menuCommandHandler","command","setOffset","normalMenuData","fullMenuData","menu","IconButton","Drawer","isTooltipSuppressed","adjustMarginToAlignToEdge","MuiIconButton","Spinner","LoaderCircle","TextField","hasError","helperText","onFocus","onBlur","ShadLabel","Toolbar","AppBar","MuiToolbar","alertVariants","Alert","AlertTitle","AlertDescription","Card","CardHeader","CardTitle","CardDescription","CardContent","CardFooter","Sonner","Toaster","Slider","SliderPrimitive","Switch","SwitchPrimitives","Tabs","TabsList","TabsTrigger","TabsContent","InstallButton","isInstalling","handleClick","buttonText","Download","EnableButton","isEnabling","DisableButton","isDisabling","UpdateButton","isUpdating","MarkdownRenderer","markdown","anchorTarget","Markdown","FilterButton","Filter","DropdownMenuItemType","DropdownMenuItemType2","FilterDropdown","groups","NoExtensionsFound","MoreInfo","category","downloads","languages","moreInfoUrl","numberFormatted","NumberFormat","handleScrollToBottom","User","locale","LucideLink","CircleHelp","VersionHistory","versionHistory","showAllVersions","setShowAllVersions","currentDate","formatTimeString","dateString","date","dateDiff","yearDiff","monthDiff","dayDiff","timeString","sortedEntries","Footer","publisherDisplayName","fileSize","locales","formattedFileSize","formatBytes","languageNames","codes","displayNames","useEvent","unsubscriber","noopUnsubscriber","useEventAsync","unsubscribe","unsub"],"mappings":"28CAGA,MAAMA,GAAgBC,GAAAA,oBAAoB,CAAE,OAAQ,KAAO,CAAA,EAyDpD,SAASC,KAAMC,EAAsB,CACnC,OAAAH,GAAcI,GAAAA,KAAKD,CAAM,CAAC,CACnC,CCzDO,MAAME,GAAQC,EAAM,WACzB,CAAC,CAAE,UAAAC,EAAW,KAAAC,EAAM,GAAGC,CAAA,EAASC,IAE5BC,EAAA,IAAC,QAAA,CACC,KAAAH,EACA,UAAWN,EACT,sbACAK,CACF,EACA,IAAAG,EAEC,GAAGD,CAAA,CAAA,CAIZ,EACAJ,GAAM,YAAc,QCNpB,MAAMO,GAAmBC,EAAA,WACvB,CACE,CAAE,aAAAC,EAAc,cAAAC,EAAe,cAAAC,EAAe,aAAAC,EAAc,GAAGR,CAAM,EACrEC,IAGEQ,EAAA,KAAC,MAAI,CAAA,UAAU,cACb,SAAA,CAAAP,EAAA,IAACQ,GAAA,CACE,GAAGV,EACJ,KAAK,OACL,UAAU,0JACV,SAAWW,GAAUN,EAAaM,EAAM,OAAO,KAAK,EACpD,UAAYC,GAAM,CACZA,EAAE,MAAQ,SACCJ,IAEfF,EAAcM,CAAC,CACjB,EACA,QAASL,EACT,IAAAN,CAAA,CACF,EACAC,EAAA,IAACW,EAAA,QAAA,CACC,UAAU,8HACV,QAAS,IAAM,CAEb,QAAQ,IAAI,iBAAiB,CAC/B,CAAA,CACF,CACF,CAAA,CAAA,CAGN,EC9CA,IAAIC,GAAI,OAAO,eACXC,GAAI,CAACC,EAAGJ,EAAGK,IAAML,KAAKI,EAAIF,GAAEE,EAAGJ,EAAG,CAAE,WAAY,GAAI,aAAc,GAAI,SAAU,GAAI,MAAOK,CAAC,CAAE,EAAID,EAAEJ,CAAC,EAAIK,EACzGC,GAAI,CAACF,EAAGJ,EAAGK,IAAMF,GAAEC,EAAG,OAAOJ,GAAK,SAAWA,EAAI,GAAKA,EAAGK,CAAC,EAW9D,MAAME,GAAI,CACR,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MAEA,MAEA,MAEA,MAEA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,MAEA,MAEA,MAEA,MAEA,MACA,MACA,MACA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,KACF,EAAGC,GAAI,CACL,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,KACF,EAAGC,GAAI,CACL,UACA,SACA,YACA,UACA,cACA,SACA,SACA,OACA,WACA,WACA,UACA,UACA,eACA,eACA,OACA,WACA,kBACA,MACA,SACA,WACA,eACA,gBACA,SACA,WACA,eACA,UACA,kBACA,QACA,OACA,OACA,UACA,QACA,QACA,QACA,WACA,YACA,SACA,YACA,UACA,UACA,OACA,OACA,OACA,OACA,SACA,gBACA,gBACA,YACA,YACA,cACA,aACA,kBACA,kBACA,YACA,YACA,QACA,WACA,UACA,QACA,UACA,UACA,SACA,SACA,SACA,OACA,aACA,QACA,SACA,eACA,oBACA,0BACA,SACA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,91,92,93,94,95,96,97,98,99,100,101,102,103,104,105,106,107,108,109,110,111,112,113,114,115,116,117,118,119,120,121,122,123,124,125,126,127,128,129,130,131,132,133,134,135,136,137,138,139,140,141,142,143,144,145,146,147,148,149,150,151,152,153,154,155,156,157,158,159,160,161,162,163,164,165,166,167,168,169,170,171,172,173,174,175,176,177,178,179,180,181,182,183,184,185,186,187,188,189,190,191,192,193,194,195,196,197,198,199,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,228]} \ No newline at end of file +{"version":3,"file":"index.cjs","sources":["../src/utils/shadcn-ui.util.ts","../src/components/shadcn-ui/input.tsx","../src/components/advanced/book-chapter-control/book-chapter-input.component.tsx","../../../node_modules/@sillsdev/scripture/dist/index.es.js","../src/components/shadcn-ui/dropdown-menu.tsx","../src/components/advanced/book-chapter-control/book-menu-item.component.tsx","../src/components/advanced/book-chapter-control/chapter-select.component.tsx","../src/components/advanced/book-chapter-control/go-to-menu-item.component.tsx","../src/components/advanced/book-chapter-control/book-chapter-control.component.tsx","../src/components/shadcn-ui/button.tsx","../src/components/shadcn-ui/label.tsx","../src/components/shadcn-ui/radio-group.tsx","../src/components/shadcn-ui/popover.tsx","../src/components/shadcn-ui/dialog.tsx","../src/components/shadcn-ui/command.tsx","../src/components/basics/combo-box.component.tsx","../src/components/basics/chapter-range-selector.component.tsx","../src/components/advanced/book-selector.component.tsx","../src/components/advanced/data-table/data-table-column-toggle.component.tsx","../src/components/shadcn-ui/select.tsx","../src/components/advanced/data-table/data-table-pagination.component.tsx","../src/components/shadcn-ui/table.tsx","../src/components/advanced/data-table/data-table.component.tsx","../src/components/advanced/inventory/occurrences-table.component.tsx","../src/components/shadcn-ui/checkbox.tsx","../src/components/advanced/inventory/inventory-utils.ts","../src/components/shadcn-ui/toggle.tsx","../src/components/shadcn-ui/toggle-group.tsx","../src/components/advanced/inventory/inventory-columns.tsx","../src/components/advanced/inventory/inventory.component.tsx","../src/components/basics/search-bar.component.tsx","../src/components/basics/tabs-vertical.tsx","../src/components/advanced/tab-navigation-content-search.component.tsx","../src/components/shadcn-ui/separator.tsx","../src/components/shadcn-ui/sheet.tsx","../src/components/shadcn-ui/skeleton.tsx","../src/components/shadcn-ui/tooltip.tsx","../src/components/hooks/use-mobile.tsx","../src/components/shadcn-ui/sidebar.tsx","../src/components/advanced/settings-components/settings-sidebar.component.tsx","../src/components/advanced/settings-components/settings-sidebar-content-search.component.tsx","../src/components/advanced/scripture-results-viewer/scripture-results-viewer.component.tsx","../src/components/advanced/scroll-group-selector.component.tsx","../src/components/advanced/settings-components/settings-list.component.tsx","../src/components/basics/checklist.component.tsx","../../../node_modules/@babel/runtime/helpers/interopRequireDefault.js","../../../node_modules/@mui/utils/chainPropTypes/chainPropTypes.js","../../../node_modules/@babel/runtime/helpers/esm/extends.js","../../../node_modules/@mui/utils/deepmerge/deepmerge.js","../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.production.min.js","../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.development.js","../../../node_modules/prop-types/node_modules/react-is/index.js","../../../node_modules/object-assign/index.js","../../../node_modules/prop-types/lib/ReactPropTypesSecret.js","../../../node_modules/prop-types/lib/has.js","../../../node_modules/prop-types/checkPropTypes.js","../../../node_modules/prop-types/factoryWithTypeCheckers.js","../../../node_modules/prop-types/factoryWithThrowingShims.js","../../../node_modules/prop-types/index.js","../../../node_modules/@mui/utils/elementAcceptingRef/elementAcceptingRef.js","../../../node_modules/@mui/utils/exactProp/exactProp.js","../../../node_modules/@mui/utils/formatMuiErrorMessage/formatMuiErrorMessage.js","../../../node_modules/react-is/cjs/react-is.production.min.js","../../../node_modules/react-is/cjs/react-is.development.js","../../../node_modules/react-is/index.js","../../../node_modules/@mui/utils/getDisplayName/getDisplayName.js","../../../node_modules/@mui/utils/HTMLElementType/HTMLElementType.js","../../../node_modules/@mui/utils/refType/refType.js","../../../node_modules/@mui/utils/capitalize/capitalize.js","../../../node_modules/@mui/utils/createChainedFunction/createChainedFunction.js","../../../node_modules/@mui/utils/debounce/debounce.js","../../../node_modules/@mui/utils/deprecatedPropType/deprecatedPropType.js","../../../node_modules/@mui/utils/isMuiElement/isMuiElement.js","../../../node_modules/@mui/utils/ownerDocument/ownerDocument.js","../../../node_modules/@mui/utils/ownerWindow/ownerWindow.js","../../../node_modules/@mui/utils/requirePropFactory/requirePropFactory.js","../../../node_modules/@mui/utils/setRef/setRef.js","../../../node_modules/@mui/utils/useEnhancedEffect/useEnhancedEffect.js","../../../node_modules/@mui/utils/useId/useId.js","../../../node_modules/@mui/utils/unsupportedProp/unsupportedProp.js","../../../node_modules/@mui/utils/useControlled/useControlled.js","../../../node_modules/@mui/utils/useEventCallback/useEventCallback.js","../../../node_modules/@mui/utils/useForkRef/useForkRef.js","../../../node_modules/@mui/utils/useLazyRef/useLazyRef.js","../../../node_modules/@mui/utils/useOnMount/useOnMount.js","../../../node_modules/@mui/utils/useTimeout/useTimeout.js","../../../node_modules/@mui/utils/useIsFocusVisible/useIsFocusVisible.js","../../../node_modules/@mui/utils/resolveProps/resolveProps.js","../../../node_modules/@mui/utils/composeClasses/composeClasses.js","../../../node_modules/@mui/utils/ClassNameGenerator/ClassNameGenerator.js","../../../node_modules/@mui/utils/generateUtilityClass/generateUtilityClass.js","../../../node_modules/@mui/utils/generateUtilityClasses/generateUtilityClasses.js","../../../node_modules/@mui/utils/clamp/clamp.js","../../../node_modules/@babel/runtime/helpers/esm/objectWithoutPropertiesLoose.js","../../../node_modules/@mui/system/esm/createTheme/createBreakpoints.js","../../../node_modules/@mui/system/esm/createTheme/shape.js","../../../node_modules/@mui/system/esm/responsivePropType.js","../../../node_modules/@mui/system/esm/merge.js","../../../node_modules/@mui/system/esm/breakpoints.js","../../../node_modules/@mui/system/esm/style.js","../../../node_modules/@mui/system/esm/memoize.js","../../../node_modules/@mui/system/esm/spacing.js","../../../node_modules/@mui/system/esm/createTheme/createSpacing.js","../../../node_modules/@mui/system/esm/compose.js","../../../node_modules/@mui/system/esm/borders.js","../../../node_modules/@mui/system/esm/cssGrid.js","../../../node_modules/@mui/system/esm/palette.js","../../../node_modules/@mui/system/esm/sizing.js","../../../node_modules/@mui/system/esm/styleFunctionSx/defaultSxConfig.js","../../../node_modules/@mui/system/esm/styleFunctionSx/styleFunctionSx.js","../../../node_modules/@mui/system/esm/createTheme/applyStyles.js","../../../node_modules/@mui/system/esm/createTheme/createTheme.js","../../../node_modules/@mui/system/esm/useThemeWithoutDefault.js","../../../node_modules/@mui/system/esm/useTheme.js","../../../node_modules/@mui/system/esm/createStyled.js","../../../node_modules/@mui/system/esm/useThemeProps/getThemeProps.js","../../../node_modules/@mui/system/esm/useThemeProps/useThemeProps.js","../../../node_modules/@mui/system/esm/colorManipulator.js","../../../node_modules/@mui/material/styles/createMixins.js","../../../node_modules/@mui/material/colors/common.js","../../../node_modules/@mui/material/colors/grey.js","../../../node_modules/@mui/material/colors/purple.js","../../../node_modules/@mui/material/colors/red.js","../../../node_modules/@mui/material/colors/orange.js","../../../node_modules/@mui/material/colors/blue.js","../../../node_modules/@mui/material/colors/lightBlue.js","../../../node_modules/@mui/material/colors/green.js","../../../node_modules/@mui/material/styles/createPalette.js","../../../node_modules/@mui/material/styles/createTypography.js","../../../node_modules/@mui/material/styles/shadows.js","../../../node_modules/@mui/material/styles/createTransitions.js","../../../node_modules/@mui/material/styles/zIndex.js","../../../node_modules/@mui/material/styles/createTheme.js","../../../node_modules/@mui/material/styles/defaultTheme.js","../../../node_modules/@mui/material/styles/identifier.js","../../../node_modules/@mui/material/styles/useThemeProps.js","../../../node_modules/@mui/material/styles/styled.js","../../../node_modules/@mui/material/SvgIcon/svgIconClasses.js","../../../node_modules/@mui/material/SvgIcon/SvgIcon.js","../../../node_modules/@mui/material/utils/createSvgIcon.js","../../../node_modules/@mui/material/utils/index.js","../../../node_modules/@mui/icons-material/utils/createSvgIcon.js","../../../node_modules/@mui/icons-material/ArrowRight.js","../../../node_modules/@mui/base/utils/isHostComponent.js","../../../node_modules/@mui/base/utils/appendOwnerState.js","../../../node_modules/@mui/base/utils/ClassNameConfigurator.js","../../../node_modules/@mui/base/utils/extractEventHandlers.js","../../../node_modules/@mui/base/utils/resolveComponentProps.js","../../../node_modules/@mui/base/utils/omitEventHandlers.js","../../../node_modules/@mui/base/utils/mergeSlotProps.js","../../../node_modules/@mui/base/utils/useSlotProps.js","../../../node_modules/@mui/base/generateUtilityClass/index.js","../../../node_modules/@mui/base/generateUtilityClasses/index.js","../../../node_modules/@mui/base/Portal/Portal.js","../../../node_modules/@popperjs/core/lib/enums.js","../../../node_modules/@popperjs/core/lib/dom-utils/getNodeName.js","../../../node_modules/@popperjs/core/lib/dom-utils/getWindow.js","../../../node_modules/@popperjs/core/lib/dom-utils/instanceOf.js","../../../node_modules/@popperjs/core/lib/modifiers/applyStyles.js","../../../node_modules/@popperjs/core/lib/utils/getBasePlacement.js","../../../node_modules/@popperjs/core/lib/utils/math.js","../../../node_modules/@popperjs/core/lib/utils/userAgent.js","../../../node_modules/@popperjs/core/lib/dom-utils/isLayoutViewport.js","../../../node_modules/@popperjs/core/lib/dom-utils/getBoundingClientRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/getLayoutRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/contains.js","../../../node_modules/@popperjs/core/lib/dom-utils/getComputedStyle.js","../../../node_modules/@popperjs/core/lib/dom-utils/isTableElement.js","../../../node_modules/@popperjs/core/lib/dom-utils/getDocumentElement.js","../../../node_modules/@popperjs/core/lib/dom-utils/getParentNode.js","../../../node_modules/@popperjs/core/lib/dom-utils/getOffsetParent.js","../../../node_modules/@popperjs/core/lib/utils/getMainAxisFromPlacement.js","../../../node_modules/@popperjs/core/lib/utils/within.js","../../../node_modules/@popperjs/core/lib/utils/getFreshSideObject.js","../../../node_modules/@popperjs/core/lib/utils/mergePaddingObject.js","../../../node_modules/@popperjs/core/lib/utils/expandToHashMap.js","../../../node_modules/@popperjs/core/lib/modifiers/arrow.js","../../../node_modules/@popperjs/core/lib/utils/getVariation.js","../../../node_modules/@popperjs/core/lib/modifiers/computeStyles.js","../../../node_modules/@popperjs/core/lib/modifiers/eventListeners.js","../../../node_modules/@popperjs/core/lib/utils/getOppositePlacement.js","../../../node_modules/@popperjs/core/lib/utils/getOppositeVariationPlacement.js","../../../node_modules/@popperjs/core/lib/dom-utils/getWindowScroll.js","../../../node_modules/@popperjs/core/lib/dom-utils/getWindowScrollBarX.js","../../../node_modules/@popperjs/core/lib/dom-utils/getViewportRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/getDocumentRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/isScrollParent.js","../../../node_modules/@popperjs/core/lib/dom-utils/getScrollParent.js","../../../node_modules/@popperjs/core/lib/dom-utils/listScrollParents.js","../../../node_modules/@popperjs/core/lib/utils/rectToClientRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/getClippingRect.js","../../../node_modules/@popperjs/core/lib/utils/computeOffsets.js","../../../node_modules/@popperjs/core/lib/utils/detectOverflow.js","../../../node_modules/@popperjs/core/lib/utils/computeAutoPlacement.js","../../../node_modules/@popperjs/core/lib/modifiers/flip.js","../../../node_modules/@popperjs/core/lib/modifiers/hide.js","../../../node_modules/@popperjs/core/lib/modifiers/offset.js","../../../node_modules/@popperjs/core/lib/modifiers/popperOffsets.js","../../../node_modules/@popperjs/core/lib/utils/getAltAxis.js","../../../node_modules/@popperjs/core/lib/modifiers/preventOverflow.js","../../../node_modules/@popperjs/core/lib/dom-utils/getHTMLElementScroll.js","../../../node_modules/@popperjs/core/lib/dom-utils/getNodeScroll.js","../../../node_modules/@popperjs/core/lib/dom-utils/getCompositeRect.js","../../../node_modules/@popperjs/core/lib/utils/orderModifiers.js","../../../node_modules/@popperjs/core/lib/utils/debounce.js","../../../node_modules/@popperjs/core/lib/utils/mergeByName.js","../../../node_modules/@popperjs/core/lib/createPopper.js","../../../node_modules/@popperjs/core/lib/popper.js","../../../node_modules/@mui/base/Popper/popperClasses.js","../../../node_modules/@mui/base/Popper/Popper.js","../../../node_modules/@mui/material/styles/useTheme.js","../../../node_modules/@babel/runtime/helpers/esm/setPrototypeOf.js","../../../node_modules/@babel/runtime/helpers/esm/inheritsLoose.js","../../../node_modules/react-transition-group/esm/config.js","../../../node_modules/react-transition-group/esm/utils/PropTypes.js","../../../node_modules/react-transition-group/esm/TransitionGroupContext.js","../../../node_modules/react-transition-group/esm/utils/reflow.js","../../../node_modules/react-transition-group/esm/Transition.js","../../../node_modules/@mui/material/transitions/utils.js","../../../node_modules/@mui/material/Grow/Grow.js","../../../node_modules/@mui/material/Popper/Popper.js","../../../node_modules/@mui/material/Tooltip/tooltipClasses.js","../../../node_modules/@mui/material/Tooltip/Tooltip.js","../src/components/mui/menu-item.component.tsx","../src/components/mui/grouped-menu-item-list.component.tsx","../src/components/mui/top-level-menu.component.tsx","../src/components/mui/grid-menu.component.tsx","../src/hooks/use-promise.hook.ts","../../../node_modules/@mui/icons-material/esm/Menu.js","../src/components/mui/hamburger-menu-button.component.tsx","../src/components/mui/icon-button.component.tsx","../src/components/basics/spinner.component.tsx","../src/components/basics/text-field.component.tsx","../src/components/mui/toolbar.component.tsx","../src/components/shadcn-ui/alert.tsx","../src/components/shadcn-ui/card.tsx","../src/components/shadcn-ui/sonner.tsx","../src/components/shadcn-ui/slider.tsx","../src/components/shadcn-ui/switch.tsx","../src/components/shadcn-ui/tabs.tsx","../src/components/advanced/extension-marketplace/buttons/install-button.component.tsx","../src/components/advanced/extension-marketplace/buttons/enable-button.component.tsx","../src/components/advanced/extension-marketplace/buttons/disable-button.component.tsx","../src/components/advanced/extension-marketplace/buttons/update-button.component.tsx","../src/components/advanced/extension-marketplace/markdown-renderer.component.tsx","../src/components/advanced/extension-marketplace/buttons/filter-button.component.tsx","../src/components/advanced/extension-marketplace/filter-dropdown.component.tsx","../src/components/advanced/extension-marketplace/no-extensions-found.component.tsx","../src/components/advanced/extension-marketplace/more-info.component.tsx","../src/components/advanced/extension-marketplace/version-history.component.tsx","../src/components/advanced/extension-marketplace/footer.component.tsx","../src/hooks/use-event.hook.ts","../src/hooks/use-event-async.hook.ts"],"sourcesContent":["import { type ClassValue, clsx } from 'clsx';\nimport { extendTailwindMerge } from 'tailwind-merge';\n\nconst twMergeCustom = extendTailwindMerge({ prefix: 'tw-' });\n\n/**\n * Tailwind and CSS class application helper function. Uses\n * [`clsx`](https://www.npmjs.com/package/clsx) to make it easy to apply classes conditionally using\n * object syntax, and uses [`tailwind-merge`](https://www.npmjs.com/package/tailwind-merge) to make\n * it easy to merge/overwrite Tailwind classes in a programmer-logic-friendly way.\n *\n * Note: `tailwind-merge` is configured to use the prefix `tw-`, so you must use the same prefix\n * with any Tailwind classes you use with this function to successfully overwrite other Tailwind\n * classes. `platform-bible-react` is configured to use `tw-` as its Tailwind prefix, so any\n * Tailwind classes you pass into `platform-bible-react` components will be compared using the `tw-`\n * prefix.\n *\n * This function was popularized by\n * [shadcn/ui](https://ui.shadcn.com/docs/installation/manual#add-a-cn-helper). See [ByteGrad's\n * explanation video](https://www.youtube.com/watch?v=re2JFITR7TI) for more information.\n *\n * @example\n *\n * ```typescript\n * const borderShouldBeBlue = true;\n * const textShouldBeRed = true;\n * const heightShouldBe20 = false;\n * const classString = cn(\n * 'tw-bg-primary tw-h-10 tw-text-primary-foreground',\n * 'tw-bg-secondary',\n * {\n * 'tw-border-blue-500': borderShouldBeBlue,\n * 'tw-text-red-500': textShouldBeRed,\n * 'tw-h-20': heightShouldBe20,\n * },\n * 'some-class',\n * );\n * ```\n *\n * The resulting `classString` is `'tw-h-10 tw-bg-secondary tw-border-blue-500 tw-text-red-500\n * some-class'`\n *\n * - Notice that `'tw-bg-secondary'`, specified later, overwrote `'tw-bg-primary'`, specified earlier,\n * because they are Tailwind classes that affect the same css property\n * - Notice that `'tw-text-red-500'`, specified later, overwrote `'tw-text-primary-foreground'`,\n * specified earlier, because they are Tailwind classes that affect the same css property\n * - Notice that `'tw-h-20'`, specified later, did not overwrite `'tw-h-10'`, specified earlier,\n * because `'tw-h-20'` is part of a conditional class object and its value evaluated to `false`;\n * therefore it was not applied\n * - Notice that `'some-class'` was applied. This function is not limited only to Tailwind classes.\n *\n *\n * @param inputs Class strings or `clsx` conditional class objects to merge. Tailwind classes\n * specified later in the arguments overwrite similar Tailwind classes specified earlier in the\n * arguments\n * @returns Class string containing all applicable classes from the arguments based on the rules\n * described above\n */\n// shadcn/ui uses this export in its boilerplate code\n// eslint-disable-next-line import/prefer-default-export\nexport function cn(...inputs: ClassValue[]) {\n return twMergeCustom(clsx(inputs));\n}\n","import React from 'react';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport interface InputProps extends React.InputHTMLAttributes {}\n\nexport const Input = React.forwardRef(\n ({ className, type, ...props }, ref) => {\n return (\n \n );\n },\n);\nInput.displayName = 'Input';\n","import { FocusEventHandler, forwardRef, KeyboardEvent, MouseEventHandler } from 'react';\nimport { History } from 'lucide-react';\nimport { Input as ShadInput } from '@/components/shadcn-ui/input';\n\nexport type BookChapterInputProps = {\n handleSearch: (searchString: string) => void;\n handleKeyDown: (event: KeyboardEvent) => void;\n handleOnClick: MouseEventHandler;\n handleSubmit: () => void;\n onFocus?: FocusEventHandler;\n value: string;\n placeholder: string;\n};\n\n// Shadcn Input sets type to \"button\"- HAVE to prop spread before setting type\nconst BookChapterInput = forwardRef(\n (\n { handleSearch, handleKeyDown, handleOnClick, handleSubmit, ...props }: BookChapterInputProps,\n ref,\n ) => {\n return (\n
    \n handleSearch(event.target.value)}\n onKeyDown={(e) => {\n if (e.key === 'Enter') {\n handleSubmit();\n }\n handleKeyDown(e);\n }}\n onClick={handleOnClick}\n ref={ref}\n />\n {\n // eslint-disable-next-line no-console\n console.log('back in history');\n }}\n />\n
    \n );\n },\n);\n\nexport default BookChapterInput;\n","var P = Object.defineProperty;\nvar R = (t, e, s) => e in t ? P(t, e, { enumerable: !0, configurable: !0, writable: !0, value: s }) : t[e] = s;\nvar n = (t, e, s) => R(t, typeof e != \"symbol\" ? e + \"\" : e, s);\nclass _ {\n constructor() {\n n(this, \"books\");\n n(this, \"firstSelectedBookNum\");\n n(this, \"lastSelectedBookNum\");\n n(this, \"count\");\n n(this, \"selectedBookNumbers\");\n n(this, \"selectedBookIds\");\n }\n}\nconst N = [\n \"GEN\",\n \"EXO\",\n \"LEV\",\n \"NUM\",\n \"DEU\",\n \"JOS\",\n \"JDG\",\n \"RUT\",\n \"1SA\",\n \"2SA\",\n // 10\n \"1KI\",\n \"2KI\",\n \"1CH\",\n \"2CH\",\n \"EZR\",\n \"NEH\",\n \"EST\",\n \"JOB\",\n \"PSA\",\n \"PRO\",\n // 20\n \"ECC\",\n \"SNG\",\n \"ISA\",\n \"JER\",\n \"LAM\",\n \"EZK\",\n \"DAN\",\n \"HOS\",\n \"JOL\",\n \"AMO\",\n // 30\n \"OBA\",\n \"JON\",\n \"MIC\",\n \"NAM\",\n \"HAB\",\n \"ZEP\",\n \"HAG\",\n \"ZEC\",\n \"MAL\",\n \"MAT\",\n // 40\n \"MRK\",\n \"LUK\",\n \"JHN\",\n \"ACT\",\n \"ROM\",\n \"1CO\",\n \"2CO\",\n \"GAL\",\n \"EPH\",\n \"PHP\",\n // 50\n \"COL\",\n \"1TH\",\n \"2TH\",\n \"1TI\",\n \"2TI\",\n \"TIT\",\n \"PHM\",\n \"HEB\",\n \"JAS\",\n \"1PE\",\n // 60\n \"2PE\",\n \"1JN\",\n \"2JN\",\n \"3JN\",\n \"JUD\",\n \"REV\",\n \"TOB\",\n \"JDT\",\n \"ESG\",\n \"WIS\",\n // 70\n \"SIR\",\n \"BAR\",\n \"LJE\",\n \"S3Y\",\n \"SUS\",\n \"BEL\",\n \"1MA\",\n \"2MA\",\n \"3MA\",\n \"4MA\",\n // 80\n \"1ES\",\n \"2ES\",\n \"MAN\",\n \"PS2\",\n \"ODA\",\n \"PSS\",\n \"JSA\",\n // actual variant text for JOS, now in LXA text\n \"JDB\",\n // actual variant text for JDG, now in LXA text\n \"TBS\",\n // actual variant text for TOB, now in LXA text\n \"SST\",\n // actual variant text for SUS, now in LXA text // 90\n \"DNT\",\n // actual variant text for DAN, now in LXA text\n \"BLT\",\n // actual variant text for BEL, now in LXA text\n \"XXA\",\n \"XXB\",\n \"XXC\",\n \"XXD\",\n \"XXE\",\n \"XXF\",\n \"XXG\",\n \"FRT\",\n // 100\n \"BAK\",\n \"OTH\",\n \"3ES\",\n // Used previously but really should be 2ES\n \"EZA\",\n // Used to be called 4ES, but not actually in any known project\n \"5EZ\",\n // Used to be called 5ES, but not actually in any known project\n \"6EZ\",\n // Used to be called 6ES, but not actually in any known project\n \"INT\",\n \"CNC\",\n \"GLO\",\n \"TDX\",\n // 110\n \"NDX\",\n \"DAG\",\n \"PS3\",\n \"2BA\",\n \"LBA\",\n \"JUB\",\n \"ENO\",\n \"1MQ\",\n \"2MQ\",\n \"3MQ\",\n // 120\n \"REP\",\n \"4BA\",\n \"LAO\"\n], B = [\n \"XXA\",\n \"XXB\",\n \"XXC\",\n \"XXD\",\n \"XXE\",\n \"XXF\",\n \"XXG\",\n \"FRT\",\n \"BAK\",\n \"OTH\",\n \"INT\",\n \"CNC\",\n \"GLO\",\n \"TDX\",\n \"NDX\"\n], O = [\n \"Genesis\",\n \"Exodus\",\n \"Leviticus\",\n \"Numbers\",\n \"Deuteronomy\",\n \"Joshua\",\n \"Judges\",\n \"Ruth\",\n \"1 Samuel\",\n \"2 Samuel\",\n \"1 Kings\",\n \"2 Kings\",\n \"1 Chronicles\",\n \"2 Chronicles\",\n \"Ezra\",\n \"Nehemiah\",\n \"Esther (Hebrew)\",\n \"Job\",\n \"Psalms\",\n \"Proverbs\",\n \"Ecclesiastes\",\n \"Song of Songs\",\n \"Isaiah\",\n \"Jeremiah\",\n \"Lamentations\",\n \"Ezekiel\",\n \"Daniel (Hebrew)\",\n \"Hosea\",\n \"Joel\",\n \"Amos\",\n \"Obadiah\",\n \"Jonah\",\n \"Micah\",\n \"Nahum\",\n \"Habakkuk\",\n \"Zephaniah\",\n \"Haggai\",\n \"Zechariah\",\n \"Malachi\",\n \"Matthew\",\n \"Mark\",\n \"Luke\",\n \"John\",\n \"Acts\",\n \"Romans\",\n \"1 Corinthians\",\n \"2 Corinthians\",\n \"Galatians\",\n \"Ephesians\",\n \"Philippians\",\n \"Colossians\",\n \"1 Thessalonians\",\n \"2 Thessalonians\",\n \"1 Timothy\",\n \"2 Timothy\",\n \"Titus\",\n \"Philemon\",\n \"Hebrews\",\n \"James\",\n \"1 Peter\",\n \"2 Peter\",\n \"1 John\",\n \"2 John\",\n \"3 John\",\n \"Jude\",\n \"Revelation\",\n \"Tobit\",\n \"Judith\",\n \"Esther Greek\",\n \"Wisdom of Solomon\",\n \"Sirach (Ecclesiasticus)\",\n \"Baruch\",\n \"Letter of Jeremiah\",\n \"Song of 3 Young Men\",\n \"Susanna\",\n \"Bel and the Dragon\",\n \"1 Maccabees\",\n \"2 Maccabees\",\n \"3 Maccabees\",\n \"4 Maccabees\",\n \"1 Esdras (Greek)\",\n \"2 Esdras (Latin)\",\n \"Prayer of Manasseh\",\n \"Psalm 151\",\n \"Odes\",\n \"Psalms of Solomon\",\n // WARNING, if you change the spelling of the *obsolete* tag be sure to update\n // IsObsolete routine\n \"Joshua A. *obsolete*\",\n \"Judges B. *obsolete*\",\n \"Tobit S. *obsolete*\",\n \"Susanna Th. *obsolete*\",\n \"Daniel Th. *obsolete*\",\n \"Bel Th. *obsolete*\",\n \"Extra A\",\n \"Extra B\",\n \"Extra C\",\n \"Extra D\",\n \"Extra E\",\n \"Extra F\",\n \"Extra G\",\n \"Front Matter\",\n \"Back Matter\",\n \"Other Matter\",\n \"3 Ezra *obsolete*\",\n \"Apocalypse of Ezra\",\n \"5 Ezra (Latin Prologue)\",\n \"6 Ezra (Latin Epilogue)\",\n \"Introduction\",\n \"Concordance \",\n \"Glossary \",\n \"Topical Index\",\n \"Names Index\",\n \"Daniel Greek\",\n \"Psalms 152-155\",\n \"2 Baruch (Apocalypse)\",\n \"Letter of Baruch\",\n \"Jubilees\",\n \"Enoch\",\n \"1 Meqabyan\",\n \"2 Meqabyan\",\n \"3 Meqabyan\",\n \"Reproof (Proverbs 25-31)\",\n \"4 Baruch (Rest of Baruch)\",\n \"Laodiceans\"\n], S = K();\nfunction g(t, e = !0) {\n return e && (t = t.toUpperCase()), t in S ? S[t] : 0;\n}\nfunction k(t) {\n return g(t) > 0;\n}\nfunction x(t) {\n const e = typeof t == \"string\" ? g(t) : t;\n return e >= 40 && e <= 66;\n}\nfunction T(t) {\n return (typeof t == \"string\" ? g(t) : t) <= 39;\n}\nfunction X(t) {\n return t <= 66;\n}\nfunction V(t) {\n const e = typeof t == \"string\" ? g(t) : t;\n return w(e) && !X(e);\n}\nfunction* L() {\n for (let t = 1; t <= N.length; t++) yield t;\n}\nconst G = 1, A = N.length;\nfunction H() {\n return [\"XXA\", \"XXB\", \"XXC\", \"XXD\", \"XXE\", \"XXF\", \"XXG\"];\n}\nfunction C(t, e = \"***\") {\n const s = t - 1;\n return s < 0 || s >= N.length ? e : N[s];\n}\nfunction I(t) {\n return t <= 0 || t > A ? \"******\" : O[t - 1];\n}\nfunction y(t) {\n return I(g(t));\n}\nfunction w(t) {\n const e = typeof t == \"number\" ? C(t) : t;\n return k(e) && !B.includes(e);\n}\nfunction q(t) {\n const e = typeof t == \"number\" ? C(t) : t;\n return k(e) && B.includes(e);\n}\nfunction U(t) {\n return O[t - 1].includes(\"*obsolete*\");\n}\nfunction K() {\n const t = {};\n for (let e = 0; e < N.length; e++)\n t[N[e]] = e + 1;\n return t;\n}\nconst m = {\n allBookIds: N,\n nonCanonicalIds: B,\n bookIdToNumber: g,\n isBookIdValid: k,\n isBookNT: x,\n isBookOT: T,\n isBookOTNT: X,\n isBookDC: V,\n allBookNumbers: L,\n firstBook: G,\n lastBook: A,\n extraBooks: H,\n bookNumberToId: C,\n bookNumberToEnglishName: I,\n bookIdToEnglishName: y,\n isCanonical: w,\n isExtraMaterial: q,\n isObsolete: U\n};\nvar l = /* @__PURE__ */ ((t) => (t[t.Unknown = 0] = \"Unknown\", t[t.Original = 1] = \"Original\", t[t.Septuagint = 2] = \"Septuagint\", t[t.Vulgate = 3] = \"Vulgate\", t[t.English = 4] = \"English\", t[t.RussianProtestant = 5] = \"RussianProtestant\", t[t.RussianOrthodox = 6] = \"RussianOrthodox\", t))(l || {});\nconst h = class h {\n // private versInfo: Versification;\n constructor(e) {\n n(this, \"name\");\n n(this, \"fullPath\");\n n(this, \"isPresent\");\n n(this, \"hasVerseSegments\");\n n(this, \"isCustomized\");\n n(this, \"baseVersification\");\n n(this, \"scriptureBooks\");\n n(this, \"_type\");\n if (e == null)\n throw new Error(\"Argument undefined\");\n typeof e == \"string\" ? (this.name = e, this._type = l[e]) : (this._type = e, this.name = l[e]);\n }\n get type() {\n return this._type;\n }\n equals(e) {\n return !e.type || !this.type ? !1 : e.type === this.type;\n }\n};\nn(h, \"Original\", new h(l.Original)), n(h, \"Septuagint\", new h(l.Septuagint)), n(h, \"Vulgate\", new h(l.Vulgate)), n(h, \"English\", new h(l.English)), n(h, \"RussianProtestant\", new h(l.RussianProtestant)), n(h, \"RussianOrthodox\", new h(l.RussianOrthodox));\nlet c = h;\nfunction E(t, e) {\n const s = e[0];\n for (let r = 1; r < e.length; r++)\n t = t.split(e[r]).join(s);\n return t.split(s);\n}\nvar D = /* @__PURE__ */ ((t) => (t[t.Valid = 0] = \"Valid\", t[t.UnknownVersification = 1] = \"UnknownVersification\", t[t.OutOfRange = 2] = \"OutOfRange\", t[t.VerseOutOfOrder = 3] = \"VerseOutOfOrder\", t[t.VerseRepeated = 4] = \"VerseRepeated\", t))(D || {});\nconst i = class i {\n constructor(e, s, r, a) {\n /** Not yet implemented. */\n n(this, \"firstChapter\");\n /** Not yet implemented. */\n n(this, \"lastChapter\");\n /** Not yet implemented. */\n n(this, \"lastVerse\");\n /** Not yet implemented. */\n n(this, \"hasSegmentsDefined\");\n /** Not yet implemented. */\n n(this, \"text\");\n /** Not yet implemented. */\n n(this, \"BBBCCCVVVS\");\n /** Not yet implemented. */\n n(this, \"longHashCode\");\n /** The versification of the reference. */\n n(this, \"versification\");\n n(this, \"rtlMark\", \"‏\");\n n(this, \"_bookNum\", 0);\n n(this, \"_chapterNum\", 0);\n n(this, \"_verseNum\", 0);\n n(this, \"_verse\");\n if (r == null && a == null)\n if (e != null && typeof e == \"string\") {\n const o = e, u = s != null && s instanceof c ? s : void 0;\n this.setEmpty(u), this.parse(o);\n } else if (e != null && typeof e == \"number\") {\n const o = s != null && s instanceof c ? s : void 0;\n this.setEmpty(o), this._verseNum = e % i.chapterDigitShifter, this._chapterNum = Math.floor(\n e % i.bookDigitShifter / i.chapterDigitShifter\n ), this._bookNum = Math.floor(e / i.bookDigitShifter);\n } else if (s == null)\n if (e != null && e instanceof i) {\n const o = e;\n this._bookNum = o.bookNum, this._chapterNum = o.chapterNum, this._verseNum = o.verseNum, this._verse = o.verse, this.versification = o.versification;\n } else {\n if (e == null) return;\n const o = e instanceof c ? e : i.defaultVersification;\n this.setEmpty(o);\n }\n else\n throw new Error(\"VerseRef constructor not supported.\");\n else if (e != null && s != null && r != null)\n if (typeof e == \"string\" && typeof s == \"string\" && typeof r == \"string\")\n this.setEmpty(a), this.updateInternal(e, s, r);\n else if (typeof e == \"number\" && typeof s == \"number\" && typeof r == \"number\")\n this._bookNum = e, this._chapterNum = s, this._verseNum = r, this.versification = a ?? i.defaultVersification;\n else\n throw new Error(\"VerseRef constructor not supported.\");\n else\n throw new Error(\"VerseRef constructor not supported.\");\n }\n /**\n * Determines if the verse string is in a valid format (does not consider versification).\n */\n static isVerseParseable(e) {\n return e.length > 0 && \"0123456789\".includes(e[0]) && !e.endsWith(this.verseRangeSeparator) && !e.endsWith(this.verseSequenceIndicator);\n }\n /**\n * Tries to parse the specified string into a verse reference.\n * @param str - The string to attempt to parse.\n * @returns success: `true` if the specified string was successfully parsed, `false` otherwise.\n * @returns verseRef: The result of the parse if successful, or empty VerseRef if it failed\n */\n static tryParse(e) {\n let s;\n try {\n return s = new i(e), { success: !0, verseRef: s };\n } catch (r) {\n if (r instanceof v)\n return s = new i(), { success: !1, verseRef: s };\n throw r;\n }\n }\n /**\n * Gets the reference as a comparable integer where the book, chapter, and verse each occupy 3\n * digits.\n * @param bookNum - Book number (this is 1-based, not an index).\n * @param chapterNum - Chapter number.\n * @param verseNum - Verse number.\n * @returns The reference as a comparable integer where the book, chapter, and verse each occupy 3\n * digits.\n */\n static getBBBCCCVVV(e, s, r) {\n return e % i.bcvMaxValue * i.bookDigitShifter + (s >= 0 ? s % i.bcvMaxValue * i.chapterDigitShifter : 0) + (r >= 0 ? r % i.bcvMaxValue : 0);\n }\n /**\n * Deserializes a serialized VerseRef.\n * @param serializedVerseRef - Serialized VerseRef to create from.\n * @returns the deserialized VerseRef.\n */\n static fromJSON(e) {\n const { book: s, chapterNum: r, verseNum: a, verse: o, versificationStr: u } = e, f = o || a.toString();\n let d;\n return u && (d = new c(u)), s ? new i(s, r.toString(), f, d) : new i();\n }\n /**\n * Parses a verse string and gets the leading numeric portion as a number.\n * @param verseStr - verse string to parse\n * @returns true if the entire string could be parsed as a single, simple verse number (1-999);\n * false if the verse string represented a verse bridge, contained segment letters, or was invalid\n */\n static tryGetVerseNum(e) {\n let s;\n if (!e)\n return s = -1, { success: !0, vNum: s };\n s = 0;\n let r;\n for (let a = 0; a < e.length; a++) {\n if (r = e[a], r < \"0\" || r > \"9\")\n return a === 0 && (s = -1), { success: !1, vNum: s };\n if (s = s * 10 + +r - 0, s > i.bcvMaxValue)\n return s = -1, { success: !1, vNum: s };\n }\n return { success: !0, vNum: s };\n }\n /**\n * Checks to see if a VerseRef hasn't been set - all values are the default.\n */\n get isDefault() {\n return this.bookNum === 0 && this.chapterNum === 0 && this.verseNum === 0 && this.versification == null;\n }\n /**\n * Gets whether the verse contains multiple verses.\n */\n get hasMultiple() {\n return this._verse != null && (this._verse.includes(i.verseRangeSeparator) || this._verse.includes(i.verseSequenceIndicator));\n }\n /**\n * Gets or sets the book of the reference. Book is the 3-letter abbreviation in capital letters,\n * e.g. `'MAT'`.\n */\n get book() {\n return m.bookNumberToId(this.bookNum, \"\");\n }\n set book(e) {\n this.bookNum = m.bookIdToNumber(e);\n }\n /**\n * Gets or sets the chapter of the reference,. e.g. `'3'`.\n */\n get chapter() {\n return this.isDefault || this._chapterNum < 0 ? \"\" : this._chapterNum.toString();\n }\n set chapter(e) {\n const s = +e;\n this._chapterNum = Number.isInteger(s) ? s : -1;\n }\n /**\n * Gets or sets the verse of the reference, including range, segments, and sequences, e.g. `'4'`,\n * or `'4b-5a, 7'`.\n */\n get verse() {\n return this._verse != null ? this._verse : this.isDefault || this._verseNum < 0 ? \"\" : this._verseNum.toString();\n }\n set verse(e) {\n const { success: s, vNum: r } = i.tryGetVerseNum(e);\n this._verse = s ? void 0 : e.replace(this.rtlMark, \"\"), this._verseNum = r, !(this._verseNum >= 0) && ({ vNum: this._verseNum } = i.tryGetVerseNum(this._verse));\n }\n /**\n * Get or set Book based on book number, e.g. `42`.\n */\n get bookNum() {\n return this._bookNum;\n }\n set bookNum(e) {\n if (e <= 0 || e > m.lastBook)\n throw new v(\n \"BookNum must be greater than zero and less than or equal to last book\"\n );\n this._bookNum = e;\n }\n /**\n * Gets or sets the chapter number, e.g. `3`. `-1` if not valid.\n */\n get chapterNum() {\n return this._chapterNum;\n }\n set chapterNum(e) {\n this.chapterNum = e;\n }\n /**\n * Gets or sets verse start number, e.g. `4`. `-1` if not valid.\n */\n get verseNum() {\n return this._verseNum;\n }\n set verseNum(e) {\n this._verseNum = e;\n }\n /**\n * String representing the versification (should ONLY be used for serialization/deserialization).\n *\n * @remarks This is for backwards compatibility when ScrVers was an enumeration.\n */\n get versificationStr() {\n var e;\n return (e = this.versification) == null ? void 0 : e.name;\n }\n set versificationStr(e) {\n this.versification = this.versification != null ? new c(e) : void 0;\n }\n /**\n * Determines if the reference is valid.\n */\n get valid() {\n return this.validStatus === 0;\n }\n /**\n * Get the valid status for this reference.\n */\n get validStatus() {\n return this.validateVerse(i.verseRangeSeparators, i.verseSequenceIndicators);\n }\n /**\n * Gets the reference as a comparable integer where the book,\n * chapter, and verse each occupy three digits and the verse is 0.\n */\n get BBBCCC() {\n return i.getBBBCCCVVV(this._bookNum, this._chapterNum, 0);\n }\n /**\n * Gets the reference as a comparable integer where the book,\n * chapter, and verse each occupy three digits. If verse is not null\n * (i.e., this reference represents a complex reference with verse\n * segments or bridge) this cannot be used for an exact comparison.\n */\n get BBBCCCVVV() {\n return i.getBBBCCCVVV(this._bookNum, this._chapterNum, this._verseNum);\n }\n /**\n * Gets whether the verse is defined as an excluded verse in the versification.\n * Does not handle verse ranges.\n */\n // eslint-disable-next-line @typescript-eslint/class-literal-property-style\n get isExcluded() {\n return !1;\n }\n /**\n * Parses the reference in the specified string.\n * Optionally versification can follow reference as in GEN 3:11/4\n * Throw an exception if\n * - invalid book name\n * - chapter number is missing or not a number\n * - verse number is missing or does not start with a number\n * - versification is invalid\n * @param verseStr - string to parse e.g. 'MAT 3:11'\n */\n parse(e) {\n if (e = e.replace(this.rtlMark, \"\"), e.includes(\"/\")) {\n const o = e.split(\"/\");\n if (e = o[0], o.length > 1)\n try {\n const u = +o[1].trim();\n this.versification = new c(l[u]);\n } catch {\n throw new v(\"Invalid reference : \" + e);\n }\n }\n const s = e.trim().split(\" \");\n if (s.length !== 2)\n throw new v(\"Invalid reference : \" + e);\n const r = s[1].split(\":\"), a = +r[0];\n if (r.length !== 2 || m.bookIdToNumber(s[0]) === 0 || !Number.isInteger(a) || a < 0 || !i.isVerseParseable(r[1]))\n throw new v(\"Invalid reference : \" + e);\n this.updateInternal(s[0], r[0], r[1]);\n }\n /**\n * Simplifies this verse ref so that it has no bridging of verses or\n * verse segments like `'1a'`.\n */\n simplify() {\n this._verse = void 0;\n }\n /**\n * Makes a clone of the reference.\n *\n * @returns The cloned VerseRef.\n */\n clone() {\n return new i(this);\n }\n toString() {\n const e = this.book;\n return e === \"\" ? \"\" : `${e} ${this.chapter}:${this.verse}`;\n }\n toJSON() {\n let e = this.verse;\n (e === \"\" || e === this.verseNum.toString()) && (e = void 0);\n const s = {\n book: this.book,\n chapterNum: this.chapterNum,\n verseNum: this.verseNum,\n verse: e,\n versificationStr: this.versificationStr\n };\n return e || delete s.verse, s;\n }\n /**\n * Compares this `VerseRef` with supplied one.\n * @param verseRef - object to compare this one to.\n * @returns `true` if this `VerseRef` is equal to the supplied one, `false` otherwise.\n */\n equals(e) {\n return e instanceof i ? e._bookNum === this._bookNum && e._chapterNum === this._chapterNum && e._verseNum === this._verseNum && e.verse === this.verse && (e.versification == null && this.versification == null || e.versification != null && this.versification != null && e.versification.equals(this.versification)) : !1;\n }\n /**\n * Enumerate all individual verses contained in a VerseRef.\n * Verse ranges are indicated by \"-\" and consecutive verses by \",\"s.\n * Examples:\n * GEN 1:2 returns GEN 1:2\n * GEN 1:1a-3b,5 returns GEN 1:1a, GEN 1:2, GEN 1:3b, GEN 1:5\n * GEN 1:2a-2c returns //! ??????\n *\n * @param specifiedVersesOnly - if set to true return only verses that are\n * explicitly specified only, not verses within a range. Defaults to `false`.\n * @param verseRangeSeparators - Verse range separators.\n * Defaults to `VerseRef.verseRangeSeparators`.\n * @param verseSequenceSeparators - Verse sequence separators.\n * Defaults to `VerseRef.verseSequenceIndicators`.\n * @returns An array of all single verse references in this VerseRef.\n */\n allVerses(e = !1, s = i.verseRangeSeparators, r = i.verseSequenceIndicators) {\n if (this._verse == null || this.chapterNum <= 0)\n return [this.clone()];\n const a = [], o = E(this._verse, r);\n for (const u of o.map((f) => E(f, s))) {\n const f = this.clone();\n f.verse = u[0];\n const d = f.verseNum;\n if (a.push(f), u.length > 1) {\n const b = this.clone();\n if (b.verse = u[1], !e)\n for (let p = d + 1; p < b.verseNum; p++) {\n const J = new i(\n this._bookNum,\n this._chapterNum,\n p,\n this.versification\n );\n this.isExcluded || a.push(J);\n }\n a.push(b);\n }\n }\n return a;\n }\n /**\n * Validates a verse number using the supplied separators rather than the defaults.\n */\n validateVerse(e, s) {\n if (!this.verse)\n return this.internalValid;\n let r = 0;\n for (const a of this.allVerses(!0, e, s)) {\n const o = a.internalValid;\n if (o !== 0)\n return o;\n const u = a.BBBCCCVVV;\n if (r > u)\n return 3;\n if (r === u)\n return 4;\n r = u;\n }\n return 0;\n }\n /**\n * Gets whether a single verse reference is valid.\n */\n get internalValid() {\n return this.versification == null ? 1 : this._bookNum <= 0 || this._bookNum > m.lastBook ? 2 : (m.isCanonical(this._bookNum), 0);\n }\n setEmpty(e = i.defaultVersification) {\n this._bookNum = 0, this._chapterNum = -1, this._verse = void 0, this.versification = e;\n }\n updateInternal(e, s, r) {\n this.bookNum = m.bookIdToNumber(e), this.chapter = s, this.verse = r;\n }\n};\nn(i, \"defaultVersification\", c.English), n(i, \"verseRangeSeparator\", \"-\"), n(i, \"verseSequenceIndicator\", \",\"), n(i, \"verseRangeSeparators\", [i.verseRangeSeparator]), n(i, \"verseSequenceIndicators\", [i.verseSequenceIndicator]), n(i, \"chapterDigitShifter\", 1e3), n(i, \"bookDigitShifter\", i.chapterDigitShifter * i.chapterDigitShifter), n(i, \"bcvMaxValue\", i.chapterDigitShifter - 1), /**\n * The valid status of the VerseRef.\n */\nn(i, \"ValidStatusType\", D);\nlet M = i;\nclass v extends Error {\n}\nexport {\n _ as BookSet,\n m as Canon,\n c as ScrVers,\n l as ScrVersType,\n M as VerseRef,\n v as VerseRefException\n};\n//# sourceMappingURL=index.es.js.map\n","import React from 'react';\nimport * as DropdownMenuPrimitive from '@radix-ui/react-dropdown-menu';\nimport { Check, ChevronRight, Circle } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport const DropdownMenu = DropdownMenuPrimitive.Root;\n\nexport const DropdownMenuTrigger = DropdownMenuPrimitive.Trigger;\n\nexport const DropdownMenuGroup = DropdownMenuPrimitive.Group;\n\nexport const DropdownMenuPortal = DropdownMenuPrimitive.Portal;\n\nexport const DropdownMenuSub = DropdownMenuPrimitive.Sub;\n\nexport const DropdownMenuRadioGroup = DropdownMenuPrimitive.RadioGroup;\n\nexport type DropdownMenuSubTriggerProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.SubTrigger\n> & {\n className?: string;\n inset?: boolean;\n};\n\nexport type DropdownMenuSubContentProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.SubContent\n> & {\n className?: string;\n};\n\nexport type DropdownMenuContentProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Content\n> & {\n className?: string;\n sideOffset?: number;\n};\n\nexport type DropdownMenuItemProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Item\n> & {\n className?: string;\n inset?: boolean;\n};\n\nexport type DropdownMenuCheckboxItemProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.CheckboxItem\n> & {\n className?: string;\n checked?: boolean;\n};\n\nexport type DropdownMenuRadioItemProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.RadioItem\n> & {\n className?: string;\n};\n\nexport type DropdownMenuLabelProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Label\n> & {\n className?: string;\n inset?: boolean;\n};\n\nexport type DropdownMenuSeparatorProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Separator\n> & {\n className?: string;\n};\n\nexport type DropdownMenuShortcutProps = React.HTMLAttributes & {\n className?: string;\n};\n\nexport const DropdownMenuSubTrigger = React.forwardRef<\n React.ElementRef,\n DropdownMenuSubTriggerProps\n>(({ className, inset, children, ...props }, ref) => (\n \n {children}\n \n \n));\nDropdownMenuSubTrigger.displayName = DropdownMenuPrimitive.SubTrigger.displayName;\n\nexport const DropdownMenuSubContent = React.forwardRef<\n React.ElementRef,\n DropdownMenuSubContentProps\n>(({ className, ...props }, ref) => (\n \n));\nDropdownMenuSubContent.displayName = DropdownMenuPrimitive.SubContent.displayName;\n\nexport const DropdownMenuContent = React.forwardRef<\n React.ElementRef,\n DropdownMenuContentProps\n>(({ className, sideOffset = 4, ...props }, ref) => (\n \n \n \n));\nDropdownMenuContent.displayName = DropdownMenuPrimitive.Content.displayName;\n\n/**\n * TODO: fix: direction is not automatically handled by this component, so that shortcuts are\n * display always to the right\n */\nexport const DropdownMenuItem = React.forwardRef<\n React.ElementRef,\n DropdownMenuItemProps\n>(({ className, inset, ...props }, ref) => (\n \n));\nDropdownMenuItem.displayName = DropdownMenuPrimitive.Item.displayName;\n\nexport const DropdownMenuCheckboxItem = React.forwardRef<\n React.ElementRef,\n DropdownMenuCheckboxItemProps\n>(({ className, children, checked, ...props }, ref) => (\n \n \n \n \n \n \n {children}\n \n));\nDropdownMenuCheckboxItem.displayName = DropdownMenuPrimitive.CheckboxItem.displayName;\n\nexport const DropdownMenuRadioItem = React.forwardRef<\n React.ElementRef,\n DropdownMenuRadioItemProps\n>(({ className, children, ...props }, ref) => (\n \n \n \n \n \n \n {children}\n \n));\nDropdownMenuRadioItem.displayName = DropdownMenuPrimitive.RadioItem.displayName;\n\nexport const DropdownMenuLabel = React.forwardRef<\n React.ElementRef,\n DropdownMenuLabelProps\n>(({ className, inset, ...props }, ref) => (\n \n));\nDropdownMenuLabel.displayName = DropdownMenuPrimitive.Label.displayName;\n\nexport const DropdownMenuSeparator = React.forwardRef<\n React.ElementRef,\n DropdownMenuSeparatorProps\n>(({ className, ...props }, ref) => (\n \n));\nDropdownMenuSeparator.displayName = DropdownMenuPrimitive.Separator.displayName;\n\nexport function DropdownMenuShortcut({ className, ...props }: DropdownMenuShortcutProps) {\n return (\n \n );\n}\nDropdownMenuShortcut.displayName = 'DropdownMenuShortcut';\n","import { Canon } from '@sillsdev/scripture';\nimport { PropsWithChildren, KeyboardEvent, forwardRef } from 'react';\nimport { DropdownMenuItem as ShadDropdownMenuItem } from '@/components/shadcn-ui/dropdown-menu';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport type BookType = 'OT' | 'NT' | 'DC';\n\ntype BookMenuItemProps = PropsWithChildren<{\n /** String id of book */\n bookId: string;\n /** Callback to run when a book menu item is selected */\n handleSelectBook: () => void;\n /** Indicates if this menu item is currently selected */\n isSelected: boolean;\n /** Function that is called upon highlighting a book in the dropdown menu */\n handleHighlightBook: () => void;\n /**\n * Function that is called on pressing a key\n *\n * @param event Event that contains information about the key stroke\n */\n handleKeyDown: (event: KeyboardEvent) => void;\n /**\n * Type of book associated with this menu item, coordinates color labels ? Mock up has the labels\n * coordinated to genre\n */\n bookType: BookType;\n}>;\n\nconst BookMenuItem = forwardRef(\n (\n {\n bookId,\n handleSelectBook,\n isSelected,\n handleHighlightBook,\n handleKeyDown,\n bookType,\n children,\n }: BookMenuItemProps,\n ref,\n ) => {\n return (\n {\n // preventDefault() here prevents the entire dropdown menu from closing when selecting this item\n event.preventDefault();\n handleSelectBook();\n }}\n onKeyDown={(event: KeyboardEvent) => {\n handleKeyDown(event);\n }}\n onFocus={handleHighlightBook}\n onMouseMove={handleHighlightBook}\n >\n \n {Canon.bookIdToEnglishName(bookId)}\n \n {isSelected &&
    {children}
    }\n \n );\n },\n);\n\nexport default BookMenuItem;\n","import { cn } from '@/utils/shadcn-ui.util';\nimport { useCallback } from 'react';\n\nexport type ChapterSelectProps = {\n /**\n * Callback to run when a chapter div is selected\n *\n * @param chapterNumber Number of the chapter that has been selected\n */\n handleSelectChapter: (chapterNumber: number) => void;\n /** The highest chapter number in the book (of course equal to number of chapters in the book) */\n endChapter: number;\n /** The chapter number that is currently selected */\n activeChapter: number;\n /** The chapter number that is currently highlighted using keyboard or mouse navigation */\n highlightedChapter: number;\n /**\n * Callback to run when a chapter is highlighted by the user\n *\n * @param chapterNumber The chapter that is highlighted\n */\n handleHighlightedChapter: (chapterNumber: number) => void;\n};\n\nfunction ChapterSelect({\n handleSelectChapter,\n endChapter,\n activeChapter,\n highlightedChapter,\n handleHighlightedChapter,\n}: ChapterSelectProps) {\n const chapters = Array.from({ length: endChapter }, (_, i) => i + 1);\n\n const handleMouse = useCallback(\n (chapterNumber: number) => {\n handleHighlightedChapter(chapterNumber);\n },\n [handleHighlightedChapter],\n );\n\n return (\n
    \n {chapters.map((chapter) => (\n {\n event.preventDefault();\n event.stopPropagation();\n handleSelectChapter(chapter);\n }}\n role=\"button\"\n onKeyDown={(event) => {\n if (event.key === 'Enter') {\n handleSelectChapter(chapter);\n }\n }}\n tabIndex={0}\n onMouseMove={() => handleMouse(chapter)}\n >\n {chapter}\n
    \n ))}\n
    \n );\n}\n\nexport default ChapterSelect;\n","import { DropdownMenuLabel as ShadDropdownMenuLabel } from '@/components/shadcn-ui/dropdown-menu';\nimport { Bookmark, Clock, ArrowDownWideNarrow } from 'lucide-react';\n\nexport type GoToMenuItemProps = {\n handleSort: () => void;\n handleLocationHistory: () => void;\n handleBookmarks: () => void;\n};\n\nfunction GoToMenuItem({ handleSort, handleLocationHistory, handleBookmarks }: GoToMenuItemProps) {\n return (\n \n

    Go To

    \n
    \n \n \n \n
    \n
    \n );\n}\n\nexport default GoToMenuItem;\n","import BookChapterInput from '@/components/advanced/book-chapter-control/book-chapter-input.component';\nimport BookMenuItem, {\n BookType,\n} from '@/components/advanced/book-chapter-control/book-menu-item.component';\nimport ChapterSelect from '@/components/advanced/book-chapter-control/chapter-select.component';\nimport GoToMenuItem from '@/components/advanced/book-chapter-control/go-to-menu-item.component';\nimport {\n DropdownMenu as ShadDropdownMenu,\n DropdownMenuContent as ShadDropdownMenuContent,\n DropdownMenuLabel as ShadDropdownMenuLabel,\n DropdownMenuSeparator as ShadDropdownMenuSeparator,\n DropdownMenuTrigger as ShadDropdownMenuTrigger,\n} from '@/components/shadcn-ui/dropdown-menu';\nimport { Canon } from '@sillsdev/scripture';\nimport { ScriptureReference, getChaptersForBook } from 'platform-bible-utils';\nimport {\n KeyboardEvent as ReactKeyboardEvent,\n useCallback,\n useEffect,\n useLayoutEffect,\n useRef,\n useState,\n} from 'react';\n\ntype BookTypeLabels = {\n [bookType in BookType]: string;\n};\ntype BookChapterControlProps = {\n scrRef: ScriptureReference;\n handleSubmit: (scrRef: ScriptureReference) => void;\n};\n\nconst ALL_BOOK_IDS = Canon.allBookIds;\nconst BOOK_TYPE_LABELS: BookTypeLabels = {\n OT: 'Old Testament',\n NT: 'New Testament',\n DC: 'Deuterocanon',\n};\nconst BOOK_TYPE_ARRAY: BookType[] = ['OT', 'NT', 'DC'];\n// This is the height of three menu items to offset scrolling to the selected menu item\n// If you use menuItemRef.clientHeight- includes height of chapter div which is too big\nconst SCROLL_OFFSET = 32 + 32 + 32;\nconst SEARCH_QUERY_FORMATS = [\n /^(\\w+)$/i, // Matches a single word (book name or id)\n /^(\\w+)(?:\\s(\\d+))$/i, // Matches a word followed by a chapter number\n /^(\\w+)(?:\\s(\\d+):(\\d+))$/i, // Matches a word followed by a chapter and verse number\n];\nconst fetchGroupedBooks = (bookType: BookType) => {\n const groupedBooks = {\n OT: ALL_BOOK_IDS.filter((bookId) => Canon.isBookOT(bookId)),\n NT: ALL_BOOK_IDS.filter((bookId) => Canon.isBookNT(bookId)),\n DC: ALL_BOOK_IDS.filter((bookId) => Canon.isBookDC(bookId)),\n };\n return groupedBooks[bookType];\n};\nconst fetchEndChapter = (bookId: string) => {\n // getChaptersForBook returns -1 if not found in scrBookData\n // scrBookData only includes OT and NT, so all DC will return -1\n return getChaptersForBook(Canon.bookIdToNumber(bookId));\n};\n\n/**\n * Gets all of the English names from book ids\n *\n * @returns String[]\n */\nfunction getAllEnglishNames(): string[] {\n const allEnglishNames = ALL_BOOK_IDS.map((bookId) => {\n return Canon.bookIdToEnglishName(bookId);\n });\n return allEnglishNames;\n}\n\n/**\n * Determines if bookName is in allEnglishNames\n *\n * @param bookName Book English name\n * @returns True if bookName is included, false otherwise\n */\nfunction isValidBookEnglishName(bookName: string): boolean {\n return getAllEnglishNames().includes(bookName);\n}\n\n/**\n * Gets a bookId from given English name\n *\n * @param bookName Book English name\n * @returns BookId of provided bookName, undefined otherwise\n */\nfunction getBookIdFromEnglishName(bookName: string): string | undefined {\n // Convert bookName to lowercase and then capitalize the first letter\n const formattedBookName = bookName.toLowerCase().replace(/^\\w/, (c) => c.toUpperCase());\n\n if (isValidBookEnglishName(formattedBookName)) {\n const matchingBookId = ALL_BOOK_IDS.find((bookId) => {\n return Canon.bookIdToEnglishName(bookId) === formattedBookName;\n });\n return matchingBookId;\n }\n\n return undefined;\n}\n\nfunction BookChapterControl({ scrRef, handleSubmit }: BookChapterControlProps) {\n const [searchQuery, setSearchQuery] = useState('');\n const [selectedBookId, setSelectedBookId] = useState(\n Canon.bookNumberToId(scrRef.bookNum),\n );\n const [highlightedChapter, setHighlightedChapter] = useState(scrRef.chapterNum ?? 0);\n const [highlightedBookId, setHighlightedBookId] = useState(\n Canon.bookNumberToId(scrRef.bookNum),\n );\n const [isContentOpen, setIsContentOpen] = useState(false);\n const [isContentOpenDelayed, setIsContentOpenDelayed] = useState(isContentOpen);\n\n // This ref will always be defined\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const inputRef = useRef(undefined!);\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const contentRef = useRef(undefined!);\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const menuItemRef = useRef(undefined!);\n\n const fetchFilteredBooks = useCallback(\n (bookType: BookType) => {\n return fetchGroupedBooks(bookType).filter((bookId: string) => {\n const englishNameLowerCase = Canon.bookIdToEnglishName(bookId).toLowerCase();\n const normalizedQuery = searchQuery.replace(/[^a-zA-Z]/g, '').toLowerCase();\n return (\n englishNameLowerCase.includes(normalizedQuery) || // Match book name\n bookId.toLowerCase().includes(normalizedQuery) // Match book ID\n );\n });\n },\n [searchQuery],\n );\n\n const handleSearchInput = (searchString: string) => {\n setSearchQuery(searchString);\n };\n\n /**\n * Whether to prevent radix's logic from closing the dropdown. This is important because radix\n * tries to close the dropdown when the input first focuses, and we don't want it to do that. But\n * we don't want to prevent the dropdown from closing when we click away from the input, so we\n * don't want to just keep it open if the input is focused\n */\n const shouldPreventAutoClosing = useRef(false);\n\n const controlMenuState = useCallback((open: boolean) => {\n if (shouldPreventAutoClosing.current) {\n shouldPreventAutoClosing.current = false;\n return;\n }\n setIsContentOpen(open);\n }, []);\n\n const updateReference = useCallback(\n (bookId: string, shouldClose: boolean, chapter?: number, verse?: number) => {\n setHighlightedChapter(\n Canon.bookNumberToId(scrRef.bookNum) !== bookId ? 1 : scrRef.chapterNum,\n );\n\n if (shouldClose || fetchEndChapter(bookId) === -1) {\n handleSubmit({\n bookNum: Canon.bookIdToNumber(bookId),\n chapterNum: chapter || 1,\n verseNum: verse || 1,\n });\n\n setIsContentOpen(false);\n setSearchQuery('');\n return;\n }\n\n setSelectedBookId(selectedBookId !== bookId ? bookId : '');\n setIsContentOpen(!shouldClose);\n },\n [handleSubmit, scrRef.bookNum, scrRef.chapterNum, selectedBookId],\n );\n\n const handleSelectChapter = (chapterNumber: number) => {\n if (chapterNumber <= 0 || chapterNumber > fetchEndChapter(selectedBookId)) {\n return;\n }\n updateReference(selectedBookId, true, chapterNumber);\n };\n\n const handleInputSubmit = useCallback(() => {\n SEARCH_QUERY_FORMATS.forEach((format) => {\n const matches = searchQuery.match(format);\n if (matches) {\n // Book should be a bookId or an english name\n const [book, chapter = undefined, verse = undefined] = matches.slice(1);\n const englishName = getBookIdFromEnglishName(book);\n\n if (Canon.isBookIdValid(book) || englishName) {\n updateReference(\n englishName ?? book,\n true,\n chapter ? parseInt(chapter, 10) : 1,\n verse ? parseInt(verse, 10) : 1,\n );\n }\n }\n });\n }, [updateReference, searchQuery]);\n\n const handleKeyDownInput = useCallback(\n (event: ReactKeyboardEvent) => {\n if (!isContentOpen) {\n setIsContentOpen(true);\n } else if (event.key === 'ArrowDown' || event.key === 'ArrowUp') {\n if (\n typeof menuItemRef !== 'undefined' &&\n // Ref uses null\n // eslint-disable-next-line no-null/no-null\n menuItemRef.current !== null\n ) {\n menuItemRef.current.focus();\n } else if (\n typeof contentRef !== 'undefined' &&\n // Ref uses null\n // eslint-disable-next-line no-null/no-null\n contentRef.current !== null\n ) {\n contentRef.current.focus();\n }\n event.preventDefault();\n }\n },\n [isContentOpen],\n );\n\n const handleKeyDownContent = (event: ReactKeyboardEvent) => {\n // When the dropdown menu has focus, key strokes should give focus to the input component,\n // unless they're navigation keys (arrows and enter)\n const { key } = event;\n if (\n key === 'ArrowRight' ||\n key === 'ArrowLeft' ||\n key === 'ArrowDown' ||\n key === 'ArrowUp' ||\n key === 'Enter'\n ) {\n return;\n }\n\n inputRef.current.dispatchEvent(new KeyboardEvent('keydown', { key }));\n inputRef.current.focus();\n };\n\n const handleKeyDownMenuItem = (event: ReactKeyboardEvent) => {\n const { key } = event;\n if (highlightedBookId === selectedBookId) {\n if (key === 'Enter') {\n event.preventDefault();\n updateReference(selectedBookId, true, highlightedChapter);\n return;\n }\n\n let chapterOffSet = 0;\n if (key === 'ArrowRight') {\n if (highlightedChapter < fetchEndChapter(highlightedBookId)) {\n chapterOffSet = 1;\n } else {\n event.preventDefault();\n return;\n }\n } else if (key === 'ArrowLeft') {\n if (highlightedChapter > 1) {\n chapterOffSet = -1;\n } else {\n event.preventDefault();\n return;\n }\n } else if (key === 'ArrowDown') {\n chapterOffSet = 6;\n } else if (key === 'ArrowUp') {\n chapterOffSet = -6;\n }\n if (\n highlightedChapter + chapterOffSet <= 0 ||\n highlightedChapter + chapterOffSet > fetchEndChapter(highlightedBookId)\n ) {\n setHighlightedChapter(0);\n } else if (chapterOffSet !== 0) {\n setHighlightedChapter(highlightedChapter + chapterOffSet);\n event.preventDefault();\n }\n }\n };\n\n useEffect(() => {\n if (selectedBookId === highlightedBookId) {\n if (selectedBookId === Canon.bookNumberToId(scrRef.bookNum)) {\n setHighlightedChapter(scrRef.chapterNum);\n } else {\n setHighlightedChapter(1);\n }\n } else {\n setHighlightedChapter(0);\n }\n }, [highlightedBookId, scrRef.bookNum, scrRef.chapterNum, selectedBookId]);\n\n // The purpose of these useLayoutEffects and timeout is to delay the scroll just\n // enough so that the refs are defined and available when they are used after the timeout\n useLayoutEffect(() => {\n setIsContentOpenDelayed(isContentOpen);\n }, [isContentOpen]);\n\n useLayoutEffect(() => {\n const scrollTimeout = setTimeout(() => {\n if (isContentOpenDelayed && contentRef.current && menuItemRef.current) {\n const menuItemOffsetTop = menuItemRef.current.offsetTop;\n const scrollPosition = menuItemOffsetTop - SCROLL_OFFSET;\n contentRef.current.scrollTo({ top: scrollPosition, behavior: 'instant' });\n }\n }, 10);\n return () => {\n clearTimeout(scrollTimeout);\n };\n }, [isContentOpenDelayed]);\n\n return (\n
    \n \n \n {\n setSelectedBookId(Canon.bookNumberToId(scrRef.bookNum));\n setHighlightedBookId(Canon.bookNumberToId(scrRef.bookNum));\n setHighlightedChapter(scrRef.chapterNum > 0 ? scrRef.chapterNum : 0);\n setIsContentOpen(true);\n inputRef.current.focus();\n }}\n onFocus={() => {\n // Radix thinks we want to close because the input is being focused. Prevent that\n shouldPreventAutoClosing.current = true;\n }}\n handleSubmit={handleInputSubmit}\n placeholder={`${Canon.bookNumberToEnglishName(scrRef.bookNum)} ${scrRef.chapterNum}:${scrRef.verseNum}`}\n />\n \n \n console.log('sorting')}\n handleLocationHistory={() => console.log('location history')}\n handleBookmarks={() => console.log('bookmarks')}\n />\n {BOOK_TYPE_ARRAY.map(\n (bookType, bookTypeIndex) =>\n fetchFilteredBooks(bookType).length > 0 && (\n
    \n \n {BOOK_TYPE_LABELS[bookType]}\n \n\n {fetchFilteredBooks(bookType).map((bookId) => (\n
    \n updateReference(bookId, false)}\n isSelected={selectedBookId === bookId}\n handleHighlightBook={() => setHighlightedBookId(bookId)}\n handleKeyDown={handleKeyDownMenuItem}\n bookType={bookType}\n ref={(element: HTMLDivElement) => {\n if (selectedBookId === bookId) menuItemRef.current = element;\n }}\n >\n {\n setHighlightedChapter(chapterNumber);\n }}\n />\n \n
    \n ))}\n {BOOK_TYPE_ARRAY.length - 1 !== bookTypeIndex ? (\n \n ) : undefined}\n
    \n ),\n )}\n \n
    \n
    \n );\n}\n\nexport default BookChapterControl;\n","import React from 'react';\nimport { Slot } from '@radix-ui/react-slot';\nimport { cva, type VariantProps } from 'class-variance-authority';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport const buttonVariants = cva(\n 'pr-twp tw-inline-flex tw-items-center tw-justify-center tw-whitespace-nowrap tw-rounded-md tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-colors focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50',\n {\n variants: {\n variant: {\n default: 'tw-bg-primary tw-text-primary-foreground hover:tw-bg-primary/90',\n destructive: 'tw-bg-destructive tw-text-destructive-foreground hover:tw-bg-destructive/90',\n outline:\n 'tw-border tw-border-input tw-bg-background hover:tw-bg-accent hover:tw-text-accent-foreground',\n secondary: 'tw-bg-secondary tw-text-secondary-foreground hover:tw-bg-secondary/80',\n ghost: 'hover:tw-bg-accent hover:tw-text-accent-foreground',\n link: 'tw-text-primary tw-underline-offset-4 hover:tw-underline',\n },\n size: {\n default: 'tw-h-10 tw-px-4 tw-py-2',\n sm: 'tw-h-9 tw-rounded-md tw-px-3',\n lg: 'tw-h-11 tw-rounded-md tw-px-8',\n icon: 'tw-h-10 tw-w-10',\n },\n },\n defaultVariants: {\n variant: 'default',\n size: 'default',\n },\n },\n);\n\nexport interface ButtonProps\n extends React.ButtonHTMLAttributes,\n VariantProps {\n asChild?: boolean;\n}\n\nexport const Button = React.forwardRef(\n ({ className, variant, size, asChild = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'button';\n return (\n \n );\n },\n);\nButton.displayName = 'Button';\n","import React from 'react';\nimport * as LabelPrimitive from '@radix-ui/react-label';\nimport { cva, type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst labelVariants = cva(\n 'tw-text-sm tw-font-medium tw-leading-none peer-disabled:tw-cursor-not-allowed peer-disabled:tw-opacity-70',\n);\n\nexport const Label = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef & VariantProps\n>(({ className, ...props }, ref) => (\n \n));\nLabel.displayName = LabelPrimitive.Root.displayName;\n","import React from 'react';\nimport * as RadioGroupPrimitive from '@radix-ui/react-radio-group';\nimport { Circle } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst RadioGroup = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => {\n return (\n \n );\n});\nRadioGroup.displayName = RadioGroupPrimitive.Root.displayName;\n\nconst RadioGroupItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => {\n return (\n \n \n \n \n \n );\n});\nRadioGroupItem.displayName = RadioGroupPrimitive.Item.displayName;\n\nexport { RadioGroup, RadioGroupItem };\n","import React from 'react';\nimport * as PopoverPrimitive from '@radix-ui/react-popover';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Popover = PopoverPrimitive.Root;\n\nconst PopoverTrigger = PopoverPrimitive.Trigger;\n\nconst PopoverContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, align = 'center', sideOffset = 4, ...props }, ref) => (\n \n \n \n));\nPopoverContent.displayName = PopoverPrimitive.Content.displayName;\n\nexport { Popover, PopoverTrigger, PopoverContent };\n","import React from 'react';\nimport * as DialogPrimitive from '@radix-ui/react-dialog';\nimport { X } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Dialog = DialogPrimitive.Root;\n\nconst DialogTrigger = DialogPrimitive.Trigger;\n\nconst DialogPortal = DialogPrimitive.Portal;\n\nconst DialogClose = DialogPrimitive.Close;\n\nconst DialogOverlay = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nDialogOverlay.displayName = DialogPrimitive.Overlay.displayName;\n\nconst DialogContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, ...props }, ref) => (\n \n \n \n {children}\n \n \n Close\n \n \n \n));\nDialogContent.displayName = DialogPrimitive.Content.displayName;\n\nfunction DialogHeader({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nDialogHeader.displayName = 'DialogHeader';\n\nfunction DialogFooter({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nDialogFooter.displayName = 'DialogFooter';\n\nconst DialogTitle = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nDialogTitle.displayName = DialogPrimitive.Title.displayName;\n\nconst DialogDescription = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nDialogDescription.displayName = DialogPrimitive.Description.displayName;\n\nexport {\n Dialog,\n DialogPortal,\n DialogOverlay,\n DialogClose,\n DialogTrigger,\n DialogContent,\n DialogHeader,\n DialogFooter,\n DialogTitle,\n DialogDescription,\n};\n","import React from 'react';\nimport { type DialogProps } from '@radix-ui/react-dialog';\nimport { Command as CommandPrimitive } from 'cmdk';\nimport { Search } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Dialog, DialogContent } from '@/components/shadcn-ui/dialog';\n\nconst Command = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nCommand.displayName = CommandPrimitive.displayName;\n\ninterface CommandDialogProps extends DialogProps {}\n\nfunction CommandDialog({ children, ...props }: CommandDialogProps) {\n return (\n \n \n \n {children}\n \n \n \n );\n}\n\nconst CommandInput = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n
    \n \n \n
    \n));\n\nCommandInput.displayName = CommandPrimitive.Input.displayName;\n\nconst CommandList = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\n\nCommandList.displayName = CommandPrimitive.List.displayName;\n\nconst CommandEmpty = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>((props, ref) => (\n \n));\n\nCommandEmpty.displayName = CommandPrimitive.Empty.displayName;\n\nconst CommandGroup = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\n\nCommandGroup.displayName = CommandPrimitive.Group.displayName;\n\nconst CommandSeparator = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nCommandSeparator.displayName = CommandPrimitive.Separator.displayName;\n\nconst CommandItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\n\nCommandItem.displayName = CommandPrimitive.Item.displayName;\n\nfunction CommandShortcut({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nCommandShortcut.displayName = 'CommandShortcut';\n\nexport {\n Command,\n CommandDialog,\n CommandInput,\n CommandList,\n CommandEmpty,\n CommandGroup,\n CommandItem,\n CommandShortcut,\n CommandSeparator,\n};\n","import { useState } from 'react';\nimport { Check, ChevronsUpDown } from 'lucide-react';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport { Popover, PopoverContent, PopoverTrigger } from '@/components/shadcn-ui/popover';\nimport {\n Command,\n CommandEmpty,\n CommandInput,\n CommandItem,\n CommandList,\n} from '@/components/shadcn-ui/command';\nimport { PopoverProps } from '@radix-ui/react-popover';\n\nexport type ComboBoxLabelOption = { label: string };\nexport type ComboBoxOption = string | number | ComboBoxLabelOption;\n\nexport type ComboBoxProps = {\n /** Optional unique identifier */\n id?: string;\n /** Text label title for combobox */\n /** List of available options for the dropdown menu */\n options?: readonly T[];\n /** Additional css classes to help with unique styling of the combo box button */\n buttonClassName?: string;\n /** Additional css classes to help with unique styling of the combo box popover */\n popoverContentClassName?: string;\n /**\n * The selected value that the combo box currently holds. Must be shallow equal to one of the\n * options entries.\n */\n value?: T;\n /** Triggers when content of textfield is changed */\n onChange?: (newValue: T) => void;\n /** Used to determine the string value for a given option. */\n getOptionLabel?: (option: ComboBoxOption) => string;\n /** Text displayed on button if `value` is undefined */\n buttonPlaceholder?: string;\n /** Placeholder text for text field */\n textPlaceholder?: string;\n /** Text to display when no options match input */\n commandEmptyMessage?: string;\n /** Variant of button */\n buttonVariant?: ButtonProps['variant'];\n /** Text direction ltr or rtl */\n dir?: Direction;\n /** Optional boolean to set if trigger should be disabled */\n isDisabled?: boolean;\n} & PopoverProps;\n\ntype Direction = 'ltr' | 'rtl';\n\nfunction getOptionLabelDefault(option: ComboBoxOption): string {\n if (typeof option === 'string') {\n return option;\n }\n if (typeof option === 'number') {\n return option.toString();\n }\n return option.label;\n}\n\n/**\n * Autocomplete input and command palette with a list of suggestions.\n *\n * Thanks to Shadcn for heavy inspiration and documentation\n * https://ui.shadcn.com/docs/components/combobox\n */\nfunction ComboBox({\n id,\n options = [],\n buttonClassName,\n popoverContentClassName,\n value,\n onChange = () => {},\n getOptionLabel = getOptionLabelDefault,\n buttonPlaceholder = '',\n textPlaceholder = '',\n commandEmptyMessage = 'No option found',\n buttonVariant = 'outline',\n dir = 'ltr',\n isDisabled = false,\n ...props\n}: ComboBoxProps) {\n const [open, setOpen] = useState(false);\n\n return (\n \n \n \n \n {value ? getOptionLabel(value) : buttonPlaceholder}\n \n \n \n \n \n \n \n {commandEmptyMessage}\n \n {options.map((option) => (\n {\n onChange(option);\n setOpen(false);\n }}\n >\n \n {getOptionLabel(option)}\n \n ))}\n \n \n \n \n );\n}\n\nexport default ComboBox;\n","import { useMemo } from 'react';\nimport ComboBox from '@/components/basics/combo-box.component';\nimport { Label } from '@/components/shadcn-ui/label';\n\nexport type ChapterRangeSelectorProps = {\n startChapter: number;\n endChapter: number;\n handleSelectStartChapter: (chapter: number) => void;\n handleSelectEndChapter: (chapter: number) => void;\n isDisabled?: boolean;\n chapterCount: number;\n};\n\nexport default function ChapterRangeSelector({\n startChapter,\n endChapter,\n handleSelectStartChapter,\n handleSelectEndChapter,\n isDisabled = false,\n chapterCount,\n}: ChapterRangeSelectorProps) {\n const chapterOptions = useMemo(\n () => Array.from({ length: chapterCount }, (_, index) => index + 1),\n [chapterCount],\n );\n\n const onChangeStartChapter = (value: number) => {\n handleSelectStartChapter(value);\n if (value > endChapter) {\n handleSelectEndChapter(value);\n }\n };\n\n const onChangeEndChapter = (value: number) => {\n handleSelectEndChapter(value);\n if (value < startChapter) {\n handleSelectStartChapter(value);\n }\n };\n\n return (\n <>\n \n option.toString()}\n value={startChapter}\n />\n\n \n option.toString()}\n value={endChapter}\n />\n \n );\n}\n","import { Button } from '@/components/shadcn-ui/button';\nimport { Label } from '@/components/shadcn-ui/label';\nimport { RadioGroup, RadioGroupItem } from '@/components/shadcn-ui/radio-group';\nimport { Canon } from '@sillsdev/scripture';\nimport { LocalizedStringValue } from 'platform-bible-utils';\nimport { useState } from 'react';\nimport ChapterRangeSelector, {\n ChapterRangeSelectorProps,\n} from '../basics/chapter-range-selector.component';\n\nexport enum BookSelectionMode {\n CURRENT_BOOK = 'current book',\n CHOOSE_BOOKS = 'choose books',\n}\n\n/**\n * Object containing all keys used for localization in this component. If you're using this\n * component in an extension, you can pass it into the useLocalizedStrings hook to easily obtain the\n * localized strings and pass them into the localizedStrings prop of this component\n */\nexport const BOOK_SELECTOR_STRING_KEYS = Object.freeze([\n '%webView_bookSelector_currentBook%',\n '%webView_bookSelector_choose%',\n '%webView_bookSelector_chooseBooks%',\n] as const);\n\nexport type BookSelectorLocalizedStrings = {\n [localizedInventoryKey in (typeof BOOK_SELECTOR_STRING_KEYS)[number]]?: LocalizedStringValue;\n};\n\n/**\n * Gets the localized value for the provided key\n *\n * @param strings Object containing localized string\n * @param key Key for a localized string\n * @returns The localized value for the provided key, if available. Returns the key if no localized\n * value is available\n */\nconst localizeString = (\n strings: BookSelectorLocalizedStrings,\n key: keyof BookSelectorLocalizedStrings,\n) => {\n return strings[key] ?? key;\n};\n\ntype BookSelectorProps = ChapterRangeSelectorProps & {\n handleBookSelectionModeChange: (newMode: BookSelectionMode) => void;\n currentBookName: string;\n onSelectBooks: () => void;\n selectedBookIds: string[];\n localizedStrings: BookSelectorLocalizedStrings;\n};\n\nexport default function BookSelector({\n handleBookSelectionModeChange,\n currentBookName,\n onSelectBooks,\n selectedBookIds,\n chapterCount,\n endChapter,\n handleSelectEndChapter,\n startChapter,\n handleSelectStartChapter,\n localizedStrings,\n}: BookSelectorProps) {\n const currentBookText = localizeString(localizedStrings, '%webView_bookSelector_currentBook%');\n const chooseText = localizeString(localizedStrings, '%webView_bookSelector_choose%');\n const chooseBooksText = localizeString(localizedStrings, '%webView_bookSelector_chooseBooks%');\n\n const [bookSelectionMode, setBookSelectionMode] = useState(\n BookSelectionMode.CURRENT_BOOK,\n );\n\n const onSelectionModeChange = (newMode: BookSelectionMode) => {\n setBookSelectionMode(newMode);\n handleBookSelectionModeChange(newMode);\n };\n\n return (\n onSelectionModeChange(value as BookSelectionMode)}\n >\n
    \n
    \n
    \n \n \n
    \n \n
    \n \n
    \n
    \n
    \n
    \n \n \n
    \n \n onSelectBooks()}\n >\n {chooseText}\n \n
    \n
    \n \n );\n}\n","import { DropdownMenuTrigger } from '@radix-ui/react-dropdown-menu';\nimport { FilterIcon } from 'lucide-react';\nimport { Table } from '@tanstack/react-table';\n\nimport { Button } from '@/components/shadcn-ui/button';\nimport {\n DropdownMenu,\n DropdownMenuCheckboxItem,\n DropdownMenuContent,\n DropdownMenuLabel,\n DropdownMenuSeparator,\n} from '@/components/shadcn-ui/dropdown-menu';\n\ninterface DataTableViewOptionsProps {\n table: Table;\n}\n\nfunction DataTableViewOptions({ table }: DataTableViewOptionsProps) {\n return (\n \n \n \n \n \n Toggle columns\n \n {table\n .getAllColumns()\n .filter((column) => column.getCanHide())\n .map((column) => {\n return (\n column.toggleVisibility(!!value)}\n >\n {column.id}\n \n );\n })}\n \n \n );\n}\n\nexport default DataTableViewOptions;\n","import React from 'react';\nimport * as SelectPrimitive from '@radix-ui/react-select';\nimport { Check, ChevronDown, ChevronUp } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Select = SelectPrimitive.Root;\n\nconst SelectGroup = SelectPrimitive.Group;\n\nconst SelectValue = SelectPrimitive.Value;\n\nconst SelectTrigger = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, ...props }, ref) => (\n span]:tw-line-clamp-1',\n className,\n )}\n {...props}\n >\n {children}\n \n \n \n \n));\nSelectTrigger.displayName = SelectPrimitive.Trigger.displayName;\n\nconst SelectScrollUpButton = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n));\nSelectScrollUpButton.displayName = SelectPrimitive.ScrollUpButton.displayName;\n\nconst SelectScrollDownButton = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n));\nSelectScrollDownButton.displayName = SelectPrimitive.ScrollDownButton.displayName;\n\nconst SelectContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, position = 'popper', ...props }, ref) => (\n \n \n \n \n {children}\n \n \n \n \n));\nSelectContent.displayName = SelectPrimitive.Content.displayName;\n\nconst SelectLabel = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSelectLabel.displayName = SelectPrimitive.Label.displayName;\n\nconst SelectItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, ...props }, ref) => (\n \n \n \n \n \n \n\n {children}\n \n));\nSelectItem.displayName = SelectPrimitive.Item.displayName;\n\nconst SelectSeparator = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSelectSeparator.displayName = SelectPrimitive.Separator.displayName;\n\nexport {\n Select,\n SelectGroup,\n SelectValue,\n SelectTrigger,\n SelectContent,\n SelectLabel,\n SelectItem,\n SelectSeparator,\n SelectScrollUpButton,\n SelectScrollDownButton,\n};\n","import { ChevronLeftIcon, ChevronRightIcon, ArrowLeftIcon, ArrowRightIcon } from 'lucide-react';\nimport { Table } from '@tanstack/react-table';\n\nimport { Button } from '@/components/shadcn-ui/button';\nimport {\n Select,\n SelectContent,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\n\ninterface DataTablePaginationProps {\n table: Table;\n}\n\nfunction DataTablePagination({ table }: DataTablePaginationProps) {\n return (\n
    \n
    \n
    \n {table.getFilteredSelectedRowModel().rows.length} of{' '}\n {table.getFilteredRowModel().rows.length} row(s) selected\n
    \n
    \n

    Rows per page

    \n {\n table.setPageSize(Number(value));\n }}\n >\n \n \n \n \n {[10, 20, 30, 40, 50].map((pageSize) => (\n \n {pageSize}\n \n ))}\n \n \n
    \n
    \n Page {table.getState().pagination.pageIndex + 1} of {table.getPageCount()}\n
    \n
    \n table.setPageIndex(0)}\n disabled={!table.getCanPreviousPage()}\n >\n Go to first page\n \n \n table.previousPage()}\n disabled={!table.getCanPreviousPage()}\n >\n Go to previous page\n \n \n table.nextPage()}\n disabled={!table.getCanNextPage()}\n >\n Go to next page\n \n \n table.setPageIndex(table.getPageCount() - 1)}\n disabled={!table.getCanNextPage()}\n >\n Go to last page\n \n \n
    \n
    \n
    \n );\n}\n\nexport default DataTablePagination;\n","import React from 'react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Table = React.forwardRef<\n HTMLTableElement,\n React.HTMLAttributes & { stickyHeader?: boolean }\n>(({ className, stickyHeader, ...props }, ref) => (\n
    \n \n
    \n));\nTable.displayName = 'Table';\n\nconst TableHeader = React.forwardRef<\n HTMLTableSectionElement,\n React.HTMLAttributes & { stickyHeader?: boolean }\n>(({ className, stickyHeader, ...props }, ref) => (\n \n));\nTableHeader.displayName = 'TableHeader';\n\nconst TableBody = React.forwardRef<\n HTMLTableSectionElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableBody.displayName = 'TableBody';\n\nconst TableFooter = React.forwardRef<\n HTMLTableSectionElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n tr]:last:tw-border-b-0', className)}\n {...props}\n />\n));\nTableFooter.displayName = 'TableFooter';\n\nconst TableRow = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nTableRow.displayName = 'TableRow';\n\nconst TableHead = React.forwardRef<\n HTMLTableCellElement,\n React.ThHTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableHead.displayName = 'TableHead';\n\nconst TableCell = React.forwardRef<\n HTMLTableCellElement,\n React.TdHTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableCell.displayName = 'TableCell';\n\nconst TableCaption = React.forwardRef<\n HTMLTableCaptionElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableCaption.displayName = 'TableCaption';\n\nexport { Table, TableHeader, TableBody, TableFooter, TableHead, TableRow, TableCell, TableCaption };\n","import { useState } from 'react';\n\nimport {\n ColumnFiltersState,\n flexRender,\n getCoreRowModel,\n getFilteredRowModel,\n getPaginationRowModel,\n getSortedRowModel,\n SortingState,\n ColumnDef as TSColumnDef,\n Row as TSRow,\n RowSelectionState as TSRowSelectionState,\n SortDirection as TSSortDirection,\n Table as TSTable,\n useReactTable,\n VisibilityState,\n} from '@tanstack/react-table';\n\nimport DataTableViewOptions from '@/components/advanced/data-table/data-table-column-toggle.component';\nimport DataTablePagination from '@/components/advanced/data-table/data-table-pagination.component';\nimport { Button } from '@/components/shadcn-ui/button';\nimport {\n Table,\n TableBody,\n TableCell,\n TableHead,\n TableHeader,\n TableRow,\n} from '@/components/shadcn-ui/table';\n\nexport type ColumnDef = TSColumnDef;\nexport type RowContents = TSRow;\nexport type TableContents = TSTable;\nexport type SortDirection = TSSortDirection;\nexport type RowSelectionState = TSRowSelectionState;\n\ninterface DataTableProps {\n columns: ColumnDef[];\n data: TData[];\n enablePagination?: boolean;\n showPaginationControls?: boolean;\n showColumnVisibilityControls?: boolean;\n stickyHeader?: boolean;\n onRowClickHandler?: (row: RowContents, table: TableContents) => void;\n}\n\n/**\n * Feature-rich table component that infuses our basic shadcn-based Table component with features\n * from TanStack's React Table library\n */\nfunction DataTable({\n columns,\n data,\n enablePagination = false,\n showPaginationControls = false,\n showColumnVisibilityControls = false,\n stickyHeader = false,\n onRowClickHandler = () => {},\n}: DataTableProps) {\n const [sorting, setSorting] = useState([]);\n const [columnFilters, setColumnFilters] = useState([]);\n const [columnVisibility, setColumnVisibility] = useState({});\n const [rowSelection, setRowSelection] = useState({});\n\n const table = useReactTable({\n data,\n columns,\n getCoreRowModel: getCoreRowModel(),\n ...(enablePagination && { getPaginationRowModel: getPaginationRowModel() }),\n onSortingChange: setSorting,\n getSortedRowModel: getSortedRowModel(),\n onColumnFiltersChange: setColumnFilters,\n getFilteredRowModel: getFilteredRowModel(),\n onColumnVisibilityChange: setColumnVisibility,\n onRowSelectionChange: setRowSelection,\n state: {\n sorting,\n columnFilters,\n columnVisibility,\n rowSelection,\n },\n });\n\n return (\n
    \n {showColumnVisibilityControls && }\n \n \n {table.getHeaderGroups().map((headerGroup) => (\n \n {headerGroup.headers.map((header) => {\n return (\n \n {header.isPlaceholder\n ? undefined\n : flexRender(header.column.columnDef.header, header.getContext())}\n \n );\n })}\n \n ))}\n \n \n {table.getRowModel().rows?.length ? (\n table.getRowModel().rows.map((row) => (\n onRowClickHandler(row, table)}\n key={row.id}\n data-state={row.getIsSelected() && 'selected'}\n >\n {row.getVisibleCells().map((cell) => (\n \n {flexRender(cell.column.columnDef.cell, cell.getContext())}\n \n ))}\n \n ))\n ) : (\n \n \n No results.\n \n \n )}\n \n
    \n {enablePagination && (\n
    \n table.previousPage()}\n disabled={!table.getCanPreviousPage()}\n >\n Previous\n \n table.nextPage()}\n disabled={!table.getCanNextPage()}\n >\n Next\n \n
    \n )}\n {enablePagination && showPaginationControls && }\n
    \n );\n}\n\nexport default DataTable;\n","import {\n Table,\n TableBody,\n TableCell,\n TableHead,\n TableHeader,\n TableRow,\n} from '@/components/shadcn-ui/table';\nimport { Canon } from '@sillsdev/scripture';\nimport { deepEqual, LanguageStrings, ScriptureReference } from 'platform-bible-utils';\nimport { useMemo } from 'react';\nimport { InventoryItemOccurrence } from './inventory-utils';\n\n/** Props for the OccurrencesTable component */\ntype OccurrencesTableProps = {\n /** Data that contains scriptures references and snippets of scripture */\n occurrenceData: InventoryItemOccurrence[];\n /** Callback function that is executed when the scripture reference is changed */\n setScriptureReference: (scriptureReference: ScriptureReference) => void;\n /**\n * Object with all localized strings that the OccurrencesTable needs to work well across multiple\n * languages\n */\n localizedStrings: LanguageStrings;\n};\n\n/**\n * Table that shows occurrences of specified inventory item(s). The first column shows the related\n * scripture reference. The second column shows the snippet of scripture that contains the specified\n * inventory item\n */\nfunction OccurrencesTable({\n occurrenceData,\n setScriptureReference,\n localizedStrings,\n}: OccurrencesTableProps) {\n const referenceHeaderText =\n localizedStrings['%webView_inventory_occurrences_table_header_reference%'];\n const occurrenceHeaderText =\n localizedStrings['%webView_inventory_occurrences_table_header_occurrence%'];\n\n const occurrences: InventoryItemOccurrence[] = useMemo(() => {\n const uniqueOccurrences: InventoryItemOccurrence[] = [];\n\n occurrenceData.forEach((occurrence) => {\n if (!uniqueOccurrences.some((uniqueOccurrence) => deepEqual(uniqueOccurrence, occurrence))) {\n uniqueOccurrences.push(occurrence);\n }\n });\n\n return uniqueOccurrences;\n }, [occurrenceData]);\n\n return (\n \n \n \n {referenceHeaderText}\n {occurrenceHeaderText}\n \n \n \n {occurrences.length > 0 &&\n occurrences.map((occurrence) => (\n {\n setScriptureReference(occurrence.reference);\n }}\n >\n {`${Canon.bookNumberToEnglishName(occurrence.reference.bookNum)} ${occurrence.reference.chapterNum}:${occurrence.reference.verseNum}`}\n {occurrence.text}\n \n ))}\n \n
    \n );\n}\n\nexport default OccurrencesTable;\n","import React from 'react';\nimport * as CheckboxPrimitive from '@radix-ui/react-checkbox';\nimport { Check } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Checkbox = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n \n \n));\nCheckbox.displayName = CheckboxPrimitive.Root.displayName;\n\nexport default Checkbox;\n","import { Canon } from '@sillsdev/scripture';\nimport { ScriptureReference } from 'platform-bible-utils';\n\n/* #region Types */\n\n/**\n * Status of items that appear in inventories. 'approved' and 'unapproved' items are defined in the\n * project's `Settings.xml`. All other items are defined as 'unknown'\n */\nexport type Status = 'approved' | 'unapproved' | 'unknown';\n\n/** Occurrence of item in inventory. Primarily used by table that shows occurrences */\nexport type InventoryItemOccurrence = {\n /** Reference to scripture where the item appears */\n reference: ScriptureReference;\n /** Snippet of scripture that contains the occurrence */\n text: string;\n};\n\n/** Data structure that contains all information on an item that is shown in an inventory */\nexport type InventoryTableData = {\n /**\n * The item (e.g. a character in the characters inventory, a marker in the marker inventory) In\n * most cases the array will only have one element. In case of additional items (e.g. the\n * preceding marker in the markers check), the primary item should be stored in the first index.\n * To show additional items in the inventory, make sure to configure the `additionalItemsLabels`\n * prop for the Inventory component\n */\n items: string[];\n /** The number of times this item occurs in the selected scope */\n count: number;\n /** The status of this item (see documentation for `Status` type for more information) */\n status: Status;\n /** Occurrences of this item in the scripture text for the selected scope */\n occurrences: InventoryItemOccurrence[];\n};\n\n/* #endregion */\n\n/* #region Functions */\n\n/**\n * Splits USFM string into shorter line-like segments\n *\n * @param text A single (likely very large) USFM string\n * @returns An array containing the input text, split into shorter segments\n */\nexport const getLinesFromUSFM = (text: string) => {\n // Splits on (CR)LF, CR, \\v, \\c and \\id\n return text.split(/(?:\\r?\\n|\\r)|(?=(?:\\\\(?:v|c|id)))/g);\n};\n\n/**\n * Extracts chapter or verse number from USFM strings that start with a \\c or \\v marker\n *\n * @param text USFM string that is expected to start with \\c or \\v marker\n * @returns Chapter or verse number if one is found. Else returns 0.\n */\nexport const getNumberFromUSFM = (text: string): number | undefined => {\n // Captures all digits that follow \\v or \\c markers followed by whitespace located at the start of a string\n const regex = /^\\\\[vc]\\s+(\\d+)/;\n const match = text.match(regex);\n\n if (match) {\n return +match[1];\n }\n return undefined;\n};\n\n/**\n * Gets book ID from USFM string that starts with the \\id marker, and returns book number for it\n *\n * @param text USFM string that is expected to start with \\id marker\n * @returns Book number corresponding to the \\id marker in the input text. Returns 0 if no marker is\n * found or the marker is not valid\n */\nexport const getBookNumFromId = (text: string): number => {\n // Captures all digits that follow an \\id marker followed by whitespace located at the start of a string\n const match = text.match(/^\\\\id\\s+([A-Za-z]+)/);\n if (match) {\n return Canon.bookIdToNumber(match[1]);\n }\n return 0;\n};\n\n/**\n * Gets the status for an item, typically used in the Inventory component\n *\n * @param item The item for which the status is being requested\n * @param approvedItems Array of approved items, typically as defined in `Settings.xml`\n * @param unapprovedItems Array of unapproved items, typically as defined in `Settings.xml`\n * @returns The status for the specified item\n */\nexport const getStatusForItem = (\n item: string,\n approvedItems: string[],\n unapprovedItems: string[],\n): Status => {\n if (unapprovedItems.includes(item)) return 'unapproved';\n if (approvedItems.includes(item)) return 'approved';\n return 'unknown';\n};\n\n/* #endregion */\n","import React from 'react';\nimport * as TogglePrimitive from '@radix-ui/react-toggle';\nimport { cva, type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst toggleVariants = cva(\n 'pr-twp tw-inline-flex tw-items-center tw-justify-center tw-rounded-md tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-colors hover:tw-bg-muted hover:tw-text-muted-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50 data-[state=on]:tw-bg-accent data-[state=on]:tw-text-accent-foreground',\n {\n variants: {\n variant: {\n default: 'tw-bg-transparent',\n outline:\n 'tw-border tw-border-input tw-bg-transparent hover:tw-bg-accent hover:tw-text-accent-foreground',\n },\n size: {\n default: 'tw-h-10 tw-px-3',\n sm: 'tw-h-9 tw-px-2.5',\n lg: 'tw-h-11 tw-px-5',\n },\n },\n defaultVariants: {\n variant: 'default',\n size: 'default',\n },\n },\n);\n\nconst Toggle = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef & VariantProps\n>(({ className, variant, size, ...props }, ref) => (\n \n));\n\nToggle.displayName = TogglePrimitive.Root.displayName;\n\nexport { Toggle, toggleVariants };\n","import React from 'react';\nimport * as ToggleGroupPrimitive from '@radix-ui/react-toggle-group';\nimport { type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { toggleVariants } from '@/components/shadcn-ui/toggle';\n\nconst ToggleGroupContext = React.createContext>({\n size: 'default',\n variant: 'default',\n});\n\nconst ToggleGroup = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef &\n VariantProps\n>(({ className, variant, size, children, ...props }, ref) => (\n \n \n {children}\n \n \n));\n\nToggleGroup.displayName = ToggleGroupPrimitive.Root.displayName;\n\nconst ToggleGroupItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef &\n VariantProps\n>(({ className, children, variant, size, ...props }, ref) => {\n const context = React.useContext(ToggleGroupContext);\n\n return (\n \n {children}\n \n );\n});\n\nToggleGroupItem.displayName = ToggleGroupPrimitive.Item.displayName;\n\nexport { ToggleGroup, ToggleGroupItem };\n","import { ColumnDef, SortDirection } from '@/components/advanced/data-table/data-table.component';\nimport { Button } from '@/components/shadcn-ui/button';\nimport { ToggleGroup, ToggleGroupItem } from '@/components/shadcn-ui/toggle-group';\nimport {\n ArrowDownIcon,\n ArrowUpDownIcon,\n ArrowUpIcon,\n CircleCheckIcon,\n CircleHelpIcon,\n CircleXIcon,\n} from 'lucide-react';\nimport { ReactNode } from 'react';\nimport { InventoryTableData, Status } from './inventory-utils';\n\n/**\n * Gets an icon that indicates the current sorting direction based on the provided input\n *\n * @param sortDirection Sorting direction. Can be ascending ('asc'), descending ('desc') or false (\n * i.e. not sorted)\n * @returns The appropriate sorting icon for the provided sorting direction\n */\nconst getSortingIcon = (sortDirection: false | SortDirection): ReactNode => {\n if (sortDirection === 'asc') {\n return ;\n }\n if (sortDirection === 'desc') {\n return ;\n }\n return ;\n};\n\n/**\n * Function that creates the item column for inventories\n *\n * @param itemLabel Localized label for the item column (e.g. 'Character', 'Repeated Word', etc.)\n * @returns Column that shows the inventory items. Should be used with the DataTable component\n */\nexport const inventoryItemColumn = (itemLabel: string): ColumnDef => {\n return {\n accessorKey: 'item',\n accessorFn: (row: InventoryTableData) => row.items[0],\n header: ({ column }) => (\n \n ),\n };\n};\n\n/**\n * Function that creates the additional item columns for inventories\n *\n * @param additionalItemLabel Localized label for the additional item column (e.g. 'Preceding\n * Marker')\n * @param additionalItemIndex Index that locates the desired item in the items array of the\n * inventory\n * @returns Column that shows additional inventory items. Should be used with the DataTable\n * component\n */\nexport const inventoryAdditionalItemColumn = (\n additionalItemLabel: string,\n additionalItemIndex: number,\n): ColumnDef => {\n return {\n accessorKey: `item${additionalItemIndex}`,\n accessorFn: (row: InventoryTableData) => row.items[additionalItemIndex],\n header: ({ column }) => (\n \n ),\n };\n};\n\n/**\n * Function that creates the count column for inventories. Should be used with the DataTable\n * component.\n *\n * @param itemLabel Localized label for the count column\n * @returns Column that shows the number of occurrences of the related inventory items\n */\nexport const inventoryCountColumn = (countLabel: string): ColumnDef => {\n return {\n accessorKey: 'count',\n header: ({ column }) => (\n
    \n \n
    \n ),\n cell: ({ row }) =>
    {row.getValue('count')}
    ,\n };\n};\n\n/**\n * Function that updates project settings when status for item(s) changes\n *\n * @param changedItems Array of items for which the status is being updated\n * @param newStatus The status that the items are being given\n * @param approvedItems Array of currently approved items\n * @param onApprovedItemsChange Callback function that stores the updated list of approved items\n * @param unapprovedItems Array of currently unapproved items\n * @param onUnapprovedItemsChange Callback function that stores the updated list of unapproved items\n */\nconst statusChangeHandler = (\n changedItems: string[],\n newStatus: Status,\n approvedItems: string[],\n onApprovedItemsChange: (items: string[]) => void,\n unapprovedItems: string[],\n onUnapprovedItemsChange: (items: string[]) => void,\n) => {\n let newApprovedItems: string[] = [...approvedItems];\n changedItems.forEach((item) => {\n if (newStatus === 'approved') {\n if (!newApprovedItems.includes(item)) {\n newApprovedItems.push(item);\n }\n } else {\n newApprovedItems = newApprovedItems.filter((validItem) => validItem !== item);\n }\n });\n onApprovedItemsChange(newApprovedItems);\n\n let newUnapprovedItems: string[] = [...unapprovedItems];\n changedItems.forEach((item) => {\n if (newStatus === 'unapproved') {\n if (!newUnapprovedItems.includes(item)) {\n newUnapprovedItems.push(item);\n }\n } else {\n newUnapprovedItems = newUnapprovedItems.filter((unapprovedItem) => unapprovedItem !== item);\n }\n });\n onUnapprovedItemsChange(newUnapprovedItems);\n};\n\n/**\n * Function that creates the status column for inventories. Should be used with the DataTable\n * component.\n *\n * @param statusLabel Localized label for the status column\n * @param approvedItems Array of approved items, typically as defined in `Settings.xml`\n * @param onApprovedItemsChange Callback function that stores the updated list of approved items\n * @param unapprovedItems Array of unapproved items, typically as defined in `Settings.xml`\n * @param onUnapprovedItemsChange Callback function that stores the updated list of unapproved items\n * @returns Column that shows the status buttons for the related inventory item. The button for the\n * current status of the item is selected\n */\nexport const inventoryStatusColumn = (\n statusLabel: string,\n approvedItems: string[],\n onApprovedItemsChange: (items: string[]) => void,\n unapprovedItems: string[],\n onUnapprovedItemsChange: (items: string[]) => void,\n): ColumnDef => {\n return {\n accessorKey: 'status',\n header: ({ column }) => {\n return (\n
    \n \n
    \n );\n },\n cell: ({ row }) => {\n const status: Status = row.getValue('status');\n const item: string = row.getValue('item');\n return (\n \n \n statusChangeHandler(\n [item],\n 'approved',\n approvedItems,\n onApprovedItemsChange,\n unapprovedItems,\n onUnapprovedItemsChange,\n )\n }\n value=\"approved\"\n >\n \n \n \n statusChangeHandler(\n [item],\n 'unapproved',\n approvedItems,\n onApprovedItemsChange,\n unapprovedItems,\n onUnapprovedItemsChange,\n )\n }\n value=\"unapproved\"\n >\n \n \n \n statusChangeHandler(\n [item],\n 'unknown',\n approvedItems,\n onApprovedItemsChange,\n unapprovedItems,\n onUnapprovedItemsChange,\n )\n }\n value=\"unknown\"\n >\n \n \n \n );\n },\n };\n};\n","import DataTable, {\n ColumnDef,\n RowContents,\n RowSelectionState,\n TableContents,\n} from '@/components/advanced/data-table/data-table.component';\nimport OccurrencesTable from '@/components/advanced/inventory/occurrences-table.component';\nimport Checkbox from '@/components/shadcn-ui/checkbox';\nimport { Input } from '@/components/shadcn-ui/input';\nimport { Label } from '@/components/shadcn-ui/label';\nimport {\n Select,\n SelectContent,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\nimport {\n deepEqual,\n LocalizedStringValue,\n ScriptureReference,\n substring,\n} from 'platform-bible-utils';\nimport { useEffect, useMemo, useState } from 'react';\nimport {\n getBookNumFromId,\n getLinesFromUSFM,\n getNumberFromUSFM,\n getStatusForItem,\n InventoryItemOccurrence,\n InventoryTableData,\n Status,\n} from './inventory-utils';\nimport { inventoryAdditionalItemColumn } from './inventory-columns';\n\n/**\n * Object containing all keys used for localization in this component. If you're using this\n * component in an extension, you can pass it into the useLocalizedStrings hook to easily obtain the\n * localized strings and pass them into the localizedStrings prop of this component\n */\nexport const INVENTORY_STRING_KEYS = Object.freeze([\n '%webView_inventory_all%',\n '%webView_inventory_approved%',\n '%webView_inventory_unapproved%',\n '%webView_inventory_unknown%',\n '%webView_inventory_scope_currentBook%',\n '%webView_inventory_scope_chapter%',\n '%webView_inventory_scope_verse%',\n '%webView_inventory_filter_text%',\n '%webView_inventory_show_additional_items%',\n '%webView_inventory_occurrences_table_header_reference%',\n '%webView_inventory_occurrences_table_header_occurrence%',\n] as const);\n\nexport type InventoryLocalizedStrings = {\n [localizedInventoryKey in (typeof INVENTORY_STRING_KEYS)[number]]?: LocalizedStringValue;\n};\n\n/** Scope of scripture that the inventory can operate on */\nexport type Scope = 'book' | 'chapter' | 'verse';\n\n/** Status values that the status filter can select from */\ntype StatusFilter = Status | 'all';\n\n/** Text labels for the inventory columns and the control components of additional inventory items */\ntype AdditionalItemsLabels = {\n checkboxText?: string;\n tableHeaders?: string[];\n};\n\n/**\n * Filters data that is shown in the DataTable section of the Inventory\n *\n * @param itemData All inventory items and their related information\n * @param statusFilter Allows filtering by status (i.e. show all items, or only items that are\n * 'approved', 'unapproved' or 'unknown')\n * @param textFilter Allows filtering by text. All items that include the filter text will be\n * selected.\n * @returns Array of items and their related information that are matched by the specified filters\n */\nconst filterItemData = (\n itemData: InventoryTableData[],\n statusFilter: StatusFilter,\n textFilter: string,\n): InventoryTableData[] => {\n let filteredItemData: InventoryTableData[] = itemData;\n\n if (statusFilter !== 'all') {\n filteredItemData = filteredItemData.filter(\n (item) =>\n (statusFilter === 'approved' && item.status === 'approved') ||\n (statusFilter === 'unapproved' && item.status === 'unapproved') ||\n (statusFilter === 'unknown' && item.status === 'unknown'),\n );\n }\n\n if (textFilter !== '')\n filteredItemData = filteredItemData.filter((item) => item.items[0].includes(textFilter));\n\n return filteredItemData;\n};\n\n/**\n * Turns array of strings into array of inventory items, along with their count and status\n *\n * @param text The source scripture text that is searched for inventory items\n * @param scriptureRef The scripture reference that the application is currently set to\n * @param approvedItems Array of approved items, typically as defined in `Settings.xml`\n * @param unapprovedItems Array of unapproved items, typically as defined in `Settings.xml`\n * @param itemRegex Regular expression that describes what items this Inventory should extract from\n * the provided scripture text\n * @returns Array of inventory items, along with their count and status\n */\nconst createTableData = (\n text: string | undefined,\n scriptureRef: ScriptureReference,\n approvedItems: string[],\n unapprovedItems: string[],\n itemRegex: RegExp,\n): InventoryTableData[] => {\n if (!text) return [];\n\n const tableData: InventoryTableData[] = [];\n\n let currentBook: number | undefined = scriptureRef.bookNum;\n let currentChapter: number | undefined = scriptureRef.chapterNum;\n let currentVerse: number | undefined = scriptureRef.verseNum;\n\n const lines = getLinesFromUSFM(text);\n\n lines.forEach((line: string) => {\n if (line.startsWith('\\\\id')) {\n currentBook = getBookNumFromId(line);\n currentChapter = 0;\n currentVerse = 0;\n }\n if (line.startsWith('\\\\c')) {\n currentChapter = getNumberFromUSFM(line);\n currentVerse = 0;\n }\n if (line.startsWith('\\\\v')) {\n currentVerse = getNumberFromUSFM(line);\n if (currentChapter === 0) {\n currentChapter = scriptureRef.chapterNum;\n }\n }\n\n let match: RegExpExecArray | undefined = itemRegex.exec(line) ?? undefined;\n while (match) {\n const items: string[] = [];\n match.forEach((item) => items.push(item));\n const itemIndex = match.index;\n const existingItem = tableData.find((tableEntry) => deepEqual(tableEntry.items, items));\n const newReference: InventoryItemOccurrence = {\n reference: {\n bookNum: currentBook !== undefined ? currentBook : -1,\n chapterNum: currentChapter !== undefined ? currentChapter : -1,\n verseNum: currentVerse !== undefined ? currentVerse : -1,\n },\n text: substring(line, Math.max(0, itemIndex - 25), Math.min(itemIndex + 25, line.length)),\n };\n if (existingItem) {\n existingItem.count += 1;\n existingItem.occurrences.push(newReference);\n } else {\n const newItem: InventoryTableData = {\n items,\n count: 1,\n status: getStatusForItem(items[0], approvedItems, unapprovedItems),\n occurrences: [newReference],\n };\n tableData.push(newItem);\n }\n\n match = itemRegex.exec(line) ?? undefined;\n }\n });\n\n return tableData;\n};\n\n/**\n * Gets the localized value for the provided key\n *\n * @param strings Object containing localized string\n * @param key Key for a localized string\n * @returns The localized value for the provided key, if available. Returns the key if no localized\n * value is available\n */\nconst localizeString = (\n strings: InventoryLocalizedStrings,\n key: keyof InventoryLocalizedStrings,\n) => {\n return strings[key] ?? key;\n};\n\n/** Props for the Inventory component */\ntype InventoryProps = {\n /** The scripture reference that the application is currently set to */\n scriptureReference: ScriptureReference;\n /** Callback function that is executed when the scripture reference is changed */\n setScriptureReference: (scriptureReference: ScriptureReference) => void;\n /**\n * Object with all localized strings that the Inventory needs to work well across multiple\n * languages. When using this component with Platform.Bible, you can import\n * `INVENTORY_STRING_KEYS` from this library, pass it in to the Platform's localization hook, and\n * pass the localized keys that are returned by the hook into this prop.\n */\n localizedStrings: InventoryLocalizedStrings;\n /**\n * The logic that finds the desired items in the source text. This can either be a Regular\n * expression that captures one or multiple items (preferred), or a custom function that builds\n * and return an InventoryDataTable[] manually. Note: In case the logic captures more than one\n * item (i.e. InventoryTableData.items has a length greater than 1), you must provide text labels\n * for the related columns and control elements to show by setting the `additionalItemsLabels`\n * prop\n */\n extractItems:\n | RegExp\n | ((\n text: string | undefined,\n scriptureRef: ScriptureReference,\n approvedItems: string[],\n unapprovedItems: string[],\n ) => InventoryTableData[]);\n /**\n * Text labels for control elements and additional column headers in case your Inventory has more\n * than one item to show (e.g. The 'Preceding Marker' in the Markers Inventory)\n */\n additionalItemsLabels?: AdditionalItemsLabels;\n /** Array of approved items, typically as defined in `Settings.xml` */\n approvedItems: string[];\n /** Array of unapproved items, typically as defined in `Settings.xml` */\n unapprovedItems: string[];\n /** The source scripture text that is searched for in inventory items */\n text: string | undefined;\n /** Scope of scripture that the inventory will operate on */\n scope: Scope;\n /** Callback function that is executed when the scope is changed from the Inventory */\n onScopeChange: (scope: Scope) => void;\n /**\n * Column definitions for the Inventory data table. The most commonly used column definitions are\n * pre-configured for your convenience and can be imported (e.g. inventoryItemColumn,\n * inventoryAdditionalItemColumn inventoryCountColumn, and inventoryStatusColumn). If you need any\n * other columns you can add these yourself\n */\n columns: ColumnDef[];\n};\n\n/** Inventory component that is used to view and control the status of provided project settings */\nexport default function Inventory({\n scriptureReference,\n setScriptureReference,\n localizedStrings,\n extractItems,\n additionalItemsLabels,\n approvedItems,\n unapprovedItems,\n text,\n scope,\n onScopeChange,\n columns,\n}: InventoryProps) {\n const allItemsText = localizeString(localizedStrings, '%webView_inventory_all%');\n const approvedItemsText = localizeString(localizedStrings, '%webView_inventory_approved%');\n const unapprovedItemsText = localizeString(localizedStrings, '%webView_inventory_unapproved%');\n const unknownItemsText = localizeString(localizedStrings, '%webView_inventory_unknown%');\n const scopeBookText = localizeString(localizedStrings, '%webView_inventory_scope_currentBook%');\n const scopeChapterText = localizeString(localizedStrings, '%webView_inventory_scope_chapter%');\n const scopeVerseText = localizeString(localizedStrings, '%webView_inventory_scope_verse%');\n const filterText = localizeString(localizedStrings, '%webView_inventory_filter_text%');\n const showAdditionalItemsText = localizeString(\n localizedStrings,\n '%webView_inventory_show_additional_items%',\n );\n\n const [showAdditionalItems, setShowAdditionalItems] = useState(false);\n const [statusFilter, setStatusFilter] = useState('all');\n const [textFilter, setTextFilter] = useState('');\n const [selectedItem, setSelectedItem] = useState([]);\n\n const tableData: InventoryTableData[] = useMemo(() => {\n if (!text) return [];\n if (extractItems instanceof RegExp)\n return createTableData(\n text,\n scriptureReference,\n approvedItems,\n unapprovedItems,\n extractItems,\n );\n return extractItems(text, scriptureReference, approvedItems, unapprovedItems);\n }, [text, extractItems, scriptureReference, approvedItems, unapprovedItems]);\n\n const reducedTableData: InventoryTableData[] = useMemo(() => {\n if (showAdditionalItems) return tableData;\n\n const newTableData: InventoryTableData[] = [];\n\n tableData.forEach((tableEntry) => {\n const firstItem = tableEntry.items[0];\n\n const existingEntry = newTableData.find(\n (newTableEntry) => newTableEntry.items[0] === firstItem,\n );\n\n if (existingEntry) {\n existingEntry.count += tableEntry.count;\n existingEntry.occurrences = existingEntry.occurrences.concat(tableEntry.occurrences);\n } else {\n newTableData.push({\n items: [firstItem],\n count: tableEntry.count,\n occurrences: tableEntry.occurrences,\n status: tableEntry.status,\n });\n }\n });\n\n return newTableData;\n }, [showAdditionalItems, tableData]);\n\n const filteredTableData: InventoryTableData[] = useMemo(() => {\n return filterItemData(reducedTableData, statusFilter, textFilter);\n }, [reducedTableData, statusFilter, textFilter]);\n\n const allColumns: ColumnDef[] = useMemo(() => {\n if (!showAdditionalItems) return columns;\n\n const numberOfAdditionalItems = additionalItemsLabels?.tableHeaders?.length;\n if (!numberOfAdditionalItems) return columns;\n\n const additionalColumns: ColumnDef[] = [];\n\n for (let index = 0; index < numberOfAdditionalItems; index++) {\n additionalColumns.push(\n inventoryAdditionalItemColumn(\n additionalItemsLabels?.tableHeaders?.[index] || 'Additional Item',\n index + 1,\n ),\n );\n }\n\n return [...additionalColumns, ...columns];\n }, [additionalItemsLabels?.tableHeaders, columns, showAdditionalItems]);\n\n useEffect(() => {\n setSelectedItem([]);\n }, [filteredTableData]);\n\n const rowClickHandler = (\n row: RowContents,\n table: TableContents,\n ) => {\n table.setRowSelection(() => {\n const newSelection: RowSelectionState = {};\n newSelection[row.index] = true;\n return newSelection;\n });\n\n setSelectedItem(row.original.items);\n };\n\n const handleScopeChange = (value: string) => {\n if (value === 'book' || value === 'chapter' || value === 'verse') {\n onScopeChange(value);\n } else {\n throw new Error(`Invalid scope value: ${value}`);\n }\n };\n\n const handleStatusFilterChange = (value: string) => {\n if (value === 'all' || value === 'approved' || value === 'unapproved' || value === 'unknown') {\n setStatusFilter(value);\n } else {\n throw new Error(`Invalid status filter value: ${value}`);\n }\n };\n\n const occurrenceData: InventoryItemOccurrence[] = useMemo(() => {\n if (reducedTableData.length === 0 || selectedItem.length === 0) return [];\n const occurrence = reducedTableData.filter((tableEntry: InventoryTableData) => {\n return deepEqual(\n showAdditionalItems ? tableEntry.items : [tableEntry.items[0]],\n selectedItem,\n );\n });\n if (occurrence.length > 1) throw new Error('Selected item is not unique');\n return occurrence[0].occurrences;\n }, [selectedItem, showAdditionalItems, reducedTableData]);\n\n return (\n
    \n
    \n handleStatusFilterChange(value)}\n defaultValue={statusFilter}\n >\n \n \n \n \n {allItemsText}\n {approvedItemsText}\n {unapprovedItemsText}\n {unknownItemsText}\n \n \n \n {\n setTextFilter(event.target.value);\n }}\n />\n {additionalItemsLabels && (\n
    \n {\n setSelectedItem([]);\n setShowAdditionalItems(checked);\n }}\n />\n \n
    \n )}\n
    \n
    \n \n
    \n {occurrenceData.length > 0 && (\n
    \n \n
    \n )}\n
    \n );\n}\n","import { Input } from '@/components/shadcn-ui/input';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { useState } from 'react';\n\n/** Props for the SearchBar component. */\nexport type SearchBarProps = {\n className?: string;\n /**\n * Callback fired to handle the search query when button pressed\n *\n * @param searchQuery\n */\n onSearch: (searchQuery: string) => void;\n\n /** Optional string that appears in the search bar without a search string */\n placeholder?: string;\n\n /** Optional boolean to set the input base to full width */\n isFullWidth?: boolean;\n};\n\nexport default function SearchBar({\n className,\n onSearch,\n placeholder,\n isFullWidth,\n}: SearchBarProps) {\n const [searchQuery, setSearchQuery] = useState('');\n\n const handleInputChange = (searchString: string) => {\n setSearchQuery(searchString);\n onSearch(searchString);\n };\n\n return (\n handleInputChange(e.target.value)}\n />\n );\n}\n","// adapted from: https://github.com/shadcn-ui/ui/discussions/752\n\n'use client';\n\nimport { TabsContentProps, TabsListProps, TabsTriggerProps } from '@/components/shadcn-ui/tabs';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport * as TabsPrimitive from '@radix-ui/react-tabs';\nimport React from 'react';\n\nexport type VerticalTabsProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport type LeftTabsTriggerProps = TabsTriggerProps & {\n value: string;\n ref?: React.Ref;\n};\n\nexport const VerticalTabs = React.forwardRef<\n React.ElementRef,\n VerticalTabsProps\n>(({ className, ...props }, ref) => (\n \n));\n\nVerticalTabs.displayName = TabsPrimitive.List.displayName;\n\nexport const VerticalTabsList = React.forwardRef<\n React.ElementRef,\n TabsListProps\n>(({ className, ...props }, ref) => (\n \n));\nVerticalTabsList.displayName = TabsPrimitive.List.displayName;\n\nexport const VerticalTabsTrigger = React.forwardRef<\n React.ElementRef,\n LeftTabsTriggerProps\n>(({ className, ...props }, ref) => (\n \n));\n\nexport const VerticalTabsContent = React.forwardRef<\n React.ElementRef,\n TabsContentProps\n>(({ className, ...props }, ref) => (\n \n));\nVerticalTabsContent.displayName = TabsPrimitive.Content.displayName;\n","import SearchBar from '@/components/basics/search-bar.component';\nimport {\n VerticalTabs,\n VerticalTabsContent,\n VerticalTabsList,\n VerticalTabsTrigger,\n} from '@/components/basics/tabs-vertical';\nimport { ReactNode } from 'react';\n\nexport type TabKeyValueContent = {\n key: string;\n value: string;\n content: ReactNode;\n};\n\nexport type TabNavigationContentSearchProps = {\n /** List of values and keys for each tab this component should provide */\n tabList: TabKeyValueContent[];\n\n /** Handler to run when the value of the search bar changes */\n onSearch: (searchQuery: string) => void;\n\n /** Optional placeholder for the search bar */\n searchPlaceholder?: string;\n\n /** Optional title to include in the header */\n headerTitle?: string;\n\n /** Optional flag to make the search bar appear full width */\n isSearchBarFullWidth?: boolean;\n\n /** Text direction ltr or rtl */\n direction?: 'ltr' | 'rtl';\n};\n\nexport default function TabNavigationContentSearch({\n tabList,\n onSearch,\n searchPlaceholder,\n headerTitle,\n isSearchBarFullWidth = false,\n direction = 'ltr',\n}: TabNavigationContentSearchProps) {\n return (\n
    \n
    \n {headerTitle ?

    {headerTitle}

    : ''}\n \n
    \n \n \n {tabList.map((tab) => (\n \n {tab.value}\n \n ))}\n \n {tabList.map((tab) => (\n \n {tab.content}\n \n ))}\n \n
    \n );\n}\n","import React from 'react';\nimport * as SeparatorPrimitive from '@radix-ui/react-separator';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Separator = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, orientation = 'horizontal', decorative = true, ...props }, ref) => (\n \n));\nSeparator.displayName = SeparatorPrimitive.Root.displayName;\n\nexport { Separator };\n","'use client';\n\nimport * as React from 'react';\nimport * as SheetPrimitive from '@radix-ui/react-dialog';\nimport { cva, type VariantProps } from 'class-variance-authority';\nimport { X } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Sheet = SheetPrimitive.Root;\n\nconst SheetTrigger = SheetPrimitive.Trigger;\n\nconst SheetClose = SheetPrimitive.Close;\n\nconst SheetPortal = SheetPrimitive.Portal;\n\nconst SheetOverlay = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSheetOverlay.displayName = SheetPrimitive.Overlay.displayName;\n\nconst sheetVariants = cva(\n 'pr-twp tw-fixed tw-z-50 tw-gap-4 tw-bg-background tw-p-6 tw-shadow-lg tw-transition tw-ease-in-out data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-duration-300 data-[state=open]:tw-duration-500',\n {\n variants: {\n side: {\n top: 'tw-inset-x-0 tw-top-0 tw-border-b data-[state=closed]:tw-slide-out-to-top data-[state=open]:tw-slide-in-from-top',\n bottom:\n 'tw-inset-x-0 tw-bottom-0 tw-border-t data-[state=closed]:tw-slide-out-to-bottom data-[state=open]:tw-slide-in-from-bottom',\n left: 'tw-inset-y-0 tw-left-0 tw-h-full tw-w-3/4 tw-border-r data-[state=closed]:tw-slide-out-to-left data-[state=open]:tw-slide-in-from-left sm:tw-max-w-sm',\n right:\n 'tw-inset-y-0 tw-right-0 tw-h-full tw-w-3/4 tw- tw-border-l data-[state=closed]:tw-slide-out-to-right data-[state=open]:tw-slide-in-from-right sm:tw-max-w-sm',\n },\n },\n defaultVariants: {\n side: 'right',\n },\n },\n);\n\ninterface SheetContentProps\n extends React.ComponentPropsWithoutRef,\n VariantProps {}\n\nconst SheetContent = React.forwardRef<\n React.ElementRef,\n SheetContentProps\n>(({ side = 'right', className, children, ...props }, ref) => (\n \n \n \n {children}\n \n \n Close\n \n \n \n));\nSheetContent.displayName = SheetPrimitive.Content.displayName;\n\nfunction SheetHeader({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nSheetHeader.displayName = 'SheetHeader';\n\nfunction SheetFooter({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nSheetFooter.displayName = 'SheetFooter';\n\nconst SheetTitle = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSheetTitle.displayName = SheetPrimitive.Title.displayName;\n\nconst SheetDescription = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSheetDescription.displayName = SheetPrimitive.Description.displayName;\n\nexport {\n Sheet,\n SheetPortal,\n SheetOverlay,\n SheetTrigger,\n SheetClose,\n SheetContent,\n SheetHeader,\n SheetFooter,\n SheetTitle,\n SheetDescription,\n};\n","import React from 'react';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nfunction Skeleton({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\n\nexport { Skeleton };\n","import React from 'react';\nimport * as TooltipPrimitive from '@radix-ui/react-tooltip';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst TooltipProvider = TooltipPrimitive.Provider;\n\nconst Tooltip = TooltipPrimitive.Root;\n\nconst TooltipTrigger = TooltipPrimitive.Trigger;\n\nconst TooltipContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, sideOffset = 4, ...props }, ref) => (\n \n));\nTooltipContent.displayName = TooltipPrimitive.Content.displayName;\n\nexport { Tooltip, TooltipTrigger, TooltipContent, TooltipProvider };\n","import React from 'react';\n\nconst MOBILE_BREAKPOINT = 768;\n\nexport default function useIsMobile() {\n const [isMobile, setIsMobile] = React.useState(undefined);\n\n React.useEffect(() => {\n const mql = window.matchMedia(`(max-width: ${MOBILE_BREAKPOINT - 1}px)`);\n const onChange = () => {\n setIsMobile(window.innerWidth < MOBILE_BREAKPOINT);\n };\n mql.addEventListener('change', onChange);\n setIsMobile(window.innerWidth < MOBILE_BREAKPOINT);\n return () => mql.removeEventListener('change', onChange);\n }, []);\n\n return !!isMobile;\n}\n","import React from 'react';\nimport { Slot } from '@radix-ui/react-slot';\nimport { VariantProps, cva } from 'class-variance-authority';\nimport { PanelLeft } from 'lucide-react';\n\nimport { Button } from '@/components/shadcn-ui/button';\nimport { Input } from '@/components/shadcn-ui/input';\nimport { Separator } from '@/components/shadcn-ui/separator';\nimport { Sheet, SheetContent } from '@/components/shadcn-ui/sheet';\nimport { Skeleton } from '@/components/shadcn-ui/skeleton';\nimport {\n Tooltip,\n TooltipContent,\n TooltipProvider,\n TooltipTrigger,\n} from '@/components/shadcn-ui/tooltip';\nimport useIsMobile from '@/components/hooks/use-mobile';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst SIDEBAR_COOKIE_NAME = 'sidebar:state';\nconst SIDEBAR_COOKIE_MAX_AGE = 60 * 60 * 24 * 7;\nconst SIDEBAR_WIDTH = '16rem';\nconst SIDEBAR_WIDTH_MOBILE = '18rem';\nconst SIDEBAR_WIDTH_ICON = '3rem';\nconst SIDEBAR_KEYBOARD_SHORTCUT = 'b';\n\ntype SidebarContextProps = {\n state: 'expanded' | 'collapsed';\n open: boolean;\n setOpen: (open: boolean) => void;\n openMobile: boolean;\n setOpenMobile: (open: boolean) => void;\n isMobile: boolean;\n toggleSidebar: () => void;\n};\n\nconst SidebarContext = React.createContext(undefined);\n\nfunction useSidebar() {\n const context = React.useContext(SidebarContext);\n if (!context) {\n throw new Error('useSidebar must be used within a SidebarProvider.');\n }\n\n return context;\n}\n\nconst SidebarProvider = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & {\n defaultOpen?: boolean;\n open?: boolean;\n onOpenChange?: (open: boolean) => void;\n }\n>(\n (\n {\n defaultOpen = true,\n open: openProp,\n onOpenChange: setOpenProp,\n className,\n style,\n children,\n ...props\n },\n ref,\n ) => {\n const isMobile = useIsMobile();\n const [openMobile, setOpenMobile] = React.useState(false);\n\n // This is the internal state of the sidebar.\n // We use openProp and setOpenProp for control from outside the component.\n const [_open, _setOpen] = React.useState(defaultOpen);\n const isOpen = openProp ?? _open;\n const setOpen = React.useCallback(\n (value: boolean | ((value: boolean) => boolean)) => {\n const openState = typeof value === 'function' ? value(isOpen) : value;\n if (setOpenProp) {\n setOpenProp(openState);\n } else {\n _setOpen(openState);\n }\n\n // This sets the cookie to keep the sidebar state.\n document.cookie = `${SIDEBAR_COOKIE_NAME}=${openState}; path=/; max-age=${SIDEBAR_COOKIE_MAX_AGE}`;\n },\n [setOpenProp, isOpen],\n );\n\n // Helper to toggle the sidebar.\n const toggleSidebar = React.useCallback(() => {\n return isMobile ? setOpenMobile((open) => !open) : setOpen((open) => !open);\n }, [isMobile, setOpen, setOpenMobile]);\n\n // Adds a keyboard shortcut to toggle the sidebar.\n React.useEffect(() => {\n const handleKeyDown = (event: KeyboardEvent) => {\n if (event.key === SIDEBAR_KEYBOARD_SHORTCUT && (event.metaKey || event.ctrlKey)) {\n event.preventDefault();\n toggleSidebar();\n }\n };\n\n window.addEventListener('keydown', handleKeyDown);\n return () => window.removeEventListener('keydown', handleKeyDown);\n }, [toggleSidebar]);\n\n // We add a state so that we can do data-state=\"expanded\" or \"collapsed\".\n // This makes it easier to style the sidebar with Tailwind classes.\n const state = isOpen ? 'expanded' : 'collapsed';\n\n const contextValue = React.useMemo(\n () => ({\n state,\n open: isOpen,\n setOpen,\n isMobile,\n openMobile,\n setOpenMobile,\n toggleSidebar,\n }),\n [state, isOpen, setOpen, isMobile, openMobile, setOpenMobile, toggleSidebar],\n );\n\n return (\n \n \n \n {children}\n
    \n \n \n );\n },\n);\nSidebarProvider.displayName = 'SidebarProvider';\n\nconst Sidebar = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & {\n side?: 'left' | 'right';\n variant?: 'sidebar' | 'floating' | 'inset';\n collapsible?: 'offcanvas' | 'icon' | 'none';\n }\n>(\n (\n {\n side = 'left',\n variant = 'sidebar',\n collapsible = 'offcanvas',\n className,\n children,\n ...props\n },\n ref,\n ) => {\n const { isMobile, state, openMobile, setOpenMobile } = useSidebar();\n\n if (collapsible === 'none') {\n return (\n \n {children}\n
    \n );\n }\n\n if (isMobile) {\n return (\n \n button]:tw-hidden\"\n style={\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n {\n '--sidebar-width': SIDEBAR_WIDTH_MOBILE,\n } as React.CSSProperties\n }\n side={side}\n >\n
    {children}
    \n \n
    \n );\n }\n\n return (\n \n {/* This is what handles the sidebar gap on desktop */}\n \n \n \n {children}\n
    \n
    \n
    \n );\n },\n);\nSidebar.displayName = 'Sidebar';\n\nconst SidebarTrigger = React.forwardRef<\n React.ElementRef,\n React.ComponentProps\n>(({ className, onClick, ...props }, ref) => {\n const { toggleSidebar } = useSidebar();\n\n return (\n {\n onClick?.(event);\n toggleSidebar();\n }}\n {...props}\n >\n \n Toggle Sidebar\n \n );\n});\nSidebarTrigger.displayName = 'SidebarTrigger';\n\nconst SidebarRail = React.forwardRef>(\n ({ className, ...props }, ref) => {\n const { toggleSidebar } = useSidebar();\n\n return (\n \n );\n },\n);\nSidebarRail.displayName = 'SidebarRail';\n\nconst SidebarInset = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarInset.displayName = 'SidebarInset';\n\nconst SidebarInput = React.forwardRef<\n React.ElementRef,\n React.ComponentProps\n>(({ className, ...props }, ref) => {\n return (\n \n );\n});\nSidebarInput.displayName = 'SidebarInput';\n\nconst SidebarHeader = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarHeader.displayName = 'SidebarHeader';\n\nconst SidebarFooter = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarFooter.displayName = 'SidebarFooter';\n\nconst SidebarSeparator = React.forwardRef<\n React.ElementRef,\n React.ComponentProps\n>(({ className, ...props }, ref) => {\n return (\n \n );\n});\nSidebarSeparator.displayName = 'SidebarSeparator';\n\nconst SidebarContent = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarContent.displayName = 'SidebarContent';\n\nconst SidebarGroup = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarGroup.displayName = 'SidebarGroup';\n\nconst SidebarGroupLabel = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & { asChild?: boolean }\n>(({ className, asChild = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'div';\n\n return (\n svg]:tw-size-4 [&>svg]:tw-shrink-0',\n 'group-data-[collapsible=icon]:tw--mt-8 group-data-[collapsible=icon]:tw-opacity-0',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarGroupLabel.displayName = 'SidebarGroupLabel';\n\nconst SidebarGroupAction = React.forwardRef<\n HTMLButtonElement,\n React.ComponentProps<'button'> & { asChild?: boolean }\n>(({ className, asChild = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'button';\n\n return (\n svg]:tw-size-4 [&>svg]:tw-shrink-0',\n // Increases the hit area of the button on mobile.\n 'after:tw-absolute after:tw--inset-2 after:md:tw-hidden',\n 'group-data-[collapsible=icon]:tw-hidden',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarGroupAction.displayName = 'SidebarGroupAction';\n\nconst SidebarGroupContent = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarGroupContent.displayName = 'SidebarGroupContent';\n\nconst SidebarMenu = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenu.displayName = 'SidebarMenu';\n\nconst SidebarMenuItem = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenuItem.displayName = 'SidebarMenuItem';\n\nconst sidebarMenuButtonVariants = cva(\n // Removed data-[active=true]:tw-bg-sidebar-accent\n 'tw-peer/menu-button tw-flex tw-w-full tw-items-center tw-gap-2 tw-overflow-hidden tw-rounded-md tw-p-2 tw-text-left tw-text-sm tw-outline-none tw-ring-sidebar-ring tw-transition-[width,height,padding] hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground focus-visible:tw-ring-2 active:tw-bg-sidebar-accent active:tw-text-sidebar-accent-foreground disabled:tw-pointer-events-none disabled:tw-opacity-50 tw-group-has-[[data-sidebar=menu-action]]/menu-item:pr-8 aria-disabled:tw-pointer-events-none aria-disabled:tw-opacity-50 data-[active=true]:tw-font-medium data-[active=true]:tw-text-sidebar-accent-foreground data-[state=open]:hover:tw-bg-sidebar-accent data-[state=open]:hover:tw-text-sidebar-accent-foreground group-data-[collapsible=icon]:tw-!size-8 group-data-[collapsible=icon]:tw-!p-2 [&>span:last-child]:tw-truncate [&>svg]:tw-size-4 [&>svg]:tw-shrink-0',\n {\n variants: {\n variant: {\n default: 'hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground',\n outline:\n 'tw-bg-background tw-shadow-[0_0_0_1px_hsl(var(--sidebar-border))] hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground hover:tw-shadow-[0_0_0_1px_hsl(var(--sidebar-accent))]',\n },\n size: {\n default: 'tw-h-8 tw-text-sm',\n sm: 'tw-h-7 tw-text-xs',\n lg: 'tw-h-12 tw-text-sm group-data-[collapsible=icon]:tw-!p-0',\n },\n },\n defaultVariants: {\n variant: 'default',\n size: 'default',\n },\n },\n);\n\nconst SidebarMenuButton = React.forwardRef<\n HTMLButtonElement,\n React.ComponentProps<'button'> & {\n asChild?: boolean;\n isActive?: boolean;\n tooltip?: string | React.ComponentProps;\n } & VariantProps\n>(\n (\n {\n asChild = false,\n isActive = false,\n variant = 'default',\n size = 'default',\n tooltip,\n className,\n ...props\n },\n ref,\n ) => {\n const Comp = asChild ? Slot : 'button';\n const { isMobile, state } = useSidebar();\n\n const button = (\n \n );\n\n if (!tooltip) {\n return button;\n }\n\n if (typeof tooltip === 'string') {\n // eslint-disable-next-line no-param-reassign\n tooltip = {\n children: tooltip,\n };\n }\n\n return (\n \n {button}\n \n );\n },\n);\nSidebarMenuButton.displayName = 'SidebarMenuButton';\n\nconst SidebarMenuAction = React.forwardRef<\n HTMLButtonElement,\n React.ComponentProps<'button'> & {\n asChild?: boolean;\n showOnHover?: boolean;\n }\n>(({ className, asChild = false, showOnHover = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'button';\n\n return (\n svg]:tw-size-4 [&>svg]:tw-shrink-0',\n // Increases the hit area of the button on mobile.\n 'after:tw-absolute after:tw--inset-2 after:md:tw-hidden',\n 'tw-peer-data-[size=sm]/menu-button:top-1',\n 'tw-peer-data-[size=default]/menu-button:top-1.5',\n 'tw-peer-data-[size=lg]/menu-button:top-2.5',\n 'group-data-[collapsible=icon]:tw-hidden',\n showOnHover &&\n 'tw-group-focus-within/menu-item:opacity-100 tw-group-hover/menu-item:opacity-100 tw-peer-data-[active=true]/menu-button:text-sidebar-accent-foreground data-[state=open]:tw-opacity-100 md:tw-opacity-0',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarMenuAction.displayName = 'SidebarMenuAction';\n\nconst SidebarMenuBadge = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenuBadge.displayName = 'SidebarMenuBadge';\n\nconst SidebarMenuSkeleton = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & {\n showIcon?: boolean;\n }\n>(({ className, showIcon = false, ...props }, ref) => {\n // Random width between 50 to 90%.\n const width = React.useMemo(() => {\n return `${Math.floor(Math.random() * 40) + 50}%`;\n }, []);\n\n return (\n \n {showIcon && (\n \n )}\n \n
    \n );\n});\nSidebarMenuSkeleton.displayName = 'SidebarMenuSkeleton';\n\nconst SidebarMenuSub = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenuSub.displayName = 'SidebarMenuSub';\n\nconst SidebarMenuSubItem = React.forwardRef>(\n ({ ...props }, ref) =>
  • ,\n);\nSidebarMenuSubItem.displayName = 'SidebarMenuSubItem';\n\nconst SidebarMenuSubButton = React.forwardRef<\n HTMLAnchorElement,\n React.ComponentProps<'a'> & {\n asChild?: boolean;\n size?: 'sm' | 'md';\n isActive?: boolean;\n }\n>(({ asChild = false, size = 'md', isActive, className, ...props }, ref) => {\n const Comp = asChild ? Slot : 'a';\n\n return (\n span:last-child]:tw-truncate [&>svg]:tw-size-4 [&>svg]:tw-shrink-0 [&>svg]:tw-text-sidebar-accent-foreground',\n 'data-[active=true]:tw-bg-sidebar-accent data-[active=true]:tw-text-sidebar-accent-foreground',\n size === 'sm' && 'tw-text-xs',\n size === 'md' && 'tw-text-sm',\n 'group-data-[collapsible=icon]:tw-hidden',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarMenuSubButton.displayName = 'SidebarMenuSubButton';\n\nexport {\n Sidebar,\n SidebarContent,\n SidebarFooter,\n SidebarGroup,\n SidebarGroupAction,\n SidebarGroupContent,\n SidebarGroupLabel,\n SidebarHeader,\n SidebarInput,\n SidebarInset,\n SidebarMenu,\n SidebarMenuAction,\n SidebarMenuBadge,\n SidebarMenuButton,\n SidebarMenuItem,\n SidebarMenuSkeleton,\n SidebarMenuSub,\n SidebarMenuSubButton,\n SidebarMenuSubItem,\n SidebarProvider,\n SidebarRail,\n SidebarSeparator,\n SidebarTrigger,\n useSidebar,\n};\n","import ComboBox, { ComboBoxOption } from '@/components/basics/combo-box.component';\nimport {\n Sidebar,\n SidebarContent,\n SidebarGroup,\n SidebarGroupLabel,\n SidebarGroupContent,\n SidebarMenu,\n SidebarMenuItem,\n SidebarMenuButton,\n} from '@/components/shadcn-ui/sidebar';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { useCallback } from 'react';\n\nexport type SelectedSettingsSidebarItem = {\n label: string;\n projectId?: string;\n};\n\nexport type ProjectInfo = { projectId: string; projectName: string };\n\nexport type SettingsSidebarProps = {\n /** Optional id for testing */\n id?: string;\n\n /** Extension labels from contribution */\n extensionLabels: string[];\n\n /** Project names and ids */\n projectOptions: ProjectInfo[];\n\n /** Handler for selecting a sidebar item */\n handleSelectSidebarItem: (key: string, projectId?: string) => void;\n\n /** The current selected value in the sidebar */\n selectedSidebarItem: SelectedSettingsSidebarItem;\n\n /** Label for the group of extensions setting groups */\n extensionsSidebarGroupLabel: string;\n\n /** Label for the group of projects settings */\n projectsSidebarGroupLabel: string;\n\n /** Placeholder text for the button */\n buttonPlaceholderText: string;\n};\n\nexport default function SettingsSidebar({\n id,\n extensionLabels,\n projectOptions,\n handleSelectSidebarItem,\n selectedSidebarItem,\n extensionsSidebarGroupLabel,\n projectsSidebarGroupLabel,\n buttonPlaceholderText,\n}: SettingsSidebarProps) {\n const handleSelectItem = useCallback(\n (item: string, projectId?: string) => {\n handleSelectSidebarItem(item, projectId);\n },\n [handleSelectSidebarItem],\n );\n\n const getProjectNameFromProjectId = useCallback(\n (projectId: string) => {\n const project = projectOptions.find((option) => option.projectId === projectId);\n return project ? project.projectName : projectId;\n },\n [projectOptions],\n );\n\n const getIsActive: (label: string) => boolean = useCallback(\n (label: string) => !selectedSidebarItem.projectId && label === selectedSidebarItem.label,\n [selectedSidebarItem],\n );\n\n return (\n \n \n \n \n {extensionsSidebarGroupLabel}\n \n \n \n {extensionLabels.map((label) => (\n \n handleSelectItem(label)}\n isActive={getIsActive(label)}\n >\n {label}\n \n \n ))}\n \n \n \n \n \n {projectsSidebarGroupLabel}\n \n \n option.projectId)}\n getOptionLabel={(projectId: ComboBoxOption) => {\n // This function expects a ComboBoxOption, but we know it is a string\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n return getProjectNameFromProjectId(projectId as string);\n }}\n buttonPlaceholder={buttonPlaceholderText}\n onChange={(projectId: string) => {\n const selectedProjectName = getProjectNameFromProjectId(projectId);\n handleSelectItem(selectedProjectName, projectId);\n }}\n value={selectedSidebarItem?.projectId ?? undefined}\n />\n \n \n \n \n );\n}\n","import { SidebarInset, SidebarProvider } from '@/components/shadcn-ui/sidebar';\nimport { PropsWithChildren } from 'react';\nimport SearchBar from '@/components/basics/search-bar.component';\nimport SettingsSidebar, { SettingsSidebarProps } from './settings-sidebar.component';\n\nexport type SettingsSidebarContentSearchProps = SettingsSidebarProps &\n PropsWithChildren & {\n /** Optional id for testing */\n id?: string;\n\n /** Handler to run when the value of the search bar changes */\n onSearch: (searchQuery: string) => void;\n };\n\nexport default function SettingsSidebarContentSearch({\n id,\n extensionLabels,\n projectOptions,\n children,\n handleSelectSidebarItem,\n selectedSidebarItem,\n onSearch,\n extensionsSidebarGroupLabel,\n projectsSidebarGroupLabel,\n buttonPlaceholderText,\n}: SettingsSidebarContentSearchProps) {\n return (\n
    \n
    \n \n
    \n \n \n {children}\n \n
    \n );\n}\n","import { Button } from '@/components/shadcn-ui/button';\nimport {\n Select,\n SelectContent,\n SelectGroup,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\nimport {\n Table,\n TableBody,\n TableCell,\n TableHead,\n TableHeader,\n TableRow,\n} from '@/components/shadcn-ui/table';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Canon } from '@sillsdev/scripture';\nimport {\n Cell,\n ColumnDef,\n flexRender,\n getCoreRowModel,\n getExpandedRowModel,\n getGroupedRowModel,\n getSortedRowModel,\n GroupingState,\n Row,\n RowSelectionState,\n SortingState,\n useReactTable,\n} from '@tanstack/react-table';\nimport '@/components/advanced/scripture-results-viewer/scripture-results-viewer.component.css';\nimport {\n compareScrRefs,\n formatScrRef,\n ScriptureSelection,\n scrRefToBBBCCCVVV,\n} from 'platform-bible-utils';\nimport { MouseEvent, useEffect, useMemo, useState } from 'react';\nimport { ChevronDown, ChevronLeft, ChevronRight } from 'lucide-react';\n\n/**\n * Information (e.g., a checking error or some other type of \"transient\" annotation) about something\n * noteworthy at a specific place in an instance of the Scriptures.\n */\nexport type ScriptureItemDetail = ScriptureSelection & {\n /**\n * Text of the error, note, etc. In the future, we might want to support something more than just\n * text so that a JSX element could be provided with a link or some other controls related to the\n * issue being reported.\n */\n detail: string;\n};\n\n/**\n * A uniquely identifiable source of results that can be displayed in the ScriptureResultsViewer.\n * Generally, the source will be a particular Scripture check, but there may be other types of\n * sources.\n */\nexport type ResultsSource = {\n /**\n * Uniquely identifies the source.\n *\n * @type {string}\n */\n id: string;\n\n /**\n * Name (potentially localized) of the source, suitable for display in the UI.\n *\n * @type {string}\n */\n displayName: string;\n};\n\nexport type ScriptureSrcItemDetail = ScriptureItemDetail & {\n /** Source/type of detail. Can be used for grouping. */\n source: ResultsSource;\n};\n\n/**\n * Represents a set of results keyed by Scripture reference. Generally, the source will be a\n * particular Scripture check, but this type also allows for other types of uniquely identifiable\n * sources.\n */\nexport type ResultsSet = {\n /**\n * The backing source associated with this set of results.\n *\n * @type {ResultsSource}\n */\n source: ResultsSource;\n\n /**\n * Array of Scripture item details (messages keyed by Scripture reference).\n *\n * @type {ScriptureItemDetail[]}\n */\n data: ScriptureItemDetail[];\n};\n\nconst scrBookColId = 'scrBook';\nconst scrRefColId = 'scrRef';\nconst typeColId = 'source';\nconst detailsColId = 'details';\n\nconst defaultScrRefColumnName = 'Scripture Reference';\nconst defaultScrBookGroupName = 'Scripture Book';\nconst defaultTypeColumnName = 'Type';\nconst defaultDetailsColumnName = 'Details';\n\nexport type ScriptureResultsViewerColumnInfo = {\n /** Optional header to display for the Reference column. Default value: 'Scripture Reference'. */\n scriptureReferenceColumnName?: string;\n\n /** Optional text to display to refer to the Scripture book group. Default value: 'Scripture Book'. */\n scriptureBookGroupName?: string;\n\n /** Optional header to display for the Type column. Default value: 'Type'. */\n typeColumnName?: string;\n\n /** Optional header to display for the Details column. Default value: 'Details' */\n detailsColumnName?: string;\n};\n\nexport type ScriptureResultsViewerProps = ScriptureResultsViewerColumnInfo & {\n /** Groups of ScriptureItemDetail objects from particular sources (e.g., Scripture checks) */\n sources: ResultsSet[];\n\n /** Flag indicating whether to display column headers. Default is false. */\n showColumnHeaders?: boolean;\n\n /** Flag indicating whether to display source column. Default is false. */\n showSourceColumn?: boolean;\n\n /** Callback function to notify when a row is selected */\n onRowSelected?: (selectedRow: ScriptureSrcItemDetail | undefined) => void;\n\n /** Text direction ltr or rtl */\n direction?: 'ltr' | 'rtl';\n};\n\nfunction getColumns(\n colInfo?: ScriptureResultsViewerColumnInfo,\n showSourceColumn?: boolean,\n): ColumnDef[] {\n const showSrcCol = showSourceColumn ?? false;\n return [\n {\n accessorFn: (row) =>\n `${Canon.bookNumberToId(row.start.bookNum)} ${row.start.chapterNum}:${row.start.verseNum}`,\n id: scrBookColId,\n header: colInfo?.scriptureReferenceColumnName ?? defaultScrRefColumnName,\n cell: (info) => {\n const row = info.row.original;\n if (info.row.getIsGrouped()) {\n return Canon.bookNumberToEnglishName(row.start.bookNum);\n }\n return info.row.groupingColumnId === scrBookColId ? formatScrRef(row.start) : undefined;\n },\n getGroupingValue: (row) => row.start.bookNum,\n sortingFn: (a, b) => {\n return compareScrRefs(a.original.start, b.original.start);\n },\n enableGrouping: true,\n },\n {\n accessorFn: (row) => formatScrRef(row.start),\n id: scrRefColId,\n header: undefined,\n cell: (info) => {\n const row = info.row.original;\n return info.row.getIsGrouped() ? undefined : formatScrRef(row.start);\n },\n sortingFn: (a, b) => {\n return compareScrRefs(a.original.start, b.original.start);\n },\n enableGrouping: false,\n },\n {\n accessorFn: (row) => row.source.displayName,\n id: typeColId,\n header: showSrcCol ? (colInfo?.typeColumnName ?? defaultTypeColumnName) : undefined,\n cell: (info) => (showSrcCol || info.row.getIsGrouped() ? info.getValue() : undefined),\n getGroupingValue: (row) => row.source.id,\n sortingFn: (a, b) =>\n a.original.source.displayName.localeCompare(b.original.source.displayName),\n enableGrouping: true,\n },\n {\n accessorFn: (row) => row.detail,\n id: detailsColId,\n header: colInfo?.detailsColumnName ?? defaultDetailsColumnName,\n cell: (info) => info.getValue(),\n enableGrouping: false,\n },\n ];\n}\n\nconst toRefOrRange = (scriptureSelection: ScriptureSelection) => {\n if (!('offset' in scriptureSelection.start))\n throw new Error('No offset available in range start');\n if (scriptureSelection.end && !('offset' in scriptureSelection.end))\n throw new Error('No offset available in range end');\n const { offset: offsetStart } = scriptureSelection.start;\n let offsetEnd: number = 0;\n if (scriptureSelection.end) ({ offset: offsetEnd } = scriptureSelection.end);\n if (\n !scriptureSelection.end ||\n compareScrRefs(scriptureSelection.start, scriptureSelection.end) === 0\n )\n return `${scrRefToBBBCCCVVV(scriptureSelection.start)}+${offsetStart}`;\n return `${scrRefToBBBCCCVVV(scriptureSelection.start)}+${offsetStart}-${scrRefToBBBCCCVVV(scriptureSelection.end)}+${offsetEnd}`;\n};\n\nconst getRowKey = (row: ScriptureSrcItemDetail) =>\n `${toRefOrRange({ start: row.start, end: row.end })} ${row.source.displayName} ${row.detail}`;\n\n/**\n * Component to display a combined list of detailed items from one or more sources, where the items\n * are keyed primarily by Scripture reference. This is particularly useful for displaying a list of\n * results from Scripture checks, but more generally could be used to display any \"results\" from any\n * source(s). The component allows for grouping by Scripture book, source, or both. By default, it\n * displays somewhat \"tree-like\" which allows it to be more horizontally compact and intuitive. But\n * it also has the option of displaying as a traditional table with column headings (with or without\n * the source column showing).\n */\nexport default function ScriptureResultsViewer({\n sources,\n showColumnHeaders = false,\n showSourceColumn = false,\n scriptureReferenceColumnName,\n scriptureBookGroupName,\n typeColumnName,\n detailsColumnName,\n onRowSelected,\n direction = 'ltr',\n}: ScriptureResultsViewerProps) {\n const [grouping, setGrouping] = useState([]);\n const [sorting, setSorting] = useState([{ id: scrBookColId, desc: false }]);\n const [rowSelection, setRowSelection] = useState({});\n\n const scriptureResults = useMemo(\n () =>\n sources.flatMap((source) => {\n return source.data.map((item) => ({\n ...item,\n source: source.source,\n }));\n }),\n [sources],\n );\n\n const columns = useMemo(\n () =>\n getColumns(\n {\n scriptureReferenceColumnName,\n typeColumnName,\n detailsColumnName,\n },\n showSourceColumn,\n ),\n [scriptureReferenceColumnName, typeColumnName, detailsColumnName, showSourceColumn],\n );\n\n useEffect(() => {\n // Ensure sorting is applied correctly when grouped by type\n if (grouping.includes(typeColId)) {\n setSorting([\n { id: typeColId, desc: false },\n { id: scrBookColId, desc: false },\n ]);\n } else {\n setSorting([{ id: scrBookColId, desc: false }]);\n }\n }, [grouping]);\n\n const table = useReactTable({\n data: scriptureResults,\n columns,\n state: {\n grouping,\n sorting,\n rowSelection,\n },\n onGroupingChange: setGrouping,\n onSortingChange: setSorting,\n onRowSelectionChange: setRowSelection,\n getExpandedRowModel: getExpandedRowModel(),\n getGroupedRowModel: getGroupedRowModel(),\n getCoreRowModel: getCoreRowModel(),\n getSortedRowModel: getSortedRowModel(),\n getRowId: getRowKey,\n autoResetExpanded: false,\n enableMultiRowSelection: false,\n enableSubRowSelection: false,\n });\n\n useEffect(() => {\n if (onRowSelected) {\n const selectedRows = table.getSelectedRowModel().rowsById;\n const keys = Object.keys(selectedRows);\n if (keys.length === 1) {\n const selectedRow = scriptureResults.find((row) => getRowKey(row) === keys[0]) || undefined;\n if (selectedRow) onRowSelected(selectedRow);\n }\n }\n }, [rowSelection, scriptureResults, onRowSelected, table]);\n\n // Define possible grouping options\n const scrBookGroupName = scriptureBookGroupName ?? defaultScrBookGroupName;\n const typeGroupName = typeColumnName ?? defaultTypeColumnName;\n\n const groupingOptions = [\n { label: 'No Grouping', value: [] },\n { label: `Group by ${scrBookGroupName}`, value: [scrBookColId] },\n { label: `Group by ${typeGroupName}`, value: [typeColId] },\n {\n label: `Group by ${scrBookGroupName} and ${typeGroupName}`,\n value: [scrBookColId, typeColId],\n },\n {\n label: `Group by ${typeGroupName} and ${scrBookGroupName}`,\n value: [typeColId, scrBookColId],\n },\n ];\n\n const handleSelectChange = (selectedGrouping: string) => {\n setGrouping(JSON.parse(selectedGrouping));\n };\n\n const handleRowClick = (row: Row, event: MouseEvent) => {\n if (!row.getIsGrouped() && !row.getIsSelected()) {\n row.getToggleSelectedHandler()(event);\n }\n };\n\n const getEvenOrOddBandingStyle = (row: Row, index: number) => {\n if (row.getIsGrouped()) return '';\n // UX has now said they don't think they want banding. I'm leaving in the code to\n // set even and odd styles, but there's nothing in the CSS to style them differently.\n // The \"even\" style used to also have tw-bg-neutral-300 (along with even) to create\n // a visual banding effect. That could be added back in if UX changes the decision.\n return cn('banded-row', index % 2 === 0 ? 'even' : 'odd');\n };\n\n const getIndent = (\n groupingState: GroupingState,\n row: Row,\n cell: Cell,\n ) => {\n if (groupingState?.length === 0 || row.depth < cell.column.getGroupedIndex()) return undefined;\n if (row.getIsGrouped()) {\n switch (row.depth) {\n case 1:\n return 'tw-ps-4';\n default:\n return undefined;\n }\n }\n switch (row.depth) {\n case 1:\n return 'tw-ps-8';\n case 2:\n return 'tw-ps-12';\n default:\n return undefined;\n }\n };\n\n return (\n
    \n {!showColumnHeaders && (\n {\n handleSelectChange(value);\n }}\n >\n \n \n \n \n \n {groupingOptions.map((option) => (\n \n {option.label}\n \n ))}\n \n \n \n )}\n \n {showColumnHeaders && (\n \n {table.getHeaderGroups().map((headerGroup) => (\n \n {headerGroup.headers\n .filter((h) => h.column.columnDef.header)\n .map((header) => (\n /* For sticky column headers to work, we probably need to change the default definition of the shadcn Table component. See https://github.com/shadcn-ui/ui/issues/1151 */\n \n {header.isPlaceholder ? undefined : (\n
    \n {header.column.getCanGroup() ? (\n \n {header.column.getIsGrouped() ? `🛑` : `👊 `}\n \n ) : undefined}{' '}\n {flexRender(header.column.columnDef.header, header.getContext())}\n
    \n )}\n
    \n ))}\n
    \n ))}\n
    \n )}\n \n {table.getRowModel().rows.map((row, rowIndex) => {\n return (\n handleRowClick(row, event)}\n >\n {row.getVisibleCells().map((cell) => {\n if (\n cell.getIsPlaceholder() ||\n (cell.column.columnDef.enableGrouping &&\n !cell.getIsGrouped() &&\n (cell.column.columnDef.id !== typeColId || !showSourceColumn))\n )\n return undefined;\n return (\n \n {(() => {\n if (cell.getIsGrouped()) {\n return (\n \n {row.getIsExpanded() && }\n {!row.getIsExpanded() &&\n (direction === 'ltr' ? : )}{' '}\n {flexRender(cell.column.columnDef.cell, cell.getContext())} (\n {row.subRows.length})\n \n );\n }\n\n // if (cell.getIsAggregated()) {\n // flexRender(\n // cell.column.columnDef.aggregatedCell ?? cell.column.columnDef.cell,\n // cell.getContext(),\n // );\n // }\n\n return flexRender(cell.column.columnDef.cell, cell.getContext());\n })()}\n \n );\n })}\n \n );\n })}\n \n
    \n
    \n );\n}\n","import {\n getLocalizeKeyForScrollGroupId,\n LanguageStrings,\n ScrollGroupId,\n} from 'platform-bible-utils';\nimport {\n Select,\n SelectContent,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\n\nconst DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS = {\n [getLocalizeKeyForScrollGroupId('undefined')]: 'Ø',\n [getLocalizeKeyForScrollGroupId(0)]: 'A',\n [getLocalizeKeyForScrollGroupId(1)]: 'B',\n [getLocalizeKeyForScrollGroupId(2)]: 'C',\n [getLocalizeKeyForScrollGroupId(3)]: 'D',\n [getLocalizeKeyForScrollGroupId(4)]: 'E',\n [getLocalizeKeyForScrollGroupId(5)]: 'F',\n [getLocalizeKeyForScrollGroupId(6)]: 'G',\n [getLocalizeKeyForScrollGroupId(7)]: 'H',\n [getLocalizeKeyForScrollGroupId(8)]: 'I',\n [getLocalizeKeyForScrollGroupId(9)]: 'J',\n [getLocalizeKeyForScrollGroupId(10)]: 'K',\n [getLocalizeKeyForScrollGroupId(11)]: 'L',\n [getLocalizeKeyForScrollGroupId(12)]: 'M',\n [getLocalizeKeyForScrollGroupId(13)]: 'N',\n [getLocalizeKeyForScrollGroupId(14)]: 'O',\n [getLocalizeKeyForScrollGroupId(15)]: 'P',\n [getLocalizeKeyForScrollGroupId(16)]: 'Q',\n [getLocalizeKeyForScrollGroupId(17)]: 'R',\n [getLocalizeKeyForScrollGroupId(18)]: 'S',\n [getLocalizeKeyForScrollGroupId(19)]: 'T',\n [getLocalizeKeyForScrollGroupId(20)]: 'U',\n [getLocalizeKeyForScrollGroupId(21)]: 'V',\n [getLocalizeKeyForScrollGroupId(22)]: 'W',\n [getLocalizeKeyForScrollGroupId(23)]: 'X',\n [getLocalizeKeyForScrollGroupId(24)]: 'Y',\n [getLocalizeKeyForScrollGroupId(25)]: 'Z',\n};\n\nexport type ScrollGroupSelectorProps = {\n /**\n * List of scroll group ids to show to the user. Either a {@link ScrollGroupId} or `undefined` for\n * no scroll group\n */\n availableScrollGroupIds: (ScrollGroupId | undefined)[];\n /** Currently selected scroll group id. `undefined` for no scroll group */\n scrollGroupId: ScrollGroupId | undefined;\n /** Callback function run when the user tries to change the scroll group id */\n onChangeScrollGroupId: (newScrollGroupId: ScrollGroupId | undefined) => void;\n /**\n * Localized strings to use for displaying scroll group ids. Must be an object whose keys are\n * `getLocalizeKeyForScrollGroupId(scrollGroupId)` for all scroll group ids (and `undefined` if\n * included) in {@link ScrollGroupSelectorProps.availableScrollGroupIds} and whose values are the\n * localized strings to use for those scroll group ids.\n *\n * Defaults to English localizations of English alphabet for scroll groups 0-25 (e.g. 0 is A) and\n * Ø for `undefined`. Will fill in any that are not provided with these English localizations.\n * Also, if any values match the keys, the English localization will be used. This is useful in\n * case you want to pass in a temporary version of the localized strings while your localized\n * strings load.\n *\n * @example\n *\n * ```typescript\n * const myScrollGroupIdLocalizedStrings = {\n * [getLocalizeKeyForScrollGroupId('undefined')]: 'Ø',\n * [getLocalizeKeyForScrollGroupId(0)]: 'A',\n * [getLocalizeKeyForScrollGroupId(1)]: 'B',\n * [getLocalizeKeyForScrollGroupId(2)]: 'C',\n * [getLocalizeKeyForScrollGroupId(3)]: 'D',\n * [getLocalizeKeyForScrollGroupId(4)]: 'E',\n * };\n * ```\n *\n * @example\n *\n * ```tsx\n * const availableScrollGroupIds = [undefined, 0, 1, 2, 3, 4];\n *\n * const localizeKeys = getLocalizeKeysForScrollGroupIds();\n *\n * const [localizedStrings] = useLocalizedStrings(localizeKeys);\n *\n * ...\n *\n * \n * ```\n */\n localizedStrings?: LanguageStrings;\n};\n\n/** Selector component for choosing a scroll group */\nexport default function ScrollGroupSelector({\n availableScrollGroupIds,\n scrollGroupId,\n onChangeScrollGroupId,\n localizedStrings = {},\n}: ScrollGroupSelectorProps) {\n const localizedStringsDefaulted = {\n ...DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS,\n ...Object.fromEntries(\n Object.entries(localizedStrings).map(\n ([localizedStringKey, localizedStringValue]: [string, string]) => [\n localizedStringKey,\n localizedStringKey === localizedStringValue &&\n localizedStringKey in DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS\n ? DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS[localizedStringKey]\n : localizedStringValue,\n ],\n ),\n ),\n };\n return (\n \n onChangeScrollGroupId(\n newScrollGroupString === 'undefined' ? undefined : parseInt(newScrollGroupString, 10),\n )\n }\n >\n \n \n \n \n {availableScrollGroupIds.map((scrollGroupOptionId) => (\n \n {localizedStringsDefaulted[getLocalizeKeyForScrollGroupId(scrollGroupOptionId)]}\n \n ))}\n \n \n );\n}\n","import { PropsWithChildren } from 'react';\nimport { Separator } from '@/components/shadcn-ui/separator';\n\n/** Props for the SettingsList component, currently just children */\ntype SettingsListProps = PropsWithChildren;\n\n/**\n * SettingsList component is a wrapper for list items. Rendered with a formatted div\n *\n * @param children To populate the list with\n * @returns Formatted div encompassing the children\n */\nexport function SettingsList({ children }: SettingsListProps) {\n return
    {children}
    ;\n}\n\n/** Props for SettingsListItem component */\ntype SettingsListItemProps = PropsWithChildren & {\n /** Primary text of the list item */\n primary: string;\n\n /** Optional text of the list item */\n secondary?: string | undefined;\n\n /** Optional boolean to display a message if the children aren't loaded yet. Defaults to false */\n isLoading?: boolean;\n\n /** Optional message to display if isLoading */\n loadingMessage?: string;\n};\n\n/**\n * SettingsListItem component is a common list item. Rendered with a formatted div\n *\n * @param primary Primary text of the list item\n * @param secondary Optional secondary text of the list item\n * @param isLoading Optional, to display a message if the action component isn't generated yet,\n * defaults to false\n * @param children The action component(s) to provide for this item\n * @param loadingMessage Optional, message to display if isLoading\n * @returns Formatted div encompassing the list item content\n */\nexport function SettingsListItem({\n primary,\n secondary,\n children,\n isLoading = false,\n loadingMessage,\n}: SettingsListItemProps) {\n return (\n
    \n
    \n

    {primary}

    \n

    \n {secondary}\n

    \n
    \n\n {isLoading ? (\n

    {loadingMessage}

    \n ) : (\n
    {children}
    \n )}\n
    \n );\n}\n\n/** Props for SettingsListHeader component */\ntype SettingsListHeaderProps = {\n /** The primary text of the list header */\n primary: string;\n\n /** Optional secondary text of the list header */\n secondary?: string | undefined;\n\n /** Optional boolean to include a separator underneath the secondary text. Defaults to false */\n includeSeparator?: boolean;\n};\n\n/**\n * SettingsListHeader component displays text above the list\n *\n * @param primary The primary text of the list header\n * @param secondary Optional secondary text of the list header\n * @param includeSeparator Optional boolean to include a separator underneath the secondary text.\n * Defaults to false\n * @returns Formatted div with list header content\n */\nexport function SettingsListHeader({\n primary,\n secondary,\n includeSeparator = false,\n}: SettingsListHeaderProps) {\n return (\n
    \n
    \n

    {primary}

    \n

    {secondary}

    \n
    \n {includeSeparator ? : ''}\n
    \n );\n}\n","import Checkbox from '@/components/shadcn-ui/checkbox';\nimport { Label } from '@/components/shadcn-ui/label';\n\nexport type ChecklistProps = {\n /** Optional string representing the id attribute of the Checklist */\n id?: string;\n /** Optional string representing CSS class name(s) for styling */\n className?: string;\n /** Array of strings representing the checkable items */\n listItems: string[];\n /** Array of strings representing the checked items */\n selectedListItems: string[];\n /**\n * Function that is called when a checkbox item is selected or deselected\n *\n * @param item The string description for this item\n * @param selected True if selected, false if not selected\n */\n handleSelectListItem: (item: string, selected: boolean) => void;\n\n /**\n * Optional function creates a label for a provided checkable item\n *\n * @param item The item for which a label is to be created\n * @returns A string representing the label text for the checkbox associated with that item\n */\n createLabel?: (item: string) => string;\n};\n\n/** Renders a list of checkboxes. Each checkbox corresponds to an item from the `listItems` array. */\nexport default function Checklist({\n id,\n className,\n listItems,\n selectedListItems,\n handleSelectListItem,\n createLabel,\n}: ChecklistProps) {\n return (\n
    \n {listItems.map((item) => (\n
    \n handleSelectListItem(item, value)}\n />\n \n
    \n ))}\n
    \n );\n}\n","function _interopRequireDefault(obj) {\n return obj && obj.__esModule ? obj : {\n \"default\": obj\n };\n}\nmodule.exports = _interopRequireDefault, module.exports.__esModule = true, module.exports[\"default\"] = module.exports;","export default function chainPropTypes(propType1, propType2) {\n if (process.env.NODE_ENV === 'production') {\n return () => null;\n }\n return function validate(...args) {\n return propType1(...args) || propType2(...args);\n };\n}","export default function _extends() {\n _extends = Object.assign ? Object.assign.bind() : function (target) {\n for (var i = 1; i < arguments.length; i++) {\n var source = arguments[i];\n for (var key in source) {\n if (Object.prototype.hasOwnProperty.call(source, key)) {\n target[key] = source[key];\n }\n }\n }\n return target;\n };\n return _extends.apply(this, arguments);\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\n// https://github.com/sindresorhus/is-plain-obj/blob/main/index.js\nexport function isPlainObject(item) {\n if (typeof item !== 'object' || item === null) {\n return false;\n }\n const prototype = Object.getPrototypeOf(item);\n return (prototype === null || prototype === Object.prototype || Object.getPrototypeOf(prototype) === null) && !(Symbol.toStringTag in item) && !(Symbol.iterator in item);\n}\nfunction deepClone(source) {\n if (!isPlainObject(source)) {\n return source;\n }\n const output = {};\n Object.keys(source).forEach(key => {\n output[key] = deepClone(source[key]);\n });\n return output;\n}\nexport default function deepmerge(target, source, options = {\n clone: true\n}) {\n const output = options.clone ? _extends({}, target) : target;\n if (isPlainObject(target) && isPlainObject(source)) {\n Object.keys(source).forEach(key => {\n // Avoid prototype pollution\n if (key === '__proto__') {\n return;\n }\n if (isPlainObject(source[key]) && key in target && isPlainObject(target[key])) {\n // Since `output` is a clone of `target` and we have narrowed `target` in this block we can cast to the same type.\n output[key] = deepmerge(target[key], source[key], options);\n } else if (options.clone) {\n output[key] = isPlainObject(source[key]) ? deepClone(source[key]) : source[key];\n } else {\n output[key] = source[key];\n }\n });\n }\n return output;\n}","/** @license React v16.13.1\n * react-is.production.min.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';var b=\"function\"===typeof Symbol&&Symbol.for,c=b?Symbol.for(\"react.element\"):60103,d=b?Symbol.for(\"react.portal\"):60106,e=b?Symbol.for(\"react.fragment\"):60107,f=b?Symbol.for(\"react.strict_mode\"):60108,g=b?Symbol.for(\"react.profiler\"):60114,h=b?Symbol.for(\"react.provider\"):60109,k=b?Symbol.for(\"react.context\"):60110,l=b?Symbol.for(\"react.async_mode\"):60111,m=b?Symbol.for(\"react.concurrent_mode\"):60111,n=b?Symbol.for(\"react.forward_ref\"):60112,p=b?Symbol.for(\"react.suspense\"):60113,q=b?\nSymbol.for(\"react.suspense_list\"):60120,r=b?Symbol.for(\"react.memo\"):60115,t=b?Symbol.for(\"react.lazy\"):60116,v=b?Symbol.for(\"react.block\"):60121,w=b?Symbol.for(\"react.fundamental\"):60117,x=b?Symbol.for(\"react.responder\"):60118,y=b?Symbol.for(\"react.scope\"):60119;\nfunction z(a){if(\"object\"===typeof a&&null!==a){var u=a.$$typeof;switch(u){case c:switch(a=a.type,a){case l:case m:case e:case g:case f:case p:return a;default:switch(a=a&&a.$$typeof,a){case k:case n:case t:case r:case h:return a;default:return u}}case d:return u}}}function A(a){return z(a)===m}exports.AsyncMode=l;exports.ConcurrentMode=m;exports.ContextConsumer=k;exports.ContextProvider=h;exports.Element=c;exports.ForwardRef=n;exports.Fragment=e;exports.Lazy=t;exports.Memo=r;exports.Portal=d;\nexports.Profiler=g;exports.StrictMode=f;exports.Suspense=p;exports.isAsyncMode=function(a){return A(a)||z(a)===l};exports.isConcurrentMode=A;exports.isContextConsumer=function(a){return z(a)===k};exports.isContextProvider=function(a){return z(a)===h};exports.isElement=function(a){return\"object\"===typeof a&&null!==a&&a.$$typeof===c};exports.isForwardRef=function(a){return z(a)===n};exports.isFragment=function(a){return z(a)===e};exports.isLazy=function(a){return z(a)===t};\nexports.isMemo=function(a){return z(a)===r};exports.isPortal=function(a){return z(a)===d};exports.isProfiler=function(a){return z(a)===g};exports.isStrictMode=function(a){return z(a)===f};exports.isSuspense=function(a){return z(a)===p};\nexports.isValidElementType=function(a){return\"string\"===typeof a||\"function\"===typeof a||a===e||a===m||a===g||a===f||a===p||a===q||\"object\"===typeof a&&null!==a&&(a.$$typeof===t||a.$$typeof===r||a.$$typeof===h||a.$$typeof===k||a.$$typeof===n||a.$$typeof===w||a.$$typeof===x||a.$$typeof===y||a.$$typeof===v)};exports.typeOf=z;\n","/** @license React v16.13.1\n * react-is.development.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\n\n\nif (process.env.NODE_ENV !== \"production\") {\n (function() {\n'use strict';\n\n// The Symbol used to tag the ReactElement-like types. If there is no native Symbol\n// nor polyfill, then a plain number is used for performance.\nvar hasSymbol = typeof Symbol === 'function' && Symbol.for;\nvar REACT_ELEMENT_TYPE = hasSymbol ? Symbol.for('react.element') : 0xeac7;\nvar REACT_PORTAL_TYPE = hasSymbol ? Symbol.for('react.portal') : 0xeaca;\nvar REACT_FRAGMENT_TYPE = hasSymbol ? Symbol.for('react.fragment') : 0xeacb;\nvar REACT_STRICT_MODE_TYPE = hasSymbol ? Symbol.for('react.strict_mode') : 0xeacc;\nvar REACT_PROFILER_TYPE = hasSymbol ? Symbol.for('react.profiler') : 0xead2;\nvar REACT_PROVIDER_TYPE = hasSymbol ? Symbol.for('react.provider') : 0xeacd;\nvar REACT_CONTEXT_TYPE = hasSymbol ? Symbol.for('react.context') : 0xeace; // TODO: We don't use AsyncMode or ConcurrentMode anymore. They were temporary\n// (unstable) APIs that have been removed. Can we remove the symbols?\n\nvar REACT_ASYNC_MODE_TYPE = hasSymbol ? Symbol.for('react.async_mode') : 0xeacf;\nvar REACT_CONCURRENT_MODE_TYPE = hasSymbol ? Symbol.for('react.concurrent_mode') : 0xeacf;\nvar REACT_FORWARD_REF_TYPE = hasSymbol ? Symbol.for('react.forward_ref') : 0xead0;\nvar REACT_SUSPENSE_TYPE = hasSymbol ? Symbol.for('react.suspense') : 0xead1;\nvar REACT_SUSPENSE_LIST_TYPE = hasSymbol ? Symbol.for('react.suspense_list') : 0xead8;\nvar REACT_MEMO_TYPE = hasSymbol ? Symbol.for('react.memo') : 0xead3;\nvar REACT_LAZY_TYPE = hasSymbol ? Symbol.for('react.lazy') : 0xead4;\nvar REACT_BLOCK_TYPE = hasSymbol ? Symbol.for('react.block') : 0xead9;\nvar REACT_FUNDAMENTAL_TYPE = hasSymbol ? Symbol.for('react.fundamental') : 0xead5;\nvar REACT_RESPONDER_TYPE = hasSymbol ? Symbol.for('react.responder') : 0xead6;\nvar REACT_SCOPE_TYPE = hasSymbol ? Symbol.for('react.scope') : 0xead7;\n\nfunction isValidElementType(type) {\n return typeof type === 'string' || typeof type === 'function' || // Note: its typeof might be other than 'symbol' or 'number' if it's a polyfill.\n type === REACT_FRAGMENT_TYPE || type === REACT_CONCURRENT_MODE_TYPE || type === REACT_PROFILER_TYPE || type === REACT_STRICT_MODE_TYPE || type === REACT_SUSPENSE_TYPE || type === REACT_SUSPENSE_LIST_TYPE || typeof type === 'object' && type !== null && (type.$$typeof === REACT_LAZY_TYPE || type.$$typeof === REACT_MEMO_TYPE || type.$$typeof === REACT_PROVIDER_TYPE || type.$$typeof === REACT_CONTEXT_TYPE || type.$$typeof === REACT_FORWARD_REF_TYPE || type.$$typeof === REACT_FUNDAMENTAL_TYPE || type.$$typeof === REACT_RESPONDER_TYPE || type.$$typeof === REACT_SCOPE_TYPE || type.$$typeof === REACT_BLOCK_TYPE);\n}\n\nfunction typeOf(object) {\n if (typeof object === 'object' && object !== null) {\n var $$typeof = object.$$typeof;\n\n switch ($$typeof) {\n case REACT_ELEMENT_TYPE:\n var type = object.type;\n\n switch (type) {\n case REACT_ASYNC_MODE_TYPE:\n case REACT_CONCURRENT_MODE_TYPE:\n case REACT_FRAGMENT_TYPE:\n case REACT_PROFILER_TYPE:\n case REACT_STRICT_MODE_TYPE:\n case REACT_SUSPENSE_TYPE:\n return type;\n\n default:\n var $$typeofType = type && type.$$typeof;\n\n switch ($$typeofType) {\n case REACT_CONTEXT_TYPE:\n case REACT_FORWARD_REF_TYPE:\n case REACT_LAZY_TYPE:\n case REACT_MEMO_TYPE:\n case REACT_PROVIDER_TYPE:\n return $$typeofType;\n\n default:\n return $$typeof;\n }\n\n }\n\n case REACT_PORTAL_TYPE:\n return $$typeof;\n }\n }\n\n return undefined;\n} // AsyncMode is deprecated along with isAsyncMode\n\nvar AsyncMode = REACT_ASYNC_MODE_TYPE;\nvar ConcurrentMode = REACT_CONCURRENT_MODE_TYPE;\nvar ContextConsumer = REACT_CONTEXT_TYPE;\nvar ContextProvider = REACT_PROVIDER_TYPE;\nvar Element = REACT_ELEMENT_TYPE;\nvar ForwardRef = REACT_FORWARD_REF_TYPE;\nvar Fragment = REACT_FRAGMENT_TYPE;\nvar Lazy = REACT_LAZY_TYPE;\nvar Memo = REACT_MEMO_TYPE;\nvar Portal = REACT_PORTAL_TYPE;\nvar Profiler = REACT_PROFILER_TYPE;\nvar StrictMode = REACT_STRICT_MODE_TYPE;\nvar Suspense = REACT_SUSPENSE_TYPE;\nvar hasWarnedAboutDeprecatedIsAsyncMode = false; // AsyncMode should be deprecated\n\nfunction isAsyncMode(object) {\n {\n if (!hasWarnedAboutDeprecatedIsAsyncMode) {\n hasWarnedAboutDeprecatedIsAsyncMode = true; // Using console['warn'] to evade Babel and ESLint\n\n console['warn']('The ReactIs.isAsyncMode() alias has been deprecated, ' + 'and will be removed in React 17+. Update your code to use ' + 'ReactIs.isConcurrentMode() instead. It has the exact same API.');\n }\n }\n\n return isConcurrentMode(object) || typeOf(object) === REACT_ASYNC_MODE_TYPE;\n}\nfunction isConcurrentMode(object) {\n return typeOf(object) === REACT_CONCURRENT_MODE_TYPE;\n}\nfunction isContextConsumer(object) {\n return typeOf(object) === REACT_CONTEXT_TYPE;\n}\nfunction isContextProvider(object) {\n return typeOf(object) === REACT_PROVIDER_TYPE;\n}\nfunction isElement(object) {\n return typeof object === 'object' && object !== null && object.$$typeof === REACT_ELEMENT_TYPE;\n}\nfunction isForwardRef(object) {\n return typeOf(object) === REACT_FORWARD_REF_TYPE;\n}\nfunction isFragment(object) {\n return typeOf(object) === REACT_FRAGMENT_TYPE;\n}\nfunction isLazy(object) {\n return typeOf(object) === REACT_LAZY_TYPE;\n}\nfunction isMemo(object) {\n return typeOf(object) === REACT_MEMO_TYPE;\n}\nfunction isPortal(object) {\n return typeOf(object) === REACT_PORTAL_TYPE;\n}\nfunction isProfiler(object) {\n return typeOf(object) === REACT_PROFILER_TYPE;\n}\nfunction isStrictMode(object) {\n return typeOf(object) === REACT_STRICT_MODE_TYPE;\n}\nfunction isSuspense(object) {\n return typeOf(object) === REACT_SUSPENSE_TYPE;\n}\n\nexports.AsyncMode = AsyncMode;\nexports.ConcurrentMode = ConcurrentMode;\nexports.ContextConsumer = ContextConsumer;\nexports.ContextProvider = ContextProvider;\nexports.Element = Element;\nexports.ForwardRef = ForwardRef;\nexports.Fragment = Fragment;\nexports.Lazy = Lazy;\nexports.Memo = Memo;\nexports.Portal = Portal;\nexports.Profiler = Profiler;\nexports.StrictMode = StrictMode;\nexports.Suspense = Suspense;\nexports.isAsyncMode = isAsyncMode;\nexports.isConcurrentMode = isConcurrentMode;\nexports.isContextConsumer = isContextConsumer;\nexports.isContextProvider = isContextProvider;\nexports.isElement = isElement;\nexports.isForwardRef = isForwardRef;\nexports.isFragment = isFragment;\nexports.isLazy = isLazy;\nexports.isMemo = isMemo;\nexports.isPortal = isPortal;\nexports.isProfiler = isProfiler;\nexports.isStrictMode = isStrictMode;\nexports.isSuspense = isSuspense;\nexports.isValidElementType = isValidElementType;\nexports.typeOf = typeOf;\n })();\n}\n","'use strict';\n\nif (process.env.NODE_ENV === 'production') {\n module.exports = require('./cjs/react-is.production.min.js');\n} else {\n module.exports = require('./cjs/react-is.development.js');\n}\n","/*\nobject-assign\n(c) Sindre Sorhus\n@license MIT\n*/\n\n'use strict';\n/* eslint-disable no-unused-vars */\nvar getOwnPropertySymbols = Object.getOwnPropertySymbols;\nvar hasOwnProperty = Object.prototype.hasOwnProperty;\nvar propIsEnumerable = Object.prototype.propertyIsEnumerable;\n\nfunction toObject(val) {\n\tif (val === null || val === undefined) {\n\t\tthrow new TypeError('Object.assign cannot be called with null or undefined');\n\t}\n\n\treturn Object(val);\n}\n\nfunction shouldUseNative() {\n\ttry {\n\t\tif (!Object.assign) {\n\t\t\treturn false;\n\t\t}\n\n\t\t// Detect buggy property enumeration order in older V8 versions.\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=4118\n\t\tvar test1 = new String('abc'); // eslint-disable-line no-new-wrappers\n\t\ttest1[5] = 'de';\n\t\tif (Object.getOwnPropertyNames(test1)[0] === '5') {\n\t\t\treturn false;\n\t\t}\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=3056\n\t\tvar test2 = {};\n\t\tfor (var i = 0; i < 10; i++) {\n\t\t\ttest2['_' + String.fromCharCode(i)] = i;\n\t\t}\n\t\tvar order2 = Object.getOwnPropertyNames(test2).map(function (n) {\n\t\t\treturn test2[n];\n\t\t});\n\t\tif (order2.join('') !== '0123456789') {\n\t\t\treturn false;\n\t\t}\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=3056\n\t\tvar test3 = {};\n\t\t'abcdefghijklmnopqrst'.split('').forEach(function (letter) {\n\t\t\ttest3[letter] = letter;\n\t\t});\n\t\tif (Object.keys(Object.assign({}, test3)).join('') !==\n\t\t\t\t'abcdefghijklmnopqrst') {\n\t\t\treturn false;\n\t\t}\n\n\t\treturn true;\n\t} catch (err) {\n\t\t// We don't expect any of the above to throw, but better to be safe.\n\t\treturn false;\n\t}\n}\n\nmodule.exports = shouldUseNative() ? Object.assign : function (target, source) {\n\tvar from;\n\tvar to = toObject(target);\n\tvar symbols;\n\n\tfor (var s = 1; s < arguments.length; s++) {\n\t\tfrom = Object(arguments[s]);\n\n\t\tfor (var key in from) {\n\t\t\tif (hasOwnProperty.call(from, key)) {\n\t\t\t\tto[key] = from[key];\n\t\t\t}\n\t\t}\n\n\t\tif (getOwnPropertySymbols) {\n\t\t\tsymbols = getOwnPropertySymbols(from);\n\t\t\tfor (var i = 0; i < symbols.length; i++) {\n\t\t\t\tif (propIsEnumerable.call(from, symbols[i])) {\n\t\t\t\t\tto[symbols[i]] = from[symbols[i]];\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\n\treturn to;\n};\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar ReactPropTypesSecret = 'SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED';\n\nmodule.exports = ReactPropTypesSecret;\n","module.exports = Function.call.bind(Object.prototype.hasOwnProperty);\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar printWarning = function() {};\n\nif (process.env.NODE_ENV !== 'production') {\n var ReactPropTypesSecret = require('./lib/ReactPropTypesSecret');\n var loggedTypeFailures = {};\n var has = require('./lib/has');\n\n printWarning = function(text) {\n var message = 'Warning: ' + text;\n if (typeof console !== 'undefined') {\n console.error(message);\n }\n try {\n // --- Welcome to debugging React ---\n // This error was thrown as a convenience so that you can use this stack\n // to find the callsite that caused this warning to fire.\n throw new Error(message);\n } catch (x) { /**/ }\n };\n}\n\n/**\n * Assert that the values match with the type specs.\n * Error messages are memorized and will only be shown once.\n *\n * @param {object} typeSpecs Map of name to a ReactPropType\n * @param {object} values Runtime values that need to be type-checked\n * @param {string} location e.g. \"prop\", \"context\", \"child context\"\n * @param {string} componentName Name of the component for error messages.\n * @param {?Function} getStack Returns the component stack.\n * @private\n */\nfunction checkPropTypes(typeSpecs, values, location, componentName, getStack) {\n if (process.env.NODE_ENV !== 'production') {\n for (var typeSpecName in typeSpecs) {\n if (has(typeSpecs, typeSpecName)) {\n var error;\n // Prop type validation may throw. In case they do, we don't want to\n // fail the render phase where it didn't fail before. So we log it.\n // After these have been cleaned up, we'll let them throw.\n try {\n // This is intentionally an invariant that gets caught. It's the same\n // behavior as without this statement except with a better message.\n if (typeof typeSpecs[typeSpecName] !== 'function') {\n var err = Error(\n (componentName || 'React class') + ': ' + location + ' type `' + typeSpecName + '` is invalid; ' +\n 'it must be a function, usually from the `prop-types` package, but received `' + typeof typeSpecs[typeSpecName] + '`.' +\n 'This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.'\n );\n err.name = 'Invariant Violation';\n throw err;\n }\n error = typeSpecs[typeSpecName](values, typeSpecName, componentName, location, null, ReactPropTypesSecret);\n } catch (ex) {\n error = ex;\n }\n if (error && !(error instanceof Error)) {\n printWarning(\n (componentName || 'React class') + ': type specification of ' +\n location + ' `' + typeSpecName + '` is invalid; the type checker ' +\n 'function must return `null` or an `Error` but returned a ' + typeof error + '. ' +\n 'You may have forgotten to pass an argument to the type checker ' +\n 'creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and ' +\n 'shape all require an argument).'\n );\n }\n if (error instanceof Error && !(error.message in loggedTypeFailures)) {\n // Only monitor this failure once because there tends to be a lot of the\n // same error.\n loggedTypeFailures[error.message] = true;\n\n var stack = getStack ? getStack() : '';\n\n printWarning(\n 'Failed ' + location + ' type: ' + error.message + (stack != null ? stack : '')\n );\n }\n }\n }\n }\n}\n\n/**\n * Resets warning cache when testing.\n *\n * @private\n */\ncheckPropTypes.resetWarningCache = function() {\n if (process.env.NODE_ENV !== 'production') {\n loggedTypeFailures = {};\n }\n}\n\nmodule.exports = checkPropTypes;\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar ReactIs = require('react-is');\nvar assign = require('object-assign');\n\nvar ReactPropTypesSecret = require('./lib/ReactPropTypesSecret');\nvar has = require('./lib/has');\nvar checkPropTypes = require('./checkPropTypes');\n\nvar printWarning = function() {};\n\nif (process.env.NODE_ENV !== 'production') {\n printWarning = function(text) {\n var message = 'Warning: ' + text;\n if (typeof console !== 'undefined') {\n console.error(message);\n }\n try {\n // --- Welcome to debugging React ---\n // This error was thrown as a convenience so that you can use this stack\n // to find the callsite that caused this warning to fire.\n throw new Error(message);\n } catch (x) {}\n };\n}\n\nfunction emptyFunctionThatReturnsNull() {\n return null;\n}\n\nmodule.exports = function(isValidElement, throwOnDirectAccess) {\n /* global Symbol */\n var ITERATOR_SYMBOL = typeof Symbol === 'function' && Symbol.iterator;\n var FAUX_ITERATOR_SYMBOL = '@@iterator'; // Before Symbol spec.\n\n /**\n * Returns the iterator method function contained on the iterable object.\n *\n * Be sure to invoke the function with the iterable as context:\n *\n * var iteratorFn = getIteratorFn(myIterable);\n * if (iteratorFn) {\n * var iterator = iteratorFn.call(myIterable);\n * ...\n * }\n *\n * @param {?object} maybeIterable\n * @return {?function}\n */\n function getIteratorFn(maybeIterable) {\n var iteratorFn = maybeIterable && (ITERATOR_SYMBOL && maybeIterable[ITERATOR_SYMBOL] || maybeIterable[FAUX_ITERATOR_SYMBOL]);\n if (typeof iteratorFn === 'function') {\n return iteratorFn;\n }\n }\n\n /**\n * Collection of methods that allow declaration and validation of props that are\n * supplied to React components. Example usage:\n *\n * var Props = require('ReactPropTypes');\n * var MyArticle = React.createClass({\n * propTypes: {\n * // An optional string prop named \"description\".\n * description: Props.string,\n *\n * // A required enum prop named \"category\".\n * category: Props.oneOf(['News','Photos']).isRequired,\n *\n * // A prop named \"dialog\" that requires an instance of Dialog.\n * dialog: Props.instanceOf(Dialog).isRequired\n * },\n * render: function() { ... }\n * });\n *\n * A more formal specification of how these methods are used:\n *\n * type := array|bool|func|object|number|string|oneOf([...])|instanceOf(...)\n * decl := ReactPropTypes.{type}(.isRequired)?\n *\n * Each and every declaration produces a function with the same signature. This\n * allows the creation of custom validation functions. For example:\n *\n * var MyLink = React.createClass({\n * propTypes: {\n * // An optional string or URI prop named \"href\".\n * href: function(props, propName, componentName) {\n * var propValue = props[propName];\n * if (propValue != null && typeof propValue !== 'string' &&\n * !(propValue instanceof URI)) {\n * return new Error(\n * 'Expected a string or an URI for ' + propName + ' in ' +\n * componentName\n * );\n * }\n * }\n * },\n * render: function() {...}\n * });\n *\n * @internal\n */\n\n var ANONYMOUS = '<>';\n\n // Important!\n // Keep this list in sync with production version in `./factoryWithThrowingShims.js`.\n var ReactPropTypes = {\n array: createPrimitiveTypeChecker('array'),\n bigint: createPrimitiveTypeChecker('bigint'),\n bool: createPrimitiveTypeChecker('boolean'),\n func: createPrimitiveTypeChecker('function'),\n number: createPrimitiveTypeChecker('number'),\n object: createPrimitiveTypeChecker('object'),\n string: createPrimitiveTypeChecker('string'),\n symbol: createPrimitiveTypeChecker('symbol'),\n\n any: createAnyTypeChecker(),\n arrayOf: createArrayOfTypeChecker,\n element: createElementTypeChecker(),\n elementType: createElementTypeTypeChecker(),\n instanceOf: createInstanceTypeChecker,\n node: createNodeChecker(),\n objectOf: createObjectOfTypeChecker,\n oneOf: createEnumTypeChecker,\n oneOfType: createUnionTypeChecker,\n shape: createShapeTypeChecker,\n exact: createStrictShapeTypeChecker,\n };\n\n /**\n * inlined Object.is polyfill to avoid requiring consumers ship their own\n * https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object/is\n */\n /*eslint-disable no-self-compare*/\n function is(x, y) {\n // SameValue algorithm\n if (x === y) {\n // Steps 1-5, 7-10\n // Steps 6.b-6.e: +0 != -0\n return x !== 0 || 1 / x === 1 / y;\n } else {\n // Step 6.a: NaN == NaN\n return x !== x && y !== y;\n }\n }\n /*eslint-enable no-self-compare*/\n\n /**\n * We use an Error-like object for backward compatibility as people may call\n * PropTypes directly and inspect their output. However, we don't use real\n * Errors anymore. We don't inspect their stack anyway, and creating them\n * is prohibitively expensive if they are created too often, such as what\n * happens in oneOfType() for any type before the one that matched.\n */\n function PropTypeError(message, data) {\n this.message = message;\n this.data = data && typeof data === 'object' ? data: {};\n this.stack = '';\n }\n // Make `instanceof Error` still work for returned errors.\n PropTypeError.prototype = Error.prototype;\n\n function createChainableTypeChecker(validate) {\n if (process.env.NODE_ENV !== 'production') {\n var manualPropTypeCallCache = {};\n var manualPropTypeWarningCount = 0;\n }\n function checkType(isRequired, props, propName, componentName, location, propFullName, secret) {\n componentName = componentName || ANONYMOUS;\n propFullName = propFullName || propName;\n\n if (secret !== ReactPropTypesSecret) {\n if (throwOnDirectAccess) {\n // New behavior only for users of `prop-types` package\n var err = new Error(\n 'Calling PropTypes validators directly is not supported by the `prop-types` package. ' +\n 'Use `PropTypes.checkPropTypes()` to call them. ' +\n 'Read more at http://fb.me/use-check-prop-types'\n );\n err.name = 'Invariant Violation';\n throw err;\n } else if (process.env.NODE_ENV !== 'production' && typeof console !== 'undefined') {\n // Old behavior for people using React.PropTypes\n var cacheKey = componentName + ':' + propName;\n if (\n !manualPropTypeCallCache[cacheKey] &&\n // Avoid spamming the console because they are often not actionable except for lib authors\n manualPropTypeWarningCount < 3\n ) {\n printWarning(\n 'You are manually calling a React.PropTypes validation ' +\n 'function for the `' + propFullName + '` prop on `' + componentName + '`. This is deprecated ' +\n 'and will throw in the standalone `prop-types` package. ' +\n 'You may be seeing this warning due to a third-party PropTypes ' +\n 'library. See https://fb.me/react-warning-dont-call-proptypes ' + 'for details.'\n );\n manualPropTypeCallCache[cacheKey] = true;\n manualPropTypeWarningCount++;\n }\n }\n }\n if (props[propName] == null) {\n if (isRequired) {\n if (props[propName] === null) {\n return new PropTypeError('The ' + location + ' `' + propFullName + '` is marked as required ' + ('in `' + componentName + '`, but its value is `null`.'));\n }\n return new PropTypeError('The ' + location + ' `' + propFullName + '` is marked as required in ' + ('`' + componentName + '`, but its value is `undefined`.'));\n }\n return null;\n } else {\n return validate(props, propName, componentName, location, propFullName);\n }\n }\n\n var chainedCheckType = checkType.bind(null, false);\n chainedCheckType.isRequired = checkType.bind(null, true);\n\n return chainedCheckType;\n }\n\n function createPrimitiveTypeChecker(expectedType) {\n function validate(props, propName, componentName, location, propFullName, secret) {\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== expectedType) {\n // `propValue` being instance of, say, date/regexp, pass the 'object'\n // check, but we can offer a more precise error message here rather than\n // 'of type `object`'.\n var preciseType = getPreciseType(propValue);\n\n return new PropTypeError(\n 'Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + preciseType + '` supplied to `' + componentName + '`, expected ') + ('`' + expectedType + '`.'),\n {expectedType: expectedType}\n );\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createAnyTypeChecker() {\n return createChainableTypeChecker(emptyFunctionThatReturnsNull);\n }\n\n function createArrayOfTypeChecker(typeChecker) {\n function validate(props, propName, componentName, location, propFullName) {\n if (typeof typeChecker !== 'function') {\n return new PropTypeError('Property `' + propFullName + '` of component `' + componentName + '` has invalid PropType notation inside arrayOf.');\n }\n var propValue = props[propName];\n if (!Array.isArray(propValue)) {\n var propType = getPropType(propValue);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected an array.'));\n }\n for (var i = 0; i < propValue.length; i++) {\n var error = typeChecker(propValue, i, componentName, location, propFullName + '[' + i + ']', ReactPropTypesSecret);\n if (error instanceof Error) {\n return error;\n }\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createElementTypeChecker() {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n if (!isValidElement(propValue)) {\n var propType = getPropType(propValue);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected a single ReactElement.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createElementTypeTypeChecker() {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n if (!ReactIs.isValidElementType(propValue)) {\n var propType = getPropType(propValue);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected a single ReactElement type.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createInstanceTypeChecker(expectedClass) {\n function validate(props, propName, componentName, location, propFullName) {\n if (!(props[propName] instanceof expectedClass)) {\n var expectedClassName = expectedClass.name || ANONYMOUS;\n var actualClassName = getClassName(props[propName]);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + actualClassName + '` supplied to `' + componentName + '`, expected ') + ('instance of `' + expectedClassName + '`.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createEnumTypeChecker(expectedValues) {\n if (!Array.isArray(expectedValues)) {\n if (process.env.NODE_ENV !== 'production') {\n if (arguments.length > 1) {\n printWarning(\n 'Invalid arguments supplied to oneOf, expected an array, got ' + arguments.length + ' arguments. ' +\n 'A common mistake is to write oneOf(x, y, z) instead of oneOf([x, y, z]).'\n );\n } else {\n printWarning('Invalid argument supplied to oneOf, expected an array.');\n }\n }\n return emptyFunctionThatReturnsNull;\n }\n\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n for (var i = 0; i < expectedValues.length; i++) {\n if (is(propValue, expectedValues[i])) {\n return null;\n }\n }\n\n var valuesString = JSON.stringify(expectedValues, function replacer(key, value) {\n var type = getPreciseType(value);\n if (type === 'symbol') {\n return String(value);\n }\n return value;\n });\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of value `' + String(propValue) + '` ' + ('supplied to `' + componentName + '`, expected one of ' + valuesString + '.'));\n }\n return createChainableTypeChecker(validate);\n }\n\n function createObjectOfTypeChecker(typeChecker) {\n function validate(props, propName, componentName, location, propFullName) {\n if (typeof typeChecker !== 'function') {\n return new PropTypeError('Property `' + propFullName + '` of component `' + componentName + '` has invalid PropType notation inside objectOf.');\n }\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== 'object') {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected an object.'));\n }\n for (var key in propValue) {\n if (has(propValue, key)) {\n var error = typeChecker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret);\n if (error instanceof Error) {\n return error;\n }\n }\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createUnionTypeChecker(arrayOfTypeCheckers) {\n if (!Array.isArray(arrayOfTypeCheckers)) {\n process.env.NODE_ENV !== 'production' ? printWarning('Invalid argument supplied to oneOfType, expected an instance of array.') : void 0;\n return emptyFunctionThatReturnsNull;\n }\n\n for (var i = 0; i < arrayOfTypeCheckers.length; i++) {\n var checker = arrayOfTypeCheckers[i];\n if (typeof checker !== 'function') {\n printWarning(\n 'Invalid argument supplied to oneOfType. Expected an array of check functions, but ' +\n 'received ' + getPostfixForTypeWarning(checker) + ' at index ' + i + '.'\n );\n return emptyFunctionThatReturnsNull;\n }\n }\n\n function validate(props, propName, componentName, location, propFullName) {\n var expectedTypes = [];\n for (var i = 0; i < arrayOfTypeCheckers.length; i++) {\n var checker = arrayOfTypeCheckers[i];\n var checkerResult = checker(props, propName, componentName, location, propFullName, ReactPropTypesSecret);\n if (checkerResult == null) {\n return null;\n }\n if (checkerResult.data && has(checkerResult.data, 'expectedType')) {\n expectedTypes.push(checkerResult.data.expectedType);\n }\n }\n var expectedTypesMessage = (expectedTypes.length > 0) ? ', expected one of type [' + expectedTypes.join(', ') + ']': '';\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` supplied to ' + ('`' + componentName + '`' + expectedTypesMessage + '.'));\n }\n return createChainableTypeChecker(validate);\n }\n\n function createNodeChecker() {\n function validate(props, propName, componentName, location, propFullName) {\n if (!isNode(props[propName])) {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` supplied to ' + ('`' + componentName + '`, expected a ReactNode.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function invalidValidatorError(componentName, location, propFullName, key, type) {\n return new PropTypeError(\n (componentName || 'React class') + ': ' + location + ' type `' + propFullName + '.' + key + '` is invalid; ' +\n 'it must be a function, usually from the `prop-types` package, but received `' + type + '`.'\n );\n }\n\n function createShapeTypeChecker(shapeTypes) {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== 'object') {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type `' + propType + '` ' + ('supplied to `' + componentName + '`, expected `object`.'));\n }\n for (var key in shapeTypes) {\n var checker = shapeTypes[key];\n if (typeof checker !== 'function') {\n return invalidValidatorError(componentName, location, propFullName, key, getPreciseType(checker));\n }\n var error = checker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret);\n if (error) {\n return error;\n }\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createStrictShapeTypeChecker(shapeTypes) {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== 'object') {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type `' + propType + '` ' + ('supplied to `' + componentName + '`, expected `object`.'));\n }\n // We need to check all keys in case some are required but missing from props.\n var allKeys = assign({}, props[propName], shapeTypes);\n for (var key in allKeys) {\n var checker = shapeTypes[key];\n if (has(shapeTypes, key) && typeof checker !== 'function') {\n return invalidValidatorError(componentName, location, propFullName, key, getPreciseType(checker));\n }\n if (!checker) {\n return new PropTypeError(\n 'Invalid ' + location + ' `' + propFullName + '` key `' + key + '` supplied to `' + componentName + '`.' +\n '\\nBad object: ' + JSON.stringify(props[propName], null, ' ') +\n '\\nValid keys: ' + JSON.stringify(Object.keys(shapeTypes), null, ' ')\n );\n }\n var error = checker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret);\n if (error) {\n return error;\n }\n }\n return null;\n }\n\n return createChainableTypeChecker(validate);\n }\n\n function isNode(propValue) {\n switch (typeof propValue) {\n case 'number':\n case 'string':\n case 'undefined':\n return true;\n case 'boolean':\n return !propValue;\n case 'object':\n if (Array.isArray(propValue)) {\n return propValue.every(isNode);\n }\n if (propValue === null || isValidElement(propValue)) {\n return true;\n }\n\n var iteratorFn = getIteratorFn(propValue);\n if (iteratorFn) {\n var iterator = iteratorFn.call(propValue);\n var step;\n if (iteratorFn !== propValue.entries) {\n while (!(step = iterator.next()).done) {\n if (!isNode(step.value)) {\n return false;\n }\n }\n } else {\n // Iterator will provide entry [k,v] tuples rather than values.\n while (!(step = iterator.next()).done) {\n var entry = step.value;\n if (entry) {\n if (!isNode(entry[1])) {\n return false;\n }\n }\n }\n }\n } else {\n return false;\n }\n\n return true;\n default:\n return false;\n }\n }\n\n function isSymbol(propType, propValue) {\n // Native Symbol.\n if (propType === 'symbol') {\n return true;\n }\n\n // falsy value can't be a Symbol\n if (!propValue) {\n return false;\n }\n\n // 19.4.3.5 Symbol.prototype[@@toStringTag] === 'Symbol'\n if (propValue['@@toStringTag'] === 'Symbol') {\n return true;\n }\n\n // Fallback for non-spec compliant Symbols which are polyfilled.\n if (typeof Symbol === 'function' && propValue instanceof Symbol) {\n return true;\n }\n\n return false;\n }\n\n // Equivalent of `typeof` but with special handling for array and regexp.\n function getPropType(propValue) {\n var propType = typeof propValue;\n if (Array.isArray(propValue)) {\n return 'array';\n }\n if (propValue instanceof RegExp) {\n // Old webkits (at least until Android 4.0) return 'function' rather than\n // 'object' for typeof a RegExp. We'll normalize this here so that /bla/\n // passes PropTypes.object.\n return 'object';\n }\n if (isSymbol(propType, propValue)) {\n return 'symbol';\n }\n return propType;\n }\n\n // This handles more types than `getPropType`. Only used for error messages.\n // See `createPrimitiveTypeChecker`.\n function getPreciseType(propValue) {\n if (typeof propValue === 'undefined' || propValue === null) {\n return '' + propValue;\n }\n var propType = getPropType(propValue);\n if (propType === 'object') {\n if (propValue instanceof Date) {\n return 'date';\n } else if (propValue instanceof RegExp) {\n return 'regexp';\n }\n }\n return propType;\n }\n\n // Returns a string that is postfixed to a warning about an invalid type.\n // For example, \"undefined\" or \"of type array\"\n function getPostfixForTypeWarning(value) {\n var type = getPreciseType(value);\n switch (type) {\n case 'array':\n case 'object':\n return 'an ' + type;\n case 'boolean':\n case 'date':\n case 'regexp':\n return 'a ' + type;\n default:\n return type;\n }\n }\n\n // Returns class name of the object, if any.\n function getClassName(propValue) {\n if (!propValue.constructor || !propValue.constructor.name) {\n return ANONYMOUS;\n }\n return propValue.constructor.name;\n }\n\n ReactPropTypes.checkPropTypes = checkPropTypes;\n ReactPropTypes.resetWarningCache = checkPropTypes.resetWarningCache;\n ReactPropTypes.PropTypes = ReactPropTypes;\n\n return ReactPropTypes;\n};\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar ReactPropTypesSecret = require('./lib/ReactPropTypesSecret');\n\nfunction emptyFunction() {}\nfunction emptyFunctionWithReset() {}\nemptyFunctionWithReset.resetWarningCache = emptyFunction;\n\nmodule.exports = function() {\n function shim(props, propName, componentName, location, propFullName, secret) {\n if (secret === ReactPropTypesSecret) {\n // It is still safe when called from React.\n return;\n }\n var err = new Error(\n 'Calling PropTypes validators directly is not supported by the `prop-types` package. ' +\n 'Use PropTypes.checkPropTypes() to call them. ' +\n 'Read more at http://fb.me/use-check-prop-types'\n );\n err.name = 'Invariant Violation';\n throw err;\n };\n shim.isRequired = shim;\n function getShim() {\n return shim;\n };\n // Important!\n // Keep this list in sync with production version in `./factoryWithTypeCheckers.js`.\n var ReactPropTypes = {\n array: shim,\n bigint: shim,\n bool: shim,\n func: shim,\n number: shim,\n object: shim,\n string: shim,\n symbol: shim,\n\n any: shim,\n arrayOf: getShim,\n element: shim,\n elementType: shim,\n instanceOf: getShim,\n node: shim,\n objectOf: getShim,\n oneOf: getShim,\n oneOfType: getShim,\n shape: getShim,\n exact: getShim,\n\n checkPropTypes: emptyFunctionWithReset,\n resetWarningCache: emptyFunction\n };\n\n ReactPropTypes.PropTypes = ReactPropTypes;\n\n return ReactPropTypes;\n};\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\nif (process.env.NODE_ENV !== 'production') {\n var ReactIs = require('react-is');\n\n // By explicitly using `prop-types` you are opting into new development behavior.\n // http://fb.me/prop-types-in-prod\n var throwOnDirectAccess = true;\n module.exports = require('./factoryWithTypeCheckers')(ReactIs.isElement, throwOnDirectAccess);\n} else {\n // By explicitly using `prop-types` you are opting into new production behavior.\n // http://fb.me/prop-types-in-prod\n module.exports = require('./factoryWithThrowingShims')();\n}\n","import PropTypes from 'prop-types';\nimport chainPropTypes from '../chainPropTypes';\nfunction isClassComponent(elementType) {\n // elementType.prototype?.isReactComponent\n const {\n prototype = {}\n } = elementType;\n return Boolean(prototype.isReactComponent);\n}\nfunction acceptingRef(props, propName, componentName, location, propFullName) {\n const element = props[propName];\n const safePropName = propFullName || propName;\n if (element == null ||\n // When server-side rendering React doesn't warn either.\n // This is not an accurate check for SSR.\n // This is only in place for Emotion compat.\n // TODO: Revisit once https://github.com/facebook/react/issues/20047 is resolved.\n typeof window === 'undefined') {\n return null;\n }\n let warningHint;\n const elementType = element.type;\n /**\n * Blacklisting instead of whitelisting\n *\n * Blacklisting will miss some components, such as React.Fragment. Those will at least\n * trigger a warning in React.\n * We can't whitelist because there is no safe way to detect React.forwardRef\n * or class components. \"Safe\" means there's no public API.\n *\n */\n if (typeof elementType === 'function' && !isClassComponent(elementType)) {\n warningHint = 'Did you accidentally use a plain function component for an element instead?';\n }\n if (warningHint !== undefined) {\n return new Error(`Invalid ${location} \\`${safePropName}\\` supplied to \\`${componentName}\\`. ` + `Expected an element that can hold a ref. ${warningHint} ` + 'For more information see https://mui.com/r/caveat-with-refs-guide');\n }\n return null;\n}\nconst elementAcceptingRef = chainPropTypes(PropTypes.element, acceptingRef);\nelementAcceptingRef.isRequired = chainPropTypes(PropTypes.element.isRequired, acceptingRef);\nexport default elementAcceptingRef;","import _extends from \"@babel/runtime/helpers/esm/extends\";\n// This module is based on https://github.com/airbnb/prop-types-exact repository.\n// However, in order to reduce the number of dependencies and to remove some extra safe checks\n// the module was forked.\n\nconst specialProperty = 'exact-prop: \\u200b';\nexport default function exactProp(propTypes) {\n if (process.env.NODE_ENV === 'production') {\n return propTypes;\n }\n return _extends({}, propTypes, {\n [specialProperty]: props => {\n const unsupportedProps = Object.keys(props).filter(prop => !propTypes.hasOwnProperty(prop));\n if (unsupportedProps.length > 0) {\n return new Error(`The following props are not supported: ${unsupportedProps.map(prop => `\\`${prop}\\``).join(', ')}. Please remove them.`);\n }\n return null;\n }\n });\n}","/**\n * WARNING: Don't import this directly.\n * Use `MuiError` from `@mui/internal-babel-macros/MuiError.macro` instead.\n * @param {number} code\n */\nexport default function formatMuiErrorMessage(code) {\n // Apply babel-plugin-transform-template-literals in loose mode\n // loose mode is safe if we're concatenating primitives\n // see https://babeljs.io/docs/en/babel-plugin-transform-template-literals#loose\n /* eslint-disable prefer-template */\n let url = 'https://mui.com/production-error/?code=' + code;\n for (let i = 1; i < arguments.length; i += 1) {\n // rest params over-transpile for this case\n // eslint-disable-next-line prefer-rest-params\n url += '&args[]=' + encodeURIComponent(arguments[i]);\n }\n return 'Minified MUI error #' + code + '; visit ' + url + ' for the full message.';\n /* eslint-enable prefer-template */\n}","/**\n * @license React\n * react-is.production.min.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n'use strict';var b=Symbol.for(\"react.element\"),c=Symbol.for(\"react.portal\"),d=Symbol.for(\"react.fragment\"),e=Symbol.for(\"react.strict_mode\"),f=Symbol.for(\"react.profiler\"),g=Symbol.for(\"react.provider\"),h=Symbol.for(\"react.context\"),k=Symbol.for(\"react.server_context\"),l=Symbol.for(\"react.forward_ref\"),m=Symbol.for(\"react.suspense\"),n=Symbol.for(\"react.suspense_list\"),p=Symbol.for(\"react.memo\"),q=Symbol.for(\"react.lazy\"),t=Symbol.for(\"react.offscreen\"),u;u=Symbol.for(\"react.module.reference\");\nfunction v(a){if(\"object\"===typeof a&&null!==a){var r=a.$$typeof;switch(r){case b:switch(a=a.type,a){case d:case f:case e:case m:case n:return a;default:switch(a=a&&a.$$typeof,a){case k:case h:case l:case q:case p:case g:return a;default:return r}}case c:return r}}}exports.ContextConsumer=h;exports.ContextProvider=g;exports.Element=b;exports.ForwardRef=l;exports.Fragment=d;exports.Lazy=q;exports.Memo=p;exports.Portal=c;exports.Profiler=f;exports.StrictMode=e;exports.Suspense=m;\nexports.SuspenseList=n;exports.isAsyncMode=function(){return!1};exports.isConcurrentMode=function(){return!1};exports.isContextConsumer=function(a){return v(a)===h};exports.isContextProvider=function(a){return v(a)===g};exports.isElement=function(a){return\"object\"===typeof a&&null!==a&&a.$$typeof===b};exports.isForwardRef=function(a){return v(a)===l};exports.isFragment=function(a){return v(a)===d};exports.isLazy=function(a){return v(a)===q};exports.isMemo=function(a){return v(a)===p};\nexports.isPortal=function(a){return v(a)===c};exports.isProfiler=function(a){return v(a)===f};exports.isStrictMode=function(a){return v(a)===e};exports.isSuspense=function(a){return v(a)===m};exports.isSuspenseList=function(a){return v(a)===n};\nexports.isValidElementType=function(a){return\"string\"===typeof a||\"function\"===typeof a||a===d||a===f||a===e||a===m||a===n||a===t||\"object\"===typeof a&&null!==a&&(a.$$typeof===q||a.$$typeof===p||a.$$typeof===g||a.$$typeof===h||a.$$typeof===l||a.$$typeof===u||void 0!==a.getModuleId)?!0:!1};exports.typeOf=v;\n","/**\n * @license React\n * react-is.development.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nif (process.env.NODE_ENV !== \"production\") {\n (function() {\n'use strict';\n\n// ATTENTION\n// When adding new symbols to this file,\n// Please consider also adding to 'react-devtools-shared/src/backend/ReactSymbols'\n// The Symbol used to tag the ReactElement-like types.\nvar REACT_ELEMENT_TYPE = Symbol.for('react.element');\nvar REACT_PORTAL_TYPE = Symbol.for('react.portal');\nvar REACT_FRAGMENT_TYPE = Symbol.for('react.fragment');\nvar REACT_STRICT_MODE_TYPE = Symbol.for('react.strict_mode');\nvar REACT_PROFILER_TYPE = Symbol.for('react.profiler');\nvar REACT_PROVIDER_TYPE = Symbol.for('react.provider');\nvar REACT_CONTEXT_TYPE = Symbol.for('react.context');\nvar REACT_SERVER_CONTEXT_TYPE = Symbol.for('react.server_context');\nvar REACT_FORWARD_REF_TYPE = Symbol.for('react.forward_ref');\nvar REACT_SUSPENSE_TYPE = Symbol.for('react.suspense');\nvar REACT_SUSPENSE_LIST_TYPE = Symbol.for('react.suspense_list');\nvar REACT_MEMO_TYPE = Symbol.for('react.memo');\nvar REACT_LAZY_TYPE = Symbol.for('react.lazy');\nvar REACT_OFFSCREEN_TYPE = Symbol.for('react.offscreen');\n\n// -----------------------------------------------------------------------------\n\nvar enableScopeAPI = false; // Experimental Create Event Handle API.\nvar enableCacheElement = false;\nvar enableTransitionTracing = false; // No known bugs, but needs performance testing\n\nvar enableLegacyHidden = false; // Enables unstable_avoidThisFallback feature in Fiber\n// stuff. Intended to enable React core members to more easily debug scheduling\n// issues in DEV builds.\n\nvar enableDebugTracing = false; // Track which Fiber(s) schedule render work.\n\nvar REACT_MODULE_REFERENCE;\n\n{\n REACT_MODULE_REFERENCE = Symbol.for('react.module.reference');\n}\n\nfunction isValidElementType(type) {\n if (typeof type === 'string' || typeof type === 'function') {\n return true;\n } // Note: typeof might be other than 'symbol' or 'number' (e.g. if it's a polyfill).\n\n\n if (type === REACT_FRAGMENT_TYPE || type === REACT_PROFILER_TYPE || enableDebugTracing || type === REACT_STRICT_MODE_TYPE || type === REACT_SUSPENSE_TYPE || type === REACT_SUSPENSE_LIST_TYPE || enableLegacyHidden || type === REACT_OFFSCREEN_TYPE || enableScopeAPI || enableCacheElement || enableTransitionTracing ) {\n return true;\n }\n\n if (typeof type === 'object' && type !== null) {\n if (type.$$typeof === REACT_LAZY_TYPE || type.$$typeof === REACT_MEMO_TYPE || type.$$typeof === REACT_PROVIDER_TYPE || type.$$typeof === REACT_CONTEXT_TYPE || type.$$typeof === REACT_FORWARD_REF_TYPE || // This needs to include all possible module reference object\n // types supported by any Flight configuration anywhere since\n // we don't know which Flight build this will end up being used\n // with.\n type.$$typeof === REACT_MODULE_REFERENCE || type.getModuleId !== undefined) {\n return true;\n }\n }\n\n return false;\n}\n\nfunction typeOf(object) {\n if (typeof object === 'object' && object !== null) {\n var $$typeof = object.$$typeof;\n\n switch ($$typeof) {\n case REACT_ELEMENT_TYPE:\n var type = object.type;\n\n switch (type) {\n case REACT_FRAGMENT_TYPE:\n case REACT_PROFILER_TYPE:\n case REACT_STRICT_MODE_TYPE:\n case REACT_SUSPENSE_TYPE:\n case REACT_SUSPENSE_LIST_TYPE:\n return type;\n\n default:\n var $$typeofType = type && type.$$typeof;\n\n switch ($$typeofType) {\n case REACT_SERVER_CONTEXT_TYPE:\n case REACT_CONTEXT_TYPE:\n case REACT_FORWARD_REF_TYPE:\n case REACT_LAZY_TYPE:\n case REACT_MEMO_TYPE:\n case REACT_PROVIDER_TYPE:\n return $$typeofType;\n\n default:\n return $$typeof;\n }\n\n }\n\n case REACT_PORTAL_TYPE:\n return $$typeof;\n }\n }\n\n return undefined;\n}\nvar ContextConsumer = REACT_CONTEXT_TYPE;\nvar ContextProvider = REACT_PROVIDER_TYPE;\nvar Element = REACT_ELEMENT_TYPE;\nvar ForwardRef = REACT_FORWARD_REF_TYPE;\nvar Fragment = REACT_FRAGMENT_TYPE;\nvar Lazy = REACT_LAZY_TYPE;\nvar Memo = REACT_MEMO_TYPE;\nvar Portal = REACT_PORTAL_TYPE;\nvar Profiler = REACT_PROFILER_TYPE;\nvar StrictMode = REACT_STRICT_MODE_TYPE;\nvar Suspense = REACT_SUSPENSE_TYPE;\nvar SuspenseList = REACT_SUSPENSE_LIST_TYPE;\nvar hasWarnedAboutDeprecatedIsAsyncMode = false;\nvar hasWarnedAboutDeprecatedIsConcurrentMode = false; // AsyncMode should be deprecated\n\nfunction isAsyncMode(object) {\n {\n if (!hasWarnedAboutDeprecatedIsAsyncMode) {\n hasWarnedAboutDeprecatedIsAsyncMode = true; // Using console['warn'] to evade Babel and ESLint\n\n console['warn']('The ReactIs.isAsyncMode() alias has been deprecated, ' + 'and will be removed in React 18+.');\n }\n }\n\n return false;\n}\nfunction isConcurrentMode(object) {\n {\n if (!hasWarnedAboutDeprecatedIsConcurrentMode) {\n hasWarnedAboutDeprecatedIsConcurrentMode = true; // Using console['warn'] to evade Babel and ESLint\n\n console['warn']('The ReactIs.isConcurrentMode() alias has been deprecated, ' + 'and will be removed in React 18+.');\n }\n }\n\n return false;\n}\nfunction isContextConsumer(object) {\n return typeOf(object) === REACT_CONTEXT_TYPE;\n}\nfunction isContextProvider(object) {\n return typeOf(object) === REACT_PROVIDER_TYPE;\n}\nfunction isElement(object) {\n return typeof object === 'object' && object !== null && object.$$typeof === REACT_ELEMENT_TYPE;\n}\nfunction isForwardRef(object) {\n return typeOf(object) === REACT_FORWARD_REF_TYPE;\n}\nfunction isFragment(object) {\n return typeOf(object) === REACT_FRAGMENT_TYPE;\n}\nfunction isLazy(object) {\n return typeOf(object) === REACT_LAZY_TYPE;\n}\nfunction isMemo(object) {\n return typeOf(object) === REACT_MEMO_TYPE;\n}\nfunction isPortal(object) {\n return typeOf(object) === REACT_PORTAL_TYPE;\n}\nfunction isProfiler(object) {\n return typeOf(object) === REACT_PROFILER_TYPE;\n}\nfunction isStrictMode(object) {\n return typeOf(object) === REACT_STRICT_MODE_TYPE;\n}\nfunction isSuspense(object) {\n return typeOf(object) === REACT_SUSPENSE_TYPE;\n}\nfunction isSuspenseList(object) {\n return typeOf(object) === REACT_SUSPENSE_LIST_TYPE;\n}\n\nexports.ContextConsumer = ContextConsumer;\nexports.ContextProvider = ContextProvider;\nexports.Element = Element;\nexports.ForwardRef = ForwardRef;\nexports.Fragment = Fragment;\nexports.Lazy = Lazy;\nexports.Memo = Memo;\nexports.Portal = Portal;\nexports.Profiler = Profiler;\nexports.StrictMode = StrictMode;\nexports.Suspense = Suspense;\nexports.SuspenseList = SuspenseList;\nexports.isAsyncMode = isAsyncMode;\nexports.isConcurrentMode = isConcurrentMode;\nexports.isContextConsumer = isContextConsumer;\nexports.isContextProvider = isContextProvider;\nexports.isElement = isElement;\nexports.isForwardRef = isForwardRef;\nexports.isFragment = isFragment;\nexports.isLazy = isLazy;\nexports.isMemo = isMemo;\nexports.isPortal = isPortal;\nexports.isProfiler = isProfiler;\nexports.isStrictMode = isStrictMode;\nexports.isSuspense = isSuspense;\nexports.isSuspenseList = isSuspenseList;\nexports.isValidElementType = isValidElementType;\nexports.typeOf = typeOf;\n })();\n}\n","'use strict';\n\nif (process.env.NODE_ENV === 'production') {\n module.exports = require('./cjs/react-is.production.min.js');\n} else {\n module.exports = require('./cjs/react-is.development.js');\n}\n","import { ForwardRef, Memo } from 'react-is';\n\n// Simplified polyfill for IE11 support\n// https://github.com/JamesMGreene/Function.name/blob/58b314d4a983110c3682f1228f845d39ccca1817/Function.name.js#L3\nconst fnNameMatchRegex = /^\\s*function(?:\\s|\\s*\\/\\*.*\\*\\/\\s*)+([^(\\s/]*)\\s*/;\nexport function getFunctionName(fn) {\n const match = `${fn}`.match(fnNameMatchRegex);\n const name = match && match[1];\n return name || '';\n}\nfunction getFunctionComponentName(Component, fallback = '') {\n return Component.displayName || Component.name || getFunctionName(Component) || fallback;\n}\nfunction getWrappedName(outerType, innerType, wrapperName) {\n const functionName = getFunctionComponentName(innerType);\n return outerType.displayName || (functionName !== '' ? `${wrapperName}(${functionName})` : wrapperName);\n}\n\n/**\n * cherry-pick from\n * https://github.com/facebook/react/blob/769b1f270e1251d9dbdce0fcbd9e92e502d059b8/packages/shared/getComponentName.js\n * originally forked from recompose/getDisplayName with added IE11 support\n */\nexport default function getDisplayName(Component) {\n if (Component == null) {\n return undefined;\n }\n if (typeof Component === 'string') {\n return Component;\n }\n if (typeof Component === 'function') {\n return getFunctionComponentName(Component, 'Component');\n }\n\n // TypeScript can't have components as objects but they exist in the form of `memo` or `Suspense`\n if (typeof Component === 'object') {\n switch (Component.$$typeof) {\n case ForwardRef:\n return getWrappedName(Component, Component.render, 'ForwardRef');\n case Memo:\n return getWrappedName(Component, Component.type, 'memo');\n default:\n return undefined;\n }\n }\n return undefined;\n}","export default function HTMLElementType(props, propName, componentName, location, propFullName) {\n if (process.env.NODE_ENV === 'production') {\n return null;\n }\n const propValue = props[propName];\n const safePropName = propFullName || propName;\n if (propValue == null) {\n return null;\n }\n if (propValue && propValue.nodeType !== 1) {\n return new Error(`Invalid ${location} \\`${safePropName}\\` supplied to \\`${componentName}\\`. ` + `Expected an HTMLElement.`);\n }\n return null;\n}","import PropTypes from 'prop-types';\nconst refType = PropTypes.oneOfType([PropTypes.func, PropTypes.object]);\nexport default refType;","import _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\n// It should to be noted that this function isn't equivalent to `text-transform: capitalize`.\n//\n// A strict capitalization should uppercase the first letter of each word in the sentence.\n// We only handle the first word.\nexport default function capitalize(string) {\n if (typeof string !== 'string') {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: \\`capitalize(string)\\` expects a string argument.` : _formatMuiErrorMessage(7));\n }\n return string.charAt(0).toUpperCase() + string.slice(1);\n}","/**\n * Safe chained function.\n *\n * Will only create a new function if needed,\n * otherwise will pass back existing functions or null.\n */\nexport default function createChainedFunction(...funcs) {\n return funcs.reduce((acc, func) => {\n if (func == null) {\n return acc;\n }\n return function chainedFunction(...args) {\n acc.apply(this, args);\n func.apply(this, args);\n };\n }, () => {});\n}","// Corresponds to 10 frames at 60 Hz.\n// A few bytes payload overhead when lodash/debounce is ~3 kB and debounce ~300 B.\nexport default function debounce(func, wait = 166) {\n let timeout;\n function debounced(...args) {\n const later = () => {\n // @ts-ignore\n func.apply(this, args);\n };\n clearTimeout(timeout);\n timeout = setTimeout(later, wait);\n }\n debounced.clear = () => {\n clearTimeout(timeout);\n };\n return debounced;\n}","export default function deprecatedPropType(validator, reason) {\n if (process.env.NODE_ENV === 'production') {\n return () => null;\n }\n return (props, propName, componentName, location, propFullName) => {\n const componentNameSafe = componentName || '<>';\n const propFullNameSafe = propFullName || propName;\n if (typeof props[propName] !== 'undefined') {\n return new Error(`The ${location} \\`${propFullNameSafe}\\` of ` + `\\`${componentNameSafe}\\` is deprecated. ${reason}`);\n }\n return null;\n };\n}","import * as React from 'react';\nexport default function isMuiElement(element, muiNames) {\n var _muiName, _element$type;\n return /*#__PURE__*/React.isValidElement(element) && muiNames.indexOf( // For server components `muiName` is avaialble in element.type._payload.value.muiName\n // relevant info - https://github.com/facebook/react/blob/2807d781a08db8e9873687fccc25c0f12b4fb3d4/packages/react/src/ReactLazy.js#L45\n // eslint-disable-next-line no-underscore-dangle\n (_muiName = element.type.muiName) != null ? _muiName : (_element$type = element.type) == null || (_element$type = _element$type._payload) == null || (_element$type = _element$type.value) == null ? void 0 : _element$type.muiName) !== -1;\n}","export default function ownerDocument(node) {\n return node && node.ownerDocument || document;\n}","import ownerDocument from '../ownerDocument';\nexport default function ownerWindow(node) {\n const doc = ownerDocument(node);\n return doc.defaultView || window;\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nexport default function requirePropFactory(componentNameInError, Component) {\n if (process.env.NODE_ENV === 'production') {\n return () => null;\n }\n\n // eslint-disable-next-line react/forbid-foreign-prop-types\n const prevPropTypes = Component ? _extends({}, Component.propTypes) : null;\n const requireProp = requiredProp => (props, propName, componentName, location, propFullName, ...args) => {\n const propFullNameSafe = propFullName || propName;\n const defaultTypeChecker = prevPropTypes == null ? void 0 : prevPropTypes[propFullNameSafe];\n if (defaultTypeChecker) {\n const typeCheckerResult = defaultTypeChecker(props, propName, componentName, location, propFullName, ...args);\n if (typeCheckerResult) {\n return typeCheckerResult;\n }\n }\n if (typeof props[propName] !== 'undefined' && !props[requiredProp]) {\n return new Error(`The prop \\`${propFullNameSafe}\\` of ` + `\\`${componentNameInError}\\` can only be used together with the \\`${requiredProp}\\` prop.`);\n }\n return null;\n };\n return requireProp;\n}","/**\n * TODO v5: consider making it private\n *\n * passes {value} to {ref}\n *\n * WARNING: Be sure to only call this inside a callback that is passed as a ref.\n * Otherwise, make sure to cleanup the previous {ref} if it changes. See\n * https://github.com/mui/material-ui/issues/13539\n *\n * Useful if you want to expose the ref of an inner component to the public API\n * while still using it inside the component.\n * @param ref A ref callback or ref object. If anything falsy, this is a no-op.\n */\nexport default function setRef(ref, value) {\n if (typeof ref === 'function') {\n ref(value);\n } else if (ref) {\n ref.current = value;\n }\n}","'use client';\n\nimport * as React from 'react';\n\n/**\n * A version of `React.useLayoutEffect` that does not show a warning when server-side rendering.\n * This is useful for effects that are only needed for client-side rendering but not for SSR.\n *\n * Before you use this hook, make sure to read https://gist.github.com/gaearon/e7d97cdf38a2907924ea12e4ebdf3c85\n * and confirm it doesn't apply to your use-case.\n */\nconst useEnhancedEffect = typeof window !== 'undefined' ? React.useLayoutEffect : React.useEffect;\nexport default useEnhancedEffect;","'use client';\n\nimport * as React from 'react';\nlet globalId = 0;\nfunction useGlobalId(idOverride) {\n const [defaultId, setDefaultId] = React.useState(idOverride);\n const id = idOverride || defaultId;\n React.useEffect(() => {\n if (defaultId == null) {\n // Fallback to this default id when possible.\n // Use the incrementing value for client-side rendering only.\n // We can't use it server-side.\n // If you want to use random values please consider the Birthday Problem: https://en.wikipedia.org/wiki/Birthday_problem\n globalId += 1;\n setDefaultId(`mui-${globalId}`);\n }\n }, [defaultId]);\n return id;\n}\n\n// downstream bundlers may remove unnecessary concatenation, but won't remove toString call -- Workaround for https://github.com/webpack/webpack/issues/14814\nconst maybeReactUseId = React['useId'.toString()];\n/**\n *\n * @example
    \n * @param idOverride\n * @returns {string}\n */\nexport default function useId(idOverride) {\n if (maybeReactUseId !== undefined) {\n const reactId = maybeReactUseId();\n return idOverride != null ? idOverride : reactId;\n }\n // eslint-disable-next-line react-hooks/rules-of-hooks -- `React.useId` is invariant at runtime.\n return useGlobalId(idOverride);\n}","export default function unsupportedProp(props, propName, componentName, location, propFullName) {\n if (process.env.NODE_ENV === 'production') {\n return null;\n }\n const propFullNameSafe = propFullName || propName;\n if (typeof props[propName] !== 'undefined') {\n return new Error(`The prop \\`${propFullNameSafe}\\` is not supported. Please remove it.`);\n }\n return null;\n}","'use client';\n\n/* eslint-disable react-hooks/rules-of-hooks, react-hooks/exhaustive-deps */\nimport * as React from 'react';\nexport default function useControlled({\n controlled,\n default: defaultProp,\n name,\n state = 'value'\n}) {\n // isControlled is ignored in the hook dependency lists as it should never change.\n const {\n current: isControlled\n } = React.useRef(controlled !== undefined);\n const [valueState, setValue] = React.useState(defaultProp);\n const value = isControlled ? controlled : valueState;\n if (process.env.NODE_ENV !== 'production') {\n React.useEffect(() => {\n if (isControlled !== (controlled !== undefined)) {\n console.error([`MUI: A component is changing the ${isControlled ? '' : 'un'}controlled ${state} state of ${name} to be ${isControlled ? 'un' : ''}controlled.`, 'Elements should not switch from uncontrolled to controlled (or vice versa).', `Decide between using a controlled or uncontrolled ${name} ` + 'element for the lifetime of the component.', \"The nature of the state is determined during the first render. It's considered controlled if the value is not `undefined`.\", 'More info: https://fb.me/react-controlled-components'].join('\\n'));\n }\n }, [state, name, controlled]);\n const {\n current: defaultValue\n } = React.useRef(defaultProp);\n React.useEffect(() => {\n if (!isControlled && defaultValue !== defaultProp) {\n console.error([`MUI: A component is changing the default ${state} state of an uncontrolled ${name} after being initialized. ` + `To suppress this warning opt to use a controlled ${name}.`].join('\\n'));\n }\n }, [JSON.stringify(defaultProp)]);\n }\n const setValueIfUncontrolled = React.useCallback(newValue => {\n if (!isControlled) {\n setValue(newValue);\n }\n }, []);\n return [value, setValueIfUncontrolled];\n}","'use client';\n\nimport * as React from 'react';\nimport useEnhancedEffect from '../useEnhancedEffect';\n\n/**\n * Inspired by https://github.com/facebook/react/issues/14099#issuecomment-440013892\n * See RFC in https://github.com/reactjs/rfcs/pull/220\n */\n\nfunction useEventCallback(fn) {\n const ref = React.useRef(fn);\n useEnhancedEffect(() => {\n ref.current = fn;\n });\n return React.useRef((...args) =>\n // @ts-expect-error hide `this`\n (0, ref.current)(...args)).current;\n}\nexport default useEventCallback;","'use client';\n\nimport * as React from 'react';\nimport setRef from '../setRef';\nexport default function useForkRef(...refs) {\n /**\n * This will create a new function if the refs passed to this hook change and are all defined.\n * This means react will call the old forkRef with `null` and the new forkRef\n * with the ref. Cleanup naturally emerges from this behavior.\n */\n return React.useMemo(() => {\n if (refs.every(ref => ref == null)) {\n return null;\n }\n return instance => {\n refs.forEach(ref => {\n setRef(ref, instance);\n });\n };\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, refs);\n}","'use client';\n\nimport * as React from 'react';\nconst UNINITIALIZED = {};\n\n/**\n * A React.useRef() that is initialized lazily with a function. Note that it accepts an optional\n * initialization argument, so the initialization function doesn't need to be an inline closure.\n *\n * @usage\n * const ref = useLazyRef(sortColumns, columns)\n */\nexport default function useLazyRef(init, initArg) {\n const ref = React.useRef(UNINITIALIZED);\n if (ref.current === UNINITIALIZED) {\n ref.current = init(initArg);\n }\n return ref;\n}","'use client';\n\nimport * as React from 'react';\nconst EMPTY = [];\n\n/**\n * A React.useEffect equivalent that runs once, when the component is mounted.\n */\nexport default function useOnMount(fn) {\n /* eslint-disable react-hooks/exhaustive-deps */\n React.useEffect(fn, EMPTY);\n /* eslint-enable react-hooks/exhaustive-deps */\n}","'use client';\n\nimport useLazyRef from '../useLazyRef/useLazyRef';\nimport useOnMount from '../useOnMount/useOnMount';\nexport class Timeout {\n constructor() {\n this.currentId = null;\n this.clear = () => {\n if (this.currentId !== null) {\n clearTimeout(this.currentId);\n this.currentId = null;\n }\n };\n this.disposeEffect = () => {\n return this.clear;\n };\n }\n static create() {\n return new Timeout();\n }\n /**\n * Executes `fn` after `delay`, clearing any previously scheduled call.\n */\n start(delay, fn) {\n this.clear();\n this.currentId = setTimeout(() => {\n this.currentId = null;\n fn();\n }, delay);\n }\n}\nexport default function useTimeout() {\n const timeout = useLazyRef(Timeout.create).current;\n useOnMount(timeout.disposeEffect);\n return timeout;\n}","'use client';\n\n// based on https://github.com/WICG/focus-visible/blob/v4.1.5/src/focus-visible.js\nimport * as React from 'react';\nimport { Timeout } from '../useTimeout/useTimeout';\nlet hadKeyboardEvent = true;\nlet hadFocusVisibleRecently = false;\nconst hadFocusVisibleRecentlyTimeout = new Timeout();\nconst inputTypesWhitelist = {\n text: true,\n search: true,\n url: true,\n tel: true,\n email: true,\n password: true,\n number: true,\n date: true,\n month: true,\n week: true,\n time: true,\n datetime: true,\n 'datetime-local': true\n};\n\n/**\n * Computes whether the given element should automatically trigger the\n * `focus-visible` class being added, i.e. whether it should always match\n * `:focus-visible` when focused.\n * @param {Element} node\n * @returns {boolean}\n */\nfunction focusTriggersKeyboardModality(node) {\n const {\n type,\n tagName\n } = node;\n if (tagName === 'INPUT' && inputTypesWhitelist[type] && !node.readOnly) {\n return true;\n }\n if (tagName === 'TEXTAREA' && !node.readOnly) {\n return true;\n }\n if (node.isContentEditable) {\n return true;\n }\n return false;\n}\n\n/**\n * Keep track of our keyboard modality state with `hadKeyboardEvent`.\n * If the most recent user interaction was via the keyboard;\n * and the key press did not include a meta, alt/option, or control key;\n * then the modality is keyboard. Otherwise, the modality is not keyboard.\n * @param {KeyboardEvent} event\n */\nfunction handleKeyDown(event) {\n if (event.metaKey || event.altKey || event.ctrlKey) {\n return;\n }\n hadKeyboardEvent = true;\n}\n\n/**\n * If at any point a user clicks with a pointing device, ensure that we change\n * the modality away from keyboard.\n * This avoids the situation where a user presses a key on an already focused\n * element, and then clicks on a different element, focusing it with a\n * pointing device, while we still think we're in keyboard modality.\n */\nfunction handlePointerDown() {\n hadKeyboardEvent = false;\n}\nfunction handleVisibilityChange() {\n if (this.visibilityState === 'hidden') {\n // If the tab becomes active again, the browser will handle calling focus\n // on the element (Safari actually calls it twice).\n // If this tab change caused a blur on an element with focus-visible,\n // re-apply the class when the user switches back to the tab.\n if (hadFocusVisibleRecently) {\n hadKeyboardEvent = true;\n }\n }\n}\nfunction prepare(doc) {\n doc.addEventListener('keydown', handleKeyDown, true);\n doc.addEventListener('mousedown', handlePointerDown, true);\n doc.addEventListener('pointerdown', handlePointerDown, true);\n doc.addEventListener('touchstart', handlePointerDown, true);\n doc.addEventListener('visibilitychange', handleVisibilityChange, true);\n}\nexport function teardown(doc) {\n doc.removeEventListener('keydown', handleKeyDown, true);\n doc.removeEventListener('mousedown', handlePointerDown, true);\n doc.removeEventListener('pointerdown', handlePointerDown, true);\n doc.removeEventListener('touchstart', handlePointerDown, true);\n doc.removeEventListener('visibilitychange', handleVisibilityChange, true);\n}\nfunction isFocusVisible(event) {\n const {\n target\n } = event;\n try {\n return target.matches(':focus-visible');\n } catch (error) {\n // Browsers not implementing :focus-visible will throw a SyntaxError.\n // We use our own heuristic for those browsers.\n // Rethrow might be better if it's not the expected error but do we really\n // want to crash if focus-visible malfunctioned?\n }\n\n // No need for validFocusTarget check. The user does that by attaching it to\n // focusable events only.\n return hadKeyboardEvent || focusTriggersKeyboardModality(target);\n}\nexport default function useIsFocusVisible() {\n const ref = React.useCallback(node => {\n if (node != null) {\n prepare(node.ownerDocument);\n }\n }, []);\n const isFocusVisibleRef = React.useRef(false);\n\n /**\n * Should be called if a blur event is fired\n */\n function handleBlurVisible() {\n // checking against potential state variable does not suffice if we focus and blur synchronously.\n // React wouldn't have time to trigger a re-render so `focusVisible` would be stale.\n // Ideally we would adjust `isFocusVisible(event)` to look at `relatedTarget` for blur events.\n // This doesn't work in IE11 due to https://github.com/facebook/react/issues/3751\n // TODO: check again if React releases their internal changes to focus event handling (https://github.com/facebook/react/pull/19186).\n if (isFocusVisibleRef.current) {\n // To detect a tab/window switch, we look for a blur event followed\n // rapidly by a visibility change.\n // If we don't see a visibility change within 100ms, it's probably a\n // regular focus change.\n hadFocusVisibleRecently = true;\n hadFocusVisibleRecentlyTimeout.start(100, () => {\n hadFocusVisibleRecently = false;\n });\n isFocusVisibleRef.current = false;\n return true;\n }\n return false;\n }\n\n /**\n * Should be called if a blur event is fired\n */\n function handleFocusVisible(event) {\n if (isFocusVisible(event)) {\n isFocusVisibleRef.current = true;\n return true;\n }\n return false;\n }\n return {\n isFocusVisibleRef,\n onFocus: handleFocusVisible,\n onBlur: handleBlurVisible,\n ref\n };\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\n/**\n * Add keys, values of `defaultProps` that does not exist in `props`\n * @param {object} defaultProps\n * @param {object} props\n * @returns {object} resolved props\n */\nexport default function resolveProps(defaultProps, props) {\n const output = _extends({}, props);\n Object.keys(defaultProps).forEach(propName => {\n if (propName.toString().match(/^(components|slots)$/)) {\n output[propName] = _extends({}, defaultProps[propName], output[propName]);\n } else if (propName.toString().match(/^(componentsProps|slotProps)$/)) {\n const defaultSlotProps = defaultProps[propName] || {};\n const slotProps = props[propName];\n output[propName] = {};\n if (!slotProps || !Object.keys(slotProps)) {\n // Reduce the iteration if the slot props is empty\n output[propName] = defaultSlotProps;\n } else if (!defaultSlotProps || !Object.keys(defaultSlotProps)) {\n // Reduce the iteration if the default slot props is empty\n output[propName] = slotProps;\n } else {\n output[propName] = _extends({}, slotProps);\n Object.keys(defaultSlotProps).forEach(slotPropName => {\n output[propName][slotPropName] = resolveProps(defaultSlotProps[slotPropName], slotProps[slotPropName]);\n });\n }\n } else if (output[propName] === undefined) {\n output[propName] = defaultProps[propName];\n }\n });\n return output;\n}","export default function composeClasses(slots, getUtilityClass, classes = undefined) {\n const output = {};\n Object.keys(slots).forEach(\n // `Object.keys(slots)` can't be wider than `T` because we infer `T` from `slots`.\n // @ts-expect-error https://github.com/microsoft/TypeScript/pull/12253#issuecomment-263132208\n slot => {\n output[slot] = slots[slot].reduce((acc, key) => {\n if (key) {\n const utilityClass = getUtilityClass(key);\n if (utilityClass !== '') {\n acc.push(utilityClass);\n }\n if (classes && classes[key]) {\n acc.push(classes[key]);\n }\n }\n return acc;\n }, []).join(' ');\n });\n return output;\n}","const defaultGenerator = componentName => componentName;\nconst createClassNameGenerator = () => {\n let generate = defaultGenerator;\n return {\n configure(generator) {\n generate = generator;\n },\n generate(componentName) {\n return generate(componentName);\n },\n reset() {\n generate = defaultGenerator;\n }\n };\n};\nconst ClassNameGenerator = createClassNameGenerator();\nexport default ClassNameGenerator;","import ClassNameGenerator from '../ClassNameGenerator';\nexport const globalStateClasses = {\n active: 'active',\n checked: 'checked',\n completed: 'completed',\n disabled: 'disabled',\n error: 'error',\n expanded: 'expanded',\n focused: 'focused',\n focusVisible: 'focusVisible',\n open: 'open',\n readOnly: 'readOnly',\n required: 'required',\n selected: 'selected'\n};\nexport default function generateUtilityClass(componentName, slot, globalStatePrefix = 'Mui') {\n const globalStateClass = globalStateClasses[slot];\n return globalStateClass ? `${globalStatePrefix}-${globalStateClass}` : `${ClassNameGenerator.generate(componentName)}-${slot}`;\n}\nexport function isGlobalState(slot) {\n return globalStateClasses[slot] !== undefined;\n}","import generateUtilityClass from '../generateUtilityClass';\nexport default function generateUtilityClasses(componentName, slots, globalStatePrefix = 'Mui') {\n const result = {};\n slots.forEach(slot => {\n result[slot] = generateUtilityClass(componentName, slot, globalStatePrefix);\n });\n return result;\n}","function clamp(val, min = Number.MIN_SAFE_INTEGER, max = Number.MAX_SAFE_INTEGER) {\n return Math.max(min, Math.min(val, max));\n}\nexport default clamp;","export default function _objectWithoutPropertiesLoose(source, excluded) {\n if (source == null) return {};\n var target = {};\n var sourceKeys = Object.keys(source);\n var key, i;\n for (i = 0; i < sourceKeys.length; i++) {\n key = sourceKeys[i];\n if (excluded.indexOf(key) >= 0) continue;\n target[key] = source[key];\n }\n return target;\n}","import _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nconst _excluded = [\"values\", \"unit\", \"step\"];\n// Sorted ASC by size. That's important.\n// It can't be configured as it's used statically for propTypes.\nexport const breakpointKeys = ['xs', 'sm', 'md', 'lg', 'xl'];\nconst sortBreakpointsValues = values => {\n const breakpointsAsArray = Object.keys(values).map(key => ({\n key,\n val: values[key]\n })) || [];\n // Sort in ascending order\n breakpointsAsArray.sort((breakpoint1, breakpoint2) => breakpoint1.val - breakpoint2.val);\n return breakpointsAsArray.reduce((acc, obj) => {\n return _extends({}, acc, {\n [obj.key]: obj.val\n });\n }, {});\n};\n\n// Keep in mind that @media is inclusive by the CSS specification.\nexport default function createBreakpoints(breakpoints) {\n const {\n // The breakpoint **start** at this value.\n // For instance with the first breakpoint xs: [xs, sm).\n values = {\n xs: 0,\n // phone\n sm: 600,\n // tablet\n md: 900,\n // small laptop\n lg: 1200,\n // desktop\n xl: 1536 // large screen\n },\n unit = 'px',\n step = 5\n } = breakpoints,\n other = _objectWithoutPropertiesLoose(breakpoints, _excluded);\n const sortedValues = sortBreakpointsValues(values);\n const keys = Object.keys(sortedValues);\n function up(key) {\n const value = typeof values[key] === 'number' ? values[key] : key;\n return `@media (min-width:${value}${unit})`;\n }\n function down(key) {\n const value = typeof values[key] === 'number' ? values[key] : key;\n return `@media (max-width:${value - step / 100}${unit})`;\n }\n function between(start, end) {\n const endIndex = keys.indexOf(end);\n return `@media (min-width:${typeof values[start] === 'number' ? values[start] : start}${unit}) and ` + `(max-width:${(endIndex !== -1 && typeof values[keys[endIndex]] === 'number' ? values[keys[endIndex]] : end) - step / 100}${unit})`;\n }\n function only(key) {\n if (keys.indexOf(key) + 1 < keys.length) {\n return between(key, keys[keys.indexOf(key) + 1]);\n }\n return up(key);\n }\n function not(key) {\n // handle first and last key separately, for better readability\n const keyIndex = keys.indexOf(key);\n if (keyIndex === 0) {\n return up(keys[1]);\n }\n if (keyIndex === keys.length - 1) {\n return down(keys[keyIndex]);\n }\n return between(key, keys[keys.indexOf(key) + 1]).replace('@media', '@media not all and');\n }\n return _extends({\n keys,\n values: sortedValues,\n up,\n down,\n between,\n only,\n not,\n unit\n }, other);\n}","const shape = {\n borderRadius: 4\n};\nexport default shape;","import PropTypes from 'prop-types';\nconst responsivePropType = process.env.NODE_ENV !== 'production' ? PropTypes.oneOfType([PropTypes.number, PropTypes.string, PropTypes.object, PropTypes.array]) : {};\nexport default responsivePropType;","import deepmerge from '@mui/utils/deepmerge';\nfunction merge(acc, item) {\n if (!item) {\n return acc;\n }\n return deepmerge(acc, item, {\n clone: false // No need to clone deep, it's way faster.\n });\n}\nexport default merge;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport PropTypes from 'prop-types';\nimport deepmerge from '@mui/utils/deepmerge';\nimport merge from './merge';\n\n// The breakpoint **start** at this value.\n// For instance with the first breakpoint xs: [xs, sm[.\nexport const values = {\n xs: 0,\n // phone\n sm: 600,\n // tablet\n md: 900,\n // small laptop\n lg: 1200,\n // desktop\n xl: 1536 // large screen\n};\nconst defaultBreakpoints = {\n // Sorted ASC by size. That's important.\n // It can't be configured as it's used statically for propTypes.\n keys: ['xs', 'sm', 'md', 'lg', 'xl'],\n up: key => `@media (min-width:${values[key]}px)`\n};\nexport function handleBreakpoints(props, propValue, styleFromPropValue) {\n const theme = props.theme || {};\n if (Array.isArray(propValue)) {\n const themeBreakpoints = theme.breakpoints || defaultBreakpoints;\n return propValue.reduce((acc, item, index) => {\n acc[themeBreakpoints.up(themeBreakpoints.keys[index])] = styleFromPropValue(propValue[index]);\n return acc;\n }, {});\n }\n if (typeof propValue === 'object') {\n const themeBreakpoints = theme.breakpoints || defaultBreakpoints;\n return Object.keys(propValue).reduce((acc, breakpoint) => {\n // key is breakpoint\n if (Object.keys(themeBreakpoints.values || values).indexOf(breakpoint) !== -1) {\n const mediaKey = themeBreakpoints.up(breakpoint);\n acc[mediaKey] = styleFromPropValue(propValue[breakpoint], breakpoint);\n } else {\n const cssKey = breakpoint;\n acc[cssKey] = propValue[cssKey];\n }\n return acc;\n }, {});\n }\n const output = styleFromPropValue(propValue);\n return output;\n}\nfunction breakpoints(styleFunction) {\n // false positive\n // eslint-disable-next-line react/function-component-definition\n const newStyleFunction = props => {\n const theme = props.theme || {};\n const base = styleFunction(props);\n const themeBreakpoints = theme.breakpoints || defaultBreakpoints;\n const extended = themeBreakpoints.keys.reduce((acc, key) => {\n if (props[key]) {\n acc = acc || {};\n acc[themeBreakpoints.up(key)] = styleFunction(_extends({\n theme\n }, props[key]));\n }\n return acc;\n }, null);\n return merge(base, extended);\n };\n newStyleFunction.propTypes = process.env.NODE_ENV !== 'production' ? _extends({}, styleFunction.propTypes, {\n xs: PropTypes.object,\n sm: PropTypes.object,\n md: PropTypes.object,\n lg: PropTypes.object,\n xl: PropTypes.object\n }) : {};\n newStyleFunction.filterProps = ['xs', 'sm', 'md', 'lg', 'xl', ...styleFunction.filterProps];\n return newStyleFunction;\n}\nexport function createEmptyBreakpointObject(breakpointsInput = {}) {\n var _breakpointsInput$key;\n const breakpointsInOrder = (_breakpointsInput$key = breakpointsInput.keys) == null ? void 0 : _breakpointsInput$key.reduce((acc, key) => {\n const breakpointStyleKey = breakpointsInput.up(key);\n acc[breakpointStyleKey] = {};\n return acc;\n }, {});\n return breakpointsInOrder || {};\n}\nexport function removeUnusedBreakpoints(breakpointKeys, style) {\n return breakpointKeys.reduce((acc, key) => {\n const breakpointOutput = acc[key];\n const isBreakpointUnused = !breakpointOutput || Object.keys(breakpointOutput).length === 0;\n if (isBreakpointUnused) {\n delete acc[key];\n }\n return acc;\n }, style);\n}\nexport function mergeBreakpointsInOrder(breakpointsInput, ...styles) {\n const emptyBreakpoints = createEmptyBreakpointObject(breakpointsInput);\n const mergedOutput = [emptyBreakpoints, ...styles].reduce((prev, next) => deepmerge(prev, next), {});\n return removeUnusedBreakpoints(Object.keys(emptyBreakpoints), mergedOutput);\n}\n\n// compute base for responsive values; e.g.,\n// [1,2,3] => {xs: true, sm: true, md: true}\n// {xs: 1, sm: 2, md: 3} => {xs: true, sm: true, md: true}\nexport function computeBreakpointsBase(breakpointValues, themeBreakpoints) {\n // fixed value\n if (typeof breakpointValues !== 'object') {\n return {};\n }\n const base = {};\n const breakpointsKeys = Object.keys(themeBreakpoints);\n if (Array.isArray(breakpointValues)) {\n breakpointsKeys.forEach((breakpoint, i) => {\n if (i < breakpointValues.length) {\n base[breakpoint] = true;\n }\n });\n } else {\n breakpointsKeys.forEach(breakpoint => {\n if (breakpointValues[breakpoint] != null) {\n base[breakpoint] = true;\n }\n });\n }\n return base;\n}\nexport function resolveBreakpointValues({\n values: breakpointValues,\n breakpoints: themeBreakpoints,\n base: customBase\n}) {\n const base = customBase || computeBreakpointsBase(breakpointValues, themeBreakpoints);\n const keys = Object.keys(base);\n if (keys.length === 0) {\n return breakpointValues;\n }\n let previous;\n return keys.reduce((acc, breakpoint, i) => {\n if (Array.isArray(breakpointValues)) {\n acc[breakpoint] = breakpointValues[i] != null ? breakpointValues[i] : breakpointValues[previous];\n previous = i;\n } else if (typeof breakpointValues === 'object') {\n acc[breakpoint] = breakpointValues[breakpoint] != null ? breakpointValues[breakpoint] : breakpointValues[previous];\n previous = breakpoint;\n } else {\n acc[breakpoint] = breakpointValues;\n }\n return acc;\n }, {});\n}\nexport default breakpoints;","import capitalize from '@mui/utils/capitalize';\nimport responsivePropType from './responsivePropType';\nimport { handleBreakpoints } from './breakpoints';\nexport function getPath(obj, path, checkVars = true) {\n if (!path || typeof path !== 'string') {\n return null;\n }\n\n // Check if CSS variables are used\n if (obj && obj.vars && checkVars) {\n const val = `vars.${path}`.split('.').reduce((acc, item) => acc && acc[item] ? acc[item] : null, obj);\n if (val != null) {\n return val;\n }\n }\n return path.split('.').reduce((acc, item) => {\n if (acc && acc[item] != null) {\n return acc[item];\n }\n return null;\n }, obj);\n}\nexport function getStyleValue(themeMapping, transform, propValueFinal, userValue = propValueFinal) {\n let value;\n if (typeof themeMapping === 'function') {\n value = themeMapping(propValueFinal);\n } else if (Array.isArray(themeMapping)) {\n value = themeMapping[propValueFinal] || userValue;\n } else {\n value = getPath(themeMapping, propValueFinal) || userValue;\n }\n if (transform) {\n value = transform(value, userValue, themeMapping);\n }\n return value;\n}\nfunction style(options) {\n const {\n prop,\n cssProperty = options.prop,\n themeKey,\n transform\n } = options;\n\n // false positive\n // eslint-disable-next-line react/function-component-definition\n const fn = props => {\n if (props[prop] == null) {\n return null;\n }\n const propValue = props[prop];\n const theme = props.theme;\n const themeMapping = getPath(theme, themeKey) || {};\n const styleFromPropValue = propValueFinal => {\n let value = getStyleValue(themeMapping, transform, propValueFinal);\n if (propValueFinal === value && typeof propValueFinal === 'string') {\n // Haven't found value\n value = getStyleValue(themeMapping, transform, `${prop}${propValueFinal === 'default' ? '' : capitalize(propValueFinal)}`, propValueFinal);\n }\n if (cssProperty === false) {\n return value;\n }\n return {\n [cssProperty]: value\n };\n };\n return handleBreakpoints(props, propValue, styleFromPropValue);\n };\n fn.propTypes = process.env.NODE_ENV !== 'production' ? {\n [prop]: responsivePropType\n } : {};\n fn.filterProps = [prop];\n return fn;\n}\nexport default style;","export default function memoize(fn) {\n const cache = {};\n return arg => {\n if (cache[arg] === undefined) {\n cache[arg] = fn(arg);\n }\n return cache[arg];\n };\n}","import responsivePropType from './responsivePropType';\nimport { handleBreakpoints } from './breakpoints';\nimport { getPath } from './style';\nimport merge from './merge';\nimport memoize from './memoize';\nconst properties = {\n m: 'margin',\n p: 'padding'\n};\nconst directions = {\n t: 'Top',\n r: 'Right',\n b: 'Bottom',\n l: 'Left',\n x: ['Left', 'Right'],\n y: ['Top', 'Bottom']\n};\nconst aliases = {\n marginX: 'mx',\n marginY: 'my',\n paddingX: 'px',\n paddingY: 'py'\n};\n\n// memoize() impact:\n// From 300,000 ops/sec\n// To 350,000 ops/sec\nconst getCssProperties = memoize(prop => {\n // It's not a shorthand notation.\n if (prop.length > 2) {\n if (aliases[prop]) {\n prop = aliases[prop];\n } else {\n return [prop];\n }\n }\n const [a, b] = prop.split('');\n const property = properties[a];\n const direction = directions[b] || '';\n return Array.isArray(direction) ? direction.map(dir => property + dir) : [property + direction];\n});\nexport const marginKeys = ['m', 'mt', 'mr', 'mb', 'ml', 'mx', 'my', 'margin', 'marginTop', 'marginRight', 'marginBottom', 'marginLeft', 'marginX', 'marginY', 'marginInline', 'marginInlineStart', 'marginInlineEnd', 'marginBlock', 'marginBlockStart', 'marginBlockEnd'];\nexport const paddingKeys = ['p', 'pt', 'pr', 'pb', 'pl', 'px', 'py', 'padding', 'paddingTop', 'paddingRight', 'paddingBottom', 'paddingLeft', 'paddingX', 'paddingY', 'paddingInline', 'paddingInlineStart', 'paddingInlineEnd', 'paddingBlock', 'paddingBlockStart', 'paddingBlockEnd'];\nconst spacingKeys = [...marginKeys, ...paddingKeys];\nexport function createUnaryUnit(theme, themeKey, defaultValue, propName) {\n var _getPath;\n const themeSpacing = (_getPath = getPath(theme, themeKey, false)) != null ? _getPath : defaultValue;\n if (typeof themeSpacing === 'number') {\n return abs => {\n if (typeof abs === 'string') {\n return abs;\n }\n if (process.env.NODE_ENV !== 'production') {\n if (typeof abs !== 'number') {\n console.error(`MUI: Expected ${propName} argument to be a number or a string, got ${abs}.`);\n }\n }\n return themeSpacing * abs;\n };\n }\n if (Array.isArray(themeSpacing)) {\n return abs => {\n if (typeof abs === 'string') {\n return abs;\n }\n if (process.env.NODE_ENV !== 'production') {\n if (!Number.isInteger(abs)) {\n console.error([`MUI: The \\`theme.${themeKey}\\` array type cannot be combined with non integer values.` + `You should either use an integer value that can be used as index, or define the \\`theme.${themeKey}\\` as a number.`].join('\\n'));\n } else if (abs > themeSpacing.length - 1) {\n console.error([`MUI: The value provided (${abs}) overflows.`, `The supported values are: ${JSON.stringify(themeSpacing)}.`, `${abs} > ${themeSpacing.length - 1}, you need to add the missing values.`].join('\\n'));\n }\n }\n return themeSpacing[abs];\n };\n }\n if (typeof themeSpacing === 'function') {\n return themeSpacing;\n }\n if (process.env.NODE_ENV !== 'production') {\n console.error([`MUI: The \\`theme.${themeKey}\\` value (${themeSpacing}) is invalid.`, 'It should be a number, an array or a function.'].join('\\n'));\n }\n return () => undefined;\n}\nexport function createUnarySpacing(theme) {\n return createUnaryUnit(theme, 'spacing', 8, 'spacing');\n}\nexport function getValue(transformer, propValue) {\n if (typeof propValue === 'string' || propValue == null) {\n return propValue;\n }\n const abs = Math.abs(propValue);\n const transformed = transformer(abs);\n if (propValue >= 0) {\n return transformed;\n }\n if (typeof transformed === 'number') {\n return -transformed;\n }\n return `-${transformed}`;\n}\nexport function getStyleFromPropValue(cssProperties, transformer) {\n return propValue => cssProperties.reduce((acc, cssProperty) => {\n acc[cssProperty] = getValue(transformer, propValue);\n return acc;\n }, {});\n}\nfunction resolveCssProperty(props, keys, prop, transformer) {\n // Using a hash computation over an array iteration could be faster, but with only 28 items,\n // it's doesn't worth the bundle size.\n if (keys.indexOf(prop) === -1) {\n return null;\n }\n const cssProperties = getCssProperties(prop);\n const styleFromPropValue = getStyleFromPropValue(cssProperties, transformer);\n const propValue = props[prop];\n return handleBreakpoints(props, propValue, styleFromPropValue);\n}\nfunction style(props, keys) {\n const transformer = createUnarySpacing(props.theme);\n return Object.keys(props).map(prop => resolveCssProperty(props, keys, prop, transformer)).reduce(merge, {});\n}\nexport function margin(props) {\n return style(props, marginKeys);\n}\nmargin.propTypes = process.env.NODE_ENV !== 'production' ? marginKeys.reduce((obj, key) => {\n obj[key] = responsivePropType;\n return obj;\n}, {}) : {};\nmargin.filterProps = marginKeys;\nexport function padding(props) {\n return style(props, paddingKeys);\n}\npadding.propTypes = process.env.NODE_ENV !== 'production' ? paddingKeys.reduce((obj, key) => {\n obj[key] = responsivePropType;\n return obj;\n}, {}) : {};\npadding.filterProps = paddingKeys;\nfunction spacing(props) {\n return style(props, spacingKeys);\n}\nspacing.propTypes = process.env.NODE_ENV !== 'production' ? spacingKeys.reduce((obj, key) => {\n obj[key] = responsivePropType;\n return obj;\n}, {}) : {};\nspacing.filterProps = spacingKeys;\nexport default spacing;","import { createUnarySpacing } from '../spacing';\n\n// The different signatures imply different meaning for their arguments that can't be expressed structurally.\n// We express the difference with variable names.\n\nexport default function createSpacing(spacingInput = 8) {\n // Already transformed.\n if (spacingInput.mui) {\n return spacingInput;\n }\n\n // Material Design layouts are visually balanced. Most measurements align to an 8dp grid, which aligns both spacing and the overall layout.\n // Smaller components, such as icons, can align to a 4dp grid.\n // https://m2.material.io/design/layout/understanding-layout.html\n const transform = createUnarySpacing({\n spacing: spacingInput\n });\n const spacing = (...argsInput) => {\n if (process.env.NODE_ENV !== 'production') {\n if (!(argsInput.length <= 4)) {\n console.error(`MUI: Too many arguments provided, expected between 0 and 4, got ${argsInput.length}`);\n }\n }\n const args = argsInput.length === 0 ? [1] : argsInput;\n return args.map(argument => {\n const output = transform(argument);\n return typeof output === 'number' ? `${output}px` : output;\n }).join(' ');\n };\n spacing.mui = true;\n return spacing;\n}","import merge from './merge';\nfunction compose(...styles) {\n const handlers = styles.reduce((acc, style) => {\n style.filterProps.forEach(prop => {\n acc[prop] = style;\n });\n return acc;\n }, {});\n\n // false positive\n // eslint-disable-next-line react/function-component-definition\n const fn = props => {\n return Object.keys(props).reduce((acc, prop) => {\n if (handlers[prop]) {\n return merge(acc, handlers[prop](props));\n }\n return acc;\n }, {});\n };\n fn.propTypes = process.env.NODE_ENV !== 'production' ? styles.reduce((acc, style) => Object.assign(acc, style.propTypes), {}) : {};\n fn.filterProps = styles.reduce((acc, style) => acc.concat(style.filterProps), []);\n return fn;\n}\nexport default compose;","import responsivePropType from './responsivePropType';\nimport style from './style';\nimport compose from './compose';\nimport { createUnaryUnit, getValue } from './spacing';\nimport { handleBreakpoints } from './breakpoints';\nexport function borderTransform(value) {\n if (typeof value !== 'number') {\n return value;\n }\n return `${value}px solid`;\n}\nfunction createBorderStyle(prop, transform) {\n return style({\n prop,\n themeKey: 'borders',\n transform\n });\n}\nexport const border = createBorderStyle('border', borderTransform);\nexport const borderTop = createBorderStyle('borderTop', borderTransform);\nexport const borderRight = createBorderStyle('borderRight', borderTransform);\nexport const borderBottom = createBorderStyle('borderBottom', borderTransform);\nexport const borderLeft = createBorderStyle('borderLeft', borderTransform);\nexport const borderColor = createBorderStyle('borderColor');\nexport const borderTopColor = createBorderStyle('borderTopColor');\nexport const borderRightColor = createBorderStyle('borderRightColor');\nexport const borderBottomColor = createBorderStyle('borderBottomColor');\nexport const borderLeftColor = createBorderStyle('borderLeftColor');\nexport const outline = createBorderStyle('outline', borderTransform);\nexport const outlineColor = createBorderStyle('outlineColor');\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const borderRadius = props => {\n if (props.borderRadius !== undefined && props.borderRadius !== null) {\n const transformer = createUnaryUnit(props.theme, 'shape.borderRadius', 4, 'borderRadius');\n const styleFromPropValue = propValue => ({\n borderRadius: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.borderRadius, styleFromPropValue);\n }\n return null;\n};\nborderRadius.propTypes = process.env.NODE_ENV !== 'production' ? {\n borderRadius: responsivePropType\n} : {};\nborderRadius.filterProps = ['borderRadius'];\nconst borders = compose(border, borderTop, borderRight, borderBottom, borderLeft, borderColor, borderTopColor, borderRightColor, borderBottomColor, borderLeftColor, borderRadius, outline, outlineColor);\nexport default borders;","import style from './style';\nimport compose from './compose';\nimport { createUnaryUnit, getValue } from './spacing';\nimport { handleBreakpoints } from './breakpoints';\nimport responsivePropType from './responsivePropType';\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const gap = props => {\n if (props.gap !== undefined && props.gap !== null) {\n const transformer = createUnaryUnit(props.theme, 'spacing', 8, 'gap');\n const styleFromPropValue = propValue => ({\n gap: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.gap, styleFromPropValue);\n }\n return null;\n};\ngap.propTypes = process.env.NODE_ENV !== 'production' ? {\n gap: responsivePropType\n} : {};\ngap.filterProps = ['gap'];\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const columnGap = props => {\n if (props.columnGap !== undefined && props.columnGap !== null) {\n const transformer = createUnaryUnit(props.theme, 'spacing', 8, 'columnGap');\n const styleFromPropValue = propValue => ({\n columnGap: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.columnGap, styleFromPropValue);\n }\n return null;\n};\ncolumnGap.propTypes = process.env.NODE_ENV !== 'production' ? {\n columnGap: responsivePropType\n} : {};\ncolumnGap.filterProps = ['columnGap'];\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const rowGap = props => {\n if (props.rowGap !== undefined && props.rowGap !== null) {\n const transformer = createUnaryUnit(props.theme, 'spacing', 8, 'rowGap');\n const styleFromPropValue = propValue => ({\n rowGap: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.rowGap, styleFromPropValue);\n }\n return null;\n};\nrowGap.propTypes = process.env.NODE_ENV !== 'production' ? {\n rowGap: responsivePropType\n} : {};\nrowGap.filterProps = ['rowGap'];\nexport const gridColumn = style({\n prop: 'gridColumn'\n});\nexport const gridRow = style({\n prop: 'gridRow'\n});\nexport const gridAutoFlow = style({\n prop: 'gridAutoFlow'\n});\nexport const gridAutoColumns = style({\n prop: 'gridAutoColumns'\n});\nexport const gridAutoRows = style({\n prop: 'gridAutoRows'\n});\nexport const gridTemplateColumns = style({\n prop: 'gridTemplateColumns'\n});\nexport const gridTemplateRows = style({\n prop: 'gridTemplateRows'\n});\nexport const gridTemplateAreas = style({\n prop: 'gridTemplateAreas'\n});\nexport const gridArea = style({\n prop: 'gridArea'\n});\nconst grid = compose(gap, columnGap, rowGap, gridColumn, gridRow, gridAutoFlow, gridAutoColumns, gridAutoRows, gridTemplateColumns, gridTemplateRows, gridTemplateAreas, gridArea);\nexport default grid;","import style from './style';\nimport compose from './compose';\nexport function paletteTransform(value, userValue) {\n if (userValue === 'grey') {\n return userValue;\n }\n return value;\n}\nexport const color = style({\n prop: 'color',\n themeKey: 'palette',\n transform: paletteTransform\n});\nexport const bgcolor = style({\n prop: 'bgcolor',\n cssProperty: 'backgroundColor',\n themeKey: 'palette',\n transform: paletteTransform\n});\nexport const backgroundColor = style({\n prop: 'backgroundColor',\n themeKey: 'palette',\n transform: paletteTransform\n});\nconst palette = compose(color, bgcolor, backgroundColor);\nexport default palette;","import style from './style';\nimport compose from './compose';\nimport { handleBreakpoints, values as breakpointsValues } from './breakpoints';\nexport function sizingTransform(value) {\n return value <= 1 && value !== 0 ? `${value * 100}%` : value;\n}\nexport const width = style({\n prop: 'width',\n transform: sizingTransform\n});\nexport const maxWidth = props => {\n if (props.maxWidth !== undefined && props.maxWidth !== null) {\n const styleFromPropValue = propValue => {\n var _props$theme, _props$theme2;\n const breakpoint = ((_props$theme = props.theme) == null || (_props$theme = _props$theme.breakpoints) == null || (_props$theme = _props$theme.values) == null ? void 0 : _props$theme[propValue]) || breakpointsValues[propValue];\n if (!breakpoint) {\n return {\n maxWidth: sizingTransform(propValue)\n };\n }\n if (((_props$theme2 = props.theme) == null || (_props$theme2 = _props$theme2.breakpoints) == null ? void 0 : _props$theme2.unit) !== 'px') {\n return {\n maxWidth: `${breakpoint}${props.theme.breakpoints.unit}`\n };\n }\n return {\n maxWidth: breakpoint\n };\n };\n return handleBreakpoints(props, props.maxWidth, styleFromPropValue);\n }\n return null;\n};\nmaxWidth.filterProps = ['maxWidth'];\nexport const minWidth = style({\n prop: 'minWidth',\n transform: sizingTransform\n});\nexport const height = style({\n prop: 'height',\n transform: sizingTransform\n});\nexport const maxHeight = style({\n prop: 'maxHeight',\n transform: sizingTransform\n});\nexport const minHeight = style({\n prop: 'minHeight',\n transform: sizingTransform\n});\nexport const sizeWidth = style({\n prop: 'size',\n cssProperty: 'width',\n transform: sizingTransform\n});\nexport const sizeHeight = style({\n prop: 'size',\n cssProperty: 'height',\n transform: sizingTransform\n});\nexport const boxSizing = style({\n prop: 'boxSizing'\n});\nconst sizing = compose(width, maxWidth, minWidth, height, maxHeight, minHeight, boxSizing);\nexport default sizing;","import { padding, margin } from '../spacing';\nimport { borderRadius, borderTransform } from '../borders';\nimport { gap, rowGap, columnGap } from '../cssGrid';\nimport { paletteTransform } from '../palette';\nimport { maxWidth, sizingTransform } from '../sizing';\nconst defaultSxConfig = {\n // borders\n border: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderTop: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderRight: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderBottom: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderLeft: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderColor: {\n themeKey: 'palette'\n },\n borderTopColor: {\n themeKey: 'palette'\n },\n borderRightColor: {\n themeKey: 'palette'\n },\n borderBottomColor: {\n themeKey: 'palette'\n },\n borderLeftColor: {\n themeKey: 'palette'\n },\n outline: {\n themeKey: 'borders',\n transform: borderTransform\n },\n outlineColor: {\n themeKey: 'palette'\n },\n borderRadius: {\n themeKey: 'shape.borderRadius',\n style: borderRadius\n },\n // palette\n color: {\n themeKey: 'palette',\n transform: paletteTransform\n },\n bgcolor: {\n themeKey: 'palette',\n cssProperty: 'backgroundColor',\n transform: paletteTransform\n },\n backgroundColor: {\n themeKey: 'palette',\n transform: paletteTransform\n },\n // spacing\n p: {\n style: padding\n },\n pt: {\n style: padding\n },\n pr: {\n style: padding\n },\n pb: {\n style: padding\n },\n pl: {\n style: padding\n },\n px: {\n style: padding\n },\n py: {\n style: padding\n },\n padding: {\n style: padding\n },\n paddingTop: {\n style: padding\n },\n paddingRight: {\n style: padding\n },\n paddingBottom: {\n style: padding\n },\n paddingLeft: {\n style: padding\n },\n paddingX: {\n style: padding\n },\n paddingY: {\n style: padding\n },\n paddingInline: {\n style: padding\n },\n paddingInlineStart: {\n style: padding\n },\n paddingInlineEnd: {\n style: padding\n },\n paddingBlock: {\n style: padding\n },\n paddingBlockStart: {\n style: padding\n },\n paddingBlockEnd: {\n style: padding\n },\n m: {\n style: margin\n },\n mt: {\n style: margin\n },\n mr: {\n style: margin\n },\n mb: {\n style: margin\n },\n ml: {\n style: margin\n },\n mx: {\n style: margin\n },\n my: {\n style: margin\n },\n margin: {\n style: margin\n },\n marginTop: {\n style: margin\n },\n marginRight: {\n style: margin\n },\n marginBottom: {\n style: margin\n },\n marginLeft: {\n style: margin\n },\n marginX: {\n style: margin\n },\n marginY: {\n style: margin\n },\n marginInline: {\n style: margin\n },\n marginInlineStart: {\n style: margin\n },\n marginInlineEnd: {\n style: margin\n },\n marginBlock: {\n style: margin\n },\n marginBlockStart: {\n style: margin\n },\n marginBlockEnd: {\n style: margin\n },\n // display\n displayPrint: {\n cssProperty: false,\n transform: value => ({\n '@media print': {\n display: value\n }\n })\n },\n display: {},\n overflow: {},\n textOverflow: {},\n visibility: {},\n whiteSpace: {},\n // flexbox\n flexBasis: {},\n flexDirection: {},\n flexWrap: {},\n justifyContent: {},\n alignItems: {},\n alignContent: {},\n order: {},\n flex: {},\n flexGrow: {},\n flexShrink: {},\n alignSelf: {},\n justifyItems: {},\n justifySelf: {},\n // grid\n gap: {\n style: gap\n },\n rowGap: {\n style: rowGap\n },\n columnGap: {\n style: columnGap\n },\n gridColumn: {},\n gridRow: {},\n gridAutoFlow: {},\n gridAutoColumns: {},\n gridAutoRows: {},\n gridTemplateColumns: {},\n gridTemplateRows: {},\n gridTemplateAreas: {},\n gridArea: {},\n // positions\n position: {},\n zIndex: {\n themeKey: 'zIndex'\n },\n top: {},\n right: {},\n bottom: {},\n left: {},\n // shadows\n boxShadow: {\n themeKey: 'shadows'\n },\n // sizing\n width: {\n transform: sizingTransform\n },\n maxWidth: {\n style: maxWidth\n },\n minWidth: {\n transform: sizingTransform\n },\n height: {\n transform: sizingTransform\n },\n maxHeight: {\n transform: sizingTransform\n },\n minHeight: {\n transform: sizingTransform\n },\n boxSizing: {},\n // typography\n fontFamily: {\n themeKey: 'typography'\n },\n fontSize: {\n themeKey: 'typography'\n },\n fontStyle: {\n themeKey: 'typography'\n },\n fontWeight: {\n themeKey: 'typography'\n },\n letterSpacing: {},\n textTransform: {},\n lineHeight: {},\n textAlign: {},\n typography: {\n cssProperty: false,\n themeKey: 'typography'\n }\n};\nexport default defaultSxConfig;","import capitalize from '@mui/utils/capitalize';\nimport merge from '../merge';\nimport { getPath, getStyleValue as getValue } from '../style';\nimport { handleBreakpoints, createEmptyBreakpointObject, removeUnusedBreakpoints } from '../breakpoints';\nimport defaultSxConfig from './defaultSxConfig';\nfunction objectsHaveSameKeys(...objects) {\n const allKeys = objects.reduce((keys, object) => keys.concat(Object.keys(object)), []);\n const union = new Set(allKeys);\n return objects.every(object => union.size === Object.keys(object).length);\n}\nfunction callIfFn(maybeFn, arg) {\n return typeof maybeFn === 'function' ? maybeFn(arg) : maybeFn;\n}\n\n// eslint-disable-next-line @typescript-eslint/naming-convention\nexport function unstable_createStyleFunctionSx() {\n function getThemeValue(prop, val, theme, config) {\n const props = {\n [prop]: val,\n theme\n };\n const options = config[prop];\n if (!options) {\n return {\n [prop]: val\n };\n }\n const {\n cssProperty = prop,\n themeKey,\n transform,\n style\n } = options;\n if (val == null) {\n return null;\n }\n\n // TODO v6: remove, see https://github.com/mui/material-ui/pull/38123\n if (themeKey === 'typography' && val === 'inherit') {\n return {\n [prop]: val\n };\n }\n const themeMapping = getPath(theme, themeKey) || {};\n if (style) {\n return style(props);\n }\n const styleFromPropValue = propValueFinal => {\n let value = getValue(themeMapping, transform, propValueFinal);\n if (propValueFinal === value && typeof propValueFinal === 'string') {\n // Haven't found value\n value = getValue(themeMapping, transform, `${prop}${propValueFinal === 'default' ? '' : capitalize(propValueFinal)}`, propValueFinal);\n }\n if (cssProperty === false) {\n return value;\n }\n return {\n [cssProperty]: value\n };\n };\n return handleBreakpoints(props, val, styleFromPropValue);\n }\n function styleFunctionSx(props) {\n var _theme$unstable_sxCon;\n const {\n sx,\n theme = {}\n } = props || {};\n if (!sx) {\n return null; // Emotion & styled-components will neglect null\n }\n const config = (_theme$unstable_sxCon = theme.unstable_sxConfig) != null ? _theme$unstable_sxCon : defaultSxConfig;\n\n /*\n * Receive `sxInput` as object or callback\n * and then recursively check keys & values to create media query object styles.\n * (the result will be used in `styled`)\n */\n function traverse(sxInput) {\n let sxObject = sxInput;\n if (typeof sxInput === 'function') {\n sxObject = sxInput(theme);\n } else if (typeof sxInput !== 'object') {\n // value\n return sxInput;\n }\n if (!sxObject) {\n return null;\n }\n const emptyBreakpoints = createEmptyBreakpointObject(theme.breakpoints);\n const breakpointsKeys = Object.keys(emptyBreakpoints);\n let css = emptyBreakpoints;\n Object.keys(sxObject).forEach(styleKey => {\n const value = callIfFn(sxObject[styleKey], theme);\n if (value !== null && value !== undefined) {\n if (typeof value === 'object') {\n if (config[styleKey]) {\n css = merge(css, getThemeValue(styleKey, value, theme, config));\n } else {\n const breakpointsValues = handleBreakpoints({\n theme\n }, value, x => ({\n [styleKey]: x\n }));\n if (objectsHaveSameKeys(breakpointsValues, value)) {\n css[styleKey] = styleFunctionSx({\n sx: value,\n theme\n });\n } else {\n css = merge(css, breakpointsValues);\n }\n }\n } else {\n css = merge(css, getThemeValue(styleKey, value, theme, config));\n }\n }\n });\n return removeUnusedBreakpoints(breakpointsKeys, css);\n }\n return Array.isArray(sx) ? sx.map(traverse) : traverse(sx);\n }\n return styleFunctionSx;\n}\nconst styleFunctionSx = unstable_createStyleFunctionSx();\nstyleFunctionSx.filterProps = ['sx'];\nexport default styleFunctionSx;","/**\n * A universal utility to style components with multiple color modes. Always use it from the theme object.\n * It works with:\n * - [Basic theme](https://mui.com/material-ui/customization/dark-mode/)\n * - [CSS theme variables](https://mui.com/material-ui/experimental-api/css-theme-variables/overview/)\n * - Zero-runtime engine\n *\n * Tips: Use an array over object spread and place `theme.applyStyles()` last.\n *\n * ✅ [{ background: '#e5e5e5' }, theme.applyStyles('dark', { background: '#1c1c1c' })]\n *\n * 🚫 { background: '#e5e5e5', ...theme.applyStyles('dark', { background: '#1c1c1c' })}\n *\n * @example\n * 1. using with `styled`:\n * ```jsx\n * const Component = styled('div')(({ theme }) => [\n * { background: '#e5e5e5' },\n * theme.applyStyles('dark', {\n * background: '#1c1c1c',\n * color: '#fff',\n * }),\n * ]);\n * ```\n *\n * @example\n * 2. using with `sx` prop:\n * ```jsx\n * [\n * { background: '#e5e5e5' },\n * theme.applyStyles('dark', {\n * background: '#1c1c1c',\n * color: '#fff',\n * }),\n * ]}\n * />\n * ```\n *\n * @example\n * 3. theming a component:\n * ```jsx\n * extendTheme({\n * components: {\n * MuiButton: {\n * styleOverrides: {\n * root: ({ theme }) => [\n * { background: '#e5e5e5' },\n * theme.applyStyles('dark', {\n * background: '#1c1c1c',\n * color: '#fff',\n * }),\n * ],\n * },\n * }\n * }\n * })\n *```\n */\nexport default function applyStyles(key, styles) {\n // @ts-expect-error this is 'any' type\n const theme = this;\n if (theme.vars && typeof theme.getColorSchemeSelector === 'function') {\n // If CssVarsProvider is used as a provider,\n // returns '* :where([data-mui-color-scheme=\"light|dark\"]) &'\n const selector = theme.getColorSchemeSelector(key).replace(/(\\[[^\\]]+\\])/, '*:where($1)');\n return {\n [selector]: styles\n };\n }\n if (theme.palette.mode === key) {\n return styles;\n }\n return {};\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"breakpoints\", \"palette\", \"spacing\", \"shape\"];\nimport deepmerge from '@mui/utils/deepmerge';\nimport createBreakpoints from './createBreakpoints';\nimport shape from './shape';\nimport createSpacing from './createSpacing';\nimport styleFunctionSx from '../styleFunctionSx/styleFunctionSx';\nimport defaultSxConfig from '../styleFunctionSx/defaultSxConfig';\nimport applyStyles from './applyStyles';\nfunction createTheme(options = {}, ...args) {\n const {\n breakpoints: breakpointsInput = {},\n palette: paletteInput = {},\n spacing: spacingInput,\n shape: shapeInput = {}\n } = options,\n other = _objectWithoutPropertiesLoose(options, _excluded);\n const breakpoints = createBreakpoints(breakpointsInput);\n const spacing = createSpacing(spacingInput);\n let muiTheme = deepmerge({\n breakpoints,\n direction: 'ltr',\n components: {},\n // Inject component definitions.\n palette: _extends({\n mode: 'light'\n }, paletteInput),\n spacing,\n shape: _extends({}, shape, shapeInput)\n }, other);\n muiTheme.applyStyles = applyStyles;\n muiTheme = args.reduce((acc, argument) => deepmerge(acc, argument), muiTheme);\n muiTheme.unstable_sxConfig = _extends({}, defaultSxConfig, other == null ? void 0 : other.unstable_sxConfig);\n muiTheme.unstable_sx = function sx(props) {\n return styleFunctionSx({\n sx: props,\n theme: this\n });\n };\n return muiTheme;\n}\nexport default createTheme;","'use client';\n\nimport * as React from 'react';\nimport { ThemeContext } from '@mui/styled-engine';\nfunction isObjectEmpty(obj) {\n return Object.keys(obj).length === 0;\n}\nfunction useTheme(defaultTheme = null) {\n const contextTheme = React.useContext(ThemeContext);\n return !contextTheme || isObjectEmpty(contextTheme) ? defaultTheme : contextTheme;\n}\nexport default useTheme;","'use client';\n\nimport createTheme from './createTheme';\nimport useThemeWithoutDefault from './useThemeWithoutDefault';\nexport const systemDefaultTheme = createTheme();\nfunction useTheme(defaultTheme = systemDefaultTheme) {\n return useThemeWithoutDefault(defaultTheme);\n}\nexport default useTheme;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"ownerState\"],\n _excluded2 = [\"variants\"],\n _excluded3 = [\"name\", \"slot\", \"skipVariantsResolver\", \"skipSx\", \"overridesResolver\"];\n/* eslint-disable no-underscore-dangle */\nimport styledEngineStyled, { internal_processStyles as processStyles } from '@mui/styled-engine';\nimport { isPlainObject } from '@mui/utils/deepmerge';\nimport capitalize from '@mui/utils/capitalize';\nimport getDisplayName from '@mui/utils/getDisplayName';\nimport createTheme from './createTheme';\nimport styleFunctionSx from './styleFunctionSx';\nfunction isEmpty(obj) {\n return Object.keys(obj).length === 0;\n}\n\n// https://github.com/emotion-js/emotion/blob/26ded6109fcd8ca9875cc2ce4564fee678a3f3c5/packages/styled/src/utils.js#L40\nfunction isStringTag(tag) {\n return typeof tag === 'string' &&\n // 96 is one less than the char code\n // for \"a\" so this is checking that\n // it's a lowercase character\n tag.charCodeAt(0) > 96;\n}\n\n// Update /system/styled/#api in case if this changes\nexport function shouldForwardProp(prop) {\n return prop !== 'ownerState' && prop !== 'theme' && prop !== 'sx' && prop !== 'as';\n}\nexport const systemDefaultTheme = createTheme();\nconst lowercaseFirstLetter = string => {\n if (!string) {\n return string;\n }\n return string.charAt(0).toLowerCase() + string.slice(1);\n};\nfunction resolveTheme({\n defaultTheme,\n theme,\n themeId\n}) {\n return isEmpty(theme) ? defaultTheme : theme[themeId] || theme;\n}\nfunction defaultOverridesResolver(slot) {\n if (!slot) {\n return null;\n }\n return (props, styles) => styles[slot];\n}\nfunction processStyleArg(callableStyle, _ref) {\n let {\n ownerState\n } = _ref,\n props = _objectWithoutPropertiesLoose(_ref, _excluded);\n const resolvedStylesArg = typeof callableStyle === 'function' ? callableStyle(_extends({\n ownerState\n }, props)) : callableStyle;\n if (Array.isArray(resolvedStylesArg)) {\n return resolvedStylesArg.flatMap(resolvedStyle => processStyleArg(resolvedStyle, _extends({\n ownerState\n }, props)));\n }\n if (!!resolvedStylesArg && typeof resolvedStylesArg === 'object' && Array.isArray(resolvedStylesArg.variants)) {\n const {\n variants = []\n } = resolvedStylesArg,\n otherStyles = _objectWithoutPropertiesLoose(resolvedStylesArg, _excluded2);\n let result = otherStyles;\n variants.forEach(variant => {\n let isMatch = true;\n if (typeof variant.props === 'function') {\n isMatch = variant.props(_extends({\n ownerState\n }, props, ownerState));\n } else {\n Object.keys(variant.props).forEach(key => {\n if ((ownerState == null ? void 0 : ownerState[key]) !== variant.props[key] && props[key] !== variant.props[key]) {\n isMatch = false;\n }\n });\n }\n if (isMatch) {\n if (!Array.isArray(result)) {\n result = [result];\n }\n result.push(typeof variant.style === 'function' ? variant.style(_extends({\n ownerState\n }, props, ownerState)) : variant.style);\n }\n });\n return result;\n }\n return resolvedStylesArg;\n}\nexport default function createStyled(input = {}) {\n const {\n themeId,\n defaultTheme = systemDefaultTheme,\n rootShouldForwardProp = shouldForwardProp,\n slotShouldForwardProp = shouldForwardProp\n } = input;\n const systemSx = props => {\n return styleFunctionSx(_extends({}, props, {\n theme: resolveTheme(_extends({}, props, {\n defaultTheme,\n themeId\n }))\n }));\n };\n systemSx.__mui_systemSx = true;\n return (tag, inputOptions = {}) => {\n // Filter out the `sx` style function from the previous styled component to prevent unnecessary styles generated by the composite components.\n processStyles(tag, styles => styles.filter(style => !(style != null && style.__mui_systemSx)));\n const {\n name: componentName,\n slot: componentSlot,\n skipVariantsResolver: inputSkipVariantsResolver,\n skipSx: inputSkipSx,\n // TODO v6: remove `lowercaseFirstLetter()` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n overridesResolver = defaultOverridesResolver(lowercaseFirstLetter(componentSlot))\n } = inputOptions,\n options = _objectWithoutPropertiesLoose(inputOptions, _excluded3);\n\n // if skipVariantsResolver option is defined, take the value, otherwise, true for root and false for other slots.\n const skipVariantsResolver = inputSkipVariantsResolver !== undefined ? inputSkipVariantsResolver :\n // TODO v6: remove `Root` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n componentSlot && componentSlot !== 'Root' && componentSlot !== 'root' || false;\n const skipSx = inputSkipSx || false;\n let label;\n if (process.env.NODE_ENV !== 'production') {\n if (componentName) {\n // TODO v6: remove `lowercaseFirstLetter()` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n label = `${componentName}-${lowercaseFirstLetter(componentSlot || 'Root')}`;\n }\n }\n let shouldForwardPropOption = shouldForwardProp;\n\n // TODO v6: remove `Root` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n if (componentSlot === 'Root' || componentSlot === 'root') {\n shouldForwardPropOption = rootShouldForwardProp;\n } else if (componentSlot) {\n // any other slot specified\n shouldForwardPropOption = slotShouldForwardProp;\n } else if (isStringTag(tag)) {\n // for string (html) tag, preserve the behavior in emotion & styled-components.\n shouldForwardPropOption = undefined;\n }\n const defaultStyledResolver = styledEngineStyled(tag, _extends({\n shouldForwardProp: shouldForwardPropOption,\n label\n }, options));\n const transformStyleArg = stylesArg => {\n // On the server Emotion doesn't use React.forwardRef for creating components, so the created\n // component stays as a function. This condition makes sure that we do not interpolate functions\n // which are basically components used as a selectors.\n if (typeof stylesArg === 'function' && stylesArg.__emotion_real !== stylesArg || isPlainObject(stylesArg)) {\n return props => processStyleArg(stylesArg, _extends({}, props, {\n theme: resolveTheme({\n theme: props.theme,\n defaultTheme,\n themeId\n })\n }));\n }\n return stylesArg;\n };\n const muiStyledResolver = (styleArg, ...expressions) => {\n let transformedStyleArg = transformStyleArg(styleArg);\n const expressionsWithDefaultTheme = expressions ? expressions.map(transformStyleArg) : [];\n if (componentName && overridesResolver) {\n expressionsWithDefaultTheme.push(props => {\n const theme = resolveTheme(_extends({}, props, {\n defaultTheme,\n themeId\n }));\n if (!theme.components || !theme.components[componentName] || !theme.components[componentName].styleOverrides) {\n return null;\n }\n const styleOverrides = theme.components[componentName].styleOverrides;\n const resolvedStyleOverrides = {};\n // TODO: v7 remove iteration and use `resolveStyleArg(styleOverrides[slot])` directly\n Object.entries(styleOverrides).forEach(([slotKey, slotStyle]) => {\n resolvedStyleOverrides[slotKey] = processStyleArg(slotStyle, _extends({}, props, {\n theme\n }));\n });\n return overridesResolver(props, resolvedStyleOverrides);\n });\n }\n if (componentName && !skipVariantsResolver) {\n expressionsWithDefaultTheme.push(props => {\n var _theme$components;\n const theme = resolveTheme(_extends({}, props, {\n defaultTheme,\n themeId\n }));\n const themeVariants = theme == null || (_theme$components = theme.components) == null || (_theme$components = _theme$components[componentName]) == null ? void 0 : _theme$components.variants;\n return processStyleArg({\n variants: themeVariants\n }, _extends({}, props, {\n theme\n }));\n });\n }\n if (!skipSx) {\n expressionsWithDefaultTheme.push(systemSx);\n }\n const numOfCustomFnsApplied = expressionsWithDefaultTheme.length - expressions.length;\n if (Array.isArray(styleArg) && numOfCustomFnsApplied > 0) {\n const placeholders = new Array(numOfCustomFnsApplied).fill('');\n // If the type is array, than we need to add placeholders in the template for the overrides, variants and the sx styles.\n transformedStyleArg = [...styleArg, ...placeholders];\n transformedStyleArg.raw = [...styleArg.raw, ...placeholders];\n }\n const Component = defaultStyledResolver(transformedStyleArg, ...expressionsWithDefaultTheme);\n if (process.env.NODE_ENV !== 'production') {\n let displayName;\n if (componentName) {\n displayName = `${componentName}${capitalize(componentSlot || '')}`;\n }\n if (displayName === undefined) {\n displayName = `Styled(${getDisplayName(tag)})`;\n }\n Component.displayName = displayName;\n }\n if (tag.muiName) {\n Component.muiName = tag.muiName;\n }\n return Component;\n };\n if (defaultStyledResolver.withConfig) {\n muiStyledResolver.withConfig = defaultStyledResolver.withConfig;\n }\n return muiStyledResolver;\n };\n}","import resolveProps from '@mui/utils/resolveProps';\nexport default function getThemeProps(params) {\n const {\n theme,\n name,\n props\n } = params;\n if (!theme || !theme.components || !theme.components[name] || !theme.components[name].defaultProps) {\n return props;\n }\n return resolveProps(theme.components[name].defaultProps, props);\n}","'use client';\n\nimport getThemeProps from './getThemeProps';\nimport useTheme from '../useTheme';\nexport default function useThemeProps({\n props,\n name,\n defaultTheme,\n themeId\n}) {\n let theme = useTheme(defaultTheme);\n if (themeId) {\n theme = theme[themeId] || theme;\n }\n const mergedProps = getThemeProps({\n theme,\n name,\n props\n });\n return mergedProps;\n}","import _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\n/* eslint-disable @typescript-eslint/naming-convention */\nimport clamp from '@mui/utils/clamp';\n/**\n * Returns a number whose value is limited to the given range.\n * @param {number} value The value to be clamped\n * @param {number} min The lower boundary of the output range\n * @param {number} max The upper boundary of the output range\n * @returns {number} A number in the range [min, max]\n */\nfunction clampWrapper(value, min = 0, max = 1) {\n if (process.env.NODE_ENV !== 'production') {\n if (value < min || value > max) {\n console.error(`MUI: The value provided ${value} is out of range [${min}, ${max}].`);\n }\n }\n return clamp(value, min, max);\n}\n\n/**\n * Converts a color from CSS hex format to CSS rgb format.\n * @param {string} color - Hex color, i.e. #nnn or #nnnnnn\n * @returns {string} A CSS rgb color string\n */\nexport function hexToRgb(color) {\n color = color.slice(1);\n const re = new RegExp(`.{1,${color.length >= 6 ? 2 : 1}}`, 'g');\n let colors = color.match(re);\n if (colors && colors[0].length === 1) {\n colors = colors.map(n => n + n);\n }\n return colors ? `rgb${colors.length === 4 ? 'a' : ''}(${colors.map((n, index) => {\n return index < 3 ? parseInt(n, 16) : Math.round(parseInt(n, 16) / 255 * 1000) / 1000;\n }).join(', ')})` : '';\n}\nfunction intToHex(int) {\n const hex = int.toString(16);\n return hex.length === 1 ? `0${hex}` : hex;\n}\n\n/**\n * Returns an object with the type and values of a color.\n *\n * Note: Does not support rgb % values.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @returns {object} - A MUI color object: {type: string, values: number[]}\n */\nexport function decomposeColor(color) {\n // Idempotent\n if (color.type) {\n return color;\n }\n if (color.charAt(0) === '#') {\n return decomposeColor(hexToRgb(color));\n }\n const marker = color.indexOf('(');\n const type = color.substring(0, marker);\n if (['rgb', 'rgba', 'hsl', 'hsla', 'color'].indexOf(type) === -1) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: Unsupported \\`${color}\\` color.\nThe following formats are supported: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color().` : _formatMuiErrorMessage(9, color));\n }\n let values = color.substring(marker + 1, color.length - 1);\n let colorSpace;\n if (type === 'color') {\n values = values.split(' ');\n colorSpace = values.shift();\n if (values.length === 4 && values[3].charAt(0) === '/') {\n values[3] = values[3].slice(1);\n }\n if (['srgb', 'display-p3', 'a98-rgb', 'prophoto-rgb', 'rec-2020'].indexOf(colorSpace) === -1) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: unsupported \\`${colorSpace}\\` color space.\nThe following color spaces are supported: srgb, display-p3, a98-rgb, prophoto-rgb, rec-2020.` : _formatMuiErrorMessage(10, colorSpace));\n }\n } else {\n values = values.split(',');\n }\n values = values.map(value => parseFloat(value));\n return {\n type,\n values,\n colorSpace\n };\n}\n\n/**\n * Returns a channel created from the input color.\n *\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @returns {string} - The channel for the color, that can be used in rgba or hsla colors\n */\nexport const colorChannel = color => {\n const decomposedColor = decomposeColor(color);\n return decomposedColor.values.slice(0, 3).map((val, idx) => decomposedColor.type.indexOf('hsl') !== -1 && idx !== 0 ? `${val}%` : val).join(' ');\n};\nexport const private_safeColorChannel = (color, warning) => {\n try {\n return colorChannel(color);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n};\n\n/**\n * Converts a color object with type and values to a string.\n * @param {object} color - Decomposed color\n * @param {string} color.type - One of: 'rgb', 'rgba', 'hsl', 'hsla', 'color'\n * @param {array} color.values - [n,n,n] or [n,n,n,n]\n * @returns {string} A CSS color string\n */\nexport function recomposeColor(color) {\n const {\n type,\n colorSpace\n } = color;\n let {\n values\n } = color;\n if (type.indexOf('rgb') !== -1) {\n // Only convert the first 3 values to int (i.e. not alpha)\n values = values.map((n, i) => i < 3 ? parseInt(n, 10) : n);\n } else if (type.indexOf('hsl') !== -1) {\n values[1] = `${values[1]}%`;\n values[2] = `${values[2]}%`;\n }\n if (type.indexOf('color') !== -1) {\n values = `${colorSpace} ${values.join(' ')}`;\n } else {\n values = `${values.join(', ')}`;\n }\n return `${type}(${values})`;\n}\n\n/**\n * Converts a color from CSS rgb format to CSS hex format.\n * @param {string} color - RGB color, i.e. rgb(n, n, n)\n * @returns {string} A CSS rgb color string, i.e. #nnnnnn\n */\nexport function rgbToHex(color) {\n // Idempotent\n if (color.indexOf('#') === 0) {\n return color;\n }\n const {\n values\n } = decomposeColor(color);\n return `#${values.map((n, i) => intToHex(i === 3 ? Math.round(255 * n) : n)).join('')}`;\n}\n\n/**\n * Converts a color from hsl format to rgb format.\n * @param {string} color - HSL color values\n * @returns {string} rgb color values\n */\nexport function hslToRgb(color) {\n color = decomposeColor(color);\n const {\n values\n } = color;\n const h = values[0];\n const s = values[1] / 100;\n const l = values[2] / 100;\n const a = s * Math.min(l, 1 - l);\n const f = (n, k = (n + h / 30) % 12) => l - a * Math.max(Math.min(k - 3, 9 - k, 1), -1);\n let type = 'rgb';\n const rgb = [Math.round(f(0) * 255), Math.round(f(8) * 255), Math.round(f(4) * 255)];\n if (color.type === 'hsla') {\n type += 'a';\n rgb.push(values[3]);\n }\n return recomposeColor({\n type,\n values: rgb\n });\n}\n/**\n * The relative brightness of any point in a color space,\n * normalized to 0 for darkest black and 1 for lightest white.\n *\n * Formula: https://www.w3.org/TR/WCAG20-TECHS/G17.html#G17-tests\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @returns {number} The relative brightness of the color in the range 0 - 1\n */\nexport function getLuminance(color) {\n color = decomposeColor(color);\n let rgb = color.type === 'hsl' || color.type === 'hsla' ? decomposeColor(hslToRgb(color)).values : color.values;\n rgb = rgb.map(val => {\n if (color.type !== 'color') {\n val /= 255; // normalized\n }\n return val <= 0.03928 ? val / 12.92 : ((val + 0.055) / 1.055) ** 2.4;\n });\n\n // Truncate at 3 digits\n return Number((0.2126 * rgb[0] + 0.7152 * rgb[1] + 0.0722 * rgb[2]).toFixed(3));\n}\n\n/**\n * Calculates the contrast ratio between two colors.\n *\n * Formula: https://www.w3.org/TR/WCAG20-TECHS/G17.html#G17-tests\n * @param {string} foreground - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla()\n * @param {string} background - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla()\n * @returns {number} A contrast ratio value in the range 0 - 21.\n */\nexport function getContrastRatio(foreground, background) {\n const lumA = getLuminance(foreground);\n const lumB = getLuminance(background);\n return (Math.max(lumA, lumB) + 0.05) / (Math.min(lumA, lumB) + 0.05);\n}\n\n/**\n * Sets the absolute transparency of a color.\n * Any existing alpha values are overwritten.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} value - value to set the alpha channel to in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function alpha(color, value) {\n color = decomposeColor(color);\n value = clampWrapper(value);\n if (color.type === 'rgb' || color.type === 'hsl') {\n color.type += 'a';\n }\n if (color.type === 'color') {\n color.values[3] = `/${value}`;\n } else {\n color.values[3] = value;\n }\n return recomposeColor(color);\n}\nexport function private_safeAlpha(color, value, warning) {\n try {\n return alpha(color, value);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Darkens a color.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} coefficient - multiplier in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function darken(color, coefficient) {\n color = decomposeColor(color);\n coefficient = clampWrapper(coefficient);\n if (color.type.indexOf('hsl') !== -1) {\n color.values[2] *= 1 - coefficient;\n } else if (color.type.indexOf('rgb') !== -1 || color.type.indexOf('color') !== -1) {\n for (let i = 0; i < 3; i += 1) {\n color.values[i] *= 1 - coefficient;\n }\n }\n return recomposeColor(color);\n}\nexport function private_safeDarken(color, coefficient, warning) {\n try {\n return darken(color, coefficient);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Lightens a color.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} coefficient - multiplier in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function lighten(color, coefficient) {\n color = decomposeColor(color);\n coefficient = clampWrapper(coefficient);\n if (color.type.indexOf('hsl') !== -1) {\n color.values[2] += (100 - color.values[2]) * coefficient;\n } else if (color.type.indexOf('rgb') !== -1) {\n for (let i = 0; i < 3; i += 1) {\n color.values[i] += (255 - color.values[i]) * coefficient;\n }\n } else if (color.type.indexOf('color') !== -1) {\n for (let i = 0; i < 3; i += 1) {\n color.values[i] += (1 - color.values[i]) * coefficient;\n }\n }\n return recomposeColor(color);\n}\nexport function private_safeLighten(color, coefficient, warning) {\n try {\n return lighten(color, coefficient);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Darken or lighten a color, depending on its luminance.\n * Light colors are darkened, dark colors are lightened.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} coefficient=0.15 - multiplier in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function emphasize(color, coefficient = 0.15) {\n return getLuminance(color) > 0.5 ? darken(color, coefficient) : lighten(color, coefficient);\n}\nexport function private_safeEmphasize(color, coefficient, warning) {\n try {\n return emphasize(color, coefficient);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Blend a transparent overlay color with a background color, resulting in a single\n * RGB color.\n * @param {string} background - CSS color\n * @param {string} overlay - CSS color\n * @param {number} opacity - Opacity multiplier in the range 0 - 1\n * @param {number} [gamma=1.0] - Gamma correction factor. For gamma-correct blending, 2.2 is usual.\n */\nexport function blend(background, overlay, opacity, gamma = 1.0) {\n const blendChannel = (b, o) => Math.round((b ** (1 / gamma) * (1 - opacity) + o ** (1 / gamma) * opacity) ** gamma);\n const backgroundColor = decomposeColor(background);\n const overlayColor = decomposeColor(overlay);\n const rgb = [blendChannel(backgroundColor.values[0], overlayColor.values[0]), blendChannel(backgroundColor.values[1], overlayColor.values[1]), blendChannel(backgroundColor.values[2], overlayColor.values[2])];\n return recomposeColor({\n type: 'rgb',\n values: rgb\n });\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nexport default function createMixins(breakpoints, mixins) {\n return _extends({\n toolbar: {\n minHeight: 56,\n [breakpoints.up('xs')]: {\n '@media (orientation: landscape)': {\n minHeight: 48\n }\n },\n [breakpoints.up('sm')]: {\n minHeight: 64\n }\n }\n }, mixins);\n}","const common = {\n black: '#000',\n white: '#fff'\n};\nexport default common;","const grey = {\n 50: '#fafafa',\n 100: '#f5f5f5',\n 200: '#eeeeee',\n 300: '#e0e0e0',\n 400: '#bdbdbd',\n 500: '#9e9e9e',\n 600: '#757575',\n 700: '#616161',\n 800: '#424242',\n 900: '#212121',\n A100: '#f5f5f5',\n A200: '#eeeeee',\n A400: '#bdbdbd',\n A700: '#616161'\n};\nexport default grey;","const purple = {\n 50: '#f3e5f5',\n 100: '#e1bee7',\n 200: '#ce93d8',\n 300: '#ba68c8',\n 400: '#ab47bc',\n 500: '#9c27b0',\n 600: '#8e24aa',\n 700: '#7b1fa2',\n 800: '#6a1b9a',\n 900: '#4a148c',\n A100: '#ea80fc',\n A200: '#e040fb',\n A400: '#d500f9',\n A700: '#aa00ff'\n};\nexport default purple;","const red = {\n 50: '#ffebee',\n 100: '#ffcdd2',\n 200: '#ef9a9a',\n 300: '#e57373',\n 400: '#ef5350',\n 500: '#f44336',\n 600: '#e53935',\n 700: '#d32f2f',\n 800: '#c62828',\n 900: '#b71c1c',\n A100: '#ff8a80',\n A200: '#ff5252',\n A400: '#ff1744',\n A700: '#d50000'\n};\nexport default red;","const orange = {\n 50: '#fff3e0',\n 100: '#ffe0b2',\n 200: '#ffcc80',\n 300: '#ffb74d',\n 400: '#ffa726',\n 500: '#ff9800',\n 600: '#fb8c00',\n 700: '#f57c00',\n 800: '#ef6c00',\n 900: '#e65100',\n A100: '#ffd180',\n A200: '#ffab40',\n A400: '#ff9100',\n A700: '#ff6d00'\n};\nexport default orange;","const blue = {\n 50: '#e3f2fd',\n 100: '#bbdefb',\n 200: '#90caf9',\n 300: '#64b5f6',\n 400: '#42a5f5',\n 500: '#2196f3',\n 600: '#1e88e5',\n 700: '#1976d2',\n 800: '#1565c0',\n 900: '#0d47a1',\n A100: '#82b1ff',\n A200: '#448aff',\n A400: '#2979ff',\n A700: '#2962ff'\n};\nexport default blue;","const lightBlue = {\n 50: '#e1f5fe',\n 100: '#b3e5fc',\n 200: '#81d4fa',\n 300: '#4fc3f7',\n 400: '#29b6f6',\n 500: '#03a9f4',\n 600: '#039be5',\n 700: '#0288d1',\n 800: '#0277bd',\n 900: '#01579b',\n A100: '#80d8ff',\n A200: '#40c4ff',\n A400: '#00b0ff',\n A700: '#0091ea'\n};\nexport default lightBlue;","const green = {\n 50: '#e8f5e9',\n 100: '#c8e6c9',\n 200: '#a5d6a7',\n 300: '#81c784',\n 400: '#66bb6a',\n 500: '#4caf50',\n 600: '#43a047',\n 700: '#388e3c',\n 800: '#2e7d32',\n 900: '#1b5e20',\n A100: '#b9f6ca',\n A200: '#69f0ae',\n A400: '#00e676',\n A700: '#00c853'\n};\nexport default green;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\nconst _excluded = [\"mode\", \"contrastThreshold\", \"tonalOffset\"];\nimport { deepmerge } from '@mui/utils';\nimport { darken, getContrastRatio, lighten } from '@mui/system';\nimport common from '../colors/common';\nimport grey from '../colors/grey';\nimport purple from '../colors/purple';\nimport red from '../colors/red';\nimport orange from '../colors/orange';\nimport blue from '../colors/blue';\nimport lightBlue from '../colors/lightBlue';\nimport green from '../colors/green';\nexport const light = {\n // The colors used to style the text.\n text: {\n // The most important text.\n primary: 'rgba(0, 0, 0, 0.87)',\n // Secondary text.\n secondary: 'rgba(0, 0, 0, 0.6)',\n // Disabled text have even lower visual prominence.\n disabled: 'rgba(0, 0, 0, 0.38)'\n },\n // The color used to divide different elements.\n divider: 'rgba(0, 0, 0, 0.12)',\n // The background colors used to style the surfaces.\n // Consistency between these values is important.\n background: {\n paper: common.white,\n default: common.white\n },\n // The colors used to style the action elements.\n action: {\n // The color of an active action like an icon button.\n active: 'rgba(0, 0, 0, 0.54)',\n // The color of an hovered action.\n hover: 'rgba(0, 0, 0, 0.04)',\n hoverOpacity: 0.04,\n // The color of a selected action.\n selected: 'rgba(0, 0, 0, 0.08)',\n selectedOpacity: 0.08,\n // The color of a disabled action.\n disabled: 'rgba(0, 0, 0, 0.26)',\n // The background color of a disabled action.\n disabledBackground: 'rgba(0, 0, 0, 0.12)',\n disabledOpacity: 0.38,\n focus: 'rgba(0, 0, 0, 0.12)',\n focusOpacity: 0.12,\n activatedOpacity: 0.12\n }\n};\nexport const dark = {\n text: {\n primary: common.white,\n secondary: 'rgba(255, 255, 255, 0.7)',\n disabled: 'rgba(255, 255, 255, 0.5)',\n icon: 'rgba(255, 255, 255, 0.5)'\n },\n divider: 'rgba(255, 255, 255, 0.12)',\n background: {\n paper: '#121212',\n default: '#121212'\n },\n action: {\n active: common.white,\n hover: 'rgba(255, 255, 255, 0.08)',\n hoverOpacity: 0.08,\n selected: 'rgba(255, 255, 255, 0.16)',\n selectedOpacity: 0.16,\n disabled: 'rgba(255, 255, 255, 0.3)',\n disabledBackground: 'rgba(255, 255, 255, 0.12)',\n disabledOpacity: 0.38,\n focus: 'rgba(255, 255, 255, 0.12)',\n focusOpacity: 0.12,\n activatedOpacity: 0.24\n }\n};\nfunction addLightOrDark(intent, direction, shade, tonalOffset) {\n const tonalOffsetLight = tonalOffset.light || tonalOffset;\n const tonalOffsetDark = tonalOffset.dark || tonalOffset * 1.5;\n if (!intent[direction]) {\n if (intent.hasOwnProperty(shade)) {\n intent[direction] = intent[shade];\n } else if (direction === 'light') {\n intent.light = lighten(intent.main, tonalOffsetLight);\n } else if (direction === 'dark') {\n intent.dark = darken(intent.main, tonalOffsetDark);\n }\n }\n}\nfunction getDefaultPrimary(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: blue[200],\n light: blue[50],\n dark: blue[400]\n };\n }\n return {\n main: blue[700],\n light: blue[400],\n dark: blue[800]\n };\n}\nfunction getDefaultSecondary(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: purple[200],\n light: purple[50],\n dark: purple[400]\n };\n }\n return {\n main: purple[500],\n light: purple[300],\n dark: purple[700]\n };\n}\nfunction getDefaultError(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: red[500],\n light: red[300],\n dark: red[700]\n };\n }\n return {\n main: red[700],\n light: red[400],\n dark: red[800]\n };\n}\nfunction getDefaultInfo(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: lightBlue[400],\n light: lightBlue[300],\n dark: lightBlue[700]\n };\n }\n return {\n main: lightBlue[700],\n light: lightBlue[500],\n dark: lightBlue[900]\n };\n}\nfunction getDefaultSuccess(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: green[400],\n light: green[300],\n dark: green[700]\n };\n }\n return {\n main: green[800],\n light: green[500],\n dark: green[900]\n };\n}\nfunction getDefaultWarning(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: orange[400],\n light: orange[300],\n dark: orange[700]\n };\n }\n return {\n main: '#ed6c02',\n // closest to orange[800] that pass 3:1.\n light: orange[500],\n dark: orange[900]\n };\n}\nexport default function createPalette(palette) {\n const {\n mode = 'light',\n contrastThreshold = 3,\n tonalOffset = 0.2\n } = palette,\n other = _objectWithoutPropertiesLoose(palette, _excluded);\n const primary = palette.primary || getDefaultPrimary(mode);\n const secondary = palette.secondary || getDefaultSecondary(mode);\n const error = palette.error || getDefaultError(mode);\n const info = palette.info || getDefaultInfo(mode);\n const success = palette.success || getDefaultSuccess(mode);\n const warning = palette.warning || getDefaultWarning(mode);\n\n // Use the same logic as\n // Bootstrap: https://github.com/twbs/bootstrap/blob/1d6e3710dd447de1a200f29e8fa521f8a0908f70/scss/_functions.scss#L59\n // and material-components-web https://github.com/material-components/material-components-web/blob/ac46b8863c4dab9fc22c4c662dc6bd1b65dd652f/packages/mdc-theme/_functions.scss#L54\n function getContrastText(background) {\n const contrastText = getContrastRatio(background, dark.text.primary) >= contrastThreshold ? dark.text.primary : light.text.primary;\n if (process.env.NODE_ENV !== 'production') {\n const contrast = getContrastRatio(background, contrastText);\n if (contrast < 3) {\n console.error([`MUI: The contrast ratio of ${contrast}:1 for ${contrastText} on ${background}`, 'falls below the WCAG recommended absolute minimum contrast ratio of 3:1.', 'https://www.w3.org/TR/2008/REC-WCAG20-20081211/#visual-audio-contrast-contrast'].join('\\n'));\n }\n }\n return contrastText;\n }\n const augmentColor = ({\n color,\n name,\n mainShade = 500,\n lightShade = 300,\n darkShade = 700\n }) => {\n color = _extends({}, color);\n if (!color.main && color[mainShade]) {\n color.main = color[mainShade];\n }\n if (!color.hasOwnProperty('main')) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: The color${name ? ` (${name})` : ''} provided to augmentColor(color) is invalid.\nThe color object needs to have a \\`main\\` property or a \\`${mainShade}\\` property.` : _formatMuiErrorMessage(11, name ? ` (${name})` : '', mainShade));\n }\n if (typeof color.main !== 'string') {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: The color${name ? ` (${name})` : ''} provided to augmentColor(color) is invalid.\n\\`color.main\\` should be a string, but \\`${JSON.stringify(color.main)}\\` was provided instead.\n\nDid you intend to use one of the following approaches?\n\nimport { green } from \"@mui/material/colors\";\n\nconst theme1 = createTheme({ palette: {\n primary: green,\n} });\n\nconst theme2 = createTheme({ palette: {\n primary: { main: green[500] },\n} });` : _formatMuiErrorMessage(12, name ? ` (${name})` : '', JSON.stringify(color.main)));\n }\n addLightOrDark(color, 'light', lightShade, tonalOffset);\n addLightOrDark(color, 'dark', darkShade, tonalOffset);\n if (!color.contrastText) {\n color.contrastText = getContrastText(color.main);\n }\n return color;\n };\n const modes = {\n dark,\n light\n };\n if (process.env.NODE_ENV !== 'production') {\n if (!modes[mode]) {\n console.error(`MUI: The palette mode \\`${mode}\\` is not supported.`);\n }\n }\n const paletteOutput = deepmerge(_extends({\n // A collection of common colors.\n common: _extends({}, common),\n // prevent mutable object.\n // The palette mode, can be light or dark.\n mode,\n // The colors used to represent primary interface elements for a user.\n primary: augmentColor({\n color: primary,\n name: 'primary'\n }),\n // The colors used to represent secondary interface elements for a user.\n secondary: augmentColor({\n color: secondary,\n name: 'secondary',\n mainShade: 'A400',\n lightShade: 'A200',\n darkShade: 'A700'\n }),\n // The colors used to represent interface elements that the user should be made aware of.\n error: augmentColor({\n color: error,\n name: 'error'\n }),\n // The colors used to represent potentially dangerous actions or important messages.\n warning: augmentColor({\n color: warning,\n name: 'warning'\n }),\n // The colors used to present information to the user that is neutral and not necessarily important.\n info: augmentColor({\n color: info,\n name: 'info'\n }),\n // The colors used to indicate the successful completion of an action that user triggered.\n success: augmentColor({\n color: success,\n name: 'success'\n }),\n // The grey colors.\n grey,\n // Used by `getContrastText()` to maximize the contrast between\n // the background and the text.\n contrastThreshold,\n // Takes a background color and returns the text color that maximizes the contrast.\n getContrastText,\n // Generate a rich color object.\n augmentColor,\n // Used by the functions below to shift a color's luminance by approximately\n // two indexes within its tonal palette.\n // E.g., shift from Red 500 to Red 300 or Red 700.\n tonalOffset\n }, modes[mode]), other);\n return paletteOutput;\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"fontFamily\", \"fontSize\", \"fontWeightLight\", \"fontWeightRegular\", \"fontWeightMedium\", \"fontWeightBold\", \"htmlFontSize\", \"allVariants\", \"pxToRem\"];\nimport { deepmerge } from '@mui/utils';\nfunction round(value) {\n return Math.round(value * 1e5) / 1e5;\n}\nconst caseAllCaps = {\n textTransform: 'uppercase'\n};\nconst defaultFontFamily = '\"Roboto\", \"Helvetica\", \"Arial\", sans-serif';\n\n/**\n * @see @link{https://m2.material.io/design/typography/the-type-system.html}\n * @see @link{https://m2.material.io/design/typography/understanding-typography.html}\n */\nexport default function createTypography(palette, typography) {\n const _ref = typeof typography === 'function' ? typography(palette) : typography,\n {\n fontFamily = defaultFontFamily,\n // The default font size of the Material Specification.\n fontSize = 14,\n // px\n fontWeightLight = 300,\n fontWeightRegular = 400,\n fontWeightMedium = 500,\n fontWeightBold = 700,\n // Tell MUI what's the font-size on the html element.\n // 16px is the default font-size used by browsers.\n htmlFontSize = 16,\n // Apply the CSS properties to all the variants.\n allVariants,\n pxToRem: pxToRem2\n } = _ref,\n other = _objectWithoutPropertiesLoose(_ref, _excluded);\n if (process.env.NODE_ENV !== 'production') {\n if (typeof fontSize !== 'number') {\n console.error('MUI: `fontSize` is required to be a number.');\n }\n if (typeof htmlFontSize !== 'number') {\n console.error('MUI: `htmlFontSize` is required to be a number.');\n }\n }\n const coef = fontSize / 14;\n const pxToRem = pxToRem2 || (size => `${size / htmlFontSize * coef}rem`);\n const buildVariant = (fontWeight, size, lineHeight, letterSpacing, casing) => _extends({\n fontFamily,\n fontWeight,\n fontSize: pxToRem(size),\n // Unitless following https://meyerweb.com/eric/thoughts/2006/02/08/unitless-line-heights/\n lineHeight\n }, fontFamily === defaultFontFamily ? {\n letterSpacing: `${round(letterSpacing / size)}em`\n } : {}, casing, allVariants);\n const variants = {\n h1: buildVariant(fontWeightLight, 96, 1.167, -1.5),\n h2: buildVariant(fontWeightLight, 60, 1.2, -0.5),\n h3: buildVariant(fontWeightRegular, 48, 1.167, 0),\n h4: buildVariant(fontWeightRegular, 34, 1.235, 0.25),\n h5: buildVariant(fontWeightRegular, 24, 1.334, 0),\n h6: buildVariant(fontWeightMedium, 20, 1.6, 0.15),\n subtitle1: buildVariant(fontWeightRegular, 16, 1.75, 0.15),\n subtitle2: buildVariant(fontWeightMedium, 14, 1.57, 0.1),\n body1: buildVariant(fontWeightRegular, 16, 1.5, 0.15),\n body2: buildVariant(fontWeightRegular, 14, 1.43, 0.15),\n button: buildVariant(fontWeightMedium, 14, 1.75, 0.4, caseAllCaps),\n caption: buildVariant(fontWeightRegular, 12, 1.66, 0.4),\n overline: buildVariant(fontWeightRegular, 12, 2.66, 1, caseAllCaps),\n // TODO v6: Remove handling of 'inherit' variant from the theme as it is already handled in Material UI's Typography component. Also, remember to remove the associated types.\n inherit: {\n fontFamily: 'inherit',\n fontWeight: 'inherit',\n fontSize: 'inherit',\n lineHeight: 'inherit',\n letterSpacing: 'inherit'\n }\n };\n return deepmerge(_extends({\n htmlFontSize,\n pxToRem,\n fontFamily,\n fontSize,\n fontWeightLight,\n fontWeightRegular,\n fontWeightMedium,\n fontWeightBold\n }, variants), other, {\n clone: false // No need to clone deep\n });\n}","const shadowKeyUmbraOpacity = 0.2;\nconst shadowKeyPenumbraOpacity = 0.14;\nconst shadowAmbientShadowOpacity = 0.12;\nfunction createShadow(...px) {\n return [`${px[0]}px ${px[1]}px ${px[2]}px ${px[3]}px rgba(0,0,0,${shadowKeyUmbraOpacity})`, `${px[4]}px ${px[5]}px ${px[6]}px ${px[7]}px rgba(0,0,0,${shadowKeyPenumbraOpacity})`, `${px[8]}px ${px[9]}px ${px[10]}px ${px[11]}px rgba(0,0,0,${shadowAmbientShadowOpacity})`].join(',');\n}\n\n// Values from https://github.com/material-components/material-components-web/blob/be8747f94574669cb5e7add1a7c54fa41a89cec7/packages/mdc-elevation/_variables.scss\nconst shadows = ['none', createShadow(0, 2, 1, -1, 0, 1, 1, 0, 0, 1, 3, 0), createShadow(0, 3, 1, -2, 0, 2, 2, 0, 0, 1, 5, 0), createShadow(0, 3, 3, -2, 0, 3, 4, 0, 0, 1, 8, 0), createShadow(0, 2, 4, -1, 0, 4, 5, 0, 0, 1, 10, 0), createShadow(0, 3, 5, -1, 0, 5, 8, 0, 0, 1, 14, 0), createShadow(0, 3, 5, -1, 0, 6, 10, 0, 0, 1, 18, 0), createShadow(0, 4, 5, -2, 0, 7, 10, 1, 0, 2, 16, 1), createShadow(0, 5, 5, -3, 0, 8, 10, 1, 0, 3, 14, 2), createShadow(0, 5, 6, -3, 0, 9, 12, 1, 0, 3, 16, 2), createShadow(0, 6, 6, -3, 0, 10, 14, 1, 0, 4, 18, 3), createShadow(0, 6, 7, -4, 0, 11, 15, 1, 0, 4, 20, 3), createShadow(0, 7, 8, -4, 0, 12, 17, 2, 0, 5, 22, 4), createShadow(0, 7, 8, -4, 0, 13, 19, 2, 0, 5, 24, 4), createShadow(0, 7, 9, -4, 0, 14, 21, 2, 0, 5, 26, 4), createShadow(0, 8, 9, -5, 0, 15, 22, 2, 0, 6, 28, 5), createShadow(0, 8, 10, -5, 0, 16, 24, 2, 0, 6, 30, 5), createShadow(0, 8, 11, -5, 0, 17, 26, 2, 0, 6, 32, 5), createShadow(0, 9, 11, -5, 0, 18, 28, 2, 0, 7, 34, 6), createShadow(0, 9, 12, -6, 0, 19, 29, 2, 0, 7, 36, 6), createShadow(0, 10, 13, -6, 0, 20, 31, 3, 0, 8, 38, 7), createShadow(0, 10, 13, -6, 0, 21, 33, 3, 0, 8, 40, 7), createShadow(0, 10, 14, -6, 0, 22, 35, 3, 0, 8, 42, 7), createShadow(0, 11, 14, -7, 0, 23, 36, 3, 0, 9, 44, 8), createShadow(0, 11, 15, -7, 0, 24, 38, 3, 0, 9, 46, 8)];\nexport default shadows;","import _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nconst _excluded = [\"duration\", \"easing\", \"delay\"];\n// Follow https://material.google.com/motion/duration-easing.html#duration-easing-natural-easing-curves\n// to learn the context in which each easing should be used.\nexport const easing = {\n // This is the most common easing curve.\n easeInOut: 'cubic-bezier(0.4, 0, 0.2, 1)',\n // Objects enter the screen at full velocity from off-screen and\n // slowly decelerate to a resting point.\n easeOut: 'cubic-bezier(0.0, 0, 0.2, 1)',\n // Objects leave the screen at full velocity. They do not decelerate when off-screen.\n easeIn: 'cubic-bezier(0.4, 0, 1, 1)',\n // The sharp curve is used by objects that may return to the screen at any time.\n sharp: 'cubic-bezier(0.4, 0, 0.6, 1)'\n};\n\n// Follow https://m2.material.io/guidelines/motion/duration-easing.html#duration-easing-common-durations\n// to learn when use what timing\nexport const duration = {\n shortest: 150,\n shorter: 200,\n short: 250,\n // most basic recommended timing\n standard: 300,\n // this is to be used in complex animations\n complex: 375,\n // recommended when something is entering screen\n enteringScreen: 225,\n // recommended when something is leaving screen\n leavingScreen: 195\n};\nfunction formatMs(milliseconds) {\n return `${Math.round(milliseconds)}ms`;\n}\nfunction getAutoHeightDuration(height) {\n if (!height) {\n return 0;\n }\n const constant = height / 36;\n\n // https://www.wolframalpha.com/input/?i=(4+%2B+15+*+(x+%2F+36+)+**+0.25+%2B+(x+%2F+36)+%2F+5)+*+10\n return Math.round((4 + 15 * constant ** 0.25 + constant / 5) * 10);\n}\nexport default function createTransitions(inputTransitions) {\n const mergedEasing = _extends({}, easing, inputTransitions.easing);\n const mergedDuration = _extends({}, duration, inputTransitions.duration);\n const create = (props = ['all'], options = {}) => {\n const {\n duration: durationOption = mergedDuration.standard,\n easing: easingOption = mergedEasing.easeInOut,\n delay = 0\n } = options,\n other = _objectWithoutPropertiesLoose(options, _excluded);\n if (process.env.NODE_ENV !== 'production') {\n const isString = value => typeof value === 'string';\n // IE11 support, replace with Number.isNaN\n // eslint-disable-next-line no-restricted-globals\n const isNumber = value => !isNaN(parseFloat(value));\n if (!isString(props) && !Array.isArray(props)) {\n console.error('MUI: Argument \"props\" must be a string or Array.');\n }\n if (!isNumber(durationOption) && !isString(durationOption)) {\n console.error(`MUI: Argument \"duration\" must be a number or a string but found ${durationOption}.`);\n }\n if (!isString(easingOption)) {\n console.error('MUI: Argument \"easing\" must be a string.');\n }\n if (!isNumber(delay) && !isString(delay)) {\n console.error('MUI: Argument \"delay\" must be a number or a string.');\n }\n if (typeof options !== 'object') {\n console.error(['MUI: Secong argument of transition.create must be an object.', \"Arguments should be either `create('prop1', options)` or `create(['prop1', 'prop2'], options)`\"].join('\\n'));\n }\n if (Object.keys(other).length !== 0) {\n console.error(`MUI: Unrecognized argument(s) [${Object.keys(other).join(',')}].`);\n }\n }\n return (Array.isArray(props) ? props : [props]).map(animatedProp => `${animatedProp} ${typeof durationOption === 'string' ? durationOption : formatMs(durationOption)} ${easingOption} ${typeof delay === 'string' ? delay : formatMs(delay)}`).join(',');\n };\n return _extends({\n getAutoHeightDuration,\n create\n }, inputTransitions, {\n easing: mergedEasing,\n duration: mergedDuration\n });\n}","// We need to centralize the zIndex definitions as they work\n// like global values in the browser.\nconst zIndex = {\n mobileStepper: 1000,\n fab: 1050,\n speedDial: 1050,\n appBar: 1100,\n drawer: 1200,\n modal: 1300,\n snackbar: 1400,\n tooltip: 1500\n};\nexport default zIndex;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\nconst _excluded = [\"breakpoints\", \"mixins\", \"spacing\", \"palette\", \"transitions\", \"typography\", \"shape\"];\nimport { deepmerge } from '@mui/utils';\nimport { createTheme as systemCreateTheme, unstable_defaultSxConfig as defaultSxConfig, unstable_styleFunctionSx as styleFunctionSx } from '@mui/system';\nimport generateUtilityClass from '@mui/utils/generateUtilityClass';\nimport createMixins from './createMixins';\nimport createPalette from './createPalette';\nimport createTypography from './createTypography';\nimport shadows from './shadows';\nimport createTransitions from './createTransitions';\nimport zIndex from './zIndex';\nfunction createTheme(options = {}, ...args) {\n const {\n mixins: mixinsInput = {},\n palette: paletteInput = {},\n transitions: transitionsInput = {},\n typography: typographyInput = {}\n } = options,\n other = _objectWithoutPropertiesLoose(options, _excluded);\n if (options.vars) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: \\`vars\\` is a private field used for CSS variables support.\nPlease use another name.` : _formatMuiErrorMessage(18));\n }\n const palette = createPalette(paletteInput);\n const systemTheme = systemCreateTheme(options);\n let muiTheme = deepmerge(systemTheme, {\n mixins: createMixins(systemTheme.breakpoints, mixinsInput),\n palette,\n // Don't use [...shadows] until you've verified its transpiled code is not invoking the iterator protocol.\n shadows: shadows.slice(),\n typography: createTypography(palette, typographyInput),\n transitions: createTransitions(transitionsInput),\n zIndex: _extends({}, zIndex)\n });\n muiTheme = deepmerge(muiTheme, other);\n muiTheme = args.reduce((acc, argument) => deepmerge(acc, argument), muiTheme);\n if (process.env.NODE_ENV !== 'production') {\n // TODO v6: Refactor to use globalStateClassesMapping from @mui/utils once `readOnly` state class is used in Rating component.\n const stateClasses = ['active', 'checked', 'completed', 'disabled', 'error', 'expanded', 'focused', 'focusVisible', 'required', 'selected'];\n const traverse = (node, component) => {\n let key;\n\n // eslint-disable-next-line guard-for-in, no-restricted-syntax\n for (key in node) {\n const child = node[key];\n if (stateClasses.indexOf(key) !== -1 && Object.keys(child).length > 0) {\n if (process.env.NODE_ENV !== 'production') {\n const stateClass = generateUtilityClass('', key);\n console.error([`MUI: The \\`${component}\\` component increases ` + `the CSS specificity of the \\`${key}\\` internal state.`, 'You can not override it like this: ', JSON.stringify(node, null, 2), '', `Instead, you need to use the '&.${stateClass}' syntax:`, JSON.stringify({\n root: {\n [`&.${stateClass}`]: child\n }\n }, null, 2), '', 'https://mui.com/r/state-classes-guide'].join('\\n'));\n }\n // Remove the style to prevent global conflicts.\n node[key] = {};\n }\n }\n };\n Object.keys(muiTheme.components).forEach(component => {\n const styleOverrides = muiTheme.components[component].styleOverrides;\n if (styleOverrides && component.indexOf('Mui') === 0) {\n traverse(styleOverrides, component);\n }\n });\n }\n muiTheme.unstable_sxConfig = _extends({}, defaultSxConfig, other == null ? void 0 : other.unstable_sxConfig);\n muiTheme.unstable_sx = function sx(props) {\n return styleFunctionSx({\n sx: props,\n theme: this\n });\n };\n return muiTheme;\n}\nlet warnedOnce = false;\nexport function createMuiTheme(...args) {\n if (process.env.NODE_ENV !== 'production') {\n if (!warnedOnce) {\n warnedOnce = true;\n console.error(['MUI: the createMuiTheme function was renamed to createTheme.', '', \"You should use `import { createTheme } from '@mui/material/styles'`\"].join('\\n'));\n }\n }\n return createTheme(...args);\n}\nexport default createTheme;","'use client';\n\nimport createTheme from './createTheme';\nconst defaultTheme = createTheme();\nexport default defaultTheme;","export default '$$material';","'use client';\n\nimport { useThemeProps as systemUseThemeProps } from '@mui/system';\nimport defaultTheme from './defaultTheme';\nimport THEME_ID from './identifier';\nexport default function useThemeProps({\n props,\n name\n}) {\n return systemUseThemeProps({\n props,\n name,\n defaultTheme,\n themeId: THEME_ID\n });\n}","'use client';\n\nimport { createStyled, shouldForwardProp } from '@mui/system';\nimport defaultTheme from './defaultTheme';\nimport THEME_ID from './identifier';\nexport const rootShouldForwardProp = prop => shouldForwardProp(prop) && prop !== 'classes';\nexport const slotShouldForwardProp = shouldForwardProp;\nconst styled = createStyled({\n themeId: THEME_ID,\n defaultTheme,\n rootShouldForwardProp\n});\nexport default styled;","import generateUtilityClasses from '@mui/utils/generateUtilityClasses';\nimport generateUtilityClass from '@mui/utils/generateUtilityClass';\nexport function getSvgIconUtilityClass(slot) {\n return generateUtilityClass('MuiSvgIcon', slot);\n}\nconst svgIconClasses = generateUtilityClasses('MuiSvgIcon', ['root', 'colorPrimary', 'colorSecondary', 'colorAction', 'colorError', 'colorDisabled', 'fontSizeInherit', 'fontSizeSmall', 'fontSizeMedium', 'fontSizeLarge']);\nexport default svgIconClasses;","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"children\", \"className\", \"color\", \"component\", \"fontSize\", \"htmlColor\", \"inheritViewBox\", \"titleAccess\", \"viewBox\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport clsx from 'clsx';\nimport { unstable_composeClasses as composeClasses } from '@mui/base/composeClasses';\nimport capitalize from '../utils/capitalize';\nimport useThemeProps from '../styles/useThemeProps';\nimport styled from '../styles/styled';\nimport { getSvgIconUtilityClass } from './svgIconClasses';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nimport { jsxs as _jsxs } from \"react/jsx-runtime\";\nconst useUtilityClasses = ownerState => {\n const {\n color,\n fontSize,\n classes\n } = ownerState;\n const slots = {\n root: ['root', color !== 'inherit' && `color${capitalize(color)}`, `fontSize${capitalize(fontSize)}`]\n };\n return composeClasses(slots, getSvgIconUtilityClass, classes);\n};\nconst SvgIconRoot = styled('svg', {\n name: 'MuiSvgIcon',\n slot: 'Root',\n overridesResolver: (props, styles) => {\n const {\n ownerState\n } = props;\n return [styles.root, ownerState.color !== 'inherit' && styles[`color${capitalize(ownerState.color)}`], styles[`fontSize${capitalize(ownerState.fontSize)}`]];\n }\n})(({\n theme,\n ownerState\n}) => {\n var _theme$transitions, _theme$transitions$cr, _theme$transitions2, _theme$typography, _theme$typography$pxT, _theme$typography2, _theme$typography2$px, _theme$typography3, _theme$typography3$px, _palette$ownerState$c, _palette, _palette2, _palette3;\n return {\n userSelect: 'none',\n width: '1em',\n height: '1em',\n display: 'inline-block',\n // the will define the property that has `currentColor`\n // e.g. heroicons uses fill=\"none\" and stroke=\"currentColor\"\n fill: ownerState.hasSvgAsChild ? undefined : 'currentColor',\n flexShrink: 0,\n transition: (_theme$transitions = theme.transitions) == null || (_theme$transitions$cr = _theme$transitions.create) == null ? void 0 : _theme$transitions$cr.call(_theme$transitions, 'fill', {\n duration: (_theme$transitions2 = theme.transitions) == null || (_theme$transitions2 = _theme$transitions2.duration) == null ? void 0 : _theme$transitions2.shorter\n }),\n fontSize: {\n inherit: 'inherit',\n small: ((_theme$typography = theme.typography) == null || (_theme$typography$pxT = _theme$typography.pxToRem) == null ? void 0 : _theme$typography$pxT.call(_theme$typography, 20)) || '1.25rem',\n medium: ((_theme$typography2 = theme.typography) == null || (_theme$typography2$px = _theme$typography2.pxToRem) == null ? void 0 : _theme$typography2$px.call(_theme$typography2, 24)) || '1.5rem',\n large: ((_theme$typography3 = theme.typography) == null || (_theme$typography3$px = _theme$typography3.pxToRem) == null ? void 0 : _theme$typography3$px.call(_theme$typography3, 35)) || '2.1875rem'\n }[ownerState.fontSize],\n // TODO v5 deprecate, v6 remove for sx\n color: (_palette$ownerState$c = (_palette = (theme.vars || theme).palette) == null || (_palette = _palette[ownerState.color]) == null ? void 0 : _palette.main) != null ? _palette$ownerState$c : {\n action: (_palette2 = (theme.vars || theme).palette) == null || (_palette2 = _palette2.action) == null ? void 0 : _palette2.active,\n disabled: (_palette3 = (theme.vars || theme).palette) == null || (_palette3 = _palette3.action) == null ? void 0 : _palette3.disabled,\n inherit: undefined\n }[ownerState.color]\n };\n});\nconst SvgIcon = /*#__PURE__*/React.forwardRef(function SvgIcon(inProps, ref) {\n const props = useThemeProps({\n props: inProps,\n name: 'MuiSvgIcon'\n });\n const {\n children,\n className,\n color = 'inherit',\n component = 'svg',\n fontSize = 'medium',\n htmlColor,\n inheritViewBox = false,\n titleAccess,\n viewBox = '0 0 24 24'\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const hasSvgAsChild = /*#__PURE__*/React.isValidElement(children) && children.type === 'svg';\n const ownerState = _extends({}, props, {\n color,\n component,\n fontSize,\n instanceFontSize: inProps.fontSize,\n inheritViewBox,\n viewBox,\n hasSvgAsChild\n });\n const more = {};\n if (!inheritViewBox) {\n more.viewBox = viewBox;\n }\n const classes = useUtilityClasses(ownerState);\n return /*#__PURE__*/_jsxs(SvgIconRoot, _extends({\n as: component,\n className: clsx(classes.root, className),\n focusable: \"false\",\n color: htmlColor,\n \"aria-hidden\": titleAccess ? undefined : true,\n role: titleAccess ? 'img' : undefined,\n ref: ref\n }, more, other, hasSvgAsChild && children.props, {\n ownerState: ownerState,\n children: [hasSvgAsChild ? children.props.children : children, titleAccess ? /*#__PURE__*/_jsx(\"title\", {\n children: titleAccess\n }) : null]\n }));\n});\nprocess.env.NODE_ENV !== \"production\" ? SvgIcon.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the d.ts file and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * Node passed into the SVG element.\n */\n children: PropTypes.node,\n /**\n * Override or extend the styles applied to the component.\n */\n classes: PropTypes.object,\n /**\n * @ignore\n */\n className: PropTypes.string,\n /**\n * The color of the component.\n * It supports both default and custom theme colors, which can be added as shown in the\n * [palette customization guide](https://mui.com/material-ui/customization/palette/#custom-colors).\n * You can use the `htmlColor` prop to apply a color attribute to the SVG element.\n * @default 'inherit'\n */\n color: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.oneOf(['inherit', 'action', 'disabled', 'primary', 'secondary', 'error', 'info', 'success', 'warning']), PropTypes.string]),\n /**\n * The component used for the root node.\n * Either a string to use a HTML element or a component.\n */\n component: PropTypes.elementType,\n /**\n * The fontSize applied to the icon. Defaults to 24px, but can be configure to inherit font size.\n * @default 'medium'\n */\n fontSize: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.oneOf(['inherit', 'large', 'medium', 'small']), PropTypes.string]),\n /**\n * Applies a color attribute to the SVG element.\n */\n htmlColor: PropTypes.string,\n /**\n * If `true`, the root node will inherit the custom `component`'s viewBox and the `viewBox`\n * prop will be ignored.\n * Useful when you want to reference a custom `component` and have `SvgIcon` pass that\n * `component`'s viewBox to the root node.\n * @default false\n */\n inheritViewBox: PropTypes.bool,\n /**\n * The shape-rendering attribute. The behavior of the different options is described on the\n * [MDN Web Docs](https://developer.mozilla.org/en-US/docs/Web/SVG/Attribute/shape-rendering).\n * If you are having issues with blurry icons you should investigate this prop.\n */\n shapeRendering: PropTypes.string,\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Provides a human-readable title for the element that contains it.\n * https://www.w3.org/TR/SVG-access/#Equivalent\n */\n titleAccess: PropTypes.string,\n /**\n * Allows you to redefine what the coordinates without units mean inside an SVG element.\n * For example, if the SVG element is 500 (width) by 200 (height),\n * and you pass viewBox=\"0 0 50 20\",\n * this means that the coordinates inside the SVG will go from the top left corner (0,0)\n * to bottom right (50,20) and each unit will be worth 10px.\n * @default '0 0 24 24'\n */\n viewBox: PropTypes.string\n} : void 0;\nSvgIcon.muiName = 'SvgIcon';\nexport default SvgIcon;","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport * as React from 'react';\nimport SvgIcon from '../SvgIcon';\n\n/**\n * Private module reserved for @mui packages.\n */\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nexport default function createSvgIcon(path, displayName) {\n function Component(props, ref) {\n return /*#__PURE__*/_jsx(SvgIcon, _extends({\n \"data-testid\": `${displayName}Icon`,\n ref: ref\n }, props, {\n children: path\n }));\n }\n if (process.env.NODE_ENV !== 'production') {\n // Need to set `displayName` on the inner component for React.memo.\n // React prior to 16.14 ignores `displayName` on the wrapper.\n Component.displayName = `${displayName}Icon`;\n }\n Component.muiName = SvgIcon.muiName;\n return /*#__PURE__*/React.memo( /*#__PURE__*/React.forwardRef(Component));\n}","'use client';\n\nimport { unstable_ClassNameGenerator as ClassNameGenerator } from '@mui/base/ClassNameGenerator';\nexport { default as capitalize } from './capitalize';\nexport { default as createChainedFunction } from './createChainedFunction';\nexport { default as createSvgIcon } from './createSvgIcon';\nexport { default as debounce } from './debounce';\nexport { default as deprecatedPropType } from './deprecatedPropType';\nexport { default as isMuiElement } from './isMuiElement';\nexport { default as ownerDocument } from './ownerDocument';\nexport { default as ownerWindow } from './ownerWindow';\nexport { default as requirePropFactory } from './requirePropFactory';\nexport { default as setRef } from './setRef';\nexport { default as unstable_useEnhancedEffect } from './useEnhancedEffect';\nexport { default as unstable_useId } from './useId';\nexport { default as unsupportedProp } from './unsupportedProp';\nexport { default as useControlled } from './useControlled';\nexport { default as useEventCallback } from './useEventCallback';\nexport { default as useForkRef } from './useForkRef';\nexport { default as useIsFocusVisible } from './useIsFocusVisible';\n// TODO: remove this export once ClassNameGenerator is stable\n// eslint-disable-next-line @typescript-eslint/naming-convention\nexport const unstable_ClassNameGenerator = {\n configure: generator => {\n if (process.env.NODE_ENV !== 'production') {\n console.warn(['MUI: `ClassNameGenerator` import from `@mui/material/utils` is outdated and might cause unexpected issues.', '', \"You should use `import { unstable_ClassNameGenerator } from '@mui/material/className'` instead\", '', 'The detail of the issue: https://github.com/mui/material-ui/issues/30011#issuecomment-1024993401', '', 'The updated documentation: https://mui.com/guides/classname-generator/'].join('\\n'));\n }\n ClassNameGenerator.configure(generator);\n }\n};","\"use strict\";\n'use client';\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nObject.defineProperty(exports, \"default\", {\n enumerable: true,\n get: function () {\n return _utils.createSvgIcon;\n }\n});\nvar _utils = require(\"@mui/material/utils\");","\"use strict\";\n\"use client\";\n\nvar _interopRequireDefault = require(\"@babel/runtime/helpers/interopRequireDefault\");\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = void 0;\nvar _createSvgIcon = _interopRequireDefault(require(\"./utils/createSvgIcon\"));\nvar _jsxRuntime = require(\"react/jsx-runtime\");\nvar _default = exports.default = (0, _createSvgIcon.default)( /*#__PURE__*/(0, _jsxRuntime.jsx)(\"path\", {\n d: \"m10 17 5-5-5-5z\"\n}), 'ArrowRight');","/**\n * Determines if a given element is a DOM element name (i.e. not a React component).\n */\nexport function isHostComponent(element) {\n return typeof element === 'string';\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport { isHostComponent } from './isHostComponent';\n\n/**\n * Type of the ownerState based on the type of an element it applies to.\n * This resolves to the provided OwnerState for React components and `undefined` for host components.\n * Falls back to `OwnerState | undefined` when the exact type can't be determined in development time.\n */\n\n/**\n * Appends the ownerState object to the props, merging with the existing one if necessary.\n *\n * @param elementType Type of the element that owns the `existingProps`. If the element is a DOM node or undefined, `ownerState` is not applied.\n * @param otherProps Props of the element.\n * @param ownerState\n */\nexport function appendOwnerState(elementType, otherProps, ownerState) {\n if (elementType === undefined || isHostComponent(elementType)) {\n return otherProps;\n }\n return _extends({}, otherProps, {\n ownerState: _extends({}, otherProps.ownerState, ownerState)\n });\n}","'use client';\n\nimport * as React from 'react';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nconst defaultContextValue = {\n disableDefaultClasses: false\n};\nconst ClassNameConfiguratorContext = /*#__PURE__*/React.createContext(defaultContextValue);\n/**\n * @ignore - internal hook.\n *\n * Wraps the `generateUtilityClass` function and controls how the classes are generated.\n * Currently it only affects whether the classes are applied or not.\n *\n * @returns Function to be called with the `generateUtilityClass` function specific to a component to generate the classes.\n */\nexport function useClassNamesOverride(generateUtilityClass) {\n const {\n disableDefaultClasses\n } = React.useContext(ClassNameConfiguratorContext);\n return slot => {\n if (disableDefaultClasses) {\n return '';\n }\n return generateUtilityClass(slot);\n };\n}\n\n/**\n * Allows to configure the components within to not apply any built-in classes.\n */\nexport function ClassNameConfigurator(props) {\n const {\n disableDefaultClasses,\n children\n } = props;\n const contextValue = React.useMemo(() => ({\n disableDefaultClasses: disableDefaultClasses != null ? disableDefaultClasses : false\n }), [disableDefaultClasses]);\n return /*#__PURE__*/_jsx(ClassNameConfiguratorContext.Provider, {\n value: contextValue,\n children: children\n });\n}","/**\n * Extracts event handlers from a given object.\n * A prop is considered an event handler if it is a function and its name starts with `on`.\n *\n * @param object An object to extract event handlers from.\n * @param excludeKeys An array of keys to exclude from the returned object.\n */\nexport function extractEventHandlers(object, excludeKeys = []) {\n if (object === undefined) {\n return {};\n }\n const result = {};\n Object.keys(object).filter(prop => prop.match(/^on[A-Z]/) && typeof object[prop] === 'function' && !excludeKeys.includes(prop)).forEach(prop => {\n result[prop] = object[prop];\n });\n return result;\n}","/**\n * If `componentProps` is a function, calls it with the provided `ownerState`.\n * Otherwise, just returns `componentProps`.\n */\nexport function resolveComponentProps(componentProps, ownerState, slotState) {\n if (typeof componentProps === 'function') {\n return componentProps(ownerState, slotState);\n }\n return componentProps;\n}","/**\n * Removes event handlers from the given object.\n * A field is considered an event handler if it is a function with a name beginning with `on`.\n *\n * @param object Object to remove event handlers from.\n * @returns Object with event handlers removed.\n */\nexport function omitEventHandlers(object) {\n if (object === undefined) {\n return {};\n }\n const result = {};\n Object.keys(object).filter(prop => !(prop.match(/^on[A-Z]/) && typeof object[prop] === 'function')).forEach(prop => {\n result[prop] = object[prop];\n });\n return result;\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport clsx from 'clsx';\nimport { extractEventHandlers } from './extractEventHandlers';\nimport { omitEventHandlers } from './omitEventHandlers';\n/**\n * Merges the slot component internal props (usually coming from a hook)\n * with the externally provided ones.\n *\n * The merge order is (the latter overrides the former):\n * 1. The internal props (specified as a getter function to work with get*Props hook result)\n * 2. Additional props (specified internally on a Base UI component)\n * 3. External props specified on the owner component. These should only be used on a root slot.\n * 4. External props specified in the `slotProps.*` prop.\n * 5. The `className` prop - combined from all the above.\n * @param parameters\n * @returns\n */\nexport function mergeSlotProps(parameters) {\n const {\n getSlotProps,\n additionalProps,\n externalSlotProps,\n externalForwardedProps,\n className\n } = parameters;\n if (!getSlotProps) {\n // The simpler case - getSlotProps is not defined, so no internal event handlers are defined,\n // so we can simply merge all the props without having to worry about extracting event handlers.\n const joinedClasses = clsx(additionalProps == null ? void 0 : additionalProps.className, className, externalForwardedProps == null ? void 0 : externalForwardedProps.className, externalSlotProps == null ? void 0 : externalSlotProps.className);\n const mergedStyle = _extends({}, additionalProps == null ? void 0 : additionalProps.style, externalForwardedProps == null ? void 0 : externalForwardedProps.style, externalSlotProps == null ? void 0 : externalSlotProps.style);\n const props = _extends({}, additionalProps, externalForwardedProps, externalSlotProps);\n if (joinedClasses.length > 0) {\n props.className = joinedClasses;\n }\n if (Object.keys(mergedStyle).length > 0) {\n props.style = mergedStyle;\n }\n return {\n props,\n internalRef: undefined\n };\n }\n\n // In this case, getSlotProps is responsible for calling the external event handlers.\n // We don't need to include them in the merged props because of this.\n\n const eventHandlers = extractEventHandlers(_extends({}, externalForwardedProps, externalSlotProps));\n const componentsPropsWithoutEventHandlers = omitEventHandlers(externalSlotProps);\n const otherPropsWithoutEventHandlers = omitEventHandlers(externalForwardedProps);\n const internalSlotProps = getSlotProps(eventHandlers);\n\n // The order of classes is important here.\n // Emotion (that we use in libraries consuming Base UI) depends on this order\n // to properly override style. It requires the most important classes to be last\n // (see https://github.com/mui/material-ui/pull/33205) for the related discussion.\n const joinedClasses = clsx(internalSlotProps == null ? void 0 : internalSlotProps.className, additionalProps == null ? void 0 : additionalProps.className, className, externalForwardedProps == null ? void 0 : externalForwardedProps.className, externalSlotProps == null ? void 0 : externalSlotProps.className);\n const mergedStyle = _extends({}, internalSlotProps == null ? void 0 : internalSlotProps.style, additionalProps == null ? void 0 : additionalProps.style, externalForwardedProps == null ? void 0 : externalForwardedProps.style, externalSlotProps == null ? void 0 : externalSlotProps.style);\n const props = _extends({}, internalSlotProps, additionalProps, otherPropsWithoutEventHandlers, componentsPropsWithoutEventHandlers);\n if (joinedClasses.length > 0) {\n props.className = joinedClasses;\n }\n if (Object.keys(mergedStyle).length > 0) {\n props.style = mergedStyle;\n }\n return {\n props,\n internalRef: internalSlotProps.ref\n };\n}","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"elementType\", \"externalSlotProps\", \"ownerState\", \"skipResolvingSlotProps\"];\nimport { unstable_useForkRef as useForkRef } from '@mui/utils';\nimport { appendOwnerState } from './appendOwnerState';\nimport { mergeSlotProps } from './mergeSlotProps';\nimport { resolveComponentProps } from './resolveComponentProps';\n/**\n * @ignore - do not document.\n * Builds the props to be passed into the slot of an unstyled component.\n * It merges the internal props of the component with the ones supplied by the user, allowing to customize the behavior.\n * If the slot component is not a host component, it also merges in the `ownerState`.\n *\n * @param parameters.getSlotProps - A function that returns the props to be passed to the slot component.\n */\nexport function useSlotProps(parameters) {\n var _parameters$additiona;\n const {\n elementType,\n externalSlotProps,\n ownerState,\n skipResolvingSlotProps = false\n } = parameters,\n rest = _objectWithoutPropertiesLoose(parameters, _excluded);\n const resolvedComponentsProps = skipResolvingSlotProps ? {} : resolveComponentProps(externalSlotProps, ownerState);\n const {\n props: mergedProps,\n internalRef\n } = mergeSlotProps(_extends({}, rest, {\n externalSlotProps: resolvedComponentsProps\n }));\n const ref = useForkRef(internalRef, resolvedComponentsProps == null ? void 0 : resolvedComponentsProps.ref, (_parameters$additiona = parameters.additionalProps) == null ? void 0 : _parameters$additiona.ref);\n const props = appendOwnerState(elementType, _extends({}, mergedProps, {\n ref\n }), ownerState);\n return props;\n}","import { globalStateClasses } from '@mui/utils/generateUtilityClass';\nconst GLOBAL_CLASS_PREFIX = 'base';\nfunction buildStateClass(state) {\n return `${GLOBAL_CLASS_PREFIX}--${state}`;\n}\nfunction buildSlotClass(componentName, slot) {\n return `${GLOBAL_CLASS_PREFIX}-${componentName}-${slot}`;\n}\nexport function generateUtilityClass(componentName, slot) {\n const globalStateClass = globalStateClasses[slot];\n return globalStateClass ? buildStateClass(globalStateClass) : buildSlotClass(componentName, slot);\n}\nexport function isGlobalState(slot) {\n return globalStateClasses[slot] !== undefined;\n}","import { generateUtilityClass } from '../generateUtilityClass';\nexport function generateUtilityClasses(componentName, slots) {\n const result = {};\n slots.forEach(slot => {\n result[slot] = generateUtilityClass(componentName, slot);\n });\n return result;\n}","'use client';\n\nimport * as React from 'react';\nimport * as ReactDOM from 'react-dom';\nimport PropTypes from 'prop-types';\nimport { exactProp, HTMLElementType, unstable_useEnhancedEffect as useEnhancedEffect, unstable_useForkRef as useForkRef, unstable_setRef as setRef } from '@mui/utils';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nfunction getContainer(container) {\n return typeof container === 'function' ? container() : container;\n}\n\n/**\n * Portals provide a first-class way to render children into a DOM node\n * that exists outside the DOM hierarchy of the parent component.\n *\n * Demos:\n *\n * - [Portal](https://mui.com/base-ui/react-portal/)\n *\n * API:\n *\n * - [Portal API](https://mui.com/base-ui/react-portal/components-api/#portal)\n */\nconst Portal = /*#__PURE__*/React.forwardRef(function Portal(props, forwardedRef) {\n const {\n children,\n container,\n disablePortal = false\n } = props;\n const [mountNode, setMountNode] = React.useState(null);\n // @ts-expect-error TODO upstream fix\n const handleRef = useForkRef( /*#__PURE__*/React.isValidElement(children) ? children.ref : null, forwardedRef);\n useEnhancedEffect(() => {\n if (!disablePortal) {\n setMountNode(getContainer(container) || document.body);\n }\n }, [container, disablePortal]);\n useEnhancedEffect(() => {\n if (mountNode && !disablePortal) {\n setRef(forwardedRef, mountNode);\n return () => {\n setRef(forwardedRef, null);\n };\n }\n return undefined;\n }, [forwardedRef, mountNode, disablePortal]);\n if (disablePortal) {\n if ( /*#__PURE__*/React.isValidElement(children)) {\n const newProps = {\n ref: handleRef\n };\n return /*#__PURE__*/React.cloneElement(children, newProps);\n }\n return /*#__PURE__*/_jsx(React.Fragment, {\n children: children\n });\n }\n return /*#__PURE__*/_jsx(React.Fragment, {\n children: mountNode ? /*#__PURE__*/ReactDOM.createPortal(children, mountNode) : mountNode\n });\n});\nprocess.env.NODE_ENV !== \"production\" ? Portal.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * The children to render into the `container`.\n */\n children: PropTypes.node,\n /**\n * An HTML element or function that returns one.\n * The `container` will have the portal children appended to it.\n *\n * You can also provide a callback, which is called in a React layout effect.\n * This lets you set the container from a ref, and also makes server-side rendering possible.\n *\n * By default, it uses the body of the top-level document object,\n * so it's simply `document.body` most of the time.\n */\n container: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.func]),\n /**\n * The `children` will be under the DOM hierarchy of the parent component.\n * @default false\n */\n disablePortal: PropTypes.bool\n} : void 0;\nif (process.env.NODE_ENV !== 'production') {\n // eslint-disable-next-line\n Portal['propTypes' + ''] = exactProp(Portal.propTypes);\n}\nexport { Portal };","export var top = 'top';\nexport var bottom = 'bottom';\nexport var right = 'right';\nexport var left = 'left';\nexport var auto = 'auto';\nexport var basePlacements = [top, bottom, right, left];\nexport var start = 'start';\nexport var end = 'end';\nexport var clippingParents = 'clippingParents';\nexport var viewport = 'viewport';\nexport var popper = 'popper';\nexport var reference = 'reference';\nexport var variationPlacements = /*#__PURE__*/basePlacements.reduce(function (acc, placement) {\n return acc.concat([placement + \"-\" + start, placement + \"-\" + end]);\n}, []);\nexport var placements = /*#__PURE__*/[].concat(basePlacements, [auto]).reduce(function (acc, placement) {\n return acc.concat([placement, placement + \"-\" + start, placement + \"-\" + end]);\n}, []); // modifiers that need to read the DOM\n\nexport var beforeRead = 'beforeRead';\nexport var read = 'read';\nexport var afterRead = 'afterRead'; // pure-logic modifiers\n\nexport var beforeMain = 'beforeMain';\nexport var main = 'main';\nexport var afterMain = 'afterMain'; // modifier with the purpose to write to the DOM (or write into a framework state)\n\nexport var beforeWrite = 'beforeWrite';\nexport var write = 'write';\nexport var afterWrite = 'afterWrite';\nexport var modifierPhases = [beforeRead, read, afterRead, beforeMain, main, afterMain, beforeWrite, write, afterWrite];","export default function getNodeName(element) {\n return element ? (element.nodeName || '').toLowerCase() : null;\n}","export default function getWindow(node) {\n if (node == null) {\n return window;\n }\n\n if (node.toString() !== '[object Window]') {\n var ownerDocument = node.ownerDocument;\n return ownerDocument ? ownerDocument.defaultView || window : window;\n }\n\n return node;\n}","import getWindow from \"./getWindow.js\";\n\nfunction isElement(node) {\n var OwnElement = getWindow(node).Element;\n return node instanceof OwnElement || node instanceof Element;\n}\n\nfunction isHTMLElement(node) {\n var OwnElement = getWindow(node).HTMLElement;\n return node instanceof OwnElement || node instanceof HTMLElement;\n}\n\nfunction isShadowRoot(node) {\n // IE 11 has no ShadowRoot\n if (typeof ShadowRoot === 'undefined') {\n return false;\n }\n\n var OwnElement = getWindow(node).ShadowRoot;\n return node instanceof OwnElement || node instanceof ShadowRoot;\n}\n\nexport { isElement, isHTMLElement, isShadowRoot };","import getNodeName from \"../dom-utils/getNodeName.js\";\nimport { isHTMLElement } from \"../dom-utils/instanceOf.js\"; // This modifier takes the styles prepared by the `computeStyles` modifier\n// and applies them to the HTMLElements such as popper and arrow\n\nfunction applyStyles(_ref) {\n var state = _ref.state;\n Object.keys(state.elements).forEach(function (name) {\n var style = state.styles[name] || {};\n var attributes = state.attributes[name] || {};\n var element = state.elements[name]; // arrow is optional + virtual elements\n\n if (!isHTMLElement(element) || !getNodeName(element)) {\n return;\n } // Flow doesn't support to extend this property, but it's the most\n // effective way to apply styles to an HTMLElement\n // $FlowFixMe[cannot-write]\n\n\n Object.assign(element.style, style);\n Object.keys(attributes).forEach(function (name) {\n var value = attributes[name];\n\n if (value === false) {\n element.removeAttribute(name);\n } else {\n element.setAttribute(name, value === true ? '' : value);\n }\n });\n });\n}\n\nfunction effect(_ref2) {\n var state = _ref2.state;\n var initialStyles = {\n popper: {\n position: state.options.strategy,\n left: '0',\n top: '0',\n margin: '0'\n },\n arrow: {\n position: 'absolute'\n },\n reference: {}\n };\n Object.assign(state.elements.popper.style, initialStyles.popper);\n state.styles = initialStyles;\n\n if (state.elements.arrow) {\n Object.assign(state.elements.arrow.style, initialStyles.arrow);\n }\n\n return function () {\n Object.keys(state.elements).forEach(function (name) {\n var element = state.elements[name];\n var attributes = state.attributes[name] || {};\n var styleProperties = Object.keys(state.styles.hasOwnProperty(name) ? state.styles[name] : initialStyles[name]); // Set all values to an empty string to unset them\n\n var style = styleProperties.reduce(function (style, property) {\n style[property] = '';\n return style;\n }, {}); // arrow is optional + virtual elements\n\n if (!isHTMLElement(element) || !getNodeName(element)) {\n return;\n }\n\n Object.assign(element.style, style);\n Object.keys(attributes).forEach(function (attribute) {\n element.removeAttribute(attribute);\n });\n });\n };\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'applyStyles',\n enabled: true,\n phase: 'write',\n fn: applyStyles,\n effect: effect,\n requires: ['computeStyles']\n};","import { auto } from \"../enums.js\";\nexport default function getBasePlacement(placement) {\n return placement.split('-')[0];\n}","export var max = Math.max;\nexport var min = Math.min;\nexport var round = Math.round;","export default function getUAString() {\n var uaData = navigator.userAgentData;\n\n if (uaData != null && uaData.brands && Array.isArray(uaData.brands)) {\n return uaData.brands.map(function (item) {\n return item.brand + \"/\" + item.version;\n }).join(' ');\n }\n\n return navigator.userAgent;\n}","import getUAString from \"../utils/userAgent.js\";\nexport default function isLayoutViewport() {\n return !/^((?!chrome|android).)*safari/i.test(getUAString());\n}","import { isElement, isHTMLElement } from \"./instanceOf.js\";\nimport { round } from \"../utils/math.js\";\nimport getWindow from \"./getWindow.js\";\nimport isLayoutViewport from \"./isLayoutViewport.js\";\nexport default function getBoundingClientRect(element, includeScale, isFixedStrategy) {\n if (includeScale === void 0) {\n includeScale = false;\n }\n\n if (isFixedStrategy === void 0) {\n isFixedStrategy = false;\n }\n\n var clientRect = element.getBoundingClientRect();\n var scaleX = 1;\n var scaleY = 1;\n\n if (includeScale && isHTMLElement(element)) {\n scaleX = element.offsetWidth > 0 ? round(clientRect.width) / element.offsetWidth || 1 : 1;\n scaleY = element.offsetHeight > 0 ? round(clientRect.height) / element.offsetHeight || 1 : 1;\n }\n\n var _ref = isElement(element) ? getWindow(element) : window,\n visualViewport = _ref.visualViewport;\n\n var addVisualOffsets = !isLayoutViewport() && isFixedStrategy;\n var x = (clientRect.left + (addVisualOffsets && visualViewport ? visualViewport.offsetLeft : 0)) / scaleX;\n var y = (clientRect.top + (addVisualOffsets && visualViewport ? visualViewport.offsetTop : 0)) / scaleY;\n var width = clientRect.width / scaleX;\n var height = clientRect.height / scaleY;\n return {\n width: width,\n height: height,\n top: y,\n right: x + width,\n bottom: y + height,\n left: x,\n x: x,\n y: y\n };\n}","import getBoundingClientRect from \"./getBoundingClientRect.js\"; // Returns the layout rect of an element relative to its offsetParent. Layout\n// means it doesn't take into account transforms.\n\nexport default function getLayoutRect(element) {\n var clientRect = getBoundingClientRect(element); // Use the clientRect sizes if it's not been transformed.\n // Fixes https://github.com/popperjs/popper-core/issues/1223\n\n var width = element.offsetWidth;\n var height = element.offsetHeight;\n\n if (Math.abs(clientRect.width - width) <= 1) {\n width = clientRect.width;\n }\n\n if (Math.abs(clientRect.height - height) <= 1) {\n height = clientRect.height;\n }\n\n return {\n x: element.offsetLeft,\n y: element.offsetTop,\n width: width,\n height: height\n };\n}","import { isShadowRoot } from \"./instanceOf.js\";\nexport default function contains(parent, child) {\n var rootNode = child.getRootNode && child.getRootNode(); // First, attempt with faster native method\n\n if (parent.contains(child)) {\n return true;\n } // then fallback to custom implementation with Shadow DOM support\n else if (rootNode && isShadowRoot(rootNode)) {\n var next = child;\n\n do {\n if (next && parent.isSameNode(next)) {\n return true;\n } // $FlowFixMe[prop-missing]: need a better way to handle this...\n\n\n next = next.parentNode || next.host;\n } while (next);\n } // Give up, the result is false\n\n\n return false;\n}","import getWindow from \"./getWindow.js\";\nexport default function getComputedStyle(element) {\n return getWindow(element).getComputedStyle(element);\n}","import getNodeName from \"./getNodeName.js\";\nexport default function isTableElement(element) {\n return ['table', 'td', 'th'].indexOf(getNodeName(element)) >= 0;\n}","import { isElement } from \"./instanceOf.js\";\nexport default function getDocumentElement(element) {\n // $FlowFixMe[incompatible-return]: assume body is always available\n return ((isElement(element) ? element.ownerDocument : // $FlowFixMe[prop-missing]\n element.document) || window.document).documentElement;\n}","import getNodeName from \"./getNodeName.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport { isShadowRoot } from \"./instanceOf.js\";\nexport default function getParentNode(element) {\n if (getNodeName(element) === 'html') {\n return element;\n }\n\n return (// this is a quicker (but less type safe) way to save quite some bytes from the bundle\n // $FlowFixMe[incompatible-return]\n // $FlowFixMe[prop-missing]\n element.assignedSlot || // step into the shadow DOM of the parent of a slotted node\n element.parentNode || ( // DOM Element detected\n isShadowRoot(element) ? element.host : null) || // ShadowRoot detected\n // $FlowFixMe[incompatible-call]: HTMLElement is a Node\n getDocumentElement(element) // fallback\n\n );\n}","import getWindow from \"./getWindow.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport getComputedStyle from \"./getComputedStyle.js\";\nimport { isHTMLElement, isShadowRoot } from \"./instanceOf.js\";\nimport isTableElement from \"./isTableElement.js\";\nimport getParentNode from \"./getParentNode.js\";\nimport getUAString from \"../utils/userAgent.js\";\n\nfunction getTrueOffsetParent(element) {\n if (!isHTMLElement(element) || // https://github.com/popperjs/popper-core/issues/837\n getComputedStyle(element).position === 'fixed') {\n return null;\n }\n\n return element.offsetParent;\n} // `.offsetParent` reports `null` for fixed elements, while absolute elements\n// return the containing block\n\n\nfunction getContainingBlock(element) {\n var isFirefox = /firefox/i.test(getUAString());\n var isIE = /Trident/i.test(getUAString());\n\n if (isIE && isHTMLElement(element)) {\n // In IE 9, 10 and 11 fixed elements containing block is always established by the viewport\n var elementCss = getComputedStyle(element);\n\n if (elementCss.position === 'fixed') {\n return null;\n }\n }\n\n var currentNode = getParentNode(element);\n\n if (isShadowRoot(currentNode)) {\n currentNode = currentNode.host;\n }\n\n while (isHTMLElement(currentNode) && ['html', 'body'].indexOf(getNodeName(currentNode)) < 0) {\n var css = getComputedStyle(currentNode); // This is non-exhaustive but covers the most common CSS properties that\n // create a containing block.\n // https://developer.mozilla.org/en-US/docs/Web/CSS/Containing_block#identifying_the_containing_block\n\n if (css.transform !== 'none' || css.perspective !== 'none' || css.contain === 'paint' || ['transform', 'perspective'].indexOf(css.willChange) !== -1 || isFirefox && css.willChange === 'filter' || isFirefox && css.filter && css.filter !== 'none') {\n return currentNode;\n } else {\n currentNode = currentNode.parentNode;\n }\n }\n\n return null;\n} // Gets the closest ancestor positioned element. Handles some edge cases,\n// such as table ancestors and cross browser bugs.\n\n\nexport default function getOffsetParent(element) {\n var window = getWindow(element);\n var offsetParent = getTrueOffsetParent(element);\n\n while (offsetParent && isTableElement(offsetParent) && getComputedStyle(offsetParent).position === 'static') {\n offsetParent = getTrueOffsetParent(offsetParent);\n }\n\n if (offsetParent && (getNodeName(offsetParent) === 'html' || getNodeName(offsetParent) === 'body' && getComputedStyle(offsetParent).position === 'static')) {\n return window;\n }\n\n return offsetParent || getContainingBlock(element) || window;\n}","export default function getMainAxisFromPlacement(placement) {\n return ['top', 'bottom'].indexOf(placement) >= 0 ? 'x' : 'y';\n}","import { max as mathMax, min as mathMin } from \"./math.js\";\nexport function within(min, value, max) {\n return mathMax(min, mathMin(value, max));\n}\nexport function withinMaxClamp(min, value, max) {\n var v = within(min, value, max);\n return v > max ? max : v;\n}","export default function getFreshSideObject() {\n return {\n top: 0,\n right: 0,\n bottom: 0,\n left: 0\n };\n}","import getFreshSideObject from \"./getFreshSideObject.js\";\nexport default function mergePaddingObject(paddingObject) {\n return Object.assign({}, getFreshSideObject(), paddingObject);\n}","export default function expandToHashMap(value, keys) {\n return keys.reduce(function (hashMap, key) {\n hashMap[key] = value;\n return hashMap;\n }, {});\n}","import getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getLayoutRect from \"../dom-utils/getLayoutRect.js\";\nimport contains from \"../dom-utils/contains.js\";\nimport getOffsetParent from \"../dom-utils/getOffsetParent.js\";\nimport getMainAxisFromPlacement from \"../utils/getMainAxisFromPlacement.js\";\nimport { within } from \"../utils/within.js\";\nimport mergePaddingObject from \"../utils/mergePaddingObject.js\";\nimport expandToHashMap from \"../utils/expandToHashMap.js\";\nimport { left, right, basePlacements, top, bottom } from \"../enums.js\"; // eslint-disable-next-line import/no-unused-modules\n\nvar toPaddingObject = function toPaddingObject(padding, state) {\n padding = typeof padding === 'function' ? padding(Object.assign({}, state.rects, {\n placement: state.placement\n })) : padding;\n return mergePaddingObject(typeof padding !== 'number' ? padding : expandToHashMap(padding, basePlacements));\n};\n\nfunction arrow(_ref) {\n var _state$modifiersData$;\n\n var state = _ref.state,\n name = _ref.name,\n options = _ref.options;\n var arrowElement = state.elements.arrow;\n var popperOffsets = state.modifiersData.popperOffsets;\n var basePlacement = getBasePlacement(state.placement);\n var axis = getMainAxisFromPlacement(basePlacement);\n var isVertical = [left, right].indexOf(basePlacement) >= 0;\n var len = isVertical ? 'height' : 'width';\n\n if (!arrowElement || !popperOffsets) {\n return;\n }\n\n var paddingObject = toPaddingObject(options.padding, state);\n var arrowRect = getLayoutRect(arrowElement);\n var minProp = axis === 'y' ? top : left;\n var maxProp = axis === 'y' ? bottom : right;\n var endDiff = state.rects.reference[len] + state.rects.reference[axis] - popperOffsets[axis] - state.rects.popper[len];\n var startDiff = popperOffsets[axis] - state.rects.reference[axis];\n var arrowOffsetParent = getOffsetParent(arrowElement);\n var clientSize = arrowOffsetParent ? axis === 'y' ? arrowOffsetParent.clientHeight || 0 : arrowOffsetParent.clientWidth || 0 : 0;\n var centerToReference = endDiff / 2 - startDiff / 2; // Make sure the arrow doesn't overflow the popper if the center point is\n // outside of the popper bounds\n\n var min = paddingObject[minProp];\n var max = clientSize - arrowRect[len] - paddingObject[maxProp];\n var center = clientSize / 2 - arrowRect[len] / 2 + centerToReference;\n var offset = within(min, center, max); // Prevents breaking syntax highlighting...\n\n var axisProp = axis;\n state.modifiersData[name] = (_state$modifiersData$ = {}, _state$modifiersData$[axisProp] = offset, _state$modifiersData$.centerOffset = offset - center, _state$modifiersData$);\n}\n\nfunction effect(_ref2) {\n var state = _ref2.state,\n options = _ref2.options;\n var _options$element = options.element,\n arrowElement = _options$element === void 0 ? '[data-popper-arrow]' : _options$element;\n\n if (arrowElement == null) {\n return;\n } // CSS selector\n\n\n if (typeof arrowElement === 'string') {\n arrowElement = state.elements.popper.querySelector(arrowElement);\n\n if (!arrowElement) {\n return;\n }\n }\n\n if (!contains(state.elements.popper, arrowElement)) {\n return;\n }\n\n state.elements.arrow = arrowElement;\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'arrow',\n enabled: true,\n phase: 'main',\n fn: arrow,\n effect: effect,\n requires: ['popperOffsets'],\n requiresIfExists: ['preventOverflow']\n};","export default function getVariation(placement) {\n return placement.split('-')[1];\n}","import { top, left, right, bottom, end } from \"../enums.js\";\nimport getOffsetParent from \"../dom-utils/getOffsetParent.js\";\nimport getWindow from \"../dom-utils/getWindow.js\";\nimport getDocumentElement from \"../dom-utils/getDocumentElement.js\";\nimport getComputedStyle from \"../dom-utils/getComputedStyle.js\";\nimport getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getVariation from \"../utils/getVariation.js\";\nimport { round } from \"../utils/math.js\"; // eslint-disable-next-line import/no-unused-modules\n\nvar unsetSides = {\n top: 'auto',\n right: 'auto',\n bottom: 'auto',\n left: 'auto'\n}; // Round the offsets to the nearest suitable subpixel based on the DPR.\n// Zooming can change the DPR, but it seems to report a value that will\n// cleanly divide the values into the appropriate subpixels.\n\nfunction roundOffsetsByDPR(_ref, win) {\n var x = _ref.x,\n y = _ref.y;\n var dpr = win.devicePixelRatio || 1;\n return {\n x: round(x * dpr) / dpr || 0,\n y: round(y * dpr) / dpr || 0\n };\n}\n\nexport function mapToStyles(_ref2) {\n var _Object$assign2;\n\n var popper = _ref2.popper,\n popperRect = _ref2.popperRect,\n placement = _ref2.placement,\n variation = _ref2.variation,\n offsets = _ref2.offsets,\n position = _ref2.position,\n gpuAcceleration = _ref2.gpuAcceleration,\n adaptive = _ref2.adaptive,\n roundOffsets = _ref2.roundOffsets,\n isFixed = _ref2.isFixed;\n var _offsets$x = offsets.x,\n x = _offsets$x === void 0 ? 0 : _offsets$x,\n _offsets$y = offsets.y,\n y = _offsets$y === void 0 ? 0 : _offsets$y;\n\n var _ref3 = typeof roundOffsets === 'function' ? roundOffsets({\n x: x,\n y: y\n }) : {\n x: x,\n y: y\n };\n\n x = _ref3.x;\n y = _ref3.y;\n var hasX = offsets.hasOwnProperty('x');\n var hasY = offsets.hasOwnProperty('y');\n var sideX = left;\n var sideY = top;\n var win = window;\n\n if (adaptive) {\n var offsetParent = getOffsetParent(popper);\n var heightProp = 'clientHeight';\n var widthProp = 'clientWidth';\n\n if (offsetParent === getWindow(popper)) {\n offsetParent = getDocumentElement(popper);\n\n if (getComputedStyle(offsetParent).position !== 'static' && position === 'absolute') {\n heightProp = 'scrollHeight';\n widthProp = 'scrollWidth';\n }\n } // $FlowFixMe[incompatible-cast]: force type refinement, we compare offsetParent with window above, but Flow doesn't detect it\n\n\n offsetParent = offsetParent;\n\n if (placement === top || (placement === left || placement === right) && variation === end) {\n sideY = bottom;\n var offsetY = isFixed && offsetParent === win && win.visualViewport ? win.visualViewport.height : // $FlowFixMe[prop-missing]\n offsetParent[heightProp];\n y -= offsetY - popperRect.height;\n y *= gpuAcceleration ? 1 : -1;\n }\n\n if (placement === left || (placement === top || placement === bottom) && variation === end) {\n sideX = right;\n var offsetX = isFixed && offsetParent === win && win.visualViewport ? win.visualViewport.width : // $FlowFixMe[prop-missing]\n offsetParent[widthProp];\n x -= offsetX - popperRect.width;\n x *= gpuAcceleration ? 1 : -1;\n }\n }\n\n var commonStyles = Object.assign({\n position: position\n }, adaptive && unsetSides);\n\n var _ref4 = roundOffsets === true ? roundOffsetsByDPR({\n x: x,\n y: y\n }, getWindow(popper)) : {\n x: x,\n y: y\n };\n\n x = _ref4.x;\n y = _ref4.y;\n\n if (gpuAcceleration) {\n var _Object$assign;\n\n return Object.assign({}, commonStyles, (_Object$assign = {}, _Object$assign[sideY] = hasY ? '0' : '', _Object$assign[sideX] = hasX ? '0' : '', _Object$assign.transform = (win.devicePixelRatio || 1) <= 1 ? \"translate(\" + x + \"px, \" + y + \"px)\" : \"translate3d(\" + x + \"px, \" + y + \"px, 0)\", _Object$assign));\n }\n\n return Object.assign({}, commonStyles, (_Object$assign2 = {}, _Object$assign2[sideY] = hasY ? y + \"px\" : '', _Object$assign2[sideX] = hasX ? x + \"px\" : '', _Object$assign2.transform = '', _Object$assign2));\n}\n\nfunction computeStyles(_ref5) {\n var state = _ref5.state,\n options = _ref5.options;\n var _options$gpuAccelerat = options.gpuAcceleration,\n gpuAcceleration = _options$gpuAccelerat === void 0 ? true : _options$gpuAccelerat,\n _options$adaptive = options.adaptive,\n adaptive = _options$adaptive === void 0 ? true : _options$adaptive,\n _options$roundOffsets = options.roundOffsets,\n roundOffsets = _options$roundOffsets === void 0 ? true : _options$roundOffsets;\n var commonStyles = {\n placement: getBasePlacement(state.placement),\n variation: getVariation(state.placement),\n popper: state.elements.popper,\n popperRect: state.rects.popper,\n gpuAcceleration: gpuAcceleration,\n isFixed: state.options.strategy === 'fixed'\n };\n\n if (state.modifiersData.popperOffsets != null) {\n state.styles.popper = Object.assign({}, state.styles.popper, mapToStyles(Object.assign({}, commonStyles, {\n offsets: state.modifiersData.popperOffsets,\n position: state.options.strategy,\n adaptive: adaptive,\n roundOffsets: roundOffsets\n })));\n }\n\n if (state.modifiersData.arrow != null) {\n state.styles.arrow = Object.assign({}, state.styles.arrow, mapToStyles(Object.assign({}, commonStyles, {\n offsets: state.modifiersData.arrow,\n position: 'absolute',\n adaptive: false,\n roundOffsets: roundOffsets\n })));\n }\n\n state.attributes.popper = Object.assign({}, state.attributes.popper, {\n 'data-popper-placement': state.placement\n });\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'computeStyles',\n enabled: true,\n phase: 'beforeWrite',\n fn: computeStyles,\n data: {}\n};","import getWindow from \"../dom-utils/getWindow.js\"; // eslint-disable-next-line import/no-unused-modules\n\nvar passive = {\n passive: true\n};\n\nfunction effect(_ref) {\n var state = _ref.state,\n instance = _ref.instance,\n options = _ref.options;\n var _options$scroll = options.scroll,\n scroll = _options$scroll === void 0 ? true : _options$scroll,\n _options$resize = options.resize,\n resize = _options$resize === void 0 ? true : _options$resize;\n var window = getWindow(state.elements.popper);\n var scrollParents = [].concat(state.scrollParents.reference, state.scrollParents.popper);\n\n if (scroll) {\n scrollParents.forEach(function (scrollParent) {\n scrollParent.addEventListener('scroll', instance.update, passive);\n });\n }\n\n if (resize) {\n window.addEventListener('resize', instance.update, passive);\n }\n\n return function () {\n if (scroll) {\n scrollParents.forEach(function (scrollParent) {\n scrollParent.removeEventListener('scroll', instance.update, passive);\n });\n }\n\n if (resize) {\n window.removeEventListener('resize', instance.update, passive);\n }\n };\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'eventListeners',\n enabled: true,\n phase: 'write',\n fn: function fn() {},\n effect: effect,\n data: {}\n};","var hash = {\n left: 'right',\n right: 'left',\n bottom: 'top',\n top: 'bottom'\n};\nexport default function getOppositePlacement(placement) {\n return placement.replace(/left|right|bottom|top/g, function (matched) {\n return hash[matched];\n });\n}","var hash = {\n start: 'end',\n end: 'start'\n};\nexport default function getOppositeVariationPlacement(placement) {\n return placement.replace(/start|end/g, function (matched) {\n return hash[matched];\n });\n}","import getWindow from \"./getWindow.js\";\nexport default function getWindowScroll(node) {\n var win = getWindow(node);\n var scrollLeft = win.pageXOffset;\n var scrollTop = win.pageYOffset;\n return {\n scrollLeft: scrollLeft,\n scrollTop: scrollTop\n };\n}","import getBoundingClientRect from \"./getBoundingClientRect.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport getWindowScroll from \"./getWindowScroll.js\";\nexport default function getWindowScrollBarX(element) {\n // If has a CSS width greater than the viewport, then this will be\n // incorrect for RTL.\n // Popper 1 is broken in this case and never had a bug report so let's assume\n // it's not an issue. I don't think anyone ever specifies width on \n // anyway.\n // Browsers where the left scrollbar doesn't cause an issue report `0` for\n // this (e.g. Edge 2019, IE11, Safari)\n return getBoundingClientRect(getDocumentElement(element)).left + getWindowScroll(element).scrollLeft;\n}","import getWindow from \"./getWindow.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport getWindowScrollBarX from \"./getWindowScrollBarX.js\";\nimport isLayoutViewport from \"./isLayoutViewport.js\";\nexport default function getViewportRect(element, strategy) {\n var win = getWindow(element);\n var html = getDocumentElement(element);\n var visualViewport = win.visualViewport;\n var width = html.clientWidth;\n var height = html.clientHeight;\n var x = 0;\n var y = 0;\n\n if (visualViewport) {\n width = visualViewport.width;\n height = visualViewport.height;\n var layoutViewport = isLayoutViewport();\n\n if (layoutViewport || !layoutViewport && strategy === 'fixed') {\n x = visualViewport.offsetLeft;\n y = visualViewport.offsetTop;\n }\n }\n\n return {\n width: width,\n height: height,\n x: x + getWindowScrollBarX(element),\n y: y\n };\n}","import getDocumentElement from \"./getDocumentElement.js\";\nimport getComputedStyle from \"./getComputedStyle.js\";\nimport getWindowScrollBarX from \"./getWindowScrollBarX.js\";\nimport getWindowScroll from \"./getWindowScroll.js\";\nimport { max } from \"../utils/math.js\"; // Gets the entire size of the scrollable document area, even extending outside\n// of the `` and `` rect bounds if horizontally scrollable\n\nexport default function getDocumentRect(element) {\n var _element$ownerDocumen;\n\n var html = getDocumentElement(element);\n var winScroll = getWindowScroll(element);\n var body = (_element$ownerDocumen = element.ownerDocument) == null ? void 0 : _element$ownerDocumen.body;\n var width = max(html.scrollWidth, html.clientWidth, body ? body.scrollWidth : 0, body ? body.clientWidth : 0);\n var height = max(html.scrollHeight, html.clientHeight, body ? body.scrollHeight : 0, body ? body.clientHeight : 0);\n var x = -winScroll.scrollLeft + getWindowScrollBarX(element);\n var y = -winScroll.scrollTop;\n\n if (getComputedStyle(body || html).direction === 'rtl') {\n x += max(html.clientWidth, body ? body.clientWidth : 0) - width;\n }\n\n return {\n width: width,\n height: height,\n x: x,\n y: y\n };\n}","import getComputedStyle from \"./getComputedStyle.js\";\nexport default function isScrollParent(element) {\n // Firefox wants us to check `-x` and `-y` variations as well\n var _getComputedStyle = getComputedStyle(element),\n overflow = _getComputedStyle.overflow,\n overflowX = _getComputedStyle.overflowX,\n overflowY = _getComputedStyle.overflowY;\n\n return /auto|scroll|overlay|hidden/.test(overflow + overflowY + overflowX);\n}","import getParentNode from \"./getParentNode.js\";\nimport isScrollParent from \"./isScrollParent.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport { isHTMLElement } from \"./instanceOf.js\";\nexport default function getScrollParent(node) {\n if (['html', 'body', '#document'].indexOf(getNodeName(node)) >= 0) {\n // $FlowFixMe[incompatible-return]: assume body is always available\n return node.ownerDocument.body;\n }\n\n if (isHTMLElement(node) && isScrollParent(node)) {\n return node;\n }\n\n return getScrollParent(getParentNode(node));\n}","import getScrollParent from \"./getScrollParent.js\";\nimport getParentNode from \"./getParentNode.js\";\nimport getWindow from \"./getWindow.js\";\nimport isScrollParent from \"./isScrollParent.js\";\n/*\ngiven a DOM element, return the list of all scroll parents, up the list of ancesors\nuntil we get to the top window object. This list is what we attach scroll listeners\nto, because if any of these parent elements scroll, we'll need to re-calculate the\nreference element's position.\n*/\n\nexport default function listScrollParents(element, list) {\n var _element$ownerDocumen;\n\n if (list === void 0) {\n list = [];\n }\n\n var scrollParent = getScrollParent(element);\n var isBody = scrollParent === ((_element$ownerDocumen = element.ownerDocument) == null ? void 0 : _element$ownerDocumen.body);\n var win = getWindow(scrollParent);\n var target = isBody ? [win].concat(win.visualViewport || [], isScrollParent(scrollParent) ? scrollParent : []) : scrollParent;\n var updatedList = list.concat(target);\n return isBody ? updatedList : // $FlowFixMe[incompatible-call]: isBody tells us target will be an HTMLElement here\n updatedList.concat(listScrollParents(getParentNode(target)));\n}","export default function rectToClientRect(rect) {\n return Object.assign({}, rect, {\n left: rect.x,\n top: rect.y,\n right: rect.x + rect.width,\n bottom: rect.y + rect.height\n });\n}","import { viewport } from \"../enums.js\";\nimport getViewportRect from \"./getViewportRect.js\";\nimport getDocumentRect from \"./getDocumentRect.js\";\nimport listScrollParents from \"./listScrollParents.js\";\nimport getOffsetParent from \"./getOffsetParent.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport getComputedStyle from \"./getComputedStyle.js\";\nimport { isElement, isHTMLElement } from \"./instanceOf.js\";\nimport getBoundingClientRect from \"./getBoundingClientRect.js\";\nimport getParentNode from \"./getParentNode.js\";\nimport contains from \"./contains.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport rectToClientRect from \"../utils/rectToClientRect.js\";\nimport { max, min } from \"../utils/math.js\";\n\nfunction getInnerBoundingClientRect(element, strategy) {\n var rect = getBoundingClientRect(element, false, strategy === 'fixed');\n rect.top = rect.top + element.clientTop;\n rect.left = rect.left + element.clientLeft;\n rect.bottom = rect.top + element.clientHeight;\n rect.right = rect.left + element.clientWidth;\n rect.width = element.clientWidth;\n rect.height = element.clientHeight;\n rect.x = rect.left;\n rect.y = rect.top;\n return rect;\n}\n\nfunction getClientRectFromMixedType(element, clippingParent, strategy) {\n return clippingParent === viewport ? rectToClientRect(getViewportRect(element, strategy)) : isElement(clippingParent) ? getInnerBoundingClientRect(clippingParent, strategy) : rectToClientRect(getDocumentRect(getDocumentElement(element)));\n} // A \"clipping parent\" is an overflowable container with the characteristic of\n// clipping (or hiding) overflowing elements with a position different from\n// `initial`\n\n\nfunction getClippingParents(element) {\n var clippingParents = listScrollParents(getParentNode(element));\n var canEscapeClipping = ['absolute', 'fixed'].indexOf(getComputedStyle(element).position) >= 0;\n var clipperElement = canEscapeClipping && isHTMLElement(element) ? getOffsetParent(element) : element;\n\n if (!isElement(clipperElement)) {\n return [];\n } // $FlowFixMe[incompatible-return]: https://github.com/facebook/flow/issues/1414\n\n\n return clippingParents.filter(function (clippingParent) {\n return isElement(clippingParent) && contains(clippingParent, clipperElement) && getNodeName(clippingParent) !== 'body';\n });\n} // Gets the maximum area that the element is visible in due to any number of\n// clipping parents\n\n\nexport default function getClippingRect(element, boundary, rootBoundary, strategy) {\n var mainClippingParents = boundary === 'clippingParents' ? getClippingParents(element) : [].concat(boundary);\n var clippingParents = [].concat(mainClippingParents, [rootBoundary]);\n var firstClippingParent = clippingParents[0];\n var clippingRect = clippingParents.reduce(function (accRect, clippingParent) {\n var rect = getClientRectFromMixedType(element, clippingParent, strategy);\n accRect.top = max(rect.top, accRect.top);\n accRect.right = min(rect.right, accRect.right);\n accRect.bottom = min(rect.bottom, accRect.bottom);\n accRect.left = max(rect.left, accRect.left);\n return accRect;\n }, getClientRectFromMixedType(element, firstClippingParent, strategy));\n clippingRect.width = clippingRect.right - clippingRect.left;\n clippingRect.height = clippingRect.bottom - clippingRect.top;\n clippingRect.x = clippingRect.left;\n clippingRect.y = clippingRect.top;\n return clippingRect;\n}","import getBasePlacement from \"./getBasePlacement.js\";\nimport getVariation from \"./getVariation.js\";\nimport getMainAxisFromPlacement from \"./getMainAxisFromPlacement.js\";\nimport { top, right, bottom, left, start, end } from \"../enums.js\";\nexport default function computeOffsets(_ref) {\n var reference = _ref.reference,\n element = _ref.element,\n placement = _ref.placement;\n var basePlacement = placement ? getBasePlacement(placement) : null;\n var variation = placement ? getVariation(placement) : null;\n var commonX = reference.x + reference.width / 2 - element.width / 2;\n var commonY = reference.y + reference.height / 2 - element.height / 2;\n var offsets;\n\n switch (basePlacement) {\n case top:\n offsets = {\n x: commonX,\n y: reference.y - element.height\n };\n break;\n\n case bottom:\n offsets = {\n x: commonX,\n y: reference.y + reference.height\n };\n break;\n\n case right:\n offsets = {\n x: reference.x + reference.width,\n y: commonY\n };\n break;\n\n case left:\n offsets = {\n x: reference.x - element.width,\n y: commonY\n };\n break;\n\n default:\n offsets = {\n x: reference.x,\n y: reference.y\n };\n }\n\n var mainAxis = basePlacement ? getMainAxisFromPlacement(basePlacement) : null;\n\n if (mainAxis != null) {\n var len = mainAxis === 'y' ? 'height' : 'width';\n\n switch (variation) {\n case start:\n offsets[mainAxis] = offsets[mainAxis] - (reference[len] / 2 - element[len] / 2);\n break;\n\n case end:\n offsets[mainAxis] = offsets[mainAxis] + (reference[len] / 2 - element[len] / 2);\n break;\n\n default:\n }\n }\n\n return offsets;\n}","import getClippingRect from \"../dom-utils/getClippingRect.js\";\nimport getDocumentElement from \"../dom-utils/getDocumentElement.js\";\nimport getBoundingClientRect from \"../dom-utils/getBoundingClientRect.js\";\nimport computeOffsets from \"./computeOffsets.js\";\nimport rectToClientRect from \"./rectToClientRect.js\";\nimport { clippingParents, reference, popper, bottom, top, right, basePlacements, viewport } from \"../enums.js\";\nimport { isElement } from \"../dom-utils/instanceOf.js\";\nimport mergePaddingObject from \"./mergePaddingObject.js\";\nimport expandToHashMap from \"./expandToHashMap.js\"; // eslint-disable-next-line import/no-unused-modules\n\nexport default function detectOverflow(state, options) {\n if (options === void 0) {\n options = {};\n }\n\n var _options = options,\n _options$placement = _options.placement,\n placement = _options$placement === void 0 ? state.placement : _options$placement,\n _options$strategy = _options.strategy,\n strategy = _options$strategy === void 0 ? state.strategy : _options$strategy,\n _options$boundary = _options.boundary,\n boundary = _options$boundary === void 0 ? clippingParents : _options$boundary,\n _options$rootBoundary = _options.rootBoundary,\n rootBoundary = _options$rootBoundary === void 0 ? viewport : _options$rootBoundary,\n _options$elementConte = _options.elementContext,\n elementContext = _options$elementConte === void 0 ? popper : _options$elementConte,\n _options$altBoundary = _options.altBoundary,\n altBoundary = _options$altBoundary === void 0 ? false : _options$altBoundary,\n _options$padding = _options.padding,\n padding = _options$padding === void 0 ? 0 : _options$padding;\n var paddingObject = mergePaddingObject(typeof padding !== 'number' ? padding : expandToHashMap(padding, basePlacements));\n var altContext = elementContext === popper ? reference : popper;\n var popperRect = state.rects.popper;\n var element = state.elements[altBoundary ? altContext : elementContext];\n var clippingClientRect = getClippingRect(isElement(element) ? element : element.contextElement || getDocumentElement(state.elements.popper), boundary, rootBoundary, strategy);\n var referenceClientRect = getBoundingClientRect(state.elements.reference);\n var popperOffsets = computeOffsets({\n reference: referenceClientRect,\n element: popperRect,\n strategy: 'absolute',\n placement: placement\n });\n var popperClientRect = rectToClientRect(Object.assign({}, popperRect, popperOffsets));\n var elementClientRect = elementContext === popper ? popperClientRect : referenceClientRect; // positive = overflowing the clipping rect\n // 0 or negative = within the clipping rect\n\n var overflowOffsets = {\n top: clippingClientRect.top - elementClientRect.top + paddingObject.top,\n bottom: elementClientRect.bottom - clippingClientRect.bottom + paddingObject.bottom,\n left: clippingClientRect.left - elementClientRect.left + paddingObject.left,\n right: elementClientRect.right - clippingClientRect.right + paddingObject.right\n };\n var offsetData = state.modifiersData.offset; // Offsets can be applied only to the popper element\n\n if (elementContext === popper && offsetData) {\n var offset = offsetData[placement];\n Object.keys(overflowOffsets).forEach(function (key) {\n var multiply = [right, bottom].indexOf(key) >= 0 ? 1 : -1;\n var axis = [top, bottom].indexOf(key) >= 0 ? 'y' : 'x';\n overflowOffsets[key] += offset[axis] * multiply;\n });\n }\n\n return overflowOffsets;\n}","import getVariation from \"./getVariation.js\";\nimport { variationPlacements, basePlacements, placements as allPlacements } from \"../enums.js\";\nimport detectOverflow from \"./detectOverflow.js\";\nimport getBasePlacement from \"./getBasePlacement.js\";\nexport default function computeAutoPlacement(state, options) {\n if (options === void 0) {\n options = {};\n }\n\n var _options = options,\n placement = _options.placement,\n boundary = _options.boundary,\n rootBoundary = _options.rootBoundary,\n padding = _options.padding,\n flipVariations = _options.flipVariations,\n _options$allowedAutoP = _options.allowedAutoPlacements,\n allowedAutoPlacements = _options$allowedAutoP === void 0 ? allPlacements : _options$allowedAutoP;\n var variation = getVariation(placement);\n var placements = variation ? flipVariations ? variationPlacements : variationPlacements.filter(function (placement) {\n return getVariation(placement) === variation;\n }) : basePlacements;\n var allowedPlacements = placements.filter(function (placement) {\n return allowedAutoPlacements.indexOf(placement) >= 0;\n });\n\n if (allowedPlacements.length === 0) {\n allowedPlacements = placements;\n } // $FlowFixMe[incompatible-type]: Flow seems to have problems with two array unions...\n\n\n var overflows = allowedPlacements.reduce(function (acc, placement) {\n acc[placement] = detectOverflow(state, {\n placement: placement,\n boundary: boundary,\n rootBoundary: rootBoundary,\n padding: padding\n })[getBasePlacement(placement)];\n return acc;\n }, {});\n return Object.keys(overflows).sort(function (a, b) {\n return overflows[a] - overflows[b];\n });\n}","import getOppositePlacement from \"../utils/getOppositePlacement.js\";\nimport getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getOppositeVariationPlacement from \"../utils/getOppositeVariationPlacement.js\";\nimport detectOverflow from \"../utils/detectOverflow.js\";\nimport computeAutoPlacement from \"../utils/computeAutoPlacement.js\";\nimport { bottom, top, start, right, left, auto } from \"../enums.js\";\nimport getVariation from \"../utils/getVariation.js\"; // eslint-disable-next-line import/no-unused-modules\n\nfunction getExpandedFallbackPlacements(placement) {\n if (getBasePlacement(placement) === auto) {\n return [];\n }\n\n var oppositePlacement = getOppositePlacement(placement);\n return [getOppositeVariationPlacement(placement), oppositePlacement, getOppositeVariationPlacement(oppositePlacement)];\n}\n\nfunction flip(_ref) {\n var state = _ref.state,\n options = _ref.options,\n name = _ref.name;\n\n if (state.modifiersData[name]._skip) {\n return;\n }\n\n var _options$mainAxis = options.mainAxis,\n checkMainAxis = _options$mainAxis === void 0 ? true : _options$mainAxis,\n _options$altAxis = options.altAxis,\n checkAltAxis = _options$altAxis === void 0 ? true : _options$altAxis,\n specifiedFallbackPlacements = options.fallbackPlacements,\n padding = options.padding,\n boundary = options.boundary,\n rootBoundary = options.rootBoundary,\n altBoundary = options.altBoundary,\n _options$flipVariatio = options.flipVariations,\n flipVariations = _options$flipVariatio === void 0 ? true : _options$flipVariatio,\n allowedAutoPlacements = options.allowedAutoPlacements;\n var preferredPlacement = state.options.placement;\n var basePlacement = getBasePlacement(preferredPlacement);\n var isBasePlacement = basePlacement === preferredPlacement;\n var fallbackPlacements = specifiedFallbackPlacements || (isBasePlacement || !flipVariations ? [getOppositePlacement(preferredPlacement)] : getExpandedFallbackPlacements(preferredPlacement));\n var placements = [preferredPlacement].concat(fallbackPlacements).reduce(function (acc, placement) {\n return acc.concat(getBasePlacement(placement) === auto ? computeAutoPlacement(state, {\n placement: placement,\n boundary: boundary,\n rootBoundary: rootBoundary,\n padding: padding,\n flipVariations: flipVariations,\n allowedAutoPlacements: allowedAutoPlacements\n }) : placement);\n }, []);\n var referenceRect = state.rects.reference;\n var popperRect = state.rects.popper;\n var checksMap = new Map();\n var makeFallbackChecks = true;\n var firstFittingPlacement = placements[0];\n\n for (var i = 0; i < placements.length; i++) {\n var placement = placements[i];\n\n var _basePlacement = getBasePlacement(placement);\n\n var isStartVariation = getVariation(placement) === start;\n var isVertical = [top, bottom].indexOf(_basePlacement) >= 0;\n var len = isVertical ? 'width' : 'height';\n var overflow = detectOverflow(state, {\n placement: placement,\n boundary: boundary,\n rootBoundary: rootBoundary,\n altBoundary: altBoundary,\n padding: padding\n });\n var mainVariationSide = isVertical ? isStartVariation ? right : left : isStartVariation ? bottom : top;\n\n if (referenceRect[len] > popperRect[len]) {\n mainVariationSide = getOppositePlacement(mainVariationSide);\n }\n\n var altVariationSide = getOppositePlacement(mainVariationSide);\n var checks = [];\n\n if (checkMainAxis) {\n checks.push(overflow[_basePlacement] <= 0);\n }\n\n if (checkAltAxis) {\n checks.push(overflow[mainVariationSide] <= 0, overflow[altVariationSide] <= 0);\n }\n\n if (checks.every(function (check) {\n return check;\n })) {\n firstFittingPlacement = placement;\n makeFallbackChecks = false;\n break;\n }\n\n checksMap.set(placement, checks);\n }\n\n if (makeFallbackChecks) {\n // `2` may be desired in some cases – research later\n var numberOfChecks = flipVariations ? 3 : 1;\n\n var _loop = function _loop(_i) {\n var fittingPlacement = placements.find(function (placement) {\n var checks = checksMap.get(placement);\n\n if (checks) {\n return checks.slice(0, _i).every(function (check) {\n return check;\n });\n }\n });\n\n if (fittingPlacement) {\n firstFittingPlacement = fittingPlacement;\n return \"break\";\n }\n };\n\n for (var _i = numberOfChecks; _i > 0; _i--) {\n var _ret = _loop(_i);\n\n if (_ret === \"break\") break;\n }\n }\n\n if (state.placement !== firstFittingPlacement) {\n state.modifiersData[name]._skip = true;\n state.placement = firstFittingPlacement;\n state.reset = true;\n }\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'flip',\n enabled: true,\n phase: 'main',\n fn: flip,\n requiresIfExists: ['offset'],\n data: {\n _skip: false\n }\n};","import { top, bottom, left, right } from \"../enums.js\";\nimport detectOverflow from \"../utils/detectOverflow.js\";\n\nfunction getSideOffsets(overflow, rect, preventedOffsets) {\n if (preventedOffsets === void 0) {\n preventedOffsets = {\n x: 0,\n y: 0\n };\n }\n\n return {\n top: overflow.top - rect.height - preventedOffsets.y,\n right: overflow.right - rect.width + preventedOffsets.x,\n bottom: overflow.bottom - rect.height + preventedOffsets.y,\n left: overflow.left - rect.width - preventedOffsets.x\n };\n}\n\nfunction isAnySideFullyClipped(overflow) {\n return [top, right, bottom, left].some(function (side) {\n return overflow[side] >= 0;\n });\n}\n\nfunction hide(_ref) {\n var state = _ref.state,\n name = _ref.name;\n var referenceRect = state.rects.reference;\n var popperRect = state.rects.popper;\n var preventedOffsets = state.modifiersData.preventOverflow;\n var referenceOverflow = detectOverflow(state, {\n elementContext: 'reference'\n });\n var popperAltOverflow = detectOverflow(state, {\n altBoundary: true\n });\n var referenceClippingOffsets = getSideOffsets(referenceOverflow, referenceRect);\n var popperEscapeOffsets = getSideOffsets(popperAltOverflow, popperRect, preventedOffsets);\n var isReferenceHidden = isAnySideFullyClipped(referenceClippingOffsets);\n var hasPopperEscaped = isAnySideFullyClipped(popperEscapeOffsets);\n state.modifiersData[name] = {\n referenceClippingOffsets: referenceClippingOffsets,\n popperEscapeOffsets: popperEscapeOffsets,\n isReferenceHidden: isReferenceHidden,\n hasPopperEscaped: hasPopperEscaped\n };\n state.attributes.popper = Object.assign({}, state.attributes.popper, {\n 'data-popper-reference-hidden': isReferenceHidden,\n 'data-popper-escaped': hasPopperEscaped\n });\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'hide',\n enabled: true,\n phase: 'main',\n requiresIfExists: ['preventOverflow'],\n fn: hide\n};","import getBasePlacement from \"../utils/getBasePlacement.js\";\nimport { top, left, right, placements } from \"../enums.js\"; // eslint-disable-next-line import/no-unused-modules\n\nexport function distanceAndSkiddingToXY(placement, rects, offset) {\n var basePlacement = getBasePlacement(placement);\n var invertDistance = [left, top].indexOf(basePlacement) >= 0 ? -1 : 1;\n\n var _ref = typeof offset === 'function' ? offset(Object.assign({}, rects, {\n placement: placement\n })) : offset,\n skidding = _ref[0],\n distance = _ref[1];\n\n skidding = skidding || 0;\n distance = (distance || 0) * invertDistance;\n return [left, right].indexOf(basePlacement) >= 0 ? {\n x: distance,\n y: skidding\n } : {\n x: skidding,\n y: distance\n };\n}\n\nfunction offset(_ref2) {\n var state = _ref2.state,\n options = _ref2.options,\n name = _ref2.name;\n var _options$offset = options.offset,\n offset = _options$offset === void 0 ? [0, 0] : _options$offset;\n var data = placements.reduce(function (acc, placement) {\n acc[placement] = distanceAndSkiddingToXY(placement, state.rects, offset);\n return acc;\n }, {});\n var _data$state$placement = data[state.placement],\n x = _data$state$placement.x,\n y = _data$state$placement.y;\n\n if (state.modifiersData.popperOffsets != null) {\n state.modifiersData.popperOffsets.x += x;\n state.modifiersData.popperOffsets.y += y;\n }\n\n state.modifiersData[name] = data;\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'offset',\n enabled: true,\n phase: 'main',\n requires: ['popperOffsets'],\n fn: offset\n};","import computeOffsets from \"../utils/computeOffsets.js\";\n\nfunction popperOffsets(_ref) {\n var state = _ref.state,\n name = _ref.name;\n // Offsets are the actual position the popper needs to have to be\n // properly positioned near its reference element\n // This is the most basic placement, and will be adjusted by\n // the modifiers in the next step\n state.modifiersData[name] = computeOffsets({\n reference: state.rects.reference,\n element: state.rects.popper,\n strategy: 'absolute',\n placement: state.placement\n });\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'popperOffsets',\n enabled: true,\n phase: 'read',\n fn: popperOffsets,\n data: {}\n};","export default function getAltAxis(axis) {\n return axis === 'x' ? 'y' : 'x';\n}","import { top, left, right, bottom, start } from \"../enums.js\";\nimport getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getMainAxisFromPlacement from \"../utils/getMainAxisFromPlacement.js\";\nimport getAltAxis from \"../utils/getAltAxis.js\";\nimport { within, withinMaxClamp } from \"../utils/within.js\";\nimport getLayoutRect from \"../dom-utils/getLayoutRect.js\";\nimport getOffsetParent from \"../dom-utils/getOffsetParent.js\";\nimport detectOverflow from \"../utils/detectOverflow.js\";\nimport getVariation from \"../utils/getVariation.js\";\nimport getFreshSideObject from \"../utils/getFreshSideObject.js\";\nimport { min as mathMin, max as mathMax } from \"../utils/math.js\";\n\nfunction preventOverflow(_ref) {\n var state = _ref.state,\n options = _ref.options,\n name = _ref.name;\n var _options$mainAxis = options.mainAxis,\n checkMainAxis = _options$mainAxis === void 0 ? true : _options$mainAxis,\n _options$altAxis = options.altAxis,\n checkAltAxis = _options$altAxis === void 0 ? false : _options$altAxis,\n boundary = options.boundary,\n rootBoundary = options.rootBoundary,\n altBoundary = options.altBoundary,\n padding = options.padding,\n _options$tether = options.tether,\n tether = _options$tether === void 0 ? true : _options$tether,\n _options$tetherOffset = options.tetherOffset,\n tetherOffset = _options$tetherOffset === void 0 ? 0 : _options$tetherOffset;\n var overflow = detectOverflow(state, {\n boundary: boundary,\n rootBoundary: rootBoundary,\n padding: padding,\n altBoundary: altBoundary\n });\n var basePlacement = getBasePlacement(state.placement);\n var variation = getVariation(state.placement);\n var isBasePlacement = !variation;\n var mainAxis = getMainAxisFromPlacement(basePlacement);\n var altAxis = getAltAxis(mainAxis);\n var popperOffsets = state.modifiersData.popperOffsets;\n var referenceRect = state.rects.reference;\n var popperRect = state.rects.popper;\n var tetherOffsetValue = typeof tetherOffset === 'function' ? tetherOffset(Object.assign({}, state.rects, {\n placement: state.placement\n })) : tetherOffset;\n var normalizedTetherOffsetValue = typeof tetherOffsetValue === 'number' ? {\n mainAxis: tetherOffsetValue,\n altAxis: tetherOffsetValue\n } : Object.assign({\n mainAxis: 0,\n altAxis: 0\n }, tetherOffsetValue);\n var offsetModifierState = state.modifiersData.offset ? state.modifiersData.offset[state.placement] : null;\n var data = {\n x: 0,\n y: 0\n };\n\n if (!popperOffsets) {\n return;\n }\n\n if (checkMainAxis) {\n var _offsetModifierState$;\n\n var mainSide = mainAxis === 'y' ? top : left;\n var altSide = mainAxis === 'y' ? bottom : right;\n var len = mainAxis === 'y' ? 'height' : 'width';\n var offset = popperOffsets[mainAxis];\n var min = offset + overflow[mainSide];\n var max = offset - overflow[altSide];\n var additive = tether ? -popperRect[len] / 2 : 0;\n var minLen = variation === start ? referenceRect[len] : popperRect[len];\n var maxLen = variation === start ? -popperRect[len] : -referenceRect[len]; // We need to include the arrow in the calculation so the arrow doesn't go\n // outside the reference bounds\n\n var arrowElement = state.elements.arrow;\n var arrowRect = tether && arrowElement ? getLayoutRect(arrowElement) : {\n width: 0,\n height: 0\n };\n var arrowPaddingObject = state.modifiersData['arrow#persistent'] ? state.modifiersData['arrow#persistent'].padding : getFreshSideObject();\n var arrowPaddingMin = arrowPaddingObject[mainSide];\n var arrowPaddingMax = arrowPaddingObject[altSide]; // If the reference length is smaller than the arrow length, we don't want\n // to include its full size in the calculation. If the reference is small\n // and near the edge of a boundary, the popper can overflow even if the\n // reference is not overflowing as well (e.g. virtual elements with no\n // width or height)\n\n var arrowLen = within(0, referenceRect[len], arrowRect[len]);\n var minOffset = isBasePlacement ? referenceRect[len] / 2 - additive - arrowLen - arrowPaddingMin - normalizedTetherOffsetValue.mainAxis : minLen - arrowLen - arrowPaddingMin - normalizedTetherOffsetValue.mainAxis;\n var maxOffset = isBasePlacement ? -referenceRect[len] / 2 + additive + arrowLen + arrowPaddingMax + normalizedTetherOffsetValue.mainAxis : maxLen + arrowLen + arrowPaddingMax + normalizedTetherOffsetValue.mainAxis;\n var arrowOffsetParent = state.elements.arrow && getOffsetParent(state.elements.arrow);\n var clientOffset = arrowOffsetParent ? mainAxis === 'y' ? arrowOffsetParent.clientTop || 0 : arrowOffsetParent.clientLeft || 0 : 0;\n var offsetModifierValue = (_offsetModifierState$ = offsetModifierState == null ? void 0 : offsetModifierState[mainAxis]) != null ? _offsetModifierState$ : 0;\n var tetherMin = offset + minOffset - offsetModifierValue - clientOffset;\n var tetherMax = offset + maxOffset - offsetModifierValue;\n var preventedOffset = within(tether ? mathMin(min, tetherMin) : min, offset, tether ? mathMax(max, tetherMax) : max);\n popperOffsets[mainAxis] = preventedOffset;\n data[mainAxis] = preventedOffset - offset;\n }\n\n if (checkAltAxis) {\n var _offsetModifierState$2;\n\n var _mainSide = mainAxis === 'x' ? top : left;\n\n var _altSide = mainAxis === 'x' ? bottom : right;\n\n var _offset = popperOffsets[altAxis];\n\n var _len = altAxis === 'y' ? 'height' : 'width';\n\n var _min = _offset + overflow[_mainSide];\n\n var _max = _offset - overflow[_altSide];\n\n var isOriginSide = [top, left].indexOf(basePlacement) !== -1;\n\n var _offsetModifierValue = (_offsetModifierState$2 = offsetModifierState == null ? void 0 : offsetModifierState[altAxis]) != null ? _offsetModifierState$2 : 0;\n\n var _tetherMin = isOriginSide ? _min : _offset - referenceRect[_len] - popperRect[_len] - _offsetModifierValue + normalizedTetherOffsetValue.altAxis;\n\n var _tetherMax = isOriginSide ? _offset + referenceRect[_len] + popperRect[_len] - _offsetModifierValue - normalizedTetherOffsetValue.altAxis : _max;\n\n var _preventedOffset = tether && isOriginSide ? withinMaxClamp(_tetherMin, _offset, _tetherMax) : within(tether ? _tetherMin : _min, _offset, tether ? _tetherMax : _max);\n\n popperOffsets[altAxis] = _preventedOffset;\n data[altAxis] = _preventedOffset - _offset;\n }\n\n state.modifiersData[name] = data;\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'preventOverflow',\n enabled: true,\n phase: 'main',\n fn: preventOverflow,\n requiresIfExists: ['offset']\n};","export default function getHTMLElementScroll(element) {\n return {\n scrollLeft: element.scrollLeft,\n scrollTop: element.scrollTop\n };\n}","import getWindowScroll from \"./getWindowScroll.js\";\nimport getWindow from \"./getWindow.js\";\nimport { isHTMLElement } from \"./instanceOf.js\";\nimport getHTMLElementScroll from \"./getHTMLElementScroll.js\";\nexport default function getNodeScroll(node) {\n if (node === getWindow(node) || !isHTMLElement(node)) {\n return getWindowScroll(node);\n } else {\n return getHTMLElementScroll(node);\n }\n}","import getBoundingClientRect from \"./getBoundingClientRect.js\";\nimport getNodeScroll from \"./getNodeScroll.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport { isHTMLElement } from \"./instanceOf.js\";\nimport getWindowScrollBarX from \"./getWindowScrollBarX.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport isScrollParent from \"./isScrollParent.js\";\nimport { round } from \"../utils/math.js\";\n\nfunction isElementScaled(element) {\n var rect = element.getBoundingClientRect();\n var scaleX = round(rect.width) / element.offsetWidth || 1;\n var scaleY = round(rect.height) / element.offsetHeight || 1;\n return scaleX !== 1 || scaleY !== 1;\n} // Returns the composite rect of an element relative to its offsetParent.\n// Composite means it takes into account transforms as well as layout.\n\n\nexport default function getCompositeRect(elementOrVirtualElement, offsetParent, isFixed) {\n if (isFixed === void 0) {\n isFixed = false;\n }\n\n var isOffsetParentAnElement = isHTMLElement(offsetParent);\n var offsetParentIsScaled = isHTMLElement(offsetParent) && isElementScaled(offsetParent);\n var documentElement = getDocumentElement(offsetParent);\n var rect = getBoundingClientRect(elementOrVirtualElement, offsetParentIsScaled, isFixed);\n var scroll = {\n scrollLeft: 0,\n scrollTop: 0\n };\n var offsets = {\n x: 0,\n y: 0\n };\n\n if (isOffsetParentAnElement || !isOffsetParentAnElement && !isFixed) {\n if (getNodeName(offsetParent) !== 'body' || // https://github.com/popperjs/popper-core/issues/1078\n isScrollParent(documentElement)) {\n scroll = getNodeScroll(offsetParent);\n }\n\n if (isHTMLElement(offsetParent)) {\n offsets = getBoundingClientRect(offsetParent, true);\n offsets.x += offsetParent.clientLeft;\n offsets.y += offsetParent.clientTop;\n } else if (documentElement) {\n offsets.x = getWindowScrollBarX(documentElement);\n }\n }\n\n return {\n x: rect.left + scroll.scrollLeft - offsets.x,\n y: rect.top + scroll.scrollTop - offsets.y,\n width: rect.width,\n height: rect.height\n };\n}","import { modifierPhases } from \"../enums.js\"; // source: https://stackoverflow.com/questions/49875255\n\nfunction order(modifiers) {\n var map = new Map();\n var visited = new Set();\n var result = [];\n modifiers.forEach(function (modifier) {\n map.set(modifier.name, modifier);\n }); // On visiting object, check for its dependencies and visit them recursively\n\n function sort(modifier) {\n visited.add(modifier.name);\n var requires = [].concat(modifier.requires || [], modifier.requiresIfExists || []);\n requires.forEach(function (dep) {\n if (!visited.has(dep)) {\n var depModifier = map.get(dep);\n\n if (depModifier) {\n sort(depModifier);\n }\n }\n });\n result.push(modifier);\n }\n\n modifiers.forEach(function (modifier) {\n if (!visited.has(modifier.name)) {\n // check for visited object\n sort(modifier);\n }\n });\n return result;\n}\n\nexport default function orderModifiers(modifiers) {\n // order based on dependencies\n var orderedModifiers = order(modifiers); // order based on phase\n\n return modifierPhases.reduce(function (acc, phase) {\n return acc.concat(orderedModifiers.filter(function (modifier) {\n return modifier.phase === phase;\n }));\n }, []);\n}","export default function debounce(fn) {\n var pending;\n return function () {\n if (!pending) {\n pending = new Promise(function (resolve) {\n Promise.resolve().then(function () {\n pending = undefined;\n resolve(fn());\n });\n });\n }\n\n return pending;\n };\n}","export default function mergeByName(modifiers) {\n var merged = modifiers.reduce(function (merged, current) {\n var existing = merged[current.name];\n merged[current.name] = existing ? Object.assign({}, existing, current, {\n options: Object.assign({}, existing.options, current.options),\n data: Object.assign({}, existing.data, current.data)\n }) : current;\n return merged;\n }, {}); // IE11 does not support Object.values\n\n return Object.keys(merged).map(function (key) {\n return merged[key];\n });\n}","import getCompositeRect from \"./dom-utils/getCompositeRect.js\";\nimport getLayoutRect from \"./dom-utils/getLayoutRect.js\";\nimport listScrollParents from \"./dom-utils/listScrollParents.js\";\nimport getOffsetParent from \"./dom-utils/getOffsetParent.js\";\nimport orderModifiers from \"./utils/orderModifiers.js\";\nimport debounce from \"./utils/debounce.js\";\nimport mergeByName from \"./utils/mergeByName.js\";\nimport detectOverflow from \"./utils/detectOverflow.js\";\nimport { isElement } from \"./dom-utils/instanceOf.js\";\nvar DEFAULT_OPTIONS = {\n placement: 'bottom',\n modifiers: [],\n strategy: 'absolute'\n};\n\nfunction areValidElements() {\n for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {\n args[_key] = arguments[_key];\n }\n\n return !args.some(function (element) {\n return !(element && typeof element.getBoundingClientRect === 'function');\n });\n}\n\nexport function popperGenerator(generatorOptions) {\n if (generatorOptions === void 0) {\n generatorOptions = {};\n }\n\n var _generatorOptions = generatorOptions,\n _generatorOptions$def = _generatorOptions.defaultModifiers,\n defaultModifiers = _generatorOptions$def === void 0 ? [] : _generatorOptions$def,\n _generatorOptions$def2 = _generatorOptions.defaultOptions,\n defaultOptions = _generatorOptions$def2 === void 0 ? DEFAULT_OPTIONS : _generatorOptions$def2;\n return function createPopper(reference, popper, options) {\n if (options === void 0) {\n options = defaultOptions;\n }\n\n var state = {\n placement: 'bottom',\n orderedModifiers: [],\n options: Object.assign({}, DEFAULT_OPTIONS, defaultOptions),\n modifiersData: {},\n elements: {\n reference: reference,\n popper: popper\n },\n attributes: {},\n styles: {}\n };\n var effectCleanupFns = [];\n var isDestroyed = false;\n var instance = {\n state: state,\n setOptions: function setOptions(setOptionsAction) {\n var options = typeof setOptionsAction === 'function' ? setOptionsAction(state.options) : setOptionsAction;\n cleanupModifierEffects();\n state.options = Object.assign({}, defaultOptions, state.options, options);\n state.scrollParents = {\n reference: isElement(reference) ? listScrollParents(reference) : reference.contextElement ? listScrollParents(reference.contextElement) : [],\n popper: listScrollParents(popper)\n }; // Orders the modifiers based on their dependencies and `phase`\n // properties\n\n var orderedModifiers = orderModifiers(mergeByName([].concat(defaultModifiers, state.options.modifiers))); // Strip out disabled modifiers\n\n state.orderedModifiers = orderedModifiers.filter(function (m) {\n return m.enabled;\n });\n runModifierEffects();\n return instance.update();\n },\n // Sync update – it will always be executed, even if not necessary. This\n // is useful for low frequency updates where sync behavior simplifies the\n // logic.\n // For high frequency updates (e.g. `resize` and `scroll` events), always\n // prefer the async Popper#update method\n forceUpdate: function forceUpdate() {\n if (isDestroyed) {\n return;\n }\n\n var _state$elements = state.elements,\n reference = _state$elements.reference,\n popper = _state$elements.popper; // Don't proceed if `reference` or `popper` are not valid elements\n // anymore\n\n if (!areValidElements(reference, popper)) {\n return;\n } // Store the reference and popper rects to be read by modifiers\n\n\n state.rects = {\n reference: getCompositeRect(reference, getOffsetParent(popper), state.options.strategy === 'fixed'),\n popper: getLayoutRect(popper)\n }; // Modifiers have the ability to reset the current update cycle. The\n // most common use case for this is the `flip` modifier changing the\n // placement, which then needs to re-run all the modifiers, because the\n // logic was previously ran for the previous placement and is therefore\n // stale/incorrect\n\n state.reset = false;\n state.placement = state.options.placement; // On each update cycle, the `modifiersData` property for each modifier\n // is filled with the initial data specified by the modifier. This means\n // it doesn't persist and is fresh on each update.\n // To ensure persistent data, use `${name}#persistent`\n\n state.orderedModifiers.forEach(function (modifier) {\n return state.modifiersData[modifier.name] = Object.assign({}, modifier.data);\n });\n\n for (var index = 0; index < state.orderedModifiers.length; index++) {\n if (state.reset === true) {\n state.reset = false;\n index = -1;\n continue;\n }\n\n var _state$orderedModifie = state.orderedModifiers[index],\n fn = _state$orderedModifie.fn,\n _state$orderedModifie2 = _state$orderedModifie.options,\n _options = _state$orderedModifie2 === void 0 ? {} : _state$orderedModifie2,\n name = _state$orderedModifie.name;\n\n if (typeof fn === 'function') {\n state = fn({\n state: state,\n options: _options,\n name: name,\n instance: instance\n }) || state;\n }\n }\n },\n // Async and optimistically optimized update – it will not be executed if\n // not necessary (debounced to run at most once-per-tick)\n update: debounce(function () {\n return new Promise(function (resolve) {\n instance.forceUpdate();\n resolve(state);\n });\n }),\n destroy: function destroy() {\n cleanupModifierEffects();\n isDestroyed = true;\n }\n };\n\n if (!areValidElements(reference, popper)) {\n return instance;\n }\n\n instance.setOptions(options).then(function (state) {\n if (!isDestroyed && options.onFirstUpdate) {\n options.onFirstUpdate(state);\n }\n }); // Modifiers have the ability to execute arbitrary code before the first\n // update cycle runs. They will be executed in the same order as the update\n // cycle. This is useful when a modifier adds some persistent data that\n // other modifiers need to use, but the modifier is run after the dependent\n // one.\n\n function runModifierEffects() {\n state.orderedModifiers.forEach(function (_ref) {\n var name = _ref.name,\n _ref$options = _ref.options,\n options = _ref$options === void 0 ? {} : _ref$options,\n effect = _ref.effect;\n\n if (typeof effect === 'function') {\n var cleanupFn = effect({\n state: state,\n name: name,\n instance: instance,\n options: options\n });\n\n var noopFn = function noopFn() {};\n\n effectCleanupFns.push(cleanupFn || noopFn);\n }\n });\n }\n\n function cleanupModifierEffects() {\n effectCleanupFns.forEach(function (fn) {\n return fn();\n });\n effectCleanupFns = [];\n }\n\n return instance;\n };\n}\nexport var createPopper = /*#__PURE__*/popperGenerator(); // eslint-disable-next-line import/no-unused-modules\n\nexport { detectOverflow };","import { popperGenerator, detectOverflow } from \"./createPopper.js\";\nimport eventListeners from \"./modifiers/eventListeners.js\";\nimport popperOffsets from \"./modifiers/popperOffsets.js\";\nimport computeStyles from \"./modifiers/computeStyles.js\";\nimport applyStyles from \"./modifiers/applyStyles.js\";\nimport offset from \"./modifiers/offset.js\";\nimport flip from \"./modifiers/flip.js\";\nimport preventOverflow from \"./modifiers/preventOverflow.js\";\nimport arrow from \"./modifiers/arrow.js\";\nimport hide from \"./modifiers/hide.js\";\nvar defaultModifiers = [eventListeners, popperOffsets, computeStyles, applyStyles, offset, flip, preventOverflow, arrow, hide];\nvar createPopper = /*#__PURE__*/popperGenerator({\n defaultModifiers: defaultModifiers\n}); // eslint-disable-next-line import/no-unused-modules\n\nexport { createPopper, popperGenerator, defaultModifiers, detectOverflow }; // eslint-disable-next-line import/no-unused-modules\n\nexport { createPopper as createPopperLite } from \"./popper-lite.js\"; // eslint-disable-next-line import/no-unused-modules\n\nexport * from \"./modifiers/index.js\";","import { generateUtilityClass } from '../generateUtilityClass';\nimport { generateUtilityClasses } from '../generateUtilityClasses';\nconst COMPONENT_NAME = 'Popper';\nexport function getPopperUtilityClass(slot) {\n return generateUtilityClass(COMPONENT_NAME, slot);\n}\nexport const popperClasses = generateUtilityClasses(COMPONENT_NAME, ['root']);","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"anchorEl\", \"children\", \"direction\", \"disablePortal\", \"modifiers\", \"open\", \"placement\", \"popperOptions\", \"popperRef\", \"slotProps\", \"slots\", \"TransitionProps\", \"ownerState\"],\n _excluded2 = [\"anchorEl\", \"children\", \"container\", \"direction\", \"disablePortal\", \"keepMounted\", \"modifiers\", \"open\", \"placement\", \"popperOptions\", \"popperRef\", \"style\", \"transition\", \"slotProps\", \"slots\"];\nimport * as React from 'react';\nimport { chainPropTypes, HTMLElementType, refType, unstable_ownerDocument as ownerDocument, unstable_useEnhancedEffect as useEnhancedEffect, unstable_useForkRef as useForkRef } from '@mui/utils';\nimport { createPopper } from '@popperjs/core';\nimport PropTypes from 'prop-types';\nimport { unstable_composeClasses as composeClasses } from '../composeClasses';\nimport { Portal } from '../Portal';\nimport { getPopperUtilityClass } from './popperClasses';\nimport { useSlotProps } from '../utils';\nimport { useClassNamesOverride } from '../utils/ClassNameConfigurator';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nfunction flipPlacement(placement, direction) {\n if (direction === 'ltr') {\n return placement;\n }\n switch (placement) {\n case 'bottom-end':\n return 'bottom-start';\n case 'bottom-start':\n return 'bottom-end';\n case 'top-end':\n return 'top-start';\n case 'top-start':\n return 'top-end';\n default:\n return placement;\n }\n}\nfunction resolveAnchorEl(anchorEl) {\n return typeof anchorEl === 'function' ? anchorEl() : anchorEl;\n}\nfunction isHTMLElement(element) {\n return element.nodeType !== undefined;\n}\nfunction isVirtualElement(element) {\n return !isHTMLElement(element);\n}\nconst useUtilityClasses = () => {\n const slots = {\n root: ['root']\n };\n return composeClasses(slots, useClassNamesOverride(getPopperUtilityClass));\n};\nconst defaultPopperOptions = {};\nconst PopperTooltip = /*#__PURE__*/React.forwardRef(function PopperTooltip(props, forwardedRef) {\n var _slots$root;\n const {\n anchorEl,\n children,\n direction,\n disablePortal,\n modifiers,\n open,\n placement: initialPlacement,\n popperOptions,\n popperRef: popperRefProp,\n slotProps = {},\n slots = {},\n TransitionProps\n // @ts-ignore internal logic\n // prevent from spreading to DOM, it can come from the parent component e.g. Select.\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const tooltipRef = React.useRef(null);\n const ownRef = useForkRef(tooltipRef, forwardedRef);\n const popperRef = React.useRef(null);\n const handlePopperRef = useForkRef(popperRef, popperRefProp);\n const handlePopperRefRef = React.useRef(handlePopperRef);\n useEnhancedEffect(() => {\n handlePopperRefRef.current = handlePopperRef;\n }, [handlePopperRef]);\n React.useImperativeHandle(popperRefProp, () => popperRef.current, []);\n const rtlPlacement = flipPlacement(initialPlacement, direction);\n /**\n * placement initialized from prop but can change during lifetime if modifiers.flip.\n * modifiers.flip is essentially a flip for controlled/uncontrolled behavior\n */\n const [placement, setPlacement] = React.useState(rtlPlacement);\n const [resolvedAnchorElement, setResolvedAnchorElement] = React.useState(resolveAnchorEl(anchorEl));\n React.useEffect(() => {\n if (popperRef.current) {\n popperRef.current.forceUpdate();\n }\n });\n React.useEffect(() => {\n if (anchorEl) {\n setResolvedAnchorElement(resolveAnchorEl(anchorEl));\n }\n }, [anchorEl]);\n useEnhancedEffect(() => {\n if (!resolvedAnchorElement || !open) {\n return undefined;\n }\n const handlePopperUpdate = data => {\n setPlacement(data.placement);\n };\n if (process.env.NODE_ENV !== 'production') {\n if (resolvedAnchorElement && isHTMLElement(resolvedAnchorElement) && resolvedAnchorElement.nodeType === 1) {\n const box = resolvedAnchorElement.getBoundingClientRect();\n if (process.env.NODE_ENV !== 'test' && box.top === 0 && box.left === 0 && box.right === 0 && box.bottom === 0) {\n console.warn(['MUI: The `anchorEl` prop provided to the component is invalid.', 'The anchor element should be part of the document layout.', \"Make sure the element is present in the document or that it's not display none.\"].join('\\n'));\n }\n }\n }\n let popperModifiers = [{\n name: 'preventOverflow',\n options: {\n altBoundary: disablePortal\n }\n }, {\n name: 'flip',\n options: {\n altBoundary: disablePortal\n }\n }, {\n name: 'onUpdate',\n enabled: true,\n phase: 'afterWrite',\n fn: ({\n state\n }) => {\n handlePopperUpdate(state);\n }\n }];\n if (modifiers != null) {\n popperModifiers = popperModifiers.concat(modifiers);\n }\n if (popperOptions && popperOptions.modifiers != null) {\n popperModifiers = popperModifiers.concat(popperOptions.modifiers);\n }\n const popper = createPopper(resolvedAnchorElement, tooltipRef.current, _extends({\n placement: rtlPlacement\n }, popperOptions, {\n modifiers: popperModifiers\n }));\n handlePopperRefRef.current(popper);\n return () => {\n popper.destroy();\n handlePopperRefRef.current(null);\n };\n }, [resolvedAnchorElement, disablePortal, modifiers, open, popperOptions, rtlPlacement]);\n const childProps = {\n placement: placement\n };\n if (TransitionProps !== null) {\n childProps.TransitionProps = TransitionProps;\n }\n const classes = useUtilityClasses();\n const Root = (_slots$root = slots.root) != null ? _slots$root : 'div';\n const rootProps = useSlotProps({\n elementType: Root,\n externalSlotProps: slotProps.root,\n externalForwardedProps: other,\n additionalProps: {\n role: 'tooltip',\n ref: ownRef\n },\n ownerState: props,\n className: classes.root\n });\n return /*#__PURE__*/_jsx(Root, _extends({}, rootProps, {\n children: typeof children === 'function' ? children(childProps) : children\n }));\n});\n\n/**\n * Poppers rely on the 3rd party library [Popper.js](https://popper.js.org/docs/v2/) for positioning.\n *\n * Demos:\n *\n * - [Popper](https://mui.com/base-ui/react-popper/)\n *\n * API:\n *\n * - [Popper API](https://mui.com/base-ui/react-popper/components-api/#popper)\n */\nconst Popper = /*#__PURE__*/React.forwardRef(function Popper(props, forwardedRef) {\n const {\n anchorEl,\n children,\n container: containerProp,\n direction = 'ltr',\n disablePortal = false,\n keepMounted = false,\n modifiers,\n open,\n placement = 'bottom',\n popperOptions = defaultPopperOptions,\n popperRef,\n style,\n transition = false,\n slotProps = {},\n slots = {}\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded2);\n const [exited, setExited] = React.useState(true);\n const handleEnter = () => {\n setExited(false);\n };\n const handleExited = () => {\n setExited(true);\n };\n if (!keepMounted && !open && (!transition || exited)) {\n return null;\n }\n\n // If the container prop is provided, use that\n // If the anchorEl prop is provided, use its parent body element as the container\n // If neither are provided let the Modal take care of choosing the container\n let container;\n if (containerProp) {\n container = containerProp;\n } else if (anchorEl) {\n const resolvedAnchorEl = resolveAnchorEl(anchorEl);\n container = resolvedAnchorEl && isHTMLElement(resolvedAnchorEl) ? ownerDocument(resolvedAnchorEl).body : ownerDocument(null).body;\n }\n const display = !open && keepMounted && (!transition || exited) ? 'none' : undefined;\n const transitionProps = transition ? {\n in: open,\n onEnter: handleEnter,\n onExited: handleExited\n } : undefined;\n return /*#__PURE__*/_jsx(Portal, {\n disablePortal: disablePortal,\n container: container,\n children: /*#__PURE__*/_jsx(PopperTooltip, _extends({\n anchorEl: anchorEl,\n direction: direction,\n disablePortal: disablePortal,\n modifiers: modifiers,\n ref: forwardedRef,\n open: transition ? !exited : open,\n placement: placement,\n popperOptions: popperOptions,\n popperRef: popperRef,\n slotProps: slotProps,\n slots: slots\n }, other, {\n style: _extends({\n // Prevents scroll issue, waiting for Popper.js to add this style once initiated.\n position: 'fixed',\n // Fix Popper.js display issue\n top: 0,\n left: 0,\n display\n }, style),\n TransitionProps: transitionProps,\n children: children\n }))\n });\n});\nprocess.env.NODE_ENV !== \"production\" ? Popper.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * An HTML element, [virtualElement](https://popper.js.org/docs/v2/virtual-elements/),\n * or a function that returns either.\n * It's used to set the position of the popper.\n * The return value will passed as the reference object of the Popper instance.\n */\n anchorEl: chainPropTypes(PropTypes.oneOfType([HTMLElementType, PropTypes.object, PropTypes.func]), props => {\n if (props.open) {\n const resolvedAnchorEl = resolveAnchorEl(props.anchorEl);\n if (resolvedAnchorEl && isHTMLElement(resolvedAnchorEl) && resolvedAnchorEl.nodeType === 1) {\n const box = resolvedAnchorEl.getBoundingClientRect();\n if (process.env.NODE_ENV !== 'test' && box.top === 0 && box.left === 0 && box.right === 0 && box.bottom === 0) {\n return new Error(['MUI: The `anchorEl` prop provided to the component is invalid.', 'The anchor element should be part of the document layout.', \"Make sure the element is present in the document or that it's not display none.\"].join('\\n'));\n }\n } else if (!resolvedAnchorEl || typeof resolvedAnchorEl.getBoundingClientRect !== 'function' || isVirtualElement(resolvedAnchorEl) && resolvedAnchorEl.contextElement != null && resolvedAnchorEl.contextElement.nodeType !== 1) {\n return new Error(['MUI: The `anchorEl` prop provided to the component is invalid.', 'It should be an HTML element instance or a virtualElement ', '(https://popper.js.org/docs/v2/virtual-elements/).'].join('\\n'));\n }\n }\n return null;\n }),\n /**\n * Popper render function or node.\n */\n children: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.node, PropTypes.func]),\n /**\n * An HTML element or function that returns one.\n * The `container` will have the portal children appended to it.\n *\n * You can also provide a callback, which is called in a React layout effect.\n * This lets you set the container from a ref, and also makes server-side rendering possible.\n *\n * By default, it uses the body of the top-level document object,\n * so it's simply `document.body` most of the time.\n */\n container: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.func]),\n /**\n * Direction of the text.\n * @default 'ltr'\n */\n direction: PropTypes.oneOf(['ltr', 'rtl']),\n /**\n * The `children` will be under the DOM hierarchy of the parent component.\n * @default false\n */\n disablePortal: PropTypes.bool,\n /**\n * Always keep the children in the DOM.\n * This prop can be useful in SEO situation or\n * when you want to maximize the responsiveness of the Popper.\n * @default false\n */\n keepMounted: PropTypes.bool,\n /**\n * Popper.js is based on a \"plugin-like\" architecture,\n * most of its features are fully encapsulated \"modifiers\".\n *\n * A modifier is a function that is called each time Popper.js needs to\n * compute the position of the popper.\n * For this reason, modifiers should be very performant to avoid bottlenecks.\n * To learn how to create a modifier, [read the modifiers documentation](https://popper.js.org/docs/v2/modifiers/).\n */\n modifiers: PropTypes.arrayOf(PropTypes.shape({\n data: PropTypes.object,\n effect: PropTypes.func,\n enabled: PropTypes.bool,\n fn: PropTypes.func,\n name: PropTypes.any,\n options: PropTypes.object,\n phase: PropTypes.oneOf(['afterMain', 'afterRead', 'afterWrite', 'beforeMain', 'beforeRead', 'beforeWrite', 'main', 'read', 'write']),\n requires: PropTypes.arrayOf(PropTypes.string),\n requiresIfExists: PropTypes.arrayOf(PropTypes.string)\n })),\n /**\n * If `true`, the component is shown.\n */\n open: PropTypes.bool.isRequired,\n /**\n * Popper placement.\n * @default 'bottom'\n */\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n /**\n * Options provided to the [`Popper.js`](https://popper.js.org/docs/v2/constructors/#options) instance.\n * @default {}\n */\n popperOptions: PropTypes.shape({\n modifiers: PropTypes.array,\n onFirstUpdate: PropTypes.func,\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n strategy: PropTypes.oneOf(['absolute', 'fixed'])\n }),\n /**\n * A ref that points to the used popper instance.\n */\n popperRef: refType,\n /**\n * The props used for each slot inside the Popper.\n * @default {}\n */\n slotProps: PropTypes.shape({\n root: PropTypes.oneOfType([PropTypes.func, PropTypes.object])\n }),\n /**\n * The components used for each slot inside the Popper.\n * Either a string to use a HTML element or a component.\n * @default {}\n */\n slots: PropTypes.shape({\n root: PropTypes.elementType\n }),\n /**\n * Help supporting a react-transition-group/Transition component.\n * @default false\n */\n transition: PropTypes.bool\n} : void 0;\nexport { Popper };","'use client';\n\nimport * as React from 'react';\nimport { useTheme as useThemeSystem } from '@mui/system';\nimport defaultTheme from './defaultTheme';\nimport THEME_ID from './identifier';\nexport default function useTheme() {\n const theme = useThemeSystem(defaultTheme);\n if (process.env.NODE_ENV !== 'production') {\n // eslint-disable-next-line react-hooks/rules-of-hooks\n React.useDebugValue(theme);\n }\n return theme[THEME_ID] || theme;\n}","export default function _setPrototypeOf(o, p) {\n _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function _setPrototypeOf(o, p) {\n o.__proto__ = p;\n return o;\n };\n return _setPrototypeOf(o, p);\n}","import setPrototypeOf from \"./setPrototypeOf.js\";\nexport default function _inheritsLoose(subClass, superClass) {\n subClass.prototype = Object.create(superClass.prototype);\n subClass.prototype.constructor = subClass;\n setPrototypeOf(subClass, superClass);\n}","export default {\n disabled: false\n};","import PropTypes from 'prop-types';\nexport var timeoutsShape = process.env.NODE_ENV !== 'production' ? PropTypes.oneOfType([PropTypes.number, PropTypes.shape({\n enter: PropTypes.number,\n exit: PropTypes.number,\n appear: PropTypes.number\n}).isRequired]) : null;\nexport var classNamesShape = process.env.NODE_ENV !== 'production' ? PropTypes.oneOfType([PropTypes.string, PropTypes.shape({\n enter: PropTypes.string,\n exit: PropTypes.string,\n active: PropTypes.string\n}), PropTypes.shape({\n enter: PropTypes.string,\n enterDone: PropTypes.string,\n enterActive: PropTypes.string,\n exit: PropTypes.string,\n exitDone: PropTypes.string,\n exitActive: PropTypes.string\n})]) : null;","import React from 'react';\nexport default React.createContext(null);","export var forceReflow = function forceReflow(node) {\n return node.scrollTop;\n};","import _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _inheritsLoose from \"@babel/runtime/helpers/esm/inheritsLoose\";\nimport PropTypes from 'prop-types';\nimport React from 'react';\nimport ReactDOM from 'react-dom';\nimport config from './config';\nimport { timeoutsShape } from './utils/PropTypes';\nimport TransitionGroupContext from './TransitionGroupContext';\nimport { forceReflow } from './utils/reflow';\nexport var UNMOUNTED = 'unmounted';\nexport var EXITED = 'exited';\nexport var ENTERING = 'entering';\nexport var ENTERED = 'entered';\nexport var EXITING = 'exiting';\n/**\n * The Transition component lets you describe a transition from one component\n * state to another _over time_ with a simple declarative API. Most commonly\n * it's used to animate the mounting and unmounting of a component, but can also\n * be used to describe in-place transition states as well.\n *\n * ---\n *\n * **Note**: `Transition` is a platform-agnostic base component. If you're using\n * transitions in CSS, you'll probably want to use\n * [`CSSTransition`](https://reactcommunity.org/react-transition-group/css-transition)\n * instead. It inherits all the features of `Transition`, but contains\n * additional features necessary to play nice with CSS transitions (hence the\n * name of the component).\n *\n * ---\n *\n * By default the `Transition` component does not alter the behavior of the\n * component it renders, it only tracks \"enter\" and \"exit\" states for the\n * components. It's up to you to give meaning and effect to those states. For\n * example we can add styles to a component when it enters or exits:\n *\n * ```jsx\n * import { Transition } from 'react-transition-group';\n *\n * const duration = 300;\n *\n * const defaultStyle = {\n * transition: `opacity ${duration}ms ease-in-out`,\n * opacity: 0,\n * }\n *\n * const transitionStyles = {\n * entering: { opacity: 1 },\n * entered: { opacity: 1 },\n * exiting: { opacity: 0 },\n * exited: { opacity: 0 },\n * };\n *\n * const Fade = ({ in: inProp }) => (\n * \n * {state => (\n *
    \n * I'm a fade Transition!\n *
    \n * )}\n *
    \n * );\n * ```\n *\n * There are 4 main states a Transition can be in:\n * - `'entering'`\n * - `'entered'`\n * - `'exiting'`\n * - `'exited'`\n *\n * Transition state is toggled via the `in` prop. When `true` the component\n * begins the \"Enter\" stage. During this stage, the component will shift from\n * its current transition state, to `'entering'` for the duration of the\n * transition and then to the `'entered'` stage once it's complete. Let's take\n * the following example (we'll use the\n * [useState](https://reactjs.org/docs/hooks-reference.html#usestate) hook):\n *\n * ```jsx\n * function App() {\n * const [inProp, setInProp] = useState(false);\n * return (\n *
    \n * \n * {state => (\n * // ...\n * )}\n * \n * \n *
    \n * );\n * }\n * ```\n *\n * When the button is clicked the component will shift to the `'entering'` state\n * and stay there for 500ms (the value of `timeout`) before it finally switches\n * to `'entered'`.\n *\n * When `in` is `false` the same thing happens except the state moves from\n * `'exiting'` to `'exited'`.\n */\n\nvar Transition = /*#__PURE__*/function (_React$Component) {\n _inheritsLoose(Transition, _React$Component);\n\n function Transition(props, context) {\n var _this;\n\n _this = _React$Component.call(this, props, context) || this;\n var parentGroup = context; // In the context of a TransitionGroup all enters are really appears\n\n var appear = parentGroup && !parentGroup.isMounting ? props.enter : props.appear;\n var initialStatus;\n _this.appearStatus = null;\n\n if (props.in) {\n if (appear) {\n initialStatus = EXITED;\n _this.appearStatus = ENTERING;\n } else {\n initialStatus = ENTERED;\n }\n } else {\n if (props.unmountOnExit || props.mountOnEnter) {\n initialStatus = UNMOUNTED;\n } else {\n initialStatus = EXITED;\n }\n }\n\n _this.state = {\n status: initialStatus\n };\n _this.nextCallback = null;\n return _this;\n }\n\n Transition.getDerivedStateFromProps = function getDerivedStateFromProps(_ref, prevState) {\n var nextIn = _ref.in;\n\n if (nextIn && prevState.status === UNMOUNTED) {\n return {\n status: EXITED\n };\n }\n\n return null;\n } // getSnapshotBeforeUpdate(prevProps) {\n // let nextStatus = null\n // if (prevProps !== this.props) {\n // const { status } = this.state\n // if (this.props.in) {\n // if (status !== ENTERING && status !== ENTERED) {\n // nextStatus = ENTERING\n // }\n // } else {\n // if (status === ENTERING || status === ENTERED) {\n // nextStatus = EXITING\n // }\n // }\n // }\n // return { nextStatus }\n // }\n ;\n\n var _proto = Transition.prototype;\n\n _proto.componentDidMount = function componentDidMount() {\n this.updateStatus(true, this.appearStatus);\n };\n\n _proto.componentDidUpdate = function componentDidUpdate(prevProps) {\n var nextStatus = null;\n\n if (prevProps !== this.props) {\n var status = this.state.status;\n\n if (this.props.in) {\n if (status !== ENTERING && status !== ENTERED) {\n nextStatus = ENTERING;\n }\n } else {\n if (status === ENTERING || status === ENTERED) {\n nextStatus = EXITING;\n }\n }\n }\n\n this.updateStatus(false, nextStatus);\n };\n\n _proto.componentWillUnmount = function componentWillUnmount() {\n this.cancelNextCallback();\n };\n\n _proto.getTimeouts = function getTimeouts() {\n var timeout = this.props.timeout;\n var exit, enter, appear;\n exit = enter = appear = timeout;\n\n if (timeout != null && typeof timeout !== 'number') {\n exit = timeout.exit;\n enter = timeout.enter; // TODO: remove fallback for next major\n\n appear = timeout.appear !== undefined ? timeout.appear : enter;\n }\n\n return {\n exit: exit,\n enter: enter,\n appear: appear\n };\n };\n\n _proto.updateStatus = function updateStatus(mounting, nextStatus) {\n if (mounting === void 0) {\n mounting = false;\n }\n\n if (nextStatus !== null) {\n // nextStatus will always be ENTERING or EXITING.\n this.cancelNextCallback();\n\n if (nextStatus === ENTERING) {\n if (this.props.unmountOnExit || this.props.mountOnEnter) {\n var node = this.props.nodeRef ? this.props.nodeRef.current : ReactDOM.findDOMNode(this); // https://github.com/reactjs/react-transition-group/pull/749\n // With unmountOnExit or mountOnEnter, the enter animation should happen at the transition between `exited` and `entering`.\n // To make the animation happen, we have to separate each rendering and avoid being processed as batched.\n\n if (node) forceReflow(node);\n }\n\n this.performEnter(mounting);\n } else {\n this.performExit();\n }\n } else if (this.props.unmountOnExit && this.state.status === EXITED) {\n this.setState({\n status: UNMOUNTED\n });\n }\n };\n\n _proto.performEnter = function performEnter(mounting) {\n var _this2 = this;\n\n var enter = this.props.enter;\n var appearing = this.context ? this.context.isMounting : mounting;\n\n var _ref2 = this.props.nodeRef ? [appearing] : [ReactDOM.findDOMNode(this), appearing],\n maybeNode = _ref2[0],\n maybeAppearing = _ref2[1];\n\n var timeouts = this.getTimeouts();\n var enterTimeout = appearing ? timeouts.appear : timeouts.enter; // no enter animation skip right to ENTERED\n // if we are mounting and running this it means appear _must_ be set\n\n if (!mounting && !enter || config.disabled) {\n this.safeSetState({\n status: ENTERED\n }, function () {\n _this2.props.onEntered(maybeNode);\n });\n return;\n }\n\n this.props.onEnter(maybeNode, maybeAppearing);\n this.safeSetState({\n status: ENTERING\n }, function () {\n _this2.props.onEntering(maybeNode, maybeAppearing);\n\n _this2.onTransitionEnd(enterTimeout, function () {\n _this2.safeSetState({\n status: ENTERED\n }, function () {\n _this2.props.onEntered(maybeNode, maybeAppearing);\n });\n });\n });\n };\n\n _proto.performExit = function performExit() {\n var _this3 = this;\n\n var exit = this.props.exit;\n var timeouts = this.getTimeouts();\n var maybeNode = this.props.nodeRef ? undefined : ReactDOM.findDOMNode(this); // no exit animation skip right to EXITED\n\n if (!exit || config.disabled) {\n this.safeSetState({\n status: EXITED\n }, function () {\n _this3.props.onExited(maybeNode);\n });\n return;\n }\n\n this.props.onExit(maybeNode);\n this.safeSetState({\n status: EXITING\n }, function () {\n _this3.props.onExiting(maybeNode);\n\n _this3.onTransitionEnd(timeouts.exit, function () {\n _this3.safeSetState({\n status: EXITED\n }, function () {\n _this3.props.onExited(maybeNode);\n });\n });\n });\n };\n\n _proto.cancelNextCallback = function cancelNextCallback() {\n if (this.nextCallback !== null) {\n this.nextCallback.cancel();\n this.nextCallback = null;\n }\n };\n\n _proto.safeSetState = function safeSetState(nextState, callback) {\n // This shouldn't be necessary, but there are weird race conditions with\n // setState callbacks and unmounting in testing, so always make sure that\n // we can cancel any pending setState callbacks after we unmount.\n callback = this.setNextCallback(callback);\n this.setState(nextState, callback);\n };\n\n _proto.setNextCallback = function setNextCallback(callback) {\n var _this4 = this;\n\n var active = true;\n\n this.nextCallback = function (event) {\n if (active) {\n active = false;\n _this4.nextCallback = null;\n callback(event);\n }\n };\n\n this.nextCallback.cancel = function () {\n active = false;\n };\n\n return this.nextCallback;\n };\n\n _proto.onTransitionEnd = function onTransitionEnd(timeout, handler) {\n this.setNextCallback(handler);\n var node = this.props.nodeRef ? this.props.nodeRef.current : ReactDOM.findDOMNode(this);\n var doesNotHaveTimeoutOrListener = timeout == null && !this.props.addEndListener;\n\n if (!node || doesNotHaveTimeoutOrListener) {\n setTimeout(this.nextCallback, 0);\n return;\n }\n\n if (this.props.addEndListener) {\n var _ref3 = this.props.nodeRef ? [this.nextCallback] : [node, this.nextCallback],\n maybeNode = _ref3[0],\n maybeNextCallback = _ref3[1];\n\n this.props.addEndListener(maybeNode, maybeNextCallback);\n }\n\n if (timeout != null) {\n setTimeout(this.nextCallback, timeout);\n }\n };\n\n _proto.render = function render() {\n var status = this.state.status;\n\n if (status === UNMOUNTED) {\n return null;\n }\n\n var _this$props = this.props,\n children = _this$props.children,\n _in = _this$props.in,\n _mountOnEnter = _this$props.mountOnEnter,\n _unmountOnExit = _this$props.unmountOnExit,\n _appear = _this$props.appear,\n _enter = _this$props.enter,\n _exit = _this$props.exit,\n _timeout = _this$props.timeout,\n _addEndListener = _this$props.addEndListener,\n _onEnter = _this$props.onEnter,\n _onEntering = _this$props.onEntering,\n _onEntered = _this$props.onEntered,\n _onExit = _this$props.onExit,\n _onExiting = _this$props.onExiting,\n _onExited = _this$props.onExited,\n _nodeRef = _this$props.nodeRef,\n childProps = _objectWithoutPropertiesLoose(_this$props, [\"children\", \"in\", \"mountOnEnter\", \"unmountOnExit\", \"appear\", \"enter\", \"exit\", \"timeout\", \"addEndListener\", \"onEnter\", \"onEntering\", \"onEntered\", \"onExit\", \"onExiting\", \"onExited\", \"nodeRef\"]);\n\n return (\n /*#__PURE__*/\n // allows for nested Transitions\n React.createElement(TransitionGroupContext.Provider, {\n value: null\n }, typeof children === 'function' ? children(status, childProps) : React.cloneElement(React.Children.only(children), childProps))\n );\n };\n\n return Transition;\n}(React.Component);\n\nTransition.contextType = TransitionGroupContext;\nTransition.propTypes = process.env.NODE_ENV !== \"production\" ? {\n /**\n * A React reference to DOM element that need to transition:\n * https://stackoverflow.com/a/51127130/4671932\n *\n * - When `nodeRef` prop is used, `node` is not passed to callback functions\n * (e.g. `onEnter`) because user already has direct access to the node.\n * - When changing `key` prop of `Transition` in a `TransitionGroup` a new\n * `nodeRef` need to be provided to `Transition` with changed `key` prop\n * (see\n * [test/CSSTransition-test.js](https://github.com/reactjs/react-transition-group/blob/13435f897b3ab71f6e19d724f145596f5910581c/test/CSSTransition-test.js#L362-L437)).\n */\n nodeRef: PropTypes.shape({\n current: typeof Element === 'undefined' ? PropTypes.any : function (propValue, key, componentName, location, propFullName, secret) {\n var value = propValue[key];\n return PropTypes.instanceOf(value && 'ownerDocument' in value ? value.ownerDocument.defaultView.Element : Element)(propValue, key, componentName, location, propFullName, secret);\n }\n }),\n\n /**\n * A `function` child can be used instead of a React element. This function is\n * called with the current transition status (`'entering'`, `'entered'`,\n * `'exiting'`, `'exited'`), which can be used to apply context\n * specific props to a component.\n *\n * ```jsx\n * \n * {state => (\n * \n * )}\n * \n * ```\n */\n children: PropTypes.oneOfType([PropTypes.func.isRequired, PropTypes.element.isRequired]).isRequired,\n\n /**\n * Show the component; triggers the enter or exit states\n */\n in: PropTypes.bool,\n\n /**\n * By default the child component is mounted immediately along with\n * the parent `Transition` component. If you want to \"lazy mount\" the component on the\n * first `in={true}` you can set `mountOnEnter`. After the first enter transition the component will stay\n * mounted, even on \"exited\", unless you also specify `unmountOnExit`.\n */\n mountOnEnter: PropTypes.bool,\n\n /**\n * By default the child component stays mounted after it reaches the `'exited'` state.\n * Set `unmountOnExit` if you'd prefer to unmount the component after it finishes exiting.\n */\n unmountOnExit: PropTypes.bool,\n\n /**\n * By default the child component does not perform the enter transition when\n * it first mounts, regardless of the value of `in`. If you want this\n * behavior, set both `appear` and `in` to `true`.\n *\n * > **Note**: there are no special appear states like `appearing`/`appeared`, this prop\n * > only adds an additional enter transition. However, in the\n * > `` component that first enter transition does result in\n * > additional `.appear-*` classes, that way you can choose to style it\n * > differently.\n */\n appear: PropTypes.bool,\n\n /**\n * Enable or disable enter transitions.\n */\n enter: PropTypes.bool,\n\n /**\n * Enable or disable exit transitions.\n */\n exit: PropTypes.bool,\n\n /**\n * The duration of the transition, in milliseconds.\n * Required unless `addEndListener` is provided.\n *\n * You may specify a single timeout for all transitions:\n *\n * ```jsx\n * timeout={500}\n * ```\n *\n * or individually:\n *\n * ```jsx\n * timeout={{\n * appear: 500,\n * enter: 300,\n * exit: 500,\n * }}\n * ```\n *\n * - `appear` defaults to the value of `enter`\n * - `enter` defaults to `0`\n * - `exit` defaults to `0`\n *\n * @type {number | { enter?: number, exit?: number, appear?: number }}\n */\n timeout: function timeout(props) {\n var pt = timeoutsShape;\n if (!props.addEndListener) pt = pt.isRequired;\n\n for (var _len = arguments.length, args = new Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) {\n args[_key - 1] = arguments[_key];\n }\n\n return pt.apply(void 0, [props].concat(args));\n },\n\n /**\n * Add a custom transition end trigger. Called with the transitioning\n * DOM node and a `done` callback. Allows for more fine grained transition end\n * logic. Timeouts are still used as a fallback if provided.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * ```jsx\n * addEndListener={(node, done) => {\n * // use the css transitionend event to mark the finish of a transition\n * node.addEventListener('transitionend', done, false);\n * }}\n * ```\n */\n addEndListener: PropTypes.func,\n\n /**\n * Callback fired before the \"entering\" status is applied. An extra parameter\n * `isAppearing` is supplied to indicate if the enter stage is occurring on the initial mount\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement, isAppearing: bool) -> void\n */\n onEnter: PropTypes.func,\n\n /**\n * Callback fired after the \"entering\" status is applied. An extra parameter\n * `isAppearing` is supplied to indicate if the enter stage is occurring on the initial mount\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement, isAppearing: bool)\n */\n onEntering: PropTypes.func,\n\n /**\n * Callback fired after the \"entered\" status is applied. An extra parameter\n * `isAppearing` is supplied to indicate if the enter stage is occurring on the initial mount\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement, isAppearing: bool) -> void\n */\n onEntered: PropTypes.func,\n\n /**\n * Callback fired before the \"exiting\" status is applied.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement) -> void\n */\n onExit: PropTypes.func,\n\n /**\n * Callback fired after the \"exiting\" status is applied.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement) -> void\n */\n onExiting: PropTypes.func,\n\n /**\n * Callback fired after the \"exited\" status is applied.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed\n *\n * @type Function(node: HtmlElement) -> void\n */\n onExited: PropTypes.func\n} : {}; // Name the function so it is clearer in the documentation\n\nfunction noop() {}\n\nTransition.defaultProps = {\n in: false,\n mountOnEnter: false,\n unmountOnExit: false,\n appear: false,\n enter: true,\n exit: true,\n onEnter: noop,\n onEntering: noop,\n onEntered: noop,\n onExit: noop,\n onExiting: noop,\n onExited: noop\n};\nTransition.UNMOUNTED = UNMOUNTED;\nTransition.EXITED = EXITED;\nTransition.ENTERING = ENTERING;\nTransition.ENTERED = ENTERED;\nTransition.EXITING = EXITING;\nexport default Transition;","export const reflow = node => node.scrollTop;\nexport function getTransitionProps(props, options) {\n var _style$transitionDura, _style$transitionTimi;\n const {\n timeout,\n easing,\n style = {}\n } = props;\n return {\n duration: (_style$transitionDura = style.transitionDuration) != null ? _style$transitionDura : typeof timeout === 'number' ? timeout : timeout[options.mode] || 0,\n easing: (_style$transitionTimi = style.transitionTimingFunction) != null ? _style$transitionTimi : typeof easing === 'object' ? easing[options.mode] : easing,\n delay: style.transitionDelay\n };\n}","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"addEndListener\", \"appear\", \"children\", \"easing\", \"in\", \"onEnter\", \"onEntered\", \"onEntering\", \"onExit\", \"onExited\", \"onExiting\", \"style\", \"timeout\", \"TransitionComponent\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport { elementAcceptingRef, unstable_useTimeout as useTimeout } from '@mui/utils';\nimport { Transition } from 'react-transition-group';\nimport useTheme from '../styles/useTheme';\nimport { getTransitionProps, reflow } from '../transitions/utils';\nimport useForkRef from '../utils/useForkRef';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nfunction getScale(value) {\n return `scale(${value}, ${value ** 2})`;\n}\nconst styles = {\n entering: {\n opacity: 1,\n transform: getScale(1)\n },\n entered: {\n opacity: 1,\n transform: 'none'\n }\n};\n\n/*\n TODO v6: remove\n Conditionally apply a workaround for the CSS transition bug in Safari 15.4 / WebKit browsers.\n */\nconst isWebKit154 = typeof navigator !== 'undefined' && /^((?!chrome|android).)*(safari|mobile)/i.test(navigator.userAgent) && /(os |version\\/)15(.|_)4/i.test(navigator.userAgent);\n\n/**\n * The Grow transition is used by the [Tooltip](/material-ui/react-tooltip/) and\n * [Popover](/material-ui/react-popover/) components.\n * It uses [react-transition-group](https://github.com/reactjs/react-transition-group) internally.\n */\nconst Grow = /*#__PURE__*/React.forwardRef(function Grow(props, ref) {\n const {\n addEndListener,\n appear = true,\n children,\n easing,\n in: inProp,\n onEnter,\n onEntered,\n onEntering,\n onExit,\n onExited,\n onExiting,\n style,\n timeout = 'auto',\n // eslint-disable-next-line react/prop-types\n TransitionComponent = Transition\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const timer = useTimeout();\n const autoTimeout = React.useRef();\n const theme = useTheme();\n const nodeRef = React.useRef(null);\n const handleRef = useForkRef(nodeRef, children.ref, ref);\n const normalizedTransitionCallback = callback => maybeIsAppearing => {\n if (callback) {\n const node = nodeRef.current;\n\n // onEnterXxx and onExitXxx callbacks have a different arguments.length value.\n if (maybeIsAppearing === undefined) {\n callback(node);\n } else {\n callback(node, maybeIsAppearing);\n }\n }\n };\n const handleEntering = normalizedTransitionCallback(onEntering);\n const handleEnter = normalizedTransitionCallback((node, isAppearing) => {\n reflow(node); // So the animation always start from the start.\n\n const {\n duration: transitionDuration,\n delay,\n easing: transitionTimingFunction\n } = getTransitionProps({\n style,\n timeout,\n easing\n }, {\n mode: 'enter'\n });\n let duration;\n if (timeout === 'auto') {\n duration = theme.transitions.getAutoHeightDuration(node.clientHeight);\n autoTimeout.current = duration;\n } else {\n duration = transitionDuration;\n }\n node.style.transition = [theme.transitions.create('opacity', {\n duration,\n delay\n }), theme.transitions.create('transform', {\n duration: isWebKit154 ? duration : duration * 0.666,\n delay,\n easing: transitionTimingFunction\n })].join(',');\n if (onEnter) {\n onEnter(node, isAppearing);\n }\n });\n const handleEntered = normalizedTransitionCallback(onEntered);\n const handleExiting = normalizedTransitionCallback(onExiting);\n const handleExit = normalizedTransitionCallback(node => {\n const {\n duration: transitionDuration,\n delay,\n easing: transitionTimingFunction\n } = getTransitionProps({\n style,\n timeout,\n easing\n }, {\n mode: 'exit'\n });\n let duration;\n if (timeout === 'auto') {\n duration = theme.transitions.getAutoHeightDuration(node.clientHeight);\n autoTimeout.current = duration;\n } else {\n duration = transitionDuration;\n }\n node.style.transition = [theme.transitions.create('opacity', {\n duration,\n delay\n }), theme.transitions.create('transform', {\n duration: isWebKit154 ? duration : duration * 0.666,\n delay: isWebKit154 ? delay : delay || duration * 0.333,\n easing: transitionTimingFunction\n })].join(',');\n node.style.opacity = 0;\n node.style.transform = getScale(0.75);\n if (onExit) {\n onExit(node);\n }\n });\n const handleExited = normalizedTransitionCallback(onExited);\n const handleAddEndListener = next => {\n if (timeout === 'auto') {\n timer.start(autoTimeout.current || 0, next);\n }\n if (addEndListener) {\n // Old call signature before `react-transition-group` implemented `nodeRef`\n addEndListener(nodeRef.current, next);\n }\n };\n return /*#__PURE__*/_jsx(TransitionComponent, _extends({\n appear: appear,\n in: inProp,\n nodeRef: nodeRef,\n onEnter: handleEnter,\n onEntered: handleEntered,\n onEntering: handleEntering,\n onExit: handleExit,\n onExited: handleExited,\n onExiting: handleExiting,\n addEndListener: handleAddEndListener,\n timeout: timeout === 'auto' ? null : timeout\n }, other, {\n children: (state, childProps) => {\n return /*#__PURE__*/React.cloneElement(children, _extends({\n style: _extends({\n opacity: 0,\n transform: getScale(0.75),\n visibility: state === 'exited' && !inProp ? 'hidden' : undefined\n }, styles[state], style, children.props.style),\n ref: handleRef\n }, childProps));\n }\n }));\n});\nprocess.env.NODE_ENV !== \"production\" ? Grow.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the d.ts file and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * Add a custom transition end trigger. Called with the transitioning DOM\n * node and a done callback. Allows for more fine grained transition end\n * logic. Note: Timeouts are still used as a fallback if provided.\n */\n addEndListener: PropTypes.func,\n /**\n * Perform the enter transition when it first mounts if `in` is also `true`.\n * Set this to `false` to disable this behavior.\n * @default true\n */\n appear: PropTypes.bool,\n /**\n * A single child content element.\n */\n children: elementAcceptingRef.isRequired,\n /**\n * The transition timing function.\n * You may specify a single easing or a object containing enter and exit values.\n */\n easing: PropTypes.oneOfType([PropTypes.shape({\n enter: PropTypes.string,\n exit: PropTypes.string\n }), PropTypes.string]),\n /**\n * If `true`, the component will transition in.\n */\n in: PropTypes.bool,\n /**\n * @ignore\n */\n onEnter: PropTypes.func,\n /**\n * @ignore\n */\n onEntered: PropTypes.func,\n /**\n * @ignore\n */\n onEntering: PropTypes.func,\n /**\n * @ignore\n */\n onExit: PropTypes.func,\n /**\n * @ignore\n */\n onExited: PropTypes.func,\n /**\n * @ignore\n */\n onExiting: PropTypes.func,\n /**\n * @ignore\n */\n style: PropTypes.object,\n /**\n * The duration for the transition, in milliseconds.\n * You may specify a single timeout for all transitions, or individually with an object.\n *\n * Set to 'auto' to automatically calculate transition time based on height.\n * @default 'auto'\n */\n timeout: PropTypes.oneOfType([PropTypes.oneOf(['auto']), PropTypes.number, PropTypes.shape({\n appear: PropTypes.number,\n enter: PropTypes.number,\n exit: PropTypes.number\n })])\n} : void 0;\nGrow.muiSupportAuto = true;\nexport default Grow;","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"anchorEl\", \"component\", \"components\", \"componentsProps\", \"container\", \"disablePortal\", \"keepMounted\", \"modifiers\", \"open\", \"placement\", \"popperOptions\", \"popperRef\", \"transition\", \"slots\", \"slotProps\"];\nimport { Popper as BasePopper } from '@mui/base/Popper';\nimport { useThemeWithoutDefault as useTheme } from '@mui/system';\nimport { HTMLElementType, refType } from '@mui/utils';\nimport PropTypes from 'prop-types';\nimport * as React from 'react';\nimport { styled, useThemeProps } from '../styles';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nconst PopperRoot = styled(BasePopper, {\n name: 'MuiPopper',\n slot: 'Root',\n overridesResolver: (props, styles) => styles.root\n})({});\n\n/**\n *\n * Demos:\n *\n * - [Autocomplete](https://mui.com/material-ui/react-autocomplete/)\n * - [Menu](https://mui.com/material-ui/react-menu/)\n * - [Popper](https://mui.com/material-ui/react-popper/)\n *\n * API:\n *\n * - [Popper API](https://mui.com/material-ui/api/popper/)\n */\nconst Popper = /*#__PURE__*/React.forwardRef(function Popper(inProps, ref) {\n var _slots$root;\n const theme = useTheme();\n const props = useThemeProps({\n props: inProps,\n name: 'MuiPopper'\n });\n const {\n anchorEl,\n component,\n components,\n componentsProps,\n container,\n disablePortal,\n keepMounted,\n modifiers,\n open,\n placement,\n popperOptions,\n popperRef,\n transition,\n slots,\n slotProps\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const RootComponent = (_slots$root = slots == null ? void 0 : slots.root) != null ? _slots$root : components == null ? void 0 : components.Root;\n const otherProps = _extends({\n anchorEl,\n container,\n disablePortal,\n keepMounted,\n modifiers,\n open,\n placement,\n popperOptions,\n popperRef,\n transition\n }, other);\n return /*#__PURE__*/_jsx(PopperRoot, _extends({\n as: component,\n direction: theme == null ? void 0 : theme.direction,\n slots: {\n root: RootComponent\n },\n slotProps: slotProps != null ? slotProps : componentsProps\n }, otherProps, {\n ref: ref\n }));\n});\nprocess.env.NODE_ENV !== \"production\" ? Popper.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * An HTML element, [virtualElement](https://popper.js.org/docs/v2/virtual-elements/),\n * or a function that returns either.\n * It's used to set the position of the popper.\n * The return value will passed as the reference object of the Popper instance.\n */\n anchorEl: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.object, PropTypes.func]),\n /**\n * Popper render function or node.\n */\n children: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.node, PropTypes.func]),\n /**\n * The component used for the root node.\n * Either a string to use a HTML element or a component.\n */\n component: PropTypes.elementType,\n /**\n * The components used for each slot inside the Popper.\n * Either a string to use a HTML element or a component.\n * @default {}\n */\n components: PropTypes.shape({\n Root: PropTypes.elementType\n }),\n /**\n * The props used for each slot inside the Popper.\n * @default {}\n */\n componentsProps: PropTypes.shape({\n root: PropTypes.oneOfType([PropTypes.func, PropTypes.object])\n }),\n /**\n * An HTML element or function that returns one.\n * The `container` will have the portal children appended to it.\n *\n * You can also provide a callback, which is called in a React layout effect.\n * This lets you set the container from a ref, and also makes server-side rendering possible.\n *\n * By default, it uses the body of the top-level document object,\n * so it's simply `document.body` most of the time.\n */\n container: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.func]),\n /**\n * The `children` will be under the DOM hierarchy of the parent component.\n * @default false\n */\n disablePortal: PropTypes.bool,\n /**\n * Always keep the children in the DOM.\n * This prop can be useful in SEO situation or\n * when you want to maximize the responsiveness of the Popper.\n * @default false\n */\n keepMounted: PropTypes.bool,\n /**\n * Popper.js is based on a \"plugin-like\" architecture,\n * most of its features are fully encapsulated \"modifiers\".\n *\n * A modifier is a function that is called each time Popper.js needs to\n * compute the position of the popper.\n * For this reason, modifiers should be very performant to avoid bottlenecks.\n * To learn how to create a modifier, [read the modifiers documentation](https://popper.js.org/docs/v2/modifiers/).\n */\n modifiers: PropTypes.arrayOf(PropTypes.shape({\n data: PropTypes.object,\n effect: PropTypes.func,\n enabled: PropTypes.bool,\n fn: PropTypes.func,\n name: PropTypes.any,\n options: PropTypes.object,\n phase: PropTypes.oneOf(['afterMain', 'afterRead', 'afterWrite', 'beforeMain', 'beforeRead', 'beforeWrite', 'main', 'read', 'write']),\n requires: PropTypes.arrayOf(PropTypes.string),\n requiresIfExists: PropTypes.arrayOf(PropTypes.string)\n })),\n /**\n * If `true`, the component is shown.\n */\n open: PropTypes.bool.isRequired,\n /**\n * Popper placement.\n * @default 'bottom'\n */\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n /**\n * Options provided to the [`Popper.js`](https://popper.js.org/docs/v2/constructors/#options) instance.\n * @default {}\n */\n popperOptions: PropTypes.shape({\n modifiers: PropTypes.array,\n onFirstUpdate: PropTypes.func,\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n strategy: PropTypes.oneOf(['absolute', 'fixed'])\n }),\n /**\n * A ref that points to the used popper instance.\n */\n popperRef: refType,\n /**\n * The props used for each slot inside the Popper.\n * @default {}\n */\n slotProps: PropTypes.shape({\n root: PropTypes.oneOfType([PropTypes.func, PropTypes.object])\n }),\n /**\n * The components used for each slot inside the Popper.\n * Either a string to use a HTML element or a component.\n * @default {}\n */\n slots: PropTypes.shape({\n root: PropTypes.elementType\n }),\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Help supporting a react-transition-group/Transition component.\n * @default false\n */\n transition: PropTypes.bool\n} : void 0;\nexport default Popper;","import generateUtilityClasses from '@mui/utils/generateUtilityClasses';\nimport generateUtilityClass from '@mui/utils/generateUtilityClass';\nexport function getTooltipUtilityClass(slot) {\n return generateUtilityClass('MuiTooltip', slot);\n}\nconst tooltipClasses = generateUtilityClasses('MuiTooltip', ['popper', 'popperInteractive', 'popperArrow', 'popperClose', 'tooltip', 'tooltipArrow', 'touch', 'tooltipPlacementLeft', 'tooltipPlacementRight', 'tooltipPlacementTop', 'tooltipPlacementBottom', 'arrow']);\nexport default tooltipClasses;","'use client';\n\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nconst _excluded = [\"arrow\", \"children\", \"classes\", \"components\", \"componentsProps\", \"describeChild\", \"disableFocusListener\", \"disableHoverListener\", \"disableInteractive\", \"disableTouchListener\", \"enterDelay\", \"enterNextDelay\", \"enterTouchDelay\", \"followCursor\", \"id\", \"leaveDelay\", \"leaveTouchDelay\", \"onClose\", \"onOpen\", \"open\", \"placement\", \"PopperComponent\", \"PopperProps\", \"slotProps\", \"slots\", \"title\", \"TransitionComponent\", \"TransitionProps\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport clsx from 'clsx';\nimport { elementAcceptingRef, unstable_useTimeout as useTimeout, unstable_Timeout as Timeout } from '@mui/utils';\nimport { unstable_composeClasses as composeClasses, appendOwnerState } from '@mui/base';\nimport { alpha } from '@mui/system';\nimport styled from '../styles/styled';\nimport useTheme from '../styles/useTheme';\nimport useThemeProps from '../styles/useThemeProps';\nimport capitalize from '../utils/capitalize';\nimport Grow from '../Grow';\nimport Popper from '../Popper';\nimport useEventCallback from '../utils/useEventCallback';\nimport useForkRef from '../utils/useForkRef';\nimport useId from '../utils/useId';\nimport useIsFocusVisible from '../utils/useIsFocusVisible';\nimport useControlled from '../utils/useControlled';\nimport tooltipClasses, { getTooltipUtilityClass } from './tooltipClasses';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nimport { jsxs as _jsxs } from \"react/jsx-runtime\";\nfunction round(value) {\n return Math.round(value * 1e5) / 1e5;\n}\nconst useUtilityClasses = ownerState => {\n const {\n classes,\n disableInteractive,\n arrow,\n touch,\n placement\n } = ownerState;\n const slots = {\n popper: ['popper', !disableInteractive && 'popperInteractive', arrow && 'popperArrow'],\n tooltip: ['tooltip', arrow && 'tooltipArrow', touch && 'touch', `tooltipPlacement${capitalize(placement.split('-')[0])}`],\n arrow: ['arrow']\n };\n return composeClasses(slots, getTooltipUtilityClass, classes);\n};\nconst TooltipPopper = styled(Popper, {\n name: 'MuiTooltip',\n slot: 'Popper',\n overridesResolver: (props, styles) => {\n const {\n ownerState\n } = props;\n return [styles.popper, !ownerState.disableInteractive && styles.popperInteractive, ownerState.arrow && styles.popperArrow, !ownerState.open && styles.popperClose];\n }\n})(({\n theme,\n ownerState,\n open\n}) => _extends({\n zIndex: (theme.vars || theme).zIndex.tooltip,\n pointerEvents: 'none'\n}, !ownerState.disableInteractive && {\n pointerEvents: 'auto'\n}, !open && {\n pointerEvents: 'none'\n}, ownerState.arrow && {\n [`&[data-popper-placement*=\"bottom\"] .${tooltipClasses.arrow}`]: {\n top: 0,\n marginTop: '-0.71em',\n '&::before': {\n transformOrigin: '0 100%'\n }\n },\n [`&[data-popper-placement*=\"top\"] .${tooltipClasses.arrow}`]: {\n bottom: 0,\n marginBottom: '-0.71em',\n '&::before': {\n transformOrigin: '100% 0'\n }\n },\n [`&[data-popper-placement*=\"right\"] .${tooltipClasses.arrow}`]: _extends({}, !ownerState.isRtl ? {\n left: 0,\n marginLeft: '-0.71em'\n } : {\n right: 0,\n marginRight: '-0.71em'\n }, {\n height: '1em',\n width: '0.71em',\n '&::before': {\n transformOrigin: '100% 100%'\n }\n }),\n [`&[data-popper-placement*=\"left\"] .${tooltipClasses.arrow}`]: _extends({}, !ownerState.isRtl ? {\n right: 0,\n marginRight: '-0.71em'\n } : {\n left: 0,\n marginLeft: '-0.71em'\n }, {\n height: '1em',\n width: '0.71em',\n '&::before': {\n transformOrigin: '0 0'\n }\n })\n}));\nconst TooltipTooltip = styled('div', {\n name: 'MuiTooltip',\n slot: 'Tooltip',\n overridesResolver: (props, styles) => {\n const {\n ownerState\n } = props;\n return [styles.tooltip, ownerState.touch && styles.touch, ownerState.arrow && styles.tooltipArrow, styles[`tooltipPlacement${capitalize(ownerState.placement.split('-')[0])}`]];\n }\n})(({\n theme,\n ownerState\n}) => _extends({\n backgroundColor: theme.vars ? theme.vars.palette.Tooltip.bg : alpha(theme.palette.grey[700], 0.92),\n borderRadius: (theme.vars || theme).shape.borderRadius,\n color: (theme.vars || theme).palette.common.white,\n fontFamily: theme.typography.fontFamily,\n padding: '4px 8px',\n fontSize: theme.typography.pxToRem(11),\n maxWidth: 300,\n margin: 2,\n wordWrap: 'break-word',\n fontWeight: theme.typography.fontWeightMedium\n}, ownerState.arrow && {\n position: 'relative',\n margin: 0\n}, ownerState.touch && {\n padding: '8px 16px',\n fontSize: theme.typography.pxToRem(14),\n lineHeight: `${round(16 / 14)}em`,\n fontWeight: theme.typography.fontWeightRegular\n}, {\n [`.${tooltipClasses.popper}[data-popper-placement*=\"left\"] &`]: _extends({\n transformOrigin: 'right center'\n }, !ownerState.isRtl ? _extends({\n marginRight: '14px'\n }, ownerState.touch && {\n marginRight: '24px'\n }) : _extends({\n marginLeft: '14px'\n }, ownerState.touch && {\n marginLeft: '24px'\n })),\n [`.${tooltipClasses.popper}[data-popper-placement*=\"right\"] &`]: _extends({\n transformOrigin: 'left center'\n }, !ownerState.isRtl ? _extends({\n marginLeft: '14px'\n }, ownerState.touch && {\n marginLeft: '24px'\n }) : _extends({\n marginRight: '14px'\n }, ownerState.touch && {\n marginRight: '24px'\n })),\n [`.${tooltipClasses.popper}[data-popper-placement*=\"top\"] &`]: _extends({\n transformOrigin: 'center bottom',\n marginBottom: '14px'\n }, ownerState.touch && {\n marginBottom: '24px'\n }),\n [`.${tooltipClasses.popper}[data-popper-placement*=\"bottom\"] &`]: _extends({\n transformOrigin: 'center top',\n marginTop: '14px'\n }, ownerState.touch && {\n marginTop: '24px'\n })\n}));\nconst TooltipArrow = styled('span', {\n name: 'MuiTooltip',\n slot: 'Arrow',\n overridesResolver: (props, styles) => styles.arrow\n})(({\n theme\n}) => ({\n overflow: 'hidden',\n position: 'absolute',\n width: '1em',\n height: '0.71em' /* = width / sqrt(2) = (length of the hypotenuse) */,\n boxSizing: 'border-box',\n color: theme.vars ? theme.vars.palette.Tooltip.bg : alpha(theme.palette.grey[700], 0.9),\n '&::before': {\n content: '\"\"',\n margin: 'auto',\n display: 'block',\n width: '100%',\n height: '100%',\n backgroundColor: 'currentColor',\n transform: 'rotate(45deg)'\n }\n}));\nlet hystersisOpen = false;\nconst hystersisTimer = new Timeout();\nlet cursorPosition = {\n x: 0,\n y: 0\n};\nexport function testReset() {\n hystersisOpen = false;\n hystersisTimer.clear();\n}\nfunction composeEventHandler(handler, eventHandler) {\n return event => {\n if (eventHandler) {\n eventHandler(event);\n }\n handler(event);\n };\n}\n\n// TODO v6: Remove PopperComponent, PopperProps, TransitionComponent and TransitionProps.\nconst Tooltip = /*#__PURE__*/React.forwardRef(function Tooltip(inProps, ref) {\n var _ref, _slots$popper, _ref2, _ref3, _slots$transition, _ref4, _slots$tooltip, _ref5, _slots$arrow, _slotProps$popper, _ref6, _slotProps$popper2, _slotProps$transition, _slotProps$tooltip, _ref7, _slotProps$tooltip2, _slotProps$arrow, _ref8, _slotProps$arrow2;\n const props = useThemeProps({\n props: inProps,\n name: 'MuiTooltip'\n });\n const {\n arrow = false,\n children: childrenProp,\n components = {},\n componentsProps = {},\n describeChild = false,\n disableFocusListener = false,\n disableHoverListener = false,\n disableInteractive: disableInteractiveProp = false,\n disableTouchListener = false,\n enterDelay = 100,\n enterNextDelay = 0,\n enterTouchDelay = 700,\n followCursor = false,\n id: idProp,\n leaveDelay = 0,\n leaveTouchDelay = 1500,\n onClose,\n onOpen,\n open: openProp,\n placement = 'bottom',\n PopperComponent: PopperComponentProp,\n PopperProps = {},\n slotProps = {},\n slots = {},\n title,\n TransitionComponent: TransitionComponentProp = Grow,\n TransitionProps\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n\n // to prevent runtime errors, developers will need to provide a child as a React element anyway.\n const children = /*#__PURE__*/React.isValidElement(childrenProp) ? childrenProp : /*#__PURE__*/_jsx(\"span\", {\n children: childrenProp\n });\n const theme = useTheme();\n const isRtl = theme.direction === 'rtl';\n const [childNode, setChildNode] = React.useState();\n const [arrowRef, setArrowRef] = React.useState(null);\n const ignoreNonTouchEvents = React.useRef(false);\n const disableInteractive = disableInteractiveProp || followCursor;\n const closeTimer = useTimeout();\n const enterTimer = useTimeout();\n const leaveTimer = useTimeout();\n const touchTimer = useTimeout();\n const [openState, setOpenState] = useControlled({\n controlled: openProp,\n default: false,\n name: 'Tooltip',\n state: 'open'\n });\n let open = openState;\n if (process.env.NODE_ENV !== 'production') {\n // eslint-disable-next-line react-hooks/rules-of-hooks\n const {\n current: isControlled\n } = React.useRef(openProp !== undefined);\n\n // eslint-disable-next-line react-hooks/rules-of-hooks\n React.useEffect(() => {\n if (childNode && childNode.disabled && !isControlled && title !== '' && childNode.tagName.toLowerCase() === 'button') {\n console.error(['MUI: You are providing a disabled `button` child to the Tooltip component.', 'A disabled element does not fire events.', \"Tooltip needs to listen to the child element's events to display the title.\", '', 'Add a simple wrapper element, such as a `span`.'].join('\\n'));\n }\n }, [title, childNode, isControlled]);\n }\n const id = useId(idProp);\n const prevUserSelect = React.useRef();\n const stopTouchInteraction = useEventCallback(() => {\n if (prevUserSelect.current !== undefined) {\n document.body.style.WebkitUserSelect = prevUserSelect.current;\n prevUserSelect.current = undefined;\n }\n touchTimer.clear();\n });\n React.useEffect(() => stopTouchInteraction, [stopTouchInteraction]);\n const handleOpen = event => {\n hystersisTimer.clear();\n hystersisOpen = true;\n\n // The mouseover event will trigger for every nested element in the tooltip.\n // We can skip rerendering when the tooltip is already open.\n // We are using the mouseover event instead of the mouseenter event to fix a hide/show issue.\n setOpenState(true);\n if (onOpen && !open) {\n onOpen(event);\n }\n };\n const handleClose = useEventCallback(\n /**\n * @param {React.SyntheticEvent | Event} event\n */\n event => {\n hystersisTimer.start(800 + leaveDelay, () => {\n hystersisOpen = false;\n });\n setOpenState(false);\n if (onClose && open) {\n onClose(event);\n }\n closeTimer.start(theme.transitions.duration.shortest, () => {\n ignoreNonTouchEvents.current = false;\n });\n });\n const handleEnter = event => {\n if (ignoreNonTouchEvents.current && event.type !== 'touchstart') {\n return;\n }\n\n // Remove the title ahead of time.\n // We don't want to wait for the next render commit.\n // We would risk displaying two tooltips at the same time (native + this one).\n if (childNode) {\n childNode.removeAttribute('title');\n }\n enterTimer.clear();\n leaveTimer.clear();\n if (enterDelay || hystersisOpen && enterNextDelay) {\n enterTimer.start(hystersisOpen ? enterNextDelay : enterDelay, () => {\n handleOpen(event);\n });\n } else {\n handleOpen(event);\n }\n };\n const handleLeave = event => {\n enterTimer.clear();\n leaveTimer.start(leaveDelay, () => {\n handleClose(event);\n });\n };\n const {\n isFocusVisibleRef,\n onBlur: handleBlurVisible,\n onFocus: handleFocusVisible,\n ref: focusVisibleRef\n } = useIsFocusVisible();\n // We don't necessarily care about the focusVisible state (which is safe to access via ref anyway).\n // We just need to re-render the Tooltip if the focus-visible state changes.\n const [, setChildIsFocusVisible] = React.useState(false);\n const handleBlur = event => {\n handleBlurVisible(event);\n if (isFocusVisibleRef.current === false) {\n setChildIsFocusVisible(false);\n handleLeave(event);\n }\n };\n const handleFocus = event => {\n // Workaround for https://github.com/facebook/react/issues/7769\n // The autoFocus of React might trigger the event before the componentDidMount.\n // We need to account for this eventuality.\n if (!childNode) {\n setChildNode(event.currentTarget);\n }\n handleFocusVisible(event);\n if (isFocusVisibleRef.current === true) {\n setChildIsFocusVisible(true);\n handleEnter(event);\n }\n };\n const detectTouchStart = event => {\n ignoreNonTouchEvents.current = true;\n const childrenProps = children.props;\n if (childrenProps.onTouchStart) {\n childrenProps.onTouchStart(event);\n }\n };\n const handleMouseOver = handleEnter;\n const handleMouseLeave = handleLeave;\n const handleTouchStart = event => {\n detectTouchStart(event);\n leaveTimer.clear();\n closeTimer.clear();\n stopTouchInteraction();\n prevUserSelect.current = document.body.style.WebkitUserSelect;\n // Prevent iOS text selection on long-tap.\n document.body.style.WebkitUserSelect = 'none';\n touchTimer.start(enterTouchDelay, () => {\n document.body.style.WebkitUserSelect = prevUserSelect.current;\n handleEnter(event);\n });\n };\n const handleTouchEnd = event => {\n if (children.props.onTouchEnd) {\n children.props.onTouchEnd(event);\n }\n stopTouchInteraction();\n leaveTimer.start(leaveTouchDelay, () => {\n handleClose(event);\n });\n };\n React.useEffect(() => {\n if (!open) {\n return undefined;\n }\n\n /**\n * @param {KeyboardEvent} nativeEvent\n */\n function handleKeyDown(nativeEvent) {\n // IE11, Edge (prior to using Bink?) use 'Esc'\n if (nativeEvent.key === 'Escape' || nativeEvent.key === 'Esc') {\n handleClose(nativeEvent);\n }\n }\n document.addEventListener('keydown', handleKeyDown);\n return () => {\n document.removeEventListener('keydown', handleKeyDown);\n };\n }, [handleClose, open]);\n const handleRef = useForkRef(children.ref, focusVisibleRef, setChildNode, ref);\n\n // There is no point in displaying an empty tooltip.\n // So we exclude all falsy values, except 0, which is valid.\n if (!title && title !== 0) {\n open = false;\n }\n const popperRef = React.useRef();\n const handleMouseMove = event => {\n const childrenProps = children.props;\n if (childrenProps.onMouseMove) {\n childrenProps.onMouseMove(event);\n }\n cursorPosition = {\n x: event.clientX,\n y: event.clientY\n };\n if (popperRef.current) {\n popperRef.current.update();\n }\n };\n const nameOrDescProps = {};\n const titleIsString = typeof title === 'string';\n if (describeChild) {\n nameOrDescProps.title = !open && titleIsString && !disableHoverListener ? title : null;\n nameOrDescProps['aria-describedby'] = open ? id : null;\n } else {\n nameOrDescProps['aria-label'] = titleIsString ? title : null;\n nameOrDescProps['aria-labelledby'] = open && !titleIsString ? id : null;\n }\n const childrenProps = _extends({}, nameOrDescProps, other, children.props, {\n className: clsx(other.className, children.props.className),\n onTouchStart: detectTouchStart,\n ref: handleRef\n }, followCursor ? {\n onMouseMove: handleMouseMove\n } : {});\n if (process.env.NODE_ENV !== 'production') {\n childrenProps['data-mui-internal-clone-element'] = true;\n\n // eslint-disable-next-line react-hooks/rules-of-hooks\n React.useEffect(() => {\n if (childNode && !childNode.getAttribute('data-mui-internal-clone-element')) {\n console.error(['MUI: The `children` component of the Tooltip is not forwarding its props correctly.', 'Please make sure that props are spread on the same element that the ref is applied to.'].join('\\n'));\n }\n }, [childNode]);\n }\n const interactiveWrapperListeners = {};\n if (!disableTouchListener) {\n childrenProps.onTouchStart = handleTouchStart;\n childrenProps.onTouchEnd = handleTouchEnd;\n }\n if (!disableHoverListener) {\n childrenProps.onMouseOver = composeEventHandler(handleMouseOver, childrenProps.onMouseOver);\n childrenProps.onMouseLeave = composeEventHandler(handleMouseLeave, childrenProps.onMouseLeave);\n if (!disableInteractive) {\n interactiveWrapperListeners.onMouseOver = handleMouseOver;\n interactiveWrapperListeners.onMouseLeave = handleMouseLeave;\n }\n }\n if (!disableFocusListener) {\n childrenProps.onFocus = composeEventHandler(handleFocus, childrenProps.onFocus);\n childrenProps.onBlur = composeEventHandler(handleBlur, childrenProps.onBlur);\n if (!disableInteractive) {\n interactiveWrapperListeners.onFocus = handleFocus;\n interactiveWrapperListeners.onBlur = handleBlur;\n }\n }\n if (process.env.NODE_ENV !== 'production') {\n if (children.props.title) {\n console.error(['MUI: You have provided a `title` prop to the child of .', `Remove this title prop \\`${children.props.title}\\` or the Tooltip component.`].join('\\n'));\n }\n }\n const popperOptions = React.useMemo(() => {\n var _PopperProps$popperOp;\n let tooltipModifiers = [{\n name: 'arrow',\n enabled: Boolean(arrowRef),\n options: {\n element: arrowRef,\n padding: 4\n }\n }];\n if ((_PopperProps$popperOp = PopperProps.popperOptions) != null && _PopperProps$popperOp.modifiers) {\n tooltipModifiers = tooltipModifiers.concat(PopperProps.popperOptions.modifiers);\n }\n return _extends({}, PopperProps.popperOptions, {\n modifiers: tooltipModifiers\n });\n }, [arrowRef, PopperProps]);\n const ownerState = _extends({}, props, {\n isRtl,\n arrow,\n disableInteractive,\n placement,\n PopperComponentProp,\n touch: ignoreNonTouchEvents.current\n });\n const classes = useUtilityClasses(ownerState);\n const PopperComponent = (_ref = (_slots$popper = slots.popper) != null ? _slots$popper : components.Popper) != null ? _ref : TooltipPopper;\n const TransitionComponent = (_ref2 = (_ref3 = (_slots$transition = slots.transition) != null ? _slots$transition : components.Transition) != null ? _ref3 : TransitionComponentProp) != null ? _ref2 : Grow;\n const TooltipComponent = (_ref4 = (_slots$tooltip = slots.tooltip) != null ? _slots$tooltip : components.Tooltip) != null ? _ref4 : TooltipTooltip;\n const ArrowComponent = (_ref5 = (_slots$arrow = slots.arrow) != null ? _slots$arrow : components.Arrow) != null ? _ref5 : TooltipArrow;\n const popperProps = appendOwnerState(PopperComponent, _extends({}, PopperProps, (_slotProps$popper = slotProps.popper) != null ? _slotProps$popper : componentsProps.popper, {\n className: clsx(classes.popper, PopperProps == null ? void 0 : PopperProps.className, (_ref6 = (_slotProps$popper2 = slotProps.popper) != null ? _slotProps$popper2 : componentsProps.popper) == null ? void 0 : _ref6.className)\n }), ownerState);\n const transitionProps = appendOwnerState(TransitionComponent, _extends({}, TransitionProps, (_slotProps$transition = slotProps.transition) != null ? _slotProps$transition : componentsProps.transition), ownerState);\n const tooltipProps = appendOwnerState(TooltipComponent, _extends({}, (_slotProps$tooltip = slotProps.tooltip) != null ? _slotProps$tooltip : componentsProps.tooltip, {\n className: clsx(classes.tooltip, (_ref7 = (_slotProps$tooltip2 = slotProps.tooltip) != null ? _slotProps$tooltip2 : componentsProps.tooltip) == null ? void 0 : _ref7.className)\n }), ownerState);\n const tooltipArrowProps = appendOwnerState(ArrowComponent, _extends({}, (_slotProps$arrow = slotProps.arrow) != null ? _slotProps$arrow : componentsProps.arrow, {\n className: clsx(classes.arrow, (_ref8 = (_slotProps$arrow2 = slotProps.arrow) != null ? _slotProps$arrow2 : componentsProps.arrow) == null ? void 0 : _ref8.className)\n }), ownerState);\n return /*#__PURE__*/_jsxs(React.Fragment, {\n children: [/*#__PURE__*/React.cloneElement(children, childrenProps), /*#__PURE__*/_jsx(PopperComponent, _extends({\n as: PopperComponentProp != null ? PopperComponentProp : Popper,\n placement: placement,\n anchorEl: followCursor ? {\n getBoundingClientRect: () => ({\n top: cursorPosition.y,\n left: cursorPosition.x,\n right: cursorPosition.x,\n bottom: cursorPosition.y,\n width: 0,\n height: 0\n })\n } : childNode,\n popperRef: popperRef,\n open: childNode ? open : false,\n id: id,\n transition: true\n }, interactiveWrapperListeners, popperProps, {\n popperOptions: popperOptions,\n children: ({\n TransitionProps: TransitionPropsInner\n }) => /*#__PURE__*/_jsx(TransitionComponent, _extends({\n timeout: theme.transitions.duration.shorter\n }, TransitionPropsInner, transitionProps, {\n children: /*#__PURE__*/_jsxs(TooltipComponent, _extends({}, tooltipProps, {\n children: [title, arrow ? /*#__PURE__*/_jsx(ArrowComponent, _extends({}, tooltipArrowProps, {\n ref: setArrowRef\n })) : null]\n }))\n }))\n }))]\n });\n});\nprocess.env.NODE_ENV !== \"production\" ? Tooltip.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the d.ts file and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * If `true`, adds an arrow to the tooltip.\n * @default false\n */\n arrow: PropTypes.bool,\n /**\n * Tooltip reference element.\n */\n children: elementAcceptingRef.isRequired,\n /**\n * Override or extend the styles applied to the component.\n */\n classes: PropTypes.object,\n /**\n * @ignore\n */\n className: PropTypes.string,\n /**\n * The components used for each slot inside.\n *\n * This prop is an alias for the `slots` prop.\n * It's recommended to use the `slots` prop instead.\n *\n * @default {}\n */\n components: PropTypes.shape({\n Arrow: PropTypes.elementType,\n Popper: PropTypes.elementType,\n Tooltip: PropTypes.elementType,\n Transition: PropTypes.elementType\n }),\n /**\n * The extra props for the slot components.\n * You can override the existing props or add new ones.\n *\n * This prop is an alias for the `slotProps` prop.\n * It's recommended to use the `slotProps` prop instead, as `componentsProps` will be deprecated in the future.\n *\n * @default {}\n */\n componentsProps: PropTypes.shape({\n arrow: PropTypes.object,\n popper: PropTypes.object,\n tooltip: PropTypes.object,\n transition: PropTypes.object\n }),\n /**\n * Set to `true` if the `title` acts as an accessible description.\n * By default the `title` acts as an accessible label for the child.\n * @default false\n */\n describeChild: PropTypes.bool,\n /**\n * Do not respond to focus-visible events.\n * @default false\n */\n disableFocusListener: PropTypes.bool,\n /**\n * Do not respond to hover events.\n * @default false\n */\n disableHoverListener: PropTypes.bool,\n /**\n * Makes a tooltip not interactive, i.e. it will close when the user\n * hovers over the tooltip before the `leaveDelay` is expired.\n * @default false\n */\n disableInteractive: PropTypes.bool,\n /**\n * Do not respond to long press touch events.\n * @default false\n */\n disableTouchListener: PropTypes.bool,\n /**\n * The number of milliseconds to wait before showing the tooltip.\n * This prop won't impact the enter touch delay (`enterTouchDelay`).\n * @default 100\n */\n enterDelay: PropTypes.number,\n /**\n * The number of milliseconds to wait before showing the tooltip when one was already recently opened.\n * @default 0\n */\n enterNextDelay: PropTypes.number,\n /**\n * The number of milliseconds a user must touch the element before showing the tooltip.\n * @default 700\n */\n enterTouchDelay: PropTypes.number,\n /**\n * If `true`, the tooltip follow the cursor over the wrapped element.\n * @default false\n */\n followCursor: PropTypes.bool,\n /**\n * This prop is used to help implement the accessibility logic.\n * If you don't provide this prop. It falls back to a randomly generated id.\n */\n id: PropTypes.string,\n /**\n * The number of milliseconds to wait before hiding the tooltip.\n * This prop won't impact the leave touch delay (`leaveTouchDelay`).\n * @default 0\n */\n leaveDelay: PropTypes.number,\n /**\n * The number of milliseconds after the user stops touching an element before hiding the tooltip.\n * @default 1500\n */\n leaveTouchDelay: PropTypes.number,\n /**\n * Callback fired when the component requests to be closed.\n *\n * @param {React.SyntheticEvent} event The event source of the callback.\n */\n onClose: PropTypes.func,\n /**\n * Callback fired when the component requests to be open.\n *\n * @param {React.SyntheticEvent} event The event source of the callback.\n */\n onOpen: PropTypes.func,\n /**\n * If `true`, the component is shown.\n */\n open: PropTypes.bool,\n /**\n * Tooltip placement.\n * @default 'bottom'\n */\n placement: PropTypes.oneOf(['bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n /**\n * The component used for the popper.\n * @default Popper\n */\n PopperComponent: PropTypes.elementType,\n /**\n * Props applied to the [`Popper`](/material-ui/api/popper/) element.\n * @default {}\n */\n PopperProps: PropTypes.object,\n /**\n * The extra props for the slot components.\n * You can override the existing props or add new ones.\n *\n * This prop is an alias for the `componentsProps` prop, which will be deprecated in the future.\n *\n * @default {}\n */\n slotProps: PropTypes.shape({\n arrow: PropTypes.object,\n popper: PropTypes.object,\n tooltip: PropTypes.object,\n transition: PropTypes.object\n }),\n /**\n * The components used for each slot inside.\n *\n * This prop is an alias for the `components` prop, which will be deprecated in the future.\n *\n * @default {}\n */\n slots: PropTypes.shape({\n arrow: PropTypes.elementType,\n popper: PropTypes.elementType,\n tooltip: PropTypes.elementType,\n transition: PropTypes.elementType\n }),\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Tooltip title. Zero-length titles string, undefined, null and false are never displayed.\n */\n title: PropTypes.node,\n /**\n * The component used for the transition.\n * [Follow this guide](/material-ui/transitions/#transitioncomponent-prop) to learn more about the requirements for this component.\n * @default Grow\n */\n TransitionComponent: PropTypes.elementType,\n /**\n * Props applied to the transition element.\n * By default, the element is based on this [`Transition`](http://reactcommunity.org/react-transition-group/transition/) component.\n */\n TransitionProps: PropTypes.object\n} : void 0;\nexport default Tooltip;","import '@/components/mui/menu-item.component.css';\nimport ArrowRightIcon from '@mui/icons-material/ArrowRight';\nimport {\n ListItemIcon as MuiListItemIcon,\n ListItemText as MuiListItemText,\n MenuItem as MuiMenuItem,\n} from '@mui/material';\nimport Tooltip from '@mui/material/Tooltip';\nimport { Localized, ReferencedItem, SingleColumnMenu } from 'platform-bible-utils';\nimport { MouseEvent, PropsWithChildren } from 'react';\n\ntype MenuItemInfoBase = {\n /** Text (displayable in the UI) as the name of the menu item */\n label: string;\n /** Text to display when the mouse hovers over the menu item */\n tooltip?: string;\n};\n\nexport type Command = MenuItemInfoBase & {\n /** Command to execute (string.string) */\n command: string;\n};\n\ntype SubMenu = MenuItemInfoBase & {\n /** Command to execute (string.string) */\n items: MenuItemInfo[];\n};\n\nexport interface CommandHandler {\n (command: Command): void;\n}\n\nexport type MenuPropsBase = {\n /*\n * The JSON defining the menu whose items are to be rendered. This will typically be one of the\n * menus in the \"defs\" in a Platform.Bible menu (see PlatformMenus). The schema for this is\n * menuDocumentSchema (at the end of menus.model.ts). Note that while this is a\n * \"SingleColumnMenu\", somewhat bizarrely, a MultiColumnMenu is a SingleColumnMenu, so it really\n * could be a MultiColumnMenu, in which case, column had better be defined so it can be used\n * to filter out the actual groups and items to display on the column.\n */\n menuDefinition: Localized;\n\n commandHandler: CommandHandler;\n\n /**\n * Additional action to perform when any menu item is clicked. Allows the caller to handle event\n * (e.g., to close the menu).\n */\n onClick?: (event: MouseEvent) => void;\n};\n\nexport type MenuItemListProps = MenuPropsBase & {\n /** Optional unique (column) identifier */\n columnId?: ReferencedItem;\n};\n\nexport type MenuItemProps = Omit &\n PropsWithChildren<{\n /** Optional unique identifier */\n id?: string;\n\n onClick: (event: MouseEvent) => void;\n }>;\n\ntype MenuItemInfo = (Command | SubMenu) & {\n /**\n * If specified, menu item will be inset if it does not have a leading icon.\n *\n * @default true\n */\n allowForLeadingIcons?: boolean;\n /**\n * If specified, the path to the icon image to display on the leading side of the menu text.\n *\n * @default undefined (no leading icon will be shown)\n */\n iconPathBefore?: string;\n /**\n * If specified, the path to the icon image to display on the trailing side of the menu text.\n *\n * @default undefined (no trailing icon will be shown)\n */\n iconPathAfter?: string;\n /**\n * If true, list item is focused during the first mount\n *\n * @default false\n */\n hasAutoFocus?: boolean;\n\n /** Additional css classes to help with unique styling of the menu item */\n className?: string;\n\n /**\n * If true, the menu item will appear disabled and it will not respond to clicks or mouse hovers.\n *\n * @default false\n */\n isDisabled?: boolean;\n\n /**\n * If true, compact vertical padding designed for keyboard and mouse input is used.\n *\n * @default true\n */\n isDense?: boolean;\n\n /**\n * If true, a right-arrow icon will be displayed (iconPathAfter, if specified, will be ignored).\n *\n * @default false\n */\n isSubMenuParent?: boolean;\n\n /**\n * If true, the left and right padding is removed\n *\n * @default false\n */\n hasDisabledGutters?: boolean;\n\n /**\n * If true, a 1px light border is added to bottom of menu item\n *\n * @default false\n */\n hasDivider?: boolean;\n\n /** Help identify which element has keyboard focus */\n focusVisibleClassName?: string;\n\n /** If it's a submenu, it should have the items property */\n items?: MenuItemInfo[];\n};\n\nfunction getIcon(icon: string | undefined, menuLabel: string, leading: boolean) {\n return icon ? (\n \n {`${leading\n \n ) : undefined;\n}\n\nexport default function MenuItem(props: MenuItemProps) {\n const {\n onClick,\n label,\n tooltip,\n allowForLeadingIcons = true,\n iconPathBefore = undefined,\n iconPathAfter = undefined,\n hasAutoFocus = false,\n className,\n isDisabled = false,\n isDense = true,\n isSubMenuParent = false,\n hasDisabledGutters = false,\n hasDivider = false,\n focusVisibleClassName,\n id,\n children,\n } = props;\n\n const menuItem = (\n \n {label ? (\n <>\n {getIcon(iconPathBefore, label, true)}\n \n {isSubMenuParent ? (\n \n \n \n ) : (\n getIcon(iconPathAfter, label, false)\n )}\n \n ) : (\n children\n )}\n \n );\n\n return tooltip ? (\n \n
    {menuItem}
    \n
    \n ) : (\n menuItem\n );\n}\n","import MenuItem, {\n MenuItemListProps,\n MenuItemProps,\n MenuPropsBase,\n} from '@/components/mui/menu-item.component';\nimport { Menu } from '@mui/material';\nimport {\n Localized,\n MenuGroupDetailsInSubMenu,\n MenuItemContainingCommand,\n MenuItemContainingSubmenu,\n OrderedExtensibleContainer,\n ReferencedItem,\n SingleColumnMenu,\n} from 'platform-bible-utils';\nimport { MouseEvent, useMemo, useState } from 'react';\n\n/**\n * All the exported types in this file should be regarded as \"internal\" (i.e., they should not be\n * exposed via index.ts).\n */\n\nexport type GroupedMenuPropsBase = MenuPropsBase & {\n /** Optional unique (column) identifier */\n columnId?: ReferencedItem;\n};\n\nexport type GroupedMenuItemListProps = MenuItemListProps & {\n /**\n * If the menuDefinition includes \"top-level\" groups (i.e., those that belong to a column as\n * opposed to those that belong to a submenu) that should not be included in the list, then this\n * array specifies which groups to include. Likewise, for a submenu, this list indicates which\n * groups are pertinent for that submenu. So then for a context menu this property need not be\n * specified since it is a top-level menu based on a \"true\" SingleColumnMenu (i.e., one that is\n * not a MultiColumnMenu).\n */\n includedGroups?: {\n id: string;\n group: Localized;\n }[];\n};\n\ninterface ItemInfo {\n item: Localized;\n isLastItemInGroup: boolean;\n}\n\ntype SubMenuProps = MenuPropsBase & {\n parentMenuItem: Localized;\n parentItemProps: Omit, 'iconPathAfter'>;\n};\n\nfunction getAllGroups(menuDefinition: Localized) {\n const groupEntries = Object.entries(menuDefinition.groups);\n // Convert array of entries to array of objects with id and group properties\n return groupEntries.map(([key, value]) => ({ id: key, group: value }));\n}\n\nfunction SubMenu(props: SubMenuProps) {\n const [anchorEl, setAnchorEl] = useState(undefined);\n\n const { parentMenuItem, parentItemProps, menuDefinition } = props;\n\n const handleParentMenuItemClick = (event: MouseEvent) => {\n setAnchorEl(event.currentTarget);\n };\n\n const handleClose = () => {\n setAnchorEl(undefined);\n };\n\n const renderSubMenuItems = () => {\n let includedGroups = getAllGroups(menuDefinition).filter((g) => 'menuItem' in g.group);\n\n // Ensure valid parent menu was provided. (If not, submenu will contain all groups!)\n if (!parentMenuItem?.id) throw new Error('A valid parent menu item is required for submenus.');\n\n // When laying out a submenu, only include groups associated with the provided parent menu.\n // Note: without the (annoying) redundant check that the included groups\n // have the menuItem field, TS doesn't think it exists.\n includedGroups = includedGroups.filter(\n (group) => 'menuItem' in group.group && group.group.menuItem === parentMenuItem.id,\n );\n\n return ;\n };\n\n return (\n <>\n \n \n {renderSubMenuItems()}\n \n \n );\n}\n\nconst getOrderedGroupItems = (\n groupId: string,\n allItems: Localized[],\n) => {\n // Filter items that belong to the specified group\n const itemsForGroup = allItems.filter((item) => item.group === groupId);\n // Sort items based on order\n const sortedItems = itemsForGroup.sort((a, b) => (a.order || 0) - (b.order || 0));\n return sortedItems;\n};\n\n/**\n * This component is internal; it does not need to be exposed to the outside world since it is not\n * useful on its own. It is used to generate and lay out the MenuItems that appear either on a\n * top-level menu (in a GridMenu or ContextMenu) or in a submenu.\n */\nexport default function GroupedMenuItemList(menuProps: GroupedMenuItemListProps) {\n const { menuDefinition, onClick, commandHandler, includedGroups } = menuProps;\n\n const { items, allowForLeadingIcons } = useMemo(() => {\n const groupsToInclude =\n includedGroups && includedGroups.length > 0\n ? includedGroups\n : // We're apparently laying out a single-column menu (presumably a context menu). In this\n // case, all groups should be included except ones that belong to a submenu.\n getAllGroups(menuDefinition).filter((g) => !('menuItem' in g.group));\n\n const sortedGroups = Object.values(groupsToInclude).sort(\n (a, b) => (a.group.order || 0) - (b.group.order || 0),\n );\n\n const itemArray: ItemInfo[] = [];\n\n sortedGroups.forEach((group) => {\n getOrderedGroupItems(group.id, menuDefinition.items).forEach((item) =>\n itemArray.push({ item, isLastItemInGroup: false }),\n );\n if (itemArray.length > 0) itemArray[itemArray.length - 1].isLastItemInGroup = true;\n });\n\n // No divider after last item in final group.\n if (itemArray.length > 0) itemArray[itemArray.length - 1].isLastItemInGroup = false;\n\n const allowSpaceForLeadingIcons = itemArray.some(\n (i) => 'iconPathBefore' in i.item && i.item.iconPathBefore,\n );\n\n return { items: itemArray, allowForLeadingIcons: allowSpaceForLeadingIcons };\n }, [includedGroups, menuDefinition]);\n\n // Create props for MenuItem component including setting hasDivider for the last item in a group\n const createMenuItemProps = ({ item, isLastItemInGroup }: ItemInfo) => {\n const menuItemProps = {\n className: 'papi-menu-item',\n label: item.label,\n tooltip: item.tooltip,\n iconPathBefore: 'iconPathBefore' in item ? item.iconPathBefore : undefined,\n iconPathAfter: 'iconPathAfter' in item ? item.iconPathAfter : undefined,\n hasDivider: isLastItemInGroup, // Set hasDivider to true for the last item in a group\n allowForLeadingIcons,\n };\n\n return menuItemProps;\n };\n\n const [firstItem] = items;\n\n if (!firstItem) return
    ;\n\n const divKey = firstItem.item.group;\n\n return (\n
    \n {items.map((itemInfo, index) => {\n const { item } = itemInfo;\n const menuItemProps = createMenuItemProps(itemInfo);\n if ('command' in item) {\n const key = item.group + index;\n return (\n ) => {\n onClick?.(event);\n commandHandler(item);\n }}\n {...menuItemProps}\n />\n );\n }\n return (\n \n );\n })}\n
    \n );\n}\n","import GroupedMenuItemList from '@/components/mui/grouped-menu-item-list.component';\nimport { MenuItemListProps } from '@/components/mui/menu-item.component';\nimport { MultiColumnMenu } from 'platform-bible-utils';\n\n/**\n * This component is internal; it does not need to be exposed to the outside world since it is not\n * useful on its own. Use either GridMenu or ContextMenu.\n */\nexport default function TopLevelMenu(props: MenuItemListProps) {\n const { menuDefinition, columnId } = props;\n\n const groupEntries = Object.entries(menuDefinition.groups);\n // Convert array of entries to array of objects with id and group properties\n const groups = groupEntries.map(([key, value]) => ({ id: key, group: value }));\n let includedGroups = groups.filter((g) => 'column' in g.group);\n\n // Check if column is provided and menuDefinition is a MultiColumnMenu\n if (\n columnId &&\n 'columns' in menuDefinition &&\n // Without this type assertion, TS doesn't know what columns is.\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n (menuDefinition as MultiColumnMenu).columns[columnId]\n ) {\n // When laying out a single column in a MultiColumnMenu, only include groups associated with\n // the provided column. Note: without the (annoying) redundant check that the included groups\n // have the colum field, TS doesn't think it exists.\n includedGroups = includedGroups.filter(\n (g) => 'column' in g.group && g.group.column === columnId,\n );\n }\n\n return ;\n}\n","import '@/components/mui/grid-menu.component.css';\nimport { GroupedMenuPropsBase } from '@/components/mui/grouped-menu-item-list.component';\nimport { CommandHandler } from '@/components/mui/menu-item.component';\nimport TopLevelMenu from '@/components/mui/top-level-menu.component';\nimport { Grid, List } from '@mui/material';\nimport {\n Localized,\n MenuColumnWithHeader,\n MultiColumnMenu,\n ReferencedItem,\n} from 'platform-bible-utils';\nimport { useMemo } from 'react';\n\ntype ColumnInfo = {\n /*\n * The ID (`${string}.${string}`) of a specific menu column.\n */\n id: ReferencedItem;\n\n /*\n * Metadata (label, order, etc.) for a specific menu column.\n */\n metadata: Localized;\n};\n\ntype MenuColumnProps = ColumnInfo &\n GroupedMenuPropsBase & {\n /** Additional css classes to help with unique styling of the menu column */\n className?: string;\n };\n\nexport type GridMenuInfo = {\n /** The menu object containing information about the columns, groups, and items to display. */\n multiColumnMenu: Localized;\n};\n\nexport type GridMenuProps = GridMenuInfo & {\n /** Optional unique identifier */\n id?: string;\n\n commandHandler: CommandHandler;\n\n /** Additional css classes to help with unique styling of the grid menu */\n className?: string;\n};\n\nfunction MenuColumn({\n commandHandler,\n menuDefinition,\n id,\n metadata,\n onClick,\n className,\n}: MenuColumnProps) {\n return (\n \n

    \n {metadata.label}\n

    \n {/* It would seem as though this List component were unnecessary, since it only contains one\n thing, but the \"dense\" property does affect the layout of the items (in a way I don't fully\n understand). There might be a better way. */}\n \n \n \n \n );\n}\n\nexport default function GridMenu({\n commandHandler,\n className,\n multiColumnMenu,\n id,\n}: GridMenuProps) {\n const { columns } = multiColumnMenu;\n\n const sortedColumns = useMemo(() => {\n const columnNumbers = new Map();\n Object.getOwnPropertyNames(columns).forEach((columnName: string) => {\n // We know for sure there is a (boolean) property 'isExtensible' that we are not interested in.\n if (columnName === 'isExtensible') return;\n // TS doesn't allow `columnName` above to be a ReferencedItem even though the type says it is\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const columnId = columnName as ReferencedItem;\n const column = columns[columnId];\n // As of right now (and hopefully forever after), all remaining properties of the\n // ColumnsWithHeaders object are columns whose property names are the IDs of the columns.\n // This is an additional (redundant) sanity check. Specifically we're interested in\n // MenuColumnWithHeader objects, which TypeScript now \"knows\" we have, but at runtime all we\n // can check for is that it's an object with a valid numeric order field. That's likely good\n // enough.\n if (\n typeof column === 'object' &&\n typeof column.order === 'number' &&\n !Number.isNaN(column.order)\n )\n columnNumbers.set(column.order, { id: columnId, metadata: column });\n else\n console.warn(\n `Property ${columnName} (${typeof column}) on menu ${id} is not a valid column and is being ignored. This might indicate data corruption`,\n );\n });\n\n // Extract values and sort them based on the 'order' property\n return Array.from(columnNumbers.values()).sort((a, b) => {\n return (a.metadata.order || 0) - (b.metadata.order || 0);\n });\n }, [columns, id]);\n\n // We might need something like this if we need to be able to prevent empty columns\n // sortedColumns.filter((c) => multiColumnMenu.groups.some((g) => 'column' in g && (g as .column)...\n\n return (\n \n {sortedColumns.map((col, index) => (\n \n ))}\n \n );\n}\n","import { useEffect, useRef, useState } from 'react';\n\nexport type UsePromiseOptions = {\n /**\n * Whether to leave the value as the most recent resolved promise value or set it back to\n * defaultValue while running the promise again. Defaults to true\n */\n preserveValue?: boolean;\n};\n\n/** Set up defaults for options for usePromise hook */\nfunction getUsePromiseOptionsDefaults(options: UsePromiseOptions): UsePromiseOptions {\n return {\n preserveValue: true,\n ...options,\n };\n}\n\n/**\n * Awaits a promise and returns a loading value while the promise is unresolved\n *\n * @param promiseFactoryCallback A function that returns the promise to await. If this callback is\n * undefined, the current value will be returned (defaultValue unless it was previously changed\n * and `options.preserveValue` is true), and there will be no loading.\n *\n * WARNING: MUST BE STABLE - const or wrapped in useCallback. The reference must not be updated\n * every render\n * @param defaultValue The initial value to return while first awaiting the promise. If\n * `options.preserveValue` is false, this value is also shown while awaiting the promise on\n * subsequent calls.\n *\n * Note: this parameter is internally assigned to a `ref`, so changing it will not cause any hooks\n * to re-run with its new value. This means that, if the `promiseFactoryCallback` changes and\n * `options.preserveValue` is `false`, the returned value will be set to the current\n * `defaultValue`. However, the returned value will not be updated if`defaultValue` changes.\n * @param options Various options for adjusting how this hook runs the `promiseFactoryCallback`\n *\n * Note: this parameter is internally assigned to a `ref`, so changing it will not cause any hooks\n * to re-run with its new value. However, the latest `options.preserveValue` will always be used\n * appropriately to determine whether to preserve the returned value when changing the\n * `promiseFactoryCallback`\n * @returns `[value, isLoading]`\n *\n * - `value`: the current value for the promise, either the defaultValue or the resolved promise value\n * - `isLoading`: whether the promise is waiting to be resolved\n */\nconst usePromise = (\n promiseFactoryCallback: (() => Promise) | undefined,\n defaultValue: T,\n options: UsePromiseOptions = {},\n): [value: T, isLoading: boolean] => {\n // Use defaultValue as a ref so it doesn't update dependency arrays\n const defaultValueRef = useRef(defaultValue);\n defaultValueRef.current = defaultValue;\n // Use options as a ref so it doesn't update dependency arrays\n const optionsDefaultedRef = useRef(options);\n optionsDefaultedRef.current = getUsePromiseOptionsDefaults(optionsDefaultedRef.current);\n\n const [value, setValue] = useState(() => defaultValueRef.current);\n const [isLoading, setIsLoading] = useState(true);\n useEffect(() => {\n let promiseIsCurrent = true;\n // If a promiseFactoryCallback was provided, we are loading. Otherwise, there is no loading to do\n setIsLoading(!!promiseFactoryCallback);\n (async () => {\n // If there is a callback to run, run it\n if (promiseFactoryCallback) {\n const result = await promiseFactoryCallback();\n // If the promise was not already replaced, update the value\n if (promiseIsCurrent) {\n setValue(() => result);\n setIsLoading(false);\n }\n }\n })();\n\n return () => {\n // Mark this promise as old and not to be used\n promiseIsCurrent = false;\n if (!optionsDefaultedRef.current.preserveValue) setValue(() => defaultValueRef.current);\n };\n }, [promiseFactoryCallback]);\n\n return [value, isLoading];\n};\nexport default usePromise;\n","\"use client\";\n\nimport createSvgIcon from './utils/createSvgIcon';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nexport default createSvgIcon( /*#__PURE__*/_jsx(\"path\", {\n d: \"M3 18h18v-2H3zm0-5h18v-2H3zm0-7v2h18V6z\"\n}), 'Menu');","import GridMenu from '@/components/mui/grid-menu.component';\nimport { Command, CommandHandler } from '@/components/mui/menu-item.component';\nimport usePromise from '@/hooks/use-promise.hook';\nimport { Menu as MenuIcon } from '@mui/icons-material';\nimport { Drawer, IconButton } from '@mui/material';\nimport { Localized, MultiColumnMenu } from 'platform-bible-utils';\nimport {\n MouseEvent,\n MutableRefObject,\n PropsWithChildren,\n useCallback,\n useEffect,\n useState,\n} from 'react';\n\nexport interface MultiColumnMenuProvider {\n (isSupportAndDevelopment: boolean): Promise>;\n}\n\nexport type HamburgerMenuButtonProps = PropsWithChildren & {\n /** The handler to use for menu commands (and eventually toolbar commands). */\n commandHandler: CommandHandler;\n\n /**\n * Optional reference to the \"div\" container that determines the where the menu should appear. If\n * not defined, then (1,1) used.\n */\n containerRef?: MutableRefObject;\n\n /**\n * The delegate to use to get the menu data. If not specified or if it returns undefined, the data\n * in normalMenu or fullMenu property will be used.\n */\n menuProvider?: MultiColumnMenuProvider;\n\n /**\n * The menu data to show when the menu is opened if the menuProvider property is not defined.\n * (This allows for a default or test-only static menu to be used.)\n */\n normalMenu?: Localized;\n\n /**\n * The menu data to show for \"full\" menu (when opened with the SHIFT key pressed) if the\n * menuProvider property is not defined. (This allows for a default or test-only static menu to be\n * used.)\n */\n fullMenu?: Localized;\n\n /** Additional css class(es) to help with unique styling of the sub-components */\n className?: string;\n\n /** Value to use as prefix for ARIA labels on interactive sub-components */\n ariaLabelPrefix?: string;\n};\n\nexport default function HamburgerMenuButton({\n menuProvider,\n normalMenu,\n fullMenu,\n commandHandler,\n containerRef,\n className,\n ariaLabelPrefix,\n children,\n}: HamburgerMenuButtonProps) {\n const [isMenuOpen, setMenuOpen] = useState(false);\n const [showFullMenu, setShowFullMenu] = useState(false);\n\n const handleMenuItemClick = useCallback(() => {\n if (isMenuOpen) setMenuOpen(false);\n setShowFullMenu(false);\n }, [isMenuOpen]);\n\n const handleMenuButtonClick = useCallback((e: MouseEvent) => {\n e.stopPropagation();\n setMenuOpen((prevIsOpen) => {\n const isOpening = !prevIsOpen;\n if (isOpening && e.shiftKey) setShowFullMenu(true);\n else if (!isOpening) setShowFullMenu(false);\n return isOpening;\n });\n }, []);\n\n const menuCommandHandler = useCallback(\n (command: Command) => {\n handleMenuItemClick();\n return commandHandler(command);\n },\n [commandHandler, handleMenuItemClick],\n );\n\n const [offset, setOffset] = useState({ top: 1, left: 1 });\n\n useEffect(() => {\n if (isMenuOpen) {\n const node = containerRef?.current;\n if (node) {\n const rect = node.getBoundingClientRect();\n const scrollTop = window.scrollY;\n const scrollLeft = window.scrollX;\n const top = rect.top + scrollTop + node.clientHeight;\n const left = rect.left + scrollLeft;\n setOffset({ top, left });\n }\n }\n }, [isMenuOpen, containerRef]);\n\n const [normalMenuData] = usePromise(\n useCallback(async () => {\n return menuProvider?.(false) ?? normalMenu;\n // isMenuOpen needs to be included for the menu contents to reevaluate when reopened\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [menuProvider, normalMenu, isMenuOpen]),\n normalMenu,\n );\n\n const [fullMenuData] = usePromise(\n useCallback(async () => {\n return menuProvider?.(true) ?? fullMenu ?? normalMenuData;\n // isMenuOpen needs to be included for the menu contents to reevaluate when reopened\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [menuProvider, fullMenu, normalMenuData, isMenuOpen]),\n fullMenu ?? normalMenuData,\n );\n\n const menu = showFullMenu && fullMenuData ? fullMenuData : normalMenuData;\n\n return (\n <>\n \n {children ?? }\n \n \n {menu ? (\n \n ) : undefined}\n \n \n );\n}\n","import '@/components/mui/icon-button.component.css';\nimport { IconButton as MuiIconButton } from '@mui/material';\nimport { MouseEventHandler, PropsWithChildren } from 'react';\n\nexport type IconButtonProps = PropsWithChildren<{\n /** Optional unique identifier */\n id?: string;\n /**\n * Required. Used as both the tooltip (aka, title) and the aria-label (used for accessibility,\n * testing, etc.), unless a distinct tooltip is supplied.\n */\n label: string;\n /**\n * Enabled status of button\n *\n * @default false\n */\n isDisabled?: boolean;\n /** Optional tooltip to display if different from the aria-label. */\n tooltip?: string;\n /** If true, no tooltip will be displayed. */\n isTooltipSuppressed?: boolean;\n /**\n * If given, uses a negative margin to counteract the padding on one side (this is often helpful\n * for aligning the left or right side of the icon with content above or below, without ruining\n * the border size and shape).\n *\n * @default false\n */\n adjustMarginToAlignToEdge?: 'end' | 'start' | false;\n /**\n * The size of the component. small is equivalent to the dense button styling.\n *\n * @default false\n */\n size: 'small' | 'medium' | 'large';\n /** Additional css classes to help with unique styling of the button */\n className?: string;\n /** Optional click handler */\n onClick?: MouseEventHandler;\n}>;\n\n/**\n * Iconic button a user can click to do something\n *\n * Thanks to MUI for heavy inspiration and documentation\n * https://mui.com/material-ui/getting-started/overview/\n */\nfunction IconButton({\n id,\n label,\n isDisabled = false,\n tooltip,\n isTooltipSuppressed = false,\n adjustMarginToAlignToEdge = false,\n size = 'medium',\n className,\n onClick,\n children,\n}: IconButtonProps) {\n return (\n \n {children /* the icon to display */}\n \n );\n}\n\nexport default IconButton;\n","import { cn } from '@/utils/shadcn-ui.util';\nimport { LoaderCircle, LucideProps } from 'lucide-react';\nimport { forwardRef } from 'react';\n\nexport type SpinnerProps = LucideProps;\n\nconst Spinner = forwardRef(({ className, ...props }, ref) => {\n return (\n \n );\n});\n\nSpinner.displayName = 'Spinner';\n\nexport default Spinner;\n","import { Input as ShadInput } from '@/components/shadcn-ui/input';\nimport { Label as ShadLabel } from '@/components/shadcn-ui/label';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { ChangeEventHandler, FocusEventHandler } from 'react';\n\nexport type TextFieldProps = {\n /** Optional unique identifier */\n id?: string;\n /**\n * If `true`, the component is disabled.\n *\n * @default false\n */\n isDisabled?: boolean;\n /**\n * If `true`, the label is displayed in an error state.\n *\n * @default false\n */\n hasError?: boolean;\n /**\n * If `true`, the input will take up the full width of its container.\n *\n * @default false\n */\n isFullWidth?: boolean;\n /** Text that gives the user instructions on what contents the TextField expects */\n helperText?: string;\n /** The title of the TextField */\n label?: string;\n /** The short hint displayed in the `input` before the user enters a value. */\n placeholder?: string;\n /**\n * If `true`, the label is displayed as required and the `input` element is required.\n *\n * @default false\n */\n isRequired?: boolean;\n /** Additional css classes to help with unique styling of the text field */\n className?: string;\n /** Starting value for the text field if it is not controlled */\n defaultValue?: string | number;\n /** Value of the text field if controlled */\n value?: string | number;\n /** Triggers when content of textfield is changed */\n onChange?: ChangeEventHandler;\n /** Triggers when textfield gets focus */\n onFocus?: FocusEventHandler;\n /** Triggers when textfield loses focus */\n onBlur?: FocusEventHandler;\n};\n\n/**\n * Text input field\n *\n * Thanks to Shadcn for heavy inspiration and documentation\n * https://ui.shadcn.com/docs/components/input#with-label\n */\nfunction TextField({\n id,\n isDisabled = false,\n hasError = false,\n isFullWidth = false,\n helperText,\n label,\n placeholder,\n isRequired = false,\n className,\n defaultValue,\n value,\n onChange,\n onFocus,\n onBlur,\n}: TextFieldProps) {\n return (\n
    \n {`${label}${isRequired ? '*' : ''}`}\n \n

    {helperText}

    \n
    \n );\n}\n\nexport default TextField;\n","import HamburgerMenuButton, {\n MultiColumnMenuProvider,\n} from '@/components/mui/hamburger-menu-button.component';\nimport { CommandHandler } from '@/components/mui/menu-item.component';\nimport '@/components/mui/toolbar.component.css';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { AppBar, Toolbar as MuiToolbar } from '@mui/material';\nimport { PropsWithChildren, useRef } from 'react';\n\nexport type ToolbarProps = PropsWithChildren<{\n /** The handler to use for menu commands (and eventually toolbar commands). */\n commandHandler: CommandHandler;\n\n /**\n * The optional delegate to use to get the menu data. If not specified, the \"hamburger\" menu will\n * not display.\n */\n menuProvider?: MultiColumnMenuProvider;\n\n /** Optional unique identifier */\n id?: string;\n\n /** Additional css classes to help with unique styling of the toolbar */\n className?: string;\n}>;\n\nexport default function Toolbar({\n menuProvider,\n commandHandler,\n className,\n id,\n children,\n}: ToolbarProps) {\n // This ref will always be defined\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const containerRef = useRef(undefined!);\n\n return (\n
    \n \n \n {menuProvider ? (\n \n ) : undefined}\n {children ?
    {children}
    : undefined}\n \n
    \n
    \n );\n}\n","import React from 'react';\nimport { cva, type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst alertVariants = cva(\n 'tw-relative tw-w-full tw-rounded-lg tw-border tw-p-4 [&>svg~*]:tw-pl-7 [&>svg+div]:tw-translate-y-[-3px] [&>svg]:tw-absolute [&>svg]:tw-left-4 [&>svg]:tw-top-4 [&>svg]:tw-text-foreground',\n {\n variants: {\n variant: {\n default: 'tw-bg-background tw-text-foreground',\n destructive:\n 'tw-border-destructive/50 tw-text-destructive dark:tw-border-destructive [&>svg]:tw-text-destructive',\n },\n },\n defaultVariants: {\n variant: 'default',\n },\n },\n);\n\nconst Alert = React.forwardRef<\n HTMLDivElement,\n React.HTMLAttributes & VariantProps\n>(({ className, variant, ...props }, ref) => (\n
    \n));\nAlert.displayName = 'Alert';\n\nconst AlertTitle = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n {/* added because of https://github.com/jsx-eslint/eslint-plugin-jsx-a11y/blob/main/docs/rules/heading-has-content.md */}\n {props.children}{' '}\n \n ),\n);\nAlertTitle.displayName = 'AlertTitle';\n\nconst AlertDescription = React.forwardRef<\n HTMLParagraphElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n
    \n));\nAlertDescription.displayName = 'AlertDescription';\n\nexport { Alert, AlertTitle, AlertDescription };\n","import React from 'react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Card = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nCard.displayName = 'Card';\n\nconst CardHeader = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nCardHeader.displayName = 'CardHeader';\n\nconst CardTitle = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n {/* added because of https://github.com/jsx-eslint/eslint-plugin-jsx-a11y/blob/main/docs/rules/heading-has-content.md */}\n {props.children}\n \n ),\n);\nCardTitle.displayName = 'CardTitle';\n\nconst CardDescription = React.forwardRef<\n HTMLParagraphElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n

    \n));\nCardDescription.displayName = 'CardDescription';\n\nconst CardContent = React.forwardRef>(\n ({ className, ...props }, ref) => (\n

    \n ),\n);\nCardContent.displayName = 'CardContent';\n\nconst CardFooter = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nCardFooter.displayName = 'CardFooter';\n\nexport { Card, CardHeader, CardFooter, CardTitle, CardDescription, CardContent };\n","import { ComponentProps } from 'react';\nimport { toast as sonner, Toaster } from 'sonner';\n\ntype SonnerProps = ComponentProps;\n\nfunction Sonner({ ...props }: SonnerProps) {\n return (\n \n );\n}\n\n// The re-export of the sonner function was added manually\nexport { Sonner, sonner };\n","import React from 'react';\nimport * as SliderPrimitive from '@radix-ui/react-slider';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Slider = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n \n \n \n));\nSlider.displayName = SliderPrimitive.Root.displayName;\n\nexport { Slider };\n","import React from 'react';\nimport * as SwitchPrimitives from '@radix-ui/react-switch';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Switch = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n));\nSwitch.displayName = SwitchPrimitives.Root.displayName;\n\nexport { Switch };\n","import React from 'react';\nimport * as TabsPrimitive from '@radix-ui/react-tabs';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport const Tabs = TabsPrimitive.Root;\n\nexport type TabsListProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport type TabsTriggerProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport type TabsContentProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport const TabsList = React.forwardRef<\n React.ElementRef,\n TabsListProps\n>(({ className, ...props }, ref) => (\n \n));\nTabsList.displayName = TabsPrimitive.List.displayName;\n\nexport const TabsTrigger = React.forwardRef<\n React.ElementRef,\n TabsTriggerProps\n>(({ className, ...props }, ref) => (\n \n));\nTabsTrigger.displayName = TabsPrimitive.Trigger.displayName;\n\nexport const TabsContent = React.forwardRef<\n React.ElementRef,\n TabsContentProps\n>(({ className, ...props }, ref) => (\n \n));\nTabsContent.displayName = TabsPrimitive.Content.displayName;\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Download } from 'lucide-react';\n\ntype InstallButtonProps = {\n /** The installing boolean value determines the state of the button. */\n isInstalling: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n /** Optional text for the button. */\n buttonText?: string;\n} & ButtonProps;\n\n/**\n * The InstallButton component is a button designed for initiating installs. It includes visuals for\n * active installing and idle states.\n *\n * @param isInstalling The installing boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @param buttonText Optional text for the button.\n * @returns A install button.\n */\nexport default function InstallButton({\n isInstalling,\n handleClick,\n buttonText,\n className,\n ...props\n}: InstallButtonProps) {\n return (\n \n {isInstalling ? (\n \n ) : (\n <>\n \n {buttonText}\n \n )}\n \n );\n}\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\n\ntype EnableButtonProps = {\n /** The enabling boolean value determines the state of the button. */\n isEnabling: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n} & ButtonProps;\n\n/**\n * The EnableButton component is a button designed for initiating enabling of downloads. It includes\n * visuals for active enabling and idle states.\n *\n * @param isEnabling The enabling boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @returns A button that can be used to enable.\n */\nexport default function EnableButton({\n isEnabling,\n handleClick,\n className,\n ...props\n}: EnableButtonProps) {\n return (\n \n {isEnabling ? (\n <>\n \n Enabling...\n \n ) : (\n 'Enable'\n )}\n \n );\n}\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\n\ntype DisableButtonProps = {\n /** The disabling boolean value determines the state of the button. */\n isDisabling: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n} & ButtonProps;\n\n/**\n * The DisableButton component is a button designed for initiating disabling of downloads. It\n * includes visuals for active disabling and idle states.\n *\n * @param isDisabling The disabling boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @returns A button that can be used to disable.\n */\nexport default function DisableButton({\n isDisabling,\n handleClick,\n className,\n ...props\n}: DisableButtonProps) {\n return (\n \n {isDisabling ? (\n <>\n \n Disabling...\n \n ) : (\n 'Disable'\n )}\n \n );\n}\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\n\ntype UpdateButtonProps = {\n /** The updating boolean value determines the state of the button. */\n isUpdating: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n} & ButtonProps;\n\n/**\n * The UpdateButton component is a button designed for initiating updates for downloaded extensions.\n * It includes visuals for active updating and idle states.\n *\n * @param isUpdating The updating boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @returns A button that can be used to update.\n */\nexport default function UpdateButton({\n isUpdating,\n handleClick,\n className,\n ...props\n}: UpdateButtonProps) {\n return (\n \n {isUpdating ? (\n <>\n \n Updating...\n \n ) : (\n 'Update'\n )}\n \n );\n}\n","import { cn } from '@/utils/shadcn-ui.util';\nimport Markdown, { MarkdownToJSX } from 'markdown-to-jsx';\nimport { useMemo } from 'react';\n\ninterface MarkdownRendererProps {\n /** Optional unique identifier */\n id?: string;\n /** The markdown string to render */\n markdown: string;\n className?: string;\n /**\n * The [`target` attribute for `a` html\n * tags](https://developer.mozilla.org/en-US/docs/Web/HTML/Element/a#target). Defaults to not\n * adding a `target` to `a` tags\n */\n anchorTarget?: string;\n}\n\n/**\n * This component renders markdown content given a markdown string. It uses typography styles from\n * the platform.\n *\n * @param markdown The markdown string to render.\n * @param id Optional unique identifier\n * @returns A div containing the rendered markdown content.\n */\nexport default function MarkdownRenderer({\n id,\n markdown,\n className,\n anchorTarget,\n}: MarkdownRendererProps) {\n const options: MarkdownToJSX.Options = useMemo(\n () => ({\n overrides: {\n a: {\n props: {\n target: anchorTarget,\n },\n },\n },\n }),\n [anchorTarget],\n );\n return (\n
    \n {markdown}\n
    \n );\n}\n","import { Filter, ChevronDown } from 'lucide-react';\nimport { forwardRef } from 'react';\nimport { Button } from '@/components/shadcn-ui/button';\n\n/**\n * The FilterButton component is a button designed for initiating filtering of data. It is designed\n * to be used with the dropdown menu. It uses forwardRef to pass the button to the dropdown trigger\n * asChild.\n *\n * @returns A button that can be used to filter.\n */\nconst FilterButton = forwardRef((props, ref) => {\n return (\n \n \n Filter\n \n \n );\n});\n\nexport default FilterButton;\n","import {\n DropdownMenu,\n DropdownMenuTrigger,\n DropdownMenuContent,\n DropdownMenuLabel,\n DropdownMenuGroup,\n DropdownMenuCheckboxItem,\n DropdownMenuRadioItem,\n DropdownMenuSeparator,\n} from '@/components/shadcn-ui/dropdown-menu';\nimport FilterButton from './buttons/filter-button.component';\n\nexport enum DropdownMenuItemType {\n Check,\n Radio,\n}\n\nexport type DropdownItem = {\n /** The label is the text that will be displayed on the dropdown item. */\n label: string;\n /** The itemType determines the DropdownMenuItemType type as either Check or Radio. */\n itemType: DropdownMenuItemType;\n /** The onClick function is called when the item is clicked. */\n onClick: () => void;\n};\n\nexport type DropdownGroup = {\n /**\n * The label is the text that will be displayed on the dropdown group. It is used to categorize\n * the items in the group.\n */\n label: string;\n /** The items array contains the items that will be displayed in the dropdown group */\n items: DropdownItem[];\n};\n\nexport type FilterDropdownProps = {\n /** Object unique identifier */\n id?: string;\n /** The groups array contains the groups that will be displayed in the dropdown */\n groups: DropdownGroup[];\n}; // TODO: extend the props later\n\n/**\n * The FilterDropdown component is a dropdown designed for filtering content. It includes groups of\n * items that can be checkboxes or radio items.\n *\n * @param id Optional unique identifier\n * @param groups The groups array contains the groups that will be displayed in the dropdown\n * @returns A filter dropdown.\n */\nexport default function FilterDropdown({ id, groups }: FilterDropdownProps) {\n return (\n
    \n {/* TODO: remove this once the DropDown Menu shadcn has an id prop */}\n \n \n \n \n \n {groups.map((group) => (\n
    \n {group.label}\n \n {group.items.map((item) => (\n
    \n {item.itemType === DropdownMenuItemType.Check ? (\n \n {item.label}\n \n ) : (\n \n {item.label}\n \n )}\n
    \n ))}\n
    \n \n
    \n ))}\n
    \n
    \n
    \n );\n}\n","interface NoExtensionsFoundProps {\n /** Optional unique identifier */\n id?: string;\n /** The message to display */\n message: string;\n}\n/**\n * This component displays a message to the user when no extensions are found in the marketplace.\n *\n * @param id Optional unique identifier\n * @param message The message to display.\n * @returns {JSX.Element} - Returns the message component that displays the message to the user.\n */\nexport default function NoExtensionsFound({ id, message }: NoExtensionsFoundProps) {\n return (\n
    \n
    \n

    {message}

    \n
    \n
    \n );\n}\n","import { CircleHelp, Link as LucideLink, User } from 'lucide-react';\nimport { NumberFormat } from 'platform-bible-utils';\n\n/** Interface that stores the parameters passed to the More Info component */\ninterface MoreInfoProps {\n /** Optional unique identifier */\n id?: string;\n /** The category of the extension */\n category: string;\n /** The number of downloads for the extension */\n downloads: Record;\n /** The languages supported by the extension */\n languages: string[];\n /** The URL to the more info page of the extension */\n moreInfoUrl: string;\n}\n/**\n * This component displays the more info section of the extension which includes the category,\n * number of downloads, languages, and links to the website and support\n *\n * @param id Optional unique identifier\n * @param category The category of the extension\n * @param downloads The number of downloads for the extension\n * @param languages The languages supported by the extension\n * @param moreInfoUrl The URL to the more info page of the extension\n * @returns {JSX.Element} - Returns the more info component that displays the category, number of\n * downloads, languages, and links to the website and support\n */\nexport default function MoreInfo({\n id,\n category,\n downloads,\n languages,\n moreInfoUrl,\n}: MoreInfoProps) {\n /**\n * This constant formats the number of downloads into a more readable format.\n *\n * @example 1000 -> 1K\n *\n * @example 1000000 -> 1M\n *\n * @returns The formatted number of downloads\n */\n const numberFormatted = new NumberFormat('en', {\n notation: 'compact',\n compactDisplay: 'short',\n }).format(Object.values(downloads).reduce((a: number, b: number) => a + b, 0));\n\n /** This function scrolls the window to the bottom of the page. */\n const handleScrollToBottom = () => {\n window.scrollTo(0, document.body.scrollHeight);\n };\n\n return (\n \n
    \n
    \n {category}\n
    \n CATEGORY\n
    \n
    \n
    \n
    \n \n {numberFormatted}\n
    \n USERS\n
    \n
    \n
    \n
    \n {languages.slice(0, 3).map((locale) => (\n \n {locale.toUpperCase()}\n \n ))}\n
    \n {languages.length > 3 && (\n handleScrollToBottom()}\n className=\"tw-text-xs tw-text-gray-500 tw-underline\"\n >\n +{languages.length - 3} more languages\n \n )}\n
    \n
    \n
    \n \n Website\n \n \n \n Support\n \n \n
    \n
    \n );\n}\n","import { useState } from 'react';\n\nexport type VersionInformation = {\n /** Date the version was published */\n date: string;\n /** Description of the changes in the version */\n description: string;\n};\n\n/** Type to store the version history information */\nexport type VersionHistoryType = Record;\n\n/** Interface that stores the parameters passed to the Version History component */\ninterface VersionHistoryProps {\n /** Optional unique identifier */\n id?: string;\n /** Object containing the versions mapped with their information */\n versionHistory: VersionHistoryType;\n}\n\n/**\n * Component to render the version history information shown in the footer component. Lists the 5\n * most recent versions, with the options to show all versions by pressing a button.\n *\n * @param versionHistory Object containing the versions mapped with their information\n * @param id Optional unique identifier\n * @returns Rendered version history for the Footer component\n */\nexport default function VersionHistory({ id, versionHistory }: VersionHistoryProps) {\n const [showAllVersions, setShowAllVersions] = useState(false);\n const currentDate = new Date();\n\n /**\n * Function to format the time string for the version history in the form of 'X year(s) ago'.\n *\n * @param dateString ISO Date string to determine the time string from\n * @returns Formatted time string\n */\n function formatTimeString(dateString: string) {\n const date = new Date(dateString);\n const dateDiff = new Date(currentDate.getTime() - date.getTime());\n const yearDiff = dateDiff.getUTCFullYear() - 1970;\n const monthDiff = dateDiff.getUTCMonth();\n const dayDiff = dateDiff.getUTCDate() - 1;\n\n // Determines how long ago the version was published\n let timeString = '';\n if (yearDiff > 0) {\n timeString = `${yearDiff.toString()} year${yearDiff === 1 ? '' : 's'} ago`;\n } else if (monthDiff > 0) {\n timeString = `${monthDiff.toString()} month${monthDiff === 1 ? '' : 's'} ago`;\n } else if (dayDiff === 0) {\n timeString = 'today';\n } else {\n timeString = `${dayDiff.toString()} day${dayDiff === 1 ? '' : 's'} ago`;\n }\n\n return timeString;\n }\n\n // Sorts the version history by version number\n const sortedEntries = Object.entries(versionHistory).sort((a, b) => b[0].localeCompare(a[0]));\n\n return (\n
    \n

    What`s New

    \n
      \n {(showAllVersions ? sortedEntries : sortedEntries.slice(0, 5)).map((entry) => (\n
      \n
      \n
    • \n {entry[1].description}\n
    • \n
      \n
      \n
      Version {entry[0]}
      \n
      {formatTimeString(entry[1].date)}
      \n
      \n
      \n ))}\n
    \n {sortedEntries.length > 5 && (\n setShowAllVersions(!showAllVersions)}\n className=\"tw-text-xs tw-text-gray-500 tw-underline\"\n >\n {showAllVersions ? 'Show Less Version History' : 'Show All Version History'}\n \n )}\n
    \n );\n}\n","import { useMemo } from 'react';\nimport { formatBytes } from 'platform-bible-utils';\nimport VersionHistory, { VersionHistoryType } from './version-history.component';\n\n/** Interface to store the parameters passed to the Footer component */\ninterface FooterProps {\n /** Optional unique identifier */\n id?: string;\n /** Name of the publisher */\n publisherDisplayName: string;\n /** Size of the extension file in bytes */\n fileSize: number;\n /** List of language codes supported by the extension */\n locales: string[];\n /** Object containing the version history mapped with their information */\n versionHistory: VersionHistoryType;\n}\n\n/**\n * Component to render the footer for the extension details which contains information on the\n * publisher, version history, languages, and file size.\n *\n * @param id Optional unique identifier\n * @param publisherDisplayName Name of the publisher\n * @param fileSize Size of the extension file in bytes\n * @param locales List of language codes supported by the extension\n * @param versionHistory Object containing the version history mapped with their information\n * @returns The rendered Footer component\n */\nexport default function Footer({\n id,\n publisherDisplayName,\n fileSize,\n locales,\n versionHistory,\n}: FooterProps) {\n /** Formats the file size into a human-readable format */\n const formattedFileSize = useMemo(() => formatBytes(fileSize), [fileSize]);\n\n /**\n * This function gets the display names of the languages based on the language codes.\n *\n * @param codes The list of language codes\n * @returns The list of language names\n */\n const getLanguageNames = (codes: string[]) => {\n const displayNames = new Intl.DisplayNames(navigator.language, { type: 'language' });\n return codes.map((code) => displayNames.of(code));\n };\n\n const languageNames = getLanguageNames(locales);\n\n return (\n
    \n
    \n \n
    \n
    \n

    Information

    \n
    \n

    \n Publisher\n {publisherDisplayName}\n Size\n {formattedFileSize}\n

    \n
    \n

    \n Languages\n {languageNames.join(', ')}\n

    \n
    \n
    \n
    \n
    \n
    \n );\n}\n","import { PlatformEvent, PlatformEventHandler } from 'platform-bible-utils';\nimport { useEffect } from 'react';\n\n/**\n * Adds an event handler to an event so the event handler runs when the event is emitted. Use\n * `papi.network.getNetworkEvent` to use a networked event with this hook.\n *\n * @param event The event to subscribe to.\n *\n * - If event is a `PlatformEvent`, that event will be used\n * - If event is undefined, the callback will not be subscribed. Useful if the event is not yet\n * available for example\n *\n * @param eventHandler The callback to run when the event is emitted\n *\n * WARNING: MUST BE STABLE - const or wrapped in useCallback. The reference must not be updated\n * every render\n */\nconst useEvent = (\n event: PlatformEvent | undefined,\n eventHandler: PlatformEventHandler,\n) => {\n useEffect(() => {\n // Do nothing if the event is not provided (in case the event is not yet available, for example)\n if (!event) return () => {};\n\n const unsubscriber = event(eventHandler);\n return () => {\n unsubscriber();\n };\n }, [event, eventHandler]);\n};\nexport default useEvent;\n","import { useCallback, useEffect } from 'react';\nimport { PlatformEvent, PlatformEventAsync, PlatformEventHandler } from 'platform-bible-utils';\nimport usePromise from './use-promise.hook';\n\nconst noopUnsubscriber = () => false;\n\n/**\n * Adds an event handler to an asynchronously subscribing/unsubscribing event so the event handler\n * runs when the event is emitted. Use `papi.network.getNetworkEvent` to use a networked event with\n * this hook.\n *\n * @param event The asynchronously (un)subscribing event to subscribe to.\n *\n * - If event is a `PlatformEvent` or `PlatformEventAsync`, that event will be used\n * - If event is undefined, the callback will not be subscribed. Useful if the event is not yet\n * available for example\n *\n * @param eventHandler The callback to run when the event is emitted\n *\n * WARNING: MUST BE STABLE - const or wrapped in useCallback. The reference must not be updated\n * every render\n */\nconst useEventAsync = (\n event: PlatformEvent | PlatformEventAsync | undefined,\n eventHandler: PlatformEventHandler,\n) => {\n // Subscribe to the event asynchronously\n const [unsubscribe] = usePromise(\n useCallback(async () => {\n // Do nothing if the event is not provided (in case the event is not yet available, for example)\n if (!event) return noopUnsubscriber;\n\n // Wrap subscribe and unsubscribe in promises to allow normal events to be used as well\n const unsub = await Promise.resolve(event(eventHandler));\n return async () => unsub();\n }, [eventHandler, event]),\n noopUnsubscriber,\n // We want the unsubscriber to return to default value immediately upon changing subscription\n // So the useEffect below will unsubscribe asap\n { preserveValue: false },\n );\n\n // Unsubscribe from the event asynchronously (but we aren't awaiting the unsub)\n useEffect(() => {\n return () => {\n if (unsubscribe !== noopUnsubscriber) {\n unsubscribe();\n }\n };\n }, [unsubscribe]);\n};\n\nexport default useEventAsync;\n"],"names":["twMergeCustom","extendTailwindMerge","cn","inputs","clsx","Input","React","className","type","props","ref","jsx","BookChapterInput","forwardRef","handleSearch","handleKeyDown","handleOnClick","handleSubmit","jsxs","ShadInput","event","e","History","P","R","t","s","n","N","B","O","S","K","g","k","x","T","X","V","w","L","G","A","H","C","I","y","q","U","m","l","h","c","E","D","i","a","o","u","v","f","d","b","p","J","DropdownMenu","DropdownMenuPrimitive","DropdownMenuTrigger","DropdownMenuGroup","DropdownMenuPortal","DropdownMenuSub","DropdownMenuRadioGroup","DropdownMenuSubTrigger","inset","children","ChevronRight","DropdownMenuSubContent","DropdownMenuContent","sideOffset","DropdownMenuItem","DropdownMenuCheckboxItem","checked","Check","DropdownMenuRadioItem","Circle","DropdownMenuLabel","DropdownMenuSeparator","DropdownMenuShortcut","BookMenuItem","bookId","handleSelectBook","isSelected","handleHighlightBook","bookType","ShadDropdownMenuItem","Canon","ChapterSelect","handleSelectChapter","endChapter","activeChapter","highlightedChapter","handleHighlightedChapter","chapters","_","handleMouse","useCallback","chapterNumber","chapter","GoToMenuItem","handleSort","handleLocationHistory","handleBookmarks","ShadDropdownMenuLabel","ArrowDownWideNarrow","Clock","Bookmark","ALL_BOOK_IDS","BOOK_TYPE_LABELS","BOOK_TYPE_ARRAY","SCROLL_OFFSET","SEARCH_QUERY_FORMATS","fetchGroupedBooks","fetchEndChapter","getChaptersForBook","getAllEnglishNames","isValidBookEnglishName","bookName","getBookIdFromEnglishName","formattedBookName","BookChapterControl","scrRef","searchQuery","setSearchQuery","useState","selectedBookId","setSelectedBookId","setHighlightedChapter","highlightedBookId","setHighlightedBookId","isContentOpen","setIsContentOpen","isContentOpenDelayed","setIsContentOpenDelayed","inputRef","useRef","contentRef","menuItemRef","fetchFilteredBooks","englishNameLowerCase","normalizedQuery","handleSearchInput","searchString","shouldPreventAutoClosing","controlMenuState","open","updateReference","shouldClose","verse","handleInputSubmit","format","matches","book","englishName","handleKeyDownInput","handleKeyDownContent","key","handleKeyDownMenuItem","chapterOffSet","useEffect","useLayoutEffect","scrollTimeout","scrollPosition","ShadDropdownMenu","ShadDropdownMenuTrigger","ShadDropdownMenuContent","bookTypeIndex","element","ShadDropdownMenuSeparator","buttonVariants","cva","Button","variant","size","asChild","Comp","Slot","labelVariants","Label","LabelPrimitive","RadioGroup","RadioGroupPrimitive","RadioGroupItem","Popover","PopoverPrimitive","PopoverTrigger","PopoverContent","align","DialogPortal","DialogPrimitive","DialogOverlay","DialogContent","DialogTitle","DialogDescription","Command","CommandPrimitive","CommandInput","Search","CommandList","CommandEmpty","CommandGroup","CommandSeparator","CommandItem","getOptionLabelDefault","option","ComboBox","id","options","buttonClassName","popoverContentClassName","value","onChange","getOptionLabel","buttonPlaceholder","textPlaceholder","commandEmptyMessage","buttonVariant","dir","isDisabled","setOpen","ChevronsUpDown","ChapterRangeSelector","startChapter","handleSelectStartChapter","handleSelectEndChapter","chapterCount","chapterOptions","useMemo","index","onChangeStartChapter","onChangeEndChapter","Fragment","BookSelectionMode","BOOK_SELECTOR_STRING_KEYS","localizeString","strings","BookSelector","handleBookSelectionModeChange","currentBookName","onSelectBooks","selectedBookIds","localizedStrings","currentBookText","chooseText","chooseBooksText","bookSelectionMode","setBookSelectionMode","onSelectionModeChange","newMode","DataTableViewOptions","table","FilterIcon","column","Select","SelectPrimitive","SelectGroup","SelectValue","SelectTrigger","ChevronDown","SelectScrollUpButton","ChevronUp","SelectScrollDownButton","SelectContent","position","SelectLabel","SelectItem","SelectSeparator","DataTablePagination","pageSize","ArrowLeftIcon","ChevronLeftIcon","ChevronRightIcon","ArrowRightIcon","Table","stickyHeader","TableHeader","TableBody","TableFooter","TableRow","TableHead","TableCell","TableCaption","DataTable","columns","data","enablePagination","showPaginationControls","showColumnVisibilityControls","onRowClickHandler","sorting","setSorting","columnFilters","setColumnFilters","columnVisibility","setColumnVisibility","rowSelection","setRowSelection","useReactTable","getCoreRowModel","getPaginationRowModel","getSortedRowModel","getFilteredRowModel","headerGroup","header","flexRender","_a","row","cell","OccurrencesTable","occurrenceData","setScriptureReference","referenceHeaderText","occurrenceHeaderText","occurrences","uniqueOccurrences","occurrence","uniqueOccurrence","deepEqual","Checkbox","CheckboxPrimitive","getLinesFromUSFM","text","getNumberFromUSFM","regex","match","getBookNumFromId","getStatusForItem","item","approvedItems","unapprovedItems","toggleVariants","Toggle","TogglePrimitive","ToggleGroupContext","ToggleGroup","ToggleGroupPrimitive","ToggleGroupItem","context","getSortingIcon","sortDirection","ArrowUpIcon","ArrowDownIcon","ArrowUpDownIcon","inventoryItemColumn","itemLabel","inventoryAdditionalItemColumn","additionalItemLabel","additionalItemIndex","inventoryCountColumn","countLabel","statusChangeHandler","changedItems","newStatus","onApprovedItemsChange","onUnapprovedItemsChange","newApprovedItems","validItem","newUnapprovedItems","unapprovedItem","inventoryStatusColumn","statusLabel","status","CircleCheckIcon","CircleXIcon","CircleHelpIcon","INVENTORY_STRING_KEYS","filterItemData","itemData","statusFilter","textFilter","filteredItemData","createTableData","scriptureRef","itemRegex","tableData","currentBook","currentChapter","currentVerse","line","items","itemIndex","existingItem","tableEntry","newReference","substring","newItem","Inventory","scriptureReference","extractItems","additionalItemsLabels","scope","onScopeChange","allItemsText","approvedItemsText","unapprovedItemsText","unknownItemsText","scopeBookText","scopeChapterText","scopeVerseText","filterText","showAdditionalItemsText","showAdditionalItems","setShowAdditionalItems","setStatusFilter","setTextFilter","selectedItem","setSelectedItem","reducedTableData","newTableData","firstItem","existingEntry","newTableEntry","filteredTableData","allColumns","numberOfAdditionalItems","additionalColumns","_b","rowClickHandler","newSelection","handleScopeChange","handleStatusFilterChange","SearchBar","onSearch","placeholder","isFullWidth","handleInputChange","VerticalTabs","TabsPrimitive","VerticalTabsList","VerticalTabsTrigger","VerticalTabsContent","TabNavigationContentSearch","tabList","searchPlaceholder","headerTitle","isSearchBarFullWidth","direction","tab","Separator","orientation","decorative","SeparatorPrimitive","Sheet","SheetPrimitive","SheetPortal","SheetOverlay","sheetVariants","SheetContent","side","SheetTitle","SheetDescription","Skeleton","TooltipProvider","TooltipPrimitive","Tooltip","TooltipTrigger","TooltipContent","MOBILE_BREAKPOINT","useIsMobile","isMobile","setIsMobile","mql","SIDEBAR_COOKIE_NAME","SIDEBAR_COOKIE_MAX_AGE","SIDEBAR_WIDTH","SIDEBAR_WIDTH_MOBILE","SIDEBAR_WIDTH_ICON","SIDEBAR_KEYBOARD_SHORTCUT","SidebarContext","useSidebar","SidebarProvider","defaultOpen","openProp","setOpenProp","style","openMobile","setOpenMobile","_open","_setOpen","isOpen","openState","toggleSidebar","state","contextValue","Sidebar","collapsible","SidebarTrigger","onClick","PanelLeft","SidebarRail","SidebarInset","SidebarInput","SidebarHeader","SidebarFooter","SidebarSeparator","SidebarContent","SidebarGroup","SidebarGroupLabel","SidebarGroupAction","SidebarGroupContent","SidebarMenu","SidebarMenuItem","sidebarMenuButtonVariants","SidebarMenuButton","isActive","tooltip","button","SidebarMenuAction","showOnHover","SidebarMenuBadge","SidebarMenuSkeleton","showIcon","width","SidebarMenuSub","SidebarMenuSubItem","SidebarMenuSubButton","SettingsSidebar","extensionLabels","projectOptions","handleSelectSidebarItem","selectedSidebarItem","extensionsSidebarGroupLabel","projectsSidebarGroupLabel","buttonPlaceholderText","handleSelectItem","projectId","getProjectNameFromProjectId","project","getIsActive","label","selectedProjectName","SettingsSidebarContentSearch","scrBookColId","scrRefColId","typeColId","detailsColId","defaultScrRefColumnName","defaultScrBookGroupName","defaultTypeColumnName","defaultDetailsColumnName","getColumns","colInfo","showSourceColumn","showSrcCol","info","formatScrRef","compareScrRefs","toRefOrRange","scriptureSelection","offsetStart","offsetEnd","scrRefToBBBCCCVVV","getRowKey","ScriptureResultsViewer","sources","showColumnHeaders","scriptureReferenceColumnName","scriptureBookGroupName","typeColumnName","detailsColumnName","onRowSelected","grouping","setGrouping","scriptureResults","source","getExpandedRowModel","getGroupedRowModel","selectedRows","keys","selectedRow","scrBookGroupName","typeGroupName","groupingOptions","handleSelectChange","selectedGrouping","handleRowClick","getEvenOrOddBandingStyle","getIndent","groupingState","rowIndex","ChevronLeft","DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS","getLocalizeKeyForScrollGroupId","ScrollGroupSelector","availableScrollGroupIds","scrollGroupId","onChangeScrollGroupId","localizedStringsDefaulted","localizedStringKey","localizedStringValue","newScrollGroupString","scrollGroupOptionId","SettingsList","SettingsListItem","primary","secondary","isLoading","loadingMessage","SettingsListHeader","includeSeparator","Checklist","listItems","selectedListItems","handleSelectListItem","createLabel","_interopRequireDefault","obj","module","chainPropTypes","propType1","propType2","args","_extends","target","isPlainObject","prototype","deepClone","output","deepmerge","r","z","reactIs_production_min","hasSymbol","REACT_ELEMENT_TYPE","REACT_PORTAL_TYPE","REACT_FRAGMENT_TYPE","REACT_STRICT_MODE_TYPE","REACT_PROFILER_TYPE","REACT_PROVIDER_TYPE","REACT_CONTEXT_TYPE","REACT_ASYNC_MODE_TYPE","REACT_CONCURRENT_MODE_TYPE","REACT_FORWARD_REF_TYPE","REACT_SUSPENSE_TYPE","REACT_SUSPENSE_LIST_TYPE","REACT_MEMO_TYPE","REACT_LAZY_TYPE","REACT_BLOCK_TYPE","REACT_FUNDAMENTAL_TYPE","REACT_RESPONDER_TYPE","REACT_SCOPE_TYPE","isValidElementType","typeOf","object","$$typeof","$$typeofType","AsyncMode","ConcurrentMode","ContextConsumer","ContextProvider","Element","ForwardRef","Lazy","Memo","Portal","Profiler","StrictMode","Suspense","hasWarnedAboutDeprecatedIsAsyncMode","isAsyncMode","isConcurrentMode","isContextConsumer","isContextProvider","isElement","isForwardRef","isFragment","isLazy","isMemo","isPortal","isProfiler","isStrictMode","isSuspense","reactIs_development","reactIsModule","require$$0","require$$1","getOwnPropertySymbols","hasOwnProperty","propIsEnumerable","toObject","val","shouldUseNative","test1","test2","order2","test3","letter","objectAssign","from","to","symbols","ReactPropTypesSecret","ReactPropTypesSecret_1","has","printWarning","loggedTypeFailures","message","checkPropTypes","typeSpecs","values","location","componentName","getStack","typeSpecName","error","err","ex","stack","checkPropTypes_1","ReactIs","assign","require$$2","require$$3","require$$4","emptyFunctionThatReturnsNull","factoryWithTypeCheckers","isValidElement","throwOnDirectAccess","ITERATOR_SYMBOL","FAUX_ITERATOR_SYMBOL","getIteratorFn","maybeIterable","iteratorFn","ANONYMOUS","ReactPropTypes","createPrimitiveTypeChecker","createAnyTypeChecker","createArrayOfTypeChecker","createElementTypeChecker","createElementTypeTypeChecker","createInstanceTypeChecker","createNodeChecker","createObjectOfTypeChecker","createEnumTypeChecker","createUnionTypeChecker","createShapeTypeChecker","createStrictShapeTypeChecker","is","PropTypeError","createChainableTypeChecker","validate","manualPropTypeCallCache","manualPropTypeWarningCount","checkType","isRequired","propName","propFullName","secret","cacheKey","chainedCheckType","expectedType","propValue","propType","getPropType","preciseType","getPreciseType","typeChecker","expectedClass","expectedClassName","actualClassName","getClassName","expectedValues","valuesString","arrayOfTypeCheckers","checker","getPostfixForTypeWarning","expectedTypes","checkerResult","expectedTypesMessage","isNode","invalidValidatorError","shapeTypes","allKeys","iterator","step","entry","isSymbol","emptyFunction","emptyFunctionWithReset","factoryWithThrowingShims","shim","getShim","propTypesModule","isClassComponent","elementType","acceptingRef","safePropName","warningHint","elementAcceptingRef","PropTypes","elementAcceptingRef$1","specialProperty","exactProp","propTypes","unsupportedProps","prop","formatMuiErrorMessage","code","url","REACT_SERVER_CONTEXT_TYPE","REACT_OFFSCREEN_TYPE","enableScopeAPI","enableCacheElement","enableTransitionTracing","enableLegacyHidden","enableDebugTracing","REACT_MODULE_REFERENCE","SuspenseList","hasWarnedAboutDeprecatedIsConcurrentMode","isSuspenseList","fnNameMatchRegex","getFunctionName","fn","getFunctionComponentName","Component","fallback","getWrappedName","outerType","innerType","wrapperName","functionName","getDisplayName","HTMLElementType","refType","refType$1","capitalize","string","_formatMuiErrorMessage","createChainedFunction","funcs","acc","func","debounce","wait","timeout","debounced","later","deprecatedPropType","validator","reason","componentNameSafe","propFullNameSafe","isMuiElement","muiNames","_muiName","_element$type","ownerDocument","node","ownerWindow","requirePropFactory","componentNameInError","prevPropTypes","requiredProp","defaultTypeChecker","typeCheckerResult","setRef","useEnhancedEffect","useEnhancedEffect$1","globalId","useGlobalId","idOverride","defaultId","setDefaultId","maybeReactUseId","useId","reactId","unsupportedProp","useControlled","controlled","defaultProp","name","isControlled","valueState","setValue","defaultValue","setValueIfUncontrolled","newValue","useEventCallback","useForkRef","refs","instance","UNINITIALIZED","useLazyRef","init","initArg","EMPTY","useOnMount","Timeout","delay","useTimeout","hadKeyboardEvent","hadFocusVisibleRecently","hadFocusVisibleRecentlyTimeout","inputTypesWhitelist","focusTriggersKeyboardModality","tagName","handlePointerDown","handleVisibilityChange","prepare","doc","isFocusVisible","useIsFocusVisible","isFocusVisibleRef","handleBlurVisible","handleFocusVisible","resolveProps","defaultProps","defaultSlotProps","slotProps","slotPropName","composeClasses","slots","getUtilityClass","classes","slot","utilityClass","defaultGenerator","createClassNameGenerator","generate","generator","ClassNameGenerator","ClassNameGenerator$1","globalStateClasses","generateUtilityClass","globalStatePrefix","globalStateClass","generateUtilityClasses","result","clamp","min","max","_objectWithoutPropertiesLoose","excluded","sourceKeys","_excluded","sortBreakpointsValues","breakpointsAsArray","breakpoint1","breakpoint2","createBreakpoints","breakpoints","unit","other","sortedValues","up","down","between","start","end","endIndex","only","not","keyIndex","shape","shape$1","responsivePropType","responsivePropType$1","merge","defaultBreakpoints","handleBreakpoints","styleFromPropValue","theme","themeBreakpoints","breakpoint","mediaKey","cssKey","createEmptyBreakpointObject","breakpointsInput","_breakpointsInput$key","breakpointStyleKey","removeUnusedBreakpoints","breakpointKeys","breakpointOutput","getPath","path","checkVars","getStyleValue","themeMapping","transform","propValueFinal","userValue","cssProperty","themeKey","memoize","cache","arg","properties","directions","aliases","getCssProperties","property","marginKeys","paddingKeys","spacingKeys","createUnaryUnit","_getPath","themeSpacing","abs","createUnarySpacing","getValue","transformer","transformed","getStyleFromPropValue","cssProperties","resolveCssProperty","margin","padding","createSpacing","spacingInput","spacing","argsInput","argument","compose","styles","handlers","borderTransform","createBorderStyle","border","borderTop","borderRight","borderBottom","borderLeft","borderColor","borderTopColor","borderRightColor","borderBottomColor","borderLeftColor","outline","outlineColor","borderRadius","gap","columnGap","rowGap","gridColumn","gridRow","gridAutoFlow","gridAutoColumns","gridAutoRows","gridTemplateColumns","gridTemplateRows","gridTemplateAreas","gridArea","paletteTransform","color","bgcolor","backgroundColor","sizingTransform","maxWidth","_props$theme","_props$theme2","breakpointsValues","minWidth","height","maxHeight","minHeight","boxSizing","defaultSxConfig","defaultSxConfig$1","objectsHaveSameKeys","objects","union","callIfFn","maybeFn","unstable_createStyleFunctionSx","getThemeValue","config","styleFunctionSx","_theme$unstable_sxCon","sx","traverse","sxInput","sxObject","emptyBreakpoints","breakpointsKeys","css","styleKey","styleFunctionSx$1","applyStyles","createTheme","paletteInput","shapeInput","muiTheme","isObjectEmpty","useTheme","defaultTheme","contextTheme","ThemeContext","systemDefaultTheme","useThemeWithoutDefault","_excluded2","_excluded3","isEmpty","isStringTag","tag","shouldForwardProp","lowercaseFirstLetter","resolveTheme","themeId","defaultOverridesResolver","processStyleArg","callableStyle","_ref","ownerState","resolvedStylesArg","resolvedStyle","variants","isMatch","createStyled","input","rootShouldForwardProp","slotShouldForwardProp","systemSx","inputOptions","processStyles","componentSlot","inputSkipVariantsResolver","inputSkipSx","overridesResolver","skipVariantsResolver","skipSx","shouldForwardPropOption","defaultStyledResolver","styledEngineStyled","transformStyleArg","stylesArg","muiStyledResolver","styleArg","expressions","transformedStyleArg","expressionsWithDefaultTheme","styleOverrides","resolvedStyleOverrides","slotKey","slotStyle","_theme$components","themeVariants","numOfCustomFnsApplied","placeholders","displayName","getThemeProps","params","useThemeProps","clampWrapper","hexToRgb","re","colors","decomposeColor","marker","colorSpace","recomposeColor","hslToRgb","rgb","getLuminance","getContrastRatio","foreground","background","lumA","lumB","alpha","darken","coefficient","lighten","createMixins","mixins","common","common$1","grey","grey$1","purple","purple$1","red","red$1","orange","orange$1","blue","blue$1","lightBlue","lightBlue$1","green","green$1","light","dark","addLightOrDark","intent","shade","tonalOffset","tonalOffsetLight","tonalOffsetDark","getDefaultPrimary","mode","getDefaultSecondary","getDefaultError","getDefaultInfo","getDefaultSuccess","getDefaultWarning","createPalette","palette","contrastThreshold","success","warning","getContrastText","contrastText","contrast","augmentColor","mainShade","lightShade","darkShade","modes","round","caseAllCaps","defaultFontFamily","createTypography","typography","fontFamily","fontSize","fontWeightLight","fontWeightRegular","fontWeightMedium","fontWeightBold","htmlFontSize","allVariants","pxToRem2","coef","pxToRem","buildVariant","fontWeight","lineHeight","letterSpacing","casing","shadowKeyUmbraOpacity","shadowKeyPenumbraOpacity","shadowAmbientShadowOpacity","createShadow","px","shadows","shadows$1","easing","duration","formatMs","milliseconds","getAutoHeightDuration","constant","createTransitions","inputTransitions","mergedEasing","mergedDuration","durationOption","easingOption","isString","isNumber","animatedProp","zIndex","zIndex$1","mixinsInput","transitionsInput","typographyInput","systemTheme","systemCreateTheme","stateClasses","component","child","stateClass","defaultTheme$1","THEME_ID","systemUseThemeProps","styled","styled$1","getSvgIconUtilityClass","useUtilityClasses","SvgIconRoot","_theme$transitions","_theme$transitions$cr","_theme$transitions2","_theme$typography","_theme$typography$pxT","_theme$typography2","_theme$typography2$px","_theme$typography3","_theme$typography3$px","_palette$ownerState$c","_palette","_palette2","_palette3","SvgIcon","inProps","htmlColor","inheritViewBox","titleAccess","viewBox","hasSvgAsChild","more","_jsxs","_jsx","SvgIcon$1","createSvgIcon","unstable_ClassNameGenerator","exports","_utils","ArrowRight","default_1","_createSvgIcon","_jsxRuntime","isHostComponent","appendOwnerState","otherProps","defaultContextValue","ClassNameConfiguratorContext","useClassNamesOverride","disableDefaultClasses","extractEventHandlers","excludeKeys","resolveComponentProps","componentProps","slotState","omitEventHandlers","mergeSlotProps","parameters","getSlotProps","additionalProps","externalSlotProps","externalForwardedProps","joinedClasses","mergedStyle","eventHandlers","componentsPropsWithoutEventHandlers","otherPropsWithoutEventHandlers","internalSlotProps","useSlotProps","_parameters$additiona","skipResolvingSlotProps","rest","resolvedComponentsProps","mergedProps","internalRef","GLOBAL_CLASS_PREFIX","buildStateClass","buildSlotClass","getContainer","container","forwardedRef","disablePortal","mountNode","setMountNode","handleRef","newProps","ReactDOM","top","bottom","right","left","auto","basePlacements","clippingParents","viewport","popper","reference","variationPlacements","placement","placements","beforeRead","read","afterRead","beforeMain","main","afterMain","beforeWrite","write","afterWrite","modifierPhases","getNodeName","getWindow","OwnElement","isHTMLElement","isShadowRoot","attributes","effect","_ref2","initialStyles","styleProperties","attribute","applyStyles$1","getBasePlacement","getUAString","uaData","isLayoutViewport","getBoundingClientRect","includeScale","isFixedStrategy","clientRect","scaleX","scaleY","visualViewport","addVisualOffsets","getLayoutRect","contains","parent","rootNode","next","getComputedStyle","isTableElement","getDocumentElement","getParentNode","getTrueOffsetParent","getContainingBlock","isFirefox","isIE","elementCss","currentNode","getOffsetParent","window","offsetParent","getMainAxisFromPlacement","within","mathMax","mathMin","withinMaxClamp","getFreshSideObject","mergePaddingObject","paddingObject","expandToHashMap","hashMap","toPaddingObject","arrow","_state$modifiersData$","arrowElement","popperOffsets","basePlacement","axis","isVertical","len","arrowRect","minProp","maxProp","endDiff","startDiff","arrowOffsetParent","clientSize","centerToReference","center","offset","axisProp","_options$element","arrow$1","getVariation","unsetSides","roundOffsetsByDPR","win","dpr","mapToStyles","_Object$assign2","popperRect","variation","offsets","gpuAcceleration","adaptive","roundOffsets","isFixed","_offsets$x","_offsets$y","_ref3","hasX","hasY","sideX","sideY","heightProp","widthProp","offsetY","offsetX","commonStyles","_ref4","_Object$assign","computeStyles","_ref5","_options$gpuAccelerat","_options$adaptive","_options$roundOffsets","computeStyles$1","passive","_options$scroll","scroll","_options$resize","resize","scrollParents","scrollParent","eventListeners","hash","getOppositePlacement","matched","getOppositeVariationPlacement","getWindowScroll","scrollLeft","scrollTop","getWindowScrollBarX","getViewportRect","strategy","html","layoutViewport","getDocumentRect","_element$ownerDocumen","winScroll","body","isScrollParent","_getComputedStyle","overflow","overflowX","overflowY","getScrollParent","listScrollParents","list","isBody","updatedList","rectToClientRect","rect","getInnerBoundingClientRect","getClientRectFromMixedType","clippingParent","getClippingParents","canEscapeClipping","clipperElement","getClippingRect","boundary","rootBoundary","mainClippingParents","firstClippingParent","clippingRect","accRect","computeOffsets","commonX","commonY","mainAxis","detectOverflow","_options","_options$placement","_options$strategy","_options$boundary","_options$rootBoundary","_options$elementConte","elementContext","_options$altBoundary","altBoundary","_options$padding","altContext","clippingClientRect","referenceClientRect","popperClientRect","elementClientRect","overflowOffsets","offsetData","multiply","computeAutoPlacement","flipVariations","_options$allowedAutoP","allowedAutoPlacements","allPlacements","allowedPlacements","overflows","getExpandedFallbackPlacements","oppositePlacement","flip","_options$mainAxis","checkMainAxis","_options$altAxis","checkAltAxis","specifiedFallbackPlacements","_options$flipVariatio","preferredPlacement","isBasePlacement","fallbackPlacements","referenceRect","checksMap","makeFallbackChecks","firstFittingPlacement","_basePlacement","isStartVariation","mainVariationSide","altVariationSide","checks","check","numberOfChecks","_loop","_i","fittingPlacement","_ret","flip$1","getSideOffsets","preventedOffsets","isAnySideFullyClipped","hide","referenceOverflow","popperAltOverflow","referenceClippingOffsets","popperEscapeOffsets","isReferenceHidden","hasPopperEscaped","hide$1","distanceAndSkiddingToXY","rects","invertDistance","skidding","distance","_options$offset","_data$state$placement","offset$1","popperOffsets$1","getAltAxis","preventOverflow","_options$tether","tether","_options$tetherOffset","tetherOffset","altAxis","tetherOffsetValue","normalizedTetherOffsetValue","offsetModifierState","_offsetModifierState$","mainSide","altSide","additive","minLen","maxLen","arrowPaddingObject","arrowPaddingMin","arrowPaddingMax","arrowLen","minOffset","maxOffset","clientOffset","offsetModifierValue","tetherMin","tetherMax","preventedOffset","_offsetModifierState$2","_mainSide","_altSide","_offset","_len","_min","_max","isOriginSide","_offsetModifierValue","_tetherMin","_tetherMax","_preventedOffset","preventOverflow$1","getHTMLElementScroll","getNodeScroll","isElementScaled","getCompositeRect","elementOrVirtualElement","isOffsetParentAnElement","offsetParentIsScaled","documentElement","order","modifiers","map","visited","modifier","sort","requires","dep","depModifier","orderModifiers","orderedModifiers","phase","pending","resolve","mergeByName","merged","current","existing","DEFAULT_OPTIONS","areValidElements","_key","popperGenerator","generatorOptions","_generatorOptions","_generatorOptions$def","defaultModifiers","_generatorOptions$def2","defaultOptions","effectCleanupFns","isDestroyed","setOptionsAction","cleanupModifierEffects","runModifierEffects","_state$elements","_state$orderedModifie","_state$orderedModifie2","_ref$options","cleanupFn","noopFn","createPopper","COMPONENT_NAME","getPopperUtilityClass","flipPlacement","resolveAnchorEl","anchorEl","isVirtualElement","defaultPopperOptions","PopperTooltip","_slots$root","initialPlacement","popperOptions","popperRefProp","TransitionProps","tooltipRef","ownRef","popperRef","handlePopperRef","handlePopperRefRef","rtlPlacement","setPlacement","resolvedAnchorElement","setResolvedAnchorElement","handlePopperUpdate","box","popperModifiers","childProps","Root","rootProps","Popper","containerProp","keepMounted","transition","exited","setExited","handleEnter","handleExited","resolvedAnchorEl","display","transitionProps","useThemeSystem","_setPrototypeOf","_inheritsLoose","subClass","superClass","setPrototypeOf","timeoutsShape","TransitionGroupContext","forceReflow","UNMOUNTED","EXITED","ENTERING","ENTERED","EXITING","Transition","_React$Component","_this","parentGroup","appear","initialStatus","prevState","nextIn","_proto","prevProps","nextStatus","exit","enter","mounting","_this2","appearing","maybeNode","maybeAppearing","timeouts","enterTimeout","_this3","nextState","callback","_this4","active","handler","doesNotHaveTimeoutOrListener","maybeNextCallback","_this$props","pt","noop","Transition$1","reflow","getTransitionProps","_style$transitionDura","_style$transitionTimi","getScale","isWebKit154","Grow","addEndListener","inProp","onEnter","onEntered","onEntering","onExit","onExited","onExiting","TransitionComponent","timer","autoTimeout","nodeRef","normalizedTransitionCallback","maybeIsAppearing","handleEntering","isAppearing","transitionDuration","transitionTimingFunction","handleEntered","handleExiting","handleExit","handleAddEndListener","Grow$1","PopperRoot","BasePopper","components","componentsProps","RootComponent","Popper$1","getTooltipUtilityClass","tooltipClasses","tooltipClasses$1","disableInteractive","touch","TooltipPopper","TooltipTooltip","TooltipArrow","hystersisOpen","hystersisTimer","cursorPosition","composeEventHandler","eventHandler","_slots$popper","_slots$transition","_slots$tooltip","_slots$arrow","_slotProps$popper","_ref6","_slotProps$popper2","_slotProps$transition","_slotProps$tooltip","_ref7","_slotProps$tooltip2","_slotProps$arrow","_ref8","_slotProps$arrow2","childrenProp","describeChild","disableFocusListener","disableHoverListener","disableInteractiveProp","disableTouchListener","enterDelay","enterNextDelay","enterTouchDelay","followCursor","idProp","leaveDelay","leaveTouchDelay","onClose","onOpen","PopperComponentProp","PopperProps","title","TransitionComponentProp","isRtl","childNode","setChildNode","arrowRef","setArrowRef","ignoreNonTouchEvents","closeTimer","enterTimer","leaveTimer","touchTimer","setOpenState","prevUserSelect","stopTouchInteraction","handleOpen","handleClose","handleLeave","focusVisibleRef","setChildIsFocusVisible","handleBlur","handleFocus","detectTouchStart","childrenProps","handleMouseOver","handleMouseLeave","handleTouchStart","handleTouchEnd","nativeEvent","handleMouseMove","nameOrDescProps","titleIsString","interactiveWrapperListeners","_PopperProps$popperOp","tooltipModifiers","PopperComponent","TooltipComponent","ArrowComponent","popperProps","tooltipProps","tooltipArrowProps","TransitionPropsInner","Tooltip$1","getIcon","icon","menuLabel","leading","MuiListItemIcon","MenuItem","allowForLeadingIcons","iconPathBefore","iconPathAfter","hasAutoFocus","isDense","isSubMenuParent","hasDisabledGutters","hasDivider","focusVisibleClassName","menuItem","MuiMenuItem","MuiListItemText","getAllGroups","menuDefinition","SubMenu","setAnchorEl","parentMenuItem","parentItemProps","handleParentMenuItemClick","renderSubMenuItems","includedGroups","group","GroupedMenuItemList","Menu","getOrderedGroupItems","groupId","allItems","menuProps","commandHandler","groupsToInclude","sortedGroups","itemArray","allowSpaceForLeadingIcons","createMenuItemProps","isLastItemInGroup","divKey","itemInfo","menuItemProps","TopLevelMenu","columnId","MenuColumn","metadata","Grid","List","GridMenu","multiColumnMenu","sortedColumns","columnNumbers","columnName","col","getUsePromiseOptionsDefaults","usePromise","promiseFactoryCallback","defaultValueRef","optionsDefaultedRef","setIsLoading","promiseIsCurrent","MenuIcon","HamburgerMenuButton","menuProvider","normalMenu","fullMenu","containerRef","ariaLabelPrefix","isMenuOpen","setMenuOpen","showFullMenu","setShowFullMenu","handleMenuItemClick","handleMenuButtonClick","prevIsOpen","isOpening","menuCommandHandler","command","setOffset","normalMenuData","fullMenuData","menu","IconButton","Drawer","isTooltipSuppressed","adjustMarginToAlignToEdge","MuiIconButton","Spinner","LoaderCircle","TextField","hasError","helperText","onFocus","onBlur","ShadLabel","Toolbar","AppBar","MuiToolbar","alertVariants","Alert","AlertTitle","AlertDescription","Card","CardHeader","CardTitle","CardDescription","CardContent","CardFooter","Sonner","Toaster","Slider","SliderPrimitive","Switch","SwitchPrimitives","Tabs","TabsList","TabsTrigger","TabsContent","InstallButton","isInstalling","handleClick","buttonText","Download","EnableButton","isEnabling","DisableButton","isDisabling","UpdateButton","isUpdating","MarkdownRenderer","markdown","anchorTarget","Markdown","FilterButton","Filter","DropdownMenuItemType","DropdownMenuItemType2","FilterDropdown","groups","NoExtensionsFound","MoreInfo","category","downloads","languages","moreInfoUrl","numberFormatted","NumberFormat","handleScrollToBottom","User","locale","LucideLink","CircleHelp","VersionHistory","versionHistory","showAllVersions","setShowAllVersions","currentDate","formatTimeString","dateString","date","dateDiff","yearDiff","monthDiff","dayDiff","timeString","sortedEntries","Footer","publisherDisplayName","fileSize","locales","formattedFileSize","formatBytes","languageNames","codes","displayNames","useEvent","unsubscriber","noopUnsubscriber","useEventAsync","unsubscribe","unsub"],"mappings":"28CAGA,MAAMA,GAAgBC,GAAAA,oBAAoB,CAAE,OAAQ,KAAO,CAAA,EAyDpD,SAASC,KAAMC,EAAsB,CACnC,OAAAH,GAAcI,GAAAA,KAAKD,CAAM,CAAC,CACnC,CCzDO,MAAME,GAAQC,EAAM,WACzB,CAAC,CAAE,UAAAC,EAAW,KAAAC,EAAM,GAAGC,CAAA,EAASC,IAE5BC,EAAA,IAAC,QAAA,CACC,KAAAH,EACA,UAAWN,EACT,sbACAK,CACF,EACA,IAAAG,EAEC,GAAGD,CAAA,CAAA,CAIZ,EACA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MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MAEA,MAEA,MAEA,MAEA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,MAEA,MAEA,MAEA,MAEA,MACA,MACA,MACA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,KACF,EAAGC,GAAI,CACL,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,KACF,EAAGC,GAAI,CACL,UACA,SACA,YACA,UACA,cACA,SACA,SACA,OACA,WACA,WACA,UACA,UACA,eACA,eACA,OACA,WACA,kBACA,MACA,SACA,WACA,eACA,gBACA,SACA,WACA,eACA,UACA,kBACA,QACA,OACA,OACA,UACA,QACA,QACA,QACA,WACA,YACA,SACA,YACA,UACA,UACA,OACA,OACA,OACA,OACA,SACA,gBACA,gBACA,YACA,YACA,cACA,aACA,kBACA,kBACA,YACA,YACA,QACA,WACA,UACA,QACA,UACA,UACA,SACA,SACA,SACA,OACA,aACA,QACA,SACA,eACA,oBACA,0BACA,SACA,qBACA,sBACA,UACA,qBACA,cACA,cACA,cACA,cACA,mBACA,mBACA,qBACA,YACA,OACA,oBAGA,uBACA,uBACA,sBACA,yBACA,wBACA,qBACA,UACA,UACA,UACA,UACA,UACA,UACA,UACA,eACA,cACA,eACA,oBACA,qBACA,0BACA,0BACA,eACA,eACA,YACA,gBACA,cACA,eACA,iBACA,wBACA,mBACA,WACA,QACA,aACA,aACA,aACA,2BACA,4BACA,YACF,EAAGC,GAAIC,KACP,SAASC,GAAER,EAAGJ,EAAI,GAAI,CACpB,OAAOA,IAAMI,EAAIA,EAAE,YAAa,GAAGA,KAAKM,GAAIA,GAAEN,CAAC,EAAI,CACrD,CACA,SAASS,GAAET,EAAG,CACZ,OAAOQ,GAAER,CAAC,EAAI,CAChB,CACA,SAASU,GAAEV,EAAG,CACZ,MAAMJ,EAAI,OAAOI,GAAK,SAAWQ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AAU,UACV,UAAWA,EACZ,EACD,aAAc,CACZ,SAAU,SACX,EACD,aAAc,CACZ,SAAU,qBACV,MAAOc,EACR,EAED,MAAO,CACL,SAAU,UACV,UAAWa,EACZ,EACD,QAAS,CACP,SAAU,UACV,YAAa,kBACb,UAAWA,EACZ,EACD,gBAAiB,CACf,SAAU,UACV,UAAWA,EACZ,EAED,EAAG,CACD,MAAOpC,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,QAAS,CACP,MAAOA,EACR,EACD,WAAY,CACV,MAAOA,EACR,EACD,aAAc,CACZ,MAAOA,EACR,EACD,cAAe,CACb,MAAOA,EACR,EACD,YAAa,CACX,MAAOA,EACR,EACD,SAAU,CACR,MAAOA,EACR,EACD,SAAU,CACR,MAAOA,EACR,EACD,cAAe,CACb,MAAOA,EACR,EACD,mBAAoB,CAClB,MAAOA,EACR,EACD,iBAAkB,CAChB,MAAOA,EACR,EACD,aAAc,CACZ,MAAOA,EACR,EACD,kBAAmB,CACjB,MAAOA,EACR,EACD,gBAAiB,CACf,MAAOA,EACR,EACD,EAAG,CACD,MAAOD,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,OAAQ,CACN,MAAOA,EACR,EACD,UAAW,CACT,MAAOA,EACR,EACD,YAAa,CACX,MAAOA,EACR,EACD,aAAc,CACZ,MAAOA,EACR,EACD,WAAY,CACV,MAAOA,EACR,EACD,QAAS,CACP,MAAOA,EACR,EACD,QAAS,CACP,MAAOA,EACR,EACD,aAAc,CACZ,MAAOA,EACR,EACD,kBAAmB,CACjB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;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","x_google_ignoreList":[3,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,83,84,85,86,87,88,89,90,91,92,93,94,95,96,97,98,99,100,101,102,103,104,105,106,107,108,109,110,111,112,113,114,115,116,117,118,119,120,121,122,123,124,125,126,127,128,129,130,131,132,133,134,135,136,137,138,139,140,141,142,143,144,145,146,147,148,149,150,151,152,153,154,155,156,157,158,159,160,161,162,163,164,165,166,167,168,169,170,171,172,173,174,175,176,177,178,179,180,181,182,183,184,185,186,187,188,189,190,191,192,193,194,195,196,197,198,199,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,228]} \ No newline at end of file diff --git a/lib/platform-bible-react/dist/index.d.ts b/lib/platform-bible-react/dist/index.d.ts index 79c9164391..f5e927d309 100644 --- a/lib/platform-bible-react/dist/index.d.ts +++ b/lib/platform-bible-react/dist/index.d.ts @@ -436,7 +436,7 @@ export type SelectedSettingsSidebarItem = { label: string; projectId?: string; }; -export type ProjectOptions = { +type ProjectInfo = { projectId: string; projectName: string; }; @@ -446,7 +446,7 @@ export type SettingsSidebarProps = { /** Extension labels from contribution */ extensionLabels: string[]; /** Project names and ids */ - projectOptions: ProjectOptions[]; + projectOptions: ProjectInfo[]; /** Handler for selecting a sidebar item */ handleSelectSidebarItem: (key: string, projectId?: string) => void; /** The current selected value in the sidebar */ @@ -455,19 +455,17 @@ export type SettingsSidebarProps = { extensionsSidebarGroupLabel: string; /** Label for the group of projects settings */ projectsSidebarGroupLabel: string; - /** Placeholder for the button */ - buttonPlaceholder: string; + /** Placeholder text for the button */ + buttonPlaceholderText: string; }; -export function SettingsSidebar({ id, extensionLabels, projectOptions, handleSelectSidebarItem, selectedSidebarItem, extensionsSidebarGroupLabel, projectsSidebarGroupLabel, buttonPlaceholder, }: SettingsSidebarProps): import("react/jsx-runtime").JSX.Element; +export function SettingsSidebar({ id, extensionLabels, projectOptions, handleSelectSidebarItem, selectedSidebarItem, extensionsSidebarGroupLabel, projectsSidebarGroupLabel, buttonPlaceholderText, }: SettingsSidebarProps): import("react/jsx-runtime").JSX.Element; export type SettingsSidebarContentSearchProps = SettingsSidebarProps & React$1.PropsWithChildren & { /** Optional id for testing */ id?: string; - /** Text direction ltr or rtl */ - direction?: "ltr" | "rtl"; /** Handler to run when the value of the search bar changes */ onSearch: (searchQuery: string) => void; }; -export function SettingsSidebarContentSearch({ id, direction, extensionLabels, projectOptions, children, handleSelectSidebarItem, selectedSidebarItem, onSearch, extensionsSidebarGroupLabel, projectsSidebarGroupLabel, buttonPlaceholder, }: SettingsSidebarContentSearchProps): import("react/jsx-runtime").JSX.Element; +export function SettingsSidebarContentSearch({ id, extensionLabels, projectOptions, children, handleSelectSidebarItem, selectedSidebarItem, onSearch, extensionsSidebarGroupLabel, projectsSidebarGroupLabel, buttonPlaceholderText, }: SettingsSidebarContentSearchProps): import("react/jsx-runtime").JSX.Element; /** * Information (e.g., a checking error or some other type of "transient" annotation) about something * noteworthy at a specific place in an instance of the Scriptures. @@ -923,6 +921,7 @@ export type IconButtonProps = React$1.PropsWithChildren<{ * https://mui.com/material-ui/getting-started/overview/ */ export declare function IconButton({ id, label, isDisabled, tooltip, isTooltipSuppressed, adjustMarginToAlignToEdge, size, className, onClick, children, }: IconButtonProps): import("react/jsx-runtime").JSX.Element; +/** Props for the SearchBar component. */ export type SearchBarProps = { className?: string; /** @@ -1507,6 +1506,7 @@ export declare const usePromise: (promiseFactoryCallback: (() => Promise) export declare function cn(...inputs: ClassValue[]): string; export { + ProjectInfo as ProjectOptions, TabNavigationContentSearch as NavigationContentSearch, sonner, }; diff --git a/lib/platform-bible-react/dist/index.js b/lib/platform-bible-react/dist/index.js index c4f03a1502..ee9424f7b9 100644 --- a/lib/platform-bible-react/dist/index.js +++ b/lib/platform-bible-react/dist/index.js @@ -1,6 +1,6 @@ import Ks, { jsx as s, jsxs as N, Fragment as ie } from "react/jsx-runtime"; import * as M from "react"; -import T, { forwardRef as Qn, useCallback as Et, useState as ut, useRef as ge, useEffect as ae, useLayoutEffect as ta, useMemo as It } from "react"; +import E, { forwardRef as Qn, useCallback as Et, useState as ut, useRef as ge, useEffect as ae, useLayoutEffect as ta, useMemo as It } from "react"; import { History as Js, ChevronRight as Ja, Check as tr, Circle as Za, ArrowDownWideNarrow as Zs, Clock as Qs, Bookmark as tl, X as Qa, Search as el, ChevronsUpDown as nl, FilterIcon as rl, ChevronDown as er, ChevronUp as ol, ArrowLeftIcon as al, ChevronLeftIcon as il, ChevronRightIcon as sl, ArrowRightIcon as ll, CircleCheckIcon as cl, CircleXIcon as dl, CircleHelpIcon as pl, ArrowUpIcon as ul, ArrowDownIcon as wl, ArrowUpDownIcon as fl, PanelLeft as ml, ChevronLeft as hl, LoaderCircle as gl, Download as bl, Filter as vl, User as yl, Link as xl, CircleHelp as Nl } from "lucide-react"; import be, { clsx as kl } from "clsx"; import { extendTailwindMerge as El } from "tailwind-merge"; @@ -35,7 +35,7 @@ const Yl = El({ prefix: "tw-" }); function x(...t) { return Yl(kl(t)); } -const Ye = T.forwardRef( +const Ye = E.forwardRef( ({ className: t, type: e, ...n }, r) => /* @__PURE__ */ s( "input", { @@ -832,7 +832,7 @@ et(Tt, "defaultVersification", ue.English), et(Tt, "verseRangeSeparator", "-"), et(Tt, "ValidStatusType", fi); class tn extends Error { } -const fo = wt.Root, mi = wt.Trigger, sc = wt.Group, fh = wt.Portal, mh = wt.Sub, hh = wt.RadioGroup, lc = T.forwardRef(({ className: t, inset: e, children: n, ...r }, o) => /* @__PURE__ */ N( +const fo = wt.Root, mi = wt.Trigger, sc = wt.Group, fh = wt.Portal, mh = wt.Sub, hh = wt.RadioGroup, lc = E.forwardRef(({ className: t, inset: e, children: n, ...r }, o) => /* @__PURE__ */ N( wt.SubTrigger, { ref: o, @@ -849,7 +849,7 @@ const fo = wt.Root, mi = wt.Trigger, sc = wt.Group, fh = wt.Portal, mh = wt.Sub, } )); lc.displayName = wt.SubTrigger.displayName; -const cc = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( +const cc = E.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( wt.SubContent, { ref: n, @@ -861,7 +861,7 @@ const cc = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( } )); cc.displayName = wt.SubContent.displayName; -const rr = T.forwardRef(({ className: t, sideOffset: e = 4, ...n }, r) => /* @__PURE__ */ s(wt.Portal, { children: /* @__PURE__ */ s( +const rr = E.forwardRef(({ className: t, sideOffset: e = 4, ...n }, r) => /* @__PURE__ */ s(wt.Portal, { children: /* @__PURE__ */ s( wt.Content, { ref: r, @@ -875,7 +875,7 @@ const rr = T.forwardRef(({ className: t, sideOffset: e = 4, ...n }, r) => /* @__ } ) })); rr.displayName = wt.Content.displayName; -const hi = T.forwardRef(({ className: t, inset: e, ...n }, r) => /* @__PURE__ */ s( +const hi = E.forwardRef(({ className: t, inset: e, ...n }, r) => /* @__PURE__ */ s( wt.Item, { ref: r, @@ -889,7 +889,7 @@ const hi = T.forwardRef(({ className: t, inset: e, ...n }, r) => /* @__PURE__ */ } )); hi.displayName = wt.Item.displayName; -const mo = T.forwardRef(({ className: t, children: e, checked: n, ...r }, o) => /* @__PURE__ */ N( +const mo = E.forwardRef(({ className: t, children: e, checked: n, ...r }, o) => /* @__PURE__ */ N( wt.CheckboxItem, { ref: o, @@ -906,7 +906,7 @@ const mo = T.forwardRef(({ className: t, children: e, checked: n, ...r }, o) => } )); mo.displayName = wt.CheckboxItem.displayName; -const gi = T.forwardRef(({ className: t, children: e, ...n }, r) => /* @__PURE__ */ N( +const gi = E.forwardRef(({ className: t, children: e, ...n }, r) => /* @__PURE__ */ N( wt.RadioItem, { ref: r, @@ -922,7 +922,7 @@ const gi = T.forwardRef(({ className: t, children: e, ...n }, r) => /* @__PURE__ } )); gi.displayName = wt.RadioItem.displayName; -const Sn = T.forwardRef(({ className: t, inset: e, ...n }, r) => /* @__PURE__ */ s( +const Sn = E.forwardRef(({ className: t, inset: e, ...n }, r) => /* @__PURE__ */ s( wt.Label, { ref: r, @@ -931,7 +931,7 @@ const Sn = T.forwardRef(({ className: t, inset: e, ...n }, r) => /* @__PURE__ */ } )); Sn.displayName = wt.Label.displayName; -const or = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( +const or = E.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( wt.Separator, { ref: n, @@ -1095,7 +1095,7 @@ function gh({ scrRef: t, handleSubmit: e }) { ot.bookNumberToId(t.bookNum) ), [i, l] = ut(t.chapterNum ?? 0), [c, d] = ut( ot.bookNumberToId(t.bookNum) - ), [p, f] = ut(!1), [w, g] = ut(p), v = ge(void 0), m = ge(void 0), h = ge(void 0), E = Et( + ), [p, f] = ut(!1), [w, g] = ut(p), v = ge(void 0), m = ge(void 0), h = ge(void 0), S = Et( (k) => gc(k).filter((B) => { const D = ot.bookIdToEnglishName(B).toLowerCase(), J = n.replace(/[^a-zA-Z]/g, "").toLowerCase(); return D.includes(J) || // Match book name @@ -1104,7 +1104,7 @@ function gh({ scrRef: t, handleSubmit: e }) { [n] ), _ = (k) => { r(k); - }, C = ge(!1), S = Et((k) => { + }, C = ge(!1), T = Et((k) => { if (C.current) { C.current = !1; return; @@ -1193,7 +1193,7 @@ function gh({ scrRef: t, handleSubmit: e }) { return () => { clearTimeout(k); }; - }, [w]), /* @__PURE__ */ s("div", { className: "pr-twp tw-flex", children: /* @__PURE__ */ N(fo, { modal: !1, open: p, onOpenChange: S, children: [ + }, [w]), /* @__PURE__ */ s("div", { className: "pr-twp tw-flex", children: /* @__PURE__ */ N(fo, { modal: !1, open: p, onOpenChange: T, children: [ /* @__PURE__ */ s(mi, { asChild: !0, children: /* @__PURE__ */ s( Wl, { @@ -1229,9 +1229,9 @@ function gh({ scrRef: t, handleSubmit: e }) { } ), ra.map( - (k, B) => E(k).length > 0 && /* @__PURE__ */ N("div", { children: [ + (k, B) => S(k).length > 0 && /* @__PURE__ */ N("div", { children: [ /* @__PURE__ */ s(Sn, { className: "tw-font-semibold tw-text-foreground/80", children: fc[k] }), - E(k).map((D) => /* @__PURE__ */ s("div", { children: /* @__PURE__ */ s( + S(k).map((D) => /* @__PURE__ */ s("div", { children: /* @__PURE__ */ s( pc, { bookId: D, @@ -1289,15 +1289,15 @@ const xc = Xe( size: "default" } } -), gt = T.forwardRef( +), gt = E.forwardRef( ({ className: t, variant: e, size: n, asChild: r = !1, ...o }, a) => /* @__PURE__ */ s(r ? He : "button", { className: x(xc({ variant: e, size: n, className: t })), ref: a, ...o }) ); gt.displayName = "Button"; const Nc = Xe( "tw-text-sm tw-font-medium tw-leading-none peer-disabled:tw-cursor-not-allowed peer-disabled:tw-opacity-70" -), Xt = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s(ti.Root, { ref: n, className: x("pr-twp", Nc(), t), ...e })); +), Xt = E.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s(ti.Root, { ref: n, className: x("pr-twp", Nc(), t), ...e })); Xt.displayName = ti.Root.displayName; -const bi = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( +const bi = E.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( mn.Root, { className: x("pr-twp tw-grid tw-gap-2", t), @@ -1306,7 +1306,7 @@ const bi = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( } )); bi.displayName = mn.Root.displayName; -const Wr = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( +const Wr = E.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( mn.Item, { ref: n, @@ -1319,7 +1319,7 @@ const Wr = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( } )); Wr.displayName = mn.Item.displayName; -const kc = hn.Root, Ec = hn.Trigger, vi = T.forwardRef(({ className: t, align: e = "center", sideOffset: n = 4, ...r }, o) => /* @__PURE__ */ s(hn.Portal, { children: /* @__PURE__ */ s( +const kc = hn.Root, Ec = hn.Trigger, vi = E.forwardRef(({ className: t, align: e = "center", sideOffset: n = 4, ...r }, o) => /* @__PURE__ */ s(hn.Portal, { children: /* @__PURE__ */ s( hn.Content, { ref: o, @@ -1333,7 +1333,7 @@ const kc = hn.Root, Ec = hn.Trigger, vi = T.forwardRef(({ className: t, align: e } ) })); vi.displayName = hn.Content.displayName; -const Sc = vt.Portal, yi = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( +const Sc = vt.Portal, yi = E.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( vt.Overlay, { ref: n, @@ -1345,7 +1345,7 @@ const Sc = vt.Portal, yi = T.forwardRef(({ className: t, ...e }, n) => /* @__PUR } )); yi.displayName = vt.Overlay.displayName; -const Tc = T.forwardRef(({ className: t, children: e, ...n }, r) => /* @__PURE__ */ N(Sc, { children: [ +const Tc = E.forwardRef(({ className: t, children: e, ...n }, r) => /* @__PURE__ */ N(Sc, { children: [ /* @__PURE__ */ s(yi, {}), /* @__PURE__ */ N( vt.Content, @@ -1367,7 +1367,7 @@ const Tc = T.forwardRef(({ className: t, children: e, ...n }, r) => /* @__PURE__ ) ] })); Tc.displayName = vt.Content.displayName; -const Cc = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( +const Cc = E.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( vt.Title, { ref: n, @@ -1376,7 +1376,7 @@ const Cc = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( } )); Cc.displayName = vt.Title.displayName; -const Oc = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( +const Oc = E.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( vt.Description, { ref: n, @@ -1385,7 +1385,7 @@ const Oc = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( } )); Oc.displayName = vt.Description.displayName; -const xi = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( +const xi = E.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( Rt, { ref: n, @@ -1397,7 +1397,7 @@ const xi = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( } )); xi.displayName = Rt.displayName; -const Ni = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ N("div", { className: "tw-flex tw-items-center tw-border-b tw-px-3", children: [ +const Ni = E.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ N("div", { className: "tw-flex tw-items-center tw-border-b tw-px-3", children: [ /* @__PURE__ */ s(el, { className: "tw-me-2 tw-h-4 tw-w-4 tw-shrink-0 tw-opacity-50" }), /* @__PURE__ */ s( Rt.Input, @@ -1412,7 +1412,7 @@ const Ni = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ N("div", ) ] })); Ni.displayName = Rt.Input.displayName; -const ki = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( +const ki = E.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( Rt.List, { ref: n, @@ -1421,9 +1421,9 @@ const ki = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( } )); ki.displayName = Rt.List.displayName; -const Ei = T.forwardRef((t, e) => /* @__PURE__ */ s(Rt.Empty, { ref: e, className: "tw-py-6 tw-text-center tw-text-sm", ...t })); +const Ei = E.forwardRef((t, e) => /* @__PURE__ */ s(Rt.Empty, { ref: e, className: "tw-py-6 tw-text-center tw-text-sm", ...t })); Ei.displayName = Rt.Empty.displayName; -const Rc = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( +const Rc = E.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( Rt.Group, { ref: n, @@ -1435,7 +1435,7 @@ const Rc = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( } )); Rc.displayName = Rt.Group.displayName; -const _c = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( +const _c = E.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( Rt.Separator, { ref: n, @@ -1444,7 +1444,7 @@ const _c = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( } )); _c.displayName = Rt.Separator.displayName; -const Si = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( +const Si = E.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( Rt.Item, { ref: n, @@ -1661,7 +1661,7 @@ function Ac({ table: t }) { ] }) ] }); } -const gn = bt.Root, Mc = bt.Group, bn = bt.Value, De = T.forwardRef(({ className: t, children: e, ...n }, r) => /* @__PURE__ */ N( +const gn = bt.Root, Mc = bt.Group, bn = bt.Value, De = E.forwardRef(({ className: t, children: e, ...n }, r) => /* @__PURE__ */ N( bt.Trigger, { ref: r, @@ -1677,7 +1677,7 @@ const gn = bt.Root, Mc = bt.Group, bn = bt.Value, De = T.forwardRef(({ className } )); De.displayName = bt.Trigger.displayName; -const Ti = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( +const Ti = E.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( bt.ScrollUpButton, { ref: n, @@ -1687,7 +1687,7 @@ const Ti = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( } )); Ti.displayName = bt.ScrollUpButton.displayName; -const Ci = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( +const Ci = E.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( bt.ScrollDownButton, { ref: n, @@ -1697,7 +1697,7 @@ const Ci = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( } )); Ci.displayName = bt.ScrollDownButton.displayName; -const Be = T.forwardRef(({ className: t, children: e, position: n = "popper", ...r }, o) => /* @__PURE__ */ s(bt.Portal, { children: /* @__PURE__ */ N( +const Be = E.forwardRef(({ className: t, children: e, position: n = "popper", ...r }, o) => /* @__PURE__ */ s(bt.Portal, { children: /* @__PURE__ */ N( bt.Content, { ref: o, @@ -1725,7 +1725,7 @@ const Be = T.forwardRef(({ className: t, children: e, position: n = "popper", .. } ) })); Be.displayName = bt.Content.displayName; -const Dc = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( +const Dc = E.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( bt.Label, { ref: n, @@ -1734,7 +1734,7 @@ const Dc = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( } )); Dc.displayName = bt.Label.displayName; -const Gt = T.forwardRef(({ className: t, children: e, ...n }, r) => /* @__PURE__ */ N( +const Gt = E.forwardRef(({ className: t, children: e, ...n }, r) => /* @__PURE__ */ N( bt.Item, { ref: r, @@ -1750,7 +1750,7 @@ const Gt = T.forwardRef(({ className: t, children: e, ...n }, r) => /* @__PURE__ } )); Gt.displayName = bt.Item.displayName; -const Bc = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( +const Bc = E.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( bt.Separator, { ref: n, @@ -1850,7 +1850,7 @@ function jc({ table: t }) { ] }) ] }) }); } -const ar = T.forwardRef(({ className: t, stickyHeader: e, ...n }, r) => /* @__PURE__ */ s("div", { className: x("pr-twp tw-relative tw-w-full", { "tw-overflow-auto": !e }), children: /* @__PURE__ */ s( +const ar = E.forwardRef(({ className: t, stickyHeader: e, ...n }, r) => /* @__PURE__ */ s("div", { className: x("pr-twp tw-relative tw-w-full", { "tw-overflow-auto": !e }), children: /* @__PURE__ */ s( "table", { ref: r, @@ -1859,7 +1859,7 @@ const ar = T.forwardRef(({ className: t, stickyHeader: e, ...n }, r) => /* @__PU } ) })); ar.displayName = "Table"; -const ir = T.forwardRef(({ className: t, stickyHeader: e, ...n }, r) => /* @__PURE__ */ s( +const ir = E.forwardRef(({ className: t, stickyHeader: e, ...n }, r) => /* @__PURE__ */ s( "thead", { ref: r, @@ -1872,9 +1872,9 @@ const ir = T.forwardRef(({ className: t, stickyHeader: e, ...n }, r) => /* @__PU } )); ir.displayName = "TableHeader"; -const sr = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s("tbody", { ref: n, className: x("[&_tr:last-child]:tw-border-0", t), ...e })); +const sr = E.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s("tbody", { ref: n, className: x("[&_tr:last-child]:tw-border-0", t), ...e })); sr.displayName = "TableBody"; -const Vc = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( +const Vc = E.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( "tfoot", { ref: n, @@ -1883,7 +1883,7 @@ const Vc = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( } )); Vc.displayName = "TableFooter"; -const oe = T.forwardRef( +const oe = E.forwardRef( ({ className: t, ...e }, n) => /* @__PURE__ */ s( "tr", { @@ -1897,7 +1897,7 @@ const oe = T.forwardRef( ) ); oe.displayName = "TableRow"; -const vn = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( +const vn = E.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( "th", { ref: n, @@ -1909,7 +1909,7 @@ const vn = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( } )); vn.displayName = "TableHead"; -const je = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( +const je = E.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( "td", { ref: n, @@ -1918,7 +1918,7 @@ const je = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( } )); je.displayName = "TableCell"; -const zc = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( +const zc = E.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( "caption", { ref: n, @@ -1959,15 +1959,15 @@ function Lc({ return /* @__PURE__ */ N("div", { className: "pr-twp", children: [ o && /* @__PURE__ */ s(Ac, { table: m }), /* @__PURE__ */ N(ar, { stickyHeader: a, children: [ - /* @__PURE__ */ s(ir, { stickyHeader: a, children: m.getHeaderGroups().map((E) => /* @__PURE__ */ s(oe, { children: E.headers.map((_) => /* @__PURE__ */ s(vn, { children: _.isPlaceholder ? void 0 : dn(_.column.columnDef.header, _.getContext()) }, _.id)) }, E.id)) }), - /* @__PURE__ */ s(sr, { children: (h = m.getRowModel().rows) != null && h.length ? m.getRowModel().rows.map((E) => /* @__PURE__ */ s( + /* @__PURE__ */ s(ir, { stickyHeader: a, children: m.getHeaderGroups().map((S) => /* @__PURE__ */ s(oe, { children: S.headers.map((_) => /* @__PURE__ */ s(vn, { children: _.isPlaceholder ? void 0 : dn(_.column.columnDef.header, _.getContext()) }, _.id)) }, S.id)) }), + /* @__PURE__ */ s(sr, { children: (h = m.getRowModel().rows) != null && h.length ? m.getRowModel().rows.map((S) => /* @__PURE__ */ s( oe, { - onClick: () => i(E, m), - "data-state": E.getIsSelected() && "selected", - children: E.getVisibleCells().map((_) => /* @__PURE__ */ s(je, { children: dn(_.column.columnDef.cell, _.getContext()) }, _.id)) + onClick: () => i(S, m), + "data-state": S.getIsSelected() && "selected", + children: S.getVisibleCells().map((_) => /* @__PURE__ */ s(je, { children: dn(_.column.columnDef.cell, _.getContext()) }, _.id)) }, - E.id + S.id )) : /* @__PURE__ */ s(oe, { children: /* @__PURE__ */ s(je, { colSpan: t.length, className: "tw-h-24 tw-text-center", children: "No results." }) }) }) ] }), n && /* @__PURE__ */ N("div", { className: "tw-flex tw-items-center tw-justify-end tw-space-x-2 tw-py-4", children: [ @@ -2026,7 +2026,7 @@ function Fc({ )) }) ] }); } -const ho = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( +const ho = E.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( Xr.Root, { ref: n, @@ -2071,7 +2071,7 @@ const Uc = (t) => t.split(/(?:\r?\n|\r)|(?=(?:\\(?:v|c|id)))/g), oa = (t) => { size: "default" } } -), Xc = T.forwardRef(({ className: t, variant: e, size: n, ...r }, o) => /* @__PURE__ */ s( +), Xc = E.forwardRef(({ className: t, variant: e, size: n, ...r }, o) => /* @__PURE__ */ s( oi.Root, { ref: o, @@ -2080,10 +2080,10 @@ const Uc = (t) => t.split(/(?:\r?\n|\r)|(?=(?:\\(?:v|c|id)))/g), oa = (t) => { } )); Xc.displayName = oi.Root.displayName; -const Ri = T.createContext({ +const Ri = E.createContext({ size: "default", variant: "default" -}), _i = T.forwardRef(({ className: t, variant: e, size: n, children: r, ...o }, a) => /* @__PURE__ */ s( +}), _i = E.forwardRef(({ className: t, variant: e, size: n, children: r, ...o }, a) => /* @__PURE__ */ s( nr.Root, { ref: a, @@ -2099,8 +2099,8 @@ const Ri = T.createContext({ } )); _i.displayName = nr.Root.displayName; -const Un = T.forwardRef(({ className: t, children: e, variant: n, size: r, ...o }, a) => { - const i = T.useContext(Ri); +const Un = E.forwardRef(({ className: t, children: e, variant: n, size: r, ...o }, a) => { + const i = E.useContext(Ri); return /* @__PURE__ */ s( nr.Item, { @@ -2268,17 +2268,17 @@ function Eh({ onScopeChange: d, columns: p }) { - const f = Jt(n, "%webView_inventory_all%"), w = Jt(n, "%webView_inventory_approved%"), g = Jt(n, "%webView_inventory_unapproved%"), v = Jt(n, "%webView_inventory_unknown%"), m = Jt(n, "%webView_inventory_scope_currentBook%"), h = Jt(n, "%webView_inventory_scope_chapter%"), E = Jt(n, "%webView_inventory_scope_verse%"), _ = Jt(n, "%webView_inventory_filter_text%"), C = Jt( + const f = Jt(n, "%webView_inventory_all%"), w = Jt(n, "%webView_inventory_approved%"), g = Jt(n, "%webView_inventory_unapproved%"), v = Jt(n, "%webView_inventory_unknown%"), m = Jt(n, "%webView_inventory_scope_currentBook%"), h = Jt(n, "%webView_inventory_scope_chapter%"), S = Jt(n, "%webView_inventory_scope_verse%"), _ = Jt(n, "%webView_inventory_filter_text%"), C = Jt( n, "%webView_inventory_show_additional_items%" - ), [S, b] = ut(!1), [I, z] = ut("all"), [H, O] = ut(""), [$, k] = ut([]), B = It(() => l ? r instanceof RegExp ? qc( + ), [T, b] = ut(!1), [I, z] = ut("all"), [H, O] = ut(""), [$, k] = ut([]), B = It(() => l ? r instanceof RegExp ? qc( l, t, a, i, r ) : r(l, t, a, i) : [], [l, r, t, a, i]), D = It(() => { - if (S) + if (T) return B; const y = []; return B.forEach((R) => { @@ -2292,9 +2292,9 @@ function Eh({ status: R.status }); }), y; - }, [S, B]), J = It(() => Wc(D, I, H), [D, I, H]), q = It(() => { + }, [T, B]), J = It(() => Wc(D, I, H), [D, I, H]), q = It(() => { var L, F; - if (!S) + if (!T) return p; const y = (L = o == null ? void 0 : o.tableHeaders) == null ? void 0 : L.length; if (!y) @@ -2308,7 +2308,7 @@ function Eh({ ) ); return [...R, ...p]; - }, [o == null ? void 0 : o.tableHeaders, p, S]); + }, [o == null ? void 0 : o.tableHeaders, p, T]); ae(() => { k([]); }, [J]); @@ -2331,13 +2331,13 @@ function Eh({ if (D.length === 0 || $.length === 0) return []; const y = D.filter((R) => co( - S ? R.items : [R.items[0]], + T ? R.items : [R.items[0]], $ )); if (y.length > 1) throw new Error("Selected item is not unique"); return y[0].occurrences; - }, [$, S, D]); + }, [$, T, D]); return /* @__PURE__ */ N("div", { className: "pr-twp tw-flex tw-h-full tw-flex-col", children: [ /* @__PURE__ */ N("div", { className: "tw-flex tw-items-stretch", children: [ /* @__PURE__ */ N( @@ -2361,7 +2361,7 @@ function Eh({ /* @__PURE__ */ N(Be, { children: [ /* @__PURE__ */ s(Gt, { value: "book", children: m }), /* @__PURE__ */ s(Gt, { value: "chapter", children: h }), - /* @__PURE__ */ s(Gt, { value: "verse", children: E }) + /* @__PURE__ */ s(Gt, { value: "verse", children: S }) ] }) ] }), /* @__PURE__ */ s( @@ -2380,7 +2380,7 @@ function Eh({ ho, { className: "tw-m-1", - checked: S, + checked: T, onCheckedChange: (y) => { k([]), b(y); } @@ -2431,7 +2431,7 @@ function Pi({ } ); } -const $i = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( +const $i = E.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( _t.Root, { orientation: "vertical", @@ -2441,7 +2441,7 @@ const $i = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( } )); $i.displayName = _t.List.displayName; -const Ii = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( +const Ii = E.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( _t.List, { ref: n, @@ -2453,7 +2453,7 @@ const Ii = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( } )); Ii.displayName = _t.List.displayName; -const Kc = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( +const Kc = E.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( _t.Trigger, { ref: n, @@ -2463,7 +2463,7 @@ const Kc = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( t ) } -)), Ai = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( +)), Ai = E.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( _t.Content, { ref: n, @@ -2502,7 +2502,7 @@ function Sh({ ] }) ] }); } -const go = T.forwardRef(({ className: t, orientation: e = "horizontal", decorative: n = !0, ...r }, o) => /* @__PURE__ */ s( +const go = E.forwardRef(({ className: t, orientation: e = "horizontal", decorative: n = !0, ...r }, o) => /* @__PURE__ */ s( ai.Root, { ref: o, @@ -2582,7 +2582,7 @@ function aa({ className: t, ...e }) { } ); } -const nd = En.Provider, rd = En.Root, od = En.Trigger, Bi = T.forwardRef(({ className: t, sideOffset: e = 4, ...n }, r) => /* @__PURE__ */ s( +const nd = En.Provider, rd = En.Root, od = En.Trigger, Bi = E.forwardRef(({ className: t, sideOffset: e = 4, ...n }, r) => /* @__PURE__ */ s( En.Content, { ref: r, @@ -2597,22 +2597,22 @@ const nd = En.Provider, rd = En.Root, od = En.Trigger, Bi = T.forwardRef(({ clas Bi.displayName = En.Content.displayName; const $r = 768; function ad() { - const [t, e] = M.useState(void 0); - return M.useEffect(() => { + const [t, e] = E.useState(void 0); + return E.useEffect(() => { const n = window.matchMedia(`(max-width: ${$r - 1}px)`), r = () => { e(window.innerWidth < $r); }; return n.addEventListener("change", r), e(window.innerWidth < $r), () => n.removeEventListener("change", r); }, []), !!t; } -const id = "sidebar:state", sd = 60 * 60 * 24 * 7, ld = "16rem", cd = "18rem", dd = "3rem", pd = "b", ji = T.createContext(void 0); +const id = "sidebar:state", sd = 60 * 60 * 24 * 7, ld = "16rem", cd = "18rem", dd = "3rem", pd = "b", ji = E.createContext(void 0); function cr() { - const t = T.useContext(ji); + const t = E.useContext(ji); if (!t) throw new Error("useSidebar must be used within a SidebarProvider."); return t; } -const Vi = T.forwardRef( +const Vi = E.forwardRef( ({ defaultOpen: t = !0, open: e, @@ -2622,20 +2622,20 @@ const Vi = T.forwardRef( children: a, ...i }, l) => { - const c = ad(), [d, p] = T.useState(!1), [f, w] = T.useState(t), g = e ?? f, v = T.useCallback( + const c = ad(), [d, p] = E.useState(!1), [f, w] = E.useState(t), g = e ?? f, v = E.useCallback( (_) => { const C = typeof _ == "function" ? _(g) : _; n ? n(C) : w(C), document.cookie = `${id}=${C}; path=/; max-age=${sd}`; }, [n, g] - ), m = T.useCallback(() => c ? p((_) => !_) : v((_) => !_), [c, v, p]); - T.useEffect(() => { + ), m = E.useCallback(() => c ? p((_) => !_) : v((_) => !_), [c, v, p]); + E.useEffect(() => { const _ = (C) => { C.key === pd && (C.metaKey || C.ctrlKey) && (C.preventDefault(), m()); }; return window.addEventListener("keydown", _), () => window.removeEventListener("keydown", _); }, [m]); - const h = g ? "expanded" : "collapsed", E = T.useMemo( + const h = g ? "expanded" : "collapsed", S = E.useMemo( () => ({ state: h, open: g, @@ -2647,7 +2647,7 @@ const Vi = T.forwardRef( }), [h, g, v, c, d, p, m] ); - return /* @__PURE__ */ s(ji.Provider, { value: E, children: /* @__PURE__ */ s(nd, { delayDuration: 0, children: /* @__PURE__ */ s( + return /* @__PURE__ */ s(ji.Provider, { value: S, children: /* @__PURE__ */ s(nd, { delayDuration: 0, children: /* @__PURE__ */ s( "div", { style: ( @@ -2671,7 +2671,7 @@ const Vi = T.forwardRef( } ); Vi.displayName = "SidebarProvider"; -const zi = T.forwardRef( +const zi = E.forwardRef( ({ side: t = "left", variant: e = "sidebar", @@ -2756,7 +2756,7 @@ const zi = T.forwardRef( } ); zi.displayName = "Sidebar"; -const ud = T.forwardRef(({ className: t, onClick: e, ...n }, r) => { +const ud = E.forwardRef(({ className: t, onClick: e, ...n }, r) => { const { toggleSidebar: o } = cr(); return /* @__PURE__ */ N( gt, @@ -2778,7 +2778,7 @@ const ud = T.forwardRef(({ className: t, onClick: e, ...n }, r) => { ); }); ud.displayName = "SidebarTrigger"; -const wd = T.forwardRef( +const wd = E.forwardRef( ({ className: t, ...e }, n) => { const { toggleSidebar: r } = cr(); return /* @__PURE__ */ s( @@ -2806,7 +2806,7 @@ const wd = T.forwardRef( } ); wd.displayName = "SidebarRail"; -const Li = T.forwardRef( +const Li = E.forwardRef( ({ className: t, ...e }, n) => /* @__PURE__ */ s( "main", { @@ -2822,7 +2822,7 @@ const Li = T.forwardRef( ) ); Li.displayName = "SidebarInset"; -const fd = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( +const fd = E.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( Ye, { ref: n, @@ -2835,7 +2835,7 @@ const fd = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( } )); fd.displayName = "SidebarInput"; -const md = T.forwardRef( +const md = E.forwardRef( ({ className: t, ...e }, n) => /* @__PURE__ */ s( "div", { @@ -2847,7 +2847,7 @@ const md = T.forwardRef( ) ); md.displayName = "SidebarHeader"; -const hd = T.forwardRef( +const hd = E.forwardRef( ({ className: t, ...e }, n) => /* @__PURE__ */ s( "div", { @@ -2859,7 +2859,7 @@ const hd = T.forwardRef( ) ); hd.displayName = "SidebarFooter"; -const gd = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( +const gd = E.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( go, { ref: n, @@ -2869,7 +2869,7 @@ const gd = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( } )); gd.displayName = "SidebarSeparator"; -const Fi = T.forwardRef( +const Fi = E.forwardRef( ({ className: t, ...e }, n) => /* @__PURE__ */ s( "div", { @@ -2884,7 +2884,7 @@ const Fi = T.forwardRef( ) ); Fi.displayName = "SidebarContent"; -const Kr = T.forwardRef( +const Kr = E.forwardRef( ({ className: t, ...e }, n) => /* @__PURE__ */ s( "div", { @@ -2896,7 +2896,7 @@ const Kr = T.forwardRef( ) ); Kr.displayName = "SidebarGroup"; -const Jr = T.forwardRef(({ className: t, asChild: e = !1, ...n }, r) => /* @__PURE__ */ s( +const Jr = E.forwardRef(({ className: t, asChild: e = !1, ...n }, r) => /* @__PURE__ */ s( e ? He : "div", { ref: r, @@ -2910,7 +2910,7 @@ const Jr = T.forwardRef(({ className: t, asChild: e = !1, ...n }, r) => /* @__PU } )); Jr.displayName = "SidebarGroupLabel"; -const bd = T.forwardRef(({ className: t, asChild: e = !1, ...n }, r) => /* @__PURE__ */ s( +const bd = E.forwardRef(({ className: t, asChild: e = !1, ...n }, r) => /* @__PURE__ */ s( e ? He : "button", { ref: r, @@ -2926,7 +2926,7 @@ const bd = T.forwardRef(({ className: t, asChild: e = !1, ...n }, r) => /* @__PU } )); bd.displayName = "SidebarGroupAction"; -const Zr = T.forwardRef( +const Zr = E.forwardRef( ({ className: t, ...e }, n) => /* @__PURE__ */ s( "div", { @@ -2938,7 +2938,7 @@ const Zr = T.forwardRef( ) ); Zr.displayName = "SidebarGroupContent"; -const Ui = T.forwardRef( +const Ui = E.forwardRef( ({ className: t, ...e }, n) => /* @__PURE__ */ s( "ul", { @@ -2950,7 +2950,7 @@ const Ui = T.forwardRef( ) ); Ui.displayName = "SidebarMenu"; -const Gi = T.forwardRef( +const Gi = E.forwardRef( ({ className: t, ...e }, n) => /* @__PURE__ */ s( "li", { @@ -2982,7 +2982,7 @@ const vd = Xe( size: "default" } } -), Hi = T.forwardRef( +), Hi = E.forwardRef( ({ asChild: t = !1, isActive: e = !1, @@ -3020,7 +3020,7 @@ const vd = Xe( } ); Hi.displayName = "SidebarMenuButton"; -const yd = T.forwardRef(({ className: t, asChild: e = !1, showOnHover: n = !1, ...r }, o) => /* @__PURE__ */ s( +const yd = E.forwardRef(({ className: t, asChild: e = !1, showOnHover: n = !1, ...r }, o) => /* @__PURE__ */ s( e ? He : "button", { ref: o, @@ -3040,7 +3040,7 @@ const yd = T.forwardRef(({ className: t, asChild: e = !1, showOnHover: n = !1, . } )); yd.displayName = "SidebarMenuAction"; -const xd = T.forwardRef( +const xd = E.forwardRef( ({ className: t, ...e }, n) => /* @__PURE__ */ s( "div", { @@ -3060,8 +3060,8 @@ const xd = T.forwardRef( ) ); xd.displayName = "SidebarMenuBadge"; -const Nd = T.forwardRef(({ className: t, showIcon: e = !1, ...n }, r) => { - const o = T.useMemo(() => `${Math.floor(Math.random() * 40) + 50}%`, []); +const Nd = E.forwardRef(({ className: t, showIcon: e = !1, ...n }, r) => { + const o = E.useMemo(() => `${Math.floor(Math.random() * 40) + 50}%`, []); return /* @__PURE__ */ N( "div", { @@ -3089,7 +3089,7 @@ const Nd = T.forwardRef(({ className: t, showIcon: e = !1, ...n }, r) => { ); }); Nd.displayName = "SidebarMenuSkeleton"; -const kd = T.forwardRef( +const kd = E.forwardRef( ({ className: t, ...e }, n) => /* @__PURE__ */ s( "ul", { @@ -3105,11 +3105,11 @@ const kd = T.forwardRef( ) ); kd.displayName = "SidebarMenuSub"; -const Ed = T.forwardRef( +const Ed = E.forwardRef( ({ ...t }, e) => /* @__PURE__ */ s("li", { ref: e, ...t }) ); Ed.displayName = "SidebarMenuSubItem"; -const Sd = T.forwardRef(({ asChild: t = !1, size: e = "md", isActive: n, className: r, ...o }, a) => /* @__PURE__ */ s( +const Sd = E.forwardRef(({ asChild: t = !1, size: e = "md", isActive: n, className: r, ...o }, a) => /* @__PURE__ */ s( t ? He : "a", { ref: a, @@ -3136,7 +3136,7 @@ function Td({ selectedSidebarItem: o, extensionsSidebarGroupLabel: a, projectsSidebarGroupLabel: i, - buttonPlaceholder: l + buttonPlaceholderText: l }) { const c = Et( (f, w) => { @@ -3170,7 +3170,7 @@ function Td({ "tw-rounded tw-py-2 tw-text-sm tw-text-gray-500 hover:tw-bg-white hover:tw-text-gray-900 hover:tw-shadow-sm active:tw-bg-white", { "tw-bg-white tw-text-gray-900 tw-shadow-sm": p(f) } ), - onClick: () => c(f, void 0), + onClick: () => c(f), isActive: p(f), children: /* @__PURE__ */ s("span", { className: "tw-pl-3", children: f }) } @@ -3199,49 +3199,40 @@ function Td({ } function Th({ id: t, - direction: e = "ltr", - extensionLabels: n, - projectOptions: r, - children: o, - handleSelectSidebarItem: a, - selectedSidebarItem: i, - onSearch: l, - extensionsSidebarGroupLabel: c, - projectsSidebarGroupLabel: d, - buttonPlaceholder: p + extensionLabels: e, + projectOptions: n, + children: r, + handleSelectSidebarItem: o, + selectedSidebarItem: a, + onSearch: i, + extensionsSidebarGroupLabel: l, + projectsSidebarGroupLabel: c, + buttonPlaceholderText: d }) { return /* @__PURE__ */ N("div", { className: "tw-box-border tw-flex tw-h-full tw-flex-col tw-p-3", children: [ /* @__PURE__ */ s("div", { className: "tw-box-border tw-flex tw-items-center tw-justify-center tw-py-4", children: /* @__PURE__ */ s( Pi, { className: "tw-w-9/12", - onSearch: l, + onSearch: i, placeholder: "Search app settings, extension settings, and project settings" } ) }), - /* @__PURE__ */ N( - Vi, - { - dir: e, - id: t, - className: "tw-h-full tw-flex-1 tw-gap-4 tw-overflow-auto", - children: [ - /* @__PURE__ */ s( - Td, - { - extensionLabels: n, - projectOptions: r, - handleSelectSidebarItem: a, - selectedSidebarItem: i, - extensionsSidebarGroupLabel: c, - projectsSidebarGroupLabel: d, - buttonPlaceholder: p - } - ), - /* @__PURE__ */ s(Li, { className: "tw-overflow-y-auto", children: o }) - ] - } - ) + /* @__PURE__ */ N(Vi, { id: t, className: "tw-h-full tw-flex-1 tw-gap-4 tw-overflow-auto", children: [ + /* @__PURE__ */ s( + Td, + { + extensionLabels: e, + projectOptions: n, + handleSelectSidebarItem: o, + selectedSidebarItem: a, + extensionsSidebarGroupLabel: l, + projectsSidebarGroupLabel: c, + buttonPlaceholderText: d + } + ), + /* @__PURE__ */ s(Li, { className: "tw-overflow-y-auto", children: r }) + ] }) ] }); } const ne = "scrBook", Cd = "scrRef", we = "source", Od = "details", Rd = "Scripture Reference", _d = "Scripture Book", Xi = "Type", Pd = "Details"; @@ -3332,7 +3323,7 @@ function Ch({ { id: ne, desc: !1 } ]) : w([{ id: ne, desc: !1 }]); }, [d]); - const E = ei({ + const S = ei({ data: m, columns: h, state: { @@ -3354,14 +3345,14 @@ function Ch({ }); ae(() => { if (l) { - const O = E.getSelectedRowModel().rowsById, $ = Object.keys(O); + const O = S.getSelectedRowModel().rowsById, $ = Object.keys(O); if ($.length === 1) { const k = m.find((B) => ia(B) === $[0]) || void 0; k && l(k); } } - }, [g, m, l, E]); - const _ = o ?? _d, C = a ?? Xi, S = [ + }, [g, m, l, S]); + const _ = o ?? _d, C = a ?? Xi, T = [ { label: "No Grouping", value: [] }, { label: `Group by ${_}`, value: [ne] }, { label: `Group by ${C}`, value: [we] }, @@ -3406,12 +3397,12 @@ function Ch({ }, children: [ /* @__PURE__ */ s(De, { className: "tw-mb-1 tw-mt-2", children: /* @__PURE__ */ s(bn, {}) }), - /* @__PURE__ */ s(Be, { position: "item-aligned", children: /* @__PURE__ */ s(Mc, { children: S.map((O) => /* @__PURE__ */ s(Gt, { value: JSON.stringify(O.value), children: O.label }, O.label)) }) }) + /* @__PURE__ */ s(Be, { position: "item-aligned", children: /* @__PURE__ */ s(Mc, { children: T.map((O) => /* @__PURE__ */ s(Gt, { value: JSON.stringify(O.value), children: O.label }, O.label)) }) }) ] } ), /* @__PURE__ */ N(ar, { className: "tw-relative tw-flex tw-flex-col tw-overflow-y-auto tw-p-0", children: [ - e && /* @__PURE__ */ s(ir, { children: E.getHeaderGroups().map((O) => /* @__PURE__ */ s(oe, { children: O.headers.filter(($) => $.column.columnDef.header).map(($) => ( + e && /* @__PURE__ */ s(ir, { children: S.getHeaderGroups().map((O) => /* @__PURE__ */ s(oe, { children: O.headers.filter(($) => $.column.columnDef.header).map(($) => ( /* For sticky column headers to work, we probably need to change the default definition of the shadcn Table component. See https://github.com/shadcn-ui/ui/issues/1151 */ /* @__PURE__ */ s(vn, { colSpan: $.colSpan, className: "top-0 tw-sticky", children: $.isPlaceholder ? void 0 : /* @__PURE__ */ N("div", { children: [ $.column.getCanGroup() ? /* @__PURE__ */ s( @@ -3428,7 +3419,7 @@ function Ch({ dn($.column.columnDef.header, $.getContext()) ] }) }, $.id) )) }, O.id)) }), - /* @__PURE__ */ s(sr, { children: E.getRowModel().rows.map((O, $) => /* @__PURE__ */ s( + /* @__PURE__ */ s(sr, { children: S.getRowModel().rows.map((O, $) => /* @__PURE__ */ s( oe, { "data-state": O.getIsSelected() ? "selected" : "", @@ -3678,7 +3669,7 @@ function Bd() { if (sa) return it; sa = 1; - var t = typeof Symbol == "function" && Symbol.for, e = t ? Symbol.for("react.element") : 60103, n = t ? Symbol.for("react.portal") : 60106, r = t ? Symbol.for("react.fragment") : 60107, o = t ? Symbol.for("react.strict_mode") : 60108, a = t ? Symbol.for("react.profiler") : 60114, i = t ? Symbol.for("react.provider") : 60109, l = t ? Symbol.for("react.context") : 60110, c = t ? Symbol.for("react.async_mode") : 60111, d = t ? Symbol.for("react.concurrent_mode") : 60111, p = t ? Symbol.for("react.forward_ref") : 60112, f = t ? Symbol.for("react.suspense") : 60113, w = t ? Symbol.for("react.suspense_list") : 60120, g = t ? Symbol.for("react.memo") : 60115, v = t ? Symbol.for("react.lazy") : 60116, m = t ? Symbol.for("react.block") : 60121, h = t ? Symbol.for("react.fundamental") : 60117, E = t ? Symbol.for("react.responder") : 60118, _ = t ? Symbol.for("react.scope") : 60119; + var t = typeof Symbol == "function" && Symbol.for, e = t ? Symbol.for("react.element") : 60103, n = t ? Symbol.for("react.portal") : 60106, r = t ? Symbol.for("react.fragment") : 60107, o = t ? Symbol.for("react.strict_mode") : 60108, a = t ? Symbol.for("react.profiler") : 60114, i = t ? Symbol.for("react.provider") : 60109, l = t ? Symbol.for("react.context") : 60110, c = t ? Symbol.for("react.async_mode") : 60111, d = t ? Symbol.for("react.concurrent_mode") : 60111, p = t ? Symbol.for("react.forward_ref") : 60112, f = t ? Symbol.for("react.suspense") : 60113, w = t ? Symbol.for("react.suspense_list") : 60120, g = t ? Symbol.for("react.memo") : 60115, v = t ? Symbol.for("react.lazy") : 60116, m = t ? Symbol.for("react.block") : 60121, h = t ? Symbol.for("react.fundamental") : 60117, S = t ? Symbol.for("react.responder") : 60118, _ = t ? Symbol.for("react.scope") : 60119; function C(b) { if (typeof b == "object" && b !== null) { var I = b.$$typeof; @@ -3709,12 +3700,12 @@ function Bd() { } } } - function S(b) { + function T(b) { return C(b) === d; } return it.AsyncMode = c, it.ConcurrentMode = d, it.ContextConsumer = l, it.ContextProvider = i, it.Element = e, it.ForwardRef = p, it.Fragment = r, it.Lazy = v, it.Memo = g, it.Portal = n, it.Profiler = a, it.StrictMode = o, it.Suspense = f, it.isAsyncMode = function(b) { - return S(b) || C(b) === c; - }, it.isConcurrentMode = S, it.isContextConsumer = function(b) { + return T(b) || C(b) === c; + }, it.isConcurrentMode = T, it.isContextConsumer = function(b) { return C(b) === l; }, it.isContextProvider = function(b) { return C(b) === i; @@ -3737,7 +3728,7 @@ function Bd() { }, it.isSuspense = function(b) { return C(b) === f; }, it.isValidElementType = function(b) { - return typeof b == "string" || typeof b == "function" || b === r || b === d || b === a || b === o || b === f || b === w || typeof b == "object" && b !== null && (b.$$typeof === v || b.$$typeof === g || b.$$typeof === i || b.$$typeof === l || b.$$typeof === p || b.$$typeof === h || b.$$typeof === E || b.$$typeof === _ || b.$$typeof === m); + return typeof b == "string" || typeof b == "function" || b === r || b === d || b === a || b === o || b === f || b === w || typeof b == "object" && b !== null && (b.$$typeof === v || b.$$typeof === g || b.$$typeof === i || b.$$typeof === l || b.$$typeof === p || b.$$typeof === h || b.$$typeof === S || b.$$typeof === _ || b.$$typeof === m); }, it.typeOf = C, it; } var st = {}; @@ -3752,12 +3743,12 @@ var st = {}; var la; function jd() { return la || (la = 1, process.env.NODE_ENV !== "production" && function() { - var t = typeof Symbol == "function" && Symbol.for, e = t ? Symbol.for("react.element") : 60103, n = t ? Symbol.for("react.portal") : 60106, r = t ? Symbol.for("react.fragment") : 60107, o = t ? Symbol.for("react.strict_mode") : 60108, a = t ? Symbol.for("react.profiler") : 60114, i = t ? Symbol.for("react.provider") : 60109, l = t ? Symbol.for("react.context") : 60110, c = t ? Symbol.for("react.async_mode") : 60111, d = t ? Symbol.for("react.concurrent_mode") : 60111, p = t ? Symbol.for("react.forward_ref") : 60112, f = t ? Symbol.for("react.suspense") : 60113, w = t ? Symbol.for("react.suspense_list") : 60120, g = t ? Symbol.for("react.memo") : 60115, v = t ? Symbol.for("react.lazy") : 60116, m = t ? Symbol.for("react.block") : 60121, h = t ? Symbol.for("react.fundamental") : 60117, E = t ? Symbol.for("react.responder") : 60118, _ = t ? Symbol.for("react.scope") : 60119; + var t = typeof Symbol == "function" && Symbol.for, e = t ? Symbol.for("react.element") : 60103, n = t ? Symbol.for("react.portal") : 60106, r = t ? Symbol.for("react.fragment") : 60107, o = t ? Symbol.for("react.strict_mode") : 60108, a = t ? Symbol.for("react.profiler") : 60114, i = t ? Symbol.for("react.provider") : 60109, l = t ? Symbol.for("react.context") : 60110, c = t ? Symbol.for("react.async_mode") : 60111, d = t ? Symbol.for("react.concurrent_mode") : 60111, p = t ? Symbol.for("react.forward_ref") : 60112, f = t ? Symbol.for("react.suspense") : 60113, w = t ? Symbol.for("react.suspense_list") : 60120, g = t ? Symbol.for("react.memo") : 60115, v = t ? Symbol.for("react.lazy") : 60116, m = t ? Symbol.for("react.block") : 60121, h = t ? Symbol.for("react.fundamental") : 60117, S = t ? Symbol.for("react.responder") : 60118, _ = t ? Symbol.for("react.scope") : 60119; function C(A) { return typeof A == "string" || typeof A == "function" || // Note: its typeof might be other than 'symbol' or 'number' if it's a polyfill. - A === r || A === d || A === a || A === o || A === f || A === w || typeof A == "object" && A !== null && (A.$$typeof === v || A.$$typeof === g || A.$$typeof === i || A.$$typeof === l || A.$$typeof === p || A.$$typeof === h || A.$$typeof === E || A.$$typeof === _ || A.$$typeof === m); + A === r || A === d || A === a || A === o || A === f || A === w || typeof A == "object" && A !== null && (A.$$typeof === v || A.$$typeof === g || A.$$typeof === i || A.$$typeof === l || A.$$typeof === p || A.$$typeof === h || A.$$typeof === S || A.$$typeof === _ || A.$$typeof === m); } - function S(A) { + function T(A) { if (typeof A == "object" && A !== null) { var Nt = A.$$typeof; switch (Nt) { @@ -3791,45 +3782,45 @@ function jd() { } var b = c, I = d, z = l, H = i, O = e, $ = p, k = r, B = v, D = g, J = n, q = a, U = o, tt = f, at = !1; function rt(A) { - return at || (at = !0, console.warn("The ReactIs.isAsyncMode() alias has been deprecated, and will be removed in React 17+. Update your code to use ReactIs.isConcurrentMode() instead. It has the exact same API.")), y(A) || S(A) === c; + return at || (at = !0, console.warn("The ReactIs.isAsyncMode() alias has been deprecated, and will be removed in React 17+. Update your code to use ReactIs.isConcurrentMode() instead. It has the exact same API.")), y(A) || T(A) === c; } function y(A) { - return S(A) === d; + return T(A) === d; } function R(A) { - return S(A) === l; + return T(A) === l; } function L(A) { - return S(A) === i; + return T(A) === i; } function F(A) { return typeof A == "object" && A !== null && A.$$typeof === e; } function V(A) { - return S(A) === p; + return T(A) === p; } function W(A) { - return S(A) === r; + return T(A) === r; } function X(A) { - return S(A) === v; + return T(A) === v; } function Y(A) { - return S(A) === g; + return T(A) === g; } function G(A) { - return S(A) === n; + return T(A) === n; } function K(A) { - return S(A) === a; + return T(A) === a; } function Z(A) { - return S(A) === o; + return T(A) === o; } function dt(A) { - return S(A) === f; + return T(A) === f; } - st.AsyncMode = b, st.ConcurrentMode = I, st.ContextConsumer = z, st.ContextProvider = H, st.Element = O, st.ForwardRef = $, st.Fragment = k, st.Lazy = B, st.Memo = D, st.Portal = J, st.Profiler = q, st.StrictMode = U, st.Suspense = tt, st.isAsyncMode = rt, st.isConcurrentMode = y, st.isContextConsumer = R, st.isContextProvider = L, st.isElement = F, st.isForwardRef = V, st.isFragment = W, st.isLazy = X, st.isMemo = Y, st.isPortal = G, st.isProfiler = K, st.isStrictMode = Z, st.isSuspense = dt, st.isValidElementType = C, st.typeOf = S; + st.AsyncMode = b, st.ConcurrentMode = I, st.ContextConsumer = z, st.ContextProvider = H, st.Element = O, st.ForwardRef = $, st.Fragment = k, st.Lazy = B, st.Memo = D, st.Portal = J, st.Profiler = q, st.StrictMode = U, st.Suspense = tt, st.isAsyncMode = rt, st.isConcurrentMode = y, st.isContextConsumer = R, st.isContextProvider = L, st.isElement = F, st.isForwardRef = V, st.isFragment = W, st.isLazy = X, st.isMemo = Y, st.isPortal = G, st.isProfiler = K, st.isStrictMode = Z, st.isSuspense = dt, st.isValidElementType = C, st.typeOf = T; }()), st; } var ca; @@ -3976,17 +3967,17 @@ function Ld() { return R; } var w = "<>", g = { - array: E("array"), - bigint: E("bigint"), - bool: E("boolean"), - func: E("function"), - number: E("number"), - object: E("object"), - string: E("string"), - symbol: E("symbol"), + array: S("array"), + bigint: S("bigint"), + bool: S("boolean"), + func: S("function"), + number: S("number"), + object: S("object"), + string: S("string"), + symbol: S("symbol"), any: _(), arrayOf: C, - element: S(), + element: T(), elementType: b(), instanceOf: I, node: $(), @@ -4026,7 +4017,7 @@ function Ld() { var V = F.bind(null, !1); return V.isRequired = F.bind(null, !0), V; } - function E(y) { + function S(y) { function R(L, F, V, W, X, Y) { var G = L[F], K = U(G); if (K !== y) { @@ -4061,7 +4052,7 @@ function Ld() { } return h(R); } - function S() { + function T() { function y(R, L, F, V, W) { var X = R[L]; if (!l(X)) { @@ -4382,8 +4373,8 @@ function qd() { v = Symbol.for("react.module.reference"); function m(h) { if (typeof h == "object" && h !== null) { - var E = h.$$typeof; - switch (E) { + var S = h.$$typeof; + switch (S) { case t: switch (h = h.type, h) { case n: @@ -4402,11 +4393,11 @@ function qd() { case a: return h; default: - return E; + return S; } } case e: - return E; + return S; } } } @@ -4455,10 +4446,10 @@ var ct = {}; var ga; function Kd() { return ga || (ga = 1, process.env.NODE_ENV !== "production" && function() { - var t = Symbol.for("react.element"), e = Symbol.for("react.portal"), n = Symbol.for("react.fragment"), r = Symbol.for("react.strict_mode"), o = Symbol.for("react.profiler"), a = Symbol.for("react.provider"), i = Symbol.for("react.context"), l = Symbol.for("react.server_context"), c = Symbol.for("react.forward_ref"), d = Symbol.for("react.suspense"), p = Symbol.for("react.suspense_list"), f = Symbol.for("react.memo"), w = Symbol.for("react.lazy"), g = Symbol.for("react.offscreen"), v = !1, m = !1, h = !1, E = !1, _ = !1, C; + var t = Symbol.for("react.element"), e = Symbol.for("react.portal"), n = Symbol.for("react.fragment"), r = Symbol.for("react.strict_mode"), o = Symbol.for("react.profiler"), a = Symbol.for("react.provider"), i = Symbol.for("react.context"), l = Symbol.for("react.server_context"), c = Symbol.for("react.forward_ref"), d = Symbol.for("react.suspense"), p = Symbol.for("react.suspense_list"), f = Symbol.for("react.memo"), w = Symbol.for("react.lazy"), g = Symbol.for("react.offscreen"), v = !1, m = !1, h = !1, S = !1, _ = !1, C; C = Symbol.for("react.module.reference"); - function S(j) { - return !!(typeof j == "string" || typeof j == "function" || j === n || j === o || _ || j === r || j === d || j === p || E || j === g || v || m || h || typeof j == "object" && j !== null && (j.$$typeof === w || j.$$typeof === f || j.$$typeof === a || j.$$typeof === i || j.$$typeof === c || // This needs to include all possible module reference object + function T(j) { + return !!(typeof j == "string" || typeof j == "function" || j === n || j === o || _ || j === r || j === d || j === p || S || j === g || v || m || h || typeof j == "object" && j !== null && (j.$$typeof === w || j.$$typeof === f || j.$$typeof === a || j.$$typeof === i || j.$$typeof === c || // This needs to include all possible module reference object // types supported by any Flight configuration anywhere since // we don't know which Flight build this will end up being used // with. @@ -4539,7 +4530,7 @@ function Kd() { function Nt(j) { return b(j) === p; } - ct.ContextConsumer = I, ct.ContextProvider = z, ct.Element = H, ct.ForwardRef = O, ct.Fragment = $, ct.Lazy = k, ct.Memo = B, ct.Portal = D, ct.Profiler = J, ct.StrictMode = q, ct.Suspense = U, ct.SuspenseList = tt, ct.isAsyncMode = y, ct.isConcurrentMode = R, ct.isContextConsumer = L, ct.isContextProvider = F, ct.isElement = V, ct.isForwardRef = W, ct.isFragment = X, ct.isLazy = Y, ct.isMemo = G, ct.isPortal = K, ct.isProfiler = Z, ct.isStrictMode = dt, ct.isSuspense = A, ct.isSuspenseList = Nt, ct.isValidElementType = S, ct.typeOf = b; + ct.ContextConsumer = I, ct.ContextProvider = z, ct.Element = H, ct.ForwardRef = O, ct.Fragment = $, ct.Lazy = k, ct.Memo = B, ct.Portal = D, ct.Profiler = J, ct.StrictMode = q, ct.Suspense = U, ct.SuspenseList = tt, ct.isAsyncMode = y, ct.isConcurrentMode = R, ct.isContextConsumer = L, ct.isContextProvider = F, ct.isElement = V, ct.isForwardRef = W, ct.isFragment = X, ct.isLazy = Y, ct.isMemo = G, ct.isPortal = K, ct.isProfiler = Z, ct.isStrictMode = dt, ct.isSuspense = A, ct.isSuspenseList = Nt, ct.isValidElementType = T, ct.typeOf = b; }()), ct; } process.env.NODE_ENV === "production" ? to.exports = qd() : to.exports = Kd(); @@ -5763,10 +5754,10 @@ function _u(t = {}) { ), m = f || !1; let h; process.env.NODE_ENV !== "production" && c && (h = `${c}-${Ta(d || "Root")}`); - let E = Gn; - d === "Root" || d === "root" ? E = r : d ? E = o : Cu(i) && (E = void 0); + let S = Gn; + d === "Root" || d === "root" ? S = r : d ? S = o : Cu(i) && (S = void 0); const _ = Al(i, P({ - shouldForwardProp: E, + shouldForwardProp: S, label: h }, g)), C = (b) => typeof b == "function" && b.__emotion_real !== b || he(b) ? (I) => Hn(b, P({}, I, { theme: Vn({ @@ -5774,7 +5765,7 @@ function _u(t = {}) { defaultTheme: n, themeId: e }) - })) : b, S = (b, ...I) => { + })) : b, T = (b, ...I) => { let z = C(b); const H = I ? I.map(C) : []; c && w && H.push((k) => { @@ -5814,7 +5805,7 @@ function _u(t = {}) { } return i.muiName && ($.muiName = i.muiName), $; }; - return _.withConfig && (S.withConfig = _.withConfig), S; + return _.withConfig && (T.withConfig = _.withConfig), T; }; } function Pu(t) { @@ -6188,8 +6179,8 @@ function tw(t) { function f(m) { const h = Oa(m, Fr.text.primary) >= n ? Fr.text.primary : Ra.text.primary; if (process.env.NODE_ENV !== "production") { - const E = Oa(m, h); - E < 3 && console.error([`MUI: The contrast ratio of ${E}:1 for ${h} on ${m}`, "falls below the WCAG recommended absolute minimum contrast ratio of 3:1.", "https://www.w3.org/TR/2008/REC-WCAG20-20081211/#visual-audio-contrast-contrast"].join(` + const S = Oa(m, h); + S < 3 && console.error([`MUI: The contrast ratio of ${S}:1 for ${h} on ${m}`, "falls below the WCAG recommended absolute minimum contrast ratio of 3:1.", "https://www.w3.org/TR/2008/REC-WCAG20-20081211/#visual-audio-contrast-contrast"].join(` `)); } return h; @@ -6197,13 +6188,13 @@ function tw(t) { const w = ({ color: m, name: h, - mainShade: E = 500, + mainShade: S = 500, lightShade: _ = 300, darkShade: C = 700 }) => { - if (m = P({}, m), !m.main && m[E] && (m.main = m[E]), !m.hasOwnProperty("main")) + if (m = P({}, m), !m.main && m[S] && (m.main = m[S]), !m.hasOwnProperty("main")) throw new Error(process.env.NODE_ENV !== "production" ? `MUI: The color${h ? ` (${h})` : ""} provided to augmentColor(color) is invalid. -The color object needs to have a \`main\` property or a \`${E}\` property.` : Ve(11, h ? ` (${h})` : "", E)); +The color object needs to have a \`main\` property or a \`${S}\` property.` : Ve(11, h ? ` (${h})` : "", S)); if (typeof m.main != "string") throw new Error(process.env.NODE_ENV !== "production" ? `MUI: The color${h ? ` (${h})` : ""} provided to augmentColor(color) is invalid. \`color.main\` should be a string, but \`${JSON.stringify(m.main)}\` was provided instead. @@ -6303,14 +6294,14 @@ function rw(t, e) { pxToRem: f } = n, w = kt(n, ew); process.env.NODE_ENV !== "production" && (typeof o != "number" && console.error("MUI: `fontSize` is required to be a number."), typeof d != "number" && console.error("MUI: `htmlFontSize` is required to be a number.")); - const g = o / 14, v = f || ((E) => `${E / d * g}rem`), m = (E, _, C, S, b) => P({ + const g = o / 14, v = f || ((S) => `${S / d * g}rem`), m = (S, _, C, T, b) => P({ fontFamily: r, - fontWeight: E, + fontWeight: S, fontSize: v(_), // Unitless following https://meyerweb.com/eric/thoughts/2006/02/08/unitless-line-heights/ lineHeight: C }, r === $a ? { - letterSpacing: `${nw(S / _)}em` + letterSpacing: `${nw(T / _)}em` } : {}, b, p), h = { h1: m(a, 96, 1.167, -1.5), h2: m(a, 60, 1.2, -0.5), @@ -6559,10 +6550,10 @@ const Nw = ["children", "className", "color", "component", "fontSize", "htmlColo hasSvgAsChild: v }), h = {}; p || (h.viewBox = w); - const E = kw(m); + const S = kw(m); return /* @__PURE__ */ N(Ew, P({ as: l, - className: be(E.root, a), + className: be(S.root, a), focusable: "false", color: d, "aria-hidden": f ? void 0 : !0, @@ -7067,7 +7058,7 @@ var df = function(e, n) { function pf(t) { var e, n = t.state, r = t.name, o = t.options, a = n.elements.arrow, i = n.modifiersData.popperOffsets, l = Yt(n.placement), c = Mo(l), d = [Ot, zt].indexOf(l) >= 0, p = d ? "height" : "width"; if (!(!a || !i)) { - var f = df(o.padding, n), w = Ao(a), g = c === "y" ? Ct : Ot, v = c === "y" ? Vt : zt, m = n.rects.reference[p] + n.rects.reference[c] - i[c] - n.rects.popper[p], h = i[c] - n.rects.reference[c], E = Pn(a), _ = E ? c === "y" ? E.clientHeight || 0 : E.clientWidth || 0 : 0, C = m / 2 - h / 2, S = f[g], b = _ - w[p] - f[v], I = _ / 2 - w[p] / 2 + C, z = wn(S, I, b), H = c; + var f = df(o.padding, n), w = Ao(a), g = c === "y" ? Ct : Ot, v = c === "y" ? Vt : zt, m = n.rects.reference[p] + n.rects.reference[c] - i[c] - n.rects.popper[p], h = i[c] - n.rects.reference[c], S = Pn(a), _ = S ? c === "y" ? S.clientHeight || 0 : S.clientWidth || 0 : 0, C = m / 2 - h / 2, T = f[g], b = _ - w[p] - f[v], I = _ / 2 - w[p] / 2 + C, z = wn(T, I, b), H = c; n.modifiersData[r] = (e = {}, e[H] = z, e.centerOffset = z - I, e); } } @@ -7109,11 +7100,11 @@ function Va(t) { y: m }; g = h.x, m = h.y; - var E = i.hasOwnProperty("x"), _ = i.hasOwnProperty("y"), C = Ot, S = Ct, b = window; + var S = i.hasOwnProperty("x"), _ = i.hasOwnProperty("y"), C = Ot, T = Ct, b = window; if (d) { var I = Pn(n), z = "clientHeight", H = "clientWidth"; if (I === Mt(n) && (I = le(n), te(I).position !== "static" && l === "absolute" && (z = "scrollHeight", H = "scrollWidth")), I = I, o === Ct || (o === Ot || o === zt) && a === Nn) { - S = Vt; + T = Vt; var O = f && I === b && b.visualViewport ? b.visualViewport.height : ( // $FlowFixMe[prop-missing] I[z] @@ -7140,9 +7131,9 @@ function Va(t) { }; if (g = B.x, m = B.y, c) { var D; - return Object.assign({}, k, (D = {}, D[S] = _ ? "0" : "", D[C] = E ? "0" : "", D.transform = (b.devicePixelRatio || 1) <= 1 ? "translate(" + g + "px, " + m + "px)" : "translate3d(" + g + "px, " + m + "px, 0)", D)); + return Object.assign({}, k, (D = {}, D[T] = _ ? "0" : "", D[C] = S ? "0" : "", D.transform = (b.devicePixelRatio || 1) <= 1 ? "translate(" + g + "px, " + m + "px)" : "translate3d(" + g + "px, " + m + "px, 0)", D)); } - return Object.assign({}, k, (e = {}, e[S] = _ ? m + "px" : "", e[C] = E ? g + "px" : "", e.transform = "", e)); + return Object.assign({}, k, (e = {}, e[T] = _ ? m + "px" : "", e[C] = S ? g + "px" : "", e.transform = "", e)); } function hf(t) { var e = t.state, n = t.options, r = n.gpuAcceleration, o = r === void 0 ? !0 : r, a = n.adaptive, i = a === void 0 ? !0 : a, l = n.roundOffsets, c = l === void 0 ? !0 : l, d = { @@ -7342,16 +7333,16 @@ function Cs(t) { } function kn(t, e) { e === void 0 && (e = {}); - var n = e, r = n.placement, o = r === void 0 ? t.placement : r, a = n.strategy, i = a === void 0 ? t.strategy : a, l = n.boundary, c = l === void 0 ? Hw : l, d = n.rootBoundary, p = d === void 0 ? vs : d, f = n.elementContext, w = f === void 0 ? rn : f, g = n.altBoundary, v = g === void 0 ? !1 : g, m = n.padding, h = m === void 0 ? 0 : m, E = Es(typeof h != "number" ? h : Ss(h, _n)), _ = w === rn ? Xw : rn, C = t.rects.popper, S = t.elements[v ? _ : w], b = Tf(ke(S) ? S : S.contextElement || le(t.elements.popper), c, p, i), I = Ue(t.elements.reference), z = Cs({ + var n = e, r = n.placement, o = r === void 0 ? t.placement : r, a = n.strategy, i = a === void 0 ? t.strategy : a, l = n.boundary, c = l === void 0 ? Hw : l, d = n.rootBoundary, p = d === void 0 ? vs : d, f = n.elementContext, w = f === void 0 ? rn : f, g = n.altBoundary, v = g === void 0 ? !1 : g, m = n.padding, h = m === void 0 ? 0 : m, S = Es(typeof h != "number" ? h : Ss(h, _n)), _ = w === rn ? Xw : rn, C = t.rects.popper, T = t.elements[v ? _ : w], b = Tf(ke(T) ? T : T.contextElement || le(t.elements.popper), c, p, i), I = Ue(t.elements.reference), z = Cs({ reference: I, element: C, strategy: "absolute", placement: o }), H = oo(Object.assign({}, C, z)), O = w === rn ? H : I, $ = { - top: b.top - O.top + E.top, - bottom: O.bottom - b.bottom + E.bottom, - left: b.left - O.left + E.left, - right: O.right - b.right + E.right + top: b.top - O.top + S.top, + bottom: O.bottom - b.bottom + S.bottom, + left: b.left - O.left + S.left, + right: O.right - b.right + S.right }, k = t.modifiersData.offset; if (w === rn && k) { var B = k[o]; @@ -7391,7 +7382,7 @@ function Of(t) { function Rf(t) { var e = t.state, n = t.options, r = t.name; if (!e.modifiersData[r]._skip) { - for (var o = n.mainAxis, a = o === void 0 ? !0 : o, i = n.altAxis, l = i === void 0 ? !0 : i, c = n.fallbackPlacements, d = n.padding, p = n.boundary, f = n.rootBoundary, w = n.altBoundary, g = n.flipVariations, v = g === void 0 ? !0 : g, m = n.allowedAutoPlacements, h = e.options.placement, E = Yt(h), _ = E === h, C = c || (_ || !v ? [Xn(h)] : Of(h)), S = [h].concat(C).reduce(function(V, W) { + for (var o = n.mainAxis, a = o === void 0 ? !0 : o, i = n.altAxis, l = i === void 0 ? !0 : i, c = n.fallbackPlacements, d = n.padding, p = n.boundary, f = n.rootBoundary, w = n.altBoundary, g = n.flipVariations, v = g === void 0 ? !0 : g, m = n.allowedAutoPlacements, h = e.options.placement, S = Yt(h), _ = S === h, C = c || (_ || !v ? [Xn(h)] : Of(h)), T = [h].concat(C).reduce(function(V, W) { return V.concat(Yt(W) === $o ? Cf(e, { placement: W, boundary: p, @@ -7400,8 +7391,8 @@ function Rf(t) { flipVariations: v, allowedAutoPlacements: m }) : W); - }, []), b = e.rects.reference, I = e.rects.popper, z = /* @__PURE__ */ new Map(), H = !0, O = S[0], $ = 0; $ < S.length; $++) { - var k = S[$], B = Yt(k), D = Ge(k) === Le, J = [Ct, Vt].indexOf(B) >= 0, q = J ? "width" : "height", U = kn(e, { + }, []), b = e.rects.reference, I = e.rects.popper, z = /* @__PURE__ */ new Map(), H = !0, O = T[0], $ = 0; $ < T.length; $++) { + var k = T[$], B = Yt(k), D = Ge(k) === Le, J = [Ct, Vt].indexOf(B) >= 0, q = J ? "width" : "height", U = kn(e, { placement: k, boundary: p, rootBoundary: f, @@ -7420,7 +7411,7 @@ function Rf(t) { } if (H) for (var y = v ? 3 : 1, R = function(W) { - var X = S.find(function(Y) { + var X = T.find(function(Y) { var G = z.get(Y); if (G) return G.slice(0, W).every(function(K) { @@ -7536,7 +7527,7 @@ function Vf(t) { rootBoundary: d, padding: f, altBoundary: p - }), E = Yt(e.placement), _ = Ge(e.placement), C = !_, S = Mo(E), b = jf(S), I = e.modifiersData.popperOffsets, z = e.rects.reference, H = e.rects.popper, O = typeof m == "function" ? m(Object.assign({}, e.rects, { + }), S = Yt(e.placement), _ = Ge(e.placement), C = !_, T = Mo(S), b = jf(T), I = e.modifiersData.popperOffsets, z = e.rects.reference, H = e.rects.popper, O = typeof m == "function" ? m(Object.assign({}, e.rects, { placement: e.placement })) : m, $ = typeof O == "number" ? { mainAxis: O, @@ -7550,14 +7541,14 @@ function Vf(t) { }; if (I) { if (a) { - var D, J = S === "y" ? Ct : Ot, q = S === "y" ? Vt : zt, U = S === "y" ? "height" : "width", tt = I[S], at = tt + h[J], rt = tt - h[q], y = g ? -H[U] / 2 : 0, R = _ === Le ? z[U] : H[U], L = _ === Le ? -H[U] : -z[U], F = e.elements.arrow, V = g && F ? Ao(F) : { + var D, J = T === "y" ? Ct : Ot, q = T === "y" ? Vt : zt, U = T === "y" ? "height" : "width", tt = I[T], at = tt + h[J], rt = tt - h[q], y = g ? -H[U] / 2 : 0, R = _ === Le ? z[U] : H[U], L = _ === Le ? -H[U] : -z[U], F = e.elements.arrow, V = g && F ? Ao(F) : { width: 0, height: 0 - }, W = e.modifiersData["arrow#persistent"] ? e.modifiersData["arrow#persistent"].padding : ks(), X = W[J], Y = W[q], G = wn(0, z[U], V[U]), K = C ? z[U] / 2 - y - G - X - $.mainAxis : R - G - X - $.mainAxis, Z = C ? -z[U] / 2 + y + G + Y + $.mainAxis : L + G + Y + $.mainAxis, dt = e.elements.arrow && Pn(e.elements.arrow), A = dt ? S === "y" ? dt.clientTop || 0 : dt.clientLeft || 0 : 0, Nt = (D = k == null ? void 0 : k[S]) != null ? D : 0, j = tt + K - Nt - A, xt = tt + Z - Nt, Ft = wn(g ? Jn(at, j) : at, tt, g ? ve(rt, xt) : rt); - I[S] = Ft, B[S] = Ft - tt; + }, W = e.modifiersData["arrow#persistent"] ? e.modifiersData["arrow#persistent"].padding : ks(), X = W[J], Y = W[q], G = wn(0, z[U], V[U]), K = C ? z[U] / 2 - y - G - X - $.mainAxis : R - G - X - $.mainAxis, Z = C ? -z[U] / 2 + y + G + Y + $.mainAxis : L + G + Y + $.mainAxis, dt = e.elements.arrow && Pn(e.elements.arrow), A = dt ? T === "y" ? dt.clientTop || 0 : dt.clientLeft || 0 : 0, Nt = (D = k == null ? void 0 : k[T]) != null ? D : 0, j = tt + K - Nt - A, xt = tt + Z - Nt, Ft = wn(g ? Jn(at, j) : at, tt, g ? ve(rt, xt) : rt); + I[T] = Ft, B[T] = Ft - tt; } if (l) { - var ce, St = S === "x" ? Ct : Ot, In = S === "x" ? Vt : zt, Ut = I[b], Ee = b === "y" ? "height" : "width", de = Ut + h[St], Se = Ut - h[In], Te = [Ct, Ot].indexOf(E) !== -1, Ce = (ce = k == null ? void 0 : k[b]) != null ? ce : 0, pe = Te ? de : Ut - z[Ee] - H[Ee] - Ce + $.altAxis, qe = Te ? Ut + z[Ee] + H[Ee] - Ce - $.altAxis : Se, An = g && Te ? cf(pe, Ut, qe) : wn(g ? pe : de, Ut, g ? qe : Se); + var ce, St = T === "x" ? Ct : Ot, In = T === "x" ? Vt : zt, Ut = I[b], Ee = b === "y" ? "height" : "width", de = Ut + h[St], Se = Ut - h[In], Te = [Ct, Ot].indexOf(S) !== -1, Ce = (ce = k == null ? void 0 : k[b]) != null ? ce : 0, pe = Te ? de : Ut - z[Ee] - H[Ee] - Ce + $.altAxis, qe = Te ? Ut + z[Ee] + H[Ee] - Ce - $.altAxis : Se, An = g && Te ? cf(pe, Ut, qe) : wn(g ? pe : de, Ut, g ? qe : Se); I[b] = An, B[b] = An - Ut; } e.modifiersData[r] = B; @@ -7679,15 +7670,15 @@ function qf(t) { styles: {} }, f = [], w = !1, g = { state: p, - setOptions: function(E) { - var _ = typeof E == "function" ? E(p.options) : E; + setOptions: function(S) { + var _ = typeof S == "function" ? S(p.options) : S; m(), p.options = Object.assign({}, a, p.options, _), p.scrollParents = { reference: ke(l) ? fn(l) : l.contextElement ? fn(l.contextElement) : [], popper: fn(c) }; var C = Xf(Wf([].concat(r, p.options.modifiers))); - return p.orderedModifiers = C.filter(function(S) { - return S.enabled; + return p.orderedModifiers = C.filter(function(T) { + return T.enabled; }), v(), g.update(); }, // Sync update – it will always be executed, even if not necessary. This @@ -7697,7 +7688,7 @@ function qf(t) { // prefer the async Popper#update method forceUpdate: function() { if (!w) { - var E = p.elements, _ = E.reference, C = E.popper; + var S = p.elements, _ = S.reference, C = S.popper; if (Ha(_, C)) { p.rects = { reference: Gf(_, Pn(C), p.options.strategy === "fixed"), @@ -7705,12 +7696,12 @@ function qf(t) { }, p.reset = !1, p.placement = p.options.placement, p.orderedModifiers.forEach(function($) { return p.modifiersData[$.name] = Object.assign({}, $.data); }); - for (var S = 0; S < p.orderedModifiers.length; S++) { + for (var T = 0; T < p.orderedModifiers.length; T++) { if (p.reset === !0) { - p.reset = !1, S = -1; + p.reset = !1, T = -1; continue; } - var b = p.orderedModifiers[S], I = b.fn, z = b.options, H = z === void 0 ? {} : z, O = b.name; + var b = p.orderedModifiers[T], I = b.fn, z = b.options, H = z === void 0 ? {} : z, O = b.name; typeof I == "function" && (p = I({ state: p, options: H, @@ -7739,11 +7730,11 @@ function qf(t) { }); function v() { p.orderedModifiers.forEach(function(h) { - var E = h.name, _ = h.options, C = _ === void 0 ? {} : _, S = h.effect; - if (typeof S == "function") { - var b = S({ + var S = h.name, _ = h.options, C = _ === void 0 ? {} : _, T = h.effect; + if (typeof T == "function") { + var b = T({ state: p, - name: E, + name: S, instance: g, options: C }), I = function() { @@ -7813,10 +7804,10 @@ const rm = () => xo({ TransitionProps: m // @ts-ignore internal logic // prevent from spreading to DOM, it can come from the parent component e.g. Select. - } = e, h = kt(e, Qf), E = M.useRef(null), _ = xe(E, n), C = M.useRef(null), S = xe(C, w), b = M.useRef(S); + } = e, h = kt(e, Qf), S = M.useRef(null), _ = xe(S, n), C = M.useRef(null), T = xe(C, w), b = M.useRef(T); ze(() => { - b.current = S; - }, [S]), M.useImperativeHandle(w, () => C.current, []); + b.current = T; + }, [T]), M.useImperativeHandle(w, () => C.current, []); const I = em(p, i), [z, H] = M.useState(I), [O, $] = M.useState(Zn(o)); M.useEffect(() => { C.current && C.current.forceUpdate(); @@ -7854,7 +7845,7 @@ const rm = () => xo({ } }]; c != null && (U = U.concat(c)), f && f.modifiers != null && (U = U.concat(f.modifiers)); - const tt = Jf(O, E.current, P({ + const tt = Jf(O, S.current, P({ placement: I }, f, { modifiers: U @@ -7897,11 +7888,11 @@ const rm = () => xo({ style: v, transition: m = !1, slotProps: h = {}, - slots: E = {} - } = e, _ = kt(e, tm), [C, S] = M.useState(!0), b = () => { - S(!1); + slots: S = {} + } = e, _ = kt(e, tm), [C, T] = M.useState(!0), b = () => { + T(!1); }, I = () => { - S(!0); + T(!0); }; if (!c && !p && (!m || C)) return null; @@ -7931,7 +7922,7 @@ const rm = () => xo({ popperOptions: w, popperRef: g, slotProps: h, - slots: E + slots: S }, _, { style: P({ // Prevents scroll issue, waiting for Popper.js to add this style once initiated. @@ -8099,7 +8090,7 @@ process.env.NODE_ENV !== "production" && u.oneOfType([u.string, u.shape({ exitDone: u.string, exitActive: u.string })]); -const Ps = T.createContext(null); +const Ps = E.createContext(null); var lm = function(e) { return e.scrollTop; }, cn = "unmounted", fe = "exited", me = "entering", Ae = "entered", io = "exiting", ee = /* @__PURE__ */ function(t) { @@ -8225,12 +8216,12 @@ var lm = function(e) { var l = kt(a, ["children", "in", "mountOnEnter", "unmountOnExit", "appear", "enter", "exit", "timeout", "addEndListener", "onEnter", "onEntering", "onEntered", "onExit", "onExiting", "onExited", "nodeRef"]); return ( // allows for nested Transitions - /* @__PURE__ */ T.createElement(Ps.Provider, { + /* @__PURE__ */ E.createElement(Ps.Provider, { value: null - }, typeof i == "function" ? i(o, l) : T.cloneElement(T.Children.only(i), l)) + }, typeof i == "function" ? i(o, l) : E.cloneElement(E.Children.only(i), l)) ); }, e; -}(T.Component); +}(E.Component); ee.contextType = Ps; ee.propTypes = process.env.NODE_ENV !== "production" ? { /** @@ -8466,7 +8457,7 @@ const um = { timeout: m = "auto", // eslint-disable-next-line react/prop-types TransitionComponent: h = cm - } = e, E = kt(e, pm), _ = sn(), C = M.useRef(), S = _s(), b = M.useRef(null), I = xe(b, a.ref, n), z = (q) => (U) => { + } = e, S = kt(e, pm), _ = sn(), C = M.useRef(), T = _s(), b = M.useRef(null), I = xe(b, a.ref, n), z = (q) => (U) => { if (q) { const tt = b.current; U === void 0 ? q(tt) : q(tt, U); @@ -8485,10 +8476,10 @@ const um = { mode: "enter" }); let y; - m === "auto" ? (y = S.transitions.getAutoHeightDuration(q.clientHeight), C.current = y) : y = tt, q.style.transition = [S.transitions.create("opacity", { + m === "auto" ? (y = T.transitions.getAutoHeightDuration(q.clientHeight), C.current = y) : y = tt, q.style.transition = [T.transitions.create("opacity", { duration: y, delay: at - }), S.transitions.create("transform", { + }), T.transitions.create("transform", { duration: Ur ? y : y * 0.666, delay: at, easing: rt @@ -8506,10 +8497,10 @@ const um = { mode: "exit" }); let rt; - m === "auto" ? (rt = S.transitions.getAutoHeightDuration(q.clientHeight), C.current = rt) : rt = U, q.style.transition = [S.transitions.create("opacity", { + m === "auto" ? (rt = T.transitions.getAutoHeightDuration(q.clientHeight), C.current = rt) : rt = U, q.style.transition = [T.transitions.create("opacity", { duration: rt, delay: tt - }), S.transitions.create("transform", { + }), T.transitions.create("transform", { duration: Ur ? rt : rt * 0.666, delay: Ur ? tt : tt || rt * 0.333, easing: at @@ -8529,7 +8520,7 @@ const um = { m === "auto" && _.start(C.current || 0, q), r && r(b.current, q); }, timeout: m === "auto" ? null : m - }, E, { + }, S, { children: (q, U) => /* @__PURE__ */ M.cloneElement(a, P({ style: P({ opacity: 0, @@ -8636,10 +8627,10 @@ const Wa = Vo, wm = ["anchorEl", "component", "components", "componentsProps", " open: v, placement: m, popperOptions: h, - popperRef: E, + popperRef: S, transition: _, slots: C, - slotProps: S + slotProps: T } = a, b = kt(a, wm), I = (r = C == null ? void 0 : C.root) != null ? r : c == null ? void 0 : c.Root, z = P({ anchorEl: i, container: p, @@ -8649,7 +8640,7 @@ const Wa = Vo, wm = ["anchorEl", "component", "components", "componentsProps", " open: v, placement: m, popperOptions: h, - popperRef: E, + popperRef: S, transition: _ }, b); return /* @__PURE__ */ s(fm, P({ @@ -8658,7 +8649,7 @@ const Wa = Vo, wm = ["anchorEl", "component", "components", "componentsProps", " slots: { root: I }, - slotProps: S ?? d + slotProps: T ?? d }, z, { ref: n })); @@ -8973,7 +8964,7 @@ function Fn(t, e) { }; } const As = /* @__PURE__ */ M.forwardRef(function(e, n) { - var r, o, a, i, l, c, d, p, f, w, g, v, m, h, E, _, C, S, b; + var r, o, a, i, l, c, d, p, f, w, g, v, m, h, S, _, C, T, b; const I = _o({ props: e, name: "MuiTooltip" @@ -9127,9 +9118,9 @@ const As = /* @__PURE__ */ M.forwardRef(function(e, n) { }), Cr = vm(Qe), Ko = (r = (o = Z.popper) != null ? o : O.Popper) != null ? r : ym, Jo = (a = (i = (l = Z.transition) != null ? l : O.Transition) != null ? i : A) != null ? a : Wa, Zo = (c = (d = Z.tooltip) != null ? d : O.Tooltip) != null ? c : xm, Qo = (p = (f = Z.arrow) != null ? f : O.Arrow) != null ? p : Nm, Xs = ln(Ko, P({}, G, (w = K.popper) != null ? w : $.popper, { className: be(Cr.popper, G == null ? void 0 : G.className, (g = (v = K.popper) != null ? v : $.popper) == null ? void 0 : g.className) }), Qe), Ys = ln(Jo, P({}, Nt, (m = K.transition) != null ? m : $.transition), Qe), Ws = ln(Zo, P({}, (h = K.tooltip) != null ? h : $.tooltip, { - className: be(Cr.tooltip, (E = (_ = K.tooltip) != null ? _ : $.tooltip) == null ? void 0 : E.className) + className: be(Cr.tooltip, (S = (_ = K.tooltip) != null ? _ : $.tooltip) == null ? void 0 : S.className) }), Qe), qs = ln(Qo, P({}, (C = K.arrow) != null ? C : $.arrow, { - className: be(Cr.arrow, (S = (b = K.arrow) != null ? b : $.arrow) == null ? void 0 : S.className) + className: be(Cr.arrow, (T = (b = K.arrow) != null ? b : $.arrow) == null ? void 0 : T.className) }), Qe); return /* @__PURE__ */ N(M.Fragment, { children: [/* @__PURE__ */ M.cloneElement(xt, Dt), /* @__PURE__ */ s(Ko, P({ @@ -9380,7 +9371,7 @@ function Ms(t) { focusVisibleClassName: v, id: m, children: h - } = t, E = /* @__PURE__ */ s( + } = t, S = /* @__PURE__ */ s( Bl, { sx: { lineHeight: 0.8 }, @@ -9400,7 +9391,7 @@ function Ms(t) { ] }) : h } ); - return r ? /* @__PURE__ */ s(km, { title: r, placement: "right", children: /* @__PURE__ */ s("div", { children: E }) }) : E; + return r ? /* @__PURE__ */ s(km, { title: r, placement: "right", children: /* @__PURE__ */ s("div", { children: S }) }) : S; } function Ds(t) { return Object.entries(t.groups).map(([n, r]) => ({ id: n, group: r })); @@ -9617,31 +9608,31 @@ function Pm({ }) { const [c, d] = ut(!1), [p, f] = ut(!1), w = Et(() => { c && d(!1), f(!1); - }, [c]), g = Et((S) => { - S.stopPropagation(), d((b) => { + }, [c]), g = Et((T) => { + T.stopPropagation(), d((b) => { const I = !b; - return I && S.shiftKey ? f(!0) : I || f(!1), I; + return I && T.shiftKey ? f(!0) : I || f(!1), I; }); }, []), v = Et( - (S) => (w(), r(S)), + (T) => (w(), r(T)), [r, w] ), [m, h] = ut({ top: 1, left: 1 }); ae(() => { if (c) { - const S = o == null ? void 0 : o.current; - if (S) { - const b = S.getBoundingClientRect(), I = window.scrollY, z = window.scrollX, H = b.top + I + S.clientHeight, O = b.left + z; + const T = o == null ? void 0 : o.current; + if (T) { + const b = T.getBoundingClientRect(), I = window.scrollY, z = window.scrollX, H = b.top + I + T.clientHeight, O = b.left + z; h({ top: H, left: O }); } } }, [c, o]); - const [E] = lo( + const [S] = lo( Et(async () => (t == null ? void 0 : t(!1)) ?? e, [t, e, c]), e ), [_] = lo( - Et(async () => (t == null ? void 0 : t(!0)) ?? n ?? E, [t, n, E, c]), - n ?? E - ), C = p && _ ? _ : E; + Et(async () => (t == null ? void 0 : t(!0)) ?? n ?? S, [t, n, S, c]), + n ?? S + ), C = p && _ ? _ : S; return /* @__PURE__ */ N(ie, { children: [ /* @__PURE__ */ s( li, @@ -9801,9 +9792,9 @@ const $m = Xe( variant: "default" } } -), Im = T.forwardRef(({ className: t, variant: e, ...n }, r) => /* @__PURE__ */ s("div", { ref: r, role: "alert", className: x($m({ variant: e }), t), ...n })); +), Im = E.forwardRef(({ className: t, variant: e, ...n }, r) => /* @__PURE__ */ s("div", { ref: r, role: "alert", className: x($m({ variant: e }), t), ...n })); Im.displayName = "Alert"; -const Am = T.forwardRef( +const Am = E.forwardRef( ({ className: t, ...e }, n) => /* @__PURE__ */ N( "h5", { @@ -9818,9 +9809,9 @@ const Am = T.forwardRef( ) ); Am.displayName = "AlertTitle"; -const Mm = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s("div", { ref: n, className: x("tw-text-sm [&_p]:tw-leading-relaxed", t), ...e })); +const Mm = E.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s("div", { ref: n, className: x("tw-text-sm [&_p]:tw-leading-relaxed", t), ...e })); Mm.displayName = "AlertDescription"; -const Dm = T.forwardRef( +const Dm = E.forwardRef( ({ className: t, ...e }, n) => /* @__PURE__ */ s( "div", { @@ -9834,7 +9825,7 @@ const Dm = T.forwardRef( ) ); Dm.displayName = "Card"; -const Bm = T.forwardRef( +const Bm = E.forwardRef( ({ className: t, ...e }, n) => /* @__PURE__ */ s( "div", { @@ -9845,7 +9836,7 @@ const Bm = T.forwardRef( ) ); Bm.displayName = "CardHeader"; -const jm = T.forwardRef( +const jm = E.forwardRef( ({ className: t, ...e }, n) => /* @__PURE__ */ s( "h3", { @@ -9860,13 +9851,13 @@ const jm = T.forwardRef( ) ); jm.displayName = "CardTitle"; -const Vm = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s("p", { ref: n, className: x("pr-twp tw-text-sm tw-text-muted-foreground", t), ...e })); +const Vm = E.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s("p", { ref: n, className: x("pr-twp tw-text-sm tw-text-muted-foreground", t), ...e })); Vm.displayName = "CardDescription"; -const zm = T.forwardRef( +const zm = E.forwardRef( ({ className: t, ...e }, n) => /* @__PURE__ */ s("div", { ref: n, className: x("pr-twp tw-p-6 tw-pt-0", t), ...e }) ); zm.displayName = "CardContent"; -const Lm = T.forwardRef( +const Lm = E.forwardRef( ({ className: t, ...e }, n) => /* @__PURE__ */ s( "div", { @@ -9894,7 +9885,7 @@ function Dh({ ...t }) { } ); } -const Fm = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ N( +const Fm = E.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ N( an.Root, { ref: n, @@ -9910,7 +9901,7 @@ const Fm = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ N( } )); Fm.displayName = an.Root.displayName; -const Um = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( +const Um = E.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( Yr.Root, { className: x( @@ -9930,7 +9921,7 @@ const Um = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( } )); Um.displayName = Yr.Root.displayName; -const Bh = _t.Root, Gm = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( +const Bh = _t.Root, Gm = E.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( _t.List, { ref: n, @@ -9942,7 +9933,7 @@ const Bh = _t.Root, Gm = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE_ } )); Gm.displayName = _t.List.displayName; -const Hm = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( +const Hm = E.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( _t.Trigger, { ref: n, @@ -9954,7 +9945,7 @@ const Hm = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( } )); Hm.displayName = _t.Trigger.displayName; -const Xm = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( +const Xm = E.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( _t.Content, { ref: n, @@ -13835,39 +13826,28 @@ video:where(.pr-twp,.pr-twp *) { .banded-row[data-state='selected']:hover { cursor: default; } -.papi-multi-column-menu { - background-color: rgb(222, 222, 222); - display: flex; - flex-direction: column; - padding-left: 3px; - padding-right: 3px; -} - -.papi-menu-column { - font-size: 11pt; - font-weight: 600; - padding-bottom: 2px; +.papi-menu-item { + background-color: transparent; } -.papi-menu-column ul { - padding-top: 0; +.papi-menu-icon-trailing { + margin-left: 10px; + place-content: flex-end; } -.papi-menu-column-header { - background-color: rgb(181, 181, 181); - padding-left: 24px; - margin-top: 0; - margin-bottom: 0; +.papi-menu-item img { + max-width: 24px; + max-height: 24px; } - -.papi-multi-column-menu.paratext { - background-color: rgb(76, 106, 76); - color: rgb(214, 255, 152); +.papi-menu-drawer-paper { + height: fit-content !important; + position: absolute !important; } -.papi-multi-column-menu.paratext.bright { - color: rgb(76, 106, 76); - background-color: rgb(214, 255, 152); +.papi-toolbar-children { + padding: 10px; + display: flex; + gap: 8px; } .papi-icon-button { border: 0; @@ -13895,28 +13875,39 @@ video:where(.pr-twp,.pr-twp *) { background-color: greenyellow; color: darkgreen; } -.papi-menu-item { - background-color: transparent; +.papi-multi-column-menu { + background-color: rgb(222, 222, 222); + display: flex; + flex-direction: column; + padding-left: 3px; + padding-right: 3px; } -.papi-menu-icon-trailing { - margin-left: 10px; - place-content: flex-end; +.papi-menu-column { + font-size: 11pt; + font-weight: 600; + padding-bottom: 2px; } -.papi-menu-item img { - max-width: 24px; - max-height: 24px; +.papi-menu-column ul { + padding-top: 0; } -.papi-menu-drawer-paper { - height: fit-content !important; - position: absolute !important; + +.papi-menu-column-header { + background-color: rgb(181, 181, 181); + padding-left: 24px; + margin-top: 0; + margin-bottom: 0; } -.papi-toolbar-children { - padding: 10px; - display: flex; - gap: 8px; +.papi-multi-column-menu.paratext { + background-color: rgb(76, 106, 76); + color: rgb(214, 255, 152); +} + +.papi-multi-column-menu.paratext.bright { + color: rgb(76, 106, 76); + background-color: rgb(214, 255, 152); } `, "top"); export { diff --git a/lib/platform-bible-react/dist/index.js.map b/lib/platform-bible-react/dist/index.js.map index 0a5ac9a783..09b33e438b 100644 --- a/lib/platform-bible-react/dist/index.js.map +++ b/lib/platform-bible-react/dist/index.js.map @@ -1 +1 @@ -{"version":3,"file":"index.js","sources":["../src/utils/shadcn-ui.util.ts","../src/components/shadcn-ui/input.tsx","../src/components/advanced/book-chapter-control/book-chapter-input.component.tsx","../../../node_modules/@sillsdev/scripture/dist/index.es.js","../src/components/shadcn-ui/dropdown-menu.tsx","../src/components/advanced/book-chapter-control/book-menu-item.component.tsx","../src/components/advanced/book-chapter-control/chapter-select.component.tsx","../src/components/advanced/book-chapter-control/go-to-menu-item.component.tsx","../src/components/advanced/book-chapter-control/book-chapter-control.component.tsx","../src/components/shadcn-ui/button.tsx","../src/components/shadcn-ui/label.tsx","../src/components/shadcn-ui/radio-group.tsx","../src/components/shadcn-ui/popover.tsx","../src/components/shadcn-ui/dialog.tsx","../src/components/shadcn-ui/command.tsx","../src/components/basics/combo-box.component.tsx","../src/components/basics/chapter-range-selector.component.tsx","../src/components/advanced/book-selector.component.tsx","../src/components/advanced/data-table/data-table-column-toggle.component.tsx","../src/components/shadcn-ui/select.tsx","../src/components/advanced/data-table/data-table-pagination.component.tsx","../src/components/shadcn-ui/table.tsx","../src/components/advanced/data-table/data-table.component.tsx","../src/components/advanced/inventory/occurrences-table.component.tsx","../src/components/shadcn-ui/checkbox.tsx","../src/components/advanced/inventory/inventory-utils.ts","../src/components/shadcn-ui/toggle.tsx","../src/components/shadcn-ui/toggle-group.tsx","../src/components/advanced/inventory/inventory-columns.tsx","../src/components/advanced/inventory/inventory.component.tsx","../src/components/basics/search-bar.component.tsx","../src/components/basics/tabs-vertical.tsx","../src/components/advanced/tab-navigation-content-search.component.tsx","../src/components/shadcn-ui/separator.tsx","../src/components/shadcn-ui/sheet.tsx","../src/components/shadcn-ui/skeleton.tsx","../src/components/shadcn-ui/tooltip.tsx","../src/components/hooks/use-mobile.tsx","../src/components/shadcn-ui/sidebar.tsx","../src/components/advanced/settings-components/settings-sidebar.component.tsx","../src/components/advanced/settings-components/settings-sidebar-content-search.component.tsx","../src/components/advanced/scripture-results-viewer/scripture-results-viewer.component.tsx","../src/components/advanced/scroll-group-selector.component.tsx","../src/components/advanced/settings-components/settings-list.component.tsx","../src/components/basics/checklist.component.tsx","../../../node_modules/@babel/runtime/helpers/interopRequireDefault.js","../../../node_modules/@mui/utils/chainPropTypes/chainPropTypes.js","../../../node_modules/@babel/runtime/helpers/esm/extends.js","../../../node_modules/@mui/utils/deepmerge/deepmerge.js","../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.production.min.js","../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.development.js","../../../node_modules/prop-types/node_modules/react-is/index.js","../../../node_modules/object-assign/index.js","../../../node_modules/prop-types/lib/ReactPropTypesSecret.js","../../../node_modules/prop-types/lib/has.js","../../../node_modules/prop-types/checkPropTypes.js","../../../node_modules/prop-types/factoryWithTypeCheckers.js","../../../node_modules/prop-types/factoryWithThrowingShims.js","../../../node_modules/prop-types/index.js","../../../node_modules/@mui/utils/elementAcceptingRef/elementAcceptingRef.js","../../../node_modules/@mui/utils/exactProp/exactProp.js","../../../node_modules/@mui/utils/formatMuiErrorMessage/formatMuiErrorMessage.js","../../../node_modules/react-is/cjs/react-is.production.min.js","../../../node_modules/react-is/cjs/react-is.development.js","../../../node_modules/react-is/index.js","../../../node_modules/@mui/utils/getDisplayName/getDisplayName.js","../../../node_modules/@mui/utils/HTMLElementType/HTMLElementType.js","../../../node_modules/@mui/utils/refType/refType.js","../../../node_modules/@mui/utils/capitalize/capitalize.js","../../../node_modules/@mui/utils/createChainedFunction/createChainedFunction.js","../../../node_modules/@mui/utils/debounce/debounce.js","../../../node_modules/@mui/utils/deprecatedPropType/deprecatedPropType.js","../../../node_modules/@mui/utils/isMuiElement/isMuiElement.js","../../../node_modules/@mui/utils/ownerDocument/ownerDocument.js","../../../node_modules/@mui/utils/ownerWindow/ownerWindow.js","../../../node_modules/@mui/utils/requirePropFactory/requirePropFactory.js","../../../node_modules/@mui/utils/setRef/setRef.js","../../../node_modules/@mui/utils/useEnhancedEffect/useEnhancedEffect.js","../../../node_modules/@mui/utils/useId/useId.js","../../../node_modules/@mui/utils/unsupportedProp/unsupportedProp.js","../../../node_modules/@mui/utils/useControlled/useControlled.js","../../../node_modules/@mui/utils/useEventCallback/useEventCallback.js","../../../node_modules/@mui/utils/useForkRef/useForkRef.js","../../../node_modules/@mui/utils/useLazyRef/useLazyRef.js","../../../node_modules/@mui/utils/useOnMount/useOnMount.js","../../../node_modules/@mui/utils/useTimeout/useTimeout.js","../../../node_modules/@mui/utils/useIsFocusVisible/useIsFocusVisible.js","../../../node_modules/@mui/utils/resolveProps/resolveProps.js","../../../node_modules/@mui/utils/composeClasses/composeClasses.js","../../../node_modules/@mui/utils/ClassNameGenerator/ClassNameGenerator.js","../../../node_modules/@mui/utils/generateUtilityClass/generateUtilityClass.js","../../../node_modules/@mui/utils/generateUtilityClasses/generateUtilityClasses.js","../../../node_modules/@mui/utils/clamp/clamp.js","../../../node_modules/@babel/runtime/helpers/esm/objectWithoutPropertiesLoose.js","../../../node_modules/@mui/system/esm/createTheme/createBreakpoints.js","../../../node_modules/@mui/system/esm/createTheme/shape.js","../../../node_modules/@mui/system/esm/responsivePropType.js","../../../node_modules/@mui/system/esm/merge.js","../../../node_modules/@mui/system/esm/breakpoints.js","../../../node_modules/@mui/system/esm/style.js","../../../node_modules/@mui/system/esm/memoize.js","../../../node_modules/@mui/system/esm/spacing.js","../../../node_modules/@mui/system/esm/createTheme/createSpacing.js","../../../node_modules/@mui/system/esm/compose.js","../../../node_modules/@mui/system/esm/borders.js","../../../node_modules/@mui/system/esm/cssGrid.js","../../../node_modules/@mui/system/esm/palette.js","../../../node_modules/@mui/system/esm/sizing.js","../../../node_modules/@mui/system/esm/styleFunctionSx/defaultSxConfig.js","../../../node_modules/@mui/system/esm/styleFunctionSx/styleFunctionSx.js","../../../node_modules/@mui/system/esm/createTheme/applyStyles.js","../../../node_modules/@mui/system/esm/createTheme/createTheme.js","../../../node_modules/@mui/system/esm/useThemeWithoutDefault.js","../../../node_modules/@mui/system/esm/useTheme.js","../../../node_modules/@mui/system/esm/createStyled.js","../../../node_modules/@mui/system/esm/useThemeProps/getThemeProps.js","../../../node_modules/@mui/system/esm/useThemeProps/useThemeProps.js","../../../node_modules/@mui/system/esm/colorManipulator.js","../../../node_modules/@mui/material/styles/createMixins.js","../../../node_modules/@mui/material/colors/common.js","../../../node_modules/@mui/material/colors/grey.js","../../../node_modules/@mui/material/colors/purple.js","../../../node_modules/@mui/material/colors/red.js","../../../node_modules/@mui/material/colors/orange.js","../../../node_modules/@mui/material/colors/blue.js","../../../node_modules/@mui/material/colors/lightBlue.js","../../../node_modules/@mui/material/colors/green.js","../../../node_modules/@mui/material/styles/createPalette.js","../../../node_modules/@mui/material/styles/createTypography.js","../../../node_modules/@mui/material/styles/shadows.js","../../../node_modules/@mui/material/styles/createTransitions.js","../../../node_modules/@mui/material/styles/zIndex.js","../../../node_modules/@mui/material/styles/createTheme.js","../../../node_modules/@mui/material/styles/defaultTheme.js","../../../node_modules/@mui/material/styles/identifier.js","../../../node_modules/@mui/material/styles/useThemeProps.js","../../../node_modules/@mui/material/styles/styled.js","../../../node_modules/@mui/material/SvgIcon/svgIconClasses.js","../../../node_modules/@mui/material/SvgIcon/SvgIcon.js","../../../node_modules/@mui/material/utils/createSvgIcon.js","../../../node_modules/@mui/material/utils/index.js","../../../node_modules/@mui/icons-material/utils/createSvgIcon.js","../../../node_modules/@mui/icons-material/ArrowRight.js","../../../node_modules/@mui/base/utils/isHostComponent.js","../../../node_modules/@mui/base/utils/appendOwnerState.js","../../../node_modules/@mui/base/utils/ClassNameConfigurator.js","../../../node_modules/@mui/base/utils/extractEventHandlers.js","../../../node_modules/@mui/base/utils/resolveComponentProps.js","../../../node_modules/@mui/base/utils/omitEventHandlers.js","../../../node_modules/@mui/base/utils/mergeSlotProps.js","../../../node_modules/@mui/base/utils/useSlotProps.js","../../../node_modules/@mui/base/generateUtilityClass/index.js","../../../node_modules/@mui/base/generateUtilityClasses/index.js","../../../node_modules/@mui/base/Portal/Portal.js","../../../node_modules/@popperjs/core/lib/enums.js","../../../node_modules/@popperjs/core/lib/dom-utils/getNodeName.js","../../../node_modules/@popperjs/core/lib/dom-utils/getWindow.js","../../../node_modules/@popperjs/core/lib/dom-utils/instanceOf.js","../../../node_modules/@popperjs/core/lib/modifiers/applyStyles.js","../../../node_modules/@popperjs/core/lib/utils/getBasePlacement.js","../../../node_modules/@popperjs/core/lib/utils/math.js","../../../node_modules/@popperjs/core/lib/utils/userAgent.js","../../../node_modules/@popperjs/core/lib/dom-utils/isLayoutViewport.js","../../../node_modules/@popperjs/core/lib/dom-utils/getBoundingClientRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/getLayoutRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/contains.js","../../../node_modules/@popperjs/core/lib/dom-utils/getComputedStyle.js","../../../node_modules/@popperjs/core/lib/dom-utils/isTableElement.js","../../../node_modules/@popperjs/core/lib/dom-utils/getDocumentElement.js","../../../node_modules/@popperjs/core/lib/dom-utils/getParentNode.js","../../../node_modules/@popperjs/core/lib/dom-utils/getOffsetParent.js","../../../node_modules/@popperjs/core/lib/utils/getMainAxisFromPlacement.js","../../../node_modules/@popperjs/core/lib/utils/within.js","../../../node_modules/@popperjs/core/lib/utils/getFreshSideObject.js","../../../node_modules/@popperjs/core/lib/utils/mergePaddingObject.js","../../../node_modules/@popperjs/core/lib/utils/expandToHashMap.js","../../../node_modules/@popperjs/core/lib/modifiers/arrow.js","../../../node_modules/@popperjs/core/lib/utils/getVariation.js","../../../node_modules/@popperjs/core/lib/modifiers/computeStyles.js","../../../node_modules/@popperjs/core/lib/modifiers/eventListeners.js","../../../node_modules/@popperjs/core/lib/utils/getOppositePlacement.js","../../../node_modules/@popperjs/core/lib/utils/getOppositeVariationPlacement.js","../../../node_modules/@popperjs/core/lib/dom-utils/getWindowScroll.js","../../../node_modules/@popperjs/core/lib/dom-utils/getWindowScrollBarX.js","../../../node_modules/@popperjs/core/lib/dom-utils/getViewportRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/getDocumentRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/isScrollParent.js","../../../node_modules/@popperjs/core/lib/dom-utils/getScrollParent.js","../../../node_modules/@popperjs/core/lib/dom-utils/listScrollParents.js","../../../node_modules/@popperjs/core/lib/utils/rectToClientRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/getClippingRect.js","../../../node_modules/@popperjs/core/lib/utils/computeOffsets.js","../../../node_modules/@popperjs/core/lib/utils/detectOverflow.js","../../../node_modules/@popperjs/core/lib/utils/computeAutoPlacement.js","../../../node_modules/@popperjs/core/lib/modifiers/flip.js","../../../node_modules/@popperjs/core/lib/modifiers/hide.js","../../../node_modules/@popperjs/core/lib/modifiers/offset.js","../../../node_modules/@popperjs/core/lib/modifiers/popperOffsets.js","../../../node_modules/@popperjs/core/lib/utils/getAltAxis.js","../../../node_modules/@popperjs/core/lib/modifiers/preventOverflow.js","../../../node_modules/@popperjs/core/lib/dom-utils/getHTMLElementScroll.js","../../../node_modules/@popperjs/core/lib/dom-utils/getNodeScroll.js","../../../node_modules/@popperjs/core/lib/dom-utils/getCompositeRect.js","../../../node_modules/@popperjs/core/lib/utils/orderModifiers.js","../../../node_modules/@popperjs/core/lib/utils/debounce.js","../../../node_modules/@popperjs/core/lib/utils/mergeByName.js","../../../node_modules/@popperjs/core/lib/createPopper.js","../../../node_modules/@popperjs/core/lib/popper.js","../../../node_modules/@mui/base/Popper/popperClasses.js","../../../node_modules/@mui/base/Popper/Popper.js","../../../node_modules/@mui/material/styles/useTheme.js","../../../node_modules/@babel/runtime/helpers/esm/setPrototypeOf.js","../../../node_modules/@babel/runtime/helpers/esm/inheritsLoose.js","../../../node_modules/react-transition-group/esm/config.js","../../../node_modules/react-transition-group/esm/utils/PropTypes.js","../../../node_modules/react-transition-group/esm/TransitionGroupContext.js","../../../node_modules/react-transition-group/esm/utils/reflow.js","../../../node_modules/react-transition-group/esm/Transition.js","../../../node_modules/@mui/material/transitions/utils.js","../../../node_modules/@mui/material/Grow/Grow.js","../../../node_modules/@mui/material/Popper/Popper.js","../../../node_modules/@mui/material/Tooltip/tooltipClasses.js","../../../node_modules/@mui/material/Tooltip/Tooltip.js","../src/components/mui/menu-item.component.tsx","../src/components/mui/grouped-menu-item-list.component.tsx","../src/components/mui/top-level-menu.component.tsx","../src/components/mui/grid-menu.component.tsx","../src/hooks/use-promise.hook.ts","../../../node_modules/@mui/icons-material/esm/Menu.js","../src/components/mui/hamburger-menu-button.component.tsx","../src/components/mui/icon-button.component.tsx","../src/components/basics/spinner.component.tsx","../src/components/basics/text-field.component.tsx","../src/components/mui/toolbar.component.tsx","../src/components/shadcn-ui/alert.tsx","../src/components/shadcn-ui/card.tsx","../src/components/shadcn-ui/sonner.tsx","../src/components/shadcn-ui/slider.tsx","../src/components/shadcn-ui/switch.tsx","../src/components/shadcn-ui/tabs.tsx","../src/components/advanced/extension-marketplace/buttons/install-button.component.tsx","../src/components/advanced/extension-marketplace/buttons/enable-button.component.tsx","../src/components/advanced/extension-marketplace/buttons/disable-button.component.tsx","../src/components/advanced/extension-marketplace/buttons/update-button.component.tsx","../src/components/advanced/extension-marketplace/markdown-renderer.component.tsx","../src/components/advanced/extension-marketplace/buttons/filter-button.component.tsx","../src/components/advanced/extension-marketplace/filter-dropdown.component.tsx","../src/components/advanced/extension-marketplace/no-extensions-found.component.tsx","../src/components/advanced/extension-marketplace/more-info.component.tsx","../src/components/advanced/extension-marketplace/version-history.component.tsx","../src/components/advanced/extension-marketplace/footer.component.tsx","../src/hooks/use-event.hook.ts","../src/hooks/use-event-async.hook.ts"],"sourcesContent":["import { type ClassValue, clsx } from 'clsx';\nimport { extendTailwindMerge } from 'tailwind-merge';\n\nconst twMergeCustom = extendTailwindMerge({ prefix: 'tw-' });\n\n/**\n * Tailwind and CSS class application helper function. Uses\n * [`clsx`](https://www.npmjs.com/package/clsx) to make it easy to apply classes conditionally using\n * object syntax, and uses [`tailwind-merge`](https://www.npmjs.com/package/tailwind-merge) to make\n * it easy to merge/overwrite Tailwind classes in a programmer-logic-friendly way.\n *\n * Note: `tailwind-merge` is configured to use the prefix `tw-`, so you must use the same prefix\n * with any Tailwind classes you use with this function to successfully overwrite other Tailwind\n * classes. `platform-bible-react` is configured to use `tw-` as its Tailwind prefix, so any\n * Tailwind classes you pass into `platform-bible-react` components will be compared using the `tw-`\n * prefix.\n *\n * This function was popularized by\n * [shadcn/ui](https://ui.shadcn.com/docs/installation/manual#add-a-cn-helper). See [ByteGrad's\n * explanation video](https://www.youtube.com/watch?v=re2JFITR7TI) for more information.\n *\n * @example\n *\n * ```typescript\n * const borderShouldBeBlue = true;\n * const textShouldBeRed = true;\n * const heightShouldBe20 = false;\n * const classString = cn(\n * 'tw-bg-primary tw-h-10 tw-text-primary-foreground',\n * 'tw-bg-secondary',\n * {\n * 'tw-border-blue-500': borderShouldBeBlue,\n * 'tw-text-red-500': textShouldBeRed,\n * 'tw-h-20': heightShouldBe20,\n * },\n * 'some-class',\n * );\n * ```\n *\n * The resulting `classString` is `'tw-h-10 tw-bg-secondary tw-border-blue-500 tw-text-red-500\n * some-class'`\n *\n * - Notice that `'tw-bg-secondary'`, specified later, overwrote `'tw-bg-primary'`, specified earlier,\n * because they are Tailwind classes that affect the same css property\n * - Notice that `'tw-text-red-500'`, specified later, overwrote `'tw-text-primary-foreground'`,\n * specified earlier, because they are Tailwind classes that affect the same css property\n * - Notice that `'tw-h-20'`, specified later, did not overwrite `'tw-h-10'`, specified earlier,\n * because `'tw-h-20'` is part of a conditional class object and its value evaluated to `false`;\n * therefore it was not applied\n * - Notice that `'some-class'` was applied. This function is not limited only to Tailwind classes.\n *\n *\n * @param inputs Class strings or `clsx` conditional class objects to merge. Tailwind classes\n * specified later in the arguments overwrite similar Tailwind classes specified earlier in the\n * arguments\n * @returns Class string containing all applicable classes from the arguments based on the rules\n * described above\n */\n// shadcn/ui uses this export in its boilerplate code\n// eslint-disable-next-line import/prefer-default-export\nexport function cn(...inputs: ClassValue[]) {\n return twMergeCustom(clsx(inputs));\n}\n","import React from 'react';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport interface InputProps extends React.InputHTMLAttributes {}\n\nexport const Input = React.forwardRef(\n ({ className, type, ...props }, ref) => {\n return (\n \n );\n },\n);\nInput.displayName = 'Input';\n","import { FocusEventHandler, forwardRef, KeyboardEvent, MouseEventHandler } from 'react';\nimport { History } from 'lucide-react';\nimport { Input as ShadInput } from '@/components/shadcn-ui/input';\n\nexport type BookChapterInputProps = {\n handleSearch: (searchString: string) => void;\n handleKeyDown: (event: KeyboardEvent) => void;\n handleOnClick: MouseEventHandler;\n handleSubmit: () => void;\n onFocus?: FocusEventHandler;\n value: string;\n placeholder: string;\n};\n\n// Shadcn Input sets type to \"button\"- HAVE to prop spread before setting type\nconst BookChapterInput = forwardRef(\n (\n { handleSearch, handleKeyDown, handleOnClick, handleSubmit, ...props }: BookChapterInputProps,\n ref,\n ) => {\n return (\n
    \n handleSearch(event.target.value)}\n onKeyDown={(e) => {\n if (e.key === 'Enter') {\n handleSubmit();\n }\n handleKeyDown(e);\n }}\n onClick={handleOnClick}\n ref={ref}\n />\n {\n // eslint-disable-next-line no-console\n console.log('back in history');\n }}\n />\n
    \n );\n },\n);\n\nexport default BookChapterInput;\n","var P = Object.defineProperty;\nvar R = (t, e, s) => e in t ? P(t, e, { enumerable: !0, configurable: !0, writable: !0, value: s }) : t[e] = s;\nvar n = (t, e, s) => R(t, typeof e != \"symbol\" ? e + \"\" : e, s);\nclass _ {\n constructor() {\n n(this, \"books\");\n n(this, \"firstSelectedBookNum\");\n n(this, \"lastSelectedBookNum\");\n n(this, \"count\");\n n(this, \"selectedBookNumbers\");\n n(this, \"selectedBookIds\");\n }\n}\nconst N = [\n \"GEN\",\n \"EXO\",\n \"LEV\",\n \"NUM\",\n \"DEU\",\n \"JOS\",\n \"JDG\",\n \"RUT\",\n \"1SA\",\n \"2SA\",\n // 10\n \"1KI\",\n \"2KI\",\n \"1CH\",\n \"2CH\",\n \"EZR\",\n \"NEH\",\n \"EST\",\n \"JOB\",\n \"PSA\",\n \"PRO\",\n // 20\n \"ECC\",\n \"SNG\",\n \"ISA\",\n \"JER\",\n \"LAM\",\n \"EZK\",\n \"DAN\",\n \"HOS\",\n \"JOL\",\n \"AMO\",\n // 30\n \"OBA\",\n \"JON\",\n \"MIC\",\n \"NAM\",\n \"HAB\",\n \"ZEP\",\n \"HAG\",\n \"ZEC\",\n \"MAL\",\n \"MAT\",\n // 40\n \"MRK\",\n \"LUK\",\n \"JHN\",\n \"ACT\",\n \"ROM\",\n \"1CO\",\n \"2CO\",\n \"GAL\",\n \"EPH\",\n \"PHP\",\n // 50\n \"COL\",\n \"1TH\",\n \"2TH\",\n \"1TI\",\n \"2TI\",\n \"TIT\",\n \"PHM\",\n \"HEB\",\n \"JAS\",\n \"1PE\",\n // 60\n \"2PE\",\n \"1JN\",\n \"2JN\",\n \"3JN\",\n \"JUD\",\n \"REV\",\n \"TOB\",\n \"JDT\",\n \"ESG\",\n \"WIS\",\n // 70\n \"SIR\",\n \"BAR\",\n \"LJE\",\n \"S3Y\",\n \"SUS\",\n \"BEL\",\n \"1MA\",\n \"2MA\",\n \"3MA\",\n \"4MA\",\n // 80\n \"1ES\",\n \"2ES\",\n \"MAN\",\n \"PS2\",\n \"ODA\",\n \"PSS\",\n \"JSA\",\n // actual variant text for JOS, now in LXA text\n \"JDB\",\n // actual variant text for JDG, now in LXA text\n \"TBS\",\n // actual variant text for TOB, now in LXA text\n \"SST\",\n // actual variant text for SUS, now in LXA text // 90\n \"DNT\",\n // actual variant text for DAN, now in LXA text\n \"BLT\",\n // actual variant text for BEL, now in LXA text\n \"XXA\",\n \"XXB\",\n \"XXC\",\n \"XXD\",\n \"XXE\",\n \"XXF\",\n \"XXG\",\n \"FRT\",\n // 100\n \"BAK\",\n \"OTH\",\n \"3ES\",\n // Used previously but really should be 2ES\n \"EZA\",\n // Used to be called 4ES, but not actually in any known project\n \"5EZ\",\n // Used to be called 5ES, but not actually in any known project\n \"6EZ\",\n // Used to be called 6ES, but not actually in any known project\n \"INT\",\n \"CNC\",\n \"GLO\",\n \"TDX\",\n // 110\n \"NDX\",\n \"DAG\",\n \"PS3\",\n \"2BA\",\n \"LBA\",\n \"JUB\",\n \"ENO\",\n \"1MQ\",\n \"2MQ\",\n \"3MQ\",\n // 120\n \"REP\",\n \"4BA\",\n \"LAO\"\n], B = [\n \"XXA\",\n \"XXB\",\n \"XXC\",\n \"XXD\",\n \"XXE\",\n \"XXF\",\n \"XXG\",\n \"FRT\",\n \"BAK\",\n \"OTH\",\n \"INT\",\n \"CNC\",\n \"GLO\",\n \"TDX\",\n \"NDX\"\n], O = [\n \"Genesis\",\n \"Exodus\",\n \"Leviticus\",\n \"Numbers\",\n \"Deuteronomy\",\n \"Joshua\",\n \"Judges\",\n \"Ruth\",\n \"1 Samuel\",\n \"2 Samuel\",\n \"1 Kings\",\n \"2 Kings\",\n \"1 Chronicles\",\n \"2 Chronicles\",\n \"Ezra\",\n \"Nehemiah\",\n \"Esther (Hebrew)\",\n \"Job\",\n \"Psalms\",\n \"Proverbs\",\n \"Ecclesiastes\",\n \"Song of Songs\",\n \"Isaiah\",\n \"Jeremiah\",\n \"Lamentations\",\n \"Ezekiel\",\n \"Daniel (Hebrew)\",\n \"Hosea\",\n \"Joel\",\n \"Amos\",\n \"Obadiah\",\n \"Jonah\",\n \"Micah\",\n \"Nahum\",\n \"Habakkuk\",\n \"Zephaniah\",\n \"Haggai\",\n \"Zechariah\",\n \"Malachi\",\n \"Matthew\",\n \"Mark\",\n \"Luke\",\n \"John\",\n \"Acts\",\n \"Romans\",\n \"1 Corinthians\",\n \"2 Corinthians\",\n \"Galatians\",\n \"Ephesians\",\n \"Philippians\",\n \"Colossians\",\n \"1 Thessalonians\",\n \"2 Thessalonians\",\n \"1 Timothy\",\n \"2 Timothy\",\n \"Titus\",\n \"Philemon\",\n \"Hebrews\",\n \"James\",\n \"1 Peter\",\n \"2 Peter\",\n \"1 John\",\n \"2 John\",\n \"3 John\",\n \"Jude\",\n \"Revelation\",\n \"Tobit\",\n \"Judith\",\n \"Esther Greek\",\n \"Wisdom of Solomon\",\n \"Sirach (Ecclesiasticus)\",\n \"Baruch\",\n \"Letter of Jeremiah\",\n \"Song of 3 Young Men\",\n \"Susanna\",\n \"Bel and the Dragon\",\n \"1 Maccabees\",\n \"2 Maccabees\",\n \"3 Maccabees\",\n \"4 Maccabees\",\n \"1 Esdras (Greek)\",\n \"2 Esdras (Latin)\",\n \"Prayer of Manasseh\",\n \"Psalm 151\",\n \"Odes\",\n \"Psalms of Solomon\",\n // WARNING, if you change the spelling of the *obsolete* tag be sure to update\n // IsObsolete routine\n \"Joshua A. *obsolete*\",\n \"Judges B. *obsolete*\",\n \"Tobit S. *obsolete*\",\n \"Susanna Th. *obsolete*\",\n \"Daniel Th. *obsolete*\",\n \"Bel Th. *obsolete*\",\n \"Extra A\",\n \"Extra B\",\n \"Extra C\",\n \"Extra D\",\n \"Extra E\",\n \"Extra F\",\n \"Extra G\",\n \"Front Matter\",\n \"Back Matter\",\n \"Other Matter\",\n \"3 Ezra *obsolete*\",\n \"Apocalypse of Ezra\",\n \"5 Ezra (Latin Prologue)\",\n \"6 Ezra (Latin Epilogue)\",\n \"Introduction\",\n \"Concordance \",\n \"Glossary \",\n \"Topical Index\",\n \"Names Index\",\n \"Daniel Greek\",\n \"Psalms 152-155\",\n \"2 Baruch (Apocalypse)\",\n \"Letter of Baruch\",\n \"Jubilees\",\n \"Enoch\",\n \"1 Meqabyan\",\n \"2 Meqabyan\",\n \"3 Meqabyan\",\n \"Reproof (Proverbs 25-31)\",\n \"4 Baruch (Rest of Baruch)\",\n \"Laodiceans\"\n], S = K();\nfunction g(t, e = !0) {\n return e && (t = t.toUpperCase()), t in S ? S[t] : 0;\n}\nfunction k(t) {\n return g(t) > 0;\n}\nfunction x(t) {\n const e = typeof t == \"string\" ? g(t) : t;\n return e >= 40 && e <= 66;\n}\nfunction T(t) {\n return (typeof t == \"string\" ? g(t) : t) <= 39;\n}\nfunction X(t) {\n return t <= 66;\n}\nfunction V(t) {\n const e = typeof t == \"string\" ? g(t) : t;\n return w(e) && !X(e);\n}\nfunction* L() {\n for (let t = 1; t <= N.length; t++) yield t;\n}\nconst G = 1, A = N.length;\nfunction H() {\n return [\"XXA\", \"XXB\", \"XXC\", \"XXD\", \"XXE\", \"XXF\", \"XXG\"];\n}\nfunction C(t, e = \"***\") {\n const s = t - 1;\n return s < 0 || s >= N.length ? e : N[s];\n}\nfunction I(t) {\n return t <= 0 || t > A ? \"******\" : O[t - 1];\n}\nfunction y(t) {\n return I(g(t));\n}\nfunction w(t) {\n const e = typeof t == \"number\" ? C(t) : t;\n return k(e) && !B.includes(e);\n}\nfunction q(t) {\n const e = typeof t == \"number\" ? C(t) : t;\n return k(e) && B.includes(e);\n}\nfunction U(t) {\n return O[t - 1].includes(\"*obsolete*\");\n}\nfunction K() {\n const t = {};\n for (let e = 0; e < N.length; e++)\n t[N[e]] = e + 1;\n return t;\n}\nconst m = {\n allBookIds: N,\n nonCanonicalIds: B,\n bookIdToNumber: g,\n isBookIdValid: k,\n isBookNT: x,\n isBookOT: T,\n isBookOTNT: X,\n isBookDC: V,\n allBookNumbers: L,\n firstBook: G,\n lastBook: A,\n extraBooks: H,\n bookNumberToId: C,\n bookNumberToEnglishName: I,\n bookIdToEnglishName: y,\n isCanonical: w,\n isExtraMaterial: q,\n isObsolete: U\n};\nvar l = /* @__PURE__ */ ((t) => (t[t.Unknown = 0] = \"Unknown\", t[t.Original = 1] = \"Original\", t[t.Septuagint = 2] = \"Septuagint\", t[t.Vulgate = 3] = \"Vulgate\", t[t.English = 4] = \"English\", t[t.RussianProtestant = 5] = \"RussianProtestant\", t[t.RussianOrthodox = 6] = \"RussianOrthodox\", t))(l || {});\nconst h = class h {\n // private versInfo: Versification;\n constructor(e) {\n n(this, \"name\");\n n(this, \"fullPath\");\n n(this, \"isPresent\");\n n(this, \"hasVerseSegments\");\n n(this, \"isCustomized\");\n n(this, \"baseVersification\");\n n(this, \"scriptureBooks\");\n n(this, \"_type\");\n if (e == null)\n throw new Error(\"Argument undefined\");\n typeof e == \"string\" ? (this.name = e, this._type = l[e]) : (this._type = e, this.name = l[e]);\n }\n get type() {\n return this._type;\n }\n equals(e) {\n return !e.type || !this.type ? !1 : e.type === this.type;\n }\n};\nn(h, \"Original\", new h(l.Original)), n(h, \"Septuagint\", new h(l.Septuagint)), n(h, \"Vulgate\", new h(l.Vulgate)), n(h, \"English\", new h(l.English)), n(h, \"RussianProtestant\", new h(l.RussianProtestant)), n(h, \"RussianOrthodox\", new h(l.RussianOrthodox));\nlet c = h;\nfunction E(t, e) {\n const s = e[0];\n for (let r = 1; r < e.length; r++)\n t = t.split(e[r]).join(s);\n return t.split(s);\n}\nvar D = /* @__PURE__ */ ((t) => (t[t.Valid = 0] = \"Valid\", t[t.UnknownVersification = 1] = \"UnknownVersification\", t[t.OutOfRange = 2] = \"OutOfRange\", t[t.VerseOutOfOrder = 3] = \"VerseOutOfOrder\", t[t.VerseRepeated = 4] = \"VerseRepeated\", t))(D || {});\nconst i = class i {\n constructor(e, s, r, a) {\n /** Not yet implemented. */\n n(this, \"firstChapter\");\n /** Not yet implemented. */\n n(this, \"lastChapter\");\n /** Not yet implemented. */\n n(this, \"lastVerse\");\n /** Not yet implemented. */\n n(this, \"hasSegmentsDefined\");\n /** Not yet implemented. */\n n(this, \"text\");\n /** Not yet implemented. */\n n(this, \"BBBCCCVVVS\");\n /** Not yet implemented. */\n n(this, \"longHashCode\");\n /** The versification of the reference. */\n n(this, \"versification\");\n n(this, \"rtlMark\", \"‏\");\n n(this, \"_bookNum\", 0);\n n(this, \"_chapterNum\", 0);\n n(this, \"_verseNum\", 0);\n n(this, \"_verse\");\n if (r == null && a == null)\n if (e != null && typeof e == \"string\") {\n const o = e, u = s != null && s instanceof c ? s : void 0;\n this.setEmpty(u), this.parse(o);\n } else if (e != null && typeof e == \"number\") {\n const o = s != null && s instanceof c ? s : void 0;\n this.setEmpty(o), this._verseNum = e % i.chapterDigitShifter, this._chapterNum = Math.floor(\n e % i.bookDigitShifter / i.chapterDigitShifter\n ), this._bookNum = Math.floor(e / i.bookDigitShifter);\n } else if (s == null)\n if (e != null && e instanceof i) {\n const o = e;\n this._bookNum = o.bookNum, this._chapterNum = o.chapterNum, this._verseNum = o.verseNum, this._verse = o.verse, this.versification = o.versification;\n } else {\n if (e == null) return;\n const o = e instanceof c ? e : i.defaultVersification;\n this.setEmpty(o);\n }\n else\n throw new Error(\"VerseRef constructor not supported.\");\n else if (e != null && s != null && r != null)\n if (typeof e == \"string\" && typeof s == \"string\" && typeof r == \"string\")\n this.setEmpty(a), this.updateInternal(e, s, r);\n else if (typeof e == \"number\" && typeof s == \"number\" && typeof r == \"number\")\n this._bookNum = e, this._chapterNum = s, this._verseNum = r, this.versification = a ?? i.defaultVersification;\n else\n throw new Error(\"VerseRef constructor not supported.\");\n else\n throw new Error(\"VerseRef constructor not supported.\");\n }\n /**\n * Determines if the verse string is in a valid format (does not consider versification).\n */\n static isVerseParseable(e) {\n return e.length > 0 && \"0123456789\".includes(e[0]) && !e.endsWith(this.verseRangeSeparator) && !e.endsWith(this.verseSequenceIndicator);\n }\n /**\n * Tries to parse the specified string into a verse reference.\n * @param str - The string to attempt to parse.\n * @returns success: `true` if the specified string was successfully parsed, `false` otherwise.\n * @returns verseRef: The result of the parse if successful, or empty VerseRef if it failed\n */\n static tryParse(e) {\n let s;\n try {\n return s = new i(e), { success: !0, verseRef: s };\n } catch (r) {\n if (r instanceof v)\n return s = new i(), { success: !1, verseRef: s };\n throw r;\n }\n }\n /**\n * Gets the reference as a comparable integer where the book, chapter, and verse each occupy 3\n * digits.\n * @param bookNum - Book number (this is 1-based, not an index).\n * @param chapterNum - Chapter number.\n * @param verseNum - Verse number.\n * @returns The reference as a comparable integer where the book, chapter, and verse each occupy 3\n * digits.\n */\n static getBBBCCCVVV(e, s, r) {\n return e % i.bcvMaxValue * i.bookDigitShifter + (s >= 0 ? s % i.bcvMaxValue * i.chapterDigitShifter : 0) + (r >= 0 ? r % i.bcvMaxValue : 0);\n }\n /**\n * Deserializes a serialized VerseRef.\n * @param serializedVerseRef - Serialized VerseRef to create from.\n * @returns the deserialized VerseRef.\n */\n static fromJSON(e) {\n const { book: s, chapterNum: r, verseNum: a, verse: o, versificationStr: u } = e, f = o || a.toString();\n let d;\n return u && (d = new c(u)), s ? new i(s, r.toString(), f, d) : new i();\n }\n /**\n * Parses a verse string and gets the leading numeric portion as a number.\n * @param verseStr - verse string to parse\n * @returns true if the entire string could be parsed as a single, simple verse number (1-999);\n * false if the verse string represented a verse bridge, contained segment letters, or was invalid\n */\n static tryGetVerseNum(e) {\n let s;\n if (!e)\n return s = -1, { success: !0, vNum: s };\n s = 0;\n let r;\n for (let a = 0; a < e.length; a++) {\n if (r = e[a], r < \"0\" || r > \"9\")\n return a === 0 && (s = -1), { success: !1, vNum: s };\n if (s = s * 10 + +r - 0, s > i.bcvMaxValue)\n return s = -1, { success: !1, vNum: s };\n }\n return { success: !0, vNum: s };\n }\n /**\n * Checks to see if a VerseRef hasn't been set - all values are the default.\n */\n get isDefault() {\n return this.bookNum === 0 && this.chapterNum === 0 && this.verseNum === 0 && this.versification == null;\n }\n /**\n * Gets whether the verse contains multiple verses.\n */\n get hasMultiple() {\n return this._verse != null && (this._verse.includes(i.verseRangeSeparator) || this._verse.includes(i.verseSequenceIndicator));\n }\n /**\n * Gets or sets the book of the reference. Book is the 3-letter abbreviation in capital letters,\n * e.g. `'MAT'`.\n */\n get book() {\n return m.bookNumberToId(this.bookNum, \"\");\n }\n set book(e) {\n this.bookNum = m.bookIdToNumber(e);\n }\n /**\n * Gets or sets the chapter of the reference,. e.g. `'3'`.\n */\n get chapter() {\n return this.isDefault || this._chapterNum < 0 ? \"\" : this._chapterNum.toString();\n }\n set chapter(e) {\n const s = +e;\n this._chapterNum = Number.isInteger(s) ? s : -1;\n }\n /**\n * Gets or sets the verse of the reference, including range, segments, and sequences, e.g. `'4'`,\n * or `'4b-5a, 7'`.\n */\n get verse() {\n return this._verse != null ? this._verse : this.isDefault || this._verseNum < 0 ? \"\" : this._verseNum.toString();\n }\n set verse(e) {\n const { success: s, vNum: r } = i.tryGetVerseNum(e);\n this._verse = s ? void 0 : e.replace(this.rtlMark, \"\"), this._verseNum = r, !(this._verseNum >= 0) && ({ vNum: this._verseNum } = i.tryGetVerseNum(this._verse));\n }\n /**\n * Get or set Book based on book number, e.g. `42`.\n */\n get bookNum() {\n return this._bookNum;\n }\n set bookNum(e) {\n if (e <= 0 || e > m.lastBook)\n throw new v(\n \"BookNum must be greater than zero and less than or equal to last book\"\n );\n this._bookNum = e;\n }\n /**\n * Gets or sets the chapter number, e.g. `3`. `-1` if not valid.\n */\n get chapterNum() {\n return this._chapterNum;\n }\n set chapterNum(e) {\n this.chapterNum = e;\n }\n /**\n * Gets or sets verse start number, e.g. `4`. `-1` if not valid.\n */\n get verseNum() {\n return this._verseNum;\n }\n set verseNum(e) {\n this._verseNum = e;\n }\n /**\n * String representing the versification (should ONLY be used for serialization/deserialization).\n *\n * @remarks This is for backwards compatibility when ScrVers was an enumeration.\n */\n get versificationStr() {\n var e;\n return (e = this.versification) == null ? void 0 : e.name;\n }\n set versificationStr(e) {\n this.versification = this.versification != null ? new c(e) : void 0;\n }\n /**\n * Determines if the reference is valid.\n */\n get valid() {\n return this.validStatus === 0;\n }\n /**\n * Get the valid status for this reference.\n */\n get validStatus() {\n return this.validateVerse(i.verseRangeSeparators, i.verseSequenceIndicators);\n }\n /**\n * Gets the reference as a comparable integer where the book,\n * chapter, and verse each occupy three digits and the verse is 0.\n */\n get BBBCCC() {\n return i.getBBBCCCVVV(this._bookNum, this._chapterNum, 0);\n }\n /**\n * Gets the reference as a comparable integer where the book,\n * chapter, and verse each occupy three digits. If verse is not null\n * (i.e., this reference represents a complex reference with verse\n * segments or bridge) this cannot be used for an exact comparison.\n */\n get BBBCCCVVV() {\n return i.getBBBCCCVVV(this._bookNum, this._chapterNum, this._verseNum);\n }\n /**\n * Gets whether the verse is defined as an excluded verse in the versification.\n * Does not handle verse ranges.\n */\n // eslint-disable-next-line @typescript-eslint/class-literal-property-style\n get isExcluded() {\n return !1;\n }\n /**\n * Parses the reference in the specified string.\n * Optionally versification can follow reference as in GEN 3:11/4\n * Throw an exception if\n * - invalid book name\n * - chapter number is missing or not a number\n * - verse number is missing or does not start with a number\n * - versification is invalid\n * @param verseStr - string to parse e.g. 'MAT 3:11'\n */\n parse(e) {\n if (e = e.replace(this.rtlMark, \"\"), e.includes(\"/\")) {\n const o = e.split(\"/\");\n if (e = o[0], o.length > 1)\n try {\n const u = +o[1].trim();\n this.versification = new c(l[u]);\n } catch {\n throw new v(\"Invalid reference : \" + e);\n }\n }\n const s = e.trim().split(\" \");\n if (s.length !== 2)\n throw new v(\"Invalid reference : \" + e);\n const r = s[1].split(\":\"), a = +r[0];\n if (r.length !== 2 || m.bookIdToNumber(s[0]) === 0 || !Number.isInteger(a) || a < 0 || !i.isVerseParseable(r[1]))\n throw new v(\"Invalid reference : \" + e);\n this.updateInternal(s[0], r[0], r[1]);\n }\n /**\n * Simplifies this verse ref so that it has no bridging of verses or\n * verse segments like `'1a'`.\n */\n simplify() {\n this._verse = void 0;\n }\n /**\n * Makes a clone of the reference.\n *\n * @returns The cloned VerseRef.\n */\n clone() {\n return new i(this);\n }\n toString() {\n const e = this.book;\n return e === \"\" ? \"\" : `${e} ${this.chapter}:${this.verse}`;\n }\n toJSON() {\n let e = this.verse;\n (e === \"\" || e === this.verseNum.toString()) && (e = void 0);\n const s = {\n book: this.book,\n chapterNum: this.chapterNum,\n verseNum: this.verseNum,\n verse: e,\n versificationStr: this.versificationStr\n };\n return e || delete s.verse, s;\n }\n /**\n * Compares this `VerseRef` with supplied one.\n * @param verseRef - object to compare this one to.\n * @returns `true` if this `VerseRef` is equal to the supplied one, `false` otherwise.\n */\n equals(e) {\n return e instanceof i ? e._bookNum === this._bookNum && e._chapterNum === this._chapterNum && e._verseNum === this._verseNum && e.verse === this.verse && (e.versification == null && this.versification == null || e.versification != null && this.versification != null && e.versification.equals(this.versification)) : !1;\n }\n /**\n * Enumerate all individual verses contained in a VerseRef.\n * Verse ranges are indicated by \"-\" and consecutive verses by \",\"s.\n * Examples:\n * GEN 1:2 returns GEN 1:2\n * GEN 1:1a-3b,5 returns GEN 1:1a, GEN 1:2, GEN 1:3b, GEN 1:5\n * GEN 1:2a-2c returns //! ??????\n *\n * @param specifiedVersesOnly - if set to true return only verses that are\n * explicitly specified only, not verses within a range. Defaults to `false`.\n * @param verseRangeSeparators - Verse range separators.\n * Defaults to `VerseRef.verseRangeSeparators`.\n * @param verseSequenceSeparators - Verse sequence separators.\n * Defaults to `VerseRef.verseSequenceIndicators`.\n * @returns An array of all single verse references in this VerseRef.\n */\n allVerses(e = !1, s = i.verseRangeSeparators, r = i.verseSequenceIndicators) {\n if (this._verse == null || this.chapterNum <= 0)\n return [this.clone()];\n const a = [], o = E(this._verse, r);\n for (const u of o.map((f) => E(f, s))) {\n const f = this.clone();\n f.verse = u[0];\n const d = f.verseNum;\n if (a.push(f), u.length > 1) {\n const b = this.clone();\n if (b.verse = u[1], !e)\n for (let p = d + 1; p < b.verseNum; p++) {\n const J = new i(\n this._bookNum,\n this._chapterNum,\n p,\n this.versification\n );\n this.isExcluded || a.push(J);\n }\n a.push(b);\n }\n }\n return a;\n }\n /**\n * Validates a verse number using the supplied separators rather than the defaults.\n */\n validateVerse(e, s) {\n if (!this.verse)\n return this.internalValid;\n let r = 0;\n for (const a of this.allVerses(!0, e, s)) {\n const o = a.internalValid;\n if (o !== 0)\n return o;\n const u = a.BBBCCCVVV;\n if (r > u)\n return 3;\n if (r === u)\n return 4;\n r = u;\n }\n return 0;\n }\n /**\n * Gets whether a single verse reference is valid.\n */\n get internalValid() {\n return this.versification == null ? 1 : this._bookNum <= 0 || this._bookNum > m.lastBook ? 2 : (m.isCanonical(this._bookNum), 0);\n }\n setEmpty(e = i.defaultVersification) {\n this._bookNum = 0, this._chapterNum = -1, this._verse = void 0, this.versification = e;\n }\n updateInternal(e, s, r) {\n this.bookNum = m.bookIdToNumber(e), this.chapter = s, this.verse = r;\n }\n};\nn(i, \"defaultVersification\", c.English), n(i, \"verseRangeSeparator\", \"-\"), n(i, \"verseSequenceIndicator\", \",\"), n(i, \"verseRangeSeparators\", [i.verseRangeSeparator]), n(i, \"verseSequenceIndicators\", [i.verseSequenceIndicator]), n(i, \"chapterDigitShifter\", 1e3), n(i, \"bookDigitShifter\", i.chapterDigitShifter * i.chapterDigitShifter), n(i, \"bcvMaxValue\", i.chapterDigitShifter - 1), /**\n * The valid status of the VerseRef.\n */\nn(i, \"ValidStatusType\", D);\nlet M = i;\nclass v extends Error {\n}\nexport {\n _ as BookSet,\n m as Canon,\n c as ScrVers,\n l as ScrVersType,\n M as VerseRef,\n v as VerseRefException\n};\n//# sourceMappingURL=index.es.js.map\n","import React from 'react';\nimport * as DropdownMenuPrimitive from '@radix-ui/react-dropdown-menu';\nimport { Check, ChevronRight, Circle } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport const DropdownMenu = DropdownMenuPrimitive.Root;\n\nexport const DropdownMenuTrigger = DropdownMenuPrimitive.Trigger;\n\nexport const DropdownMenuGroup = DropdownMenuPrimitive.Group;\n\nexport const DropdownMenuPortal = DropdownMenuPrimitive.Portal;\n\nexport const DropdownMenuSub = DropdownMenuPrimitive.Sub;\n\nexport const DropdownMenuRadioGroup = DropdownMenuPrimitive.RadioGroup;\n\nexport type DropdownMenuSubTriggerProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.SubTrigger\n> & {\n className?: string;\n inset?: boolean;\n};\n\nexport type DropdownMenuSubContentProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.SubContent\n> & {\n className?: string;\n};\n\nexport type DropdownMenuContentProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Content\n> & {\n className?: string;\n sideOffset?: number;\n};\n\nexport type DropdownMenuItemProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Item\n> & {\n className?: string;\n inset?: boolean;\n};\n\nexport type DropdownMenuCheckboxItemProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.CheckboxItem\n> & {\n className?: string;\n checked?: boolean;\n};\n\nexport type DropdownMenuRadioItemProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.RadioItem\n> & {\n className?: string;\n};\n\nexport type DropdownMenuLabelProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Label\n> & {\n className?: string;\n inset?: boolean;\n};\n\nexport type DropdownMenuSeparatorProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Separator\n> & {\n className?: string;\n};\n\nexport type DropdownMenuShortcutProps = React.HTMLAttributes & {\n className?: string;\n};\n\nexport const DropdownMenuSubTrigger = React.forwardRef<\n React.ElementRef,\n DropdownMenuSubTriggerProps\n>(({ className, inset, children, ...props }, ref) => (\n \n {children}\n \n \n));\nDropdownMenuSubTrigger.displayName = DropdownMenuPrimitive.SubTrigger.displayName;\n\nexport const DropdownMenuSubContent = React.forwardRef<\n React.ElementRef,\n DropdownMenuSubContentProps\n>(({ className, ...props }, ref) => (\n \n));\nDropdownMenuSubContent.displayName = DropdownMenuPrimitive.SubContent.displayName;\n\nexport const DropdownMenuContent = React.forwardRef<\n React.ElementRef,\n DropdownMenuContentProps\n>(({ className, sideOffset = 4, ...props }, ref) => (\n \n \n \n));\nDropdownMenuContent.displayName = DropdownMenuPrimitive.Content.displayName;\n\n/**\n * TODO: fix: direction is not automatically handled by this component, so that shortcuts are\n * display always to the right\n */\nexport const DropdownMenuItem = React.forwardRef<\n React.ElementRef,\n DropdownMenuItemProps\n>(({ className, inset, ...props }, ref) => (\n \n));\nDropdownMenuItem.displayName = DropdownMenuPrimitive.Item.displayName;\n\nexport const DropdownMenuCheckboxItem = React.forwardRef<\n React.ElementRef,\n DropdownMenuCheckboxItemProps\n>(({ className, children, checked, ...props }, ref) => (\n \n \n \n \n \n \n {children}\n \n));\nDropdownMenuCheckboxItem.displayName = DropdownMenuPrimitive.CheckboxItem.displayName;\n\nexport const DropdownMenuRadioItem = React.forwardRef<\n React.ElementRef,\n DropdownMenuRadioItemProps\n>(({ className, children, ...props }, ref) => (\n \n \n \n \n \n \n {children}\n \n));\nDropdownMenuRadioItem.displayName = DropdownMenuPrimitive.RadioItem.displayName;\n\nexport const DropdownMenuLabel = React.forwardRef<\n React.ElementRef,\n DropdownMenuLabelProps\n>(({ className, inset, ...props }, ref) => (\n \n));\nDropdownMenuLabel.displayName = DropdownMenuPrimitive.Label.displayName;\n\nexport const DropdownMenuSeparator = React.forwardRef<\n React.ElementRef,\n DropdownMenuSeparatorProps\n>(({ className, ...props }, ref) => (\n \n));\nDropdownMenuSeparator.displayName = DropdownMenuPrimitive.Separator.displayName;\n\nexport function DropdownMenuShortcut({ className, ...props }: DropdownMenuShortcutProps) {\n return (\n \n );\n}\nDropdownMenuShortcut.displayName = 'DropdownMenuShortcut';\n","import { Canon } from '@sillsdev/scripture';\nimport { PropsWithChildren, KeyboardEvent, forwardRef } from 'react';\nimport { DropdownMenuItem as ShadDropdownMenuItem } from '@/components/shadcn-ui/dropdown-menu';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport type BookType = 'OT' | 'NT' | 'DC';\n\ntype BookMenuItemProps = PropsWithChildren<{\n /** String id of book */\n bookId: string;\n /** Callback to run when a book menu item is selected */\n handleSelectBook: () => void;\n /** Indicates if this menu item is currently selected */\n isSelected: boolean;\n /** Function that is called upon highlighting a book in the dropdown menu */\n handleHighlightBook: () => void;\n /**\n * Function that is called on pressing a key\n *\n * @param event Event that contains information about the key stroke\n */\n handleKeyDown: (event: KeyboardEvent) => void;\n /**\n * Type of book associated with this menu item, coordinates color labels ? Mock up has the labels\n * coordinated to genre\n */\n bookType: BookType;\n}>;\n\nconst BookMenuItem = forwardRef(\n (\n {\n bookId,\n handleSelectBook,\n isSelected,\n handleHighlightBook,\n handleKeyDown,\n bookType,\n children,\n }: BookMenuItemProps,\n ref,\n ) => {\n return (\n {\n // preventDefault() here prevents the entire dropdown menu from closing when selecting this item\n event.preventDefault();\n handleSelectBook();\n }}\n onKeyDown={(event: KeyboardEvent) => {\n handleKeyDown(event);\n }}\n onFocus={handleHighlightBook}\n onMouseMove={handleHighlightBook}\n >\n \n {Canon.bookIdToEnglishName(bookId)}\n \n {isSelected &&
    {children}
    }\n \n );\n },\n);\n\nexport default BookMenuItem;\n","import { cn } from '@/utils/shadcn-ui.util';\nimport { useCallback } from 'react';\n\nexport type ChapterSelectProps = {\n /**\n * Callback to run when a chapter div is selected\n *\n * @param chapterNumber Number of the chapter that has been selected\n */\n handleSelectChapter: (chapterNumber: number) => void;\n /** The highest chapter number in the book (of course equal to number of chapters in the book) */\n endChapter: number;\n /** The chapter number that is currently selected */\n activeChapter: number;\n /** The chapter number that is currently highlighted using keyboard or mouse navigation */\n highlightedChapter: number;\n /**\n * Callback to run when a chapter is highlighted by the user\n *\n * @param chapterNumber The chapter that is highlighted\n */\n handleHighlightedChapter: (chapterNumber: number) => void;\n};\n\nfunction ChapterSelect({\n handleSelectChapter,\n endChapter,\n activeChapter,\n highlightedChapter,\n handleHighlightedChapter,\n}: ChapterSelectProps) {\n const chapters = Array.from({ length: endChapter }, (_, i) => i + 1);\n\n const handleMouse = useCallback(\n (chapterNumber: number) => {\n handleHighlightedChapter(chapterNumber);\n },\n [handleHighlightedChapter],\n );\n\n return (\n
    \n {chapters.map((chapter) => (\n {\n event.preventDefault();\n event.stopPropagation();\n handleSelectChapter(chapter);\n }}\n role=\"button\"\n onKeyDown={(event) => {\n if (event.key === 'Enter') {\n handleSelectChapter(chapter);\n }\n }}\n tabIndex={0}\n onMouseMove={() => handleMouse(chapter)}\n >\n {chapter}\n
    \n ))}\n
    \n );\n}\n\nexport default ChapterSelect;\n","import { DropdownMenuLabel as ShadDropdownMenuLabel } from '@/components/shadcn-ui/dropdown-menu';\nimport { Bookmark, Clock, ArrowDownWideNarrow } from 'lucide-react';\n\nexport type GoToMenuItemProps = {\n handleSort: () => void;\n handleLocationHistory: () => void;\n handleBookmarks: () => void;\n};\n\nfunction GoToMenuItem({ handleSort, handleLocationHistory, handleBookmarks }: GoToMenuItemProps) {\n return (\n \n

    Go To

    \n
    \n \n \n \n
    \n
    \n );\n}\n\nexport default GoToMenuItem;\n","import BookChapterInput from '@/components/advanced/book-chapter-control/book-chapter-input.component';\nimport BookMenuItem, {\n BookType,\n} from '@/components/advanced/book-chapter-control/book-menu-item.component';\nimport ChapterSelect from '@/components/advanced/book-chapter-control/chapter-select.component';\nimport GoToMenuItem from '@/components/advanced/book-chapter-control/go-to-menu-item.component';\nimport {\n DropdownMenu as ShadDropdownMenu,\n DropdownMenuContent as ShadDropdownMenuContent,\n DropdownMenuLabel as ShadDropdownMenuLabel,\n DropdownMenuSeparator as ShadDropdownMenuSeparator,\n DropdownMenuTrigger as ShadDropdownMenuTrigger,\n} from '@/components/shadcn-ui/dropdown-menu';\nimport { Canon } from '@sillsdev/scripture';\nimport { ScriptureReference, getChaptersForBook } from 'platform-bible-utils';\nimport {\n KeyboardEvent as ReactKeyboardEvent,\n useCallback,\n useEffect,\n useLayoutEffect,\n useRef,\n useState,\n} from 'react';\n\ntype BookTypeLabels = {\n [bookType in BookType]: string;\n};\ntype BookChapterControlProps = {\n scrRef: ScriptureReference;\n handleSubmit: (scrRef: ScriptureReference) => void;\n};\n\nconst ALL_BOOK_IDS = Canon.allBookIds;\nconst BOOK_TYPE_LABELS: BookTypeLabels = {\n OT: 'Old Testament',\n NT: 'New Testament',\n DC: 'Deuterocanon',\n};\nconst BOOK_TYPE_ARRAY: BookType[] = ['OT', 'NT', 'DC'];\n// This is the height of three menu items to offset scrolling to the selected menu item\n// If you use menuItemRef.clientHeight- includes height of chapter div which is too big\nconst SCROLL_OFFSET = 32 + 32 + 32;\nconst SEARCH_QUERY_FORMATS = [\n /^(\\w+)$/i, // Matches a single word (book name or id)\n /^(\\w+)(?:\\s(\\d+))$/i, // Matches a word followed by a chapter number\n /^(\\w+)(?:\\s(\\d+):(\\d+))$/i, // Matches a word followed by a chapter and verse number\n];\nconst fetchGroupedBooks = (bookType: BookType) => {\n const groupedBooks = {\n OT: ALL_BOOK_IDS.filter((bookId) => Canon.isBookOT(bookId)),\n NT: ALL_BOOK_IDS.filter((bookId) => Canon.isBookNT(bookId)),\n DC: ALL_BOOK_IDS.filter((bookId) => Canon.isBookDC(bookId)),\n };\n return groupedBooks[bookType];\n};\nconst fetchEndChapter = (bookId: string) => {\n // getChaptersForBook returns -1 if not found in scrBookData\n // scrBookData only includes OT and NT, so all DC will return -1\n return getChaptersForBook(Canon.bookIdToNumber(bookId));\n};\n\n/**\n * Gets all of the English names from book ids\n *\n * @returns String[]\n */\nfunction getAllEnglishNames(): string[] {\n const allEnglishNames = ALL_BOOK_IDS.map((bookId) => {\n return Canon.bookIdToEnglishName(bookId);\n });\n return allEnglishNames;\n}\n\n/**\n * Determines if bookName is in allEnglishNames\n *\n * @param bookName Book English name\n * @returns True if bookName is included, false otherwise\n */\nfunction isValidBookEnglishName(bookName: string): boolean {\n return getAllEnglishNames().includes(bookName);\n}\n\n/**\n * Gets a bookId from given English name\n *\n * @param bookName Book English name\n * @returns BookId of provided bookName, undefined otherwise\n */\nfunction getBookIdFromEnglishName(bookName: string): string | undefined {\n // Convert bookName to lowercase and then capitalize the first letter\n const formattedBookName = bookName.toLowerCase().replace(/^\\w/, (c) => c.toUpperCase());\n\n if (isValidBookEnglishName(formattedBookName)) {\n const matchingBookId = ALL_BOOK_IDS.find((bookId) => {\n return Canon.bookIdToEnglishName(bookId) === formattedBookName;\n });\n return matchingBookId;\n }\n\n return undefined;\n}\n\nfunction BookChapterControl({ scrRef, handleSubmit }: BookChapterControlProps) {\n const [searchQuery, setSearchQuery] = useState('');\n const [selectedBookId, setSelectedBookId] = useState(\n Canon.bookNumberToId(scrRef.bookNum),\n );\n const [highlightedChapter, setHighlightedChapter] = useState(scrRef.chapterNum ?? 0);\n const [highlightedBookId, setHighlightedBookId] = useState(\n Canon.bookNumberToId(scrRef.bookNum),\n );\n const [isContentOpen, setIsContentOpen] = useState(false);\n const [isContentOpenDelayed, setIsContentOpenDelayed] = useState(isContentOpen);\n\n // This ref will always be defined\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const inputRef = useRef(undefined!);\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const contentRef = useRef(undefined!);\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const menuItemRef = useRef(undefined!);\n\n const fetchFilteredBooks = useCallback(\n (bookType: BookType) => {\n return fetchGroupedBooks(bookType).filter((bookId: string) => {\n const englishNameLowerCase = Canon.bookIdToEnglishName(bookId).toLowerCase();\n const normalizedQuery = searchQuery.replace(/[^a-zA-Z]/g, '').toLowerCase();\n return (\n englishNameLowerCase.includes(normalizedQuery) || // Match book name\n bookId.toLowerCase().includes(normalizedQuery) // Match book ID\n );\n });\n },\n [searchQuery],\n );\n\n const handleSearchInput = (searchString: string) => {\n setSearchQuery(searchString);\n };\n\n /**\n * Whether to prevent radix's logic from closing the dropdown. This is important because radix\n * tries to close the dropdown when the input first focuses, and we don't want it to do that. But\n * we don't want to prevent the dropdown from closing when we click away from the input, so we\n * don't want to just keep it open if the input is focused\n */\n const shouldPreventAutoClosing = useRef(false);\n\n const controlMenuState = useCallback((open: boolean) => {\n if (shouldPreventAutoClosing.current) {\n shouldPreventAutoClosing.current = false;\n return;\n }\n setIsContentOpen(open);\n }, []);\n\n const updateReference = useCallback(\n (bookId: string, shouldClose: boolean, chapter?: number, verse?: number) => {\n setHighlightedChapter(\n Canon.bookNumberToId(scrRef.bookNum) !== bookId ? 1 : scrRef.chapterNum,\n );\n\n if (shouldClose || fetchEndChapter(bookId) === -1) {\n handleSubmit({\n bookNum: Canon.bookIdToNumber(bookId),\n chapterNum: chapter || 1,\n verseNum: verse || 1,\n });\n\n setIsContentOpen(false);\n setSearchQuery('');\n return;\n }\n\n setSelectedBookId(selectedBookId !== bookId ? bookId : '');\n setIsContentOpen(!shouldClose);\n },\n [handleSubmit, scrRef.bookNum, scrRef.chapterNum, selectedBookId],\n );\n\n const handleSelectChapter = (chapterNumber: number) => {\n if (chapterNumber <= 0 || chapterNumber > fetchEndChapter(selectedBookId)) {\n return;\n }\n updateReference(selectedBookId, true, chapterNumber);\n };\n\n const handleInputSubmit = useCallback(() => {\n SEARCH_QUERY_FORMATS.forEach((format) => {\n const matches = searchQuery.match(format);\n if (matches) {\n // Book should be a bookId or an english name\n const [book, chapter = undefined, verse = undefined] = matches.slice(1);\n const englishName = getBookIdFromEnglishName(book);\n\n if (Canon.isBookIdValid(book) || englishName) {\n updateReference(\n englishName ?? book,\n true,\n chapter ? parseInt(chapter, 10) : 1,\n verse ? parseInt(verse, 10) : 1,\n );\n }\n }\n });\n }, [updateReference, searchQuery]);\n\n const handleKeyDownInput = useCallback(\n (event: ReactKeyboardEvent) => {\n if (!isContentOpen) {\n setIsContentOpen(true);\n } else if (event.key === 'ArrowDown' || event.key === 'ArrowUp') {\n if (\n typeof menuItemRef !== 'undefined' &&\n // Ref uses null\n // eslint-disable-next-line no-null/no-null\n menuItemRef.current !== null\n ) {\n menuItemRef.current.focus();\n } else if (\n typeof contentRef !== 'undefined' &&\n // Ref uses null\n // eslint-disable-next-line no-null/no-null\n contentRef.current !== null\n ) {\n contentRef.current.focus();\n }\n event.preventDefault();\n }\n },\n [isContentOpen],\n );\n\n const handleKeyDownContent = (event: ReactKeyboardEvent) => {\n // When the dropdown menu has focus, key strokes should give focus to the input component,\n // unless they're navigation keys (arrows and enter)\n const { key } = event;\n if (\n key === 'ArrowRight' ||\n key === 'ArrowLeft' ||\n key === 'ArrowDown' ||\n key === 'ArrowUp' ||\n key === 'Enter'\n ) {\n return;\n }\n\n inputRef.current.dispatchEvent(new KeyboardEvent('keydown', { key }));\n inputRef.current.focus();\n };\n\n const handleKeyDownMenuItem = (event: ReactKeyboardEvent) => {\n const { key } = event;\n if (highlightedBookId === selectedBookId) {\n if (key === 'Enter') {\n event.preventDefault();\n updateReference(selectedBookId, true, highlightedChapter);\n return;\n }\n\n let chapterOffSet = 0;\n if (key === 'ArrowRight') {\n if (highlightedChapter < fetchEndChapter(highlightedBookId)) {\n chapterOffSet = 1;\n } else {\n event.preventDefault();\n return;\n }\n } else if (key === 'ArrowLeft') {\n if (highlightedChapter > 1) {\n chapterOffSet = -1;\n } else {\n event.preventDefault();\n return;\n }\n } else if (key === 'ArrowDown') {\n chapterOffSet = 6;\n } else if (key === 'ArrowUp') {\n chapterOffSet = -6;\n }\n if (\n highlightedChapter + chapterOffSet <= 0 ||\n highlightedChapter + chapterOffSet > fetchEndChapter(highlightedBookId)\n ) {\n setHighlightedChapter(0);\n } else if (chapterOffSet !== 0) {\n setHighlightedChapter(highlightedChapter + chapterOffSet);\n event.preventDefault();\n }\n }\n };\n\n useEffect(() => {\n if (selectedBookId === highlightedBookId) {\n if (selectedBookId === Canon.bookNumberToId(scrRef.bookNum)) {\n setHighlightedChapter(scrRef.chapterNum);\n } else {\n setHighlightedChapter(1);\n }\n } else {\n setHighlightedChapter(0);\n }\n }, [highlightedBookId, scrRef.bookNum, scrRef.chapterNum, selectedBookId]);\n\n // The purpose of these useLayoutEffects and timeout is to delay the scroll just\n // enough so that the refs are defined and available when they are used after the timeout\n useLayoutEffect(() => {\n setIsContentOpenDelayed(isContentOpen);\n }, [isContentOpen]);\n\n useLayoutEffect(() => {\n const scrollTimeout = setTimeout(() => {\n if (isContentOpenDelayed && contentRef.current && menuItemRef.current) {\n const menuItemOffsetTop = menuItemRef.current.offsetTop;\n const scrollPosition = menuItemOffsetTop - SCROLL_OFFSET;\n contentRef.current.scrollTo({ top: scrollPosition, behavior: 'instant' });\n }\n }, 10);\n return () => {\n clearTimeout(scrollTimeout);\n };\n }, [isContentOpenDelayed]);\n\n return (\n
    \n \n \n {\n setSelectedBookId(Canon.bookNumberToId(scrRef.bookNum));\n setHighlightedBookId(Canon.bookNumberToId(scrRef.bookNum));\n setHighlightedChapter(scrRef.chapterNum > 0 ? scrRef.chapterNum : 0);\n setIsContentOpen(true);\n inputRef.current.focus();\n }}\n onFocus={() => {\n // Radix thinks we want to close because the input is being focused. Prevent that\n shouldPreventAutoClosing.current = true;\n }}\n handleSubmit={handleInputSubmit}\n placeholder={`${Canon.bookNumberToEnglishName(scrRef.bookNum)} ${scrRef.chapterNum}:${scrRef.verseNum}`}\n />\n \n \n console.log('sorting')}\n handleLocationHistory={() => console.log('location history')}\n handleBookmarks={() => console.log('bookmarks')}\n />\n {BOOK_TYPE_ARRAY.map(\n (bookType, bookTypeIndex) =>\n fetchFilteredBooks(bookType).length > 0 && (\n
    \n \n {BOOK_TYPE_LABELS[bookType]}\n \n\n {fetchFilteredBooks(bookType).map((bookId) => (\n
    \n updateReference(bookId, false)}\n isSelected={selectedBookId === bookId}\n handleHighlightBook={() => setHighlightedBookId(bookId)}\n handleKeyDown={handleKeyDownMenuItem}\n bookType={bookType}\n ref={(element: HTMLDivElement) => {\n if (selectedBookId === bookId) menuItemRef.current = element;\n }}\n >\n {\n setHighlightedChapter(chapterNumber);\n }}\n />\n \n
    \n ))}\n {BOOK_TYPE_ARRAY.length - 1 !== bookTypeIndex ? (\n \n ) : undefined}\n
    \n ),\n )}\n \n
    \n
    \n );\n}\n\nexport default BookChapterControl;\n","import React from 'react';\nimport { Slot } from '@radix-ui/react-slot';\nimport { cva, type VariantProps } from 'class-variance-authority';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport const buttonVariants = cva(\n 'pr-twp tw-inline-flex tw-items-center tw-justify-center tw-whitespace-nowrap tw-rounded-md tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-colors focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50',\n {\n variants: {\n variant: {\n default: 'tw-bg-primary tw-text-primary-foreground hover:tw-bg-primary/90',\n destructive: 'tw-bg-destructive tw-text-destructive-foreground hover:tw-bg-destructive/90',\n outline:\n 'tw-border tw-border-input tw-bg-background hover:tw-bg-accent hover:tw-text-accent-foreground',\n secondary: 'tw-bg-secondary tw-text-secondary-foreground hover:tw-bg-secondary/80',\n ghost: 'hover:tw-bg-accent hover:tw-text-accent-foreground',\n link: 'tw-text-primary tw-underline-offset-4 hover:tw-underline',\n },\n size: {\n default: 'tw-h-10 tw-px-4 tw-py-2',\n sm: 'tw-h-9 tw-rounded-md tw-px-3',\n lg: 'tw-h-11 tw-rounded-md tw-px-8',\n icon: 'tw-h-10 tw-w-10',\n },\n },\n defaultVariants: {\n variant: 'default',\n size: 'default',\n },\n },\n);\n\nexport interface ButtonProps\n extends React.ButtonHTMLAttributes,\n VariantProps {\n asChild?: boolean;\n}\n\nexport const Button = React.forwardRef(\n ({ className, variant, size, asChild = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'button';\n return (\n \n );\n },\n);\nButton.displayName = 'Button';\n","import React from 'react';\nimport * as LabelPrimitive from '@radix-ui/react-label';\nimport { cva, type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst labelVariants = cva(\n 'tw-text-sm tw-font-medium tw-leading-none peer-disabled:tw-cursor-not-allowed peer-disabled:tw-opacity-70',\n);\n\nexport const Label = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef & VariantProps\n>(({ className, ...props }, ref) => (\n \n));\nLabel.displayName = LabelPrimitive.Root.displayName;\n","import React from 'react';\nimport * as RadioGroupPrimitive from '@radix-ui/react-radio-group';\nimport { Circle } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst RadioGroup = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => {\n return (\n \n );\n});\nRadioGroup.displayName = RadioGroupPrimitive.Root.displayName;\n\nconst RadioGroupItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => {\n return (\n \n \n \n \n \n );\n});\nRadioGroupItem.displayName = RadioGroupPrimitive.Item.displayName;\n\nexport { RadioGroup, RadioGroupItem };\n","import React from 'react';\nimport * as PopoverPrimitive from '@radix-ui/react-popover';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Popover = PopoverPrimitive.Root;\n\nconst PopoverTrigger = PopoverPrimitive.Trigger;\n\nconst PopoverContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, align = 'center', sideOffset = 4, ...props }, ref) => (\n \n \n \n));\nPopoverContent.displayName = PopoverPrimitive.Content.displayName;\n\nexport { Popover, PopoverTrigger, PopoverContent };\n","import React from 'react';\nimport * as DialogPrimitive from '@radix-ui/react-dialog';\nimport { X } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Dialog = DialogPrimitive.Root;\n\nconst DialogTrigger = DialogPrimitive.Trigger;\n\nconst DialogPortal = DialogPrimitive.Portal;\n\nconst DialogClose = DialogPrimitive.Close;\n\nconst DialogOverlay = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nDialogOverlay.displayName = DialogPrimitive.Overlay.displayName;\n\nconst DialogContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, ...props }, ref) => (\n \n \n \n {children}\n \n \n Close\n \n \n \n));\nDialogContent.displayName = DialogPrimitive.Content.displayName;\n\nfunction DialogHeader({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nDialogHeader.displayName = 'DialogHeader';\n\nfunction DialogFooter({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nDialogFooter.displayName = 'DialogFooter';\n\nconst DialogTitle = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nDialogTitle.displayName = DialogPrimitive.Title.displayName;\n\nconst DialogDescription = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nDialogDescription.displayName = DialogPrimitive.Description.displayName;\n\nexport {\n Dialog,\n DialogPortal,\n DialogOverlay,\n DialogClose,\n DialogTrigger,\n DialogContent,\n DialogHeader,\n DialogFooter,\n DialogTitle,\n DialogDescription,\n};\n","import React from 'react';\nimport { type DialogProps } from '@radix-ui/react-dialog';\nimport { Command as CommandPrimitive } from 'cmdk';\nimport { Search } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Dialog, DialogContent } from '@/components/shadcn-ui/dialog';\n\nconst Command = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nCommand.displayName = CommandPrimitive.displayName;\n\ninterface CommandDialogProps extends DialogProps {}\n\nfunction CommandDialog({ children, ...props }: CommandDialogProps) {\n return (\n \n \n \n {children}\n \n \n \n );\n}\n\nconst CommandInput = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n
    \n \n \n
    \n));\n\nCommandInput.displayName = CommandPrimitive.Input.displayName;\n\nconst CommandList = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\n\nCommandList.displayName = CommandPrimitive.List.displayName;\n\nconst CommandEmpty = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>((props, ref) => (\n \n));\n\nCommandEmpty.displayName = CommandPrimitive.Empty.displayName;\n\nconst CommandGroup = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\n\nCommandGroup.displayName = CommandPrimitive.Group.displayName;\n\nconst CommandSeparator = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nCommandSeparator.displayName = CommandPrimitive.Separator.displayName;\n\nconst CommandItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\n\nCommandItem.displayName = CommandPrimitive.Item.displayName;\n\nfunction CommandShortcut({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nCommandShortcut.displayName = 'CommandShortcut';\n\nexport {\n Command,\n CommandDialog,\n CommandInput,\n CommandList,\n CommandEmpty,\n CommandGroup,\n CommandItem,\n CommandShortcut,\n CommandSeparator,\n};\n","import { useState } from 'react';\nimport { Check, ChevronsUpDown } from 'lucide-react';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport { Popover, PopoverContent, PopoverTrigger } from '@/components/shadcn-ui/popover';\nimport {\n Command,\n CommandEmpty,\n CommandInput,\n CommandItem,\n CommandList,\n} from '@/components/shadcn-ui/command';\nimport { PopoverProps } from '@radix-ui/react-popover';\n\nexport type ComboBoxLabelOption = { label: string };\nexport type ComboBoxOption = string | number | ComboBoxLabelOption;\n\nexport type ComboBoxProps = {\n /** Optional unique identifier */\n id?: string;\n /** Text label title for combobox */\n /** List of available options for the dropdown menu */\n options?: readonly T[];\n /** Additional css classes to help with unique styling of the combo box button */\n buttonClassName?: string;\n /** Additional css classes to help with unique styling of the combo box popover */\n popoverContentClassName?: string;\n /**\n * The selected value that the combo box currently holds. Must be shallow equal to one of the\n * options entries.\n */\n value?: T;\n /** Triggers when content of textfield is changed */\n onChange?: (newValue: T) => void;\n /** Used to determine the string value for a given option. */\n getOptionLabel?: (option: ComboBoxOption) => string;\n /** Text displayed on button if `value` is undefined */\n buttonPlaceholder?: string;\n /** Placeholder text for text field */\n textPlaceholder?: string;\n /** Text to display when no options match input */\n commandEmptyMessage?: string;\n /** Variant of button */\n buttonVariant?: ButtonProps['variant'];\n /** Text direction ltr or rtl */\n dir?: Direction;\n /** Optional boolean to set if trigger should be disabled */\n isDisabled?: boolean;\n} & PopoverProps;\n\ntype Direction = 'ltr' | 'rtl';\n\nfunction getOptionLabelDefault(option: ComboBoxOption): string {\n if (typeof option === 'string') {\n return option;\n }\n if (typeof option === 'number') {\n return option.toString();\n }\n return option.label;\n}\n\n/**\n * Autocomplete input and command palette with a list of suggestions.\n *\n * Thanks to Shadcn for heavy inspiration and documentation\n * https://ui.shadcn.com/docs/components/combobox\n */\nfunction ComboBox({\n id,\n options = [],\n buttonClassName,\n popoverContentClassName,\n value,\n onChange = () => {},\n getOptionLabel = getOptionLabelDefault,\n buttonPlaceholder = '',\n textPlaceholder = '',\n commandEmptyMessage = 'No option found',\n buttonVariant = 'outline',\n dir = 'ltr',\n isDisabled = false,\n ...props\n}: ComboBoxProps) {\n const [open, setOpen] = useState(false);\n\n return (\n \n \n \n \n {value ? getOptionLabel(value) : buttonPlaceholder}\n \n \n \n \n \n \n \n {commandEmptyMessage}\n \n {options.map((option) => (\n {\n onChange(option);\n setOpen(false);\n }}\n >\n \n {getOptionLabel(option)}\n \n ))}\n \n \n \n \n );\n}\n\nexport default ComboBox;\n","import { useMemo } from 'react';\nimport ComboBox from '@/components/basics/combo-box.component';\nimport { Label } from '@/components/shadcn-ui/label';\n\nexport type ChapterRangeSelectorProps = {\n startChapter: number;\n endChapter: number;\n handleSelectStartChapter: (chapter: number) => void;\n handleSelectEndChapter: (chapter: number) => void;\n isDisabled?: boolean;\n chapterCount: number;\n};\n\nexport default function ChapterRangeSelector({\n startChapter,\n endChapter,\n handleSelectStartChapter,\n handleSelectEndChapter,\n isDisabled = false,\n chapterCount,\n}: ChapterRangeSelectorProps) {\n const chapterOptions = useMemo(\n () => Array.from({ length: chapterCount }, (_, index) => index + 1),\n [chapterCount],\n );\n\n const onChangeStartChapter = (value: number) => {\n handleSelectStartChapter(value);\n if (value > endChapter) {\n handleSelectEndChapter(value);\n }\n };\n\n const onChangeEndChapter = (value: number) => {\n handleSelectEndChapter(value);\n if (value < startChapter) {\n handleSelectStartChapter(value);\n }\n };\n\n return (\n <>\n \n option.toString()}\n value={startChapter}\n />\n\n \n option.toString()}\n value={endChapter}\n />\n \n );\n}\n","import { Button } from '@/components/shadcn-ui/button';\nimport { Label } from '@/components/shadcn-ui/label';\nimport { RadioGroup, RadioGroupItem } from '@/components/shadcn-ui/radio-group';\nimport { Canon } from '@sillsdev/scripture';\nimport { LocalizedStringValue } from 'platform-bible-utils';\nimport { useState } from 'react';\nimport ChapterRangeSelector, {\n ChapterRangeSelectorProps,\n} from '../basics/chapter-range-selector.component';\n\nexport enum BookSelectionMode {\n CURRENT_BOOK = 'current book',\n CHOOSE_BOOKS = 'choose books',\n}\n\n/**\n * Object containing all keys used for localization in this component. If you're using this\n * component in an extension, you can pass it into the useLocalizedStrings hook to easily obtain the\n * localized strings and pass them into the localizedStrings prop of this component\n */\nexport const BOOK_SELECTOR_STRING_KEYS = Object.freeze([\n '%webView_bookSelector_currentBook%',\n '%webView_bookSelector_choose%',\n '%webView_bookSelector_chooseBooks%',\n] as const);\n\nexport type BookSelectorLocalizedStrings = {\n [localizedInventoryKey in (typeof BOOK_SELECTOR_STRING_KEYS)[number]]?: LocalizedStringValue;\n};\n\n/**\n * Gets the localized value for the provided key\n *\n * @param strings Object containing localized string\n * @param key Key for a localized string\n * @returns The localized value for the provided key, if available. Returns the key if no localized\n * value is available\n */\nconst localizeString = (\n strings: BookSelectorLocalizedStrings,\n key: keyof BookSelectorLocalizedStrings,\n) => {\n return strings[key] ?? key;\n};\n\ntype BookSelectorProps = ChapterRangeSelectorProps & {\n handleBookSelectionModeChange: (newMode: BookSelectionMode) => void;\n currentBookName: string;\n onSelectBooks: () => void;\n selectedBookIds: string[];\n localizedStrings: BookSelectorLocalizedStrings;\n};\n\nexport default function BookSelector({\n handleBookSelectionModeChange,\n currentBookName,\n onSelectBooks,\n selectedBookIds,\n chapterCount,\n endChapter,\n handleSelectEndChapter,\n startChapter,\n handleSelectStartChapter,\n localizedStrings,\n}: BookSelectorProps) {\n const currentBookText = localizeString(localizedStrings, '%webView_bookSelector_currentBook%');\n const chooseText = localizeString(localizedStrings, '%webView_bookSelector_choose%');\n const chooseBooksText = localizeString(localizedStrings, '%webView_bookSelector_chooseBooks%');\n\n const [bookSelectionMode, setBookSelectionMode] = useState(\n BookSelectionMode.CURRENT_BOOK,\n );\n\n const onSelectionModeChange = (newMode: BookSelectionMode) => {\n setBookSelectionMode(newMode);\n handleBookSelectionModeChange(newMode);\n };\n\n return (\n onSelectionModeChange(value as BookSelectionMode)}\n >\n
    \n
    \n
    \n \n \n
    \n \n
    \n \n
    \n
    \n
    \n
    \n \n \n
    \n \n onSelectBooks()}\n >\n {chooseText}\n \n
    \n
    \n \n );\n}\n","import { DropdownMenuTrigger } from '@radix-ui/react-dropdown-menu';\nimport { FilterIcon } from 'lucide-react';\nimport { Table } from '@tanstack/react-table';\n\nimport { Button } from '@/components/shadcn-ui/button';\nimport {\n DropdownMenu,\n DropdownMenuCheckboxItem,\n DropdownMenuContent,\n DropdownMenuLabel,\n DropdownMenuSeparator,\n} from '@/components/shadcn-ui/dropdown-menu';\n\ninterface DataTableViewOptionsProps {\n table: Table;\n}\n\nfunction DataTableViewOptions({ table }: DataTableViewOptionsProps) {\n return (\n \n \n \n \n \n Toggle columns\n \n {table\n .getAllColumns()\n .filter((column) => column.getCanHide())\n .map((column) => {\n return (\n column.toggleVisibility(!!value)}\n >\n {column.id}\n \n );\n })}\n \n \n );\n}\n\nexport default DataTableViewOptions;\n","import React from 'react';\nimport * as SelectPrimitive from '@radix-ui/react-select';\nimport { Check, ChevronDown, ChevronUp } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Select = SelectPrimitive.Root;\n\nconst SelectGroup = SelectPrimitive.Group;\n\nconst SelectValue = SelectPrimitive.Value;\n\nconst SelectTrigger = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, ...props }, ref) => (\n span]:tw-line-clamp-1',\n className,\n )}\n {...props}\n >\n {children}\n \n \n \n \n));\nSelectTrigger.displayName = SelectPrimitive.Trigger.displayName;\n\nconst SelectScrollUpButton = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n));\nSelectScrollUpButton.displayName = SelectPrimitive.ScrollUpButton.displayName;\n\nconst SelectScrollDownButton = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n));\nSelectScrollDownButton.displayName = SelectPrimitive.ScrollDownButton.displayName;\n\nconst SelectContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, position = 'popper', ...props }, ref) => (\n \n \n \n \n {children}\n \n \n \n \n));\nSelectContent.displayName = SelectPrimitive.Content.displayName;\n\nconst SelectLabel = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSelectLabel.displayName = SelectPrimitive.Label.displayName;\n\nconst SelectItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, ...props }, ref) => (\n \n \n \n \n \n \n\n {children}\n \n));\nSelectItem.displayName = SelectPrimitive.Item.displayName;\n\nconst SelectSeparator = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSelectSeparator.displayName = SelectPrimitive.Separator.displayName;\n\nexport {\n Select,\n SelectGroup,\n SelectValue,\n SelectTrigger,\n SelectContent,\n SelectLabel,\n SelectItem,\n SelectSeparator,\n SelectScrollUpButton,\n SelectScrollDownButton,\n};\n","import { ChevronLeftIcon, ChevronRightIcon, ArrowLeftIcon, ArrowRightIcon } from 'lucide-react';\nimport { Table } from '@tanstack/react-table';\n\nimport { Button } from '@/components/shadcn-ui/button';\nimport {\n Select,\n SelectContent,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\n\ninterface DataTablePaginationProps {\n table: Table;\n}\n\nfunction DataTablePagination({ table }: DataTablePaginationProps) {\n return (\n
    \n
    \n
    \n {table.getFilteredSelectedRowModel().rows.length} of{' '}\n {table.getFilteredRowModel().rows.length} row(s) selected\n
    \n
    \n

    Rows per page

    \n {\n table.setPageSize(Number(value));\n }}\n >\n \n \n \n \n {[10, 20, 30, 40, 50].map((pageSize) => (\n \n {pageSize}\n \n ))}\n \n \n
    \n
    \n Page {table.getState().pagination.pageIndex + 1} of {table.getPageCount()}\n
    \n
    \n table.setPageIndex(0)}\n disabled={!table.getCanPreviousPage()}\n >\n Go to first page\n \n \n table.previousPage()}\n disabled={!table.getCanPreviousPage()}\n >\n Go to previous page\n \n \n table.nextPage()}\n disabled={!table.getCanNextPage()}\n >\n Go to next page\n \n \n table.setPageIndex(table.getPageCount() - 1)}\n disabled={!table.getCanNextPage()}\n >\n Go to last page\n \n \n
    \n
    \n
    \n );\n}\n\nexport default DataTablePagination;\n","import React from 'react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Table = React.forwardRef<\n HTMLTableElement,\n React.HTMLAttributes & { stickyHeader?: boolean }\n>(({ className, stickyHeader, ...props }, ref) => (\n
    \n \n
    \n));\nTable.displayName = 'Table';\n\nconst TableHeader = React.forwardRef<\n HTMLTableSectionElement,\n React.HTMLAttributes & { stickyHeader?: boolean }\n>(({ className, stickyHeader, ...props }, ref) => (\n \n));\nTableHeader.displayName = 'TableHeader';\n\nconst TableBody = React.forwardRef<\n HTMLTableSectionElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableBody.displayName = 'TableBody';\n\nconst TableFooter = React.forwardRef<\n HTMLTableSectionElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n tr]:last:tw-border-b-0', className)}\n {...props}\n />\n));\nTableFooter.displayName = 'TableFooter';\n\nconst TableRow = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nTableRow.displayName = 'TableRow';\n\nconst TableHead = React.forwardRef<\n HTMLTableCellElement,\n React.ThHTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableHead.displayName = 'TableHead';\n\nconst TableCell = React.forwardRef<\n HTMLTableCellElement,\n React.TdHTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableCell.displayName = 'TableCell';\n\nconst TableCaption = React.forwardRef<\n HTMLTableCaptionElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableCaption.displayName = 'TableCaption';\n\nexport { Table, TableHeader, TableBody, TableFooter, TableHead, TableRow, TableCell, TableCaption };\n","import { useState } from 'react';\n\nimport {\n ColumnFiltersState,\n flexRender,\n getCoreRowModel,\n getFilteredRowModel,\n getPaginationRowModel,\n getSortedRowModel,\n SortingState,\n ColumnDef as TSColumnDef,\n Row as TSRow,\n RowSelectionState as TSRowSelectionState,\n SortDirection as TSSortDirection,\n Table as TSTable,\n useReactTable,\n VisibilityState,\n} from '@tanstack/react-table';\n\nimport DataTableViewOptions from '@/components/advanced/data-table/data-table-column-toggle.component';\nimport DataTablePagination from '@/components/advanced/data-table/data-table-pagination.component';\nimport { Button } from '@/components/shadcn-ui/button';\nimport {\n Table,\n TableBody,\n TableCell,\n TableHead,\n TableHeader,\n TableRow,\n} from '@/components/shadcn-ui/table';\n\nexport type ColumnDef = TSColumnDef;\nexport type RowContents = TSRow;\nexport type TableContents = TSTable;\nexport type SortDirection = TSSortDirection;\nexport type RowSelectionState = TSRowSelectionState;\n\ninterface DataTableProps {\n columns: ColumnDef[];\n data: TData[];\n enablePagination?: boolean;\n showPaginationControls?: boolean;\n showColumnVisibilityControls?: boolean;\n stickyHeader?: boolean;\n onRowClickHandler?: (row: RowContents, table: TableContents) => void;\n}\n\n/**\n * Feature-rich table component that infuses our basic shadcn-based Table component with features\n * from TanStack's React Table library\n */\nfunction DataTable({\n columns,\n data,\n enablePagination = false,\n showPaginationControls = false,\n showColumnVisibilityControls = false,\n stickyHeader = false,\n onRowClickHandler = () => {},\n}: DataTableProps) {\n const [sorting, setSorting] = useState([]);\n const [columnFilters, setColumnFilters] = useState([]);\n const [columnVisibility, setColumnVisibility] = useState({});\n const [rowSelection, setRowSelection] = useState({});\n\n const table = useReactTable({\n data,\n columns,\n getCoreRowModel: getCoreRowModel(),\n ...(enablePagination && { getPaginationRowModel: getPaginationRowModel() }),\n onSortingChange: setSorting,\n getSortedRowModel: getSortedRowModel(),\n onColumnFiltersChange: setColumnFilters,\n getFilteredRowModel: getFilteredRowModel(),\n onColumnVisibilityChange: setColumnVisibility,\n onRowSelectionChange: setRowSelection,\n state: {\n sorting,\n columnFilters,\n columnVisibility,\n rowSelection,\n },\n });\n\n return (\n
    \n {showColumnVisibilityControls && }\n \n \n {table.getHeaderGroups().map((headerGroup) => (\n \n {headerGroup.headers.map((header) => {\n return (\n \n {header.isPlaceholder\n ? undefined\n : flexRender(header.column.columnDef.header, header.getContext())}\n \n );\n })}\n \n ))}\n \n \n {table.getRowModel().rows?.length ? (\n table.getRowModel().rows.map((row) => (\n onRowClickHandler(row, table)}\n key={row.id}\n data-state={row.getIsSelected() && 'selected'}\n >\n {row.getVisibleCells().map((cell) => (\n \n {flexRender(cell.column.columnDef.cell, cell.getContext())}\n \n ))}\n \n ))\n ) : (\n \n \n No results.\n \n \n )}\n \n
    \n {enablePagination && (\n
    \n table.previousPage()}\n disabled={!table.getCanPreviousPage()}\n >\n Previous\n \n table.nextPage()}\n disabled={!table.getCanNextPage()}\n >\n Next\n \n
    \n )}\n {enablePagination && showPaginationControls && }\n
    \n );\n}\n\nexport default DataTable;\n","import {\n Table,\n TableBody,\n TableCell,\n TableHead,\n TableHeader,\n TableRow,\n} from '@/components/shadcn-ui/table';\nimport { Canon } from '@sillsdev/scripture';\nimport { deepEqual, LanguageStrings, ScriptureReference } from 'platform-bible-utils';\nimport { useMemo } from 'react';\nimport { InventoryItemOccurrence } from './inventory-utils';\n\n/** Props for the OccurrencesTable component */\ntype OccurrencesTableProps = {\n /** Data that contains scriptures references and snippets of scripture */\n occurrenceData: InventoryItemOccurrence[];\n /** Callback function that is executed when the scripture reference is changed */\n setScriptureReference: (scriptureReference: ScriptureReference) => void;\n /**\n * Object with all localized strings that the OccurrencesTable needs to work well across multiple\n * languages\n */\n localizedStrings: LanguageStrings;\n};\n\n/**\n * Table that shows occurrences of specified inventory item(s). The first column shows the related\n * scripture reference. The second column shows the snippet of scripture that contains the specified\n * inventory item\n */\nfunction OccurrencesTable({\n occurrenceData,\n setScriptureReference,\n localizedStrings,\n}: OccurrencesTableProps) {\n const referenceHeaderText =\n localizedStrings['%webView_inventory_occurrences_table_header_reference%'];\n const occurrenceHeaderText =\n localizedStrings['%webView_inventory_occurrences_table_header_occurrence%'];\n\n const occurrences: InventoryItemOccurrence[] = useMemo(() => {\n const uniqueOccurrences: InventoryItemOccurrence[] = [];\n\n occurrenceData.forEach((occurrence) => {\n if (!uniqueOccurrences.some((uniqueOccurrence) => deepEqual(uniqueOccurrence, occurrence))) {\n uniqueOccurrences.push(occurrence);\n }\n });\n\n return uniqueOccurrences;\n }, [occurrenceData]);\n\n return (\n \n \n \n {referenceHeaderText}\n {occurrenceHeaderText}\n \n \n \n {occurrences.length > 0 &&\n occurrences.map((occurrence) => (\n {\n setScriptureReference(occurrence.reference);\n }}\n >\n {`${Canon.bookNumberToEnglishName(occurrence.reference.bookNum)} ${occurrence.reference.chapterNum}:${occurrence.reference.verseNum}`}\n {occurrence.text}\n \n ))}\n \n
    \n );\n}\n\nexport default OccurrencesTable;\n","import React from 'react';\nimport * as CheckboxPrimitive from '@radix-ui/react-checkbox';\nimport { Check } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Checkbox = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n \n \n));\nCheckbox.displayName = CheckboxPrimitive.Root.displayName;\n\nexport default Checkbox;\n","import { Canon } from '@sillsdev/scripture';\nimport { ScriptureReference } from 'platform-bible-utils';\n\n/* #region Types */\n\n/**\n * Status of items that appear in inventories. 'approved' and 'unapproved' items are defined in the\n * project's `Settings.xml`. All other items are defined as 'unknown'\n */\nexport type Status = 'approved' | 'unapproved' | 'unknown';\n\n/** Occurrence of item in inventory. Primarily used by table that shows occurrences */\nexport type InventoryItemOccurrence = {\n /** Reference to scripture where the item appears */\n reference: ScriptureReference;\n /** Snippet of scripture that contains the occurrence */\n text: string;\n};\n\n/** Data structure that contains all information on an item that is shown in an inventory */\nexport type InventoryTableData = {\n /**\n * The item (e.g. a character in the characters inventory, a marker in the marker inventory) In\n * most cases the array will only have one element. In case of additional items (e.g. the\n * preceding marker in the markers check), the primary item should be stored in the first index.\n * To show additional items in the inventory, make sure to configure the `additionalItemsLabels`\n * prop for the Inventory component\n */\n items: string[];\n /** The number of times this item occurs in the selected scope */\n count: number;\n /** The status of this item (see documentation for `Status` type for more information) */\n status: Status;\n /** Occurrences of this item in the scripture text for the selected scope */\n occurrences: InventoryItemOccurrence[];\n};\n\n/* #endregion */\n\n/* #region Functions */\n\n/**\n * Splits USFM string into shorter line-like segments\n *\n * @param text A single (likely very large) USFM string\n * @returns An array containing the input text, split into shorter segments\n */\nexport const getLinesFromUSFM = (text: string) => {\n // Splits on (CR)LF, CR, \\v, \\c and \\id\n return text.split(/(?:\\r?\\n|\\r)|(?=(?:\\\\(?:v|c|id)))/g);\n};\n\n/**\n * Extracts chapter or verse number from USFM strings that start with a \\c or \\v marker\n *\n * @param text USFM string that is expected to start with \\c or \\v marker\n * @returns Chapter or verse number if one is found. Else returns 0.\n */\nexport const getNumberFromUSFM = (text: string): number | undefined => {\n // Captures all digits that follow \\v or \\c markers followed by whitespace located at the start of a string\n const regex = /^\\\\[vc]\\s+(\\d+)/;\n const match = text.match(regex);\n\n if (match) {\n return +match[1];\n }\n return undefined;\n};\n\n/**\n * Gets book ID from USFM string that starts with the \\id marker, and returns book number for it\n *\n * @param text USFM string that is expected to start with \\id marker\n * @returns Book number corresponding to the \\id marker in the input text. Returns 0 if no marker is\n * found or the marker is not valid\n */\nexport const getBookNumFromId = (text: string): number => {\n // Captures all digits that follow an \\id marker followed by whitespace located at the start of a string\n const match = text.match(/^\\\\id\\s+([A-Za-z]+)/);\n if (match) {\n return Canon.bookIdToNumber(match[1]);\n }\n return 0;\n};\n\n/**\n * Gets the status for an item, typically used in the Inventory component\n *\n * @param item The item for which the status is being requested\n * @param approvedItems Array of approved items, typically as defined in `Settings.xml`\n * @param unapprovedItems Array of unapproved items, typically as defined in `Settings.xml`\n * @returns The status for the specified item\n */\nexport const getStatusForItem = (\n item: string,\n approvedItems: string[],\n unapprovedItems: string[],\n): Status => {\n if (unapprovedItems.includes(item)) return 'unapproved';\n if (approvedItems.includes(item)) return 'approved';\n return 'unknown';\n};\n\n/* #endregion */\n","import React from 'react';\nimport * as TogglePrimitive from '@radix-ui/react-toggle';\nimport { cva, type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst toggleVariants = cva(\n 'pr-twp tw-inline-flex tw-items-center tw-justify-center tw-rounded-md tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-colors hover:tw-bg-muted hover:tw-text-muted-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50 data-[state=on]:tw-bg-accent data-[state=on]:tw-text-accent-foreground',\n {\n variants: {\n variant: {\n default: 'tw-bg-transparent',\n outline:\n 'tw-border tw-border-input tw-bg-transparent hover:tw-bg-accent hover:tw-text-accent-foreground',\n },\n size: {\n default: 'tw-h-10 tw-px-3',\n sm: 'tw-h-9 tw-px-2.5',\n lg: 'tw-h-11 tw-px-5',\n },\n },\n defaultVariants: {\n variant: 'default',\n size: 'default',\n },\n },\n);\n\nconst Toggle = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef & VariantProps\n>(({ className, variant, size, ...props }, ref) => (\n \n));\n\nToggle.displayName = TogglePrimitive.Root.displayName;\n\nexport { Toggle, toggleVariants };\n","import React from 'react';\nimport * as ToggleGroupPrimitive from '@radix-ui/react-toggle-group';\nimport { type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { toggleVariants } from '@/components/shadcn-ui/toggle';\n\nconst ToggleGroupContext = React.createContext>({\n size: 'default',\n variant: 'default',\n});\n\nconst ToggleGroup = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef &\n VariantProps\n>(({ className, variant, size, children, ...props }, ref) => (\n \n \n {children}\n \n \n));\n\nToggleGroup.displayName = ToggleGroupPrimitive.Root.displayName;\n\nconst ToggleGroupItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef &\n VariantProps\n>(({ className, children, variant, size, ...props }, ref) => {\n const context = React.useContext(ToggleGroupContext);\n\n return (\n \n {children}\n \n );\n});\n\nToggleGroupItem.displayName = ToggleGroupPrimitive.Item.displayName;\n\nexport { ToggleGroup, ToggleGroupItem };\n","import { ColumnDef, SortDirection } from '@/components/advanced/data-table/data-table.component';\nimport { Button } from '@/components/shadcn-ui/button';\nimport { ToggleGroup, ToggleGroupItem } from '@/components/shadcn-ui/toggle-group';\nimport {\n ArrowDownIcon,\n ArrowUpDownIcon,\n ArrowUpIcon,\n CircleCheckIcon,\n CircleHelpIcon,\n CircleXIcon,\n} from 'lucide-react';\nimport { ReactNode } from 'react';\nimport { InventoryTableData, Status } from './inventory-utils';\n\n/**\n * Gets an icon that indicates the current sorting direction based on the provided input\n *\n * @param sortDirection Sorting direction. Can be ascending ('asc'), descending ('desc') or false (\n * i.e. not sorted)\n * @returns The appropriate sorting icon for the provided sorting direction\n */\nconst getSortingIcon = (sortDirection: false | SortDirection): ReactNode => {\n if (sortDirection === 'asc') {\n return ;\n }\n if (sortDirection === 'desc') {\n return ;\n }\n return ;\n};\n\n/**\n * Function that creates the item column for inventories\n *\n * @param itemLabel Localized label for the item column (e.g. 'Character', 'Repeated Word', etc.)\n * @returns Column that shows the inventory items. Should be used with the DataTable component\n */\nexport const inventoryItemColumn = (itemLabel: string): ColumnDef => {\n return {\n accessorKey: 'item',\n accessorFn: (row: InventoryTableData) => row.items[0],\n header: ({ column }) => (\n \n ),\n };\n};\n\n/**\n * Function that creates the additional item columns for inventories\n *\n * @param additionalItemLabel Localized label for the additional item column (e.g. 'Preceding\n * Marker')\n * @param additionalItemIndex Index that locates the desired item in the items array of the\n * inventory\n * @returns Column that shows additional inventory items. Should be used with the DataTable\n * component\n */\nexport const inventoryAdditionalItemColumn = (\n additionalItemLabel: string,\n additionalItemIndex: number,\n): ColumnDef => {\n return {\n accessorKey: `item${additionalItemIndex}`,\n accessorFn: (row: InventoryTableData) => row.items[additionalItemIndex],\n header: ({ column }) => (\n \n ),\n };\n};\n\n/**\n * Function that creates the count column for inventories. Should be used with the DataTable\n * component.\n *\n * @param itemLabel Localized label for the count column\n * @returns Column that shows the number of occurrences of the related inventory items\n */\nexport const inventoryCountColumn = (countLabel: string): ColumnDef => {\n return {\n accessorKey: 'count',\n header: ({ column }) => (\n
    \n \n
    \n ),\n cell: ({ row }) =>
    {row.getValue('count')}
    ,\n };\n};\n\n/**\n * Function that updates project settings when status for item(s) changes\n *\n * @param changedItems Array of items for which the status is being updated\n * @param newStatus The status that the items are being given\n * @param approvedItems Array of currently approved items\n * @param onApprovedItemsChange Callback function that stores the updated list of approved items\n * @param unapprovedItems Array of currently unapproved items\n * @param onUnapprovedItemsChange Callback function that stores the updated list of unapproved items\n */\nconst statusChangeHandler = (\n changedItems: string[],\n newStatus: Status,\n approvedItems: string[],\n onApprovedItemsChange: (items: string[]) => void,\n unapprovedItems: string[],\n onUnapprovedItemsChange: (items: string[]) => void,\n) => {\n let newApprovedItems: string[] = [...approvedItems];\n changedItems.forEach((item) => {\n if (newStatus === 'approved') {\n if (!newApprovedItems.includes(item)) {\n newApprovedItems.push(item);\n }\n } else {\n newApprovedItems = newApprovedItems.filter((validItem) => validItem !== item);\n }\n });\n onApprovedItemsChange(newApprovedItems);\n\n let newUnapprovedItems: string[] = [...unapprovedItems];\n changedItems.forEach((item) => {\n if (newStatus === 'unapproved') {\n if (!newUnapprovedItems.includes(item)) {\n newUnapprovedItems.push(item);\n }\n } else {\n newUnapprovedItems = newUnapprovedItems.filter((unapprovedItem) => unapprovedItem !== item);\n }\n });\n onUnapprovedItemsChange(newUnapprovedItems);\n};\n\n/**\n * Function that creates the status column for inventories. Should be used with the DataTable\n * component.\n *\n * @param statusLabel Localized label for the status column\n * @param approvedItems Array of approved items, typically as defined in `Settings.xml`\n * @param onApprovedItemsChange Callback function that stores the updated list of approved items\n * @param unapprovedItems Array of unapproved items, typically as defined in `Settings.xml`\n * @param onUnapprovedItemsChange Callback function that stores the updated list of unapproved items\n * @returns Column that shows the status buttons for the related inventory item. The button for the\n * current status of the item is selected\n */\nexport const inventoryStatusColumn = (\n statusLabel: string,\n approvedItems: string[],\n onApprovedItemsChange: (items: string[]) => void,\n unapprovedItems: string[],\n onUnapprovedItemsChange: (items: string[]) => void,\n): ColumnDef => {\n return {\n accessorKey: 'status',\n header: ({ column }) => {\n return (\n
    \n \n
    \n );\n },\n cell: ({ row }) => {\n const status: Status = row.getValue('status');\n const item: string = row.getValue('item');\n return (\n \n \n statusChangeHandler(\n [item],\n 'approved',\n approvedItems,\n onApprovedItemsChange,\n unapprovedItems,\n onUnapprovedItemsChange,\n )\n }\n value=\"approved\"\n >\n \n \n \n statusChangeHandler(\n [item],\n 'unapproved',\n approvedItems,\n onApprovedItemsChange,\n unapprovedItems,\n onUnapprovedItemsChange,\n )\n }\n value=\"unapproved\"\n >\n \n \n \n statusChangeHandler(\n [item],\n 'unknown',\n approvedItems,\n onApprovedItemsChange,\n unapprovedItems,\n onUnapprovedItemsChange,\n )\n }\n value=\"unknown\"\n >\n \n \n \n );\n },\n };\n};\n","import DataTable, {\n ColumnDef,\n RowContents,\n RowSelectionState,\n TableContents,\n} from '@/components/advanced/data-table/data-table.component';\nimport OccurrencesTable from '@/components/advanced/inventory/occurrences-table.component';\nimport Checkbox from '@/components/shadcn-ui/checkbox';\nimport { Input } from '@/components/shadcn-ui/input';\nimport { Label } from '@/components/shadcn-ui/label';\nimport {\n Select,\n SelectContent,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\nimport {\n deepEqual,\n LocalizedStringValue,\n ScriptureReference,\n substring,\n} from 'platform-bible-utils';\nimport { useEffect, useMemo, useState } from 'react';\nimport {\n getBookNumFromId,\n getLinesFromUSFM,\n getNumberFromUSFM,\n getStatusForItem,\n InventoryItemOccurrence,\n InventoryTableData,\n Status,\n} from './inventory-utils';\nimport { inventoryAdditionalItemColumn } from './inventory-columns';\n\n/**\n * Object containing all keys used for localization in this component. If you're using this\n * component in an extension, you can pass it into the useLocalizedStrings hook to easily obtain the\n * localized strings and pass them into the localizedStrings prop of this component\n */\nexport const INVENTORY_STRING_KEYS = Object.freeze([\n '%webView_inventory_all%',\n '%webView_inventory_approved%',\n '%webView_inventory_unapproved%',\n '%webView_inventory_unknown%',\n '%webView_inventory_scope_currentBook%',\n '%webView_inventory_scope_chapter%',\n '%webView_inventory_scope_verse%',\n '%webView_inventory_filter_text%',\n '%webView_inventory_show_additional_items%',\n '%webView_inventory_occurrences_table_header_reference%',\n '%webView_inventory_occurrences_table_header_occurrence%',\n] as const);\n\nexport type InventoryLocalizedStrings = {\n [localizedInventoryKey in (typeof INVENTORY_STRING_KEYS)[number]]?: LocalizedStringValue;\n};\n\n/** Scope of scripture that the inventory can operate on */\nexport type Scope = 'book' | 'chapter' | 'verse';\n\n/** Status values that the status filter can select from */\ntype StatusFilter = Status | 'all';\n\n/** Text labels for the inventory columns and the control components of additional inventory items */\ntype AdditionalItemsLabels = {\n checkboxText?: string;\n tableHeaders?: string[];\n};\n\n/**\n * Filters data that is shown in the DataTable section of the Inventory\n *\n * @param itemData All inventory items and their related information\n * @param statusFilter Allows filtering by status (i.e. show all items, or only items that are\n * 'approved', 'unapproved' or 'unknown')\n * @param textFilter Allows filtering by text. All items that include the filter text will be\n * selected.\n * @returns Array of items and their related information that are matched by the specified filters\n */\nconst filterItemData = (\n itemData: InventoryTableData[],\n statusFilter: StatusFilter,\n textFilter: string,\n): InventoryTableData[] => {\n let filteredItemData: InventoryTableData[] = itemData;\n\n if (statusFilter !== 'all') {\n filteredItemData = filteredItemData.filter(\n (item) =>\n (statusFilter === 'approved' && item.status === 'approved') ||\n (statusFilter === 'unapproved' && item.status === 'unapproved') ||\n (statusFilter === 'unknown' && item.status === 'unknown'),\n );\n }\n\n if (textFilter !== '')\n filteredItemData = filteredItemData.filter((item) => item.items[0].includes(textFilter));\n\n return filteredItemData;\n};\n\n/**\n * Turns array of strings into array of inventory items, along with their count and status\n *\n * @param text The source scripture text that is searched for inventory items\n * @param scriptureRef The scripture reference that the application is currently set to\n * @param approvedItems Array of approved items, typically as defined in `Settings.xml`\n * @param unapprovedItems Array of unapproved items, typically as defined in `Settings.xml`\n * @param itemRegex Regular expression that describes what items this Inventory should extract from\n * the provided scripture text\n * @returns Array of inventory items, along with their count and status\n */\nconst createTableData = (\n text: string | undefined,\n scriptureRef: ScriptureReference,\n approvedItems: string[],\n unapprovedItems: string[],\n itemRegex: RegExp,\n): InventoryTableData[] => {\n if (!text) return [];\n\n const tableData: InventoryTableData[] = [];\n\n let currentBook: number | undefined = scriptureRef.bookNum;\n let currentChapter: number | undefined = scriptureRef.chapterNum;\n let currentVerse: number | undefined = scriptureRef.verseNum;\n\n const lines = getLinesFromUSFM(text);\n\n lines.forEach((line: string) => {\n if (line.startsWith('\\\\id')) {\n currentBook = getBookNumFromId(line);\n currentChapter = 0;\n currentVerse = 0;\n }\n if (line.startsWith('\\\\c')) {\n currentChapter = getNumberFromUSFM(line);\n currentVerse = 0;\n }\n if (line.startsWith('\\\\v')) {\n currentVerse = getNumberFromUSFM(line);\n if (currentChapter === 0) {\n currentChapter = scriptureRef.chapterNum;\n }\n }\n\n let match: RegExpExecArray | undefined = itemRegex.exec(line) ?? undefined;\n while (match) {\n const items: string[] = [];\n match.forEach((item) => items.push(item));\n const itemIndex = match.index;\n const existingItem = tableData.find((tableEntry) => deepEqual(tableEntry.items, items));\n const newReference: InventoryItemOccurrence = {\n reference: {\n bookNum: currentBook !== undefined ? currentBook : -1,\n chapterNum: currentChapter !== undefined ? currentChapter : -1,\n verseNum: currentVerse !== undefined ? currentVerse : -1,\n },\n text: substring(line, Math.max(0, itemIndex - 25), Math.min(itemIndex + 25, line.length)),\n };\n if (existingItem) {\n existingItem.count += 1;\n existingItem.occurrences.push(newReference);\n } else {\n const newItem: InventoryTableData = {\n items,\n count: 1,\n status: getStatusForItem(items[0], approvedItems, unapprovedItems),\n occurrences: [newReference],\n };\n tableData.push(newItem);\n }\n\n match = itemRegex.exec(line) ?? undefined;\n }\n });\n\n return tableData;\n};\n\n/**\n * Gets the localized value for the provided key\n *\n * @param strings Object containing localized string\n * @param key Key for a localized string\n * @returns The localized value for the provided key, if available. Returns the key if no localized\n * value is available\n */\nconst localizeString = (\n strings: InventoryLocalizedStrings,\n key: keyof InventoryLocalizedStrings,\n) => {\n return strings[key] ?? key;\n};\n\n/** Props for the Inventory component */\ntype InventoryProps = {\n /** The scripture reference that the application is currently set to */\n scriptureReference: ScriptureReference;\n /** Callback function that is executed when the scripture reference is changed */\n setScriptureReference: (scriptureReference: ScriptureReference) => void;\n /**\n * Object with all localized strings that the Inventory needs to work well across multiple\n * languages. When using this component with Platform.Bible, you can import\n * `INVENTORY_STRING_KEYS` from this library, pass it in to the Platform's localization hook, and\n * pass the localized keys that are returned by the hook into this prop.\n */\n localizedStrings: InventoryLocalizedStrings;\n /**\n * The logic that finds the desired items in the source text. This can either be a Regular\n * expression that captures one or multiple items (preferred), or a custom function that builds\n * and return an InventoryDataTable[] manually. Note: In case the logic captures more than one\n * item (i.e. InventoryTableData.items has a length greater than 1), you must provide text labels\n * for the related columns and control elements to show by setting the `additionalItemsLabels`\n * prop\n */\n extractItems:\n | RegExp\n | ((\n text: string | undefined,\n scriptureRef: ScriptureReference,\n approvedItems: string[],\n unapprovedItems: string[],\n ) => InventoryTableData[]);\n /**\n * Text labels for control elements and additional column headers in case your Inventory has more\n * than one item to show (e.g. The 'Preceding Marker' in the Markers Inventory)\n */\n additionalItemsLabels?: AdditionalItemsLabels;\n /** Array of approved items, typically as defined in `Settings.xml` */\n approvedItems: string[];\n /** Array of unapproved items, typically as defined in `Settings.xml` */\n unapprovedItems: string[];\n /** The source scripture text that is searched for in inventory items */\n text: string | undefined;\n /** Scope of scripture that the inventory will operate on */\n scope: Scope;\n /** Callback function that is executed when the scope is changed from the Inventory */\n onScopeChange: (scope: Scope) => void;\n /**\n * Column definitions for the Inventory data table. The most commonly used column definitions are\n * pre-configured for your convenience and can be imported (e.g. inventoryItemColumn,\n * inventoryAdditionalItemColumn inventoryCountColumn, and inventoryStatusColumn). If you need any\n * other columns you can add these yourself\n */\n columns: ColumnDef[];\n};\n\n/** Inventory component that is used to view and control the status of provided project settings */\nexport default function Inventory({\n scriptureReference,\n setScriptureReference,\n localizedStrings,\n extractItems,\n additionalItemsLabels,\n approvedItems,\n unapprovedItems,\n text,\n scope,\n onScopeChange,\n columns,\n}: InventoryProps) {\n const allItemsText = localizeString(localizedStrings, '%webView_inventory_all%');\n const approvedItemsText = localizeString(localizedStrings, '%webView_inventory_approved%');\n const unapprovedItemsText = localizeString(localizedStrings, '%webView_inventory_unapproved%');\n const unknownItemsText = localizeString(localizedStrings, '%webView_inventory_unknown%');\n const scopeBookText = localizeString(localizedStrings, '%webView_inventory_scope_currentBook%');\n const scopeChapterText = localizeString(localizedStrings, '%webView_inventory_scope_chapter%');\n const scopeVerseText = localizeString(localizedStrings, '%webView_inventory_scope_verse%');\n const filterText = localizeString(localizedStrings, '%webView_inventory_filter_text%');\n const showAdditionalItemsText = localizeString(\n localizedStrings,\n '%webView_inventory_show_additional_items%',\n );\n\n const [showAdditionalItems, setShowAdditionalItems] = useState(false);\n const [statusFilter, setStatusFilter] = useState('all');\n const [textFilter, setTextFilter] = useState('');\n const [selectedItem, setSelectedItem] = useState([]);\n\n const tableData: InventoryTableData[] = useMemo(() => {\n if (!text) return [];\n if (extractItems instanceof RegExp)\n return createTableData(\n text,\n scriptureReference,\n approvedItems,\n unapprovedItems,\n extractItems,\n );\n return extractItems(text, scriptureReference, approvedItems, unapprovedItems);\n }, [text, extractItems, scriptureReference, approvedItems, unapprovedItems]);\n\n const reducedTableData: InventoryTableData[] = useMemo(() => {\n if (showAdditionalItems) return tableData;\n\n const newTableData: InventoryTableData[] = [];\n\n tableData.forEach((tableEntry) => {\n const firstItem = tableEntry.items[0];\n\n const existingEntry = newTableData.find(\n (newTableEntry) => newTableEntry.items[0] === firstItem,\n );\n\n if (existingEntry) {\n existingEntry.count += tableEntry.count;\n existingEntry.occurrences = existingEntry.occurrences.concat(tableEntry.occurrences);\n } else {\n newTableData.push({\n items: [firstItem],\n count: tableEntry.count,\n occurrences: tableEntry.occurrences,\n status: tableEntry.status,\n });\n }\n });\n\n return newTableData;\n }, [showAdditionalItems, tableData]);\n\n const filteredTableData: InventoryTableData[] = useMemo(() => {\n return filterItemData(reducedTableData, statusFilter, textFilter);\n }, [reducedTableData, statusFilter, textFilter]);\n\n const allColumns: ColumnDef[] = useMemo(() => {\n if (!showAdditionalItems) return columns;\n\n const numberOfAdditionalItems = additionalItemsLabels?.tableHeaders?.length;\n if (!numberOfAdditionalItems) return columns;\n\n const additionalColumns: ColumnDef[] = [];\n\n for (let index = 0; index < numberOfAdditionalItems; index++) {\n additionalColumns.push(\n inventoryAdditionalItemColumn(\n additionalItemsLabels?.tableHeaders?.[index] || 'Additional Item',\n index + 1,\n ),\n );\n }\n\n return [...additionalColumns, ...columns];\n }, [additionalItemsLabels?.tableHeaders, columns, showAdditionalItems]);\n\n useEffect(() => {\n setSelectedItem([]);\n }, [filteredTableData]);\n\n const rowClickHandler = (\n row: RowContents,\n table: TableContents,\n ) => {\n table.setRowSelection(() => {\n const newSelection: RowSelectionState = {};\n newSelection[row.index] = true;\n return newSelection;\n });\n\n setSelectedItem(row.original.items);\n };\n\n const handleScopeChange = (value: string) => {\n if (value === 'book' || value === 'chapter' || value === 'verse') {\n onScopeChange(value);\n } else {\n throw new Error(`Invalid scope value: ${value}`);\n }\n };\n\n const handleStatusFilterChange = (value: string) => {\n if (value === 'all' || value === 'approved' || value === 'unapproved' || value === 'unknown') {\n setStatusFilter(value);\n } else {\n throw new Error(`Invalid status filter value: ${value}`);\n }\n };\n\n const occurrenceData: InventoryItemOccurrence[] = useMemo(() => {\n if (reducedTableData.length === 0 || selectedItem.length === 0) return [];\n const occurrence = reducedTableData.filter((tableEntry: InventoryTableData) => {\n return deepEqual(\n showAdditionalItems ? tableEntry.items : [tableEntry.items[0]],\n selectedItem,\n );\n });\n if (occurrence.length > 1) throw new Error('Selected item is not unique');\n return occurrence[0].occurrences;\n }, [selectedItem, showAdditionalItems, reducedTableData]);\n\n return (\n
    \n
    \n handleStatusFilterChange(value)}\n defaultValue={statusFilter}\n >\n \n \n \n \n {allItemsText}\n {approvedItemsText}\n {unapprovedItemsText}\n {unknownItemsText}\n \n \n \n {\n setTextFilter(event.target.value);\n }}\n />\n {additionalItemsLabels && (\n
    \n {\n setSelectedItem([]);\n setShowAdditionalItems(checked);\n }}\n />\n \n
    \n )}\n
    \n
    \n \n
    \n {occurrenceData.length > 0 && (\n
    \n \n
    \n )}\n
    \n );\n}\n","import { Input } from '@/components/shadcn-ui/input';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { useState } from 'react';\n\nexport type SearchBarProps = {\n className?: string;\n /**\n * Callback fired to handle the search query when button pressed\n *\n * @param searchQuery\n */\n onSearch: (searchQuery: string) => void;\n\n /** Optional string that appears in the search bar without a search string */\n placeholder?: string;\n\n /** Optional boolean to set the input base to full width */\n isFullWidth?: boolean;\n};\n\nexport default function SearchBar({\n className,\n onSearch,\n placeholder,\n isFullWidth,\n}: SearchBarProps) {\n const [searchQuery, setSearchQuery] = useState('');\n\n const handleInputChange = (searchString: string) => {\n setSearchQuery(searchString);\n onSearch(searchString);\n };\n\n return (\n handleInputChange(e.target.value)}\n />\n );\n}\n","// adapted from: https://github.com/shadcn-ui/ui/discussions/752\n\n'use client';\n\nimport { TabsContentProps, TabsListProps, TabsTriggerProps } from '@/components/shadcn-ui/tabs';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport * as TabsPrimitive from '@radix-ui/react-tabs';\nimport React from 'react';\n\nexport type VerticalTabsProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport type LeftTabsTriggerProps = TabsTriggerProps & {\n value: string;\n ref?: React.Ref;\n};\n\nexport const VerticalTabs = React.forwardRef<\n React.ElementRef,\n VerticalTabsProps\n>(({ className, ...props }, ref) => (\n \n));\n\nVerticalTabs.displayName = TabsPrimitive.List.displayName;\n\nexport const VerticalTabsList = React.forwardRef<\n React.ElementRef,\n TabsListProps\n>(({ className, ...props }, ref) => (\n \n));\nVerticalTabsList.displayName = TabsPrimitive.List.displayName;\n\nexport const VerticalTabsTrigger = React.forwardRef<\n React.ElementRef,\n LeftTabsTriggerProps\n>(({ className, ...props }, ref) => (\n \n));\n\nexport const VerticalTabsContent = React.forwardRef<\n React.ElementRef,\n TabsContentProps\n>(({ className, ...props }, ref) => (\n \n));\nVerticalTabsContent.displayName = TabsPrimitive.Content.displayName;\n","import SearchBar from '@/components/basics/search-bar.component';\nimport {\n VerticalTabs,\n VerticalTabsContent,\n VerticalTabsList,\n VerticalTabsTrigger,\n} from '@/components/basics/tabs-vertical';\nimport { ReactNode } from 'react';\n\nexport type TabKeyValueContent = {\n key: string;\n value: string;\n content: ReactNode;\n};\n\nexport type TabNavigationContentSearchProps = {\n /** List of values and keys for each tab this component should provide */\n tabList: TabKeyValueContent[];\n\n /** Handler to run when the value of the search bar changes */\n onSearch: (searchQuery: string) => void;\n\n /** Optional placeholder for the search bar */\n searchPlaceholder?: string;\n\n /** Optional title to include in the header */\n headerTitle?: string;\n\n /** Optional flag to make the search bar appear full width */\n isSearchBarFullWidth?: boolean;\n\n /** Text direction ltr or rtl */\n direction?: 'ltr' | 'rtl';\n};\n\nexport default function TabNavigationContentSearch({\n tabList,\n onSearch,\n searchPlaceholder,\n headerTitle,\n isSearchBarFullWidth = false,\n direction = 'ltr',\n}: TabNavigationContentSearchProps) {\n return (\n
    \n
    \n {headerTitle ?

    {headerTitle}

    : ''}\n \n
    \n \n \n {tabList.map((tab) => (\n \n {tab.value}\n \n ))}\n \n {tabList.map((tab) => (\n \n {tab.content}\n \n ))}\n \n
    \n );\n}\n","import React from 'react';\nimport * as SeparatorPrimitive from '@radix-ui/react-separator';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Separator = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, orientation = 'horizontal', decorative = true, ...props }, ref) => (\n \n));\nSeparator.displayName = SeparatorPrimitive.Root.displayName;\n\nexport { Separator };\n","'use client';\n\nimport * as React from 'react';\nimport * as SheetPrimitive from '@radix-ui/react-dialog';\nimport { cva, type VariantProps } from 'class-variance-authority';\nimport { X } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Sheet = SheetPrimitive.Root;\n\nconst SheetTrigger = SheetPrimitive.Trigger;\n\nconst SheetClose = SheetPrimitive.Close;\n\nconst SheetPortal = SheetPrimitive.Portal;\n\nconst SheetOverlay = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSheetOverlay.displayName = SheetPrimitive.Overlay.displayName;\n\nconst sheetVariants = cva(\n 'pr-twp tw-fixed tw-z-50 tw-gap-4 tw-bg-background tw-p-6 tw-shadow-lg tw-transition tw-ease-in-out data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-duration-300 data-[state=open]:tw-duration-500',\n {\n variants: {\n side: {\n top: 'tw-inset-x-0 tw-top-0 tw-border-b data-[state=closed]:tw-slide-out-to-top data-[state=open]:tw-slide-in-from-top',\n bottom:\n 'tw-inset-x-0 tw-bottom-0 tw-border-t data-[state=closed]:tw-slide-out-to-bottom data-[state=open]:tw-slide-in-from-bottom',\n left: 'tw-inset-y-0 tw-left-0 tw-h-full tw-w-3/4 tw-border-r data-[state=closed]:tw-slide-out-to-left data-[state=open]:tw-slide-in-from-left sm:tw-max-w-sm',\n right:\n 'tw-inset-y-0 tw-right-0 tw-h-full tw-w-3/4 tw- tw-border-l data-[state=closed]:tw-slide-out-to-right data-[state=open]:tw-slide-in-from-right sm:tw-max-w-sm',\n },\n },\n defaultVariants: {\n side: 'right',\n },\n },\n);\n\ninterface SheetContentProps\n extends React.ComponentPropsWithoutRef,\n VariantProps {}\n\nconst SheetContent = React.forwardRef<\n React.ElementRef,\n SheetContentProps\n>(({ side = 'right', className, children, ...props }, ref) => (\n \n \n \n {children}\n \n \n Close\n \n \n \n));\nSheetContent.displayName = SheetPrimitive.Content.displayName;\n\nfunction SheetHeader({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nSheetHeader.displayName = 'SheetHeader';\n\nfunction SheetFooter({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nSheetFooter.displayName = 'SheetFooter';\n\nconst SheetTitle = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSheetTitle.displayName = SheetPrimitive.Title.displayName;\n\nconst SheetDescription = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSheetDescription.displayName = SheetPrimitive.Description.displayName;\n\nexport {\n Sheet,\n SheetPortal,\n SheetOverlay,\n SheetTrigger,\n SheetClose,\n SheetContent,\n SheetHeader,\n SheetFooter,\n SheetTitle,\n SheetDescription,\n};\n","import React from 'react';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nfunction Skeleton({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\n\nexport { Skeleton };\n","import React from 'react';\nimport * as TooltipPrimitive from '@radix-ui/react-tooltip';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst TooltipProvider = TooltipPrimitive.Provider;\n\nconst Tooltip = TooltipPrimitive.Root;\n\nconst TooltipTrigger = TooltipPrimitive.Trigger;\n\nconst TooltipContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, sideOffset = 4, ...props }, ref) => (\n \n));\nTooltipContent.displayName = TooltipPrimitive.Content.displayName;\n\nexport { Tooltip, TooltipTrigger, TooltipContent, TooltipProvider };\n","import * as React from 'react';\n\nconst MOBILE_BREAKPOINT = 768;\n\nexport default function useIsMobile() {\n const [isMobile, setIsMobile] = React.useState(undefined);\n\n React.useEffect(() => {\n const mql = window.matchMedia(`(max-width: ${MOBILE_BREAKPOINT - 1}px)`);\n const onChange = () => {\n setIsMobile(window.innerWidth < MOBILE_BREAKPOINT);\n };\n mql.addEventListener('change', onChange);\n setIsMobile(window.innerWidth < MOBILE_BREAKPOINT);\n return () => mql.removeEventListener('change', onChange);\n }, []);\n\n return !!isMobile;\n}\n","import React from 'react';\nimport { Slot } from '@radix-ui/react-slot';\nimport { VariantProps, cva } from 'class-variance-authority';\nimport { PanelLeft } from 'lucide-react';\n\nimport { Button } from '@/components/shadcn-ui/button';\nimport { Input } from '@/components/shadcn-ui/input';\nimport { Separator } from '@/components/shadcn-ui/separator';\nimport { Sheet, SheetContent } from '@/components/shadcn-ui/sheet';\nimport { Skeleton } from '@/components/shadcn-ui/skeleton';\nimport {\n Tooltip,\n TooltipContent,\n TooltipProvider,\n TooltipTrigger,\n} from '@/components/shadcn-ui/tooltip';\nimport useIsMobile from '@/components/hooks/use-mobile';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst SIDEBAR_COOKIE_NAME = 'sidebar:state';\nconst SIDEBAR_COOKIE_MAX_AGE = 60 * 60 * 24 * 7;\nconst SIDEBAR_WIDTH = '16rem';\nconst SIDEBAR_WIDTH_MOBILE = '18rem';\nconst SIDEBAR_WIDTH_ICON = '3rem';\nconst SIDEBAR_KEYBOARD_SHORTCUT = 'b';\n\ntype SidebarContextProps = {\n state: 'expanded' | 'collapsed';\n open: boolean;\n setOpen: (open: boolean) => void;\n openMobile: boolean;\n setOpenMobile: (open: boolean) => void;\n isMobile: boolean;\n toggleSidebar: () => void;\n};\n\nconst SidebarContext = React.createContext(undefined);\n\nfunction useSidebar() {\n const context = React.useContext(SidebarContext);\n if (!context) {\n throw new Error('useSidebar must be used within a SidebarProvider.');\n }\n\n return context;\n}\n\nconst SidebarProvider = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & {\n defaultOpen?: boolean;\n open?: boolean;\n onOpenChange?: (open: boolean) => void;\n }\n>(\n (\n {\n defaultOpen = true,\n open: openProp,\n onOpenChange: setOpenProp,\n className,\n style,\n children,\n ...props\n },\n ref,\n ) => {\n const isMobile = useIsMobile();\n const [openMobile, setOpenMobile] = React.useState(false);\n\n // This is the internal state of the sidebar.\n // We use openProp and setOpenProp for control from outside the component.\n const [_open, _setOpen] = React.useState(defaultOpen);\n const isOpen = openProp ?? _open;\n const setOpen = React.useCallback(\n (value: boolean | ((value: boolean) => boolean)) => {\n const openState = typeof value === 'function' ? value(isOpen) : value;\n if (setOpenProp) {\n setOpenProp(openState);\n } else {\n _setOpen(openState);\n }\n\n // This sets the cookie to keep the sidebar state.\n document.cookie = `${SIDEBAR_COOKIE_NAME}=${openState}; path=/; max-age=${SIDEBAR_COOKIE_MAX_AGE}`;\n },\n [setOpenProp, isOpen],\n );\n\n // Helper to toggle the sidebar.\n const toggleSidebar = React.useCallback(() => {\n return isMobile ? setOpenMobile((open) => !open) : setOpen((open) => !open);\n }, [isMobile, setOpen, setOpenMobile]);\n\n // Adds a keyboard shortcut to toggle the sidebar.\n React.useEffect(() => {\n const handleKeyDown = (event: KeyboardEvent) => {\n if (event.key === SIDEBAR_KEYBOARD_SHORTCUT && (event.metaKey || event.ctrlKey)) {\n event.preventDefault();\n toggleSidebar();\n }\n };\n\n window.addEventListener('keydown', handleKeyDown);\n return () => window.removeEventListener('keydown', handleKeyDown);\n }, [toggleSidebar]);\n\n // We add a state so that we can do data-state=\"expanded\" or \"collapsed\".\n // This makes it easier to style the sidebar with Tailwind classes.\n const state = isOpen ? 'expanded' : 'collapsed';\n\n const contextValue = React.useMemo(\n () => ({\n state,\n open: isOpen,\n setOpen,\n isMobile,\n openMobile,\n setOpenMobile,\n toggleSidebar,\n }),\n [state, isOpen, setOpen, isMobile, openMobile, setOpenMobile, toggleSidebar],\n );\n\n return (\n \n \n \n {children}\n
    \n \n \n );\n },\n);\nSidebarProvider.displayName = 'SidebarProvider';\n\nconst Sidebar = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & {\n side?: 'left' | 'right';\n variant?: 'sidebar' | 'floating' | 'inset';\n collapsible?: 'offcanvas' | 'icon' | 'none';\n }\n>(\n (\n {\n side = 'left',\n variant = 'sidebar',\n collapsible = 'offcanvas',\n className,\n children,\n ...props\n },\n ref,\n ) => {\n const { isMobile, state, openMobile, setOpenMobile } = useSidebar();\n\n if (collapsible === 'none') {\n return (\n \n {children}\n
    \n );\n }\n\n if (isMobile) {\n return (\n \n button]:tw-hidden\"\n style={\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n {\n '--sidebar-width': SIDEBAR_WIDTH_MOBILE,\n } as React.CSSProperties\n }\n side={side}\n >\n
    {children}
    \n \n
    \n );\n }\n\n return (\n \n {/* This is what handles the sidebar gap on desktop */}\n \n \n \n {children}\n
    \n
    \n
    \n );\n },\n);\nSidebar.displayName = 'Sidebar';\n\nconst SidebarTrigger = React.forwardRef<\n React.ElementRef,\n React.ComponentProps\n>(({ className, onClick, ...props }, ref) => {\n const { toggleSidebar } = useSidebar();\n\n return (\n {\n onClick?.(event);\n toggleSidebar();\n }}\n {...props}\n >\n \n Toggle Sidebar\n \n );\n});\nSidebarTrigger.displayName = 'SidebarTrigger';\n\nconst SidebarRail = React.forwardRef>(\n ({ className, ...props }, ref) => {\n const { toggleSidebar } = useSidebar();\n\n return (\n \n );\n },\n);\nSidebarRail.displayName = 'SidebarRail';\n\nconst SidebarInset = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarInset.displayName = 'SidebarInset';\n\nconst SidebarInput = React.forwardRef<\n React.ElementRef,\n React.ComponentProps\n>(({ className, ...props }, ref) => {\n return (\n \n );\n});\nSidebarInput.displayName = 'SidebarInput';\n\nconst SidebarHeader = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarHeader.displayName = 'SidebarHeader';\n\nconst SidebarFooter = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarFooter.displayName = 'SidebarFooter';\n\nconst SidebarSeparator = React.forwardRef<\n React.ElementRef,\n React.ComponentProps\n>(({ className, ...props }, ref) => {\n return (\n \n );\n});\nSidebarSeparator.displayName = 'SidebarSeparator';\n\nconst SidebarContent = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarContent.displayName = 'SidebarContent';\n\nconst SidebarGroup = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarGroup.displayName = 'SidebarGroup';\n\nconst SidebarGroupLabel = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & { asChild?: boolean }\n>(({ className, asChild = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'div';\n\n return (\n svg]:tw-size-4 [&>svg]:tw-shrink-0',\n 'group-data-[collapsible=icon]:tw--mt-8 group-data-[collapsible=icon]:tw-opacity-0',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarGroupLabel.displayName = 'SidebarGroupLabel';\n\nconst SidebarGroupAction = React.forwardRef<\n HTMLButtonElement,\n React.ComponentProps<'button'> & { asChild?: boolean }\n>(({ className, asChild = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'button';\n\n return (\n svg]:tw-size-4 [&>svg]:tw-shrink-0',\n // Increases the hit area of the button on mobile.\n 'after:tw-absolute after:tw--inset-2 after:md:tw-hidden',\n 'group-data-[collapsible=icon]:tw-hidden',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarGroupAction.displayName = 'SidebarGroupAction';\n\nconst SidebarGroupContent = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarGroupContent.displayName = 'SidebarGroupContent';\n\nconst SidebarMenu = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenu.displayName = 'SidebarMenu';\n\nconst SidebarMenuItem = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenuItem.displayName = 'SidebarMenuItem';\n\nconst sidebarMenuButtonVariants = cva(\n // Removed data-[active=true]:tw-bg-sidebar-accent\n 'tw-peer/menu-button tw-flex tw-w-full tw-items-center tw-gap-2 tw-overflow-hidden tw-rounded-md tw-p-2 tw-text-left tw-text-sm tw-outline-none tw-ring-sidebar-ring tw-transition-[width,height,padding] hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground focus-visible:tw-ring-2 active:tw-bg-sidebar-accent active:tw-text-sidebar-accent-foreground disabled:tw-pointer-events-none disabled:tw-opacity-50 tw-group-has-[[data-sidebar=menu-action]]/menu-item:pr-8 aria-disabled:tw-pointer-events-none aria-disabled:tw-opacity-50 data-[active=true]:tw-font-medium data-[active=true]:tw-text-sidebar-accent-foreground data-[state=open]:hover:tw-bg-sidebar-accent data-[state=open]:hover:tw-text-sidebar-accent-foreground group-data-[collapsible=icon]:tw-!size-8 group-data-[collapsible=icon]:tw-!p-2 [&>span:last-child]:tw-truncate [&>svg]:tw-size-4 [&>svg]:tw-shrink-0',\n {\n variants: {\n variant: {\n default: 'hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground',\n outline:\n 'tw-bg-background tw-shadow-[0_0_0_1px_hsl(var(--sidebar-border))] hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground hover:tw-shadow-[0_0_0_1px_hsl(var(--sidebar-accent))]',\n },\n size: {\n default: 'tw-h-8 tw-text-sm',\n sm: 'tw-h-7 tw-text-xs',\n lg: 'tw-h-12 tw-text-sm group-data-[collapsible=icon]:tw-!p-0',\n },\n },\n defaultVariants: {\n variant: 'default',\n size: 'default',\n },\n },\n);\n\nconst SidebarMenuButton = React.forwardRef<\n HTMLButtonElement,\n React.ComponentProps<'button'> & {\n asChild?: boolean;\n isActive?: boolean;\n tooltip?: string | React.ComponentProps;\n } & VariantProps\n>(\n (\n {\n asChild = false,\n isActive = false,\n variant = 'default',\n size = 'default',\n tooltip,\n className,\n ...props\n },\n ref,\n ) => {\n const Comp = asChild ? Slot : 'button';\n const { isMobile, state } = useSidebar();\n\n const button = (\n \n );\n\n if (!tooltip) {\n return button;\n }\n\n if (typeof tooltip === 'string') {\n // eslint-disable-next-line no-param-reassign\n tooltip = {\n children: tooltip,\n };\n }\n\n return (\n \n {button}\n \n );\n },\n);\nSidebarMenuButton.displayName = 'SidebarMenuButton';\n\nconst SidebarMenuAction = React.forwardRef<\n HTMLButtonElement,\n React.ComponentProps<'button'> & {\n asChild?: boolean;\n showOnHover?: boolean;\n }\n>(({ className, asChild = false, showOnHover = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'button';\n\n return (\n svg]:tw-size-4 [&>svg]:tw-shrink-0',\n // Increases the hit area of the button on mobile.\n 'after:tw-absolute after:tw--inset-2 after:md:tw-hidden',\n 'tw-peer-data-[size=sm]/menu-button:top-1',\n 'tw-peer-data-[size=default]/menu-button:top-1.5',\n 'tw-peer-data-[size=lg]/menu-button:top-2.5',\n 'group-data-[collapsible=icon]:tw-hidden',\n showOnHover &&\n 'tw-group-focus-within/menu-item:opacity-100 tw-group-hover/menu-item:opacity-100 tw-peer-data-[active=true]/menu-button:text-sidebar-accent-foreground data-[state=open]:tw-opacity-100 md:tw-opacity-0',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarMenuAction.displayName = 'SidebarMenuAction';\n\nconst SidebarMenuBadge = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenuBadge.displayName = 'SidebarMenuBadge';\n\nconst SidebarMenuSkeleton = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & {\n showIcon?: boolean;\n }\n>(({ className, showIcon = false, ...props }, ref) => {\n // Random width between 50 to 90%.\n const width = React.useMemo(() => {\n return `${Math.floor(Math.random() * 40) + 50}%`;\n }, []);\n\n return (\n \n {showIcon && (\n \n )}\n \n
    \n );\n});\nSidebarMenuSkeleton.displayName = 'SidebarMenuSkeleton';\n\nconst SidebarMenuSub = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenuSub.displayName = 'SidebarMenuSub';\n\nconst SidebarMenuSubItem = React.forwardRef>(\n ({ ...props }, ref) =>
  • ,\n);\nSidebarMenuSubItem.displayName = 'SidebarMenuSubItem';\n\nconst SidebarMenuSubButton = React.forwardRef<\n HTMLAnchorElement,\n React.ComponentProps<'a'> & {\n asChild?: boolean;\n size?: 'sm' | 'md';\n isActive?: boolean;\n }\n>(({ asChild = false, size = 'md', isActive, className, ...props }, ref) => {\n const Comp = asChild ? Slot : 'a';\n\n return (\n span:last-child]:tw-truncate [&>svg]:tw-size-4 [&>svg]:tw-shrink-0 [&>svg]:tw-text-sidebar-accent-foreground',\n 'data-[active=true]:tw-bg-sidebar-accent data-[active=true]:tw-text-sidebar-accent-foreground',\n size === 'sm' && 'tw-text-xs',\n size === 'md' && 'tw-text-sm',\n 'group-data-[collapsible=icon]:tw-hidden',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarMenuSubButton.displayName = 'SidebarMenuSubButton';\n\nexport {\n Sidebar,\n SidebarContent,\n SidebarFooter,\n SidebarGroup,\n SidebarGroupAction,\n SidebarGroupContent,\n SidebarGroupLabel,\n SidebarHeader,\n SidebarInput,\n SidebarInset,\n SidebarMenu,\n SidebarMenuAction,\n SidebarMenuBadge,\n SidebarMenuButton,\n SidebarMenuItem,\n SidebarMenuSkeleton,\n SidebarMenuSub,\n SidebarMenuSubButton,\n SidebarMenuSubItem,\n SidebarProvider,\n SidebarRail,\n SidebarSeparator,\n SidebarTrigger,\n useSidebar,\n};\n","import ComboBox, { ComboBoxOption } from '@/components/basics/combo-box.component';\nimport {\n Sidebar,\n SidebarContent,\n SidebarGroup,\n SidebarGroupLabel,\n SidebarGroupContent,\n SidebarMenu,\n SidebarMenuItem,\n SidebarMenuButton,\n} from '@/components/shadcn-ui/sidebar';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { useCallback } from 'react';\n\nexport type SelectedSettingsSidebarItem = {\n label: string;\n projectId?: string;\n};\n\nexport type ProjectOptions = { projectId: string; projectName: string };\n\nexport type SettingsSidebarProps = {\n /** Optional id for testing */\n id?: string;\n\n /** Extension labels from contribution */\n extensionLabels: string[];\n\n /** Project names and ids */\n projectOptions: ProjectOptions[];\n\n /** Handler for selecting a sidebar item */\n handleSelectSidebarItem: (key: string, projectId?: string) => void;\n\n /** The current selected value in the sidebar */\n selectedSidebarItem: SelectedSettingsSidebarItem;\n\n /** Label for the group of extensions setting groups */\n extensionsSidebarGroupLabel: string;\n\n /** Label for the group of projects settings */\n projectsSidebarGroupLabel: string;\n\n /** Placeholder for the button */\n buttonPlaceholder: string;\n};\n\nexport default function SettingsSidebar({\n id,\n extensionLabels,\n projectOptions,\n handleSelectSidebarItem,\n selectedSidebarItem,\n extensionsSidebarGroupLabel,\n projectsSidebarGroupLabel,\n buttonPlaceholder,\n}: SettingsSidebarProps) {\n const handleSelectItem = useCallback(\n (item: string, projectId?: string) => {\n handleSelectSidebarItem(item, projectId);\n },\n [handleSelectSidebarItem],\n );\n\n const getProjectNameFromProjectId = useCallback(\n (projectId: string) => {\n const project = projectOptions.find((option) => option.projectId === projectId);\n return project ? project.projectName : projectId;\n },\n [projectOptions],\n );\n\n const getIsActive: (label: string) => boolean = useCallback(\n (label: string) => !selectedSidebarItem.projectId && label === selectedSidebarItem.label,\n [selectedSidebarItem],\n );\n\n return (\n \n \n \n \n {extensionsSidebarGroupLabel}\n \n \n \n {extensionLabels.map((label) => (\n \n handleSelectItem(label, undefined)}\n isActive={getIsActive(label)}\n >\n {label}\n \n \n ))}\n \n \n \n \n \n {projectsSidebarGroupLabel}\n \n \n option.projectId)}\n getOptionLabel={(projectId: ComboBoxOption) => {\n // This function expects a ComboBoxOption, but we know it is a string\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n return getProjectNameFromProjectId(projectId as string);\n }}\n buttonPlaceholder={buttonPlaceholder}\n onChange={(projectId: string) => {\n const selectedProjectName = getProjectNameFromProjectId(projectId);\n handleSelectItem(selectedProjectName, projectId);\n }}\n value={selectedSidebarItem?.projectId ?? undefined}\n />\n \n \n \n \n );\n}\n","import { SidebarInset, SidebarProvider } from '@/components/shadcn-ui/sidebar';\nimport { PropsWithChildren } from 'react';\nimport SearchBar from '@/components/basics/search-bar.component';\nimport SettingsSidebar, { SettingsSidebarProps } from './settings-sidebar.component';\n\nexport type SettingsSidebarContentSearchProps = SettingsSidebarProps &\n PropsWithChildren & {\n /** Optional id for testing */\n id?: string;\n\n /** Text direction ltr or rtl */\n direction?: 'ltr' | 'rtl';\n\n /** Handler to run when the value of the search bar changes */\n onSearch: (searchQuery: string) => void;\n };\n\nexport default function SettingsSidebarContentSearch({\n id,\n direction = 'ltr',\n extensionLabels,\n projectOptions,\n children,\n handleSelectSidebarItem,\n selectedSidebarItem,\n onSearch,\n extensionsSidebarGroupLabel,\n projectsSidebarGroupLabel,\n buttonPlaceholder,\n}: SettingsSidebarContentSearchProps) {\n return (\n
    \n
    \n \n
    \n \n \n {children}\n \n
    \n );\n}\n","import { Button } from '@/components/shadcn-ui/button';\nimport {\n Select,\n SelectContent,\n SelectGroup,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\nimport {\n Table,\n TableBody,\n TableCell,\n TableHead,\n TableHeader,\n TableRow,\n} from '@/components/shadcn-ui/table';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Canon } from '@sillsdev/scripture';\nimport {\n Cell,\n ColumnDef,\n flexRender,\n getCoreRowModel,\n getExpandedRowModel,\n getGroupedRowModel,\n getSortedRowModel,\n GroupingState,\n Row,\n RowSelectionState,\n SortingState,\n useReactTable,\n} from '@tanstack/react-table';\nimport '@/components/advanced/scripture-results-viewer/scripture-results-viewer.component.css';\nimport {\n compareScrRefs,\n formatScrRef,\n ScriptureSelection,\n scrRefToBBBCCCVVV,\n} from 'platform-bible-utils';\nimport { MouseEvent, useEffect, useMemo, useState } from 'react';\nimport { ChevronDown, ChevronLeft, ChevronRight } from 'lucide-react';\n\n/**\n * Information (e.g., a checking error or some other type of \"transient\" annotation) about something\n * noteworthy at a specific place in an instance of the Scriptures.\n */\nexport type ScriptureItemDetail = ScriptureSelection & {\n /**\n * Text of the error, note, etc. In the future, we might want to support something more than just\n * text so that a JSX element could be provided with a link or some other controls related to the\n * issue being reported.\n */\n detail: string;\n};\n\n/**\n * A uniquely identifiable source of results that can be displayed in the ScriptureResultsViewer.\n * Generally, the source will be a particular Scripture check, but there may be other types of\n * sources.\n */\nexport type ResultsSource = {\n /**\n * Uniquely identifies the source.\n *\n * @type {string}\n */\n id: string;\n\n /**\n * Name (potentially localized) of the source, suitable for display in the UI.\n *\n * @type {string}\n */\n displayName: string;\n};\n\nexport type ScriptureSrcItemDetail = ScriptureItemDetail & {\n /** Source/type of detail. Can be used for grouping. */\n source: ResultsSource;\n};\n\n/**\n * Represents a set of results keyed by Scripture reference. Generally, the source will be a\n * particular Scripture check, but this type also allows for other types of uniquely identifiable\n * sources.\n */\nexport type ResultsSet = {\n /**\n * The backing source associated with this set of results.\n *\n * @type {ResultsSource}\n */\n source: ResultsSource;\n\n /**\n * Array of Scripture item details (messages keyed by Scripture reference).\n *\n * @type {ScriptureItemDetail[]}\n */\n data: ScriptureItemDetail[];\n};\n\nconst scrBookColId = 'scrBook';\nconst scrRefColId = 'scrRef';\nconst typeColId = 'source';\nconst detailsColId = 'details';\n\nconst defaultScrRefColumnName = 'Scripture Reference';\nconst defaultScrBookGroupName = 'Scripture Book';\nconst defaultTypeColumnName = 'Type';\nconst defaultDetailsColumnName = 'Details';\n\nexport type ScriptureResultsViewerColumnInfo = {\n /** Optional header to display for the Reference column. Default value: 'Scripture Reference'. */\n scriptureReferenceColumnName?: string;\n\n /** Optional text to display to refer to the Scripture book group. Default value: 'Scripture Book'. */\n scriptureBookGroupName?: string;\n\n /** Optional header to display for the Type column. Default value: 'Type'. */\n typeColumnName?: string;\n\n /** Optional header to display for the Details column. Default value: 'Details' */\n detailsColumnName?: string;\n};\n\nexport type ScriptureResultsViewerProps = ScriptureResultsViewerColumnInfo & {\n /** Groups of ScriptureItemDetail objects from particular sources (e.g., Scripture checks) */\n sources: ResultsSet[];\n\n /** Flag indicating whether to display column headers. Default is false. */\n showColumnHeaders?: boolean;\n\n /** Flag indicating whether to display source column. Default is false. */\n showSourceColumn?: boolean;\n\n /** Callback function to notify when a row is selected */\n onRowSelected?: (selectedRow: ScriptureSrcItemDetail | undefined) => void;\n\n /** Text direction ltr or rtl */\n direction?: 'ltr' | 'rtl';\n};\n\nfunction getColumns(\n colInfo?: ScriptureResultsViewerColumnInfo,\n showSourceColumn?: boolean,\n): ColumnDef[] {\n const showSrcCol = showSourceColumn ?? false;\n return [\n {\n accessorFn: (row) =>\n `${Canon.bookNumberToId(row.start.bookNum)} ${row.start.chapterNum}:${row.start.verseNum}`,\n id: scrBookColId,\n header: colInfo?.scriptureReferenceColumnName ?? defaultScrRefColumnName,\n cell: (info) => {\n const row = info.row.original;\n if (info.row.getIsGrouped()) {\n return Canon.bookNumberToEnglishName(row.start.bookNum);\n }\n return info.row.groupingColumnId === scrBookColId ? formatScrRef(row.start) : undefined;\n },\n getGroupingValue: (row) => row.start.bookNum,\n sortingFn: (a, b) => {\n return compareScrRefs(a.original.start, b.original.start);\n },\n enableGrouping: true,\n },\n {\n accessorFn: (row) => formatScrRef(row.start),\n id: scrRefColId,\n header: undefined,\n cell: (info) => {\n const row = info.row.original;\n return info.row.getIsGrouped() ? undefined : formatScrRef(row.start);\n },\n sortingFn: (a, b) => {\n return compareScrRefs(a.original.start, b.original.start);\n },\n enableGrouping: false,\n },\n {\n accessorFn: (row) => row.source.displayName,\n id: typeColId,\n header: showSrcCol ? (colInfo?.typeColumnName ?? defaultTypeColumnName) : undefined,\n cell: (info) => (showSrcCol || info.row.getIsGrouped() ? info.getValue() : undefined),\n getGroupingValue: (row) => row.source.id,\n sortingFn: (a, b) =>\n a.original.source.displayName.localeCompare(b.original.source.displayName),\n enableGrouping: true,\n },\n {\n accessorFn: (row) => row.detail,\n id: detailsColId,\n header: colInfo?.detailsColumnName ?? defaultDetailsColumnName,\n cell: (info) => info.getValue(),\n enableGrouping: false,\n },\n ];\n}\n\nconst toRefOrRange = (scriptureSelection: ScriptureSelection) => {\n if (!('offset' in scriptureSelection.start))\n throw new Error('No offset available in range start');\n if (scriptureSelection.end && !('offset' in scriptureSelection.end))\n throw new Error('No offset available in range end');\n const { offset: offsetStart } = scriptureSelection.start;\n let offsetEnd: number = 0;\n if (scriptureSelection.end) ({ offset: offsetEnd } = scriptureSelection.end);\n if (\n !scriptureSelection.end ||\n compareScrRefs(scriptureSelection.start, scriptureSelection.end) === 0\n )\n return `${scrRefToBBBCCCVVV(scriptureSelection.start)}+${offsetStart}`;\n return `${scrRefToBBBCCCVVV(scriptureSelection.start)}+${offsetStart}-${scrRefToBBBCCCVVV(scriptureSelection.end)}+${offsetEnd}`;\n};\n\nconst getRowKey = (row: ScriptureSrcItemDetail) =>\n `${toRefOrRange({ start: row.start, end: row.end })} ${row.source.displayName} ${row.detail}`;\n\n/**\n * Component to display a combined list of detailed items from one or more sources, where the items\n * are keyed primarily by Scripture reference. This is particularly useful for displaying a list of\n * results from Scripture checks, but more generally could be used to display any \"results\" from any\n * source(s). The component allows for grouping by Scripture book, source, or both. By default, it\n * displays somewhat \"tree-like\" which allows it to be more horizontally compact and intuitive. But\n * it also has the option of displaying as a traditional table with column headings (with or without\n * the source column showing).\n */\nexport default function ScriptureResultsViewer({\n sources,\n showColumnHeaders = false,\n showSourceColumn = false,\n scriptureReferenceColumnName,\n scriptureBookGroupName,\n typeColumnName,\n detailsColumnName,\n onRowSelected,\n direction = 'ltr',\n}: ScriptureResultsViewerProps) {\n const [grouping, setGrouping] = useState([]);\n const [sorting, setSorting] = useState([{ id: scrBookColId, desc: false }]);\n const [rowSelection, setRowSelection] = useState({});\n\n const scriptureResults = useMemo(\n () =>\n sources.flatMap((source) => {\n return source.data.map((item) => ({\n ...item,\n source: source.source,\n }));\n }),\n [sources],\n );\n\n const columns = useMemo(\n () =>\n getColumns(\n {\n scriptureReferenceColumnName,\n typeColumnName,\n detailsColumnName,\n },\n showSourceColumn,\n ),\n [scriptureReferenceColumnName, typeColumnName, detailsColumnName, showSourceColumn],\n );\n\n useEffect(() => {\n // Ensure sorting is applied correctly when grouped by type\n if (grouping.includes(typeColId)) {\n setSorting([\n { id: typeColId, desc: false },\n { id: scrBookColId, desc: false },\n ]);\n } else {\n setSorting([{ id: scrBookColId, desc: false }]);\n }\n }, [grouping]);\n\n const table = useReactTable({\n data: scriptureResults,\n columns,\n state: {\n grouping,\n sorting,\n rowSelection,\n },\n onGroupingChange: setGrouping,\n onSortingChange: setSorting,\n onRowSelectionChange: setRowSelection,\n getExpandedRowModel: getExpandedRowModel(),\n getGroupedRowModel: getGroupedRowModel(),\n getCoreRowModel: getCoreRowModel(),\n getSortedRowModel: getSortedRowModel(),\n getRowId: getRowKey,\n autoResetExpanded: false,\n enableMultiRowSelection: false,\n enableSubRowSelection: false,\n });\n\n useEffect(() => {\n if (onRowSelected) {\n const selectedRows = table.getSelectedRowModel().rowsById;\n const keys = Object.keys(selectedRows);\n if (keys.length === 1) {\n const selectedRow = scriptureResults.find((row) => getRowKey(row) === keys[0]) || undefined;\n if (selectedRow) onRowSelected(selectedRow);\n }\n }\n }, [rowSelection, scriptureResults, onRowSelected, table]);\n\n // Define possible grouping options\n const scrBookGroupName = scriptureBookGroupName ?? defaultScrBookGroupName;\n const typeGroupName = typeColumnName ?? defaultTypeColumnName;\n\n const groupingOptions = [\n { label: 'No Grouping', value: [] },\n { label: `Group by ${scrBookGroupName}`, value: [scrBookColId] },\n { label: `Group by ${typeGroupName}`, value: [typeColId] },\n {\n label: `Group by ${scrBookGroupName} and ${typeGroupName}`,\n value: [scrBookColId, typeColId],\n },\n {\n label: `Group by ${typeGroupName} and ${scrBookGroupName}`,\n value: [typeColId, scrBookColId],\n },\n ];\n\n const handleSelectChange = (selectedGrouping: string) => {\n setGrouping(JSON.parse(selectedGrouping));\n };\n\n const handleRowClick = (row: Row, event: MouseEvent) => {\n if (!row.getIsGrouped() && !row.getIsSelected()) {\n row.getToggleSelectedHandler()(event);\n }\n };\n\n const getEvenOrOddBandingStyle = (row: Row, index: number) => {\n if (row.getIsGrouped()) return '';\n // UX has now said they don't think they want banding. I'm leaving in the code to\n // set even and odd styles, but there's nothing in the CSS to style them differently.\n // The \"even\" style used to also have tw-bg-neutral-300 (along with even) to create\n // a visual banding effect. That could be added back in if UX changes the decision.\n return cn('banded-row', index % 2 === 0 ? 'even' : 'odd');\n };\n\n const getIndent = (\n groupingState: GroupingState,\n row: Row,\n cell: Cell,\n ) => {\n if (groupingState?.length === 0 || row.depth < cell.column.getGroupedIndex()) return undefined;\n if (row.getIsGrouped()) {\n switch (row.depth) {\n case 1:\n return 'tw-ps-4';\n default:\n return undefined;\n }\n }\n switch (row.depth) {\n case 1:\n return 'tw-ps-8';\n case 2:\n return 'tw-ps-12';\n default:\n return undefined;\n }\n };\n\n return (\n
    \n {!showColumnHeaders && (\n {\n handleSelectChange(value);\n }}\n >\n \n \n \n \n \n {groupingOptions.map((option) => (\n \n {option.label}\n \n ))}\n \n \n \n )}\n \n {showColumnHeaders && (\n \n {table.getHeaderGroups().map((headerGroup) => (\n \n {headerGroup.headers\n .filter((h) => h.column.columnDef.header)\n .map((header) => (\n /* For sticky column headers to work, we probably need to change the default definition of the shadcn Table component. See https://github.com/shadcn-ui/ui/issues/1151 */\n \n {header.isPlaceholder ? undefined : (\n
    \n {header.column.getCanGroup() ? (\n \n {header.column.getIsGrouped() ? `🛑` : `👊 `}\n \n ) : undefined}{' '}\n {flexRender(header.column.columnDef.header, header.getContext())}\n
    \n )}\n
    \n ))}\n
    \n ))}\n
    \n )}\n \n {table.getRowModel().rows.map((row, rowIndex) => {\n return (\n handleRowClick(row, event)}\n >\n {row.getVisibleCells().map((cell) => {\n if (\n cell.getIsPlaceholder() ||\n (cell.column.columnDef.enableGrouping &&\n !cell.getIsGrouped() &&\n (cell.column.columnDef.id !== typeColId || !showSourceColumn))\n )\n return undefined;\n return (\n \n {(() => {\n if (cell.getIsGrouped()) {\n return (\n \n {row.getIsExpanded() && }\n {!row.getIsExpanded() &&\n (direction === 'ltr' ? : )}{' '}\n {flexRender(cell.column.columnDef.cell, cell.getContext())} (\n {row.subRows.length})\n \n );\n }\n\n // if (cell.getIsAggregated()) {\n // flexRender(\n // cell.column.columnDef.aggregatedCell ?? cell.column.columnDef.cell,\n // cell.getContext(),\n // );\n // }\n\n return flexRender(cell.column.columnDef.cell, cell.getContext());\n })()}\n \n );\n })}\n \n );\n })}\n \n
    \n
    \n );\n}\n","import {\n getLocalizeKeyForScrollGroupId,\n LanguageStrings,\n ScrollGroupId,\n} from 'platform-bible-utils';\nimport {\n Select,\n SelectContent,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\n\nconst DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS = {\n [getLocalizeKeyForScrollGroupId('undefined')]: 'Ø',\n [getLocalizeKeyForScrollGroupId(0)]: 'A',\n [getLocalizeKeyForScrollGroupId(1)]: 'B',\n [getLocalizeKeyForScrollGroupId(2)]: 'C',\n [getLocalizeKeyForScrollGroupId(3)]: 'D',\n [getLocalizeKeyForScrollGroupId(4)]: 'E',\n [getLocalizeKeyForScrollGroupId(5)]: 'F',\n [getLocalizeKeyForScrollGroupId(6)]: 'G',\n [getLocalizeKeyForScrollGroupId(7)]: 'H',\n [getLocalizeKeyForScrollGroupId(8)]: 'I',\n [getLocalizeKeyForScrollGroupId(9)]: 'J',\n [getLocalizeKeyForScrollGroupId(10)]: 'K',\n [getLocalizeKeyForScrollGroupId(11)]: 'L',\n [getLocalizeKeyForScrollGroupId(12)]: 'M',\n [getLocalizeKeyForScrollGroupId(13)]: 'N',\n [getLocalizeKeyForScrollGroupId(14)]: 'O',\n [getLocalizeKeyForScrollGroupId(15)]: 'P',\n [getLocalizeKeyForScrollGroupId(16)]: 'Q',\n [getLocalizeKeyForScrollGroupId(17)]: 'R',\n [getLocalizeKeyForScrollGroupId(18)]: 'S',\n [getLocalizeKeyForScrollGroupId(19)]: 'T',\n [getLocalizeKeyForScrollGroupId(20)]: 'U',\n [getLocalizeKeyForScrollGroupId(21)]: 'V',\n [getLocalizeKeyForScrollGroupId(22)]: 'W',\n [getLocalizeKeyForScrollGroupId(23)]: 'X',\n [getLocalizeKeyForScrollGroupId(24)]: 'Y',\n [getLocalizeKeyForScrollGroupId(25)]: 'Z',\n};\n\nexport type ScrollGroupSelectorProps = {\n /**\n * List of scroll group ids to show to the user. Either a {@link ScrollGroupId} or `undefined` for\n * no scroll group\n */\n availableScrollGroupIds: (ScrollGroupId | undefined)[];\n /** Currently selected scroll group id. `undefined` for no scroll group */\n scrollGroupId: ScrollGroupId | undefined;\n /** Callback function run when the user tries to change the scroll group id */\n onChangeScrollGroupId: (newScrollGroupId: ScrollGroupId | undefined) => void;\n /**\n * Localized strings to use for displaying scroll group ids. Must be an object whose keys are\n * `getLocalizeKeyForScrollGroupId(scrollGroupId)` for all scroll group ids (and `undefined` if\n * included) in {@link ScrollGroupSelectorProps.availableScrollGroupIds} and whose values are the\n * localized strings to use for those scroll group ids.\n *\n * Defaults to English localizations of English alphabet for scroll groups 0-25 (e.g. 0 is A) and\n * Ø for `undefined`. Will fill in any that are not provided with these English localizations.\n * Also, if any values match the keys, the English localization will be used. This is useful in\n * case you want to pass in a temporary version of the localized strings while your localized\n * strings load.\n *\n * @example\n *\n * ```typescript\n * const myScrollGroupIdLocalizedStrings = {\n * [getLocalizeKeyForScrollGroupId('undefined')]: 'Ø',\n * [getLocalizeKeyForScrollGroupId(0)]: 'A',\n * [getLocalizeKeyForScrollGroupId(1)]: 'B',\n * [getLocalizeKeyForScrollGroupId(2)]: 'C',\n * [getLocalizeKeyForScrollGroupId(3)]: 'D',\n * [getLocalizeKeyForScrollGroupId(4)]: 'E',\n * };\n * ```\n *\n * @example\n *\n * ```tsx\n * const availableScrollGroupIds = [undefined, 0, 1, 2, 3, 4];\n *\n * const localizeKeys = getLocalizeKeysForScrollGroupIds();\n *\n * const [localizedStrings] = useLocalizedStrings(localizeKeys);\n *\n * ...\n *\n * \n * ```\n */\n localizedStrings?: LanguageStrings;\n};\n\n/** Selector component for choosing a scroll group */\nexport default function ScrollGroupSelector({\n availableScrollGroupIds,\n scrollGroupId,\n onChangeScrollGroupId,\n localizedStrings = {},\n}: ScrollGroupSelectorProps) {\n const localizedStringsDefaulted = {\n ...DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS,\n ...Object.fromEntries(\n Object.entries(localizedStrings).map(\n ([localizedStringKey, localizedStringValue]: [string, string]) => [\n localizedStringKey,\n localizedStringKey === localizedStringValue &&\n localizedStringKey in DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS\n ? DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS[localizedStringKey]\n : localizedStringValue,\n ],\n ),\n ),\n };\n return (\n \n onChangeScrollGroupId(\n newScrollGroupString === 'undefined' ? undefined : parseInt(newScrollGroupString, 10),\n )\n }\n >\n \n \n \n \n {availableScrollGroupIds.map((scrollGroupOptionId) => (\n \n {localizedStringsDefaulted[getLocalizeKeyForScrollGroupId(scrollGroupOptionId)]}\n \n ))}\n \n \n );\n}\n","import { PropsWithChildren } from 'react';\nimport { Separator } from '@/components/shadcn-ui/separator';\n\n/** Props for the SettingsList component, currently just children */\ntype SettingsListProps = PropsWithChildren;\n\n/**\n * SettingsList component is a wrapper for list items. Rendered with a formatted div\n *\n * @param children To populate the list with\n * @returns Formatted div encompassing the children\n */\nexport function SettingsList({ children }: SettingsListProps) {\n return
    {children}
    ;\n}\n\n/** Props for SettingsListItem component */\ntype SettingsListItemProps = PropsWithChildren & {\n /** Primary text of the list item */\n primary: string;\n\n /** Optional text of the list item */\n secondary?: string | undefined;\n\n /** Optional boolean to display a message if the children aren't loaded yet. Defaults to false */\n isLoading?: boolean;\n\n /** Optional message to display if isLoading */\n loadingMessage?: string;\n};\n\n/**\n * SettingsListItem component is a common list item. Rendered with a formatted div\n *\n * @param primary Primary text of the list item\n * @param secondary Optional secondary text of the list item\n * @param isLoading Optional, to display a message if the action component isn't generated yet,\n * defaults to false\n * @param children The action component(s) to provide for this item\n * @param loadingMessage Optional, message to display if isLoading\n * @returns Formatted div encompassing the list item content\n */\nexport function SettingsListItem({\n primary,\n secondary,\n children,\n isLoading = false,\n loadingMessage,\n}: SettingsListItemProps) {\n return (\n
    \n
    \n

    {primary}

    \n

    \n {secondary}\n

    \n
    \n\n {isLoading ? (\n

    {loadingMessage}

    \n ) : (\n
    {children}
    \n )}\n
    \n );\n}\n\n/** Props for SettingsListHeader component */\ntype SettingsListHeaderProps = {\n /** The primary text of the list header */\n primary: string;\n\n /** Optional secondary text of the list header */\n secondary?: string | undefined;\n\n /** Optional boolean to include a separator underneath the secondary text. Defaults to false */\n includeSeparator?: boolean;\n};\n\n/**\n * SettingsListHeader component displays text above the list\n *\n * @param primary The primary text of the list header\n * @param secondary Optional secondary text of the list header\n * @param includeSeparator Optional boolean to include a separator underneath the secondary text.\n * Defaults to false\n * @returns Formatted div with list header content\n */\nexport function SettingsListHeader({\n primary,\n secondary,\n includeSeparator = false,\n}: SettingsListHeaderProps) {\n return (\n
    \n
    \n

    {primary}

    \n

    {secondary}

    \n
    \n {includeSeparator ? : ''}\n
    \n );\n}\n","import Checkbox from '@/components/shadcn-ui/checkbox';\nimport { Label } from '@/components/shadcn-ui/label';\n\nexport type ChecklistProps = {\n /** Optional string representing the id attribute of the Checklist */\n id?: string;\n /** Optional string representing CSS class name(s) for styling */\n className?: string;\n /** Array of strings representing the checkable items */\n listItems: string[];\n /** Array of strings representing the checked items */\n selectedListItems: string[];\n /**\n * Function that is called when a checkbox item is selected or deselected\n *\n * @param item The string description for this item\n * @param selected True if selected, false if not selected\n */\n handleSelectListItem: (item: string, selected: boolean) => void;\n\n /**\n * Optional function creates a label for a provided checkable item\n *\n * @param item The item for which a label is to be created\n * @returns A string representing the label text for the checkbox associated with that item\n */\n createLabel?: (item: string) => string;\n};\n\n/** Renders a list of checkboxes. Each checkbox corresponds to an item from the `listItems` array. */\nexport default function Checklist({\n id,\n className,\n listItems,\n selectedListItems,\n handleSelectListItem,\n createLabel,\n}: ChecklistProps) {\n return (\n
    \n {listItems.map((item) => (\n
    \n handleSelectListItem(item, value)}\n />\n \n
    \n ))}\n
    \n );\n}\n","function _interopRequireDefault(obj) {\n return obj && obj.__esModule ? obj : {\n \"default\": obj\n };\n}\nmodule.exports = _interopRequireDefault, module.exports.__esModule = true, module.exports[\"default\"] = module.exports;","export default function chainPropTypes(propType1, propType2) {\n if (process.env.NODE_ENV === 'production') {\n return () => null;\n }\n return function validate(...args) {\n return propType1(...args) || propType2(...args);\n };\n}","export default function _extends() {\n _extends = Object.assign ? Object.assign.bind() : function (target) {\n for (var i = 1; i < arguments.length; i++) {\n var source = arguments[i];\n for (var key in source) {\n if (Object.prototype.hasOwnProperty.call(source, key)) {\n target[key] = source[key];\n }\n }\n }\n return target;\n };\n return _extends.apply(this, arguments);\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\n// https://github.com/sindresorhus/is-plain-obj/blob/main/index.js\nexport function isPlainObject(item) {\n if (typeof item !== 'object' || item === null) {\n return false;\n }\n const prototype = Object.getPrototypeOf(item);\n return (prototype === null || prototype === Object.prototype || Object.getPrototypeOf(prototype) === null) && !(Symbol.toStringTag in item) && !(Symbol.iterator in item);\n}\nfunction deepClone(source) {\n if (!isPlainObject(source)) {\n return source;\n }\n const output = {};\n Object.keys(source).forEach(key => {\n output[key] = deepClone(source[key]);\n });\n return output;\n}\nexport default function deepmerge(target, source, options = {\n clone: true\n}) {\n const output = options.clone ? _extends({}, target) : target;\n if (isPlainObject(target) && isPlainObject(source)) {\n Object.keys(source).forEach(key => {\n // Avoid prototype pollution\n if (key === '__proto__') {\n return;\n }\n if (isPlainObject(source[key]) && key in target && isPlainObject(target[key])) {\n // Since `output` is a clone of `target` and we have narrowed `target` in this block we can cast to the same type.\n output[key] = deepmerge(target[key], source[key], options);\n } else if (options.clone) {\n output[key] = isPlainObject(source[key]) ? deepClone(source[key]) : source[key];\n } else {\n output[key] = source[key];\n }\n });\n }\n return output;\n}","/** @license React v16.13.1\n * react-is.production.min.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';var b=\"function\"===typeof Symbol&&Symbol.for,c=b?Symbol.for(\"react.element\"):60103,d=b?Symbol.for(\"react.portal\"):60106,e=b?Symbol.for(\"react.fragment\"):60107,f=b?Symbol.for(\"react.strict_mode\"):60108,g=b?Symbol.for(\"react.profiler\"):60114,h=b?Symbol.for(\"react.provider\"):60109,k=b?Symbol.for(\"react.context\"):60110,l=b?Symbol.for(\"react.async_mode\"):60111,m=b?Symbol.for(\"react.concurrent_mode\"):60111,n=b?Symbol.for(\"react.forward_ref\"):60112,p=b?Symbol.for(\"react.suspense\"):60113,q=b?\nSymbol.for(\"react.suspense_list\"):60120,r=b?Symbol.for(\"react.memo\"):60115,t=b?Symbol.for(\"react.lazy\"):60116,v=b?Symbol.for(\"react.block\"):60121,w=b?Symbol.for(\"react.fundamental\"):60117,x=b?Symbol.for(\"react.responder\"):60118,y=b?Symbol.for(\"react.scope\"):60119;\nfunction z(a){if(\"object\"===typeof a&&null!==a){var u=a.$$typeof;switch(u){case c:switch(a=a.type,a){case l:case m:case e:case g:case f:case p:return a;default:switch(a=a&&a.$$typeof,a){case k:case n:case t:case r:case h:return a;default:return u}}case d:return u}}}function A(a){return z(a)===m}exports.AsyncMode=l;exports.ConcurrentMode=m;exports.ContextConsumer=k;exports.ContextProvider=h;exports.Element=c;exports.ForwardRef=n;exports.Fragment=e;exports.Lazy=t;exports.Memo=r;exports.Portal=d;\nexports.Profiler=g;exports.StrictMode=f;exports.Suspense=p;exports.isAsyncMode=function(a){return A(a)||z(a)===l};exports.isConcurrentMode=A;exports.isContextConsumer=function(a){return z(a)===k};exports.isContextProvider=function(a){return z(a)===h};exports.isElement=function(a){return\"object\"===typeof a&&null!==a&&a.$$typeof===c};exports.isForwardRef=function(a){return z(a)===n};exports.isFragment=function(a){return z(a)===e};exports.isLazy=function(a){return z(a)===t};\nexports.isMemo=function(a){return z(a)===r};exports.isPortal=function(a){return z(a)===d};exports.isProfiler=function(a){return z(a)===g};exports.isStrictMode=function(a){return z(a)===f};exports.isSuspense=function(a){return z(a)===p};\nexports.isValidElementType=function(a){return\"string\"===typeof a||\"function\"===typeof a||a===e||a===m||a===g||a===f||a===p||a===q||\"object\"===typeof a&&null!==a&&(a.$$typeof===t||a.$$typeof===r||a.$$typeof===h||a.$$typeof===k||a.$$typeof===n||a.$$typeof===w||a.$$typeof===x||a.$$typeof===y||a.$$typeof===v)};exports.typeOf=z;\n","/** @license React v16.13.1\n * react-is.development.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\n\n\nif (process.env.NODE_ENV !== \"production\") {\n (function() {\n'use strict';\n\n// The Symbol used to tag the ReactElement-like types. If there is no native Symbol\n// nor polyfill, then a plain number is used for performance.\nvar hasSymbol = typeof Symbol === 'function' && Symbol.for;\nvar REACT_ELEMENT_TYPE = hasSymbol ? Symbol.for('react.element') : 0xeac7;\nvar REACT_PORTAL_TYPE = hasSymbol ? Symbol.for('react.portal') : 0xeaca;\nvar REACT_FRAGMENT_TYPE = hasSymbol ? Symbol.for('react.fragment') : 0xeacb;\nvar REACT_STRICT_MODE_TYPE = hasSymbol ? Symbol.for('react.strict_mode') : 0xeacc;\nvar REACT_PROFILER_TYPE = hasSymbol ? Symbol.for('react.profiler') : 0xead2;\nvar REACT_PROVIDER_TYPE = hasSymbol ? Symbol.for('react.provider') : 0xeacd;\nvar REACT_CONTEXT_TYPE = hasSymbol ? Symbol.for('react.context') : 0xeace; // TODO: We don't use AsyncMode or ConcurrentMode anymore. They were temporary\n// (unstable) APIs that have been removed. Can we remove the symbols?\n\nvar REACT_ASYNC_MODE_TYPE = hasSymbol ? Symbol.for('react.async_mode') : 0xeacf;\nvar REACT_CONCURRENT_MODE_TYPE = hasSymbol ? Symbol.for('react.concurrent_mode') : 0xeacf;\nvar REACT_FORWARD_REF_TYPE = hasSymbol ? Symbol.for('react.forward_ref') : 0xead0;\nvar REACT_SUSPENSE_TYPE = hasSymbol ? Symbol.for('react.suspense') : 0xead1;\nvar REACT_SUSPENSE_LIST_TYPE = hasSymbol ? Symbol.for('react.suspense_list') : 0xead8;\nvar REACT_MEMO_TYPE = hasSymbol ? Symbol.for('react.memo') : 0xead3;\nvar REACT_LAZY_TYPE = hasSymbol ? Symbol.for('react.lazy') : 0xead4;\nvar REACT_BLOCK_TYPE = hasSymbol ? Symbol.for('react.block') : 0xead9;\nvar REACT_FUNDAMENTAL_TYPE = hasSymbol ? Symbol.for('react.fundamental') : 0xead5;\nvar REACT_RESPONDER_TYPE = hasSymbol ? Symbol.for('react.responder') : 0xead6;\nvar REACT_SCOPE_TYPE = hasSymbol ? Symbol.for('react.scope') : 0xead7;\n\nfunction isValidElementType(type) {\n return typeof type === 'string' || typeof type === 'function' || // Note: its typeof might be other than 'symbol' or 'number' if it's a polyfill.\n type === REACT_FRAGMENT_TYPE || type === REACT_CONCURRENT_MODE_TYPE || type === REACT_PROFILER_TYPE || type === REACT_STRICT_MODE_TYPE || type === REACT_SUSPENSE_TYPE || type === REACT_SUSPENSE_LIST_TYPE || typeof type === 'object' && type !== null && (type.$$typeof === REACT_LAZY_TYPE || type.$$typeof === REACT_MEMO_TYPE || type.$$typeof === REACT_PROVIDER_TYPE || type.$$typeof === REACT_CONTEXT_TYPE || type.$$typeof === REACT_FORWARD_REF_TYPE || type.$$typeof === REACT_FUNDAMENTAL_TYPE || type.$$typeof === REACT_RESPONDER_TYPE || type.$$typeof === REACT_SCOPE_TYPE || type.$$typeof === REACT_BLOCK_TYPE);\n}\n\nfunction typeOf(object) {\n if (typeof object === 'object' && object !== null) {\n var $$typeof = object.$$typeof;\n\n switch ($$typeof) {\n case REACT_ELEMENT_TYPE:\n var type = object.type;\n\n switch (type) {\n case REACT_ASYNC_MODE_TYPE:\n case REACT_CONCURRENT_MODE_TYPE:\n case REACT_FRAGMENT_TYPE:\n case REACT_PROFILER_TYPE:\n case REACT_STRICT_MODE_TYPE:\n case REACT_SUSPENSE_TYPE:\n return type;\n\n default:\n var $$typeofType = type && type.$$typeof;\n\n switch ($$typeofType) {\n case REACT_CONTEXT_TYPE:\n case REACT_FORWARD_REF_TYPE:\n case REACT_LAZY_TYPE:\n case REACT_MEMO_TYPE:\n case REACT_PROVIDER_TYPE:\n return $$typeofType;\n\n default:\n return $$typeof;\n }\n\n }\n\n case REACT_PORTAL_TYPE:\n return $$typeof;\n }\n }\n\n return undefined;\n} // AsyncMode is deprecated along with isAsyncMode\n\nvar AsyncMode = REACT_ASYNC_MODE_TYPE;\nvar ConcurrentMode = REACT_CONCURRENT_MODE_TYPE;\nvar ContextConsumer = REACT_CONTEXT_TYPE;\nvar ContextProvider = REACT_PROVIDER_TYPE;\nvar Element = REACT_ELEMENT_TYPE;\nvar ForwardRef = REACT_FORWARD_REF_TYPE;\nvar Fragment = REACT_FRAGMENT_TYPE;\nvar Lazy = REACT_LAZY_TYPE;\nvar Memo = REACT_MEMO_TYPE;\nvar Portal = REACT_PORTAL_TYPE;\nvar Profiler = REACT_PROFILER_TYPE;\nvar StrictMode = REACT_STRICT_MODE_TYPE;\nvar Suspense = REACT_SUSPENSE_TYPE;\nvar hasWarnedAboutDeprecatedIsAsyncMode = false; // AsyncMode should be deprecated\n\nfunction isAsyncMode(object) {\n {\n if (!hasWarnedAboutDeprecatedIsAsyncMode) {\n hasWarnedAboutDeprecatedIsAsyncMode = true; // Using console['warn'] to evade Babel and ESLint\n\n console['warn']('The ReactIs.isAsyncMode() alias has been deprecated, ' + 'and will be removed in React 17+. Update your code to use ' + 'ReactIs.isConcurrentMode() instead. It has the exact same API.');\n }\n }\n\n return isConcurrentMode(object) || typeOf(object) === REACT_ASYNC_MODE_TYPE;\n}\nfunction isConcurrentMode(object) {\n return typeOf(object) === REACT_CONCURRENT_MODE_TYPE;\n}\nfunction isContextConsumer(object) {\n return typeOf(object) === REACT_CONTEXT_TYPE;\n}\nfunction isContextProvider(object) {\n return typeOf(object) === REACT_PROVIDER_TYPE;\n}\nfunction isElement(object) {\n return typeof object === 'object' && object !== null && object.$$typeof === REACT_ELEMENT_TYPE;\n}\nfunction isForwardRef(object) {\n return typeOf(object) === REACT_FORWARD_REF_TYPE;\n}\nfunction isFragment(object) {\n return typeOf(object) === REACT_FRAGMENT_TYPE;\n}\nfunction isLazy(object) {\n return typeOf(object) === REACT_LAZY_TYPE;\n}\nfunction isMemo(object) {\n return typeOf(object) === REACT_MEMO_TYPE;\n}\nfunction isPortal(object) {\n return typeOf(object) === REACT_PORTAL_TYPE;\n}\nfunction isProfiler(object) {\n return typeOf(object) === REACT_PROFILER_TYPE;\n}\nfunction isStrictMode(object) {\n return typeOf(object) === REACT_STRICT_MODE_TYPE;\n}\nfunction isSuspense(object) {\n return typeOf(object) === REACT_SUSPENSE_TYPE;\n}\n\nexports.AsyncMode = AsyncMode;\nexports.ConcurrentMode = ConcurrentMode;\nexports.ContextConsumer = ContextConsumer;\nexports.ContextProvider = ContextProvider;\nexports.Element = Element;\nexports.ForwardRef = ForwardRef;\nexports.Fragment = Fragment;\nexports.Lazy = Lazy;\nexports.Memo = Memo;\nexports.Portal = Portal;\nexports.Profiler = Profiler;\nexports.StrictMode = StrictMode;\nexports.Suspense = Suspense;\nexports.isAsyncMode = isAsyncMode;\nexports.isConcurrentMode = isConcurrentMode;\nexports.isContextConsumer = isContextConsumer;\nexports.isContextProvider = isContextProvider;\nexports.isElement = isElement;\nexports.isForwardRef = isForwardRef;\nexports.isFragment = isFragment;\nexports.isLazy = isLazy;\nexports.isMemo = isMemo;\nexports.isPortal = isPortal;\nexports.isProfiler = isProfiler;\nexports.isStrictMode = isStrictMode;\nexports.isSuspense = isSuspense;\nexports.isValidElementType = isValidElementType;\nexports.typeOf = typeOf;\n })();\n}\n","'use strict';\n\nif (process.env.NODE_ENV === 'production') {\n module.exports = require('./cjs/react-is.production.min.js');\n} else {\n module.exports = require('./cjs/react-is.development.js');\n}\n","/*\nobject-assign\n(c) Sindre Sorhus\n@license MIT\n*/\n\n'use strict';\n/* eslint-disable no-unused-vars */\nvar getOwnPropertySymbols = Object.getOwnPropertySymbols;\nvar hasOwnProperty = Object.prototype.hasOwnProperty;\nvar propIsEnumerable = Object.prototype.propertyIsEnumerable;\n\nfunction toObject(val) {\n\tif (val === null || val === undefined) {\n\t\tthrow new TypeError('Object.assign cannot be called with null or undefined');\n\t}\n\n\treturn Object(val);\n}\n\nfunction shouldUseNative() {\n\ttry {\n\t\tif (!Object.assign) {\n\t\t\treturn false;\n\t\t}\n\n\t\t// Detect buggy property enumeration order in older V8 versions.\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=4118\n\t\tvar test1 = new String('abc'); // eslint-disable-line no-new-wrappers\n\t\ttest1[5] = 'de';\n\t\tif (Object.getOwnPropertyNames(test1)[0] === '5') {\n\t\t\treturn false;\n\t\t}\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=3056\n\t\tvar test2 = {};\n\t\tfor (var i = 0; i < 10; i++) {\n\t\t\ttest2['_' + String.fromCharCode(i)] = i;\n\t\t}\n\t\tvar order2 = Object.getOwnPropertyNames(test2).map(function (n) {\n\t\t\treturn test2[n];\n\t\t});\n\t\tif (order2.join('') !== '0123456789') {\n\t\t\treturn false;\n\t\t}\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=3056\n\t\tvar test3 = {};\n\t\t'abcdefghijklmnopqrst'.split('').forEach(function (letter) {\n\t\t\ttest3[letter] = letter;\n\t\t});\n\t\tif (Object.keys(Object.assign({}, test3)).join('') !==\n\t\t\t\t'abcdefghijklmnopqrst') {\n\t\t\treturn false;\n\t\t}\n\n\t\treturn true;\n\t} catch (err) {\n\t\t// We don't expect any of the above to throw, but better to be safe.\n\t\treturn false;\n\t}\n}\n\nmodule.exports = shouldUseNative() ? Object.assign : function (target, source) {\n\tvar from;\n\tvar to = toObject(target);\n\tvar symbols;\n\n\tfor (var s = 1; s < arguments.length; s++) {\n\t\tfrom = Object(arguments[s]);\n\n\t\tfor (var key in from) {\n\t\t\tif (hasOwnProperty.call(from, key)) {\n\t\t\t\tto[key] = from[key];\n\t\t\t}\n\t\t}\n\n\t\tif (getOwnPropertySymbols) {\n\t\t\tsymbols = getOwnPropertySymbols(from);\n\t\t\tfor (var i = 0; i < symbols.length; i++) {\n\t\t\t\tif (propIsEnumerable.call(from, symbols[i])) {\n\t\t\t\t\tto[symbols[i]] = from[symbols[i]];\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\n\treturn to;\n};\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar ReactPropTypesSecret = 'SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED';\n\nmodule.exports = ReactPropTypesSecret;\n","module.exports = Function.call.bind(Object.prototype.hasOwnProperty);\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar printWarning = function() {};\n\nif (process.env.NODE_ENV !== 'production') {\n var ReactPropTypesSecret = require('./lib/ReactPropTypesSecret');\n var loggedTypeFailures = {};\n var has = require('./lib/has');\n\n printWarning = function(text) {\n var message = 'Warning: ' + text;\n if (typeof console !== 'undefined') {\n console.error(message);\n }\n try {\n // --- Welcome to debugging React ---\n // This error was thrown as a convenience so that you can use this stack\n // to find the callsite that caused this warning to fire.\n throw new Error(message);\n } catch (x) { /**/ }\n };\n}\n\n/**\n * Assert that the values match with the type specs.\n * Error messages are memorized and will only be shown once.\n *\n * @param {object} typeSpecs Map of name to a ReactPropType\n * @param {object} values Runtime values that need to be type-checked\n * @param {string} location e.g. \"prop\", \"context\", \"child context\"\n * @param {string} componentName Name of the component for error messages.\n * @param {?Function} getStack Returns the component stack.\n * @private\n */\nfunction checkPropTypes(typeSpecs, values, location, componentName, getStack) {\n if (process.env.NODE_ENV !== 'production') {\n for (var typeSpecName in typeSpecs) {\n if (has(typeSpecs, typeSpecName)) {\n var error;\n // Prop type validation may throw. In case they do, we don't want to\n // fail the render phase where it didn't fail before. So we log it.\n // After these have been cleaned up, we'll let them throw.\n try {\n // This is intentionally an invariant that gets caught. It's the same\n // behavior as without this statement except with a better message.\n if (typeof typeSpecs[typeSpecName] !== 'function') {\n var err = Error(\n (componentName || 'React class') + ': ' + location + ' type `' + typeSpecName + '` is invalid; ' +\n 'it must be a function, usually from the `prop-types` package, but received `' + typeof typeSpecs[typeSpecName] + '`.' +\n 'This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.'\n );\n err.name = 'Invariant Violation';\n throw err;\n }\n error = typeSpecs[typeSpecName](values, typeSpecName, componentName, location, null, ReactPropTypesSecret);\n } catch (ex) {\n error = ex;\n }\n if (error && !(error instanceof Error)) {\n printWarning(\n (componentName || 'React class') + ': type specification of ' +\n location + ' `' + typeSpecName + '` is invalid; the type checker ' +\n 'function must return `null` or an `Error` but returned a ' + typeof error + '. ' +\n 'You may have forgotten to pass an argument to the type checker ' +\n 'creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and ' +\n 'shape all require an argument).'\n );\n }\n if (error instanceof Error && !(error.message in loggedTypeFailures)) {\n // Only monitor this failure once because there tends to be a lot of the\n // same error.\n loggedTypeFailures[error.message] = true;\n\n var stack = getStack ? getStack() : '';\n\n printWarning(\n 'Failed ' + location + ' type: ' + error.message + (stack != null ? stack : '')\n );\n }\n }\n }\n }\n}\n\n/**\n * Resets warning cache when testing.\n *\n * @private\n */\ncheckPropTypes.resetWarningCache = function() {\n if (process.env.NODE_ENV !== 'production') {\n loggedTypeFailures = {};\n }\n}\n\nmodule.exports = checkPropTypes;\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar ReactIs = require('react-is');\nvar assign = require('object-assign');\n\nvar ReactPropTypesSecret = require('./lib/ReactPropTypesSecret');\nvar has = require('./lib/has');\nvar checkPropTypes = require('./checkPropTypes');\n\nvar printWarning = function() {};\n\nif (process.env.NODE_ENV !== 'production') {\n printWarning = function(text) {\n var message = 'Warning: ' + text;\n if (typeof console !== 'undefined') {\n console.error(message);\n }\n try {\n // --- Welcome to debugging React ---\n // This error was thrown as a convenience so that you can use this stack\n // to find the callsite that caused this warning to fire.\n throw new Error(message);\n } catch (x) {}\n };\n}\n\nfunction emptyFunctionThatReturnsNull() {\n return null;\n}\n\nmodule.exports = function(isValidElement, throwOnDirectAccess) {\n /* global Symbol */\n var ITERATOR_SYMBOL = typeof Symbol === 'function' && Symbol.iterator;\n var FAUX_ITERATOR_SYMBOL = '@@iterator'; // Before Symbol spec.\n\n /**\n * Returns the iterator method function contained on the iterable object.\n *\n * Be sure to invoke the function with the iterable as context:\n *\n * var iteratorFn = getIteratorFn(myIterable);\n * if (iteratorFn) {\n * var iterator = iteratorFn.call(myIterable);\n * ...\n * }\n *\n * @param {?object} maybeIterable\n * @return {?function}\n */\n function getIteratorFn(maybeIterable) {\n var iteratorFn = maybeIterable && (ITERATOR_SYMBOL && maybeIterable[ITERATOR_SYMBOL] || maybeIterable[FAUX_ITERATOR_SYMBOL]);\n if (typeof iteratorFn === 'function') {\n return iteratorFn;\n }\n }\n\n /**\n * Collection of methods that allow declaration and validation of props that are\n * supplied to React components. Example usage:\n *\n * var Props = require('ReactPropTypes');\n * var MyArticle = React.createClass({\n * propTypes: {\n * // An optional string prop named \"description\".\n * description: Props.string,\n *\n * // A required enum prop named \"category\".\n * category: Props.oneOf(['News','Photos']).isRequired,\n *\n * // A prop named \"dialog\" that requires an instance of Dialog.\n * dialog: Props.instanceOf(Dialog).isRequired\n * },\n * render: function() { ... }\n * });\n *\n * A more formal specification of how these methods are used:\n *\n * type := array|bool|func|object|number|string|oneOf([...])|instanceOf(...)\n * decl := ReactPropTypes.{type}(.isRequired)?\n *\n * Each and every declaration produces a function with the same signature. This\n * allows the creation of custom validation functions. For example:\n *\n * var MyLink = React.createClass({\n * propTypes: {\n * // An optional string or URI prop named \"href\".\n * href: function(props, propName, componentName) {\n * var propValue = props[propName];\n * if (propValue != null && typeof propValue !== 'string' &&\n * !(propValue instanceof URI)) {\n * return new Error(\n * 'Expected a string or an URI for ' + propName + ' in ' +\n * componentName\n * );\n * }\n * }\n * },\n * render: function() {...}\n * });\n *\n * @internal\n */\n\n var ANONYMOUS = '<>';\n\n // Important!\n // Keep this list in sync with production version in `./factoryWithThrowingShims.js`.\n var ReactPropTypes = {\n array: createPrimitiveTypeChecker('array'),\n bigint: createPrimitiveTypeChecker('bigint'),\n bool: createPrimitiveTypeChecker('boolean'),\n func: createPrimitiveTypeChecker('function'),\n number: createPrimitiveTypeChecker('number'),\n object: createPrimitiveTypeChecker('object'),\n string: createPrimitiveTypeChecker('string'),\n symbol: createPrimitiveTypeChecker('symbol'),\n\n any: createAnyTypeChecker(),\n arrayOf: createArrayOfTypeChecker,\n element: createElementTypeChecker(),\n elementType: createElementTypeTypeChecker(),\n instanceOf: createInstanceTypeChecker,\n node: createNodeChecker(),\n objectOf: createObjectOfTypeChecker,\n oneOf: createEnumTypeChecker,\n oneOfType: createUnionTypeChecker,\n shape: createShapeTypeChecker,\n exact: createStrictShapeTypeChecker,\n };\n\n /**\n * inlined Object.is polyfill to avoid requiring consumers ship their own\n * https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object/is\n */\n /*eslint-disable no-self-compare*/\n function is(x, y) {\n // SameValue algorithm\n if (x === y) {\n // Steps 1-5, 7-10\n // Steps 6.b-6.e: +0 != -0\n return x !== 0 || 1 / x === 1 / y;\n } else {\n // Step 6.a: NaN == NaN\n return x !== x && y !== y;\n }\n }\n /*eslint-enable no-self-compare*/\n\n /**\n * We use an Error-like object for backward compatibility as people may call\n * PropTypes directly and inspect their output. However, we don't use real\n * Errors anymore. We don't inspect their stack anyway, and creating them\n * is prohibitively expensive if they are created too often, such as what\n * happens in oneOfType() for any type before the one that matched.\n */\n function PropTypeError(message, data) {\n this.message = message;\n this.data = data && typeof data === 'object' ? data: {};\n this.stack = '';\n }\n // Make `instanceof Error` still work for returned errors.\n PropTypeError.prototype = Error.prototype;\n\n function createChainableTypeChecker(validate) {\n if (process.env.NODE_ENV !== 'production') {\n var manualPropTypeCallCache = {};\n var manualPropTypeWarningCount = 0;\n }\n function checkType(isRequired, props, propName, componentName, location, propFullName, secret) {\n componentName = componentName || ANONYMOUS;\n propFullName = propFullName || propName;\n\n if (secret !== ReactPropTypesSecret) {\n if (throwOnDirectAccess) {\n // New behavior only for users of `prop-types` package\n var err = new Error(\n 'Calling PropTypes validators directly is not supported by the `prop-types` package. ' +\n 'Use `PropTypes.checkPropTypes()` to call them. ' +\n 'Read more at http://fb.me/use-check-prop-types'\n );\n err.name = 'Invariant Violation';\n throw err;\n } else if (process.env.NODE_ENV !== 'production' && typeof console !== 'undefined') {\n // Old behavior for people using React.PropTypes\n var cacheKey = componentName + ':' + propName;\n if (\n !manualPropTypeCallCache[cacheKey] &&\n // Avoid spamming the console because they are often not actionable except for lib authors\n manualPropTypeWarningCount < 3\n ) {\n printWarning(\n 'You are manually calling a React.PropTypes validation ' +\n 'function for the `' + propFullName + '` prop on `' + componentName + '`. This is deprecated ' +\n 'and will throw in the standalone `prop-types` package. ' +\n 'You may be seeing this warning due to a third-party PropTypes ' +\n 'library. See https://fb.me/react-warning-dont-call-proptypes ' + 'for details.'\n );\n manualPropTypeCallCache[cacheKey] = true;\n manualPropTypeWarningCount++;\n }\n }\n }\n if (props[propName] == null) {\n if (isRequired) {\n if (props[propName] === null) {\n return new PropTypeError('The ' + location + ' `' + propFullName + '` is marked as required ' + ('in `' + componentName + '`, but its value is `null`.'));\n }\n return new PropTypeError('The ' + location + ' `' + propFullName + '` is marked as required in ' + ('`' + componentName + '`, but its value is `undefined`.'));\n }\n return null;\n } else {\n return validate(props, propName, componentName, location, propFullName);\n }\n }\n\n var chainedCheckType = checkType.bind(null, false);\n chainedCheckType.isRequired = checkType.bind(null, true);\n\n return chainedCheckType;\n }\n\n function createPrimitiveTypeChecker(expectedType) {\n function validate(props, propName, componentName, location, propFullName, secret) {\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== expectedType) {\n // `propValue` being instance of, say, date/regexp, pass the 'object'\n // check, but we can offer a more precise error message here rather than\n // 'of type `object`'.\n var preciseType = getPreciseType(propValue);\n\n return new PropTypeError(\n 'Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + preciseType + '` supplied to `' + componentName + '`, expected ') + ('`' + expectedType + '`.'),\n {expectedType: expectedType}\n );\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createAnyTypeChecker() {\n return createChainableTypeChecker(emptyFunctionThatReturnsNull);\n }\n\n function createArrayOfTypeChecker(typeChecker) {\n function validate(props, propName, componentName, location, propFullName) {\n if (typeof typeChecker !== 'function') {\n return new PropTypeError('Property `' + propFullName + '` of component `' + componentName + '` has invalid PropType notation inside arrayOf.');\n }\n var propValue = props[propName];\n if (!Array.isArray(propValue)) {\n var propType = getPropType(propValue);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected an array.'));\n }\n for (var i = 0; i < propValue.length; i++) {\n var error = typeChecker(propValue, i, componentName, location, propFullName + '[' + i + ']', ReactPropTypesSecret);\n if (error instanceof Error) {\n return error;\n }\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createElementTypeChecker() {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n if (!isValidElement(propValue)) {\n var propType = getPropType(propValue);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected a single ReactElement.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createElementTypeTypeChecker() {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n if (!ReactIs.isValidElementType(propValue)) {\n var propType = getPropType(propValue);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected a single ReactElement type.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createInstanceTypeChecker(expectedClass) {\n function validate(props, propName, componentName, location, propFullName) {\n if (!(props[propName] instanceof expectedClass)) {\n var expectedClassName = expectedClass.name || ANONYMOUS;\n var actualClassName = getClassName(props[propName]);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + actualClassName + '` supplied to `' + componentName + '`, expected ') + ('instance of `' + expectedClassName + '`.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createEnumTypeChecker(expectedValues) {\n if (!Array.isArray(expectedValues)) {\n if (process.env.NODE_ENV !== 'production') {\n if (arguments.length > 1) {\n printWarning(\n 'Invalid arguments supplied to oneOf, expected an array, got ' + arguments.length + ' arguments. ' +\n 'A common mistake is to write oneOf(x, y, z) instead of oneOf([x, y, z]).'\n );\n } else {\n printWarning('Invalid argument supplied to oneOf, expected an array.');\n }\n }\n return emptyFunctionThatReturnsNull;\n }\n\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n for (var i = 0; i < expectedValues.length; i++) {\n if (is(propValue, expectedValues[i])) {\n return null;\n }\n }\n\n var valuesString = JSON.stringify(expectedValues, function replacer(key, value) {\n var type = getPreciseType(value);\n if (type === 'symbol') {\n return String(value);\n }\n return value;\n });\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of value `' + String(propValue) + '` ' + ('supplied to `' + componentName + '`, expected one of ' + valuesString + '.'));\n }\n return createChainableTypeChecker(validate);\n }\n\n function createObjectOfTypeChecker(typeChecker) {\n function validate(props, propName, componentName, location, propFullName) {\n if (typeof typeChecker !== 'function') {\n return new PropTypeError('Property `' + propFullName + '` of component `' + componentName + '` has invalid PropType notation inside objectOf.');\n }\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== 'object') {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected an object.'));\n }\n for (var key in propValue) {\n if (has(propValue, key)) {\n var error = typeChecker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret);\n if (error instanceof Error) {\n return error;\n }\n }\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createUnionTypeChecker(arrayOfTypeCheckers) {\n if (!Array.isArray(arrayOfTypeCheckers)) {\n process.env.NODE_ENV !== 'production' ? printWarning('Invalid argument supplied to oneOfType, expected an instance of array.') : void 0;\n return emptyFunctionThatReturnsNull;\n }\n\n for (var i = 0; i < arrayOfTypeCheckers.length; i++) {\n var checker = arrayOfTypeCheckers[i];\n if (typeof checker !== 'function') {\n printWarning(\n 'Invalid argument supplied to oneOfType. Expected an array of check functions, but ' +\n 'received ' + getPostfixForTypeWarning(checker) + ' at index ' + i + '.'\n );\n return emptyFunctionThatReturnsNull;\n }\n }\n\n function validate(props, propName, componentName, location, propFullName) {\n var expectedTypes = [];\n for (var i = 0; i < arrayOfTypeCheckers.length; i++) {\n var checker = arrayOfTypeCheckers[i];\n var checkerResult = checker(props, propName, componentName, location, propFullName, ReactPropTypesSecret);\n if (checkerResult == null) {\n return null;\n }\n if (checkerResult.data && has(checkerResult.data, 'expectedType')) {\n expectedTypes.push(checkerResult.data.expectedType);\n }\n }\n var expectedTypesMessage = (expectedTypes.length > 0) ? ', expected one of type [' + expectedTypes.join(', ') + ']': '';\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` supplied to ' + ('`' + componentName + '`' + expectedTypesMessage + '.'));\n }\n return createChainableTypeChecker(validate);\n }\n\n function createNodeChecker() {\n function validate(props, propName, componentName, location, propFullName) {\n if (!isNode(props[propName])) {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` supplied to ' + ('`' + componentName + '`, expected a ReactNode.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function invalidValidatorError(componentName, location, propFullName, key, type) {\n return new PropTypeError(\n (componentName || 'React class') + ': ' + location + ' type `' + propFullName + '.' + key + '` is invalid; ' +\n 'it must be a function, usually from the `prop-types` package, but received `' + type + '`.'\n );\n }\n\n function createShapeTypeChecker(shapeTypes) {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== 'object') {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type `' + propType + '` ' + ('supplied to `' + componentName + '`, expected `object`.'));\n }\n for (var key in shapeTypes) {\n var checker = shapeTypes[key];\n if (typeof checker !== 'function') {\n return invalidValidatorError(componentName, location, propFullName, key, getPreciseType(checker));\n }\n var error = checker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret);\n if (error) {\n return error;\n }\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createStrictShapeTypeChecker(shapeTypes) {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== 'object') {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type `' + propType + '` ' + ('supplied to `' + componentName + '`, expected `object`.'));\n }\n // We need to check all keys in case some are required but missing from props.\n var allKeys = assign({}, props[propName], shapeTypes);\n for (var key in allKeys) {\n var checker = shapeTypes[key];\n if (has(shapeTypes, key) && typeof checker !== 'function') {\n return invalidValidatorError(componentName, location, propFullName, key, getPreciseType(checker));\n }\n if (!checker) {\n return new PropTypeError(\n 'Invalid ' + location + ' `' + propFullName + '` key `' + key + '` supplied to `' + componentName + '`.' +\n '\\nBad object: ' + JSON.stringify(props[propName], null, ' ') +\n '\\nValid keys: ' + JSON.stringify(Object.keys(shapeTypes), null, ' ')\n );\n }\n var error = checker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret);\n if (error) {\n return error;\n }\n }\n return null;\n }\n\n return createChainableTypeChecker(validate);\n }\n\n function isNode(propValue) {\n switch (typeof propValue) {\n case 'number':\n case 'string':\n case 'undefined':\n return true;\n case 'boolean':\n return !propValue;\n case 'object':\n if (Array.isArray(propValue)) {\n return propValue.every(isNode);\n }\n if (propValue === null || isValidElement(propValue)) {\n return true;\n }\n\n var iteratorFn = getIteratorFn(propValue);\n if (iteratorFn) {\n var iterator = iteratorFn.call(propValue);\n var step;\n if (iteratorFn !== propValue.entries) {\n while (!(step = iterator.next()).done) {\n if (!isNode(step.value)) {\n return false;\n }\n }\n } else {\n // Iterator will provide entry [k,v] tuples rather than values.\n while (!(step = iterator.next()).done) {\n var entry = step.value;\n if (entry) {\n if (!isNode(entry[1])) {\n return false;\n }\n }\n }\n }\n } else {\n return false;\n }\n\n return true;\n default:\n return false;\n }\n }\n\n function isSymbol(propType, propValue) {\n // Native Symbol.\n if (propType === 'symbol') {\n return true;\n }\n\n // falsy value can't be a Symbol\n if (!propValue) {\n return false;\n }\n\n // 19.4.3.5 Symbol.prototype[@@toStringTag] === 'Symbol'\n if (propValue['@@toStringTag'] === 'Symbol') {\n return true;\n }\n\n // Fallback for non-spec compliant Symbols which are polyfilled.\n if (typeof Symbol === 'function' && propValue instanceof Symbol) {\n return true;\n }\n\n return false;\n }\n\n // Equivalent of `typeof` but with special handling for array and regexp.\n function getPropType(propValue) {\n var propType = typeof propValue;\n if (Array.isArray(propValue)) {\n return 'array';\n }\n if (propValue instanceof RegExp) {\n // Old webkits (at least until Android 4.0) return 'function' rather than\n // 'object' for typeof a RegExp. We'll normalize this here so that /bla/\n // passes PropTypes.object.\n return 'object';\n }\n if (isSymbol(propType, propValue)) {\n return 'symbol';\n }\n return propType;\n }\n\n // This handles more types than `getPropType`. Only used for error messages.\n // See `createPrimitiveTypeChecker`.\n function getPreciseType(propValue) {\n if (typeof propValue === 'undefined' || propValue === null) {\n return '' + propValue;\n }\n var propType = getPropType(propValue);\n if (propType === 'object') {\n if (propValue instanceof Date) {\n return 'date';\n } else if (propValue instanceof RegExp) {\n return 'regexp';\n }\n }\n return propType;\n }\n\n // Returns a string that is postfixed to a warning about an invalid type.\n // For example, \"undefined\" or \"of type array\"\n function getPostfixForTypeWarning(value) {\n var type = getPreciseType(value);\n switch (type) {\n case 'array':\n case 'object':\n return 'an ' + type;\n case 'boolean':\n case 'date':\n case 'regexp':\n return 'a ' + type;\n default:\n return type;\n }\n }\n\n // Returns class name of the object, if any.\n function getClassName(propValue) {\n if (!propValue.constructor || !propValue.constructor.name) {\n return ANONYMOUS;\n }\n return propValue.constructor.name;\n }\n\n ReactPropTypes.checkPropTypes = checkPropTypes;\n ReactPropTypes.resetWarningCache = checkPropTypes.resetWarningCache;\n ReactPropTypes.PropTypes = ReactPropTypes;\n\n return ReactPropTypes;\n};\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar ReactPropTypesSecret = require('./lib/ReactPropTypesSecret');\n\nfunction emptyFunction() {}\nfunction emptyFunctionWithReset() {}\nemptyFunctionWithReset.resetWarningCache = emptyFunction;\n\nmodule.exports = function() {\n function shim(props, propName, componentName, location, propFullName, secret) {\n if (secret === ReactPropTypesSecret) {\n // It is still safe when called from React.\n return;\n }\n var err = new Error(\n 'Calling PropTypes validators directly is not supported by the `prop-types` package. ' +\n 'Use PropTypes.checkPropTypes() to call them. ' +\n 'Read more at http://fb.me/use-check-prop-types'\n );\n err.name = 'Invariant Violation';\n throw err;\n };\n shim.isRequired = shim;\n function getShim() {\n return shim;\n };\n // Important!\n // Keep this list in sync with production version in `./factoryWithTypeCheckers.js`.\n var ReactPropTypes = {\n array: shim,\n bigint: shim,\n bool: shim,\n func: shim,\n number: shim,\n object: shim,\n string: shim,\n symbol: shim,\n\n any: shim,\n arrayOf: getShim,\n element: shim,\n elementType: shim,\n instanceOf: getShim,\n node: shim,\n objectOf: getShim,\n oneOf: getShim,\n oneOfType: getShim,\n shape: getShim,\n exact: getShim,\n\n checkPropTypes: emptyFunctionWithReset,\n resetWarningCache: emptyFunction\n };\n\n ReactPropTypes.PropTypes = ReactPropTypes;\n\n return ReactPropTypes;\n};\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\nif (process.env.NODE_ENV !== 'production') {\n var ReactIs = require('react-is');\n\n // By explicitly using `prop-types` you are opting into new development behavior.\n // http://fb.me/prop-types-in-prod\n var throwOnDirectAccess = true;\n module.exports = require('./factoryWithTypeCheckers')(ReactIs.isElement, throwOnDirectAccess);\n} else {\n // By explicitly using `prop-types` you are opting into new production behavior.\n // http://fb.me/prop-types-in-prod\n module.exports = require('./factoryWithThrowingShims')();\n}\n","import PropTypes from 'prop-types';\nimport chainPropTypes from '../chainPropTypes';\nfunction isClassComponent(elementType) {\n // elementType.prototype?.isReactComponent\n const {\n prototype = {}\n } = elementType;\n return Boolean(prototype.isReactComponent);\n}\nfunction acceptingRef(props, propName, componentName, location, propFullName) {\n const element = props[propName];\n const safePropName = propFullName || propName;\n if (element == null ||\n // When server-side rendering React doesn't warn either.\n // This is not an accurate check for SSR.\n // This is only in place for Emotion compat.\n // TODO: Revisit once https://github.com/facebook/react/issues/20047 is resolved.\n typeof window === 'undefined') {\n return null;\n }\n let warningHint;\n const elementType = element.type;\n /**\n * Blacklisting instead of whitelisting\n *\n * Blacklisting will miss some components, such as React.Fragment. Those will at least\n * trigger a warning in React.\n * We can't whitelist because there is no safe way to detect React.forwardRef\n * or class components. \"Safe\" means there's no public API.\n *\n */\n if (typeof elementType === 'function' && !isClassComponent(elementType)) {\n warningHint = 'Did you accidentally use a plain function component for an element instead?';\n }\n if (warningHint !== undefined) {\n return new Error(`Invalid ${location} \\`${safePropName}\\` supplied to \\`${componentName}\\`. ` + `Expected an element that can hold a ref. ${warningHint} ` + 'For more information see https://mui.com/r/caveat-with-refs-guide');\n }\n return null;\n}\nconst elementAcceptingRef = chainPropTypes(PropTypes.element, acceptingRef);\nelementAcceptingRef.isRequired = chainPropTypes(PropTypes.element.isRequired, acceptingRef);\nexport default elementAcceptingRef;","import _extends from \"@babel/runtime/helpers/esm/extends\";\n// This module is based on https://github.com/airbnb/prop-types-exact repository.\n// However, in order to reduce the number of dependencies and to remove some extra safe checks\n// the module was forked.\n\nconst specialProperty = 'exact-prop: \\u200b';\nexport default function exactProp(propTypes) {\n if (process.env.NODE_ENV === 'production') {\n return propTypes;\n }\n return _extends({}, propTypes, {\n [specialProperty]: props => {\n const unsupportedProps = Object.keys(props).filter(prop => !propTypes.hasOwnProperty(prop));\n if (unsupportedProps.length > 0) {\n return new Error(`The following props are not supported: ${unsupportedProps.map(prop => `\\`${prop}\\``).join(', ')}. Please remove them.`);\n }\n return null;\n }\n });\n}","/**\n * WARNING: Don't import this directly.\n * Use `MuiError` from `@mui/internal-babel-macros/MuiError.macro` instead.\n * @param {number} code\n */\nexport default function formatMuiErrorMessage(code) {\n // Apply babel-plugin-transform-template-literals in loose mode\n // loose mode is safe if we're concatenating primitives\n // see https://babeljs.io/docs/en/babel-plugin-transform-template-literals#loose\n /* eslint-disable prefer-template */\n let url = 'https://mui.com/production-error/?code=' + code;\n for (let i = 1; i < arguments.length; i += 1) {\n // rest params over-transpile for this case\n // eslint-disable-next-line prefer-rest-params\n url += '&args[]=' + encodeURIComponent(arguments[i]);\n }\n return 'Minified MUI error #' + code + '; visit ' + url + ' for the full message.';\n /* eslint-enable prefer-template */\n}","/**\n * @license React\n * react-is.production.min.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n'use strict';var b=Symbol.for(\"react.element\"),c=Symbol.for(\"react.portal\"),d=Symbol.for(\"react.fragment\"),e=Symbol.for(\"react.strict_mode\"),f=Symbol.for(\"react.profiler\"),g=Symbol.for(\"react.provider\"),h=Symbol.for(\"react.context\"),k=Symbol.for(\"react.server_context\"),l=Symbol.for(\"react.forward_ref\"),m=Symbol.for(\"react.suspense\"),n=Symbol.for(\"react.suspense_list\"),p=Symbol.for(\"react.memo\"),q=Symbol.for(\"react.lazy\"),t=Symbol.for(\"react.offscreen\"),u;u=Symbol.for(\"react.module.reference\");\nfunction v(a){if(\"object\"===typeof a&&null!==a){var r=a.$$typeof;switch(r){case b:switch(a=a.type,a){case d:case f:case e:case m:case n:return a;default:switch(a=a&&a.$$typeof,a){case k:case h:case l:case q:case p:case g:return a;default:return r}}case c:return r}}}exports.ContextConsumer=h;exports.ContextProvider=g;exports.Element=b;exports.ForwardRef=l;exports.Fragment=d;exports.Lazy=q;exports.Memo=p;exports.Portal=c;exports.Profiler=f;exports.StrictMode=e;exports.Suspense=m;\nexports.SuspenseList=n;exports.isAsyncMode=function(){return!1};exports.isConcurrentMode=function(){return!1};exports.isContextConsumer=function(a){return v(a)===h};exports.isContextProvider=function(a){return v(a)===g};exports.isElement=function(a){return\"object\"===typeof a&&null!==a&&a.$$typeof===b};exports.isForwardRef=function(a){return v(a)===l};exports.isFragment=function(a){return v(a)===d};exports.isLazy=function(a){return v(a)===q};exports.isMemo=function(a){return v(a)===p};\nexports.isPortal=function(a){return v(a)===c};exports.isProfiler=function(a){return v(a)===f};exports.isStrictMode=function(a){return v(a)===e};exports.isSuspense=function(a){return v(a)===m};exports.isSuspenseList=function(a){return v(a)===n};\nexports.isValidElementType=function(a){return\"string\"===typeof a||\"function\"===typeof a||a===d||a===f||a===e||a===m||a===n||a===t||\"object\"===typeof a&&null!==a&&(a.$$typeof===q||a.$$typeof===p||a.$$typeof===g||a.$$typeof===h||a.$$typeof===l||a.$$typeof===u||void 0!==a.getModuleId)?!0:!1};exports.typeOf=v;\n","/**\n * @license React\n * react-is.development.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nif (process.env.NODE_ENV !== \"production\") {\n (function() {\n'use strict';\n\n// ATTENTION\n// When adding new symbols to this file,\n// Please consider also adding to 'react-devtools-shared/src/backend/ReactSymbols'\n// The Symbol used to tag the ReactElement-like types.\nvar REACT_ELEMENT_TYPE = Symbol.for('react.element');\nvar REACT_PORTAL_TYPE = Symbol.for('react.portal');\nvar REACT_FRAGMENT_TYPE = Symbol.for('react.fragment');\nvar REACT_STRICT_MODE_TYPE = Symbol.for('react.strict_mode');\nvar REACT_PROFILER_TYPE = Symbol.for('react.profiler');\nvar REACT_PROVIDER_TYPE = Symbol.for('react.provider');\nvar REACT_CONTEXT_TYPE = Symbol.for('react.context');\nvar REACT_SERVER_CONTEXT_TYPE = Symbol.for('react.server_context');\nvar REACT_FORWARD_REF_TYPE = Symbol.for('react.forward_ref');\nvar REACT_SUSPENSE_TYPE = Symbol.for('react.suspense');\nvar REACT_SUSPENSE_LIST_TYPE = Symbol.for('react.suspense_list');\nvar REACT_MEMO_TYPE = Symbol.for('react.memo');\nvar REACT_LAZY_TYPE = Symbol.for('react.lazy');\nvar REACT_OFFSCREEN_TYPE = Symbol.for('react.offscreen');\n\n// -----------------------------------------------------------------------------\n\nvar enableScopeAPI = false; // Experimental Create Event Handle API.\nvar enableCacheElement = false;\nvar enableTransitionTracing = false; // No known bugs, but needs performance testing\n\nvar enableLegacyHidden = false; // Enables unstable_avoidThisFallback feature in Fiber\n// stuff. Intended to enable React core members to more easily debug scheduling\n// issues in DEV builds.\n\nvar enableDebugTracing = false; // Track which Fiber(s) schedule render work.\n\nvar REACT_MODULE_REFERENCE;\n\n{\n REACT_MODULE_REFERENCE = Symbol.for('react.module.reference');\n}\n\nfunction isValidElementType(type) {\n if (typeof type === 'string' || typeof type === 'function') {\n return true;\n } // Note: typeof might be other than 'symbol' or 'number' (e.g. if it's a polyfill).\n\n\n if (type === REACT_FRAGMENT_TYPE || type === REACT_PROFILER_TYPE || enableDebugTracing || type === REACT_STRICT_MODE_TYPE || type === REACT_SUSPENSE_TYPE || type === REACT_SUSPENSE_LIST_TYPE || enableLegacyHidden || type === REACT_OFFSCREEN_TYPE || enableScopeAPI || enableCacheElement || enableTransitionTracing ) {\n return true;\n }\n\n if (typeof type === 'object' && type !== null) {\n if (type.$$typeof === REACT_LAZY_TYPE || type.$$typeof === REACT_MEMO_TYPE || type.$$typeof === REACT_PROVIDER_TYPE || type.$$typeof === REACT_CONTEXT_TYPE || type.$$typeof === REACT_FORWARD_REF_TYPE || // This needs to include all possible module reference object\n // types supported by any Flight configuration anywhere since\n // we don't know which Flight build this will end up being used\n // with.\n type.$$typeof === REACT_MODULE_REFERENCE || type.getModuleId !== undefined) {\n return true;\n }\n }\n\n return false;\n}\n\nfunction typeOf(object) {\n if (typeof object === 'object' && object !== null) {\n var $$typeof = object.$$typeof;\n\n switch ($$typeof) {\n case REACT_ELEMENT_TYPE:\n var type = object.type;\n\n switch (type) {\n case REACT_FRAGMENT_TYPE:\n case REACT_PROFILER_TYPE:\n case REACT_STRICT_MODE_TYPE:\n case REACT_SUSPENSE_TYPE:\n case REACT_SUSPENSE_LIST_TYPE:\n return type;\n\n default:\n var $$typeofType = type && type.$$typeof;\n\n switch ($$typeofType) {\n case REACT_SERVER_CONTEXT_TYPE:\n case REACT_CONTEXT_TYPE:\n case REACT_FORWARD_REF_TYPE:\n case REACT_LAZY_TYPE:\n case REACT_MEMO_TYPE:\n case REACT_PROVIDER_TYPE:\n return $$typeofType;\n\n default:\n return $$typeof;\n }\n\n }\n\n case REACT_PORTAL_TYPE:\n return $$typeof;\n }\n }\n\n return undefined;\n}\nvar ContextConsumer = REACT_CONTEXT_TYPE;\nvar ContextProvider = REACT_PROVIDER_TYPE;\nvar Element = REACT_ELEMENT_TYPE;\nvar ForwardRef = REACT_FORWARD_REF_TYPE;\nvar Fragment = REACT_FRAGMENT_TYPE;\nvar Lazy = REACT_LAZY_TYPE;\nvar Memo = REACT_MEMO_TYPE;\nvar Portal = REACT_PORTAL_TYPE;\nvar Profiler = REACT_PROFILER_TYPE;\nvar StrictMode = REACT_STRICT_MODE_TYPE;\nvar Suspense = REACT_SUSPENSE_TYPE;\nvar SuspenseList = REACT_SUSPENSE_LIST_TYPE;\nvar hasWarnedAboutDeprecatedIsAsyncMode = false;\nvar hasWarnedAboutDeprecatedIsConcurrentMode = false; // AsyncMode should be deprecated\n\nfunction isAsyncMode(object) {\n {\n if (!hasWarnedAboutDeprecatedIsAsyncMode) {\n hasWarnedAboutDeprecatedIsAsyncMode = true; // Using console['warn'] to evade Babel and ESLint\n\n console['warn']('The ReactIs.isAsyncMode() alias has been deprecated, ' + 'and will be removed in React 18+.');\n }\n }\n\n return false;\n}\nfunction isConcurrentMode(object) {\n {\n if (!hasWarnedAboutDeprecatedIsConcurrentMode) {\n hasWarnedAboutDeprecatedIsConcurrentMode = true; // Using console['warn'] to evade Babel and ESLint\n\n console['warn']('The ReactIs.isConcurrentMode() alias has been deprecated, ' + 'and will be removed in React 18+.');\n }\n }\n\n return false;\n}\nfunction isContextConsumer(object) {\n return typeOf(object) === REACT_CONTEXT_TYPE;\n}\nfunction isContextProvider(object) {\n return typeOf(object) === REACT_PROVIDER_TYPE;\n}\nfunction isElement(object) {\n return typeof object === 'object' && object !== null && object.$$typeof === REACT_ELEMENT_TYPE;\n}\nfunction isForwardRef(object) {\n return typeOf(object) === REACT_FORWARD_REF_TYPE;\n}\nfunction isFragment(object) {\n return typeOf(object) === REACT_FRAGMENT_TYPE;\n}\nfunction isLazy(object) {\n return typeOf(object) === REACT_LAZY_TYPE;\n}\nfunction isMemo(object) {\n return typeOf(object) === REACT_MEMO_TYPE;\n}\nfunction isPortal(object) {\n return typeOf(object) === REACT_PORTAL_TYPE;\n}\nfunction isProfiler(object) {\n return typeOf(object) === REACT_PROFILER_TYPE;\n}\nfunction isStrictMode(object) {\n return typeOf(object) === REACT_STRICT_MODE_TYPE;\n}\nfunction isSuspense(object) {\n return typeOf(object) === REACT_SUSPENSE_TYPE;\n}\nfunction isSuspenseList(object) {\n return typeOf(object) === REACT_SUSPENSE_LIST_TYPE;\n}\n\nexports.ContextConsumer = ContextConsumer;\nexports.ContextProvider = ContextProvider;\nexports.Element = Element;\nexports.ForwardRef = ForwardRef;\nexports.Fragment = Fragment;\nexports.Lazy = Lazy;\nexports.Memo = Memo;\nexports.Portal = Portal;\nexports.Profiler = Profiler;\nexports.StrictMode = StrictMode;\nexports.Suspense = Suspense;\nexports.SuspenseList = SuspenseList;\nexports.isAsyncMode = isAsyncMode;\nexports.isConcurrentMode = isConcurrentMode;\nexports.isContextConsumer = isContextConsumer;\nexports.isContextProvider = isContextProvider;\nexports.isElement = isElement;\nexports.isForwardRef = isForwardRef;\nexports.isFragment = isFragment;\nexports.isLazy = isLazy;\nexports.isMemo = isMemo;\nexports.isPortal = isPortal;\nexports.isProfiler = isProfiler;\nexports.isStrictMode = isStrictMode;\nexports.isSuspense = isSuspense;\nexports.isSuspenseList = isSuspenseList;\nexports.isValidElementType = isValidElementType;\nexports.typeOf = typeOf;\n })();\n}\n","'use strict';\n\nif (process.env.NODE_ENV === 'production') {\n module.exports = require('./cjs/react-is.production.min.js');\n} else {\n module.exports = require('./cjs/react-is.development.js');\n}\n","import { ForwardRef, Memo } from 'react-is';\n\n// Simplified polyfill for IE11 support\n// https://github.com/JamesMGreene/Function.name/blob/58b314d4a983110c3682f1228f845d39ccca1817/Function.name.js#L3\nconst fnNameMatchRegex = /^\\s*function(?:\\s|\\s*\\/\\*.*\\*\\/\\s*)+([^(\\s/]*)\\s*/;\nexport function getFunctionName(fn) {\n const match = `${fn}`.match(fnNameMatchRegex);\n const name = match && match[1];\n return name || '';\n}\nfunction getFunctionComponentName(Component, fallback = '') {\n return Component.displayName || Component.name || getFunctionName(Component) || fallback;\n}\nfunction getWrappedName(outerType, innerType, wrapperName) {\n const functionName = getFunctionComponentName(innerType);\n return outerType.displayName || (functionName !== '' ? `${wrapperName}(${functionName})` : wrapperName);\n}\n\n/**\n * cherry-pick from\n * https://github.com/facebook/react/blob/769b1f270e1251d9dbdce0fcbd9e92e502d059b8/packages/shared/getComponentName.js\n * originally forked from recompose/getDisplayName with added IE11 support\n */\nexport default function getDisplayName(Component) {\n if (Component == null) {\n return undefined;\n }\n if (typeof Component === 'string') {\n return Component;\n }\n if (typeof Component === 'function') {\n return getFunctionComponentName(Component, 'Component');\n }\n\n // TypeScript can't have components as objects but they exist in the form of `memo` or `Suspense`\n if (typeof Component === 'object') {\n switch (Component.$$typeof) {\n case ForwardRef:\n return getWrappedName(Component, Component.render, 'ForwardRef');\n case Memo:\n return getWrappedName(Component, Component.type, 'memo');\n default:\n return undefined;\n }\n }\n return undefined;\n}","export default function HTMLElementType(props, propName, componentName, location, propFullName) {\n if (process.env.NODE_ENV === 'production') {\n return null;\n }\n const propValue = props[propName];\n const safePropName = propFullName || propName;\n if (propValue == null) {\n return null;\n }\n if (propValue && propValue.nodeType !== 1) {\n return new Error(`Invalid ${location} \\`${safePropName}\\` supplied to \\`${componentName}\\`. ` + `Expected an HTMLElement.`);\n }\n return null;\n}","import PropTypes from 'prop-types';\nconst refType = PropTypes.oneOfType([PropTypes.func, PropTypes.object]);\nexport default refType;","import _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\n// It should to be noted that this function isn't equivalent to `text-transform: capitalize`.\n//\n// A strict capitalization should uppercase the first letter of each word in the sentence.\n// We only handle the first word.\nexport default function capitalize(string) {\n if (typeof string !== 'string') {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: \\`capitalize(string)\\` expects a string argument.` : _formatMuiErrorMessage(7));\n }\n return string.charAt(0).toUpperCase() + string.slice(1);\n}","/**\n * Safe chained function.\n *\n * Will only create a new function if needed,\n * otherwise will pass back existing functions or null.\n */\nexport default function createChainedFunction(...funcs) {\n return funcs.reduce((acc, func) => {\n if (func == null) {\n return acc;\n }\n return function chainedFunction(...args) {\n acc.apply(this, args);\n func.apply(this, args);\n };\n }, () => {});\n}","// Corresponds to 10 frames at 60 Hz.\n// A few bytes payload overhead when lodash/debounce is ~3 kB and debounce ~300 B.\nexport default function debounce(func, wait = 166) {\n let timeout;\n function debounced(...args) {\n const later = () => {\n // @ts-ignore\n func.apply(this, args);\n };\n clearTimeout(timeout);\n timeout = setTimeout(later, wait);\n }\n debounced.clear = () => {\n clearTimeout(timeout);\n };\n return debounced;\n}","export default function deprecatedPropType(validator, reason) {\n if (process.env.NODE_ENV === 'production') {\n return () => null;\n }\n return (props, propName, componentName, location, propFullName) => {\n const componentNameSafe = componentName || '<>';\n const propFullNameSafe = propFullName || propName;\n if (typeof props[propName] !== 'undefined') {\n return new Error(`The ${location} \\`${propFullNameSafe}\\` of ` + `\\`${componentNameSafe}\\` is deprecated. ${reason}`);\n }\n return null;\n };\n}","import * as React from 'react';\nexport default function isMuiElement(element, muiNames) {\n var _muiName, _element$type;\n return /*#__PURE__*/React.isValidElement(element) && muiNames.indexOf( // For server components `muiName` is avaialble in element.type._payload.value.muiName\n // relevant info - https://github.com/facebook/react/blob/2807d781a08db8e9873687fccc25c0f12b4fb3d4/packages/react/src/ReactLazy.js#L45\n // eslint-disable-next-line no-underscore-dangle\n (_muiName = element.type.muiName) != null ? _muiName : (_element$type = element.type) == null || (_element$type = _element$type._payload) == null || (_element$type = _element$type.value) == null ? void 0 : _element$type.muiName) !== -1;\n}","export default function ownerDocument(node) {\n return node && node.ownerDocument || document;\n}","import ownerDocument from '../ownerDocument';\nexport default function ownerWindow(node) {\n const doc = ownerDocument(node);\n return doc.defaultView || window;\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nexport default function requirePropFactory(componentNameInError, Component) {\n if (process.env.NODE_ENV === 'production') {\n return () => null;\n }\n\n // eslint-disable-next-line react/forbid-foreign-prop-types\n const prevPropTypes = Component ? _extends({}, Component.propTypes) : null;\n const requireProp = requiredProp => (props, propName, componentName, location, propFullName, ...args) => {\n const propFullNameSafe = propFullName || propName;\n const defaultTypeChecker = prevPropTypes == null ? void 0 : prevPropTypes[propFullNameSafe];\n if (defaultTypeChecker) {\n const typeCheckerResult = defaultTypeChecker(props, propName, componentName, location, propFullName, ...args);\n if (typeCheckerResult) {\n return typeCheckerResult;\n }\n }\n if (typeof props[propName] !== 'undefined' && !props[requiredProp]) {\n return new Error(`The prop \\`${propFullNameSafe}\\` of ` + `\\`${componentNameInError}\\` can only be used together with the \\`${requiredProp}\\` prop.`);\n }\n return null;\n };\n return requireProp;\n}","/**\n * TODO v5: consider making it private\n *\n * passes {value} to {ref}\n *\n * WARNING: Be sure to only call this inside a callback that is passed as a ref.\n * Otherwise, make sure to cleanup the previous {ref} if it changes. See\n * https://github.com/mui/material-ui/issues/13539\n *\n * Useful if you want to expose the ref of an inner component to the public API\n * while still using it inside the component.\n * @param ref A ref callback or ref object. If anything falsy, this is a no-op.\n */\nexport default function setRef(ref, value) {\n if (typeof ref === 'function') {\n ref(value);\n } else if (ref) {\n ref.current = value;\n }\n}","'use client';\n\nimport * as React from 'react';\n\n/**\n * A version of `React.useLayoutEffect` that does not show a warning when server-side rendering.\n * This is useful for effects that are only needed for client-side rendering but not for SSR.\n *\n * Before you use this hook, make sure to read https://gist.github.com/gaearon/e7d97cdf38a2907924ea12e4ebdf3c85\n * and confirm it doesn't apply to your use-case.\n */\nconst useEnhancedEffect = typeof window !== 'undefined' ? React.useLayoutEffect : React.useEffect;\nexport default useEnhancedEffect;","'use client';\n\nimport * as React from 'react';\nlet globalId = 0;\nfunction useGlobalId(idOverride) {\n const [defaultId, setDefaultId] = React.useState(idOverride);\n const id = idOverride || defaultId;\n React.useEffect(() => {\n if (defaultId == null) {\n // Fallback to this default id when possible.\n // Use the incrementing value for client-side rendering only.\n // We can't use it server-side.\n // If you want to use random values please consider the Birthday Problem: https://en.wikipedia.org/wiki/Birthday_problem\n globalId += 1;\n setDefaultId(`mui-${globalId}`);\n }\n }, [defaultId]);\n return id;\n}\n\n// downstream bundlers may remove unnecessary concatenation, but won't remove toString call -- Workaround for https://github.com/webpack/webpack/issues/14814\nconst maybeReactUseId = React['useId'.toString()];\n/**\n *\n * @example
    \n * @param idOverride\n * @returns {string}\n */\nexport default function useId(idOverride) {\n if (maybeReactUseId !== undefined) {\n const reactId = maybeReactUseId();\n return idOverride != null ? idOverride : reactId;\n }\n // eslint-disable-next-line react-hooks/rules-of-hooks -- `React.useId` is invariant at runtime.\n return useGlobalId(idOverride);\n}","export default function unsupportedProp(props, propName, componentName, location, propFullName) {\n if (process.env.NODE_ENV === 'production') {\n return null;\n }\n const propFullNameSafe = propFullName || propName;\n if (typeof props[propName] !== 'undefined') {\n return new Error(`The prop \\`${propFullNameSafe}\\` is not supported. Please remove it.`);\n }\n return null;\n}","'use client';\n\n/* eslint-disable react-hooks/rules-of-hooks, react-hooks/exhaustive-deps */\nimport * as React from 'react';\nexport default function useControlled({\n controlled,\n default: defaultProp,\n name,\n state = 'value'\n}) {\n // isControlled is ignored in the hook dependency lists as it should never change.\n const {\n current: isControlled\n } = React.useRef(controlled !== undefined);\n const [valueState, setValue] = React.useState(defaultProp);\n const value = isControlled ? controlled : valueState;\n if (process.env.NODE_ENV !== 'production') {\n React.useEffect(() => {\n if (isControlled !== (controlled !== undefined)) {\n console.error([`MUI: A component is changing the ${isControlled ? '' : 'un'}controlled ${state} state of ${name} to be ${isControlled ? 'un' : ''}controlled.`, 'Elements should not switch from uncontrolled to controlled (or vice versa).', `Decide between using a controlled or uncontrolled ${name} ` + 'element for the lifetime of the component.', \"The nature of the state is determined during the first render. It's considered controlled if the value is not `undefined`.\", 'More info: https://fb.me/react-controlled-components'].join('\\n'));\n }\n }, [state, name, controlled]);\n const {\n current: defaultValue\n } = React.useRef(defaultProp);\n React.useEffect(() => {\n if (!isControlled && defaultValue !== defaultProp) {\n console.error([`MUI: A component is changing the default ${state} state of an uncontrolled ${name} after being initialized. ` + `To suppress this warning opt to use a controlled ${name}.`].join('\\n'));\n }\n }, [JSON.stringify(defaultProp)]);\n }\n const setValueIfUncontrolled = React.useCallback(newValue => {\n if (!isControlled) {\n setValue(newValue);\n }\n }, []);\n return [value, setValueIfUncontrolled];\n}","'use client';\n\nimport * as React from 'react';\nimport useEnhancedEffect from '../useEnhancedEffect';\n\n/**\n * Inspired by https://github.com/facebook/react/issues/14099#issuecomment-440013892\n * See RFC in https://github.com/reactjs/rfcs/pull/220\n */\n\nfunction useEventCallback(fn) {\n const ref = React.useRef(fn);\n useEnhancedEffect(() => {\n ref.current = fn;\n });\n return React.useRef((...args) =>\n // @ts-expect-error hide `this`\n (0, ref.current)(...args)).current;\n}\nexport default useEventCallback;","'use client';\n\nimport * as React from 'react';\nimport setRef from '../setRef';\nexport default function useForkRef(...refs) {\n /**\n * This will create a new function if the refs passed to this hook change and are all defined.\n * This means react will call the old forkRef with `null` and the new forkRef\n * with the ref. Cleanup naturally emerges from this behavior.\n */\n return React.useMemo(() => {\n if (refs.every(ref => ref == null)) {\n return null;\n }\n return instance => {\n refs.forEach(ref => {\n setRef(ref, instance);\n });\n };\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, refs);\n}","'use client';\n\nimport * as React from 'react';\nconst UNINITIALIZED = {};\n\n/**\n * A React.useRef() that is initialized lazily with a function. Note that it accepts an optional\n * initialization argument, so the initialization function doesn't need to be an inline closure.\n *\n * @usage\n * const ref = useLazyRef(sortColumns, columns)\n */\nexport default function useLazyRef(init, initArg) {\n const ref = React.useRef(UNINITIALIZED);\n if (ref.current === UNINITIALIZED) {\n ref.current = init(initArg);\n }\n return ref;\n}","'use client';\n\nimport * as React from 'react';\nconst EMPTY = [];\n\n/**\n * A React.useEffect equivalent that runs once, when the component is mounted.\n */\nexport default function useOnMount(fn) {\n /* eslint-disable react-hooks/exhaustive-deps */\n React.useEffect(fn, EMPTY);\n /* eslint-enable react-hooks/exhaustive-deps */\n}","'use client';\n\nimport useLazyRef from '../useLazyRef/useLazyRef';\nimport useOnMount from '../useOnMount/useOnMount';\nexport class Timeout {\n constructor() {\n this.currentId = null;\n this.clear = () => {\n if (this.currentId !== null) {\n clearTimeout(this.currentId);\n this.currentId = null;\n }\n };\n this.disposeEffect = () => {\n return this.clear;\n };\n }\n static create() {\n return new Timeout();\n }\n /**\n * Executes `fn` after `delay`, clearing any previously scheduled call.\n */\n start(delay, fn) {\n this.clear();\n this.currentId = setTimeout(() => {\n this.currentId = null;\n fn();\n }, delay);\n }\n}\nexport default function useTimeout() {\n const timeout = useLazyRef(Timeout.create).current;\n useOnMount(timeout.disposeEffect);\n return timeout;\n}","'use client';\n\n// based on https://github.com/WICG/focus-visible/blob/v4.1.5/src/focus-visible.js\nimport * as React from 'react';\nimport { Timeout } from '../useTimeout/useTimeout';\nlet hadKeyboardEvent = true;\nlet hadFocusVisibleRecently = false;\nconst hadFocusVisibleRecentlyTimeout = new Timeout();\nconst inputTypesWhitelist = {\n text: true,\n search: true,\n url: true,\n tel: true,\n email: true,\n password: true,\n number: true,\n date: true,\n month: true,\n week: true,\n time: true,\n datetime: true,\n 'datetime-local': true\n};\n\n/**\n * Computes whether the given element should automatically trigger the\n * `focus-visible` class being added, i.e. whether it should always match\n * `:focus-visible` when focused.\n * @param {Element} node\n * @returns {boolean}\n */\nfunction focusTriggersKeyboardModality(node) {\n const {\n type,\n tagName\n } = node;\n if (tagName === 'INPUT' && inputTypesWhitelist[type] && !node.readOnly) {\n return true;\n }\n if (tagName === 'TEXTAREA' && !node.readOnly) {\n return true;\n }\n if (node.isContentEditable) {\n return true;\n }\n return false;\n}\n\n/**\n * Keep track of our keyboard modality state with `hadKeyboardEvent`.\n * If the most recent user interaction was via the keyboard;\n * and the key press did not include a meta, alt/option, or control key;\n * then the modality is keyboard. Otherwise, the modality is not keyboard.\n * @param {KeyboardEvent} event\n */\nfunction handleKeyDown(event) {\n if (event.metaKey || event.altKey || event.ctrlKey) {\n return;\n }\n hadKeyboardEvent = true;\n}\n\n/**\n * If at any point a user clicks with a pointing device, ensure that we change\n * the modality away from keyboard.\n * This avoids the situation where a user presses a key on an already focused\n * element, and then clicks on a different element, focusing it with a\n * pointing device, while we still think we're in keyboard modality.\n */\nfunction handlePointerDown() {\n hadKeyboardEvent = false;\n}\nfunction handleVisibilityChange() {\n if (this.visibilityState === 'hidden') {\n // If the tab becomes active again, the browser will handle calling focus\n // on the element (Safari actually calls it twice).\n // If this tab change caused a blur on an element with focus-visible,\n // re-apply the class when the user switches back to the tab.\n if (hadFocusVisibleRecently) {\n hadKeyboardEvent = true;\n }\n }\n}\nfunction prepare(doc) {\n doc.addEventListener('keydown', handleKeyDown, true);\n doc.addEventListener('mousedown', handlePointerDown, true);\n doc.addEventListener('pointerdown', handlePointerDown, true);\n doc.addEventListener('touchstart', handlePointerDown, true);\n doc.addEventListener('visibilitychange', handleVisibilityChange, true);\n}\nexport function teardown(doc) {\n doc.removeEventListener('keydown', handleKeyDown, true);\n doc.removeEventListener('mousedown', handlePointerDown, true);\n doc.removeEventListener('pointerdown', handlePointerDown, true);\n doc.removeEventListener('touchstart', handlePointerDown, true);\n doc.removeEventListener('visibilitychange', handleVisibilityChange, true);\n}\nfunction isFocusVisible(event) {\n const {\n target\n } = event;\n try {\n return target.matches(':focus-visible');\n } catch (error) {\n // Browsers not implementing :focus-visible will throw a SyntaxError.\n // We use our own heuristic for those browsers.\n // Rethrow might be better if it's not the expected error but do we really\n // want to crash if focus-visible malfunctioned?\n }\n\n // No need for validFocusTarget check. The user does that by attaching it to\n // focusable events only.\n return hadKeyboardEvent || focusTriggersKeyboardModality(target);\n}\nexport default function useIsFocusVisible() {\n const ref = React.useCallback(node => {\n if (node != null) {\n prepare(node.ownerDocument);\n }\n }, []);\n const isFocusVisibleRef = React.useRef(false);\n\n /**\n * Should be called if a blur event is fired\n */\n function handleBlurVisible() {\n // checking against potential state variable does not suffice if we focus and blur synchronously.\n // React wouldn't have time to trigger a re-render so `focusVisible` would be stale.\n // Ideally we would adjust `isFocusVisible(event)` to look at `relatedTarget` for blur events.\n // This doesn't work in IE11 due to https://github.com/facebook/react/issues/3751\n // TODO: check again if React releases their internal changes to focus event handling (https://github.com/facebook/react/pull/19186).\n if (isFocusVisibleRef.current) {\n // To detect a tab/window switch, we look for a blur event followed\n // rapidly by a visibility change.\n // If we don't see a visibility change within 100ms, it's probably a\n // regular focus change.\n hadFocusVisibleRecently = true;\n hadFocusVisibleRecentlyTimeout.start(100, () => {\n hadFocusVisibleRecently = false;\n });\n isFocusVisibleRef.current = false;\n return true;\n }\n return false;\n }\n\n /**\n * Should be called if a blur event is fired\n */\n function handleFocusVisible(event) {\n if (isFocusVisible(event)) {\n isFocusVisibleRef.current = true;\n return true;\n }\n return false;\n }\n return {\n isFocusVisibleRef,\n onFocus: handleFocusVisible,\n onBlur: handleBlurVisible,\n ref\n };\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\n/**\n * Add keys, values of `defaultProps` that does not exist in `props`\n * @param {object} defaultProps\n * @param {object} props\n * @returns {object} resolved props\n */\nexport default function resolveProps(defaultProps, props) {\n const output = _extends({}, props);\n Object.keys(defaultProps).forEach(propName => {\n if (propName.toString().match(/^(components|slots)$/)) {\n output[propName] = _extends({}, defaultProps[propName], output[propName]);\n } else if (propName.toString().match(/^(componentsProps|slotProps)$/)) {\n const defaultSlotProps = defaultProps[propName] || {};\n const slotProps = props[propName];\n output[propName] = {};\n if (!slotProps || !Object.keys(slotProps)) {\n // Reduce the iteration if the slot props is empty\n output[propName] = defaultSlotProps;\n } else if (!defaultSlotProps || !Object.keys(defaultSlotProps)) {\n // Reduce the iteration if the default slot props is empty\n output[propName] = slotProps;\n } else {\n output[propName] = _extends({}, slotProps);\n Object.keys(defaultSlotProps).forEach(slotPropName => {\n output[propName][slotPropName] = resolveProps(defaultSlotProps[slotPropName], slotProps[slotPropName]);\n });\n }\n } else if (output[propName] === undefined) {\n output[propName] = defaultProps[propName];\n }\n });\n return output;\n}","export default function composeClasses(slots, getUtilityClass, classes = undefined) {\n const output = {};\n Object.keys(slots).forEach(\n // `Object.keys(slots)` can't be wider than `T` because we infer `T` from `slots`.\n // @ts-expect-error https://github.com/microsoft/TypeScript/pull/12253#issuecomment-263132208\n slot => {\n output[slot] = slots[slot].reduce((acc, key) => {\n if (key) {\n const utilityClass = getUtilityClass(key);\n if (utilityClass !== '') {\n acc.push(utilityClass);\n }\n if (classes && classes[key]) {\n acc.push(classes[key]);\n }\n }\n return acc;\n }, []).join(' ');\n });\n return output;\n}","const defaultGenerator = componentName => componentName;\nconst createClassNameGenerator = () => {\n let generate = defaultGenerator;\n return {\n configure(generator) {\n generate = generator;\n },\n generate(componentName) {\n return generate(componentName);\n },\n reset() {\n generate = defaultGenerator;\n }\n };\n};\nconst ClassNameGenerator = createClassNameGenerator();\nexport default ClassNameGenerator;","import ClassNameGenerator from '../ClassNameGenerator';\nexport const globalStateClasses = {\n active: 'active',\n checked: 'checked',\n completed: 'completed',\n disabled: 'disabled',\n error: 'error',\n expanded: 'expanded',\n focused: 'focused',\n focusVisible: 'focusVisible',\n open: 'open',\n readOnly: 'readOnly',\n required: 'required',\n selected: 'selected'\n};\nexport default function generateUtilityClass(componentName, slot, globalStatePrefix = 'Mui') {\n const globalStateClass = globalStateClasses[slot];\n return globalStateClass ? `${globalStatePrefix}-${globalStateClass}` : `${ClassNameGenerator.generate(componentName)}-${slot}`;\n}\nexport function isGlobalState(slot) {\n return globalStateClasses[slot] !== undefined;\n}","import generateUtilityClass from '../generateUtilityClass';\nexport default function generateUtilityClasses(componentName, slots, globalStatePrefix = 'Mui') {\n const result = {};\n slots.forEach(slot => {\n result[slot] = generateUtilityClass(componentName, slot, globalStatePrefix);\n });\n return result;\n}","function clamp(val, min = Number.MIN_SAFE_INTEGER, max = Number.MAX_SAFE_INTEGER) {\n return Math.max(min, Math.min(val, max));\n}\nexport default clamp;","export default function _objectWithoutPropertiesLoose(source, excluded) {\n if (source == null) return {};\n var target = {};\n var sourceKeys = Object.keys(source);\n var key, i;\n for (i = 0; i < sourceKeys.length; i++) {\n key = sourceKeys[i];\n if (excluded.indexOf(key) >= 0) continue;\n target[key] = source[key];\n }\n return target;\n}","import _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nconst _excluded = [\"values\", \"unit\", \"step\"];\n// Sorted ASC by size. That's important.\n// It can't be configured as it's used statically for propTypes.\nexport const breakpointKeys = ['xs', 'sm', 'md', 'lg', 'xl'];\nconst sortBreakpointsValues = values => {\n const breakpointsAsArray = Object.keys(values).map(key => ({\n key,\n val: values[key]\n })) || [];\n // Sort in ascending order\n breakpointsAsArray.sort((breakpoint1, breakpoint2) => breakpoint1.val - breakpoint2.val);\n return breakpointsAsArray.reduce((acc, obj) => {\n return _extends({}, acc, {\n [obj.key]: obj.val\n });\n }, {});\n};\n\n// Keep in mind that @media is inclusive by the CSS specification.\nexport default function createBreakpoints(breakpoints) {\n const {\n // The breakpoint **start** at this value.\n // For instance with the first breakpoint xs: [xs, sm).\n values = {\n xs: 0,\n // phone\n sm: 600,\n // tablet\n md: 900,\n // small laptop\n lg: 1200,\n // desktop\n xl: 1536 // large screen\n },\n unit = 'px',\n step = 5\n } = breakpoints,\n other = _objectWithoutPropertiesLoose(breakpoints, _excluded);\n const sortedValues = sortBreakpointsValues(values);\n const keys = Object.keys(sortedValues);\n function up(key) {\n const value = typeof values[key] === 'number' ? values[key] : key;\n return `@media (min-width:${value}${unit})`;\n }\n function down(key) {\n const value = typeof values[key] === 'number' ? values[key] : key;\n return `@media (max-width:${value - step / 100}${unit})`;\n }\n function between(start, end) {\n const endIndex = keys.indexOf(end);\n return `@media (min-width:${typeof values[start] === 'number' ? values[start] : start}${unit}) and ` + `(max-width:${(endIndex !== -1 && typeof values[keys[endIndex]] === 'number' ? values[keys[endIndex]] : end) - step / 100}${unit})`;\n }\n function only(key) {\n if (keys.indexOf(key) + 1 < keys.length) {\n return between(key, keys[keys.indexOf(key) + 1]);\n }\n return up(key);\n }\n function not(key) {\n // handle first and last key separately, for better readability\n const keyIndex = keys.indexOf(key);\n if (keyIndex === 0) {\n return up(keys[1]);\n }\n if (keyIndex === keys.length - 1) {\n return down(keys[keyIndex]);\n }\n return between(key, keys[keys.indexOf(key) + 1]).replace('@media', '@media not all and');\n }\n return _extends({\n keys,\n values: sortedValues,\n up,\n down,\n between,\n only,\n not,\n unit\n }, other);\n}","const shape = {\n borderRadius: 4\n};\nexport default shape;","import PropTypes from 'prop-types';\nconst responsivePropType = process.env.NODE_ENV !== 'production' ? PropTypes.oneOfType([PropTypes.number, PropTypes.string, PropTypes.object, PropTypes.array]) : {};\nexport default responsivePropType;","import deepmerge from '@mui/utils/deepmerge';\nfunction merge(acc, item) {\n if (!item) {\n return acc;\n }\n return deepmerge(acc, item, {\n clone: false // No need to clone deep, it's way faster.\n });\n}\nexport default merge;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport PropTypes from 'prop-types';\nimport deepmerge from '@mui/utils/deepmerge';\nimport merge from './merge';\n\n// The breakpoint **start** at this value.\n// For instance with the first breakpoint xs: [xs, sm[.\nexport const values = {\n xs: 0,\n // phone\n sm: 600,\n // tablet\n md: 900,\n // small laptop\n lg: 1200,\n // desktop\n xl: 1536 // large screen\n};\nconst defaultBreakpoints = {\n // Sorted ASC by size. That's important.\n // It can't be configured as it's used statically for propTypes.\n keys: ['xs', 'sm', 'md', 'lg', 'xl'],\n up: key => `@media (min-width:${values[key]}px)`\n};\nexport function handleBreakpoints(props, propValue, styleFromPropValue) {\n const theme = props.theme || {};\n if (Array.isArray(propValue)) {\n const themeBreakpoints = theme.breakpoints || defaultBreakpoints;\n return propValue.reduce((acc, item, index) => {\n acc[themeBreakpoints.up(themeBreakpoints.keys[index])] = styleFromPropValue(propValue[index]);\n return acc;\n }, {});\n }\n if (typeof propValue === 'object') {\n const themeBreakpoints = theme.breakpoints || defaultBreakpoints;\n return Object.keys(propValue).reduce((acc, breakpoint) => {\n // key is breakpoint\n if (Object.keys(themeBreakpoints.values || values).indexOf(breakpoint) !== -1) {\n const mediaKey = themeBreakpoints.up(breakpoint);\n acc[mediaKey] = styleFromPropValue(propValue[breakpoint], breakpoint);\n } else {\n const cssKey = breakpoint;\n acc[cssKey] = propValue[cssKey];\n }\n return acc;\n }, {});\n }\n const output = styleFromPropValue(propValue);\n return output;\n}\nfunction breakpoints(styleFunction) {\n // false positive\n // eslint-disable-next-line react/function-component-definition\n const newStyleFunction = props => {\n const theme = props.theme || {};\n const base = styleFunction(props);\n const themeBreakpoints = theme.breakpoints || defaultBreakpoints;\n const extended = themeBreakpoints.keys.reduce((acc, key) => {\n if (props[key]) {\n acc = acc || {};\n acc[themeBreakpoints.up(key)] = styleFunction(_extends({\n theme\n }, props[key]));\n }\n return acc;\n }, null);\n return merge(base, extended);\n };\n newStyleFunction.propTypes = process.env.NODE_ENV !== 'production' ? _extends({}, styleFunction.propTypes, {\n xs: PropTypes.object,\n sm: PropTypes.object,\n md: PropTypes.object,\n lg: PropTypes.object,\n xl: PropTypes.object\n }) : {};\n newStyleFunction.filterProps = ['xs', 'sm', 'md', 'lg', 'xl', ...styleFunction.filterProps];\n return newStyleFunction;\n}\nexport function createEmptyBreakpointObject(breakpointsInput = {}) {\n var _breakpointsInput$key;\n const breakpointsInOrder = (_breakpointsInput$key = breakpointsInput.keys) == null ? void 0 : _breakpointsInput$key.reduce((acc, key) => {\n const breakpointStyleKey = breakpointsInput.up(key);\n acc[breakpointStyleKey] = {};\n return acc;\n }, {});\n return breakpointsInOrder || {};\n}\nexport function removeUnusedBreakpoints(breakpointKeys, style) {\n return breakpointKeys.reduce((acc, key) => {\n const breakpointOutput = acc[key];\n const isBreakpointUnused = !breakpointOutput || Object.keys(breakpointOutput).length === 0;\n if (isBreakpointUnused) {\n delete acc[key];\n }\n return acc;\n }, style);\n}\nexport function mergeBreakpointsInOrder(breakpointsInput, ...styles) {\n const emptyBreakpoints = createEmptyBreakpointObject(breakpointsInput);\n const mergedOutput = [emptyBreakpoints, ...styles].reduce((prev, next) => deepmerge(prev, next), {});\n return removeUnusedBreakpoints(Object.keys(emptyBreakpoints), mergedOutput);\n}\n\n// compute base for responsive values; e.g.,\n// [1,2,3] => {xs: true, sm: true, md: true}\n// {xs: 1, sm: 2, md: 3} => {xs: true, sm: true, md: true}\nexport function computeBreakpointsBase(breakpointValues, themeBreakpoints) {\n // fixed value\n if (typeof breakpointValues !== 'object') {\n return {};\n }\n const base = {};\n const breakpointsKeys = Object.keys(themeBreakpoints);\n if (Array.isArray(breakpointValues)) {\n breakpointsKeys.forEach((breakpoint, i) => {\n if (i < breakpointValues.length) {\n base[breakpoint] = true;\n }\n });\n } else {\n breakpointsKeys.forEach(breakpoint => {\n if (breakpointValues[breakpoint] != null) {\n base[breakpoint] = true;\n }\n });\n }\n return base;\n}\nexport function resolveBreakpointValues({\n values: breakpointValues,\n breakpoints: themeBreakpoints,\n base: customBase\n}) {\n const base = customBase || computeBreakpointsBase(breakpointValues, themeBreakpoints);\n const keys = Object.keys(base);\n if (keys.length === 0) {\n return breakpointValues;\n }\n let previous;\n return keys.reduce((acc, breakpoint, i) => {\n if (Array.isArray(breakpointValues)) {\n acc[breakpoint] = breakpointValues[i] != null ? breakpointValues[i] : breakpointValues[previous];\n previous = i;\n } else if (typeof breakpointValues === 'object') {\n acc[breakpoint] = breakpointValues[breakpoint] != null ? breakpointValues[breakpoint] : breakpointValues[previous];\n previous = breakpoint;\n } else {\n acc[breakpoint] = breakpointValues;\n }\n return acc;\n }, {});\n}\nexport default breakpoints;","import capitalize from '@mui/utils/capitalize';\nimport responsivePropType from './responsivePropType';\nimport { handleBreakpoints } from './breakpoints';\nexport function getPath(obj, path, checkVars = true) {\n if (!path || typeof path !== 'string') {\n return null;\n }\n\n // Check if CSS variables are used\n if (obj && obj.vars && checkVars) {\n const val = `vars.${path}`.split('.').reduce((acc, item) => acc && acc[item] ? acc[item] : null, obj);\n if (val != null) {\n return val;\n }\n }\n return path.split('.').reduce((acc, item) => {\n if (acc && acc[item] != null) {\n return acc[item];\n }\n return null;\n }, obj);\n}\nexport function getStyleValue(themeMapping, transform, propValueFinal, userValue = propValueFinal) {\n let value;\n if (typeof themeMapping === 'function') {\n value = themeMapping(propValueFinal);\n } else if (Array.isArray(themeMapping)) {\n value = themeMapping[propValueFinal] || userValue;\n } else {\n value = getPath(themeMapping, propValueFinal) || userValue;\n }\n if (transform) {\n value = transform(value, userValue, themeMapping);\n }\n return value;\n}\nfunction style(options) {\n const {\n prop,\n cssProperty = options.prop,\n themeKey,\n transform\n } = options;\n\n // false positive\n // eslint-disable-next-line react/function-component-definition\n const fn = props => {\n if (props[prop] == null) {\n return null;\n }\n const propValue = props[prop];\n const theme = props.theme;\n const themeMapping = getPath(theme, themeKey) || {};\n const styleFromPropValue = propValueFinal => {\n let value = getStyleValue(themeMapping, transform, propValueFinal);\n if (propValueFinal === value && typeof propValueFinal === 'string') {\n // Haven't found value\n value = getStyleValue(themeMapping, transform, `${prop}${propValueFinal === 'default' ? '' : capitalize(propValueFinal)}`, propValueFinal);\n }\n if (cssProperty === false) {\n return value;\n }\n return {\n [cssProperty]: value\n };\n };\n return handleBreakpoints(props, propValue, styleFromPropValue);\n };\n fn.propTypes = process.env.NODE_ENV !== 'production' ? {\n [prop]: responsivePropType\n } : {};\n fn.filterProps = [prop];\n return fn;\n}\nexport default style;","export default function memoize(fn) {\n const cache = {};\n return arg => {\n if (cache[arg] === undefined) {\n cache[arg] = fn(arg);\n }\n return cache[arg];\n };\n}","import responsivePropType from './responsivePropType';\nimport { handleBreakpoints } from './breakpoints';\nimport { getPath } from './style';\nimport merge from './merge';\nimport memoize from './memoize';\nconst properties = {\n m: 'margin',\n p: 'padding'\n};\nconst directions = {\n t: 'Top',\n r: 'Right',\n b: 'Bottom',\n l: 'Left',\n x: ['Left', 'Right'],\n y: ['Top', 'Bottom']\n};\nconst aliases = {\n marginX: 'mx',\n marginY: 'my',\n paddingX: 'px',\n paddingY: 'py'\n};\n\n// memoize() impact:\n// From 300,000 ops/sec\n// To 350,000 ops/sec\nconst getCssProperties = memoize(prop => {\n // It's not a shorthand notation.\n if (prop.length > 2) {\n if (aliases[prop]) {\n prop = aliases[prop];\n } else {\n return [prop];\n }\n }\n const [a, b] = prop.split('');\n const property = properties[a];\n const direction = directions[b] || '';\n return Array.isArray(direction) ? direction.map(dir => property + dir) : [property + direction];\n});\nexport const marginKeys = ['m', 'mt', 'mr', 'mb', 'ml', 'mx', 'my', 'margin', 'marginTop', 'marginRight', 'marginBottom', 'marginLeft', 'marginX', 'marginY', 'marginInline', 'marginInlineStart', 'marginInlineEnd', 'marginBlock', 'marginBlockStart', 'marginBlockEnd'];\nexport const paddingKeys = ['p', 'pt', 'pr', 'pb', 'pl', 'px', 'py', 'padding', 'paddingTop', 'paddingRight', 'paddingBottom', 'paddingLeft', 'paddingX', 'paddingY', 'paddingInline', 'paddingInlineStart', 'paddingInlineEnd', 'paddingBlock', 'paddingBlockStart', 'paddingBlockEnd'];\nconst spacingKeys = [...marginKeys, ...paddingKeys];\nexport function createUnaryUnit(theme, themeKey, defaultValue, propName) {\n var _getPath;\n const themeSpacing = (_getPath = getPath(theme, themeKey, false)) != null ? _getPath : defaultValue;\n if (typeof themeSpacing === 'number') {\n return abs => {\n if (typeof abs === 'string') {\n return abs;\n }\n if (process.env.NODE_ENV !== 'production') {\n if (typeof abs !== 'number') {\n console.error(`MUI: Expected ${propName} argument to be a number or a string, got ${abs}.`);\n }\n }\n return themeSpacing * abs;\n };\n }\n if (Array.isArray(themeSpacing)) {\n return abs => {\n if (typeof abs === 'string') {\n return abs;\n }\n if (process.env.NODE_ENV !== 'production') {\n if (!Number.isInteger(abs)) {\n console.error([`MUI: The \\`theme.${themeKey}\\` array type cannot be combined with non integer values.` + `You should either use an integer value that can be used as index, or define the \\`theme.${themeKey}\\` as a number.`].join('\\n'));\n } else if (abs > themeSpacing.length - 1) {\n console.error([`MUI: The value provided (${abs}) overflows.`, `The supported values are: ${JSON.stringify(themeSpacing)}.`, `${abs} > ${themeSpacing.length - 1}, you need to add the missing values.`].join('\\n'));\n }\n }\n return themeSpacing[abs];\n };\n }\n if (typeof themeSpacing === 'function') {\n return themeSpacing;\n }\n if (process.env.NODE_ENV !== 'production') {\n console.error([`MUI: The \\`theme.${themeKey}\\` value (${themeSpacing}) is invalid.`, 'It should be a number, an array or a function.'].join('\\n'));\n }\n return () => undefined;\n}\nexport function createUnarySpacing(theme) {\n return createUnaryUnit(theme, 'spacing', 8, 'spacing');\n}\nexport function getValue(transformer, propValue) {\n if (typeof propValue === 'string' || propValue == null) {\n return propValue;\n }\n const abs = Math.abs(propValue);\n const transformed = transformer(abs);\n if (propValue >= 0) {\n return transformed;\n }\n if (typeof transformed === 'number') {\n return -transformed;\n }\n return `-${transformed}`;\n}\nexport function getStyleFromPropValue(cssProperties, transformer) {\n return propValue => cssProperties.reduce((acc, cssProperty) => {\n acc[cssProperty] = getValue(transformer, propValue);\n return acc;\n }, {});\n}\nfunction resolveCssProperty(props, keys, prop, transformer) {\n // Using a hash computation over an array iteration could be faster, but with only 28 items,\n // it's doesn't worth the bundle size.\n if (keys.indexOf(prop) === -1) {\n return null;\n }\n const cssProperties = getCssProperties(prop);\n const styleFromPropValue = getStyleFromPropValue(cssProperties, transformer);\n const propValue = props[prop];\n return handleBreakpoints(props, propValue, styleFromPropValue);\n}\nfunction style(props, keys) {\n const transformer = createUnarySpacing(props.theme);\n return Object.keys(props).map(prop => resolveCssProperty(props, keys, prop, transformer)).reduce(merge, {});\n}\nexport function margin(props) {\n return style(props, marginKeys);\n}\nmargin.propTypes = process.env.NODE_ENV !== 'production' ? marginKeys.reduce((obj, key) => {\n obj[key] = responsivePropType;\n return obj;\n}, {}) : {};\nmargin.filterProps = marginKeys;\nexport function padding(props) {\n return style(props, paddingKeys);\n}\npadding.propTypes = process.env.NODE_ENV !== 'production' ? paddingKeys.reduce((obj, key) => {\n obj[key] = responsivePropType;\n return obj;\n}, {}) : {};\npadding.filterProps = paddingKeys;\nfunction spacing(props) {\n return style(props, spacingKeys);\n}\nspacing.propTypes = process.env.NODE_ENV !== 'production' ? spacingKeys.reduce((obj, key) => {\n obj[key] = responsivePropType;\n return obj;\n}, {}) : {};\nspacing.filterProps = spacingKeys;\nexport default spacing;","import { createUnarySpacing } from '../spacing';\n\n// The different signatures imply different meaning for their arguments that can't be expressed structurally.\n// We express the difference with variable names.\n\nexport default function createSpacing(spacingInput = 8) {\n // Already transformed.\n if (spacingInput.mui) {\n return spacingInput;\n }\n\n // Material Design layouts are visually balanced. Most measurements align to an 8dp grid, which aligns both spacing and the overall layout.\n // Smaller components, such as icons, can align to a 4dp grid.\n // https://m2.material.io/design/layout/understanding-layout.html\n const transform = createUnarySpacing({\n spacing: spacingInput\n });\n const spacing = (...argsInput) => {\n if (process.env.NODE_ENV !== 'production') {\n if (!(argsInput.length <= 4)) {\n console.error(`MUI: Too many arguments provided, expected between 0 and 4, got ${argsInput.length}`);\n }\n }\n const args = argsInput.length === 0 ? [1] : argsInput;\n return args.map(argument => {\n const output = transform(argument);\n return typeof output === 'number' ? `${output}px` : output;\n }).join(' ');\n };\n spacing.mui = true;\n return spacing;\n}","import merge from './merge';\nfunction compose(...styles) {\n const handlers = styles.reduce((acc, style) => {\n style.filterProps.forEach(prop => {\n acc[prop] = style;\n });\n return acc;\n }, {});\n\n // false positive\n // eslint-disable-next-line react/function-component-definition\n const fn = props => {\n return Object.keys(props).reduce((acc, prop) => {\n if (handlers[prop]) {\n return merge(acc, handlers[prop](props));\n }\n return acc;\n }, {});\n };\n fn.propTypes = process.env.NODE_ENV !== 'production' ? styles.reduce((acc, style) => Object.assign(acc, style.propTypes), {}) : {};\n fn.filterProps = styles.reduce((acc, style) => acc.concat(style.filterProps), []);\n return fn;\n}\nexport default compose;","import responsivePropType from './responsivePropType';\nimport style from './style';\nimport compose from './compose';\nimport { createUnaryUnit, getValue } from './spacing';\nimport { handleBreakpoints } from './breakpoints';\nexport function borderTransform(value) {\n if (typeof value !== 'number') {\n return value;\n }\n return `${value}px solid`;\n}\nfunction createBorderStyle(prop, transform) {\n return style({\n prop,\n themeKey: 'borders',\n transform\n });\n}\nexport const border = createBorderStyle('border', borderTransform);\nexport const borderTop = createBorderStyle('borderTop', borderTransform);\nexport const borderRight = createBorderStyle('borderRight', borderTransform);\nexport const borderBottom = createBorderStyle('borderBottom', borderTransform);\nexport const borderLeft = createBorderStyle('borderLeft', borderTransform);\nexport const borderColor = createBorderStyle('borderColor');\nexport const borderTopColor = createBorderStyle('borderTopColor');\nexport const borderRightColor = createBorderStyle('borderRightColor');\nexport const borderBottomColor = createBorderStyle('borderBottomColor');\nexport const borderLeftColor = createBorderStyle('borderLeftColor');\nexport const outline = createBorderStyle('outline', borderTransform);\nexport const outlineColor = createBorderStyle('outlineColor');\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const borderRadius = props => {\n if (props.borderRadius !== undefined && props.borderRadius !== null) {\n const transformer = createUnaryUnit(props.theme, 'shape.borderRadius', 4, 'borderRadius');\n const styleFromPropValue = propValue => ({\n borderRadius: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.borderRadius, styleFromPropValue);\n }\n return null;\n};\nborderRadius.propTypes = process.env.NODE_ENV !== 'production' ? {\n borderRadius: responsivePropType\n} : {};\nborderRadius.filterProps = ['borderRadius'];\nconst borders = compose(border, borderTop, borderRight, borderBottom, borderLeft, borderColor, borderTopColor, borderRightColor, borderBottomColor, borderLeftColor, borderRadius, outline, outlineColor);\nexport default borders;","import style from './style';\nimport compose from './compose';\nimport { createUnaryUnit, getValue } from './spacing';\nimport { handleBreakpoints } from './breakpoints';\nimport responsivePropType from './responsivePropType';\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const gap = props => {\n if (props.gap !== undefined && props.gap !== null) {\n const transformer = createUnaryUnit(props.theme, 'spacing', 8, 'gap');\n const styleFromPropValue = propValue => ({\n gap: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.gap, styleFromPropValue);\n }\n return null;\n};\ngap.propTypes = process.env.NODE_ENV !== 'production' ? {\n gap: responsivePropType\n} : {};\ngap.filterProps = ['gap'];\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const columnGap = props => {\n if (props.columnGap !== undefined && props.columnGap !== null) {\n const transformer = createUnaryUnit(props.theme, 'spacing', 8, 'columnGap');\n const styleFromPropValue = propValue => ({\n columnGap: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.columnGap, styleFromPropValue);\n }\n return null;\n};\ncolumnGap.propTypes = process.env.NODE_ENV !== 'production' ? {\n columnGap: responsivePropType\n} : {};\ncolumnGap.filterProps = ['columnGap'];\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const rowGap = props => {\n if (props.rowGap !== undefined && props.rowGap !== null) {\n const transformer = createUnaryUnit(props.theme, 'spacing', 8, 'rowGap');\n const styleFromPropValue = propValue => ({\n rowGap: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.rowGap, styleFromPropValue);\n }\n return null;\n};\nrowGap.propTypes = process.env.NODE_ENV !== 'production' ? {\n rowGap: responsivePropType\n} : {};\nrowGap.filterProps = ['rowGap'];\nexport const gridColumn = style({\n prop: 'gridColumn'\n});\nexport const gridRow = style({\n prop: 'gridRow'\n});\nexport const gridAutoFlow = style({\n prop: 'gridAutoFlow'\n});\nexport const gridAutoColumns = style({\n prop: 'gridAutoColumns'\n});\nexport const gridAutoRows = style({\n prop: 'gridAutoRows'\n});\nexport const gridTemplateColumns = style({\n prop: 'gridTemplateColumns'\n});\nexport const gridTemplateRows = style({\n prop: 'gridTemplateRows'\n});\nexport const gridTemplateAreas = style({\n prop: 'gridTemplateAreas'\n});\nexport const gridArea = style({\n prop: 'gridArea'\n});\nconst grid = compose(gap, columnGap, rowGap, gridColumn, gridRow, gridAutoFlow, gridAutoColumns, gridAutoRows, gridTemplateColumns, gridTemplateRows, gridTemplateAreas, gridArea);\nexport default grid;","import style from './style';\nimport compose from './compose';\nexport function paletteTransform(value, userValue) {\n if (userValue === 'grey') {\n return userValue;\n }\n return value;\n}\nexport const color = style({\n prop: 'color',\n themeKey: 'palette',\n transform: paletteTransform\n});\nexport const bgcolor = style({\n prop: 'bgcolor',\n cssProperty: 'backgroundColor',\n themeKey: 'palette',\n transform: paletteTransform\n});\nexport const backgroundColor = style({\n prop: 'backgroundColor',\n themeKey: 'palette',\n transform: paletteTransform\n});\nconst palette = compose(color, bgcolor, backgroundColor);\nexport default palette;","import style from './style';\nimport compose from './compose';\nimport { handleBreakpoints, values as breakpointsValues } from './breakpoints';\nexport function sizingTransform(value) {\n return value <= 1 && value !== 0 ? `${value * 100}%` : value;\n}\nexport const width = style({\n prop: 'width',\n transform: sizingTransform\n});\nexport const maxWidth = props => {\n if (props.maxWidth !== undefined && props.maxWidth !== null) {\n const styleFromPropValue = propValue => {\n var _props$theme, _props$theme2;\n const breakpoint = ((_props$theme = props.theme) == null || (_props$theme = _props$theme.breakpoints) == null || (_props$theme = _props$theme.values) == null ? void 0 : _props$theme[propValue]) || breakpointsValues[propValue];\n if (!breakpoint) {\n return {\n maxWidth: sizingTransform(propValue)\n };\n }\n if (((_props$theme2 = props.theme) == null || (_props$theme2 = _props$theme2.breakpoints) == null ? void 0 : _props$theme2.unit) !== 'px') {\n return {\n maxWidth: `${breakpoint}${props.theme.breakpoints.unit}`\n };\n }\n return {\n maxWidth: breakpoint\n };\n };\n return handleBreakpoints(props, props.maxWidth, styleFromPropValue);\n }\n return null;\n};\nmaxWidth.filterProps = ['maxWidth'];\nexport const minWidth = style({\n prop: 'minWidth',\n transform: sizingTransform\n});\nexport const height = style({\n prop: 'height',\n transform: sizingTransform\n});\nexport const maxHeight = style({\n prop: 'maxHeight',\n transform: sizingTransform\n});\nexport const minHeight = style({\n prop: 'minHeight',\n transform: sizingTransform\n});\nexport const sizeWidth = style({\n prop: 'size',\n cssProperty: 'width',\n transform: sizingTransform\n});\nexport const sizeHeight = style({\n prop: 'size',\n cssProperty: 'height',\n transform: sizingTransform\n});\nexport const boxSizing = style({\n prop: 'boxSizing'\n});\nconst sizing = compose(width, maxWidth, minWidth, height, maxHeight, minHeight, boxSizing);\nexport default sizing;","import { padding, margin } from '../spacing';\nimport { borderRadius, borderTransform } from '../borders';\nimport { gap, rowGap, columnGap } from '../cssGrid';\nimport { paletteTransform } from '../palette';\nimport { maxWidth, sizingTransform } from '../sizing';\nconst defaultSxConfig = {\n // borders\n border: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderTop: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderRight: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderBottom: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderLeft: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderColor: {\n themeKey: 'palette'\n },\n borderTopColor: {\n themeKey: 'palette'\n },\n borderRightColor: {\n themeKey: 'palette'\n },\n borderBottomColor: {\n themeKey: 'palette'\n },\n borderLeftColor: {\n themeKey: 'palette'\n },\n outline: {\n themeKey: 'borders',\n transform: borderTransform\n },\n outlineColor: {\n themeKey: 'palette'\n },\n borderRadius: {\n themeKey: 'shape.borderRadius',\n style: borderRadius\n },\n // palette\n color: {\n themeKey: 'palette',\n transform: paletteTransform\n },\n bgcolor: {\n themeKey: 'palette',\n cssProperty: 'backgroundColor',\n transform: paletteTransform\n },\n backgroundColor: {\n themeKey: 'palette',\n transform: paletteTransform\n },\n // spacing\n p: {\n style: padding\n },\n pt: {\n style: padding\n },\n pr: {\n style: padding\n },\n pb: {\n style: padding\n },\n pl: {\n style: padding\n },\n px: {\n style: padding\n },\n py: {\n style: padding\n },\n padding: {\n style: padding\n },\n paddingTop: {\n style: padding\n },\n paddingRight: {\n style: padding\n },\n paddingBottom: {\n style: padding\n },\n paddingLeft: {\n style: padding\n },\n paddingX: {\n style: padding\n },\n paddingY: {\n style: padding\n },\n paddingInline: {\n style: padding\n },\n paddingInlineStart: {\n style: padding\n },\n paddingInlineEnd: {\n style: padding\n },\n paddingBlock: {\n style: padding\n },\n paddingBlockStart: {\n style: padding\n },\n paddingBlockEnd: {\n style: padding\n },\n m: {\n style: margin\n },\n mt: {\n style: margin\n },\n mr: {\n style: margin\n },\n mb: {\n style: margin\n },\n ml: {\n style: margin\n },\n mx: {\n style: margin\n },\n my: {\n style: margin\n },\n margin: {\n style: margin\n },\n marginTop: {\n style: margin\n },\n marginRight: {\n style: margin\n },\n marginBottom: {\n style: margin\n },\n marginLeft: {\n style: margin\n },\n marginX: {\n style: margin\n },\n marginY: {\n style: margin\n },\n marginInline: {\n style: margin\n },\n marginInlineStart: {\n style: margin\n },\n marginInlineEnd: {\n style: margin\n },\n marginBlock: {\n style: margin\n },\n marginBlockStart: {\n style: margin\n },\n marginBlockEnd: {\n style: margin\n },\n // display\n displayPrint: {\n cssProperty: false,\n transform: value => ({\n '@media print': {\n display: value\n }\n })\n },\n display: {},\n overflow: {},\n textOverflow: {},\n visibility: {},\n whiteSpace: {},\n // flexbox\n flexBasis: {},\n flexDirection: {},\n flexWrap: {},\n justifyContent: {},\n alignItems: {},\n alignContent: {},\n order: {},\n flex: {},\n flexGrow: {},\n flexShrink: {},\n alignSelf: {},\n justifyItems: {},\n justifySelf: {},\n // grid\n gap: {\n style: gap\n },\n rowGap: {\n style: rowGap\n },\n columnGap: {\n style: columnGap\n },\n gridColumn: {},\n gridRow: {},\n gridAutoFlow: {},\n gridAutoColumns: {},\n gridAutoRows: {},\n gridTemplateColumns: {},\n gridTemplateRows: {},\n gridTemplateAreas: {},\n gridArea: {},\n // positions\n position: {},\n zIndex: {\n themeKey: 'zIndex'\n },\n top: {},\n right: {},\n bottom: {},\n left: {},\n // shadows\n boxShadow: {\n themeKey: 'shadows'\n },\n // sizing\n width: {\n transform: sizingTransform\n },\n maxWidth: {\n style: maxWidth\n },\n minWidth: {\n transform: sizingTransform\n },\n height: {\n transform: sizingTransform\n },\n maxHeight: {\n transform: sizingTransform\n },\n minHeight: {\n transform: sizingTransform\n },\n boxSizing: {},\n // typography\n fontFamily: {\n themeKey: 'typography'\n },\n fontSize: {\n themeKey: 'typography'\n },\n fontStyle: {\n themeKey: 'typography'\n },\n fontWeight: {\n themeKey: 'typography'\n },\n letterSpacing: {},\n textTransform: {},\n lineHeight: {},\n textAlign: {},\n typography: {\n cssProperty: false,\n themeKey: 'typography'\n }\n};\nexport default defaultSxConfig;","import capitalize from '@mui/utils/capitalize';\nimport merge from '../merge';\nimport { getPath, getStyleValue as getValue } from '../style';\nimport { handleBreakpoints, createEmptyBreakpointObject, removeUnusedBreakpoints } from '../breakpoints';\nimport defaultSxConfig from './defaultSxConfig';\nfunction objectsHaveSameKeys(...objects) {\n const allKeys = objects.reduce((keys, object) => keys.concat(Object.keys(object)), []);\n const union = new Set(allKeys);\n return objects.every(object => union.size === Object.keys(object).length);\n}\nfunction callIfFn(maybeFn, arg) {\n return typeof maybeFn === 'function' ? maybeFn(arg) : maybeFn;\n}\n\n// eslint-disable-next-line @typescript-eslint/naming-convention\nexport function unstable_createStyleFunctionSx() {\n function getThemeValue(prop, val, theme, config) {\n const props = {\n [prop]: val,\n theme\n };\n const options = config[prop];\n if (!options) {\n return {\n [prop]: val\n };\n }\n const {\n cssProperty = prop,\n themeKey,\n transform,\n style\n } = options;\n if (val == null) {\n return null;\n }\n\n // TODO v6: remove, see https://github.com/mui/material-ui/pull/38123\n if (themeKey === 'typography' && val === 'inherit') {\n return {\n [prop]: val\n };\n }\n const themeMapping = getPath(theme, themeKey) || {};\n if (style) {\n return style(props);\n }\n const styleFromPropValue = propValueFinal => {\n let value = getValue(themeMapping, transform, propValueFinal);\n if (propValueFinal === value && typeof propValueFinal === 'string') {\n // Haven't found value\n value = getValue(themeMapping, transform, `${prop}${propValueFinal === 'default' ? '' : capitalize(propValueFinal)}`, propValueFinal);\n }\n if (cssProperty === false) {\n return value;\n }\n return {\n [cssProperty]: value\n };\n };\n return handleBreakpoints(props, val, styleFromPropValue);\n }\n function styleFunctionSx(props) {\n var _theme$unstable_sxCon;\n const {\n sx,\n theme = {}\n } = props || {};\n if (!sx) {\n return null; // Emotion & styled-components will neglect null\n }\n const config = (_theme$unstable_sxCon = theme.unstable_sxConfig) != null ? _theme$unstable_sxCon : defaultSxConfig;\n\n /*\n * Receive `sxInput` as object or callback\n * and then recursively check keys & values to create media query object styles.\n * (the result will be used in `styled`)\n */\n function traverse(sxInput) {\n let sxObject = sxInput;\n if (typeof sxInput === 'function') {\n sxObject = sxInput(theme);\n } else if (typeof sxInput !== 'object') {\n // value\n return sxInput;\n }\n if (!sxObject) {\n return null;\n }\n const emptyBreakpoints = createEmptyBreakpointObject(theme.breakpoints);\n const breakpointsKeys = Object.keys(emptyBreakpoints);\n let css = emptyBreakpoints;\n Object.keys(sxObject).forEach(styleKey => {\n const value = callIfFn(sxObject[styleKey], theme);\n if (value !== null && value !== undefined) {\n if (typeof value === 'object') {\n if (config[styleKey]) {\n css = merge(css, getThemeValue(styleKey, value, theme, config));\n } else {\n const breakpointsValues = handleBreakpoints({\n theme\n }, value, x => ({\n [styleKey]: x\n }));\n if (objectsHaveSameKeys(breakpointsValues, value)) {\n css[styleKey] = styleFunctionSx({\n sx: value,\n theme\n });\n } else {\n css = merge(css, breakpointsValues);\n }\n }\n } else {\n css = merge(css, getThemeValue(styleKey, value, theme, config));\n }\n }\n });\n return removeUnusedBreakpoints(breakpointsKeys, css);\n }\n return Array.isArray(sx) ? sx.map(traverse) : traverse(sx);\n }\n return styleFunctionSx;\n}\nconst styleFunctionSx = unstable_createStyleFunctionSx();\nstyleFunctionSx.filterProps = ['sx'];\nexport default styleFunctionSx;","/**\n * A universal utility to style components with multiple color modes. Always use it from the theme object.\n * It works with:\n * - [Basic theme](https://mui.com/material-ui/customization/dark-mode/)\n * - [CSS theme variables](https://mui.com/material-ui/experimental-api/css-theme-variables/overview/)\n * - Zero-runtime engine\n *\n * Tips: Use an array over object spread and place `theme.applyStyles()` last.\n *\n * ✅ [{ background: '#e5e5e5' }, theme.applyStyles('dark', { background: '#1c1c1c' })]\n *\n * 🚫 { background: '#e5e5e5', ...theme.applyStyles('dark', { background: '#1c1c1c' })}\n *\n * @example\n * 1. using with `styled`:\n * ```jsx\n * const Component = styled('div')(({ theme }) => [\n * { background: '#e5e5e5' },\n * theme.applyStyles('dark', {\n * background: '#1c1c1c',\n * color: '#fff',\n * }),\n * ]);\n * ```\n *\n * @example\n * 2. using with `sx` prop:\n * ```jsx\n * [\n * { background: '#e5e5e5' },\n * theme.applyStyles('dark', {\n * background: '#1c1c1c',\n * color: '#fff',\n * }),\n * ]}\n * />\n * ```\n *\n * @example\n * 3. theming a component:\n * ```jsx\n * extendTheme({\n * components: {\n * MuiButton: {\n * styleOverrides: {\n * root: ({ theme }) => [\n * { background: '#e5e5e5' },\n * theme.applyStyles('dark', {\n * background: '#1c1c1c',\n * color: '#fff',\n * }),\n * ],\n * },\n * }\n * }\n * })\n *```\n */\nexport default function applyStyles(key, styles) {\n // @ts-expect-error this is 'any' type\n const theme = this;\n if (theme.vars && typeof theme.getColorSchemeSelector === 'function') {\n // If CssVarsProvider is used as a provider,\n // returns '* :where([data-mui-color-scheme=\"light|dark\"]) &'\n const selector = theme.getColorSchemeSelector(key).replace(/(\\[[^\\]]+\\])/, '*:where($1)');\n return {\n [selector]: styles\n };\n }\n if (theme.palette.mode === key) {\n return styles;\n }\n return {};\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"breakpoints\", \"palette\", \"spacing\", \"shape\"];\nimport deepmerge from '@mui/utils/deepmerge';\nimport createBreakpoints from './createBreakpoints';\nimport shape from './shape';\nimport createSpacing from './createSpacing';\nimport styleFunctionSx from '../styleFunctionSx/styleFunctionSx';\nimport defaultSxConfig from '../styleFunctionSx/defaultSxConfig';\nimport applyStyles from './applyStyles';\nfunction createTheme(options = {}, ...args) {\n const {\n breakpoints: breakpointsInput = {},\n palette: paletteInput = {},\n spacing: spacingInput,\n shape: shapeInput = {}\n } = options,\n other = _objectWithoutPropertiesLoose(options, _excluded);\n const breakpoints = createBreakpoints(breakpointsInput);\n const spacing = createSpacing(spacingInput);\n let muiTheme = deepmerge({\n breakpoints,\n direction: 'ltr',\n components: {},\n // Inject component definitions.\n palette: _extends({\n mode: 'light'\n }, paletteInput),\n spacing,\n shape: _extends({}, shape, shapeInput)\n }, other);\n muiTheme.applyStyles = applyStyles;\n muiTheme = args.reduce((acc, argument) => deepmerge(acc, argument), muiTheme);\n muiTheme.unstable_sxConfig = _extends({}, defaultSxConfig, other == null ? void 0 : other.unstable_sxConfig);\n muiTheme.unstable_sx = function sx(props) {\n return styleFunctionSx({\n sx: props,\n theme: this\n });\n };\n return muiTheme;\n}\nexport default createTheme;","'use client';\n\nimport * as React from 'react';\nimport { ThemeContext } from '@mui/styled-engine';\nfunction isObjectEmpty(obj) {\n return Object.keys(obj).length === 0;\n}\nfunction useTheme(defaultTheme = null) {\n const contextTheme = React.useContext(ThemeContext);\n return !contextTheme || isObjectEmpty(contextTheme) ? defaultTheme : contextTheme;\n}\nexport default useTheme;","'use client';\n\nimport createTheme from './createTheme';\nimport useThemeWithoutDefault from './useThemeWithoutDefault';\nexport const systemDefaultTheme = createTheme();\nfunction useTheme(defaultTheme = systemDefaultTheme) {\n return useThemeWithoutDefault(defaultTheme);\n}\nexport default useTheme;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"ownerState\"],\n _excluded2 = [\"variants\"],\n _excluded3 = [\"name\", \"slot\", \"skipVariantsResolver\", \"skipSx\", \"overridesResolver\"];\n/* eslint-disable no-underscore-dangle */\nimport styledEngineStyled, { internal_processStyles as processStyles } from '@mui/styled-engine';\nimport { isPlainObject } from '@mui/utils/deepmerge';\nimport capitalize from '@mui/utils/capitalize';\nimport getDisplayName from '@mui/utils/getDisplayName';\nimport createTheme from './createTheme';\nimport styleFunctionSx from './styleFunctionSx';\nfunction isEmpty(obj) {\n return Object.keys(obj).length === 0;\n}\n\n// https://github.com/emotion-js/emotion/blob/26ded6109fcd8ca9875cc2ce4564fee678a3f3c5/packages/styled/src/utils.js#L40\nfunction isStringTag(tag) {\n return typeof tag === 'string' &&\n // 96 is one less than the char code\n // for \"a\" so this is checking that\n // it's a lowercase character\n tag.charCodeAt(0) > 96;\n}\n\n// Update /system/styled/#api in case if this changes\nexport function shouldForwardProp(prop) {\n return prop !== 'ownerState' && prop !== 'theme' && prop !== 'sx' && prop !== 'as';\n}\nexport const systemDefaultTheme = createTheme();\nconst lowercaseFirstLetter = string => {\n if (!string) {\n return string;\n }\n return string.charAt(0).toLowerCase() + string.slice(1);\n};\nfunction resolveTheme({\n defaultTheme,\n theme,\n themeId\n}) {\n return isEmpty(theme) ? defaultTheme : theme[themeId] || theme;\n}\nfunction defaultOverridesResolver(slot) {\n if (!slot) {\n return null;\n }\n return (props, styles) => styles[slot];\n}\nfunction processStyleArg(callableStyle, _ref) {\n let {\n ownerState\n } = _ref,\n props = _objectWithoutPropertiesLoose(_ref, _excluded);\n const resolvedStylesArg = typeof callableStyle === 'function' ? callableStyle(_extends({\n ownerState\n }, props)) : callableStyle;\n if (Array.isArray(resolvedStylesArg)) {\n return resolvedStylesArg.flatMap(resolvedStyle => processStyleArg(resolvedStyle, _extends({\n ownerState\n }, props)));\n }\n if (!!resolvedStylesArg && typeof resolvedStylesArg === 'object' && Array.isArray(resolvedStylesArg.variants)) {\n const {\n variants = []\n } = resolvedStylesArg,\n otherStyles = _objectWithoutPropertiesLoose(resolvedStylesArg, _excluded2);\n let result = otherStyles;\n variants.forEach(variant => {\n let isMatch = true;\n if (typeof variant.props === 'function') {\n isMatch = variant.props(_extends({\n ownerState\n }, props, ownerState));\n } else {\n Object.keys(variant.props).forEach(key => {\n if ((ownerState == null ? void 0 : ownerState[key]) !== variant.props[key] && props[key] !== variant.props[key]) {\n isMatch = false;\n }\n });\n }\n if (isMatch) {\n if (!Array.isArray(result)) {\n result = [result];\n }\n result.push(typeof variant.style === 'function' ? variant.style(_extends({\n ownerState\n }, props, ownerState)) : variant.style);\n }\n });\n return result;\n }\n return resolvedStylesArg;\n}\nexport default function createStyled(input = {}) {\n const {\n themeId,\n defaultTheme = systemDefaultTheme,\n rootShouldForwardProp = shouldForwardProp,\n slotShouldForwardProp = shouldForwardProp\n } = input;\n const systemSx = props => {\n return styleFunctionSx(_extends({}, props, {\n theme: resolveTheme(_extends({}, props, {\n defaultTheme,\n themeId\n }))\n }));\n };\n systemSx.__mui_systemSx = true;\n return (tag, inputOptions = {}) => {\n // Filter out the `sx` style function from the previous styled component to prevent unnecessary styles generated by the composite components.\n processStyles(tag, styles => styles.filter(style => !(style != null && style.__mui_systemSx)));\n const {\n name: componentName,\n slot: componentSlot,\n skipVariantsResolver: inputSkipVariantsResolver,\n skipSx: inputSkipSx,\n // TODO v6: remove `lowercaseFirstLetter()` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n overridesResolver = defaultOverridesResolver(lowercaseFirstLetter(componentSlot))\n } = inputOptions,\n options = _objectWithoutPropertiesLoose(inputOptions, _excluded3);\n\n // if skipVariantsResolver option is defined, take the value, otherwise, true for root and false for other slots.\n const skipVariantsResolver = inputSkipVariantsResolver !== undefined ? inputSkipVariantsResolver :\n // TODO v6: remove `Root` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n componentSlot && componentSlot !== 'Root' && componentSlot !== 'root' || false;\n const skipSx = inputSkipSx || false;\n let label;\n if (process.env.NODE_ENV !== 'production') {\n if (componentName) {\n // TODO v6: remove `lowercaseFirstLetter()` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n label = `${componentName}-${lowercaseFirstLetter(componentSlot || 'Root')}`;\n }\n }\n let shouldForwardPropOption = shouldForwardProp;\n\n // TODO v6: remove `Root` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n if (componentSlot === 'Root' || componentSlot === 'root') {\n shouldForwardPropOption = rootShouldForwardProp;\n } else if (componentSlot) {\n // any other slot specified\n shouldForwardPropOption = slotShouldForwardProp;\n } else if (isStringTag(tag)) {\n // for string (html) tag, preserve the behavior in emotion & styled-components.\n shouldForwardPropOption = undefined;\n }\n const defaultStyledResolver = styledEngineStyled(tag, _extends({\n shouldForwardProp: shouldForwardPropOption,\n label\n }, options));\n const transformStyleArg = stylesArg => {\n // On the server Emotion doesn't use React.forwardRef for creating components, so the created\n // component stays as a function. This condition makes sure that we do not interpolate functions\n // which are basically components used as a selectors.\n if (typeof stylesArg === 'function' && stylesArg.__emotion_real !== stylesArg || isPlainObject(stylesArg)) {\n return props => processStyleArg(stylesArg, _extends({}, props, {\n theme: resolveTheme({\n theme: props.theme,\n defaultTheme,\n themeId\n })\n }));\n }\n return stylesArg;\n };\n const muiStyledResolver = (styleArg, ...expressions) => {\n let transformedStyleArg = transformStyleArg(styleArg);\n const expressionsWithDefaultTheme = expressions ? expressions.map(transformStyleArg) : [];\n if (componentName && overridesResolver) {\n expressionsWithDefaultTheme.push(props => {\n const theme = resolveTheme(_extends({}, props, {\n defaultTheme,\n themeId\n }));\n if (!theme.components || !theme.components[componentName] || !theme.components[componentName].styleOverrides) {\n return null;\n }\n const styleOverrides = theme.components[componentName].styleOverrides;\n const resolvedStyleOverrides = {};\n // TODO: v7 remove iteration and use `resolveStyleArg(styleOverrides[slot])` directly\n Object.entries(styleOverrides).forEach(([slotKey, slotStyle]) => {\n resolvedStyleOverrides[slotKey] = processStyleArg(slotStyle, _extends({}, props, {\n theme\n }));\n });\n return overridesResolver(props, resolvedStyleOverrides);\n });\n }\n if (componentName && !skipVariantsResolver) {\n expressionsWithDefaultTheme.push(props => {\n var _theme$components;\n const theme = resolveTheme(_extends({}, props, {\n defaultTheme,\n themeId\n }));\n const themeVariants = theme == null || (_theme$components = theme.components) == null || (_theme$components = _theme$components[componentName]) == null ? void 0 : _theme$components.variants;\n return processStyleArg({\n variants: themeVariants\n }, _extends({}, props, {\n theme\n }));\n });\n }\n if (!skipSx) {\n expressionsWithDefaultTheme.push(systemSx);\n }\n const numOfCustomFnsApplied = expressionsWithDefaultTheme.length - expressions.length;\n if (Array.isArray(styleArg) && numOfCustomFnsApplied > 0) {\n const placeholders = new Array(numOfCustomFnsApplied).fill('');\n // If the type is array, than we need to add placeholders in the template for the overrides, variants and the sx styles.\n transformedStyleArg = [...styleArg, ...placeholders];\n transformedStyleArg.raw = [...styleArg.raw, ...placeholders];\n }\n const Component = defaultStyledResolver(transformedStyleArg, ...expressionsWithDefaultTheme);\n if (process.env.NODE_ENV !== 'production') {\n let displayName;\n if (componentName) {\n displayName = `${componentName}${capitalize(componentSlot || '')}`;\n }\n if (displayName === undefined) {\n displayName = `Styled(${getDisplayName(tag)})`;\n }\n Component.displayName = displayName;\n }\n if (tag.muiName) {\n Component.muiName = tag.muiName;\n }\n return Component;\n };\n if (defaultStyledResolver.withConfig) {\n muiStyledResolver.withConfig = defaultStyledResolver.withConfig;\n }\n return muiStyledResolver;\n };\n}","import resolveProps from '@mui/utils/resolveProps';\nexport default function getThemeProps(params) {\n const {\n theme,\n name,\n props\n } = params;\n if (!theme || !theme.components || !theme.components[name] || !theme.components[name].defaultProps) {\n return props;\n }\n return resolveProps(theme.components[name].defaultProps, props);\n}","'use client';\n\nimport getThemeProps from './getThemeProps';\nimport useTheme from '../useTheme';\nexport default function useThemeProps({\n props,\n name,\n defaultTheme,\n themeId\n}) {\n let theme = useTheme(defaultTheme);\n if (themeId) {\n theme = theme[themeId] || theme;\n }\n const mergedProps = getThemeProps({\n theme,\n name,\n props\n });\n return mergedProps;\n}","import _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\n/* eslint-disable @typescript-eslint/naming-convention */\nimport clamp from '@mui/utils/clamp';\n/**\n * Returns a number whose value is limited to the given range.\n * @param {number} value The value to be clamped\n * @param {number} min The lower boundary of the output range\n * @param {number} max The upper boundary of the output range\n * @returns {number} A number in the range [min, max]\n */\nfunction clampWrapper(value, min = 0, max = 1) {\n if (process.env.NODE_ENV !== 'production') {\n if (value < min || value > max) {\n console.error(`MUI: The value provided ${value} is out of range [${min}, ${max}].`);\n }\n }\n return clamp(value, min, max);\n}\n\n/**\n * Converts a color from CSS hex format to CSS rgb format.\n * @param {string} color - Hex color, i.e. #nnn or #nnnnnn\n * @returns {string} A CSS rgb color string\n */\nexport function hexToRgb(color) {\n color = color.slice(1);\n const re = new RegExp(`.{1,${color.length >= 6 ? 2 : 1}}`, 'g');\n let colors = color.match(re);\n if (colors && colors[0].length === 1) {\n colors = colors.map(n => n + n);\n }\n return colors ? `rgb${colors.length === 4 ? 'a' : ''}(${colors.map((n, index) => {\n return index < 3 ? parseInt(n, 16) : Math.round(parseInt(n, 16) / 255 * 1000) / 1000;\n }).join(', ')})` : '';\n}\nfunction intToHex(int) {\n const hex = int.toString(16);\n return hex.length === 1 ? `0${hex}` : hex;\n}\n\n/**\n * Returns an object with the type and values of a color.\n *\n * Note: Does not support rgb % values.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @returns {object} - A MUI color object: {type: string, values: number[]}\n */\nexport function decomposeColor(color) {\n // Idempotent\n if (color.type) {\n return color;\n }\n if (color.charAt(0) === '#') {\n return decomposeColor(hexToRgb(color));\n }\n const marker = color.indexOf('(');\n const type = color.substring(0, marker);\n if (['rgb', 'rgba', 'hsl', 'hsla', 'color'].indexOf(type) === -1) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: Unsupported \\`${color}\\` color.\nThe following formats are supported: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color().` : _formatMuiErrorMessage(9, color));\n }\n let values = color.substring(marker + 1, color.length - 1);\n let colorSpace;\n if (type === 'color') {\n values = values.split(' ');\n colorSpace = values.shift();\n if (values.length === 4 && values[3].charAt(0) === '/') {\n values[3] = values[3].slice(1);\n }\n if (['srgb', 'display-p3', 'a98-rgb', 'prophoto-rgb', 'rec-2020'].indexOf(colorSpace) === -1) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: unsupported \\`${colorSpace}\\` color space.\nThe following color spaces are supported: srgb, display-p3, a98-rgb, prophoto-rgb, rec-2020.` : _formatMuiErrorMessage(10, colorSpace));\n }\n } else {\n values = values.split(',');\n }\n values = values.map(value => parseFloat(value));\n return {\n type,\n values,\n colorSpace\n };\n}\n\n/**\n * Returns a channel created from the input color.\n *\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @returns {string} - The channel for the color, that can be used in rgba or hsla colors\n */\nexport const colorChannel = color => {\n const decomposedColor = decomposeColor(color);\n return decomposedColor.values.slice(0, 3).map((val, idx) => decomposedColor.type.indexOf('hsl') !== -1 && idx !== 0 ? `${val}%` : val).join(' ');\n};\nexport const private_safeColorChannel = (color, warning) => {\n try {\n return colorChannel(color);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n};\n\n/**\n * Converts a color object with type and values to a string.\n * @param {object} color - Decomposed color\n * @param {string} color.type - One of: 'rgb', 'rgba', 'hsl', 'hsla', 'color'\n * @param {array} color.values - [n,n,n] or [n,n,n,n]\n * @returns {string} A CSS color string\n */\nexport function recomposeColor(color) {\n const {\n type,\n colorSpace\n } = color;\n let {\n values\n } = color;\n if (type.indexOf('rgb') !== -1) {\n // Only convert the first 3 values to int (i.e. not alpha)\n values = values.map((n, i) => i < 3 ? parseInt(n, 10) : n);\n } else if (type.indexOf('hsl') !== -1) {\n values[1] = `${values[1]}%`;\n values[2] = `${values[2]}%`;\n }\n if (type.indexOf('color') !== -1) {\n values = `${colorSpace} ${values.join(' ')}`;\n } else {\n values = `${values.join(', ')}`;\n }\n return `${type}(${values})`;\n}\n\n/**\n * Converts a color from CSS rgb format to CSS hex format.\n * @param {string} color - RGB color, i.e. rgb(n, n, n)\n * @returns {string} A CSS rgb color string, i.e. #nnnnnn\n */\nexport function rgbToHex(color) {\n // Idempotent\n if (color.indexOf('#') === 0) {\n return color;\n }\n const {\n values\n } = decomposeColor(color);\n return `#${values.map((n, i) => intToHex(i === 3 ? Math.round(255 * n) : n)).join('')}`;\n}\n\n/**\n * Converts a color from hsl format to rgb format.\n * @param {string} color - HSL color values\n * @returns {string} rgb color values\n */\nexport function hslToRgb(color) {\n color = decomposeColor(color);\n const {\n values\n } = color;\n const h = values[0];\n const s = values[1] / 100;\n const l = values[2] / 100;\n const a = s * Math.min(l, 1 - l);\n const f = (n, k = (n + h / 30) % 12) => l - a * Math.max(Math.min(k - 3, 9 - k, 1), -1);\n let type = 'rgb';\n const rgb = [Math.round(f(0) * 255), Math.round(f(8) * 255), Math.round(f(4) * 255)];\n if (color.type === 'hsla') {\n type += 'a';\n rgb.push(values[3]);\n }\n return recomposeColor({\n type,\n values: rgb\n });\n}\n/**\n * The relative brightness of any point in a color space,\n * normalized to 0 for darkest black and 1 for lightest white.\n *\n * Formula: https://www.w3.org/TR/WCAG20-TECHS/G17.html#G17-tests\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @returns {number} The relative brightness of the color in the range 0 - 1\n */\nexport function getLuminance(color) {\n color = decomposeColor(color);\n let rgb = color.type === 'hsl' || color.type === 'hsla' ? decomposeColor(hslToRgb(color)).values : color.values;\n rgb = rgb.map(val => {\n if (color.type !== 'color') {\n val /= 255; // normalized\n }\n return val <= 0.03928 ? val / 12.92 : ((val + 0.055) / 1.055) ** 2.4;\n });\n\n // Truncate at 3 digits\n return Number((0.2126 * rgb[0] + 0.7152 * rgb[1] + 0.0722 * rgb[2]).toFixed(3));\n}\n\n/**\n * Calculates the contrast ratio between two colors.\n *\n * Formula: https://www.w3.org/TR/WCAG20-TECHS/G17.html#G17-tests\n * @param {string} foreground - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla()\n * @param {string} background - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla()\n * @returns {number} A contrast ratio value in the range 0 - 21.\n */\nexport function getContrastRatio(foreground, background) {\n const lumA = getLuminance(foreground);\n const lumB = getLuminance(background);\n return (Math.max(lumA, lumB) + 0.05) / (Math.min(lumA, lumB) + 0.05);\n}\n\n/**\n * Sets the absolute transparency of a color.\n * Any existing alpha values are overwritten.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} value - value to set the alpha channel to in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function alpha(color, value) {\n color = decomposeColor(color);\n value = clampWrapper(value);\n if (color.type === 'rgb' || color.type === 'hsl') {\n color.type += 'a';\n }\n if (color.type === 'color') {\n color.values[3] = `/${value}`;\n } else {\n color.values[3] = value;\n }\n return recomposeColor(color);\n}\nexport function private_safeAlpha(color, value, warning) {\n try {\n return alpha(color, value);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Darkens a color.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} coefficient - multiplier in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function darken(color, coefficient) {\n color = decomposeColor(color);\n coefficient = clampWrapper(coefficient);\n if (color.type.indexOf('hsl') !== -1) {\n color.values[2] *= 1 - coefficient;\n } else if (color.type.indexOf('rgb') !== -1 || color.type.indexOf('color') !== -1) {\n for (let i = 0; i < 3; i += 1) {\n color.values[i] *= 1 - coefficient;\n }\n }\n return recomposeColor(color);\n}\nexport function private_safeDarken(color, coefficient, warning) {\n try {\n return darken(color, coefficient);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Lightens a color.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} coefficient - multiplier in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function lighten(color, coefficient) {\n color = decomposeColor(color);\n coefficient = clampWrapper(coefficient);\n if (color.type.indexOf('hsl') !== -1) {\n color.values[2] += (100 - color.values[2]) * coefficient;\n } else if (color.type.indexOf('rgb') !== -1) {\n for (let i = 0; i < 3; i += 1) {\n color.values[i] += (255 - color.values[i]) * coefficient;\n }\n } else if (color.type.indexOf('color') !== -1) {\n for (let i = 0; i < 3; i += 1) {\n color.values[i] += (1 - color.values[i]) * coefficient;\n }\n }\n return recomposeColor(color);\n}\nexport function private_safeLighten(color, coefficient, warning) {\n try {\n return lighten(color, coefficient);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Darken or lighten a color, depending on its luminance.\n * Light colors are darkened, dark colors are lightened.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} coefficient=0.15 - multiplier in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function emphasize(color, coefficient = 0.15) {\n return getLuminance(color) > 0.5 ? darken(color, coefficient) : lighten(color, coefficient);\n}\nexport function private_safeEmphasize(color, coefficient, warning) {\n try {\n return emphasize(color, coefficient);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Blend a transparent overlay color with a background color, resulting in a single\n * RGB color.\n * @param {string} background - CSS color\n * @param {string} overlay - CSS color\n * @param {number} opacity - Opacity multiplier in the range 0 - 1\n * @param {number} [gamma=1.0] - Gamma correction factor. For gamma-correct blending, 2.2 is usual.\n */\nexport function blend(background, overlay, opacity, gamma = 1.0) {\n const blendChannel = (b, o) => Math.round((b ** (1 / gamma) * (1 - opacity) + o ** (1 / gamma) * opacity) ** gamma);\n const backgroundColor = decomposeColor(background);\n const overlayColor = decomposeColor(overlay);\n const rgb = [blendChannel(backgroundColor.values[0], overlayColor.values[0]), blendChannel(backgroundColor.values[1], overlayColor.values[1]), blendChannel(backgroundColor.values[2], overlayColor.values[2])];\n return recomposeColor({\n type: 'rgb',\n values: rgb\n });\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nexport default function createMixins(breakpoints, mixins) {\n return _extends({\n toolbar: {\n minHeight: 56,\n [breakpoints.up('xs')]: {\n '@media (orientation: landscape)': {\n minHeight: 48\n }\n },\n [breakpoints.up('sm')]: {\n minHeight: 64\n }\n }\n }, mixins);\n}","const common = {\n black: '#000',\n white: '#fff'\n};\nexport default common;","const grey = {\n 50: '#fafafa',\n 100: '#f5f5f5',\n 200: '#eeeeee',\n 300: '#e0e0e0',\n 400: '#bdbdbd',\n 500: '#9e9e9e',\n 600: '#757575',\n 700: '#616161',\n 800: '#424242',\n 900: '#212121',\n A100: '#f5f5f5',\n A200: '#eeeeee',\n A400: '#bdbdbd',\n A700: '#616161'\n};\nexport default grey;","const purple = {\n 50: '#f3e5f5',\n 100: '#e1bee7',\n 200: '#ce93d8',\n 300: '#ba68c8',\n 400: '#ab47bc',\n 500: '#9c27b0',\n 600: '#8e24aa',\n 700: '#7b1fa2',\n 800: '#6a1b9a',\n 900: '#4a148c',\n A100: '#ea80fc',\n A200: '#e040fb',\n A400: '#d500f9',\n A700: '#aa00ff'\n};\nexport default purple;","const red = {\n 50: '#ffebee',\n 100: '#ffcdd2',\n 200: '#ef9a9a',\n 300: '#e57373',\n 400: '#ef5350',\n 500: '#f44336',\n 600: '#e53935',\n 700: '#d32f2f',\n 800: '#c62828',\n 900: '#b71c1c',\n A100: '#ff8a80',\n A200: '#ff5252',\n A400: '#ff1744',\n A700: '#d50000'\n};\nexport default red;","const orange = {\n 50: '#fff3e0',\n 100: '#ffe0b2',\n 200: '#ffcc80',\n 300: '#ffb74d',\n 400: '#ffa726',\n 500: '#ff9800',\n 600: '#fb8c00',\n 700: '#f57c00',\n 800: '#ef6c00',\n 900: '#e65100',\n A100: '#ffd180',\n A200: '#ffab40',\n A400: '#ff9100',\n A700: '#ff6d00'\n};\nexport default orange;","const blue = {\n 50: '#e3f2fd',\n 100: '#bbdefb',\n 200: '#90caf9',\n 300: '#64b5f6',\n 400: '#42a5f5',\n 500: '#2196f3',\n 600: '#1e88e5',\n 700: '#1976d2',\n 800: '#1565c0',\n 900: '#0d47a1',\n A100: '#82b1ff',\n A200: '#448aff',\n A400: '#2979ff',\n A700: '#2962ff'\n};\nexport default blue;","const lightBlue = {\n 50: '#e1f5fe',\n 100: '#b3e5fc',\n 200: '#81d4fa',\n 300: '#4fc3f7',\n 400: '#29b6f6',\n 500: '#03a9f4',\n 600: '#039be5',\n 700: '#0288d1',\n 800: '#0277bd',\n 900: '#01579b',\n A100: '#80d8ff',\n A200: '#40c4ff',\n A400: '#00b0ff',\n A700: '#0091ea'\n};\nexport default lightBlue;","const green = {\n 50: '#e8f5e9',\n 100: '#c8e6c9',\n 200: '#a5d6a7',\n 300: '#81c784',\n 400: '#66bb6a',\n 500: '#4caf50',\n 600: '#43a047',\n 700: '#388e3c',\n 800: '#2e7d32',\n 900: '#1b5e20',\n A100: '#b9f6ca',\n A200: '#69f0ae',\n A400: '#00e676',\n A700: '#00c853'\n};\nexport default green;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\nconst _excluded = [\"mode\", \"contrastThreshold\", \"tonalOffset\"];\nimport { deepmerge } from '@mui/utils';\nimport { darken, getContrastRatio, lighten } from '@mui/system';\nimport common from '../colors/common';\nimport grey from '../colors/grey';\nimport purple from '../colors/purple';\nimport red from '../colors/red';\nimport orange from '../colors/orange';\nimport blue from '../colors/blue';\nimport lightBlue from '../colors/lightBlue';\nimport green from '../colors/green';\nexport const light = {\n // The colors used to style the text.\n text: {\n // The most important text.\n primary: 'rgba(0, 0, 0, 0.87)',\n // Secondary text.\n secondary: 'rgba(0, 0, 0, 0.6)',\n // Disabled text have even lower visual prominence.\n disabled: 'rgba(0, 0, 0, 0.38)'\n },\n // The color used to divide different elements.\n divider: 'rgba(0, 0, 0, 0.12)',\n // The background colors used to style the surfaces.\n // Consistency between these values is important.\n background: {\n paper: common.white,\n default: common.white\n },\n // The colors used to style the action elements.\n action: {\n // The color of an active action like an icon button.\n active: 'rgba(0, 0, 0, 0.54)',\n // The color of an hovered action.\n hover: 'rgba(0, 0, 0, 0.04)',\n hoverOpacity: 0.04,\n // The color of a selected action.\n selected: 'rgba(0, 0, 0, 0.08)',\n selectedOpacity: 0.08,\n // The color of a disabled action.\n disabled: 'rgba(0, 0, 0, 0.26)',\n // The background color of a disabled action.\n disabledBackground: 'rgba(0, 0, 0, 0.12)',\n disabledOpacity: 0.38,\n focus: 'rgba(0, 0, 0, 0.12)',\n focusOpacity: 0.12,\n activatedOpacity: 0.12\n }\n};\nexport const dark = {\n text: {\n primary: common.white,\n secondary: 'rgba(255, 255, 255, 0.7)',\n disabled: 'rgba(255, 255, 255, 0.5)',\n icon: 'rgba(255, 255, 255, 0.5)'\n },\n divider: 'rgba(255, 255, 255, 0.12)',\n background: {\n paper: '#121212',\n default: '#121212'\n },\n action: {\n active: common.white,\n hover: 'rgba(255, 255, 255, 0.08)',\n hoverOpacity: 0.08,\n selected: 'rgba(255, 255, 255, 0.16)',\n selectedOpacity: 0.16,\n disabled: 'rgba(255, 255, 255, 0.3)',\n disabledBackground: 'rgba(255, 255, 255, 0.12)',\n disabledOpacity: 0.38,\n focus: 'rgba(255, 255, 255, 0.12)',\n focusOpacity: 0.12,\n activatedOpacity: 0.24\n }\n};\nfunction addLightOrDark(intent, direction, shade, tonalOffset) {\n const tonalOffsetLight = tonalOffset.light || tonalOffset;\n const tonalOffsetDark = tonalOffset.dark || tonalOffset * 1.5;\n if (!intent[direction]) {\n if (intent.hasOwnProperty(shade)) {\n intent[direction] = intent[shade];\n } else if (direction === 'light') {\n intent.light = lighten(intent.main, tonalOffsetLight);\n } else if (direction === 'dark') {\n intent.dark = darken(intent.main, tonalOffsetDark);\n }\n }\n}\nfunction getDefaultPrimary(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: blue[200],\n light: blue[50],\n dark: blue[400]\n };\n }\n return {\n main: blue[700],\n light: blue[400],\n dark: blue[800]\n };\n}\nfunction getDefaultSecondary(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: purple[200],\n light: purple[50],\n dark: purple[400]\n };\n }\n return {\n main: purple[500],\n light: purple[300],\n dark: purple[700]\n };\n}\nfunction getDefaultError(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: red[500],\n light: red[300],\n dark: red[700]\n };\n }\n return {\n main: red[700],\n light: red[400],\n dark: red[800]\n };\n}\nfunction getDefaultInfo(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: lightBlue[400],\n light: lightBlue[300],\n dark: lightBlue[700]\n };\n }\n return {\n main: lightBlue[700],\n light: lightBlue[500],\n dark: lightBlue[900]\n };\n}\nfunction getDefaultSuccess(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: green[400],\n light: green[300],\n dark: green[700]\n };\n }\n return {\n main: green[800],\n light: green[500],\n dark: green[900]\n };\n}\nfunction getDefaultWarning(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: orange[400],\n light: orange[300],\n dark: orange[700]\n };\n }\n return {\n main: '#ed6c02',\n // closest to orange[800] that pass 3:1.\n light: orange[500],\n dark: orange[900]\n };\n}\nexport default function createPalette(palette) {\n const {\n mode = 'light',\n contrastThreshold = 3,\n tonalOffset = 0.2\n } = palette,\n other = _objectWithoutPropertiesLoose(palette, _excluded);\n const primary = palette.primary || getDefaultPrimary(mode);\n const secondary = palette.secondary || getDefaultSecondary(mode);\n const error = palette.error || getDefaultError(mode);\n const info = palette.info || getDefaultInfo(mode);\n const success = palette.success || getDefaultSuccess(mode);\n const warning = palette.warning || getDefaultWarning(mode);\n\n // Use the same logic as\n // Bootstrap: https://github.com/twbs/bootstrap/blob/1d6e3710dd447de1a200f29e8fa521f8a0908f70/scss/_functions.scss#L59\n // and material-components-web https://github.com/material-components/material-components-web/blob/ac46b8863c4dab9fc22c4c662dc6bd1b65dd652f/packages/mdc-theme/_functions.scss#L54\n function getContrastText(background) {\n const contrastText = getContrastRatio(background, dark.text.primary) >= contrastThreshold ? dark.text.primary : light.text.primary;\n if (process.env.NODE_ENV !== 'production') {\n const contrast = getContrastRatio(background, contrastText);\n if (contrast < 3) {\n console.error([`MUI: The contrast ratio of ${contrast}:1 for ${contrastText} on ${background}`, 'falls below the WCAG recommended absolute minimum contrast ratio of 3:1.', 'https://www.w3.org/TR/2008/REC-WCAG20-20081211/#visual-audio-contrast-contrast'].join('\\n'));\n }\n }\n return contrastText;\n }\n const augmentColor = ({\n color,\n name,\n mainShade = 500,\n lightShade = 300,\n darkShade = 700\n }) => {\n color = _extends({}, color);\n if (!color.main && color[mainShade]) {\n color.main = color[mainShade];\n }\n if (!color.hasOwnProperty('main')) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: The color${name ? ` (${name})` : ''} provided to augmentColor(color) is invalid.\nThe color object needs to have a \\`main\\` property or a \\`${mainShade}\\` property.` : _formatMuiErrorMessage(11, name ? ` (${name})` : '', mainShade));\n }\n if (typeof color.main !== 'string') {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: The color${name ? ` (${name})` : ''} provided to augmentColor(color) is invalid.\n\\`color.main\\` should be a string, but \\`${JSON.stringify(color.main)}\\` was provided instead.\n\nDid you intend to use one of the following approaches?\n\nimport { green } from \"@mui/material/colors\";\n\nconst theme1 = createTheme({ palette: {\n primary: green,\n} });\n\nconst theme2 = createTheme({ palette: {\n primary: { main: green[500] },\n} });` : _formatMuiErrorMessage(12, name ? ` (${name})` : '', JSON.stringify(color.main)));\n }\n addLightOrDark(color, 'light', lightShade, tonalOffset);\n addLightOrDark(color, 'dark', darkShade, tonalOffset);\n if (!color.contrastText) {\n color.contrastText = getContrastText(color.main);\n }\n return color;\n };\n const modes = {\n dark,\n light\n };\n if (process.env.NODE_ENV !== 'production') {\n if (!modes[mode]) {\n console.error(`MUI: The palette mode \\`${mode}\\` is not supported.`);\n }\n }\n const paletteOutput = deepmerge(_extends({\n // A collection of common colors.\n common: _extends({}, common),\n // prevent mutable object.\n // The palette mode, can be light or dark.\n mode,\n // The colors used to represent primary interface elements for a user.\n primary: augmentColor({\n color: primary,\n name: 'primary'\n }),\n // The colors used to represent secondary interface elements for a user.\n secondary: augmentColor({\n color: secondary,\n name: 'secondary',\n mainShade: 'A400',\n lightShade: 'A200',\n darkShade: 'A700'\n }),\n // The colors used to represent interface elements that the user should be made aware of.\n error: augmentColor({\n color: error,\n name: 'error'\n }),\n // The colors used to represent potentially dangerous actions or important messages.\n warning: augmentColor({\n color: warning,\n name: 'warning'\n }),\n // The colors used to present information to the user that is neutral and not necessarily important.\n info: augmentColor({\n color: info,\n name: 'info'\n }),\n // The colors used to indicate the successful completion of an action that user triggered.\n success: augmentColor({\n color: success,\n name: 'success'\n }),\n // The grey colors.\n grey,\n // Used by `getContrastText()` to maximize the contrast between\n // the background and the text.\n contrastThreshold,\n // Takes a background color and returns the text color that maximizes the contrast.\n getContrastText,\n // Generate a rich color object.\n augmentColor,\n // Used by the functions below to shift a color's luminance by approximately\n // two indexes within its tonal palette.\n // E.g., shift from Red 500 to Red 300 or Red 700.\n tonalOffset\n }, modes[mode]), other);\n return paletteOutput;\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"fontFamily\", \"fontSize\", \"fontWeightLight\", \"fontWeightRegular\", \"fontWeightMedium\", \"fontWeightBold\", \"htmlFontSize\", \"allVariants\", \"pxToRem\"];\nimport { deepmerge } from '@mui/utils';\nfunction round(value) {\n return Math.round(value * 1e5) / 1e5;\n}\nconst caseAllCaps = {\n textTransform: 'uppercase'\n};\nconst defaultFontFamily = '\"Roboto\", \"Helvetica\", \"Arial\", sans-serif';\n\n/**\n * @see @link{https://m2.material.io/design/typography/the-type-system.html}\n * @see @link{https://m2.material.io/design/typography/understanding-typography.html}\n */\nexport default function createTypography(palette, typography) {\n const _ref = typeof typography === 'function' ? typography(palette) : typography,\n {\n fontFamily = defaultFontFamily,\n // The default font size of the Material Specification.\n fontSize = 14,\n // px\n fontWeightLight = 300,\n fontWeightRegular = 400,\n fontWeightMedium = 500,\n fontWeightBold = 700,\n // Tell MUI what's the font-size on the html element.\n // 16px is the default font-size used by browsers.\n htmlFontSize = 16,\n // Apply the CSS properties to all the variants.\n allVariants,\n pxToRem: pxToRem2\n } = _ref,\n other = _objectWithoutPropertiesLoose(_ref, _excluded);\n if (process.env.NODE_ENV !== 'production') {\n if (typeof fontSize !== 'number') {\n console.error('MUI: `fontSize` is required to be a number.');\n }\n if (typeof htmlFontSize !== 'number') {\n console.error('MUI: `htmlFontSize` is required to be a number.');\n }\n }\n const coef = fontSize / 14;\n const pxToRem = pxToRem2 || (size => `${size / htmlFontSize * coef}rem`);\n const buildVariant = (fontWeight, size, lineHeight, letterSpacing, casing) => _extends({\n fontFamily,\n fontWeight,\n fontSize: pxToRem(size),\n // Unitless following https://meyerweb.com/eric/thoughts/2006/02/08/unitless-line-heights/\n lineHeight\n }, fontFamily === defaultFontFamily ? {\n letterSpacing: `${round(letterSpacing / size)}em`\n } : {}, casing, allVariants);\n const variants = {\n h1: buildVariant(fontWeightLight, 96, 1.167, -1.5),\n h2: buildVariant(fontWeightLight, 60, 1.2, -0.5),\n h3: buildVariant(fontWeightRegular, 48, 1.167, 0),\n h4: buildVariant(fontWeightRegular, 34, 1.235, 0.25),\n h5: buildVariant(fontWeightRegular, 24, 1.334, 0),\n h6: buildVariant(fontWeightMedium, 20, 1.6, 0.15),\n subtitle1: buildVariant(fontWeightRegular, 16, 1.75, 0.15),\n subtitle2: buildVariant(fontWeightMedium, 14, 1.57, 0.1),\n body1: buildVariant(fontWeightRegular, 16, 1.5, 0.15),\n body2: buildVariant(fontWeightRegular, 14, 1.43, 0.15),\n button: buildVariant(fontWeightMedium, 14, 1.75, 0.4, caseAllCaps),\n caption: buildVariant(fontWeightRegular, 12, 1.66, 0.4),\n overline: buildVariant(fontWeightRegular, 12, 2.66, 1, caseAllCaps),\n // TODO v6: Remove handling of 'inherit' variant from the theme as it is already handled in Material UI's Typography component. Also, remember to remove the associated types.\n inherit: {\n fontFamily: 'inherit',\n fontWeight: 'inherit',\n fontSize: 'inherit',\n lineHeight: 'inherit',\n letterSpacing: 'inherit'\n }\n };\n return deepmerge(_extends({\n htmlFontSize,\n pxToRem,\n fontFamily,\n fontSize,\n fontWeightLight,\n fontWeightRegular,\n fontWeightMedium,\n fontWeightBold\n }, variants), other, {\n clone: false // No need to clone deep\n });\n}","const shadowKeyUmbraOpacity = 0.2;\nconst shadowKeyPenumbraOpacity = 0.14;\nconst shadowAmbientShadowOpacity = 0.12;\nfunction createShadow(...px) {\n return [`${px[0]}px ${px[1]}px ${px[2]}px ${px[3]}px rgba(0,0,0,${shadowKeyUmbraOpacity})`, `${px[4]}px ${px[5]}px ${px[6]}px ${px[7]}px rgba(0,0,0,${shadowKeyPenumbraOpacity})`, `${px[8]}px ${px[9]}px ${px[10]}px ${px[11]}px rgba(0,0,0,${shadowAmbientShadowOpacity})`].join(',');\n}\n\n// Values from https://github.com/material-components/material-components-web/blob/be8747f94574669cb5e7add1a7c54fa41a89cec7/packages/mdc-elevation/_variables.scss\nconst shadows = ['none', createShadow(0, 2, 1, -1, 0, 1, 1, 0, 0, 1, 3, 0), createShadow(0, 3, 1, -2, 0, 2, 2, 0, 0, 1, 5, 0), createShadow(0, 3, 3, -2, 0, 3, 4, 0, 0, 1, 8, 0), createShadow(0, 2, 4, -1, 0, 4, 5, 0, 0, 1, 10, 0), createShadow(0, 3, 5, -1, 0, 5, 8, 0, 0, 1, 14, 0), createShadow(0, 3, 5, -1, 0, 6, 10, 0, 0, 1, 18, 0), createShadow(0, 4, 5, -2, 0, 7, 10, 1, 0, 2, 16, 1), createShadow(0, 5, 5, -3, 0, 8, 10, 1, 0, 3, 14, 2), createShadow(0, 5, 6, -3, 0, 9, 12, 1, 0, 3, 16, 2), createShadow(0, 6, 6, -3, 0, 10, 14, 1, 0, 4, 18, 3), createShadow(0, 6, 7, -4, 0, 11, 15, 1, 0, 4, 20, 3), createShadow(0, 7, 8, -4, 0, 12, 17, 2, 0, 5, 22, 4), createShadow(0, 7, 8, -4, 0, 13, 19, 2, 0, 5, 24, 4), createShadow(0, 7, 9, -4, 0, 14, 21, 2, 0, 5, 26, 4), createShadow(0, 8, 9, -5, 0, 15, 22, 2, 0, 6, 28, 5), createShadow(0, 8, 10, -5, 0, 16, 24, 2, 0, 6, 30, 5), createShadow(0, 8, 11, -5, 0, 17, 26, 2, 0, 6, 32, 5), createShadow(0, 9, 11, -5, 0, 18, 28, 2, 0, 7, 34, 6), createShadow(0, 9, 12, -6, 0, 19, 29, 2, 0, 7, 36, 6), createShadow(0, 10, 13, -6, 0, 20, 31, 3, 0, 8, 38, 7), createShadow(0, 10, 13, -6, 0, 21, 33, 3, 0, 8, 40, 7), createShadow(0, 10, 14, -6, 0, 22, 35, 3, 0, 8, 42, 7), createShadow(0, 11, 14, -7, 0, 23, 36, 3, 0, 9, 44, 8), createShadow(0, 11, 15, -7, 0, 24, 38, 3, 0, 9, 46, 8)];\nexport default shadows;","import _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nconst _excluded = [\"duration\", \"easing\", \"delay\"];\n// Follow https://material.google.com/motion/duration-easing.html#duration-easing-natural-easing-curves\n// to learn the context in which each easing should be used.\nexport const easing = {\n // This is the most common easing curve.\n easeInOut: 'cubic-bezier(0.4, 0, 0.2, 1)',\n // Objects enter the screen at full velocity from off-screen and\n // slowly decelerate to a resting point.\n easeOut: 'cubic-bezier(0.0, 0, 0.2, 1)',\n // Objects leave the screen at full velocity. They do not decelerate when off-screen.\n easeIn: 'cubic-bezier(0.4, 0, 1, 1)',\n // The sharp curve is used by objects that may return to the screen at any time.\n sharp: 'cubic-bezier(0.4, 0, 0.6, 1)'\n};\n\n// Follow https://m2.material.io/guidelines/motion/duration-easing.html#duration-easing-common-durations\n// to learn when use what timing\nexport const duration = {\n shortest: 150,\n shorter: 200,\n short: 250,\n // most basic recommended timing\n standard: 300,\n // this is to be used in complex animations\n complex: 375,\n // recommended when something is entering screen\n enteringScreen: 225,\n // recommended when something is leaving screen\n leavingScreen: 195\n};\nfunction formatMs(milliseconds) {\n return `${Math.round(milliseconds)}ms`;\n}\nfunction getAutoHeightDuration(height) {\n if (!height) {\n return 0;\n }\n const constant = height / 36;\n\n // https://www.wolframalpha.com/input/?i=(4+%2B+15+*+(x+%2F+36+)+**+0.25+%2B+(x+%2F+36)+%2F+5)+*+10\n return Math.round((4 + 15 * constant ** 0.25 + constant / 5) * 10);\n}\nexport default function createTransitions(inputTransitions) {\n const mergedEasing = _extends({}, easing, inputTransitions.easing);\n const mergedDuration = _extends({}, duration, inputTransitions.duration);\n const create = (props = ['all'], options = {}) => {\n const {\n duration: durationOption = mergedDuration.standard,\n easing: easingOption = mergedEasing.easeInOut,\n delay = 0\n } = options,\n other = _objectWithoutPropertiesLoose(options, _excluded);\n if (process.env.NODE_ENV !== 'production') {\n const isString = value => typeof value === 'string';\n // IE11 support, replace with Number.isNaN\n // eslint-disable-next-line no-restricted-globals\n const isNumber = value => !isNaN(parseFloat(value));\n if (!isString(props) && !Array.isArray(props)) {\n console.error('MUI: Argument \"props\" must be a string or Array.');\n }\n if (!isNumber(durationOption) && !isString(durationOption)) {\n console.error(`MUI: Argument \"duration\" must be a number or a string but found ${durationOption}.`);\n }\n if (!isString(easingOption)) {\n console.error('MUI: Argument \"easing\" must be a string.');\n }\n if (!isNumber(delay) && !isString(delay)) {\n console.error('MUI: Argument \"delay\" must be a number or a string.');\n }\n if (typeof options !== 'object') {\n console.error(['MUI: Secong argument of transition.create must be an object.', \"Arguments should be either `create('prop1', options)` or `create(['prop1', 'prop2'], options)`\"].join('\\n'));\n }\n if (Object.keys(other).length !== 0) {\n console.error(`MUI: Unrecognized argument(s) [${Object.keys(other).join(',')}].`);\n }\n }\n return (Array.isArray(props) ? props : [props]).map(animatedProp => `${animatedProp} ${typeof durationOption === 'string' ? durationOption : formatMs(durationOption)} ${easingOption} ${typeof delay === 'string' ? delay : formatMs(delay)}`).join(',');\n };\n return _extends({\n getAutoHeightDuration,\n create\n }, inputTransitions, {\n easing: mergedEasing,\n duration: mergedDuration\n });\n}","// We need to centralize the zIndex definitions as they work\n// like global values in the browser.\nconst zIndex = {\n mobileStepper: 1000,\n fab: 1050,\n speedDial: 1050,\n appBar: 1100,\n drawer: 1200,\n modal: 1300,\n snackbar: 1400,\n tooltip: 1500\n};\nexport default zIndex;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\nconst _excluded = [\"breakpoints\", \"mixins\", \"spacing\", \"palette\", \"transitions\", \"typography\", \"shape\"];\nimport { deepmerge } from '@mui/utils';\nimport { createTheme as systemCreateTheme, unstable_defaultSxConfig as defaultSxConfig, unstable_styleFunctionSx as styleFunctionSx } from '@mui/system';\nimport generateUtilityClass from '@mui/utils/generateUtilityClass';\nimport createMixins from './createMixins';\nimport createPalette from './createPalette';\nimport createTypography from './createTypography';\nimport shadows from './shadows';\nimport createTransitions from './createTransitions';\nimport zIndex from './zIndex';\nfunction createTheme(options = {}, ...args) {\n const {\n mixins: mixinsInput = {},\n palette: paletteInput = {},\n transitions: transitionsInput = {},\n typography: typographyInput = {}\n } = options,\n other = _objectWithoutPropertiesLoose(options, _excluded);\n if (options.vars) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: \\`vars\\` is a private field used for CSS variables support.\nPlease use another name.` : _formatMuiErrorMessage(18));\n }\n const palette = createPalette(paletteInput);\n const systemTheme = systemCreateTheme(options);\n let muiTheme = deepmerge(systemTheme, {\n mixins: createMixins(systemTheme.breakpoints, mixinsInput),\n palette,\n // Don't use [...shadows] until you've verified its transpiled code is not invoking the iterator protocol.\n shadows: shadows.slice(),\n typography: createTypography(palette, typographyInput),\n transitions: createTransitions(transitionsInput),\n zIndex: _extends({}, zIndex)\n });\n muiTheme = deepmerge(muiTheme, other);\n muiTheme = args.reduce((acc, argument) => deepmerge(acc, argument), muiTheme);\n if (process.env.NODE_ENV !== 'production') {\n // TODO v6: Refactor to use globalStateClassesMapping from @mui/utils once `readOnly` state class is used in Rating component.\n const stateClasses = ['active', 'checked', 'completed', 'disabled', 'error', 'expanded', 'focused', 'focusVisible', 'required', 'selected'];\n const traverse = (node, component) => {\n let key;\n\n // eslint-disable-next-line guard-for-in, no-restricted-syntax\n for (key in node) {\n const child = node[key];\n if (stateClasses.indexOf(key) !== -1 && Object.keys(child).length > 0) {\n if (process.env.NODE_ENV !== 'production') {\n const stateClass = generateUtilityClass('', key);\n console.error([`MUI: The \\`${component}\\` component increases ` + `the CSS specificity of the \\`${key}\\` internal state.`, 'You can not override it like this: ', JSON.stringify(node, null, 2), '', `Instead, you need to use the '&.${stateClass}' syntax:`, JSON.stringify({\n root: {\n [`&.${stateClass}`]: child\n }\n }, null, 2), '', 'https://mui.com/r/state-classes-guide'].join('\\n'));\n }\n // Remove the style to prevent global conflicts.\n node[key] = {};\n }\n }\n };\n Object.keys(muiTheme.components).forEach(component => {\n const styleOverrides = muiTheme.components[component].styleOverrides;\n if (styleOverrides && component.indexOf('Mui') === 0) {\n traverse(styleOverrides, component);\n }\n });\n }\n muiTheme.unstable_sxConfig = _extends({}, defaultSxConfig, other == null ? void 0 : other.unstable_sxConfig);\n muiTheme.unstable_sx = function sx(props) {\n return styleFunctionSx({\n sx: props,\n theme: this\n });\n };\n return muiTheme;\n}\nlet warnedOnce = false;\nexport function createMuiTheme(...args) {\n if (process.env.NODE_ENV !== 'production') {\n if (!warnedOnce) {\n warnedOnce = true;\n console.error(['MUI: the createMuiTheme function was renamed to createTheme.', '', \"You should use `import { createTheme } from '@mui/material/styles'`\"].join('\\n'));\n }\n }\n return createTheme(...args);\n}\nexport default createTheme;","'use client';\n\nimport createTheme from './createTheme';\nconst defaultTheme = createTheme();\nexport default defaultTheme;","export default '$$material';","'use client';\n\nimport { useThemeProps as systemUseThemeProps } from '@mui/system';\nimport defaultTheme from './defaultTheme';\nimport THEME_ID from './identifier';\nexport default function useThemeProps({\n props,\n name\n}) {\n return systemUseThemeProps({\n props,\n name,\n defaultTheme,\n themeId: THEME_ID\n });\n}","'use client';\n\nimport { createStyled, shouldForwardProp } from '@mui/system';\nimport defaultTheme from './defaultTheme';\nimport THEME_ID from './identifier';\nexport const rootShouldForwardProp = prop => shouldForwardProp(prop) && prop !== 'classes';\nexport const slotShouldForwardProp = shouldForwardProp;\nconst styled = createStyled({\n themeId: THEME_ID,\n defaultTheme,\n rootShouldForwardProp\n});\nexport default styled;","import generateUtilityClasses from '@mui/utils/generateUtilityClasses';\nimport generateUtilityClass from '@mui/utils/generateUtilityClass';\nexport function getSvgIconUtilityClass(slot) {\n return generateUtilityClass('MuiSvgIcon', slot);\n}\nconst svgIconClasses = generateUtilityClasses('MuiSvgIcon', ['root', 'colorPrimary', 'colorSecondary', 'colorAction', 'colorError', 'colorDisabled', 'fontSizeInherit', 'fontSizeSmall', 'fontSizeMedium', 'fontSizeLarge']);\nexport default svgIconClasses;","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"children\", \"className\", \"color\", \"component\", \"fontSize\", \"htmlColor\", \"inheritViewBox\", \"titleAccess\", \"viewBox\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport clsx from 'clsx';\nimport { unstable_composeClasses as composeClasses } from '@mui/base/composeClasses';\nimport capitalize from '../utils/capitalize';\nimport useThemeProps from '../styles/useThemeProps';\nimport styled from '../styles/styled';\nimport { getSvgIconUtilityClass } from './svgIconClasses';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nimport { jsxs as _jsxs } from \"react/jsx-runtime\";\nconst useUtilityClasses = ownerState => {\n const {\n color,\n fontSize,\n classes\n } = ownerState;\n const slots = {\n root: ['root', color !== 'inherit' && `color${capitalize(color)}`, `fontSize${capitalize(fontSize)}`]\n };\n return composeClasses(slots, getSvgIconUtilityClass, classes);\n};\nconst SvgIconRoot = styled('svg', {\n name: 'MuiSvgIcon',\n slot: 'Root',\n overridesResolver: (props, styles) => {\n const {\n ownerState\n } = props;\n return [styles.root, ownerState.color !== 'inherit' && styles[`color${capitalize(ownerState.color)}`], styles[`fontSize${capitalize(ownerState.fontSize)}`]];\n }\n})(({\n theme,\n ownerState\n}) => {\n var _theme$transitions, _theme$transitions$cr, _theme$transitions2, _theme$typography, _theme$typography$pxT, _theme$typography2, _theme$typography2$px, _theme$typography3, _theme$typography3$px, _palette$ownerState$c, _palette, _palette2, _palette3;\n return {\n userSelect: 'none',\n width: '1em',\n height: '1em',\n display: 'inline-block',\n // the will define the property that has `currentColor`\n // e.g. heroicons uses fill=\"none\" and stroke=\"currentColor\"\n fill: ownerState.hasSvgAsChild ? undefined : 'currentColor',\n flexShrink: 0,\n transition: (_theme$transitions = theme.transitions) == null || (_theme$transitions$cr = _theme$transitions.create) == null ? void 0 : _theme$transitions$cr.call(_theme$transitions, 'fill', {\n duration: (_theme$transitions2 = theme.transitions) == null || (_theme$transitions2 = _theme$transitions2.duration) == null ? void 0 : _theme$transitions2.shorter\n }),\n fontSize: {\n inherit: 'inherit',\n small: ((_theme$typography = theme.typography) == null || (_theme$typography$pxT = _theme$typography.pxToRem) == null ? void 0 : _theme$typography$pxT.call(_theme$typography, 20)) || '1.25rem',\n medium: ((_theme$typography2 = theme.typography) == null || (_theme$typography2$px = _theme$typography2.pxToRem) == null ? void 0 : _theme$typography2$px.call(_theme$typography2, 24)) || '1.5rem',\n large: ((_theme$typography3 = theme.typography) == null || (_theme$typography3$px = _theme$typography3.pxToRem) == null ? void 0 : _theme$typography3$px.call(_theme$typography3, 35)) || '2.1875rem'\n }[ownerState.fontSize],\n // TODO v5 deprecate, v6 remove for sx\n color: (_palette$ownerState$c = (_palette = (theme.vars || theme).palette) == null || (_palette = _palette[ownerState.color]) == null ? void 0 : _palette.main) != null ? _palette$ownerState$c : {\n action: (_palette2 = (theme.vars || theme).palette) == null || (_palette2 = _palette2.action) == null ? void 0 : _palette2.active,\n disabled: (_palette3 = (theme.vars || theme).palette) == null || (_palette3 = _palette3.action) == null ? void 0 : _palette3.disabled,\n inherit: undefined\n }[ownerState.color]\n };\n});\nconst SvgIcon = /*#__PURE__*/React.forwardRef(function SvgIcon(inProps, ref) {\n const props = useThemeProps({\n props: inProps,\n name: 'MuiSvgIcon'\n });\n const {\n children,\n className,\n color = 'inherit',\n component = 'svg',\n fontSize = 'medium',\n htmlColor,\n inheritViewBox = false,\n titleAccess,\n viewBox = '0 0 24 24'\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const hasSvgAsChild = /*#__PURE__*/React.isValidElement(children) && children.type === 'svg';\n const ownerState = _extends({}, props, {\n color,\n component,\n fontSize,\n instanceFontSize: inProps.fontSize,\n inheritViewBox,\n viewBox,\n hasSvgAsChild\n });\n const more = {};\n if (!inheritViewBox) {\n more.viewBox = viewBox;\n }\n const classes = useUtilityClasses(ownerState);\n return /*#__PURE__*/_jsxs(SvgIconRoot, _extends({\n as: component,\n className: clsx(classes.root, className),\n focusable: \"false\",\n color: htmlColor,\n \"aria-hidden\": titleAccess ? undefined : true,\n role: titleAccess ? 'img' : undefined,\n ref: ref\n }, more, other, hasSvgAsChild && children.props, {\n ownerState: ownerState,\n children: [hasSvgAsChild ? children.props.children : children, titleAccess ? /*#__PURE__*/_jsx(\"title\", {\n children: titleAccess\n }) : null]\n }));\n});\nprocess.env.NODE_ENV !== \"production\" ? SvgIcon.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the d.ts file and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * Node passed into the SVG element.\n */\n children: PropTypes.node,\n /**\n * Override or extend the styles applied to the component.\n */\n classes: PropTypes.object,\n /**\n * @ignore\n */\n className: PropTypes.string,\n /**\n * The color of the component.\n * It supports both default and custom theme colors, which can be added as shown in the\n * [palette customization guide](https://mui.com/material-ui/customization/palette/#custom-colors).\n * You can use the `htmlColor` prop to apply a color attribute to the SVG element.\n * @default 'inherit'\n */\n color: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.oneOf(['inherit', 'action', 'disabled', 'primary', 'secondary', 'error', 'info', 'success', 'warning']), PropTypes.string]),\n /**\n * The component used for the root node.\n * Either a string to use a HTML element or a component.\n */\n component: PropTypes.elementType,\n /**\n * The fontSize applied to the icon. Defaults to 24px, but can be configure to inherit font size.\n * @default 'medium'\n */\n fontSize: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.oneOf(['inherit', 'large', 'medium', 'small']), PropTypes.string]),\n /**\n * Applies a color attribute to the SVG element.\n */\n htmlColor: PropTypes.string,\n /**\n * If `true`, the root node will inherit the custom `component`'s viewBox and the `viewBox`\n * prop will be ignored.\n * Useful when you want to reference a custom `component` and have `SvgIcon` pass that\n * `component`'s viewBox to the root node.\n * @default false\n */\n inheritViewBox: PropTypes.bool,\n /**\n * The shape-rendering attribute. The behavior of the different options is described on the\n * [MDN Web Docs](https://developer.mozilla.org/en-US/docs/Web/SVG/Attribute/shape-rendering).\n * If you are having issues with blurry icons you should investigate this prop.\n */\n shapeRendering: PropTypes.string,\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Provides a human-readable title for the element that contains it.\n * https://www.w3.org/TR/SVG-access/#Equivalent\n */\n titleAccess: PropTypes.string,\n /**\n * Allows you to redefine what the coordinates without units mean inside an SVG element.\n * For example, if the SVG element is 500 (width) by 200 (height),\n * and you pass viewBox=\"0 0 50 20\",\n * this means that the coordinates inside the SVG will go from the top left corner (0,0)\n * to bottom right (50,20) and each unit will be worth 10px.\n * @default '0 0 24 24'\n */\n viewBox: PropTypes.string\n} : void 0;\nSvgIcon.muiName = 'SvgIcon';\nexport default SvgIcon;","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport * as React from 'react';\nimport SvgIcon from '../SvgIcon';\n\n/**\n * Private module reserved for @mui packages.\n */\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nexport default function createSvgIcon(path, displayName) {\n function Component(props, ref) {\n return /*#__PURE__*/_jsx(SvgIcon, _extends({\n \"data-testid\": `${displayName}Icon`,\n ref: ref\n }, props, {\n children: path\n }));\n }\n if (process.env.NODE_ENV !== 'production') {\n // Need to set `displayName` on the inner component for React.memo.\n // React prior to 16.14 ignores `displayName` on the wrapper.\n Component.displayName = `${displayName}Icon`;\n }\n Component.muiName = SvgIcon.muiName;\n return /*#__PURE__*/React.memo( /*#__PURE__*/React.forwardRef(Component));\n}","'use client';\n\nimport { unstable_ClassNameGenerator as ClassNameGenerator } from '@mui/base/ClassNameGenerator';\nexport { default as capitalize } from './capitalize';\nexport { default as createChainedFunction } from './createChainedFunction';\nexport { default as createSvgIcon } from './createSvgIcon';\nexport { default as debounce } from './debounce';\nexport { default as deprecatedPropType } from './deprecatedPropType';\nexport { default as isMuiElement } from './isMuiElement';\nexport { default as ownerDocument } from './ownerDocument';\nexport { default as ownerWindow } from './ownerWindow';\nexport { default as requirePropFactory } from './requirePropFactory';\nexport { default as setRef } from './setRef';\nexport { default as unstable_useEnhancedEffect } from './useEnhancedEffect';\nexport { default as unstable_useId } from './useId';\nexport { default as unsupportedProp } from './unsupportedProp';\nexport { default as useControlled } from './useControlled';\nexport { default as useEventCallback } from './useEventCallback';\nexport { default as useForkRef } from './useForkRef';\nexport { default as useIsFocusVisible } from './useIsFocusVisible';\n// TODO: remove this export once ClassNameGenerator is stable\n// eslint-disable-next-line @typescript-eslint/naming-convention\nexport const unstable_ClassNameGenerator = {\n configure: generator => {\n if (process.env.NODE_ENV !== 'production') {\n console.warn(['MUI: `ClassNameGenerator` import from `@mui/material/utils` is outdated and might cause unexpected issues.', '', \"You should use `import { unstable_ClassNameGenerator } from '@mui/material/className'` instead\", '', 'The detail of the issue: https://github.com/mui/material-ui/issues/30011#issuecomment-1024993401', '', 'The updated documentation: https://mui.com/guides/classname-generator/'].join('\\n'));\n }\n ClassNameGenerator.configure(generator);\n }\n};","\"use strict\";\n'use client';\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nObject.defineProperty(exports, \"default\", {\n enumerable: true,\n get: function () {\n return _utils.createSvgIcon;\n }\n});\nvar _utils = require(\"@mui/material/utils\");","\"use strict\";\n\"use client\";\n\nvar _interopRequireDefault = require(\"@babel/runtime/helpers/interopRequireDefault\");\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = void 0;\nvar _createSvgIcon = _interopRequireDefault(require(\"./utils/createSvgIcon\"));\nvar _jsxRuntime = require(\"react/jsx-runtime\");\nvar _default = exports.default = (0, _createSvgIcon.default)( /*#__PURE__*/(0, _jsxRuntime.jsx)(\"path\", {\n d: \"m10 17 5-5-5-5z\"\n}), 'ArrowRight');","/**\n * Determines if a given element is a DOM element name (i.e. not a React component).\n */\nexport function isHostComponent(element) {\n return typeof element === 'string';\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport { isHostComponent } from './isHostComponent';\n\n/**\n * Type of the ownerState based on the type of an element it applies to.\n * This resolves to the provided OwnerState for React components and `undefined` for host components.\n * Falls back to `OwnerState | undefined` when the exact type can't be determined in development time.\n */\n\n/**\n * Appends the ownerState object to the props, merging with the existing one if necessary.\n *\n * @param elementType Type of the element that owns the `existingProps`. If the element is a DOM node or undefined, `ownerState` is not applied.\n * @param otherProps Props of the element.\n * @param ownerState\n */\nexport function appendOwnerState(elementType, otherProps, ownerState) {\n if (elementType === undefined || isHostComponent(elementType)) {\n return otherProps;\n }\n return _extends({}, otherProps, {\n ownerState: _extends({}, otherProps.ownerState, ownerState)\n });\n}","'use client';\n\nimport * as React from 'react';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nconst defaultContextValue = {\n disableDefaultClasses: false\n};\nconst ClassNameConfiguratorContext = /*#__PURE__*/React.createContext(defaultContextValue);\n/**\n * @ignore - internal hook.\n *\n * Wraps the `generateUtilityClass` function and controls how the classes are generated.\n * Currently it only affects whether the classes are applied or not.\n *\n * @returns Function to be called with the `generateUtilityClass` function specific to a component to generate the classes.\n */\nexport function useClassNamesOverride(generateUtilityClass) {\n const {\n disableDefaultClasses\n } = React.useContext(ClassNameConfiguratorContext);\n return slot => {\n if (disableDefaultClasses) {\n return '';\n }\n return generateUtilityClass(slot);\n };\n}\n\n/**\n * Allows to configure the components within to not apply any built-in classes.\n */\nexport function ClassNameConfigurator(props) {\n const {\n disableDefaultClasses,\n children\n } = props;\n const contextValue = React.useMemo(() => ({\n disableDefaultClasses: disableDefaultClasses != null ? disableDefaultClasses : false\n }), [disableDefaultClasses]);\n return /*#__PURE__*/_jsx(ClassNameConfiguratorContext.Provider, {\n value: contextValue,\n children: children\n });\n}","/**\n * Extracts event handlers from a given object.\n * A prop is considered an event handler if it is a function and its name starts with `on`.\n *\n * @param object An object to extract event handlers from.\n * @param excludeKeys An array of keys to exclude from the returned object.\n */\nexport function extractEventHandlers(object, excludeKeys = []) {\n if (object === undefined) {\n return {};\n }\n const result = {};\n Object.keys(object).filter(prop => prop.match(/^on[A-Z]/) && typeof object[prop] === 'function' && !excludeKeys.includes(prop)).forEach(prop => {\n result[prop] = object[prop];\n });\n return result;\n}","/**\n * If `componentProps` is a function, calls it with the provided `ownerState`.\n * Otherwise, just returns `componentProps`.\n */\nexport function resolveComponentProps(componentProps, ownerState, slotState) {\n if (typeof componentProps === 'function') {\n return componentProps(ownerState, slotState);\n }\n return componentProps;\n}","/**\n * Removes event handlers from the given object.\n * A field is considered an event handler if it is a function with a name beginning with `on`.\n *\n * @param object Object to remove event handlers from.\n * @returns Object with event handlers removed.\n */\nexport function omitEventHandlers(object) {\n if (object === undefined) {\n return {};\n }\n const result = {};\n Object.keys(object).filter(prop => !(prop.match(/^on[A-Z]/) && typeof object[prop] === 'function')).forEach(prop => {\n result[prop] = object[prop];\n });\n return result;\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport clsx from 'clsx';\nimport { extractEventHandlers } from './extractEventHandlers';\nimport { omitEventHandlers } from './omitEventHandlers';\n/**\n * Merges the slot component internal props (usually coming from a hook)\n * with the externally provided ones.\n *\n * The merge order is (the latter overrides the former):\n * 1. The internal props (specified as a getter function to work with get*Props hook result)\n * 2. Additional props (specified internally on a Base UI component)\n * 3. External props specified on the owner component. These should only be used on a root slot.\n * 4. External props specified in the `slotProps.*` prop.\n * 5. The `className` prop - combined from all the above.\n * @param parameters\n * @returns\n */\nexport function mergeSlotProps(parameters) {\n const {\n getSlotProps,\n additionalProps,\n externalSlotProps,\n externalForwardedProps,\n className\n } = parameters;\n if (!getSlotProps) {\n // The simpler case - getSlotProps is not defined, so no internal event handlers are defined,\n // so we can simply merge all the props without having to worry about extracting event handlers.\n const joinedClasses = clsx(additionalProps == null ? void 0 : additionalProps.className, className, externalForwardedProps == null ? void 0 : externalForwardedProps.className, externalSlotProps == null ? void 0 : externalSlotProps.className);\n const mergedStyle = _extends({}, additionalProps == null ? void 0 : additionalProps.style, externalForwardedProps == null ? void 0 : externalForwardedProps.style, externalSlotProps == null ? void 0 : externalSlotProps.style);\n const props = _extends({}, additionalProps, externalForwardedProps, externalSlotProps);\n if (joinedClasses.length > 0) {\n props.className = joinedClasses;\n }\n if (Object.keys(mergedStyle).length > 0) {\n props.style = mergedStyle;\n }\n return {\n props,\n internalRef: undefined\n };\n }\n\n // In this case, getSlotProps is responsible for calling the external event handlers.\n // We don't need to include them in the merged props because of this.\n\n const eventHandlers = extractEventHandlers(_extends({}, externalForwardedProps, externalSlotProps));\n const componentsPropsWithoutEventHandlers = omitEventHandlers(externalSlotProps);\n const otherPropsWithoutEventHandlers = omitEventHandlers(externalForwardedProps);\n const internalSlotProps = getSlotProps(eventHandlers);\n\n // The order of classes is important here.\n // Emotion (that we use in libraries consuming Base UI) depends on this order\n // to properly override style. It requires the most important classes to be last\n // (see https://github.com/mui/material-ui/pull/33205) for the related discussion.\n const joinedClasses = clsx(internalSlotProps == null ? void 0 : internalSlotProps.className, additionalProps == null ? void 0 : additionalProps.className, className, externalForwardedProps == null ? void 0 : externalForwardedProps.className, externalSlotProps == null ? void 0 : externalSlotProps.className);\n const mergedStyle = _extends({}, internalSlotProps == null ? void 0 : internalSlotProps.style, additionalProps == null ? void 0 : additionalProps.style, externalForwardedProps == null ? void 0 : externalForwardedProps.style, externalSlotProps == null ? void 0 : externalSlotProps.style);\n const props = _extends({}, internalSlotProps, additionalProps, otherPropsWithoutEventHandlers, componentsPropsWithoutEventHandlers);\n if (joinedClasses.length > 0) {\n props.className = joinedClasses;\n }\n if (Object.keys(mergedStyle).length > 0) {\n props.style = mergedStyle;\n }\n return {\n props,\n internalRef: internalSlotProps.ref\n };\n}","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"elementType\", \"externalSlotProps\", \"ownerState\", \"skipResolvingSlotProps\"];\nimport { unstable_useForkRef as useForkRef } from '@mui/utils';\nimport { appendOwnerState } from './appendOwnerState';\nimport { mergeSlotProps } from './mergeSlotProps';\nimport { resolveComponentProps } from './resolveComponentProps';\n/**\n * @ignore - do not document.\n * Builds the props to be passed into the slot of an unstyled component.\n * It merges the internal props of the component with the ones supplied by the user, allowing to customize the behavior.\n * If the slot component is not a host component, it also merges in the `ownerState`.\n *\n * @param parameters.getSlotProps - A function that returns the props to be passed to the slot component.\n */\nexport function useSlotProps(parameters) {\n var _parameters$additiona;\n const {\n elementType,\n externalSlotProps,\n ownerState,\n skipResolvingSlotProps = false\n } = parameters,\n rest = _objectWithoutPropertiesLoose(parameters, _excluded);\n const resolvedComponentsProps = skipResolvingSlotProps ? {} : resolveComponentProps(externalSlotProps, ownerState);\n const {\n props: mergedProps,\n internalRef\n } = mergeSlotProps(_extends({}, rest, {\n externalSlotProps: resolvedComponentsProps\n }));\n const ref = useForkRef(internalRef, resolvedComponentsProps == null ? void 0 : resolvedComponentsProps.ref, (_parameters$additiona = parameters.additionalProps) == null ? void 0 : _parameters$additiona.ref);\n const props = appendOwnerState(elementType, _extends({}, mergedProps, {\n ref\n }), ownerState);\n return props;\n}","import { globalStateClasses } from '@mui/utils/generateUtilityClass';\nconst GLOBAL_CLASS_PREFIX = 'base';\nfunction buildStateClass(state) {\n return `${GLOBAL_CLASS_PREFIX}--${state}`;\n}\nfunction buildSlotClass(componentName, slot) {\n return `${GLOBAL_CLASS_PREFIX}-${componentName}-${slot}`;\n}\nexport function generateUtilityClass(componentName, slot) {\n const globalStateClass = globalStateClasses[slot];\n return globalStateClass ? buildStateClass(globalStateClass) : buildSlotClass(componentName, slot);\n}\nexport function isGlobalState(slot) {\n return globalStateClasses[slot] !== undefined;\n}","import { generateUtilityClass } from '../generateUtilityClass';\nexport function generateUtilityClasses(componentName, slots) {\n const result = {};\n slots.forEach(slot => {\n result[slot] = generateUtilityClass(componentName, slot);\n });\n return result;\n}","'use client';\n\nimport * as React from 'react';\nimport * as ReactDOM from 'react-dom';\nimport PropTypes from 'prop-types';\nimport { exactProp, HTMLElementType, unstable_useEnhancedEffect as useEnhancedEffect, unstable_useForkRef as useForkRef, unstable_setRef as setRef } from '@mui/utils';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nfunction getContainer(container) {\n return typeof container === 'function' ? container() : container;\n}\n\n/**\n * Portals provide a first-class way to render children into a DOM node\n * that exists outside the DOM hierarchy of the parent component.\n *\n * Demos:\n *\n * - [Portal](https://mui.com/base-ui/react-portal/)\n *\n * API:\n *\n * - [Portal API](https://mui.com/base-ui/react-portal/components-api/#portal)\n */\nconst Portal = /*#__PURE__*/React.forwardRef(function Portal(props, forwardedRef) {\n const {\n children,\n container,\n disablePortal = false\n } = props;\n const [mountNode, setMountNode] = React.useState(null);\n // @ts-expect-error TODO upstream fix\n const handleRef = useForkRef( /*#__PURE__*/React.isValidElement(children) ? children.ref : null, forwardedRef);\n useEnhancedEffect(() => {\n if (!disablePortal) {\n setMountNode(getContainer(container) || document.body);\n }\n }, [container, disablePortal]);\n useEnhancedEffect(() => {\n if (mountNode && !disablePortal) {\n setRef(forwardedRef, mountNode);\n return () => {\n setRef(forwardedRef, null);\n };\n }\n return undefined;\n }, [forwardedRef, mountNode, disablePortal]);\n if (disablePortal) {\n if ( /*#__PURE__*/React.isValidElement(children)) {\n const newProps = {\n ref: handleRef\n };\n return /*#__PURE__*/React.cloneElement(children, newProps);\n }\n return /*#__PURE__*/_jsx(React.Fragment, {\n children: children\n });\n }\n return /*#__PURE__*/_jsx(React.Fragment, {\n children: mountNode ? /*#__PURE__*/ReactDOM.createPortal(children, mountNode) : mountNode\n });\n});\nprocess.env.NODE_ENV !== \"production\" ? Portal.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * The children to render into the `container`.\n */\n children: PropTypes.node,\n /**\n * An HTML element or function that returns one.\n * The `container` will have the portal children appended to it.\n *\n * You can also provide a callback, which is called in a React layout effect.\n * This lets you set the container from a ref, and also makes server-side rendering possible.\n *\n * By default, it uses the body of the top-level document object,\n * so it's simply `document.body` most of the time.\n */\n container: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.func]),\n /**\n * The `children` will be under the DOM hierarchy of the parent component.\n * @default false\n */\n disablePortal: PropTypes.bool\n} : void 0;\nif (process.env.NODE_ENV !== 'production') {\n // eslint-disable-next-line\n Portal['propTypes' + ''] = exactProp(Portal.propTypes);\n}\nexport { Portal };","export var top = 'top';\nexport var bottom = 'bottom';\nexport var right = 'right';\nexport var left = 'left';\nexport var auto = 'auto';\nexport var basePlacements = [top, bottom, right, left];\nexport var start = 'start';\nexport var end = 'end';\nexport var clippingParents = 'clippingParents';\nexport var viewport = 'viewport';\nexport var popper = 'popper';\nexport var reference = 'reference';\nexport var variationPlacements = /*#__PURE__*/basePlacements.reduce(function (acc, placement) {\n return acc.concat([placement + \"-\" + start, placement + \"-\" + end]);\n}, []);\nexport var placements = /*#__PURE__*/[].concat(basePlacements, [auto]).reduce(function (acc, placement) {\n return acc.concat([placement, placement + \"-\" + start, placement + \"-\" + end]);\n}, []); // modifiers that need to read the DOM\n\nexport var beforeRead = 'beforeRead';\nexport var read = 'read';\nexport var afterRead = 'afterRead'; // pure-logic modifiers\n\nexport var beforeMain = 'beforeMain';\nexport var main = 'main';\nexport var afterMain = 'afterMain'; // modifier with the purpose to write to the DOM (or write into a framework state)\n\nexport var beforeWrite = 'beforeWrite';\nexport var write = 'write';\nexport var afterWrite = 'afterWrite';\nexport var modifierPhases = [beforeRead, read, afterRead, beforeMain, main, afterMain, beforeWrite, write, afterWrite];","export default function getNodeName(element) {\n return element ? (element.nodeName || '').toLowerCase() : null;\n}","export default function getWindow(node) {\n if (node == null) {\n return window;\n }\n\n if (node.toString() !== '[object Window]') {\n var ownerDocument = node.ownerDocument;\n return ownerDocument ? ownerDocument.defaultView || window : window;\n }\n\n return node;\n}","import getWindow from \"./getWindow.js\";\n\nfunction isElement(node) {\n var OwnElement = getWindow(node).Element;\n return node instanceof OwnElement || node instanceof Element;\n}\n\nfunction isHTMLElement(node) {\n var OwnElement = getWindow(node).HTMLElement;\n return node instanceof OwnElement || node instanceof HTMLElement;\n}\n\nfunction isShadowRoot(node) {\n // IE 11 has no ShadowRoot\n if (typeof ShadowRoot === 'undefined') {\n return false;\n }\n\n var OwnElement = getWindow(node).ShadowRoot;\n return node instanceof OwnElement || node instanceof ShadowRoot;\n}\n\nexport { isElement, isHTMLElement, isShadowRoot };","import getNodeName from \"../dom-utils/getNodeName.js\";\nimport { isHTMLElement } from \"../dom-utils/instanceOf.js\"; // This modifier takes the styles prepared by the `computeStyles` modifier\n// and applies them to the HTMLElements such as popper and arrow\n\nfunction applyStyles(_ref) {\n var state = _ref.state;\n Object.keys(state.elements).forEach(function (name) {\n var style = state.styles[name] || {};\n var attributes = state.attributes[name] || {};\n var element = state.elements[name]; // arrow is optional + virtual elements\n\n if (!isHTMLElement(element) || !getNodeName(element)) {\n return;\n } // Flow doesn't support to extend this property, but it's the most\n // effective way to apply styles to an HTMLElement\n // $FlowFixMe[cannot-write]\n\n\n Object.assign(element.style, style);\n Object.keys(attributes).forEach(function (name) {\n var value = attributes[name];\n\n if (value === false) {\n element.removeAttribute(name);\n } else {\n element.setAttribute(name, value === true ? '' : value);\n }\n });\n });\n}\n\nfunction effect(_ref2) {\n var state = _ref2.state;\n var initialStyles = {\n popper: {\n position: state.options.strategy,\n left: '0',\n top: '0',\n margin: '0'\n },\n arrow: {\n position: 'absolute'\n },\n reference: {}\n };\n Object.assign(state.elements.popper.style, initialStyles.popper);\n state.styles = initialStyles;\n\n if (state.elements.arrow) {\n Object.assign(state.elements.arrow.style, initialStyles.arrow);\n }\n\n return function () {\n Object.keys(state.elements).forEach(function (name) {\n var element = state.elements[name];\n var attributes = state.attributes[name] || {};\n var styleProperties = Object.keys(state.styles.hasOwnProperty(name) ? state.styles[name] : initialStyles[name]); // Set all values to an empty string to unset them\n\n var style = styleProperties.reduce(function (style, property) {\n style[property] = '';\n return style;\n }, {}); // arrow is optional + virtual elements\n\n if (!isHTMLElement(element) || !getNodeName(element)) {\n return;\n }\n\n Object.assign(element.style, style);\n Object.keys(attributes).forEach(function (attribute) {\n element.removeAttribute(attribute);\n });\n });\n };\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'applyStyles',\n enabled: true,\n phase: 'write',\n fn: applyStyles,\n effect: effect,\n requires: ['computeStyles']\n};","import { auto } from \"../enums.js\";\nexport default function getBasePlacement(placement) {\n return placement.split('-')[0];\n}","export var max = Math.max;\nexport var min = Math.min;\nexport var round = Math.round;","export default function getUAString() {\n var uaData = navigator.userAgentData;\n\n if (uaData != null && uaData.brands && Array.isArray(uaData.brands)) {\n return uaData.brands.map(function (item) {\n return item.brand + \"/\" + item.version;\n }).join(' ');\n }\n\n return navigator.userAgent;\n}","import getUAString from \"../utils/userAgent.js\";\nexport default function isLayoutViewport() {\n return !/^((?!chrome|android).)*safari/i.test(getUAString());\n}","import { isElement, isHTMLElement } from \"./instanceOf.js\";\nimport { round } from \"../utils/math.js\";\nimport getWindow from \"./getWindow.js\";\nimport isLayoutViewport from \"./isLayoutViewport.js\";\nexport default function getBoundingClientRect(element, includeScale, isFixedStrategy) {\n if (includeScale === void 0) {\n includeScale = false;\n }\n\n if (isFixedStrategy === void 0) {\n isFixedStrategy = false;\n }\n\n var clientRect = element.getBoundingClientRect();\n var scaleX = 1;\n var scaleY = 1;\n\n if (includeScale && isHTMLElement(element)) {\n scaleX = element.offsetWidth > 0 ? round(clientRect.width) / element.offsetWidth || 1 : 1;\n scaleY = element.offsetHeight > 0 ? round(clientRect.height) / element.offsetHeight || 1 : 1;\n }\n\n var _ref = isElement(element) ? getWindow(element) : window,\n visualViewport = _ref.visualViewport;\n\n var addVisualOffsets = !isLayoutViewport() && isFixedStrategy;\n var x = (clientRect.left + (addVisualOffsets && visualViewport ? visualViewport.offsetLeft : 0)) / scaleX;\n var y = (clientRect.top + (addVisualOffsets && visualViewport ? visualViewport.offsetTop : 0)) / scaleY;\n var width = clientRect.width / scaleX;\n var height = clientRect.height / scaleY;\n return {\n width: width,\n height: height,\n top: y,\n right: x + width,\n bottom: y + height,\n left: x,\n x: x,\n y: y\n };\n}","import getBoundingClientRect from \"./getBoundingClientRect.js\"; // Returns the layout rect of an element relative to its offsetParent. Layout\n// means it doesn't take into account transforms.\n\nexport default function getLayoutRect(element) {\n var clientRect = getBoundingClientRect(element); // Use the clientRect sizes if it's not been transformed.\n // Fixes https://github.com/popperjs/popper-core/issues/1223\n\n var width = element.offsetWidth;\n var height = element.offsetHeight;\n\n if (Math.abs(clientRect.width - width) <= 1) {\n width = clientRect.width;\n }\n\n if (Math.abs(clientRect.height - height) <= 1) {\n height = clientRect.height;\n }\n\n return {\n x: element.offsetLeft,\n y: element.offsetTop,\n width: width,\n height: height\n };\n}","import { isShadowRoot } from \"./instanceOf.js\";\nexport default function contains(parent, child) {\n var rootNode = child.getRootNode && child.getRootNode(); // First, attempt with faster native method\n\n if (parent.contains(child)) {\n return true;\n } // then fallback to custom implementation with Shadow DOM support\n else if (rootNode && isShadowRoot(rootNode)) {\n var next = child;\n\n do {\n if (next && parent.isSameNode(next)) {\n return true;\n } // $FlowFixMe[prop-missing]: need a better way to handle this...\n\n\n next = next.parentNode || next.host;\n } while (next);\n } // Give up, the result is false\n\n\n return false;\n}","import getWindow from \"./getWindow.js\";\nexport default function getComputedStyle(element) {\n return getWindow(element).getComputedStyle(element);\n}","import getNodeName from \"./getNodeName.js\";\nexport default function isTableElement(element) {\n return ['table', 'td', 'th'].indexOf(getNodeName(element)) >= 0;\n}","import { isElement } from \"./instanceOf.js\";\nexport default function getDocumentElement(element) {\n // $FlowFixMe[incompatible-return]: assume body is always available\n return ((isElement(element) ? element.ownerDocument : // $FlowFixMe[prop-missing]\n element.document) || window.document).documentElement;\n}","import getNodeName from \"./getNodeName.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport { isShadowRoot } from \"./instanceOf.js\";\nexport default function getParentNode(element) {\n if (getNodeName(element) === 'html') {\n return element;\n }\n\n return (// this is a quicker (but less type safe) way to save quite some bytes from the bundle\n // $FlowFixMe[incompatible-return]\n // $FlowFixMe[prop-missing]\n element.assignedSlot || // step into the shadow DOM of the parent of a slotted node\n element.parentNode || ( // DOM Element detected\n isShadowRoot(element) ? element.host : null) || // ShadowRoot detected\n // $FlowFixMe[incompatible-call]: HTMLElement is a Node\n getDocumentElement(element) // fallback\n\n );\n}","import getWindow from \"./getWindow.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport getComputedStyle from \"./getComputedStyle.js\";\nimport { isHTMLElement, isShadowRoot } from \"./instanceOf.js\";\nimport isTableElement from \"./isTableElement.js\";\nimport getParentNode from \"./getParentNode.js\";\nimport getUAString from \"../utils/userAgent.js\";\n\nfunction getTrueOffsetParent(element) {\n if (!isHTMLElement(element) || // https://github.com/popperjs/popper-core/issues/837\n getComputedStyle(element).position === 'fixed') {\n return null;\n }\n\n return element.offsetParent;\n} // `.offsetParent` reports `null` for fixed elements, while absolute elements\n// return the containing block\n\n\nfunction getContainingBlock(element) {\n var isFirefox = /firefox/i.test(getUAString());\n var isIE = /Trident/i.test(getUAString());\n\n if (isIE && isHTMLElement(element)) {\n // In IE 9, 10 and 11 fixed elements containing block is always established by the viewport\n var elementCss = getComputedStyle(element);\n\n if (elementCss.position === 'fixed') {\n return null;\n }\n }\n\n var currentNode = getParentNode(element);\n\n if (isShadowRoot(currentNode)) {\n currentNode = currentNode.host;\n }\n\n while (isHTMLElement(currentNode) && ['html', 'body'].indexOf(getNodeName(currentNode)) < 0) {\n var css = getComputedStyle(currentNode); // This is non-exhaustive but covers the most common CSS properties that\n // create a containing block.\n // https://developer.mozilla.org/en-US/docs/Web/CSS/Containing_block#identifying_the_containing_block\n\n if (css.transform !== 'none' || css.perspective !== 'none' || css.contain === 'paint' || ['transform', 'perspective'].indexOf(css.willChange) !== -1 || isFirefox && css.willChange === 'filter' || isFirefox && css.filter && css.filter !== 'none') {\n return currentNode;\n } else {\n currentNode = currentNode.parentNode;\n }\n }\n\n return null;\n} // Gets the closest ancestor positioned element. Handles some edge cases,\n// such as table ancestors and cross browser bugs.\n\n\nexport default function getOffsetParent(element) {\n var window = getWindow(element);\n var offsetParent = getTrueOffsetParent(element);\n\n while (offsetParent && isTableElement(offsetParent) && getComputedStyle(offsetParent).position === 'static') {\n offsetParent = getTrueOffsetParent(offsetParent);\n }\n\n if (offsetParent && (getNodeName(offsetParent) === 'html' || getNodeName(offsetParent) === 'body' && getComputedStyle(offsetParent).position === 'static')) {\n return window;\n }\n\n return offsetParent || getContainingBlock(element) || window;\n}","export default function getMainAxisFromPlacement(placement) {\n return ['top', 'bottom'].indexOf(placement) >= 0 ? 'x' : 'y';\n}","import { max as mathMax, min as mathMin } from \"./math.js\";\nexport function within(min, value, max) {\n return mathMax(min, mathMin(value, max));\n}\nexport function withinMaxClamp(min, value, max) {\n var v = within(min, value, max);\n return v > max ? max : v;\n}","export default function getFreshSideObject() {\n return {\n top: 0,\n right: 0,\n bottom: 0,\n left: 0\n };\n}","import getFreshSideObject from \"./getFreshSideObject.js\";\nexport default function mergePaddingObject(paddingObject) {\n return Object.assign({}, getFreshSideObject(), paddingObject);\n}","export default function expandToHashMap(value, keys) {\n return keys.reduce(function (hashMap, key) {\n hashMap[key] = value;\n return hashMap;\n }, {});\n}","import getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getLayoutRect from \"../dom-utils/getLayoutRect.js\";\nimport contains from \"../dom-utils/contains.js\";\nimport getOffsetParent from \"../dom-utils/getOffsetParent.js\";\nimport getMainAxisFromPlacement from \"../utils/getMainAxisFromPlacement.js\";\nimport { within } from \"../utils/within.js\";\nimport mergePaddingObject from \"../utils/mergePaddingObject.js\";\nimport expandToHashMap from \"../utils/expandToHashMap.js\";\nimport { left, right, basePlacements, top, bottom } from \"../enums.js\"; // eslint-disable-next-line import/no-unused-modules\n\nvar toPaddingObject = function toPaddingObject(padding, state) {\n padding = typeof padding === 'function' ? padding(Object.assign({}, state.rects, {\n placement: state.placement\n })) : padding;\n return mergePaddingObject(typeof padding !== 'number' ? padding : expandToHashMap(padding, basePlacements));\n};\n\nfunction arrow(_ref) {\n var _state$modifiersData$;\n\n var state = _ref.state,\n name = _ref.name,\n options = _ref.options;\n var arrowElement = state.elements.arrow;\n var popperOffsets = state.modifiersData.popperOffsets;\n var basePlacement = getBasePlacement(state.placement);\n var axis = getMainAxisFromPlacement(basePlacement);\n var isVertical = [left, right].indexOf(basePlacement) >= 0;\n var len = isVertical ? 'height' : 'width';\n\n if (!arrowElement || !popperOffsets) {\n return;\n }\n\n var paddingObject = toPaddingObject(options.padding, state);\n var arrowRect = getLayoutRect(arrowElement);\n var minProp = axis === 'y' ? top : left;\n var maxProp = axis === 'y' ? bottom : right;\n var endDiff = state.rects.reference[len] + state.rects.reference[axis] - popperOffsets[axis] - state.rects.popper[len];\n var startDiff = popperOffsets[axis] - state.rects.reference[axis];\n var arrowOffsetParent = getOffsetParent(arrowElement);\n var clientSize = arrowOffsetParent ? axis === 'y' ? arrowOffsetParent.clientHeight || 0 : arrowOffsetParent.clientWidth || 0 : 0;\n var centerToReference = endDiff / 2 - startDiff / 2; // Make sure the arrow doesn't overflow the popper if the center point is\n // outside of the popper bounds\n\n var min = paddingObject[minProp];\n var max = clientSize - arrowRect[len] - paddingObject[maxProp];\n var center = clientSize / 2 - arrowRect[len] / 2 + centerToReference;\n var offset = within(min, center, max); // Prevents breaking syntax highlighting...\n\n var axisProp = axis;\n state.modifiersData[name] = (_state$modifiersData$ = {}, _state$modifiersData$[axisProp] = offset, _state$modifiersData$.centerOffset = offset - center, _state$modifiersData$);\n}\n\nfunction effect(_ref2) {\n var state = _ref2.state,\n options = _ref2.options;\n var _options$element = options.element,\n arrowElement = _options$element === void 0 ? '[data-popper-arrow]' : _options$element;\n\n if (arrowElement == null) {\n return;\n } // CSS selector\n\n\n if (typeof arrowElement === 'string') {\n arrowElement = state.elements.popper.querySelector(arrowElement);\n\n if (!arrowElement) {\n return;\n }\n }\n\n if (!contains(state.elements.popper, arrowElement)) {\n return;\n }\n\n state.elements.arrow = arrowElement;\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'arrow',\n enabled: true,\n phase: 'main',\n fn: arrow,\n effect: effect,\n requires: ['popperOffsets'],\n requiresIfExists: ['preventOverflow']\n};","export default function getVariation(placement) {\n return placement.split('-')[1];\n}","import { top, left, right, bottom, end } from \"../enums.js\";\nimport getOffsetParent from \"../dom-utils/getOffsetParent.js\";\nimport getWindow from \"../dom-utils/getWindow.js\";\nimport getDocumentElement from \"../dom-utils/getDocumentElement.js\";\nimport getComputedStyle from \"../dom-utils/getComputedStyle.js\";\nimport getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getVariation from \"../utils/getVariation.js\";\nimport { round } from \"../utils/math.js\"; // eslint-disable-next-line import/no-unused-modules\n\nvar unsetSides = {\n top: 'auto',\n right: 'auto',\n bottom: 'auto',\n left: 'auto'\n}; // Round the offsets to the nearest suitable subpixel based on the DPR.\n// Zooming can change the DPR, but it seems to report a value that will\n// cleanly divide the values into the appropriate subpixels.\n\nfunction roundOffsetsByDPR(_ref, win) {\n var x = _ref.x,\n y = _ref.y;\n var dpr = win.devicePixelRatio || 1;\n return {\n x: round(x * dpr) / dpr || 0,\n y: round(y * dpr) / dpr || 0\n };\n}\n\nexport function mapToStyles(_ref2) {\n var _Object$assign2;\n\n var popper = _ref2.popper,\n popperRect = _ref2.popperRect,\n placement = _ref2.placement,\n variation = _ref2.variation,\n offsets = _ref2.offsets,\n position = _ref2.position,\n gpuAcceleration = _ref2.gpuAcceleration,\n adaptive = _ref2.adaptive,\n roundOffsets = _ref2.roundOffsets,\n isFixed = _ref2.isFixed;\n var _offsets$x = offsets.x,\n x = _offsets$x === void 0 ? 0 : _offsets$x,\n _offsets$y = offsets.y,\n y = _offsets$y === void 0 ? 0 : _offsets$y;\n\n var _ref3 = typeof roundOffsets === 'function' ? roundOffsets({\n x: x,\n y: y\n }) : {\n x: x,\n y: y\n };\n\n x = _ref3.x;\n y = _ref3.y;\n var hasX = offsets.hasOwnProperty('x');\n var hasY = offsets.hasOwnProperty('y');\n var sideX = left;\n var sideY = top;\n var win = window;\n\n if (adaptive) {\n var offsetParent = getOffsetParent(popper);\n var heightProp = 'clientHeight';\n var widthProp = 'clientWidth';\n\n if (offsetParent === getWindow(popper)) {\n offsetParent = getDocumentElement(popper);\n\n if (getComputedStyle(offsetParent).position !== 'static' && position === 'absolute') {\n heightProp = 'scrollHeight';\n widthProp = 'scrollWidth';\n }\n } // $FlowFixMe[incompatible-cast]: force type refinement, we compare offsetParent with window above, but Flow doesn't detect it\n\n\n offsetParent = offsetParent;\n\n if (placement === top || (placement === left || placement === right) && variation === end) {\n sideY = bottom;\n var offsetY = isFixed && offsetParent === win && win.visualViewport ? win.visualViewport.height : // $FlowFixMe[prop-missing]\n offsetParent[heightProp];\n y -= offsetY - popperRect.height;\n y *= gpuAcceleration ? 1 : -1;\n }\n\n if (placement === left || (placement === top || placement === bottom) && variation === end) {\n sideX = right;\n var offsetX = isFixed && offsetParent === win && win.visualViewport ? win.visualViewport.width : // $FlowFixMe[prop-missing]\n offsetParent[widthProp];\n x -= offsetX - popperRect.width;\n x *= gpuAcceleration ? 1 : -1;\n }\n }\n\n var commonStyles = Object.assign({\n position: position\n }, adaptive && unsetSides);\n\n var _ref4 = roundOffsets === true ? roundOffsetsByDPR({\n x: x,\n y: y\n }, getWindow(popper)) : {\n x: x,\n y: y\n };\n\n x = _ref4.x;\n y = _ref4.y;\n\n if (gpuAcceleration) {\n var _Object$assign;\n\n return Object.assign({}, commonStyles, (_Object$assign = {}, _Object$assign[sideY] = hasY ? '0' : '', _Object$assign[sideX] = hasX ? '0' : '', _Object$assign.transform = (win.devicePixelRatio || 1) <= 1 ? \"translate(\" + x + \"px, \" + y + \"px)\" : \"translate3d(\" + x + \"px, \" + y + \"px, 0)\", _Object$assign));\n }\n\n return Object.assign({}, commonStyles, (_Object$assign2 = {}, _Object$assign2[sideY] = hasY ? y + \"px\" : '', _Object$assign2[sideX] = hasX ? x + \"px\" : '', _Object$assign2.transform = '', _Object$assign2));\n}\n\nfunction computeStyles(_ref5) {\n var state = _ref5.state,\n options = _ref5.options;\n var _options$gpuAccelerat = options.gpuAcceleration,\n gpuAcceleration = _options$gpuAccelerat === void 0 ? true : _options$gpuAccelerat,\n _options$adaptive = options.adaptive,\n adaptive = _options$adaptive === void 0 ? true : _options$adaptive,\n _options$roundOffsets = options.roundOffsets,\n roundOffsets = _options$roundOffsets === void 0 ? true : _options$roundOffsets;\n var commonStyles = {\n placement: getBasePlacement(state.placement),\n variation: getVariation(state.placement),\n popper: state.elements.popper,\n popperRect: state.rects.popper,\n gpuAcceleration: gpuAcceleration,\n isFixed: state.options.strategy === 'fixed'\n };\n\n if (state.modifiersData.popperOffsets != null) {\n state.styles.popper = Object.assign({}, state.styles.popper, mapToStyles(Object.assign({}, commonStyles, {\n offsets: state.modifiersData.popperOffsets,\n position: state.options.strategy,\n adaptive: adaptive,\n roundOffsets: roundOffsets\n })));\n }\n\n if (state.modifiersData.arrow != null) {\n state.styles.arrow = Object.assign({}, state.styles.arrow, mapToStyles(Object.assign({}, commonStyles, {\n offsets: state.modifiersData.arrow,\n position: 'absolute',\n adaptive: false,\n roundOffsets: roundOffsets\n })));\n }\n\n state.attributes.popper = Object.assign({}, state.attributes.popper, {\n 'data-popper-placement': state.placement\n });\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'computeStyles',\n enabled: true,\n phase: 'beforeWrite',\n fn: computeStyles,\n data: {}\n};","import getWindow from \"../dom-utils/getWindow.js\"; // eslint-disable-next-line import/no-unused-modules\n\nvar passive = {\n passive: true\n};\n\nfunction effect(_ref) {\n var state = _ref.state,\n instance = _ref.instance,\n options = _ref.options;\n var _options$scroll = options.scroll,\n scroll = _options$scroll === void 0 ? true : _options$scroll,\n _options$resize = options.resize,\n resize = _options$resize === void 0 ? true : _options$resize;\n var window = getWindow(state.elements.popper);\n var scrollParents = [].concat(state.scrollParents.reference, state.scrollParents.popper);\n\n if (scroll) {\n scrollParents.forEach(function (scrollParent) {\n scrollParent.addEventListener('scroll', instance.update, passive);\n });\n }\n\n if (resize) {\n window.addEventListener('resize', instance.update, passive);\n }\n\n return function () {\n if (scroll) {\n scrollParents.forEach(function (scrollParent) {\n scrollParent.removeEventListener('scroll', instance.update, passive);\n });\n }\n\n if (resize) {\n window.removeEventListener('resize', instance.update, passive);\n }\n };\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'eventListeners',\n enabled: true,\n phase: 'write',\n fn: function fn() {},\n effect: effect,\n data: {}\n};","var hash = {\n left: 'right',\n right: 'left',\n bottom: 'top',\n top: 'bottom'\n};\nexport default function getOppositePlacement(placement) {\n return placement.replace(/left|right|bottom|top/g, function (matched) {\n return hash[matched];\n });\n}","var hash = {\n start: 'end',\n end: 'start'\n};\nexport default function getOppositeVariationPlacement(placement) {\n return placement.replace(/start|end/g, function (matched) {\n return hash[matched];\n });\n}","import getWindow from \"./getWindow.js\";\nexport default function getWindowScroll(node) {\n var win = getWindow(node);\n var scrollLeft = win.pageXOffset;\n var scrollTop = win.pageYOffset;\n return {\n scrollLeft: scrollLeft,\n scrollTop: scrollTop\n };\n}","import getBoundingClientRect from \"./getBoundingClientRect.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport getWindowScroll from \"./getWindowScroll.js\";\nexport default function getWindowScrollBarX(element) {\n // If has a CSS width greater than the viewport, then this will be\n // incorrect for RTL.\n // Popper 1 is broken in this case and never had a bug report so let's assume\n // it's not an issue. I don't think anyone ever specifies width on \n // anyway.\n // Browsers where the left scrollbar doesn't cause an issue report `0` for\n // this (e.g. Edge 2019, IE11, Safari)\n return getBoundingClientRect(getDocumentElement(element)).left + getWindowScroll(element).scrollLeft;\n}","import getWindow from \"./getWindow.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport getWindowScrollBarX from \"./getWindowScrollBarX.js\";\nimport isLayoutViewport from \"./isLayoutViewport.js\";\nexport default function getViewportRect(element, strategy) {\n var win = getWindow(element);\n var html = getDocumentElement(element);\n var visualViewport = win.visualViewport;\n var width = html.clientWidth;\n var height = html.clientHeight;\n var x = 0;\n var y = 0;\n\n if (visualViewport) {\n width = visualViewport.width;\n height = visualViewport.height;\n var layoutViewport = isLayoutViewport();\n\n if (layoutViewport || !layoutViewport && strategy === 'fixed') {\n x = visualViewport.offsetLeft;\n y = visualViewport.offsetTop;\n }\n }\n\n return {\n width: width,\n height: height,\n x: x + getWindowScrollBarX(element),\n y: y\n };\n}","import getDocumentElement from \"./getDocumentElement.js\";\nimport getComputedStyle from \"./getComputedStyle.js\";\nimport getWindowScrollBarX from \"./getWindowScrollBarX.js\";\nimport getWindowScroll from \"./getWindowScroll.js\";\nimport { max } from \"../utils/math.js\"; // Gets the entire size of the scrollable document area, even extending outside\n// of the `` and `` rect bounds if horizontally scrollable\n\nexport default function getDocumentRect(element) {\n var _element$ownerDocumen;\n\n var html = getDocumentElement(element);\n var winScroll = getWindowScroll(element);\n var body = (_element$ownerDocumen = element.ownerDocument) == null ? void 0 : _element$ownerDocumen.body;\n var width = max(html.scrollWidth, html.clientWidth, body ? body.scrollWidth : 0, body ? body.clientWidth : 0);\n var height = max(html.scrollHeight, html.clientHeight, body ? body.scrollHeight : 0, body ? body.clientHeight : 0);\n var x = -winScroll.scrollLeft + getWindowScrollBarX(element);\n var y = -winScroll.scrollTop;\n\n if (getComputedStyle(body || html).direction === 'rtl') {\n x += max(html.clientWidth, body ? body.clientWidth : 0) - width;\n }\n\n return {\n width: width,\n height: height,\n x: x,\n y: y\n };\n}","import getComputedStyle from \"./getComputedStyle.js\";\nexport default function isScrollParent(element) {\n // Firefox wants us to check `-x` and `-y` variations as well\n var _getComputedStyle = getComputedStyle(element),\n overflow = _getComputedStyle.overflow,\n overflowX = _getComputedStyle.overflowX,\n overflowY = _getComputedStyle.overflowY;\n\n return /auto|scroll|overlay|hidden/.test(overflow + overflowY + overflowX);\n}","import getParentNode from \"./getParentNode.js\";\nimport isScrollParent from \"./isScrollParent.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport { isHTMLElement } from \"./instanceOf.js\";\nexport default function getScrollParent(node) {\n if (['html', 'body', '#document'].indexOf(getNodeName(node)) >= 0) {\n // $FlowFixMe[incompatible-return]: assume body is always available\n return node.ownerDocument.body;\n }\n\n if (isHTMLElement(node) && isScrollParent(node)) {\n return node;\n }\n\n return getScrollParent(getParentNode(node));\n}","import getScrollParent from \"./getScrollParent.js\";\nimport getParentNode from \"./getParentNode.js\";\nimport getWindow from \"./getWindow.js\";\nimport isScrollParent from \"./isScrollParent.js\";\n/*\ngiven a DOM element, return the list of all scroll parents, up the list of ancesors\nuntil we get to the top window object. This list is what we attach scroll listeners\nto, because if any of these parent elements scroll, we'll need to re-calculate the\nreference element's position.\n*/\n\nexport default function listScrollParents(element, list) {\n var _element$ownerDocumen;\n\n if (list === void 0) {\n list = [];\n }\n\n var scrollParent = getScrollParent(element);\n var isBody = scrollParent === ((_element$ownerDocumen = element.ownerDocument) == null ? void 0 : _element$ownerDocumen.body);\n var win = getWindow(scrollParent);\n var target = isBody ? [win].concat(win.visualViewport || [], isScrollParent(scrollParent) ? scrollParent : []) : scrollParent;\n var updatedList = list.concat(target);\n return isBody ? updatedList : // $FlowFixMe[incompatible-call]: isBody tells us target will be an HTMLElement here\n updatedList.concat(listScrollParents(getParentNode(target)));\n}","export default function rectToClientRect(rect) {\n return Object.assign({}, rect, {\n left: rect.x,\n top: rect.y,\n right: rect.x + rect.width,\n bottom: rect.y + rect.height\n });\n}","import { viewport } from \"../enums.js\";\nimport getViewportRect from \"./getViewportRect.js\";\nimport getDocumentRect from \"./getDocumentRect.js\";\nimport listScrollParents from \"./listScrollParents.js\";\nimport getOffsetParent from \"./getOffsetParent.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport getComputedStyle from \"./getComputedStyle.js\";\nimport { isElement, isHTMLElement } from \"./instanceOf.js\";\nimport getBoundingClientRect from \"./getBoundingClientRect.js\";\nimport getParentNode from \"./getParentNode.js\";\nimport contains from \"./contains.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport rectToClientRect from \"../utils/rectToClientRect.js\";\nimport { max, min } from \"../utils/math.js\";\n\nfunction getInnerBoundingClientRect(element, strategy) {\n var rect = getBoundingClientRect(element, false, strategy === 'fixed');\n rect.top = rect.top + element.clientTop;\n rect.left = rect.left + element.clientLeft;\n rect.bottom = rect.top + element.clientHeight;\n rect.right = rect.left + element.clientWidth;\n rect.width = element.clientWidth;\n rect.height = element.clientHeight;\n rect.x = rect.left;\n rect.y = rect.top;\n return rect;\n}\n\nfunction getClientRectFromMixedType(element, clippingParent, strategy) {\n return clippingParent === viewport ? rectToClientRect(getViewportRect(element, strategy)) : isElement(clippingParent) ? getInnerBoundingClientRect(clippingParent, strategy) : rectToClientRect(getDocumentRect(getDocumentElement(element)));\n} // A \"clipping parent\" is an overflowable container with the characteristic of\n// clipping (or hiding) overflowing elements with a position different from\n// `initial`\n\n\nfunction getClippingParents(element) {\n var clippingParents = listScrollParents(getParentNode(element));\n var canEscapeClipping = ['absolute', 'fixed'].indexOf(getComputedStyle(element).position) >= 0;\n var clipperElement = canEscapeClipping && isHTMLElement(element) ? getOffsetParent(element) : element;\n\n if (!isElement(clipperElement)) {\n return [];\n } // $FlowFixMe[incompatible-return]: https://github.com/facebook/flow/issues/1414\n\n\n return clippingParents.filter(function (clippingParent) {\n return isElement(clippingParent) && contains(clippingParent, clipperElement) && getNodeName(clippingParent) !== 'body';\n });\n} // Gets the maximum area that the element is visible in due to any number of\n// clipping parents\n\n\nexport default function getClippingRect(element, boundary, rootBoundary, strategy) {\n var mainClippingParents = boundary === 'clippingParents' ? getClippingParents(element) : [].concat(boundary);\n var clippingParents = [].concat(mainClippingParents, [rootBoundary]);\n var firstClippingParent = clippingParents[0];\n var clippingRect = clippingParents.reduce(function (accRect, clippingParent) {\n var rect = getClientRectFromMixedType(element, clippingParent, strategy);\n accRect.top = max(rect.top, accRect.top);\n accRect.right = min(rect.right, accRect.right);\n accRect.bottom = min(rect.bottom, accRect.bottom);\n accRect.left = max(rect.left, accRect.left);\n return accRect;\n }, getClientRectFromMixedType(element, firstClippingParent, strategy));\n clippingRect.width = clippingRect.right - clippingRect.left;\n clippingRect.height = clippingRect.bottom - clippingRect.top;\n clippingRect.x = clippingRect.left;\n clippingRect.y = clippingRect.top;\n return clippingRect;\n}","import getBasePlacement from \"./getBasePlacement.js\";\nimport getVariation from \"./getVariation.js\";\nimport getMainAxisFromPlacement from \"./getMainAxisFromPlacement.js\";\nimport { top, right, bottom, left, start, end } from \"../enums.js\";\nexport default function computeOffsets(_ref) {\n var reference = _ref.reference,\n element = _ref.element,\n placement = _ref.placement;\n var basePlacement = placement ? getBasePlacement(placement) : null;\n var variation = placement ? getVariation(placement) : null;\n var commonX = reference.x + reference.width / 2 - element.width / 2;\n var commonY = reference.y + reference.height / 2 - element.height / 2;\n var offsets;\n\n switch (basePlacement) {\n case top:\n offsets = {\n x: commonX,\n y: reference.y - element.height\n };\n break;\n\n case bottom:\n offsets = {\n x: commonX,\n y: reference.y + reference.height\n };\n break;\n\n case right:\n offsets = {\n x: reference.x + reference.width,\n y: commonY\n };\n break;\n\n case left:\n offsets = {\n x: reference.x - element.width,\n y: commonY\n };\n break;\n\n default:\n offsets = {\n x: reference.x,\n y: reference.y\n };\n }\n\n var mainAxis = basePlacement ? getMainAxisFromPlacement(basePlacement) : null;\n\n if (mainAxis != null) {\n var len = mainAxis === 'y' ? 'height' : 'width';\n\n switch (variation) {\n case start:\n offsets[mainAxis] = offsets[mainAxis] - (reference[len] / 2 - element[len] / 2);\n break;\n\n case end:\n offsets[mainAxis] = offsets[mainAxis] + (reference[len] / 2 - element[len] / 2);\n break;\n\n default:\n }\n }\n\n return offsets;\n}","import getClippingRect from \"../dom-utils/getClippingRect.js\";\nimport getDocumentElement from \"../dom-utils/getDocumentElement.js\";\nimport getBoundingClientRect from \"../dom-utils/getBoundingClientRect.js\";\nimport computeOffsets from \"./computeOffsets.js\";\nimport rectToClientRect from \"./rectToClientRect.js\";\nimport { clippingParents, reference, popper, bottom, top, right, basePlacements, viewport } from \"../enums.js\";\nimport { isElement } from \"../dom-utils/instanceOf.js\";\nimport mergePaddingObject from \"./mergePaddingObject.js\";\nimport expandToHashMap from \"./expandToHashMap.js\"; // eslint-disable-next-line import/no-unused-modules\n\nexport default function detectOverflow(state, options) {\n if (options === void 0) {\n options = {};\n }\n\n var _options = options,\n _options$placement = _options.placement,\n placement = _options$placement === void 0 ? state.placement : _options$placement,\n _options$strategy = _options.strategy,\n strategy = _options$strategy === void 0 ? state.strategy : _options$strategy,\n _options$boundary = _options.boundary,\n boundary = _options$boundary === void 0 ? clippingParents : _options$boundary,\n _options$rootBoundary = _options.rootBoundary,\n rootBoundary = _options$rootBoundary === void 0 ? viewport : _options$rootBoundary,\n _options$elementConte = _options.elementContext,\n elementContext = _options$elementConte === void 0 ? popper : _options$elementConte,\n _options$altBoundary = _options.altBoundary,\n altBoundary = _options$altBoundary === void 0 ? false : _options$altBoundary,\n _options$padding = _options.padding,\n padding = _options$padding === void 0 ? 0 : _options$padding;\n var paddingObject = mergePaddingObject(typeof padding !== 'number' ? padding : expandToHashMap(padding, basePlacements));\n var altContext = elementContext === popper ? reference : popper;\n var popperRect = state.rects.popper;\n var element = state.elements[altBoundary ? altContext : elementContext];\n var clippingClientRect = getClippingRect(isElement(element) ? element : element.contextElement || getDocumentElement(state.elements.popper), boundary, rootBoundary, strategy);\n var referenceClientRect = getBoundingClientRect(state.elements.reference);\n var popperOffsets = computeOffsets({\n reference: referenceClientRect,\n element: popperRect,\n strategy: 'absolute',\n placement: placement\n });\n var popperClientRect = rectToClientRect(Object.assign({}, popperRect, popperOffsets));\n var elementClientRect = elementContext === popper ? popperClientRect : referenceClientRect; // positive = overflowing the clipping rect\n // 0 or negative = within the clipping rect\n\n var overflowOffsets = {\n top: clippingClientRect.top - elementClientRect.top + paddingObject.top,\n bottom: elementClientRect.bottom - clippingClientRect.bottom + paddingObject.bottom,\n left: clippingClientRect.left - elementClientRect.left + paddingObject.left,\n right: elementClientRect.right - clippingClientRect.right + paddingObject.right\n };\n var offsetData = state.modifiersData.offset; // Offsets can be applied only to the popper element\n\n if (elementContext === popper && offsetData) {\n var offset = offsetData[placement];\n Object.keys(overflowOffsets).forEach(function (key) {\n var multiply = [right, bottom].indexOf(key) >= 0 ? 1 : -1;\n var axis = [top, bottom].indexOf(key) >= 0 ? 'y' : 'x';\n overflowOffsets[key] += offset[axis] * multiply;\n });\n }\n\n return overflowOffsets;\n}","import getVariation from \"./getVariation.js\";\nimport { variationPlacements, basePlacements, placements as allPlacements } from \"../enums.js\";\nimport detectOverflow from \"./detectOverflow.js\";\nimport getBasePlacement from \"./getBasePlacement.js\";\nexport default function computeAutoPlacement(state, options) {\n if (options === void 0) {\n options = {};\n }\n\n var _options = options,\n placement = _options.placement,\n boundary = _options.boundary,\n rootBoundary = _options.rootBoundary,\n padding = _options.padding,\n flipVariations = _options.flipVariations,\n _options$allowedAutoP = _options.allowedAutoPlacements,\n allowedAutoPlacements = _options$allowedAutoP === void 0 ? allPlacements : _options$allowedAutoP;\n var variation = getVariation(placement);\n var placements = variation ? flipVariations ? variationPlacements : variationPlacements.filter(function (placement) {\n return getVariation(placement) === variation;\n }) : basePlacements;\n var allowedPlacements = placements.filter(function (placement) {\n return allowedAutoPlacements.indexOf(placement) >= 0;\n });\n\n if (allowedPlacements.length === 0) {\n allowedPlacements = placements;\n } // $FlowFixMe[incompatible-type]: Flow seems to have problems with two array unions...\n\n\n var overflows = allowedPlacements.reduce(function (acc, placement) {\n acc[placement] = detectOverflow(state, {\n placement: placement,\n boundary: boundary,\n rootBoundary: rootBoundary,\n padding: padding\n })[getBasePlacement(placement)];\n return acc;\n }, {});\n return Object.keys(overflows).sort(function (a, b) {\n return overflows[a] - overflows[b];\n });\n}","import getOppositePlacement from \"../utils/getOppositePlacement.js\";\nimport getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getOppositeVariationPlacement from \"../utils/getOppositeVariationPlacement.js\";\nimport detectOverflow from \"../utils/detectOverflow.js\";\nimport computeAutoPlacement from \"../utils/computeAutoPlacement.js\";\nimport { bottom, top, start, right, left, auto } from \"../enums.js\";\nimport getVariation from \"../utils/getVariation.js\"; // eslint-disable-next-line import/no-unused-modules\n\nfunction getExpandedFallbackPlacements(placement) {\n if (getBasePlacement(placement) === auto) {\n return [];\n }\n\n var oppositePlacement = getOppositePlacement(placement);\n return [getOppositeVariationPlacement(placement), oppositePlacement, getOppositeVariationPlacement(oppositePlacement)];\n}\n\nfunction flip(_ref) {\n var state = _ref.state,\n options = _ref.options,\n name = _ref.name;\n\n if (state.modifiersData[name]._skip) {\n return;\n }\n\n var _options$mainAxis = options.mainAxis,\n checkMainAxis = _options$mainAxis === void 0 ? true : _options$mainAxis,\n _options$altAxis = options.altAxis,\n checkAltAxis = _options$altAxis === void 0 ? true : _options$altAxis,\n specifiedFallbackPlacements = options.fallbackPlacements,\n padding = options.padding,\n boundary = options.boundary,\n rootBoundary = options.rootBoundary,\n altBoundary = options.altBoundary,\n _options$flipVariatio = options.flipVariations,\n flipVariations = _options$flipVariatio === void 0 ? true : _options$flipVariatio,\n allowedAutoPlacements = options.allowedAutoPlacements;\n var preferredPlacement = state.options.placement;\n var basePlacement = getBasePlacement(preferredPlacement);\n var isBasePlacement = basePlacement === preferredPlacement;\n var fallbackPlacements = specifiedFallbackPlacements || (isBasePlacement || !flipVariations ? [getOppositePlacement(preferredPlacement)] : getExpandedFallbackPlacements(preferredPlacement));\n var placements = [preferredPlacement].concat(fallbackPlacements).reduce(function (acc, placement) {\n return acc.concat(getBasePlacement(placement) === auto ? computeAutoPlacement(state, {\n placement: placement,\n boundary: boundary,\n rootBoundary: rootBoundary,\n padding: padding,\n flipVariations: flipVariations,\n allowedAutoPlacements: allowedAutoPlacements\n }) : placement);\n }, []);\n var referenceRect = state.rects.reference;\n var popperRect = state.rects.popper;\n var checksMap = new Map();\n var makeFallbackChecks = true;\n var firstFittingPlacement = placements[0];\n\n for (var i = 0; i < placements.length; i++) {\n var placement = placements[i];\n\n var _basePlacement = getBasePlacement(placement);\n\n var isStartVariation = getVariation(placement) === start;\n var isVertical = [top, bottom].indexOf(_basePlacement) >= 0;\n var len = isVertical ? 'width' : 'height';\n var overflow = detectOverflow(state, {\n placement: placement,\n boundary: boundary,\n rootBoundary: rootBoundary,\n altBoundary: altBoundary,\n padding: padding\n });\n var mainVariationSide = isVertical ? isStartVariation ? right : left : isStartVariation ? bottom : top;\n\n if (referenceRect[len] > popperRect[len]) {\n mainVariationSide = getOppositePlacement(mainVariationSide);\n }\n\n var altVariationSide = getOppositePlacement(mainVariationSide);\n var checks = [];\n\n if (checkMainAxis) {\n checks.push(overflow[_basePlacement] <= 0);\n }\n\n if (checkAltAxis) {\n checks.push(overflow[mainVariationSide] <= 0, overflow[altVariationSide] <= 0);\n }\n\n if (checks.every(function (check) {\n return check;\n })) {\n firstFittingPlacement = placement;\n makeFallbackChecks = false;\n break;\n }\n\n checksMap.set(placement, checks);\n }\n\n if (makeFallbackChecks) {\n // `2` may be desired in some cases – research later\n var numberOfChecks = flipVariations ? 3 : 1;\n\n var _loop = function _loop(_i) {\n var fittingPlacement = placements.find(function (placement) {\n var checks = checksMap.get(placement);\n\n if (checks) {\n return checks.slice(0, _i).every(function (check) {\n return check;\n });\n }\n });\n\n if (fittingPlacement) {\n firstFittingPlacement = fittingPlacement;\n return \"break\";\n }\n };\n\n for (var _i = numberOfChecks; _i > 0; _i--) {\n var _ret = _loop(_i);\n\n if (_ret === \"break\") break;\n }\n }\n\n if (state.placement !== firstFittingPlacement) {\n state.modifiersData[name]._skip = true;\n state.placement = firstFittingPlacement;\n state.reset = true;\n }\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'flip',\n enabled: true,\n phase: 'main',\n fn: flip,\n requiresIfExists: ['offset'],\n data: {\n _skip: false\n }\n};","import { top, bottom, left, right } from \"../enums.js\";\nimport detectOverflow from \"../utils/detectOverflow.js\";\n\nfunction getSideOffsets(overflow, rect, preventedOffsets) {\n if (preventedOffsets === void 0) {\n preventedOffsets = {\n x: 0,\n y: 0\n };\n }\n\n return {\n top: overflow.top - rect.height - preventedOffsets.y,\n right: overflow.right - rect.width + preventedOffsets.x,\n bottom: overflow.bottom - rect.height + preventedOffsets.y,\n left: overflow.left - rect.width - preventedOffsets.x\n };\n}\n\nfunction isAnySideFullyClipped(overflow) {\n return [top, right, bottom, left].some(function (side) {\n return overflow[side] >= 0;\n });\n}\n\nfunction hide(_ref) {\n var state = _ref.state,\n name = _ref.name;\n var referenceRect = state.rects.reference;\n var popperRect = state.rects.popper;\n var preventedOffsets = state.modifiersData.preventOverflow;\n var referenceOverflow = detectOverflow(state, {\n elementContext: 'reference'\n });\n var popperAltOverflow = detectOverflow(state, {\n altBoundary: true\n });\n var referenceClippingOffsets = getSideOffsets(referenceOverflow, referenceRect);\n var popperEscapeOffsets = getSideOffsets(popperAltOverflow, popperRect, preventedOffsets);\n var isReferenceHidden = isAnySideFullyClipped(referenceClippingOffsets);\n var hasPopperEscaped = isAnySideFullyClipped(popperEscapeOffsets);\n state.modifiersData[name] = {\n referenceClippingOffsets: referenceClippingOffsets,\n popperEscapeOffsets: popperEscapeOffsets,\n isReferenceHidden: isReferenceHidden,\n hasPopperEscaped: hasPopperEscaped\n };\n state.attributes.popper = Object.assign({}, state.attributes.popper, {\n 'data-popper-reference-hidden': isReferenceHidden,\n 'data-popper-escaped': hasPopperEscaped\n });\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'hide',\n enabled: true,\n phase: 'main',\n requiresIfExists: ['preventOverflow'],\n fn: hide\n};","import getBasePlacement from \"../utils/getBasePlacement.js\";\nimport { top, left, right, placements } from \"../enums.js\"; // eslint-disable-next-line import/no-unused-modules\n\nexport function distanceAndSkiddingToXY(placement, rects, offset) {\n var basePlacement = getBasePlacement(placement);\n var invertDistance = [left, top].indexOf(basePlacement) >= 0 ? -1 : 1;\n\n var _ref = typeof offset === 'function' ? offset(Object.assign({}, rects, {\n placement: placement\n })) : offset,\n skidding = _ref[0],\n distance = _ref[1];\n\n skidding = skidding || 0;\n distance = (distance || 0) * invertDistance;\n return [left, right].indexOf(basePlacement) >= 0 ? {\n x: distance,\n y: skidding\n } : {\n x: skidding,\n y: distance\n };\n}\n\nfunction offset(_ref2) {\n var state = _ref2.state,\n options = _ref2.options,\n name = _ref2.name;\n var _options$offset = options.offset,\n offset = _options$offset === void 0 ? [0, 0] : _options$offset;\n var data = placements.reduce(function (acc, placement) {\n acc[placement] = distanceAndSkiddingToXY(placement, state.rects, offset);\n return acc;\n }, {});\n var _data$state$placement = data[state.placement],\n x = _data$state$placement.x,\n y = _data$state$placement.y;\n\n if (state.modifiersData.popperOffsets != null) {\n state.modifiersData.popperOffsets.x += x;\n state.modifiersData.popperOffsets.y += y;\n }\n\n state.modifiersData[name] = data;\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'offset',\n enabled: true,\n phase: 'main',\n requires: ['popperOffsets'],\n fn: offset\n};","import computeOffsets from \"../utils/computeOffsets.js\";\n\nfunction popperOffsets(_ref) {\n var state = _ref.state,\n name = _ref.name;\n // Offsets are the actual position the popper needs to have to be\n // properly positioned near its reference element\n // This is the most basic placement, and will be adjusted by\n // the modifiers in the next step\n state.modifiersData[name] = computeOffsets({\n reference: state.rects.reference,\n element: state.rects.popper,\n strategy: 'absolute',\n placement: state.placement\n });\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'popperOffsets',\n enabled: true,\n phase: 'read',\n fn: popperOffsets,\n data: {}\n};","export default function getAltAxis(axis) {\n return axis === 'x' ? 'y' : 'x';\n}","import { top, left, right, bottom, start } from \"../enums.js\";\nimport getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getMainAxisFromPlacement from \"../utils/getMainAxisFromPlacement.js\";\nimport getAltAxis from \"../utils/getAltAxis.js\";\nimport { within, withinMaxClamp } from \"../utils/within.js\";\nimport getLayoutRect from \"../dom-utils/getLayoutRect.js\";\nimport getOffsetParent from \"../dom-utils/getOffsetParent.js\";\nimport detectOverflow from \"../utils/detectOverflow.js\";\nimport getVariation from \"../utils/getVariation.js\";\nimport getFreshSideObject from \"../utils/getFreshSideObject.js\";\nimport { min as mathMin, max as mathMax } from \"../utils/math.js\";\n\nfunction preventOverflow(_ref) {\n var state = _ref.state,\n options = _ref.options,\n name = _ref.name;\n var _options$mainAxis = options.mainAxis,\n checkMainAxis = _options$mainAxis === void 0 ? true : _options$mainAxis,\n _options$altAxis = options.altAxis,\n checkAltAxis = _options$altAxis === void 0 ? false : _options$altAxis,\n boundary = options.boundary,\n rootBoundary = options.rootBoundary,\n altBoundary = options.altBoundary,\n padding = options.padding,\n _options$tether = options.tether,\n tether = _options$tether === void 0 ? true : _options$tether,\n _options$tetherOffset = options.tetherOffset,\n tetherOffset = _options$tetherOffset === void 0 ? 0 : _options$tetherOffset;\n var overflow = detectOverflow(state, {\n boundary: boundary,\n rootBoundary: rootBoundary,\n padding: padding,\n altBoundary: altBoundary\n });\n var basePlacement = getBasePlacement(state.placement);\n var variation = getVariation(state.placement);\n var isBasePlacement = !variation;\n var mainAxis = getMainAxisFromPlacement(basePlacement);\n var altAxis = getAltAxis(mainAxis);\n var popperOffsets = state.modifiersData.popperOffsets;\n var referenceRect = state.rects.reference;\n var popperRect = state.rects.popper;\n var tetherOffsetValue = typeof tetherOffset === 'function' ? tetherOffset(Object.assign({}, state.rects, {\n placement: state.placement\n })) : tetherOffset;\n var normalizedTetherOffsetValue = typeof tetherOffsetValue === 'number' ? {\n mainAxis: tetherOffsetValue,\n altAxis: tetherOffsetValue\n } : Object.assign({\n mainAxis: 0,\n altAxis: 0\n }, tetherOffsetValue);\n var offsetModifierState = state.modifiersData.offset ? state.modifiersData.offset[state.placement] : null;\n var data = {\n x: 0,\n y: 0\n };\n\n if (!popperOffsets) {\n return;\n }\n\n if (checkMainAxis) {\n var _offsetModifierState$;\n\n var mainSide = mainAxis === 'y' ? top : left;\n var altSide = mainAxis === 'y' ? bottom : right;\n var len = mainAxis === 'y' ? 'height' : 'width';\n var offset = popperOffsets[mainAxis];\n var min = offset + overflow[mainSide];\n var max = offset - overflow[altSide];\n var additive = tether ? -popperRect[len] / 2 : 0;\n var minLen = variation === start ? referenceRect[len] : popperRect[len];\n var maxLen = variation === start ? -popperRect[len] : -referenceRect[len]; // We need to include the arrow in the calculation so the arrow doesn't go\n // outside the reference bounds\n\n var arrowElement = state.elements.arrow;\n var arrowRect = tether && arrowElement ? getLayoutRect(arrowElement) : {\n width: 0,\n height: 0\n };\n var arrowPaddingObject = state.modifiersData['arrow#persistent'] ? state.modifiersData['arrow#persistent'].padding : getFreshSideObject();\n var arrowPaddingMin = arrowPaddingObject[mainSide];\n var arrowPaddingMax = arrowPaddingObject[altSide]; // If the reference length is smaller than the arrow length, we don't want\n // to include its full size in the calculation. If the reference is small\n // and near the edge of a boundary, the popper can overflow even if the\n // reference is not overflowing as well (e.g. virtual elements with no\n // width or height)\n\n var arrowLen = within(0, referenceRect[len], arrowRect[len]);\n var minOffset = isBasePlacement ? referenceRect[len] / 2 - additive - arrowLen - arrowPaddingMin - normalizedTetherOffsetValue.mainAxis : minLen - arrowLen - arrowPaddingMin - normalizedTetherOffsetValue.mainAxis;\n var maxOffset = isBasePlacement ? -referenceRect[len] / 2 + additive + arrowLen + arrowPaddingMax + normalizedTetherOffsetValue.mainAxis : maxLen + arrowLen + arrowPaddingMax + normalizedTetherOffsetValue.mainAxis;\n var arrowOffsetParent = state.elements.arrow && getOffsetParent(state.elements.arrow);\n var clientOffset = arrowOffsetParent ? mainAxis === 'y' ? arrowOffsetParent.clientTop || 0 : arrowOffsetParent.clientLeft || 0 : 0;\n var offsetModifierValue = (_offsetModifierState$ = offsetModifierState == null ? void 0 : offsetModifierState[mainAxis]) != null ? _offsetModifierState$ : 0;\n var tetherMin = offset + minOffset - offsetModifierValue - clientOffset;\n var tetherMax = offset + maxOffset - offsetModifierValue;\n var preventedOffset = within(tether ? mathMin(min, tetherMin) : min, offset, tether ? mathMax(max, tetherMax) : max);\n popperOffsets[mainAxis] = preventedOffset;\n data[mainAxis] = preventedOffset - offset;\n }\n\n if (checkAltAxis) {\n var _offsetModifierState$2;\n\n var _mainSide = mainAxis === 'x' ? top : left;\n\n var _altSide = mainAxis === 'x' ? bottom : right;\n\n var _offset = popperOffsets[altAxis];\n\n var _len = altAxis === 'y' ? 'height' : 'width';\n\n var _min = _offset + overflow[_mainSide];\n\n var _max = _offset - overflow[_altSide];\n\n var isOriginSide = [top, left].indexOf(basePlacement) !== -1;\n\n var _offsetModifierValue = (_offsetModifierState$2 = offsetModifierState == null ? void 0 : offsetModifierState[altAxis]) != null ? _offsetModifierState$2 : 0;\n\n var _tetherMin = isOriginSide ? _min : _offset - referenceRect[_len] - popperRect[_len] - _offsetModifierValue + normalizedTetherOffsetValue.altAxis;\n\n var _tetherMax = isOriginSide ? _offset + referenceRect[_len] + popperRect[_len] - _offsetModifierValue - normalizedTetherOffsetValue.altAxis : _max;\n\n var _preventedOffset = tether && isOriginSide ? withinMaxClamp(_tetherMin, _offset, _tetherMax) : within(tether ? _tetherMin : _min, _offset, tether ? _tetherMax : _max);\n\n popperOffsets[altAxis] = _preventedOffset;\n data[altAxis] = _preventedOffset - _offset;\n }\n\n state.modifiersData[name] = data;\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'preventOverflow',\n enabled: true,\n phase: 'main',\n fn: preventOverflow,\n requiresIfExists: ['offset']\n};","export default function getHTMLElementScroll(element) {\n return {\n scrollLeft: element.scrollLeft,\n scrollTop: element.scrollTop\n };\n}","import getWindowScroll from \"./getWindowScroll.js\";\nimport getWindow from \"./getWindow.js\";\nimport { isHTMLElement } from \"./instanceOf.js\";\nimport getHTMLElementScroll from \"./getHTMLElementScroll.js\";\nexport default function getNodeScroll(node) {\n if (node === getWindow(node) || !isHTMLElement(node)) {\n return getWindowScroll(node);\n } else {\n return getHTMLElementScroll(node);\n }\n}","import getBoundingClientRect from \"./getBoundingClientRect.js\";\nimport getNodeScroll from \"./getNodeScroll.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport { isHTMLElement } from \"./instanceOf.js\";\nimport getWindowScrollBarX from \"./getWindowScrollBarX.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport isScrollParent from \"./isScrollParent.js\";\nimport { round } from \"../utils/math.js\";\n\nfunction isElementScaled(element) {\n var rect = element.getBoundingClientRect();\n var scaleX = round(rect.width) / element.offsetWidth || 1;\n var scaleY = round(rect.height) / element.offsetHeight || 1;\n return scaleX !== 1 || scaleY !== 1;\n} // Returns the composite rect of an element relative to its offsetParent.\n// Composite means it takes into account transforms as well as layout.\n\n\nexport default function getCompositeRect(elementOrVirtualElement, offsetParent, isFixed) {\n if (isFixed === void 0) {\n isFixed = false;\n }\n\n var isOffsetParentAnElement = isHTMLElement(offsetParent);\n var offsetParentIsScaled = isHTMLElement(offsetParent) && isElementScaled(offsetParent);\n var documentElement = getDocumentElement(offsetParent);\n var rect = getBoundingClientRect(elementOrVirtualElement, offsetParentIsScaled, isFixed);\n var scroll = {\n scrollLeft: 0,\n scrollTop: 0\n };\n var offsets = {\n x: 0,\n y: 0\n };\n\n if (isOffsetParentAnElement || !isOffsetParentAnElement && !isFixed) {\n if (getNodeName(offsetParent) !== 'body' || // https://github.com/popperjs/popper-core/issues/1078\n isScrollParent(documentElement)) {\n scroll = getNodeScroll(offsetParent);\n }\n\n if (isHTMLElement(offsetParent)) {\n offsets = getBoundingClientRect(offsetParent, true);\n offsets.x += offsetParent.clientLeft;\n offsets.y += offsetParent.clientTop;\n } else if (documentElement) {\n offsets.x = getWindowScrollBarX(documentElement);\n }\n }\n\n return {\n x: rect.left + scroll.scrollLeft - offsets.x,\n y: rect.top + scroll.scrollTop - offsets.y,\n width: rect.width,\n height: rect.height\n };\n}","import { modifierPhases } from \"../enums.js\"; // source: https://stackoverflow.com/questions/49875255\n\nfunction order(modifiers) {\n var map = new Map();\n var visited = new Set();\n var result = [];\n modifiers.forEach(function (modifier) {\n map.set(modifier.name, modifier);\n }); // On visiting object, check for its dependencies and visit them recursively\n\n function sort(modifier) {\n visited.add(modifier.name);\n var requires = [].concat(modifier.requires || [], modifier.requiresIfExists || []);\n requires.forEach(function (dep) {\n if (!visited.has(dep)) {\n var depModifier = map.get(dep);\n\n if (depModifier) {\n sort(depModifier);\n }\n }\n });\n result.push(modifier);\n }\n\n modifiers.forEach(function (modifier) {\n if (!visited.has(modifier.name)) {\n // check for visited object\n sort(modifier);\n }\n });\n return result;\n}\n\nexport default function orderModifiers(modifiers) {\n // order based on dependencies\n var orderedModifiers = order(modifiers); // order based on phase\n\n return modifierPhases.reduce(function (acc, phase) {\n return acc.concat(orderedModifiers.filter(function (modifier) {\n return modifier.phase === phase;\n }));\n }, []);\n}","export default function debounce(fn) {\n var pending;\n return function () {\n if (!pending) {\n pending = new Promise(function (resolve) {\n Promise.resolve().then(function () {\n pending = undefined;\n resolve(fn());\n });\n });\n }\n\n return pending;\n };\n}","export default function mergeByName(modifiers) {\n var merged = modifiers.reduce(function (merged, current) {\n var existing = merged[current.name];\n merged[current.name] = existing ? Object.assign({}, existing, current, {\n options: Object.assign({}, existing.options, current.options),\n data: Object.assign({}, existing.data, current.data)\n }) : current;\n return merged;\n }, {}); // IE11 does not support Object.values\n\n return Object.keys(merged).map(function (key) {\n return merged[key];\n });\n}","import getCompositeRect from \"./dom-utils/getCompositeRect.js\";\nimport getLayoutRect from \"./dom-utils/getLayoutRect.js\";\nimport listScrollParents from \"./dom-utils/listScrollParents.js\";\nimport getOffsetParent from \"./dom-utils/getOffsetParent.js\";\nimport orderModifiers from \"./utils/orderModifiers.js\";\nimport debounce from \"./utils/debounce.js\";\nimport mergeByName from \"./utils/mergeByName.js\";\nimport detectOverflow from \"./utils/detectOverflow.js\";\nimport { isElement } from \"./dom-utils/instanceOf.js\";\nvar DEFAULT_OPTIONS = {\n placement: 'bottom',\n modifiers: [],\n strategy: 'absolute'\n};\n\nfunction areValidElements() {\n for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {\n args[_key] = arguments[_key];\n }\n\n return !args.some(function (element) {\n return !(element && typeof element.getBoundingClientRect === 'function');\n });\n}\n\nexport function popperGenerator(generatorOptions) {\n if (generatorOptions === void 0) {\n generatorOptions = {};\n }\n\n var _generatorOptions = generatorOptions,\n _generatorOptions$def = _generatorOptions.defaultModifiers,\n defaultModifiers = _generatorOptions$def === void 0 ? [] : _generatorOptions$def,\n _generatorOptions$def2 = _generatorOptions.defaultOptions,\n defaultOptions = _generatorOptions$def2 === void 0 ? DEFAULT_OPTIONS : _generatorOptions$def2;\n return function createPopper(reference, popper, options) {\n if (options === void 0) {\n options = defaultOptions;\n }\n\n var state = {\n placement: 'bottom',\n orderedModifiers: [],\n options: Object.assign({}, DEFAULT_OPTIONS, defaultOptions),\n modifiersData: {},\n elements: {\n reference: reference,\n popper: popper\n },\n attributes: {},\n styles: {}\n };\n var effectCleanupFns = [];\n var isDestroyed = false;\n var instance = {\n state: state,\n setOptions: function setOptions(setOptionsAction) {\n var options = typeof setOptionsAction === 'function' ? setOptionsAction(state.options) : setOptionsAction;\n cleanupModifierEffects();\n state.options = Object.assign({}, defaultOptions, state.options, options);\n state.scrollParents = {\n reference: isElement(reference) ? listScrollParents(reference) : reference.contextElement ? listScrollParents(reference.contextElement) : [],\n popper: listScrollParents(popper)\n }; // Orders the modifiers based on their dependencies and `phase`\n // properties\n\n var orderedModifiers = orderModifiers(mergeByName([].concat(defaultModifiers, state.options.modifiers))); // Strip out disabled modifiers\n\n state.orderedModifiers = orderedModifiers.filter(function (m) {\n return m.enabled;\n });\n runModifierEffects();\n return instance.update();\n },\n // Sync update – it will always be executed, even if not necessary. This\n // is useful for low frequency updates where sync behavior simplifies the\n // logic.\n // For high frequency updates (e.g. `resize` and `scroll` events), always\n // prefer the async Popper#update method\n forceUpdate: function forceUpdate() {\n if (isDestroyed) {\n return;\n }\n\n var _state$elements = state.elements,\n reference = _state$elements.reference,\n popper = _state$elements.popper; // Don't proceed if `reference` or `popper` are not valid elements\n // anymore\n\n if (!areValidElements(reference, popper)) {\n return;\n } // Store the reference and popper rects to be read by modifiers\n\n\n state.rects = {\n reference: getCompositeRect(reference, getOffsetParent(popper), state.options.strategy === 'fixed'),\n popper: getLayoutRect(popper)\n }; // Modifiers have the ability to reset the current update cycle. The\n // most common use case for this is the `flip` modifier changing the\n // placement, which then needs to re-run all the modifiers, because the\n // logic was previously ran for the previous placement and is therefore\n // stale/incorrect\n\n state.reset = false;\n state.placement = state.options.placement; // On each update cycle, the `modifiersData` property for each modifier\n // is filled with the initial data specified by the modifier. This means\n // it doesn't persist and is fresh on each update.\n // To ensure persistent data, use `${name}#persistent`\n\n state.orderedModifiers.forEach(function (modifier) {\n return state.modifiersData[modifier.name] = Object.assign({}, modifier.data);\n });\n\n for (var index = 0; index < state.orderedModifiers.length; index++) {\n if (state.reset === true) {\n state.reset = false;\n index = -1;\n continue;\n }\n\n var _state$orderedModifie = state.orderedModifiers[index],\n fn = _state$orderedModifie.fn,\n _state$orderedModifie2 = _state$orderedModifie.options,\n _options = _state$orderedModifie2 === void 0 ? {} : _state$orderedModifie2,\n name = _state$orderedModifie.name;\n\n if (typeof fn === 'function') {\n state = fn({\n state: state,\n options: _options,\n name: name,\n instance: instance\n }) || state;\n }\n }\n },\n // Async and optimistically optimized update – it will not be executed if\n // not necessary (debounced to run at most once-per-tick)\n update: debounce(function () {\n return new Promise(function (resolve) {\n instance.forceUpdate();\n resolve(state);\n });\n }),\n destroy: function destroy() {\n cleanupModifierEffects();\n isDestroyed = true;\n }\n };\n\n if (!areValidElements(reference, popper)) {\n return instance;\n }\n\n instance.setOptions(options).then(function (state) {\n if (!isDestroyed && options.onFirstUpdate) {\n options.onFirstUpdate(state);\n }\n }); // Modifiers have the ability to execute arbitrary code before the first\n // update cycle runs. They will be executed in the same order as the update\n // cycle. This is useful when a modifier adds some persistent data that\n // other modifiers need to use, but the modifier is run after the dependent\n // one.\n\n function runModifierEffects() {\n state.orderedModifiers.forEach(function (_ref) {\n var name = _ref.name,\n _ref$options = _ref.options,\n options = _ref$options === void 0 ? {} : _ref$options,\n effect = _ref.effect;\n\n if (typeof effect === 'function') {\n var cleanupFn = effect({\n state: state,\n name: name,\n instance: instance,\n options: options\n });\n\n var noopFn = function noopFn() {};\n\n effectCleanupFns.push(cleanupFn || noopFn);\n }\n });\n }\n\n function cleanupModifierEffects() {\n effectCleanupFns.forEach(function (fn) {\n return fn();\n });\n effectCleanupFns = [];\n }\n\n return instance;\n };\n}\nexport var createPopper = /*#__PURE__*/popperGenerator(); // eslint-disable-next-line import/no-unused-modules\n\nexport { detectOverflow };","import { popperGenerator, detectOverflow } from \"./createPopper.js\";\nimport eventListeners from \"./modifiers/eventListeners.js\";\nimport popperOffsets from \"./modifiers/popperOffsets.js\";\nimport computeStyles from \"./modifiers/computeStyles.js\";\nimport applyStyles from \"./modifiers/applyStyles.js\";\nimport offset from \"./modifiers/offset.js\";\nimport flip from \"./modifiers/flip.js\";\nimport preventOverflow from \"./modifiers/preventOverflow.js\";\nimport arrow from \"./modifiers/arrow.js\";\nimport hide from \"./modifiers/hide.js\";\nvar defaultModifiers = [eventListeners, popperOffsets, computeStyles, applyStyles, offset, flip, preventOverflow, arrow, hide];\nvar createPopper = /*#__PURE__*/popperGenerator({\n defaultModifiers: defaultModifiers\n}); // eslint-disable-next-line import/no-unused-modules\n\nexport { createPopper, popperGenerator, defaultModifiers, detectOverflow }; // eslint-disable-next-line import/no-unused-modules\n\nexport { createPopper as createPopperLite } from \"./popper-lite.js\"; // eslint-disable-next-line import/no-unused-modules\n\nexport * from \"./modifiers/index.js\";","import { generateUtilityClass } from '../generateUtilityClass';\nimport { generateUtilityClasses } from '../generateUtilityClasses';\nconst COMPONENT_NAME = 'Popper';\nexport function getPopperUtilityClass(slot) {\n return generateUtilityClass(COMPONENT_NAME, slot);\n}\nexport const popperClasses = generateUtilityClasses(COMPONENT_NAME, ['root']);","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"anchorEl\", \"children\", \"direction\", \"disablePortal\", \"modifiers\", \"open\", \"placement\", \"popperOptions\", \"popperRef\", \"slotProps\", \"slots\", \"TransitionProps\", \"ownerState\"],\n _excluded2 = [\"anchorEl\", \"children\", \"container\", \"direction\", \"disablePortal\", \"keepMounted\", \"modifiers\", \"open\", \"placement\", \"popperOptions\", \"popperRef\", \"style\", \"transition\", \"slotProps\", \"slots\"];\nimport * as React from 'react';\nimport { chainPropTypes, HTMLElementType, refType, unstable_ownerDocument as ownerDocument, unstable_useEnhancedEffect as useEnhancedEffect, unstable_useForkRef as useForkRef } from '@mui/utils';\nimport { createPopper } from '@popperjs/core';\nimport PropTypes from 'prop-types';\nimport { unstable_composeClasses as composeClasses } from '../composeClasses';\nimport { Portal } from '../Portal';\nimport { getPopperUtilityClass } from './popperClasses';\nimport { useSlotProps } from '../utils';\nimport { useClassNamesOverride } from '../utils/ClassNameConfigurator';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nfunction flipPlacement(placement, direction) {\n if (direction === 'ltr') {\n return placement;\n }\n switch (placement) {\n case 'bottom-end':\n return 'bottom-start';\n case 'bottom-start':\n return 'bottom-end';\n case 'top-end':\n return 'top-start';\n case 'top-start':\n return 'top-end';\n default:\n return placement;\n }\n}\nfunction resolveAnchorEl(anchorEl) {\n return typeof anchorEl === 'function' ? anchorEl() : anchorEl;\n}\nfunction isHTMLElement(element) {\n return element.nodeType !== undefined;\n}\nfunction isVirtualElement(element) {\n return !isHTMLElement(element);\n}\nconst useUtilityClasses = () => {\n const slots = {\n root: ['root']\n };\n return composeClasses(slots, useClassNamesOverride(getPopperUtilityClass));\n};\nconst defaultPopperOptions = {};\nconst PopperTooltip = /*#__PURE__*/React.forwardRef(function PopperTooltip(props, forwardedRef) {\n var _slots$root;\n const {\n anchorEl,\n children,\n direction,\n disablePortal,\n modifiers,\n open,\n placement: initialPlacement,\n popperOptions,\n popperRef: popperRefProp,\n slotProps = {},\n slots = {},\n TransitionProps\n // @ts-ignore internal logic\n // prevent from spreading to DOM, it can come from the parent component e.g. Select.\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const tooltipRef = React.useRef(null);\n const ownRef = useForkRef(tooltipRef, forwardedRef);\n const popperRef = React.useRef(null);\n const handlePopperRef = useForkRef(popperRef, popperRefProp);\n const handlePopperRefRef = React.useRef(handlePopperRef);\n useEnhancedEffect(() => {\n handlePopperRefRef.current = handlePopperRef;\n }, [handlePopperRef]);\n React.useImperativeHandle(popperRefProp, () => popperRef.current, []);\n const rtlPlacement = flipPlacement(initialPlacement, direction);\n /**\n * placement initialized from prop but can change during lifetime if modifiers.flip.\n * modifiers.flip is essentially a flip for controlled/uncontrolled behavior\n */\n const [placement, setPlacement] = React.useState(rtlPlacement);\n const [resolvedAnchorElement, setResolvedAnchorElement] = React.useState(resolveAnchorEl(anchorEl));\n React.useEffect(() => {\n if (popperRef.current) {\n popperRef.current.forceUpdate();\n }\n });\n React.useEffect(() => {\n if (anchorEl) {\n setResolvedAnchorElement(resolveAnchorEl(anchorEl));\n }\n }, [anchorEl]);\n useEnhancedEffect(() => {\n if (!resolvedAnchorElement || !open) {\n return undefined;\n }\n const handlePopperUpdate = data => {\n setPlacement(data.placement);\n };\n if (process.env.NODE_ENV !== 'production') {\n if (resolvedAnchorElement && isHTMLElement(resolvedAnchorElement) && resolvedAnchorElement.nodeType === 1) {\n const box = resolvedAnchorElement.getBoundingClientRect();\n if (process.env.NODE_ENV !== 'test' && box.top === 0 && box.left === 0 && box.right === 0 && box.bottom === 0) {\n console.warn(['MUI: The `anchorEl` prop provided to the component is invalid.', 'The anchor element should be part of the document layout.', \"Make sure the element is present in the document or that it's not display none.\"].join('\\n'));\n }\n }\n }\n let popperModifiers = [{\n name: 'preventOverflow',\n options: {\n altBoundary: disablePortal\n }\n }, {\n name: 'flip',\n options: {\n altBoundary: disablePortal\n }\n }, {\n name: 'onUpdate',\n enabled: true,\n phase: 'afterWrite',\n fn: ({\n state\n }) => {\n handlePopperUpdate(state);\n }\n }];\n if (modifiers != null) {\n popperModifiers = popperModifiers.concat(modifiers);\n }\n if (popperOptions && popperOptions.modifiers != null) {\n popperModifiers = popperModifiers.concat(popperOptions.modifiers);\n }\n const popper = createPopper(resolvedAnchorElement, tooltipRef.current, _extends({\n placement: rtlPlacement\n }, popperOptions, {\n modifiers: popperModifiers\n }));\n handlePopperRefRef.current(popper);\n return () => {\n popper.destroy();\n handlePopperRefRef.current(null);\n };\n }, [resolvedAnchorElement, disablePortal, modifiers, open, popperOptions, rtlPlacement]);\n const childProps = {\n placement: placement\n };\n if (TransitionProps !== null) {\n childProps.TransitionProps = TransitionProps;\n }\n const classes = useUtilityClasses();\n const Root = (_slots$root = slots.root) != null ? _slots$root : 'div';\n const rootProps = useSlotProps({\n elementType: Root,\n externalSlotProps: slotProps.root,\n externalForwardedProps: other,\n additionalProps: {\n role: 'tooltip',\n ref: ownRef\n },\n ownerState: props,\n className: classes.root\n });\n return /*#__PURE__*/_jsx(Root, _extends({}, rootProps, {\n children: typeof children === 'function' ? children(childProps) : children\n }));\n});\n\n/**\n * Poppers rely on the 3rd party library [Popper.js](https://popper.js.org/docs/v2/) for positioning.\n *\n * Demos:\n *\n * - [Popper](https://mui.com/base-ui/react-popper/)\n *\n * API:\n *\n * - [Popper API](https://mui.com/base-ui/react-popper/components-api/#popper)\n */\nconst Popper = /*#__PURE__*/React.forwardRef(function Popper(props, forwardedRef) {\n const {\n anchorEl,\n children,\n container: containerProp,\n direction = 'ltr',\n disablePortal = false,\n keepMounted = false,\n modifiers,\n open,\n placement = 'bottom',\n popperOptions = defaultPopperOptions,\n popperRef,\n style,\n transition = false,\n slotProps = {},\n slots = {}\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded2);\n const [exited, setExited] = React.useState(true);\n const handleEnter = () => {\n setExited(false);\n };\n const handleExited = () => {\n setExited(true);\n };\n if (!keepMounted && !open && (!transition || exited)) {\n return null;\n }\n\n // If the container prop is provided, use that\n // If the anchorEl prop is provided, use its parent body element as the container\n // If neither are provided let the Modal take care of choosing the container\n let container;\n if (containerProp) {\n container = containerProp;\n } else if (anchorEl) {\n const resolvedAnchorEl = resolveAnchorEl(anchorEl);\n container = resolvedAnchorEl && isHTMLElement(resolvedAnchorEl) ? ownerDocument(resolvedAnchorEl).body : ownerDocument(null).body;\n }\n const display = !open && keepMounted && (!transition || exited) ? 'none' : undefined;\n const transitionProps = transition ? {\n in: open,\n onEnter: handleEnter,\n onExited: handleExited\n } : undefined;\n return /*#__PURE__*/_jsx(Portal, {\n disablePortal: disablePortal,\n container: container,\n children: /*#__PURE__*/_jsx(PopperTooltip, _extends({\n anchorEl: anchorEl,\n direction: direction,\n disablePortal: disablePortal,\n modifiers: modifiers,\n ref: forwardedRef,\n open: transition ? !exited : open,\n placement: placement,\n popperOptions: popperOptions,\n popperRef: popperRef,\n slotProps: slotProps,\n slots: slots\n }, other, {\n style: _extends({\n // Prevents scroll issue, waiting for Popper.js to add this style once initiated.\n position: 'fixed',\n // Fix Popper.js display issue\n top: 0,\n left: 0,\n display\n }, style),\n TransitionProps: transitionProps,\n children: children\n }))\n });\n});\nprocess.env.NODE_ENV !== \"production\" ? Popper.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * An HTML element, [virtualElement](https://popper.js.org/docs/v2/virtual-elements/),\n * or a function that returns either.\n * It's used to set the position of the popper.\n * The return value will passed as the reference object of the Popper instance.\n */\n anchorEl: chainPropTypes(PropTypes.oneOfType([HTMLElementType, PropTypes.object, PropTypes.func]), props => {\n if (props.open) {\n const resolvedAnchorEl = resolveAnchorEl(props.anchorEl);\n if (resolvedAnchorEl && isHTMLElement(resolvedAnchorEl) && resolvedAnchorEl.nodeType === 1) {\n const box = resolvedAnchorEl.getBoundingClientRect();\n if (process.env.NODE_ENV !== 'test' && box.top === 0 && box.left === 0 && box.right === 0 && box.bottom === 0) {\n return new Error(['MUI: The `anchorEl` prop provided to the component is invalid.', 'The anchor element should be part of the document layout.', \"Make sure the element is present in the document or that it's not display none.\"].join('\\n'));\n }\n } else if (!resolvedAnchorEl || typeof resolvedAnchorEl.getBoundingClientRect !== 'function' || isVirtualElement(resolvedAnchorEl) && resolvedAnchorEl.contextElement != null && resolvedAnchorEl.contextElement.nodeType !== 1) {\n return new Error(['MUI: The `anchorEl` prop provided to the component is invalid.', 'It should be an HTML element instance or a virtualElement ', '(https://popper.js.org/docs/v2/virtual-elements/).'].join('\\n'));\n }\n }\n return null;\n }),\n /**\n * Popper render function or node.\n */\n children: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.node, PropTypes.func]),\n /**\n * An HTML element or function that returns one.\n * The `container` will have the portal children appended to it.\n *\n * You can also provide a callback, which is called in a React layout effect.\n * This lets you set the container from a ref, and also makes server-side rendering possible.\n *\n * By default, it uses the body of the top-level document object,\n * so it's simply `document.body` most of the time.\n */\n container: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.func]),\n /**\n * Direction of the text.\n * @default 'ltr'\n */\n direction: PropTypes.oneOf(['ltr', 'rtl']),\n /**\n * The `children` will be under the DOM hierarchy of the parent component.\n * @default false\n */\n disablePortal: PropTypes.bool,\n /**\n * Always keep the children in the DOM.\n * This prop can be useful in SEO situation or\n * when you want to maximize the responsiveness of the Popper.\n * @default false\n */\n keepMounted: PropTypes.bool,\n /**\n * Popper.js is based on a \"plugin-like\" architecture,\n * most of its features are fully encapsulated \"modifiers\".\n *\n * A modifier is a function that is called each time Popper.js needs to\n * compute the position of the popper.\n * For this reason, modifiers should be very performant to avoid bottlenecks.\n * To learn how to create a modifier, [read the modifiers documentation](https://popper.js.org/docs/v2/modifiers/).\n */\n modifiers: PropTypes.arrayOf(PropTypes.shape({\n data: PropTypes.object,\n effect: PropTypes.func,\n enabled: PropTypes.bool,\n fn: PropTypes.func,\n name: PropTypes.any,\n options: PropTypes.object,\n phase: PropTypes.oneOf(['afterMain', 'afterRead', 'afterWrite', 'beforeMain', 'beforeRead', 'beforeWrite', 'main', 'read', 'write']),\n requires: PropTypes.arrayOf(PropTypes.string),\n requiresIfExists: PropTypes.arrayOf(PropTypes.string)\n })),\n /**\n * If `true`, the component is shown.\n */\n open: PropTypes.bool.isRequired,\n /**\n * Popper placement.\n * @default 'bottom'\n */\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n /**\n * Options provided to the [`Popper.js`](https://popper.js.org/docs/v2/constructors/#options) instance.\n * @default {}\n */\n popperOptions: PropTypes.shape({\n modifiers: PropTypes.array,\n onFirstUpdate: PropTypes.func,\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n strategy: PropTypes.oneOf(['absolute', 'fixed'])\n }),\n /**\n * A ref that points to the used popper instance.\n */\n popperRef: refType,\n /**\n * The props used for each slot inside the Popper.\n * @default {}\n */\n slotProps: PropTypes.shape({\n root: PropTypes.oneOfType([PropTypes.func, PropTypes.object])\n }),\n /**\n * The components used for each slot inside the Popper.\n * Either a string to use a HTML element or a component.\n * @default {}\n */\n slots: PropTypes.shape({\n root: PropTypes.elementType\n }),\n /**\n * Help supporting a react-transition-group/Transition component.\n * @default false\n */\n transition: PropTypes.bool\n} : void 0;\nexport { Popper };","'use client';\n\nimport * as React from 'react';\nimport { useTheme as useThemeSystem } from '@mui/system';\nimport defaultTheme from './defaultTheme';\nimport THEME_ID from './identifier';\nexport default function useTheme() {\n const theme = useThemeSystem(defaultTheme);\n if (process.env.NODE_ENV !== 'production') {\n // eslint-disable-next-line react-hooks/rules-of-hooks\n React.useDebugValue(theme);\n }\n return theme[THEME_ID] || theme;\n}","export default function _setPrototypeOf(o, p) {\n _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function _setPrototypeOf(o, p) {\n o.__proto__ = p;\n return o;\n };\n return _setPrototypeOf(o, p);\n}","import setPrototypeOf from \"./setPrototypeOf.js\";\nexport default function _inheritsLoose(subClass, superClass) {\n subClass.prototype = Object.create(superClass.prototype);\n subClass.prototype.constructor = subClass;\n setPrototypeOf(subClass, superClass);\n}","export default {\n disabled: false\n};","import PropTypes from 'prop-types';\nexport var timeoutsShape = process.env.NODE_ENV !== 'production' ? PropTypes.oneOfType([PropTypes.number, PropTypes.shape({\n enter: PropTypes.number,\n exit: PropTypes.number,\n appear: PropTypes.number\n}).isRequired]) : null;\nexport var classNamesShape = process.env.NODE_ENV !== 'production' ? PropTypes.oneOfType([PropTypes.string, PropTypes.shape({\n enter: PropTypes.string,\n exit: PropTypes.string,\n active: PropTypes.string\n}), PropTypes.shape({\n enter: PropTypes.string,\n enterDone: PropTypes.string,\n enterActive: PropTypes.string,\n exit: PropTypes.string,\n exitDone: PropTypes.string,\n exitActive: PropTypes.string\n})]) : null;","import React from 'react';\nexport default React.createContext(null);","export var forceReflow = function forceReflow(node) {\n return node.scrollTop;\n};","import _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _inheritsLoose from \"@babel/runtime/helpers/esm/inheritsLoose\";\nimport PropTypes from 'prop-types';\nimport React from 'react';\nimport ReactDOM from 'react-dom';\nimport config from './config';\nimport { timeoutsShape } from './utils/PropTypes';\nimport TransitionGroupContext from './TransitionGroupContext';\nimport { forceReflow } from './utils/reflow';\nexport var UNMOUNTED = 'unmounted';\nexport var EXITED = 'exited';\nexport var ENTERING = 'entering';\nexport var ENTERED = 'entered';\nexport var EXITING = 'exiting';\n/**\n * The Transition component lets you describe a transition from one component\n * state to another _over time_ with a simple declarative API. Most commonly\n * it's used to animate the mounting and unmounting of a component, but can also\n * be used to describe in-place transition states as well.\n *\n * ---\n *\n * **Note**: `Transition` is a platform-agnostic base component. If you're using\n * transitions in CSS, you'll probably want to use\n * [`CSSTransition`](https://reactcommunity.org/react-transition-group/css-transition)\n * instead. It inherits all the features of `Transition`, but contains\n * additional features necessary to play nice with CSS transitions (hence the\n * name of the component).\n *\n * ---\n *\n * By default the `Transition` component does not alter the behavior of the\n * component it renders, it only tracks \"enter\" and \"exit\" states for the\n * components. It's up to you to give meaning and effect to those states. For\n * example we can add styles to a component when it enters or exits:\n *\n * ```jsx\n * import { Transition } from 'react-transition-group';\n *\n * const duration = 300;\n *\n * const defaultStyle = {\n * transition: `opacity ${duration}ms ease-in-out`,\n * opacity: 0,\n * }\n *\n * const transitionStyles = {\n * entering: { opacity: 1 },\n * entered: { opacity: 1 },\n * exiting: { opacity: 0 },\n * exited: { opacity: 0 },\n * };\n *\n * const Fade = ({ in: inProp }) => (\n * \n * {state => (\n *
    \n * I'm a fade Transition!\n *
    \n * )}\n *
    \n * );\n * ```\n *\n * There are 4 main states a Transition can be in:\n * - `'entering'`\n * - `'entered'`\n * - `'exiting'`\n * - `'exited'`\n *\n * Transition state is toggled via the `in` prop. When `true` the component\n * begins the \"Enter\" stage. During this stage, the component will shift from\n * its current transition state, to `'entering'` for the duration of the\n * transition and then to the `'entered'` stage once it's complete. Let's take\n * the following example (we'll use the\n * [useState](https://reactjs.org/docs/hooks-reference.html#usestate) hook):\n *\n * ```jsx\n * function App() {\n * const [inProp, setInProp] = useState(false);\n * return (\n *
    \n * \n * {state => (\n * // ...\n * )}\n * \n * \n *
    \n * );\n * }\n * ```\n *\n * When the button is clicked the component will shift to the `'entering'` state\n * and stay there for 500ms (the value of `timeout`) before it finally switches\n * to `'entered'`.\n *\n * When `in` is `false` the same thing happens except the state moves from\n * `'exiting'` to `'exited'`.\n */\n\nvar Transition = /*#__PURE__*/function (_React$Component) {\n _inheritsLoose(Transition, _React$Component);\n\n function Transition(props, context) {\n var _this;\n\n _this = _React$Component.call(this, props, context) || this;\n var parentGroup = context; // In the context of a TransitionGroup all enters are really appears\n\n var appear = parentGroup && !parentGroup.isMounting ? props.enter : props.appear;\n var initialStatus;\n _this.appearStatus = null;\n\n if (props.in) {\n if (appear) {\n initialStatus = EXITED;\n _this.appearStatus = ENTERING;\n } else {\n initialStatus = ENTERED;\n }\n } else {\n if (props.unmountOnExit || props.mountOnEnter) {\n initialStatus = UNMOUNTED;\n } else {\n initialStatus = EXITED;\n }\n }\n\n _this.state = {\n status: initialStatus\n };\n _this.nextCallback = null;\n return _this;\n }\n\n Transition.getDerivedStateFromProps = function getDerivedStateFromProps(_ref, prevState) {\n var nextIn = _ref.in;\n\n if (nextIn && prevState.status === UNMOUNTED) {\n return {\n status: EXITED\n };\n }\n\n return null;\n } // getSnapshotBeforeUpdate(prevProps) {\n // let nextStatus = null\n // if (prevProps !== this.props) {\n // const { status } = this.state\n // if (this.props.in) {\n // if (status !== ENTERING && status !== ENTERED) {\n // nextStatus = ENTERING\n // }\n // } else {\n // if (status === ENTERING || status === ENTERED) {\n // nextStatus = EXITING\n // }\n // }\n // }\n // return { nextStatus }\n // }\n ;\n\n var _proto = Transition.prototype;\n\n _proto.componentDidMount = function componentDidMount() {\n this.updateStatus(true, this.appearStatus);\n };\n\n _proto.componentDidUpdate = function componentDidUpdate(prevProps) {\n var nextStatus = null;\n\n if (prevProps !== this.props) {\n var status = this.state.status;\n\n if (this.props.in) {\n if (status !== ENTERING && status !== ENTERED) {\n nextStatus = ENTERING;\n }\n } else {\n if (status === ENTERING || status === ENTERED) {\n nextStatus = EXITING;\n }\n }\n }\n\n this.updateStatus(false, nextStatus);\n };\n\n _proto.componentWillUnmount = function componentWillUnmount() {\n this.cancelNextCallback();\n };\n\n _proto.getTimeouts = function getTimeouts() {\n var timeout = this.props.timeout;\n var exit, enter, appear;\n exit = enter = appear = timeout;\n\n if (timeout != null && typeof timeout !== 'number') {\n exit = timeout.exit;\n enter = timeout.enter; // TODO: remove fallback for next major\n\n appear = timeout.appear !== undefined ? timeout.appear : enter;\n }\n\n return {\n exit: exit,\n enter: enter,\n appear: appear\n };\n };\n\n _proto.updateStatus = function updateStatus(mounting, nextStatus) {\n if (mounting === void 0) {\n mounting = false;\n }\n\n if (nextStatus !== null) {\n // nextStatus will always be ENTERING or EXITING.\n this.cancelNextCallback();\n\n if (nextStatus === ENTERING) {\n if (this.props.unmountOnExit || this.props.mountOnEnter) {\n var node = this.props.nodeRef ? this.props.nodeRef.current : ReactDOM.findDOMNode(this); // https://github.com/reactjs/react-transition-group/pull/749\n // With unmountOnExit or mountOnEnter, the enter animation should happen at the transition between `exited` and `entering`.\n // To make the animation happen, we have to separate each rendering and avoid being processed as batched.\n\n if (node) forceReflow(node);\n }\n\n this.performEnter(mounting);\n } else {\n this.performExit();\n }\n } else if (this.props.unmountOnExit && this.state.status === EXITED) {\n this.setState({\n status: UNMOUNTED\n });\n }\n };\n\n _proto.performEnter = function performEnter(mounting) {\n var _this2 = this;\n\n var enter = this.props.enter;\n var appearing = this.context ? this.context.isMounting : mounting;\n\n var _ref2 = this.props.nodeRef ? [appearing] : [ReactDOM.findDOMNode(this), appearing],\n maybeNode = _ref2[0],\n maybeAppearing = _ref2[1];\n\n var timeouts = this.getTimeouts();\n var enterTimeout = appearing ? timeouts.appear : timeouts.enter; // no enter animation skip right to ENTERED\n // if we are mounting and running this it means appear _must_ be set\n\n if (!mounting && !enter || config.disabled) {\n this.safeSetState({\n status: ENTERED\n }, function () {\n _this2.props.onEntered(maybeNode);\n });\n return;\n }\n\n this.props.onEnter(maybeNode, maybeAppearing);\n this.safeSetState({\n status: ENTERING\n }, function () {\n _this2.props.onEntering(maybeNode, maybeAppearing);\n\n _this2.onTransitionEnd(enterTimeout, function () {\n _this2.safeSetState({\n status: ENTERED\n }, function () {\n _this2.props.onEntered(maybeNode, maybeAppearing);\n });\n });\n });\n };\n\n _proto.performExit = function performExit() {\n var _this3 = this;\n\n var exit = this.props.exit;\n var timeouts = this.getTimeouts();\n var maybeNode = this.props.nodeRef ? undefined : ReactDOM.findDOMNode(this); // no exit animation skip right to EXITED\n\n if (!exit || config.disabled) {\n this.safeSetState({\n status: EXITED\n }, function () {\n _this3.props.onExited(maybeNode);\n });\n return;\n }\n\n this.props.onExit(maybeNode);\n this.safeSetState({\n status: EXITING\n }, function () {\n _this3.props.onExiting(maybeNode);\n\n _this3.onTransitionEnd(timeouts.exit, function () {\n _this3.safeSetState({\n status: EXITED\n }, function () {\n _this3.props.onExited(maybeNode);\n });\n });\n });\n };\n\n _proto.cancelNextCallback = function cancelNextCallback() {\n if (this.nextCallback !== null) {\n this.nextCallback.cancel();\n this.nextCallback = null;\n }\n };\n\n _proto.safeSetState = function safeSetState(nextState, callback) {\n // This shouldn't be necessary, but there are weird race conditions with\n // setState callbacks and unmounting in testing, so always make sure that\n // we can cancel any pending setState callbacks after we unmount.\n callback = this.setNextCallback(callback);\n this.setState(nextState, callback);\n };\n\n _proto.setNextCallback = function setNextCallback(callback) {\n var _this4 = this;\n\n var active = true;\n\n this.nextCallback = function (event) {\n if (active) {\n active = false;\n _this4.nextCallback = null;\n callback(event);\n }\n };\n\n this.nextCallback.cancel = function () {\n active = false;\n };\n\n return this.nextCallback;\n };\n\n _proto.onTransitionEnd = function onTransitionEnd(timeout, handler) {\n this.setNextCallback(handler);\n var node = this.props.nodeRef ? this.props.nodeRef.current : ReactDOM.findDOMNode(this);\n var doesNotHaveTimeoutOrListener = timeout == null && !this.props.addEndListener;\n\n if (!node || doesNotHaveTimeoutOrListener) {\n setTimeout(this.nextCallback, 0);\n return;\n }\n\n if (this.props.addEndListener) {\n var _ref3 = this.props.nodeRef ? [this.nextCallback] : [node, this.nextCallback],\n maybeNode = _ref3[0],\n maybeNextCallback = _ref3[1];\n\n this.props.addEndListener(maybeNode, maybeNextCallback);\n }\n\n if (timeout != null) {\n setTimeout(this.nextCallback, timeout);\n }\n };\n\n _proto.render = function render() {\n var status = this.state.status;\n\n if (status === UNMOUNTED) {\n return null;\n }\n\n var _this$props = this.props,\n children = _this$props.children,\n _in = _this$props.in,\n _mountOnEnter = _this$props.mountOnEnter,\n _unmountOnExit = _this$props.unmountOnExit,\n _appear = _this$props.appear,\n _enter = _this$props.enter,\n _exit = _this$props.exit,\n _timeout = _this$props.timeout,\n _addEndListener = _this$props.addEndListener,\n _onEnter = _this$props.onEnter,\n _onEntering = _this$props.onEntering,\n _onEntered = _this$props.onEntered,\n _onExit = _this$props.onExit,\n _onExiting = _this$props.onExiting,\n _onExited = _this$props.onExited,\n _nodeRef = _this$props.nodeRef,\n childProps = _objectWithoutPropertiesLoose(_this$props, [\"children\", \"in\", \"mountOnEnter\", \"unmountOnExit\", \"appear\", \"enter\", \"exit\", \"timeout\", \"addEndListener\", \"onEnter\", \"onEntering\", \"onEntered\", \"onExit\", \"onExiting\", \"onExited\", \"nodeRef\"]);\n\n return (\n /*#__PURE__*/\n // allows for nested Transitions\n React.createElement(TransitionGroupContext.Provider, {\n value: null\n }, typeof children === 'function' ? children(status, childProps) : React.cloneElement(React.Children.only(children), childProps))\n );\n };\n\n return Transition;\n}(React.Component);\n\nTransition.contextType = TransitionGroupContext;\nTransition.propTypes = process.env.NODE_ENV !== \"production\" ? {\n /**\n * A React reference to DOM element that need to transition:\n * https://stackoverflow.com/a/51127130/4671932\n *\n * - When `nodeRef` prop is used, `node` is not passed to callback functions\n * (e.g. `onEnter`) because user already has direct access to the node.\n * - When changing `key` prop of `Transition` in a `TransitionGroup` a new\n * `nodeRef` need to be provided to `Transition` with changed `key` prop\n * (see\n * [test/CSSTransition-test.js](https://github.com/reactjs/react-transition-group/blob/13435f897b3ab71f6e19d724f145596f5910581c/test/CSSTransition-test.js#L362-L437)).\n */\n nodeRef: PropTypes.shape({\n current: typeof Element === 'undefined' ? PropTypes.any : function (propValue, key, componentName, location, propFullName, secret) {\n var value = propValue[key];\n return PropTypes.instanceOf(value && 'ownerDocument' in value ? value.ownerDocument.defaultView.Element : Element)(propValue, key, componentName, location, propFullName, secret);\n }\n }),\n\n /**\n * A `function` child can be used instead of a React element. This function is\n * called with the current transition status (`'entering'`, `'entered'`,\n * `'exiting'`, `'exited'`), which can be used to apply context\n * specific props to a component.\n *\n * ```jsx\n * \n * {state => (\n * \n * )}\n * \n * ```\n */\n children: PropTypes.oneOfType([PropTypes.func.isRequired, PropTypes.element.isRequired]).isRequired,\n\n /**\n * Show the component; triggers the enter or exit states\n */\n in: PropTypes.bool,\n\n /**\n * By default the child component is mounted immediately along with\n * the parent `Transition` component. If you want to \"lazy mount\" the component on the\n * first `in={true}` you can set `mountOnEnter`. After the first enter transition the component will stay\n * mounted, even on \"exited\", unless you also specify `unmountOnExit`.\n */\n mountOnEnter: PropTypes.bool,\n\n /**\n * By default the child component stays mounted after it reaches the `'exited'` state.\n * Set `unmountOnExit` if you'd prefer to unmount the component after it finishes exiting.\n */\n unmountOnExit: PropTypes.bool,\n\n /**\n * By default the child component does not perform the enter transition when\n * it first mounts, regardless of the value of `in`. If you want this\n * behavior, set both `appear` and `in` to `true`.\n *\n * > **Note**: there are no special appear states like `appearing`/`appeared`, this prop\n * > only adds an additional enter transition. However, in the\n * > `` component that first enter transition does result in\n * > additional `.appear-*` classes, that way you can choose to style it\n * > differently.\n */\n appear: PropTypes.bool,\n\n /**\n * Enable or disable enter transitions.\n */\n enter: PropTypes.bool,\n\n /**\n * Enable or disable exit transitions.\n */\n exit: PropTypes.bool,\n\n /**\n * The duration of the transition, in milliseconds.\n * Required unless `addEndListener` is provided.\n *\n * You may specify a single timeout for all transitions:\n *\n * ```jsx\n * timeout={500}\n * ```\n *\n * or individually:\n *\n * ```jsx\n * timeout={{\n * appear: 500,\n * enter: 300,\n * exit: 500,\n * }}\n * ```\n *\n * - `appear` defaults to the value of `enter`\n * - `enter` defaults to `0`\n * - `exit` defaults to `0`\n *\n * @type {number | { enter?: number, exit?: number, appear?: number }}\n */\n timeout: function timeout(props) {\n var pt = timeoutsShape;\n if (!props.addEndListener) pt = pt.isRequired;\n\n for (var _len = arguments.length, args = new Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) {\n args[_key - 1] = arguments[_key];\n }\n\n return pt.apply(void 0, [props].concat(args));\n },\n\n /**\n * Add a custom transition end trigger. Called with the transitioning\n * DOM node and a `done` callback. Allows for more fine grained transition end\n * logic. Timeouts are still used as a fallback if provided.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * ```jsx\n * addEndListener={(node, done) => {\n * // use the css transitionend event to mark the finish of a transition\n * node.addEventListener('transitionend', done, false);\n * }}\n * ```\n */\n addEndListener: PropTypes.func,\n\n /**\n * Callback fired before the \"entering\" status is applied. An extra parameter\n * `isAppearing` is supplied to indicate if the enter stage is occurring on the initial mount\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement, isAppearing: bool) -> void\n */\n onEnter: PropTypes.func,\n\n /**\n * Callback fired after the \"entering\" status is applied. An extra parameter\n * `isAppearing` is supplied to indicate if the enter stage is occurring on the initial mount\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement, isAppearing: bool)\n */\n onEntering: PropTypes.func,\n\n /**\n * Callback fired after the \"entered\" status is applied. An extra parameter\n * `isAppearing` is supplied to indicate if the enter stage is occurring on the initial mount\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement, isAppearing: bool) -> void\n */\n onEntered: PropTypes.func,\n\n /**\n * Callback fired before the \"exiting\" status is applied.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement) -> void\n */\n onExit: PropTypes.func,\n\n /**\n * Callback fired after the \"exiting\" status is applied.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement) -> void\n */\n onExiting: PropTypes.func,\n\n /**\n * Callback fired after the \"exited\" status is applied.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed\n *\n * @type Function(node: HtmlElement) -> void\n */\n onExited: PropTypes.func\n} : {}; // Name the function so it is clearer in the documentation\n\nfunction noop() {}\n\nTransition.defaultProps = {\n in: false,\n mountOnEnter: false,\n unmountOnExit: false,\n appear: false,\n enter: true,\n exit: true,\n onEnter: noop,\n onEntering: noop,\n onEntered: noop,\n onExit: noop,\n onExiting: noop,\n onExited: noop\n};\nTransition.UNMOUNTED = UNMOUNTED;\nTransition.EXITED = EXITED;\nTransition.ENTERING = ENTERING;\nTransition.ENTERED = ENTERED;\nTransition.EXITING = EXITING;\nexport default Transition;","export const reflow = node => node.scrollTop;\nexport function getTransitionProps(props, options) {\n var _style$transitionDura, _style$transitionTimi;\n const {\n timeout,\n easing,\n style = {}\n } = props;\n return {\n duration: (_style$transitionDura = style.transitionDuration) != null ? _style$transitionDura : typeof timeout === 'number' ? timeout : timeout[options.mode] || 0,\n easing: (_style$transitionTimi = style.transitionTimingFunction) != null ? _style$transitionTimi : typeof easing === 'object' ? easing[options.mode] : easing,\n delay: style.transitionDelay\n };\n}","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"addEndListener\", \"appear\", \"children\", \"easing\", \"in\", \"onEnter\", \"onEntered\", \"onEntering\", \"onExit\", \"onExited\", \"onExiting\", \"style\", \"timeout\", \"TransitionComponent\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport { elementAcceptingRef, unstable_useTimeout as useTimeout } from '@mui/utils';\nimport { Transition } from 'react-transition-group';\nimport useTheme from '../styles/useTheme';\nimport { getTransitionProps, reflow } from '../transitions/utils';\nimport useForkRef from '../utils/useForkRef';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nfunction getScale(value) {\n return `scale(${value}, ${value ** 2})`;\n}\nconst styles = {\n entering: {\n opacity: 1,\n transform: getScale(1)\n },\n entered: {\n opacity: 1,\n transform: 'none'\n }\n};\n\n/*\n TODO v6: remove\n Conditionally apply a workaround for the CSS transition bug in Safari 15.4 / WebKit browsers.\n */\nconst isWebKit154 = typeof navigator !== 'undefined' && /^((?!chrome|android).)*(safari|mobile)/i.test(navigator.userAgent) && /(os |version\\/)15(.|_)4/i.test(navigator.userAgent);\n\n/**\n * The Grow transition is used by the [Tooltip](/material-ui/react-tooltip/) and\n * [Popover](/material-ui/react-popover/) components.\n * It uses [react-transition-group](https://github.com/reactjs/react-transition-group) internally.\n */\nconst Grow = /*#__PURE__*/React.forwardRef(function Grow(props, ref) {\n const {\n addEndListener,\n appear = true,\n children,\n easing,\n in: inProp,\n onEnter,\n onEntered,\n onEntering,\n onExit,\n onExited,\n onExiting,\n style,\n timeout = 'auto',\n // eslint-disable-next-line react/prop-types\n TransitionComponent = Transition\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const timer = useTimeout();\n const autoTimeout = React.useRef();\n const theme = useTheme();\n const nodeRef = React.useRef(null);\n const handleRef = useForkRef(nodeRef, children.ref, ref);\n const normalizedTransitionCallback = callback => maybeIsAppearing => {\n if (callback) {\n const node = nodeRef.current;\n\n // onEnterXxx and onExitXxx callbacks have a different arguments.length value.\n if (maybeIsAppearing === undefined) {\n callback(node);\n } else {\n callback(node, maybeIsAppearing);\n }\n }\n };\n const handleEntering = normalizedTransitionCallback(onEntering);\n const handleEnter = normalizedTransitionCallback((node, isAppearing) => {\n reflow(node); // So the animation always start from the start.\n\n const {\n duration: transitionDuration,\n delay,\n easing: transitionTimingFunction\n } = getTransitionProps({\n style,\n timeout,\n easing\n }, {\n mode: 'enter'\n });\n let duration;\n if (timeout === 'auto') {\n duration = theme.transitions.getAutoHeightDuration(node.clientHeight);\n autoTimeout.current = duration;\n } else {\n duration = transitionDuration;\n }\n node.style.transition = [theme.transitions.create('opacity', {\n duration,\n delay\n }), theme.transitions.create('transform', {\n duration: isWebKit154 ? duration : duration * 0.666,\n delay,\n easing: transitionTimingFunction\n })].join(',');\n if (onEnter) {\n onEnter(node, isAppearing);\n }\n });\n const handleEntered = normalizedTransitionCallback(onEntered);\n const handleExiting = normalizedTransitionCallback(onExiting);\n const handleExit = normalizedTransitionCallback(node => {\n const {\n duration: transitionDuration,\n delay,\n easing: transitionTimingFunction\n } = getTransitionProps({\n style,\n timeout,\n easing\n }, {\n mode: 'exit'\n });\n let duration;\n if (timeout === 'auto') {\n duration = theme.transitions.getAutoHeightDuration(node.clientHeight);\n autoTimeout.current = duration;\n } else {\n duration = transitionDuration;\n }\n node.style.transition = [theme.transitions.create('opacity', {\n duration,\n delay\n }), theme.transitions.create('transform', {\n duration: isWebKit154 ? duration : duration * 0.666,\n delay: isWebKit154 ? delay : delay || duration * 0.333,\n easing: transitionTimingFunction\n })].join(',');\n node.style.opacity = 0;\n node.style.transform = getScale(0.75);\n if (onExit) {\n onExit(node);\n }\n });\n const handleExited = normalizedTransitionCallback(onExited);\n const handleAddEndListener = next => {\n if (timeout === 'auto') {\n timer.start(autoTimeout.current || 0, next);\n }\n if (addEndListener) {\n // Old call signature before `react-transition-group` implemented `nodeRef`\n addEndListener(nodeRef.current, next);\n }\n };\n return /*#__PURE__*/_jsx(TransitionComponent, _extends({\n appear: appear,\n in: inProp,\n nodeRef: nodeRef,\n onEnter: handleEnter,\n onEntered: handleEntered,\n onEntering: handleEntering,\n onExit: handleExit,\n onExited: handleExited,\n onExiting: handleExiting,\n addEndListener: handleAddEndListener,\n timeout: timeout === 'auto' ? null : timeout\n }, other, {\n children: (state, childProps) => {\n return /*#__PURE__*/React.cloneElement(children, _extends({\n style: _extends({\n opacity: 0,\n transform: getScale(0.75),\n visibility: state === 'exited' && !inProp ? 'hidden' : undefined\n }, styles[state], style, children.props.style),\n ref: handleRef\n }, childProps));\n }\n }));\n});\nprocess.env.NODE_ENV !== \"production\" ? Grow.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the d.ts file and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * Add a custom transition end trigger. Called with the transitioning DOM\n * node and a done callback. Allows for more fine grained transition end\n * logic. Note: Timeouts are still used as a fallback if provided.\n */\n addEndListener: PropTypes.func,\n /**\n * Perform the enter transition when it first mounts if `in` is also `true`.\n * Set this to `false` to disable this behavior.\n * @default true\n */\n appear: PropTypes.bool,\n /**\n * A single child content element.\n */\n children: elementAcceptingRef.isRequired,\n /**\n * The transition timing function.\n * You may specify a single easing or a object containing enter and exit values.\n */\n easing: PropTypes.oneOfType([PropTypes.shape({\n enter: PropTypes.string,\n exit: PropTypes.string\n }), PropTypes.string]),\n /**\n * If `true`, the component will transition in.\n */\n in: PropTypes.bool,\n /**\n * @ignore\n */\n onEnter: PropTypes.func,\n /**\n * @ignore\n */\n onEntered: PropTypes.func,\n /**\n * @ignore\n */\n onEntering: PropTypes.func,\n /**\n * @ignore\n */\n onExit: PropTypes.func,\n /**\n * @ignore\n */\n onExited: PropTypes.func,\n /**\n * @ignore\n */\n onExiting: PropTypes.func,\n /**\n * @ignore\n */\n style: PropTypes.object,\n /**\n * The duration for the transition, in milliseconds.\n * You may specify a single timeout for all transitions, or individually with an object.\n *\n * Set to 'auto' to automatically calculate transition time based on height.\n * @default 'auto'\n */\n timeout: PropTypes.oneOfType([PropTypes.oneOf(['auto']), PropTypes.number, PropTypes.shape({\n appear: PropTypes.number,\n enter: PropTypes.number,\n exit: PropTypes.number\n })])\n} : void 0;\nGrow.muiSupportAuto = true;\nexport default Grow;","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"anchorEl\", \"component\", \"components\", \"componentsProps\", \"container\", \"disablePortal\", \"keepMounted\", \"modifiers\", \"open\", \"placement\", \"popperOptions\", \"popperRef\", \"transition\", \"slots\", \"slotProps\"];\nimport { Popper as BasePopper } from '@mui/base/Popper';\nimport { useThemeWithoutDefault as useTheme } from '@mui/system';\nimport { HTMLElementType, refType } from '@mui/utils';\nimport PropTypes from 'prop-types';\nimport * as React from 'react';\nimport { styled, useThemeProps } from '../styles';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nconst PopperRoot = styled(BasePopper, {\n name: 'MuiPopper',\n slot: 'Root',\n overridesResolver: (props, styles) => styles.root\n})({});\n\n/**\n *\n * Demos:\n *\n * - [Autocomplete](https://mui.com/material-ui/react-autocomplete/)\n * - [Menu](https://mui.com/material-ui/react-menu/)\n * - [Popper](https://mui.com/material-ui/react-popper/)\n *\n * API:\n *\n * - [Popper API](https://mui.com/material-ui/api/popper/)\n */\nconst Popper = /*#__PURE__*/React.forwardRef(function Popper(inProps, ref) {\n var _slots$root;\n const theme = useTheme();\n const props = useThemeProps({\n props: inProps,\n name: 'MuiPopper'\n });\n const {\n anchorEl,\n component,\n components,\n componentsProps,\n container,\n disablePortal,\n keepMounted,\n modifiers,\n open,\n placement,\n popperOptions,\n popperRef,\n transition,\n slots,\n slotProps\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const RootComponent = (_slots$root = slots == null ? void 0 : slots.root) != null ? _slots$root : components == null ? void 0 : components.Root;\n const otherProps = _extends({\n anchorEl,\n container,\n disablePortal,\n keepMounted,\n modifiers,\n open,\n placement,\n popperOptions,\n popperRef,\n transition\n }, other);\n return /*#__PURE__*/_jsx(PopperRoot, _extends({\n as: component,\n direction: theme == null ? void 0 : theme.direction,\n slots: {\n root: RootComponent\n },\n slotProps: slotProps != null ? slotProps : componentsProps\n }, otherProps, {\n ref: ref\n }));\n});\nprocess.env.NODE_ENV !== \"production\" ? Popper.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * An HTML element, [virtualElement](https://popper.js.org/docs/v2/virtual-elements/),\n * or a function that returns either.\n * It's used to set the position of the popper.\n * The return value will passed as the reference object of the Popper instance.\n */\n anchorEl: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.object, PropTypes.func]),\n /**\n * Popper render function or node.\n */\n children: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.node, PropTypes.func]),\n /**\n * The component used for the root node.\n * Either a string to use a HTML element or a component.\n */\n component: PropTypes.elementType,\n /**\n * The components used for each slot inside the Popper.\n * Either a string to use a HTML element or a component.\n * @default {}\n */\n components: PropTypes.shape({\n Root: PropTypes.elementType\n }),\n /**\n * The props used for each slot inside the Popper.\n * @default {}\n */\n componentsProps: PropTypes.shape({\n root: PropTypes.oneOfType([PropTypes.func, PropTypes.object])\n }),\n /**\n * An HTML element or function that returns one.\n * The `container` will have the portal children appended to it.\n *\n * You can also provide a callback, which is called in a React layout effect.\n * This lets you set the container from a ref, and also makes server-side rendering possible.\n *\n * By default, it uses the body of the top-level document object,\n * so it's simply `document.body` most of the time.\n */\n container: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.func]),\n /**\n * The `children` will be under the DOM hierarchy of the parent component.\n * @default false\n */\n disablePortal: PropTypes.bool,\n /**\n * Always keep the children in the DOM.\n * This prop can be useful in SEO situation or\n * when you want to maximize the responsiveness of the Popper.\n * @default false\n */\n keepMounted: PropTypes.bool,\n /**\n * Popper.js is based on a \"plugin-like\" architecture,\n * most of its features are fully encapsulated \"modifiers\".\n *\n * A modifier is a function that is called each time Popper.js needs to\n * compute the position of the popper.\n * For this reason, modifiers should be very performant to avoid bottlenecks.\n * To learn how to create a modifier, [read the modifiers documentation](https://popper.js.org/docs/v2/modifiers/).\n */\n modifiers: PropTypes.arrayOf(PropTypes.shape({\n data: PropTypes.object,\n effect: PropTypes.func,\n enabled: PropTypes.bool,\n fn: PropTypes.func,\n name: PropTypes.any,\n options: PropTypes.object,\n phase: PropTypes.oneOf(['afterMain', 'afterRead', 'afterWrite', 'beforeMain', 'beforeRead', 'beforeWrite', 'main', 'read', 'write']),\n requires: PropTypes.arrayOf(PropTypes.string),\n requiresIfExists: PropTypes.arrayOf(PropTypes.string)\n })),\n /**\n * If `true`, the component is shown.\n */\n open: PropTypes.bool.isRequired,\n /**\n * Popper placement.\n * @default 'bottom'\n */\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n /**\n * Options provided to the [`Popper.js`](https://popper.js.org/docs/v2/constructors/#options) instance.\n * @default {}\n */\n popperOptions: PropTypes.shape({\n modifiers: PropTypes.array,\n onFirstUpdate: PropTypes.func,\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n strategy: PropTypes.oneOf(['absolute', 'fixed'])\n }),\n /**\n * A ref that points to the used popper instance.\n */\n popperRef: refType,\n /**\n * The props used for each slot inside the Popper.\n * @default {}\n */\n slotProps: PropTypes.shape({\n root: PropTypes.oneOfType([PropTypes.func, PropTypes.object])\n }),\n /**\n * The components used for each slot inside the Popper.\n * Either a string to use a HTML element or a component.\n * @default {}\n */\n slots: PropTypes.shape({\n root: PropTypes.elementType\n }),\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Help supporting a react-transition-group/Transition component.\n * @default false\n */\n transition: PropTypes.bool\n} : void 0;\nexport default Popper;","import generateUtilityClasses from '@mui/utils/generateUtilityClasses';\nimport generateUtilityClass from '@mui/utils/generateUtilityClass';\nexport function getTooltipUtilityClass(slot) {\n return generateUtilityClass('MuiTooltip', slot);\n}\nconst tooltipClasses = generateUtilityClasses('MuiTooltip', ['popper', 'popperInteractive', 'popperArrow', 'popperClose', 'tooltip', 'tooltipArrow', 'touch', 'tooltipPlacementLeft', 'tooltipPlacementRight', 'tooltipPlacementTop', 'tooltipPlacementBottom', 'arrow']);\nexport default tooltipClasses;","'use client';\n\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nconst _excluded = [\"arrow\", \"children\", \"classes\", \"components\", \"componentsProps\", \"describeChild\", \"disableFocusListener\", \"disableHoverListener\", \"disableInteractive\", \"disableTouchListener\", \"enterDelay\", \"enterNextDelay\", \"enterTouchDelay\", \"followCursor\", \"id\", \"leaveDelay\", \"leaveTouchDelay\", \"onClose\", \"onOpen\", \"open\", \"placement\", \"PopperComponent\", \"PopperProps\", \"slotProps\", \"slots\", \"title\", \"TransitionComponent\", \"TransitionProps\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport clsx from 'clsx';\nimport { elementAcceptingRef, unstable_useTimeout as useTimeout, unstable_Timeout as Timeout } from '@mui/utils';\nimport { unstable_composeClasses as composeClasses, appendOwnerState } from '@mui/base';\nimport { alpha } from '@mui/system';\nimport styled from '../styles/styled';\nimport useTheme from '../styles/useTheme';\nimport useThemeProps from '../styles/useThemeProps';\nimport capitalize from '../utils/capitalize';\nimport Grow from '../Grow';\nimport Popper from '../Popper';\nimport useEventCallback from '../utils/useEventCallback';\nimport useForkRef from '../utils/useForkRef';\nimport useId from '../utils/useId';\nimport useIsFocusVisible from '../utils/useIsFocusVisible';\nimport useControlled from '../utils/useControlled';\nimport tooltipClasses, { getTooltipUtilityClass } from './tooltipClasses';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nimport { jsxs as _jsxs } from \"react/jsx-runtime\";\nfunction round(value) {\n return Math.round(value * 1e5) / 1e5;\n}\nconst useUtilityClasses = ownerState => {\n const {\n classes,\n disableInteractive,\n arrow,\n touch,\n placement\n } = ownerState;\n const slots = {\n popper: ['popper', !disableInteractive && 'popperInteractive', arrow && 'popperArrow'],\n tooltip: ['tooltip', arrow && 'tooltipArrow', touch && 'touch', `tooltipPlacement${capitalize(placement.split('-')[0])}`],\n arrow: ['arrow']\n };\n return composeClasses(slots, getTooltipUtilityClass, classes);\n};\nconst TooltipPopper = styled(Popper, {\n name: 'MuiTooltip',\n slot: 'Popper',\n overridesResolver: (props, styles) => {\n const {\n ownerState\n } = props;\n return [styles.popper, !ownerState.disableInteractive && styles.popperInteractive, ownerState.arrow && styles.popperArrow, !ownerState.open && styles.popperClose];\n }\n})(({\n theme,\n ownerState,\n open\n}) => _extends({\n zIndex: (theme.vars || theme).zIndex.tooltip,\n pointerEvents: 'none'\n}, !ownerState.disableInteractive && {\n pointerEvents: 'auto'\n}, !open && {\n pointerEvents: 'none'\n}, ownerState.arrow && {\n [`&[data-popper-placement*=\"bottom\"] .${tooltipClasses.arrow}`]: {\n top: 0,\n marginTop: '-0.71em',\n '&::before': {\n transformOrigin: '0 100%'\n }\n },\n [`&[data-popper-placement*=\"top\"] .${tooltipClasses.arrow}`]: {\n bottom: 0,\n marginBottom: '-0.71em',\n '&::before': {\n transformOrigin: '100% 0'\n }\n },\n [`&[data-popper-placement*=\"right\"] .${tooltipClasses.arrow}`]: _extends({}, !ownerState.isRtl ? {\n left: 0,\n marginLeft: '-0.71em'\n } : {\n right: 0,\n marginRight: '-0.71em'\n }, {\n height: '1em',\n width: '0.71em',\n '&::before': {\n transformOrigin: '100% 100%'\n }\n }),\n [`&[data-popper-placement*=\"left\"] .${tooltipClasses.arrow}`]: _extends({}, !ownerState.isRtl ? {\n right: 0,\n marginRight: '-0.71em'\n } : {\n left: 0,\n marginLeft: '-0.71em'\n }, {\n height: '1em',\n width: '0.71em',\n '&::before': {\n transformOrigin: '0 0'\n }\n })\n}));\nconst TooltipTooltip = styled('div', {\n name: 'MuiTooltip',\n slot: 'Tooltip',\n overridesResolver: (props, styles) => {\n const {\n ownerState\n } = props;\n return [styles.tooltip, ownerState.touch && styles.touch, ownerState.arrow && styles.tooltipArrow, styles[`tooltipPlacement${capitalize(ownerState.placement.split('-')[0])}`]];\n }\n})(({\n theme,\n ownerState\n}) => _extends({\n backgroundColor: theme.vars ? theme.vars.palette.Tooltip.bg : alpha(theme.palette.grey[700], 0.92),\n borderRadius: (theme.vars || theme).shape.borderRadius,\n color: (theme.vars || theme).palette.common.white,\n fontFamily: theme.typography.fontFamily,\n padding: '4px 8px',\n fontSize: theme.typography.pxToRem(11),\n maxWidth: 300,\n margin: 2,\n wordWrap: 'break-word',\n fontWeight: theme.typography.fontWeightMedium\n}, ownerState.arrow && {\n position: 'relative',\n margin: 0\n}, ownerState.touch && {\n padding: '8px 16px',\n fontSize: theme.typography.pxToRem(14),\n lineHeight: `${round(16 / 14)}em`,\n fontWeight: theme.typography.fontWeightRegular\n}, {\n [`.${tooltipClasses.popper}[data-popper-placement*=\"left\"] &`]: _extends({\n transformOrigin: 'right center'\n }, !ownerState.isRtl ? _extends({\n marginRight: '14px'\n }, ownerState.touch && {\n marginRight: '24px'\n }) : _extends({\n marginLeft: '14px'\n }, ownerState.touch && {\n marginLeft: '24px'\n })),\n [`.${tooltipClasses.popper}[data-popper-placement*=\"right\"] &`]: _extends({\n transformOrigin: 'left center'\n }, !ownerState.isRtl ? _extends({\n marginLeft: '14px'\n }, ownerState.touch && {\n marginLeft: '24px'\n }) : _extends({\n marginRight: '14px'\n }, ownerState.touch && {\n marginRight: '24px'\n })),\n [`.${tooltipClasses.popper}[data-popper-placement*=\"top\"] &`]: _extends({\n transformOrigin: 'center bottom',\n marginBottom: '14px'\n }, ownerState.touch && {\n marginBottom: '24px'\n }),\n [`.${tooltipClasses.popper}[data-popper-placement*=\"bottom\"] &`]: _extends({\n transformOrigin: 'center top',\n marginTop: '14px'\n }, ownerState.touch && {\n marginTop: '24px'\n })\n}));\nconst TooltipArrow = styled('span', {\n name: 'MuiTooltip',\n slot: 'Arrow',\n overridesResolver: (props, styles) => styles.arrow\n})(({\n theme\n}) => ({\n overflow: 'hidden',\n position: 'absolute',\n width: '1em',\n height: '0.71em' /* = width / sqrt(2) = (length of the hypotenuse) */,\n boxSizing: 'border-box',\n color: theme.vars ? theme.vars.palette.Tooltip.bg : alpha(theme.palette.grey[700], 0.9),\n '&::before': {\n content: '\"\"',\n margin: 'auto',\n display: 'block',\n width: '100%',\n height: '100%',\n backgroundColor: 'currentColor',\n transform: 'rotate(45deg)'\n }\n}));\nlet hystersisOpen = false;\nconst hystersisTimer = new Timeout();\nlet cursorPosition = {\n x: 0,\n y: 0\n};\nexport function testReset() {\n hystersisOpen = false;\n hystersisTimer.clear();\n}\nfunction composeEventHandler(handler, eventHandler) {\n return event => {\n if (eventHandler) {\n eventHandler(event);\n }\n handler(event);\n };\n}\n\n// TODO v6: Remove PopperComponent, PopperProps, TransitionComponent and TransitionProps.\nconst Tooltip = /*#__PURE__*/React.forwardRef(function Tooltip(inProps, ref) {\n var _ref, _slots$popper, _ref2, _ref3, _slots$transition, _ref4, _slots$tooltip, _ref5, _slots$arrow, _slotProps$popper, _ref6, _slotProps$popper2, _slotProps$transition, _slotProps$tooltip, _ref7, _slotProps$tooltip2, _slotProps$arrow, _ref8, _slotProps$arrow2;\n const props = useThemeProps({\n props: inProps,\n name: 'MuiTooltip'\n });\n const {\n arrow = false,\n children: childrenProp,\n components = {},\n componentsProps = {},\n describeChild = false,\n disableFocusListener = false,\n disableHoverListener = false,\n disableInteractive: disableInteractiveProp = false,\n disableTouchListener = false,\n enterDelay = 100,\n enterNextDelay = 0,\n enterTouchDelay = 700,\n followCursor = false,\n id: idProp,\n leaveDelay = 0,\n leaveTouchDelay = 1500,\n onClose,\n onOpen,\n open: openProp,\n placement = 'bottom',\n PopperComponent: PopperComponentProp,\n PopperProps = {},\n slotProps = {},\n slots = {},\n title,\n TransitionComponent: TransitionComponentProp = Grow,\n TransitionProps\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n\n // to prevent runtime errors, developers will need to provide a child as a React element anyway.\n const children = /*#__PURE__*/React.isValidElement(childrenProp) ? childrenProp : /*#__PURE__*/_jsx(\"span\", {\n children: childrenProp\n });\n const theme = useTheme();\n const isRtl = theme.direction === 'rtl';\n const [childNode, setChildNode] = React.useState();\n const [arrowRef, setArrowRef] = React.useState(null);\n const ignoreNonTouchEvents = React.useRef(false);\n const disableInteractive = disableInteractiveProp || followCursor;\n const closeTimer = useTimeout();\n const enterTimer = useTimeout();\n const leaveTimer = useTimeout();\n const touchTimer = useTimeout();\n const [openState, setOpenState] = useControlled({\n controlled: openProp,\n default: false,\n name: 'Tooltip',\n state: 'open'\n });\n let open = openState;\n if (process.env.NODE_ENV !== 'production') {\n // eslint-disable-next-line react-hooks/rules-of-hooks\n const {\n current: isControlled\n } = React.useRef(openProp !== undefined);\n\n // eslint-disable-next-line react-hooks/rules-of-hooks\n React.useEffect(() => {\n if (childNode && childNode.disabled && !isControlled && title !== '' && childNode.tagName.toLowerCase() === 'button') {\n console.error(['MUI: You are providing a disabled `button` child to the Tooltip component.', 'A disabled element does not fire events.', \"Tooltip needs to listen to the child element's events to display the title.\", '', 'Add a simple wrapper element, such as a `span`.'].join('\\n'));\n }\n }, [title, childNode, isControlled]);\n }\n const id = useId(idProp);\n const prevUserSelect = React.useRef();\n const stopTouchInteraction = useEventCallback(() => {\n if (prevUserSelect.current !== undefined) {\n document.body.style.WebkitUserSelect = prevUserSelect.current;\n prevUserSelect.current = undefined;\n }\n touchTimer.clear();\n });\n React.useEffect(() => stopTouchInteraction, [stopTouchInteraction]);\n const handleOpen = event => {\n hystersisTimer.clear();\n hystersisOpen = true;\n\n // The mouseover event will trigger for every nested element in the tooltip.\n // We can skip rerendering when the tooltip is already open.\n // We are using the mouseover event instead of the mouseenter event to fix a hide/show issue.\n setOpenState(true);\n if (onOpen && !open) {\n onOpen(event);\n }\n };\n const handleClose = useEventCallback(\n /**\n * @param {React.SyntheticEvent | Event} event\n */\n event => {\n hystersisTimer.start(800 + leaveDelay, () => {\n hystersisOpen = false;\n });\n setOpenState(false);\n if (onClose && open) {\n onClose(event);\n }\n closeTimer.start(theme.transitions.duration.shortest, () => {\n ignoreNonTouchEvents.current = false;\n });\n });\n const handleEnter = event => {\n if (ignoreNonTouchEvents.current && event.type !== 'touchstart') {\n return;\n }\n\n // Remove the title ahead of time.\n // We don't want to wait for the next render commit.\n // We would risk displaying two tooltips at the same time (native + this one).\n if (childNode) {\n childNode.removeAttribute('title');\n }\n enterTimer.clear();\n leaveTimer.clear();\n if (enterDelay || hystersisOpen && enterNextDelay) {\n enterTimer.start(hystersisOpen ? enterNextDelay : enterDelay, () => {\n handleOpen(event);\n });\n } else {\n handleOpen(event);\n }\n };\n const handleLeave = event => {\n enterTimer.clear();\n leaveTimer.start(leaveDelay, () => {\n handleClose(event);\n });\n };\n const {\n isFocusVisibleRef,\n onBlur: handleBlurVisible,\n onFocus: handleFocusVisible,\n ref: focusVisibleRef\n } = useIsFocusVisible();\n // We don't necessarily care about the focusVisible state (which is safe to access via ref anyway).\n // We just need to re-render the Tooltip if the focus-visible state changes.\n const [, setChildIsFocusVisible] = React.useState(false);\n const handleBlur = event => {\n handleBlurVisible(event);\n if (isFocusVisibleRef.current === false) {\n setChildIsFocusVisible(false);\n handleLeave(event);\n }\n };\n const handleFocus = event => {\n // Workaround for https://github.com/facebook/react/issues/7769\n // The autoFocus of React might trigger the event before the componentDidMount.\n // We need to account for this eventuality.\n if (!childNode) {\n setChildNode(event.currentTarget);\n }\n handleFocusVisible(event);\n if (isFocusVisibleRef.current === true) {\n setChildIsFocusVisible(true);\n handleEnter(event);\n }\n };\n const detectTouchStart = event => {\n ignoreNonTouchEvents.current = true;\n const childrenProps = children.props;\n if (childrenProps.onTouchStart) {\n childrenProps.onTouchStart(event);\n }\n };\n const handleMouseOver = handleEnter;\n const handleMouseLeave = handleLeave;\n const handleTouchStart = event => {\n detectTouchStart(event);\n leaveTimer.clear();\n closeTimer.clear();\n stopTouchInteraction();\n prevUserSelect.current = document.body.style.WebkitUserSelect;\n // Prevent iOS text selection on long-tap.\n document.body.style.WebkitUserSelect = 'none';\n touchTimer.start(enterTouchDelay, () => {\n document.body.style.WebkitUserSelect = prevUserSelect.current;\n handleEnter(event);\n });\n };\n const handleTouchEnd = event => {\n if (children.props.onTouchEnd) {\n children.props.onTouchEnd(event);\n }\n stopTouchInteraction();\n leaveTimer.start(leaveTouchDelay, () => {\n handleClose(event);\n });\n };\n React.useEffect(() => {\n if (!open) {\n return undefined;\n }\n\n /**\n * @param {KeyboardEvent} nativeEvent\n */\n function handleKeyDown(nativeEvent) {\n // IE11, Edge (prior to using Bink?) use 'Esc'\n if (nativeEvent.key === 'Escape' || nativeEvent.key === 'Esc') {\n handleClose(nativeEvent);\n }\n }\n document.addEventListener('keydown', handleKeyDown);\n return () => {\n document.removeEventListener('keydown', handleKeyDown);\n };\n }, [handleClose, open]);\n const handleRef = useForkRef(children.ref, focusVisibleRef, setChildNode, ref);\n\n // There is no point in displaying an empty tooltip.\n // So we exclude all falsy values, except 0, which is valid.\n if (!title && title !== 0) {\n open = false;\n }\n const popperRef = React.useRef();\n const handleMouseMove = event => {\n const childrenProps = children.props;\n if (childrenProps.onMouseMove) {\n childrenProps.onMouseMove(event);\n }\n cursorPosition = {\n x: event.clientX,\n y: event.clientY\n };\n if (popperRef.current) {\n popperRef.current.update();\n }\n };\n const nameOrDescProps = {};\n const titleIsString = typeof title === 'string';\n if (describeChild) {\n nameOrDescProps.title = !open && titleIsString && !disableHoverListener ? title : null;\n nameOrDescProps['aria-describedby'] = open ? id : null;\n } else {\n nameOrDescProps['aria-label'] = titleIsString ? title : null;\n nameOrDescProps['aria-labelledby'] = open && !titleIsString ? id : null;\n }\n const childrenProps = _extends({}, nameOrDescProps, other, children.props, {\n className: clsx(other.className, children.props.className),\n onTouchStart: detectTouchStart,\n ref: handleRef\n }, followCursor ? {\n onMouseMove: handleMouseMove\n } : {});\n if (process.env.NODE_ENV !== 'production') {\n childrenProps['data-mui-internal-clone-element'] = true;\n\n // eslint-disable-next-line react-hooks/rules-of-hooks\n React.useEffect(() => {\n if (childNode && !childNode.getAttribute('data-mui-internal-clone-element')) {\n console.error(['MUI: The `children` component of the Tooltip is not forwarding its props correctly.', 'Please make sure that props are spread on the same element that the ref is applied to.'].join('\\n'));\n }\n }, [childNode]);\n }\n const interactiveWrapperListeners = {};\n if (!disableTouchListener) {\n childrenProps.onTouchStart = handleTouchStart;\n childrenProps.onTouchEnd = handleTouchEnd;\n }\n if (!disableHoverListener) {\n childrenProps.onMouseOver = composeEventHandler(handleMouseOver, childrenProps.onMouseOver);\n childrenProps.onMouseLeave = composeEventHandler(handleMouseLeave, childrenProps.onMouseLeave);\n if (!disableInteractive) {\n interactiveWrapperListeners.onMouseOver = handleMouseOver;\n interactiveWrapperListeners.onMouseLeave = handleMouseLeave;\n }\n }\n if (!disableFocusListener) {\n childrenProps.onFocus = composeEventHandler(handleFocus, childrenProps.onFocus);\n childrenProps.onBlur = composeEventHandler(handleBlur, childrenProps.onBlur);\n if (!disableInteractive) {\n interactiveWrapperListeners.onFocus = handleFocus;\n interactiveWrapperListeners.onBlur = handleBlur;\n }\n }\n if (process.env.NODE_ENV !== 'production') {\n if (children.props.title) {\n console.error(['MUI: You have provided a `title` prop to the child of .', `Remove this title prop \\`${children.props.title}\\` or the Tooltip component.`].join('\\n'));\n }\n }\n const popperOptions = React.useMemo(() => {\n var _PopperProps$popperOp;\n let tooltipModifiers = [{\n name: 'arrow',\n enabled: Boolean(arrowRef),\n options: {\n element: arrowRef,\n padding: 4\n }\n }];\n if ((_PopperProps$popperOp = PopperProps.popperOptions) != null && _PopperProps$popperOp.modifiers) {\n tooltipModifiers = tooltipModifiers.concat(PopperProps.popperOptions.modifiers);\n }\n return _extends({}, PopperProps.popperOptions, {\n modifiers: tooltipModifiers\n });\n }, [arrowRef, PopperProps]);\n const ownerState = _extends({}, props, {\n isRtl,\n arrow,\n disableInteractive,\n placement,\n PopperComponentProp,\n touch: ignoreNonTouchEvents.current\n });\n const classes = useUtilityClasses(ownerState);\n const PopperComponent = (_ref = (_slots$popper = slots.popper) != null ? _slots$popper : components.Popper) != null ? _ref : TooltipPopper;\n const TransitionComponent = (_ref2 = (_ref3 = (_slots$transition = slots.transition) != null ? _slots$transition : components.Transition) != null ? _ref3 : TransitionComponentProp) != null ? _ref2 : Grow;\n const TooltipComponent = (_ref4 = (_slots$tooltip = slots.tooltip) != null ? _slots$tooltip : components.Tooltip) != null ? _ref4 : TooltipTooltip;\n const ArrowComponent = (_ref5 = (_slots$arrow = slots.arrow) != null ? _slots$arrow : components.Arrow) != null ? _ref5 : TooltipArrow;\n const popperProps = appendOwnerState(PopperComponent, _extends({}, PopperProps, (_slotProps$popper = slotProps.popper) != null ? _slotProps$popper : componentsProps.popper, {\n className: clsx(classes.popper, PopperProps == null ? void 0 : PopperProps.className, (_ref6 = (_slotProps$popper2 = slotProps.popper) != null ? _slotProps$popper2 : componentsProps.popper) == null ? void 0 : _ref6.className)\n }), ownerState);\n const transitionProps = appendOwnerState(TransitionComponent, _extends({}, TransitionProps, (_slotProps$transition = slotProps.transition) != null ? _slotProps$transition : componentsProps.transition), ownerState);\n const tooltipProps = appendOwnerState(TooltipComponent, _extends({}, (_slotProps$tooltip = slotProps.tooltip) != null ? _slotProps$tooltip : componentsProps.tooltip, {\n className: clsx(classes.tooltip, (_ref7 = (_slotProps$tooltip2 = slotProps.tooltip) != null ? _slotProps$tooltip2 : componentsProps.tooltip) == null ? void 0 : _ref7.className)\n }), ownerState);\n const tooltipArrowProps = appendOwnerState(ArrowComponent, _extends({}, (_slotProps$arrow = slotProps.arrow) != null ? _slotProps$arrow : componentsProps.arrow, {\n className: clsx(classes.arrow, (_ref8 = (_slotProps$arrow2 = slotProps.arrow) != null ? _slotProps$arrow2 : componentsProps.arrow) == null ? void 0 : _ref8.className)\n }), ownerState);\n return /*#__PURE__*/_jsxs(React.Fragment, {\n children: [/*#__PURE__*/React.cloneElement(children, childrenProps), /*#__PURE__*/_jsx(PopperComponent, _extends({\n as: PopperComponentProp != null ? PopperComponentProp : Popper,\n placement: placement,\n anchorEl: followCursor ? {\n getBoundingClientRect: () => ({\n top: cursorPosition.y,\n left: cursorPosition.x,\n right: cursorPosition.x,\n bottom: cursorPosition.y,\n width: 0,\n height: 0\n })\n } : childNode,\n popperRef: popperRef,\n open: childNode ? open : false,\n id: id,\n transition: true\n }, interactiveWrapperListeners, popperProps, {\n popperOptions: popperOptions,\n children: ({\n TransitionProps: TransitionPropsInner\n }) => /*#__PURE__*/_jsx(TransitionComponent, _extends({\n timeout: theme.transitions.duration.shorter\n }, TransitionPropsInner, transitionProps, {\n children: /*#__PURE__*/_jsxs(TooltipComponent, _extends({}, tooltipProps, {\n children: [title, arrow ? /*#__PURE__*/_jsx(ArrowComponent, _extends({}, tooltipArrowProps, {\n ref: setArrowRef\n })) : null]\n }))\n }))\n }))]\n });\n});\nprocess.env.NODE_ENV !== \"production\" ? Tooltip.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the d.ts file and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * If `true`, adds an arrow to the tooltip.\n * @default false\n */\n arrow: PropTypes.bool,\n /**\n * Tooltip reference element.\n */\n children: elementAcceptingRef.isRequired,\n /**\n * Override or extend the styles applied to the component.\n */\n classes: PropTypes.object,\n /**\n * @ignore\n */\n className: PropTypes.string,\n /**\n * The components used for each slot inside.\n *\n * This prop is an alias for the `slots` prop.\n * It's recommended to use the `slots` prop instead.\n *\n * @default {}\n */\n components: PropTypes.shape({\n Arrow: PropTypes.elementType,\n Popper: PropTypes.elementType,\n Tooltip: PropTypes.elementType,\n Transition: PropTypes.elementType\n }),\n /**\n * The extra props for the slot components.\n * You can override the existing props or add new ones.\n *\n * This prop is an alias for the `slotProps` prop.\n * It's recommended to use the `slotProps` prop instead, as `componentsProps` will be deprecated in the future.\n *\n * @default {}\n */\n componentsProps: PropTypes.shape({\n arrow: PropTypes.object,\n popper: PropTypes.object,\n tooltip: PropTypes.object,\n transition: PropTypes.object\n }),\n /**\n * Set to `true` if the `title` acts as an accessible description.\n * By default the `title` acts as an accessible label for the child.\n * @default false\n */\n describeChild: PropTypes.bool,\n /**\n * Do not respond to focus-visible events.\n * @default false\n */\n disableFocusListener: PropTypes.bool,\n /**\n * Do not respond to hover events.\n * @default false\n */\n disableHoverListener: PropTypes.bool,\n /**\n * Makes a tooltip not interactive, i.e. it will close when the user\n * hovers over the tooltip before the `leaveDelay` is expired.\n * @default false\n */\n disableInteractive: PropTypes.bool,\n /**\n * Do not respond to long press touch events.\n * @default false\n */\n disableTouchListener: PropTypes.bool,\n /**\n * The number of milliseconds to wait before showing the tooltip.\n * This prop won't impact the enter touch delay (`enterTouchDelay`).\n * @default 100\n */\n enterDelay: PropTypes.number,\n /**\n * The number of milliseconds to wait before showing the tooltip when one was already recently opened.\n * @default 0\n */\n enterNextDelay: PropTypes.number,\n /**\n * The number of milliseconds a user must touch the element before showing the tooltip.\n * @default 700\n */\n enterTouchDelay: PropTypes.number,\n /**\n * If `true`, the tooltip follow the cursor over the wrapped element.\n * @default false\n */\n followCursor: PropTypes.bool,\n /**\n * This prop is used to help implement the accessibility logic.\n * If you don't provide this prop. It falls back to a randomly generated id.\n */\n id: PropTypes.string,\n /**\n * The number of milliseconds to wait before hiding the tooltip.\n * This prop won't impact the leave touch delay (`leaveTouchDelay`).\n * @default 0\n */\n leaveDelay: PropTypes.number,\n /**\n * The number of milliseconds after the user stops touching an element before hiding the tooltip.\n * @default 1500\n */\n leaveTouchDelay: PropTypes.number,\n /**\n * Callback fired when the component requests to be closed.\n *\n * @param {React.SyntheticEvent} event The event source of the callback.\n */\n onClose: PropTypes.func,\n /**\n * Callback fired when the component requests to be open.\n *\n * @param {React.SyntheticEvent} event The event source of the callback.\n */\n onOpen: PropTypes.func,\n /**\n * If `true`, the component is shown.\n */\n open: PropTypes.bool,\n /**\n * Tooltip placement.\n * @default 'bottom'\n */\n placement: PropTypes.oneOf(['bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n /**\n * The component used for the popper.\n * @default Popper\n */\n PopperComponent: PropTypes.elementType,\n /**\n * Props applied to the [`Popper`](/material-ui/api/popper/) element.\n * @default {}\n */\n PopperProps: PropTypes.object,\n /**\n * The extra props for the slot components.\n * You can override the existing props or add new ones.\n *\n * This prop is an alias for the `componentsProps` prop, which will be deprecated in the future.\n *\n * @default {}\n */\n slotProps: PropTypes.shape({\n arrow: PropTypes.object,\n popper: PropTypes.object,\n tooltip: PropTypes.object,\n transition: PropTypes.object\n }),\n /**\n * The components used for each slot inside.\n *\n * This prop is an alias for the `components` prop, which will be deprecated in the future.\n *\n * @default {}\n */\n slots: PropTypes.shape({\n arrow: PropTypes.elementType,\n popper: PropTypes.elementType,\n tooltip: PropTypes.elementType,\n transition: PropTypes.elementType\n }),\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Tooltip title. Zero-length titles string, undefined, null and false are never displayed.\n */\n title: PropTypes.node,\n /**\n * The component used for the transition.\n * [Follow this guide](/material-ui/transitions/#transitioncomponent-prop) to learn more about the requirements for this component.\n * @default Grow\n */\n TransitionComponent: PropTypes.elementType,\n /**\n * Props applied to the transition element.\n * By default, the element is based on this [`Transition`](http://reactcommunity.org/react-transition-group/transition/) component.\n */\n TransitionProps: PropTypes.object\n} : void 0;\nexport default Tooltip;","import '@/components/mui/menu-item.component.css';\nimport ArrowRightIcon from '@mui/icons-material/ArrowRight';\nimport {\n ListItemIcon as MuiListItemIcon,\n ListItemText as MuiListItemText,\n MenuItem as MuiMenuItem,\n} from '@mui/material';\nimport Tooltip from '@mui/material/Tooltip';\nimport { Localized, ReferencedItem, SingleColumnMenu } from 'platform-bible-utils';\nimport { MouseEvent, PropsWithChildren } from 'react';\n\ntype MenuItemInfoBase = {\n /** Text (displayable in the UI) as the name of the menu item */\n label: string;\n /** Text to display when the mouse hovers over the menu item */\n tooltip?: string;\n};\n\nexport type Command = MenuItemInfoBase & {\n /** Command to execute (string.string) */\n command: string;\n};\n\ntype SubMenu = MenuItemInfoBase & {\n /** Command to execute (string.string) */\n items: MenuItemInfo[];\n};\n\nexport interface CommandHandler {\n (command: Command): void;\n}\n\nexport type MenuPropsBase = {\n /*\n * The JSON defining the menu whose items are to be rendered. This will typically be one of the\n * menus in the \"defs\" in a Platform.Bible menu (see PlatformMenus). The schema for this is\n * menuDocumentSchema (at the end of menus.model.ts). Note that while this is a\n * \"SingleColumnMenu\", somewhat bizarrely, a MultiColumnMenu is a SingleColumnMenu, so it really\n * could be a MultiColumnMenu, in which case, column had better be defined so it can be used\n * to filter out the actual groups and items to display on the column.\n */\n menuDefinition: Localized;\n\n commandHandler: CommandHandler;\n\n /**\n * Additional action to perform when any menu item is clicked. Allows the caller to handle event\n * (e.g., to close the menu).\n */\n onClick?: (event: MouseEvent) => void;\n};\n\nexport type MenuItemListProps = MenuPropsBase & {\n /** Optional unique (column) identifier */\n columnId?: ReferencedItem;\n};\n\nexport type MenuItemProps = Omit &\n PropsWithChildren<{\n /** Optional unique identifier */\n id?: string;\n\n onClick: (event: MouseEvent) => void;\n }>;\n\ntype MenuItemInfo = (Command | SubMenu) & {\n /**\n * If specified, menu item will be inset if it does not have a leading icon.\n *\n * @default true\n */\n allowForLeadingIcons?: boolean;\n /**\n * If specified, the path to the icon image to display on the leading side of the menu text.\n *\n * @default undefined (no leading icon will be shown)\n */\n iconPathBefore?: string;\n /**\n * If specified, the path to the icon image to display on the trailing side of the menu text.\n *\n * @default undefined (no trailing icon will be shown)\n */\n iconPathAfter?: string;\n /**\n * If true, list item is focused during the first mount\n *\n * @default false\n */\n hasAutoFocus?: boolean;\n\n /** Additional css classes to help with unique styling of the menu item */\n className?: string;\n\n /**\n * If true, the menu item will appear disabled and it will not respond to clicks or mouse hovers.\n *\n * @default false\n */\n isDisabled?: boolean;\n\n /**\n * If true, compact vertical padding designed for keyboard and mouse input is used.\n *\n * @default true\n */\n isDense?: boolean;\n\n /**\n * If true, a right-arrow icon will be displayed (iconPathAfter, if specified, will be ignored).\n *\n * @default false\n */\n isSubMenuParent?: boolean;\n\n /**\n * If true, the left and right padding is removed\n *\n * @default false\n */\n hasDisabledGutters?: boolean;\n\n /**\n * If true, a 1px light border is added to bottom of menu item\n *\n * @default false\n */\n hasDivider?: boolean;\n\n /** Help identify which element has keyboard focus */\n focusVisibleClassName?: string;\n\n /** If it's a submenu, it should have the items property */\n items?: MenuItemInfo[];\n};\n\nfunction getIcon(icon: string | undefined, menuLabel: string, leading: boolean) {\n return icon ? (\n \n {`${leading\n \n ) : undefined;\n}\n\nexport default function MenuItem(props: MenuItemProps) {\n const {\n onClick,\n label,\n tooltip,\n allowForLeadingIcons = true,\n iconPathBefore = undefined,\n iconPathAfter = undefined,\n hasAutoFocus = false,\n className,\n isDisabled = false,\n isDense = true,\n isSubMenuParent = false,\n hasDisabledGutters = false,\n hasDivider = false,\n focusVisibleClassName,\n id,\n children,\n } = props;\n\n const menuItem = (\n \n {label ? (\n <>\n {getIcon(iconPathBefore, label, true)}\n \n {isSubMenuParent ? (\n \n \n \n ) : (\n getIcon(iconPathAfter, label, false)\n )}\n \n ) : (\n children\n )}\n \n );\n\n return tooltip ? (\n \n
    {menuItem}
    \n
    \n ) : (\n menuItem\n );\n}\n","import MenuItem, {\n MenuItemListProps,\n MenuItemProps,\n MenuPropsBase,\n} from '@/components/mui/menu-item.component';\nimport { Menu } from '@mui/material';\nimport {\n Localized,\n MenuGroupDetailsInSubMenu,\n MenuItemContainingCommand,\n MenuItemContainingSubmenu,\n OrderedExtensibleContainer,\n ReferencedItem,\n SingleColumnMenu,\n} from 'platform-bible-utils';\nimport { MouseEvent, useMemo, useState } from 'react';\n\n/**\n * All the exported types in this file should be regarded as \"internal\" (i.e., they should not be\n * exposed via index.ts).\n */\n\nexport type GroupedMenuPropsBase = MenuPropsBase & {\n /** Optional unique (column) identifier */\n columnId?: ReferencedItem;\n};\n\nexport type GroupedMenuItemListProps = MenuItemListProps & {\n /**\n * If the menuDefinition includes \"top-level\" groups (i.e., those that belong to a column as\n * opposed to those that belong to a submenu) that should not be included in the list, then this\n * array specifies which groups to include. Likewise, for a submenu, this list indicates which\n * groups are pertinent for that submenu. So then for a context menu this property need not be\n * specified since it is a top-level menu based on a \"true\" SingleColumnMenu (i.e., one that is\n * not a MultiColumnMenu).\n */\n includedGroups?: {\n id: string;\n group: Localized;\n }[];\n};\n\ninterface ItemInfo {\n item: Localized;\n isLastItemInGroup: boolean;\n}\n\ntype SubMenuProps = MenuPropsBase & {\n parentMenuItem: Localized;\n parentItemProps: Omit, 'iconPathAfter'>;\n};\n\nfunction getAllGroups(menuDefinition: Localized) {\n const groupEntries = Object.entries(menuDefinition.groups);\n // Convert array of entries to array of objects with id and group properties\n return groupEntries.map(([key, value]) => ({ id: key, group: value }));\n}\n\nfunction SubMenu(props: SubMenuProps) {\n const [anchorEl, setAnchorEl] = useState(undefined);\n\n const { parentMenuItem, parentItemProps, menuDefinition } = props;\n\n const handleParentMenuItemClick = (event: MouseEvent) => {\n setAnchorEl(event.currentTarget);\n };\n\n const handleClose = () => {\n setAnchorEl(undefined);\n };\n\n const renderSubMenuItems = () => {\n let includedGroups = getAllGroups(menuDefinition).filter((g) => 'menuItem' in g.group);\n\n // Ensure valid parent menu was provided. (If not, submenu will contain all groups!)\n if (!parentMenuItem?.id) throw new Error('A valid parent menu item is required for submenus.');\n\n // When laying out a submenu, only include groups associated with the provided parent menu.\n // Note: without the (annoying) redundant check that the included groups\n // have the menuItem field, TS doesn't think it exists.\n includedGroups = includedGroups.filter(\n (group) => 'menuItem' in group.group && group.group.menuItem === parentMenuItem.id,\n );\n\n return ;\n };\n\n return (\n <>\n \n \n {renderSubMenuItems()}\n \n \n );\n}\n\nconst getOrderedGroupItems = (\n groupId: string,\n allItems: Localized[],\n) => {\n // Filter items that belong to the specified group\n const itemsForGroup = allItems.filter((item) => item.group === groupId);\n // Sort items based on order\n const sortedItems = itemsForGroup.sort((a, b) => (a.order || 0) - (b.order || 0));\n return sortedItems;\n};\n\n/**\n * This component is internal; it does not need to be exposed to the outside world since it is not\n * useful on its own. It is used to generate and lay out the MenuItems that appear either on a\n * top-level menu (in a GridMenu or ContextMenu) or in a submenu.\n */\nexport default function GroupedMenuItemList(menuProps: GroupedMenuItemListProps) {\n const { menuDefinition, onClick, commandHandler, includedGroups } = menuProps;\n\n const { items, allowForLeadingIcons } = useMemo(() => {\n const groupsToInclude =\n includedGroups && includedGroups.length > 0\n ? includedGroups\n : // We're apparently laying out a single-column menu (presumably a context menu). In this\n // case, all groups should be included except ones that belong to a submenu.\n getAllGroups(menuDefinition).filter((g) => !('menuItem' in g.group));\n\n const sortedGroups = Object.values(groupsToInclude).sort(\n (a, b) => (a.group.order || 0) - (b.group.order || 0),\n );\n\n const itemArray: ItemInfo[] = [];\n\n sortedGroups.forEach((group) => {\n getOrderedGroupItems(group.id, menuDefinition.items).forEach((item) =>\n itemArray.push({ item, isLastItemInGroup: false }),\n );\n if (itemArray.length > 0) itemArray[itemArray.length - 1].isLastItemInGroup = true;\n });\n\n // No divider after last item in final group.\n if (itemArray.length > 0) itemArray[itemArray.length - 1].isLastItemInGroup = false;\n\n const allowSpaceForLeadingIcons = itemArray.some(\n (i) => 'iconPathBefore' in i.item && i.item.iconPathBefore,\n );\n\n return { items: itemArray, allowForLeadingIcons: allowSpaceForLeadingIcons };\n }, [includedGroups, menuDefinition]);\n\n // Create props for MenuItem component including setting hasDivider for the last item in a group\n const createMenuItemProps = ({ item, isLastItemInGroup }: ItemInfo) => {\n const menuItemProps = {\n className: 'papi-menu-item',\n label: item.label,\n tooltip: item.tooltip,\n iconPathBefore: 'iconPathBefore' in item ? item.iconPathBefore : undefined,\n iconPathAfter: 'iconPathAfter' in item ? item.iconPathAfter : undefined,\n hasDivider: isLastItemInGroup, // Set hasDivider to true for the last item in a group\n allowForLeadingIcons,\n };\n\n return menuItemProps;\n };\n\n const [firstItem] = items;\n\n if (!firstItem) return
    ;\n\n const divKey = firstItem.item.group;\n\n return (\n
    \n {items.map((itemInfo, index) => {\n const { item } = itemInfo;\n const menuItemProps = createMenuItemProps(itemInfo);\n if ('command' in item) {\n const key = item.group + index;\n return (\n ) => {\n onClick?.(event);\n commandHandler(item);\n }}\n {...menuItemProps}\n />\n );\n }\n return (\n \n );\n })}\n
    \n );\n}\n","import GroupedMenuItemList from '@/components/mui/grouped-menu-item-list.component';\nimport { MenuItemListProps } from '@/components/mui/menu-item.component';\nimport { MultiColumnMenu } from 'platform-bible-utils';\n\n/**\n * This component is internal; it does not need to be exposed to the outside world since it is not\n * useful on its own. Use either GridMenu or ContextMenu.\n */\nexport default function TopLevelMenu(props: MenuItemListProps) {\n const { menuDefinition, columnId } = props;\n\n const groupEntries = Object.entries(menuDefinition.groups);\n // Convert array of entries to array of objects with id and group properties\n const groups = groupEntries.map(([key, value]) => ({ id: key, group: value }));\n let includedGroups = groups.filter((g) => 'column' in g.group);\n\n // Check if column is provided and menuDefinition is a MultiColumnMenu\n if (\n columnId &&\n 'columns' in menuDefinition &&\n // Without this type assertion, TS doesn't know what columns is.\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n (menuDefinition as MultiColumnMenu).columns[columnId]\n ) {\n // When laying out a single column in a MultiColumnMenu, only include groups associated with\n // the provided column. Note: without the (annoying) redundant check that the included groups\n // have the colum field, TS doesn't think it exists.\n includedGroups = includedGroups.filter(\n (g) => 'column' in g.group && g.group.column === columnId,\n );\n }\n\n return ;\n}\n","import '@/components/mui/grid-menu.component.css';\nimport { GroupedMenuPropsBase } from '@/components/mui/grouped-menu-item-list.component';\nimport { CommandHandler } from '@/components/mui/menu-item.component';\nimport TopLevelMenu from '@/components/mui/top-level-menu.component';\nimport { Grid, List } from '@mui/material';\nimport {\n Localized,\n MenuColumnWithHeader,\n MultiColumnMenu,\n ReferencedItem,\n} from 'platform-bible-utils';\nimport { useMemo } from 'react';\n\ntype ColumnInfo = {\n /*\n * The ID (`${string}.${string}`) of a specific menu column.\n */\n id: ReferencedItem;\n\n /*\n * Metadata (label, order, etc.) for a specific menu column.\n */\n metadata: Localized;\n};\n\ntype MenuColumnProps = ColumnInfo &\n GroupedMenuPropsBase & {\n /** Additional css classes to help with unique styling of the menu column */\n className?: string;\n };\n\nexport type GridMenuInfo = {\n /** The menu object containing information about the columns, groups, and items to display. */\n multiColumnMenu: Localized;\n};\n\nexport type GridMenuProps = GridMenuInfo & {\n /** Optional unique identifier */\n id?: string;\n\n commandHandler: CommandHandler;\n\n /** Additional css classes to help with unique styling of the grid menu */\n className?: string;\n};\n\nfunction MenuColumn({\n commandHandler,\n menuDefinition,\n id,\n metadata,\n onClick,\n className,\n}: MenuColumnProps) {\n return (\n \n

    \n {metadata.label}\n

    \n {/* It would seem as though this List component were unnecessary, since it only contains one\n thing, but the \"dense\" property does affect the layout of the items (in a way I don't fully\n understand). There might be a better way. */}\n \n \n \n \n );\n}\n\nexport default function GridMenu({\n commandHandler,\n className,\n multiColumnMenu,\n id,\n}: GridMenuProps) {\n const { columns } = multiColumnMenu;\n\n const sortedColumns = useMemo(() => {\n const columnNumbers = new Map();\n Object.getOwnPropertyNames(columns).forEach((columnName: string) => {\n // We know for sure there is a (boolean) property 'isExtensible' that we are not interested in.\n if (columnName === 'isExtensible') return;\n // TS doesn't allow `columnName` above to be a ReferencedItem even though the type says it is\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const columnId = columnName as ReferencedItem;\n const column = columns[columnId];\n // As of right now (and hopefully forever after), all remaining properties of the\n // ColumnsWithHeaders object are columns whose property names are the IDs of the columns.\n // This is an additional (redundant) sanity check. Specifically we're interested in\n // MenuColumnWithHeader objects, which TypeScript now \"knows\" we have, but at runtime all we\n // can check for is that it's an object with a valid numeric order field. That's likely good\n // enough.\n if (\n typeof column === 'object' &&\n typeof column.order === 'number' &&\n !Number.isNaN(column.order)\n )\n columnNumbers.set(column.order, { id: columnId, metadata: column });\n else\n console.warn(\n `Property ${columnName} (${typeof column}) on menu ${id} is not a valid column and is being ignored. This might indicate data corruption`,\n );\n });\n\n // Extract values and sort them based on the 'order' property\n return Array.from(columnNumbers.values()).sort((a, b) => {\n return (a.metadata.order || 0) - (b.metadata.order || 0);\n });\n }, [columns, id]);\n\n // We might need something like this if we need to be able to prevent empty columns\n // sortedColumns.filter((c) => multiColumnMenu.groups.some((g) => 'column' in g && (g as .column)...\n\n return (\n \n {sortedColumns.map((col, index) => (\n \n ))}\n \n );\n}\n","import { useEffect, useRef, useState } from 'react';\n\nexport type UsePromiseOptions = {\n /**\n * Whether to leave the value as the most recent resolved promise value or set it back to\n * defaultValue while running the promise again. Defaults to true\n */\n preserveValue?: boolean;\n};\n\n/** Set up defaults for options for usePromise hook */\nfunction getUsePromiseOptionsDefaults(options: UsePromiseOptions): UsePromiseOptions {\n return {\n preserveValue: true,\n ...options,\n };\n}\n\n/**\n * Awaits a promise and returns a loading value while the promise is unresolved\n *\n * @param promiseFactoryCallback A function that returns the promise to await. If this callback is\n * undefined, the current value will be returned (defaultValue unless it was previously changed\n * and `options.preserveValue` is true), and there will be no loading.\n *\n * WARNING: MUST BE STABLE - const or wrapped in useCallback. The reference must not be updated\n * every render\n * @param defaultValue The initial value to return while first awaiting the promise. If\n * `options.preserveValue` is false, this value is also shown while awaiting the promise on\n * subsequent calls.\n *\n * Note: this parameter is internally assigned to a `ref`, so changing it will not cause any hooks\n * to re-run with its new value. This means that, if the `promiseFactoryCallback` changes and\n * `options.preserveValue` is `false`, the returned value will be set to the current\n * `defaultValue`. However, the returned value will not be updated if`defaultValue` changes.\n * @param options Various options for adjusting how this hook runs the `promiseFactoryCallback`\n *\n * Note: this parameter is internally assigned to a `ref`, so changing it will not cause any hooks\n * to re-run with its new value. However, the latest `options.preserveValue` will always be used\n * appropriately to determine whether to preserve the returned value when changing the\n * `promiseFactoryCallback`\n * @returns `[value, isLoading]`\n *\n * - `value`: the current value for the promise, either the defaultValue or the resolved promise value\n * - `isLoading`: whether the promise is waiting to be resolved\n */\nconst usePromise = (\n promiseFactoryCallback: (() => Promise) | undefined,\n defaultValue: T,\n options: UsePromiseOptions = {},\n): [value: T, isLoading: boolean] => {\n // Use defaultValue as a ref so it doesn't update dependency arrays\n const defaultValueRef = useRef(defaultValue);\n defaultValueRef.current = defaultValue;\n // Use options as a ref so it doesn't update dependency arrays\n const optionsDefaultedRef = useRef(options);\n optionsDefaultedRef.current = getUsePromiseOptionsDefaults(optionsDefaultedRef.current);\n\n const [value, setValue] = useState(() => defaultValueRef.current);\n const [isLoading, setIsLoading] = useState(true);\n useEffect(() => {\n let promiseIsCurrent = true;\n // If a promiseFactoryCallback was provided, we are loading. Otherwise, there is no loading to do\n setIsLoading(!!promiseFactoryCallback);\n (async () => {\n // If there is a callback to run, run it\n if (promiseFactoryCallback) {\n const result = await promiseFactoryCallback();\n // If the promise was not already replaced, update the value\n if (promiseIsCurrent) {\n setValue(() => result);\n setIsLoading(false);\n }\n }\n })();\n\n return () => {\n // Mark this promise as old and not to be used\n promiseIsCurrent = false;\n if (!optionsDefaultedRef.current.preserveValue) setValue(() => defaultValueRef.current);\n };\n }, [promiseFactoryCallback]);\n\n return [value, isLoading];\n};\nexport default usePromise;\n","\"use client\";\n\nimport createSvgIcon from './utils/createSvgIcon';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nexport default createSvgIcon( /*#__PURE__*/_jsx(\"path\", {\n d: \"M3 18h18v-2H3zm0-5h18v-2H3zm0-7v2h18V6z\"\n}), 'Menu');","import GridMenu from '@/components/mui/grid-menu.component';\nimport { Command, CommandHandler } from '@/components/mui/menu-item.component';\nimport usePromise from '@/hooks/use-promise.hook';\nimport { Menu as MenuIcon } from '@mui/icons-material';\nimport { Drawer, IconButton } from '@mui/material';\nimport { Localized, MultiColumnMenu } from 'platform-bible-utils';\nimport {\n MouseEvent,\n MutableRefObject,\n PropsWithChildren,\n useCallback,\n useEffect,\n useState,\n} from 'react';\n\nexport interface MultiColumnMenuProvider {\n (isSupportAndDevelopment: boolean): Promise>;\n}\n\nexport type HamburgerMenuButtonProps = PropsWithChildren & {\n /** The handler to use for menu commands (and eventually toolbar commands). */\n commandHandler: CommandHandler;\n\n /**\n * Optional reference to the \"div\" container that determines the where the menu should appear. If\n * not defined, then (1,1) used.\n */\n containerRef?: MutableRefObject;\n\n /**\n * The delegate to use to get the menu data. If not specified or if it returns undefined, the data\n * in normalMenu or fullMenu property will be used.\n */\n menuProvider?: MultiColumnMenuProvider;\n\n /**\n * The menu data to show when the menu is opened if the menuProvider property is not defined.\n * (This allows for a default or test-only static menu to be used.)\n */\n normalMenu?: Localized;\n\n /**\n * The menu data to show for \"full\" menu (when opened with the SHIFT key pressed) if the\n * menuProvider property is not defined. (This allows for a default or test-only static menu to be\n * used.)\n */\n fullMenu?: Localized;\n\n /** Additional css class(es) to help with unique styling of the sub-components */\n className?: string;\n\n /** Value to use as prefix for ARIA labels on interactive sub-components */\n ariaLabelPrefix?: string;\n};\n\nexport default function HamburgerMenuButton({\n menuProvider,\n normalMenu,\n fullMenu,\n commandHandler,\n containerRef,\n className,\n ariaLabelPrefix,\n children,\n}: HamburgerMenuButtonProps) {\n const [isMenuOpen, setMenuOpen] = useState(false);\n const [showFullMenu, setShowFullMenu] = useState(false);\n\n const handleMenuItemClick = useCallback(() => {\n if (isMenuOpen) setMenuOpen(false);\n setShowFullMenu(false);\n }, [isMenuOpen]);\n\n const handleMenuButtonClick = useCallback((e: MouseEvent) => {\n e.stopPropagation();\n setMenuOpen((prevIsOpen) => {\n const isOpening = !prevIsOpen;\n if (isOpening && e.shiftKey) setShowFullMenu(true);\n else if (!isOpening) setShowFullMenu(false);\n return isOpening;\n });\n }, []);\n\n const menuCommandHandler = useCallback(\n (command: Command) => {\n handleMenuItemClick();\n return commandHandler(command);\n },\n [commandHandler, handleMenuItemClick],\n );\n\n const [offset, setOffset] = useState({ top: 1, left: 1 });\n\n useEffect(() => {\n if (isMenuOpen) {\n const node = containerRef?.current;\n if (node) {\n const rect = node.getBoundingClientRect();\n const scrollTop = window.scrollY;\n const scrollLeft = window.scrollX;\n const top = rect.top + scrollTop + node.clientHeight;\n const left = rect.left + scrollLeft;\n setOffset({ top, left });\n }\n }\n }, [isMenuOpen, containerRef]);\n\n const [normalMenuData] = usePromise(\n useCallback(async () => {\n return menuProvider?.(false) ?? normalMenu;\n // isMenuOpen needs to be included for the menu contents to reevaluate when reopened\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [menuProvider, normalMenu, isMenuOpen]),\n normalMenu,\n );\n\n const [fullMenuData] = usePromise(\n useCallback(async () => {\n return menuProvider?.(true) ?? fullMenu ?? normalMenuData;\n // isMenuOpen needs to be included for the menu contents to reevaluate when reopened\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [menuProvider, fullMenu, normalMenuData, isMenuOpen]),\n fullMenu ?? normalMenuData,\n );\n\n const menu = showFullMenu && fullMenuData ? fullMenuData : normalMenuData;\n\n return (\n <>\n \n {children ?? }\n \n \n {menu ? (\n \n ) : undefined}\n \n \n );\n}\n","import '@/components/mui/icon-button.component.css';\nimport { IconButton as MuiIconButton } from '@mui/material';\nimport { MouseEventHandler, PropsWithChildren } from 'react';\n\nexport type IconButtonProps = PropsWithChildren<{\n /** Optional unique identifier */\n id?: string;\n /**\n * Required. Used as both the tooltip (aka, title) and the aria-label (used for accessibility,\n * testing, etc.), unless a distinct tooltip is supplied.\n */\n label: string;\n /**\n * Enabled status of button\n *\n * @default false\n */\n isDisabled?: boolean;\n /** Optional tooltip to display if different from the aria-label. */\n tooltip?: string;\n /** If true, no tooltip will be displayed. */\n isTooltipSuppressed?: boolean;\n /**\n * If given, uses a negative margin to counteract the padding on one side (this is often helpful\n * for aligning the left or right side of the icon with content above or below, without ruining\n * the border size and shape).\n *\n * @default false\n */\n adjustMarginToAlignToEdge?: 'end' | 'start' | false;\n /**\n * The size of the component. small is equivalent to the dense button styling.\n *\n * @default false\n */\n size: 'small' | 'medium' | 'large';\n /** Additional css classes to help with unique styling of the button */\n className?: string;\n /** Optional click handler */\n onClick?: MouseEventHandler;\n}>;\n\n/**\n * Iconic button a user can click to do something\n *\n * Thanks to MUI for heavy inspiration and documentation\n * https://mui.com/material-ui/getting-started/overview/\n */\nfunction IconButton({\n id,\n label,\n isDisabled = false,\n tooltip,\n isTooltipSuppressed = false,\n adjustMarginToAlignToEdge = false,\n size = 'medium',\n className,\n onClick,\n children,\n}: IconButtonProps) {\n return (\n \n {children /* the icon to display */}\n \n );\n}\n\nexport default IconButton;\n","import { cn } from '@/utils/shadcn-ui.util';\nimport { LoaderCircle, LucideProps } from 'lucide-react';\nimport { forwardRef } from 'react';\n\nexport type SpinnerProps = LucideProps;\n\nconst Spinner = forwardRef(({ className, ...props }, ref) => {\n return (\n \n );\n});\n\nSpinner.displayName = 'Spinner';\n\nexport default Spinner;\n","import { Input as ShadInput } from '@/components/shadcn-ui/input';\nimport { Label as ShadLabel } from '@/components/shadcn-ui/label';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { ChangeEventHandler, FocusEventHandler } from 'react';\n\nexport type TextFieldProps = {\n /** Optional unique identifier */\n id?: string;\n /**\n * If `true`, the component is disabled.\n *\n * @default false\n */\n isDisabled?: boolean;\n /**\n * If `true`, the label is displayed in an error state.\n *\n * @default false\n */\n hasError?: boolean;\n /**\n * If `true`, the input will take up the full width of its container.\n *\n * @default false\n */\n isFullWidth?: boolean;\n /** Text that gives the user instructions on what contents the TextField expects */\n helperText?: string;\n /** The title of the TextField */\n label?: string;\n /** The short hint displayed in the `input` before the user enters a value. */\n placeholder?: string;\n /**\n * If `true`, the label is displayed as required and the `input` element is required.\n *\n * @default false\n */\n isRequired?: boolean;\n /** Additional css classes to help with unique styling of the text field */\n className?: string;\n /** Starting value for the text field if it is not controlled */\n defaultValue?: string | number;\n /** Value of the text field if controlled */\n value?: string | number;\n /** Triggers when content of textfield is changed */\n onChange?: ChangeEventHandler;\n /** Triggers when textfield gets focus */\n onFocus?: FocusEventHandler;\n /** Triggers when textfield loses focus */\n onBlur?: FocusEventHandler;\n};\n\n/**\n * Text input field\n *\n * Thanks to Shadcn for heavy inspiration and documentation\n * https://ui.shadcn.com/docs/components/input#with-label\n */\nfunction TextField({\n id,\n isDisabled = false,\n hasError = false,\n isFullWidth = false,\n helperText,\n label,\n placeholder,\n isRequired = false,\n className,\n defaultValue,\n value,\n onChange,\n onFocus,\n onBlur,\n}: TextFieldProps) {\n return (\n
    \n {`${label}${isRequired ? '*' : ''}`}\n \n

    {helperText}

    \n
    \n );\n}\n\nexport default TextField;\n","import HamburgerMenuButton, {\n MultiColumnMenuProvider,\n} from '@/components/mui/hamburger-menu-button.component';\nimport { CommandHandler } from '@/components/mui/menu-item.component';\nimport '@/components/mui/toolbar.component.css';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { AppBar, Toolbar as MuiToolbar } from '@mui/material';\nimport { PropsWithChildren, useRef } from 'react';\n\nexport type ToolbarProps = PropsWithChildren<{\n /** The handler to use for menu commands (and eventually toolbar commands). */\n commandHandler: CommandHandler;\n\n /**\n * The optional delegate to use to get the menu data. If not specified, the \"hamburger\" menu will\n * not display.\n */\n menuProvider?: MultiColumnMenuProvider;\n\n /** Optional unique identifier */\n id?: string;\n\n /** Additional css classes to help with unique styling of the toolbar */\n className?: string;\n}>;\n\nexport default function Toolbar({\n menuProvider,\n commandHandler,\n className,\n id,\n children,\n}: ToolbarProps) {\n // This ref will always be defined\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const containerRef = useRef(undefined!);\n\n return (\n
    \n \n \n {menuProvider ? (\n \n ) : undefined}\n {children ?
    {children}
    : undefined}\n \n
    \n
    \n );\n}\n","import React from 'react';\nimport { cva, type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst alertVariants = cva(\n 'tw-relative tw-w-full tw-rounded-lg tw-border tw-p-4 [&>svg~*]:tw-pl-7 [&>svg+div]:tw-translate-y-[-3px] [&>svg]:tw-absolute [&>svg]:tw-left-4 [&>svg]:tw-top-4 [&>svg]:tw-text-foreground',\n {\n variants: {\n variant: {\n default: 'tw-bg-background tw-text-foreground',\n destructive:\n 'tw-border-destructive/50 tw-text-destructive dark:tw-border-destructive [&>svg]:tw-text-destructive',\n },\n },\n defaultVariants: {\n variant: 'default',\n },\n },\n);\n\nconst Alert = React.forwardRef<\n HTMLDivElement,\n React.HTMLAttributes & VariantProps\n>(({ className, variant, ...props }, ref) => (\n
    \n));\nAlert.displayName = 'Alert';\n\nconst AlertTitle = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n {/* added because of https://github.com/jsx-eslint/eslint-plugin-jsx-a11y/blob/main/docs/rules/heading-has-content.md */}\n {props.children}{' '}\n \n ),\n);\nAlertTitle.displayName = 'AlertTitle';\n\nconst AlertDescription = React.forwardRef<\n HTMLParagraphElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n
    \n));\nAlertDescription.displayName = 'AlertDescription';\n\nexport { Alert, AlertTitle, AlertDescription };\n","import React from 'react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Card = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nCard.displayName = 'Card';\n\nconst CardHeader = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nCardHeader.displayName = 'CardHeader';\n\nconst CardTitle = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n {/* added because of https://github.com/jsx-eslint/eslint-plugin-jsx-a11y/blob/main/docs/rules/heading-has-content.md */}\n {props.children}\n \n ),\n);\nCardTitle.displayName = 'CardTitle';\n\nconst CardDescription = React.forwardRef<\n HTMLParagraphElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n

    \n));\nCardDescription.displayName = 'CardDescription';\n\nconst CardContent = React.forwardRef>(\n ({ className, ...props }, ref) => (\n

    \n ),\n);\nCardContent.displayName = 'CardContent';\n\nconst CardFooter = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nCardFooter.displayName = 'CardFooter';\n\nexport { Card, CardHeader, CardFooter, CardTitle, CardDescription, CardContent };\n","import { ComponentProps } from 'react';\nimport { toast as sonner, Toaster } from 'sonner';\n\ntype SonnerProps = ComponentProps;\n\nfunction Sonner({ ...props }: SonnerProps) {\n return (\n \n );\n}\n\n// The re-export of the sonner function was added manually\nexport { Sonner, sonner };\n","import React from 'react';\nimport * as SliderPrimitive from '@radix-ui/react-slider';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Slider = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n \n \n \n));\nSlider.displayName = SliderPrimitive.Root.displayName;\n\nexport { Slider };\n","import React from 'react';\nimport * as SwitchPrimitives from '@radix-ui/react-switch';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Switch = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n));\nSwitch.displayName = SwitchPrimitives.Root.displayName;\n\nexport { Switch };\n","import React from 'react';\nimport * as TabsPrimitive from '@radix-ui/react-tabs';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport const Tabs = TabsPrimitive.Root;\n\nexport type TabsListProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport type TabsTriggerProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport type TabsContentProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport const TabsList = React.forwardRef<\n React.ElementRef,\n TabsListProps\n>(({ className, ...props }, ref) => (\n \n));\nTabsList.displayName = TabsPrimitive.List.displayName;\n\nexport const TabsTrigger = React.forwardRef<\n React.ElementRef,\n TabsTriggerProps\n>(({ className, ...props }, ref) => (\n \n));\nTabsTrigger.displayName = TabsPrimitive.Trigger.displayName;\n\nexport const TabsContent = React.forwardRef<\n React.ElementRef,\n TabsContentProps\n>(({ className, ...props }, ref) => (\n \n));\nTabsContent.displayName = TabsPrimitive.Content.displayName;\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Download } from 'lucide-react';\n\ntype InstallButtonProps = {\n /** The installing boolean value determines the state of the button. */\n isInstalling: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n /** Optional text for the button. */\n buttonText?: string;\n} & ButtonProps;\n\n/**\n * The InstallButton component is a button designed for initiating installs. It includes visuals for\n * active installing and idle states.\n *\n * @param isInstalling The installing boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @param buttonText Optional text for the button.\n * @returns A install button.\n */\nexport default function InstallButton({\n isInstalling,\n handleClick,\n buttonText,\n className,\n ...props\n}: InstallButtonProps) {\n return (\n \n {isInstalling ? (\n \n ) : (\n <>\n \n {buttonText}\n \n )}\n \n );\n}\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\n\ntype EnableButtonProps = {\n /** The enabling boolean value determines the state of the button. */\n isEnabling: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n} & ButtonProps;\n\n/**\n * The EnableButton component is a button designed for initiating enabling of downloads. It includes\n * visuals for active enabling and idle states.\n *\n * @param isEnabling The enabling boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @returns A button that can be used to enable.\n */\nexport default function EnableButton({\n isEnabling,\n handleClick,\n className,\n ...props\n}: EnableButtonProps) {\n return (\n \n {isEnabling ? (\n <>\n \n Enabling...\n \n ) : (\n 'Enable'\n )}\n \n );\n}\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\n\ntype DisableButtonProps = {\n /** The disabling boolean value determines the state of the button. */\n isDisabling: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n} & ButtonProps;\n\n/**\n * The DisableButton component is a button designed for initiating disabling of downloads. It\n * includes visuals for active disabling and idle states.\n *\n * @param isDisabling The disabling boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @returns A button that can be used to disable.\n */\nexport default function DisableButton({\n isDisabling,\n handleClick,\n className,\n ...props\n}: DisableButtonProps) {\n return (\n \n {isDisabling ? (\n <>\n \n Disabling...\n \n ) : (\n 'Disable'\n )}\n \n );\n}\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\n\ntype UpdateButtonProps = {\n /** The updating boolean value determines the state of the button. */\n isUpdating: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n} & ButtonProps;\n\n/**\n * The UpdateButton component is a button designed for initiating updates for downloaded extensions.\n * It includes visuals for active updating and idle states.\n *\n * @param isUpdating The updating boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @returns A button that can be used to update.\n */\nexport default function UpdateButton({\n isUpdating,\n handleClick,\n className,\n ...props\n}: UpdateButtonProps) {\n return (\n \n {isUpdating ? (\n <>\n \n Updating...\n \n ) : (\n 'Update'\n )}\n \n );\n}\n","import { cn } from '@/utils/shadcn-ui.util';\nimport Markdown, { MarkdownToJSX } from 'markdown-to-jsx';\nimport { useMemo } from 'react';\n\ninterface MarkdownRendererProps {\n /** Optional unique identifier */\n id?: string;\n /** The markdown string to render */\n markdown: string;\n className?: string;\n /**\n * The [`target` attribute for `a` html\n * tags](https://developer.mozilla.org/en-US/docs/Web/HTML/Element/a#target). Defaults to not\n * adding a `target` to `a` tags\n */\n anchorTarget?: string;\n}\n\n/**\n * This component renders markdown content given a markdown string. It uses typography styles from\n * the platform.\n *\n * @param markdown The markdown string to render.\n * @param id Optional unique identifier\n * @returns A div containing the rendered markdown content.\n */\nexport default function MarkdownRenderer({\n id,\n markdown,\n className,\n anchorTarget,\n}: MarkdownRendererProps) {\n const options: MarkdownToJSX.Options = useMemo(\n () => ({\n overrides: {\n a: {\n props: {\n target: anchorTarget,\n },\n },\n },\n }),\n [anchorTarget],\n );\n return (\n
    \n {markdown}\n
    \n );\n}\n","import { Filter, ChevronDown } from 'lucide-react';\nimport { forwardRef } from 'react';\nimport { Button } from '@/components/shadcn-ui/button';\n\n/**\n * The FilterButton component is a button designed for initiating filtering of data. It is designed\n * to be used with the dropdown menu. It uses forwardRef to pass the button to the dropdown trigger\n * asChild.\n *\n * @returns A button that can be used to filter.\n */\nconst FilterButton = forwardRef((props, ref) => {\n return (\n \n \n Filter\n \n \n );\n});\n\nexport default FilterButton;\n","import {\n DropdownMenu,\n DropdownMenuTrigger,\n DropdownMenuContent,\n DropdownMenuLabel,\n DropdownMenuGroup,\n DropdownMenuCheckboxItem,\n DropdownMenuRadioItem,\n DropdownMenuSeparator,\n} from '@/components/shadcn-ui/dropdown-menu';\nimport FilterButton from './buttons/filter-button.component';\n\nexport enum DropdownMenuItemType {\n Check,\n Radio,\n}\n\nexport type DropdownItem = {\n /** The label is the text that will be displayed on the dropdown item. */\n label: string;\n /** The itemType determines the DropdownMenuItemType type as either Check or Radio. */\n itemType: DropdownMenuItemType;\n /** The onClick function is called when the item is clicked. */\n onClick: () => void;\n};\n\nexport type DropdownGroup = {\n /**\n * The label is the text that will be displayed on the dropdown group. It is used to categorize\n * the items in the group.\n */\n label: string;\n /** The items array contains the items that will be displayed in the dropdown group */\n items: DropdownItem[];\n};\n\nexport type FilterDropdownProps = {\n /** Object unique identifier */\n id?: string;\n /** The groups array contains the groups that will be displayed in the dropdown */\n groups: DropdownGroup[];\n}; // TODO: extend the props later\n\n/**\n * The FilterDropdown component is a dropdown designed for filtering content. It includes groups of\n * items that can be checkboxes or radio items.\n *\n * @param id Optional unique identifier\n * @param groups The groups array contains the groups that will be displayed in the dropdown\n * @returns A filter dropdown.\n */\nexport default function FilterDropdown({ id, groups }: FilterDropdownProps) {\n return (\n
    \n {/* TODO: remove this once the DropDown Menu shadcn has an id prop */}\n \n \n \n \n \n {groups.map((group) => (\n
    \n {group.label}\n \n {group.items.map((item) => (\n
    \n {item.itemType === DropdownMenuItemType.Check ? (\n \n {item.label}\n \n ) : (\n \n {item.label}\n \n )}\n
    \n ))}\n
    \n \n
    \n ))}\n
    \n
    \n
    \n );\n}\n","interface NoExtensionsFoundProps {\n /** Optional unique identifier */\n id?: string;\n /** The message to display */\n message: string;\n}\n/**\n * This component displays a message to the user when no extensions are found in the marketplace.\n *\n * @param id Optional unique identifier\n * @param message The message to display.\n * @returns {JSX.Element} - Returns the message component that displays the message to the user.\n */\nexport default function NoExtensionsFound({ id, message }: NoExtensionsFoundProps) {\n return (\n
    \n
    \n

    {message}

    \n
    \n
    \n );\n}\n","import { CircleHelp, Link as LucideLink, User } from 'lucide-react';\nimport { NumberFormat } from 'platform-bible-utils';\n\n/** Interface that stores the parameters passed to the More Info component */\ninterface MoreInfoProps {\n /** Optional unique identifier */\n id?: string;\n /** The category of the extension */\n category: string;\n /** The number of downloads for the extension */\n downloads: Record;\n /** The languages supported by the extension */\n languages: string[];\n /** The URL to the more info page of the extension */\n moreInfoUrl: string;\n}\n/**\n * This component displays the more info section of the extension which includes the category,\n * number of downloads, languages, and links to the website and support\n *\n * @param id Optional unique identifier\n * @param category The category of the extension\n * @param downloads The number of downloads for the extension\n * @param languages The languages supported by the extension\n * @param moreInfoUrl The URL to the more info page of the extension\n * @returns {JSX.Element} - Returns the more info component that displays the category, number of\n * downloads, languages, and links to the website and support\n */\nexport default function MoreInfo({\n id,\n category,\n downloads,\n languages,\n moreInfoUrl,\n}: MoreInfoProps) {\n /**\n * This constant formats the number of downloads into a more readable format.\n *\n * @example 1000 -> 1K\n *\n * @example 1000000 -> 1M\n *\n * @returns The formatted number of downloads\n */\n const numberFormatted = new NumberFormat('en', {\n notation: 'compact',\n compactDisplay: 'short',\n }).format(Object.values(downloads).reduce((a: number, b: number) => a + b, 0));\n\n /** This function scrolls the window to the bottom of the page. */\n const handleScrollToBottom = () => {\n window.scrollTo(0, document.body.scrollHeight);\n };\n\n return (\n \n
    \n
    \n {category}\n
    \n CATEGORY\n
    \n
    \n
    \n
    \n \n {numberFormatted}\n
    \n USERS\n
    \n
    \n
    \n
    \n {languages.slice(0, 3).map((locale) => (\n \n {locale.toUpperCase()}\n \n ))}\n
    \n {languages.length > 3 && (\n handleScrollToBottom()}\n className=\"tw-text-xs tw-text-gray-500 tw-underline\"\n >\n +{languages.length - 3} more languages\n \n )}\n
    \n
    \n
    \n \n Website\n \n \n \n Support\n \n \n
    \n
    \n );\n}\n","import { useState } from 'react';\n\nexport type VersionInformation = {\n /** Date the version was published */\n date: string;\n /** Description of the changes in the version */\n description: string;\n};\n\n/** Type to store the version history information */\nexport type VersionHistoryType = Record;\n\n/** Interface that stores the parameters passed to the Version History component */\ninterface VersionHistoryProps {\n /** Optional unique identifier */\n id?: string;\n /** Object containing the versions mapped with their information */\n versionHistory: VersionHistoryType;\n}\n\n/**\n * Component to render the version history information shown in the footer component. Lists the 5\n * most recent versions, with the options to show all versions by pressing a button.\n *\n * @param versionHistory Object containing the versions mapped with their information\n * @param id Optional unique identifier\n * @returns Rendered version history for the Footer component\n */\nexport default function VersionHistory({ id, versionHistory }: VersionHistoryProps) {\n const [showAllVersions, setShowAllVersions] = useState(false);\n const currentDate = new Date();\n\n /**\n * Function to format the time string for the version history in the form of 'X year(s) ago'.\n *\n * @param dateString ISO Date string to determine the time string from\n * @returns Formatted time string\n */\n function formatTimeString(dateString: string) {\n const date = new Date(dateString);\n const dateDiff = new Date(currentDate.getTime() - date.getTime());\n const yearDiff = dateDiff.getUTCFullYear() - 1970;\n const monthDiff = dateDiff.getUTCMonth();\n const dayDiff = dateDiff.getUTCDate() - 1;\n\n // Determines how long ago the version was published\n let timeString = '';\n if (yearDiff > 0) {\n timeString = `${yearDiff.toString()} year${yearDiff === 1 ? '' : 's'} ago`;\n } else if (monthDiff > 0) {\n timeString = `${monthDiff.toString()} month${monthDiff === 1 ? '' : 's'} ago`;\n } else if (dayDiff === 0) {\n timeString = 'today';\n } else {\n timeString = `${dayDiff.toString()} day${dayDiff === 1 ? '' : 's'} ago`;\n }\n\n return timeString;\n }\n\n // Sorts the version history by version number\n const sortedEntries = Object.entries(versionHistory).sort((a, b) => b[0].localeCompare(a[0]));\n\n return (\n
    \n

    What`s New

    \n
      \n {(showAllVersions ? sortedEntries : sortedEntries.slice(0, 5)).map((entry) => (\n
      \n
      \n
    • \n {entry[1].description}\n
    • \n
      \n
      \n
      Version {entry[0]}
      \n
      {formatTimeString(entry[1].date)}
      \n
      \n
      \n ))}\n
    \n {sortedEntries.length > 5 && (\n setShowAllVersions(!showAllVersions)}\n className=\"tw-text-xs tw-text-gray-500 tw-underline\"\n >\n {showAllVersions ? 'Show Less Version History' : 'Show All Version History'}\n \n )}\n
    \n );\n}\n","import { useMemo } from 'react';\nimport { formatBytes } from 'platform-bible-utils';\nimport VersionHistory, { VersionHistoryType } from './version-history.component';\n\n/** Interface to store the parameters passed to the Footer component */\ninterface FooterProps {\n /** Optional unique identifier */\n id?: string;\n /** Name of the publisher */\n publisherDisplayName: string;\n /** Size of the extension file in bytes */\n fileSize: number;\n /** List of language codes supported by the extension */\n locales: string[];\n /** Object containing the version history mapped with their information */\n versionHistory: VersionHistoryType;\n}\n\n/**\n * Component to render the footer for the extension details which contains information on the\n * publisher, version history, languages, and file size.\n *\n * @param id Optional unique identifier\n * @param publisherDisplayName Name of the publisher\n * @param fileSize Size of the extension file in bytes\n * @param locales List of language codes supported by the extension\n * @param versionHistory Object containing the version history mapped with their information\n * @returns The rendered Footer component\n */\nexport default function Footer({\n id,\n publisherDisplayName,\n fileSize,\n locales,\n versionHistory,\n}: FooterProps) {\n /** Formats the file size into a human-readable format */\n const formattedFileSize = useMemo(() => formatBytes(fileSize), [fileSize]);\n\n /**\n * This function gets the display names of the languages based on the language codes.\n *\n * @param codes The list of language codes\n * @returns The list of language names\n */\n const getLanguageNames = (codes: string[]) => {\n const displayNames = new Intl.DisplayNames(navigator.language, { type: 'language' });\n return codes.map((code) => displayNames.of(code));\n };\n\n const languageNames = getLanguageNames(locales);\n\n return (\n
    \n
    \n \n
    \n
    \n

    Information

    \n
    \n

    \n Publisher\n {publisherDisplayName}\n Size\n {formattedFileSize}\n

    \n
    \n

    \n Languages\n {languageNames.join(', ')}\n

    \n
    \n
    \n
    \n
    \n
    \n );\n}\n","import { PlatformEvent, PlatformEventHandler } from 'platform-bible-utils';\nimport { useEffect } from 'react';\n\n/**\n * Adds an event handler to an event so the event handler runs when the event is emitted. Use\n * `papi.network.getNetworkEvent` to use a networked event with this hook.\n *\n * @param event The event to subscribe to.\n *\n * - If event is a `PlatformEvent`, that event will be used\n * - If event is undefined, the callback will not be subscribed. Useful if the event is not yet\n * available for example\n *\n * @param eventHandler The callback to run when the event is emitted\n *\n * WARNING: MUST BE STABLE - const or wrapped in useCallback. The reference must not be updated\n * every render\n */\nconst useEvent = (\n event: PlatformEvent | undefined,\n eventHandler: PlatformEventHandler,\n) => {\n useEffect(() => {\n // Do nothing if the event is not provided (in case the event is not yet available, for example)\n if (!event) return () => {};\n\n const unsubscriber = event(eventHandler);\n return () => {\n unsubscriber();\n };\n }, [event, eventHandler]);\n};\nexport default useEvent;\n","import { useCallback, useEffect } from 'react';\nimport { PlatformEvent, PlatformEventAsync, PlatformEventHandler } from 'platform-bible-utils';\nimport usePromise from './use-promise.hook';\n\nconst noopUnsubscriber = () => false;\n\n/**\n * Adds an event handler to an asynchronously subscribing/unsubscribing event so the event handler\n * runs when the event is emitted. Use `papi.network.getNetworkEvent` to use a networked event with\n * this hook.\n *\n * @param event The asynchronously (un)subscribing event to subscribe to.\n *\n * - If event is a `PlatformEvent` or `PlatformEventAsync`, that event will be used\n * - If event is undefined, the callback will not be subscribed. Useful if the event is not yet\n * available for example\n *\n * @param eventHandler The callback to run when the event is emitted\n *\n * WARNING: MUST BE STABLE - const or wrapped in useCallback. The reference must not be updated\n * every render\n */\nconst useEventAsync = (\n event: PlatformEvent | PlatformEventAsync | undefined,\n eventHandler: PlatformEventHandler,\n) => {\n // Subscribe to the event asynchronously\n const [unsubscribe] = usePromise(\n useCallback(async () => {\n // Do nothing if the event is not provided (in case the event is not yet available, for example)\n if (!event) return noopUnsubscriber;\n\n // Wrap subscribe and unsubscribe in promises to allow normal events to be used as well\n const unsub = await Promise.resolve(event(eventHandler));\n return async () => unsub();\n }, [eventHandler, event]),\n noopUnsubscriber,\n // We want the unsubscriber to return to default value immediately upon changing subscription\n // So the useEffect below will unsubscribe asap\n { preserveValue: false },\n );\n\n // Unsubscribe from the event asynchronously (but we aren't awaiting the unsub)\n useEffect(() => {\n return () => {\n if (unsubscribe !== noopUnsubscriber) {\n unsubscribe();\n }\n };\n }, [unsubscribe]);\n};\n\nexport default useEventAsync;\n"],"names":["twMergeCustom","extendTailwindMerge","cn","inputs","clsx","Input","React","className","type","props","ref","jsx","BookChapterInput","forwardRef","handleSearch","handleKeyDown","handleOnClick","handleSubmit","jsxs","ShadInput","event","e","History","P","R","s","n","N","B","O","S","K","g","k","x","T","X","V","w","L","G","A","H","C","I","y","q","U","m","l","h","c","E","D","i","a","o","u","v","f","d","b","J","DropdownMenu","DropdownMenuPrimitive","DropdownMenuTrigger","DropdownMenuGroup","DropdownMenuPortal","DropdownMenuSub","DropdownMenuRadioGroup","DropdownMenuSubTrigger","inset","children","ChevronRight","DropdownMenuSubContent","DropdownMenuContent","sideOffset","DropdownMenuItem","DropdownMenuCheckboxItem","checked","Check","DropdownMenuRadioItem","Circle","DropdownMenuLabel","DropdownMenuSeparator","DropdownMenuShortcut","BookMenuItem","bookId","handleSelectBook","isSelected","handleHighlightBook","bookType","ShadDropdownMenuItem","Canon","ChapterSelect","handleSelectChapter","endChapter","activeChapter","highlightedChapter","handleHighlightedChapter","chapters","_","handleMouse","useCallback","chapterNumber","chapter","GoToMenuItem","handleSort","handleLocationHistory","handleBookmarks","ShadDropdownMenuLabel","ArrowDownWideNarrow","Clock","Bookmark","ALL_BOOK_IDS","BOOK_TYPE_LABELS","BOOK_TYPE_ARRAY","SCROLL_OFFSET","SEARCH_QUERY_FORMATS","fetchGroupedBooks","fetchEndChapter","getChaptersForBook","getAllEnglishNames","isValidBookEnglishName","bookName","getBookIdFromEnglishName","formattedBookName","BookChapterControl","scrRef","searchQuery","setSearchQuery","useState","selectedBookId","setSelectedBookId","setHighlightedChapter","highlightedBookId","setHighlightedBookId","isContentOpen","setIsContentOpen","isContentOpenDelayed","setIsContentOpenDelayed","inputRef","useRef","contentRef","menuItemRef","fetchFilteredBooks","englishNameLowerCase","normalizedQuery","handleSearchInput","searchString","shouldPreventAutoClosing","controlMenuState","open","updateReference","shouldClose","verse","handleInputSubmit","format","matches","book","englishName","handleKeyDownInput","handleKeyDownContent","key","handleKeyDownMenuItem","chapterOffSet","useEffect","useLayoutEffect","scrollTimeout","scrollPosition","ShadDropdownMenu","ShadDropdownMenuTrigger","ShadDropdownMenuContent","bookTypeIndex","element","ShadDropdownMenuSeparator","buttonVariants","cva","Button","variant","size","asChild","Slot","labelVariants","Label","LabelPrimitive","RadioGroup","RadioGroupPrimitive","RadioGroupItem","Popover","PopoverPrimitive","PopoverTrigger","PopoverContent","align","DialogPortal","DialogPrimitive","DialogOverlay","DialogContent","DialogTitle","DialogDescription","Command","CommandPrimitive","CommandInput","Search","CommandList","CommandEmpty","CommandGroup","CommandSeparator","CommandItem","getOptionLabelDefault","option","ComboBox","id","options","buttonClassName","popoverContentClassName","value","onChange","getOptionLabel","buttonPlaceholder","textPlaceholder","commandEmptyMessage","buttonVariant","dir","isDisabled","setOpen","ChevronsUpDown","ChapterRangeSelector","startChapter","handleSelectStartChapter","handleSelectEndChapter","chapterCount","chapterOptions","useMemo","index","Fragment","BookSelectionMode","BOOK_SELECTOR_STRING_KEYS","localizeString","strings","BookSelector","handleBookSelectionModeChange","currentBookName","onSelectBooks","selectedBookIds","localizedStrings","currentBookText","chooseText","chooseBooksText","bookSelectionMode","setBookSelectionMode","onSelectionModeChange","newMode","DataTableViewOptions","table","FilterIcon","column","Select","SelectPrimitive","SelectGroup","SelectValue","SelectTrigger","ChevronDown","SelectScrollUpButton","ChevronUp","SelectScrollDownButton","SelectContent","position","SelectLabel","SelectItem","SelectSeparator","DataTablePagination","pageSize","ArrowLeftIcon","ChevronLeftIcon","ChevronRightIcon","ArrowRightIcon","Table","stickyHeader","TableHeader","TableBody","TableFooter","TableRow","TableHead","TableCell","TableCaption","DataTable","columns","data","enablePagination","showPaginationControls","showColumnVisibilityControls","onRowClickHandler","sorting","setSorting","columnFilters","setColumnFilters","columnVisibility","setColumnVisibility","rowSelection","setRowSelection","useReactTable","getCoreRowModel","getPaginationRowModel","getSortedRowModel","getFilteredRowModel","headerGroup","header","flexRender","_a","row","cell","OccurrencesTable","occurrenceData","setScriptureReference","referenceHeaderText","occurrenceHeaderText","occurrences","uniqueOccurrences","occurrence","uniqueOccurrence","deepEqual","Checkbox","CheckboxPrimitive","getLinesFromUSFM","text","getNumberFromUSFM","regex","match","getBookNumFromId","getStatusForItem","item","approvedItems","unapprovedItems","toggleVariants","Toggle","TogglePrimitive","ToggleGroupContext","ToggleGroup","ToggleGroupPrimitive","ToggleGroupItem","context","getSortingIcon","sortDirection","ArrowUpIcon","ArrowDownIcon","ArrowUpDownIcon","inventoryItemColumn","itemLabel","inventoryAdditionalItemColumn","additionalItemLabel","additionalItemIndex","inventoryCountColumn","countLabel","statusChangeHandler","changedItems","newStatus","onApprovedItemsChange","onUnapprovedItemsChange","newApprovedItems","validItem","newUnapprovedItems","unapprovedItem","inventoryStatusColumn","statusLabel","status","CircleCheckIcon","CircleXIcon","CircleHelpIcon","INVENTORY_STRING_KEYS","filterItemData","itemData","statusFilter","textFilter","filteredItemData","createTableData","scriptureRef","itemRegex","tableData","currentBook","currentChapter","currentVerse","line","items","itemIndex","existingItem","tableEntry","newReference","substring","newItem","Inventory","scriptureReference","extractItems","additionalItemsLabels","scope","onScopeChange","allItemsText","approvedItemsText","unapprovedItemsText","unknownItemsText","scopeBookText","scopeChapterText","scopeVerseText","filterText","showAdditionalItemsText","showAdditionalItems","setShowAdditionalItems","setStatusFilter","setTextFilter","selectedItem","setSelectedItem","reducedTableData","newTableData","firstItem","existingEntry","newTableEntry","filteredTableData","allColumns","numberOfAdditionalItems","additionalColumns","_b","rowClickHandler","newSelection","handleScopeChange","handleStatusFilterChange","SearchBar","onSearch","placeholder","isFullWidth","handleInputChange","VerticalTabs","TabsPrimitive","VerticalTabsList","VerticalTabsTrigger","VerticalTabsContent","TabNavigationContentSearch","tabList","searchPlaceholder","headerTitle","isSearchBarFullWidth","direction","tab","Separator","orientation","decorative","SeparatorPrimitive","Sheet","SheetPrimitive","SheetPortal","SheetOverlay","sheetVariants","SheetContent","side","SheetTitle","SheetDescription","Skeleton","TooltipProvider","TooltipPrimitive","Tooltip","TooltipTrigger","TooltipContent","MOBILE_BREAKPOINT","useIsMobile","isMobile","setIsMobile","mql","SIDEBAR_COOKIE_NAME","SIDEBAR_COOKIE_MAX_AGE","SIDEBAR_WIDTH","SIDEBAR_WIDTH_MOBILE","SIDEBAR_WIDTH_ICON","SIDEBAR_KEYBOARD_SHORTCUT","SidebarContext","useSidebar","SidebarProvider","defaultOpen","openProp","setOpenProp","style","openMobile","setOpenMobile","_open","_setOpen","isOpen","openState","toggleSidebar","state","contextValue","Sidebar","collapsible","SidebarTrigger","onClick","PanelLeft","SidebarRail","SidebarInset","SidebarInput","SidebarHeader","SidebarFooter","SidebarSeparator","SidebarContent","SidebarGroup","SidebarGroupLabel","SidebarGroupAction","SidebarGroupContent","SidebarMenu","SidebarMenuItem","sidebarMenuButtonVariants","SidebarMenuButton","isActive","tooltip","Comp","button","SidebarMenuAction","showOnHover","SidebarMenuBadge","SidebarMenuSkeleton","showIcon","width","SidebarMenuSub","SidebarMenuSubItem","SidebarMenuSubButton","SettingsSidebar","extensionLabels","projectOptions","handleSelectSidebarItem","selectedSidebarItem","extensionsSidebarGroupLabel","projectsSidebarGroupLabel","handleSelectItem","projectId","getProjectNameFromProjectId","project","getIsActive","label","selectedProjectName","SettingsSidebarContentSearch","scrBookColId","scrRefColId","typeColId","detailsColId","defaultScrRefColumnName","defaultScrBookGroupName","defaultTypeColumnName","defaultDetailsColumnName","getColumns","colInfo","showSourceColumn","showSrcCol","info","formatScrRef","compareScrRefs","toRefOrRange","scriptureSelection","offsetStart","offsetEnd","scrRefToBBBCCCVVV","getRowKey","ScriptureResultsViewer","sources","showColumnHeaders","scriptureReferenceColumnName","scriptureBookGroupName","typeColumnName","detailsColumnName","onRowSelected","grouping","setGrouping","scriptureResults","source","getExpandedRowModel","getGroupedRowModel","selectedRows","keys","selectedRow","scrBookGroupName","typeGroupName","groupingOptions","handleSelectChange","selectedGrouping","handleRowClick","getEvenOrOddBandingStyle","getIndent","groupingState","rowIndex","ChevronLeft","DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS","getLocalizeKeyForScrollGroupId","ScrollGroupSelector","availableScrollGroupIds","scrollGroupId","onChangeScrollGroupId","localizedStringsDefaulted","localizedStringKey","localizedStringValue","newScrollGroupString","scrollGroupOptionId","SettingsList","SettingsListItem","primary","secondary","isLoading","loadingMessage","SettingsListHeader","includeSeparator","Checklist","listItems","selectedListItems","handleSelectListItem","createLabel","_interopRequireDefault","obj","module","chainPropTypes","propType1","propType2","args","_extends","target","isPlainObject","prototype","deepClone","output","deepmerge","p","r","t","z","reactIs_production_min","hasSymbol","REACT_ELEMENT_TYPE","REACT_PORTAL_TYPE","REACT_FRAGMENT_TYPE","REACT_STRICT_MODE_TYPE","REACT_PROFILER_TYPE","REACT_PROVIDER_TYPE","REACT_CONTEXT_TYPE","REACT_ASYNC_MODE_TYPE","REACT_CONCURRENT_MODE_TYPE","REACT_FORWARD_REF_TYPE","REACT_SUSPENSE_TYPE","REACT_SUSPENSE_LIST_TYPE","REACT_MEMO_TYPE","REACT_LAZY_TYPE","REACT_BLOCK_TYPE","REACT_FUNDAMENTAL_TYPE","REACT_RESPONDER_TYPE","REACT_SCOPE_TYPE","isValidElementType","typeOf","object","$$typeof","$$typeofType","AsyncMode","ConcurrentMode","ContextConsumer","ContextProvider","Element","ForwardRef","Lazy","Memo","Portal","Profiler","StrictMode","Suspense","hasWarnedAboutDeprecatedIsAsyncMode","isAsyncMode","isConcurrentMode","isContextConsumer","isContextProvider","isElement","isForwardRef","isFragment","isLazy","isMemo","isPortal","isProfiler","isStrictMode","isSuspense","reactIs_development","reactIsModule","require$$0","require$$1","getOwnPropertySymbols","hasOwnProperty","propIsEnumerable","toObject","val","shouldUseNative","test1","test2","order2","test3","letter","objectAssign","from","to","symbols","ReactPropTypesSecret","ReactPropTypesSecret_1","has","printWarning","loggedTypeFailures","message","checkPropTypes","typeSpecs","values","location","componentName","getStack","typeSpecName","error","err","ex","stack","checkPropTypes_1","ReactIs","assign","require$$2","require$$3","require$$4","emptyFunctionThatReturnsNull","factoryWithTypeCheckers","isValidElement","throwOnDirectAccess","ITERATOR_SYMBOL","FAUX_ITERATOR_SYMBOL","getIteratorFn","maybeIterable","iteratorFn","ANONYMOUS","ReactPropTypes","createPrimitiveTypeChecker","createAnyTypeChecker","createArrayOfTypeChecker","createElementTypeChecker","createElementTypeTypeChecker","createInstanceTypeChecker","createNodeChecker","createObjectOfTypeChecker","createEnumTypeChecker","createUnionTypeChecker","createShapeTypeChecker","createStrictShapeTypeChecker","is","PropTypeError","createChainableTypeChecker","validate","manualPropTypeCallCache","manualPropTypeWarningCount","checkType","isRequired","propName","propFullName","secret","cacheKey","chainedCheckType","expectedType","propValue","propType","getPropType","preciseType","getPreciseType","typeChecker","expectedClass","expectedClassName","actualClassName","getClassName","expectedValues","valuesString","arrayOfTypeCheckers","checker","getPostfixForTypeWarning","expectedTypes","checkerResult","expectedTypesMessage","isNode","invalidValidatorError","shapeTypes","allKeys","iterator","step","entry","isSymbol","emptyFunction","emptyFunctionWithReset","factoryWithThrowingShims","shim","getShim","propTypesModule","isClassComponent","elementType","acceptingRef","safePropName","warningHint","elementAcceptingRef","PropTypes","elementAcceptingRef$1","specialProperty","exactProp","propTypes","unsupportedProps","prop","formatMuiErrorMessage","code","url","REACT_SERVER_CONTEXT_TYPE","REACT_OFFSCREEN_TYPE","enableScopeAPI","enableCacheElement","enableTransitionTracing","enableLegacyHidden","enableDebugTracing","REACT_MODULE_REFERENCE","SuspenseList","hasWarnedAboutDeprecatedIsConcurrentMode","isSuspenseList","fnNameMatchRegex","getFunctionName","fn","getFunctionComponentName","Component","fallback","getWrappedName","outerType","innerType","wrapperName","functionName","getDisplayName","HTMLElementType","refType","refType$1","capitalize","string","_formatMuiErrorMessage","createChainedFunction","funcs","acc","func","debounce","wait","timeout","debounced","later","deprecatedPropType","validator","reason","componentNameSafe","propFullNameSafe","isMuiElement","muiNames","_muiName","_element$type","ownerDocument","node","ownerWindow","requirePropFactory","componentNameInError","prevPropTypes","requiredProp","defaultTypeChecker","typeCheckerResult","setRef","useEnhancedEffect","useEnhancedEffect$1","globalId","useGlobalId","idOverride","defaultId","setDefaultId","maybeReactUseId","useId","reactId","unsupportedProp","useControlled","controlled","defaultProp","name","isControlled","valueState","setValue","defaultValue","setValueIfUncontrolled","newValue","useEventCallback","useForkRef","refs","instance","UNINITIALIZED","useLazyRef","init","initArg","EMPTY","useOnMount","Timeout","delay","useTimeout","hadKeyboardEvent","hadFocusVisibleRecently","hadFocusVisibleRecentlyTimeout","inputTypesWhitelist","focusTriggersKeyboardModality","tagName","handlePointerDown","handleVisibilityChange","prepare","doc","isFocusVisible","useIsFocusVisible","isFocusVisibleRef","handleBlurVisible","handleFocusVisible","resolveProps","defaultProps","defaultSlotProps","slotProps","slotPropName","composeClasses","slots","getUtilityClass","classes","slot","utilityClass","defaultGenerator","createClassNameGenerator","generate","generator","ClassNameGenerator","ClassNameGenerator$1","globalStateClasses","generateUtilityClass","globalStatePrefix","globalStateClass","generateUtilityClasses","result","clamp","min","max","_objectWithoutPropertiesLoose","excluded","sourceKeys","_excluded","sortBreakpointsValues","breakpointsAsArray","breakpoint1","breakpoint2","createBreakpoints","breakpoints","unit","other","sortedValues","up","down","between","start","end","endIndex","only","not","keyIndex","shape","shape$1","responsivePropType","responsivePropType$1","merge","defaultBreakpoints","handleBreakpoints","styleFromPropValue","theme","themeBreakpoints","breakpoint","mediaKey","cssKey","createEmptyBreakpointObject","breakpointsInput","_breakpointsInput$key","breakpointStyleKey","removeUnusedBreakpoints","breakpointKeys","breakpointOutput","getPath","path","checkVars","getStyleValue","themeMapping","transform","propValueFinal","userValue","cssProperty","themeKey","memoize","cache","arg","properties","directions","aliases","getCssProperties","property","marginKeys","paddingKeys","spacingKeys","createUnaryUnit","_getPath","themeSpacing","abs","createUnarySpacing","getValue","transformer","transformed","getStyleFromPropValue","cssProperties","resolveCssProperty","margin","padding","createSpacing","spacingInput","spacing","argsInput","argument","compose","styles","handlers","borderTransform","createBorderStyle","border","borderTop","borderRight","borderBottom","borderLeft","borderColor","borderTopColor","borderRightColor","borderBottomColor","borderLeftColor","outline","outlineColor","borderRadius","gap","columnGap","rowGap","gridColumn","gridRow","gridAutoFlow","gridAutoColumns","gridAutoRows","gridTemplateColumns","gridTemplateRows","gridTemplateAreas","gridArea","paletteTransform","color","bgcolor","backgroundColor","sizingTransform","maxWidth","_props$theme","_props$theme2","breakpointsValues","minWidth","height","maxHeight","minHeight","boxSizing","defaultSxConfig","defaultSxConfig$1","objectsHaveSameKeys","objects","union","callIfFn","maybeFn","unstable_createStyleFunctionSx","getThemeValue","config","styleFunctionSx","_theme$unstable_sxCon","sx","traverse","sxInput","sxObject","emptyBreakpoints","breakpointsKeys","css","styleKey","styleFunctionSx$1","applyStyles","createTheme","paletteInput","shapeInput","muiTheme","isObjectEmpty","useTheme","defaultTheme","contextTheme","ThemeContext","systemDefaultTheme","useThemeWithoutDefault","_excluded2","_excluded3","isEmpty","isStringTag","tag","shouldForwardProp","lowercaseFirstLetter","resolveTheme","themeId","defaultOverridesResolver","processStyleArg","callableStyle","_ref","ownerState","resolvedStylesArg","resolvedStyle","variants","isMatch","createStyled","input","rootShouldForwardProp","slotShouldForwardProp","systemSx","inputOptions","processStyles","componentSlot","inputSkipVariantsResolver","inputSkipSx","overridesResolver","skipVariantsResolver","skipSx","shouldForwardPropOption","defaultStyledResolver","styledEngineStyled","transformStyleArg","stylesArg","muiStyledResolver","styleArg","expressions","transformedStyleArg","expressionsWithDefaultTheme","styleOverrides","resolvedStyleOverrides","slotKey","slotStyle","_theme$components","themeVariants","numOfCustomFnsApplied","placeholders","displayName","getThemeProps","params","useThemeProps","clampWrapper","hexToRgb","re","colors","decomposeColor","marker","colorSpace","recomposeColor","hslToRgb","rgb","getLuminance","getContrastRatio","foreground","background","lumA","lumB","alpha","darken","coefficient","lighten","createMixins","mixins","common","common$1","grey","grey$1","purple","purple$1","red","red$1","orange","orange$1","blue","blue$1","lightBlue","lightBlue$1","green","green$1","light","dark","addLightOrDark","intent","shade","tonalOffset","tonalOffsetLight","tonalOffsetDark","getDefaultPrimary","mode","getDefaultSecondary","getDefaultError","getDefaultInfo","getDefaultSuccess","getDefaultWarning","createPalette","palette","contrastThreshold","success","warning","getContrastText","contrastText","contrast","augmentColor","mainShade","lightShade","darkShade","modes","round","caseAllCaps","defaultFontFamily","createTypography","typography","fontFamily","fontSize","fontWeightLight","fontWeightRegular","fontWeightMedium","fontWeightBold","htmlFontSize","allVariants","pxToRem2","coef","pxToRem","buildVariant","fontWeight","lineHeight","letterSpacing","casing","shadowKeyUmbraOpacity","shadowKeyPenumbraOpacity","shadowAmbientShadowOpacity","createShadow","px","shadows","shadows$1","easing","duration","formatMs","milliseconds","getAutoHeightDuration","constant","createTransitions","inputTransitions","mergedEasing","mergedDuration","durationOption","easingOption","isString","isNumber","animatedProp","zIndex","zIndex$1","mixinsInput","transitionsInput","typographyInput","systemTheme","systemCreateTheme","stateClasses","component","child","stateClass","defaultTheme$1","THEME_ID","systemUseThemeProps","styled","styled$1","getSvgIconUtilityClass","useUtilityClasses","SvgIconRoot","_theme$transitions","_theme$transitions$cr","_theme$transitions2","_theme$typography","_theme$typography$pxT","_theme$typography2","_theme$typography2$px","_theme$typography3","_theme$typography3$px","_palette$ownerState$c","_palette","_palette2","_palette3","SvgIcon","inProps","htmlColor","inheritViewBox","titleAccess","viewBox","hasSvgAsChild","more","_jsxs","_jsx","SvgIcon$1","createSvgIcon","unstable_ClassNameGenerator","exports","_utils","ArrowRight","default_1","_createSvgIcon","_jsxRuntime","isHostComponent","appendOwnerState","otherProps","defaultContextValue","ClassNameConfiguratorContext","useClassNamesOverride","disableDefaultClasses","extractEventHandlers","excludeKeys","resolveComponentProps","componentProps","slotState","omitEventHandlers","mergeSlotProps","parameters","getSlotProps","additionalProps","externalSlotProps","externalForwardedProps","joinedClasses","mergedStyle","eventHandlers","componentsPropsWithoutEventHandlers","otherPropsWithoutEventHandlers","internalSlotProps","useSlotProps","_parameters$additiona","skipResolvingSlotProps","rest","resolvedComponentsProps","mergedProps","internalRef","GLOBAL_CLASS_PREFIX","buildStateClass","buildSlotClass","getContainer","container","forwardedRef","disablePortal","mountNode","setMountNode","handleRef","newProps","ReactDOM","top","bottom","right","left","auto","basePlacements","clippingParents","viewport","popper","reference","variationPlacements","placement","placements","beforeRead","read","afterRead","beforeMain","main","afterMain","beforeWrite","write","afterWrite","modifierPhases","getNodeName","getWindow","OwnElement","isHTMLElement","isShadowRoot","attributes","effect","_ref2","initialStyles","styleProperties","attribute","applyStyles$1","getBasePlacement","getUAString","uaData","isLayoutViewport","getBoundingClientRect","includeScale","isFixedStrategy","clientRect","scaleX","scaleY","visualViewport","addVisualOffsets","getLayoutRect","contains","parent","rootNode","next","getComputedStyle","isTableElement","getDocumentElement","getParentNode","getTrueOffsetParent","getContainingBlock","isFirefox","isIE","elementCss","currentNode","getOffsetParent","window","offsetParent","getMainAxisFromPlacement","within","mathMax","mathMin","withinMaxClamp","getFreshSideObject","mergePaddingObject","paddingObject","expandToHashMap","hashMap","toPaddingObject","arrow","_state$modifiersData$","arrowElement","popperOffsets","basePlacement","axis","isVertical","len","arrowRect","minProp","maxProp","endDiff","startDiff","arrowOffsetParent","clientSize","centerToReference","center","offset","axisProp","_options$element","arrow$1","getVariation","unsetSides","roundOffsetsByDPR","win","dpr","mapToStyles","_Object$assign2","popperRect","variation","offsets","gpuAcceleration","adaptive","roundOffsets","isFixed","_offsets$x","_offsets$y","_ref3","hasX","hasY","sideX","sideY","heightProp","widthProp","offsetY","offsetX","commonStyles","_ref4","_Object$assign","computeStyles","_ref5","_options$gpuAccelerat","_options$adaptive","_options$roundOffsets","computeStyles$1","passive","_options$scroll","scroll","_options$resize","resize","scrollParents","scrollParent","eventListeners","hash","getOppositePlacement","matched","getOppositeVariationPlacement","getWindowScroll","scrollLeft","scrollTop","getWindowScrollBarX","getViewportRect","strategy","html","layoutViewport","getDocumentRect","_element$ownerDocumen","winScroll","body","isScrollParent","_getComputedStyle","overflow","overflowX","overflowY","getScrollParent","listScrollParents","list","isBody","updatedList","rectToClientRect","rect","getInnerBoundingClientRect","getClientRectFromMixedType","clippingParent","getClippingParents","canEscapeClipping","clipperElement","getClippingRect","boundary","rootBoundary","mainClippingParents","firstClippingParent","clippingRect","accRect","computeOffsets","commonX","commonY","mainAxis","detectOverflow","_options","_options$placement","_options$strategy","_options$boundary","_options$rootBoundary","_options$elementConte","elementContext","_options$altBoundary","altBoundary","_options$padding","altContext","clippingClientRect","referenceClientRect","popperClientRect","elementClientRect","overflowOffsets","offsetData","multiply","computeAutoPlacement","flipVariations","_options$allowedAutoP","allowedAutoPlacements","allPlacements","allowedPlacements","overflows","getExpandedFallbackPlacements","oppositePlacement","flip","_options$mainAxis","checkMainAxis","_options$altAxis","checkAltAxis","specifiedFallbackPlacements","_options$flipVariatio","preferredPlacement","isBasePlacement","fallbackPlacements","referenceRect","checksMap","makeFallbackChecks","firstFittingPlacement","_basePlacement","isStartVariation","mainVariationSide","altVariationSide","checks","check","numberOfChecks","_loop","_i","fittingPlacement","_ret","flip$1","getSideOffsets","preventedOffsets","isAnySideFullyClipped","hide","referenceOverflow","popperAltOverflow","referenceClippingOffsets","popperEscapeOffsets","isReferenceHidden","hasPopperEscaped","hide$1","distanceAndSkiddingToXY","rects","invertDistance","skidding","distance","_options$offset","_data$state$placement","offset$1","popperOffsets$1","getAltAxis","preventOverflow","_options$tether","tether","_options$tetherOffset","tetherOffset","altAxis","tetherOffsetValue","normalizedTetherOffsetValue","offsetModifierState","_offsetModifierState$","mainSide","altSide","additive","minLen","maxLen","arrowPaddingObject","arrowPaddingMin","arrowPaddingMax","arrowLen","minOffset","maxOffset","clientOffset","offsetModifierValue","tetherMin","tetherMax","preventedOffset","_offsetModifierState$2","_mainSide","_altSide","_offset","_len","_min","_max","isOriginSide","_offsetModifierValue","_tetherMin","_tetherMax","_preventedOffset","preventOverflow$1","getHTMLElementScroll","getNodeScroll","isElementScaled","getCompositeRect","elementOrVirtualElement","isOffsetParentAnElement","offsetParentIsScaled","documentElement","order","modifiers","map","visited","modifier","sort","requires","dep","depModifier","orderModifiers","orderedModifiers","phase","pending","resolve","mergeByName","merged","current","existing","DEFAULT_OPTIONS","areValidElements","_key","popperGenerator","generatorOptions","_generatorOptions","_generatorOptions$def","defaultModifiers","_generatorOptions$def2","defaultOptions","effectCleanupFns","isDestroyed","setOptionsAction","cleanupModifierEffects","runModifierEffects","_state$elements","_state$orderedModifie","_state$orderedModifie2","_ref$options","cleanupFn","noopFn","createPopper","COMPONENT_NAME","getPopperUtilityClass","flipPlacement","resolveAnchorEl","anchorEl","isVirtualElement","defaultPopperOptions","PopperTooltip","_slots$root","initialPlacement","popperOptions","popperRefProp","TransitionProps","tooltipRef","ownRef","popperRef","handlePopperRef","handlePopperRefRef","rtlPlacement","setPlacement","resolvedAnchorElement","setResolvedAnchorElement","handlePopperUpdate","box","popperModifiers","childProps","Root","rootProps","Popper","containerProp","keepMounted","transition","exited","setExited","handleEnter","handleExited","resolvedAnchorEl","display","transitionProps","useThemeSystem","_setPrototypeOf","_inheritsLoose","subClass","superClass","setPrototypeOf","timeoutsShape","TransitionGroupContext","forceReflow","UNMOUNTED","EXITED","ENTERING","ENTERED","EXITING","Transition","_React$Component","_this","parentGroup","appear","initialStatus","prevState","nextIn","_proto","prevProps","nextStatus","exit","enter","mounting","_this2","appearing","maybeNode","maybeAppearing","timeouts","enterTimeout","_this3","nextState","callback","_this4","active","handler","doesNotHaveTimeoutOrListener","maybeNextCallback","_this$props","pt","noop","Transition$1","reflow","getTransitionProps","_style$transitionDura","_style$transitionTimi","getScale","isWebKit154","Grow","addEndListener","inProp","onEnter","onEntered","onEntering","onExit","onExited","onExiting","TransitionComponent","timer","autoTimeout","nodeRef","normalizedTransitionCallback","maybeIsAppearing","handleEntering","isAppearing","transitionDuration","transitionTimingFunction","handleEntered","handleExiting","handleExit","Grow$1","PopperRoot","BasePopper","components","componentsProps","RootComponent","Popper$1","getTooltipUtilityClass","tooltipClasses","tooltipClasses$1","disableInteractive","touch","TooltipPopper","TooltipTooltip","TooltipArrow","hystersisOpen","hystersisTimer","cursorPosition","composeEventHandler","eventHandler","_slots$popper","_slots$transition","_slots$tooltip","_slots$arrow","_slotProps$popper","_ref6","_slotProps$popper2","_slotProps$transition","_slotProps$tooltip","_ref7","_slotProps$tooltip2","_slotProps$arrow","_ref8","_slotProps$arrow2","childrenProp","describeChild","disableFocusListener","disableHoverListener","disableInteractiveProp","disableTouchListener","enterDelay","enterNextDelay","enterTouchDelay","followCursor","idProp","leaveDelay","leaveTouchDelay","onClose","onOpen","PopperComponentProp","PopperProps","title","TransitionComponentProp","isRtl","childNode","setChildNode","arrowRef","setArrowRef","ignoreNonTouchEvents","closeTimer","enterTimer","leaveTimer","touchTimer","setOpenState","prevUserSelect","stopTouchInteraction","handleOpen","handleClose","handleLeave","focusVisibleRef","setChildIsFocusVisible","handleBlur","handleFocus","detectTouchStart","childrenProps","handleMouseOver","handleMouseLeave","handleTouchStart","handleTouchEnd","nativeEvent","handleMouseMove","nameOrDescProps","titleIsString","interactiveWrapperListeners","_PopperProps$popperOp","tooltipModifiers","PopperComponent","TooltipComponent","ArrowComponent","popperProps","tooltipProps","tooltipArrowProps","TransitionPropsInner","Tooltip$1","getIcon","icon","menuLabel","leading","MuiListItemIcon","MenuItem","allowForLeadingIcons","iconPathBefore","iconPathAfter","hasAutoFocus","isDense","isSubMenuParent","hasDisabledGutters","hasDivider","focusVisibleClassName","menuItem","MuiMenuItem","MuiListItemText","getAllGroups","menuDefinition","SubMenu","setAnchorEl","parentMenuItem","parentItemProps","handleParentMenuItemClick","renderSubMenuItems","includedGroups","group","GroupedMenuItemList","Menu","getOrderedGroupItems","groupId","allItems","menuProps","commandHandler","groupsToInclude","sortedGroups","itemArray","allowSpaceForLeadingIcons","createMenuItemProps","isLastItemInGroup","divKey","itemInfo","menuItemProps","TopLevelMenu","columnId","MenuColumn","metadata","Grid","List","GridMenu","multiColumnMenu","sortedColumns","columnNumbers","columnName","col","getUsePromiseOptionsDefaults","usePromise","promiseFactoryCallback","defaultValueRef","optionsDefaultedRef","setIsLoading","promiseIsCurrent","MenuIcon","HamburgerMenuButton","menuProvider","normalMenu","fullMenu","containerRef","ariaLabelPrefix","isMenuOpen","setMenuOpen","showFullMenu","setShowFullMenu","handleMenuItemClick","handleMenuButtonClick","prevIsOpen","isOpening","menuCommandHandler","command","setOffset","normalMenuData","fullMenuData","menu","IconButton","Drawer","isTooltipSuppressed","adjustMarginToAlignToEdge","MuiIconButton","Spinner","LoaderCircle","TextField","hasError","helperText","onFocus","onBlur","ShadLabel","Toolbar","AppBar","MuiToolbar","alertVariants","Alert","AlertTitle","AlertDescription","Card","CardHeader","CardTitle","CardDescription","CardContent","CardFooter","Sonner","Toaster","Slider","SliderPrimitive","Switch","SwitchPrimitives","Tabs","TabsList","TabsTrigger","TabsContent","InstallButton","isInstalling","handleClick","buttonText","Download","EnableButton","isEnabling","DisableButton","isDisabling","UpdateButton","isUpdating","MarkdownRenderer","markdown","anchorTarget","Markdown","FilterButton","Filter","DropdownMenuItemType","DropdownMenuItemType2","FilterDropdown","groups","NoExtensionsFound","MoreInfo","category","downloads","languages","moreInfoUrl","numberFormatted","NumberFormat","handleScrollToBottom","User","locale","LucideLink","CircleHelp","VersionHistory","versionHistory","showAllVersions","setShowAllVersions","currentDate","formatTimeString","dateString","date","dateDiff","yearDiff","monthDiff","dayDiff","timeString","sortedEntries","Footer","publisherDisplayName","fileSize","locales","formattedFileSize","formatBytes","languageNames","codes","displayNames","useEvent","unsubscriber","noopUnsubscriber","useEventAsync","unsubscribe","unsub"],"mappings":";;;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;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","x_google_ignoreList":[3,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,83,84,85,86,87,88,89,90,91,92,93,94,95,96,97,98,99,100,101,102,103,104,105,106,107,108,109,110,111,112,113,114,115,116,117,118,119,120,121,122,123,124,125,126,127,128,129,130,131,132,133,134,135,136,137,138,139,140,141,142,143,144,145,146,147,148,149,150,151,152,153,154,155,156,157,158,159,160,161,162,163,164,165,166,167,168,169,170,171,172,173,174,175,176,177,178,179,180,181,182,183,184,185,186,187,188,189,190,191,192,193,194,195,196,197,198,199,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,228]} \ No newline at end of file +{"version":3,"file":"index.js","sources":["../src/utils/shadcn-ui.util.ts","../src/components/shadcn-ui/input.tsx","../src/components/advanced/book-chapter-control/book-chapter-input.component.tsx","../../../node_modules/@sillsdev/scripture/dist/index.es.js","../src/components/shadcn-ui/dropdown-menu.tsx","../src/components/advanced/book-chapter-control/book-menu-item.component.tsx","../src/components/advanced/book-chapter-control/chapter-select.component.tsx","../src/components/advanced/book-chapter-control/go-to-menu-item.component.tsx","../src/components/advanced/book-chapter-control/book-chapter-control.component.tsx","../src/components/shadcn-ui/button.tsx","../src/components/shadcn-ui/label.tsx","../src/components/shadcn-ui/radio-group.tsx","../src/components/shadcn-ui/popover.tsx","../src/components/shadcn-ui/dialog.tsx","../src/components/shadcn-ui/command.tsx","../src/components/basics/combo-box.component.tsx","../src/components/basics/chapter-range-selector.component.tsx","../src/components/advanced/book-selector.component.tsx","../src/components/advanced/data-table/data-table-column-toggle.component.tsx","../src/components/shadcn-ui/select.tsx","../src/components/advanced/data-table/data-table-pagination.component.tsx","../src/components/shadcn-ui/table.tsx","../src/components/advanced/data-table/data-table.component.tsx","../src/components/advanced/inventory/occurrences-table.component.tsx","../src/components/shadcn-ui/checkbox.tsx","../src/components/advanced/inventory/inventory-utils.ts","../src/components/shadcn-ui/toggle.tsx","../src/components/shadcn-ui/toggle-group.tsx","../src/components/advanced/inventory/inventory-columns.tsx","../src/components/advanced/inventory/inventory.component.tsx","../src/components/basics/search-bar.component.tsx","../src/components/basics/tabs-vertical.tsx","../src/components/advanced/tab-navigation-content-search.component.tsx","../src/components/shadcn-ui/separator.tsx","../src/components/shadcn-ui/sheet.tsx","../src/components/shadcn-ui/skeleton.tsx","../src/components/shadcn-ui/tooltip.tsx","../src/components/hooks/use-mobile.tsx","../src/components/shadcn-ui/sidebar.tsx","../src/components/advanced/settings-components/settings-sidebar.component.tsx","../src/components/advanced/settings-components/settings-sidebar-content-search.component.tsx","../src/components/advanced/scripture-results-viewer/scripture-results-viewer.component.tsx","../src/components/advanced/scroll-group-selector.component.tsx","../src/components/advanced/settings-components/settings-list.component.tsx","../src/components/basics/checklist.component.tsx","../../../node_modules/@babel/runtime/helpers/interopRequireDefault.js","../../../node_modules/@mui/utils/chainPropTypes/chainPropTypes.js","../../../node_modules/@babel/runtime/helpers/esm/extends.js","../../../node_modules/@mui/utils/deepmerge/deepmerge.js","../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.production.min.js","../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.development.js","../../../node_modules/prop-types/node_modules/react-is/index.js","../../../node_modules/object-assign/index.js","../../../node_modules/prop-types/lib/ReactPropTypesSecret.js","../../../node_modules/prop-types/lib/has.js","../../../node_modules/prop-types/checkPropTypes.js","../../../node_modules/prop-types/factoryWithTypeCheckers.js","../../../node_modules/prop-types/factoryWithThrowingShims.js","../../../node_modules/prop-types/index.js","../../../node_modules/@mui/utils/elementAcceptingRef/elementAcceptingRef.js","../../../node_modules/@mui/utils/exactProp/exactProp.js","../../../node_modules/@mui/utils/formatMuiErrorMessage/formatMuiErrorMessage.js","../../../node_modules/react-is/cjs/react-is.production.min.js","../../../node_modules/react-is/cjs/react-is.development.js","../../../node_modules/react-is/index.js","../../../node_modules/@mui/utils/getDisplayName/getDisplayName.js","../../../node_modules/@mui/utils/HTMLElementType/HTMLElementType.js","../../../node_modules/@mui/utils/refType/refType.js","../../../node_modules/@mui/utils/capitalize/capitalize.js","../../../node_modules/@mui/utils/createChainedFunction/createChainedFunction.js","../../../node_modules/@mui/utils/debounce/debounce.js","../../../node_modules/@mui/utils/deprecatedPropType/deprecatedPropType.js","../../../node_modules/@mui/utils/isMuiElement/isMuiElement.js","../../../node_modules/@mui/utils/ownerDocument/ownerDocument.js","../../../node_modules/@mui/utils/ownerWindow/ownerWindow.js","../../../node_modules/@mui/utils/requirePropFactory/requirePropFactory.js","../../../node_modules/@mui/utils/setRef/setRef.js","../../../node_modules/@mui/utils/useEnhancedEffect/useEnhancedEffect.js","../../../node_modules/@mui/utils/useId/useId.js","../../../node_modules/@mui/utils/unsupportedProp/unsupportedProp.js","../../../node_modules/@mui/utils/useControlled/useControlled.js","../../../node_modules/@mui/utils/useEventCallback/useEventCallback.js","../../../node_modules/@mui/utils/useForkRef/useForkRef.js","../../../node_modules/@mui/utils/useLazyRef/useLazyRef.js","../../../node_modules/@mui/utils/useOnMount/useOnMount.js","../../../node_modules/@mui/utils/useTimeout/useTimeout.js","../../../node_modules/@mui/utils/useIsFocusVisible/useIsFocusVisible.js","../../../node_modules/@mui/utils/resolveProps/resolveProps.js","../../../node_modules/@mui/utils/composeClasses/composeClasses.js","../../../node_modules/@mui/utils/ClassNameGenerator/ClassNameGenerator.js","../../../node_modules/@mui/utils/generateUtilityClass/generateUtilityClass.js","../../../node_modules/@mui/utils/generateUtilityClasses/generateUtilityClasses.js","../../../node_modules/@mui/utils/clamp/clamp.js","../../../node_modules/@babel/runtime/helpers/esm/objectWithoutPropertiesLoose.js","../../../node_modules/@mui/system/esm/createTheme/createBreakpoints.js","../../../node_modules/@mui/system/esm/createTheme/shape.js","../../../node_modules/@mui/system/esm/responsivePropType.js","../../../node_modules/@mui/system/esm/merge.js","../../../node_modules/@mui/system/esm/breakpoints.js","../../../node_modules/@mui/system/esm/style.js","../../../node_modules/@mui/system/esm/memoize.js","../../../node_modules/@mui/system/esm/spacing.js","../../../node_modules/@mui/system/esm/createTheme/createSpacing.js","../../../node_modules/@mui/system/esm/compose.js","../../../node_modules/@mui/system/esm/borders.js","../../../node_modules/@mui/system/esm/cssGrid.js","../../../node_modules/@mui/system/esm/palette.js","../../../node_modules/@mui/system/esm/sizing.js","../../../node_modules/@mui/system/esm/styleFunctionSx/defaultSxConfig.js","../../../node_modules/@mui/system/esm/styleFunctionSx/styleFunctionSx.js","../../../node_modules/@mui/system/esm/createTheme/applyStyles.js","../../../node_modules/@mui/system/esm/createTheme/createTheme.js","../../../node_modules/@mui/system/esm/useThemeWithoutDefault.js","../../../node_modules/@mui/system/esm/useTheme.js","../../../node_modules/@mui/system/esm/createStyled.js","../../../node_modules/@mui/system/esm/useThemeProps/getThemeProps.js","../../../node_modules/@mui/system/esm/useThemeProps/useThemeProps.js","../../../node_modules/@mui/system/esm/colorManipulator.js","../../../node_modules/@mui/material/styles/createMixins.js","../../../node_modules/@mui/material/colors/common.js","../../../node_modules/@mui/material/colors/grey.js","../../../node_modules/@mui/material/colors/purple.js","../../../node_modules/@mui/material/colors/red.js","../../../node_modules/@mui/material/colors/orange.js","../../../node_modules/@mui/material/colors/blue.js","../../../node_modules/@mui/material/colors/lightBlue.js","../../../node_modules/@mui/material/colors/green.js","../../../node_modules/@mui/material/styles/createPalette.js","../../../node_modules/@mui/material/styles/createTypography.js","../../../node_modules/@mui/material/styles/shadows.js","../../../node_modules/@mui/material/styles/createTransitions.js","../../../node_modules/@mui/material/styles/zIndex.js","../../../node_modules/@mui/material/styles/createTheme.js","../../../node_modules/@mui/material/styles/defaultTheme.js","../../../node_modules/@mui/material/styles/identifier.js","../../../node_modules/@mui/material/styles/useThemeProps.js","../../../node_modules/@mui/material/styles/styled.js","../../../node_modules/@mui/material/SvgIcon/svgIconClasses.js","../../../node_modules/@mui/material/SvgIcon/SvgIcon.js","../../../node_modules/@mui/material/utils/createSvgIcon.js","../../../node_modules/@mui/material/utils/index.js","../../../node_modules/@mui/icons-material/utils/createSvgIcon.js","../../../node_modules/@mui/icons-material/ArrowRight.js","../../../node_modules/@mui/base/utils/isHostComponent.js","../../../node_modules/@mui/base/utils/appendOwnerState.js","../../../node_modules/@mui/base/utils/ClassNameConfigurator.js","../../../node_modules/@mui/base/utils/extractEventHandlers.js","../../../node_modules/@mui/base/utils/resolveComponentProps.js","../../../node_modules/@mui/base/utils/omitEventHandlers.js","../../../node_modules/@mui/base/utils/mergeSlotProps.js","../../../node_modules/@mui/base/utils/useSlotProps.js","../../../node_modules/@mui/base/generateUtilityClass/index.js","../../../node_modules/@mui/base/generateUtilityClasses/index.js","../../../node_modules/@mui/base/Portal/Portal.js","../../../node_modules/@popperjs/core/lib/enums.js","../../../node_modules/@popperjs/core/lib/dom-utils/getNodeName.js","../../../node_modules/@popperjs/core/lib/dom-utils/getWindow.js","../../../node_modules/@popperjs/core/lib/dom-utils/instanceOf.js","../../../node_modules/@popperjs/core/lib/modifiers/applyStyles.js","../../../node_modules/@popperjs/core/lib/utils/getBasePlacement.js","../../../node_modules/@popperjs/core/lib/utils/math.js","../../../node_modules/@popperjs/core/lib/utils/userAgent.js","../../../node_modules/@popperjs/core/lib/dom-utils/isLayoutViewport.js","../../../node_modules/@popperjs/core/lib/dom-utils/getBoundingClientRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/getLayoutRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/contains.js","../../../node_modules/@popperjs/core/lib/dom-utils/getComputedStyle.js","../../../node_modules/@popperjs/core/lib/dom-utils/isTableElement.js","../../../node_modules/@popperjs/core/lib/dom-utils/getDocumentElement.js","../../../node_modules/@popperjs/core/lib/dom-utils/getParentNode.js","../../../node_modules/@popperjs/core/lib/dom-utils/getOffsetParent.js","../../../node_modules/@popperjs/core/lib/utils/getMainAxisFromPlacement.js","../../../node_modules/@popperjs/core/lib/utils/within.js","../../../node_modules/@popperjs/core/lib/utils/getFreshSideObject.js","../../../node_modules/@popperjs/core/lib/utils/mergePaddingObject.js","../../../node_modules/@popperjs/core/lib/utils/expandToHashMap.js","../../../node_modules/@popperjs/core/lib/modifiers/arrow.js","../../../node_modules/@popperjs/core/lib/utils/getVariation.js","../../../node_modules/@popperjs/core/lib/modifiers/computeStyles.js","../../../node_modules/@popperjs/core/lib/modifiers/eventListeners.js","../../../node_modules/@popperjs/core/lib/utils/getOppositePlacement.js","../../../node_modules/@popperjs/core/lib/utils/getOppositeVariationPlacement.js","../../../node_modules/@popperjs/core/lib/dom-utils/getWindowScroll.js","../../../node_modules/@popperjs/core/lib/dom-utils/getWindowScrollBarX.js","../../../node_modules/@popperjs/core/lib/dom-utils/getViewportRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/getDocumentRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/isScrollParent.js","../../../node_modules/@popperjs/core/lib/dom-utils/getScrollParent.js","../../../node_modules/@popperjs/core/lib/dom-utils/listScrollParents.js","../../../node_modules/@popperjs/core/lib/utils/rectToClientRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/getClippingRect.js","../../../node_modules/@popperjs/core/lib/utils/computeOffsets.js","../../../node_modules/@popperjs/core/lib/utils/detectOverflow.js","../../../node_modules/@popperjs/core/lib/utils/computeAutoPlacement.js","../../../node_modules/@popperjs/core/lib/modifiers/flip.js","../../../node_modules/@popperjs/core/lib/modifiers/hide.js","../../../node_modules/@popperjs/core/lib/modifiers/offset.js","../../../node_modules/@popperjs/core/lib/modifiers/popperOffsets.js","../../../node_modules/@popperjs/core/lib/utils/getAltAxis.js","../../../node_modules/@popperjs/core/lib/modifiers/preventOverflow.js","../../../node_modules/@popperjs/core/lib/dom-utils/getHTMLElementScroll.js","../../../node_modules/@popperjs/core/lib/dom-utils/getNodeScroll.js","../../../node_modules/@popperjs/core/lib/dom-utils/getCompositeRect.js","../../../node_modules/@popperjs/core/lib/utils/orderModifiers.js","../../../node_modules/@popperjs/core/lib/utils/debounce.js","../../../node_modules/@popperjs/core/lib/utils/mergeByName.js","../../../node_modules/@popperjs/core/lib/createPopper.js","../../../node_modules/@popperjs/core/lib/popper.js","../../../node_modules/@mui/base/Popper/popperClasses.js","../../../node_modules/@mui/base/Popper/Popper.js","../../../node_modules/@mui/material/styles/useTheme.js","../../../node_modules/@babel/runtime/helpers/esm/setPrototypeOf.js","../../../node_modules/@babel/runtime/helpers/esm/inheritsLoose.js","../../../node_modules/react-transition-group/esm/config.js","../../../node_modules/react-transition-group/esm/utils/PropTypes.js","../../../node_modules/react-transition-group/esm/TransitionGroupContext.js","../../../node_modules/react-transition-group/esm/utils/reflow.js","../../../node_modules/react-transition-group/esm/Transition.js","../../../node_modules/@mui/material/transitions/utils.js","../../../node_modules/@mui/material/Grow/Grow.js","../../../node_modules/@mui/material/Popper/Popper.js","../../../node_modules/@mui/material/Tooltip/tooltipClasses.js","../../../node_modules/@mui/material/Tooltip/Tooltip.js","../src/components/mui/menu-item.component.tsx","../src/components/mui/grouped-menu-item-list.component.tsx","../src/components/mui/top-level-menu.component.tsx","../src/components/mui/grid-menu.component.tsx","../src/hooks/use-promise.hook.ts","../../../node_modules/@mui/icons-material/esm/Menu.js","../src/components/mui/hamburger-menu-button.component.tsx","../src/components/mui/icon-button.component.tsx","../src/components/basics/spinner.component.tsx","../src/components/basics/text-field.component.tsx","../src/components/mui/toolbar.component.tsx","../src/components/shadcn-ui/alert.tsx","../src/components/shadcn-ui/card.tsx","../src/components/shadcn-ui/sonner.tsx","../src/components/shadcn-ui/slider.tsx","../src/components/shadcn-ui/switch.tsx","../src/components/shadcn-ui/tabs.tsx","../src/components/advanced/extension-marketplace/buttons/install-button.component.tsx","../src/components/advanced/extension-marketplace/buttons/enable-button.component.tsx","../src/components/advanced/extension-marketplace/buttons/disable-button.component.tsx","../src/components/advanced/extension-marketplace/buttons/update-button.component.tsx","../src/components/advanced/extension-marketplace/markdown-renderer.component.tsx","../src/components/advanced/extension-marketplace/buttons/filter-button.component.tsx","../src/components/advanced/extension-marketplace/filter-dropdown.component.tsx","../src/components/advanced/extension-marketplace/no-extensions-found.component.tsx","../src/components/advanced/extension-marketplace/more-info.component.tsx","../src/components/advanced/extension-marketplace/version-history.component.tsx","../src/components/advanced/extension-marketplace/footer.component.tsx","../src/hooks/use-event.hook.ts","../src/hooks/use-event-async.hook.ts"],"sourcesContent":["import { type ClassValue, clsx } from 'clsx';\nimport { extendTailwindMerge } from 'tailwind-merge';\n\nconst twMergeCustom = extendTailwindMerge({ prefix: 'tw-' });\n\n/**\n * Tailwind and CSS class application helper function. Uses\n * [`clsx`](https://www.npmjs.com/package/clsx) to make it easy to apply classes conditionally using\n * object syntax, and uses [`tailwind-merge`](https://www.npmjs.com/package/tailwind-merge) to make\n * it easy to merge/overwrite Tailwind classes in a programmer-logic-friendly way.\n *\n * Note: `tailwind-merge` is configured to use the prefix `tw-`, so you must use the same prefix\n * with any Tailwind classes you use with this function to successfully overwrite other Tailwind\n * classes. `platform-bible-react` is configured to use `tw-` as its Tailwind prefix, so any\n * Tailwind classes you pass into `platform-bible-react` components will be compared using the `tw-`\n * prefix.\n *\n * This function was popularized by\n * [shadcn/ui](https://ui.shadcn.com/docs/installation/manual#add-a-cn-helper). See [ByteGrad's\n * explanation video](https://www.youtube.com/watch?v=re2JFITR7TI) for more information.\n *\n * @example\n *\n * ```typescript\n * const borderShouldBeBlue = true;\n * const textShouldBeRed = true;\n * const heightShouldBe20 = false;\n * const classString = cn(\n * 'tw-bg-primary tw-h-10 tw-text-primary-foreground',\n * 'tw-bg-secondary',\n * {\n * 'tw-border-blue-500': borderShouldBeBlue,\n * 'tw-text-red-500': textShouldBeRed,\n * 'tw-h-20': heightShouldBe20,\n * },\n * 'some-class',\n * );\n * ```\n *\n * The resulting `classString` is `'tw-h-10 tw-bg-secondary tw-border-blue-500 tw-text-red-500\n * some-class'`\n *\n * - Notice that `'tw-bg-secondary'`, specified later, overwrote `'tw-bg-primary'`, specified earlier,\n * because they are Tailwind classes that affect the same css property\n * - Notice that `'tw-text-red-500'`, specified later, overwrote `'tw-text-primary-foreground'`,\n * specified earlier, because they are Tailwind classes that affect the same css property\n * - Notice that `'tw-h-20'`, specified later, did not overwrite `'tw-h-10'`, specified earlier,\n * because `'tw-h-20'` is part of a conditional class object and its value evaluated to `false`;\n * therefore it was not applied\n * - Notice that `'some-class'` was applied. This function is not limited only to Tailwind classes.\n *\n *\n * @param inputs Class strings or `clsx` conditional class objects to merge. Tailwind classes\n * specified later in the arguments overwrite similar Tailwind classes specified earlier in the\n * arguments\n * @returns Class string containing all applicable classes from the arguments based on the rules\n * described above\n */\n// shadcn/ui uses this export in its boilerplate code\n// eslint-disable-next-line import/prefer-default-export\nexport function cn(...inputs: ClassValue[]) {\n return twMergeCustom(clsx(inputs));\n}\n","import React from 'react';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport interface InputProps extends React.InputHTMLAttributes {}\n\nexport const Input = React.forwardRef(\n ({ className, type, ...props }, ref) => {\n return (\n \n );\n },\n);\nInput.displayName = 'Input';\n","import { FocusEventHandler, forwardRef, KeyboardEvent, MouseEventHandler } from 'react';\nimport { History } from 'lucide-react';\nimport { Input as ShadInput } from '@/components/shadcn-ui/input';\n\nexport type BookChapterInputProps = {\n handleSearch: (searchString: string) => void;\n handleKeyDown: (event: KeyboardEvent) => void;\n handleOnClick: MouseEventHandler;\n handleSubmit: () => void;\n onFocus?: FocusEventHandler;\n value: string;\n placeholder: string;\n};\n\n// Shadcn Input sets type to \"button\"- HAVE to prop spread before setting type\nconst BookChapterInput = forwardRef(\n (\n { handleSearch, handleKeyDown, handleOnClick, handleSubmit, ...props }: BookChapterInputProps,\n ref,\n ) => {\n return (\n
    \n handleSearch(event.target.value)}\n onKeyDown={(e) => {\n if (e.key === 'Enter') {\n handleSubmit();\n }\n handleKeyDown(e);\n }}\n onClick={handleOnClick}\n ref={ref}\n />\n {\n // eslint-disable-next-line no-console\n console.log('back in history');\n }}\n />\n
    \n );\n },\n);\n\nexport default BookChapterInput;\n","var P = Object.defineProperty;\nvar R = (t, e, s) => e in t ? P(t, e, { enumerable: !0, configurable: !0, writable: !0, value: s }) : t[e] = s;\nvar n = (t, e, s) => R(t, typeof e != \"symbol\" ? e + \"\" : e, s);\nclass _ {\n constructor() {\n n(this, \"books\");\n n(this, \"firstSelectedBookNum\");\n n(this, \"lastSelectedBookNum\");\n n(this, \"count\");\n n(this, \"selectedBookNumbers\");\n n(this, \"selectedBookIds\");\n }\n}\nconst N = [\n \"GEN\",\n \"EXO\",\n \"LEV\",\n \"NUM\",\n \"DEU\",\n \"JOS\",\n \"JDG\",\n \"RUT\",\n \"1SA\",\n \"2SA\",\n // 10\n \"1KI\",\n \"2KI\",\n \"1CH\",\n \"2CH\",\n \"EZR\",\n \"NEH\",\n \"EST\",\n \"JOB\",\n \"PSA\",\n \"PRO\",\n // 20\n \"ECC\",\n \"SNG\",\n \"ISA\",\n \"JER\",\n \"LAM\",\n \"EZK\",\n \"DAN\",\n \"HOS\",\n \"JOL\",\n \"AMO\",\n // 30\n \"OBA\",\n \"JON\",\n \"MIC\",\n \"NAM\",\n \"HAB\",\n \"ZEP\",\n \"HAG\",\n \"ZEC\",\n \"MAL\",\n \"MAT\",\n // 40\n \"MRK\",\n \"LUK\",\n \"JHN\",\n \"ACT\",\n \"ROM\",\n \"1CO\",\n \"2CO\",\n \"GAL\",\n \"EPH\",\n \"PHP\",\n // 50\n \"COL\",\n \"1TH\",\n \"2TH\",\n \"1TI\",\n \"2TI\",\n \"TIT\",\n \"PHM\",\n \"HEB\",\n \"JAS\",\n \"1PE\",\n // 60\n \"2PE\",\n \"1JN\",\n \"2JN\",\n \"3JN\",\n \"JUD\",\n \"REV\",\n \"TOB\",\n \"JDT\",\n \"ESG\",\n \"WIS\",\n // 70\n \"SIR\",\n \"BAR\",\n \"LJE\",\n \"S3Y\",\n \"SUS\",\n \"BEL\",\n \"1MA\",\n \"2MA\",\n \"3MA\",\n \"4MA\",\n // 80\n \"1ES\",\n \"2ES\",\n \"MAN\",\n \"PS2\",\n \"ODA\",\n \"PSS\",\n \"JSA\",\n // actual variant text for JOS, now in LXA text\n \"JDB\",\n // actual variant text for JDG, now in LXA text\n \"TBS\",\n // actual variant text for TOB, now in LXA text\n \"SST\",\n // actual variant text for SUS, now in LXA text // 90\n \"DNT\",\n // actual variant text for DAN, now in LXA text\n \"BLT\",\n // actual variant text for BEL, now in LXA text\n \"XXA\",\n \"XXB\",\n \"XXC\",\n \"XXD\",\n \"XXE\",\n \"XXF\",\n \"XXG\",\n \"FRT\",\n // 100\n \"BAK\",\n \"OTH\",\n \"3ES\",\n // Used previously but really should be 2ES\n \"EZA\",\n // Used to be called 4ES, but not actually in any known project\n \"5EZ\",\n // Used to be called 5ES, but not actually in any known project\n \"6EZ\",\n // Used to be called 6ES, but not actually in any known project\n \"INT\",\n \"CNC\",\n \"GLO\",\n \"TDX\",\n // 110\n \"NDX\",\n \"DAG\",\n \"PS3\",\n \"2BA\",\n \"LBA\",\n \"JUB\",\n \"ENO\",\n \"1MQ\",\n \"2MQ\",\n \"3MQ\",\n // 120\n \"REP\",\n \"4BA\",\n \"LAO\"\n], B = [\n \"XXA\",\n \"XXB\",\n \"XXC\",\n \"XXD\",\n \"XXE\",\n \"XXF\",\n \"XXG\",\n \"FRT\",\n \"BAK\",\n \"OTH\",\n \"INT\",\n \"CNC\",\n \"GLO\",\n \"TDX\",\n \"NDX\"\n], O = [\n \"Genesis\",\n \"Exodus\",\n \"Leviticus\",\n \"Numbers\",\n \"Deuteronomy\",\n \"Joshua\",\n \"Judges\",\n \"Ruth\",\n \"1 Samuel\",\n \"2 Samuel\",\n \"1 Kings\",\n \"2 Kings\",\n \"1 Chronicles\",\n \"2 Chronicles\",\n \"Ezra\",\n \"Nehemiah\",\n \"Esther (Hebrew)\",\n \"Job\",\n \"Psalms\",\n \"Proverbs\",\n \"Ecclesiastes\",\n \"Song of Songs\",\n \"Isaiah\",\n \"Jeremiah\",\n \"Lamentations\",\n \"Ezekiel\",\n \"Daniel (Hebrew)\",\n \"Hosea\",\n \"Joel\",\n \"Amos\",\n \"Obadiah\",\n \"Jonah\",\n \"Micah\",\n \"Nahum\",\n \"Habakkuk\",\n \"Zephaniah\",\n \"Haggai\",\n \"Zechariah\",\n \"Malachi\",\n \"Matthew\",\n \"Mark\",\n \"Luke\",\n \"John\",\n \"Acts\",\n \"Romans\",\n \"1 Corinthians\",\n \"2 Corinthians\",\n \"Galatians\",\n \"Ephesians\",\n \"Philippians\",\n \"Colossians\",\n \"1 Thessalonians\",\n \"2 Thessalonians\",\n \"1 Timothy\",\n \"2 Timothy\",\n \"Titus\",\n \"Philemon\",\n \"Hebrews\",\n \"James\",\n \"1 Peter\",\n \"2 Peter\",\n \"1 John\",\n \"2 John\",\n \"3 John\",\n \"Jude\",\n \"Revelation\",\n \"Tobit\",\n \"Judith\",\n \"Esther Greek\",\n \"Wisdom of Solomon\",\n \"Sirach (Ecclesiasticus)\",\n \"Baruch\",\n \"Letter of Jeremiah\",\n \"Song of 3 Young Men\",\n \"Susanna\",\n \"Bel and the Dragon\",\n \"1 Maccabees\",\n \"2 Maccabees\",\n \"3 Maccabees\",\n \"4 Maccabees\",\n \"1 Esdras (Greek)\",\n \"2 Esdras (Latin)\",\n \"Prayer of Manasseh\",\n \"Psalm 151\",\n \"Odes\",\n \"Psalms of Solomon\",\n // WARNING, if you change the spelling of the *obsolete* tag be sure to update\n // IsObsolete routine\n \"Joshua A. *obsolete*\",\n \"Judges B. *obsolete*\",\n \"Tobit S. *obsolete*\",\n \"Susanna Th. *obsolete*\",\n \"Daniel Th. *obsolete*\",\n \"Bel Th. *obsolete*\",\n \"Extra A\",\n \"Extra B\",\n \"Extra C\",\n \"Extra D\",\n \"Extra E\",\n \"Extra F\",\n \"Extra G\",\n \"Front Matter\",\n \"Back Matter\",\n \"Other Matter\",\n \"3 Ezra *obsolete*\",\n \"Apocalypse of Ezra\",\n \"5 Ezra (Latin Prologue)\",\n \"6 Ezra (Latin Epilogue)\",\n \"Introduction\",\n \"Concordance \",\n \"Glossary \",\n \"Topical Index\",\n \"Names Index\",\n \"Daniel Greek\",\n \"Psalms 152-155\",\n \"2 Baruch (Apocalypse)\",\n \"Letter of Baruch\",\n \"Jubilees\",\n \"Enoch\",\n \"1 Meqabyan\",\n \"2 Meqabyan\",\n \"3 Meqabyan\",\n \"Reproof (Proverbs 25-31)\",\n \"4 Baruch (Rest of Baruch)\",\n \"Laodiceans\"\n], S = K();\nfunction g(t, e = !0) {\n return e && (t = t.toUpperCase()), t in S ? S[t] : 0;\n}\nfunction k(t) {\n return g(t) > 0;\n}\nfunction x(t) {\n const e = typeof t == \"string\" ? g(t) : t;\n return e >= 40 && e <= 66;\n}\nfunction T(t) {\n return (typeof t == \"string\" ? g(t) : t) <= 39;\n}\nfunction X(t) {\n return t <= 66;\n}\nfunction V(t) {\n const e = typeof t == \"string\" ? g(t) : t;\n return w(e) && !X(e);\n}\nfunction* L() {\n for (let t = 1; t <= N.length; t++) yield t;\n}\nconst G = 1, A = N.length;\nfunction H() {\n return [\"XXA\", \"XXB\", \"XXC\", \"XXD\", \"XXE\", \"XXF\", \"XXG\"];\n}\nfunction C(t, e = \"***\") {\n const s = t - 1;\n return s < 0 || s >= N.length ? e : N[s];\n}\nfunction I(t) {\n return t <= 0 || t > A ? \"******\" : O[t - 1];\n}\nfunction y(t) {\n return I(g(t));\n}\nfunction w(t) {\n const e = typeof t == \"number\" ? C(t) : t;\n return k(e) && !B.includes(e);\n}\nfunction q(t) {\n const e = typeof t == \"number\" ? C(t) : t;\n return k(e) && B.includes(e);\n}\nfunction U(t) {\n return O[t - 1].includes(\"*obsolete*\");\n}\nfunction K() {\n const t = {};\n for (let e = 0; e < N.length; e++)\n t[N[e]] = e + 1;\n return t;\n}\nconst m = {\n allBookIds: N,\n nonCanonicalIds: B,\n bookIdToNumber: g,\n isBookIdValid: k,\n isBookNT: x,\n isBookOT: T,\n isBookOTNT: X,\n isBookDC: V,\n allBookNumbers: L,\n firstBook: G,\n lastBook: A,\n extraBooks: H,\n bookNumberToId: C,\n bookNumberToEnglishName: I,\n bookIdToEnglishName: y,\n isCanonical: w,\n isExtraMaterial: q,\n isObsolete: U\n};\nvar l = /* @__PURE__ */ ((t) => (t[t.Unknown = 0] = \"Unknown\", t[t.Original = 1] = \"Original\", t[t.Septuagint = 2] = \"Septuagint\", t[t.Vulgate = 3] = \"Vulgate\", t[t.English = 4] = \"English\", t[t.RussianProtestant = 5] = \"RussianProtestant\", t[t.RussianOrthodox = 6] = \"RussianOrthodox\", t))(l || {});\nconst h = class h {\n // private versInfo: Versification;\n constructor(e) {\n n(this, \"name\");\n n(this, \"fullPath\");\n n(this, \"isPresent\");\n n(this, \"hasVerseSegments\");\n n(this, \"isCustomized\");\n n(this, \"baseVersification\");\n n(this, \"scriptureBooks\");\n n(this, \"_type\");\n if (e == null)\n throw new Error(\"Argument undefined\");\n typeof e == \"string\" ? (this.name = e, this._type = l[e]) : (this._type = e, this.name = l[e]);\n }\n get type() {\n return this._type;\n }\n equals(e) {\n return !e.type || !this.type ? !1 : e.type === this.type;\n }\n};\nn(h, \"Original\", new h(l.Original)), n(h, \"Septuagint\", new h(l.Septuagint)), n(h, \"Vulgate\", new h(l.Vulgate)), n(h, \"English\", new h(l.English)), n(h, \"RussianProtestant\", new h(l.RussianProtestant)), n(h, \"RussianOrthodox\", new h(l.RussianOrthodox));\nlet c = h;\nfunction E(t, e) {\n const s = e[0];\n for (let r = 1; r < e.length; r++)\n t = t.split(e[r]).join(s);\n return t.split(s);\n}\nvar D = /* @__PURE__ */ ((t) => (t[t.Valid = 0] = \"Valid\", t[t.UnknownVersification = 1] = \"UnknownVersification\", t[t.OutOfRange = 2] = \"OutOfRange\", t[t.VerseOutOfOrder = 3] = \"VerseOutOfOrder\", t[t.VerseRepeated = 4] = \"VerseRepeated\", t))(D || {});\nconst i = class i {\n constructor(e, s, r, a) {\n /** Not yet implemented. */\n n(this, \"firstChapter\");\n /** Not yet implemented. */\n n(this, \"lastChapter\");\n /** Not yet implemented. */\n n(this, \"lastVerse\");\n /** Not yet implemented. */\n n(this, \"hasSegmentsDefined\");\n /** Not yet implemented. */\n n(this, \"text\");\n /** Not yet implemented. */\n n(this, \"BBBCCCVVVS\");\n /** Not yet implemented. */\n n(this, \"longHashCode\");\n /** The versification of the reference. */\n n(this, \"versification\");\n n(this, \"rtlMark\", \"‏\");\n n(this, \"_bookNum\", 0);\n n(this, \"_chapterNum\", 0);\n n(this, \"_verseNum\", 0);\n n(this, \"_verse\");\n if (r == null && a == null)\n if (e != null && typeof e == \"string\") {\n const o = e, u = s != null && s instanceof c ? s : void 0;\n this.setEmpty(u), this.parse(o);\n } else if (e != null && typeof e == \"number\") {\n const o = s != null && s instanceof c ? s : void 0;\n this.setEmpty(o), this._verseNum = e % i.chapterDigitShifter, this._chapterNum = Math.floor(\n e % i.bookDigitShifter / i.chapterDigitShifter\n ), this._bookNum = Math.floor(e / i.bookDigitShifter);\n } else if (s == null)\n if (e != null && e instanceof i) {\n const o = e;\n this._bookNum = o.bookNum, this._chapterNum = o.chapterNum, this._verseNum = o.verseNum, this._verse = o.verse, this.versification = o.versification;\n } else {\n if (e == null) return;\n const o = e instanceof c ? e : i.defaultVersification;\n this.setEmpty(o);\n }\n else\n throw new Error(\"VerseRef constructor not supported.\");\n else if (e != null && s != null && r != null)\n if (typeof e == \"string\" && typeof s == \"string\" && typeof r == \"string\")\n this.setEmpty(a), this.updateInternal(e, s, r);\n else if (typeof e == \"number\" && typeof s == \"number\" && typeof r == \"number\")\n this._bookNum = e, this._chapterNum = s, this._verseNum = r, this.versification = a ?? i.defaultVersification;\n else\n throw new Error(\"VerseRef constructor not supported.\");\n else\n throw new Error(\"VerseRef constructor not supported.\");\n }\n /**\n * Determines if the verse string is in a valid format (does not consider versification).\n */\n static isVerseParseable(e) {\n return e.length > 0 && \"0123456789\".includes(e[0]) && !e.endsWith(this.verseRangeSeparator) && !e.endsWith(this.verseSequenceIndicator);\n }\n /**\n * Tries to parse the specified string into a verse reference.\n * @param str - The string to attempt to parse.\n * @returns success: `true` if the specified string was successfully parsed, `false` otherwise.\n * @returns verseRef: The result of the parse if successful, or empty VerseRef if it failed\n */\n static tryParse(e) {\n let s;\n try {\n return s = new i(e), { success: !0, verseRef: s };\n } catch (r) {\n if (r instanceof v)\n return s = new i(), { success: !1, verseRef: s };\n throw r;\n }\n }\n /**\n * Gets the reference as a comparable integer where the book, chapter, and verse each occupy 3\n * digits.\n * @param bookNum - Book number (this is 1-based, not an index).\n * @param chapterNum - Chapter number.\n * @param verseNum - Verse number.\n * @returns The reference as a comparable integer where the book, chapter, and verse each occupy 3\n * digits.\n */\n static getBBBCCCVVV(e, s, r) {\n return e % i.bcvMaxValue * i.bookDigitShifter + (s >= 0 ? s % i.bcvMaxValue * i.chapterDigitShifter : 0) + (r >= 0 ? r % i.bcvMaxValue : 0);\n }\n /**\n * Deserializes a serialized VerseRef.\n * @param serializedVerseRef - Serialized VerseRef to create from.\n * @returns the deserialized VerseRef.\n */\n static fromJSON(e) {\n const { book: s, chapterNum: r, verseNum: a, verse: o, versificationStr: u } = e, f = o || a.toString();\n let d;\n return u && (d = new c(u)), s ? new i(s, r.toString(), f, d) : new i();\n }\n /**\n * Parses a verse string and gets the leading numeric portion as a number.\n * @param verseStr - verse string to parse\n * @returns true if the entire string could be parsed as a single, simple verse number (1-999);\n * false if the verse string represented a verse bridge, contained segment letters, or was invalid\n */\n static tryGetVerseNum(e) {\n let s;\n if (!e)\n return s = -1, { success: !0, vNum: s };\n s = 0;\n let r;\n for (let a = 0; a < e.length; a++) {\n if (r = e[a], r < \"0\" || r > \"9\")\n return a === 0 && (s = -1), { success: !1, vNum: s };\n if (s = s * 10 + +r - 0, s > i.bcvMaxValue)\n return s = -1, { success: !1, vNum: s };\n }\n return { success: !0, vNum: s };\n }\n /**\n * Checks to see if a VerseRef hasn't been set - all values are the default.\n */\n get isDefault() {\n return this.bookNum === 0 && this.chapterNum === 0 && this.verseNum === 0 && this.versification == null;\n }\n /**\n * Gets whether the verse contains multiple verses.\n */\n get hasMultiple() {\n return this._verse != null && (this._verse.includes(i.verseRangeSeparator) || this._verse.includes(i.verseSequenceIndicator));\n }\n /**\n * Gets or sets the book of the reference. Book is the 3-letter abbreviation in capital letters,\n * e.g. `'MAT'`.\n */\n get book() {\n return m.bookNumberToId(this.bookNum, \"\");\n }\n set book(e) {\n this.bookNum = m.bookIdToNumber(e);\n }\n /**\n * Gets or sets the chapter of the reference,. e.g. `'3'`.\n */\n get chapter() {\n return this.isDefault || this._chapterNum < 0 ? \"\" : this._chapterNum.toString();\n }\n set chapter(e) {\n const s = +e;\n this._chapterNum = Number.isInteger(s) ? s : -1;\n }\n /**\n * Gets or sets the verse of the reference, including range, segments, and sequences, e.g. `'4'`,\n * or `'4b-5a, 7'`.\n */\n get verse() {\n return this._verse != null ? this._verse : this.isDefault || this._verseNum < 0 ? \"\" : this._verseNum.toString();\n }\n set verse(e) {\n const { success: s, vNum: r } = i.tryGetVerseNum(e);\n this._verse = s ? void 0 : e.replace(this.rtlMark, \"\"), this._verseNum = r, !(this._verseNum >= 0) && ({ vNum: this._verseNum } = i.tryGetVerseNum(this._verse));\n }\n /**\n * Get or set Book based on book number, e.g. `42`.\n */\n get bookNum() {\n return this._bookNum;\n }\n set bookNum(e) {\n if (e <= 0 || e > m.lastBook)\n throw new v(\n \"BookNum must be greater than zero and less than or equal to last book\"\n );\n this._bookNum = e;\n }\n /**\n * Gets or sets the chapter number, e.g. `3`. `-1` if not valid.\n */\n get chapterNum() {\n return this._chapterNum;\n }\n set chapterNum(e) {\n this.chapterNum = e;\n }\n /**\n * Gets or sets verse start number, e.g. `4`. `-1` if not valid.\n */\n get verseNum() {\n return this._verseNum;\n }\n set verseNum(e) {\n this._verseNum = e;\n }\n /**\n * String representing the versification (should ONLY be used for serialization/deserialization).\n *\n * @remarks This is for backwards compatibility when ScrVers was an enumeration.\n */\n get versificationStr() {\n var e;\n return (e = this.versification) == null ? void 0 : e.name;\n }\n set versificationStr(e) {\n this.versification = this.versification != null ? new c(e) : void 0;\n }\n /**\n * Determines if the reference is valid.\n */\n get valid() {\n return this.validStatus === 0;\n }\n /**\n * Get the valid status for this reference.\n */\n get validStatus() {\n return this.validateVerse(i.verseRangeSeparators, i.verseSequenceIndicators);\n }\n /**\n * Gets the reference as a comparable integer where the book,\n * chapter, and verse each occupy three digits and the verse is 0.\n */\n get BBBCCC() {\n return i.getBBBCCCVVV(this._bookNum, this._chapterNum, 0);\n }\n /**\n * Gets the reference as a comparable integer where the book,\n * chapter, and verse each occupy three digits. If verse is not null\n * (i.e., this reference represents a complex reference with verse\n * segments or bridge) this cannot be used for an exact comparison.\n */\n get BBBCCCVVV() {\n return i.getBBBCCCVVV(this._bookNum, this._chapterNum, this._verseNum);\n }\n /**\n * Gets whether the verse is defined as an excluded verse in the versification.\n * Does not handle verse ranges.\n */\n // eslint-disable-next-line @typescript-eslint/class-literal-property-style\n get isExcluded() {\n return !1;\n }\n /**\n * Parses the reference in the specified string.\n * Optionally versification can follow reference as in GEN 3:11/4\n * Throw an exception if\n * - invalid book name\n * - chapter number is missing or not a number\n * - verse number is missing or does not start with a number\n * - versification is invalid\n * @param verseStr - string to parse e.g. 'MAT 3:11'\n */\n parse(e) {\n if (e = e.replace(this.rtlMark, \"\"), e.includes(\"/\")) {\n const o = e.split(\"/\");\n if (e = o[0], o.length > 1)\n try {\n const u = +o[1].trim();\n this.versification = new c(l[u]);\n } catch {\n throw new v(\"Invalid reference : \" + e);\n }\n }\n const s = e.trim().split(\" \");\n if (s.length !== 2)\n throw new v(\"Invalid reference : \" + e);\n const r = s[1].split(\":\"), a = +r[0];\n if (r.length !== 2 || m.bookIdToNumber(s[0]) === 0 || !Number.isInteger(a) || a < 0 || !i.isVerseParseable(r[1]))\n throw new v(\"Invalid reference : \" + e);\n this.updateInternal(s[0], r[0], r[1]);\n }\n /**\n * Simplifies this verse ref so that it has no bridging of verses or\n * verse segments like `'1a'`.\n */\n simplify() {\n this._verse = void 0;\n }\n /**\n * Makes a clone of the reference.\n *\n * @returns The cloned VerseRef.\n */\n clone() {\n return new i(this);\n }\n toString() {\n const e = this.book;\n return e === \"\" ? \"\" : `${e} ${this.chapter}:${this.verse}`;\n }\n toJSON() {\n let e = this.verse;\n (e === \"\" || e === this.verseNum.toString()) && (e = void 0);\n const s = {\n book: this.book,\n chapterNum: this.chapterNum,\n verseNum: this.verseNum,\n verse: e,\n versificationStr: this.versificationStr\n };\n return e || delete s.verse, s;\n }\n /**\n * Compares this `VerseRef` with supplied one.\n * @param verseRef - object to compare this one to.\n * @returns `true` if this `VerseRef` is equal to the supplied one, `false` otherwise.\n */\n equals(e) {\n return e instanceof i ? e._bookNum === this._bookNum && e._chapterNum === this._chapterNum && e._verseNum === this._verseNum && e.verse === this.verse && (e.versification == null && this.versification == null || e.versification != null && this.versification != null && e.versification.equals(this.versification)) : !1;\n }\n /**\n * Enumerate all individual verses contained in a VerseRef.\n * Verse ranges are indicated by \"-\" and consecutive verses by \",\"s.\n * Examples:\n * GEN 1:2 returns GEN 1:2\n * GEN 1:1a-3b,5 returns GEN 1:1a, GEN 1:2, GEN 1:3b, GEN 1:5\n * GEN 1:2a-2c returns //! ??????\n *\n * @param specifiedVersesOnly - if set to true return only verses that are\n * explicitly specified only, not verses within a range. Defaults to `false`.\n * @param verseRangeSeparators - Verse range separators.\n * Defaults to `VerseRef.verseRangeSeparators`.\n * @param verseSequenceSeparators - Verse sequence separators.\n * Defaults to `VerseRef.verseSequenceIndicators`.\n * @returns An array of all single verse references in this VerseRef.\n */\n allVerses(e = !1, s = i.verseRangeSeparators, r = i.verseSequenceIndicators) {\n if (this._verse == null || this.chapterNum <= 0)\n return [this.clone()];\n const a = [], o = E(this._verse, r);\n for (const u of o.map((f) => E(f, s))) {\n const f = this.clone();\n f.verse = u[0];\n const d = f.verseNum;\n if (a.push(f), u.length > 1) {\n const b = this.clone();\n if (b.verse = u[1], !e)\n for (let p = d + 1; p < b.verseNum; p++) {\n const J = new i(\n this._bookNum,\n this._chapterNum,\n p,\n this.versification\n );\n this.isExcluded || a.push(J);\n }\n a.push(b);\n }\n }\n return a;\n }\n /**\n * Validates a verse number using the supplied separators rather than the defaults.\n */\n validateVerse(e, s) {\n if (!this.verse)\n return this.internalValid;\n let r = 0;\n for (const a of this.allVerses(!0, e, s)) {\n const o = a.internalValid;\n if (o !== 0)\n return o;\n const u = a.BBBCCCVVV;\n if (r > u)\n return 3;\n if (r === u)\n return 4;\n r = u;\n }\n return 0;\n }\n /**\n * Gets whether a single verse reference is valid.\n */\n get internalValid() {\n return this.versification == null ? 1 : this._bookNum <= 0 || this._bookNum > m.lastBook ? 2 : (m.isCanonical(this._bookNum), 0);\n }\n setEmpty(e = i.defaultVersification) {\n this._bookNum = 0, this._chapterNum = -1, this._verse = void 0, this.versification = e;\n }\n updateInternal(e, s, r) {\n this.bookNum = m.bookIdToNumber(e), this.chapter = s, this.verse = r;\n }\n};\nn(i, \"defaultVersification\", c.English), n(i, \"verseRangeSeparator\", \"-\"), n(i, \"verseSequenceIndicator\", \",\"), n(i, \"verseRangeSeparators\", [i.verseRangeSeparator]), n(i, \"verseSequenceIndicators\", [i.verseSequenceIndicator]), n(i, \"chapterDigitShifter\", 1e3), n(i, \"bookDigitShifter\", i.chapterDigitShifter * i.chapterDigitShifter), n(i, \"bcvMaxValue\", i.chapterDigitShifter - 1), /**\n * The valid status of the VerseRef.\n */\nn(i, \"ValidStatusType\", D);\nlet M = i;\nclass v extends Error {\n}\nexport {\n _ as BookSet,\n m as Canon,\n c as ScrVers,\n l as ScrVersType,\n M as VerseRef,\n v as VerseRefException\n};\n//# sourceMappingURL=index.es.js.map\n","import React from 'react';\nimport * as DropdownMenuPrimitive from '@radix-ui/react-dropdown-menu';\nimport { Check, ChevronRight, Circle } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport const DropdownMenu = DropdownMenuPrimitive.Root;\n\nexport const DropdownMenuTrigger = DropdownMenuPrimitive.Trigger;\n\nexport const DropdownMenuGroup = DropdownMenuPrimitive.Group;\n\nexport const DropdownMenuPortal = DropdownMenuPrimitive.Portal;\n\nexport const DropdownMenuSub = DropdownMenuPrimitive.Sub;\n\nexport const DropdownMenuRadioGroup = DropdownMenuPrimitive.RadioGroup;\n\nexport type DropdownMenuSubTriggerProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.SubTrigger\n> & {\n className?: string;\n inset?: boolean;\n};\n\nexport type DropdownMenuSubContentProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.SubContent\n> & {\n className?: string;\n};\n\nexport type DropdownMenuContentProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Content\n> & {\n className?: string;\n sideOffset?: number;\n};\n\nexport type DropdownMenuItemProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Item\n> & {\n className?: string;\n inset?: boolean;\n};\n\nexport type DropdownMenuCheckboxItemProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.CheckboxItem\n> & {\n className?: string;\n checked?: boolean;\n};\n\nexport type DropdownMenuRadioItemProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.RadioItem\n> & {\n className?: string;\n};\n\nexport type DropdownMenuLabelProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Label\n> & {\n className?: string;\n inset?: boolean;\n};\n\nexport type DropdownMenuSeparatorProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Separator\n> & {\n className?: string;\n};\n\nexport type DropdownMenuShortcutProps = React.HTMLAttributes & {\n className?: string;\n};\n\nexport const DropdownMenuSubTrigger = React.forwardRef<\n React.ElementRef,\n DropdownMenuSubTriggerProps\n>(({ className, inset, children, ...props }, ref) => (\n \n {children}\n \n \n));\nDropdownMenuSubTrigger.displayName = DropdownMenuPrimitive.SubTrigger.displayName;\n\nexport const DropdownMenuSubContent = React.forwardRef<\n React.ElementRef,\n DropdownMenuSubContentProps\n>(({ className, ...props }, ref) => (\n \n));\nDropdownMenuSubContent.displayName = DropdownMenuPrimitive.SubContent.displayName;\n\nexport const DropdownMenuContent = React.forwardRef<\n React.ElementRef,\n DropdownMenuContentProps\n>(({ className, sideOffset = 4, ...props }, ref) => (\n \n \n \n));\nDropdownMenuContent.displayName = DropdownMenuPrimitive.Content.displayName;\n\n/**\n * TODO: fix: direction is not automatically handled by this component, so that shortcuts are\n * display always to the right\n */\nexport const DropdownMenuItem = React.forwardRef<\n React.ElementRef,\n DropdownMenuItemProps\n>(({ className, inset, ...props }, ref) => (\n \n));\nDropdownMenuItem.displayName = DropdownMenuPrimitive.Item.displayName;\n\nexport const DropdownMenuCheckboxItem = React.forwardRef<\n React.ElementRef,\n DropdownMenuCheckboxItemProps\n>(({ className, children, checked, ...props }, ref) => (\n \n \n \n \n \n \n {children}\n \n));\nDropdownMenuCheckboxItem.displayName = DropdownMenuPrimitive.CheckboxItem.displayName;\n\nexport const DropdownMenuRadioItem = React.forwardRef<\n React.ElementRef,\n DropdownMenuRadioItemProps\n>(({ className, children, ...props }, ref) => (\n \n \n \n \n \n \n {children}\n \n));\nDropdownMenuRadioItem.displayName = DropdownMenuPrimitive.RadioItem.displayName;\n\nexport const DropdownMenuLabel = React.forwardRef<\n React.ElementRef,\n DropdownMenuLabelProps\n>(({ className, inset, ...props }, ref) => (\n \n));\nDropdownMenuLabel.displayName = DropdownMenuPrimitive.Label.displayName;\n\nexport const DropdownMenuSeparator = React.forwardRef<\n React.ElementRef,\n DropdownMenuSeparatorProps\n>(({ className, ...props }, ref) => (\n \n));\nDropdownMenuSeparator.displayName = DropdownMenuPrimitive.Separator.displayName;\n\nexport function DropdownMenuShortcut({ className, ...props }: DropdownMenuShortcutProps) {\n return (\n \n );\n}\nDropdownMenuShortcut.displayName = 'DropdownMenuShortcut';\n","import { Canon } from '@sillsdev/scripture';\nimport { PropsWithChildren, KeyboardEvent, forwardRef } from 'react';\nimport { DropdownMenuItem as ShadDropdownMenuItem } from '@/components/shadcn-ui/dropdown-menu';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport type BookType = 'OT' | 'NT' | 'DC';\n\ntype BookMenuItemProps = PropsWithChildren<{\n /** String id of book */\n bookId: string;\n /** Callback to run when a book menu item is selected */\n handleSelectBook: () => void;\n /** Indicates if this menu item is currently selected */\n isSelected: boolean;\n /** Function that is called upon highlighting a book in the dropdown menu */\n handleHighlightBook: () => void;\n /**\n * Function that is called on pressing a key\n *\n * @param event Event that contains information about the key stroke\n */\n handleKeyDown: (event: KeyboardEvent) => void;\n /**\n * Type of book associated with this menu item, coordinates color labels ? Mock up has the labels\n * coordinated to genre\n */\n bookType: BookType;\n}>;\n\nconst BookMenuItem = forwardRef(\n (\n {\n bookId,\n handleSelectBook,\n isSelected,\n handleHighlightBook,\n handleKeyDown,\n bookType,\n children,\n }: BookMenuItemProps,\n ref,\n ) => {\n return (\n {\n // preventDefault() here prevents the entire dropdown menu from closing when selecting this item\n event.preventDefault();\n handleSelectBook();\n }}\n onKeyDown={(event: KeyboardEvent) => {\n handleKeyDown(event);\n }}\n onFocus={handleHighlightBook}\n onMouseMove={handleHighlightBook}\n >\n \n {Canon.bookIdToEnglishName(bookId)}\n \n {isSelected &&
    {children}
    }\n \n );\n },\n);\n\nexport default BookMenuItem;\n","import { cn } from '@/utils/shadcn-ui.util';\nimport { useCallback } from 'react';\n\nexport type ChapterSelectProps = {\n /**\n * Callback to run when a chapter div is selected\n *\n * @param chapterNumber Number of the chapter that has been selected\n */\n handleSelectChapter: (chapterNumber: number) => void;\n /** The highest chapter number in the book (of course equal to number of chapters in the book) */\n endChapter: number;\n /** The chapter number that is currently selected */\n activeChapter: number;\n /** The chapter number that is currently highlighted using keyboard or mouse navigation */\n highlightedChapter: number;\n /**\n * Callback to run when a chapter is highlighted by the user\n *\n * @param chapterNumber The chapter that is highlighted\n */\n handleHighlightedChapter: (chapterNumber: number) => void;\n};\n\nfunction ChapterSelect({\n handleSelectChapter,\n endChapter,\n activeChapter,\n highlightedChapter,\n handleHighlightedChapter,\n}: ChapterSelectProps) {\n const chapters = Array.from({ length: endChapter }, (_, i) => i + 1);\n\n const handleMouse = useCallback(\n (chapterNumber: number) => {\n handleHighlightedChapter(chapterNumber);\n },\n [handleHighlightedChapter],\n );\n\n return (\n
    \n {chapters.map((chapter) => (\n {\n event.preventDefault();\n event.stopPropagation();\n handleSelectChapter(chapter);\n }}\n role=\"button\"\n onKeyDown={(event) => {\n if (event.key === 'Enter') {\n handleSelectChapter(chapter);\n }\n }}\n tabIndex={0}\n onMouseMove={() => handleMouse(chapter)}\n >\n {chapter}\n
    \n ))}\n
    \n );\n}\n\nexport default ChapterSelect;\n","import { DropdownMenuLabel as ShadDropdownMenuLabel } from '@/components/shadcn-ui/dropdown-menu';\nimport { Bookmark, Clock, ArrowDownWideNarrow } from 'lucide-react';\n\nexport type GoToMenuItemProps = {\n handleSort: () => void;\n handleLocationHistory: () => void;\n handleBookmarks: () => void;\n};\n\nfunction GoToMenuItem({ handleSort, handleLocationHistory, handleBookmarks }: GoToMenuItemProps) {\n return (\n \n

    Go To

    \n
    \n \n \n \n
    \n
    \n );\n}\n\nexport default GoToMenuItem;\n","import BookChapterInput from '@/components/advanced/book-chapter-control/book-chapter-input.component';\nimport BookMenuItem, {\n BookType,\n} from '@/components/advanced/book-chapter-control/book-menu-item.component';\nimport ChapterSelect from '@/components/advanced/book-chapter-control/chapter-select.component';\nimport GoToMenuItem from '@/components/advanced/book-chapter-control/go-to-menu-item.component';\nimport {\n DropdownMenu as ShadDropdownMenu,\n DropdownMenuContent as ShadDropdownMenuContent,\n DropdownMenuLabel as ShadDropdownMenuLabel,\n DropdownMenuSeparator as ShadDropdownMenuSeparator,\n DropdownMenuTrigger as ShadDropdownMenuTrigger,\n} from '@/components/shadcn-ui/dropdown-menu';\nimport { Canon } from '@sillsdev/scripture';\nimport { ScriptureReference, getChaptersForBook } from 'platform-bible-utils';\nimport {\n KeyboardEvent as ReactKeyboardEvent,\n useCallback,\n useEffect,\n useLayoutEffect,\n useRef,\n useState,\n} from 'react';\n\ntype BookTypeLabels = {\n [bookType in BookType]: string;\n};\ntype BookChapterControlProps = {\n scrRef: ScriptureReference;\n handleSubmit: (scrRef: ScriptureReference) => void;\n};\n\nconst ALL_BOOK_IDS = Canon.allBookIds;\nconst BOOK_TYPE_LABELS: BookTypeLabels = {\n OT: 'Old Testament',\n NT: 'New Testament',\n DC: 'Deuterocanon',\n};\nconst BOOK_TYPE_ARRAY: BookType[] = ['OT', 'NT', 'DC'];\n// This is the height of three menu items to offset scrolling to the selected menu item\n// If you use menuItemRef.clientHeight- includes height of chapter div which is too big\nconst SCROLL_OFFSET = 32 + 32 + 32;\nconst SEARCH_QUERY_FORMATS = [\n /^(\\w+)$/i, // Matches a single word (book name or id)\n /^(\\w+)(?:\\s(\\d+))$/i, // Matches a word followed by a chapter number\n /^(\\w+)(?:\\s(\\d+):(\\d+))$/i, // Matches a word followed by a chapter and verse number\n];\nconst fetchGroupedBooks = (bookType: BookType) => {\n const groupedBooks = {\n OT: ALL_BOOK_IDS.filter((bookId) => Canon.isBookOT(bookId)),\n NT: ALL_BOOK_IDS.filter((bookId) => Canon.isBookNT(bookId)),\n DC: ALL_BOOK_IDS.filter((bookId) => Canon.isBookDC(bookId)),\n };\n return groupedBooks[bookType];\n};\nconst fetchEndChapter = (bookId: string) => {\n // getChaptersForBook returns -1 if not found in scrBookData\n // scrBookData only includes OT and NT, so all DC will return -1\n return getChaptersForBook(Canon.bookIdToNumber(bookId));\n};\n\n/**\n * Gets all of the English names from book ids\n *\n * @returns String[]\n */\nfunction getAllEnglishNames(): string[] {\n const allEnglishNames = ALL_BOOK_IDS.map((bookId) => {\n return Canon.bookIdToEnglishName(bookId);\n });\n return allEnglishNames;\n}\n\n/**\n * Determines if bookName is in allEnglishNames\n *\n * @param bookName Book English name\n * @returns True if bookName is included, false otherwise\n */\nfunction isValidBookEnglishName(bookName: string): boolean {\n return getAllEnglishNames().includes(bookName);\n}\n\n/**\n * Gets a bookId from given English name\n *\n * @param bookName Book English name\n * @returns BookId of provided bookName, undefined otherwise\n */\nfunction getBookIdFromEnglishName(bookName: string): string | undefined {\n // Convert bookName to lowercase and then capitalize the first letter\n const formattedBookName = bookName.toLowerCase().replace(/^\\w/, (c) => c.toUpperCase());\n\n if (isValidBookEnglishName(formattedBookName)) {\n const matchingBookId = ALL_BOOK_IDS.find((bookId) => {\n return Canon.bookIdToEnglishName(bookId) === formattedBookName;\n });\n return matchingBookId;\n }\n\n return undefined;\n}\n\nfunction BookChapterControl({ scrRef, handleSubmit }: BookChapterControlProps) {\n const [searchQuery, setSearchQuery] = useState('');\n const [selectedBookId, setSelectedBookId] = useState(\n Canon.bookNumberToId(scrRef.bookNum),\n );\n const [highlightedChapter, setHighlightedChapter] = useState(scrRef.chapterNum ?? 0);\n const [highlightedBookId, setHighlightedBookId] = useState(\n Canon.bookNumberToId(scrRef.bookNum),\n );\n const [isContentOpen, setIsContentOpen] = useState(false);\n const [isContentOpenDelayed, setIsContentOpenDelayed] = useState(isContentOpen);\n\n // This ref will always be defined\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const inputRef = useRef(undefined!);\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const contentRef = useRef(undefined!);\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const menuItemRef = useRef(undefined!);\n\n const fetchFilteredBooks = useCallback(\n (bookType: BookType) => {\n return fetchGroupedBooks(bookType).filter((bookId: string) => {\n const englishNameLowerCase = Canon.bookIdToEnglishName(bookId).toLowerCase();\n const normalizedQuery = searchQuery.replace(/[^a-zA-Z]/g, '').toLowerCase();\n return (\n englishNameLowerCase.includes(normalizedQuery) || // Match book name\n bookId.toLowerCase().includes(normalizedQuery) // Match book ID\n );\n });\n },\n [searchQuery],\n );\n\n const handleSearchInput = (searchString: string) => {\n setSearchQuery(searchString);\n };\n\n /**\n * Whether to prevent radix's logic from closing the dropdown. This is important because radix\n * tries to close the dropdown when the input first focuses, and we don't want it to do that. But\n * we don't want to prevent the dropdown from closing when we click away from the input, so we\n * don't want to just keep it open if the input is focused\n */\n const shouldPreventAutoClosing = useRef(false);\n\n const controlMenuState = useCallback((open: boolean) => {\n if (shouldPreventAutoClosing.current) {\n shouldPreventAutoClosing.current = false;\n return;\n }\n setIsContentOpen(open);\n }, []);\n\n const updateReference = useCallback(\n (bookId: string, shouldClose: boolean, chapter?: number, verse?: number) => {\n setHighlightedChapter(\n Canon.bookNumberToId(scrRef.bookNum) !== bookId ? 1 : scrRef.chapterNum,\n );\n\n if (shouldClose || fetchEndChapter(bookId) === -1) {\n handleSubmit({\n bookNum: Canon.bookIdToNumber(bookId),\n chapterNum: chapter || 1,\n verseNum: verse || 1,\n });\n\n setIsContentOpen(false);\n setSearchQuery('');\n return;\n }\n\n setSelectedBookId(selectedBookId !== bookId ? bookId : '');\n setIsContentOpen(!shouldClose);\n },\n [handleSubmit, scrRef.bookNum, scrRef.chapterNum, selectedBookId],\n );\n\n const handleSelectChapter = (chapterNumber: number) => {\n if (chapterNumber <= 0 || chapterNumber > fetchEndChapter(selectedBookId)) {\n return;\n }\n updateReference(selectedBookId, true, chapterNumber);\n };\n\n const handleInputSubmit = useCallback(() => {\n SEARCH_QUERY_FORMATS.forEach((format) => {\n const matches = searchQuery.match(format);\n if (matches) {\n // Book should be a bookId or an english name\n const [book, chapter = undefined, verse = undefined] = matches.slice(1);\n const englishName = getBookIdFromEnglishName(book);\n\n if (Canon.isBookIdValid(book) || englishName) {\n updateReference(\n englishName ?? book,\n true,\n chapter ? parseInt(chapter, 10) : 1,\n verse ? parseInt(verse, 10) : 1,\n );\n }\n }\n });\n }, [updateReference, searchQuery]);\n\n const handleKeyDownInput = useCallback(\n (event: ReactKeyboardEvent) => {\n if (!isContentOpen) {\n setIsContentOpen(true);\n } else if (event.key === 'ArrowDown' || event.key === 'ArrowUp') {\n if (\n typeof menuItemRef !== 'undefined' &&\n // Ref uses null\n // eslint-disable-next-line no-null/no-null\n menuItemRef.current !== null\n ) {\n menuItemRef.current.focus();\n } else if (\n typeof contentRef !== 'undefined' &&\n // Ref uses null\n // eslint-disable-next-line no-null/no-null\n contentRef.current !== null\n ) {\n contentRef.current.focus();\n }\n event.preventDefault();\n }\n },\n [isContentOpen],\n );\n\n const handleKeyDownContent = (event: ReactKeyboardEvent) => {\n // When the dropdown menu has focus, key strokes should give focus to the input component,\n // unless they're navigation keys (arrows and enter)\n const { key } = event;\n if (\n key === 'ArrowRight' ||\n key === 'ArrowLeft' ||\n key === 'ArrowDown' ||\n key === 'ArrowUp' ||\n key === 'Enter'\n ) {\n return;\n }\n\n inputRef.current.dispatchEvent(new KeyboardEvent('keydown', { key }));\n inputRef.current.focus();\n };\n\n const handleKeyDownMenuItem = (event: ReactKeyboardEvent) => {\n const { key } = event;\n if (highlightedBookId === selectedBookId) {\n if (key === 'Enter') {\n event.preventDefault();\n updateReference(selectedBookId, true, highlightedChapter);\n return;\n }\n\n let chapterOffSet = 0;\n if (key === 'ArrowRight') {\n if (highlightedChapter < fetchEndChapter(highlightedBookId)) {\n chapterOffSet = 1;\n } else {\n event.preventDefault();\n return;\n }\n } else if (key === 'ArrowLeft') {\n if (highlightedChapter > 1) {\n chapterOffSet = -1;\n } else {\n event.preventDefault();\n return;\n }\n } else if (key === 'ArrowDown') {\n chapterOffSet = 6;\n } else if (key === 'ArrowUp') {\n chapterOffSet = -6;\n }\n if (\n highlightedChapter + chapterOffSet <= 0 ||\n highlightedChapter + chapterOffSet > fetchEndChapter(highlightedBookId)\n ) {\n setHighlightedChapter(0);\n } else if (chapterOffSet !== 0) {\n setHighlightedChapter(highlightedChapter + chapterOffSet);\n event.preventDefault();\n }\n }\n };\n\n useEffect(() => {\n if (selectedBookId === highlightedBookId) {\n if (selectedBookId === Canon.bookNumberToId(scrRef.bookNum)) {\n setHighlightedChapter(scrRef.chapterNum);\n } else {\n setHighlightedChapter(1);\n }\n } else {\n setHighlightedChapter(0);\n }\n }, [highlightedBookId, scrRef.bookNum, scrRef.chapterNum, selectedBookId]);\n\n // The purpose of these useLayoutEffects and timeout is to delay the scroll just\n // enough so that the refs are defined and available when they are used after the timeout\n useLayoutEffect(() => {\n setIsContentOpenDelayed(isContentOpen);\n }, [isContentOpen]);\n\n useLayoutEffect(() => {\n const scrollTimeout = setTimeout(() => {\n if (isContentOpenDelayed && contentRef.current && menuItemRef.current) {\n const menuItemOffsetTop = menuItemRef.current.offsetTop;\n const scrollPosition = menuItemOffsetTop - SCROLL_OFFSET;\n contentRef.current.scrollTo({ top: scrollPosition, behavior: 'instant' });\n }\n }, 10);\n return () => {\n clearTimeout(scrollTimeout);\n };\n }, [isContentOpenDelayed]);\n\n return (\n
    \n \n \n {\n setSelectedBookId(Canon.bookNumberToId(scrRef.bookNum));\n setHighlightedBookId(Canon.bookNumberToId(scrRef.bookNum));\n setHighlightedChapter(scrRef.chapterNum > 0 ? scrRef.chapterNum : 0);\n setIsContentOpen(true);\n inputRef.current.focus();\n }}\n onFocus={() => {\n // Radix thinks we want to close because the input is being focused. Prevent that\n shouldPreventAutoClosing.current = true;\n }}\n handleSubmit={handleInputSubmit}\n placeholder={`${Canon.bookNumberToEnglishName(scrRef.bookNum)} ${scrRef.chapterNum}:${scrRef.verseNum}`}\n />\n \n \n console.log('sorting')}\n handleLocationHistory={() => console.log('location history')}\n handleBookmarks={() => console.log('bookmarks')}\n />\n {BOOK_TYPE_ARRAY.map(\n (bookType, bookTypeIndex) =>\n fetchFilteredBooks(bookType).length > 0 && (\n
    \n \n {BOOK_TYPE_LABELS[bookType]}\n \n\n {fetchFilteredBooks(bookType).map((bookId) => (\n
    \n updateReference(bookId, false)}\n isSelected={selectedBookId === bookId}\n handleHighlightBook={() => setHighlightedBookId(bookId)}\n handleKeyDown={handleKeyDownMenuItem}\n bookType={bookType}\n ref={(element: HTMLDivElement) => {\n if (selectedBookId === bookId) menuItemRef.current = element;\n }}\n >\n {\n setHighlightedChapter(chapterNumber);\n }}\n />\n \n
    \n ))}\n {BOOK_TYPE_ARRAY.length - 1 !== bookTypeIndex ? (\n \n ) : undefined}\n
    \n ),\n )}\n \n
    \n
    \n );\n}\n\nexport default BookChapterControl;\n","import React from 'react';\nimport { Slot } from '@radix-ui/react-slot';\nimport { cva, type VariantProps } from 'class-variance-authority';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport const buttonVariants = cva(\n 'pr-twp tw-inline-flex tw-items-center tw-justify-center tw-whitespace-nowrap tw-rounded-md tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-colors focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50',\n {\n variants: {\n variant: {\n default: 'tw-bg-primary tw-text-primary-foreground hover:tw-bg-primary/90',\n destructive: 'tw-bg-destructive tw-text-destructive-foreground hover:tw-bg-destructive/90',\n outline:\n 'tw-border tw-border-input tw-bg-background hover:tw-bg-accent hover:tw-text-accent-foreground',\n secondary: 'tw-bg-secondary tw-text-secondary-foreground hover:tw-bg-secondary/80',\n ghost: 'hover:tw-bg-accent hover:tw-text-accent-foreground',\n link: 'tw-text-primary tw-underline-offset-4 hover:tw-underline',\n },\n size: {\n default: 'tw-h-10 tw-px-4 tw-py-2',\n sm: 'tw-h-9 tw-rounded-md tw-px-3',\n lg: 'tw-h-11 tw-rounded-md tw-px-8',\n icon: 'tw-h-10 tw-w-10',\n },\n },\n defaultVariants: {\n variant: 'default',\n size: 'default',\n },\n },\n);\n\nexport interface ButtonProps\n extends React.ButtonHTMLAttributes,\n VariantProps {\n asChild?: boolean;\n}\n\nexport const Button = React.forwardRef(\n ({ className, variant, size, asChild = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'button';\n return (\n \n );\n },\n);\nButton.displayName = 'Button';\n","import React from 'react';\nimport * as LabelPrimitive from '@radix-ui/react-label';\nimport { cva, type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst labelVariants = cva(\n 'tw-text-sm tw-font-medium tw-leading-none peer-disabled:tw-cursor-not-allowed peer-disabled:tw-opacity-70',\n);\n\nexport const Label = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef & VariantProps\n>(({ className, ...props }, ref) => (\n \n));\nLabel.displayName = LabelPrimitive.Root.displayName;\n","import React from 'react';\nimport * as RadioGroupPrimitive from '@radix-ui/react-radio-group';\nimport { Circle } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst RadioGroup = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => {\n return (\n \n );\n});\nRadioGroup.displayName = RadioGroupPrimitive.Root.displayName;\n\nconst RadioGroupItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => {\n return (\n \n \n \n \n \n );\n});\nRadioGroupItem.displayName = RadioGroupPrimitive.Item.displayName;\n\nexport { RadioGroup, RadioGroupItem };\n","import React from 'react';\nimport * as PopoverPrimitive from '@radix-ui/react-popover';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Popover = PopoverPrimitive.Root;\n\nconst PopoverTrigger = PopoverPrimitive.Trigger;\n\nconst PopoverContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, align = 'center', sideOffset = 4, ...props }, ref) => (\n \n \n \n));\nPopoverContent.displayName = PopoverPrimitive.Content.displayName;\n\nexport { Popover, PopoverTrigger, PopoverContent };\n","import React from 'react';\nimport * as DialogPrimitive from '@radix-ui/react-dialog';\nimport { X } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Dialog = DialogPrimitive.Root;\n\nconst DialogTrigger = DialogPrimitive.Trigger;\n\nconst DialogPortal = DialogPrimitive.Portal;\n\nconst DialogClose = DialogPrimitive.Close;\n\nconst DialogOverlay = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nDialogOverlay.displayName = DialogPrimitive.Overlay.displayName;\n\nconst DialogContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, ...props }, ref) => (\n \n \n \n {children}\n \n \n Close\n \n \n \n));\nDialogContent.displayName = DialogPrimitive.Content.displayName;\n\nfunction DialogHeader({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nDialogHeader.displayName = 'DialogHeader';\n\nfunction DialogFooter({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nDialogFooter.displayName = 'DialogFooter';\n\nconst DialogTitle = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nDialogTitle.displayName = DialogPrimitive.Title.displayName;\n\nconst DialogDescription = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nDialogDescription.displayName = DialogPrimitive.Description.displayName;\n\nexport {\n Dialog,\n DialogPortal,\n DialogOverlay,\n DialogClose,\n DialogTrigger,\n DialogContent,\n DialogHeader,\n DialogFooter,\n DialogTitle,\n DialogDescription,\n};\n","import React from 'react';\nimport { type DialogProps } from '@radix-ui/react-dialog';\nimport { Command as CommandPrimitive } from 'cmdk';\nimport { Search } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Dialog, DialogContent } from '@/components/shadcn-ui/dialog';\n\nconst Command = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nCommand.displayName = CommandPrimitive.displayName;\n\ninterface CommandDialogProps extends DialogProps {}\n\nfunction CommandDialog({ children, ...props }: CommandDialogProps) {\n return (\n \n \n \n {children}\n \n \n \n );\n}\n\nconst CommandInput = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n
    \n \n \n
    \n));\n\nCommandInput.displayName = CommandPrimitive.Input.displayName;\n\nconst CommandList = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\n\nCommandList.displayName = CommandPrimitive.List.displayName;\n\nconst CommandEmpty = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>((props, ref) => (\n \n));\n\nCommandEmpty.displayName = CommandPrimitive.Empty.displayName;\n\nconst CommandGroup = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\n\nCommandGroup.displayName = CommandPrimitive.Group.displayName;\n\nconst CommandSeparator = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nCommandSeparator.displayName = CommandPrimitive.Separator.displayName;\n\nconst CommandItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\n\nCommandItem.displayName = CommandPrimitive.Item.displayName;\n\nfunction CommandShortcut({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nCommandShortcut.displayName = 'CommandShortcut';\n\nexport {\n Command,\n CommandDialog,\n CommandInput,\n CommandList,\n CommandEmpty,\n CommandGroup,\n CommandItem,\n CommandShortcut,\n CommandSeparator,\n};\n","import { useState } from 'react';\nimport { Check, ChevronsUpDown } from 'lucide-react';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport { Popover, PopoverContent, PopoverTrigger } from '@/components/shadcn-ui/popover';\nimport {\n Command,\n CommandEmpty,\n CommandInput,\n CommandItem,\n CommandList,\n} from '@/components/shadcn-ui/command';\nimport { PopoverProps } from '@radix-ui/react-popover';\n\nexport type ComboBoxLabelOption = { label: string };\nexport type ComboBoxOption = string | number | ComboBoxLabelOption;\n\nexport type ComboBoxProps = {\n /** Optional unique identifier */\n id?: string;\n /** Text label title for combobox */\n /** List of available options for the dropdown menu */\n options?: readonly T[];\n /** Additional css classes to help with unique styling of the combo box button */\n buttonClassName?: string;\n /** Additional css classes to help with unique styling of the combo box popover */\n popoverContentClassName?: string;\n /**\n * The selected value that the combo box currently holds. Must be shallow equal to one of the\n * options entries.\n */\n value?: T;\n /** Triggers when content of textfield is changed */\n onChange?: (newValue: T) => void;\n /** Used to determine the string value for a given option. */\n getOptionLabel?: (option: ComboBoxOption) => string;\n /** Text displayed on button if `value` is undefined */\n buttonPlaceholder?: string;\n /** Placeholder text for text field */\n textPlaceholder?: string;\n /** Text to display when no options match input */\n commandEmptyMessage?: string;\n /** Variant of button */\n buttonVariant?: ButtonProps['variant'];\n /** Text direction ltr or rtl */\n dir?: Direction;\n /** Optional boolean to set if trigger should be disabled */\n isDisabled?: boolean;\n} & PopoverProps;\n\ntype Direction = 'ltr' | 'rtl';\n\nfunction getOptionLabelDefault(option: ComboBoxOption): string {\n if (typeof option === 'string') {\n return option;\n }\n if (typeof option === 'number') {\n return option.toString();\n }\n return option.label;\n}\n\n/**\n * Autocomplete input and command palette with a list of suggestions.\n *\n * Thanks to Shadcn for heavy inspiration and documentation\n * https://ui.shadcn.com/docs/components/combobox\n */\nfunction ComboBox({\n id,\n options = [],\n buttonClassName,\n popoverContentClassName,\n value,\n onChange = () => {},\n getOptionLabel = getOptionLabelDefault,\n buttonPlaceholder = '',\n textPlaceholder = '',\n commandEmptyMessage = 'No option found',\n buttonVariant = 'outline',\n dir = 'ltr',\n isDisabled = false,\n ...props\n}: ComboBoxProps) {\n const [open, setOpen] = useState(false);\n\n return (\n \n \n \n \n {value ? getOptionLabel(value) : buttonPlaceholder}\n \n \n \n \n \n \n \n {commandEmptyMessage}\n \n {options.map((option) => (\n {\n onChange(option);\n setOpen(false);\n }}\n >\n \n {getOptionLabel(option)}\n \n ))}\n \n \n \n \n );\n}\n\nexport default ComboBox;\n","import { useMemo } from 'react';\nimport ComboBox from '@/components/basics/combo-box.component';\nimport { Label } from '@/components/shadcn-ui/label';\n\nexport type ChapterRangeSelectorProps = {\n startChapter: number;\n endChapter: number;\n handleSelectStartChapter: (chapter: number) => void;\n handleSelectEndChapter: (chapter: number) => void;\n isDisabled?: boolean;\n chapterCount: number;\n};\n\nexport default function ChapterRangeSelector({\n startChapter,\n endChapter,\n handleSelectStartChapter,\n handleSelectEndChapter,\n isDisabled = false,\n chapterCount,\n}: ChapterRangeSelectorProps) {\n const chapterOptions = useMemo(\n () => Array.from({ length: chapterCount }, (_, index) => index + 1),\n [chapterCount],\n );\n\n const onChangeStartChapter = (value: number) => {\n handleSelectStartChapter(value);\n if (value > endChapter) {\n handleSelectEndChapter(value);\n }\n };\n\n const onChangeEndChapter = (value: number) => {\n handleSelectEndChapter(value);\n if (value < startChapter) {\n handleSelectStartChapter(value);\n }\n };\n\n return (\n <>\n \n option.toString()}\n value={startChapter}\n />\n\n \n option.toString()}\n value={endChapter}\n />\n \n );\n}\n","import { Button } from '@/components/shadcn-ui/button';\nimport { Label } from '@/components/shadcn-ui/label';\nimport { RadioGroup, RadioGroupItem } from '@/components/shadcn-ui/radio-group';\nimport { Canon } from '@sillsdev/scripture';\nimport { LocalizedStringValue } from 'platform-bible-utils';\nimport { useState } from 'react';\nimport ChapterRangeSelector, {\n ChapterRangeSelectorProps,\n} from '../basics/chapter-range-selector.component';\n\nexport enum BookSelectionMode {\n CURRENT_BOOK = 'current book',\n CHOOSE_BOOKS = 'choose books',\n}\n\n/**\n * Object containing all keys used for localization in this component. If you're using this\n * component in an extension, you can pass it into the useLocalizedStrings hook to easily obtain the\n * localized strings and pass them into the localizedStrings prop of this component\n */\nexport const BOOK_SELECTOR_STRING_KEYS = Object.freeze([\n '%webView_bookSelector_currentBook%',\n '%webView_bookSelector_choose%',\n '%webView_bookSelector_chooseBooks%',\n] as const);\n\nexport type BookSelectorLocalizedStrings = {\n [localizedInventoryKey in (typeof BOOK_SELECTOR_STRING_KEYS)[number]]?: LocalizedStringValue;\n};\n\n/**\n * Gets the localized value for the provided key\n *\n * @param strings Object containing localized string\n * @param key Key for a localized string\n * @returns The localized value for the provided key, if available. Returns the key if no localized\n * value is available\n */\nconst localizeString = (\n strings: BookSelectorLocalizedStrings,\n key: keyof BookSelectorLocalizedStrings,\n) => {\n return strings[key] ?? key;\n};\n\ntype BookSelectorProps = ChapterRangeSelectorProps & {\n handleBookSelectionModeChange: (newMode: BookSelectionMode) => void;\n currentBookName: string;\n onSelectBooks: () => void;\n selectedBookIds: string[];\n localizedStrings: BookSelectorLocalizedStrings;\n};\n\nexport default function BookSelector({\n handleBookSelectionModeChange,\n currentBookName,\n onSelectBooks,\n selectedBookIds,\n chapterCount,\n endChapter,\n handleSelectEndChapter,\n startChapter,\n handleSelectStartChapter,\n localizedStrings,\n}: BookSelectorProps) {\n const currentBookText = localizeString(localizedStrings, '%webView_bookSelector_currentBook%');\n const chooseText = localizeString(localizedStrings, '%webView_bookSelector_choose%');\n const chooseBooksText = localizeString(localizedStrings, '%webView_bookSelector_chooseBooks%');\n\n const [bookSelectionMode, setBookSelectionMode] = useState(\n BookSelectionMode.CURRENT_BOOK,\n );\n\n const onSelectionModeChange = (newMode: BookSelectionMode) => {\n setBookSelectionMode(newMode);\n handleBookSelectionModeChange(newMode);\n };\n\n return (\n onSelectionModeChange(value as BookSelectionMode)}\n >\n
    \n
    \n
    \n \n \n
    \n \n
    \n \n
    \n
    \n
    \n
    \n \n \n
    \n \n onSelectBooks()}\n >\n {chooseText}\n \n
    \n
    \n \n );\n}\n","import { DropdownMenuTrigger } from '@radix-ui/react-dropdown-menu';\nimport { FilterIcon } from 'lucide-react';\nimport { Table } from '@tanstack/react-table';\n\nimport { Button } from '@/components/shadcn-ui/button';\nimport {\n DropdownMenu,\n DropdownMenuCheckboxItem,\n DropdownMenuContent,\n DropdownMenuLabel,\n DropdownMenuSeparator,\n} from '@/components/shadcn-ui/dropdown-menu';\n\ninterface DataTableViewOptionsProps {\n table: Table;\n}\n\nfunction DataTableViewOptions({ table }: DataTableViewOptionsProps) {\n return (\n \n \n \n \n \n Toggle columns\n \n {table\n .getAllColumns()\n .filter((column) => column.getCanHide())\n .map((column) => {\n return (\n column.toggleVisibility(!!value)}\n >\n {column.id}\n \n );\n })}\n \n \n );\n}\n\nexport default DataTableViewOptions;\n","import React from 'react';\nimport * as SelectPrimitive from '@radix-ui/react-select';\nimport { Check, ChevronDown, ChevronUp } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Select = SelectPrimitive.Root;\n\nconst SelectGroup = SelectPrimitive.Group;\n\nconst SelectValue = SelectPrimitive.Value;\n\nconst SelectTrigger = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, ...props }, ref) => (\n span]:tw-line-clamp-1',\n className,\n )}\n {...props}\n >\n {children}\n \n \n \n \n));\nSelectTrigger.displayName = SelectPrimitive.Trigger.displayName;\n\nconst SelectScrollUpButton = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n));\nSelectScrollUpButton.displayName = SelectPrimitive.ScrollUpButton.displayName;\n\nconst SelectScrollDownButton = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n));\nSelectScrollDownButton.displayName = SelectPrimitive.ScrollDownButton.displayName;\n\nconst SelectContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, position = 'popper', ...props }, ref) => (\n \n \n \n \n {children}\n \n \n \n \n));\nSelectContent.displayName = SelectPrimitive.Content.displayName;\n\nconst SelectLabel = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSelectLabel.displayName = SelectPrimitive.Label.displayName;\n\nconst SelectItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, ...props }, ref) => (\n \n \n \n \n \n \n\n {children}\n \n));\nSelectItem.displayName = SelectPrimitive.Item.displayName;\n\nconst SelectSeparator = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSelectSeparator.displayName = SelectPrimitive.Separator.displayName;\n\nexport {\n Select,\n SelectGroup,\n SelectValue,\n SelectTrigger,\n SelectContent,\n SelectLabel,\n SelectItem,\n SelectSeparator,\n SelectScrollUpButton,\n SelectScrollDownButton,\n};\n","import { ChevronLeftIcon, ChevronRightIcon, ArrowLeftIcon, ArrowRightIcon } from 'lucide-react';\nimport { Table } from '@tanstack/react-table';\n\nimport { Button } from '@/components/shadcn-ui/button';\nimport {\n Select,\n SelectContent,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\n\ninterface DataTablePaginationProps {\n table: Table;\n}\n\nfunction DataTablePagination({ table }: DataTablePaginationProps) {\n return (\n
    \n
    \n
    \n {table.getFilteredSelectedRowModel().rows.length} of{' '}\n {table.getFilteredRowModel().rows.length} row(s) selected\n
    \n
    \n

    Rows per page

    \n {\n table.setPageSize(Number(value));\n }}\n >\n \n \n \n \n {[10, 20, 30, 40, 50].map((pageSize) => (\n \n {pageSize}\n \n ))}\n \n \n
    \n
    \n Page {table.getState().pagination.pageIndex + 1} of {table.getPageCount()}\n
    \n
    \n table.setPageIndex(0)}\n disabled={!table.getCanPreviousPage()}\n >\n Go to first page\n \n \n table.previousPage()}\n disabled={!table.getCanPreviousPage()}\n >\n Go to previous page\n \n \n table.nextPage()}\n disabled={!table.getCanNextPage()}\n >\n Go to next page\n \n \n table.setPageIndex(table.getPageCount() - 1)}\n disabled={!table.getCanNextPage()}\n >\n Go to last page\n \n \n
    \n
    \n
    \n );\n}\n\nexport default DataTablePagination;\n","import React from 'react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Table = React.forwardRef<\n HTMLTableElement,\n React.HTMLAttributes & { stickyHeader?: boolean }\n>(({ className, stickyHeader, ...props }, ref) => (\n
    \n \n
    \n));\nTable.displayName = 'Table';\n\nconst TableHeader = React.forwardRef<\n HTMLTableSectionElement,\n React.HTMLAttributes & { stickyHeader?: boolean }\n>(({ className, stickyHeader, ...props }, ref) => (\n \n));\nTableHeader.displayName = 'TableHeader';\n\nconst TableBody = React.forwardRef<\n HTMLTableSectionElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableBody.displayName = 'TableBody';\n\nconst TableFooter = React.forwardRef<\n HTMLTableSectionElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n tr]:last:tw-border-b-0', className)}\n {...props}\n />\n));\nTableFooter.displayName = 'TableFooter';\n\nconst TableRow = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nTableRow.displayName = 'TableRow';\n\nconst TableHead = React.forwardRef<\n HTMLTableCellElement,\n React.ThHTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableHead.displayName = 'TableHead';\n\nconst TableCell = React.forwardRef<\n HTMLTableCellElement,\n React.TdHTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableCell.displayName = 'TableCell';\n\nconst TableCaption = React.forwardRef<\n HTMLTableCaptionElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableCaption.displayName = 'TableCaption';\n\nexport { Table, TableHeader, TableBody, TableFooter, TableHead, TableRow, TableCell, TableCaption };\n","import { useState } from 'react';\n\nimport {\n ColumnFiltersState,\n flexRender,\n getCoreRowModel,\n getFilteredRowModel,\n getPaginationRowModel,\n getSortedRowModel,\n SortingState,\n ColumnDef as TSColumnDef,\n Row as TSRow,\n RowSelectionState as TSRowSelectionState,\n SortDirection as TSSortDirection,\n Table as TSTable,\n useReactTable,\n VisibilityState,\n} from '@tanstack/react-table';\n\nimport DataTableViewOptions from '@/components/advanced/data-table/data-table-column-toggle.component';\nimport DataTablePagination from '@/components/advanced/data-table/data-table-pagination.component';\nimport { Button } from '@/components/shadcn-ui/button';\nimport {\n Table,\n TableBody,\n TableCell,\n TableHead,\n TableHeader,\n TableRow,\n} from '@/components/shadcn-ui/table';\n\nexport type ColumnDef = TSColumnDef;\nexport type RowContents = TSRow;\nexport type TableContents = TSTable;\nexport type SortDirection = TSSortDirection;\nexport type RowSelectionState = TSRowSelectionState;\n\ninterface DataTableProps {\n columns: ColumnDef[];\n data: TData[];\n enablePagination?: boolean;\n showPaginationControls?: boolean;\n showColumnVisibilityControls?: boolean;\n stickyHeader?: boolean;\n onRowClickHandler?: (row: RowContents, table: TableContents) => void;\n}\n\n/**\n * Feature-rich table component that infuses our basic shadcn-based Table component with features\n * from TanStack's React Table library\n */\nfunction DataTable({\n columns,\n data,\n enablePagination = false,\n showPaginationControls = false,\n showColumnVisibilityControls = false,\n stickyHeader = false,\n onRowClickHandler = () => {},\n}: DataTableProps) {\n const [sorting, setSorting] = useState([]);\n const [columnFilters, setColumnFilters] = useState([]);\n const [columnVisibility, setColumnVisibility] = useState({});\n const [rowSelection, setRowSelection] = useState({});\n\n const table = useReactTable({\n data,\n columns,\n getCoreRowModel: getCoreRowModel(),\n ...(enablePagination && { getPaginationRowModel: getPaginationRowModel() }),\n onSortingChange: setSorting,\n getSortedRowModel: getSortedRowModel(),\n onColumnFiltersChange: setColumnFilters,\n getFilteredRowModel: getFilteredRowModel(),\n onColumnVisibilityChange: setColumnVisibility,\n onRowSelectionChange: setRowSelection,\n state: {\n sorting,\n columnFilters,\n columnVisibility,\n rowSelection,\n },\n });\n\n return (\n
    \n {showColumnVisibilityControls && }\n \n \n {table.getHeaderGroups().map((headerGroup) => (\n \n {headerGroup.headers.map((header) => {\n return (\n \n {header.isPlaceholder\n ? undefined\n : flexRender(header.column.columnDef.header, header.getContext())}\n \n );\n })}\n \n ))}\n \n \n {table.getRowModel().rows?.length ? (\n table.getRowModel().rows.map((row) => (\n onRowClickHandler(row, table)}\n key={row.id}\n data-state={row.getIsSelected() && 'selected'}\n >\n {row.getVisibleCells().map((cell) => (\n \n {flexRender(cell.column.columnDef.cell, cell.getContext())}\n \n ))}\n \n ))\n ) : (\n \n \n No results.\n \n \n )}\n \n
    \n {enablePagination && (\n
    \n table.previousPage()}\n disabled={!table.getCanPreviousPage()}\n >\n Previous\n \n table.nextPage()}\n disabled={!table.getCanNextPage()}\n >\n Next\n \n
    \n )}\n {enablePagination && showPaginationControls && }\n
    \n );\n}\n\nexport default DataTable;\n","import {\n Table,\n TableBody,\n TableCell,\n TableHead,\n TableHeader,\n TableRow,\n} from '@/components/shadcn-ui/table';\nimport { Canon } from '@sillsdev/scripture';\nimport { deepEqual, LanguageStrings, ScriptureReference } from 'platform-bible-utils';\nimport { useMemo } from 'react';\nimport { InventoryItemOccurrence } from './inventory-utils';\n\n/** Props for the OccurrencesTable component */\ntype OccurrencesTableProps = {\n /** Data that contains scriptures references and snippets of scripture */\n occurrenceData: InventoryItemOccurrence[];\n /** Callback function that is executed when the scripture reference is changed */\n setScriptureReference: (scriptureReference: ScriptureReference) => void;\n /**\n * Object with all localized strings that the OccurrencesTable needs to work well across multiple\n * languages\n */\n localizedStrings: LanguageStrings;\n};\n\n/**\n * Table that shows occurrences of specified inventory item(s). The first column shows the related\n * scripture reference. The second column shows the snippet of scripture that contains the specified\n * inventory item\n */\nfunction OccurrencesTable({\n occurrenceData,\n setScriptureReference,\n localizedStrings,\n}: OccurrencesTableProps) {\n const referenceHeaderText =\n localizedStrings['%webView_inventory_occurrences_table_header_reference%'];\n const occurrenceHeaderText =\n localizedStrings['%webView_inventory_occurrences_table_header_occurrence%'];\n\n const occurrences: InventoryItemOccurrence[] = useMemo(() => {\n const uniqueOccurrences: InventoryItemOccurrence[] = [];\n\n occurrenceData.forEach((occurrence) => {\n if (!uniqueOccurrences.some((uniqueOccurrence) => deepEqual(uniqueOccurrence, occurrence))) {\n uniqueOccurrences.push(occurrence);\n }\n });\n\n return uniqueOccurrences;\n }, [occurrenceData]);\n\n return (\n \n \n \n {referenceHeaderText}\n {occurrenceHeaderText}\n \n \n \n {occurrences.length > 0 &&\n occurrences.map((occurrence) => (\n {\n setScriptureReference(occurrence.reference);\n }}\n >\n {`${Canon.bookNumberToEnglishName(occurrence.reference.bookNum)} ${occurrence.reference.chapterNum}:${occurrence.reference.verseNum}`}\n {occurrence.text}\n \n ))}\n \n
    \n );\n}\n\nexport default OccurrencesTable;\n","import React from 'react';\nimport * as CheckboxPrimitive from '@radix-ui/react-checkbox';\nimport { Check } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Checkbox = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n \n \n));\nCheckbox.displayName = CheckboxPrimitive.Root.displayName;\n\nexport default Checkbox;\n","import { Canon } from '@sillsdev/scripture';\nimport { ScriptureReference } from 'platform-bible-utils';\n\n/* #region Types */\n\n/**\n * Status of items that appear in inventories. 'approved' and 'unapproved' items are defined in the\n * project's `Settings.xml`. All other items are defined as 'unknown'\n */\nexport type Status = 'approved' | 'unapproved' | 'unknown';\n\n/** Occurrence of item in inventory. Primarily used by table that shows occurrences */\nexport type InventoryItemOccurrence = {\n /** Reference to scripture where the item appears */\n reference: ScriptureReference;\n /** Snippet of scripture that contains the occurrence */\n text: string;\n};\n\n/** Data structure that contains all information on an item that is shown in an inventory */\nexport type InventoryTableData = {\n /**\n * The item (e.g. a character in the characters inventory, a marker in the marker inventory) In\n * most cases the array will only have one element. In case of additional items (e.g. the\n * preceding marker in the markers check), the primary item should be stored in the first index.\n * To show additional items in the inventory, make sure to configure the `additionalItemsLabels`\n * prop for the Inventory component\n */\n items: string[];\n /** The number of times this item occurs in the selected scope */\n count: number;\n /** The status of this item (see documentation for `Status` type for more information) */\n status: Status;\n /** Occurrences of this item in the scripture text for the selected scope */\n occurrences: InventoryItemOccurrence[];\n};\n\n/* #endregion */\n\n/* #region Functions */\n\n/**\n * Splits USFM string into shorter line-like segments\n *\n * @param text A single (likely very large) USFM string\n * @returns An array containing the input text, split into shorter segments\n */\nexport const getLinesFromUSFM = (text: string) => {\n // Splits on (CR)LF, CR, \\v, \\c and \\id\n return text.split(/(?:\\r?\\n|\\r)|(?=(?:\\\\(?:v|c|id)))/g);\n};\n\n/**\n * Extracts chapter or verse number from USFM strings that start with a \\c or \\v marker\n *\n * @param text USFM string that is expected to start with \\c or \\v marker\n * @returns Chapter or verse number if one is found. Else returns 0.\n */\nexport const getNumberFromUSFM = (text: string): number | undefined => {\n // Captures all digits that follow \\v or \\c markers followed by whitespace located at the start of a string\n const regex = /^\\\\[vc]\\s+(\\d+)/;\n const match = text.match(regex);\n\n if (match) {\n return +match[1];\n }\n return undefined;\n};\n\n/**\n * Gets book ID from USFM string that starts with the \\id marker, and returns book number for it\n *\n * @param text USFM string that is expected to start with \\id marker\n * @returns Book number corresponding to the \\id marker in the input text. Returns 0 if no marker is\n * found or the marker is not valid\n */\nexport const getBookNumFromId = (text: string): number => {\n // Captures all digits that follow an \\id marker followed by whitespace located at the start of a string\n const match = text.match(/^\\\\id\\s+([A-Za-z]+)/);\n if (match) {\n return Canon.bookIdToNumber(match[1]);\n }\n return 0;\n};\n\n/**\n * Gets the status for an item, typically used in the Inventory component\n *\n * @param item The item for which the status is being requested\n * @param approvedItems Array of approved items, typically as defined in `Settings.xml`\n * @param unapprovedItems Array of unapproved items, typically as defined in `Settings.xml`\n * @returns The status for the specified item\n */\nexport const getStatusForItem = (\n item: string,\n approvedItems: string[],\n unapprovedItems: string[],\n): Status => {\n if (unapprovedItems.includes(item)) return 'unapproved';\n if (approvedItems.includes(item)) return 'approved';\n return 'unknown';\n};\n\n/* #endregion */\n","import React from 'react';\nimport * as TogglePrimitive from '@radix-ui/react-toggle';\nimport { cva, type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst toggleVariants = cva(\n 'pr-twp tw-inline-flex tw-items-center tw-justify-center tw-rounded-md tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-colors hover:tw-bg-muted hover:tw-text-muted-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50 data-[state=on]:tw-bg-accent data-[state=on]:tw-text-accent-foreground',\n {\n variants: {\n variant: {\n default: 'tw-bg-transparent',\n outline:\n 'tw-border tw-border-input tw-bg-transparent hover:tw-bg-accent hover:tw-text-accent-foreground',\n },\n size: {\n default: 'tw-h-10 tw-px-3',\n sm: 'tw-h-9 tw-px-2.5',\n lg: 'tw-h-11 tw-px-5',\n },\n },\n defaultVariants: {\n variant: 'default',\n size: 'default',\n },\n },\n);\n\nconst Toggle = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef & VariantProps\n>(({ className, variant, size, ...props }, ref) => (\n \n));\n\nToggle.displayName = TogglePrimitive.Root.displayName;\n\nexport { Toggle, toggleVariants };\n","import React from 'react';\nimport * as ToggleGroupPrimitive from '@radix-ui/react-toggle-group';\nimport { type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { toggleVariants } from '@/components/shadcn-ui/toggle';\n\nconst ToggleGroupContext = React.createContext>({\n size: 'default',\n variant: 'default',\n});\n\nconst ToggleGroup = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef &\n VariantProps\n>(({ className, variant, size, children, ...props }, ref) => (\n \n \n {children}\n \n \n));\n\nToggleGroup.displayName = ToggleGroupPrimitive.Root.displayName;\n\nconst ToggleGroupItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef &\n VariantProps\n>(({ className, children, variant, size, ...props }, ref) => {\n const context = React.useContext(ToggleGroupContext);\n\n return (\n \n {children}\n \n );\n});\n\nToggleGroupItem.displayName = ToggleGroupPrimitive.Item.displayName;\n\nexport { ToggleGroup, ToggleGroupItem };\n","import { ColumnDef, SortDirection } from '@/components/advanced/data-table/data-table.component';\nimport { Button } from '@/components/shadcn-ui/button';\nimport { ToggleGroup, ToggleGroupItem } from '@/components/shadcn-ui/toggle-group';\nimport {\n ArrowDownIcon,\n ArrowUpDownIcon,\n ArrowUpIcon,\n CircleCheckIcon,\n CircleHelpIcon,\n CircleXIcon,\n} from 'lucide-react';\nimport { ReactNode } from 'react';\nimport { InventoryTableData, Status } from './inventory-utils';\n\n/**\n * Gets an icon that indicates the current sorting direction based on the provided input\n *\n * @param sortDirection Sorting direction. Can be ascending ('asc'), descending ('desc') or false (\n * i.e. not sorted)\n * @returns The appropriate sorting icon for the provided sorting direction\n */\nconst getSortingIcon = (sortDirection: false | SortDirection): ReactNode => {\n if (sortDirection === 'asc') {\n return ;\n }\n if (sortDirection === 'desc') {\n return ;\n }\n return ;\n};\n\n/**\n * Function that creates the item column for inventories\n *\n * @param itemLabel Localized label for the item column (e.g. 'Character', 'Repeated Word', etc.)\n * @returns Column that shows the inventory items. Should be used with the DataTable component\n */\nexport const inventoryItemColumn = (itemLabel: string): ColumnDef => {\n return {\n accessorKey: 'item',\n accessorFn: (row: InventoryTableData) => row.items[0],\n header: ({ column }) => (\n \n ),\n };\n};\n\n/**\n * Function that creates the additional item columns for inventories\n *\n * @param additionalItemLabel Localized label for the additional item column (e.g. 'Preceding\n * Marker')\n * @param additionalItemIndex Index that locates the desired item in the items array of the\n * inventory\n * @returns Column that shows additional inventory items. Should be used with the DataTable\n * component\n */\nexport const inventoryAdditionalItemColumn = (\n additionalItemLabel: string,\n additionalItemIndex: number,\n): ColumnDef => {\n return {\n accessorKey: `item${additionalItemIndex}`,\n accessorFn: (row: InventoryTableData) => row.items[additionalItemIndex],\n header: ({ column }) => (\n \n ),\n };\n};\n\n/**\n * Function that creates the count column for inventories. Should be used with the DataTable\n * component.\n *\n * @param itemLabel Localized label for the count column\n * @returns Column that shows the number of occurrences of the related inventory items\n */\nexport const inventoryCountColumn = (countLabel: string): ColumnDef => {\n return {\n accessorKey: 'count',\n header: ({ column }) => (\n
    \n \n
    \n ),\n cell: ({ row }) =>
    {row.getValue('count')}
    ,\n };\n};\n\n/**\n * Function that updates project settings when status for item(s) changes\n *\n * @param changedItems Array of items for which the status is being updated\n * @param newStatus The status that the items are being given\n * @param approvedItems Array of currently approved items\n * @param onApprovedItemsChange Callback function that stores the updated list of approved items\n * @param unapprovedItems Array of currently unapproved items\n * @param onUnapprovedItemsChange Callback function that stores the updated list of unapproved items\n */\nconst statusChangeHandler = (\n changedItems: string[],\n newStatus: Status,\n approvedItems: string[],\n onApprovedItemsChange: (items: string[]) => void,\n unapprovedItems: string[],\n onUnapprovedItemsChange: (items: string[]) => void,\n) => {\n let newApprovedItems: string[] = [...approvedItems];\n changedItems.forEach((item) => {\n if (newStatus === 'approved') {\n if (!newApprovedItems.includes(item)) {\n newApprovedItems.push(item);\n }\n } else {\n newApprovedItems = newApprovedItems.filter((validItem) => validItem !== item);\n }\n });\n onApprovedItemsChange(newApprovedItems);\n\n let newUnapprovedItems: string[] = [...unapprovedItems];\n changedItems.forEach((item) => {\n if (newStatus === 'unapproved') {\n if (!newUnapprovedItems.includes(item)) {\n newUnapprovedItems.push(item);\n }\n } else {\n newUnapprovedItems = newUnapprovedItems.filter((unapprovedItem) => unapprovedItem !== item);\n }\n });\n onUnapprovedItemsChange(newUnapprovedItems);\n};\n\n/**\n * Function that creates the status column for inventories. Should be used with the DataTable\n * component.\n *\n * @param statusLabel Localized label for the status column\n * @param approvedItems Array of approved items, typically as defined in `Settings.xml`\n * @param onApprovedItemsChange Callback function that stores the updated list of approved items\n * @param unapprovedItems Array of unapproved items, typically as defined in `Settings.xml`\n * @param onUnapprovedItemsChange Callback function that stores the updated list of unapproved items\n * @returns Column that shows the status buttons for the related inventory item. The button for the\n * current status of the item is selected\n */\nexport const inventoryStatusColumn = (\n statusLabel: string,\n approvedItems: string[],\n onApprovedItemsChange: (items: string[]) => void,\n unapprovedItems: string[],\n onUnapprovedItemsChange: (items: string[]) => void,\n): ColumnDef => {\n return {\n accessorKey: 'status',\n header: ({ column }) => {\n return (\n
    \n \n
    \n );\n },\n cell: ({ row }) => {\n const status: Status = row.getValue('status');\n const item: string = row.getValue('item');\n return (\n \n \n statusChangeHandler(\n [item],\n 'approved',\n approvedItems,\n onApprovedItemsChange,\n unapprovedItems,\n onUnapprovedItemsChange,\n )\n }\n value=\"approved\"\n >\n \n \n \n statusChangeHandler(\n [item],\n 'unapproved',\n approvedItems,\n onApprovedItemsChange,\n unapprovedItems,\n onUnapprovedItemsChange,\n )\n }\n value=\"unapproved\"\n >\n \n \n \n statusChangeHandler(\n [item],\n 'unknown',\n approvedItems,\n onApprovedItemsChange,\n unapprovedItems,\n onUnapprovedItemsChange,\n )\n }\n value=\"unknown\"\n >\n \n \n \n );\n },\n };\n};\n","import DataTable, {\n ColumnDef,\n RowContents,\n RowSelectionState,\n TableContents,\n} from '@/components/advanced/data-table/data-table.component';\nimport OccurrencesTable from '@/components/advanced/inventory/occurrences-table.component';\nimport Checkbox from '@/components/shadcn-ui/checkbox';\nimport { Input } from '@/components/shadcn-ui/input';\nimport { Label } from '@/components/shadcn-ui/label';\nimport {\n Select,\n SelectContent,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\nimport {\n deepEqual,\n LocalizedStringValue,\n ScriptureReference,\n substring,\n} from 'platform-bible-utils';\nimport { useEffect, useMemo, useState } from 'react';\nimport {\n getBookNumFromId,\n getLinesFromUSFM,\n getNumberFromUSFM,\n getStatusForItem,\n InventoryItemOccurrence,\n InventoryTableData,\n Status,\n} from './inventory-utils';\nimport { inventoryAdditionalItemColumn } from './inventory-columns';\n\n/**\n * Object containing all keys used for localization in this component. If you're using this\n * component in an extension, you can pass it into the useLocalizedStrings hook to easily obtain the\n * localized strings and pass them into the localizedStrings prop of this component\n */\nexport const INVENTORY_STRING_KEYS = Object.freeze([\n '%webView_inventory_all%',\n '%webView_inventory_approved%',\n '%webView_inventory_unapproved%',\n '%webView_inventory_unknown%',\n '%webView_inventory_scope_currentBook%',\n '%webView_inventory_scope_chapter%',\n '%webView_inventory_scope_verse%',\n '%webView_inventory_filter_text%',\n '%webView_inventory_show_additional_items%',\n '%webView_inventory_occurrences_table_header_reference%',\n '%webView_inventory_occurrences_table_header_occurrence%',\n] as const);\n\nexport type InventoryLocalizedStrings = {\n [localizedInventoryKey in (typeof INVENTORY_STRING_KEYS)[number]]?: LocalizedStringValue;\n};\n\n/** Scope of scripture that the inventory can operate on */\nexport type Scope = 'book' | 'chapter' | 'verse';\n\n/** Status values that the status filter can select from */\ntype StatusFilter = Status | 'all';\n\n/** Text labels for the inventory columns and the control components of additional inventory items */\ntype AdditionalItemsLabels = {\n checkboxText?: string;\n tableHeaders?: string[];\n};\n\n/**\n * Filters data that is shown in the DataTable section of the Inventory\n *\n * @param itemData All inventory items and their related information\n * @param statusFilter Allows filtering by status (i.e. show all items, or only items that are\n * 'approved', 'unapproved' or 'unknown')\n * @param textFilter Allows filtering by text. All items that include the filter text will be\n * selected.\n * @returns Array of items and their related information that are matched by the specified filters\n */\nconst filterItemData = (\n itemData: InventoryTableData[],\n statusFilter: StatusFilter,\n textFilter: string,\n): InventoryTableData[] => {\n let filteredItemData: InventoryTableData[] = itemData;\n\n if (statusFilter !== 'all') {\n filteredItemData = filteredItemData.filter(\n (item) =>\n (statusFilter === 'approved' && item.status === 'approved') ||\n (statusFilter === 'unapproved' && item.status === 'unapproved') ||\n (statusFilter === 'unknown' && item.status === 'unknown'),\n );\n }\n\n if (textFilter !== '')\n filteredItemData = filteredItemData.filter((item) => item.items[0].includes(textFilter));\n\n return filteredItemData;\n};\n\n/**\n * Turns array of strings into array of inventory items, along with their count and status\n *\n * @param text The source scripture text that is searched for inventory items\n * @param scriptureRef The scripture reference that the application is currently set to\n * @param approvedItems Array of approved items, typically as defined in `Settings.xml`\n * @param unapprovedItems Array of unapproved items, typically as defined in `Settings.xml`\n * @param itemRegex Regular expression that describes what items this Inventory should extract from\n * the provided scripture text\n * @returns Array of inventory items, along with their count and status\n */\nconst createTableData = (\n text: string | undefined,\n scriptureRef: ScriptureReference,\n approvedItems: string[],\n unapprovedItems: string[],\n itemRegex: RegExp,\n): InventoryTableData[] => {\n if (!text) return [];\n\n const tableData: InventoryTableData[] = [];\n\n let currentBook: number | undefined = scriptureRef.bookNum;\n let currentChapter: number | undefined = scriptureRef.chapterNum;\n let currentVerse: number | undefined = scriptureRef.verseNum;\n\n const lines = getLinesFromUSFM(text);\n\n lines.forEach((line: string) => {\n if (line.startsWith('\\\\id')) {\n currentBook = getBookNumFromId(line);\n currentChapter = 0;\n currentVerse = 0;\n }\n if (line.startsWith('\\\\c')) {\n currentChapter = getNumberFromUSFM(line);\n currentVerse = 0;\n }\n if (line.startsWith('\\\\v')) {\n currentVerse = getNumberFromUSFM(line);\n if (currentChapter === 0) {\n currentChapter = scriptureRef.chapterNum;\n }\n }\n\n let match: RegExpExecArray | undefined = itemRegex.exec(line) ?? undefined;\n while (match) {\n const items: string[] = [];\n match.forEach((item) => items.push(item));\n const itemIndex = match.index;\n const existingItem = tableData.find((tableEntry) => deepEqual(tableEntry.items, items));\n const newReference: InventoryItemOccurrence = {\n reference: {\n bookNum: currentBook !== undefined ? currentBook : -1,\n chapterNum: currentChapter !== undefined ? currentChapter : -1,\n verseNum: currentVerse !== undefined ? currentVerse : -1,\n },\n text: substring(line, Math.max(0, itemIndex - 25), Math.min(itemIndex + 25, line.length)),\n };\n if (existingItem) {\n existingItem.count += 1;\n existingItem.occurrences.push(newReference);\n } else {\n const newItem: InventoryTableData = {\n items,\n count: 1,\n status: getStatusForItem(items[0], approvedItems, unapprovedItems),\n occurrences: [newReference],\n };\n tableData.push(newItem);\n }\n\n match = itemRegex.exec(line) ?? undefined;\n }\n });\n\n return tableData;\n};\n\n/**\n * Gets the localized value for the provided key\n *\n * @param strings Object containing localized string\n * @param key Key for a localized string\n * @returns The localized value for the provided key, if available. Returns the key if no localized\n * value is available\n */\nconst localizeString = (\n strings: InventoryLocalizedStrings,\n key: keyof InventoryLocalizedStrings,\n) => {\n return strings[key] ?? key;\n};\n\n/** Props for the Inventory component */\ntype InventoryProps = {\n /** The scripture reference that the application is currently set to */\n scriptureReference: ScriptureReference;\n /** Callback function that is executed when the scripture reference is changed */\n setScriptureReference: (scriptureReference: ScriptureReference) => void;\n /**\n * Object with all localized strings that the Inventory needs to work well across multiple\n * languages. When using this component with Platform.Bible, you can import\n * `INVENTORY_STRING_KEYS` from this library, pass it in to the Platform's localization hook, and\n * pass the localized keys that are returned by the hook into this prop.\n */\n localizedStrings: InventoryLocalizedStrings;\n /**\n * The logic that finds the desired items in the source text. This can either be a Regular\n * expression that captures one or multiple items (preferred), or a custom function that builds\n * and return an InventoryDataTable[] manually. Note: In case the logic captures more than one\n * item (i.e. InventoryTableData.items has a length greater than 1), you must provide text labels\n * for the related columns and control elements to show by setting the `additionalItemsLabels`\n * prop\n */\n extractItems:\n | RegExp\n | ((\n text: string | undefined,\n scriptureRef: ScriptureReference,\n approvedItems: string[],\n unapprovedItems: string[],\n ) => InventoryTableData[]);\n /**\n * Text labels for control elements and additional column headers in case your Inventory has more\n * than one item to show (e.g. The 'Preceding Marker' in the Markers Inventory)\n */\n additionalItemsLabels?: AdditionalItemsLabels;\n /** Array of approved items, typically as defined in `Settings.xml` */\n approvedItems: string[];\n /** Array of unapproved items, typically as defined in `Settings.xml` */\n unapprovedItems: string[];\n /** The source scripture text that is searched for in inventory items */\n text: string | undefined;\n /** Scope of scripture that the inventory will operate on */\n scope: Scope;\n /** Callback function that is executed when the scope is changed from the Inventory */\n onScopeChange: (scope: Scope) => void;\n /**\n * Column definitions for the Inventory data table. The most commonly used column definitions are\n * pre-configured for your convenience and can be imported (e.g. inventoryItemColumn,\n * inventoryAdditionalItemColumn inventoryCountColumn, and inventoryStatusColumn). If you need any\n * other columns you can add these yourself\n */\n columns: ColumnDef[];\n};\n\n/** Inventory component that is used to view and control the status of provided project settings */\nexport default function Inventory({\n scriptureReference,\n setScriptureReference,\n localizedStrings,\n extractItems,\n additionalItemsLabels,\n approvedItems,\n unapprovedItems,\n text,\n scope,\n onScopeChange,\n columns,\n}: InventoryProps) {\n const allItemsText = localizeString(localizedStrings, '%webView_inventory_all%');\n const approvedItemsText = localizeString(localizedStrings, '%webView_inventory_approved%');\n const unapprovedItemsText = localizeString(localizedStrings, '%webView_inventory_unapproved%');\n const unknownItemsText = localizeString(localizedStrings, '%webView_inventory_unknown%');\n const scopeBookText = localizeString(localizedStrings, '%webView_inventory_scope_currentBook%');\n const scopeChapterText = localizeString(localizedStrings, '%webView_inventory_scope_chapter%');\n const scopeVerseText = localizeString(localizedStrings, '%webView_inventory_scope_verse%');\n const filterText = localizeString(localizedStrings, '%webView_inventory_filter_text%');\n const showAdditionalItemsText = localizeString(\n localizedStrings,\n '%webView_inventory_show_additional_items%',\n );\n\n const [showAdditionalItems, setShowAdditionalItems] = useState(false);\n const [statusFilter, setStatusFilter] = useState('all');\n const [textFilter, setTextFilter] = useState('');\n const [selectedItem, setSelectedItem] = useState([]);\n\n const tableData: InventoryTableData[] = useMemo(() => {\n if (!text) return [];\n if (extractItems instanceof RegExp)\n return createTableData(\n text,\n scriptureReference,\n approvedItems,\n unapprovedItems,\n extractItems,\n );\n return extractItems(text, scriptureReference, approvedItems, unapprovedItems);\n }, [text, extractItems, scriptureReference, approvedItems, unapprovedItems]);\n\n const reducedTableData: InventoryTableData[] = useMemo(() => {\n if (showAdditionalItems) return tableData;\n\n const newTableData: InventoryTableData[] = [];\n\n tableData.forEach((tableEntry) => {\n const firstItem = tableEntry.items[0];\n\n const existingEntry = newTableData.find(\n (newTableEntry) => newTableEntry.items[0] === firstItem,\n );\n\n if (existingEntry) {\n existingEntry.count += tableEntry.count;\n existingEntry.occurrences = existingEntry.occurrences.concat(tableEntry.occurrences);\n } else {\n newTableData.push({\n items: [firstItem],\n count: tableEntry.count,\n occurrences: tableEntry.occurrences,\n status: tableEntry.status,\n });\n }\n });\n\n return newTableData;\n }, [showAdditionalItems, tableData]);\n\n const filteredTableData: InventoryTableData[] = useMemo(() => {\n return filterItemData(reducedTableData, statusFilter, textFilter);\n }, [reducedTableData, statusFilter, textFilter]);\n\n const allColumns: ColumnDef[] = useMemo(() => {\n if (!showAdditionalItems) return columns;\n\n const numberOfAdditionalItems = additionalItemsLabels?.tableHeaders?.length;\n if (!numberOfAdditionalItems) return columns;\n\n const additionalColumns: ColumnDef[] = [];\n\n for (let index = 0; index < numberOfAdditionalItems; index++) {\n additionalColumns.push(\n inventoryAdditionalItemColumn(\n additionalItemsLabels?.tableHeaders?.[index] || 'Additional Item',\n index + 1,\n ),\n );\n }\n\n return [...additionalColumns, ...columns];\n }, [additionalItemsLabels?.tableHeaders, columns, showAdditionalItems]);\n\n useEffect(() => {\n setSelectedItem([]);\n }, [filteredTableData]);\n\n const rowClickHandler = (\n row: RowContents,\n table: TableContents,\n ) => {\n table.setRowSelection(() => {\n const newSelection: RowSelectionState = {};\n newSelection[row.index] = true;\n return newSelection;\n });\n\n setSelectedItem(row.original.items);\n };\n\n const handleScopeChange = (value: string) => {\n if (value === 'book' || value === 'chapter' || value === 'verse') {\n onScopeChange(value);\n } else {\n throw new Error(`Invalid scope value: ${value}`);\n }\n };\n\n const handleStatusFilterChange = (value: string) => {\n if (value === 'all' || value === 'approved' || value === 'unapproved' || value === 'unknown') {\n setStatusFilter(value);\n } else {\n throw new Error(`Invalid status filter value: ${value}`);\n }\n };\n\n const occurrenceData: InventoryItemOccurrence[] = useMemo(() => {\n if (reducedTableData.length === 0 || selectedItem.length === 0) return [];\n const occurrence = reducedTableData.filter((tableEntry: InventoryTableData) => {\n return deepEqual(\n showAdditionalItems ? tableEntry.items : [tableEntry.items[0]],\n selectedItem,\n );\n });\n if (occurrence.length > 1) throw new Error('Selected item is not unique');\n return occurrence[0].occurrences;\n }, [selectedItem, showAdditionalItems, reducedTableData]);\n\n return (\n
    \n
    \n handleStatusFilterChange(value)}\n defaultValue={statusFilter}\n >\n \n \n \n \n {allItemsText}\n {approvedItemsText}\n {unapprovedItemsText}\n {unknownItemsText}\n \n \n \n {\n setTextFilter(event.target.value);\n }}\n />\n {additionalItemsLabels && (\n
    \n {\n setSelectedItem([]);\n setShowAdditionalItems(checked);\n }}\n />\n \n
    \n )}\n
    \n
    \n \n
    \n {occurrenceData.length > 0 && (\n
    \n \n
    \n )}\n
    \n );\n}\n","import { Input } from '@/components/shadcn-ui/input';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { useState } from 'react';\n\n/** Props for the SearchBar component. */\nexport type SearchBarProps = {\n className?: string;\n /**\n * Callback fired to handle the search query when button pressed\n *\n * @param searchQuery\n */\n onSearch: (searchQuery: string) => void;\n\n /** Optional string that appears in the search bar without a search string */\n placeholder?: string;\n\n /** Optional boolean to set the input base to full width */\n isFullWidth?: boolean;\n};\n\nexport default function SearchBar({\n className,\n onSearch,\n placeholder,\n isFullWidth,\n}: SearchBarProps) {\n const [searchQuery, setSearchQuery] = useState('');\n\n const handleInputChange = (searchString: string) => {\n setSearchQuery(searchString);\n onSearch(searchString);\n };\n\n return (\n handleInputChange(e.target.value)}\n />\n );\n}\n","// adapted from: https://github.com/shadcn-ui/ui/discussions/752\n\n'use client';\n\nimport { TabsContentProps, TabsListProps, TabsTriggerProps } from '@/components/shadcn-ui/tabs';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport * as TabsPrimitive from '@radix-ui/react-tabs';\nimport React from 'react';\n\nexport type VerticalTabsProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport type LeftTabsTriggerProps = TabsTriggerProps & {\n value: string;\n ref?: React.Ref;\n};\n\nexport const VerticalTabs = React.forwardRef<\n React.ElementRef,\n VerticalTabsProps\n>(({ className, ...props }, ref) => (\n \n));\n\nVerticalTabs.displayName = TabsPrimitive.List.displayName;\n\nexport const VerticalTabsList = React.forwardRef<\n React.ElementRef,\n TabsListProps\n>(({ className, ...props }, ref) => (\n \n));\nVerticalTabsList.displayName = TabsPrimitive.List.displayName;\n\nexport const VerticalTabsTrigger = React.forwardRef<\n React.ElementRef,\n LeftTabsTriggerProps\n>(({ className, ...props }, ref) => (\n \n));\n\nexport const VerticalTabsContent = React.forwardRef<\n React.ElementRef,\n TabsContentProps\n>(({ className, ...props }, ref) => (\n \n));\nVerticalTabsContent.displayName = TabsPrimitive.Content.displayName;\n","import SearchBar from '@/components/basics/search-bar.component';\nimport {\n VerticalTabs,\n VerticalTabsContent,\n VerticalTabsList,\n VerticalTabsTrigger,\n} from '@/components/basics/tabs-vertical';\nimport { ReactNode } from 'react';\n\nexport type TabKeyValueContent = {\n key: string;\n value: string;\n content: ReactNode;\n};\n\nexport type TabNavigationContentSearchProps = {\n /** List of values and keys for each tab this component should provide */\n tabList: TabKeyValueContent[];\n\n /** Handler to run when the value of the search bar changes */\n onSearch: (searchQuery: string) => void;\n\n /** Optional placeholder for the search bar */\n searchPlaceholder?: string;\n\n /** Optional title to include in the header */\n headerTitle?: string;\n\n /** Optional flag to make the search bar appear full width */\n isSearchBarFullWidth?: boolean;\n\n /** Text direction ltr or rtl */\n direction?: 'ltr' | 'rtl';\n};\n\nexport default function TabNavigationContentSearch({\n tabList,\n onSearch,\n searchPlaceholder,\n headerTitle,\n isSearchBarFullWidth = false,\n direction = 'ltr',\n}: TabNavigationContentSearchProps) {\n return (\n
    \n
    \n {headerTitle ?

    {headerTitle}

    : ''}\n \n
    \n \n \n {tabList.map((tab) => (\n \n {tab.value}\n \n ))}\n \n {tabList.map((tab) => (\n \n {tab.content}\n \n ))}\n \n
    \n );\n}\n","import React from 'react';\nimport * as SeparatorPrimitive from '@radix-ui/react-separator';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Separator = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, orientation = 'horizontal', decorative = true, ...props }, ref) => (\n \n));\nSeparator.displayName = SeparatorPrimitive.Root.displayName;\n\nexport { Separator };\n","'use client';\n\nimport * as React from 'react';\nimport * as SheetPrimitive from '@radix-ui/react-dialog';\nimport { cva, type VariantProps } from 'class-variance-authority';\nimport { X } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Sheet = SheetPrimitive.Root;\n\nconst SheetTrigger = SheetPrimitive.Trigger;\n\nconst SheetClose = SheetPrimitive.Close;\n\nconst SheetPortal = SheetPrimitive.Portal;\n\nconst SheetOverlay = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSheetOverlay.displayName = SheetPrimitive.Overlay.displayName;\n\nconst sheetVariants = cva(\n 'pr-twp tw-fixed tw-z-50 tw-gap-4 tw-bg-background tw-p-6 tw-shadow-lg tw-transition tw-ease-in-out data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-duration-300 data-[state=open]:tw-duration-500',\n {\n variants: {\n side: {\n top: 'tw-inset-x-0 tw-top-0 tw-border-b data-[state=closed]:tw-slide-out-to-top data-[state=open]:tw-slide-in-from-top',\n bottom:\n 'tw-inset-x-0 tw-bottom-0 tw-border-t data-[state=closed]:tw-slide-out-to-bottom data-[state=open]:tw-slide-in-from-bottom',\n left: 'tw-inset-y-0 tw-left-0 tw-h-full tw-w-3/4 tw-border-r data-[state=closed]:tw-slide-out-to-left data-[state=open]:tw-slide-in-from-left sm:tw-max-w-sm',\n right:\n 'tw-inset-y-0 tw-right-0 tw-h-full tw-w-3/4 tw- tw-border-l data-[state=closed]:tw-slide-out-to-right data-[state=open]:tw-slide-in-from-right sm:tw-max-w-sm',\n },\n },\n defaultVariants: {\n side: 'right',\n },\n },\n);\n\ninterface SheetContentProps\n extends React.ComponentPropsWithoutRef,\n VariantProps {}\n\nconst SheetContent = React.forwardRef<\n React.ElementRef,\n SheetContentProps\n>(({ side = 'right', className, children, ...props }, ref) => (\n \n \n \n {children}\n \n \n Close\n \n \n \n));\nSheetContent.displayName = SheetPrimitive.Content.displayName;\n\nfunction SheetHeader({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nSheetHeader.displayName = 'SheetHeader';\n\nfunction SheetFooter({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nSheetFooter.displayName = 'SheetFooter';\n\nconst SheetTitle = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSheetTitle.displayName = SheetPrimitive.Title.displayName;\n\nconst SheetDescription = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSheetDescription.displayName = SheetPrimitive.Description.displayName;\n\nexport {\n Sheet,\n SheetPortal,\n SheetOverlay,\n SheetTrigger,\n SheetClose,\n SheetContent,\n SheetHeader,\n SheetFooter,\n SheetTitle,\n SheetDescription,\n};\n","import React from 'react';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nfunction Skeleton({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\n\nexport { Skeleton };\n","import React from 'react';\nimport * as TooltipPrimitive from '@radix-ui/react-tooltip';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst TooltipProvider = TooltipPrimitive.Provider;\n\nconst Tooltip = TooltipPrimitive.Root;\n\nconst TooltipTrigger = TooltipPrimitive.Trigger;\n\nconst TooltipContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, sideOffset = 4, ...props }, ref) => (\n \n));\nTooltipContent.displayName = TooltipPrimitive.Content.displayName;\n\nexport { Tooltip, TooltipTrigger, TooltipContent, TooltipProvider };\n","import React from 'react';\n\nconst MOBILE_BREAKPOINT = 768;\n\nexport default function useIsMobile() {\n const [isMobile, setIsMobile] = React.useState(undefined);\n\n React.useEffect(() => {\n const mql = window.matchMedia(`(max-width: ${MOBILE_BREAKPOINT - 1}px)`);\n const onChange = () => {\n setIsMobile(window.innerWidth < MOBILE_BREAKPOINT);\n };\n mql.addEventListener('change', onChange);\n setIsMobile(window.innerWidth < MOBILE_BREAKPOINT);\n return () => mql.removeEventListener('change', onChange);\n }, []);\n\n return !!isMobile;\n}\n","import React from 'react';\nimport { Slot } from '@radix-ui/react-slot';\nimport { VariantProps, cva } from 'class-variance-authority';\nimport { PanelLeft } from 'lucide-react';\n\nimport { Button } from '@/components/shadcn-ui/button';\nimport { Input } from '@/components/shadcn-ui/input';\nimport { Separator } from '@/components/shadcn-ui/separator';\nimport { Sheet, SheetContent } from '@/components/shadcn-ui/sheet';\nimport { Skeleton } from '@/components/shadcn-ui/skeleton';\nimport {\n Tooltip,\n TooltipContent,\n TooltipProvider,\n TooltipTrigger,\n} from '@/components/shadcn-ui/tooltip';\nimport useIsMobile from '@/components/hooks/use-mobile';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst SIDEBAR_COOKIE_NAME = 'sidebar:state';\nconst SIDEBAR_COOKIE_MAX_AGE = 60 * 60 * 24 * 7;\nconst SIDEBAR_WIDTH = '16rem';\nconst SIDEBAR_WIDTH_MOBILE = '18rem';\nconst SIDEBAR_WIDTH_ICON = '3rem';\nconst SIDEBAR_KEYBOARD_SHORTCUT = 'b';\n\ntype SidebarContextProps = {\n state: 'expanded' | 'collapsed';\n open: boolean;\n setOpen: (open: boolean) => void;\n openMobile: boolean;\n setOpenMobile: (open: boolean) => void;\n isMobile: boolean;\n toggleSidebar: () => void;\n};\n\nconst SidebarContext = React.createContext(undefined);\n\nfunction useSidebar() {\n const context = React.useContext(SidebarContext);\n if (!context) {\n throw new Error('useSidebar must be used within a SidebarProvider.');\n }\n\n return context;\n}\n\nconst SidebarProvider = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & {\n defaultOpen?: boolean;\n open?: boolean;\n onOpenChange?: (open: boolean) => void;\n }\n>(\n (\n {\n defaultOpen = true,\n open: openProp,\n onOpenChange: setOpenProp,\n className,\n style,\n children,\n ...props\n },\n ref,\n ) => {\n const isMobile = useIsMobile();\n const [openMobile, setOpenMobile] = React.useState(false);\n\n // This is the internal state of the sidebar.\n // We use openProp and setOpenProp for control from outside the component.\n const [_open, _setOpen] = React.useState(defaultOpen);\n const isOpen = openProp ?? _open;\n const setOpen = React.useCallback(\n (value: boolean | ((value: boolean) => boolean)) => {\n const openState = typeof value === 'function' ? value(isOpen) : value;\n if (setOpenProp) {\n setOpenProp(openState);\n } else {\n _setOpen(openState);\n }\n\n // This sets the cookie to keep the sidebar state.\n document.cookie = `${SIDEBAR_COOKIE_NAME}=${openState}; path=/; max-age=${SIDEBAR_COOKIE_MAX_AGE}`;\n },\n [setOpenProp, isOpen],\n );\n\n // Helper to toggle the sidebar.\n const toggleSidebar = React.useCallback(() => {\n return isMobile ? setOpenMobile((open) => !open) : setOpen((open) => !open);\n }, [isMobile, setOpen, setOpenMobile]);\n\n // Adds a keyboard shortcut to toggle the sidebar.\n React.useEffect(() => {\n const handleKeyDown = (event: KeyboardEvent) => {\n if (event.key === SIDEBAR_KEYBOARD_SHORTCUT && (event.metaKey || event.ctrlKey)) {\n event.preventDefault();\n toggleSidebar();\n }\n };\n\n window.addEventListener('keydown', handleKeyDown);\n return () => window.removeEventListener('keydown', handleKeyDown);\n }, [toggleSidebar]);\n\n // We add a state so that we can do data-state=\"expanded\" or \"collapsed\".\n // This makes it easier to style the sidebar with Tailwind classes.\n const state = isOpen ? 'expanded' : 'collapsed';\n\n const contextValue = React.useMemo(\n () => ({\n state,\n open: isOpen,\n setOpen,\n isMobile,\n openMobile,\n setOpenMobile,\n toggleSidebar,\n }),\n [state, isOpen, setOpen, isMobile, openMobile, setOpenMobile, toggleSidebar],\n );\n\n return (\n \n \n \n {children}\n
    \n \n \n );\n },\n);\nSidebarProvider.displayName = 'SidebarProvider';\n\nconst Sidebar = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & {\n side?: 'left' | 'right';\n variant?: 'sidebar' | 'floating' | 'inset';\n collapsible?: 'offcanvas' | 'icon' | 'none';\n }\n>(\n (\n {\n side = 'left',\n variant = 'sidebar',\n collapsible = 'offcanvas',\n className,\n children,\n ...props\n },\n ref,\n ) => {\n const { isMobile, state, openMobile, setOpenMobile } = useSidebar();\n\n if (collapsible === 'none') {\n return (\n \n {children}\n
    \n );\n }\n\n if (isMobile) {\n return (\n \n button]:tw-hidden\"\n style={\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n {\n '--sidebar-width': SIDEBAR_WIDTH_MOBILE,\n } as React.CSSProperties\n }\n side={side}\n >\n
    {children}
    \n \n
    \n );\n }\n\n return (\n \n {/* This is what handles the sidebar gap on desktop */}\n \n \n \n {children}\n
    \n
    \n
    \n );\n },\n);\nSidebar.displayName = 'Sidebar';\n\nconst SidebarTrigger = React.forwardRef<\n React.ElementRef,\n React.ComponentProps\n>(({ className, onClick, ...props }, ref) => {\n const { toggleSidebar } = useSidebar();\n\n return (\n {\n onClick?.(event);\n toggleSidebar();\n }}\n {...props}\n >\n \n Toggle Sidebar\n \n );\n});\nSidebarTrigger.displayName = 'SidebarTrigger';\n\nconst SidebarRail = React.forwardRef>(\n ({ className, ...props }, ref) => {\n const { toggleSidebar } = useSidebar();\n\n return (\n \n );\n },\n);\nSidebarRail.displayName = 'SidebarRail';\n\nconst SidebarInset = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarInset.displayName = 'SidebarInset';\n\nconst SidebarInput = React.forwardRef<\n React.ElementRef,\n React.ComponentProps\n>(({ className, ...props }, ref) => {\n return (\n \n );\n});\nSidebarInput.displayName = 'SidebarInput';\n\nconst SidebarHeader = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarHeader.displayName = 'SidebarHeader';\n\nconst SidebarFooter = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarFooter.displayName = 'SidebarFooter';\n\nconst SidebarSeparator = React.forwardRef<\n React.ElementRef,\n React.ComponentProps\n>(({ className, ...props }, ref) => {\n return (\n \n );\n});\nSidebarSeparator.displayName = 'SidebarSeparator';\n\nconst SidebarContent = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarContent.displayName = 'SidebarContent';\n\nconst SidebarGroup = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarGroup.displayName = 'SidebarGroup';\n\nconst SidebarGroupLabel = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & { asChild?: boolean }\n>(({ className, asChild = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'div';\n\n return (\n svg]:tw-size-4 [&>svg]:tw-shrink-0',\n 'group-data-[collapsible=icon]:tw--mt-8 group-data-[collapsible=icon]:tw-opacity-0',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarGroupLabel.displayName = 'SidebarGroupLabel';\n\nconst SidebarGroupAction = React.forwardRef<\n HTMLButtonElement,\n React.ComponentProps<'button'> & { asChild?: boolean }\n>(({ className, asChild = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'button';\n\n return (\n svg]:tw-size-4 [&>svg]:tw-shrink-0',\n // Increases the hit area of the button on mobile.\n 'after:tw-absolute after:tw--inset-2 after:md:tw-hidden',\n 'group-data-[collapsible=icon]:tw-hidden',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarGroupAction.displayName = 'SidebarGroupAction';\n\nconst SidebarGroupContent = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarGroupContent.displayName = 'SidebarGroupContent';\n\nconst SidebarMenu = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenu.displayName = 'SidebarMenu';\n\nconst SidebarMenuItem = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenuItem.displayName = 'SidebarMenuItem';\n\nconst sidebarMenuButtonVariants = cva(\n // Removed data-[active=true]:tw-bg-sidebar-accent\n 'tw-peer/menu-button tw-flex tw-w-full tw-items-center tw-gap-2 tw-overflow-hidden tw-rounded-md tw-p-2 tw-text-left tw-text-sm tw-outline-none tw-ring-sidebar-ring tw-transition-[width,height,padding] hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground focus-visible:tw-ring-2 active:tw-bg-sidebar-accent active:tw-text-sidebar-accent-foreground disabled:tw-pointer-events-none disabled:tw-opacity-50 tw-group-has-[[data-sidebar=menu-action]]/menu-item:pr-8 aria-disabled:tw-pointer-events-none aria-disabled:tw-opacity-50 data-[active=true]:tw-font-medium data-[active=true]:tw-text-sidebar-accent-foreground data-[state=open]:hover:tw-bg-sidebar-accent data-[state=open]:hover:tw-text-sidebar-accent-foreground group-data-[collapsible=icon]:tw-!size-8 group-data-[collapsible=icon]:tw-!p-2 [&>span:last-child]:tw-truncate [&>svg]:tw-size-4 [&>svg]:tw-shrink-0',\n {\n variants: {\n variant: {\n default: 'hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground',\n outline:\n 'tw-bg-background tw-shadow-[0_0_0_1px_hsl(var(--sidebar-border))] hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground hover:tw-shadow-[0_0_0_1px_hsl(var(--sidebar-accent))]',\n },\n size: {\n default: 'tw-h-8 tw-text-sm',\n sm: 'tw-h-7 tw-text-xs',\n lg: 'tw-h-12 tw-text-sm group-data-[collapsible=icon]:tw-!p-0',\n },\n },\n defaultVariants: {\n variant: 'default',\n size: 'default',\n },\n },\n);\n\nconst SidebarMenuButton = React.forwardRef<\n HTMLButtonElement,\n React.ComponentProps<'button'> & {\n asChild?: boolean;\n isActive?: boolean;\n tooltip?: string | React.ComponentProps;\n } & VariantProps\n>(\n (\n {\n asChild = false,\n isActive = false,\n variant = 'default',\n size = 'default',\n tooltip,\n className,\n ...props\n },\n ref,\n ) => {\n const Comp = asChild ? Slot : 'button';\n const { isMobile, state } = useSidebar();\n\n const button = (\n \n );\n\n if (!tooltip) {\n return button;\n }\n\n if (typeof tooltip === 'string') {\n // eslint-disable-next-line no-param-reassign\n tooltip = {\n children: tooltip,\n };\n }\n\n return (\n \n {button}\n \n );\n },\n);\nSidebarMenuButton.displayName = 'SidebarMenuButton';\n\nconst SidebarMenuAction = React.forwardRef<\n HTMLButtonElement,\n React.ComponentProps<'button'> & {\n asChild?: boolean;\n showOnHover?: boolean;\n }\n>(({ className, asChild = false, showOnHover = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'button';\n\n return (\n svg]:tw-size-4 [&>svg]:tw-shrink-0',\n // Increases the hit area of the button on mobile.\n 'after:tw-absolute after:tw--inset-2 after:md:tw-hidden',\n 'tw-peer-data-[size=sm]/menu-button:top-1',\n 'tw-peer-data-[size=default]/menu-button:top-1.5',\n 'tw-peer-data-[size=lg]/menu-button:top-2.5',\n 'group-data-[collapsible=icon]:tw-hidden',\n showOnHover &&\n 'tw-group-focus-within/menu-item:opacity-100 tw-group-hover/menu-item:opacity-100 tw-peer-data-[active=true]/menu-button:text-sidebar-accent-foreground data-[state=open]:tw-opacity-100 md:tw-opacity-0',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarMenuAction.displayName = 'SidebarMenuAction';\n\nconst SidebarMenuBadge = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenuBadge.displayName = 'SidebarMenuBadge';\n\nconst SidebarMenuSkeleton = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & {\n showIcon?: boolean;\n }\n>(({ className, showIcon = false, ...props }, ref) => {\n // Random width between 50 to 90%.\n const width = React.useMemo(() => {\n return `${Math.floor(Math.random() * 40) + 50}%`;\n }, []);\n\n return (\n \n {showIcon && (\n \n )}\n \n
    \n );\n});\nSidebarMenuSkeleton.displayName = 'SidebarMenuSkeleton';\n\nconst SidebarMenuSub = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenuSub.displayName = 'SidebarMenuSub';\n\nconst SidebarMenuSubItem = React.forwardRef>(\n ({ ...props }, ref) =>
  • ,\n);\nSidebarMenuSubItem.displayName = 'SidebarMenuSubItem';\n\nconst SidebarMenuSubButton = React.forwardRef<\n HTMLAnchorElement,\n React.ComponentProps<'a'> & {\n asChild?: boolean;\n size?: 'sm' | 'md';\n isActive?: boolean;\n }\n>(({ asChild = false, size = 'md', isActive, className, ...props }, ref) => {\n const Comp = asChild ? Slot : 'a';\n\n return (\n span:last-child]:tw-truncate [&>svg]:tw-size-4 [&>svg]:tw-shrink-0 [&>svg]:tw-text-sidebar-accent-foreground',\n 'data-[active=true]:tw-bg-sidebar-accent data-[active=true]:tw-text-sidebar-accent-foreground',\n size === 'sm' && 'tw-text-xs',\n size === 'md' && 'tw-text-sm',\n 'group-data-[collapsible=icon]:tw-hidden',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarMenuSubButton.displayName = 'SidebarMenuSubButton';\n\nexport {\n Sidebar,\n SidebarContent,\n SidebarFooter,\n SidebarGroup,\n SidebarGroupAction,\n SidebarGroupContent,\n SidebarGroupLabel,\n SidebarHeader,\n SidebarInput,\n SidebarInset,\n SidebarMenu,\n SidebarMenuAction,\n SidebarMenuBadge,\n SidebarMenuButton,\n SidebarMenuItem,\n SidebarMenuSkeleton,\n SidebarMenuSub,\n SidebarMenuSubButton,\n SidebarMenuSubItem,\n SidebarProvider,\n SidebarRail,\n SidebarSeparator,\n SidebarTrigger,\n useSidebar,\n};\n","import ComboBox, { ComboBoxOption } from '@/components/basics/combo-box.component';\nimport {\n Sidebar,\n SidebarContent,\n SidebarGroup,\n SidebarGroupLabel,\n SidebarGroupContent,\n SidebarMenu,\n SidebarMenuItem,\n SidebarMenuButton,\n} from '@/components/shadcn-ui/sidebar';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { useCallback } from 'react';\n\nexport type SelectedSettingsSidebarItem = {\n label: string;\n projectId?: string;\n};\n\nexport type ProjectInfo = { projectId: string; projectName: string };\n\nexport type SettingsSidebarProps = {\n /** Optional id for testing */\n id?: string;\n\n /** Extension labels from contribution */\n extensionLabels: string[];\n\n /** Project names and ids */\n projectOptions: ProjectInfo[];\n\n /** Handler for selecting a sidebar item */\n handleSelectSidebarItem: (key: string, projectId?: string) => void;\n\n /** The current selected value in the sidebar */\n selectedSidebarItem: SelectedSettingsSidebarItem;\n\n /** Label for the group of extensions setting groups */\n extensionsSidebarGroupLabel: string;\n\n /** Label for the group of projects settings */\n projectsSidebarGroupLabel: string;\n\n /** Placeholder text for the button */\n buttonPlaceholderText: string;\n};\n\nexport default function SettingsSidebar({\n id,\n extensionLabels,\n projectOptions,\n handleSelectSidebarItem,\n selectedSidebarItem,\n extensionsSidebarGroupLabel,\n projectsSidebarGroupLabel,\n buttonPlaceholderText,\n}: SettingsSidebarProps) {\n const handleSelectItem = useCallback(\n (item: string, projectId?: string) => {\n handleSelectSidebarItem(item, projectId);\n },\n [handleSelectSidebarItem],\n );\n\n const getProjectNameFromProjectId = useCallback(\n (projectId: string) => {\n const project = projectOptions.find((option) => option.projectId === projectId);\n return project ? project.projectName : projectId;\n },\n [projectOptions],\n );\n\n const getIsActive: (label: string) => boolean = useCallback(\n (label: string) => !selectedSidebarItem.projectId && label === selectedSidebarItem.label,\n [selectedSidebarItem],\n );\n\n return (\n \n \n \n \n {extensionsSidebarGroupLabel}\n \n \n \n {extensionLabels.map((label) => (\n \n handleSelectItem(label)}\n isActive={getIsActive(label)}\n >\n {label}\n \n \n ))}\n \n \n \n \n \n {projectsSidebarGroupLabel}\n \n \n option.projectId)}\n getOptionLabel={(projectId: ComboBoxOption) => {\n // This function expects a ComboBoxOption, but we know it is a string\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n return getProjectNameFromProjectId(projectId as string);\n }}\n buttonPlaceholder={buttonPlaceholderText}\n onChange={(projectId: string) => {\n const selectedProjectName = getProjectNameFromProjectId(projectId);\n handleSelectItem(selectedProjectName, projectId);\n }}\n value={selectedSidebarItem?.projectId ?? undefined}\n />\n \n \n \n \n );\n}\n","import { SidebarInset, SidebarProvider } from '@/components/shadcn-ui/sidebar';\nimport { PropsWithChildren } from 'react';\nimport SearchBar from '@/components/basics/search-bar.component';\nimport SettingsSidebar, { SettingsSidebarProps } from './settings-sidebar.component';\n\nexport type SettingsSidebarContentSearchProps = SettingsSidebarProps &\n PropsWithChildren & {\n /** Optional id for testing */\n id?: string;\n\n /** Handler to run when the value of the search bar changes */\n onSearch: (searchQuery: string) => void;\n };\n\nexport default function SettingsSidebarContentSearch({\n id,\n extensionLabels,\n projectOptions,\n children,\n handleSelectSidebarItem,\n selectedSidebarItem,\n onSearch,\n extensionsSidebarGroupLabel,\n projectsSidebarGroupLabel,\n buttonPlaceholderText,\n}: SettingsSidebarContentSearchProps) {\n return (\n
    \n
    \n \n
    \n \n \n {children}\n \n
    \n );\n}\n","import { Button } from '@/components/shadcn-ui/button';\nimport {\n Select,\n SelectContent,\n SelectGroup,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\nimport {\n Table,\n TableBody,\n TableCell,\n TableHead,\n TableHeader,\n TableRow,\n} from '@/components/shadcn-ui/table';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Canon } from '@sillsdev/scripture';\nimport {\n Cell,\n ColumnDef,\n flexRender,\n getCoreRowModel,\n getExpandedRowModel,\n getGroupedRowModel,\n getSortedRowModel,\n GroupingState,\n Row,\n RowSelectionState,\n SortingState,\n useReactTable,\n} from '@tanstack/react-table';\nimport '@/components/advanced/scripture-results-viewer/scripture-results-viewer.component.css';\nimport {\n compareScrRefs,\n formatScrRef,\n ScriptureSelection,\n scrRefToBBBCCCVVV,\n} from 'platform-bible-utils';\nimport { MouseEvent, useEffect, useMemo, useState } from 'react';\nimport { ChevronDown, ChevronLeft, ChevronRight } from 'lucide-react';\n\n/**\n * Information (e.g., a checking error or some other type of \"transient\" annotation) about something\n * noteworthy at a specific place in an instance of the Scriptures.\n */\nexport type ScriptureItemDetail = ScriptureSelection & {\n /**\n * Text of the error, note, etc. In the future, we might want to support something more than just\n * text so that a JSX element could be provided with a link or some other controls related to the\n * issue being reported.\n */\n detail: string;\n};\n\n/**\n * A uniquely identifiable source of results that can be displayed in the ScriptureResultsViewer.\n * Generally, the source will be a particular Scripture check, but there may be other types of\n * sources.\n */\nexport type ResultsSource = {\n /**\n * Uniquely identifies the source.\n *\n * @type {string}\n */\n id: string;\n\n /**\n * Name (potentially localized) of the source, suitable for display in the UI.\n *\n * @type {string}\n */\n displayName: string;\n};\n\nexport type ScriptureSrcItemDetail = ScriptureItemDetail & {\n /** Source/type of detail. Can be used for grouping. */\n source: ResultsSource;\n};\n\n/**\n * Represents a set of results keyed by Scripture reference. Generally, the source will be a\n * particular Scripture check, but this type also allows for other types of uniquely identifiable\n * sources.\n */\nexport type ResultsSet = {\n /**\n * The backing source associated with this set of results.\n *\n * @type {ResultsSource}\n */\n source: ResultsSource;\n\n /**\n * Array of Scripture item details (messages keyed by Scripture reference).\n *\n * @type {ScriptureItemDetail[]}\n */\n data: ScriptureItemDetail[];\n};\n\nconst scrBookColId = 'scrBook';\nconst scrRefColId = 'scrRef';\nconst typeColId = 'source';\nconst detailsColId = 'details';\n\nconst defaultScrRefColumnName = 'Scripture Reference';\nconst defaultScrBookGroupName = 'Scripture Book';\nconst defaultTypeColumnName = 'Type';\nconst defaultDetailsColumnName = 'Details';\n\nexport type ScriptureResultsViewerColumnInfo = {\n /** Optional header to display for the Reference column. Default value: 'Scripture Reference'. */\n scriptureReferenceColumnName?: string;\n\n /** Optional text to display to refer to the Scripture book group. Default value: 'Scripture Book'. */\n scriptureBookGroupName?: string;\n\n /** Optional header to display for the Type column. Default value: 'Type'. */\n typeColumnName?: string;\n\n /** Optional header to display for the Details column. Default value: 'Details' */\n detailsColumnName?: string;\n};\n\nexport type ScriptureResultsViewerProps = ScriptureResultsViewerColumnInfo & {\n /** Groups of ScriptureItemDetail objects from particular sources (e.g., Scripture checks) */\n sources: ResultsSet[];\n\n /** Flag indicating whether to display column headers. Default is false. */\n showColumnHeaders?: boolean;\n\n /** Flag indicating whether to display source column. Default is false. */\n showSourceColumn?: boolean;\n\n /** Callback function to notify when a row is selected */\n onRowSelected?: (selectedRow: ScriptureSrcItemDetail | undefined) => void;\n\n /** Text direction ltr or rtl */\n direction?: 'ltr' | 'rtl';\n};\n\nfunction getColumns(\n colInfo?: ScriptureResultsViewerColumnInfo,\n showSourceColumn?: boolean,\n): ColumnDef[] {\n const showSrcCol = showSourceColumn ?? false;\n return [\n {\n accessorFn: (row) =>\n `${Canon.bookNumberToId(row.start.bookNum)} ${row.start.chapterNum}:${row.start.verseNum}`,\n id: scrBookColId,\n header: colInfo?.scriptureReferenceColumnName ?? defaultScrRefColumnName,\n cell: (info) => {\n const row = info.row.original;\n if (info.row.getIsGrouped()) {\n return Canon.bookNumberToEnglishName(row.start.bookNum);\n }\n return info.row.groupingColumnId === scrBookColId ? formatScrRef(row.start) : undefined;\n },\n getGroupingValue: (row) => row.start.bookNum,\n sortingFn: (a, b) => {\n return compareScrRefs(a.original.start, b.original.start);\n },\n enableGrouping: true,\n },\n {\n accessorFn: (row) => formatScrRef(row.start),\n id: scrRefColId,\n header: undefined,\n cell: (info) => {\n const row = info.row.original;\n return info.row.getIsGrouped() ? undefined : formatScrRef(row.start);\n },\n sortingFn: (a, b) => {\n return compareScrRefs(a.original.start, b.original.start);\n },\n enableGrouping: false,\n },\n {\n accessorFn: (row) => row.source.displayName,\n id: typeColId,\n header: showSrcCol ? (colInfo?.typeColumnName ?? defaultTypeColumnName) : undefined,\n cell: (info) => (showSrcCol || info.row.getIsGrouped() ? info.getValue() : undefined),\n getGroupingValue: (row) => row.source.id,\n sortingFn: (a, b) =>\n a.original.source.displayName.localeCompare(b.original.source.displayName),\n enableGrouping: true,\n },\n {\n accessorFn: (row) => row.detail,\n id: detailsColId,\n header: colInfo?.detailsColumnName ?? defaultDetailsColumnName,\n cell: (info) => info.getValue(),\n enableGrouping: false,\n },\n ];\n}\n\nconst toRefOrRange = (scriptureSelection: ScriptureSelection) => {\n if (!('offset' in scriptureSelection.start))\n throw new Error('No offset available in range start');\n if (scriptureSelection.end && !('offset' in scriptureSelection.end))\n throw new Error('No offset available in range end');\n const { offset: offsetStart } = scriptureSelection.start;\n let offsetEnd: number = 0;\n if (scriptureSelection.end) ({ offset: offsetEnd } = scriptureSelection.end);\n if (\n !scriptureSelection.end ||\n compareScrRefs(scriptureSelection.start, scriptureSelection.end) === 0\n )\n return `${scrRefToBBBCCCVVV(scriptureSelection.start)}+${offsetStart}`;\n return `${scrRefToBBBCCCVVV(scriptureSelection.start)}+${offsetStart}-${scrRefToBBBCCCVVV(scriptureSelection.end)}+${offsetEnd}`;\n};\n\nconst getRowKey = (row: ScriptureSrcItemDetail) =>\n `${toRefOrRange({ start: row.start, end: row.end })} ${row.source.displayName} ${row.detail}`;\n\n/**\n * Component to display a combined list of detailed items from one or more sources, where the items\n * are keyed primarily by Scripture reference. This is particularly useful for displaying a list of\n * results from Scripture checks, but more generally could be used to display any \"results\" from any\n * source(s). The component allows for grouping by Scripture book, source, or both. By default, it\n * displays somewhat \"tree-like\" which allows it to be more horizontally compact and intuitive. But\n * it also has the option of displaying as a traditional table with column headings (with or without\n * the source column showing).\n */\nexport default function ScriptureResultsViewer({\n sources,\n showColumnHeaders = false,\n showSourceColumn = false,\n scriptureReferenceColumnName,\n scriptureBookGroupName,\n typeColumnName,\n detailsColumnName,\n onRowSelected,\n direction = 'ltr',\n}: ScriptureResultsViewerProps) {\n const [grouping, setGrouping] = useState([]);\n const [sorting, setSorting] = useState([{ id: scrBookColId, desc: false }]);\n const [rowSelection, setRowSelection] = useState({});\n\n const scriptureResults = useMemo(\n () =>\n sources.flatMap((source) => {\n return source.data.map((item) => ({\n ...item,\n source: source.source,\n }));\n }),\n [sources],\n );\n\n const columns = useMemo(\n () =>\n getColumns(\n {\n scriptureReferenceColumnName,\n typeColumnName,\n detailsColumnName,\n },\n showSourceColumn,\n ),\n [scriptureReferenceColumnName, typeColumnName, detailsColumnName, showSourceColumn],\n );\n\n useEffect(() => {\n // Ensure sorting is applied correctly when grouped by type\n if (grouping.includes(typeColId)) {\n setSorting([\n { id: typeColId, desc: false },\n { id: scrBookColId, desc: false },\n ]);\n } else {\n setSorting([{ id: scrBookColId, desc: false }]);\n }\n }, [grouping]);\n\n const table = useReactTable({\n data: scriptureResults,\n columns,\n state: {\n grouping,\n sorting,\n rowSelection,\n },\n onGroupingChange: setGrouping,\n onSortingChange: setSorting,\n onRowSelectionChange: setRowSelection,\n getExpandedRowModel: getExpandedRowModel(),\n getGroupedRowModel: getGroupedRowModel(),\n getCoreRowModel: getCoreRowModel(),\n getSortedRowModel: getSortedRowModel(),\n getRowId: getRowKey,\n autoResetExpanded: false,\n enableMultiRowSelection: false,\n enableSubRowSelection: false,\n });\n\n useEffect(() => {\n if (onRowSelected) {\n const selectedRows = table.getSelectedRowModel().rowsById;\n const keys = Object.keys(selectedRows);\n if (keys.length === 1) {\n const selectedRow = scriptureResults.find((row) => getRowKey(row) === keys[0]) || undefined;\n if (selectedRow) onRowSelected(selectedRow);\n }\n }\n }, [rowSelection, scriptureResults, onRowSelected, table]);\n\n // Define possible grouping options\n const scrBookGroupName = scriptureBookGroupName ?? defaultScrBookGroupName;\n const typeGroupName = typeColumnName ?? defaultTypeColumnName;\n\n const groupingOptions = [\n { label: 'No Grouping', value: [] },\n { label: `Group by ${scrBookGroupName}`, value: [scrBookColId] },\n { label: `Group by ${typeGroupName}`, value: [typeColId] },\n {\n label: `Group by ${scrBookGroupName} and ${typeGroupName}`,\n value: [scrBookColId, typeColId],\n },\n {\n label: `Group by ${typeGroupName} and ${scrBookGroupName}`,\n value: [typeColId, scrBookColId],\n },\n ];\n\n const handleSelectChange = (selectedGrouping: string) => {\n setGrouping(JSON.parse(selectedGrouping));\n };\n\n const handleRowClick = (row: Row, event: MouseEvent) => {\n if (!row.getIsGrouped() && !row.getIsSelected()) {\n row.getToggleSelectedHandler()(event);\n }\n };\n\n const getEvenOrOddBandingStyle = (row: Row, index: number) => {\n if (row.getIsGrouped()) return '';\n // UX has now said they don't think they want banding. I'm leaving in the code to\n // set even and odd styles, but there's nothing in the CSS to style them differently.\n // The \"even\" style used to also have tw-bg-neutral-300 (along with even) to create\n // a visual banding effect. That could be added back in if UX changes the decision.\n return cn('banded-row', index % 2 === 0 ? 'even' : 'odd');\n };\n\n const getIndent = (\n groupingState: GroupingState,\n row: Row,\n cell: Cell,\n ) => {\n if (groupingState?.length === 0 || row.depth < cell.column.getGroupedIndex()) return undefined;\n if (row.getIsGrouped()) {\n switch (row.depth) {\n case 1:\n return 'tw-ps-4';\n default:\n return undefined;\n }\n }\n switch (row.depth) {\n case 1:\n return 'tw-ps-8';\n case 2:\n return 'tw-ps-12';\n default:\n return undefined;\n }\n };\n\n return (\n
    \n {!showColumnHeaders && (\n {\n handleSelectChange(value);\n }}\n >\n \n \n \n \n \n {groupingOptions.map((option) => (\n \n {option.label}\n \n ))}\n \n \n \n )}\n \n {showColumnHeaders && (\n \n {table.getHeaderGroups().map((headerGroup) => (\n \n {headerGroup.headers\n .filter((h) => h.column.columnDef.header)\n .map((header) => (\n /* For sticky column headers to work, we probably need to change the default definition of the shadcn Table component. See https://github.com/shadcn-ui/ui/issues/1151 */\n \n {header.isPlaceholder ? undefined : (\n
    \n {header.column.getCanGroup() ? (\n \n {header.column.getIsGrouped() ? `🛑` : `👊 `}\n \n ) : undefined}{' '}\n {flexRender(header.column.columnDef.header, header.getContext())}\n
    \n )}\n
    \n ))}\n
    \n ))}\n
    \n )}\n \n {table.getRowModel().rows.map((row, rowIndex) => {\n return (\n handleRowClick(row, event)}\n >\n {row.getVisibleCells().map((cell) => {\n if (\n cell.getIsPlaceholder() ||\n (cell.column.columnDef.enableGrouping &&\n !cell.getIsGrouped() &&\n (cell.column.columnDef.id !== typeColId || !showSourceColumn))\n )\n return undefined;\n return (\n \n {(() => {\n if (cell.getIsGrouped()) {\n return (\n \n {row.getIsExpanded() && }\n {!row.getIsExpanded() &&\n (direction === 'ltr' ? : )}{' '}\n {flexRender(cell.column.columnDef.cell, cell.getContext())} (\n {row.subRows.length})\n \n );\n }\n\n // if (cell.getIsAggregated()) {\n // flexRender(\n // cell.column.columnDef.aggregatedCell ?? cell.column.columnDef.cell,\n // cell.getContext(),\n // );\n // }\n\n return flexRender(cell.column.columnDef.cell, cell.getContext());\n })()}\n \n );\n })}\n \n );\n })}\n \n
    \n
    \n );\n}\n","import {\n getLocalizeKeyForScrollGroupId,\n LanguageStrings,\n ScrollGroupId,\n} from 'platform-bible-utils';\nimport {\n Select,\n SelectContent,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\n\nconst DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS = {\n [getLocalizeKeyForScrollGroupId('undefined')]: 'Ø',\n [getLocalizeKeyForScrollGroupId(0)]: 'A',\n [getLocalizeKeyForScrollGroupId(1)]: 'B',\n [getLocalizeKeyForScrollGroupId(2)]: 'C',\n [getLocalizeKeyForScrollGroupId(3)]: 'D',\n [getLocalizeKeyForScrollGroupId(4)]: 'E',\n [getLocalizeKeyForScrollGroupId(5)]: 'F',\n [getLocalizeKeyForScrollGroupId(6)]: 'G',\n [getLocalizeKeyForScrollGroupId(7)]: 'H',\n [getLocalizeKeyForScrollGroupId(8)]: 'I',\n [getLocalizeKeyForScrollGroupId(9)]: 'J',\n [getLocalizeKeyForScrollGroupId(10)]: 'K',\n [getLocalizeKeyForScrollGroupId(11)]: 'L',\n [getLocalizeKeyForScrollGroupId(12)]: 'M',\n [getLocalizeKeyForScrollGroupId(13)]: 'N',\n [getLocalizeKeyForScrollGroupId(14)]: 'O',\n [getLocalizeKeyForScrollGroupId(15)]: 'P',\n [getLocalizeKeyForScrollGroupId(16)]: 'Q',\n [getLocalizeKeyForScrollGroupId(17)]: 'R',\n [getLocalizeKeyForScrollGroupId(18)]: 'S',\n [getLocalizeKeyForScrollGroupId(19)]: 'T',\n [getLocalizeKeyForScrollGroupId(20)]: 'U',\n [getLocalizeKeyForScrollGroupId(21)]: 'V',\n [getLocalizeKeyForScrollGroupId(22)]: 'W',\n [getLocalizeKeyForScrollGroupId(23)]: 'X',\n [getLocalizeKeyForScrollGroupId(24)]: 'Y',\n [getLocalizeKeyForScrollGroupId(25)]: 'Z',\n};\n\nexport type ScrollGroupSelectorProps = {\n /**\n * List of scroll group ids to show to the user. Either a {@link ScrollGroupId} or `undefined` for\n * no scroll group\n */\n availableScrollGroupIds: (ScrollGroupId | undefined)[];\n /** Currently selected scroll group id. `undefined` for no scroll group */\n scrollGroupId: ScrollGroupId | undefined;\n /** Callback function run when the user tries to change the scroll group id */\n onChangeScrollGroupId: (newScrollGroupId: ScrollGroupId | undefined) => void;\n /**\n * Localized strings to use for displaying scroll group ids. Must be an object whose keys are\n * `getLocalizeKeyForScrollGroupId(scrollGroupId)` for all scroll group ids (and `undefined` if\n * included) in {@link ScrollGroupSelectorProps.availableScrollGroupIds} and whose values are the\n * localized strings to use for those scroll group ids.\n *\n * Defaults to English localizations of English alphabet for scroll groups 0-25 (e.g. 0 is A) and\n * Ø for `undefined`. Will fill in any that are not provided with these English localizations.\n * Also, if any values match the keys, the English localization will be used. This is useful in\n * case you want to pass in a temporary version of the localized strings while your localized\n * strings load.\n *\n * @example\n *\n * ```typescript\n * const myScrollGroupIdLocalizedStrings = {\n * [getLocalizeKeyForScrollGroupId('undefined')]: 'Ø',\n * [getLocalizeKeyForScrollGroupId(0)]: 'A',\n * [getLocalizeKeyForScrollGroupId(1)]: 'B',\n * [getLocalizeKeyForScrollGroupId(2)]: 'C',\n * [getLocalizeKeyForScrollGroupId(3)]: 'D',\n * [getLocalizeKeyForScrollGroupId(4)]: 'E',\n * };\n * ```\n *\n * @example\n *\n * ```tsx\n * const availableScrollGroupIds = [undefined, 0, 1, 2, 3, 4];\n *\n * const localizeKeys = getLocalizeKeysForScrollGroupIds();\n *\n * const [localizedStrings] = useLocalizedStrings(localizeKeys);\n *\n * ...\n *\n * \n * ```\n */\n localizedStrings?: LanguageStrings;\n};\n\n/** Selector component for choosing a scroll group */\nexport default function ScrollGroupSelector({\n availableScrollGroupIds,\n scrollGroupId,\n onChangeScrollGroupId,\n localizedStrings = {},\n}: ScrollGroupSelectorProps) {\n const localizedStringsDefaulted = {\n ...DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS,\n ...Object.fromEntries(\n Object.entries(localizedStrings).map(\n ([localizedStringKey, localizedStringValue]: [string, string]) => [\n localizedStringKey,\n localizedStringKey === localizedStringValue &&\n localizedStringKey in DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS\n ? DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS[localizedStringKey]\n : localizedStringValue,\n ],\n ),\n ),\n };\n return (\n \n onChangeScrollGroupId(\n newScrollGroupString === 'undefined' ? undefined : parseInt(newScrollGroupString, 10),\n )\n }\n >\n \n \n \n \n {availableScrollGroupIds.map((scrollGroupOptionId) => (\n \n {localizedStringsDefaulted[getLocalizeKeyForScrollGroupId(scrollGroupOptionId)]}\n \n ))}\n \n \n );\n}\n","import { PropsWithChildren } from 'react';\nimport { Separator } from '@/components/shadcn-ui/separator';\n\n/** Props for the SettingsList component, currently just children */\ntype SettingsListProps = PropsWithChildren;\n\n/**\n * SettingsList component is a wrapper for list items. Rendered with a formatted div\n *\n * @param children To populate the list with\n * @returns Formatted div encompassing the children\n */\nexport function SettingsList({ children }: SettingsListProps) {\n return
    {children}
    ;\n}\n\n/** Props for SettingsListItem component */\ntype SettingsListItemProps = PropsWithChildren & {\n /** Primary text of the list item */\n primary: string;\n\n /** Optional text of the list item */\n secondary?: string | undefined;\n\n /** Optional boolean to display a message if the children aren't loaded yet. Defaults to false */\n isLoading?: boolean;\n\n /** Optional message to display if isLoading */\n loadingMessage?: string;\n};\n\n/**\n * SettingsListItem component is a common list item. Rendered with a formatted div\n *\n * @param primary Primary text of the list item\n * @param secondary Optional secondary text of the list item\n * @param isLoading Optional, to display a message if the action component isn't generated yet,\n * defaults to false\n * @param children The action component(s) to provide for this item\n * @param loadingMessage Optional, message to display if isLoading\n * @returns Formatted div encompassing the list item content\n */\nexport function SettingsListItem({\n primary,\n secondary,\n children,\n isLoading = false,\n loadingMessage,\n}: SettingsListItemProps) {\n return (\n
    \n
    \n

    {primary}

    \n

    \n {secondary}\n

    \n
    \n\n {isLoading ? (\n

    {loadingMessage}

    \n ) : (\n
    {children}
    \n )}\n
    \n );\n}\n\n/** Props for SettingsListHeader component */\ntype SettingsListHeaderProps = {\n /** The primary text of the list header */\n primary: string;\n\n /** Optional secondary text of the list header */\n secondary?: string | undefined;\n\n /** Optional boolean to include a separator underneath the secondary text. Defaults to false */\n includeSeparator?: boolean;\n};\n\n/**\n * SettingsListHeader component displays text above the list\n *\n * @param primary The primary text of the list header\n * @param secondary Optional secondary text of the list header\n * @param includeSeparator Optional boolean to include a separator underneath the secondary text.\n * Defaults to false\n * @returns Formatted div with list header content\n */\nexport function SettingsListHeader({\n primary,\n secondary,\n includeSeparator = false,\n}: SettingsListHeaderProps) {\n return (\n
    \n
    \n

    {primary}

    \n

    {secondary}

    \n
    \n {includeSeparator ? : ''}\n
    \n );\n}\n","import Checkbox from '@/components/shadcn-ui/checkbox';\nimport { Label } from '@/components/shadcn-ui/label';\n\nexport type ChecklistProps = {\n /** Optional string representing the id attribute of the Checklist */\n id?: string;\n /** Optional string representing CSS class name(s) for styling */\n className?: string;\n /** Array of strings representing the checkable items */\n listItems: string[];\n /** Array of strings representing the checked items */\n selectedListItems: string[];\n /**\n * Function that is called when a checkbox item is selected or deselected\n *\n * @param item The string description for this item\n * @param selected True if selected, false if not selected\n */\n handleSelectListItem: (item: string, selected: boolean) => void;\n\n /**\n * Optional function creates a label for a provided checkable item\n *\n * @param item The item for which a label is to be created\n * @returns A string representing the label text for the checkbox associated with that item\n */\n createLabel?: (item: string) => string;\n};\n\n/** Renders a list of checkboxes. Each checkbox corresponds to an item from the `listItems` array. */\nexport default function Checklist({\n id,\n className,\n listItems,\n selectedListItems,\n handleSelectListItem,\n createLabel,\n}: ChecklistProps) {\n return (\n
    \n {listItems.map((item) => (\n
    \n handleSelectListItem(item, value)}\n />\n \n
    \n ))}\n
    \n );\n}\n","function _interopRequireDefault(obj) {\n return obj && obj.__esModule ? obj : {\n \"default\": obj\n };\n}\nmodule.exports = _interopRequireDefault, module.exports.__esModule = true, module.exports[\"default\"] = module.exports;","export default function chainPropTypes(propType1, propType2) {\n if (process.env.NODE_ENV === 'production') {\n return () => null;\n }\n return function validate(...args) {\n return propType1(...args) || propType2(...args);\n };\n}","export default function _extends() {\n _extends = Object.assign ? Object.assign.bind() : function (target) {\n for (var i = 1; i < arguments.length; i++) {\n var source = arguments[i];\n for (var key in source) {\n if (Object.prototype.hasOwnProperty.call(source, key)) {\n target[key] = source[key];\n }\n }\n }\n return target;\n };\n return _extends.apply(this, arguments);\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\n// https://github.com/sindresorhus/is-plain-obj/blob/main/index.js\nexport function isPlainObject(item) {\n if (typeof item !== 'object' || item === null) {\n return false;\n }\n const prototype = Object.getPrototypeOf(item);\n return (prototype === null || prototype === Object.prototype || Object.getPrototypeOf(prototype) === null) && !(Symbol.toStringTag in item) && !(Symbol.iterator in item);\n}\nfunction deepClone(source) {\n if (!isPlainObject(source)) {\n return source;\n }\n const output = {};\n Object.keys(source).forEach(key => {\n output[key] = deepClone(source[key]);\n });\n return output;\n}\nexport default function deepmerge(target, source, options = {\n clone: true\n}) {\n const output = options.clone ? _extends({}, target) : target;\n if (isPlainObject(target) && isPlainObject(source)) {\n Object.keys(source).forEach(key => {\n // Avoid prototype pollution\n if (key === '__proto__') {\n return;\n }\n if (isPlainObject(source[key]) && key in target && isPlainObject(target[key])) {\n // Since `output` is a clone of `target` and we have narrowed `target` in this block we can cast to the same type.\n output[key] = deepmerge(target[key], source[key], options);\n } else if (options.clone) {\n output[key] = isPlainObject(source[key]) ? deepClone(source[key]) : source[key];\n } else {\n output[key] = source[key];\n }\n });\n }\n return output;\n}","/** @license React v16.13.1\n * react-is.production.min.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';var b=\"function\"===typeof Symbol&&Symbol.for,c=b?Symbol.for(\"react.element\"):60103,d=b?Symbol.for(\"react.portal\"):60106,e=b?Symbol.for(\"react.fragment\"):60107,f=b?Symbol.for(\"react.strict_mode\"):60108,g=b?Symbol.for(\"react.profiler\"):60114,h=b?Symbol.for(\"react.provider\"):60109,k=b?Symbol.for(\"react.context\"):60110,l=b?Symbol.for(\"react.async_mode\"):60111,m=b?Symbol.for(\"react.concurrent_mode\"):60111,n=b?Symbol.for(\"react.forward_ref\"):60112,p=b?Symbol.for(\"react.suspense\"):60113,q=b?\nSymbol.for(\"react.suspense_list\"):60120,r=b?Symbol.for(\"react.memo\"):60115,t=b?Symbol.for(\"react.lazy\"):60116,v=b?Symbol.for(\"react.block\"):60121,w=b?Symbol.for(\"react.fundamental\"):60117,x=b?Symbol.for(\"react.responder\"):60118,y=b?Symbol.for(\"react.scope\"):60119;\nfunction z(a){if(\"object\"===typeof a&&null!==a){var u=a.$$typeof;switch(u){case c:switch(a=a.type,a){case l:case m:case e:case g:case f:case p:return a;default:switch(a=a&&a.$$typeof,a){case k:case n:case t:case r:case h:return a;default:return u}}case d:return u}}}function A(a){return z(a)===m}exports.AsyncMode=l;exports.ConcurrentMode=m;exports.ContextConsumer=k;exports.ContextProvider=h;exports.Element=c;exports.ForwardRef=n;exports.Fragment=e;exports.Lazy=t;exports.Memo=r;exports.Portal=d;\nexports.Profiler=g;exports.StrictMode=f;exports.Suspense=p;exports.isAsyncMode=function(a){return A(a)||z(a)===l};exports.isConcurrentMode=A;exports.isContextConsumer=function(a){return z(a)===k};exports.isContextProvider=function(a){return z(a)===h};exports.isElement=function(a){return\"object\"===typeof a&&null!==a&&a.$$typeof===c};exports.isForwardRef=function(a){return z(a)===n};exports.isFragment=function(a){return z(a)===e};exports.isLazy=function(a){return z(a)===t};\nexports.isMemo=function(a){return z(a)===r};exports.isPortal=function(a){return z(a)===d};exports.isProfiler=function(a){return z(a)===g};exports.isStrictMode=function(a){return z(a)===f};exports.isSuspense=function(a){return z(a)===p};\nexports.isValidElementType=function(a){return\"string\"===typeof a||\"function\"===typeof a||a===e||a===m||a===g||a===f||a===p||a===q||\"object\"===typeof a&&null!==a&&(a.$$typeof===t||a.$$typeof===r||a.$$typeof===h||a.$$typeof===k||a.$$typeof===n||a.$$typeof===w||a.$$typeof===x||a.$$typeof===y||a.$$typeof===v)};exports.typeOf=z;\n","/** @license React v16.13.1\n * react-is.development.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\n\n\nif (process.env.NODE_ENV !== \"production\") {\n (function() {\n'use strict';\n\n// The Symbol used to tag the ReactElement-like types. If there is no native Symbol\n// nor polyfill, then a plain number is used for performance.\nvar hasSymbol = typeof Symbol === 'function' && Symbol.for;\nvar REACT_ELEMENT_TYPE = hasSymbol ? Symbol.for('react.element') : 0xeac7;\nvar REACT_PORTAL_TYPE = hasSymbol ? Symbol.for('react.portal') : 0xeaca;\nvar REACT_FRAGMENT_TYPE = hasSymbol ? Symbol.for('react.fragment') : 0xeacb;\nvar REACT_STRICT_MODE_TYPE = hasSymbol ? Symbol.for('react.strict_mode') : 0xeacc;\nvar REACT_PROFILER_TYPE = hasSymbol ? Symbol.for('react.profiler') : 0xead2;\nvar REACT_PROVIDER_TYPE = hasSymbol ? Symbol.for('react.provider') : 0xeacd;\nvar REACT_CONTEXT_TYPE = hasSymbol ? Symbol.for('react.context') : 0xeace; // TODO: We don't use AsyncMode or ConcurrentMode anymore. They were temporary\n// (unstable) APIs that have been removed. Can we remove the symbols?\n\nvar REACT_ASYNC_MODE_TYPE = hasSymbol ? Symbol.for('react.async_mode') : 0xeacf;\nvar REACT_CONCURRENT_MODE_TYPE = hasSymbol ? Symbol.for('react.concurrent_mode') : 0xeacf;\nvar REACT_FORWARD_REF_TYPE = hasSymbol ? Symbol.for('react.forward_ref') : 0xead0;\nvar REACT_SUSPENSE_TYPE = hasSymbol ? Symbol.for('react.suspense') : 0xead1;\nvar REACT_SUSPENSE_LIST_TYPE = hasSymbol ? Symbol.for('react.suspense_list') : 0xead8;\nvar REACT_MEMO_TYPE = hasSymbol ? Symbol.for('react.memo') : 0xead3;\nvar REACT_LAZY_TYPE = hasSymbol ? Symbol.for('react.lazy') : 0xead4;\nvar REACT_BLOCK_TYPE = hasSymbol ? Symbol.for('react.block') : 0xead9;\nvar REACT_FUNDAMENTAL_TYPE = hasSymbol ? Symbol.for('react.fundamental') : 0xead5;\nvar REACT_RESPONDER_TYPE = hasSymbol ? Symbol.for('react.responder') : 0xead6;\nvar REACT_SCOPE_TYPE = hasSymbol ? Symbol.for('react.scope') : 0xead7;\n\nfunction isValidElementType(type) {\n return typeof type === 'string' || typeof type === 'function' || // Note: its typeof might be other than 'symbol' or 'number' if it's a polyfill.\n type === REACT_FRAGMENT_TYPE || type === REACT_CONCURRENT_MODE_TYPE || type === REACT_PROFILER_TYPE || type === REACT_STRICT_MODE_TYPE || type === REACT_SUSPENSE_TYPE || type === REACT_SUSPENSE_LIST_TYPE || typeof type === 'object' && type !== null && (type.$$typeof === REACT_LAZY_TYPE || type.$$typeof === REACT_MEMO_TYPE || type.$$typeof === REACT_PROVIDER_TYPE || type.$$typeof === REACT_CONTEXT_TYPE || type.$$typeof === REACT_FORWARD_REF_TYPE || type.$$typeof === REACT_FUNDAMENTAL_TYPE || type.$$typeof === REACT_RESPONDER_TYPE || type.$$typeof === REACT_SCOPE_TYPE || type.$$typeof === REACT_BLOCK_TYPE);\n}\n\nfunction typeOf(object) {\n if (typeof object === 'object' && object !== null) {\n var $$typeof = object.$$typeof;\n\n switch ($$typeof) {\n case REACT_ELEMENT_TYPE:\n var type = object.type;\n\n switch (type) {\n case REACT_ASYNC_MODE_TYPE:\n case REACT_CONCURRENT_MODE_TYPE:\n case REACT_FRAGMENT_TYPE:\n case REACT_PROFILER_TYPE:\n case REACT_STRICT_MODE_TYPE:\n case REACT_SUSPENSE_TYPE:\n return type;\n\n default:\n var $$typeofType = type && type.$$typeof;\n\n switch ($$typeofType) {\n case REACT_CONTEXT_TYPE:\n case REACT_FORWARD_REF_TYPE:\n case REACT_LAZY_TYPE:\n case REACT_MEMO_TYPE:\n case REACT_PROVIDER_TYPE:\n return $$typeofType;\n\n default:\n return $$typeof;\n }\n\n }\n\n case REACT_PORTAL_TYPE:\n return $$typeof;\n }\n }\n\n return undefined;\n} // AsyncMode is deprecated along with isAsyncMode\n\nvar AsyncMode = REACT_ASYNC_MODE_TYPE;\nvar ConcurrentMode = REACT_CONCURRENT_MODE_TYPE;\nvar ContextConsumer = REACT_CONTEXT_TYPE;\nvar ContextProvider = REACT_PROVIDER_TYPE;\nvar Element = REACT_ELEMENT_TYPE;\nvar ForwardRef = REACT_FORWARD_REF_TYPE;\nvar Fragment = REACT_FRAGMENT_TYPE;\nvar Lazy = REACT_LAZY_TYPE;\nvar Memo = REACT_MEMO_TYPE;\nvar Portal = REACT_PORTAL_TYPE;\nvar Profiler = REACT_PROFILER_TYPE;\nvar StrictMode = REACT_STRICT_MODE_TYPE;\nvar Suspense = REACT_SUSPENSE_TYPE;\nvar hasWarnedAboutDeprecatedIsAsyncMode = false; // AsyncMode should be deprecated\n\nfunction isAsyncMode(object) {\n {\n if (!hasWarnedAboutDeprecatedIsAsyncMode) {\n hasWarnedAboutDeprecatedIsAsyncMode = true; // Using console['warn'] to evade Babel and ESLint\n\n console['warn']('The ReactIs.isAsyncMode() alias has been deprecated, ' + 'and will be removed in React 17+. Update your code to use ' + 'ReactIs.isConcurrentMode() instead. It has the exact same API.');\n }\n }\n\n return isConcurrentMode(object) || typeOf(object) === REACT_ASYNC_MODE_TYPE;\n}\nfunction isConcurrentMode(object) {\n return typeOf(object) === REACT_CONCURRENT_MODE_TYPE;\n}\nfunction isContextConsumer(object) {\n return typeOf(object) === REACT_CONTEXT_TYPE;\n}\nfunction isContextProvider(object) {\n return typeOf(object) === REACT_PROVIDER_TYPE;\n}\nfunction isElement(object) {\n return typeof object === 'object' && object !== null && object.$$typeof === REACT_ELEMENT_TYPE;\n}\nfunction isForwardRef(object) {\n return typeOf(object) === REACT_FORWARD_REF_TYPE;\n}\nfunction isFragment(object) {\n return typeOf(object) === REACT_FRAGMENT_TYPE;\n}\nfunction isLazy(object) {\n return typeOf(object) === REACT_LAZY_TYPE;\n}\nfunction isMemo(object) {\n return typeOf(object) === REACT_MEMO_TYPE;\n}\nfunction isPortal(object) {\n return typeOf(object) === REACT_PORTAL_TYPE;\n}\nfunction isProfiler(object) {\n return typeOf(object) === REACT_PROFILER_TYPE;\n}\nfunction isStrictMode(object) {\n return typeOf(object) === REACT_STRICT_MODE_TYPE;\n}\nfunction isSuspense(object) {\n return typeOf(object) === REACT_SUSPENSE_TYPE;\n}\n\nexports.AsyncMode = AsyncMode;\nexports.ConcurrentMode = ConcurrentMode;\nexports.ContextConsumer = ContextConsumer;\nexports.ContextProvider = ContextProvider;\nexports.Element = Element;\nexports.ForwardRef = ForwardRef;\nexports.Fragment = Fragment;\nexports.Lazy = Lazy;\nexports.Memo = Memo;\nexports.Portal = Portal;\nexports.Profiler = Profiler;\nexports.StrictMode = StrictMode;\nexports.Suspense = Suspense;\nexports.isAsyncMode = isAsyncMode;\nexports.isConcurrentMode = isConcurrentMode;\nexports.isContextConsumer = isContextConsumer;\nexports.isContextProvider = isContextProvider;\nexports.isElement = isElement;\nexports.isForwardRef = isForwardRef;\nexports.isFragment = isFragment;\nexports.isLazy = isLazy;\nexports.isMemo = isMemo;\nexports.isPortal = isPortal;\nexports.isProfiler = isProfiler;\nexports.isStrictMode = isStrictMode;\nexports.isSuspense = isSuspense;\nexports.isValidElementType = isValidElementType;\nexports.typeOf = typeOf;\n })();\n}\n","'use strict';\n\nif (process.env.NODE_ENV === 'production') {\n module.exports = require('./cjs/react-is.production.min.js');\n} else {\n module.exports = require('./cjs/react-is.development.js');\n}\n","/*\nobject-assign\n(c) Sindre Sorhus\n@license MIT\n*/\n\n'use strict';\n/* eslint-disable no-unused-vars */\nvar getOwnPropertySymbols = Object.getOwnPropertySymbols;\nvar hasOwnProperty = Object.prototype.hasOwnProperty;\nvar propIsEnumerable = Object.prototype.propertyIsEnumerable;\n\nfunction toObject(val) {\n\tif (val === null || val === undefined) {\n\t\tthrow new TypeError('Object.assign cannot be called with null or undefined');\n\t}\n\n\treturn Object(val);\n}\n\nfunction shouldUseNative() {\n\ttry {\n\t\tif (!Object.assign) {\n\t\t\treturn false;\n\t\t}\n\n\t\t// Detect buggy property enumeration order in older V8 versions.\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=4118\n\t\tvar test1 = new String('abc'); // eslint-disable-line no-new-wrappers\n\t\ttest1[5] = 'de';\n\t\tif (Object.getOwnPropertyNames(test1)[0] === '5') {\n\t\t\treturn false;\n\t\t}\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=3056\n\t\tvar test2 = {};\n\t\tfor (var i = 0; i < 10; i++) {\n\t\t\ttest2['_' + String.fromCharCode(i)] = i;\n\t\t}\n\t\tvar order2 = Object.getOwnPropertyNames(test2).map(function (n) {\n\t\t\treturn test2[n];\n\t\t});\n\t\tif (order2.join('') !== '0123456789') {\n\t\t\treturn false;\n\t\t}\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=3056\n\t\tvar test3 = {};\n\t\t'abcdefghijklmnopqrst'.split('').forEach(function (letter) {\n\t\t\ttest3[letter] = letter;\n\t\t});\n\t\tif (Object.keys(Object.assign({}, test3)).join('') !==\n\t\t\t\t'abcdefghijklmnopqrst') {\n\t\t\treturn false;\n\t\t}\n\n\t\treturn true;\n\t} catch (err) {\n\t\t// We don't expect any of the above to throw, but better to be safe.\n\t\treturn false;\n\t}\n}\n\nmodule.exports = shouldUseNative() ? Object.assign : function (target, source) {\n\tvar from;\n\tvar to = toObject(target);\n\tvar symbols;\n\n\tfor (var s = 1; s < arguments.length; s++) {\n\t\tfrom = Object(arguments[s]);\n\n\t\tfor (var key in from) {\n\t\t\tif (hasOwnProperty.call(from, key)) {\n\t\t\t\tto[key] = from[key];\n\t\t\t}\n\t\t}\n\n\t\tif (getOwnPropertySymbols) {\n\t\t\tsymbols = getOwnPropertySymbols(from);\n\t\t\tfor (var i = 0; i < symbols.length; i++) {\n\t\t\t\tif (propIsEnumerable.call(from, symbols[i])) {\n\t\t\t\t\tto[symbols[i]] = from[symbols[i]];\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\n\treturn to;\n};\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar ReactPropTypesSecret = 'SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED';\n\nmodule.exports = ReactPropTypesSecret;\n","module.exports = Function.call.bind(Object.prototype.hasOwnProperty);\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar printWarning = function() {};\n\nif (process.env.NODE_ENV !== 'production') {\n var ReactPropTypesSecret = require('./lib/ReactPropTypesSecret');\n var loggedTypeFailures = {};\n var has = require('./lib/has');\n\n printWarning = function(text) {\n var message = 'Warning: ' + text;\n if (typeof console !== 'undefined') {\n console.error(message);\n }\n try {\n // --- Welcome to debugging React ---\n // This error was thrown as a convenience so that you can use this stack\n // to find the callsite that caused this warning to fire.\n throw new Error(message);\n } catch (x) { /**/ }\n };\n}\n\n/**\n * Assert that the values match with the type specs.\n * Error messages are memorized and will only be shown once.\n *\n * @param {object} typeSpecs Map of name to a ReactPropType\n * @param {object} values Runtime values that need to be type-checked\n * @param {string} location e.g. \"prop\", \"context\", \"child context\"\n * @param {string} componentName Name of the component for error messages.\n * @param {?Function} getStack Returns the component stack.\n * @private\n */\nfunction checkPropTypes(typeSpecs, values, location, componentName, getStack) {\n if (process.env.NODE_ENV !== 'production') {\n for (var typeSpecName in typeSpecs) {\n if (has(typeSpecs, typeSpecName)) {\n var error;\n // Prop type validation may throw. In case they do, we don't want to\n // fail the render phase where it didn't fail before. So we log it.\n // After these have been cleaned up, we'll let them throw.\n try {\n // This is intentionally an invariant that gets caught. It's the same\n // behavior as without this statement except with a better message.\n if (typeof typeSpecs[typeSpecName] !== 'function') {\n var err = Error(\n (componentName || 'React class') + ': ' + location + ' type `' + typeSpecName + '` is invalid; ' +\n 'it must be a function, usually from the `prop-types` package, but received `' + typeof typeSpecs[typeSpecName] + '`.' +\n 'This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.'\n );\n err.name = 'Invariant Violation';\n throw err;\n }\n error = typeSpecs[typeSpecName](values, typeSpecName, componentName, location, null, ReactPropTypesSecret);\n } catch (ex) {\n error = ex;\n }\n if (error && !(error instanceof Error)) {\n printWarning(\n (componentName || 'React class') + ': type specification of ' +\n location + ' `' + typeSpecName + '` is invalid; the type checker ' +\n 'function must return `null` or an `Error` but returned a ' + typeof error + '. ' +\n 'You may have forgotten to pass an argument to the type checker ' +\n 'creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and ' +\n 'shape all require an argument).'\n );\n }\n if (error instanceof Error && !(error.message in loggedTypeFailures)) {\n // Only monitor this failure once because there tends to be a lot of the\n // same error.\n loggedTypeFailures[error.message] = true;\n\n var stack = getStack ? getStack() : '';\n\n printWarning(\n 'Failed ' + location + ' type: ' + error.message + (stack != null ? stack : '')\n );\n }\n }\n }\n }\n}\n\n/**\n * Resets warning cache when testing.\n *\n * @private\n */\ncheckPropTypes.resetWarningCache = function() {\n if (process.env.NODE_ENV !== 'production') {\n loggedTypeFailures = {};\n }\n}\n\nmodule.exports = checkPropTypes;\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar ReactIs = require('react-is');\nvar assign = require('object-assign');\n\nvar ReactPropTypesSecret = require('./lib/ReactPropTypesSecret');\nvar has = require('./lib/has');\nvar checkPropTypes = require('./checkPropTypes');\n\nvar printWarning = function() {};\n\nif (process.env.NODE_ENV !== 'production') {\n printWarning = function(text) {\n var message = 'Warning: ' + text;\n if (typeof console !== 'undefined') {\n console.error(message);\n }\n try {\n // --- Welcome to debugging React ---\n // This error was thrown as a convenience so that you can use this stack\n // to find the callsite that caused this warning to fire.\n throw new Error(message);\n } catch (x) {}\n };\n}\n\nfunction emptyFunctionThatReturnsNull() {\n return null;\n}\n\nmodule.exports = function(isValidElement, throwOnDirectAccess) {\n /* global Symbol */\n var ITERATOR_SYMBOL = typeof Symbol === 'function' && Symbol.iterator;\n var FAUX_ITERATOR_SYMBOL = '@@iterator'; // Before Symbol spec.\n\n /**\n * Returns the iterator method function contained on the iterable object.\n *\n * Be sure to invoke the function with the iterable as context:\n *\n * var iteratorFn = getIteratorFn(myIterable);\n * if (iteratorFn) {\n * var iterator = iteratorFn.call(myIterable);\n * ...\n * }\n *\n * @param {?object} maybeIterable\n * @return {?function}\n */\n function getIteratorFn(maybeIterable) {\n var iteratorFn = maybeIterable && (ITERATOR_SYMBOL && maybeIterable[ITERATOR_SYMBOL] || maybeIterable[FAUX_ITERATOR_SYMBOL]);\n if (typeof iteratorFn === 'function') {\n return iteratorFn;\n }\n }\n\n /**\n * Collection of methods that allow declaration and validation of props that are\n * supplied to React components. Example usage:\n *\n * var Props = require('ReactPropTypes');\n * var MyArticle = React.createClass({\n * propTypes: {\n * // An optional string prop named \"description\".\n * description: Props.string,\n *\n * // A required enum prop named \"category\".\n * category: Props.oneOf(['News','Photos']).isRequired,\n *\n * // A prop named \"dialog\" that requires an instance of Dialog.\n * dialog: Props.instanceOf(Dialog).isRequired\n * },\n * render: function() { ... }\n * });\n *\n * A more formal specification of how these methods are used:\n *\n * type := array|bool|func|object|number|string|oneOf([...])|instanceOf(...)\n * decl := ReactPropTypes.{type}(.isRequired)?\n *\n * Each and every declaration produces a function with the same signature. This\n * allows the creation of custom validation functions. For example:\n *\n * var MyLink = React.createClass({\n * propTypes: {\n * // An optional string or URI prop named \"href\".\n * href: function(props, propName, componentName) {\n * var propValue = props[propName];\n * if (propValue != null && typeof propValue !== 'string' &&\n * !(propValue instanceof URI)) {\n * return new Error(\n * 'Expected a string or an URI for ' + propName + ' in ' +\n * componentName\n * );\n * }\n * }\n * },\n * render: function() {...}\n * });\n *\n * @internal\n */\n\n var ANONYMOUS = '<>';\n\n // Important!\n // Keep this list in sync with production version in `./factoryWithThrowingShims.js`.\n var ReactPropTypes = {\n array: createPrimitiveTypeChecker('array'),\n bigint: createPrimitiveTypeChecker('bigint'),\n bool: createPrimitiveTypeChecker('boolean'),\n func: createPrimitiveTypeChecker('function'),\n number: createPrimitiveTypeChecker('number'),\n object: createPrimitiveTypeChecker('object'),\n string: createPrimitiveTypeChecker('string'),\n symbol: createPrimitiveTypeChecker('symbol'),\n\n any: createAnyTypeChecker(),\n arrayOf: createArrayOfTypeChecker,\n element: createElementTypeChecker(),\n elementType: createElementTypeTypeChecker(),\n instanceOf: createInstanceTypeChecker,\n node: createNodeChecker(),\n objectOf: createObjectOfTypeChecker,\n oneOf: createEnumTypeChecker,\n oneOfType: createUnionTypeChecker,\n shape: createShapeTypeChecker,\n exact: createStrictShapeTypeChecker,\n };\n\n /**\n * inlined Object.is polyfill to avoid requiring consumers ship their own\n * https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object/is\n */\n /*eslint-disable no-self-compare*/\n function is(x, y) {\n // SameValue algorithm\n if (x === y) {\n // Steps 1-5, 7-10\n // Steps 6.b-6.e: +0 != -0\n return x !== 0 || 1 / x === 1 / y;\n } else {\n // Step 6.a: NaN == NaN\n return x !== x && y !== y;\n }\n }\n /*eslint-enable no-self-compare*/\n\n /**\n * We use an Error-like object for backward compatibility as people may call\n * PropTypes directly and inspect their output. However, we don't use real\n * Errors anymore. We don't inspect their stack anyway, and creating them\n * is prohibitively expensive if they are created too often, such as what\n * happens in oneOfType() for any type before the one that matched.\n */\n function PropTypeError(message, data) {\n this.message = message;\n this.data = data && typeof data === 'object' ? data: {};\n this.stack = '';\n }\n // Make `instanceof Error` still work for returned errors.\n PropTypeError.prototype = Error.prototype;\n\n function createChainableTypeChecker(validate) {\n if (process.env.NODE_ENV !== 'production') {\n var manualPropTypeCallCache = {};\n var manualPropTypeWarningCount = 0;\n }\n function checkType(isRequired, props, propName, componentName, location, propFullName, secret) {\n componentName = componentName || ANONYMOUS;\n propFullName = propFullName || propName;\n\n if (secret !== ReactPropTypesSecret) {\n if (throwOnDirectAccess) {\n // New behavior only for users of `prop-types` package\n var err = new Error(\n 'Calling PropTypes validators directly is not supported by the `prop-types` package. ' +\n 'Use `PropTypes.checkPropTypes()` to call them. ' +\n 'Read more at http://fb.me/use-check-prop-types'\n );\n err.name = 'Invariant Violation';\n throw err;\n } else if (process.env.NODE_ENV !== 'production' && typeof console !== 'undefined') {\n // Old behavior for people using React.PropTypes\n var cacheKey = componentName + ':' + propName;\n if (\n !manualPropTypeCallCache[cacheKey] &&\n // Avoid spamming the console because they are often not actionable except for lib authors\n manualPropTypeWarningCount < 3\n ) {\n printWarning(\n 'You are manually calling a React.PropTypes validation ' +\n 'function for the `' + propFullName + '` prop on `' + componentName + '`. This is deprecated ' +\n 'and will throw in the standalone `prop-types` package. ' +\n 'You may be seeing this warning due to a third-party PropTypes ' +\n 'library. See https://fb.me/react-warning-dont-call-proptypes ' + 'for details.'\n );\n manualPropTypeCallCache[cacheKey] = true;\n manualPropTypeWarningCount++;\n }\n }\n }\n if (props[propName] == null) {\n if (isRequired) {\n if (props[propName] === null) {\n return new PropTypeError('The ' + location + ' `' + propFullName + '` is marked as required ' + ('in `' + componentName + '`, but its value is `null`.'));\n }\n return new PropTypeError('The ' + location + ' `' + propFullName + '` is marked as required in ' + ('`' + componentName + '`, but its value is `undefined`.'));\n }\n return null;\n } else {\n return validate(props, propName, componentName, location, propFullName);\n }\n }\n\n var chainedCheckType = checkType.bind(null, false);\n chainedCheckType.isRequired = checkType.bind(null, true);\n\n return chainedCheckType;\n }\n\n function createPrimitiveTypeChecker(expectedType) {\n function validate(props, propName, componentName, location, propFullName, secret) {\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== expectedType) {\n // `propValue` being instance of, say, date/regexp, pass the 'object'\n // check, but we can offer a more precise error message here rather than\n // 'of type `object`'.\n var preciseType = getPreciseType(propValue);\n\n return new PropTypeError(\n 'Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + preciseType + '` supplied to `' + componentName + '`, expected ') + ('`' + expectedType + '`.'),\n {expectedType: expectedType}\n );\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createAnyTypeChecker() {\n return createChainableTypeChecker(emptyFunctionThatReturnsNull);\n }\n\n function createArrayOfTypeChecker(typeChecker) {\n function validate(props, propName, componentName, location, propFullName) {\n if (typeof typeChecker !== 'function') {\n return new PropTypeError('Property `' + propFullName + '` of component `' + componentName + '` has invalid PropType notation inside arrayOf.');\n }\n var propValue = props[propName];\n if (!Array.isArray(propValue)) {\n var propType = getPropType(propValue);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected an array.'));\n }\n for (var i = 0; i < propValue.length; i++) {\n var error = typeChecker(propValue, i, componentName, location, propFullName + '[' + i + ']', ReactPropTypesSecret);\n if (error instanceof Error) {\n return error;\n }\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createElementTypeChecker() {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n if (!isValidElement(propValue)) {\n var propType = getPropType(propValue);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected a single ReactElement.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createElementTypeTypeChecker() {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n if (!ReactIs.isValidElementType(propValue)) {\n var propType = getPropType(propValue);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected a single ReactElement type.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createInstanceTypeChecker(expectedClass) {\n function validate(props, propName, componentName, location, propFullName) {\n if (!(props[propName] instanceof expectedClass)) {\n var expectedClassName = expectedClass.name || ANONYMOUS;\n var actualClassName = getClassName(props[propName]);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + actualClassName + '` supplied to `' + componentName + '`, expected ') + ('instance of `' + expectedClassName + '`.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createEnumTypeChecker(expectedValues) {\n if (!Array.isArray(expectedValues)) {\n if (process.env.NODE_ENV !== 'production') {\n if (arguments.length > 1) {\n printWarning(\n 'Invalid arguments supplied to oneOf, expected an array, got ' + arguments.length + ' arguments. ' +\n 'A common mistake is to write oneOf(x, y, z) instead of oneOf([x, y, z]).'\n );\n } else {\n printWarning('Invalid argument supplied to oneOf, expected an array.');\n }\n }\n return emptyFunctionThatReturnsNull;\n }\n\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n for (var i = 0; i < expectedValues.length; i++) {\n if (is(propValue, expectedValues[i])) {\n return null;\n }\n }\n\n var valuesString = JSON.stringify(expectedValues, function replacer(key, value) {\n var type = getPreciseType(value);\n if (type === 'symbol') {\n return String(value);\n }\n return value;\n });\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of value `' + String(propValue) + '` ' + ('supplied to `' + componentName + '`, expected one of ' + valuesString + '.'));\n }\n return createChainableTypeChecker(validate);\n }\n\n function createObjectOfTypeChecker(typeChecker) {\n function validate(props, propName, componentName, location, propFullName) {\n if (typeof typeChecker !== 'function') {\n return new PropTypeError('Property `' + propFullName + '` of component `' + componentName + '` has invalid PropType notation inside objectOf.');\n }\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== 'object') {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected an object.'));\n }\n for (var key in propValue) {\n if (has(propValue, key)) {\n var error = typeChecker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret);\n if (error instanceof Error) {\n return error;\n }\n }\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createUnionTypeChecker(arrayOfTypeCheckers) {\n if (!Array.isArray(arrayOfTypeCheckers)) {\n process.env.NODE_ENV !== 'production' ? printWarning('Invalid argument supplied to oneOfType, expected an instance of array.') : void 0;\n return emptyFunctionThatReturnsNull;\n }\n\n for (var i = 0; i < arrayOfTypeCheckers.length; i++) {\n var checker = arrayOfTypeCheckers[i];\n if (typeof checker !== 'function') {\n printWarning(\n 'Invalid argument supplied to oneOfType. Expected an array of check functions, but ' +\n 'received ' + getPostfixForTypeWarning(checker) + ' at index ' + i + '.'\n );\n return emptyFunctionThatReturnsNull;\n }\n }\n\n function validate(props, propName, componentName, location, propFullName) {\n var expectedTypes = [];\n for (var i = 0; i < arrayOfTypeCheckers.length; i++) {\n var checker = arrayOfTypeCheckers[i];\n var checkerResult = checker(props, propName, componentName, location, propFullName, ReactPropTypesSecret);\n if (checkerResult == null) {\n return null;\n }\n if (checkerResult.data && has(checkerResult.data, 'expectedType')) {\n expectedTypes.push(checkerResult.data.expectedType);\n }\n }\n var expectedTypesMessage = (expectedTypes.length > 0) ? ', expected one of type [' + expectedTypes.join(', ') + ']': '';\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` supplied to ' + ('`' + componentName + '`' + expectedTypesMessage + '.'));\n }\n return createChainableTypeChecker(validate);\n }\n\n function createNodeChecker() {\n function validate(props, propName, componentName, location, propFullName) {\n if (!isNode(props[propName])) {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` supplied to ' + ('`' + componentName + '`, expected a ReactNode.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function invalidValidatorError(componentName, location, propFullName, key, type) {\n return new PropTypeError(\n (componentName || 'React class') + ': ' + location + ' type `' + propFullName + '.' + key + '` is invalid; ' +\n 'it must be a function, usually from the `prop-types` package, but received `' + type + '`.'\n );\n }\n\n function createShapeTypeChecker(shapeTypes) {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== 'object') {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type `' + propType + '` ' + ('supplied to `' + componentName + '`, expected `object`.'));\n }\n for (var key in shapeTypes) {\n var checker = shapeTypes[key];\n if (typeof checker !== 'function') {\n return invalidValidatorError(componentName, location, propFullName, key, getPreciseType(checker));\n }\n var error = checker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret);\n if (error) {\n return error;\n }\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createStrictShapeTypeChecker(shapeTypes) {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== 'object') {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type `' + propType + '` ' + ('supplied to `' + componentName + '`, expected `object`.'));\n }\n // We need to check all keys in case some are required but missing from props.\n var allKeys = assign({}, props[propName], shapeTypes);\n for (var key in allKeys) {\n var checker = shapeTypes[key];\n if (has(shapeTypes, key) && typeof checker !== 'function') {\n return invalidValidatorError(componentName, location, propFullName, key, getPreciseType(checker));\n }\n if (!checker) {\n return new PropTypeError(\n 'Invalid ' + location + ' `' + propFullName + '` key `' + key + '` supplied to `' + componentName + '`.' +\n '\\nBad object: ' + JSON.stringify(props[propName], null, ' ') +\n '\\nValid keys: ' + JSON.stringify(Object.keys(shapeTypes), null, ' ')\n );\n }\n var error = checker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret);\n if (error) {\n return error;\n }\n }\n return null;\n }\n\n return createChainableTypeChecker(validate);\n }\n\n function isNode(propValue) {\n switch (typeof propValue) {\n case 'number':\n case 'string':\n case 'undefined':\n return true;\n case 'boolean':\n return !propValue;\n case 'object':\n if (Array.isArray(propValue)) {\n return propValue.every(isNode);\n }\n if (propValue === null || isValidElement(propValue)) {\n return true;\n }\n\n var iteratorFn = getIteratorFn(propValue);\n if (iteratorFn) {\n var iterator = iteratorFn.call(propValue);\n var step;\n if (iteratorFn !== propValue.entries) {\n while (!(step = iterator.next()).done) {\n if (!isNode(step.value)) {\n return false;\n }\n }\n } else {\n // Iterator will provide entry [k,v] tuples rather than values.\n while (!(step = iterator.next()).done) {\n var entry = step.value;\n if (entry) {\n if (!isNode(entry[1])) {\n return false;\n }\n }\n }\n }\n } else {\n return false;\n }\n\n return true;\n default:\n return false;\n }\n }\n\n function isSymbol(propType, propValue) {\n // Native Symbol.\n if (propType === 'symbol') {\n return true;\n }\n\n // falsy value can't be a Symbol\n if (!propValue) {\n return false;\n }\n\n // 19.4.3.5 Symbol.prototype[@@toStringTag] === 'Symbol'\n if (propValue['@@toStringTag'] === 'Symbol') {\n return true;\n }\n\n // Fallback for non-spec compliant Symbols which are polyfilled.\n if (typeof Symbol === 'function' && propValue instanceof Symbol) {\n return true;\n }\n\n return false;\n }\n\n // Equivalent of `typeof` but with special handling for array and regexp.\n function getPropType(propValue) {\n var propType = typeof propValue;\n if (Array.isArray(propValue)) {\n return 'array';\n }\n if (propValue instanceof RegExp) {\n // Old webkits (at least until Android 4.0) return 'function' rather than\n // 'object' for typeof a RegExp. We'll normalize this here so that /bla/\n // passes PropTypes.object.\n return 'object';\n }\n if (isSymbol(propType, propValue)) {\n return 'symbol';\n }\n return propType;\n }\n\n // This handles more types than `getPropType`. Only used for error messages.\n // See `createPrimitiveTypeChecker`.\n function getPreciseType(propValue) {\n if (typeof propValue === 'undefined' || propValue === null) {\n return '' + propValue;\n }\n var propType = getPropType(propValue);\n if (propType === 'object') {\n if (propValue instanceof Date) {\n return 'date';\n } else if (propValue instanceof RegExp) {\n return 'regexp';\n }\n }\n return propType;\n }\n\n // Returns a string that is postfixed to a warning about an invalid type.\n // For example, \"undefined\" or \"of type array\"\n function getPostfixForTypeWarning(value) {\n var type = getPreciseType(value);\n switch (type) {\n case 'array':\n case 'object':\n return 'an ' + type;\n case 'boolean':\n case 'date':\n case 'regexp':\n return 'a ' + type;\n default:\n return type;\n }\n }\n\n // Returns class name of the object, if any.\n function getClassName(propValue) {\n if (!propValue.constructor || !propValue.constructor.name) {\n return ANONYMOUS;\n }\n return propValue.constructor.name;\n }\n\n ReactPropTypes.checkPropTypes = checkPropTypes;\n ReactPropTypes.resetWarningCache = checkPropTypes.resetWarningCache;\n ReactPropTypes.PropTypes = ReactPropTypes;\n\n return ReactPropTypes;\n};\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar ReactPropTypesSecret = require('./lib/ReactPropTypesSecret');\n\nfunction emptyFunction() {}\nfunction emptyFunctionWithReset() {}\nemptyFunctionWithReset.resetWarningCache = emptyFunction;\n\nmodule.exports = function() {\n function shim(props, propName, componentName, location, propFullName, secret) {\n if (secret === ReactPropTypesSecret) {\n // It is still safe when called from React.\n return;\n }\n var err = new Error(\n 'Calling PropTypes validators directly is not supported by the `prop-types` package. ' +\n 'Use PropTypes.checkPropTypes() to call them. ' +\n 'Read more at http://fb.me/use-check-prop-types'\n );\n err.name = 'Invariant Violation';\n throw err;\n };\n shim.isRequired = shim;\n function getShim() {\n return shim;\n };\n // Important!\n // Keep this list in sync with production version in `./factoryWithTypeCheckers.js`.\n var ReactPropTypes = {\n array: shim,\n bigint: shim,\n bool: shim,\n func: shim,\n number: shim,\n object: shim,\n string: shim,\n symbol: shim,\n\n any: shim,\n arrayOf: getShim,\n element: shim,\n elementType: shim,\n instanceOf: getShim,\n node: shim,\n objectOf: getShim,\n oneOf: getShim,\n oneOfType: getShim,\n shape: getShim,\n exact: getShim,\n\n checkPropTypes: emptyFunctionWithReset,\n resetWarningCache: emptyFunction\n };\n\n ReactPropTypes.PropTypes = ReactPropTypes;\n\n return ReactPropTypes;\n};\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\nif (process.env.NODE_ENV !== 'production') {\n var ReactIs = require('react-is');\n\n // By explicitly using `prop-types` you are opting into new development behavior.\n // http://fb.me/prop-types-in-prod\n var throwOnDirectAccess = true;\n module.exports = require('./factoryWithTypeCheckers')(ReactIs.isElement, throwOnDirectAccess);\n} else {\n // By explicitly using `prop-types` you are opting into new production behavior.\n // http://fb.me/prop-types-in-prod\n module.exports = require('./factoryWithThrowingShims')();\n}\n","import PropTypes from 'prop-types';\nimport chainPropTypes from '../chainPropTypes';\nfunction isClassComponent(elementType) {\n // elementType.prototype?.isReactComponent\n const {\n prototype = {}\n } = elementType;\n return Boolean(prototype.isReactComponent);\n}\nfunction acceptingRef(props, propName, componentName, location, propFullName) {\n const element = props[propName];\n const safePropName = propFullName || propName;\n if (element == null ||\n // When server-side rendering React doesn't warn either.\n // This is not an accurate check for SSR.\n // This is only in place for Emotion compat.\n // TODO: Revisit once https://github.com/facebook/react/issues/20047 is resolved.\n typeof window === 'undefined') {\n return null;\n }\n let warningHint;\n const elementType = element.type;\n /**\n * Blacklisting instead of whitelisting\n *\n * Blacklisting will miss some components, such as React.Fragment. Those will at least\n * trigger a warning in React.\n * We can't whitelist because there is no safe way to detect React.forwardRef\n * or class components. \"Safe\" means there's no public API.\n *\n */\n if (typeof elementType === 'function' && !isClassComponent(elementType)) {\n warningHint = 'Did you accidentally use a plain function component for an element instead?';\n }\n if (warningHint !== undefined) {\n return new Error(`Invalid ${location} \\`${safePropName}\\` supplied to \\`${componentName}\\`. ` + `Expected an element that can hold a ref. ${warningHint} ` + 'For more information see https://mui.com/r/caveat-with-refs-guide');\n }\n return null;\n}\nconst elementAcceptingRef = chainPropTypes(PropTypes.element, acceptingRef);\nelementAcceptingRef.isRequired = chainPropTypes(PropTypes.element.isRequired, acceptingRef);\nexport default elementAcceptingRef;","import _extends from \"@babel/runtime/helpers/esm/extends\";\n// This module is based on https://github.com/airbnb/prop-types-exact repository.\n// However, in order to reduce the number of dependencies and to remove some extra safe checks\n// the module was forked.\n\nconst specialProperty = 'exact-prop: \\u200b';\nexport default function exactProp(propTypes) {\n if (process.env.NODE_ENV === 'production') {\n return propTypes;\n }\n return _extends({}, propTypes, {\n [specialProperty]: props => {\n const unsupportedProps = Object.keys(props).filter(prop => !propTypes.hasOwnProperty(prop));\n if (unsupportedProps.length > 0) {\n return new Error(`The following props are not supported: ${unsupportedProps.map(prop => `\\`${prop}\\``).join(', ')}. Please remove them.`);\n }\n return null;\n }\n });\n}","/**\n * WARNING: Don't import this directly.\n * Use `MuiError` from `@mui/internal-babel-macros/MuiError.macro` instead.\n * @param {number} code\n */\nexport default function formatMuiErrorMessage(code) {\n // Apply babel-plugin-transform-template-literals in loose mode\n // loose mode is safe if we're concatenating primitives\n // see https://babeljs.io/docs/en/babel-plugin-transform-template-literals#loose\n /* eslint-disable prefer-template */\n let url = 'https://mui.com/production-error/?code=' + code;\n for (let i = 1; i < arguments.length; i += 1) {\n // rest params over-transpile for this case\n // eslint-disable-next-line prefer-rest-params\n url += '&args[]=' + encodeURIComponent(arguments[i]);\n }\n return 'Minified MUI error #' + code + '; visit ' + url + ' for the full message.';\n /* eslint-enable prefer-template */\n}","/**\n * @license React\n * react-is.production.min.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n'use strict';var b=Symbol.for(\"react.element\"),c=Symbol.for(\"react.portal\"),d=Symbol.for(\"react.fragment\"),e=Symbol.for(\"react.strict_mode\"),f=Symbol.for(\"react.profiler\"),g=Symbol.for(\"react.provider\"),h=Symbol.for(\"react.context\"),k=Symbol.for(\"react.server_context\"),l=Symbol.for(\"react.forward_ref\"),m=Symbol.for(\"react.suspense\"),n=Symbol.for(\"react.suspense_list\"),p=Symbol.for(\"react.memo\"),q=Symbol.for(\"react.lazy\"),t=Symbol.for(\"react.offscreen\"),u;u=Symbol.for(\"react.module.reference\");\nfunction v(a){if(\"object\"===typeof a&&null!==a){var r=a.$$typeof;switch(r){case b:switch(a=a.type,a){case d:case f:case e:case m:case n:return a;default:switch(a=a&&a.$$typeof,a){case k:case h:case l:case q:case p:case g:return a;default:return r}}case c:return r}}}exports.ContextConsumer=h;exports.ContextProvider=g;exports.Element=b;exports.ForwardRef=l;exports.Fragment=d;exports.Lazy=q;exports.Memo=p;exports.Portal=c;exports.Profiler=f;exports.StrictMode=e;exports.Suspense=m;\nexports.SuspenseList=n;exports.isAsyncMode=function(){return!1};exports.isConcurrentMode=function(){return!1};exports.isContextConsumer=function(a){return v(a)===h};exports.isContextProvider=function(a){return v(a)===g};exports.isElement=function(a){return\"object\"===typeof a&&null!==a&&a.$$typeof===b};exports.isForwardRef=function(a){return v(a)===l};exports.isFragment=function(a){return v(a)===d};exports.isLazy=function(a){return v(a)===q};exports.isMemo=function(a){return v(a)===p};\nexports.isPortal=function(a){return v(a)===c};exports.isProfiler=function(a){return v(a)===f};exports.isStrictMode=function(a){return v(a)===e};exports.isSuspense=function(a){return v(a)===m};exports.isSuspenseList=function(a){return v(a)===n};\nexports.isValidElementType=function(a){return\"string\"===typeof a||\"function\"===typeof a||a===d||a===f||a===e||a===m||a===n||a===t||\"object\"===typeof a&&null!==a&&(a.$$typeof===q||a.$$typeof===p||a.$$typeof===g||a.$$typeof===h||a.$$typeof===l||a.$$typeof===u||void 0!==a.getModuleId)?!0:!1};exports.typeOf=v;\n","/**\n * @license React\n * react-is.development.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nif (process.env.NODE_ENV !== \"production\") {\n (function() {\n'use strict';\n\n// ATTENTION\n// When adding new symbols to this file,\n// Please consider also adding to 'react-devtools-shared/src/backend/ReactSymbols'\n// The Symbol used to tag the ReactElement-like types.\nvar REACT_ELEMENT_TYPE = Symbol.for('react.element');\nvar REACT_PORTAL_TYPE = Symbol.for('react.portal');\nvar REACT_FRAGMENT_TYPE = Symbol.for('react.fragment');\nvar REACT_STRICT_MODE_TYPE = Symbol.for('react.strict_mode');\nvar REACT_PROFILER_TYPE = Symbol.for('react.profiler');\nvar REACT_PROVIDER_TYPE = Symbol.for('react.provider');\nvar REACT_CONTEXT_TYPE = Symbol.for('react.context');\nvar REACT_SERVER_CONTEXT_TYPE = Symbol.for('react.server_context');\nvar REACT_FORWARD_REF_TYPE = Symbol.for('react.forward_ref');\nvar REACT_SUSPENSE_TYPE = Symbol.for('react.suspense');\nvar REACT_SUSPENSE_LIST_TYPE = Symbol.for('react.suspense_list');\nvar REACT_MEMO_TYPE = Symbol.for('react.memo');\nvar REACT_LAZY_TYPE = Symbol.for('react.lazy');\nvar REACT_OFFSCREEN_TYPE = Symbol.for('react.offscreen');\n\n// -----------------------------------------------------------------------------\n\nvar enableScopeAPI = false; // Experimental Create Event Handle API.\nvar enableCacheElement = false;\nvar enableTransitionTracing = false; // No known bugs, but needs performance testing\n\nvar enableLegacyHidden = false; // Enables unstable_avoidThisFallback feature in Fiber\n// stuff. Intended to enable React core members to more easily debug scheduling\n// issues in DEV builds.\n\nvar enableDebugTracing = false; // Track which Fiber(s) schedule render work.\n\nvar REACT_MODULE_REFERENCE;\n\n{\n REACT_MODULE_REFERENCE = Symbol.for('react.module.reference');\n}\n\nfunction isValidElementType(type) {\n if (typeof type === 'string' || typeof type === 'function') {\n return true;\n } // Note: typeof might be other than 'symbol' or 'number' (e.g. if it's a polyfill).\n\n\n if (type === REACT_FRAGMENT_TYPE || type === REACT_PROFILER_TYPE || enableDebugTracing || type === REACT_STRICT_MODE_TYPE || type === REACT_SUSPENSE_TYPE || type === REACT_SUSPENSE_LIST_TYPE || enableLegacyHidden || type === REACT_OFFSCREEN_TYPE || enableScopeAPI || enableCacheElement || enableTransitionTracing ) {\n return true;\n }\n\n if (typeof type === 'object' && type !== null) {\n if (type.$$typeof === REACT_LAZY_TYPE || type.$$typeof === REACT_MEMO_TYPE || type.$$typeof === REACT_PROVIDER_TYPE || type.$$typeof === REACT_CONTEXT_TYPE || type.$$typeof === REACT_FORWARD_REF_TYPE || // This needs to include all possible module reference object\n // types supported by any Flight configuration anywhere since\n // we don't know which Flight build this will end up being used\n // with.\n type.$$typeof === REACT_MODULE_REFERENCE || type.getModuleId !== undefined) {\n return true;\n }\n }\n\n return false;\n}\n\nfunction typeOf(object) {\n if (typeof object === 'object' && object !== null) {\n var $$typeof = object.$$typeof;\n\n switch ($$typeof) {\n case REACT_ELEMENT_TYPE:\n var type = object.type;\n\n switch (type) {\n case REACT_FRAGMENT_TYPE:\n case REACT_PROFILER_TYPE:\n case REACT_STRICT_MODE_TYPE:\n case REACT_SUSPENSE_TYPE:\n case REACT_SUSPENSE_LIST_TYPE:\n return type;\n\n default:\n var $$typeofType = type && type.$$typeof;\n\n switch ($$typeofType) {\n case REACT_SERVER_CONTEXT_TYPE:\n case REACT_CONTEXT_TYPE:\n case REACT_FORWARD_REF_TYPE:\n case REACT_LAZY_TYPE:\n case REACT_MEMO_TYPE:\n case REACT_PROVIDER_TYPE:\n return $$typeofType;\n\n default:\n return $$typeof;\n }\n\n }\n\n case REACT_PORTAL_TYPE:\n return $$typeof;\n }\n }\n\n return undefined;\n}\nvar ContextConsumer = REACT_CONTEXT_TYPE;\nvar ContextProvider = REACT_PROVIDER_TYPE;\nvar Element = REACT_ELEMENT_TYPE;\nvar ForwardRef = REACT_FORWARD_REF_TYPE;\nvar Fragment = REACT_FRAGMENT_TYPE;\nvar Lazy = REACT_LAZY_TYPE;\nvar Memo = REACT_MEMO_TYPE;\nvar Portal = REACT_PORTAL_TYPE;\nvar Profiler = REACT_PROFILER_TYPE;\nvar StrictMode = REACT_STRICT_MODE_TYPE;\nvar Suspense = REACT_SUSPENSE_TYPE;\nvar SuspenseList = REACT_SUSPENSE_LIST_TYPE;\nvar hasWarnedAboutDeprecatedIsAsyncMode = false;\nvar hasWarnedAboutDeprecatedIsConcurrentMode = false; // AsyncMode should be deprecated\n\nfunction isAsyncMode(object) {\n {\n if (!hasWarnedAboutDeprecatedIsAsyncMode) {\n hasWarnedAboutDeprecatedIsAsyncMode = true; // Using console['warn'] to evade Babel and ESLint\n\n console['warn']('The ReactIs.isAsyncMode() alias has been deprecated, ' + 'and will be removed in React 18+.');\n }\n }\n\n return false;\n}\nfunction isConcurrentMode(object) {\n {\n if (!hasWarnedAboutDeprecatedIsConcurrentMode) {\n hasWarnedAboutDeprecatedIsConcurrentMode = true; // Using console['warn'] to evade Babel and ESLint\n\n console['warn']('The ReactIs.isConcurrentMode() alias has been deprecated, ' + 'and will be removed in React 18+.');\n }\n }\n\n return false;\n}\nfunction isContextConsumer(object) {\n return typeOf(object) === REACT_CONTEXT_TYPE;\n}\nfunction isContextProvider(object) {\n return typeOf(object) === REACT_PROVIDER_TYPE;\n}\nfunction isElement(object) {\n return typeof object === 'object' && object !== null && object.$$typeof === REACT_ELEMENT_TYPE;\n}\nfunction isForwardRef(object) {\n return typeOf(object) === REACT_FORWARD_REF_TYPE;\n}\nfunction isFragment(object) {\n return typeOf(object) === REACT_FRAGMENT_TYPE;\n}\nfunction isLazy(object) {\n return typeOf(object) === REACT_LAZY_TYPE;\n}\nfunction isMemo(object) {\n return typeOf(object) === REACT_MEMO_TYPE;\n}\nfunction isPortal(object) {\n return typeOf(object) === REACT_PORTAL_TYPE;\n}\nfunction isProfiler(object) {\n return typeOf(object) === REACT_PROFILER_TYPE;\n}\nfunction isStrictMode(object) {\n return typeOf(object) === REACT_STRICT_MODE_TYPE;\n}\nfunction isSuspense(object) {\n return typeOf(object) === REACT_SUSPENSE_TYPE;\n}\nfunction isSuspenseList(object) {\n return typeOf(object) === REACT_SUSPENSE_LIST_TYPE;\n}\n\nexports.ContextConsumer = ContextConsumer;\nexports.ContextProvider = ContextProvider;\nexports.Element = Element;\nexports.ForwardRef = ForwardRef;\nexports.Fragment = Fragment;\nexports.Lazy = Lazy;\nexports.Memo = Memo;\nexports.Portal = Portal;\nexports.Profiler = Profiler;\nexports.StrictMode = StrictMode;\nexports.Suspense = Suspense;\nexports.SuspenseList = SuspenseList;\nexports.isAsyncMode = isAsyncMode;\nexports.isConcurrentMode = isConcurrentMode;\nexports.isContextConsumer = isContextConsumer;\nexports.isContextProvider = isContextProvider;\nexports.isElement = isElement;\nexports.isForwardRef = isForwardRef;\nexports.isFragment = isFragment;\nexports.isLazy = isLazy;\nexports.isMemo = isMemo;\nexports.isPortal = isPortal;\nexports.isProfiler = isProfiler;\nexports.isStrictMode = isStrictMode;\nexports.isSuspense = isSuspense;\nexports.isSuspenseList = isSuspenseList;\nexports.isValidElementType = isValidElementType;\nexports.typeOf = typeOf;\n })();\n}\n","'use strict';\n\nif (process.env.NODE_ENV === 'production') {\n module.exports = require('./cjs/react-is.production.min.js');\n} else {\n module.exports = require('./cjs/react-is.development.js');\n}\n","import { ForwardRef, Memo } from 'react-is';\n\n// Simplified polyfill for IE11 support\n// https://github.com/JamesMGreene/Function.name/blob/58b314d4a983110c3682f1228f845d39ccca1817/Function.name.js#L3\nconst fnNameMatchRegex = /^\\s*function(?:\\s|\\s*\\/\\*.*\\*\\/\\s*)+([^(\\s/]*)\\s*/;\nexport function getFunctionName(fn) {\n const match = `${fn}`.match(fnNameMatchRegex);\n const name = match && match[1];\n return name || '';\n}\nfunction getFunctionComponentName(Component, fallback = '') {\n return Component.displayName || Component.name || getFunctionName(Component) || fallback;\n}\nfunction getWrappedName(outerType, innerType, wrapperName) {\n const functionName = getFunctionComponentName(innerType);\n return outerType.displayName || (functionName !== '' ? `${wrapperName}(${functionName})` : wrapperName);\n}\n\n/**\n * cherry-pick from\n * https://github.com/facebook/react/blob/769b1f270e1251d9dbdce0fcbd9e92e502d059b8/packages/shared/getComponentName.js\n * originally forked from recompose/getDisplayName with added IE11 support\n */\nexport default function getDisplayName(Component) {\n if (Component == null) {\n return undefined;\n }\n if (typeof Component === 'string') {\n return Component;\n }\n if (typeof Component === 'function') {\n return getFunctionComponentName(Component, 'Component');\n }\n\n // TypeScript can't have components as objects but they exist in the form of `memo` or `Suspense`\n if (typeof Component === 'object') {\n switch (Component.$$typeof) {\n case ForwardRef:\n return getWrappedName(Component, Component.render, 'ForwardRef');\n case Memo:\n return getWrappedName(Component, Component.type, 'memo');\n default:\n return undefined;\n }\n }\n return undefined;\n}","export default function HTMLElementType(props, propName, componentName, location, propFullName) {\n if (process.env.NODE_ENV === 'production') {\n return null;\n }\n const propValue = props[propName];\n const safePropName = propFullName || propName;\n if (propValue == null) {\n return null;\n }\n if (propValue && propValue.nodeType !== 1) {\n return new Error(`Invalid ${location} \\`${safePropName}\\` supplied to \\`${componentName}\\`. ` + `Expected an HTMLElement.`);\n }\n return null;\n}","import PropTypes from 'prop-types';\nconst refType = PropTypes.oneOfType([PropTypes.func, PropTypes.object]);\nexport default refType;","import _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\n// It should to be noted that this function isn't equivalent to `text-transform: capitalize`.\n//\n// A strict capitalization should uppercase the first letter of each word in the sentence.\n// We only handle the first word.\nexport default function capitalize(string) {\n if (typeof string !== 'string') {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: \\`capitalize(string)\\` expects a string argument.` : _formatMuiErrorMessage(7));\n }\n return string.charAt(0).toUpperCase() + string.slice(1);\n}","/**\n * Safe chained function.\n *\n * Will only create a new function if needed,\n * otherwise will pass back existing functions or null.\n */\nexport default function createChainedFunction(...funcs) {\n return funcs.reduce((acc, func) => {\n if (func == null) {\n return acc;\n }\n return function chainedFunction(...args) {\n acc.apply(this, args);\n func.apply(this, args);\n };\n }, () => {});\n}","// Corresponds to 10 frames at 60 Hz.\n// A few bytes payload overhead when lodash/debounce is ~3 kB and debounce ~300 B.\nexport default function debounce(func, wait = 166) {\n let timeout;\n function debounced(...args) {\n const later = () => {\n // @ts-ignore\n func.apply(this, args);\n };\n clearTimeout(timeout);\n timeout = setTimeout(later, wait);\n }\n debounced.clear = () => {\n clearTimeout(timeout);\n };\n return debounced;\n}","export default function deprecatedPropType(validator, reason) {\n if (process.env.NODE_ENV === 'production') {\n return () => null;\n }\n return (props, propName, componentName, location, propFullName) => {\n const componentNameSafe = componentName || '<>';\n const propFullNameSafe = propFullName || propName;\n if (typeof props[propName] !== 'undefined') {\n return new Error(`The ${location} \\`${propFullNameSafe}\\` of ` + `\\`${componentNameSafe}\\` is deprecated. ${reason}`);\n }\n return null;\n };\n}","import * as React from 'react';\nexport default function isMuiElement(element, muiNames) {\n var _muiName, _element$type;\n return /*#__PURE__*/React.isValidElement(element) && muiNames.indexOf( // For server components `muiName` is avaialble in element.type._payload.value.muiName\n // relevant info - https://github.com/facebook/react/blob/2807d781a08db8e9873687fccc25c0f12b4fb3d4/packages/react/src/ReactLazy.js#L45\n // eslint-disable-next-line no-underscore-dangle\n (_muiName = element.type.muiName) != null ? _muiName : (_element$type = element.type) == null || (_element$type = _element$type._payload) == null || (_element$type = _element$type.value) == null ? void 0 : _element$type.muiName) !== -1;\n}","export default function ownerDocument(node) {\n return node && node.ownerDocument || document;\n}","import ownerDocument from '../ownerDocument';\nexport default function ownerWindow(node) {\n const doc = ownerDocument(node);\n return doc.defaultView || window;\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nexport default function requirePropFactory(componentNameInError, Component) {\n if (process.env.NODE_ENV === 'production') {\n return () => null;\n }\n\n // eslint-disable-next-line react/forbid-foreign-prop-types\n const prevPropTypes = Component ? _extends({}, Component.propTypes) : null;\n const requireProp = requiredProp => (props, propName, componentName, location, propFullName, ...args) => {\n const propFullNameSafe = propFullName || propName;\n const defaultTypeChecker = prevPropTypes == null ? void 0 : prevPropTypes[propFullNameSafe];\n if (defaultTypeChecker) {\n const typeCheckerResult = defaultTypeChecker(props, propName, componentName, location, propFullName, ...args);\n if (typeCheckerResult) {\n return typeCheckerResult;\n }\n }\n if (typeof props[propName] !== 'undefined' && !props[requiredProp]) {\n return new Error(`The prop \\`${propFullNameSafe}\\` of ` + `\\`${componentNameInError}\\` can only be used together with the \\`${requiredProp}\\` prop.`);\n }\n return null;\n };\n return requireProp;\n}","/**\n * TODO v5: consider making it private\n *\n * passes {value} to {ref}\n *\n * WARNING: Be sure to only call this inside a callback that is passed as a ref.\n * Otherwise, make sure to cleanup the previous {ref} if it changes. See\n * https://github.com/mui/material-ui/issues/13539\n *\n * Useful if you want to expose the ref of an inner component to the public API\n * while still using it inside the component.\n * @param ref A ref callback or ref object. If anything falsy, this is a no-op.\n */\nexport default function setRef(ref, value) {\n if (typeof ref === 'function') {\n ref(value);\n } else if (ref) {\n ref.current = value;\n }\n}","'use client';\n\nimport * as React from 'react';\n\n/**\n * A version of `React.useLayoutEffect` that does not show a warning when server-side rendering.\n * This is useful for effects that are only needed for client-side rendering but not for SSR.\n *\n * Before you use this hook, make sure to read https://gist.github.com/gaearon/e7d97cdf38a2907924ea12e4ebdf3c85\n * and confirm it doesn't apply to your use-case.\n */\nconst useEnhancedEffect = typeof window !== 'undefined' ? React.useLayoutEffect : React.useEffect;\nexport default useEnhancedEffect;","'use client';\n\nimport * as React from 'react';\nlet globalId = 0;\nfunction useGlobalId(idOverride) {\n const [defaultId, setDefaultId] = React.useState(idOverride);\n const id = idOverride || defaultId;\n React.useEffect(() => {\n if (defaultId == null) {\n // Fallback to this default id when possible.\n // Use the incrementing value for client-side rendering only.\n // We can't use it server-side.\n // If you want to use random values please consider the Birthday Problem: https://en.wikipedia.org/wiki/Birthday_problem\n globalId += 1;\n setDefaultId(`mui-${globalId}`);\n }\n }, [defaultId]);\n return id;\n}\n\n// downstream bundlers may remove unnecessary concatenation, but won't remove toString call -- Workaround for https://github.com/webpack/webpack/issues/14814\nconst maybeReactUseId = React['useId'.toString()];\n/**\n *\n * @example
    \n * @param idOverride\n * @returns {string}\n */\nexport default function useId(idOverride) {\n if (maybeReactUseId !== undefined) {\n const reactId = maybeReactUseId();\n return idOverride != null ? idOverride : reactId;\n }\n // eslint-disable-next-line react-hooks/rules-of-hooks -- `React.useId` is invariant at runtime.\n return useGlobalId(idOverride);\n}","export default function unsupportedProp(props, propName, componentName, location, propFullName) {\n if (process.env.NODE_ENV === 'production') {\n return null;\n }\n const propFullNameSafe = propFullName || propName;\n if (typeof props[propName] !== 'undefined') {\n return new Error(`The prop \\`${propFullNameSafe}\\` is not supported. Please remove it.`);\n }\n return null;\n}","'use client';\n\n/* eslint-disable react-hooks/rules-of-hooks, react-hooks/exhaustive-deps */\nimport * as React from 'react';\nexport default function useControlled({\n controlled,\n default: defaultProp,\n name,\n state = 'value'\n}) {\n // isControlled is ignored in the hook dependency lists as it should never change.\n const {\n current: isControlled\n } = React.useRef(controlled !== undefined);\n const [valueState, setValue] = React.useState(defaultProp);\n const value = isControlled ? controlled : valueState;\n if (process.env.NODE_ENV !== 'production') {\n React.useEffect(() => {\n if (isControlled !== (controlled !== undefined)) {\n console.error([`MUI: A component is changing the ${isControlled ? '' : 'un'}controlled ${state} state of ${name} to be ${isControlled ? 'un' : ''}controlled.`, 'Elements should not switch from uncontrolled to controlled (or vice versa).', `Decide between using a controlled or uncontrolled ${name} ` + 'element for the lifetime of the component.', \"The nature of the state is determined during the first render. It's considered controlled if the value is not `undefined`.\", 'More info: https://fb.me/react-controlled-components'].join('\\n'));\n }\n }, [state, name, controlled]);\n const {\n current: defaultValue\n } = React.useRef(defaultProp);\n React.useEffect(() => {\n if (!isControlled && defaultValue !== defaultProp) {\n console.error([`MUI: A component is changing the default ${state} state of an uncontrolled ${name} after being initialized. ` + `To suppress this warning opt to use a controlled ${name}.`].join('\\n'));\n }\n }, [JSON.stringify(defaultProp)]);\n }\n const setValueIfUncontrolled = React.useCallback(newValue => {\n if (!isControlled) {\n setValue(newValue);\n }\n }, []);\n return [value, setValueIfUncontrolled];\n}","'use client';\n\nimport * as React from 'react';\nimport useEnhancedEffect from '../useEnhancedEffect';\n\n/**\n * Inspired by https://github.com/facebook/react/issues/14099#issuecomment-440013892\n * See RFC in https://github.com/reactjs/rfcs/pull/220\n */\n\nfunction useEventCallback(fn) {\n const ref = React.useRef(fn);\n useEnhancedEffect(() => {\n ref.current = fn;\n });\n return React.useRef((...args) =>\n // @ts-expect-error hide `this`\n (0, ref.current)(...args)).current;\n}\nexport default useEventCallback;","'use client';\n\nimport * as React from 'react';\nimport setRef from '../setRef';\nexport default function useForkRef(...refs) {\n /**\n * This will create a new function if the refs passed to this hook change and are all defined.\n * This means react will call the old forkRef with `null` and the new forkRef\n * with the ref. Cleanup naturally emerges from this behavior.\n */\n return React.useMemo(() => {\n if (refs.every(ref => ref == null)) {\n return null;\n }\n return instance => {\n refs.forEach(ref => {\n setRef(ref, instance);\n });\n };\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, refs);\n}","'use client';\n\nimport * as React from 'react';\nconst UNINITIALIZED = {};\n\n/**\n * A React.useRef() that is initialized lazily with a function. Note that it accepts an optional\n * initialization argument, so the initialization function doesn't need to be an inline closure.\n *\n * @usage\n * const ref = useLazyRef(sortColumns, columns)\n */\nexport default function useLazyRef(init, initArg) {\n const ref = React.useRef(UNINITIALIZED);\n if (ref.current === UNINITIALIZED) {\n ref.current = init(initArg);\n }\n return ref;\n}","'use client';\n\nimport * as React from 'react';\nconst EMPTY = [];\n\n/**\n * A React.useEffect equivalent that runs once, when the component is mounted.\n */\nexport default function useOnMount(fn) {\n /* eslint-disable react-hooks/exhaustive-deps */\n React.useEffect(fn, EMPTY);\n /* eslint-enable react-hooks/exhaustive-deps */\n}","'use client';\n\nimport useLazyRef from '../useLazyRef/useLazyRef';\nimport useOnMount from '../useOnMount/useOnMount';\nexport class Timeout {\n constructor() {\n this.currentId = null;\n this.clear = () => {\n if (this.currentId !== null) {\n clearTimeout(this.currentId);\n this.currentId = null;\n }\n };\n this.disposeEffect = () => {\n return this.clear;\n };\n }\n static create() {\n return new Timeout();\n }\n /**\n * Executes `fn` after `delay`, clearing any previously scheduled call.\n */\n start(delay, fn) {\n this.clear();\n this.currentId = setTimeout(() => {\n this.currentId = null;\n fn();\n }, delay);\n }\n}\nexport default function useTimeout() {\n const timeout = useLazyRef(Timeout.create).current;\n useOnMount(timeout.disposeEffect);\n return timeout;\n}","'use client';\n\n// based on https://github.com/WICG/focus-visible/blob/v4.1.5/src/focus-visible.js\nimport * as React from 'react';\nimport { Timeout } from '../useTimeout/useTimeout';\nlet hadKeyboardEvent = true;\nlet hadFocusVisibleRecently = false;\nconst hadFocusVisibleRecentlyTimeout = new Timeout();\nconst inputTypesWhitelist = {\n text: true,\n search: true,\n url: true,\n tel: true,\n email: true,\n password: true,\n number: true,\n date: true,\n month: true,\n week: true,\n time: true,\n datetime: true,\n 'datetime-local': true\n};\n\n/**\n * Computes whether the given element should automatically trigger the\n * `focus-visible` class being added, i.e. whether it should always match\n * `:focus-visible` when focused.\n * @param {Element} node\n * @returns {boolean}\n */\nfunction focusTriggersKeyboardModality(node) {\n const {\n type,\n tagName\n } = node;\n if (tagName === 'INPUT' && inputTypesWhitelist[type] && !node.readOnly) {\n return true;\n }\n if (tagName === 'TEXTAREA' && !node.readOnly) {\n return true;\n }\n if (node.isContentEditable) {\n return true;\n }\n return false;\n}\n\n/**\n * Keep track of our keyboard modality state with `hadKeyboardEvent`.\n * If the most recent user interaction was via the keyboard;\n * and the key press did not include a meta, alt/option, or control key;\n * then the modality is keyboard. Otherwise, the modality is not keyboard.\n * @param {KeyboardEvent} event\n */\nfunction handleKeyDown(event) {\n if (event.metaKey || event.altKey || event.ctrlKey) {\n return;\n }\n hadKeyboardEvent = true;\n}\n\n/**\n * If at any point a user clicks with a pointing device, ensure that we change\n * the modality away from keyboard.\n * This avoids the situation where a user presses a key on an already focused\n * element, and then clicks on a different element, focusing it with a\n * pointing device, while we still think we're in keyboard modality.\n */\nfunction handlePointerDown() {\n hadKeyboardEvent = false;\n}\nfunction handleVisibilityChange() {\n if (this.visibilityState === 'hidden') {\n // If the tab becomes active again, the browser will handle calling focus\n // on the element (Safari actually calls it twice).\n // If this tab change caused a blur on an element with focus-visible,\n // re-apply the class when the user switches back to the tab.\n if (hadFocusVisibleRecently) {\n hadKeyboardEvent = true;\n }\n }\n}\nfunction prepare(doc) {\n doc.addEventListener('keydown', handleKeyDown, true);\n doc.addEventListener('mousedown', handlePointerDown, true);\n doc.addEventListener('pointerdown', handlePointerDown, true);\n doc.addEventListener('touchstart', handlePointerDown, true);\n doc.addEventListener('visibilitychange', handleVisibilityChange, true);\n}\nexport function teardown(doc) {\n doc.removeEventListener('keydown', handleKeyDown, true);\n doc.removeEventListener('mousedown', handlePointerDown, true);\n doc.removeEventListener('pointerdown', handlePointerDown, true);\n doc.removeEventListener('touchstart', handlePointerDown, true);\n doc.removeEventListener('visibilitychange', handleVisibilityChange, true);\n}\nfunction isFocusVisible(event) {\n const {\n target\n } = event;\n try {\n return target.matches(':focus-visible');\n } catch (error) {\n // Browsers not implementing :focus-visible will throw a SyntaxError.\n // We use our own heuristic for those browsers.\n // Rethrow might be better if it's not the expected error but do we really\n // want to crash if focus-visible malfunctioned?\n }\n\n // No need for validFocusTarget check. The user does that by attaching it to\n // focusable events only.\n return hadKeyboardEvent || focusTriggersKeyboardModality(target);\n}\nexport default function useIsFocusVisible() {\n const ref = React.useCallback(node => {\n if (node != null) {\n prepare(node.ownerDocument);\n }\n }, []);\n const isFocusVisibleRef = React.useRef(false);\n\n /**\n * Should be called if a blur event is fired\n */\n function handleBlurVisible() {\n // checking against potential state variable does not suffice if we focus and blur synchronously.\n // React wouldn't have time to trigger a re-render so `focusVisible` would be stale.\n // Ideally we would adjust `isFocusVisible(event)` to look at `relatedTarget` for blur events.\n // This doesn't work in IE11 due to https://github.com/facebook/react/issues/3751\n // TODO: check again if React releases their internal changes to focus event handling (https://github.com/facebook/react/pull/19186).\n if (isFocusVisibleRef.current) {\n // To detect a tab/window switch, we look for a blur event followed\n // rapidly by a visibility change.\n // If we don't see a visibility change within 100ms, it's probably a\n // regular focus change.\n hadFocusVisibleRecently = true;\n hadFocusVisibleRecentlyTimeout.start(100, () => {\n hadFocusVisibleRecently = false;\n });\n isFocusVisibleRef.current = false;\n return true;\n }\n return false;\n }\n\n /**\n * Should be called if a blur event is fired\n */\n function handleFocusVisible(event) {\n if (isFocusVisible(event)) {\n isFocusVisibleRef.current = true;\n return true;\n }\n return false;\n }\n return {\n isFocusVisibleRef,\n onFocus: handleFocusVisible,\n onBlur: handleBlurVisible,\n ref\n };\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\n/**\n * Add keys, values of `defaultProps` that does not exist in `props`\n * @param {object} defaultProps\n * @param {object} props\n * @returns {object} resolved props\n */\nexport default function resolveProps(defaultProps, props) {\n const output = _extends({}, props);\n Object.keys(defaultProps).forEach(propName => {\n if (propName.toString().match(/^(components|slots)$/)) {\n output[propName] = _extends({}, defaultProps[propName], output[propName]);\n } else if (propName.toString().match(/^(componentsProps|slotProps)$/)) {\n const defaultSlotProps = defaultProps[propName] || {};\n const slotProps = props[propName];\n output[propName] = {};\n if (!slotProps || !Object.keys(slotProps)) {\n // Reduce the iteration if the slot props is empty\n output[propName] = defaultSlotProps;\n } else if (!defaultSlotProps || !Object.keys(defaultSlotProps)) {\n // Reduce the iteration if the default slot props is empty\n output[propName] = slotProps;\n } else {\n output[propName] = _extends({}, slotProps);\n Object.keys(defaultSlotProps).forEach(slotPropName => {\n output[propName][slotPropName] = resolveProps(defaultSlotProps[slotPropName], slotProps[slotPropName]);\n });\n }\n } else if (output[propName] === undefined) {\n output[propName] = defaultProps[propName];\n }\n });\n return output;\n}","export default function composeClasses(slots, getUtilityClass, classes = undefined) {\n const output = {};\n Object.keys(slots).forEach(\n // `Object.keys(slots)` can't be wider than `T` because we infer `T` from `slots`.\n // @ts-expect-error https://github.com/microsoft/TypeScript/pull/12253#issuecomment-263132208\n slot => {\n output[slot] = slots[slot].reduce((acc, key) => {\n if (key) {\n const utilityClass = getUtilityClass(key);\n if (utilityClass !== '') {\n acc.push(utilityClass);\n }\n if (classes && classes[key]) {\n acc.push(classes[key]);\n }\n }\n return acc;\n }, []).join(' ');\n });\n return output;\n}","const defaultGenerator = componentName => componentName;\nconst createClassNameGenerator = () => {\n let generate = defaultGenerator;\n return {\n configure(generator) {\n generate = generator;\n },\n generate(componentName) {\n return generate(componentName);\n },\n reset() {\n generate = defaultGenerator;\n }\n };\n};\nconst ClassNameGenerator = createClassNameGenerator();\nexport default ClassNameGenerator;","import ClassNameGenerator from '../ClassNameGenerator';\nexport const globalStateClasses = {\n active: 'active',\n checked: 'checked',\n completed: 'completed',\n disabled: 'disabled',\n error: 'error',\n expanded: 'expanded',\n focused: 'focused',\n focusVisible: 'focusVisible',\n open: 'open',\n readOnly: 'readOnly',\n required: 'required',\n selected: 'selected'\n};\nexport default function generateUtilityClass(componentName, slot, globalStatePrefix = 'Mui') {\n const globalStateClass = globalStateClasses[slot];\n return globalStateClass ? `${globalStatePrefix}-${globalStateClass}` : `${ClassNameGenerator.generate(componentName)}-${slot}`;\n}\nexport function isGlobalState(slot) {\n return globalStateClasses[slot] !== undefined;\n}","import generateUtilityClass from '../generateUtilityClass';\nexport default function generateUtilityClasses(componentName, slots, globalStatePrefix = 'Mui') {\n const result = {};\n slots.forEach(slot => {\n result[slot] = generateUtilityClass(componentName, slot, globalStatePrefix);\n });\n return result;\n}","function clamp(val, min = Number.MIN_SAFE_INTEGER, max = Number.MAX_SAFE_INTEGER) {\n return Math.max(min, Math.min(val, max));\n}\nexport default clamp;","export default function _objectWithoutPropertiesLoose(source, excluded) {\n if (source == null) return {};\n var target = {};\n var sourceKeys = Object.keys(source);\n var key, i;\n for (i = 0; i < sourceKeys.length; i++) {\n key = sourceKeys[i];\n if (excluded.indexOf(key) >= 0) continue;\n target[key] = source[key];\n }\n return target;\n}","import _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nconst _excluded = [\"values\", \"unit\", \"step\"];\n// Sorted ASC by size. That's important.\n// It can't be configured as it's used statically for propTypes.\nexport const breakpointKeys = ['xs', 'sm', 'md', 'lg', 'xl'];\nconst sortBreakpointsValues = values => {\n const breakpointsAsArray = Object.keys(values).map(key => ({\n key,\n val: values[key]\n })) || [];\n // Sort in ascending order\n breakpointsAsArray.sort((breakpoint1, breakpoint2) => breakpoint1.val - breakpoint2.val);\n return breakpointsAsArray.reduce((acc, obj) => {\n return _extends({}, acc, {\n [obj.key]: obj.val\n });\n }, {});\n};\n\n// Keep in mind that @media is inclusive by the CSS specification.\nexport default function createBreakpoints(breakpoints) {\n const {\n // The breakpoint **start** at this value.\n // For instance with the first breakpoint xs: [xs, sm).\n values = {\n xs: 0,\n // phone\n sm: 600,\n // tablet\n md: 900,\n // small laptop\n lg: 1200,\n // desktop\n xl: 1536 // large screen\n },\n unit = 'px',\n step = 5\n } = breakpoints,\n other = _objectWithoutPropertiesLoose(breakpoints, _excluded);\n const sortedValues = sortBreakpointsValues(values);\n const keys = Object.keys(sortedValues);\n function up(key) {\n const value = typeof values[key] === 'number' ? values[key] : key;\n return `@media (min-width:${value}${unit})`;\n }\n function down(key) {\n const value = typeof values[key] === 'number' ? values[key] : key;\n return `@media (max-width:${value - step / 100}${unit})`;\n }\n function between(start, end) {\n const endIndex = keys.indexOf(end);\n return `@media (min-width:${typeof values[start] === 'number' ? values[start] : start}${unit}) and ` + `(max-width:${(endIndex !== -1 && typeof values[keys[endIndex]] === 'number' ? values[keys[endIndex]] : end) - step / 100}${unit})`;\n }\n function only(key) {\n if (keys.indexOf(key) + 1 < keys.length) {\n return between(key, keys[keys.indexOf(key) + 1]);\n }\n return up(key);\n }\n function not(key) {\n // handle first and last key separately, for better readability\n const keyIndex = keys.indexOf(key);\n if (keyIndex === 0) {\n return up(keys[1]);\n }\n if (keyIndex === keys.length - 1) {\n return down(keys[keyIndex]);\n }\n return between(key, keys[keys.indexOf(key) + 1]).replace('@media', '@media not all and');\n }\n return _extends({\n keys,\n values: sortedValues,\n up,\n down,\n between,\n only,\n not,\n unit\n }, other);\n}","const shape = {\n borderRadius: 4\n};\nexport default shape;","import PropTypes from 'prop-types';\nconst responsivePropType = process.env.NODE_ENV !== 'production' ? PropTypes.oneOfType([PropTypes.number, PropTypes.string, PropTypes.object, PropTypes.array]) : {};\nexport default responsivePropType;","import deepmerge from '@mui/utils/deepmerge';\nfunction merge(acc, item) {\n if (!item) {\n return acc;\n }\n return deepmerge(acc, item, {\n clone: false // No need to clone deep, it's way faster.\n });\n}\nexport default merge;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport PropTypes from 'prop-types';\nimport deepmerge from '@mui/utils/deepmerge';\nimport merge from './merge';\n\n// The breakpoint **start** at this value.\n// For instance with the first breakpoint xs: [xs, sm[.\nexport const values = {\n xs: 0,\n // phone\n sm: 600,\n // tablet\n md: 900,\n // small laptop\n lg: 1200,\n // desktop\n xl: 1536 // large screen\n};\nconst defaultBreakpoints = {\n // Sorted ASC by size. That's important.\n // It can't be configured as it's used statically for propTypes.\n keys: ['xs', 'sm', 'md', 'lg', 'xl'],\n up: key => `@media (min-width:${values[key]}px)`\n};\nexport function handleBreakpoints(props, propValue, styleFromPropValue) {\n const theme = props.theme || {};\n if (Array.isArray(propValue)) {\n const themeBreakpoints = theme.breakpoints || defaultBreakpoints;\n return propValue.reduce((acc, item, index) => {\n acc[themeBreakpoints.up(themeBreakpoints.keys[index])] = styleFromPropValue(propValue[index]);\n return acc;\n }, {});\n }\n if (typeof propValue === 'object') {\n const themeBreakpoints = theme.breakpoints || defaultBreakpoints;\n return Object.keys(propValue).reduce((acc, breakpoint) => {\n // key is breakpoint\n if (Object.keys(themeBreakpoints.values || values).indexOf(breakpoint) !== -1) {\n const mediaKey = themeBreakpoints.up(breakpoint);\n acc[mediaKey] = styleFromPropValue(propValue[breakpoint], breakpoint);\n } else {\n const cssKey = breakpoint;\n acc[cssKey] = propValue[cssKey];\n }\n return acc;\n }, {});\n }\n const output = styleFromPropValue(propValue);\n return output;\n}\nfunction breakpoints(styleFunction) {\n // false positive\n // eslint-disable-next-line react/function-component-definition\n const newStyleFunction = props => {\n const theme = props.theme || {};\n const base = styleFunction(props);\n const themeBreakpoints = theme.breakpoints || defaultBreakpoints;\n const extended = themeBreakpoints.keys.reduce((acc, key) => {\n if (props[key]) {\n acc = acc || {};\n acc[themeBreakpoints.up(key)] = styleFunction(_extends({\n theme\n }, props[key]));\n }\n return acc;\n }, null);\n return merge(base, extended);\n };\n newStyleFunction.propTypes = process.env.NODE_ENV !== 'production' ? _extends({}, styleFunction.propTypes, {\n xs: PropTypes.object,\n sm: PropTypes.object,\n md: PropTypes.object,\n lg: PropTypes.object,\n xl: PropTypes.object\n }) : {};\n newStyleFunction.filterProps = ['xs', 'sm', 'md', 'lg', 'xl', ...styleFunction.filterProps];\n return newStyleFunction;\n}\nexport function createEmptyBreakpointObject(breakpointsInput = {}) {\n var _breakpointsInput$key;\n const breakpointsInOrder = (_breakpointsInput$key = breakpointsInput.keys) == null ? void 0 : _breakpointsInput$key.reduce((acc, key) => {\n const breakpointStyleKey = breakpointsInput.up(key);\n acc[breakpointStyleKey] = {};\n return acc;\n }, {});\n return breakpointsInOrder || {};\n}\nexport function removeUnusedBreakpoints(breakpointKeys, style) {\n return breakpointKeys.reduce((acc, key) => {\n const breakpointOutput = acc[key];\n const isBreakpointUnused = !breakpointOutput || Object.keys(breakpointOutput).length === 0;\n if (isBreakpointUnused) {\n delete acc[key];\n }\n return acc;\n }, style);\n}\nexport function mergeBreakpointsInOrder(breakpointsInput, ...styles) {\n const emptyBreakpoints = createEmptyBreakpointObject(breakpointsInput);\n const mergedOutput = [emptyBreakpoints, ...styles].reduce((prev, next) => deepmerge(prev, next), {});\n return removeUnusedBreakpoints(Object.keys(emptyBreakpoints), mergedOutput);\n}\n\n// compute base for responsive values; e.g.,\n// [1,2,3] => {xs: true, sm: true, md: true}\n// {xs: 1, sm: 2, md: 3} => {xs: true, sm: true, md: true}\nexport function computeBreakpointsBase(breakpointValues, themeBreakpoints) {\n // fixed value\n if (typeof breakpointValues !== 'object') {\n return {};\n }\n const base = {};\n const breakpointsKeys = Object.keys(themeBreakpoints);\n if (Array.isArray(breakpointValues)) {\n breakpointsKeys.forEach((breakpoint, i) => {\n if (i < breakpointValues.length) {\n base[breakpoint] = true;\n }\n });\n } else {\n breakpointsKeys.forEach(breakpoint => {\n if (breakpointValues[breakpoint] != null) {\n base[breakpoint] = true;\n }\n });\n }\n return base;\n}\nexport function resolveBreakpointValues({\n values: breakpointValues,\n breakpoints: themeBreakpoints,\n base: customBase\n}) {\n const base = customBase || computeBreakpointsBase(breakpointValues, themeBreakpoints);\n const keys = Object.keys(base);\n if (keys.length === 0) {\n return breakpointValues;\n }\n let previous;\n return keys.reduce((acc, breakpoint, i) => {\n if (Array.isArray(breakpointValues)) {\n acc[breakpoint] = breakpointValues[i] != null ? breakpointValues[i] : breakpointValues[previous];\n previous = i;\n } else if (typeof breakpointValues === 'object') {\n acc[breakpoint] = breakpointValues[breakpoint] != null ? breakpointValues[breakpoint] : breakpointValues[previous];\n previous = breakpoint;\n } else {\n acc[breakpoint] = breakpointValues;\n }\n return acc;\n }, {});\n}\nexport default breakpoints;","import capitalize from '@mui/utils/capitalize';\nimport responsivePropType from './responsivePropType';\nimport { handleBreakpoints } from './breakpoints';\nexport function getPath(obj, path, checkVars = true) {\n if (!path || typeof path !== 'string') {\n return null;\n }\n\n // Check if CSS variables are used\n if (obj && obj.vars && checkVars) {\n const val = `vars.${path}`.split('.').reduce((acc, item) => acc && acc[item] ? acc[item] : null, obj);\n if (val != null) {\n return val;\n }\n }\n return path.split('.').reduce((acc, item) => {\n if (acc && acc[item] != null) {\n return acc[item];\n }\n return null;\n }, obj);\n}\nexport function getStyleValue(themeMapping, transform, propValueFinal, userValue = propValueFinal) {\n let value;\n if (typeof themeMapping === 'function') {\n value = themeMapping(propValueFinal);\n } else if (Array.isArray(themeMapping)) {\n value = themeMapping[propValueFinal] || userValue;\n } else {\n value = getPath(themeMapping, propValueFinal) || userValue;\n }\n if (transform) {\n value = transform(value, userValue, themeMapping);\n }\n return value;\n}\nfunction style(options) {\n const {\n prop,\n cssProperty = options.prop,\n themeKey,\n transform\n } = options;\n\n // false positive\n // eslint-disable-next-line react/function-component-definition\n const fn = props => {\n if (props[prop] == null) {\n return null;\n }\n const propValue = props[prop];\n const theme = props.theme;\n const themeMapping = getPath(theme, themeKey) || {};\n const styleFromPropValue = propValueFinal => {\n let value = getStyleValue(themeMapping, transform, propValueFinal);\n if (propValueFinal === value && typeof propValueFinal === 'string') {\n // Haven't found value\n value = getStyleValue(themeMapping, transform, `${prop}${propValueFinal === 'default' ? '' : capitalize(propValueFinal)}`, propValueFinal);\n }\n if (cssProperty === false) {\n return value;\n }\n return {\n [cssProperty]: value\n };\n };\n return handleBreakpoints(props, propValue, styleFromPropValue);\n };\n fn.propTypes = process.env.NODE_ENV !== 'production' ? {\n [prop]: responsivePropType\n } : {};\n fn.filterProps = [prop];\n return fn;\n}\nexport default style;","export default function memoize(fn) {\n const cache = {};\n return arg => {\n if (cache[arg] === undefined) {\n cache[arg] = fn(arg);\n }\n return cache[arg];\n };\n}","import responsivePropType from './responsivePropType';\nimport { handleBreakpoints } from './breakpoints';\nimport { getPath } from './style';\nimport merge from './merge';\nimport memoize from './memoize';\nconst properties = {\n m: 'margin',\n p: 'padding'\n};\nconst directions = {\n t: 'Top',\n r: 'Right',\n b: 'Bottom',\n l: 'Left',\n x: ['Left', 'Right'],\n y: ['Top', 'Bottom']\n};\nconst aliases = {\n marginX: 'mx',\n marginY: 'my',\n paddingX: 'px',\n paddingY: 'py'\n};\n\n// memoize() impact:\n// From 300,000 ops/sec\n// To 350,000 ops/sec\nconst getCssProperties = memoize(prop => {\n // It's not a shorthand notation.\n if (prop.length > 2) {\n if (aliases[prop]) {\n prop = aliases[prop];\n } else {\n return [prop];\n }\n }\n const [a, b] = prop.split('');\n const property = properties[a];\n const direction = directions[b] || '';\n return Array.isArray(direction) ? direction.map(dir => property + dir) : [property + direction];\n});\nexport const marginKeys = ['m', 'mt', 'mr', 'mb', 'ml', 'mx', 'my', 'margin', 'marginTop', 'marginRight', 'marginBottom', 'marginLeft', 'marginX', 'marginY', 'marginInline', 'marginInlineStart', 'marginInlineEnd', 'marginBlock', 'marginBlockStart', 'marginBlockEnd'];\nexport const paddingKeys = ['p', 'pt', 'pr', 'pb', 'pl', 'px', 'py', 'padding', 'paddingTop', 'paddingRight', 'paddingBottom', 'paddingLeft', 'paddingX', 'paddingY', 'paddingInline', 'paddingInlineStart', 'paddingInlineEnd', 'paddingBlock', 'paddingBlockStart', 'paddingBlockEnd'];\nconst spacingKeys = [...marginKeys, ...paddingKeys];\nexport function createUnaryUnit(theme, themeKey, defaultValue, propName) {\n var _getPath;\n const themeSpacing = (_getPath = getPath(theme, themeKey, false)) != null ? _getPath : defaultValue;\n if (typeof themeSpacing === 'number') {\n return abs => {\n if (typeof abs === 'string') {\n return abs;\n }\n if (process.env.NODE_ENV !== 'production') {\n if (typeof abs !== 'number') {\n console.error(`MUI: Expected ${propName} argument to be a number or a string, got ${abs}.`);\n }\n }\n return themeSpacing * abs;\n };\n }\n if (Array.isArray(themeSpacing)) {\n return abs => {\n if (typeof abs === 'string') {\n return abs;\n }\n if (process.env.NODE_ENV !== 'production') {\n if (!Number.isInteger(abs)) {\n console.error([`MUI: The \\`theme.${themeKey}\\` array type cannot be combined with non integer values.` + `You should either use an integer value that can be used as index, or define the \\`theme.${themeKey}\\` as a number.`].join('\\n'));\n } else if (abs > themeSpacing.length - 1) {\n console.error([`MUI: The value provided (${abs}) overflows.`, `The supported values are: ${JSON.stringify(themeSpacing)}.`, `${abs} > ${themeSpacing.length - 1}, you need to add the missing values.`].join('\\n'));\n }\n }\n return themeSpacing[abs];\n };\n }\n if (typeof themeSpacing === 'function') {\n return themeSpacing;\n }\n if (process.env.NODE_ENV !== 'production') {\n console.error([`MUI: The \\`theme.${themeKey}\\` value (${themeSpacing}) is invalid.`, 'It should be a number, an array or a function.'].join('\\n'));\n }\n return () => undefined;\n}\nexport function createUnarySpacing(theme) {\n return createUnaryUnit(theme, 'spacing', 8, 'spacing');\n}\nexport function getValue(transformer, propValue) {\n if (typeof propValue === 'string' || propValue == null) {\n return propValue;\n }\n const abs = Math.abs(propValue);\n const transformed = transformer(abs);\n if (propValue >= 0) {\n return transformed;\n }\n if (typeof transformed === 'number') {\n return -transformed;\n }\n return `-${transformed}`;\n}\nexport function getStyleFromPropValue(cssProperties, transformer) {\n return propValue => cssProperties.reduce((acc, cssProperty) => {\n acc[cssProperty] = getValue(transformer, propValue);\n return acc;\n }, {});\n}\nfunction resolveCssProperty(props, keys, prop, transformer) {\n // Using a hash computation over an array iteration could be faster, but with only 28 items,\n // it's doesn't worth the bundle size.\n if (keys.indexOf(prop) === -1) {\n return null;\n }\n const cssProperties = getCssProperties(prop);\n const styleFromPropValue = getStyleFromPropValue(cssProperties, transformer);\n const propValue = props[prop];\n return handleBreakpoints(props, propValue, styleFromPropValue);\n}\nfunction style(props, keys) {\n const transformer = createUnarySpacing(props.theme);\n return Object.keys(props).map(prop => resolveCssProperty(props, keys, prop, transformer)).reduce(merge, {});\n}\nexport function margin(props) {\n return style(props, marginKeys);\n}\nmargin.propTypes = process.env.NODE_ENV !== 'production' ? marginKeys.reduce((obj, key) => {\n obj[key] = responsivePropType;\n return obj;\n}, {}) : {};\nmargin.filterProps = marginKeys;\nexport function padding(props) {\n return style(props, paddingKeys);\n}\npadding.propTypes = process.env.NODE_ENV !== 'production' ? paddingKeys.reduce((obj, key) => {\n obj[key] = responsivePropType;\n return obj;\n}, {}) : {};\npadding.filterProps = paddingKeys;\nfunction spacing(props) {\n return style(props, spacingKeys);\n}\nspacing.propTypes = process.env.NODE_ENV !== 'production' ? spacingKeys.reduce((obj, key) => {\n obj[key] = responsivePropType;\n return obj;\n}, {}) : {};\nspacing.filterProps = spacingKeys;\nexport default spacing;","import { createUnarySpacing } from '../spacing';\n\n// The different signatures imply different meaning for their arguments that can't be expressed structurally.\n// We express the difference with variable names.\n\nexport default function createSpacing(spacingInput = 8) {\n // Already transformed.\n if (spacingInput.mui) {\n return spacingInput;\n }\n\n // Material Design layouts are visually balanced. Most measurements align to an 8dp grid, which aligns both spacing and the overall layout.\n // Smaller components, such as icons, can align to a 4dp grid.\n // https://m2.material.io/design/layout/understanding-layout.html\n const transform = createUnarySpacing({\n spacing: spacingInput\n });\n const spacing = (...argsInput) => {\n if (process.env.NODE_ENV !== 'production') {\n if (!(argsInput.length <= 4)) {\n console.error(`MUI: Too many arguments provided, expected between 0 and 4, got ${argsInput.length}`);\n }\n }\n const args = argsInput.length === 0 ? [1] : argsInput;\n return args.map(argument => {\n const output = transform(argument);\n return typeof output === 'number' ? `${output}px` : output;\n }).join(' ');\n };\n spacing.mui = true;\n return spacing;\n}","import merge from './merge';\nfunction compose(...styles) {\n const handlers = styles.reduce((acc, style) => {\n style.filterProps.forEach(prop => {\n acc[prop] = style;\n });\n return acc;\n }, {});\n\n // false positive\n // eslint-disable-next-line react/function-component-definition\n const fn = props => {\n return Object.keys(props).reduce((acc, prop) => {\n if (handlers[prop]) {\n return merge(acc, handlers[prop](props));\n }\n return acc;\n }, {});\n };\n fn.propTypes = process.env.NODE_ENV !== 'production' ? styles.reduce((acc, style) => Object.assign(acc, style.propTypes), {}) : {};\n fn.filterProps = styles.reduce((acc, style) => acc.concat(style.filterProps), []);\n return fn;\n}\nexport default compose;","import responsivePropType from './responsivePropType';\nimport style from './style';\nimport compose from './compose';\nimport { createUnaryUnit, getValue } from './spacing';\nimport { handleBreakpoints } from './breakpoints';\nexport function borderTransform(value) {\n if (typeof value !== 'number') {\n return value;\n }\n return `${value}px solid`;\n}\nfunction createBorderStyle(prop, transform) {\n return style({\n prop,\n themeKey: 'borders',\n transform\n });\n}\nexport const border = createBorderStyle('border', borderTransform);\nexport const borderTop = createBorderStyle('borderTop', borderTransform);\nexport const borderRight = createBorderStyle('borderRight', borderTransform);\nexport const borderBottom = createBorderStyle('borderBottom', borderTransform);\nexport const borderLeft = createBorderStyle('borderLeft', borderTransform);\nexport const borderColor = createBorderStyle('borderColor');\nexport const borderTopColor = createBorderStyle('borderTopColor');\nexport const borderRightColor = createBorderStyle('borderRightColor');\nexport const borderBottomColor = createBorderStyle('borderBottomColor');\nexport const borderLeftColor = createBorderStyle('borderLeftColor');\nexport const outline = createBorderStyle('outline', borderTransform);\nexport const outlineColor = createBorderStyle('outlineColor');\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const borderRadius = props => {\n if (props.borderRadius !== undefined && props.borderRadius !== null) {\n const transformer = createUnaryUnit(props.theme, 'shape.borderRadius', 4, 'borderRadius');\n const styleFromPropValue = propValue => ({\n borderRadius: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.borderRadius, styleFromPropValue);\n }\n return null;\n};\nborderRadius.propTypes = process.env.NODE_ENV !== 'production' ? {\n borderRadius: responsivePropType\n} : {};\nborderRadius.filterProps = ['borderRadius'];\nconst borders = compose(border, borderTop, borderRight, borderBottom, borderLeft, borderColor, borderTopColor, borderRightColor, borderBottomColor, borderLeftColor, borderRadius, outline, outlineColor);\nexport default borders;","import style from './style';\nimport compose from './compose';\nimport { createUnaryUnit, getValue } from './spacing';\nimport { handleBreakpoints } from './breakpoints';\nimport responsivePropType from './responsivePropType';\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const gap = props => {\n if (props.gap !== undefined && props.gap !== null) {\n const transformer = createUnaryUnit(props.theme, 'spacing', 8, 'gap');\n const styleFromPropValue = propValue => ({\n gap: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.gap, styleFromPropValue);\n }\n return null;\n};\ngap.propTypes = process.env.NODE_ENV !== 'production' ? {\n gap: responsivePropType\n} : {};\ngap.filterProps = ['gap'];\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const columnGap = props => {\n if (props.columnGap !== undefined && props.columnGap !== null) {\n const transformer = createUnaryUnit(props.theme, 'spacing', 8, 'columnGap');\n const styleFromPropValue = propValue => ({\n columnGap: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.columnGap, styleFromPropValue);\n }\n return null;\n};\ncolumnGap.propTypes = process.env.NODE_ENV !== 'production' ? {\n columnGap: responsivePropType\n} : {};\ncolumnGap.filterProps = ['columnGap'];\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const rowGap = props => {\n if (props.rowGap !== undefined && props.rowGap !== null) {\n const transformer = createUnaryUnit(props.theme, 'spacing', 8, 'rowGap');\n const styleFromPropValue = propValue => ({\n rowGap: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.rowGap, styleFromPropValue);\n }\n return null;\n};\nrowGap.propTypes = process.env.NODE_ENV !== 'production' ? {\n rowGap: responsivePropType\n} : {};\nrowGap.filterProps = ['rowGap'];\nexport const gridColumn = style({\n prop: 'gridColumn'\n});\nexport const gridRow = style({\n prop: 'gridRow'\n});\nexport const gridAutoFlow = style({\n prop: 'gridAutoFlow'\n});\nexport const gridAutoColumns = style({\n prop: 'gridAutoColumns'\n});\nexport const gridAutoRows = style({\n prop: 'gridAutoRows'\n});\nexport const gridTemplateColumns = style({\n prop: 'gridTemplateColumns'\n});\nexport const gridTemplateRows = style({\n prop: 'gridTemplateRows'\n});\nexport const gridTemplateAreas = style({\n prop: 'gridTemplateAreas'\n});\nexport const gridArea = style({\n prop: 'gridArea'\n});\nconst grid = compose(gap, columnGap, rowGap, gridColumn, gridRow, gridAutoFlow, gridAutoColumns, gridAutoRows, gridTemplateColumns, gridTemplateRows, gridTemplateAreas, gridArea);\nexport default grid;","import style from './style';\nimport compose from './compose';\nexport function paletteTransform(value, userValue) {\n if (userValue === 'grey') {\n return userValue;\n }\n return value;\n}\nexport const color = style({\n prop: 'color',\n themeKey: 'palette',\n transform: paletteTransform\n});\nexport const bgcolor = style({\n prop: 'bgcolor',\n cssProperty: 'backgroundColor',\n themeKey: 'palette',\n transform: paletteTransform\n});\nexport const backgroundColor = style({\n prop: 'backgroundColor',\n themeKey: 'palette',\n transform: paletteTransform\n});\nconst palette = compose(color, bgcolor, backgroundColor);\nexport default palette;","import style from './style';\nimport compose from './compose';\nimport { handleBreakpoints, values as breakpointsValues } from './breakpoints';\nexport function sizingTransform(value) {\n return value <= 1 && value !== 0 ? `${value * 100}%` : value;\n}\nexport const width = style({\n prop: 'width',\n transform: sizingTransform\n});\nexport const maxWidth = props => {\n if (props.maxWidth !== undefined && props.maxWidth !== null) {\n const styleFromPropValue = propValue => {\n var _props$theme, _props$theme2;\n const breakpoint = ((_props$theme = props.theme) == null || (_props$theme = _props$theme.breakpoints) == null || (_props$theme = _props$theme.values) == null ? void 0 : _props$theme[propValue]) || breakpointsValues[propValue];\n if (!breakpoint) {\n return {\n maxWidth: sizingTransform(propValue)\n };\n }\n if (((_props$theme2 = props.theme) == null || (_props$theme2 = _props$theme2.breakpoints) == null ? void 0 : _props$theme2.unit) !== 'px') {\n return {\n maxWidth: `${breakpoint}${props.theme.breakpoints.unit}`\n };\n }\n return {\n maxWidth: breakpoint\n };\n };\n return handleBreakpoints(props, props.maxWidth, styleFromPropValue);\n }\n return null;\n};\nmaxWidth.filterProps = ['maxWidth'];\nexport const minWidth = style({\n prop: 'minWidth',\n transform: sizingTransform\n});\nexport const height = style({\n prop: 'height',\n transform: sizingTransform\n});\nexport const maxHeight = style({\n prop: 'maxHeight',\n transform: sizingTransform\n});\nexport const minHeight = style({\n prop: 'minHeight',\n transform: sizingTransform\n});\nexport const sizeWidth = style({\n prop: 'size',\n cssProperty: 'width',\n transform: sizingTransform\n});\nexport const sizeHeight = style({\n prop: 'size',\n cssProperty: 'height',\n transform: sizingTransform\n});\nexport const boxSizing = style({\n prop: 'boxSizing'\n});\nconst sizing = compose(width, maxWidth, minWidth, height, maxHeight, minHeight, boxSizing);\nexport default sizing;","import { padding, margin } from '../spacing';\nimport { borderRadius, borderTransform } from '../borders';\nimport { gap, rowGap, columnGap } from '../cssGrid';\nimport { paletteTransform } from '../palette';\nimport { maxWidth, sizingTransform } from '../sizing';\nconst defaultSxConfig = {\n // borders\n border: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderTop: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderRight: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderBottom: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderLeft: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderColor: {\n themeKey: 'palette'\n },\n borderTopColor: {\n themeKey: 'palette'\n },\n borderRightColor: {\n themeKey: 'palette'\n },\n borderBottomColor: {\n themeKey: 'palette'\n },\n borderLeftColor: {\n themeKey: 'palette'\n },\n outline: {\n themeKey: 'borders',\n transform: borderTransform\n },\n outlineColor: {\n themeKey: 'palette'\n },\n borderRadius: {\n themeKey: 'shape.borderRadius',\n style: borderRadius\n },\n // palette\n color: {\n themeKey: 'palette',\n transform: paletteTransform\n },\n bgcolor: {\n themeKey: 'palette',\n cssProperty: 'backgroundColor',\n transform: paletteTransform\n },\n backgroundColor: {\n themeKey: 'palette',\n transform: paletteTransform\n },\n // spacing\n p: {\n style: padding\n },\n pt: {\n style: padding\n },\n pr: {\n style: padding\n },\n pb: {\n style: padding\n },\n pl: {\n style: padding\n },\n px: {\n style: padding\n },\n py: {\n style: padding\n },\n padding: {\n style: padding\n },\n paddingTop: {\n style: padding\n },\n paddingRight: {\n style: padding\n },\n paddingBottom: {\n style: padding\n },\n paddingLeft: {\n style: padding\n },\n paddingX: {\n style: padding\n },\n paddingY: {\n style: padding\n },\n paddingInline: {\n style: padding\n },\n paddingInlineStart: {\n style: padding\n },\n paddingInlineEnd: {\n style: padding\n },\n paddingBlock: {\n style: padding\n },\n paddingBlockStart: {\n style: padding\n },\n paddingBlockEnd: {\n style: padding\n },\n m: {\n style: margin\n },\n mt: {\n style: margin\n },\n mr: {\n style: margin\n },\n mb: {\n style: margin\n },\n ml: {\n style: margin\n },\n mx: {\n style: margin\n },\n my: {\n style: margin\n },\n margin: {\n style: margin\n },\n marginTop: {\n style: margin\n },\n marginRight: {\n style: margin\n },\n marginBottom: {\n style: margin\n },\n marginLeft: {\n style: margin\n },\n marginX: {\n style: margin\n },\n marginY: {\n style: margin\n },\n marginInline: {\n style: margin\n },\n marginInlineStart: {\n style: margin\n },\n marginInlineEnd: {\n style: margin\n },\n marginBlock: {\n style: margin\n },\n marginBlockStart: {\n style: margin\n },\n marginBlockEnd: {\n style: margin\n },\n // display\n displayPrint: {\n cssProperty: false,\n transform: value => ({\n '@media print': {\n display: value\n }\n })\n },\n display: {},\n overflow: {},\n textOverflow: {},\n visibility: {},\n whiteSpace: {},\n // flexbox\n flexBasis: {},\n flexDirection: {},\n flexWrap: {},\n justifyContent: {},\n alignItems: {},\n alignContent: {},\n order: {},\n flex: {},\n flexGrow: {},\n flexShrink: {},\n alignSelf: {},\n justifyItems: {},\n justifySelf: {},\n // grid\n gap: {\n style: gap\n },\n rowGap: {\n style: rowGap\n },\n columnGap: {\n style: columnGap\n },\n gridColumn: {},\n gridRow: {},\n gridAutoFlow: {},\n gridAutoColumns: {},\n gridAutoRows: {},\n gridTemplateColumns: {},\n gridTemplateRows: {},\n gridTemplateAreas: {},\n gridArea: {},\n // positions\n position: {},\n zIndex: {\n themeKey: 'zIndex'\n },\n top: {},\n right: {},\n bottom: {},\n left: {},\n // shadows\n boxShadow: {\n themeKey: 'shadows'\n },\n // sizing\n width: {\n transform: sizingTransform\n },\n maxWidth: {\n style: maxWidth\n },\n minWidth: {\n transform: sizingTransform\n },\n height: {\n transform: sizingTransform\n },\n maxHeight: {\n transform: sizingTransform\n },\n minHeight: {\n transform: sizingTransform\n },\n boxSizing: {},\n // typography\n fontFamily: {\n themeKey: 'typography'\n },\n fontSize: {\n themeKey: 'typography'\n },\n fontStyle: {\n themeKey: 'typography'\n },\n fontWeight: {\n themeKey: 'typography'\n },\n letterSpacing: {},\n textTransform: {},\n lineHeight: {},\n textAlign: {},\n typography: {\n cssProperty: false,\n themeKey: 'typography'\n }\n};\nexport default defaultSxConfig;","import capitalize from '@mui/utils/capitalize';\nimport merge from '../merge';\nimport { getPath, getStyleValue as getValue } from '../style';\nimport { handleBreakpoints, createEmptyBreakpointObject, removeUnusedBreakpoints } from '../breakpoints';\nimport defaultSxConfig from './defaultSxConfig';\nfunction objectsHaveSameKeys(...objects) {\n const allKeys = objects.reduce((keys, object) => keys.concat(Object.keys(object)), []);\n const union = new Set(allKeys);\n return objects.every(object => union.size === Object.keys(object).length);\n}\nfunction callIfFn(maybeFn, arg) {\n return typeof maybeFn === 'function' ? maybeFn(arg) : maybeFn;\n}\n\n// eslint-disable-next-line @typescript-eslint/naming-convention\nexport function unstable_createStyleFunctionSx() {\n function getThemeValue(prop, val, theme, config) {\n const props = {\n [prop]: val,\n theme\n };\n const options = config[prop];\n if (!options) {\n return {\n [prop]: val\n };\n }\n const {\n cssProperty = prop,\n themeKey,\n transform,\n style\n } = options;\n if (val == null) {\n return null;\n }\n\n // TODO v6: remove, see https://github.com/mui/material-ui/pull/38123\n if (themeKey === 'typography' && val === 'inherit') {\n return {\n [prop]: val\n };\n }\n const themeMapping = getPath(theme, themeKey) || {};\n if (style) {\n return style(props);\n }\n const styleFromPropValue = propValueFinal => {\n let value = getValue(themeMapping, transform, propValueFinal);\n if (propValueFinal === value && typeof propValueFinal === 'string') {\n // Haven't found value\n value = getValue(themeMapping, transform, `${prop}${propValueFinal === 'default' ? '' : capitalize(propValueFinal)}`, propValueFinal);\n }\n if (cssProperty === false) {\n return value;\n }\n return {\n [cssProperty]: value\n };\n };\n return handleBreakpoints(props, val, styleFromPropValue);\n }\n function styleFunctionSx(props) {\n var _theme$unstable_sxCon;\n const {\n sx,\n theme = {}\n } = props || {};\n if (!sx) {\n return null; // Emotion & styled-components will neglect null\n }\n const config = (_theme$unstable_sxCon = theme.unstable_sxConfig) != null ? _theme$unstable_sxCon : defaultSxConfig;\n\n /*\n * Receive `sxInput` as object or callback\n * and then recursively check keys & values to create media query object styles.\n * (the result will be used in `styled`)\n */\n function traverse(sxInput) {\n let sxObject = sxInput;\n if (typeof sxInput === 'function') {\n sxObject = sxInput(theme);\n } else if (typeof sxInput !== 'object') {\n // value\n return sxInput;\n }\n if (!sxObject) {\n return null;\n }\n const emptyBreakpoints = createEmptyBreakpointObject(theme.breakpoints);\n const breakpointsKeys = Object.keys(emptyBreakpoints);\n let css = emptyBreakpoints;\n Object.keys(sxObject).forEach(styleKey => {\n const value = callIfFn(sxObject[styleKey], theme);\n if (value !== null && value !== undefined) {\n if (typeof value === 'object') {\n if (config[styleKey]) {\n css = merge(css, getThemeValue(styleKey, value, theme, config));\n } else {\n const breakpointsValues = handleBreakpoints({\n theme\n }, value, x => ({\n [styleKey]: x\n }));\n if (objectsHaveSameKeys(breakpointsValues, value)) {\n css[styleKey] = styleFunctionSx({\n sx: value,\n theme\n });\n } else {\n css = merge(css, breakpointsValues);\n }\n }\n } else {\n css = merge(css, getThemeValue(styleKey, value, theme, config));\n }\n }\n });\n return removeUnusedBreakpoints(breakpointsKeys, css);\n }\n return Array.isArray(sx) ? sx.map(traverse) : traverse(sx);\n }\n return styleFunctionSx;\n}\nconst styleFunctionSx = unstable_createStyleFunctionSx();\nstyleFunctionSx.filterProps = ['sx'];\nexport default styleFunctionSx;","/**\n * A universal utility to style components with multiple color modes. Always use it from the theme object.\n * It works with:\n * - [Basic theme](https://mui.com/material-ui/customization/dark-mode/)\n * - [CSS theme variables](https://mui.com/material-ui/experimental-api/css-theme-variables/overview/)\n * - Zero-runtime engine\n *\n * Tips: Use an array over object spread and place `theme.applyStyles()` last.\n *\n * ✅ [{ background: '#e5e5e5' }, theme.applyStyles('dark', { background: '#1c1c1c' })]\n *\n * 🚫 { background: '#e5e5e5', ...theme.applyStyles('dark', { background: '#1c1c1c' })}\n *\n * @example\n * 1. using with `styled`:\n * ```jsx\n * const Component = styled('div')(({ theme }) => [\n * { background: '#e5e5e5' },\n * theme.applyStyles('dark', {\n * background: '#1c1c1c',\n * color: '#fff',\n * }),\n * ]);\n * ```\n *\n * @example\n * 2. using with `sx` prop:\n * ```jsx\n * [\n * { background: '#e5e5e5' },\n * theme.applyStyles('dark', {\n * background: '#1c1c1c',\n * color: '#fff',\n * }),\n * ]}\n * />\n * ```\n *\n * @example\n * 3. theming a component:\n * ```jsx\n * extendTheme({\n * components: {\n * MuiButton: {\n * styleOverrides: {\n * root: ({ theme }) => [\n * { background: '#e5e5e5' },\n * theme.applyStyles('dark', {\n * background: '#1c1c1c',\n * color: '#fff',\n * }),\n * ],\n * },\n * }\n * }\n * })\n *```\n */\nexport default function applyStyles(key, styles) {\n // @ts-expect-error this is 'any' type\n const theme = this;\n if (theme.vars && typeof theme.getColorSchemeSelector === 'function') {\n // If CssVarsProvider is used as a provider,\n // returns '* :where([data-mui-color-scheme=\"light|dark\"]) &'\n const selector = theme.getColorSchemeSelector(key).replace(/(\\[[^\\]]+\\])/, '*:where($1)');\n return {\n [selector]: styles\n };\n }\n if (theme.palette.mode === key) {\n return styles;\n }\n return {};\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"breakpoints\", \"palette\", \"spacing\", \"shape\"];\nimport deepmerge from '@mui/utils/deepmerge';\nimport createBreakpoints from './createBreakpoints';\nimport shape from './shape';\nimport createSpacing from './createSpacing';\nimport styleFunctionSx from '../styleFunctionSx/styleFunctionSx';\nimport defaultSxConfig from '../styleFunctionSx/defaultSxConfig';\nimport applyStyles from './applyStyles';\nfunction createTheme(options = {}, ...args) {\n const {\n breakpoints: breakpointsInput = {},\n palette: paletteInput = {},\n spacing: spacingInput,\n shape: shapeInput = {}\n } = options,\n other = _objectWithoutPropertiesLoose(options, _excluded);\n const breakpoints = createBreakpoints(breakpointsInput);\n const spacing = createSpacing(spacingInput);\n let muiTheme = deepmerge({\n breakpoints,\n direction: 'ltr',\n components: {},\n // Inject component definitions.\n palette: _extends({\n mode: 'light'\n }, paletteInput),\n spacing,\n shape: _extends({}, shape, shapeInput)\n }, other);\n muiTheme.applyStyles = applyStyles;\n muiTheme = args.reduce((acc, argument) => deepmerge(acc, argument), muiTheme);\n muiTheme.unstable_sxConfig = _extends({}, defaultSxConfig, other == null ? void 0 : other.unstable_sxConfig);\n muiTheme.unstable_sx = function sx(props) {\n return styleFunctionSx({\n sx: props,\n theme: this\n });\n };\n return muiTheme;\n}\nexport default createTheme;","'use client';\n\nimport * as React from 'react';\nimport { ThemeContext } from '@mui/styled-engine';\nfunction isObjectEmpty(obj) {\n return Object.keys(obj).length === 0;\n}\nfunction useTheme(defaultTheme = null) {\n const contextTheme = React.useContext(ThemeContext);\n return !contextTheme || isObjectEmpty(contextTheme) ? defaultTheme : contextTheme;\n}\nexport default useTheme;","'use client';\n\nimport createTheme from './createTheme';\nimport useThemeWithoutDefault from './useThemeWithoutDefault';\nexport const systemDefaultTheme = createTheme();\nfunction useTheme(defaultTheme = systemDefaultTheme) {\n return useThemeWithoutDefault(defaultTheme);\n}\nexport default useTheme;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"ownerState\"],\n _excluded2 = [\"variants\"],\n _excluded3 = [\"name\", \"slot\", \"skipVariantsResolver\", \"skipSx\", \"overridesResolver\"];\n/* eslint-disable no-underscore-dangle */\nimport styledEngineStyled, { internal_processStyles as processStyles } from '@mui/styled-engine';\nimport { isPlainObject } from '@mui/utils/deepmerge';\nimport capitalize from '@mui/utils/capitalize';\nimport getDisplayName from '@mui/utils/getDisplayName';\nimport createTheme from './createTheme';\nimport styleFunctionSx from './styleFunctionSx';\nfunction isEmpty(obj) {\n return Object.keys(obj).length === 0;\n}\n\n// https://github.com/emotion-js/emotion/blob/26ded6109fcd8ca9875cc2ce4564fee678a3f3c5/packages/styled/src/utils.js#L40\nfunction isStringTag(tag) {\n return typeof tag === 'string' &&\n // 96 is one less than the char code\n // for \"a\" so this is checking that\n // it's a lowercase character\n tag.charCodeAt(0) > 96;\n}\n\n// Update /system/styled/#api in case if this changes\nexport function shouldForwardProp(prop) {\n return prop !== 'ownerState' && prop !== 'theme' && prop !== 'sx' && prop !== 'as';\n}\nexport const systemDefaultTheme = createTheme();\nconst lowercaseFirstLetter = string => {\n if (!string) {\n return string;\n }\n return string.charAt(0).toLowerCase() + string.slice(1);\n};\nfunction resolveTheme({\n defaultTheme,\n theme,\n themeId\n}) {\n return isEmpty(theme) ? defaultTheme : theme[themeId] || theme;\n}\nfunction defaultOverridesResolver(slot) {\n if (!slot) {\n return null;\n }\n return (props, styles) => styles[slot];\n}\nfunction processStyleArg(callableStyle, _ref) {\n let {\n ownerState\n } = _ref,\n props = _objectWithoutPropertiesLoose(_ref, _excluded);\n const resolvedStylesArg = typeof callableStyle === 'function' ? callableStyle(_extends({\n ownerState\n }, props)) : callableStyle;\n if (Array.isArray(resolvedStylesArg)) {\n return resolvedStylesArg.flatMap(resolvedStyle => processStyleArg(resolvedStyle, _extends({\n ownerState\n }, props)));\n }\n if (!!resolvedStylesArg && typeof resolvedStylesArg === 'object' && Array.isArray(resolvedStylesArg.variants)) {\n const {\n variants = []\n } = resolvedStylesArg,\n otherStyles = _objectWithoutPropertiesLoose(resolvedStylesArg, _excluded2);\n let result = otherStyles;\n variants.forEach(variant => {\n let isMatch = true;\n if (typeof variant.props === 'function') {\n isMatch = variant.props(_extends({\n ownerState\n }, props, ownerState));\n } else {\n Object.keys(variant.props).forEach(key => {\n if ((ownerState == null ? void 0 : ownerState[key]) !== variant.props[key] && props[key] !== variant.props[key]) {\n isMatch = false;\n }\n });\n }\n if (isMatch) {\n if (!Array.isArray(result)) {\n result = [result];\n }\n result.push(typeof variant.style === 'function' ? variant.style(_extends({\n ownerState\n }, props, ownerState)) : variant.style);\n }\n });\n return result;\n }\n return resolvedStylesArg;\n}\nexport default function createStyled(input = {}) {\n const {\n themeId,\n defaultTheme = systemDefaultTheme,\n rootShouldForwardProp = shouldForwardProp,\n slotShouldForwardProp = shouldForwardProp\n } = input;\n const systemSx = props => {\n return styleFunctionSx(_extends({}, props, {\n theme: resolveTheme(_extends({}, props, {\n defaultTheme,\n themeId\n }))\n }));\n };\n systemSx.__mui_systemSx = true;\n return (tag, inputOptions = {}) => {\n // Filter out the `sx` style function from the previous styled component to prevent unnecessary styles generated by the composite components.\n processStyles(tag, styles => styles.filter(style => !(style != null && style.__mui_systemSx)));\n const {\n name: componentName,\n slot: componentSlot,\n skipVariantsResolver: inputSkipVariantsResolver,\n skipSx: inputSkipSx,\n // TODO v6: remove `lowercaseFirstLetter()` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n overridesResolver = defaultOverridesResolver(lowercaseFirstLetter(componentSlot))\n } = inputOptions,\n options = _objectWithoutPropertiesLoose(inputOptions, _excluded3);\n\n // if skipVariantsResolver option is defined, take the value, otherwise, true for root and false for other slots.\n const skipVariantsResolver = inputSkipVariantsResolver !== undefined ? inputSkipVariantsResolver :\n // TODO v6: remove `Root` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n componentSlot && componentSlot !== 'Root' && componentSlot !== 'root' || false;\n const skipSx = inputSkipSx || false;\n let label;\n if (process.env.NODE_ENV !== 'production') {\n if (componentName) {\n // TODO v6: remove `lowercaseFirstLetter()` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n label = `${componentName}-${lowercaseFirstLetter(componentSlot || 'Root')}`;\n }\n }\n let shouldForwardPropOption = shouldForwardProp;\n\n // TODO v6: remove `Root` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n if (componentSlot === 'Root' || componentSlot === 'root') {\n shouldForwardPropOption = rootShouldForwardProp;\n } else if (componentSlot) {\n // any other slot specified\n shouldForwardPropOption = slotShouldForwardProp;\n } else if (isStringTag(tag)) {\n // for string (html) tag, preserve the behavior in emotion & styled-components.\n shouldForwardPropOption = undefined;\n }\n const defaultStyledResolver = styledEngineStyled(tag, _extends({\n shouldForwardProp: shouldForwardPropOption,\n label\n }, options));\n const transformStyleArg = stylesArg => {\n // On the server Emotion doesn't use React.forwardRef for creating components, so the created\n // component stays as a function. This condition makes sure that we do not interpolate functions\n // which are basically components used as a selectors.\n if (typeof stylesArg === 'function' && stylesArg.__emotion_real !== stylesArg || isPlainObject(stylesArg)) {\n return props => processStyleArg(stylesArg, _extends({}, props, {\n theme: resolveTheme({\n theme: props.theme,\n defaultTheme,\n themeId\n })\n }));\n }\n return stylesArg;\n };\n const muiStyledResolver = (styleArg, ...expressions) => {\n let transformedStyleArg = transformStyleArg(styleArg);\n const expressionsWithDefaultTheme = expressions ? expressions.map(transformStyleArg) : [];\n if (componentName && overridesResolver) {\n expressionsWithDefaultTheme.push(props => {\n const theme = resolveTheme(_extends({}, props, {\n defaultTheme,\n themeId\n }));\n if (!theme.components || !theme.components[componentName] || !theme.components[componentName].styleOverrides) {\n return null;\n }\n const styleOverrides = theme.components[componentName].styleOverrides;\n const resolvedStyleOverrides = {};\n // TODO: v7 remove iteration and use `resolveStyleArg(styleOverrides[slot])` directly\n Object.entries(styleOverrides).forEach(([slotKey, slotStyle]) => {\n resolvedStyleOverrides[slotKey] = processStyleArg(slotStyle, _extends({}, props, {\n theme\n }));\n });\n return overridesResolver(props, resolvedStyleOverrides);\n });\n }\n if (componentName && !skipVariantsResolver) {\n expressionsWithDefaultTheme.push(props => {\n var _theme$components;\n const theme = resolveTheme(_extends({}, props, {\n defaultTheme,\n themeId\n }));\n const themeVariants = theme == null || (_theme$components = theme.components) == null || (_theme$components = _theme$components[componentName]) == null ? void 0 : _theme$components.variants;\n return processStyleArg({\n variants: themeVariants\n }, _extends({}, props, {\n theme\n }));\n });\n }\n if (!skipSx) {\n expressionsWithDefaultTheme.push(systemSx);\n }\n const numOfCustomFnsApplied = expressionsWithDefaultTheme.length - expressions.length;\n if (Array.isArray(styleArg) && numOfCustomFnsApplied > 0) {\n const placeholders = new Array(numOfCustomFnsApplied).fill('');\n // If the type is array, than we need to add placeholders in the template for the overrides, variants and the sx styles.\n transformedStyleArg = [...styleArg, ...placeholders];\n transformedStyleArg.raw = [...styleArg.raw, ...placeholders];\n }\n const Component = defaultStyledResolver(transformedStyleArg, ...expressionsWithDefaultTheme);\n if (process.env.NODE_ENV !== 'production') {\n let displayName;\n if (componentName) {\n displayName = `${componentName}${capitalize(componentSlot || '')}`;\n }\n if (displayName === undefined) {\n displayName = `Styled(${getDisplayName(tag)})`;\n }\n Component.displayName = displayName;\n }\n if (tag.muiName) {\n Component.muiName = tag.muiName;\n }\n return Component;\n };\n if (defaultStyledResolver.withConfig) {\n muiStyledResolver.withConfig = defaultStyledResolver.withConfig;\n }\n return muiStyledResolver;\n };\n}","import resolveProps from '@mui/utils/resolveProps';\nexport default function getThemeProps(params) {\n const {\n theme,\n name,\n props\n } = params;\n if (!theme || !theme.components || !theme.components[name] || !theme.components[name].defaultProps) {\n return props;\n }\n return resolveProps(theme.components[name].defaultProps, props);\n}","'use client';\n\nimport getThemeProps from './getThemeProps';\nimport useTheme from '../useTheme';\nexport default function useThemeProps({\n props,\n name,\n defaultTheme,\n themeId\n}) {\n let theme = useTheme(defaultTheme);\n if (themeId) {\n theme = theme[themeId] || theme;\n }\n const mergedProps = getThemeProps({\n theme,\n name,\n props\n });\n return mergedProps;\n}","import _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\n/* eslint-disable @typescript-eslint/naming-convention */\nimport clamp from '@mui/utils/clamp';\n/**\n * Returns a number whose value is limited to the given range.\n * @param {number} value The value to be clamped\n * @param {number} min The lower boundary of the output range\n * @param {number} max The upper boundary of the output range\n * @returns {number} A number in the range [min, max]\n */\nfunction clampWrapper(value, min = 0, max = 1) {\n if (process.env.NODE_ENV !== 'production') {\n if (value < min || value > max) {\n console.error(`MUI: The value provided ${value} is out of range [${min}, ${max}].`);\n }\n }\n return clamp(value, min, max);\n}\n\n/**\n * Converts a color from CSS hex format to CSS rgb format.\n * @param {string} color - Hex color, i.e. #nnn or #nnnnnn\n * @returns {string} A CSS rgb color string\n */\nexport function hexToRgb(color) {\n color = color.slice(1);\n const re = new RegExp(`.{1,${color.length >= 6 ? 2 : 1}}`, 'g');\n let colors = color.match(re);\n if (colors && colors[0].length === 1) {\n colors = colors.map(n => n + n);\n }\n return colors ? `rgb${colors.length === 4 ? 'a' : ''}(${colors.map((n, index) => {\n return index < 3 ? parseInt(n, 16) : Math.round(parseInt(n, 16) / 255 * 1000) / 1000;\n }).join(', ')})` : '';\n}\nfunction intToHex(int) {\n const hex = int.toString(16);\n return hex.length === 1 ? `0${hex}` : hex;\n}\n\n/**\n * Returns an object with the type and values of a color.\n *\n * Note: Does not support rgb % values.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @returns {object} - A MUI color object: {type: string, values: number[]}\n */\nexport function decomposeColor(color) {\n // Idempotent\n if (color.type) {\n return color;\n }\n if (color.charAt(0) === '#') {\n return decomposeColor(hexToRgb(color));\n }\n const marker = color.indexOf('(');\n const type = color.substring(0, marker);\n if (['rgb', 'rgba', 'hsl', 'hsla', 'color'].indexOf(type) === -1) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: Unsupported \\`${color}\\` color.\nThe following formats are supported: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color().` : _formatMuiErrorMessage(9, color));\n }\n let values = color.substring(marker + 1, color.length - 1);\n let colorSpace;\n if (type === 'color') {\n values = values.split(' ');\n colorSpace = values.shift();\n if (values.length === 4 && values[3].charAt(0) === '/') {\n values[3] = values[3].slice(1);\n }\n if (['srgb', 'display-p3', 'a98-rgb', 'prophoto-rgb', 'rec-2020'].indexOf(colorSpace) === -1) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: unsupported \\`${colorSpace}\\` color space.\nThe following color spaces are supported: srgb, display-p3, a98-rgb, prophoto-rgb, rec-2020.` : _formatMuiErrorMessage(10, colorSpace));\n }\n } else {\n values = values.split(',');\n }\n values = values.map(value => parseFloat(value));\n return {\n type,\n values,\n colorSpace\n };\n}\n\n/**\n * Returns a channel created from the input color.\n *\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @returns {string} - The channel for the color, that can be used in rgba or hsla colors\n */\nexport const colorChannel = color => {\n const decomposedColor = decomposeColor(color);\n return decomposedColor.values.slice(0, 3).map((val, idx) => decomposedColor.type.indexOf('hsl') !== -1 && idx !== 0 ? `${val}%` : val).join(' ');\n};\nexport const private_safeColorChannel = (color, warning) => {\n try {\n return colorChannel(color);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n};\n\n/**\n * Converts a color object with type and values to a string.\n * @param {object} color - Decomposed color\n * @param {string} color.type - One of: 'rgb', 'rgba', 'hsl', 'hsla', 'color'\n * @param {array} color.values - [n,n,n] or [n,n,n,n]\n * @returns {string} A CSS color string\n */\nexport function recomposeColor(color) {\n const {\n type,\n colorSpace\n } = color;\n let {\n values\n } = color;\n if (type.indexOf('rgb') !== -1) {\n // Only convert the first 3 values to int (i.e. not alpha)\n values = values.map((n, i) => i < 3 ? parseInt(n, 10) : n);\n } else if (type.indexOf('hsl') !== -1) {\n values[1] = `${values[1]}%`;\n values[2] = `${values[2]}%`;\n }\n if (type.indexOf('color') !== -1) {\n values = `${colorSpace} ${values.join(' ')}`;\n } else {\n values = `${values.join(', ')}`;\n }\n return `${type}(${values})`;\n}\n\n/**\n * Converts a color from CSS rgb format to CSS hex format.\n * @param {string} color - RGB color, i.e. rgb(n, n, n)\n * @returns {string} A CSS rgb color string, i.e. #nnnnnn\n */\nexport function rgbToHex(color) {\n // Idempotent\n if (color.indexOf('#') === 0) {\n return color;\n }\n const {\n values\n } = decomposeColor(color);\n return `#${values.map((n, i) => intToHex(i === 3 ? Math.round(255 * n) : n)).join('')}`;\n}\n\n/**\n * Converts a color from hsl format to rgb format.\n * @param {string} color - HSL color values\n * @returns {string} rgb color values\n */\nexport function hslToRgb(color) {\n color = decomposeColor(color);\n const {\n values\n } = color;\n const h = values[0];\n const s = values[1] / 100;\n const l = values[2] / 100;\n const a = s * Math.min(l, 1 - l);\n const f = (n, k = (n + h / 30) % 12) => l - a * Math.max(Math.min(k - 3, 9 - k, 1), -1);\n let type = 'rgb';\n const rgb = [Math.round(f(0) * 255), Math.round(f(8) * 255), Math.round(f(4) * 255)];\n if (color.type === 'hsla') {\n type += 'a';\n rgb.push(values[3]);\n }\n return recomposeColor({\n type,\n values: rgb\n });\n}\n/**\n * The relative brightness of any point in a color space,\n * normalized to 0 for darkest black and 1 for lightest white.\n *\n * Formula: https://www.w3.org/TR/WCAG20-TECHS/G17.html#G17-tests\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @returns {number} The relative brightness of the color in the range 0 - 1\n */\nexport function getLuminance(color) {\n color = decomposeColor(color);\n let rgb = color.type === 'hsl' || color.type === 'hsla' ? decomposeColor(hslToRgb(color)).values : color.values;\n rgb = rgb.map(val => {\n if (color.type !== 'color') {\n val /= 255; // normalized\n }\n return val <= 0.03928 ? val / 12.92 : ((val + 0.055) / 1.055) ** 2.4;\n });\n\n // Truncate at 3 digits\n return Number((0.2126 * rgb[0] + 0.7152 * rgb[1] + 0.0722 * rgb[2]).toFixed(3));\n}\n\n/**\n * Calculates the contrast ratio between two colors.\n *\n * Formula: https://www.w3.org/TR/WCAG20-TECHS/G17.html#G17-tests\n * @param {string} foreground - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla()\n * @param {string} background - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla()\n * @returns {number} A contrast ratio value in the range 0 - 21.\n */\nexport function getContrastRatio(foreground, background) {\n const lumA = getLuminance(foreground);\n const lumB = getLuminance(background);\n return (Math.max(lumA, lumB) + 0.05) / (Math.min(lumA, lumB) + 0.05);\n}\n\n/**\n * Sets the absolute transparency of a color.\n * Any existing alpha values are overwritten.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} value - value to set the alpha channel to in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function alpha(color, value) {\n color = decomposeColor(color);\n value = clampWrapper(value);\n if (color.type === 'rgb' || color.type === 'hsl') {\n color.type += 'a';\n }\n if (color.type === 'color') {\n color.values[3] = `/${value}`;\n } else {\n color.values[3] = value;\n }\n return recomposeColor(color);\n}\nexport function private_safeAlpha(color, value, warning) {\n try {\n return alpha(color, value);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Darkens a color.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} coefficient - multiplier in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function darken(color, coefficient) {\n color = decomposeColor(color);\n coefficient = clampWrapper(coefficient);\n if (color.type.indexOf('hsl') !== -1) {\n color.values[2] *= 1 - coefficient;\n } else if (color.type.indexOf('rgb') !== -1 || color.type.indexOf('color') !== -1) {\n for (let i = 0; i < 3; i += 1) {\n color.values[i] *= 1 - coefficient;\n }\n }\n return recomposeColor(color);\n}\nexport function private_safeDarken(color, coefficient, warning) {\n try {\n return darken(color, coefficient);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Lightens a color.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} coefficient - multiplier in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function lighten(color, coefficient) {\n color = decomposeColor(color);\n coefficient = clampWrapper(coefficient);\n if (color.type.indexOf('hsl') !== -1) {\n color.values[2] += (100 - color.values[2]) * coefficient;\n } else if (color.type.indexOf('rgb') !== -1) {\n for (let i = 0; i < 3; i += 1) {\n color.values[i] += (255 - color.values[i]) * coefficient;\n }\n } else if (color.type.indexOf('color') !== -1) {\n for (let i = 0; i < 3; i += 1) {\n color.values[i] += (1 - color.values[i]) * coefficient;\n }\n }\n return recomposeColor(color);\n}\nexport function private_safeLighten(color, coefficient, warning) {\n try {\n return lighten(color, coefficient);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Darken or lighten a color, depending on its luminance.\n * Light colors are darkened, dark colors are lightened.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} coefficient=0.15 - multiplier in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function emphasize(color, coefficient = 0.15) {\n return getLuminance(color) > 0.5 ? darken(color, coefficient) : lighten(color, coefficient);\n}\nexport function private_safeEmphasize(color, coefficient, warning) {\n try {\n return emphasize(color, coefficient);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Blend a transparent overlay color with a background color, resulting in a single\n * RGB color.\n * @param {string} background - CSS color\n * @param {string} overlay - CSS color\n * @param {number} opacity - Opacity multiplier in the range 0 - 1\n * @param {number} [gamma=1.0] - Gamma correction factor. For gamma-correct blending, 2.2 is usual.\n */\nexport function blend(background, overlay, opacity, gamma = 1.0) {\n const blendChannel = (b, o) => Math.round((b ** (1 / gamma) * (1 - opacity) + o ** (1 / gamma) * opacity) ** gamma);\n const backgroundColor = decomposeColor(background);\n const overlayColor = decomposeColor(overlay);\n const rgb = [blendChannel(backgroundColor.values[0], overlayColor.values[0]), blendChannel(backgroundColor.values[1], overlayColor.values[1]), blendChannel(backgroundColor.values[2], overlayColor.values[2])];\n return recomposeColor({\n type: 'rgb',\n values: rgb\n });\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nexport default function createMixins(breakpoints, mixins) {\n return _extends({\n toolbar: {\n minHeight: 56,\n [breakpoints.up('xs')]: {\n '@media (orientation: landscape)': {\n minHeight: 48\n }\n },\n [breakpoints.up('sm')]: {\n minHeight: 64\n }\n }\n }, mixins);\n}","const common = {\n black: '#000',\n white: '#fff'\n};\nexport default common;","const grey = {\n 50: '#fafafa',\n 100: '#f5f5f5',\n 200: '#eeeeee',\n 300: '#e0e0e0',\n 400: '#bdbdbd',\n 500: '#9e9e9e',\n 600: '#757575',\n 700: '#616161',\n 800: '#424242',\n 900: '#212121',\n A100: '#f5f5f5',\n A200: '#eeeeee',\n A400: '#bdbdbd',\n A700: '#616161'\n};\nexport default grey;","const purple = {\n 50: '#f3e5f5',\n 100: '#e1bee7',\n 200: '#ce93d8',\n 300: '#ba68c8',\n 400: '#ab47bc',\n 500: '#9c27b0',\n 600: '#8e24aa',\n 700: '#7b1fa2',\n 800: '#6a1b9a',\n 900: '#4a148c',\n A100: '#ea80fc',\n A200: '#e040fb',\n A400: '#d500f9',\n A700: '#aa00ff'\n};\nexport default purple;","const red = {\n 50: '#ffebee',\n 100: '#ffcdd2',\n 200: '#ef9a9a',\n 300: '#e57373',\n 400: '#ef5350',\n 500: '#f44336',\n 600: '#e53935',\n 700: '#d32f2f',\n 800: '#c62828',\n 900: '#b71c1c',\n A100: '#ff8a80',\n A200: '#ff5252',\n A400: '#ff1744',\n A700: '#d50000'\n};\nexport default red;","const orange = {\n 50: '#fff3e0',\n 100: '#ffe0b2',\n 200: '#ffcc80',\n 300: '#ffb74d',\n 400: '#ffa726',\n 500: '#ff9800',\n 600: '#fb8c00',\n 700: '#f57c00',\n 800: '#ef6c00',\n 900: '#e65100',\n A100: '#ffd180',\n A200: '#ffab40',\n A400: '#ff9100',\n A700: '#ff6d00'\n};\nexport default orange;","const blue = {\n 50: '#e3f2fd',\n 100: '#bbdefb',\n 200: '#90caf9',\n 300: '#64b5f6',\n 400: '#42a5f5',\n 500: '#2196f3',\n 600: '#1e88e5',\n 700: '#1976d2',\n 800: '#1565c0',\n 900: '#0d47a1',\n A100: '#82b1ff',\n A200: '#448aff',\n A400: '#2979ff',\n A700: '#2962ff'\n};\nexport default blue;","const lightBlue = {\n 50: '#e1f5fe',\n 100: '#b3e5fc',\n 200: '#81d4fa',\n 300: '#4fc3f7',\n 400: '#29b6f6',\n 500: '#03a9f4',\n 600: '#039be5',\n 700: '#0288d1',\n 800: '#0277bd',\n 900: '#01579b',\n A100: '#80d8ff',\n A200: '#40c4ff',\n A400: '#00b0ff',\n A700: '#0091ea'\n};\nexport default lightBlue;","const green = {\n 50: '#e8f5e9',\n 100: '#c8e6c9',\n 200: '#a5d6a7',\n 300: '#81c784',\n 400: '#66bb6a',\n 500: '#4caf50',\n 600: '#43a047',\n 700: '#388e3c',\n 800: '#2e7d32',\n 900: '#1b5e20',\n A100: '#b9f6ca',\n A200: '#69f0ae',\n A400: '#00e676',\n A700: '#00c853'\n};\nexport default green;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\nconst _excluded = [\"mode\", \"contrastThreshold\", \"tonalOffset\"];\nimport { deepmerge } from '@mui/utils';\nimport { darken, getContrastRatio, lighten } from '@mui/system';\nimport common from '../colors/common';\nimport grey from '../colors/grey';\nimport purple from '../colors/purple';\nimport red from '../colors/red';\nimport orange from '../colors/orange';\nimport blue from '../colors/blue';\nimport lightBlue from '../colors/lightBlue';\nimport green from '../colors/green';\nexport const light = {\n // The colors used to style the text.\n text: {\n // The most important text.\n primary: 'rgba(0, 0, 0, 0.87)',\n // Secondary text.\n secondary: 'rgba(0, 0, 0, 0.6)',\n // Disabled text have even lower visual prominence.\n disabled: 'rgba(0, 0, 0, 0.38)'\n },\n // The color used to divide different elements.\n divider: 'rgba(0, 0, 0, 0.12)',\n // The background colors used to style the surfaces.\n // Consistency between these values is important.\n background: {\n paper: common.white,\n default: common.white\n },\n // The colors used to style the action elements.\n action: {\n // The color of an active action like an icon button.\n active: 'rgba(0, 0, 0, 0.54)',\n // The color of an hovered action.\n hover: 'rgba(0, 0, 0, 0.04)',\n hoverOpacity: 0.04,\n // The color of a selected action.\n selected: 'rgba(0, 0, 0, 0.08)',\n selectedOpacity: 0.08,\n // The color of a disabled action.\n disabled: 'rgba(0, 0, 0, 0.26)',\n // The background color of a disabled action.\n disabledBackground: 'rgba(0, 0, 0, 0.12)',\n disabledOpacity: 0.38,\n focus: 'rgba(0, 0, 0, 0.12)',\n focusOpacity: 0.12,\n activatedOpacity: 0.12\n }\n};\nexport const dark = {\n text: {\n primary: common.white,\n secondary: 'rgba(255, 255, 255, 0.7)',\n disabled: 'rgba(255, 255, 255, 0.5)',\n icon: 'rgba(255, 255, 255, 0.5)'\n },\n divider: 'rgba(255, 255, 255, 0.12)',\n background: {\n paper: '#121212',\n default: '#121212'\n },\n action: {\n active: common.white,\n hover: 'rgba(255, 255, 255, 0.08)',\n hoverOpacity: 0.08,\n selected: 'rgba(255, 255, 255, 0.16)',\n selectedOpacity: 0.16,\n disabled: 'rgba(255, 255, 255, 0.3)',\n disabledBackground: 'rgba(255, 255, 255, 0.12)',\n disabledOpacity: 0.38,\n focus: 'rgba(255, 255, 255, 0.12)',\n focusOpacity: 0.12,\n activatedOpacity: 0.24\n }\n};\nfunction addLightOrDark(intent, direction, shade, tonalOffset) {\n const tonalOffsetLight = tonalOffset.light || tonalOffset;\n const tonalOffsetDark = tonalOffset.dark || tonalOffset * 1.5;\n if (!intent[direction]) {\n if (intent.hasOwnProperty(shade)) {\n intent[direction] = intent[shade];\n } else if (direction === 'light') {\n intent.light = lighten(intent.main, tonalOffsetLight);\n } else if (direction === 'dark') {\n intent.dark = darken(intent.main, tonalOffsetDark);\n }\n }\n}\nfunction getDefaultPrimary(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: blue[200],\n light: blue[50],\n dark: blue[400]\n };\n }\n return {\n main: blue[700],\n light: blue[400],\n dark: blue[800]\n };\n}\nfunction getDefaultSecondary(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: purple[200],\n light: purple[50],\n dark: purple[400]\n };\n }\n return {\n main: purple[500],\n light: purple[300],\n dark: purple[700]\n };\n}\nfunction getDefaultError(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: red[500],\n light: red[300],\n dark: red[700]\n };\n }\n return {\n main: red[700],\n light: red[400],\n dark: red[800]\n };\n}\nfunction getDefaultInfo(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: lightBlue[400],\n light: lightBlue[300],\n dark: lightBlue[700]\n };\n }\n return {\n main: lightBlue[700],\n light: lightBlue[500],\n dark: lightBlue[900]\n };\n}\nfunction getDefaultSuccess(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: green[400],\n light: green[300],\n dark: green[700]\n };\n }\n return {\n main: green[800],\n light: green[500],\n dark: green[900]\n };\n}\nfunction getDefaultWarning(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: orange[400],\n light: orange[300],\n dark: orange[700]\n };\n }\n return {\n main: '#ed6c02',\n // closest to orange[800] that pass 3:1.\n light: orange[500],\n dark: orange[900]\n };\n}\nexport default function createPalette(palette) {\n const {\n mode = 'light',\n contrastThreshold = 3,\n tonalOffset = 0.2\n } = palette,\n other = _objectWithoutPropertiesLoose(palette, _excluded);\n const primary = palette.primary || getDefaultPrimary(mode);\n const secondary = palette.secondary || getDefaultSecondary(mode);\n const error = palette.error || getDefaultError(mode);\n const info = palette.info || getDefaultInfo(mode);\n const success = palette.success || getDefaultSuccess(mode);\n const warning = palette.warning || getDefaultWarning(mode);\n\n // Use the same logic as\n // Bootstrap: https://github.com/twbs/bootstrap/blob/1d6e3710dd447de1a200f29e8fa521f8a0908f70/scss/_functions.scss#L59\n // and material-components-web https://github.com/material-components/material-components-web/blob/ac46b8863c4dab9fc22c4c662dc6bd1b65dd652f/packages/mdc-theme/_functions.scss#L54\n function getContrastText(background) {\n const contrastText = getContrastRatio(background, dark.text.primary) >= contrastThreshold ? dark.text.primary : light.text.primary;\n if (process.env.NODE_ENV !== 'production') {\n const contrast = getContrastRatio(background, contrastText);\n if (contrast < 3) {\n console.error([`MUI: The contrast ratio of ${contrast}:1 for ${contrastText} on ${background}`, 'falls below the WCAG recommended absolute minimum contrast ratio of 3:1.', 'https://www.w3.org/TR/2008/REC-WCAG20-20081211/#visual-audio-contrast-contrast'].join('\\n'));\n }\n }\n return contrastText;\n }\n const augmentColor = ({\n color,\n name,\n mainShade = 500,\n lightShade = 300,\n darkShade = 700\n }) => {\n color = _extends({}, color);\n if (!color.main && color[mainShade]) {\n color.main = color[mainShade];\n }\n if (!color.hasOwnProperty('main')) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: The color${name ? ` (${name})` : ''} provided to augmentColor(color) is invalid.\nThe color object needs to have a \\`main\\` property or a \\`${mainShade}\\` property.` : _formatMuiErrorMessage(11, name ? ` (${name})` : '', mainShade));\n }\n if (typeof color.main !== 'string') {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: The color${name ? ` (${name})` : ''} provided to augmentColor(color) is invalid.\n\\`color.main\\` should be a string, but \\`${JSON.stringify(color.main)}\\` was provided instead.\n\nDid you intend to use one of the following approaches?\n\nimport { green } from \"@mui/material/colors\";\n\nconst theme1 = createTheme({ palette: {\n primary: green,\n} });\n\nconst theme2 = createTheme({ palette: {\n primary: { main: green[500] },\n} });` : _formatMuiErrorMessage(12, name ? ` (${name})` : '', JSON.stringify(color.main)));\n }\n addLightOrDark(color, 'light', lightShade, tonalOffset);\n addLightOrDark(color, 'dark', darkShade, tonalOffset);\n if (!color.contrastText) {\n color.contrastText = getContrastText(color.main);\n }\n return color;\n };\n const modes = {\n dark,\n light\n };\n if (process.env.NODE_ENV !== 'production') {\n if (!modes[mode]) {\n console.error(`MUI: The palette mode \\`${mode}\\` is not supported.`);\n }\n }\n const paletteOutput = deepmerge(_extends({\n // A collection of common colors.\n common: _extends({}, common),\n // prevent mutable object.\n // The palette mode, can be light or dark.\n mode,\n // The colors used to represent primary interface elements for a user.\n primary: augmentColor({\n color: primary,\n name: 'primary'\n }),\n // The colors used to represent secondary interface elements for a user.\n secondary: augmentColor({\n color: secondary,\n name: 'secondary',\n mainShade: 'A400',\n lightShade: 'A200',\n darkShade: 'A700'\n }),\n // The colors used to represent interface elements that the user should be made aware of.\n error: augmentColor({\n color: error,\n name: 'error'\n }),\n // The colors used to represent potentially dangerous actions or important messages.\n warning: augmentColor({\n color: warning,\n name: 'warning'\n }),\n // The colors used to present information to the user that is neutral and not necessarily important.\n info: augmentColor({\n color: info,\n name: 'info'\n }),\n // The colors used to indicate the successful completion of an action that user triggered.\n success: augmentColor({\n color: success,\n name: 'success'\n }),\n // The grey colors.\n grey,\n // Used by `getContrastText()` to maximize the contrast between\n // the background and the text.\n contrastThreshold,\n // Takes a background color and returns the text color that maximizes the contrast.\n getContrastText,\n // Generate a rich color object.\n augmentColor,\n // Used by the functions below to shift a color's luminance by approximately\n // two indexes within its tonal palette.\n // E.g., shift from Red 500 to Red 300 or Red 700.\n tonalOffset\n }, modes[mode]), other);\n return paletteOutput;\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"fontFamily\", \"fontSize\", \"fontWeightLight\", \"fontWeightRegular\", \"fontWeightMedium\", \"fontWeightBold\", \"htmlFontSize\", \"allVariants\", \"pxToRem\"];\nimport { deepmerge } from '@mui/utils';\nfunction round(value) {\n return Math.round(value * 1e5) / 1e5;\n}\nconst caseAllCaps = {\n textTransform: 'uppercase'\n};\nconst defaultFontFamily = '\"Roboto\", \"Helvetica\", \"Arial\", sans-serif';\n\n/**\n * @see @link{https://m2.material.io/design/typography/the-type-system.html}\n * @see @link{https://m2.material.io/design/typography/understanding-typography.html}\n */\nexport default function createTypography(palette, typography) {\n const _ref = typeof typography === 'function' ? typography(palette) : typography,\n {\n fontFamily = defaultFontFamily,\n // The default font size of the Material Specification.\n fontSize = 14,\n // px\n fontWeightLight = 300,\n fontWeightRegular = 400,\n fontWeightMedium = 500,\n fontWeightBold = 700,\n // Tell MUI what's the font-size on the html element.\n // 16px is the default font-size used by browsers.\n htmlFontSize = 16,\n // Apply the CSS properties to all the variants.\n allVariants,\n pxToRem: pxToRem2\n } = _ref,\n other = _objectWithoutPropertiesLoose(_ref, _excluded);\n if (process.env.NODE_ENV !== 'production') {\n if (typeof fontSize !== 'number') {\n console.error('MUI: `fontSize` is required to be a number.');\n }\n if (typeof htmlFontSize !== 'number') {\n console.error('MUI: `htmlFontSize` is required to be a number.');\n }\n }\n const coef = fontSize / 14;\n const pxToRem = pxToRem2 || (size => `${size / htmlFontSize * coef}rem`);\n const buildVariant = (fontWeight, size, lineHeight, letterSpacing, casing) => _extends({\n fontFamily,\n fontWeight,\n fontSize: pxToRem(size),\n // Unitless following https://meyerweb.com/eric/thoughts/2006/02/08/unitless-line-heights/\n lineHeight\n }, fontFamily === defaultFontFamily ? {\n letterSpacing: `${round(letterSpacing / size)}em`\n } : {}, casing, allVariants);\n const variants = {\n h1: buildVariant(fontWeightLight, 96, 1.167, -1.5),\n h2: buildVariant(fontWeightLight, 60, 1.2, -0.5),\n h3: buildVariant(fontWeightRegular, 48, 1.167, 0),\n h4: buildVariant(fontWeightRegular, 34, 1.235, 0.25),\n h5: buildVariant(fontWeightRegular, 24, 1.334, 0),\n h6: buildVariant(fontWeightMedium, 20, 1.6, 0.15),\n subtitle1: buildVariant(fontWeightRegular, 16, 1.75, 0.15),\n subtitle2: buildVariant(fontWeightMedium, 14, 1.57, 0.1),\n body1: buildVariant(fontWeightRegular, 16, 1.5, 0.15),\n body2: buildVariant(fontWeightRegular, 14, 1.43, 0.15),\n button: buildVariant(fontWeightMedium, 14, 1.75, 0.4, caseAllCaps),\n caption: buildVariant(fontWeightRegular, 12, 1.66, 0.4),\n overline: buildVariant(fontWeightRegular, 12, 2.66, 1, caseAllCaps),\n // TODO v6: Remove handling of 'inherit' variant from the theme as it is already handled in Material UI's Typography component. Also, remember to remove the associated types.\n inherit: {\n fontFamily: 'inherit',\n fontWeight: 'inherit',\n fontSize: 'inherit',\n lineHeight: 'inherit',\n letterSpacing: 'inherit'\n }\n };\n return deepmerge(_extends({\n htmlFontSize,\n pxToRem,\n fontFamily,\n fontSize,\n fontWeightLight,\n fontWeightRegular,\n fontWeightMedium,\n fontWeightBold\n }, variants), other, {\n clone: false // No need to clone deep\n });\n}","const shadowKeyUmbraOpacity = 0.2;\nconst shadowKeyPenumbraOpacity = 0.14;\nconst shadowAmbientShadowOpacity = 0.12;\nfunction createShadow(...px) {\n return [`${px[0]}px ${px[1]}px ${px[2]}px ${px[3]}px rgba(0,0,0,${shadowKeyUmbraOpacity})`, `${px[4]}px ${px[5]}px ${px[6]}px ${px[7]}px rgba(0,0,0,${shadowKeyPenumbraOpacity})`, `${px[8]}px ${px[9]}px ${px[10]}px ${px[11]}px rgba(0,0,0,${shadowAmbientShadowOpacity})`].join(',');\n}\n\n// Values from https://github.com/material-components/material-components-web/blob/be8747f94574669cb5e7add1a7c54fa41a89cec7/packages/mdc-elevation/_variables.scss\nconst shadows = ['none', createShadow(0, 2, 1, -1, 0, 1, 1, 0, 0, 1, 3, 0), createShadow(0, 3, 1, -2, 0, 2, 2, 0, 0, 1, 5, 0), createShadow(0, 3, 3, -2, 0, 3, 4, 0, 0, 1, 8, 0), createShadow(0, 2, 4, -1, 0, 4, 5, 0, 0, 1, 10, 0), createShadow(0, 3, 5, -1, 0, 5, 8, 0, 0, 1, 14, 0), createShadow(0, 3, 5, -1, 0, 6, 10, 0, 0, 1, 18, 0), createShadow(0, 4, 5, -2, 0, 7, 10, 1, 0, 2, 16, 1), createShadow(0, 5, 5, -3, 0, 8, 10, 1, 0, 3, 14, 2), createShadow(0, 5, 6, -3, 0, 9, 12, 1, 0, 3, 16, 2), createShadow(0, 6, 6, -3, 0, 10, 14, 1, 0, 4, 18, 3), createShadow(0, 6, 7, -4, 0, 11, 15, 1, 0, 4, 20, 3), createShadow(0, 7, 8, -4, 0, 12, 17, 2, 0, 5, 22, 4), createShadow(0, 7, 8, -4, 0, 13, 19, 2, 0, 5, 24, 4), createShadow(0, 7, 9, -4, 0, 14, 21, 2, 0, 5, 26, 4), createShadow(0, 8, 9, -5, 0, 15, 22, 2, 0, 6, 28, 5), createShadow(0, 8, 10, -5, 0, 16, 24, 2, 0, 6, 30, 5), createShadow(0, 8, 11, -5, 0, 17, 26, 2, 0, 6, 32, 5), createShadow(0, 9, 11, -5, 0, 18, 28, 2, 0, 7, 34, 6), createShadow(0, 9, 12, -6, 0, 19, 29, 2, 0, 7, 36, 6), createShadow(0, 10, 13, -6, 0, 20, 31, 3, 0, 8, 38, 7), createShadow(0, 10, 13, -6, 0, 21, 33, 3, 0, 8, 40, 7), createShadow(0, 10, 14, -6, 0, 22, 35, 3, 0, 8, 42, 7), createShadow(0, 11, 14, -7, 0, 23, 36, 3, 0, 9, 44, 8), createShadow(0, 11, 15, -7, 0, 24, 38, 3, 0, 9, 46, 8)];\nexport default shadows;","import _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nconst _excluded = [\"duration\", \"easing\", \"delay\"];\n// Follow https://material.google.com/motion/duration-easing.html#duration-easing-natural-easing-curves\n// to learn the context in which each easing should be used.\nexport const easing = {\n // This is the most common easing curve.\n easeInOut: 'cubic-bezier(0.4, 0, 0.2, 1)',\n // Objects enter the screen at full velocity from off-screen and\n // slowly decelerate to a resting point.\n easeOut: 'cubic-bezier(0.0, 0, 0.2, 1)',\n // Objects leave the screen at full velocity. They do not decelerate when off-screen.\n easeIn: 'cubic-bezier(0.4, 0, 1, 1)',\n // The sharp curve is used by objects that may return to the screen at any time.\n sharp: 'cubic-bezier(0.4, 0, 0.6, 1)'\n};\n\n// Follow https://m2.material.io/guidelines/motion/duration-easing.html#duration-easing-common-durations\n// to learn when use what timing\nexport const duration = {\n shortest: 150,\n shorter: 200,\n short: 250,\n // most basic recommended timing\n standard: 300,\n // this is to be used in complex animations\n complex: 375,\n // recommended when something is entering screen\n enteringScreen: 225,\n // recommended when something is leaving screen\n leavingScreen: 195\n};\nfunction formatMs(milliseconds) {\n return `${Math.round(milliseconds)}ms`;\n}\nfunction getAutoHeightDuration(height) {\n if (!height) {\n return 0;\n }\n const constant = height / 36;\n\n // https://www.wolframalpha.com/input/?i=(4+%2B+15+*+(x+%2F+36+)+**+0.25+%2B+(x+%2F+36)+%2F+5)+*+10\n return Math.round((4 + 15 * constant ** 0.25 + constant / 5) * 10);\n}\nexport default function createTransitions(inputTransitions) {\n const mergedEasing = _extends({}, easing, inputTransitions.easing);\n const mergedDuration = _extends({}, duration, inputTransitions.duration);\n const create = (props = ['all'], options = {}) => {\n const {\n duration: durationOption = mergedDuration.standard,\n easing: easingOption = mergedEasing.easeInOut,\n delay = 0\n } = options,\n other = _objectWithoutPropertiesLoose(options, _excluded);\n if (process.env.NODE_ENV !== 'production') {\n const isString = value => typeof value === 'string';\n // IE11 support, replace with Number.isNaN\n // eslint-disable-next-line no-restricted-globals\n const isNumber = value => !isNaN(parseFloat(value));\n if (!isString(props) && !Array.isArray(props)) {\n console.error('MUI: Argument \"props\" must be a string or Array.');\n }\n if (!isNumber(durationOption) && !isString(durationOption)) {\n console.error(`MUI: Argument \"duration\" must be a number or a string but found ${durationOption}.`);\n }\n if (!isString(easingOption)) {\n console.error('MUI: Argument \"easing\" must be a string.');\n }\n if (!isNumber(delay) && !isString(delay)) {\n console.error('MUI: Argument \"delay\" must be a number or a string.');\n }\n if (typeof options !== 'object') {\n console.error(['MUI: Secong argument of transition.create must be an object.', \"Arguments should be either `create('prop1', options)` or `create(['prop1', 'prop2'], options)`\"].join('\\n'));\n }\n if (Object.keys(other).length !== 0) {\n console.error(`MUI: Unrecognized argument(s) [${Object.keys(other).join(',')}].`);\n }\n }\n return (Array.isArray(props) ? props : [props]).map(animatedProp => `${animatedProp} ${typeof durationOption === 'string' ? durationOption : formatMs(durationOption)} ${easingOption} ${typeof delay === 'string' ? delay : formatMs(delay)}`).join(',');\n };\n return _extends({\n getAutoHeightDuration,\n create\n }, inputTransitions, {\n easing: mergedEasing,\n duration: mergedDuration\n });\n}","// We need to centralize the zIndex definitions as they work\n// like global values in the browser.\nconst zIndex = {\n mobileStepper: 1000,\n fab: 1050,\n speedDial: 1050,\n appBar: 1100,\n drawer: 1200,\n modal: 1300,\n snackbar: 1400,\n tooltip: 1500\n};\nexport default zIndex;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\nconst _excluded = [\"breakpoints\", \"mixins\", \"spacing\", \"palette\", \"transitions\", \"typography\", \"shape\"];\nimport { deepmerge } from '@mui/utils';\nimport { createTheme as systemCreateTheme, unstable_defaultSxConfig as defaultSxConfig, unstable_styleFunctionSx as styleFunctionSx } from '@mui/system';\nimport generateUtilityClass from '@mui/utils/generateUtilityClass';\nimport createMixins from './createMixins';\nimport createPalette from './createPalette';\nimport createTypography from './createTypography';\nimport shadows from './shadows';\nimport createTransitions from './createTransitions';\nimport zIndex from './zIndex';\nfunction createTheme(options = {}, ...args) {\n const {\n mixins: mixinsInput = {},\n palette: paletteInput = {},\n transitions: transitionsInput = {},\n typography: typographyInput = {}\n } = options,\n other = _objectWithoutPropertiesLoose(options, _excluded);\n if (options.vars) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: \\`vars\\` is a private field used for CSS variables support.\nPlease use another name.` : _formatMuiErrorMessage(18));\n }\n const palette = createPalette(paletteInput);\n const systemTheme = systemCreateTheme(options);\n let muiTheme = deepmerge(systemTheme, {\n mixins: createMixins(systemTheme.breakpoints, mixinsInput),\n palette,\n // Don't use [...shadows] until you've verified its transpiled code is not invoking the iterator protocol.\n shadows: shadows.slice(),\n typography: createTypography(palette, typographyInput),\n transitions: createTransitions(transitionsInput),\n zIndex: _extends({}, zIndex)\n });\n muiTheme = deepmerge(muiTheme, other);\n muiTheme = args.reduce((acc, argument) => deepmerge(acc, argument), muiTheme);\n if (process.env.NODE_ENV !== 'production') {\n // TODO v6: Refactor to use globalStateClassesMapping from @mui/utils once `readOnly` state class is used in Rating component.\n const stateClasses = ['active', 'checked', 'completed', 'disabled', 'error', 'expanded', 'focused', 'focusVisible', 'required', 'selected'];\n const traverse = (node, component) => {\n let key;\n\n // eslint-disable-next-line guard-for-in, no-restricted-syntax\n for (key in node) {\n const child = node[key];\n if (stateClasses.indexOf(key) !== -1 && Object.keys(child).length > 0) {\n if (process.env.NODE_ENV !== 'production') {\n const stateClass = generateUtilityClass('', key);\n console.error([`MUI: The \\`${component}\\` component increases ` + `the CSS specificity of the \\`${key}\\` internal state.`, 'You can not override it like this: ', JSON.stringify(node, null, 2), '', `Instead, you need to use the '&.${stateClass}' syntax:`, JSON.stringify({\n root: {\n [`&.${stateClass}`]: child\n }\n }, null, 2), '', 'https://mui.com/r/state-classes-guide'].join('\\n'));\n }\n // Remove the style to prevent global conflicts.\n node[key] = {};\n }\n }\n };\n Object.keys(muiTheme.components).forEach(component => {\n const styleOverrides = muiTheme.components[component].styleOverrides;\n if (styleOverrides && component.indexOf('Mui') === 0) {\n traverse(styleOverrides, component);\n }\n });\n }\n muiTheme.unstable_sxConfig = _extends({}, defaultSxConfig, other == null ? void 0 : other.unstable_sxConfig);\n muiTheme.unstable_sx = function sx(props) {\n return styleFunctionSx({\n sx: props,\n theme: this\n });\n };\n return muiTheme;\n}\nlet warnedOnce = false;\nexport function createMuiTheme(...args) {\n if (process.env.NODE_ENV !== 'production') {\n if (!warnedOnce) {\n warnedOnce = true;\n console.error(['MUI: the createMuiTheme function was renamed to createTheme.', '', \"You should use `import { createTheme } from '@mui/material/styles'`\"].join('\\n'));\n }\n }\n return createTheme(...args);\n}\nexport default createTheme;","'use client';\n\nimport createTheme from './createTheme';\nconst defaultTheme = createTheme();\nexport default defaultTheme;","export default '$$material';","'use client';\n\nimport { useThemeProps as systemUseThemeProps } from '@mui/system';\nimport defaultTheme from './defaultTheme';\nimport THEME_ID from './identifier';\nexport default function useThemeProps({\n props,\n name\n}) {\n return systemUseThemeProps({\n props,\n name,\n defaultTheme,\n themeId: THEME_ID\n });\n}","'use client';\n\nimport { createStyled, shouldForwardProp } from '@mui/system';\nimport defaultTheme from './defaultTheme';\nimport THEME_ID from './identifier';\nexport const rootShouldForwardProp = prop => shouldForwardProp(prop) && prop !== 'classes';\nexport const slotShouldForwardProp = shouldForwardProp;\nconst styled = createStyled({\n themeId: THEME_ID,\n defaultTheme,\n rootShouldForwardProp\n});\nexport default styled;","import generateUtilityClasses from '@mui/utils/generateUtilityClasses';\nimport generateUtilityClass from '@mui/utils/generateUtilityClass';\nexport function getSvgIconUtilityClass(slot) {\n return generateUtilityClass('MuiSvgIcon', slot);\n}\nconst svgIconClasses = generateUtilityClasses('MuiSvgIcon', ['root', 'colorPrimary', 'colorSecondary', 'colorAction', 'colorError', 'colorDisabled', 'fontSizeInherit', 'fontSizeSmall', 'fontSizeMedium', 'fontSizeLarge']);\nexport default svgIconClasses;","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"children\", \"className\", \"color\", \"component\", \"fontSize\", \"htmlColor\", \"inheritViewBox\", \"titleAccess\", \"viewBox\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport clsx from 'clsx';\nimport { unstable_composeClasses as composeClasses } from '@mui/base/composeClasses';\nimport capitalize from '../utils/capitalize';\nimport useThemeProps from '../styles/useThemeProps';\nimport styled from '../styles/styled';\nimport { getSvgIconUtilityClass } from './svgIconClasses';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nimport { jsxs as _jsxs } from \"react/jsx-runtime\";\nconst useUtilityClasses = ownerState => {\n const {\n color,\n fontSize,\n classes\n } = ownerState;\n const slots = {\n root: ['root', color !== 'inherit' && `color${capitalize(color)}`, `fontSize${capitalize(fontSize)}`]\n };\n return composeClasses(slots, getSvgIconUtilityClass, classes);\n};\nconst SvgIconRoot = styled('svg', {\n name: 'MuiSvgIcon',\n slot: 'Root',\n overridesResolver: (props, styles) => {\n const {\n ownerState\n } = props;\n return [styles.root, ownerState.color !== 'inherit' && styles[`color${capitalize(ownerState.color)}`], styles[`fontSize${capitalize(ownerState.fontSize)}`]];\n }\n})(({\n theme,\n ownerState\n}) => {\n var _theme$transitions, _theme$transitions$cr, _theme$transitions2, _theme$typography, _theme$typography$pxT, _theme$typography2, _theme$typography2$px, _theme$typography3, _theme$typography3$px, _palette$ownerState$c, _palette, _palette2, _palette3;\n return {\n userSelect: 'none',\n width: '1em',\n height: '1em',\n display: 'inline-block',\n // the will define the property that has `currentColor`\n // e.g. heroicons uses fill=\"none\" and stroke=\"currentColor\"\n fill: ownerState.hasSvgAsChild ? undefined : 'currentColor',\n flexShrink: 0,\n transition: (_theme$transitions = theme.transitions) == null || (_theme$transitions$cr = _theme$transitions.create) == null ? void 0 : _theme$transitions$cr.call(_theme$transitions, 'fill', {\n duration: (_theme$transitions2 = theme.transitions) == null || (_theme$transitions2 = _theme$transitions2.duration) == null ? void 0 : _theme$transitions2.shorter\n }),\n fontSize: {\n inherit: 'inherit',\n small: ((_theme$typography = theme.typography) == null || (_theme$typography$pxT = _theme$typography.pxToRem) == null ? void 0 : _theme$typography$pxT.call(_theme$typography, 20)) || '1.25rem',\n medium: ((_theme$typography2 = theme.typography) == null || (_theme$typography2$px = _theme$typography2.pxToRem) == null ? void 0 : _theme$typography2$px.call(_theme$typography2, 24)) || '1.5rem',\n large: ((_theme$typography3 = theme.typography) == null || (_theme$typography3$px = _theme$typography3.pxToRem) == null ? void 0 : _theme$typography3$px.call(_theme$typography3, 35)) || '2.1875rem'\n }[ownerState.fontSize],\n // TODO v5 deprecate, v6 remove for sx\n color: (_palette$ownerState$c = (_palette = (theme.vars || theme).palette) == null || (_palette = _palette[ownerState.color]) == null ? void 0 : _palette.main) != null ? _palette$ownerState$c : {\n action: (_palette2 = (theme.vars || theme).palette) == null || (_palette2 = _palette2.action) == null ? void 0 : _palette2.active,\n disabled: (_palette3 = (theme.vars || theme).palette) == null || (_palette3 = _palette3.action) == null ? void 0 : _palette3.disabled,\n inherit: undefined\n }[ownerState.color]\n };\n});\nconst SvgIcon = /*#__PURE__*/React.forwardRef(function SvgIcon(inProps, ref) {\n const props = useThemeProps({\n props: inProps,\n name: 'MuiSvgIcon'\n });\n const {\n children,\n className,\n color = 'inherit',\n component = 'svg',\n fontSize = 'medium',\n htmlColor,\n inheritViewBox = false,\n titleAccess,\n viewBox = '0 0 24 24'\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const hasSvgAsChild = /*#__PURE__*/React.isValidElement(children) && children.type === 'svg';\n const ownerState = _extends({}, props, {\n color,\n component,\n fontSize,\n instanceFontSize: inProps.fontSize,\n inheritViewBox,\n viewBox,\n hasSvgAsChild\n });\n const more = {};\n if (!inheritViewBox) {\n more.viewBox = viewBox;\n }\n const classes = useUtilityClasses(ownerState);\n return /*#__PURE__*/_jsxs(SvgIconRoot, _extends({\n as: component,\n className: clsx(classes.root, className),\n focusable: \"false\",\n color: htmlColor,\n \"aria-hidden\": titleAccess ? undefined : true,\n role: titleAccess ? 'img' : undefined,\n ref: ref\n }, more, other, hasSvgAsChild && children.props, {\n ownerState: ownerState,\n children: [hasSvgAsChild ? children.props.children : children, titleAccess ? /*#__PURE__*/_jsx(\"title\", {\n children: titleAccess\n }) : null]\n }));\n});\nprocess.env.NODE_ENV !== \"production\" ? SvgIcon.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the d.ts file and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * Node passed into the SVG element.\n */\n children: PropTypes.node,\n /**\n * Override or extend the styles applied to the component.\n */\n classes: PropTypes.object,\n /**\n * @ignore\n */\n className: PropTypes.string,\n /**\n * The color of the component.\n * It supports both default and custom theme colors, which can be added as shown in the\n * [palette customization guide](https://mui.com/material-ui/customization/palette/#custom-colors).\n * You can use the `htmlColor` prop to apply a color attribute to the SVG element.\n * @default 'inherit'\n */\n color: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.oneOf(['inherit', 'action', 'disabled', 'primary', 'secondary', 'error', 'info', 'success', 'warning']), PropTypes.string]),\n /**\n * The component used for the root node.\n * Either a string to use a HTML element or a component.\n */\n component: PropTypes.elementType,\n /**\n * The fontSize applied to the icon. Defaults to 24px, but can be configure to inherit font size.\n * @default 'medium'\n */\n fontSize: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.oneOf(['inherit', 'large', 'medium', 'small']), PropTypes.string]),\n /**\n * Applies a color attribute to the SVG element.\n */\n htmlColor: PropTypes.string,\n /**\n * If `true`, the root node will inherit the custom `component`'s viewBox and the `viewBox`\n * prop will be ignored.\n * Useful when you want to reference a custom `component` and have `SvgIcon` pass that\n * `component`'s viewBox to the root node.\n * @default false\n */\n inheritViewBox: PropTypes.bool,\n /**\n * The shape-rendering attribute. The behavior of the different options is described on the\n * [MDN Web Docs](https://developer.mozilla.org/en-US/docs/Web/SVG/Attribute/shape-rendering).\n * If you are having issues with blurry icons you should investigate this prop.\n */\n shapeRendering: PropTypes.string,\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Provides a human-readable title for the element that contains it.\n * https://www.w3.org/TR/SVG-access/#Equivalent\n */\n titleAccess: PropTypes.string,\n /**\n * Allows you to redefine what the coordinates without units mean inside an SVG element.\n * For example, if the SVG element is 500 (width) by 200 (height),\n * and you pass viewBox=\"0 0 50 20\",\n * this means that the coordinates inside the SVG will go from the top left corner (0,0)\n * to bottom right (50,20) and each unit will be worth 10px.\n * @default '0 0 24 24'\n */\n viewBox: PropTypes.string\n} : void 0;\nSvgIcon.muiName = 'SvgIcon';\nexport default SvgIcon;","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport * as React from 'react';\nimport SvgIcon from '../SvgIcon';\n\n/**\n * Private module reserved for @mui packages.\n */\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nexport default function createSvgIcon(path, displayName) {\n function Component(props, ref) {\n return /*#__PURE__*/_jsx(SvgIcon, _extends({\n \"data-testid\": `${displayName}Icon`,\n ref: ref\n }, props, {\n children: path\n }));\n }\n if (process.env.NODE_ENV !== 'production') {\n // Need to set `displayName` on the inner component for React.memo.\n // React prior to 16.14 ignores `displayName` on the wrapper.\n Component.displayName = `${displayName}Icon`;\n }\n Component.muiName = SvgIcon.muiName;\n return /*#__PURE__*/React.memo( /*#__PURE__*/React.forwardRef(Component));\n}","'use client';\n\nimport { unstable_ClassNameGenerator as ClassNameGenerator } from '@mui/base/ClassNameGenerator';\nexport { default as capitalize } from './capitalize';\nexport { default as createChainedFunction } from './createChainedFunction';\nexport { default as createSvgIcon } from './createSvgIcon';\nexport { default as debounce } from './debounce';\nexport { default as deprecatedPropType } from './deprecatedPropType';\nexport { default as isMuiElement } from './isMuiElement';\nexport { default as ownerDocument } from './ownerDocument';\nexport { default as ownerWindow } from './ownerWindow';\nexport { default as requirePropFactory } from './requirePropFactory';\nexport { default as setRef } from './setRef';\nexport { default as unstable_useEnhancedEffect } from './useEnhancedEffect';\nexport { default as unstable_useId } from './useId';\nexport { default as unsupportedProp } from './unsupportedProp';\nexport { default as useControlled } from './useControlled';\nexport { default as useEventCallback } from './useEventCallback';\nexport { default as useForkRef } from './useForkRef';\nexport { default as useIsFocusVisible } from './useIsFocusVisible';\n// TODO: remove this export once ClassNameGenerator is stable\n// eslint-disable-next-line @typescript-eslint/naming-convention\nexport const unstable_ClassNameGenerator = {\n configure: generator => {\n if (process.env.NODE_ENV !== 'production') {\n console.warn(['MUI: `ClassNameGenerator` import from `@mui/material/utils` is outdated and might cause unexpected issues.', '', \"You should use `import { unstable_ClassNameGenerator } from '@mui/material/className'` instead\", '', 'The detail of the issue: https://github.com/mui/material-ui/issues/30011#issuecomment-1024993401', '', 'The updated documentation: https://mui.com/guides/classname-generator/'].join('\\n'));\n }\n ClassNameGenerator.configure(generator);\n }\n};","\"use strict\";\n'use client';\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nObject.defineProperty(exports, \"default\", {\n enumerable: true,\n get: function () {\n return _utils.createSvgIcon;\n }\n});\nvar _utils = require(\"@mui/material/utils\");","\"use strict\";\n\"use client\";\n\nvar _interopRequireDefault = require(\"@babel/runtime/helpers/interopRequireDefault\");\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = void 0;\nvar _createSvgIcon = _interopRequireDefault(require(\"./utils/createSvgIcon\"));\nvar _jsxRuntime = require(\"react/jsx-runtime\");\nvar _default = exports.default = (0, _createSvgIcon.default)( /*#__PURE__*/(0, _jsxRuntime.jsx)(\"path\", {\n d: \"m10 17 5-5-5-5z\"\n}), 'ArrowRight');","/**\n * Determines if a given element is a DOM element name (i.e. not a React component).\n */\nexport function isHostComponent(element) {\n return typeof element === 'string';\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport { isHostComponent } from './isHostComponent';\n\n/**\n * Type of the ownerState based on the type of an element it applies to.\n * This resolves to the provided OwnerState for React components and `undefined` for host components.\n * Falls back to `OwnerState | undefined` when the exact type can't be determined in development time.\n */\n\n/**\n * Appends the ownerState object to the props, merging with the existing one if necessary.\n *\n * @param elementType Type of the element that owns the `existingProps`. If the element is a DOM node or undefined, `ownerState` is not applied.\n * @param otherProps Props of the element.\n * @param ownerState\n */\nexport function appendOwnerState(elementType, otherProps, ownerState) {\n if (elementType === undefined || isHostComponent(elementType)) {\n return otherProps;\n }\n return _extends({}, otherProps, {\n ownerState: _extends({}, otherProps.ownerState, ownerState)\n });\n}","'use client';\n\nimport * as React from 'react';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nconst defaultContextValue = {\n disableDefaultClasses: false\n};\nconst ClassNameConfiguratorContext = /*#__PURE__*/React.createContext(defaultContextValue);\n/**\n * @ignore - internal hook.\n *\n * Wraps the `generateUtilityClass` function and controls how the classes are generated.\n * Currently it only affects whether the classes are applied or not.\n *\n * @returns Function to be called with the `generateUtilityClass` function specific to a component to generate the classes.\n */\nexport function useClassNamesOverride(generateUtilityClass) {\n const {\n disableDefaultClasses\n } = React.useContext(ClassNameConfiguratorContext);\n return slot => {\n if (disableDefaultClasses) {\n return '';\n }\n return generateUtilityClass(slot);\n };\n}\n\n/**\n * Allows to configure the components within to not apply any built-in classes.\n */\nexport function ClassNameConfigurator(props) {\n const {\n disableDefaultClasses,\n children\n } = props;\n const contextValue = React.useMemo(() => ({\n disableDefaultClasses: disableDefaultClasses != null ? disableDefaultClasses : false\n }), [disableDefaultClasses]);\n return /*#__PURE__*/_jsx(ClassNameConfiguratorContext.Provider, {\n value: contextValue,\n children: children\n });\n}","/**\n * Extracts event handlers from a given object.\n * A prop is considered an event handler if it is a function and its name starts with `on`.\n *\n * @param object An object to extract event handlers from.\n * @param excludeKeys An array of keys to exclude from the returned object.\n */\nexport function extractEventHandlers(object, excludeKeys = []) {\n if (object === undefined) {\n return {};\n }\n const result = {};\n Object.keys(object).filter(prop => prop.match(/^on[A-Z]/) && typeof object[prop] === 'function' && !excludeKeys.includes(prop)).forEach(prop => {\n result[prop] = object[prop];\n });\n return result;\n}","/**\n * If `componentProps` is a function, calls it with the provided `ownerState`.\n * Otherwise, just returns `componentProps`.\n */\nexport function resolveComponentProps(componentProps, ownerState, slotState) {\n if (typeof componentProps === 'function') {\n return componentProps(ownerState, slotState);\n }\n return componentProps;\n}","/**\n * Removes event handlers from the given object.\n * A field is considered an event handler if it is a function with a name beginning with `on`.\n *\n * @param object Object to remove event handlers from.\n * @returns Object with event handlers removed.\n */\nexport function omitEventHandlers(object) {\n if (object === undefined) {\n return {};\n }\n const result = {};\n Object.keys(object).filter(prop => !(prop.match(/^on[A-Z]/) && typeof object[prop] === 'function')).forEach(prop => {\n result[prop] = object[prop];\n });\n return result;\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport clsx from 'clsx';\nimport { extractEventHandlers } from './extractEventHandlers';\nimport { omitEventHandlers } from './omitEventHandlers';\n/**\n * Merges the slot component internal props (usually coming from a hook)\n * with the externally provided ones.\n *\n * The merge order is (the latter overrides the former):\n * 1. The internal props (specified as a getter function to work with get*Props hook result)\n * 2. Additional props (specified internally on a Base UI component)\n * 3. External props specified on the owner component. These should only be used on a root slot.\n * 4. External props specified in the `slotProps.*` prop.\n * 5. The `className` prop - combined from all the above.\n * @param parameters\n * @returns\n */\nexport function mergeSlotProps(parameters) {\n const {\n getSlotProps,\n additionalProps,\n externalSlotProps,\n externalForwardedProps,\n className\n } = parameters;\n if (!getSlotProps) {\n // The simpler case - getSlotProps is not defined, so no internal event handlers are defined,\n // so we can simply merge all the props without having to worry about extracting event handlers.\n const joinedClasses = clsx(additionalProps == null ? void 0 : additionalProps.className, className, externalForwardedProps == null ? void 0 : externalForwardedProps.className, externalSlotProps == null ? void 0 : externalSlotProps.className);\n const mergedStyle = _extends({}, additionalProps == null ? void 0 : additionalProps.style, externalForwardedProps == null ? void 0 : externalForwardedProps.style, externalSlotProps == null ? void 0 : externalSlotProps.style);\n const props = _extends({}, additionalProps, externalForwardedProps, externalSlotProps);\n if (joinedClasses.length > 0) {\n props.className = joinedClasses;\n }\n if (Object.keys(mergedStyle).length > 0) {\n props.style = mergedStyle;\n }\n return {\n props,\n internalRef: undefined\n };\n }\n\n // In this case, getSlotProps is responsible for calling the external event handlers.\n // We don't need to include them in the merged props because of this.\n\n const eventHandlers = extractEventHandlers(_extends({}, externalForwardedProps, externalSlotProps));\n const componentsPropsWithoutEventHandlers = omitEventHandlers(externalSlotProps);\n const otherPropsWithoutEventHandlers = omitEventHandlers(externalForwardedProps);\n const internalSlotProps = getSlotProps(eventHandlers);\n\n // The order of classes is important here.\n // Emotion (that we use in libraries consuming Base UI) depends on this order\n // to properly override style. It requires the most important classes to be last\n // (see https://github.com/mui/material-ui/pull/33205) for the related discussion.\n const joinedClasses = clsx(internalSlotProps == null ? void 0 : internalSlotProps.className, additionalProps == null ? void 0 : additionalProps.className, className, externalForwardedProps == null ? void 0 : externalForwardedProps.className, externalSlotProps == null ? void 0 : externalSlotProps.className);\n const mergedStyle = _extends({}, internalSlotProps == null ? void 0 : internalSlotProps.style, additionalProps == null ? void 0 : additionalProps.style, externalForwardedProps == null ? void 0 : externalForwardedProps.style, externalSlotProps == null ? void 0 : externalSlotProps.style);\n const props = _extends({}, internalSlotProps, additionalProps, otherPropsWithoutEventHandlers, componentsPropsWithoutEventHandlers);\n if (joinedClasses.length > 0) {\n props.className = joinedClasses;\n }\n if (Object.keys(mergedStyle).length > 0) {\n props.style = mergedStyle;\n }\n return {\n props,\n internalRef: internalSlotProps.ref\n };\n}","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"elementType\", \"externalSlotProps\", \"ownerState\", \"skipResolvingSlotProps\"];\nimport { unstable_useForkRef as useForkRef } from '@mui/utils';\nimport { appendOwnerState } from './appendOwnerState';\nimport { mergeSlotProps } from './mergeSlotProps';\nimport { resolveComponentProps } from './resolveComponentProps';\n/**\n * @ignore - do not document.\n * Builds the props to be passed into the slot of an unstyled component.\n * It merges the internal props of the component with the ones supplied by the user, allowing to customize the behavior.\n * If the slot component is not a host component, it also merges in the `ownerState`.\n *\n * @param parameters.getSlotProps - A function that returns the props to be passed to the slot component.\n */\nexport function useSlotProps(parameters) {\n var _parameters$additiona;\n const {\n elementType,\n externalSlotProps,\n ownerState,\n skipResolvingSlotProps = false\n } = parameters,\n rest = _objectWithoutPropertiesLoose(parameters, _excluded);\n const resolvedComponentsProps = skipResolvingSlotProps ? {} : resolveComponentProps(externalSlotProps, ownerState);\n const {\n props: mergedProps,\n internalRef\n } = mergeSlotProps(_extends({}, rest, {\n externalSlotProps: resolvedComponentsProps\n }));\n const ref = useForkRef(internalRef, resolvedComponentsProps == null ? void 0 : resolvedComponentsProps.ref, (_parameters$additiona = parameters.additionalProps) == null ? void 0 : _parameters$additiona.ref);\n const props = appendOwnerState(elementType, _extends({}, mergedProps, {\n ref\n }), ownerState);\n return props;\n}","import { globalStateClasses } from '@mui/utils/generateUtilityClass';\nconst GLOBAL_CLASS_PREFIX = 'base';\nfunction buildStateClass(state) {\n return `${GLOBAL_CLASS_PREFIX}--${state}`;\n}\nfunction buildSlotClass(componentName, slot) {\n return `${GLOBAL_CLASS_PREFIX}-${componentName}-${slot}`;\n}\nexport function generateUtilityClass(componentName, slot) {\n const globalStateClass = globalStateClasses[slot];\n return globalStateClass ? buildStateClass(globalStateClass) : buildSlotClass(componentName, slot);\n}\nexport function isGlobalState(slot) {\n return globalStateClasses[slot] !== undefined;\n}","import { generateUtilityClass } from '../generateUtilityClass';\nexport function generateUtilityClasses(componentName, slots) {\n const result = {};\n slots.forEach(slot => {\n result[slot] = generateUtilityClass(componentName, slot);\n });\n return result;\n}","'use client';\n\nimport * as React from 'react';\nimport * as ReactDOM from 'react-dom';\nimport PropTypes from 'prop-types';\nimport { exactProp, HTMLElementType, unstable_useEnhancedEffect as useEnhancedEffect, unstable_useForkRef as useForkRef, unstable_setRef as setRef } from '@mui/utils';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nfunction getContainer(container) {\n return typeof container === 'function' ? container() : container;\n}\n\n/**\n * Portals provide a first-class way to render children into a DOM node\n * that exists outside the DOM hierarchy of the parent component.\n *\n * Demos:\n *\n * - [Portal](https://mui.com/base-ui/react-portal/)\n *\n * API:\n *\n * - [Portal API](https://mui.com/base-ui/react-portal/components-api/#portal)\n */\nconst Portal = /*#__PURE__*/React.forwardRef(function Portal(props, forwardedRef) {\n const {\n children,\n container,\n disablePortal = false\n } = props;\n const [mountNode, setMountNode] = React.useState(null);\n // @ts-expect-error TODO upstream fix\n const handleRef = useForkRef( /*#__PURE__*/React.isValidElement(children) ? children.ref : null, forwardedRef);\n useEnhancedEffect(() => {\n if (!disablePortal) {\n setMountNode(getContainer(container) || document.body);\n }\n }, [container, disablePortal]);\n useEnhancedEffect(() => {\n if (mountNode && !disablePortal) {\n setRef(forwardedRef, mountNode);\n return () => {\n setRef(forwardedRef, null);\n };\n }\n return undefined;\n }, [forwardedRef, mountNode, disablePortal]);\n if (disablePortal) {\n if ( /*#__PURE__*/React.isValidElement(children)) {\n const newProps = {\n ref: handleRef\n };\n return /*#__PURE__*/React.cloneElement(children, newProps);\n }\n return /*#__PURE__*/_jsx(React.Fragment, {\n children: children\n });\n }\n return /*#__PURE__*/_jsx(React.Fragment, {\n children: mountNode ? /*#__PURE__*/ReactDOM.createPortal(children, mountNode) : mountNode\n });\n});\nprocess.env.NODE_ENV !== \"production\" ? Portal.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * The children to render into the `container`.\n */\n children: PropTypes.node,\n /**\n * An HTML element or function that returns one.\n * The `container` will have the portal children appended to it.\n *\n * You can also provide a callback, which is called in a React layout effect.\n * This lets you set the container from a ref, and also makes server-side rendering possible.\n *\n * By default, it uses the body of the top-level document object,\n * so it's simply `document.body` most of the time.\n */\n container: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.func]),\n /**\n * The `children` will be under the DOM hierarchy of the parent component.\n * @default false\n */\n disablePortal: PropTypes.bool\n} : void 0;\nif (process.env.NODE_ENV !== 'production') {\n // eslint-disable-next-line\n Portal['propTypes' + ''] = exactProp(Portal.propTypes);\n}\nexport { Portal };","export var top = 'top';\nexport var bottom = 'bottom';\nexport var right = 'right';\nexport var left = 'left';\nexport var auto = 'auto';\nexport var basePlacements = [top, bottom, right, left];\nexport var start = 'start';\nexport var end = 'end';\nexport var clippingParents = 'clippingParents';\nexport var viewport = 'viewport';\nexport var popper = 'popper';\nexport var reference = 'reference';\nexport var variationPlacements = /*#__PURE__*/basePlacements.reduce(function (acc, placement) {\n return acc.concat([placement + \"-\" + start, placement + \"-\" + end]);\n}, []);\nexport var placements = /*#__PURE__*/[].concat(basePlacements, [auto]).reduce(function (acc, placement) {\n return acc.concat([placement, placement + \"-\" + start, placement + \"-\" + end]);\n}, []); // modifiers that need to read the DOM\n\nexport var beforeRead = 'beforeRead';\nexport var read = 'read';\nexport var afterRead = 'afterRead'; // pure-logic modifiers\n\nexport var beforeMain = 'beforeMain';\nexport var main = 'main';\nexport var afterMain = 'afterMain'; // modifier with the purpose to write to the DOM (or write into a framework state)\n\nexport var beforeWrite = 'beforeWrite';\nexport var write = 'write';\nexport var afterWrite = 'afterWrite';\nexport var modifierPhases = [beforeRead, read, afterRead, beforeMain, main, afterMain, beforeWrite, write, afterWrite];","export default function getNodeName(element) {\n return element ? (element.nodeName || '').toLowerCase() : null;\n}","export default function getWindow(node) {\n if (node == null) {\n return window;\n }\n\n if (node.toString() !== '[object Window]') {\n var ownerDocument = node.ownerDocument;\n return ownerDocument ? ownerDocument.defaultView || window : window;\n }\n\n return node;\n}","import getWindow from \"./getWindow.js\";\n\nfunction isElement(node) {\n var OwnElement = getWindow(node).Element;\n return node instanceof OwnElement || node instanceof Element;\n}\n\nfunction isHTMLElement(node) {\n var OwnElement = getWindow(node).HTMLElement;\n return node instanceof OwnElement || node instanceof HTMLElement;\n}\n\nfunction isShadowRoot(node) {\n // IE 11 has no ShadowRoot\n if (typeof ShadowRoot === 'undefined') {\n return false;\n }\n\n var OwnElement = getWindow(node).ShadowRoot;\n return node instanceof OwnElement || node instanceof ShadowRoot;\n}\n\nexport { isElement, isHTMLElement, isShadowRoot };","import getNodeName from \"../dom-utils/getNodeName.js\";\nimport { isHTMLElement } from \"../dom-utils/instanceOf.js\"; // This modifier takes the styles prepared by the `computeStyles` modifier\n// and applies them to the HTMLElements such as popper and arrow\n\nfunction applyStyles(_ref) {\n var state = _ref.state;\n Object.keys(state.elements).forEach(function (name) {\n var style = state.styles[name] || {};\n var attributes = state.attributes[name] || {};\n var element = state.elements[name]; // arrow is optional + virtual elements\n\n if (!isHTMLElement(element) || !getNodeName(element)) {\n return;\n } // Flow doesn't support to extend this property, but it's the most\n // effective way to apply styles to an HTMLElement\n // $FlowFixMe[cannot-write]\n\n\n Object.assign(element.style, style);\n Object.keys(attributes).forEach(function (name) {\n var value = attributes[name];\n\n if (value === false) {\n element.removeAttribute(name);\n } else {\n element.setAttribute(name, value === true ? '' : value);\n }\n });\n });\n}\n\nfunction effect(_ref2) {\n var state = _ref2.state;\n var initialStyles = {\n popper: {\n position: state.options.strategy,\n left: '0',\n top: '0',\n margin: '0'\n },\n arrow: {\n position: 'absolute'\n },\n reference: {}\n };\n Object.assign(state.elements.popper.style, initialStyles.popper);\n state.styles = initialStyles;\n\n if (state.elements.arrow) {\n Object.assign(state.elements.arrow.style, initialStyles.arrow);\n }\n\n return function () {\n Object.keys(state.elements).forEach(function (name) {\n var element = state.elements[name];\n var attributes = state.attributes[name] || {};\n var styleProperties = Object.keys(state.styles.hasOwnProperty(name) ? state.styles[name] : initialStyles[name]); // Set all values to an empty string to unset them\n\n var style = styleProperties.reduce(function (style, property) {\n style[property] = '';\n return style;\n }, {}); // arrow is optional + virtual elements\n\n if (!isHTMLElement(element) || !getNodeName(element)) {\n return;\n }\n\n Object.assign(element.style, style);\n Object.keys(attributes).forEach(function (attribute) {\n element.removeAttribute(attribute);\n });\n });\n };\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'applyStyles',\n enabled: true,\n phase: 'write',\n fn: applyStyles,\n effect: effect,\n requires: ['computeStyles']\n};","import { auto } from \"../enums.js\";\nexport default function getBasePlacement(placement) {\n return placement.split('-')[0];\n}","export var max = Math.max;\nexport var min = Math.min;\nexport var round = Math.round;","export default function getUAString() {\n var uaData = navigator.userAgentData;\n\n if (uaData != null && uaData.brands && Array.isArray(uaData.brands)) {\n return uaData.brands.map(function (item) {\n return item.brand + \"/\" + item.version;\n }).join(' ');\n }\n\n return navigator.userAgent;\n}","import getUAString from \"../utils/userAgent.js\";\nexport default function isLayoutViewport() {\n return !/^((?!chrome|android).)*safari/i.test(getUAString());\n}","import { isElement, isHTMLElement } from \"./instanceOf.js\";\nimport { round } from \"../utils/math.js\";\nimport getWindow from \"./getWindow.js\";\nimport isLayoutViewport from \"./isLayoutViewport.js\";\nexport default function getBoundingClientRect(element, includeScale, isFixedStrategy) {\n if (includeScale === void 0) {\n includeScale = false;\n }\n\n if (isFixedStrategy === void 0) {\n isFixedStrategy = false;\n }\n\n var clientRect = element.getBoundingClientRect();\n var scaleX = 1;\n var scaleY = 1;\n\n if (includeScale && isHTMLElement(element)) {\n scaleX = element.offsetWidth > 0 ? round(clientRect.width) / element.offsetWidth || 1 : 1;\n scaleY = element.offsetHeight > 0 ? round(clientRect.height) / element.offsetHeight || 1 : 1;\n }\n\n var _ref = isElement(element) ? getWindow(element) : window,\n visualViewport = _ref.visualViewport;\n\n var addVisualOffsets = !isLayoutViewport() && isFixedStrategy;\n var x = (clientRect.left + (addVisualOffsets && visualViewport ? visualViewport.offsetLeft : 0)) / scaleX;\n var y = (clientRect.top + (addVisualOffsets && visualViewport ? visualViewport.offsetTop : 0)) / scaleY;\n var width = clientRect.width / scaleX;\n var height = clientRect.height / scaleY;\n return {\n width: width,\n height: height,\n top: y,\n right: x + width,\n bottom: y + height,\n left: x,\n x: x,\n y: y\n };\n}","import getBoundingClientRect from \"./getBoundingClientRect.js\"; // Returns the layout rect of an element relative to its offsetParent. Layout\n// means it doesn't take into account transforms.\n\nexport default function getLayoutRect(element) {\n var clientRect = getBoundingClientRect(element); // Use the clientRect sizes if it's not been transformed.\n // Fixes https://github.com/popperjs/popper-core/issues/1223\n\n var width = element.offsetWidth;\n var height = element.offsetHeight;\n\n if (Math.abs(clientRect.width - width) <= 1) {\n width = clientRect.width;\n }\n\n if (Math.abs(clientRect.height - height) <= 1) {\n height = clientRect.height;\n }\n\n return {\n x: element.offsetLeft,\n y: element.offsetTop,\n width: width,\n height: height\n };\n}","import { isShadowRoot } from \"./instanceOf.js\";\nexport default function contains(parent, child) {\n var rootNode = child.getRootNode && child.getRootNode(); // First, attempt with faster native method\n\n if (parent.contains(child)) {\n return true;\n } // then fallback to custom implementation with Shadow DOM support\n else if (rootNode && isShadowRoot(rootNode)) {\n var next = child;\n\n do {\n if (next && parent.isSameNode(next)) {\n return true;\n } // $FlowFixMe[prop-missing]: need a better way to handle this...\n\n\n next = next.parentNode || next.host;\n } while (next);\n } // Give up, the result is false\n\n\n return false;\n}","import getWindow from \"./getWindow.js\";\nexport default function getComputedStyle(element) {\n return getWindow(element).getComputedStyle(element);\n}","import getNodeName from \"./getNodeName.js\";\nexport default function isTableElement(element) {\n return ['table', 'td', 'th'].indexOf(getNodeName(element)) >= 0;\n}","import { isElement } from \"./instanceOf.js\";\nexport default function getDocumentElement(element) {\n // $FlowFixMe[incompatible-return]: assume body is always available\n return ((isElement(element) ? element.ownerDocument : // $FlowFixMe[prop-missing]\n element.document) || window.document).documentElement;\n}","import getNodeName from \"./getNodeName.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport { isShadowRoot } from \"./instanceOf.js\";\nexport default function getParentNode(element) {\n if (getNodeName(element) === 'html') {\n return element;\n }\n\n return (// this is a quicker (but less type safe) way to save quite some bytes from the bundle\n // $FlowFixMe[incompatible-return]\n // $FlowFixMe[prop-missing]\n element.assignedSlot || // step into the shadow DOM of the parent of a slotted node\n element.parentNode || ( // DOM Element detected\n isShadowRoot(element) ? element.host : null) || // ShadowRoot detected\n // $FlowFixMe[incompatible-call]: HTMLElement is a Node\n getDocumentElement(element) // fallback\n\n );\n}","import getWindow from \"./getWindow.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport getComputedStyle from \"./getComputedStyle.js\";\nimport { isHTMLElement, isShadowRoot } from \"./instanceOf.js\";\nimport isTableElement from \"./isTableElement.js\";\nimport getParentNode from \"./getParentNode.js\";\nimport getUAString from \"../utils/userAgent.js\";\n\nfunction getTrueOffsetParent(element) {\n if (!isHTMLElement(element) || // https://github.com/popperjs/popper-core/issues/837\n getComputedStyle(element).position === 'fixed') {\n return null;\n }\n\n return element.offsetParent;\n} // `.offsetParent` reports `null` for fixed elements, while absolute elements\n// return the containing block\n\n\nfunction getContainingBlock(element) {\n var isFirefox = /firefox/i.test(getUAString());\n var isIE = /Trident/i.test(getUAString());\n\n if (isIE && isHTMLElement(element)) {\n // In IE 9, 10 and 11 fixed elements containing block is always established by the viewport\n var elementCss = getComputedStyle(element);\n\n if (elementCss.position === 'fixed') {\n return null;\n }\n }\n\n var currentNode = getParentNode(element);\n\n if (isShadowRoot(currentNode)) {\n currentNode = currentNode.host;\n }\n\n while (isHTMLElement(currentNode) && ['html', 'body'].indexOf(getNodeName(currentNode)) < 0) {\n var css = getComputedStyle(currentNode); // This is non-exhaustive but covers the most common CSS properties that\n // create a containing block.\n // https://developer.mozilla.org/en-US/docs/Web/CSS/Containing_block#identifying_the_containing_block\n\n if (css.transform !== 'none' || css.perspective !== 'none' || css.contain === 'paint' || ['transform', 'perspective'].indexOf(css.willChange) !== -1 || isFirefox && css.willChange === 'filter' || isFirefox && css.filter && css.filter !== 'none') {\n return currentNode;\n } else {\n currentNode = currentNode.parentNode;\n }\n }\n\n return null;\n} // Gets the closest ancestor positioned element. Handles some edge cases,\n// such as table ancestors and cross browser bugs.\n\n\nexport default function getOffsetParent(element) {\n var window = getWindow(element);\n var offsetParent = getTrueOffsetParent(element);\n\n while (offsetParent && isTableElement(offsetParent) && getComputedStyle(offsetParent).position === 'static') {\n offsetParent = getTrueOffsetParent(offsetParent);\n }\n\n if (offsetParent && (getNodeName(offsetParent) === 'html' || getNodeName(offsetParent) === 'body' && getComputedStyle(offsetParent).position === 'static')) {\n return window;\n }\n\n return offsetParent || getContainingBlock(element) || window;\n}","export default function getMainAxisFromPlacement(placement) {\n return ['top', 'bottom'].indexOf(placement) >= 0 ? 'x' : 'y';\n}","import { max as mathMax, min as mathMin } from \"./math.js\";\nexport function within(min, value, max) {\n return mathMax(min, mathMin(value, max));\n}\nexport function withinMaxClamp(min, value, max) {\n var v = within(min, value, max);\n return v > max ? max : v;\n}","export default function getFreshSideObject() {\n return {\n top: 0,\n right: 0,\n bottom: 0,\n left: 0\n };\n}","import getFreshSideObject from \"./getFreshSideObject.js\";\nexport default function mergePaddingObject(paddingObject) {\n return Object.assign({}, getFreshSideObject(), paddingObject);\n}","export default function expandToHashMap(value, keys) {\n return keys.reduce(function (hashMap, key) {\n hashMap[key] = value;\n return hashMap;\n }, {});\n}","import getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getLayoutRect from \"../dom-utils/getLayoutRect.js\";\nimport contains from \"../dom-utils/contains.js\";\nimport getOffsetParent from \"../dom-utils/getOffsetParent.js\";\nimport getMainAxisFromPlacement from \"../utils/getMainAxisFromPlacement.js\";\nimport { within } from \"../utils/within.js\";\nimport mergePaddingObject from \"../utils/mergePaddingObject.js\";\nimport expandToHashMap from \"../utils/expandToHashMap.js\";\nimport { left, right, basePlacements, top, bottom } from \"../enums.js\"; // eslint-disable-next-line import/no-unused-modules\n\nvar toPaddingObject = function toPaddingObject(padding, state) {\n padding = typeof padding === 'function' ? padding(Object.assign({}, state.rects, {\n placement: state.placement\n })) : padding;\n return mergePaddingObject(typeof padding !== 'number' ? padding : expandToHashMap(padding, basePlacements));\n};\n\nfunction arrow(_ref) {\n var _state$modifiersData$;\n\n var state = _ref.state,\n name = _ref.name,\n options = _ref.options;\n var arrowElement = state.elements.arrow;\n var popperOffsets = state.modifiersData.popperOffsets;\n var basePlacement = getBasePlacement(state.placement);\n var axis = getMainAxisFromPlacement(basePlacement);\n var isVertical = [left, right].indexOf(basePlacement) >= 0;\n var len = isVertical ? 'height' : 'width';\n\n if (!arrowElement || !popperOffsets) {\n return;\n }\n\n var paddingObject = toPaddingObject(options.padding, state);\n var arrowRect = getLayoutRect(arrowElement);\n var minProp = axis === 'y' ? top : left;\n var maxProp = axis === 'y' ? bottom : right;\n var endDiff = state.rects.reference[len] + state.rects.reference[axis] - popperOffsets[axis] - state.rects.popper[len];\n var startDiff = popperOffsets[axis] - state.rects.reference[axis];\n var arrowOffsetParent = getOffsetParent(arrowElement);\n var clientSize = arrowOffsetParent ? axis === 'y' ? arrowOffsetParent.clientHeight || 0 : arrowOffsetParent.clientWidth || 0 : 0;\n var centerToReference = endDiff / 2 - startDiff / 2; // Make sure the arrow doesn't overflow the popper if the center point is\n // outside of the popper bounds\n\n var min = paddingObject[minProp];\n var max = clientSize - arrowRect[len] - paddingObject[maxProp];\n var center = clientSize / 2 - arrowRect[len] / 2 + centerToReference;\n var offset = within(min, center, max); // Prevents breaking syntax highlighting...\n\n var axisProp = axis;\n state.modifiersData[name] = (_state$modifiersData$ = {}, _state$modifiersData$[axisProp] = offset, _state$modifiersData$.centerOffset = offset - center, _state$modifiersData$);\n}\n\nfunction effect(_ref2) {\n var state = _ref2.state,\n options = _ref2.options;\n var _options$element = options.element,\n arrowElement = _options$element === void 0 ? '[data-popper-arrow]' : _options$element;\n\n if (arrowElement == null) {\n return;\n } // CSS selector\n\n\n if (typeof arrowElement === 'string') {\n arrowElement = state.elements.popper.querySelector(arrowElement);\n\n if (!arrowElement) {\n return;\n }\n }\n\n if (!contains(state.elements.popper, arrowElement)) {\n return;\n }\n\n state.elements.arrow = arrowElement;\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'arrow',\n enabled: true,\n phase: 'main',\n fn: arrow,\n effect: effect,\n requires: ['popperOffsets'],\n requiresIfExists: ['preventOverflow']\n};","export default function getVariation(placement) {\n return placement.split('-')[1];\n}","import { top, left, right, bottom, end } from \"../enums.js\";\nimport getOffsetParent from \"../dom-utils/getOffsetParent.js\";\nimport getWindow from \"../dom-utils/getWindow.js\";\nimport getDocumentElement from \"../dom-utils/getDocumentElement.js\";\nimport getComputedStyle from \"../dom-utils/getComputedStyle.js\";\nimport getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getVariation from \"../utils/getVariation.js\";\nimport { round } from \"../utils/math.js\"; // eslint-disable-next-line import/no-unused-modules\n\nvar unsetSides = {\n top: 'auto',\n right: 'auto',\n bottom: 'auto',\n left: 'auto'\n}; // Round the offsets to the nearest suitable subpixel based on the DPR.\n// Zooming can change the DPR, but it seems to report a value that will\n// cleanly divide the values into the appropriate subpixels.\n\nfunction roundOffsetsByDPR(_ref, win) {\n var x = _ref.x,\n y = _ref.y;\n var dpr = win.devicePixelRatio || 1;\n return {\n x: round(x * dpr) / dpr || 0,\n y: round(y * dpr) / dpr || 0\n };\n}\n\nexport function mapToStyles(_ref2) {\n var _Object$assign2;\n\n var popper = _ref2.popper,\n popperRect = _ref2.popperRect,\n placement = _ref2.placement,\n variation = _ref2.variation,\n offsets = _ref2.offsets,\n position = _ref2.position,\n gpuAcceleration = _ref2.gpuAcceleration,\n adaptive = _ref2.adaptive,\n roundOffsets = _ref2.roundOffsets,\n isFixed = _ref2.isFixed;\n var _offsets$x = offsets.x,\n x = _offsets$x === void 0 ? 0 : _offsets$x,\n _offsets$y = offsets.y,\n y = _offsets$y === void 0 ? 0 : _offsets$y;\n\n var _ref3 = typeof roundOffsets === 'function' ? roundOffsets({\n x: x,\n y: y\n }) : {\n x: x,\n y: y\n };\n\n x = _ref3.x;\n y = _ref3.y;\n var hasX = offsets.hasOwnProperty('x');\n var hasY = offsets.hasOwnProperty('y');\n var sideX = left;\n var sideY = top;\n var win = window;\n\n if (adaptive) {\n var offsetParent = getOffsetParent(popper);\n var heightProp = 'clientHeight';\n var widthProp = 'clientWidth';\n\n if (offsetParent === getWindow(popper)) {\n offsetParent = getDocumentElement(popper);\n\n if (getComputedStyle(offsetParent).position !== 'static' && position === 'absolute') {\n heightProp = 'scrollHeight';\n widthProp = 'scrollWidth';\n }\n } // $FlowFixMe[incompatible-cast]: force type refinement, we compare offsetParent with window above, but Flow doesn't detect it\n\n\n offsetParent = offsetParent;\n\n if (placement === top || (placement === left || placement === right) && variation === end) {\n sideY = bottom;\n var offsetY = isFixed && offsetParent === win && win.visualViewport ? win.visualViewport.height : // $FlowFixMe[prop-missing]\n offsetParent[heightProp];\n y -= offsetY - popperRect.height;\n y *= gpuAcceleration ? 1 : -1;\n }\n\n if (placement === left || (placement === top || placement === bottom) && variation === end) {\n sideX = right;\n var offsetX = isFixed && offsetParent === win && win.visualViewport ? win.visualViewport.width : // $FlowFixMe[prop-missing]\n offsetParent[widthProp];\n x -= offsetX - popperRect.width;\n x *= gpuAcceleration ? 1 : -1;\n }\n }\n\n var commonStyles = Object.assign({\n position: position\n }, adaptive && unsetSides);\n\n var _ref4 = roundOffsets === true ? roundOffsetsByDPR({\n x: x,\n y: y\n }, getWindow(popper)) : {\n x: x,\n y: y\n };\n\n x = _ref4.x;\n y = _ref4.y;\n\n if (gpuAcceleration) {\n var _Object$assign;\n\n return Object.assign({}, commonStyles, (_Object$assign = {}, _Object$assign[sideY] = hasY ? '0' : '', _Object$assign[sideX] = hasX ? '0' : '', _Object$assign.transform = (win.devicePixelRatio || 1) <= 1 ? \"translate(\" + x + \"px, \" + y + \"px)\" : \"translate3d(\" + x + \"px, \" + y + \"px, 0)\", _Object$assign));\n }\n\n return Object.assign({}, commonStyles, (_Object$assign2 = {}, _Object$assign2[sideY] = hasY ? y + \"px\" : '', _Object$assign2[sideX] = hasX ? x + \"px\" : '', _Object$assign2.transform = '', _Object$assign2));\n}\n\nfunction computeStyles(_ref5) {\n var state = _ref5.state,\n options = _ref5.options;\n var _options$gpuAccelerat = options.gpuAcceleration,\n gpuAcceleration = _options$gpuAccelerat === void 0 ? true : _options$gpuAccelerat,\n _options$adaptive = options.adaptive,\n adaptive = _options$adaptive === void 0 ? true : _options$adaptive,\n _options$roundOffsets = options.roundOffsets,\n roundOffsets = _options$roundOffsets === void 0 ? true : _options$roundOffsets;\n var commonStyles = {\n placement: getBasePlacement(state.placement),\n variation: getVariation(state.placement),\n popper: state.elements.popper,\n popperRect: state.rects.popper,\n gpuAcceleration: gpuAcceleration,\n isFixed: state.options.strategy === 'fixed'\n };\n\n if (state.modifiersData.popperOffsets != null) {\n state.styles.popper = Object.assign({}, state.styles.popper, mapToStyles(Object.assign({}, commonStyles, {\n offsets: state.modifiersData.popperOffsets,\n position: state.options.strategy,\n adaptive: adaptive,\n roundOffsets: roundOffsets\n })));\n }\n\n if (state.modifiersData.arrow != null) {\n state.styles.arrow = Object.assign({}, state.styles.arrow, mapToStyles(Object.assign({}, commonStyles, {\n offsets: state.modifiersData.arrow,\n position: 'absolute',\n adaptive: false,\n roundOffsets: roundOffsets\n })));\n }\n\n state.attributes.popper = Object.assign({}, state.attributes.popper, {\n 'data-popper-placement': state.placement\n });\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'computeStyles',\n enabled: true,\n phase: 'beforeWrite',\n fn: computeStyles,\n data: {}\n};","import getWindow from \"../dom-utils/getWindow.js\"; // eslint-disable-next-line import/no-unused-modules\n\nvar passive = {\n passive: true\n};\n\nfunction effect(_ref) {\n var state = _ref.state,\n instance = _ref.instance,\n options = _ref.options;\n var _options$scroll = options.scroll,\n scroll = _options$scroll === void 0 ? true : _options$scroll,\n _options$resize = options.resize,\n resize = _options$resize === void 0 ? true : _options$resize;\n var window = getWindow(state.elements.popper);\n var scrollParents = [].concat(state.scrollParents.reference, state.scrollParents.popper);\n\n if (scroll) {\n scrollParents.forEach(function (scrollParent) {\n scrollParent.addEventListener('scroll', instance.update, passive);\n });\n }\n\n if (resize) {\n window.addEventListener('resize', instance.update, passive);\n }\n\n return function () {\n if (scroll) {\n scrollParents.forEach(function (scrollParent) {\n scrollParent.removeEventListener('scroll', instance.update, passive);\n });\n }\n\n if (resize) {\n window.removeEventListener('resize', instance.update, passive);\n }\n };\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'eventListeners',\n enabled: true,\n phase: 'write',\n fn: function fn() {},\n effect: effect,\n data: {}\n};","var hash = {\n left: 'right',\n right: 'left',\n bottom: 'top',\n top: 'bottom'\n};\nexport default function getOppositePlacement(placement) {\n return placement.replace(/left|right|bottom|top/g, function (matched) {\n return hash[matched];\n });\n}","var hash = {\n start: 'end',\n end: 'start'\n};\nexport default function getOppositeVariationPlacement(placement) {\n return placement.replace(/start|end/g, function (matched) {\n return hash[matched];\n });\n}","import getWindow from \"./getWindow.js\";\nexport default function getWindowScroll(node) {\n var win = getWindow(node);\n var scrollLeft = win.pageXOffset;\n var scrollTop = win.pageYOffset;\n return {\n scrollLeft: scrollLeft,\n scrollTop: scrollTop\n };\n}","import getBoundingClientRect from \"./getBoundingClientRect.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport getWindowScroll from \"./getWindowScroll.js\";\nexport default function getWindowScrollBarX(element) {\n // If has a CSS width greater than the viewport, then this will be\n // incorrect for RTL.\n // Popper 1 is broken in this case and never had a bug report so let's assume\n // it's not an issue. I don't think anyone ever specifies width on \n // anyway.\n // Browsers where the left scrollbar doesn't cause an issue report `0` for\n // this (e.g. Edge 2019, IE11, Safari)\n return getBoundingClientRect(getDocumentElement(element)).left + getWindowScroll(element).scrollLeft;\n}","import getWindow from \"./getWindow.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport getWindowScrollBarX from \"./getWindowScrollBarX.js\";\nimport isLayoutViewport from \"./isLayoutViewport.js\";\nexport default function getViewportRect(element, strategy) {\n var win = getWindow(element);\n var html = getDocumentElement(element);\n var visualViewport = win.visualViewport;\n var width = html.clientWidth;\n var height = html.clientHeight;\n var x = 0;\n var y = 0;\n\n if (visualViewport) {\n width = visualViewport.width;\n height = visualViewport.height;\n var layoutViewport = isLayoutViewport();\n\n if (layoutViewport || !layoutViewport && strategy === 'fixed') {\n x = visualViewport.offsetLeft;\n y = visualViewport.offsetTop;\n }\n }\n\n return {\n width: width,\n height: height,\n x: x + getWindowScrollBarX(element),\n y: y\n };\n}","import getDocumentElement from \"./getDocumentElement.js\";\nimport getComputedStyle from \"./getComputedStyle.js\";\nimport getWindowScrollBarX from \"./getWindowScrollBarX.js\";\nimport getWindowScroll from \"./getWindowScroll.js\";\nimport { max } from \"../utils/math.js\"; // Gets the entire size of the scrollable document area, even extending outside\n// of the `` and `` rect bounds if horizontally scrollable\n\nexport default function getDocumentRect(element) {\n var _element$ownerDocumen;\n\n var html = getDocumentElement(element);\n var winScroll = getWindowScroll(element);\n var body = (_element$ownerDocumen = element.ownerDocument) == null ? void 0 : _element$ownerDocumen.body;\n var width = max(html.scrollWidth, html.clientWidth, body ? body.scrollWidth : 0, body ? body.clientWidth : 0);\n var height = max(html.scrollHeight, html.clientHeight, body ? body.scrollHeight : 0, body ? body.clientHeight : 0);\n var x = -winScroll.scrollLeft + getWindowScrollBarX(element);\n var y = -winScroll.scrollTop;\n\n if (getComputedStyle(body || html).direction === 'rtl') {\n x += max(html.clientWidth, body ? body.clientWidth : 0) - width;\n }\n\n return {\n width: width,\n height: height,\n x: x,\n y: y\n };\n}","import getComputedStyle from \"./getComputedStyle.js\";\nexport default function isScrollParent(element) {\n // Firefox wants us to check `-x` and `-y` variations as well\n var _getComputedStyle = getComputedStyle(element),\n overflow = _getComputedStyle.overflow,\n overflowX = _getComputedStyle.overflowX,\n overflowY = _getComputedStyle.overflowY;\n\n return /auto|scroll|overlay|hidden/.test(overflow + overflowY + overflowX);\n}","import getParentNode from \"./getParentNode.js\";\nimport isScrollParent from \"./isScrollParent.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport { isHTMLElement } from \"./instanceOf.js\";\nexport default function getScrollParent(node) {\n if (['html', 'body', '#document'].indexOf(getNodeName(node)) >= 0) {\n // $FlowFixMe[incompatible-return]: assume body is always available\n return node.ownerDocument.body;\n }\n\n if (isHTMLElement(node) && isScrollParent(node)) {\n return node;\n }\n\n return getScrollParent(getParentNode(node));\n}","import getScrollParent from \"./getScrollParent.js\";\nimport getParentNode from \"./getParentNode.js\";\nimport getWindow from \"./getWindow.js\";\nimport isScrollParent from \"./isScrollParent.js\";\n/*\ngiven a DOM element, return the list of all scroll parents, up the list of ancesors\nuntil we get to the top window object. This list is what we attach scroll listeners\nto, because if any of these parent elements scroll, we'll need to re-calculate the\nreference element's position.\n*/\n\nexport default function listScrollParents(element, list) {\n var _element$ownerDocumen;\n\n if (list === void 0) {\n list = [];\n }\n\n var scrollParent = getScrollParent(element);\n var isBody = scrollParent === ((_element$ownerDocumen = element.ownerDocument) == null ? void 0 : _element$ownerDocumen.body);\n var win = getWindow(scrollParent);\n var target = isBody ? [win].concat(win.visualViewport || [], isScrollParent(scrollParent) ? scrollParent : []) : scrollParent;\n var updatedList = list.concat(target);\n return isBody ? updatedList : // $FlowFixMe[incompatible-call]: isBody tells us target will be an HTMLElement here\n updatedList.concat(listScrollParents(getParentNode(target)));\n}","export default function rectToClientRect(rect) {\n return Object.assign({}, rect, {\n left: rect.x,\n top: rect.y,\n right: rect.x + rect.width,\n bottom: rect.y + rect.height\n });\n}","import { viewport } from \"../enums.js\";\nimport getViewportRect from \"./getViewportRect.js\";\nimport getDocumentRect from \"./getDocumentRect.js\";\nimport listScrollParents from \"./listScrollParents.js\";\nimport getOffsetParent from \"./getOffsetParent.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport getComputedStyle from \"./getComputedStyle.js\";\nimport { isElement, isHTMLElement } from \"./instanceOf.js\";\nimport getBoundingClientRect from \"./getBoundingClientRect.js\";\nimport getParentNode from \"./getParentNode.js\";\nimport contains from \"./contains.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport rectToClientRect from \"../utils/rectToClientRect.js\";\nimport { max, min } from \"../utils/math.js\";\n\nfunction getInnerBoundingClientRect(element, strategy) {\n var rect = getBoundingClientRect(element, false, strategy === 'fixed');\n rect.top = rect.top + element.clientTop;\n rect.left = rect.left + element.clientLeft;\n rect.bottom = rect.top + element.clientHeight;\n rect.right = rect.left + element.clientWidth;\n rect.width = element.clientWidth;\n rect.height = element.clientHeight;\n rect.x = rect.left;\n rect.y = rect.top;\n return rect;\n}\n\nfunction getClientRectFromMixedType(element, clippingParent, strategy) {\n return clippingParent === viewport ? rectToClientRect(getViewportRect(element, strategy)) : isElement(clippingParent) ? getInnerBoundingClientRect(clippingParent, strategy) : rectToClientRect(getDocumentRect(getDocumentElement(element)));\n} // A \"clipping parent\" is an overflowable container with the characteristic of\n// clipping (or hiding) overflowing elements with a position different from\n// `initial`\n\n\nfunction getClippingParents(element) {\n var clippingParents = listScrollParents(getParentNode(element));\n var canEscapeClipping = ['absolute', 'fixed'].indexOf(getComputedStyle(element).position) >= 0;\n var clipperElement = canEscapeClipping && isHTMLElement(element) ? getOffsetParent(element) : element;\n\n if (!isElement(clipperElement)) {\n return [];\n } // $FlowFixMe[incompatible-return]: https://github.com/facebook/flow/issues/1414\n\n\n return clippingParents.filter(function (clippingParent) {\n return isElement(clippingParent) && contains(clippingParent, clipperElement) && getNodeName(clippingParent) !== 'body';\n });\n} // Gets the maximum area that the element is visible in due to any number of\n// clipping parents\n\n\nexport default function getClippingRect(element, boundary, rootBoundary, strategy) {\n var mainClippingParents = boundary === 'clippingParents' ? getClippingParents(element) : [].concat(boundary);\n var clippingParents = [].concat(mainClippingParents, [rootBoundary]);\n var firstClippingParent = clippingParents[0];\n var clippingRect = clippingParents.reduce(function (accRect, clippingParent) {\n var rect = getClientRectFromMixedType(element, clippingParent, strategy);\n accRect.top = max(rect.top, accRect.top);\n accRect.right = min(rect.right, accRect.right);\n accRect.bottom = min(rect.bottom, accRect.bottom);\n accRect.left = max(rect.left, accRect.left);\n return accRect;\n }, getClientRectFromMixedType(element, firstClippingParent, strategy));\n clippingRect.width = clippingRect.right - clippingRect.left;\n clippingRect.height = clippingRect.bottom - clippingRect.top;\n clippingRect.x = clippingRect.left;\n clippingRect.y = clippingRect.top;\n return clippingRect;\n}","import getBasePlacement from \"./getBasePlacement.js\";\nimport getVariation from \"./getVariation.js\";\nimport getMainAxisFromPlacement from \"./getMainAxisFromPlacement.js\";\nimport { top, right, bottom, left, start, end } from \"../enums.js\";\nexport default function computeOffsets(_ref) {\n var reference = _ref.reference,\n element = _ref.element,\n placement = _ref.placement;\n var basePlacement = placement ? getBasePlacement(placement) : null;\n var variation = placement ? getVariation(placement) : null;\n var commonX = reference.x + reference.width / 2 - element.width / 2;\n var commonY = reference.y + reference.height / 2 - element.height / 2;\n var offsets;\n\n switch (basePlacement) {\n case top:\n offsets = {\n x: commonX,\n y: reference.y - element.height\n };\n break;\n\n case bottom:\n offsets = {\n x: commonX,\n y: reference.y + reference.height\n };\n break;\n\n case right:\n offsets = {\n x: reference.x + reference.width,\n y: commonY\n };\n break;\n\n case left:\n offsets = {\n x: reference.x - element.width,\n y: commonY\n };\n break;\n\n default:\n offsets = {\n x: reference.x,\n y: reference.y\n };\n }\n\n var mainAxis = basePlacement ? getMainAxisFromPlacement(basePlacement) : null;\n\n if (mainAxis != null) {\n var len = mainAxis === 'y' ? 'height' : 'width';\n\n switch (variation) {\n case start:\n offsets[mainAxis] = offsets[mainAxis] - (reference[len] / 2 - element[len] / 2);\n break;\n\n case end:\n offsets[mainAxis] = offsets[mainAxis] + (reference[len] / 2 - element[len] / 2);\n break;\n\n default:\n }\n }\n\n return offsets;\n}","import getClippingRect from \"../dom-utils/getClippingRect.js\";\nimport getDocumentElement from \"../dom-utils/getDocumentElement.js\";\nimport getBoundingClientRect from \"../dom-utils/getBoundingClientRect.js\";\nimport computeOffsets from \"./computeOffsets.js\";\nimport rectToClientRect from \"./rectToClientRect.js\";\nimport { clippingParents, reference, popper, bottom, top, right, basePlacements, viewport } from \"../enums.js\";\nimport { isElement } from \"../dom-utils/instanceOf.js\";\nimport mergePaddingObject from \"./mergePaddingObject.js\";\nimport expandToHashMap from \"./expandToHashMap.js\"; // eslint-disable-next-line import/no-unused-modules\n\nexport default function detectOverflow(state, options) {\n if (options === void 0) {\n options = {};\n }\n\n var _options = options,\n _options$placement = _options.placement,\n placement = _options$placement === void 0 ? state.placement : _options$placement,\n _options$strategy = _options.strategy,\n strategy = _options$strategy === void 0 ? state.strategy : _options$strategy,\n _options$boundary = _options.boundary,\n boundary = _options$boundary === void 0 ? clippingParents : _options$boundary,\n _options$rootBoundary = _options.rootBoundary,\n rootBoundary = _options$rootBoundary === void 0 ? viewport : _options$rootBoundary,\n _options$elementConte = _options.elementContext,\n elementContext = _options$elementConte === void 0 ? popper : _options$elementConte,\n _options$altBoundary = _options.altBoundary,\n altBoundary = _options$altBoundary === void 0 ? false : _options$altBoundary,\n _options$padding = _options.padding,\n padding = _options$padding === void 0 ? 0 : _options$padding;\n var paddingObject = mergePaddingObject(typeof padding !== 'number' ? padding : expandToHashMap(padding, basePlacements));\n var altContext = elementContext === popper ? reference : popper;\n var popperRect = state.rects.popper;\n var element = state.elements[altBoundary ? altContext : elementContext];\n var clippingClientRect = getClippingRect(isElement(element) ? element : element.contextElement || getDocumentElement(state.elements.popper), boundary, rootBoundary, strategy);\n var referenceClientRect = getBoundingClientRect(state.elements.reference);\n var popperOffsets = computeOffsets({\n reference: referenceClientRect,\n element: popperRect,\n strategy: 'absolute',\n placement: placement\n });\n var popperClientRect = rectToClientRect(Object.assign({}, popperRect, popperOffsets));\n var elementClientRect = elementContext === popper ? popperClientRect : referenceClientRect; // positive = overflowing the clipping rect\n // 0 or negative = within the clipping rect\n\n var overflowOffsets = {\n top: clippingClientRect.top - elementClientRect.top + paddingObject.top,\n bottom: elementClientRect.bottom - clippingClientRect.bottom + paddingObject.bottom,\n left: clippingClientRect.left - elementClientRect.left + paddingObject.left,\n right: elementClientRect.right - clippingClientRect.right + paddingObject.right\n };\n var offsetData = state.modifiersData.offset; // Offsets can be applied only to the popper element\n\n if (elementContext === popper && offsetData) {\n var offset = offsetData[placement];\n Object.keys(overflowOffsets).forEach(function (key) {\n var multiply = [right, bottom].indexOf(key) >= 0 ? 1 : -1;\n var axis = [top, bottom].indexOf(key) >= 0 ? 'y' : 'x';\n overflowOffsets[key] += offset[axis] * multiply;\n });\n }\n\n return overflowOffsets;\n}","import getVariation from \"./getVariation.js\";\nimport { variationPlacements, basePlacements, placements as allPlacements } from \"../enums.js\";\nimport detectOverflow from \"./detectOverflow.js\";\nimport getBasePlacement from \"./getBasePlacement.js\";\nexport default function computeAutoPlacement(state, options) {\n if (options === void 0) {\n options = {};\n }\n\n var _options = options,\n placement = _options.placement,\n boundary = _options.boundary,\n rootBoundary = _options.rootBoundary,\n padding = _options.padding,\n flipVariations = _options.flipVariations,\n _options$allowedAutoP = _options.allowedAutoPlacements,\n allowedAutoPlacements = _options$allowedAutoP === void 0 ? allPlacements : _options$allowedAutoP;\n var variation = getVariation(placement);\n var placements = variation ? flipVariations ? variationPlacements : variationPlacements.filter(function (placement) {\n return getVariation(placement) === variation;\n }) : basePlacements;\n var allowedPlacements = placements.filter(function (placement) {\n return allowedAutoPlacements.indexOf(placement) >= 0;\n });\n\n if (allowedPlacements.length === 0) {\n allowedPlacements = placements;\n } // $FlowFixMe[incompatible-type]: Flow seems to have problems with two array unions...\n\n\n var overflows = allowedPlacements.reduce(function (acc, placement) {\n acc[placement] = detectOverflow(state, {\n placement: placement,\n boundary: boundary,\n rootBoundary: rootBoundary,\n padding: padding\n })[getBasePlacement(placement)];\n return acc;\n }, {});\n return Object.keys(overflows).sort(function (a, b) {\n return overflows[a] - overflows[b];\n });\n}","import getOppositePlacement from \"../utils/getOppositePlacement.js\";\nimport getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getOppositeVariationPlacement from \"../utils/getOppositeVariationPlacement.js\";\nimport detectOverflow from \"../utils/detectOverflow.js\";\nimport computeAutoPlacement from \"../utils/computeAutoPlacement.js\";\nimport { bottom, top, start, right, left, auto } from \"../enums.js\";\nimport getVariation from \"../utils/getVariation.js\"; // eslint-disable-next-line import/no-unused-modules\n\nfunction getExpandedFallbackPlacements(placement) {\n if (getBasePlacement(placement) === auto) {\n return [];\n }\n\n var oppositePlacement = getOppositePlacement(placement);\n return [getOppositeVariationPlacement(placement), oppositePlacement, getOppositeVariationPlacement(oppositePlacement)];\n}\n\nfunction flip(_ref) {\n var state = _ref.state,\n options = _ref.options,\n name = _ref.name;\n\n if (state.modifiersData[name]._skip) {\n return;\n }\n\n var _options$mainAxis = options.mainAxis,\n checkMainAxis = _options$mainAxis === void 0 ? true : _options$mainAxis,\n _options$altAxis = options.altAxis,\n checkAltAxis = _options$altAxis === void 0 ? true : _options$altAxis,\n specifiedFallbackPlacements = options.fallbackPlacements,\n padding = options.padding,\n boundary = options.boundary,\n rootBoundary = options.rootBoundary,\n altBoundary = options.altBoundary,\n _options$flipVariatio = options.flipVariations,\n flipVariations = _options$flipVariatio === void 0 ? true : _options$flipVariatio,\n allowedAutoPlacements = options.allowedAutoPlacements;\n var preferredPlacement = state.options.placement;\n var basePlacement = getBasePlacement(preferredPlacement);\n var isBasePlacement = basePlacement === preferredPlacement;\n var fallbackPlacements = specifiedFallbackPlacements || (isBasePlacement || !flipVariations ? [getOppositePlacement(preferredPlacement)] : getExpandedFallbackPlacements(preferredPlacement));\n var placements = [preferredPlacement].concat(fallbackPlacements).reduce(function (acc, placement) {\n return acc.concat(getBasePlacement(placement) === auto ? computeAutoPlacement(state, {\n placement: placement,\n boundary: boundary,\n rootBoundary: rootBoundary,\n padding: padding,\n flipVariations: flipVariations,\n allowedAutoPlacements: allowedAutoPlacements\n }) : placement);\n }, []);\n var referenceRect = state.rects.reference;\n var popperRect = state.rects.popper;\n var checksMap = new Map();\n var makeFallbackChecks = true;\n var firstFittingPlacement = placements[0];\n\n for (var i = 0; i < placements.length; i++) {\n var placement = placements[i];\n\n var _basePlacement = getBasePlacement(placement);\n\n var isStartVariation = getVariation(placement) === start;\n var isVertical = [top, bottom].indexOf(_basePlacement) >= 0;\n var len = isVertical ? 'width' : 'height';\n var overflow = detectOverflow(state, {\n placement: placement,\n boundary: boundary,\n rootBoundary: rootBoundary,\n altBoundary: altBoundary,\n padding: padding\n });\n var mainVariationSide = isVertical ? isStartVariation ? right : left : isStartVariation ? bottom : top;\n\n if (referenceRect[len] > popperRect[len]) {\n mainVariationSide = getOppositePlacement(mainVariationSide);\n }\n\n var altVariationSide = getOppositePlacement(mainVariationSide);\n var checks = [];\n\n if (checkMainAxis) {\n checks.push(overflow[_basePlacement] <= 0);\n }\n\n if (checkAltAxis) {\n checks.push(overflow[mainVariationSide] <= 0, overflow[altVariationSide] <= 0);\n }\n\n if (checks.every(function (check) {\n return check;\n })) {\n firstFittingPlacement = placement;\n makeFallbackChecks = false;\n break;\n }\n\n checksMap.set(placement, checks);\n }\n\n if (makeFallbackChecks) {\n // `2` may be desired in some cases – research later\n var numberOfChecks = flipVariations ? 3 : 1;\n\n var _loop = function _loop(_i) {\n var fittingPlacement = placements.find(function (placement) {\n var checks = checksMap.get(placement);\n\n if (checks) {\n return checks.slice(0, _i).every(function (check) {\n return check;\n });\n }\n });\n\n if (fittingPlacement) {\n firstFittingPlacement = fittingPlacement;\n return \"break\";\n }\n };\n\n for (var _i = numberOfChecks; _i > 0; _i--) {\n var _ret = _loop(_i);\n\n if (_ret === \"break\") break;\n }\n }\n\n if (state.placement !== firstFittingPlacement) {\n state.modifiersData[name]._skip = true;\n state.placement = firstFittingPlacement;\n state.reset = true;\n }\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'flip',\n enabled: true,\n phase: 'main',\n fn: flip,\n requiresIfExists: ['offset'],\n data: {\n _skip: false\n }\n};","import { top, bottom, left, right } from \"../enums.js\";\nimport detectOverflow from \"../utils/detectOverflow.js\";\n\nfunction getSideOffsets(overflow, rect, preventedOffsets) {\n if (preventedOffsets === void 0) {\n preventedOffsets = {\n x: 0,\n y: 0\n };\n }\n\n return {\n top: overflow.top - rect.height - preventedOffsets.y,\n right: overflow.right - rect.width + preventedOffsets.x,\n bottom: overflow.bottom - rect.height + preventedOffsets.y,\n left: overflow.left - rect.width - preventedOffsets.x\n };\n}\n\nfunction isAnySideFullyClipped(overflow) {\n return [top, right, bottom, left].some(function (side) {\n return overflow[side] >= 0;\n });\n}\n\nfunction hide(_ref) {\n var state = _ref.state,\n name = _ref.name;\n var referenceRect = state.rects.reference;\n var popperRect = state.rects.popper;\n var preventedOffsets = state.modifiersData.preventOverflow;\n var referenceOverflow = detectOverflow(state, {\n elementContext: 'reference'\n });\n var popperAltOverflow = detectOverflow(state, {\n altBoundary: true\n });\n var referenceClippingOffsets = getSideOffsets(referenceOverflow, referenceRect);\n var popperEscapeOffsets = getSideOffsets(popperAltOverflow, popperRect, preventedOffsets);\n var isReferenceHidden = isAnySideFullyClipped(referenceClippingOffsets);\n var hasPopperEscaped = isAnySideFullyClipped(popperEscapeOffsets);\n state.modifiersData[name] = {\n referenceClippingOffsets: referenceClippingOffsets,\n popperEscapeOffsets: popperEscapeOffsets,\n isReferenceHidden: isReferenceHidden,\n hasPopperEscaped: hasPopperEscaped\n };\n state.attributes.popper = Object.assign({}, state.attributes.popper, {\n 'data-popper-reference-hidden': isReferenceHidden,\n 'data-popper-escaped': hasPopperEscaped\n });\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'hide',\n enabled: true,\n phase: 'main',\n requiresIfExists: ['preventOverflow'],\n fn: hide\n};","import getBasePlacement from \"../utils/getBasePlacement.js\";\nimport { top, left, right, placements } from \"../enums.js\"; // eslint-disable-next-line import/no-unused-modules\n\nexport function distanceAndSkiddingToXY(placement, rects, offset) {\n var basePlacement = getBasePlacement(placement);\n var invertDistance = [left, top].indexOf(basePlacement) >= 0 ? -1 : 1;\n\n var _ref = typeof offset === 'function' ? offset(Object.assign({}, rects, {\n placement: placement\n })) : offset,\n skidding = _ref[0],\n distance = _ref[1];\n\n skidding = skidding || 0;\n distance = (distance || 0) * invertDistance;\n return [left, right].indexOf(basePlacement) >= 0 ? {\n x: distance,\n y: skidding\n } : {\n x: skidding,\n y: distance\n };\n}\n\nfunction offset(_ref2) {\n var state = _ref2.state,\n options = _ref2.options,\n name = _ref2.name;\n var _options$offset = options.offset,\n offset = _options$offset === void 0 ? [0, 0] : _options$offset;\n var data = placements.reduce(function (acc, placement) {\n acc[placement] = distanceAndSkiddingToXY(placement, state.rects, offset);\n return acc;\n }, {});\n var _data$state$placement = data[state.placement],\n x = _data$state$placement.x,\n y = _data$state$placement.y;\n\n if (state.modifiersData.popperOffsets != null) {\n state.modifiersData.popperOffsets.x += x;\n state.modifiersData.popperOffsets.y += y;\n }\n\n state.modifiersData[name] = data;\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'offset',\n enabled: true,\n phase: 'main',\n requires: ['popperOffsets'],\n fn: offset\n};","import computeOffsets from \"../utils/computeOffsets.js\";\n\nfunction popperOffsets(_ref) {\n var state = _ref.state,\n name = _ref.name;\n // Offsets are the actual position the popper needs to have to be\n // properly positioned near its reference element\n // This is the most basic placement, and will be adjusted by\n // the modifiers in the next step\n state.modifiersData[name] = computeOffsets({\n reference: state.rects.reference,\n element: state.rects.popper,\n strategy: 'absolute',\n placement: state.placement\n });\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'popperOffsets',\n enabled: true,\n phase: 'read',\n fn: popperOffsets,\n data: {}\n};","export default function getAltAxis(axis) {\n return axis === 'x' ? 'y' : 'x';\n}","import { top, left, right, bottom, start } from \"../enums.js\";\nimport getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getMainAxisFromPlacement from \"../utils/getMainAxisFromPlacement.js\";\nimport getAltAxis from \"../utils/getAltAxis.js\";\nimport { within, withinMaxClamp } from \"../utils/within.js\";\nimport getLayoutRect from \"../dom-utils/getLayoutRect.js\";\nimport getOffsetParent from \"../dom-utils/getOffsetParent.js\";\nimport detectOverflow from \"../utils/detectOverflow.js\";\nimport getVariation from \"../utils/getVariation.js\";\nimport getFreshSideObject from \"../utils/getFreshSideObject.js\";\nimport { min as mathMin, max as mathMax } from \"../utils/math.js\";\n\nfunction preventOverflow(_ref) {\n var state = _ref.state,\n options = _ref.options,\n name = _ref.name;\n var _options$mainAxis = options.mainAxis,\n checkMainAxis = _options$mainAxis === void 0 ? true : _options$mainAxis,\n _options$altAxis = options.altAxis,\n checkAltAxis = _options$altAxis === void 0 ? false : _options$altAxis,\n boundary = options.boundary,\n rootBoundary = options.rootBoundary,\n altBoundary = options.altBoundary,\n padding = options.padding,\n _options$tether = options.tether,\n tether = _options$tether === void 0 ? true : _options$tether,\n _options$tetherOffset = options.tetherOffset,\n tetherOffset = _options$tetherOffset === void 0 ? 0 : _options$tetherOffset;\n var overflow = detectOverflow(state, {\n boundary: boundary,\n rootBoundary: rootBoundary,\n padding: padding,\n altBoundary: altBoundary\n });\n var basePlacement = getBasePlacement(state.placement);\n var variation = getVariation(state.placement);\n var isBasePlacement = !variation;\n var mainAxis = getMainAxisFromPlacement(basePlacement);\n var altAxis = getAltAxis(mainAxis);\n var popperOffsets = state.modifiersData.popperOffsets;\n var referenceRect = state.rects.reference;\n var popperRect = state.rects.popper;\n var tetherOffsetValue = typeof tetherOffset === 'function' ? tetherOffset(Object.assign({}, state.rects, {\n placement: state.placement\n })) : tetherOffset;\n var normalizedTetherOffsetValue = typeof tetherOffsetValue === 'number' ? {\n mainAxis: tetherOffsetValue,\n altAxis: tetherOffsetValue\n } : Object.assign({\n mainAxis: 0,\n altAxis: 0\n }, tetherOffsetValue);\n var offsetModifierState = state.modifiersData.offset ? state.modifiersData.offset[state.placement] : null;\n var data = {\n x: 0,\n y: 0\n };\n\n if (!popperOffsets) {\n return;\n }\n\n if (checkMainAxis) {\n var _offsetModifierState$;\n\n var mainSide = mainAxis === 'y' ? top : left;\n var altSide = mainAxis === 'y' ? bottom : right;\n var len = mainAxis === 'y' ? 'height' : 'width';\n var offset = popperOffsets[mainAxis];\n var min = offset + overflow[mainSide];\n var max = offset - overflow[altSide];\n var additive = tether ? -popperRect[len] / 2 : 0;\n var minLen = variation === start ? referenceRect[len] : popperRect[len];\n var maxLen = variation === start ? -popperRect[len] : -referenceRect[len]; // We need to include the arrow in the calculation so the arrow doesn't go\n // outside the reference bounds\n\n var arrowElement = state.elements.arrow;\n var arrowRect = tether && arrowElement ? getLayoutRect(arrowElement) : {\n width: 0,\n height: 0\n };\n var arrowPaddingObject = state.modifiersData['arrow#persistent'] ? state.modifiersData['arrow#persistent'].padding : getFreshSideObject();\n var arrowPaddingMin = arrowPaddingObject[mainSide];\n var arrowPaddingMax = arrowPaddingObject[altSide]; // If the reference length is smaller than the arrow length, we don't want\n // to include its full size in the calculation. If the reference is small\n // and near the edge of a boundary, the popper can overflow even if the\n // reference is not overflowing as well (e.g. virtual elements with no\n // width or height)\n\n var arrowLen = within(0, referenceRect[len], arrowRect[len]);\n var minOffset = isBasePlacement ? referenceRect[len] / 2 - additive - arrowLen - arrowPaddingMin - normalizedTetherOffsetValue.mainAxis : minLen - arrowLen - arrowPaddingMin - normalizedTetherOffsetValue.mainAxis;\n var maxOffset = isBasePlacement ? -referenceRect[len] / 2 + additive + arrowLen + arrowPaddingMax + normalizedTetherOffsetValue.mainAxis : maxLen + arrowLen + arrowPaddingMax + normalizedTetherOffsetValue.mainAxis;\n var arrowOffsetParent = state.elements.arrow && getOffsetParent(state.elements.arrow);\n var clientOffset = arrowOffsetParent ? mainAxis === 'y' ? arrowOffsetParent.clientTop || 0 : arrowOffsetParent.clientLeft || 0 : 0;\n var offsetModifierValue = (_offsetModifierState$ = offsetModifierState == null ? void 0 : offsetModifierState[mainAxis]) != null ? _offsetModifierState$ : 0;\n var tetherMin = offset + minOffset - offsetModifierValue - clientOffset;\n var tetherMax = offset + maxOffset - offsetModifierValue;\n var preventedOffset = within(tether ? mathMin(min, tetherMin) : min, offset, tether ? mathMax(max, tetherMax) : max);\n popperOffsets[mainAxis] = preventedOffset;\n data[mainAxis] = preventedOffset - offset;\n }\n\n if (checkAltAxis) {\n var _offsetModifierState$2;\n\n var _mainSide = mainAxis === 'x' ? top : left;\n\n var _altSide = mainAxis === 'x' ? bottom : right;\n\n var _offset = popperOffsets[altAxis];\n\n var _len = altAxis === 'y' ? 'height' : 'width';\n\n var _min = _offset + overflow[_mainSide];\n\n var _max = _offset - overflow[_altSide];\n\n var isOriginSide = [top, left].indexOf(basePlacement) !== -1;\n\n var _offsetModifierValue = (_offsetModifierState$2 = offsetModifierState == null ? void 0 : offsetModifierState[altAxis]) != null ? _offsetModifierState$2 : 0;\n\n var _tetherMin = isOriginSide ? _min : _offset - referenceRect[_len] - popperRect[_len] - _offsetModifierValue + normalizedTetherOffsetValue.altAxis;\n\n var _tetherMax = isOriginSide ? _offset + referenceRect[_len] + popperRect[_len] - _offsetModifierValue - normalizedTetherOffsetValue.altAxis : _max;\n\n var _preventedOffset = tether && isOriginSide ? withinMaxClamp(_tetherMin, _offset, _tetherMax) : within(tether ? _tetherMin : _min, _offset, tether ? _tetherMax : _max);\n\n popperOffsets[altAxis] = _preventedOffset;\n data[altAxis] = _preventedOffset - _offset;\n }\n\n state.modifiersData[name] = data;\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'preventOverflow',\n enabled: true,\n phase: 'main',\n fn: preventOverflow,\n requiresIfExists: ['offset']\n};","export default function getHTMLElementScroll(element) {\n return {\n scrollLeft: element.scrollLeft,\n scrollTop: element.scrollTop\n };\n}","import getWindowScroll from \"./getWindowScroll.js\";\nimport getWindow from \"./getWindow.js\";\nimport { isHTMLElement } from \"./instanceOf.js\";\nimport getHTMLElementScroll from \"./getHTMLElementScroll.js\";\nexport default function getNodeScroll(node) {\n if (node === getWindow(node) || !isHTMLElement(node)) {\n return getWindowScroll(node);\n } else {\n return getHTMLElementScroll(node);\n }\n}","import getBoundingClientRect from \"./getBoundingClientRect.js\";\nimport getNodeScroll from \"./getNodeScroll.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport { isHTMLElement } from \"./instanceOf.js\";\nimport getWindowScrollBarX from \"./getWindowScrollBarX.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport isScrollParent from \"./isScrollParent.js\";\nimport { round } from \"../utils/math.js\";\n\nfunction isElementScaled(element) {\n var rect = element.getBoundingClientRect();\n var scaleX = round(rect.width) / element.offsetWidth || 1;\n var scaleY = round(rect.height) / element.offsetHeight || 1;\n return scaleX !== 1 || scaleY !== 1;\n} // Returns the composite rect of an element relative to its offsetParent.\n// Composite means it takes into account transforms as well as layout.\n\n\nexport default function getCompositeRect(elementOrVirtualElement, offsetParent, isFixed) {\n if (isFixed === void 0) {\n isFixed = false;\n }\n\n var isOffsetParentAnElement = isHTMLElement(offsetParent);\n var offsetParentIsScaled = isHTMLElement(offsetParent) && isElementScaled(offsetParent);\n var documentElement = getDocumentElement(offsetParent);\n var rect = getBoundingClientRect(elementOrVirtualElement, offsetParentIsScaled, isFixed);\n var scroll = {\n scrollLeft: 0,\n scrollTop: 0\n };\n var offsets = {\n x: 0,\n y: 0\n };\n\n if (isOffsetParentAnElement || !isOffsetParentAnElement && !isFixed) {\n if (getNodeName(offsetParent) !== 'body' || // https://github.com/popperjs/popper-core/issues/1078\n isScrollParent(documentElement)) {\n scroll = getNodeScroll(offsetParent);\n }\n\n if (isHTMLElement(offsetParent)) {\n offsets = getBoundingClientRect(offsetParent, true);\n offsets.x += offsetParent.clientLeft;\n offsets.y += offsetParent.clientTop;\n } else if (documentElement) {\n offsets.x = getWindowScrollBarX(documentElement);\n }\n }\n\n return {\n x: rect.left + scroll.scrollLeft - offsets.x,\n y: rect.top + scroll.scrollTop - offsets.y,\n width: rect.width,\n height: rect.height\n };\n}","import { modifierPhases } from \"../enums.js\"; // source: https://stackoverflow.com/questions/49875255\n\nfunction order(modifiers) {\n var map = new Map();\n var visited = new Set();\n var result = [];\n modifiers.forEach(function (modifier) {\n map.set(modifier.name, modifier);\n }); // On visiting object, check for its dependencies and visit them recursively\n\n function sort(modifier) {\n visited.add(modifier.name);\n var requires = [].concat(modifier.requires || [], modifier.requiresIfExists || []);\n requires.forEach(function (dep) {\n if (!visited.has(dep)) {\n var depModifier = map.get(dep);\n\n if (depModifier) {\n sort(depModifier);\n }\n }\n });\n result.push(modifier);\n }\n\n modifiers.forEach(function (modifier) {\n if (!visited.has(modifier.name)) {\n // check for visited object\n sort(modifier);\n }\n });\n return result;\n}\n\nexport default function orderModifiers(modifiers) {\n // order based on dependencies\n var orderedModifiers = order(modifiers); // order based on phase\n\n return modifierPhases.reduce(function (acc, phase) {\n return acc.concat(orderedModifiers.filter(function (modifier) {\n return modifier.phase === phase;\n }));\n }, []);\n}","export default function debounce(fn) {\n var pending;\n return function () {\n if (!pending) {\n pending = new Promise(function (resolve) {\n Promise.resolve().then(function () {\n pending = undefined;\n resolve(fn());\n });\n });\n }\n\n return pending;\n };\n}","export default function mergeByName(modifiers) {\n var merged = modifiers.reduce(function (merged, current) {\n var existing = merged[current.name];\n merged[current.name] = existing ? Object.assign({}, existing, current, {\n options: Object.assign({}, existing.options, current.options),\n data: Object.assign({}, existing.data, current.data)\n }) : current;\n return merged;\n }, {}); // IE11 does not support Object.values\n\n return Object.keys(merged).map(function (key) {\n return merged[key];\n });\n}","import getCompositeRect from \"./dom-utils/getCompositeRect.js\";\nimport getLayoutRect from \"./dom-utils/getLayoutRect.js\";\nimport listScrollParents from \"./dom-utils/listScrollParents.js\";\nimport getOffsetParent from \"./dom-utils/getOffsetParent.js\";\nimport orderModifiers from \"./utils/orderModifiers.js\";\nimport debounce from \"./utils/debounce.js\";\nimport mergeByName from \"./utils/mergeByName.js\";\nimport detectOverflow from \"./utils/detectOverflow.js\";\nimport { isElement } from \"./dom-utils/instanceOf.js\";\nvar DEFAULT_OPTIONS = {\n placement: 'bottom',\n modifiers: [],\n strategy: 'absolute'\n};\n\nfunction areValidElements() {\n for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {\n args[_key] = arguments[_key];\n }\n\n return !args.some(function (element) {\n return !(element && typeof element.getBoundingClientRect === 'function');\n });\n}\n\nexport function popperGenerator(generatorOptions) {\n if (generatorOptions === void 0) {\n generatorOptions = {};\n }\n\n var _generatorOptions = generatorOptions,\n _generatorOptions$def = _generatorOptions.defaultModifiers,\n defaultModifiers = _generatorOptions$def === void 0 ? [] : _generatorOptions$def,\n _generatorOptions$def2 = _generatorOptions.defaultOptions,\n defaultOptions = _generatorOptions$def2 === void 0 ? DEFAULT_OPTIONS : _generatorOptions$def2;\n return function createPopper(reference, popper, options) {\n if (options === void 0) {\n options = defaultOptions;\n }\n\n var state = {\n placement: 'bottom',\n orderedModifiers: [],\n options: Object.assign({}, DEFAULT_OPTIONS, defaultOptions),\n modifiersData: {},\n elements: {\n reference: reference,\n popper: popper\n },\n attributes: {},\n styles: {}\n };\n var effectCleanupFns = [];\n var isDestroyed = false;\n var instance = {\n state: state,\n setOptions: function setOptions(setOptionsAction) {\n var options = typeof setOptionsAction === 'function' ? setOptionsAction(state.options) : setOptionsAction;\n cleanupModifierEffects();\n state.options = Object.assign({}, defaultOptions, state.options, options);\n state.scrollParents = {\n reference: isElement(reference) ? listScrollParents(reference) : reference.contextElement ? listScrollParents(reference.contextElement) : [],\n popper: listScrollParents(popper)\n }; // Orders the modifiers based on their dependencies and `phase`\n // properties\n\n var orderedModifiers = orderModifiers(mergeByName([].concat(defaultModifiers, state.options.modifiers))); // Strip out disabled modifiers\n\n state.orderedModifiers = orderedModifiers.filter(function (m) {\n return m.enabled;\n });\n runModifierEffects();\n return instance.update();\n },\n // Sync update – it will always be executed, even if not necessary. This\n // is useful for low frequency updates where sync behavior simplifies the\n // logic.\n // For high frequency updates (e.g. `resize` and `scroll` events), always\n // prefer the async Popper#update method\n forceUpdate: function forceUpdate() {\n if (isDestroyed) {\n return;\n }\n\n var _state$elements = state.elements,\n reference = _state$elements.reference,\n popper = _state$elements.popper; // Don't proceed if `reference` or `popper` are not valid elements\n // anymore\n\n if (!areValidElements(reference, popper)) {\n return;\n } // Store the reference and popper rects to be read by modifiers\n\n\n state.rects = {\n reference: getCompositeRect(reference, getOffsetParent(popper), state.options.strategy === 'fixed'),\n popper: getLayoutRect(popper)\n }; // Modifiers have the ability to reset the current update cycle. The\n // most common use case for this is the `flip` modifier changing the\n // placement, which then needs to re-run all the modifiers, because the\n // logic was previously ran for the previous placement and is therefore\n // stale/incorrect\n\n state.reset = false;\n state.placement = state.options.placement; // On each update cycle, the `modifiersData` property for each modifier\n // is filled with the initial data specified by the modifier. This means\n // it doesn't persist and is fresh on each update.\n // To ensure persistent data, use `${name}#persistent`\n\n state.orderedModifiers.forEach(function (modifier) {\n return state.modifiersData[modifier.name] = Object.assign({}, modifier.data);\n });\n\n for (var index = 0; index < state.orderedModifiers.length; index++) {\n if (state.reset === true) {\n state.reset = false;\n index = -1;\n continue;\n }\n\n var _state$orderedModifie = state.orderedModifiers[index],\n fn = _state$orderedModifie.fn,\n _state$orderedModifie2 = _state$orderedModifie.options,\n _options = _state$orderedModifie2 === void 0 ? {} : _state$orderedModifie2,\n name = _state$orderedModifie.name;\n\n if (typeof fn === 'function') {\n state = fn({\n state: state,\n options: _options,\n name: name,\n instance: instance\n }) || state;\n }\n }\n },\n // Async and optimistically optimized update – it will not be executed if\n // not necessary (debounced to run at most once-per-tick)\n update: debounce(function () {\n return new Promise(function (resolve) {\n instance.forceUpdate();\n resolve(state);\n });\n }),\n destroy: function destroy() {\n cleanupModifierEffects();\n isDestroyed = true;\n }\n };\n\n if (!areValidElements(reference, popper)) {\n return instance;\n }\n\n instance.setOptions(options).then(function (state) {\n if (!isDestroyed && options.onFirstUpdate) {\n options.onFirstUpdate(state);\n }\n }); // Modifiers have the ability to execute arbitrary code before the first\n // update cycle runs. They will be executed in the same order as the update\n // cycle. This is useful when a modifier adds some persistent data that\n // other modifiers need to use, but the modifier is run after the dependent\n // one.\n\n function runModifierEffects() {\n state.orderedModifiers.forEach(function (_ref) {\n var name = _ref.name,\n _ref$options = _ref.options,\n options = _ref$options === void 0 ? {} : _ref$options,\n effect = _ref.effect;\n\n if (typeof effect === 'function') {\n var cleanupFn = effect({\n state: state,\n name: name,\n instance: instance,\n options: options\n });\n\n var noopFn = function noopFn() {};\n\n effectCleanupFns.push(cleanupFn || noopFn);\n }\n });\n }\n\n function cleanupModifierEffects() {\n effectCleanupFns.forEach(function (fn) {\n return fn();\n });\n effectCleanupFns = [];\n }\n\n return instance;\n };\n}\nexport var createPopper = /*#__PURE__*/popperGenerator(); // eslint-disable-next-line import/no-unused-modules\n\nexport { detectOverflow };","import { popperGenerator, detectOverflow } from \"./createPopper.js\";\nimport eventListeners from \"./modifiers/eventListeners.js\";\nimport popperOffsets from \"./modifiers/popperOffsets.js\";\nimport computeStyles from \"./modifiers/computeStyles.js\";\nimport applyStyles from \"./modifiers/applyStyles.js\";\nimport offset from \"./modifiers/offset.js\";\nimport flip from \"./modifiers/flip.js\";\nimport preventOverflow from \"./modifiers/preventOverflow.js\";\nimport arrow from \"./modifiers/arrow.js\";\nimport hide from \"./modifiers/hide.js\";\nvar defaultModifiers = [eventListeners, popperOffsets, computeStyles, applyStyles, offset, flip, preventOverflow, arrow, hide];\nvar createPopper = /*#__PURE__*/popperGenerator({\n defaultModifiers: defaultModifiers\n}); // eslint-disable-next-line import/no-unused-modules\n\nexport { createPopper, popperGenerator, defaultModifiers, detectOverflow }; // eslint-disable-next-line import/no-unused-modules\n\nexport { createPopper as createPopperLite } from \"./popper-lite.js\"; // eslint-disable-next-line import/no-unused-modules\n\nexport * from \"./modifiers/index.js\";","import { generateUtilityClass } from '../generateUtilityClass';\nimport { generateUtilityClasses } from '../generateUtilityClasses';\nconst COMPONENT_NAME = 'Popper';\nexport function getPopperUtilityClass(slot) {\n return generateUtilityClass(COMPONENT_NAME, slot);\n}\nexport const popperClasses = generateUtilityClasses(COMPONENT_NAME, ['root']);","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"anchorEl\", \"children\", \"direction\", \"disablePortal\", \"modifiers\", \"open\", \"placement\", \"popperOptions\", \"popperRef\", \"slotProps\", \"slots\", \"TransitionProps\", \"ownerState\"],\n _excluded2 = [\"anchorEl\", \"children\", \"container\", \"direction\", \"disablePortal\", \"keepMounted\", \"modifiers\", \"open\", \"placement\", \"popperOptions\", \"popperRef\", \"style\", \"transition\", \"slotProps\", \"slots\"];\nimport * as React from 'react';\nimport { chainPropTypes, HTMLElementType, refType, unstable_ownerDocument as ownerDocument, unstable_useEnhancedEffect as useEnhancedEffect, unstable_useForkRef as useForkRef } from '@mui/utils';\nimport { createPopper } from '@popperjs/core';\nimport PropTypes from 'prop-types';\nimport { unstable_composeClasses as composeClasses } from '../composeClasses';\nimport { Portal } from '../Portal';\nimport { getPopperUtilityClass } from './popperClasses';\nimport { useSlotProps } from '../utils';\nimport { useClassNamesOverride } from '../utils/ClassNameConfigurator';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nfunction flipPlacement(placement, direction) {\n if (direction === 'ltr') {\n return placement;\n }\n switch (placement) {\n case 'bottom-end':\n return 'bottom-start';\n case 'bottom-start':\n return 'bottom-end';\n case 'top-end':\n return 'top-start';\n case 'top-start':\n return 'top-end';\n default:\n return placement;\n }\n}\nfunction resolveAnchorEl(anchorEl) {\n return typeof anchorEl === 'function' ? anchorEl() : anchorEl;\n}\nfunction isHTMLElement(element) {\n return element.nodeType !== undefined;\n}\nfunction isVirtualElement(element) {\n return !isHTMLElement(element);\n}\nconst useUtilityClasses = () => {\n const slots = {\n root: ['root']\n };\n return composeClasses(slots, useClassNamesOverride(getPopperUtilityClass));\n};\nconst defaultPopperOptions = {};\nconst PopperTooltip = /*#__PURE__*/React.forwardRef(function PopperTooltip(props, forwardedRef) {\n var _slots$root;\n const {\n anchorEl,\n children,\n direction,\n disablePortal,\n modifiers,\n open,\n placement: initialPlacement,\n popperOptions,\n popperRef: popperRefProp,\n slotProps = {},\n slots = {},\n TransitionProps\n // @ts-ignore internal logic\n // prevent from spreading to DOM, it can come from the parent component e.g. Select.\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const tooltipRef = React.useRef(null);\n const ownRef = useForkRef(tooltipRef, forwardedRef);\n const popperRef = React.useRef(null);\n const handlePopperRef = useForkRef(popperRef, popperRefProp);\n const handlePopperRefRef = React.useRef(handlePopperRef);\n useEnhancedEffect(() => {\n handlePopperRefRef.current = handlePopperRef;\n }, [handlePopperRef]);\n React.useImperativeHandle(popperRefProp, () => popperRef.current, []);\n const rtlPlacement = flipPlacement(initialPlacement, direction);\n /**\n * placement initialized from prop but can change during lifetime if modifiers.flip.\n * modifiers.flip is essentially a flip for controlled/uncontrolled behavior\n */\n const [placement, setPlacement] = React.useState(rtlPlacement);\n const [resolvedAnchorElement, setResolvedAnchorElement] = React.useState(resolveAnchorEl(anchorEl));\n React.useEffect(() => {\n if (popperRef.current) {\n popperRef.current.forceUpdate();\n }\n });\n React.useEffect(() => {\n if (anchorEl) {\n setResolvedAnchorElement(resolveAnchorEl(anchorEl));\n }\n }, [anchorEl]);\n useEnhancedEffect(() => {\n if (!resolvedAnchorElement || !open) {\n return undefined;\n }\n const handlePopperUpdate = data => {\n setPlacement(data.placement);\n };\n if (process.env.NODE_ENV !== 'production') {\n if (resolvedAnchorElement && isHTMLElement(resolvedAnchorElement) && resolvedAnchorElement.nodeType === 1) {\n const box = resolvedAnchorElement.getBoundingClientRect();\n if (process.env.NODE_ENV !== 'test' && box.top === 0 && box.left === 0 && box.right === 0 && box.bottom === 0) {\n console.warn(['MUI: The `anchorEl` prop provided to the component is invalid.', 'The anchor element should be part of the document layout.', \"Make sure the element is present in the document or that it's not display none.\"].join('\\n'));\n }\n }\n }\n let popperModifiers = [{\n name: 'preventOverflow',\n options: {\n altBoundary: disablePortal\n }\n }, {\n name: 'flip',\n options: {\n altBoundary: disablePortal\n }\n }, {\n name: 'onUpdate',\n enabled: true,\n phase: 'afterWrite',\n fn: ({\n state\n }) => {\n handlePopperUpdate(state);\n }\n }];\n if (modifiers != null) {\n popperModifiers = popperModifiers.concat(modifiers);\n }\n if (popperOptions && popperOptions.modifiers != null) {\n popperModifiers = popperModifiers.concat(popperOptions.modifiers);\n }\n const popper = createPopper(resolvedAnchorElement, tooltipRef.current, _extends({\n placement: rtlPlacement\n }, popperOptions, {\n modifiers: popperModifiers\n }));\n handlePopperRefRef.current(popper);\n return () => {\n popper.destroy();\n handlePopperRefRef.current(null);\n };\n }, [resolvedAnchorElement, disablePortal, modifiers, open, popperOptions, rtlPlacement]);\n const childProps = {\n placement: placement\n };\n if (TransitionProps !== null) {\n childProps.TransitionProps = TransitionProps;\n }\n const classes = useUtilityClasses();\n const Root = (_slots$root = slots.root) != null ? _slots$root : 'div';\n const rootProps = useSlotProps({\n elementType: Root,\n externalSlotProps: slotProps.root,\n externalForwardedProps: other,\n additionalProps: {\n role: 'tooltip',\n ref: ownRef\n },\n ownerState: props,\n className: classes.root\n });\n return /*#__PURE__*/_jsx(Root, _extends({}, rootProps, {\n children: typeof children === 'function' ? children(childProps) : children\n }));\n});\n\n/**\n * Poppers rely on the 3rd party library [Popper.js](https://popper.js.org/docs/v2/) for positioning.\n *\n * Demos:\n *\n * - [Popper](https://mui.com/base-ui/react-popper/)\n *\n * API:\n *\n * - [Popper API](https://mui.com/base-ui/react-popper/components-api/#popper)\n */\nconst Popper = /*#__PURE__*/React.forwardRef(function Popper(props, forwardedRef) {\n const {\n anchorEl,\n children,\n container: containerProp,\n direction = 'ltr',\n disablePortal = false,\n keepMounted = false,\n modifiers,\n open,\n placement = 'bottom',\n popperOptions = defaultPopperOptions,\n popperRef,\n style,\n transition = false,\n slotProps = {},\n slots = {}\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded2);\n const [exited, setExited] = React.useState(true);\n const handleEnter = () => {\n setExited(false);\n };\n const handleExited = () => {\n setExited(true);\n };\n if (!keepMounted && !open && (!transition || exited)) {\n return null;\n }\n\n // If the container prop is provided, use that\n // If the anchorEl prop is provided, use its parent body element as the container\n // If neither are provided let the Modal take care of choosing the container\n let container;\n if (containerProp) {\n container = containerProp;\n } else if (anchorEl) {\n const resolvedAnchorEl = resolveAnchorEl(anchorEl);\n container = resolvedAnchorEl && isHTMLElement(resolvedAnchorEl) ? ownerDocument(resolvedAnchorEl).body : ownerDocument(null).body;\n }\n const display = !open && keepMounted && (!transition || exited) ? 'none' : undefined;\n const transitionProps = transition ? {\n in: open,\n onEnter: handleEnter,\n onExited: handleExited\n } : undefined;\n return /*#__PURE__*/_jsx(Portal, {\n disablePortal: disablePortal,\n container: container,\n children: /*#__PURE__*/_jsx(PopperTooltip, _extends({\n anchorEl: anchorEl,\n direction: direction,\n disablePortal: disablePortal,\n modifiers: modifiers,\n ref: forwardedRef,\n open: transition ? !exited : open,\n placement: placement,\n popperOptions: popperOptions,\n popperRef: popperRef,\n slotProps: slotProps,\n slots: slots\n }, other, {\n style: _extends({\n // Prevents scroll issue, waiting for Popper.js to add this style once initiated.\n position: 'fixed',\n // Fix Popper.js display issue\n top: 0,\n left: 0,\n display\n }, style),\n TransitionProps: transitionProps,\n children: children\n }))\n });\n});\nprocess.env.NODE_ENV !== \"production\" ? Popper.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * An HTML element, [virtualElement](https://popper.js.org/docs/v2/virtual-elements/),\n * or a function that returns either.\n * It's used to set the position of the popper.\n * The return value will passed as the reference object of the Popper instance.\n */\n anchorEl: chainPropTypes(PropTypes.oneOfType([HTMLElementType, PropTypes.object, PropTypes.func]), props => {\n if (props.open) {\n const resolvedAnchorEl = resolveAnchorEl(props.anchorEl);\n if (resolvedAnchorEl && isHTMLElement(resolvedAnchorEl) && resolvedAnchorEl.nodeType === 1) {\n const box = resolvedAnchorEl.getBoundingClientRect();\n if (process.env.NODE_ENV !== 'test' && box.top === 0 && box.left === 0 && box.right === 0 && box.bottom === 0) {\n return new Error(['MUI: The `anchorEl` prop provided to the component is invalid.', 'The anchor element should be part of the document layout.', \"Make sure the element is present in the document or that it's not display none.\"].join('\\n'));\n }\n } else if (!resolvedAnchorEl || typeof resolvedAnchorEl.getBoundingClientRect !== 'function' || isVirtualElement(resolvedAnchorEl) && resolvedAnchorEl.contextElement != null && resolvedAnchorEl.contextElement.nodeType !== 1) {\n return new Error(['MUI: The `anchorEl` prop provided to the component is invalid.', 'It should be an HTML element instance or a virtualElement ', '(https://popper.js.org/docs/v2/virtual-elements/).'].join('\\n'));\n }\n }\n return null;\n }),\n /**\n * Popper render function or node.\n */\n children: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.node, PropTypes.func]),\n /**\n * An HTML element or function that returns one.\n * The `container` will have the portal children appended to it.\n *\n * You can also provide a callback, which is called in a React layout effect.\n * This lets you set the container from a ref, and also makes server-side rendering possible.\n *\n * By default, it uses the body of the top-level document object,\n * so it's simply `document.body` most of the time.\n */\n container: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.func]),\n /**\n * Direction of the text.\n * @default 'ltr'\n */\n direction: PropTypes.oneOf(['ltr', 'rtl']),\n /**\n * The `children` will be under the DOM hierarchy of the parent component.\n * @default false\n */\n disablePortal: PropTypes.bool,\n /**\n * Always keep the children in the DOM.\n * This prop can be useful in SEO situation or\n * when you want to maximize the responsiveness of the Popper.\n * @default false\n */\n keepMounted: PropTypes.bool,\n /**\n * Popper.js is based on a \"plugin-like\" architecture,\n * most of its features are fully encapsulated \"modifiers\".\n *\n * A modifier is a function that is called each time Popper.js needs to\n * compute the position of the popper.\n * For this reason, modifiers should be very performant to avoid bottlenecks.\n * To learn how to create a modifier, [read the modifiers documentation](https://popper.js.org/docs/v2/modifiers/).\n */\n modifiers: PropTypes.arrayOf(PropTypes.shape({\n data: PropTypes.object,\n effect: PropTypes.func,\n enabled: PropTypes.bool,\n fn: PropTypes.func,\n name: PropTypes.any,\n options: PropTypes.object,\n phase: PropTypes.oneOf(['afterMain', 'afterRead', 'afterWrite', 'beforeMain', 'beforeRead', 'beforeWrite', 'main', 'read', 'write']),\n requires: PropTypes.arrayOf(PropTypes.string),\n requiresIfExists: PropTypes.arrayOf(PropTypes.string)\n })),\n /**\n * If `true`, the component is shown.\n */\n open: PropTypes.bool.isRequired,\n /**\n * Popper placement.\n * @default 'bottom'\n */\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n /**\n * Options provided to the [`Popper.js`](https://popper.js.org/docs/v2/constructors/#options) instance.\n * @default {}\n */\n popperOptions: PropTypes.shape({\n modifiers: PropTypes.array,\n onFirstUpdate: PropTypes.func,\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n strategy: PropTypes.oneOf(['absolute', 'fixed'])\n }),\n /**\n * A ref that points to the used popper instance.\n */\n popperRef: refType,\n /**\n * The props used for each slot inside the Popper.\n * @default {}\n */\n slotProps: PropTypes.shape({\n root: PropTypes.oneOfType([PropTypes.func, PropTypes.object])\n }),\n /**\n * The components used for each slot inside the Popper.\n * Either a string to use a HTML element or a component.\n * @default {}\n */\n slots: PropTypes.shape({\n root: PropTypes.elementType\n }),\n /**\n * Help supporting a react-transition-group/Transition component.\n * @default false\n */\n transition: PropTypes.bool\n} : void 0;\nexport { Popper };","'use client';\n\nimport * as React from 'react';\nimport { useTheme as useThemeSystem } from '@mui/system';\nimport defaultTheme from './defaultTheme';\nimport THEME_ID from './identifier';\nexport default function useTheme() {\n const theme = useThemeSystem(defaultTheme);\n if (process.env.NODE_ENV !== 'production') {\n // eslint-disable-next-line react-hooks/rules-of-hooks\n React.useDebugValue(theme);\n }\n return theme[THEME_ID] || theme;\n}","export default function _setPrototypeOf(o, p) {\n _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function _setPrototypeOf(o, p) {\n o.__proto__ = p;\n return o;\n };\n return _setPrototypeOf(o, p);\n}","import setPrototypeOf from \"./setPrototypeOf.js\";\nexport default function _inheritsLoose(subClass, superClass) {\n subClass.prototype = Object.create(superClass.prototype);\n subClass.prototype.constructor = subClass;\n setPrototypeOf(subClass, superClass);\n}","export default {\n disabled: false\n};","import PropTypes from 'prop-types';\nexport var timeoutsShape = process.env.NODE_ENV !== 'production' ? PropTypes.oneOfType([PropTypes.number, PropTypes.shape({\n enter: PropTypes.number,\n exit: PropTypes.number,\n appear: PropTypes.number\n}).isRequired]) : null;\nexport var classNamesShape = process.env.NODE_ENV !== 'production' ? PropTypes.oneOfType([PropTypes.string, PropTypes.shape({\n enter: PropTypes.string,\n exit: PropTypes.string,\n active: PropTypes.string\n}), PropTypes.shape({\n enter: PropTypes.string,\n enterDone: PropTypes.string,\n enterActive: PropTypes.string,\n exit: PropTypes.string,\n exitDone: PropTypes.string,\n exitActive: PropTypes.string\n})]) : null;","import React from 'react';\nexport default React.createContext(null);","export var forceReflow = function forceReflow(node) {\n return node.scrollTop;\n};","import _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _inheritsLoose from \"@babel/runtime/helpers/esm/inheritsLoose\";\nimport PropTypes from 'prop-types';\nimport React from 'react';\nimport ReactDOM from 'react-dom';\nimport config from './config';\nimport { timeoutsShape } from './utils/PropTypes';\nimport TransitionGroupContext from './TransitionGroupContext';\nimport { forceReflow } from './utils/reflow';\nexport var UNMOUNTED = 'unmounted';\nexport var EXITED = 'exited';\nexport var ENTERING = 'entering';\nexport var ENTERED = 'entered';\nexport var EXITING = 'exiting';\n/**\n * The Transition component lets you describe a transition from one component\n * state to another _over time_ with a simple declarative API. Most commonly\n * it's used to animate the mounting and unmounting of a component, but can also\n * be used to describe in-place transition states as well.\n *\n * ---\n *\n * **Note**: `Transition` is a platform-agnostic base component. If you're using\n * transitions in CSS, you'll probably want to use\n * [`CSSTransition`](https://reactcommunity.org/react-transition-group/css-transition)\n * instead. It inherits all the features of `Transition`, but contains\n * additional features necessary to play nice with CSS transitions (hence the\n * name of the component).\n *\n * ---\n *\n * By default the `Transition` component does not alter the behavior of the\n * component it renders, it only tracks \"enter\" and \"exit\" states for the\n * components. It's up to you to give meaning and effect to those states. For\n * example we can add styles to a component when it enters or exits:\n *\n * ```jsx\n * import { Transition } from 'react-transition-group';\n *\n * const duration = 300;\n *\n * const defaultStyle = {\n * transition: `opacity ${duration}ms ease-in-out`,\n * opacity: 0,\n * }\n *\n * const transitionStyles = {\n * entering: { opacity: 1 },\n * entered: { opacity: 1 },\n * exiting: { opacity: 0 },\n * exited: { opacity: 0 },\n * };\n *\n * const Fade = ({ in: inProp }) => (\n * \n * {state => (\n *
    \n * I'm a fade Transition!\n *
    \n * )}\n *
    \n * );\n * ```\n *\n * There are 4 main states a Transition can be in:\n * - `'entering'`\n * - `'entered'`\n * - `'exiting'`\n * - `'exited'`\n *\n * Transition state is toggled via the `in` prop. When `true` the component\n * begins the \"Enter\" stage. During this stage, the component will shift from\n * its current transition state, to `'entering'` for the duration of the\n * transition and then to the `'entered'` stage once it's complete. Let's take\n * the following example (we'll use the\n * [useState](https://reactjs.org/docs/hooks-reference.html#usestate) hook):\n *\n * ```jsx\n * function App() {\n * const [inProp, setInProp] = useState(false);\n * return (\n *
    \n * \n * {state => (\n * // ...\n * )}\n * \n * \n *
    \n * );\n * }\n * ```\n *\n * When the button is clicked the component will shift to the `'entering'` state\n * and stay there for 500ms (the value of `timeout`) before it finally switches\n * to `'entered'`.\n *\n * When `in` is `false` the same thing happens except the state moves from\n * `'exiting'` to `'exited'`.\n */\n\nvar Transition = /*#__PURE__*/function (_React$Component) {\n _inheritsLoose(Transition, _React$Component);\n\n function Transition(props, context) {\n var _this;\n\n _this = _React$Component.call(this, props, context) || this;\n var parentGroup = context; // In the context of a TransitionGroup all enters are really appears\n\n var appear = parentGroup && !parentGroup.isMounting ? props.enter : props.appear;\n var initialStatus;\n _this.appearStatus = null;\n\n if (props.in) {\n if (appear) {\n initialStatus = EXITED;\n _this.appearStatus = ENTERING;\n } else {\n initialStatus = ENTERED;\n }\n } else {\n if (props.unmountOnExit || props.mountOnEnter) {\n initialStatus = UNMOUNTED;\n } else {\n initialStatus = EXITED;\n }\n }\n\n _this.state = {\n status: initialStatus\n };\n _this.nextCallback = null;\n return _this;\n }\n\n Transition.getDerivedStateFromProps = function getDerivedStateFromProps(_ref, prevState) {\n var nextIn = _ref.in;\n\n if (nextIn && prevState.status === UNMOUNTED) {\n return {\n status: EXITED\n };\n }\n\n return null;\n } // getSnapshotBeforeUpdate(prevProps) {\n // let nextStatus = null\n // if (prevProps !== this.props) {\n // const { status } = this.state\n // if (this.props.in) {\n // if (status !== ENTERING && status !== ENTERED) {\n // nextStatus = ENTERING\n // }\n // } else {\n // if (status === ENTERING || status === ENTERED) {\n // nextStatus = EXITING\n // }\n // }\n // }\n // return { nextStatus }\n // }\n ;\n\n var _proto = Transition.prototype;\n\n _proto.componentDidMount = function componentDidMount() {\n this.updateStatus(true, this.appearStatus);\n };\n\n _proto.componentDidUpdate = function componentDidUpdate(prevProps) {\n var nextStatus = null;\n\n if (prevProps !== this.props) {\n var status = this.state.status;\n\n if (this.props.in) {\n if (status !== ENTERING && status !== ENTERED) {\n nextStatus = ENTERING;\n }\n } else {\n if (status === ENTERING || status === ENTERED) {\n nextStatus = EXITING;\n }\n }\n }\n\n this.updateStatus(false, nextStatus);\n };\n\n _proto.componentWillUnmount = function componentWillUnmount() {\n this.cancelNextCallback();\n };\n\n _proto.getTimeouts = function getTimeouts() {\n var timeout = this.props.timeout;\n var exit, enter, appear;\n exit = enter = appear = timeout;\n\n if (timeout != null && typeof timeout !== 'number') {\n exit = timeout.exit;\n enter = timeout.enter; // TODO: remove fallback for next major\n\n appear = timeout.appear !== undefined ? timeout.appear : enter;\n }\n\n return {\n exit: exit,\n enter: enter,\n appear: appear\n };\n };\n\n _proto.updateStatus = function updateStatus(mounting, nextStatus) {\n if (mounting === void 0) {\n mounting = false;\n }\n\n if (nextStatus !== null) {\n // nextStatus will always be ENTERING or EXITING.\n this.cancelNextCallback();\n\n if (nextStatus === ENTERING) {\n if (this.props.unmountOnExit || this.props.mountOnEnter) {\n var node = this.props.nodeRef ? this.props.nodeRef.current : ReactDOM.findDOMNode(this); // https://github.com/reactjs/react-transition-group/pull/749\n // With unmountOnExit or mountOnEnter, the enter animation should happen at the transition between `exited` and `entering`.\n // To make the animation happen, we have to separate each rendering and avoid being processed as batched.\n\n if (node) forceReflow(node);\n }\n\n this.performEnter(mounting);\n } else {\n this.performExit();\n }\n } else if (this.props.unmountOnExit && this.state.status === EXITED) {\n this.setState({\n status: UNMOUNTED\n });\n }\n };\n\n _proto.performEnter = function performEnter(mounting) {\n var _this2 = this;\n\n var enter = this.props.enter;\n var appearing = this.context ? this.context.isMounting : mounting;\n\n var _ref2 = this.props.nodeRef ? [appearing] : [ReactDOM.findDOMNode(this), appearing],\n maybeNode = _ref2[0],\n maybeAppearing = _ref2[1];\n\n var timeouts = this.getTimeouts();\n var enterTimeout = appearing ? timeouts.appear : timeouts.enter; // no enter animation skip right to ENTERED\n // if we are mounting and running this it means appear _must_ be set\n\n if (!mounting && !enter || config.disabled) {\n this.safeSetState({\n status: ENTERED\n }, function () {\n _this2.props.onEntered(maybeNode);\n });\n return;\n }\n\n this.props.onEnter(maybeNode, maybeAppearing);\n this.safeSetState({\n status: ENTERING\n }, function () {\n _this2.props.onEntering(maybeNode, maybeAppearing);\n\n _this2.onTransitionEnd(enterTimeout, function () {\n _this2.safeSetState({\n status: ENTERED\n }, function () {\n _this2.props.onEntered(maybeNode, maybeAppearing);\n });\n });\n });\n };\n\n _proto.performExit = function performExit() {\n var _this3 = this;\n\n var exit = this.props.exit;\n var timeouts = this.getTimeouts();\n var maybeNode = this.props.nodeRef ? undefined : ReactDOM.findDOMNode(this); // no exit animation skip right to EXITED\n\n if (!exit || config.disabled) {\n this.safeSetState({\n status: EXITED\n }, function () {\n _this3.props.onExited(maybeNode);\n });\n return;\n }\n\n this.props.onExit(maybeNode);\n this.safeSetState({\n status: EXITING\n }, function () {\n _this3.props.onExiting(maybeNode);\n\n _this3.onTransitionEnd(timeouts.exit, function () {\n _this3.safeSetState({\n status: EXITED\n }, function () {\n _this3.props.onExited(maybeNode);\n });\n });\n });\n };\n\n _proto.cancelNextCallback = function cancelNextCallback() {\n if (this.nextCallback !== null) {\n this.nextCallback.cancel();\n this.nextCallback = null;\n }\n };\n\n _proto.safeSetState = function safeSetState(nextState, callback) {\n // This shouldn't be necessary, but there are weird race conditions with\n // setState callbacks and unmounting in testing, so always make sure that\n // we can cancel any pending setState callbacks after we unmount.\n callback = this.setNextCallback(callback);\n this.setState(nextState, callback);\n };\n\n _proto.setNextCallback = function setNextCallback(callback) {\n var _this4 = this;\n\n var active = true;\n\n this.nextCallback = function (event) {\n if (active) {\n active = false;\n _this4.nextCallback = null;\n callback(event);\n }\n };\n\n this.nextCallback.cancel = function () {\n active = false;\n };\n\n return this.nextCallback;\n };\n\n _proto.onTransitionEnd = function onTransitionEnd(timeout, handler) {\n this.setNextCallback(handler);\n var node = this.props.nodeRef ? this.props.nodeRef.current : ReactDOM.findDOMNode(this);\n var doesNotHaveTimeoutOrListener = timeout == null && !this.props.addEndListener;\n\n if (!node || doesNotHaveTimeoutOrListener) {\n setTimeout(this.nextCallback, 0);\n return;\n }\n\n if (this.props.addEndListener) {\n var _ref3 = this.props.nodeRef ? [this.nextCallback] : [node, this.nextCallback],\n maybeNode = _ref3[0],\n maybeNextCallback = _ref3[1];\n\n this.props.addEndListener(maybeNode, maybeNextCallback);\n }\n\n if (timeout != null) {\n setTimeout(this.nextCallback, timeout);\n }\n };\n\n _proto.render = function render() {\n var status = this.state.status;\n\n if (status === UNMOUNTED) {\n return null;\n }\n\n var _this$props = this.props,\n children = _this$props.children,\n _in = _this$props.in,\n _mountOnEnter = _this$props.mountOnEnter,\n _unmountOnExit = _this$props.unmountOnExit,\n _appear = _this$props.appear,\n _enter = _this$props.enter,\n _exit = _this$props.exit,\n _timeout = _this$props.timeout,\n _addEndListener = _this$props.addEndListener,\n _onEnter = _this$props.onEnter,\n _onEntering = _this$props.onEntering,\n _onEntered = _this$props.onEntered,\n _onExit = _this$props.onExit,\n _onExiting = _this$props.onExiting,\n _onExited = _this$props.onExited,\n _nodeRef = _this$props.nodeRef,\n childProps = _objectWithoutPropertiesLoose(_this$props, [\"children\", \"in\", \"mountOnEnter\", \"unmountOnExit\", \"appear\", \"enter\", \"exit\", \"timeout\", \"addEndListener\", \"onEnter\", \"onEntering\", \"onEntered\", \"onExit\", \"onExiting\", \"onExited\", \"nodeRef\"]);\n\n return (\n /*#__PURE__*/\n // allows for nested Transitions\n React.createElement(TransitionGroupContext.Provider, {\n value: null\n }, typeof children === 'function' ? children(status, childProps) : React.cloneElement(React.Children.only(children), childProps))\n );\n };\n\n return Transition;\n}(React.Component);\n\nTransition.contextType = TransitionGroupContext;\nTransition.propTypes = process.env.NODE_ENV !== \"production\" ? {\n /**\n * A React reference to DOM element that need to transition:\n * https://stackoverflow.com/a/51127130/4671932\n *\n * - When `nodeRef` prop is used, `node` is not passed to callback functions\n * (e.g. `onEnter`) because user already has direct access to the node.\n * - When changing `key` prop of `Transition` in a `TransitionGroup` a new\n * `nodeRef` need to be provided to `Transition` with changed `key` prop\n * (see\n * [test/CSSTransition-test.js](https://github.com/reactjs/react-transition-group/blob/13435f897b3ab71f6e19d724f145596f5910581c/test/CSSTransition-test.js#L362-L437)).\n */\n nodeRef: PropTypes.shape({\n current: typeof Element === 'undefined' ? PropTypes.any : function (propValue, key, componentName, location, propFullName, secret) {\n var value = propValue[key];\n return PropTypes.instanceOf(value && 'ownerDocument' in value ? value.ownerDocument.defaultView.Element : Element)(propValue, key, componentName, location, propFullName, secret);\n }\n }),\n\n /**\n * A `function` child can be used instead of a React element. This function is\n * called with the current transition status (`'entering'`, `'entered'`,\n * `'exiting'`, `'exited'`), which can be used to apply context\n * specific props to a component.\n *\n * ```jsx\n * \n * {state => (\n * \n * )}\n * \n * ```\n */\n children: PropTypes.oneOfType([PropTypes.func.isRequired, PropTypes.element.isRequired]).isRequired,\n\n /**\n * Show the component; triggers the enter or exit states\n */\n in: PropTypes.bool,\n\n /**\n * By default the child component is mounted immediately along with\n * the parent `Transition` component. If you want to \"lazy mount\" the component on the\n * first `in={true}` you can set `mountOnEnter`. After the first enter transition the component will stay\n * mounted, even on \"exited\", unless you also specify `unmountOnExit`.\n */\n mountOnEnter: PropTypes.bool,\n\n /**\n * By default the child component stays mounted after it reaches the `'exited'` state.\n * Set `unmountOnExit` if you'd prefer to unmount the component after it finishes exiting.\n */\n unmountOnExit: PropTypes.bool,\n\n /**\n * By default the child component does not perform the enter transition when\n * it first mounts, regardless of the value of `in`. If you want this\n * behavior, set both `appear` and `in` to `true`.\n *\n * > **Note**: there are no special appear states like `appearing`/`appeared`, this prop\n * > only adds an additional enter transition. However, in the\n * > `` component that first enter transition does result in\n * > additional `.appear-*` classes, that way you can choose to style it\n * > differently.\n */\n appear: PropTypes.bool,\n\n /**\n * Enable or disable enter transitions.\n */\n enter: PropTypes.bool,\n\n /**\n * Enable or disable exit transitions.\n */\n exit: PropTypes.bool,\n\n /**\n * The duration of the transition, in milliseconds.\n * Required unless `addEndListener` is provided.\n *\n * You may specify a single timeout for all transitions:\n *\n * ```jsx\n * timeout={500}\n * ```\n *\n * or individually:\n *\n * ```jsx\n * timeout={{\n * appear: 500,\n * enter: 300,\n * exit: 500,\n * }}\n * ```\n *\n * - `appear` defaults to the value of `enter`\n * - `enter` defaults to `0`\n * - `exit` defaults to `0`\n *\n * @type {number | { enter?: number, exit?: number, appear?: number }}\n */\n timeout: function timeout(props) {\n var pt = timeoutsShape;\n if (!props.addEndListener) pt = pt.isRequired;\n\n for (var _len = arguments.length, args = new Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) {\n args[_key - 1] = arguments[_key];\n }\n\n return pt.apply(void 0, [props].concat(args));\n },\n\n /**\n * Add a custom transition end trigger. Called with the transitioning\n * DOM node and a `done` callback. Allows for more fine grained transition end\n * logic. Timeouts are still used as a fallback if provided.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * ```jsx\n * addEndListener={(node, done) => {\n * // use the css transitionend event to mark the finish of a transition\n * node.addEventListener('transitionend', done, false);\n * }}\n * ```\n */\n addEndListener: PropTypes.func,\n\n /**\n * Callback fired before the \"entering\" status is applied. An extra parameter\n * `isAppearing` is supplied to indicate if the enter stage is occurring on the initial mount\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement, isAppearing: bool) -> void\n */\n onEnter: PropTypes.func,\n\n /**\n * Callback fired after the \"entering\" status is applied. An extra parameter\n * `isAppearing` is supplied to indicate if the enter stage is occurring on the initial mount\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement, isAppearing: bool)\n */\n onEntering: PropTypes.func,\n\n /**\n * Callback fired after the \"entered\" status is applied. An extra parameter\n * `isAppearing` is supplied to indicate if the enter stage is occurring on the initial mount\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement, isAppearing: bool) -> void\n */\n onEntered: PropTypes.func,\n\n /**\n * Callback fired before the \"exiting\" status is applied.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement) -> void\n */\n onExit: PropTypes.func,\n\n /**\n * Callback fired after the \"exiting\" status is applied.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement) -> void\n */\n onExiting: PropTypes.func,\n\n /**\n * Callback fired after the \"exited\" status is applied.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed\n *\n * @type Function(node: HtmlElement) -> void\n */\n onExited: PropTypes.func\n} : {}; // Name the function so it is clearer in the documentation\n\nfunction noop() {}\n\nTransition.defaultProps = {\n in: false,\n mountOnEnter: false,\n unmountOnExit: false,\n appear: false,\n enter: true,\n exit: true,\n onEnter: noop,\n onEntering: noop,\n onEntered: noop,\n onExit: noop,\n onExiting: noop,\n onExited: noop\n};\nTransition.UNMOUNTED = UNMOUNTED;\nTransition.EXITED = EXITED;\nTransition.ENTERING = ENTERING;\nTransition.ENTERED = ENTERED;\nTransition.EXITING = EXITING;\nexport default Transition;","export const reflow = node => node.scrollTop;\nexport function getTransitionProps(props, options) {\n var _style$transitionDura, _style$transitionTimi;\n const {\n timeout,\n easing,\n style = {}\n } = props;\n return {\n duration: (_style$transitionDura = style.transitionDuration) != null ? _style$transitionDura : typeof timeout === 'number' ? timeout : timeout[options.mode] || 0,\n easing: (_style$transitionTimi = style.transitionTimingFunction) != null ? _style$transitionTimi : typeof easing === 'object' ? easing[options.mode] : easing,\n delay: style.transitionDelay\n };\n}","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"addEndListener\", \"appear\", \"children\", \"easing\", \"in\", \"onEnter\", \"onEntered\", \"onEntering\", \"onExit\", \"onExited\", \"onExiting\", \"style\", \"timeout\", \"TransitionComponent\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport { elementAcceptingRef, unstable_useTimeout as useTimeout } from '@mui/utils';\nimport { Transition } from 'react-transition-group';\nimport useTheme from '../styles/useTheme';\nimport { getTransitionProps, reflow } from '../transitions/utils';\nimport useForkRef from '../utils/useForkRef';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nfunction getScale(value) {\n return `scale(${value}, ${value ** 2})`;\n}\nconst styles = {\n entering: {\n opacity: 1,\n transform: getScale(1)\n },\n entered: {\n opacity: 1,\n transform: 'none'\n }\n};\n\n/*\n TODO v6: remove\n Conditionally apply a workaround for the CSS transition bug in Safari 15.4 / WebKit browsers.\n */\nconst isWebKit154 = typeof navigator !== 'undefined' && /^((?!chrome|android).)*(safari|mobile)/i.test(navigator.userAgent) && /(os |version\\/)15(.|_)4/i.test(navigator.userAgent);\n\n/**\n * The Grow transition is used by the [Tooltip](/material-ui/react-tooltip/) and\n * [Popover](/material-ui/react-popover/) components.\n * It uses [react-transition-group](https://github.com/reactjs/react-transition-group) internally.\n */\nconst Grow = /*#__PURE__*/React.forwardRef(function Grow(props, ref) {\n const {\n addEndListener,\n appear = true,\n children,\n easing,\n in: inProp,\n onEnter,\n onEntered,\n onEntering,\n onExit,\n onExited,\n onExiting,\n style,\n timeout = 'auto',\n // eslint-disable-next-line react/prop-types\n TransitionComponent = Transition\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const timer = useTimeout();\n const autoTimeout = React.useRef();\n const theme = useTheme();\n const nodeRef = React.useRef(null);\n const handleRef = useForkRef(nodeRef, children.ref, ref);\n const normalizedTransitionCallback = callback => maybeIsAppearing => {\n if (callback) {\n const node = nodeRef.current;\n\n // onEnterXxx and onExitXxx callbacks have a different arguments.length value.\n if (maybeIsAppearing === undefined) {\n callback(node);\n } else {\n callback(node, maybeIsAppearing);\n }\n }\n };\n const handleEntering = normalizedTransitionCallback(onEntering);\n const handleEnter = normalizedTransitionCallback((node, isAppearing) => {\n reflow(node); // So the animation always start from the start.\n\n const {\n duration: transitionDuration,\n delay,\n easing: transitionTimingFunction\n } = getTransitionProps({\n style,\n timeout,\n easing\n }, {\n mode: 'enter'\n });\n let duration;\n if (timeout === 'auto') {\n duration = theme.transitions.getAutoHeightDuration(node.clientHeight);\n autoTimeout.current = duration;\n } else {\n duration = transitionDuration;\n }\n node.style.transition = [theme.transitions.create('opacity', {\n duration,\n delay\n }), theme.transitions.create('transform', {\n duration: isWebKit154 ? duration : duration * 0.666,\n delay,\n easing: transitionTimingFunction\n })].join(',');\n if (onEnter) {\n onEnter(node, isAppearing);\n }\n });\n const handleEntered = normalizedTransitionCallback(onEntered);\n const handleExiting = normalizedTransitionCallback(onExiting);\n const handleExit = normalizedTransitionCallback(node => {\n const {\n duration: transitionDuration,\n delay,\n easing: transitionTimingFunction\n } = getTransitionProps({\n style,\n timeout,\n easing\n }, {\n mode: 'exit'\n });\n let duration;\n if (timeout === 'auto') {\n duration = theme.transitions.getAutoHeightDuration(node.clientHeight);\n autoTimeout.current = duration;\n } else {\n duration = transitionDuration;\n }\n node.style.transition = [theme.transitions.create('opacity', {\n duration,\n delay\n }), theme.transitions.create('transform', {\n duration: isWebKit154 ? duration : duration * 0.666,\n delay: isWebKit154 ? delay : delay || duration * 0.333,\n easing: transitionTimingFunction\n })].join(',');\n node.style.opacity = 0;\n node.style.transform = getScale(0.75);\n if (onExit) {\n onExit(node);\n }\n });\n const handleExited = normalizedTransitionCallback(onExited);\n const handleAddEndListener = next => {\n if (timeout === 'auto') {\n timer.start(autoTimeout.current || 0, next);\n }\n if (addEndListener) {\n // Old call signature before `react-transition-group` implemented `nodeRef`\n addEndListener(nodeRef.current, next);\n }\n };\n return /*#__PURE__*/_jsx(TransitionComponent, _extends({\n appear: appear,\n in: inProp,\n nodeRef: nodeRef,\n onEnter: handleEnter,\n onEntered: handleEntered,\n onEntering: handleEntering,\n onExit: handleExit,\n onExited: handleExited,\n onExiting: handleExiting,\n addEndListener: handleAddEndListener,\n timeout: timeout === 'auto' ? null : timeout\n }, other, {\n children: (state, childProps) => {\n return /*#__PURE__*/React.cloneElement(children, _extends({\n style: _extends({\n opacity: 0,\n transform: getScale(0.75),\n visibility: state === 'exited' && !inProp ? 'hidden' : undefined\n }, styles[state], style, children.props.style),\n ref: handleRef\n }, childProps));\n }\n }));\n});\nprocess.env.NODE_ENV !== \"production\" ? Grow.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the d.ts file and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * Add a custom transition end trigger. Called with the transitioning DOM\n * node and a done callback. Allows for more fine grained transition end\n * logic. Note: Timeouts are still used as a fallback if provided.\n */\n addEndListener: PropTypes.func,\n /**\n * Perform the enter transition when it first mounts if `in` is also `true`.\n * Set this to `false` to disable this behavior.\n * @default true\n */\n appear: PropTypes.bool,\n /**\n * A single child content element.\n */\n children: elementAcceptingRef.isRequired,\n /**\n * The transition timing function.\n * You may specify a single easing or a object containing enter and exit values.\n */\n easing: PropTypes.oneOfType([PropTypes.shape({\n enter: PropTypes.string,\n exit: PropTypes.string\n }), PropTypes.string]),\n /**\n * If `true`, the component will transition in.\n */\n in: PropTypes.bool,\n /**\n * @ignore\n */\n onEnter: PropTypes.func,\n /**\n * @ignore\n */\n onEntered: PropTypes.func,\n /**\n * @ignore\n */\n onEntering: PropTypes.func,\n /**\n * @ignore\n */\n onExit: PropTypes.func,\n /**\n * @ignore\n */\n onExited: PropTypes.func,\n /**\n * @ignore\n */\n onExiting: PropTypes.func,\n /**\n * @ignore\n */\n style: PropTypes.object,\n /**\n * The duration for the transition, in milliseconds.\n * You may specify a single timeout for all transitions, or individually with an object.\n *\n * Set to 'auto' to automatically calculate transition time based on height.\n * @default 'auto'\n */\n timeout: PropTypes.oneOfType([PropTypes.oneOf(['auto']), PropTypes.number, PropTypes.shape({\n appear: PropTypes.number,\n enter: PropTypes.number,\n exit: PropTypes.number\n })])\n} : void 0;\nGrow.muiSupportAuto = true;\nexport default Grow;","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"anchorEl\", \"component\", \"components\", \"componentsProps\", \"container\", \"disablePortal\", \"keepMounted\", \"modifiers\", \"open\", \"placement\", \"popperOptions\", \"popperRef\", \"transition\", \"slots\", \"slotProps\"];\nimport { Popper as BasePopper } from '@mui/base/Popper';\nimport { useThemeWithoutDefault as useTheme } from '@mui/system';\nimport { HTMLElementType, refType } from '@mui/utils';\nimport PropTypes from 'prop-types';\nimport * as React from 'react';\nimport { styled, useThemeProps } from '../styles';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nconst PopperRoot = styled(BasePopper, {\n name: 'MuiPopper',\n slot: 'Root',\n overridesResolver: (props, styles) => styles.root\n})({});\n\n/**\n *\n * Demos:\n *\n * - [Autocomplete](https://mui.com/material-ui/react-autocomplete/)\n * - [Menu](https://mui.com/material-ui/react-menu/)\n * - [Popper](https://mui.com/material-ui/react-popper/)\n *\n * API:\n *\n * - [Popper API](https://mui.com/material-ui/api/popper/)\n */\nconst Popper = /*#__PURE__*/React.forwardRef(function Popper(inProps, ref) {\n var _slots$root;\n const theme = useTheme();\n const props = useThemeProps({\n props: inProps,\n name: 'MuiPopper'\n });\n const {\n anchorEl,\n component,\n components,\n componentsProps,\n container,\n disablePortal,\n keepMounted,\n modifiers,\n open,\n placement,\n popperOptions,\n popperRef,\n transition,\n slots,\n slotProps\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const RootComponent = (_slots$root = slots == null ? void 0 : slots.root) != null ? _slots$root : components == null ? void 0 : components.Root;\n const otherProps = _extends({\n anchorEl,\n container,\n disablePortal,\n keepMounted,\n modifiers,\n open,\n placement,\n popperOptions,\n popperRef,\n transition\n }, other);\n return /*#__PURE__*/_jsx(PopperRoot, _extends({\n as: component,\n direction: theme == null ? void 0 : theme.direction,\n slots: {\n root: RootComponent\n },\n slotProps: slotProps != null ? slotProps : componentsProps\n }, otherProps, {\n ref: ref\n }));\n});\nprocess.env.NODE_ENV !== \"production\" ? Popper.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * An HTML element, [virtualElement](https://popper.js.org/docs/v2/virtual-elements/),\n * or a function that returns either.\n * It's used to set the position of the popper.\n * The return value will passed as the reference object of the Popper instance.\n */\n anchorEl: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.object, PropTypes.func]),\n /**\n * Popper render function or node.\n */\n children: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.node, PropTypes.func]),\n /**\n * The component used for the root node.\n * Either a string to use a HTML element or a component.\n */\n component: PropTypes.elementType,\n /**\n * The components used for each slot inside the Popper.\n * Either a string to use a HTML element or a component.\n * @default {}\n */\n components: PropTypes.shape({\n Root: PropTypes.elementType\n }),\n /**\n * The props used for each slot inside the Popper.\n * @default {}\n */\n componentsProps: PropTypes.shape({\n root: PropTypes.oneOfType([PropTypes.func, PropTypes.object])\n }),\n /**\n * An HTML element or function that returns one.\n * The `container` will have the portal children appended to it.\n *\n * You can also provide a callback, which is called in a React layout effect.\n * This lets you set the container from a ref, and also makes server-side rendering possible.\n *\n * By default, it uses the body of the top-level document object,\n * so it's simply `document.body` most of the time.\n */\n container: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.func]),\n /**\n * The `children` will be under the DOM hierarchy of the parent component.\n * @default false\n */\n disablePortal: PropTypes.bool,\n /**\n * Always keep the children in the DOM.\n * This prop can be useful in SEO situation or\n * when you want to maximize the responsiveness of the Popper.\n * @default false\n */\n keepMounted: PropTypes.bool,\n /**\n * Popper.js is based on a \"plugin-like\" architecture,\n * most of its features are fully encapsulated \"modifiers\".\n *\n * A modifier is a function that is called each time Popper.js needs to\n * compute the position of the popper.\n * For this reason, modifiers should be very performant to avoid bottlenecks.\n * To learn how to create a modifier, [read the modifiers documentation](https://popper.js.org/docs/v2/modifiers/).\n */\n modifiers: PropTypes.arrayOf(PropTypes.shape({\n data: PropTypes.object,\n effect: PropTypes.func,\n enabled: PropTypes.bool,\n fn: PropTypes.func,\n name: PropTypes.any,\n options: PropTypes.object,\n phase: PropTypes.oneOf(['afterMain', 'afterRead', 'afterWrite', 'beforeMain', 'beforeRead', 'beforeWrite', 'main', 'read', 'write']),\n requires: PropTypes.arrayOf(PropTypes.string),\n requiresIfExists: PropTypes.arrayOf(PropTypes.string)\n })),\n /**\n * If `true`, the component is shown.\n */\n open: PropTypes.bool.isRequired,\n /**\n * Popper placement.\n * @default 'bottom'\n */\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n /**\n * Options provided to the [`Popper.js`](https://popper.js.org/docs/v2/constructors/#options) instance.\n * @default {}\n */\n popperOptions: PropTypes.shape({\n modifiers: PropTypes.array,\n onFirstUpdate: PropTypes.func,\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n strategy: PropTypes.oneOf(['absolute', 'fixed'])\n }),\n /**\n * A ref that points to the used popper instance.\n */\n popperRef: refType,\n /**\n * The props used for each slot inside the Popper.\n * @default {}\n */\n slotProps: PropTypes.shape({\n root: PropTypes.oneOfType([PropTypes.func, PropTypes.object])\n }),\n /**\n * The components used for each slot inside the Popper.\n * Either a string to use a HTML element or a component.\n * @default {}\n */\n slots: PropTypes.shape({\n root: PropTypes.elementType\n }),\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Help supporting a react-transition-group/Transition component.\n * @default false\n */\n transition: PropTypes.bool\n} : void 0;\nexport default Popper;","import generateUtilityClasses from '@mui/utils/generateUtilityClasses';\nimport generateUtilityClass from '@mui/utils/generateUtilityClass';\nexport function getTooltipUtilityClass(slot) {\n return generateUtilityClass('MuiTooltip', slot);\n}\nconst tooltipClasses = generateUtilityClasses('MuiTooltip', ['popper', 'popperInteractive', 'popperArrow', 'popperClose', 'tooltip', 'tooltipArrow', 'touch', 'tooltipPlacementLeft', 'tooltipPlacementRight', 'tooltipPlacementTop', 'tooltipPlacementBottom', 'arrow']);\nexport default tooltipClasses;","'use client';\n\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nconst _excluded = [\"arrow\", \"children\", \"classes\", \"components\", \"componentsProps\", \"describeChild\", \"disableFocusListener\", \"disableHoverListener\", \"disableInteractive\", \"disableTouchListener\", \"enterDelay\", \"enterNextDelay\", \"enterTouchDelay\", \"followCursor\", \"id\", \"leaveDelay\", \"leaveTouchDelay\", \"onClose\", \"onOpen\", \"open\", \"placement\", \"PopperComponent\", \"PopperProps\", \"slotProps\", \"slots\", \"title\", \"TransitionComponent\", \"TransitionProps\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport clsx from 'clsx';\nimport { elementAcceptingRef, unstable_useTimeout as useTimeout, unstable_Timeout as Timeout } from '@mui/utils';\nimport { unstable_composeClasses as composeClasses, appendOwnerState } from '@mui/base';\nimport { alpha } from '@mui/system';\nimport styled from '../styles/styled';\nimport useTheme from '../styles/useTheme';\nimport useThemeProps from '../styles/useThemeProps';\nimport capitalize from '../utils/capitalize';\nimport Grow from '../Grow';\nimport Popper from '../Popper';\nimport useEventCallback from '../utils/useEventCallback';\nimport useForkRef from '../utils/useForkRef';\nimport useId from '../utils/useId';\nimport useIsFocusVisible from '../utils/useIsFocusVisible';\nimport useControlled from '../utils/useControlled';\nimport tooltipClasses, { getTooltipUtilityClass } from './tooltipClasses';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nimport { jsxs as _jsxs } from \"react/jsx-runtime\";\nfunction round(value) {\n return Math.round(value * 1e5) / 1e5;\n}\nconst useUtilityClasses = ownerState => {\n const {\n classes,\n disableInteractive,\n arrow,\n touch,\n placement\n } = ownerState;\n const slots = {\n popper: ['popper', !disableInteractive && 'popperInteractive', arrow && 'popperArrow'],\n tooltip: ['tooltip', arrow && 'tooltipArrow', touch && 'touch', `tooltipPlacement${capitalize(placement.split('-')[0])}`],\n arrow: ['arrow']\n };\n return composeClasses(slots, getTooltipUtilityClass, classes);\n};\nconst TooltipPopper = styled(Popper, {\n name: 'MuiTooltip',\n slot: 'Popper',\n overridesResolver: (props, styles) => {\n const {\n ownerState\n } = props;\n return [styles.popper, !ownerState.disableInteractive && styles.popperInteractive, ownerState.arrow && styles.popperArrow, !ownerState.open && styles.popperClose];\n }\n})(({\n theme,\n ownerState,\n open\n}) => _extends({\n zIndex: (theme.vars || theme).zIndex.tooltip,\n pointerEvents: 'none'\n}, !ownerState.disableInteractive && {\n pointerEvents: 'auto'\n}, !open && {\n pointerEvents: 'none'\n}, ownerState.arrow && {\n [`&[data-popper-placement*=\"bottom\"] .${tooltipClasses.arrow}`]: {\n top: 0,\n marginTop: '-0.71em',\n '&::before': {\n transformOrigin: '0 100%'\n }\n },\n [`&[data-popper-placement*=\"top\"] .${tooltipClasses.arrow}`]: {\n bottom: 0,\n marginBottom: '-0.71em',\n '&::before': {\n transformOrigin: '100% 0'\n }\n },\n [`&[data-popper-placement*=\"right\"] .${tooltipClasses.arrow}`]: _extends({}, !ownerState.isRtl ? {\n left: 0,\n marginLeft: '-0.71em'\n } : {\n right: 0,\n marginRight: '-0.71em'\n }, {\n height: '1em',\n width: '0.71em',\n '&::before': {\n transformOrigin: '100% 100%'\n }\n }),\n [`&[data-popper-placement*=\"left\"] .${tooltipClasses.arrow}`]: _extends({}, !ownerState.isRtl ? {\n right: 0,\n marginRight: '-0.71em'\n } : {\n left: 0,\n marginLeft: '-0.71em'\n }, {\n height: '1em',\n width: '0.71em',\n '&::before': {\n transformOrigin: '0 0'\n }\n })\n}));\nconst TooltipTooltip = styled('div', {\n name: 'MuiTooltip',\n slot: 'Tooltip',\n overridesResolver: (props, styles) => {\n const {\n ownerState\n } = props;\n return [styles.tooltip, ownerState.touch && styles.touch, ownerState.arrow && styles.tooltipArrow, styles[`tooltipPlacement${capitalize(ownerState.placement.split('-')[0])}`]];\n }\n})(({\n theme,\n ownerState\n}) => _extends({\n backgroundColor: theme.vars ? theme.vars.palette.Tooltip.bg : alpha(theme.palette.grey[700], 0.92),\n borderRadius: (theme.vars || theme).shape.borderRadius,\n color: (theme.vars || theme).palette.common.white,\n fontFamily: theme.typography.fontFamily,\n padding: '4px 8px',\n fontSize: theme.typography.pxToRem(11),\n maxWidth: 300,\n margin: 2,\n wordWrap: 'break-word',\n fontWeight: theme.typography.fontWeightMedium\n}, ownerState.arrow && {\n position: 'relative',\n margin: 0\n}, ownerState.touch && {\n padding: '8px 16px',\n fontSize: theme.typography.pxToRem(14),\n lineHeight: `${round(16 / 14)}em`,\n fontWeight: theme.typography.fontWeightRegular\n}, {\n [`.${tooltipClasses.popper}[data-popper-placement*=\"left\"] &`]: _extends({\n transformOrigin: 'right center'\n }, !ownerState.isRtl ? _extends({\n marginRight: '14px'\n }, ownerState.touch && {\n marginRight: '24px'\n }) : _extends({\n marginLeft: '14px'\n }, ownerState.touch && {\n marginLeft: '24px'\n })),\n [`.${tooltipClasses.popper}[data-popper-placement*=\"right\"] &`]: _extends({\n transformOrigin: 'left center'\n }, !ownerState.isRtl ? _extends({\n marginLeft: '14px'\n }, ownerState.touch && {\n marginLeft: '24px'\n }) : _extends({\n marginRight: '14px'\n }, ownerState.touch && {\n marginRight: '24px'\n })),\n [`.${tooltipClasses.popper}[data-popper-placement*=\"top\"] &`]: _extends({\n transformOrigin: 'center bottom',\n marginBottom: '14px'\n }, ownerState.touch && {\n marginBottom: '24px'\n }),\n [`.${tooltipClasses.popper}[data-popper-placement*=\"bottom\"] &`]: _extends({\n transformOrigin: 'center top',\n marginTop: '14px'\n }, ownerState.touch && {\n marginTop: '24px'\n })\n}));\nconst TooltipArrow = styled('span', {\n name: 'MuiTooltip',\n slot: 'Arrow',\n overridesResolver: (props, styles) => styles.arrow\n})(({\n theme\n}) => ({\n overflow: 'hidden',\n position: 'absolute',\n width: '1em',\n height: '0.71em' /* = width / sqrt(2) = (length of the hypotenuse) */,\n boxSizing: 'border-box',\n color: theme.vars ? theme.vars.palette.Tooltip.bg : alpha(theme.palette.grey[700], 0.9),\n '&::before': {\n content: '\"\"',\n margin: 'auto',\n display: 'block',\n width: '100%',\n height: '100%',\n backgroundColor: 'currentColor',\n transform: 'rotate(45deg)'\n }\n}));\nlet hystersisOpen = false;\nconst hystersisTimer = new Timeout();\nlet cursorPosition = {\n x: 0,\n y: 0\n};\nexport function testReset() {\n hystersisOpen = false;\n hystersisTimer.clear();\n}\nfunction composeEventHandler(handler, eventHandler) {\n return event => {\n if (eventHandler) {\n eventHandler(event);\n }\n handler(event);\n };\n}\n\n// TODO v6: Remove PopperComponent, PopperProps, TransitionComponent and TransitionProps.\nconst Tooltip = /*#__PURE__*/React.forwardRef(function Tooltip(inProps, ref) {\n var _ref, _slots$popper, _ref2, _ref3, _slots$transition, _ref4, _slots$tooltip, _ref5, _slots$arrow, _slotProps$popper, _ref6, _slotProps$popper2, _slotProps$transition, _slotProps$tooltip, _ref7, _slotProps$tooltip2, _slotProps$arrow, _ref8, _slotProps$arrow2;\n const props = useThemeProps({\n props: inProps,\n name: 'MuiTooltip'\n });\n const {\n arrow = false,\n children: childrenProp,\n components = {},\n componentsProps = {},\n describeChild = false,\n disableFocusListener = false,\n disableHoverListener = false,\n disableInteractive: disableInteractiveProp = false,\n disableTouchListener = false,\n enterDelay = 100,\n enterNextDelay = 0,\n enterTouchDelay = 700,\n followCursor = false,\n id: idProp,\n leaveDelay = 0,\n leaveTouchDelay = 1500,\n onClose,\n onOpen,\n open: openProp,\n placement = 'bottom',\n PopperComponent: PopperComponentProp,\n PopperProps = {},\n slotProps = {},\n slots = {},\n title,\n TransitionComponent: TransitionComponentProp = Grow,\n TransitionProps\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n\n // to prevent runtime errors, developers will need to provide a child as a React element anyway.\n const children = /*#__PURE__*/React.isValidElement(childrenProp) ? childrenProp : /*#__PURE__*/_jsx(\"span\", {\n children: childrenProp\n });\n const theme = useTheme();\n const isRtl = theme.direction === 'rtl';\n const [childNode, setChildNode] = React.useState();\n const [arrowRef, setArrowRef] = React.useState(null);\n const ignoreNonTouchEvents = React.useRef(false);\n const disableInteractive = disableInteractiveProp || followCursor;\n const closeTimer = useTimeout();\n const enterTimer = useTimeout();\n const leaveTimer = useTimeout();\n const touchTimer = useTimeout();\n const [openState, setOpenState] = useControlled({\n controlled: openProp,\n default: false,\n name: 'Tooltip',\n state: 'open'\n });\n let open = openState;\n if (process.env.NODE_ENV !== 'production') {\n // eslint-disable-next-line react-hooks/rules-of-hooks\n const {\n current: isControlled\n } = React.useRef(openProp !== undefined);\n\n // eslint-disable-next-line react-hooks/rules-of-hooks\n React.useEffect(() => {\n if (childNode && childNode.disabled && !isControlled && title !== '' && childNode.tagName.toLowerCase() === 'button') {\n console.error(['MUI: You are providing a disabled `button` child to the Tooltip component.', 'A disabled element does not fire events.', \"Tooltip needs to listen to the child element's events to display the title.\", '', 'Add a simple wrapper element, such as a `span`.'].join('\\n'));\n }\n }, [title, childNode, isControlled]);\n }\n const id = useId(idProp);\n const prevUserSelect = React.useRef();\n const stopTouchInteraction = useEventCallback(() => {\n if (prevUserSelect.current !== undefined) {\n document.body.style.WebkitUserSelect = prevUserSelect.current;\n prevUserSelect.current = undefined;\n }\n touchTimer.clear();\n });\n React.useEffect(() => stopTouchInteraction, [stopTouchInteraction]);\n const handleOpen = event => {\n hystersisTimer.clear();\n hystersisOpen = true;\n\n // The mouseover event will trigger for every nested element in the tooltip.\n // We can skip rerendering when the tooltip is already open.\n // We are using the mouseover event instead of the mouseenter event to fix a hide/show issue.\n setOpenState(true);\n if (onOpen && !open) {\n onOpen(event);\n }\n };\n const handleClose = useEventCallback(\n /**\n * @param {React.SyntheticEvent | Event} event\n */\n event => {\n hystersisTimer.start(800 + leaveDelay, () => {\n hystersisOpen = false;\n });\n setOpenState(false);\n if (onClose && open) {\n onClose(event);\n }\n closeTimer.start(theme.transitions.duration.shortest, () => {\n ignoreNonTouchEvents.current = false;\n });\n });\n const handleEnter = event => {\n if (ignoreNonTouchEvents.current && event.type !== 'touchstart') {\n return;\n }\n\n // Remove the title ahead of time.\n // We don't want to wait for the next render commit.\n // We would risk displaying two tooltips at the same time (native + this one).\n if (childNode) {\n childNode.removeAttribute('title');\n }\n enterTimer.clear();\n leaveTimer.clear();\n if (enterDelay || hystersisOpen && enterNextDelay) {\n enterTimer.start(hystersisOpen ? enterNextDelay : enterDelay, () => {\n handleOpen(event);\n });\n } else {\n handleOpen(event);\n }\n };\n const handleLeave = event => {\n enterTimer.clear();\n leaveTimer.start(leaveDelay, () => {\n handleClose(event);\n });\n };\n const {\n isFocusVisibleRef,\n onBlur: handleBlurVisible,\n onFocus: handleFocusVisible,\n ref: focusVisibleRef\n } = useIsFocusVisible();\n // We don't necessarily care about the focusVisible state (which is safe to access via ref anyway).\n // We just need to re-render the Tooltip if the focus-visible state changes.\n const [, setChildIsFocusVisible] = React.useState(false);\n const handleBlur = event => {\n handleBlurVisible(event);\n if (isFocusVisibleRef.current === false) {\n setChildIsFocusVisible(false);\n handleLeave(event);\n }\n };\n const handleFocus = event => {\n // Workaround for https://github.com/facebook/react/issues/7769\n // The autoFocus of React might trigger the event before the componentDidMount.\n // We need to account for this eventuality.\n if (!childNode) {\n setChildNode(event.currentTarget);\n }\n handleFocusVisible(event);\n if (isFocusVisibleRef.current === true) {\n setChildIsFocusVisible(true);\n handleEnter(event);\n }\n };\n const detectTouchStart = event => {\n ignoreNonTouchEvents.current = true;\n const childrenProps = children.props;\n if (childrenProps.onTouchStart) {\n childrenProps.onTouchStart(event);\n }\n };\n const handleMouseOver = handleEnter;\n const handleMouseLeave = handleLeave;\n const handleTouchStart = event => {\n detectTouchStart(event);\n leaveTimer.clear();\n closeTimer.clear();\n stopTouchInteraction();\n prevUserSelect.current = document.body.style.WebkitUserSelect;\n // Prevent iOS text selection on long-tap.\n document.body.style.WebkitUserSelect = 'none';\n touchTimer.start(enterTouchDelay, () => {\n document.body.style.WebkitUserSelect = prevUserSelect.current;\n handleEnter(event);\n });\n };\n const handleTouchEnd = event => {\n if (children.props.onTouchEnd) {\n children.props.onTouchEnd(event);\n }\n stopTouchInteraction();\n leaveTimer.start(leaveTouchDelay, () => {\n handleClose(event);\n });\n };\n React.useEffect(() => {\n if (!open) {\n return undefined;\n }\n\n /**\n * @param {KeyboardEvent} nativeEvent\n */\n function handleKeyDown(nativeEvent) {\n // IE11, Edge (prior to using Bink?) use 'Esc'\n if (nativeEvent.key === 'Escape' || nativeEvent.key === 'Esc') {\n handleClose(nativeEvent);\n }\n }\n document.addEventListener('keydown', handleKeyDown);\n return () => {\n document.removeEventListener('keydown', handleKeyDown);\n };\n }, [handleClose, open]);\n const handleRef = useForkRef(children.ref, focusVisibleRef, setChildNode, ref);\n\n // There is no point in displaying an empty tooltip.\n // So we exclude all falsy values, except 0, which is valid.\n if (!title && title !== 0) {\n open = false;\n }\n const popperRef = React.useRef();\n const handleMouseMove = event => {\n const childrenProps = children.props;\n if (childrenProps.onMouseMove) {\n childrenProps.onMouseMove(event);\n }\n cursorPosition = {\n x: event.clientX,\n y: event.clientY\n };\n if (popperRef.current) {\n popperRef.current.update();\n }\n };\n const nameOrDescProps = {};\n const titleIsString = typeof title === 'string';\n if (describeChild) {\n nameOrDescProps.title = !open && titleIsString && !disableHoverListener ? title : null;\n nameOrDescProps['aria-describedby'] = open ? id : null;\n } else {\n nameOrDescProps['aria-label'] = titleIsString ? title : null;\n nameOrDescProps['aria-labelledby'] = open && !titleIsString ? id : null;\n }\n const childrenProps = _extends({}, nameOrDescProps, other, children.props, {\n className: clsx(other.className, children.props.className),\n onTouchStart: detectTouchStart,\n ref: handleRef\n }, followCursor ? {\n onMouseMove: handleMouseMove\n } : {});\n if (process.env.NODE_ENV !== 'production') {\n childrenProps['data-mui-internal-clone-element'] = true;\n\n // eslint-disable-next-line react-hooks/rules-of-hooks\n React.useEffect(() => {\n if (childNode && !childNode.getAttribute('data-mui-internal-clone-element')) {\n console.error(['MUI: The `children` component of the Tooltip is not forwarding its props correctly.', 'Please make sure that props are spread on the same element that the ref is applied to.'].join('\\n'));\n }\n }, [childNode]);\n }\n const interactiveWrapperListeners = {};\n if (!disableTouchListener) {\n childrenProps.onTouchStart = handleTouchStart;\n childrenProps.onTouchEnd = handleTouchEnd;\n }\n if (!disableHoverListener) {\n childrenProps.onMouseOver = composeEventHandler(handleMouseOver, childrenProps.onMouseOver);\n childrenProps.onMouseLeave = composeEventHandler(handleMouseLeave, childrenProps.onMouseLeave);\n if (!disableInteractive) {\n interactiveWrapperListeners.onMouseOver = handleMouseOver;\n interactiveWrapperListeners.onMouseLeave = handleMouseLeave;\n }\n }\n if (!disableFocusListener) {\n childrenProps.onFocus = composeEventHandler(handleFocus, childrenProps.onFocus);\n childrenProps.onBlur = composeEventHandler(handleBlur, childrenProps.onBlur);\n if (!disableInteractive) {\n interactiveWrapperListeners.onFocus = handleFocus;\n interactiveWrapperListeners.onBlur = handleBlur;\n }\n }\n if (process.env.NODE_ENV !== 'production') {\n if (children.props.title) {\n console.error(['MUI: You have provided a `title` prop to the child of .', `Remove this title prop \\`${children.props.title}\\` or the Tooltip component.`].join('\\n'));\n }\n }\n const popperOptions = React.useMemo(() => {\n var _PopperProps$popperOp;\n let tooltipModifiers = [{\n name: 'arrow',\n enabled: Boolean(arrowRef),\n options: {\n element: arrowRef,\n padding: 4\n }\n }];\n if ((_PopperProps$popperOp = PopperProps.popperOptions) != null && _PopperProps$popperOp.modifiers) {\n tooltipModifiers = tooltipModifiers.concat(PopperProps.popperOptions.modifiers);\n }\n return _extends({}, PopperProps.popperOptions, {\n modifiers: tooltipModifiers\n });\n }, [arrowRef, PopperProps]);\n const ownerState = _extends({}, props, {\n isRtl,\n arrow,\n disableInteractive,\n placement,\n PopperComponentProp,\n touch: ignoreNonTouchEvents.current\n });\n const classes = useUtilityClasses(ownerState);\n const PopperComponent = (_ref = (_slots$popper = slots.popper) != null ? _slots$popper : components.Popper) != null ? _ref : TooltipPopper;\n const TransitionComponent = (_ref2 = (_ref3 = (_slots$transition = slots.transition) != null ? _slots$transition : components.Transition) != null ? _ref3 : TransitionComponentProp) != null ? _ref2 : Grow;\n const TooltipComponent = (_ref4 = (_slots$tooltip = slots.tooltip) != null ? _slots$tooltip : components.Tooltip) != null ? _ref4 : TooltipTooltip;\n const ArrowComponent = (_ref5 = (_slots$arrow = slots.arrow) != null ? _slots$arrow : components.Arrow) != null ? _ref5 : TooltipArrow;\n const popperProps = appendOwnerState(PopperComponent, _extends({}, PopperProps, (_slotProps$popper = slotProps.popper) != null ? _slotProps$popper : componentsProps.popper, {\n className: clsx(classes.popper, PopperProps == null ? void 0 : PopperProps.className, (_ref6 = (_slotProps$popper2 = slotProps.popper) != null ? _slotProps$popper2 : componentsProps.popper) == null ? void 0 : _ref6.className)\n }), ownerState);\n const transitionProps = appendOwnerState(TransitionComponent, _extends({}, TransitionProps, (_slotProps$transition = slotProps.transition) != null ? _slotProps$transition : componentsProps.transition), ownerState);\n const tooltipProps = appendOwnerState(TooltipComponent, _extends({}, (_slotProps$tooltip = slotProps.tooltip) != null ? _slotProps$tooltip : componentsProps.tooltip, {\n className: clsx(classes.tooltip, (_ref7 = (_slotProps$tooltip2 = slotProps.tooltip) != null ? _slotProps$tooltip2 : componentsProps.tooltip) == null ? void 0 : _ref7.className)\n }), ownerState);\n const tooltipArrowProps = appendOwnerState(ArrowComponent, _extends({}, (_slotProps$arrow = slotProps.arrow) != null ? _slotProps$arrow : componentsProps.arrow, {\n className: clsx(classes.arrow, (_ref8 = (_slotProps$arrow2 = slotProps.arrow) != null ? _slotProps$arrow2 : componentsProps.arrow) == null ? void 0 : _ref8.className)\n }), ownerState);\n return /*#__PURE__*/_jsxs(React.Fragment, {\n children: [/*#__PURE__*/React.cloneElement(children, childrenProps), /*#__PURE__*/_jsx(PopperComponent, _extends({\n as: PopperComponentProp != null ? PopperComponentProp : Popper,\n placement: placement,\n anchorEl: followCursor ? {\n getBoundingClientRect: () => ({\n top: cursorPosition.y,\n left: cursorPosition.x,\n right: cursorPosition.x,\n bottom: cursorPosition.y,\n width: 0,\n height: 0\n })\n } : childNode,\n popperRef: popperRef,\n open: childNode ? open : false,\n id: id,\n transition: true\n }, interactiveWrapperListeners, popperProps, {\n popperOptions: popperOptions,\n children: ({\n TransitionProps: TransitionPropsInner\n }) => /*#__PURE__*/_jsx(TransitionComponent, _extends({\n timeout: theme.transitions.duration.shorter\n }, TransitionPropsInner, transitionProps, {\n children: /*#__PURE__*/_jsxs(TooltipComponent, _extends({}, tooltipProps, {\n children: [title, arrow ? /*#__PURE__*/_jsx(ArrowComponent, _extends({}, tooltipArrowProps, {\n ref: setArrowRef\n })) : null]\n }))\n }))\n }))]\n });\n});\nprocess.env.NODE_ENV !== \"production\" ? Tooltip.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the d.ts file and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * If `true`, adds an arrow to the tooltip.\n * @default false\n */\n arrow: PropTypes.bool,\n /**\n * Tooltip reference element.\n */\n children: elementAcceptingRef.isRequired,\n /**\n * Override or extend the styles applied to the component.\n */\n classes: PropTypes.object,\n /**\n * @ignore\n */\n className: PropTypes.string,\n /**\n * The components used for each slot inside.\n *\n * This prop is an alias for the `slots` prop.\n * It's recommended to use the `slots` prop instead.\n *\n * @default {}\n */\n components: PropTypes.shape({\n Arrow: PropTypes.elementType,\n Popper: PropTypes.elementType,\n Tooltip: PropTypes.elementType,\n Transition: PropTypes.elementType\n }),\n /**\n * The extra props for the slot components.\n * You can override the existing props or add new ones.\n *\n * This prop is an alias for the `slotProps` prop.\n * It's recommended to use the `slotProps` prop instead, as `componentsProps` will be deprecated in the future.\n *\n * @default {}\n */\n componentsProps: PropTypes.shape({\n arrow: PropTypes.object,\n popper: PropTypes.object,\n tooltip: PropTypes.object,\n transition: PropTypes.object\n }),\n /**\n * Set to `true` if the `title` acts as an accessible description.\n * By default the `title` acts as an accessible label for the child.\n * @default false\n */\n describeChild: PropTypes.bool,\n /**\n * Do not respond to focus-visible events.\n * @default false\n */\n disableFocusListener: PropTypes.bool,\n /**\n * Do not respond to hover events.\n * @default false\n */\n disableHoverListener: PropTypes.bool,\n /**\n * Makes a tooltip not interactive, i.e. it will close when the user\n * hovers over the tooltip before the `leaveDelay` is expired.\n * @default false\n */\n disableInteractive: PropTypes.bool,\n /**\n * Do not respond to long press touch events.\n * @default false\n */\n disableTouchListener: PropTypes.bool,\n /**\n * The number of milliseconds to wait before showing the tooltip.\n * This prop won't impact the enter touch delay (`enterTouchDelay`).\n * @default 100\n */\n enterDelay: PropTypes.number,\n /**\n * The number of milliseconds to wait before showing the tooltip when one was already recently opened.\n * @default 0\n */\n enterNextDelay: PropTypes.number,\n /**\n * The number of milliseconds a user must touch the element before showing the tooltip.\n * @default 700\n */\n enterTouchDelay: PropTypes.number,\n /**\n * If `true`, the tooltip follow the cursor over the wrapped element.\n * @default false\n */\n followCursor: PropTypes.bool,\n /**\n * This prop is used to help implement the accessibility logic.\n * If you don't provide this prop. It falls back to a randomly generated id.\n */\n id: PropTypes.string,\n /**\n * The number of milliseconds to wait before hiding the tooltip.\n * This prop won't impact the leave touch delay (`leaveTouchDelay`).\n * @default 0\n */\n leaveDelay: PropTypes.number,\n /**\n * The number of milliseconds after the user stops touching an element before hiding the tooltip.\n * @default 1500\n */\n leaveTouchDelay: PropTypes.number,\n /**\n * Callback fired when the component requests to be closed.\n *\n * @param {React.SyntheticEvent} event The event source of the callback.\n */\n onClose: PropTypes.func,\n /**\n * Callback fired when the component requests to be open.\n *\n * @param {React.SyntheticEvent} event The event source of the callback.\n */\n onOpen: PropTypes.func,\n /**\n * If `true`, the component is shown.\n */\n open: PropTypes.bool,\n /**\n * Tooltip placement.\n * @default 'bottom'\n */\n placement: PropTypes.oneOf(['bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n /**\n * The component used for the popper.\n * @default Popper\n */\n PopperComponent: PropTypes.elementType,\n /**\n * Props applied to the [`Popper`](/material-ui/api/popper/) element.\n * @default {}\n */\n PopperProps: PropTypes.object,\n /**\n * The extra props for the slot components.\n * You can override the existing props or add new ones.\n *\n * This prop is an alias for the `componentsProps` prop, which will be deprecated in the future.\n *\n * @default {}\n */\n slotProps: PropTypes.shape({\n arrow: PropTypes.object,\n popper: PropTypes.object,\n tooltip: PropTypes.object,\n transition: PropTypes.object\n }),\n /**\n * The components used for each slot inside.\n *\n * This prop is an alias for the `components` prop, which will be deprecated in the future.\n *\n * @default {}\n */\n slots: PropTypes.shape({\n arrow: PropTypes.elementType,\n popper: PropTypes.elementType,\n tooltip: PropTypes.elementType,\n transition: PropTypes.elementType\n }),\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Tooltip title. Zero-length titles string, undefined, null and false are never displayed.\n */\n title: PropTypes.node,\n /**\n * The component used for the transition.\n * [Follow this guide](/material-ui/transitions/#transitioncomponent-prop) to learn more about the requirements for this component.\n * @default Grow\n */\n TransitionComponent: PropTypes.elementType,\n /**\n * Props applied to the transition element.\n * By default, the element is based on this [`Transition`](http://reactcommunity.org/react-transition-group/transition/) component.\n */\n TransitionProps: PropTypes.object\n} : void 0;\nexport default Tooltip;","import '@/components/mui/menu-item.component.css';\nimport ArrowRightIcon from '@mui/icons-material/ArrowRight';\nimport {\n ListItemIcon as MuiListItemIcon,\n ListItemText as MuiListItemText,\n MenuItem as MuiMenuItem,\n} from '@mui/material';\nimport Tooltip from '@mui/material/Tooltip';\nimport { Localized, ReferencedItem, SingleColumnMenu } from 'platform-bible-utils';\nimport { MouseEvent, PropsWithChildren } from 'react';\n\ntype MenuItemInfoBase = {\n /** Text (displayable in the UI) as the name of the menu item */\n label: string;\n /** Text to display when the mouse hovers over the menu item */\n tooltip?: string;\n};\n\nexport type Command = MenuItemInfoBase & {\n /** Command to execute (string.string) */\n command: string;\n};\n\ntype SubMenu = MenuItemInfoBase & {\n /** Command to execute (string.string) */\n items: MenuItemInfo[];\n};\n\nexport interface CommandHandler {\n (command: Command): void;\n}\n\nexport type MenuPropsBase = {\n /*\n * The JSON defining the menu whose items are to be rendered. This will typically be one of the\n * menus in the \"defs\" in a Platform.Bible menu (see PlatformMenus). The schema for this is\n * menuDocumentSchema (at the end of menus.model.ts). Note that while this is a\n * \"SingleColumnMenu\", somewhat bizarrely, a MultiColumnMenu is a SingleColumnMenu, so it really\n * could be a MultiColumnMenu, in which case, column had better be defined so it can be used\n * to filter out the actual groups and items to display on the column.\n */\n menuDefinition: Localized;\n\n commandHandler: CommandHandler;\n\n /**\n * Additional action to perform when any menu item is clicked. Allows the caller to handle event\n * (e.g., to close the menu).\n */\n onClick?: (event: MouseEvent) => void;\n};\n\nexport type MenuItemListProps = MenuPropsBase & {\n /** Optional unique (column) identifier */\n columnId?: ReferencedItem;\n};\n\nexport type MenuItemProps = Omit &\n PropsWithChildren<{\n /** Optional unique identifier */\n id?: string;\n\n onClick: (event: MouseEvent) => void;\n }>;\n\ntype MenuItemInfo = (Command | SubMenu) & {\n /**\n * If specified, menu item will be inset if it does not have a leading icon.\n *\n * @default true\n */\n allowForLeadingIcons?: boolean;\n /**\n * If specified, the path to the icon image to display on the leading side of the menu text.\n *\n * @default undefined (no leading icon will be shown)\n */\n iconPathBefore?: string;\n /**\n * If specified, the path to the icon image to display on the trailing side of the menu text.\n *\n * @default undefined (no trailing icon will be shown)\n */\n iconPathAfter?: string;\n /**\n * If true, list item is focused during the first mount\n *\n * @default false\n */\n hasAutoFocus?: boolean;\n\n /** Additional css classes to help with unique styling of the menu item */\n className?: string;\n\n /**\n * If true, the menu item will appear disabled and it will not respond to clicks or mouse hovers.\n *\n * @default false\n */\n isDisabled?: boolean;\n\n /**\n * If true, compact vertical padding designed for keyboard and mouse input is used.\n *\n * @default true\n */\n isDense?: boolean;\n\n /**\n * If true, a right-arrow icon will be displayed (iconPathAfter, if specified, will be ignored).\n *\n * @default false\n */\n isSubMenuParent?: boolean;\n\n /**\n * If true, the left and right padding is removed\n *\n * @default false\n */\n hasDisabledGutters?: boolean;\n\n /**\n * If true, a 1px light border is added to bottom of menu item\n *\n * @default false\n */\n hasDivider?: boolean;\n\n /** Help identify which element has keyboard focus */\n focusVisibleClassName?: string;\n\n /** If it's a submenu, it should have the items property */\n items?: MenuItemInfo[];\n};\n\nfunction getIcon(icon: string | undefined, menuLabel: string, leading: boolean) {\n return icon ? (\n \n {`${leading\n \n ) : undefined;\n}\n\nexport default function MenuItem(props: MenuItemProps) {\n const {\n onClick,\n label,\n tooltip,\n allowForLeadingIcons = true,\n iconPathBefore = undefined,\n iconPathAfter = undefined,\n hasAutoFocus = false,\n className,\n isDisabled = false,\n isDense = true,\n isSubMenuParent = false,\n hasDisabledGutters = false,\n hasDivider = false,\n focusVisibleClassName,\n id,\n children,\n } = props;\n\n const menuItem = (\n \n {label ? (\n <>\n {getIcon(iconPathBefore, label, true)}\n \n {isSubMenuParent ? (\n \n \n \n ) : (\n getIcon(iconPathAfter, label, false)\n )}\n \n ) : (\n children\n )}\n \n );\n\n return tooltip ? (\n \n
    {menuItem}
    \n
    \n ) : (\n menuItem\n );\n}\n","import MenuItem, {\n MenuItemListProps,\n MenuItemProps,\n MenuPropsBase,\n} from '@/components/mui/menu-item.component';\nimport { Menu } from '@mui/material';\nimport {\n Localized,\n MenuGroupDetailsInSubMenu,\n MenuItemContainingCommand,\n MenuItemContainingSubmenu,\n OrderedExtensibleContainer,\n ReferencedItem,\n SingleColumnMenu,\n} from 'platform-bible-utils';\nimport { MouseEvent, useMemo, useState } from 'react';\n\n/**\n * All the exported types in this file should be regarded as \"internal\" (i.e., they should not be\n * exposed via index.ts).\n */\n\nexport type GroupedMenuPropsBase = MenuPropsBase & {\n /** Optional unique (column) identifier */\n columnId?: ReferencedItem;\n};\n\nexport type GroupedMenuItemListProps = MenuItemListProps & {\n /**\n * If the menuDefinition includes \"top-level\" groups (i.e., those that belong to a column as\n * opposed to those that belong to a submenu) that should not be included in the list, then this\n * array specifies which groups to include. Likewise, for a submenu, this list indicates which\n * groups are pertinent for that submenu. So then for a context menu this property need not be\n * specified since it is a top-level menu based on a \"true\" SingleColumnMenu (i.e., one that is\n * not a MultiColumnMenu).\n */\n includedGroups?: {\n id: string;\n group: Localized;\n }[];\n};\n\ninterface ItemInfo {\n item: Localized;\n isLastItemInGroup: boolean;\n}\n\ntype SubMenuProps = MenuPropsBase & {\n parentMenuItem: Localized;\n parentItemProps: Omit, 'iconPathAfter'>;\n};\n\nfunction getAllGroups(menuDefinition: Localized) {\n const groupEntries = Object.entries(menuDefinition.groups);\n // Convert array of entries to array of objects with id and group properties\n return groupEntries.map(([key, value]) => ({ id: key, group: value }));\n}\n\nfunction SubMenu(props: SubMenuProps) {\n const [anchorEl, setAnchorEl] = useState(undefined);\n\n const { parentMenuItem, parentItemProps, menuDefinition } = props;\n\n const handleParentMenuItemClick = (event: MouseEvent) => {\n setAnchorEl(event.currentTarget);\n };\n\n const handleClose = () => {\n setAnchorEl(undefined);\n };\n\n const renderSubMenuItems = () => {\n let includedGroups = getAllGroups(menuDefinition).filter((g) => 'menuItem' in g.group);\n\n // Ensure valid parent menu was provided. (If not, submenu will contain all groups!)\n if (!parentMenuItem?.id) throw new Error('A valid parent menu item is required for submenus.');\n\n // When laying out a submenu, only include groups associated with the provided parent menu.\n // Note: without the (annoying) redundant check that the included groups\n // have the menuItem field, TS doesn't think it exists.\n includedGroups = includedGroups.filter(\n (group) => 'menuItem' in group.group && group.group.menuItem === parentMenuItem.id,\n );\n\n return ;\n };\n\n return (\n <>\n \n \n {renderSubMenuItems()}\n \n \n );\n}\n\nconst getOrderedGroupItems = (\n groupId: string,\n allItems: Localized[],\n) => {\n // Filter items that belong to the specified group\n const itemsForGroup = allItems.filter((item) => item.group === groupId);\n // Sort items based on order\n const sortedItems = itemsForGroup.sort((a, b) => (a.order || 0) - (b.order || 0));\n return sortedItems;\n};\n\n/**\n * This component is internal; it does not need to be exposed to the outside world since it is not\n * useful on its own. It is used to generate and lay out the MenuItems that appear either on a\n * top-level menu (in a GridMenu or ContextMenu) or in a submenu.\n */\nexport default function GroupedMenuItemList(menuProps: GroupedMenuItemListProps) {\n const { menuDefinition, onClick, commandHandler, includedGroups } = menuProps;\n\n const { items, allowForLeadingIcons } = useMemo(() => {\n const groupsToInclude =\n includedGroups && includedGroups.length > 0\n ? includedGroups\n : // We're apparently laying out a single-column menu (presumably a context menu). In this\n // case, all groups should be included except ones that belong to a submenu.\n getAllGroups(menuDefinition).filter((g) => !('menuItem' in g.group));\n\n const sortedGroups = Object.values(groupsToInclude).sort(\n (a, b) => (a.group.order || 0) - (b.group.order || 0),\n );\n\n const itemArray: ItemInfo[] = [];\n\n sortedGroups.forEach((group) => {\n getOrderedGroupItems(group.id, menuDefinition.items).forEach((item) =>\n itemArray.push({ item, isLastItemInGroup: false }),\n );\n if (itemArray.length > 0) itemArray[itemArray.length - 1].isLastItemInGroup = true;\n });\n\n // No divider after last item in final group.\n if (itemArray.length > 0) itemArray[itemArray.length - 1].isLastItemInGroup = false;\n\n const allowSpaceForLeadingIcons = itemArray.some(\n (i) => 'iconPathBefore' in i.item && i.item.iconPathBefore,\n );\n\n return { items: itemArray, allowForLeadingIcons: allowSpaceForLeadingIcons };\n }, [includedGroups, menuDefinition]);\n\n // Create props for MenuItem component including setting hasDivider for the last item in a group\n const createMenuItemProps = ({ item, isLastItemInGroup }: ItemInfo) => {\n const menuItemProps = {\n className: 'papi-menu-item',\n label: item.label,\n tooltip: item.tooltip,\n iconPathBefore: 'iconPathBefore' in item ? item.iconPathBefore : undefined,\n iconPathAfter: 'iconPathAfter' in item ? item.iconPathAfter : undefined,\n hasDivider: isLastItemInGroup, // Set hasDivider to true for the last item in a group\n allowForLeadingIcons,\n };\n\n return menuItemProps;\n };\n\n const [firstItem] = items;\n\n if (!firstItem) return
    ;\n\n const divKey = firstItem.item.group;\n\n return (\n
    \n {items.map((itemInfo, index) => {\n const { item } = itemInfo;\n const menuItemProps = createMenuItemProps(itemInfo);\n if ('command' in item) {\n const key = item.group + index;\n return (\n ) => {\n onClick?.(event);\n commandHandler(item);\n }}\n {...menuItemProps}\n />\n );\n }\n return (\n \n );\n })}\n
    \n );\n}\n","import GroupedMenuItemList from '@/components/mui/grouped-menu-item-list.component';\nimport { MenuItemListProps } from '@/components/mui/menu-item.component';\nimport { MultiColumnMenu } from 'platform-bible-utils';\n\n/**\n * This component is internal; it does not need to be exposed to the outside world since it is not\n * useful on its own. Use either GridMenu or ContextMenu.\n */\nexport default function TopLevelMenu(props: MenuItemListProps) {\n const { menuDefinition, columnId } = props;\n\n const groupEntries = Object.entries(menuDefinition.groups);\n // Convert array of entries to array of objects with id and group properties\n const groups = groupEntries.map(([key, value]) => ({ id: key, group: value }));\n let includedGroups = groups.filter((g) => 'column' in g.group);\n\n // Check if column is provided and menuDefinition is a MultiColumnMenu\n if (\n columnId &&\n 'columns' in menuDefinition &&\n // Without this type assertion, TS doesn't know what columns is.\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n (menuDefinition as MultiColumnMenu).columns[columnId]\n ) {\n // When laying out a single column in a MultiColumnMenu, only include groups associated with\n // the provided column. Note: without the (annoying) redundant check that the included groups\n // have the colum field, TS doesn't think it exists.\n includedGroups = includedGroups.filter(\n (g) => 'column' in g.group && g.group.column === columnId,\n );\n }\n\n return ;\n}\n","import '@/components/mui/grid-menu.component.css';\nimport { GroupedMenuPropsBase } from '@/components/mui/grouped-menu-item-list.component';\nimport { CommandHandler } from '@/components/mui/menu-item.component';\nimport TopLevelMenu from '@/components/mui/top-level-menu.component';\nimport { Grid, List } from '@mui/material';\nimport {\n Localized,\n MenuColumnWithHeader,\n MultiColumnMenu,\n ReferencedItem,\n} from 'platform-bible-utils';\nimport { useMemo } from 'react';\n\ntype ColumnInfo = {\n /*\n * The ID (`${string}.${string}`) of a specific menu column.\n */\n id: ReferencedItem;\n\n /*\n * Metadata (label, order, etc.) for a specific menu column.\n */\n metadata: Localized;\n};\n\ntype MenuColumnProps = ColumnInfo &\n GroupedMenuPropsBase & {\n /** Additional css classes to help with unique styling of the menu column */\n className?: string;\n };\n\nexport type GridMenuInfo = {\n /** The menu object containing information about the columns, groups, and items to display. */\n multiColumnMenu: Localized;\n};\n\nexport type GridMenuProps = GridMenuInfo & {\n /** Optional unique identifier */\n id?: string;\n\n commandHandler: CommandHandler;\n\n /** Additional css classes to help with unique styling of the grid menu */\n className?: string;\n};\n\nfunction MenuColumn({\n commandHandler,\n menuDefinition,\n id,\n metadata,\n onClick,\n className,\n}: MenuColumnProps) {\n return (\n \n

    \n {metadata.label}\n

    \n {/* It would seem as though this List component were unnecessary, since it only contains one\n thing, but the \"dense\" property does affect the layout of the items (in a way I don't fully\n understand). There might be a better way. */}\n \n \n \n \n );\n}\n\nexport default function GridMenu({\n commandHandler,\n className,\n multiColumnMenu,\n id,\n}: GridMenuProps) {\n const { columns } = multiColumnMenu;\n\n const sortedColumns = useMemo(() => {\n const columnNumbers = new Map();\n Object.getOwnPropertyNames(columns).forEach((columnName: string) => {\n // We know for sure there is a (boolean) property 'isExtensible' that we are not interested in.\n if (columnName === 'isExtensible') return;\n // TS doesn't allow `columnName` above to be a ReferencedItem even though the type says it is\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const columnId = columnName as ReferencedItem;\n const column = columns[columnId];\n // As of right now (and hopefully forever after), all remaining properties of the\n // ColumnsWithHeaders object are columns whose property names are the IDs of the columns.\n // This is an additional (redundant) sanity check. Specifically we're interested in\n // MenuColumnWithHeader objects, which TypeScript now \"knows\" we have, but at runtime all we\n // can check for is that it's an object with a valid numeric order field. That's likely good\n // enough.\n if (\n typeof column === 'object' &&\n typeof column.order === 'number' &&\n !Number.isNaN(column.order)\n )\n columnNumbers.set(column.order, { id: columnId, metadata: column });\n else\n console.warn(\n `Property ${columnName} (${typeof column}) on menu ${id} is not a valid column and is being ignored. This might indicate data corruption`,\n );\n });\n\n // Extract values and sort them based on the 'order' property\n return Array.from(columnNumbers.values()).sort((a, b) => {\n return (a.metadata.order || 0) - (b.metadata.order || 0);\n });\n }, [columns, id]);\n\n // We might need something like this if we need to be able to prevent empty columns\n // sortedColumns.filter((c) => multiColumnMenu.groups.some((g) => 'column' in g && (g as .column)...\n\n return (\n \n {sortedColumns.map((col, index) => (\n \n ))}\n \n );\n}\n","import { useEffect, useRef, useState } from 'react';\n\nexport type UsePromiseOptions = {\n /**\n * Whether to leave the value as the most recent resolved promise value or set it back to\n * defaultValue while running the promise again. Defaults to true\n */\n preserveValue?: boolean;\n};\n\n/** Set up defaults for options for usePromise hook */\nfunction getUsePromiseOptionsDefaults(options: UsePromiseOptions): UsePromiseOptions {\n return {\n preserveValue: true,\n ...options,\n };\n}\n\n/**\n * Awaits a promise and returns a loading value while the promise is unresolved\n *\n * @param promiseFactoryCallback A function that returns the promise to await. If this callback is\n * undefined, the current value will be returned (defaultValue unless it was previously changed\n * and `options.preserveValue` is true), and there will be no loading.\n *\n * WARNING: MUST BE STABLE - const or wrapped in useCallback. The reference must not be updated\n * every render\n * @param defaultValue The initial value to return while first awaiting the promise. If\n * `options.preserveValue` is false, this value is also shown while awaiting the promise on\n * subsequent calls.\n *\n * Note: this parameter is internally assigned to a `ref`, so changing it will not cause any hooks\n * to re-run with its new value. This means that, if the `promiseFactoryCallback` changes and\n * `options.preserveValue` is `false`, the returned value will be set to the current\n * `defaultValue`. However, the returned value will not be updated if`defaultValue` changes.\n * @param options Various options for adjusting how this hook runs the `promiseFactoryCallback`\n *\n * Note: this parameter is internally assigned to a `ref`, so changing it will not cause any hooks\n * to re-run with its new value. However, the latest `options.preserveValue` will always be used\n * appropriately to determine whether to preserve the returned value when changing the\n * `promiseFactoryCallback`\n * @returns `[value, isLoading]`\n *\n * - `value`: the current value for the promise, either the defaultValue or the resolved promise value\n * - `isLoading`: whether the promise is waiting to be resolved\n */\nconst usePromise = (\n promiseFactoryCallback: (() => Promise) | undefined,\n defaultValue: T,\n options: UsePromiseOptions = {},\n): [value: T, isLoading: boolean] => {\n // Use defaultValue as a ref so it doesn't update dependency arrays\n const defaultValueRef = useRef(defaultValue);\n defaultValueRef.current = defaultValue;\n // Use options as a ref so it doesn't update dependency arrays\n const optionsDefaultedRef = useRef(options);\n optionsDefaultedRef.current = getUsePromiseOptionsDefaults(optionsDefaultedRef.current);\n\n const [value, setValue] = useState(() => defaultValueRef.current);\n const [isLoading, setIsLoading] = useState(true);\n useEffect(() => {\n let promiseIsCurrent = true;\n // If a promiseFactoryCallback was provided, we are loading. Otherwise, there is no loading to do\n setIsLoading(!!promiseFactoryCallback);\n (async () => {\n // If there is a callback to run, run it\n if (promiseFactoryCallback) {\n const result = await promiseFactoryCallback();\n // If the promise was not already replaced, update the value\n if (promiseIsCurrent) {\n setValue(() => result);\n setIsLoading(false);\n }\n }\n })();\n\n return () => {\n // Mark this promise as old and not to be used\n promiseIsCurrent = false;\n if (!optionsDefaultedRef.current.preserveValue) setValue(() => defaultValueRef.current);\n };\n }, [promiseFactoryCallback]);\n\n return [value, isLoading];\n};\nexport default usePromise;\n","\"use client\";\n\nimport createSvgIcon from './utils/createSvgIcon';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nexport default createSvgIcon( /*#__PURE__*/_jsx(\"path\", {\n d: \"M3 18h18v-2H3zm0-5h18v-2H3zm0-7v2h18V6z\"\n}), 'Menu');","import GridMenu from '@/components/mui/grid-menu.component';\nimport { Command, CommandHandler } from '@/components/mui/menu-item.component';\nimport usePromise from '@/hooks/use-promise.hook';\nimport { Menu as MenuIcon } from '@mui/icons-material';\nimport { Drawer, IconButton } from '@mui/material';\nimport { Localized, MultiColumnMenu } from 'platform-bible-utils';\nimport {\n MouseEvent,\n MutableRefObject,\n PropsWithChildren,\n useCallback,\n useEffect,\n useState,\n} from 'react';\n\nexport interface MultiColumnMenuProvider {\n (isSupportAndDevelopment: boolean): Promise>;\n}\n\nexport type HamburgerMenuButtonProps = PropsWithChildren & {\n /** The handler to use for menu commands (and eventually toolbar commands). */\n commandHandler: CommandHandler;\n\n /**\n * Optional reference to the \"div\" container that determines the where the menu should appear. If\n * not defined, then (1,1) used.\n */\n containerRef?: MutableRefObject;\n\n /**\n * The delegate to use to get the menu data. If not specified or if it returns undefined, the data\n * in normalMenu or fullMenu property will be used.\n */\n menuProvider?: MultiColumnMenuProvider;\n\n /**\n * The menu data to show when the menu is opened if the menuProvider property is not defined.\n * (This allows for a default or test-only static menu to be used.)\n */\n normalMenu?: Localized;\n\n /**\n * The menu data to show for \"full\" menu (when opened with the SHIFT key pressed) if the\n * menuProvider property is not defined. (This allows for a default or test-only static menu to be\n * used.)\n */\n fullMenu?: Localized;\n\n /** Additional css class(es) to help with unique styling of the sub-components */\n className?: string;\n\n /** Value to use as prefix for ARIA labels on interactive sub-components */\n ariaLabelPrefix?: string;\n};\n\nexport default function HamburgerMenuButton({\n menuProvider,\n normalMenu,\n fullMenu,\n commandHandler,\n containerRef,\n className,\n ariaLabelPrefix,\n children,\n}: HamburgerMenuButtonProps) {\n const [isMenuOpen, setMenuOpen] = useState(false);\n const [showFullMenu, setShowFullMenu] = useState(false);\n\n const handleMenuItemClick = useCallback(() => {\n if (isMenuOpen) setMenuOpen(false);\n setShowFullMenu(false);\n }, [isMenuOpen]);\n\n const handleMenuButtonClick = useCallback((e: MouseEvent) => {\n e.stopPropagation();\n setMenuOpen((prevIsOpen) => {\n const isOpening = !prevIsOpen;\n if (isOpening && e.shiftKey) setShowFullMenu(true);\n else if (!isOpening) setShowFullMenu(false);\n return isOpening;\n });\n }, []);\n\n const menuCommandHandler = useCallback(\n (command: Command) => {\n handleMenuItemClick();\n return commandHandler(command);\n },\n [commandHandler, handleMenuItemClick],\n );\n\n const [offset, setOffset] = useState({ top: 1, left: 1 });\n\n useEffect(() => {\n if (isMenuOpen) {\n const node = containerRef?.current;\n if (node) {\n const rect = node.getBoundingClientRect();\n const scrollTop = window.scrollY;\n const scrollLeft = window.scrollX;\n const top = rect.top + scrollTop + node.clientHeight;\n const left = rect.left + scrollLeft;\n setOffset({ top, left });\n }\n }\n }, [isMenuOpen, containerRef]);\n\n const [normalMenuData] = usePromise(\n useCallback(async () => {\n return menuProvider?.(false) ?? normalMenu;\n // isMenuOpen needs to be included for the menu contents to reevaluate when reopened\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [menuProvider, normalMenu, isMenuOpen]),\n normalMenu,\n );\n\n const [fullMenuData] = usePromise(\n useCallback(async () => {\n return menuProvider?.(true) ?? fullMenu ?? normalMenuData;\n // isMenuOpen needs to be included for the menu contents to reevaluate when reopened\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [menuProvider, fullMenu, normalMenuData, isMenuOpen]),\n fullMenu ?? normalMenuData,\n );\n\n const menu = showFullMenu && fullMenuData ? fullMenuData : normalMenuData;\n\n return (\n <>\n \n {children ?? }\n \n \n {menu ? (\n \n ) : undefined}\n \n \n );\n}\n","import '@/components/mui/icon-button.component.css';\nimport { IconButton as MuiIconButton } from '@mui/material';\nimport { MouseEventHandler, PropsWithChildren } from 'react';\n\nexport type IconButtonProps = PropsWithChildren<{\n /** Optional unique identifier */\n id?: string;\n /**\n * Required. Used as both the tooltip (aka, title) and the aria-label (used for accessibility,\n * testing, etc.), unless a distinct tooltip is supplied.\n */\n label: string;\n /**\n * Enabled status of button\n *\n * @default false\n */\n isDisabled?: boolean;\n /** Optional tooltip to display if different from the aria-label. */\n tooltip?: string;\n /** If true, no tooltip will be displayed. */\n isTooltipSuppressed?: boolean;\n /**\n * If given, uses a negative margin to counteract the padding on one side (this is often helpful\n * for aligning the left or right side of the icon with content above or below, without ruining\n * the border size and shape).\n *\n * @default false\n */\n adjustMarginToAlignToEdge?: 'end' | 'start' | false;\n /**\n * The size of the component. small is equivalent to the dense button styling.\n *\n * @default false\n */\n size: 'small' | 'medium' | 'large';\n /** Additional css classes to help with unique styling of the button */\n className?: string;\n /** Optional click handler */\n onClick?: MouseEventHandler;\n}>;\n\n/**\n * Iconic button a user can click to do something\n *\n * Thanks to MUI for heavy inspiration and documentation\n * https://mui.com/material-ui/getting-started/overview/\n */\nfunction IconButton({\n id,\n label,\n isDisabled = false,\n tooltip,\n isTooltipSuppressed = false,\n adjustMarginToAlignToEdge = false,\n size = 'medium',\n className,\n onClick,\n children,\n}: IconButtonProps) {\n return (\n \n {children /* the icon to display */}\n \n );\n}\n\nexport default IconButton;\n","import { cn } from '@/utils/shadcn-ui.util';\nimport { LoaderCircle, LucideProps } from 'lucide-react';\nimport { forwardRef } from 'react';\n\nexport type SpinnerProps = LucideProps;\n\nconst Spinner = forwardRef(({ className, ...props }, ref) => {\n return (\n \n );\n});\n\nSpinner.displayName = 'Spinner';\n\nexport default Spinner;\n","import { Input as ShadInput } from '@/components/shadcn-ui/input';\nimport { Label as ShadLabel } from '@/components/shadcn-ui/label';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { ChangeEventHandler, FocusEventHandler } from 'react';\n\nexport type TextFieldProps = {\n /** Optional unique identifier */\n id?: string;\n /**\n * If `true`, the component is disabled.\n *\n * @default false\n */\n isDisabled?: boolean;\n /**\n * If `true`, the label is displayed in an error state.\n *\n * @default false\n */\n hasError?: boolean;\n /**\n * If `true`, the input will take up the full width of its container.\n *\n * @default false\n */\n isFullWidth?: boolean;\n /** Text that gives the user instructions on what contents the TextField expects */\n helperText?: string;\n /** The title of the TextField */\n label?: string;\n /** The short hint displayed in the `input` before the user enters a value. */\n placeholder?: string;\n /**\n * If `true`, the label is displayed as required and the `input` element is required.\n *\n * @default false\n */\n isRequired?: boolean;\n /** Additional css classes to help with unique styling of the text field */\n className?: string;\n /** Starting value for the text field if it is not controlled */\n defaultValue?: string | number;\n /** Value of the text field if controlled */\n value?: string | number;\n /** Triggers when content of textfield is changed */\n onChange?: ChangeEventHandler;\n /** Triggers when textfield gets focus */\n onFocus?: FocusEventHandler;\n /** Triggers when textfield loses focus */\n onBlur?: FocusEventHandler;\n};\n\n/**\n * Text input field\n *\n * Thanks to Shadcn for heavy inspiration and documentation\n * https://ui.shadcn.com/docs/components/input#with-label\n */\nfunction TextField({\n id,\n isDisabled = false,\n hasError = false,\n isFullWidth = false,\n helperText,\n label,\n placeholder,\n isRequired = false,\n className,\n defaultValue,\n value,\n onChange,\n onFocus,\n onBlur,\n}: TextFieldProps) {\n return (\n
    \n {`${label}${isRequired ? '*' : ''}`}\n \n

    {helperText}

    \n
    \n );\n}\n\nexport default TextField;\n","import HamburgerMenuButton, {\n MultiColumnMenuProvider,\n} from '@/components/mui/hamburger-menu-button.component';\nimport { CommandHandler } from '@/components/mui/menu-item.component';\nimport '@/components/mui/toolbar.component.css';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { AppBar, Toolbar as MuiToolbar } from '@mui/material';\nimport { PropsWithChildren, useRef } from 'react';\n\nexport type ToolbarProps = PropsWithChildren<{\n /** The handler to use for menu commands (and eventually toolbar commands). */\n commandHandler: CommandHandler;\n\n /**\n * The optional delegate to use to get the menu data. If not specified, the \"hamburger\" menu will\n * not display.\n */\n menuProvider?: MultiColumnMenuProvider;\n\n /** Optional unique identifier */\n id?: string;\n\n /** Additional css classes to help with unique styling of the toolbar */\n className?: string;\n}>;\n\nexport default function Toolbar({\n menuProvider,\n commandHandler,\n className,\n id,\n children,\n}: ToolbarProps) {\n // This ref will always be defined\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const containerRef = useRef(undefined!);\n\n return (\n
    \n \n \n {menuProvider ? (\n \n ) : undefined}\n {children ?
    {children}
    : undefined}\n \n
    \n
    \n );\n}\n","import React from 'react';\nimport { cva, type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst alertVariants = cva(\n 'tw-relative tw-w-full tw-rounded-lg tw-border tw-p-4 [&>svg~*]:tw-pl-7 [&>svg+div]:tw-translate-y-[-3px] [&>svg]:tw-absolute [&>svg]:tw-left-4 [&>svg]:tw-top-4 [&>svg]:tw-text-foreground',\n {\n variants: {\n variant: {\n default: 'tw-bg-background tw-text-foreground',\n destructive:\n 'tw-border-destructive/50 tw-text-destructive dark:tw-border-destructive [&>svg]:tw-text-destructive',\n },\n },\n defaultVariants: {\n variant: 'default',\n },\n },\n);\n\nconst Alert = React.forwardRef<\n HTMLDivElement,\n React.HTMLAttributes & VariantProps\n>(({ className, variant, ...props }, ref) => (\n
    \n));\nAlert.displayName = 'Alert';\n\nconst AlertTitle = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n {/* added because of https://github.com/jsx-eslint/eslint-plugin-jsx-a11y/blob/main/docs/rules/heading-has-content.md */}\n {props.children}{' '}\n \n ),\n);\nAlertTitle.displayName = 'AlertTitle';\n\nconst AlertDescription = React.forwardRef<\n HTMLParagraphElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n
    \n));\nAlertDescription.displayName = 'AlertDescription';\n\nexport { Alert, AlertTitle, AlertDescription };\n","import React from 'react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Card = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nCard.displayName = 'Card';\n\nconst CardHeader = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nCardHeader.displayName = 'CardHeader';\n\nconst CardTitle = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n {/* added because of https://github.com/jsx-eslint/eslint-plugin-jsx-a11y/blob/main/docs/rules/heading-has-content.md */}\n {props.children}\n \n ),\n);\nCardTitle.displayName = 'CardTitle';\n\nconst CardDescription = React.forwardRef<\n HTMLParagraphElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n

    \n));\nCardDescription.displayName = 'CardDescription';\n\nconst CardContent = React.forwardRef>(\n ({ className, ...props }, ref) => (\n

    \n ),\n);\nCardContent.displayName = 'CardContent';\n\nconst CardFooter = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nCardFooter.displayName = 'CardFooter';\n\nexport { Card, CardHeader, CardFooter, CardTitle, CardDescription, CardContent };\n","import { ComponentProps } from 'react';\nimport { toast as sonner, Toaster } from 'sonner';\n\ntype SonnerProps = ComponentProps;\n\nfunction Sonner({ ...props }: SonnerProps) {\n return (\n \n );\n}\n\n// The re-export of the sonner function was added manually\nexport { Sonner, sonner };\n","import React from 'react';\nimport * as SliderPrimitive from '@radix-ui/react-slider';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Slider = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n \n \n \n));\nSlider.displayName = SliderPrimitive.Root.displayName;\n\nexport { Slider };\n","import React from 'react';\nimport * as SwitchPrimitives from '@radix-ui/react-switch';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Switch = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n));\nSwitch.displayName = SwitchPrimitives.Root.displayName;\n\nexport { Switch };\n","import React from 'react';\nimport * as TabsPrimitive from '@radix-ui/react-tabs';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport const Tabs = TabsPrimitive.Root;\n\nexport type TabsListProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport type TabsTriggerProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport type TabsContentProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport const TabsList = React.forwardRef<\n React.ElementRef,\n TabsListProps\n>(({ className, ...props }, ref) => (\n \n));\nTabsList.displayName = TabsPrimitive.List.displayName;\n\nexport const TabsTrigger = React.forwardRef<\n React.ElementRef,\n TabsTriggerProps\n>(({ className, ...props }, ref) => (\n \n));\nTabsTrigger.displayName = TabsPrimitive.Trigger.displayName;\n\nexport const TabsContent = React.forwardRef<\n React.ElementRef,\n TabsContentProps\n>(({ className, ...props }, ref) => (\n \n));\nTabsContent.displayName = TabsPrimitive.Content.displayName;\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Download } from 'lucide-react';\n\ntype InstallButtonProps = {\n /** The installing boolean value determines the state of the button. */\n isInstalling: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n /** Optional text for the button. */\n buttonText?: string;\n} & ButtonProps;\n\n/**\n * The InstallButton component is a button designed for initiating installs. It includes visuals for\n * active installing and idle states.\n *\n * @param isInstalling The installing boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @param buttonText Optional text for the button.\n * @returns A install button.\n */\nexport default function InstallButton({\n isInstalling,\n handleClick,\n buttonText,\n className,\n ...props\n}: InstallButtonProps) {\n return (\n \n {isInstalling ? (\n \n ) : (\n <>\n \n {buttonText}\n \n )}\n \n );\n}\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\n\ntype EnableButtonProps = {\n /** The enabling boolean value determines the state of the button. */\n isEnabling: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n} & ButtonProps;\n\n/**\n * The EnableButton component is a button designed for initiating enabling of downloads. It includes\n * visuals for active enabling and idle states.\n *\n * @param isEnabling The enabling boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @returns A button that can be used to enable.\n */\nexport default function EnableButton({\n isEnabling,\n handleClick,\n className,\n ...props\n}: EnableButtonProps) {\n return (\n \n {isEnabling ? (\n <>\n \n Enabling...\n \n ) : (\n 'Enable'\n )}\n \n );\n}\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\n\ntype DisableButtonProps = {\n /** The disabling boolean value determines the state of the button. */\n isDisabling: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n} & ButtonProps;\n\n/**\n * The DisableButton component is a button designed for initiating disabling of downloads. It\n * includes visuals for active disabling and idle states.\n *\n * @param isDisabling The disabling boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @returns A button that can be used to disable.\n */\nexport default function DisableButton({\n isDisabling,\n handleClick,\n className,\n ...props\n}: DisableButtonProps) {\n return (\n \n {isDisabling ? (\n <>\n \n Disabling...\n \n ) : (\n 'Disable'\n )}\n \n );\n}\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\n\ntype UpdateButtonProps = {\n /** The updating boolean value determines the state of the button. */\n isUpdating: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n} & ButtonProps;\n\n/**\n * The UpdateButton component is a button designed for initiating updates for downloaded extensions.\n * It includes visuals for active updating and idle states.\n *\n * @param isUpdating The updating boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @returns A button that can be used to update.\n */\nexport default function UpdateButton({\n isUpdating,\n handleClick,\n className,\n ...props\n}: UpdateButtonProps) {\n return (\n \n {isUpdating ? (\n <>\n \n Updating...\n \n ) : (\n 'Update'\n )}\n \n );\n}\n","import { cn } from '@/utils/shadcn-ui.util';\nimport Markdown, { MarkdownToJSX } from 'markdown-to-jsx';\nimport { useMemo } from 'react';\n\ninterface MarkdownRendererProps {\n /** Optional unique identifier */\n id?: string;\n /** The markdown string to render */\n markdown: string;\n className?: string;\n /**\n * The [`target` attribute for `a` html\n * tags](https://developer.mozilla.org/en-US/docs/Web/HTML/Element/a#target). Defaults to not\n * adding a `target` to `a` tags\n */\n anchorTarget?: string;\n}\n\n/**\n * This component renders markdown content given a markdown string. It uses typography styles from\n * the platform.\n *\n * @param markdown The markdown string to render.\n * @param id Optional unique identifier\n * @returns A div containing the rendered markdown content.\n */\nexport default function MarkdownRenderer({\n id,\n markdown,\n className,\n anchorTarget,\n}: MarkdownRendererProps) {\n const options: MarkdownToJSX.Options = useMemo(\n () => ({\n overrides: {\n a: {\n props: {\n target: anchorTarget,\n },\n },\n },\n }),\n [anchorTarget],\n );\n return (\n
    \n {markdown}\n
    \n );\n}\n","import { Filter, ChevronDown } from 'lucide-react';\nimport { forwardRef } from 'react';\nimport { Button } from '@/components/shadcn-ui/button';\n\n/**\n * The FilterButton component is a button designed for initiating filtering of data. It is designed\n * to be used with the dropdown menu. It uses forwardRef to pass the button to the dropdown trigger\n * asChild.\n *\n * @returns A button that can be used to filter.\n */\nconst FilterButton = forwardRef((props, ref) => {\n return (\n \n \n Filter\n \n \n );\n});\n\nexport default FilterButton;\n","import {\n DropdownMenu,\n DropdownMenuTrigger,\n DropdownMenuContent,\n DropdownMenuLabel,\n DropdownMenuGroup,\n DropdownMenuCheckboxItem,\n DropdownMenuRadioItem,\n DropdownMenuSeparator,\n} from '@/components/shadcn-ui/dropdown-menu';\nimport FilterButton from './buttons/filter-button.component';\n\nexport enum DropdownMenuItemType {\n Check,\n Radio,\n}\n\nexport type DropdownItem = {\n /** The label is the text that will be displayed on the dropdown item. */\n label: string;\n /** The itemType determines the DropdownMenuItemType type as either Check or Radio. */\n itemType: DropdownMenuItemType;\n /** The onClick function is called when the item is clicked. */\n onClick: () => void;\n};\n\nexport type DropdownGroup = {\n /**\n * The label is the text that will be displayed on the dropdown group. It is used to categorize\n * the items in the group.\n */\n label: string;\n /** The items array contains the items that will be displayed in the dropdown group */\n items: DropdownItem[];\n};\n\nexport type FilterDropdownProps = {\n /** Object unique identifier */\n id?: string;\n /** The groups array contains the groups that will be displayed in the dropdown */\n groups: DropdownGroup[];\n}; // TODO: extend the props later\n\n/**\n * The FilterDropdown component is a dropdown designed for filtering content. It includes groups of\n * items that can be checkboxes or radio items.\n *\n * @param id Optional unique identifier\n * @param groups The groups array contains the groups that will be displayed in the dropdown\n * @returns A filter dropdown.\n */\nexport default function FilterDropdown({ id, groups }: FilterDropdownProps) {\n return (\n
    \n {/* TODO: remove this once the DropDown Menu shadcn has an id prop */}\n \n \n \n \n \n {groups.map((group) => (\n
    \n {group.label}\n \n {group.items.map((item) => (\n
    \n {item.itemType === DropdownMenuItemType.Check ? (\n \n {item.label}\n \n ) : (\n \n {item.label}\n \n )}\n
    \n ))}\n
    \n \n
    \n ))}\n
    \n
    \n
    \n );\n}\n","interface NoExtensionsFoundProps {\n /** Optional unique identifier */\n id?: string;\n /** The message to display */\n message: string;\n}\n/**\n * This component displays a message to the user when no extensions are found in the marketplace.\n *\n * @param id Optional unique identifier\n * @param message The message to display.\n * @returns {JSX.Element} - Returns the message component that displays the message to the user.\n */\nexport default function NoExtensionsFound({ id, message }: NoExtensionsFoundProps) {\n return (\n
    \n
    \n

    {message}

    \n
    \n
    \n );\n}\n","import { CircleHelp, Link as LucideLink, User } from 'lucide-react';\nimport { NumberFormat } from 'platform-bible-utils';\n\n/** Interface that stores the parameters passed to the More Info component */\ninterface MoreInfoProps {\n /** Optional unique identifier */\n id?: string;\n /** The category of the extension */\n category: string;\n /** The number of downloads for the extension */\n downloads: Record;\n /** The languages supported by the extension */\n languages: string[];\n /** The URL to the more info page of the extension */\n moreInfoUrl: string;\n}\n/**\n * This component displays the more info section of the extension which includes the category,\n * number of downloads, languages, and links to the website and support\n *\n * @param id Optional unique identifier\n * @param category The category of the extension\n * @param downloads The number of downloads for the extension\n * @param languages The languages supported by the extension\n * @param moreInfoUrl The URL to the more info page of the extension\n * @returns {JSX.Element} - Returns the more info component that displays the category, number of\n * downloads, languages, and links to the website and support\n */\nexport default function MoreInfo({\n id,\n category,\n downloads,\n languages,\n moreInfoUrl,\n}: MoreInfoProps) {\n /**\n * This constant formats the number of downloads into a more readable format.\n *\n * @example 1000 -> 1K\n *\n * @example 1000000 -> 1M\n *\n * @returns The formatted number of downloads\n */\n const numberFormatted = new NumberFormat('en', {\n notation: 'compact',\n compactDisplay: 'short',\n }).format(Object.values(downloads).reduce((a: number, b: number) => a + b, 0));\n\n /** This function scrolls the window to the bottom of the page. */\n const handleScrollToBottom = () => {\n window.scrollTo(0, document.body.scrollHeight);\n };\n\n return (\n \n
    \n
    \n {category}\n
    \n CATEGORY\n
    \n
    \n
    \n
    \n \n {numberFormatted}\n
    \n USERS\n
    \n
    \n
    \n
    \n {languages.slice(0, 3).map((locale) => (\n \n {locale.toUpperCase()}\n \n ))}\n
    \n {languages.length > 3 && (\n handleScrollToBottom()}\n className=\"tw-text-xs tw-text-gray-500 tw-underline\"\n >\n +{languages.length - 3} more languages\n \n )}\n
    \n
    \n
    \n \n Website\n \n \n \n Support\n \n \n
    \n
    \n );\n}\n","import { useState } from 'react';\n\nexport type VersionInformation = {\n /** Date the version was published */\n date: string;\n /** Description of the changes in the version */\n description: string;\n};\n\n/** Type to store the version history information */\nexport type VersionHistoryType = Record;\n\n/** Interface that stores the parameters passed to the Version History component */\ninterface VersionHistoryProps {\n /** Optional unique identifier */\n id?: string;\n /** Object containing the versions mapped with their information */\n versionHistory: VersionHistoryType;\n}\n\n/**\n * Component to render the version history information shown in the footer component. Lists the 5\n * most recent versions, with the options to show all versions by pressing a button.\n *\n * @param versionHistory Object containing the versions mapped with their information\n * @param id Optional unique identifier\n * @returns Rendered version history for the Footer component\n */\nexport default function VersionHistory({ id, versionHistory }: VersionHistoryProps) {\n const [showAllVersions, setShowAllVersions] = useState(false);\n const currentDate = new Date();\n\n /**\n * Function to format the time string for the version history in the form of 'X year(s) ago'.\n *\n * @param dateString ISO Date string to determine the time string from\n * @returns Formatted time string\n */\n function formatTimeString(dateString: string) {\n const date = new Date(dateString);\n const dateDiff = new Date(currentDate.getTime() - date.getTime());\n const yearDiff = dateDiff.getUTCFullYear() - 1970;\n const monthDiff = dateDiff.getUTCMonth();\n const dayDiff = dateDiff.getUTCDate() - 1;\n\n // Determines how long ago the version was published\n let timeString = '';\n if (yearDiff > 0) {\n timeString = `${yearDiff.toString()} year${yearDiff === 1 ? '' : 's'} ago`;\n } else if (monthDiff > 0) {\n timeString = `${monthDiff.toString()} month${monthDiff === 1 ? '' : 's'} ago`;\n } else if (dayDiff === 0) {\n timeString = 'today';\n } else {\n timeString = `${dayDiff.toString()} day${dayDiff === 1 ? '' : 's'} ago`;\n }\n\n return timeString;\n }\n\n // Sorts the version history by version number\n const sortedEntries = Object.entries(versionHistory).sort((a, b) => b[0].localeCompare(a[0]));\n\n return (\n
    \n

    What`s New

    \n
      \n {(showAllVersions ? sortedEntries : sortedEntries.slice(0, 5)).map((entry) => (\n
      \n
      \n
    • \n {entry[1].description}\n
    • \n
      \n
      \n
      Version {entry[0]}
      \n
      {formatTimeString(entry[1].date)}
      \n
      \n
      \n ))}\n
    \n {sortedEntries.length > 5 && (\n setShowAllVersions(!showAllVersions)}\n className=\"tw-text-xs tw-text-gray-500 tw-underline\"\n >\n {showAllVersions ? 'Show Less Version History' : 'Show All Version History'}\n \n )}\n
    \n );\n}\n","import { useMemo } from 'react';\nimport { formatBytes } from 'platform-bible-utils';\nimport VersionHistory, { VersionHistoryType } from './version-history.component';\n\n/** Interface to store the parameters passed to the Footer component */\ninterface FooterProps {\n /** Optional unique identifier */\n id?: string;\n /** Name of the publisher */\n publisherDisplayName: string;\n /** Size of the extension file in bytes */\n fileSize: number;\n /** List of language codes supported by the extension */\n locales: string[];\n /** Object containing the version history mapped with their information */\n versionHistory: VersionHistoryType;\n}\n\n/**\n * Component to render the footer for the extension details which contains information on the\n * publisher, version history, languages, and file size.\n *\n * @param id Optional unique identifier\n * @param publisherDisplayName Name of the publisher\n * @param fileSize Size of the extension file in bytes\n * @param locales List of language codes supported by the extension\n * @param versionHistory Object containing the version history mapped with their information\n * @returns The rendered Footer component\n */\nexport default function Footer({\n id,\n publisherDisplayName,\n fileSize,\n locales,\n versionHistory,\n}: FooterProps) {\n /** Formats the file size into a human-readable format */\n const formattedFileSize = useMemo(() => formatBytes(fileSize), [fileSize]);\n\n /**\n * This function gets the display names of the languages based on the language codes.\n *\n * @param codes The list of language codes\n * @returns The list of language names\n */\n const getLanguageNames = (codes: string[]) => {\n const displayNames = new Intl.DisplayNames(navigator.language, { type: 'language' });\n return codes.map((code) => displayNames.of(code));\n };\n\n const languageNames = getLanguageNames(locales);\n\n return (\n
    \n
    \n \n
    \n
    \n

    Information

    \n
    \n

    \n Publisher\n {publisherDisplayName}\n Size\n {formattedFileSize}\n

    \n
    \n

    \n Languages\n {languageNames.join(', ')}\n

    \n
    \n
    \n
    \n
    \n
    \n );\n}\n","import { PlatformEvent, PlatformEventHandler } from 'platform-bible-utils';\nimport { useEffect } from 'react';\n\n/**\n * Adds an event handler to an event so the event handler runs when the event is emitted. Use\n * `papi.network.getNetworkEvent` to use a networked event with this hook.\n *\n * @param event The event to subscribe to.\n *\n * - If event is a `PlatformEvent`, that event will be used\n * - If event is undefined, the callback will not be subscribed. Useful if the event is not yet\n * available for example\n *\n * @param eventHandler The callback to run when the event is emitted\n *\n * WARNING: MUST BE STABLE - const or wrapped in useCallback. The reference must not be updated\n * every render\n */\nconst useEvent = (\n event: PlatformEvent | undefined,\n eventHandler: PlatformEventHandler,\n) => {\n useEffect(() => {\n // Do nothing if the event is not provided (in case the event is not yet available, for example)\n if (!event) return () => {};\n\n const unsubscriber = event(eventHandler);\n return () => {\n unsubscriber();\n };\n }, [event, eventHandler]);\n};\nexport default useEvent;\n","import { useCallback, useEffect } from 'react';\nimport { PlatformEvent, PlatformEventAsync, PlatformEventHandler } from 'platform-bible-utils';\nimport usePromise from './use-promise.hook';\n\nconst noopUnsubscriber = () => false;\n\n/**\n * Adds an event handler to an asynchronously subscribing/unsubscribing event so the event handler\n * runs when the event is emitted. Use `papi.network.getNetworkEvent` to use a networked event with\n * this hook.\n *\n * @param event The asynchronously (un)subscribing event to subscribe to.\n *\n * - If event is a `PlatformEvent` or `PlatformEventAsync`, that event will be used\n * - If event is undefined, the callback will not be subscribed. Useful if the event is not yet\n * available for example\n *\n * @param eventHandler The callback to run when the event is emitted\n *\n * WARNING: MUST BE STABLE - const or wrapped in useCallback. The reference must not be updated\n * every render\n */\nconst useEventAsync = (\n event: PlatformEvent | PlatformEventAsync | undefined,\n eventHandler: PlatformEventHandler,\n) => {\n // Subscribe to the event asynchronously\n const [unsubscribe] = usePromise(\n useCallback(async () => {\n // Do nothing if the event is not provided (in case the event is not yet available, for example)\n if (!event) return noopUnsubscriber;\n\n // Wrap subscribe and unsubscribe in promises to allow normal events to be used as well\n const unsub = await Promise.resolve(event(eventHandler));\n return async () => unsub();\n }, [eventHandler, event]),\n noopUnsubscriber,\n // We want the unsubscriber to return to default value immediately upon changing subscription\n // So the useEffect below will unsubscribe asap\n { preserveValue: false },\n );\n\n // Unsubscribe from the event asynchronously (but we aren't awaiting the unsub)\n useEffect(() => {\n return () => {\n if (unsubscribe !== noopUnsubscriber) {\n unsubscribe();\n }\n };\n }, [unsubscribe]);\n};\n\nexport default useEventAsync;\n"],"names":["twMergeCustom","extendTailwindMerge","cn","inputs","clsx","Input","React","className","type","props","ref","jsx","BookChapterInput","forwardRef","handleSearch","handleKeyDown","handleOnClick","handleSubmit","jsxs","ShadInput","event","e","History","P","R","s","n","N","B","O","S","K","g","k","x","T","X","V","w","L","G","A","H","C","I","y","q","U","m","l","h","c","E","D","i","a","o","u","v","f","d","b","J","DropdownMenu","DropdownMenuPrimitive","DropdownMenuTrigger","DropdownMenuGroup","DropdownMenuPortal","DropdownMenuSub","DropdownMenuRadioGroup","DropdownMenuSubTrigger","inset","children","ChevronRight","DropdownMenuSubContent","DropdownMenuContent","sideOffset","DropdownMenuItem","DropdownMenuCheckboxItem","checked","Check","DropdownMenuRadioItem","Circle","DropdownMenuLabel","DropdownMenuSeparator","DropdownMenuShortcut","BookMenuItem","bookId","handleSelectBook","isSelected","handleHighlightBook","bookType","ShadDropdownMenuItem","Canon","ChapterSelect","handleSelectChapter","endChapter","activeChapter","highlightedChapter","handleHighlightedChapter","chapters","_","handleMouse","useCallback","chapterNumber","chapter","GoToMenuItem","handleSort","handleLocationHistory","handleBookmarks","ShadDropdownMenuLabel","ArrowDownWideNarrow","Clock","Bookmark","ALL_BOOK_IDS","BOOK_TYPE_LABELS","BOOK_TYPE_ARRAY","SCROLL_OFFSET","SEARCH_QUERY_FORMATS","fetchGroupedBooks","fetchEndChapter","getChaptersForBook","getAllEnglishNames","isValidBookEnglishName","bookName","getBookIdFromEnglishName","formattedBookName","BookChapterControl","scrRef","searchQuery","setSearchQuery","useState","selectedBookId","setSelectedBookId","setHighlightedChapter","highlightedBookId","setHighlightedBookId","isContentOpen","setIsContentOpen","isContentOpenDelayed","setIsContentOpenDelayed","inputRef","useRef","contentRef","menuItemRef","fetchFilteredBooks","englishNameLowerCase","normalizedQuery","handleSearchInput","searchString","shouldPreventAutoClosing","controlMenuState","open","updateReference","shouldClose","verse","handleInputSubmit","format","matches","book","englishName","handleKeyDownInput","handleKeyDownContent","key","handleKeyDownMenuItem","chapterOffSet","useEffect","useLayoutEffect","scrollTimeout","scrollPosition","ShadDropdownMenu","ShadDropdownMenuTrigger","ShadDropdownMenuContent","bookTypeIndex","element","ShadDropdownMenuSeparator","buttonVariants","cva","Button","variant","size","asChild","Slot","labelVariants","Label","LabelPrimitive","RadioGroup","RadioGroupPrimitive","RadioGroupItem","Popover","PopoverPrimitive","PopoverTrigger","PopoverContent","align","DialogPortal","DialogPrimitive","DialogOverlay","DialogContent","DialogTitle","DialogDescription","Command","CommandPrimitive","CommandInput","Search","CommandList","CommandEmpty","CommandGroup","CommandSeparator","CommandItem","getOptionLabelDefault","option","ComboBox","id","options","buttonClassName","popoverContentClassName","value","onChange","getOptionLabel","buttonPlaceholder","textPlaceholder","commandEmptyMessage","buttonVariant","dir","isDisabled","setOpen","ChevronsUpDown","ChapterRangeSelector","startChapter","handleSelectStartChapter","handleSelectEndChapter","chapterCount","chapterOptions","useMemo","index","Fragment","BookSelectionMode","BOOK_SELECTOR_STRING_KEYS","localizeString","strings","BookSelector","handleBookSelectionModeChange","currentBookName","onSelectBooks","selectedBookIds","localizedStrings","currentBookText","chooseText","chooseBooksText","bookSelectionMode","setBookSelectionMode","onSelectionModeChange","newMode","DataTableViewOptions","table","FilterIcon","column","Select","SelectPrimitive","SelectGroup","SelectValue","SelectTrigger","ChevronDown","SelectScrollUpButton","ChevronUp","SelectScrollDownButton","SelectContent","position","SelectLabel","SelectItem","SelectSeparator","DataTablePagination","pageSize","ArrowLeftIcon","ChevronLeftIcon","ChevronRightIcon","ArrowRightIcon","Table","stickyHeader","TableHeader","TableBody","TableFooter","TableRow","TableHead","TableCell","TableCaption","DataTable","columns","data","enablePagination","showPaginationControls","showColumnVisibilityControls","onRowClickHandler","sorting","setSorting","columnFilters","setColumnFilters","columnVisibility","setColumnVisibility","rowSelection","setRowSelection","useReactTable","getCoreRowModel","getPaginationRowModel","getSortedRowModel","getFilteredRowModel","headerGroup","header","flexRender","_a","row","cell","OccurrencesTable","occurrenceData","setScriptureReference","referenceHeaderText","occurrenceHeaderText","occurrences","uniqueOccurrences","occurrence","uniqueOccurrence","deepEqual","Checkbox","CheckboxPrimitive","getLinesFromUSFM","text","getNumberFromUSFM","regex","match","getBookNumFromId","getStatusForItem","item","approvedItems","unapprovedItems","toggleVariants","Toggle","TogglePrimitive","ToggleGroupContext","ToggleGroup","ToggleGroupPrimitive","ToggleGroupItem","context","getSortingIcon","sortDirection","ArrowUpIcon","ArrowDownIcon","ArrowUpDownIcon","inventoryItemColumn","itemLabel","inventoryAdditionalItemColumn","additionalItemLabel","additionalItemIndex","inventoryCountColumn","countLabel","statusChangeHandler","changedItems","newStatus","onApprovedItemsChange","onUnapprovedItemsChange","newApprovedItems","validItem","newUnapprovedItems","unapprovedItem","inventoryStatusColumn","statusLabel","status","CircleCheckIcon","CircleXIcon","CircleHelpIcon","INVENTORY_STRING_KEYS","filterItemData","itemData","statusFilter","textFilter","filteredItemData","createTableData","scriptureRef","itemRegex","tableData","currentBook","currentChapter","currentVerse","line","items","itemIndex","existingItem","tableEntry","newReference","substring","newItem","Inventory","scriptureReference","extractItems","additionalItemsLabels","scope","onScopeChange","allItemsText","approvedItemsText","unapprovedItemsText","unknownItemsText","scopeBookText","scopeChapterText","scopeVerseText","filterText","showAdditionalItemsText","showAdditionalItems","setShowAdditionalItems","setStatusFilter","setTextFilter","selectedItem","setSelectedItem","reducedTableData","newTableData","firstItem","existingEntry","newTableEntry","filteredTableData","allColumns","numberOfAdditionalItems","additionalColumns","_b","rowClickHandler","newSelection","handleScopeChange","handleStatusFilterChange","SearchBar","onSearch","placeholder","isFullWidth","handleInputChange","VerticalTabs","TabsPrimitive","VerticalTabsList","VerticalTabsTrigger","VerticalTabsContent","TabNavigationContentSearch","tabList","searchPlaceholder","headerTitle","isSearchBarFullWidth","direction","tab","Separator","orientation","decorative","SeparatorPrimitive","Sheet","SheetPrimitive","SheetPortal","SheetOverlay","sheetVariants","SheetContent","side","SheetTitle","SheetDescription","Skeleton","TooltipProvider","TooltipPrimitive","Tooltip","TooltipTrigger","TooltipContent","MOBILE_BREAKPOINT","useIsMobile","isMobile","setIsMobile","mql","SIDEBAR_COOKIE_NAME","SIDEBAR_COOKIE_MAX_AGE","SIDEBAR_WIDTH","SIDEBAR_WIDTH_MOBILE","SIDEBAR_WIDTH_ICON","SIDEBAR_KEYBOARD_SHORTCUT","SidebarContext","useSidebar","SidebarProvider","defaultOpen","openProp","setOpenProp","style","openMobile","setOpenMobile","_open","_setOpen","isOpen","openState","toggleSidebar","state","contextValue","Sidebar","collapsible","SidebarTrigger","onClick","PanelLeft","SidebarRail","SidebarInset","SidebarInput","SidebarHeader","SidebarFooter","SidebarSeparator","SidebarContent","SidebarGroup","SidebarGroupLabel","SidebarGroupAction","SidebarGroupContent","SidebarMenu","SidebarMenuItem","sidebarMenuButtonVariants","SidebarMenuButton","isActive","tooltip","Comp","button","SidebarMenuAction","showOnHover","SidebarMenuBadge","SidebarMenuSkeleton","showIcon","width","SidebarMenuSub","SidebarMenuSubItem","SidebarMenuSubButton","SettingsSidebar","extensionLabels","projectOptions","handleSelectSidebarItem","selectedSidebarItem","extensionsSidebarGroupLabel","projectsSidebarGroupLabel","buttonPlaceholderText","handleSelectItem","projectId","getProjectNameFromProjectId","project","getIsActive","label","selectedProjectName","SettingsSidebarContentSearch","scrBookColId","scrRefColId","typeColId","detailsColId","defaultScrRefColumnName","defaultScrBookGroupName","defaultTypeColumnName","defaultDetailsColumnName","getColumns","colInfo","showSourceColumn","showSrcCol","info","formatScrRef","compareScrRefs","toRefOrRange","scriptureSelection","offsetStart","offsetEnd","scrRefToBBBCCCVVV","getRowKey","ScriptureResultsViewer","sources","showColumnHeaders","scriptureReferenceColumnName","scriptureBookGroupName","typeColumnName","detailsColumnName","onRowSelected","grouping","setGrouping","scriptureResults","source","getExpandedRowModel","getGroupedRowModel","selectedRows","keys","selectedRow","scrBookGroupName","typeGroupName","groupingOptions","handleSelectChange","selectedGrouping","handleRowClick","getEvenOrOddBandingStyle","getIndent","groupingState","rowIndex","ChevronLeft","DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS","getLocalizeKeyForScrollGroupId","ScrollGroupSelector","availableScrollGroupIds","scrollGroupId","onChangeScrollGroupId","localizedStringsDefaulted","localizedStringKey","localizedStringValue","newScrollGroupString","scrollGroupOptionId","SettingsList","SettingsListItem","primary","secondary","isLoading","loadingMessage","SettingsListHeader","includeSeparator","Checklist","listItems","selectedListItems","handleSelectListItem","createLabel","_interopRequireDefault","obj","module","chainPropTypes","propType1","propType2","args","_extends","target","isPlainObject","prototype","deepClone","output","deepmerge","p","r","t","z","reactIs_production_min","hasSymbol","REACT_ELEMENT_TYPE","REACT_PORTAL_TYPE","REACT_FRAGMENT_TYPE","REACT_STRICT_MODE_TYPE","REACT_PROFILER_TYPE","REACT_PROVIDER_TYPE","REACT_CONTEXT_TYPE","REACT_ASYNC_MODE_TYPE","REACT_CONCURRENT_MODE_TYPE","REACT_FORWARD_REF_TYPE","REACT_SUSPENSE_TYPE","REACT_SUSPENSE_LIST_TYPE","REACT_MEMO_TYPE","REACT_LAZY_TYPE","REACT_BLOCK_TYPE","REACT_FUNDAMENTAL_TYPE","REACT_RESPONDER_TYPE","REACT_SCOPE_TYPE","isValidElementType","typeOf","object","$$typeof","$$typeofType","AsyncMode","ConcurrentMode","ContextConsumer","ContextProvider","Element","ForwardRef","Lazy","Memo","Portal","Profiler","StrictMode","Suspense","hasWarnedAboutDeprecatedIsAsyncMode","isAsyncMode","isConcurrentMode","isContextConsumer","isContextProvider","isElement","isForwardRef","isFragment","isLazy","isMemo","isPortal","isProfiler","isStrictMode","isSuspense","reactIs_development","reactIsModule","require$$0","require$$1","getOwnPropertySymbols","hasOwnProperty","propIsEnumerable","toObject","val","shouldUseNative","test1","test2","order2","test3","letter","objectAssign","from","to","symbols","ReactPropTypesSecret","ReactPropTypesSecret_1","has","printWarning","loggedTypeFailures","message","checkPropTypes","typeSpecs","values","location","componentName","getStack","typeSpecName","error","err","ex","stack","checkPropTypes_1","ReactIs","assign","require$$2","require$$3","require$$4","emptyFunctionThatReturnsNull","factoryWithTypeCheckers","isValidElement","throwOnDirectAccess","ITERATOR_SYMBOL","FAUX_ITERATOR_SYMBOL","getIteratorFn","maybeIterable","iteratorFn","ANONYMOUS","ReactPropTypes","createPrimitiveTypeChecker","createAnyTypeChecker","createArrayOfTypeChecker","createElementTypeChecker","createElementTypeTypeChecker","createInstanceTypeChecker","createNodeChecker","createObjectOfTypeChecker","createEnumTypeChecker","createUnionTypeChecker","createShapeTypeChecker","createStrictShapeTypeChecker","is","PropTypeError","createChainableTypeChecker","validate","manualPropTypeCallCache","manualPropTypeWarningCount","checkType","isRequired","propName","propFullName","secret","cacheKey","chainedCheckType","expectedType","propValue","propType","getPropType","preciseType","getPreciseType","typeChecker","expectedClass","expectedClassName","actualClassName","getClassName","expectedValues","valuesString","arrayOfTypeCheckers","checker","getPostfixForTypeWarning","expectedTypes","checkerResult","expectedTypesMessage","isNode","invalidValidatorError","shapeTypes","allKeys","iterator","step","entry","isSymbol","emptyFunction","emptyFunctionWithReset","factoryWithThrowingShims","shim","getShim","propTypesModule","isClassComponent","elementType","acceptingRef","safePropName","warningHint","elementAcceptingRef","PropTypes","elementAcceptingRef$1","specialProperty","exactProp","propTypes","unsupportedProps","prop","formatMuiErrorMessage","code","url","REACT_SERVER_CONTEXT_TYPE","REACT_OFFSCREEN_TYPE","enableScopeAPI","enableCacheElement","enableTransitionTracing","enableLegacyHidden","enableDebugTracing","REACT_MODULE_REFERENCE","SuspenseList","hasWarnedAboutDeprecatedIsConcurrentMode","isSuspenseList","fnNameMatchRegex","getFunctionName","fn","getFunctionComponentName","Component","fallback","getWrappedName","outerType","innerType","wrapperName","functionName","getDisplayName","HTMLElementType","refType","refType$1","capitalize","string","_formatMuiErrorMessage","createChainedFunction","funcs","acc","func","debounce","wait","timeout","debounced","later","deprecatedPropType","validator","reason","componentNameSafe","propFullNameSafe","isMuiElement","muiNames","_muiName","_element$type","ownerDocument","node","ownerWindow","requirePropFactory","componentNameInError","prevPropTypes","requiredProp","defaultTypeChecker","typeCheckerResult","setRef","useEnhancedEffect","useEnhancedEffect$1","globalId","useGlobalId","idOverride","defaultId","setDefaultId","maybeReactUseId","useId","reactId","unsupportedProp","useControlled","controlled","defaultProp","name","isControlled","valueState","setValue","defaultValue","setValueIfUncontrolled","newValue","useEventCallback","useForkRef","refs","instance","UNINITIALIZED","useLazyRef","init","initArg","EMPTY","useOnMount","Timeout","delay","useTimeout","hadKeyboardEvent","hadFocusVisibleRecently","hadFocusVisibleRecentlyTimeout","inputTypesWhitelist","focusTriggersKeyboardModality","tagName","handlePointerDown","handleVisibilityChange","prepare","doc","isFocusVisible","useIsFocusVisible","isFocusVisibleRef","handleBlurVisible","handleFocusVisible","resolveProps","defaultProps","defaultSlotProps","slotProps","slotPropName","composeClasses","slots","getUtilityClass","classes","slot","utilityClass","defaultGenerator","createClassNameGenerator","generate","generator","ClassNameGenerator","ClassNameGenerator$1","globalStateClasses","generateUtilityClass","globalStatePrefix","globalStateClass","generateUtilityClasses","result","clamp","min","max","_objectWithoutPropertiesLoose","excluded","sourceKeys","_excluded","sortBreakpointsValues","breakpointsAsArray","breakpoint1","breakpoint2","createBreakpoints","breakpoints","unit","other","sortedValues","up","down","between","start","end","endIndex","only","not","keyIndex","shape","shape$1","responsivePropType","responsivePropType$1","merge","defaultBreakpoints","handleBreakpoints","styleFromPropValue","theme","themeBreakpoints","breakpoint","mediaKey","cssKey","createEmptyBreakpointObject","breakpointsInput","_breakpointsInput$key","breakpointStyleKey","removeUnusedBreakpoints","breakpointKeys","breakpointOutput","getPath","path","checkVars","getStyleValue","themeMapping","transform","propValueFinal","userValue","cssProperty","themeKey","memoize","cache","arg","properties","directions","aliases","getCssProperties","property","marginKeys","paddingKeys","spacingKeys","createUnaryUnit","_getPath","themeSpacing","abs","createUnarySpacing","getValue","transformer","transformed","getStyleFromPropValue","cssProperties","resolveCssProperty","margin","padding","createSpacing","spacingInput","spacing","argsInput","argument","compose","styles","handlers","borderTransform","createBorderStyle","border","borderTop","borderRight","borderBottom","borderLeft","borderColor","borderTopColor","borderRightColor","borderBottomColor","borderLeftColor","outline","outlineColor","borderRadius","gap","columnGap","rowGap","gridColumn","gridRow","gridAutoFlow","gridAutoColumns","gridAutoRows","gridTemplateColumns","gridTemplateRows","gridTemplateAreas","gridArea","paletteTransform","color","bgcolor","backgroundColor","sizingTransform","maxWidth","_props$theme","_props$theme2","breakpointsValues","minWidth","height","maxHeight","minHeight","boxSizing","defaultSxConfig","defaultSxConfig$1","objectsHaveSameKeys","objects","union","callIfFn","maybeFn","unstable_createStyleFunctionSx","getThemeValue","config","styleFunctionSx","_theme$unstable_sxCon","sx","traverse","sxInput","sxObject","emptyBreakpoints","breakpointsKeys","css","styleKey","styleFunctionSx$1","applyStyles","createTheme","paletteInput","shapeInput","muiTheme","isObjectEmpty","useTheme","defaultTheme","contextTheme","ThemeContext","systemDefaultTheme","useThemeWithoutDefault","_excluded2","_excluded3","isEmpty","isStringTag","tag","shouldForwardProp","lowercaseFirstLetter","resolveTheme","themeId","defaultOverridesResolver","processStyleArg","callableStyle","_ref","ownerState","resolvedStylesArg","resolvedStyle","variants","isMatch","createStyled","input","rootShouldForwardProp","slotShouldForwardProp","systemSx","inputOptions","processStyles","componentSlot","inputSkipVariantsResolver","inputSkipSx","overridesResolver","skipVariantsResolver","skipSx","shouldForwardPropOption","defaultStyledResolver","styledEngineStyled","transformStyleArg","stylesArg","muiStyledResolver","styleArg","expressions","transformedStyleArg","expressionsWithDefaultTheme","styleOverrides","resolvedStyleOverrides","slotKey","slotStyle","_theme$components","themeVariants","numOfCustomFnsApplied","placeholders","displayName","getThemeProps","params","useThemeProps","clampWrapper","hexToRgb","re","colors","decomposeColor","marker","colorSpace","recomposeColor","hslToRgb","rgb","getLuminance","getContrastRatio","foreground","background","lumA","lumB","alpha","darken","coefficient","lighten","createMixins","mixins","common","common$1","grey","grey$1","purple","purple$1","red","red$1","orange","orange$1","blue","blue$1","lightBlue","lightBlue$1","green","green$1","light","dark","addLightOrDark","intent","shade","tonalOffset","tonalOffsetLight","tonalOffsetDark","getDefaultPrimary","mode","getDefaultSecondary","getDefaultError","getDefaultInfo","getDefaultSuccess","getDefaultWarning","createPalette","palette","contrastThreshold","success","warning","getContrastText","contrastText","contrast","augmentColor","mainShade","lightShade","darkShade","modes","round","caseAllCaps","defaultFontFamily","createTypography","typography","fontFamily","fontSize","fontWeightLight","fontWeightRegular","fontWeightMedium","fontWeightBold","htmlFontSize","allVariants","pxToRem2","coef","pxToRem","buildVariant","fontWeight","lineHeight","letterSpacing","casing","shadowKeyUmbraOpacity","shadowKeyPenumbraOpacity","shadowAmbientShadowOpacity","createShadow","px","shadows","shadows$1","easing","duration","formatMs","milliseconds","getAutoHeightDuration","constant","createTransitions","inputTransitions","mergedEasing","mergedDuration","durationOption","easingOption","isString","isNumber","animatedProp","zIndex","zIndex$1","mixinsInput","transitionsInput","typographyInput","systemTheme","systemCreateTheme","stateClasses","component","child","stateClass","defaultTheme$1","THEME_ID","systemUseThemeProps","styled","styled$1","getSvgIconUtilityClass","useUtilityClasses","SvgIconRoot","_theme$transitions","_theme$transitions$cr","_theme$transitions2","_theme$typography","_theme$typography$pxT","_theme$typography2","_theme$typography2$px","_theme$typography3","_theme$typography3$px","_palette$ownerState$c","_palette","_palette2","_palette3","SvgIcon","inProps","htmlColor","inheritViewBox","titleAccess","viewBox","hasSvgAsChild","more","_jsxs","_jsx","SvgIcon$1","createSvgIcon","unstable_ClassNameGenerator","exports","_utils","ArrowRight","default_1","_createSvgIcon","_jsxRuntime","isHostComponent","appendOwnerState","otherProps","defaultContextValue","ClassNameConfiguratorContext","useClassNamesOverride","disableDefaultClasses","extractEventHandlers","excludeKeys","resolveComponentProps","componentProps","slotState","omitEventHandlers","mergeSlotProps","parameters","getSlotProps","additionalProps","externalSlotProps","externalForwardedProps","joinedClasses","mergedStyle","eventHandlers","componentsPropsWithoutEventHandlers","otherPropsWithoutEventHandlers","internalSlotProps","useSlotProps","_parameters$additiona","skipResolvingSlotProps","rest","resolvedComponentsProps","mergedProps","internalRef","GLOBAL_CLASS_PREFIX","buildStateClass","buildSlotClass","getContainer","container","forwardedRef","disablePortal","mountNode","setMountNode","handleRef","newProps","ReactDOM","top","bottom","right","left","auto","basePlacements","clippingParents","viewport","popper","reference","variationPlacements","placement","placements","beforeRead","read","afterRead","beforeMain","main","afterMain","beforeWrite","write","afterWrite","modifierPhases","getNodeName","getWindow","OwnElement","isHTMLElement","isShadowRoot","attributes","effect","_ref2","initialStyles","styleProperties","attribute","applyStyles$1","getBasePlacement","getUAString","uaData","isLayoutViewport","getBoundingClientRect","includeScale","isFixedStrategy","clientRect","scaleX","scaleY","visualViewport","addVisualOffsets","getLayoutRect","contains","parent","rootNode","next","getComputedStyle","isTableElement","getDocumentElement","getParentNode","getTrueOffsetParent","getContainingBlock","isFirefox","isIE","elementCss","currentNode","getOffsetParent","window","offsetParent","getMainAxisFromPlacement","within","mathMax","mathMin","withinMaxClamp","getFreshSideObject","mergePaddingObject","paddingObject","expandToHashMap","hashMap","toPaddingObject","arrow","_state$modifiersData$","arrowElement","popperOffsets","basePlacement","axis","isVertical","len","arrowRect","minProp","maxProp","endDiff","startDiff","arrowOffsetParent","clientSize","centerToReference","center","offset","axisProp","_options$element","arrow$1","getVariation","unsetSides","roundOffsetsByDPR","win","dpr","mapToStyles","_Object$assign2","popperRect","variation","offsets","gpuAcceleration","adaptive","roundOffsets","isFixed","_offsets$x","_offsets$y","_ref3","hasX","hasY","sideX","sideY","heightProp","widthProp","offsetY","offsetX","commonStyles","_ref4","_Object$assign","computeStyles","_ref5","_options$gpuAccelerat","_options$adaptive","_options$roundOffsets","computeStyles$1","passive","_options$scroll","scroll","_options$resize","resize","scrollParents","scrollParent","eventListeners","hash","getOppositePlacement","matched","getOppositeVariationPlacement","getWindowScroll","scrollLeft","scrollTop","getWindowScrollBarX","getViewportRect","strategy","html","layoutViewport","getDocumentRect","_element$ownerDocumen","winScroll","body","isScrollParent","_getComputedStyle","overflow","overflowX","overflowY","getScrollParent","listScrollParents","list","isBody","updatedList","rectToClientRect","rect","getInnerBoundingClientRect","getClientRectFromMixedType","clippingParent","getClippingParents","canEscapeClipping","clipperElement","getClippingRect","boundary","rootBoundary","mainClippingParents","firstClippingParent","clippingRect","accRect","computeOffsets","commonX","commonY","mainAxis","detectOverflow","_options","_options$placement","_options$strategy","_options$boundary","_options$rootBoundary","_options$elementConte","elementContext","_options$altBoundary","altBoundary","_options$padding","altContext","clippingClientRect","referenceClientRect","popperClientRect","elementClientRect","overflowOffsets","offsetData","multiply","computeAutoPlacement","flipVariations","_options$allowedAutoP","allowedAutoPlacements","allPlacements","allowedPlacements","overflows","getExpandedFallbackPlacements","oppositePlacement","flip","_options$mainAxis","checkMainAxis","_options$altAxis","checkAltAxis","specifiedFallbackPlacements","_options$flipVariatio","preferredPlacement","isBasePlacement","fallbackPlacements","referenceRect","checksMap","makeFallbackChecks","firstFittingPlacement","_basePlacement","isStartVariation","mainVariationSide","altVariationSide","checks","check","numberOfChecks","_loop","_i","fittingPlacement","_ret","flip$1","getSideOffsets","preventedOffsets","isAnySideFullyClipped","hide","referenceOverflow","popperAltOverflow","referenceClippingOffsets","popperEscapeOffsets","isReferenceHidden","hasPopperEscaped","hide$1","distanceAndSkiddingToXY","rects","invertDistance","skidding","distance","_options$offset","_data$state$placement","offset$1","popperOffsets$1","getAltAxis","preventOverflow","_options$tether","tether","_options$tetherOffset","tetherOffset","altAxis","tetherOffsetValue","normalizedTetherOffsetValue","offsetModifierState","_offsetModifierState$","mainSide","altSide","additive","minLen","maxLen","arrowPaddingObject","arrowPaddingMin","arrowPaddingMax","arrowLen","minOffset","maxOffset","clientOffset","offsetModifierValue","tetherMin","tetherMax","preventedOffset","_offsetModifierState$2","_mainSide","_altSide","_offset","_len","_min","_max","isOriginSide","_offsetModifierValue","_tetherMin","_tetherMax","_preventedOffset","preventOverflow$1","getHTMLElementScroll","getNodeScroll","isElementScaled","getCompositeRect","elementOrVirtualElement","isOffsetParentAnElement","offsetParentIsScaled","documentElement","order","modifiers","map","visited","modifier","sort","requires","dep","depModifier","orderModifiers","orderedModifiers","phase","pending","resolve","mergeByName","merged","current","existing","DEFAULT_OPTIONS","areValidElements","_key","popperGenerator","generatorOptions","_generatorOptions","_generatorOptions$def","defaultModifiers","_generatorOptions$def2","defaultOptions","effectCleanupFns","isDestroyed","setOptionsAction","cleanupModifierEffects","runModifierEffects","_state$elements","_state$orderedModifie","_state$orderedModifie2","_ref$options","cleanupFn","noopFn","createPopper","COMPONENT_NAME","getPopperUtilityClass","flipPlacement","resolveAnchorEl","anchorEl","isVirtualElement","defaultPopperOptions","PopperTooltip","_slots$root","initialPlacement","popperOptions","popperRefProp","TransitionProps","tooltipRef","ownRef","popperRef","handlePopperRef","handlePopperRefRef","rtlPlacement","setPlacement","resolvedAnchorElement","setResolvedAnchorElement","handlePopperUpdate","box","popperModifiers","childProps","Root","rootProps","Popper","containerProp","keepMounted","transition","exited","setExited","handleEnter","handleExited","resolvedAnchorEl","display","transitionProps","useThemeSystem","_setPrototypeOf","_inheritsLoose","subClass","superClass","setPrototypeOf","timeoutsShape","TransitionGroupContext","forceReflow","UNMOUNTED","EXITED","ENTERING","ENTERED","EXITING","Transition","_React$Component","_this","parentGroup","appear","initialStatus","prevState","nextIn","_proto","prevProps","nextStatus","exit","enter","mounting","_this2","appearing","maybeNode","maybeAppearing","timeouts","enterTimeout","_this3","nextState","callback","_this4","active","handler","doesNotHaveTimeoutOrListener","maybeNextCallback","_this$props","pt","noop","Transition$1","reflow","getTransitionProps","_style$transitionDura","_style$transitionTimi","getScale","isWebKit154","Grow","addEndListener","inProp","onEnter","onEntered","onEntering","onExit","onExited","onExiting","TransitionComponent","timer","autoTimeout","nodeRef","normalizedTransitionCallback","maybeIsAppearing","handleEntering","isAppearing","transitionDuration","transitionTimingFunction","handleEntered","handleExiting","handleExit","Grow$1","PopperRoot","BasePopper","components","componentsProps","RootComponent","Popper$1","getTooltipUtilityClass","tooltipClasses","tooltipClasses$1","disableInteractive","touch","TooltipPopper","TooltipTooltip","TooltipArrow","hystersisOpen","hystersisTimer","cursorPosition","composeEventHandler","eventHandler","_slots$popper","_slots$transition","_slots$tooltip","_slots$arrow","_slotProps$popper","_ref6","_slotProps$popper2","_slotProps$transition","_slotProps$tooltip","_ref7","_slotProps$tooltip2","_slotProps$arrow","_ref8","_slotProps$arrow2","childrenProp","describeChild","disableFocusListener","disableHoverListener","disableInteractiveProp","disableTouchListener","enterDelay","enterNextDelay","enterTouchDelay","followCursor","idProp","leaveDelay","leaveTouchDelay","onClose","onOpen","PopperComponentProp","PopperProps","title","TransitionComponentProp","isRtl","childNode","setChildNode","arrowRef","setArrowRef","ignoreNonTouchEvents","closeTimer","enterTimer","leaveTimer","touchTimer","setOpenState","prevUserSelect","stopTouchInteraction","handleOpen","handleClose","handleLeave","focusVisibleRef","setChildIsFocusVisible","handleBlur","handleFocus","detectTouchStart","childrenProps","handleMouseOver","handleMouseLeave","handleTouchStart","handleTouchEnd","nativeEvent","handleMouseMove","nameOrDescProps","titleIsString","interactiveWrapperListeners","_PopperProps$popperOp","tooltipModifiers","PopperComponent","TooltipComponent","ArrowComponent","popperProps","tooltipProps","tooltipArrowProps","TransitionPropsInner","Tooltip$1","getIcon","icon","menuLabel","leading","MuiListItemIcon","MenuItem","allowForLeadingIcons","iconPathBefore","iconPathAfter","hasAutoFocus","isDense","isSubMenuParent","hasDisabledGutters","hasDivider","focusVisibleClassName","menuItem","MuiMenuItem","MuiListItemText","getAllGroups","menuDefinition","SubMenu","setAnchorEl","parentMenuItem","parentItemProps","handleParentMenuItemClick","renderSubMenuItems","includedGroups","group","GroupedMenuItemList","Menu","getOrderedGroupItems","groupId","allItems","menuProps","commandHandler","groupsToInclude","sortedGroups","itemArray","allowSpaceForLeadingIcons","createMenuItemProps","isLastItemInGroup","divKey","itemInfo","menuItemProps","TopLevelMenu","columnId","MenuColumn","metadata","Grid","List","GridMenu","multiColumnMenu","sortedColumns","columnNumbers","columnName","col","getUsePromiseOptionsDefaults","usePromise","promiseFactoryCallback","defaultValueRef","optionsDefaultedRef","setIsLoading","promiseIsCurrent","MenuIcon","HamburgerMenuButton","menuProvider","normalMenu","fullMenu","containerRef","ariaLabelPrefix","isMenuOpen","setMenuOpen","showFullMenu","setShowFullMenu","handleMenuItemClick","handleMenuButtonClick","prevIsOpen","isOpening","menuCommandHandler","command","setOffset","normalMenuData","fullMenuData","menu","IconButton","Drawer","isTooltipSuppressed","adjustMarginToAlignToEdge","MuiIconButton","Spinner","LoaderCircle","TextField","hasError","helperText","onFocus","onBlur","ShadLabel","Toolbar","AppBar","MuiToolbar","alertVariants","Alert","AlertTitle","AlertDescription","Card","CardHeader","CardTitle","CardDescription","CardContent","CardFooter","Sonner","Toaster","Slider","SliderPrimitive","Switch","SwitchPrimitives","Tabs","TabsList","TabsTrigger","TabsContent","InstallButton","isInstalling","handleClick","buttonText","Download","EnableButton","isEnabling","DisableButton","isDisabling","UpdateButton","isUpdating","MarkdownRenderer","markdown","anchorTarget","Markdown","FilterButton","Filter","DropdownMenuItemType","DropdownMenuItemType2","FilterDropdown","groups","NoExtensionsFound","MoreInfo","category","downloads","languages","moreInfoUrl","numberFormatted","NumberFormat","handleScrollToBottom","User","locale","LucideLink","CircleHelp","VersionHistory","versionHistory","showAllVersions","setShowAllVersions","currentDate","formatTimeString","dateString","date","dateDiff","yearDiff","monthDiff","dayDiff","timeString","sortedEntries","Footer","publisherDisplayName","fileSize","locales","formattedFileSize","formatBytes","languageNames","codes","displayNames","useEvent","unsubscriber","noopUnsubscriber","useEventAsync","unsubscribe","unsub"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAGA,MAAMA,KAAgBC,GAAoB,EAAE,QAAQ,MAAO,CAAA;AAyDpD,SAASC,KAAMC,GAAsB;AACnC,SAAAH,GAAcI,GAAKD,CAAM,CAAC;AACnC;ACzDO,MAAME,KAAQC,EAAM;AAAA,EACzB,CAAC,EAAE,WAAAC,GAAW,MAAAC,GAAM,GAAGC,EAAA,GAASC,MAE5B,gBAAAC;AAAA,IAAC;AAAA,IAAA;AAAA,MACC,MAAAH;AAAA,MACA,WAAWN;AAAA,QACT;AAAA,QACAK;AAAA,MACF;AAAA,MACA,KAAAG;AAAA,MAEC,GAAGD;AAAA,IAAA;AAAA,EAAA;AAIZ;AACAJ,GAAM,cAAc;ACNpB,MAAMO,KAAmBC;AAAA,EACvB,CACE,EAAE,cAAAC,GAAc,eAAAC,GAAe,eAAAC,GAAe,cAAAC,GAAc,GAAGR,EAAM,GACrEC,MAGE,gBAAAQ,EAAC,OAAI,EAAA,WAAU,eACb,UAAA;AAAA,IAAA,gBAAAP;AAAA,MAACQ;AAAAA,MAAA;AAAA,QACE,GAAGV;AAAA,QACJ,MAAK;AAAA,QACL,WAAU;AAAA,QACV,UAAU,CAACW,MAAUN,EAAaM,EAAM,OAAO,KAAK;AAAA,QACpD,WAAW,CAACC,MAAM;AACZ,UAAAA,EAAE,QAAQ,WACCJ,KAEfF,EAAcM,CAAC;AAA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A,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA;AAAA;AAAA,EAGA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AACF,GAAGC,KAAIC;AACP,SAASC,GAAE,GAAG,IAAI,IAAI;AACpB,SAAO,MAAM,IAAI,EAAE,YAAa,IAAG,KAAKF,KAAIA,GAAE,CAAC,IAAI;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;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","x_google_ignoreList":[3,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,83,84,85,86,87,88,89,90,91,92,93,94,95,96,97,98,99,100,101,102,103,104,105,106,107,108,109,110,111,112,113,114,115,116,117,118,119,120,121,122,123,124,125,126,127,128,129,130,131,132,133,134,135,136,137,138,139,140,141,142,143,144,145,146,147,148,149,150,151,152,153,154,155,156,157,158,159,160,161,162,163,164,165,166,167,168,169,170,171,172,173,174,175,176,177,178,179,180,181,182,183,184,185,186,187,188,189,190,191,192,193,194,195,196,197,198,199,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,228]} \ No newline at end of file diff --git a/lib/platform-bible-react/src/components/advanced/settings-components/settings-sidebar-content-search.component.tsx b/lib/platform-bible-react/src/components/advanced/settings-components/settings-sidebar-content-search.component.tsx index 99b5ed5099..210a18da17 100644 --- a/lib/platform-bible-react/src/components/advanced/settings-components/settings-sidebar-content-search.component.tsx +++ b/lib/platform-bible-react/src/components/advanced/settings-components/settings-sidebar-content-search.component.tsx @@ -8,16 +8,12 @@ export type SettingsSidebarContentSearchProps = SettingsSidebarProps & /** Optional id for testing */ id?: string; - /** Text direction ltr or rtl */ - direction?: 'ltr' | 'rtl'; - /** Handler to run when the value of the search bar changes */ onSearch: (searchQuery: string) => void; }; export default function SettingsSidebarContentSearch({ id, - direction = 'ltr', extensionLabels, projectOptions, children, @@ -26,7 +22,7 @@ export default function SettingsSidebarContentSearch({ onSearch, extensionsSidebarGroupLabel, projectsSidebarGroupLabel, - buttonPlaceholder, + buttonPlaceholderText, }: SettingsSidebarContentSearchProps) { return (
    @@ -37,11 +33,7 @@ export default function SettingsSidebarContentSearch({ placeholder="Search app settings, extension settings, and project settings" />
    - + {children} diff --git a/lib/platform-bible-react/src/components/advanced/settings-components/settings-sidebar.component.tsx b/lib/platform-bible-react/src/components/advanced/settings-components/settings-sidebar.component.tsx index aac254c988..ceaf4462c9 100644 --- a/lib/platform-bible-react/src/components/advanced/settings-components/settings-sidebar.component.tsx +++ b/lib/platform-bible-react/src/components/advanced/settings-components/settings-sidebar.component.tsx @@ -17,7 +17,7 @@ export type SelectedSettingsSidebarItem = { projectId?: string; }; -export type ProjectOptions = { projectId: string; projectName: string }; +export type ProjectInfo = { projectId: string; projectName: string }; export type SettingsSidebarProps = { /** Optional id for testing */ @@ -27,7 +27,7 @@ export type SettingsSidebarProps = { extensionLabels: string[]; /** Project names and ids */ - projectOptions: ProjectOptions[]; + projectOptions: ProjectInfo[]; /** Handler for selecting a sidebar item */ handleSelectSidebarItem: (key: string, projectId?: string) => void; @@ -41,8 +41,8 @@ export type SettingsSidebarProps = { /** Label for the group of projects settings */ projectsSidebarGroupLabel: string; - /** Placeholder for the button */ - buttonPlaceholder: string; + /** Placeholder text for the button */ + buttonPlaceholderText: string; }; export default function SettingsSidebar({ @@ -53,7 +53,7 @@ export default function SettingsSidebar({ selectedSidebarItem, extensionsSidebarGroupLabel, projectsSidebarGroupLabel, - buttonPlaceholder, + buttonPlaceholderText, }: SettingsSidebarProps) { const handleSelectItem = useCallback( (item: string, projectId?: string) => { @@ -96,7 +96,7 @@ export default function SettingsSidebar({ 'tw-rounded tw-py-2 tw-text-sm tw-text-gray-500 hover:tw-bg-white hover:tw-text-gray-900 hover:tw-shadow-sm active:tw-bg-white', { 'tw-bg-white tw-text-gray-900 tw-shadow-sm': getIsActive(label) }, )} - onClick={() => handleSelectItem(label, undefined)} + onClick={() => handleSelectItem(label)} isActive={getIsActive(label)} > {label} @@ -119,7 +119,7 @@ export default function SettingsSidebar({ // eslint-disable-next-line no-type-assertion/no-type-assertion return getProjectNameFromProjectId(projectId as string); }} - buttonPlaceholder={buttonPlaceholder} + buttonPlaceholder={buttonPlaceholderText} onChange={(projectId: string) => { const selectedProjectName = getProjectNameFromProjectId(projectId); handleSelectItem(selectedProjectName, projectId); diff --git a/lib/platform-bible-react/src/components/basics/search-bar.component.tsx b/lib/platform-bible-react/src/components/basics/search-bar.component.tsx index 40163aa5d1..a4f9771bc3 100644 --- a/lib/platform-bible-react/src/components/basics/search-bar.component.tsx +++ b/lib/platform-bible-react/src/components/basics/search-bar.component.tsx @@ -2,6 +2,7 @@ import { Input } from '@/components/shadcn-ui/input'; import { cn } from '@/utils/shadcn-ui.util'; import { useState } from 'react'; +/** Props for the SearchBar component. */ export type SearchBarProps = { className?: string; /** diff --git a/lib/platform-bible-react/src/components/hooks/use-mobile.tsx b/lib/platform-bible-react/src/components/hooks/use-mobile.tsx index d8fca73432..972c7d6d27 100644 --- a/lib/platform-bible-react/src/components/hooks/use-mobile.tsx +++ b/lib/platform-bible-react/src/components/hooks/use-mobile.tsx @@ -1,4 +1,4 @@ -import * as React from 'react'; +import React from 'react'; const MOBILE_BREAKPOINT = 768; diff --git a/lib/platform-bible-react/src/index.ts b/lib/platform-bible-react/src/index.ts index 6fd6ae51c7..e3fd8a4330 100644 --- a/lib/platform-bible-react/src/index.ts +++ b/lib/platform-bible-react/src/index.ts @@ -43,7 +43,7 @@ export { export { default as SettingsSidebar, type SettingsSidebarProps, - type ProjectOptions, + type ProjectInfo as ProjectOptions, type SelectedSettingsSidebarItem, } from './components/advanced/settings-components/settings-sidebar.component'; export { default as SettingsSidebarContentSearch } from './components/advanced/settings-components/settings-sidebar-content-search.component'; diff --git a/src/renderer/components/settings-tabs/settings-tab.component.tsx b/src/renderer/components/settings-tabs/settings-tab.component.tsx index b786f4d8b6..dc120468c9 100644 --- a/src/renderer/components/settings-tabs/settings-tab.component.tsx +++ b/src/renderer/components/settings-tabs/settings-tab.component.tsx @@ -41,6 +41,7 @@ const LOCALIZE_SETTING_KEYS: LocalizeKey[] = [ '%settings_sidebar_extensionsLabel%', '%settings_sidebar_projectsLabel%', '%settings_sidebar_projectsComboBoxPlaceholder%', + '%settings_defaultMessage_noSettings%', ]; export default function SettingsTab({ projectIdToLimitSettings }: SettingsTabProps) { @@ -182,7 +183,10 @@ export default function SettingsTab({ projectIdToLimitSettings }: SettingsTabPro
    ); - if (!settingsContributions) return
    No Settings
    ; + if (!settingsContributions) + return ( +
    {localizedStrings['%settings_defaultMessage_noSettings%']}
    + ); return (
    From 90daad4a5427a4c7ed85d84fbda450a5cca1ef55 Mon Sep 17 00:00:00 2001 From: Jolie Rabideau Date: Tue, 3 Dec 2024 16:27:11 -0500 Subject: [PATCH 12/18] Add deprecated comment to className, fix shadcn sidebar code and preview --- lib/platform-bible-react/dist/index.cjs | 198 +- lib/platform-bible-react/dist/index.cjs.map | 2 +- lib/platform-bible-react/dist/index.js | 4806 ++++++++--------- lib/platform-bible-react/dist/index.js.map | 2 +- .../components/basics/combo-box.component.tsx | 2 + .../src/components/hooks/use-mobile.tsx | 19 - .../src/components/shadcn-ui/sheet.tsx | 131 - .../src/components/shadcn-ui/sidebar.tsx | 60 +- .../basics/sidebar.examples.component.tsx | 57 +- 9 files changed, 2424 insertions(+), 2853 deletions(-) delete mode 100644 lib/platform-bible-react/src/components/hooks/use-mobile.tsx delete mode 100644 lib/platform-bible-react/src/components/shadcn-ui/sheet.tsx diff --git a/lib/platform-bible-react/dist/index.cjs b/lib/platform-bible-react/dist/index.cjs index 0aced6c971..d9ed6eedc1 100644 --- a/lib/platform-bible-react/dist/index.cjs +++ b/lib/platform-bible-react/dist/index.cjs @@ -1,23 +1,23 @@ -"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const a=require("react/jsx-runtime"),g=require("react"),Q=require("lucide-react"),ot=require("clsx"),ml=require("tailwind-merge"),Za=require("@radix-ui/react-dropdown-menu"),W=require("platform-bible-utils"),Ht=require("@radix-ui/react-slot"),Xt=require("class-variance-authority"),hl=require("@radix-ui/react-label"),gl=require("@radix-ui/react-radio-group"),bl=require("@radix-ui/react-popover"),Re=require("cmdk"),vl=require("@radix-ui/react-dialog"),Se=require("@tanstack/react-table"),xl=require("@radix-ui/react-select"),yl=require("@radix-ui/react-checkbox"),Nl=require("@radix-ui/react-toggle-group"),kl=require("@radix-ui/react-toggle"),Sl=require("@radix-ui/react-tabs"),El=require("@radix-ui/react-separator"),jl=require("@radix-ui/react-tooltip"),Gr=require("@mui/styled-engine"),Me=require("@mui/material"),ln=require("react-dom"),Qa=require("sonner"),Cl=require("@radix-ui/react-slider"),Tl=require("@radix-ui/react-switch"),Rl=require("markdown-to-jsx");function ke(e){const t=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(e){for(const n in e)if(n!=="default"){const r=Object.getOwnPropertyDescriptor(e,n);Object.defineProperty(t,n,r.get?r:{enumerable:!0,get:()=>e[n]})}}return t.default=e,Object.freeze(t)}const M=ke(g),pe=ke(Za),es=ke(hl),bn=ke(gl),vn=ke(bl),be=ke(vl),ge=ke(xl),Ur=ke(yl),rr=ke(Nl),ts=ke(kl),Oe=ke(Sl),ns=ke(El),Sn=ke(jl),Ol=ke(ln),cn=ke(Cl),qr=ke(Tl);const _l=ml.extendTailwindMerge({prefix:"tw-"});function N(...e){return _l(ot.clsx(e))}const St=g.forwardRef(({className:e,type:t,...n},r)=>a.jsx("input",{type:t,className:N("pr-twp tw-flex tw-h-10 tw-rounded-md tw-border tw-border-input tw-bg-background tw-px-3 tw-py-2 tw-text-sm tw-ring-offset-background file:tw-border-0 file:tw-bg-transparent file:tw-text-sm file:tw-font-medium file:tw-text-foreground placeholder:tw-text-muted-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-cursor-not-allowed disabled:tw-opacity-50",e),ref:r,...n}));St.displayName="Input";const Pl=g.forwardRef(({handleSearch:e,handleKeyDown:t,handleOnClick:n,handleSubmit:r,...o},s)=>a.jsxs("div",{className:"tw-relative",children:[a.jsx(St,{...o,type:"text",className:"tw-box-border tw-gap-2.5 tw-rounded-lg tw-border tw-border-solid tw-bg-background tw-py-2 tw-pl-4 tw-pr-3 tw-font-medium tw-shadow-none tw-outline-none",onChange:i=>e(i.target.value),onKeyDown:i=>{i.key==="Enter"&&r(),t(i)},onClick:n,ref:s}),a.jsx(Q.History,{className:"tw-absolute tw-right-3 tw-top-1/2 tw-h-4 tw-w-4 tw--translate-y-1/2 tw-transform tw-cursor-pointer tw-text-muted-foreground",onClick:()=>{console.log("back in history")}})]}));var Il=Object.defineProperty,Ml=(e,t,n)=>t in e?Il(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,ne=(e,t,n)=>Ml(e,typeof t!="symbol"?t+"":t,n);const gt=["GEN","EXO","LEV","NUM","DEU","JOS","JDG","RUT","1SA","2SA","1KI","2KI","1CH","2CH","EZR","NEH","EST","JOB","PSA","PRO","ECC","SNG","ISA","JER","LAM","EZK","DAN","HOS","JOL","AMO","OBA","JON","MIC","NAM","HAB","ZEP","HAG","ZEC","MAL","MAT","MRK","LUK","JHN","ACT","ROM","1CO","2CO","GAL","EPH","PHP","COL","1TH","2TH","1TI","2TI","TIT","PHM","HEB","JAS","1PE","2PE","1JN","2JN","3JN","JUD","REV","TOB","JDT","ESG","WIS","SIR","BAR","LJE","S3Y","SUS","BEL","1MA","2MA","3MA","4MA","1ES","2ES","MAN","PS2","ODA","PSS","JSA","JDB","TBS","SST","DNT","BLT","XXA","XXB","XXC","XXD","XXE","XXF","XXG","FRT","BAK","OTH","3ES","EZA","5EZ","6EZ","INT","CNC","GLO","TDX","NDX","DAG","PS3","2BA","LBA","JUB","ENO","1MQ","2MQ","3MQ","REP","4BA","LAO"],ao=["XXA","XXB","XXC","XXD","XXE","XXF","XXG","FRT","BAK","OTH","INT","CNC","GLO","TDX","NDX"],rs=["Genesis","Exodus","Leviticus","Numbers","Deuteronomy","Joshua","Judges","Ruth","1 Samuel","2 Samuel","1 Kings","2 Kings","1 Chronicles","2 Chronicles","Ezra","Nehemiah","Esther (Hebrew)","Job","Psalms","Proverbs","Ecclesiastes","Song of Songs","Isaiah","Jeremiah","Lamentations","Ezekiel","Daniel (Hebrew)","Hosea","Joel","Amos","Obadiah","Jonah","Micah","Nahum","Habakkuk","Zephaniah","Haggai","Zechariah","Malachi","Matthew","Mark","Luke","John","Acts","Romans","1 Corinthians","2 Corinthians","Galatians","Ephesians","Philippians","Colossians","1 Thessalonians","2 Thessalonians","1 Timothy","2 Timothy","Titus","Philemon","Hebrews","James","1 Peter","2 Peter","1 John","2 John","3 John","Jude","Revelation","Tobit","Judith","Esther Greek","Wisdom of Solomon","Sirach (Ecclesiasticus)","Baruch","Letter of Jeremiah","Song of 3 Young Men","Susanna","Bel and the Dragon","1 Maccabees","2 Maccabees","3 Maccabees","4 Maccabees","1 Esdras (Greek)","2 Esdras (Latin)","Prayer of Manasseh","Psalm 151","Odes","Psalms of Solomon","Joshua A. *obsolete*","Judges B. *obsolete*","Tobit S. *obsolete*","Susanna Th. *obsolete*","Daniel Th. *obsolete*","Bel Th. *obsolete*","Extra A","Extra B","Extra C","Extra D","Extra E","Extra F","Extra G","Front Matter","Back Matter","Other Matter","3 Ezra *obsolete*","Apocalypse of Ezra","5 Ezra (Latin Prologue)","6 Ezra (Latin Epilogue)","Introduction","Concordance ","Glossary ","Topical Index","Names Index","Daniel Greek","Psalms 152-155","2 Baruch (Apocalypse)","Letter of Baruch","Jubilees","Enoch","1 Meqabyan","2 Meqabyan","3 Meqabyan","Reproof (Proverbs 25-31)","4 Baruch (Rest of Baruch)","Laodiceans"],ra=Ul();function Yt(e,t=!0){return t&&(e=e.toUpperCase()),e in ra?ra[e]:0}function so(e){return Yt(e)>0}function $l(e){const t=typeof e=="string"?Yt(e):e;return t>=40&&t<=66}function Dl(e){return(typeof e=="string"?Yt(e):e)<=39}function os(e){return e<=66}function Al(e){const t=typeof e=="string"?Yt(e):e;return is(t)&&!os(t)}function*Bl(){for(let e=1;e<=gt.length;e++)yield e}const Vl=1,as=gt.length;function zl(){return["XXA","XXB","XXC","XXD","XXE","XXF","XXG"]}function io(e,t="***"){const n=e-1;return n<0||n>=gt.length?t:gt[n]}function ss(e){return e<=0||e>as?"******":rs[e-1]}function Ll(e){return ss(Yt(e))}function is(e){const t=typeof e=="number"?io(e):e;return so(t)&&!ao.includes(t)}function Fl(e){const t=typeof e=="number"?io(e):e;return so(t)&&ao.includes(t)}function Gl(e){return rs[e-1].includes("*obsolete*")}function Ul(){const e={};for(let t=0;t(e[e.Unknown=0]="Unknown",e[e.Original=1]="Original",e[e.Septuagint=2]="Septuagint",e[e.Vulgate=3]="Vulgate",e[e.English=4]="English",e[e.RussianProtestant=5]="RussianProtestant",e[e.RussianOrthodox=6]="RussianOrthodox",e))(He||{});const Pe=class{constructor(t){if(ne(this,"name"),ne(this,"fullPath"),ne(this,"isPresent"),ne(this,"hasVerseSegments"),ne(this,"isCustomized"),ne(this,"baseVersification"),ne(this,"scriptureBooks"),ne(this,"_type"),t==null)throw new Error("Argument undefined");typeof t=="string"?(this.name=t,this._type=He[t]):(this._type=t,this.name=He[t])}get type(){return this._type}equals(t){return!t.type||!this.type?!1:t.type===this.type}};ne(Pe,"Original",new Pe(He.Original)),ne(Pe,"Septuagint",new Pe(He.Septuagint)),ne(Pe,"Vulgate",new Pe(He.Vulgate)),ne(Pe,"English",new Pe(He.English)),ne(Pe,"RussianProtestant",new Pe(He.RussianProtestant)),ne(Pe,"RussianOrthodox",new Pe(He.RussianOrthodox));let ut=Pe;function oa(e,t){const n=t[0];for(let r=1;r(e[e.Valid=0]="Valid",e[e.UnknownVersification=1]="UnknownVersification",e[e.OutOfRange=2]="OutOfRange",e[e.VerseOutOfOrder=3]="VerseOutOfOrder",e[e.VerseRepeated=4]="VerseRepeated",e))(ls||{});const je=class re{constructor(t,n,r,o){if(ne(this,"firstChapter"),ne(this,"lastChapter"),ne(this,"lastVerse"),ne(this,"hasSegmentsDefined"),ne(this,"text"),ne(this,"BBBCCCVVVS"),ne(this,"longHashCode"),ne(this,"versification"),ne(this,"rtlMark","‏"),ne(this,"_bookNum",0),ne(this,"_chapterNum",0),ne(this,"_verseNum",0),ne(this,"_verse"),r==null&&o==null)if(t!=null&&typeof t=="string"){const s=t,i=n!=null&&n instanceof ut?n:void 0;this.setEmpty(i),this.parse(s)}else if(t!=null&&typeof t=="number"){const s=n!=null&&n instanceof ut?n:void 0;this.setEmpty(s),this._verseNum=t%re.chapterDigitShifter,this._chapterNum=Math.floor(t%re.bookDigitShifter/re.chapterDigitShifter),this._bookNum=Math.floor(t/re.bookDigitShifter)}else if(n==null)if(t!=null&&t instanceof re){const s=t;this._bookNum=s.bookNum,this._chapterNum=s.chapterNum,this._verseNum=s.verseNum,this._verse=s.verse,this.versification=s.versification}else{if(t==null)return;const s=t instanceof ut?t:re.defaultVersification;this.setEmpty(s)}else throw new Error("VerseRef constructor not supported.");else if(t!=null&&n!=null&&r!=null)if(typeof t=="string"&&typeof n=="string"&&typeof r=="string")this.setEmpty(o),this.updateInternal(t,n,r);else if(typeof t=="number"&&typeof n=="number"&&typeof r=="number")this._bookNum=t,this._chapterNum=n,this._verseNum=r,this.versification=o??re.defaultVersification;else throw new Error("VerseRef constructor not supported.");else throw new Error("VerseRef constructor not supported.")}static isVerseParseable(t){return t.length>0&&"0123456789".includes(t[0])&&!t.endsWith(this.verseRangeSeparator)&&!t.endsWith(this.verseSequenceIndicator)}static tryParse(t){let n;try{return n=new re(t),{success:!0,verseRef:n}}catch(r){if(r instanceof nn)return n=new re,{success:!1,verseRef:n};throw r}}static getBBBCCCVVV(t,n,r){return t%re.bcvMaxValue*re.bookDigitShifter+(n>=0?n%re.bcvMaxValue*re.chapterDigitShifter:0)+(r>=0?r%re.bcvMaxValue:0)}static fromJSON(t){const{book:n,chapterNum:r,verseNum:o,verse:s,versificationStr:i}=t,l=s||o.toString();let c;return i&&(c=new ut(i)),n?new re(n,r.toString(),l,c):new re}static tryGetVerseNum(t){let n;if(!t)return n=-1,{success:!0,vNum:n};n=0;let r;for(let o=0;o"9")return o===0&&(n=-1),{success:!1,vNum:n};if(n=n*10+ +r-0,n>re.bcvMaxValue)return n=-1,{success:!1,vNum:n}}return{success:!0,vNum:n}}get isDefault(){return this.bookNum===0&&this.chapterNum===0&&this.verseNum===0&&this.versification==null}get hasMultiple(){return this._verse!=null&&(this._verse.includes(re.verseRangeSeparator)||this._verse.includes(re.verseSequenceIndicator))}get book(){return ae.bookNumberToId(this.bookNum,"")}set book(t){this.bookNum=ae.bookIdToNumber(t)}get chapter(){return this.isDefault||this._chapterNum<0?"":this._chapterNum.toString()}set chapter(t){const n=+t;this._chapterNum=Number.isInteger(n)?n:-1}get verse(){return this._verse!=null?this._verse:this.isDefault||this._verseNum<0?"":this._verseNum.toString()}set verse(t){const{success:n,vNum:r}=re.tryGetVerseNum(t);this._verse=n?void 0:t.replace(this.rtlMark,""),this._verseNum=r,!(this._verseNum>=0)&&({vNum:this._verseNum}=re.tryGetVerseNum(this._verse))}get bookNum(){return this._bookNum}set bookNum(t){if(t<=0||t>ae.lastBook)throw new nn("BookNum must be greater than zero and less than or equal to last book");this._bookNum=t}get chapterNum(){return this._chapterNum}set chapterNum(t){this.chapterNum=t}get verseNum(){return this._verseNum}set verseNum(t){this._verseNum=t}get versificationStr(){var t;return(t=this.versification)==null?void 0:t.name}set versificationStr(t){this.versification=this.versification!=null?new ut(t):void 0}get valid(){return this.validStatus===0}get validStatus(){return this.validateVerse(re.verseRangeSeparators,re.verseSequenceIndicators)}get BBBCCC(){return re.getBBBCCCVVV(this._bookNum,this._chapterNum,0)}get BBBCCCVVV(){return re.getBBBCCCVVV(this._bookNum,this._chapterNum,this._verseNum)}get isExcluded(){return!1}parse(t){if(t=t.replace(this.rtlMark,""),t.includes("/")){const s=t.split("/");if(t=s[0],s.length>1)try{const i=+s[1].trim();this.versification=new ut(He[i])}catch{throw new nn("Invalid reference : "+t)}}const n=t.trim().split(" ");if(n.length!==2)throw new nn("Invalid reference : "+t);const r=n[1].split(":"),o=+r[0];if(r.length!==2||ae.bookIdToNumber(n[0])===0||!Number.isInteger(o)||o<0||!re.isVerseParseable(r[1]))throw new nn("Invalid reference : "+t);this.updateInternal(n[0],r[0],r[1])}simplify(){this._verse=void 0}clone(){return new re(this)}toString(){const t=this.book;return t===""?"":`${t} ${this.chapter}:${this.verse}`}toJSON(){let t=this.verse;(t===""||t===this.verseNum.toString())&&(t=void 0);const n={book:this.book,chapterNum:this.chapterNum,verseNum:this.verseNum,verse:t,versificationStr:this.versificationStr};return t||delete n.verse,n}equals(t){return t instanceof re?t._bookNum===this._bookNum&&t._chapterNum===this._chapterNum&&t._verseNum===this._verseNum&&t.verse===this.verse&&(t.versification==null&&this.versification==null||t.versification!=null&&this.versification!=null&&t.versification.equals(this.versification)):!1}allVerses(t=!1,n=re.verseRangeSeparators,r=re.verseSequenceIndicators){if(this._verse==null||this.chapterNum<=0)return[this.clone()];const o=[],s=oa(this._verse,r);for(const i of s.map(l=>oa(l,n))){const l=this.clone();l.verse=i[0];const c=l.verseNum;if(o.push(l),i.length>1){const d=this.clone();if(d.verse=i[1],!t)for(let u=c+1;ui)return 3;if(r===i)return 4;r=i}return 0}get internalValid(){return this.versification==null?1:this._bookNum<=0||this._bookNum>ae.lastBook?2:(ae.isCanonical(this._bookNum),0)}setEmpty(t=re.defaultVersification){this._bookNum=0,this._chapterNum=-1,this._verse=void 0,this.versification=t}updateInternal(t,n,r){this.bookNum=ae.bookIdToNumber(t),this.chapter=n,this.verse=r}};ne(je,"defaultVersification",ut.English),ne(je,"verseRangeSeparator","-"),ne(je,"verseSequenceIndicator",","),ne(je,"verseRangeSeparators",[je.verseRangeSeparator]),ne(je,"verseSequenceIndicators",[je.verseSequenceIndicator]),ne(je,"chapterDigitShifter",1e3),ne(je,"bookDigitShifter",je.chapterDigitShifter*je.chapterDigitShifter),ne(je,"bcvMaxValue",je.chapterDigitShifter-1),ne(je,"ValidStatusType",ls);class nn extends Error{}const or=pe.Root,lo=pe.Trigger,cs=pe.Group,ql=pe.Portal,Hl=pe.Sub,Xl=pe.RadioGroup,ds=g.forwardRef(({className:e,inset:t,children:n,...r},o)=>a.jsxs(pe.SubTrigger,{ref:o,className:N("tw-flex tw-cursor-default tw-select-none tw-items-center tw-rounded-sm tw-px-2 tw-py-1.5 tw-text-sm tw-outline-none focus:tw-bg-accent data-[state=open]:tw-bg-accent",t&&"tw-pl-8",e),...r,children:[n,a.jsx(Q.ChevronRight,{className:"tw-ml-auto tw-h-4 tw-w-4"})]}));ds.displayName=pe.SubTrigger.displayName;const us=g.forwardRef(({className:e,...t},n)=>a.jsx(pe.SubContent,{ref:n,className:N("tw-z-50 tw-min-w-[8rem] tw-overflow-hidden tw-rounded-md tw-border tw-bg-popover tw-p-1 tw-text-popover-foreground tw-shadow-lg data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0 data-[state=closed]:tw-zoom-out-95 data-[state=open]:tw-zoom-in-95 data-[side=bottom]:tw-slide-in-from-top-2 data-[side=left]:tw-slide-in-from-right-2 data-[side=right]:tw-slide-in-from-left-2 data-[side=top]:tw-slide-in-from-bottom-2",e),...t}));us.displayName=pe.SubContent.displayName;const En=g.forwardRef(({className:e,sideOffset:t=4,...n},r)=>a.jsx(pe.Portal,{children:a.jsx(pe.Content,{ref:r,sideOffset:t,className:N("pr-twp tw-z-50 tw-min-w-[8rem] tw-overflow-hidden tw-rounded-md tw-border tw-bg-popover tw-p-1 tw-text-popover-foreground tw-shadow-md data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0 data-[state=closed]:tw-zoom-out-95 data-[state=open]:tw-zoom-in-95 data-[side=bottom]:tw-slide-in-from-top-2 data-[side=left]:tw-slide-in-from-right-2 data-[side=right]:tw-slide-in-from-left-2 data-[side=top]:tw-slide-in-from-bottom-2",e),...n})}));En.displayName=pe.Content.displayName;const co=g.forwardRef(({className:e,inset:t,...n},r)=>a.jsx(pe.Item,{ref:r,className:N("tw-cursor-default tw-select-none tw-items-center tw-rounded-sm tw-px-2 tw-py-1.5 tw-text-sm tw-outline-none tw-transition-colors focus:tw-bg-accent data-[disabled]:tw-pointer-events-none data-[disabled]:tw-opacity-50",t&&"tw-pl-8",e),...n}));co.displayName=pe.Item.displayName;const ar=g.forwardRef(({className:e,children:t,checked:n,...r},o)=>a.jsxs(pe.CheckboxItem,{ref:o,className:N("tw-relative tw-flex tw-cursor-default tw-select-none tw-items-center tw-rounded-sm tw-py-1.5 tw-pl-8 tw-pr-2 tw-text-sm tw-outline-none tw-transition-colors focus:tw-bg-accent focus:tw-text-accent-foreground data-[disabled]:tw-pointer-events-none data-[disabled]:tw-opacity-50",e),checked:n,...r,children:[a.jsx("span",{className:"tw-absolute tw-left-2 tw-flex tw-h-3.5 tw-w-3.5 tw-items-center tw-justify-center",children:a.jsx(pe.ItemIndicator,{children:a.jsx(Q.Check,{className:"tw-h-4 tw-w-4"})})}),t]}));ar.displayName=pe.CheckboxItem.displayName;const uo=g.forwardRef(({className:e,children:t,...n},r)=>a.jsxs(pe.RadioItem,{ref:r,className:N("tw-relative tw-flex tw-cursor-default tw-select-none tw-items-center tw-rounded-sm tw-py-1.5 tw-pl-8 tw-pr-2 tw-text-sm tw-outline-none tw-transition-colors focus:tw-bg-accent focus:tw-text-accent-foreground data-[disabled]:tw-pointer-events-none data-[disabled]:tw-opacity-50",e),...n,children:[a.jsx("span",{className:"tw-absolute tw-left-2 tw-flex tw-h-3.5 tw-w-3.5 tw-items-center tw-justify-center",children:a.jsx(pe.ItemIndicator,{children:a.jsx(Q.Circle,{className:"tw-h-2 tw-w-2 tw-fill-current"})})}),t]}));uo.displayName=pe.RadioItem.displayName;const Wt=g.forwardRef(({className:e,inset:t,...n},r)=>a.jsx(pe.Label,{ref:r,className:N("tw-px-2 tw-py-1.5 tw-text-sm tw-font-semibold",t&&"tw-pl-8",e),...n}));Wt.displayName=pe.Label.displayName;const jn=g.forwardRef(({className:e,...t},n)=>a.jsx(pe.Separator,{ref:n,className:N("tw--mx-1 tw-my-1 tw-h-px tw-bg-muted",e),...t}));jn.displayName=pe.Separator.displayName;function ps({className:e,...t}){return a.jsx("span",{className:N("tw-ml-auto tw-text-xs tw-tracking-widest tw-opacity-60",e),...t})}ps.displayName="DropdownMenuShortcut";const Yl=g.forwardRef(({bookId:e,handleSelectBook:t,isSelected:n,handleHighlightBook:r,handleKeyDown:o,bookType:s,children:i},l)=>a.jsxs(co,{ref:l,textValue:e,className:N("tw-mx-1 tw-px-1 tw-font-normal tw-text-foreground/80",{"tw-bg-amber-50 tw-text-yellow-900 data-[highlighted]:tw-bg-amber-100":n}),onSelect:c=>{c.preventDefault(),t()},onKeyDown:c=>{o(c)},onFocus:r,onMouseMove:r,children:[a.jsx("span",{className:N("tw-border-b-0 tw-border-l-2 tw-border-r-0 tw-border-t-0 tw-border-solid tw-px-2",{"tw-font-bold":n,"tw-border-l-red-200":s.toLowerCase()==="ot","tw-border-l-purple-200":s.toLowerCase()==="nt","tw-border-l-indigo-200":s.toLowerCase()==="dc"}),children:ae.bookIdToEnglishName(e)}),n&&a.jsx("div",{children:i})]},e));function Wl({handleSelectChapter:e,endChapter:t,activeChapter:n,highlightedChapter:r,handleHighlightedChapter:o}){const s=Array.from({length:t},(l,c)=>c+1),i=g.useCallback(l=>{o(l)},[o]);return a.jsx("div",{className:N("tw-flex tw-flex-wrap tw-items-start tw-justify-start tw-self-stretch"),children:s.map(l=>a.jsx("div",{className:N("tw-box-content tw-flex tw-h-4 tw-w-4 tw-cursor-pointer tw-items-center tw-justify-end tw-rounded-md tw-p-2 tw-text-amber-800",{"tw-font-semibold tw-text-amber-900":l===n,"tw-bg-amber-200":l===r}),onClick:c=>{c.preventDefault(),c.stopPropagation(),e(l)},role:"button",onKeyDown:c=>{c.key==="Enter"&&e(l)},tabIndex:0,onMouseMove:()=>i(l),children:l},l))})}function Kl({handleSort:e,handleLocationHistory:t,handleBookmarks:n}){return a.jsxs(Wt,{className:"tw-flex tw-justify-between",children:[a.jsx("p",{className:"tw-inline-block tw-align-middle",children:"Go To"}),a.jsxs("div",{className:"tw-flex tw-items-center",children:[a.jsx(Q.ArrowDownWideNarrow,{onClick:e,className:"tw-m-2 tw-h-4 tw-w-4 tw-cursor-pointer tw-gap-2"}),a.jsx(Q.Clock,{onClick:t,className:"tw-m-2 tw-h-4 tw-w-4 tw-cursor-pointer tw-gap-2"}),a.jsx(Q.Bookmark,{onClick:n,className:"tw-m-2 tw-h-4 tw-w-4 tw-cursor-pointer tw-gap-2"})]})]})}const wn=ae.allBookIds,Jl={OT:"Old Testament",NT:"New Testament",DC:"Deuterocanon"},aa=["OT","NT","DC"],Zl=32+32+32,Ql=[/^(\w+)$/i,/^(\w+)(?:\s(\d+))$/i,/^(\w+)(?:\s(\d+):(\d+))$/i],ec=e=>({OT:wn.filter(n=>ae.isBookOT(n)),NT:wn.filter(n=>ae.isBookNT(n)),DC:wn.filter(n=>ae.isBookDC(n))})[e],rn=e=>W.getChaptersForBook(ae.bookIdToNumber(e));function tc(){return wn.map(t=>ae.bookIdToEnglishName(t))}function nc(e){return tc().includes(e)}function rc(e){const t=e.toLowerCase().replace(/^\w/,n=>n.toUpperCase());if(nc(t))return wn.find(r=>ae.bookIdToEnglishName(r)===t)}function oc({scrRef:e,handleSubmit:t}){const[n,r]=g.useState(""),[o,s]=g.useState(ae.bookNumberToId(e.bookNum)),[i,l]=g.useState(e.chapterNum??0),[c,d]=g.useState(ae.bookNumberToId(e.bookNum)),[u,f]=g.useState(!1),[w,b]=g.useState(u),x=g.useRef(void 0),m=g.useRef(void 0),h=g.useRef(void 0),S=g.useCallback(k=>ec(k).filter(D=>{const $=ae.bookIdToEnglishName(D).toLowerCase(),J=n.replace(/[^a-zA-Z]/g,"").toLowerCase();return $.includes(J)||D.toLowerCase().includes(J)}),[n]),R=k=>{r(k)},j=g.useRef(!1),E=g.useCallback(k=>{if(j.current){j.current=!1;return}f(k)},[]),v=g.useCallback((k,D,$,J)=>{if(l(ae.bookNumberToId(e.bookNum)!==k?1:e.chapterNum),D||rn(k)===-1){t({bookNum:ae.bookIdToNumber(k),chapterNum:$||1,verseNum:J||1}),f(!1),r("");return}s(o!==k?k:""),f(!D)},[t,e.bookNum,e.chapterNum,o]),P=k=>{k<=0||k>rn(o)||v(o,!0,k)},V=g.useCallback(()=>{Ql.forEach(k=>{const D=n.match(k);if(D){const[$,J=void 0,Y=void 0]=D.slice(1),F=rc($);(ae.isBookIdValid($)||F)&&v(F??$,!0,J?parseInt(J,10):1,Y?parseInt(Y,10):1)}})},[v,n]),U=g.useCallback(k=>{u?(k.key==="ArrowDown"||k.key==="ArrowUp")&&(typeof h<"u"&&h.current!==null?h.current.focus():typeof m<"u"&&m.current!==null&&m.current.focus(),k.preventDefault()):f(!0)},[u]),C=k=>{const{key:D}=k;D==="ArrowRight"||D==="ArrowLeft"||D==="ArrowDown"||D==="ArrowUp"||D==="Enter"||(x.current.dispatchEvent(new KeyboardEvent("keydown",{key:D})),x.current.focus())},_=k=>{const{key:D}=k;if(c===o){if(D==="Enter"){k.preventDefault(),v(o,!0,i);return}let $=0;if(D==="ArrowRight")if(i1)$=-1;else{k.preventDefault();return}else D==="ArrowDown"?$=6:D==="ArrowUp"&&($=-6);i+$<=0||i+$>rn(c)?l(0):$!==0&&(l(i+$),k.preventDefault())}};return g.useEffect(()=>{o===c?o===ae.bookNumberToId(e.bookNum)?l(e.chapterNum):l(1):l(0)},[c,e.bookNum,e.chapterNum,o]),g.useLayoutEffect(()=>{b(u)},[u]),g.useLayoutEffect(()=>{const k=setTimeout(()=>{if(w&&m.current&&h.current){const $=h.current.offsetTop-Zl;m.current.scrollTo({top:$,behavior:"instant"})}},10);return()=>{clearTimeout(k)}},[w]),a.jsx("div",{className:"pr-twp tw-flex",children:a.jsxs(or,{modal:!1,open:u,onOpenChange:E,children:[a.jsx(lo,{asChild:!0,children:a.jsx(Pl,{ref:x,value:n,handleSearch:R,handleKeyDown:U,handleOnClick:()=>{s(ae.bookNumberToId(e.bookNum)),d(ae.bookNumberToId(e.bookNum)),l(e.chapterNum>0?e.chapterNum:0),f(!0),x.current.focus()},onFocus:()=>{j.current=!0},handleSubmit:V,placeholder:`${ae.bookNumberToEnglishName(e.bookNum)} ${e.chapterNum}:${e.verseNum}`})}),a.jsxs(En,{className:"tw-m-1 tw-overflow-y-auto tw-p-0 tw-font-normal tw-text-foreground/80",style:{width:"233px",maxHeight:"500px",zIndex:"250"},onKeyDown:C,align:"start",ref:m,children:[a.jsx(Kl,{handleSort:()=>console.log("sorting"),handleLocationHistory:()=>console.log("location history"),handleBookmarks:()=>console.log("bookmarks")}),aa.map((k,D)=>S(k).length>0&&a.jsxs("div",{children:[a.jsx(Wt,{className:"tw-font-semibold tw-text-foreground/80",children:Jl[k]}),S(k).map($=>a.jsx("div",{children:a.jsx(Yl,{bookId:$,handleSelectBook:()=>v($,!1),isSelected:o===$,handleHighlightBook:()=>d($),handleKeyDown:_,bookType:k,ref:J=>{o===$&&(h.current=J)},children:a.jsx(Wl,{handleSelectChapter:P,endChapter:rn($),activeChapter:e.bookNum===ae.bookIdToNumber($)?e.chapterNum:0,highlightedChapter:i,handleHighlightedChapter:J=>{l(J)}})})},$)),aa.length-1!==D?a.jsx(jn,{}):void 0]},k))]})]})})}const ws=Xt.cva("pr-twp tw-inline-flex tw-items-center tw-justify-center tw-whitespace-nowrap tw-rounded-md tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-colors focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50",{variants:{variant:{default:"tw-bg-primary tw-text-primary-foreground hover:tw-bg-primary/90",destructive:"tw-bg-destructive tw-text-destructive-foreground hover:tw-bg-destructive/90",outline:"tw-border tw-border-input tw-bg-background hover:tw-bg-accent hover:tw-text-accent-foreground",secondary:"tw-bg-secondary tw-text-secondary-foreground hover:tw-bg-secondary/80",ghost:"hover:tw-bg-accent hover:tw-text-accent-foreground",link:"tw-text-primary tw-underline-offset-4 hover:tw-underline"},size:{default:"tw-h-10 tw-px-4 tw-py-2",sm:"tw-h-9 tw-rounded-md tw-px-3",lg:"tw-h-11 tw-rounded-md tw-px-8",icon:"tw-h-10 tw-w-10"}},defaultVariants:{variant:"default",size:"default"}}),fe=g.forwardRef(({className:e,variant:t,size:n,asChild:r=!1,...o},s)=>{const i=r?Ht.Slot:"button";return a.jsx(i,{className:N(ws({variant:t,size:n,className:e})),ref:s,...o})});fe.displayName="Button";const ac=Xt.cva("tw-text-sm tw-font-medium tw-leading-none peer-disabled:tw-cursor-not-allowed peer-disabled:tw-opacity-70"),qe=g.forwardRef(({className:e,...t},n)=>a.jsx(es.Root,{ref:n,className:N("pr-twp",ac(),e),...t}));qe.displayName=es.Root.displayName;const po=g.forwardRef(({className:e,...t},n)=>a.jsx(bn.Root,{className:N("pr-twp tw-grid tw-gap-2",e),...t,ref:n}));po.displayName=bn.Root.displayName;const Yn=g.forwardRef(({className:e,...t},n)=>a.jsx(bn.Item,{ref:n,className:N("pr-twp tw-aspect-square tw-h-4 tw-w-4 tw-rounded-full tw-border tw-border-primary tw-text-primary tw-ring-offset-background focus:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-cursor-not-allowed disabled:tw-opacity-50",e),...t,children:a.jsx(bn.Indicator,{className:"tw-flex tw-items-center tw-justify-center",children:a.jsx(Q.Circle,{className:"tw-h-2.5 tw-w-2.5 tw-fill-current tw-text-current"})})}));Yn.displayName=bn.Item.displayName;const sc=vn.Root,ic=vn.Trigger,fs=g.forwardRef(({className:e,align:t="center",sideOffset:n=4,...r},o)=>a.jsx(vn.Portal,{children:a.jsx(vn.Content,{ref:o,align:t,sideOffset:n,className:N("pr-twp tw-z-50 tw-w-72 tw-rounded-md tw-border tw-bg-popover tw-p-4 tw-text-popover-foreground tw-shadow-md tw-outline-none data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0 data-[state=closed]:tw-zoom-out-95 data-[state=open]:tw-zoom-in-95 data-[side=bottom]:tw-slide-in-from-top-2 data-[side=left]:tw-slide-in-from-right-2 data-[side=right]:tw-slide-in-from-left-2 data-[side=top]:tw-slide-in-from-bottom-2",e),...r})}));fs.displayName=vn.Content.displayName;const lc=be.Portal,ms=g.forwardRef(({className:e,...t},n)=>a.jsx(be.Overlay,{ref:n,className:N("tw-fixed tw-inset-0 tw-z-50 tw-bg-black/80 data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0",e),...t}));ms.displayName=be.Overlay.displayName;const cc=g.forwardRef(({className:e,children:t,...n},r)=>a.jsxs(lc,{children:[a.jsx(ms,{}),a.jsxs(be.Content,{ref:r,className:N("tw-fixed tw-left-[50%] tw-top-[50%] tw-z-50 tw-grid tw-w-full tw-max-w-lg tw-translate-x-[-50%] tw-translate-y-[-50%] tw-gap-4 tw-border tw-bg-background tw-p-6 tw-shadow-lg tw-duration-200 data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0 data-[state=closed]:tw-zoom-out-95 data-[state=open]:tw-zoom-in-95 data-[state=closed]:tw-slide-out-to-left-1/2 data-[state=closed]:tw-slide-out-to-top-[48%] data-[state=open]:tw-slide-in-from-left-1/2 data-[state=open]:tw-slide-in-from-top-[48%] sm:tw-rounded-lg",e),...n,children:[t,a.jsxs(be.Close,{className:"tw-absolute tw-right-4 tw-top-4 tw-rounded-sm tw-opacity-70 tw-ring-offset-background tw-transition-opacity hover:tw-opacity-100 focus:tw-outline-none focus:tw-ring-2 focus:tw-ring-ring focus:tw-ring-offset-2 disabled:tw-pointer-events-none data-[state=open]:tw-bg-accent data-[state=open]:tw-text-muted-foreground",children:[a.jsx(Q.X,{className:"tw-h-4 tw-w-4"}),a.jsx("span",{className:"tw-sr-only",children:"Close"})]})]})]}));cc.displayName=be.Content.displayName;const dc=g.forwardRef(({className:e,...t},n)=>a.jsx(be.Title,{ref:n,className:N("tw-text-lg tw-font-semibold tw-leading-none tw-tracking-tight",e),...t}));dc.displayName=be.Title.displayName;const uc=g.forwardRef(({className:e,...t},n)=>a.jsx(be.Description,{ref:n,className:N("tw-text-sm tw-text-muted-foreground",e),...t}));uc.displayName=be.Description.displayName;const hs=g.forwardRef(({className:e,...t},n)=>a.jsx(Re.Command,{ref:n,className:N("tw-flex tw-h-full tw-w-full tw-flex-col tw-overflow-hidden tw-rounded-md tw-bg-popover tw-text-popover-foreground",e),...t}));hs.displayName=Re.Command.displayName;const gs=g.forwardRef(({className:e,...t},n)=>a.jsxs("div",{className:"tw-flex tw-items-center tw-border-b tw-px-3",children:[a.jsx(Q.Search,{className:"tw-me-2 tw-h-4 tw-w-4 tw-shrink-0 tw-opacity-50"}),a.jsx(Re.Command.Input,{ref:n,className:N("tw-flex tw-h-11 tw-w-full tw-rounded-md tw-bg-transparent tw-py-3 tw-text-sm tw-outline-none placeholder:tw-text-muted-foreground disabled:tw-cursor-not-allowed disabled:tw-opacity-50",e),...t})]}));gs.displayName=Re.Command.Input.displayName;const bs=g.forwardRef(({className:e,...t},n)=>a.jsx(Re.Command.List,{ref:n,className:N("tw-max-h-[300px] tw-overflow-y-auto tw-overflow-x-hidden",e),...t}));bs.displayName=Re.Command.List.displayName;const vs=g.forwardRef((e,t)=>a.jsx(Re.Command.Empty,{ref:t,className:"tw-py-6 tw-text-center tw-text-sm",...e}));vs.displayName=Re.Command.Empty.displayName;const pc=g.forwardRef(({className:e,...t},n)=>a.jsx(Re.Command.Group,{ref:n,className:N("tw-overflow-hidden tw-p-1 tw-text-foreground [&_[cmdk-group-heading]]:tw-px-2 [&_[cmdk-group-heading]]:tw-py-1.5 [&_[cmdk-group-heading]]:tw-text-xs [&_[cmdk-group-heading]]:tw-font-medium [&_[cmdk-group-heading]]:tw-text-muted-foreground",e),...t}));pc.displayName=Re.Command.Group.displayName;const wc=g.forwardRef(({className:e,...t},n)=>a.jsx(Re.Command.Separator,{ref:n,className:N("tw--mx-1 tw-h-px tw-bg-border",e),...t}));wc.displayName=Re.Command.Separator.displayName;const xs=g.forwardRef(({className:e,...t},n)=>a.jsx(Re.Command.Item,{ref:n,className:N("tw-relative tw-flex tw-cursor-default tw-select-none tw-items-center tw-rounded-sm tw-px-2 tw-py-1.5 tw-text-sm tw-outline-none data-[disabled=true]:tw-pointer-events-none data-[selected=true]:tw-bg-accent data-[selected=true]:tw-text-accent-foreground data-[disabled=true]:tw-opacity-50",e),...t}));xs.displayName=Re.Command.Item.displayName;function fc(e){return typeof e=="string"?e:typeof e=="number"?e.toString():e.label}function Wn({id:e,options:t=[],buttonClassName:n,popoverContentClassName:r,value:o,onChange:s=()=>{},getOptionLabel:i=fc,buttonPlaceholder:l="",textPlaceholder:c="",commandEmptyMessage:d="No option found",buttonVariant:u="outline",dir:f="ltr",isDisabled:w=!1,...b}){const[x,m]=g.useState(!1);return a.jsxs(sc,{open:x,onOpenChange:m,...b,children:[a.jsx(ic,{asChild:!0,children:a.jsxs(fe,{variant:u,role:"combobox","aria-expanded":x,id:e,className:N("tw-w-[200px] tw-justify-between",n),disabled:w,children:[a.jsx("span",{className:"tw-overflow-hidden tw-text-ellipsis tw-whitespace-nowrap",children:o?i(o):l}),a.jsx(Q.ChevronsUpDown,{className:"tw-ms-2 tw-h-4 tw-w-4 tw-shrink-0 tw-opacity-50"})]})}),a.jsx(fs,{className:N("tw-w-[200px] tw-p-0",r),dir:f,children:a.jsxs(hs,{children:[a.jsx(gs,{dir:f,placeholder:c,className:"tw-text-inherit"}),a.jsx(vs,{children:d}),a.jsx(bs,{children:t.map(h=>a.jsxs(xs,{value:i(h),onSelect:()=>{s(h),m(!1)},children:[a.jsx(Q.Check,{className:N("tw-me-2 tw-h-4 tw-w-4",{"tw-opacity-0":!o||i(o)!==i(h)})}),i(h)]},i(h)))})]})})]})}function ys({startChapter:e,endChapter:t,handleSelectStartChapter:n,handleSelectEndChapter:r,isDisabled:o=!1,chapterCount:s}){const i=g.useMemo(()=>Array.from({length:s},(d,u)=>u+1),[s]),l=d=>{n(d),d>t&&r(d)},c=d=>{r(d),dd.toString(),value:e},"start chapter"),a.jsx(qe,{htmlFor:"end-chapters-combobox",children:"to"}),a.jsx(Wn,{isDisabled:o,onChange:c,buttonClassName:"tw-ml-2 tw-w-20",options:i,getOptionLabel:d=>d.toString(),value:t},"end chapter")]})}var Ns=(e=>(e.CURRENT_BOOK="current book",e.CHOOSE_BOOKS="choose books",e))(Ns||{});const mc=Object.freeze(["%webView_bookSelector_currentBook%","%webView_bookSelector_choose%","%webView_bookSelector_chooseBooks%"]),Tr=(e,t)=>e[t]??t;function hc({handleBookSelectionModeChange:e,currentBookName:t,onSelectBooks:n,selectedBookIds:r,chapterCount:o,endChapter:s,handleSelectEndChapter:i,startChapter:l,handleSelectStartChapter:c,localizedStrings:d}){const u=Tr(d,"%webView_bookSelector_currentBook%"),f=Tr(d,"%webView_bookSelector_choose%"),w=Tr(d,"%webView_bookSelector_chooseBooks%"),[b,x]=g.useState("current book"),m=h=>{x(h),e(h)};return a.jsx(po,{className:"pr-twp tw-flex",value:b,onValueChange:h=>m(h),children:a.jsxs("div",{className:"tw-flex tw-w-full tw-flex-col tw-gap-4",children:[a.jsxs("div",{className:"tw-grid tw-grid-cols-[25%,25%,50%]",children:[a.jsxs("div",{className:"tw-flex tw-items-center",children:[a.jsx(Yn,{value:"current book"}),a.jsx(qe,{className:"tw-ml-1",children:u})]}),a.jsx(qe,{className:"tw-flex tw-items-center",children:t}),a.jsx("div",{className:"tw-flex tw-items-center tw-justify-end",children:a.jsx(ys,{isDisabled:b==="choose books",handleSelectStartChapter:c,handleSelectEndChapter:i,chapterCount:o,startChapter:l,endChapter:s})})]}),a.jsxs("div",{className:"tw-grid tw-grid-cols-[25%,50%,25%]",children:[a.jsxs("div",{className:"tw-flex tw-items-center",children:[a.jsx(Yn,{value:"choose books"}),a.jsx(qe,{className:"tw-ml-1",children:w})]}),a.jsx(qe,{className:"tw-flex tw-items-center",children:r.map(h=>ae.bookIdToEnglishName(h)).join(", ")}),a.jsx(fe,{disabled:b==="current book",onClick:()=>n(),children:f})]})]})})}function gc({table:e}){return a.jsxs(or,{children:[a.jsx(Za.DropdownMenuTrigger,{asChild:!0,children:a.jsxs(fe,{variant:"outline",size:"sm",className:"tw-ml-auto tw-hidden tw-h-8 lg:tw-flex",children:[a.jsx(Q.FilterIcon,{className:"tw-mr-2 tw-h-4 tw-w-4"}),"View"]})}),a.jsxs(En,{align:"end",className:"tw-w-[150px]",children:[a.jsx(Wt,{children:"Toggle columns"}),a.jsx(jn,{}),e.getAllColumns().filter(t=>t.getCanHide()).map(t=>a.jsx(ar,{className:"tw-capitalize",checked:t.getIsVisible(),onCheckedChange:n=>t.toggleVisibility(!!n),children:t.id},t.id))]})]})}const At=ge.Root,ks=ge.Group,Bt=ge.Value,bt=g.forwardRef(({className:e,children:t,...n},r)=>a.jsxs(ge.Trigger,{ref:r,className:N("tw-flex tw-h-10 tw-w-full tw-items-center tw-justify-between tw-rounded-md tw-border tw-border-input tw-bg-background tw-px-3 tw-py-2 tw-text-sm tw-ring-offset-background placeholder:tw-text-muted-foreground focus:tw-outline-none focus:tw-ring-2 focus:tw-ring-ring focus:tw-ring-offset-2 disabled:tw-cursor-not-allowed disabled:tw-opacity-50 [&>span]:tw-line-clamp-1",e),...n,children:[t,a.jsx(ge.Icon,{asChild:!0,children:a.jsx(Q.ChevronDown,{className:"tw-h-4 tw-w-4 tw-opacity-50"})})]}));bt.displayName=ge.Trigger.displayName;const wo=g.forwardRef(({className:e,...t},n)=>a.jsx(ge.ScrollUpButton,{ref:n,className:N("tw-flex tw-cursor-default tw-items-center tw-justify-center tw-py-1",e),...t,children:a.jsx(Q.ChevronUp,{className:"tw-h-4 tw-w-4"})}));wo.displayName=ge.ScrollUpButton.displayName;const fo=g.forwardRef(({className:e,...t},n)=>a.jsx(ge.ScrollDownButton,{ref:n,className:N("tw-flex tw-cursor-default tw-items-center tw-justify-center tw-py-1",e),...t,children:a.jsx(Q.ChevronDown,{className:"tw-h-4 tw-w-4"})}));fo.displayName=ge.ScrollDownButton.displayName;const vt=g.forwardRef(({className:e,children:t,position:n="popper",...r},o)=>a.jsx(ge.Portal,{children:a.jsxs(ge.Content,{ref:o,className:N("pr-twp tw-relative tw-z-50 tw-max-h-96 tw-min-w-[8rem] tw-overflow-hidden tw-rounded-md tw-border tw-bg-popover tw-text-popover-foreground tw-shadow-md data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0 data-[state=closed]:tw-zoom-out-95 data-[state=open]:tw-zoom-in-95 data-[side=bottom]:tw-slide-in-from-top-2 data-[side=left]:tw-slide-in-from-right-2 data-[side=right]:tw-slide-in-from-left-2 data-[side=top]:tw-slide-in-from-bottom-2",n==="popper"&&"data-[side=bottom]:tw-translate-y-1 data-[side=left]:tw--translate-x-1 data-[side=right]:tw-translate-x-1 data-[side=top]:tw--translate-y-1",e),position:n,...r,children:[a.jsx(wo,{}),a.jsx(ge.Viewport,{className:N("tw-p-1",n==="popper"&&"tw-h-[var(--radix-select-trigger-height)] tw-w-full tw-min-w-[var(--radix-select-trigger-width)]"),children:t}),a.jsx(fo,{})]})}));vt.displayName=ge.Content.displayName;const Ss=g.forwardRef(({className:e,...t},n)=>a.jsx(ge.Label,{ref:n,className:N("tw-py-1.5 tw-pl-8 tw-pr-2 tw-text-sm tw-font-semibold",e),...t}));Ss.displayName=ge.Label.displayName;const Ae=g.forwardRef(({className:e,children:t,...n},r)=>a.jsxs(ge.Item,{ref:r,className:N("tw-relative tw-flex tw-w-full tw-cursor-default tw-select-none tw-items-center tw-rounded-sm tw-py-1.5 tw-pl-8 tw-pr-2 tw-text-sm tw-outline-none focus:tw-bg-accent focus:tw-text-accent-foreground data-[disabled]:tw-pointer-events-none data-[disabled]:tw-opacity-50",e),...n,children:[a.jsx("span",{className:"tw-absolute tw-left-2 tw-flex tw-h-3.5 tw-w-3.5 tw-items-center tw-justify-center",children:a.jsx(ge.ItemIndicator,{children:a.jsx(Q.Check,{className:"tw-h-4 tw-w-4"})})}),a.jsx(ge.ItemText,{children:t})]}));Ae.displayName=ge.Item.displayName;const Es=g.forwardRef(({className:e,...t},n)=>a.jsx(ge.Separator,{ref:n,className:N("tw--mx-1 tw-my-1 tw-h-px tw-bg-muted",e),...t}));Es.displayName=ge.Separator.displayName;function bc({table:e}){return a.jsx("div",{className:"tw-flex tw-items-center tw-justify-between tw-px-2 tw-pb-3 tw-pt-3",children:a.jsxs("div",{className:"tw-flex tw-items-center tw-space-x-6 lg:tw-space-x-8",children:[a.jsxs("div",{className:"tw-flex-1 tw-text-sm tw-text-muted-foreground",children:[e.getFilteredSelectedRowModel().rows.length," of"," ",e.getFilteredRowModel().rows.length," row(s) selected"]}),a.jsxs("div",{className:"tw-flex tw-items-center tw-space-x-2",children:[a.jsx("p",{className:"tw-text-nowrap tw-text-sm tw-font-medium",children:"Rows per page"}),a.jsxs(At,{value:`${e.getState().pagination.pageSize}`,onValueChange:t=>{e.setPageSize(Number(t))},children:[a.jsx(bt,{className:"tw-h-8 tw-w-[70px]",children:a.jsx(Bt,{placeholder:e.getState().pagination.pageSize})}),a.jsx(vt,{side:"top",children:[10,20,30,40,50].map(t=>a.jsx(Ae,{value:`${t}`,children:t},t))})]})]}),a.jsxs("div",{className:"tw-flex tw-w-[100px] tw-items-center tw-justify-center tw-text-sm tw-font-medium",children:["Page ",e.getState().pagination.pageIndex+1," of ",e.getPageCount()]}),a.jsxs("div",{className:"tw-flex tw-items-center tw-space-x-2",children:[a.jsxs(fe,{variant:"outline",size:"icon",className:"tw-hidden tw-h-8 tw-w-8 tw-p-0 lg:tw-flex",onClick:()=>e.setPageIndex(0),disabled:!e.getCanPreviousPage(),children:[a.jsx("span",{className:"tw-sr-only",children:"Go to first page"}),a.jsx(Q.ArrowLeftIcon,{className:"tw-h-4 tw-w-4"})]}),a.jsxs(fe,{variant:"outline",size:"icon",className:"tw-h-8 tw-w-8 tw-p-0",onClick:()=>e.previousPage(),disabled:!e.getCanPreviousPage(),children:[a.jsx("span",{className:"tw-sr-only",children:"Go to previous page"}),a.jsx(Q.ChevronLeftIcon,{className:"tw-h-4 tw-w-4"})]}),a.jsxs(fe,{variant:"outline",size:"icon",className:"tw-h-8 tw-w-8 tw-p-0",onClick:()=>e.nextPage(),disabled:!e.getCanNextPage(),children:[a.jsx("span",{className:"tw-sr-only",children:"Go to next page"}),a.jsx(Q.ChevronRightIcon,{className:"tw-h-4 tw-w-4"})]}),a.jsxs(fe,{variant:"outline",size:"icon",className:"tw-hidden tw-h-8 tw-w-8 tw-p-0 lg:tw-flex",onClick:()=>e.setPageIndex(e.getPageCount()-1),disabled:!e.getCanNextPage(),children:[a.jsx("span",{className:"tw-sr-only",children:"Go to last page"}),a.jsx(Q.ArrowRightIcon,{className:"tw-h-4 tw-w-4"})]})]})]})})}const Cn=g.forwardRef(({className:e,stickyHeader:t,...n},r)=>a.jsx("div",{className:N("pr-twp tw-relative tw-w-full",{"tw-overflow-auto":!t}),children:a.jsx("table",{ref:r,className:N("tw-w-full tw-caption-bottom tw-text-sm",e),...n})}));Cn.displayName="Table";const Tn=g.forwardRef(({className:e,stickyHeader:t,...n},r)=>a.jsx("thead",{ref:r,className:N({"tw-sticky tw-top-[-1px] tw-bg-background tw-drop-shadow-sm":t},"[&_tr]:tw-border-b",e),...n}));Tn.displayName="TableHeader";const Rn=g.forwardRef(({className:e,...t},n)=>a.jsx("tbody",{ref:n,className:N("[&_tr:last-child]:tw-border-0",e),...t}));Rn.displayName="TableBody";const js=g.forwardRef(({className:e,...t},n)=>a.jsx("tfoot",{ref:n,className:N("tw-border-t tw-bg-muted/50 tw-font-medium [&>tr]:last:tw-border-b-0",e),...t}));js.displayName="TableFooter";const Ze=g.forwardRef(({className:e,...t},n)=>a.jsx("tr",{ref:n,className:N("tw-border-b tw-transition-colors hover:tw-bg-muted/50 data-[state=selected]:tw-bg-muted",e),...t}));Ze.displayName="TableRow";const Vt=g.forwardRef(({className:e,...t},n)=>a.jsx("th",{ref:n,className:N("tw-h-12 tw-px-4 tw-text-start tw-align-middle tw-font-medium tw-text-muted-foreground [&:has([role=checkbox])]:tw-pe-0",e),...t}));Vt.displayName="TableHead";const xt=g.forwardRef(({className:e,...t},n)=>a.jsx("td",{ref:n,className:N("tw-p-4 tw-align-middle [&:has([role=checkbox])]:tw-pe-0",e),...t}));xt.displayName="TableCell";const Cs=g.forwardRef(({className:e,...t},n)=>a.jsx("caption",{ref:n,className:N("tw-mt-4 tw-text-sm tw-text-muted-foreground",e),...t}));Cs.displayName="TableCaption";function Ts({columns:e,data:t,enablePagination:n=!1,showPaginationControls:r=!1,showColumnVisibilityControls:o=!1,stickyHeader:s=!1,onRowClickHandler:i=()=>{}}){var h;const[l,c]=g.useState([]),[d,u]=g.useState([]),[f,w]=g.useState({}),[b,x]=g.useState({}),m=Se.useReactTable({data:t,columns:e,getCoreRowModel:Se.getCoreRowModel(),...n&&{getPaginationRowModel:Se.getPaginationRowModel()},onSortingChange:c,getSortedRowModel:Se.getSortedRowModel(),onColumnFiltersChange:u,getFilteredRowModel:Se.getFilteredRowModel(),onColumnVisibilityChange:w,onRowSelectionChange:x,state:{sorting:l,columnFilters:d,columnVisibility:f,rowSelection:b}});return a.jsxs("div",{className:"pr-twp",children:[o&&a.jsx(gc,{table:m}),a.jsxs(Cn,{stickyHeader:s,children:[a.jsx(Tn,{stickyHeader:s,children:m.getHeaderGroups().map(S=>a.jsx(Ze,{children:S.headers.map(R=>a.jsx(Vt,{children:R.isPlaceholder?void 0:Se.flexRender(R.column.columnDef.header,R.getContext())},R.id))},S.id))}),a.jsx(Rn,{children:(h=m.getRowModel().rows)!=null&&h.length?m.getRowModel().rows.map(S=>a.jsx(Ze,{onClick:()=>i(S,m),"data-state":S.getIsSelected()&&"selected",children:S.getVisibleCells().map(R=>a.jsx(xt,{children:Se.flexRender(R.column.columnDef.cell,R.getContext())},R.id))},S.id)):a.jsx(Ze,{children:a.jsx(xt,{colSpan:e.length,className:"tw-h-24 tw-text-center",children:"No results."})})})]}),n&&a.jsxs("div",{className:"tw-flex tw-items-center tw-justify-end tw-space-x-2 tw-py-4",children:[a.jsx(fe,{variant:"outline",size:"sm",onClick:()=>m.previousPage(),disabled:!m.getCanPreviousPage(),children:"Previous"}),a.jsx(fe,{variant:"outline",size:"sm",onClick:()=>m.nextPage(),disabled:!m.getCanNextPage(),children:"Next"})]}),n&&r&&a.jsx(bc,{table:m})]})}function vc({occurrenceData:e,setScriptureReference:t,localizedStrings:n}){const r=n["%webView_inventory_occurrences_table_header_reference%"],o=n["%webView_inventory_occurrences_table_header_occurrence%"],s=g.useMemo(()=>{const i=[];return e.forEach(l=>{i.some(c=>W.deepEqual(c,l))||i.push(l)}),i},[e]);return a.jsxs(Cn,{stickyHeader:!0,children:[a.jsx(Tn,{stickyHeader:!0,children:a.jsxs(Ze,{children:[a.jsx(Vt,{children:r}),a.jsx(Vt,{children:o})]})}),a.jsx(Rn,{children:s.length>0&&s.map(i=>a.jsxs(Ze,{onClick:()=>{t(i.reference)},children:[a.jsx(xt,{children:`${ae.bookNumberToEnglishName(i.reference.bookNum)} ${i.reference.chapterNum}:${i.reference.verseNum}`}),a.jsx(xt,{children:i.text})]},`${i.reference.bookNum} ${i.reference.chapterNum}:${i.reference.verseNum}-${i.text}`))})]})}const sr=g.forwardRef(({className:e,...t},n)=>a.jsx(Ur.Root,{ref:n,className:N("tw-peer pr-twp tw-h-4 tw-w-4 tw-shrink-0 tw-rounded-sm tw-border tw-border-primary tw-ring-offset-background focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-cursor-not-allowed disabled:tw-opacity-50 data-[state=checked]:tw-bg-primary data-[state=checked]:tw-text-primary-foreground",e),...t,children:a.jsx(Ur.Indicator,{className:N("tw-flex tw-items-center tw-justify-center tw-text-current"),children:a.jsx(Q.Check,{className:"tw-h-4 tw-w-4"})})}));sr.displayName=Ur.Root.displayName;const Rs=e=>e.split(/(?:\r?\n|\r)|(?=(?:\\(?:v|c|id)))/g),Hr=e=>{const t=/^\\[vc]\s+(\d+)/,n=e.match(t);if(n)return+n[1]},Os=e=>{const t=e.match(/^\\id\s+([A-Za-z]+)/);return t?ae.bookIdToNumber(t[1]):0},_s=(e,t,n)=>n.includes(e)?"unapproved":t.includes(e)?"approved":"unknown",Ps=Xt.cva("pr-twp tw-inline-flex tw-items-center tw-justify-center tw-rounded-md tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-colors hover:tw-bg-muted hover:tw-text-muted-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50 data-[state=on]:tw-bg-accent data-[state=on]:tw-text-accent-foreground",{variants:{variant:{default:"tw-bg-transparent",outline:"tw-border tw-border-input tw-bg-transparent hover:tw-bg-accent hover:tw-text-accent-foreground"},size:{default:"tw-h-10 tw-px-3",sm:"tw-h-9 tw-px-2.5",lg:"tw-h-11 tw-px-5"}},defaultVariants:{variant:"default",size:"default"}}),xc=g.forwardRef(({className:e,variant:t,size:n,...r},o)=>a.jsx(ts.Root,{ref:o,className:N(Ps({variant:t,size:n,className:e})),...r}));xc.displayName=ts.Root.displayName;const Is=g.createContext({size:"default",variant:"default"}),mo=g.forwardRef(({className:e,variant:t,size:n,children:r,...o},s)=>a.jsx(rr.Root,{ref:s,className:N("pr-twp tw-flex tw-items-center tw-justify-center tw-gap-1",e),...o,children:a.jsx(Is.Provider,{value:{variant:t,size:n},children:r})}));mo.displayName=rr.Root.displayName;const fn=g.forwardRef(({className:e,children:t,variant:n,size:r,...o},s)=>{const i=g.useContext(Is);return a.jsx(rr.Item,{ref:s,className:N(Ps({variant:i.variant||n,size:i.size||r}),e),...o,children:t})});fn.displayName=rr.Item.displayName;const ir=e=>e==="asc"?a.jsx(Q.ArrowUpIcon,{className:"tw-ms-2 tw-h-4 tw-w-4"}):e==="desc"?a.jsx(Q.ArrowDownIcon,{className:"tw-ms-2 tw-h-4 tw-w-4"}):a.jsx(Q.ArrowUpDownIcon,{className:"tw-ms-2 tw-h-4 tw-w-4"}),yc=e=>({accessorKey:"item",accessorFn:t=>t.items[0],header:({column:t})=>a.jsxs(fe,{variant:"ghost",onClick:()=>t.toggleSorting(void 0),children:[e,ir(t.getIsSorted())]})}),Nc=(e,t)=>({accessorKey:`item${t}`,accessorFn:n=>n.items[t],header:({column:n})=>a.jsxs(fe,{variant:"ghost",onClick:()=>n.toggleSorting(void 0),children:[e,ir(n.getIsSorted())]})}),kc=e=>({accessorKey:"count",header:({column:t})=>a.jsx("div",{className:"tw-flex tw-justify-end tw-tabular-nums",children:a.jsxs(fe,{variant:"ghost",onClick:()=>t.toggleSorting(void 0),children:[e,ir(t.getIsSorted())]})}),cell:({row:t})=>a.jsx("div",{className:"tw-flex tw-justify-end",children:t.getValue("count")})}),Rr=(e,t,n,r,o,s)=>{let i=[...n];e.forEach(c=>{t==="approved"?i.includes(c)||i.push(c):i=i.filter(d=>d!==c)}),r(i);let l=[...o];e.forEach(c=>{t==="unapproved"?l.includes(c)||l.push(c):l=l.filter(d=>d!==c)}),s(l)},Sc=(e,t,n,r,o)=>({accessorKey:"status",header:({column:s})=>a.jsx("div",{className:"tw-flex tw-justify-center",children:a.jsxs(fe,{variant:"ghost",onClick:()=>s.toggleSorting(void 0),children:[e,ir(s.getIsSorted())]})}),cell:({row:s})=>{const i=s.getValue("status"),l=s.getValue("item");return a.jsxs(mo,{value:i,variant:"outline",type:"single",children:[a.jsx(fn,{onClick:()=>Rr([l],"approved",t,n,r,o),value:"approved",children:a.jsx(Q.CircleCheckIcon,{})}),a.jsx(fn,{onClick:()=>Rr([l],"unapproved",t,n,r,o),value:"unapproved",children:a.jsx(Q.CircleXIcon,{})}),a.jsx(fn,{onClick:()=>Rr([l],"unknown",t,n,r,o),value:"unknown",children:a.jsx(Q.CircleHelpIcon,{})})]})}}),Ec=Object.freeze(["%webView_inventory_all%","%webView_inventory_approved%","%webView_inventory_unapproved%","%webView_inventory_unknown%","%webView_inventory_scope_currentBook%","%webView_inventory_scope_chapter%","%webView_inventory_scope_verse%","%webView_inventory_filter_text%","%webView_inventory_show_additional_items%","%webView_inventory_occurrences_table_header_reference%","%webView_inventory_occurrences_table_header_occurrence%"]),jc=(e,t,n)=>{let r=e;return t!=="all"&&(r=r.filter(o=>t==="approved"&&o.status==="approved"||t==="unapproved"&&o.status==="unapproved"||t==="unknown"&&o.status==="unknown")),n!==""&&(r=r.filter(o=>o.items[0].includes(n))),r},Cc=(e,t,n,r,o)=>{if(!e)return[];const s=[];let i=t.bookNum,l=t.chapterNum,c=t.verseNum;return Rs(e).forEach(u=>{u.startsWith("\\id")&&(i=Os(u),l=0,c=0),u.startsWith("\\c")&&(l=Hr(u),c=0),u.startsWith("\\v")&&(c=Hr(u),l===0&&(l=t.chapterNum));let f=o.exec(u)??void 0;for(;f;){const w=[];f.forEach(h=>w.push(h));const b=f.index,x=s.find(h=>W.deepEqual(h.items,w)),m={reference:{bookNum:i!==void 0?i:-1,chapterNum:l!==void 0?l:-1,verseNum:c!==void 0?c:-1},text:W.substring(u,Math.max(0,b-25),Math.min(b+25,u.length))};if(x)x.count+=1,x.occurrences.push(m);else{const h={items:w,count:1,status:_s(w[0],n,r),occurrences:[m]};s.push(h)}f=o.exec(u)??void 0}}),s},Je=(e,t)=>e[t]??t;function Tc({scriptureReference:e,setScriptureReference:t,localizedStrings:n,extractItems:r,additionalItemsLabels:o,approvedItems:s,unapprovedItems:i,text:l,scope:c,onScopeChange:d,columns:u}){const f=Je(n,"%webView_inventory_all%"),w=Je(n,"%webView_inventory_approved%"),b=Je(n,"%webView_inventory_unapproved%"),x=Je(n,"%webView_inventory_unknown%"),m=Je(n,"%webView_inventory_scope_currentBook%"),h=Je(n,"%webView_inventory_scope_chapter%"),S=Je(n,"%webView_inventory_scope_verse%"),R=Je(n,"%webView_inventory_filter_text%"),j=Je(n,"%webView_inventory_show_additional_items%"),[E,v]=g.useState(!1),[P,V]=g.useState("all"),[U,C]=g.useState(""),[_,k]=g.useState([]),D=g.useMemo(()=>l?r instanceof RegExp?Cc(l,e,s,i,r):r(l,e,s,i):[],[l,r,e,s,i]),$=g.useMemo(()=>{if(E)return D;const y=[];return D.forEach(T=>{const z=T.items[0],L=y.find(B=>B.items[0]===z);L?(L.count+=T.count,L.occurrences=L.occurrences.concat(T.occurrences)):y.push({items:[z],count:T.count,occurrences:T.occurrences,status:T.status})}),y},[E,D]),J=g.useMemo(()=>jc($,P,U),[$,P,U]),Y=g.useMemo(()=>{var z,L;if(!E)return u;const y=(z=o==null?void 0:o.tableHeaders)==null?void 0:z.length;if(!y)return u;const T=[];for(let B=0;B{k([])},[J]);const F=(y,T)=>{T.setRowSelection(()=>{const z={};return z[y.index]=!0,z}),k(y.original.items)},te=y=>{if(y==="book"||y==="chapter"||y==="verse")d(y);else throw new Error(`Invalid scope value: ${y}`)},se=y=>{if(y==="all"||y==="approved"||y==="unapproved"||y==="unknown")V(y);else throw new Error(`Invalid status filter value: ${y}`)},oe=g.useMemo(()=>{if($.length===0||_.length===0)return[];const y=$.filter(T=>W.deepEqual(E?T.items:[T.items[0]],_));if(y.length>1)throw new Error("Selected item is not unique");return y[0].occurrences},[_,E,$]);return a.jsxs("div",{className:"pr-twp tw-flex tw-h-full tw-flex-col",children:[a.jsxs("div",{className:"tw-flex tw-items-stretch",children:[a.jsxs(At,{onValueChange:y=>se(y),defaultValue:P,children:[a.jsx(bt,{className:"tw-m-1",children:a.jsx(Bt,{placeholder:"Select filter"})}),a.jsxs(vt,{children:[a.jsx(Ae,{value:"all",children:f}),a.jsx(Ae,{value:"approved",children:w}),a.jsx(Ae,{value:"unapproved",children:b}),a.jsx(Ae,{value:"unknown",children:x})]})]}),a.jsxs(At,{onValueChange:y=>te(y),defaultValue:c,children:[a.jsx(bt,{className:"tw-m-1",children:a.jsx(Bt,{placeholder:"Select scope"})}),a.jsxs(vt,{children:[a.jsx(Ae,{value:"book",children:m}),a.jsx(Ae,{value:"chapter",children:h}),a.jsx(Ae,{value:"verse",children:S})]})]}),a.jsx(St,{className:"tw-m-1 tw-rounded-md tw-border",placeholder:R,value:U,onChange:y=>{C(y.target.value)}}),o&&a.jsxs("div",{className:"tw-m-1 tw-flex tw-items-center tw-rounded-md tw-border",children:[a.jsx(sr,{className:"tw-m-1",checked:E,onCheckedChange:y=>{k([]),v(y)}}),a.jsx(qe,{className:"tw-m-1 tw-flex-shrink-0 tw-whitespace-nowrap",children:(o==null?void 0:o.checkboxText)??j})]})]}),a.jsx("div",{className:"tw-m-1 tw-flex-1 tw-overflow-auto tw-rounded-md tw-border",children:a.jsx(Ts,{columns:Y,data:J,onRowClickHandler:F,stickyHeader:!0})}),oe.length>0&&a.jsx("div",{className:"tw-m-1 tw-flex-1 tw-overflow-auto tw-rounded-md tw-border",children:a.jsx(vc,{occurrenceData:oe,setScriptureReference:t,localizedStrings:n})})]})}function ho({className:e,onSearch:t,placeholder:n,isFullWidth:r}){const[o,s]=g.useState(""),i=l=>{s(l),t(l)};return a.jsx(St,{className:N("tw-flex tw-h-10 tw-rounded-md tw-border tw-border-input tw-bg-background tw-px-3 tw-py-2 tw-text-sm tw-ring-offset-background file:tw-border-0 file:tw-bg-transparent file:tw-text-sm file:tw-font-medium placeholder:tw-text-muted-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-[color:hsl(240,5%,64.9%)] focus-visible:tw-ring-offset-2 disabled:tw-cursor-not-allowed disabled:tw-opacity-50",{"tw-w-full":r},e),placeholder:n,value:o,onChange:l=>i(l.target.value)})}const go=g.forwardRef(({className:e,...t},n)=>a.jsx(Oe.Root,{orientation:"vertical",ref:n,className:N("tw-flex tw-gap-1 tw-rounded-md tw-text-muted-foreground",e),...t}));go.displayName=Oe.List.displayName;const bo=g.forwardRef(({className:e,...t},n)=>a.jsx(Oe.List,{ref:n,className:N("tw-flex-fit tw-mlk-items-center tw-w-[124px] tw-justify-center tw-rounded-md tw-bg-muted tw-p-1 tw-text-muted-foreground",e),...t}));bo.displayName=Oe.List.displayName;const Ms=g.forwardRef(({className:e,...t},n)=>a.jsx(Oe.Trigger,{ref:n,...t,className:N("overflow-clip tw-inline-flex tw-w-[116px] tw-cursor-pointer tw-items-center tw-justify-center tw-break-words tw-rounded-sm tw-border-0 tw-bg-muted tw-px-3 tw-py-1.5 tw-text-sm tw-font-medium tw-text-inherit tw-ring-offset-background tw-transition-all hover:tw-text-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50 data-[state=active]:tw-bg-background data-[state=active]:tw-text-foreground data-[state=active]:tw-shadow-sm",e)})),vo=g.forwardRef(({className:e,...t},n)=>a.jsx(Oe.Content,{ref:n,className:N("tw-ms-5 tw-flex-grow tw-text-foreground tw-ring-offset-background focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2",e),...t}));vo.displayName=Oe.Content.displayName;function Rc({tabList:e,onSearch:t,searchPlaceholder:n,headerTitle:r,isSearchBarFullWidth:o=!1,direction:s="ltr"}){return a.jsxs("div",{className:"pr-twp",children:[a.jsxs("div",{className:"tw-sticky tw-top-0 tw-space-y-2 tw-pb-2",children:[r?a.jsx("h1",{children:r}):"",a.jsx(ho,{isFullWidth:o,onSearch:t,placeholder:n})]}),a.jsxs(go,{dir:s,children:[a.jsx(bo,{children:e.map(i=>a.jsx(Ms,{value:i.value,children:i.value},i.key))}),e.map(i=>a.jsx(vo,{value:i.value,children:i.content},i.key))]})]})}const lr=g.forwardRef(({className:e,orientation:t="horizontal",decorative:n=!0,...r},o)=>a.jsx(ns.Root,{ref:o,decorative:n,orientation:t,className:N("pr-twp tw-shrink-0 tw-bg-border",t==="horizontal"?"tw-h-[1px] tw-w-full":"tw-h-full tw-w-[1px]",e),...r}));lr.displayName=ns.Root.displayName;const Oc=be.Root,_c=be.Portal,$s=M.forwardRef(({className:e,...t},n)=>a.jsx(be.Overlay,{className:N("tw-fixed tw-inset-0 tw-z-50 tw-bg-black/80 data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0",e),...t,ref:n}));$s.displayName=be.Overlay.displayName;const Pc=Xt.cva("pr-twp tw-fixed tw-z-50 tw-gap-4 tw-bg-background tw-p-6 tw-shadow-lg tw-transition tw-ease-in-out data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-duration-300 data-[state=open]:tw-duration-500",{variants:{side:{top:"tw-inset-x-0 tw-top-0 tw-border-b data-[state=closed]:tw-slide-out-to-top data-[state=open]:tw-slide-in-from-top",bottom:"tw-inset-x-0 tw-bottom-0 tw-border-t data-[state=closed]:tw-slide-out-to-bottom data-[state=open]:tw-slide-in-from-bottom",left:"tw-inset-y-0 tw-left-0 tw-h-full tw-w-3/4 tw-border-r data-[state=closed]:tw-slide-out-to-left data-[state=open]:tw-slide-in-from-left sm:tw-max-w-sm",right:"tw-inset-y-0 tw-right-0 tw-h-full tw-w-3/4 tw- tw-border-l data-[state=closed]:tw-slide-out-to-right data-[state=open]:tw-slide-in-from-right sm:tw-max-w-sm"}},defaultVariants:{side:"right"}}),Ds=M.forwardRef(({side:e="right",className:t,children:n,...r},o)=>a.jsxs(_c,{children:[a.jsx($s,{}),a.jsxs(be.Content,{ref:o,className:N(Pc({side:e}),t),...r,children:[n,a.jsxs(be.Close,{className:"tw-absolute tw-right-4 tw-top-4 tw-rounded-sm tw-opacity-70 tw-ring-offset-background tw-transition-opacity hover:tw-opacity-100 focus:tw-outline-none focus:tw-ring-2 focus:tw-ring-ring focus:tw-ring-offset-2 disabled:tw-pointer-events-none data-[state=open]:tw-bg-secondary",children:[a.jsx(Q.X,{className:"tw-h-4 tw-w-4"}),a.jsx("span",{className:"tw-sr-only",children:"Close"})]})]})]}));Ds.displayName=be.Content.displayName;const Ic=M.forwardRef(({className:e,...t},n)=>a.jsx(be.Title,{ref:n,className:N("tw-text-lg tw-font-semibold tw-text-foreground",e),...t}));Ic.displayName=be.Title.displayName;const Mc=M.forwardRef(({className:e,...t},n)=>a.jsx(be.Description,{ref:n,className:N("tw-text-sm tw-text-muted-foreground",e),...t}));Mc.displayName=be.Description.displayName;function sa({className:e,...t}){return a.jsx("div",{className:N("pr-twp tw-animate-pulse tw-rounded-md tw-bg-muted",e),...t})}const $c=Sn.Provider,Dc=Sn.Root,Ac=Sn.Trigger,As=g.forwardRef(({className:e,sideOffset:t=4,...n},r)=>a.jsx(Sn.Content,{ref:r,sideOffset:t,className:N("pr-twp tw-z-50 tw-overflow-hidden tw-rounded-md tw-border tw-bg-popover tw-px-3 tw-py-1.5 tw-text-sm tw-text-popover-foreground tw-shadow-md tw-animate-in tw-fade-in-0 tw-zoom-in-95 data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=closed]:tw-zoom-out-95 data-[side=bottom]:tw-slide-in-from-top-2 data-[side=left]:tw-slide-in-from-right-2 data-[side=right]:tw-slide-in-from-left-2 data-[side=top]:tw-slide-in-from-bottom-2",e),...n}));As.displayName=Sn.Content.displayName;const Or=768;function Bc(){const[e,t]=g.useState(void 0);return g.useEffect(()=>{const n=window.matchMedia(`(max-width: ${Or-1}px)`),r=()=>{t(window.innerWidthn.removeEventListener("change",r)},[]),!!e}const Vc="sidebar:state",zc=60*60*24*7,Lc="16rem",Fc="18rem",Gc="3rem",Uc="b",Bs=g.createContext(void 0);function cr(){const e=g.useContext(Bs);if(!e)throw new Error("useSidebar must be used within a SidebarProvider.");return e}const Vs=g.forwardRef(({defaultOpen:e=!0,open:t,onOpenChange:n,className:r,style:o,children:s,...i},l)=>{const c=Bc(),[d,u]=g.useState(!1),[f,w]=g.useState(e),b=t??f,x=g.useCallback(R=>{const j=typeof R=="function"?R(b):R;n?n(j):w(j),document.cookie=`${Vc}=${j}; path=/; max-age=${zc}`},[n,b]),m=g.useCallback(()=>c?u(R=>!R):x(R=>!R),[c,x,u]);g.useEffect(()=>{const R=j=>{j.key===Uc&&(j.metaKey||j.ctrlKey)&&(j.preventDefault(),m())};return window.addEventListener("keydown",R),()=>window.removeEventListener("keydown",R)},[m]);const h=b?"expanded":"collapsed",S=g.useMemo(()=>({state:h,open:b,setOpen:x,isMobile:c,openMobile:d,setOpenMobile:u,toggleSidebar:m}),[h,b,x,c,d,u,m]);return a.jsx(Bs.Provider,{value:S,children:a.jsx($c,{delayDuration:0,children:a.jsx("div",{style:{"--sidebar-width":Lc,"--sidebar-width-icon":Gc,...o},className:N("tw-group/sidebar-wrapper pr-twp tw-flex tw-w-full has-[[data-variant=inset]]:tw-bg-sidebar",r),ref:l,...i,children:s})})})});Vs.displayName="SidebarProvider";const zs=g.forwardRef(({side:e="left",variant:t="sidebar",collapsible:n="offcanvas",className:r,children:o,...s},i)=>{const{isMobile:l,state:c,openMobile:d,setOpenMobile:u}=cr();return n==="none"?a.jsx("div",{className:N("tw-flex tw-h-full tw-w-[--sidebar-width] tw-flex-col tw-bg-sidebar tw-text-sidebar-foreground",r),ref:i,...s,children:o}):l?a.jsx(Oc,{open:d,onOpenChange:u,...s,children:a.jsx(Ds,{"data-sidebar":"sidebar","data-mobile":"true",className:"tw-w-[--sidebar-width] tw-bg-sidebar tw-p-0 tw-text-sidebar-foreground [&>button]:tw-hidden",style:{"--sidebar-width":Fc},side:e,children:a.jsx("div",{className:"tw-flex tw-h-full tw-w-full tw-flex-col",children:o})})}):a.jsxs("div",{ref:i,className:"tw-group tw-peer tw-hidden tw-text-sidebar-foreground md:tw-block","data-state":c,"data-collapsible":c==="collapsed"?n:"","data-variant":t,"data-side":e,children:[a.jsx("div",{className:N("tw-relative tw-h-svh tw-w-[--sidebar-width] tw-bg-transparent tw-transition-[width] tw-duration-200 tw-ease-linear","group-data-[collapsible=offcanvas]:tw-w-0","group-data-[side=right]:tw-rotate-180",t==="floating"||t==="inset"?"group-data-[collapsible=icon]:tw-w-[calc(var(--sidebar-width-icon)_+_theme(spacing.4))]":"group-data-[collapsible=icon]:tw-w-[--sidebar-width-icon]")}),a.jsx("div",{className:N("tw-absolute tw-inset-y-0 tw-z-10 tw-hidden tw-h-svh tw-w-[--sidebar-width] tw-transition-[left,right,width] tw-duration-200 tw-ease-linear md:tw-flex",e==="left"?"tw-left-0 group-data-[collapsible=offcanvas]:tw-left-[calc(var(--sidebar-width)*-1)]":"tw-right-0 group-data-[collapsible=offcanvas]:tw-right-[calc(var(--sidebar-width)*-1)]",t==="floating"||t==="inset"?"tw-p-2 group-data-[collapsible=icon]:tw-w-[calc(var(--sidebar-width-icon)_+_theme(spacing.4)_+2px)]":"group-data-[collapsible=icon]:tw-w-[--sidebar-width-icon] group-data-[side=left]:tw-border-r group-data-[side=right]:tw-border-l",r),...s,children:a.jsx("div",{"data-sidebar":"sidebar",className:"tw-flex tw-h-full tw-w-full tw-flex-col tw-bg-sidebar group-data-[variant=floating]:tw-rounded-lg group-data-[variant=floating]:tw-border group-data-[variant=floating]:tw-border-sidebar-border group-data-[variant=floating]:tw-shadow",children:o})})]})});zs.displayName="Sidebar";const qc=g.forwardRef(({className:e,onClick:t,...n},r)=>{const{toggleSidebar:o}=cr();return a.jsxs(fe,{ref:r,"data-sidebar":"trigger",variant:"ghost",size:"icon",className:N("tw-h-7 tw-w-7",e),onClick:s=>{t==null||t(s),o()},...n,children:[a.jsx(Q.PanelLeft,{}),a.jsx("span",{className:"tw-sr-only",children:"Toggle Sidebar"})]})});qc.displayName="SidebarTrigger";const Hc=g.forwardRef(({className:e,...t},n)=>{const{toggleSidebar:r}=cr();return a.jsx("button",{type:"button",ref:n,"data-sidebar":"rail","aria-label":"Toggle Sidebar",tabIndex:-1,onClick:r,title:"Toggle Sidebar",className:N("tw-absolute tw-inset-y-0 tw-z-20 tw-hidden tw-w-4 tw--translate-x-1/2 tw-transition-all tw-ease-linear after:tw-absolute after:tw-inset-y-0 after:tw-left-1/2 after:tw-w-[2px] hover:after:tw-bg-sidebar-border group-data-[side=left]:tw--right-4 group-data-[side=right]:tw-left-0 sm:tw-flex","[[data-side=left]_&]:tw-cursor-w-resize [[data-side=right]_&]:tw-cursor-e-resize","[[data-side=left][data-state=collapsed]_&]:tw-cursor-e-resize [[data-side=right][data-state=collapsed]_&]:tw-cursor-w-resize","group-data-[collapsible=offcanvas]:tw-translate-x-0 group-data-[collapsible=offcanvas]:after:tw-left-full group-data-[collapsible=offcanvas]:hover:tw-bg-sidebar","[[data-side=left][data-collapsible=offcanvas]_&]:tw--right-2","[[data-side=right][data-collapsible=offcanvas]_&]:tw--left-2",e),...t})});Hc.displayName="SidebarRail";const Ls=g.forwardRef(({className:e,...t},n)=>a.jsx("main",{ref:n,className:N("tw-relative tw-flex tw-flex-1 tw-flex-col tw-bg-background","peer-data-[variant=inset]:tw-min-h-[calc(100svh-theme(spacing.4))] md:peer-data-[variant=inset]:tw-m-2 md:peer-data-[state=collapsed]:peer-data-[variant=inset]:tw-ml-2 md:peer-data-[variant=inset]:tw-ml-0 md:peer-data-[variant=inset]:tw-rounded-xl md:peer-data-[variant=inset]:tw-shadow",e),...t}));Ls.displayName="SidebarInset";const Xc=g.forwardRef(({className:e,...t},n)=>a.jsx(St,{ref:n,"data-sidebar":"input",className:N("tw-h-8 tw-w-full tw-bg-background tw-shadow-none focus-visible:tw-ring-2 focus-visible:tw-ring-sidebar-ring",e),...t}));Xc.displayName="SidebarInput";const Yc=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,"data-sidebar":"header",className:N("tw-flex tw-flex-col tw-gap-2 tw-p-2",e),...t}));Yc.displayName="SidebarHeader";const Wc=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,"data-sidebar":"footer",className:N("tw-flex tw-flex-col tw-gap-2 tw-p-2",e),...t}));Wc.displayName="SidebarFooter";const Kc=g.forwardRef(({className:e,...t},n)=>a.jsx(lr,{ref:n,"data-sidebar":"separator",className:N("tw-mx-2 tw-w-auto tw-bg-sidebar-border",e),...t}));Kc.displayName="SidebarSeparator";const Fs=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,"data-sidebar":"content",className:N("tw-flex tw-min-h-0 tw-flex-1 tw-flex-col tw-gap-2 tw-overflow-auto group-data-[collapsible=icon]:tw-overflow-hidden",e),...t}));Fs.displayName="SidebarContent";const Xr=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,"data-sidebar":"group",className:N("tw-relative tw-flex tw-w-full tw-min-w-0 tw-flex-col tw-p-2",e),...t}));Xr.displayName="SidebarGroup";const Yr=g.forwardRef(({className:e,asChild:t=!1,...n},r)=>{const o=t?Ht.Slot:"div";return a.jsx(o,{ref:r,"data-sidebar":"group-label",className:N("tw-flex tw-h-8 tw-shrink-0 tw-items-center tw-rounded-md tw-px-2 tw-text-xs tw-font-medium tw-text-sidebar-foreground/70 tw-outline-none tw-ring-sidebar-ring tw-transition-[margin,opa] tw-duration-200 tw-ease-linear focus-visible:tw-ring-2 [&>svg]:tw-size-4 [&>svg]:tw-shrink-0","group-data-[collapsible=icon]:tw--mt-8 group-data-[collapsible=icon]:tw-opacity-0",e),...n})});Yr.displayName="SidebarGroupLabel";const Jc=g.forwardRef(({className:e,asChild:t=!1,...n},r)=>{const o=t?Ht.Slot:"button";return a.jsx(o,{ref:r,"data-sidebar":"group-action",className:N("tw-absolute tw-right-3 tw-top-3.5 tw-flex tw-aspect-square tw-w-5 tw-items-center tw-justify-center tw-rounded-md tw-p-0 tw-text-sidebar-foreground tw-outline-none tw-ring-sidebar-ring tw-transition-transform hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground focus-visible:tw-ring-2 [&>svg]:tw-size-4 [&>svg]:tw-shrink-0","after:tw-absolute after:tw--inset-2 after:md:tw-hidden","group-data-[collapsible=icon]:tw-hidden",e),...n})});Jc.displayName="SidebarGroupAction";const Wr=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,"data-sidebar":"group-content",className:N("tw-w-full tw-text-sm",e),...t}));Wr.displayName="SidebarGroupContent";const Gs=g.forwardRef(({className:e,...t},n)=>a.jsx("ul",{ref:n,"data-sidebar":"menu",className:N("tw-flex tw-w-full tw-min-w-0 tw-flex-col tw-gap-1",e),...t}));Gs.displayName="SidebarMenu";const Us=g.forwardRef(({className:e,...t},n)=>a.jsx("li",{ref:n,"data-sidebar":"menu-item",className:N("tw-group/menu-item tw-relative",e),...t}));Us.displayName="SidebarMenuItem";const Zc=Xt.cva("tw-peer/menu-button tw-flex tw-w-full tw-items-center tw-gap-2 tw-overflow-hidden tw-rounded-md tw-p-2 tw-text-left tw-text-sm tw-outline-none tw-ring-sidebar-ring tw-transition-[width,height,padding] hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground focus-visible:tw-ring-2 active:tw-bg-sidebar-accent active:tw-text-sidebar-accent-foreground disabled:tw-pointer-events-none disabled:tw-opacity-50 tw-group-has-[[data-sidebar=menu-action]]/menu-item:pr-8 aria-disabled:tw-pointer-events-none aria-disabled:tw-opacity-50 data-[active=true]:tw-font-medium data-[active=true]:tw-text-sidebar-accent-foreground data-[state=open]:hover:tw-bg-sidebar-accent data-[state=open]:hover:tw-text-sidebar-accent-foreground group-data-[collapsible=icon]:tw-!size-8 group-data-[collapsible=icon]:tw-!p-2 [&>span:last-child]:tw-truncate [&>svg]:tw-size-4 [&>svg]:tw-shrink-0",{variants:{variant:{default:"hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground",outline:"tw-bg-background tw-shadow-[0_0_0_1px_hsl(var(--sidebar-border))] hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground hover:tw-shadow-[0_0_0_1px_hsl(var(--sidebar-accent))]"},size:{default:"tw-h-8 tw-text-sm",sm:"tw-h-7 tw-text-xs",lg:"tw-h-12 tw-text-sm group-data-[collapsible=icon]:tw-!p-0"}},defaultVariants:{variant:"default",size:"default"}}),qs=g.forwardRef(({asChild:e=!1,isActive:t=!1,variant:n="default",size:r="default",tooltip:o,className:s,...i},l)=>{const c=e?Ht.Slot:"button",{isMobile:d,state:u}=cr(),f=a.jsx(c,{ref:l,"data-sidebar":"menu-button","data-size":r,"data-active":t,className:N(Zc({variant:n,size:r}),s),...i});return o?(typeof o=="string"&&(o={children:o}),a.jsxs(Dc,{children:[a.jsx(Ac,{asChild:!0,children:f}),a.jsx(As,{side:"right",align:"center",hidden:u!=="collapsed"||d,...o})]})):f});qs.displayName="SidebarMenuButton";const Qc=g.forwardRef(({className:e,asChild:t=!1,showOnHover:n=!1,...r},o)=>{const s=t?Ht.Slot:"button";return a.jsx(s,{ref:o,"data-sidebar":"menu-action",className:N("tw-peer-hover/menu-button:text-sidebar-accent-foreground tw-absolute tw-right-1 tw-top-1.5 tw-flex tw-aspect-square tw-w-5 tw-items-center tw-justify-center tw-rounded-md tw-p-0 tw-text-sidebar-foreground tw-outline-none tw-ring-sidebar-ring tw-transition-transform hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground focus-visible:tw-ring-2 [&>svg]:tw-size-4 [&>svg]:tw-shrink-0","after:tw-absolute after:tw--inset-2 after:md:tw-hidden","tw-peer-data-[size=sm]/menu-button:top-1","tw-peer-data-[size=default]/menu-button:top-1.5","tw-peer-data-[size=lg]/menu-button:top-2.5","group-data-[collapsible=icon]:tw-hidden",n&&"tw-group-focus-within/menu-item:opacity-100 tw-group-hover/menu-item:opacity-100 tw-peer-data-[active=true]/menu-button:text-sidebar-accent-foreground data-[state=open]:tw-opacity-100 md:tw-opacity-0",e),...r})});Qc.displayName="SidebarMenuAction";const ed=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,"data-sidebar":"menu-badge",className:N("tw-pointer-events-none tw-absolute tw-right-1 tw-flex tw-h-5 tw-min-w-5 tw-select-none tw-items-center tw-justify-center tw-rounded-md tw-px-1 tw-text-xs tw-font-medium tw-tabular-nums tw-text-sidebar-foreground","tw-peer-hover/menu-button:text-sidebar-accent-foreground tw-peer-data-[active=true]/menu-button:text-sidebar-accent-foreground","tw-peer-data-[size=sm]/menu-button:top-1","tw-peer-data-[size=default]/menu-button:top-1.5","tw-peer-data-[size=lg]/menu-button:top-2.5","group-data-[collapsible=icon]:tw-hidden",e),...t}));ed.displayName="SidebarMenuBadge";const td=g.forwardRef(({className:e,showIcon:t=!1,...n},r)=>{const o=g.useMemo(()=>`${Math.floor(Math.random()*40)+50}%`,[]);return a.jsxs("div",{ref:r,"data-sidebar":"menu-skeleton",className:N("tw-flex tw-h-8 tw-items-center tw-gap-2 tw-rounded-md tw-px-2",e),...n,children:[t&&a.jsx(sa,{className:"tw-size-4 tw-rounded-md","data-sidebar":"menu-skeleton-icon"}),a.jsx(sa,{className:"tw-h-4 tw-max-w-[--skeleton-width] tw-flex-1","data-sidebar":"menu-skeleton-text",style:{"--skeleton-width":o}})]})});td.displayName="SidebarMenuSkeleton";const nd=g.forwardRef(({className:e,...t},n)=>a.jsx("ul",{ref:n,"data-sidebar":"menu-sub",className:N("tw-mx-3.5 tw-flex tw-min-w-0 tw-translate-x-px tw-flex-col tw-gap-1 tw-border-l tw-border-sidebar-border tw-px-2.5 tw-py-0.5","group-data-[collapsible=icon]:tw-hidden",e),...t}));nd.displayName="SidebarMenuSub";const rd=g.forwardRef(({...e},t)=>a.jsx("li",{ref:t,...e}));rd.displayName="SidebarMenuSubItem";const od=g.forwardRef(({asChild:e=!1,size:t="md",isActive:n,className:r,...o},s)=>{const i=e?Ht.Slot:"a";return a.jsx(i,{ref:s,"data-sidebar":"menu-sub-button","data-size":t,"data-active":n,className:N("tw-flex tw-h-7 tw-min-w-0 tw--translate-x-px tw-items-center tw-gap-2 tw-overflow-hidden tw-rounded-md tw-px-2 tw-text-sidebar-foreground tw-outline-none tw-ring-sidebar-ring hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground focus-visible:tw-ring-2 active:tw-bg-sidebar-accent active:tw-text-sidebar-accent-foreground disabled:tw-pointer-events-none disabled:tw-opacity-50 aria-disabled:tw-pointer-events-none aria-disabled:tw-opacity-50 [&>span:last-child]:tw-truncate [&>svg]:tw-size-4 [&>svg]:tw-shrink-0 [&>svg]:tw-text-sidebar-accent-foreground","data-[active=true]:tw-bg-sidebar-accent data-[active=true]:tw-text-sidebar-accent-foreground",t==="sm"&&"tw-text-xs",t==="md"&&"tw-text-sm","group-data-[collapsible=icon]:tw-hidden",r),...o})});od.displayName="SidebarMenuSubButton";function Hs({id:e,extensionLabels:t,projectOptions:n,handleSelectSidebarItem:r,selectedSidebarItem:o,extensionsSidebarGroupLabel:s,projectsSidebarGroupLabel:i,buttonPlaceholderText:l}){const c=g.useCallback((f,w)=>{r(f,w)},[r]),d=g.useCallback(f=>{const w=n.find(b=>b.projectId===f);return w?w.projectName:f},[n]),u=g.useCallback(f=>!o.projectId&&f===o.label,[o]);return a.jsx(zs,{id:e,collapsible:"none",variant:"inset",className:"tw-w-96 tw-gap-2 tw-overflow-y-auto tw-rounded tw-bg-slate-100",children:a.jsxs(Fs,{children:[a.jsxs(Xr,{children:[a.jsx(Yr,{className:"tw-text-sm tw-text-gray-400",children:s}),a.jsx(Wr,{children:a.jsx(Gs,{children:t.map(f=>a.jsx(Us,{children:a.jsx(qs,{className:N("tw-rounded tw-py-2 tw-text-sm tw-text-gray-500 hover:tw-bg-white hover:tw-text-gray-900 hover:tw-shadow-sm active:tw-bg-white",{"tw-bg-white tw-text-gray-900 tw-shadow-sm":u(f)}),onClick:()=>c(f),isActive:u(f),children:a.jsx("span",{className:"tw-pl-3",children:f})})},f))})})]}),a.jsxs(Xr,{children:[a.jsx(Yr,{className:"tw-text-sm tw-text-gray-400",children:i}),a.jsx(Wr,{className:"tw-pl-3",children:a.jsx(Wn,{popoverContentClassName:"tw-z-[1000]",options:n.flatMap(f=>f.projectId),getOptionLabel:f=>d(f),buttonPlaceholder:l,onChange:f=>{const w=d(f);c(w,f)},value:(o==null?void 0:o.projectId)??void 0})})]})]})})}function ad({id:e,extensionLabels:t,projectOptions:n,children:r,handleSelectSidebarItem:o,selectedSidebarItem:s,onSearch:i,extensionsSidebarGroupLabel:l,projectsSidebarGroupLabel:c,buttonPlaceholderText:d}){return a.jsxs("div",{className:"tw-box-border tw-flex tw-h-full tw-flex-col tw-p-3",children:[a.jsx("div",{className:"tw-box-border tw-flex tw-items-center tw-justify-center tw-py-4",children:a.jsx(ho,{className:"tw-w-9/12",onSearch:i,placeholder:"Search app settings, extension settings, and project settings"})}),a.jsxs(Vs,{id:e,className:"tw-h-full tw-flex-1 tw-gap-4 tw-overflow-auto",children:[a.jsx(Hs,{extensionLabels:t,projectOptions:n,handleSelectSidebarItem:o,selectedSidebarItem:s,extensionsSidebarGroupLabel:l,projectsSidebarGroupLabel:c,buttonPlaceholderText:d}),a.jsx(Ls,{className:"tw-overflow-y-auto",children:r})]})]})}const rt="scrBook",sd="scrRef",pt="source",id="details",ld="Scripture Reference",cd="Scripture Book",Xs="Type",dd="Details";function ud(e,t){const n=t??!1;return[{accessorFn:r=>`${ae.bookNumberToId(r.start.bookNum)} ${r.start.chapterNum}:${r.start.verseNum}`,id:rt,header:(e==null?void 0:e.scriptureReferenceColumnName)??ld,cell:r=>{const o=r.row.original;return r.row.getIsGrouped()?ae.bookNumberToEnglishName(o.start.bookNum):r.row.groupingColumnId===rt?W.formatScrRef(o.start):void 0},getGroupingValue:r=>r.start.bookNum,sortingFn:(r,o)=>W.compareScrRefs(r.original.start,o.original.start),enableGrouping:!0},{accessorFn:r=>W.formatScrRef(r.start),id:sd,header:void 0,cell:r=>{const o=r.row.original;return r.row.getIsGrouped()?void 0:W.formatScrRef(o.start)},sortingFn:(r,o)=>W.compareScrRefs(r.original.start,o.original.start),enableGrouping:!1},{accessorFn:r=>r.source.displayName,id:pt,header:n?(e==null?void 0:e.typeColumnName)??Xs:void 0,cell:r=>n||r.row.getIsGrouped()?r.getValue():void 0,getGroupingValue:r=>r.source.id,sortingFn:(r,o)=>r.original.source.displayName.localeCompare(o.original.source.displayName),enableGrouping:!0},{accessorFn:r=>r.detail,id,header:(e==null?void 0:e.detailsColumnName)??dd,cell:r=>r.getValue(),enableGrouping:!1}]}const pd=e=>{if(!("offset"in e.start))throw new Error("No offset available in range start");if(e.end&&!("offset"in e.end))throw new Error("No offset available in range end");const{offset:t}=e.start;let n=0;return e.end&&({offset:n}=e.end),!e.end||W.compareScrRefs(e.start,e.end)===0?`${W.scrRefToBBBCCCVVV(e.start)}+${t}`:`${W.scrRefToBBBCCCVVV(e.start)}+${t}-${W.scrRefToBBBCCCVVV(e.end)}+${n}`},ia=e=>`${pd({start:e.start,end:e.end})} ${e.source.displayName} ${e.detail}`;function wd({sources:e,showColumnHeaders:t=!1,showSourceColumn:n=!1,scriptureReferenceColumnName:r,scriptureBookGroupName:o,typeColumnName:s,detailsColumnName:i,onRowSelected:l,direction:c="ltr"}){const[d,u]=g.useState([]),[f,w]=g.useState([{id:rt,desc:!1}]),[b,x]=g.useState({}),m=g.useMemo(()=>e.flatMap(C=>C.data.map(_=>({..._,source:C.source}))),[e]),h=g.useMemo(()=>ud({scriptureReferenceColumnName:r,typeColumnName:s,detailsColumnName:i},n),[r,s,i,n]);g.useEffect(()=>{d.includes(pt)?w([{id:pt,desc:!1},{id:rt,desc:!1}]):w([{id:rt,desc:!1}])},[d]);const S=Se.useReactTable({data:m,columns:h,state:{grouping:d,sorting:f,rowSelection:b},onGroupingChange:u,onSortingChange:w,onRowSelectionChange:x,getExpandedRowModel:Se.getExpandedRowModel(),getGroupedRowModel:Se.getGroupedRowModel(),getCoreRowModel:Se.getCoreRowModel(),getSortedRowModel:Se.getSortedRowModel(),getRowId:ia,autoResetExpanded:!1,enableMultiRowSelection:!1,enableSubRowSelection:!1});g.useEffect(()=>{if(l){const C=S.getSelectedRowModel().rowsById,_=Object.keys(C);if(_.length===1){const k=m.find(D=>ia(D)===_[0])||void 0;k&&l(k)}}},[b,m,l,S]);const R=o??cd,j=s??Xs,E=[{label:"No Grouping",value:[]},{label:`Group by ${R}`,value:[rt]},{label:`Group by ${j}`,value:[pt]},{label:`Group by ${R} and ${j}`,value:[rt,pt]},{label:`Group by ${j} and ${R}`,value:[pt,rt]}],v=C=>{u(JSON.parse(C))},P=(C,_)=>{!C.getIsGrouped()&&!C.getIsSelected()&&C.getToggleSelectedHandler()(_)},V=(C,_)=>C.getIsGrouped()?"":N("banded-row",_%2===0?"even":"odd"),U=(C,_,k)=>{if(!((C==null?void 0:C.length)===0||_.depth{v(C)},children:[a.jsx(bt,{className:"tw-mb-1 tw-mt-2",children:a.jsx(Bt,{})}),a.jsx(vt,{position:"item-aligned",children:a.jsx(ks,{children:E.map(C=>a.jsx(Ae,{value:JSON.stringify(C.value),children:C.label},C.label))})})]}),a.jsxs(Cn,{className:"tw-relative tw-flex tw-flex-col tw-overflow-y-auto tw-p-0",children:[t&&a.jsx(Tn,{children:S.getHeaderGroups().map(C=>a.jsx(Ze,{children:C.headers.filter(_=>_.column.columnDef.header).map(_=>a.jsx(Vt,{colSpan:_.colSpan,className:"top-0 tw-sticky",children:_.isPlaceholder?void 0:a.jsxs("div",{children:[_.column.getCanGroup()?a.jsx(fe,{variant:"ghost",title:`Toggle grouping by ${_.column.columnDef.header}`,onClick:_.column.getToggleGroupingHandler(),type:"button",children:_.column.getIsGrouped()?"🛑":"👊 "}):void 0," ",Se.flexRender(_.column.columnDef.header,_.getContext())]})},_.id))},C.id))}),a.jsx(Rn,{children:S.getRowModel().rows.map((C,_)=>a.jsx(Ze,{"data-state":C.getIsSelected()?"selected":"",className:N(V(C,_)),onClick:k=>P(C,k),children:C.getVisibleCells().map(k=>{if(!(k.getIsPlaceholder()||k.column.columnDef.enableGrouping&&!k.getIsGrouped()&&(k.column.columnDef.id!==pt||!n)))return a.jsx(xt,{className:N(k.column.columnDef.id,"tw-p-[1px]",U(d,C,k)),children:(()=>k.getIsGrouped()?a.jsxs(fe,{variant:"link",onClick:C.getToggleExpandedHandler(),type:"button",children:[C.getIsExpanded()&&a.jsx(Q.ChevronDown,{}),!C.getIsExpanded()&&(c==="ltr"?a.jsx(Q.ChevronRight,{}):a.jsx(Q.ChevronLeft,{}))," ",Se.flexRender(k.column.columnDef.cell,k.getContext())," (",C.subRows.length,")"]}):Se.flexRender(k.column.columnDef.cell,k.getContext()))()},k.id)})},C.id))})]})]})}const _r={[W.getLocalizeKeyForScrollGroupId("undefined")]:"Ø",[W.getLocalizeKeyForScrollGroupId(0)]:"A",[W.getLocalizeKeyForScrollGroupId(1)]:"B",[W.getLocalizeKeyForScrollGroupId(2)]:"C",[W.getLocalizeKeyForScrollGroupId(3)]:"D",[W.getLocalizeKeyForScrollGroupId(4)]:"E",[W.getLocalizeKeyForScrollGroupId(5)]:"F",[W.getLocalizeKeyForScrollGroupId(6)]:"G",[W.getLocalizeKeyForScrollGroupId(7)]:"H",[W.getLocalizeKeyForScrollGroupId(8)]:"I",[W.getLocalizeKeyForScrollGroupId(9)]:"J",[W.getLocalizeKeyForScrollGroupId(10)]:"K",[W.getLocalizeKeyForScrollGroupId(11)]:"L",[W.getLocalizeKeyForScrollGroupId(12)]:"M",[W.getLocalizeKeyForScrollGroupId(13)]:"N",[W.getLocalizeKeyForScrollGroupId(14)]:"O",[W.getLocalizeKeyForScrollGroupId(15)]:"P",[W.getLocalizeKeyForScrollGroupId(16)]:"Q",[W.getLocalizeKeyForScrollGroupId(17)]:"R",[W.getLocalizeKeyForScrollGroupId(18)]:"S",[W.getLocalizeKeyForScrollGroupId(19)]:"T",[W.getLocalizeKeyForScrollGroupId(20)]:"U",[W.getLocalizeKeyForScrollGroupId(21)]:"V",[W.getLocalizeKeyForScrollGroupId(22)]:"W",[W.getLocalizeKeyForScrollGroupId(23)]:"X",[W.getLocalizeKeyForScrollGroupId(24)]:"Y",[W.getLocalizeKeyForScrollGroupId(25)]:"Z"};function fd({availableScrollGroupIds:e,scrollGroupId:t,onChangeScrollGroupId:n,localizedStrings:r={}}){const o={..._r,...Object.fromEntries(Object.entries(r).map(([s,i])=>[s,s===i&&s in _r?_r[s]:i]))};return a.jsxs(At,{value:`${t}`,onValueChange:s=>n(s==="undefined"?void 0:parseInt(s,10)),children:[a.jsx(bt,{className:"pr-twp tw-w-auto",children:a.jsx(Bt,{placeholder:o[W.getLocalizeKeyForScrollGroupId(t)]??t})}),a.jsx(vt,{style:{zIndex:250},children:e.map(s=>a.jsx(Ae,{value:`${s}`,children:o[W.getLocalizeKeyForScrollGroupId(s)]},`${s}`))})]})}function md({children:e}){return a.jsx("div",{className:"pr-twp tw-grid",children:e})}function hd({primary:e,secondary:t,children:n,isLoading:r=!1,loadingMessage:o}){return a.jsxs("div",{className:"tw-flex tw-items-center tw-justify-between tw-space-x-4 tw-py-2",children:[a.jsxs("div",{children:[a.jsx("p",{className:"tw-text-sm tw-font-medium tw-leading-none",children:e}),a.jsx("p",{className:"tw-whitespace-normal tw-break-words tw-text-sm tw-text-muted-foreground",children:t})]}),r?a.jsx("p",{className:"tw-text-sm tw-text-muted-foreground",children:o}):a.jsx("div",{children:n})]})}function gd({primary:e,secondary:t,includeSeparator:n=!1}){return a.jsxs("div",{className:"tw-space-y-4 tw-py-2",children:[a.jsxs("div",{children:[a.jsx("h3",{className:"tw-text-lg tw-font-medium",children:e}),a.jsx("p",{className:"tw-text-sm tw-text-muted-foreground",children:t})]}),n?a.jsx(lr,{}):""]})}function bd({id:e,className:t,listItems:n,selectedListItems:r,handleSelectListItem:o,createLabel:s}){return a.jsx("div",{id:e,className:t,children:n.map(i=>a.jsxs("div",{className:"tw-m-2 tw-flex tw-items-center",children:[a.jsx(sr,{className:"tw-mr-2 tw-align-middle",checked:r.includes(i),onCheckedChange:l=>o(i,l)}),a.jsx(qe,{children:s?s(i):i})]},i))})}function vd(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}function xd(e){if(e.__esModule)return e;var t=e.default;if(typeof t=="function"){var n=function r(){return this instanceof r?Reflect.construct(t,arguments,this.constructor):t.apply(this,arguments)};n.prototype=t.prototype}else n={};return Object.defineProperty(n,"__esModule",{value:!0}),Object.keys(e).forEach(function(r){var o=Object.getOwnPropertyDescriptor(e,r);Object.defineProperty(n,r,o.get?o:{enumerable:!0,get:function(){return e[r]}})}),n}var xo={},Ys={exports:{}};(function(e){function t(n){return n&&n.__esModule?n:{default:n}}e.exports=t,e.exports.__esModule=!0,e.exports.default=e.exports})(Ys);var yd=Ys.exports,Pr={};function yo(e,t){return process.env.NODE_ENV==="production"?()=>null:function(...r){return e(...r)||t(...r)}}function O(){return O=Object.assign?Object.assign.bind():function(e){for(var t=1;t{t[n]=Ws(e[n])}),t}function Qe(e,t,n={clone:!0}){const r=n.clone?O({},e):e;return mt(e)&&mt(t)&&Object.keys(t).forEach(o=>{o!=="__proto__"&&(mt(t[o])&&o in e&&mt(e[o])?r[o]=Qe(e[o],t[o],n):n.clone?r[o]=mt(t[o])?Ws(t[o]):t[o]:r[o]=t[o])}),r}var Kr={exports:{}},zn={exports:{}},ie={};/** @license React v16.13.1 +"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const a=require("react/jsx-runtime"),g=require("react"),ee=require("lucide-react"),ot=require("clsx"),pl=require("tailwind-merge"),Ja=require("@radix-ui/react-dropdown-menu"),W=require("platform-bible-utils"),Ht=require("@radix-ui/react-slot"),kn=require("class-variance-authority"),wl=require("@radix-ui/react-label"),fl=require("@radix-ui/react-radio-group"),ml=require("@radix-ui/react-popover"),Ce=require("cmdk"),hl=require("@radix-ui/react-dialog"),ke=require("@tanstack/react-table"),gl=require("@radix-ui/react-select"),bl=require("@radix-ui/react-checkbox"),vl=require("@radix-ui/react-toggle-group"),xl=require("@radix-ui/react-toggle"),yl=require("@radix-ui/react-tabs"),Nl=require("@radix-ui/react-separator"),kl=require("@radix-ui/react-tooltip"),Fr=require("@mui/styled-engine"),Ie=require("@mui/material"),sn=require("react-dom"),Za=require("sonner"),Sl=require("@radix-ui/react-slider"),El=require("@radix-ui/react-switch"),jl=require("markdown-to-jsx");function Ne(e){const t=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(e){for(const n in e)if(n!=="default"){const r=Object.getOwnPropertyDescriptor(e,n);Object.defineProperty(t,n,r.get?r:{enumerable:!0,get:()=>e[n]})}}return t.default=e,Object.freeze(t)}const $=Ne(g),pe=Ne(Ja),Qa=Ne(wl),gn=Ne(fl),bn=Ne(ml),Ye=Ne(hl),ge=Ne(gl),Gr=Ne(bl),rr=Ne(vl),es=Ne(xl),Re=Ne(yl),ts=Ne(Nl),Sn=Ne(kl),Tl=Ne(sn),ln=Ne(Sl),Ur=Ne(El);const Cl=pl.extendTailwindMerge({prefix:"tw-"});function N(...e){return Cl(ot.clsx(e))}const St=g.forwardRef(({className:e,type:t,...n},r)=>a.jsx("input",{type:t,className:N("pr-twp tw-flex tw-h-10 tw-rounded-md tw-border tw-border-input tw-bg-background tw-px-3 tw-py-2 tw-text-sm tw-ring-offset-background file:tw-border-0 file:tw-bg-transparent file:tw-text-sm file:tw-font-medium file:tw-text-foreground placeholder:tw-text-muted-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-cursor-not-allowed disabled:tw-opacity-50",e),ref:r,...n}));St.displayName="Input";const Rl=g.forwardRef(({handleSearch:e,handleKeyDown:t,handleOnClick:n,handleSubmit:r,...o},s)=>a.jsxs("div",{className:"tw-relative",children:[a.jsx(St,{...o,type:"text",className:"tw-box-border tw-gap-2.5 tw-rounded-lg tw-border tw-border-solid tw-bg-background tw-py-2 tw-pl-4 tw-pr-3 tw-font-medium tw-shadow-none tw-outline-none",onChange:i=>e(i.target.value),onKeyDown:i=>{i.key==="Enter"&&r(),t(i)},onClick:n,ref:s}),a.jsx(ee.History,{className:"tw-absolute tw-right-3 tw-top-1/2 tw-h-4 tw-w-4 tw--translate-y-1/2 tw-transform tw-cursor-pointer tw-text-muted-foreground",onClick:()=>{console.log("back in history")}})]}));var Ol=Object.defineProperty,_l=(e,t,n)=>t in e?Ol(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,ne=(e,t,n)=>_l(e,typeof t!="symbol"?t+"":t,n);const gt=["GEN","EXO","LEV","NUM","DEU","JOS","JDG","RUT","1SA","2SA","1KI","2KI","1CH","2CH","EZR","NEH","EST","JOB","PSA","PRO","ECC","SNG","ISA","JER","LAM","EZK","DAN","HOS","JOL","AMO","OBA","JON","MIC","NAM","HAB","ZEP","HAG","ZEC","MAL","MAT","MRK","LUK","JHN","ACT","ROM","1CO","2CO","GAL","EPH","PHP","COL","1TH","2TH","1TI","2TI","TIT","PHM","HEB","JAS","1PE","2PE","1JN","2JN","3JN","JUD","REV","TOB","JDT","ESG","WIS","SIR","BAR","LJE","S3Y","SUS","BEL","1MA","2MA","3MA","4MA","1ES","2ES","MAN","PS2","ODA","PSS","JSA","JDB","TBS","SST","DNT","BLT","XXA","XXB","XXC","XXD","XXE","XXF","XXG","FRT","BAK","OTH","3ES","EZA","5EZ","6EZ","INT","CNC","GLO","TDX","NDX","DAG","PS3","2BA","LBA","JUB","ENO","1MQ","2MQ","3MQ","REP","4BA","LAO"],oo=["XXA","XXB","XXC","XXD","XXE","XXF","XXG","FRT","BAK","OTH","INT","CNC","GLO","TDX","NDX"],ns=["Genesis","Exodus","Leviticus","Numbers","Deuteronomy","Joshua","Judges","Ruth","1 Samuel","2 Samuel","1 Kings","2 Kings","1 Chronicles","2 Chronicles","Ezra","Nehemiah","Esther (Hebrew)","Job","Psalms","Proverbs","Ecclesiastes","Song of Songs","Isaiah","Jeremiah","Lamentations","Ezekiel","Daniel (Hebrew)","Hosea","Joel","Amos","Obadiah","Jonah","Micah","Nahum","Habakkuk","Zephaniah","Haggai","Zechariah","Malachi","Matthew","Mark","Luke","John","Acts","Romans","1 Corinthians","2 Corinthians","Galatians","Ephesians","Philippians","Colossians","1 Thessalonians","2 Thessalonians","1 Timothy","2 Timothy","Titus","Philemon","Hebrews","James","1 Peter","2 Peter","1 John","2 John","3 John","Jude","Revelation","Tobit","Judith","Esther Greek","Wisdom of Solomon","Sirach (Ecclesiasticus)","Baruch","Letter of Jeremiah","Song of 3 Young Men","Susanna","Bel and the Dragon","1 Maccabees","2 Maccabees","3 Maccabees","4 Maccabees","1 Esdras (Greek)","2 Esdras (Latin)","Prayer of Manasseh","Psalm 151","Odes","Psalms of Solomon","Joshua A. *obsolete*","Judges B. *obsolete*","Tobit S. *obsolete*","Susanna Th. *obsolete*","Daniel Th. *obsolete*","Bel Th. *obsolete*","Extra A","Extra B","Extra C","Extra D","Extra E","Extra F","Extra G","Front Matter","Back Matter","Other Matter","3 Ezra *obsolete*","Apocalypse of Ezra","5 Ezra (Latin Prologue)","6 Ezra (Latin Epilogue)","Introduction","Concordance ","Glossary ","Topical Index","Names Index","Daniel Greek","Psalms 152-155","2 Baruch (Apocalypse)","Letter of Baruch","Jubilees","Enoch","1 Meqabyan","2 Meqabyan","3 Meqabyan","Reproof (Proverbs 25-31)","4 Baruch (Rest of Baruch)","Laodiceans"],na=Ll();function Yt(e,t=!0){return t&&(e=e.toUpperCase()),e in na?na[e]:0}function ao(e){return Yt(e)>0}function Pl(e){const t=typeof e=="string"?Yt(e):e;return t>=40&&t<=66}function Il(e){return(typeof e=="string"?Yt(e):e)<=39}function rs(e){return e<=66}function Ml(e){const t=typeof e=="string"?Yt(e):e;return ss(t)&&!rs(t)}function*$l(){for(let e=1;e<=gt.length;e++)yield e}const Dl=1,os=gt.length;function Al(){return["XXA","XXB","XXC","XXD","XXE","XXF","XXG"]}function so(e,t="***"){const n=e-1;return n<0||n>=gt.length?t:gt[n]}function as(e){return e<=0||e>os?"******":ns[e-1]}function Bl(e){return as(Yt(e))}function ss(e){const t=typeof e=="number"?so(e):e;return ao(t)&&!oo.includes(t)}function Vl(e){const t=typeof e=="number"?so(e):e;return ao(t)&&oo.includes(t)}function zl(e){return ns[e-1].includes("*obsolete*")}function Ll(){const e={};for(let t=0;t(e[e.Unknown=0]="Unknown",e[e.Original=1]="Original",e[e.Septuagint=2]="Septuagint",e[e.Vulgate=3]="Vulgate",e[e.English=4]="English",e[e.RussianProtestant=5]="RussianProtestant",e[e.RussianOrthodox=6]="RussianOrthodox",e))(qe||{});const _e=class{constructor(t){if(ne(this,"name"),ne(this,"fullPath"),ne(this,"isPresent"),ne(this,"hasVerseSegments"),ne(this,"isCustomized"),ne(this,"baseVersification"),ne(this,"scriptureBooks"),ne(this,"_type"),t==null)throw new Error("Argument undefined");typeof t=="string"?(this.name=t,this._type=qe[t]):(this._type=t,this.name=qe[t])}get type(){return this._type}equals(t){return!t.type||!this.type?!1:t.type===this.type}};ne(_e,"Original",new _e(qe.Original)),ne(_e,"Septuagint",new _e(qe.Septuagint)),ne(_e,"Vulgate",new _e(qe.Vulgate)),ne(_e,"English",new _e(qe.English)),ne(_e,"RussianProtestant",new _e(qe.RussianProtestant)),ne(_e,"RussianOrthodox",new _e(qe.RussianOrthodox));let ut=_e;function ra(e,t){const n=t[0];for(let r=1;r(e[e.Valid=0]="Valid",e[e.UnknownVersification=1]="UnknownVersification",e[e.OutOfRange=2]="OutOfRange",e[e.VerseOutOfOrder=3]="VerseOutOfOrder",e[e.VerseRepeated=4]="VerseRepeated",e))(is||{});const Ee=class re{constructor(t,n,r,o){if(ne(this,"firstChapter"),ne(this,"lastChapter"),ne(this,"lastVerse"),ne(this,"hasSegmentsDefined"),ne(this,"text"),ne(this,"BBBCCCVVVS"),ne(this,"longHashCode"),ne(this,"versification"),ne(this,"rtlMark","‏"),ne(this,"_bookNum",0),ne(this,"_chapterNum",0),ne(this,"_verseNum",0),ne(this,"_verse"),r==null&&o==null)if(t!=null&&typeof t=="string"){const s=t,i=n!=null&&n instanceof ut?n:void 0;this.setEmpty(i),this.parse(s)}else if(t!=null&&typeof t=="number"){const s=n!=null&&n instanceof ut?n:void 0;this.setEmpty(s),this._verseNum=t%re.chapterDigitShifter,this._chapterNum=Math.floor(t%re.bookDigitShifter/re.chapterDigitShifter),this._bookNum=Math.floor(t/re.bookDigitShifter)}else if(n==null)if(t!=null&&t instanceof re){const s=t;this._bookNum=s.bookNum,this._chapterNum=s.chapterNum,this._verseNum=s.verseNum,this._verse=s.verse,this.versification=s.versification}else{if(t==null)return;const s=t instanceof ut?t:re.defaultVersification;this.setEmpty(s)}else throw new Error("VerseRef constructor not supported.");else if(t!=null&&n!=null&&r!=null)if(typeof t=="string"&&typeof n=="string"&&typeof r=="string")this.setEmpty(o),this.updateInternal(t,n,r);else if(typeof t=="number"&&typeof n=="number"&&typeof r=="number")this._bookNum=t,this._chapterNum=n,this._verseNum=r,this.versification=o??re.defaultVersification;else throw new Error("VerseRef constructor not supported.");else throw new Error("VerseRef constructor not supported.")}static isVerseParseable(t){return t.length>0&&"0123456789".includes(t[0])&&!t.endsWith(this.verseRangeSeparator)&&!t.endsWith(this.verseSequenceIndicator)}static tryParse(t){let n;try{return n=new re(t),{success:!0,verseRef:n}}catch(r){if(r instanceof tn)return n=new re,{success:!1,verseRef:n};throw r}}static getBBBCCCVVV(t,n,r){return t%re.bcvMaxValue*re.bookDigitShifter+(n>=0?n%re.bcvMaxValue*re.chapterDigitShifter:0)+(r>=0?r%re.bcvMaxValue:0)}static fromJSON(t){const{book:n,chapterNum:r,verseNum:o,verse:s,versificationStr:i}=t,l=s||o.toString();let c;return i&&(c=new ut(i)),n?new re(n,r.toString(),l,c):new re}static tryGetVerseNum(t){let n;if(!t)return n=-1,{success:!0,vNum:n};n=0;let r;for(let o=0;o"9")return o===0&&(n=-1),{success:!1,vNum:n};if(n=n*10+ +r-0,n>re.bcvMaxValue)return n=-1,{success:!1,vNum:n}}return{success:!0,vNum:n}}get isDefault(){return this.bookNum===0&&this.chapterNum===0&&this.verseNum===0&&this.versification==null}get hasMultiple(){return this._verse!=null&&(this._verse.includes(re.verseRangeSeparator)||this._verse.includes(re.verseSequenceIndicator))}get book(){return ae.bookNumberToId(this.bookNum,"")}set book(t){this.bookNum=ae.bookIdToNumber(t)}get chapter(){return this.isDefault||this._chapterNum<0?"":this._chapterNum.toString()}set chapter(t){const n=+t;this._chapterNum=Number.isInteger(n)?n:-1}get verse(){return this._verse!=null?this._verse:this.isDefault||this._verseNum<0?"":this._verseNum.toString()}set verse(t){const{success:n,vNum:r}=re.tryGetVerseNum(t);this._verse=n?void 0:t.replace(this.rtlMark,""),this._verseNum=r,!(this._verseNum>=0)&&({vNum:this._verseNum}=re.tryGetVerseNum(this._verse))}get bookNum(){return this._bookNum}set bookNum(t){if(t<=0||t>ae.lastBook)throw new tn("BookNum must be greater than zero and less than or equal to last book");this._bookNum=t}get chapterNum(){return this._chapterNum}set chapterNum(t){this.chapterNum=t}get verseNum(){return this._verseNum}set verseNum(t){this._verseNum=t}get versificationStr(){var t;return(t=this.versification)==null?void 0:t.name}set versificationStr(t){this.versification=this.versification!=null?new ut(t):void 0}get valid(){return this.validStatus===0}get validStatus(){return this.validateVerse(re.verseRangeSeparators,re.verseSequenceIndicators)}get BBBCCC(){return re.getBBBCCCVVV(this._bookNum,this._chapterNum,0)}get BBBCCCVVV(){return re.getBBBCCCVVV(this._bookNum,this._chapterNum,this._verseNum)}get isExcluded(){return!1}parse(t){if(t=t.replace(this.rtlMark,""),t.includes("/")){const s=t.split("/");if(t=s[0],s.length>1)try{const i=+s[1].trim();this.versification=new ut(qe[i])}catch{throw new tn("Invalid reference : "+t)}}const n=t.trim().split(" ");if(n.length!==2)throw new tn("Invalid reference : "+t);const r=n[1].split(":"),o=+r[0];if(r.length!==2||ae.bookIdToNumber(n[0])===0||!Number.isInteger(o)||o<0||!re.isVerseParseable(r[1]))throw new tn("Invalid reference : "+t);this.updateInternal(n[0],r[0],r[1])}simplify(){this._verse=void 0}clone(){return new re(this)}toString(){const t=this.book;return t===""?"":`${t} ${this.chapter}:${this.verse}`}toJSON(){let t=this.verse;(t===""||t===this.verseNum.toString())&&(t=void 0);const n={book:this.book,chapterNum:this.chapterNum,verseNum:this.verseNum,verse:t,versificationStr:this.versificationStr};return t||delete n.verse,n}equals(t){return t instanceof re?t._bookNum===this._bookNum&&t._chapterNum===this._chapterNum&&t._verseNum===this._verseNum&&t.verse===this.verse&&(t.versification==null&&this.versification==null||t.versification!=null&&this.versification!=null&&t.versification.equals(this.versification)):!1}allVerses(t=!1,n=re.verseRangeSeparators,r=re.verseSequenceIndicators){if(this._verse==null||this.chapterNum<=0)return[this.clone()];const o=[],s=ra(this._verse,r);for(const i of s.map(l=>ra(l,n))){const l=this.clone();l.verse=i[0];const c=l.verseNum;if(o.push(l),i.length>1){const d=this.clone();if(d.verse=i[1],!t)for(let u=c+1;ui)return 3;if(r===i)return 4;r=i}return 0}get internalValid(){return this.versification==null?1:this._bookNum<=0||this._bookNum>ae.lastBook?2:(ae.isCanonical(this._bookNum),0)}setEmpty(t=re.defaultVersification){this._bookNum=0,this._chapterNum=-1,this._verse=void 0,this.versification=t}updateInternal(t,n,r){this.bookNum=ae.bookIdToNumber(t),this.chapter=n,this.verse=r}};ne(Ee,"defaultVersification",ut.English),ne(Ee,"verseRangeSeparator","-"),ne(Ee,"verseSequenceIndicator",","),ne(Ee,"verseRangeSeparators",[Ee.verseRangeSeparator]),ne(Ee,"verseSequenceIndicators",[Ee.verseSequenceIndicator]),ne(Ee,"chapterDigitShifter",1e3),ne(Ee,"bookDigitShifter",Ee.chapterDigitShifter*Ee.chapterDigitShifter),ne(Ee,"bcvMaxValue",Ee.chapterDigitShifter-1),ne(Ee,"ValidStatusType",is);class tn extends Error{}const or=pe.Root,io=pe.Trigger,ls=pe.Group,Fl=pe.Portal,Gl=pe.Sub,Ul=pe.RadioGroup,cs=g.forwardRef(({className:e,inset:t,children:n,...r},o)=>a.jsxs(pe.SubTrigger,{ref:o,className:N("tw-flex tw-cursor-default tw-select-none tw-items-center tw-rounded-sm tw-px-2 tw-py-1.5 tw-text-sm tw-outline-none focus:tw-bg-accent data-[state=open]:tw-bg-accent",t&&"tw-pl-8",e),...r,children:[n,a.jsx(ee.ChevronRight,{className:"tw-ml-auto tw-h-4 tw-w-4"})]}));cs.displayName=pe.SubTrigger.displayName;const ds=g.forwardRef(({className:e,...t},n)=>a.jsx(pe.SubContent,{ref:n,className:N("tw-z-50 tw-min-w-[8rem] tw-overflow-hidden tw-rounded-md tw-border tw-bg-popover tw-p-1 tw-text-popover-foreground tw-shadow-lg data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0 data-[state=closed]:tw-zoom-out-95 data-[state=open]:tw-zoom-in-95 data-[side=bottom]:tw-slide-in-from-top-2 data-[side=left]:tw-slide-in-from-right-2 data-[side=right]:tw-slide-in-from-left-2 data-[side=top]:tw-slide-in-from-bottom-2",e),...t}));ds.displayName=pe.SubContent.displayName;const En=g.forwardRef(({className:e,sideOffset:t=4,...n},r)=>a.jsx(pe.Portal,{children:a.jsx(pe.Content,{ref:r,sideOffset:t,className:N("pr-twp tw-z-50 tw-min-w-[8rem] tw-overflow-hidden tw-rounded-md tw-border tw-bg-popover tw-p-1 tw-text-popover-foreground tw-shadow-md data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0 data-[state=closed]:tw-zoom-out-95 data-[state=open]:tw-zoom-in-95 data-[side=bottom]:tw-slide-in-from-top-2 data-[side=left]:tw-slide-in-from-right-2 data-[side=right]:tw-slide-in-from-left-2 data-[side=top]:tw-slide-in-from-bottom-2",e),...n})}));En.displayName=pe.Content.displayName;const lo=g.forwardRef(({className:e,inset:t,...n},r)=>a.jsx(pe.Item,{ref:r,className:N("tw-cursor-default tw-select-none tw-items-center tw-rounded-sm tw-px-2 tw-py-1.5 tw-text-sm tw-outline-none tw-transition-colors focus:tw-bg-accent data-[disabled]:tw-pointer-events-none data-[disabled]:tw-opacity-50",t&&"tw-pl-8",e),...n}));lo.displayName=pe.Item.displayName;const ar=g.forwardRef(({className:e,children:t,checked:n,...r},o)=>a.jsxs(pe.CheckboxItem,{ref:o,className:N("tw-relative tw-flex tw-cursor-default tw-select-none tw-items-center tw-rounded-sm tw-py-1.5 tw-pl-8 tw-pr-2 tw-text-sm tw-outline-none tw-transition-colors focus:tw-bg-accent focus:tw-text-accent-foreground data-[disabled]:tw-pointer-events-none data-[disabled]:tw-opacity-50",e),checked:n,...r,children:[a.jsx("span",{className:"tw-absolute tw-left-2 tw-flex tw-h-3.5 tw-w-3.5 tw-items-center tw-justify-center",children:a.jsx(pe.ItemIndicator,{children:a.jsx(ee.Check,{className:"tw-h-4 tw-w-4"})})}),t]}));ar.displayName=pe.CheckboxItem.displayName;const co=g.forwardRef(({className:e,children:t,...n},r)=>a.jsxs(pe.RadioItem,{ref:r,className:N("tw-relative tw-flex tw-cursor-default tw-select-none tw-items-center tw-rounded-sm tw-py-1.5 tw-pl-8 tw-pr-2 tw-text-sm tw-outline-none tw-transition-colors focus:tw-bg-accent focus:tw-text-accent-foreground data-[disabled]:tw-pointer-events-none data-[disabled]:tw-opacity-50",e),...n,children:[a.jsx("span",{className:"tw-absolute tw-left-2 tw-flex tw-h-3.5 tw-w-3.5 tw-items-center tw-justify-center",children:a.jsx(pe.ItemIndicator,{children:a.jsx(ee.Circle,{className:"tw-h-2 tw-w-2 tw-fill-current"})})}),t]}));co.displayName=pe.RadioItem.displayName;const Xt=g.forwardRef(({className:e,inset:t,...n},r)=>a.jsx(pe.Label,{ref:r,className:N("tw-px-2 tw-py-1.5 tw-text-sm tw-font-semibold",t&&"tw-pl-8",e),...n}));Xt.displayName=pe.Label.displayName;const jn=g.forwardRef(({className:e,...t},n)=>a.jsx(pe.Separator,{ref:n,className:N("tw--mx-1 tw-my-1 tw-h-px tw-bg-muted",e),...t}));jn.displayName=pe.Separator.displayName;function us({className:e,...t}){return a.jsx("span",{className:N("tw-ml-auto tw-text-xs tw-tracking-widest tw-opacity-60",e),...t})}us.displayName="DropdownMenuShortcut";const ql=g.forwardRef(({bookId:e,handleSelectBook:t,isSelected:n,handleHighlightBook:r,handleKeyDown:o,bookType:s,children:i},l)=>a.jsxs(lo,{ref:l,textValue:e,className:N("tw-mx-1 tw-px-1 tw-font-normal tw-text-foreground/80",{"tw-bg-amber-50 tw-text-yellow-900 data-[highlighted]:tw-bg-amber-100":n}),onSelect:c=>{c.preventDefault(),t()},onKeyDown:c=>{o(c)},onFocus:r,onMouseMove:r,children:[a.jsx("span",{className:N("tw-border-b-0 tw-border-l-2 tw-border-r-0 tw-border-t-0 tw-border-solid tw-px-2",{"tw-font-bold":n,"tw-border-l-red-200":s.toLowerCase()==="ot","tw-border-l-purple-200":s.toLowerCase()==="nt","tw-border-l-indigo-200":s.toLowerCase()==="dc"}),children:ae.bookIdToEnglishName(e)}),n&&a.jsx("div",{children:i})]},e));function Hl({handleSelectChapter:e,endChapter:t,activeChapter:n,highlightedChapter:r,handleHighlightedChapter:o}){const s=Array.from({length:t},(l,c)=>c+1),i=g.useCallback(l=>{o(l)},[o]);return a.jsx("div",{className:N("tw-flex tw-flex-wrap tw-items-start tw-justify-start tw-self-stretch"),children:s.map(l=>a.jsx("div",{className:N("tw-box-content tw-flex tw-h-4 tw-w-4 tw-cursor-pointer tw-items-center tw-justify-end tw-rounded-md tw-p-2 tw-text-amber-800",{"tw-font-semibold tw-text-amber-900":l===n,"tw-bg-amber-200":l===r}),onClick:c=>{c.preventDefault(),c.stopPropagation(),e(l)},role:"button",onKeyDown:c=>{c.key==="Enter"&&e(l)},tabIndex:0,onMouseMove:()=>i(l),children:l},l))})}function Yl({handleSort:e,handleLocationHistory:t,handleBookmarks:n}){return a.jsxs(Xt,{className:"tw-flex tw-justify-between",children:[a.jsx("p",{className:"tw-inline-block tw-align-middle",children:"Go To"}),a.jsxs("div",{className:"tw-flex tw-items-center",children:[a.jsx(ee.ArrowDownWideNarrow,{onClick:e,className:"tw-m-2 tw-h-4 tw-w-4 tw-cursor-pointer tw-gap-2"}),a.jsx(ee.Clock,{onClick:t,className:"tw-m-2 tw-h-4 tw-w-4 tw-cursor-pointer tw-gap-2"}),a.jsx(ee.Bookmark,{onClick:n,className:"tw-m-2 tw-h-4 tw-w-4 tw-cursor-pointer tw-gap-2"})]})]})}const pn=ae.allBookIds,Xl={OT:"Old Testament",NT:"New Testament",DC:"Deuterocanon"},oa=["OT","NT","DC"],Wl=32+32+32,Kl=[/^(\w+)$/i,/^(\w+)(?:\s(\d+))$/i,/^(\w+)(?:\s(\d+):(\d+))$/i],Jl=e=>({OT:pn.filter(n=>ae.isBookOT(n)),NT:pn.filter(n=>ae.isBookNT(n)),DC:pn.filter(n=>ae.isBookDC(n))})[e],nn=e=>W.getChaptersForBook(ae.bookIdToNumber(e));function Zl(){return pn.map(t=>ae.bookIdToEnglishName(t))}function Ql(e){return Zl().includes(e)}function ec(e){const t=e.toLowerCase().replace(/^\w/,n=>n.toUpperCase());if(Ql(t))return pn.find(r=>ae.bookIdToEnglishName(r)===t)}function tc({scrRef:e,handleSubmit:t}){const[n,r]=g.useState(""),[o,s]=g.useState(ae.bookNumberToId(e.bookNum)),[i,l]=g.useState(e.chapterNum??0),[c,d]=g.useState(ae.bookNumberToId(e.bookNum)),[u,f]=g.useState(!1),[w,b]=g.useState(u),x=g.useRef(void 0),m=g.useRef(void 0),h=g.useRef(void 0),E=g.useCallback(k=>Jl(k).filter(D=>{const M=ae.bookIdToEnglishName(D).toLowerCase(),J=n.replace(/[^a-zA-Z]/g,"").toLowerCase();return M.includes(J)||D.toLowerCase().includes(J)}),[n]),I=k=>{r(k)},C=g.useRef(!1),S=g.useCallback(k=>{if(C.current){C.current=!1;return}f(k)},[]),v=g.useCallback((k,D,M,J)=>{if(l(ae.bookNumberToId(e.bookNum)!==k?1:e.chapterNum),D||nn(k)===-1){t({bookNum:ae.bookIdToNumber(k),chapterNum:M||1,verseNum:J||1}),f(!1),r("");return}s(o!==k?k:""),f(!D)},[t,e.bookNum,e.chapterNum,o]),_=k=>{k<=0||k>nn(o)||v(o,!0,k)},V=g.useCallback(()=>{Kl.forEach(k=>{const D=n.match(k);if(D){const[M,J=void 0,X=void 0]=D.slice(1),F=ec(M);(ae.isBookIdValid(M)||F)&&v(F??M,!0,J?parseInt(J,10):1,X?parseInt(X,10):1)}})},[v,n]),U=g.useCallback(k=>{u?(k.key==="ArrowDown"||k.key==="ArrowUp")&&(typeof h<"u"&&h.current!==null?h.current.focus():typeof m<"u"&&m.current!==null&&m.current.focus(),k.preventDefault()):f(!0)},[u]),j=k=>{const{key:D}=k;D==="ArrowRight"||D==="ArrowLeft"||D==="ArrowDown"||D==="ArrowUp"||D==="Enter"||(x.current.dispatchEvent(new KeyboardEvent("keydown",{key:D})),x.current.focus())},O=k=>{const{key:D}=k;if(c===o){if(D==="Enter"){k.preventDefault(),v(o,!0,i);return}let M=0;if(D==="ArrowRight")if(i1)M=-1;else{k.preventDefault();return}else D==="ArrowDown"?M=6:D==="ArrowUp"&&(M=-6);i+M<=0||i+M>nn(c)?l(0):M!==0&&(l(i+M),k.preventDefault())}};return g.useEffect(()=>{o===c?o===ae.bookNumberToId(e.bookNum)?l(e.chapterNum):l(1):l(0)},[c,e.bookNum,e.chapterNum,o]),g.useLayoutEffect(()=>{b(u)},[u]),g.useLayoutEffect(()=>{const k=setTimeout(()=>{if(w&&m.current&&h.current){const M=h.current.offsetTop-Wl;m.current.scrollTo({top:M,behavior:"instant"})}},10);return()=>{clearTimeout(k)}},[w]),a.jsx("div",{className:"pr-twp tw-flex",children:a.jsxs(or,{modal:!1,open:u,onOpenChange:S,children:[a.jsx(io,{asChild:!0,children:a.jsx(Rl,{ref:x,value:n,handleSearch:I,handleKeyDown:U,handleOnClick:()=>{s(ae.bookNumberToId(e.bookNum)),d(ae.bookNumberToId(e.bookNum)),l(e.chapterNum>0?e.chapterNum:0),f(!0),x.current.focus()},onFocus:()=>{C.current=!0},handleSubmit:V,placeholder:`${ae.bookNumberToEnglishName(e.bookNum)} ${e.chapterNum}:${e.verseNum}`})}),a.jsxs(En,{className:"tw-m-1 tw-overflow-y-auto tw-p-0 tw-font-normal tw-text-foreground/80",style:{width:"233px",maxHeight:"500px",zIndex:"250"},onKeyDown:j,align:"start",ref:m,children:[a.jsx(Yl,{handleSort:()=>console.log("sorting"),handleLocationHistory:()=>console.log("location history"),handleBookmarks:()=>console.log("bookmarks")}),oa.map((k,D)=>E(k).length>0&&a.jsxs("div",{children:[a.jsx(Xt,{className:"tw-font-semibold tw-text-foreground/80",children:Xl[k]}),E(k).map(M=>a.jsx("div",{children:a.jsx(ql,{bookId:M,handleSelectBook:()=>v(M,!1),isSelected:o===M,handleHighlightBook:()=>d(M),handleKeyDown:O,bookType:k,ref:J=>{o===M&&(h.current=J)},children:a.jsx(Hl,{handleSelectChapter:_,endChapter:nn(M),activeChapter:e.bookNum===ae.bookIdToNumber(M)?e.chapterNum:0,highlightedChapter:i,handleHighlightedChapter:J=>{l(J)}})})},M)),oa.length-1!==D?a.jsx(jn,{}):void 0]},k))]})]})})}const ps=kn.cva("pr-twp tw-inline-flex tw-items-center tw-justify-center tw-whitespace-nowrap tw-rounded-md tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-colors focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50",{variants:{variant:{default:"tw-bg-primary tw-text-primary-foreground hover:tw-bg-primary/90",destructive:"tw-bg-destructive tw-text-destructive-foreground hover:tw-bg-destructive/90",outline:"tw-border tw-border-input tw-bg-background hover:tw-bg-accent hover:tw-text-accent-foreground",secondary:"tw-bg-secondary tw-text-secondary-foreground hover:tw-bg-secondary/80",ghost:"hover:tw-bg-accent hover:tw-text-accent-foreground",link:"tw-text-primary tw-underline-offset-4 hover:tw-underline"},size:{default:"tw-h-10 tw-px-4 tw-py-2",sm:"tw-h-9 tw-rounded-md tw-px-3",lg:"tw-h-11 tw-rounded-md tw-px-8",icon:"tw-h-10 tw-w-10"}},defaultVariants:{variant:"default",size:"default"}}),fe=g.forwardRef(({className:e,variant:t,size:n,asChild:r=!1,...o},s)=>{const i=r?Ht.Slot:"button";return a.jsx(i,{className:N(ps({variant:t,size:n,className:e})),ref:s,...o})});fe.displayName="Button";const nc=kn.cva("tw-text-sm tw-font-medium tw-leading-none peer-disabled:tw-cursor-not-allowed peer-disabled:tw-opacity-70"),Ue=g.forwardRef(({className:e,...t},n)=>a.jsx(Qa.Root,{ref:n,className:N("pr-twp",nc(),e),...t}));Ue.displayName=Qa.Root.displayName;const uo=g.forwardRef(({className:e,...t},n)=>a.jsx(gn.Root,{className:N("pr-twp tw-grid tw-gap-2",e),...t,ref:n}));uo.displayName=gn.Root.displayName;const Xn=g.forwardRef(({className:e,...t},n)=>a.jsx(gn.Item,{ref:n,className:N("pr-twp tw-aspect-square tw-h-4 tw-w-4 tw-rounded-full tw-border tw-border-primary tw-text-primary tw-ring-offset-background focus:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-cursor-not-allowed disabled:tw-opacity-50",e),...t,children:a.jsx(gn.Indicator,{className:"tw-flex tw-items-center tw-justify-center",children:a.jsx(ee.Circle,{className:"tw-h-2.5 tw-w-2.5 tw-fill-current tw-text-current"})})}));Xn.displayName=gn.Item.displayName;const rc=bn.Root,oc=bn.Trigger,ws=g.forwardRef(({className:e,align:t="center",sideOffset:n=4,...r},o)=>a.jsx(bn.Portal,{children:a.jsx(bn.Content,{ref:o,align:t,sideOffset:n,className:N("pr-twp tw-z-50 tw-w-72 tw-rounded-md tw-border tw-bg-popover tw-p-4 tw-text-popover-foreground tw-shadow-md tw-outline-none data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0 data-[state=closed]:tw-zoom-out-95 data-[state=open]:tw-zoom-in-95 data-[side=bottom]:tw-slide-in-from-top-2 data-[side=left]:tw-slide-in-from-right-2 data-[side=right]:tw-slide-in-from-left-2 data-[side=top]:tw-slide-in-from-bottom-2",e),...r})}));ws.displayName=bn.Content.displayName;const ac=Ye.Portal,fs=g.forwardRef(({className:e,...t},n)=>a.jsx(Ye.Overlay,{ref:n,className:N("tw-fixed tw-inset-0 tw-z-50 tw-bg-black/80 data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0",e),...t}));fs.displayName=Ye.Overlay.displayName;const sc=g.forwardRef(({className:e,children:t,...n},r)=>a.jsxs(ac,{children:[a.jsx(fs,{}),a.jsxs(Ye.Content,{ref:r,className:N("tw-fixed tw-left-[50%] tw-top-[50%] tw-z-50 tw-grid tw-w-full tw-max-w-lg tw-translate-x-[-50%] tw-translate-y-[-50%] tw-gap-4 tw-border tw-bg-background tw-p-6 tw-shadow-lg tw-duration-200 data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0 data-[state=closed]:tw-zoom-out-95 data-[state=open]:tw-zoom-in-95 data-[state=closed]:tw-slide-out-to-left-1/2 data-[state=closed]:tw-slide-out-to-top-[48%] data-[state=open]:tw-slide-in-from-left-1/2 data-[state=open]:tw-slide-in-from-top-[48%] sm:tw-rounded-lg",e),...n,children:[t,a.jsxs(Ye.Close,{className:"tw-absolute tw-right-4 tw-top-4 tw-rounded-sm tw-opacity-70 tw-ring-offset-background tw-transition-opacity hover:tw-opacity-100 focus:tw-outline-none focus:tw-ring-2 focus:tw-ring-ring focus:tw-ring-offset-2 disabled:tw-pointer-events-none data-[state=open]:tw-bg-accent data-[state=open]:tw-text-muted-foreground",children:[a.jsx(ee.X,{className:"tw-h-4 tw-w-4"}),a.jsx("span",{className:"tw-sr-only",children:"Close"})]})]})]}));sc.displayName=Ye.Content.displayName;const ic=g.forwardRef(({className:e,...t},n)=>a.jsx(Ye.Title,{ref:n,className:N("tw-text-lg tw-font-semibold tw-leading-none tw-tracking-tight",e),...t}));ic.displayName=Ye.Title.displayName;const lc=g.forwardRef(({className:e,...t},n)=>a.jsx(Ye.Description,{ref:n,className:N("tw-text-sm tw-text-muted-foreground",e),...t}));lc.displayName=Ye.Description.displayName;const ms=g.forwardRef(({className:e,...t},n)=>a.jsx(Ce.Command,{ref:n,className:N("tw-flex tw-h-full tw-w-full tw-flex-col tw-overflow-hidden tw-rounded-md tw-bg-popover tw-text-popover-foreground",e),...t}));ms.displayName=Ce.Command.displayName;const hs=g.forwardRef(({className:e,...t},n)=>a.jsxs("div",{className:"tw-flex tw-items-center tw-border-b tw-px-3",children:[a.jsx(ee.Search,{className:"tw-me-2 tw-h-4 tw-w-4 tw-shrink-0 tw-opacity-50"}),a.jsx(Ce.Command.Input,{ref:n,className:N("tw-flex tw-h-11 tw-w-full tw-rounded-md tw-bg-transparent tw-py-3 tw-text-sm tw-outline-none placeholder:tw-text-muted-foreground disabled:tw-cursor-not-allowed disabled:tw-opacity-50",e),...t})]}));hs.displayName=Ce.Command.Input.displayName;const gs=g.forwardRef(({className:e,...t},n)=>a.jsx(Ce.Command.List,{ref:n,className:N("tw-max-h-[300px] tw-overflow-y-auto tw-overflow-x-hidden",e),...t}));gs.displayName=Ce.Command.List.displayName;const bs=g.forwardRef((e,t)=>a.jsx(Ce.Command.Empty,{ref:t,className:"tw-py-6 tw-text-center tw-text-sm",...e}));bs.displayName=Ce.Command.Empty.displayName;const cc=g.forwardRef(({className:e,...t},n)=>a.jsx(Ce.Command.Group,{ref:n,className:N("tw-overflow-hidden tw-p-1 tw-text-foreground [&_[cmdk-group-heading]]:tw-px-2 [&_[cmdk-group-heading]]:tw-py-1.5 [&_[cmdk-group-heading]]:tw-text-xs [&_[cmdk-group-heading]]:tw-font-medium [&_[cmdk-group-heading]]:tw-text-muted-foreground",e),...t}));cc.displayName=Ce.Command.Group.displayName;const dc=g.forwardRef(({className:e,...t},n)=>a.jsx(Ce.Command.Separator,{ref:n,className:N("tw--mx-1 tw-h-px tw-bg-border",e),...t}));dc.displayName=Ce.Command.Separator.displayName;const vs=g.forwardRef(({className:e,...t},n)=>a.jsx(Ce.Command.Item,{ref:n,className:N("tw-relative tw-flex tw-cursor-default tw-select-none tw-items-center tw-rounded-sm tw-px-2 tw-py-1.5 tw-text-sm tw-outline-none data-[disabled=true]:tw-pointer-events-none data-[selected=true]:tw-bg-accent data-[selected=true]:tw-text-accent-foreground data-[disabled=true]:tw-opacity-50",e),...t}));vs.displayName=Ce.Command.Item.displayName;function uc(e){return typeof e=="string"?e:typeof e=="number"?e.toString():e.label}function Wn({id:e,options:t=[],buttonClassName:n,popoverContentClassName:r,value:o,onChange:s=()=>{},getOptionLabel:i=uc,buttonPlaceholder:l="",textPlaceholder:c="",commandEmptyMessage:d="No option found",buttonVariant:u="outline",dir:f="ltr",isDisabled:w=!1,...b}){const[x,m]=g.useState(!1);return a.jsxs(rc,{open:x,onOpenChange:m,...b,children:[a.jsx(oc,{asChild:!0,children:a.jsxs(fe,{variant:u,role:"combobox","aria-expanded":x,id:e,className:N("tw-w-[200px] tw-justify-between",n),disabled:w,children:[a.jsx("span",{className:"tw-overflow-hidden tw-text-ellipsis tw-whitespace-nowrap",children:o?i(o):l}),a.jsx(ee.ChevronsUpDown,{className:"tw-ms-2 tw-h-4 tw-w-4 tw-shrink-0 tw-opacity-50"})]})}),a.jsx(ws,{className:N("tw-w-[200px] tw-p-0",r),dir:f,children:a.jsxs(ms,{children:[a.jsx(hs,{dir:f,placeholder:c,className:"tw-text-inherit"}),a.jsx(bs,{children:d}),a.jsx(gs,{children:t.map(h=>a.jsxs(vs,{value:i(h),onSelect:()=>{s(h),m(!1)},children:[a.jsx(ee.Check,{className:N("tw-me-2 tw-h-4 tw-w-4",{"tw-opacity-0":!o||i(o)!==i(h)})}),i(h)]},i(h)))})]})})]})}function xs({startChapter:e,endChapter:t,handleSelectStartChapter:n,handleSelectEndChapter:r,isDisabled:o=!1,chapterCount:s}){const i=g.useMemo(()=>Array.from({length:s},(d,u)=>u+1),[s]),l=d=>{n(d),d>t&&r(d)},c=d=>{r(d),dd.toString(),value:e},"start chapter"),a.jsx(Ue,{htmlFor:"end-chapters-combobox",children:"to"}),a.jsx(Wn,{isDisabled:o,onChange:c,buttonClassName:"tw-ml-2 tw-w-20",options:i,getOptionLabel:d=>d.toString(),value:t},"end chapter")]})}var ys=(e=>(e.CURRENT_BOOK="current book",e.CHOOSE_BOOKS="choose books",e))(ys||{});const pc=Object.freeze(["%webView_bookSelector_currentBook%","%webView_bookSelector_choose%","%webView_bookSelector_chooseBooks%"]),Cr=(e,t)=>e[t]??t;function wc({handleBookSelectionModeChange:e,currentBookName:t,onSelectBooks:n,selectedBookIds:r,chapterCount:o,endChapter:s,handleSelectEndChapter:i,startChapter:l,handleSelectStartChapter:c,localizedStrings:d}){const u=Cr(d,"%webView_bookSelector_currentBook%"),f=Cr(d,"%webView_bookSelector_choose%"),w=Cr(d,"%webView_bookSelector_chooseBooks%"),[b,x]=g.useState("current book"),m=h=>{x(h),e(h)};return a.jsx(uo,{className:"pr-twp tw-flex",value:b,onValueChange:h=>m(h),children:a.jsxs("div",{className:"tw-flex tw-w-full tw-flex-col tw-gap-4",children:[a.jsxs("div",{className:"tw-grid tw-grid-cols-[25%,25%,50%]",children:[a.jsxs("div",{className:"tw-flex tw-items-center",children:[a.jsx(Xn,{value:"current book"}),a.jsx(Ue,{className:"tw-ml-1",children:u})]}),a.jsx(Ue,{className:"tw-flex tw-items-center",children:t}),a.jsx("div",{className:"tw-flex tw-items-center tw-justify-end",children:a.jsx(xs,{isDisabled:b==="choose books",handleSelectStartChapter:c,handleSelectEndChapter:i,chapterCount:o,startChapter:l,endChapter:s})})]}),a.jsxs("div",{className:"tw-grid tw-grid-cols-[25%,50%,25%]",children:[a.jsxs("div",{className:"tw-flex tw-items-center",children:[a.jsx(Xn,{value:"choose books"}),a.jsx(Ue,{className:"tw-ml-1",children:w})]}),a.jsx(Ue,{className:"tw-flex tw-items-center",children:r.map(h=>ae.bookIdToEnglishName(h)).join(", ")}),a.jsx(fe,{disabled:b==="current book",onClick:()=>n(),children:f})]})]})})}function fc({table:e}){return a.jsxs(or,{children:[a.jsx(Ja.DropdownMenuTrigger,{asChild:!0,children:a.jsxs(fe,{variant:"outline",size:"sm",className:"tw-ml-auto tw-hidden tw-h-8 lg:tw-flex",children:[a.jsx(ee.FilterIcon,{className:"tw-mr-2 tw-h-4 tw-w-4"}),"View"]})}),a.jsxs(En,{align:"end",className:"tw-w-[150px]",children:[a.jsx(Xt,{children:"Toggle columns"}),a.jsx(jn,{}),e.getAllColumns().filter(t=>t.getCanHide()).map(t=>a.jsx(ar,{className:"tw-capitalize",checked:t.getIsVisible(),onCheckedChange:n=>t.toggleVisibility(!!n),children:t.id},t.id))]})]})}const At=ge.Root,Ns=ge.Group,Bt=ge.Value,bt=g.forwardRef(({className:e,children:t,...n},r)=>a.jsxs(ge.Trigger,{ref:r,className:N("tw-flex tw-h-10 tw-w-full tw-items-center tw-justify-between tw-rounded-md tw-border tw-border-input tw-bg-background tw-px-3 tw-py-2 tw-text-sm tw-ring-offset-background placeholder:tw-text-muted-foreground focus:tw-outline-none focus:tw-ring-2 focus:tw-ring-ring focus:tw-ring-offset-2 disabled:tw-cursor-not-allowed disabled:tw-opacity-50 [&>span]:tw-line-clamp-1",e),...n,children:[t,a.jsx(ge.Icon,{asChild:!0,children:a.jsx(ee.ChevronDown,{className:"tw-h-4 tw-w-4 tw-opacity-50"})})]}));bt.displayName=ge.Trigger.displayName;const po=g.forwardRef(({className:e,...t},n)=>a.jsx(ge.ScrollUpButton,{ref:n,className:N("tw-flex tw-cursor-default tw-items-center tw-justify-center tw-py-1",e),...t,children:a.jsx(ee.ChevronUp,{className:"tw-h-4 tw-w-4"})}));po.displayName=ge.ScrollUpButton.displayName;const wo=g.forwardRef(({className:e,...t},n)=>a.jsx(ge.ScrollDownButton,{ref:n,className:N("tw-flex tw-cursor-default tw-items-center tw-justify-center tw-py-1",e),...t,children:a.jsx(ee.ChevronDown,{className:"tw-h-4 tw-w-4"})}));wo.displayName=ge.ScrollDownButton.displayName;const vt=g.forwardRef(({className:e,children:t,position:n="popper",...r},o)=>a.jsx(ge.Portal,{children:a.jsxs(ge.Content,{ref:o,className:N("pr-twp tw-relative tw-z-50 tw-max-h-96 tw-min-w-[8rem] tw-overflow-hidden tw-rounded-md tw-border tw-bg-popover tw-text-popover-foreground tw-shadow-md data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0 data-[state=closed]:tw-zoom-out-95 data-[state=open]:tw-zoom-in-95 data-[side=bottom]:tw-slide-in-from-top-2 data-[side=left]:tw-slide-in-from-right-2 data-[side=right]:tw-slide-in-from-left-2 data-[side=top]:tw-slide-in-from-bottom-2",n==="popper"&&"data-[side=bottom]:tw-translate-y-1 data-[side=left]:tw--translate-x-1 data-[side=right]:tw-translate-x-1 data-[side=top]:tw--translate-y-1",e),position:n,...r,children:[a.jsx(po,{}),a.jsx(ge.Viewport,{className:N("tw-p-1",n==="popper"&&"tw-h-[var(--radix-select-trigger-height)] tw-w-full tw-min-w-[var(--radix-select-trigger-width)]"),children:t}),a.jsx(wo,{})]})}));vt.displayName=ge.Content.displayName;const ks=g.forwardRef(({className:e,...t},n)=>a.jsx(ge.Label,{ref:n,className:N("tw-py-1.5 tw-pl-8 tw-pr-2 tw-text-sm tw-font-semibold",e),...t}));ks.displayName=ge.Label.displayName;const De=g.forwardRef(({className:e,children:t,...n},r)=>a.jsxs(ge.Item,{ref:r,className:N("tw-relative tw-flex tw-w-full tw-cursor-default tw-select-none tw-items-center tw-rounded-sm tw-py-1.5 tw-pl-8 tw-pr-2 tw-text-sm tw-outline-none focus:tw-bg-accent focus:tw-text-accent-foreground data-[disabled]:tw-pointer-events-none data-[disabled]:tw-opacity-50",e),...n,children:[a.jsx("span",{className:"tw-absolute tw-left-2 tw-flex tw-h-3.5 tw-w-3.5 tw-items-center tw-justify-center",children:a.jsx(ge.ItemIndicator,{children:a.jsx(ee.Check,{className:"tw-h-4 tw-w-4"})})}),a.jsx(ge.ItemText,{children:t})]}));De.displayName=ge.Item.displayName;const Ss=g.forwardRef(({className:e,...t},n)=>a.jsx(ge.Separator,{ref:n,className:N("tw--mx-1 tw-my-1 tw-h-px tw-bg-muted",e),...t}));Ss.displayName=ge.Separator.displayName;function mc({table:e}){return a.jsx("div",{className:"tw-flex tw-items-center tw-justify-between tw-px-2 tw-pb-3 tw-pt-3",children:a.jsxs("div",{className:"tw-flex tw-items-center tw-space-x-6 lg:tw-space-x-8",children:[a.jsxs("div",{className:"tw-flex-1 tw-text-sm tw-text-muted-foreground",children:[e.getFilteredSelectedRowModel().rows.length," of"," ",e.getFilteredRowModel().rows.length," row(s) selected"]}),a.jsxs("div",{className:"tw-flex tw-items-center tw-space-x-2",children:[a.jsx("p",{className:"tw-text-nowrap tw-text-sm tw-font-medium",children:"Rows per page"}),a.jsxs(At,{value:`${e.getState().pagination.pageSize}`,onValueChange:t=>{e.setPageSize(Number(t))},children:[a.jsx(bt,{className:"tw-h-8 tw-w-[70px]",children:a.jsx(Bt,{placeholder:e.getState().pagination.pageSize})}),a.jsx(vt,{side:"top",children:[10,20,30,40,50].map(t=>a.jsx(De,{value:`${t}`,children:t},t))})]})]}),a.jsxs("div",{className:"tw-flex tw-w-[100px] tw-items-center tw-justify-center tw-text-sm tw-font-medium",children:["Page ",e.getState().pagination.pageIndex+1," of ",e.getPageCount()]}),a.jsxs("div",{className:"tw-flex tw-items-center tw-space-x-2",children:[a.jsxs(fe,{variant:"outline",size:"icon",className:"tw-hidden tw-h-8 tw-w-8 tw-p-0 lg:tw-flex",onClick:()=>e.setPageIndex(0),disabled:!e.getCanPreviousPage(),children:[a.jsx("span",{className:"tw-sr-only",children:"Go to first page"}),a.jsx(ee.ArrowLeftIcon,{className:"tw-h-4 tw-w-4"})]}),a.jsxs(fe,{variant:"outline",size:"icon",className:"tw-h-8 tw-w-8 tw-p-0",onClick:()=>e.previousPage(),disabled:!e.getCanPreviousPage(),children:[a.jsx("span",{className:"tw-sr-only",children:"Go to previous page"}),a.jsx(ee.ChevronLeftIcon,{className:"tw-h-4 tw-w-4"})]}),a.jsxs(fe,{variant:"outline",size:"icon",className:"tw-h-8 tw-w-8 tw-p-0",onClick:()=>e.nextPage(),disabled:!e.getCanNextPage(),children:[a.jsx("span",{className:"tw-sr-only",children:"Go to next page"}),a.jsx(ee.ChevronRightIcon,{className:"tw-h-4 tw-w-4"})]}),a.jsxs(fe,{variant:"outline",size:"icon",className:"tw-hidden tw-h-8 tw-w-8 tw-p-0 lg:tw-flex",onClick:()=>e.setPageIndex(e.getPageCount()-1),disabled:!e.getCanNextPage(),children:[a.jsx("span",{className:"tw-sr-only",children:"Go to last page"}),a.jsx(ee.ArrowRightIcon,{className:"tw-h-4 tw-w-4"})]})]})]})})}const Tn=g.forwardRef(({className:e,stickyHeader:t,...n},r)=>a.jsx("div",{className:N("pr-twp tw-relative tw-w-full",{"tw-overflow-auto":!t}),children:a.jsx("table",{ref:r,className:N("tw-w-full tw-caption-bottom tw-text-sm",e),...n})}));Tn.displayName="Table";const Cn=g.forwardRef(({className:e,stickyHeader:t,...n},r)=>a.jsx("thead",{ref:r,className:N({"tw-sticky tw-top-[-1px] tw-bg-background tw-drop-shadow-sm":t},"[&_tr]:tw-border-b",e),...n}));Cn.displayName="TableHeader";const Rn=g.forwardRef(({className:e,...t},n)=>a.jsx("tbody",{ref:n,className:N("[&_tr:last-child]:tw-border-0",e),...t}));Rn.displayName="TableBody";const Es=g.forwardRef(({className:e,...t},n)=>a.jsx("tfoot",{ref:n,className:N("tw-border-t tw-bg-muted/50 tw-font-medium [&>tr]:last:tw-border-b-0",e),...t}));Es.displayName="TableFooter";const Ze=g.forwardRef(({className:e,...t},n)=>a.jsx("tr",{ref:n,className:N("tw-border-b tw-transition-colors hover:tw-bg-muted/50 data-[state=selected]:tw-bg-muted",e),...t}));Ze.displayName="TableRow";const Vt=g.forwardRef(({className:e,...t},n)=>a.jsx("th",{ref:n,className:N("tw-h-12 tw-px-4 tw-text-start tw-align-middle tw-font-medium tw-text-muted-foreground [&:has([role=checkbox])]:tw-pe-0",e),...t}));Vt.displayName="TableHead";const xt=g.forwardRef(({className:e,...t},n)=>a.jsx("td",{ref:n,className:N("tw-p-4 tw-align-middle [&:has([role=checkbox])]:tw-pe-0",e),...t}));xt.displayName="TableCell";const js=g.forwardRef(({className:e,...t},n)=>a.jsx("caption",{ref:n,className:N("tw-mt-4 tw-text-sm tw-text-muted-foreground",e),...t}));js.displayName="TableCaption";function Ts({columns:e,data:t,enablePagination:n=!1,showPaginationControls:r=!1,showColumnVisibilityControls:o=!1,stickyHeader:s=!1,onRowClickHandler:i=()=>{}}){var h;const[l,c]=g.useState([]),[d,u]=g.useState([]),[f,w]=g.useState({}),[b,x]=g.useState({}),m=ke.useReactTable({data:t,columns:e,getCoreRowModel:ke.getCoreRowModel(),...n&&{getPaginationRowModel:ke.getPaginationRowModel()},onSortingChange:c,getSortedRowModel:ke.getSortedRowModel(),onColumnFiltersChange:u,getFilteredRowModel:ke.getFilteredRowModel(),onColumnVisibilityChange:w,onRowSelectionChange:x,state:{sorting:l,columnFilters:d,columnVisibility:f,rowSelection:b}});return a.jsxs("div",{className:"pr-twp",children:[o&&a.jsx(fc,{table:m}),a.jsxs(Tn,{stickyHeader:s,children:[a.jsx(Cn,{stickyHeader:s,children:m.getHeaderGroups().map(E=>a.jsx(Ze,{children:E.headers.map(I=>a.jsx(Vt,{children:I.isPlaceholder?void 0:ke.flexRender(I.column.columnDef.header,I.getContext())},I.id))},E.id))}),a.jsx(Rn,{children:(h=m.getRowModel().rows)!=null&&h.length?m.getRowModel().rows.map(E=>a.jsx(Ze,{onClick:()=>i(E,m),"data-state":E.getIsSelected()&&"selected",children:E.getVisibleCells().map(I=>a.jsx(xt,{children:ke.flexRender(I.column.columnDef.cell,I.getContext())},I.id))},E.id)):a.jsx(Ze,{children:a.jsx(xt,{colSpan:e.length,className:"tw-h-24 tw-text-center",children:"No results."})})})]}),n&&a.jsxs("div",{className:"tw-flex tw-items-center tw-justify-end tw-space-x-2 tw-py-4",children:[a.jsx(fe,{variant:"outline",size:"sm",onClick:()=>m.previousPage(),disabled:!m.getCanPreviousPage(),children:"Previous"}),a.jsx(fe,{variant:"outline",size:"sm",onClick:()=>m.nextPage(),disabled:!m.getCanNextPage(),children:"Next"})]}),n&&r&&a.jsx(mc,{table:m})]})}function hc({occurrenceData:e,setScriptureReference:t,localizedStrings:n}){const r=n["%webView_inventory_occurrences_table_header_reference%"],o=n["%webView_inventory_occurrences_table_header_occurrence%"],s=g.useMemo(()=>{const i=[];return e.forEach(l=>{i.some(c=>W.deepEqual(c,l))||i.push(l)}),i},[e]);return a.jsxs(Tn,{stickyHeader:!0,children:[a.jsx(Cn,{stickyHeader:!0,children:a.jsxs(Ze,{children:[a.jsx(Vt,{children:r}),a.jsx(Vt,{children:o})]})}),a.jsx(Rn,{children:s.length>0&&s.map(i=>a.jsxs(Ze,{onClick:()=>{t(i.reference)},children:[a.jsx(xt,{children:`${ae.bookNumberToEnglishName(i.reference.bookNum)} ${i.reference.chapterNum}:${i.reference.verseNum}`}),a.jsx(xt,{children:i.text})]},`${i.reference.bookNum} ${i.reference.chapterNum}:${i.reference.verseNum}-${i.text}`))})]})}const sr=g.forwardRef(({className:e,...t},n)=>a.jsx(Gr.Root,{ref:n,className:N("tw-peer pr-twp tw-h-4 tw-w-4 tw-shrink-0 tw-rounded-sm tw-border tw-border-primary tw-ring-offset-background focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-cursor-not-allowed disabled:tw-opacity-50 data-[state=checked]:tw-bg-primary data-[state=checked]:tw-text-primary-foreground",e),...t,children:a.jsx(Gr.Indicator,{className:N("tw-flex tw-items-center tw-justify-center tw-text-current"),children:a.jsx(ee.Check,{className:"tw-h-4 tw-w-4"})})}));sr.displayName=Gr.Root.displayName;const Cs=e=>e.split(/(?:\r?\n|\r)|(?=(?:\\(?:v|c|id)))/g),qr=e=>{const t=/^\\[vc]\s+(\d+)/,n=e.match(t);if(n)return+n[1]},Rs=e=>{const t=e.match(/^\\id\s+([A-Za-z]+)/);return t?ae.bookIdToNumber(t[1]):0},Os=(e,t,n)=>n.includes(e)?"unapproved":t.includes(e)?"approved":"unknown",_s=kn.cva("pr-twp tw-inline-flex tw-items-center tw-justify-center tw-rounded-md tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-colors hover:tw-bg-muted hover:tw-text-muted-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50 data-[state=on]:tw-bg-accent data-[state=on]:tw-text-accent-foreground",{variants:{variant:{default:"tw-bg-transparent",outline:"tw-border tw-border-input tw-bg-transparent hover:tw-bg-accent hover:tw-text-accent-foreground"},size:{default:"tw-h-10 tw-px-3",sm:"tw-h-9 tw-px-2.5",lg:"tw-h-11 tw-px-5"}},defaultVariants:{variant:"default",size:"default"}}),gc=g.forwardRef(({className:e,variant:t,size:n,...r},o)=>a.jsx(es.Root,{ref:o,className:N(_s({variant:t,size:n,className:e})),...r}));gc.displayName=es.Root.displayName;const Ps=g.createContext({size:"default",variant:"default"}),fo=g.forwardRef(({className:e,variant:t,size:n,children:r,...o},s)=>a.jsx(rr.Root,{ref:s,className:N("pr-twp tw-flex tw-items-center tw-justify-center tw-gap-1",e),...o,children:a.jsx(Ps.Provider,{value:{variant:t,size:n},children:r})}));fo.displayName=rr.Root.displayName;const wn=g.forwardRef(({className:e,children:t,variant:n,size:r,...o},s)=>{const i=g.useContext(Ps);return a.jsx(rr.Item,{ref:s,className:N(_s({variant:i.variant||n,size:i.size||r}),e),...o,children:t})});wn.displayName=rr.Item.displayName;const ir=e=>e==="asc"?a.jsx(ee.ArrowUpIcon,{className:"tw-ms-2 tw-h-4 tw-w-4"}):e==="desc"?a.jsx(ee.ArrowDownIcon,{className:"tw-ms-2 tw-h-4 tw-w-4"}):a.jsx(ee.ArrowUpDownIcon,{className:"tw-ms-2 tw-h-4 tw-w-4"}),bc=e=>({accessorKey:"item",accessorFn:t=>t.items[0],header:({column:t})=>a.jsxs(fe,{variant:"ghost",onClick:()=>t.toggleSorting(void 0),children:[e,ir(t.getIsSorted())]})}),vc=(e,t)=>({accessorKey:`item${t}`,accessorFn:n=>n.items[t],header:({column:n})=>a.jsxs(fe,{variant:"ghost",onClick:()=>n.toggleSorting(void 0),children:[e,ir(n.getIsSorted())]})}),xc=e=>({accessorKey:"count",header:({column:t})=>a.jsx("div",{className:"tw-flex tw-justify-end tw-tabular-nums",children:a.jsxs(fe,{variant:"ghost",onClick:()=>t.toggleSorting(void 0),children:[e,ir(t.getIsSorted())]})}),cell:({row:t})=>a.jsx("div",{className:"tw-flex tw-justify-end",children:t.getValue("count")})}),Rr=(e,t,n,r,o,s)=>{let i=[...n];e.forEach(c=>{t==="approved"?i.includes(c)||i.push(c):i=i.filter(d=>d!==c)}),r(i);let l=[...o];e.forEach(c=>{t==="unapproved"?l.includes(c)||l.push(c):l=l.filter(d=>d!==c)}),s(l)},yc=(e,t,n,r,o)=>({accessorKey:"status",header:({column:s})=>a.jsx("div",{className:"tw-flex tw-justify-center",children:a.jsxs(fe,{variant:"ghost",onClick:()=>s.toggleSorting(void 0),children:[e,ir(s.getIsSorted())]})}),cell:({row:s})=>{const i=s.getValue("status"),l=s.getValue("item");return a.jsxs(fo,{value:i,variant:"outline",type:"single",children:[a.jsx(wn,{onClick:()=>Rr([l],"approved",t,n,r,o),value:"approved",children:a.jsx(ee.CircleCheckIcon,{})}),a.jsx(wn,{onClick:()=>Rr([l],"unapproved",t,n,r,o),value:"unapproved",children:a.jsx(ee.CircleXIcon,{})}),a.jsx(wn,{onClick:()=>Rr([l],"unknown",t,n,r,o),value:"unknown",children:a.jsx(ee.CircleHelpIcon,{})})]})}}),Nc=Object.freeze(["%webView_inventory_all%","%webView_inventory_approved%","%webView_inventory_unapproved%","%webView_inventory_unknown%","%webView_inventory_scope_currentBook%","%webView_inventory_scope_chapter%","%webView_inventory_scope_verse%","%webView_inventory_filter_text%","%webView_inventory_show_additional_items%","%webView_inventory_occurrences_table_header_reference%","%webView_inventory_occurrences_table_header_occurrence%"]),kc=(e,t,n)=>{let r=e;return t!=="all"&&(r=r.filter(o=>t==="approved"&&o.status==="approved"||t==="unapproved"&&o.status==="unapproved"||t==="unknown"&&o.status==="unknown")),n!==""&&(r=r.filter(o=>o.items[0].includes(n))),r},Sc=(e,t,n,r,o)=>{if(!e)return[];const s=[];let i=t.bookNum,l=t.chapterNum,c=t.verseNum;return Cs(e).forEach(u=>{u.startsWith("\\id")&&(i=Rs(u),l=0,c=0),u.startsWith("\\c")&&(l=qr(u),c=0),u.startsWith("\\v")&&(c=qr(u),l===0&&(l=t.chapterNum));let f=o.exec(u)??void 0;for(;f;){const w=[];f.forEach(h=>w.push(h));const b=f.index,x=s.find(h=>W.deepEqual(h.items,w)),m={reference:{bookNum:i!==void 0?i:-1,chapterNum:l!==void 0?l:-1,verseNum:c!==void 0?c:-1},text:W.substring(u,Math.max(0,b-25),Math.min(b+25,u.length))};if(x)x.count+=1,x.occurrences.push(m);else{const h={items:w,count:1,status:Os(w[0],n,r),occurrences:[m]};s.push(h)}f=o.exec(u)??void 0}}),s},Je=(e,t)=>e[t]??t;function Ec({scriptureReference:e,setScriptureReference:t,localizedStrings:n,extractItems:r,additionalItemsLabels:o,approvedItems:s,unapprovedItems:i,text:l,scope:c,onScopeChange:d,columns:u}){const f=Je(n,"%webView_inventory_all%"),w=Je(n,"%webView_inventory_approved%"),b=Je(n,"%webView_inventory_unapproved%"),x=Je(n,"%webView_inventory_unknown%"),m=Je(n,"%webView_inventory_scope_currentBook%"),h=Je(n,"%webView_inventory_scope_chapter%"),E=Je(n,"%webView_inventory_scope_verse%"),I=Je(n,"%webView_inventory_filter_text%"),C=Je(n,"%webView_inventory_show_additional_items%"),[S,v]=g.useState(!1),[_,V]=g.useState("all"),[U,j]=g.useState(""),[O,k]=g.useState([]),D=g.useMemo(()=>l?r instanceof RegExp?Sc(l,e,s,i,r):r(l,e,s,i):[],[l,r,e,s,i]),M=g.useMemo(()=>{if(S)return D;const y=[];return D.forEach(T=>{const z=T.items[0],L=y.find(B=>B.items[0]===z);L?(L.count+=T.count,L.occurrences=L.occurrences.concat(T.occurrences)):y.push({items:[z],count:T.count,occurrences:T.occurrences,status:T.status})}),y},[S,D]),J=g.useMemo(()=>kc(M,_,U),[M,_,U]),X=g.useMemo(()=>{var z,L;if(!S)return u;const y=(z=o==null?void 0:o.tableHeaders)==null?void 0:z.length;if(!y)return u;const T=[];for(let B=0;B{k([])},[J]);const F=(y,T)=>{T.setRowSelection(()=>{const z={};return z[y.index]=!0,z}),k(y.original.items)},te=y=>{if(y==="book"||y==="chapter"||y==="verse")d(y);else throw new Error(`Invalid scope value: ${y}`)},se=y=>{if(y==="all"||y==="approved"||y==="unapproved"||y==="unknown")V(y);else throw new Error(`Invalid status filter value: ${y}`)},oe=g.useMemo(()=>{if(M.length===0||O.length===0)return[];const y=M.filter(T=>W.deepEqual(S?T.items:[T.items[0]],O));if(y.length>1)throw new Error("Selected item is not unique");return y[0].occurrences},[O,S,M]);return a.jsxs("div",{className:"pr-twp tw-flex tw-h-full tw-flex-col",children:[a.jsxs("div",{className:"tw-flex tw-items-stretch",children:[a.jsxs(At,{onValueChange:y=>se(y),defaultValue:_,children:[a.jsx(bt,{className:"tw-m-1",children:a.jsx(Bt,{placeholder:"Select filter"})}),a.jsxs(vt,{children:[a.jsx(De,{value:"all",children:f}),a.jsx(De,{value:"approved",children:w}),a.jsx(De,{value:"unapproved",children:b}),a.jsx(De,{value:"unknown",children:x})]})]}),a.jsxs(At,{onValueChange:y=>te(y),defaultValue:c,children:[a.jsx(bt,{className:"tw-m-1",children:a.jsx(Bt,{placeholder:"Select scope"})}),a.jsxs(vt,{children:[a.jsx(De,{value:"book",children:m}),a.jsx(De,{value:"chapter",children:h}),a.jsx(De,{value:"verse",children:E})]})]}),a.jsx(St,{className:"tw-m-1 tw-rounded-md tw-border",placeholder:I,value:U,onChange:y=>{j(y.target.value)}}),o&&a.jsxs("div",{className:"tw-m-1 tw-flex tw-items-center tw-rounded-md tw-border",children:[a.jsx(sr,{className:"tw-m-1",checked:S,onCheckedChange:y=>{k([]),v(y)}}),a.jsx(Ue,{className:"tw-m-1 tw-flex-shrink-0 tw-whitespace-nowrap",children:(o==null?void 0:o.checkboxText)??C})]})]}),a.jsx("div",{className:"tw-m-1 tw-flex-1 tw-overflow-auto tw-rounded-md tw-border",children:a.jsx(Ts,{columns:X,data:J,onRowClickHandler:F,stickyHeader:!0})}),oe.length>0&&a.jsx("div",{className:"tw-m-1 tw-flex-1 tw-overflow-auto tw-rounded-md tw-border",children:a.jsx(hc,{occurrenceData:oe,setScriptureReference:t,localizedStrings:n})})]})}function mo({className:e,onSearch:t,placeholder:n,isFullWidth:r}){const[o,s]=g.useState(""),i=l=>{s(l),t(l)};return a.jsx(St,{className:N("tw-flex tw-h-10 tw-rounded-md tw-border tw-border-input tw-bg-background tw-px-3 tw-py-2 tw-text-sm tw-ring-offset-background file:tw-border-0 file:tw-bg-transparent file:tw-text-sm file:tw-font-medium placeholder:tw-text-muted-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-[color:hsl(240,5%,64.9%)] focus-visible:tw-ring-offset-2 disabled:tw-cursor-not-allowed disabled:tw-opacity-50",{"tw-w-full":r},e),placeholder:n,value:o,onChange:l=>i(l.target.value)})}const ho=g.forwardRef(({className:e,...t},n)=>a.jsx(Re.Root,{orientation:"vertical",ref:n,className:N("tw-flex tw-gap-1 tw-rounded-md tw-text-muted-foreground",e),...t}));ho.displayName=Re.List.displayName;const go=g.forwardRef(({className:e,...t},n)=>a.jsx(Re.List,{ref:n,className:N("tw-flex-fit tw-mlk-items-center tw-w-[124px] tw-justify-center tw-rounded-md tw-bg-muted tw-p-1 tw-text-muted-foreground",e),...t}));go.displayName=Re.List.displayName;const Is=g.forwardRef(({className:e,...t},n)=>a.jsx(Re.Trigger,{ref:n,...t,className:N("overflow-clip tw-inline-flex tw-w-[116px] tw-cursor-pointer tw-items-center tw-justify-center tw-break-words tw-rounded-sm tw-border-0 tw-bg-muted tw-px-3 tw-py-1.5 tw-text-sm tw-font-medium tw-text-inherit tw-ring-offset-background tw-transition-all hover:tw-text-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50 data-[state=active]:tw-bg-background data-[state=active]:tw-text-foreground data-[state=active]:tw-shadow-sm",e)})),bo=g.forwardRef(({className:e,...t},n)=>a.jsx(Re.Content,{ref:n,className:N("tw-ms-5 tw-flex-grow tw-text-foreground tw-ring-offset-background focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2",e),...t}));bo.displayName=Re.Content.displayName;function jc({tabList:e,onSearch:t,searchPlaceholder:n,headerTitle:r,isSearchBarFullWidth:o=!1,direction:s="ltr"}){return a.jsxs("div",{className:"pr-twp",children:[a.jsxs("div",{className:"tw-sticky tw-top-0 tw-space-y-2 tw-pb-2",children:[r?a.jsx("h1",{children:r}):"",a.jsx(mo,{isFullWidth:o,onSearch:t,placeholder:n})]}),a.jsxs(ho,{dir:s,children:[a.jsx(go,{children:e.map(i=>a.jsx(Is,{value:i.value,children:i.value},i.key))}),e.map(i=>a.jsx(bo,{value:i.value,children:i.content},i.key))]})]})}const lr=g.forwardRef(({className:e,orientation:t="horizontal",decorative:n=!0,...r},o)=>a.jsx(ts.Root,{ref:o,decorative:n,orientation:t,className:N("pr-twp tw-shrink-0 tw-bg-border",t==="horizontal"?"tw-h-[1px] tw-w-full":"tw-h-full tw-w-[1px]",e),...r}));lr.displayName=ts.Root.displayName;function aa({className:e,...t}){return a.jsx("div",{className:N("pr-twp tw-animate-pulse tw-rounded-md tw-bg-muted",e),...t})}const Tc=Sn.Provider,Cc=Sn.Root,Rc=Sn.Trigger,Ms=g.forwardRef(({className:e,sideOffset:t=4,...n},r)=>a.jsx(Sn.Content,{ref:r,sideOffset:t,className:N("pr-twp tw-z-50 tw-overflow-hidden tw-rounded-md tw-border tw-bg-popover tw-px-3 tw-py-1.5 tw-text-sm tw-text-popover-foreground tw-shadow-md tw-animate-in tw-fade-in-0 tw-zoom-in-95 data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=closed]:tw-zoom-out-95 data-[side=bottom]:tw-slide-in-from-top-2 data-[side=left]:tw-slide-in-from-right-2 data-[side=right]:tw-slide-in-from-left-2 data-[side=top]:tw-slide-in-from-bottom-2",e),...n}));Ms.displayName=Sn.Content.displayName;const Oc="16rem",_c="3rem",Pc="b",$s=g.createContext(void 0);function cr(){const e=g.useContext($s);if(!e)throw new Error("useSidebar must be used within a SidebarProvider.");return e}const Ds=g.forwardRef(({defaultOpen:e=!0,open:t,onOpenChange:n,className:r,style:o,children:s,...i},l)=>{const[c,d]=g.useState(e),u=t??c,f=g.useCallback(m=>{const h=typeof m=="function"?m(u):m;n?n(h):d(h)},[n,u]),w=g.useCallback(()=>f(m=>!m),[f]);g.useEffect(()=>{const m=h=>{h.key===Pc&&(h.metaKey||h.ctrlKey)&&(h.preventDefault(),w())};return window.addEventListener("keydown",m),()=>window.removeEventListener("keydown",m)},[w]);const b=u?"expanded":"collapsed",x=g.useMemo(()=>({state:b,open:u,setOpen:f,toggleSidebar:w}),[b,u,f,w]);return a.jsx($s.Provider,{value:x,children:a.jsx(Tc,{delayDuration:0,children:a.jsx("div",{style:{"--sidebar-width":Oc,"--sidebar-width-icon":_c,...o},className:N("tw-group/sidebar-wrapper pr-twp tw-flex tw-w-full has-[[data-variant=inset]]:tw-bg-sidebar",r),ref:l,...i,children:s})})})});Ds.displayName="SidebarProvider";const As=g.forwardRef(({side:e="left",variant:t="sidebar",collapsible:n="offcanvas",className:r,children:o,...s},i)=>{const{state:l}=cr();return n==="none"?a.jsx("div",{className:N("tw-flex tw-h-full tw-w-[--sidebar-width] tw-flex-col tw-bg-sidebar tw-text-sidebar-foreground",r),ref:i,...s,children:o}):a.jsxs("div",{ref:i,className:"tw-group tw-peer tw-hidden tw-text-sidebar-foreground md:tw-block","data-state":l,"data-collapsible":l==="collapsed"?n:"","data-variant":t,"data-side":e,children:[a.jsx("div",{className:N("tw-relative tw-h-svh tw-w-[--sidebar-width] tw-bg-transparent tw-transition-[width] tw-duration-200 tw-ease-linear","group-data-[collapsible=offcanvas]:tw-w-0","group-data-[side=right]:tw-rotate-180",t==="floating"||t==="inset"?"group-data-[collapsible=icon]:tw-w-[calc(var(--sidebar-width-icon)_+_theme(spacing.4))]":"group-data-[collapsible=icon]:tw-w-[--sidebar-width-icon]")}),a.jsx("div",{className:N("tw-absolute tw-inset-y-0 tw-z-10 tw-hidden tw-h-svh tw-w-[--sidebar-width] tw-transition-[left,right,width] tw-duration-200 tw-ease-linear md:tw-flex",e==="left"?"tw-left-0 group-data-[collapsible=offcanvas]:tw-left-[calc(var(--sidebar-width)*-1)]":"tw-right-0 group-data-[collapsible=offcanvas]:tw-right-[calc(var(--sidebar-width)*-1)]",t==="floating"||t==="inset"?"tw-p-2 group-data-[collapsible=icon]:tw-w-[calc(var(--sidebar-width-icon)_+_theme(spacing.4)_+2px)]":"group-data-[collapsible=icon]:tw-w-[--sidebar-width-icon] group-data-[side=left]:tw-border-r group-data-[side=right]:tw-border-l",r),...s,children:a.jsx("div",{"data-sidebar":"sidebar",className:"tw-flex tw-h-full tw-w-full tw-flex-col tw-bg-sidebar group-data-[variant=floating]:tw-rounded-lg group-data-[variant=floating]:tw-border group-data-[variant=floating]:tw-border-sidebar-border group-data-[variant=floating]:tw-shadow",children:o})})]})});As.displayName="Sidebar";const Ic=g.forwardRef(({className:e,onClick:t,...n},r)=>{const{toggleSidebar:o}=cr();return a.jsxs(fe,{ref:r,"data-sidebar":"trigger",variant:"ghost",size:"icon",className:N("tw-h-7 tw-w-7",e),onClick:s=>{t==null||t(s),o()},...n,children:[a.jsx(ee.PanelLeft,{}),a.jsx("span",{className:"tw-sr-only",children:"Toggle Sidebar"})]})});Ic.displayName="SidebarTrigger";const Mc=g.forwardRef(({className:e,...t},n)=>{const{toggleSidebar:r}=cr();return a.jsx("button",{type:"button",ref:n,"data-sidebar":"rail","aria-label":"Toggle Sidebar",tabIndex:-1,onClick:r,title:"Toggle Sidebar",className:N("tw-absolute tw-inset-y-0 tw-z-20 tw-hidden tw-w-4 tw--translate-x-1/2 tw-transition-all tw-ease-linear after:tw-absolute after:tw-inset-y-0 after:tw-left-1/2 after:tw-w-[2px] hover:after:tw-bg-sidebar-border group-data-[side=left]:tw--right-4 group-data-[side=right]:tw-left-0 sm:tw-flex","[[data-side=left]_&]:tw-cursor-w-resize [[data-side=right]_&]:tw-cursor-e-resize","[[data-side=left][data-state=collapsed]_&]:tw-cursor-e-resize [[data-side=right][data-state=collapsed]_&]:tw-cursor-w-resize","group-data-[collapsible=offcanvas]:tw-translate-x-0 group-data-[collapsible=offcanvas]:after:tw-left-full group-data-[collapsible=offcanvas]:hover:tw-bg-sidebar","[[data-side=left][data-collapsible=offcanvas]_&]:tw--right-2","[[data-side=right][data-collapsible=offcanvas]_&]:tw--left-2",e),...t})});Mc.displayName="SidebarRail";const Bs=g.forwardRef(({className:e,...t},n)=>a.jsx("main",{ref:n,className:N("tw-relative tw-flex tw-flex-1 tw-flex-col tw-bg-background","peer-data-[variant=inset]:tw-min-h-[calc(100svh-theme(spacing.4))] md:peer-data-[variant=inset]:tw-m-2 md:peer-data-[state=collapsed]:peer-data-[variant=inset]:tw-ml-2 md:peer-data-[variant=inset]:tw-ml-0 md:peer-data-[variant=inset]:tw-rounded-xl md:peer-data-[variant=inset]:tw-shadow",e),...t}));Bs.displayName="SidebarInset";const $c=g.forwardRef(({className:e,...t},n)=>a.jsx(St,{ref:n,"data-sidebar":"input",className:N("tw-h-8 tw-w-full tw-bg-background tw-shadow-none focus-visible:tw-ring-2 focus-visible:tw-ring-sidebar-ring",e),...t}));$c.displayName="SidebarInput";const Dc=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,"data-sidebar":"header",className:N("tw-flex tw-flex-col tw-gap-2 tw-p-2",e),...t}));Dc.displayName="SidebarHeader";const Ac=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,"data-sidebar":"footer",className:N("tw-flex tw-flex-col tw-gap-2 tw-p-2",e),...t}));Ac.displayName="SidebarFooter";const Bc=g.forwardRef(({className:e,...t},n)=>a.jsx(lr,{ref:n,"data-sidebar":"separator",className:N("tw-mx-2 tw-w-auto tw-bg-sidebar-border",e),...t}));Bc.displayName="SidebarSeparator";const Vs=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,"data-sidebar":"content",className:N("tw-flex tw-min-h-0 tw-flex-1 tw-flex-col tw-gap-2 tw-overflow-auto group-data-[collapsible=icon]:tw-overflow-hidden",e),...t}));Vs.displayName="SidebarContent";const Hr=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,"data-sidebar":"group",className:N("tw-relative tw-flex tw-w-full tw-min-w-0 tw-flex-col tw-p-2",e),...t}));Hr.displayName="SidebarGroup";const Yr=g.forwardRef(({className:e,asChild:t=!1,...n},r)=>{const o=t?Ht.Slot:"div";return a.jsx(o,{ref:r,"data-sidebar":"group-label",className:N("tw-flex tw-h-8 tw-shrink-0 tw-items-center tw-rounded-md tw-px-2 tw-text-xs tw-font-medium tw-text-sidebar-foreground/70 tw-outline-none tw-ring-sidebar-ring tw-transition-[margin,opa] tw-duration-200 tw-ease-linear focus-visible:tw-ring-2 [&>svg]:tw-size-4 [&>svg]:tw-shrink-0","group-data-[collapsible=icon]:tw--mt-8 group-data-[collapsible=icon]:tw-opacity-0",e),...n})});Yr.displayName="SidebarGroupLabel";const Vc=g.forwardRef(({className:e,asChild:t=!1,...n},r)=>{const o=t?Ht.Slot:"button";return a.jsx(o,{ref:r,"data-sidebar":"group-action",className:N("tw-absolute tw-right-3 tw-top-3.5 tw-flex tw-aspect-square tw-w-5 tw-items-center tw-justify-center tw-rounded-md tw-p-0 tw-text-sidebar-foreground tw-outline-none tw-ring-sidebar-ring tw-transition-transform hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground focus-visible:tw-ring-2 [&>svg]:tw-size-4 [&>svg]:tw-shrink-0","after:tw-absolute after:tw--inset-2 after:md:tw-hidden","group-data-[collapsible=icon]:tw-hidden",e),...n})});Vc.displayName="SidebarGroupAction";const Xr=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,"data-sidebar":"group-content",className:N("tw-w-full tw-text-sm",e),...t}));Xr.displayName="SidebarGroupContent";const zs=g.forwardRef(({className:e,...t},n)=>a.jsx("ul",{ref:n,"data-sidebar":"menu",className:N("tw-flex tw-w-full tw-min-w-0 tw-flex-col tw-gap-1",e),...t}));zs.displayName="SidebarMenu";const Ls=g.forwardRef(({className:e,...t},n)=>a.jsx("li",{ref:n,"data-sidebar":"menu-item",className:N("tw-group/menu-item tw-relative",e),...t}));Ls.displayName="SidebarMenuItem";const zc=kn.cva("tw-peer/menu-button tw-flex tw-w-full tw-items-center tw-gap-2 tw-overflow-hidden tw-rounded-md tw-p-2 tw-text-left tw-text-sm tw-outline-none tw-ring-sidebar-ring tw-transition-[width,height,padding] hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground focus-visible:tw-ring-2 active:tw-bg-sidebar-accent active:tw-text-sidebar-accent-foreground disabled:tw-pointer-events-none disabled:tw-opacity-50 tw-group-has-[[data-sidebar=menu-action]]/menu-item:pr-8 aria-disabled:tw-pointer-events-none aria-disabled:tw-opacity-50 data-[active=true]:tw-font-medium data-[active=true]:tw-text-sidebar-accent-foreground data-[state=open]:hover:tw-bg-sidebar-accent data-[state=open]:hover:tw-text-sidebar-accent-foreground group-data-[collapsible=icon]:tw-!size-8 group-data-[collapsible=icon]:tw-!p-2 [&>span:last-child]:tw-truncate [&>svg]:tw-size-4 [&>svg]:tw-shrink-0",{variants:{variant:{default:"hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground",outline:"tw-bg-background tw-shadow-[0_0_0_1px_hsl(var(--sidebar-border))] hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground hover:tw-shadow-[0_0_0_1px_hsl(var(--sidebar-accent))]"},size:{default:"tw-h-8 tw-text-sm",sm:"tw-h-7 tw-text-xs",lg:"tw-h-12 tw-text-sm group-data-[collapsible=icon]:tw-!p-0"}},defaultVariants:{variant:"default",size:"default"}}),Fs=g.forwardRef(({asChild:e=!1,isActive:t=!1,variant:n="default",size:r="default",tooltip:o,className:s,...i},l)=>{const c=e?Ht.Slot:"button",{state:d}=cr(),u=a.jsx(c,{ref:l,"data-sidebar":"menu-button","data-size":r,"data-active":t,className:N(zc({variant:n,size:r}),s),...i});return o?(typeof o=="string"&&(o={children:o}),a.jsxs(Cc,{children:[a.jsx(Rc,{asChild:!0,children:u}),a.jsx(Ms,{side:"right",align:"center",hidden:d!=="collapsed",...o})]})):u});Fs.displayName="SidebarMenuButton";const Lc=g.forwardRef(({className:e,asChild:t=!1,showOnHover:n=!1,...r},o)=>{const s=t?Ht.Slot:"button";return a.jsx(s,{ref:o,"data-sidebar":"menu-action",className:N("tw-peer-hover/menu-button:text-sidebar-accent-foreground tw-absolute tw-right-1 tw-top-1.5 tw-flex tw-aspect-square tw-w-5 tw-items-center tw-justify-center tw-rounded-md tw-p-0 tw-text-sidebar-foreground tw-outline-none tw-ring-sidebar-ring tw-transition-transform hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground focus-visible:tw-ring-2 [&>svg]:tw-size-4 [&>svg]:tw-shrink-0","after:tw-absolute after:tw--inset-2 after:md:tw-hidden","tw-peer-data-[size=sm]/menu-button:top-1","tw-peer-data-[size=default]/menu-button:top-1.5","tw-peer-data-[size=lg]/menu-button:top-2.5","group-data-[collapsible=icon]:tw-hidden",n&&"tw-group-focus-within/menu-item:opacity-100 tw-group-hover/menu-item:opacity-100 tw-peer-data-[active=true]/menu-button:text-sidebar-accent-foreground data-[state=open]:tw-opacity-100 md:tw-opacity-0",e),...r})});Lc.displayName="SidebarMenuAction";const Fc=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,"data-sidebar":"menu-badge",className:N("tw-pointer-events-none tw-absolute tw-right-1 tw-flex tw-h-5 tw-min-w-5 tw-select-none tw-items-center tw-justify-center tw-rounded-md tw-px-1 tw-text-xs tw-font-medium tw-tabular-nums tw-text-sidebar-foreground","tw-peer-hover/menu-button:text-sidebar-accent-foreground tw-peer-data-[active=true]/menu-button:text-sidebar-accent-foreground","tw-peer-data-[size=sm]/menu-button:top-1","tw-peer-data-[size=default]/menu-button:top-1.5","tw-peer-data-[size=lg]/menu-button:top-2.5","group-data-[collapsible=icon]:tw-hidden",e),...t}));Fc.displayName="SidebarMenuBadge";const Gc=g.forwardRef(({className:e,showIcon:t=!1,...n},r)=>{const o=g.useMemo(()=>`${Math.floor(Math.random()*40)+50}%`,[]);return a.jsxs("div",{ref:r,"data-sidebar":"menu-skeleton",className:N("tw-flex tw-h-8 tw-items-center tw-gap-2 tw-rounded-md tw-px-2",e),...n,children:[t&&a.jsx(aa,{className:"tw-size-4 tw-rounded-md","data-sidebar":"menu-skeleton-icon"}),a.jsx(aa,{className:"tw-h-4 tw-max-w-[--skeleton-width] tw-flex-1","data-sidebar":"menu-skeleton-text",style:{"--skeleton-width":o}})]})});Gc.displayName="SidebarMenuSkeleton";const Uc=g.forwardRef(({className:e,...t},n)=>a.jsx("ul",{ref:n,"data-sidebar":"menu-sub",className:N("tw-mx-3.5 tw-flex tw-min-w-0 tw-translate-x-px tw-flex-col tw-gap-1 tw-border-l tw-border-sidebar-border tw-px-2.5 tw-py-0.5","group-data-[collapsible=icon]:tw-hidden",e),...t}));Uc.displayName="SidebarMenuSub";const qc=g.forwardRef(({...e},t)=>a.jsx("li",{ref:t,...e}));qc.displayName="SidebarMenuSubItem";const Hc=g.forwardRef(({asChild:e=!1,size:t="md",isActive:n,className:r,...o},s)=>{const i=e?Ht.Slot:"a";return a.jsx(i,{ref:s,"data-sidebar":"menu-sub-button","data-size":t,"data-active":n,className:N("tw-flex tw-h-7 tw-min-w-0 tw--translate-x-px tw-items-center tw-gap-2 tw-overflow-hidden tw-rounded-md tw-px-2 tw-text-sidebar-foreground tw-outline-none tw-ring-sidebar-ring hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground focus-visible:tw-ring-2 active:tw-bg-sidebar-accent active:tw-text-sidebar-accent-foreground disabled:tw-pointer-events-none disabled:tw-opacity-50 aria-disabled:tw-pointer-events-none aria-disabled:tw-opacity-50 [&>span:last-child]:tw-truncate [&>svg]:tw-size-4 [&>svg]:tw-shrink-0 [&>svg]:tw-text-sidebar-accent-foreground","data-[active=true]:tw-bg-sidebar-accent data-[active=true]:tw-text-sidebar-accent-foreground",t==="sm"&&"tw-text-xs",t==="md"&&"tw-text-sm","group-data-[collapsible=icon]:tw-hidden",r),...o})});Hc.displayName="SidebarMenuSubButton";function Gs({id:e,extensionLabels:t,projectOptions:n,handleSelectSidebarItem:r,selectedSidebarItem:o,extensionsSidebarGroupLabel:s,projectsSidebarGroupLabel:i,buttonPlaceholderText:l}){const c=g.useCallback((f,w)=>{r(f,w)},[r]),d=g.useCallback(f=>{const w=n.find(b=>b.projectId===f);return w?w.projectName:f},[n]),u=g.useCallback(f=>!o.projectId&&f===o.label,[o]);return a.jsx(As,{id:e,collapsible:"none",variant:"inset",className:"tw-w-96 tw-gap-2 tw-overflow-y-auto tw-rounded tw-bg-slate-100",children:a.jsxs(Vs,{children:[a.jsxs(Hr,{children:[a.jsx(Yr,{className:"tw-text-sm tw-text-gray-400",children:s}),a.jsx(Xr,{children:a.jsx(zs,{children:t.map(f=>a.jsx(Ls,{children:a.jsx(Fs,{className:N("tw-rounded tw-py-2 tw-text-sm tw-text-gray-500 hover:tw-bg-white hover:tw-text-gray-900 hover:tw-shadow-sm active:tw-bg-white",{"tw-bg-white tw-text-gray-900 tw-shadow-sm":u(f)}),onClick:()=>c(f),isActive:u(f),children:a.jsx("span",{className:"tw-pl-3",children:f})})},f))})})]}),a.jsxs(Hr,{children:[a.jsx(Yr,{className:"tw-text-sm tw-text-gray-400",children:i}),a.jsx(Xr,{className:"tw-pl-3",children:a.jsx(Wn,{popoverContentClassName:"tw-z-[1000]",options:n.flatMap(f=>f.projectId),getOptionLabel:f=>d(f),buttonPlaceholder:l,onChange:f=>{const w=d(f);c(w,f)},value:(o==null?void 0:o.projectId)??void 0})})]})]})})}function Yc({id:e,extensionLabels:t,projectOptions:n,children:r,handleSelectSidebarItem:o,selectedSidebarItem:s,onSearch:i,extensionsSidebarGroupLabel:l,projectsSidebarGroupLabel:c,buttonPlaceholderText:d}){return a.jsxs("div",{className:"tw-box-border tw-flex tw-h-full tw-flex-col tw-p-3",children:[a.jsx("div",{className:"tw-box-border tw-flex tw-items-center tw-justify-center tw-py-4",children:a.jsx(mo,{className:"tw-w-9/12",onSearch:i,placeholder:"Search app settings, extension settings, and project settings"})}),a.jsxs(Ds,{id:e,className:"tw-h-full tw-flex-1 tw-gap-4 tw-overflow-auto",children:[a.jsx(Gs,{extensionLabels:t,projectOptions:n,handleSelectSidebarItem:o,selectedSidebarItem:s,extensionsSidebarGroupLabel:l,projectsSidebarGroupLabel:c,buttonPlaceholderText:d}),a.jsx(Bs,{className:"tw-overflow-y-auto",children:r})]})]})}const rt="scrBook",Xc="scrRef",pt="source",Wc="details",Kc="Scripture Reference",Jc="Scripture Book",Us="Type",Zc="Details";function Qc(e,t){const n=t??!1;return[{accessorFn:r=>`${ae.bookNumberToId(r.start.bookNum)} ${r.start.chapterNum}:${r.start.verseNum}`,id:rt,header:(e==null?void 0:e.scriptureReferenceColumnName)??Kc,cell:r=>{const o=r.row.original;return r.row.getIsGrouped()?ae.bookNumberToEnglishName(o.start.bookNum):r.row.groupingColumnId===rt?W.formatScrRef(o.start):void 0},getGroupingValue:r=>r.start.bookNum,sortingFn:(r,o)=>W.compareScrRefs(r.original.start,o.original.start),enableGrouping:!0},{accessorFn:r=>W.formatScrRef(r.start),id:Xc,header:void 0,cell:r=>{const o=r.row.original;return r.row.getIsGrouped()?void 0:W.formatScrRef(o.start)},sortingFn:(r,o)=>W.compareScrRefs(r.original.start,o.original.start),enableGrouping:!1},{accessorFn:r=>r.source.displayName,id:pt,header:n?(e==null?void 0:e.typeColumnName)??Us:void 0,cell:r=>n||r.row.getIsGrouped()?r.getValue():void 0,getGroupingValue:r=>r.source.id,sortingFn:(r,o)=>r.original.source.displayName.localeCompare(o.original.source.displayName),enableGrouping:!0},{accessorFn:r=>r.detail,id:Wc,header:(e==null?void 0:e.detailsColumnName)??Zc,cell:r=>r.getValue(),enableGrouping:!1}]}const ed=e=>{if(!("offset"in e.start))throw new Error("No offset available in range start");if(e.end&&!("offset"in e.end))throw new Error("No offset available in range end");const{offset:t}=e.start;let n=0;return e.end&&({offset:n}=e.end),!e.end||W.compareScrRefs(e.start,e.end)===0?`${W.scrRefToBBBCCCVVV(e.start)}+${t}`:`${W.scrRefToBBBCCCVVV(e.start)}+${t}-${W.scrRefToBBBCCCVVV(e.end)}+${n}`},sa=e=>`${ed({start:e.start,end:e.end})} ${e.source.displayName} ${e.detail}`;function td({sources:e,showColumnHeaders:t=!1,showSourceColumn:n=!1,scriptureReferenceColumnName:r,scriptureBookGroupName:o,typeColumnName:s,detailsColumnName:i,onRowSelected:l,direction:c="ltr"}){const[d,u]=g.useState([]),[f,w]=g.useState([{id:rt,desc:!1}]),[b,x]=g.useState({}),m=g.useMemo(()=>e.flatMap(j=>j.data.map(O=>({...O,source:j.source}))),[e]),h=g.useMemo(()=>Qc({scriptureReferenceColumnName:r,typeColumnName:s,detailsColumnName:i},n),[r,s,i,n]);g.useEffect(()=>{d.includes(pt)?w([{id:pt,desc:!1},{id:rt,desc:!1}]):w([{id:rt,desc:!1}])},[d]);const E=ke.useReactTable({data:m,columns:h,state:{grouping:d,sorting:f,rowSelection:b},onGroupingChange:u,onSortingChange:w,onRowSelectionChange:x,getExpandedRowModel:ke.getExpandedRowModel(),getGroupedRowModel:ke.getGroupedRowModel(),getCoreRowModel:ke.getCoreRowModel(),getSortedRowModel:ke.getSortedRowModel(),getRowId:sa,autoResetExpanded:!1,enableMultiRowSelection:!1,enableSubRowSelection:!1});g.useEffect(()=>{if(l){const j=E.getSelectedRowModel().rowsById,O=Object.keys(j);if(O.length===1){const k=m.find(D=>sa(D)===O[0])||void 0;k&&l(k)}}},[b,m,l,E]);const I=o??Jc,C=s??Us,S=[{label:"No Grouping",value:[]},{label:`Group by ${I}`,value:[rt]},{label:`Group by ${C}`,value:[pt]},{label:`Group by ${I} and ${C}`,value:[rt,pt]},{label:`Group by ${C} and ${I}`,value:[pt,rt]}],v=j=>{u(JSON.parse(j))},_=(j,O)=>{!j.getIsGrouped()&&!j.getIsSelected()&&j.getToggleSelectedHandler()(O)},V=(j,O)=>j.getIsGrouped()?"":N("banded-row",O%2===0?"even":"odd"),U=(j,O,k)=>{if(!((j==null?void 0:j.length)===0||O.depth{v(j)},children:[a.jsx(bt,{className:"tw-mb-1 tw-mt-2",children:a.jsx(Bt,{})}),a.jsx(vt,{position:"item-aligned",children:a.jsx(Ns,{children:S.map(j=>a.jsx(De,{value:JSON.stringify(j.value),children:j.label},j.label))})})]}),a.jsxs(Tn,{className:"tw-relative tw-flex tw-flex-col tw-overflow-y-auto tw-p-0",children:[t&&a.jsx(Cn,{children:E.getHeaderGroups().map(j=>a.jsx(Ze,{children:j.headers.filter(O=>O.column.columnDef.header).map(O=>a.jsx(Vt,{colSpan:O.colSpan,className:"top-0 tw-sticky",children:O.isPlaceholder?void 0:a.jsxs("div",{children:[O.column.getCanGroup()?a.jsx(fe,{variant:"ghost",title:`Toggle grouping by ${O.column.columnDef.header}`,onClick:O.column.getToggleGroupingHandler(),type:"button",children:O.column.getIsGrouped()?"🛑":"👊 "}):void 0," ",ke.flexRender(O.column.columnDef.header,O.getContext())]})},O.id))},j.id))}),a.jsx(Rn,{children:E.getRowModel().rows.map((j,O)=>a.jsx(Ze,{"data-state":j.getIsSelected()?"selected":"",className:N(V(j,O)),onClick:k=>_(j,k),children:j.getVisibleCells().map(k=>{if(!(k.getIsPlaceholder()||k.column.columnDef.enableGrouping&&!k.getIsGrouped()&&(k.column.columnDef.id!==pt||!n)))return a.jsx(xt,{className:N(k.column.columnDef.id,"tw-p-[1px]",U(d,j,k)),children:(()=>k.getIsGrouped()?a.jsxs(fe,{variant:"link",onClick:j.getToggleExpandedHandler(),type:"button",children:[j.getIsExpanded()&&a.jsx(ee.ChevronDown,{}),!j.getIsExpanded()&&(c==="ltr"?a.jsx(ee.ChevronRight,{}):a.jsx(ee.ChevronLeft,{}))," ",ke.flexRender(k.column.columnDef.cell,k.getContext())," (",j.subRows.length,")"]}):ke.flexRender(k.column.columnDef.cell,k.getContext()))()},k.id)})},j.id))})]})]})}const Or={[W.getLocalizeKeyForScrollGroupId("undefined")]:"Ø",[W.getLocalizeKeyForScrollGroupId(0)]:"A",[W.getLocalizeKeyForScrollGroupId(1)]:"B",[W.getLocalizeKeyForScrollGroupId(2)]:"C",[W.getLocalizeKeyForScrollGroupId(3)]:"D",[W.getLocalizeKeyForScrollGroupId(4)]:"E",[W.getLocalizeKeyForScrollGroupId(5)]:"F",[W.getLocalizeKeyForScrollGroupId(6)]:"G",[W.getLocalizeKeyForScrollGroupId(7)]:"H",[W.getLocalizeKeyForScrollGroupId(8)]:"I",[W.getLocalizeKeyForScrollGroupId(9)]:"J",[W.getLocalizeKeyForScrollGroupId(10)]:"K",[W.getLocalizeKeyForScrollGroupId(11)]:"L",[W.getLocalizeKeyForScrollGroupId(12)]:"M",[W.getLocalizeKeyForScrollGroupId(13)]:"N",[W.getLocalizeKeyForScrollGroupId(14)]:"O",[W.getLocalizeKeyForScrollGroupId(15)]:"P",[W.getLocalizeKeyForScrollGroupId(16)]:"Q",[W.getLocalizeKeyForScrollGroupId(17)]:"R",[W.getLocalizeKeyForScrollGroupId(18)]:"S",[W.getLocalizeKeyForScrollGroupId(19)]:"T",[W.getLocalizeKeyForScrollGroupId(20)]:"U",[W.getLocalizeKeyForScrollGroupId(21)]:"V",[W.getLocalizeKeyForScrollGroupId(22)]:"W",[W.getLocalizeKeyForScrollGroupId(23)]:"X",[W.getLocalizeKeyForScrollGroupId(24)]:"Y",[W.getLocalizeKeyForScrollGroupId(25)]:"Z"};function nd({availableScrollGroupIds:e,scrollGroupId:t,onChangeScrollGroupId:n,localizedStrings:r={}}){const o={...Or,...Object.fromEntries(Object.entries(r).map(([s,i])=>[s,s===i&&s in Or?Or[s]:i]))};return a.jsxs(At,{value:`${t}`,onValueChange:s=>n(s==="undefined"?void 0:parseInt(s,10)),children:[a.jsx(bt,{className:"pr-twp tw-w-auto",children:a.jsx(Bt,{placeholder:o[W.getLocalizeKeyForScrollGroupId(t)]??t})}),a.jsx(vt,{style:{zIndex:250},children:e.map(s=>a.jsx(De,{value:`${s}`,children:o[W.getLocalizeKeyForScrollGroupId(s)]},`${s}`))})]})}function rd({children:e}){return a.jsx("div",{className:"pr-twp tw-grid",children:e})}function od({primary:e,secondary:t,children:n,isLoading:r=!1,loadingMessage:o}){return a.jsxs("div",{className:"tw-flex tw-items-center tw-justify-between tw-space-x-4 tw-py-2",children:[a.jsxs("div",{children:[a.jsx("p",{className:"tw-text-sm tw-font-medium tw-leading-none",children:e}),a.jsx("p",{className:"tw-whitespace-normal tw-break-words tw-text-sm tw-text-muted-foreground",children:t})]}),r?a.jsx("p",{className:"tw-text-sm tw-text-muted-foreground",children:o}):a.jsx("div",{children:n})]})}function ad({primary:e,secondary:t,includeSeparator:n=!1}){return a.jsxs("div",{className:"tw-space-y-4 tw-py-2",children:[a.jsxs("div",{children:[a.jsx("h3",{className:"tw-text-lg tw-font-medium",children:e}),a.jsx("p",{className:"tw-text-sm tw-text-muted-foreground",children:t})]}),n?a.jsx(lr,{}):""]})}function sd({id:e,className:t,listItems:n,selectedListItems:r,handleSelectListItem:o,createLabel:s}){return a.jsx("div",{id:e,className:t,children:n.map(i=>a.jsxs("div",{className:"tw-m-2 tw-flex tw-items-center",children:[a.jsx(sr,{className:"tw-mr-2 tw-align-middle",checked:r.includes(i),onCheckedChange:l=>o(i,l)}),a.jsx(Ue,{children:s?s(i):i})]},i))})}function id(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}function ld(e){if(e.__esModule)return e;var t=e.default;if(typeof t=="function"){var n=function r(){return this instanceof r?Reflect.construct(t,arguments,this.constructor):t.apply(this,arguments)};n.prototype=t.prototype}else n={};return Object.defineProperty(n,"__esModule",{value:!0}),Object.keys(e).forEach(function(r){var o=Object.getOwnPropertyDescriptor(e,r);Object.defineProperty(n,r,o.get?o:{enumerable:!0,get:function(){return e[r]}})}),n}var vo={},qs={exports:{}};(function(e){function t(n){return n&&n.__esModule?n:{default:n}}e.exports=t,e.exports.__esModule=!0,e.exports.default=e.exports})(qs);var cd=qs.exports,_r={};function xo(e,t){return process.env.NODE_ENV==="production"?()=>null:function(...r){return e(...r)||t(...r)}}function R(){return R=Object.assign?Object.assign.bind():function(e){for(var t=1;t{t[n]=Hs(e[n])}),t}function Qe(e,t,n={clone:!0}){const r=n.clone?R({},e):e;return mt(e)&&mt(t)&&Object.keys(t).forEach(o=>{o!=="__proto__"&&(mt(t[o])&&o in e&&mt(e[o])?r[o]=Qe(e[o],t[o],n):n.clone?r[o]=mt(t[o])?Hs(t[o]):t[o]:r[o]=t[o])}),r}var Wr={exports:{}},zn={exports:{}},ie={};/** @license React v16.13.1 * react-is.production.min.js * * Copyright (c) Facebook, Inc. and its affiliates. * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. - */var la;function Nd(){if(la)return ie;la=1;var e=typeof Symbol=="function"&&Symbol.for,t=e?Symbol.for("react.element"):60103,n=e?Symbol.for("react.portal"):60106,r=e?Symbol.for("react.fragment"):60107,o=e?Symbol.for("react.strict_mode"):60108,s=e?Symbol.for("react.profiler"):60114,i=e?Symbol.for("react.provider"):60109,l=e?Symbol.for("react.context"):60110,c=e?Symbol.for("react.async_mode"):60111,d=e?Symbol.for("react.concurrent_mode"):60111,u=e?Symbol.for("react.forward_ref"):60112,f=e?Symbol.for("react.suspense"):60113,w=e?Symbol.for("react.suspense_list"):60120,b=e?Symbol.for("react.memo"):60115,x=e?Symbol.for("react.lazy"):60116,m=e?Symbol.for("react.block"):60121,h=e?Symbol.for("react.fundamental"):60117,S=e?Symbol.for("react.responder"):60118,R=e?Symbol.for("react.scope"):60119;function j(v){if(typeof v=="object"&&v!==null){var P=v.$$typeof;switch(P){case t:switch(v=v.type,v){case c:case d:case r:case s:case o:case f:return v;default:switch(v=v&&v.$$typeof,v){case l:case u:case x:case b:case i:return v;default:return P}}case n:return P}}}function E(v){return j(v)===d}return ie.AsyncMode=c,ie.ConcurrentMode=d,ie.ContextConsumer=l,ie.ContextProvider=i,ie.Element=t,ie.ForwardRef=u,ie.Fragment=r,ie.Lazy=x,ie.Memo=b,ie.Portal=n,ie.Profiler=s,ie.StrictMode=o,ie.Suspense=f,ie.isAsyncMode=function(v){return E(v)||j(v)===c},ie.isConcurrentMode=E,ie.isContextConsumer=function(v){return j(v)===l},ie.isContextProvider=function(v){return j(v)===i},ie.isElement=function(v){return typeof v=="object"&&v!==null&&v.$$typeof===t},ie.isForwardRef=function(v){return j(v)===u},ie.isFragment=function(v){return j(v)===r},ie.isLazy=function(v){return j(v)===x},ie.isMemo=function(v){return j(v)===b},ie.isPortal=function(v){return j(v)===n},ie.isProfiler=function(v){return j(v)===s},ie.isStrictMode=function(v){return j(v)===o},ie.isSuspense=function(v){return j(v)===f},ie.isValidElementType=function(v){return typeof v=="string"||typeof v=="function"||v===r||v===d||v===s||v===o||v===f||v===w||typeof v=="object"&&v!==null&&(v.$$typeof===x||v.$$typeof===b||v.$$typeof===i||v.$$typeof===l||v.$$typeof===u||v.$$typeof===h||v.$$typeof===S||v.$$typeof===R||v.$$typeof===m)},ie.typeOf=j,ie}var le={};/** @license React v16.13.1 + */var ia;function dd(){if(ia)return ie;ia=1;var e=typeof Symbol=="function"&&Symbol.for,t=e?Symbol.for("react.element"):60103,n=e?Symbol.for("react.portal"):60106,r=e?Symbol.for("react.fragment"):60107,o=e?Symbol.for("react.strict_mode"):60108,s=e?Symbol.for("react.profiler"):60114,i=e?Symbol.for("react.provider"):60109,l=e?Symbol.for("react.context"):60110,c=e?Symbol.for("react.async_mode"):60111,d=e?Symbol.for("react.concurrent_mode"):60111,u=e?Symbol.for("react.forward_ref"):60112,f=e?Symbol.for("react.suspense"):60113,w=e?Symbol.for("react.suspense_list"):60120,b=e?Symbol.for("react.memo"):60115,x=e?Symbol.for("react.lazy"):60116,m=e?Symbol.for("react.block"):60121,h=e?Symbol.for("react.fundamental"):60117,E=e?Symbol.for("react.responder"):60118,I=e?Symbol.for("react.scope"):60119;function C(v){if(typeof v=="object"&&v!==null){var _=v.$$typeof;switch(_){case t:switch(v=v.type,v){case c:case d:case r:case s:case o:case f:return v;default:switch(v=v&&v.$$typeof,v){case l:case u:case x:case b:case i:return v;default:return _}}case n:return _}}}function S(v){return C(v)===d}return ie.AsyncMode=c,ie.ConcurrentMode=d,ie.ContextConsumer=l,ie.ContextProvider=i,ie.Element=t,ie.ForwardRef=u,ie.Fragment=r,ie.Lazy=x,ie.Memo=b,ie.Portal=n,ie.Profiler=s,ie.StrictMode=o,ie.Suspense=f,ie.isAsyncMode=function(v){return S(v)||C(v)===c},ie.isConcurrentMode=S,ie.isContextConsumer=function(v){return C(v)===l},ie.isContextProvider=function(v){return C(v)===i},ie.isElement=function(v){return typeof v=="object"&&v!==null&&v.$$typeof===t},ie.isForwardRef=function(v){return C(v)===u},ie.isFragment=function(v){return C(v)===r},ie.isLazy=function(v){return C(v)===x},ie.isMemo=function(v){return C(v)===b},ie.isPortal=function(v){return C(v)===n},ie.isProfiler=function(v){return C(v)===s},ie.isStrictMode=function(v){return C(v)===o},ie.isSuspense=function(v){return C(v)===f},ie.isValidElementType=function(v){return typeof v=="string"||typeof v=="function"||v===r||v===d||v===s||v===o||v===f||v===w||typeof v=="object"&&v!==null&&(v.$$typeof===x||v.$$typeof===b||v.$$typeof===i||v.$$typeof===l||v.$$typeof===u||v.$$typeof===h||v.$$typeof===E||v.$$typeof===I||v.$$typeof===m)},ie.typeOf=C,ie}var le={};/** @license React v16.13.1 * react-is.development.js * * Copyright (c) Facebook, Inc. and its affiliates. * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. - */var ca;function kd(){return ca||(ca=1,process.env.NODE_ENV!=="production"&&function(){var e=typeof Symbol=="function"&&Symbol.for,t=e?Symbol.for("react.element"):60103,n=e?Symbol.for("react.portal"):60106,r=e?Symbol.for("react.fragment"):60107,o=e?Symbol.for("react.strict_mode"):60108,s=e?Symbol.for("react.profiler"):60114,i=e?Symbol.for("react.provider"):60109,l=e?Symbol.for("react.context"):60110,c=e?Symbol.for("react.async_mode"):60111,d=e?Symbol.for("react.concurrent_mode"):60111,u=e?Symbol.for("react.forward_ref"):60112,f=e?Symbol.for("react.suspense"):60113,w=e?Symbol.for("react.suspense_list"):60120,b=e?Symbol.for("react.memo"):60115,x=e?Symbol.for("react.lazy"):60116,m=e?Symbol.for("react.block"):60121,h=e?Symbol.for("react.fundamental"):60117,S=e?Symbol.for("react.responder"):60118,R=e?Symbol.for("react.scope"):60119;function j(I){return typeof I=="string"||typeof I=="function"||I===r||I===d||I===s||I===o||I===f||I===w||typeof I=="object"&&I!==null&&(I.$$typeof===x||I.$$typeof===b||I.$$typeof===i||I.$$typeof===l||I.$$typeof===u||I.$$typeof===h||I.$$typeof===S||I.$$typeof===R||I.$$typeof===m)}function E(I){if(typeof I=="object"&&I!==null){var ye=I.$$typeof;switch(ye){case t:var A=I.type;switch(A){case c:case d:case r:case s:case o:case f:return A;default:var xe=A&&A.$$typeof;switch(xe){case l:case u:case x:case b:case i:return xe;default:return ye}}case n:return ye}}}var v=c,P=d,V=l,U=i,C=t,_=u,k=r,D=x,$=b,J=n,Y=s,F=o,te=f,se=!1;function oe(I){return se||(se=!0,console.warn("The ReactIs.isAsyncMode() alias has been deprecated, and will be removed in React 17+. Update your code to use ReactIs.isConcurrentMode() instead. It has the exact same API.")),y(I)||E(I)===c}function y(I){return E(I)===d}function T(I){return E(I)===l}function z(I){return E(I)===i}function L(I){return typeof I=="object"&&I!==null&&I.$$typeof===t}function B(I){return E(I)===u}function X(I){return E(I)===r}function q(I){return E(I)===x}function H(I){return E(I)===b}function G(I){return E(I)===n}function K(I){return E(I)===s}function Z(I){return E(I)===o}function ue(I){return E(I)===f}le.AsyncMode=v,le.ConcurrentMode=P,le.ContextConsumer=V,le.ContextProvider=U,le.Element=C,le.ForwardRef=_,le.Fragment=k,le.Lazy=D,le.Memo=$,le.Portal=J,le.Profiler=Y,le.StrictMode=F,le.Suspense=te,le.isAsyncMode=oe,le.isConcurrentMode=y,le.isContextConsumer=T,le.isContextProvider=z,le.isElement=L,le.isForwardRef=B,le.isFragment=X,le.isLazy=q,le.isMemo=H,le.isPortal=G,le.isProfiler=K,le.isStrictMode=Z,le.isSuspense=ue,le.isValidElementType=j,le.typeOf=E}()),le}var da;function Ks(){return da||(da=1,process.env.NODE_ENV==="production"?zn.exports=Nd():zn.exports=kd()),zn.exports}/* + */var la;function ud(){return la||(la=1,process.env.NODE_ENV!=="production"&&function(){var e=typeof Symbol=="function"&&Symbol.for,t=e?Symbol.for("react.element"):60103,n=e?Symbol.for("react.portal"):60106,r=e?Symbol.for("react.fragment"):60107,o=e?Symbol.for("react.strict_mode"):60108,s=e?Symbol.for("react.profiler"):60114,i=e?Symbol.for("react.provider"):60109,l=e?Symbol.for("react.context"):60110,c=e?Symbol.for("react.async_mode"):60111,d=e?Symbol.for("react.concurrent_mode"):60111,u=e?Symbol.for("react.forward_ref"):60112,f=e?Symbol.for("react.suspense"):60113,w=e?Symbol.for("react.suspense_list"):60120,b=e?Symbol.for("react.memo"):60115,x=e?Symbol.for("react.lazy"):60116,m=e?Symbol.for("react.block"):60121,h=e?Symbol.for("react.fundamental"):60117,E=e?Symbol.for("react.responder"):60118,I=e?Symbol.for("react.scope"):60119;function C(P){return typeof P=="string"||typeof P=="function"||P===r||P===d||P===s||P===o||P===f||P===w||typeof P=="object"&&P!==null&&(P.$$typeof===x||P.$$typeof===b||P.$$typeof===i||P.$$typeof===l||P.$$typeof===u||P.$$typeof===h||P.$$typeof===E||P.$$typeof===I||P.$$typeof===m)}function S(P){if(typeof P=="object"&&P!==null){var xe=P.$$typeof;switch(xe){case t:var A=P.type;switch(A){case c:case d:case r:case s:case o:case f:return A;default:var ve=A&&A.$$typeof;switch(ve){case l:case u:case x:case b:case i:return ve;default:return xe}}case n:return xe}}}var v=c,_=d,V=l,U=i,j=t,O=u,k=r,D=x,M=b,J=n,X=s,F=o,te=f,se=!1;function oe(P){return se||(se=!0,console.warn("The ReactIs.isAsyncMode() alias has been deprecated, and will be removed in React 17+. Update your code to use ReactIs.isConcurrentMode() instead. It has the exact same API.")),y(P)||S(P)===c}function y(P){return S(P)===d}function T(P){return S(P)===l}function z(P){return S(P)===i}function L(P){return typeof P=="object"&&P!==null&&P.$$typeof===t}function B(P){return S(P)===u}function Y(P){return S(P)===r}function q(P){return S(P)===x}function H(P){return S(P)===b}function G(P){return S(P)===n}function K(P){return S(P)===s}function Z(P){return S(P)===o}function ue(P){return S(P)===f}le.AsyncMode=v,le.ConcurrentMode=_,le.ContextConsumer=V,le.ContextProvider=U,le.Element=j,le.ForwardRef=O,le.Fragment=k,le.Lazy=D,le.Memo=M,le.Portal=J,le.Profiler=X,le.StrictMode=F,le.Suspense=te,le.isAsyncMode=oe,le.isConcurrentMode=y,le.isContextConsumer=T,le.isContextProvider=z,le.isElement=L,le.isForwardRef=B,le.isFragment=Y,le.isLazy=q,le.isMemo=H,le.isPortal=G,le.isProfiler=K,le.isStrictMode=Z,le.isSuspense=ue,le.isValidElementType=C,le.typeOf=S}()),le}var ca;function Ys(){return ca||(ca=1,process.env.NODE_ENV==="production"?zn.exports=dd():zn.exports=ud()),zn.exports}/* object-assign (c) Sindre Sorhus @license MIT -*/var Ir,ua;function Sd(){if(ua)return Ir;ua=1;var e=Object.getOwnPropertySymbols,t=Object.prototype.hasOwnProperty,n=Object.prototype.propertyIsEnumerable;function r(s){if(s==null)throw new TypeError("Object.assign cannot be called with null or undefined");return Object(s)}function o(){try{if(!Object.assign)return!1;var s=new String("abc");if(s[5]="de",Object.getOwnPropertyNames(s)[0]==="5")return!1;for(var i={},l=0;l<10;l++)i["_"+String.fromCharCode(l)]=l;var c=Object.getOwnPropertyNames(i).map(function(u){return i[u]});if(c.join("")!=="0123456789")return!1;var d={};return"abcdefghijklmnopqrst".split("").forEach(function(u){d[u]=u}),Object.keys(Object.assign({},d)).join("")==="abcdefghijklmnopqrst"}catch{return!1}}return Ir=o()?Object.assign:function(s,i){for(var l,c=r(s),d,u=1;u1?s("Invalid arguments supplied to oneOf, expected an array, got "+arguments.length+" arguments. A common mistake is to write oneOf(x, y, z) instead of oneOf([x, y, z])."):s("Invalid argument supplied to oneOf, expected an array.")),i;function T(z,L,B,X,q){for(var H=z[L],G=0;G0?", expected one of type ["+K.join(", ")+"]":"";return new m("Invalid "+H+" `"+G+"` supplied to "+("`"+q+"`"+ye+"."))}return h(L)}function _(){function y(T,z,L,B,X){return J(T[z])?null:new m("Invalid "+B+" `"+X+"` supplied to "+("`"+L+"`, expected a ReactNode."))}return h(y)}function k(y,T,z,L,B){return new m((y||"React class")+": "+T+" type `"+z+"."+L+"` is invalid; it must be a function, usually from the `prop-types` package, but received `"+B+"`.")}function D(y){function T(z,L,B,X,q){var H=z[L],G=F(H);if(G!=="object")return new m("Invalid "+X+" `"+q+"` of type `"+G+"` "+("supplied to `"+B+"`, expected `object`."));for(var K in y){var Z=y[K];if(typeof Z!="function")return k(B,X,q,K,te(Z));var ue=Z(H,K,B,X,q+"."+K,n);if(ue)return ue}return null}return h(T)}function $(y){function T(z,L,B,X,q){var H=z[L],G=F(H);if(G!=="object")return new m("Invalid "+X+" `"+q+"` of type `"+G+"` "+("supplied to `"+B+"`, expected `object`."));var K=t({},z[L],y);for(var Z in K){var ue=y[Z];if(r(y,Z)&&typeof ue!="function")return k(B,X,q,Z,te(ue));if(!ue)return new m("Invalid "+X+" `"+q+"` key `"+Z+"` supplied to `"+B+"`.\nBad object: "+JSON.stringify(z[L],null," ")+` -Valid keys: `+JSON.stringify(Object.keys(y),null," "));var I=ue(H,Z,B,X,q+"."+Z,n);if(I)return I}return null}return h(T)}function J(y){switch(typeof y){case"number":case"string":case"undefined":return!0;case"boolean":return!y;case"object":if(Array.isArray(y))return y.every(J);if(y===null||l(y))return!0;var T=f(y);if(T){var z=T.call(y),L;if(T!==y.entries){for(;!(L=z.next()).done;)if(!J(L.value))return!1}else for(;!(L=z.next()).done;){var B=L.value;if(B&&!J(B[1]))return!1}}else return!1;return!0;default:return!1}}function Y(y,T){return y==="symbol"?!0:T?T["@@toStringTag"]==="Symbol"||typeof Symbol=="function"&&T instanceof Symbol:!1}function F(y){var T=typeof y;return Array.isArray(y)?"array":y instanceof RegExp?"object":Y(T,y)?"symbol":T}function te(y){if(typeof y>"u"||y===null)return""+y;var T=F(y);if(T==="object"){if(y instanceof Date)return"date";if(y instanceof RegExp)return"regexp"}return T}function se(y){var T=te(y);switch(T){case"array":case"object":return"an "+T;case"boolean":case"date":case"regexp":return"a "+T;default:return T}}function oe(y){return!y.constructor||!y.constructor.name?w:y.constructor.name}return b.checkPropTypes=o,b.resetWarningCache=o.resetWarningCache,b.PropTypes=b,b},Ar}var Br,ha;function Cd(){if(ha)return Br;ha=1;var e=No();function t(){}function n(){}return n.resetWarningCache=t,Br=function(){function r(i,l,c,d,u,f){if(f!==e){var w=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types");throw w.name="Invariant Violation",w}}r.isRequired=r;function o(){return r}var s={array:r,bigint:r,bool:r,func:r,number:r,object:r,string:r,symbol:r,any:r,arrayOf:o,element:r,elementType:r,instanceOf:o,node:r,objectOf:o,oneOf:o,oneOfType:o,shape:o,exact:o,checkPropTypes:n,resetWarningCache:t};return s.PropTypes=s,s},Br}if(process.env.NODE_ENV!=="production"){var Td=Ks(),Rd=!0;Kr.exports=jd()(Td.isElement,Rd)}else Kr.exports=Cd()();var Od=Kr.exports;const p=vd(Od);function _d(e){const{prototype:t={}}=e;return!!t.isReactComponent}function Zs(e,t,n,r,o){const s=e[t],i=o||t;if(s==null||typeof window>"u")return null;let l;const c=s.type;return typeof c=="function"&&!_d(c)&&(l="Did you accidentally use a plain function component for an element instead?"),l!==void 0?new Error(`Invalid ${r} \`${i}\` supplied to \`${n}\`. Expected an element that can hold a ref. ${l} For more information see https://mui.com/r/caveat-with-refs-guide`):null}const Qs=yo(p.element,Zs);Qs.isRequired=yo(p.element.isRequired,Zs);const ei=Qs,Pd="exact-prop: ​";function Id(e){return process.env.NODE_ENV==="production"?e:O({},e,{[Pd]:t=>{const n=Object.keys(t).filter(r=>!e.hasOwnProperty(r));return n.length>0?new Error(`The following props are not supported: ${n.map(r=>`\`${r}\``).join(", ")}. Please remove them.`):null}})}function zt(e){let t="https://mui.com/production-error/?code="+e;for(let n=1;n1?s("Invalid arguments supplied to oneOf, expected an array, got "+arguments.length+" arguments. A common mistake is to write oneOf(x, y, z) instead of oneOf([x, y, z])."):s("Invalid argument supplied to oneOf, expected an array.")),i;function T(z,L,B,Y,q){for(var H=z[L],G=0;G0?", expected one of type ["+K.join(", ")+"]":"";return new m("Invalid "+H+" `"+G+"` supplied to "+("`"+q+"`"+xe+"."))}return h(L)}function O(){function y(T,z,L,B,Y){return J(T[z])?null:new m("Invalid "+B+" `"+Y+"` supplied to "+("`"+L+"`, expected a ReactNode."))}return h(y)}function k(y,T,z,L,B){return new m((y||"React class")+": "+T+" type `"+z+"."+L+"` is invalid; it must be a function, usually from the `prop-types` package, but received `"+B+"`.")}function D(y){function T(z,L,B,Y,q){var H=z[L],G=F(H);if(G!=="object")return new m("Invalid "+Y+" `"+q+"` of type `"+G+"` "+("supplied to `"+B+"`, expected `object`."));for(var K in y){var Z=y[K];if(typeof Z!="function")return k(B,Y,q,K,te(Z));var ue=Z(H,K,B,Y,q+"."+K,n);if(ue)return ue}return null}return h(T)}function M(y){function T(z,L,B,Y,q){var H=z[L],G=F(H);if(G!=="object")return new m("Invalid "+Y+" `"+q+"` of type `"+G+"` "+("supplied to `"+B+"`, expected `object`."));var K=t({},z[L],y);for(var Z in K){var ue=y[Z];if(r(y,Z)&&typeof ue!="function")return k(B,Y,q,Z,te(ue));if(!ue)return new m("Invalid "+Y+" `"+q+"` key `"+Z+"` supplied to `"+B+"`.\nBad object: "+JSON.stringify(z[L],null," ")+` +Valid keys: `+JSON.stringify(Object.keys(y),null," "));var P=ue(H,Z,B,Y,q+"."+Z,n);if(P)return P}return null}return h(T)}function J(y){switch(typeof y){case"number":case"string":case"undefined":return!0;case"boolean":return!y;case"object":if(Array.isArray(y))return y.every(J);if(y===null||l(y))return!0;var T=f(y);if(T){var z=T.call(y),L;if(T!==y.entries){for(;!(L=z.next()).done;)if(!J(L.value))return!1}else for(;!(L=z.next()).done;){var B=L.value;if(B&&!J(B[1]))return!1}}else return!1;return!0;default:return!1}}function X(y,T){return y==="symbol"?!0:T?T["@@toStringTag"]==="Symbol"||typeof Symbol=="function"&&T instanceof Symbol:!1}function F(y){var T=typeof y;return Array.isArray(y)?"array":y instanceof RegExp?"object":X(T,y)?"symbol":T}function te(y){if(typeof y>"u"||y===null)return""+y;var T=F(y);if(T==="object"){if(y instanceof Date)return"date";if(y instanceof RegExp)return"regexp"}return T}function se(y){var T=te(y);switch(T){case"array":case"object":return"an "+T;case"boolean":case"date":case"regexp":return"a "+T;default:return T}}function oe(y){return!y.constructor||!y.constructor.name?w:y.constructor.name}return b.checkPropTypes=o,b.resetWarningCache=o.resetWarningCache,b.PropTypes=b,b},Dr}var Ar,ma;function md(){if(ma)return Ar;ma=1;var e=yo();function t(){}function n(){}return n.resetWarningCache=t,Ar=function(){function r(i,l,c,d,u,f){if(f!==e){var w=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types");throw w.name="Invariant Violation",w}}r.isRequired=r;function o(){return r}var s={array:r,bigint:r,bool:r,func:r,number:r,object:r,string:r,symbol:r,any:r,arrayOf:o,element:r,elementType:r,instanceOf:o,node:r,objectOf:o,oneOf:o,oneOfType:o,shape:o,exact:o,checkPropTypes:n,resetWarningCache:t};return s.PropTypes=s,s},Ar}if(process.env.NODE_ENV!=="production"){var hd=Ys(),gd=!0;Wr.exports=fd()(hd.isElement,gd)}else Wr.exports=md()();var bd=Wr.exports;const p=id(bd);function vd(e){const{prototype:t={}}=e;return!!t.isReactComponent}function Ws(e,t,n,r,o){const s=e[t],i=o||t;if(s==null||typeof window>"u")return null;let l;const c=s.type;return typeof c=="function"&&!vd(c)&&(l="Did you accidentally use a plain function component for an element instead?"),l!==void 0?new Error(`Invalid ${r} \`${i}\` supplied to \`${n}\`. Expected an element that can hold a ref. ${l} For more information see https://mui.com/r/caveat-with-refs-guide`):null}const Ks=xo(p.element,Ws);Ks.isRequired=xo(p.element.isRequired,Ws);const Js=Ks,xd="exact-prop: ​";function yd(e){return process.env.NODE_ENV==="production"?e:R({},e,{[xd]:t=>{const n=Object.keys(t).filter(r=>!e.hasOwnProperty(r));return n.length>0?new Error(`The following props are not supported: ${n.map(r=>`\`${r}\``).join(", ")}. Please remove them.`):null}})}function zt(e){let t="https://mui.com/production-error/?code="+e;for(let n=1;nn==null?t:function(...o){t.apply(this,o),n.apply(this,o)},()=>{})}function Ld(e,t=166){let n;function r(...o){const s=()=>{e.apply(this,o)};clearTimeout(n),n=setTimeout(s,t)}return r.clear=()=>{clearTimeout(n)},r}function Fd(e,t){return process.env.NODE_ENV==="production"?()=>null:(n,r,o,s,i)=>{const l=o||"<>",c=i||r;return typeof n[r]<"u"?new Error(`The ${s} \`${c}\` of \`${l}\` is deprecated. ${t}`):null}}function Gd(e,t){var n,r;return M.isValidElement(e)&&t.indexOf((n=e.type.muiName)!=null?n:(r=e.type)==null||(r=r._payload)==null||(r=r.value)==null?void 0:r.muiName)!==-1}function Kn(e){return e&&e.ownerDocument||document}function Ud(e){return Kn(e).defaultView||window}function qd(e,t){if(process.env.NODE_ENV==="production")return()=>null;const n=t?O({},t.propTypes):null;return o=>(s,i,l,c,d,...u)=>{const f=d||i,w=n==null?void 0:n[f];if(w){const b=w(s,i,l,c,d,...u);if(b)return b}return typeof s[i]<"u"&&!s[o]?new Error(`The prop \`${f}\` of \`${e}\` can only be used together with the \`${o}\` prop.`):null}}function Jn(e,t){typeof e=="function"?e(t):e&&(e.current=t)}const Hd=typeof window<"u"?M.useLayoutEffect:M.useEffect,Lt=Hd;let ya=0;function Xd(e){const[t,n]=M.useState(e),r=e||t;return M.useEffect(()=>{t==null&&(ya+=1,n(`mui-${ya}`))},[t]),r}const Na=M["useId".toString()];function ri(e){if(Na!==void 0){const t=Na();return e??t}return Xd(e)}function Yd(e,t,n,r,o){if(process.env.NODE_ENV==="production")return null;const s=o||t;return typeof e[t]<"u"?new Error(`The prop \`${s}\` is not supported. Please remove it.`):null}function oi({controlled:e,default:t,name:n,state:r="value"}){const{current:o}=M.useRef(e!==void 0),[s,i]=M.useState(t),l=o?e:s;if(process.env.NODE_ENV!=="production"){M.useEffect(()=>{o!==(e!==void 0)&&console.error([`MUI: A component is changing the ${o?"":"un"}controlled ${r} state of ${n} to be ${o?"un":""}controlled.`,"Elements should not switch from uncontrolled to controlled (or vice versa).",`Decide between using a controlled or uncontrolled ${n} element for the lifetime of the component.`,"The nature of the state is determined during the first render. It's considered controlled if the value is not `undefined`.","More info: https://fb.me/react-controlled-components"].join(` -`))},[r,n,e]);const{current:d}=M.useRef(t);M.useEffect(()=>{!o&&d!==t&&console.error([`MUI: A component is changing the default ${r} state of an uncontrolled ${n} after being initialized. To suppress this warning opt to use a controlled ${n}.`].join(` -`))},[JSON.stringify(t)])}const c=M.useCallback(d=>{o||i(d)},[]);return[l,c]}function Zr(e){const t=M.useRef(e);return Lt(()=>{t.current=e}),M.useRef((...n)=>(0,t.current)(...n)).current}function yt(...e){return M.useMemo(()=>e.every(t=>t==null)?null:t=>{e.forEach(n=>{Jn(n,t)})},e)}const ka={};function Wd(e,t){const n=M.useRef(ka);return n.current===ka&&(n.current=e(t)),n}const Kd=[];function Jd(e){M.useEffect(e,Kd)}class On{constructor(){this.currentId=null,this.clear=()=>{this.currentId!==null&&(clearTimeout(this.currentId),this.currentId=null)},this.disposeEffect=()=>this.clear}static create(){return new On}start(t,n){this.clear(),this.currentId=setTimeout(()=>{this.currentId=null,n()},t)}}function dn(){const e=Wd(On.create).current;return Jd(e.disposeEffect),e}let dr=!0,Qr=!1;const Zd=new On,Qd={text:!0,search:!0,url:!0,tel:!0,email:!0,password:!0,number:!0,date:!0,month:!0,week:!0,time:!0,datetime:!0,"datetime-local":!0};function eu(e){const{type:t,tagName:n}=e;return!!(n==="INPUT"&&Qd[t]&&!e.readOnly||n==="TEXTAREA"&&!e.readOnly||e.isContentEditable)}function tu(e){e.metaKey||e.altKey||e.ctrlKey||(dr=!0)}function Vr(){dr=!1}function nu(){this.visibilityState==="hidden"&&Qr&&(dr=!0)}function ru(e){e.addEventListener("keydown",tu,!0),e.addEventListener("mousedown",Vr,!0),e.addEventListener("pointerdown",Vr,!0),e.addEventListener("touchstart",Vr,!0),e.addEventListener("visibilitychange",nu,!0)}function ou(e){const{target:t}=e;try{return t.matches(":focus-visible")}catch{}return dr||eu(t)}function ai(){const e=M.useCallback(o=>{o!=null&&ru(o.ownerDocument)},[]),t=M.useRef(!1);function n(){return t.current?(Qr=!0,Zd.start(100,()=>{Qr=!1}),t.current=!1,!0):!1}function r(o){return ou(o)?(t.current=!0,!0):!1}return{isFocusVisibleRef:t,onFocus:r,onBlur:n,ref:e}}function si(e,t){const n=O({},t);return Object.keys(e).forEach(r=>{if(r.toString().match(/^(components|slots)$/))n[r]=O({},e[r],n[r]);else if(r.toString().match(/^(componentsProps|slotProps)$/)){const o=e[r]||{},s=t[r];n[r]={},!s||!Object.keys(s)?n[r]=o:!o||!Object.keys(o)?n[r]=s:(n[r]=O({},s),Object.keys(o).forEach(i=>{n[r][i]=si(o[i],s[i])}))}else n[r]===void 0&&(n[r]=e[r])}),n}function ko(e,t,n=void 0){const r={};return Object.keys(e).forEach(o=>{r[o]=e[o].reduce((s,i)=>{if(i){const l=t(i);l!==""&&s.push(l),n&&n[i]&&s.push(n[i])}return s},[]).join(" ")}),r}const Sa=e=>e,au=()=>{let e=Sa;return{configure(t){e=t},generate(t){return e(t)},reset(){e=Sa}}},su=au(),ii=su,li={active:"active",checked:"checked",completed:"completed",disabled:"disabled",error:"error",expanded:"expanded",focused:"focused",focusVisible:"focusVisible",open:"open",readOnly:"readOnly",required:"required",selected:"selected"};function ur(e,t,n="Mui"){const r=li[t];return r?`${n}-${r}`:`${ii.generate(e)}-${t}`}function ci(e,t,n="Mui"){const r={};return t.forEach(o=>{r[o]=ur(e,o,n)}),r}function iu(e,t=Number.MIN_SAFE_INTEGER,n=Number.MAX_SAFE_INTEGER){return Math.max(t,Math.min(e,n))}function Ne(e,t){if(e==null)return{};var n={},r=Object.keys(e),o,s;for(s=0;s=0)&&(n[o]=e[o]);return n}const lu=["values","unit","step"],cu=e=>{const t=Object.keys(e).map(n=>({key:n,val:e[n]}))||[];return t.sort((n,r)=>n.val-r.val),t.reduce((n,r)=>O({},n,{[r.key]:r.val}),{})};function du(e){const{values:t={xs:0,sm:600,md:900,lg:1200,xl:1536},unit:n="px",step:r=5}=e,o=Ne(e,lu),s=cu(t),i=Object.keys(s);function l(w){return`@media (min-width:${typeof t[w]=="number"?t[w]:w}${n})`}function c(w){return`@media (max-width:${(typeof t[w]=="number"?t[w]:w)-r/100}${n})`}function d(w,b){const x=i.indexOf(b);return`@media (min-width:${typeof t[w]=="number"?t[w]:w}${n}) and (max-width:${(x!==-1&&typeof t[i[x]]=="number"?t[i[x]]:b)-r/100}${n})`}function u(w){return i.indexOf(w)+1`@media (min-width:${So[e]}px)`};function et(e,t,n){const r=e.theme||{};if(Array.isArray(t)){const s=r.breakpoints||Ea;return t.reduce((i,l,c)=>(i[s.up(s.keys[c])]=n(t[c]),i),{})}if(typeof t=="object"){const s=r.breakpoints||Ea;return Object.keys(t).reduce((i,l)=>{if(Object.keys(s.values||So).indexOf(l)!==-1){const c=s.up(l);i[c]=n(t[l],l)}else{const c=l;i[c]=t[c]}return i},{})}return n(t)}function fu(e={}){var t;return((t=e.keys)==null?void 0:t.reduce((r,o)=>{const s=e.up(o);return r[s]={},r},{}))||{}}function mu(e,t){return e.reduce((n,r)=>{const o=n[r];return(!o||Object.keys(o).length===0)&&delete n[r],n},t)}function pr(e,t,n=!0){if(!t||typeof t!="string")return null;if(e&&e.vars&&n){const r=`vars.${t}`.split(".").reduce((o,s)=>o&&o[s]?o[s]:null,e);if(r!=null)return r}return t.split(".").reduce((r,o)=>r&&r[o]!=null?r[o]:null,e)}function Zn(e,t,n,r=n){let o;return typeof e=="function"?o=e(n):Array.isArray(e)?o=e[n]||r:o=pr(e,n)||r,t&&(o=t(o,r,e)),o}function ve(e){const{prop:t,cssProperty:n=e.prop,themeKey:r,transform:o}=e,s=i=>{if(i[t]==null)return null;const l=i[t],c=i.theme,d=pr(c,r)||{};return et(i,l,f=>{let w=Zn(d,o,f);return f===w&&typeof f=="string"&&(w=Zn(d,o,`${t}${f==="default"?"":Ye(f)}`,f)),n===!1?w:{[n]:w}})};return s.propTypes=process.env.NODE_ENV!=="production"?{[t]:st}:{},s.filterProps=[t],s}function hu(e){const t={};return n=>(t[n]===void 0&&(t[n]=e(n)),t[n])}const gu={m:"margin",p:"padding"},bu={t:"Top",r:"Right",b:"Bottom",l:"Left",x:["Left","Right"],y:["Top","Bottom"]},ja={marginX:"mx",marginY:"my",paddingX:"px",paddingY:"py"},vu=hu(e=>{if(e.length>2)if(ja[e])e=ja[e];else return[e];const[t,n]=e.split(""),r=gu[t],o=bu[n]||"";return Array.isArray(o)?o.map(s=>r+s):[r+o]}),wr=["m","mt","mr","mb","ml","mx","my","margin","marginTop","marginRight","marginBottom","marginLeft","marginX","marginY","marginInline","marginInlineStart","marginInlineEnd","marginBlock","marginBlockStart","marginBlockEnd"],fr=["p","pt","pr","pb","pl","px","py","padding","paddingTop","paddingRight","paddingBottom","paddingLeft","paddingX","paddingY","paddingInline","paddingInlineStart","paddingInlineEnd","paddingBlock","paddingBlockStart","paddingBlockEnd"],xu=[...wr,...fr];function _n(e,t,n,r){var o;const s=(o=pr(e,t,!1))!=null?o:n;return typeof s=="number"?i=>typeof i=="string"?i:(process.env.NODE_ENV!=="production"&&typeof i!="number"&&console.error(`MUI: Expected ${r} argument to be a number or a string, got ${i}.`),s*i):Array.isArray(s)?i=>typeof i=="string"?i:(process.env.NODE_ENV!=="production"&&(Number.isInteger(i)?i>s.length-1&&console.error([`MUI: The value provided (${i}) overflows.`,`The supported values are: ${JSON.stringify(s)}.`,`${i} > ${s.length-1}, you need to add the missing values.`].join(` + */var ga;function kd(){return ga||(ga=1,process.env.NODE_ENV!=="production"&&function(){var e=Symbol.for("react.element"),t=Symbol.for("react.portal"),n=Symbol.for("react.fragment"),r=Symbol.for("react.strict_mode"),o=Symbol.for("react.profiler"),s=Symbol.for("react.provider"),i=Symbol.for("react.context"),l=Symbol.for("react.server_context"),c=Symbol.for("react.forward_ref"),d=Symbol.for("react.suspense"),u=Symbol.for("react.suspense_list"),f=Symbol.for("react.memo"),w=Symbol.for("react.lazy"),b=Symbol.for("react.offscreen"),x=!1,m=!1,h=!1,E=!1,I=!1,C;C=Symbol.for("react.module.reference");function S(A){return!!(typeof A=="string"||typeof A=="function"||A===n||A===o||I||A===r||A===d||A===u||E||A===b||x||m||h||typeof A=="object"&&A!==null&&(A.$$typeof===w||A.$$typeof===f||A.$$typeof===s||A.$$typeof===i||A.$$typeof===c||A.$$typeof===C||A.getModuleId!==void 0))}function v(A){if(typeof A=="object"&&A!==null){var ve=A.$$typeof;switch(ve){case e:var Fe=A.type;switch(Fe){case n:case o:case r:case d:case u:return Fe;default:var lt=Fe&&Fe.$$typeof;switch(lt){case l:case i:case c:case w:case f:case s:return lt;default:return ve}}case t:return ve}}}var _=i,V=s,U=e,j=c,O=n,k=w,D=f,M=t,J=o,X=r,F=d,te=u,se=!1,oe=!1;function y(A){return se||(se=!0,console.warn("The ReactIs.isAsyncMode() alias has been deprecated, and will be removed in React 18+.")),!1}function T(A){return oe||(oe=!0,console.warn("The ReactIs.isConcurrentMode() alias has been deprecated, and will be removed in React 18+.")),!1}function z(A){return v(A)===i}function L(A){return v(A)===s}function B(A){return typeof A=="object"&&A!==null&&A.$$typeof===e}function Y(A){return v(A)===c}function q(A){return v(A)===n}function H(A){return v(A)===w}function G(A){return v(A)===f}function K(A){return v(A)===t}function Z(A){return v(A)===o}function ue(A){return v(A)===r}function P(A){return v(A)===d}function xe(A){return v(A)===u}de.ContextConsumer=_,de.ContextProvider=V,de.Element=U,de.ForwardRef=j,de.Fragment=O,de.Lazy=k,de.Memo=D,de.Portal=M,de.Profiler=J,de.StrictMode=X,de.Suspense=F,de.SuspenseList=te,de.isAsyncMode=y,de.isConcurrentMode=T,de.isContextConsumer=z,de.isContextProvider=L,de.isElement=B,de.isForwardRef=Y,de.isFragment=q,de.isLazy=H,de.isMemo=G,de.isPortal=K,de.isProfiler=Z,de.isStrictMode=ue,de.isSuspense=P,de.isSuspenseList=xe,de.isValidElementType=S,de.typeOf=v}()),de}process.env.NODE_ENV==="production"?Kr.exports=Nd():Kr.exports=kd();var ba=Kr.exports;const Sd=/^\s*function(?:\s|\s*\/\*.*\*\/\s*)+([^(\s/]*)\s*/;function Ed(e){const t=`${e}`.match(Sd);return t&&t[1]||""}function Zs(e,t=""){return e.displayName||e.name||Ed(e)||t}function va(e,t,n){const r=Zs(t);return e.displayName||(r!==""?`${n}(${r})`:n)}function jd(e){if(e!=null){if(typeof e=="string")return e;if(typeof e=="function")return Zs(e,"Component");if(typeof e=="object")switch(e.$$typeof){case ba.ForwardRef:return va(e,e.render,"ForwardRef");case ba.Memo:return va(e,e.type,"memo");default:return}}}function vn(e,t,n,r,o){if(process.env.NODE_ENV==="production")return null;const s=e[t],i=o||t;return s==null?null:s&&s.nodeType!==1?new Error(`Invalid ${r} \`${i}\` supplied to \`${n}\`. Expected an HTMLElement.`):null}const Td=p.oneOfType([p.func,p.object]),Qs=Td;function Xe(e){if(typeof e!="string")throw new Error(process.env.NODE_ENV!=="production"?"MUI: `capitalize(string)` expects a string argument.":zt(7));return e.charAt(0).toUpperCase()+e.slice(1)}function Cd(...e){return e.reduce((t,n)=>n==null?t:function(...o){t.apply(this,o),n.apply(this,o)},()=>{})}function Rd(e,t=166){let n;function r(...o){const s=()=>{e.apply(this,o)};clearTimeout(n),n=setTimeout(s,t)}return r.clear=()=>{clearTimeout(n)},r}function Od(e,t){return process.env.NODE_ENV==="production"?()=>null:(n,r,o,s,i)=>{const l=o||"<>",c=i||r;return typeof n[r]<"u"?new Error(`The ${s} \`${c}\` of \`${l}\` is deprecated. ${t}`):null}}function _d(e,t){var n,r;return $.isValidElement(e)&&t.indexOf((n=e.type.muiName)!=null?n:(r=e.type)==null||(r=r._payload)==null||(r=r.value)==null?void 0:r.muiName)!==-1}function Kn(e){return e&&e.ownerDocument||document}function Pd(e){return Kn(e).defaultView||window}function Id(e,t){if(process.env.NODE_ENV==="production")return()=>null;const n=t?R({},t.propTypes):null;return o=>(s,i,l,c,d,...u)=>{const f=d||i,w=n==null?void 0:n[f];if(w){const b=w(s,i,l,c,d,...u);if(b)return b}return typeof s[i]<"u"&&!s[o]?new Error(`The prop \`${f}\` of \`${e}\` can only be used together with the \`${o}\` prop.`):null}}function Jn(e,t){typeof e=="function"?e(t):e&&(e.current=t)}const Md=typeof window<"u"?$.useLayoutEffect:$.useEffect,Lt=Md;let xa=0;function $d(e){const[t,n]=$.useState(e),r=e||t;return $.useEffect(()=>{t==null&&(xa+=1,n(`mui-${xa}`))},[t]),r}const ya=$["useId".toString()];function ei(e){if(ya!==void 0){const t=ya();return e??t}return $d(e)}function Dd(e,t,n,r,o){if(process.env.NODE_ENV==="production")return null;const s=o||t;return typeof e[t]<"u"?new Error(`The prop \`${s}\` is not supported. Please remove it.`):null}function ti({controlled:e,default:t,name:n,state:r="value"}){const{current:o}=$.useRef(e!==void 0),[s,i]=$.useState(t),l=o?e:s;if(process.env.NODE_ENV!=="production"){$.useEffect(()=>{o!==(e!==void 0)&&console.error([`MUI: A component is changing the ${o?"":"un"}controlled ${r} state of ${n} to be ${o?"un":""}controlled.`,"Elements should not switch from uncontrolled to controlled (or vice versa).",`Decide between using a controlled or uncontrolled ${n} element for the lifetime of the component.`,"The nature of the state is determined during the first render. It's considered controlled if the value is not `undefined`.","More info: https://fb.me/react-controlled-components"].join(` +`))},[r,n,e]);const{current:d}=$.useRef(t);$.useEffect(()=>{!o&&d!==t&&console.error([`MUI: A component is changing the default ${r} state of an uncontrolled ${n} after being initialized. To suppress this warning opt to use a controlled ${n}.`].join(` +`))},[JSON.stringify(t)])}const c=$.useCallback(d=>{o||i(d)},[]);return[l,c]}function Jr(e){const t=$.useRef(e);return Lt(()=>{t.current=e}),$.useRef((...n)=>(0,t.current)(...n)).current}function yt(...e){return $.useMemo(()=>e.every(t=>t==null)?null:t=>{e.forEach(n=>{Jn(n,t)})},e)}const Na={};function Ad(e,t){const n=$.useRef(Na);return n.current===Na&&(n.current=e(t)),n}const Bd=[];function Vd(e){$.useEffect(e,Bd)}class On{constructor(){this.currentId=null,this.clear=()=>{this.currentId!==null&&(clearTimeout(this.currentId),this.currentId=null)},this.disposeEffect=()=>this.clear}static create(){return new On}start(t,n){this.clear(),this.currentId=setTimeout(()=>{this.currentId=null,n()},t)}}function cn(){const e=Ad(On.create).current;return Vd(e.disposeEffect),e}let dr=!0,Zr=!1;const zd=new On,Ld={text:!0,search:!0,url:!0,tel:!0,email:!0,password:!0,number:!0,date:!0,month:!0,week:!0,time:!0,datetime:!0,"datetime-local":!0};function Fd(e){const{type:t,tagName:n}=e;return!!(n==="INPUT"&&Ld[t]&&!e.readOnly||n==="TEXTAREA"&&!e.readOnly||e.isContentEditable)}function Gd(e){e.metaKey||e.altKey||e.ctrlKey||(dr=!0)}function Br(){dr=!1}function Ud(){this.visibilityState==="hidden"&&Zr&&(dr=!0)}function qd(e){e.addEventListener("keydown",Gd,!0),e.addEventListener("mousedown",Br,!0),e.addEventListener("pointerdown",Br,!0),e.addEventListener("touchstart",Br,!0),e.addEventListener("visibilitychange",Ud,!0)}function Hd(e){const{target:t}=e;try{return t.matches(":focus-visible")}catch{}return dr||Fd(t)}function ni(){const e=$.useCallback(o=>{o!=null&&qd(o.ownerDocument)},[]),t=$.useRef(!1);function n(){return t.current?(Zr=!0,zd.start(100,()=>{Zr=!1}),t.current=!1,!0):!1}function r(o){return Hd(o)?(t.current=!0,!0):!1}return{isFocusVisibleRef:t,onFocus:r,onBlur:n,ref:e}}function ri(e,t){const n=R({},t);return Object.keys(e).forEach(r=>{if(r.toString().match(/^(components|slots)$/))n[r]=R({},e[r],n[r]);else if(r.toString().match(/^(componentsProps|slotProps)$/)){const o=e[r]||{},s=t[r];n[r]={},!s||!Object.keys(s)?n[r]=o:!o||!Object.keys(o)?n[r]=s:(n[r]=R({},s),Object.keys(o).forEach(i=>{n[r][i]=ri(o[i],s[i])}))}else n[r]===void 0&&(n[r]=e[r])}),n}function No(e,t,n=void 0){const r={};return Object.keys(e).forEach(o=>{r[o]=e[o].reduce((s,i)=>{if(i){const l=t(i);l!==""&&s.push(l),n&&n[i]&&s.push(n[i])}return s},[]).join(" ")}),r}const ka=e=>e,Yd=()=>{let e=ka;return{configure(t){e=t},generate(t){return e(t)},reset(){e=ka}}},Xd=Yd(),oi=Xd,ai={active:"active",checked:"checked",completed:"completed",disabled:"disabled",error:"error",expanded:"expanded",focused:"focused",focusVisible:"focusVisible",open:"open",readOnly:"readOnly",required:"required",selected:"selected"};function ur(e,t,n="Mui"){const r=ai[t];return r?`${n}-${r}`:`${oi.generate(e)}-${t}`}function si(e,t,n="Mui"){const r={};return t.forEach(o=>{r[o]=ur(e,o,n)}),r}function Wd(e,t=Number.MIN_SAFE_INTEGER,n=Number.MAX_SAFE_INTEGER){return Math.max(t,Math.min(e,n))}function ye(e,t){if(e==null)return{};var n={},r=Object.keys(e),o,s;for(s=0;s=0)&&(n[o]=e[o]);return n}const Kd=["values","unit","step"],Jd=e=>{const t=Object.keys(e).map(n=>({key:n,val:e[n]}))||[];return t.sort((n,r)=>n.val-r.val),t.reduce((n,r)=>R({},n,{[r.key]:r.val}),{})};function Zd(e){const{values:t={xs:0,sm:600,md:900,lg:1200,xl:1536},unit:n="px",step:r=5}=e,o=ye(e,Kd),s=Jd(t),i=Object.keys(s);function l(w){return`@media (min-width:${typeof t[w]=="number"?t[w]:w}${n})`}function c(w){return`@media (max-width:${(typeof t[w]=="number"?t[w]:w)-r/100}${n})`}function d(w,b){const x=i.indexOf(b);return`@media (min-width:${typeof t[w]=="number"?t[w]:w}${n}) and (max-width:${(x!==-1&&typeof t[i[x]]=="number"?t[i[x]]:b)-r/100}${n})`}function u(w){return i.indexOf(w)+1`@media (min-width:${ko[e]}px)`};function et(e,t,n){const r=e.theme||{};if(Array.isArray(t)){const s=r.breakpoints||Sa;return t.reduce((i,l,c)=>(i[s.up(s.keys[c])]=n(t[c]),i),{})}if(typeof t=="object"){const s=r.breakpoints||Sa;return Object.keys(t).reduce((i,l)=>{if(Object.keys(s.values||ko).indexOf(l)!==-1){const c=s.up(l);i[c]=n(t[l],l)}else{const c=l;i[c]=t[c]}return i},{})}return n(t)}function nu(e={}){var t;return((t=e.keys)==null?void 0:t.reduce((r,o)=>{const s=e.up(o);return r[s]={},r},{}))||{}}function ru(e,t){return e.reduce((n,r)=>{const o=n[r];return(!o||Object.keys(o).length===0)&&delete n[r],n},t)}function pr(e,t,n=!0){if(!t||typeof t!="string")return null;if(e&&e.vars&&n){const r=`vars.${t}`.split(".").reduce((o,s)=>o&&o[s]?o[s]:null,e);if(r!=null)return r}return t.split(".").reduce((r,o)=>r&&r[o]!=null?r[o]:null,e)}function Zn(e,t,n,r=n){let o;return typeof e=="function"?o=e(n):Array.isArray(e)?o=e[n]||r:o=pr(e,n)||r,t&&(o=t(o,r,e)),o}function be(e){const{prop:t,cssProperty:n=e.prop,themeKey:r,transform:o}=e,s=i=>{if(i[t]==null)return null;const l=i[t],c=i.theme,d=pr(c,r)||{};return et(i,l,f=>{let w=Zn(d,o,f);return f===w&&typeof f=="string"&&(w=Zn(d,o,`${t}${f==="default"?"":Xe(f)}`,f)),n===!1?w:{[n]:w}})};return s.propTypes=process.env.NODE_ENV!=="production"?{[t]:st}:{},s.filterProps=[t],s}function ou(e){const t={};return n=>(t[n]===void 0&&(t[n]=e(n)),t[n])}const au={m:"margin",p:"padding"},su={t:"Top",r:"Right",b:"Bottom",l:"Left",x:["Left","Right"],y:["Top","Bottom"]},Ea={marginX:"mx",marginY:"my",paddingX:"px",paddingY:"py"},iu=ou(e=>{if(e.length>2)if(Ea[e])e=Ea[e];else return[e];const[t,n]=e.split(""),r=au[t],o=su[n]||"";return Array.isArray(o)?o.map(s=>r+s):[r+o]}),wr=["m","mt","mr","mb","ml","mx","my","margin","marginTop","marginRight","marginBottom","marginLeft","marginX","marginY","marginInline","marginInlineStart","marginInlineEnd","marginBlock","marginBlockStart","marginBlockEnd"],fr=["p","pt","pr","pb","pl","px","py","padding","paddingTop","paddingRight","paddingBottom","paddingLeft","paddingX","paddingY","paddingInline","paddingInlineStart","paddingInlineEnd","paddingBlock","paddingBlockStart","paddingBlockEnd"],lu=[...wr,...fr];function _n(e,t,n,r){var o;const s=(o=pr(e,t,!1))!=null?o:n;return typeof s=="number"?i=>typeof i=="string"?i:(process.env.NODE_ENV!=="production"&&typeof i!="number"&&console.error(`MUI: Expected ${r} argument to be a number or a string, got ${i}.`),s*i):Array.isArray(s)?i=>typeof i=="string"?i:(process.env.NODE_ENV!=="production"&&(Number.isInteger(i)?i>s.length-1&&console.error([`MUI: The value provided (${i}) overflows.`,`The supported values are: ${JSON.stringify(s)}.`,`${i} > ${s.length-1}, you need to add the missing values.`].join(` `)):console.error([`MUI: The \`theme.${t}\` array type cannot be combined with non integer values.You should either use an integer value that can be used as index, or define the \`theme.${t}\` as a number.`].join(` `))),s[i]):typeof s=="function"?s:(process.env.NODE_ENV!=="production"&&console.error([`MUI: The \`theme.${t}\` value (${s}) is invalid.`,"It should be a number, an array or a function."].join(` -`)),()=>{})}function di(e){return _n(e,"spacing",8,"spacing")}function Pn(e,t){if(typeof t=="string"||t==null)return t;const n=Math.abs(t),r=e(n);return t>=0?r:typeof r=="number"?-r:`-${r}`}function yu(e,t){return n=>e.reduce((r,o)=>(r[o]=Pn(t,n),r),{})}function Nu(e,t,n,r){if(t.indexOf(n)===-1)return null;const o=vu(n),s=yu(o,r),i=e[n];return et(e,i,s)}function ui(e,t){const n=di(e.theme);return Object.keys(e).map(r=>Nu(e,t,r,n)).reduce(mn,{})}function me(e){return ui(e,wr)}me.propTypes=process.env.NODE_ENV!=="production"?wr.reduce((e,t)=>(e[t]=st,e),{}):{};me.filterProps=wr;function he(e){return ui(e,fr)}he.propTypes=process.env.NODE_ENV!=="production"?fr.reduce((e,t)=>(e[t]=st,e),{}):{};he.filterProps=fr;process.env.NODE_ENV!=="production"&&xu.reduce((e,t)=>(e[t]=st,e),{});function ku(e=8){if(e.mui)return e;const t=di({spacing:e}),n=(...r)=>(process.env.NODE_ENV!=="production"&&(r.length<=4||console.error(`MUI: Too many arguments provided, expected between 0 and 4, got ${r.length}`)),(r.length===0?[1]:r).map(s=>{const i=t(s);return typeof i=="number"?`${i}px`:i}).join(" "));return n.mui=!0,n}function mr(...e){const t=e.reduce((r,o)=>(o.filterProps.forEach(s=>{r[s]=o}),r),{}),n=r=>Object.keys(r).reduce((o,s)=>t[s]?mn(o,t[s](r)):o,{});return n.propTypes=process.env.NODE_ENV!=="production"?e.reduce((r,o)=>Object.assign(r,o.propTypes),{}):{},n.filterProps=e.reduce((r,o)=>r.concat(o.filterProps),[]),n}function Be(e){return typeof e!="number"?e:`${e}px solid`}function Fe(e,t){return ve({prop:e,themeKey:"borders",transform:t})}const Su=Fe("border",Be),Eu=Fe("borderTop",Be),ju=Fe("borderRight",Be),Cu=Fe("borderBottom",Be),Tu=Fe("borderLeft",Be),Ru=Fe("borderColor"),Ou=Fe("borderTopColor"),_u=Fe("borderRightColor"),Pu=Fe("borderBottomColor"),Iu=Fe("borderLeftColor"),Mu=Fe("outline",Be),$u=Fe("outlineColor"),hr=e=>{if(e.borderRadius!==void 0&&e.borderRadius!==null){const t=_n(e.theme,"shape.borderRadius",4,"borderRadius"),n=r=>({borderRadius:Pn(t,r)});return et(e,e.borderRadius,n)}return null};hr.propTypes=process.env.NODE_ENV!=="production"?{borderRadius:st}:{};hr.filterProps=["borderRadius"];mr(Su,Eu,ju,Cu,Tu,Ru,Ou,_u,Pu,Iu,hr,Mu,$u);const gr=e=>{if(e.gap!==void 0&&e.gap!==null){const t=_n(e.theme,"spacing",8,"gap"),n=r=>({gap:Pn(t,r)});return et(e,e.gap,n)}return null};gr.propTypes=process.env.NODE_ENV!=="production"?{gap:st}:{};gr.filterProps=["gap"];const br=e=>{if(e.columnGap!==void 0&&e.columnGap!==null){const t=_n(e.theme,"spacing",8,"columnGap"),n=r=>({columnGap:Pn(t,r)});return et(e,e.columnGap,n)}return null};br.propTypes=process.env.NODE_ENV!=="production"?{columnGap:st}:{};br.filterProps=["columnGap"];const vr=e=>{if(e.rowGap!==void 0&&e.rowGap!==null){const t=_n(e.theme,"spacing",8,"rowGap"),n=r=>({rowGap:Pn(t,r)});return et(e,e.rowGap,n)}return null};vr.propTypes=process.env.NODE_ENV!=="production"?{rowGap:st}:{};vr.filterProps=["rowGap"];const Du=ve({prop:"gridColumn"}),Au=ve({prop:"gridRow"}),Bu=ve({prop:"gridAutoFlow"}),Vu=ve({prop:"gridAutoColumns"}),zu=ve({prop:"gridAutoRows"}),Lu=ve({prop:"gridTemplateColumns"}),Fu=ve({prop:"gridTemplateRows"}),Gu=ve({prop:"gridTemplateAreas"}),Uu=ve({prop:"gridArea"});mr(gr,br,vr,Du,Au,Bu,Vu,zu,Lu,Fu,Gu,Uu);function Dt(e,t){return t==="grey"?t:e}const qu=ve({prop:"color",themeKey:"palette",transform:Dt}),Hu=ve({prop:"bgcolor",cssProperty:"backgroundColor",themeKey:"palette",transform:Dt}),Xu=ve({prop:"backgroundColor",themeKey:"palette",transform:Dt});mr(qu,Hu,Xu);function Ie(e){return e<=1&&e!==0?`${e*100}%`:e}const Yu=ve({prop:"width",transform:Ie}),Eo=e=>{if(e.maxWidth!==void 0&&e.maxWidth!==null){const t=n=>{var r,o;const s=((r=e.theme)==null||(r=r.breakpoints)==null||(r=r.values)==null?void 0:r[n])||So[n];return s?((o=e.theme)==null||(o=o.breakpoints)==null?void 0:o.unit)!=="px"?{maxWidth:`${s}${e.theme.breakpoints.unit}`}:{maxWidth:s}:{maxWidth:Ie(n)}};return et(e,e.maxWidth,t)}return null};Eo.filterProps=["maxWidth"];const Wu=ve({prop:"minWidth",transform:Ie}),Ku=ve({prop:"height",transform:Ie}),Ju=ve({prop:"maxHeight",transform:Ie}),Zu=ve({prop:"minHeight",transform:Ie});ve({prop:"size",cssProperty:"width",transform:Ie});ve({prop:"size",cssProperty:"height",transform:Ie});const Qu=ve({prop:"boxSizing"});mr(Yu,Eo,Wu,Ku,Ju,Zu,Qu);const ep={border:{themeKey:"borders",transform:Be},borderTop:{themeKey:"borders",transform:Be},borderRight:{themeKey:"borders",transform:Be},borderBottom:{themeKey:"borders",transform:Be},borderLeft:{themeKey:"borders",transform:Be},borderColor:{themeKey:"palette"},borderTopColor:{themeKey:"palette"},borderRightColor:{themeKey:"palette"},borderBottomColor:{themeKey:"palette"},borderLeftColor:{themeKey:"palette"},outline:{themeKey:"borders",transform:Be},outlineColor:{themeKey:"palette"},borderRadius:{themeKey:"shape.borderRadius",style:hr},color:{themeKey:"palette",transform:Dt},bgcolor:{themeKey:"palette",cssProperty:"backgroundColor",transform:Dt},backgroundColor:{themeKey:"palette",transform:Dt},p:{style:he},pt:{style:he},pr:{style:he},pb:{style:he},pl:{style:he},px:{style:he},py:{style:he},padding:{style:he},paddingTop:{style:he},paddingRight:{style:he},paddingBottom:{style:he},paddingLeft:{style:he},paddingX:{style:he},paddingY:{style:he},paddingInline:{style:he},paddingInlineStart:{style:he},paddingInlineEnd:{style:he},paddingBlock:{style:he},paddingBlockStart:{style:he},paddingBlockEnd:{style:he},m:{style:me},mt:{style:me},mr:{style:me},mb:{style:me},ml:{style:me},mx:{style:me},my:{style:me},margin:{style:me},marginTop:{style:me},marginRight:{style:me},marginBottom:{style:me},marginLeft:{style:me},marginX:{style:me},marginY:{style:me},marginInline:{style:me},marginInlineStart:{style:me},marginInlineEnd:{style:me},marginBlock:{style:me},marginBlockStart:{style:me},marginBlockEnd:{style:me},displayPrint:{cssProperty:!1,transform:e=>({"@media print":{display:e}})},display:{},overflow:{},textOverflow:{},visibility:{},whiteSpace:{},flexBasis:{},flexDirection:{},flexWrap:{},justifyContent:{},alignItems:{},alignContent:{},order:{},flex:{},flexGrow:{},flexShrink:{},alignSelf:{},justifyItems:{},justifySelf:{},gap:{style:gr},rowGap:{style:vr},columnGap:{style:br},gridColumn:{},gridRow:{},gridAutoFlow:{},gridAutoColumns:{},gridAutoRows:{},gridTemplateColumns:{},gridTemplateRows:{},gridTemplateAreas:{},gridArea:{},position:{},zIndex:{themeKey:"zIndex"},top:{},right:{},bottom:{},left:{},boxShadow:{themeKey:"shadows"},width:{transform:Ie},maxWidth:{style:Eo},minWidth:{transform:Ie},height:{transform:Ie},maxHeight:{transform:Ie},minHeight:{transform:Ie},boxSizing:{},fontFamily:{themeKey:"typography"},fontSize:{themeKey:"typography"},fontStyle:{themeKey:"typography"},fontWeight:{themeKey:"typography"},letterSpacing:{},textTransform:{},lineHeight:{},textAlign:{},typography:{cssProperty:!1,themeKey:"typography"}},jo=ep;function tp(...e){const t=e.reduce((r,o)=>r.concat(Object.keys(o)),[]),n=new Set(t);return e.every(r=>n.size===Object.keys(r).length)}function np(e,t){return typeof e=="function"?e(t):e}function rp(){function e(n,r,o,s){const i={[n]:r,theme:o},l=s[n];if(!l)return{[n]:r};const{cssProperty:c=n,themeKey:d,transform:u,style:f}=l;if(r==null)return null;if(d==="typography"&&r==="inherit")return{[n]:r};const w=pr(o,d)||{};return f?f(i):et(i,r,x=>{let m=Zn(w,u,x);return x===m&&typeof x=="string"&&(m=Zn(w,u,`${n}${x==="default"?"":Ye(x)}`,x)),c===!1?m:{[c]:m}})}function t(n){var r;const{sx:o,theme:s={}}=n||{};if(!o)return null;const i=(r=s.unstable_sxConfig)!=null?r:jo;function l(c){let d=c;if(typeof c=="function")d=c(s);else if(typeof c!="object")return c;if(!d)return null;const u=fu(s.breakpoints),f=Object.keys(u);let w=u;return Object.keys(d).forEach(b=>{const x=np(d[b],s);if(x!=null)if(typeof x=="object")if(i[b])w=mn(w,e(b,x,s,i));else{const m=et({theme:s},x,h=>({[b]:h}));tp(m,x)?w[b]=t({sx:x,theme:s}):w=mn(w,m)}else w=mn(w,e(b,x,s,i))}),mu(f,w)}return Array.isArray(o)?o.map(l):l(o)}return t}const pi=rp();pi.filterProps=["sx"];const Co=pi;function op(e,t){const n=this;return n.vars&&typeof n.getColorSchemeSelector=="function"?{[n.getColorSchemeSelector(e).replace(/(\[[^\]]+\])/,"*:where($1)")]:t}:n.palette.mode===e?t:{}}const ap=["breakpoints","palette","spacing","shape"];function To(e={},...t){const{breakpoints:n={},palette:r={},spacing:o,shape:s={}}=e,i=Ne(e,ap),l=du(n),c=ku(o);let d=Qe({breakpoints:l,direction:"ltr",components:{},palette:O({mode:"light"},r),spacing:c,shape:O({},pu,s)},i);return d.applyStyles=op,d=t.reduce((u,f)=>Qe(u,f),d),d.unstable_sxConfig=O({},jo,i==null?void 0:i.unstable_sxConfig),d.unstable_sx=function(f){return Co({sx:f,theme:this})},d}function sp(e){return Object.keys(e).length===0}function wi(e=null){const t=M.useContext(Gr.ThemeContext);return!t||sp(t)?e:t}const ip=To();function fi(e=ip){return wi(e)}const lp=["ownerState"],cp=["variants"],dp=["name","slot","skipVariantsResolver","skipSx","overridesResolver"];function up(e){return Object.keys(e).length===0}function pp(e){return typeof e=="string"&&e.charCodeAt(0)>96}function qn(e){return e!=="ownerState"&&e!=="theme"&&e!=="sx"&&e!=="as"}const wp=To(),Ca=e=>e&&e.charAt(0).toLowerCase()+e.slice(1);function Ln({defaultTheme:e,theme:t,themeId:n}){return up(t)?e:t[n]||t}function fp(e){return e?(t,n)=>n[e]:null}function Hn(e,t){let{ownerState:n}=t,r=Ne(t,lp);const o=typeof e=="function"?e(O({ownerState:n},r)):e;if(Array.isArray(o))return o.flatMap(s=>Hn(s,O({ownerState:n},r)));if(o&&typeof o=="object"&&Array.isArray(o.variants)){const{variants:s=[]}=o;let l=Ne(o,cp);return s.forEach(c=>{let d=!0;typeof c.props=="function"?d=c.props(O({ownerState:n},r,n)):Object.keys(c.props).forEach(u=>{(n==null?void 0:n[u])!==c.props[u]&&r[u]!==c.props[u]&&(d=!1)}),d&&(Array.isArray(l)||(l=[l]),l.push(typeof c.style=="function"?c.style(O({ownerState:n},r,n)):c.style))}),l}return o}function mp(e={}){const{themeId:t,defaultTheme:n=wp,rootShouldForwardProp:r=qn,slotShouldForwardProp:o=qn}=e,s=i=>Co(O({},i,{theme:Ln(O({},i,{defaultTheme:n,themeId:t}))}));return s.__mui_systemSx=!0,(i,l={})=>{Gr.internal_processStyles(i,v=>v.filter(P=>!(P!=null&&P.__mui_systemSx)));const{name:c,slot:d,skipVariantsResolver:u,skipSx:f,overridesResolver:w=fp(Ca(d))}=l,b=Ne(l,dp),x=u!==void 0?u:d&&d!=="Root"&&d!=="root"||!1,m=f||!1;let h;process.env.NODE_ENV!=="production"&&c&&(h=`${c}-${Ca(d||"Root")}`);let S=qn;d==="Root"||d==="root"?S=r:d?S=o:pp(i)&&(S=void 0);const R=Gr(i,O({shouldForwardProp:S,label:h},b)),j=v=>typeof v=="function"&&v.__emotion_real!==v||mt(v)?P=>Hn(v,O({},P,{theme:Ln({theme:P.theme,defaultTheme:n,themeId:t})})):v,E=(v,...P)=>{let V=j(v);const U=P?P.map(j):[];c&&w&&U.push(k=>{const D=Ln(O({},k,{defaultTheme:n,themeId:t}));if(!D.components||!D.components[c]||!D.components[c].styleOverrides)return null;const $=D.components[c].styleOverrides,J={};return Object.entries($).forEach(([Y,F])=>{J[Y]=Hn(F,O({},k,{theme:D}))}),w(k,J)}),c&&!x&&U.push(k=>{var D;const $=Ln(O({},k,{defaultTheme:n,themeId:t})),J=$==null||(D=$.components)==null||(D=D[c])==null?void 0:D.variants;return Hn({variants:J},O({},k,{theme:$}))}),m||U.push(s);const C=U.length-P.length;if(Array.isArray(v)&&C>0){const k=new Array(C).fill("");V=[...v,...k],V.raw=[...v.raw,...k]}const _=R(V,...U);if(process.env.NODE_ENV!=="production"){let k;c&&(k=`${c}${Ye(d||"")}`),k===void 0&&(k=`Styled(${Bd(i)})`),_.displayName=k}return i.muiName&&(_.muiName=i.muiName),_};return R.withConfig&&(E.withConfig=R.withConfig),E}}function hp(e){const{theme:t,name:n,props:r}=e;return!t||!t.components||!t.components[n]||!t.components[n].defaultProps?r:si(t.components[n].defaultProps,r)}function gp({props:e,name:t,defaultTheme:n,themeId:r}){let o=fi(n);return r&&(o=o[r]||o),hp({theme:o,name:t,props:e})}function Ro(e,t=0,n=1){return process.env.NODE_ENV!=="production"&&(en)&&console.error(`MUI: The value provided ${e} is out of range [${t}, ${n}].`),iu(e,t,n)}function bp(e){e=e.slice(1);const t=new RegExp(`.{1,${e.length>=6?2:1}}`,"g");let n=e.match(t);return n&&n[0].length===1&&(n=n.map(r=>r+r)),n?`rgb${n.length===4?"a":""}(${n.map((r,o)=>o<3?parseInt(r,16):Math.round(parseInt(r,16)/255*1e3)/1e3).join(", ")})`:""}function Nt(e){if(e.type)return e;if(e.charAt(0)==="#")return Nt(bp(e));const t=e.indexOf("("),n=e.substring(0,t);if(["rgb","rgba","hsl","hsla","color"].indexOf(n)===-1)throw new Error(process.env.NODE_ENV!=="production"?`MUI: Unsupported \`${e}\` color. +`)),()=>{})}function ii(e){return _n(e,"spacing",8,"spacing")}function Pn(e,t){if(typeof t=="string"||t==null)return t;const n=Math.abs(t),r=e(n);return t>=0?r:typeof r=="number"?-r:`-${r}`}function cu(e,t){return n=>e.reduce((r,o)=>(r[o]=Pn(t,n),r),{})}function du(e,t,n,r){if(t.indexOf(n)===-1)return null;const o=iu(n),s=cu(o,r),i=e[n];return et(e,i,s)}function li(e,t){const n=ii(e.theme);return Object.keys(e).map(r=>du(e,t,r,n)).reduce(fn,{})}function me(e){return li(e,wr)}me.propTypes=process.env.NODE_ENV!=="production"?wr.reduce((e,t)=>(e[t]=st,e),{}):{};me.filterProps=wr;function he(e){return li(e,fr)}he.propTypes=process.env.NODE_ENV!=="production"?fr.reduce((e,t)=>(e[t]=st,e),{}):{};he.filterProps=fr;process.env.NODE_ENV!=="production"&&lu.reduce((e,t)=>(e[t]=st,e),{});function uu(e=8){if(e.mui)return e;const t=ii({spacing:e}),n=(...r)=>(process.env.NODE_ENV!=="production"&&(r.length<=4||console.error(`MUI: Too many arguments provided, expected between 0 and 4, got ${r.length}`)),(r.length===0?[1]:r).map(s=>{const i=t(s);return typeof i=="number"?`${i}px`:i}).join(" "));return n.mui=!0,n}function mr(...e){const t=e.reduce((r,o)=>(o.filterProps.forEach(s=>{r[s]=o}),r),{}),n=r=>Object.keys(r).reduce((o,s)=>t[s]?fn(o,t[s](r)):o,{});return n.propTypes=process.env.NODE_ENV!=="production"?e.reduce((r,o)=>Object.assign(r,o.propTypes),{}):{},n.filterProps=e.reduce((r,o)=>r.concat(o.filterProps),[]),n}function Ae(e){return typeof e!="number"?e:`${e}px solid`}function Le(e,t){return be({prop:e,themeKey:"borders",transform:t})}const pu=Le("border",Ae),wu=Le("borderTop",Ae),fu=Le("borderRight",Ae),mu=Le("borderBottom",Ae),hu=Le("borderLeft",Ae),gu=Le("borderColor"),bu=Le("borderTopColor"),vu=Le("borderRightColor"),xu=Le("borderBottomColor"),yu=Le("borderLeftColor"),Nu=Le("outline",Ae),ku=Le("outlineColor"),hr=e=>{if(e.borderRadius!==void 0&&e.borderRadius!==null){const t=_n(e.theme,"shape.borderRadius",4,"borderRadius"),n=r=>({borderRadius:Pn(t,r)});return et(e,e.borderRadius,n)}return null};hr.propTypes=process.env.NODE_ENV!=="production"?{borderRadius:st}:{};hr.filterProps=["borderRadius"];mr(pu,wu,fu,mu,hu,gu,bu,vu,xu,yu,hr,Nu,ku);const gr=e=>{if(e.gap!==void 0&&e.gap!==null){const t=_n(e.theme,"spacing",8,"gap"),n=r=>({gap:Pn(t,r)});return et(e,e.gap,n)}return null};gr.propTypes=process.env.NODE_ENV!=="production"?{gap:st}:{};gr.filterProps=["gap"];const br=e=>{if(e.columnGap!==void 0&&e.columnGap!==null){const t=_n(e.theme,"spacing",8,"columnGap"),n=r=>({columnGap:Pn(t,r)});return et(e,e.columnGap,n)}return null};br.propTypes=process.env.NODE_ENV!=="production"?{columnGap:st}:{};br.filterProps=["columnGap"];const vr=e=>{if(e.rowGap!==void 0&&e.rowGap!==null){const t=_n(e.theme,"spacing",8,"rowGap"),n=r=>({rowGap:Pn(t,r)});return et(e,e.rowGap,n)}return null};vr.propTypes=process.env.NODE_ENV!=="production"?{rowGap:st}:{};vr.filterProps=["rowGap"];const Su=be({prop:"gridColumn"}),Eu=be({prop:"gridRow"}),ju=be({prop:"gridAutoFlow"}),Tu=be({prop:"gridAutoColumns"}),Cu=be({prop:"gridAutoRows"}),Ru=be({prop:"gridTemplateColumns"}),Ou=be({prop:"gridTemplateRows"}),_u=be({prop:"gridTemplateAreas"}),Pu=be({prop:"gridArea"});mr(gr,br,vr,Su,Eu,ju,Tu,Cu,Ru,Ou,_u,Pu);function Dt(e,t){return t==="grey"?t:e}const Iu=be({prop:"color",themeKey:"palette",transform:Dt}),Mu=be({prop:"bgcolor",cssProperty:"backgroundColor",themeKey:"palette",transform:Dt}),$u=be({prop:"backgroundColor",themeKey:"palette",transform:Dt});mr(Iu,Mu,$u);function Pe(e){return e<=1&&e!==0?`${e*100}%`:e}const Du=be({prop:"width",transform:Pe}),So=e=>{if(e.maxWidth!==void 0&&e.maxWidth!==null){const t=n=>{var r,o;const s=((r=e.theme)==null||(r=r.breakpoints)==null||(r=r.values)==null?void 0:r[n])||ko[n];return s?((o=e.theme)==null||(o=o.breakpoints)==null?void 0:o.unit)!=="px"?{maxWidth:`${s}${e.theme.breakpoints.unit}`}:{maxWidth:s}:{maxWidth:Pe(n)}};return et(e,e.maxWidth,t)}return null};So.filterProps=["maxWidth"];const Au=be({prop:"minWidth",transform:Pe}),Bu=be({prop:"height",transform:Pe}),Vu=be({prop:"maxHeight",transform:Pe}),zu=be({prop:"minHeight",transform:Pe});be({prop:"size",cssProperty:"width",transform:Pe});be({prop:"size",cssProperty:"height",transform:Pe});const Lu=be({prop:"boxSizing"});mr(Du,So,Au,Bu,Vu,zu,Lu);const Fu={border:{themeKey:"borders",transform:Ae},borderTop:{themeKey:"borders",transform:Ae},borderRight:{themeKey:"borders",transform:Ae},borderBottom:{themeKey:"borders",transform:Ae},borderLeft:{themeKey:"borders",transform:Ae},borderColor:{themeKey:"palette"},borderTopColor:{themeKey:"palette"},borderRightColor:{themeKey:"palette"},borderBottomColor:{themeKey:"palette"},borderLeftColor:{themeKey:"palette"},outline:{themeKey:"borders",transform:Ae},outlineColor:{themeKey:"palette"},borderRadius:{themeKey:"shape.borderRadius",style:hr},color:{themeKey:"palette",transform:Dt},bgcolor:{themeKey:"palette",cssProperty:"backgroundColor",transform:Dt},backgroundColor:{themeKey:"palette",transform:Dt},p:{style:he},pt:{style:he},pr:{style:he},pb:{style:he},pl:{style:he},px:{style:he},py:{style:he},padding:{style:he},paddingTop:{style:he},paddingRight:{style:he},paddingBottom:{style:he},paddingLeft:{style:he},paddingX:{style:he},paddingY:{style:he},paddingInline:{style:he},paddingInlineStart:{style:he},paddingInlineEnd:{style:he},paddingBlock:{style:he},paddingBlockStart:{style:he},paddingBlockEnd:{style:he},m:{style:me},mt:{style:me},mr:{style:me},mb:{style:me},ml:{style:me},mx:{style:me},my:{style:me},margin:{style:me},marginTop:{style:me},marginRight:{style:me},marginBottom:{style:me},marginLeft:{style:me},marginX:{style:me},marginY:{style:me},marginInline:{style:me},marginInlineStart:{style:me},marginInlineEnd:{style:me},marginBlock:{style:me},marginBlockStart:{style:me},marginBlockEnd:{style:me},displayPrint:{cssProperty:!1,transform:e=>({"@media print":{display:e}})},display:{},overflow:{},textOverflow:{},visibility:{},whiteSpace:{},flexBasis:{},flexDirection:{},flexWrap:{},justifyContent:{},alignItems:{},alignContent:{},order:{},flex:{},flexGrow:{},flexShrink:{},alignSelf:{},justifyItems:{},justifySelf:{},gap:{style:gr},rowGap:{style:vr},columnGap:{style:br},gridColumn:{},gridRow:{},gridAutoFlow:{},gridAutoColumns:{},gridAutoRows:{},gridTemplateColumns:{},gridTemplateRows:{},gridTemplateAreas:{},gridArea:{},position:{},zIndex:{themeKey:"zIndex"},top:{},right:{},bottom:{},left:{},boxShadow:{themeKey:"shadows"},width:{transform:Pe},maxWidth:{style:So},minWidth:{transform:Pe},height:{transform:Pe},maxHeight:{transform:Pe},minHeight:{transform:Pe},boxSizing:{},fontFamily:{themeKey:"typography"},fontSize:{themeKey:"typography"},fontStyle:{themeKey:"typography"},fontWeight:{themeKey:"typography"},letterSpacing:{},textTransform:{},lineHeight:{},textAlign:{},typography:{cssProperty:!1,themeKey:"typography"}},Eo=Fu;function Gu(...e){const t=e.reduce((r,o)=>r.concat(Object.keys(o)),[]),n=new Set(t);return e.every(r=>n.size===Object.keys(r).length)}function Uu(e,t){return typeof e=="function"?e(t):e}function qu(){function e(n,r,o,s){const i={[n]:r,theme:o},l=s[n];if(!l)return{[n]:r};const{cssProperty:c=n,themeKey:d,transform:u,style:f}=l;if(r==null)return null;if(d==="typography"&&r==="inherit")return{[n]:r};const w=pr(o,d)||{};return f?f(i):et(i,r,x=>{let m=Zn(w,u,x);return x===m&&typeof x=="string"&&(m=Zn(w,u,`${n}${x==="default"?"":Xe(x)}`,x)),c===!1?m:{[c]:m}})}function t(n){var r;const{sx:o,theme:s={}}=n||{};if(!o)return null;const i=(r=s.unstable_sxConfig)!=null?r:Eo;function l(c){let d=c;if(typeof c=="function")d=c(s);else if(typeof c!="object")return c;if(!d)return null;const u=nu(s.breakpoints),f=Object.keys(u);let w=u;return Object.keys(d).forEach(b=>{const x=Uu(d[b],s);if(x!=null)if(typeof x=="object")if(i[b])w=fn(w,e(b,x,s,i));else{const m=et({theme:s},x,h=>({[b]:h}));Gu(m,x)?w[b]=t({sx:x,theme:s}):w=fn(w,m)}else w=fn(w,e(b,x,s,i))}),ru(f,w)}return Array.isArray(o)?o.map(l):l(o)}return t}const ci=qu();ci.filterProps=["sx"];const jo=ci;function Hu(e,t){const n=this;return n.vars&&typeof n.getColorSchemeSelector=="function"?{[n.getColorSchemeSelector(e).replace(/(\[[^\]]+\])/,"*:where($1)")]:t}:n.palette.mode===e?t:{}}const Yu=["breakpoints","palette","spacing","shape"];function To(e={},...t){const{breakpoints:n={},palette:r={},spacing:o,shape:s={}}=e,i=ye(e,Yu),l=Zd(n),c=uu(o);let d=Qe({breakpoints:l,direction:"ltr",components:{},palette:R({mode:"light"},r),spacing:c,shape:R({},eu,s)},i);return d.applyStyles=Hu,d=t.reduce((u,f)=>Qe(u,f),d),d.unstable_sxConfig=R({},Eo,i==null?void 0:i.unstable_sxConfig),d.unstable_sx=function(f){return jo({sx:f,theme:this})},d}function Xu(e){return Object.keys(e).length===0}function di(e=null){const t=$.useContext(Fr.ThemeContext);return!t||Xu(t)?e:t}const Wu=To();function ui(e=Wu){return di(e)}const Ku=["ownerState"],Ju=["variants"],Zu=["name","slot","skipVariantsResolver","skipSx","overridesResolver"];function Qu(e){return Object.keys(e).length===0}function ep(e){return typeof e=="string"&&e.charCodeAt(0)>96}function qn(e){return e!=="ownerState"&&e!=="theme"&&e!=="sx"&&e!=="as"}const tp=To(),ja=e=>e&&e.charAt(0).toLowerCase()+e.slice(1);function Ln({defaultTheme:e,theme:t,themeId:n}){return Qu(t)?e:t[n]||t}function np(e){return e?(t,n)=>n[e]:null}function Hn(e,t){let{ownerState:n}=t,r=ye(t,Ku);const o=typeof e=="function"?e(R({ownerState:n},r)):e;if(Array.isArray(o))return o.flatMap(s=>Hn(s,R({ownerState:n},r)));if(o&&typeof o=="object"&&Array.isArray(o.variants)){const{variants:s=[]}=o;let l=ye(o,Ju);return s.forEach(c=>{let d=!0;typeof c.props=="function"?d=c.props(R({ownerState:n},r,n)):Object.keys(c.props).forEach(u=>{(n==null?void 0:n[u])!==c.props[u]&&r[u]!==c.props[u]&&(d=!1)}),d&&(Array.isArray(l)||(l=[l]),l.push(typeof c.style=="function"?c.style(R({ownerState:n},r,n)):c.style))}),l}return o}function rp(e={}){const{themeId:t,defaultTheme:n=tp,rootShouldForwardProp:r=qn,slotShouldForwardProp:o=qn}=e,s=i=>jo(R({},i,{theme:Ln(R({},i,{defaultTheme:n,themeId:t}))}));return s.__mui_systemSx=!0,(i,l={})=>{Fr.internal_processStyles(i,v=>v.filter(_=>!(_!=null&&_.__mui_systemSx)));const{name:c,slot:d,skipVariantsResolver:u,skipSx:f,overridesResolver:w=np(ja(d))}=l,b=ye(l,Zu),x=u!==void 0?u:d&&d!=="Root"&&d!=="root"||!1,m=f||!1;let h;process.env.NODE_ENV!=="production"&&c&&(h=`${c}-${ja(d||"Root")}`);let E=qn;d==="Root"||d==="root"?E=r:d?E=o:ep(i)&&(E=void 0);const I=Fr(i,R({shouldForwardProp:E,label:h},b)),C=v=>typeof v=="function"&&v.__emotion_real!==v||mt(v)?_=>Hn(v,R({},_,{theme:Ln({theme:_.theme,defaultTheme:n,themeId:t})})):v,S=(v,..._)=>{let V=C(v);const U=_?_.map(C):[];c&&w&&U.push(k=>{const D=Ln(R({},k,{defaultTheme:n,themeId:t}));if(!D.components||!D.components[c]||!D.components[c].styleOverrides)return null;const M=D.components[c].styleOverrides,J={};return Object.entries(M).forEach(([X,F])=>{J[X]=Hn(F,R({},k,{theme:D}))}),w(k,J)}),c&&!x&&U.push(k=>{var D;const M=Ln(R({},k,{defaultTheme:n,themeId:t})),J=M==null||(D=M.components)==null||(D=D[c])==null?void 0:D.variants;return Hn({variants:J},R({},k,{theme:M}))}),m||U.push(s);const j=U.length-_.length;if(Array.isArray(v)&&j>0){const k=new Array(j).fill("");V=[...v,...k],V.raw=[...v.raw,...k]}const O=I(V,...U);if(process.env.NODE_ENV!=="production"){let k;c&&(k=`${c}${Xe(d||"")}`),k===void 0&&(k=`Styled(${jd(i)})`),O.displayName=k}return i.muiName&&(O.muiName=i.muiName),O};return I.withConfig&&(S.withConfig=I.withConfig),S}}function op(e){const{theme:t,name:n,props:r}=e;return!t||!t.components||!t.components[n]||!t.components[n].defaultProps?r:ri(t.components[n].defaultProps,r)}function ap({props:e,name:t,defaultTheme:n,themeId:r}){let o=ui(n);return r&&(o=o[r]||o),op({theme:o,name:t,props:e})}function Co(e,t=0,n=1){return process.env.NODE_ENV!=="production"&&(en)&&console.error(`MUI: The value provided ${e} is out of range [${t}, ${n}].`),Wd(e,t,n)}function sp(e){e=e.slice(1);const t=new RegExp(`.{1,${e.length>=6?2:1}}`,"g");let n=e.match(t);return n&&n[0].length===1&&(n=n.map(r=>r+r)),n?`rgb${n.length===4?"a":""}(${n.map((r,o)=>o<3?parseInt(r,16):Math.round(parseInt(r,16)/255*1e3)/1e3).join(", ")})`:""}function Nt(e){if(e.type)return e;if(e.charAt(0)==="#")return Nt(sp(e));const t=e.indexOf("("),n=e.substring(0,t);if(["rgb","rgba","hsl","hsla","color"].indexOf(n)===-1)throw new Error(process.env.NODE_ENV!=="production"?`MUI: Unsupported \`${e}\` color. The following formats are supported: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color().`:zt(9,e));let r=e.substring(t+1,e.length-1),o;if(n==="color"){if(r=r.split(" "),o=r.shift(),r.length===4&&r[3].charAt(0)==="/"&&(r[3]=r[3].slice(1)),["srgb","display-p3","a98-rgb","prophoto-rgb","rec-2020"].indexOf(o)===-1)throw new Error(process.env.NODE_ENV!=="production"?`MUI: unsupported \`${o}\` color space. -The following color spaces are supported: srgb, display-p3, a98-rgb, prophoto-rgb, rec-2020.`:zt(10,o))}else r=r.split(",");return r=r.map(s=>parseFloat(s)),{type:n,values:r,colorSpace:o}}function xr(e){const{type:t,colorSpace:n}=e;let{values:r}=e;return t.indexOf("rgb")!==-1?r=r.map((o,s)=>s<3?parseInt(o,10):o):t.indexOf("hsl")!==-1&&(r[1]=`${r[1]}%`,r[2]=`${r[2]}%`),t.indexOf("color")!==-1?r=`${n} ${r.join(" ")}`:r=`${r.join(", ")}`,`${t}(${r})`}function vp(e){e=Nt(e);const{values:t}=e,n=t[0],r=t[1]/100,o=t[2]/100,s=r*Math.min(o,1-o),i=(d,u=(d+n/30)%12)=>o-s*Math.max(Math.min(u-3,9-u,1),-1);let l="rgb";const c=[Math.round(i(0)*255),Math.round(i(8)*255),Math.round(i(4)*255)];return e.type==="hsla"&&(l+="a",c.push(t[3])),xr({type:l,values:c})}function Ta(e){e=Nt(e);let t=e.type==="hsl"||e.type==="hsla"?Nt(vp(e)).values:e.values;return t=t.map(n=>(e.type!=="color"&&(n/=255),n<=.03928?n/12.92:((n+.055)/1.055)**2.4)),Number((.2126*t[0]+.7152*t[1]+.0722*t[2]).toFixed(3))}function Ra(e,t){const n=Ta(e),r=Ta(t);return(Math.max(n,r)+.05)/(Math.min(n,r)+.05)}function mi(e,t){return e=Nt(e),t=Ro(t),(e.type==="rgb"||e.type==="hsl")&&(e.type+="a"),e.type==="color"?e.values[3]=`/${t}`:e.values[3]=t,xr(e)}function xp(e,t){if(e=Nt(e),t=Ro(t),e.type.indexOf("hsl")!==-1)e.values[2]*=1-t;else if(e.type.indexOf("rgb")!==-1||e.type.indexOf("color")!==-1)for(let n=0;n<3;n+=1)e.values[n]*=1-t;return xr(e)}function yp(e,t){if(e=Nt(e),t=Ro(t),e.type.indexOf("hsl")!==-1)e.values[2]+=(100-e.values[2])*t;else if(e.type.indexOf("rgb")!==-1)for(let n=0;n<3;n+=1)e.values[n]+=(255-e.values[n])*t;else if(e.type.indexOf("color")!==-1)for(let n=0;n<3;n+=1)e.values[n]+=(1-e.values[n])*t;return xr(e)}function Np(e,t){return O({toolbar:{minHeight:56,[e.up("xs")]:{"@media (orientation: landscape)":{minHeight:48}},[e.up("sm")]:{minHeight:64}}},t)}const kp={black:"#000",white:"#fff"},yn=kp,Sp={50:"#fafafa",100:"#f5f5f5",200:"#eeeeee",300:"#e0e0e0",400:"#bdbdbd",500:"#9e9e9e",600:"#757575",700:"#616161",800:"#424242",900:"#212121",A100:"#f5f5f5",A200:"#eeeeee",A400:"#bdbdbd",A700:"#616161"},Ep=Sp,jp={50:"#f3e5f5",100:"#e1bee7",200:"#ce93d8",300:"#ba68c8",400:"#ab47bc",500:"#9c27b0",600:"#8e24aa",700:"#7b1fa2",800:"#6a1b9a",900:"#4a148c",A100:"#ea80fc",A200:"#e040fb",A400:"#d500f9",A700:"#aa00ff"},Rt=jp,Cp={50:"#ffebee",100:"#ffcdd2",200:"#ef9a9a",300:"#e57373",400:"#ef5350",500:"#f44336",600:"#e53935",700:"#d32f2f",800:"#c62828",900:"#b71c1c",A100:"#ff8a80",A200:"#ff5252",A400:"#ff1744",A700:"#d50000"},Ot=Cp,Tp={50:"#fff3e0",100:"#ffe0b2",200:"#ffcc80",300:"#ffb74d",400:"#ffa726",500:"#ff9800",600:"#fb8c00",700:"#f57c00",800:"#ef6c00",900:"#e65100",A100:"#ffd180",A200:"#ffab40",A400:"#ff9100",A700:"#ff6d00"},on=Tp,Rp={50:"#e3f2fd",100:"#bbdefb",200:"#90caf9",300:"#64b5f6",400:"#42a5f5",500:"#2196f3",600:"#1e88e5",700:"#1976d2",800:"#1565c0",900:"#0d47a1",A100:"#82b1ff",A200:"#448aff",A400:"#2979ff",A700:"#2962ff"},_t=Rp,Op={50:"#e1f5fe",100:"#b3e5fc",200:"#81d4fa",300:"#4fc3f7",400:"#29b6f6",500:"#03a9f4",600:"#039be5",700:"#0288d1",800:"#0277bd",900:"#01579b",A100:"#80d8ff",A200:"#40c4ff",A400:"#00b0ff",A700:"#0091ea"},Pt=Op,_p={50:"#e8f5e9",100:"#c8e6c9",200:"#a5d6a7",300:"#81c784",400:"#66bb6a",500:"#4caf50",600:"#43a047",700:"#388e3c",800:"#2e7d32",900:"#1b5e20",A100:"#b9f6ca",A200:"#69f0ae",A400:"#00e676",A700:"#00c853"},It=_p,Pp=["mode","contrastThreshold","tonalOffset"],Oa={text:{primary:"rgba(0, 0, 0, 0.87)",secondary:"rgba(0, 0, 0, 0.6)",disabled:"rgba(0, 0, 0, 0.38)"},divider:"rgba(0, 0, 0, 0.12)",background:{paper:yn.white,default:yn.white},action:{active:"rgba(0, 0, 0, 0.54)",hover:"rgba(0, 0, 0, 0.04)",hoverOpacity:.04,selected:"rgba(0, 0, 0, 0.08)",selectedOpacity:.08,disabled:"rgba(0, 0, 0, 0.26)",disabledBackground:"rgba(0, 0, 0, 0.12)",disabledOpacity:.38,focus:"rgba(0, 0, 0, 0.12)",focusOpacity:.12,activatedOpacity:.12}},zr={text:{primary:yn.white,secondary:"rgba(255, 255, 255, 0.7)",disabled:"rgba(255, 255, 255, 0.5)",icon:"rgba(255, 255, 255, 0.5)"},divider:"rgba(255, 255, 255, 0.12)",background:{paper:"#121212",default:"#121212"},action:{active:yn.white,hover:"rgba(255, 255, 255, 0.08)",hoverOpacity:.08,selected:"rgba(255, 255, 255, 0.16)",selectedOpacity:.16,disabled:"rgba(255, 255, 255, 0.3)",disabledBackground:"rgba(255, 255, 255, 0.12)",disabledOpacity:.38,focus:"rgba(255, 255, 255, 0.12)",focusOpacity:.12,activatedOpacity:.24}};function _a(e,t,n,r){const o=r.light||r,s=r.dark||r*1.5;e[t]||(e.hasOwnProperty(n)?e[t]=e[n]:t==="light"?e.light=yp(e.main,o):t==="dark"&&(e.dark=xp(e.main,s)))}function Ip(e="light"){return e==="dark"?{main:_t[200],light:_t[50],dark:_t[400]}:{main:_t[700],light:_t[400],dark:_t[800]}}function Mp(e="light"){return e==="dark"?{main:Rt[200],light:Rt[50],dark:Rt[400]}:{main:Rt[500],light:Rt[300],dark:Rt[700]}}function $p(e="light"){return e==="dark"?{main:Ot[500],light:Ot[300],dark:Ot[700]}:{main:Ot[700],light:Ot[400],dark:Ot[800]}}function Dp(e="light"){return e==="dark"?{main:Pt[400],light:Pt[300],dark:Pt[700]}:{main:Pt[700],light:Pt[500],dark:Pt[900]}}function Ap(e="light"){return e==="dark"?{main:It[400],light:It[300],dark:It[700]}:{main:It[800],light:It[500],dark:It[900]}}function Bp(e="light"){return e==="dark"?{main:on[400],light:on[300],dark:on[700]}:{main:"#ed6c02",light:on[500],dark:on[900]}}function Vp(e){const{mode:t="light",contrastThreshold:n=3,tonalOffset:r=.2}=e,o=Ne(e,Pp),s=e.primary||Ip(t),i=e.secondary||Mp(t),l=e.error||$p(t),c=e.info||Dp(t),d=e.success||Ap(t),u=e.warning||Bp(t);function f(m){const h=Ra(m,zr.text.primary)>=n?zr.text.primary:Oa.text.primary;if(process.env.NODE_ENV!=="production"){const S=Ra(m,h);S<3&&console.error([`MUI: The contrast ratio of ${S}:1 for ${h} on ${m}`,"falls below the WCAG recommended absolute minimum contrast ratio of 3:1.","https://www.w3.org/TR/2008/REC-WCAG20-20081211/#visual-audio-contrast-contrast"].join(` -`))}return h}const w=({color:m,name:h,mainShade:S=500,lightShade:R=300,darkShade:j=700})=>{if(m=O({},m),!m.main&&m[S]&&(m.main=m[S]),!m.hasOwnProperty("main"))throw new Error(process.env.NODE_ENV!=="production"?`MUI: The color${h?` (${h})`:""} provided to augmentColor(color) is invalid. -The color object needs to have a \`main\` property or a \`${S}\` property.`:zt(11,h?` (${h})`:"",S));if(typeof m.main!="string")throw new Error(process.env.NODE_ENV!=="production"?`MUI: The color${h?` (${h})`:""} provided to augmentColor(color) is invalid. +The following color spaces are supported: srgb, display-p3, a98-rgb, prophoto-rgb, rec-2020.`:zt(10,o))}else r=r.split(",");return r=r.map(s=>parseFloat(s)),{type:n,values:r,colorSpace:o}}function xr(e){const{type:t,colorSpace:n}=e;let{values:r}=e;return t.indexOf("rgb")!==-1?r=r.map((o,s)=>s<3?parseInt(o,10):o):t.indexOf("hsl")!==-1&&(r[1]=`${r[1]}%`,r[2]=`${r[2]}%`),t.indexOf("color")!==-1?r=`${n} ${r.join(" ")}`:r=`${r.join(", ")}`,`${t}(${r})`}function ip(e){e=Nt(e);const{values:t}=e,n=t[0],r=t[1]/100,o=t[2]/100,s=r*Math.min(o,1-o),i=(d,u=(d+n/30)%12)=>o-s*Math.max(Math.min(u-3,9-u,1),-1);let l="rgb";const c=[Math.round(i(0)*255),Math.round(i(8)*255),Math.round(i(4)*255)];return e.type==="hsla"&&(l+="a",c.push(t[3])),xr({type:l,values:c})}function Ta(e){e=Nt(e);let t=e.type==="hsl"||e.type==="hsla"?Nt(ip(e)).values:e.values;return t=t.map(n=>(e.type!=="color"&&(n/=255),n<=.03928?n/12.92:((n+.055)/1.055)**2.4)),Number((.2126*t[0]+.7152*t[1]+.0722*t[2]).toFixed(3))}function Ca(e,t){const n=Ta(e),r=Ta(t);return(Math.max(n,r)+.05)/(Math.min(n,r)+.05)}function pi(e,t){return e=Nt(e),t=Co(t),(e.type==="rgb"||e.type==="hsl")&&(e.type+="a"),e.type==="color"?e.values[3]=`/${t}`:e.values[3]=t,xr(e)}function lp(e,t){if(e=Nt(e),t=Co(t),e.type.indexOf("hsl")!==-1)e.values[2]*=1-t;else if(e.type.indexOf("rgb")!==-1||e.type.indexOf("color")!==-1)for(let n=0;n<3;n+=1)e.values[n]*=1-t;return xr(e)}function cp(e,t){if(e=Nt(e),t=Co(t),e.type.indexOf("hsl")!==-1)e.values[2]+=(100-e.values[2])*t;else if(e.type.indexOf("rgb")!==-1)for(let n=0;n<3;n+=1)e.values[n]+=(255-e.values[n])*t;else if(e.type.indexOf("color")!==-1)for(let n=0;n<3;n+=1)e.values[n]+=(1-e.values[n])*t;return xr(e)}function dp(e,t){return R({toolbar:{minHeight:56,[e.up("xs")]:{"@media (orientation: landscape)":{minHeight:48}},[e.up("sm")]:{minHeight:64}}},t)}const up={black:"#000",white:"#fff"},xn=up,pp={50:"#fafafa",100:"#f5f5f5",200:"#eeeeee",300:"#e0e0e0",400:"#bdbdbd",500:"#9e9e9e",600:"#757575",700:"#616161",800:"#424242",900:"#212121",A100:"#f5f5f5",A200:"#eeeeee",A400:"#bdbdbd",A700:"#616161"},wp=pp,fp={50:"#f3e5f5",100:"#e1bee7",200:"#ce93d8",300:"#ba68c8",400:"#ab47bc",500:"#9c27b0",600:"#8e24aa",700:"#7b1fa2",800:"#6a1b9a",900:"#4a148c",A100:"#ea80fc",A200:"#e040fb",A400:"#d500f9",A700:"#aa00ff"},Rt=fp,mp={50:"#ffebee",100:"#ffcdd2",200:"#ef9a9a",300:"#e57373",400:"#ef5350",500:"#f44336",600:"#e53935",700:"#d32f2f",800:"#c62828",900:"#b71c1c",A100:"#ff8a80",A200:"#ff5252",A400:"#ff1744",A700:"#d50000"},Ot=mp,hp={50:"#fff3e0",100:"#ffe0b2",200:"#ffcc80",300:"#ffb74d",400:"#ffa726",500:"#ff9800",600:"#fb8c00",700:"#f57c00",800:"#ef6c00",900:"#e65100",A100:"#ffd180",A200:"#ffab40",A400:"#ff9100",A700:"#ff6d00"},rn=hp,gp={50:"#e3f2fd",100:"#bbdefb",200:"#90caf9",300:"#64b5f6",400:"#42a5f5",500:"#2196f3",600:"#1e88e5",700:"#1976d2",800:"#1565c0",900:"#0d47a1",A100:"#82b1ff",A200:"#448aff",A400:"#2979ff",A700:"#2962ff"},_t=gp,bp={50:"#e1f5fe",100:"#b3e5fc",200:"#81d4fa",300:"#4fc3f7",400:"#29b6f6",500:"#03a9f4",600:"#039be5",700:"#0288d1",800:"#0277bd",900:"#01579b",A100:"#80d8ff",A200:"#40c4ff",A400:"#00b0ff",A700:"#0091ea"},Pt=bp,vp={50:"#e8f5e9",100:"#c8e6c9",200:"#a5d6a7",300:"#81c784",400:"#66bb6a",500:"#4caf50",600:"#43a047",700:"#388e3c",800:"#2e7d32",900:"#1b5e20",A100:"#b9f6ca",A200:"#69f0ae",A400:"#00e676",A700:"#00c853"},It=vp,xp=["mode","contrastThreshold","tonalOffset"],Ra={text:{primary:"rgba(0, 0, 0, 0.87)",secondary:"rgba(0, 0, 0, 0.6)",disabled:"rgba(0, 0, 0, 0.38)"},divider:"rgba(0, 0, 0, 0.12)",background:{paper:xn.white,default:xn.white},action:{active:"rgba(0, 0, 0, 0.54)",hover:"rgba(0, 0, 0, 0.04)",hoverOpacity:.04,selected:"rgba(0, 0, 0, 0.08)",selectedOpacity:.08,disabled:"rgba(0, 0, 0, 0.26)",disabledBackground:"rgba(0, 0, 0, 0.12)",disabledOpacity:.38,focus:"rgba(0, 0, 0, 0.12)",focusOpacity:.12,activatedOpacity:.12}},Vr={text:{primary:xn.white,secondary:"rgba(255, 255, 255, 0.7)",disabled:"rgba(255, 255, 255, 0.5)",icon:"rgba(255, 255, 255, 0.5)"},divider:"rgba(255, 255, 255, 0.12)",background:{paper:"#121212",default:"#121212"},action:{active:xn.white,hover:"rgba(255, 255, 255, 0.08)",hoverOpacity:.08,selected:"rgba(255, 255, 255, 0.16)",selectedOpacity:.16,disabled:"rgba(255, 255, 255, 0.3)",disabledBackground:"rgba(255, 255, 255, 0.12)",disabledOpacity:.38,focus:"rgba(255, 255, 255, 0.12)",focusOpacity:.12,activatedOpacity:.24}};function Oa(e,t,n,r){const o=r.light||r,s=r.dark||r*1.5;e[t]||(e.hasOwnProperty(n)?e[t]=e[n]:t==="light"?e.light=cp(e.main,o):t==="dark"&&(e.dark=lp(e.main,s)))}function yp(e="light"){return e==="dark"?{main:_t[200],light:_t[50],dark:_t[400]}:{main:_t[700],light:_t[400],dark:_t[800]}}function Np(e="light"){return e==="dark"?{main:Rt[200],light:Rt[50],dark:Rt[400]}:{main:Rt[500],light:Rt[300],dark:Rt[700]}}function kp(e="light"){return e==="dark"?{main:Ot[500],light:Ot[300],dark:Ot[700]}:{main:Ot[700],light:Ot[400],dark:Ot[800]}}function Sp(e="light"){return e==="dark"?{main:Pt[400],light:Pt[300],dark:Pt[700]}:{main:Pt[700],light:Pt[500],dark:Pt[900]}}function Ep(e="light"){return e==="dark"?{main:It[400],light:It[300],dark:It[700]}:{main:It[800],light:It[500],dark:It[900]}}function jp(e="light"){return e==="dark"?{main:rn[400],light:rn[300],dark:rn[700]}:{main:"#ed6c02",light:rn[500],dark:rn[900]}}function Tp(e){const{mode:t="light",contrastThreshold:n=3,tonalOffset:r=.2}=e,o=ye(e,xp),s=e.primary||yp(t),i=e.secondary||Np(t),l=e.error||kp(t),c=e.info||Sp(t),d=e.success||Ep(t),u=e.warning||jp(t);function f(m){const h=Ca(m,Vr.text.primary)>=n?Vr.text.primary:Ra.text.primary;if(process.env.NODE_ENV!=="production"){const E=Ca(m,h);E<3&&console.error([`MUI: The contrast ratio of ${E}:1 for ${h} on ${m}`,"falls below the WCAG recommended absolute minimum contrast ratio of 3:1.","https://www.w3.org/TR/2008/REC-WCAG20-20081211/#visual-audio-contrast-contrast"].join(` +`))}return h}const w=({color:m,name:h,mainShade:E=500,lightShade:I=300,darkShade:C=700})=>{if(m=R({},m),!m.main&&m[E]&&(m.main=m[E]),!m.hasOwnProperty("main"))throw new Error(process.env.NODE_ENV!=="production"?`MUI: The color${h?` (${h})`:""} provided to augmentColor(color) is invalid. +The color object needs to have a \`main\` property or a \`${E}\` property.`:zt(11,h?` (${h})`:"",E));if(typeof m.main!="string")throw new Error(process.env.NODE_ENV!=="production"?`MUI: The color${h?` (${h})`:""} provided to augmentColor(color) is invalid. \`color.main\` should be a string, but \`${JSON.stringify(m.main)}\` was provided instead. Did you intend to use one of the following approaches? @@ -55,16 +55,16 @@ const theme1 = createTheme({ palette: { const theme2 = createTheme({ palette: { primary: { main: green[500] }, -} });`:zt(12,h?` (${h})`:"",JSON.stringify(m.main)));return _a(m,"light",R,r),_a(m,"dark",j,r),m.contrastText||(m.contrastText=f(m.main)),m},b={dark:zr,light:Oa};return process.env.NODE_ENV!=="production"&&(b[t]||console.error(`MUI: The palette mode \`${t}\` is not supported.`)),Qe(O({common:O({},yn),mode:t,primary:w({color:s,name:"primary"}),secondary:w({color:i,name:"secondary",mainShade:"A400",lightShade:"A200",darkShade:"A700"}),error:w({color:l,name:"error"}),warning:w({color:u,name:"warning"}),info:w({color:c,name:"info"}),success:w({color:d,name:"success"}),grey:Ep,contrastThreshold:n,getContrastText:f,augmentColor:w,tonalOffset:r},b[t]),o)}const zp=["fontFamily","fontSize","fontWeightLight","fontWeightRegular","fontWeightMedium","fontWeightBold","htmlFontSize","allVariants","pxToRem"];function Lp(e){return Math.round(e*1e5)/1e5}const Pa={textTransform:"uppercase"},Ia='"Roboto", "Helvetica", "Arial", sans-serif';function Fp(e,t){const n=typeof t=="function"?t(e):t,{fontFamily:r=Ia,fontSize:o=14,fontWeightLight:s=300,fontWeightRegular:i=400,fontWeightMedium:l=500,fontWeightBold:c=700,htmlFontSize:d=16,allVariants:u,pxToRem:f}=n,w=Ne(n,zp);process.env.NODE_ENV!=="production"&&(typeof o!="number"&&console.error("MUI: `fontSize` is required to be a number."),typeof d!="number"&&console.error("MUI: `htmlFontSize` is required to be a number."));const b=o/14,x=f||(S=>`${S/d*b}rem`),m=(S,R,j,E,v)=>O({fontFamily:r,fontWeight:S,fontSize:x(R),lineHeight:j},r===Ia?{letterSpacing:`${Lp(E/R)}em`}:{},v,u),h={h1:m(s,96,1.167,-1.5),h2:m(s,60,1.2,-.5),h3:m(i,48,1.167,0),h4:m(i,34,1.235,.25),h5:m(i,24,1.334,0),h6:m(l,20,1.6,.15),subtitle1:m(i,16,1.75,.15),subtitle2:m(l,14,1.57,.1),body1:m(i,16,1.5,.15),body2:m(i,14,1.43,.15),button:m(l,14,1.75,.4,Pa),caption:m(i,12,1.66,.4),overline:m(i,12,2.66,1,Pa),inherit:{fontFamily:"inherit",fontWeight:"inherit",fontSize:"inherit",lineHeight:"inherit",letterSpacing:"inherit"}};return Qe(O({htmlFontSize:d,pxToRem:x,fontFamily:r,fontSize:o,fontWeightLight:s,fontWeightRegular:i,fontWeightMedium:l,fontWeightBold:c},h),w,{clone:!1})}const Gp=.2,Up=.14,qp=.12;function we(...e){return[`${e[0]}px ${e[1]}px ${e[2]}px ${e[3]}px rgba(0,0,0,${Gp})`,`${e[4]}px ${e[5]}px ${e[6]}px ${e[7]}px rgba(0,0,0,${Up})`,`${e[8]}px ${e[9]}px ${e[10]}px ${e[11]}px rgba(0,0,0,${qp})`].join(",")}const Hp=["none",we(0,2,1,-1,0,1,1,0,0,1,3,0),we(0,3,1,-2,0,2,2,0,0,1,5,0),we(0,3,3,-2,0,3,4,0,0,1,8,0),we(0,2,4,-1,0,4,5,0,0,1,10,0),we(0,3,5,-1,0,5,8,0,0,1,14,0),we(0,3,5,-1,0,6,10,0,0,1,18,0),we(0,4,5,-2,0,7,10,1,0,2,16,1),we(0,5,5,-3,0,8,10,1,0,3,14,2),we(0,5,6,-3,0,9,12,1,0,3,16,2),we(0,6,6,-3,0,10,14,1,0,4,18,3),we(0,6,7,-4,0,11,15,1,0,4,20,3),we(0,7,8,-4,0,12,17,2,0,5,22,4),we(0,7,8,-4,0,13,19,2,0,5,24,4),we(0,7,9,-4,0,14,21,2,0,5,26,4),we(0,8,9,-5,0,15,22,2,0,6,28,5),we(0,8,10,-5,0,16,24,2,0,6,30,5),we(0,8,11,-5,0,17,26,2,0,6,32,5),we(0,9,11,-5,0,18,28,2,0,7,34,6),we(0,9,12,-6,0,19,29,2,0,7,36,6),we(0,10,13,-6,0,20,31,3,0,8,38,7),we(0,10,13,-6,0,21,33,3,0,8,40,7),we(0,10,14,-6,0,22,35,3,0,8,42,7),we(0,11,14,-7,0,23,36,3,0,9,44,8),we(0,11,15,-7,0,24,38,3,0,9,46,8)],Xp=Hp,Yp=["duration","easing","delay"],Wp={easeInOut:"cubic-bezier(0.4, 0, 0.2, 1)",easeOut:"cubic-bezier(0.0, 0, 0.2, 1)",easeIn:"cubic-bezier(0.4, 0, 1, 1)",sharp:"cubic-bezier(0.4, 0, 0.6, 1)"},Kp={shortest:150,shorter:200,short:250,standard:300,complex:375,enteringScreen:225,leavingScreen:195};function Ma(e){return`${Math.round(e)}ms`}function Jp(e){if(!e)return 0;const t=e/36;return Math.round((4+15*t**.25+t/5)*10)}function Zp(e){const t=O({},Wp,e.easing),n=O({},Kp,e.duration);return O({getAutoHeightDuration:Jp,create:(o=["all"],s={})=>{const{duration:i=n.standard,easing:l=t.easeInOut,delay:c=0}=s,d=Ne(s,Yp);if(process.env.NODE_ENV!=="production"){const u=w=>typeof w=="string",f=w=>!isNaN(parseFloat(w));!u(o)&&!Array.isArray(o)&&console.error('MUI: Argument "props" must be a string or Array.'),!f(i)&&!u(i)&&console.error(`MUI: Argument "duration" must be a number or a string but found ${i}.`),u(l)||console.error('MUI: Argument "easing" must be a string.'),!f(c)&&!u(c)&&console.error('MUI: Argument "delay" must be a number or a string.'),typeof s!="object"&&console.error(["MUI: Secong argument of transition.create must be an object.","Arguments should be either `create('prop1', options)` or `create(['prop1', 'prop2'], options)`"].join(` -`)),Object.keys(d).length!==0&&console.error(`MUI: Unrecognized argument(s) [${Object.keys(d).join(",")}].`)}return(Array.isArray(o)?o:[o]).map(u=>`${u} ${typeof i=="string"?i:Ma(i)} ${l} ${typeof c=="string"?c:Ma(c)}`).join(",")}},e,{easing:t,duration:n})}const Qp={mobileStepper:1e3,fab:1050,speedDial:1050,appBar:1100,drawer:1200,modal:1300,snackbar:1400,tooltip:1500},ew=Qp,tw=["breakpoints","mixins","spacing","palette","transitions","typography","shape"];function nw(e={},...t){const{mixins:n={},palette:r={},transitions:o={},typography:s={}}=e,i=Ne(e,tw);if(e.vars)throw new Error(process.env.NODE_ENV!=="production"?"MUI: `vars` is a private field used for CSS variables support.\nPlease use another name.":zt(18));const l=Vp(r),c=To(e);let d=Qe(c,{mixins:Np(c.breakpoints,n),palette:l,shadows:Xp.slice(),typography:Fp(l,s),transitions:Zp(o),zIndex:O({},ew)});if(d=Qe(d,i),d=t.reduce((u,f)=>Qe(u,f),d),process.env.NODE_ENV!=="production"){const u=["active","checked","completed","disabled","error","expanded","focused","focusVisible","required","selected"],f=(w,b)=>{let x;for(x in w){const m=w[x];if(u.indexOf(x)!==-1&&Object.keys(m).length>0){if(process.env.NODE_ENV!=="production"){const h=ur("",x);console.error([`MUI: The \`${b}\` component increases the CSS specificity of the \`${x}\` internal state.`,"You can not override it like this: ",JSON.stringify(w,null,2),"",`Instead, you need to use the '&.${h}' syntax:`,JSON.stringify({root:{[`&.${h}`]:m}},null,2),"","https://mui.com/r/state-classes-guide"].join(` -`))}w[x]={}}}};Object.keys(d.components).forEach(w=>{const b=d.components[w].styleOverrides;b&&w.indexOf("Mui")===0&&f(b,w)})}return d.unstable_sxConfig=O({},jo,i==null?void 0:i.unstable_sxConfig),d.unstable_sx=function(f){return Co({sx:f,theme:this})},d}const rw=nw(),Oo=rw,_o="$$material";function Po({props:e,name:t}){return gp({props:e,name:t,defaultTheme:Oo,themeId:_o})}const ow=e=>qn(e)&&e!=="classes",aw=mp({themeId:_o,defaultTheme:Oo,rootShouldForwardProp:ow}),In=aw;function sw(e){return ur("MuiSvgIcon",e)}ci("MuiSvgIcon",["root","colorPrimary","colorSecondary","colorAction","colorError","colorDisabled","fontSizeInherit","fontSizeSmall","fontSizeMedium","fontSizeLarge"]);const iw=["children","className","color","component","fontSize","htmlColor","inheritViewBox","titleAccess","viewBox"],lw=e=>{const{color:t,fontSize:n,classes:r}=e,o={root:["root",t!=="inherit"&&`color${Ye(t)}`,`fontSize${Ye(n)}`]};return ko(o,sw,r)},cw=In("svg",{name:"MuiSvgIcon",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.root,n.color!=="inherit"&&t[`color${Ye(n.color)}`],t[`fontSize${Ye(n.fontSize)}`]]}})(({theme:e,ownerState:t})=>{var n,r,o,s,i,l,c,d,u,f,w,b,x;return{userSelect:"none",width:"1em",height:"1em",display:"inline-block",fill:t.hasSvgAsChild?void 0:"currentColor",flexShrink:0,transition:(n=e.transitions)==null||(r=n.create)==null?void 0:r.call(n,"fill",{duration:(o=e.transitions)==null||(o=o.duration)==null?void 0:o.shorter}),fontSize:{inherit:"inherit",small:((s=e.typography)==null||(i=s.pxToRem)==null?void 0:i.call(s,20))||"1.25rem",medium:((l=e.typography)==null||(c=l.pxToRem)==null?void 0:c.call(l,24))||"1.5rem",large:((d=e.typography)==null||(u=d.pxToRem)==null?void 0:u.call(d,35))||"2.1875rem"}[t.fontSize],color:(f=(w=(e.vars||e).palette)==null||(w=w[t.color])==null?void 0:w.main)!=null?f:{action:(b=(e.vars||e).palette)==null||(b=b.action)==null?void 0:b.active,disabled:(x=(e.vars||e).palette)==null||(x=x.action)==null?void 0:x.disabled,inherit:void 0}[t.color]}}),Io=M.forwardRef(function(t,n){const r=Po({props:t,name:"MuiSvgIcon"}),{children:o,className:s,color:i="inherit",component:l="svg",fontSize:c="medium",htmlColor:d,inheritViewBox:u=!1,titleAccess:f,viewBox:w="0 0 24 24"}=r,b=Ne(r,iw),x=M.isValidElement(o)&&o.type==="svg",m=O({},r,{color:i,component:l,fontSize:c,instanceFontSize:t.fontSize,inheritViewBox:u,viewBox:w,hasSvgAsChild:x}),h={};u||(h.viewBox=w);const S=lw(m);return a.jsxs(cw,O({as:l,className:ot(S.root,s),focusable:"false",color:d,"aria-hidden":f?void 0:!0,role:f?"img":void 0,ref:n},h,b,x&&o.props,{ownerState:m,children:[x?o.props.children:o,f?a.jsx("title",{children:f}):null]}))});process.env.NODE_ENV!=="production"&&(Io.propTypes={children:p.node,classes:p.object,className:p.string,color:p.oneOfType([p.oneOf(["inherit","action","disabled","primary","secondary","error","info","success","warning"]),p.string]),component:p.elementType,fontSize:p.oneOfType([p.oneOf(["inherit","large","medium","small"]),p.string]),htmlColor:p.string,inheritViewBox:p.bool,shapeRendering:p.string,sx:p.oneOfType([p.arrayOf(p.oneOfType([p.func,p.object,p.bool])),p.func,p.object]),titleAccess:p.string,viewBox:p.string});Io.muiName="SvgIcon";const $a=Io;function hi(e,t){function n(r,o){return a.jsx($a,O({"data-testid":`${t}Icon`,ref:o},r,{children:e}))}return process.env.NODE_ENV!=="production"&&(n.displayName=`${t}Icon`),n.muiName=$a.muiName,M.memo(M.forwardRef(n))}const dw={configure:e=>{process.env.NODE_ENV!=="production"&&console.warn(["MUI: `ClassNameGenerator` import from `@mui/material/utils` is outdated and might cause unexpected issues.","","You should use `import { unstable_ClassNameGenerator } from '@mui/material/className'` instead","","The detail of the issue: https://github.com/mui/material-ui/issues/30011#issuecomment-1024993401","","The updated documentation: https://mui.com/guides/classname-generator/"].join(` -`)),ii.configure(e)}},uw=Object.freeze(Object.defineProperty({__proto__:null,capitalize:Ye,createChainedFunction:zd,createSvgIcon:hi,debounce:Ld,deprecatedPropType:Fd,isMuiElement:Gd,ownerDocument:Kn,ownerWindow:Ud,requirePropFactory:qd,setRef:Jn,unstable_ClassNameGenerator:dw,unstable_useEnhancedEffect:Lt,unstable_useId:ri,unsupportedProp:Yd,useControlled:oi,useEventCallback:Zr,useForkRef:yt,useIsFocusVisible:ai},Symbol.toStringTag,{value:"Module"})),pw=xd(uw);var Da;function ww(){return Da||(Da=1,function(e){"use client";Object.defineProperty(e,"__esModule",{value:!0}),Object.defineProperty(e,"default",{enumerable:!0,get:function(){return t.createSvgIcon}});var t=pw}(Pr)),Pr}var fw=yd;Object.defineProperty(xo,"__esModule",{value:!0});var gi=xo.default=void 0,mw=fw(ww()),hw=a;gi=xo.default=(0,mw.default)((0,hw.jsx)("path",{d:"m10 17 5-5-5-5z"}),"ArrowRight");function gw(e){return typeof e=="string"}function un(e,t,n){return e===void 0||gw(e)?t:O({},t,{ownerState:O({},t.ownerState,n)})}const bw={disableDefaultClasses:!1},vw=M.createContext(bw);function xw(e){const{disableDefaultClasses:t}=M.useContext(vw);return n=>t?"":e(n)}function yw(e,t=[]){if(e===void 0)return{};const n={};return Object.keys(e).filter(r=>r.match(/^on[A-Z]/)&&typeof e[r]=="function"&&!t.includes(r)).forEach(r=>{n[r]=e[r]}),n}function Nw(e,t,n){return typeof e=="function"?e(t,n):e}function Aa(e){if(e===void 0)return{};const t={};return Object.keys(e).filter(n=>!(n.match(/^on[A-Z]/)&&typeof e[n]=="function")).forEach(n=>{t[n]=e[n]}),t}function kw(e){const{getSlotProps:t,additionalProps:n,externalSlotProps:r,externalForwardedProps:o,className:s}=e;if(!t){const b=ot(n==null?void 0:n.className,s,o==null?void 0:o.className,r==null?void 0:r.className),x=O({},n==null?void 0:n.style,o==null?void 0:o.style,r==null?void 0:r.style),m=O({},n,o,r);return b.length>0&&(m.className=b),Object.keys(x).length>0&&(m.style=x),{props:m,internalRef:void 0}}const i=yw(O({},o,r)),l=Aa(r),c=Aa(o),d=t(i),u=ot(d==null?void 0:d.className,n==null?void 0:n.className,s,o==null?void 0:o.className,r==null?void 0:r.className),f=O({},d==null?void 0:d.style,n==null?void 0:n.style,o==null?void 0:o.style,r==null?void 0:r.style),w=O({},d,n,c,l);return u.length>0&&(w.className=u),Object.keys(f).length>0&&(w.style=f),{props:w,internalRef:d.ref}}const Sw=["elementType","externalSlotProps","ownerState","skipResolvingSlotProps"];function Ew(e){var t;const{elementType:n,externalSlotProps:r,ownerState:o,skipResolvingSlotProps:s=!1}=e,i=Ne(e,Sw),l=s?{}:Nw(r,o),{props:c,internalRef:d}=kw(O({},i,{externalSlotProps:l})),u=yt(d,l==null?void 0:l.ref,(t=e.additionalProps)==null?void 0:t.ref);return un(n,O({},c,{ref:u}),o)}const bi="base";function jw(e){return`${bi}--${e}`}function Cw(e,t){return`${bi}-${e}-${t}`}function vi(e,t){const n=li[t];return n?jw(n):Cw(e,t)}function Tw(e,t){const n={};return t.forEach(r=>{n[r]=vi(e,r)}),n}function Rw(e){return typeof e=="function"?e():e}const Qn=M.forwardRef(function(t,n){const{children:r,container:o,disablePortal:s=!1}=t,[i,l]=M.useState(null),c=yt(M.isValidElement(r)?r.ref:null,n);if(Lt(()=>{s||l(Rw(o)||document.body)},[o,s]),Lt(()=>{if(i&&!s)return Jn(n,i),()=>{Jn(n,null)}},[n,i,s]),s){if(M.isValidElement(r)){const d={ref:c};return M.cloneElement(r,d)}return a.jsx(M.Fragment,{children:r})}return a.jsx(M.Fragment,{children:i&&Ol.createPortal(r,i)})});process.env.NODE_ENV!=="production"&&(Qn.propTypes={children:p.node,container:p.oneOfType([xn,p.func]),disablePortal:p.bool});process.env.NODE_ENV!=="production"&&(Qn["propTypes"]=Id(Qn.propTypes));var Ce="top",ze="bottom",Le="right",Te="left",Mo="auto",Mn=[Ce,ze,Le,Te],Ft="start",Nn="end",Ow="clippingParents",xi="viewport",an="popper",_w="reference",Ba=Mn.reduce(function(e,t){return e.concat([t+"-"+Ft,t+"-"+Nn])},[]),yi=[].concat(Mn,[Mo]).reduce(function(e,t){return e.concat([t,t+"-"+Ft,t+"-"+Nn])},[]),Pw="beforeRead",Iw="read",Mw="afterRead",$w="beforeMain",Dw="main",Aw="afterMain",Bw="beforeWrite",Vw="write",zw="afterWrite",Lw=[Pw,Iw,Mw,$w,Dw,Aw,Bw,Vw,zw];function We(e){return e?(e.nodeName||"").toLowerCase():null}function $e(e){if(e==null)return window;if(e.toString()!=="[object Window]"){var t=e.ownerDocument;return t&&t.defaultView||window}return e}function kt(e){var t=$e(e).Element;return e instanceof t||e instanceof Element}function Ve(e){var t=$e(e).HTMLElement;return e instanceof t||e instanceof HTMLElement}function $o(e){if(typeof ShadowRoot>"u")return!1;var t=$e(e).ShadowRoot;return e instanceof t||e instanceof ShadowRoot}function Fw(e){var t=e.state;Object.keys(t.elements).forEach(function(n){var r=t.styles[n]||{},o=t.attributes[n]||{},s=t.elements[n];!Ve(s)||!We(s)||(Object.assign(s.style,r),Object.keys(o).forEach(function(i){var l=o[i];l===!1?s.removeAttribute(i):s.setAttribute(i,l===!0?"":l)}))})}function Gw(e){var t=e.state,n={popper:{position:t.options.strategy,left:"0",top:"0",margin:"0"},arrow:{position:"absolute"},reference:{}};return Object.assign(t.elements.popper.style,n.popper),t.styles=n,t.elements.arrow&&Object.assign(t.elements.arrow.style,n.arrow),function(){Object.keys(t.elements).forEach(function(r){var o=t.elements[r],s=t.attributes[r]||{},i=Object.keys(t.styles.hasOwnProperty(r)?t.styles[r]:n[r]),l=i.reduce(function(c,d){return c[d]="",c},{});!Ve(o)||!We(o)||(Object.assign(o.style,l),Object.keys(s).forEach(function(c){o.removeAttribute(c)}))})}}const Uw={name:"applyStyles",enabled:!0,phase:"write",fn:Fw,effect:Gw,requires:["computeStyles"]};function Xe(e){return e.split("-")[0]}var ht=Math.max,er=Math.min,Gt=Math.round;function eo(){var e=navigator.userAgentData;return e!=null&&e.brands&&Array.isArray(e.brands)?e.brands.map(function(t){return t.brand+"/"+t.version}).join(" "):navigator.userAgent}function Ni(){return!/^((?!chrome|android).)*safari/i.test(eo())}function Ut(e,t,n){t===void 0&&(t=!1),n===void 0&&(n=!1);var r=e.getBoundingClientRect(),o=1,s=1;t&&Ve(e)&&(o=e.offsetWidth>0&&Gt(r.width)/e.offsetWidth||1,s=e.offsetHeight>0&&Gt(r.height)/e.offsetHeight||1);var i=kt(e)?$e(e):window,l=i.visualViewport,c=!Ni()&&n,d=(r.left+(c&&l?l.offsetLeft:0))/o,u=(r.top+(c&&l?l.offsetTop:0))/s,f=r.width/o,w=r.height/s;return{width:f,height:w,top:u,right:d+f,bottom:u+w,left:d,x:d,y:u}}function Do(e){var t=Ut(e),n=e.offsetWidth,r=e.offsetHeight;return Math.abs(t.width-n)<=1&&(n=t.width),Math.abs(t.height-r)<=1&&(r=t.height),{x:e.offsetLeft,y:e.offsetTop,width:n,height:r}}function ki(e,t){var n=t.getRootNode&&t.getRootNode();if(e.contains(t))return!0;if(n&&$o(n)){var r=t;do{if(r&&e.isSameNode(r))return!0;r=r.parentNode||r.host}while(r)}return!1}function tt(e){return $e(e).getComputedStyle(e)}function qw(e){return["table","td","th"].indexOf(We(e))>=0}function it(e){return((kt(e)?e.ownerDocument:e.document)||window.document).documentElement}function yr(e){return We(e)==="html"?e:e.assignedSlot||e.parentNode||($o(e)?e.host:null)||it(e)}function Va(e){return!Ve(e)||tt(e).position==="fixed"?null:e.offsetParent}function Hw(e){var t=/firefox/i.test(eo()),n=/Trident/i.test(eo());if(n&&Ve(e)){var r=tt(e);if(r.position==="fixed")return null}var o=yr(e);for($o(o)&&(o=o.host);Ve(o)&&["html","body"].indexOf(We(o))<0;){var s=tt(o);if(s.transform!=="none"||s.perspective!=="none"||s.contain==="paint"||["transform","perspective"].indexOf(s.willChange)!==-1||t&&s.willChange==="filter"||t&&s.filter&&s.filter!=="none")return o;o=o.parentNode}return null}function $n(e){for(var t=$e(e),n=Va(e);n&&qw(n)&&tt(n).position==="static";)n=Va(n);return n&&(We(n)==="html"||We(n)==="body"&&tt(n).position==="static")?t:n||Hw(e)||t}function Ao(e){return["top","bottom"].indexOf(e)>=0?"x":"y"}function hn(e,t,n){return ht(e,er(t,n))}function Xw(e,t,n){var r=hn(e,t,n);return r>n?n:r}function Si(){return{top:0,right:0,bottom:0,left:0}}function Ei(e){return Object.assign({},Si(),e)}function ji(e,t){return t.reduce(function(n,r){return n[r]=e,n},{})}var Yw=function(t,n){return t=typeof t=="function"?t(Object.assign({},n.rects,{placement:n.placement})):t,Ei(typeof t!="number"?t:ji(t,Mn))};function Ww(e){var t,n=e.state,r=e.name,o=e.options,s=n.elements.arrow,i=n.modifiersData.popperOffsets,l=Xe(n.placement),c=Ao(l),d=[Te,Le].indexOf(l)>=0,u=d?"height":"width";if(!(!s||!i)){var f=Yw(o.padding,n),w=Do(s),b=c==="y"?Ce:Te,x=c==="y"?ze:Le,m=n.rects.reference[u]+n.rects.reference[c]-i[c]-n.rects.popper[u],h=i[c]-n.rects.reference[c],S=$n(s),R=S?c==="y"?S.clientHeight||0:S.clientWidth||0:0,j=m/2-h/2,E=f[b],v=R-w[u]-f[x],P=R/2-w[u]/2+j,V=hn(E,P,v),U=c;n.modifiersData[r]=(t={},t[U]=V,t.centerOffset=V-P,t)}}function Kw(e){var t=e.state,n=e.options,r=n.element,o=r===void 0?"[data-popper-arrow]":r;o!=null&&(typeof o=="string"&&(o=t.elements.popper.querySelector(o),!o)||ki(t.elements.popper,o)&&(t.elements.arrow=o))}const Jw={name:"arrow",enabled:!0,phase:"main",fn:Ww,effect:Kw,requires:["popperOffsets"],requiresIfExists:["preventOverflow"]};function qt(e){return e.split("-")[1]}var Zw={top:"auto",right:"auto",bottom:"auto",left:"auto"};function Qw(e,t){var n=e.x,r=e.y,o=t.devicePixelRatio||1;return{x:Gt(n*o)/o||0,y:Gt(r*o)/o||0}}function za(e){var t,n=e.popper,r=e.popperRect,o=e.placement,s=e.variation,i=e.offsets,l=e.position,c=e.gpuAcceleration,d=e.adaptive,u=e.roundOffsets,f=e.isFixed,w=i.x,b=w===void 0?0:w,x=i.y,m=x===void 0?0:x,h=typeof u=="function"?u({x:b,y:m}):{x:b,y:m};b=h.x,m=h.y;var S=i.hasOwnProperty("x"),R=i.hasOwnProperty("y"),j=Te,E=Ce,v=window;if(d){var P=$n(n),V="clientHeight",U="clientWidth";if(P===$e(n)&&(P=it(n),tt(P).position!=="static"&&l==="absolute"&&(V="scrollHeight",U="scrollWidth")),P=P,o===Ce||(o===Te||o===Le)&&s===Nn){E=ze;var C=f&&P===v&&v.visualViewport?v.visualViewport.height:P[V];m-=C-r.height,m*=c?1:-1}if(o===Te||(o===Ce||o===ze)&&s===Nn){j=Le;var _=f&&P===v&&v.visualViewport?v.visualViewport.width:P[U];b-=_-r.width,b*=c?1:-1}}var k=Object.assign({position:l},d&&Zw),D=u===!0?Qw({x:b,y:m},$e(n)):{x:b,y:m};if(b=D.x,m=D.y,c){var $;return Object.assign({},k,($={},$[E]=R?"0":"",$[j]=S?"0":"",$.transform=(v.devicePixelRatio||1)<=1?"translate("+b+"px, "+m+"px)":"translate3d("+b+"px, "+m+"px, 0)",$))}return Object.assign({},k,(t={},t[E]=R?m+"px":"",t[j]=S?b+"px":"",t.transform="",t))}function ef(e){var t=e.state,n=e.options,r=n.gpuAcceleration,o=r===void 0?!0:r,s=n.adaptive,i=s===void 0?!0:s,l=n.roundOffsets,c=l===void 0?!0:l,d={placement:Xe(t.placement),variation:qt(t.placement),popper:t.elements.popper,popperRect:t.rects.popper,gpuAcceleration:o,isFixed:t.options.strategy==="fixed"};t.modifiersData.popperOffsets!=null&&(t.styles.popper=Object.assign({},t.styles.popper,za(Object.assign({},d,{offsets:t.modifiersData.popperOffsets,position:t.options.strategy,adaptive:i,roundOffsets:c})))),t.modifiersData.arrow!=null&&(t.styles.arrow=Object.assign({},t.styles.arrow,za(Object.assign({},d,{offsets:t.modifiersData.arrow,position:"absolute",adaptive:!1,roundOffsets:c})))),t.attributes.popper=Object.assign({},t.attributes.popper,{"data-popper-placement":t.placement})}const tf={name:"computeStyles",enabled:!0,phase:"beforeWrite",fn:ef,data:{}};var Fn={passive:!0};function nf(e){var t=e.state,n=e.instance,r=e.options,o=r.scroll,s=o===void 0?!0:o,i=r.resize,l=i===void 0?!0:i,c=$e(t.elements.popper),d=[].concat(t.scrollParents.reference,t.scrollParents.popper);return s&&d.forEach(function(u){u.addEventListener("scroll",n.update,Fn)}),l&&c.addEventListener("resize",n.update,Fn),function(){s&&d.forEach(function(u){u.removeEventListener("scroll",n.update,Fn)}),l&&c.removeEventListener("resize",n.update,Fn)}}const rf={name:"eventListeners",enabled:!0,phase:"write",fn:function(){},effect:nf,data:{}};var of={left:"right",right:"left",bottom:"top",top:"bottom"};function Xn(e){return e.replace(/left|right|bottom|top/g,function(t){return of[t]})}var af={start:"end",end:"start"};function La(e){return e.replace(/start|end/g,function(t){return af[t]})}function Bo(e){var t=$e(e),n=t.pageXOffset,r=t.pageYOffset;return{scrollLeft:n,scrollTop:r}}function Vo(e){return Ut(it(e)).left+Bo(e).scrollLeft}function sf(e,t){var n=$e(e),r=it(e),o=n.visualViewport,s=r.clientWidth,i=r.clientHeight,l=0,c=0;if(o){s=o.width,i=o.height;var d=Ni();(d||!d&&t==="fixed")&&(l=o.offsetLeft,c=o.offsetTop)}return{width:s,height:i,x:l+Vo(e),y:c}}function lf(e){var t,n=it(e),r=Bo(e),o=(t=e.ownerDocument)==null?void 0:t.body,s=ht(n.scrollWidth,n.clientWidth,o?o.scrollWidth:0,o?o.clientWidth:0),i=ht(n.scrollHeight,n.clientHeight,o?o.scrollHeight:0,o?o.clientHeight:0),l=-r.scrollLeft+Vo(e),c=-r.scrollTop;return tt(o||n).direction==="rtl"&&(l+=ht(n.clientWidth,o?o.clientWidth:0)-s),{width:s,height:i,x:l,y:c}}function zo(e){var t=tt(e),n=t.overflow,r=t.overflowX,o=t.overflowY;return/auto|scroll|overlay|hidden/.test(n+o+r)}function Ci(e){return["html","body","#document"].indexOf(We(e))>=0?e.ownerDocument.body:Ve(e)&&zo(e)?e:Ci(yr(e))}function gn(e,t){var n;t===void 0&&(t=[]);var r=Ci(e),o=r===((n=e.ownerDocument)==null?void 0:n.body),s=$e(r),i=o?[s].concat(s.visualViewport||[],zo(r)?r:[]):r,l=t.concat(i);return o?l:l.concat(gn(yr(i)))}function to(e){return Object.assign({},e,{left:e.x,top:e.y,right:e.x+e.width,bottom:e.y+e.height})}function cf(e,t){var n=Ut(e,!1,t==="fixed");return n.top=n.top+e.clientTop,n.left=n.left+e.clientLeft,n.bottom=n.top+e.clientHeight,n.right=n.left+e.clientWidth,n.width=e.clientWidth,n.height=e.clientHeight,n.x=n.left,n.y=n.top,n}function Fa(e,t,n){return t===xi?to(sf(e,n)):kt(t)?cf(t,n):to(lf(it(e)))}function df(e){var t=gn(yr(e)),n=["absolute","fixed"].indexOf(tt(e).position)>=0,r=n&&Ve(e)?$n(e):e;return kt(r)?t.filter(function(o){return kt(o)&&ki(o,r)&&We(o)!=="body"}):[]}function uf(e,t,n,r){var o=t==="clippingParents"?df(e):[].concat(t),s=[].concat(o,[n]),i=s[0],l=s.reduce(function(c,d){var u=Fa(e,d,r);return c.top=ht(u.top,c.top),c.right=er(u.right,c.right),c.bottom=er(u.bottom,c.bottom),c.left=ht(u.left,c.left),c},Fa(e,i,r));return l.width=l.right-l.left,l.height=l.bottom-l.top,l.x=l.left,l.y=l.top,l}function Ti(e){var t=e.reference,n=e.element,r=e.placement,o=r?Xe(r):null,s=r?qt(r):null,i=t.x+t.width/2-n.width/2,l=t.y+t.height/2-n.height/2,c;switch(o){case Ce:c={x:i,y:t.y-n.height};break;case ze:c={x:i,y:t.y+t.height};break;case Le:c={x:t.x+t.width,y:l};break;case Te:c={x:t.x-n.width,y:l};break;default:c={x:t.x,y:t.y}}var d=o?Ao(o):null;if(d!=null){var u=d==="y"?"height":"width";switch(s){case Ft:c[d]=c[d]-(t[u]/2-n[u]/2);break;case Nn:c[d]=c[d]+(t[u]/2-n[u]/2);break}}return c}function kn(e,t){t===void 0&&(t={});var n=t,r=n.placement,o=r===void 0?e.placement:r,s=n.strategy,i=s===void 0?e.strategy:s,l=n.boundary,c=l===void 0?Ow:l,d=n.rootBoundary,u=d===void 0?xi:d,f=n.elementContext,w=f===void 0?an:f,b=n.altBoundary,x=b===void 0?!1:b,m=n.padding,h=m===void 0?0:m,S=Ei(typeof h!="number"?h:ji(h,Mn)),R=w===an?_w:an,j=e.rects.popper,E=e.elements[x?R:w],v=uf(kt(E)?E:E.contextElement||it(e.elements.popper),c,u,i),P=Ut(e.elements.reference),V=Ti({reference:P,element:j,strategy:"absolute",placement:o}),U=to(Object.assign({},j,V)),C=w===an?U:P,_={top:v.top-C.top+S.top,bottom:C.bottom-v.bottom+S.bottom,left:v.left-C.left+S.left,right:C.right-v.right+S.right},k=e.modifiersData.offset;if(w===an&&k){var D=k[o];Object.keys(_).forEach(function($){var J=[Le,ze].indexOf($)>=0?1:-1,Y=[Ce,ze].indexOf($)>=0?"y":"x";_[$]+=D[Y]*J})}return _}function pf(e,t){t===void 0&&(t={});var n=t,r=n.placement,o=n.boundary,s=n.rootBoundary,i=n.padding,l=n.flipVariations,c=n.allowedAutoPlacements,d=c===void 0?yi:c,u=qt(r),f=u?l?Ba:Ba.filter(function(x){return qt(x)===u}):Mn,w=f.filter(function(x){return d.indexOf(x)>=0});w.length===0&&(w=f);var b=w.reduce(function(x,m){return x[m]=kn(e,{placement:m,boundary:o,rootBoundary:s,padding:i})[Xe(m)],x},{});return Object.keys(b).sort(function(x,m){return b[x]-b[m]})}function wf(e){if(Xe(e)===Mo)return[];var t=Xn(e);return[La(e),t,La(t)]}function ff(e){var t=e.state,n=e.options,r=e.name;if(!t.modifiersData[r]._skip){for(var o=n.mainAxis,s=o===void 0?!0:o,i=n.altAxis,l=i===void 0?!0:i,c=n.fallbackPlacements,d=n.padding,u=n.boundary,f=n.rootBoundary,w=n.altBoundary,b=n.flipVariations,x=b===void 0?!0:b,m=n.allowedAutoPlacements,h=t.options.placement,S=Xe(h),R=S===h,j=c||(R||!x?[Xn(h)]:wf(h)),E=[h].concat(j).reduce(function(B,X){return B.concat(Xe(X)===Mo?pf(t,{placement:X,boundary:u,rootBoundary:f,padding:d,flipVariations:x,allowedAutoPlacements:m}):X)},[]),v=t.rects.reference,P=t.rects.popper,V=new Map,U=!0,C=E[0],_=0;_=0,Y=J?"width":"height",F=kn(t,{placement:k,boundary:u,rootBoundary:f,altBoundary:w,padding:d}),te=J?$?Le:Te:$?ze:Ce;v[Y]>P[Y]&&(te=Xn(te));var se=Xn(te),oe=[];if(s&&oe.push(F[D]<=0),l&&oe.push(F[te]<=0,F[se]<=0),oe.every(function(B){return B})){C=k,U=!1;break}V.set(k,oe)}if(U)for(var y=x?3:1,T=function(X){var q=E.find(function(H){var G=V.get(H);if(G)return G.slice(0,X).every(function(K){return K})});if(q)return C=q,"break"},z=y;z>0;z--){var L=T(z);if(L==="break")break}t.placement!==C&&(t.modifiersData[r]._skip=!0,t.placement=C,t.reset=!0)}}const mf={name:"flip",enabled:!0,phase:"main",fn:ff,requiresIfExists:["offset"],data:{_skip:!1}};function Ga(e,t,n){return n===void 0&&(n={x:0,y:0}),{top:e.top-t.height-n.y,right:e.right-t.width+n.x,bottom:e.bottom-t.height+n.y,left:e.left-t.width-n.x}}function Ua(e){return[Ce,Le,ze,Te].some(function(t){return e[t]>=0})}function hf(e){var t=e.state,n=e.name,r=t.rects.reference,o=t.rects.popper,s=t.modifiersData.preventOverflow,i=kn(t,{elementContext:"reference"}),l=kn(t,{altBoundary:!0}),c=Ga(i,r),d=Ga(l,o,s),u=Ua(c),f=Ua(d);t.modifiersData[n]={referenceClippingOffsets:c,popperEscapeOffsets:d,isReferenceHidden:u,hasPopperEscaped:f},t.attributes.popper=Object.assign({},t.attributes.popper,{"data-popper-reference-hidden":u,"data-popper-escaped":f})}const gf={name:"hide",enabled:!0,phase:"main",requiresIfExists:["preventOverflow"],fn:hf};function bf(e,t,n){var r=Xe(e),o=[Te,Ce].indexOf(r)>=0?-1:1,s=typeof n=="function"?n(Object.assign({},t,{placement:e})):n,i=s[0],l=s[1];return i=i||0,l=(l||0)*o,[Te,Le].indexOf(r)>=0?{x:l,y:i}:{x:i,y:l}}function vf(e){var t=e.state,n=e.options,r=e.name,o=n.offset,s=o===void 0?[0,0]:o,i=yi.reduce(function(u,f){return u[f]=bf(f,t.rects,s),u},{}),l=i[t.placement],c=l.x,d=l.y;t.modifiersData.popperOffsets!=null&&(t.modifiersData.popperOffsets.x+=c,t.modifiersData.popperOffsets.y+=d),t.modifiersData[r]=i}const xf={name:"offset",enabled:!0,phase:"main",requires:["popperOffsets"],fn:vf};function yf(e){var t=e.state,n=e.name;t.modifiersData[n]=Ti({reference:t.rects.reference,element:t.rects.popper,strategy:"absolute",placement:t.placement})}const Nf={name:"popperOffsets",enabled:!0,phase:"read",fn:yf,data:{}};function kf(e){return e==="x"?"y":"x"}function Sf(e){var t=e.state,n=e.options,r=e.name,o=n.mainAxis,s=o===void 0?!0:o,i=n.altAxis,l=i===void 0?!1:i,c=n.boundary,d=n.rootBoundary,u=n.altBoundary,f=n.padding,w=n.tether,b=w===void 0?!0:w,x=n.tetherOffset,m=x===void 0?0:x,h=kn(t,{boundary:c,rootBoundary:d,padding:f,altBoundary:u}),S=Xe(t.placement),R=qt(t.placement),j=!R,E=Ao(S),v=kf(E),P=t.modifiersData.popperOffsets,V=t.rects.reference,U=t.rects.popper,C=typeof m=="function"?m(Object.assign({},t.rects,{placement:t.placement})):m,_=typeof C=="number"?{mainAxis:C,altAxis:C}:Object.assign({mainAxis:0,altAxis:0},C),k=t.modifiersData.offset?t.modifiersData.offset[t.placement]:null,D={x:0,y:0};if(P){if(s){var $,J=E==="y"?Ce:Te,Y=E==="y"?ze:Le,F=E==="y"?"height":"width",te=P[E],se=te+h[J],oe=te-h[Y],y=b?-U[F]/2:0,T=R===Ft?V[F]:U[F],z=R===Ft?-U[F]:-V[F],L=t.elements.arrow,B=b&&L?Do(L):{width:0,height:0},X=t.modifiersData["arrow#persistent"]?t.modifiersData["arrow#persistent"].padding:Si(),q=X[J],H=X[Y],G=hn(0,V[F],B[F]),K=j?V[F]/2-y-G-q-_.mainAxis:T-G-q-_.mainAxis,Z=j?-V[F]/2+y+G+H+_.mainAxis:z+G+H+_.mainAxis,ue=t.elements.arrow&&$n(t.elements.arrow),I=ue?E==="y"?ue.clientTop||0:ue.clientLeft||0:0,ye=($=k==null?void 0:k[E])!=null?$:0,A=te+K-ye-I,xe=te+Z-ye,Ge=hn(b?er(se,A):se,te,b?ht(oe,xe):oe);P[E]=Ge,D[E]=Ge-te}if(l){var lt,Ee=E==="x"?Ce:Te,Dn=E==="x"?ze:Le,Ue=P[v],Et=v==="y"?"height":"width",ct=Ue+h[Ee],jt=Ue-h[Dn],Ct=[Ce,Te].indexOf(S)!==-1,Tt=(lt=k==null?void 0:k[v])!=null?lt:0,dt=Ct?ct:Ue-V[Et]-U[Et]-Tt+_.altAxis,Jt=Ct?Ue+V[Et]+U[Et]-Tt-_.altAxis:jt,An=b&&Ct?Xw(dt,Ue,Jt):hn(b?dt:ct,Ue,b?Jt:jt);P[v]=An,D[v]=An-Ue}t.modifiersData[r]=D}}const Ef={name:"preventOverflow",enabled:!0,phase:"main",fn:Sf,requiresIfExists:["offset"]};function jf(e){return{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}}function Cf(e){return e===$e(e)||!Ve(e)?Bo(e):jf(e)}function Tf(e){var t=e.getBoundingClientRect(),n=Gt(t.width)/e.offsetWidth||1,r=Gt(t.height)/e.offsetHeight||1;return n!==1||r!==1}function Rf(e,t,n){n===void 0&&(n=!1);var r=Ve(t),o=Ve(t)&&Tf(t),s=it(t),i=Ut(e,o,n),l={scrollLeft:0,scrollTop:0},c={x:0,y:0};return(r||!r&&!n)&&((We(t)!=="body"||zo(s))&&(l=Cf(t)),Ve(t)?(c=Ut(t,!0),c.x+=t.clientLeft,c.y+=t.clientTop):s&&(c.x=Vo(s))),{x:i.left+l.scrollLeft-c.x,y:i.top+l.scrollTop-c.y,width:i.width,height:i.height}}function Of(e){var t=new Map,n=new Set,r=[];e.forEach(function(s){t.set(s.name,s)});function o(s){n.add(s.name);var i=[].concat(s.requires||[],s.requiresIfExists||[]);i.forEach(function(l){if(!n.has(l)){var c=t.get(l);c&&o(c)}}),r.push(s)}return e.forEach(function(s){n.has(s.name)||o(s)}),r}function _f(e){var t=Of(e);return Lw.reduce(function(n,r){return n.concat(t.filter(function(o){return o.phase===r}))},[])}function Pf(e){var t;return function(){return t||(t=new Promise(function(n){Promise.resolve().then(function(){t=void 0,n(e())})})),t}}function If(e){var t=e.reduce(function(n,r){var o=n[r.name];return n[r.name]=o?Object.assign({},o,r,{options:Object.assign({},o.options,r.options),data:Object.assign({},o.data,r.data)}):r,n},{});return Object.keys(t).map(function(n){return t[n]})}var qa={placement:"bottom",modifiers:[],strategy:"absolute"};function Ha(){for(var e=arguments.length,t=new Array(e),n=0;nko({root:["root"]},xw(Af)),Gf={},Uf=M.forwardRef(function(t,n){var r;const{anchorEl:o,children:s,direction:i,disablePortal:l,modifiers:c,open:d,placement:u,popperOptions:f,popperRef:w,slotProps:b={},slots:x={},TransitionProps:m}=t,h=Ne(t,Bf),S=M.useRef(null),R=yt(S,n),j=M.useRef(null),E=yt(j,w),v=M.useRef(E);Lt(()=>{v.current=E},[E]),M.useImperativeHandle(w,()=>j.current,[]);const P=zf(u,i),[V,U]=M.useState(P),[C,_]=M.useState(tr(o));M.useEffect(()=>{j.current&&j.current.forceUpdate()}),M.useEffect(()=>{o&&_(tr(o))},[o]),Lt(()=>{if(!C||!d)return;const Y=se=>{U(se.placement)};if(process.env.NODE_ENV!=="production"&&C&&Nr(C)&&C.nodeType===1){const se=C.getBoundingClientRect();process.env.NODE_ENV!=="test"&&se.top===0&&se.left===0&&se.right===0&&se.bottom===0&&console.warn(["MUI: The `anchorEl` prop provided to the component is invalid.","The anchor element should be part of the document layout.","Make sure the element is present in the document or that it's not display none."].join(` -`))}let F=[{name:"preventOverflow",options:{altBoundary:l}},{name:"flip",options:{altBoundary:l}},{name:"onUpdate",enabled:!0,phase:"afterWrite",fn:({state:se})=>{Y(se)}}];c!=null&&(F=F.concat(c)),f&&f.modifiers!=null&&(F=F.concat(f.modifiers));const te=Df(C,S.current,O({placement:P},f,{modifiers:F}));return v.current(te),()=>{te.destroy(),v.current(null)}},[C,l,c,d,f,P]);const k={placement:V};m!==null&&(k.TransitionProps=m);const D=Ff(),$=(r=x.root)!=null?r:"div",J=Ew({elementType:$,externalSlotProps:b.root,externalForwardedProps:h,additionalProps:{role:"tooltip",ref:R},ownerState:t,className:D.root});return a.jsx($,O({},J,{children:typeof s=="function"?s(k):s}))}),Oi=M.forwardRef(function(t,n){const{anchorEl:r,children:o,container:s,direction:i="ltr",disablePortal:l=!1,keepMounted:c=!1,modifiers:d,open:u,placement:f="bottom",popperOptions:w=Gf,popperRef:b,style:x,transition:m=!1,slotProps:h={},slots:S={}}=t,R=Ne(t,Vf),[j,E]=M.useState(!0),v=()=>{E(!1)},P=()=>{E(!0)};if(!c&&!u&&(!m||j))return null;let V;if(s)V=s;else if(r){const _=tr(r);V=_&&Nr(_)?Kn(_).body:Kn(null).body}const U=!u&&c&&(!m||j)?"none":void 0,C=m?{in:u,onEnter:v,onExited:P}:void 0;return a.jsx(Qn,{disablePortal:l,container:V,children:a.jsx(Uf,O({anchorEl:r,direction:i,disablePortal:l,modifiers:d,ref:n,open:m?!j:u,placement:f,popperOptions:w,popperRef:b,slotProps:h,slots:S},R,{style:O({position:"fixed",top:0,left:0,display:U},x),TransitionProps:C,children:o}))})});process.env.NODE_ENV!=="production"&&(Oi.propTypes={anchorEl:yo(p.oneOfType([xn,p.object,p.func]),e=>{if(e.open){const t=tr(e.anchorEl);if(t&&Nr(t)&&t.nodeType===1){const n=t.getBoundingClientRect();if(process.env.NODE_ENV!=="test"&&n.top===0&&n.left===0&&n.right===0&&n.bottom===0)return new Error(["MUI: The `anchorEl` prop provided to the component is invalid.","The anchor element should be part of the document layout.","Make sure the element is present in the document or that it's not display none."].join(` -`))}else if(!t||typeof t.getBoundingClientRect!="function"||Lf(t)&&t.contextElement!=null&&t.contextElement.nodeType!==1)return new Error(["MUI: The `anchorEl` prop provided to the component is invalid.","It should be an HTML element instance or a virtualElement ","(https://popper.js.org/docs/v2/virtual-elements/)."].join(` -`))}return null}),children:p.oneOfType([p.node,p.func]),container:p.oneOfType([xn,p.func]),direction:p.oneOf(["ltr","rtl"]),disablePortal:p.bool,keepMounted:p.bool,modifiers:p.arrayOf(p.shape({data:p.object,effect:p.func,enabled:p.bool,fn:p.func,name:p.any,options:p.object,phase:p.oneOf(["afterMain","afterRead","afterWrite","beforeMain","beforeRead","beforeWrite","main","read","write"]),requires:p.arrayOf(p.string),requiresIfExists:p.arrayOf(p.string)})),open:p.bool.isRequired,placement:p.oneOf(["auto-end","auto-start","auto","bottom-end","bottom-start","bottom","left-end","left-start","left","right-end","right-start","right","top-end","top-start","top"]),popperOptions:p.shape({modifiers:p.array,onFirstUpdate:p.func,placement:p.oneOf(["auto-end","auto-start","auto","bottom-end","bottom-start","bottom","left-end","left-start","left","right-end","right-start","right","top-end","top-start","top"]),strategy:p.oneOf(["absolute","fixed"])}),popperRef:ni,slotProps:p.shape({root:p.oneOfType([p.func,p.object])}),slots:p.shape({root:p.elementType}),transition:p.bool});function _i(){const e=fi(Oo);return process.env.NODE_ENV!=="production"&&M.useDebugValue(e),e[_o]||e}function no(e,t){return no=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,o){return r.__proto__=o,r},no(e,t)}function qf(e,t){e.prototype=Object.create(t.prototype),e.prototype.constructor=e,no(e,t)}const Xa={disabled:!1};var Hf=process.env.NODE_ENV!=="production"?p.oneOfType([p.number,p.shape({enter:p.number,exit:p.number,appear:p.number}).isRequired]):null;process.env.NODE_ENV!=="production"&&p.oneOfType([p.string,p.shape({enter:p.string,exit:p.string,active:p.string}),p.shape({enter:p.string,enterDone:p.string,enterActive:p.string,exit:p.string,exitDone:p.string,exitActive:p.string})]);const Pi=g.createContext(null);var Xf=function(t){return t.scrollTop},pn="unmounted",wt="exited",ft="entering",$t="entered",ro="exiting",nt=function(e){qf(t,e);function t(r,o){var s;s=e.call(this,r,o)||this;var i=o,l=i&&!i.isMounting?r.enter:r.appear,c;return s.appearStatus=null,r.in?l?(c=wt,s.appearStatus=ft):c=$t:r.unmountOnExit||r.mountOnEnter?c=pn:c=wt,s.state={status:c},s.nextCallback=null,s}t.getDerivedStateFromProps=function(o,s){var i=o.in;return i&&s.status===pn?{status:wt}:null};var n=t.prototype;return n.componentDidMount=function(){this.updateStatus(!0,this.appearStatus)},n.componentDidUpdate=function(o){var s=null;if(o!==this.props){var i=this.state.status;this.props.in?i!==ft&&i!==$t&&(s=ft):(i===ft||i===$t)&&(s=ro)}this.updateStatus(!1,s)},n.componentWillUnmount=function(){this.cancelNextCallback()},n.getTimeouts=function(){var o=this.props.timeout,s,i,l;return s=i=l=o,o!=null&&typeof o!="number"&&(s=o.exit,i=o.enter,l=o.appear!==void 0?o.appear:i),{exit:s,enter:i,appear:l}},n.updateStatus=function(o,s){if(o===void 0&&(o=!1),s!==null)if(this.cancelNextCallback(),s===ft){if(this.props.unmountOnExit||this.props.mountOnEnter){var i=this.props.nodeRef?this.props.nodeRef.current:ln.findDOMNode(this);i&&Xf(i)}this.performEnter(o)}else this.performExit();else this.props.unmountOnExit&&this.state.status===wt&&this.setState({status:pn})},n.performEnter=function(o){var s=this,i=this.props.enter,l=this.context?this.context.isMounting:o,c=this.props.nodeRef?[l]:[ln.findDOMNode(this),l],d=c[0],u=c[1],f=this.getTimeouts(),w=l?f.appear:f.enter;if(!o&&!i||Xa.disabled){this.safeSetState({status:$t},function(){s.props.onEntered(d)});return}this.props.onEnter(d,u),this.safeSetState({status:ft},function(){s.props.onEntering(d,u),s.onTransitionEnd(w,function(){s.safeSetState({status:$t},function(){s.props.onEntered(d,u)})})})},n.performExit=function(){var o=this,s=this.props.exit,i=this.getTimeouts(),l=this.props.nodeRef?void 0:ln.findDOMNode(this);if(!s||Xa.disabled){this.safeSetState({status:wt},function(){o.props.onExited(l)});return}this.props.onExit(l),this.safeSetState({status:ro},function(){o.props.onExiting(l),o.onTransitionEnd(i.exit,function(){o.safeSetState({status:wt},function(){o.props.onExited(l)})})})},n.cancelNextCallback=function(){this.nextCallback!==null&&(this.nextCallback.cancel(),this.nextCallback=null)},n.safeSetState=function(o,s){s=this.setNextCallback(s),this.setState(o,s)},n.setNextCallback=function(o){var s=this,i=!0;return this.nextCallback=function(l){i&&(i=!1,s.nextCallback=null,o(l))},this.nextCallback.cancel=function(){i=!1},this.nextCallback},n.onTransitionEnd=function(o,s){this.setNextCallback(s);var i=this.props.nodeRef?this.props.nodeRef.current:ln.findDOMNode(this),l=o==null&&!this.props.addEndListener;if(!i||l){setTimeout(this.nextCallback,0);return}if(this.props.addEndListener){var c=this.props.nodeRef?[this.nextCallback]:[i,this.nextCallback],d=c[0],u=c[1];this.props.addEndListener(d,u)}o!=null&&setTimeout(this.nextCallback,o)},n.render=function(){var o=this.state.status;if(o===pn)return null;var s=this.props,i=s.children;s.in,s.mountOnEnter,s.unmountOnExit,s.appear,s.enter,s.exit,s.timeout,s.addEndListener,s.onEnter,s.onEntering,s.onEntered,s.onExit,s.onExiting,s.onExited,s.nodeRef;var l=Ne(s,["children","in","mountOnEnter","unmountOnExit","appear","enter","exit","timeout","addEndListener","onEnter","onEntering","onEntered","onExit","onExiting","onExited","nodeRef"]);return g.createElement(Pi.Provider,{value:null},typeof i=="function"?i(o,l):g.cloneElement(g.Children.only(i),l))},t}(g.Component);nt.contextType=Pi;nt.propTypes=process.env.NODE_ENV!=="production"?{nodeRef:p.shape({current:typeof Element>"u"?p.any:function(e,t,n,r,o,s){var i=e[t];return p.instanceOf(i&&"ownerDocument"in i?i.ownerDocument.defaultView.Element:Element)(e,t,n,r,o,s)}}),children:p.oneOfType([p.func.isRequired,p.element.isRequired]).isRequired,in:p.bool,mountOnEnter:p.bool,unmountOnExit:p.bool,appear:p.bool,enter:p.bool,exit:p.bool,timeout:function(t){var n=Hf;t.addEndListener||(n=n.isRequired);for(var r=arguments.length,o=new Array(r>1?r-1:0),s=1;se.scrollTop;function Ya(e,t){var n,r;const{timeout:o,easing:s,style:i={}}=e;return{duration:(n=i.transitionDuration)!=null?n:typeof o=="number"?o:o[t.mode]||0,easing:(r=i.transitionTimingFunction)!=null?r:typeof s=="object"?s[t.mode]:s,delay:i.transitionDelay}}const Kf=["addEndListener","appear","children","easing","in","onEnter","onEntered","onEntering","onExit","onExited","onExiting","style","timeout","TransitionComponent"];function oo(e){return`scale(${e}, ${e**2})`}const Jf={entering:{opacity:1,transform:oo(1)},entered:{opacity:1,transform:"none"}},Lr=typeof navigator<"u"&&/^((?!chrome|android).)*(safari|mobile)/i.test(navigator.userAgent)&&/(os |version\/)15(.|_)4/i.test(navigator.userAgent),Lo=M.forwardRef(function(t,n){const{addEndListener:r,appear:o=!0,children:s,easing:i,in:l,onEnter:c,onEntered:d,onEntering:u,onExit:f,onExited:w,onExiting:b,style:x,timeout:m="auto",TransitionComponent:h=Yf}=t,S=Ne(t,Kf),R=dn(),j=M.useRef(),E=_i(),v=M.useRef(null),P=yt(v,s.ref,n),V=Y=>F=>{if(Y){const te=v.current;F===void 0?Y(te):Y(te,F)}},U=V(u),C=V((Y,F)=>{Wf(Y);const{duration:te,delay:se,easing:oe}=Ya({style:x,timeout:m,easing:i},{mode:"enter"});let y;m==="auto"?(y=E.transitions.getAutoHeightDuration(Y.clientHeight),j.current=y):y=te,Y.style.transition=[E.transitions.create("opacity",{duration:y,delay:se}),E.transitions.create("transform",{duration:Lr?y:y*.666,delay:se,easing:oe})].join(","),c&&c(Y,F)}),_=V(d),k=V(b),D=V(Y=>{const{duration:F,delay:te,easing:se}=Ya({style:x,timeout:m,easing:i},{mode:"exit"});let oe;m==="auto"?(oe=E.transitions.getAutoHeightDuration(Y.clientHeight),j.current=oe):oe=F,Y.style.transition=[E.transitions.create("opacity",{duration:oe,delay:te}),E.transitions.create("transform",{duration:Lr?oe:oe*.666,delay:Lr?te:te||oe*.333,easing:se})].join(","),Y.style.opacity=0,Y.style.transform=oo(.75),f&&f(Y)}),$=V(w),J=Y=>{m==="auto"&&R.start(j.current||0,Y),r&&r(v.current,Y)};return a.jsx(h,O({appear:o,in:l,nodeRef:v,onEnter:C,onEntered:_,onEntering:U,onExit:D,onExited:$,onExiting:k,addEndListener:J,timeout:m==="auto"?null:m},S,{children:(Y,F)=>M.cloneElement(s,O({style:O({opacity:0,transform:oo(.75),visibility:Y==="exited"&&!l?"hidden":void 0},Jf[Y],x,s.props.style),ref:P},F))}))});process.env.NODE_ENV!=="production"&&(Lo.propTypes={addEndListener:p.func,appear:p.bool,children:ei.isRequired,easing:p.oneOfType([p.shape({enter:p.string,exit:p.string}),p.string]),in:p.bool,onEnter:p.func,onEntered:p.func,onEntering:p.func,onExit:p.func,onExited:p.func,onExiting:p.func,style:p.object,timeout:p.oneOfType([p.oneOf(["auto"]),p.number,p.shape({appear:p.number,enter:p.number,exit:p.number})])});Lo.muiSupportAuto=!0;const Wa=Lo,Zf=["anchorEl","component","components","componentsProps","container","disablePortal","keepMounted","modifiers","open","placement","popperOptions","popperRef","transition","slots","slotProps"],Qf=In(Oi,{name:"MuiPopper",slot:"Root",overridesResolver:(e,t)=>t.root})({}),Ii=M.forwardRef(function(t,n){var r;const o=wi(),s=Po({props:t,name:"MuiPopper"}),{anchorEl:i,component:l,components:c,componentsProps:d,container:u,disablePortal:f,keepMounted:w,modifiers:b,open:x,placement:m,popperOptions:h,popperRef:S,transition:R,slots:j,slotProps:E}=s,v=Ne(s,Zf),P=(r=j==null?void 0:j.root)!=null?r:c==null?void 0:c.Root,V=O({anchorEl:i,container:u,disablePortal:f,keepMounted:w,modifiers:b,open:x,placement:m,popperOptions:h,popperRef:S,transition:R},v);return a.jsx(Qf,O({as:l,direction:o==null?void 0:o.direction,slots:{root:P},slotProps:E??d},V,{ref:n}))});process.env.NODE_ENV!=="production"&&(Ii.propTypes={anchorEl:p.oneOfType([xn,p.object,p.func]),children:p.oneOfType([p.node,p.func]),component:p.elementType,components:p.shape({Root:p.elementType}),componentsProps:p.shape({root:p.oneOfType([p.func,p.object])}),container:p.oneOfType([xn,p.func]),disablePortal:p.bool,keepMounted:p.bool,modifiers:p.arrayOf(p.shape({data:p.object,effect:p.func,enabled:p.bool,fn:p.func,name:p.any,options:p.object,phase:p.oneOf(["afterMain","afterRead","afterWrite","beforeMain","beforeRead","beforeWrite","main","read","write"]),requires:p.arrayOf(p.string),requiresIfExists:p.arrayOf(p.string)})),open:p.bool.isRequired,placement:p.oneOf(["auto-end","auto-start","auto","bottom-end","bottom-start","bottom","left-end","left-start","left","right-end","right-start","right","top-end","top-start","top"]),popperOptions:p.shape({modifiers:p.array,onFirstUpdate:p.func,placement:p.oneOf(["auto-end","auto-start","auto","bottom-end","bottom-start","bottom","left-end","left-start","left","right-end","right-start","right","top-end","top-start","top"]),strategy:p.oneOf(["absolute","fixed"])}),popperRef:ni,slotProps:p.shape({root:p.oneOfType([p.func,p.object])}),slots:p.shape({root:p.elementType}),sx:p.oneOfType([p.arrayOf(p.oneOfType([p.func,p.object,p.bool])),p.func,p.object]),transition:p.bool});const Mi=Ii;function em(e){return ur("MuiTooltip",e)}const tm=ci("MuiTooltip",["popper","popperInteractive","popperArrow","popperClose","tooltip","tooltipArrow","touch","tooltipPlacementLeft","tooltipPlacementRight","tooltipPlacementTop","tooltipPlacementBottom","arrow"]),at=tm,nm=["arrow","children","classes","components","componentsProps","describeChild","disableFocusListener","disableHoverListener","disableInteractive","disableTouchListener","enterDelay","enterNextDelay","enterTouchDelay","followCursor","id","leaveDelay","leaveTouchDelay","onClose","onOpen","open","placement","PopperComponent","PopperProps","slotProps","slots","title","TransitionComponent","TransitionProps"];function rm(e){return Math.round(e*1e5)/1e5}const om=e=>{const{classes:t,disableInteractive:n,arrow:r,touch:o,placement:s}=e,i={popper:["popper",!n&&"popperInteractive",r&&"popperArrow"],tooltip:["tooltip",r&&"tooltipArrow",o&&"touch",`tooltipPlacement${Ye(s.split("-")[0])}`],arrow:["arrow"]};return ko(i,em,t)},am=In(Mi,{name:"MuiTooltip",slot:"Popper",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.popper,!n.disableInteractive&&t.popperInteractive,n.arrow&&t.popperArrow,!n.open&&t.popperClose]}})(({theme:e,ownerState:t,open:n})=>O({zIndex:(e.vars||e).zIndex.tooltip,pointerEvents:"none"},!t.disableInteractive&&{pointerEvents:"auto"},!n&&{pointerEvents:"none"},t.arrow&&{[`&[data-popper-placement*="bottom"] .${at.arrow}`]:{top:0,marginTop:"-0.71em","&::before":{transformOrigin:"0 100%"}},[`&[data-popper-placement*="top"] .${at.arrow}`]:{bottom:0,marginBottom:"-0.71em","&::before":{transformOrigin:"100% 0"}},[`&[data-popper-placement*="right"] .${at.arrow}`]:O({},t.isRtl?{right:0,marginRight:"-0.71em"}:{left:0,marginLeft:"-0.71em"},{height:"1em",width:"0.71em","&::before":{transformOrigin:"100% 100%"}}),[`&[data-popper-placement*="left"] .${at.arrow}`]:O({},t.isRtl?{left:0,marginLeft:"-0.71em"}:{right:0,marginRight:"-0.71em"},{height:"1em",width:"0.71em","&::before":{transformOrigin:"0 0"}})})),sm=In("div",{name:"MuiTooltip",slot:"Tooltip",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.tooltip,n.touch&&t.touch,n.arrow&&t.tooltipArrow,t[`tooltipPlacement${Ye(n.placement.split("-")[0])}`]]}})(({theme:e,ownerState:t})=>O({backgroundColor:e.vars?e.vars.palette.Tooltip.bg:mi(e.palette.grey[700],.92),borderRadius:(e.vars||e).shape.borderRadius,color:(e.vars||e).palette.common.white,fontFamily:e.typography.fontFamily,padding:"4px 8px",fontSize:e.typography.pxToRem(11),maxWidth:300,margin:2,wordWrap:"break-word",fontWeight:e.typography.fontWeightMedium},t.arrow&&{position:"relative",margin:0},t.touch&&{padding:"8px 16px",fontSize:e.typography.pxToRem(14),lineHeight:`${rm(16/14)}em`,fontWeight:e.typography.fontWeightRegular},{[`.${at.popper}[data-popper-placement*="left"] &`]:O({transformOrigin:"right center"},t.isRtl?O({marginLeft:"14px"},t.touch&&{marginLeft:"24px"}):O({marginRight:"14px"},t.touch&&{marginRight:"24px"})),[`.${at.popper}[data-popper-placement*="right"] &`]:O({transformOrigin:"left center"},t.isRtl?O({marginRight:"14px"},t.touch&&{marginRight:"24px"}):O({marginLeft:"14px"},t.touch&&{marginLeft:"24px"})),[`.${at.popper}[data-popper-placement*="top"] &`]:O({transformOrigin:"center bottom",marginBottom:"14px"},t.touch&&{marginBottom:"24px"}),[`.${at.popper}[data-popper-placement*="bottom"] &`]:O({transformOrigin:"center top",marginTop:"14px"},t.touch&&{marginTop:"24px"})})),im=In("span",{name:"MuiTooltip",slot:"Arrow",overridesResolver:(e,t)=>t.arrow})(({theme:e})=>({overflow:"hidden",position:"absolute",width:"1em",height:"0.71em",boxSizing:"border-box",color:e.vars?e.vars.palette.Tooltip.bg:mi(e.palette.grey[700],.9),"&::before":{content:'""',margin:"auto",display:"block",width:"100%",height:"100%",backgroundColor:"currentColor",transform:"rotate(45deg)"}}));let Gn=!1;const Ka=new On;let sn={x:0,y:0};function Un(e,t){return n=>{t&&t(n),e(n)}}const $i=M.forwardRef(function(t,n){var r,o,s,i,l,c,d,u,f,w,b,x,m,h,S,R,j,E,v;const P=Po({props:t,name:"MuiTooltip"}),{arrow:V=!1,children:U,components:C={},componentsProps:_={},describeChild:k=!1,disableFocusListener:D=!1,disableHoverListener:$=!1,disableInteractive:J=!1,disableTouchListener:Y=!1,enterDelay:F=100,enterNextDelay:te=0,enterTouchDelay:se=700,followCursor:oe=!1,id:y,leaveDelay:T=0,leaveTouchDelay:z=1500,onClose:L,onOpen:B,open:X,placement:q="bottom",PopperComponent:H,PopperProps:G={},slotProps:K={},slots:Z={},title:ue,TransitionComponent:I=Wa,TransitionProps:ye}=P,A=Ne(P,nm),xe=M.isValidElement(U)?U:a.jsx("span",{children:U}),Ge=_i(),lt=Ge.direction==="rtl",[Ee,Dn]=M.useState(),[Ue,Et]=M.useState(null),ct=M.useRef(!1),jt=J||oe,Ct=dn(),Tt=dn(),dt=dn(),Jt=dn(),[An,Go]=oi({controlled:X,default:!1,name:"Tooltip",state:"open"});let Ke=An;if(process.env.NODE_ENV!=="production"){const{current:ee}=M.useRef(X!==void 0);M.useEffect(()=>{Ee&&Ee.disabled&&!ee&&ue!==""&&Ee.tagName.toLowerCase()==="button"&&console.error(["MUI: You are providing a disabled `button` child to the Tooltip component.","A disabled element does not fire events.","Tooltip needs to listen to the child element's events to display the title.","","Add a simple wrapper element, such as a `span`."].join(` -`))},[ue,Ee,ee])}const kr=ri(y),Zt=M.useRef(),Bn=Zr(()=>{Zt.current!==void 0&&(document.body.style.WebkitUserSelect=Zt.current,Zt.current=void 0),Jt.clear()});M.useEffect(()=>Bn,[Bn]);const Uo=ee=>{Ka.clear(),Gn=!0,Go(!0),B&&!Ke&&B(ee)},Vn=Zr(ee=>{Ka.start(800+T,()=>{Gn=!1}),Go(!1),L&&Ke&&L(ee),Ct.start(Ge.transitions.duration.shortest,()=>{ct.current=!1})}),Sr=ee=>{ct.current&&ee.type!=="touchstart"||(Ee&&Ee.removeAttribute("title"),Tt.clear(),dt.clear(),F||Gn&&te?Tt.start(Gn?te:F,()=>{Uo(ee)}):Uo(ee))},qo=ee=>{Tt.clear(),dt.start(T,()=>{Vn(ee)})},{isFocusVisibleRef:Ho,onBlur:rl,onFocus:ol,ref:al}=ai(),[,Xo]=M.useState(!1),Yo=ee=>{rl(ee),Ho.current===!1&&(Xo(!1),qo(ee))},Wo=ee=>{Ee||Dn(ee.currentTarget),ol(ee),Ho.current===!0&&(Xo(!0),Sr(ee))},Ko=ee=>{ct.current=!0;const _e=xe.props;_e.onTouchStart&&_e.onTouchStart(ee)},Jo=Sr,Zo=qo,sl=ee=>{Ko(ee),dt.clear(),Ct.clear(),Bn(),Zt.current=document.body.style.WebkitUserSelect,document.body.style.WebkitUserSelect="none",Jt.start(se,()=>{document.body.style.WebkitUserSelect=Zt.current,Sr(ee)})},il=ee=>{xe.props.onTouchEnd&&xe.props.onTouchEnd(ee),Bn(),dt.start(z,()=>{Vn(ee)})};M.useEffect(()=>{if(!Ke)return;function ee(_e){(_e.key==="Escape"||_e.key==="Esc")&&Vn(_e)}return document.addEventListener("keydown",ee),()=>{document.removeEventListener("keydown",ee)}},[Vn,Ke]);const ll=yt(xe.ref,al,Dn,n);!ue&&ue!==0&&(Ke=!1);const Er=M.useRef(),cl=ee=>{const _e=xe.props;_e.onMouseMove&&_e.onMouseMove(ee),sn={x:ee.clientX,y:ee.clientY},Er.current&&Er.current.update()},Qt={},jr=typeof ue=="string";k?(Qt.title=!Ke&&jr&&!$?ue:null,Qt["aria-describedby"]=Ke?kr:null):(Qt["aria-label"]=jr?ue:null,Qt["aria-labelledby"]=Ke&&!jr?kr:null);const De=O({},Qt,A,xe.props,{className:ot(A.className,xe.props.className),onTouchStart:Ko,ref:ll},oe?{onMouseMove:cl}:{});process.env.NODE_ENV!=="production"&&(De["data-mui-internal-clone-element"]=!0,M.useEffect(()=>{Ee&&!Ee.getAttribute("data-mui-internal-clone-element")&&console.error(["MUI: The `children` component of the Tooltip is not forwarding its props correctly.","Please make sure that props are spread on the same element that the ref is applied to."].join(` -`))},[Ee]));const en={};Y||(De.onTouchStart=sl,De.onTouchEnd=il),$||(De.onMouseOver=Un(Jo,De.onMouseOver),De.onMouseLeave=Un(Zo,De.onMouseLeave),jt||(en.onMouseOver=Jo,en.onMouseLeave=Zo)),D||(De.onFocus=Un(Wo,De.onFocus),De.onBlur=Un(Yo,De.onBlur),jt||(en.onFocus=Wo,en.onBlur=Yo)),process.env.NODE_ENV!=="production"&&xe.props.title&&console.error(["MUI: You have provided a `title` prop to the child of .",`Remove this title prop \`${xe.props.title}\` or the Tooltip component.`].join(` -`));const dl=M.useMemo(()=>{var ee;let _e=[{name:"arrow",enabled:!!Ue,options:{element:Ue,padding:4}}];return(ee=G.popperOptions)!=null&&ee.modifiers&&(_e=_e.concat(G.popperOptions.modifiers)),O({},G.popperOptions,{modifiers:_e})},[Ue,G]),tn=O({},P,{isRtl:lt,arrow:V,disableInteractive:jt,placement:q,PopperComponentProp:H,touch:ct.current}),Cr=om(tn),Qo=(r=(o=Z.popper)!=null?o:C.Popper)!=null?r:am,ea=(s=(i=(l=Z.transition)!=null?l:C.Transition)!=null?i:I)!=null?s:Wa,ta=(c=(d=Z.tooltip)!=null?d:C.Tooltip)!=null?c:sm,na=(u=(f=Z.arrow)!=null?f:C.Arrow)!=null?u:im,ul=un(Qo,O({},G,(w=K.popper)!=null?w:_.popper,{className:ot(Cr.popper,G==null?void 0:G.className,(b=(x=K.popper)!=null?x:_.popper)==null?void 0:b.className)}),tn),pl=un(ea,O({},ye,(m=K.transition)!=null?m:_.transition),tn),wl=un(ta,O({},(h=K.tooltip)!=null?h:_.tooltip,{className:ot(Cr.tooltip,(S=(R=K.tooltip)!=null?R:_.tooltip)==null?void 0:S.className)}),tn),fl=un(na,O({},(j=K.arrow)!=null?j:_.arrow,{className:ot(Cr.arrow,(E=(v=K.arrow)!=null?v:_.arrow)==null?void 0:E.className)}),tn);return a.jsxs(M.Fragment,{children:[M.cloneElement(xe,De),a.jsx(Qo,O({as:H??Mi,placement:q,anchorEl:oe?{getBoundingClientRect:()=>({top:sn.y,left:sn.x,right:sn.x,bottom:sn.y,width:0,height:0})}:Ee,popperRef:Er,open:Ee?Ke:!1,id:kr,transition:!0},en,ul,{popperOptions:dl,children:({TransitionProps:ee})=>a.jsx(ea,O({timeout:Ge.transitions.duration.shorter},ee,pl,{children:a.jsxs(ta,O({},wl,{children:[ue,V?a.jsx(na,O({},fl,{ref:Et})):null]}))}))}))]})});process.env.NODE_ENV!=="production"&&($i.propTypes={arrow:p.bool,children:ei.isRequired,classes:p.object,className:p.string,components:p.shape({Arrow:p.elementType,Popper:p.elementType,Tooltip:p.elementType,Transition:p.elementType}),componentsProps:p.shape({arrow:p.object,popper:p.object,tooltip:p.object,transition:p.object}),describeChild:p.bool,disableFocusListener:p.bool,disableHoverListener:p.bool,disableInteractive:p.bool,disableTouchListener:p.bool,enterDelay:p.number,enterNextDelay:p.number,enterTouchDelay:p.number,followCursor:p.bool,id:p.string,leaveDelay:p.number,leaveTouchDelay:p.number,onClose:p.func,onOpen:p.func,open:p.bool,placement:p.oneOf(["bottom-end","bottom-start","bottom","left-end","left-start","left","right-end","right-start","right","top-end","top-start","top"]),PopperComponent:p.elementType,PopperProps:p.object,slotProps:p.shape({arrow:p.object,popper:p.object,tooltip:p.object,transition:p.object}),slots:p.shape({arrow:p.elementType,popper:p.elementType,tooltip:p.elementType,transition:p.elementType}),sx:p.oneOfType([p.arrayOf(p.oneOfType([p.func,p.object,p.bool])),p.func,p.object]),title:p.node,TransitionComponent:p.elementType,TransitionProps:p.object});const lm=$i;function Ja(e,t,n){return e?a.jsx(Me.ListItemIcon,{className:`papi-menu-icon-${n?"leading":"trailing"}`,children:a.jsx("img",{src:e,alt:`${n?"Leading":"Trailing"} icon for ${t}`})}):void 0}function Fo(e){const{onClick:t,label:n,tooltip:r,allowForLeadingIcons:o=!0,iconPathBefore:s=void 0,iconPathAfter:i=void 0,hasAutoFocus:l=!1,className:c,isDisabled:d=!1,isDense:u=!0,isSubMenuParent:f=!1,hasDisabledGutters:w=!1,hasDivider:b=!1,focusVisibleClassName:x,id:m,children:h}=e,S=a.jsx(Me.MenuItem,{sx:{lineHeight:.8},autoFocus:l,className:c,disabled:d,dense:u,disableGutters:w,divider:b,focusVisibleClassName:x,onClick:t,id:m,children:n?a.jsxs(a.Fragment,{children:[Ja(s,n,!0),a.jsx(Me.ListItemText,{primary:n,inset:!s&&o}),f?a.jsx(Me.ListItemIcon,{className:"papi-menu-icon-trailing",children:a.jsx(gi,{})}):Ja(i,n,!1)]}):h});return r?a.jsx(lm,{title:r,placement:"right",children:a.jsx("div",{children:S})}):S}function Di(e){return Object.entries(e.groups).map(([n,r])=>({id:n,group:r}))}function cm(e){const[t,n]=g.useState(void 0),{parentMenuItem:r,parentItemProps:o,menuDefinition:s}=e,i=d=>{n(d.currentTarget)},l=()=>{n(void 0)},c=()=>{let d=Di(s).filter(u=>"menuItem"in u.group);if(!(r!=null&&r.id))throw new Error("A valid parent menu item is required for submenus.");return d=d.filter(u=>"menuItem"in u.group&&u.group.menuItem===r.id),a.jsx(Ai,{...e,includedGroups:d})};return a.jsxs(a.Fragment,{children:[a.jsx(Fo,{onClick:i,...o,isSubMenuParent:!0}),a.jsx(Me.Menu,{anchorEl:t,open:!!t,onClose:l,anchorOrigin:{vertical:"top",horizontal:"right"},transformOrigin:{vertical:"top",horizontal:"left"},children:c()},r.id)]})}const dm=(e,t)=>t.filter(o=>o.group===e).sort((o,s)=>(o.order||0)-(s.order||0));function Ai(e){const{menuDefinition:t,onClick:n,commandHandler:r,includedGroups:o}=e,{items:s,allowForLeadingIcons:i}=g.useMemo(()=>{const u=o&&o.length>0?o:Di(t).filter(x=>!("menuItem"in x.group)),f=Object.values(u).sort((x,m)=>(x.group.order||0)-(m.group.order||0)),w=[];f.forEach(x=>{dm(x.id,t.items).forEach(m=>w.push({item:m,isLastItemInGroup:!1})),w.length>0&&(w[w.length-1].isLastItemInGroup=!0)}),w.length>0&&(w[w.length-1].isLastItemInGroup=!1);const b=w.some(x=>"iconPathBefore"in x.item&&x.item.iconPathBefore);return{items:w,allowForLeadingIcons:b}},[o,t]),l=({item:u,isLastItemInGroup:f})=>({className:"papi-menu-item",label:u.label,tooltip:u.tooltip,iconPathBefore:"iconPathBefore"in u?u.iconPathBefore:void 0,iconPathAfter:"iconPathAfter"in u?u.iconPathAfter:void 0,hasDivider:f,allowForLeadingIcons:i}),[c]=s;if(!c)return a.jsx("div",{});const d=c.item.group;return a.jsx("div",{role:"menu","aria-label":d,children:s.map((u,f)=>{const{item:w}=u,b=l(u);if("command"in w){const x=w.group+f;return a.jsx(Fo,{onClick:m=>{n==null||n(m),r(w)},...b},x)}return a.jsx(cm,{parentMenuItem:w,parentItemProps:b,...e},d+w.id)})},d)}function um(e){const{menuDefinition:t,columnId:n}=e;let s=Object.entries(t.groups).map(([i,l])=>({id:i,group:l})).filter(i=>"column"in i.group);return n&&"columns"in t&&t.columns[n]&&(s=s.filter(i=>"column"in i.group&&i.group.column===n)),a.jsx(Ai,{...e,includedGroups:s})}function pm({commandHandler:e,menuDefinition:t,id:n,metadata:r,onClick:o,className:s}){return a.jsxs(Me.Grid,{id:n,item:!0,xs:"auto",role:"menu","aria-label":n,className:`papi-menu-column ${s??""}`,children:[a.jsx("h3",{"aria-label":r.label,className:`papi-menu-column-header ${s??""}`,children:r.label}),a.jsx(Me.List,{id:n,dense:!0,className:s??"",children:a.jsx(um,{commandHandler:e,menuDefinition:t,columnId:n,onClick:o})})]})}function Bi({commandHandler:e,className:t,multiColumnMenu:n,id:r}){const{columns:o}=n,s=g.useMemo(()=>{const i=new Map;return Object.getOwnPropertyNames(o).forEach(l=>{if(l==="isExtensible")return;const c=l,d=o[c];typeof d=="object"&&typeof d.order=="number"&&!Number.isNaN(d.order)?i.set(d.order,{id:c,metadata:d}):console.warn(`Property ${l} (${typeof d}) on menu ${r} is not a valid column and is being ignored. This might indicate data corruption`)}),Array.from(i.values()).sort((l,c)=>(l.metadata.order||0)-(c.metadata.order||0))},[o,r]);return a.jsx(Me.Grid,{container:!0,spacing:0,className:`papi-multi-column-menu ${t??""}`,columns:s.length,role:"menu","aria-label":"GridMenu",id:r,children:s.map((i,l)=>a.jsx(pm,{commandHandler:e,menuDefinition:n,...i,className:t},l))})}function wm(e){return{preserveValue:!0,...e}}const nr=(e,t,n={})=>{const r=g.useRef(t);r.current=t;const o=g.useRef(n);o.current=wm(o.current);const[s,i]=g.useState(()=>r.current),[l,c]=g.useState(!0);return g.useEffect(()=>{let d=!0;return c(!!e),(async()=>{if(e){const u=await e();d&&(i(()=>u),c(!1))}})(),()=>{d=!1,o.current.preserveValue||i(()=>r.current)}},[e]),[s,l]},fm=hi(a.jsx("path",{d:"M3 18h18v-2H3zm0-5h18v-2H3zm0-7v2h18V6z"}),"Menu");function Vi({menuProvider:e,normalMenu:t,fullMenu:n,commandHandler:r,containerRef:o,className:s,ariaLabelPrefix:i,children:l}){const[c,d]=g.useState(!1),[u,f]=g.useState(!1),w=g.useCallback(()=>{c&&d(!1),f(!1)},[c]),b=g.useCallback(E=>{E.stopPropagation(),d(v=>{const P=!v;return P&&E.shiftKey?f(!0):P||f(!1),P})},[]),x=g.useCallback(E=>(w(),r(E)),[r,w]),[m,h]=g.useState({top:1,left:1});g.useEffect(()=>{if(c){const E=o==null?void 0:o.current;if(E){const v=E.getBoundingClientRect(),P=window.scrollY,V=window.scrollX,U=v.top+P+E.clientHeight,C=v.left+V;h({top:U,left:C})}}},[c,o]);const[S]=nr(g.useCallback(async()=>(e==null?void 0:e(!1))??t,[e,t,c]),t),[R]=nr(g.useCallback(async()=>(e==null?void 0:e(!0))??n??S,[e,n,S,c]),n??S),j=u&&R?R:S;return a.jsxs(a.Fragment,{children:[a.jsx(Me.IconButton,{sx:{paddingTop:0,paddingBottom:0},edge:"start",className:`papi-menuButton ${s??""}`,color:"inherit","aria-label":`${i??""} menu button`,onClick:b,children:l??a.jsx(fm,{})}),a.jsx(Me.Drawer,{className:`papi-menu-drawer ${s??""}`,anchor:"left",variant:"temporary",open:c,onClose:w,PaperProps:{className:"papi-menu-drawer-paper",style:{top:m.top,left:m.left}},children:j?a.jsx(Bi,{className:s,id:`${i??""} main menu`,commandHandler:x,multiColumnMenu:j}):void 0})]})}function mm({id:e,label:t,isDisabled:n=!1,tooltip:r,isTooltipSuppressed:o=!1,adjustMarginToAlignToEdge:s=!1,size:i="medium",className:l,onClick:c,children:d}){return a.jsx(Me.IconButton,{id:e,disabled:n,edge:s,size:i,"aria-label":t,title:o?void 0:r??t,className:`papi-icon-button ${l??""}`,onClick:c,children:d})}const Kt=g.forwardRef(({className:e,...t},n)=>a.jsx(Q.LoaderCircle,{size:35,className:N("tw-animate-spin",e),...t,ref:n}));Kt.displayName="Spinner";function hm({id:e,isDisabled:t=!1,hasError:n=!1,isFullWidth:r=!1,helperText:o,label:s,placeholder:i,isRequired:l=!1,className:c,defaultValue:d,value:u,onChange:f,onFocus:w,onBlur:b}){return a.jsxs("div",{className:N("tw-inline-grid tw-items-center tw-gap-1.5",{"tw-w-full":r}),children:[a.jsx(qe,{htmlFor:e,className:N({"tw-text-red-600":n,"tw-hidden":!s}),children:`${s}${l?"*":""}`}),a.jsx(St,{id:e,disabled:t,placeholder:i,required:l,className:N(c,{"tw-border-red-600":n}),defaultValue:d,value:u,onChange:f,onFocus:w,onBlur:b}),a.jsx("p",{className:N({"tw-hidden":!o}),children:o})]})}function gm({menuProvider:e,commandHandler:t,className:n,id:r,children:o}){const s=g.useRef(void 0);return a.jsx("div",{ref:s,style:{position:"relative"},children:a.jsx(Me.AppBar,{position:"static",id:r,children:a.jsxs(Me.Toolbar,{className:N("tw-bg-muted tw-text-muted-foreground",n),variant:"dense",children:[e?a.jsx(Vi,{commandHandler:t,containerRef:s,menuProvider:e}):void 0,o?a.jsx("div",{className:"papi-toolbar-children",children:o}):void 0]})})})}const bm=Xt.cva("tw-relative tw-w-full tw-rounded-lg tw-border tw-p-4 [&>svg~*]:tw-pl-7 [&>svg+div]:tw-translate-y-[-3px] [&>svg]:tw-absolute [&>svg]:tw-left-4 [&>svg]:tw-top-4 [&>svg]:tw-text-foreground",{variants:{variant:{default:"tw-bg-background tw-text-foreground",destructive:"tw-border-destructive/50 tw-text-destructive dark:tw-border-destructive [&>svg]:tw-text-destructive"}},defaultVariants:{variant:"default"}}),zi=g.forwardRef(({className:e,variant:t,...n},r)=>a.jsx("div",{ref:r,role:"alert",className:N(bm({variant:t}),e),...n}));zi.displayName="Alert";const Li=g.forwardRef(({className:e,...t},n)=>a.jsxs("h5",{ref:n,className:N("tw-mb-1 tw-font-medium tw-leading-none tw-tracking-tight",e),...t,children:[t.children," "]}));Li.displayName="AlertTitle";const Fi=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,className:N("tw-text-sm [&_p]:tw-leading-relaxed",e),...t}));Fi.displayName="AlertDescription";const Gi=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,className:N("pr-twp tw-rounded-lg tw-border tw-bg-card tw-text-card-foreground tw-shadow-sm",e),...t}));Gi.displayName="Card";const Ui=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,className:N("pr-twp tw-flex tw-flex-col tw-space-y-1.5 tw-p-6",e),...t}));Ui.displayName="CardHeader";const qi=g.forwardRef(({className:e,...t},n)=>a.jsx("h3",{ref:n,className:N("pr-twp tw-text-2xl tw-font-semibold tw-leading-none tw-tracking-tight",e),...t,children:t.children}));qi.displayName="CardTitle";const Hi=g.forwardRef(({className:e,...t},n)=>a.jsx("p",{ref:n,className:N("pr-twp tw-text-sm tw-text-muted-foreground",e),...t}));Hi.displayName="CardDescription";const Xi=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,className:N("pr-twp tw-p-6 tw-pt-0",e),...t}));Xi.displayName="CardContent";const Yi=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,className:N("pr-twp tw-flex tw-items-center tw-p-6 tw-pt-0",e),...t}));Yi.displayName="CardFooter";function vm({...e}){return a.jsx(Qa.Toaster,{className:"tw-toaster tw-group",toastOptions:{classNames:{toast:"group toast group-[.toaster]:bg-background group-[.toaster]:text-foreground group-[.toaster]:border-border group-[.toaster]:shadow-lg",description:"group-[.toast]:text-muted-foreground",actionButton:"group-[.toast]:bg-primary group-[.toast]:text-primary-foreground",cancelButton:"group-[.toast]:bg-muted group-[.toast]:text-muted-foreground"}},...e})}const Wi=g.forwardRef(({className:e,...t},n)=>a.jsxs(cn.Root,{ref:n,className:N("pr-twp tw-relative tw-flex tw-w-full tw-touch-none tw-select-none tw-items-center",e),...t,children:[a.jsx(cn.Track,{className:"tw-relative tw-h-2 tw-w-full tw-grow tw-overflow-hidden tw-rounded-full tw-bg-secondary",children:a.jsx(cn.Range,{className:"tw-absolute tw-h-full tw-bg-primary"})}),a.jsx(cn.Thumb,{className:"tw-block tw-h-5 tw-w-5 tw-rounded-full tw-border-2 tw-border-primary tw-bg-background tw-ring-offset-background tw-transition-colors focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50"})]}));Wi.displayName=cn.Root.displayName;const Ki=g.forwardRef(({className:e,...t},n)=>a.jsx(qr.Root,{className:N("tw-peer pr-twp tw-inline-flex tw-h-6 tw-w-11 tw-shrink-0 tw-cursor-pointer tw-items-center tw-rounded-full tw-border-2 tw-border-transparent tw-transition-colors focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 focus-visible:tw-ring-offset-background disabled:tw-cursor-not-allowed disabled:tw-opacity-50 data-[state=checked]:tw-bg-primary data-[state=unchecked]:tw-bg-input",e),...t,ref:n,children:a.jsx(qr.Thumb,{className:N("pr-twp tw-pointer-events-none tw-block tw-h-5 tw-w-5 tw-rounded-full tw-bg-background tw-shadow-lg tw-ring-0 tw-transition-transform data-[state=checked]:tw-translate-x-5 data-[state=unchecked]:tw-translate-x-0")})}));Ki.displayName=qr.Root.displayName;const xm=Oe.Root,Ji=g.forwardRef(({className:e,...t},n)=>a.jsx(Oe.List,{ref:n,className:N("tw-inline-flex tw-h-10 tw-items-center tw-justify-center tw-rounded-md tw-bg-muted tw-p-1 tw-text-muted-foreground",e),...t}));Ji.displayName=Oe.List.displayName;const Zi=g.forwardRef(({className:e,...t},n)=>a.jsx(Oe.Trigger,{ref:n,className:N("tw-inline-flex tw-items-center tw-justify-center tw-whitespace-nowrap tw-rounded-sm tw-px-3 tw-py-1.5 tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-all hover:tw-text-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50 data-[state=active]:tw-bg-background data-[state=active]:tw-text-foreground data-[state=active]:tw-shadow-sm",e),...t}));Zi.displayName=Oe.Trigger.displayName;const Qi=g.forwardRef(({className:e,...t},n)=>a.jsx(Oe.Content,{ref:n,className:N("tw-mt-2 tw-ring-offset-background focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2",e),...t}));Qi.displayName=Oe.Content.displayName;function ym({isInstalling:e,handleClick:t,buttonText:n,className:r,...o}){return a.jsx(fe,{className:N("tw-h-8 tw-rounded-md tw-text-white tw-transition tw-duration-300 tw-ease-in-out hover:tw-bg-blue-700",{"tw-cursor-not-allowed tw-bg-blue-700":e,"tw-bg-blue-600":!e,"tw-bg-white tw-text-blue-600 hover:tw-text-white":!n,"tw-w-20":n},r),onClick:t,...o,children:e?a.jsx(Kt,{size:15}):a.jsxs(a.Fragment,{children:[a.jsx(Q.Download,{size:25,className:N("tw-h-4 tw-w-4",{"tw-mr-1":n})}),n]})})}function Nm({isEnabling:e,handleClick:t,className:n,...r}){return a.jsx(fe,{className:N("tw-h-8 tw-rounded-md tw-bg-blue-600 tw-px-4 tw-text-white tw-transition tw-duration-300 tw-ease-in-out hover:tw-bg-blue-700",{"tw-cursor-not-allowed tw-bg-blue-700":e},n),onClick:t,...r,children:e?a.jsxs(a.Fragment,{children:[a.jsx(Kt,{size:15,className:"tw-mr-1 tw-text-white"}),"Enabling..."]}):"Enable"})}function km({isDisabling:e,handleClick:t,className:n,...r}){return a.jsx(fe,{className:N("tw-h-8 tw-rounded-md tw-bg-gray-300 tw-text-black tw-transition tw-duration-300 tw-ease-in-out hover:tw-bg-gray-400",{"tw-cursor-not-allowed tw-bg-gray-400":e},n),onClick:t,...r,children:e?a.jsxs(a.Fragment,{children:[a.jsx(Kt,{size:15,className:"tw-mr-1 tw-text-black"}),"Disabling..."]}):"Disable"})}function Sm({isUpdating:e,handleClick:t,className:n,...r}){return a.jsx(fe,{className:N("tw-h-8 tw-rounded-md tw-bg-blue-600 tw-px-4 tw-text-white tw-transition tw-duration-300 tw-ease-in-out hover:tw-bg-blue-700 hover:tw-text-white",{"tw-cursor-not-allowed tw-bg-blue-700":e},n),onClick:t,...r,children:e?a.jsxs(a.Fragment,{children:[a.jsx(Kt,{size:15,className:"tw-mr-1 tw-text-white"}),"Updating..."]}):"Update"})}function Em({id:e,markdown:t,className:n,anchorTarget:r}){const o=g.useMemo(()=>({overrides:{a:{props:{target:r}}}}),[r]);return a.jsx("div",{id:e,className:N("pr-twp tw-prose",n),children:a.jsx(Rl,{options:o,children:t})})}const el=g.forwardRef((e,t)=>a.jsxs(fe,{ref:t,className:"tw-rounded-md tw-border tw-border-dashed tw-border-gray-400 tw-bg-white tw-px-4 tw-py-2 tw-text-black tw-transition tw-duration-300 tw-ease-in-out hover:tw-border-blue-600 hover:tw-bg-white hover:tw-text-blue-600",...e,children:[a.jsx(Q.Filter,{size:16,className:"tw-mr-2 tw-h-4 tw-w-4 tw-text-gray-700 hover:tw-text-blue-600"}),"Filter",a.jsx(Q.ChevronDown,{size:16,className:"tw-ml-2 tw-h-4 tw-w-4 tw-text-gray-700 hover:tw-text-blue-600"})]}));var tl=(e=>(e[e.Check=0]="Check",e[e.Radio=1]="Radio",e))(tl||{});function jm({id:e,groups:t}){return a.jsx("div",{id:e,children:a.jsxs(or,{children:[a.jsx(lo,{asChild:!0,children:a.jsx(el,{})}),a.jsx(En,{children:t.map(n=>a.jsxs("div",{children:[a.jsx(Wt,{children:n.label}),a.jsx(cs,{children:n.items.map(r=>a.jsx("div",{children:r.itemType===0?a.jsx(ar,{onClick:r.onClick,children:r.label}):a.jsx(uo,{onClick:r.onClick,value:r.label,children:r.label})},r.label))}),a.jsx(jn,{})]},n.label))})]})})}function Cm({id:e,message:t}){return a.jsx("div",{id:e,className:"tw-mb-20 tw-mt-20 tw-flex tw-items-center tw-justify-center",children:a.jsx("div",{className:"tw-w-3/4 tw-rounded-lg tw-bg-gray-100 tw-p-8 tw-text-center",children:a.jsx("p",{className:"tw-text-lg tw-text-gray-800",children:t})})})}function Tm({id:e,category:t,downloads:n,languages:r,moreInfoUrl:o}){const s=new W.NumberFormat("en",{notation:"compact",compactDisplay:"short"}).format(Object.values(n).reduce((l,c)=>l+c,0)),i=()=>{window.scrollTo(0,document.body.scrollHeight)};return a.jsxs("div",{id:e,className:"tw-flex tw-flex-wrap tw-items-start tw-space-x-4 tw-border-b tw-border-t tw-bg-white tw-pb-4 tw-pt-4",children:[a.jsxs("div",{className:"tw-flex tw-flex-col tw-items-center",children:[a.jsx("div",{className:"tw-flex tw-items-center tw-rounded-md tw-bg-gray-100 tw-px-2 tw-py-1",children:a.jsx("span",{className:"tw-text-xs tw-font-semibold tw-text-gray-700",children:t})}),a.jsx("span",{className:"tw-text-xs tw-text-gray-500",children:"CATEGORY"})]}),a.jsx("div",{className:"tw-mx-2 tw-h-10 tw-border-l tw-border-gray-300"}),a.jsxs("div",{className:"tw-flex tw-flex-col tw-items-center",children:[a.jsxs("div",{className:"tw-flex tw-items-center tw-rounded-md tw-bg-gray-100 tw-px-2 tw-py-1",children:[a.jsx(Q.User,{className:"tw-mr-1 tw-h-4 tw-w-4"}),a.jsx("span",{className:"tw-text-xs tw-font-semibold tw-text-gray-700",children:s})]}),a.jsx("span",{className:"tw-text-xs tw-text-gray-500",children:"USERS"})]}),a.jsx("div",{className:"tw-mx-2 tw-h-10 tw-border-l tw-border-gray-300"}),a.jsxs("div",{className:"tw-flex tw-flex-col tw-items-center",children:[a.jsx("div",{className:"tw-flex tw-items-center",children:r.slice(0,3).map(l=>a.jsx("span",{className:"tw-ml-1 tw-rounded-md tw-bg-gray-100 tw-px-2 tw-py-1 tw-text-xs tw-font-semibold tw-text-gray-700",children:l.toUpperCase()},l))}),r.length>3&&a.jsxs("button",{type:"button",onClick:()=>i(),className:"tw-text-xs tw-text-gray-500 tw-underline",children:["+",r.length-3," more languages"]})]}),a.jsx("div",{className:"tw-mx-2 tw-h-10 tw-border-l tw-border-gray-300"}),a.jsxs("div",{className:"tw-ml-auto tw-flex tw-flex-col tw-space-y-2",children:[a.jsxs("a",{href:o,target:"_blank",rel:"noreferrer",className:"tw-flex tw-items-center tw-text-xs tw-font-semibold tw-text-gray-500 tw-underline",children:["Website",a.jsx(Q.Link,{className:"tw-ml-1 tw-inline tw-h-4 tw-w-4"})]}),a.jsxs("a",{href:"https://example.com",target:"_blank",rel:"noreferrer",className:"tw-flex tw-items-center tw-text-xs tw-font-semibold tw-text-gray-500 tw-underline",children:["Support",a.jsx(Q.CircleHelp,{className:"tw-ml-1 tw-inline tw-h-4 tw-w-4"})]})]})]})}function nl({id:e,versionHistory:t}){const[n,r]=g.useState(!1),o=new Date;function s(l){const c=new Date(l),d=new Date(o.getTime()-c.getTime()),u=d.getUTCFullYear()-1970,f=d.getUTCMonth(),w=d.getUTCDate()-1;let b="";return u>0?b=`${u.toString()} year${u===1?"":"s"} ago`:f>0?b=`${f.toString()} month${f===1?"":"s"} ago`:w===0?b="today":b=`${w.toString()} day${w===1?"":"s"} ago`,b}const i=Object.entries(t).sort((l,c)=>c[0].localeCompare(l[0]));return a.jsxs("div",{id:e,children:[a.jsx("h3",{className:"tw-text-md tw-font-semibold",children:"What`s New"}),a.jsx("ul",{className:"tw-list-disc tw-pl-5 tw-pr-4 tw-text-xs tw-text-gray-600",children:(n?i:i.slice(0,5)).map(l=>a.jsxs("div",{className:"tw-mt-3 tw-flex tw-justify-between",children:[a.jsx("div",{className:"tw-text-gray-600",children:a.jsx("li",{className:"tw-prose tw-text-xs",children:a.jsx("span",{children:l[1].description})})}),a.jsxs("div",{className:"tw-justify-end tw-text-right",children:[a.jsxs("div",{children:["Version ",l[0]]}),a.jsx("div",{children:s(l[1].date)})]})]},l[0]))}),i.length>5&&a.jsx("button",{type:"button",onClick:()=>r(!n),className:"tw-text-xs tw-text-gray-500 tw-underline",children:n?"Show Less Version History":"Show All Version History"})]})}function Rm({id:e,publisherDisplayName:t,fileSize:n,locales:r,versionHistory:o}){const s=g.useMemo(()=>W.formatBytes(n),[n]),l=(c=>{const d=new Intl.DisplayNames(navigator.language,{type:"language"});return c.map(u=>d.of(u))})(r);return a.jsx("div",{id:e,className:"tw-border-t tw-pb-4 tw-pt-4",children:a.jsxs("div",{className:"tw-md:flex-row tw-md:space-x-8 tw-flex tw-flex-col tw-space-x-0",children:[a.jsx(nl,{versionHistory:o}),a.jsx("div",{className:"tw-md:border-t-0 tw-md:border-l tw-md-h-auto tw-md-ml-8 tw-mt-4 tw-border-t tw-border-gray-300"}),a.jsxs("div",{className:"tw-md:mt-0 tw-mt-4 tw-flex-1 tw-space-y-3",children:[a.jsx("h2",{className:"tw-text-md tw-font-semibold",children:"Information"}),a.jsxs("div",{className:"tw-flex tw-items-start tw-justify-between tw-pr-4 tw-text-xs tw-text-gray-600",children:[a.jsxs("p",{className:"tw-flex tw-flex-col tw-justify-start",children:[a.jsx("span",{className:"tw-mb-2",children:"Publisher"}),a.jsx("span",{className:"tw-font-semibold",children:t}),a.jsx("span",{className:"tw-mb-2 tw-mt-4",children:"Size"}),a.jsx("span",{className:"tw-font-semibold",children:s})]}),a.jsx("div",{className:"tw-flex tw-w-3/4 tw-items-center tw-justify-between tw-text-xs tw-text-gray-600",children:a.jsxs("p",{className:"tw-flex tw-flex-col tw-justify-start",children:[a.jsx("span",{className:"tw-mb-2",children:"Languages"}),a.jsx("span",{className:"tw-font-semibold",children:l.join(", ")})]})})]})]})]})})}const Om=(e,t)=>{g.useEffect(()=>{if(!e)return()=>{};const n=e(t);return()=>{n()}},[e,t])},Fr=()=>!1,_m=(e,t)=>{const[n]=nr(g.useCallback(async()=>{if(!e)return Fr;const r=await Promise.resolve(e(t));return async()=>r()},[t,e]),Fr,{preserveValue:!1});g.useEffect(()=>()=>{n!==Fr&&n()},[n])};Object.defineProperty(exports,"sonner",{enumerable:!0,get:()=>Qa.toast});exports.Alert=zi;exports.AlertDescription=Fi;exports.AlertTitle=Li;exports.BOOK_SELECTOR_STRING_KEYS=mc;exports.BookChapterControl=oc;exports.BookSelectionMode=Ns;exports.BookSelector=hc;exports.Button=fe;exports.Card=Gi;exports.CardContent=Xi;exports.CardDescription=Hi;exports.CardFooter=Yi;exports.CardHeader=Ui;exports.CardTitle=qi;exports.ChapterRangeSelector=ys;exports.Checkbox=sr;exports.Checklist=bd;exports.ComboBox=Wn;exports.DataTable=Ts;exports.DisableButton=km;exports.DropdownMenu=or;exports.DropdownMenuCheckboxItem=ar;exports.DropdownMenuContent=En;exports.DropdownMenuGroup=cs;exports.DropdownMenuItem=co;exports.DropdownMenuItemType=tl;exports.DropdownMenuLabel=Wt;exports.DropdownMenuPortal=ql;exports.DropdownMenuRadioGroup=Xl;exports.DropdownMenuRadioItem=uo;exports.DropdownMenuSeparator=jn;exports.DropdownMenuShortcut=ps;exports.DropdownMenuSub=Hl;exports.DropdownMenuSubContent=us;exports.DropdownMenuSubTrigger=ds;exports.DropdownMenuTrigger=lo;exports.EnableButton=Nm;exports.FilterButton=el;exports.FilterDropdown=jm;exports.Footer=Rm;exports.GridMenu=Bi;exports.HamburgerMenuButton=Vi;exports.INVENTORY_STRING_KEYS=Ec;exports.IconButton=mm;exports.Input=St;exports.InstallButton=ym;exports.Inventory=Tc;exports.Label=qe;exports.MarkdownRenderer=Em;exports.MenuItem=Fo;exports.MoreInfo=Tm;exports.NavigationContentSearch=Rc;exports.NoExtensionsFound=Cm;exports.RadioGroup=po;exports.RadioGroupItem=Yn;exports.ScriptureResultsViewer=wd;exports.ScrollGroupSelector=fd;exports.SearchBar=ho;exports.Select=At;exports.SelectContent=vt;exports.SelectGroup=ks;exports.SelectItem=Ae;exports.SelectLabel=Ss;exports.SelectScrollDownButton=fo;exports.SelectScrollUpButton=wo;exports.SelectSeparator=Es;exports.SelectTrigger=bt;exports.SelectValue=Bt;exports.Separator=lr;exports.SettingsList=md;exports.SettingsListHeader=gd;exports.SettingsListItem=hd;exports.SettingsSidebar=Hs;exports.SettingsSidebarContentSearch=ad;exports.Slider=Wi;exports.Sonner=vm;exports.Spinner=Kt;exports.Switch=Ki;exports.Table=Cn;exports.TableBody=Rn;exports.TableCaption=Cs;exports.TableCell=xt;exports.TableFooter=js;exports.TableHead=Vt;exports.TableHeader=Tn;exports.TableRow=Ze;exports.Tabs=xm;exports.TabsContent=Qi;exports.TabsList=Ji;exports.TabsTrigger=Zi;exports.TextField=hm;exports.ToggleGroup=mo;exports.ToggleGroupItem=fn;exports.Toolbar=gm;exports.UpdateButton=Sm;exports.VersionHistory=nl;exports.VerticalTabs=go;exports.VerticalTabsContent=vo;exports.VerticalTabsList=bo;exports.VerticalTabsTrigger=Ms;exports.buttonVariants=ws;exports.cn=N;exports.getBookNumFromId=Os;exports.getLinesFromUSFM=Rs;exports.getNumberFromUSFM=Hr;exports.getStatusForItem=_s;exports.inventoryCountColumn=kc;exports.inventoryItemColumn=yc;exports.inventoryStatusColumn=Sc;exports.useEvent=Om;exports.useEventAsync=_m;exports.usePromise=nr;function Pm(e,t="top"){if(!e||typeof document>"u")return;const n=document.head||document.querySelector("head"),r=n.querySelector(":first-child"),o=document.createElement("style");o.appendChild(document.createTextNode(e)),t==="top"&&r?n.insertBefore(o,r):n.appendChild(o)}Pm(`*, ::before, ::after { +} });`:zt(12,h?` (${h})`:"",JSON.stringify(m.main)));return Oa(m,"light",I,r),Oa(m,"dark",C,r),m.contrastText||(m.contrastText=f(m.main)),m},b={dark:Vr,light:Ra};return process.env.NODE_ENV!=="production"&&(b[t]||console.error(`MUI: The palette mode \`${t}\` is not supported.`)),Qe(R({common:R({},xn),mode:t,primary:w({color:s,name:"primary"}),secondary:w({color:i,name:"secondary",mainShade:"A400",lightShade:"A200",darkShade:"A700"}),error:w({color:l,name:"error"}),warning:w({color:u,name:"warning"}),info:w({color:c,name:"info"}),success:w({color:d,name:"success"}),grey:wp,contrastThreshold:n,getContrastText:f,augmentColor:w,tonalOffset:r},b[t]),o)}const Cp=["fontFamily","fontSize","fontWeightLight","fontWeightRegular","fontWeightMedium","fontWeightBold","htmlFontSize","allVariants","pxToRem"];function Rp(e){return Math.round(e*1e5)/1e5}const _a={textTransform:"uppercase"},Pa='"Roboto", "Helvetica", "Arial", sans-serif';function Op(e,t){const n=typeof t=="function"?t(e):t,{fontFamily:r=Pa,fontSize:o=14,fontWeightLight:s=300,fontWeightRegular:i=400,fontWeightMedium:l=500,fontWeightBold:c=700,htmlFontSize:d=16,allVariants:u,pxToRem:f}=n,w=ye(n,Cp);process.env.NODE_ENV!=="production"&&(typeof o!="number"&&console.error("MUI: `fontSize` is required to be a number."),typeof d!="number"&&console.error("MUI: `htmlFontSize` is required to be a number."));const b=o/14,x=f||(E=>`${E/d*b}rem`),m=(E,I,C,S,v)=>R({fontFamily:r,fontWeight:E,fontSize:x(I),lineHeight:C},r===Pa?{letterSpacing:`${Rp(S/I)}em`}:{},v,u),h={h1:m(s,96,1.167,-1.5),h2:m(s,60,1.2,-.5),h3:m(i,48,1.167,0),h4:m(i,34,1.235,.25),h5:m(i,24,1.334,0),h6:m(l,20,1.6,.15),subtitle1:m(i,16,1.75,.15),subtitle2:m(l,14,1.57,.1),body1:m(i,16,1.5,.15),body2:m(i,14,1.43,.15),button:m(l,14,1.75,.4,_a),caption:m(i,12,1.66,.4),overline:m(i,12,2.66,1,_a),inherit:{fontFamily:"inherit",fontWeight:"inherit",fontSize:"inherit",lineHeight:"inherit",letterSpacing:"inherit"}};return Qe(R({htmlFontSize:d,pxToRem:x,fontFamily:r,fontSize:o,fontWeightLight:s,fontWeightRegular:i,fontWeightMedium:l,fontWeightBold:c},h),w,{clone:!1})}const _p=.2,Pp=.14,Ip=.12;function we(...e){return[`${e[0]}px ${e[1]}px ${e[2]}px ${e[3]}px rgba(0,0,0,${_p})`,`${e[4]}px ${e[5]}px ${e[6]}px ${e[7]}px rgba(0,0,0,${Pp})`,`${e[8]}px ${e[9]}px ${e[10]}px ${e[11]}px rgba(0,0,0,${Ip})`].join(",")}const Mp=["none",we(0,2,1,-1,0,1,1,0,0,1,3,0),we(0,3,1,-2,0,2,2,0,0,1,5,0),we(0,3,3,-2,0,3,4,0,0,1,8,0),we(0,2,4,-1,0,4,5,0,0,1,10,0),we(0,3,5,-1,0,5,8,0,0,1,14,0),we(0,3,5,-1,0,6,10,0,0,1,18,0),we(0,4,5,-2,0,7,10,1,0,2,16,1),we(0,5,5,-3,0,8,10,1,0,3,14,2),we(0,5,6,-3,0,9,12,1,0,3,16,2),we(0,6,6,-3,0,10,14,1,0,4,18,3),we(0,6,7,-4,0,11,15,1,0,4,20,3),we(0,7,8,-4,0,12,17,2,0,5,22,4),we(0,7,8,-4,0,13,19,2,0,5,24,4),we(0,7,9,-4,0,14,21,2,0,5,26,4),we(0,8,9,-5,0,15,22,2,0,6,28,5),we(0,8,10,-5,0,16,24,2,0,6,30,5),we(0,8,11,-5,0,17,26,2,0,6,32,5),we(0,9,11,-5,0,18,28,2,0,7,34,6),we(0,9,12,-6,0,19,29,2,0,7,36,6),we(0,10,13,-6,0,20,31,3,0,8,38,7),we(0,10,13,-6,0,21,33,3,0,8,40,7),we(0,10,14,-6,0,22,35,3,0,8,42,7),we(0,11,14,-7,0,23,36,3,0,9,44,8),we(0,11,15,-7,0,24,38,3,0,9,46,8)],$p=Mp,Dp=["duration","easing","delay"],Ap={easeInOut:"cubic-bezier(0.4, 0, 0.2, 1)",easeOut:"cubic-bezier(0.0, 0, 0.2, 1)",easeIn:"cubic-bezier(0.4, 0, 1, 1)",sharp:"cubic-bezier(0.4, 0, 0.6, 1)"},Bp={shortest:150,shorter:200,short:250,standard:300,complex:375,enteringScreen:225,leavingScreen:195};function Ia(e){return`${Math.round(e)}ms`}function Vp(e){if(!e)return 0;const t=e/36;return Math.round((4+15*t**.25+t/5)*10)}function zp(e){const t=R({},Ap,e.easing),n=R({},Bp,e.duration);return R({getAutoHeightDuration:Vp,create:(o=["all"],s={})=>{const{duration:i=n.standard,easing:l=t.easeInOut,delay:c=0}=s,d=ye(s,Dp);if(process.env.NODE_ENV!=="production"){const u=w=>typeof w=="string",f=w=>!isNaN(parseFloat(w));!u(o)&&!Array.isArray(o)&&console.error('MUI: Argument "props" must be a string or Array.'),!f(i)&&!u(i)&&console.error(`MUI: Argument "duration" must be a number or a string but found ${i}.`),u(l)||console.error('MUI: Argument "easing" must be a string.'),!f(c)&&!u(c)&&console.error('MUI: Argument "delay" must be a number or a string.'),typeof s!="object"&&console.error(["MUI: Secong argument of transition.create must be an object.","Arguments should be either `create('prop1', options)` or `create(['prop1', 'prop2'], options)`"].join(` +`)),Object.keys(d).length!==0&&console.error(`MUI: Unrecognized argument(s) [${Object.keys(d).join(",")}].`)}return(Array.isArray(o)?o:[o]).map(u=>`${u} ${typeof i=="string"?i:Ia(i)} ${l} ${typeof c=="string"?c:Ia(c)}`).join(",")}},e,{easing:t,duration:n})}const Lp={mobileStepper:1e3,fab:1050,speedDial:1050,appBar:1100,drawer:1200,modal:1300,snackbar:1400,tooltip:1500},Fp=Lp,Gp=["breakpoints","mixins","spacing","palette","transitions","typography","shape"];function Up(e={},...t){const{mixins:n={},palette:r={},transitions:o={},typography:s={}}=e,i=ye(e,Gp);if(e.vars)throw new Error(process.env.NODE_ENV!=="production"?"MUI: `vars` is a private field used for CSS variables support.\nPlease use another name.":zt(18));const l=Tp(r),c=To(e);let d=Qe(c,{mixins:dp(c.breakpoints,n),palette:l,shadows:$p.slice(),typography:Op(l,s),transitions:zp(o),zIndex:R({},Fp)});if(d=Qe(d,i),d=t.reduce((u,f)=>Qe(u,f),d),process.env.NODE_ENV!=="production"){const u=["active","checked","completed","disabled","error","expanded","focused","focusVisible","required","selected"],f=(w,b)=>{let x;for(x in w){const m=w[x];if(u.indexOf(x)!==-1&&Object.keys(m).length>0){if(process.env.NODE_ENV!=="production"){const h=ur("",x);console.error([`MUI: The \`${b}\` component increases the CSS specificity of the \`${x}\` internal state.`,"You can not override it like this: ",JSON.stringify(w,null,2),"",`Instead, you need to use the '&.${h}' syntax:`,JSON.stringify({root:{[`&.${h}`]:m}},null,2),"","https://mui.com/r/state-classes-guide"].join(` +`))}w[x]={}}}};Object.keys(d.components).forEach(w=>{const b=d.components[w].styleOverrides;b&&w.indexOf("Mui")===0&&f(b,w)})}return d.unstable_sxConfig=R({},Eo,i==null?void 0:i.unstable_sxConfig),d.unstable_sx=function(f){return jo({sx:f,theme:this})},d}const qp=Up(),Ro=qp,Oo="$$material";function _o({props:e,name:t}){return ap({props:e,name:t,defaultTheme:Ro,themeId:Oo})}const Hp=e=>qn(e)&&e!=="classes",Yp=rp({themeId:Oo,defaultTheme:Ro,rootShouldForwardProp:Hp}),In=Yp;function Xp(e){return ur("MuiSvgIcon",e)}si("MuiSvgIcon",["root","colorPrimary","colorSecondary","colorAction","colorError","colorDisabled","fontSizeInherit","fontSizeSmall","fontSizeMedium","fontSizeLarge"]);const Wp=["children","className","color","component","fontSize","htmlColor","inheritViewBox","titleAccess","viewBox"],Kp=e=>{const{color:t,fontSize:n,classes:r}=e,o={root:["root",t!=="inherit"&&`color${Xe(t)}`,`fontSize${Xe(n)}`]};return No(o,Xp,r)},Jp=In("svg",{name:"MuiSvgIcon",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.root,n.color!=="inherit"&&t[`color${Xe(n.color)}`],t[`fontSize${Xe(n.fontSize)}`]]}})(({theme:e,ownerState:t})=>{var n,r,o,s,i,l,c,d,u,f,w,b,x;return{userSelect:"none",width:"1em",height:"1em",display:"inline-block",fill:t.hasSvgAsChild?void 0:"currentColor",flexShrink:0,transition:(n=e.transitions)==null||(r=n.create)==null?void 0:r.call(n,"fill",{duration:(o=e.transitions)==null||(o=o.duration)==null?void 0:o.shorter}),fontSize:{inherit:"inherit",small:((s=e.typography)==null||(i=s.pxToRem)==null?void 0:i.call(s,20))||"1.25rem",medium:((l=e.typography)==null||(c=l.pxToRem)==null?void 0:c.call(l,24))||"1.5rem",large:((d=e.typography)==null||(u=d.pxToRem)==null?void 0:u.call(d,35))||"2.1875rem"}[t.fontSize],color:(f=(w=(e.vars||e).palette)==null||(w=w[t.color])==null?void 0:w.main)!=null?f:{action:(b=(e.vars||e).palette)==null||(b=b.action)==null?void 0:b.active,disabled:(x=(e.vars||e).palette)==null||(x=x.action)==null?void 0:x.disabled,inherit:void 0}[t.color]}}),Po=$.forwardRef(function(t,n){const r=_o({props:t,name:"MuiSvgIcon"}),{children:o,className:s,color:i="inherit",component:l="svg",fontSize:c="medium",htmlColor:d,inheritViewBox:u=!1,titleAccess:f,viewBox:w="0 0 24 24"}=r,b=ye(r,Wp),x=$.isValidElement(o)&&o.type==="svg",m=R({},r,{color:i,component:l,fontSize:c,instanceFontSize:t.fontSize,inheritViewBox:u,viewBox:w,hasSvgAsChild:x}),h={};u||(h.viewBox=w);const E=Kp(m);return a.jsxs(Jp,R({as:l,className:ot(E.root,s),focusable:"false",color:d,"aria-hidden":f?void 0:!0,role:f?"img":void 0,ref:n},h,b,x&&o.props,{ownerState:m,children:[x?o.props.children:o,f?a.jsx("title",{children:f}):null]}))});process.env.NODE_ENV!=="production"&&(Po.propTypes={children:p.node,classes:p.object,className:p.string,color:p.oneOfType([p.oneOf(["inherit","action","disabled","primary","secondary","error","info","success","warning"]),p.string]),component:p.elementType,fontSize:p.oneOfType([p.oneOf(["inherit","large","medium","small"]),p.string]),htmlColor:p.string,inheritViewBox:p.bool,shapeRendering:p.string,sx:p.oneOfType([p.arrayOf(p.oneOfType([p.func,p.object,p.bool])),p.func,p.object]),titleAccess:p.string,viewBox:p.string});Po.muiName="SvgIcon";const Ma=Po;function wi(e,t){function n(r,o){return a.jsx(Ma,R({"data-testid":`${t}Icon`,ref:o},r,{children:e}))}return process.env.NODE_ENV!=="production"&&(n.displayName=`${t}Icon`),n.muiName=Ma.muiName,$.memo($.forwardRef(n))}const Zp={configure:e=>{process.env.NODE_ENV!=="production"&&console.warn(["MUI: `ClassNameGenerator` import from `@mui/material/utils` is outdated and might cause unexpected issues.","","You should use `import { unstable_ClassNameGenerator } from '@mui/material/className'` instead","","The detail of the issue: https://github.com/mui/material-ui/issues/30011#issuecomment-1024993401","","The updated documentation: https://mui.com/guides/classname-generator/"].join(` +`)),oi.configure(e)}},Qp=Object.freeze(Object.defineProperty({__proto__:null,capitalize:Xe,createChainedFunction:Cd,createSvgIcon:wi,debounce:Rd,deprecatedPropType:Od,isMuiElement:_d,ownerDocument:Kn,ownerWindow:Pd,requirePropFactory:Id,setRef:Jn,unstable_ClassNameGenerator:Zp,unstable_useEnhancedEffect:Lt,unstable_useId:ei,unsupportedProp:Dd,useControlled:ti,useEventCallback:Jr,useForkRef:yt,useIsFocusVisible:ni},Symbol.toStringTag,{value:"Module"})),ew=ld(Qp);var $a;function tw(){return $a||($a=1,function(e){"use client";Object.defineProperty(e,"__esModule",{value:!0}),Object.defineProperty(e,"default",{enumerable:!0,get:function(){return t.createSvgIcon}});var t=ew}(_r)),_r}var nw=cd;Object.defineProperty(vo,"__esModule",{value:!0});var fi=vo.default=void 0,rw=nw(tw()),ow=a;fi=vo.default=(0,rw.default)((0,ow.jsx)("path",{d:"m10 17 5-5-5-5z"}),"ArrowRight");function aw(e){return typeof e=="string"}function dn(e,t,n){return e===void 0||aw(e)?t:R({},t,{ownerState:R({},t.ownerState,n)})}const sw={disableDefaultClasses:!1},iw=$.createContext(sw);function lw(e){const{disableDefaultClasses:t}=$.useContext(iw);return n=>t?"":e(n)}function cw(e,t=[]){if(e===void 0)return{};const n={};return Object.keys(e).filter(r=>r.match(/^on[A-Z]/)&&typeof e[r]=="function"&&!t.includes(r)).forEach(r=>{n[r]=e[r]}),n}function dw(e,t,n){return typeof e=="function"?e(t,n):e}function Da(e){if(e===void 0)return{};const t={};return Object.keys(e).filter(n=>!(n.match(/^on[A-Z]/)&&typeof e[n]=="function")).forEach(n=>{t[n]=e[n]}),t}function uw(e){const{getSlotProps:t,additionalProps:n,externalSlotProps:r,externalForwardedProps:o,className:s}=e;if(!t){const b=ot(n==null?void 0:n.className,s,o==null?void 0:o.className,r==null?void 0:r.className),x=R({},n==null?void 0:n.style,o==null?void 0:o.style,r==null?void 0:r.style),m=R({},n,o,r);return b.length>0&&(m.className=b),Object.keys(x).length>0&&(m.style=x),{props:m,internalRef:void 0}}const i=cw(R({},o,r)),l=Da(r),c=Da(o),d=t(i),u=ot(d==null?void 0:d.className,n==null?void 0:n.className,s,o==null?void 0:o.className,r==null?void 0:r.className),f=R({},d==null?void 0:d.style,n==null?void 0:n.style,o==null?void 0:o.style,r==null?void 0:r.style),w=R({},d,n,c,l);return u.length>0&&(w.className=u),Object.keys(f).length>0&&(w.style=f),{props:w,internalRef:d.ref}}const pw=["elementType","externalSlotProps","ownerState","skipResolvingSlotProps"];function ww(e){var t;const{elementType:n,externalSlotProps:r,ownerState:o,skipResolvingSlotProps:s=!1}=e,i=ye(e,pw),l=s?{}:dw(r,o),{props:c,internalRef:d}=uw(R({},i,{externalSlotProps:l})),u=yt(d,l==null?void 0:l.ref,(t=e.additionalProps)==null?void 0:t.ref);return dn(n,R({},c,{ref:u}),o)}const mi="base";function fw(e){return`${mi}--${e}`}function mw(e,t){return`${mi}-${e}-${t}`}function hi(e,t){const n=ai[t];return n?fw(n):mw(e,t)}function hw(e,t){const n={};return t.forEach(r=>{n[r]=hi(e,r)}),n}function gw(e){return typeof e=="function"?e():e}const Qn=$.forwardRef(function(t,n){const{children:r,container:o,disablePortal:s=!1}=t,[i,l]=$.useState(null),c=yt($.isValidElement(r)?r.ref:null,n);if(Lt(()=>{s||l(gw(o)||document.body)},[o,s]),Lt(()=>{if(i&&!s)return Jn(n,i),()=>{Jn(n,null)}},[n,i,s]),s){if($.isValidElement(r)){const d={ref:c};return $.cloneElement(r,d)}return a.jsx($.Fragment,{children:r})}return a.jsx($.Fragment,{children:i&&Tl.createPortal(r,i)})});process.env.NODE_ENV!=="production"&&(Qn.propTypes={children:p.node,container:p.oneOfType([vn,p.func]),disablePortal:p.bool});process.env.NODE_ENV!=="production"&&(Qn["propTypes"]=yd(Qn.propTypes));var je="top",Ve="bottom",ze="right",Te="left",Io="auto",Mn=[je,Ve,ze,Te],Ft="start",yn="end",bw="clippingParents",gi="viewport",on="popper",vw="reference",Aa=Mn.reduce(function(e,t){return e.concat([t+"-"+Ft,t+"-"+yn])},[]),bi=[].concat(Mn,[Io]).reduce(function(e,t){return e.concat([t,t+"-"+Ft,t+"-"+yn])},[]),xw="beforeRead",yw="read",Nw="afterRead",kw="beforeMain",Sw="main",Ew="afterMain",jw="beforeWrite",Tw="write",Cw="afterWrite",Rw=[xw,yw,Nw,kw,Sw,Ew,jw,Tw,Cw];function We(e){return e?(e.nodeName||"").toLowerCase():null}function Me(e){if(e==null)return window;if(e.toString()!=="[object Window]"){var t=e.ownerDocument;return t&&t.defaultView||window}return e}function kt(e){var t=Me(e).Element;return e instanceof t||e instanceof Element}function Be(e){var t=Me(e).HTMLElement;return e instanceof t||e instanceof HTMLElement}function Mo(e){if(typeof ShadowRoot>"u")return!1;var t=Me(e).ShadowRoot;return e instanceof t||e instanceof ShadowRoot}function Ow(e){var t=e.state;Object.keys(t.elements).forEach(function(n){var r=t.styles[n]||{},o=t.attributes[n]||{},s=t.elements[n];!Be(s)||!We(s)||(Object.assign(s.style,r),Object.keys(o).forEach(function(i){var l=o[i];l===!1?s.removeAttribute(i):s.setAttribute(i,l===!0?"":l)}))})}function _w(e){var t=e.state,n={popper:{position:t.options.strategy,left:"0",top:"0",margin:"0"},arrow:{position:"absolute"},reference:{}};return Object.assign(t.elements.popper.style,n.popper),t.styles=n,t.elements.arrow&&Object.assign(t.elements.arrow.style,n.arrow),function(){Object.keys(t.elements).forEach(function(r){var o=t.elements[r],s=t.attributes[r]||{},i=Object.keys(t.styles.hasOwnProperty(r)?t.styles[r]:n[r]),l=i.reduce(function(c,d){return c[d]="",c},{});!Be(o)||!We(o)||(Object.assign(o.style,l),Object.keys(s).forEach(function(c){o.removeAttribute(c)}))})}}const Pw={name:"applyStyles",enabled:!0,phase:"write",fn:Ow,effect:_w,requires:["computeStyles"]};function He(e){return e.split("-")[0]}var ht=Math.max,er=Math.min,Gt=Math.round;function Qr(){var e=navigator.userAgentData;return e!=null&&e.brands&&Array.isArray(e.brands)?e.brands.map(function(t){return t.brand+"/"+t.version}).join(" "):navigator.userAgent}function vi(){return!/^((?!chrome|android).)*safari/i.test(Qr())}function Ut(e,t,n){t===void 0&&(t=!1),n===void 0&&(n=!1);var r=e.getBoundingClientRect(),o=1,s=1;t&&Be(e)&&(o=e.offsetWidth>0&&Gt(r.width)/e.offsetWidth||1,s=e.offsetHeight>0&&Gt(r.height)/e.offsetHeight||1);var i=kt(e)?Me(e):window,l=i.visualViewport,c=!vi()&&n,d=(r.left+(c&&l?l.offsetLeft:0))/o,u=(r.top+(c&&l?l.offsetTop:0))/s,f=r.width/o,w=r.height/s;return{width:f,height:w,top:u,right:d+f,bottom:u+w,left:d,x:d,y:u}}function $o(e){var t=Ut(e),n=e.offsetWidth,r=e.offsetHeight;return Math.abs(t.width-n)<=1&&(n=t.width),Math.abs(t.height-r)<=1&&(r=t.height),{x:e.offsetLeft,y:e.offsetTop,width:n,height:r}}function xi(e,t){var n=t.getRootNode&&t.getRootNode();if(e.contains(t))return!0;if(n&&Mo(n)){var r=t;do{if(r&&e.isSameNode(r))return!0;r=r.parentNode||r.host}while(r)}return!1}function tt(e){return Me(e).getComputedStyle(e)}function Iw(e){return["table","td","th"].indexOf(We(e))>=0}function it(e){return((kt(e)?e.ownerDocument:e.document)||window.document).documentElement}function yr(e){return We(e)==="html"?e:e.assignedSlot||e.parentNode||(Mo(e)?e.host:null)||it(e)}function Ba(e){return!Be(e)||tt(e).position==="fixed"?null:e.offsetParent}function Mw(e){var t=/firefox/i.test(Qr()),n=/Trident/i.test(Qr());if(n&&Be(e)){var r=tt(e);if(r.position==="fixed")return null}var o=yr(e);for(Mo(o)&&(o=o.host);Be(o)&&["html","body"].indexOf(We(o))<0;){var s=tt(o);if(s.transform!=="none"||s.perspective!=="none"||s.contain==="paint"||["transform","perspective"].indexOf(s.willChange)!==-1||t&&s.willChange==="filter"||t&&s.filter&&s.filter!=="none")return o;o=o.parentNode}return null}function $n(e){for(var t=Me(e),n=Ba(e);n&&Iw(n)&&tt(n).position==="static";)n=Ba(n);return n&&(We(n)==="html"||We(n)==="body"&&tt(n).position==="static")?t:n||Mw(e)||t}function Do(e){return["top","bottom"].indexOf(e)>=0?"x":"y"}function mn(e,t,n){return ht(e,er(t,n))}function $w(e,t,n){var r=mn(e,t,n);return r>n?n:r}function yi(){return{top:0,right:0,bottom:0,left:0}}function Ni(e){return Object.assign({},yi(),e)}function ki(e,t){return t.reduce(function(n,r){return n[r]=e,n},{})}var Dw=function(t,n){return t=typeof t=="function"?t(Object.assign({},n.rects,{placement:n.placement})):t,Ni(typeof t!="number"?t:ki(t,Mn))};function Aw(e){var t,n=e.state,r=e.name,o=e.options,s=n.elements.arrow,i=n.modifiersData.popperOffsets,l=He(n.placement),c=Do(l),d=[Te,ze].indexOf(l)>=0,u=d?"height":"width";if(!(!s||!i)){var f=Dw(o.padding,n),w=$o(s),b=c==="y"?je:Te,x=c==="y"?Ve:ze,m=n.rects.reference[u]+n.rects.reference[c]-i[c]-n.rects.popper[u],h=i[c]-n.rects.reference[c],E=$n(s),I=E?c==="y"?E.clientHeight||0:E.clientWidth||0:0,C=m/2-h/2,S=f[b],v=I-w[u]-f[x],_=I/2-w[u]/2+C,V=mn(S,_,v),U=c;n.modifiersData[r]=(t={},t[U]=V,t.centerOffset=V-_,t)}}function Bw(e){var t=e.state,n=e.options,r=n.element,o=r===void 0?"[data-popper-arrow]":r;o!=null&&(typeof o=="string"&&(o=t.elements.popper.querySelector(o),!o)||xi(t.elements.popper,o)&&(t.elements.arrow=o))}const Vw={name:"arrow",enabled:!0,phase:"main",fn:Aw,effect:Bw,requires:["popperOffsets"],requiresIfExists:["preventOverflow"]};function qt(e){return e.split("-")[1]}var zw={top:"auto",right:"auto",bottom:"auto",left:"auto"};function Lw(e,t){var n=e.x,r=e.y,o=t.devicePixelRatio||1;return{x:Gt(n*o)/o||0,y:Gt(r*o)/o||0}}function Va(e){var t,n=e.popper,r=e.popperRect,o=e.placement,s=e.variation,i=e.offsets,l=e.position,c=e.gpuAcceleration,d=e.adaptive,u=e.roundOffsets,f=e.isFixed,w=i.x,b=w===void 0?0:w,x=i.y,m=x===void 0?0:x,h=typeof u=="function"?u({x:b,y:m}):{x:b,y:m};b=h.x,m=h.y;var E=i.hasOwnProperty("x"),I=i.hasOwnProperty("y"),C=Te,S=je,v=window;if(d){var _=$n(n),V="clientHeight",U="clientWidth";if(_===Me(n)&&(_=it(n),tt(_).position!=="static"&&l==="absolute"&&(V="scrollHeight",U="scrollWidth")),_=_,o===je||(o===Te||o===ze)&&s===yn){S=Ve;var j=f&&_===v&&v.visualViewport?v.visualViewport.height:_[V];m-=j-r.height,m*=c?1:-1}if(o===Te||(o===je||o===Ve)&&s===yn){C=ze;var O=f&&_===v&&v.visualViewport?v.visualViewport.width:_[U];b-=O-r.width,b*=c?1:-1}}var k=Object.assign({position:l},d&&zw),D=u===!0?Lw({x:b,y:m},Me(n)):{x:b,y:m};if(b=D.x,m=D.y,c){var M;return Object.assign({},k,(M={},M[S]=I?"0":"",M[C]=E?"0":"",M.transform=(v.devicePixelRatio||1)<=1?"translate("+b+"px, "+m+"px)":"translate3d("+b+"px, "+m+"px, 0)",M))}return Object.assign({},k,(t={},t[S]=I?m+"px":"",t[C]=E?b+"px":"",t.transform="",t))}function Fw(e){var t=e.state,n=e.options,r=n.gpuAcceleration,o=r===void 0?!0:r,s=n.adaptive,i=s===void 0?!0:s,l=n.roundOffsets,c=l===void 0?!0:l,d={placement:He(t.placement),variation:qt(t.placement),popper:t.elements.popper,popperRect:t.rects.popper,gpuAcceleration:o,isFixed:t.options.strategy==="fixed"};t.modifiersData.popperOffsets!=null&&(t.styles.popper=Object.assign({},t.styles.popper,Va(Object.assign({},d,{offsets:t.modifiersData.popperOffsets,position:t.options.strategy,adaptive:i,roundOffsets:c})))),t.modifiersData.arrow!=null&&(t.styles.arrow=Object.assign({},t.styles.arrow,Va(Object.assign({},d,{offsets:t.modifiersData.arrow,position:"absolute",adaptive:!1,roundOffsets:c})))),t.attributes.popper=Object.assign({},t.attributes.popper,{"data-popper-placement":t.placement})}const Gw={name:"computeStyles",enabled:!0,phase:"beforeWrite",fn:Fw,data:{}};var Fn={passive:!0};function Uw(e){var t=e.state,n=e.instance,r=e.options,o=r.scroll,s=o===void 0?!0:o,i=r.resize,l=i===void 0?!0:i,c=Me(t.elements.popper),d=[].concat(t.scrollParents.reference,t.scrollParents.popper);return s&&d.forEach(function(u){u.addEventListener("scroll",n.update,Fn)}),l&&c.addEventListener("resize",n.update,Fn),function(){s&&d.forEach(function(u){u.removeEventListener("scroll",n.update,Fn)}),l&&c.removeEventListener("resize",n.update,Fn)}}const qw={name:"eventListeners",enabled:!0,phase:"write",fn:function(){},effect:Uw,data:{}};var Hw={left:"right",right:"left",bottom:"top",top:"bottom"};function Yn(e){return e.replace(/left|right|bottom|top/g,function(t){return Hw[t]})}var Yw={start:"end",end:"start"};function za(e){return e.replace(/start|end/g,function(t){return Yw[t]})}function Ao(e){var t=Me(e),n=t.pageXOffset,r=t.pageYOffset;return{scrollLeft:n,scrollTop:r}}function Bo(e){return Ut(it(e)).left+Ao(e).scrollLeft}function Xw(e,t){var n=Me(e),r=it(e),o=n.visualViewport,s=r.clientWidth,i=r.clientHeight,l=0,c=0;if(o){s=o.width,i=o.height;var d=vi();(d||!d&&t==="fixed")&&(l=o.offsetLeft,c=o.offsetTop)}return{width:s,height:i,x:l+Bo(e),y:c}}function Ww(e){var t,n=it(e),r=Ao(e),o=(t=e.ownerDocument)==null?void 0:t.body,s=ht(n.scrollWidth,n.clientWidth,o?o.scrollWidth:0,o?o.clientWidth:0),i=ht(n.scrollHeight,n.clientHeight,o?o.scrollHeight:0,o?o.clientHeight:0),l=-r.scrollLeft+Bo(e),c=-r.scrollTop;return tt(o||n).direction==="rtl"&&(l+=ht(n.clientWidth,o?o.clientWidth:0)-s),{width:s,height:i,x:l,y:c}}function Vo(e){var t=tt(e),n=t.overflow,r=t.overflowX,o=t.overflowY;return/auto|scroll|overlay|hidden/.test(n+o+r)}function Si(e){return["html","body","#document"].indexOf(We(e))>=0?e.ownerDocument.body:Be(e)&&Vo(e)?e:Si(yr(e))}function hn(e,t){var n;t===void 0&&(t=[]);var r=Si(e),o=r===((n=e.ownerDocument)==null?void 0:n.body),s=Me(r),i=o?[s].concat(s.visualViewport||[],Vo(r)?r:[]):r,l=t.concat(i);return o?l:l.concat(hn(yr(i)))}function eo(e){return Object.assign({},e,{left:e.x,top:e.y,right:e.x+e.width,bottom:e.y+e.height})}function Kw(e,t){var n=Ut(e,!1,t==="fixed");return n.top=n.top+e.clientTop,n.left=n.left+e.clientLeft,n.bottom=n.top+e.clientHeight,n.right=n.left+e.clientWidth,n.width=e.clientWidth,n.height=e.clientHeight,n.x=n.left,n.y=n.top,n}function La(e,t,n){return t===gi?eo(Xw(e,n)):kt(t)?Kw(t,n):eo(Ww(it(e)))}function Jw(e){var t=hn(yr(e)),n=["absolute","fixed"].indexOf(tt(e).position)>=0,r=n&&Be(e)?$n(e):e;return kt(r)?t.filter(function(o){return kt(o)&&xi(o,r)&&We(o)!=="body"}):[]}function Zw(e,t,n,r){var o=t==="clippingParents"?Jw(e):[].concat(t),s=[].concat(o,[n]),i=s[0],l=s.reduce(function(c,d){var u=La(e,d,r);return c.top=ht(u.top,c.top),c.right=er(u.right,c.right),c.bottom=er(u.bottom,c.bottom),c.left=ht(u.left,c.left),c},La(e,i,r));return l.width=l.right-l.left,l.height=l.bottom-l.top,l.x=l.left,l.y=l.top,l}function Ei(e){var t=e.reference,n=e.element,r=e.placement,o=r?He(r):null,s=r?qt(r):null,i=t.x+t.width/2-n.width/2,l=t.y+t.height/2-n.height/2,c;switch(o){case je:c={x:i,y:t.y-n.height};break;case Ve:c={x:i,y:t.y+t.height};break;case ze:c={x:t.x+t.width,y:l};break;case Te:c={x:t.x-n.width,y:l};break;default:c={x:t.x,y:t.y}}var d=o?Do(o):null;if(d!=null){var u=d==="y"?"height":"width";switch(s){case Ft:c[d]=c[d]-(t[u]/2-n[u]/2);break;case yn:c[d]=c[d]+(t[u]/2-n[u]/2);break}}return c}function Nn(e,t){t===void 0&&(t={});var n=t,r=n.placement,o=r===void 0?e.placement:r,s=n.strategy,i=s===void 0?e.strategy:s,l=n.boundary,c=l===void 0?bw:l,d=n.rootBoundary,u=d===void 0?gi:d,f=n.elementContext,w=f===void 0?on:f,b=n.altBoundary,x=b===void 0?!1:b,m=n.padding,h=m===void 0?0:m,E=Ni(typeof h!="number"?h:ki(h,Mn)),I=w===on?vw:on,C=e.rects.popper,S=e.elements[x?I:w],v=Zw(kt(S)?S:S.contextElement||it(e.elements.popper),c,u,i),_=Ut(e.elements.reference),V=Ei({reference:_,element:C,strategy:"absolute",placement:o}),U=eo(Object.assign({},C,V)),j=w===on?U:_,O={top:v.top-j.top+E.top,bottom:j.bottom-v.bottom+E.bottom,left:v.left-j.left+E.left,right:j.right-v.right+E.right},k=e.modifiersData.offset;if(w===on&&k){var D=k[o];Object.keys(O).forEach(function(M){var J=[ze,Ve].indexOf(M)>=0?1:-1,X=[je,Ve].indexOf(M)>=0?"y":"x";O[M]+=D[X]*J})}return O}function Qw(e,t){t===void 0&&(t={});var n=t,r=n.placement,o=n.boundary,s=n.rootBoundary,i=n.padding,l=n.flipVariations,c=n.allowedAutoPlacements,d=c===void 0?bi:c,u=qt(r),f=u?l?Aa:Aa.filter(function(x){return qt(x)===u}):Mn,w=f.filter(function(x){return d.indexOf(x)>=0});w.length===0&&(w=f);var b=w.reduce(function(x,m){return x[m]=Nn(e,{placement:m,boundary:o,rootBoundary:s,padding:i})[He(m)],x},{});return Object.keys(b).sort(function(x,m){return b[x]-b[m]})}function ef(e){if(He(e)===Io)return[];var t=Yn(e);return[za(e),t,za(t)]}function tf(e){var t=e.state,n=e.options,r=e.name;if(!t.modifiersData[r]._skip){for(var o=n.mainAxis,s=o===void 0?!0:o,i=n.altAxis,l=i===void 0?!0:i,c=n.fallbackPlacements,d=n.padding,u=n.boundary,f=n.rootBoundary,w=n.altBoundary,b=n.flipVariations,x=b===void 0?!0:b,m=n.allowedAutoPlacements,h=t.options.placement,E=He(h),I=E===h,C=c||(I||!x?[Yn(h)]:ef(h)),S=[h].concat(C).reduce(function(B,Y){return B.concat(He(Y)===Io?Qw(t,{placement:Y,boundary:u,rootBoundary:f,padding:d,flipVariations:x,allowedAutoPlacements:m}):Y)},[]),v=t.rects.reference,_=t.rects.popper,V=new Map,U=!0,j=S[0],O=0;O=0,X=J?"width":"height",F=Nn(t,{placement:k,boundary:u,rootBoundary:f,altBoundary:w,padding:d}),te=J?M?ze:Te:M?Ve:je;v[X]>_[X]&&(te=Yn(te));var se=Yn(te),oe=[];if(s&&oe.push(F[D]<=0),l&&oe.push(F[te]<=0,F[se]<=0),oe.every(function(B){return B})){j=k,U=!1;break}V.set(k,oe)}if(U)for(var y=x?3:1,T=function(Y){var q=S.find(function(H){var G=V.get(H);if(G)return G.slice(0,Y).every(function(K){return K})});if(q)return j=q,"break"},z=y;z>0;z--){var L=T(z);if(L==="break")break}t.placement!==j&&(t.modifiersData[r]._skip=!0,t.placement=j,t.reset=!0)}}const nf={name:"flip",enabled:!0,phase:"main",fn:tf,requiresIfExists:["offset"],data:{_skip:!1}};function Fa(e,t,n){return n===void 0&&(n={x:0,y:0}),{top:e.top-t.height-n.y,right:e.right-t.width+n.x,bottom:e.bottom-t.height+n.y,left:e.left-t.width-n.x}}function Ga(e){return[je,ze,Ve,Te].some(function(t){return e[t]>=0})}function rf(e){var t=e.state,n=e.name,r=t.rects.reference,o=t.rects.popper,s=t.modifiersData.preventOverflow,i=Nn(t,{elementContext:"reference"}),l=Nn(t,{altBoundary:!0}),c=Fa(i,r),d=Fa(l,o,s),u=Ga(c),f=Ga(d);t.modifiersData[n]={referenceClippingOffsets:c,popperEscapeOffsets:d,isReferenceHidden:u,hasPopperEscaped:f},t.attributes.popper=Object.assign({},t.attributes.popper,{"data-popper-reference-hidden":u,"data-popper-escaped":f})}const of={name:"hide",enabled:!0,phase:"main",requiresIfExists:["preventOverflow"],fn:rf};function af(e,t,n){var r=He(e),o=[Te,je].indexOf(r)>=0?-1:1,s=typeof n=="function"?n(Object.assign({},t,{placement:e})):n,i=s[0],l=s[1];return i=i||0,l=(l||0)*o,[Te,ze].indexOf(r)>=0?{x:l,y:i}:{x:i,y:l}}function sf(e){var t=e.state,n=e.options,r=e.name,o=n.offset,s=o===void 0?[0,0]:o,i=bi.reduce(function(u,f){return u[f]=af(f,t.rects,s),u},{}),l=i[t.placement],c=l.x,d=l.y;t.modifiersData.popperOffsets!=null&&(t.modifiersData.popperOffsets.x+=c,t.modifiersData.popperOffsets.y+=d),t.modifiersData[r]=i}const lf={name:"offset",enabled:!0,phase:"main",requires:["popperOffsets"],fn:sf};function cf(e){var t=e.state,n=e.name;t.modifiersData[n]=Ei({reference:t.rects.reference,element:t.rects.popper,strategy:"absolute",placement:t.placement})}const df={name:"popperOffsets",enabled:!0,phase:"read",fn:cf,data:{}};function uf(e){return e==="x"?"y":"x"}function pf(e){var t=e.state,n=e.options,r=e.name,o=n.mainAxis,s=o===void 0?!0:o,i=n.altAxis,l=i===void 0?!1:i,c=n.boundary,d=n.rootBoundary,u=n.altBoundary,f=n.padding,w=n.tether,b=w===void 0?!0:w,x=n.tetherOffset,m=x===void 0?0:x,h=Nn(t,{boundary:c,rootBoundary:d,padding:f,altBoundary:u}),E=He(t.placement),I=qt(t.placement),C=!I,S=Do(E),v=uf(S),_=t.modifiersData.popperOffsets,V=t.rects.reference,U=t.rects.popper,j=typeof m=="function"?m(Object.assign({},t.rects,{placement:t.placement})):m,O=typeof j=="number"?{mainAxis:j,altAxis:j}:Object.assign({mainAxis:0,altAxis:0},j),k=t.modifiersData.offset?t.modifiersData.offset[t.placement]:null,D={x:0,y:0};if(_){if(s){var M,J=S==="y"?je:Te,X=S==="y"?Ve:ze,F=S==="y"?"height":"width",te=_[S],se=te+h[J],oe=te-h[X],y=b?-U[F]/2:0,T=I===Ft?V[F]:U[F],z=I===Ft?-U[F]:-V[F],L=t.elements.arrow,B=b&&L?$o(L):{width:0,height:0},Y=t.modifiersData["arrow#persistent"]?t.modifiersData["arrow#persistent"].padding:yi(),q=Y[J],H=Y[X],G=mn(0,V[F],B[F]),K=C?V[F]/2-y-G-q-O.mainAxis:T-G-q-O.mainAxis,Z=C?-V[F]/2+y+G+H+O.mainAxis:z+G+H+O.mainAxis,ue=t.elements.arrow&&$n(t.elements.arrow),P=ue?S==="y"?ue.clientTop||0:ue.clientLeft||0:0,xe=(M=k==null?void 0:k[S])!=null?M:0,A=te+K-xe-P,ve=te+Z-xe,Fe=mn(b?er(se,A):se,te,b?ht(oe,ve):oe);_[S]=Fe,D[S]=Fe-te}if(l){var lt,Se=S==="x"?je:Te,Dn=S==="x"?Ve:ze,Ge=_[v],Et=v==="y"?"height":"width",ct=Ge+h[Se],jt=Ge-h[Dn],Tt=[je,Te].indexOf(E)!==-1,Ct=(lt=k==null?void 0:k[v])!=null?lt:0,dt=Tt?ct:Ge-V[Et]-U[Et]-Ct+O.altAxis,Kt=Tt?Ge+V[Et]+U[Et]-Ct-O.altAxis:jt,An=b&&Tt?$w(dt,Ge,Kt):mn(b?dt:ct,Ge,b?Kt:jt);_[v]=An,D[v]=An-Ge}t.modifiersData[r]=D}}const wf={name:"preventOverflow",enabled:!0,phase:"main",fn:pf,requiresIfExists:["offset"]};function ff(e){return{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}}function mf(e){return e===Me(e)||!Be(e)?Ao(e):ff(e)}function hf(e){var t=e.getBoundingClientRect(),n=Gt(t.width)/e.offsetWidth||1,r=Gt(t.height)/e.offsetHeight||1;return n!==1||r!==1}function gf(e,t,n){n===void 0&&(n=!1);var r=Be(t),o=Be(t)&&hf(t),s=it(t),i=Ut(e,o,n),l={scrollLeft:0,scrollTop:0},c={x:0,y:0};return(r||!r&&!n)&&((We(t)!=="body"||Vo(s))&&(l=mf(t)),Be(t)?(c=Ut(t,!0),c.x+=t.clientLeft,c.y+=t.clientTop):s&&(c.x=Bo(s))),{x:i.left+l.scrollLeft-c.x,y:i.top+l.scrollTop-c.y,width:i.width,height:i.height}}function bf(e){var t=new Map,n=new Set,r=[];e.forEach(function(s){t.set(s.name,s)});function o(s){n.add(s.name);var i=[].concat(s.requires||[],s.requiresIfExists||[]);i.forEach(function(l){if(!n.has(l)){var c=t.get(l);c&&o(c)}}),r.push(s)}return e.forEach(function(s){n.has(s.name)||o(s)}),r}function vf(e){var t=bf(e);return Rw.reduce(function(n,r){return n.concat(t.filter(function(o){return o.phase===r}))},[])}function xf(e){var t;return function(){return t||(t=new Promise(function(n){Promise.resolve().then(function(){t=void 0,n(e())})})),t}}function yf(e){var t=e.reduce(function(n,r){var o=n[r.name];return n[r.name]=o?Object.assign({},o,r,{options:Object.assign({},o.options,r.options),data:Object.assign({},o.data,r.data)}):r,n},{});return Object.keys(t).map(function(n){return t[n]})}var Ua={placement:"bottom",modifiers:[],strategy:"absolute"};function qa(){for(var e=arguments.length,t=new Array(e),n=0;nNo({root:["root"]},lw(Ef)),_f={},Pf=$.forwardRef(function(t,n){var r;const{anchorEl:o,children:s,direction:i,disablePortal:l,modifiers:c,open:d,placement:u,popperOptions:f,popperRef:w,slotProps:b={},slots:x={},TransitionProps:m}=t,h=ye(t,jf),E=$.useRef(null),I=yt(E,n),C=$.useRef(null),S=yt(C,w),v=$.useRef(S);Lt(()=>{v.current=S},[S]),$.useImperativeHandle(w,()=>C.current,[]);const _=Cf(u,i),[V,U]=$.useState(_),[j,O]=$.useState(tr(o));$.useEffect(()=>{C.current&&C.current.forceUpdate()}),$.useEffect(()=>{o&&O(tr(o))},[o]),Lt(()=>{if(!j||!d)return;const X=se=>{U(se.placement)};if(process.env.NODE_ENV!=="production"&&j&&Nr(j)&&j.nodeType===1){const se=j.getBoundingClientRect();process.env.NODE_ENV!=="test"&&se.top===0&&se.left===0&&se.right===0&&se.bottom===0&&console.warn(["MUI: The `anchorEl` prop provided to the component is invalid.","The anchor element should be part of the document layout.","Make sure the element is present in the document or that it's not display none."].join(` +`))}let F=[{name:"preventOverflow",options:{altBoundary:l}},{name:"flip",options:{altBoundary:l}},{name:"onUpdate",enabled:!0,phase:"afterWrite",fn:({state:se})=>{X(se)}}];c!=null&&(F=F.concat(c)),f&&f.modifiers!=null&&(F=F.concat(f.modifiers));const te=Sf(j,E.current,R({placement:_},f,{modifiers:F}));return v.current(te),()=>{te.destroy(),v.current(null)}},[j,l,c,d,f,_]);const k={placement:V};m!==null&&(k.TransitionProps=m);const D=Of(),M=(r=x.root)!=null?r:"div",J=ww({elementType:M,externalSlotProps:b.root,externalForwardedProps:h,additionalProps:{role:"tooltip",ref:I},ownerState:t,className:D.root});return a.jsx(M,R({},J,{children:typeof s=="function"?s(k):s}))}),Ti=$.forwardRef(function(t,n){const{anchorEl:r,children:o,container:s,direction:i="ltr",disablePortal:l=!1,keepMounted:c=!1,modifiers:d,open:u,placement:f="bottom",popperOptions:w=_f,popperRef:b,style:x,transition:m=!1,slotProps:h={},slots:E={}}=t,I=ye(t,Tf),[C,S]=$.useState(!0),v=()=>{S(!1)},_=()=>{S(!0)};if(!c&&!u&&(!m||C))return null;let V;if(s)V=s;else if(r){const O=tr(r);V=O&&Nr(O)?Kn(O).body:Kn(null).body}const U=!u&&c&&(!m||C)?"none":void 0,j=m?{in:u,onEnter:v,onExited:_}:void 0;return a.jsx(Qn,{disablePortal:l,container:V,children:a.jsx(Pf,R({anchorEl:r,direction:i,disablePortal:l,modifiers:d,ref:n,open:m?!C:u,placement:f,popperOptions:w,popperRef:b,slotProps:h,slots:E},I,{style:R({position:"fixed",top:0,left:0,display:U},x),TransitionProps:j,children:o}))})});process.env.NODE_ENV!=="production"&&(Ti.propTypes={anchorEl:xo(p.oneOfType([vn,p.object,p.func]),e=>{if(e.open){const t=tr(e.anchorEl);if(t&&Nr(t)&&t.nodeType===1){const n=t.getBoundingClientRect();if(process.env.NODE_ENV!=="test"&&n.top===0&&n.left===0&&n.right===0&&n.bottom===0)return new Error(["MUI: The `anchorEl` prop provided to the component is invalid.","The anchor element should be part of the document layout.","Make sure the element is present in the document or that it's not display none."].join(` +`))}else if(!t||typeof t.getBoundingClientRect!="function"||Rf(t)&&t.contextElement!=null&&t.contextElement.nodeType!==1)return new Error(["MUI: The `anchorEl` prop provided to the component is invalid.","It should be an HTML element instance or a virtualElement ","(https://popper.js.org/docs/v2/virtual-elements/)."].join(` +`))}return null}),children:p.oneOfType([p.node,p.func]),container:p.oneOfType([vn,p.func]),direction:p.oneOf(["ltr","rtl"]),disablePortal:p.bool,keepMounted:p.bool,modifiers:p.arrayOf(p.shape({data:p.object,effect:p.func,enabled:p.bool,fn:p.func,name:p.any,options:p.object,phase:p.oneOf(["afterMain","afterRead","afterWrite","beforeMain","beforeRead","beforeWrite","main","read","write"]),requires:p.arrayOf(p.string),requiresIfExists:p.arrayOf(p.string)})),open:p.bool.isRequired,placement:p.oneOf(["auto-end","auto-start","auto","bottom-end","bottom-start","bottom","left-end","left-start","left","right-end","right-start","right","top-end","top-start","top"]),popperOptions:p.shape({modifiers:p.array,onFirstUpdate:p.func,placement:p.oneOf(["auto-end","auto-start","auto","bottom-end","bottom-start","bottom","left-end","left-start","left","right-end","right-start","right","top-end","top-start","top"]),strategy:p.oneOf(["absolute","fixed"])}),popperRef:Qs,slotProps:p.shape({root:p.oneOfType([p.func,p.object])}),slots:p.shape({root:p.elementType}),transition:p.bool});function Ci(){const e=ui(Ro);return process.env.NODE_ENV!=="production"&&$.useDebugValue(e),e[Oo]||e}function to(e,t){return to=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,o){return r.__proto__=o,r},to(e,t)}function If(e,t){e.prototype=Object.create(t.prototype),e.prototype.constructor=e,to(e,t)}const Ha={disabled:!1};var Mf=process.env.NODE_ENV!=="production"?p.oneOfType([p.number,p.shape({enter:p.number,exit:p.number,appear:p.number}).isRequired]):null;process.env.NODE_ENV!=="production"&&p.oneOfType([p.string,p.shape({enter:p.string,exit:p.string,active:p.string}),p.shape({enter:p.string,enterDone:p.string,enterActive:p.string,exit:p.string,exitDone:p.string,exitActive:p.string})]);const Ri=g.createContext(null);var $f=function(t){return t.scrollTop},un="unmounted",wt="exited",ft="entering",$t="entered",no="exiting",nt=function(e){If(t,e);function t(r,o){var s;s=e.call(this,r,o)||this;var i=o,l=i&&!i.isMounting?r.enter:r.appear,c;return s.appearStatus=null,r.in?l?(c=wt,s.appearStatus=ft):c=$t:r.unmountOnExit||r.mountOnEnter?c=un:c=wt,s.state={status:c},s.nextCallback=null,s}t.getDerivedStateFromProps=function(o,s){var i=o.in;return i&&s.status===un?{status:wt}:null};var n=t.prototype;return n.componentDidMount=function(){this.updateStatus(!0,this.appearStatus)},n.componentDidUpdate=function(o){var s=null;if(o!==this.props){var i=this.state.status;this.props.in?i!==ft&&i!==$t&&(s=ft):(i===ft||i===$t)&&(s=no)}this.updateStatus(!1,s)},n.componentWillUnmount=function(){this.cancelNextCallback()},n.getTimeouts=function(){var o=this.props.timeout,s,i,l;return s=i=l=o,o!=null&&typeof o!="number"&&(s=o.exit,i=o.enter,l=o.appear!==void 0?o.appear:i),{exit:s,enter:i,appear:l}},n.updateStatus=function(o,s){if(o===void 0&&(o=!1),s!==null)if(this.cancelNextCallback(),s===ft){if(this.props.unmountOnExit||this.props.mountOnEnter){var i=this.props.nodeRef?this.props.nodeRef.current:sn.findDOMNode(this);i&&$f(i)}this.performEnter(o)}else this.performExit();else this.props.unmountOnExit&&this.state.status===wt&&this.setState({status:un})},n.performEnter=function(o){var s=this,i=this.props.enter,l=this.context?this.context.isMounting:o,c=this.props.nodeRef?[l]:[sn.findDOMNode(this),l],d=c[0],u=c[1],f=this.getTimeouts(),w=l?f.appear:f.enter;if(!o&&!i||Ha.disabled){this.safeSetState({status:$t},function(){s.props.onEntered(d)});return}this.props.onEnter(d,u),this.safeSetState({status:ft},function(){s.props.onEntering(d,u),s.onTransitionEnd(w,function(){s.safeSetState({status:$t},function(){s.props.onEntered(d,u)})})})},n.performExit=function(){var o=this,s=this.props.exit,i=this.getTimeouts(),l=this.props.nodeRef?void 0:sn.findDOMNode(this);if(!s||Ha.disabled){this.safeSetState({status:wt},function(){o.props.onExited(l)});return}this.props.onExit(l),this.safeSetState({status:no},function(){o.props.onExiting(l),o.onTransitionEnd(i.exit,function(){o.safeSetState({status:wt},function(){o.props.onExited(l)})})})},n.cancelNextCallback=function(){this.nextCallback!==null&&(this.nextCallback.cancel(),this.nextCallback=null)},n.safeSetState=function(o,s){s=this.setNextCallback(s),this.setState(o,s)},n.setNextCallback=function(o){var s=this,i=!0;return this.nextCallback=function(l){i&&(i=!1,s.nextCallback=null,o(l))},this.nextCallback.cancel=function(){i=!1},this.nextCallback},n.onTransitionEnd=function(o,s){this.setNextCallback(s);var i=this.props.nodeRef?this.props.nodeRef.current:sn.findDOMNode(this),l=o==null&&!this.props.addEndListener;if(!i||l){setTimeout(this.nextCallback,0);return}if(this.props.addEndListener){var c=this.props.nodeRef?[this.nextCallback]:[i,this.nextCallback],d=c[0],u=c[1];this.props.addEndListener(d,u)}o!=null&&setTimeout(this.nextCallback,o)},n.render=function(){var o=this.state.status;if(o===un)return null;var s=this.props,i=s.children;s.in,s.mountOnEnter,s.unmountOnExit,s.appear,s.enter,s.exit,s.timeout,s.addEndListener,s.onEnter,s.onEntering,s.onEntered,s.onExit,s.onExiting,s.onExited,s.nodeRef;var l=ye(s,["children","in","mountOnEnter","unmountOnExit","appear","enter","exit","timeout","addEndListener","onEnter","onEntering","onEntered","onExit","onExiting","onExited","nodeRef"]);return g.createElement(Ri.Provider,{value:null},typeof i=="function"?i(o,l):g.cloneElement(g.Children.only(i),l))},t}(g.Component);nt.contextType=Ri;nt.propTypes=process.env.NODE_ENV!=="production"?{nodeRef:p.shape({current:typeof Element>"u"?p.any:function(e,t,n,r,o,s){var i=e[t];return p.instanceOf(i&&"ownerDocument"in i?i.ownerDocument.defaultView.Element:Element)(e,t,n,r,o,s)}}),children:p.oneOfType([p.func.isRequired,p.element.isRequired]).isRequired,in:p.bool,mountOnEnter:p.bool,unmountOnExit:p.bool,appear:p.bool,enter:p.bool,exit:p.bool,timeout:function(t){var n=Mf;t.addEndListener||(n=n.isRequired);for(var r=arguments.length,o=new Array(r>1?r-1:0),s=1;se.scrollTop;function Ya(e,t){var n,r;const{timeout:o,easing:s,style:i={}}=e;return{duration:(n=i.transitionDuration)!=null?n:typeof o=="number"?o:o[t.mode]||0,easing:(r=i.transitionTimingFunction)!=null?r:typeof s=="object"?s[t.mode]:s,delay:i.transitionDelay}}const Bf=["addEndListener","appear","children","easing","in","onEnter","onEntered","onEntering","onExit","onExited","onExiting","style","timeout","TransitionComponent"];function ro(e){return`scale(${e}, ${e**2})`}const Vf={entering:{opacity:1,transform:ro(1)},entered:{opacity:1,transform:"none"}},zr=typeof navigator<"u"&&/^((?!chrome|android).)*(safari|mobile)/i.test(navigator.userAgent)&&/(os |version\/)15(.|_)4/i.test(navigator.userAgent),zo=$.forwardRef(function(t,n){const{addEndListener:r,appear:o=!0,children:s,easing:i,in:l,onEnter:c,onEntered:d,onEntering:u,onExit:f,onExited:w,onExiting:b,style:x,timeout:m="auto",TransitionComponent:h=Df}=t,E=ye(t,Bf),I=cn(),C=$.useRef(),S=Ci(),v=$.useRef(null),_=yt(v,s.ref,n),V=X=>F=>{if(X){const te=v.current;F===void 0?X(te):X(te,F)}},U=V(u),j=V((X,F)=>{Af(X);const{duration:te,delay:se,easing:oe}=Ya({style:x,timeout:m,easing:i},{mode:"enter"});let y;m==="auto"?(y=S.transitions.getAutoHeightDuration(X.clientHeight),C.current=y):y=te,X.style.transition=[S.transitions.create("opacity",{duration:y,delay:se}),S.transitions.create("transform",{duration:zr?y:y*.666,delay:se,easing:oe})].join(","),c&&c(X,F)}),O=V(d),k=V(b),D=V(X=>{const{duration:F,delay:te,easing:se}=Ya({style:x,timeout:m,easing:i},{mode:"exit"});let oe;m==="auto"?(oe=S.transitions.getAutoHeightDuration(X.clientHeight),C.current=oe):oe=F,X.style.transition=[S.transitions.create("opacity",{duration:oe,delay:te}),S.transitions.create("transform",{duration:zr?oe:oe*.666,delay:zr?te:te||oe*.333,easing:se})].join(","),X.style.opacity=0,X.style.transform=ro(.75),f&&f(X)}),M=V(w),J=X=>{m==="auto"&&I.start(C.current||0,X),r&&r(v.current,X)};return a.jsx(h,R({appear:o,in:l,nodeRef:v,onEnter:j,onEntered:O,onEntering:U,onExit:D,onExited:M,onExiting:k,addEndListener:J,timeout:m==="auto"?null:m},E,{children:(X,F)=>$.cloneElement(s,R({style:R({opacity:0,transform:ro(.75),visibility:X==="exited"&&!l?"hidden":void 0},Vf[X],x,s.props.style),ref:_},F))}))});process.env.NODE_ENV!=="production"&&(zo.propTypes={addEndListener:p.func,appear:p.bool,children:Js.isRequired,easing:p.oneOfType([p.shape({enter:p.string,exit:p.string}),p.string]),in:p.bool,onEnter:p.func,onEntered:p.func,onEntering:p.func,onExit:p.func,onExited:p.func,onExiting:p.func,style:p.object,timeout:p.oneOfType([p.oneOf(["auto"]),p.number,p.shape({appear:p.number,enter:p.number,exit:p.number})])});zo.muiSupportAuto=!0;const Xa=zo,zf=["anchorEl","component","components","componentsProps","container","disablePortal","keepMounted","modifiers","open","placement","popperOptions","popperRef","transition","slots","slotProps"],Lf=In(Ti,{name:"MuiPopper",slot:"Root",overridesResolver:(e,t)=>t.root})({}),Oi=$.forwardRef(function(t,n){var r;const o=di(),s=_o({props:t,name:"MuiPopper"}),{anchorEl:i,component:l,components:c,componentsProps:d,container:u,disablePortal:f,keepMounted:w,modifiers:b,open:x,placement:m,popperOptions:h,popperRef:E,transition:I,slots:C,slotProps:S}=s,v=ye(s,zf),_=(r=C==null?void 0:C.root)!=null?r:c==null?void 0:c.Root,V=R({anchorEl:i,container:u,disablePortal:f,keepMounted:w,modifiers:b,open:x,placement:m,popperOptions:h,popperRef:E,transition:I},v);return a.jsx(Lf,R({as:l,direction:o==null?void 0:o.direction,slots:{root:_},slotProps:S??d},V,{ref:n}))});process.env.NODE_ENV!=="production"&&(Oi.propTypes={anchorEl:p.oneOfType([vn,p.object,p.func]),children:p.oneOfType([p.node,p.func]),component:p.elementType,components:p.shape({Root:p.elementType}),componentsProps:p.shape({root:p.oneOfType([p.func,p.object])}),container:p.oneOfType([vn,p.func]),disablePortal:p.bool,keepMounted:p.bool,modifiers:p.arrayOf(p.shape({data:p.object,effect:p.func,enabled:p.bool,fn:p.func,name:p.any,options:p.object,phase:p.oneOf(["afterMain","afterRead","afterWrite","beforeMain","beforeRead","beforeWrite","main","read","write"]),requires:p.arrayOf(p.string),requiresIfExists:p.arrayOf(p.string)})),open:p.bool.isRequired,placement:p.oneOf(["auto-end","auto-start","auto","bottom-end","bottom-start","bottom","left-end","left-start","left","right-end","right-start","right","top-end","top-start","top"]),popperOptions:p.shape({modifiers:p.array,onFirstUpdate:p.func,placement:p.oneOf(["auto-end","auto-start","auto","bottom-end","bottom-start","bottom","left-end","left-start","left","right-end","right-start","right","top-end","top-start","top"]),strategy:p.oneOf(["absolute","fixed"])}),popperRef:Qs,slotProps:p.shape({root:p.oneOfType([p.func,p.object])}),slots:p.shape({root:p.elementType}),sx:p.oneOfType([p.arrayOf(p.oneOfType([p.func,p.object,p.bool])),p.func,p.object]),transition:p.bool});const _i=Oi;function Ff(e){return ur("MuiTooltip",e)}const Gf=si("MuiTooltip",["popper","popperInteractive","popperArrow","popperClose","tooltip","tooltipArrow","touch","tooltipPlacementLeft","tooltipPlacementRight","tooltipPlacementTop","tooltipPlacementBottom","arrow"]),at=Gf,Uf=["arrow","children","classes","components","componentsProps","describeChild","disableFocusListener","disableHoverListener","disableInteractive","disableTouchListener","enterDelay","enterNextDelay","enterTouchDelay","followCursor","id","leaveDelay","leaveTouchDelay","onClose","onOpen","open","placement","PopperComponent","PopperProps","slotProps","slots","title","TransitionComponent","TransitionProps"];function qf(e){return Math.round(e*1e5)/1e5}const Hf=e=>{const{classes:t,disableInteractive:n,arrow:r,touch:o,placement:s}=e,i={popper:["popper",!n&&"popperInteractive",r&&"popperArrow"],tooltip:["tooltip",r&&"tooltipArrow",o&&"touch",`tooltipPlacement${Xe(s.split("-")[0])}`],arrow:["arrow"]};return No(i,Ff,t)},Yf=In(_i,{name:"MuiTooltip",slot:"Popper",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.popper,!n.disableInteractive&&t.popperInteractive,n.arrow&&t.popperArrow,!n.open&&t.popperClose]}})(({theme:e,ownerState:t,open:n})=>R({zIndex:(e.vars||e).zIndex.tooltip,pointerEvents:"none"},!t.disableInteractive&&{pointerEvents:"auto"},!n&&{pointerEvents:"none"},t.arrow&&{[`&[data-popper-placement*="bottom"] .${at.arrow}`]:{top:0,marginTop:"-0.71em","&::before":{transformOrigin:"0 100%"}},[`&[data-popper-placement*="top"] .${at.arrow}`]:{bottom:0,marginBottom:"-0.71em","&::before":{transformOrigin:"100% 0"}},[`&[data-popper-placement*="right"] .${at.arrow}`]:R({},t.isRtl?{right:0,marginRight:"-0.71em"}:{left:0,marginLeft:"-0.71em"},{height:"1em",width:"0.71em","&::before":{transformOrigin:"100% 100%"}}),[`&[data-popper-placement*="left"] .${at.arrow}`]:R({},t.isRtl?{left:0,marginLeft:"-0.71em"}:{right:0,marginRight:"-0.71em"},{height:"1em",width:"0.71em","&::before":{transformOrigin:"0 0"}})})),Xf=In("div",{name:"MuiTooltip",slot:"Tooltip",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.tooltip,n.touch&&t.touch,n.arrow&&t.tooltipArrow,t[`tooltipPlacement${Xe(n.placement.split("-")[0])}`]]}})(({theme:e,ownerState:t})=>R({backgroundColor:e.vars?e.vars.palette.Tooltip.bg:pi(e.palette.grey[700],.92),borderRadius:(e.vars||e).shape.borderRadius,color:(e.vars||e).palette.common.white,fontFamily:e.typography.fontFamily,padding:"4px 8px",fontSize:e.typography.pxToRem(11),maxWidth:300,margin:2,wordWrap:"break-word",fontWeight:e.typography.fontWeightMedium},t.arrow&&{position:"relative",margin:0},t.touch&&{padding:"8px 16px",fontSize:e.typography.pxToRem(14),lineHeight:`${qf(16/14)}em`,fontWeight:e.typography.fontWeightRegular},{[`.${at.popper}[data-popper-placement*="left"] &`]:R({transformOrigin:"right center"},t.isRtl?R({marginLeft:"14px"},t.touch&&{marginLeft:"24px"}):R({marginRight:"14px"},t.touch&&{marginRight:"24px"})),[`.${at.popper}[data-popper-placement*="right"] &`]:R({transformOrigin:"left center"},t.isRtl?R({marginRight:"14px"},t.touch&&{marginRight:"24px"}):R({marginLeft:"14px"},t.touch&&{marginLeft:"24px"})),[`.${at.popper}[data-popper-placement*="top"] &`]:R({transformOrigin:"center bottom",marginBottom:"14px"},t.touch&&{marginBottom:"24px"}),[`.${at.popper}[data-popper-placement*="bottom"] &`]:R({transformOrigin:"center top",marginTop:"14px"},t.touch&&{marginTop:"24px"})})),Wf=In("span",{name:"MuiTooltip",slot:"Arrow",overridesResolver:(e,t)=>t.arrow})(({theme:e})=>({overflow:"hidden",position:"absolute",width:"1em",height:"0.71em",boxSizing:"border-box",color:e.vars?e.vars.palette.Tooltip.bg:pi(e.palette.grey[700],.9),"&::before":{content:'""',margin:"auto",display:"block",width:"100%",height:"100%",backgroundColor:"currentColor",transform:"rotate(45deg)"}}));let Gn=!1;const Wa=new On;let an={x:0,y:0};function Un(e,t){return n=>{t&&t(n),e(n)}}const Pi=$.forwardRef(function(t,n){var r,o,s,i,l,c,d,u,f,w,b,x,m,h,E,I,C,S,v;const _=_o({props:t,name:"MuiTooltip"}),{arrow:V=!1,children:U,components:j={},componentsProps:O={},describeChild:k=!1,disableFocusListener:D=!1,disableHoverListener:M=!1,disableInteractive:J=!1,disableTouchListener:X=!1,enterDelay:F=100,enterNextDelay:te=0,enterTouchDelay:se=700,followCursor:oe=!1,id:y,leaveDelay:T=0,leaveTouchDelay:z=1500,onClose:L,onOpen:B,open:Y,placement:q="bottom",PopperComponent:H,PopperProps:G={},slotProps:K={},slots:Z={},title:ue,TransitionComponent:P=Xa,TransitionProps:xe}=_,A=ye(_,Uf),ve=$.isValidElement(U)?U:a.jsx("span",{children:U}),Fe=Ci(),lt=Fe.direction==="rtl",[Se,Dn]=$.useState(),[Ge,Et]=$.useState(null),ct=$.useRef(!1),jt=J||oe,Tt=cn(),Ct=cn(),dt=cn(),Kt=cn(),[An,Fo]=ti({controlled:Y,default:!1,name:"Tooltip",state:"open"});let Ke=An;if(process.env.NODE_ENV!=="production"){const{current:Q}=$.useRef(Y!==void 0);$.useEffect(()=>{Se&&Se.disabled&&!Q&&ue!==""&&Se.tagName.toLowerCase()==="button"&&console.error(["MUI: You are providing a disabled `button` child to the Tooltip component.","A disabled element does not fire events.","Tooltip needs to listen to the child element's events to display the title.","","Add a simple wrapper element, such as a `span`."].join(` +`))},[ue,Se,Q])}const kr=ei(y),Jt=$.useRef(),Bn=Jr(()=>{Jt.current!==void 0&&(document.body.style.WebkitUserSelect=Jt.current,Jt.current=void 0),Kt.clear()});$.useEffect(()=>Bn,[Bn]);const Go=Q=>{Wa.clear(),Gn=!0,Fo(!0),B&&!Ke&&B(Q)},Vn=Jr(Q=>{Wa.start(800+T,()=>{Gn=!1}),Fo(!1),L&&Ke&&L(Q),Tt.start(Fe.transitions.duration.shortest,()=>{ct.current=!1})}),Sr=Q=>{ct.current&&Q.type!=="touchstart"||(Se&&Se.removeAttribute("title"),Ct.clear(),dt.clear(),F||Gn&&te?Ct.start(Gn?te:F,()=>{Go(Q)}):Go(Q))},Uo=Q=>{Ct.clear(),dt.start(T,()=>{Vn(Q)})},{isFocusVisibleRef:qo,onBlur:el,onFocus:tl,ref:nl}=ni(),[,Ho]=$.useState(!1),Yo=Q=>{el(Q),qo.current===!1&&(Ho(!1),Uo(Q))},Xo=Q=>{Se||Dn(Q.currentTarget),tl(Q),qo.current===!0&&(Ho(!0),Sr(Q))},Wo=Q=>{ct.current=!0;const Oe=ve.props;Oe.onTouchStart&&Oe.onTouchStart(Q)},Ko=Sr,Jo=Uo,rl=Q=>{Wo(Q),dt.clear(),Tt.clear(),Bn(),Jt.current=document.body.style.WebkitUserSelect,document.body.style.WebkitUserSelect="none",Kt.start(se,()=>{document.body.style.WebkitUserSelect=Jt.current,Sr(Q)})},ol=Q=>{ve.props.onTouchEnd&&ve.props.onTouchEnd(Q),Bn(),dt.start(z,()=>{Vn(Q)})};$.useEffect(()=>{if(!Ke)return;function Q(Oe){(Oe.key==="Escape"||Oe.key==="Esc")&&Vn(Oe)}return document.addEventListener("keydown",Q),()=>{document.removeEventListener("keydown",Q)}},[Vn,Ke]);const al=yt(ve.ref,nl,Dn,n);!ue&&ue!==0&&(Ke=!1);const Er=$.useRef(),sl=Q=>{const Oe=ve.props;Oe.onMouseMove&&Oe.onMouseMove(Q),an={x:Q.clientX,y:Q.clientY},Er.current&&Er.current.update()},Zt={},jr=typeof ue=="string";k?(Zt.title=!Ke&&jr&&!M?ue:null,Zt["aria-describedby"]=Ke?kr:null):(Zt["aria-label"]=jr?ue:null,Zt["aria-labelledby"]=Ke&&!jr?kr:null);const $e=R({},Zt,A,ve.props,{className:ot(A.className,ve.props.className),onTouchStart:Wo,ref:al},oe?{onMouseMove:sl}:{});process.env.NODE_ENV!=="production"&&($e["data-mui-internal-clone-element"]=!0,$.useEffect(()=>{Se&&!Se.getAttribute("data-mui-internal-clone-element")&&console.error(["MUI: The `children` component of the Tooltip is not forwarding its props correctly.","Please make sure that props are spread on the same element that the ref is applied to."].join(` +`))},[Se]));const Qt={};X||($e.onTouchStart=rl,$e.onTouchEnd=ol),M||($e.onMouseOver=Un(Ko,$e.onMouseOver),$e.onMouseLeave=Un(Jo,$e.onMouseLeave),jt||(Qt.onMouseOver=Ko,Qt.onMouseLeave=Jo)),D||($e.onFocus=Un(Xo,$e.onFocus),$e.onBlur=Un(Yo,$e.onBlur),jt||(Qt.onFocus=Xo,Qt.onBlur=Yo)),process.env.NODE_ENV!=="production"&&ve.props.title&&console.error(["MUI: You have provided a `title` prop to the child of .",`Remove this title prop \`${ve.props.title}\` or the Tooltip component.`].join(` +`));const il=$.useMemo(()=>{var Q;let Oe=[{name:"arrow",enabled:!!Ge,options:{element:Ge,padding:4}}];return(Q=G.popperOptions)!=null&&Q.modifiers&&(Oe=Oe.concat(G.popperOptions.modifiers)),R({},G.popperOptions,{modifiers:Oe})},[Ge,G]),en=R({},_,{isRtl:lt,arrow:V,disableInteractive:jt,placement:q,PopperComponentProp:H,touch:ct.current}),Tr=Hf(en),Zo=(r=(o=Z.popper)!=null?o:j.Popper)!=null?r:Yf,Qo=(s=(i=(l=Z.transition)!=null?l:j.Transition)!=null?i:P)!=null?s:Xa,ea=(c=(d=Z.tooltip)!=null?d:j.Tooltip)!=null?c:Xf,ta=(u=(f=Z.arrow)!=null?f:j.Arrow)!=null?u:Wf,ll=dn(Zo,R({},G,(w=K.popper)!=null?w:O.popper,{className:ot(Tr.popper,G==null?void 0:G.className,(b=(x=K.popper)!=null?x:O.popper)==null?void 0:b.className)}),en),cl=dn(Qo,R({},xe,(m=K.transition)!=null?m:O.transition),en),dl=dn(ea,R({},(h=K.tooltip)!=null?h:O.tooltip,{className:ot(Tr.tooltip,(E=(I=K.tooltip)!=null?I:O.tooltip)==null?void 0:E.className)}),en),ul=dn(ta,R({},(C=K.arrow)!=null?C:O.arrow,{className:ot(Tr.arrow,(S=(v=K.arrow)!=null?v:O.arrow)==null?void 0:S.className)}),en);return a.jsxs($.Fragment,{children:[$.cloneElement(ve,$e),a.jsx(Zo,R({as:H??_i,placement:q,anchorEl:oe?{getBoundingClientRect:()=>({top:an.y,left:an.x,right:an.x,bottom:an.y,width:0,height:0})}:Se,popperRef:Er,open:Se?Ke:!1,id:kr,transition:!0},Qt,ll,{popperOptions:il,children:({TransitionProps:Q})=>a.jsx(Qo,R({timeout:Fe.transitions.duration.shorter},Q,cl,{children:a.jsxs(ea,R({},dl,{children:[ue,V?a.jsx(ta,R({},ul,{ref:Et})):null]}))}))}))]})});process.env.NODE_ENV!=="production"&&(Pi.propTypes={arrow:p.bool,children:Js.isRequired,classes:p.object,className:p.string,components:p.shape({Arrow:p.elementType,Popper:p.elementType,Tooltip:p.elementType,Transition:p.elementType}),componentsProps:p.shape({arrow:p.object,popper:p.object,tooltip:p.object,transition:p.object}),describeChild:p.bool,disableFocusListener:p.bool,disableHoverListener:p.bool,disableInteractive:p.bool,disableTouchListener:p.bool,enterDelay:p.number,enterNextDelay:p.number,enterTouchDelay:p.number,followCursor:p.bool,id:p.string,leaveDelay:p.number,leaveTouchDelay:p.number,onClose:p.func,onOpen:p.func,open:p.bool,placement:p.oneOf(["bottom-end","bottom-start","bottom","left-end","left-start","left","right-end","right-start","right","top-end","top-start","top"]),PopperComponent:p.elementType,PopperProps:p.object,slotProps:p.shape({arrow:p.object,popper:p.object,tooltip:p.object,transition:p.object}),slots:p.shape({arrow:p.elementType,popper:p.elementType,tooltip:p.elementType,transition:p.elementType}),sx:p.oneOfType([p.arrayOf(p.oneOfType([p.func,p.object,p.bool])),p.func,p.object]),title:p.node,TransitionComponent:p.elementType,TransitionProps:p.object});const Kf=Pi;function Ka(e,t,n){return e?a.jsx(Ie.ListItemIcon,{className:`papi-menu-icon-${n?"leading":"trailing"}`,children:a.jsx("img",{src:e,alt:`${n?"Leading":"Trailing"} icon for ${t}`})}):void 0}function Lo(e){const{onClick:t,label:n,tooltip:r,allowForLeadingIcons:o=!0,iconPathBefore:s=void 0,iconPathAfter:i=void 0,hasAutoFocus:l=!1,className:c,isDisabled:d=!1,isDense:u=!0,isSubMenuParent:f=!1,hasDisabledGutters:w=!1,hasDivider:b=!1,focusVisibleClassName:x,id:m,children:h}=e,E=a.jsx(Ie.MenuItem,{sx:{lineHeight:.8},autoFocus:l,className:c,disabled:d,dense:u,disableGutters:w,divider:b,focusVisibleClassName:x,onClick:t,id:m,children:n?a.jsxs(a.Fragment,{children:[Ka(s,n,!0),a.jsx(Ie.ListItemText,{primary:n,inset:!s&&o}),f?a.jsx(Ie.ListItemIcon,{className:"papi-menu-icon-trailing",children:a.jsx(fi,{})}):Ka(i,n,!1)]}):h});return r?a.jsx(Kf,{title:r,placement:"right",children:a.jsx("div",{children:E})}):E}function Ii(e){return Object.entries(e.groups).map(([n,r])=>({id:n,group:r}))}function Jf(e){const[t,n]=g.useState(void 0),{parentMenuItem:r,parentItemProps:o,menuDefinition:s}=e,i=d=>{n(d.currentTarget)},l=()=>{n(void 0)},c=()=>{let d=Ii(s).filter(u=>"menuItem"in u.group);if(!(r!=null&&r.id))throw new Error("A valid parent menu item is required for submenus.");return d=d.filter(u=>"menuItem"in u.group&&u.group.menuItem===r.id),a.jsx(Mi,{...e,includedGroups:d})};return a.jsxs(a.Fragment,{children:[a.jsx(Lo,{onClick:i,...o,isSubMenuParent:!0}),a.jsx(Ie.Menu,{anchorEl:t,open:!!t,onClose:l,anchorOrigin:{vertical:"top",horizontal:"right"},transformOrigin:{vertical:"top",horizontal:"left"},children:c()},r.id)]})}const Zf=(e,t)=>t.filter(o=>o.group===e).sort((o,s)=>(o.order||0)-(s.order||0));function Mi(e){const{menuDefinition:t,onClick:n,commandHandler:r,includedGroups:o}=e,{items:s,allowForLeadingIcons:i}=g.useMemo(()=>{const u=o&&o.length>0?o:Ii(t).filter(x=>!("menuItem"in x.group)),f=Object.values(u).sort((x,m)=>(x.group.order||0)-(m.group.order||0)),w=[];f.forEach(x=>{Zf(x.id,t.items).forEach(m=>w.push({item:m,isLastItemInGroup:!1})),w.length>0&&(w[w.length-1].isLastItemInGroup=!0)}),w.length>0&&(w[w.length-1].isLastItemInGroup=!1);const b=w.some(x=>"iconPathBefore"in x.item&&x.item.iconPathBefore);return{items:w,allowForLeadingIcons:b}},[o,t]),l=({item:u,isLastItemInGroup:f})=>({className:"papi-menu-item",label:u.label,tooltip:u.tooltip,iconPathBefore:"iconPathBefore"in u?u.iconPathBefore:void 0,iconPathAfter:"iconPathAfter"in u?u.iconPathAfter:void 0,hasDivider:f,allowForLeadingIcons:i}),[c]=s;if(!c)return a.jsx("div",{});const d=c.item.group;return a.jsx("div",{role:"menu","aria-label":d,children:s.map((u,f)=>{const{item:w}=u,b=l(u);if("command"in w){const x=w.group+f;return a.jsx(Lo,{onClick:m=>{n==null||n(m),r(w)},...b},x)}return a.jsx(Jf,{parentMenuItem:w,parentItemProps:b,...e},d+w.id)})},d)}function Qf(e){const{menuDefinition:t,columnId:n}=e;let s=Object.entries(t.groups).map(([i,l])=>({id:i,group:l})).filter(i=>"column"in i.group);return n&&"columns"in t&&t.columns[n]&&(s=s.filter(i=>"column"in i.group&&i.group.column===n)),a.jsx(Mi,{...e,includedGroups:s})}function em({commandHandler:e,menuDefinition:t,id:n,metadata:r,onClick:o,className:s}){return a.jsxs(Ie.Grid,{id:n,item:!0,xs:"auto",role:"menu","aria-label":n,className:`papi-menu-column ${s??""}`,children:[a.jsx("h3",{"aria-label":r.label,className:`papi-menu-column-header ${s??""}`,children:r.label}),a.jsx(Ie.List,{id:n,dense:!0,className:s??"",children:a.jsx(Qf,{commandHandler:e,menuDefinition:t,columnId:n,onClick:o})})]})}function $i({commandHandler:e,className:t,multiColumnMenu:n,id:r}){const{columns:o}=n,s=g.useMemo(()=>{const i=new Map;return Object.getOwnPropertyNames(o).forEach(l=>{if(l==="isExtensible")return;const c=l,d=o[c];typeof d=="object"&&typeof d.order=="number"&&!Number.isNaN(d.order)?i.set(d.order,{id:c,metadata:d}):console.warn(`Property ${l} (${typeof d}) on menu ${r} is not a valid column and is being ignored. This might indicate data corruption`)}),Array.from(i.values()).sort((l,c)=>(l.metadata.order||0)-(c.metadata.order||0))},[o,r]);return a.jsx(Ie.Grid,{container:!0,spacing:0,className:`papi-multi-column-menu ${t??""}`,columns:s.length,role:"menu","aria-label":"GridMenu",id:r,children:s.map((i,l)=>a.jsx(em,{commandHandler:e,menuDefinition:n,...i,className:t},l))})}function tm(e){return{preserveValue:!0,...e}}const nr=(e,t,n={})=>{const r=g.useRef(t);r.current=t;const o=g.useRef(n);o.current=tm(o.current);const[s,i]=g.useState(()=>r.current),[l,c]=g.useState(!0);return g.useEffect(()=>{let d=!0;return c(!!e),(async()=>{if(e){const u=await e();d&&(i(()=>u),c(!1))}})(),()=>{d=!1,o.current.preserveValue||i(()=>r.current)}},[e]),[s,l]},nm=wi(a.jsx("path",{d:"M3 18h18v-2H3zm0-5h18v-2H3zm0-7v2h18V6z"}),"Menu");function Di({menuProvider:e,normalMenu:t,fullMenu:n,commandHandler:r,containerRef:o,className:s,ariaLabelPrefix:i,children:l}){const[c,d]=g.useState(!1),[u,f]=g.useState(!1),w=g.useCallback(()=>{c&&d(!1),f(!1)},[c]),b=g.useCallback(S=>{S.stopPropagation(),d(v=>{const _=!v;return _&&S.shiftKey?f(!0):_||f(!1),_})},[]),x=g.useCallback(S=>(w(),r(S)),[r,w]),[m,h]=g.useState({top:1,left:1});g.useEffect(()=>{if(c){const S=o==null?void 0:o.current;if(S){const v=S.getBoundingClientRect(),_=window.scrollY,V=window.scrollX,U=v.top+_+S.clientHeight,j=v.left+V;h({top:U,left:j})}}},[c,o]);const[E]=nr(g.useCallback(async()=>(e==null?void 0:e(!1))??t,[e,t,c]),t),[I]=nr(g.useCallback(async()=>(e==null?void 0:e(!0))??n??E,[e,n,E,c]),n??E),C=u&&I?I:E;return a.jsxs(a.Fragment,{children:[a.jsx(Ie.IconButton,{sx:{paddingTop:0,paddingBottom:0},edge:"start",className:`papi-menuButton ${s??""}`,color:"inherit","aria-label":`${i??""} menu button`,onClick:b,children:l??a.jsx(nm,{})}),a.jsx(Ie.Drawer,{className:`papi-menu-drawer ${s??""}`,anchor:"left",variant:"temporary",open:c,onClose:w,PaperProps:{className:"papi-menu-drawer-paper",style:{top:m.top,left:m.left}},children:C?a.jsx($i,{className:s,id:`${i??""} main menu`,commandHandler:x,multiColumnMenu:C}):void 0})]})}function rm({id:e,label:t,isDisabled:n=!1,tooltip:r,isTooltipSuppressed:o=!1,adjustMarginToAlignToEdge:s=!1,size:i="medium",className:l,onClick:c,children:d}){return a.jsx(Ie.IconButton,{id:e,disabled:n,edge:s,size:i,"aria-label":t,title:o?void 0:r??t,className:`papi-icon-button ${l??""}`,onClick:c,children:d})}const Wt=g.forwardRef(({className:e,...t},n)=>a.jsx(ee.LoaderCircle,{size:35,className:N("tw-animate-spin",e),...t,ref:n}));Wt.displayName="Spinner";function om({id:e,isDisabled:t=!1,hasError:n=!1,isFullWidth:r=!1,helperText:o,label:s,placeholder:i,isRequired:l=!1,className:c,defaultValue:d,value:u,onChange:f,onFocus:w,onBlur:b}){return a.jsxs("div",{className:N("tw-inline-grid tw-items-center tw-gap-1.5",{"tw-w-full":r}),children:[a.jsx(Ue,{htmlFor:e,className:N({"tw-text-red-600":n,"tw-hidden":!s}),children:`${s}${l?"*":""}`}),a.jsx(St,{id:e,disabled:t,placeholder:i,required:l,className:N(c,{"tw-border-red-600":n}),defaultValue:d,value:u,onChange:f,onFocus:w,onBlur:b}),a.jsx("p",{className:N({"tw-hidden":!o}),children:o})]})}function am({menuProvider:e,commandHandler:t,className:n,id:r,children:o}){const s=g.useRef(void 0);return a.jsx("div",{ref:s,style:{position:"relative"},children:a.jsx(Ie.AppBar,{position:"static",id:r,children:a.jsxs(Ie.Toolbar,{className:N("tw-bg-muted tw-text-muted-foreground",n),variant:"dense",children:[e?a.jsx(Di,{commandHandler:t,containerRef:s,menuProvider:e}):void 0,o?a.jsx("div",{className:"papi-toolbar-children",children:o}):void 0]})})})}const sm=kn.cva("tw-relative tw-w-full tw-rounded-lg tw-border tw-p-4 [&>svg~*]:tw-pl-7 [&>svg+div]:tw-translate-y-[-3px] [&>svg]:tw-absolute [&>svg]:tw-left-4 [&>svg]:tw-top-4 [&>svg]:tw-text-foreground",{variants:{variant:{default:"tw-bg-background tw-text-foreground",destructive:"tw-border-destructive/50 tw-text-destructive dark:tw-border-destructive [&>svg]:tw-text-destructive"}},defaultVariants:{variant:"default"}}),Ai=g.forwardRef(({className:e,variant:t,...n},r)=>a.jsx("div",{ref:r,role:"alert",className:N(sm({variant:t}),e),...n}));Ai.displayName="Alert";const Bi=g.forwardRef(({className:e,...t},n)=>a.jsxs("h5",{ref:n,className:N("tw-mb-1 tw-font-medium tw-leading-none tw-tracking-tight",e),...t,children:[t.children," "]}));Bi.displayName="AlertTitle";const Vi=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,className:N("tw-text-sm [&_p]:tw-leading-relaxed",e),...t}));Vi.displayName="AlertDescription";const zi=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,className:N("pr-twp tw-rounded-lg tw-border tw-bg-card tw-text-card-foreground tw-shadow-sm",e),...t}));zi.displayName="Card";const Li=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,className:N("pr-twp tw-flex tw-flex-col tw-space-y-1.5 tw-p-6",e),...t}));Li.displayName="CardHeader";const Fi=g.forwardRef(({className:e,...t},n)=>a.jsx("h3",{ref:n,className:N("pr-twp tw-text-2xl tw-font-semibold tw-leading-none tw-tracking-tight",e),...t,children:t.children}));Fi.displayName="CardTitle";const Gi=g.forwardRef(({className:e,...t},n)=>a.jsx("p",{ref:n,className:N("pr-twp tw-text-sm tw-text-muted-foreground",e),...t}));Gi.displayName="CardDescription";const Ui=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,className:N("pr-twp tw-p-6 tw-pt-0",e),...t}));Ui.displayName="CardContent";const qi=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,className:N("pr-twp tw-flex tw-items-center tw-p-6 tw-pt-0",e),...t}));qi.displayName="CardFooter";function im({...e}){return a.jsx(Za.Toaster,{className:"tw-toaster tw-group",toastOptions:{classNames:{toast:"group toast group-[.toaster]:bg-background group-[.toaster]:text-foreground group-[.toaster]:border-border group-[.toaster]:shadow-lg",description:"group-[.toast]:text-muted-foreground",actionButton:"group-[.toast]:bg-primary group-[.toast]:text-primary-foreground",cancelButton:"group-[.toast]:bg-muted group-[.toast]:text-muted-foreground"}},...e})}const Hi=g.forwardRef(({className:e,...t},n)=>a.jsxs(ln.Root,{ref:n,className:N("pr-twp tw-relative tw-flex tw-w-full tw-touch-none tw-select-none tw-items-center",e),...t,children:[a.jsx(ln.Track,{className:"tw-relative tw-h-2 tw-w-full tw-grow tw-overflow-hidden tw-rounded-full tw-bg-secondary",children:a.jsx(ln.Range,{className:"tw-absolute tw-h-full tw-bg-primary"})}),a.jsx(ln.Thumb,{className:"tw-block tw-h-5 tw-w-5 tw-rounded-full tw-border-2 tw-border-primary tw-bg-background tw-ring-offset-background tw-transition-colors focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50"})]}));Hi.displayName=ln.Root.displayName;const Yi=g.forwardRef(({className:e,...t},n)=>a.jsx(Ur.Root,{className:N("tw-peer pr-twp tw-inline-flex tw-h-6 tw-w-11 tw-shrink-0 tw-cursor-pointer tw-items-center tw-rounded-full tw-border-2 tw-border-transparent tw-transition-colors focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 focus-visible:tw-ring-offset-background disabled:tw-cursor-not-allowed disabled:tw-opacity-50 data-[state=checked]:tw-bg-primary data-[state=unchecked]:tw-bg-input",e),...t,ref:n,children:a.jsx(Ur.Thumb,{className:N("pr-twp tw-pointer-events-none tw-block tw-h-5 tw-w-5 tw-rounded-full tw-bg-background tw-shadow-lg tw-ring-0 tw-transition-transform data-[state=checked]:tw-translate-x-5 data-[state=unchecked]:tw-translate-x-0")})}));Yi.displayName=Ur.Root.displayName;const lm=Re.Root,Xi=g.forwardRef(({className:e,...t},n)=>a.jsx(Re.List,{ref:n,className:N("tw-inline-flex tw-h-10 tw-items-center tw-justify-center tw-rounded-md tw-bg-muted tw-p-1 tw-text-muted-foreground",e),...t}));Xi.displayName=Re.List.displayName;const Wi=g.forwardRef(({className:e,...t},n)=>a.jsx(Re.Trigger,{ref:n,className:N("tw-inline-flex tw-items-center tw-justify-center tw-whitespace-nowrap tw-rounded-sm tw-px-3 tw-py-1.5 tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-all hover:tw-text-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50 data-[state=active]:tw-bg-background data-[state=active]:tw-text-foreground data-[state=active]:tw-shadow-sm",e),...t}));Wi.displayName=Re.Trigger.displayName;const Ki=g.forwardRef(({className:e,...t},n)=>a.jsx(Re.Content,{ref:n,className:N("tw-mt-2 tw-ring-offset-background focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2",e),...t}));Ki.displayName=Re.Content.displayName;function cm({isInstalling:e,handleClick:t,buttonText:n,className:r,...o}){return a.jsx(fe,{className:N("tw-h-8 tw-rounded-md tw-text-white tw-transition tw-duration-300 tw-ease-in-out hover:tw-bg-blue-700",{"tw-cursor-not-allowed tw-bg-blue-700":e,"tw-bg-blue-600":!e,"tw-bg-white tw-text-blue-600 hover:tw-text-white":!n,"tw-w-20":n},r),onClick:t,...o,children:e?a.jsx(Wt,{size:15}):a.jsxs(a.Fragment,{children:[a.jsx(ee.Download,{size:25,className:N("tw-h-4 tw-w-4",{"tw-mr-1":n})}),n]})})}function dm({isEnabling:e,handleClick:t,className:n,...r}){return a.jsx(fe,{className:N("tw-h-8 tw-rounded-md tw-bg-blue-600 tw-px-4 tw-text-white tw-transition tw-duration-300 tw-ease-in-out hover:tw-bg-blue-700",{"tw-cursor-not-allowed tw-bg-blue-700":e},n),onClick:t,...r,children:e?a.jsxs(a.Fragment,{children:[a.jsx(Wt,{size:15,className:"tw-mr-1 tw-text-white"}),"Enabling..."]}):"Enable"})}function um({isDisabling:e,handleClick:t,className:n,...r}){return a.jsx(fe,{className:N("tw-h-8 tw-rounded-md tw-bg-gray-300 tw-text-black tw-transition tw-duration-300 tw-ease-in-out hover:tw-bg-gray-400",{"tw-cursor-not-allowed tw-bg-gray-400":e},n),onClick:t,...r,children:e?a.jsxs(a.Fragment,{children:[a.jsx(Wt,{size:15,className:"tw-mr-1 tw-text-black"}),"Disabling..."]}):"Disable"})}function pm({isUpdating:e,handleClick:t,className:n,...r}){return a.jsx(fe,{className:N("tw-h-8 tw-rounded-md tw-bg-blue-600 tw-px-4 tw-text-white tw-transition tw-duration-300 tw-ease-in-out hover:tw-bg-blue-700 hover:tw-text-white",{"tw-cursor-not-allowed tw-bg-blue-700":e},n),onClick:t,...r,children:e?a.jsxs(a.Fragment,{children:[a.jsx(Wt,{size:15,className:"tw-mr-1 tw-text-white"}),"Updating..."]}):"Update"})}function wm({id:e,markdown:t,className:n,anchorTarget:r}){const o=g.useMemo(()=>({overrides:{a:{props:{target:r}}}}),[r]);return a.jsx("div",{id:e,className:N("pr-twp tw-prose",n),children:a.jsx(jl,{options:o,children:t})})}const Ji=g.forwardRef((e,t)=>a.jsxs(fe,{ref:t,className:"tw-rounded-md tw-border tw-border-dashed tw-border-gray-400 tw-bg-white tw-px-4 tw-py-2 tw-text-black tw-transition tw-duration-300 tw-ease-in-out hover:tw-border-blue-600 hover:tw-bg-white hover:tw-text-blue-600",...e,children:[a.jsx(ee.Filter,{size:16,className:"tw-mr-2 tw-h-4 tw-w-4 tw-text-gray-700 hover:tw-text-blue-600"}),"Filter",a.jsx(ee.ChevronDown,{size:16,className:"tw-ml-2 tw-h-4 tw-w-4 tw-text-gray-700 hover:tw-text-blue-600"})]}));var Zi=(e=>(e[e.Check=0]="Check",e[e.Radio=1]="Radio",e))(Zi||{});function fm({id:e,groups:t}){return a.jsx("div",{id:e,children:a.jsxs(or,{children:[a.jsx(io,{asChild:!0,children:a.jsx(Ji,{})}),a.jsx(En,{children:t.map(n=>a.jsxs("div",{children:[a.jsx(Xt,{children:n.label}),a.jsx(ls,{children:n.items.map(r=>a.jsx("div",{children:r.itemType===0?a.jsx(ar,{onClick:r.onClick,children:r.label}):a.jsx(co,{onClick:r.onClick,value:r.label,children:r.label})},r.label))}),a.jsx(jn,{})]},n.label))})]})})}function mm({id:e,message:t}){return a.jsx("div",{id:e,className:"tw-mb-20 tw-mt-20 tw-flex tw-items-center tw-justify-center",children:a.jsx("div",{className:"tw-w-3/4 tw-rounded-lg tw-bg-gray-100 tw-p-8 tw-text-center",children:a.jsx("p",{className:"tw-text-lg tw-text-gray-800",children:t})})})}function hm({id:e,category:t,downloads:n,languages:r,moreInfoUrl:o}){const s=new W.NumberFormat("en",{notation:"compact",compactDisplay:"short"}).format(Object.values(n).reduce((l,c)=>l+c,0)),i=()=>{window.scrollTo(0,document.body.scrollHeight)};return a.jsxs("div",{id:e,className:"tw-flex tw-flex-wrap tw-items-start tw-space-x-4 tw-border-b tw-border-t tw-bg-white tw-pb-4 tw-pt-4",children:[a.jsxs("div",{className:"tw-flex tw-flex-col tw-items-center",children:[a.jsx("div",{className:"tw-flex tw-items-center tw-rounded-md tw-bg-gray-100 tw-px-2 tw-py-1",children:a.jsx("span",{className:"tw-text-xs tw-font-semibold tw-text-gray-700",children:t})}),a.jsx("span",{className:"tw-text-xs tw-text-gray-500",children:"CATEGORY"})]}),a.jsx("div",{className:"tw-mx-2 tw-h-10 tw-border-l tw-border-gray-300"}),a.jsxs("div",{className:"tw-flex tw-flex-col tw-items-center",children:[a.jsxs("div",{className:"tw-flex tw-items-center tw-rounded-md tw-bg-gray-100 tw-px-2 tw-py-1",children:[a.jsx(ee.User,{className:"tw-mr-1 tw-h-4 tw-w-4"}),a.jsx("span",{className:"tw-text-xs tw-font-semibold tw-text-gray-700",children:s})]}),a.jsx("span",{className:"tw-text-xs tw-text-gray-500",children:"USERS"})]}),a.jsx("div",{className:"tw-mx-2 tw-h-10 tw-border-l tw-border-gray-300"}),a.jsxs("div",{className:"tw-flex tw-flex-col tw-items-center",children:[a.jsx("div",{className:"tw-flex tw-items-center",children:r.slice(0,3).map(l=>a.jsx("span",{className:"tw-ml-1 tw-rounded-md tw-bg-gray-100 tw-px-2 tw-py-1 tw-text-xs tw-font-semibold tw-text-gray-700",children:l.toUpperCase()},l))}),r.length>3&&a.jsxs("button",{type:"button",onClick:()=>i(),className:"tw-text-xs tw-text-gray-500 tw-underline",children:["+",r.length-3," more languages"]})]}),a.jsx("div",{className:"tw-mx-2 tw-h-10 tw-border-l tw-border-gray-300"}),a.jsxs("div",{className:"tw-ml-auto tw-flex tw-flex-col tw-space-y-2",children:[a.jsxs("a",{href:o,target:"_blank",rel:"noreferrer",className:"tw-flex tw-items-center tw-text-xs tw-font-semibold tw-text-gray-500 tw-underline",children:["Website",a.jsx(ee.Link,{className:"tw-ml-1 tw-inline tw-h-4 tw-w-4"})]}),a.jsxs("a",{href:"https://example.com",target:"_blank",rel:"noreferrer",className:"tw-flex tw-items-center tw-text-xs tw-font-semibold tw-text-gray-500 tw-underline",children:["Support",a.jsx(ee.CircleHelp,{className:"tw-ml-1 tw-inline tw-h-4 tw-w-4"})]})]})]})}function Qi({id:e,versionHistory:t}){const[n,r]=g.useState(!1),o=new Date;function s(l){const c=new Date(l),d=new Date(o.getTime()-c.getTime()),u=d.getUTCFullYear()-1970,f=d.getUTCMonth(),w=d.getUTCDate()-1;let b="";return u>0?b=`${u.toString()} year${u===1?"":"s"} ago`:f>0?b=`${f.toString()} month${f===1?"":"s"} ago`:w===0?b="today":b=`${w.toString()} day${w===1?"":"s"} ago`,b}const i=Object.entries(t).sort((l,c)=>c[0].localeCompare(l[0]));return a.jsxs("div",{id:e,children:[a.jsx("h3",{className:"tw-text-md tw-font-semibold",children:"What`s New"}),a.jsx("ul",{className:"tw-list-disc tw-pl-5 tw-pr-4 tw-text-xs tw-text-gray-600",children:(n?i:i.slice(0,5)).map(l=>a.jsxs("div",{className:"tw-mt-3 tw-flex tw-justify-between",children:[a.jsx("div",{className:"tw-text-gray-600",children:a.jsx("li",{className:"tw-prose tw-text-xs",children:a.jsx("span",{children:l[1].description})})}),a.jsxs("div",{className:"tw-justify-end tw-text-right",children:[a.jsxs("div",{children:["Version ",l[0]]}),a.jsx("div",{children:s(l[1].date)})]})]},l[0]))}),i.length>5&&a.jsx("button",{type:"button",onClick:()=>r(!n),className:"tw-text-xs tw-text-gray-500 tw-underline",children:n?"Show Less Version History":"Show All Version History"})]})}function gm({id:e,publisherDisplayName:t,fileSize:n,locales:r,versionHistory:o}){const s=g.useMemo(()=>W.formatBytes(n),[n]),l=(c=>{const d=new Intl.DisplayNames(navigator.language,{type:"language"});return c.map(u=>d.of(u))})(r);return a.jsx("div",{id:e,className:"tw-border-t tw-pb-4 tw-pt-4",children:a.jsxs("div",{className:"tw-md:flex-row tw-md:space-x-8 tw-flex tw-flex-col tw-space-x-0",children:[a.jsx(Qi,{versionHistory:o}),a.jsx("div",{className:"tw-md:border-t-0 tw-md:border-l tw-md-h-auto tw-md-ml-8 tw-mt-4 tw-border-t tw-border-gray-300"}),a.jsxs("div",{className:"tw-md:mt-0 tw-mt-4 tw-flex-1 tw-space-y-3",children:[a.jsx("h2",{className:"tw-text-md tw-font-semibold",children:"Information"}),a.jsxs("div",{className:"tw-flex tw-items-start tw-justify-between tw-pr-4 tw-text-xs tw-text-gray-600",children:[a.jsxs("p",{className:"tw-flex tw-flex-col tw-justify-start",children:[a.jsx("span",{className:"tw-mb-2",children:"Publisher"}),a.jsx("span",{className:"tw-font-semibold",children:t}),a.jsx("span",{className:"tw-mb-2 tw-mt-4",children:"Size"}),a.jsx("span",{className:"tw-font-semibold",children:s})]}),a.jsx("div",{className:"tw-flex tw-w-3/4 tw-items-center tw-justify-between tw-text-xs tw-text-gray-600",children:a.jsxs("p",{className:"tw-flex tw-flex-col tw-justify-start",children:[a.jsx("span",{className:"tw-mb-2",children:"Languages"}),a.jsx("span",{className:"tw-font-semibold",children:l.join(", ")})]})})]})]})]})})}const bm=(e,t)=>{g.useEffect(()=>{if(!e)return()=>{};const n=e(t);return()=>{n()}},[e,t])},Lr=()=>!1,vm=(e,t)=>{const[n]=nr(g.useCallback(async()=>{if(!e)return Lr;const r=await Promise.resolve(e(t));return async()=>r()},[t,e]),Lr,{preserveValue:!1});g.useEffect(()=>()=>{n!==Lr&&n()},[n])};Object.defineProperty(exports,"sonner",{enumerable:!0,get:()=>Za.toast});exports.Alert=Ai;exports.AlertDescription=Vi;exports.AlertTitle=Bi;exports.BOOK_SELECTOR_STRING_KEYS=pc;exports.BookChapterControl=tc;exports.BookSelectionMode=ys;exports.BookSelector=wc;exports.Button=fe;exports.Card=zi;exports.CardContent=Ui;exports.CardDescription=Gi;exports.CardFooter=qi;exports.CardHeader=Li;exports.CardTitle=Fi;exports.ChapterRangeSelector=xs;exports.Checkbox=sr;exports.Checklist=sd;exports.ComboBox=Wn;exports.DataTable=Ts;exports.DisableButton=um;exports.DropdownMenu=or;exports.DropdownMenuCheckboxItem=ar;exports.DropdownMenuContent=En;exports.DropdownMenuGroup=ls;exports.DropdownMenuItem=lo;exports.DropdownMenuItemType=Zi;exports.DropdownMenuLabel=Xt;exports.DropdownMenuPortal=Fl;exports.DropdownMenuRadioGroup=Ul;exports.DropdownMenuRadioItem=co;exports.DropdownMenuSeparator=jn;exports.DropdownMenuShortcut=us;exports.DropdownMenuSub=Gl;exports.DropdownMenuSubContent=ds;exports.DropdownMenuSubTrigger=cs;exports.DropdownMenuTrigger=io;exports.EnableButton=dm;exports.FilterButton=Ji;exports.FilterDropdown=fm;exports.Footer=gm;exports.GridMenu=$i;exports.HamburgerMenuButton=Di;exports.INVENTORY_STRING_KEYS=Nc;exports.IconButton=rm;exports.Input=St;exports.InstallButton=cm;exports.Inventory=Ec;exports.Label=Ue;exports.MarkdownRenderer=wm;exports.MenuItem=Lo;exports.MoreInfo=hm;exports.NavigationContentSearch=jc;exports.NoExtensionsFound=mm;exports.RadioGroup=uo;exports.RadioGroupItem=Xn;exports.ScriptureResultsViewer=td;exports.ScrollGroupSelector=nd;exports.SearchBar=mo;exports.Select=At;exports.SelectContent=vt;exports.SelectGroup=Ns;exports.SelectItem=De;exports.SelectLabel=ks;exports.SelectScrollDownButton=wo;exports.SelectScrollUpButton=po;exports.SelectSeparator=Ss;exports.SelectTrigger=bt;exports.SelectValue=Bt;exports.Separator=lr;exports.SettingsList=rd;exports.SettingsListHeader=ad;exports.SettingsListItem=od;exports.SettingsSidebar=Gs;exports.SettingsSidebarContentSearch=Yc;exports.Slider=Hi;exports.Sonner=im;exports.Spinner=Wt;exports.Switch=Yi;exports.Table=Tn;exports.TableBody=Rn;exports.TableCaption=js;exports.TableCell=xt;exports.TableFooter=Es;exports.TableHead=Vt;exports.TableHeader=Cn;exports.TableRow=Ze;exports.Tabs=lm;exports.TabsContent=Ki;exports.TabsList=Xi;exports.TabsTrigger=Wi;exports.TextField=om;exports.ToggleGroup=fo;exports.ToggleGroupItem=wn;exports.Toolbar=am;exports.UpdateButton=pm;exports.VersionHistory=Qi;exports.VerticalTabs=ho;exports.VerticalTabsContent=bo;exports.VerticalTabsList=go;exports.VerticalTabsTrigger=Is;exports.buttonVariants=ps;exports.cn=N;exports.getBookNumFromId=Rs;exports.getLinesFromUSFM=Cs;exports.getNumberFromUSFM=qr;exports.getStatusForItem=Os;exports.inventoryCountColumn=xc;exports.inventoryItemColumn=bc;exports.inventoryStatusColumn=yc;exports.useEvent=bm;exports.useEventAsync=vm;exports.usePromise=nr;function xm(e,t="top"){if(!e||typeof document>"u")return;const n=document.head||document.querySelector("head"),r=n.querySelector(":first-child"),o=document.createElement("style");o.appendChild(document.createTextNode(e)),t==="top"&&r?n.insertBefore(o,r):n.appendChild(o)}xm(`*, ::before, ::after { --tw-border-spacing-x: 0; --tw-border-spacing-y: 0; --tw-translate-x: 0; @@ -1134,17 +1134,10 @@ video:where(.pr-twp,.pr-twp *) { .tw-inset-0 { inset: 0px; } -.tw-inset-x-0 { - left: 0px; - right: 0px; -} .tw-inset-y-0 { top: 0px; bottom: 0px; } -.tw-bottom-0 { - bottom: 0px; -} .tw-bottom-2 { bottom: 0.5rem; } @@ -1856,9 +1849,6 @@ video:where(.pr-twp,.pr-twp *) { .tw-border-l-2 { border-left-width: 2px; } -.tw-border-r { - border-right-width: 1px; -} .tw-border-r-0 { border-right-width: 0px; } @@ -2868,10 +2858,6 @@ video:where(.pr-twp,.pr-twp *) { background-color: hsl(var(--accent)); } -.data-\\[state\\=open\\]\\:tw-bg-secondary[data-state="open"] { - background-color: hsl(var(--secondary)); -} - .data-\\[state\\=selected\\]\\:tw-bg-muted[data-state="selected"] { background-color: hsl(var(--muted)); } @@ -2926,14 +2912,6 @@ video:where(.pr-twp,.pr-twp *) { box-shadow: var(--tw-ring-offset-shadow, 0 0 #0000), var(--tw-ring-shadow, 0 0 #0000), var(--tw-shadow); } -.data-\\[state\\=closed\\]\\:tw-duration-300[data-state="closed"] { - transition-duration: 300ms; -} - -.data-\\[state\\=open\\]\\:tw-duration-500[data-state="open"] { - transition-duration: 500ms; -} - .data-\\[state\\=open\\]\\:tw-animate-in[data-state="open"] { animation-name: enter; animation-duration: 150ms; @@ -2986,62 +2964,22 @@ video:where(.pr-twp,.pr-twp *) { --tw-enter-translate-y: 0.5rem; } -.data-\\[state\\=closed\\]\\:tw-slide-out-to-bottom[data-state="closed"] { - --tw-exit-translate-y: 100%; -} - -.data-\\[state\\=closed\\]\\:tw-slide-out-to-left[data-state="closed"] { - --tw-exit-translate-x: -100%; -} - .data-\\[state\\=closed\\]\\:tw-slide-out-to-left-1\\/2[data-state="closed"] { --tw-exit-translate-x: -50%; } -.data-\\[state\\=closed\\]\\:tw-slide-out-to-right[data-state="closed"] { - --tw-exit-translate-x: 100%; -} - -.data-\\[state\\=closed\\]\\:tw-slide-out-to-top[data-state="closed"] { - --tw-exit-translate-y: -100%; -} - .data-\\[state\\=closed\\]\\:tw-slide-out-to-top-\\[48\\%\\][data-state="closed"] { --tw-exit-translate-y: -48%; } -.data-\\[state\\=open\\]\\:tw-slide-in-from-bottom[data-state="open"] { - --tw-enter-translate-y: 100%; -} - -.data-\\[state\\=open\\]\\:tw-slide-in-from-left[data-state="open"] { - --tw-enter-translate-x: -100%; -} - .data-\\[state\\=open\\]\\:tw-slide-in-from-left-1\\/2[data-state="open"] { --tw-enter-translate-x: -50%; } -.data-\\[state\\=open\\]\\:tw-slide-in-from-right[data-state="open"] { - --tw-enter-translate-x: 100%; -} - -.data-\\[state\\=open\\]\\:tw-slide-in-from-top[data-state="open"] { - --tw-enter-translate-y: -100%; -} - .data-\\[state\\=open\\]\\:tw-slide-in-from-top-\\[48\\%\\][data-state="open"] { --tw-enter-translate-y: -48%; } -.data-\\[state\\=closed\\]\\:tw-duration-300[data-state="closed"] { - animation-duration: 300ms; -} - -.data-\\[state\\=open\\]\\:tw-duration-500[data-state="open"] { - animation-duration: 500ms; -} - .data-\\[state\\=open\\]\\:hover\\:tw-bg-sidebar-accent:hover[data-state="open"] { background-color: hsl(var(--sidebar-accent)); } @@ -3180,10 +3118,6 @@ video:where(.pr-twp,.pr-twp *) { display: none; } - .sm\\:tw-max-w-sm { - max-width: 24rem; - } - .sm\\:tw-grid-cols-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); } @@ -3426,10 +3360,6 @@ video:where(.pr-twp,.pr-twp *) { padding-inline-end: 0px; } -.\\[\\&\\>button\\]\\:tw-hidden>button { - display: none; -} - .\\[\\&\\>span\\:last-child\\]\\:tw-truncate>span:last-child { overflow: hidden; text-overflow: ellipsis; @@ -3593,28 +3523,39 @@ video:where(.pr-twp,.pr-twp *) { .banded-row[data-state='selected']:hover { cursor: default; } -.papi-menu-item { - background-color: transparent; +.papi-multi-column-menu { + background-color: rgb(222, 222, 222); + display: flex; + flex-direction: column; + padding-left: 3px; + padding-right: 3px; } -.papi-menu-icon-trailing { - margin-left: 10px; - place-content: flex-end; +.papi-menu-column { + font-size: 11pt; + font-weight: 600; + padding-bottom: 2px; } -.papi-menu-item img { - max-width: 24px; - max-height: 24px; +.papi-menu-column ul { + padding-top: 0; } -.papi-menu-drawer-paper { - height: fit-content !important; - position: absolute !important; + +.papi-menu-column-header { + background-color: rgb(181, 181, 181); + padding-left: 24px; + margin-top: 0; + margin-bottom: 0; } -.papi-toolbar-children { - padding: 10px; - display: flex; - gap: 8px; +.papi-multi-column-menu.paratext { + background-color: rgb(76, 106, 76); + color: rgb(214, 255, 152); +} + +.papi-multi-column-menu.paratext.bright { + color: rgb(76, 106, 76); + background-color: rgb(214, 255, 152); } .papi-icon-button { border: 0; @@ -3642,39 +3583,28 @@ video:where(.pr-twp,.pr-twp *) { background-color: greenyellow; color: darkgreen; } -.papi-multi-column-menu { - background-color: rgb(222, 222, 222); - display: flex; - flex-direction: column; - padding-left: 3px; - padding-right: 3px; -} - -.papi-menu-column { - font-size: 11pt; - font-weight: 600; - padding-bottom: 2px; +.papi-menu-drawer-paper { + height: fit-content !important; + position: absolute !important; } -.papi-menu-column ul { - padding-top: 0; +.papi-toolbar-children { + padding: 10px; + display: flex; + gap: 8px; } - -.papi-menu-column-header { - background-color: rgb(181, 181, 181); - padding-left: 24px; - margin-top: 0; - margin-bottom: 0; +.papi-menu-item { + background-color: transparent; } -.papi-multi-column-menu.paratext { - background-color: rgb(76, 106, 76); - color: rgb(214, 255, 152); +.papi-menu-icon-trailing { + margin-left: 10px; + place-content: flex-end; } -.papi-multi-column-menu.paratext.bright { - color: rgb(76, 106, 76); - background-color: rgb(214, 255, 152); +.papi-menu-item img { + max-width: 24px; + max-height: 24px; } `,"top"); //# sourceMappingURL=index.cjs.map diff --git a/lib/platform-bible-react/dist/index.cjs.map b/lib/platform-bible-react/dist/index.cjs.map index 43c0128dfb..366091aa66 100644 --- a/lib/platform-bible-react/dist/index.cjs.map +++ b/lib/platform-bible-react/dist/index.cjs.map @@ -1 +1 @@ -{"version":3,"file":"index.cjs","sources":["../src/utils/shadcn-ui.util.ts","../src/components/shadcn-ui/input.tsx","../src/components/advanced/book-chapter-control/book-chapter-input.component.tsx","../../../node_modules/@sillsdev/scripture/dist/index.es.js","../src/components/shadcn-ui/dropdown-menu.tsx","../src/components/advanced/book-chapter-control/book-menu-item.component.tsx","../src/components/advanced/book-chapter-control/chapter-select.component.tsx","../src/components/advanced/book-chapter-control/go-to-menu-item.component.tsx","../src/components/advanced/book-chapter-control/book-chapter-control.component.tsx","../src/components/shadcn-ui/button.tsx","../src/components/shadcn-ui/label.tsx","../src/components/shadcn-ui/radio-group.tsx","../src/components/shadcn-ui/popover.tsx","../src/components/shadcn-ui/dialog.tsx","../src/components/shadcn-ui/command.tsx","../src/components/basics/combo-box.component.tsx","../src/components/basics/chapter-range-selector.component.tsx","../src/components/advanced/book-selector.component.tsx","../src/components/advanced/data-table/data-table-column-toggle.component.tsx","../src/components/shadcn-ui/select.tsx","../src/components/advanced/data-table/data-table-pagination.component.tsx","../src/components/shadcn-ui/table.tsx","../src/components/advanced/data-table/data-table.component.tsx","../src/components/advanced/inventory/occurrences-table.component.tsx","../src/components/shadcn-ui/checkbox.tsx","../src/components/advanced/inventory/inventory-utils.ts","../src/components/shadcn-ui/toggle.tsx","../src/components/shadcn-ui/toggle-group.tsx","../src/components/advanced/inventory/inventory-columns.tsx","../src/components/advanced/inventory/inventory.component.tsx","../src/components/basics/search-bar.component.tsx","../src/components/basics/tabs-vertical.tsx","../src/components/advanced/tab-navigation-content-search.component.tsx","../src/components/shadcn-ui/separator.tsx","../src/components/shadcn-ui/sheet.tsx","../src/components/shadcn-ui/skeleton.tsx","../src/components/shadcn-ui/tooltip.tsx","../src/components/hooks/use-mobile.tsx","../src/components/shadcn-ui/sidebar.tsx","../src/components/advanced/settings-components/settings-sidebar.component.tsx","../src/components/advanced/settings-components/settings-sidebar-content-search.component.tsx","../src/components/advanced/scripture-results-viewer/scripture-results-viewer.component.tsx","../src/components/advanced/scroll-group-selector.component.tsx","../src/components/advanced/settings-components/settings-list.component.tsx","../src/components/basics/checklist.component.tsx","../../../node_modules/@babel/runtime/helpers/interopRequireDefault.js","../../../node_modules/@mui/utils/chainPropTypes/chainPropTypes.js","../../../node_modules/@babel/runtime/helpers/esm/extends.js","../../../node_modules/@mui/utils/deepmerge/deepmerge.js","../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.production.min.js","../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.development.js","../../../node_modules/prop-types/node_modules/react-is/index.js","../../../node_modules/object-assign/index.js","../../../node_modules/prop-types/lib/ReactPropTypesSecret.js","../../../node_modules/prop-types/lib/has.js","../../../node_modules/prop-types/checkPropTypes.js","../../../node_modules/prop-types/factoryWithTypeCheckers.js","../../../node_modules/prop-types/factoryWithThrowingShims.js","../../../node_modules/prop-types/index.js","../../../node_modules/@mui/utils/elementAcceptingRef/elementAcceptingRef.js","../../../node_modules/@mui/utils/exactProp/exactProp.js","../../../node_modules/@mui/utils/formatMuiErrorMessage/formatMuiErrorMessage.js","../../../node_modules/react-is/cjs/react-is.production.min.js","../../../node_modules/react-is/cjs/react-is.development.js","../../../node_modules/react-is/index.js","../../../node_modules/@mui/utils/getDisplayName/getDisplayName.js","../../../node_modules/@mui/utils/HTMLElementType/HTMLElementType.js","../../../node_modules/@mui/utils/refType/refType.js","../../../node_modules/@mui/utils/capitalize/capitalize.js","../../../node_modules/@mui/utils/createChainedFunction/createChainedFunction.js","../../../node_modules/@mui/utils/debounce/debounce.js","../../../node_modules/@mui/utils/deprecatedPropType/deprecatedPropType.js","../../../node_modules/@mui/utils/isMuiElement/isMuiElement.js","../../../node_modules/@mui/utils/ownerDocument/ownerDocument.js","../../../node_modules/@mui/utils/ownerWindow/ownerWindow.js","../../../node_modules/@mui/utils/requirePropFactory/requirePropFactory.js","../../../node_modules/@mui/utils/setRef/setRef.js","../../../node_modules/@mui/utils/useEnhancedEffect/useEnhancedEffect.js","../../../node_modules/@mui/utils/useId/useId.js","../../../node_modules/@mui/utils/unsupportedProp/unsupportedProp.js","../../../node_modules/@mui/utils/useControlled/useControlled.js","../../../node_modules/@mui/utils/useEventCallback/useEventCallback.js","../../../node_modules/@mui/utils/useForkRef/useForkRef.js","../../../node_modules/@mui/utils/useLazyRef/useLazyRef.js","../../../node_modules/@mui/utils/useOnMount/useOnMount.js","../../../node_modules/@mui/utils/useTimeout/useTimeout.js","../../../node_modules/@mui/utils/useIsFocusVisible/useIsFocusVisible.js","../../../node_modules/@mui/utils/resolveProps/resolveProps.js","../../../node_modules/@mui/utils/composeClasses/composeClasses.js","../../../node_modules/@mui/utils/ClassNameGenerator/ClassNameGenerator.js","../../../node_modules/@mui/utils/generateUtilityClass/generateUtilityClass.js","../../../node_modules/@mui/utils/generateUtilityClasses/generateUtilityClasses.js","../../../node_modules/@mui/utils/clamp/clamp.js","../../../node_modules/@babel/runtime/helpers/esm/objectWithoutPropertiesLoose.js","../../../node_modules/@mui/system/esm/createTheme/createBreakpoints.js","../../../node_modules/@mui/system/esm/createTheme/shape.js","../../../node_modules/@mui/system/esm/responsivePropType.js","../../../node_modules/@mui/system/esm/merge.js","../../../node_modules/@mui/system/esm/breakpoints.js","../../../node_modules/@mui/system/esm/style.js","../../../node_modules/@mui/system/esm/memoize.js","../../../node_modules/@mui/system/esm/spacing.js","../../../node_modules/@mui/system/esm/createTheme/createSpacing.js","../../../node_modules/@mui/system/esm/compose.js","../../../node_modules/@mui/system/esm/borders.js","../../../node_modules/@mui/system/esm/cssGrid.js","../../../node_modules/@mui/system/esm/palette.js","../../../node_modules/@mui/system/esm/sizing.js","../../../node_modules/@mui/system/esm/styleFunctionSx/defaultSxConfig.js","../../../node_modules/@mui/system/esm/styleFunctionSx/styleFunctionSx.js","../../../node_modules/@mui/system/esm/createTheme/applyStyles.js","../../../node_modules/@mui/system/esm/createTheme/createTheme.js","../../../node_modules/@mui/system/esm/useThemeWithoutDefault.js","../../../node_modules/@mui/system/esm/useTheme.js","../../../node_modules/@mui/system/esm/createStyled.js","../../../node_modules/@mui/system/esm/useThemeProps/getThemeProps.js","../../../node_modules/@mui/system/esm/useThemeProps/useThemeProps.js","../../../node_modules/@mui/system/esm/colorManipulator.js","../../../node_modules/@mui/material/styles/createMixins.js","../../../node_modules/@mui/material/colors/common.js","../../../node_modules/@mui/material/colors/grey.js","../../../node_modules/@mui/material/colors/purple.js","../../../node_modules/@mui/material/colors/red.js","../../../node_modules/@mui/material/colors/orange.js","../../../node_modules/@mui/material/colors/blue.js","../../../node_modules/@mui/material/colors/lightBlue.js","../../../node_modules/@mui/material/colors/green.js","../../../node_modules/@mui/material/styles/createPalette.js","../../../node_modules/@mui/material/styles/createTypography.js","../../../node_modules/@mui/material/styles/shadows.js","../../../node_modules/@mui/material/styles/createTransitions.js","../../../node_modules/@mui/material/styles/zIndex.js","../../../node_modules/@mui/material/styles/createTheme.js","../../../node_modules/@mui/material/styles/defaultTheme.js","../../../node_modules/@mui/material/styles/identifier.js","../../../node_modules/@mui/material/styles/useThemeProps.js","../../../node_modules/@mui/material/styles/styled.js","../../../node_modules/@mui/material/SvgIcon/svgIconClasses.js","../../../node_modules/@mui/material/SvgIcon/SvgIcon.js","../../../node_modules/@mui/material/utils/createSvgIcon.js","../../../node_modules/@mui/material/utils/index.js","../../../node_modules/@mui/icons-material/utils/createSvgIcon.js","../../../node_modules/@mui/icons-material/ArrowRight.js","../../../node_modules/@mui/base/utils/isHostComponent.js","../../../node_modules/@mui/base/utils/appendOwnerState.js","../../../node_modules/@mui/base/utils/ClassNameConfigurator.js","../../../node_modules/@mui/base/utils/extractEventHandlers.js","../../../node_modules/@mui/base/utils/resolveComponentProps.js","../../../node_modules/@mui/base/utils/omitEventHandlers.js","../../../node_modules/@mui/base/utils/mergeSlotProps.js","../../../node_modules/@mui/base/utils/useSlotProps.js","../../../node_modules/@mui/base/generateUtilityClass/index.js","../../../node_modules/@mui/base/generateUtilityClasses/index.js","../../../node_modules/@mui/base/Portal/Portal.js","../../../node_modules/@popperjs/core/lib/enums.js","../../../node_modules/@popperjs/core/lib/dom-utils/getNodeName.js","../../../node_modules/@popperjs/core/lib/dom-utils/getWindow.js","../../../node_modules/@popperjs/core/lib/dom-utils/instanceOf.js","../../../node_modules/@popperjs/core/lib/modifiers/applyStyles.js","../../../node_modules/@popperjs/core/lib/utils/getBasePlacement.js","../../../node_modules/@popperjs/core/lib/utils/math.js","../../../node_modules/@popperjs/core/lib/utils/userAgent.js","../../../node_modules/@popperjs/core/lib/dom-utils/isLayoutViewport.js","../../../node_modules/@popperjs/core/lib/dom-utils/getBoundingClientRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/getLayoutRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/contains.js","../../../node_modules/@popperjs/core/lib/dom-utils/getComputedStyle.js","../../../node_modules/@popperjs/core/lib/dom-utils/isTableElement.js","../../../node_modules/@popperjs/core/lib/dom-utils/getDocumentElement.js","../../../node_modules/@popperjs/core/lib/dom-utils/getParentNode.js","../../../node_modules/@popperjs/core/lib/dom-utils/getOffsetParent.js","../../../node_modules/@popperjs/core/lib/utils/getMainAxisFromPlacement.js","../../../node_modules/@popperjs/core/lib/utils/within.js","../../../node_modules/@popperjs/core/lib/utils/getFreshSideObject.js","../../../node_modules/@popperjs/core/lib/utils/mergePaddingObject.js","../../../node_modules/@popperjs/core/lib/utils/expandToHashMap.js","../../../node_modules/@popperjs/core/lib/modifiers/arrow.js","../../../node_modules/@popperjs/core/lib/utils/getVariation.js","../../../node_modules/@popperjs/core/lib/modifiers/computeStyles.js","../../../node_modules/@popperjs/core/lib/modifiers/eventListeners.js","../../../node_modules/@popperjs/core/lib/utils/getOppositePlacement.js","../../../node_modules/@popperjs/core/lib/utils/getOppositeVariationPlacement.js","../../../node_modules/@popperjs/core/lib/dom-utils/getWindowScroll.js","../../../node_modules/@popperjs/core/lib/dom-utils/getWindowScrollBarX.js","../../../node_modules/@popperjs/core/lib/dom-utils/getViewportRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/getDocumentRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/isScrollParent.js","../../../node_modules/@popperjs/core/lib/dom-utils/getScrollParent.js","../../../node_modules/@popperjs/core/lib/dom-utils/listScrollParents.js","../../../node_modules/@popperjs/core/lib/utils/rectToClientRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/getClippingRect.js","../../../node_modules/@popperjs/core/lib/utils/computeOffsets.js","../../../node_modules/@popperjs/core/lib/utils/detectOverflow.js","../../../node_modules/@popperjs/core/lib/utils/computeAutoPlacement.js","../../../node_modules/@popperjs/core/lib/modifiers/flip.js","../../../node_modules/@popperjs/core/lib/modifiers/hide.js","../../../node_modules/@popperjs/core/lib/modifiers/offset.js","../../../node_modules/@popperjs/core/lib/modifiers/popperOffsets.js","../../../node_modules/@popperjs/core/lib/utils/getAltAxis.js","../../../node_modules/@popperjs/core/lib/modifiers/preventOverflow.js","../../../node_modules/@popperjs/core/lib/dom-utils/getHTMLElementScroll.js","../../../node_modules/@popperjs/core/lib/dom-utils/getNodeScroll.js","../../../node_modules/@popperjs/core/lib/dom-utils/getCompositeRect.js","../../../node_modules/@popperjs/core/lib/utils/orderModifiers.js","../../../node_modules/@popperjs/core/lib/utils/debounce.js","../../../node_modules/@popperjs/core/lib/utils/mergeByName.js","../../../node_modules/@popperjs/core/lib/createPopper.js","../../../node_modules/@popperjs/core/lib/popper.js","../../../node_modules/@mui/base/Popper/popperClasses.js","../../../node_modules/@mui/base/Popper/Popper.js","../../../node_modules/@mui/material/styles/useTheme.js","../../../node_modules/@babel/runtime/helpers/esm/setPrototypeOf.js","../../../node_modules/@babel/runtime/helpers/esm/inheritsLoose.js","../../../node_modules/react-transition-group/esm/config.js","../../../node_modules/react-transition-group/esm/utils/PropTypes.js","../../../node_modules/react-transition-group/esm/TransitionGroupContext.js","../../../node_modules/react-transition-group/esm/utils/reflow.js","../../../node_modules/react-transition-group/esm/Transition.js","../../../node_modules/@mui/material/transitions/utils.js","../../../node_modules/@mui/material/Grow/Grow.js","../../../node_modules/@mui/material/Popper/Popper.js","../../../node_modules/@mui/material/Tooltip/tooltipClasses.js","../../../node_modules/@mui/material/Tooltip/Tooltip.js","../src/components/mui/menu-item.component.tsx","../src/components/mui/grouped-menu-item-list.component.tsx","../src/components/mui/top-level-menu.component.tsx","../src/components/mui/grid-menu.component.tsx","../src/hooks/use-promise.hook.ts","../../../node_modules/@mui/icons-material/esm/Menu.js","../src/components/mui/hamburger-menu-button.component.tsx","../src/components/mui/icon-button.component.tsx","../src/components/basics/spinner.component.tsx","../src/components/basics/text-field.component.tsx","../src/components/mui/toolbar.component.tsx","../src/components/shadcn-ui/alert.tsx","../src/components/shadcn-ui/card.tsx","../src/components/shadcn-ui/sonner.tsx","../src/components/shadcn-ui/slider.tsx","../src/components/shadcn-ui/switch.tsx","../src/components/shadcn-ui/tabs.tsx","../src/components/advanced/extension-marketplace/buttons/install-button.component.tsx","../src/components/advanced/extension-marketplace/buttons/enable-button.component.tsx","../src/components/advanced/extension-marketplace/buttons/disable-button.component.tsx","../src/components/advanced/extension-marketplace/buttons/update-button.component.tsx","../src/components/advanced/extension-marketplace/markdown-renderer.component.tsx","../src/components/advanced/extension-marketplace/buttons/filter-button.component.tsx","../src/components/advanced/extension-marketplace/filter-dropdown.component.tsx","../src/components/advanced/extension-marketplace/no-extensions-found.component.tsx","../src/components/advanced/extension-marketplace/more-info.component.tsx","../src/components/advanced/extension-marketplace/version-history.component.tsx","../src/components/advanced/extension-marketplace/footer.component.tsx","../src/hooks/use-event.hook.ts","../src/hooks/use-event-async.hook.ts"],"sourcesContent":["import { type ClassValue, clsx } from 'clsx';\nimport { extendTailwindMerge } from 'tailwind-merge';\n\nconst twMergeCustom = extendTailwindMerge({ prefix: 'tw-' });\n\n/**\n * Tailwind and CSS class application helper function. Uses\n * [`clsx`](https://www.npmjs.com/package/clsx) to make it easy to apply classes conditionally using\n * object syntax, and uses [`tailwind-merge`](https://www.npmjs.com/package/tailwind-merge) to make\n * it easy to merge/overwrite Tailwind classes in a programmer-logic-friendly way.\n *\n * Note: `tailwind-merge` is configured to use the prefix `tw-`, so you must use the same prefix\n * with any Tailwind classes you use with this function to successfully overwrite other Tailwind\n * classes. `platform-bible-react` is configured to use `tw-` as its Tailwind prefix, so any\n * Tailwind classes you pass into `platform-bible-react` components will be compared using the `tw-`\n * prefix.\n *\n * This function was popularized by\n * [shadcn/ui](https://ui.shadcn.com/docs/installation/manual#add-a-cn-helper). See [ByteGrad's\n * explanation video](https://www.youtube.com/watch?v=re2JFITR7TI) for more information.\n *\n * @example\n *\n * ```typescript\n * const borderShouldBeBlue = true;\n * const textShouldBeRed = true;\n * const heightShouldBe20 = false;\n * const classString = cn(\n * 'tw-bg-primary tw-h-10 tw-text-primary-foreground',\n * 'tw-bg-secondary',\n * {\n * 'tw-border-blue-500': borderShouldBeBlue,\n * 'tw-text-red-500': textShouldBeRed,\n * 'tw-h-20': heightShouldBe20,\n * },\n * 'some-class',\n * );\n * ```\n *\n * The resulting `classString` is `'tw-h-10 tw-bg-secondary tw-border-blue-500 tw-text-red-500\n * some-class'`\n *\n * - Notice that `'tw-bg-secondary'`, specified later, overwrote `'tw-bg-primary'`, specified earlier,\n * because they are Tailwind classes that affect the same css property\n * - Notice that `'tw-text-red-500'`, specified later, overwrote `'tw-text-primary-foreground'`,\n * specified earlier, because they are Tailwind classes that affect the same css property\n * - Notice that `'tw-h-20'`, specified later, did not overwrite `'tw-h-10'`, specified earlier,\n * because `'tw-h-20'` is part of a conditional class object and its value evaluated to `false`;\n * therefore it was not applied\n * - Notice that `'some-class'` was applied. This function is not limited only to Tailwind classes.\n *\n *\n * @param inputs Class strings or `clsx` conditional class objects to merge. Tailwind classes\n * specified later in the arguments overwrite similar Tailwind classes specified earlier in the\n * arguments\n * @returns Class string containing all applicable classes from the arguments based on the rules\n * described above\n */\n// shadcn/ui uses this export in its boilerplate code\n// eslint-disable-next-line import/prefer-default-export\nexport function cn(...inputs: ClassValue[]) {\n return twMergeCustom(clsx(inputs));\n}\n","import React from 'react';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport interface InputProps extends React.InputHTMLAttributes {}\n\nexport const Input = React.forwardRef(\n ({ className, type, ...props }, ref) => {\n return (\n \n );\n },\n);\nInput.displayName = 'Input';\n","import { FocusEventHandler, forwardRef, KeyboardEvent, MouseEventHandler } from 'react';\nimport { History } from 'lucide-react';\nimport { Input as ShadInput } from '@/components/shadcn-ui/input';\n\nexport type BookChapterInputProps = {\n handleSearch: (searchString: string) => void;\n handleKeyDown: (event: KeyboardEvent) => void;\n handleOnClick: MouseEventHandler;\n handleSubmit: () => void;\n onFocus?: FocusEventHandler;\n value: string;\n placeholder: string;\n};\n\n// Shadcn Input sets type to \"button\"- HAVE to prop spread before setting type\nconst BookChapterInput = forwardRef(\n (\n { handleSearch, handleKeyDown, handleOnClick, handleSubmit, ...props }: BookChapterInputProps,\n ref,\n ) => {\n return (\n
    \n handleSearch(event.target.value)}\n onKeyDown={(e) => {\n if (e.key === 'Enter') {\n handleSubmit();\n }\n handleKeyDown(e);\n }}\n onClick={handleOnClick}\n ref={ref}\n />\n {\n // eslint-disable-next-line no-console\n console.log('back in history');\n }}\n />\n
    \n );\n },\n);\n\nexport default BookChapterInput;\n","var P = Object.defineProperty;\nvar R = (t, e, s) => e in t ? P(t, e, { enumerable: !0, configurable: !0, writable: !0, value: s }) : t[e] = s;\nvar n = (t, e, s) => R(t, typeof e != \"symbol\" ? e + \"\" : e, s);\nclass _ {\n constructor() {\n n(this, \"books\");\n n(this, \"firstSelectedBookNum\");\n n(this, \"lastSelectedBookNum\");\n n(this, \"count\");\n n(this, \"selectedBookNumbers\");\n n(this, \"selectedBookIds\");\n }\n}\nconst N = [\n \"GEN\",\n \"EXO\",\n \"LEV\",\n \"NUM\",\n \"DEU\",\n \"JOS\",\n \"JDG\",\n \"RUT\",\n \"1SA\",\n \"2SA\",\n // 10\n \"1KI\",\n \"2KI\",\n \"1CH\",\n \"2CH\",\n \"EZR\",\n \"NEH\",\n \"EST\",\n \"JOB\",\n \"PSA\",\n \"PRO\",\n // 20\n \"ECC\",\n \"SNG\",\n \"ISA\",\n \"JER\",\n \"LAM\",\n \"EZK\",\n \"DAN\",\n \"HOS\",\n \"JOL\",\n \"AMO\",\n // 30\n \"OBA\",\n \"JON\",\n \"MIC\",\n \"NAM\",\n \"HAB\",\n \"ZEP\",\n \"HAG\",\n \"ZEC\",\n \"MAL\",\n \"MAT\",\n // 40\n \"MRK\",\n \"LUK\",\n \"JHN\",\n \"ACT\",\n \"ROM\",\n \"1CO\",\n \"2CO\",\n \"GAL\",\n \"EPH\",\n \"PHP\",\n // 50\n \"COL\",\n \"1TH\",\n \"2TH\",\n \"1TI\",\n \"2TI\",\n \"TIT\",\n \"PHM\",\n \"HEB\",\n \"JAS\",\n \"1PE\",\n // 60\n \"2PE\",\n \"1JN\",\n \"2JN\",\n \"3JN\",\n \"JUD\",\n \"REV\",\n \"TOB\",\n \"JDT\",\n \"ESG\",\n \"WIS\",\n // 70\n \"SIR\",\n \"BAR\",\n \"LJE\",\n \"S3Y\",\n \"SUS\",\n \"BEL\",\n \"1MA\",\n \"2MA\",\n \"3MA\",\n \"4MA\",\n // 80\n \"1ES\",\n \"2ES\",\n \"MAN\",\n \"PS2\",\n \"ODA\",\n \"PSS\",\n \"JSA\",\n // actual variant text for JOS, now in LXA text\n \"JDB\",\n // actual variant text for JDG, now in LXA text\n \"TBS\",\n // actual variant text for TOB, now in LXA text\n \"SST\",\n // actual variant text for SUS, now in LXA text // 90\n \"DNT\",\n // actual variant text for DAN, now in LXA text\n \"BLT\",\n // actual variant text for BEL, now in LXA text\n \"XXA\",\n \"XXB\",\n \"XXC\",\n \"XXD\",\n \"XXE\",\n \"XXF\",\n \"XXG\",\n \"FRT\",\n // 100\n \"BAK\",\n \"OTH\",\n \"3ES\",\n // Used previously but really should be 2ES\n \"EZA\",\n // Used to be called 4ES, but not actually in any known project\n \"5EZ\",\n // Used to be called 5ES, but not actually in any known project\n \"6EZ\",\n // Used to be called 6ES, but not actually in any known project\n \"INT\",\n \"CNC\",\n \"GLO\",\n \"TDX\",\n // 110\n \"NDX\",\n \"DAG\",\n \"PS3\",\n \"2BA\",\n \"LBA\",\n \"JUB\",\n \"ENO\",\n \"1MQ\",\n \"2MQ\",\n \"3MQ\",\n // 120\n \"REP\",\n \"4BA\",\n \"LAO\"\n], B = [\n \"XXA\",\n \"XXB\",\n \"XXC\",\n \"XXD\",\n \"XXE\",\n \"XXF\",\n \"XXG\",\n \"FRT\",\n \"BAK\",\n \"OTH\",\n \"INT\",\n \"CNC\",\n \"GLO\",\n \"TDX\",\n \"NDX\"\n], O = [\n \"Genesis\",\n \"Exodus\",\n \"Leviticus\",\n \"Numbers\",\n \"Deuteronomy\",\n \"Joshua\",\n \"Judges\",\n \"Ruth\",\n \"1 Samuel\",\n \"2 Samuel\",\n \"1 Kings\",\n \"2 Kings\",\n \"1 Chronicles\",\n \"2 Chronicles\",\n \"Ezra\",\n \"Nehemiah\",\n \"Esther (Hebrew)\",\n \"Job\",\n \"Psalms\",\n \"Proverbs\",\n \"Ecclesiastes\",\n \"Song of Songs\",\n \"Isaiah\",\n \"Jeremiah\",\n \"Lamentations\",\n \"Ezekiel\",\n \"Daniel (Hebrew)\",\n \"Hosea\",\n \"Joel\",\n \"Amos\",\n \"Obadiah\",\n \"Jonah\",\n \"Micah\",\n \"Nahum\",\n \"Habakkuk\",\n \"Zephaniah\",\n \"Haggai\",\n \"Zechariah\",\n \"Malachi\",\n \"Matthew\",\n \"Mark\",\n \"Luke\",\n \"John\",\n \"Acts\",\n \"Romans\",\n \"1 Corinthians\",\n \"2 Corinthians\",\n \"Galatians\",\n \"Ephesians\",\n \"Philippians\",\n \"Colossians\",\n \"1 Thessalonians\",\n \"2 Thessalonians\",\n \"1 Timothy\",\n \"2 Timothy\",\n \"Titus\",\n \"Philemon\",\n \"Hebrews\",\n \"James\",\n \"1 Peter\",\n \"2 Peter\",\n \"1 John\",\n \"2 John\",\n \"3 John\",\n \"Jude\",\n \"Revelation\",\n \"Tobit\",\n \"Judith\",\n \"Esther Greek\",\n \"Wisdom of Solomon\",\n \"Sirach (Ecclesiasticus)\",\n \"Baruch\",\n \"Letter of Jeremiah\",\n \"Song of 3 Young Men\",\n \"Susanna\",\n \"Bel and the Dragon\",\n \"1 Maccabees\",\n \"2 Maccabees\",\n \"3 Maccabees\",\n \"4 Maccabees\",\n \"1 Esdras (Greek)\",\n \"2 Esdras (Latin)\",\n \"Prayer of Manasseh\",\n \"Psalm 151\",\n \"Odes\",\n \"Psalms of Solomon\",\n // WARNING, if you change the spelling of the *obsolete* tag be sure to update\n // IsObsolete routine\n \"Joshua A. *obsolete*\",\n \"Judges B. *obsolete*\",\n \"Tobit S. *obsolete*\",\n \"Susanna Th. *obsolete*\",\n \"Daniel Th. *obsolete*\",\n \"Bel Th. *obsolete*\",\n \"Extra A\",\n \"Extra B\",\n \"Extra C\",\n \"Extra D\",\n \"Extra E\",\n \"Extra F\",\n \"Extra G\",\n \"Front Matter\",\n \"Back Matter\",\n \"Other Matter\",\n \"3 Ezra *obsolete*\",\n \"Apocalypse of Ezra\",\n \"5 Ezra (Latin Prologue)\",\n \"6 Ezra (Latin Epilogue)\",\n \"Introduction\",\n \"Concordance \",\n \"Glossary \",\n \"Topical Index\",\n \"Names Index\",\n \"Daniel Greek\",\n \"Psalms 152-155\",\n \"2 Baruch (Apocalypse)\",\n \"Letter of Baruch\",\n \"Jubilees\",\n \"Enoch\",\n \"1 Meqabyan\",\n \"2 Meqabyan\",\n \"3 Meqabyan\",\n \"Reproof (Proverbs 25-31)\",\n \"4 Baruch (Rest of Baruch)\",\n \"Laodiceans\"\n], S = K();\nfunction g(t, e = !0) {\n return e && (t = t.toUpperCase()), t in S ? S[t] : 0;\n}\nfunction k(t) {\n return g(t) > 0;\n}\nfunction x(t) {\n const e = typeof t == \"string\" ? g(t) : t;\n return e >= 40 && e <= 66;\n}\nfunction T(t) {\n return (typeof t == \"string\" ? g(t) : t) <= 39;\n}\nfunction X(t) {\n return t <= 66;\n}\nfunction V(t) {\n const e = typeof t == \"string\" ? g(t) : t;\n return w(e) && !X(e);\n}\nfunction* L() {\n for (let t = 1; t <= N.length; t++) yield t;\n}\nconst G = 1, A = N.length;\nfunction H() {\n return [\"XXA\", \"XXB\", \"XXC\", \"XXD\", \"XXE\", \"XXF\", \"XXG\"];\n}\nfunction C(t, e = \"***\") {\n const s = t - 1;\n return s < 0 || s >= N.length ? e : N[s];\n}\nfunction I(t) {\n return t <= 0 || t > A ? \"******\" : O[t - 1];\n}\nfunction y(t) {\n return I(g(t));\n}\nfunction w(t) {\n const e = typeof t == \"number\" ? C(t) : t;\n return k(e) && !B.includes(e);\n}\nfunction q(t) {\n const e = typeof t == \"number\" ? C(t) : t;\n return k(e) && B.includes(e);\n}\nfunction U(t) {\n return O[t - 1].includes(\"*obsolete*\");\n}\nfunction K() {\n const t = {};\n for (let e = 0; e < N.length; e++)\n t[N[e]] = e + 1;\n return t;\n}\nconst m = {\n allBookIds: N,\n nonCanonicalIds: B,\n bookIdToNumber: g,\n isBookIdValid: k,\n isBookNT: x,\n isBookOT: T,\n isBookOTNT: X,\n isBookDC: V,\n allBookNumbers: L,\n firstBook: G,\n lastBook: A,\n extraBooks: H,\n bookNumberToId: C,\n bookNumberToEnglishName: I,\n bookIdToEnglishName: y,\n isCanonical: w,\n isExtraMaterial: q,\n isObsolete: U\n};\nvar l = /* @__PURE__ */ ((t) => (t[t.Unknown = 0] = \"Unknown\", t[t.Original = 1] = \"Original\", t[t.Septuagint = 2] = \"Septuagint\", t[t.Vulgate = 3] = \"Vulgate\", t[t.English = 4] = \"English\", t[t.RussianProtestant = 5] = \"RussianProtestant\", t[t.RussianOrthodox = 6] = \"RussianOrthodox\", t))(l || {});\nconst h = class h {\n // private versInfo: Versification;\n constructor(e) {\n n(this, \"name\");\n n(this, \"fullPath\");\n n(this, \"isPresent\");\n n(this, \"hasVerseSegments\");\n n(this, \"isCustomized\");\n n(this, \"baseVersification\");\n n(this, \"scriptureBooks\");\n n(this, \"_type\");\n if (e == null)\n throw new Error(\"Argument undefined\");\n typeof e == \"string\" ? (this.name = e, this._type = l[e]) : (this._type = e, this.name = l[e]);\n }\n get type() {\n return this._type;\n }\n equals(e) {\n return !e.type || !this.type ? !1 : e.type === this.type;\n }\n};\nn(h, \"Original\", new h(l.Original)), n(h, \"Septuagint\", new h(l.Septuagint)), n(h, \"Vulgate\", new h(l.Vulgate)), n(h, \"English\", new h(l.English)), n(h, \"RussianProtestant\", new h(l.RussianProtestant)), n(h, \"RussianOrthodox\", new h(l.RussianOrthodox));\nlet c = h;\nfunction E(t, e) {\n const s = e[0];\n for (let r = 1; r < e.length; r++)\n t = t.split(e[r]).join(s);\n return t.split(s);\n}\nvar D = /* @__PURE__ */ ((t) => (t[t.Valid = 0] = \"Valid\", t[t.UnknownVersification = 1] = \"UnknownVersification\", t[t.OutOfRange = 2] = \"OutOfRange\", t[t.VerseOutOfOrder = 3] = \"VerseOutOfOrder\", t[t.VerseRepeated = 4] = \"VerseRepeated\", t))(D || {});\nconst i = class i {\n constructor(e, s, r, a) {\n /** Not yet implemented. */\n n(this, \"firstChapter\");\n /** Not yet implemented. */\n n(this, \"lastChapter\");\n /** Not yet implemented. */\n n(this, \"lastVerse\");\n /** Not yet implemented. */\n n(this, \"hasSegmentsDefined\");\n /** Not yet implemented. */\n n(this, \"text\");\n /** Not yet implemented. */\n n(this, \"BBBCCCVVVS\");\n /** Not yet implemented. */\n n(this, \"longHashCode\");\n /** The versification of the reference. */\n n(this, \"versification\");\n n(this, \"rtlMark\", \"‏\");\n n(this, \"_bookNum\", 0);\n n(this, \"_chapterNum\", 0);\n n(this, \"_verseNum\", 0);\n n(this, \"_verse\");\n if (r == null && a == null)\n if (e != null && typeof e == \"string\") {\n const o = e, u = s != null && s instanceof c ? s : void 0;\n this.setEmpty(u), this.parse(o);\n } else if (e != null && typeof e == \"number\") {\n const o = s != null && s instanceof c ? s : void 0;\n this.setEmpty(o), this._verseNum = e % i.chapterDigitShifter, this._chapterNum = Math.floor(\n e % i.bookDigitShifter / i.chapterDigitShifter\n ), this._bookNum = Math.floor(e / i.bookDigitShifter);\n } else if (s == null)\n if (e != null && e instanceof i) {\n const o = e;\n this._bookNum = o.bookNum, this._chapterNum = o.chapterNum, this._verseNum = o.verseNum, this._verse = o.verse, this.versification = o.versification;\n } else {\n if (e == null) return;\n const o = e instanceof c ? e : i.defaultVersification;\n this.setEmpty(o);\n }\n else\n throw new Error(\"VerseRef constructor not supported.\");\n else if (e != null && s != null && r != null)\n if (typeof e == \"string\" && typeof s == \"string\" && typeof r == \"string\")\n this.setEmpty(a), this.updateInternal(e, s, r);\n else if (typeof e == \"number\" && typeof s == \"number\" && typeof r == \"number\")\n this._bookNum = e, this._chapterNum = s, this._verseNum = r, this.versification = a ?? i.defaultVersification;\n else\n throw new Error(\"VerseRef constructor not supported.\");\n else\n throw new Error(\"VerseRef constructor not supported.\");\n }\n /**\n * Determines if the verse string is in a valid format (does not consider versification).\n */\n static isVerseParseable(e) {\n return e.length > 0 && \"0123456789\".includes(e[0]) && !e.endsWith(this.verseRangeSeparator) && !e.endsWith(this.verseSequenceIndicator);\n }\n /**\n * Tries to parse the specified string into a verse reference.\n * @param str - The string to attempt to parse.\n * @returns success: `true` if the specified string was successfully parsed, `false` otherwise.\n * @returns verseRef: The result of the parse if successful, or empty VerseRef if it failed\n */\n static tryParse(e) {\n let s;\n try {\n return s = new i(e), { success: !0, verseRef: s };\n } catch (r) {\n if (r instanceof v)\n return s = new i(), { success: !1, verseRef: s };\n throw r;\n }\n }\n /**\n * Gets the reference as a comparable integer where the book, chapter, and verse each occupy 3\n * digits.\n * @param bookNum - Book number (this is 1-based, not an index).\n * @param chapterNum - Chapter number.\n * @param verseNum - Verse number.\n * @returns The reference as a comparable integer where the book, chapter, and verse each occupy 3\n * digits.\n */\n static getBBBCCCVVV(e, s, r) {\n return e % i.bcvMaxValue * i.bookDigitShifter + (s >= 0 ? s % i.bcvMaxValue * i.chapterDigitShifter : 0) + (r >= 0 ? r % i.bcvMaxValue : 0);\n }\n /**\n * Deserializes a serialized VerseRef.\n * @param serializedVerseRef - Serialized VerseRef to create from.\n * @returns the deserialized VerseRef.\n */\n static fromJSON(e) {\n const { book: s, chapterNum: r, verseNum: a, verse: o, versificationStr: u } = e, f = o || a.toString();\n let d;\n return u && (d = new c(u)), s ? new i(s, r.toString(), f, d) : new i();\n }\n /**\n * Parses a verse string and gets the leading numeric portion as a number.\n * @param verseStr - verse string to parse\n * @returns true if the entire string could be parsed as a single, simple verse number (1-999);\n * false if the verse string represented a verse bridge, contained segment letters, or was invalid\n */\n static tryGetVerseNum(e) {\n let s;\n if (!e)\n return s = -1, { success: !0, vNum: s };\n s = 0;\n let r;\n for (let a = 0; a < e.length; a++) {\n if (r = e[a], r < \"0\" || r > \"9\")\n return a === 0 && (s = -1), { success: !1, vNum: s };\n if (s = s * 10 + +r - 0, s > i.bcvMaxValue)\n return s = -1, { success: !1, vNum: s };\n }\n return { success: !0, vNum: s };\n }\n /**\n * Checks to see if a VerseRef hasn't been set - all values are the default.\n */\n get isDefault() {\n return this.bookNum === 0 && this.chapterNum === 0 && this.verseNum === 0 && this.versification == null;\n }\n /**\n * Gets whether the verse contains multiple verses.\n */\n get hasMultiple() {\n return this._verse != null && (this._verse.includes(i.verseRangeSeparator) || this._verse.includes(i.verseSequenceIndicator));\n }\n /**\n * Gets or sets the book of the reference. Book is the 3-letter abbreviation in capital letters,\n * e.g. `'MAT'`.\n */\n get book() {\n return m.bookNumberToId(this.bookNum, \"\");\n }\n set book(e) {\n this.bookNum = m.bookIdToNumber(e);\n }\n /**\n * Gets or sets the chapter of the reference,. e.g. `'3'`.\n */\n get chapter() {\n return this.isDefault || this._chapterNum < 0 ? \"\" : this._chapterNum.toString();\n }\n set chapter(e) {\n const s = +e;\n this._chapterNum = Number.isInteger(s) ? s : -1;\n }\n /**\n * Gets or sets the verse of the reference, including range, segments, and sequences, e.g. `'4'`,\n * or `'4b-5a, 7'`.\n */\n get verse() {\n return this._verse != null ? this._verse : this.isDefault || this._verseNum < 0 ? \"\" : this._verseNum.toString();\n }\n set verse(e) {\n const { success: s, vNum: r } = i.tryGetVerseNum(e);\n this._verse = s ? void 0 : e.replace(this.rtlMark, \"\"), this._verseNum = r, !(this._verseNum >= 0) && ({ vNum: this._verseNum } = i.tryGetVerseNum(this._verse));\n }\n /**\n * Get or set Book based on book number, e.g. `42`.\n */\n get bookNum() {\n return this._bookNum;\n }\n set bookNum(e) {\n if (e <= 0 || e > m.lastBook)\n throw new v(\n \"BookNum must be greater than zero and less than or equal to last book\"\n );\n this._bookNum = e;\n }\n /**\n * Gets or sets the chapter number, e.g. `3`. `-1` if not valid.\n */\n get chapterNum() {\n return this._chapterNum;\n }\n set chapterNum(e) {\n this.chapterNum = e;\n }\n /**\n * Gets or sets verse start number, e.g. `4`. `-1` if not valid.\n */\n get verseNum() {\n return this._verseNum;\n }\n set verseNum(e) {\n this._verseNum = e;\n }\n /**\n * String representing the versification (should ONLY be used for serialization/deserialization).\n *\n * @remarks This is for backwards compatibility when ScrVers was an enumeration.\n */\n get versificationStr() {\n var e;\n return (e = this.versification) == null ? void 0 : e.name;\n }\n set versificationStr(e) {\n this.versification = this.versification != null ? new c(e) : void 0;\n }\n /**\n * Determines if the reference is valid.\n */\n get valid() {\n return this.validStatus === 0;\n }\n /**\n * Get the valid status for this reference.\n */\n get validStatus() {\n return this.validateVerse(i.verseRangeSeparators, i.verseSequenceIndicators);\n }\n /**\n * Gets the reference as a comparable integer where the book,\n * chapter, and verse each occupy three digits and the verse is 0.\n */\n get BBBCCC() {\n return i.getBBBCCCVVV(this._bookNum, this._chapterNum, 0);\n }\n /**\n * Gets the reference as a comparable integer where the book,\n * chapter, and verse each occupy three digits. If verse is not null\n * (i.e., this reference represents a complex reference with verse\n * segments or bridge) this cannot be used for an exact comparison.\n */\n get BBBCCCVVV() {\n return i.getBBBCCCVVV(this._bookNum, this._chapterNum, this._verseNum);\n }\n /**\n * Gets whether the verse is defined as an excluded verse in the versification.\n * Does not handle verse ranges.\n */\n // eslint-disable-next-line @typescript-eslint/class-literal-property-style\n get isExcluded() {\n return !1;\n }\n /**\n * Parses the reference in the specified string.\n * Optionally versification can follow reference as in GEN 3:11/4\n * Throw an exception if\n * - invalid book name\n * - chapter number is missing or not a number\n * - verse number is missing or does not start with a number\n * - versification is invalid\n * @param verseStr - string to parse e.g. 'MAT 3:11'\n */\n parse(e) {\n if (e = e.replace(this.rtlMark, \"\"), e.includes(\"/\")) {\n const o = e.split(\"/\");\n if (e = o[0], o.length > 1)\n try {\n const u = +o[1].trim();\n this.versification = new c(l[u]);\n } catch {\n throw new v(\"Invalid reference : \" + e);\n }\n }\n const s = e.trim().split(\" \");\n if (s.length !== 2)\n throw new v(\"Invalid reference : \" + e);\n const r = s[1].split(\":\"), a = +r[0];\n if (r.length !== 2 || m.bookIdToNumber(s[0]) === 0 || !Number.isInteger(a) || a < 0 || !i.isVerseParseable(r[1]))\n throw new v(\"Invalid reference : \" + e);\n this.updateInternal(s[0], r[0], r[1]);\n }\n /**\n * Simplifies this verse ref so that it has no bridging of verses or\n * verse segments like `'1a'`.\n */\n simplify() {\n this._verse = void 0;\n }\n /**\n * Makes a clone of the reference.\n *\n * @returns The cloned VerseRef.\n */\n clone() {\n return new i(this);\n }\n toString() {\n const e = this.book;\n return e === \"\" ? \"\" : `${e} ${this.chapter}:${this.verse}`;\n }\n toJSON() {\n let e = this.verse;\n (e === \"\" || e === this.verseNum.toString()) && (e = void 0);\n const s = {\n book: this.book,\n chapterNum: this.chapterNum,\n verseNum: this.verseNum,\n verse: e,\n versificationStr: this.versificationStr\n };\n return e || delete s.verse, s;\n }\n /**\n * Compares this `VerseRef` with supplied one.\n * @param verseRef - object to compare this one to.\n * @returns `true` if this `VerseRef` is equal to the supplied one, `false` otherwise.\n */\n equals(e) {\n return e instanceof i ? e._bookNum === this._bookNum && e._chapterNum === this._chapterNum && e._verseNum === this._verseNum && e.verse === this.verse && (e.versification == null && this.versification == null || e.versification != null && this.versification != null && e.versification.equals(this.versification)) : !1;\n }\n /**\n * Enumerate all individual verses contained in a VerseRef.\n * Verse ranges are indicated by \"-\" and consecutive verses by \",\"s.\n * Examples:\n * GEN 1:2 returns GEN 1:2\n * GEN 1:1a-3b,5 returns GEN 1:1a, GEN 1:2, GEN 1:3b, GEN 1:5\n * GEN 1:2a-2c returns //! ??????\n *\n * @param specifiedVersesOnly - if set to true return only verses that are\n * explicitly specified only, not verses within a range. Defaults to `false`.\n * @param verseRangeSeparators - Verse range separators.\n * Defaults to `VerseRef.verseRangeSeparators`.\n * @param verseSequenceSeparators - Verse sequence separators.\n * Defaults to `VerseRef.verseSequenceIndicators`.\n * @returns An array of all single verse references in this VerseRef.\n */\n allVerses(e = !1, s = i.verseRangeSeparators, r = i.verseSequenceIndicators) {\n if (this._verse == null || this.chapterNum <= 0)\n return [this.clone()];\n const a = [], o = E(this._verse, r);\n for (const u of o.map((f) => E(f, s))) {\n const f = this.clone();\n f.verse = u[0];\n const d = f.verseNum;\n if (a.push(f), u.length > 1) {\n const b = this.clone();\n if (b.verse = u[1], !e)\n for (let p = d + 1; p < b.verseNum; p++) {\n const J = new i(\n this._bookNum,\n this._chapterNum,\n p,\n this.versification\n );\n this.isExcluded || a.push(J);\n }\n a.push(b);\n }\n }\n return a;\n }\n /**\n * Validates a verse number using the supplied separators rather than the defaults.\n */\n validateVerse(e, s) {\n if (!this.verse)\n return this.internalValid;\n let r = 0;\n for (const a of this.allVerses(!0, e, s)) {\n const o = a.internalValid;\n if (o !== 0)\n return o;\n const u = a.BBBCCCVVV;\n if (r > u)\n return 3;\n if (r === u)\n return 4;\n r = u;\n }\n return 0;\n }\n /**\n * Gets whether a single verse reference is valid.\n */\n get internalValid() {\n return this.versification == null ? 1 : this._bookNum <= 0 || this._bookNum > m.lastBook ? 2 : (m.isCanonical(this._bookNum), 0);\n }\n setEmpty(e = i.defaultVersification) {\n this._bookNum = 0, this._chapterNum = -1, this._verse = void 0, this.versification = e;\n }\n updateInternal(e, s, r) {\n this.bookNum = m.bookIdToNumber(e), this.chapter = s, this.verse = r;\n }\n};\nn(i, \"defaultVersification\", c.English), n(i, \"verseRangeSeparator\", \"-\"), n(i, \"verseSequenceIndicator\", \",\"), n(i, \"verseRangeSeparators\", [i.verseRangeSeparator]), n(i, \"verseSequenceIndicators\", [i.verseSequenceIndicator]), n(i, \"chapterDigitShifter\", 1e3), n(i, \"bookDigitShifter\", i.chapterDigitShifter * i.chapterDigitShifter), n(i, \"bcvMaxValue\", i.chapterDigitShifter - 1), /**\n * The valid status of the VerseRef.\n */\nn(i, \"ValidStatusType\", D);\nlet M = i;\nclass v extends Error {\n}\nexport {\n _ as BookSet,\n m as Canon,\n c as ScrVers,\n l as ScrVersType,\n M as VerseRef,\n v as VerseRefException\n};\n//# sourceMappingURL=index.es.js.map\n","import React from 'react';\nimport * as DropdownMenuPrimitive from '@radix-ui/react-dropdown-menu';\nimport { Check, ChevronRight, Circle } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport const DropdownMenu = DropdownMenuPrimitive.Root;\n\nexport const DropdownMenuTrigger = DropdownMenuPrimitive.Trigger;\n\nexport const DropdownMenuGroup = DropdownMenuPrimitive.Group;\n\nexport const DropdownMenuPortal = DropdownMenuPrimitive.Portal;\n\nexport const DropdownMenuSub = DropdownMenuPrimitive.Sub;\n\nexport const DropdownMenuRadioGroup = DropdownMenuPrimitive.RadioGroup;\n\nexport type DropdownMenuSubTriggerProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.SubTrigger\n> & {\n className?: string;\n inset?: boolean;\n};\n\nexport type DropdownMenuSubContentProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.SubContent\n> & {\n className?: string;\n};\n\nexport type DropdownMenuContentProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Content\n> & {\n className?: string;\n sideOffset?: number;\n};\n\nexport type DropdownMenuItemProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Item\n> & {\n className?: string;\n inset?: boolean;\n};\n\nexport type DropdownMenuCheckboxItemProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.CheckboxItem\n> & {\n className?: string;\n checked?: boolean;\n};\n\nexport type DropdownMenuRadioItemProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.RadioItem\n> & {\n className?: string;\n};\n\nexport type DropdownMenuLabelProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Label\n> & {\n className?: string;\n inset?: boolean;\n};\n\nexport type DropdownMenuSeparatorProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Separator\n> & {\n className?: string;\n};\n\nexport type DropdownMenuShortcutProps = React.HTMLAttributes & {\n className?: string;\n};\n\nexport const DropdownMenuSubTrigger = React.forwardRef<\n React.ElementRef,\n DropdownMenuSubTriggerProps\n>(({ className, inset, children, ...props }, ref) => (\n \n {children}\n \n \n));\nDropdownMenuSubTrigger.displayName = DropdownMenuPrimitive.SubTrigger.displayName;\n\nexport const DropdownMenuSubContent = React.forwardRef<\n React.ElementRef,\n DropdownMenuSubContentProps\n>(({ className, ...props }, ref) => (\n \n));\nDropdownMenuSubContent.displayName = DropdownMenuPrimitive.SubContent.displayName;\n\nexport const DropdownMenuContent = React.forwardRef<\n React.ElementRef,\n DropdownMenuContentProps\n>(({ className, sideOffset = 4, ...props }, ref) => (\n \n \n \n));\nDropdownMenuContent.displayName = DropdownMenuPrimitive.Content.displayName;\n\n/**\n * TODO: fix: direction is not automatically handled by this component, so that shortcuts are\n * display always to the right\n */\nexport const DropdownMenuItem = React.forwardRef<\n React.ElementRef,\n DropdownMenuItemProps\n>(({ className, inset, ...props }, ref) => (\n \n));\nDropdownMenuItem.displayName = DropdownMenuPrimitive.Item.displayName;\n\nexport const DropdownMenuCheckboxItem = React.forwardRef<\n React.ElementRef,\n DropdownMenuCheckboxItemProps\n>(({ className, children, checked, ...props }, ref) => (\n \n \n \n \n \n \n {children}\n \n));\nDropdownMenuCheckboxItem.displayName = DropdownMenuPrimitive.CheckboxItem.displayName;\n\nexport const DropdownMenuRadioItem = React.forwardRef<\n React.ElementRef,\n DropdownMenuRadioItemProps\n>(({ className, children, ...props }, ref) => (\n \n \n \n \n \n \n {children}\n \n));\nDropdownMenuRadioItem.displayName = DropdownMenuPrimitive.RadioItem.displayName;\n\nexport const DropdownMenuLabel = React.forwardRef<\n React.ElementRef,\n DropdownMenuLabelProps\n>(({ className, inset, ...props }, ref) => (\n \n));\nDropdownMenuLabel.displayName = DropdownMenuPrimitive.Label.displayName;\n\nexport const DropdownMenuSeparator = React.forwardRef<\n React.ElementRef,\n DropdownMenuSeparatorProps\n>(({ className, ...props }, ref) => (\n \n));\nDropdownMenuSeparator.displayName = DropdownMenuPrimitive.Separator.displayName;\n\nexport function DropdownMenuShortcut({ className, ...props }: DropdownMenuShortcutProps) {\n return (\n \n );\n}\nDropdownMenuShortcut.displayName = 'DropdownMenuShortcut';\n","import { Canon } from '@sillsdev/scripture';\nimport { PropsWithChildren, KeyboardEvent, forwardRef } from 'react';\nimport { DropdownMenuItem as ShadDropdownMenuItem } from '@/components/shadcn-ui/dropdown-menu';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport type BookType = 'OT' | 'NT' | 'DC';\n\ntype BookMenuItemProps = PropsWithChildren<{\n /** String id of book */\n bookId: string;\n /** Callback to run when a book menu item is selected */\n handleSelectBook: () => void;\n /** Indicates if this menu item is currently selected */\n isSelected: boolean;\n /** Function that is called upon highlighting a book in the dropdown menu */\n handleHighlightBook: () => void;\n /**\n * Function that is called on pressing a key\n *\n * @param event Event that contains information about the key stroke\n */\n handleKeyDown: (event: KeyboardEvent) => void;\n /**\n * Type of book associated with this menu item, coordinates color labels ? Mock up has the labels\n * coordinated to genre\n */\n bookType: BookType;\n}>;\n\nconst BookMenuItem = forwardRef(\n (\n {\n bookId,\n handleSelectBook,\n isSelected,\n handleHighlightBook,\n handleKeyDown,\n bookType,\n children,\n }: BookMenuItemProps,\n ref,\n ) => {\n return (\n {\n // preventDefault() here prevents the entire dropdown menu from closing when selecting this item\n event.preventDefault();\n handleSelectBook();\n }}\n onKeyDown={(event: KeyboardEvent) => {\n handleKeyDown(event);\n }}\n onFocus={handleHighlightBook}\n onMouseMove={handleHighlightBook}\n >\n \n {Canon.bookIdToEnglishName(bookId)}\n \n {isSelected &&
    {children}
    }\n \n );\n },\n);\n\nexport default BookMenuItem;\n","import { cn } from '@/utils/shadcn-ui.util';\nimport { useCallback } from 'react';\n\nexport type ChapterSelectProps = {\n /**\n * Callback to run when a chapter div is selected\n *\n * @param chapterNumber Number of the chapter that has been selected\n */\n handleSelectChapter: (chapterNumber: number) => void;\n /** The highest chapter number in the book (of course equal to number of chapters in the book) */\n endChapter: number;\n /** The chapter number that is currently selected */\n activeChapter: number;\n /** The chapter number that is currently highlighted using keyboard or mouse navigation */\n highlightedChapter: number;\n /**\n * Callback to run when a chapter is highlighted by the user\n *\n * @param chapterNumber The chapter that is highlighted\n */\n handleHighlightedChapter: (chapterNumber: number) => void;\n};\n\nfunction ChapterSelect({\n handleSelectChapter,\n endChapter,\n activeChapter,\n highlightedChapter,\n handleHighlightedChapter,\n}: ChapterSelectProps) {\n const chapters = Array.from({ length: endChapter }, (_, i) => i + 1);\n\n const handleMouse = useCallback(\n (chapterNumber: number) => {\n handleHighlightedChapter(chapterNumber);\n },\n [handleHighlightedChapter],\n );\n\n return (\n
    \n {chapters.map((chapter) => (\n {\n event.preventDefault();\n event.stopPropagation();\n handleSelectChapter(chapter);\n }}\n role=\"button\"\n onKeyDown={(event) => {\n if (event.key === 'Enter') {\n handleSelectChapter(chapter);\n }\n }}\n tabIndex={0}\n onMouseMove={() => handleMouse(chapter)}\n >\n {chapter}\n
    \n ))}\n
    \n );\n}\n\nexport default ChapterSelect;\n","import { DropdownMenuLabel as ShadDropdownMenuLabel } from '@/components/shadcn-ui/dropdown-menu';\nimport { Bookmark, Clock, ArrowDownWideNarrow } from 'lucide-react';\n\nexport type GoToMenuItemProps = {\n handleSort: () => void;\n handleLocationHistory: () => void;\n handleBookmarks: () => void;\n};\n\nfunction GoToMenuItem({ handleSort, handleLocationHistory, handleBookmarks }: GoToMenuItemProps) {\n return (\n \n

    Go To

    \n
    \n \n \n \n
    \n
    \n );\n}\n\nexport default GoToMenuItem;\n","import BookChapterInput from '@/components/advanced/book-chapter-control/book-chapter-input.component';\nimport BookMenuItem, {\n BookType,\n} from '@/components/advanced/book-chapter-control/book-menu-item.component';\nimport ChapterSelect from '@/components/advanced/book-chapter-control/chapter-select.component';\nimport GoToMenuItem from '@/components/advanced/book-chapter-control/go-to-menu-item.component';\nimport {\n DropdownMenu as ShadDropdownMenu,\n DropdownMenuContent as ShadDropdownMenuContent,\n DropdownMenuLabel as ShadDropdownMenuLabel,\n DropdownMenuSeparator as ShadDropdownMenuSeparator,\n DropdownMenuTrigger as ShadDropdownMenuTrigger,\n} from '@/components/shadcn-ui/dropdown-menu';\nimport { Canon } from '@sillsdev/scripture';\nimport { ScriptureReference, getChaptersForBook } from 'platform-bible-utils';\nimport {\n KeyboardEvent as ReactKeyboardEvent,\n useCallback,\n useEffect,\n useLayoutEffect,\n useRef,\n useState,\n} from 'react';\n\ntype BookTypeLabels = {\n [bookType in BookType]: string;\n};\ntype BookChapterControlProps = {\n scrRef: ScriptureReference;\n handleSubmit: (scrRef: ScriptureReference) => void;\n};\n\nconst ALL_BOOK_IDS = Canon.allBookIds;\nconst BOOK_TYPE_LABELS: BookTypeLabels = {\n OT: 'Old Testament',\n NT: 'New Testament',\n DC: 'Deuterocanon',\n};\nconst BOOK_TYPE_ARRAY: BookType[] = ['OT', 'NT', 'DC'];\n// This is the height of three menu items to offset scrolling to the selected menu item\n// If you use menuItemRef.clientHeight- includes height of chapter div which is too big\nconst SCROLL_OFFSET = 32 + 32 + 32;\nconst SEARCH_QUERY_FORMATS = [\n /^(\\w+)$/i, // Matches a single word (book name or id)\n /^(\\w+)(?:\\s(\\d+))$/i, // Matches a word followed by a chapter number\n /^(\\w+)(?:\\s(\\d+):(\\d+))$/i, // Matches a word followed by a chapter and verse number\n];\nconst fetchGroupedBooks = (bookType: BookType) => {\n const groupedBooks = {\n OT: ALL_BOOK_IDS.filter((bookId) => Canon.isBookOT(bookId)),\n NT: ALL_BOOK_IDS.filter((bookId) => Canon.isBookNT(bookId)),\n DC: ALL_BOOK_IDS.filter((bookId) => Canon.isBookDC(bookId)),\n };\n return groupedBooks[bookType];\n};\nconst fetchEndChapter = (bookId: string) => {\n // getChaptersForBook returns -1 if not found in scrBookData\n // scrBookData only includes OT and NT, so all DC will return -1\n return getChaptersForBook(Canon.bookIdToNumber(bookId));\n};\n\n/**\n * Gets all of the English names from book ids\n *\n * @returns String[]\n */\nfunction getAllEnglishNames(): string[] {\n const allEnglishNames = ALL_BOOK_IDS.map((bookId) => {\n return Canon.bookIdToEnglishName(bookId);\n });\n return allEnglishNames;\n}\n\n/**\n * Determines if bookName is in allEnglishNames\n *\n * @param bookName Book English name\n * @returns True if bookName is included, false otherwise\n */\nfunction isValidBookEnglishName(bookName: string): boolean {\n return getAllEnglishNames().includes(bookName);\n}\n\n/**\n * Gets a bookId from given English name\n *\n * @param bookName Book English name\n * @returns BookId of provided bookName, undefined otherwise\n */\nfunction getBookIdFromEnglishName(bookName: string): string | undefined {\n // Convert bookName to lowercase and then capitalize the first letter\n const formattedBookName = bookName.toLowerCase().replace(/^\\w/, (c) => c.toUpperCase());\n\n if (isValidBookEnglishName(formattedBookName)) {\n const matchingBookId = ALL_BOOK_IDS.find((bookId) => {\n return Canon.bookIdToEnglishName(bookId) === formattedBookName;\n });\n return matchingBookId;\n }\n\n return undefined;\n}\n\nfunction BookChapterControl({ scrRef, handleSubmit }: BookChapterControlProps) {\n const [searchQuery, setSearchQuery] = useState('');\n const [selectedBookId, setSelectedBookId] = useState(\n Canon.bookNumberToId(scrRef.bookNum),\n );\n const [highlightedChapter, setHighlightedChapter] = useState(scrRef.chapterNum ?? 0);\n const [highlightedBookId, setHighlightedBookId] = useState(\n Canon.bookNumberToId(scrRef.bookNum),\n );\n const [isContentOpen, setIsContentOpen] = useState(false);\n const [isContentOpenDelayed, setIsContentOpenDelayed] = useState(isContentOpen);\n\n // This ref will always be defined\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const inputRef = useRef(undefined!);\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const contentRef = useRef(undefined!);\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const menuItemRef = useRef(undefined!);\n\n const fetchFilteredBooks = useCallback(\n (bookType: BookType) => {\n return fetchGroupedBooks(bookType).filter((bookId: string) => {\n const englishNameLowerCase = Canon.bookIdToEnglishName(bookId).toLowerCase();\n const normalizedQuery = searchQuery.replace(/[^a-zA-Z]/g, '').toLowerCase();\n return (\n englishNameLowerCase.includes(normalizedQuery) || // Match book name\n bookId.toLowerCase().includes(normalizedQuery) // Match book ID\n );\n });\n },\n [searchQuery],\n );\n\n const handleSearchInput = (searchString: string) => {\n setSearchQuery(searchString);\n };\n\n /**\n * Whether to prevent radix's logic from closing the dropdown. This is important because radix\n * tries to close the dropdown when the input first focuses, and we don't want it to do that. But\n * we don't want to prevent the dropdown from closing when we click away from the input, so we\n * don't want to just keep it open if the input is focused\n */\n const shouldPreventAutoClosing = useRef(false);\n\n const controlMenuState = useCallback((open: boolean) => {\n if (shouldPreventAutoClosing.current) {\n shouldPreventAutoClosing.current = false;\n return;\n }\n setIsContentOpen(open);\n }, []);\n\n const updateReference = useCallback(\n (bookId: string, shouldClose: boolean, chapter?: number, verse?: number) => {\n setHighlightedChapter(\n Canon.bookNumberToId(scrRef.bookNum) !== bookId ? 1 : scrRef.chapterNum,\n );\n\n if (shouldClose || fetchEndChapter(bookId) === -1) {\n handleSubmit({\n bookNum: Canon.bookIdToNumber(bookId),\n chapterNum: chapter || 1,\n verseNum: verse || 1,\n });\n\n setIsContentOpen(false);\n setSearchQuery('');\n return;\n }\n\n setSelectedBookId(selectedBookId !== bookId ? bookId : '');\n setIsContentOpen(!shouldClose);\n },\n [handleSubmit, scrRef.bookNum, scrRef.chapterNum, selectedBookId],\n );\n\n const handleSelectChapter = (chapterNumber: number) => {\n if (chapterNumber <= 0 || chapterNumber > fetchEndChapter(selectedBookId)) {\n return;\n }\n updateReference(selectedBookId, true, chapterNumber);\n };\n\n const handleInputSubmit = useCallback(() => {\n SEARCH_QUERY_FORMATS.forEach((format) => {\n const matches = searchQuery.match(format);\n if (matches) {\n // Book should be a bookId or an english name\n const [book, chapter = undefined, verse = undefined] = matches.slice(1);\n const englishName = getBookIdFromEnglishName(book);\n\n if (Canon.isBookIdValid(book) || englishName) {\n updateReference(\n englishName ?? book,\n true,\n chapter ? parseInt(chapter, 10) : 1,\n verse ? parseInt(verse, 10) : 1,\n );\n }\n }\n });\n }, [updateReference, searchQuery]);\n\n const handleKeyDownInput = useCallback(\n (event: ReactKeyboardEvent) => {\n if (!isContentOpen) {\n setIsContentOpen(true);\n } else if (event.key === 'ArrowDown' || event.key === 'ArrowUp') {\n if (\n typeof menuItemRef !== 'undefined' &&\n // Ref uses null\n // eslint-disable-next-line no-null/no-null\n menuItemRef.current !== null\n ) {\n menuItemRef.current.focus();\n } else if (\n typeof contentRef !== 'undefined' &&\n // Ref uses null\n // eslint-disable-next-line no-null/no-null\n contentRef.current !== null\n ) {\n contentRef.current.focus();\n }\n event.preventDefault();\n }\n },\n [isContentOpen],\n );\n\n const handleKeyDownContent = (event: ReactKeyboardEvent) => {\n // When the dropdown menu has focus, key strokes should give focus to the input component,\n // unless they're navigation keys (arrows and enter)\n const { key } = event;\n if (\n key === 'ArrowRight' ||\n key === 'ArrowLeft' ||\n key === 'ArrowDown' ||\n key === 'ArrowUp' ||\n key === 'Enter'\n ) {\n return;\n }\n\n inputRef.current.dispatchEvent(new KeyboardEvent('keydown', { key }));\n inputRef.current.focus();\n };\n\n const handleKeyDownMenuItem = (event: ReactKeyboardEvent) => {\n const { key } = event;\n if (highlightedBookId === selectedBookId) {\n if (key === 'Enter') {\n event.preventDefault();\n updateReference(selectedBookId, true, highlightedChapter);\n return;\n }\n\n let chapterOffSet = 0;\n if (key === 'ArrowRight') {\n if (highlightedChapter < fetchEndChapter(highlightedBookId)) {\n chapterOffSet = 1;\n } else {\n event.preventDefault();\n return;\n }\n } else if (key === 'ArrowLeft') {\n if (highlightedChapter > 1) {\n chapterOffSet = -1;\n } else {\n event.preventDefault();\n return;\n }\n } else if (key === 'ArrowDown') {\n chapterOffSet = 6;\n } else if (key === 'ArrowUp') {\n chapterOffSet = -6;\n }\n if (\n highlightedChapter + chapterOffSet <= 0 ||\n highlightedChapter + chapterOffSet > fetchEndChapter(highlightedBookId)\n ) {\n setHighlightedChapter(0);\n } else if (chapterOffSet !== 0) {\n setHighlightedChapter(highlightedChapter + chapterOffSet);\n event.preventDefault();\n }\n }\n };\n\n useEffect(() => {\n if (selectedBookId === highlightedBookId) {\n if (selectedBookId === Canon.bookNumberToId(scrRef.bookNum)) {\n setHighlightedChapter(scrRef.chapterNum);\n } else {\n setHighlightedChapter(1);\n }\n } else {\n setHighlightedChapter(0);\n }\n }, [highlightedBookId, scrRef.bookNum, scrRef.chapterNum, selectedBookId]);\n\n // The purpose of these useLayoutEffects and timeout is to delay the scroll just\n // enough so that the refs are defined and available when they are used after the timeout\n useLayoutEffect(() => {\n setIsContentOpenDelayed(isContentOpen);\n }, [isContentOpen]);\n\n useLayoutEffect(() => {\n const scrollTimeout = setTimeout(() => {\n if (isContentOpenDelayed && contentRef.current && menuItemRef.current) {\n const menuItemOffsetTop = menuItemRef.current.offsetTop;\n const scrollPosition = menuItemOffsetTop - SCROLL_OFFSET;\n contentRef.current.scrollTo({ top: scrollPosition, behavior: 'instant' });\n }\n }, 10);\n return () => {\n clearTimeout(scrollTimeout);\n };\n }, [isContentOpenDelayed]);\n\n return (\n
    \n \n \n {\n setSelectedBookId(Canon.bookNumberToId(scrRef.bookNum));\n setHighlightedBookId(Canon.bookNumberToId(scrRef.bookNum));\n setHighlightedChapter(scrRef.chapterNum > 0 ? scrRef.chapterNum : 0);\n setIsContentOpen(true);\n inputRef.current.focus();\n }}\n onFocus={() => {\n // Radix thinks we want to close because the input is being focused. Prevent that\n shouldPreventAutoClosing.current = true;\n }}\n handleSubmit={handleInputSubmit}\n placeholder={`${Canon.bookNumberToEnglishName(scrRef.bookNum)} ${scrRef.chapterNum}:${scrRef.verseNum}`}\n />\n \n \n console.log('sorting')}\n handleLocationHistory={() => console.log('location history')}\n handleBookmarks={() => console.log('bookmarks')}\n />\n {BOOK_TYPE_ARRAY.map(\n (bookType, bookTypeIndex) =>\n fetchFilteredBooks(bookType).length > 0 && (\n
    \n \n {BOOK_TYPE_LABELS[bookType]}\n \n\n {fetchFilteredBooks(bookType).map((bookId) => (\n
    \n updateReference(bookId, false)}\n isSelected={selectedBookId === bookId}\n handleHighlightBook={() => setHighlightedBookId(bookId)}\n handleKeyDown={handleKeyDownMenuItem}\n bookType={bookType}\n ref={(element: HTMLDivElement) => {\n if (selectedBookId === bookId) menuItemRef.current = element;\n }}\n >\n {\n setHighlightedChapter(chapterNumber);\n }}\n />\n \n
    \n ))}\n {BOOK_TYPE_ARRAY.length - 1 !== bookTypeIndex ? (\n \n ) : undefined}\n
    \n ),\n )}\n \n
    \n
    \n );\n}\n\nexport default BookChapterControl;\n","import React from 'react';\nimport { Slot } from '@radix-ui/react-slot';\nimport { cva, type VariantProps } from 'class-variance-authority';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport const buttonVariants = cva(\n 'pr-twp tw-inline-flex tw-items-center tw-justify-center tw-whitespace-nowrap tw-rounded-md tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-colors focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50',\n {\n variants: {\n variant: {\n default: 'tw-bg-primary tw-text-primary-foreground hover:tw-bg-primary/90',\n destructive: 'tw-bg-destructive tw-text-destructive-foreground hover:tw-bg-destructive/90',\n outline:\n 'tw-border tw-border-input tw-bg-background hover:tw-bg-accent hover:tw-text-accent-foreground',\n secondary: 'tw-bg-secondary tw-text-secondary-foreground hover:tw-bg-secondary/80',\n ghost: 'hover:tw-bg-accent hover:tw-text-accent-foreground',\n link: 'tw-text-primary tw-underline-offset-4 hover:tw-underline',\n },\n size: {\n default: 'tw-h-10 tw-px-4 tw-py-2',\n sm: 'tw-h-9 tw-rounded-md tw-px-3',\n lg: 'tw-h-11 tw-rounded-md tw-px-8',\n icon: 'tw-h-10 tw-w-10',\n },\n },\n defaultVariants: {\n variant: 'default',\n size: 'default',\n },\n },\n);\n\nexport interface ButtonProps\n extends React.ButtonHTMLAttributes,\n VariantProps {\n asChild?: boolean;\n}\n\nexport const Button = React.forwardRef(\n ({ className, variant, size, asChild = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'button';\n return (\n \n );\n },\n);\nButton.displayName = 'Button';\n","import React from 'react';\nimport * as LabelPrimitive from '@radix-ui/react-label';\nimport { cva, type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst labelVariants = cva(\n 'tw-text-sm tw-font-medium tw-leading-none peer-disabled:tw-cursor-not-allowed peer-disabled:tw-opacity-70',\n);\n\nexport const Label = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef & VariantProps\n>(({ className, ...props }, ref) => (\n \n));\nLabel.displayName = LabelPrimitive.Root.displayName;\n","import React from 'react';\nimport * as RadioGroupPrimitive from '@radix-ui/react-radio-group';\nimport { Circle } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst RadioGroup = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => {\n return (\n \n );\n});\nRadioGroup.displayName = RadioGroupPrimitive.Root.displayName;\n\nconst RadioGroupItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => {\n return (\n \n \n \n \n \n );\n});\nRadioGroupItem.displayName = RadioGroupPrimitive.Item.displayName;\n\nexport { RadioGroup, RadioGroupItem };\n","import React from 'react';\nimport * as PopoverPrimitive from '@radix-ui/react-popover';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Popover = PopoverPrimitive.Root;\n\nconst PopoverTrigger = PopoverPrimitive.Trigger;\n\nconst PopoverContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, align = 'center', sideOffset = 4, ...props }, ref) => (\n \n \n \n));\nPopoverContent.displayName = PopoverPrimitive.Content.displayName;\n\nexport { Popover, PopoverTrigger, PopoverContent };\n","import React from 'react';\nimport * as DialogPrimitive from '@radix-ui/react-dialog';\nimport { X } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Dialog = DialogPrimitive.Root;\n\nconst DialogTrigger = DialogPrimitive.Trigger;\n\nconst DialogPortal = DialogPrimitive.Portal;\n\nconst DialogClose = DialogPrimitive.Close;\n\nconst DialogOverlay = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nDialogOverlay.displayName = DialogPrimitive.Overlay.displayName;\n\nconst DialogContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, ...props }, ref) => (\n \n \n \n {children}\n \n \n Close\n \n \n \n));\nDialogContent.displayName = DialogPrimitive.Content.displayName;\n\nfunction DialogHeader({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nDialogHeader.displayName = 'DialogHeader';\n\nfunction DialogFooter({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nDialogFooter.displayName = 'DialogFooter';\n\nconst DialogTitle = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nDialogTitle.displayName = DialogPrimitive.Title.displayName;\n\nconst DialogDescription = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nDialogDescription.displayName = DialogPrimitive.Description.displayName;\n\nexport {\n Dialog,\n DialogPortal,\n DialogOverlay,\n DialogClose,\n DialogTrigger,\n DialogContent,\n DialogHeader,\n DialogFooter,\n DialogTitle,\n DialogDescription,\n};\n","import React from 'react';\nimport { type DialogProps } from '@radix-ui/react-dialog';\nimport { Command as CommandPrimitive } from 'cmdk';\nimport { Search } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Dialog, DialogContent } from '@/components/shadcn-ui/dialog';\n\nconst Command = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nCommand.displayName = CommandPrimitive.displayName;\n\ninterface CommandDialogProps extends DialogProps {}\n\nfunction CommandDialog({ children, ...props }: CommandDialogProps) {\n return (\n \n \n \n {children}\n \n \n \n );\n}\n\nconst CommandInput = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n
    \n \n \n
    \n));\n\nCommandInput.displayName = CommandPrimitive.Input.displayName;\n\nconst CommandList = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\n\nCommandList.displayName = CommandPrimitive.List.displayName;\n\nconst CommandEmpty = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>((props, ref) => (\n \n));\n\nCommandEmpty.displayName = CommandPrimitive.Empty.displayName;\n\nconst CommandGroup = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\n\nCommandGroup.displayName = CommandPrimitive.Group.displayName;\n\nconst CommandSeparator = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nCommandSeparator.displayName = CommandPrimitive.Separator.displayName;\n\nconst CommandItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\n\nCommandItem.displayName = CommandPrimitive.Item.displayName;\n\nfunction CommandShortcut({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nCommandShortcut.displayName = 'CommandShortcut';\n\nexport {\n Command,\n CommandDialog,\n CommandInput,\n CommandList,\n CommandEmpty,\n CommandGroup,\n CommandItem,\n CommandShortcut,\n CommandSeparator,\n};\n","import { useState } from 'react';\nimport { Check, ChevronsUpDown } from 'lucide-react';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport { Popover, PopoverContent, PopoverTrigger } from '@/components/shadcn-ui/popover';\nimport {\n Command,\n CommandEmpty,\n CommandInput,\n CommandItem,\n CommandList,\n} from '@/components/shadcn-ui/command';\nimport { PopoverProps } from '@radix-ui/react-popover';\n\nexport type ComboBoxLabelOption = { label: string };\nexport type ComboBoxOption = string | number | ComboBoxLabelOption;\n\nexport type ComboBoxProps = {\n /** Optional unique identifier */\n id?: string;\n /** Text label title for combobox */\n /** List of available options for the dropdown menu */\n options?: readonly T[];\n /** Additional css classes to help with unique styling of the combo box button */\n buttonClassName?: string;\n /** Additional css classes to help with unique styling of the combo box popover */\n popoverContentClassName?: string;\n /**\n * The selected value that the combo box currently holds. Must be shallow equal to one of the\n * options entries.\n */\n value?: T;\n /** Triggers when content of textfield is changed */\n onChange?: (newValue: T) => void;\n /** Used to determine the string value for a given option. */\n getOptionLabel?: (option: ComboBoxOption) => string;\n /** Text displayed on button if `value` is undefined */\n buttonPlaceholder?: string;\n /** Placeholder text for text field */\n textPlaceholder?: string;\n /** Text to display when no options match input */\n commandEmptyMessage?: string;\n /** Variant of button */\n buttonVariant?: ButtonProps['variant'];\n /** Text direction ltr or rtl */\n dir?: Direction;\n /** Optional boolean to set if trigger should be disabled */\n isDisabled?: boolean;\n} & PopoverProps;\n\ntype Direction = 'ltr' | 'rtl';\n\nfunction getOptionLabelDefault(option: ComboBoxOption): string {\n if (typeof option === 'string') {\n return option;\n }\n if (typeof option === 'number') {\n return option.toString();\n }\n return option.label;\n}\n\n/**\n * Autocomplete input and command palette with a list of suggestions.\n *\n * Thanks to Shadcn for heavy inspiration and documentation\n * https://ui.shadcn.com/docs/components/combobox\n */\nfunction ComboBox({\n id,\n options = [],\n buttonClassName,\n popoverContentClassName,\n value,\n onChange = () => {},\n getOptionLabel = getOptionLabelDefault,\n buttonPlaceholder = '',\n textPlaceholder = '',\n commandEmptyMessage = 'No option found',\n buttonVariant = 'outline',\n dir = 'ltr',\n isDisabled = false,\n ...props\n}: ComboBoxProps) {\n const [open, setOpen] = useState(false);\n\n return (\n \n \n \n \n {value ? getOptionLabel(value) : buttonPlaceholder}\n \n \n \n \n \n \n \n {commandEmptyMessage}\n \n {options.map((option) => (\n {\n onChange(option);\n setOpen(false);\n }}\n >\n \n {getOptionLabel(option)}\n \n ))}\n \n \n \n \n );\n}\n\nexport default ComboBox;\n","import { useMemo } from 'react';\nimport ComboBox from '@/components/basics/combo-box.component';\nimport { Label } from '@/components/shadcn-ui/label';\n\nexport type ChapterRangeSelectorProps = {\n startChapter: number;\n endChapter: number;\n handleSelectStartChapter: (chapter: number) => void;\n handleSelectEndChapter: (chapter: number) => void;\n isDisabled?: boolean;\n chapterCount: number;\n};\n\nexport default function ChapterRangeSelector({\n startChapter,\n endChapter,\n handleSelectStartChapter,\n handleSelectEndChapter,\n isDisabled = false,\n chapterCount,\n}: ChapterRangeSelectorProps) {\n const chapterOptions = useMemo(\n () => Array.from({ length: chapterCount }, (_, index) => index + 1),\n [chapterCount],\n );\n\n const onChangeStartChapter = (value: number) => {\n handleSelectStartChapter(value);\n if (value > endChapter) {\n handleSelectEndChapter(value);\n }\n };\n\n const onChangeEndChapter = (value: number) => {\n handleSelectEndChapter(value);\n if (value < startChapter) {\n handleSelectStartChapter(value);\n }\n };\n\n return (\n <>\n \n option.toString()}\n value={startChapter}\n />\n\n \n option.toString()}\n value={endChapter}\n />\n \n );\n}\n","import { Button } from '@/components/shadcn-ui/button';\nimport { Label } from '@/components/shadcn-ui/label';\nimport { RadioGroup, RadioGroupItem } from '@/components/shadcn-ui/radio-group';\nimport { Canon } from '@sillsdev/scripture';\nimport { LocalizedStringValue } from 'platform-bible-utils';\nimport { useState } from 'react';\nimport ChapterRangeSelector, {\n ChapterRangeSelectorProps,\n} from '../basics/chapter-range-selector.component';\n\nexport enum BookSelectionMode {\n CURRENT_BOOK = 'current book',\n CHOOSE_BOOKS = 'choose books',\n}\n\n/**\n * Object containing all keys used for localization in this component. If you're using this\n * component in an extension, you can pass it into the useLocalizedStrings hook to easily obtain the\n * localized strings and pass them into the localizedStrings prop of this component\n */\nexport const BOOK_SELECTOR_STRING_KEYS = Object.freeze([\n '%webView_bookSelector_currentBook%',\n '%webView_bookSelector_choose%',\n '%webView_bookSelector_chooseBooks%',\n] as const);\n\nexport type BookSelectorLocalizedStrings = {\n [localizedInventoryKey in (typeof BOOK_SELECTOR_STRING_KEYS)[number]]?: LocalizedStringValue;\n};\n\n/**\n * Gets the localized value for the provided key\n *\n * @param strings Object containing localized string\n * @param key Key for a localized string\n * @returns The localized value for the provided key, if available. Returns the key if no localized\n * value is available\n */\nconst localizeString = (\n strings: BookSelectorLocalizedStrings,\n key: keyof BookSelectorLocalizedStrings,\n) => {\n return strings[key] ?? key;\n};\n\ntype BookSelectorProps = ChapterRangeSelectorProps & {\n handleBookSelectionModeChange: (newMode: BookSelectionMode) => void;\n currentBookName: string;\n onSelectBooks: () => void;\n selectedBookIds: string[];\n localizedStrings: BookSelectorLocalizedStrings;\n};\n\nexport default function BookSelector({\n handleBookSelectionModeChange,\n currentBookName,\n onSelectBooks,\n selectedBookIds,\n chapterCount,\n endChapter,\n handleSelectEndChapter,\n startChapter,\n handleSelectStartChapter,\n localizedStrings,\n}: BookSelectorProps) {\n const currentBookText = localizeString(localizedStrings, '%webView_bookSelector_currentBook%');\n const chooseText = localizeString(localizedStrings, '%webView_bookSelector_choose%');\n const chooseBooksText = localizeString(localizedStrings, '%webView_bookSelector_chooseBooks%');\n\n const [bookSelectionMode, setBookSelectionMode] = useState(\n BookSelectionMode.CURRENT_BOOK,\n );\n\n const onSelectionModeChange = (newMode: BookSelectionMode) => {\n setBookSelectionMode(newMode);\n handleBookSelectionModeChange(newMode);\n };\n\n return (\n onSelectionModeChange(value as BookSelectionMode)}\n >\n
    \n
    \n
    \n \n \n
    \n \n
    \n \n
    \n
    \n
    \n
    \n \n \n
    \n \n onSelectBooks()}\n >\n {chooseText}\n \n
    \n
    \n \n );\n}\n","import { DropdownMenuTrigger } from '@radix-ui/react-dropdown-menu';\nimport { FilterIcon } from 'lucide-react';\nimport { Table } from '@tanstack/react-table';\n\nimport { Button } from '@/components/shadcn-ui/button';\nimport {\n DropdownMenu,\n DropdownMenuCheckboxItem,\n DropdownMenuContent,\n DropdownMenuLabel,\n DropdownMenuSeparator,\n} from '@/components/shadcn-ui/dropdown-menu';\n\ninterface DataTableViewOptionsProps {\n table: Table;\n}\n\nfunction DataTableViewOptions({ table }: DataTableViewOptionsProps) {\n return (\n \n \n \n \n \n Toggle columns\n \n {table\n .getAllColumns()\n .filter((column) => column.getCanHide())\n .map((column) => {\n return (\n column.toggleVisibility(!!value)}\n >\n {column.id}\n \n );\n })}\n \n \n );\n}\n\nexport default DataTableViewOptions;\n","import React from 'react';\nimport * as SelectPrimitive from '@radix-ui/react-select';\nimport { Check, ChevronDown, ChevronUp } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Select = SelectPrimitive.Root;\n\nconst SelectGroup = SelectPrimitive.Group;\n\nconst SelectValue = SelectPrimitive.Value;\n\nconst SelectTrigger = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, ...props }, ref) => (\n span]:tw-line-clamp-1',\n className,\n )}\n {...props}\n >\n {children}\n \n \n \n \n));\nSelectTrigger.displayName = SelectPrimitive.Trigger.displayName;\n\nconst SelectScrollUpButton = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n));\nSelectScrollUpButton.displayName = SelectPrimitive.ScrollUpButton.displayName;\n\nconst SelectScrollDownButton = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n));\nSelectScrollDownButton.displayName = SelectPrimitive.ScrollDownButton.displayName;\n\nconst SelectContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, position = 'popper', ...props }, ref) => (\n \n \n \n \n {children}\n \n \n \n \n));\nSelectContent.displayName = SelectPrimitive.Content.displayName;\n\nconst SelectLabel = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSelectLabel.displayName = SelectPrimitive.Label.displayName;\n\nconst SelectItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, ...props }, ref) => (\n \n \n \n \n \n \n\n {children}\n \n));\nSelectItem.displayName = SelectPrimitive.Item.displayName;\n\nconst SelectSeparator = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSelectSeparator.displayName = SelectPrimitive.Separator.displayName;\n\nexport {\n Select,\n SelectGroup,\n SelectValue,\n SelectTrigger,\n SelectContent,\n SelectLabel,\n SelectItem,\n SelectSeparator,\n SelectScrollUpButton,\n SelectScrollDownButton,\n};\n","import { ChevronLeftIcon, ChevronRightIcon, ArrowLeftIcon, ArrowRightIcon } from 'lucide-react';\nimport { Table } from '@tanstack/react-table';\n\nimport { Button } from '@/components/shadcn-ui/button';\nimport {\n Select,\n SelectContent,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\n\ninterface DataTablePaginationProps {\n table: Table;\n}\n\nfunction DataTablePagination({ table }: DataTablePaginationProps) {\n return (\n
    \n
    \n
    \n {table.getFilteredSelectedRowModel().rows.length} of{' '}\n {table.getFilteredRowModel().rows.length} row(s) selected\n
    \n
    \n

    Rows per page

    \n {\n table.setPageSize(Number(value));\n }}\n >\n \n \n \n \n {[10, 20, 30, 40, 50].map((pageSize) => (\n \n {pageSize}\n \n ))}\n \n \n
    \n
    \n Page {table.getState().pagination.pageIndex + 1} of {table.getPageCount()}\n
    \n
    \n table.setPageIndex(0)}\n disabled={!table.getCanPreviousPage()}\n >\n Go to first page\n \n \n table.previousPage()}\n disabled={!table.getCanPreviousPage()}\n >\n Go to previous page\n \n \n table.nextPage()}\n disabled={!table.getCanNextPage()}\n >\n Go to next page\n \n \n table.setPageIndex(table.getPageCount() - 1)}\n disabled={!table.getCanNextPage()}\n >\n Go to last page\n \n \n
    \n
    \n
    \n );\n}\n\nexport default DataTablePagination;\n","import React from 'react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Table = React.forwardRef<\n HTMLTableElement,\n React.HTMLAttributes & { stickyHeader?: boolean }\n>(({ className, stickyHeader, ...props }, ref) => (\n
    \n \n
    \n));\nTable.displayName = 'Table';\n\nconst TableHeader = React.forwardRef<\n HTMLTableSectionElement,\n React.HTMLAttributes & { stickyHeader?: boolean }\n>(({ className, stickyHeader, ...props }, ref) => (\n \n));\nTableHeader.displayName = 'TableHeader';\n\nconst TableBody = React.forwardRef<\n HTMLTableSectionElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableBody.displayName = 'TableBody';\n\nconst TableFooter = React.forwardRef<\n HTMLTableSectionElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n tr]:last:tw-border-b-0', className)}\n {...props}\n />\n));\nTableFooter.displayName = 'TableFooter';\n\nconst TableRow = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nTableRow.displayName = 'TableRow';\n\nconst TableHead = React.forwardRef<\n HTMLTableCellElement,\n React.ThHTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableHead.displayName = 'TableHead';\n\nconst TableCell = React.forwardRef<\n HTMLTableCellElement,\n React.TdHTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableCell.displayName = 'TableCell';\n\nconst TableCaption = React.forwardRef<\n HTMLTableCaptionElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableCaption.displayName = 'TableCaption';\n\nexport { Table, TableHeader, TableBody, TableFooter, TableHead, TableRow, TableCell, TableCaption };\n","import { useState } from 'react';\n\nimport {\n ColumnFiltersState,\n flexRender,\n getCoreRowModel,\n getFilteredRowModel,\n getPaginationRowModel,\n getSortedRowModel,\n SortingState,\n ColumnDef as TSColumnDef,\n Row as TSRow,\n RowSelectionState as TSRowSelectionState,\n SortDirection as TSSortDirection,\n Table as TSTable,\n useReactTable,\n VisibilityState,\n} from '@tanstack/react-table';\n\nimport DataTableViewOptions from '@/components/advanced/data-table/data-table-column-toggle.component';\nimport DataTablePagination from '@/components/advanced/data-table/data-table-pagination.component';\nimport { Button } from '@/components/shadcn-ui/button';\nimport {\n Table,\n TableBody,\n TableCell,\n TableHead,\n TableHeader,\n TableRow,\n} from '@/components/shadcn-ui/table';\n\nexport type ColumnDef = TSColumnDef;\nexport type RowContents = TSRow;\nexport type TableContents = TSTable;\nexport type SortDirection = TSSortDirection;\nexport type RowSelectionState = TSRowSelectionState;\n\ninterface DataTableProps {\n columns: ColumnDef[];\n data: TData[];\n enablePagination?: boolean;\n showPaginationControls?: boolean;\n showColumnVisibilityControls?: boolean;\n stickyHeader?: boolean;\n onRowClickHandler?: (row: RowContents, table: TableContents) => void;\n}\n\n/**\n * Feature-rich table component that infuses our basic shadcn-based Table component with features\n * from TanStack's React Table library\n */\nfunction DataTable({\n columns,\n data,\n enablePagination = false,\n showPaginationControls = false,\n showColumnVisibilityControls = false,\n stickyHeader = false,\n onRowClickHandler = () => {},\n}: DataTableProps) {\n const [sorting, setSorting] = useState([]);\n const [columnFilters, setColumnFilters] = useState([]);\n const [columnVisibility, setColumnVisibility] = useState({});\n const [rowSelection, setRowSelection] = useState({});\n\n const table = useReactTable({\n data,\n columns,\n getCoreRowModel: getCoreRowModel(),\n ...(enablePagination && { getPaginationRowModel: getPaginationRowModel() }),\n onSortingChange: setSorting,\n getSortedRowModel: getSortedRowModel(),\n onColumnFiltersChange: setColumnFilters,\n getFilteredRowModel: getFilteredRowModel(),\n onColumnVisibilityChange: setColumnVisibility,\n onRowSelectionChange: setRowSelection,\n state: {\n sorting,\n columnFilters,\n columnVisibility,\n rowSelection,\n },\n });\n\n return (\n
    \n {showColumnVisibilityControls && }\n \n \n {table.getHeaderGroups().map((headerGroup) => (\n \n {headerGroup.headers.map((header) => {\n return (\n \n {header.isPlaceholder\n ? undefined\n : flexRender(header.column.columnDef.header, header.getContext())}\n \n );\n })}\n \n ))}\n \n \n {table.getRowModel().rows?.length ? (\n table.getRowModel().rows.map((row) => (\n onRowClickHandler(row, table)}\n key={row.id}\n data-state={row.getIsSelected() && 'selected'}\n >\n {row.getVisibleCells().map((cell) => (\n \n {flexRender(cell.column.columnDef.cell, cell.getContext())}\n \n ))}\n \n ))\n ) : (\n \n \n No results.\n \n \n )}\n \n
    \n {enablePagination && (\n
    \n table.previousPage()}\n disabled={!table.getCanPreviousPage()}\n >\n Previous\n \n table.nextPage()}\n disabled={!table.getCanNextPage()}\n >\n Next\n \n
    \n )}\n {enablePagination && showPaginationControls && }\n
    \n );\n}\n\nexport default DataTable;\n","import {\n Table,\n TableBody,\n TableCell,\n TableHead,\n TableHeader,\n TableRow,\n} from '@/components/shadcn-ui/table';\nimport { Canon } from '@sillsdev/scripture';\nimport { deepEqual, LanguageStrings, ScriptureReference } from 'platform-bible-utils';\nimport { useMemo } from 'react';\nimport { InventoryItemOccurrence } from './inventory-utils';\n\n/** Props for the OccurrencesTable component */\ntype OccurrencesTableProps = {\n /** Data that contains scriptures references and snippets of scripture */\n occurrenceData: InventoryItemOccurrence[];\n /** Callback function that is executed when the scripture reference is changed */\n setScriptureReference: (scriptureReference: ScriptureReference) => void;\n /**\n * Object with all localized strings that the OccurrencesTable needs to work well across multiple\n * languages\n */\n localizedStrings: LanguageStrings;\n};\n\n/**\n * Table that shows occurrences of specified inventory item(s). The first column shows the related\n * scripture reference. The second column shows the snippet of scripture that contains the specified\n * inventory item\n */\nfunction OccurrencesTable({\n occurrenceData,\n setScriptureReference,\n localizedStrings,\n}: OccurrencesTableProps) {\n const referenceHeaderText =\n localizedStrings['%webView_inventory_occurrences_table_header_reference%'];\n const occurrenceHeaderText =\n localizedStrings['%webView_inventory_occurrences_table_header_occurrence%'];\n\n const occurrences: InventoryItemOccurrence[] = useMemo(() => {\n const uniqueOccurrences: InventoryItemOccurrence[] = [];\n\n occurrenceData.forEach((occurrence) => {\n if (!uniqueOccurrences.some((uniqueOccurrence) => deepEqual(uniqueOccurrence, occurrence))) {\n uniqueOccurrences.push(occurrence);\n }\n });\n\n return uniqueOccurrences;\n }, [occurrenceData]);\n\n return (\n \n \n \n {referenceHeaderText}\n {occurrenceHeaderText}\n \n \n \n {occurrences.length > 0 &&\n occurrences.map((occurrence) => (\n {\n setScriptureReference(occurrence.reference);\n }}\n >\n {`${Canon.bookNumberToEnglishName(occurrence.reference.bookNum)} ${occurrence.reference.chapterNum}:${occurrence.reference.verseNum}`}\n {occurrence.text}\n \n ))}\n \n
    \n );\n}\n\nexport default OccurrencesTable;\n","import React from 'react';\nimport * as CheckboxPrimitive from '@radix-ui/react-checkbox';\nimport { Check } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Checkbox = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n \n \n));\nCheckbox.displayName = CheckboxPrimitive.Root.displayName;\n\nexport default Checkbox;\n","import { Canon } from '@sillsdev/scripture';\nimport { ScriptureReference } from 'platform-bible-utils';\n\n/* #region Types */\n\n/**\n * Status of items that appear in inventories. 'approved' and 'unapproved' items are defined in the\n * project's `Settings.xml`. All other items are defined as 'unknown'\n */\nexport type Status = 'approved' | 'unapproved' | 'unknown';\n\n/** Occurrence of item in inventory. Primarily used by table that shows occurrences */\nexport type InventoryItemOccurrence = {\n /** Reference to scripture where the item appears */\n reference: ScriptureReference;\n /** Snippet of scripture that contains the occurrence */\n text: string;\n};\n\n/** Data structure that contains all information on an item that is shown in an inventory */\nexport type InventoryTableData = {\n /**\n * The item (e.g. a character in the characters inventory, a marker in the marker inventory) In\n * most cases the array will only have one element. In case of additional items (e.g. the\n * preceding marker in the markers check), the primary item should be stored in the first index.\n * To show additional items in the inventory, make sure to configure the `additionalItemsLabels`\n * prop for the Inventory component\n */\n items: string[];\n /** The number of times this item occurs in the selected scope */\n count: number;\n /** The status of this item (see documentation for `Status` type for more information) */\n status: Status;\n /** Occurrences of this item in the scripture text for the selected scope */\n occurrences: InventoryItemOccurrence[];\n};\n\n/* #endregion */\n\n/* #region Functions */\n\n/**\n * Splits USFM string into shorter line-like segments\n *\n * @param text A single (likely very large) USFM string\n * @returns An array containing the input text, split into shorter segments\n */\nexport const getLinesFromUSFM = (text: string) => {\n // Splits on (CR)LF, CR, \\v, \\c and \\id\n return text.split(/(?:\\r?\\n|\\r)|(?=(?:\\\\(?:v|c|id)))/g);\n};\n\n/**\n * Extracts chapter or verse number from USFM strings that start with a \\c or \\v marker\n *\n * @param text USFM string that is expected to start with \\c or \\v marker\n * @returns Chapter or verse number if one is found. Else returns 0.\n */\nexport const getNumberFromUSFM = (text: string): number | undefined => {\n // Captures all digits that follow \\v or \\c markers followed by whitespace located at the start of a string\n const regex = /^\\\\[vc]\\s+(\\d+)/;\n const match = text.match(regex);\n\n if (match) {\n return +match[1];\n }\n return undefined;\n};\n\n/**\n * Gets book ID from USFM string that starts with the \\id marker, and returns book number for it\n *\n * @param text USFM string that is expected to start with \\id marker\n * @returns Book number corresponding to the \\id marker in the input text. Returns 0 if no marker is\n * found or the marker is not valid\n */\nexport const getBookNumFromId = (text: string): number => {\n // Captures all digits that follow an \\id marker followed by whitespace located at the start of a string\n const match = text.match(/^\\\\id\\s+([A-Za-z]+)/);\n if (match) {\n return Canon.bookIdToNumber(match[1]);\n }\n return 0;\n};\n\n/**\n * Gets the status for an item, typically used in the Inventory component\n *\n * @param item The item for which the status is being requested\n * @param approvedItems Array of approved items, typically as defined in `Settings.xml`\n * @param unapprovedItems Array of unapproved items, typically as defined in `Settings.xml`\n * @returns The status for the specified item\n */\nexport const getStatusForItem = (\n item: string,\n approvedItems: string[],\n unapprovedItems: string[],\n): Status => {\n if (unapprovedItems.includes(item)) return 'unapproved';\n if (approvedItems.includes(item)) return 'approved';\n return 'unknown';\n};\n\n/* #endregion */\n","import React from 'react';\nimport * as TogglePrimitive from '@radix-ui/react-toggle';\nimport { cva, type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst toggleVariants = cva(\n 'pr-twp tw-inline-flex tw-items-center tw-justify-center tw-rounded-md tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-colors hover:tw-bg-muted hover:tw-text-muted-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50 data-[state=on]:tw-bg-accent data-[state=on]:tw-text-accent-foreground',\n {\n variants: {\n variant: {\n default: 'tw-bg-transparent',\n outline:\n 'tw-border tw-border-input tw-bg-transparent hover:tw-bg-accent hover:tw-text-accent-foreground',\n },\n size: {\n default: 'tw-h-10 tw-px-3',\n sm: 'tw-h-9 tw-px-2.5',\n lg: 'tw-h-11 tw-px-5',\n },\n },\n defaultVariants: {\n variant: 'default',\n size: 'default',\n },\n },\n);\n\nconst Toggle = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef & VariantProps\n>(({ className, variant, size, ...props }, ref) => (\n \n));\n\nToggle.displayName = TogglePrimitive.Root.displayName;\n\nexport { Toggle, toggleVariants };\n","import React from 'react';\nimport * as ToggleGroupPrimitive from '@radix-ui/react-toggle-group';\nimport { type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { toggleVariants } from '@/components/shadcn-ui/toggle';\n\nconst ToggleGroupContext = React.createContext>({\n size: 'default',\n variant: 'default',\n});\n\nconst ToggleGroup = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef &\n VariantProps\n>(({ className, variant, size, children, ...props }, ref) => (\n \n \n {children}\n \n \n));\n\nToggleGroup.displayName = ToggleGroupPrimitive.Root.displayName;\n\nconst ToggleGroupItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef &\n VariantProps\n>(({ className, children, variant, size, ...props }, ref) => {\n const context = React.useContext(ToggleGroupContext);\n\n return (\n \n {children}\n \n );\n});\n\nToggleGroupItem.displayName = ToggleGroupPrimitive.Item.displayName;\n\nexport { ToggleGroup, ToggleGroupItem };\n","import { ColumnDef, SortDirection } from '@/components/advanced/data-table/data-table.component';\nimport { Button } from '@/components/shadcn-ui/button';\nimport { ToggleGroup, ToggleGroupItem } from '@/components/shadcn-ui/toggle-group';\nimport {\n ArrowDownIcon,\n ArrowUpDownIcon,\n ArrowUpIcon,\n CircleCheckIcon,\n CircleHelpIcon,\n CircleXIcon,\n} from 'lucide-react';\nimport { ReactNode } from 'react';\nimport { InventoryTableData, Status } from './inventory-utils';\n\n/**\n * Gets an icon that indicates the current sorting direction based on the provided input\n *\n * @param sortDirection Sorting direction. Can be ascending ('asc'), descending ('desc') or false (\n * i.e. not sorted)\n * @returns The appropriate sorting icon for the provided sorting direction\n */\nconst getSortingIcon = (sortDirection: false | SortDirection): ReactNode => {\n if (sortDirection === 'asc') {\n return ;\n }\n if (sortDirection === 'desc') {\n return ;\n }\n return ;\n};\n\n/**\n * Function that creates the item column for inventories\n *\n * @param itemLabel Localized label for the item column (e.g. 'Character', 'Repeated Word', etc.)\n * @returns Column that shows the inventory items. Should be used with the DataTable component\n */\nexport const inventoryItemColumn = (itemLabel: string): ColumnDef => {\n return {\n accessorKey: 'item',\n accessorFn: (row: InventoryTableData) => row.items[0],\n header: ({ column }) => (\n \n ),\n };\n};\n\n/**\n * Function that creates the additional item columns for inventories\n *\n * @param additionalItemLabel Localized label for the additional item column (e.g. 'Preceding\n * Marker')\n * @param additionalItemIndex Index that locates the desired item in the items array of the\n * inventory\n * @returns Column that shows additional inventory items. Should be used with the DataTable\n * component\n */\nexport const inventoryAdditionalItemColumn = (\n additionalItemLabel: string,\n additionalItemIndex: number,\n): ColumnDef => {\n return {\n accessorKey: `item${additionalItemIndex}`,\n accessorFn: (row: InventoryTableData) => row.items[additionalItemIndex],\n header: ({ column }) => (\n \n ),\n };\n};\n\n/**\n * Function that creates the count column for inventories. Should be used with the DataTable\n * component.\n *\n * @param itemLabel Localized label for the count column\n * @returns Column that shows the number of occurrences of the related inventory items\n */\nexport const inventoryCountColumn = (countLabel: string): ColumnDef => {\n return {\n accessorKey: 'count',\n header: ({ column }) => (\n
    \n \n
    \n ),\n cell: ({ row }) =>
    {row.getValue('count')}
    ,\n };\n};\n\n/**\n * Function that updates project settings when status for item(s) changes\n *\n * @param changedItems Array of items for which the status is being updated\n * @param newStatus The status that the items are being given\n * @param approvedItems Array of currently approved items\n * @param onApprovedItemsChange Callback function that stores the updated list of approved items\n * @param unapprovedItems Array of currently unapproved items\n * @param onUnapprovedItemsChange Callback function that stores the updated list of unapproved items\n */\nconst statusChangeHandler = (\n changedItems: string[],\n newStatus: Status,\n approvedItems: string[],\n onApprovedItemsChange: (items: string[]) => void,\n unapprovedItems: string[],\n onUnapprovedItemsChange: (items: string[]) => void,\n) => {\n let newApprovedItems: string[] = [...approvedItems];\n changedItems.forEach((item) => {\n if (newStatus === 'approved') {\n if (!newApprovedItems.includes(item)) {\n newApprovedItems.push(item);\n }\n } else {\n newApprovedItems = newApprovedItems.filter((validItem) => validItem !== item);\n }\n });\n onApprovedItemsChange(newApprovedItems);\n\n let newUnapprovedItems: string[] = [...unapprovedItems];\n changedItems.forEach((item) => {\n if (newStatus === 'unapproved') {\n if (!newUnapprovedItems.includes(item)) {\n newUnapprovedItems.push(item);\n }\n } else {\n newUnapprovedItems = newUnapprovedItems.filter((unapprovedItem) => unapprovedItem !== item);\n }\n });\n onUnapprovedItemsChange(newUnapprovedItems);\n};\n\n/**\n * Function that creates the status column for inventories. Should be used with the DataTable\n * component.\n *\n * @param statusLabel Localized label for the status column\n * @param approvedItems Array of approved items, typically as defined in `Settings.xml`\n * @param onApprovedItemsChange Callback function that stores the updated list of approved items\n * @param unapprovedItems Array of unapproved items, typically as defined in `Settings.xml`\n * @param onUnapprovedItemsChange Callback function that stores the updated list of unapproved items\n * @returns Column that shows the status buttons for the related inventory item. The button for the\n * current status of the item is selected\n */\nexport const inventoryStatusColumn = (\n statusLabel: string,\n approvedItems: string[],\n onApprovedItemsChange: (items: string[]) => void,\n unapprovedItems: string[],\n onUnapprovedItemsChange: (items: string[]) => void,\n): ColumnDef => {\n return {\n accessorKey: 'status',\n header: ({ column }) => {\n return (\n
    \n \n
    \n );\n },\n cell: ({ row }) => {\n const status: Status = row.getValue('status');\n const item: string = row.getValue('item');\n return (\n \n \n statusChangeHandler(\n [item],\n 'approved',\n approvedItems,\n onApprovedItemsChange,\n unapprovedItems,\n onUnapprovedItemsChange,\n )\n }\n value=\"approved\"\n >\n \n \n \n statusChangeHandler(\n [item],\n 'unapproved',\n approvedItems,\n onApprovedItemsChange,\n unapprovedItems,\n onUnapprovedItemsChange,\n )\n }\n value=\"unapproved\"\n >\n \n \n \n statusChangeHandler(\n [item],\n 'unknown',\n approvedItems,\n onApprovedItemsChange,\n unapprovedItems,\n onUnapprovedItemsChange,\n )\n }\n value=\"unknown\"\n >\n \n \n \n );\n },\n };\n};\n","import DataTable, {\n ColumnDef,\n RowContents,\n RowSelectionState,\n TableContents,\n} from '@/components/advanced/data-table/data-table.component';\nimport OccurrencesTable from '@/components/advanced/inventory/occurrences-table.component';\nimport Checkbox from '@/components/shadcn-ui/checkbox';\nimport { Input } from '@/components/shadcn-ui/input';\nimport { Label } from '@/components/shadcn-ui/label';\nimport {\n Select,\n SelectContent,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\nimport {\n deepEqual,\n LocalizedStringValue,\n ScriptureReference,\n substring,\n} from 'platform-bible-utils';\nimport { useEffect, useMemo, useState } from 'react';\nimport {\n getBookNumFromId,\n getLinesFromUSFM,\n getNumberFromUSFM,\n getStatusForItem,\n InventoryItemOccurrence,\n InventoryTableData,\n Status,\n} from './inventory-utils';\nimport { inventoryAdditionalItemColumn } from './inventory-columns';\n\n/**\n * Object containing all keys used for localization in this component. If you're using this\n * component in an extension, you can pass it into the useLocalizedStrings hook to easily obtain the\n * localized strings and pass them into the localizedStrings prop of this component\n */\nexport const INVENTORY_STRING_KEYS = Object.freeze([\n '%webView_inventory_all%',\n '%webView_inventory_approved%',\n '%webView_inventory_unapproved%',\n '%webView_inventory_unknown%',\n '%webView_inventory_scope_currentBook%',\n '%webView_inventory_scope_chapter%',\n '%webView_inventory_scope_verse%',\n '%webView_inventory_filter_text%',\n '%webView_inventory_show_additional_items%',\n '%webView_inventory_occurrences_table_header_reference%',\n '%webView_inventory_occurrences_table_header_occurrence%',\n] as const);\n\nexport type InventoryLocalizedStrings = {\n [localizedInventoryKey in (typeof INVENTORY_STRING_KEYS)[number]]?: LocalizedStringValue;\n};\n\n/** Scope of scripture that the inventory can operate on */\nexport type Scope = 'book' | 'chapter' | 'verse';\n\n/** Status values that the status filter can select from */\ntype StatusFilter = Status | 'all';\n\n/** Text labels for the inventory columns and the control components of additional inventory items */\ntype AdditionalItemsLabels = {\n checkboxText?: string;\n tableHeaders?: string[];\n};\n\n/**\n * Filters data that is shown in the DataTable section of the Inventory\n *\n * @param itemData All inventory items and their related information\n * @param statusFilter Allows filtering by status (i.e. show all items, or only items that are\n * 'approved', 'unapproved' or 'unknown')\n * @param textFilter Allows filtering by text. All items that include the filter text will be\n * selected.\n * @returns Array of items and their related information that are matched by the specified filters\n */\nconst filterItemData = (\n itemData: InventoryTableData[],\n statusFilter: StatusFilter,\n textFilter: string,\n): InventoryTableData[] => {\n let filteredItemData: InventoryTableData[] = itemData;\n\n if (statusFilter !== 'all') {\n filteredItemData = filteredItemData.filter(\n (item) =>\n (statusFilter === 'approved' && item.status === 'approved') ||\n (statusFilter === 'unapproved' && item.status === 'unapproved') ||\n (statusFilter === 'unknown' && item.status === 'unknown'),\n );\n }\n\n if (textFilter !== '')\n filteredItemData = filteredItemData.filter((item) => item.items[0].includes(textFilter));\n\n return filteredItemData;\n};\n\n/**\n * Turns array of strings into array of inventory items, along with their count and status\n *\n * @param text The source scripture text that is searched for inventory items\n * @param scriptureRef The scripture reference that the application is currently set to\n * @param approvedItems Array of approved items, typically as defined in `Settings.xml`\n * @param unapprovedItems Array of unapproved items, typically as defined in `Settings.xml`\n * @param itemRegex Regular expression that describes what items this Inventory should extract from\n * the provided scripture text\n * @returns Array of inventory items, along with their count and status\n */\nconst createTableData = (\n text: string | undefined,\n scriptureRef: ScriptureReference,\n approvedItems: string[],\n unapprovedItems: string[],\n itemRegex: RegExp,\n): InventoryTableData[] => {\n if (!text) return [];\n\n const tableData: InventoryTableData[] = [];\n\n let currentBook: number | undefined = scriptureRef.bookNum;\n let currentChapter: number | undefined = scriptureRef.chapterNum;\n let currentVerse: number | undefined = scriptureRef.verseNum;\n\n const lines = getLinesFromUSFM(text);\n\n lines.forEach((line: string) => {\n if (line.startsWith('\\\\id')) {\n currentBook = getBookNumFromId(line);\n currentChapter = 0;\n currentVerse = 0;\n }\n if (line.startsWith('\\\\c')) {\n currentChapter = getNumberFromUSFM(line);\n currentVerse = 0;\n }\n if (line.startsWith('\\\\v')) {\n currentVerse = getNumberFromUSFM(line);\n if (currentChapter === 0) {\n currentChapter = scriptureRef.chapterNum;\n }\n }\n\n let match: RegExpExecArray | undefined = itemRegex.exec(line) ?? undefined;\n while (match) {\n const items: string[] = [];\n match.forEach((item) => items.push(item));\n const itemIndex = match.index;\n const existingItem = tableData.find((tableEntry) => deepEqual(tableEntry.items, items));\n const newReference: InventoryItemOccurrence = {\n reference: {\n bookNum: currentBook !== undefined ? currentBook : -1,\n chapterNum: currentChapter !== undefined ? currentChapter : -1,\n verseNum: currentVerse !== undefined ? currentVerse : -1,\n },\n text: substring(line, Math.max(0, itemIndex - 25), Math.min(itemIndex + 25, line.length)),\n };\n if (existingItem) {\n existingItem.count += 1;\n existingItem.occurrences.push(newReference);\n } else {\n const newItem: InventoryTableData = {\n items,\n count: 1,\n status: getStatusForItem(items[0], approvedItems, unapprovedItems),\n occurrences: [newReference],\n };\n tableData.push(newItem);\n }\n\n match = itemRegex.exec(line) ?? undefined;\n }\n });\n\n return tableData;\n};\n\n/**\n * Gets the localized value for the provided key\n *\n * @param strings Object containing localized string\n * @param key Key for a localized string\n * @returns The localized value for the provided key, if available. Returns the key if no localized\n * value is available\n */\nconst localizeString = (\n strings: InventoryLocalizedStrings,\n key: keyof InventoryLocalizedStrings,\n) => {\n return strings[key] ?? key;\n};\n\n/** Props for the Inventory component */\ntype InventoryProps = {\n /** The scripture reference that the application is currently set to */\n scriptureReference: ScriptureReference;\n /** Callback function that is executed when the scripture reference is changed */\n setScriptureReference: (scriptureReference: ScriptureReference) => void;\n /**\n * Object with all localized strings that the Inventory needs to work well across multiple\n * languages. When using this component with Platform.Bible, you can import\n * `INVENTORY_STRING_KEYS` from this library, pass it in to the Platform's localization hook, and\n * pass the localized keys that are returned by the hook into this prop.\n */\n localizedStrings: InventoryLocalizedStrings;\n /**\n * The logic that finds the desired items in the source text. This can either be a Regular\n * expression that captures one or multiple items (preferred), or a custom function that builds\n * and return an InventoryDataTable[] manually. Note: In case the logic captures more than one\n * item (i.e. InventoryTableData.items has a length greater than 1), you must provide text labels\n * for the related columns and control elements to show by setting the `additionalItemsLabels`\n * prop\n */\n extractItems:\n | RegExp\n | ((\n text: string | undefined,\n scriptureRef: ScriptureReference,\n approvedItems: string[],\n unapprovedItems: string[],\n ) => InventoryTableData[]);\n /**\n * Text labels for control elements and additional column headers in case your Inventory has more\n * than one item to show (e.g. The 'Preceding Marker' in the Markers Inventory)\n */\n additionalItemsLabels?: AdditionalItemsLabels;\n /** Array of approved items, typically as defined in `Settings.xml` */\n approvedItems: string[];\n /** Array of unapproved items, typically as defined in `Settings.xml` */\n unapprovedItems: string[];\n /** The source scripture text that is searched for in inventory items */\n text: string | undefined;\n /** Scope of scripture that the inventory will operate on */\n scope: Scope;\n /** Callback function that is executed when the scope is changed from the Inventory */\n onScopeChange: (scope: Scope) => void;\n /**\n * Column definitions for the Inventory data table. The most commonly used column definitions are\n * pre-configured for your convenience and can be imported (e.g. inventoryItemColumn,\n * inventoryAdditionalItemColumn inventoryCountColumn, and inventoryStatusColumn). If you need any\n * other columns you can add these yourself\n */\n columns: ColumnDef[];\n};\n\n/** Inventory component that is used to view and control the status of provided project settings */\nexport default function Inventory({\n scriptureReference,\n setScriptureReference,\n localizedStrings,\n extractItems,\n additionalItemsLabels,\n approvedItems,\n unapprovedItems,\n text,\n scope,\n onScopeChange,\n columns,\n}: InventoryProps) {\n const allItemsText = localizeString(localizedStrings, '%webView_inventory_all%');\n const approvedItemsText = localizeString(localizedStrings, '%webView_inventory_approved%');\n const unapprovedItemsText = localizeString(localizedStrings, '%webView_inventory_unapproved%');\n const unknownItemsText = localizeString(localizedStrings, '%webView_inventory_unknown%');\n const scopeBookText = localizeString(localizedStrings, '%webView_inventory_scope_currentBook%');\n const scopeChapterText = localizeString(localizedStrings, '%webView_inventory_scope_chapter%');\n const scopeVerseText = localizeString(localizedStrings, '%webView_inventory_scope_verse%');\n const filterText = localizeString(localizedStrings, '%webView_inventory_filter_text%');\n const showAdditionalItemsText = localizeString(\n localizedStrings,\n '%webView_inventory_show_additional_items%',\n );\n\n const [showAdditionalItems, setShowAdditionalItems] = useState(false);\n const [statusFilter, setStatusFilter] = useState('all');\n const [textFilter, setTextFilter] = useState('');\n const [selectedItem, setSelectedItem] = useState([]);\n\n const tableData: InventoryTableData[] = useMemo(() => {\n if (!text) return [];\n if (extractItems instanceof RegExp)\n return createTableData(\n text,\n scriptureReference,\n approvedItems,\n unapprovedItems,\n extractItems,\n );\n return extractItems(text, scriptureReference, approvedItems, unapprovedItems);\n }, [text, extractItems, scriptureReference, approvedItems, unapprovedItems]);\n\n const reducedTableData: InventoryTableData[] = useMemo(() => {\n if (showAdditionalItems) return tableData;\n\n const newTableData: InventoryTableData[] = [];\n\n tableData.forEach((tableEntry) => {\n const firstItem = tableEntry.items[0];\n\n const existingEntry = newTableData.find(\n (newTableEntry) => newTableEntry.items[0] === firstItem,\n );\n\n if (existingEntry) {\n existingEntry.count += tableEntry.count;\n existingEntry.occurrences = existingEntry.occurrences.concat(tableEntry.occurrences);\n } else {\n newTableData.push({\n items: [firstItem],\n count: tableEntry.count,\n occurrences: tableEntry.occurrences,\n status: tableEntry.status,\n });\n }\n });\n\n return newTableData;\n }, [showAdditionalItems, tableData]);\n\n const filteredTableData: InventoryTableData[] = useMemo(() => {\n return filterItemData(reducedTableData, statusFilter, textFilter);\n }, [reducedTableData, statusFilter, textFilter]);\n\n const allColumns: ColumnDef[] = useMemo(() => {\n if (!showAdditionalItems) return columns;\n\n const numberOfAdditionalItems = additionalItemsLabels?.tableHeaders?.length;\n if (!numberOfAdditionalItems) return columns;\n\n const additionalColumns: ColumnDef[] = [];\n\n for (let index = 0; index < numberOfAdditionalItems; index++) {\n additionalColumns.push(\n inventoryAdditionalItemColumn(\n additionalItemsLabels?.tableHeaders?.[index] || 'Additional Item',\n index + 1,\n ),\n );\n }\n\n return [...additionalColumns, ...columns];\n }, [additionalItemsLabels?.tableHeaders, columns, showAdditionalItems]);\n\n useEffect(() => {\n setSelectedItem([]);\n }, [filteredTableData]);\n\n const rowClickHandler = (\n row: RowContents,\n table: TableContents,\n ) => {\n table.setRowSelection(() => {\n const newSelection: RowSelectionState = {};\n newSelection[row.index] = true;\n return newSelection;\n });\n\n setSelectedItem(row.original.items);\n };\n\n const handleScopeChange = (value: string) => {\n if (value === 'book' || value === 'chapter' || value === 'verse') {\n onScopeChange(value);\n } else {\n throw new Error(`Invalid scope value: ${value}`);\n }\n };\n\n const handleStatusFilterChange = (value: string) => {\n if (value === 'all' || value === 'approved' || value === 'unapproved' || value === 'unknown') {\n setStatusFilter(value);\n } else {\n throw new Error(`Invalid status filter value: ${value}`);\n }\n };\n\n const occurrenceData: InventoryItemOccurrence[] = useMemo(() => {\n if (reducedTableData.length === 0 || selectedItem.length === 0) return [];\n const occurrence = reducedTableData.filter((tableEntry: InventoryTableData) => {\n return deepEqual(\n showAdditionalItems ? tableEntry.items : [tableEntry.items[0]],\n selectedItem,\n );\n });\n if (occurrence.length > 1) throw new Error('Selected item is not unique');\n return occurrence[0].occurrences;\n }, [selectedItem, showAdditionalItems, reducedTableData]);\n\n return (\n
    \n
    \n handleStatusFilterChange(value)}\n defaultValue={statusFilter}\n >\n \n \n \n \n {allItemsText}\n {approvedItemsText}\n {unapprovedItemsText}\n {unknownItemsText}\n \n \n \n {\n setTextFilter(event.target.value);\n }}\n />\n {additionalItemsLabels && (\n
    \n {\n setSelectedItem([]);\n setShowAdditionalItems(checked);\n }}\n />\n \n
    \n )}\n
    \n
    \n \n
    \n {occurrenceData.length > 0 && (\n
    \n \n
    \n )}\n
    \n );\n}\n","import { Input } from '@/components/shadcn-ui/input';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { useState } from 'react';\n\n/** Props for the SearchBar component. */\nexport type SearchBarProps = {\n className?: string;\n /**\n * Callback fired to handle the search query when button pressed\n *\n * @param searchQuery\n */\n onSearch: (searchQuery: string) => void;\n\n /** Optional string that appears in the search bar without a search string */\n placeholder?: string;\n\n /** Optional boolean to set the input base to full width */\n isFullWidth?: boolean;\n};\n\nexport default function SearchBar({\n className,\n onSearch,\n placeholder,\n isFullWidth,\n}: SearchBarProps) {\n const [searchQuery, setSearchQuery] = useState('');\n\n const handleInputChange = (searchString: string) => {\n setSearchQuery(searchString);\n onSearch(searchString);\n };\n\n return (\n handleInputChange(e.target.value)}\n />\n );\n}\n","// adapted from: https://github.com/shadcn-ui/ui/discussions/752\n\n'use client';\n\nimport { TabsContentProps, TabsListProps, TabsTriggerProps } from '@/components/shadcn-ui/tabs';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport * as TabsPrimitive from '@radix-ui/react-tabs';\nimport React from 'react';\n\nexport type VerticalTabsProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport type LeftTabsTriggerProps = TabsTriggerProps & {\n value: string;\n ref?: React.Ref;\n};\n\nexport const VerticalTabs = React.forwardRef<\n React.ElementRef,\n VerticalTabsProps\n>(({ className, ...props }, ref) => (\n \n));\n\nVerticalTabs.displayName = TabsPrimitive.List.displayName;\n\nexport const VerticalTabsList = React.forwardRef<\n React.ElementRef,\n TabsListProps\n>(({ className, ...props }, ref) => (\n \n));\nVerticalTabsList.displayName = TabsPrimitive.List.displayName;\n\nexport const VerticalTabsTrigger = React.forwardRef<\n React.ElementRef,\n LeftTabsTriggerProps\n>(({ className, ...props }, ref) => (\n \n));\n\nexport const VerticalTabsContent = React.forwardRef<\n React.ElementRef,\n TabsContentProps\n>(({ className, ...props }, ref) => (\n \n));\nVerticalTabsContent.displayName = TabsPrimitive.Content.displayName;\n","import SearchBar from '@/components/basics/search-bar.component';\nimport {\n VerticalTabs,\n VerticalTabsContent,\n VerticalTabsList,\n VerticalTabsTrigger,\n} from '@/components/basics/tabs-vertical';\nimport { ReactNode } from 'react';\n\nexport type TabKeyValueContent = {\n key: string;\n value: string;\n content: ReactNode;\n};\n\nexport type TabNavigationContentSearchProps = {\n /** List of values and keys for each tab this component should provide */\n tabList: TabKeyValueContent[];\n\n /** Handler to run when the value of the search bar changes */\n onSearch: (searchQuery: string) => void;\n\n /** Optional placeholder for the search bar */\n searchPlaceholder?: string;\n\n /** Optional title to include in the header */\n headerTitle?: string;\n\n /** Optional flag to make the search bar appear full width */\n isSearchBarFullWidth?: boolean;\n\n /** Text direction ltr or rtl */\n direction?: 'ltr' | 'rtl';\n};\n\nexport default function TabNavigationContentSearch({\n tabList,\n onSearch,\n searchPlaceholder,\n headerTitle,\n isSearchBarFullWidth = false,\n direction = 'ltr',\n}: TabNavigationContentSearchProps) {\n return (\n
    \n
    \n {headerTitle ?

    {headerTitle}

    : ''}\n \n
    \n \n \n {tabList.map((tab) => (\n \n {tab.value}\n \n ))}\n \n {tabList.map((tab) => (\n \n {tab.content}\n \n ))}\n \n
    \n );\n}\n","import React from 'react';\nimport * as SeparatorPrimitive from '@radix-ui/react-separator';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Separator = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, orientation = 'horizontal', decorative = true, ...props }, ref) => (\n \n));\nSeparator.displayName = SeparatorPrimitive.Root.displayName;\n\nexport { Separator };\n","'use client';\n\nimport * as React from 'react';\nimport * as SheetPrimitive from '@radix-ui/react-dialog';\nimport { cva, type VariantProps } from 'class-variance-authority';\nimport { X } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Sheet = SheetPrimitive.Root;\n\nconst SheetTrigger = SheetPrimitive.Trigger;\n\nconst SheetClose = SheetPrimitive.Close;\n\nconst SheetPortal = SheetPrimitive.Portal;\n\nconst SheetOverlay = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSheetOverlay.displayName = SheetPrimitive.Overlay.displayName;\n\nconst sheetVariants = cva(\n 'pr-twp tw-fixed tw-z-50 tw-gap-4 tw-bg-background tw-p-6 tw-shadow-lg tw-transition tw-ease-in-out data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-duration-300 data-[state=open]:tw-duration-500',\n {\n variants: {\n side: {\n top: 'tw-inset-x-0 tw-top-0 tw-border-b data-[state=closed]:tw-slide-out-to-top data-[state=open]:tw-slide-in-from-top',\n bottom:\n 'tw-inset-x-0 tw-bottom-0 tw-border-t data-[state=closed]:tw-slide-out-to-bottom data-[state=open]:tw-slide-in-from-bottom',\n left: 'tw-inset-y-0 tw-left-0 tw-h-full tw-w-3/4 tw-border-r data-[state=closed]:tw-slide-out-to-left data-[state=open]:tw-slide-in-from-left sm:tw-max-w-sm',\n right:\n 'tw-inset-y-0 tw-right-0 tw-h-full tw-w-3/4 tw- tw-border-l data-[state=closed]:tw-slide-out-to-right data-[state=open]:tw-slide-in-from-right sm:tw-max-w-sm',\n },\n },\n defaultVariants: {\n side: 'right',\n },\n },\n);\n\ninterface SheetContentProps\n extends React.ComponentPropsWithoutRef,\n VariantProps {}\n\nconst SheetContent = React.forwardRef<\n React.ElementRef,\n SheetContentProps\n>(({ side = 'right', className, children, ...props }, ref) => (\n \n \n \n {children}\n \n \n Close\n \n \n \n));\nSheetContent.displayName = SheetPrimitive.Content.displayName;\n\nfunction SheetHeader({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nSheetHeader.displayName = 'SheetHeader';\n\nfunction SheetFooter({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nSheetFooter.displayName = 'SheetFooter';\n\nconst SheetTitle = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSheetTitle.displayName = SheetPrimitive.Title.displayName;\n\nconst SheetDescription = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSheetDescription.displayName = SheetPrimitive.Description.displayName;\n\nexport {\n Sheet,\n SheetPortal,\n SheetOverlay,\n SheetTrigger,\n SheetClose,\n SheetContent,\n SheetHeader,\n SheetFooter,\n SheetTitle,\n SheetDescription,\n};\n","import React from 'react';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nfunction Skeleton({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\n\nexport { Skeleton };\n","import React from 'react';\nimport * as TooltipPrimitive from '@radix-ui/react-tooltip';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst TooltipProvider = TooltipPrimitive.Provider;\n\nconst Tooltip = TooltipPrimitive.Root;\n\nconst TooltipTrigger = TooltipPrimitive.Trigger;\n\nconst TooltipContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, sideOffset = 4, ...props }, ref) => (\n \n));\nTooltipContent.displayName = TooltipPrimitive.Content.displayName;\n\nexport { Tooltip, TooltipTrigger, TooltipContent, TooltipProvider };\n","import React from 'react';\n\nconst MOBILE_BREAKPOINT = 768;\n\nexport default function useIsMobile() {\n const [isMobile, setIsMobile] = React.useState(undefined);\n\n React.useEffect(() => {\n const mql = window.matchMedia(`(max-width: ${MOBILE_BREAKPOINT - 1}px)`);\n const onChange = () => {\n setIsMobile(window.innerWidth < MOBILE_BREAKPOINT);\n };\n mql.addEventListener('change', onChange);\n setIsMobile(window.innerWidth < MOBILE_BREAKPOINT);\n return () => mql.removeEventListener('change', onChange);\n }, []);\n\n return !!isMobile;\n}\n","import React from 'react';\nimport { Slot } from '@radix-ui/react-slot';\nimport { VariantProps, cva } from 'class-variance-authority';\nimport { PanelLeft } from 'lucide-react';\n\nimport { Button } from '@/components/shadcn-ui/button';\nimport { Input } from '@/components/shadcn-ui/input';\nimport { Separator } from '@/components/shadcn-ui/separator';\nimport { Sheet, SheetContent } from '@/components/shadcn-ui/sheet';\nimport { Skeleton } from '@/components/shadcn-ui/skeleton';\nimport {\n Tooltip,\n TooltipContent,\n TooltipProvider,\n TooltipTrigger,\n} from '@/components/shadcn-ui/tooltip';\nimport useIsMobile from '@/components/hooks/use-mobile';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst SIDEBAR_COOKIE_NAME = 'sidebar:state';\nconst SIDEBAR_COOKIE_MAX_AGE = 60 * 60 * 24 * 7;\nconst SIDEBAR_WIDTH = '16rem';\nconst SIDEBAR_WIDTH_MOBILE = '18rem';\nconst SIDEBAR_WIDTH_ICON = '3rem';\nconst SIDEBAR_KEYBOARD_SHORTCUT = 'b';\n\ntype SidebarContextProps = {\n state: 'expanded' | 'collapsed';\n open: boolean;\n setOpen: (open: boolean) => void;\n openMobile: boolean;\n setOpenMobile: (open: boolean) => void;\n isMobile: boolean;\n toggleSidebar: () => void;\n};\n\nconst SidebarContext = React.createContext(undefined);\n\nfunction useSidebar() {\n const context = React.useContext(SidebarContext);\n if (!context) {\n throw new Error('useSidebar must be used within a SidebarProvider.');\n }\n\n return context;\n}\n\nconst SidebarProvider = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & {\n defaultOpen?: boolean;\n open?: boolean;\n onOpenChange?: (open: boolean) => void;\n }\n>(\n (\n {\n defaultOpen = true,\n open: openProp,\n onOpenChange: setOpenProp,\n className,\n style,\n children,\n ...props\n },\n ref,\n ) => {\n const isMobile = useIsMobile();\n const [openMobile, setOpenMobile] = React.useState(false);\n\n // This is the internal state of the sidebar.\n // We use openProp and setOpenProp for control from outside the component.\n const [_open, _setOpen] = React.useState(defaultOpen);\n const isOpen = openProp ?? _open;\n const setOpen = React.useCallback(\n (value: boolean | ((value: boolean) => boolean)) => {\n const openState = typeof value === 'function' ? value(isOpen) : value;\n if (setOpenProp) {\n setOpenProp(openState);\n } else {\n _setOpen(openState);\n }\n\n // This sets the cookie to keep the sidebar state.\n document.cookie = `${SIDEBAR_COOKIE_NAME}=${openState}; path=/; max-age=${SIDEBAR_COOKIE_MAX_AGE}`;\n },\n [setOpenProp, isOpen],\n );\n\n // Helper to toggle the sidebar.\n const toggleSidebar = React.useCallback(() => {\n return isMobile ? setOpenMobile((open) => !open) : setOpen((open) => !open);\n }, [isMobile, setOpen, setOpenMobile]);\n\n // Adds a keyboard shortcut to toggle the sidebar.\n React.useEffect(() => {\n const handleKeyDown = (event: KeyboardEvent) => {\n if (event.key === SIDEBAR_KEYBOARD_SHORTCUT && (event.metaKey || event.ctrlKey)) {\n event.preventDefault();\n toggleSidebar();\n }\n };\n\n window.addEventListener('keydown', handleKeyDown);\n return () => window.removeEventListener('keydown', handleKeyDown);\n }, [toggleSidebar]);\n\n // We add a state so that we can do data-state=\"expanded\" or \"collapsed\".\n // This makes it easier to style the sidebar with Tailwind classes.\n const state = isOpen ? 'expanded' : 'collapsed';\n\n const contextValue = React.useMemo(\n () => ({\n state,\n open: isOpen,\n setOpen,\n isMobile,\n openMobile,\n setOpenMobile,\n toggleSidebar,\n }),\n [state, isOpen, setOpen, isMobile, openMobile, setOpenMobile, toggleSidebar],\n );\n\n return (\n \n \n \n {children}\n
    \n \n \n );\n },\n);\nSidebarProvider.displayName = 'SidebarProvider';\n\nconst Sidebar = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & {\n side?: 'left' | 'right';\n variant?: 'sidebar' | 'floating' | 'inset';\n collapsible?: 'offcanvas' | 'icon' | 'none';\n }\n>(\n (\n {\n side = 'left',\n variant = 'sidebar',\n collapsible = 'offcanvas',\n className,\n children,\n ...props\n },\n ref,\n ) => {\n const { isMobile, state, openMobile, setOpenMobile } = useSidebar();\n\n if (collapsible === 'none') {\n return (\n \n {children}\n
    \n );\n }\n\n if (isMobile) {\n return (\n \n button]:tw-hidden\"\n style={\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n {\n '--sidebar-width': SIDEBAR_WIDTH_MOBILE,\n } as React.CSSProperties\n }\n side={side}\n >\n
    {children}
    \n \n
    \n );\n }\n\n return (\n \n {/* This is what handles the sidebar gap on desktop */}\n \n \n \n {children}\n
    \n
    \n
    \n );\n },\n);\nSidebar.displayName = 'Sidebar';\n\nconst SidebarTrigger = React.forwardRef<\n React.ElementRef,\n React.ComponentProps\n>(({ className, onClick, ...props }, ref) => {\n const { toggleSidebar } = useSidebar();\n\n return (\n {\n onClick?.(event);\n toggleSidebar();\n }}\n {...props}\n >\n \n Toggle Sidebar\n \n );\n});\nSidebarTrigger.displayName = 'SidebarTrigger';\n\nconst SidebarRail = React.forwardRef>(\n ({ className, ...props }, ref) => {\n const { toggleSidebar } = useSidebar();\n\n return (\n \n );\n },\n);\nSidebarRail.displayName = 'SidebarRail';\n\nconst SidebarInset = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarInset.displayName = 'SidebarInset';\n\nconst SidebarInput = React.forwardRef<\n React.ElementRef,\n React.ComponentProps\n>(({ className, ...props }, ref) => {\n return (\n \n );\n});\nSidebarInput.displayName = 'SidebarInput';\n\nconst SidebarHeader = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarHeader.displayName = 'SidebarHeader';\n\nconst SidebarFooter = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarFooter.displayName = 'SidebarFooter';\n\nconst SidebarSeparator = React.forwardRef<\n React.ElementRef,\n React.ComponentProps\n>(({ className, ...props }, ref) => {\n return (\n \n );\n});\nSidebarSeparator.displayName = 'SidebarSeparator';\n\nconst SidebarContent = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarContent.displayName = 'SidebarContent';\n\nconst SidebarGroup = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarGroup.displayName = 'SidebarGroup';\n\nconst SidebarGroupLabel = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & { asChild?: boolean }\n>(({ className, asChild = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'div';\n\n return (\n svg]:tw-size-4 [&>svg]:tw-shrink-0',\n 'group-data-[collapsible=icon]:tw--mt-8 group-data-[collapsible=icon]:tw-opacity-0',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarGroupLabel.displayName = 'SidebarGroupLabel';\n\nconst SidebarGroupAction = React.forwardRef<\n HTMLButtonElement,\n React.ComponentProps<'button'> & { asChild?: boolean }\n>(({ className, asChild = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'button';\n\n return (\n svg]:tw-size-4 [&>svg]:tw-shrink-0',\n // Increases the hit area of the button on mobile.\n 'after:tw-absolute after:tw--inset-2 after:md:tw-hidden',\n 'group-data-[collapsible=icon]:tw-hidden',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarGroupAction.displayName = 'SidebarGroupAction';\n\nconst SidebarGroupContent = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarGroupContent.displayName = 'SidebarGroupContent';\n\nconst SidebarMenu = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenu.displayName = 'SidebarMenu';\n\nconst SidebarMenuItem = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenuItem.displayName = 'SidebarMenuItem';\n\nconst sidebarMenuButtonVariants = cva(\n // Removed data-[active=true]:tw-bg-sidebar-accent\n 'tw-peer/menu-button tw-flex tw-w-full tw-items-center tw-gap-2 tw-overflow-hidden tw-rounded-md tw-p-2 tw-text-left tw-text-sm tw-outline-none tw-ring-sidebar-ring tw-transition-[width,height,padding] hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground focus-visible:tw-ring-2 active:tw-bg-sidebar-accent active:tw-text-sidebar-accent-foreground disabled:tw-pointer-events-none disabled:tw-opacity-50 tw-group-has-[[data-sidebar=menu-action]]/menu-item:pr-8 aria-disabled:tw-pointer-events-none aria-disabled:tw-opacity-50 data-[active=true]:tw-font-medium data-[active=true]:tw-text-sidebar-accent-foreground data-[state=open]:hover:tw-bg-sidebar-accent data-[state=open]:hover:tw-text-sidebar-accent-foreground group-data-[collapsible=icon]:tw-!size-8 group-data-[collapsible=icon]:tw-!p-2 [&>span:last-child]:tw-truncate [&>svg]:tw-size-4 [&>svg]:tw-shrink-0',\n {\n variants: {\n variant: {\n default: 'hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground',\n outline:\n 'tw-bg-background tw-shadow-[0_0_0_1px_hsl(var(--sidebar-border))] hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground hover:tw-shadow-[0_0_0_1px_hsl(var(--sidebar-accent))]',\n },\n size: {\n default: 'tw-h-8 tw-text-sm',\n sm: 'tw-h-7 tw-text-xs',\n lg: 'tw-h-12 tw-text-sm group-data-[collapsible=icon]:tw-!p-0',\n },\n },\n defaultVariants: {\n variant: 'default',\n size: 'default',\n },\n },\n);\n\nconst SidebarMenuButton = React.forwardRef<\n HTMLButtonElement,\n React.ComponentProps<'button'> & {\n asChild?: boolean;\n isActive?: boolean;\n tooltip?: string | React.ComponentProps;\n } & VariantProps\n>(\n (\n {\n asChild = false,\n isActive = false,\n variant = 'default',\n size = 'default',\n tooltip,\n className,\n ...props\n },\n ref,\n ) => {\n const Comp = asChild ? Slot : 'button';\n const { isMobile, state } = useSidebar();\n\n const button = (\n \n );\n\n if (!tooltip) {\n return button;\n }\n\n if (typeof tooltip === 'string') {\n // eslint-disable-next-line no-param-reassign\n tooltip = {\n children: tooltip,\n };\n }\n\n return (\n \n {button}\n \n );\n },\n);\nSidebarMenuButton.displayName = 'SidebarMenuButton';\n\nconst SidebarMenuAction = React.forwardRef<\n HTMLButtonElement,\n React.ComponentProps<'button'> & {\n asChild?: boolean;\n showOnHover?: boolean;\n }\n>(({ className, asChild = false, showOnHover = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'button';\n\n return (\n svg]:tw-size-4 [&>svg]:tw-shrink-0',\n // Increases the hit area of the button on mobile.\n 'after:tw-absolute after:tw--inset-2 after:md:tw-hidden',\n 'tw-peer-data-[size=sm]/menu-button:top-1',\n 'tw-peer-data-[size=default]/menu-button:top-1.5',\n 'tw-peer-data-[size=lg]/menu-button:top-2.5',\n 'group-data-[collapsible=icon]:tw-hidden',\n showOnHover &&\n 'tw-group-focus-within/menu-item:opacity-100 tw-group-hover/menu-item:opacity-100 tw-peer-data-[active=true]/menu-button:text-sidebar-accent-foreground data-[state=open]:tw-opacity-100 md:tw-opacity-0',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarMenuAction.displayName = 'SidebarMenuAction';\n\nconst SidebarMenuBadge = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenuBadge.displayName = 'SidebarMenuBadge';\n\nconst SidebarMenuSkeleton = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & {\n showIcon?: boolean;\n }\n>(({ className, showIcon = false, ...props }, ref) => {\n // Random width between 50 to 90%.\n const width = React.useMemo(() => {\n return `${Math.floor(Math.random() * 40) + 50}%`;\n }, []);\n\n return (\n \n {showIcon && (\n \n )}\n \n
    \n );\n});\nSidebarMenuSkeleton.displayName = 'SidebarMenuSkeleton';\n\nconst SidebarMenuSub = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenuSub.displayName = 'SidebarMenuSub';\n\nconst SidebarMenuSubItem = React.forwardRef>(\n ({ ...props }, ref) =>
  • ,\n);\nSidebarMenuSubItem.displayName = 'SidebarMenuSubItem';\n\nconst SidebarMenuSubButton = React.forwardRef<\n HTMLAnchorElement,\n React.ComponentProps<'a'> & {\n asChild?: boolean;\n size?: 'sm' | 'md';\n isActive?: boolean;\n }\n>(({ asChild = false, size = 'md', isActive, className, ...props }, ref) => {\n const Comp = asChild ? Slot : 'a';\n\n return (\n span:last-child]:tw-truncate [&>svg]:tw-size-4 [&>svg]:tw-shrink-0 [&>svg]:tw-text-sidebar-accent-foreground',\n 'data-[active=true]:tw-bg-sidebar-accent data-[active=true]:tw-text-sidebar-accent-foreground',\n size === 'sm' && 'tw-text-xs',\n size === 'md' && 'tw-text-sm',\n 'group-data-[collapsible=icon]:tw-hidden',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarMenuSubButton.displayName = 'SidebarMenuSubButton';\n\nexport {\n Sidebar,\n SidebarContent,\n SidebarFooter,\n SidebarGroup,\n SidebarGroupAction,\n SidebarGroupContent,\n SidebarGroupLabel,\n SidebarHeader,\n SidebarInput,\n SidebarInset,\n SidebarMenu,\n SidebarMenuAction,\n SidebarMenuBadge,\n SidebarMenuButton,\n SidebarMenuItem,\n SidebarMenuSkeleton,\n SidebarMenuSub,\n SidebarMenuSubButton,\n SidebarMenuSubItem,\n SidebarProvider,\n SidebarRail,\n SidebarSeparator,\n SidebarTrigger,\n useSidebar,\n};\n","import ComboBox, { ComboBoxOption } from '@/components/basics/combo-box.component';\nimport {\n Sidebar,\n SidebarContent,\n SidebarGroup,\n SidebarGroupLabel,\n SidebarGroupContent,\n SidebarMenu,\n SidebarMenuItem,\n SidebarMenuButton,\n} from '@/components/shadcn-ui/sidebar';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { useCallback } from 'react';\n\nexport type SelectedSettingsSidebarItem = {\n label: string;\n projectId?: string;\n};\n\nexport type ProjectInfo = { projectId: string; projectName: string };\n\nexport type SettingsSidebarProps = {\n /** Optional id for testing */\n id?: string;\n\n /** Extension labels from contribution */\n extensionLabels: string[];\n\n /** Project names and ids */\n projectOptions: ProjectInfo[];\n\n /** Handler for selecting a sidebar item */\n handleSelectSidebarItem: (key: string, projectId?: string) => void;\n\n /** The current selected value in the sidebar */\n selectedSidebarItem: SelectedSettingsSidebarItem;\n\n /** Label for the group of extensions setting groups */\n extensionsSidebarGroupLabel: string;\n\n /** Label for the group of projects settings */\n projectsSidebarGroupLabel: string;\n\n /** Placeholder text for the button */\n buttonPlaceholderText: string;\n};\n\nexport default function SettingsSidebar({\n id,\n extensionLabels,\n projectOptions,\n handleSelectSidebarItem,\n selectedSidebarItem,\n extensionsSidebarGroupLabel,\n projectsSidebarGroupLabel,\n buttonPlaceholderText,\n}: SettingsSidebarProps) {\n const handleSelectItem = useCallback(\n (item: string, projectId?: string) => {\n handleSelectSidebarItem(item, projectId);\n },\n [handleSelectSidebarItem],\n );\n\n const getProjectNameFromProjectId = useCallback(\n (projectId: string) => {\n const project = projectOptions.find((option) => option.projectId === projectId);\n return project ? project.projectName : projectId;\n },\n [projectOptions],\n );\n\n const getIsActive: (label: string) => boolean = useCallback(\n (label: string) => !selectedSidebarItem.projectId && label === selectedSidebarItem.label,\n [selectedSidebarItem],\n );\n\n return (\n \n \n \n \n {extensionsSidebarGroupLabel}\n \n \n \n {extensionLabels.map((label) => (\n \n handleSelectItem(label)}\n isActive={getIsActive(label)}\n >\n {label}\n \n \n ))}\n \n \n \n \n \n {projectsSidebarGroupLabel}\n \n \n option.projectId)}\n getOptionLabel={(projectId: ComboBoxOption) => {\n // This function expects a ComboBoxOption, but we know it is a string\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n return getProjectNameFromProjectId(projectId as string);\n }}\n buttonPlaceholder={buttonPlaceholderText}\n onChange={(projectId: string) => {\n const selectedProjectName = getProjectNameFromProjectId(projectId);\n handleSelectItem(selectedProjectName, projectId);\n }}\n value={selectedSidebarItem?.projectId ?? undefined}\n />\n \n \n \n \n );\n}\n","import { SidebarInset, SidebarProvider } from '@/components/shadcn-ui/sidebar';\nimport { PropsWithChildren } from 'react';\nimport SearchBar from '@/components/basics/search-bar.component';\nimport SettingsSidebar, { SettingsSidebarProps } from './settings-sidebar.component';\n\nexport type SettingsSidebarContentSearchProps = SettingsSidebarProps &\n PropsWithChildren & {\n /** Optional id for testing */\n id?: string;\n\n /** Handler to run when the value of the search bar changes */\n onSearch: (searchQuery: string) => void;\n };\n\nexport default function SettingsSidebarContentSearch({\n id,\n extensionLabels,\n projectOptions,\n children,\n handleSelectSidebarItem,\n selectedSidebarItem,\n onSearch,\n extensionsSidebarGroupLabel,\n projectsSidebarGroupLabel,\n buttonPlaceholderText,\n}: SettingsSidebarContentSearchProps) {\n return (\n
    \n
    \n \n
    \n \n \n {children}\n \n
    \n );\n}\n","import { Button } from '@/components/shadcn-ui/button';\nimport {\n Select,\n SelectContent,\n SelectGroup,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\nimport {\n Table,\n TableBody,\n TableCell,\n TableHead,\n TableHeader,\n TableRow,\n} from '@/components/shadcn-ui/table';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Canon } from '@sillsdev/scripture';\nimport {\n Cell,\n ColumnDef,\n flexRender,\n getCoreRowModel,\n getExpandedRowModel,\n getGroupedRowModel,\n getSortedRowModel,\n GroupingState,\n Row,\n RowSelectionState,\n SortingState,\n useReactTable,\n} from '@tanstack/react-table';\nimport '@/components/advanced/scripture-results-viewer/scripture-results-viewer.component.css';\nimport {\n compareScrRefs,\n formatScrRef,\n ScriptureSelection,\n scrRefToBBBCCCVVV,\n} from 'platform-bible-utils';\nimport { MouseEvent, useEffect, useMemo, useState } from 'react';\nimport { ChevronDown, ChevronLeft, ChevronRight } from 'lucide-react';\n\n/**\n * Information (e.g., a checking error or some other type of \"transient\" annotation) about something\n * noteworthy at a specific place in an instance of the Scriptures.\n */\nexport type ScriptureItemDetail = ScriptureSelection & {\n /**\n * Text of the error, note, etc. In the future, we might want to support something more than just\n * text so that a JSX element could be provided with a link or some other controls related to the\n * issue being reported.\n */\n detail: string;\n};\n\n/**\n * A uniquely identifiable source of results that can be displayed in the ScriptureResultsViewer.\n * Generally, the source will be a particular Scripture check, but there may be other types of\n * sources.\n */\nexport type ResultsSource = {\n /**\n * Uniquely identifies the source.\n *\n * @type {string}\n */\n id: string;\n\n /**\n * Name (potentially localized) of the source, suitable for display in the UI.\n *\n * @type {string}\n */\n displayName: string;\n};\n\nexport type ScriptureSrcItemDetail = ScriptureItemDetail & {\n /** Source/type of detail. Can be used for grouping. */\n source: ResultsSource;\n};\n\n/**\n * Represents a set of results keyed by Scripture reference. Generally, the source will be a\n * particular Scripture check, but this type also allows for other types of uniquely identifiable\n * sources.\n */\nexport type ResultsSet = {\n /**\n * The backing source associated with this set of results.\n *\n * @type {ResultsSource}\n */\n source: ResultsSource;\n\n /**\n * Array of Scripture item details (messages keyed by Scripture reference).\n *\n * @type {ScriptureItemDetail[]}\n */\n data: ScriptureItemDetail[];\n};\n\nconst scrBookColId = 'scrBook';\nconst scrRefColId = 'scrRef';\nconst typeColId = 'source';\nconst detailsColId = 'details';\n\nconst defaultScrRefColumnName = 'Scripture Reference';\nconst defaultScrBookGroupName = 'Scripture Book';\nconst defaultTypeColumnName = 'Type';\nconst defaultDetailsColumnName = 'Details';\n\nexport type ScriptureResultsViewerColumnInfo = {\n /** Optional header to display for the Reference column. Default value: 'Scripture Reference'. */\n scriptureReferenceColumnName?: string;\n\n /** Optional text to display to refer to the Scripture book group. Default value: 'Scripture Book'. */\n scriptureBookGroupName?: string;\n\n /** Optional header to display for the Type column. Default value: 'Type'. */\n typeColumnName?: string;\n\n /** Optional header to display for the Details column. Default value: 'Details' */\n detailsColumnName?: string;\n};\n\nexport type ScriptureResultsViewerProps = ScriptureResultsViewerColumnInfo & {\n /** Groups of ScriptureItemDetail objects from particular sources (e.g., Scripture checks) */\n sources: ResultsSet[];\n\n /** Flag indicating whether to display column headers. Default is false. */\n showColumnHeaders?: boolean;\n\n /** Flag indicating whether to display source column. Default is false. */\n showSourceColumn?: boolean;\n\n /** Callback function to notify when a row is selected */\n onRowSelected?: (selectedRow: ScriptureSrcItemDetail | undefined) => void;\n\n /** Text direction ltr or rtl */\n direction?: 'ltr' | 'rtl';\n};\n\nfunction getColumns(\n colInfo?: ScriptureResultsViewerColumnInfo,\n showSourceColumn?: boolean,\n): ColumnDef[] {\n const showSrcCol = showSourceColumn ?? false;\n return [\n {\n accessorFn: (row) =>\n `${Canon.bookNumberToId(row.start.bookNum)} ${row.start.chapterNum}:${row.start.verseNum}`,\n id: scrBookColId,\n header: colInfo?.scriptureReferenceColumnName ?? defaultScrRefColumnName,\n cell: (info) => {\n const row = info.row.original;\n if (info.row.getIsGrouped()) {\n return Canon.bookNumberToEnglishName(row.start.bookNum);\n }\n return info.row.groupingColumnId === scrBookColId ? formatScrRef(row.start) : undefined;\n },\n getGroupingValue: (row) => row.start.bookNum,\n sortingFn: (a, b) => {\n return compareScrRefs(a.original.start, b.original.start);\n },\n enableGrouping: true,\n },\n {\n accessorFn: (row) => formatScrRef(row.start),\n id: scrRefColId,\n header: undefined,\n cell: (info) => {\n const row = info.row.original;\n return info.row.getIsGrouped() ? undefined : formatScrRef(row.start);\n },\n sortingFn: (a, b) => {\n return compareScrRefs(a.original.start, b.original.start);\n },\n enableGrouping: false,\n },\n {\n accessorFn: (row) => row.source.displayName,\n id: typeColId,\n header: showSrcCol ? (colInfo?.typeColumnName ?? defaultTypeColumnName) : undefined,\n cell: (info) => (showSrcCol || info.row.getIsGrouped() ? info.getValue() : undefined),\n getGroupingValue: (row) => row.source.id,\n sortingFn: (a, b) =>\n a.original.source.displayName.localeCompare(b.original.source.displayName),\n enableGrouping: true,\n },\n {\n accessorFn: (row) => row.detail,\n id: detailsColId,\n header: colInfo?.detailsColumnName ?? defaultDetailsColumnName,\n cell: (info) => info.getValue(),\n enableGrouping: false,\n },\n ];\n}\n\nconst toRefOrRange = (scriptureSelection: ScriptureSelection) => {\n if (!('offset' in scriptureSelection.start))\n throw new Error('No offset available in range start');\n if (scriptureSelection.end && !('offset' in scriptureSelection.end))\n throw new Error('No offset available in range end');\n const { offset: offsetStart } = scriptureSelection.start;\n let offsetEnd: number = 0;\n if (scriptureSelection.end) ({ offset: offsetEnd } = scriptureSelection.end);\n if (\n !scriptureSelection.end ||\n compareScrRefs(scriptureSelection.start, scriptureSelection.end) === 0\n )\n return `${scrRefToBBBCCCVVV(scriptureSelection.start)}+${offsetStart}`;\n return `${scrRefToBBBCCCVVV(scriptureSelection.start)}+${offsetStart}-${scrRefToBBBCCCVVV(scriptureSelection.end)}+${offsetEnd}`;\n};\n\nconst getRowKey = (row: ScriptureSrcItemDetail) =>\n `${toRefOrRange({ start: row.start, end: row.end })} ${row.source.displayName} ${row.detail}`;\n\n/**\n * Component to display a combined list of detailed items from one or more sources, where the items\n * are keyed primarily by Scripture reference. This is particularly useful for displaying a list of\n * results from Scripture checks, but more generally could be used to display any \"results\" from any\n * source(s). The component allows for grouping by Scripture book, source, or both. By default, it\n * displays somewhat \"tree-like\" which allows it to be more horizontally compact and intuitive. But\n * it also has the option of displaying as a traditional table with column headings (with or without\n * the source column showing).\n */\nexport default function ScriptureResultsViewer({\n sources,\n showColumnHeaders = false,\n showSourceColumn = false,\n scriptureReferenceColumnName,\n scriptureBookGroupName,\n typeColumnName,\n detailsColumnName,\n onRowSelected,\n direction = 'ltr',\n}: ScriptureResultsViewerProps) {\n const [grouping, setGrouping] = useState([]);\n const [sorting, setSorting] = useState([{ id: scrBookColId, desc: false }]);\n const [rowSelection, setRowSelection] = useState({});\n\n const scriptureResults = useMemo(\n () =>\n sources.flatMap((source) => {\n return source.data.map((item) => ({\n ...item,\n source: source.source,\n }));\n }),\n [sources],\n );\n\n const columns = useMemo(\n () =>\n getColumns(\n {\n scriptureReferenceColumnName,\n typeColumnName,\n detailsColumnName,\n },\n showSourceColumn,\n ),\n [scriptureReferenceColumnName, typeColumnName, detailsColumnName, showSourceColumn],\n );\n\n useEffect(() => {\n // Ensure sorting is applied correctly when grouped by type\n if (grouping.includes(typeColId)) {\n setSorting([\n { id: typeColId, desc: false },\n { id: scrBookColId, desc: false },\n ]);\n } else {\n setSorting([{ id: scrBookColId, desc: false }]);\n }\n }, [grouping]);\n\n const table = useReactTable({\n data: scriptureResults,\n columns,\n state: {\n grouping,\n sorting,\n rowSelection,\n },\n onGroupingChange: setGrouping,\n onSortingChange: setSorting,\n onRowSelectionChange: setRowSelection,\n getExpandedRowModel: getExpandedRowModel(),\n getGroupedRowModel: getGroupedRowModel(),\n getCoreRowModel: getCoreRowModel(),\n getSortedRowModel: getSortedRowModel(),\n getRowId: getRowKey,\n autoResetExpanded: false,\n enableMultiRowSelection: false,\n enableSubRowSelection: false,\n });\n\n useEffect(() => {\n if (onRowSelected) {\n const selectedRows = table.getSelectedRowModel().rowsById;\n const keys = Object.keys(selectedRows);\n if (keys.length === 1) {\n const selectedRow = scriptureResults.find((row) => getRowKey(row) === keys[0]) || undefined;\n if (selectedRow) onRowSelected(selectedRow);\n }\n }\n }, [rowSelection, scriptureResults, onRowSelected, table]);\n\n // Define possible grouping options\n const scrBookGroupName = scriptureBookGroupName ?? defaultScrBookGroupName;\n const typeGroupName = typeColumnName ?? defaultTypeColumnName;\n\n const groupingOptions = [\n { label: 'No Grouping', value: [] },\n { label: `Group by ${scrBookGroupName}`, value: [scrBookColId] },\n { label: `Group by ${typeGroupName}`, value: [typeColId] },\n {\n label: `Group by ${scrBookGroupName} and ${typeGroupName}`,\n value: [scrBookColId, typeColId],\n },\n {\n label: `Group by ${typeGroupName} and ${scrBookGroupName}`,\n value: [typeColId, scrBookColId],\n },\n ];\n\n const handleSelectChange = (selectedGrouping: string) => {\n setGrouping(JSON.parse(selectedGrouping));\n };\n\n const handleRowClick = (row: Row, event: MouseEvent) => {\n if (!row.getIsGrouped() && !row.getIsSelected()) {\n row.getToggleSelectedHandler()(event);\n }\n };\n\n const getEvenOrOddBandingStyle = (row: Row, index: number) => {\n if (row.getIsGrouped()) return '';\n // UX has now said they don't think they want banding. I'm leaving in the code to\n // set even and odd styles, but there's nothing in the CSS to style them differently.\n // The \"even\" style used to also have tw-bg-neutral-300 (along with even) to create\n // a visual banding effect. That could be added back in if UX changes the decision.\n return cn('banded-row', index % 2 === 0 ? 'even' : 'odd');\n };\n\n const getIndent = (\n groupingState: GroupingState,\n row: Row,\n cell: Cell,\n ) => {\n if (groupingState?.length === 0 || row.depth < cell.column.getGroupedIndex()) return undefined;\n if (row.getIsGrouped()) {\n switch (row.depth) {\n case 1:\n return 'tw-ps-4';\n default:\n return undefined;\n }\n }\n switch (row.depth) {\n case 1:\n return 'tw-ps-8';\n case 2:\n return 'tw-ps-12';\n default:\n return undefined;\n }\n };\n\n return (\n
    \n {!showColumnHeaders && (\n {\n handleSelectChange(value);\n }}\n >\n \n \n \n \n \n {groupingOptions.map((option) => (\n \n {option.label}\n \n ))}\n \n \n \n )}\n \n {showColumnHeaders && (\n \n {table.getHeaderGroups().map((headerGroup) => (\n \n {headerGroup.headers\n .filter((h) => h.column.columnDef.header)\n .map((header) => (\n /* For sticky column headers to work, we probably need to change the default definition of the shadcn Table component. See https://github.com/shadcn-ui/ui/issues/1151 */\n \n {header.isPlaceholder ? undefined : (\n
    \n {header.column.getCanGroup() ? (\n \n {header.column.getIsGrouped() ? `🛑` : `👊 `}\n \n ) : undefined}{' '}\n {flexRender(header.column.columnDef.header, header.getContext())}\n
    \n )}\n
    \n ))}\n
    \n ))}\n
    \n )}\n \n {table.getRowModel().rows.map((row, rowIndex) => {\n return (\n handleRowClick(row, event)}\n >\n {row.getVisibleCells().map((cell) => {\n if (\n cell.getIsPlaceholder() ||\n (cell.column.columnDef.enableGrouping &&\n !cell.getIsGrouped() &&\n (cell.column.columnDef.id !== typeColId || !showSourceColumn))\n )\n return undefined;\n return (\n \n {(() => {\n if (cell.getIsGrouped()) {\n return (\n \n {row.getIsExpanded() && }\n {!row.getIsExpanded() &&\n (direction === 'ltr' ? : )}{' '}\n {flexRender(cell.column.columnDef.cell, cell.getContext())} (\n {row.subRows.length})\n \n );\n }\n\n // if (cell.getIsAggregated()) {\n // flexRender(\n // cell.column.columnDef.aggregatedCell ?? cell.column.columnDef.cell,\n // cell.getContext(),\n // );\n // }\n\n return flexRender(cell.column.columnDef.cell, cell.getContext());\n })()}\n \n );\n })}\n \n );\n })}\n \n
    \n
    \n );\n}\n","import {\n getLocalizeKeyForScrollGroupId,\n LanguageStrings,\n ScrollGroupId,\n} from 'platform-bible-utils';\nimport {\n Select,\n SelectContent,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\n\nconst DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS = {\n [getLocalizeKeyForScrollGroupId('undefined')]: 'Ø',\n [getLocalizeKeyForScrollGroupId(0)]: 'A',\n [getLocalizeKeyForScrollGroupId(1)]: 'B',\n [getLocalizeKeyForScrollGroupId(2)]: 'C',\n [getLocalizeKeyForScrollGroupId(3)]: 'D',\n [getLocalizeKeyForScrollGroupId(4)]: 'E',\n [getLocalizeKeyForScrollGroupId(5)]: 'F',\n [getLocalizeKeyForScrollGroupId(6)]: 'G',\n [getLocalizeKeyForScrollGroupId(7)]: 'H',\n [getLocalizeKeyForScrollGroupId(8)]: 'I',\n [getLocalizeKeyForScrollGroupId(9)]: 'J',\n [getLocalizeKeyForScrollGroupId(10)]: 'K',\n [getLocalizeKeyForScrollGroupId(11)]: 'L',\n [getLocalizeKeyForScrollGroupId(12)]: 'M',\n [getLocalizeKeyForScrollGroupId(13)]: 'N',\n [getLocalizeKeyForScrollGroupId(14)]: 'O',\n [getLocalizeKeyForScrollGroupId(15)]: 'P',\n [getLocalizeKeyForScrollGroupId(16)]: 'Q',\n [getLocalizeKeyForScrollGroupId(17)]: 'R',\n [getLocalizeKeyForScrollGroupId(18)]: 'S',\n [getLocalizeKeyForScrollGroupId(19)]: 'T',\n [getLocalizeKeyForScrollGroupId(20)]: 'U',\n [getLocalizeKeyForScrollGroupId(21)]: 'V',\n [getLocalizeKeyForScrollGroupId(22)]: 'W',\n [getLocalizeKeyForScrollGroupId(23)]: 'X',\n [getLocalizeKeyForScrollGroupId(24)]: 'Y',\n [getLocalizeKeyForScrollGroupId(25)]: 'Z',\n};\n\nexport type ScrollGroupSelectorProps = {\n /**\n * List of scroll group ids to show to the user. Either a {@link ScrollGroupId} or `undefined` for\n * no scroll group\n */\n availableScrollGroupIds: (ScrollGroupId | undefined)[];\n /** Currently selected scroll group id. `undefined` for no scroll group */\n scrollGroupId: ScrollGroupId | undefined;\n /** Callback function run when the user tries to change the scroll group id */\n onChangeScrollGroupId: (newScrollGroupId: ScrollGroupId | undefined) => void;\n /**\n * Localized strings to use for displaying scroll group ids. Must be an object whose keys are\n * `getLocalizeKeyForScrollGroupId(scrollGroupId)` for all scroll group ids (and `undefined` if\n * included) in {@link ScrollGroupSelectorProps.availableScrollGroupIds} and whose values are the\n * localized strings to use for those scroll group ids.\n *\n * Defaults to English localizations of English alphabet for scroll groups 0-25 (e.g. 0 is A) and\n * Ø for `undefined`. Will fill in any that are not provided with these English localizations.\n * Also, if any values match the keys, the English localization will be used. This is useful in\n * case you want to pass in a temporary version of the localized strings while your localized\n * strings load.\n *\n * @example\n *\n * ```typescript\n * const myScrollGroupIdLocalizedStrings = {\n * [getLocalizeKeyForScrollGroupId('undefined')]: 'Ø',\n * [getLocalizeKeyForScrollGroupId(0)]: 'A',\n * [getLocalizeKeyForScrollGroupId(1)]: 'B',\n * [getLocalizeKeyForScrollGroupId(2)]: 'C',\n * [getLocalizeKeyForScrollGroupId(3)]: 'D',\n * [getLocalizeKeyForScrollGroupId(4)]: 'E',\n * };\n * ```\n *\n * @example\n *\n * ```tsx\n * const availableScrollGroupIds = [undefined, 0, 1, 2, 3, 4];\n *\n * const localizeKeys = getLocalizeKeysForScrollGroupIds();\n *\n * const [localizedStrings] = useLocalizedStrings(localizeKeys);\n *\n * ...\n *\n * \n * ```\n */\n localizedStrings?: LanguageStrings;\n};\n\n/** Selector component for choosing a scroll group */\nexport default function ScrollGroupSelector({\n availableScrollGroupIds,\n scrollGroupId,\n onChangeScrollGroupId,\n localizedStrings = {},\n}: ScrollGroupSelectorProps) {\n const localizedStringsDefaulted = {\n ...DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS,\n ...Object.fromEntries(\n Object.entries(localizedStrings).map(\n ([localizedStringKey, localizedStringValue]: [string, string]) => [\n localizedStringKey,\n localizedStringKey === localizedStringValue &&\n localizedStringKey in DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS\n ? DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS[localizedStringKey]\n : localizedStringValue,\n ],\n ),\n ),\n };\n return (\n \n onChangeScrollGroupId(\n newScrollGroupString === 'undefined' ? undefined : parseInt(newScrollGroupString, 10),\n )\n }\n >\n \n \n \n \n {availableScrollGroupIds.map((scrollGroupOptionId) => (\n \n {localizedStringsDefaulted[getLocalizeKeyForScrollGroupId(scrollGroupOptionId)]}\n \n ))}\n \n \n );\n}\n","import { PropsWithChildren } from 'react';\nimport { Separator } from '@/components/shadcn-ui/separator';\n\n/** Props for the SettingsList component, currently just children */\ntype SettingsListProps = PropsWithChildren;\n\n/**\n * SettingsList component is a wrapper for list items. Rendered with a formatted div\n *\n * @param children To populate the list with\n * @returns Formatted div encompassing the children\n */\nexport function SettingsList({ children }: SettingsListProps) {\n return
    {children}
    ;\n}\n\n/** Props for SettingsListItem component */\ntype SettingsListItemProps = PropsWithChildren & {\n /** Primary text of the list item */\n primary: string;\n\n /** Optional text of the list item */\n secondary?: string | undefined;\n\n /** Optional boolean to display a message if the children aren't loaded yet. Defaults to false */\n isLoading?: boolean;\n\n /** Optional message to display if isLoading */\n loadingMessage?: string;\n};\n\n/**\n * SettingsListItem component is a common list item. Rendered with a formatted div\n *\n * @param primary Primary text of the list item\n * @param secondary Optional secondary text of the list item\n * @param isLoading Optional, to display a message if the action component isn't generated yet,\n * defaults to false\n * @param children The action component(s) to provide for this item\n * @param loadingMessage Optional, message to display if isLoading\n * @returns Formatted div encompassing the list item content\n */\nexport function SettingsListItem({\n primary,\n secondary,\n children,\n isLoading = false,\n loadingMessage,\n}: SettingsListItemProps) {\n return (\n
    \n
    \n

    {primary}

    \n

    \n {secondary}\n

    \n
    \n\n {isLoading ? (\n

    {loadingMessage}

    \n ) : (\n
    {children}
    \n )}\n
    \n );\n}\n\n/** Props for SettingsListHeader component */\ntype SettingsListHeaderProps = {\n /** The primary text of the list header */\n primary: string;\n\n /** Optional secondary text of the list header */\n secondary?: string | undefined;\n\n /** Optional boolean to include a separator underneath the secondary text. Defaults to false */\n includeSeparator?: boolean;\n};\n\n/**\n * SettingsListHeader component displays text above the list\n *\n * @param primary The primary text of the list header\n * @param secondary Optional secondary text of the list header\n * @param includeSeparator Optional boolean to include a separator underneath the secondary text.\n * Defaults to false\n * @returns Formatted div with list header content\n */\nexport function SettingsListHeader({\n primary,\n secondary,\n includeSeparator = false,\n}: SettingsListHeaderProps) {\n return (\n
    \n
    \n

    {primary}

    \n

    {secondary}

    \n
    \n {includeSeparator ? : ''}\n
    \n );\n}\n","import Checkbox from '@/components/shadcn-ui/checkbox';\nimport { Label } from '@/components/shadcn-ui/label';\n\nexport type ChecklistProps = {\n /** Optional string representing the id attribute of the Checklist */\n id?: string;\n /** Optional string representing CSS class name(s) for styling */\n className?: string;\n /** Array of strings representing the checkable items */\n listItems: string[];\n /** Array of strings representing the checked items */\n selectedListItems: string[];\n /**\n * Function that is called when a checkbox item is selected or deselected\n *\n * @param item The string description for this item\n * @param selected True if selected, false if not selected\n */\n handleSelectListItem: (item: string, selected: boolean) => void;\n\n /**\n * Optional function creates a label for a provided checkable item\n *\n * @param item The item for which a label is to be created\n * @returns A string representing the label text for the checkbox associated with that item\n */\n createLabel?: (item: string) => string;\n};\n\n/** Renders a list of checkboxes. Each checkbox corresponds to an item from the `listItems` array. */\nexport default function Checklist({\n id,\n className,\n listItems,\n selectedListItems,\n handleSelectListItem,\n createLabel,\n}: ChecklistProps) {\n return (\n
    \n {listItems.map((item) => (\n
    \n handleSelectListItem(item, value)}\n />\n \n
    \n ))}\n
    \n );\n}\n","function _interopRequireDefault(obj) {\n return obj && obj.__esModule ? obj : {\n \"default\": obj\n };\n}\nmodule.exports = _interopRequireDefault, module.exports.__esModule = true, module.exports[\"default\"] = module.exports;","export default function chainPropTypes(propType1, propType2) {\n if (process.env.NODE_ENV === 'production') {\n return () => null;\n }\n return function validate(...args) {\n return propType1(...args) || propType2(...args);\n };\n}","export default function _extends() {\n _extends = Object.assign ? Object.assign.bind() : function (target) {\n for (var i = 1; i < arguments.length; i++) {\n var source = arguments[i];\n for (var key in source) {\n if (Object.prototype.hasOwnProperty.call(source, key)) {\n target[key] = source[key];\n }\n }\n }\n return target;\n };\n return _extends.apply(this, arguments);\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\n// https://github.com/sindresorhus/is-plain-obj/blob/main/index.js\nexport function isPlainObject(item) {\n if (typeof item !== 'object' || item === null) {\n return false;\n }\n const prototype = Object.getPrototypeOf(item);\n return (prototype === null || prototype === Object.prototype || Object.getPrototypeOf(prototype) === null) && !(Symbol.toStringTag in item) && !(Symbol.iterator in item);\n}\nfunction deepClone(source) {\n if (!isPlainObject(source)) {\n return source;\n }\n const output = {};\n Object.keys(source).forEach(key => {\n output[key] = deepClone(source[key]);\n });\n return output;\n}\nexport default function deepmerge(target, source, options = {\n clone: true\n}) {\n const output = options.clone ? _extends({}, target) : target;\n if (isPlainObject(target) && isPlainObject(source)) {\n Object.keys(source).forEach(key => {\n // Avoid prototype pollution\n if (key === '__proto__') {\n return;\n }\n if (isPlainObject(source[key]) && key in target && isPlainObject(target[key])) {\n // Since `output` is a clone of `target` and we have narrowed `target` in this block we can cast to the same type.\n output[key] = deepmerge(target[key], source[key], options);\n } else if (options.clone) {\n output[key] = isPlainObject(source[key]) ? deepClone(source[key]) : source[key];\n } else {\n output[key] = source[key];\n }\n });\n }\n return output;\n}","/** @license React v16.13.1\n * react-is.production.min.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';var b=\"function\"===typeof Symbol&&Symbol.for,c=b?Symbol.for(\"react.element\"):60103,d=b?Symbol.for(\"react.portal\"):60106,e=b?Symbol.for(\"react.fragment\"):60107,f=b?Symbol.for(\"react.strict_mode\"):60108,g=b?Symbol.for(\"react.profiler\"):60114,h=b?Symbol.for(\"react.provider\"):60109,k=b?Symbol.for(\"react.context\"):60110,l=b?Symbol.for(\"react.async_mode\"):60111,m=b?Symbol.for(\"react.concurrent_mode\"):60111,n=b?Symbol.for(\"react.forward_ref\"):60112,p=b?Symbol.for(\"react.suspense\"):60113,q=b?\nSymbol.for(\"react.suspense_list\"):60120,r=b?Symbol.for(\"react.memo\"):60115,t=b?Symbol.for(\"react.lazy\"):60116,v=b?Symbol.for(\"react.block\"):60121,w=b?Symbol.for(\"react.fundamental\"):60117,x=b?Symbol.for(\"react.responder\"):60118,y=b?Symbol.for(\"react.scope\"):60119;\nfunction z(a){if(\"object\"===typeof a&&null!==a){var u=a.$$typeof;switch(u){case c:switch(a=a.type,a){case l:case m:case e:case g:case f:case p:return a;default:switch(a=a&&a.$$typeof,a){case k:case n:case t:case r:case h:return a;default:return u}}case d:return u}}}function A(a){return z(a)===m}exports.AsyncMode=l;exports.ConcurrentMode=m;exports.ContextConsumer=k;exports.ContextProvider=h;exports.Element=c;exports.ForwardRef=n;exports.Fragment=e;exports.Lazy=t;exports.Memo=r;exports.Portal=d;\nexports.Profiler=g;exports.StrictMode=f;exports.Suspense=p;exports.isAsyncMode=function(a){return A(a)||z(a)===l};exports.isConcurrentMode=A;exports.isContextConsumer=function(a){return z(a)===k};exports.isContextProvider=function(a){return z(a)===h};exports.isElement=function(a){return\"object\"===typeof a&&null!==a&&a.$$typeof===c};exports.isForwardRef=function(a){return z(a)===n};exports.isFragment=function(a){return z(a)===e};exports.isLazy=function(a){return z(a)===t};\nexports.isMemo=function(a){return z(a)===r};exports.isPortal=function(a){return z(a)===d};exports.isProfiler=function(a){return z(a)===g};exports.isStrictMode=function(a){return z(a)===f};exports.isSuspense=function(a){return z(a)===p};\nexports.isValidElementType=function(a){return\"string\"===typeof a||\"function\"===typeof a||a===e||a===m||a===g||a===f||a===p||a===q||\"object\"===typeof a&&null!==a&&(a.$$typeof===t||a.$$typeof===r||a.$$typeof===h||a.$$typeof===k||a.$$typeof===n||a.$$typeof===w||a.$$typeof===x||a.$$typeof===y||a.$$typeof===v)};exports.typeOf=z;\n","/** @license React v16.13.1\n * react-is.development.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\n\n\nif (process.env.NODE_ENV !== \"production\") {\n (function() {\n'use strict';\n\n// The Symbol used to tag the ReactElement-like types. If there is no native Symbol\n// nor polyfill, then a plain number is used for performance.\nvar hasSymbol = typeof Symbol === 'function' && Symbol.for;\nvar REACT_ELEMENT_TYPE = hasSymbol ? Symbol.for('react.element') : 0xeac7;\nvar REACT_PORTAL_TYPE = hasSymbol ? Symbol.for('react.portal') : 0xeaca;\nvar REACT_FRAGMENT_TYPE = hasSymbol ? Symbol.for('react.fragment') : 0xeacb;\nvar REACT_STRICT_MODE_TYPE = hasSymbol ? Symbol.for('react.strict_mode') : 0xeacc;\nvar REACT_PROFILER_TYPE = hasSymbol ? Symbol.for('react.profiler') : 0xead2;\nvar REACT_PROVIDER_TYPE = hasSymbol ? Symbol.for('react.provider') : 0xeacd;\nvar REACT_CONTEXT_TYPE = hasSymbol ? Symbol.for('react.context') : 0xeace; // TODO: We don't use AsyncMode or ConcurrentMode anymore. They were temporary\n// (unstable) APIs that have been removed. Can we remove the symbols?\n\nvar REACT_ASYNC_MODE_TYPE = hasSymbol ? Symbol.for('react.async_mode') : 0xeacf;\nvar REACT_CONCURRENT_MODE_TYPE = hasSymbol ? Symbol.for('react.concurrent_mode') : 0xeacf;\nvar REACT_FORWARD_REF_TYPE = hasSymbol ? Symbol.for('react.forward_ref') : 0xead0;\nvar REACT_SUSPENSE_TYPE = hasSymbol ? Symbol.for('react.suspense') : 0xead1;\nvar REACT_SUSPENSE_LIST_TYPE = hasSymbol ? Symbol.for('react.suspense_list') : 0xead8;\nvar REACT_MEMO_TYPE = hasSymbol ? Symbol.for('react.memo') : 0xead3;\nvar REACT_LAZY_TYPE = hasSymbol ? Symbol.for('react.lazy') : 0xead4;\nvar REACT_BLOCK_TYPE = hasSymbol ? Symbol.for('react.block') : 0xead9;\nvar REACT_FUNDAMENTAL_TYPE = hasSymbol ? Symbol.for('react.fundamental') : 0xead5;\nvar REACT_RESPONDER_TYPE = hasSymbol ? Symbol.for('react.responder') : 0xead6;\nvar REACT_SCOPE_TYPE = hasSymbol ? Symbol.for('react.scope') : 0xead7;\n\nfunction isValidElementType(type) {\n return typeof type === 'string' || typeof type === 'function' || // Note: its typeof might be other than 'symbol' or 'number' if it's a polyfill.\n type === REACT_FRAGMENT_TYPE || type === REACT_CONCURRENT_MODE_TYPE || type === REACT_PROFILER_TYPE || type === REACT_STRICT_MODE_TYPE || type === REACT_SUSPENSE_TYPE || type === REACT_SUSPENSE_LIST_TYPE || typeof type === 'object' && type !== null && (type.$$typeof === REACT_LAZY_TYPE || type.$$typeof === REACT_MEMO_TYPE || type.$$typeof === REACT_PROVIDER_TYPE || type.$$typeof === REACT_CONTEXT_TYPE || type.$$typeof === REACT_FORWARD_REF_TYPE || type.$$typeof === REACT_FUNDAMENTAL_TYPE || type.$$typeof === REACT_RESPONDER_TYPE || type.$$typeof === REACT_SCOPE_TYPE || type.$$typeof === REACT_BLOCK_TYPE);\n}\n\nfunction typeOf(object) {\n if (typeof object === 'object' && object !== null) {\n var $$typeof = object.$$typeof;\n\n switch ($$typeof) {\n case REACT_ELEMENT_TYPE:\n var type = object.type;\n\n switch (type) {\n case REACT_ASYNC_MODE_TYPE:\n case REACT_CONCURRENT_MODE_TYPE:\n case REACT_FRAGMENT_TYPE:\n case REACT_PROFILER_TYPE:\n case REACT_STRICT_MODE_TYPE:\n case REACT_SUSPENSE_TYPE:\n return type;\n\n default:\n var $$typeofType = type && type.$$typeof;\n\n switch ($$typeofType) {\n case REACT_CONTEXT_TYPE:\n case REACT_FORWARD_REF_TYPE:\n case REACT_LAZY_TYPE:\n case REACT_MEMO_TYPE:\n case REACT_PROVIDER_TYPE:\n return $$typeofType;\n\n default:\n return $$typeof;\n }\n\n }\n\n case REACT_PORTAL_TYPE:\n return $$typeof;\n }\n }\n\n return undefined;\n} // AsyncMode is deprecated along with isAsyncMode\n\nvar AsyncMode = REACT_ASYNC_MODE_TYPE;\nvar ConcurrentMode = REACT_CONCURRENT_MODE_TYPE;\nvar ContextConsumer = REACT_CONTEXT_TYPE;\nvar ContextProvider = REACT_PROVIDER_TYPE;\nvar Element = REACT_ELEMENT_TYPE;\nvar ForwardRef = REACT_FORWARD_REF_TYPE;\nvar Fragment = REACT_FRAGMENT_TYPE;\nvar Lazy = REACT_LAZY_TYPE;\nvar Memo = REACT_MEMO_TYPE;\nvar Portal = REACT_PORTAL_TYPE;\nvar Profiler = REACT_PROFILER_TYPE;\nvar StrictMode = REACT_STRICT_MODE_TYPE;\nvar Suspense = REACT_SUSPENSE_TYPE;\nvar hasWarnedAboutDeprecatedIsAsyncMode = false; // AsyncMode should be deprecated\n\nfunction isAsyncMode(object) {\n {\n if (!hasWarnedAboutDeprecatedIsAsyncMode) {\n hasWarnedAboutDeprecatedIsAsyncMode = true; // Using console['warn'] to evade Babel and ESLint\n\n console['warn']('The ReactIs.isAsyncMode() alias has been deprecated, ' + 'and will be removed in React 17+. Update your code to use ' + 'ReactIs.isConcurrentMode() instead. It has the exact same API.');\n }\n }\n\n return isConcurrentMode(object) || typeOf(object) === REACT_ASYNC_MODE_TYPE;\n}\nfunction isConcurrentMode(object) {\n return typeOf(object) === REACT_CONCURRENT_MODE_TYPE;\n}\nfunction isContextConsumer(object) {\n return typeOf(object) === REACT_CONTEXT_TYPE;\n}\nfunction isContextProvider(object) {\n return typeOf(object) === REACT_PROVIDER_TYPE;\n}\nfunction isElement(object) {\n return typeof object === 'object' && object !== null && object.$$typeof === REACT_ELEMENT_TYPE;\n}\nfunction isForwardRef(object) {\n return typeOf(object) === REACT_FORWARD_REF_TYPE;\n}\nfunction isFragment(object) {\n return typeOf(object) === REACT_FRAGMENT_TYPE;\n}\nfunction isLazy(object) {\n return typeOf(object) === REACT_LAZY_TYPE;\n}\nfunction isMemo(object) {\n return typeOf(object) === REACT_MEMO_TYPE;\n}\nfunction isPortal(object) {\n return typeOf(object) === REACT_PORTAL_TYPE;\n}\nfunction isProfiler(object) {\n return typeOf(object) === REACT_PROFILER_TYPE;\n}\nfunction isStrictMode(object) {\n return typeOf(object) === REACT_STRICT_MODE_TYPE;\n}\nfunction isSuspense(object) {\n return typeOf(object) === REACT_SUSPENSE_TYPE;\n}\n\nexports.AsyncMode = AsyncMode;\nexports.ConcurrentMode = ConcurrentMode;\nexports.ContextConsumer = ContextConsumer;\nexports.ContextProvider = ContextProvider;\nexports.Element = Element;\nexports.ForwardRef = ForwardRef;\nexports.Fragment = Fragment;\nexports.Lazy = Lazy;\nexports.Memo = Memo;\nexports.Portal = Portal;\nexports.Profiler = Profiler;\nexports.StrictMode = StrictMode;\nexports.Suspense = Suspense;\nexports.isAsyncMode = isAsyncMode;\nexports.isConcurrentMode = isConcurrentMode;\nexports.isContextConsumer = isContextConsumer;\nexports.isContextProvider = isContextProvider;\nexports.isElement = isElement;\nexports.isForwardRef = isForwardRef;\nexports.isFragment = isFragment;\nexports.isLazy = isLazy;\nexports.isMemo = isMemo;\nexports.isPortal = isPortal;\nexports.isProfiler = isProfiler;\nexports.isStrictMode = isStrictMode;\nexports.isSuspense = isSuspense;\nexports.isValidElementType = isValidElementType;\nexports.typeOf = typeOf;\n })();\n}\n","'use strict';\n\nif (process.env.NODE_ENV === 'production') {\n module.exports = require('./cjs/react-is.production.min.js');\n} else {\n module.exports = require('./cjs/react-is.development.js');\n}\n","/*\nobject-assign\n(c) Sindre Sorhus\n@license MIT\n*/\n\n'use strict';\n/* eslint-disable no-unused-vars */\nvar getOwnPropertySymbols = Object.getOwnPropertySymbols;\nvar hasOwnProperty = Object.prototype.hasOwnProperty;\nvar propIsEnumerable = Object.prototype.propertyIsEnumerable;\n\nfunction toObject(val) {\n\tif (val === null || val === undefined) {\n\t\tthrow new TypeError('Object.assign cannot be called with null or undefined');\n\t}\n\n\treturn Object(val);\n}\n\nfunction shouldUseNative() {\n\ttry {\n\t\tif (!Object.assign) {\n\t\t\treturn false;\n\t\t}\n\n\t\t// Detect buggy property enumeration order in older V8 versions.\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=4118\n\t\tvar test1 = new String('abc'); // eslint-disable-line no-new-wrappers\n\t\ttest1[5] = 'de';\n\t\tif (Object.getOwnPropertyNames(test1)[0] === '5') {\n\t\t\treturn false;\n\t\t}\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=3056\n\t\tvar test2 = {};\n\t\tfor (var i = 0; i < 10; i++) {\n\t\t\ttest2['_' + String.fromCharCode(i)] = i;\n\t\t}\n\t\tvar order2 = Object.getOwnPropertyNames(test2).map(function (n) {\n\t\t\treturn test2[n];\n\t\t});\n\t\tif (order2.join('') !== '0123456789') {\n\t\t\treturn false;\n\t\t}\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=3056\n\t\tvar test3 = {};\n\t\t'abcdefghijklmnopqrst'.split('').forEach(function (letter) {\n\t\t\ttest3[letter] = letter;\n\t\t});\n\t\tif (Object.keys(Object.assign({}, test3)).join('') !==\n\t\t\t\t'abcdefghijklmnopqrst') {\n\t\t\treturn false;\n\t\t}\n\n\t\treturn true;\n\t} catch (err) {\n\t\t// We don't expect any of the above to throw, but better to be safe.\n\t\treturn false;\n\t}\n}\n\nmodule.exports = shouldUseNative() ? Object.assign : function (target, source) {\n\tvar from;\n\tvar to = toObject(target);\n\tvar symbols;\n\n\tfor (var s = 1; s < arguments.length; s++) {\n\t\tfrom = Object(arguments[s]);\n\n\t\tfor (var key in from) {\n\t\t\tif (hasOwnProperty.call(from, key)) {\n\t\t\t\tto[key] = from[key];\n\t\t\t}\n\t\t}\n\n\t\tif (getOwnPropertySymbols) {\n\t\t\tsymbols = getOwnPropertySymbols(from);\n\t\t\tfor (var i = 0; i < symbols.length; i++) {\n\t\t\t\tif (propIsEnumerable.call(from, symbols[i])) {\n\t\t\t\t\tto[symbols[i]] = from[symbols[i]];\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\n\treturn to;\n};\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar ReactPropTypesSecret = 'SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED';\n\nmodule.exports = ReactPropTypesSecret;\n","module.exports = Function.call.bind(Object.prototype.hasOwnProperty);\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar printWarning = function() {};\n\nif (process.env.NODE_ENV !== 'production') {\n var ReactPropTypesSecret = require('./lib/ReactPropTypesSecret');\n var loggedTypeFailures = {};\n var has = require('./lib/has');\n\n printWarning = function(text) {\n var message = 'Warning: ' + text;\n if (typeof console !== 'undefined') {\n console.error(message);\n }\n try {\n // --- Welcome to debugging React ---\n // This error was thrown as a convenience so that you can use this stack\n // to find the callsite that caused this warning to fire.\n throw new Error(message);\n } catch (x) { /**/ }\n };\n}\n\n/**\n * Assert that the values match with the type specs.\n * Error messages are memorized and will only be shown once.\n *\n * @param {object} typeSpecs Map of name to a ReactPropType\n * @param {object} values Runtime values that need to be type-checked\n * @param {string} location e.g. \"prop\", \"context\", \"child context\"\n * @param {string} componentName Name of the component for error messages.\n * @param {?Function} getStack Returns the component stack.\n * @private\n */\nfunction checkPropTypes(typeSpecs, values, location, componentName, getStack) {\n if (process.env.NODE_ENV !== 'production') {\n for (var typeSpecName in typeSpecs) {\n if (has(typeSpecs, typeSpecName)) {\n var error;\n // Prop type validation may throw. In case they do, we don't want to\n // fail the render phase where it didn't fail before. So we log it.\n // After these have been cleaned up, we'll let them throw.\n try {\n // This is intentionally an invariant that gets caught. It's the same\n // behavior as without this statement except with a better message.\n if (typeof typeSpecs[typeSpecName] !== 'function') {\n var err = Error(\n (componentName || 'React class') + ': ' + location + ' type `' + typeSpecName + '` is invalid; ' +\n 'it must be a function, usually from the `prop-types` package, but received `' + typeof typeSpecs[typeSpecName] + '`.' +\n 'This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.'\n );\n err.name = 'Invariant Violation';\n throw err;\n }\n error = typeSpecs[typeSpecName](values, typeSpecName, componentName, location, null, ReactPropTypesSecret);\n } catch (ex) {\n error = ex;\n }\n if (error && !(error instanceof Error)) {\n printWarning(\n (componentName || 'React class') + ': type specification of ' +\n location + ' `' + typeSpecName + '` is invalid; the type checker ' +\n 'function must return `null` or an `Error` but returned a ' + typeof error + '. ' +\n 'You may have forgotten to pass an argument to the type checker ' +\n 'creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and ' +\n 'shape all require an argument).'\n );\n }\n if (error instanceof Error && !(error.message in loggedTypeFailures)) {\n // Only monitor this failure once because there tends to be a lot of the\n // same error.\n loggedTypeFailures[error.message] = true;\n\n var stack = getStack ? getStack() : '';\n\n printWarning(\n 'Failed ' + location + ' type: ' + error.message + (stack != null ? stack : '')\n );\n }\n }\n }\n }\n}\n\n/**\n * Resets warning cache when testing.\n *\n * @private\n */\ncheckPropTypes.resetWarningCache = function() {\n if (process.env.NODE_ENV !== 'production') {\n loggedTypeFailures = {};\n }\n}\n\nmodule.exports = checkPropTypes;\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar ReactIs = require('react-is');\nvar assign = require('object-assign');\n\nvar ReactPropTypesSecret = require('./lib/ReactPropTypesSecret');\nvar has = require('./lib/has');\nvar checkPropTypes = require('./checkPropTypes');\n\nvar printWarning = function() {};\n\nif (process.env.NODE_ENV !== 'production') {\n printWarning = function(text) {\n var message = 'Warning: ' + text;\n if (typeof console !== 'undefined') {\n console.error(message);\n }\n try {\n // --- Welcome to debugging React ---\n // This error was thrown as a convenience so that you can use this stack\n // to find the callsite that caused this warning to fire.\n throw new Error(message);\n } catch (x) {}\n };\n}\n\nfunction emptyFunctionThatReturnsNull() {\n return null;\n}\n\nmodule.exports = function(isValidElement, throwOnDirectAccess) {\n /* global Symbol */\n var ITERATOR_SYMBOL = typeof Symbol === 'function' && Symbol.iterator;\n var FAUX_ITERATOR_SYMBOL = '@@iterator'; // Before Symbol spec.\n\n /**\n * Returns the iterator method function contained on the iterable object.\n *\n * Be sure to invoke the function with the iterable as context:\n *\n * var iteratorFn = getIteratorFn(myIterable);\n * if (iteratorFn) {\n * var iterator = iteratorFn.call(myIterable);\n * ...\n * }\n *\n * @param {?object} maybeIterable\n * @return {?function}\n */\n function getIteratorFn(maybeIterable) {\n var iteratorFn = maybeIterable && (ITERATOR_SYMBOL && maybeIterable[ITERATOR_SYMBOL] || maybeIterable[FAUX_ITERATOR_SYMBOL]);\n if (typeof iteratorFn === 'function') {\n return iteratorFn;\n }\n }\n\n /**\n * Collection of methods that allow declaration and validation of props that are\n * supplied to React components. Example usage:\n *\n * var Props = require('ReactPropTypes');\n * var MyArticle = React.createClass({\n * propTypes: {\n * // An optional string prop named \"description\".\n * description: Props.string,\n *\n * // A required enum prop named \"category\".\n * category: Props.oneOf(['News','Photos']).isRequired,\n *\n * // A prop named \"dialog\" that requires an instance of Dialog.\n * dialog: Props.instanceOf(Dialog).isRequired\n * },\n * render: function() { ... }\n * });\n *\n * A more formal specification of how these methods are used:\n *\n * type := array|bool|func|object|number|string|oneOf([...])|instanceOf(...)\n * decl := ReactPropTypes.{type}(.isRequired)?\n *\n * Each and every declaration produces a function with the same signature. This\n * allows the creation of custom validation functions. For example:\n *\n * var MyLink = React.createClass({\n * propTypes: {\n * // An optional string or URI prop named \"href\".\n * href: function(props, propName, componentName) {\n * var propValue = props[propName];\n * if (propValue != null && typeof propValue !== 'string' &&\n * !(propValue instanceof URI)) {\n * return new Error(\n * 'Expected a string or an URI for ' + propName + ' in ' +\n * componentName\n * );\n * }\n * }\n * },\n * render: function() {...}\n * });\n *\n * @internal\n */\n\n var ANONYMOUS = '<>';\n\n // Important!\n // Keep this list in sync with production version in `./factoryWithThrowingShims.js`.\n var ReactPropTypes = {\n array: createPrimitiveTypeChecker('array'),\n bigint: createPrimitiveTypeChecker('bigint'),\n bool: createPrimitiveTypeChecker('boolean'),\n func: createPrimitiveTypeChecker('function'),\n number: createPrimitiveTypeChecker('number'),\n object: createPrimitiveTypeChecker('object'),\n string: createPrimitiveTypeChecker('string'),\n symbol: createPrimitiveTypeChecker('symbol'),\n\n any: createAnyTypeChecker(),\n arrayOf: createArrayOfTypeChecker,\n element: createElementTypeChecker(),\n elementType: createElementTypeTypeChecker(),\n instanceOf: createInstanceTypeChecker,\n node: createNodeChecker(),\n objectOf: createObjectOfTypeChecker,\n oneOf: createEnumTypeChecker,\n oneOfType: createUnionTypeChecker,\n shape: createShapeTypeChecker,\n exact: createStrictShapeTypeChecker,\n };\n\n /**\n * inlined Object.is polyfill to avoid requiring consumers ship their own\n * https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object/is\n */\n /*eslint-disable no-self-compare*/\n function is(x, y) {\n // SameValue algorithm\n if (x === y) {\n // Steps 1-5, 7-10\n // Steps 6.b-6.e: +0 != -0\n return x !== 0 || 1 / x === 1 / y;\n } else {\n // Step 6.a: NaN == NaN\n return x !== x && y !== y;\n }\n }\n /*eslint-enable no-self-compare*/\n\n /**\n * We use an Error-like object for backward compatibility as people may call\n * PropTypes directly and inspect their output. However, we don't use real\n * Errors anymore. We don't inspect their stack anyway, and creating them\n * is prohibitively expensive if they are created too often, such as what\n * happens in oneOfType() for any type before the one that matched.\n */\n function PropTypeError(message, data) {\n this.message = message;\n this.data = data && typeof data === 'object' ? data: {};\n this.stack = '';\n }\n // Make `instanceof Error` still work for returned errors.\n PropTypeError.prototype = Error.prototype;\n\n function createChainableTypeChecker(validate) {\n if (process.env.NODE_ENV !== 'production') {\n var manualPropTypeCallCache = {};\n var manualPropTypeWarningCount = 0;\n }\n function checkType(isRequired, props, propName, componentName, location, propFullName, secret) {\n componentName = componentName || ANONYMOUS;\n propFullName = propFullName || propName;\n\n if (secret !== ReactPropTypesSecret) {\n if (throwOnDirectAccess) {\n // New behavior only for users of `prop-types` package\n var err = new Error(\n 'Calling PropTypes validators directly is not supported by the `prop-types` package. ' +\n 'Use `PropTypes.checkPropTypes()` to call them. ' +\n 'Read more at http://fb.me/use-check-prop-types'\n );\n err.name = 'Invariant Violation';\n throw err;\n } else if (process.env.NODE_ENV !== 'production' && typeof console !== 'undefined') {\n // Old behavior for people using React.PropTypes\n var cacheKey = componentName + ':' + propName;\n if (\n !manualPropTypeCallCache[cacheKey] &&\n // Avoid spamming the console because they are often not actionable except for lib authors\n manualPropTypeWarningCount < 3\n ) {\n printWarning(\n 'You are manually calling a React.PropTypes validation ' +\n 'function for the `' + propFullName + '` prop on `' + componentName + '`. This is deprecated ' +\n 'and will throw in the standalone `prop-types` package. ' +\n 'You may be seeing this warning due to a third-party PropTypes ' +\n 'library. See https://fb.me/react-warning-dont-call-proptypes ' + 'for details.'\n );\n manualPropTypeCallCache[cacheKey] = true;\n manualPropTypeWarningCount++;\n }\n }\n }\n if (props[propName] == null) {\n if (isRequired) {\n if (props[propName] === null) {\n return new PropTypeError('The ' + location + ' `' + propFullName + '` is marked as required ' + ('in `' + componentName + '`, but its value is `null`.'));\n }\n return new PropTypeError('The ' + location + ' `' + propFullName + '` is marked as required in ' + ('`' + componentName + '`, but its value is `undefined`.'));\n }\n return null;\n } else {\n return validate(props, propName, componentName, location, propFullName);\n }\n }\n\n var chainedCheckType = checkType.bind(null, false);\n chainedCheckType.isRequired = checkType.bind(null, true);\n\n return chainedCheckType;\n }\n\n function createPrimitiveTypeChecker(expectedType) {\n function validate(props, propName, componentName, location, propFullName, secret) {\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== expectedType) {\n // `propValue` being instance of, say, date/regexp, pass the 'object'\n // check, but we can offer a more precise error message here rather than\n // 'of type `object`'.\n var preciseType = getPreciseType(propValue);\n\n return new PropTypeError(\n 'Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + preciseType + '` supplied to `' + componentName + '`, expected ') + ('`' + expectedType + '`.'),\n {expectedType: expectedType}\n );\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createAnyTypeChecker() {\n return createChainableTypeChecker(emptyFunctionThatReturnsNull);\n }\n\n function createArrayOfTypeChecker(typeChecker) {\n function validate(props, propName, componentName, location, propFullName) {\n if (typeof typeChecker !== 'function') {\n return new PropTypeError('Property `' + propFullName + '` of component `' + componentName + '` has invalid PropType notation inside arrayOf.');\n }\n var propValue = props[propName];\n if (!Array.isArray(propValue)) {\n var propType = getPropType(propValue);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected an array.'));\n }\n for (var i = 0; i < propValue.length; i++) {\n var error = typeChecker(propValue, i, componentName, location, propFullName + '[' + i + ']', ReactPropTypesSecret);\n if (error instanceof Error) {\n return error;\n }\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createElementTypeChecker() {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n if (!isValidElement(propValue)) {\n var propType = getPropType(propValue);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected a single ReactElement.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createElementTypeTypeChecker() {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n if (!ReactIs.isValidElementType(propValue)) {\n var propType = getPropType(propValue);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected a single ReactElement type.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createInstanceTypeChecker(expectedClass) {\n function validate(props, propName, componentName, location, propFullName) {\n if (!(props[propName] instanceof expectedClass)) {\n var expectedClassName = expectedClass.name || ANONYMOUS;\n var actualClassName = getClassName(props[propName]);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + actualClassName + '` supplied to `' + componentName + '`, expected ') + ('instance of `' + expectedClassName + '`.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createEnumTypeChecker(expectedValues) {\n if (!Array.isArray(expectedValues)) {\n if (process.env.NODE_ENV !== 'production') {\n if (arguments.length > 1) {\n printWarning(\n 'Invalid arguments supplied to oneOf, expected an array, got ' + arguments.length + ' arguments. ' +\n 'A common mistake is to write oneOf(x, y, z) instead of oneOf([x, y, z]).'\n );\n } else {\n printWarning('Invalid argument supplied to oneOf, expected an array.');\n }\n }\n return emptyFunctionThatReturnsNull;\n }\n\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n for (var i = 0; i < expectedValues.length; i++) {\n if (is(propValue, expectedValues[i])) {\n return null;\n }\n }\n\n var valuesString = JSON.stringify(expectedValues, function replacer(key, value) {\n var type = getPreciseType(value);\n if (type === 'symbol') {\n return String(value);\n }\n return value;\n });\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of value `' + String(propValue) + '` ' + ('supplied to `' + componentName + '`, expected one of ' + valuesString + '.'));\n }\n return createChainableTypeChecker(validate);\n }\n\n function createObjectOfTypeChecker(typeChecker) {\n function validate(props, propName, componentName, location, propFullName) {\n if (typeof typeChecker !== 'function') {\n return new PropTypeError('Property `' + propFullName + '` of component `' + componentName + '` has invalid PropType notation inside objectOf.');\n }\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== 'object') {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected an object.'));\n }\n for (var key in propValue) {\n if (has(propValue, key)) {\n var error = typeChecker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret);\n if (error instanceof Error) {\n return error;\n }\n }\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createUnionTypeChecker(arrayOfTypeCheckers) {\n if (!Array.isArray(arrayOfTypeCheckers)) {\n process.env.NODE_ENV !== 'production' ? printWarning('Invalid argument supplied to oneOfType, expected an instance of array.') : void 0;\n return emptyFunctionThatReturnsNull;\n }\n\n for (var i = 0; i < arrayOfTypeCheckers.length; i++) {\n var checker = arrayOfTypeCheckers[i];\n if (typeof checker !== 'function') {\n printWarning(\n 'Invalid argument supplied to oneOfType. Expected an array of check functions, but ' +\n 'received ' + getPostfixForTypeWarning(checker) + ' at index ' + i + '.'\n );\n return emptyFunctionThatReturnsNull;\n }\n }\n\n function validate(props, propName, componentName, location, propFullName) {\n var expectedTypes = [];\n for (var i = 0; i < arrayOfTypeCheckers.length; i++) {\n var checker = arrayOfTypeCheckers[i];\n var checkerResult = checker(props, propName, componentName, location, propFullName, ReactPropTypesSecret);\n if (checkerResult == null) {\n return null;\n }\n if (checkerResult.data && has(checkerResult.data, 'expectedType')) {\n expectedTypes.push(checkerResult.data.expectedType);\n }\n }\n var expectedTypesMessage = (expectedTypes.length > 0) ? ', expected one of type [' + expectedTypes.join(', ') + ']': '';\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` supplied to ' + ('`' + componentName + '`' + expectedTypesMessage + '.'));\n }\n return createChainableTypeChecker(validate);\n }\n\n function createNodeChecker() {\n function validate(props, propName, componentName, location, propFullName) {\n if (!isNode(props[propName])) {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` supplied to ' + ('`' + componentName + '`, expected a ReactNode.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function invalidValidatorError(componentName, location, propFullName, key, type) {\n return new PropTypeError(\n (componentName || 'React class') + ': ' + location + ' type `' + propFullName + '.' + key + '` is invalid; ' +\n 'it must be a function, usually from the `prop-types` package, but received `' + type + '`.'\n );\n }\n\n function createShapeTypeChecker(shapeTypes) {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== 'object') {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type `' + propType + '` ' + ('supplied to `' + componentName + '`, expected `object`.'));\n }\n for (var key in shapeTypes) {\n var checker = shapeTypes[key];\n if (typeof checker !== 'function') {\n return invalidValidatorError(componentName, location, propFullName, key, getPreciseType(checker));\n }\n var error = checker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret);\n if (error) {\n return error;\n }\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createStrictShapeTypeChecker(shapeTypes) {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== 'object') {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type `' + propType + '` ' + ('supplied to `' + componentName + '`, expected `object`.'));\n }\n // We need to check all keys in case some are required but missing from props.\n var allKeys = assign({}, props[propName], shapeTypes);\n for (var key in allKeys) {\n var checker = shapeTypes[key];\n if (has(shapeTypes, key) && typeof checker !== 'function') {\n return invalidValidatorError(componentName, location, propFullName, key, getPreciseType(checker));\n }\n if (!checker) {\n return new PropTypeError(\n 'Invalid ' + location + ' `' + propFullName + '` key `' + key + '` supplied to `' + componentName + '`.' +\n '\\nBad object: ' + JSON.stringify(props[propName], null, ' ') +\n '\\nValid keys: ' + JSON.stringify(Object.keys(shapeTypes), null, ' ')\n );\n }\n var error = checker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret);\n if (error) {\n return error;\n }\n }\n return null;\n }\n\n return createChainableTypeChecker(validate);\n }\n\n function isNode(propValue) {\n switch (typeof propValue) {\n case 'number':\n case 'string':\n case 'undefined':\n return true;\n case 'boolean':\n return !propValue;\n case 'object':\n if (Array.isArray(propValue)) {\n return propValue.every(isNode);\n }\n if (propValue === null || isValidElement(propValue)) {\n return true;\n }\n\n var iteratorFn = getIteratorFn(propValue);\n if (iteratorFn) {\n var iterator = iteratorFn.call(propValue);\n var step;\n if (iteratorFn !== propValue.entries) {\n while (!(step = iterator.next()).done) {\n if (!isNode(step.value)) {\n return false;\n }\n }\n } else {\n // Iterator will provide entry [k,v] tuples rather than values.\n while (!(step = iterator.next()).done) {\n var entry = step.value;\n if (entry) {\n if (!isNode(entry[1])) {\n return false;\n }\n }\n }\n }\n } else {\n return false;\n }\n\n return true;\n default:\n return false;\n }\n }\n\n function isSymbol(propType, propValue) {\n // Native Symbol.\n if (propType === 'symbol') {\n return true;\n }\n\n // falsy value can't be a Symbol\n if (!propValue) {\n return false;\n }\n\n // 19.4.3.5 Symbol.prototype[@@toStringTag] === 'Symbol'\n if (propValue['@@toStringTag'] === 'Symbol') {\n return true;\n }\n\n // Fallback for non-spec compliant Symbols which are polyfilled.\n if (typeof Symbol === 'function' && propValue instanceof Symbol) {\n return true;\n }\n\n return false;\n }\n\n // Equivalent of `typeof` but with special handling for array and regexp.\n function getPropType(propValue) {\n var propType = typeof propValue;\n if (Array.isArray(propValue)) {\n return 'array';\n }\n if (propValue instanceof RegExp) {\n // Old webkits (at least until Android 4.0) return 'function' rather than\n // 'object' for typeof a RegExp. We'll normalize this here so that /bla/\n // passes PropTypes.object.\n return 'object';\n }\n if (isSymbol(propType, propValue)) {\n return 'symbol';\n }\n return propType;\n }\n\n // This handles more types than `getPropType`. Only used for error messages.\n // See `createPrimitiveTypeChecker`.\n function getPreciseType(propValue) {\n if (typeof propValue === 'undefined' || propValue === null) {\n return '' + propValue;\n }\n var propType = getPropType(propValue);\n if (propType === 'object') {\n if (propValue instanceof Date) {\n return 'date';\n } else if (propValue instanceof RegExp) {\n return 'regexp';\n }\n }\n return propType;\n }\n\n // Returns a string that is postfixed to a warning about an invalid type.\n // For example, \"undefined\" or \"of type array\"\n function getPostfixForTypeWarning(value) {\n var type = getPreciseType(value);\n switch (type) {\n case 'array':\n case 'object':\n return 'an ' + type;\n case 'boolean':\n case 'date':\n case 'regexp':\n return 'a ' + type;\n default:\n return type;\n }\n }\n\n // Returns class name of the object, if any.\n function getClassName(propValue) {\n if (!propValue.constructor || !propValue.constructor.name) {\n return ANONYMOUS;\n }\n return propValue.constructor.name;\n }\n\n ReactPropTypes.checkPropTypes = checkPropTypes;\n ReactPropTypes.resetWarningCache = checkPropTypes.resetWarningCache;\n ReactPropTypes.PropTypes = ReactPropTypes;\n\n return ReactPropTypes;\n};\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar ReactPropTypesSecret = require('./lib/ReactPropTypesSecret');\n\nfunction emptyFunction() {}\nfunction emptyFunctionWithReset() {}\nemptyFunctionWithReset.resetWarningCache = emptyFunction;\n\nmodule.exports = function() {\n function shim(props, propName, componentName, location, propFullName, secret) {\n if (secret === ReactPropTypesSecret) {\n // It is still safe when called from React.\n return;\n }\n var err = new Error(\n 'Calling PropTypes validators directly is not supported by the `prop-types` package. ' +\n 'Use PropTypes.checkPropTypes() to call them. ' +\n 'Read more at http://fb.me/use-check-prop-types'\n );\n err.name = 'Invariant Violation';\n throw err;\n };\n shim.isRequired = shim;\n function getShim() {\n return shim;\n };\n // Important!\n // Keep this list in sync with production version in `./factoryWithTypeCheckers.js`.\n var ReactPropTypes = {\n array: shim,\n bigint: shim,\n bool: shim,\n func: shim,\n number: shim,\n object: shim,\n string: shim,\n symbol: shim,\n\n any: shim,\n arrayOf: getShim,\n element: shim,\n elementType: shim,\n instanceOf: getShim,\n node: shim,\n objectOf: getShim,\n oneOf: getShim,\n oneOfType: getShim,\n shape: getShim,\n exact: getShim,\n\n checkPropTypes: emptyFunctionWithReset,\n resetWarningCache: emptyFunction\n };\n\n ReactPropTypes.PropTypes = ReactPropTypes;\n\n return ReactPropTypes;\n};\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\nif (process.env.NODE_ENV !== 'production') {\n var ReactIs = require('react-is');\n\n // By explicitly using `prop-types` you are opting into new development behavior.\n // http://fb.me/prop-types-in-prod\n var throwOnDirectAccess = true;\n module.exports = require('./factoryWithTypeCheckers')(ReactIs.isElement, throwOnDirectAccess);\n} else {\n // By explicitly using `prop-types` you are opting into new production behavior.\n // http://fb.me/prop-types-in-prod\n module.exports = require('./factoryWithThrowingShims')();\n}\n","import PropTypes from 'prop-types';\nimport chainPropTypes from '../chainPropTypes';\nfunction isClassComponent(elementType) {\n // elementType.prototype?.isReactComponent\n const {\n prototype = {}\n } = elementType;\n return Boolean(prototype.isReactComponent);\n}\nfunction acceptingRef(props, propName, componentName, location, propFullName) {\n const element = props[propName];\n const safePropName = propFullName || propName;\n if (element == null ||\n // When server-side rendering React doesn't warn either.\n // This is not an accurate check for SSR.\n // This is only in place for Emotion compat.\n // TODO: Revisit once https://github.com/facebook/react/issues/20047 is resolved.\n typeof window === 'undefined') {\n return null;\n }\n let warningHint;\n const elementType = element.type;\n /**\n * Blacklisting instead of whitelisting\n *\n * Blacklisting will miss some components, such as React.Fragment. Those will at least\n * trigger a warning in React.\n * We can't whitelist because there is no safe way to detect React.forwardRef\n * or class components. \"Safe\" means there's no public API.\n *\n */\n if (typeof elementType === 'function' && !isClassComponent(elementType)) {\n warningHint = 'Did you accidentally use a plain function component for an element instead?';\n }\n if (warningHint !== undefined) {\n return new Error(`Invalid ${location} \\`${safePropName}\\` supplied to \\`${componentName}\\`. ` + `Expected an element that can hold a ref. ${warningHint} ` + 'For more information see https://mui.com/r/caveat-with-refs-guide');\n }\n return null;\n}\nconst elementAcceptingRef = chainPropTypes(PropTypes.element, acceptingRef);\nelementAcceptingRef.isRequired = chainPropTypes(PropTypes.element.isRequired, acceptingRef);\nexport default elementAcceptingRef;","import _extends from \"@babel/runtime/helpers/esm/extends\";\n// This module is based on https://github.com/airbnb/prop-types-exact repository.\n// However, in order to reduce the number of dependencies and to remove some extra safe checks\n// the module was forked.\n\nconst specialProperty = 'exact-prop: \\u200b';\nexport default function exactProp(propTypes) {\n if (process.env.NODE_ENV === 'production') {\n return propTypes;\n }\n return _extends({}, propTypes, {\n [specialProperty]: props => {\n const unsupportedProps = Object.keys(props).filter(prop => !propTypes.hasOwnProperty(prop));\n if (unsupportedProps.length > 0) {\n return new Error(`The following props are not supported: ${unsupportedProps.map(prop => `\\`${prop}\\``).join(', ')}. Please remove them.`);\n }\n return null;\n }\n });\n}","/**\n * WARNING: Don't import this directly.\n * Use `MuiError` from `@mui/internal-babel-macros/MuiError.macro` instead.\n * @param {number} code\n */\nexport default function formatMuiErrorMessage(code) {\n // Apply babel-plugin-transform-template-literals in loose mode\n // loose mode is safe if we're concatenating primitives\n // see https://babeljs.io/docs/en/babel-plugin-transform-template-literals#loose\n /* eslint-disable prefer-template */\n let url = 'https://mui.com/production-error/?code=' + code;\n for (let i = 1; i < arguments.length; i += 1) {\n // rest params over-transpile for this case\n // eslint-disable-next-line prefer-rest-params\n url += '&args[]=' + encodeURIComponent(arguments[i]);\n }\n return 'Minified MUI error #' + code + '; visit ' + url + ' for the full message.';\n /* eslint-enable prefer-template */\n}","/**\n * @license React\n * react-is.production.min.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n'use strict';var b=Symbol.for(\"react.element\"),c=Symbol.for(\"react.portal\"),d=Symbol.for(\"react.fragment\"),e=Symbol.for(\"react.strict_mode\"),f=Symbol.for(\"react.profiler\"),g=Symbol.for(\"react.provider\"),h=Symbol.for(\"react.context\"),k=Symbol.for(\"react.server_context\"),l=Symbol.for(\"react.forward_ref\"),m=Symbol.for(\"react.suspense\"),n=Symbol.for(\"react.suspense_list\"),p=Symbol.for(\"react.memo\"),q=Symbol.for(\"react.lazy\"),t=Symbol.for(\"react.offscreen\"),u;u=Symbol.for(\"react.module.reference\");\nfunction v(a){if(\"object\"===typeof a&&null!==a){var r=a.$$typeof;switch(r){case b:switch(a=a.type,a){case d:case f:case e:case m:case n:return a;default:switch(a=a&&a.$$typeof,a){case k:case h:case l:case q:case p:case g:return a;default:return r}}case c:return r}}}exports.ContextConsumer=h;exports.ContextProvider=g;exports.Element=b;exports.ForwardRef=l;exports.Fragment=d;exports.Lazy=q;exports.Memo=p;exports.Portal=c;exports.Profiler=f;exports.StrictMode=e;exports.Suspense=m;\nexports.SuspenseList=n;exports.isAsyncMode=function(){return!1};exports.isConcurrentMode=function(){return!1};exports.isContextConsumer=function(a){return v(a)===h};exports.isContextProvider=function(a){return v(a)===g};exports.isElement=function(a){return\"object\"===typeof a&&null!==a&&a.$$typeof===b};exports.isForwardRef=function(a){return v(a)===l};exports.isFragment=function(a){return v(a)===d};exports.isLazy=function(a){return v(a)===q};exports.isMemo=function(a){return v(a)===p};\nexports.isPortal=function(a){return v(a)===c};exports.isProfiler=function(a){return v(a)===f};exports.isStrictMode=function(a){return v(a)===e};exports.isSuspense=function(a){return v(a)===m};exports.isSuspenseList=function(a){return v(a)===n};\nexports.isValidElementType=function(a){return\"string\"===typeof a||\"function\"===typeof a||a===d||a===f||a===e||a===m||a===n||a===t||\"object\"===typeof a&&null!==a&&(a.$$typeof===q||a.$$typeof===p||a.$$typeof===g||a.$$typeof===h||a.$$typeof===l||a.$$typeof===u||void 0!==a.getModuleId)?!0:!1};exports.typeOf=v;\n","/**\n * @license React\n * react-is.development.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nif (process.env.NODE_ENV !== \"production\") {\n (function() {\n'use strict';\n\n// ATTENTION\n// When adding new symbols to this file,\n// Please consider also adding to 'react-devtools-shared/src/backend/ReactSymbols'\n// The Symbol used to tag the ReactElement-like types.\nvar REACT_ELEMENT_TYPE = Symbol.for('react.element');\nvar REACT_PORTAL_TYPE = Symbol.for('react.portal');\nvar REACT_FRAGMENT_TYPE = Symbol.for('react.fragment');\nvar REACT_STRICT_MODE_TYPE = Symbol.for('react.strict_mode');\nvar REACT_PROFILER_TYPE = Symbol.for('react.profiler');\nvar REACT_PROVIDER_TYPE = Symbol.for('react.provider');\nvar REACT_CONTEXT_TYPE = Symbol.for('react.context');\nvar REACT_SERVER_CONTEXT_TYPE = Symbol.for('react.server_context');\nvar REACT_FORWARD_REF_TYPE = Symbol.for('react.forward_ref');\nvar REACT_SUSPENSE_TYPE = Symbol.for('react.suspense');\nvar REACT_SUSPENSE_LIST_TYPE = Symbol.for('react.suspense_list');\nvar REACT_MEMO_TYPE = Symbol.for('react.memo');\nvar REACT_LAZY_TYPE = Symbol.for('react.lazy');\nvar REACT_OFFSCREEN_TYPE = Symbol.for('react.offscreen');\n\n// -----------------------------------------------------------------------------\n\nvar enableScopeAPI = false; // Experimental Create Event Handle API.\nvar enableCacheElement = false;\nvar enableTransitionTracing = false; // No known bugs, but needs performance testing\n\nvar enableLegacyHidden = false; // Enables unstable_avoidThisFallback feature in Fiber\n// stuff. Intended to enable React core members to more easily debug scheduling\n// issues in DEV builds.\n\nvar enableDebugTracing = false; // Track which Fiber(s) schedule render work.\n\nvar REACT_MODULE_REFERENCE;\n\n{\n REACT_MODULE_REFERENCE = Symbol.for('react.module.reference');\n}\n\nfunction isValidElementType(type) {\n if (typeof type === 'string' || typeof type === 'function') {\n return true;\n } // Note: typeof might be other than 'symbol' or 'number' (e.g. if it's a polyfill).\n\n\n if (type === REACT_FRAGMENT_TYPE || type === REACT_PROFILER_TYPE || enableDebugTracing || type === REACT_STRICT_MODE_TYPE || type === REACT_SUSPENSE_TYPE || type === REACT_SUSPENSE_LIST_TYPE || enableLegacyHidden || type === REACT_OFFSCREEN_TYPE || enableScopeAPI || enableCacheElement || enableTransitionTracing ) {\n return true;\n }\n\n if (typeof type === 'object' && type !== null) {\n if (type.$$typeof === REACT_LAZY_TYPE || type.$$typeof === REACT_MEMO_TYPE || type.$$typeof === REACT_PROVIDER_TYPE || type.$$typeof === REACT_CONTEXT_TYPE || type.$$typeof === REACT_FORWARD_REF_TYPE || // This needs to include all possible module reference object\n // types supported by any Flight configuration anywhere since\n // we don't know which Flight build this will end up being used\n // with.\n type.$$typeof === REACT_MODULE_REFERENCE || type.getModuleId !== undefined) {\n return true;\n }\n }\n\n return false;\n}\n\nfunction typeOf(object) {\n if (typeof object === 'object' && object !== null) {\n var $$typeof = object.$$typeof;\n\n switch ($$typeof) {\n case REACT_ELEMENT_TYPE:\n var type = object.type;\n\n switch (type) {\n case REACT_FRAGMENT_TYPE:\n case REACT_PROFILER_TYPE:\n case REACT_STRICT_MODE_TYPE:\n case REACT_SUSPENSE_TYPE:\n case REACT_SUSPENSE_LIST_TYPE:\n return type;\n\n default:\n var $$typeofType = type && type.$$typeof;\n\n switch ($$typeofType) {\n case REACT_SERVER_CONTEXT_TYPE:\n case REACT_CONTEXT_TYPE:\n case REACT_FORWARD_REF_TYPE:\n case REACT_LAZY_TYPE:\n case REACT_MEMO_TYPE:\n case REACT_PROVIDER_TYPE:\n return $$typeofType;\n\n default:\n return $$typeof;\n }\n\n }\n\n case REACT_PORTAL_TYPE:\n return $$typeof;\n }\n }\n\n return undefined;\n}\nvar ContextConsumer = REACT_CONTEXT_TYPE;\nvar ContextProvider = REACT_PROVIDER_TYPE;\nvar Element = REACT_ELEMENT_TYPE;\nvar ForwardRef = REACT_FORWARD_REF_TYPE;\nvar Fragment = REACT_FRAGMENT_TYPE;\nvar Lazy = REACT_LAZY_TYPE;\nvar Memo = REACT_MEMO_TYPE;\nvar Portal = REACT_PORTAL_TYPE;\nvar Profiler = REACT_PROFILER_TYPE;\nvar StrictMode = REACT_STRICT_MODE_TYPE;\nvar Suspense = REACT_SUSPENSE_TYPE;\nvar SuspenseList = REACT_SUSPENSE_LIST_TYPE;\nvar hasWarnedAboutDeprecatedIsAsyncMode = false;\nvar hasWarnedAboutDeprecatedIsConcurrentMode = false; // AsyncMode should be deprecated\n\nfunction isAsyncMode(object) {\n {\n if (!hasWarnedAboutDeprecatedIsAsyncMode) {\n hasWarnedAboutDeprecatedIsAsyncMode = true; // Using console['warn'] to evade Babel and ESLint\n\n console['warn']('The ReactIs.isAsyncMode() alias has been deprecated, ' + 'and will be removed in React 18+.');\n }\n }\n\n return false;\n}\nfunction isConcurrentMode(object) {\n {\n if (!hasWarnedAboutDeprecatedIsConcurrentMode) {\n hasWarnedAboutDeprecatedIsConcurrentMode = true; // Using console['warn'] to evade Babel and ESLint\n\n console['warn']('The ReactIs.isConcurrentMode() alias has been deprecated, ' + 'and will be removed in React 18+.');\n }\n }\n\n return false;\n}\nfunction isContextConsumer(object) {\n return typeOf(object) === REACT_CONTEXT_TYPE;\n}\nfunction isContextProvider(object) {\n return typeOf(object) === REACT_PROVIDER_TYPE;\n}\nfunction isElement(object) {\n return typeof object === 'object' && object !== null && object.$$typeof === REACT_ELEMENT_TYPE;\n}\nfunction isForwardRef(object) {\n return typeOf(object) === REACT_FORWARD_REF_TYPE;\n}\nfunction isFragment(object) {\n return typeOf(object) === REACT_FRAGMENT_TYPE;\n}\nfunction isLazy(object) {\n return typeOf(object) === REACT_LAZY_TYPE;\n}\nfunction isMemo(object) {\n return typeOf(object) === REACT_MEMO_TYPE;\n}\nfunction isPortal(object) {\n return typeOf(object) === REACT_PORTAL_TYPE;\n}\nfunction isProfiler(object) {\n return typeOf(object) === REACT_PROFILER_TYPE;\n}\nfunction isStrictMode(object) {\n return typeOf(object) === REACT_STRICT_MODE_TYPE;\n}\nfunction isSuspense(object) {\n return typeOf(object) === REACT_SUSPENSE_TYPE;\n}\nfunction isSuspenseList(object) {\n return typeOf(object) === REACT_SUSPENSE_LIST_TYPE;\n}\n\nexports.ContextConsumer = ContextConsumer;\nexports.ContextProvider = ContextProvider;\nexports.Element = Element;\nexports.ForwardRef = ForwardRef;\nexports.Fragment = Fragment;\nexports.Lazy = Lazy;\nexports.Memo = Memo;\nexports.Portal = Portal;\nexports.Profiler = Profiler;\nexports.StrictMode = StrictMode;\nexports.Suspense = Suspense;\nexports.SuspenseList = SuspenseList;\nexports.isAsyncMode = isAsyncMode;\nexports.isConcurrentMode = isConcurrentMode;\nexports.isContextConsumer = isContextConsumer;\nexports.isContextProvider = isContextProvider;\nexports.isElement = isElement;\nexports.isForwardRef = isForwardRef;\nexports.isFragment = isFragment;\nexports.isLazy = isLazy;\nexports.isMemo = isMemo;\nexports.isPortal = isPortal;\nexports.isProfiler = isProfiler;\nexports.isStrictMode = isStrictMode;\nexports.isSuspense = isSuspense;\nexports.isSuspenseList = isSuspenseList;\nexports.isValidElementType = isValidElementType;\nexports.typeOf = typeOf;\n })();\n}\n","'use strict';\n\nif (process.env.NODE_ENV === 'production') {\n module.exports = require('./cjs/react-is.production.min.js');\n} else {\n module.exports = require('./cjs/react-is.development.js');\n}\n","import { ForwardRef, Memo } from 'react-is';\n\n// Simplified polyfill for IE11 support\n// https://github.com/JamesMGreene/Function.name/blob/58b314d4a983110c3682f1228f845d39ccca1817/Function.name.js#L3\nconst fnNameMatchRegex = /^\\s*function(?:\\s|\\s*\\/\\*.*\\*\\/\\s*)+([^(\\s/]*)\\s*/;\nexport function getFunctionName(fn) {\n const match = `${fn}`.match(fnNameMatchRegex);\n const name = match && match[1];\n return name || '';\n}\nfunction getFunctionComponentName(Component, fallback = '') {\n return Component.displayName || Component.name || getFunctionName(Component) || fallback;\n}\nfunction getWrappedName(outerType, innerType, wrapperName) {\n const functionName = getFunctionComponentName(innerType);\n return outerType.displayName || (functionName !== '' ? `${wrapperName}(${functionName})` : wrapperName);\n}\n\n/**\n * cherry-pick from\n * https://github.com/facebook/react/blob/769b1f270e1251d9dbdce0fcbd9e92e502d059b8/packages/shared/getComponentName.js\n * originally forked from recompose/getDisplayName with added IE11 support\n */\nexport default function getDisplayName(Component) {\n if (Component == null) {\n return undefined;\n }\n if (typeof Component === 'string') {\n return Component;\n }\n if (typeof Component === 'function') {\n return getFunctionComponentName(Component, 'Component');\n }\n\n // TypeScript can't have components as objects but they exist in the form of `memo` or `Suspense`\n if (typeof Component === 'object') {\n switch (Component.$$typeof) {\n case ForwardRef:\n return getWrappedName(Component, Component.render, 'ForwardRef');\n case Memo:\n return getWrappedName(Component, Component.type, 'memo');\n default:\n return undefined;\n }\n }\n return undefined;\n}","export default function HTMLElementType(props, propName, componentName, location, propFullName) {\n if (process.env.NODE_ENV === 'production') {\n return null;\n }\n const propValue = props[propName];\n const safePropName = propFullName || propName;\n if (propValue == null) {\n return null;\n }\n if (propValue && propValue.nodeType !== 1) {\n return new Error(`Invalid ${location} \\`${safePropName}\\` supplied to \\`${componentName}\\`. ` + `Expected an HTMLElement.`);\n }\n return null;\n}","import PropTypes from 'prop-types';\nconst refType = PropTypes.oneOfType([PropTypes.func, PropTypes.object]);\nexport default refType;","import _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\n// It should to be noted that this function isn't equivalent to `text-transform: capitalize`.\n//\n// A strict capitalization should uppercase the first letter of each word in the sentence.\n// We only handle the first word.\nexport default function capitalize(string) {\n if (typeof string !== 'string') {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: \\`capitalize(string)\\` expects a string argument.` : _formatMuiErrorMessage(7));\n }\n return string.charAt(0).toUpperCase() + string.slice(1);\n}","/**\n * Safe chained function.\n *\n * Will only create a new function if needed,\n * otherwise will pass back existing functions or null.\n */\nexport default function createChainedFunction(...funcs) {\n return funcs.reduce((acc, func) => {\n if (func == null) {\n return acc;\n }\n return function chainedFunction(...args) {\n acc.apply(this, args);\n func.apply(this, args);\n };\n }, () => {});\n}","// Corresponds to 10 frames at 60 Hz.\n// A few bytes payload overhead when lodash/debounce is ~3 kB and debounce ~300 B.\nexport default function debounce(func, wait = 166) {\n let timeout;\n function debounced(...args) {\n const later = () => {\n // @ts-ignore\n func.apply(this, args);\n };\n clearTimeout(timeout);\n timeout = setTimeout(later, wait);\n }\n debounced.clear = () => {\n clearTimeout(timeout);\n };\n return debounced;\n}","export default function deprecatedPropType(validator, reason) {\n if (process.env.NODE_ENV === 'production') {\n return () => null;\n }\n return (props, propName, componentName, location, propFullName) => {\n const componentNameSafe = componentName || '<>';\n const propFullNameSafe = propFullName || propName;\n if (typeof props[propName] !== 'undefined') {\n return new Error(`The ${location} \\`${propFullNameSafe}\\` of ` + `\\`${componentNameSafe}\\` is deprecated. ${reason}`);\n }\n return null;\n };\n}","import * as React from 'react';\nexport default function isMuiElement(element, muiNames) {\n var _muiName, _element$type;\n return /*#__PURE__*/React.isValidElement(element) && muiNames.indexOf( // For server components `muiName` is avaialble in element.type._payload.value.muiName\n // relevant info - https://github.com/facebook/react/blob/2807d781a08db8e9873687fccc25c0f12b4fb3d4/packages/react/src/ReactLazy.js#L45\n // eslint-disable-next-line no-underscore-dangle\n (_muiName = element.type.muiName) != null ? _muiName : (_element$type = element.type) == null || (_element$type = _element$type._payload) == null || (_element$type = _element$type.value) == null ? void 0 : _element$type.muiName) !== -1;\n}","export default function ownerDocument(node) {\n return node && node.ownerDocument || document;\n}","import ownerDocument from '../ownerDocument';\nexport default function ownerWindow(node) {\n const doc = ownerDocument(node);\n return doc.defaultView || window;\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nexport default function requirePropFactory(componentNameInError, Component) {\n if (process.env.NODE_ENV === 'production') {\n return () => null;\n }\n\n // eslint-disable-next-line react/forbid-foreign-prop-types\n const prevPropTypes = Component ? _extends({}, Component.propTypes) : null;\n const requireProp = requiredProp => (props, propName, componentName, location, propFullName, ...args) => {\n const propFullNameSafe = propFullName || propName;\n const defaultTypeChecker = prevPropTypes == null ? void 0 : prevPropTypes[propFullNameSafe];\n if (defaultTypeChecker) {\n const typeCheckerResult = defaultTypeChecker(props, propName, componentName, location, propFullName, ...args);\n if (typeCheckerResult) {\n return typeCheckerResult;\n }\n }\n if (typeof props[propName] !== 'undefined' && !props[requiredProp]) {\n return new Error(`The prop \\`${propFullNameSafe}\\` of ` + `\\`${componentNameInError}\\` can only be used together with the \\`${requiredProp}\\` prop.`);\n }\n return null;\n };\n return requireProp;\n}","/**\n * TODO v5: consider making it private\n *\n * passes {value} to {ref}\n *\n * WARNING: Be sure to only call this inside a callback that is passed as a ref.\n * Otherwise, make sure to cleanup the previous {ref} if it changes. See\n * https://github.com/mui/material-ui/issues/13539\n *\n * Useful if you want to expose the ref of an inner component to the public API\n * while still using it inside the component.\n * @param ref A ref callback or ref object. If anything falsy, this is a no-op.\n */\nexport default function setRef(ref, value) {\n if (typeof ref === 'function') {\n ref(value);\n } else if (ref) {\n ref.current = value;\n }\n}","'use client';\n\nimport * as React from 'react';\n\n/**\n * A version of `React.useLayoutEffect` that does not show a warning when server-side rendering.\n * This is useful for effects that are only needed for client-side rendering but not for SSR.\n *\n * Before you use this hook, make sure to read https://gist.github.com/gaearon/e7d97cdf38a2907924ea12e4ebdf3c85\n * and confirm it doesn't apply to your use-case.\n */\nconst useEnhancedEffect = typeof window !== 'undefined' ? React.useLayoutEffect : React.useEffect;\nexport default useEnhancedEffect;","'use client';\n\nimport * as React from 'react';\nlet globalId = 0;\nfunction useGlobalId(idOverride) {\n const [defaultId, setDefaultId] = React.useState(idOverride);\n const id = idOverride || defaultId;\n React.useEffect(() => {\n if (defaultId == null) {\n // Fallback to this default id when possible.\n // Use the incrementing value for client-side rendering only.\n // We can't use it server-side.\n // If you want to use random values please consider the Birthday Problem: https://en.wikipedia.org/wiki/Birthday_problem\n globalId += 1;\n setDefaultId(`mui-${globalId}`);\n }\n }, [defaultId]);\n return id;\n}\n\n// downstream bundlers may remove unnecessary concatenation, but won't remove toString call -- Workaround for https://github.com/webpack/webpack/issues/14814\nconst maybeReactUseId = React['useId'.toString()];\n/**\n *\n * @example
    \n * @param idOverride\n * @returns {string}\n */\nexport default function useId(idOverride) {\n if (maybeReactUseId !== undefined) {\n const reactId = maybeReactUseId();\n return idOverride != null ? idOverride : reactId;\n }\n // eslint-disable-next-line react-hooks/rules-of-hooks -- `React.useId` is invariant at runtime.\n return useGlobalId(idOverride);\n}","export default function unsupportedProp(props, propName, componentName, location, propFullName) {\n if (process.env.NODE_ENV === 'production') {\n return null;\n }\n const propFullNameSafe = propFullName || propName;\n if (typeof props[propName] !== 'undefined') {\n return new Error(`The prop \\`${propFullNameSafe}\\` is not supported. Please remove it.`);\n }\n return null;\n}","'use client';\n\n/* eslint-disable react-hooks/rules-of-hooks, react-hooks/exhaustive-deps */\nimport * as React from 'react';\nexport default function useControlled({\n controlled,\n default: defaultProp,\n name,\n state = 'value'\n}) {\n // isControlled is ignored in the hook dependency lists as it should never change.\n const {\n current: isControlled\n } = React.useRef(controlled !== undefined);\n const [valueState, setValue] = React.useState(defaultProp);\n const value = isControlled ? controlled : valueState;\n if (process.env.NODE_ENV !== 'production') {\n React.useEffect(() => {\n if (isControlled !== (controlled !== undefined)) {\n console.error([`MUI: A component is changing the ${isControlled ? '' : 'un'}controlled ${state} state of ${name} to be ${isControlled ? 'un' : ''}controlled.`, 'Elements should not switch from uncontrolled to controlled (or vice versa).', `Decide between using a controlled or uncontrolled ${name} ` + 'element for the lifetime of the component.', \"The nature of the state is determined during the first render. It's considered controlled if the value is not `undefined`.\", 'More info: https://fb.me/react-controlled-components'].join('\\n'));\n }\n }, [state, name, controlled]);\n const {\n current: defaultValue\n } = React.useRef(defaultProp);\n React.useEffect(() => {\n if (!isControlled && defaultValue !== defaultProp) {\n console.error([`MUI: A component is changing the default ${state} state of an uncontrolled ${name} after being initialized. ` + `To suppress this warning opt to use a controlled ${name}.`].join('\\n'));\n }\n }, [JSON.stringify(defaultProp)]);\n }\n const setValueIfUncontrolled = React.useCallback(newValue => {\n if (!isControlled) {\n setValue(newValue);\n }\n }, []);\n return [value, setValueIfUncontrolled];\n}","'use client';\n\nimport * as React from 'react';\nimport useEnhancedEffect from '../useEnhancedEffect';\n\n/**\n * Inspired by https://github.com/facebook/react/issues/14099#issuecomment-440013892\n * See RFC in https://github.com/reactjs/rfcs/pull/220\n */\n\nfunction useEventCallback(fn) {\n const ref = React.useRef(fn);\n useEnhancedEffect(() => {\n ref.current = fn;\n });\n return React.useRef((...args) =>\n // @ts-expect-error hide `this`\n (0, ref.current)(...args)).current;\n}\nexport default useEventCallback;","'use client';\n\nimport * as React from 'react';\nimport setRef from '../setRef';\nexport default function useForkRef(...refs) {\n /**\n * This will create a new function if the refs passed to this hook change and are all defined.\n * This means react will call the old forkRef with `null` and the new forkRef\n * with the ref. Cleanup naturally emerges from this behavior.\n */\n return React.useMemo(() => {\n if (refs.every(ref => ref == null)) {\n return null;\n }\n return instance => {\n refs.forEach(ref => {\n setRef(ref, instance);\n });\n };\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, refs);\n}","'use client';\n\nimport * as React from 'react';\nconst UNINITIALIZED = {};\n\n/**\n * A React.useRef() that is initialized lazily with a function. Note that it accepts an optional\n * initialization argument, so the initialization function doesn't need to be an inline closure.\n *\n * @usage\n * const ref = useLazyRef(sortColumns, columns)\n */\nexport default function useLazyRef(init, initArg) {\n const ref = React.useRef(UNINITIALIZED);\n if (ref.current === UNINITIALIZED) {\n ref.current = init(initArg);\n }\n return ref;\n}","'use client';\n\nimport * as React from 'react';\nconst EMPTY = [];\n\n/**\n * A React.useEffect equivalent that runs once, when the component is mounted.\n */\nexport default function useOnMount(fn) {\n /* eslint-disable react-hooks/exhaustive-deps */\n React.useEffect(fn, EMPTY);\n /* eslint-enable react-hooks/exhaustive-deps */\n}","'use client';\n\nimport useLazyRef from '../useLazyRef/useLazyRef';\nimport useOnMount from '../useOnMount/useOnMount';\nexport class Timeout {\n constructor() {\n this.currentId = null;\n this.clear = () => {\n if (this.currentId !== null) {\n clearTimeout(this.currentId);\n this.currentId = null;\n }\n };\n this.disposeEffect = () => {\n return this.clear;\n };\n }\n static create() {\n return new Timeout();\n }\n /**\n * Executes `fn` after `delay`, clearing any previously scheduled call.\n */\n start(delay, fn) {\n this.clear();\n this.currentId = setTimeout(() => {\n this.currentId = null;\n fn();\n }, delay);\n }\n}\nexport default function useTimeout() {\n const timeout = useLazyRef(Timeout.create).current;\n useOnMount(timeout.disposeEffect);\n return timeout;\n}","'use client';\n\n// based on https://github.com/WICG/focus-visible/blob/v4.1.5/src/focus-visible.js\nimport * as React from 'react';\nimport { Timeout } from '../useTimeout/useTimeout';\nlet hadKeyboardEvent = true;\nlet hadFocusVisibleRecently = false;\nconst hadFocusVisibleRecentlyTimeout = new Timeout();\nconst inputTypesWhitelist = {\n text: true,\n search: true,\n url: true,\n tel: true,\n email: true,\n password: true,\n number: true,\n date: true,\n month: true,\n week: true,\n time: true,\n datetime: true,\n 'datetime-local': true\n};\n\n/**\n * Computes whether the given element should automatically trigger the\n * `focus-visible` class being added, i.e. whether it should always match\n * `:focus-visible` when focused.\n * @param {Element} node\n * @returns {boolean}\n */\nfunction focusTriggersKeyboardModality(node) {\n const {\n type,\n tagName\n } = node;\n if (tagName === 'INPUT' && inputTypesWhitelist[type] && !node.readOnly) {\n return true;\n }\n if (tagName === 'TEXTAREA' && !node.readOnly) {\n return true;\n }\n if (node.isContentEditable) {\n return true;\n }\n return false;\n}\n\n/**\n * Keep track of our keyboard modality state with `hadKeyboardEvent`.\n * If the most recent user interaction was via the keyboard;\n * and the key press did not include a meta, alt/option, or control key;\n * then the modality is keyboard. Otherwise, the modality is not keyboard.\n * @param {KeyboardEvent} event\n */\nfunction handleKeyDown(event) {\n if (event.metaKey || event.altKey || event.ctrlKey) {\n return;\n }\n hadKeyboardEvent = true;\n}\n\n/**\n * If at any point a user clicks with a pointing device, ensure that we change\n * the modality away from keyboard.\n * This avoids the situation where a user presses a key on an already focused\n * element, and then clicks on a different element, focusing it with a\n * pointing device, while we still think we're in keyboard modality.\n */\nfunction handlePointerDown() {\n hadKeyboardEvent = false;\n}\nfunction handleVisibilityChange() {\n if (this.visibilityState === 'hidden') {\n // If the tab becomes active again, the browser will handle calling focus\n // on the element (Safari actually calls it twice).\n // If this tab change caused a blur on an element with focus-visible,\n // re-apply the class when the user switches back to the tab.\n if (hadFocusVisibleRecently) {\n hadKeyboardEvent = true;\n }\n }\n}\nfunction prepare(doc) {\n doc.addEventListener('keydown', handleKeyDown, true);\n doc.addEventListener('mousedown', handlePointerDown, true);\n doc.addEventListener('pointerdown', handlePointerDown, true);\n doc.addEventListener('touchstart', handlePointerDown, true);\n doc.addEventListener('visibilitychange', handleVisibilityChange, true);\n}\nexport function teardown(doc) {\n doc.removeEventListener('keydown', handleKeyDown, true);\n doc.removeEventListener('mousedown', handlePointerDown, true);\n doc.removeEventListener('pointerdown', handlePointerDown, true);\n doc.removeEventListener('touchstart', handlePointerDown, true);\n doc.removeEventListener('visibilitychange', handleVisibilityChange, true);\n}\nfunction isFocusVisible(event) {\n const {\n target\n } = event;\n try {\n return target.matches(':focus-visible');\n } catch (error) {\n // Browsers not implementing :focus-visible will throw a SyntaxError.\n // We use our own heuristic for those browsers.\n // Rethrow might be better if it's not the expected error but do we really\n // want to crash if focus-visible malfunctioned?\n }\n\n // No need for validFocusTarget check. The user does that by attaching it to\n // focusable events only.\n return hadKeyboardEvent || focusTriggersKeyboardModality(target);\n}\nexport default function useIsFocusVisible() {\n const ref = React.useCallback(node => {\n if (node != null) {\n prepare(node.ownerDocument);\n }\n }, []);\n const isFocusVisibleRef = React.useRef(false);\n\n /**\n * Should be called if a blur event is fired\n */\n function handleBlurVisible() {\n // checking against potential state variable does not suffice if we focus and blur synchronously.\n // React wouldn't have time to trigger a re-render so `focusVisible` would be stale.\n // Ideally we would adjust `isFocusVisible(event)` to look at `relatedTarget` for blur events.\n // This doesn't work in IE11 due to https://github.com/facebook/react/issues/3751\n // TODO: check again if React releases their internal changes to focus event handling (https://github.com/facebook/react/pull/19186).\n if (isFocusVisibleRef.current) {\n // To detect a tab/window switch, we look for a blur event followed\n // rapidly by a visibility change.\n // If we don't see a visibility change within 100ms, it's probably a\n // regular focus change.\n hadFocusVisibleRecently = true;\n hadFocusVisibleRecentlyTimeout.start(100, () => {\n hadFocusVisibleRecently = false;\n });\n isFocusVisibleRef.current = false;\n return true;\n }\n return false;\n }\n\n /**\n * Should be called if a blur event is fired\n */\n function handleFocusVisible(event) {\n if (isFocusVisible(event)) {\n isFocusVisibleRef.current = true;\n return true;\n }\n return false;\n }\n return {\n isFocusVisibleRef,\n onFocus: handleFocusVisible,\n onBlur: handleBlurVisible,\n ref\n };\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\n/**\n * Add keys, values of `defaultProps` that does not exist in `props`\n * @param {object} defaultProps\n * @param {object} props\n * @returns {object} resolved props\n */\nexport default function resolveProps(defaultProps, props) {\n const output = _extends({}, props);\n Object.keys(defaultProps).forEach(propName => {\n if (propName.toString().match(/^(components|slots)$/)) {\n output[propName] = _extends({}, defaultProps[propName], output[propName]);\n } else if (propName.toString().match(/^(componentsProps|slotProps)$/)) {\n const defaultSlotProps = defaultProps[propName] || {};\n const slotProps = props[propName];\n output[propName] = {};\n if (!slotProps || !Object.keys(slotProps)) {\n // Reduce the iteration if the slot props is empty\n output[propName] = defaultSlotProps;\n } else if (!defaultSlotProps || !Object.keys(defaultSlotProps)) {\n // Reduce the iteration if the default slot props is empty\n output[propName] = slotProps;\n } else {\n output[propName] = _extends({}, slotProps);\n Object.keys(defaultSlotProps).forEach(slotPropName => {\n output[propName][slotPropName] = resolveProps(defaultSlotProps[slotPropName], slotProps[slotPropName]);\n });\n }\n } else if (output[propName] === undefined) {\n output[propName] = defaultProps[propName];\n }\n });\n return output;\n}","export default function composeClasses(slots, getUtilityClass, classes = undefined) {\n const output = {};\n Object.keys(slots).forEach(\n // `Object.keys(slots)` can't be wider than `T` because we infer `T` from `slots`.\n // @ts-expect-error https://github.com/microsoft/TypeScript/pull/12253#issuecomment-263132208\n slot => {\n output[slot] = slots[slot].reduce((acc, key) => {\n if (key) {\n const utilityClass = getUtilityClass(key);\n if (utilityClass !== '') {\n acc.push(utilityClass);\n }\n if (classes && classes[key]) {\n acc.push(classes[key]);\n }\n }\n return acc;\n }, []).join(' ');\n });\n return output;\n}","const defaultGenerator = componentName => componentName;\nconst createClassNameGenerator = () => {\n let generate = defaultGenerator;\n return {\n configure(generator) {\n generate = generator;\n },\n generate(componentName) {\n return generate(componentName);\n },\n reset() {\n generate = defaultGenerator;\n }\n };\n};\nconst ClassNameGenerator = createClassNameGenerator();\nexport default ClassNameGenerator;","import ClassNameGenerator from '../ClassNameGenerator';\nexport const globalStateClasses = {\n active: 'active',\n checked: 'checked',\n completed: 'completed',\n disabled: 'disabled',\n error: 'error',\n expanded: 'expanded',\n focused: 'focused',\n focusVisible: 'focusVisible',\n open: 'open',\n readOnly: 'readOnly',\n required: 'required',\n selected: 'selected'\n};\nexport default function generateUtilityClass(componentName, slot, globalStatePrefix = 'Mui') {\n const globalStateClass = globalStateClasses[slot];\n return globalStateClass ? `${globalStatePrefix}-${globalStateClass}` : `${ClassNameGenerator.generate(componentName)}-${slot}`;\n}\nexport function isGlobalState(slot) {\n return globalStateClasses[slot] !== undefined;\n}","import generateUtilityClass from '../generateUtilityClass';\nexport default function generateUtilityClasses(componentName, slots, globalStatePrefix = 'Mui') {\n const result = {};\n slots.forEach(slot => {\n result[slot] = generateUtilityClass(componentName, slot, globalStatePrefix);\n });\n return result;\n}","function clamp(val, min = Number.MIN_SAFE_INTEGER, max = Number.MAX_SAFE_INTEGER) {\n return Math.max(min, Math.min(val, max));\n}\nexport default clamp;","export default function _objectWithoutPropertiesLoose(source, excluded) {\n if (source == null) return {};\n var target = {};\n var sourceKeys = Object.keys(source);\n var key, i;\n for (i = 0; i < sourceKeys.length; i++) {\n key = sourceKeys[i];\n if (excluded.indexOf(key) >= 0) continue;\n target[key] = source[key];\n }\n return target;\n}","import _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nconst _excluded = [\"values\", \"unit\", \"step\"];\n// Sorted ASC by size. That's important.\n// It can't be configured as it's used statically for propTypes.\nexport const breakpointKeys = ['xs', 'sm', 'md', 'lg', 'xl'];\nconst sortBreakpointsValues = values => {\n const breakpointsAsArray = Object.keys(values).map(key => ({\n key,\n val: values[key]\n })) || [];\n // Sort in ascending order\n breakpointsAsArray.sort((breakpoint1, breakpoint2) => breakpoint1.val - breakpoint2.val);\n return breakpointsAsArray.reduce((acc, obj) => {\n return _extends({}, acc, {\n [obj.key]: obj.val\n });\n }, {});\n};\n\n// Keep in mind that @media is inclusive by the CSS specification.\nexport default function createBreakpoints(breakpoints) {\n const {\n // The breakpoint **start** at this value.\n // For instance with the first breakpoint xs: [xs, sm).\n values = {\n xs: 0,\n // phone\n sm: 600,\n // tablet\n md: 900,\n // small laptop\n lg: 1200,\n // desktop\n xl: 1536 // large screen\n },\n unit = 'px',\n step = 5\n } = breakpoints,\n other = _objectWithoutPropertiesLoose(breakpoints, _excluded);\n const sortedValues = sortBreakpointsValues(values);\n const keys = Object.keys(sortedValues);\n function up(key) {\n const value = typeof values[key] === 'number' ? values[key] : key;\n return `@media (min-width:${value}${unit})`;\n }\n function down(key) {\n const value = typeof values[key] === 'number' ? values[key] : key;\n return `@media (max-width:${value - step / 100}${unit})`;\n }\n function between(start, end) {\n const endIndex = keys.indexOf(end);\n return `@media (min-width:${typeof values[start] === 'number' ? values[start] : start}${unit}) and ` + `(max-width:${(endIndex !== -1 && typeof values[keys[endIndex]] === 'number' ? values[keys[endIndex]] : end) - step / 100}${unit})`;\n }\n function only(key) {\n if (keys.indexOf(key) + 1 < keys.length) {\n return between(key, keys[keys.indexOf(key) + 1]);\n }\n return up(key);\n }\n function not(key) {\n // handle first and last key separately, for better readability\n const keyIndex = keys.indexOf(key);\n if (keyIndex === 0) {\n return up(keys[1]);\n }\n if (keyIndex === keys.length - 1) {\n return down(keys[keyIndex]);\n }\n return between(key, keys[keys.indexOf(key) + 1]).replace('@media', '@media not all and');\n }\n return _extends({\n keys,\n values: sortedValues,\n up,\n down,\n between,\n only,\n not,\n unit\n }, other);\n}","const shape = {\n borderRadius: 4\n};\nexport default shape;","import PropTypes from 'prop-types';\nconst responsivePropType = process.env.NODE_ENV !== 'production' ? PropTypes.oneOfType([PropTypes.number, PropTypes.string, PropTypes.object, PropTypes.array]) : {};\nexport default responsivePropType;","import deepmerge from '@mui/utils/deepmerge';\nfunction merge(acc, item) {\n if (!item) {\n return acc;\n }\n return deepmerge(acc, item, {\n clone: false // No need to clone deep, it's way faster.\n });\n}\nexport default merge;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport PropTypes from 'prop-types';\nimport deepmerge from '@mui/utils/deepmerge';\nimport merge from './merge';\n\n// The breakpoint **start** at this value.\n// For instance with the first breakpoint xs: [xs, sm[.\nexport const values = {\n xs: 0,\n // phone\n sm: 600,\n // tablet\n md: 900,\n // small laptop\n lg: 1200,\n // desktop\n xl: 1536 // large screen\n};\nconst defaultBreakpoints = {\n // Sorted ASC by size. That's important.\n // It can't be configured as it's used statically for propTypes.\n keys: ['xs', 'sm', 'md', 'lg', 'xl'],\n up: key => `@media (min-width:${values[key]}px)`\n};\nexport function handleBreakpoints(props, propValue, styleFromPropValue) {\n const theme = props.theme || {};\n if (Array.isArray(propValue)) {\n const themeBreakpoints = theme.breakpoints || defaultBreakpoints;\n return propValue.reduce((acc, item, index) => {\n acc[themeBreakpoints.up(themeBreakpoints.keys[index])] = styleFromPropValue(propValue[index]);\n return acc;\n }, {});\n }\n if (typeof propValue === 'object') {\n const themeBreakpoints = theme.breakpoints || defaultBreakpoints;\n return Object.keys(propValue).reduce((acc, breakpoint) => {\n // key is breakpoint\n if (Object.keys(themeBreakpoints.values || values).indexOf(breakpoint) !== -1) {\n const mediaKey = themeBreakpoints.up(breakpoint);\n acc[mediaKey] = styleFromPropValue(propValue[breakpoint], breakpoint);\n } else {\n const cssKey = breakpoint;\n acc[cssKey] = propValue[cssKey];\n }\n return acc;\n }, {});\n }\n const output = styleFromPropValue(propValue);\n return output;\n}\nfunction breakpoints(styleFunction) {\n // false positive\n // eslint-disable-next-line react/function-component-definition\n const newStyleFunction = props => {\n const theme = props.theme || {};\n const base = styleFunction(props);\n const themeBreakpoints = theme.breakpoints || defaultBreakpoints;\n const extended = themeBreakpoints.keys.reduce((acc, key) => {\n if (props[key]) {\n acc = acc || {};\n acc[themeBreakpoints.up(key)] = styleFunction(_extends({\n theme\n }, props[key]));\n }\n return acc;\n }, null);\n return merge(base, extended);\n };\n newStyleFunction.propTypes = process.env.NODE_ENV !== 'production' ? _extends({}, styleFunction.propTypes, {\n xs: PropTypes.object,\n sm: PropTypes.object,\n md: PropTypes.object,\n lg: PropTypes.object,\n xl: PropTypes.object\n }) : {};\n newStyleFunction.filterProps = ['xs', 'sm', 'md', 'lg', 'xl', ...styleFunction.filterProps];\n return newStyleFunction;\n}\nexport function createEmptyBreakpointObject(breakpointsInput = {}) {\n var _breakpointsInput$key;\n const breakpointsInOrder = (_breakpointsInput$key = breakpointsInput.keys) == null ? void 0 : _breakpointsInput$key.reduce((acc, key) => {\n const breakpointStyleKey = breakpointsInput.up(key);\n acc[breakpointStyleKey] = {};\n return acc;\n }, {});\n return breakpointsInOrder || {};\n}\nexport function removeUnusedBreakpoints(breakpointKeys, style) {\n return breakpointKeys.reduce((acc, key) => {\n const breakpointOutput = acc[key];\n const isBreakpointUnused = !breakpointOutput || Object.keys(breakpointOutput).length === 0;\n if (isBreakpointUnused) {\n delete acc[key];\n }\n return acc;\n }, style);\n}\nexport function mergeBreakpointsInOrder(breakpointsInput, ...styles) {\n const emptyBreakpoints = createEmptyBreakpointObject(breakpointsInput);\n const mergedOutput = [emptyBreakpoints, ...styles].reduce((prev, next) => deepmerge(prev, next), {});\n return removeUnusedBreakpoints(Object.keys(emptyBreakpoints), mergedOutput);\n}\n\n// compute base for responsive values; e.g.,\n// [1,2,3] => {xs: true, sm: true, md: true}\n// {xs: 1, sm: 2, md: 3} => {xs: true, sm: true, md: true}\nexport function computeBreakpointsBase(breakpointValues, themeBreakpoints) {\n // fixed value\n if (typeof breakpointValues !== 'object') {\n return {};\n }\n const base = {};\n const breakpointsKeys = Object.keys(themeBreakpoints);\n if (Array.isArray(breakpointValues)) {\n breakpointsKeys.forEach((breakpoint, i) => {\n if (i < breakpointValues.length) {\n base[breakpoint] = true;\n }\n });\n } else {\n breakpointsKeys.forEach(breakpoint => {\n if (breakpointValues[breakpoint] != null) {\n base[breakpoint] = true;\n }\n });\n }\n return base;\n}\nexport function resolveBreakpointValues({\n values: breakpointValues,\n breakpoints: themeBreakpoints,\n base: customBase\n}) {\n const base = customBase || computeBreakpointsBase(breakpointValues, themeBreakpoints);\n const keys = Object.keys(base);\n if (keys.length === 0) {\n return breakpointValues;\n }\n let previous;\n return keys.reduce((acc, breakpoint, i) => {\n if (Array.isArray(breakpointValues)) {\n acc[breakpoint] = breakpointValues[i] != null ? breakpointValues[i] : breakpointValues[previous];\n previous = i;\n } else if (typeof breakpointValues === 'object') {\n acc[breakpoint] = breakpointValues[breakpoint] != null ? breakpointValues[breakpoint] : breakpointValues[previous];\n previous = breakpoint;\n } else {\n acc[breakpoint] = breakpointValues;\n }\n return acc;\n }, {});\n}\nexport default breakpoints;","import capitalize from '@mui/utils/capitalize';\nimport responsivePropType from './responsivePropType';\nimport { handleBreakpoints } from './breakpoints';\nexport function getPath(obj, path, checkVars = true) {\n if (!path || typeof path !== 'string') {\n return null;\n }\n\n // Check if CSS variables are used\n if (obj && obj.vars && checkVars) {\n const val = `vars.${path}`.split('.').reduce((acc, item) => acc && acc[item] ? acc[item] : null, obj);\n if (val != null) {\n return val;\n }\n }\n return path.split('.').reduce((acc, item) => {\n if (acc && acc[item] != null) {\n return acc[item];\n }\n return null;\n }, obj);\n}\nexport function getStyleValue(themeMapping, transform, propValueFinal, userValue = propValueFinal) {\n let value;\n if (typeof themeMapping === 'function') {\n value = themeMapping(propValueFinal);\n } else if (Array.isArray(themeMapping)) {\n value = themeMapping[propValueFinal] || userValue;\n } else {\n value = getPath(themeMapping, propValueFinal) || userValue;\n }\n if (transform) {\n value = transform(value, userValue, themeMapping);\n }\n return value;\n}\nfunction style(options) {\n const {\n prop,\n cssProperty = options.prop,\n themeKey,\n transform\n } = options;\n\n // false positive\n // eslint-disable-next-line react/function-component-definition\n const fn = props => {\n if (props[prop] == null) {\n return null;\n }\n const propValue = props[prop];\n const theme = props.theme;\n const themeMapping = getPath(theme, themeKey) || {};\n const styleFromPropValue = propValueFinal => {\n let value = getStyleValue(themeMapping, transform, propValueFinal);\n if (propValueFinal === value && typeof propValueFinal === 'string') {\n // Haven't found value\n value = getStyleValue(themeMapping, transform, `${prop}${propValueFinal === 'default' ? '' : capitalize(propValueFinal)}`, propValueFinal);\n }\n if (cssProperty === false) {\n return value;\n }\n return {\n [cssProperty]: value\n };\n };\n return handleBreakpoints(props, propValue, styleFromPropValue);\n };\n fn.propTypes = process.env.NODE_ENV !== 'production' ? {\n [prop]: responsivePropType\n } : {};\n fn.filterProps = [prop];\n return fn;\n}\nexport default style;","export default function memoize(fn) {\n const cache = {};\n return arg => {\n if (cache[arg] === undefined) {\n cache[arg] = fn(arg);\n }\n return cache[arg];\n };\n}","import responsivePropType from './responsivePropType';\nimport { handleBreakpoints } from './breakpoints';\nimport { getPath } from './style';\nimport merge from './merge';\nimport memoize from './memoize';\nconst properties = {\n m: 'margin',\n p: 'padding'\n};\nconst directions = {\n t: 'Top',\n r: 'Right',\n b: 'Bottom',\n l: 'Left',\n x: ['Left', 'Right'],\n y: ['Top', 'Bottom']\n};\nconst aliases = {\n marginX: 'mx',\n marginY: 'my',\n paddingX: 'px',\n paddingY: 'py'\n};\n\n// memoize() impact:\n// From 300,000 ops/sec\n// To 350,000 ops/sec\nconst getCssProperties = memoize(prop => {\n // It's not a shorthand notation.\n if (prop.length > 2) {\n if (aliases[prop]) {\n prop = aliases[prop];\n } else {\n return [prop];\n }\n }\n const [a, b] = prop.split('');\n const property = properties[a];\n const direction = directions[b] || '';\n return Array.isArray(direction) ? direction.map(dir => property + dir) : [property + direction];\n});\nexport const marginKeys = ['m', 'mt', 'mr', 'mb', 'ml', 'mx', 'my', 'margin', 'marginTop', 'marginRight', 'marginBottom', 'marginLeft', 'marginX', 'marginY', 'marginInline', 'marginInlineStart', 'marginInlineEnd', 'marginBlock', 'marginBlockStart', 'marginBlockEnd'];\nexport const paddingKeys = ['p', 'pt', 'pr', 'pb', 'pl', 'px', 'py', 'padding', 'paddingTop', 'paddingRight', 'paddingBottom', 'paddingLeft', 'paddingX', 'paddingY', 'paddingInline', 'paddingInlineStart', 'paddingInlineEnd', 'paddingBlock', 'paddingBlockStart', 'paddingBlockEnd'];\nconst spacingKeys = [...marginKeys, ...paddingKeys];\nexport function createUnaryUnit(theme, themeKey, defaultValue, propName) {\n var _getPath;\n const themeSpacing = (_getPath = getPath(theme, themeKey, false)) != null ? _getPath : defaultValue;\n if (typeof themeSpacing === 'number') {\n return abs => {\n if (typeof abs === 'string') {\n return abs;\n }\n if (process.env.NODE_ENV !== 'production') {\n if (typeof abs !== 'number') {\n console.error(`MUI: Expected ${propName} argument to be a number or a string, got ${abs}.`);\n }\n }\n return themeSpacing * abs;\n };\n }\n if (Array.isArray(themeSpacing)) {\n return abs => {\n if (typeof abs === 'string') {\n return abs;\n }\n if (process.env.NODE_ENV !== 'production') {\n if (!Number.isInteger(abs)) {\n console.error([`MUI: The \\`theme.${themeKey}\\` array type cannot be combined with non integer values.` + `You should either use an integer value that can be used as index, or define the \\`theme.${themeKey}\\` as a number.`].join('\\n'));\n } else if (abs > themeSpacing.length - 1) {\n console.error([`MUI: The value provided (${abs}) overflows.`, `The supported values are: ${JSON.stringify(themeSpacing)}.`, `${abs} > ${themeSpacing.length - 1}, you need to add the missing values.`].join('\\n'));\n }\n }\n return themeSpacing[abs];\n };\n }\n if (typeof themeSpacing === 'function') {\n return themeSpacing;\n }\n if (process.env.NODE_ENV !== 'production') {\n console.error([`MUI: The \\`theme.${themeKey}\\` value (${themeSpacing}) is invalid.`, 'It should be a number, an array or a function.'].join('\\n'));\n }\n return () => undefined;\n}\nexport function createUnarySpacing(theme) {\n return createUnaryUnit(theme, 'spacing', 8, 'spacing');\n}\nexport function getValue(transformer, propValue) {\n if (typeof propValue === 'string' || propValue == null) {\n return propValue;\n }\n const abs = Math.abs(propValue);\n const transformed = transformer(abs);\n if (propValue >= 0) {\n return transformed;\n }\n if (typeof transformed === 'number') {\n return -transformed;\n }\n return `-${transformed}`;\n}\nexport function getStyleFromPropValue(cssProperties, transformer) {\n return propValue => cssProperties.reduce((acc, cssProperty) => {\n acc[cssProperty] = getValue(transformer, propValue);\n return acc;\n }, {});\n}\nfunction resolveCssProperty(props, keys, prop, transformer) {\n // Using a hash computation over an array iteration could be faster, but with only 28 items,\n // it's doesn't worth the bundle size.\n if (keys.indexOf(prop) === -1) {\n return null;\n }\n const cssProperties = getCssProperties(prop);\n const styleFromPropValue = getStyleFromPropValue(cssProperties, transformer);\n const propValue = props[prop];\n return handleBreakpoints(props, propValue, styleFromPropValue);\n}\nfunction style(props, keys) {\n const transformer = createUnarySpacing(props.theme);\n return Object.keys(props).map(prop => resolveCssProperty(props, keys, prop, transformer)).reduce(merge, {});\n}\nexport function margin(props) {\n return style(props, marginKeys);\n}\nmargin.propTypes = process.env.NODE_ENV !== 'production' ? marginKeys.reduce((obj, key) => {\n obj[key] = responsivePropType;\n return obj;\n}, {}) : {};\nmargin.filterProps = marginKeys;\nexport function padding(props) {\n return style(props, paddingKeys);\n}\npadding.propTypes = process.env.NODE_ENV !== 'production' ? paddingKeys.reduce((obj, key) => {\n obj[key] = responsivePropType;\n return obj;\n}, {}) : {};\npadding.filterProps = paddingKeys;\nfunction spacing(props) {\n return style(props, spacingKeys);\n}\nspacing.propTypes = process.env.NODE_ENV !== 'production' ? spacingKeys.reduce((obj, key) => {\n obj[key] = responsivePropType;\n return obj;\n}, {}) : {};\nspacing.filterProps = spacingKeys;\nexport default spacing;","import { createUnarySpacing } from '../spacing';\n\n// The different signatures imply different meaning for their arguments that can't be expressed structurally.\n// We express the difference with variable names.\n\nexport default function createSpacing(spacingInput = 8) {\n // Already transformed.\n if (spacingInput.mui) {\n return spacingInput;\n }\n\n // Material Design layouts are visually balanced. Most measurements align to an 8dp grid, which aligns both spacing and the overall layout.\n // Smaller components, such as icons, can align to a 4dp grid.\n // https://m2.material.io/design/layout/understanding-layout.html\n const transform = createUnarySpacing({\n spacing: spacingInput\n });\n const spacing = (...argsInput) => {\n if (process.env.NODE_ENV !== 'production') {\n if (!(argsInput.length <= 4)) {\n console.error(`MUI: Too many arguments provided, expected between 0 and 4, got ${argsInput.length}`);\n }\n }\n const args = argsInput.length === 0 ? [1] : argsInput;\n return args.map(argument => {\n const output = transform(argument);\n return typeof output === 'number' ? `${output}px` : output;\n }).join(' ');\n };\n spacing.mui = true;\n return spacing;\n}","import merge from './merge';\nfunction compose(...styles) {\n const handlers = styles.reduce((acc, style) => {\n style.filterProps.forEach(prop => {\n acc[prop] = style;\n });\n return acc;\n }, {});\n\n // false positive\n // eslint-disable-next-line react/function-component-definition\n const fn = props => {\n return Object.keys(props).reduce((acc, prop) => {\n if (handlers[prop]) {\n return merge(acc, handlers[prop](props));\n }\n return acc;\n }, {});\n };\n fn.propTypes = process.env.NODE_ENV !== 'production' ? styles.reduce((acc, style) => Object.assign(acc, style.propTypes), {}) : {};\n fn.filterProps = styles.reduce((acc, style) => acc.concat(style.filterProps), []);\n return fn;\n}\nexport default compose;","import responsivePropType from './responsivePropType';\nimport style from './style';\nimport compose from './compose';\nimport { createUnaryUnit, getValue } from './spacing';\nimport { handleBreakpoints } from './breakpoints';\nexport function borderTransform(value) {\n if (typeof value !== 'number') {\n return value;\n }\n return `${value}px solid`;\n}\nfunction createBorderStyle(prop, transform) {\n return style({\n prop,\n themeKey: 'borders',\n transform\n });\n}\nexport const border = createBorderStyle('border', borderTransform);\nexport const borderTop = createBorderStyle('borderTop', borderTransform);\nexport const borderRight = createBorderStyle('borderRight', borderTransform);\nexport const borderBottom = createBorderStyle('borderBottom', borderTransform);\nexport const borderLeft = createBorderStyle('borderLeft', borderTransform);\nexport const borderColor = createBorderStyle('borderColor');\nexport const borderTopColor = createBorderStyle('borderTopColor');\nexport const borderRightColor = createBorderStyle('borderRightColor');\nexport const borderBottomColor = createBorderStyle('borderBottomColor');\nexport const borderLeftColor = createBorderStyle('borderLeftColor');\nexport const outline = createBorderStyle('outline', borderTransform);\nexport const outlineColor = createBorderStyle('outlineColor');\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const borderRadius = props => {\n if (props.borderRadius !== undefined && props.borderRadius !== null) {\n const transformer = createUnaryUnit(props.theme, 'shape.borderRadius', 4, 'borderRadius');\n const styleFromPropValue = propValue => ({\n borderRadius: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.borderRadius, styleFromPropValue);\n }\n return null;\n};\nborderRadius.propTypes = process.env.NODE_ENV !== 'production' ? {\n borderRadius: responsivePropType\n} : {};\nborderRadius.filterProps = ['borderRadius'];\nconst borders = compose(border, borderTop, borderRight, borderBottom, borderLeft, borderColor, borderTopColor, borderRightColor, borderBottomColor, borderLeftColor, borderRadius, outline, outlineColor);\nexport default borders;","import style from './style';\nimport compose from './compose';\nimport { createUnaryUnit, getValue } from './spacing';\nimport { handleBreakpoints } from './breakpoints';\nimport responsivePropType from './responsivePropType';\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const gap = props => {\n if (props.gap !== undefined && props.gap !== null) {\n const transformer = createUnaryUnit(props.theme, 'spacing', 8, 'gap');\n const styleFromPropValue = propValue => ({\n gap: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.gap, styleFromPropValue);\n }\n return null;\n};\ngap.propTypes = process.env.NODE_ENV !== 'production' ? {\n gap: responsivePropType\n} : {};\ngap.filterProps = ['gap'];\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const columnGap = props => {\n if (props.columnGap !== undefined && props.columnGap !== null) {\n const transformer = createUnaryUnit(props.theme, 'spacing', 8, 'columnGap');\n const styleFromPropValue = propValue => ({\n columnGap: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.columnGap, styleFromPropValue);\n }\n return null;\n};\ncolumnGap.propTypes = process.env.NODE_ENV !== 'production' ? {\n columnGap: responsivePropType\n} : {};\ncolumnGap.filterProps = ['columnGap'];\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const rowGap = props => {\n if (props.rowGap !== undefined && props.rowGap !== null) {\n const transformer = createUnaryUnit(props.theme, 'spacing', 8, 'rowGap');\n const styleFromPropValue = propValue => ({\n rowGap: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.rowGap, styleFromPropValue);\n }\n return null;\n};\nrowGap.propTypes = process.env.NODE_ENV !== 'production' ? {\n rowGap: responsivePropType\n} : {};\nrowGap.filterProps = ['rowGap'];\nexport const gridColumn = style({\n prop: 'gridColumn'\n});\nexport const gridRow = style({\n prop: 'gridRow'\n});\nexport const gridAutoFlow = style({\n prop: 'gridAutoFlow'\n});\nexport const gridAutoColumns = style({\n prop: 'gridAutoColumns'\n});\nexport const gridAutoRows = style({\n prop: 'gridAutoRows'\n});\nexport const gridTemplateColumns = style({\n prop: 'gridTemplateColumns'\n});\nexport const gridTemplateRows = style({\n prop: 'gridTemplateRows'\n});\nexport const gridTemplateAreas = style({\n prop: 'gridTemplateAreas'\n});\nexport const gridArea = style({\n prop: 'gridArea'\n});\nconst grid = compose(gap, columnGap, rowGap, gridColumn, gridRow, gridAutoFlow, gridAutoColumns, gridAutoRows, gridTemplateColumns, gridTemplateRows, gridTemplateAreas, gridArea);\nexport default grid;","import style from './style';\nimport compose from './compose';\nexport function paletteTransform(value, userValue) {\n if (userValue === 'grey') {\n return userValue;\n }\n return value;\n}\nexport const color = style({\n prop: 'color',\n themeKey: 'palette',\n transform: paletteTransform\n});\nexport const bgcolor = style({\n prop: 'bgcolor',\n cssProperty: 'backgroundColor',\n themeKey: 'palette',\n transform: paletteTransform\n});\nexport const backgroundColor = style({\n prop: 'backgroundColor',\n themeKey: 'palette',\n transform: paletteTransform\n});\nconst palette = compose(color, bgcolor, backgroundColor);\nexport default palette;","import style from './style';\nimport compose from './compose';\nimport { handleBreakpoints, values as breakpointsValues } from './breakpoints';\nexport function sizingTransform(value) {\n return value <= 1 && value !== 0 ? `${value * 100}%` : value;\n}\nexport const width = style({\n prop: 'width',\n transform: sizingTransform\n});\nexport const maxWidth = props => {\n if (props.maxWidth !== undefined && props.maxWidth !== null) {\n const styleFromPropValue = propValue => {\n var _props$theme, _props$theme2;\n const breakpoint = ((_props$theme = props.theme) == null || (_props$theme = _props$theme.breakpoints) == null || (_props$theme = _props$theme.values) == null ? void 0 : _props$theme[propValue]) || breakpointsValues[propValue];\n if (!breakpoint) {\n return {\n maxWidth: sizingTransform(propValue)\n };\n }\n if (((_props$theme2 = props.theme) == null || (_props$theme2 = _props$theme2.breakpoints) == null ? void 0 : _props$theme2.unit) !== 'px') {\n return {\n maxWidth: `${breakpoint}${props.theme.breakpoints.unit}`\n };\n }\n return {\n maxWidth: breakpoint\n };\n };\n return handleBreakpoints(props, props.maxWidth, styleFromPropValue);\n }\n return null;\n};\nmaxWidth.filterProps = ['maxWidth'];\nexport const minWidth = style({\n prop: 'minWidth',\n transform: sizingTransform\n});\nexport const height = style({\n prop: 'height',\n transform: sizingTransform\n});\nexport const maxHeight = style({\n prop: 'maxHeight',\n transform: sizingTransform\n});\nexport const minHeight = style({\n prop: 'minHeight',\n transform: sizingTransform\n});\nexport const sizeWidth = style({\n prop: 'size',\n cssProperty: 'width',\n transform: sizingTransform\n});\nexport const sizeHeight = style({\n prop: 'size',\n cssProperty: 'height',\n transform: sizingTransform\n});\nexport const boxSizing = style({\n prop: 'boxSizing'\n});\nconst sizing = compose(width, maxWidth, minWidth, height, maxHeight, minHeight, boxSizing);\nexport default sizing;","import { padding, margin } from '../spacing';\nimport { borderRadius, borderTransform } from '../borders';\nimport { gap, rowGap, columnGap } from '../cssGrid';\nimport { paletteTransform } from '../palette';\nimport { maxWidth, sizingTransform } from '../sizing';\nconst defaultSxConfig = {\n // borders\n border: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderTop: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderRight: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderBottom: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderLeft: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderColor: {\n themeKey: 'palette'\n },\n borderTopColor: {\n themeKey: 'palette'\n },\n borderRightColor: {\n themeKey: 'palette'\n },\n borderBottomColor: {\n themeKey: 'palette'\n },\n borderLeftColor: {\n themeKey: 'palette'\n },\n outline: {\n themeKey: 'borders',\n transform: borderTransform\n },\n outlineColor: {\n themeKey: 'palette'\n },\n borderRadius: {\n themeKey: 'shape.borderRadius',\n style: borderRadius\n },\n // palette\n color: {\n themeKey: 'palette',\n transform: paletteTransform\n },\n bgcolor: {\n themeKey: 'palette',\n cssProperty: 'backgroundColor',\n transform: paletteTransform\n },\n backgroundColor: {\n themeKey: 'palette',\n transform: paletteTransform\n },\n // spacing\n p: {\n style: padding\n },\n pt: {\n style: padding\n },\n pr: {\n style: padding\n },\n pb: {\n style: padding\n },\n pl: {\n style: padding\n },\n px: {\n style: padding\n },\n py: {\n style: padding\n },\n padding: {\n style: padding\n },\n paddingTop: {\n style: padding\n },\n paddingRight: {\n style: padding\n },\n paddingBottom: {\n style: padding\n },\n paddingLeft: {\n style: padding\n },\n paddingX: {\n style: padding\n },\n paddingY: {\n style: padding\n },\n paddingInline: {\n style: padding\n },\n paddingInlineStart: {\n style: padding\n },\n paddingInlineEnd: {\n style: padding\n },\n paddingBlock: {\n style: padding\n },\n paddingBlockStart: {\n style: padding\n },\n paddingBlockEnd: {\n style: padding\n },\n m: {\n style: margin\n },\n mt: {\n style: margin\n },\n mr: {\n style: margin\n },\n mb: {\n style: margin\n },\n ml: {\n style: margin\n },\n mx: {\n style: margin\n },\n my: {\n style: margin\n },\n margin: {\n style: margin\n },\n marginTop: {\n style: margin\n },\n marginRight: {\n style: margin\n },\n marginBottom: {\n style: margin\n },\n marginLeft: {\n style: margin\n },\n marginX: {\n style: margin\n },\n marginY: {\n style: margin\n },\n marginInline: {\n style: margin\n },\n marginInlineStart: {\n style: margin\n },\n marginInlineEnd: {\n style: margin\n },\n marginBlock: {\n style: margin\n },\n marginBlockStart: {\n style: margin\n },\n marginBlockEnd: {\n style: margin\n },\n // display\n displayPrint: {\n cssProperty: false,\n transform: value => ({\n '@media print': {\n display: value\n }\n })\n },\n display: {},\n overflow: {},\n textOverflow: {},\n visibility: {},\n whiteSpace: {},\n // flexbox\n flexBasis: {},\n flexDirection: {},\n flexWrap: {},\n justifyContent: {},\n alignItems: {},\n alignContent: {},\n order: {},\n flex: {},\n flexGrow: {},\n flexShrink: {},\n alignSelf: {},\n justifyItems: {},\n justifySelf: {},\n // grid\n gap: {\n style: gap\n },\n rowGap: {\n style: rowGap\n },\n columnGap: {\n style: columnGap\n },\n gridColumn: {},\n gridRow: {},\n gridAutoFlow: {},\n gridAutoColumns: {},\n gridAutoRows: {},\n gridTemplateColumns: {},\n gridTemplateRows: {},\n gridTemplateAreas: {},\n gridArea: {},\n // positions\n position: {},\n zIndex: {\n themeKey: 'zIndex'\n },\n top: {},\n right: {},\n bottom: {},\n left: {},\n // shadows\n boxShadow: {\n themeKey: 'shadows'\n },\n // sizing\n width: {\n transform: sizingTransform\n },\n maxWidth: {\n style: maxWidth\n },\n minWidth: {\n transform: sizingTransform\n },\n height: {\n transform: sizingTransform\n },\n maxHeight: {\n transform: sizingTransform\n },\n minHeight: {\n transform: sizingTransform\n },\n boxSizing: {},\n // typography\n fontFamily: {\n themeKey: 'typography'\n },\n fontSize: {\n themeKey: 'typography'\n },\n fontStyle: {\n themeKey: 'typography'\n },\n fontWeight: {\n themeKey: 'typography'\n },\n letterSpacing: {},\n textTransform: {},\n lineHeight: {},\n textAlign: {},\n typography: {\n cssProperty: false,\n themeKey: 'typography'\n }\n};\nexport default defaultSxConfig;","import capitalize from '@mui/utils/capitalize';\nimport merge from '../merge';\nimport { getPath, getStyleValue as getValue } from '../style';\nimport { handleBreakpoints, createEmptyBreakpointObject, removeUnusedBreakpoints } from '../breakpoints';\nimport defaultSxConfig from './defaultSxConfig';\nfunction objectsHaveSameKeys(...objects) {\n const allKeys = objects.reduce((keys, object) => keys.concat(Object.keys(object)), []);\n const union = new Set(allKeys);\n return objects.every(object => union.size === Object.keys(object).length);\n}\nfunction callIfFn(maybeFn, arg) {\n return typeof maybeFn === 'function' ? maybeFn(arg) : maybeFn;\n}\n\n// eslint-disable-next-line @typescript-eslint/naming-convention\nexport function unstable_createStyleFunctionSx() {\n function getThemeValue(prop, val, theme, config) {\n const props = {\n [prop]: val,\n theme\n };\n const options = config[prop];\n if (!options) {\n return {\n [prop]: val\n };\n }\n const {\n cssProperty = prop,\n themeKey,\n transform,\n style\n } = options;\n if (val == null) {\n return null;\n }\n\n // TODO v6: remove, see https://github.com/mui/material-ui/pull/38123\n if (themeKey === 'typography' && val === 'inherit') {\n return {\n [prop]: val\n };\n }\n const themeMapping = getPath(theme, themeKey) || {};\n if (style) {\n return style(props);\n }\n const styleFromPropValue = propValueFinal => {\n let value = getValue(themeMapping, transform, propValueFinal);\n if (propValueFinal === value && typeof propValueFinal === 'string') {\n // Haven't found value\n value = getValue(themeMapping, transform, `${prop}${propValueFinal === 'default' ? '' : capitalize(propValueFinal)}`, propValueFinal);\n }\n if (cssProperty === false) {\n return value;\n }\n return {\n [cssProperty]: value\n };\n };\n return handleBreakpoints(props, val, styleFromPropValue);\n }\n function styleFunctionSx(props) {\n var _theme$unstable_sxCon;\n const {\n sx,\n theme = {}\n } = props || {};\n if (!sx) {\n return null; // Emotion & styled-components will neglect null\n }\n const config = (_theme$unstable_sxCon = theme.unstable_sxConfig) != null ? _theme$unstable_sxCon : defaultSxConfig;\n\n /*\n * Receive `sxInput` as object or callback\n * and then recursively check keys & values to create media query object styles.\n * (the result will be used in `styled`)\n */\n function traverse(sxInput) {\n let sxObject = sxInput;\n if (typeof sxInput === 'function') {\n sxObject = sxInput(theme);\n } else if (typeof sxInput !== 'object') {\n // value\n return sxInput;\n }\n if (!sxObject) {\n return null;\n }\n const emptyBreakpoints = createEmptyBreakpointObject(theme.breakpoints);\n const breakpointsKeys = Object.keys(emptyBreakpoints);\n let css = emptyBreakpoints;\n Object.keys(sxObject).forEach(styleKey => {\n const value = callIfFn(sxObject[styleKey], theme);\n if (value !== null && value !== undefined) {\n if (typeof value === 'object') {\n if (config[styleKey]) {\n css = merge(css, getThemeValue(styleKey, value, theme, config));\n } else {\n const breakpointsValues = handleBreakpoints({\n theme\n }, value, x => ({\n [styleKey]: x\n }));\n if (objectsHaveSameKeys(breakpointsValues, value)) {\n css[styleKey] = styleFunctionSx({\n sx: value,\n theme\n });\n } else {\n css = merge(css, breakpointsValues);\n }\n }\n } else {\n css = merge(css, getThemeValue(styleKey, value, theme, config));\n }\n }\n });\n return removeUnusedBreakpoints(breakpointsKeys, css);\n }\n return Array.isArray(sx) ? sx.map(traverse) : traverse(sx);\n }\n return styleFunctionSx;\n}\nconst styleFunctionSx = unstable_createStyleFunctionSx();\nstyleFunctionSx.filterProps = ['sx'];\nexport default styleFunctionSx;","/**\n * A universal utility to style components with multiple color modes. Always use it from the theme object.\n * It works with:\n * - [Basic theme](https://mui.com/material-ui/customization/dark-mode/)\n * - [CSS theme variables](https://mui.com/material-ui/experimental-api/css-theme-variables/overview/)\n * - Zero-runtime engine\n *\n * Tips: Use an array over object spread and place `theme.applyStyles()` last.\n *\n * ✅ [{ background: '#e5e5e5' }, theme.applyStyles('dark', { background: '#1c1c1c' })]\n *\n * 🚫 { background: '#e5e5e5', ...theme.applyStyles('dark', { background: '#1c1c1c' })}\n *\n * @example\n * 1. using with `styled`:\n * ```jsx\n * const Component = styled('div')(({ theme }) => [\n * { background: '#e5e5e5' },\n * theme.applyStyles('dark', {\n * background: '#1c1c1c',\n * color: '#fff',\n * }),\n * ]);\n * ```\n *\n * @example\n * 2. using with `sx` prop:\n * ```jsx\n * [\n * { background: '#e5e5e5' },\n * theme.applyStyles('dark', {\n * background: '#1c1c1c',\n * color: '#fff',\n * }),\n * ]}\n * />\n * ```\n *\n * @example\n * 3. theming a component:\n * ```jsx\n * extendTheme({\n * components: {\n * MuiButton: {\n * styleOverrides: {\n * root: ({ theme }) => [\n * { background: '#e5e5e5' },\n * theme.applyStyles('dark', {\n * background: '#1c1c1c',\n * color: '#fff',\n * }),\n * ],\n * },\n * }\n * }\n * })\n *```\n */\nexport default function applyStyles(key, styles) {\n // @ts-expect-error this is 'any' type\n const theme = this;\n if (theme.vars && typeof theme.getColorSchemeSelector === 'function') {\n // If CssVarsProvider is used as a provider,\n // returns '* :where([data-mui-color-scheme=\"light|dark\"]) &'\n const selector = theme.getColorSchemeSelector(key).replace(/(\\[[^\\]]+\\])/, '*:where($1)');\n return {\n [selector]: styles\n };\n }\n if (theme.palette.mode === key) {\n return styles;\n }\n return {};\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"breakpoints\", \"palette\", \"spacing\", \"shape\"];\nimport deepmerge from '@mui/utils/deepmerge';\nimport createBreakpoints from './createBreakpoints';\nimport shape from './shape';\nimport createSpacing from './createSpacing';\nimport styleFunctionSx from '../styleFunctionSx/styleFunctionSx';\nimport defaultSxConfig from '../styleFunctionSx/defaultSxConfig';\nimport applyStyles from './applyStyles';\nfunction createTheme(options = {}, ...args) {\n const {\n breakpoints: breakpointsInput = {},\n palette: paletteInput = {},\n spacing: spacingInput,\n shape: shapeInput = {}\n } = options,\n other = _objectWithoutPropertiesLoose(options, _excluded);\n const breakpoints = createBreakpoints(breakpointsInput);\n const spacing = createSpacing(spacingInput);\n let muiTheme = deepmerge({\n breakpoints,\n direction: 'ltr',\n components: {},\n // Inject component definitions.\n palette: _extends({\n mode: 'light'\n }, paletteInput),\n spacing,\n shape: _extends({}, shape, shapeInput)\n }, other);\n muiTheme.applyStyles = applyStyles;\n muiTheme = args.reduce((acc, argument) => deepmerge(acc, argument), muiTheme);\n muiTheme.unstable_sxConfig = _extends({}, defaultSxConfig, other == null ? void 0 : other.unstable_sxConfig);\n muiTheme.unstable_sx = function sx(props) {\n return styleFunctionSx({\n sx: props,\n theme: this\n });\n };\n return muiTheme;\n}\nexport default createTheme;","'use client';\n\nimport * as React from 'react';\nimport { ThemeContext } from '@mui/styled-engine';\nfunction isObjectEmpty(obj) {\n return Object.keys(obj).length === 0;\n}\nfunction useTheme(defaultTheme = null) {\n const contextTheme = React.useContext(ThemeContext);\n return !contextTheme || isObjectEmpty(contextTheme) ? defaultTheme : contextTheme;\n}\nexport default useTheme;","'use client';\n\nimport createTheme from './createTheme';\nimport useThemeWithoutDefault from './useThemeWithoutDefault';\nexport const systemDefaultTheme = createTheme();\nfunction useTheme(defaultTheme = systemDefaultTheme) {\n return useThemeWithoutDefault(defaultTheme);\n}\nexport default useTheme;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"ownerState\"],\n _excluded2 = [\"variants\"],\n _excluded3 = [\"name\", \"slot\", \"skipVariantsResolver\", \"skipSx\", \"overridesResolver\"];\n/* eslint-disable no-underscore-dangle */\nimport styledEngineStyled, { internal_processStyles as processStyles } from '@mui/styled-engine';\nimport { isPlainObject } from '@mui/utils/deepmerge';\nimport capitalize from '@mui/utils/capitalize';\nimport getDisplayName from '@mui/utils/getDisplayName';\nimport createTheme from './createTheme';\nimport styleFunctionSx from './styleFunctionSx';\nfunction isEmpty(obj) {\n return Object.keys(obj).length === 0;\n}\n\n// https://github.com/emotion-js/emotion/blob/26ded6109fcd8ca9875cc2ce4564fee678a3f3c5/packages/styled/src/utils.js#L40\nfunction isStringTag(tag) {\n return typeof tag === 'string' &&\n // 96 is one less than the char code\n // for \"a\" so this is checking that\n // it's a lowercase character\n tag.charCodeAt(0) > 96;\n}\n\n// Update /system/styled/#api in case if this changes\nexport function shouldForwardProp(prop) {\n return prop !== 'ownerState' && prop !== 'theme' && prop !== 'sx' && prop !== 'as';\n}\nexport const systemDefaultTheme = createTheme();\nconst lowercaseFirstLetter = string => {\n if (!string) {\n return string;\n }\n return string.charAt(0).toLowerCase() + string.slice(1);\n};\nfunction resolveTheme({\n defaultTheme,\n theme,\n themeId\n}) {\n return isEmpty(theme) ? defaultTheme : theme[themeId] || theme;\n}\nfunction defaultOverridesResolver(slot) {\n if (!slot) {\n return null;\n }\n return (props, styles) => styles[slot];\n}\nfunction processStyleArg(callableStyle, _ref) {\n let {\n ownerState\n } = _ref,\n props = _objectWithoutPropertiesLoose(_ref, _excluded);\n const resolvedStylesArg = typeof callableStyle === 'function' ? callableStyle(_extends({\n ownerState\n }, props)) : callableStyle;\n if (Array.isArray(resolvedStylesArg)) {\n return resolvedStylesArg.flatMap(resolvedStyle => processStyleArg(resolvedStyle, _extends({\n ownerState\n }, props)));\n }\n if (!!resolvedStylesArg && typeof resolvedStylesArg === 'object' && Array.isArray(resolvedStylesArg.variants)) {\n const {\n variants = []\n } = resolvedStylesArg,\n otherStyles = _objectWithoutPropertiesLoose(resolvedStylesArg, _excluded2);\n let result = otherStyles;\n variants.forEach(variant => {\n let isMatch = true;\n if (typeof variant.props === 'function') {\n isMatch = variant.props(_extends({\n ownerState\n }, props, ownerState));\n } else {\n Object.keys(variant.props).forEach(key => {\n if ((ownerState == null ? void 0 : ownerState[key]) !== variant.props[key] && props[key] !== variant.props[key]) {\n isMatch = false;\n }\n });\n }\n if (isMatch) {\n if (!Array.isArray(result)) {\n result = [result];\n }\n result.push(typeof variant.style === 'function' ? variant.style(_extends({\n ownerState\n }, props, ownerState)) : variant.style);\n }\n });\n return result;\n }\n return resolvedStylesArg;\n}\nexport default function createStyled(input = {}) {\n const {\n themeId,\n defaultTheme = systemDefaultTheme,\n rootShouldForwardProp = shouldForwardProp,\n slotShouldForwardProp = shouldForwardProp\n } = input;\n const systemSx = props => {\n return styleFunctionSx(_extends({}, props, {\n theme: resolveTheme(_extends({}, props, {\n defaultTheme,\n themeId\n }))\n }));\n };\n systemSx.__mui_systemSx = true;\n return (tag, inputOptions = {}) => {\n // Filter out the `sx` style function from the previous styled component to prevent unnecessary styles generated by the composite components.\n processStyles(tag, styles => styles.filter(style => !(style != null && style.__mui_systemSx)));\n const {\n name: componentName,\n slot: componentSlot,\n skipVariantsResolver: inputSkipVariantsResolver,\n skipSx: inputSkipSx,\n // TODO v6: remove `lowercaseFirstLetter()` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n overridesResolver = defaultOverridesResolver(lowercaseFirstLetter(componentSlot))\n } = inputOptions,\n options = _objectWithoutPropertiesLoose(inputOptions, _excluded3);\n\n // if skipVariantsResolver option is defined, take the value, otherwise, true for root and false for other slots.\n const skipVariantsResolver = inputSkipVariantsResolver !== undefined ? inputSkipVariantsResolver :\n // TODO v6: remove `Root` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n componentSlot && componentSlot !== 'Root' && componentSlot !== 'root' || false;\n const skipSx = inputSkipSx || false;\n let label;\n if (process.env.NODE_ENV !== 'production') {\n if (componentName) {\n // TODO v6: remove `lowercaseFirstLetter()` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n label = `${componentName}-${lowercaseFirstLetter(componentSlot || 'Root')}`;\n }\n }\n let shouldForwardPropOption = shouldForwardProp;\n\n // TODO v6: remove `Root` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n if (componentSlot === 'Root' || componentSlot === 'root') {\n shouldForwardPropOption = rootShouldForwardProp;\n } else if (componentSlot) {\n // any other slot specified\n shouldForwardPropOption = slotShouldForwardProp;\n } else if (isStringTag(tag)) {\n // for string (html) tag, preserve the behavior in emotion & styled-components.\n shouldForwardPropOption = undefined;\n }\n const defaultStyledResolver = styledEngineStyled(tag, _extends({\n shouldForwardProp: shouldForwardPropOption,\n label\n }, options));\n const transformStyleArg = stylesArg => {\n // On the server Emotion doesn't use React.forwardRef for creating components, so the created\n // component stays as a function. This condition makes sure that we do not interpolate functions\n // which are basically components used as a selectors.\n if (typeof stylesArg === 'function' && stylesArg.__emotion_real !== stylesArg || isPlainObject(stylesArg)) {\n return props => processStyleArg(stylesArg, _extends({}, props, {\n theme: resolveTheme({\n theme: props.theme,\n defaultTheme,\n themeId\n })\n }));\n }\n return stylesArg;\n };\n const muiStyledResolver = (styleArg, ...expressions) => {\n let transformedStyleArg = transformStyleArg(styleArg);\n const expressionsWithDefaultTheme = expressions ? expressions.map(transformStyleArg) : [];\n if (componentName && overridesResolver) {\n expressionsWithDefaultTheme.push(props => {\n const theme = resolveTheme(_extends({}, props, {\n defaultTheme,\n themeId\n }));\n if (!theme.components || !theme.components[componentName] || !theme.components[componentName].styleOverrides) {\n return null;\n }\n const styleOverrides = theme.components[componentName].styleOverrides;\n const resolvedStyleOverrides = {};\n // TODO: v7 remove iteration and use `resolveStyleArg(styleOverrides[slot])` directly\n Object.entries(styleOverrides).forEach(([slotKey, slotStyle]) => {\n resolvedStyleOverrides[slotKey] = processStyleArg(slotStyle, _extends({}, props, {\n theme\n }));\n });\n return overridesResolver(props, resolvedStyleOverrides);\n });\n }\n if (componentName && !skipVariantsResolver) {\n expressionsWithDefaultTheme.push(props => {\n var _theme$components;\n const theme = resolveTheme(_extends({}, props, {\n defaultTheme,\n themeId\n }));\n const themeVariants = theme == null || (_theme$components = theme.components) == null || (_theme$components = _theme$components[componentName]) == null ? void 0 : _theme$components.variants;\n return processStyleArg({\n variants: themeVariants\n }, _extends({}, props, {\n theme\n }));\n });\n }\n if (!skipSx) {\n expressionsWithDefaultTheme.push(systemSx);\n }\n const numOfCustomFnsApplied = expressionsWithDefaultTheme.length - expressions.length;\n if (Array.isArray(styleArg) && numOfCustomFnsApplied > 0) {\n const placeholders = new Array(numOfCustomFnsApplied).fill('');\n // If the type is array, than we need to add placeholders in the template for the overrides, variants and the sx styles.\n transformedStyleArg = [...styleArg, ...placeholders];\n transformedStyleArg.raw = [...styleArg.raw, ...placeholders];\n }\n const Component = defaultStyledResolver(transformedStyleArg, ...expressionsWithDefaultTheme);\n if (process.env.NODE_ENV !== 'production') {\n let displayName;\n if (componentName) {\n displayName = `${componentName}${capitalize(componentSlot || '')}`;\n }\n if (displayName === undefined) {\n displayName = `Styled(${getDisplayName(tag)})`;\n }\n Component.displayName = displayName;\n }\n if (tag.muiName) {\n Component.muiName = tag.muiName;\n }\n return Component;\n };\n if (defaultStyledResolver.withConfig) {\n muiStyledResolver.withConfig = defaultStyledResolver.withConfig;\n }\n return muiStyledResolver;\n };\n}","import resolveProps from '@mui/utils/resolveProps';\nexport default function getThemeProps(params) {\n const {\n theme,\n name,\n props\n } = params;\n if (!theme || !theme.components || !theme.components[name] || !theme.components[name].defaultProps) {\n return props;\n }\n return resolveProps(theme.components[name].defaultProps, props);\n}","'use client';\n\nimport getThemeProps from './getThemeProps';\nimport useTheme from '../useTheme';\nexport default function useThemeProps({\n props,\n name,\n defaultTheme,\n themeId\n}) {\n let theme = useTheme(defaultTheme);\n if (themeId) {\n theme = theme[themeId] || theme;\n }\n const mergedProps = getThemeProps({\n theme,\n name,\n props\n });\n return mergedProps;\n}","import _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\n/* eslint-disable @typescript-eslint/naming-convention */\nimport clamp from '@mui/utils/clamp';\n/**\n * Returns a number whose value is limited to the given range.\n * @param {number} value The value to be clamped\n * @param {number} min The lower boundary of the output range\n * @param {number} max The upper boundary of the output range\n * @returns {number} A number in the range [min, max]\n */\nfunction clampWrapper(value, min = 0, max = 1) {\n if (process.env.NODE_ENV !== 'production') {\n if (value < min || value > max) {\n console.error(`MUI: The value provided ${value} is out of range [${min}, ${max}].`);\n }\n }\n return clamp(value, min, max);\n}\n\n/**\n * Converts a color from CSS hex format to CSS rgb format.\n * @param {string} color - Hex color, i.e. #nnn or #nnnnnn\n * @returns {string} A CSS rgb color string\n */\nexport function hexToRgb(color) {\n color = color.slice(1);\n const re = new RegExp(`.{1,${color.length >= 6 ? 2 : 1}}`, 'g');\n let colors = color.match(re);\n if (colors && colors[0].length === 1) {\n colors = colors.map(n => n + n);\n }\n return colors ? `rgb${colors.length === 4 ? 'a' : ''}(${colors.map((n, index) => {\n return index < 3 ? parseInt(n, 16) : Math.round(parseInt(n, 16) / 255 * 1000) / 1000;\n }).join(', ')})` : '';\n}\nfunction intToHex(int) {\n const hex = int.toString(16);\n return hex.length === 1 ? `0${hex}` : hex;\n}\n\n/**\n * Returns an object with the type and values of a color.\n *\n * Note: Does not support rgb % values.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @returns {object} - A MUI color object: {type: string, values: number[]}\n */\nexport function decomposeColor(color) {\n // Idempotent\n if (color.type) {\n return color;\n }\n if (color.charAt(0) === '#') {\n return decomposeColor(hexToRgb(color));\n }\n const marker = color.indexOf('(');\n const type = color.substring(0, marker);\n if (['rgb', 'rgba', 'hsl', 'hsla', 'color'].indexOf(type) === -1) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: Unsupported \\`${color}\\` color.\nThe following formats are supported: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color().` : _formatMuiErrorMessage(9, color));\n }\n let values = color.substring(marker + 1, color.length - 1);\n let colorSpace;\n if (type === 'color') {\n values = values.split(' ');\n colorSpace = values.shift();\n if (values.length === 4 && values[3].charAt(0) === '/') {\n values[3] = values[3].slice(1);\n }\n if (['srgb', 'display-p3', 'a98-rgb', 'prophoto-rgb', 'rec-2020'].indexOf(colorSpace) === -1) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: unsupported \\`${colorSpace}\\` color space.\nThe following color spaces are supported: srgb, display-p3, a98-rgb, prophoto-rgb, rec-2020.` : _formatMuiErrorMessage(10, colorSpace));\n }\n } else {\n values = values.split(',');\n }\n values = values.map(value => parseFloat(value));\n return {\n type,\n values,\n colorSpace\n };\n}\n\n/**\n * Returns a channel created from the input color.\n *\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @returns {string} - The channel for the color, that can be used in rgba or hsla colors\n */\nexport const colorChannel = color => {\n const decomposedColor = decomposeColor(color);\n return decomposedColor.values.slice(0, 3).map((val, idx) => decomposedColor.type.indexOf('hsl') !== -1 && idx !== 0 ? `${val}%` : val).join(' ');\n};\nexport const private_safeColorChannel = (color, warning) => {\n try {\n return colorChannel(color);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n};\n\n/**\n * Converts a color object with type and values to a string.\n * @param {object} color - Decomposed color\n * @param {string} color.type - One of: 'rgb', 'rgba', 'hsl', 'hsla', 'color'\n * @param {array} color.values - [n,n,n] or [n,n,n,n]\n * @returns {string} A CSS color string\n */\nexport function recomposeColor(color) {\n const {\n type,\n colorSpace\n } = color;\n let {\n values\n } = color;\n if (type.indexOf('rgb') !== -1) {\n // Only convert the first 3 values to int (i.e. not alpha)\n values = values.map((n, i) => i < 3 ? parseInt(n, 10) : n);\n } else if (type.indexOf('hsl') !== -1) {\n values[1] = `${values[1]}%`;\n values[2] = `${values[2]}%`;\n }\n if (type.indexOf('color') !== -1) {\n values = `${colorSpace} ${values.join(' ')}`;\n } else {\n values = `${values.join(', ')}`;\n }\n return `${type}(${values})`;\n}\n\n/**\n * Converts a color from CSS rgb format to CSS hex format.\n * @param {string} color - RGB color, i.e. rgb(n, n, n)\n * @returns {string} A CSS rgb color string, i.e. #nnnnnn\n */\nexport function rgbToHex(color) {\n // Idempotent\n if (color.indexOf('#') === 0) {\n return color;\n }\n const {\n values\n } = decomposeColor(color);\n return `#${values.map((n, i) => intToHex(i === 3 ? Math.round(255 * n) : n)).join('')}`;\n}\n\n/**\n * Converts a color from hsl format to rgb format.\n * @param {string} color - HSL color values\n * @returns {string} rgb color values\n */\nexport function hslToRgb(color) {\n color = decomposeColor(color);\n const {\n values\n } = color;\n const h = values[0];\n const s = values[1] / 100;\n const l = values[2] / 100;\n const a = s * Math.min(l, 1 - l);\n const f = (n, k = (n + h / 30) % 12) => l - a * Math.max(Math.min(k - 3, 9 - k, 1), -1);\n let type = 'rgb';\n const rgb = [Math.round(f(0) * 255), Math.round(f(8) * 255), Math.round(f(4) * 255)];\n if (color.type === 'hsla') {\n type += 'a';\n rgb.push(values[3]);\n }\n return recomposeColor({\n type,\n values: rgb\n });\n}\n/**\n * The relative brightness of any point in a color space,\n * normalized to 0 for darkest black and 1 for lightest white.\n *\n * Formula: https://www.w3.org/TR/WCAG20-TECHS/G17.html#G17-tests\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @returns {number} The relative brightness of the color in the range 0 - 1\n */\nexport function getLuminance(color) {\n color = decomposeColor(color);\n let rgb = color.type === 'hsl' || color.type === 'hsla' ? decomposeColor(hslToRgb(color)).values : color.values;\n rgb = rgb.map(val => {\n if (color.type !== 'color') {\n val /= 255; // normalized\n }\n return val <= 0.03928 ? val / 12.92 : ((val + 0.055) / 1.055) ** 2.4;\n });\n\n // Truncate at 3 digits\n return Number((0.2126 * rgb[0] + 0.7152 * rgb[1] + 0.0722 * rgb[2]).toFixed(3));\n}\n\n/**\n * Calculates the contrast ratio between two colors.\n *\n * Formula: https://www.w3.org/TR/WCAG20-TECHS/G17.html#G17-tests\n * @param {string} foreground - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla()\n * @param {string} background - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla()\n * @returns {number} A contrast ratio value in the range 0 - 21.\n */\nexport function getContrastRatio(foreground, background) {\n const lumA = getLuminance(foreground);\n const lumB = getLuminance(background);\n return (Math.max(lumA, lumB) + 0.05) / (Math.min(lumA, lumB) + 0.05);\n}\n\n/**\n * Sets the absolute transparency of a color.\n * Any existing alpha values are overwritten.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} value - value to set the alpha channel to in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function alpha(color, value) {\n color = decomposeColor(color);\n value = clampWrapper(value);\n if (color.type === 'rgb' || color.type === 'hsl') {\n color.type += 'a';\n }\n if (color.type === 'color') {\n color.values[3] = `/${value}`;\n } else {\n color.values[3] = value;\n }\n return recomposeColor(color);\n}\nexport function private_safeAlpha(color, value, warning) {\n try {\n return alpha(color, value);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Darkens a color.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} coefficient - multiplier in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function darken(color, coefficient) {\n color = decomposeColor(color);\n coefficient = clampWrapper(coefficient);\n if (color.type.indexOf('hsl') !== -1) {\n color.values[2] *= 1 - coefficient;\n } else if (color.type.indexOf('rgb') !== -1 || color.type.indexOf('color') !== -1) {\n for (let i = 0; i < 3; i += 1) {\n color.values[i] *= 1 - coefficient;\n }\n }\n return recomposeColor(color);\n}\nexport function private_safeDarken(color, coefficient, warning) {\n try {\n return darken(color, coefficient);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Lightens a color.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} coefficient - multiplier in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function lighten(color, coefficient) {\n color = decomposeColor(color);\n coefficient = clampWrapper(coefficient);\n if (color.type.indexOf('hsl') !== -1) {\n color.values[2] += (100 - color.values[2]) * coefficient;\n } else if (color.type.indexOf('rgb') !== -1) {\n for (let i = 0; i < 3; i += 1) {\n color.values[i] += (255 - color.values[i]) * coefficient;\n }\n } else if (color.type.indexOf('color') !== -1) {\n for (let i = 0; i < 3; i += 1) {\n color.values[i] += (1 - color.values[i]) * coefficient;\n }\n }\n return recomposeColor(color);\n}\nexport function private_safeLighten(color, coefficient, warning) {\n try {\n return lighten(color, coefficient);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Darken or lighten a color, depending on its luminance.\n * Light colors are darkened, dark colors are lightened.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} coefficient=0.15 - multiplier in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function emphasize(color, coefficient = 0.15) {\n return getLuminance(color) > 0.5 ? darken(color, coefficient) : lighten(color, coefficient);\n}\nexport function private_safeEmphasize(color, coefficient, warning) {\n try {\n return emphasize(color, coefficient);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Blend a transparent overlay color with a background color, resulting in a single\n * RGB color.\n * @param {string} background - CSS color\n * @param {string} overlay - CSS color\n * @param {number} opacity - Opacity multiplier in the range 0 - 1\n * @param {number} [gamma=1.0] - Gamma correction factor. For gamma-correct blending, 2.2 is usual.\n */\nexport function blend(background, overlay, opacity, gamma = 1.0) {\n const blendChannel = (b, o) => Math.round((b ** (1 / gamma) * (1 - opacity) + o ** (1 / gamma) * opacity) ** gamma);\n const backgroundColor = decomposeColor(background);\n const overlayColor = decomposeColor(overlay);\n const rgb = [blendChannel(backgroundColor.values[0], overlayColor.values[0]), blendChannel(backgroundColor.values[1], overlayColor.values[1]), blendChannel(backgroundColor.values[2], overlayColor.values[2])];\n return recomposeColor({\n type: 'rgb',\n values: rgb\n });\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nexport default function createMixins(breakpoints, mixins) {\n return _extends({\n toolbar: {\n minHeight: 56,\n [breakpoints.up('xs')]: {\n '@media (orientation: landscape)': {\n minHeight: 48\n }\n },\n [breakpoints.up('sm')]: {\n minHeight: 64\n }\n }\n }, mixins);\n}","const common = {\n black: '#000',\n white: '#fff'\n};\nexport default common;","const grey = {\n 50: '#fafafa',\n 100: '#f5f5f5',\n 200: '#eeeeee',\n 300: '#e0e0e0',\n 400: '#bdbdbd',\n 500: '#9e9e9e',\n 600: '#757575',\n 700: '#616161',\n 800: '#424242',\n 900: '#212121',\n A100: '#f5f5f5',\n A200: '#eeeeee',\n A400: '#bdbdbd',\n A700: '#616161'\n};\nexport default grey;","const purple = {\n 50: '#f3e5f5',\n 100: '#e1bee7',\n 200: '#ce93d8',\n 300: '#ba68c8',\n 400: '#ab47bc',\n 500: '#9c27b0',\n 600: '#8e24aa',\n 700: '#7b1fa2',\n 800: '#6a1b9a',\n 900: '#4a148c',\n A100: '#ea80fc',\n A200: '#e040fb',\n A400: '#d500f9',\n A700: '#aa00ff'\n};\nexport default purple;","const red = {\n 50: '#ffebee',\n 100: '#ffcdd2',\n 200: '#ef9a9a',\n 300: '#e57373',\n 400: '#ef5350',\n 500: '#f44336',\n 600: '#e53935',\n 700: '#d32f2f',\n 800: '#c62828',\n 900: '#b71c1c',\n A100: '#ff8a80',\n A200: '#ff5252',\n A400: '#ff1744',\n A700: '#d50000'\n};\nexport default red;","const orange = {\n 50: '#fff3e0',\n 100: '#ffe0b2',\n 200: '#ffcc80',\n 300: '#ffb74d',\n 400: '#ffa726',\n 500: '#ff9800',\n 600: '#fb8c00',\n 700: '#f57c00',\n 800: '#ef6c00',\n 900: '#e65100',\n A100: '#ffd180',\n A200: '#ffab40',\n A400: '#ff9100',\n A700: '#ff6d00'\n};\nexport default orange;","const blue = {\n 50: '#e3f2fd',\n 100: '#bbdefb',\n 200: '#90caf9',\n 300: '#64b5f6',\n 400: '#42a5f5',\n 500: '#2196f3',\n 600: '#1e88e5',\n 700: '#1976d2',\n 800: '#1565c0',\n 900: '#0d47a1',\n A100: '#82b1ff',\n A200: '#448aff',\n A400: '#2979ff',\n A700: '#2962ff'\n};\nexport default blue;","const lightBlue = {\n 50: '#e1f5fe',\n 100: '#b3e5fc',\n 200: '#81d4fa',\n 300: '#4fc3f7',\n 400: '#29b6f6',\n 500: '#03a9f4',\n 600: '#039be5',\n 700: '#0288d1',\n 800: '#0277bd',\n 900: '#01579b',\n A100: '#80d8ff',\n A200: '#40c4ff',\n A400: '#00b0ff',\n A700: '#0091ea'\n};\nexport default lightBlue;","const green = {\n 50: '#e8f5e9',\n 100: '#c8e6c9',\n 200: '#a5d6a7',\n 300: '#81c784',\n 400: '#66bb6a',\n 500: '#4caf50',\n 600: '#43a047',\n 700: '#388e3c',\n 800: '#2e7d32',\n 900: '#1b5e20',\n A100: '#b9f6ca',\n A200: '#69f0ae',\n A400: '#00e676',\n A700: '#00c853'\n};\nexport default green;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\nconst _excluded = [\"mode\", \"contrastThreshold\", \"tonalOffset\"];\nimport { deepmerge } from '@mui/utils';\nimport { darken, getContrastRatio, lighten } from '@mui/system';\nimport common from '../colors/common';\nimport grey from '../colors/grey';\nimport purple from '../colors/purple';\nimport red from '../colors/red';\nimport orange from '../colors/orange';\nimport blue from '../colors/blue';\nimport lightBlue from '../colors/lightBlue';\nimport green from '../colors/green';\nexport const light = {\n // The colors used to style the text.\n text: {\n // The most important text.\n primary: 'rgba(0, 0, 0, 0.87)',\n // Secondary text.\n secondary: 'rgba(0, 0, 0, 0.6)',\n // Disabled text have even lower visual prominence.\n disabled: 'rgba(0, 0, 0, 0.38)'\n },\n // The color used to divide different elements.\n divider: 'rgba(0, 0, 0, 0.12)',\n // The background colors used to style the surfaces.\n // Consistency between these values is important.\n background: {\n paper: common.white,\n default: common.white\n },\n // The colors used to style the action elements.\n action: {\n // The color of an active action like an icon button.\n active: 'rgba(0, 0, 0, 0.54)',\n // The color of an hovered action.\n hover: 'rgba(0, 0, 0, 0.04)',\n hoverOpacity: 0.04,\n // The color of a selected action.\n selected: 'rgba(0, 0, 0, 0.08)',\n selectedOpacity: 0.08,\n // The color of a disabled action.\n disabled: 'rgba(0, 0, 0, 0.26)',\n // The background color of a disabled action.\n disabledBackground: 'rgba(0, 0, 0, 0.12)',\n disabledOpacity: 0.38,\n focus: 'rgba(0, 0, 0, 0.12)',\n focusOpacity: 0.12,\n activatedOpacity: 0.12\n }\n};\nexport const dark = {\n text: {\n primary: common.white,\n secondary: 'rgba(255, 255, 255, 0.7)',\n disabled: 'rgba(255, 255, 255, 0.5)',\n icon: 'rgba(255, 255, 255, 0.5)'\n },\n divider: 'rgba(255, 255, 255, 0.12)',\n background: {\n paper: '#121212',\n default: '#121212'\n },\n action: {\n active: common.white,\n hover: 'rgba(255, 255, 255, 0.08)',\n hoverOpacity: 0.08,\n selected: 'rgba(255, 255, 255, 0.16)',\n selectedOpacity: 0.16,\n disabled: 'rgba(255, 255, 255, 0.3)',\n disabledBackground: 'rgba(255, 255, 255, 0.12)',\n disabledOpacity: 0.38,\n focus: 'rgba(255, 255, 255, 0.12)',\n focusOpacity: 0.12,\n activatedOpacity: 0.24\n }\n};\nfunction addLightOrDark(intent, direction, shade, tonalOffset) {\n const tonalOffsetLight = tonalOffset.light || tonalOffset;\n const tonalOffsetDark = tonalOffset.dark || tonalOffset * 1.5;\n if (!intent[direction]) {\n if (intent.hasOwnProperty(shade)) {\n intent[direction] = intent[shade];\n } else if (direction === 'light') {\n intent.light = lighten(intent.main, tonalOffsetLight);\n } else if (direction === 'dark') {\n intent.dark = darken(intent.main, tonalOffsetDark);\n }\n }\n}\nfunction getDefaultPrimary(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: blue[200],\n light: blue[50],\n dark: blue[400]\n };\n }\n return {\n main: blue[700],\n light: blue[400],\n dark: blue[800]\n };\n}\nfunction getDefaultSecondary(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: purple[200],\n light: purple[50],\n dark: purple[400]\n };\n }\n return {\n main: purple[500],\n light: purple[300],\n dark: purple[700]\n };\n}\nfunction getDefaultError(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: red[500],\n light: red[300],\n dark: red[700]\n };\n }\n return {\n main: red[700],\n light: red[400],\n dark: red[800]\n };\n}\nfunction getDefaultInfo(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: lightBlue[400],\n light: lightBlue[300],\n dark: lightBlue[700]\n };\n }\n return {\n main: lightBlue[700],\n light: lightBlue[500],\n dark: lightBlue[900]\n };\n}\nfunction getDefaultSuccess(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: green[400],\n light: green[300],\n dark: green[700]\n };\n }\n return {\n main: green[800],\n light: green[500],\n dark: green[900]\n };\n}\nfunction getDefaultWarning(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: orange[400],\n light: orange[300],\n dark: orange[700]\n };\n }\n return {\n main: '#ed6c02',\n // closest to orange[800] that pass 3:1.\n light: orange[500],\n dark: orange[900]\n };\n}\nexport default function createPalette(palette) {\n const {\n mode = 'light',\n contrastThreshold = 3,\n tonalOffset = 0.2\n } = palette,\n other = _objectWithoutPropertiesLoose(palette, _excluded);\n const primary = palette.primary || getDefaultPrimary(mode);\n const secondary = palette.secondary || getDefaultSecondary(mode);\n const error = palette.error || getDefaultError(mode);\n const info = palette.info || getDefaultInfo(mode);\n const success = palette.success || getDefaultSuccess(mode);\n const warning = palette.warning || getDefaultWarning(mode);\n\n // Use the same logic as\n // Bootstrap: https://github.com/twbs/bootstrap/blob/1d6e3710dd447de1a200f29e8fa521f8a0908f70/scss/_functions.scss#L59\n // and material-components-web https://github.com/material-components/material-components-web/blob/ac46b8863c4dab9fc22c4c662dc6bd1b65dd652f/packages/mdc-theme/_functions.scss#L54\n function getContrastText(background) {\n const contrastText = getContrastRatio(background, dark.text.primary) >= contrastThreshold ? dark.text.primary : light.text.primary;\n if (process.env.NODE_ENV !== 'production') {\n const contrast = getContrastRatio(background, contrastText);\n if (contrast < 3) {\n console.error([`MUI: The contrast ratio of ${contrast}:1 for ${contrastText} on ${background}`, 'falls below the WCAG recommended absolute minimum contrast ratio of 3:1.', 'https://www.w3.org/TR/2008/REC-WCAG20-20081211/#visual-audio-contrast-contrast'].join('\\n'));\n }\n }\n return contrastText;\n }\n const augmentColor = ({\n color,\n name,\n mainShade = 500,\n lightShade = 300,\n darkShade = 700\n }) => {\n color = _extends({}, color);\n if (!color.main && color[mainShade]) {\n color.main = color[mainShade];\n }\n if (!color.hasOwnProperty('main')) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: The color${name ? ` (${name})` : ''} provided to augmentColor(color) is invalid.\nThe color object needs to have a \\`main\\` property or a \\`${mainShade}\\` property.` : _formatMuiErrorMessage(11, name ? ` (${name})` : '', mainShade));\n }\n if (typeof color.main !== 'string') {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: The color${name ? ` (${name})` : ''} provided to augmentColor(color) is invalid.\n\\`color.main\\` should be a string, but \\`${JSON.stringify(color.main)}\\` was provided instead.\n\nDid you intend to use one of the following approaches?\n\nimport { green } from \"@mui/material/colors\";\n\nconst theme1 = createTheme({ palette: {\n primary: green,\n} });\n\nconst theme2 = createTheme({ palette: {\n primary: { main: green[500] },\n} });` : _formatMuiErrorMessage(12, name ? ` (${name})` : '', JSON.stringify(color.main)));\n }\n addLightOrDark(color, 'light', lightShade, tonalOffset);\n addLightOrDark(color, 'dark', darkShade, tonalOffset);\n if (!color.contrastText) {\n color.contrastText = getContrastText(color.main);\n }\n return color;\n };\n const modes = {\n dark,\n light\n };\n if (process.env.NODE_ENV !== 'production') {\n if (!modes[mode]) {\n console.error(`MUI: The palette mode \\`${mode}\\` is not supported.`);\n }\n }\n const paletteOutput = deepmerge(_extends({\n // A collection of common colors.\n common: _extends({}, common),\n // prevent mutable object.\n // The palette mode, can be light or dark.\n mode,\n // The colors used to represent primary interface elements for a user.\n primary: augmentColor({\n color: primary,\n name: 'primary'\n }),\n // The colors used to represent secondary interface elements for a user.\n secondary: augmentColor({\n color: secondary,\n name: 'secondary',\n mainShade: 'A400',\n lightShade: 'A200',\n darkShade: 'A700'\n }),\n // The colors used to represent interface elements that the user should be made aware of.\n error: augmentColor({\n color: error,\n name: 'error'\n }),\n // The colors used to represent potentially dangerous actions or important messages.\n warning: augmentColor({\n color: warning,\n name: 'warning'\n }),\n // The colors used to present information to the user that is neutral and not necessarily important.\n info: augmentColor({\n color: info,\n name: 'info'\n }),\n // The colors used to indicate the successful completion of an action that user triggered.\n success: augmentColor({\n color: success,\n name: 'success'\n }),\n // The grey colors.\n grey,\n // Used by `getContrastText()` to maximize the contrast between\n // the background and the text.\n contrastThreshold,\n // Takes a background color and returns the text color that maximizes the contrast.\n getContrastText,\n // Generate a rich color object.\n augmentColor,\n // Used by the functions below to shift a color's luminance by approximately\n // two indexes within its tonal palette.\n // E.g., shift from Red 500 to Red 300 or Red 700.\n tonalOffset\n }, modes[mode]), other);\n return paletteOutput;\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"fontFamily\", \"fontSize\", \"fontWeightLight\", \"fontWeightRegular\", \"fontWeightMedium\", \"fontWeightBold\", \"htmlFontSize\", \"allVariants\", \"pxToRem\"];\nimport { deepmerge } from '@mui/utils';\nfunction round(value) {\n return Math.round(value * 1e5) / 1e5;\n}\nconst caseAllCaps = {\n textTransform: 'uppercase'\n};\nconst defaultFontFamily = '\"Roboto\", \"Helvetica\", \"Arial\", sans-serif';\n\n/**\n * @see @link{https://m2.material.io/design/typography/the-type-system.html}\n * @see @link{https://m2.material.io/design/typography/understanding-typography.html}\n */\nexport default function createTypography(palette, typography) {\n const _ref = typeof typography === 'function' ? typography(palette) : typography,\n {\n fontFamily = defaultFontFamily,\n // The default font size of the Material Specification.\n fontSize = 14,\n // px\n fontWeightLight = 300,\n fontWeightRegular = 400,\n fontWeightMedium = 500,\n fontWeightBold = 700,\n // Tell MUI what's the font-size on the html element.\n // 16px is the default font-size used by browsers.\n htmlFontSize = 16,\n // Apply the CSS properties to all the variants.\n allVariants,\n pxToRem: pxToRem2\n } = _ref,\n other = _objectWithoutPropertiesLoose(_ref, _excluded);\n if (process.env.NODE_ENV !== 'production') {\n if (typeof fontSize !== 'number') {\n console.error('MUI: `fontSize` is required to be a number.');\n }\n if (typeof htmlFontSize !== 'number') {\n console.error('MUI: `htmlFontSize` is required to be a number.');\n }\n }\n const coef = fontSize / 14;\n const pxToRem = pxToRem2 || (size => `${size / htmlFontSize * coef}rem`);\n const buildVariant = (fontWeight, size, lineHeight, letterSpacing, casing) => _extends({\n fontFamily,\n fontWeight,\n fontSize: pxToRem(size),\n // Unitless following https://meyerweb.com/eric/thoughts/2006/02/08/unitless-line-heights/\n lineHeight\n }, fontFamily === defaultFontFamily ? {\n letterSpacing: `${round(letterSpacing / size)}em`\n } : {}, casing, allVariants);\n const variants = {\n h1: buildVariant(fontWeightLight, 96, 1.167, -1.5),\n h2: buildVariant(fontWeightLight, 60, 1.2, -0.5),\n h3: buildVariant(fontWeightRegular, 48, 1.167, 0),\n h4: buildVariant(fontWeightRegular, 34, 1.235, 0.25),\n h5: buildVariant(fontWeightRegular, 24, 1.334, 0),\n h6: buildVariant(fontWeightMedium, 20, 1.6, 0.15),\n subtitle1: buildVariant(fontWeightRegular, 16, 1.75, 0.15),\n subtitle2: buildVariant(fontWeightMedium, 14, 1.57, 0.1),\n body1: buildVariant(fontWeightRegular, 16, 1.5, 0.15),\n body2: buildVariant(fontWeightRegular, 14, 1.43, 0.15),\n button: buildVariant(fontWeightMedium, 14, 1.75, 0.4, caseAllCaps),\n caption: buildVariant(fontWeightRegular, 12, 1.66, 0.4),\n overline: buildVariant(fontWeightRegular, 12, 2.66, 1, caseAllCaps),\n // TODO v6: Remove handling of 'inherit' variant from the theme as it is already handled in Material UI's Typography component. Also, remember to remove the associated types.\n inherit: {\n fontFamily: 'inherit',\n fontWeight: 'inherit',\n fontSize: 'inherit',\n lineHeight: 'inherit',\n letterSpacing: 'inherit'\n }\n };\n return deepmerge(_extends({\n htmlFontSize,\n pxToRem,\n fontFamily,\n fontSize,\n fontWeightLight,\n fontWeightRegular,\n fontWeightMedium,\n fontWeightBold\n }, variants), other, {\n clone: false // No need to clone deep\n });\n}","const shadowKeyUmbraOpacity = 0.2;\nconst shadowKeyPenumbraOpacity = 0.14;\nconst shadowAmbientShadowOpacity = 0.12;\nfunction createShadow(...px) {\n return [`${px[0]}px ${px[1]}px ${px[2]}px ${px[3]}px rgba(0,0,0,${shadowKeyUmbraOpacity})`, `${px[4]}px ${px[5]}px ${px[6]}px ${px[7]}px rgba(0,0,0,${shadowKeyPenumbraOpacity})`, `${px[8]}px ${px[9]}px ${px[10]}px ${px[11]}px rgba(0,0,0,${shadowAmbientShadowOpacity})`].join(',');\n}\n\n// Values from https://github.com/material-components/material-components-web/blob/be8747f94574669cb5e7add1a7c54fa41a89cec7/packages/mdc-elevation/_variables.scss\nconst shadows = ['none', createShadow(0, 2, 1, -1, 0, 1, 1, 0, 0, 1, 3, 0), createShadow(0, 3, 1, -2, 0, 2, 2, 0, 0, 1, 5, 0), createShadow(0, 3, 3, -2, 0, 3, 4, 0, 0, 1, 8, 0), createShadow(0, 2, 4, -1, 0, 4, 5, 0, 0, 1, 10, 0), createShadow(0, 3, 5, -1, 0, 5, 8, 0, 0, 1, 14, 0), createShadow(0, 3, 5, -1, 0, 6, 10, 0, 0, 1, 18, 0), createShadow(0, 4, 5, -2, 0, 7, 10, 1, 0, 2, 16, 1), createShadow(0, 5, 5, -3, 0, 8, 10, 1, 0, 3, 14, 2), createShadow(0, 5, 6, -3, 0, 9, 12, 1, 0, 3, 16, 2), createShadow(0, 6, 6, -3, 0, 10, 14, 1, 0, 4, 18, 3), createShadow(0, 6, 7, -4, 0, 11, 15, 1, 0, 4, 20, 3), createShadow(0, 7, 8, -4, 0, 12, 17, 2, 0, 5, 22, 4), createShadow(0, 7, 8, -4, 0, 13, 19, 2, 0, 5, 24, 4), createShadow(0, 7, 9, -4, 0, 14, 21, 2, 0, 5, 26, 4), createShadow(0, 8, 9, -5, 0, 15, 22, 2, 0, 6, 28, 5), createShadow(0, 8, 10, -5, 0, 16, 24, 2, 0, 6, 30, 5), createShadow(0, 8, 11, -5, 0, 17, 26, 2, 0, 6, 32, 5), createShadow(0, 9, 11, -5, 0, 18, 28, 2, 0, 7, 34, 6), createShadow(0, 9, 12, -6, 0, 19, 29, 2, 0, 7, 36, 6), createShadow(0, 10, 13, -6, 0, 20, 31, 3, 0, 8, 38, 7), createShadow(0, 10, 13, -6, 0, 21, 33, 3, 0, 8, 40, 7), createShadow(0, 10, 14, -6, 0, 22, 35, 3, 0, 8, 42, 7), createShadow(0, 11, 14, -7, 0, 23, 36, 3, 0, 9, 44, 8), createShadow(0, 11, 15, -7, 0, 24, 38, 3, 0, 9, 46, 8)];\nexport default shadows;","import _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nconst _excluded = [\"duration\", \"easing\", \"delay\"];\n// Follow https://material.google.com/motion/duration-easing.html#duration-easing-natural-easing-curves\n// to learn the context in which each easing should be used.\nexport const easing = {\n // This is the most common easing curve.\n easeInOut: 'cubic-bezier(0.4, 0, 0.2, 1)',\n // Objects enter the screen at full velocity from off-screen and\n // slowly decelerate to a resting point.\n easeOut: 'cubic-bezier(0.0, 0, 0.2, 1)',\n // Objects leave the screen at full velocity. They do not decelerate when off-screen.\n easeIn: 'cubic-bezier(0.4, 0, 1, 1)',\n // The sharp curve is used by objects that may return to the screen at any time.\n sharp: 'cubic-bezier(0.4, 0, 0.6, 1)'\n};\n\n// Follow https://m2.material.io/guidelines/motion/duration-easing.html#duration-easing-common-durations\n// to learn when use what timing\nexport const duration = {\n shortest: 150,\n shorter: 200,\n short: 250,\n // most basic recommended timing\n standard: 300,\n // this is to be used in complex animations\n complex: 375,\n // recommended when something is entering screen\n enteringScreen: 225,\n // recommended when something is leaving screen\n leavingScreen: 195\n};\nfunction formatMs(milliseconds) {\n return `${Math.round(milliseconds)}ms`;\n}\nfunction getAutoHeightDuration(height) {\n if (!height) {\n return 0;\n }\n const constant = height / 36;\n\n // https://www.wolframalpha.com/input/?i=(4+%2B+15+*+(x+%2F+36+)+**+0.25+%2B+(x+%2F+36)+%2F+5)+*+10\n return Math.round((4 + 15 * constant ** 0.25 + constant / 5) * 10);\n}\nexport default function createTransitions(inputTransitions) {\n const mergedEasing = _extends({}, easing, inputTransitions.easing);\n const mergedDuration = _extends({}, duration, inputTransitions.duration);\n const create = (props = ['all'], options = {}) => {\n const {\n duration: durationOption = mergedDuration.standard,\n easing: easingOption = mergedEasing.easeInOut,\n delay = 0\n } = options,\n other = _objectWithoutPropertiesLoose(options, _excluded);\n if (process.env.NODE_ENV !== 'production') {\n const isString = value => typeof value === 'string';\n // IE11 support, replace with Number.isNaN\n // eslint-disable-next-line no-restricted-globals\n const isNumber = value => !isNaN(parseFloat(value));\n if (!isString(props) && !Array.isArray(props)) {\n console.error('MUI: Argument \"props\" must be a string or Array.');\n }\n if (!isNumber(durationOption) && !isString(durationOption)) {\n console.error(`MUI: Argument \"duration\" must be a number or a string but found ${durationOption}.`);\n }\n if (!isString(easingOption)) {\n console.error('MUI: Argument \"easing\" must be a string.');\n }\n if (!isNumber(delay) && !isString(delay)) {\n console.error('MUI: Argument \"delay\" must be a number or a string.');\n }\n if (typeof options !== 'object') {\n console.error(['MUI: Secong argument of transition.create must be an object.', \"Arguments should be either `create('prop1', options)` or `create(['prop1', 'prop2'], options)`\"].join('\\n'));\n }\n if (Object.keys(other).length !== 0) {\n console.error(`MUI: Unrecognized argument(s) [${Object.keys(other).join(',')}].`);\n }\n }\n return (Array.isArray(props) ? props : [props]).map(animatedProp => `${animatedProp} ${typeof durationOption === 'string' ? durationOption : formatMs(durationOption)} ${easingOption} ${typeof delay === 'string' ? delay : formatMs(delay)}`).join(',');\n };\n return _extends({\n getAutoHeightDuration,\n create\n }, inputTransitions, {\n easing: mergedEasing,\n duration: mergedDuration\n });\n}","// We need to centralize the zIndex definitions as they work\n// like global values in the browser.\nconst zIndex = {\n mobileStepper: 1000,\n fab: 1050,\n speedDial: 1050,\n appBar: 1100,\n drawer: 1200,\n modal: 1300,\n snackbar: 1400,\n tooltip: 1500\n};\nexport default zIndex;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\nconst _excluded = [\"breakpoints\", \"mixins\", \"spacing\", \"palette\", \"transitions\", \"typography\", \"shape\"];\nimport { deepmerge } from '@mui/utils';\nimport { createTheme as systemCreateTheme, unstable_defaultSxConfig as defaultSxConfig, unstable_styleFunctionSx as styleFunctionSx } from '@mui/system';\nimport generateUtilityClass from '@mui/utils/generateUtilityClass';\nimport createMixins from './createMixins';\nimport createPalette from './createPalette';\nimport createTypography from './createTypography';\nimport shadows from './shadows';\nimport createTransitions from './createTransitions';\nimport zIndex from './zIndex';\nfunction createTheme(options = {}, ...args) {\n const {\n mixins: mixinsInput = {},\n palette: paletteInput = {},\n transitions: transitionsInput = {},\n typography: typographyInput = {}\n } = options,\n other = _objectWithoutPropertiesLoose(options, _excluded);\n if (options.vars) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: \\`vars\\` is a private field used for CSS variables support.\nPlease use another name.` : _formatMuiErrorMessage(18));\n }\n const palette = createPalette(paletteInput);\n const systemTheme = systemCreateTheme(options);\n let muiTheme = deepmerge(systemTheme, {\n mixins: createMixins(systemTheme.breakpoints, mixinsInput),\n palette,\n // Don't use [...shadows] until you've verified its transpiled code is not invoking the iterator protocol.\n shadows: shadows.slice(),\n typography: createTypography(palette, typographyInput),\n transitions: createTransitions(transitionsInput),\n zIndex: _extends({}, zIndex)\n });\n muiTheme = deepmerge(muiTheme, other);\n muiTheme = args.reduce((acc, argument) => deepmerge(acc, argument), muiTheme);\n if (process.env.NODE_ENV !== 'production') {\n // TODO v6: Refactor to use globalStateClassesMapping from @mui/utils once `readOnly` state class is used in Rating component.\n const stateClasses = ['active', 'checked', 'completed', 'disabled', 'error', 'expanded', 'focused', 'focusVisible', 'required', 'selected'];\n const traverse = (node, component) => {\n let key;\n\n // eslint-disable-next-line guard-for-in, no-restricted-syntax\n for (key in node) {\n const child = node[key];\n if (stateClasses.indexOf(key) !== -1 && Object.keys(child).length > 0) {\n if (process.env.NODE_ENV !== 'production') {\n const stateClass = generateUtilityClass('', key);\n console.error([`MUI: The \\`${component}\\` component increases ` + `the CSS specificity of the \\`${key}\\` internal state.`, 'You can not override it like this: ', JSON.stringify(node, null, 2), '', `Instead, you need to use the '&.${stateClass}' syntax:`, JSON.stringify({\n root: {\n [`&.${stateClass}`]: child\n }\n }, null, 2), '', 'https://mui.com/r/state-classes-guide'].join('\\n'));\n }\n // Remove the style to prevent global conflicts.\n node[key] = {};\n }\n }\n };\n Object.keys(muiTheme.components).forEach(component => {\n const styleOverrides = muiTheme.components[component].styleOverrides;\n if (styleOverrides && component.indexOf('Mui') === 0) {\n traverse(styleOverrides, component);\n }\n });\n }\n muiTheme.unstable_sxConfig = _extends({}, defaultSxConfig, other == null ? void 0 : other.unstable_sxConfig);\n muiTheme.unstable_sx = function sx(props) {\n return styleFunctionSx({\n sx: props,\n theme: this\n });\n };\n return muiTheme;\n}\nlet warnedOnce = false;\nexport function createMuiTheme(...args) {\n if (process.env.NODE_ENV !== 'production') {\n if (!warnedOnce) {\n warnedOnce = true;\n console.error(['MUI: the createMuiTheme function was renamed to createTheme.', '', \"You should use `import { createTheme } from '@mui/material/styles'`\"].join('\\n'));\n }\n }\n return createTheme(...args);\n}\nexport default createTheme;","'use client';\n\nimport createTheme from './createTheme';\nconst defaultTheme = createTheme();\nexport default defaultTheme;","export default '$$material';","'use client';\n\nimport { useThemeProps as systemUseThemeProps } from '@mui/system';\nimport defaultTheme from './defaultTheme';\nimport THEME_ID from './identifier';\nexport default function useThemeProps({\n props,\n name\n}) {\n return systemUseThemeProps({\n props,\n name,\n defaultTheme,\n themeId: THEME_ID\n });\n}","'use client';\n\nimport { createStyled, shouldForwardProp } from '@mui/system';\nimport defaultTheme from './defaultTheme';\nimport THEME_ID from './identifier';\nexport const rootShouldForwardProp = prop => shouldForwardProp(prop) && prop !== 'classes';\nexport const slotShouldForwardProp = shouldForwardProp;\nconst styled = createStyled({\n themeId: THEME_ID,\n defaultTheme,\n rootShouldForwardProp\n});\nexport default styled;","import generateUtilityClasses from '@mui/utils/generateUtilityClasses';\nimport generateUtilityClass from '@mui/utils/generateUtilityClass';\nexport function getSvgIconUtilityClass(slot) {\n return generateUtilityClass('MuiSvgIcon', slot);\n}\nconst svgIconClasses = generateUtilityClasses('MuiSvgIcon', ['root', 'colorPrimary', 'colorSecondary', 'colorAction', 'colorError', 'colorDisabled', 'fontSizeInherit', 'fontSizeSmall', 'fontSizeMedium', 'fontSizeLarge']);\nexport default svgIconClasses;","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"children\", \"className\", \"color\", \"component\", \"fontSize\", \"htmlColor\", \"inheritViewBox\", \"titleAccess\", \"viewBox\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport clsx from 'clsx';\nimport { unstable_composeClasses as composeClasses } from '@mui/base/composeClasses';\nimport capitalize from '../utils/capitalize';\nimport useThemeProps from '../styles/useThemeProps';\nimport styled from '../styles/styled';\nimport { getSvgIconUtilityClass } from './svgIconClasses';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nimport { jsxs as _jsxs } from \"react/jsx-runtime\";\nconst useUtilityClasses = ownerState => {\n const {\n color,\n fontSize,\n classes\n } = ownerState;\n const slots = {\n root: ['root', color !== 'inherit' && `color${capitalize(color)}`, `fontSize${capitalize(fontSize)}`]\n };\n return composeClasses(slots, getSvgIconUtilityClass, classes);\n};\nconst SvgIconRoot = styled('svg', {\n name: 'MuiSvgIcon',\n slot: 'Root',\n overridesResolver: (props, styles) => {\n const {\n ownerState\n } = props;\n return [styles.root, ownerState.color !== 'inherit' && styles[`color${capitalize(ownerState.color)}`], styles[`fontSize${capitalize(ownerState.fontSize)}`]];\n }\n})(({\n theme,\n ownerState\n}) => {\n var _theme$transitions, _theme$transitions$cr, _theme$transitions2, _theme$typography, _theme$typography$pxT, _theme$typography2, _theme$typography2$px, _theme$typography3, _theme$typography3$px, _palette$ownerState$c, _palette, _palette2, _palette3;\n return {\n userSelect: 'none',\n width: '1em',\n height: '1em',\n display: 'inline-block',\n // the will define the property that has `currentColor`\n // e.g. heroicons uses fill=\"none\" and stroke=\"currentColor\"\n fill: ownerState.hasSvgAsChild ? undefined : 'currentColor',\n flexShrink: 0,\n transition: (_theme$transitions = theme.transitions) == null || (_theme$transitions$cr = _theme$transitions.create) == null ? void 0 : _theme$transitions$cr.call(_theme$transitions, 'fill', {\n duration: (_theme$transitions2 = theme.transitions) == null || (_theme$transitions2 = _theme$transitions2.duration) == null ? void 0 : _theme$transitions2.shorter\n }),\n fontSize: {\n inherit: 'inherit',\n small: ((_theme$typography = theme.typography) == null || (_theme$typography$pxT = _theme$typography.pxToRem) == null ? void 0 : _theme$typography$pxT.call(_theme$typography, 20)) || '1.25rem',\n medium: ((_theme$typography2 = theme.typography) == null || (_theme$typography2$px = _theme$typography2.pxToRem) == null ? void 0 : _theme$typography2$px.call(_theme$typography2, 24)) || '1.5rem',\n large: ((_theme$typography3 = theme.typography) == null || (_theme$typography3$px = _theme$typography3.pxToRem) == null ? void 0 : _theme$typography3$px.call(_theme$typography3, 35)) || '2.1875rem'\n }[ownerState.fontSize],\n // TODO v5 deprecate, v6 remove for sx\n color: (_palette$ownerState$c = (_palette = (theme.vars || theme).palette) == null || (_palette = _palette[ownerState.color]) == null ? void 0 : _palette.main) != null ? _palette$ownerState$c : {\n action: (_palette2 = (theme.vars || theme).palette) == null || (_palette2 = _palette2.action) == null ? void 0 : _palette2.active,\n disabled: (_palette3 = (theme.vars || theme).palette) == null || (_palette3 = _palette3.action) == null ? void 0 : _palette3.disabled,\n inherit: undefined\n }[ownerState.color]\n };\n});\nconst SvgIcon = /*#__PURE__*/React.forwardRef(function SvgIcon(inProps, ref) {\n const props = useThemeProps({\n props: inProps,\n name: 'MuiSvgIcon'\n });\n const {\n children,\n className,\n color = 'inherit',\n component = 'svg',\n fontSize = 'medium',\n htmlColor,\n inheritViewBox = false,\n titleAccess,\n viewBox = '0 0 24 24'\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const hasSvgAsChild = /*#__PURE__*/React.isValidElement(children) && children.type === 'svg';\n const ownerState = _extends({}, props, {\n color,\n component,\n fontSize,\n instanceFontSize: inProps.fontSize,\n inheritViewBox,\n viewBox,\n hasSvgAsChild\n });\n const more = {};\n if (!inheritViewBox) {\n more.viewBox = viewBox;\n }\n const classes = useUtilityClasses(ownerState);\n return /*#__PURE__*/_jsxs(SvgIconRoot, _extends({\n as: component,\n className: clsx(classes.root, className),\n focusable: \"false\",\n color: htmlColor,\n \"aria-hidden\": titleAccess ? undefined : true,\n role: titleAccess ? 'img' : undefined,\n ref: ref\n }, more, other, hasSvgAsChild && children.props, {\n ownerState: ownerState,\n children: [hasSvgAsChild ? children.props.children : children, titleAccess ? /*#__PURE__*/_jsx(\"title\", {\n children: titleAccess\n }) : null]\n }));\n});\nprocess.env.NODE_ENV !== \"production\" ? SvgIcon.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the d.ts file and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * Node passed into the SVG element.\n */\n children: PropTypes.node,\n /**\n * Override or extend the styles applied to the component.\n */\n classes: PropTypes.object,\n /**\n * @ignore\n */\n className: PropTypes.string,\n /**\n * The color of the component.\n * It supports both default and custom theme colors, which can be added as shown in the\n * [palette customization guide](https://mui.com/material-ui/customization/palette/#custom-colors).\n * You can use the `htmlColor` prop to apply a color attribute to the SVG element.\n * @default 'inherit'\n */\n color: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.oneOf(['inherit', 'action', 'disabled', 'primary', 'secondary', 'error', 'info', 'success', 'warning']), PropTypes.string]),\n /**\n * The component used for the root node.\n * Either a string to use a HTML element or a component.\n */\n component: PropTypes.elementType,\n /**\n * The fontSize applied to the icon. Defaults to 24px, but can be configure to inherit font size.\n * @default 'medium'\n */\n fontSize: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.oneOf(['inherit', 'large', 'medium', 'small']), PropTypes.string]),\n /**\n * Applies a color attribute to the SVG element.\n */\n htmlColor: PropTypes.string,\n /**\n * If `true`, the root node will inherit the custom `component`'s viewBox and the `viewBox`\n * prop will be ignored.\n * Useful when you want to reference a custom `component` and have `SvgIcon` pass that\n * `component`'s viewBox to the root node.\n * @default false\n */\n inheritViewBox: PropTypes.bool,\n /**\n * The shape-rendering attribute. The behavior of the different options is described on the\n * [MDN Web Docs](https://developer.mozilla.org/en-US/docs/Web/SVG/Attribute/shape-rendering).\n * If you are having issues with blurry icons you should investigate this prop.\n */\n shapeRendering: PropTypes.string,\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Provides a human-readable title for the element that contains it.\n * https://www.w3.org/TR/SVG-access/#Equivalent\n */\n titleAccess: PropTypes.string,\n /**\n * Allows you to redefine what the coordinates without units mean inside an SVG element.\n * For example, if the SVG element is 500 (width) by 200 (height),\n * and you pass viewBox=\"0 0 50 20\",\n * this means that the coordinates inside the SVG will go from the top left corner (0,0)\n * to bottom right (50,20) and each unit will be worth 10px.\n * @default '0 0 24 24'\n */\n viewBox: PropTypes.string\n} : void 0;\nSvgIcon.muiName = 'SvgIcon';\nexport default SvgIcon;","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport * as React from 'react';\nimport SvgIcon from '../SvgIcon';\n\n/**\n * Private module reserved for @mui packages.\n */\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nexport default function createSvgIcon(path, displayName) {\n function Component(props, ref) {\n return /*#__PURE__*/_jsx(SvgIcon, _extends({\n \"data-testid\": `${displayName}Icon`,\n ref: ref\n }, props, {\n children: path\n }));\n }\n if (process.env.NODE_ENV !== 'production') {\n // Need to set `displayName` on the inner component for React.memo.\n // React prior to 16.14 ignores `displayName` on the wrapper.\n Component.displayName = `${displayName}Icon`;\n }\n Component.muiName = SvgIcon.muiName;\n return /*#__PURE__*/React.memo( /*#__PURE__*/React.forwardRef(Component));\n}","'use client';\n\nimport { unstable_ClassNameGenerator as ClassNameGenerator } from '@mui/base/ClassNameGenerator';\nexport { default as capitalize } from './capitalize';\nexport { default as createChainedFunction } from './createChainedFunction';\nexport { default as createSvgIcon } from './createSvgIcon';\nexport { default as debounce } from './debounce';\nexport { default as deprecatedPropType } from './deprecatedPropType';\nexport { default as isMuiElement } from './isMuiElement';\nexport { default as ownerDocument } from './ownerDocument';\nexport { default as ownerWindow } from './ownerWindow';\nexport { default as requirePropFactory } from './requirePropFactory';\nexport { default as setRef } from './setRef';\nexport { default as unstable_useEnhancedEffect } from './useEnhancedEffect';\nexport { default as unstable_useId } from './useId';\nexport { default as unsupportedProp } from './unsupportedProp';\nexport { default as useControlled } from './useControlled';\nexport { default as useEventCallback } from './useEventCallback';\nexport { default as useForkRef } from './useForkRef';\nexport { default as useIsFocusVisible } from './useIsFocusVisible';\n// TODO: remove this export once ClassNameGenerator is stable\n// eslint-disable-next-line @typescript-eslint/naming-convention\nexport const unstable_ClassNameGenerator = {\n configure: generator => {\n if (process.env.NODE_ENV !== 'production') {\n console.warn(['MUI: `ClassNameGenerator` import from `@mui/material/utils` is outdated and might cause unexpected issues.', '', \"You should use `import { unstable_ClassNameGenerator } from '@mui/material/className'` instead\", '', 'The detail of the issue: https://github.com/mui/material-ui/issues/30011#issuecomment-1024993401', '', 'The updated documentation: https://mui.com/guides/classname-generator/'].join('\\n'));\n }\n ClassNameGenerator.configure(generator);\n }\n};","\"use strict\";\n'use client';\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nObject.defineProperty(exports, \"default\", {\n enumerable: true,\n get: function () {\n return _utils.createSvgIcon;\n }\n});\nvar _utils = require(\"@mui/material/utils\");","\"use strict\";\n\"use client\";\n\nvar _interopRequireDefault = require(\"@babel/runtime/helpers/interopRequireDefault\");\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = void 0;\nvar _createSvgIcon = _interopRequireDefault(require(\"./utils/createSvgIcon\"));\nvar _jsxRuntime = require(\"react/jsx-runtime\");\nvar _default = exports.default = (0, _createSvgIcon.default)( /*#__PURE__*/(0, _jsxRuntime.jsx)(\"path\", {\n d: \"m10 17 5-5-5-5z\"\n}), 'ArrowRight');","/**\n * Determines if a given element is a DOM element name (i.e. not a React component).\n */\nexport function isHostComponent(element) {\n return typeof element === 'string';\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport { isHostComponent } from './isHostComponent';\n\n/**\n * Type of the ownerState based on the type of an element it applies to.\n * This resolves to the provided OwnerState for React components and `undefined` for host components.\n * Falls back to `OwnerState | undefined` when the exact type can't be determined in development time.\n */\n\n/**\n * Appends the ownerState object to the props, merging with the existing one if necessary.\n *\n * @param elementType Type of the element that owns the `existingProps`. If the element is a DOM node or undefined, `ownerState` is not applied.\n * @param otherProps Props of the element.\n * @param ownerState\n */\nexport function appendOwnerState(elementType, otherProps, ownerState) {\n if (elementType === undefined || isHostComponent(elementType)) {\n return otherProps;\n }\n return _extends({}, otherProps, {\n ownerState: _extends({}, otherProps.ownerState, ownerState)\n });\n}","'use client';\n\nimport * as React from 'react';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nconst defaultContextValue = {\n disableDefaultClasses: false\n};\nconst ClassNameConfiguratorContext = /*#__PURE__*/React.createContext(defaultContextValue);\n/**\n * @ignore - internal hook.\n *\n * Wraps the `generateUtilityClass` function and controls how the classes are generated.\n * Currently it only affects whether the classes are applied or not.\n *\n * @returns Function to be called with the `generateUtilityClass` function specific to a component to generate the classes.\n */\nexport function useClassNamesOverride(generateUtilityClass) {\n const {\n disableDefaultClasses\n } = React.useContext(ClassNameConfiguratorContext);\n return slot => {\n if (disableDefaultClasses) {\n return '';\n }\n return generateUtilityClass(slot);\n };\n}\n\n/**\n * Allows to configure the components within to not apply any built-in classes.\n */\nexport function ClassNameConfigurator(props) {\n const {\n disableDefaultClasses,\n children\n } = props;\n const contextValue = React.useMemo(() => ({\n disableDefaultClasses: disableDefaultClasses != null ? disableDefaultClasses : false\n }), [disableDefaultClasses]);\n return /*#__PURE__*/_jsx(ClassNameConfiguratorContext.Provider, {\n value: contextValue,\n children: children\n });\n}","/**\n * Extracts event handlers from a given object.\n * A prop is considered an event handler if it is a function and its name starts with `on`.\n *\n * @param object An object to extract event handlers from.\n * @param excludeKeys An array of keys to exclude from the returned object.\n */\nexport function extractEventHandlers(object, excludeKeys = []) {\n if (object === undefined) {\n return {};\n }\n const result = {};\n Object.keys(object).filter(prop => prop.match(/^on[A-Z]/) && typeof object[prop] === 'function' && !excludeKeys.includes(prop)).forEach(prop => {\n result[prop] = object[prop];\n });\n return result;\n}","/**\n * If `componentProps` is a function, calls it with the provided `ownerState`.\n * Otherwise, just returns `componentProps`.\n */\nexport function resolveComponentProps(componentProps, ownerState, slotState) {\n if (typeof componentProps === 'function') {\n return componentProps(ownerState, slotState);\n }\n return componentProps;\n}","/**\n * Removes event handlers from the given object.\n * A field is considered an event handler if it is a function with a name beginning with `on`.\n *\n * @param object Object to remove event handlers from.\n * @returns Object with event handlers removed.\n */\nexport function omitEventHandlers(object) {\n if (object === undefined) {\n return {};\n }\n const result = {};\n Object.keys(object).filter(prop => !(prop.match(/^on[A-Z]/) && typeof object[prop] === 'function')).forEach(prop => {\n result[prop] = object[prop];\n });\n return result;\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport clsx from 'clsx';\nimport { extractEventHandlers } from './extractEventHandlers';\nimport { omitEventHandlers } from './omitEventHandlers';\n/**\n * Merges the slot component internal props (usually coming from a hook)\n * with the externally provided ones.\n *\n * The merge order is (the latter overrides the former):\n * 1. The internal props (specified as a getter function to work with get*Props hook result)\n * 2. Additional props (specified internally on a Base UI component)\n * 3. External props specified on the owner component. These should only be used on a root slot.\n * 4. External props specified in the `slotProps.*` prop.\n * 5. The `className` prop - combined from all the above.\n * @param parameters\n * @returns\n */\nexport function mergeSlotProps(parameters) {\n const {\n getSlotProps,\n additionalProps,\n externalSlotProps,\n externalForwardedProps,\n className\n } = parameters;\n if (!getSlotProps) {\n // The simpler case - getSlotProps is not defined, so no internal event handlers are defined,\n // so we can simply merge all the props without having to worry about extracting event handlers.\n const joinedClasses = clsx(additionalProps == null ? void 0 : additionalProps.className, className, externalForwardedProps == null ? void 0 : externalForwardedProps.className, externalSlotProps == null ? void 0 : externalSlotProps.className);\n const mergedStyle = _extends({}, additionalProps == null ? void 0 : additionalProps.style, externalForwardedProps == null ? void 0 : externalForwardedProps.style, externalSlotProps == null ? void 0 : externalSlotProps.style);\n const props = _extends({}, additionalProps, externalForwardedProps, externalSlotProps);\n if (joinedClasses.length > 0) {\n props.className = joinedClasses;\n }\n if (Object.keys(mergedStyle).length > 0) {\n props.style = mergedStyle;\n }\n return {\n props,\n internalRef: undefined\n };\n }\n\n // In this case, getSlotProps is responsible for calling the external event handlers.\n // We don't need to include them in the merged props because of this.\n\n const eventHandlers = extractEventHandlers(_extends({}, externalForwardedProps, externalSlotProps));\n const componentsPropsWithoutEventHandlers = omitEventHandlers(externalSlotProps);\n const otherPropsWithoutEventHandlers = omitEventHandlers(externalForwardedProps);\n const internalSlotProps = getSlotProps(eventHandlers);\n\n // The order of classes is important here.\n // Emotion (that we use in libraries consuming Base UI) depends on this order\n // to properly override style. It requires the most important classes to be last\n // (see https://github.com/mui/material-ui/pull/33205) for the related discussion.\n const joinedClasses = clsx(internalSlotProps == null ? void 0 : internalSlotProps.className, additionalProps == null ? void 0 : additionalProps.className, className, externalForwardedProps == null ? void 0 : externalForwardedProps.className, externalSlotProps == null ? void 0 : externalSlotProps.className);\n const mergedStyle = _extends({}, internalSlotProps == null ? void 0 : internalSlotProps.style, additionalProps == null ? void 0 : additionalProps.style, externalForwardedProps == null ? void 0 : externalForwardedProps.style, externalSlotProps == null ? void 0 : externalSlotProps.style);\n const props = _extends({}, internalSlotProps, additionalProps, otherPropsWithoutEventHandlers, componentsPropsWithoutEventHandlers);\n if (joinedClasses.length > 0) {\n props.className = joinedClasses;\n }\n if (Object.keys(mergedStyle).length > 0) {\n props.style = mergedStyle;\n }\n return {\n props,\n internalRef: internalSlotProps.ref\n };\n}","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"elementType\", \"externalSlotProps\", \"ownerState\", \"skipResolvingSlotProps\"];\nimport { unstable_useForkRef as useForkRef } from '@mui/utils';\nimport { appendOwnerState } from './appendOwnerState';\nimport { mergeSlotProps } from './mergeSlotProps';\nimport { resolveComponentProps } from './resolveComponentProps';\n/**\n * @ignore - do not document.\n * Builds the props to be passed into the slot of an unstyled component.\n * It merges the internal props of the component with the ones supplied by the user, allowing to customize the behavior.\n * If the slot component is not a host component, it also merges in the `ownerState`.\n *\n * @param parameters.getSlotProps - A function that returns the props to be passed to the slot component.\n */\nexport function useSlotProps(parameters) {\n var _parameters$additiona;\n const {\n elementType,\n externalSlotProps,\n ownerState,\n skipResolvingSlotProps = false\n } = parameters,\n rest = _objectWithoutPropertiesLoose(parameters, _excluded);\n const resolvedComponentsProps = skipResolvingSlotProps ? {} : resolveComponentProps(externalSlotProps, ownerState);\n const {\n props: mergedProps,\n internalRef\n } = mergeSlotProps(_extends({}, rest, {\n externalSlotProps: resolvedComponentsProps\n }));\n const ref = useForkRef(internalRef, resolvedComponentsProps == null ? void 0 : resolvedComponentsProps.ref, (_parameters$additiona = parameters.additionalProps) == null ? void 0 : _parameters$additiona.ref);\n const props = appendOwnerState(elementType, _extends({}, mergedProps, {\n ref\n }), ownerState);\n return props;\n}","import { globalStateClasses } from '@mui/utils/generateUtilityClass';\nconst GLOBAL_CLASS_PREFIX = 'base';\nfunction buildStateClass(state) {\n return `${GLOBAL_CLASS_PREFIX}--${state}`;\n}\nfunction buildSlotClass(componentName, slot) {\n return `${GLOBAL_CLASS_PREFIX}-${componentName}-${slot}`;\n}\nexport function generateUtilityClass(componentName, slot) {\n const globalStateClass = globalStateClasses[slot];\n return globalStateClass ? buildStateClass(globalStateClass) : buildSlotClass(componentName, slot);\n}\nexport function isGlobalState(slot) {\n return globalStateClasses[slot] !== undefined;\n}","import { generateUtilityClass } from '../generateUtilityClass';\nexport function generateUtilityClasses(componentName, slots) {\n const result = {};\n slots.forEach(slot => {\n result[slot] = generateUtilityClass(componentName, slot);\n });\n return result;\n}","'use client';\n\nimport * as React from 'react';\nimport * as ReactDOM from 'react-dom';\nimport PropTypes from 'prop-types';\nimport { exactProp, HTMLElementType, unstable_useEnhancedEffect as useEnhancedEffect, unstable_useForkRef as useForkRef, unstable_setRef as setRef } from '@mui/utils';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nfunction getContainer(container) {\n return typeof container === 'function' ? container() : container;\n}\n\n/**\n * Portals provide a first-class way to render children into a DOM node\n * that exists outside the DOM hierarchy of the parent component.\n *\n * Demos:\n *\n * - [Portal](https://mui.com/base-ui/react-portal/)\n *\n * API:\n *\n * - [Portal API](https://mui.com/base-ui/react-portal/components-api/#portal)\n */\nconst Portal = /*#__PURE__*/React.forwardRef(function Portal(props, forwardedRef) {\n const {\n children,\n container,\n disablePortal = false\n } = props;\n const [mountNode, setMountNode] = React.useState(null);\n // @ts-expect-error TODO upstream fix\n const handleRef = useForkRef( /*#__PURE__*/React.isValidElement(children) ? children.ref : null, forwardedRef);\n useEnhancedEffect(() => {\n if (!disablePortal) {\n setMountNode(getContainer(container) || document.body);\n }\n }, [container, disablePortal]);\n useEnhancedEffect(() => {\n if (mountNode && !disablePortal) {\n setRef(forwardedRef, mountNode);\n return () => {\n setRef(forwardedRef, null);\n };\n }\n return undefined;\n }, [forwardedRef, mountNode, disablePortal]);\n if (disablePortal) {\n if ( /*#__PURE__*/React.isValidElement(children)) {\n const newProps = {\n ref: handleRef\n };\n return /*#__PURE__*/React.cloneElement(children, newProps);\n }\n return /*#__PURE__*/_jsx(React.Fragment, {\n children: children\n });\n }\n return /*#__PURE__*/_jsx(React.Fragment, {\n children: mountNode ? /*#__PURE__*/ReactDOM.createPortal(children, mountNode) : mountNode\n });\n});\nprocess.env.NODE_ENV !== \"production\" ? Portal.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * The children to render into the `container`.\n */\n children: PropTypes.node,\n /**\n * An HTML element or function that returns one.\n * The `container` will have the portal children appended to it.\n *\n * You can also provide a callback, which is called in a React layout effect.\n * This lets you set the container from a ref, and also makes server-side rendering possible.\n *\n * By default, it uses the body of the top-level document object,\n * so it's simply `document.body` most of the time.\n */\n container: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.func]),\n /**\n * The `children` will be under the DOM hierarchy of the parent component.\n * @default false\n */\n disablePortal: PropTypes.bool\n} : void 0;\nif (process.env.NODE_ENV !== 'production') {\n // eslint-disable-next-line\n Portal['propTypes' + ''] = exactProp(Portal.propTypes);\n}\nexport { Portal };","export var top = 'top';\nexport var bottom = 'bottom';\nexport var right = 'right';\nexport var left = 'left';\nexport var auto = 'auto';\nexport var basePlacements = [top, bottom, right, left];\nexport var start = 'start';\nexport var end = 'end';\nexport var clippingParents = 'clippingParents';\nexport var viewport = 'viewport';\nexport var popper = 'popper';\nexport var reference = 'reference';\nexport var variationPlacements = /*#__PURE__*/basePlacements.reduce(function (acc, placement) {\n return acc.concat([placement + \"-\" + start, placement + \"-\" + end]);\n}, []);\nexport var placements = /*#__PURE__*/[].concat(basePlacements, [auto]).reduce(function (acc, placement) {\n return acc.concat([placement, placement + \"-\" + start, placement + \"-\" + end]);\n}, []); // modifiers that need to read the DOM\n\nexport var beforeRead = 'beforeRead';\nexport var read = 'read';\nexport var afterRead = 'afterRead'; // pure-logic modifiers\n\nexport var beforeMain = 'beforeMain';\nexport var main = 'main';\nexport var afterMain = 'afterMain'; // modifier with the purpose to write to the DOM (or write into a framework state)\n\nexport var beforeWrite = 'beforeWrite';\nexport var write = 'write';\nexport var afterWrite = 'afterWrite';\nexport var modifierPhases = [beforeRead, read, afterRead, beforeMain, main, afterMain, beforeWrite, write, afterWrite];","export default function getNodeName(element) {\n return element ? (element.nodeName || '').toLowerCase() : null;\n}","export default function getWindow(node) {\n if (node == null) {\n return window;\n }\n\n if (node.toString() !== '[object Window]') {\n var ownerDocument = node.ownerDocument;\n return ownerDocument ? ownerDocument.defaultView || window : window;\n }\n\n return node;\n}","import getWindow from \"./getWindow.js\";\n\nfunction isElement(node) {\n var OwnElement = getWindow(node).Element;\n return node instanceof OwnElement || node instanceof Element;\n}\n\nfunction isHTMLElement(node) {\n var OwnElement = getWindow(node).HTMLElement;\n return node instanceof OwnElement || node instanceof HTMLElement;\n}\n\nfunction isShadowRoot(node) {\n // IE 11 has no ShadowRoot\n if (typeof ShadowRoot === 'undefined') {\n return false;\n }\n\n var OwnElement = getWindow(node).ShadowRoot;\n return node instanceof OwnElement || node instanceof ShadowRoot;\n}\n\nexport { isElement, isHTMLElement, isShadowRoot };","import getNodeName from \"../dom-utils/getNodeName.js\";\nimport { isHTMLElement } from \"../dom-utils/instanceOf.js\"; // This modifier takes the styles prepared by the `computeStyles` modifier\n// and applies them to the HTMLElements such as popper and arrow\n\nfunction applyStyles(_ref) {\n var state = _ref.state;\n Object.keys(state.elements).forEach(function (name) {\n var style = state.styles[name] || {};\n var attributes = state.attributes[name] || {};\n var element = state.elements[name]; // arrow is optional + virtual elements\n\n if (!isHTMLElement(element) || !getNodeName(element)) {\n return;\n } // Flow doesn't support to extend this property, but it's the most\n // effective way to apply styles to an HTMLElement\n // $FlowFixMe[cannot-write]\n\n\n Object.assign(element.style, style);\n Object.keys(attributes).forEach(function (name) {\n var value = attributes[name];\n\n if (value === false) {\n element.removeAttribute(name);\n } else {\n element.setAttribute(name, value === true ? '' : value);\n }\n });\n });\n}\n\nfunction effect(_ref2) {\n var state = _ref2.state;\n var initialStyles = {\n popper: {\n position: state.options.strategy,\n left: '0',\n top: '0',\n margin: '0'\n },\n arrow: {\n position: 'absolute'\n },\n reference: {}\n };\n Object.assign(state.elements.popper.style, initialStyles.popper);\n state.styles = initialStyles;\n\n if (state.elements.arrow) {\n Object.assign(state.elements.arrow.style, initialStyles.arrow);\n }\n\n return function () {\n Object.keys(state.elements).forEach(function (name) {\n var element = state.elements[name];\n var attributes = state.attributes[name] || {};\n var styleProperties = Object.keys(state.styles.hasOwnProperty(name) ? state.styles[name] : initialStyles[name]); // Set all values to an empty string to unset them\n\n var style = styleProperties.reduce(function (style, property) {\n style[property] = '';\n return style;\n }, {}); // arrow is optional + virtual elements\n\n if (!isHTMLElement(element) || !getNodeName(element)) {\n return;\n }\n\n Object.assign(element.style, style);\n Object.keys(attributes).forEach(function (attribute) {\n element.removeAttribute(attribute);\n });\n });\n };\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'applyStyles',\n enabled: true,\n phase: 'write',\n fn: applyStyles,\n effect: effect,\n requires: ['computeStyles']\n};","import { auto } from \"../enums.js\";\nexport default function getBasePlacement(placement) {\n return placement.split('-')[0];\n}","export var max = Math.max;\nexport var min = Math.min;\nexport var round = Math.round;","export default function getUAString() {\n var uaData = navigator.userAgentData;\n\n if (uaData != null && uaData.brands && Array.isArray(uaData.brands)) {\n return uaData.brands.map(function (item) {\n return item.brand + \"/\" + item.version;\n }).join(' ');\n }\n\n return navigator.userAgent;\n}","import getUAString from \"../utils/userAgent.js\";\nexport default function isLayoutViewport() {\n return !/^((?!chrome|android).)*safari/i.test(getUAString());\n}","import { isElement, isHTMLElement } from \"./instanceOf.js\";\nimport { round } from \"../utils/math.js\";\nimport getWindow from \"./getWindow.js\";\nimport isLayoutViewport from \"./isLayoutViewport.js\";\nexport default function getBoundingClientRect(element, includeScale, isFixedStrategy) {\n if (includeScale === void 0) {\n includeScale = false;\n }\n\n if (isFixedStrategy === void 0) {\n isFixedStrategy = false;\n }\n\n var clientRect = element.getBoundingClientRect();\n var scaleX = 1;\n var scaleY = 1;\n\n if (includeScale && isHTMLElement(element)) {\n scaleX = element.offsetWidth > 0 ? round(clientRect.width) / element.offsetWidth || 1 : 1;\n scaleY = element.offsetHeight > 0 ? round(clientRect.height) / element.offsetHeight || 1 : 1;\n }\n\n var _ref = isElement(element) ? getWindow(element) : window,\n visualViewport = _ref.visualViewport;\n\n var addVisualOffsets = !isLayoutViewport() && isFixedStrategy;\n var x = (clientRect.left + (addVisualOffsets && visualViewport ? visualViewport.offsetLeft : 0)) / scaleX;\n var y = (clientRect.top + (addVisualOffsets && visualViewport ? visualViewport.offsetTop : 0)) / scaleY;\n var width = clientRect.width / scaleX;\n var height = clientRect.height / scaleY;\n return {\n width: width,\n height: height,\n top: y,\n right: x + width,\n bottom: y + height,\n left: x,\n x: x,\n y: y\n };\n}","import getBoundingClientRect from \"./getBoundingClientRect.js\"; // Returns the layout rect of an element relative to its offsetParent. Layout\n// means it doesn't take into account transforms.\n\nexport default function getLayoutRect(element) {\n var clientRect = getBoundingClientRect(element); // Use the clientRect sizes if it's not been transformed.\n // Fixes https://github.com/popperjs/popper-core/issues/1223\n\n var width = element.offsetWidth;\n var height = element.offsetHeight;\n\n if (Math.abs(clientRect.width - width) <= 1) {\n width = clientRect.width;\n }\n\n if (Math.abs(clientRect.height - height) <= 1) {\n height = clientRect.height;\n }\n\n return {\n x: element.offsetLeft,\n y: element.offsetTop,\n width: width,\n height: height\n };\n}","import { isShadowRoot } from \"./instanceOf.js\";\nexport default function contains(parent, child) {\n var rootNode = child.getRootNode && child.getRootNode(); // First, attempt with faster native method\n\n if (parent.contains(child)) {\n return true;\n } // then fallback to custom implementation with Shadow DOM support\n else if (rootNode && isShadowRoot(rootNode)) {\n var next = child;\n\n do {\n if (next && parent.isSameNode(next)) {\n return true;\n } // $FlowFixMe[prop-missing]: need a better way to handle this...\n\n\n next = next.parentNode || next.host;\n } while (next);\n } // Give up, the result is false\n\n\n return false;\n}","import getWindow from \"./getWindow.js\";\nexport default function getComputedStyle(element) {\n return getWindow(element).getComputedStyle(element);\n}","import getNodeName from \"./getNodeName.js\";\nexport default function isTableElement(element) {\n return ['table', 'td', 'th'].indexOf(getNodeName(element)) >= 0;\n}","import { isElement } from \"./instanceOf.js\";\nexport default function getDocumentElement(element) {\n // $FlowFixMe[incompatible-return]: assume body is always available\n return ((isElement(element) ? element.ownerDocument : // $FlowFixMe[prop-missing]\n element.document) || window.document).documentElement;\n}","import getNodeName from \"./getNodeName.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport { isShadowRoot } from \"./instanceOf.js\";\nexport default function getParentNode(element) {\n if (getNodeName(element) === 'html') {\n return element;\n }\n\n return (// this is a quicker (but less type safe) way to save quite some bytes from the bundle\n // $FlowFixMe[incompatible-return]\n // $FlowFixMe[prop-missing]\n element.assignedSlot || // step into the shadow DOM of the parent of a slotted node\n element.parentNode || ( // DOM Element detected\n isShadowRoot(element) ? element.host : null) || // ShadowRoot detected\n // $FlowFixMe[incompatible-call]: HTMLElement is a Node\n getDocumentElement(element) // fallback\n\n );\n}","import getWindow from \"./getWindow.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport getComputedStyle from \"./getComputedStyle.js\";\nimport { isHTMLElement, isShadowRoot } from \"./instanceOf.js\";\nimport isTableElement from \"./isTableElement.js\";\nimport getParentNode from \"./getParentNode.js\";\nimport getUAString from \"../utils/userAgent.js\";\n\nfunction getTrueOffsetParent(element) {\n if (!isHTMLElement(element) || // https://github.com/popperjs/popper-core/issues/837\n getComputedStyle(element).position === 'fixed') {\n return null;\n }\n\n return element.offsetParent;\n} // `.offsetParent` reports `null` for fixed elements, while absolute elements\n// return the containing block\n\n\nfunction getContainingBlock(element) {\n var isFirefox = /firefox/i.test(getUAString());\n var isIE = /Trident/i.test(getUAString());\n\n if (isIE && isHTMLElement(element)) {\n // In IE 9, 10 and 11 fixed elements containing block is always established by the viewport\n var elementCss = getComputedStyle(element);\n\n if (elementCss.position === 'fixed') {\n return null;\n }\n }\n\n var currentNode = getParentNode(element);\n\n if (isShadowRoot(currentNode)) {\n currentNode = currentNode.host;\n }\n\n while (isHTMLElement(currentNode) && ['html', 'body'].indexOf(getNodeName(currentNode)) < 0) {\n var css = getComputedStyle(currentNode); // This is non-exhaustive but covers the most common CSS properties that\n // create a containing block.\n // https://developer.mozilla.org/en-US/docs/Web/CSS/Containing_block#identifying_the_containing_block\n\n if (css.transform !== 'none' || css.perspective !== 'none' || css.contain === 'paint' || ['transform', 'perspective'].indexOf(css.willChange) !== -1 || isFirefox && css.willChange === 'filter' || isFirefox && css.filter && css.filter !== 'none') {\n return currentNode;\n } else {\n currentNode = currentNode.parentNode;\n }\n }\n\n return null;\n} // Gets the closest ancestor positioned element. Handles some edge cases,\n// such as table ancestors and cross browser bugs.\n\n\nexport default function getOffsetParent(element) {\n var window = getWindow(element);\n var offsetParent = getTrueOffsetParent(element);\n\n while (offsetParent && isTableElement(offsetParent) && getComputedStyle(offsetParent).position === 'static') {\n offsetParent = getTrueOffsetParent(offsetParent);\n }\n\n if (offsetParent && (getNodeName(offsetParent) === 'html' || getNodeName(offsetParent) === 'body' && getComputedStyle(offsetParent).position === 'static')) {\n return window;\n }\n\n return offsetParent || getContainingBlock(element) || window;\n}","export default function getMainAxisFromPlacement(placement) {\n return ['top', 'bottom'].indexOf(placement) >= 0 ? 'x' : 'y';\n}","import { max as mathMax, min as mathMin } from \"./math.js\";\nexport function within(min, value, max) {\n return mathMax(min, mathMin(value, max));\n}\nexport function withinMaxClamp(min, value, max) {\n var v = within(min, value, max);\n return v > max ? max : v;\n}","export default function getFreshSideObject() {\n return {\n top: 0,\n right: 0,\n bottom: 0,\n left: 0\n };\n}","import getFreshSideObject from \"./getFreshSideObject.js\";\nexport default function mergePaddingObject(paddingObject) {\n return Object.assign({}, getFreshSideObject(), paddingObject);\n}","export default function expandToHashMap(value, keys) {\n return keys.reduce(function (hashMap, key) {\n hashMap[key] = value;\n return hashMap;\n }, {});\n}","import getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getLayoutRect from \"../dom-utils/getLayoutRect.js\";\nimport contains from \"../dom-utils/contains.js\";\nimport getOffsetParent from \"../dom-utils/getOffsetParent.js\";\nimport getMainAxisFromPlacement from \"../utils/getMainAxisFromPlacement.js\";\nimport { within } from \"../utils/within.js\";\nimport mergePaddingObject from \"../utils/mergePaddingObject.js\";\nimport expandToHashMap from \"../utils/expandToHashMap.js\";\nimport { left, right, basePlacements, top, bottom } from \"../enums.js\"; // eslint-disable-next-line import/no-unused-modules\n\nvar toPaddingObject = function toPaddingObject(padding, state) {\n padding = typeof padding === 'function' ? padding(Object.assign({}, state.rects, {\n placement: state.placement\n })) : padding;\n return mergePaddingObject(typeof padding !== 'number' ? padding : expandToHashMap(padding, basePlacements));\n};\n\nfunction arrow(_ref) {\n var _state$modifiersData$;\n\n var state = _ref.state,\n name = _ref.name,\n options = _ref.options;\n var arrowElement = state.elements.arrow;\n var popperOffsets = state.modifiersData.popperOffsets;\n var basePlacement = getBasePlacement(state.placement);\n var axis = getMainAxisFromPlacement(basePlacement);\n var isVertical = [left, right].indexOf(basePlacement) >= 0;\n var len = isVertical ? 'height' : 'width';\n\n if (!arrowElement || !popperOffsets) {\n return;\n }\n\n var paddingObject = toPaddingObject(options.padding, state);\n var arrowRect = getLayoutRect(arrowElement);\n var minProp = axis === 'y' ? top : left;\n var maxProp = axis === 'y' ? bottom : right;\n var endDiff = state.rects.reference[len] + state.rects.reference[axis] - popperOffsets[axis] - state.rects.popper[len];\n var startDiff = popperOffsets[axis] - state.rects.reference[axis];\n var arrowOffsetParent = getOffsetParent(arrowElement);\n var clientSize = arrowOffsetParent ? axis === 'y' ? arrowOffsetParent.clientHeight || 0 : arrowOffsetParent.clientWidth || 0 : 0;\n var centerToReference = endDiff / 2 - startDiff / 2; // Make sure the arrow doesn't overflow the popper if the center point is\n // outside of the popper bounds\n\n var min = paddingObject[minProp];\n var max = clientSize - arrowRect[len] - paddingObject[maxProp];\n var center = clientSize / 2 - arrowRect[len] / 2 + centerToReference;\n var offset = within(min, center, max); // Prevents breaking syntax highlighting...\n\n var axisProp = axis;\n state.modifiersData[name] = (_state$modifiersData$ = {}, _state$modifiersData$[axisProp] = offset, _state$modifiersData$.centerOffset = offset - center, _state$modifiersData$);\n}\n\nfunction effect(_ref2) {\n var state = _ref2.state,\n options = _ref2.options;\n var _options$element = options.element,\n arrowElement = _options$element === void 0 ? '[data-popper-arrow]' : _options$element;\n\n if (arrowElement == null) {\n return;\n } // CSS selector\n\n\n if (typeof arrowElement === 'string') {\n arrowElement = state.elements.popper.querySelector(arrowElement);\n\n if (!arrowElement) {\n return;\n }\n }\n\n if (!contains(state.elements.popper, arrowElement)) {\n return;\n }\n\n state.elements.arrow = arrowElement;\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'arrow',\n enabled: true,\n phase: 'main',\n fn: arrow,\n effect: effect,\n requires: ['popperOffsets'],\n requiresIfExists: ['preventOverflow']\n};","export default function getVariation(placement) {\n return placement.split('-')[1];\n}","import { top, left, right, bottom, end } from \"../enums.js\";\nimport getOffsetParent from \"../dom-utils/getOffsetParent.js\";\nimport getWindow from \"../dom-utils/getWindow.js\";\nimport getDocumentElement from \"../dom-utils/getDocumentElement.js\";\nimport getComputedStyle from \"../dom-utils/getComputedStyle.js\";\nimport getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getVariation from \"../utils/getVariation.js\";\nimport { round } from \"../utils/math.js\"; // eslint-disable-next-line import/no-unused-modules\n\nvar unsetSides = {\n top: 'auto',\n right: 'auto',\n bottom: 'auto',\n left: 'auto'\n}; // Round the offsets to the nearest suitable subpixel based on the DPR.\n// Zooming can change the DPR, but it seems to report a value that will\n// cleanly divide the values into the appropriate subpixels.\n\nfunction roundOffsetsByDPR(_ref, win) {\n var x = _ref.x,\n y = _ref.y;\n var dpr = win.devicePixelRatio || 1;\n return {\n x: round(x * dpr) / dpr || 0,\n y: round(y * dpr) / dpr || 0\n };\n}\n\nexport function mapToStyles(_ref2) {\n var _Object$assign2;\n\n var popper = _ref2.popper,\n popperRect = _ref2.popperRect,\n placement = _ref2.placement,\n variation = _ref2.variation,\n offsets = _ref2.offsets,\n position = _ref2.position,\n gpuAcceleration = _ref2.gpuAcceleration,\n adaptive = _ref2.adaptive,\n roundOffsets = _ref2.roundOffsets,\n isFixed = _ref2.isFixed;\n var _offsets$x = offsets.x,\n x = _offsets$x === void 0 ? 0 : _offsets$x,\n _offsets$y = offsets.y,\n y = _offsets$y === void 0 ? 0 : _offsets$y;\n\n var _ref3 = typeof roundOffsets === 'function' ? roundOffsets({\n x: x,\n y: y\n }) : {\n x: x,\n y: y\n };\n\n x = _ref3.x;\n y = _ref3.y;\n var hasX = offsets.hasOwnProperty('x');\n var hasY = offsets.hasOwnProperty('y');\n var sideX = left;\n var sideY = top;\n var win = window;\n\n if (adaptive) {\n var offsetParent = getOffsetParent(popper);\n var heightProp = 'clientHeight';\n var widthProp = 'clientWidth';\n\n if (offsetParent === getWindow(popper)) {\n offsetParent = getDocumentElement(popper);\n\n if (getComputedStyle(offsetParent).position !== 'static' && position === 'absolute') {\n heightProp = 'scrollHeight';\n widthProp = 'scrollWidth';\n }\n } // $FlowFixMe[incompatible-cast]: force type refinement, we compare offsetParent with window above, but Flow doesn't detect it\n\n\n offsetParent = offsetParent;\n\n if (placement === top || (placement === left || placement === right) && variation === end) {\n sideY = bottom;\n var offsetY = isFixed && offsetParent === win && win.visualViewport ? win.visualViewport.height : // $FlowFixMe[prop-missing]\n offsetParent[heightProp];\n y -= offsetY - popperRect.height;\n y *= gpuAcceleration ? 1 : -1;\n }\n\n if (placement === left || (placement === top || placement === bottom) && variation === end) {\n sideX = right;\n var offsetX = isFixed && offsetParent === win && win.visualViewport ? win.visualViewport.width : // $FlowFixMe[prop-missing]\n offsetParent[widthProp];\n x -= offsetX - popperRect.width;\n x *= gpuAcceleration ? 1 : -1;\n }\n }\n\n var commonStyles = Object.assign({\n position: position\n }, adaptive && unsetSides);\n\n var _ref4 = roundOffsets === true ? roundOffsetsByDPR({\n x: x,\n y: y\n }, getWindow(popper)) : {\n x: x,\n y: y\n };\n\n x = _ref4.x;\n y = _ref4.y;\n\n if (gpuAcceleration) {\n var _Object$assign;\n\n return Object.assign({}, commonStyles, (_Object$assign = {}, _Object$assign[sideY] = hasY ? '0' : '', _Object$assign[sideX] = hasX ? '0' : '', _Object$assign.transform = (win.devicePixelRatio || 1) <= 1 ? \"translate(\" + x + \"px, \" + y + \"px)\" : \"translate3d(\" + x + \"px, \" + y + \"px, 0)\", _Object$assign));\n }\n\n return Object.assign({}, commonStyles, (_Object$assign2 = {}, _Object$assign2[sideY] = hasY ? y + \"px\" : '', _Object$assign2[sideX] = hasX ? x + \"px\" : '', _Object$assign2.transform = '', _Object$assign2));\n}\n\nfunction computeStyles(_ref5) {\n var state = _ref5.state,\n options = _ref5.options;\n var _options$gpuAccelerat = options.gpuAcceleration,\n gpuAcceleration = _options$gpuAccelerat === void 0 ? true : _options$gpuAccelerat,\n _options$adaptive = options.adaptive,\n adaptive = _options$adaptive === void 0 ? true : _options$adaptive,\n _options$roundOffsets = options.roundOffsets,\n roundOffsets = _options$roundOffsets === void 0 ? true : _options$roundOffsets;\n var commonStyles = {\n placement: getBasePlacement(state.placement),\n variation: getVariation(state.placement),\n popper: state.elements.popper,\n popperRect: state.rects.popper,\n gpuAcceleration: gpuAcceleration,\n isFixed: state.options.strategy === 'fixed'\n };\n\n if (state.modifiersData.popperOffsets != null) {\n state.styles.popper = Object.assign({}, state.styles.popper, mapToStyles(Object.assign({}, commonStyles, {\n offsets: state.modifiersData.popperOffsets,\n position: state.options.strategy,\n adaptive: adaptive,\n roundOffsets: roundOffsets\n })));\n }\n\n if (state.modifiersData.arrow != null) {\n state.styles.arrow = Object.assign({}, state.styles.arrow, mapToStyles(Object.assign({}, commonStyles, {\n offsets: state.modifiersData.arrow,\n position: 'absolute',\n adaptive: false,\n roundOffsets: roundOffsets\n })));\n }\n\n state.attributes.popper = Object.assign({}, state.attributes.popper, {\n 'data-popper-placement': state.placement\n });\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'computeStyles',\n enabled: true,\n phase: 'beforeWrite',\n fn: computeStyles,\n data: {}\n};","import getWindow from \"../dom-utils/getWindow.js\"; // eslint-disable-next-line import/no-unused-modules\n\nvar passive = {\n passive: true\n};\n\nfunction effect(_ref) {\n var state = _ref.state,\n instance = _ref.instance,\n options = _ref.options;\n var _options$scroll = options.scroll,\n scroll = _options$scroll === void 0 ? true : _options$scroll,\n _options$resize = options.resize,\n resize = _options$resize === void 0 ? true : _options$resize;\n var window = getWindow(state.elements.popper);\n var scrollParents = [].concat(state.scrollParents.reference, state.scrollParents.popper);\n\n if (scroll) {\n scrollParents.forEach(function (scrollParent) {\n scrollParent.addEventListener('scroll', instance.update, passive);\n });\n }\n\n if (resize) {\n window.addEventListener('resize', instance.update, passive);\n }\n\n return function () {\n if (scroll) {\n scrollParents.forEach(function (scrollParent) {\n scrollParent.removeEventListener('scroll', instance.update, passive);\n });\n }\n\n if (resize) {\n window.removeEventListener('resize', instance.update, passive);\n }\n };\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'eventListeners',\n enabled: true,\n phase: 'write',\n fn: function fn() {},\n effect: effect,\n data: {}\n};","var hash = {\n left: 'right',\n right: 'left',\n bottom: 'top',\n top: 'bottom'\n};\nexport default function getOppositePlacement(placement) {\n return placement.replace(/left|right|bottom|top/g, function (matched) {\n return hash[matched];\n });\n}","var hash = {\n start: 'end',\n end: 'start'\n};\nexport default function getOppositeVariationPlacement(placement) {\n return placement.replace(/start|end/g, function (matched) {\n return hash[matched];\n });\n}","import getWindow from \"./getWindow.js\";\nexport default function getWindowScroll(node) {\n var win = getWindow(node);\n var scrollLeft = win.pageXOffset;\n var scrollTop = win.pageYOffset;\n return {\n scrollLeft: scrollLeft,\n scrollTop: scrollTop\n };\n}","import getBoundingClientRect from \"./getBoundingClientRect.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport getWindowScroll from \"./getWindowScroll.js\";\nexport default function getWindowScrollBarX(element) {\n // If has a CSS width greater than the viewport, then this will be\n // incorrect for RTL.\n // Popper 1 is broken in this case and never had a bug report so let's assume\n // it's not an issue. I don't think anyone ever specifies width on \n // anyway.\n // Browsers where the left scrollbar doesn't cause an issue report `0` for\n // this (e.g. Edge 2019, IE11, Safari)\n return getBoundingClientRect(getDocumentElement(element)).left + getWindowScroll(element).scrollLeft;\n}","import getWindow from \"./getWindow.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport getWindowScrollBarX from \"./getWindowScrollBarX.js\";\nimport isLayoutViewport from \"./isLayoutViewport.js\";\nexport default function getViewportRect(element, strategy) {\n var win = getWindow(element);\n var html = getDocumentElement(element);\n var visualViewport = win.visualViewport;\n var width = html.clientWidth;\n var height = html.clientHeight;\n var x = 0;\n var y = 0;\n\n if (visualViewport) {\n width = visualViewport.width;\n height = visualViewport.height;\n var layoutViewport = isLayoutViewport();\n\n if (layoutViewport || !layoutViewport && strategy === 'fixed') {\n x = visualViewport.offsetLeft;\n y = visualViewport.offsetTop;\n }\n }\n\n return {\n width: width,\n height: height,\n x: x + getWindowScrollBarX(element),\n y: y\n };\n}","import getDocumentElement from \"./getDocumentElement.js\";\nimport getComputedStyle from \"./getComputedStyle.js\";\nimport getWindowScrollBarX from \"./getWindowScrollBarX.js\";\nimport getWindowScroll from \"./getWindowScroll.js\";\nimport { max } from \"../utils/math.js\"; // Gets the entire size of the scrollable document area, even extending outside\n// of the `` and `` rect bounds if horizontally scrollable\n\nexport default function getDocumentRect(element) {\n var _element$ownerDocumen;\n\n var html = getDocumentElement(element);\n var winScroll = getWindowScroll(element);\n var body = (_element$ownerDocumen = element.ownerDocument) == null ? void 0 : _element$ownerDocumen.body;\n var width = max(html.scrollWidth, html.clientWidth, body ? body.scrollWidth : 0, body ? body.clientWidth : 0);\n var height = max(html.scrollHeight, html.clientHeight, body ? body.scrollHeight : 0, body ? body.clientHeight : 0);\n var x = -winScroll.scrollLeft + getWindowScrollBarX(element);\n var y = -winScroll.scrollTop;\n\n if (getComputedStyle(body || html).direction === 'rtl') {\n x += max(html.clientWidth, body ? body.clientWidth : 0) - width;\n }\n\n return {\n width: width,\n height: height,\n x: x,\n y: y\n };\n}","import getComputedStyle from \"./getComputedStyle.js\";\nexport default function isScrollParent(element) {\n // Firefox wants us to check `-x` and `-y` variations as well\n var _getComputedStyle = getComputedStyle(element),\n overflow = _getComputedStyle.overflow,\n overflowX = _getComputedStyle.overflowX,\n overflowY = _getComputedStyle.overflowY;\n\n return /auto|scroll|overlay|hidden/.test(overflow + overflowY + overflowX);\n}","import getParentNode from \"./getParentNode.js\";\nimport isScrollParent from \"./isScrollParent.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport { isHTMLElement } from \"./instanceOf.js\";\nexport default function getScrollParent(node) {\n if (['html', 'body', '#document'].indexOf(getNodeName(node)) >= 0) {\n // $FlowFixMe[incompatible-return]: assume body is always available\n return node.ownerDocument.body;\n }\n\n if (isHTMLElement(node) && isScrollParent(node)) {\n return node;\n }\n\n return getScrollParent(getParentNode(node));\n}","import getScrollParent from \"./getScrollParent.js\";\nimport getParentNode from \"./getParentNode.js\";\nimport getWindow from \"./getWindow.js\";\nimport isScrollParent from \"./isScrollParent.js\";\n/*\ngiven a DOM element, return the list of all scroll parents, up the list of ancesors\nuntil we get to the top window object. This list is what we attach scroll listeners\nto, because if any of these parent elements scroll, we'll need to re-calculate the\nreference element's position.\n*/\n\nexport default function listScrollParents(element, list) {\n var _element$ownerDocumen;\n\n if (list === void 0) {\n list = [];\n }\n\n var scrollParent = getScrollParent(element);\n var isBody = scrollParent === ((_element$ownerDocumen = element.ownerDocument) == null ? void 0 : _element$ownerDocumen.body);\n var win = getWindow(scrollParent);\n var target = isBody ? [win].concat(win.visualViewport || [], isScrollParent(scrollParent) ? scrollParent : []) : scrollParent;\n var updatedList = list.concat(target);\n return isBody ? updatedList : // $FlowFixMe[incompatible-call]: isBody tells us target will be an HTMLElement here\n updatedList.concat(listScrollParents(getParentNode(target)));\n}","export default function rectToClientRect(rect) {\n return Object.assign({}, rect, {\n left: rect.x,\n top: rect.y,\n right: rect.x + rect.width,\n bottom: rect.y + rect.height\n });\n}","import { viewport } from \"../enums.js\";\nimport getViewportRect from \"./getViewportRect.js\";\nimport getDocumentRect from \"./getDocumentRect.js\";\nimport listScrollParents from \"./listScrollParents.js\";\nimport getOffsetParent from \"./getOffsetParent.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport getComputedStyle from \"./getComputedStyle.js\";\nimport { isElement, isHTMLElement } from \"./instanceOf.js\";\nimport getBoundingClientRect from \"./getBoundingClientRect.js\";\nimport getParentNode from \"./getParentNode.js\";\nimport contains from \"./contains.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport rectToClientRect from \"../utils/rectToClientRect.js\";\nimport { max, min } from \"../utils/math.js\";\n\nfunction getInnerBoundingClientRect(element, strategy) {\n var rect = getBoundingClientRect(element, false, strategy === 'fixed');\n rect.top = rect.top + element.clientTop;\n rect.left = rect.left + element.clientLeft;\n rect.bottom = rect.top + element.clientHeight;\n rect.right = rect.left + element.clientWidth;\n rect.width = element.clientWidth;\n rect.height = element.clientHeight;\n rect.x = rect.left;\n rect.y = rect.top;\n return rect;\n}\n\nfunction getClientRectFromMixedType(element, clippingParent, strategy) {\n return clippingParent === viewport ? rectToClientRect(getViewportRect(element, strategy)) : isElement(clippingParent) ? getInnerBoundingClientRect(clippingParent, strategy) : rectToClientRect(getDocumentRect(getDocumentElement(element)));\n} // A \"clipping parent\" is an overflowable container with the characteristic of\n// clipping (or hiding) overflowing elements with a position different from\n// `initial`\n\n\nfunction getClippingParents(element) {\n var clippingParents = listScrollParents(getParentNode(element));\n var canEscapeClipping = ['absolute', 'fixed'].indexOf(getComputedStyle(element).position) >= 0;\n var clipperElement = canEscapeClipping && isHTMLElement(element) ? getOffsetParent(element) : element;\n\n if (!isElement(clipperElement)) {\n return [];\n } // $FlowFixMe[incompatible-return]: https://github.com/facebook/flow/issues/1414\n\n\n return clippingParents.filter(function (clippingParent) {\n return isElement(clippingParent) && contains(clippingParent, clipperElement) && getNodeName(clippingParent) !== 'body';\n });\n} // Gets the maximum area that the element is visible in due to any number of\n// clipping parents\n\n\nexport default function getClippingRect(element, boundary, rootBoundary, strategy) {\n var mainClippingParents = boundary === 'clippingParents' ? getClippingParents(element) : [].concat(boundary);\n var clippingParents = [].concat(mainClippingParents, [rootBoundary]);\n var firstClippingParent = clippingParents[0];\n var clippingRect = clippingParents.reduce(function (accRect, clippingParent) {\n var rect = getClientRectFromMixedType(element, clippingParent, strategy);\n accRect.top = max(rect.top, accRect.top);\n accRect.right = min(rect.right, accRect.right);\n accRect.bottom = min(rect.bottom, accRect.bottom);\n accRect.left = max(rect.left, accRect.left);\n return accRect;\n }, getClientRectFromMixedType(element, firstClippingParent, strategy));\n clippingRect.width = clippingRect.right - clippingRect.left;\n clippingRect.height = clippingRect.bottom - clippingRect.top;\n clippingRect.x = clippingRect.left;\n clippingRect.y = clippingRect.top;\n return clippingRect;\n}","import getBasePlacement from \"./getBasePlacement.js\";\nimport getVariation from \"./getVariation.js\";\nimport getMainAxisFromPlacement from \"./getMainAxisFromPlacement.js\";\nimport { top, right, bottom, left, start, end } from \"../enums.js\";\nexport default function computeOffsets(_ref) {\n var reference = _ref.reference,\n element = _ref.element,\n placement = _ref.placement;\n var basePlacement = placement ? getBasePlacement(placement) : null;\n var variation = placement ? getVariation(placement) : null;\n var commonX = reference.x + reference.width / 2 - element.width / 2;\n var commonY = reference.y + reference.height / 2 - element.height / 2;\n var offsets;\n\n switch (basePlacement) {\n case top:\n offsets = {\n x: commonX,\n y: reference.y - element.height\n };\n break;\n\n case bottom:\n offsets = {\n x: commonX,\n y: reference.y + reference.height\n };\n break;\n\n case right:\n offsets = {\n x: reference.x + reference.width,\n y: commonY\n };\n break;\n\n case left:\n offsets = {\n x: reference.x - element.width,\n y: commonY\n };\n break;\n\n default:\n offsets = {\n x: reference.x,\n y: reference.y\n };\n }\n\n var mainAxis = basePlacement ? getMainAxisFromPlacement(basePlacement) : null;\n\n if (mainAxis != null) {\n var len = mainAxis === 'y' ? 'height' : 'width';\n\n switch (variation) {\n case start:\n offsets[mainAxis] = offsets[mainAxis] - (reference[len] / 2 - element[len] / 2);\n break;\n\n case end:\n offsets[mainAxis] = offsets[mainAxis] + (reference[len] / 2 - element[len] / 2);\n break;\n\n default:\n }\n }\n\n return offsets;\n}","import getClippingRect from \"../dom-utils/getClippingRect.js\";\nimport getDocumentElement from \"../dom-utils/getDocumentElement.js\";\nimport getBoundingClientRect from \"../dom-utils/getBoundingClientRect.js\";\nimport computeOffsets from \"./computeOffsets.js\";\nimport rectToClientRect from \"./rectToClientRect.js\";\nimport { clippingParents, reference, popper, bottom, top, right, basePlacements, viewport } from \"../enums.js\";\nimport { isElement } from \"../dom-utils/instanceOf.js\";\nimport mergePaddingObject from \"./mergePaddingObject.js\";\nimport expandToHashMap from \"./expandToHashMap.js\"; // eslint-disable-next-line import/no-unused-modules\n\nexport default function detectOverflow(state, options) {\n if (options === void 0) {\n options = {};\n }\n\n var _options = options,\n _options$placement = _options.placement,\n placement = _options$placement === void 0 ? state.placement : _options$placement,\n _options$strategy = _options.strategy,\n strategy = _options$strategy === void 0 ? state.strategy : _options$strategy,\n _options$boundary = _options.boundary,\n boundary = _options$boundary === void 0 ? clippingParents : _options$boundary,\n _options$rootBoundary = _options.rootBoundary,\n rootBoundary = _options$rootBoundary === void 0 ? viewport : _options$rootBoundary,\n _options$elementConte = _options.elementContext,\n elementContext = _options$elementConte === void 0 ? popper : _options$elementConte,\n _options$altBoundary = _options.altBoundary,\n altBoundary = _options$altBoundary === void 0 ? false : _options$altBoundary,\n _options$padding = _options.padding,\n padding = _options$padding === void 0 ? 0 : _options$padding;\n var paddingObject = mergePaddingObject(typeof padding !== 'number' ? padding : expandToHashMap(padding, basePlacements));\n var altContext = elementContext === popper ? reference : popper;\n var popperRect = state.rects.popper;\n var element = state.elements[altBoundary ? altContext : elementContext];\n var clippingClientRect = getClippingRect(isElement(element) ? element : element.contextElement || getDocumentElement(state.elements.popper), boundary, rootBoundary, strategy);\n var referenceClientRect = getBoundingClientRect(state.elements.reference);\n var popperOffsets = computeOffsets({\n reference: referenceClientRect,\n element: popperRect,\n strategy: 'absolute',\n placement: placement\n });\n var popperClientRect = rectToClientRect(Object.assign({}, popperRect, popperOffsets));\n var elementClientRect = elementContext === popper ? popperClientRect : referenceClientRect; // positive = overflowing the clipping rect\n // 0 or negative = within the clipping rect\n\n var overflowOffsets = {\n top: clippingClientRect.top - elementClientRect.top + paddingObject.top,\n bottom: elementClientRect.bottom - clippingClientRect.bottom + paddingObject.bottom,\n left: clippingClientRect.left - elementClientRect.left + paddingObject.left,\n right: elementClientRect.right - clippingClientRect.right + paddingObject.right\n };\n var offsetData = state.modifiersData.offset; // Offsets can be applied only to the popper element\n\n if (elementContext === popper && offsetData) {\n var offset = offsetData[placement];\n Object.keys(overflowOffsets).forEach(function (key) {\n var multiply = [right, bottom].indexOf(key) >= 0 ? 1 : -1;\n var axis = [top, bottom].indexOf(key) >= 0 ? 'y' : 'x';\n overflowOffsets[key] += offset[axis] * multiply;\n });\n }\n\n return overflowOffsets;\n}","import getVariation from \"./getVariation.js\";\nimport { variationPlacements, basePlacements, placements as allPlacements } from \"../enums.js\";\nimport detectOverflow from \"./detectOverflow.js\";\nimport getBasePlacement from \"./getBasePlacement.js\";\nexport default function computeAutoPlacement(state, options) {\n if (options === void 0) {\n options = {};\n }\n\n var _options = options,\n placement = _options.placement,\n boundary = _options.boundary,\n rootBoundary = _options.rootBoundary,\n padding = _options.padding,\n flipVariations = _options.flipVariations,\n _options$allowedAutoP = _options.allowedAutoPlacements,\n allowedAutoPlacements = _options$allowedAutoP === void 0 ? allPlacements : _options$allowedAutoP;\n var variation = getVariation(placement);\n var placements = variation ? flipVariations ? variationPlacements : variationPlacements.filter(function (placement) {\n return getVariation(placement) === variation;\n }) : basePlacements;\n var allowedPlacements = placements.filter(function (placement) {\n return allowedAutoPlacements.indexOf(placement) >= 0;\n });\n\n if (allowedPlacements.length === 0) {\n allowedPlacements = placements;\n } // $FlowFixMe[incompatible-type]: Flow seems to have problems with two array unions...\n\n\n var overflows = allowedPlacements.reduce(function (acc, placement) {\n acc[placement] = detectOverflow(state, {\n placement: placement,\n boundary: boundary,\n rootBoundary: rootBoundary,\n padding: padding\n })[getBasePlacement(placement)];\n return acc;\n }, {});\n return Object.keys(overflows).sort(function (a, b) {\n return overflows[a] - overflows[b];\n });\n}","import getOppositePlacement from \"../utils/getOppositePlacement.js\";\nimport getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getOppositeVariationPlacement from \"../utils/getOppositeVariationPlacement.js\";\nimport detectOverflow from \"../utils/detectOverflow.js\";\nimport computeAutoPlacement from \"../utils/computeAutoPlacement.js\";\nimport { bottom, top, start, right, left, auto } from \"../enums.js\";\nimport getVariation from \"../utils/getVariation.js\"; // eslint-disable-next-line import/no-unused-modules\n\nfunction getExpandedFallbackPlacements(placement) {\n if (getBasePlacement(placement) === auto) {\n return [];\n }\n\n var oppositePlacement = getOppositePlacement(placement);\n return [getOppositeVariationPlacement(placement), oppositePlacement, getOppositeVariationPlacement(oppositePlacement)];\n}\n\nfunction flip(_ref) {\n var state = _ref.state,\n options = _ref.options,\n name = _ref.name;\n\n if (state.modifiersData[name]._skip) {\n return;\n }\n\n var _options$mainAxis = options.mainAxis,\n checkMainAxis = _options$mainAxis === void 0 ? true : _options$mainAxis,\n _options$altAxis = options.altAxis,\n checkAltAxis = _options$altAxis === void 0 ? true : _options$altAxis,\n specifiedFallbackPlacements = options.fallbackPlacements,\n padding = options.padding,\n boundary = options.boundary,\n rootBoundary = options.rootBoundary,\n altBoundary = options.altBoundary,\n _options$flipVariatio = options.flipVariations,\n flipVariations = _options$flipVariatio === void 0 ? true : _options$flipVariatio,\n allowedAutoPlacements = options.allowedAutoPlacements;\n var preferredPlacement = state.options.placement;\n var basePlacement = getBasePlacement(preferredPlacement);\n var isBasePlacement = basePlacement === preferredPlacement;\n var fallbackPlacements = specifiedFallbackPlacements || (isBasePlacement || !flipVariations ? [getOppositePlacement(preferredPlacement)] : getExpandedFallbackPlacements(preferredPlacement));\n var placements = [preferredPlacement].concat(fallbackPlacements).reduce(function (acc, placement) {\n return acc.concat(getBasePlacement(placement) === auto ? computeAutoPlacement(state, {\n placement: placement,\n boundary: boundary,\n rootBoundary: rootBoundary,\n padding: padding,\n flipVariations: flipVariations,\n allowedAutoPlacements: allowedAutoPlacements\n }) : placement);\n }, []);\n var referenceRect = state.rects.reference;\n var popperRect = state.rects.popper;\n var checksMap = new Map();\n var makeFallbackChecks = true;\n var firstFittingPlacement = placements[0];\n\n for (var i = 0; i < placements.length; i++) {\n var placement = placements[i];\n\n var _basePlacement = getBasePlacement(placement);\n\n var isStartVariation = getVariation(placement) === start;\n var isVertical = [top, bottom].indexOf(_basePlacement) >= 0;\n var len = isVertical ? 'width' : 'height';\n var overflow = detectOverflow(state, {\n placement: placement,\n boundary: boundary,\n rootBoundary: rootBoundary,\n altBoundary: altBoundary,\n padding: padding\n });\n var mainVariationSide = isVertical ? isStartVariation ? right : left : isStartVariation ? bottom : top;\n\n if (referenceRect[len] > popperRect[len]) {\n mainVariationSide = getOppositePlacement(mainVariationSide);\n }\n\n var altVariationSide = getOppositePlacement(mainVariationSide);\n var checks = [];\n\n if (checkMainAxis) {\n checks.push(overflow[_basePlacement] <= 0);\n }\n\n if (checkAltAxis) {\n checks.push(overflow[mainVariationSide] <= 0, overflow[altVariationSide] <= 0);\n }\n\n if (checks.every(function (check) {\n return check;\n })) {\n firstFittingPlacement = placement;\n makeFallbackChecks = false;\n break;\n }\n\n checksMap.set(placement, checks);\n }\n\n if (makeFallbackChecks) {\n // `2` may be desired in some cases – research later\n var numberOfChecks = flipVariations ? 3 : 1;\n\n var _loop = function _loop(_i) {\n var fittingPlacement = placements.find(function (placement) {\n var checks = checksMap.get(placement);\n\n if (checks) {\n return checks.slice(0, _i).every(function (check) {\n return check;\n });\n }\n });\n\n if (fittingPlacement) {\n firstFittingPlacement = fittingPlacement;\n return \"break\";\n }\n };\n\n for (var _i = numberOfChecks; _i > 0; _i--) {\n var _ret = _loop(_i);\n\n if (_ret === \"break\") break;\n }\n }\n\n if (state.placement !== firstFittingPlacement) {\n state.modifiersData[name]._skip = true;\n state.placement = firstFittingPlacement;\n state.reset = true;\n }\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'flip',\n enabled: true,\n phase: 'main',\n fn: flip,\n requiresIfExists: ['offset'],\n data: {\n _skip: false\n }\n};","import { top, bottom, left, right } from \"../enums.js\";\nimport detectOverflow from \"../utils/detectOverflow.js\";\n\nfunction getSideOffsets(overflow, rect, preventedOffsets) {\n if (preventedOffsets === void 0) {\n preventedOffsets = {\n x: 0,\n y: 0\n };\n }\n\n return {\n top: overflow.top - rect.height - preventedOffsets.y,\n right: overflow.right - rect.width + preventedOffsets.x,\n bottom: overflow.bottom - rect.height + preventedOffsets.y,\n left: overflow.left - rect.width - preventedOffsets.x\n };\n}\n\nfunction isAnySideFullyClipped(overflow) {\n return [top, right, bottom, left].some(function (side) {\n return overflow[side] >= 0;\n });\n}\n\nfunction hide(_ref) {\n var state = _ref.state,\n name = _ref.name;\n var referenceRect = state.rects.reference;\n var popperRect = state.rects.popper;\n var preventedOffsets = state.modifiersData.preventOverflow;\n var referenceOverflow = detectOverflow(state, {\n elementContext: 'reference'\n });\n var popperAltOverflow = detectOverflow(state, {\n altBoundary: true\n });\n var referenceClippingOffsets = getSideOffsets(referenceOverflow, referenceRect);\n var popperEscapeOffsets = getSideOffsets(popperAltOverflow, popperRect, preventedOffsets);\n var isReferenceHidden = isAnySideFullyClipped(referenceClippingOffsets);\n var hasPopperEscaped = isAnySideFullyClipped(popperEscapeOffsets);\n state.modifiersData[name] = {\n referenceClippingOffsets: referenceClippingOffsets,\n popperEscapeOffsets: popperEscapeOffsets,\n isReferenceHidden: isReferenceHidden,\n hasPopperEscaped: hasPopperEscaped\n };\n state.attributes.popper = Object.assign({}, state.attributes.popper, {\n 'data-popper-reference-hidden': isReferenceHidden,\n 'data-popper-escaped': hasPopperEscaped\n });\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'hide',\n enabled: true,\n phase: 'main',\n requiresIfExists: ['preventOverflow'],\n fn: hide\n};","import getBasePlacement from \"../utils/getBasePlacement.js\";\nimport { top, left, right, placements } from \"../enums.js\"; // eslint-disable-next-line import/no-unused-modules\n\nexport function distanceAndSkiddingToXY(placement, rects, offset) {\n var basePlacement = getBasePlacement(placement);\n var invertDistance = [left, top].indexOf(basePlacement) >= 0 ? -1 : 1;\n\n var _ref = typeof offset === 'function' ? offset(Object.assign({}, rects, {\n placement: placement\n })) : offset,\n skidding = _ref[0],\n distance = _ref[1];\n\n skidding = skidding || 0;\n distance = (distance || 0) * invertDistance;\n return [left, right].indexOf(basePlacement) >= 0 ? {\n x: distance,\n y: skidding\n } : {\n x: skidding,\n y: distance\n };\n}\n\nfunction offset(_ref2) {\n var state = _ref2.state,\n options = _ref2.options,\n name = _ref2.name;\n var _options$offset = options.offset,\n offset = _options$offset === void 0 ? [0, 0] : _options$offset;\n var data = placements.reduce(function (acc, placement) {\n acc[placement] = distanceAndSkiddingToXY(placement, state.rects, offset);\n return acc;\n }, {});\n var _data$state$placement = data[state.placement],\n x = _data$state$placement.x,\n y = _data$state$placement.y;\n\n if (state.modifiersData.popperOffsets != null) {\n state.modifiersData.popperOffsets.x += x;\n state.modifiersData.popperOffsets.y += y;\n }\n\n state.modifiersData[name] = data;\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'offset',\n enabled: true,\n phase: 'main',\n requires: ['popperOffsets'],\n fn: offset\n};","import computeOffsets from \"../utils/computeOffsets.js\";\n\nfunction popperOffsets(_ref) {\n var state = _ref.state,\n name = _ref.name;\n // Offsets are the actual position the popper needs to have to be\n // properly positioned near its reference element\n // This is the most basic placement, and will be adjusted by\n // the modifiers in the next step\n state.modifiersData[name] = computeOffsets({\n reference: state.rects.reference,\n element: state.rects.popper,\n strategy: 'absolute',\n placement: state.placement\n });\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'popperOffsets',\n enabled: true,\n phase: 'read',\n fn: popperOffsets,\n data: {}\n};","export default function getAltAxis(axis) {\n return axis === 'x' ? 'y' : 'x';\n}","import { top, left, right, bottom, start } from \"../enums.js\";\nimport getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getMainAxisFromPlacement from \"../utils/getMainAxisFromPlacement.js\";\nimport getAltAxis from \"../utils/getAltAxis.js\";\nimport { within, withinMaxClamp } from \"../utils/within.js\";\nimport getLayoutRect from \"../dom-utils/getLayoutRect.js\";\nimport getOffsetParent from \"../dom-utils/getOffsetParent.js\";\nimport detectOverflow from \"../utils/detectOverflow.js\";\nimport getVariation from \"../utils/getVariation.js\";\nimport getFreshSideObject from \"../utils/getFreshSideObject.js\";\nimport { min as mathMin, max as mathMax } from \"../utils/math.js\";\n\nfunction preventOverflow(_ref) {\n var state = _ref.state,\n options = _ref.options,\n name = _ref.name;\n var _options$mainAxis = options.mainAxis,\n checkMainAxis = _options$mainAxis === void 0 ? true : _options$mainAxis,\n _options$altAxis = options.altAxis,\n checkAltAxis = _options$altAxis === void 0 ? false : _options$altAxis,\n boundary = options.boundary,\n rootBoundary = options.rootBoundary,\n altBoundary = options.altBoundary,\n padding = options.padding,\n _options$tether = options.tether,\n tether = _options$tether === void 0 ? true : _options$tether,\n _options$tetherOffset = options.tetherOffset,\n tetherOffset = _options$tetherOffset === void 0 ? 0 : _options$tetherOffset;\n var overflow = detectOverflow(state, {\n boundary: boundary,\n rootBoundary: rootBoundary,\n padding: padding,\n altBoundary: altBoundary\n });\n var basePlacement = getBasePlacement(state.placement);\n var variation = getVariation(state.placement);\n var isBasePlacement = !variation;\n var mainAxis = getMainAxisFromPlacement(basePlacement);\n var altAxis = getAltAxis(mainAxis);\n var popperOffsets = state.modifiersData.popperOffsets;\n var referenceRect = state.rects.reference;\n var popperRect = state.rects.popper;\n var tetherOffsetValue = typeof tetherOffset === 'function' ? tetherOffset(Object.assign({}, state.rects, {\n placement: state.placement\n })) : tetherOffset;\n var normalizedTetherOffsetValue = typeof tetherOffsetValue === 'number' ? {\n mainAxis: tetherOffsetValue,\n altAxis: tetherOffsetValue\n } : Object.assign({\n mainAxis: 0,\n altAxis: 0\n }, tetherOffsetValue);\n var offsetModifierState = state.modifiersData.offset ? state.modifiersData.offset[state.placement] : null;\n var data = {\n x: 0,\n y: 0\n };\n\n if (!popperOffsets) {\n return;\n }\n\n if (checkMainAxis) {\n var _offsetModifierState$;\n\n var mainSide = mainAxis === 'y' ? top : left;\n var altSide = mainAxis === 'y' ? bottom : right;\n var len = mainAxis === 'y' ? 'height' : 'width';\n var offset = popperOffsets[mainAxis];\n var min = offset + overflow[mainSide];\n var max = offset - overflow[altSide];\n var additive = tether ? -popperRect[len] / 2 : 0;\n var minLen = variation === start ? referenceRect[len] : popperRect[len];\n var maxLen = variation === start ? -popperRect[len] : -referenceRect[len]; // We need to include the arrow in the calculation so the arrow doesn't go\n // outside the reference bounds\n\n var arrowElement = state.elements.arrow;\n var arrowRect = tether && arrowElement ? getLayoutRect(arrowElement) : {\n width: 0,\n height: 0\n };\n var arrowPaddingObject = state.modifiersData['arrow#persistent'] ? state.modifiersData['arrow#persistent'].padding : getFreshSideObject();\n var arrowPaddingMin = arrowPaddingObject[mainSide];\n var arrowPaddingMax = arrowPaddingObject[altSide]; // If the reference length is smaller than the arrow length, we don't want\n // to include its full size in the calculation. If the reference is small\n // and near the edge of a boundary, the popper can overflow even if the\n // reference is not overflowing as well (e.g. virtual elements with no\n // width or height)\n\n var arrowLen = within(0, referenceRect[len], arrowRect[len]);\n var minOffset = isBasePlacement ? referenceRect[len] / 2 - additive - arrowLen - arrowPaddingMin - normalizedTetherOffsetValue.mainAxis : minLen - arrowLen - arrowPaddingMin - normalizedTetherOffsetValue.mainAxis;\n var maxOffset = isBasePlacement ? -referenceRect[len] / 2 + additive + arrowLen + arrowPaddingMax + normalizedTetherOffsetValue.mainAxis : maxLen + arrowLen + arrowPaddingMax + normalizedTetherOffsetValue.mainAxis;\n var arrowOffsetParent = state.elements.arrow && getOffsetParent(state.elements.arrow);\n var clientOffset = arrowOffsetParent ? mainAxis === 'y' ? arrowOffsetParent.clientTop || 0 : arrowOffsetParent.clientLeft || 0 : 0;\n var offsetModifierValue = (_offsetModifierState$ = offsetModifierState == null ? void 0 : offsetModifierState[mainAxis]) != null ? _offsetModifierState$ : 0;\n var tetherMin = offset + minOffset - offsetModifierValue - clientOffset;\n var tetherMax = offset + maxOffset - offsetModifierValue;\n var preventedOffset = within(tether ? mathMin(min, tetherMin) : min, offset, tether ? mathMax(max, tetherMax) : max);\n popperOffsets[mainAxis] = preventedOffset;\n data[mainAxis] = preventedOffset - offset;\n }\n\n if (checkAltAxis) {\n var _offsetModifierState$2;\n\n var _mainSide = mainAxis === 'x' ? top : left;\n\n var _altSide = mainAxis === 'x' ? bottom : right;\n\n var _offset = popperOffsets[altAxis];\n\n var _len = altAxis === 'y' ? 'height' : 'width';\n\n var _min = _offset + overflow[_mainSide];\n\n var _max = _offset - overflow[_altSide];\n\n var isOriginSide = [top, left].indexOf(basePlacement) !== -1;\n\n var _offsetModifierValue = (_offsetModifierState$2 = offsetModifierState == null ? void 0 : offsetModifierState[altAxis]) != null ? _offsetModifierState$2 : 0;\n\n var _tetherMin = isOriginSide ? _min : _offset - referenceRect[_len] - popperRect[_len] - _offsetModifierValue + normalizedTetherOffsetValue.altAxis;\n\n var _tetherMax = isOriginSide ? _offset + referenceRect[_len] + popperRect[_len] - _offsetModifierValue - normalizedTetherOffsetValue.altAxis : _max;\n\n var _preventedOffset = tether && isOriginSide ? withinMaxClamp(_tetherMin, _offset, _tetherMax) : within(tether ? _tetherMin : _min, _offset, tether ? _tetherMax : _max);\n\n popperOffsets[altAxis] = _preventedOffset;\n data[altAxis] = _preventedOffset - _offset;\n }\n\n state.modifiersData[name] = data;\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'preventOverflow',\n enabled: true,\n phase: 'main',\n fn: preventOverflow,\n requiresIfExists: ['offset']\n};","export default function getHTMLElementScroll(element) {\n return {\n scrollLeft: element.scrollLeft,\n scrollTop: element.scrollTop\n };\n}","import getWindowScroll from \"./getWindowScroll.js\";\nimport getWindow from \"./getWindow.js\";\nimport { isHTMLElement } from \"./instanceOf.js\";\nimport getHTMLElementScroll from \"./getHTMLElementScroll.js\";\nexport default function getNodeScroll(node) {\n if (node === getWindow(node) || !isHTMLElement(node)) {\n return getWindowScroll(node);\n } else {\n return getHTMLElementScroll(node);\n }\n}","import getBoundingClientRect from \"./getBoundingClientRect.js\";\nimport getNodeScroll from \"./getNodeScroll.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport { isHTMLElement } from \"./instanceOf.js\";\nimport getWindowScrollBarX from \"./getWindowScrollBarX.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport isScrollParent from \"./isScrollParent.js\";\nimport { round } from \"../utils/math.js\";\n\nfunction isElementScaled(element) {\n var rect = element.getBoundingClientRect();\n var scaleX = round(rect.width) / element.offsetWidth || 1;\n var scaleY = round(rect.height) / element.offsetHeight || 1;\n return scaleX !== 1 || scaleY !== 1;\n} // Returns the composite rect of an element relative to its offsetParent.\n// Composite means it takes into account transforms as well as layout.\n\n\nexport default function getCompositeRect(elementOrVirtualElement, offsetParent, isFixed) {\n if (isFixed === void 0) {\n isFixed = false;\n }\n\n var isOffsetParentAnElement = isHTMLElement(offsetParent);\n var offsetParentIsScaled = isHTMLElement(offsetParent) && isElementScaled(offsetParent);\n var documentElement = getDocumentElement(offsetParent);\n var rect = getBoundingClientRect(elementOrVirtualElement, offsetParentIsScaled, isFixed);\n var scroll = {\n scrollLeft: 0,\n scrollTop: 0\n };\n var offsets = {\n x: 0,\n y: 0\n };\n\n if (isOffsetParentAnElement || !isOffsetParentAnElement && !isFixed) {\n if (getNodeName(offsetParent) !== 'body' || // https://github.com/popperjs/popper-core/issues/1078\n isScrollParent(documentElement)) {\n scroll = getNodeScroll(offsetParent);\n }\n\n if (isHTMLElement(offsetParent)) {\n offsets = getBoundingClientRect(offsetParent, true);\n offsets.x += offsetParent.clientLeft;\n offsets.y += offsetParent.clientTop;\n } else if (documentElement) {\n offsets.x = getWindowScrollBarX(documentElement);\n }\n }\n\n return {\n x: rect.left + scroll.scrollLeft - offsets.x,\n y: rect.top + scroll.scrollTop - offsets.y,\n width: rect.width,\n height: rect.height\n };\n}","import { modifierPhases } from \"../enums.js\"; // source: https://stackoverflow.com/questions/49875255\n\nfunction order(modifiers) {\n var map = new Map();\n var visited = new Set();\n var result = [];\n modifiers.forEach(function (modifier) {\n map.set(modifier.name, modifier);\n }); // On visiting object, check for its dependencies and visit them recursively\n\n function sort(modifier) {\n visited.add(modifier.name);\n var requires = [].concat(modifier.requires || [], modifier.requiresIfExists || []);\n requires.forEach(function (dep) {\n if (!visited.has(dep)) {\n var depModifier = map.get(dep);\n\n if (depModifier) {\n sort(depModifier);\n }\n }\n });\n result.push(modifier);\n }\n\n modifiers.forEach(function (modifier) {\n if (!visited.has(modifier.name)) {\n // check for visited object\n sort(modifier);\n }\n });\n return result;\n}\n\nexport default function orderModifiers(modifiers) {\n // order based on dependencies\n var orderedModifiers = order(modifiers); // order based on phase\n\n return modifierPhases.reduce(function (acc, phase) {\n return acc.concat(orderedModifiers.filter(function (modifier) {\n return modifier.phase === phase;\n }));\n }, []);\n}","export default function debounce(fn) {\n var pending;\n return function () {\n if (!pending) {\n pending = new Promise(function (resolve) {\n Promise.resolve().then(function () {\n pending = undefined;\n resolve(fn());\n });\n });\n }\n\n return pending;\n };\n}","export default function mergeByName(modifiers) {\n var merged = modifiers.reduce(function (merged, current) {\n var existing = merged[current.name];\n merged[current.name] = existing ? Object.assign({}, existing, current, {\n options: Object.assign({}, existing.options, current.options),\n data: Object.assign({}, existing.data, current.data)\n }) : current;\n return merged;\n }, {}); // IE11 does not support Object.values\n\n return Object.keys(merged).map(function (key) {\n return merged[key];\n });\n}","import getCompositeRect from \"./dom-utils/getCompositeRect.js\";\nimport getLayoutRect from \"./dom-utils/getLayoutRect.js\";\nimport listScrollParents from \"./dom-utils/listScrollParents.js\";\nimport getOffsetParent from \"./dom-utils/getOffsetParent.js\";\nimport orderModifiers from \"./utils/orderModifiers.js\";\nimport debounce from \"./utils/debounce.js\";\nimport mergeByName from \"./utils/mergeByName.js\";\nimport detectOverflow from \"./utils/detectOverflow.js\";\nimport { isElement } from \"./dom-utils/instanceOf.js\";\nvar DEFAULT_OPTIONS = {\n placement: 'bottom',\n modifiers: [],\n strategy: 'absolute'\n};\n\nfunction areValidElements() {\n for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {\n args[_key] = arguments[_key];\n }\n\n return !args.some(function (element) {\n return !(element && typeof element.getBoundingClientRect === 'function');\n });\n}\n\nexport function popperGenerator(generatorOptions) {\n if (generatorOptions === void 0) {\n generatorOptions = {};\n }\n\n var _generatorOptions = generatorOptions,\n _generatorOptions$def = _generatorOptions.defaultModifiers,\n defaultModifiers = _generatorOptions$def === void 0 ? [] : _generatorOptions$def,\n _generatorOptions$def2 = _generatorOptions.defaultOptions,\n defaultOptions = _generatorOptions$def2 === void 0 ? DEFAULT_OPTIONS : _generatorOptions$def2;\n return function createPopper(reference, popper, options) {\n if (options === void 0) {\n options = defaultOptions;\n }\n\n var state = {\n placement: 'bottom',\n orderedModifiers: [],\n options: Object.assign({}, DEFAULT_OPTIONS, defaultOptions),\n modifiersData: {},\n elements: {\n reference: reference,\n popper: popper\n },\n attributes: {},\n styles: {}\n };\n var effectCleanupFns = [];\n var isDestroyed = false;\n var instance = {\n state: state,\n setOptions: function setOptions(setOptionsAction) {\n var options = typeof setOptionsAction === 'function' ? setOptionsAction(state.options) : setOptionsAction;\n cleanupModifierEffects();\n state.options = Object.assign({}, defaultOptions, state.options, options);\n state.scrollParents = {\n reference: isElement(reference) ? listScrollParents(reference) : reference.contextElement ? listScrollParents(reference.contextElement) : [],\n popper: listScrollParents(popper)\n }; // Orders the modifiers based on their dependencies and `phase`\n // properties\n\n var orderedModifiers = orderModifiers(mergeByName([].concat(defaultModifiers, state.options.modifiers))); // Strip out disabled modifiers\n\n state.orderedModifiers = orderedModifiers.filter(function (m) {\n return m.enabled;\n });\n runModifierEffects();\n return instance.update();\n },\n // Sync update – it will always be executed, even if not necessary. This\n // is useful for low frequency updates where sync behavior simplifies the\n // logic.\n // For high frequency updates (e.g. `resize` and `scroll` events), always\n // prefer the async Popper#update method\n forceUpdate: function forceUpdate() {\n if (isDestroyed) {\n return;\n }\n\n var _state$elements = state.elements,\n reference = _state$elements.reference,\n popper = _state$elements.popper; // Don't proceed if `reference` or `popper` are not valid elements\n // anymore\n\n if (!areValidElements(reference, popper)) {\n return;\n } // Store the reference and popper rects to be read by modifiers\n\n\n state.rects = {\n reference: getCompositeRect(reference, getOffsetParent(popper), state.options.strategy === 'fixed'),\n popper: getLayoutRect(popper)\n }; // Modifiers have the ability to reset the current update cycle. The\n // most common use case for this is the `flip` modifier changing the\n // placement, which then needs to re-run all the modifiers, because the\n // logic was previously ran for the previous placement and is therefore\n // stale/incorrect\n\n state.reset = false;\n state.placement = state.options.placement; // On each update cycle, the `modifiersData` property for each modifier\n // is filled with the initial data specified by the modifier. This means\n // it doesn't persist and is fresh on each update.\n // To ensure persistent data, use `${name}#persistent`\n\n state.orderedModifiers.forEach(function (modifier) {\n return state.modifiersData[modifier.name] = Object.assign({}, modifier.data);\n });\n\n for (var index = 0; index < state.orderedModifiers.length; index++) {\n if (state.reset === true) {\n state.reset = false;\n index = -1;\n continue;\n }\n\n var _state$orderedModifie = state.orderedModifiers[index],\n fn = _state$orderedModifie.fn,\n _state$orderedModifie2 = _state$orderedModifie.options,\n _options = _state$orderedModifie2 === void 0 ? {} : _state$orderedModifie2,\n name = _state$orderedModifie.name;\n\n if (typeof fn === 'function') {\n state = fn({\n state: state,\n options: _options,\n name: name,\n instance: instance\n }) || state;\n }\n }\n },\n // Async and optimistically optimized update – it will not be executed if\n // not necessary (debounced to run at most once-per-tick)\n update: debounce(function () {\n return new Promise(function (resolve) {\n instance.forceUpdate();\n resolve(state);\n });\n }),\n destroy: function destroy() {\n cleanupModifierEffects();\n isDestroyed = true;\n }\n };\n\n if (!areValidElements(reference, popper)) {\n return instance;\n }\n\n instance.setOptions(options).then(function (state) {\n if (!isDestroyed && options.onFirstUpdate) {\n options.onFirstUpdate(state);\n }\n }); // Modifiers have the ability to execute arbitrary code before the first\n // update cycle runs. They will be executed in the same order as the update\n // cycle. This is useful when a modifier adds some persistent data that\n // other modifiers need to use, but the modifier is run after the dependent\n // one.\n\n function runModifierEffects() {\n state.orderedModifiers.forEach(function (_ref) {\n var name = _ref.name,\n _ref$options = _ref.options,\n options = _ref$options === void 0 ? {} : _ref$options,\n effect = _ref.effect;\n\n if (typeof effect === 'function') {\n var cleanupFn = effect({\n state: state,\n name: name,\n instance: instance,\n options: options\n });\n\n var noopFn = function noopFn() {};\n\n effectCleanupFns.push(cleanupFn || noopFn);\n }\n });\n }\n\n function cleanupModifierEffects() {\n effectCleanupFns.forEach(function (fn) {\n return fn();\n });\n effectCleanupFns = [];\n }\n\n return instance;\n };\n}\nexport var createPopper = /*#__PURE__*/popperGenerator(); // eslint-disable-next-line import/no-unused-modules\n\nexport { detectOverflow };","import { popperGenerator, detectOverflow } from \"./createPopper.js\";\nimport eventListeners from \"./modifiers/eventListeners.js\";\nimport popperOffsets from \"./modifiers/popperOffsets.js\";\nimport computeStyles from \"./modifiers/computeStyles.js\";\nimport applyStyles from \"./modifiers/applyStyles.js\";\nimport offset from \"./modifiers/offset.js\";\nimport flip from \"./modifiers/flip.js\";\nimport preventOverflow from \"./modifiers/preventOverflow.js\";\nimport arrow from \"./modifiers/arrow.js\";\nimport hide from \"./modifiers/hide.js\";\nvar defaultModifiers = [eventListeners, popperOffsets, computeStyles, applyStyles, offset, flip, preventOverflow, arrow, hide];\nvar createPopper = /*#__PURE__*/popperGenerator({\n defaultModifiers: defaultModifiers\n}); // eslint-disable-next-line import/no-unused-modules\n\nexport { createPopper, popperGenerator, defaultModifiers, detectOverflow }; // eslint-disable-next-line import/no-unused-modules\n\nexport { createPopper as createPopperLite } from \"./popper-lite.js\"; // eslint-disable-next-line import/no-unused-modules\n\nexport * from \"./modifiers/index.js\";","import { generateUtilityClass } from '../generateUtilityClass';\nimport { generateUtilityClasses } from '../generateUtilityClasses';\nconst COMPONENT_NAME = 'Popper';\nexport function getPopperUtilityClass(slot) {\n return generateUtilityClass(COMPONENT_NAME, slot);\n}\nexport const popperClasses = generateUtilityClasses(COMPONENT_NAME, ['root']);","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"anchorEl\", \"children\", \"direction\", \"disablePortal\", \"modifiers\", \"open\", \"placement\", \"popperOptions\", \"popperRef\", \"slotProps\", \"slots\", \"TransitionProps\", \"ownerState\"],\n _excluded2 = [\"anchorEl\", \"children\", \"container\", \"direction\", \"disablePortal\", \"keepMounted\", \"modifiers\", \"open\", \"placement\", \"popperOptions\", \"popperRef\", \"style\", \"transition\", \"slotProps\", \"slots\"];\nimport * as React from 'react';\nimport { chainPropTypes, HTMLElementType, refType, unstable_ownerDocument as ownerDocument, unstable_useEnhancedEffect as useEnhancedEffect, unstable_useForkRef as useForkRef } from '@mui/utils';\nimport { createPopper } from '@popperjs/core';\nimport PropTypes from 'prop-types';\nimport { unstable_composeClasses as composeClasses } from '../composeClasses';\nimport { Portal } from '../Portal';\nimport { getPopperUtilityClass } from './popperClasses';\nimport { useSlotProps } from '../utils';\nimport { useClassNamesOverride } from '../utils/ClassNameConfigurator';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nfunction flipPlacement(placement, direction) {\n if (direction === 'ltr') {\n return placement;\n }\n switch (placement) {\n case 'bottom-end':\n return 'bottom-start';\n case 'bottom-start':\n return 'bottom-end';\n case 'top-end':\n return 'top-start';\n case 'top-start':\n return 'top-end';\n default:\n return placement;\n }\n}\nfunction resolveAnchorEl(anchorEl) {\n return typeof anchorEl === 'function' ? anchorEl() : anchorEl;\n}\nfunction isHTMLElement(element) {\n return element.nodeType !== undefined;\n}\nfunction isVirtualElement(element) {\n return !isHTMLElement(element);\n}\nconst useUtilityClasses = () => {\n const slots = {\n root: ['root']\n };\n return composeClasses(slots, useClassNamesOverride(getPopperUtilityClass));\n};\nconst defaultPopperOptions = {};\nconst PopperTooltip = /*#__PURE__*/React.forwardRef(function PopperTooltip(props, forwardedRef) {\n var _slots$root;\n const {\n anchorEl,\n children,\n direction,\n disablePortal,\n modifiers,\n open,\n placement: initialPlacement,\n popperOptions,\n popperRef: popperRefProp,\n slotProps = {},\n slots = {},\n TransitionProps\n // @ts-ignore internal logic\n // prevent from spreading to DOM, it can come from the parent component e.g. Select.\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const tooltipRef = React.useRef(null);\n const ownRef = useForkRef(tooltipRef, forwardedRef);\n const popperRef = React.useRef(null);\n const handlePopperRef = useForkRef(popperRef, popperRefProp);\n const handlePopperRefRef = React.useRef(handlePopperRef);\n useEnhancedEffect(() => {\n handlePopperRefRef.current = handlePopperRef;\n }, [handlePopperRef]);\n React.useImperativeHandle(popperRefProp, () => popperRef.current, []);\n const rtlPlacement = flipPlacement(initialPlacement, direction);\n /**\n * placement initialized from prop but can change during lifetime if modifiers.flip.\n * modifiers.flip is essentially a flip for controlled/uncontrolled behavior\n */\n const [placement, setPlacement] = React.useState(rtlPlacement);\n const [resolvedAnchorElement, setResolvedAnchorElement] = React.useState(resolveAnchorEl(anchorEl));\n React.useEffect(() => {\n if (popperRef.current) {\n popperRef.current.forceUpdate();\n }\n });\n React.useEffect(() => {\n if (anchorEl) {\n setResolvedAnchorElement(resolveAnchorEl(anchorEl));\n }\n }, [anchorEl]);\n useEnhancedEffect(() => {\n if (!resolvedAnchorElement || !open) {\n return undefined;\n }\n const handlePopperUpdate = data => {\n setPlacement(data.placement);\n };\n if (process.env.NODE_ENV !== 'production') {\n if (resolvedAnchorElement && isHTMLElement(resolvedAnchorElement) && resolvedAnchorElement.nodeType === 1) {\n const box = resolvedAnchorElement.getBoundingClientRect();\n if (process.env.NODE_ENV !== 'test' && box.top === 0 && box.left === 0 && box.right === 0 && box.bottom === 0) {\n console.warn(['MUI: The `anchorEl` prop provided to the component is invalid.', 'The anchor element should be part of the document layout.', \"Make sure the element is present in the document or that it's not display none.\"].join('\\n'));\n }\n }\n }\n let popperModifiers = [{\n name: 'preventOverflow',\n options: {\n altBoundary: disablePortal\n }\n }, {\n name: 'flip',\n options: {\n altBoundary: disablePortal\n }\n }, {\n name: 'onUpdate',\n enabled: true,\n phase: 'afterWrite',\n fn: ({\n state\n }) => {\n handlePopperUpdate(state);\n }\n }];\n if (modifiers != null) {\n popperModifiers = popperModifiers.concat(modifiers);\n }\n if (popperOptions && popperOptions.modifiers != null) {\n popperModifiers = popperModifiers.concat(popperOptions.modifiers);\n }\n const popper = createPopper(resolvedAnchorElement, tooltipRef.current, _extends({\n placement: rtlPlacement\n }, popperOptions, {\n modifiers: popperModifiers\n }));\n handlePopperRefRef.current(popper);\n return () => {\n popper.destroy();\n handlePopperRefRef.current(null);\n };\n }, [resolvedAnchorElement, disablePortal, modifiers, open, popperOptions, rtlPlacement]);\n const childProps = {\n placement: placement\n };\n if (TransitionProps !== null) {\n childProps.TransitionProps = TransitionProps;\n }\n const classes = useUtilityClasses();\n const Root = (_slots$root = slots.root) != null ? _slots$root : 'div';\n const rootProps = useSlotProps({\n elementType: Root,\n externalSlotProps: slotProps.root,\n externalForwardedProps: other,\n additionalProps: {\n role: 'tooltip',\n ref: ownRef\n },\n ownerState: props,\n className: classes.root\n });\n return /*#__PURE__*/_jsx(Root, _extends({}, rootProps, {\n children: typeof children === 'function' ? children(childProps) : children\n }));\n});\n\n/**\n * Poppers rely on the 3rd party library [Popper.js](https://popper.js.org/docs/v2/) for positioning.\n *\n * Demos:\n *\n * - [Popper](https://mui.com/base-ui/react-popper/)\n *\n * API:\n *\n * - [Popper API](https://mui.com/base-ui/react-popper/components-api/#popper)\n */\nconst Popper = /*#__PURE__*/React.forwardRef(function Popper(props, forwardedRef) {\n const {\n anchorEl,\n children,\n container: containerProp,\n direction = 'ltr',\n disablePortal = false,\n keepMounted = false,\n modifiers,\n open,\n placement = 'bottom',\n popperOptions = defaultPopperOptions,\n popperRef,\n style,\n transition = false,\n slotProps = {},\n slots = {}\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded2);\n const [exited, setExited] = React.useState(true);\n const handleEnter = () => {\n setExited(false);\n };\n const handleExited = () => {\n setExited(true);\n };\n if (!keepMounted && !open && (!transition || exited)) {\n return null;\n }\n\n // If the container prop is provided, use that\n // If the anchorEl prop is provided, use its parent body element as the container\n // If neither are provided let the Modal take care of choosing the container\n let container;\n if (containerProp) {\n container = containerProp;\n } else if (anchorEl) {\n const resolvedAnchorEl = resolveAnchorEl(anchorEl);\n container = resolvedAnchorEl && isHTMLElement(resolvedAnchorEl) ? ownerDocument(resolvedAnchorEl).body : ownerDocument(null).body;\n }\n const display = !open && keepMounted && (!transition || exited) ? 'none' : undefined;\n const transitionProps = transition ? {\n in: open,\n onEnter: handleEnter,\n onExited: handleExited\n } : undefined;\n return /*#__PURE__*/_jsx(Portal, {\n disablePortal: disablePortal,\n container: container,\n children: /*#__PURE__*/_jsx(PopperTooltip, _extends({\n anchorEl: anchorEl,\n direction: direction,\n disablePortal: disablePortal,\n modifiers: modifiers,\n ref: forwardedRef,\n open: transition ? !exited : open,\n placement: placement,\n popperOptions: popperOptions,\n popperRef: popperRef,\n slotProps: slotProps,\n slots: slots\n }, other, {\n style: _extends({\n // Prevents scroll issue, waiting for Popper.js to add this style once initiated.\n position: 'fixed',\n // Fix Popper.js display issue\n top: 0,\n left: 0,\n display\n }, style),\n TransitionProps: transitionProps,\n children: children\n }))\n });\n});\nprocess.env.NODE_ENV !== \"production\" ? Popper.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * An HTML element, [virtualElement](https://popper.js.org/docs/v2/virtual-elements/),\n * or a function that returns either.\n * It's used to set the position of the popper.\n * The return value will passed as the reference object of the Popper instance.\n */\n anchorEl: chainPropTypes(PropTypes.oneOfType([HTMLElementType, PropTypes.object, PropTypes.func]), props => {\n if (props.open) {\n const resolvedAnchorEl = resolveAnchorEl(props.anchorEl);\n if (resolvedAnchorEl && isHTMLElement(resolvedAnchorEl) && resolvedAnchorEl.nodeType === 1) {\n const box = resolvedAnchorEl.getBoundingClientRect();\n if (process.env.NODE_ENV !== 'test' && box.top === 0 && box.left === 0 && box.right === 0 && box.bottom === 0) {\n return new Error(['MUI: The `anchorEl` prop provided to the component is invalid.', 'The anchor element should be part of the document layout.', \"Make sure the element is present in the document or that it's not display none.\"].join('\\n'));\n }\n } else if (!resolvedAnchorEl || typeof resolvedAnchorEl.getBoundingClientRect !== 'function' || isVirtualElement(resolvedAnchorEl) && resolvedAnchorEl.contextElement != null && resolvedAnchorEl.contextElement.nodeType !== 1) {\n return new Error(['MUI: The `anchorEl` prop provided to the component is invalid.', 'It should be an HTML element instance or a virtualElement ', '(https://popper.js.org/docs/v2/virtual-elements/).'].join('\\n'));\n }\n }\n return null;\n }),\n /**\n * Popper render function or node.\n */\n children: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.node, PropTypes.func]),\n /**\n * An HTML element or function that returns one.\n * The `container` will have the portal children appended to it.\n *\n * You can also provide a callback, which is called in a React layout effect.\n * This lets you set the container from a ref, and also makes server-side rendering possible.\n *\n * By default, it uses the body of the top-level document object,\n * so it's simply `document.body` most of the time.\n */\n container: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.func]),\n /**\n * Direction of the text.\n * @default 'ltr'\n */\n direction: PropTypes.oneOf(['ltr', 'rtl']),\n /**\n * The `children` will be under the DOM hierarchy of the parent component.\n * @default false\n */\n disablePortal: PropTypes.bool,\n /**\n * Always keep the children in the DOM.\n * This prop can be useful in SEO situation or\n * when you want to maximize the responsiveness of the Popper.\n * @default false\n */\n keepMounted: PropTypes.bool,\n /**\n * Popper.js is based on a \"plugin-like\" architecture,\n * most of its features are fully encapsulated \"modifiers\".\n *\n * A modifier is a function that is called each time Popper.js needs to\n * compute the position of the popper.\n * For this reason, modifiers should be very performant to avoid bottlenecks.\n * To learn how to create a modifier, [read the modifiers documentation](https://popper.js.org/docs/v2/modifiers/).\n */\n modifiers: PropTypes.arrayOf(PropTypes.shape({\n data: PropTypes.object,\n effect: PropTypes.func,\n enabled: PropTypes.bool,\n fn: PropTypes.func,\n name: PropTypes.any,\n options: PropTypes.object,\n phase: PropTypes.oneOf(['afterMain', 'afterRead', 'afterWrite', 'beforeMain', 'beforeRead', 'beforeWrite', 'main', 'read', 'write']),\n requires: PropTypes.arrayOf(PropTypes.string),\n requiresIfExists: PropTypes.arrayOf(PropTypes.string)\n })),\n /**\n * If `true`, the component is shown.\n */\n open: PropTypes.bool.isRequired,\n /**\n * Popper placement.\n * @default 'bottom'\n */\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n /**\n * Options provided to the [`Popper.js`](https://popper.js.org/docs/v2/constructors/#options) instance.\n * @default {}\n */\n popperOptions: PropTypes.shape({\n modifiers: PropTypes.array,\n onFirstUpdate: PropTypes.func,\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n strategy: PropTypes.oneOf(['absolute', 'fixed'])\n }),\n /**\n * A ref that points to the used popper instance.\n */\n popperRef: refType,\n /**\n * The props used for each slot inside the Popper.\n * @default {}\n */\n slotProps: PropTypes.shape({\n root: PropTypes.oneOfType([PropTypes.func, PropTypes.object])\n }),\n /**\n * The components used for each slot inside the Popper.\n * Either a string to use a HTML element or a component.\n * @default {}\n */\n slots: PropTypes.shape({\n root: PropTypes.elementType\n }),\n /**\n * Help supporting a react-transition-group/Transition component.\n * @default false\n */\n transition: PropTypes.bool\n} : void 0;\nexport { Popper };","'use client';\n\nimport * as React from 'react';\nimport { useTheme as useThemeSystem } from '@mui/system';\nimport defaultTheme from './defaultTheme';\nimport THEME_ID from './identifier';\nexport default function useTheme() {\n const theme = useThemeSystem(defaultTheme);\n if (process.env.NODE_ENV !== 'production') {\n // eslint-disable-next-line react-hooks/rules-of-hooks\n React.useDebugValue(theme);\n }\n return theme[THEME_ID] || theme;\n}","export default function _setPrototypeOf(o, p) {\n _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function _setPrototypeOf(o, p) {\n o.__proto__ = p;\n return o;\n };\n return _setPrototypeOf(o, p);\n}","import setPrototypeOf from \"./setPrototypeOf.js\";\nexport default function _inheritsLoose(subClass, superClass) {\n subClass.prototype = Object.create(superClass.prototype);\n subClass.prototype.constructor = subClass;\n setPrototypeOf(subClass, superClass);\n}","export default {\n disabled: false\n};","import PropTypes from 'prop-types';\nexport var timeoutsShape = process.env.NODE_ENV !== 'production' ? PropTypes.oneOfType([PropTypes.number, PropTypes.shape({\n enter: PropTypes.number,\n exit: PropTypes.number,\n appear: PropTypes.number\n}).isRequired]) : null;\nexport var classNamesShape = process.env.NODE_ENV !== 'production' ? PropTypes.oneOfType([PropTypes.string, PropTypes.shape({\n enter: PropTypes.string,\n exit: PropTypes.string,\n active: PropTypes.string\n}), PropTypes.shape({\n enter: PropTypes.string,\n enterDone: PropTypes.string,\n enterActive: PropTypes.string,\n exit: PropTypes.string,\n exitDone: PropTypes.string,\n exitActive: PropTypes.string\n})]) : null;","import React from 'react';\nexport default React.createContext(null);","export var forceReflow = function forceReflow(node) {\n return node.scrollTop;\n};","import _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _inheritsLoose from \"@babel/runtime/helpers/esm/inheritsLoose\";\nimport PropTypes from 'prop-types';\nimport React from 'react';\nimport ReactDOM from 'react-dom';\nimport config from './config';\nimport { timeoutsShape } from './utils/PropTypes';\nimport TransitionGroupContext from './TransitionGroupContext';\nimport { forceReflow } from './utils/reflow';\nexport var UNMOUNTED = 'unmounted';\nexport var EXITED = 'exited';\nexport var ENTERING = 'entering';\nexport var ENTERED = 'entered';\nexport var EXITING = 'exiting';\n/**\n * The Transition component lets you describe a transition from one component\n * state to another _over time_ with a simple declarative API. Most commonly\n * it's used to animate the mounting and unmounting of a component, but can also\n * be used to describe in-place transition states as well.\n *\n * ---\n *\n * **Note**: `Transition` is a platform-agnostic base component. If you're using\n * transitions in CSS, you'll probably want to use\n * [`CSSTransition`](https://reactcommunity.org/react-transition-group/css-transition)\n * instead. It inherits all the features of `Transition`, but contains\n * additional features necessary to play nice with CSS transitions (hence the\n * name of the component).\n *\n * ---\n *\n * By default the `Transition` component does not alter the behavior of the\n * component it renders, it only tracks \"enter\" and \"exit\" states for the\n * components. It's up to you to give meaning and effect to those states. For\n * example we can add styles to a component when it enters or exits:\n *\n * ```jsx\n * import { Transition } from 'react-transition-group';\n *\n * const duration = 300;\n *\n * const defaultStyle = {\n * transition: `opacity ${duration}ms ease-in-out`,\n * opacity: 0,\n * }\n *\n * const transitionStyles = {\n * entering: { opacity: 1 },\n * entered: { opacity: 1 },\n * exiting: { opacity: 0 },\n * exited: { opacity: 0 },\n * };\n *\n * const Fade = ({ in: inProp }) => (\n * \n * {state => (\n *
    \n * I'm a fade Transition!\n *
    \n * )}\n *
    \n * );\n * ```\n *\n * There are 4 main states a Transition can be in:\n * - `'entering'`\n * - `'entered'`\n * - `'exiting'`\n * - `'exited'`\n *\n * Transition state is toggled via the `in` prop. When `true` the component\n * begins the \"Enter\" stage. During this stage, the component will shift from\n * its current transition state, to `'entering'` for the duration of the\n * transition and then to the `'entered'` stage once it's complete. Let's take\n * the following example (we'll use the\n * [useState](https://reactjs.org/docs/hooks-reference.html#usestate) hook):\n *\n * ```jsx\n * function App() {\n * const [inProp, setInProp] = useState(false);\n * return (\n *
    \n * \n * {state => (\n * // ...\n * )}\n * \n * \n *
    \n * );\n * }\n * ```\n *\n * When the button is clicked the component will shift to the `'entering'` state\n * and stay there for 500ms (the value of `timeout`) before it finally switches\n * to `'entered'`.\n *\n * When `in` is `false` the same thing happens except the state moves from\n * `'exiting'` to `'exited'`.\n */\n\nvar Transition = /*#__PURE__*/function (_React$Component) {\n _inheritsLoose(Transition, _React$Component);\n\n function Transition(props, context) {\n var _this;\n\n _this = _React$Component.call(this, props, context) || this;\n var parentGroup = context; // In the context of a TransitionGroup all enters are really appears\n\n var appear = parentGroup && !parentGroup.isMounting ? props.enter : props.appear;\n var initialStatus;\n _this.appearStatus = null;\n\n if (props.in) {\n if (appear) {\n initialStatus = EXITED;\n _this.appearStatus = ENTERING;\n } else {\n initialStatus = ENTERED;\n }\n } else {\n if (props.unmountOnExit || props.mountOnEnter) {\n initialStatus = UNMOUNTED;\n } else {\n initialStatus = EXITED;\n }\n }\n\n _this.state = {\n status: initialStatus\n };\n _this.nextCallback = null;\n return _this;\n }\n\n Transition.getDerivedStateFromProps = function getDerivedStateFromProps(_ref, prevState) {\n var nextIn = _ref.in;\n\n if (nextIn && prevState.status === UNMOUNTED) {\n return {\n status: EXITED\n };\n }\n\n return null;\n } // getSnapshotBeforeUpdate(prevProps) {\n // let nextStatus = null\n // if (prevProps !== this.props) {\n // const { status } = this.state\n // if (this.props.in) {\n // if (status !== ENTERING && status !== ENTERED) {\n // nextStatus = ENTERING\n // }\n // } else {\n // if (status === ENTERING || status === ENTERED) {\n // nextStatus = EXITING\n // }\n // }\n // }\n // return { nextStatus }\n // }\n ;\n\n var _proto = Transition.prototype;\n\n _proto.componentDidMount = function componentDidMount() {\n this.updateStatus(true, this.appearStatus);\n };\n\n _proto.componentDidUpdate = function componentDidUpdate(prevProps) {\n var nextStatus = null;\n\n if (prevProps !== this.props) {\n var status = this.state.status;\n\n if (this.props.in) {\n if (status !== ENTERING && status !== ENTERED) {\n nextStatus = ENTERING;\n }\n } else {\n if (status === ENTERING || status === ENTERED) {\n nextStatus = EXITING;\n }\n }\n }\n\n this.updateStatus(false, nextStatus);\n };\n\n _proto.componentWillUnmount = function componentWillUnmount() {\n this.cancelNextCallback();\n };\n\n _proto.getTimeouts = function getTimeouts() {\n var timeout = this.props.timeout;\n var exit, enter, appear;\n exit = enter = appear = timeout;\n\n if (timeout != null && typeof timeout !== 'number') {\n exit = timeout.exit;\n enter = timeout.enter; // TODO: remove fallback for next major\n\n appear = timeout.appear !== undefined ? timeout.appear : enter;\n }\n\n return {\n exit: exit,\n enter: enter,\n appear: appear\n };\n };\n\n _proto.updateStatus = function updateStatus(mounting, nextStatus) {\n if (mounting === void 0) {\n mounting = false;\n }\n\n if (nextStatus !== null) {\n // nextStatus will always be ENTERING or EXITING.\n this.cancelNextCallback();\n\n if (nextStatus === ENTERING) {\n if (this.props.unmountOnExit || this.props.mountOnEnter) {\n var node = this.props.nodeRef ? this.props.nodeRef.current : ReactDOM.findDOMNode(this); // https://github.com/reactjs/react-transition-group/pull/749\n // With unmountOnExit or mountOnEnter, the enter animation should happen at the transition between `exited` and `entering`.\n // To make the animation happen, we have to separate each rendering and avoid being processed as batched.\n\n if (node) forceReflow(node);\n }\n\n this.performEnter(mounting);\n } else {\n this.performExit();\n }\n } else if (this.props.unmountOnExit && this.state.status === EXITED) {\n this.setState({\n status: UNMOUNTED\n });\n }\n };\n\n _proto.performEnter = function performEnter(mounting) {\n var _this2 = this;\n\n var enter = this.props.enter;\n var appearing = this.context ? this.context.isMounting : mounting;\n\n var _ref2 = this.props.nodeRef ? [appearing] : [ReactDOM.findDOMNode(this), appearing],\n maybeNode = _ref2[0],\n maybeAppearing = _ref2[1];\n\n var timeouts = this.getTimeouts();\n var enterTimeout = appearing ? timeouts.appear : timeouts.enter; // no enter animation skip right to ENTERED\n // if we are mounting and running this it means appear _must_ be set\n\n if (!mounting && !enter || config.disabled) {\n this.safeSetState({\n status: ENTERED\n }, function () {\n _this2.props.onEntered(maybeNode);\n });\n return;\n }\n\n this.props.onEnter(maybeNode, maybeAppearing);\n this.safeSetState({\n status: ENTERING\n }, function () {\n _this2.props.onEntering(maybeNode, maybeAppearing);\n\n _this2.onTransitionEnd(enterTimeout, function () {\n _this2.safeSetState({\n status: ENTERED\n }, function () {\n _this2.props.onEntered(maybeNode, maybeAppearing);\n });\n });\n });\n };\n\n _proto.performExit = function performExit() {\n var _this3 = this;\n\n var exit = this.props.exit;\n var timeouts = this.getTimeouts();\n var maybeNode = this.props.nodeRef ? undefined : ReactDOM.findDOMNode(this); // no exit animation skip right to EXITED\n\n if (!exit || config.disabled) {\n this.safeSetState({\n status: EXITED\n }, function () {\n _this3.props.onExited(maybeNode);\n });\n return;\n }\n\n this.props.onExit(maybeNode);\n this.safeSetState({\n status: EXITING\n }, function () {\n _this3.props.onExiting(maybeNode);\n\n _this3.onTransitionEnd(timeouts.exit, function () {\n _this3.safeSetState({\n status: EXITED\n }, function () {\n _this3.props.onExited(maybeNode);\n });\n });\n });\n };\n\n _proto.cancelNextCallback = function cancelNextCallback() {\n if (this.nextCallback !== null) {\n this.nextCallback.cancel();\n this.nextCallback = null;\n }\n };\n\n _proto.safeSetState = function safeSetState(nextState, callback) {\n // This shouldn't be necessary, but there are weird race conditions with\n // setState callbacks and unmounting in testing, so always make sure that\n // we can cancel any pending setState callbacks after we unmount.\n callback = this.setNextCallback(callback);\n this.setState(nextState, callback);\n };\n\n _proto.setNextCallback = function setNextCallback(callback) {\n var _this4 = this;\n\n var active = true;\n\n this.nextCallback = function (event) {\n if (active) {\n active = false;\n _this4.nextCallback = null;\n callback(event);\n }\n };\n\n this.nextCallback.cancel = function () {\n active = false;\n };\n\n return this.nextCallback;\n };\n\n _proto.onTransitionEnd = function onTransitionEnd(timeout, handler) {\n this.setNextCallback(handler);\n var node = this.props.nodeRef ? this.props.nodeRef.current : ReactDOM.findDOMNode(this);\n var doesNotHaveTimeoutOrListener = timeout == null && !this.props.addEndListener;\n\n if (!node || doesNotHaveTimeoutOrListener) {\n setTimeout(this.nextCallback, 0);\n return;\n }\n\n if (this.props.addEndListener) {\n var _ref3 = this.props.nodeRef ? [this.nextCallback] : [node, this.nextCallback],\n maybeNode = _ref3[0],\n maybeNextCallback = _ref3[1];\n\n this.props.addEndListener(maybeNode, maybeNextCallback);\n }\n\n if (timeout != null) {\n setTimeout(this.nextCallback, timeout);\n }\n };\n\n _proto.render = function render() {\n var status = this.state.status;\n\n if (status === UNMOUNTED) {\n return null;\n }\n\n var _this$props = this.props,\n children = _this$props.children,\n _in = _this$props.in,\n _mountOnEnter = _this$props.mountOnEnter,\n _unmountOnExit = _this$props.unmountOnExit,\n _appear = _this$props.appear,\n _enter = _this$props.enter,\n _exit = _this$props.exit,\n _timeout = _this$props.timeout,\n _addEndListener = _this$props.addEndListener,\n _onEnter = _this$props.onEnter,\n _onEntering = _this$props.onEntering,\n _onEntered = _this$props.onEntered,\n _onExit = _this$props.onExit,\n _onExiting = _this$props.onExiting,\n _onExited = _this$props.onExited,\n _nodeRef = _this$props.nodeRef,\n childProps = _objectWithoutPropertiesLoose(_this$props, [\"children\", \"in\", \"mountOnEnter\", \"unmountOnExit\", \"appear\", \"enter\", \"exit\", \"timeout\", \"addEndListener\", \"onEnter\", \"onEntering\", \"onEntered\", \"onExit\", \"onExiting\", \"onExited\", \"nodeRef\"]);\n\n return (\n /*#__PURE__*/\n // allows for nested Transitions\n React.createElement(TransitionGroupContext.Provider, {\n value: null\n }, typeof children === 'function' ? children(status, childProps) : React.cloneElement(React.Children.only(children), childProps))\n );\n };\n\n return Transition;\n}(React.Component);\n\nTransition.contextType = TransitionGroupContext;\nTransition.propTypes = process.env.NODE_ENV !== \"production\" ? {\n /**\n * A React reference to DOM element that need to transition:\n * https://stackoverflow.com/a/51127130/4671932\n *\n * - When `nodeRef` prop is used, `node` is not passed to callback functions\n * (e.g. `onEnter`) because user already has direct access to the node.\n * - When changing `key` prop of `Transition` in a `TransitionGroup` a new\n * `nodeRef` need to be provided to `Transition` with changed `key` prop\n * (see\n * [test/CSSTransition-test.js](https://github.com/reactjs/react-transition-group/blob/13435f897b3ab71f6e19d724f145596f5910581c/test/CSSTransition-test.js#L362-L437)).\n */\n nodeRef: PropTypes.shape({\n current: typeof Element === 'undefined' ? PropTypes.any : function (propValue, key, componentName, location, propFullName, secret) {\n var value = propValue[key];\n return PropTypes.instanceOf(value && 'ownerDocument' in value ? value.ownerDocument.defaultView.Element : Element)(propValue, key, componentName, location, propFullName, secret);\n }\n }),\n\n /**\n * A `function` child can be used instead of a React element. This function is\n * called with the current transition status (`'entering'`, `'entered'`,\n * `'exiting'`, `'exited'`), which can be used to apply context\n * specific props to a component.\n *\n * ```jsx\n * \n * {state => (\n * \n * )}\n * \n * ```\n */\n children: PropTypes.oneOfType([PropTypes.func.isRequired, PropTypes.element.isRequired]).isRequired,\n\n /**\n * Show the component; triggers the enter or exit states\n */\n in: PropTypes.bool,\n\n /**\n * By default the child component is mounted immediately along with\n * the parent `Transition` component. If you want to \"lazy mount\" the component on the\n * first `in={true}` you can set `mountOnEnter`. After the first enter transition the component will stay\n * mounted, even on \"exited\", unless you also specify `unmountOnExit`.\n */\n mountOnEnter: PropTypes.bool,\n\n /**\n * By default the child component stays mounted after it reaches the `'exited'` state.\n * Set `unmountOnExit` if you'd prefer to unmount the component after it finishes exiting.\n */\n unmountOnExit: PropTypes.bool,\n\n /**\n * By default the child component does not perform the enter transition when\n * it first mounts, regardless of the value of `in`. If you want this\n * behavior, set both `appear` and `in` to `true`.\n *\n * > **Note**: there are no special appear states like `appearing`/`appeared`, this prop\n * > only adds an additional enter transition. However, in the\n * > `` component that first enter transition does result in\n * > additional `.appear-*` classes, that way you can choose to style it\n * > differently.\n */\n appear: PropTypes.bool,\n\n /**\n * Enable or disable enter transitions.\n */\n enter: PropTypes.bool,\n\n /**\n * Enable or disable exit transitions.\n */\n exit: PropTypes.bool,\n\n /**\n * The duration of the transition, in milliseconds.\n * Required unless `addEndListener` is provided.\n *\n * You may specify a single timeout for all transitions:\n *\n * ```jsx\n * timeout={500}\n * ```\n *\n * or individually:\n *\n * ```jsx\n * timeout={{\n * appear: 500,\n * enter: 300,\n * exit: 500,\n * }}\n * ```\n *\n * - `appear` defaults to the value of `enter`\n * - `enter` defaults to `0`\n * - `exit` defaults to `0`\n *\n * @type {number | { enter?: number, exit?: number, appear?: number }}\n */\n timeout: function timeout(props) {\n var pt = timeoutsShape;\n if (!props.addEndListener) pt = pt.isRequired;\n\n for (var _len = arguments.length, args = new Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) {\n args[_key - 1] = arguments[_key];\n }\n\n return pt.apply(void 0, [props].concat(args));\n },\n\n /**\n * Add a custom transition end trigger. Called with the transitioning\n * DOM node and a `done` callback. Allows for more fine grained transition end\n * logic. Timeouts are still used as a fallback if provided.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * ```jsx\n * addEndListener={(node, done) => {\n * // use the css transitionend event to mark the finish of a transition\n * node.addEventListener('transitionend', done, false);\n * }}\n * ```\n */\n addEndListener: PropTypes.func,\n\n /**\n * Callback fired before the \"entering\" status is applied. An extra parameter\n * `isAppearing` is supplied to indicate if the enter stage is occurring on the initial mount\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement, isAppearing: bool) -> void\n */\n onEnter: PropTypes.func,\n\n /**\n * Callback fired after the \"entering\" status is applied. An extra parameter\n * `isAppearing` is supplied to indicate if the enter stage is occurring on the initial mount\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement, isAppearing: bool)\n */\n onEntering: PropTypes.func,\n\n /**\n * Callback fired after the \"entered\" status is applied. An extra parameter\n * `isAppearing` is supplied to indicate if the enter stage is occurring on the initial mount\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement, isAppearing: bool) -> void\n */\n onEntered: PropTypes.func,\n\n /**\n * Callback fired before the \"exiting\" status is applied.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement) -> void\n */\n onExit: PropTypes.func,\n\n /**\n * Callback fired after the \"exiting\" status is applied.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement) -> void\n */\n onExiting: PropTypes.func,\n\n /**\n * Callback fired after the \"exited\" status is applied.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed\n *\n * @type Function(node: HtmlElement) -> void\n */\n onExited: PropTypes.func\n} : {}; // Name the function so it is clearer in the documentation\n\nfunction noop() {}\n\nTransition.defaultProps = {\n in: false,\n mountOnEnter: false,\n unmountOnExit: false,\n appear: false,\n enter: true,\n exit: true,\n onEnter: noop,\n onEntering: noop,\n onEntered: noop,\n onExit: noop,\n onExiting: noop,\n onExited: noop\n};\nTransition.UNMOUNTED = UNMOUNTED;\nTransition.EXITED = EXITED;\nTransition.ENTERING = ENTERING;\nTransition.ENTERED = ENTERED;\nTransition.EXITING = EXITING;\nexport default Transition;","export const reflow = node => node.scrollTop;\nexport function getTransitionProps(props, options) {\n var _style$transitionDura, _style$transitionTimi;\n const {\n timeout,\n easing,\n style = {}\n } = props;\n return {\n duration: (_style$transitionDura = style.transitionDuration) != null ? _style$transitionDura : typeof timeout === 'number' ? timeout : timeout[options.mode] || 0,\n easing: (_style$transitionTimi = style.transitionTimingFunction) != null ? _style$transitionTimi : typeof easing === 'object' ? easing[options.mode] : easing,\n delay: style.transitionDelay\n };\n}","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"addEndListener\", \"appear\", \"children\", \"easing\", \"in\", \"onEnter\", \"onEntered\", \"onEntering\", \"onExit\", \"onExited\", \"onExiting\", \"style\", \"timeout\", \"TransitionComponent\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport { elementAcceptingRef, unstable_useTimeout as useTimeout } from '@mui/utils';\nimport { Transition } from 'react-transition-group';\nimport useTheme from '../styles/useTheme';\nimport { getTransitionProps, reflow } from '../transitions/utils';\nimport useForkRef from '../utils/useForkRef';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nfunction getScale(value) {\n return `scale(${value}, ${value ** 2})`;\n}\nconst styles = {\n entering: {\n opacity: 1,\n transform: getScale(1)\n },\n entered: {\n opacity: 1,\n transform: 'none'\n }\n};\n\n/*\n TODO v6: remove\n Conditionally apply a workaround for the CSS transition bug in Safari 15.4 / WebKit browsers.\n */\nconst isWebKit154 = typeof navigator !== 'undefined' && /^((?!chrome|android).)*(safari|mobile)/i.test(navigator.userAgent) && /(os |version\\/)15(.|_)4/i.test(navigator.userAgent);\n\n/**\n * The Grow transition is used by the [Tooltip](/material-ui/react-tooltip/) and\n * [Popover](/material-ui/react-popover/) components.\n * It uses [react-transition-group](https://github.com/reactjs/react-transition-group) internally.\n */\nconst Grow = /*#__PURE__*/React.forwardRef(function Grow(props, ref) {\n const {\n addEndListener,\n appear = true,\n children,\n easing,\n in: inProp,\n onEnter,\n onEntered,\n onEntering,\n onExit,\n onExited,\n onExiting,\n style,\n timeout = 'auto',\n // eslint-disable-next-line react/prop-types\n TransitionComponent = Transition\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const timer = useTimeout();\n const autoTimeout = React.useRef();\n const theme = useTheme();\n const nodeRef = React.useRef(null);\n const handleRef = useForkRef(nodeRef, children.ref, ref);\n const normalizedTransitionCallback = callback => maybeIsAppearing => {\n if (callback) {\n const node = nodeRef.current;\n\n // onEnterXxx and onExitXxx callbacks have a different arguments.length value.\n if (maybeIsAppearing === undefined) {\n callback(node);\n } else {\n callback(node, maybeIsAppearing);\n }\n }\n };\n const handleEntering = normalizedTransitionCallback(onEntering);\n const handleEnter = normalizedTransitionCallback((node, isAppearing) => {\n reflow(node); // So the animation always start from the start.\n\n const {\n duration: transitionDuration,\n delay,\n easing: transitionTimingFunction\n } = getTransitionProps({\n style,\n timeout,\n easing\n }, {\n mode: 'enter'\n });\n let duration;\n if (timeout === 'auto') {\n duration = theme.transitions.getAutoHeightDuration(node.clientHeight);\n autoTimeout.current = duration;\n } else {\n duration = transitionDuration;\n }\n node.style.transition = [theme.transitions.create('opacity', {\n duration,\n delay\n }), theme.transitions.create('transform', {\n duration: isWebKit154 ? duration : duration * 0.666,\n delay,\n easing: transitionTimingFunction\n })].join(',');\n if (onEnter) {\n onEnter(node, isAppearing);\n }\n });\n const handleEntered = normalizedTransitionCallback(onEntered);\n const handleExiting = normalizedTransitionCallback(onExiting);\n const handleExit = normalizedTransitionCallback(node => {\n const {\n duration: transitionDuration,\n delay,\n easing: transitionTimingFunction\n } = getTransitionProps({\n style,\n timeout,\n easing\n }, {\n mode: 'exit'\n });\n let duration;\n if (timeout === 'auto') {\n duration = theme.transitions.getAutoHeightDuration(node.clientHeight);\n autoTimeout.current = duration;\n } else {\n duration = transitionDuration;\n }\n node.style.transition = [theme.transitions.create('opacity', {\n duration,\n delay\n }), theme.transitions.create('transform', {\n duration: isWebKit154 ? duration : duration * 0.666,\n delay: isWebKit154 ? delay : delay || duration * 0.333,\n easing: transitionTimingFunction\n })].join(',');\n node.style.opacity = 0;\n node.style.transform = getScale(0.75);\n if (onExit) {\n onExit(node);\n }\n });\n const handleExited = normalizedTransitionCallback(onExited);\n const handleAddEndListener = next => {\n if (timeout === 'auto') {\n timer.start(autoTimeout.current || 0, next);\n }\n if (addEndListener) {\n // Old call signature before `react-transition-group` implemented `nodeRef`\n addEndListener(nodeRef.current, next);\n }\n };\n return /*#__PURE__*/_jsx(TransitionComponent, _extends({\n appear: appear,\n in: inProp,\n nodeRef: nodeRef,\n onEnter: handleEnter,\n onEntered: handleEntered,\n onEntering: handleEntering,\n onExit: handleExit,\n onExited: handleExited,\n onExiting: handleExiting,\n addEndListener: handleAddEndListener,\n timeout: timeout === 'auto' ? null : timeout\n }, other, {\n children: (state, childProps) => {\n return /*#__PURE__*/React.cloneElement(children, _extends({\n style: _extends({\n opacity: 0,\n transform: getScale(0.75),\n visibility: state === 'exited' && !inProp ? 'hidden' : undefined\n }, styles[state], style, children.props.style),\n ref: handleRef\n }, childProps));\n }\n }));\n});\nprocess.env.NODE_ENV !== \"production\" ? Grow.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the d.ts file and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * Add a custom transition end trigger. Called with the transitioning DOM\n * node and a done callback. Allows for more fine grained transition end\n * logic. Note: Timeouts are still used as a fallback if provided.\n */\n addEndListener: PropTypes.func,\n /**\n * Perform the enter transition when it first mounts if `in` is also `true`.\n * Set this to `false` to disable this behavior.\n * @default true\n */\n appear: PropTypes.bool,\n /**\n * A single child content element.\n */\n children: elementAcceptingRef.isRequired,\n /**\n * The transition timing function.\n * You may specify a single easing or a object containing enter and exit values.\n */\n easing: PropTypes.oneOfType([PropTypes.shape({\n enter: PropTypes.string,\n exit: PropTypes.string\n }), PropTypes.string]),\n /**\n * If `true`, the component will transition in.\n */\n in: PropTypes.bool,\n /**\n * @ignore\n */\n onEnter: PropTypes.func,\n /**\n * @ignore\n */\n onEntered: PropTypes.func,\n /**\n * @ignore\n */\n onEntering: PropTypes.func,\n /**\n * @ignore\n */\n onExit: PropTypes.func,\n /**\n * @ignore\n */\n onExited: PropTypes.func,\n /**\n * @ignore\n */\n onExiting: PropTypes.func,\n /**\n * @ignore\n */\n style: PropTypes.object,\n /**\n * The duration for the transition, in milliseconds.\n * You may specify a single timeout for all transitions, or individually with an object.\n *\n * Set to 'auto' to automatically calculate transition time based on height.\n * @default 'auto'\n */\n timeout: PropTypes.oneOfType([PropTypes.oneOf(['auto']), PropTypes.number, PropTypes.shape({\n appear: PropTypes.number,\n enter: PropTypes.number,\n exit: PropTypes.number\n })])\n} : void 0;\nGrow.muiSupportAuto = true;\nexport default Grow;","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"anchorEl\", \"component\", \"components\", \"componentsProps\", \"container\", \"disablePortal\", \"keepMounted\", \"modifiers\", \"open\", \"placement\", \"popperOptions\", \"popperRef\", \"transition\", \"slots\", \"slotProps\"];\nimport { Popper as BasePopper } from '@mui/base/Popper';\nimport { useThemeWithoutDefault as useTheme } from '@mui/system';\nimport { HTMLElementType, refType } from '@mui/utils';\nimport PropTypes from 'prop-types';\nimport * as React from 'react';\nimport { styled, useThemeProps } from '../styles';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nconst PopperRoot = styled(BasePopper, {\n name: 'MuiPopper',\n slot: 'Root',\n overridesResolver: (props, styles) => styles.root\n})({});\n\n/**\n *\n * Demos:\n *\n * - [Autocomplete](https://mui.com/material-ui/react-autocomplete/)\n * - [Menu](https://mui.com/material-ui/react-menu/)\n * - [Popper](https://mui.com/material-ui/react-popper/)\n *\n * API:\n *\n * - [Popper API](https://mui.com/material-ui/api/popper/)\n */\nconst Popper = /*#__PURE__*/React.forwardRef(function Popper(inProps, ref) {\n var _slots$root;\n const theme = useTheme();\n const props = useThemeProps({\n props: inProps,\n name: 'MuiPopper'\n });\n const {\n anchorEl,\n component,\n components,\n componentsProps,\n container,\n disablePortal,\n keepMounted,\n modifiers,\n open,\n placement,\n popperOptions,\n popperRef,\n transition,\n slots,\n slotProps\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const RootComponent = (_slots$root = slots == null ? void 0 : slots.root) != null ? _slots$root : components == null ? void 0 : components.Root;\n const otherProps = _extends({\n anchorEl,\n container,\n disablePortal,\n keepMounted,\n modifiers,\n open,\n placement,\n popperOptions,\n popperRef,\n transition\n }, other);\n return /*#__PURE__*/_jsx(PopperRoot, _extends({\n as: component,\n direction: theme == null ? void 0 : theme.direction,\n slots: {\n root: RootComponent\n },\n slotProps: slotProps != null ? slotProps : componentsProps\n }, otherProps, {\n ref: ref\n }));\n});\nprocess.env.NODE_ENV !== \"production\" ? Popper.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * An HTML element, [virtualElement](https://popper.js.org/docs/v2/virtual-elements/),\n * or a function that returns either.\n * It's used to set the position of the popper.\n * The return value will passed as the reference object of the Popper instance.\n */\n anchorEl: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.object, PropTypes.func]),\n /**\n * Popper render function or node.\n */\n children: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.node, PropTypes.func]),\n /**\n * The component used for the root node.\n * Either a string to use a HTML element or a component.\n */\n component: PropTypes.elementType,\n /**\n * The components used for each slot inside the Popper.\n * Either a string to use a HTML element or a component.\n * @default {}\n */\n components: PropTypes.shape({\n Root: PropTypes.elementType\n }),\n /**\n * The props used for each slot inside the Popper.\n * @default {}\n */\n componentsProps: PropTypes.shape({\n root: PropTypes.oneOfType([PropTypes.func, PropTypes.object])\n }),\n /**\n * An HTML element or function that returns one.\n * The `container` will have the portal children appended to it.\n *\n * You can also provide a callback, which is called in a React layout effect.\n * This lets you set the container from a ref, and also makes server-side rendering possible.\n *\n * By default, it uses the body of the top-level document object,\n * so it's simply `document.body` most of the time.\n */\n container: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.func]),\n /**\n * The `children` will be under the DOM hierarchy of the parent component.\n * @default false\n */\n disablePortal: PropTypes.bool,\n /**\n * Always keep the children in the DOM.\n * This prop can be useful in SEO situation or\n * when you want to maximize the responsiveness of the Popper.\n * @default false\n */\n keepMounted: PropTypes.bool,\n /**\n * Popper.js is based on a \"plugin-like\" architecture,\n * most of its features are fully encapsulated \"modifiers\".\n *\n * A modifier is a function that is called each time Popper.js needs to\n * compute the position of the popper.\n * For this reason, modifiers should be very performant to avoid bottlenecks.\n * To learn how to create a modifier, [read the modifiers documentation](https://popper.js.org/docs/v2/modifiers/).\n */\n modifiers: PropTypes.arrayOf(PropTypes.shape({\n data: PropTypes.object,\n effect: PropTypes.func,\n enabled: PropTypes.bool,\n fn: PropTypes.func,\n name: PropTypes.any,\n options: PropTypes.object,\n phase: PropTypes.oneOf(['afterMain', 'afterRead', 'afterWrite', 'beforeMain', 'beforeRead', 'beforeWrite', 'main', 'read', 'write']),\n requires: PropTypes.arrayOf(PropTypes.string),\n requiresIfExists: PropTypes.arrayOf(PropTypes.string)\n })),\n /**\n * If `true`, the component is shown.\n */\n open: PropTypes.bool.isRequired,\n /**\n * Popper placement.\n * @default 'bottom'\n */\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n /**\n * Options provided to the [`Popper.js`](https://popper.js.org/docs/v2/constructors/#options) instance.\n * @default {}\n */\n popperOptions: PropTypes.shape({\n modifiers: PropTypes.array,\n onFirstUpdate: PropTypes.func,\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n strategy: PropTypes.oneOf(['absolute', 'fixed'])\n }),\n /**\n * A ref that points to the used popper instance.\n */\n popperRef: refType,\n /**\n * The props used for each slot inside the Popper.\n * @default {}\n */\n slotProps: PropTypes.shape({\n root: PropTypes.oneOfType([PropTypes.func, PropTypes.object])\n }),\n /**\n * The components used for each slot inside the Popper.\n * Either a string to use a HTML element or a component.\n * @default {}\n */\n slots: PropTypes.shape({\n root: PropTypes.elementType\n }),\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Help supporting a react-transition-group/Transition component.\n * @default false\n */\n transition: PropTypes.bool\n} : void 0;\nexport default Popper;","import generateUtilityClasses from '@mui/utils/generateUtilityClasses';\nimport generateUtilityClass from '@mui/utils/generateUtilityClass';\nexport function getTooltipUtilityClass(slot) {\n return generateUtilityClass('MuiTooltip', slot);\n}\nconst tooltipClasses = generateUtilityClasses('MuiTooltip', ['popper', 'popperInteractive', 'popperArrow', 'popperClose', 'tooltip', 'tooltipArrow', 'touch', 'tooltipPlacementLeft', 'tooltipPlacementRight', 'tooltipPlacementTop', 'tooltipPlacementBottom', 'arrow']);\nexport default tooltipClasses;","'use client';\n\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nconst _excluded = [\"arrow\", \"children\", \"classes\", \"components\", \"componentsProps\", \"describeChild\", \"disableFocusListener\", \"disableHoverListener\", \"disableInteractive\", \"disableTouchListener\", \"enterDelay\", \"enterNextDelay\", \"enterTouchDelay\", \"followCursor\", \"id\", \"leaveDelay\", \"leaveTouchDelay\", \"onClose\", \"onOpen\", \"open\", \"placement\", \"PopperComponent\", \"PopperProps\", \"slotProps\", \"slots\", \"title\", \"TransitionComponent\", \"TransitionProps\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport clsx from 'clsx';\nimport { elementAcceptingRef, unstable_useTimeout as useTimeout, unstable_Timeout as Timeout } from '@mui/utils';\nimport { unstable_composeClasses as composeClasses, appendOwnerState } from '@mui/base';\nimport { alpha } from '@mui/system';\nimport styled from '../styles/styled';\nimport useTheme from '../styles/useTheme';\nimport useThemeProps from '../styles/useThemeProps';\nimport capitalize from '../utils/capitalize';\nimport Grow from '../Grow';\nimport Popper from '../Popper';\nimport useEventCallback from '../utils/useEventCallback';\nimport useForkRef from '../utils/useForkRef';\nimport useId from '../utils/useId';\nimport useIsFocusVisible from '../utils/useIsFocusVisible';\nimport useControlled from '../utils/useControlled';\nimport tooltipClasses, { getTooltipUtilityClass } from './tooltipClasses';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nimport { jsxs as _jsxs } from \"react/jsx-runtime\";\nfunction round(value) {\n return Math.round(value * 1e5) / 1e5;\n}\nconst useUtilityClasses = ownerState => {\n const {\n classes,\n disableInteractive,\n arrow,\n touch,\n placement\n } = ownerState;\n const slots = {\n popper: ['popper', !disableInteractive && 'popperInteractive', arrow && 'popperArrow'],\n tooltip: ['tooltip', arrow && 'tooltipArrow', touch && 'touch', `tooltipPlacement${capitalize(placement.split('-')[0])}`],\n arrow: ['arrow']\n };\n return composeClasses(slots, getTooltipUtilityClass, classes);\n};\nconst TooltipPopper = styled(Popper, {\n name: 'MuiTooltip',\n slot: 'Popper',\n overridesResolver: (props, styles) => {\n const {\n ownerState\n } = props;\n return [styles.popper, !ownerState.disableInteractive && styles.popperInteractive, ownerState.arrow && styles.popperArrow, !ownerState.open && styles.popperClose];\n }\n})(({\n theme,\n ownerState,\n open\n}) => _extends({\n zIndex: (theme.vars || theme).zIndex.tooltip,\n pointerEvents: 'none'\n}, !ownerState.disableInteractive && {\n pointerEvents: 'auto'\n}, !open && {\n pointerEvents: 'none'\n}, ownerState.arrow && {\n [`&[data-popper-placement*=\"bottom\"] .${tooltipClasses.arrow}`]: {\n top: 0,\n marginTop: '-0.71em',\n '&::before': {\n transformOrigin: '0 100%'\n }\n },\n [`&[data-popper-placement*=\"top\"] .${tooltipClasses.arrow}`]: {\n bottom: 0,\n marginBottom: '-0.71em',\n '&::before': {\n transformOrigin: '100% 0'\n }\n },\n [`&[data-popper-placement*=\"right\"] .${tooltipClasses.arrow}`]: _extends({}, !ownerState.isRtl ? {\n left: 0,\n marginLeft: '-0.71em'\n } : {\n right: 0,\n marginRight: '-0.71em'\n }, {\n height: '1em',\n width: '0.71em',\n '&::before': {\n transformOrigin: '100% 100%'\n }\n }),\n [`&[data-popper-placement*=\"left\"] .${tooltipClasses.arrow}`]: _extends({}, !ownerState.isRtl ? {\n right: 0,\n marginRight: '-0.71em'\n } : {\n left: 0,\n marginLeft: '-0.71em'\n }, {\n height: '1em',\n width: '0.71em',\n '&::before': {\n transformOrigin: '0 0'\n }\n })\n}));\nconst TooltipTooltip = styled('div', {\n name: 'MuiTooltip',\n slot: 'Tooltip',\n overridesResolver: (props, styles) => {\n const {\n ownerState\n } = props;\n return [styles.tooltip, ownerState.touch && styles.touch, ownerState.arrow && styles.tooltipArrow, styles[`tooltipPlacement${capitalize(ownerState.placement.split('-')[0])}`]];\n }\n})(({\n theme,\n ownerState\n}) => _extends({\n backgroundColor: theme.vars ? theme.vars.palette.Tooltip.bg : alpha(theme.palette.grey[700], 0.92),\n borderRadius: (theme.vars || theme).shape.borderRadius,\n color: (theme.vars || theme).palette.common.white,\n fontFamily: theme.typography.fontFamily,\n padding: '4px 8px',\n fontSize: theme.typography.pxToRem(11),\n maxWidth: 300,\n margin: 2,\n wordWrap: 'break-word',\n fontWeight: theme.typography.fontWeightMedium\n}, ownerState.arrow && {\n position: 'relative',\n margin: 0\n}, ownerState.touch && {\n padding: '8px 16px',\n fontSize: theme.typography.pxToRem(14),\n lineHeight: `${round(16 / 14)}em`,\n fontWeight: theme.typography.fontWeightRegular\n}, {\n [`.${tooltipClasses.popper}[data-popper-placement*=\"left\"] &`]: _extends({\n transformOrigin: 'right center'\n }, !ownerState.isRtl ? _extends({\n marginRight: '14px'\n }, ownerState.touch && {\n marginRight: '24px'\n }) : _extends({\n marginLeft: '14px'\n }, ownerState.touch && {\n marginLeft: '24px'\n })),\n [`.${tooltipClasses.popper}[data-popper-placement*=\"right\"] &`]: _extends({\n transformOrigin: 'left center'\n }, !ownerState.isRtl ? _extends({\n marginLeft: '14px'\n }, ownerState.touch && {\n marginLeft: '24px'\n }) : _extends({\n marginRight: '14px'\n }, ownerState.touch && {\n marginRight: '24px'\n })),\n [`.${tooltipClasses.popper}[data-popper-placement*=\"top\"] &`]: _extends({\n transformOrigin: 'center bottom',\n marginBottom: '14px'\n }, ownerState.touch && {\n marginBottom: '24px'\n }),\n [`.${tooltipClasses.popper}[data-popper-placement*=\"bottom\"] &`]: _extends({\n transformOrigin: 'center top',\n marginTop: '14px'\n }, ownerState.touch && {\n marginTop: '24px'\n })\n}));\nconst TooltipArrow = styled('span', {\n name: 'MuiTooltip',\n slot: 'Arrow',\n overridesResolver: (props, styles) => styles.arrow\n})(({\n theme\n}) => ({\n overflow: 'hidden',\n position: 'absolute',\n width: '1em',\n height: '0.71em' /* = width / sqrt(2) = (length of the hypotenuse) */,\n boxSizing: 'border-box',\n color: theme.vars ? theme.vars.palette.Tooltip.bg : alpha(theme.palette.grey[700], 0.9),\n '&::before': {\n content: '\"\"',\n margin: 'auto',\n display: 'block',\n width: '100%',\n height: '100%',\n backgroundColor: 'currentColor',\n transform: 'rotate(45deg)'\n }\n}));\nlet hystersisOpen = false;\nconst hystersisTimer = new Timeout();\nlet cursorPosition = {\n x: 0,\n y: 0\n};\nexport function testReset() {\n hystersisOpen = false;\n hystersisTimer.clear();\n}\nfunction composeEventHandler(handler, eventHandler) {\n return event => {\n if (eventHandler) {\n eventHandler(event);\n }\n handler(event);\n };\n}\n\n// TODO v6: Remove PopperComponent, PopperProps, TransitionComponent and TransitionProps.\nconst Tooltip = /*#__PURE__*/React.forwardRef(function Tooltip(inProps, ref) {\n var _ref, _slots$popper, _ref2, _ref3, _slots$transition, _ref4, _slots$tooltip, _ref5, _slots$arrow, _slotProps$popper, _ref6, _slotProps$popper2, _slotProps$transition, _slotProps$tooltip, _ref7, _slotProps$tooltip2, _slotProps$arrow, _ref8, _slotProps$arrow2;\n const props = useThemeProps({\n props: inProps,\n name: 'MuiTooltip'\n });\n const {\n arrow = false,\n children: childrenProp,\n components = {},\n componentsProps = {},\n describeChild = false,\n disableFocusListener = false,\n disableHoverListener = false,\n disableInteractive: disableInteractiveProp = false,\n disableTouchListener = false,\n enterDelay = 100,\n enterNextDelay = 0,\n enterTouchDelay = 700,\n followCursor = false,\n id: idProp,\n leaveDelay = 0,\n leaveTouchDelay = 1500,\n onClose,\n onOpen,\n open: openProp,\n placement = 'bottom',\n PopperComponent: PopperComponentProp,\n PopperProps = {},\n slotProps = {},\n slots = {},\n title,\n TransitionComponent: TransitionComponentProp = Grow,\n TransitionProps\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n\n // to prevent runtime errors, developers will need to provide a child as a React element anyway.\n const children = /*#__PURE__*/React.isValidElement(childrenProp) ? childrenProp : /*#__PURE__*/_jsx(\"span\", {\n children: childrenProp\n });\n const theme = useTheme();\n const isRtl = theme.direction === 'rtl';\n const [childNode, setChildNode] = React.useState();\n const [arrowRef, setArrowRef] = React.useState(null);\n const ignoreNonTouchEvents = React.useRef(false);\n const disableInteractive = disableInteractiveProp || followCursor;\n const closeTimer = useTimeout();\n const enterTimer = useTimeout();\n const leaveTimer = useTimeout();\n const touchTimer = useTimeout();\n const [openState, setOpenState] = useControlled({\n controlled: openProp,\n default: false,\n name: 'Tooltip',\n state: 'open'\n });\n let open = openState;\n if (process.env.NODE_ENV !== 'production') {\n // eslint-disable-next-line react-hooks/rules-of-hooks\n const {\n current: isControlled\n } = React.useRef(openProp !== undefined);\n\n // eslint-disable-next-line react-hooks/rules-of-hooks\n React.useEffect(() => {\n if (childNode && childNode.disabled && !isControlled && title !== '' && childNode.tagName.toLowerCase() === 'button') {\n console.error(['MUI: You are providing a disabled `button` child to the Tooltip component.', 'A disabled element does not fire events.', \"Tooltip needs to listen to the child element's events to display the title.\", '', 'Add a simple wrapper element, such as a `span`.'].join('\\n'));\n }\n }, [title, childNode, isControlled]);\n }\n const id = useId(idProp);\n const prevUserSelect = React.useRef();\n const stopTouchInteraction = useEventCallback(() => {\n if (prevUserSelect.current !== undefined) {\n document.body.style.WebkitUserSelect = prevUserSelect.current;\n prevUserSelect.current = undefined;\n }\n touchTimer.clear();\n });\n React.useEffect(() => stopTouchInteraction, [stopTouchInteraction]);\n const handleOpen = event => {\n hystersisTimer.clear();\n hystersisOpen = true;\n\n // The mouseover event will trigger for every nested element in the tooltip.\n // We can skip rerendering when the tooltip is already open.\n // We are using the mouseover event instead of the mouseenter event to fix a hide/show issue.\n setOpenState(true);\n if (onOpen && !open) {\n onOpen(event);\n }\n };\n const handleClose = useEventCallback(\n /**\n * @param {React.SyntheticEvent | Event} event\n */\n event => {\n hystersisTimer.start(800 + leaveDelay, () => {\n hystersisOpen = false;\n });\n setOpenState(false);\n if (onClose && open) {\n onClose(event);\n }\n closeTimer.start(theme.transitions.duration.shortest, () => {\n ignoreNonTouchEvents.current = false;\n });\n });\n const handleEnter = event => {\n if (ignoreNonTouchEvents.current && event.type !== 'touchstart') {\n return;\n }\n\n // Remove the title ahead of time.\n // We don't want to wait for the next render commit.\n // We would risk displaying two tooltips at the same time (native + this one).\n if (childNode) {\n childNode.removeAttribute('title');\n }\n enterTimer.clear();\n leaveTimer.clear();\n if (enterDelay || hystersisOpen && enterNextDelay) {\n enterTimer.start(hystersisOpen ? enterNextDelay : enterDelay, () => {\n handleOpen(event);\n });\n } else {\n handleOpen(event);\n }\n };\n const handleLeave = event => {\n enterTimer.clear();\n leaveTimer.start(leaveDelay, () => {\n handleClose(event);\n });\n };\n const {\n isFocusVisibleRef,\n onBlur: handleBlurVisible,\n onFocus: handleFocusVisible,\n ref: focusVisibleRef\n } = useIsFocusVisible();\n // We don't necessarily care about the focusVisible state (which is safe to access via ref anyway).\n // We just need to re-render the Tooltip if the focus-visible state changes.\n const [, setChildIsFocusVisible] = React.useState(false);\n const handleBlur = event => {\n handleBlurVisible(event);\n if (isFocusVisibleRef.current === false) {\n setChildIsFocusVisible(false);\n handleLeave(event);\n }\n };\n const handleFocus = event => {\n // Workaround for https://github.com/facebook/react/issues/7769\n // The autoFocus of React might trigger the event before the componentDidMount.\n // We need to account for this eventuality.\n if (!childNode) {\n setChildNode(event.currentTarget);\n }\n handleFocusVisible(event);\n if (isFocusVisibleRef.current === true) {\n setChildIsFocusVisible(true);\n handleEnter(event);\n }\n };\n const detectTouchStart = event => {\n ignoreNonTouchEvents.current = true;\n const childrenProps = children.props;\n if (childrenProps.onTouchStart) {\n childrenProps.onTouchStart(event);\n }\n };\n const handleMouseOver = handleEnter;\n const handleMouseLeave = handleLeave;\n const handleTouchStart = event => {\n detectTouchStart(event);\n leaveTimer.clear();\n closeTimer.clear();\n stopTouchInteraction();\n prevUserSelect.current = document.body.style.WebkitUserSelect;\n // Prevent iOS text selection on long-tap.\n document.body.style.WebkitUserSelect = 'none';\n touchTimer.start(enterTouchDelay, () => {\n document.body.style.WebkitUserSelect = prevUserSelect.current;\n handleEnter(event);\n });\n };\n const handleTouchEnd = event => {\n if (children.props.onTouchEnd) {\n children.props.onTouchEnd(event);\n }\n stopTouchInteraction();\n leaveTimer.start(leaveTouchDelay, () => {\n handleClose(event);\n });\n };\n React.useEffect(() => {\n if (!open) {\n return undefined;\n }\n\n /**\n * @param {KeyboardEvent} nativeEvent\n */\n function handleKeyDown(nativeEvent) {\n // IE11, Edge (prior to using Bink?) use 'Esc'\n if (nativeEvent.key === 'Escape' || nativeEvent.key === 'Esc') {\n handleClose(nativeEvent);\n }\n }\n document.addEventListener('keydown', handleKeyDown);\n return () => {\n document.removeEventListener('keydown', handleKeyDown);\n };\n }, [handleClose, open]);\n const handleRef = useForkRef(children.ref, focusVisibleRef, setChildNode, ref);\n\n // There is no point in displaying an empty tooltip.\n // So we exclude all falsy values, except 0, which is valid.\n if (!title && title !== 0) {\n open = false;\n }\n const popperRef = React.useRef();\n const handleMouseMove = event => {\n const childrenProps = children.props;\n if (childrenProps.onMouseMove) {\n childrenProps.onMouseMove(event);\n }\n cursorPosition = {\n x: event.clientX,\n y: event.clientY\n };\n if (popperRef.current) {\n popperRef.current.update();\n }\n };\n const nameOrDescProps = {};\n const titleIsString = typeof title === 'string';\n if (describeChild) {\n nameOrDescProps.title = !open && titleIsString && !disableHoverListener ? title : null;\n nameOrDescProps['aria-describedby'] = open ? id : null;\n } else {\n nameOrDescProps['aria-label'] = titleIsString ? title : null;\n nameOrDescProps['aria-labelledby'] = open && !titleIsString ? id : null;\n }\n const childrenProps = _extends({}, nameOrDescProps, other, children.props, {\n className: clsx(other.className, children.props.className),\n onTouchStart: detectTouchStart,\n ref: handleRef\n }, followCursor ? {\n onMouseMove: handleMouseMove\n } : {});\n if (process.env.NODE_ENV !== 'production') {\n childrenProps['data-mui-internal-clone-element'] = true;\n\n // eslint-disable-next-line react-hooks/rules-of-hooks\n React.useEffect(() => {\n if (childNode && !childNode.getAttribute('data-mui-internal-clone-element')) {\n console.error(['MUI: The `children` component of the Tooltip is not forwarding its props correctly.', 'Please make sure that props are spread on the same element that the ref is applied to.'].join('\\n'));\n }\n }, [childNode]);\n }\n const interactiveWrapperListeners = {};\n if (!disableTouchListener) {\n childrenProps.onTouchStart = handleTouchStart;\n childrenProps.onTouchEnd = handleTouchEnd;\n }\n if (!disableHoverListener) {\n childrenProps.onMouseOver = composeEventHandler(handleMouseOver, childrenProps.onMouseOver);\n childrenProps.onMouseLeave = composeEventHandler(handleMouseLeave, childrenProps.onMouseLeave);\n if (!disableInteractive) {\n interactiveWrapperListeners.onMouseOver = handleMouseOver;\n interactiveWrapperListeners.onMouseLeave = handleMouseLeave;\n }\n }\n if (!disableFocusListener) {\n childrenProps.onFocus = composeEventHandler(handleFocus, childrenProps.onFocus);\n childrenProps.onBlur = composeEventHandler(handleBlur, childrenProps.onBlur);\n if (!disableInteractive) {\n interactiveWrapperListeners.onFocus = handleFocus;\n interactiveWrapperListeners.onBlur = handleBlur;\n }\n }\n if (process.env.NODE_ENV !== 'production') {\n if (children.props.title) {\n console.error(['MUI: You have provided a `title` prop to the child of .', `Remove this title prop \\`${children.props.title}\\` or the Tooltip component.`].join('\\n'));\n }\n }\n const popperOptions = React.useMemo(() => {\n var _PopperProps$popperOp;\n let tooltipModifiers = [{\n name: 'arrow',\n enabled: Boolean(arrowRef),\n options: {\n element: arrowRef,\n padding: 4\n }\n }];\n if ((_PopperProps$popperOp = PopperProps.popperOptions) != null && _PopperProps$popperOp.modifiers) {\n tooltipModifiers = tooltipModifiers.concat(PopperProps.popperOptions.modifiers);\n }\n return _extends({}, PopperProps.popperOptions, {\n modifiers: tooltipModifiers\n });\n }, [arrowRef, PopperProps]);\n const ownerState = _extends({}, props, {\n isRtl,\n arrow,\n disableInteractive,\n placement,\n PopperComponentProp,\n touch: ignoreNonTouchEvents.current\n });\n const classes = useUtilityClasses(ownerState);\n const PopperComponent = (_ref = (_slots$popper = slots.popper) != null ? _slots$popper : components.Popper) != null ? _ref : TooltipPopper;\n const TransitionComponent = (_ref2 = (_ref3 = (_slots$transition = slots.transition) != null ? _slots$transition : components.Transition) != null ? _ref3 : TransitionComponentProp) != null ? _ref2 : Grow;\n const TooltipComponent = (_ref4 = (_slots$tooltip = slots.tooltip) != null ? _slots$tooltip : components.Tooltip) != null ? _ref4 : TooltipTooltip;\n const ArrowComponent = (_ref5 = (_slots$arrow = slots.arrow) != null ? _slots$arrow : components.Arrow) != null ? _ref5 : TooltipArrow;\n const popperProps = appendOwnerState(PopperComponent, _extends({}, PopperProps, (_slotProps$popper = slotProps.popper) != null ? _slotProps$popper : componentsProps.popper, {\n className: clsx(classes.popper, PopperProps == null ? void 0 : PopperProps.className, (_ref6 = (_slotProps$popper2 = slotProps.popper) != null ? _slotProps$popper2 : componentsProps.popper) == null ? void 0 : _ref6.className)\n }), ownerState);\n const transitionProps = appendOwnerState(TransitionComponent, _extends({}, TransitionProps, (_slotProps$transition = slotProps.transition) != null ? _slotProps$transition : componentsProps.transition), ownerState);\n const tooltipProps = appendOwnerState(TooltipComponent, _extends({}, (_slotProps$tooltip = slotProps.tooltip) != null ? _slotProps$tooltip : componentsProps.tooltip, {\n className: clsx(classes.tooltip, (_ref7 = (_slotProps$tooltip2 = slotProps.tooltip) != null ? _slotProps$tooltip2 : componentsProps.tooltip) == null ? void 0 : _ref7.className)\n }), ownerState);\n const tooltipArrowProps = appendOwnerState(ArrowComponent, _extends({}, (_slotProps$arrow = slotProps.arrow) != null ? _slotProps$arrow : componentsProps.arrow, {\n className: clsx(classes.arrow, (_ref8 = (_slotProps$arrow2 = slotProps.arrow) != null ? _slotProps$arrow2 : componentsProps.arrow) == null ? void 0 : _ref8.className)\n }), ownerState);\n return /*#__PURE__*/_jsxs(React.Fragment, {\n children: [/*#__PURE__*/React.cloneElement(children, childrenProps), /*#__PURE__*/_jsx(PopperComponent, _extends({\n as: PopperComponentProp != null ? PopperComponentProp : Popper,\n placement: placement,\n anchorEl: followCursor ? {\n getBoundingClientRect: () => ({\n top: cursorPosition.y,\n left: cursorPosition.x,\n right: cursorPosition.x,\n bottom: cursorPosition.y,\n width: 0,\n height: 0\n })\n } : childNode,\n popperRef: popperRef,\n open: childNode ? open : false,\n id: id,\n transition: true\n }, interactiveWrapperListeners, popperProps, {\n popperOptions: popperOptions,\n children: ({\n TransitionProps: TransitionPropsInner\n }) => /*#__PURE__*/_jsx(TransitionComponent, _extends({\n timeout: theme.transitions.duration.shorter\n }, TransitionPropsInner, transitionProps, {\n children: /*#__PURE__*/_jsxs(TooltipComponent, _extends({}, tooltipProps, {\n children: [title, arrow ? /*#__PURE__*/_jsx(ArrowComponent, _extends({}, tooltipArrowProps, {\n ref: setArrowRef\n })) : null]\n }))\n }))\n }))]\n });\n});\nprocess.env.NODE_ENV !== \"production\" ? Tooltip.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the d.ts file and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * If `true`, adds an arrow to the tooltip.\n * @default false\n */\n arrow: PropTypes.bool,\n /**\n * Tooltip reference element.\n */\n children: elementAcceptingRef.isRequired,\n /**\n * Override or extend the styles applied to the component.\n */\n classes: PropTypes.object,\n /**\n * @ignore\n */\n className: PropTypes.string,\n /**\n * The components used for each slot inside.\n *\n * This prop is an alias for the `slots` prop.\n * It's recommended to use the `slots` prop instead.\n *\n * @default {}\n */\n components: PropTypes.shape({\n Arrow: PropTypes.elementType,\n Popper: PropTypes.elementType,\n Tooltip: PropTypes.elementType,\n Transition: PropTypes.elementType\n }),\n /**\n * The extra props for the slot components.\n * You can override the existing props or add new ones.\n *\n * This prop is an alias for the `slotProps` prop.\n * It's recommended to use the `slotProps` prop instead, as `componentsProps` will be deprecated in the future.\n *\n * @default {}\n */\n componentsProps: PropTypes.shape({\n arrow: PropTypes.object,\n popper: PropTypes.object,\n tooltip: PropTypes.object,\n transition: PropTypes.object\n }),\n /**\n * Set to `true` if the `title` acts as an accessible description.\n * By default the `title` acts as an accessible label for the child.\n * @default false\n */\n describeChild: PropTypes.bool,\n /**\n * Do not respond to focus-visible events.\n * @default false\n */\n disableFocusListener: PropTypes.bool,\n /**\n * Do not respond to hover events.\n * @default false\n */\n disableHoverListener: PropTypes.bool,\n /**\n * Makes a tooltip not interactive, i.e. it will close when the user\n * hovers over the tooltip before the `leaveDelay` is expired.\n * @default false\n */\n disableInteractive: PropTypes.bool,\n /**\n * Do not respond to long press touch events.\n * @default false\n */\n disableTouchListener: PropTypes.bool,\n /**\n * The number of milliseconds to wait before showing the tooltip.\n * This prop won't impact the enter touch delay (`enterTouchDelay`).\n * @default 100\n */\n enterDelay: PropTypes.number,\n /**\n * The number of milliseconds to wait before showing the tooltip when one was already recently opened.\n * @default 0\n */\n enterNextDelay: PropTypes.number,\n /**\n * The number of milliseconds a user must touch the element before showing the tooltip.\n * @default 700\n */\n enterTouchDelay: PropTypes.number,\n /**\n * If `true`, the tooltip follow the cursor over the wrapped element.\n * @default false\n */\n followCursor: PropTypes.bool,\n /**\n * This prop is used to help implement the accessibility logic.\n * If you don't provide this prop. It falls back to a randomly generated id.\n */\n id: PropTypes.string,\n /**\n * The number of milliseconds to wait before hiding the tooltip.\n * This prop won't impact the leave touch delay (`leaveTouchDelay`).\n * @default 0\n */\n leaveDelay: PropTypes.number,\n /**\n * The number of milliseconds after the user stops touching an element before hiding the tooltip.\n * @default 1500\n */\n leaveTouchDelay: PropTypes.number,\n /**\n * Callback fired when the component requests to be closed.\n *\n * @param {React.SyntheticEvent} event The event source of the callback.\n */\n onClose: PropTypes.func,\n /**\n * Callback fired when the component requests to be open.\n *\n * @param {React.SyntheticEvent} event The event source of the callback.\n */\n onOpen: PropTypes.func,\n /**\n * If `true`, the component is shown.\n */\n open: PropTypes.bool,\n /**\n * Tooltip placement.\n * @default 'bottom'\n */\n placement: PropTypes.oneOf(['bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n /**\n * The component used for the popper.\n * @default Popper\n */\n PopperComponent: PropTypes.elementType,\n /**\n * Props applied to the [`Popper`](/material-ui/api/popper/) element.\n * @default {}\n */\n PopperProps: PropTypes.object,\n /**\n * The extra props for the slot components.\n * You can override the existing props or add new ones.\n *\n * This prop is an alias for the `componentsProps` prop, which will be deprecated in the future.\n *\n * @default {}\n */\n slotProps: PropTypes.shape({\n arrow: PropTypes.object,\n popper: PropTypes.object,\n tooltip: PropTypes.object,\n transition: PropTypes.object\n }),\n /**\n * The components used for each slot inside.\n *\n * This prop is an alias for the `components` prop, which will be deprecated in the future.\n *\n * @default {}\n */\n slots: PropTypes.shape({\n arrow: PropTypes.elementType,\n popper: PropTypes.elementType,\n tooltip: PropTypes.elementType,\n transition: PropTypes.elementType\n }),\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Tooltip title. Zero-length titles string, undefined, null and false are never displayed.\n */\n title: PropTypes.node,\n /**\n * The component used for the transition.\n * [Follow this guide](/material-ui/transitions/#transitioncomponent-prop) to learn more about the requirements for this component.\n * @default Grow\n */\n TransitionComponent: PropTypes.elementType,\n /**\n * Props applied to the transition element.\n * By default, the element is based on this [`Transition`](http://reactcommunity.org/react-transition-group/transition/) component.\n */\n TransitionProps: PropTypes.object\n} : void 0;\nexport default Tooltip;","import '@/components/mui/menu-item.component.css';\nimport ArrowRightIcon from '@mui/icons-material/ArrowRight';\nimport {\n ListItemIcon as MuiListItemIcon,\n ListItemText as MuiListItemText,\n MenuItem as MuiMenuItem,\n} from '@mui/material';\nimport Tooltip from '@mui/material/Tooltip';\nimport { Localized, ReferencedItem, SingleColumnMenu } from 'platform-bible-utils';\nimport { MouseEvent, PropsWithChildren } from 'react';\n\ntype MenuItemInfoBase = {\n /** Text (displayable in the UI) as the name of the menu item */\n label: string;\n /** Text to display when the mouse hovers over the menu item */\n tooltip?: string;\n};\n\nexport type Command = MenuItemInfoBase & {\n /** Command to execute (string.string) */\n command: string;\n};\n\ntype SubMenu = MenuItemInfoBase & {\n /** Command to execute (string.string) */\n items: MenuItemInfo[];\n};\n\nexport interface CommandHandler {\n (command: Command): void;\n}\n\nexport type MenuPropsBase = {\n /*\n * The JSON defining the menu whose items are to be rendered. This will typically be one of the\n * menus in the \"defs\" in a Platform.Bible menu (see PlatformMenus). The schema for this is\n * menuDocumentSchema (at the end of menus.model.ts). Note that while this is a\n * \"SingleColumnMenu\", somewhat bizarrely, a MultiColumnMenu is a SingleColumnMenu, so it really\n * could be a MultiColumnMenu, in which case, column had better be defined so it can be used\n * to filter out the actual groups and items to display on the column.\n */\n menuDefinition: Localized;\n\n commandHandler: CommandHandler;\n\n /**\n * Additional action to perform when any menu item is clicked. Allows the caller to handle event\n * (e.g., to close the menu).\n */\n onClick?: (event: MouseEvent) => void;\n};\n\nexport type MenuItemListProps = MenuPropsBase & {\n /** Optional unique (column) identifier */\n columnId?: ReferencedItem;\n};\n\nexport type MenuItemProps = Omit &\n PropsWithChildren<{\n /** Optional unique identifier */\n id?: string;\n\n onClick: (event: MouseEvent) => void;\n }>;\n\ntype MenuItemInfo = (Command | SubMenu) & {\n /**\n * If specified, menu item will be inset if it does not have a leading icon.\n *\n * @default true\n */\n allowForLeadingIcons?: boolean;\n /**\n * If specified, the path to the icon image to display on the leading side of the menu text.\n *\n * @default undefined (no leading icon will be shown)\n */\n iconPathBefore?: string;\n /**\n * If specified, the path to the icon image to display on the trailing side of the menu text.\n *\n * @default undefined (no trailing icon will be shown)\n */\n iconPathAfter?: string;\n /**\n * If true, list item is focused during the first mount\n *\n * @default false\n */\n hasAutoFocus?: boolean;\n\n /** Additional css classes to help with unique styling of the menu item */\n className?: string;\n\n /**\n * If true, the menu item will appear disabled and it will not respond to clicks or mouse hovers.\n *\n * @default false\n */\n isDisabled?: boolean;\n\n /**\n * If true, compact vertical padding designed for keyboard and mouse input is used.\n *\n * @default true\n */\n isDense?: boolean;\n\n /**\n * If true, a right-arrow icon will be displayed (iconPathAfter, if specified, will be ignored).\n *\n * @default false\n */\n isSubMenuParent?: boolean;\n\n /**\n * If true, the left and right padding is removed\n *\n * @default false\n */\n hasDisabledGutters?: boolean;\n\n /**\n * If true, a 1px light border is added to bottom of menu item\n *\n * @default false\n */\n hasDivider?: boolean;\n\n /** Help identify which element has keyboard focus */\n focusVisibleClassName?: string;\n\n /** If it's a submenu, it should have the items property */\n items?: MenuItemInfo[];\n};\n\nfunction getIcon(icon: string | undefined, menuLabel: string, leading: boolean) {\n return icon ? (\n \n {`${leading\n \n ) : undefined;\n}\n\nexport default function MenuItem(props: MenuItemProps) {\n const {\n onClick,\n label,\n tooltip,\n allowForLeadingIcons = true,\n iconPathBefore = undefined,\n iconPathAfter = undefined,\n hasAutoFocus = false,\n className,\n isDisabled = false,\n isDense = true,\n isSubMenuParent = false,\n hasDisabledGutters = false,\n hasDivider = false,\n focusVisibleClassName,\n id,\n children,\n } = props;\n\n const menuItem = (\n \n {label ? (\n <>\n {getIcon(iconPathBefore, label, true)}\n \n {isSubMenuParent ? (\n \n \n \n ) : (\n getIcon(iconPathAfter, label, false)\n )}\n \n ) : (\n children\n )}\n \n );\n\n return tooltip ? (\n \n
    {menuItem}
    \n
    \n ) : (\n menuItem\n );\n}\n","import MenuItem, {\n MenuItemListProps,\n MenuItemProps,\n MenuPropsBase,\n} from '@/components/mui/menu-item.component';\nimport { Menu } from '@mui/material';\nimport {\n Localized,\n MenuGroupDetailsInSubMenu,\n MenuItemContainingCommand,\n MenuItemContainingSubmenu,\n OrderedExtensibleContainer,\n ReferencedItem,\n SingleColumnMenu,\n} from 'platform-bible-utils';\nimport { MouseEvent, useMemo, useState } from 'react';\n\n/**\n * All the exported types in this file should be regarded as \"internal\" (i.e., they should not be\n * exposed via index.ts).\n */\n\nexport type GroupedMenuPropsBase = MenuPropsBase & {\n /** Optional unique (column) identifier */\n columnId?: ReferencedItem;\n};\n\nexport type GroupedMenuItemListProps = MenuItemListProps & {\n /**\n * If the menuDefinition includes \"top-level\" groups (i.e., those that belong to a column as\n * opposed to those that belong to a submenu) that should not be included in the list, then this\n * array specifies which groups to include. Likewise, for a submenu, this list indicates which\n * groups are pertinent for that submenu. So then for a context menu this property need not be\n * specified since it is a top-level menu based on a \"true\" SingleColumnMenu (i.e., one that is\n * not a MultiColumnMenu).\n */\n includedGroups?: {\n id: string;\n group: Localized;\n }[];\n};\n\ninterface ItemInfo {\n item: Localized;\n isLastItemInGroup: boolean;\n}\n\ntype SubMenuProps = MenuPropsBase & {\n parentMenuItem: Localized;\n parentItemProps: Omit, 'iconPathAfter'>;\n};\n\nfunction getAllGroups(menuDefinition: Localized) {\n const groupEntries = Object.entries(menuDefinition.groups);\n // Convert array of entries to array of objects with id and group properties\n return groupEntries.map(([key, value]) => ({ id: key, group: value }));\n}\n\nfunction SubMenu(props: SubMenuProps) {\n const [anchorEl, setAnchorEl] = useState(undefined);\n\n const { parentMenuItem, parentItemProps, menuDefinition } = props;\n\n const handleParentMenuItemClick = (event: MouseEvent) => {\n setAnchorEl(event.currentTarget);\n };\n\n const handleClose = () => {\n setAnchorEl(undefined);\n };\n\n const renderSubMenuItems = () => {\n let includedGroups = getAllGroups(menuDefinition).filter((g) => 'menuItem' in g.group);\n\n // Ensure valid parent menu was provided. (If not, submenu will contain all groups!)\n if (!parentMenuItem?.id) throw new Error('A valid parent menu item is required for submenus.');\n\n // When laying out a submenu, only include groups associated with the provided parent menu.\n // Note: without the (annoying) redundant check that the included groups\n // have the menuItem field, TS doesn't think it exists.\n includedGroups = includedGroups.filter(\n (group) => 'menuItem' in group.group && group.group.menuItem === parentMenuItem.id,\n );\n\n return ;\n };\n\n return (\n <>\n \n \n {renderSubMenuItems()}\n \n \n );\n}\n\nconst getOrderedGroupItems = (\n groupId: string,\n allItems: Localized[],\n) => {\n // Filter items that belong to the specified group\n const itemsForGroup = allItems.filter((item) => item.group === groupId);\n // Sort items based on order\n const sortedItems = itemsForGroup.sort((a, b) => (a.order || 0) - (b.order || 0));\n return sortedItems;\n};\n\n/**\n * This component is internal; it does not need to be exposed to the outside world since it is not\n * useful on its own. It is used to generate and lay out the MenuItems that appear either on a\n * top-level menu (in a GridMenu or ContextMenu) or in a submenu.\n */\nexport default function GroupedMenuItemList(menuProps: GroupedMenuItemListProps) {\n const { menuDefinition, onClick, commandHandler, includedGroups } = menuProps;\n\n const { items, allowForLeadingIcons } = useMemo(() => {\n const groupsToInclude =\n includedGroups && includedGroups.length > 0\n ? includedGroups\n : // We're apparently laying out a single-column menu (presumably a context menu). In this\n // case, all groups should be included except ones that belong to a submenu.\n getAllGroups(menuDefinition).filter((g) => !('menuItem' in g.group));\n\n const sortedGroups = Object.values(groupsToInclude).sort(\n (a, b) => (a.group.order || 0) - (b.group.order || 0),\n );\n\n const itemArray: ItemInfo[] = [];\n\n sortedGroups.forEach((group) => {\n getOrderedGroupItems(group.id, menuDefinition.items).forEach((item) =>\n itemArray.push({ item, isLastItemInGroup: false }),\n );\n if (itemArray.length > 0) itemArray[itemArray.length - 1].isLastItemInGroup = true;\n });\n\n // No divider after last item in final group.\n if (itemArray.length > 0) itemArray[itemArray.length - 1].isLastItemInGroup = false;\n\n const allowSpaceForLeadingIcons = itemArray.some(\n (i) => 'iconPathBefore' in i.item && i.item.iconPathBefore,\n );\n\n return { items: itemArray, allowForLeadingIcons: allowSpaceForLeadingIcons };\n }, [includedGroups, menuDefinition]);\n\n // Create props for MenuItem component including setting hasDivider for the last item in a group\n const createMenuItemProps = ({ item, isLastItemInGroup }: ItemInfo) => {\n const menuItemProps = {\n className: 'papi-menu-item',\n label: item.label,\n tooltip: item.tooltip,\n iconPathBefore: 'iconPathBefore' in item ? item.iconPathBefore : undefined,\n iconPathAfter: 'iconPathAfter' in item ? item.iconPathAfter : undefined,\n hasDivider: isLastItemInGroup, // Set hasDivider to true for the last item in a group\n allowForLeadingIcons,\n };\n\n return menuItemProps;\n };\n\n const [firstItem] = items;\n\n if (!firstItem) return
    ;\n\n const divKey = firstItem.item.group;\n\n return (\n
    \n {items.map((itemInfo, index) => {\n const { item } = itemInfo;\n const menuItemProps = createMenuItemProps(itemInfo);\n if ('command' in item) {\n const key = item.group + index;\n return (\n ) => {\n onClick?.(event);\n commandHandler(item);\n }}\n {...menuItemProps}\n />\n );\n }\n return (\n \n );\n })}\n
    \n );\n}\n","import GroupedMenuItemList from '@/components/mui/grouped-menu-item-list.component';\nimport { MenuItemListProps } from '@/components/mui/menu-item.component';\nimport { MultiColumnMenu } from 'platform-bible-utils';\n\n/**\n * This component is internal; it does not need to be exposed to the outside world since it is not\n * useful on its own. Use either GridMenu or ContextMenu.\n */\nexport default function TopLevelMenu(props: MenuItemListProps) {\n const { menuDefinition, columnId } = props;\n\n const groupEntries = Object.entries(menuDefinition.groups);\n // Convert array of entries to array of objects with id and group properties\n const groups = groupEntries.map(([key, value]) => ({ id: key, group: value }));\n let includedGroups = groups.filter((g) => 'column' in g.group);\n\n // Check if column is provided and menuDefinition is a MultiColumnMenu\n if (\n columnId &&\n 'columns' in menuDefinition &&\n // Without this type assertion, TS doesn't know what columns is.\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n (menuDefinition as MultiColumnMenu).columns[columnId]\n ) {\n // When laying out a single column in a MultiColumnMenu, only include groups associated with\n // the provided column. Note: without the (annoying) redundant check that the included groups\n // have the colum field, TS doesn't think it exists.\n includedGroups = includedGroups.filter(\n (g) => 'column' in g.group && g.group.column === columnId,\n );\n }\n\n return ;\n}\n","import '@/components/mui/grid-menu.component.css';\nimport { GroupedMenuPropsBase } from '@/components/mui/grouped-menu-item-list.component';\nimport { CommandHandler } from '@/components/mui/menu-item.component';\nimport TopLevelMenu from '@/components/mui/top-level-menu.component';\nimport { Grid, List } from '@mui/material';\nimport {\n Localized,\n MenuColumnWithHeader,\n MultiColumnMenu,\n ReferencedItem,\n} from 'platform-bible-utils';\nimport { useMemo } from 'react';\n\ntype ColumnInfo = {\n /*\n * The ID (`${string}.${string}`) of a specific menu column.\n */\n id: ReferencedItem;\n\n /*\n * Metadata (label, order, etc.) for a specific menu column.\n */\n metadata: Localized;\n};\n\ntype MenuColumnProps = ColumnInfo &\n GroupedMenuPropsBase & {\n /** Additional css classes to help with unique styling of the menu column */\n className?: string;\n };\n\nexport type GridMenuInfo = {\n /** The menu object containing information about the columns, groups, and items to display. */\n multiColumnMenu: Localized;\n};\n\nexport type GridMenuProps = GridMenuInfo & {\n /** Optional unique identifier */\n id?: string;\n\n commandHandler: CommandHandler;\n\n /** Additional css classes to help with unique styling of the grid menu */\n className?: string;\n};\n\nfunction MenuColumn({\n commandHandler,\n menuDefinition,\n id,\n metadata,\n onClick,\n className,\n}: MenuColumnProps) {\n return (\n \n

    \n {metadata.label}\n

    \n {/* It would seem as though this List component were unnecessary, since it only contains one\n thing, but the \"dense\" property does affect the layout of the items (in a way I don't fully\n understand). There might be a better way. */}\n \n \n \n \n );\n}\n\nexport default function GridMenu({\n commandHandler,\n className,\n multiColumnMenu,\n id,\n}: GridMenuProps) {\n const { columns } = multiColumnMenu;\n\n const sortedColumns = useMemo(() => {\n const columnNumbers = new Map();\n Object.getOwnPropertyNames(columns).forEach((columnName: string) => {\n // We know for sure there is a (boolean) property 'isExtensible' that we are not interested in.\n if (columnName === 'isExtensible') return;\n // TS doesn't allow `columnName` above to be a ReferencedItem even though the type says it is\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const columnId = columnName as ReferencedItem;\n const column = columns[columnId];\n // As of right now (and hopefully forever after), all remaining properties of the\n // ColumnsWithHeaders object are columns whose property names are the IDs of the columns.\n // This is an additional (redundant) sanity check. Specifically we're interested in\n // MenuColumnWithHeader objects, which TypeScript now \"knows\" we have, but at runtime all we\n // can check for is that it's an object with a valid numeric order field. That's likely good\n // enough.\n if (\n typeof column === 'object' &&\n typeof column.order === 'number' &&\n !Number.isNaN(column.order)\n )\n columnNumbers.set(column.order, { id: columnId, metadata: column });\n else\n console.warn(\n `Property ${columnName} (${typeof column}) on menu ${id} is not a valid column and is being ignored. This might indicate data corruption`,\n );\n });\n\n // Extract values and sort them based on the 'order' property\n return Array.from(columnNumbers.values()).sort((a, b) => {\n return (a.metadata.order || 0) - (b.metadata.order || 0);\n });\n }, [columns, id]);\n\n // We might need something like this if we need to be able to prevent empty columns\n // sortedColumns.filter((c) => multiColumnMenu.groups.some((g) => 'column' in g && (g as .column)...\n\n return (\n \n {sortedColumns.map((col, index) => (\n \n ))}\n \n );\n}\n","import { useEffect, useRef, useState } from 'react';\n\nexport type UsePromiseOptions = {\n /**\n * Whether to leave the value as the most recent resolved promise value or set it back to\n * defaultValue while running the promise again. Defaults to true\n */\n preserveValue?: boolean;\n};\n\n/** Set up defaults for options for usePromise hook */\nfunction getUsePromiseOptionsDefaults(options: UsePromiseOptions): UsePromiseOptions {\n return {\n preserveValue: true,\n ...options,\n };\n}\n\n/**\n * Awaits a promise and returns a loading value while the promise is unresolved\n *\n * @param promiseFactoryCallback A function that returns the promise to await. If this callback is\n * undefined, the current value will be returned (defaultValue unless it was previously changed\n * and `options.preserveValue` is true), and there will be no loading.\n *\n * WARNING: MUST BE STABLE - const or wrapped in useCallback. The reference must not be updated\n * every render\n * @param defaultValue The initial value to return while first awaiting the promise. If\n * `options.preserveValue` is false, this value is also shown while awaiting the promise on\n * subsequent calls.\n *\n * Note: this parameter is internally assigned to a `ref`, so changing it will not cause any hooks\n * to re-run with its new value. This means that, if the `promiseFactoryCallback` changes and\n * `options.preserveValue` is `false`, the returned value will be set to the current\n * `defaultValue`. However, the returned value will not be updated if`defaultValue` changes.\n * @param options Various options for adjusting how this hook runs the `promiseFactoryCallback`\n *\n * Note: this parameter is internally assigned to a `ref`, so changing it will not cause any hooks\n * to re-run with its new value. However, the latest `options.preserveValue` will always be used\n * appropriately to determine whether to preserve the returned value when changing the\n * `promiseFactoryCallback`\n * @returns `[value, isLoading]`\n *\n * - `value`: the current value for the promise, either the defaultValue or the resolved promise value\n * - `isLoading`: whether the promise is waiting to be resolved\n */\nconst usePromise = (\n promiseFactoryCallback: (() => Promise) | undefined,\n defaultValue: T,\n options: UsePromiseOptions = {},\n): [value: T, isLoading: boolean] => {\n // Use defaultValue as a ref so it doesn't update dependency arrays\n const defaultValueRef = useRef(defaultValue);\n defaultValueRef.current = defaultValue;\n // Use options as a ref so it doesn't update dependency arrays\n const optionsDefaultedRef = useRef(options);\n optionsDefaultedRef.current = getUsePromiseOptionsDefaults(optionsDefaultedRef.current);\n\n const [value, setValue] = useState(() => defaultValueRef.current);\n const [isLoading, setIsLoading] = useState(true);\n useEffect(() => {\n let promiseIsCurrent = true;\n // If a promiseFactoryCallback was provided, we are loading. Otherwise, there is no loading to do\n setIsLoading(!!promiseFactoryCallback);\n (async () => {\n // If there is a callback to run, run it\n if (promiseFactoryCallback) {\n const result = await promiseFactoryCallback();\n // If the promise was not already replaced, update the value\n if (promiseIsCurrent) {\n setValue(() => result);\n setIsLoading(false);\n }\n }\n })();\n\n return () => {\n // Mark this promise as old and not to be used\n promiseIsCurrent = false;\n if (!optionsDefaultedRef.current.preserveValue) setValue(() => defaultValueRef.current);\n };\n }, [promiseFactoryCallback]);\n\n return [value, isLoading];\n};\nexport default usePromise;\n","\"use client\";\n\nimport createSvgIcon from './utils/createSvgIcon';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nexport default createSvgIcon( /*#__PURE__*/_jsx(\"path\", {\n d: \"M3 18h18v-2H3zm0-5h18v-2H3zm0-7v2h18V6z\"\n}), 'Menu');","import GridMenu from '@/components/mui/grid-menu.component';\nimport { Command, CommandHandler } from '@/components/mui/menu-item.component';\nimport usePromise from '@/hooks/use-promise.hook';\nimport { Menu as MenuIcon } from '@mui/icons-material';\nimport { Drawer, IconButton } from '@mui/material';\nimport { Localized, MultiColumnMenu } from 'platform-bible-utils';\nimport {\n MouseEvent,\n MutableRefObject,\n PropsWithChildren,\n useCallback,\n useEffect,\n useState,\n} from 'react';\n\nexport interface MultiColumnMenuProvider {\n (isSupportAndDevelopment: boolean): Promise>;\n}\n\nexport type HamburgerMenuButtonProps = PropsWithChildren & {\n /** The handler to use for menu commands (and eventually toolbar commands). */\n commandHandler: CommandHandler;\n\n /**\n * Optional reference to the \"div\" container that determines the where the menu should appear. If\n * not defined, then (1,1) used.\n */\n containerRef?: MutableRefObject;\n\n /**\n * The delegate to use to get the menu data. If not specified or if it returns undefined, the data\n * in normalMenu or fullMenu property will be used.\n */\n menuProvider?: MultiColumnMenuProvider;\n\n /**\n * The menu data to show when the menu is opened if the menuProvider property is not defined.\n * (This allows for a default or test-only static menu to be used.)\n */\n normalMenu?: Localized;\n\n /**\n * The menu data to show for \"full\" menu (when opened with the SHIFT key pressed) if the\n * menuProvider property is not defined. (This allows for a default or test-only static menu to be\n * used.)\n */\n fullMenu?: Localized;\n\n /** Additional css class(es) to help with unique styling of the sub-components */\n className?: string;\n\n /** Value to use as prefix for ARIA labels on interactive sub-components */\n ariaLabelPrefix?: string;\n};\n\nexport default function HamburgerMenuButton({\n menuProvider,\n normalMenu,\n fullMenu,\n commandHandler,\n containerRef,\n className,\n ariaLabelPrefix,\n children,\n}: HamburgerMenuButtonProps) {\n const [isMenuOpen, setMenuOpen] = useState(false);\n const [showFullMenu, setShowFullMenu] = useState(false);\n\n const handleMenuItemClick = useCallback(() => {\n if (isMenuOpen) setMenuOpen(false);\n setShowFullMenu(false);\n }, [isMenuOpen]);\n\n const handleMenuButtonClick = useCallback((e: MouseEvent) => {\n e.stopPropagation();\n setMenuOpen((prevIsOpen) => {\n const isOpening = !prevIsOpen;\n if (isOpening && e.shiftKey) setShowFullMenu(true);\n else if (!isOpening) setShowFullMenu(false);\n return isOpening;\n });\n }, []);\n\n const menuCommandHandler = useCallback(\n (command: Command) => {\n handleMenuItemClick();\n return commandHandler(command);\n },\n [commandHandler, handleMenuItemClick],\n );\n\n const [offset, setOffset] = useState({ top: 1, left: 1 });\n\n useEffect(() => {\n if (isMenuOpen) {\n const node = containerRef?.current;\n if (node) {\n const rect = node.getBoundingClientRect();\n const scrollTop = window.scrollY;\n const scrollLeft = window.scrollX;\n const top = rect.top + scrollTop + node.clientHeight;\n const left = rect.left + scrollLeft;\n setOffset({ top, left });\n }\n }\n }, [isMenuOpen, containerRef]);\n\n const [normalMenuData] = usePromise(\n useCallback(async () => {\n return menuProvider?.(false) ?? normalMenu;\n // isMenuOpen needs to be included for the menu contents to reevaluate when reopened\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [menuProvider, normalMenu, isMenuOpen]),\n normalMenu,\n );\n\n const [fullMenuData] = usePromise(\n useCallback(async () => {\n return menuProvider?.(true) ?? fullMenu ?? normalMenuData;\n // isMenuOpen needs to be included for the menu contents to reevaluate when reopened\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [menuProvider, fullMenu, normalMenuData, isMenuOpen]),\n fullMenu ?? normalMenuData,\n );\n\n const menu = showFullMenu && fullMenuData ? fullMenuData : normalMenuData;\n\n return (\n <>\n \n {children ?? }\n \n \n {menu ? (\n \n ) : undefined}\n \n \n );\n}\n","import '@/components/mui/icon-button.component.css';\nimport { IconButton as MuiIconButton } from '@mui/material';\nimport { MouseEventHandler, PropsWithChildren } from 'react';\n\nexport type IconButtonProps = PropsWithChildren<{\n /** Optional unique identifier */\n id?: string;\n /**\n * Required. Used as both the tooltip (aka, title) and the aria-label (used for accessibility,\n * testing, etc.), unless a distinct tooltip is supplied.\n */\n label: string;\n /**\n * Enabled status of button\n *\n * @default false\n */\n isDisabled?: boolean;\n /** Optional tooltip to display if different from the aria-label. */\n tooltip?: string;\n /** If true, no tooltip will be displayed. */\n isTooltipSuppressed?: boolean;\n /**\n * If given, uses a negative margin to counteract the padding on one side (this is often helpful\n * for aligning the left or right side of the icon with content above or below, without ruining\n * the border size and shape).\n *\n * @default false\n */\n adjustMarginToAlignToEdge?: 'end' | 'start' | false;\n /**\n * The size of the component. small is equivalent to the dense button styling.\n *\n * @default false\n */\n size: 'small' | 'medium' | 'large';\n /** Additional css classes to help with unique styling of the button */\n className?: string;\n /** Optional click handler */\n onClick?: MouseEventHandler;\n}>;\n\n/**\n * Iconic button a user can click to do something\n *\n * Thanks to MUI for heavy inspiration and documentation\n * https://mui.com/material-ui/getting-started/overview/\n */\nfunction IconButton({\n id,\n label,\n isDisabled = false,\n tooltip,\n isTooltipSuppressed = false,\n adjustMarginToAlignToEdge = false,\n size = 'medium',\n className,\n onClick,\n children,\n}: IconButtonProps) {\n return (\n \n {children /* the icon to display */}\n \n );\n}\n\nexport default IconButton;\n","import { cn } from '@/utils/shadcn-ui.util';\nimport { LoaderCircle, LucideProps } from 'lucide-react';\nimport { forwardRef } from 'react';\n\nexport type SpinnerProps = LucideProps;\n\nconst Spinner = forwardRef(({ className, ...props }, ref) => {\n return (\n \n );\n});\n\nSpinner.displayName = 'Spinner';\n\nexport default Spinner;\n","import { Input as ShadInput } from '@/components/shadcn-ui/input';\nimport { Label as ShadLabel } from '@/components/shadcn-ui/label';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { ChangeEventHandler, FocusEventHandler } from 'react';\n\nexport type TextFieldProps = {\n /** Optional unique identifier */\n id?: string;\n /**\n * If `true`, the component is disabled.\n *\n * @default false\n */\n isDisabled?: boolean;\n /**\n * If `true`, the label is displayed in an error state.\n *\n * @default false\n */\n hasError?: boolean;\n /**\n * If `true`, the input will take up the full width of its container.\n *\n * @default false\n */\n isFullWidth?: boolean;\n /** Text that gives the user instructions on what contents the TextField expects */\n helperText?: string;\n /** The title of the TextField */\n label?: string;\n /** The short hint displayed in the `input` before the user enters a value. */\n placeholder?: string;\n /**\n * If `true`, the label is displayed as required and the `input` element is required.\n *\n * @default false\n */\n isRequired?: boolean;\n /** Additional css classes to help with unique styling of the text field */\n className?: string;\n /** Starting value for the text field if it is not controlled */\n defaultValue?: string | number;\n /** Value of the text field if controlled */\n value?: string | number;\n /** Triggers when content of textfield is changed */\n onChange?: ChangeEventHandler;\n /** Triggers when textfield gets focus */\n onFocus?: FocusEventHandler;\n /** Triggers when textfield loses focus */\n onBlur?: FocusEventHandler;\n};\n\n/**\n * Text input field\n *\n * Thanks to Shadcn for heavy inspiration and documentation\n * https://ui.shadcn.com/docs/components/input#with-label\n */\nfunction TextField({\n id,\n isDisabled = false,\n hasError = false,\n isFullWidth = false,\n helperText,\n label,\n placeholder,\n isRequired = false,\n className,\n defaultValue,\n value,\n onChange,\n onFocus,\n onBlur,\n}: TextFieldProps) {\n return (\n
    \n {`${label}${isRequired ? '*' : ''}`}\n \n

    {helperText}

    \n
    \n );\n}\n\nexport default TextField;\n","import HamburgerMenuButton, {\n MultiColumnMenuProvider,\n} from '@/components/mui/hamburger-menu-button.component';\nimport { CommandHandler } from '@/components/mui/menu-item.component';\nimport '@/components/mui/toolbar.component.css';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { AppBar, Toolbar as MuiToolbar } from '@mui/material';\nimport { PropsWithChildren, useRef } from 'react';\n\nexport type ToolbarProps = PropsWithChildren<{\n /** The handler to use for menu commands (and eventually toolbar commands). */\n commandHandler: CommandHandler;\n\n /**\n * The optional delegate to use to get the menu data. If not specified, the \"hamburger\" menu will\n * not display.\n */\n menuProvider?: MultiColumnMenuProvider;\n\n /** Optional unique identifier */\n id?: string;\n\n /** Additional css classes to help with unique styling of the toolbar */\n className?: string;\n}>;\n\nexport default function Toolbar({\n menuProvider,\n commandHandler,\n className,\n id,\n children,\n}: ToolbarProps) {\n // This ref will always be defined\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const containerRef = useRef(undefined!);\n\n return (\n
    \n \n \n {menuProvider ? (\n \n ) : undefined}\n {children ?
    {children}
    : undefined}\n \n
    \n
    \n );\n}\n","import React from 'react';\nimport { cva, type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst alertVariants = cva(\n 'tw-relative tw-w-full tw-rounded-lg tw-border tw-p-4 [&>svg~*]:tw-pl-7 [&>svg+div]:tw-translate-y-[-3px] [&>svg]:tw-absolute [&>svg]:tw-left-4 [&>svg]:tw-top-4 [&>svg]:tw-text-foreground',\n {\n variants: {\n variant: {\n default: 'tw-bg-background tw-text-foreground',\n destructive:\n 'tw-border-destructive/50 tw-text-destructive dark:tw-border-destructive [&>svg]:tw-text-destructive',\n },\n },\n defaultVariants: {\n variant: 'default',\n },\n },\n);\n\nconst Alert = React.forwardRef<\n HTMLDivElement,\n React.HTMLAttributes & VariantProps\n>(({ className, variant, ...props }, ref) => (\n
    \n));\nAlert.displayName = 'Alert';\n\nconst AlertTitle = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n {/* added because of https://github.com/jsx-eslint/eslint-plugin-jsx-a11y/blob/main/docs/rules/heading-has-content.md */}\n {props.children}{' '}\n \n ),\n);\nAlertTitle.displayName = 'AlertTitle';\n\nconst AlertDescription = React.forwardRef<\n HTMLParagraphElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n
    \n));\nAlertDescription.displayName = 'AlertDescription';\n\nexport { Alert, AlertTitle, AlertDescription };\n","import React from 'react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Card = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nCard.displayName = 'Card';\n\nconst CardHeader = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nCardHeader.displayName = 'CardHeader';\n\nconst CardTitle = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n {/* added because of https://github.com/jsx-eslint/eslint-plugin-jsx-a11y/blob/main/docs/rules/heading-has-content.md */}\n {props.children}\n \n ),\n);\nCardTitle.displayName = 'CardTitle';\n\nconst CardDescription = React.forwardRef<\n HTMLParagraphElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n

    \n));\nCardDescription.displayName = 'CardDescription';\n\nconst CardContent = React.forwardRef>(\n ({ className, ...props }, ref) => (\n

    \n ),\n);\nCardContent.displayName = 'CardContent';\n\nconst CardFooter = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nCardFooter.displayName = 'CardFooter';\n\nexport { Card, CardHeader, CardFooter, CardTitle, CardDescription, CardContent };\n","import { ComponentProps } from 'react';\nimport { toast as sonner, Toaster } from 'sonner';\n\ntype SonnerProps = ComponentProps;\n\nfunction Sonner({ ...props }: SonnerProps) {\n return (\n \n );\n}\n\n// The re-export of the sonner function was added manually\nexport { Sonner, sonner };\n","import React from 'react';\nimport * as SliderPrimitive from '@radix-ui/react-slider';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Slider = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n \n \n \n));\nSlider.displayName = SliderPrimitive.Root.displayName;\n\nexport { Slider };\n","import React from 'react';\nimport * as SwitchPrimitives from '@radix-ui/react-switch';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Switch = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n));\nSwitch.displayName = SwitchPrimitives.Root.displayName;\n\nexport { Switch };\n","import React from 'react';\nimport * as TabsPrimitive from '@radix-ui/react-tabs';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport const Tabs = TabsPrimitive.Root;\n\nexport type TabsListProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport type TabsTriggerProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport type TabsContentProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport const TabsList = React.forwardRef<\n React.ElementRef,\n TabsListProps\n>(({ className, ...props }, ref) => (\n \n));\nTabsList.displayName = TabsPrimitive.List.displayName;\n\nexport const TabsTrigger = React.forwardRef<\n React.ElementRef,\n TabsTriggerProps\n>(({ className, ...props }, ref) => (\n \n));\nTabsTrigger.displayName = TabsPrimitive.Trigger.displayName;\n\nexport const TabsContent = React.forwardRef<\n React.ElementRef,\n TabsContentProps\n>(({ className, ...props }, ref) => (\n \n));\nTabsContent.displayName = TabsPrimitive.Content.displayName;\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Download } from 'lucide-react';\n\ntype InstallButtonProps = {\n /** The installing boolean value determines the state of the button. */\n isInstalling: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n /** Optional text for the button. */\n buttonText?: string;\n} & ButtonProps;\n\n/**\n * The InstallButton component is a button designed for initiating installs. It includes visuals for\n * active installing and idle states.\n *\n * @param isInstalling The installing boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @param buttonText Optional text for the button.\n * @returns A install button.\n */\nexport default function InstallButton({\n isInstalling,\n handleClick,\n buttonText,\n className,\n ...props\n}: InstallButtonProps) {\n return (\n \n {isInstalling ? (\n \n ) : (\n <>\n \n {buttonText}\n \n )}\n \n );\n}\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\n\ntype EnableButtonProps = {\n /** The enabling boolean value determines the state of the button. */\n isEnabling: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n} & ButtonProps;\n\n/**\n * The EnableButton component is a button designed for initiating enabling of downloads. It includes\n * visuals for active enabling and idle states.\n *\n * @param isEnabling The enabling boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @returns A button that can be used to enable.\n */\nexport default function EnableButton({\n isEnabling,\n handleClick,\n className,\n ...props\n}: EnableButtonProps) {\n return (\n \n {isEnabling ? (\n <>\n \n Enabling...\n \n ) : (\n 'Enable'\n )}\n \n );\n}\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\n\ntype DisableButtonProps = {\n /** The disabling boolean value determines the state of the button. */\n isDisabling: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n} & ButtonProps;\n\n/**\n * The DisableButton component is a button designed for initiating disabling of downloads. It\n * includes visuals for active disabling and idle states.\n *\n * @param isDisabling The disabling boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @returns A button that can be used to disable.\n */\nexport default function DisableButton({\n isDisabling,\n handleClick,\n className,\n ...props\n}: DisableButtonProps) {\n return (\n \n {isDisabling ? (\n <>\n \n Disabling...\n \n ) : (\n 'Disable'\n )}\n \n );\n}\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\n\ntype UpdateButtonProps = {\n /** The updating boolean value determines the state of the button. */\n isUpdating: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n} & ButtonProps;\n\n/**\n * The UpdateButton component is a button designed for initiating updates for downloaded extensions.\n * It includes visuals for active updating and idle states.\n *\n * @param isUpdating The updating boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @returns A button that can be used to update.\n */\nexport default function UpdateButton({\n isUpdating,\n handleClick,\n className,\n ...props\n}: UpdateButtonProps) {\n return (\n \n {isUpdating ? (\n <>\n \n Updating...\n \n ) : (\n 'Update'\n )}\n \n );\n}\n","import { cn } from '@/utils/shadcn-ui.util';\nimport Markdown, { MarkdownToJSX } from 'markdown-to-jsx';\nimport { useMemo } from 'react';\n\ninterface MarkdownRendererProps {\n /** Optional unique identifier */\n id?: string;\n /** The markdown string to render */\n markdown: string;\n className?: string;\n /**\n * The [`target` attribute for `a` html\n * tags](https://developer.mozilla.org/en-US/docs/Web/HTML/Element/a#target). Defaults to not\n * adding a `target` to `a` tags\n */\n anchorTarget?: string;\n}\n\n/**\n * This component renders markdown content given a markdown string. It uses typography styles from\n * the platform.\n *\n * @param markdown The markdown string to render.\n * @param id Optional unique identifier\n * @returns A div containing the rendered markdown content.\n */\nexport default function MarkdownRenderer({\n id,\n markdown,\n className,\n anchorTarget,\n}: MarkdownRendererProps) {\n const options: MarkdownToJSX.Options = useMemo(\n () => ({\n overrides: {\n a: {\n props: {\n target: anchorTarget,\n },\n },\n },\n }),\n [anchorTarget],\n );\n return (\n
    \n {markdown}\n
    \n );\n}\n","import { Filter, ChevronDown } from 'lucide-react';\nimport { forwardRef } from 'react';\nimport { Button } from '@/components/shadcn-ui/button';\n\n/**\n * The FilterButton component is a button designed for initiating filtering of data. It is designed\n * to be used with the dropdown menu. It uses forwardRef to pass the button to the dropdown trigger\n * asChild.\n *\n * @returns A button that can be used to filter.\n */\nconst FilterButton = forwardRef((props, ref) => {\n return (\n \n \n Filter\n \n \n );\n});\n\nexport default FilterButton;\n","import {\n DropdownMenu,\n DropdownMenuTrigger,\n DropdownMenuContent,\n DropdownMenuLabel,\n DropdownMenuGroup,\n DropdownMenuCheckboxItem,\n DropdownMenuRadioItem,\n DropdownMenuSeparator,\n} from '@/components/shadcn-ui/dropdown-menu';\nimport FilterButton from './buttons/filter-button.component';\n\nexport enum DropdownMenuItemType {\n Check,\n Radio,\n}\n\nexport type DropdownItem = {\n /** The label is the text that will be displayed on the dropdown item. */\n label: string;\n /** The itemType determines the DropdownMenuItemType type as either Check or Radio. */\n itemType: DropdownMenuItemType;\n /** The onClick function is called when the item is clicked. */\n onClick: () => void;\n};\n\nexport type DropdownGroup = {\n /**\n * The label is the text that will be displayed on the dropdown group. It is used to categorize\n * the items in the group.\n */\n label: string;\n /** The items array contains the items that will be displayed in the dropdown group */\n items: DropdownItem[];\n};\n\nexport type FilterDropdownProps = {\n /** Object unique identifier */\n id?: string;\n /** The groups array contains the groups that will be displayed in the dropdown */\n groups: DropdownGroup[];\n}; // TODO: extend the props later\n\n/**\n * The FilterDropdown component is a dropdown designed for filtering content. It includes groups of\n * items that can be checkboxes or radio items.\n *\n * @param id Optional unique identifier\n * @param groups The groups array contains the groups that will be displayed in the dropdown\n * @returns A filter dropdown.\n */\nexport default function FilterDropdown({ id, groups }: FilterDropdownProps) {\n return (\n
    \n {/* TODO: remove this once the DropDown Menu shadcn has an id prop */}\n \n \n \n \n \n {groups.map((group) => (\n
    \n {group.label}\n \n {group.items.map((item) => (\n
    \n {item.itemType === DropdownMenuItemType.Check ? (\n \n {item.label}\n \n ) : (\n \n {item.label}\n \n )}\n
    \n ))}\n
    \n \n
    \n ))}\n
    \n
    \n
    \n );\n}\n","interface NoExtensionsFoundProps {\n /** Optional unique identifier */\n id?: string;\n /** The message to display */\n message: string;\n}\n/**\n * This component displays a message to the user when no extensions are found in the marketplace.\n *\n * @param id Optional unique identifier\n * @param message The message to display.\n * @returns {JSX.Element} - Returns the message component that displays the message to the user.\n */\nexport default function NoExtensionsFound({ id, message }: NoExtensionsFoundProps) {\n return (\n
    \n
    \n

    {message}

    \n
    \n
    \n );\n}\n","import { CircleHelp, Link as LucideLink, User } from 'lucide-react';\nimport { NumberFormat } from 'platform-bible-utils';\n\n/** Interface that stores the parameters passed to the More Info component */\ninterface MoreInfoProps {\n /** Optional unique identifier */\n id?: string;\n /** The category of the extension */\n category: string;\n /** The number of downloads for the extension */\n downloads: Record;\n /** The languages supported by the extension */\n languages: string[];\n /** The URL to the more info page of the extension */\n moreInfoUrl: string;\n}\n/**\n * This component displays the more info section of the extension which includes the category,\n * number of downloads, languages, and links to the website and support\n *\n * @param id Optional unique identifier\n * @param category The category of the extension\n * @param downloads The number of downloads for the extension\n * @param languages The languages supported by the extension\n * @param moreInfoUrl The URL to the more info page of the extension\n * @returns {JSX.Element} - Returns the more info component that displays the category, number of\n * downloads, languages, and links to the website and support\n */\nexport default function MoreInfo({\n id,\n category,\n downloads,\n languages,\n moreInfoUrl,\n}: MoreInfoProps) {\n /**\n * This constant formats the number of downloads into a more readable format.\n *\n * @example 1000 -> 1K\n *\n * @example 1000000 -> 1M\n *\n * @returns The formatted number of downloads\n */\n const numberFormatted = new NumberFormat('en', {\n notation: 'compact',\n compactDisplay: 'short',\n }).format(Object.values(downloads).reduce((a: number, b: number) => a + b, 0));\n\n /** This function scrolls the window to the bottom of the page. */\n const handleScrollToBottom = () => {\n window.scrollTo(0, document.body.scrollHeight);\n };\n\n return (\n \n
    \n
    \n {category}\n
    \n CATEGORY\n
    \n
    \n
    \n
    \n \n {numberFormatted}\n
    \n USERS\n
    \n
    \n
    \n
    \n {languages.slice(0, 3).map((locale) => (\n \n {locale.toUpperCase()}\n \n ))}\n
    \n {languages.length > 3 && (\n handleScrollToBottom()}\n className=\"tw-text-xs tw-text-gray-500 tw-underline\"\n >\n +{languages.length - 3} more languages\n \n )}\n
    \n
    \n
    \n \n Website\n \n \n \n Support\n \n \n
    \n
    \n );\n}\n","import { useState } from 'react';\n\nexport type VersionInformation = {\n /** Date the version was published */\n date: string;\n /** Description of the changes in the version */\n description: string;\n};\n\n/** Type to store the version history information */\nexport type VersionHistoryType = Record;\n\n/** Interface that stores the parameters passed to the Version History component */\ninterface VersionHistoryProps {\n /** Optional unique identifier */\n id?: string;\n /** Object containing the versions mapped with their information */\n versionHistory: VersionHistoryType;\n}\n\n/**\n * Component to render the version history information shown in the footer component. Lists the 5\n * most recent versions, with the options to show all versions by pressing a button.\n *\n * @param versionHistory Object containing the versions mapped with their information\n * @param id Optional unique identifier\n * @returns Rendered version history for the Footer component\n */\nexport default function VersionHistory({ id, versionHistory }: VersionHistoryProps) {\n const [showAllVersions, setShowAllVersions] = useState(false);\n const currentDate = new Date();\n\n /**\n * Function to format the time string for the version history in the form of 'X year(s) ago'.\n *\n * @param dateString ISO Date string to determine the time string from\n * @returns Formatted time string\n */\n function formatTimeString(dateString: string) {\n const date = new Date(dateString);\n const dateDiff = new Date(currentDate.getTime() - date.getTime());\n const yearDiff = dateDiff.getUTCFullYear() - 1970;\n const monthDiff = dateDiff.getUTCMonth();\n const dayDiff = dateDiff.getUTCDate() - 1;\n\n // Determines how long ago the version was published\n let timeString = '';\n if (yearDiff > 0) {\n timeString = `${yearDiff.toString()} year${yearDiff === 1 ? '' : 's'} ago`;\n } else if (monthDiff > 0) {\n timeString = `${monthDiff.toString()} month${monthDiff === 1 ? '' : 's'} ago`;\n } else if (dayDiff === 0) {\n timeString = 'today';\n } else {\n timeString = `${dayDiff.toString()} day${dayDiff === 1 ? '' : 's'} ago`;\n }\n\n return timeString;\n }\n\n // Sorts the version history by version number\n const sortedEntries = Object.entries(versionHistory).sort((a, b) => b[0].localeCompare(a[0]));\n\n return (\n
    \n

    What`s New

    \n
      \n {(showAllVersions ? sortedEntries : sortedEntries.slice(0, 5)).map((entry) => (\n
      \n
      \n
    • \n {entry[1].description}\n
    • \n
      \n
      \n
      Version {entry[0]}
      \n
      {formatTimeString(entry[1].date)}
      \n
      \n
      \n ))}\n
    \n {sortedEntries.length > 5 && (\n setShowAllVersions(!showAllVersions)}\n className=\"tw-text-xs tw-text-gray-500 tw-underline\"\n >\n {showAllVersions ? 'Show Less Version History' : 'Show All Version History'}\n \n )}\n
    \n );\n}\n","import { useMemo } from 'react';\nimport { formatBytes } from 'platform-bible-utils';\nimport VersionHistory, { VersionHistoryType } from './version-history.component';\n\n/** Interface to store the parameters passed to the Footer component */\ninterface FooterProps {\n /** Optional unique identifier */\n id?: string;\n /** Name of the publisher */\n publisherDisplayName: string;\n /** Size of the extension file in bytes */\n fileSize: number;\n /** List of language codes supported by the extension */\n locales: string[];\n /** Object containing the version history mapped with their information */\n versionHistory: VersionHistoryType;\n}\n\n/**\n * Component to render the footer for the extension details which contains information on the\n * publisher, version history, languages, and file size.\n *\n * @param id Optional unique identifier\n * @param publisherDisplayName Name of the publisher\n * @param fileSize Size of the extension file in bytes\n * @param locales List of language codes supported by the extension\n * @param versionHistory Object containing the version history mapped with their information\n * @returns The rendered Footer component\n */\nexport default function Footer({\n id,\n publisherDisplayName,\n fileSize,\n locales,\n versionHistory,\n}: FooterProps) {\n /** Formats the file size into a human-readable format */\n const formattedFileSize = useMemo(() => formatBytes(fileSize), [fileSize]);\n\n /**\n * This function gets the display names of the languages based on the language codes.\n *\n * @param codes The list of language codes\n * @returns The list of language names\n */\n const getLanguageNames = (codes: string[]) => {\n const displayNames = new Intl.DisplayNames(navigator.language, { type: 'language' });\n return codes.map((code) => displayNames.of(code));\n };\n\n const languageNames = getLanguageNames(locales);\n\n return (\n
    \n
    \n \n
    \n
    \n

    Information

    \n
    \n

    \n Publisher\n {publisherDisplayName}\n Size\n {formattedFileSize}\n

    \n
    \n

    \n Languages\n {languageNames.join(', ')}\n

    \n
    \n
    \n
    \n
    \n
    \n );\n}\n","import { PlatformEvent, PlatformEventHandler } from 'platform-bible-utils';\nimport { useEffect } from 'react';\n\n/**\n * Adds an event handler to an event so the event handler runs when the event is emitted. Use\n * `papi.network.getNetworkEvent` to use a networked event with this hook.\n *\n * @param event The event to subscribe to.\n *\n * - If event is a `PlatformEvent`, that event will be used\n * - If event is undefined, the callback will not be subscribed. Useful if the event is not yet\n * available for example\n *\n * @param eventHandler The callback to run when the event is emitted\n *\n * WARNING: MUST BE STABLE - const or wrapped in useCallback. The reference must not be updated\n * every render\n */\nconst useEvent = (\n event: PlatformEvent | undefined,\n eventHandler: PlatformEventHandler,\n) => {\n useEffect(() => {\n // Do nothing if the event is not provided (in case the event is not yet available, for example)\n if (!event) return () => {};\n\n const unsubscriber = event(eventHandler);\n return () => {\n unsubscriber();\n };\n }, [event, eventHandler]);\n};\nexport default useEvent;\n","import { useCallback, useEffect } from 'react';\nimport { PlatformEvent, PlatformEventAsync, PlatformEventHandler } from 'platform-bible-utils';\nimport usePromise from './use-promise.hook';\n\nconst noopUnsubscriber = () => false;\n\n/**\n * Adds an event handler to an asynchronously subscribing/unsubscribing event so the event handler\n * runs when the event is emitted. Use `papi.network.getNetworkEvent` to use a networked event with\n * this hook.\n *\n * @param event The asynchronously (un)subscribing event to subscribe to.\n *\n * - If event is a `PlatformEvent` or `PlatformEventAsync`, that event will be used\n * - If event is undefined, the callback will not be subscribed. Useful if the event is not yet\n * available for example\n *\n * @param eventHandler The callback to run when the event is emitted\n *\n * WARNING: MUST BE STABLE - const or wrapped in useCallback. The reference must not be updated\n * every render\n */\nconst useEventAsync = (\n event: PlatformEvent | PlatformEventAsync | undefined,\n eventHandler: PlatformEventHandler,\n) => {\n // Subscribe to the event asynchronously\n const [unsubscribe] = usePromise(\n useCallback(async () => {\n // Do nothing if the event is not provided (in case the event is not yet available, for example)\n if (!event) return noopUnsubscriber;\n\n // Wrap subscribe and unsubscribe in promises to allow normal events to be used as well\n const unsub = await Promise.resolve(event(eventHandler));\n return async () => unsub();\n }, [eventHandler, event]),\n noopUnsubscriber,\n // We want the unsubscriber to return to default value immediately upon changing subscription\n // So the useEffect below will unsubscribe asap\n { preserveValue: false },\n );\n\n // Unsubscribe from the event asynchronously (but we aren't awaiting the unsub)\n useEffect(() => {\n return () => {\n if (unsubscribe !== noopUnsubscriber) {\n unsubscribe();\n }\n };\n }, [unsubscribe]);\n};\n\nexport default useEventAsync;\n"],"names":["twMergeCustom","extendTailwindMerge","cn","inputs","clsx","Input","React","className","type","props","ref","jsx","BookChapterInput","forwardRef","handleSearch","handleKeyDown","handleOnClick","handleSubmit","jsxs","ShadInput","event","e","History","P","R","t","s","n","N","B","O","S","K","g","k","x","T","X","V","w","L","G","A","H","C","I","y","q","U","m","l","h","c","E","D","i","a","o","u","v","f","d","b","p","J","DropdownMenu","DropdownMenuPrimitive","DropdownMenuTrigger","DropdownMenuGroup","DropdownMenuPortal","DropdownMenuSub","DropdownMenuRadioGroup","DropdownMenuSubTrigger","inset","children","ChevronRight","DropdownMenuSubContent","DropdownMenuContent","sideOffset","DropdownMenuItem","DropdownMenuCheckboxItem","checked","Check","DropdownMenuRadioItem","Circle","DropdownMenuLabel","DropdownMenuSeparator","DropdownMenuShortcut","BookMenuItem","bookId","handleSelectBook","isSelected","handleHighlightBook","bookType","ShadDropdownMenuItem","Canon","ChapterSelect","handleSelectChapter","endChapter","activeChapter","highlightedChapter","handleHighlightedChapter","chapters","_","handleMouse","useCallback","chapterNumber","chapter","GoToMenuItem","handleSort","handleLocationHistory","handleBookmarks","ShadDropdownMenuLabel","ArrowDownWideNarrow","Clock","Bookmark","ALL_BOOK_IDS","BOOK_TYPE_LABELS","BOOK_TYPE_ARRAY","SCROLL_OFFSET","SEARCH_QUERY_FORMATS","fetchGroupedBooks","fetchEndChapter","getChaptersForBook","getAllEnglishNames","isValidBookEnglishName","bookName","getBookIdFromEnglishName","formattedBookName","BookChapterControl","scrRef","searchQuery","setSearchQuery","useState","selectedBookId","setSelectedBookId","setHighlightedChapter","highlightedBookId","setHighlightedBookId","isContentOpen","setIsContentOpen","isContentOpenDelayed","setIsContentOpenDelayed","inputRef","useRef","contentRef","menuItemRef","fetchFilteredBooks","englishNameLowerCase","normalizedQuery","handleSearchInput","searchString","shouldPreventAutoClosing","controlMenuState","open","updateReference","shouldClose","verse","handleInputSubmit","format","matches","book","englishName","handleKeyDownInput","handleKeyDownContent","key","handleKeyDownMenuItem","chapterOffSet","useEffect","useLayoutEffect","scrollTimeout","scrollPosition","ShadDropdownMenu","ShadDropdownMenuTrigger","ShadDropdownMenuContent","bookTypeIndex","element","ShadDropdownMenuSeparator","buttonVariants","cva","Button","variant","size","asChild","Comp","Slot","labelVariants","Label","LabelPrimitive","RadioGroup","RadioGroupPrimitive","RadioGroupItem","Popover","PopoverPrimitive","PopoverTrigger","PopoverContent","align","DialogPortal","DialogPrimitive","DialogOverlay","DialogContent","DialogTitle","DialogDescription","Command","CommandPrimitive","CommandInput","Search","CommandList","CommandEmpty","CommandGroup","CommandSeparator","CommandItem","getOptionLabelDefault","option","ComboBox","id","options","buttonClassName","popoverContentClassName","value","onChange","getOptionLabel","buttonPlaceholder","textPlaceholder","commandEmptyMessage","buttonVariant","dir","isDisabled","setOpen","ChevronsUpDown","ChapterRangeSelector","startChapter","handleSelectStartChapter","handleSelectEndChapter","chapterCount","chapterOptions","useMemo","index","onChangeStartChapter","onChangeEndChapter","Fragment","BookSelectionMode","BOOK_SELECTOR_STRING_KEYS","localizeString","strings","BookSelector","handleBookSelectionModeChange","currentBookName","onSelectBooks","selectedBookIds","localizedStrings","currentBookText","chooseText","chooseBooksText","bookSelectionMode","setBookSelectionMode","onSelectionModeChange","newMode","DataTableViewOptions","table","FilterIcon","column","Select","SelectPrimitive","SelectGroup","SelectValue","SelectTrigger","ChevronDown","SelectScrollUpButton","ChevronUp","SelectScrollDownButton","SelectContent","position","SelectLabel","SelectItem","SelectSeparator","DataTablePagination","pageSize","ArrowLeftIcon","ChevronLeftIcon","ChevronRightIcon","ArrowRightIcon","Table","stickyHeader","TableHeader","TableBody","TableFooter","TableRow","TableHead","TableCell","TableCaption","DataTable","columns","data","enablePagination","showPaginationControls","showColumnVisibilityControls","onRowClickHandler","sorting","setSorting","columnFilters","setColumnFilters","columnVisibility","setColumnVisibility","rowSelection","setRowSelection","useReactTable","getCoreRowModel","getPaginationRowModel","getSortedRowModel","getFilteredRowModel","headerGroup","header","flexRender","_a","row","cell","OccurrencesTable","occurrenceData","setScriptureReference","referenceHeaderText","occurrenceHeaderText","occurrences","uniqueOccurrences","occurrence","uniqueOccurrence","deepEqual","Checkbox","CheckboxPrimitive","getLinesFromUSFM","text","getNumberFromUSFM","regex","match","getBookNumFromId","getStatusForItem","item","approvedItems","unapprovedItems","toggleVariants","Toggle","TogglePrimitive","ToggleGroupContext","ToggleGroup","ToggleGroupPrimitive","ToggleGroupItem","context","getSortingIcon","sortDirection","ArrowUpIcon","ArrowDownIcon","ArrowUpDownIcon","inventoryItemColumn","itemLabel","inventoryAdditionalItemColumn","additionalItemLabel","additionalItemIndex","inventoryCountColumn","countLabel","statusChangeHandler","changedItems","newStatus","onApprovedItemsChange","onUnapprovedItemsChange","newApprovedItems","validItem","newUnapprovedItems","unapprovedItem","inventoryStatusColumn","statusLabel","status","CircleCheckIcon","CircleXIcon","CircleHelpIcon","INVENTORY_STRING_KEYS","filterItemData","itemData","statusFilter","textFilter","filteredItemData","createTableData","scriptureRef","itemRegex","tableData","currentBook","currentChapter","currentVerse","line","items","itemIndex","existingItem","tableEntry","newReference","substring","newItem","Inventory","scriptureReference","extractItems","additionalItemsLabels","scope","onScopeChange","allItemsText","approvedItemsText","unapprovedItemsText","unknownItemsText","scopeBookText","scopeChapterText","scopeVerseText","filterText","showAdditionalItemsText","showAdditionalItems","setShowAdditionalItems","setStatusFilter","setTextFilter","selectedItem","setSelectedItem","reducedTableData","newTableData","firstItem","existingEntry","newTableEntry","filteredTableData","allColumns","numberOfAdditionalItems","additionalColumns","_b","rowClickHandler","newSelection","handleScopeChange","handleStatusFilterChange","SearchBar","onSearch","placeholder","isFullWidth","handleInputChange","VerticalTabs","TabsPrimitive","VerticalTabsList","VerticalTabsTrigger","VerticalTabsContent","TabNavigationContentSearch","tabList","searchPlaceholder","headerTitle","isSearchBarFullWidth","direction","tab","Separator","orientation","decorative","SeparatorPrimitive","Sheet","SheetPrimitive","SheetPortal","SheetOverlay","sheetVariants","SheetContent","side","SheetTitle","SheetDescription","Skeleton","TooltipProvider","TooltipPrimitive","Tooltip","TooltipTrigger","TooltipContent","MOBILE_BREAKPOINT","useIsMobile","isMobile","setIsMobile","mql","SIDEBAR_COOKIE_NAME","SIDEBAR_COOKIE_MAX_AGE","SIDEBAR_WIDTH","SIDEBAR_WIDTH_MOBILE","SIDEBAR_WIDTH_ICON","SIDEBAR_KEYBOARD_SHORTCUT","SidebarContext","useSidebar","SidebarProvider","defaultOpen","openProp","setOpenProp","style","openMobile","setOpenMobile","_open","_setOpen","isOpen","openState","toggleSidebar","state","contextValue","Sidebar","collapsible","SidebarTrigger","onClick","PanelLeft","SidebarRail","SidebarInset","SidebarInput","SidebarHeader","SidebarFooter","SidebarSeparator","SidebarContent","SidebarGroup","SidebarGroupLabel","SidebarGroupAction","SidebarGroupContent","SidebarMenu","SidebarMenuItem","sidebarMenuButtonVariants","SidebarMenuButton","isActive","tooltip","button","SidebarMenuAction","showOnHover","SidebarMenuBadge","SidebarMenuSkeleton","showIcon","width","SidebarMenuSub","SidebarMenuSubItem","SidebarMenuSubButton","SettingsSidebar","extensionLabels","projectOptions","handleSelectSidebarItem","selectedSidebarItem","extensionsSidebarGroupLabel","projectsSidebarGroupLabel","buttonPlaceholderText","handleSelectItem","projectId","getProjectNameFromProjectId","project","getIsActive","label","selectedProjectName","SettingsSidebarContentSearch","scrBookColId","scrRefColId","typeColId","detailsColId","defaultScrRefColumnName","defaultScrBookGroupName","defaultTypeColumnName","defaultDetailsColumnName","getColumns","colInfo","showSourceColumn","showSrcCol","info","formatScrRef","compareScrRefs","toRefOrRange","scriptureSelection","offsetStart","offsetEnd","scrRefToBBBCCCVVV","getRowKey","ScriptureResultsViewer","sources","showColumnHeaders","scriptureReferenceColumnName","scriptureBookGroupName","typeColumnName","detailsColumnName","onRowSelected","grouping","setGrouping","scriptureResults","source","getExpandedRowModel","getGroupedRowModel","selectedRows","keys","selectedRow","scrBookGroupName","typeGroupName","groupingOptions","handleSelectChange","selectedGrouping","handleRowClick","getEvenOrOddBandingStyle","getIndent","groupingState","rowIndex","ChevronLeft","DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS","getLocalizeKeyForScrollGroupId","ScrollGroupSelector","availableScrollGroupIds","scrollGroupId","onChangeScrollGroupId","localizedStringsDefaulted","localizedStringKey","localizedStringValue","newScrollGroupString","scrollGroupOptionId","SettingsList","SettingsListItem","primary","secondary","isLoading","loadingMessage","SettingsListHeader","includeSeparator","Checklist","listItems","selectedListItems","handleSelectListItem","createLabel","_interopRequireDefault","obj","module","chainPropTypes","propType1","propType2","args","_extends","target","isPlainObject","prototype","deepClone","output","deepmerge","r","z","reactIs_production_min","hasSymbol","REACT_ELEMENT_TYPE","REACT_PORTAL_TYPE","REACT_FRAGMENT_TYPE","REACT_STRICT_MODE_TYPE","REACT_PROFILER_TYPE","REACT_PROVIDER_TYPE","REACT_CONTEXT_TYPE","REACT_ASYNC_MODE_TYPE","REACT_CONCURRENT_MODE_TYPE","REACT_FORWARD_REF_TYPE","REACT_SUSPENSE_TYPE","REACT_SUSPENSE_LIST_TYPE","REACT_MEMO_TYPE","REACT_LAZY_TYPE","REACT_BLOCK_TYPE","REACT_FUNDAMENTAL_TYPE","REACT_RESPONDER_TYPE","REACT_SCOPE_TYPE","isValidElementType","typeOf","object","$$typeof","$$typeofType","AsyncMode","ConcurrentMode","ContextConsumer","ContextProvider","Element","ForwardRef","Lazy","Memo","Portal","Profiler","StrictMode","Suspense","hasWarnedAboutDeprecatedIsAsyncMode","isAsyncMode","isConcurrentMode","isContextConsumer","isContextProvider","isElement","isForwardRef","isFragment","isLazy","isMemo","isPortal","isProfiler","isStrictMode","isSuspense","reactIs_development","reactIsModule","require$$0","require$$1","getOwnPropertySymbols","hasOwnProperty","propIsEnumerable","toObject","val","shouldUseNative","test1","test2","order2","test3","letter","objectAssign","from","to","symbols","ReactPropTypesSecret","ReactPropTypesSecret_1","has","printWarning","loggedTypeFailures","message","checkPropTypes","typeSpecs","values","location","componentName","getStack","typeSpecName","error","err","ex","stack","checkPropTypes_1","ReactIs","assign","require$$2","require$$3","require$$4","emptyFunctionThatReturnsNull","factoryWithTypeCheckers","isValidElement","throwOnDirectAccess","ITERATOR_SYMBOL","FAUX_ITERATOR_SYMBOL","getIteratorFn","maybeIterable","iteratorFn","ANONYMOUS","ReactPropTypes","createPrimitiveTypeChecker","createAnyTypeChecker","createArrayOfTypeChecker","createElementTypeChecker","createElementTypeTypeChecker","createInstanceTypeChecker","createNodeChecker","createObjectOfTypeChecker","createEnumTypeChecker","createUnionTypeChecker","createShapeTypeChecker","createStrictShapeTypeChecker","is","PropTypeError","createChainableTypeChecker","validate","manualPropTypeCallCache","manualPropTypeWarningCount","checkType","isRequired","propName","propFullName","secret","cacheKey","chainedCheckType","expectedType","propValue","propType","getPropType","preciseType","getPreciseType","typeChecker","expectedClass","expectedClassName","actualClassName","getClassName","expectedValues","valuesString","arrayOfTypeCheckers","checker","getPostfixForTypeWarning","expectedTypes","checkerResult","expectedTypesMessage","isNode","invalidValidatorError","shapeTypes","allKeys","iterator","step","entry","isSymbol","emptyFunction","emptyFunctionWithReset","factoryWithThrowingShims","shim","getShim","propTypesModule","isClassComponent","elementType","acceptingRef","safePropName","warningHint","elementAcceptingRef","PropTypes","elementAcceptingRef$1","specialProperty","exactProp","propTypes","unsupportedProps","prop","formatMuiErrorMessage","code","url","REACT_SERVER_CONTEXT_TYPE","REACT_OFFSCREEN_TYPE","enableScopeAPI","enableCacheElement","enableTransitionTracing","enableLegacyHidden","enableDebugTracing","REACT_MODULE_REFERENCE","SuspenseList","hasWarnedAboutDeprecatedIsConcurrentMode","isSuspenseList","fnNameMatchRegex","getFunctionName","fn","getFunctionComponentName","Component","fallback","getWrappedName","outerType","innerType","wrapperName","functionName","getDisplayName","HTMLElementType","refType","refType$1","capitalize","string","_formatMuiErrorMessage","createChainedFunction","funcs","acc","func","debounce","wait","timeout","debounced","later","deprecatedPropType","validator","reason","componentNameSafe","propFullNameSafe","isMuiElement","muiNames","_muiName","_element$type","ownerDocument","node","ownerWindow","requirePropFactory","componentNameInError","prevPropTypes","requiredProp","defaultTypeChecker","typeCheckerResult","setRef","useEnhancedEffect","useEnhancedEffect$1","globalId","useGlobalId","idOverride","defaultId","setDefaultId","maybeReactUseId","useId","reactId","unsupportedProp","useControlled","controlled","defaultProp","name","isControlled","valueState","setValue","defaultValue","setValueIfUncontrolled","newValue","useEventCallback","useForkRef","refs","instance","UNINITIALIZED","useLazyRef","init","initArg","EMPTY","useOnMount","Timeout","delay","useTimeout","hadKeyboardEvent","hadFocusVisibleRecently","hadFocusVisibleRecentlyTimeout","inputTypesWhitelist","focusTriggersKeyboardModality","tagName","handlePointerDown","handleVisibilityChange","prepare","doc","isFocusVisible","useIsFocusVisible","isFocusVisibleRef","handleBlurVisible","handleFocusVisible","resolveProps","defaultProps","defaultSlotProps","slotProps","slotPropName","composeClasses","slots","getUtilityClass","classes","slot","utilityClass","defaultGenerator","createClassNameGenerator","generate","generator","ClassNameGenerator","ClassNameGenerator$1","globalStateClasses","generateUtilityClass","globalStatePrefix","globalStateClass","generateUtilityClasses","result","clamp","min","max","_objectWithoutPropertiesLoose","excluded","sourceKeys","_excluded","sortBreakpointsValues","breakpointsAsArray","breakpoint1","breakpoint2","createBreakpoints","breakpoints","unit","other","sortedValues","up","down","between","start","end","endIndex","only","not","keyIndex","shape","shape$1","responsivePropType","responsivePropType$1","merge","defaultBreakpoints","handleBreakpoints","styleFromPropValue","theme","themeBreakpoints","breakpoint","mediaKey","cssKey","createEmptyBreakpointObject","breakpointsInput","_breakpointsInput$key","breakpointStyleKey","removeUnusedBreakpoints","breakpointKeys","breakpointOutput","getPath","path","checkVars","getStyleValue","themeMapping","transform","propValueFinal","userValue","cssProperty","themeKey","memoize","cache","arg","properties","directions","aliases","getCssProperties","property","marginKeys","paddingKeys","spacingKeys","createUnaryUnit","_getPath","themeSpacing","abs","createUnarySpacing","getValue","transformer","transformed","getStyleFromPropValue","cssProperties","resolveCssProperty","margin","padding","createSpacing","spacingInput","spacing","argsInput","argument","compose","styles","handlers","borderTransform","createBorderStyle","border","borderTop","borderRight","borderBottom","borderLeft","borderColor","borderTopColor","borderRightColor","borderBottomColor","borderLeftColor","outline","outlineColor","borderRadius","gap","columnGap","rowGap","gridColumn","gridRow","gridAutoFlow","gridAutoColumns","gridAutoRows","gridTemplateColumns","gridTemplateRows","gridTemplateAreas","gridArea","paletteTransform","color","bgcolor","backgroundColor","sizingTransform","maxWidth","_props$theme","_props$theme2","breakpointsValues","minWidth","height","maxHeight","minHeight","boxSizing","defaultSxConfig","defaultSxConfig$1","objectsHaveSameKeys","objects","union","callIfFn","maybeFn","unstable_createStyleFunctionSx","getThemeValue","config","styleFunctionSx","_theme$unstable_sxCon","sx","traverse","sxInput","sxObject","emptyBreakpoints","breakpointsKeys","css","styleKey","styleFunctionSx$1","applyStyles","createTheme","paletteInput","shapeInput","muiTheme","isObjectEmpty","useTheme","defaultTheme","contextTheme","ThemeContext","systemDefaultTheme","useThemeWithoutDefault","_excluded2","_excluded3","isEmpty","isStringTag","tag","shouldForwardProp","lowercaseFirstLetter","resolveTheme","themeId","defaultOverridesResolver","processStyleArg","callableStyle","_ref","ownerState","resolvedStylesArg","resolvedStyle","variants","isMatch","createStyled","input","rootShouldForwardProp","slotShouldForwardProp","systemSx","inputOptions","processStyles","componentSlot","inputSkipVariantsResolver","inputSkipSx","overridesResolver","skipVariantsResolver","skipSx","shouldForwardPropOption","defaultStyledResolver","styledEngineStyled","transformStyleArg","stylesArg","muiStyledResolver","styleArg","expressions","transformedStyleArg","expressionsWithDefaultTheme","styleOverrides","resolvedStyleOverrides","slotKey","slotStyle","_theme$components","themeVariants","numOfCustomFnsApplied","placeholders","displayName","getThemeProps","params","useThemeProps","clampWrapper","hexToRgb","re","colors","decomposeColor","marker","colorSpace","recomposeColor","hslToRgb","rgb","getLuminance","getContrastRatio","foreground","background","lumA","lumB","alpha","darken","coefficient","lighten","createMixins","mixins","common","common$1","grey","grey$1","purple","purple$1","red","red$1","orange","orange$1","blue","blue$1","lightBlue","lightBlue$1","green","green$1","light","dark","addLightOrDark","intent","shade","tonalOffset","tonalOffsetLight","tonalOffsetDark","getDefaultPrimary","mode","getDefaultSecondary","getDefaultError","getDefaultInfo","getDefaultSuccess","getDefaultWarning","createPalette","palette","contrastThreshold","success","warning","getContrastText","contrastText","contrast","augmentColor","mainShade","lightShade","darkShade","modes","round","caseAllCaps","defaultFontFamily","createTypography","typography","fontFamily","fontSize","fontWeightLight","fontWeightRegular","fontWeightMedium","fontWeightBold","htmlFontSize","allVariants","pxToRem2","coef","pxToRem","buildVariant","fontWeight","lineHeight","letterSpacing","casing","shadowKeyUmbraOpacity","shadowKeyPenumbraOpacity","shadowAmbientShadowOpacity","createShadow","px","shadows","shadows$1","easing","duration","formatMs","milliseconds","getAutoHeightDuration","constant","createTransitions","inputTransitions","mergedEasing","mergedDuration","durationOption","easingOption","isString","isNumber","animatedProp","zIndex","zIndex$1","mixinsInput","transitionsInput","typographyInput","systemTheme","systemCreateTheme","stateClasses","component","child","stateClass","defaultTheme$1","THEME_ID","systemUseThemeProps","styled","styled$1","getSvgIconUtilityClass","useUtilityClasses","SvgIconRoot","_theme$transitions","_theme$transitions$cr","_theme$transitions2","_theme$typography","_theme$typography$pxT","_theme$typography2","_theme$typography2$px","_theme$typography3","_theme$typography3$px","_palette$ownerState$c","_palette","_palette2","_palette3","SvgIcon","inProps","htmlColor","inheritViewBox","titleAccess","viewBox","hasSvgAsChild","more","_jsxs","_jsx","SvgIcon$1","createSvgIcon","unstable_ClassNameGenerator","exports","_utils","ArrowRight","default_1","_createSvgIcon","_jsxRuntime","isHostComponent","appendOwnerState","otherProps","defaultContextValue","ClassNameConfiguratorContext","useClassNamesOverride","disableDefaultClasses","extractEventHandlers","excludeKeys","resolveComponentProps","componentProps","slotState","omitEventHandlers","mergeSlotProps","parameters","getSlotProps","additionalProps","externalSlotProps","externalForwardedProps","joinedClasses","mergedStyle","eventHandlers","componentsPropsWithoutEventHandlers","otherPropsWithoutEventHandlers","internalSlotProps","useSlotProps","_parameters$additiona","skipResolvingSlotProps","rest","resolvedComponentsProps","mergedProps","internalRef","GLOBAL_CLASS_PREFIX","buildStateClass","buildSlotClass","getContainer","container","forwardedRef","disablePortal","mountNode","setMountNode","handleRef","newProps","ReactDOM","top","bottom","right","left","auto","basePlacements","clippingParents","viewport","popper","reference","variationPlacements","placement","placements","beforeRead","read","afterRead","beforeMain","main","afterMain","beforeWrite","write","afterWrite","modifierPhases","getNodeName","getWindow","OwnElement","isHTMLElement","isShadowRoot","attributes","effect","_ref2","initialStyles","styleProperties","attribute","applyStyles$1","getBasePlacement","getUAString","uaData","isLayoutViewport","getBoundingClientRect","includeScale","isFixedStrategy","clientRect","scaleX","scaleY","visualViewport","addVisualOffsets","getLayoutRect","contains","parent","rootNode","next","getComputedStyle","isTableElement","getDocumentElement","getParentNode","getTrueOffsetParent","getContainingBlock","isFirefox","isIE","elementCss","currentNode","getOffsetParent","window","offsetParent","getMainAxisFromPlacement","within","mathMax","mathMin","withinMaxClamp","getFreshSideObject","mergePaddingObject","paddingObject","expandToHashMap","hashMap","toPaddingObject","arrow","_state$modifiersData$","arrowElement","popperOffsets","basePlacement","axis","isVertical","len","arrowRect","minProp","maxProp","endDiff","startDiff","arrowOffsetParent","clientSize","centerToReference","center","offset","axisProp","_options$element","arrow$1","getVariation","unsetSides","roundOffsetsByDPR","win","dpr","mapToStyles","_Object$assign2","popperRect","variation","offsets","gpuAcceleration","adaptive","roundOffsets","isFixed","_offsets$x","_offsets$y","_ref3","hasX","hasY","sideX","sideY","heightProp","widthProp","offsetY","offsetX","commonStyles","_ref4","_Object$assign","computeStyles","_ref5","_options$gpuAccelerat","_options$adaptive","_options$roundOffsets","computeStyles$1","passive","_options$scroll","scroll","_options$resize","resize","scrollParents","scrollParent","eventListeners","hash","getOppositePlacement","matched","getOppositeVariationPlacement","getWindowScroll","scrollLeft","scrollTop","getWindowScrollBarX","getViewportRect","strategy","html","layoutViewport","getDocumentRect","_element$ownerDocumen","winScroll","body","isScrollParent","_getComputedStyle","overflow","overflowX","overflowY","getScrollParent","listScrollParents","list","isBody","updatedList","rectToClientRect","rect","getInnerBoundingClientRect","getClientRectFromMixedType","clippingParent","getClippingParents","canEscapeClipping","clipperElement","getClippingRect","boundary","rootBoundary","mainClippingParents","firstClippingParent","clippingRect","accRect","computeOffsets","commonX","commonY","mainAxis","detectOverflow","_options","_options$placement","_options$strategy","_options$boundary","_options$rootBoundary","_options$elementConte","elementContext","_options$altBoundary","altBoundary","_options$padding","altContext","clippingClientRect","referenceClientRect","popperClientRect","elementClientRect","overflowOffsets","offsetData","multiply","computeAutoPlacement","flipVariations","_options$allowedAutoP","allowedAutoPlacements","allPlacements","allowedPlacements","overflows","getExpandedFallbackPlacements","oppositePlacement","flip","_options$mainAxis","checkMainAxis","_options$altAxis","checkAltAxis","specifiedFallbackPlacements","_options$flipVariatio","preferredPlacement","isBasePlacement","fallbackPlacements","referenceRect","checksMap","makeFallbackChecks","firstFittingPlacement","_basePlacement","isStartVariation","mainVariationSide","altVariationSide","checks","check","numberOfChecks","_loop","_i","fittingPlacement","_ret","flip$1","getSideOffsets","preventedOffsets","isAnySideFullyClipped","hide","referenceOverflow","popperAltOverflow","referenceClippingOffsets","popperEscapeOffsets","isReferenceHidden","hasPopperEscaped","hide$1","distanceAndSkiddingToXY","rects","invertDistance","skidding","distance","_options$offset","_data$state$placement","offset$1","popperOffsets$1","getAltAxis","preventOverflow","_options$tether","tether","_options$tetherOffset","tetherOffset","altAxis","tetherOffsetValue","normalizedTetherOffsetValue","offsetModifierState","_offsetModifierState$","mainSide","altSide","additive","minLen","maxLen","arrowPaddingObject","arrowPaddingMin","arrowPaddingMax","arrowLen","minOffset","maxOffset","clientOffset","offsetModifierValue","tetherMin","tetherMax","preventedOffset","_offsetModifierState$2","_mainSide","_altSide","_offset","_len","_min","_max","isOriginSide","_offsetModifierValue","_tetherMin","_tetherMax","_preventedOffset","preventOverflow$1","getHTMLElementScroll","getNodeScroll","isElementScaled","getCompositeRect","elementOrVirtualElement","isOffsetParentAnElement","offsetParentIsScaled","documentElement","order","modifiers","map","visited","modifier","sort","requires","dep","depModifier","orderModifiers","orderedModifiers","phase","pending","resolve","mergeByName","merged","current","existing","DEFAULT_OPTIONS","areValidElements","_key","popperGenerator","generatorOptions","_generatorOptions","_generatorOptions$def","defaultModifiers","_generatorOptions$def2","defaultOptions","effectCleanupFns","isDestroyed","setOptionsAction","cleanupModifierEffects","runModifierEffects","_state$elements","_state$orderedModifie","_state$orderedModifie2","_ref$options","cleanupFn","noopFn","createPopper","COMPONENT_NAME","getPopperUtilityClass","flipPlacement","resolveAnchorEl","anchorEl","isVirtualElement","defaultPopperOptions","PopperTooltip","_slots$root","initialPlacement","popperOptions","popperRefProp","TransitionProps","tooltipRef","ownRef","popperRef","handlePopperRef","handlePopperRefRef","rtlPlacement","setPlacement","resolvedAnchorElement","setResolvedAnchorElement","handlePopperUpdate","box","popperModifiers","childProps","Root","rootProps","Popper","containerProp","keepMounted","transition","exited","setExited","handleEnter","handleExited","resolvedAnchorEl","display","transitionProps","useThemeSystem","_setPrototypeOf","_inheritsLoose","subClass","superClass","setPrototypeOf","timeoutsShape","TransitionGroupContext","forceReflow","UNMOUNTED","EXITED","ENTERING","ENTERED","EXITING","Transition","_React$Component","_this","parentGroup","appear","initialStatus","prevState","nextIn","_proto","prevProps","nextStatus","exit","enter","mounting","_this2","appearing","maybeNode","maybeAppearing","timeouts","enterTimeout","_this3","nextState","callback","_this4","active","handler","doesNotHaveTimeoutOrListener","maybeNextCallback","_this$props","pt","noop","Transition$1","reflow","getTransitionProps","_style$transitionDura","_style$transitionTimi","getScale","isWebKit154","Grow","addEndListener","inProp","onEnter","onEntered","onEntering","onExit","onExited","onExiting","TransitionComponent","timer","autoTimeout","nodeRef","normalizedTransitionCallback","maybeIsAppearing","handleEntering","isAppearing","transitionDuration","transitionTimingFunction","handleEntered","handleExiting","handleExit","handleAddEndListener","Grow$1","PopperRoot","BasePopper","components","componentsProps","RootComponent","Popper$1","getTooltipUtilityClass","tooltipClasses","tooltipClasses$1","disableInteractive","touch","TooltipPopper","TooltipTooltip","TooltipArrow","hystersisOpen","hystersisTimer","cursorPosition","composeEventHandler","eventHandler","_slots$popper","_slots$transition","_slots$tooltip","_slots$arrow","_slotProps$popper","_ref6","_slotProps$popper2","_slotProps$transition","_slotProps$tooltip","_ref7","_slotProps$tooltip2","_slotProps$arrow","_ref8","_slotProps$arrow2","childrenProp","describeChild","disableFocusListener","disableHoverListener","disableInteractiveProp","disableTouchListener","enterDelay","enterNextDelay","enterTouchDelay","followCursor","idProp","leaveDelay","leaveTouchDelay","onClose","onOpen","PopperComponentProp","PopperProps","title","TransitionComponentProp","isRtl","childNode","setChildNode","arrowRef","setArrowRef","ignoreNonTouchEvents","closeTimer","enterTimer","leaveTimer","touchTimer","setOpenState","prevUserSelect","stopTouchInteraction","handleOpen","handleClose","handleLeave","focusVisibleRef","setChildIsFocusVisible","handleBlur","handleFocus","detectTouchStart","childrenProps","handleMouseOver","handleMouseLeave","handleTouchStart","handleTouchEnd","nativeEvent","handleMouseMove","nameOrDescProps","titleIsString","interactiveWrapperListeners","_PopperProps$popperOp","tooltipModifiers","PopperComponent","TooltipComponent","ArrowComponent","popperProps","tooltipProps","tooltipArrowProps","TransitionPropsInner","Tooltip$1","getIcon","icon","menuLabel","leading","MuiListItemIcon","MenuItem","allowForLeadingIcons","iconPathBefore","iconPathAfter","hasAutoFocus","isDense","isSubMenuParent","hasDisabledGutters","hasDivider","focusVisibleClassName","menuItem","MuiMenuItem","MuiListItemText","getAllGroups","menuDefinition","SubMenu","setAnchorEl","parentMenuItem","parentItemProps","handleParentMenuItemClick","renderSubMenuItems","includedGroups","group","GroupedMenuItemList","Menu","getOrderedGroupItems","groupId","allItems","menuProps","commandHandler","groupsToInclude","sortedGroups","itemArray","allowSpaceForLeadingIcons","createMenuItemProps","isLastItemInGroup","divKey","itemInfo","menuItemProps","TopLevelMenu","columnId","MenuColumn","metadata","Grid","List","GridMenu","multiColumnMenu","sortedColumns","columnNumbers","columnName","col","getUsePromiseOptionsDefaults","usePromise","promiseFactoryCallback","defaultValueRef","optionsDefaultedRef","setIsLoading","promiseIsCurrent","MenuIcon","HamburgerMenuButton","menuProvider","normalMenu","fullMenu","containerRef","ariaLabelPrefix","isMenuOpen","setMenuOpen","showFullMenu","setShowFullMenu","handleMenuItemClick","handleMenuButtonClick","prevIsOpen","isOpening","menuCommandHandler","command","setOffset","normalMenuData","fullMenuData","menu","IconButton","Drawer","isTooltipSuppressed","adjustMarginToAlignToEdge","MuiIconButton","Spinner","LoaderCircle","TextField","hasError","helperText","onFocus","onBlur","ShadLabel","Toolbar","AppBar","MuiToolbar","alertVariants","Alert","AlertTitle","AlertDescription","Card","CardHeader","CardTitle","CardDescription","CardContent","CardFooter","Sonner","Toaster","Slider","SliderPrimitive","Switch","SwitchPrimitives","Tabs","TabsList","TabsTrigger","TabsContent","InstallButton","isInstalling","handleClick","buttonText","Download","EnableButton","isEnabling","DisableButton","isDisabling","UpdateButton","isUpdating","MarkdownRenderer","markdown","anchorTarget","Markdown","FilterButton","Filter","DropdownMenuItemType","DropdownMenuItemType2","FilterDropdown","groups","NoExtensionsFound","MoreInfo","category","downloads","languages","moreInfoUrl","numberFormatted","NumberFormat","handleScrollToBottom","User","locale","LucideLink","CircleHelp","VersionHistory","versionHistory","showAllVersions","setShowAllVersions","currentDate","formatTimeString","dateString","date","dateDiff","yearDiff","monthDiff","dayDiff","timeString","sortedEntries","Footer","publisherDisplayName","fileSize","locales","formattedFileSize","formatBytes","languageNames","codes","displayNames","useEvent","unsubscriber","noopUnsubscriber","useEventAsync","unsubscribe","unsub"],"mappings":"28CAGA,MAAMA,GAAgBC,GAAAA,oBAAoB,CAAE,OAAQ,KAAO,CAAA,EAyDpD,SAASC,KAAMC,EAAsB,CACnC,OAAAH,GAAcI,GAAAA,KAAKD,CAAM,CAAC,CACnC,CCzDO,MAAME,GAAQC,EAAM,WACzB,CAAC,CAAE,UAAAC,EAAW,KAAAC,EAAM,GAAGC,CAAA,EAASC,IAE5BC,EAAA,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A,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MAEA,MAEA,MAEA,MAEA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,MAEA,MAEA,MAEA,MAEA,MACA,MACA,MACA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,KACF,EAAGC,GAAI,CACL,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,KACF,EAAGC,GAAI,CACL,UACA,SACA,YACA,UACA,cACA,SACA,SACA,OACA,WACA,WACA,UACA,UACA,eACA,eACA,OACA,WACA,kBACA,MACA,SACA,WACA,eACA,gBACA,SACA,WACA,eACA,UACA,kBACA,QACA,OACA,OACA,UACA,QACA,QACA,QACA,WACA,YACA,SACA,YACA,UACA,UACA,OACA,OACA,OACA,OACA,SACA,gBACA,gBACA,YACA,YACA,cACA,aACA,kBACA,kBACA,YACA,YACA,QACA,WACA,UACA,QACA,UACA,UACA,SACA,SACA,SACA,OACA,aACA,QACA,SACA,eACA,oBACA,0BACA,SACA,qBACA,sBACA,UACA,qBACA,cACA,cACA,cACA,cACA,mBACA,mBACA,qBACA,YACA,OACA,oBAGA,uBACA,uBACA,sBACA,yBACA,wBACA,qBACA,UACA,UACA,UACA,UACA,UACA,UACA,UACA,eACA,cACA,eACA,oBACA,qBACA,0BACA,0BACA,eACA,eACA,YACA,gBACA,cACA,eACA,iBACA,wBACA,mBACA,WACA,QACA,aACA,aACA,aACA,2BACA,4BACA,YACF,EAAGC,GAAIC,KACP,SAASC,GAAER,EAAGJ,EAAI,GAAI,CACpB,OAAOA,IAAMI,EAAIA,EAAE,YAAa,GAAGA,KAAKM,GAAIA,GAAEN,CAAC,EAAI,CACrD,CACA,SAASS,GAAET,EAAG,C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iBAAkB,CAChB,SAAU,SACX,EACD,kBAAmB,CACjB,SAAU,SACX,EACD,gBAAiB,CACf,SAAU,SACX,EACD,QAAS,CACP,SAAU,UACV,UAAWA,EACZ,EACD,aAAc,CACZ,SAAU,SACX,EACD,aAAc,CACZ,SAAU,qBACV,MAAOc,EACR,EAED,MAAO,CACL,SAAU,UACV,UAAWa,EACZ,EACD,QAAS,CACP,SAAU,UACV,YAAa,kBACb,UAAWA,EACZ,EACD,gBAAiB,CACf,SAAU,UACV,UAAWA,EACZ,EAED,EAAG,CACD,MAAOpC,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,QAAS,CACP,MAAOA,EACR,EACD,WAAY,CACV,MAAOA,EACR,EACD,aAAc,CACZ,MAAOA,EACR,EACD,cAAe,CACb,MAAOA,EACR,EACD,YAAa,CACX,MAAOA,EACR,EACD,SAAU,CACR,MAAOA,EACR,EACD,SAAU,CACR,MAAOA,EACR,EACD,cAAe,CACb,MAAOA,EACR,EACD,mBAAoB,CAClB,MAAOA,EACR,EACD,iBAAkB,CAChB,MAAOA,EACR,EACD,aAAc,CACZ,MAAOA,EACR,EACD,kBAAmB,CACjB,MAAOA,EACR,EACD,gBAAiB,CACf,MAAOA,EACR,EACD,EAAG,CACD,MAAOD,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,OAAQ,CACN,MAAOA,EACR,EACD,UAAW,CACT,MAAOA,EACR,EACD,YAAa,CACX,MAAOA,EACR,EACD,aAAc,CACZ,MAAOA,EACR,EACD,WAAY,CACV,MAAOA,EACR,E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;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","x_google_ignoreList":[3,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,83,84,85,86,87,88,89,90,91,92,93,94,95,96,97,98,99,100,101,102,103,104,105,106,107,108,109,110,111,112,113,114,115,116,117,118,119,120,121,122,123,124,125,126,127,128,129,130,131,132,133,134,135,136,137,138,139,140,141,142,143,144,145,146,147,148,149,150,151,152,153,154,155,156,157,158,159,160,161,162,163,164,165,166,167,168,169,170,171,172,173,174,175,176,177,178,179,180,181,182,183,184,185,186,187,188,189,190,191,192,193,194,195,196,197,198,199,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,228]} \ No newline at end of file +{"version":3,"file":"index.cjs","sources":["../src/utils/shadcn-ui.util.ts","../src/components/shadcn-ui/input.tsx","../src/components/advanced/book-chapter-control/book-chapter-input.component.tsx","../../../node_modules/@sillsdev/scripture/dist/index.es.js","../src/components/shadcn-ui/dropdown-menu.tsx","../src/components/advanced/book-chapter-control/book-menu-item.component.tsx","../src/components/advanced/book-chapter-control/chapter-select.component.tsx","../src/components/advanced/book-chapter-control/go-to-menu-item.component.tsx","../src/components/advanced/book-chapter-control/book-chapter-control.component.tsx","../src/components/shadcn-ui/button.tsx","../src/components/shadcn-ui/label.tsx","../src/components/shadcn-ui/radio-group.tsx","../src/components/shadcn-ui/popover.tsx","../src/components/shadcn-ui/dialog.tsx","../src/components/shadcn-ui/command.tsx","../src/components/basics/combo-box.component.tsx","../src/components/basics/chapter-range-selector.component.tsx","../src/components/advanced/book-selector.component.tsx","../src/components/advanced/data-table/data-table-column-toggle.component.tsx","../src/components/shadcn-ui/select.tsx","../src/components/advanced/data-table/data-table-pagination.component.tsx","../src/components/shadcn-ui/table.tsx","../src/components/advanced/data-table/data-table.component.tsx","../src/components/advanced/inventory/occurrences-table.component.tsx","../src/components/shadcn-ui/checkbox.tsx","../src/components/advanced/inventory/inventory-utils.ts","../src/components/shadcn-ui/toggle.tsx","../src/components/shadcn-ui/toggle-group.tsx","../src/components/advanced/inventory/inventory-columns.tsx","../src/components/advanced/inventory/inventory.component.tsx","../src/components/basics/search-bar.component.tsx","../src/components/basics/tabs-vertical.tsx","../src/components/advanced/tab-navigation-content-search.component.tsx","../src/components/shadcn-ui/separator.tsx","../src/components/shadcn-ui/skeleton.tsx","../src/components/shadcn-ui/tooltip.tsx","../src/components/shadcn-ui/sidebar.tsx","../src/components/advanced/settings-components/settings-sidebar.component.tsx","../src/components/advanced/settings-components/settings-sidebar-content-search.component.tsx","../src/components/advanced/scripture-results-viewer/scripture-results-viewer.component.tsx","../src/components/advanced/scroll-group-selector.component.tsx","../src/components/advanced/settings-components/settings-list.component.tsx","../src/components/basics/checklist.component.tsx","../../../node_modules/@babel/runtime/helpers/interopRequireDefault.js","../../../node_modules/@mui/utils/chainPropTypes/chainPropTypes.js","../../../node_modules/@babel/runtime/helpers/esm/extends.js","../../../node_modules/@mui/utils/deepmerge/deepmerge.js","../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.production.min.js","../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.development.js","../../../node_modules/prop-types/node_modules/react-is/index.js","../../../node_modules/object-assign/index.js","../../../node_modules/prop-types/lib/ReactPropTypesSecret.js","../../../node_modules/prop-types/lib/has.js","../../../node_modules/prop-types/checkPropTypes.js","../../../node_modules/prop-types/factoryWithTypeCheckers.js","../../../node_modules/prop-types/factoryWithThrowingShims.js","../../../node_modules/prop-types/index.js","../../../node_modules/@mui/utils/elementAcceptingRef/elementAcceptingRef.js","../../../node_modules/@mui/utils/exactProp/exactProp.js","../../../node_modules/@mui/utils/formatMuiErrorMessage/formatMuiErrorMessage.js","../../../node_modules/react-is/cjs/react-is.production.min.js","../../../node_modules/react-is/cjs/react-is.development.js","../../../node_modules/react-is/index.js","../../../node_modules/@mui/utils/getDisplayName/getDisplayName.js","../../../node_modules/@mui/utils/HTMLElementType/HTMLElementType.js","../../../node_modules/@mui/utils/refType/refType.js","../../../node_modules/@mui/utils/capitalize/capitalize.js","../../../node_modules/@mui/utils/createChainedFunction/createChainedFunction.js","../../../node_modules/@mui/utils/debounce/debounce.js","../../../node_modules/@mui/utils/deprecatedPropType/deprecatedPropType.js","../../../node_modules/@mui/utils/isMuiElement/isMuiElement.js","../../../node_modules/@mui/utils/ownerDocument/ownerDocument.js","../../../node_modules/@mui/utils/ownerWindow/ownerWindow.js","../../../node_modules/@mui/utils/requirePropFactory/requirePropFactory.js","../../../node_modules/@mui/utils/setRef/setRef.js","../../../node_modules/@mui/utils/useEnhancedEffect/useEnhancedEffect.js","../../../node_modules/@mui/utils/useId/useId.js","../../../node_modules/@mui/utils/unsupportedProp/unsupportedProp.js","../../../node_modules/@mui/utils/useControlled/useControlled.js","../../../node_modules/@mui/utils/useEventCallback/useEventCallback.js","../../../node_modules/@mui/utils/useForkRef/useForkRef.js","../../../node_modules/@mui/utils/useLazyRef/useLazyRef.js","../../../node_modules/@mui/utils/useOnMount/useOnMount.js","../../../node_modules/@mui/utils/useTimeout/useTimeout.js","../../../node_modules/@mui/utils/useIsFocusVisible/useIsFocusVisible.js","../../../node_modules/@mui/utils/resolveProps/resolveProps.js","../../../node_modules/@mui/utils/composeClasses/composeClasses.js","../../../node_modules/@mui/utils/ClassNameGenerator/ClassNameGenerator.js","../../../node_modules/@mui/utils/generateUtilityClass/generateUtilityClass.js","../../../node_modules/@mui/utils/generateUtilityClasses/generateUtilityClasses.js","../../../node_modules/@mui/utils/clamp/clamp.js","../../../node_modules/@babel/runtime/helpers/esm/objectWithoutPropertiesLoose.js","../../../node_modules/@mui/system/esm/createTheme/createBreakpoints.js","../../../node_modules/@mui/system/esm/createTheme/shape.js","../../../node_modules/@mui/system/esm/responsivePropType.js","../../../node_modules/@mui/system/esm/merge.js","../../../node_modules/@mui/system/esm/breakpoints.js","../../../node_modules/@mui/system/esm/style.js","../../../node_modules/@mui/system/esm/memoize.js","../../../node_modules/@mui/system/esm/spacing.js","../../../node_modules/@mui/system/esm/createTheme/createSpacing.js","../../../node_modules/@mui/system/esm/compose.js","../../../node_modules/@mui/system/esm/borders.js","../../../node_modules/@mui/system/esm/cssGrid.js","../../../node_modules/@mui/system/esm/palette.js","../../../node_modules/@mui/system/esm/sizing.js","../../../node_modules/@mui/system/esm/styleFunctionSx/defaultSxConfig.js","../../../node_modules/@mui/system/esm/styleFunctionSx/styleFunctionSx.js","../../../node_modules/@mui/system/esm/createTheme/applyStyles.js","../../../node_modules/@mui/system/esm/createTheme/createTheme.js","../../../node_modules/@mui/system/esm/useThemeWithoutDefault.js","../../../node_modules/@mui/system/esm/useTheme.js","../../../node_modules/@mui/system/esm/createStyled.js","../../../node_modules/@mui/system/esm/useThemeProps/getThemeProps.js","../../../node_modules/@mui/system/esm/useThemeProps/useThemeProps.js","../../../node_modules/@mui/system/esm/colorManipulator.js","../../../node_modules/@mui/material/styles/createMixins.js","../../../node_modules/@mui/material/colors/common.js","../../../node_modules/@mui/material/colors/grey.js","../../../node_modules/@mui/material/colors/purple.js","../../../node_modules/@mui/material/colors/red.js","../../../node_modules/@mui/material/colors/orange.js","../../../node_modules/@mui/material/colors/blue.js","../../../node_modules/@mui/material/colors/lightBlue.js","../../../node_modules/@mui/material/colors/green.js","../../../node_modules/@mui/material/styles/createPalette.js","../../../node_modules/@mui/material/styles/createTypography.js","../../../node_modules/@mui/material/styles/shadows.js","../../../node_modules/@mui/material/styles/createTransitions.js","../../../node_modules/@mui/material/styles/zIndex.js","../../../node_modules/@mui/material/styles/createTheme.js","../../../node_modules/@mui/material/styles/defaultTheme.js","../../../node_modules/@mui/material/styles/identifier.js","../../../node_modules/@mui/material/styles/useThemeProps.js","../../../node_modules/@mui/material/styles/styled.js","../../../node_modules/@mui/material/SvgIcon/svgIconClasses.js","../../../node_modules/@mui/material/SvgIcon/SvgIcon.js","../../../node_modules/@mui/material/utils/createSvgIcon.js","../../../node_modules/@mui/material/utils/index.js","../../../node_modules/@mui/icons-material/utils/createSvgIcon.js","../../../node_modules/@mui/icons-material/ArrowRight.js","../../../node_modules/@mui/base/utils/isHostComponent.js","../../../node_modules/@mui/base/utils/appendOwnerState.js","../../../node_modules/@mui/base/utils/ClassNameConfigurator.js","../../../node_modules/@mui/base/utils/extractEventHandlers.js","../../../node_modules/@mui/base/utils/resolveComponentProps.js","../../../node_modules/@mui/base/utils/omitEventHandlers.js","../../../node_modules/@mui/base/utils/mergeSlotProps.js","../../../node_modules/@mui/base/utils/useSlotProps.js","../../../node_modules/@mui/base/generateUtilityClass/index.js","../../../node_modules/@mui/base/generateUtilityClasses/index.js","../../../node_modules/@mui/base/Portal/Portal.js","../../../node_modules/@popperjs/core/lib/enums.js","../../../node_modules/@popperjs/core/lib/dom-utils/getNodeName.js","../../../node_modules/@popperjs/core/lib/dom-utils/getWindow.js","../../../node_modules/@popperjs/core/lib/dom-utils/instanceOf.js","../../../node_modules/@popperjs/core/lib/modifiers/applyStyles.js","../../../node_modules/@popperjs/core/lib/utils/getBasePlacement.js","../../../node_modules/@popperjs/core/lib/utils/math.js","../../../node_modules/@popperjs/core/lib/utils/userAgent.js","../../../node_modules/@popperjs/core/lib/dom-utils/isLayoutViewport.js","../../../node_modules/@popperjs/core/lib/dom-utils/getBoundingClientRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/getLayoutRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/contains.js","../../../node_modules/@popperjs/core/lib/dom-utils/getComputedStyle.js","../../../node_modules/@popperjs/core/lib/dom-utils/isTableElement.js","../../../node_modules/@popperjs/core/lib/dom-utils/getDocumentElement.js","../../../node_modules/@popperjs/core/lib/dom-utils/getParentNode.js","../../../node_modules/@popperjs/core/lib/dom-utils/getOffsetParent.js","../../../node_modules/@popperjs/core/lib/utils/getMainAxisFromPlacement.js","../../../node_modules/@popperjs/core/lib/utils/within.js","../../../node_modules/@popperjs/core/lib/utils/getFreshSideObject.js","../../../node_modules/@popperjs/core/lib/utils/mergePaddingObject.js","../../../node_modules/@popperjs/core/lib/utils/expandToHashMap.js","../../../node_modules/@popperjs/core/lib/modifiers/arrow.js","../../../node_modules/@popperjs/core/lib/utils/getVariation.js","../../../node_modules/@popperjs/core/lib/modifiers/computeStyles.js","../../../node_modules/@popperjs/core/lib/modifiers/eventListeners.js","../../../node_modules/@popperjs/core/lib/utils/getOppositePlacement.js","../../../node_modules/@popperjs/core/lib/utils/getOppositeVariationPlacement.js","../../../node_modules/@popperjs/core/lib/dom-utils/getWindowScroll.js","../../../node_modules/@popperjs/core/lib/dom-utils/getWindowScrollBarX.js","../../../node_modules/@popperjs/core/lib/dom-utils/getViewportRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/getDocumentRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/isScrollParent.js","../../../node_modules/@popperjs/core/lib/dom-utils/getScrollParent.js","../../../node_modules/@popperjs/core/lib/dom-utils/listScrollParents.js","../../../node_modules/@popperjs/core/lib/utils/rectToClientRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/getClippingRect.js","../../../node_modules/@popperjs/core/lib/utils/computeOffsets.js","../../../node_modules/@popperjs/core/lib/utils/detectOverflow.js","../../../node_modules/@popperjs/core/lib/utils/computeAutoPlacement.js","../../../node_modules/@popperjs/core/lib/modifiers/flip.js","../../../node_modules/@popperjs/core/lib/modifiers/hide.js","../../../node_modules/@popperjs/core/lib/modifiers/offset.js","../../../node_modules/@popperjs/core/lib/modifiers/popperOffsets.js","../../../node_modules/@popperjs/core/lib/utils/getAltAxis.js","../../../node_modules/@popperjs/core/lib/modifiers/preventOverflow.js","../../../node_modules/@popperjs/core/lib/dom-utils/getHTMLElementScroll.js","../../../node_modules/@popperjs/core/lib/dom-utils/getNodeScroll.js","../../../node_modules/@popperjs/core/lib/dom-utils/getCompositeRect.js","../../../node_modules/@popperjs/core/lib/utils/orderModifiers.js","../../../node_modules/@popperjs/core/lib/utils/debounce.js","../../../node_modules/@popperjs/core/lib/utils/mergeByName.js","../../../node_modules/@popperjs/core/lib/createPopper.js","../../../node_modules/@popperjs/core/lib/popper.js","../../../node_modules/@mui/base/Popper/popperClasses.js","../../../node_modules/@mui/base/Popper/Popper.js","../../../node_modules/@mui/material/styles/useTheme.js","../../../node_modules/@babel/runtime/helpers/esm/setPrototypeOf.js","../../../node_modules/@babel/runtime/helpers/esm/inheritsLoose.js","../../../node_modules/react-transition-group/esm/config.js","../../../node_modules/react-transition-group/esm/utils/PropTypes.js","../../../node_modules/react-transition-group/esm/TransitionGroupContext.js","../../../node_modules/react-transition-group/esm/utils/reflow.js","../../../node_modules/react-transition-group/esm/Transition.js","../../../node_modules/@mui/material/transitions/utils.js","../../../node_modules/@mui/material/Grow/Grow.js","../../../node_modules/@mui/material/Popper/Popper.js","../../../node_modules/@mui/material/Tooltip/tooltipClasses.js","../../../node_modules/@mui/material/Tooltip/Tooltip.js","../src/components/mui/menu-item.component.tsx","../src/components/mui/grouped-menu-item-list.component.tsx","../src/components/mui/top-level-menu.component.tsx","../src/components/mui/grid-menu.component.tsx","../src/hooks/use-promise.hook.ts","../../../node_modules/@mui/icons-material/esm/Menu.js","../src/components/mui/hamburger-menu-button.component.tsx","../src/components/mui/icon-button.component.tsx","../src/components/basics/spinner.component.tsx","../src/components/basics/text-field.component.tsx","../src/components/mui/toolbar.component.tsx","../src/components/shadcn-ui/alert.tsx","../src/components/shadcn-ui/card.tsx","../src/components/shadcn-ui/sonner.tsx","../src/components/shadcn-ui/slider.tsx","../src/components/shadcn-ui/switch.tsx","../src/components/shadcn-ui/tabs.tsx","../src/components/advanced/extension-marketplace/buttons/install-button.component.tsx","../src/components/advanced/extension-marketplace/buttons/enable-button.component.tsx","../src/components/advanced/extension-marketplace/buttons/disable-button.component.tsx","../src/components/advanced/extension-marketplace/buttons/update-button.component.tsx","../src/components/advanced/extension-marketplace/markdown-renderer.component.tsx","../src/components/advanced/extension-marketplace/buttons/filter-button.component.tsx","../src/components/advanced/extension-marketplace/filter-dropdown.component.tsx","../src/components/advanced/extension-marketplace/no-extensions-found.component.tsx","../src/components/advanced/extension-marketplace/more-info.component.tsx","../src/components/advanced/extension-marketplace/version-history.component.tsx","../src/components/advanced/extension-marketplace/footer.component.tsx","../src/hooks/use-event.hook.ts","../src/hooks/use-event-async.hook.ts"],"sourcesContent":["import { type ClassValue, clsx } from 'clsx';\nimport { extendTailwindMerge } from 'tailwind-merge';\n\nconst twMergeCustom = extendTailwindMerge({ prefix: 'tw-' });\n\n/**\n * Tailwind and CSS class application helper function. Uses\n * [`clsx`](https://www.npmjs.com/package/clsx) to make it easy to apply classes conditionally using\n * object syntax, and uses [`tailwind-merge`](https://www.npmjs.com/package/tailwind-merge) to make\n * it easy to merge/overwrite Tailwind classes in a programmer-logic-friendly way.\n *\n * Note: `tailwind-merge` is configured to use the prefix `tw-`, so you must use the same prefix\n * with any Tailwind classes you use with this function to successfully overwrite other Tailwind\n * classes. `platform-bible-react` is configured to use `tw-` as its Tailwind prefix, so any\n * Tailwind classes you pass into `platform-bible-react` components will be compared using the `tw-`\n * prefix.\n *\n * This function was popularized by\n * [shadcn/ui](https://ui.shadcn.com/docs/installation/manual#add-a-cn-helper). See [ByteGrad's\n * explanation video](https://www.youtube.com/watch?v=re2JFITR7TI) for more information.\n *\n * @example\n *\n * ```typescript\n * const borderShouldBeBlue = true;\n * const textShouldBeRed = true;\n * const heightShouldBe20 = false;\n * const classString = cn(\n * 'tw-bg-primary tw-h-10 tw-text-primary-foreground',\n * 'tw-bg-secondary',\n * {\n * 'tw-border-blue-500': borderShouldBeBlue,\n * 'tw-text-red-500': textShouldBeRed,\n * 'tw-h-20': heightShouldBe20,\n * },\n * 'some-class',\n * );\n * ```\n *\n * The resulting `classString` is `'tw-h-10 tw-bg-secondary tw-border-blue-500 tw-text-red-500\n * some-class'`\n *\n * - Notice that `'tw-bg-secondary'`, specified later, overwrote `'tw-bg-primary'`, specified earlier,\n * because they are Tailwind classes that affect the same css property\n * - Notice that `'tw-text-red-500'`, specified later, overwrote `'tw-text-primary-foreground'`,\n * specified earlier, because they are Tailwind classes that affect the same css property\n * - Notice that `'tw-h-20'`, specified later, did not overwrite `'tw-h-10'`, specified earlier,\n * because `'tw-h-20'` is part of a conditional class object and its value evaluated to `false`;\n * therefore it was not applied\n * - Notice that `'some-class'` was applied. This function is not limited only to Tailwind classes.\n *\n *\n * @param inputs Class strings or `clsx` conditional class objects to merge. Tailwind classes\n * specified later in the arguments overwrite similar Tailwind classes specified earlier in the\n * arguments\n * @returns Class string containing all applicable classes from the arguments based on the rules\n * described above\n */\n// shadcn/ui uses this export in its boilerplate code\n// eslint-disable-next-line import/prefer-default-export\nexport function cn(...inputs: ClassValue[]) {\n return twMergeCustom(clsx(inputs));\n}\n","import React from 'react';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport interface InputProps extends React.InputHTMLAttributes {}\n\nexport const Input = React.forwardRef(\n ({ className, type, ...props }, ref) => {\n return (\n \n );\n },\n);\nInput.displayName = 'Input';\n","import { FocusEventHandler, forwardRef, KeyboardEvent, MouseEventHandler } from 'react';\nimport { History } from 'lucide-react';\nimport { Input as ShadInput } from '@/components/shadcn-ui/input';\n\nexport type BookChapterInputProps = {\n handleSearch: (searchString: string) => void;\n handleKeyDown: (event: KeyboardEvent) => void;\n handleOnClick: MouseEventHandler;\n handleSubmit: () => void;\n onFocus?: FocusEventHandler;\n value: string;\n placeholder: string;\n};\n\n// Shadcn Input sets type to \"button\"- HAVE to prop spread before setting type\nconst BookChapterInput = forwardRef(\n (\n { handleSearch, handleKeyDown, handleOnClick, handleSubmit, ...props }: BookChapterInputProps,\n ref,\n ) => {\n return (\n
    \n handleSearch(event.target.value)}\n onKeyDown={(e) => {\n if (e.key === 'Enter') {\n handleSubmit();\n }\n handleKeyDown(e);\n }}\n onClick={handleOnClick}\n ref={ref}\n />\n {\n // eslint-disable-next-line no-console\n console.log('back in history');\n }}\n />\n
    \n );\n },\n);\n\nexport default BookChapterInput;\n","var P = Object.defineProperty;\nvar R = (t, e, s) => e in t ? P(t, e, { enumerable: !0, configurable: !0, writable: !0, value: s }) : t[e] = s;\nvar n = (t, e, s) => R(t, typeof e != \"symbol\" ? e + \"\" : e, s);\nclass _ {\n constructor() {\n n(this, \"books\");\n n(this, \"firstSelectedBookNum\");\n n(this, \"lastSelectedBookNum\");\n n(this, \"count\");\n n(this, \"selectedBookNumbers\");\n n(this, \"selectedBookIds\");\n }\n}\nconst N = [\n \"GEN\",\n \"EXO\",\n \"LEV\",\n \"NUM\",\n \"DEU\",\n \"JOS\",\n \"JDG\",\n \"RUT\",\n \"1SA\",\n \"2SA\",\n // 10\n \"1KI\",\n \"2KI\",\n \"1CH\",\n \"2CH\",\n \"EZR\",\n \"NEH\",\n \"EST\",\n \"JOB\",\n \"PSA\",\n \"PRO\",\n // 20\n \"ECC\",\n \"SNG\",\n \"ISA\",\n \"JER\",\n \"LAM\",\n \"EZK\",\n \"DAN\",\n \"HOS\",\n \"JOL\",\n \"AMO\",\n // 30\n \"OBA\",\n \"JON\",\n \"MIC\",\n \"NAM\",\n \"HAB\",\n \"ZEP\",\n \"HAG\",\n \"ZEC\",\n \"MAL\",\n \"MAT\",\n // 40\n \"MRK\",\n \"LUK\",\n \"JHN\",\n \"ACT\",\n \"ROM\",\n \"1CO\",\n \"2CO\",\n \"GAL\",\n \"EPH\",\n \"PHP\",\n // 50\n \"COL\",\n \"1TH\",\n \"2TH\",\n \"1TI\",\n \"2TI\",\n \"TIT\",\n \"PHM\",\n \"HEB\",\n \"JAS\",\n \"1PE\",\n // 60\n \"2PE\",\n \"1JN\",\n \"2JN\",\n \"3JN\",\n \"JUD\",\n \"REV\",\n \"TOB\",\n \"JDT\",\n \"ESG\",\n \"WIS\",\n // 70\n \"SIR\",\n \"BAR\",\n \"LJE\",\n \"S3Y\",\n \"SUS\",\n \"BEL\",\n \"1MA\",\n \"2MA\",\n \"3MA\",\n \"4MA\",\n // 80\n \"1ES\",\n \"2ES\",\n \"MAN\",\n \"PS2\",\n \"ODA\",\n \"PSS\",\n \"JSA\",\n // actual variant text for JOS, now in LXA text\n \"JDB\",\n // actual variant text for JDG, now in LXA text\n \"TBS\",\n // actual variant text for TOB, now in LXA text\n \"SST\",\n // actual variant text for SUS, now in LXA text // 90\n \"DNT\",\n // actual variant text for DAN, now in LXA text\n \"BLT\",\n // actual variant text for BEL, now in LXA text\n \"XXA\",\n \"XXB\",\n \"XXC\",\n \"XXD\",\n \"XXE\",\n \"XXF\",\n \"XXG\",\n \"FRT\",\n // 100\n \"BAK\",\n \"OTH\",\n \"3ES\",\n // Used previously but really should be 2ES\n \"EZA\",\n // Used to be called 4ES, but not actually in any known project\n \"5EZ\",\n // Used to be called 5ES, but not actually in any known project\n \"6EZ\",\n // Used to be called 6ES, but not actually in any known project\n \"INT\",\n \"CNC\",\n \"GLO\",\n \"TDX\",\n // 110\n \"NDX\",\n \"DAG\",\n \"PS3\",\n \"2BA\",\n \"LBA\",\n \"JUB\",\n \"ENO\",\n \"1MQ\",\n \"2MQ\",\n \"3MQ\",\n // 120\n \"REP\",\n \"4BA\",\n \"LAO\"\n], B = [\n \"XXA\",\n \"XXB\",\n \"XXC\",\n \"XXD\",\n \"XXE\",\n \"XXF\",\n \"XXG\",\n \"FRT\",\n \"BAK\",\n \"OTH\",\n \"INT\",\n \"CNC\",\n \"GLO\",\n \"TDX\",\n \"NDX\"\n], O = [\n \"Genesis\",\n \"Exodus\",\n \"Leviticus\",\n \"Numbers\",\n \"Deuteronomy\",\n \"Joshua\",\n \"Judges\",\n \"Ruth\",\n \"1 Samuel\",\n \"2 Samuel\",\n \"1 Kings\",\n \"2 Kings\",\n \"1 Chronicles\",\n \"2 Chronicles\",\n \"Ezra\",\n \"Nehemiah\",\n \"Esther (Hebrew)\",\n \"Job\",\n \"Psalms\",\n \"Proverbs\",\n \"Ecclesiastes\",\n \"Song of Songs\",\n \"Isaiah\",\n \"Jeremiah\",\n \"Lamentations\",\n \"Ezekiel\",\n \"Daniel (Hebrew)\",\n \"Hosea\",\n \"Joel\",\n \"Amos\",\n \"Obadiah\",\n \"Jonah\",\n \"Micah\",\n \"Nahum\",\n \"Habakkuk\",\n \"Zephaniah\",\n \"Haggai\",\n \"Zechariah\",\n \"Malachi\",\n \"Matthew\",\n \"Mark\",\n \"Luke\",\n \"John\",\n \"Acts\",\n \"Romans\",\n \"1 Corinthians\",\n \"2 Corinthians\",\n \"Galatians\",\n \"Ephesians\",\n \"Philippians\",\n \"Colossians\",\n \"1 Thessalonians\",\n \"2 Thessalonians\",\n \"1 Timothy\",\n \"2 Timothy\",\n \"Titus\",\n \"Philemon\",\n \"Hebrews\",\n \"James\",\n \"1 Peter\",\n \"2 Peter\",\n \"1 John\",\n \"2 John\",\n \"3 John\",\n \"Jude\",\n \"Revelation\",\n \"Tobit\",\n \"Judith\",\n \"Esther Greek\",\n \"Wisdom of Solomon\",\n \"Sirach (Ecclesiasticus)\",\n \"Baruch\",\n \"Letter of Jeremiah\",\n \"Song of 3 Young Men\",\n \"Susanna\",\n \"Bel and the Dragon\",\n \"1 Maccabees\",\n \"2 Maccabees\",\n \"3 Maccabees\",\n \"4 Maccabees\",\n \"1 Esdras (Greek)\",\n \"2 Esdras (Latin)\",\n \"Prayer of Manasseh\",\n \"Psalm 151\",\n \"Odes\",\n \"Psalms of Solomon\",\n // WARNING, if you change the spelling of the *obsolete* tag be sure to update\n // IsObsolete routine\n \"Joshua A. *obsolete*\",\n \"Judges B. *obsolete*\",\n \"Tobit S. *obsolete*\",\n \"Susanna Th. *obsolete*\",\n \"Daniel Th. *obsolete*\",\n \"Bel Th. *obsolete*\",\n \"Extra A\",\n \"Extra B\",\n \"Extra C\",\n \"Extra D\",\n \"Extra E\",\n \"Extra F\",\n \"Extra G\",\n \"Front Matter\",\n \"Back Matter\",\n \"Other Matter\",\n \"3 Ezra *obsolete*\",\n \"Apocalypse of Ezra\",\n \"5 Ezra (Latin Prologue)\",\n \"6 Ezra (Latin Epilogue)\",\n \"Introduction\",\n \"Concordance \",\n \"Glossary \",\n \"Topical Index\",\n \"Names Index\",\n \"Daniel Greek\",\n \"Psalms 152-155\",\n \"2 Baruch (Apocalypse)\",\n \"Letter of Baruch\",\n \"Jubilees\",\n \"Enoch\",\n \"1 Meqabyan\",\n \"2 Meqabyan\",\n \"3 Meqabyan\",\n \"Reproof (Proverbs 25-31)\",\n \"4 Baruch (Rest of Baruch)\",\n \"Laodiceans\"\n], S = K();\nfunction g(t, e = !0) {\n return e && (t = t.toUpperCase()), t in S ? S[t] : 0;\n}\nfunction k(t) {\n return g(t) > 0;\n}\nfunction x(t) {\n const e = typeof t == \"string\" ? g(t) : t;\n return e >= 40 && e <= 66;\n}\nfunction T(t) {\n return (typeof t == \"string\" ? g(t) : t) <= 39;\n}\nfunction X(t) {\n return t <= 66;\n}\nfunction V(t) {\n const e = typeof t == \"string\" ? g(t) : t;\n return w(e) && !X(e);\n}\nfunction* L() {\n for (let t = 1; t <= N.length; t++) yield t;\n}\nconst G = 1, A = N.length;\nfunction H() {\n return [\"XXA\", \"XXB\", \"XXC\", \"XXD\", \"XXE\", \"XXF\", \"XXG\"];\n}\nfunction C(t, e = \"***\") {\n const s = t - 1;\n return s < 0 || s >= N.length ? e : N[s];\n}\nfunction I(t) {\n return t <= 0 || t > A ? \"******\" : O[t - 1];\n}\nfunction y(t) {\n return I(g(t));\n}\nfunction w(t) {\n const e = typeof t == \"number\" ? C(t) : t;\n return k(e) && !B.includes(e);\n}\nfunction q(t) {\n const e = typeof t == \"number\" ? C(t) : t;\n return k(e) && B.includes(e);\n}\nfunction U(t) {\n return O[t - 1].includes(\"*obsolete*\");\n}\nfunction K() {\n const t = {};\n for (let e = 0; e < N.length; e++)\n t[N[e]] = e + 1;\n return t;\n}\nconst m = {\n allBookIds: N,\n nonCanonicalIds: B,\n bookIdToNumber: g,\n isBookIdValid: k,\n isBookNT: x,\n isBookOT: T,\n isBookOTNT: X,\n isBookDC: V,\n allBookNumbers: L,\n firstBook: G,\n lastBook: A,\n extraBooks: H,\n bookNumberToId: C,\n bookNumberToEnglishName: I,\n bookIdToEnglishName: y,\n isCanonical: w,\n isExtraMaterial: q,\n isObsolete: U\n};\nvar l = /* @__PURE__ */ ((t) => (t[t.Unknown = 0] = \"Unknown\", t[t.Original = 1] = \"Original\", t[t.Septuagint = 2] = \"Septuagint\", t[t.Vulgate = 3] = \"Vulgate\", t[t.English = 4] = \"English\", t[t.RussianProtestant = 5] = \"RussianProtestant\", t[t.RussianOrthodox = 6] = \"RussianOrthodox\", t))(l || {});\nconst h = class h {\n // private versInfo: Versification;\n constructor(e) {\n n(this, \"name\");\n n(this, \"fullPath\");\n n(this, \"isPresent\");\n n(this, \"hasVerseSegments\");\n n(this, \"isCustomized\");\n n(this, \"baseVersification\");\n n(this, \"scriptureBooks\");\n n(this, \"_type\");\n if (e == null)\n throw new Error(\"Argument undefined\");\n typeof e == \"string\" ? (this.name = e, this._type = l[e]) : (this._type = e, this.name = l[e]);\n }\n get type() {\n return this._type;\n }\n equals(e) {\n return !e.type || !this.type ? !1 : e.type === this.type;\n }\n};\nn(h, \"Original\", new h(l.Original)), n(h, \"Septuagint\", new h(l.Septuagint)), n(h, \"Vulgate\", new h(l.Vulgate)), n(h, \"English\", new h(l.English)), n(h, \"RussianProtestant\", new h(l.RussianProtestant)), n(h, \"RussianOrthodox\", new h(l.RussianOrthodox));\nlet c = h;\nfunction E(t, e) {\n const s = e[0];\n for (let r = 1; r < e.length; r++)\n t = t.split(e[r]).join(s);\n return t.split(s);\n}\nvar D = /* @__PURE__ */ ((t) => (t[t.Valid = 0] = \"Valid\", t[t.UnknownVersification = 1] = \"UnknownVersification\", t[t.OutOfRange = 2] = \"OutOfRange\", t[t.VerseOutOfOrder = 3] = \"VerseOutOfOrder\", t[t.VerseRepeated = 4] = \"VerseRepeated\", t))(D || {});\nconst i = class i {\n constructor(e, s, r, a) {\n /** Not yet implemented. */\n n(this, \"firstChapter\");\n /** Not yet implemented. */\n n(this, \"lastChapter\");\n /** Not yet implemented. */\n n(this, \"lastVerse\");\n /** Not yet implemented. */\n n(this, \"hasSegmentsDefined\");\n /** Not yet implemented. */\n n(this, \"text\");\n /** Not yet implemented. */\n n(this, \"BBBCCCVVVS\");\n /** Not yet implemented. */\n n(this, \"longHashCode\");\n /** The versification of the reference. */\n n(this, \"versification\");\n n(this, \"rtlMark\", \"‏\");\n n(this, \"_bookNum\", 0);\n n(this, \"_chapterNum\", 0);\n n(this, \"_verseNum\", 0);\n n(this, \"_verse\");\n if (r == null && a == null)\n if (e != null && typeof e == \"string\") {\n const o = e, u = s != null && s instanceof c ? s : void 0;\n this.setEmpty(u), this.parse(o);\n } else if (e != null && typeof e == \"number\") {\n const o = s != null && s instanceof c ? s : void 0;\n this.setEmpty(o), this._verseNum = e % i.chapterDigitShifter, this._chapterNum = Math.floor(\n e % i.bookDigitShifter / i.chapterDigitShifter\n ), this._bookNum = Math.floor(e / i.bookDigitShifter);\n } else if (s == null)\n if (e != null && e instanceof i) {\n const o = e;\n this._bookNum = o.bookNum, this._chapterNum = o.chapterNum, this._verseNum = o.verseNum, this._verse = o.verse, this.versification = o.versification;\n } else {\n if (e == null) return;\n const o = e instanceof c ? e : i.defaultVersification;\n this.setEmpty(o);\n }\n else\n throw new Error(\"VerseRef constructor not supported.\");\n else if (e != null && s != null && r != null)\n if (typeof e == \"string\" && typeof s == \"string\" && typeof r == \"string\")\n this.setEmpty(a), this.updateInternal(e, s, r);\n else if (typeof e == \"number\" && typeof s == \"number\" && typeof r == \"number\")\n this._bookNum = e, this._chapterNum = s, this._verseNum = r, this.versification = a ?? i.defaultVersification;\n else\n throw new Error(\"VerseRef constructor not supported.\");\n else\n throw new Error(\"VerseRef constructor not supported.\");\n }\n /**\n * Determines if the verse string is in a valid format (does not consider versification).\n */\n static isVerseParseable(e) {\n return e.length > 0 && \"0123456789\".includes(e[0]) && !e.endsWith(this.verseRangeSeparator) && !e.endsWith(this.verseSequenceIndicator);\n }\n /**\n * Tries to parse the specified string into a verse reference.\n * @param str - The string to attempt to parse.\n * @returns success: `true` if the specified string was successfully parsed, `false` otherwise.\n * @returns verseRef: The result of the parse if successful, or empty VerseRef if it failed\n */\n static tryParse(e) {\n let s;\n try {\n return s = new i(e), { success: !0, verseRef: s };\n } catch (r) {\n if (r instanceof v)\n return s = new i(), { success: !1, verseRef: s };\n throw r;\n }\n }\n /**\n * Gets the reference as a comparable integer where the book, chapter, and verse each occupy 3\n * digits.\n * @param bookNum - Book number (this is 1-based, not an index).\n * @param chapterNum - Chapter number.\n * @param verseNum - Verse number.\n * @returns The reference as a comparable integer where the book, chapter, and verse each occupy 3\n * digits.\n */\n static getBBBCCCVVV(e, s, r) {\n return e % i.bcvMaxValue * i.bookDigitShifter + (s >= 0 ? s % i.bcvMaxValue * i.chapterDigitShifter : 0) + (r >= 0 ? r % i.bcvMaxValue : 0);\n }\n /**\n * Deserializes a serialized VerseRef.\n * @param serializedVerseRef - Serialized VerseRef to create from.\n * @returns the deserialized VerseRef.\n */\n static fromJSON(e) {\n const { book: s, chapterNum: r, verseNum: a, verse: o, versificationStr: u } = e, f = o || a.toString();\n let d;\n return u && (d = new c(u)), s ? new i(s, r.toString(), f, d) : new i();\n }\n /**\n * Parses a verse string and gets the leading numeric portion as a number.\n * @param verseStr - verse string to parse\n * @returns true if the entire string could be parsed as a single, simple verse number (1-999);\n * false if the verse string represented a verse bridge, contained segment letters, or was invalid\n */\n static tryGetVerseNum(e) {\n let s;\n if (!e)\n return s = -1, { success: !0, vNum: s };\n s = 0;\n let r;\n for (let a = 0; a < e.length; a++) {\n if (r = e[a], r < \"0\" || r > \"9\")\n return a === 0 && (s = -1), { success: !1, vNum: s };\n if (s = s * 10 + +r - 0, s > i.bcvMaxValue)\n return s = -1, { success: !1, vNum: s };\n }\n return { success: !0, vNum: s };\n }\n /**\n * Checks to see if a VerseRef hasn't been set - all values are the default.\n */\n get isDefault() {\n return this.bookNum === 0 && this.chapterNum === 0 && this.verseNum === 0 && this.versification == null;\n }\n /**\n * Gets whether the verse contains multiple verses.\n */\n get hasMultiple() {\n return this._verse != null && (this._verse.includes(i.verseRangeSeparator) || this._verse.includes(i.verseSequenceIndicator));\n }\n /**\n * Gets or sets the book of the reference. Book is the 3-letter abbreviation in capital letters,\n * e.g. `'MAT'`.\n */\n get book() {\n return m.bookNumberToId(this.bookNum, \"\");\n }\n set book(e) {\n this.bookNum = m.bookIdToNumber(e);\n }\n /**\n * Gets or sets the chapter of the reference,. e.g. `'3'`.\n */\n get chapter() {\n return this.isDefault || this._chapterNum < 0 ? \"\" : this._chapterNum.toString();\n }\n set chapter(e) {\n const s = +e;\n this._chapterNum = Number.isInteger(s) ? s : -1;\n }\n /**\n * Gets or sets the verse of the reference, including range, segments, and sequences, e.g. `'4'`,\n * or `'4b-5a, 7'`.\n */\n get verse() {\n return this._verse != null ? this._verse : this.isDefault || this._verseNum < 0 ? \"\" : this._verseNum.toString();\n }\n set verse(e) {\n const { success: s, vNum: r } = i.tryGetVerseNum(e);\n this._verse = s ? void 0 : e.replace(this.rtlMark, \"\"), this._verseNum = r, !(this._verseNum >= 0) && ({ vNum: this._verseNum } = i.tryGetVerseNum(this._verse));\n }\n /**\n * Get or set Book based on book number, e.g. `42`.\n */\n get bookNum() {\n return this._bookNum;\n }\n set bookNum(e) {\n if (e <= 0 || e > m.lastBook)\n throw new v(\n \"BookNum must be greater than zero and less than or equal to last book\"\n );\n this._bookNum = e;\n }\n /**\n * Gets or sets the chapter number, e.g. `3`. `-1` if not valid.\n */\n get chapterNum() {\n return this._chapterNum;\n }\n set chapterNum(e) {\n this.chapterNum = e;\n }\n /**\n * Gets or sets verse start number, e.g. `4`. `-1` if not valid.\n */\n get verseNum() {\n return this._verseNum;\n }\n set verseNum(e) {\n this._verseNum = e;\n }\n /**\n * String representing the versification (should ONLY be used for serialization/deserialization).\n *\n * @remarks This is for backwards compatibility when ScrVers was an enumeration.\n */\n get versificationStr() {\n var e;\n return (e = this.versification) == null ? void 0 : e.name;\n }\n set versificationStr(e) {\n this.versification = this.versification != null ? new c(e) : void 0;\n }\n /**\n * Determines if the reference is valid.\n */\n get valid() {\n return this.validStatus === 0;\n }\n /**\n * Get the valid status for this reference.\n */\n get validStatus() {\n return this.validateVerse(i.verseRangeSeparators, i.verseSequenceIndicators);\n }\n /**\n * Gets the reference as a comparable integer where the book,\n * chapter, and verse each occupy three digits and the verse is 0.\n */\n get BBBCCC() {\n return i.getBBBCCCVVV(this._bookNum, this._chapterNum, 0);\n }\n /**\n * Gets the reference as a comparable integer where the book,\n * chapter, and verse each occupy three digits. If verse is not null\n * (i.e., this reference represents a complex reference with verse\n * segments or bridge) this cannot be used for an exact comparison.\n */\n get BBBCCCVVV() {\n return i.getBBBCCCVVV(this._bookNum, this._chapterNum, this._verseNum);\n }\n /**\n * Gets whether the verse is defined as an excluded verse in the versification.\n * Does not handle verse ranges.\n */\n // eslint-disable-next-line @typescript-eslint/class-literal-property-style\n get isExcluded() {\n return !1;\n }\n /**\n * Parses the reference in the specified string.\n * Optionally versification can follow reference as in GEN 3:11/4\n * Throw an exception if\n * - invalid book name\n * - chapter number is missing or not a number\n * - verse number is missing or does not start with a number\n * - versification is invalid\n * @param verseStr - string to parse e.g. 'MAT 3:11'\n */\n parse(e) {\n if (e = e.replace(this.rtlMark, \"\"), e.includes(\"/\")) {\n const o = e.split(\"/\");\n if (e = o[0], o.length > 1)\n try {\n const u = +o[1].trim();\n this.versification = new c(l[u]);\n } catch {\n throw new v(\"Invalid reference : \" + e);\n }\n }\n const s = e.trim().split(\" \");\n if (s.length !== 2)\n throw new v(\"Invalid reference : \" + e);\n const r = s[1].split(\":\"), a = +r[0];\n if (r.length !== 2 || m.bookIdToNumber(s[0]) === 0 || !Number.isInteger(a) || a < 0 || !i.isVerseParseable(r[1]))\n throw new v(\"Invalid reference : \" + e);\n this.updateInternal(s[0], r[0], r[1]);\n }\n /**\n * Simplifies this verse ref so that it has no bridging of verses or\n * verse segments like `'1a'`.\n */\n simplify() {\n this._verse = void 0;\n }\n /**\n * Makes a clone of the reference.\n *\n * @returns The cloned VerseRef.\n */\n clone() {\n return new i(this);\n }\n toString() {\n const e = this.book;\n return e === \"\" ? \"\" : `${e} ${this.chapter}:${this.verse}`;\n }\n toJSON() {\n let e = this.verse;\n (e === \"\" || e === this.verseNum.toString()) && (e = void 0);\n const s = {\n book: this.book,\n chapterNum: this.chapterNum,\n verseNum: this.verseNum,\n verse: e,\n versificationStr: this.versificationStr\n };\n return e || delete s.verse, s;\n }\n /**\n * Compares this `VerseRef` with supplied one.\n * @param verseRef - object to compare this one to.\n * @returns `true` if this `VerseRef` is equal to the supplied one, `false` otherwise.\n */\n equals(e) {\n return e instanceof i ? e._bookNum === this._bookNum && e._chapterNum === this._chapterNum && e._verseNum === this._verseNum && e.verse === this.verse && (e.versification == null && this.versification == null || e.versification != null && this.versification != null && e.versification.equals(this.versification)) : !1;\n }\n /**\n * Enumerate all individual verses contained in a VerseRef.\n * Verse ranges are indicated by \"-\" and consecutive verses by \",\"s.\n * Examples:\n * GEN 1:2 returns GEN 1:2\n * GEN 1:1a-3b,5 returns GEN 1:1a, GEN 1:2, GEN 1:3b, GEN 1:5\n * GEN 1:2a-2c returns //! ??????\n *\n * @param specifiedVersesOnly - if set to true return only verses that are\n * explicitly specified only, not verses within a range. Defaults to `false`.\n * @param verseRangeSeparators - Verse range separators.\n * Defaults to `VerseRef.verseRangeSeparators`.\n * @param verseSequenceSeparators - Verse sequence separators.\n * Defaults to `VerseRef.verseSequenceIndicators`.\n * @returns An array of all single verse references in this VerseRef.\n */\n allVerses(e = !1, s = i.verseRangeSeparators, r = i.verseSequenceIndicators) {\n if (this._verse == null || this.chapterNum <= 0)\n return [this.clone()];\n const a = [], o = E(this._verse, r);\n for (const u of o.map((f) => E(f, s))) {\n const f = this.clone();\n f.verse = u[0];\n const d = f.verseNum;\n if (a.push(f), u.length > 1) {\n const b = this.clone();\n if (b.verse = u[1], !e)\n for (let p = d + 1; p < b.verseNum; p++) {\n const J = new i(\n this._bookNum,\n this._chapterNum,\n p,\n this.versification\n );\n this.isExcluded || a.push(J);\n }\n a.push(b);\n }\n }\n return a;\n }\n /**\n * Validates a verse number using the supplied separators rather than the defaults.\n */\n validateVerse(e, s) {\n if (!this.verse)\n return this.internalValid;\n let r = 0;\n for (const a of this.allVerses(!0, e, s)) {\n const o = a.internalValid;\n if (o !== 0)\n return o;\n const u = a.BBBCCCVVV;\n if (r > u)\n return 3;\n if (r === u)\n return 4;\n r = u;\n }\n return 0;\n }\n /**\n * Gets whether a single verse reference is valid.\n */\n get internalValid() {\n return this.versification == null ? 1 : this._bookNum <= 0 || this._bookNum > m.lastBook ? 2 : (m.isCanonical(this._bookNum), 0);\n }\n setEmpty(e = i.defaultVersification) {\n this._bookNum = 0, this._chapterNum = -1, this._verse = void 0, this.versification = e;\n }\n updateInternal(e, s, r) {\n this.bookNum = m.bookIdToNumber(e), this.chapter = s, this.verse = r;\n }\n};\nn(i, \"defaultVersification\", c.English), n(i, \"verseRangeSeparator\", \"-\"), n(i, \"verseSequenceIndicator\", \",\"), n(i, \"verseRangeSeparators\", [i.verseRangeSeparator]), n(i, \"verseSequenceIndicators\", [i.verseSequenceIndicator]), n(i, \"chapterDigitShifter\", 1e3), n(i, \"bookDigitShifter\", i.chapterDigitShifter * i.chapterDigitShifter), n(i, \"bcvMaxValue\", i.chapterDigitShifter - 1), /**\n * The valid status of the VerseRef.\n */\nn(i, \"ValidStatusType\", D);\nlet M = i;\nclass v extends Error {\n}\nexport {\n _ as BookSet,\n m as Canon,\n c as ScrVers,\n l as ScrVersType,\n M as VerseRef,\n v as VerseRefException\n};\n//# sourceMappingURL=index.es.js.map\n","import React from 'react';\nimport * as DropdownMenuPrimitive from '@radix-ui/react-dropdown-menu';\nimport { Check, ChevronRight, Circle } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport const DropdownMenu = DropdownMenuPrimitive.Root;\n\nexport const DropdownMenuTrigger = DropdownMenuPrimitive.Trigger;\n\nexport const DropdownMenuGroup = DropdownMenuPrimitive.Group;\n\nexport const DropdownMenuPortal = DropdownMenuPrimitive.Portal;\n\nexport const DropdownMenuSub = DropdownMenuPrimitive.Sub;\n\nexport const DropdownMenuRadioGroup = DropdownMenuPrimitive.RadioGroup;\n\nexport type DropdownMenuSubTriggerProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.SubTrigger\n> & {\n className?: string;\n inset?: boolean;\n};\n\nexport type DropdownMenuSubContentProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.SubContent\n> & {\n className?: string;\n};\n\nexport type DropdownMenuContentProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Content\n> & {\n className?: string;\n sideOffset?: number;\n};\n\nexport type DropdownMenuItemProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Item\n> & {\n className?: string;\n inset?: boolean;\n};\n\nexport type DropdownMenuCheckboxItemProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.CheckboxItem\n> & {\n className?: string;\n checked?: boolean;\n};\n\nexport type DropdownMenuRadioItemProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.RadioItem\n> & {\n className?: string;\n};\n\nexport type DropdownMenuLabelProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Label\n> & {\n className?: string;\n inset?: boolean;\n};\n\nexport type DropdownMenuSeparatorProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Separator\n> & {\n className?: string;\n};\n\nexport type DropdownMenuShortcutProps = React.HTMLAttributes & {\n className?: string;\n};\n\nexport const DropdownMenuSubTrigger = React.forwardRef<\n React.ElementRef,\n DropdownMenuSubTriggerProps\n>(({ className, inset, children, ...props }, ref) => (\n \n {children}\n \n \n));\nDropdownMenuSubTrigger.displayName = DropdownMenuPrimitive.SubTrigger.displayName;\n\nexport const DropdownMenuSubContent = React.forwardRef<\n React.ElementRef,\n DropdownMenuSubContentProps\n>(({ className, ...props }, ref) => (\n \n));\nDropdownMenuSubContent.displayName = DropdownMenuPrimitive.SubContent.displayName;\n\nexport const DropdownMenuContent = React.forwardRef<\n React.ElementRef,\n DropdownMenuContentProps\n>(({ className, sideOffset = 4, ...props }, ref) => (\n \n \n \n));\nDropdownMenuContent.displayName = DropdownMenuPrimitive.Content.displayName;\n\n/**\n * TODO: fix: direction is not automatically handled by this component, so that shortcuts are\n * display always to the right\n */\nexport const DropdownMenuItem = React.forwardRef<\n React.ElementRef,\n DropdownMenuItemProps\n>(({ className, inset, ...props }, ref) => (\n \n));\nDropdownMenuItem.displayName = DropdownMenuPrimitive.Item.displayName;\n\nexport const DropdownMenuCheckboxItem = React.forwardRef<\n React.ElementRef,\n DropdownMenuCheckboxItemProps\n>(({ className, children, checked, ...props }, ref) => (\n \n \n \n \n \n \n {children}\n \n));\nDropdownMenuCheckboxItem.displayName = DropdownMenuPrimitive.CheckboxItem.displayName;\n\nexport const DropdownMenuRadioItem = React.forwardRef<\n React.ElementRef,\n DropdownMenuRadioItemProps\n>(({ className, children, ...props }, ref) => (\n \n \n \n \n \n \n {children}\n \n));\nDropdownMenuRadioItem.displayName = DropdownMenuPrimitive.RadioItem.displayName;\n\nexport const DropdownMenuLabel = React.forwardRef<\n React.ElementRef,\n DropdownMenuLabelProps\n>(({ className, inset, ...props }, ref) => (\n \n));\nDropdownMenuLabel.displayName = DropdownMenuPrimitive.Label.displayName;\n\nexport const DropdownMenuSeparator = React.forwardRef<\n React.ElementRef,\n DropdownMenuSeparatorProps\n>(({ className, ...props }, ref) => (\n \n));\nDropdownMenuSeparator.displayName = DropdownMenuPrimitive.Separator.displayName;\n\nexport function DropdownMenuShortcut({ className, ...props }: DropdownMenuShortcutProps) {\n return (\n \n );\n}\nDropdownMenuShortcut.displayName = 'DropdownMenuShortcut';\n","import { Canon } from '@sillsdev/scripture';\nimport { PropsWithChildren, KeyboardEvent, forwardRef } from 'react';\nimport { DropdownMenuItem as ShadDropdownMenuItem } from '@/components/shadcn-ui/dropdown-menu';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport type BookType = 'OT' | 'NT' | 'DC';\n\ntype BookMenuItemProps = PropsWithChildren<{\n /** String id of book */\n bookId: string;\n /** Callback to run when a book menu item is selected */\n handleSelectBook: () => void;\n /** Indicates if this menu item is currently selected */\n isSelected: boolean;\n /** Function that is called upon highlighting a book in the dropdown menu */\n handleHighlightBook: () => void;\n /**\n * Function that is called on pressing a key\n *\n * @param event Event that contains information about the key stroke\n */\n handleKeyDown: (event: KeyboardEvent) => void;\n /**\n * Type of book associated with this menu item, coordinates color labels ? Mock up has the labels\n * coordinated to genre\n */\n bookType: BookType;\n}>;\n\nconst BookMenuItem = forwardRef(\n (\n {\n bookId,\n handleSelectBook,\n isSelected,\n handleHighlightBook,\n handleKeyDown,\n bookType,\n children,\n }: BookMenuItemProps,\n ref,\n ) => {\n return (\n {\n // preventDefault() here prevents the entire dropdown menu from closing when selecting this item\n event.preventDefault();\n handleSelectBook();\n }}\n onKeyDown={(event: KeyboardEvent) => {\n handleKeyDown(event);\n }}\n onFocus={handleHighlightBook}\n onMouseMove={handleHighlightBook}\n >\n \n {Canon.bookIdToEnglishName(bookId)}\n \n {isSelected &&
    {children}
    }\n \n );\n },\n);\n\nexport default BookMenuItem;\n","import { cn } from '@/utils/shadcn-ui.util';\nimport { useCallback } from 'react';\n\nexport type ChapterSelectProps = {\n /**\n * Callback to run when a chapter div is selected\n *\n * @param chapterNumber Number of the chapter that has been selected\n */\n handleSelectChapter: (chapterNumber: number) => void;\n /** The highest chapter number in the book (of course equal to number of chapters in the book) */\n endChapter: number;\n /** The chapter number that is currently selected */\n activeChapter: number;\n /** The chapter number that is currently highlighted using keyboard or mouse navigation */\n highlightedChapter: number;\n /**\n * Callback to run when a chapter is highlighted by the user\n *\n * @param chapterNumber The chapter that is highlighted\n */\n handleHighlightedChapter: (chapterNumber: number) => void;\n};\n\nfunction ChapterSelect({\n handleSelectChapter,\n endChapter,\n activeChapter,\n highlightedChapter,\n handleHighlightedChapter,\n}: ChapterSelectProps) {\n const chapters = Array.from({ length: endChapter }, (_, i) => i + 1);\n\n const handleMouse = useCallback(\n (chapterNumber: number) => {\n handleHighlightedChapter(chapterNumber);\n },\n [handleHighlightedChapter],\n );\n\n return (\n
    \n {chapters.map((chapter) => (\n {\n event.preventDefault();\n event.stopPropagation();\n handleSelectChapter(chapter);\n }}\n role=\"button\"\n onKeyDown={(event) => {\n if (event.key === 'Enter') {\n handleSelectChapter(chapter);\n }\n }}\n tabIndex={0}\n onMouseMove={() => handleMouse(chapter)}\n >\n {chapter}\n
    \n ))}\n
    \n );\n}\n\nexport default ChapterSelect;\n","import { DropdownMenuLabel as ShadDropdownMenuLabel } from '@/components/shadcn-ui/dropdown-menu';\nimport { Bookmark, Clock, ArrowDownWideNarrow } from 'lucide-react';\n\nexport type GoToMenuItemProps = {\n handleSort: () => void;\n handleLocationHistory: () => void;\n handleBookmarks: () => void;\n};\n\nfunction GoToMenuItem({ handleSort, handleLocationHistory, handleBookmarks }: GoToMenuItemProps) {\n return (\n \n

    Go To

    \n
    \n \n \n \n
    \n
    \n );\n}\n\nexport default GoToMenuItem;\n","import BookChapterInput from '@/components/advanced/book-chapter-control/book-chapter-input.component';\nimport BookMenuItem, {\n BookType,\n} from '@/components/advanced/book-chapter-control/book-menu-item.component';\nimport ChapterSelect from '@/components/advanced/book-chapter-control/chapter-select.component';\nimport GoToMenuItem from '@/components/advanced/book-chapter-control/go-to-menu-item.component';\nimport {\n DropdownMenu as ShadDropdownMenu,\n DropdownMenuContent as ShadDropdownMenuContent,\n DropdownMenuLabel as ShadDropdownMenuLabel,\n DropdownMenuSeparator as ShadDropdownMenuSeparator,\n DropdownMenuTrigger as ShadDropdownMenuTrigger,\n} from '@/components/shadcn-ui/dropdown-menu';\nimport { Canon } from '@sillsdev/scripture';\nimport { ScriptureReference, getChaptersForBook } from 'platform-bible-utils';\nimport {\n KeyboardEvent as ReactKeyboardEvent,\n useCallback,\n useEffect,\n useLayoutEffect,\n useRef,\n useState,\n} from 'react';\n\ntype BookTypeLabels = {\n [bookType in BookType]: string;\n};\ntype BookChapterControlProps = {\n scrRef: ScriptureReference;\n handleSubmit: (scrRef: ScriptureReference) => void;\n};\n\nconst ALL_BOOK_IDS = Canon.allBookIds;\nconst BOOK_TYPE_LABELS: BookTypeLabels = {\n OT: 'Old Testament',\n NT: 'New Testament',\n DC: 'Deuterocanon',\n};\nconst BOOK_TYPE_ARRAY: BookType[] = ['OT', 'NT', 'DC'];\n// This is the height of three menu items to offset scrolling to the selected menu item\n// If you use menuItemRef.clientHeight- includes height of chapter div which is too big\nconst SCROLL_OFFSET = 32 + 32 + 32;\nconst SEARCH_QUERY_FORMATS = [\n /^(\\w+)$/i, // Matches a single word (book name or id)\n /^(\\w+)(?:\\s(\\d+))$/i, // Matches a word followed by a chapter number\n /^(\\w+)(?:\\s(\\d+):(\\d+))$/i, // Matches a word followed by a chapter and verse number\n];\nconst fetchGroupedBooks = (bookType: BookType) => {\n const groupedBooks = {\n OT: ALL_BOOK_IDS.filter((bookId) => Canon.isBookOT(bookId)),\n NT: ALL_BOOK_IDS.filter((bookId) => Canon.isBookNT(bookId)),\n DC: ALL_BOOK_IDS.filter((bookId) => Canon.isBookDC(bookId)),\n };\n return groupedBooks[bookType];\n};\nconst fetchEndChapter = (bookId: string) => {\n // getChaptersForBook returns -1 if not found in scrBookData\n // scrBookData only includes OT and NT, so all DC will return -1\n return getChaptersForBook(Canon.bookIdToNumber(bookId));\n};\n\n/**\n * Gets all of the English names from book ids\n *\n * @returns String[]\n */\nfunction getAllEnglishNames(): string[] {\n const allEnglishNames = ALL_BOOK_IDS.map((bookId) => {\n return Canon.bookIdToEnglishName(bookId);\n });\n return allEnglishNames;\n}\n\n/**\n * Determines if bookName is in allEnglishNames\n *\n * @param bookName Book English name\n * @returns True if bookName is included, false otherwise\n */\nfunction isValidBookEnglishName(bookName: string): boolean {\n return getAllEnglishNames().includes(bookName);\n}\n\n/**\n * Gets a bookId from given English name\n *\n * @param bookName Book English name\n * @returns BookId of provided bookName, undefined otherwise\n */\nfunction getBookIdFromEnglishName(bookName: string): string | undefined {\n // Convert bookName to lowercase and then capitalize the first letter\n const formattedBookName = bookName.toLowerCase().replace(/^\\w/, (c) => c.toUpperCase());\n\n if (isValidBookEnglishName(formattedBookName)) {\n const matchingBookId = ALL_BOOK_IDS.find((bookId) => {\n return Canon.bookIdToEnglishName(bookId) === formattedBookName;\n });\n return matchingBookId;\n }\n\n return undefined;\n}\n\nfunction BookChapterControl({ scrRef, handleSubmit }: BookChapterControlProps) {\n const [searchQuery, setSearchQuery] = useState('');\n const [selectedBookId, setSelectedBookId] = useState(\n Canon.bookNumberToId(scrRef.bookNum),\n );\n const [highlightedChapter, setHighlightedChapter] = useState(scrRef.chapterNum ?? 0);\n const [highlightedBookId, setHighlightedBookId] = useState(\n Canon.bookNumberToId(scrRef.bookNum),\n );\n const [isContentOpen, setIsContentOpen] = useState(false);\n const [isContentOpenDelayed, setIsContentOpenDelayed] = useState(isContentOpen);\n\n // This ref will always be defined\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const inputRef = useRef(undefined!);\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const contentRef = useRef(undefined!);\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const menuItemRef = useRef(undefined!);\n\n const fetchFilteredBooks = useCallback(\n (bookType: BookType) => {\n return fetchGroupedBooks(bookType).filter((bookId: string) => {\n const englishNameLowerCase = Canon.bookIdToEnglishName(bookId).toLowerCase();\n const normalizedQuery = searchQuery.replace(/[^a-zA-Z]/g, '').toLowerCase();\n return (\n englishNameLowerCase.includes(normalizedQuery) || // Match book name\n bookId.toLowerCase().includes(normalizedQuery) // Match book ID\n );\n });\n },\n [searchQuery],\n );\n\n const handleSearchInput = (searchString: string) => {\n setSearchQuery(searchString);\n };\n\n /**\n * Whether to prevent radix's logic from closing the dropdown. This is important because radix\n * tries to close the dropdown when the input first focuses, and we don't want it to do that. But\n * we don't want to prevent the dropdown from closing when we click away from the input, so we\n * don't want to just keep it open if the input is focused\n */\n const shouldPreventAutoClosing = useRef(false);\n\n const controlMenuState = useCallback((open: boolean) => {\n if (shouldPreventAutoClosing.current) {\n shouldPreventAutoClosing.current = false;\n return;\n }\n setIsContentOpen(open);\n }, []);\n\n const updateReference = useCallback(\n (bookId: string, shouldClose: boolean, chapter?: number, verse?: number) => {\n setHighlightedChapter(\n Canon.bookNumberToId(scrRef.bookNum) !== bookId ? 1 : scrRef.chapterNum,\n );\n\n if (shouldClose || fetchEndChapter(bookId) === -1) {\n handleSubmit({\n bookNum: Canon.bookIdToNumber(bookId),\n chapterNum: chapter || 1,\n verseNum: verse || 1,\n });\n\n setIsContentOpen(false);\n setSearchQuery('');\n return;\n }\n\n setSelectedBookId(selectedBookId !== bookId ? bookId : '');\n setIsContentOpen(!shouldClose);\n },\n [handleSubmit, scrRef.bookNum, scrRef.chapterNum, selectedBookId],\n );\n\n const handleSelectChapter = (chapterNumber: number) => {\n if (chapterNumber <= 0 || chapterNumber > fetchEndChapter(selectedBookId)) {\n return;\n }\n updateReference(selectedBookId, true, chapterNumber);\n };\n\n const handleInputSubmit = useCallback(() => {\n SEARCH_QUERY_FORMATS.forEach((format) => {\n const matches = searchQuery.match(format);\n if (matches) {\n // Book should be a bookId or an english name\n const [book, chapter = undefined, verse = undefined] = matches.slice(1);\n const englishName = getBookIdFromEnglishName(book);\n\n if (Canon.isBookIdValid(book) || englishName) {\n updateReference(\n englishName ?? book,\n true,\n chapter ? parseInt(chapter, 10) : 1,\n verse ? parseInt(verse, 10) : 1,\n );\n }\n }\n });\n }, [updateReference, searchQuery]);\n\n const handleKeyDownInput = useCallback(\n (event: ReactKeyboardEvent) => {\n if (!isContentOpen) {\n setIsContentOpen(true);\n } else if (event.key === 'ArrowDown' || event.key === 'ArrowUp') {\n if (\n typeof menuItemRef !== 'undefined' &&\n // Ref uses null\n // eslint-disable-next-line no-null/no-null\n menuItemRef.current !== null\n ) {\n menuItemRef.current.focus();\n } else if (\n typeof contentRef !== 'undefined' &&\n // Ref uses null\n // eslint-disable-next-line no-null/no-null\n contentRef.current !== null\n ) {\n contentRef.current.focus();\n }\n event.preventDefault();\n }\n },\n [isContentOpen],\n );\n\n const handleKeyDownContent = (event: ReactKeyboardEvent) => {\n // When the dropdown menu has focus, key strokes should give focus to the input component,\n // unless they're navigation keys (arrows and enter)\n const { key } = event;\n if (\n key === 'ArrowRight' ||\n key === 'ArrowLeft' ||\n key === 'ArrowDown' ||\n key === 'ArrowUp' ||\n key === 'Enter'\n ) {\n return;\n }\n\n inputRef.current.dispatchEvent(new KeyboardEvent('keydown', { key }));\n inputRef.current.focus();\n };\n\n const handleKeyDownMenuItem = (event: ReactKeyboardEvent) => {\n const { key } = event;\n if (highlightedBookId === selectedBookId) {\n if (key === 'Enter') {\n event.preventDefault();\n updateReference(selectedBookId, true, highlightedChapter);\n return;\n }\n\n let chapterOffSet = 0;\n if (key === 'ArrowRight') {\n if (highlightedChapter < fetchEndChapter(highlightedBookId)) {\n chapterOffSet = 1;\n } else {\n event.preventDefault();\n return;\n }\n } else if (key === 'ArrowLeft') {\n if (highlightedChapter > 1) {\n chapterOffSet = -1;\n } else {\n event.preventDefault();\n return;\n }\n } else if (key === 'ArrowDown') {\n chapterOffSet = 6;\n } else if (key === 'ArrowUp') {\n chapterOffSet = -6;\n }\n if (\n highlightedChapter + chapterOffSet <= 0 ||\n highlightedChapter + chapterOffSet > fetchEndChapter(highlightedBookId)\n ) {\n setHighlightedChapter(0);\n } else if (chapterOffSet !== 0) {\n setHighlightedChapter(highlightedChapter + chapterOffSet);\n event.preventDefault();\n }\n }\n };\n\n useEffect(() => {\n if (selectedBookId === highlightedBookId) {\n if (selectedBookId === Canon.bookNumberToId(scrRef.bookNum)) {\n setHighlightedChapter(scrRef.chapterNum);\n } else {\n setHighlightedChapter(1);\n }\n } else {\n setHighlightedChapter(0);\n }\n }, [highlightedBookId, scrRef.bookNum, scrRef.chapterNum, selectedBookId]);\n\n // The purpose of these useLayoutEffects and timeout is to delay the scroll just\n // enough so that the refs are defined and available when they are used after the timeout\n useLayoutEffect(() => {\n setIsContentOpenDelayed(isContentOpen);\n }, [isContentOpen]);\n\n useLayoutEffect(() => {\n const scrollTimeout = setTimeout(() => {\n if (isContentOpenDelayed && contentRef.current && menuItemRef.current) {\n const menuItemOffsetTop = menuItemRef.current.offsetTop;\n const scrollPosition = menuItemOffsetTop - SCROLL_OFFSET;\n contentRef.current.scrollTo({ top: scrollPosition, behavior: 'instant' });\n }\n }, 10);\n return () => {\n clearTimeout(scrollTimeout);\n };\n }, [isContentOpenDelayed]);\n\n return (\n
    \n \n \n {\n setSelectedBookId(Canon.bookNumberToId(scrRef.bookNum));\n setHighlightedBookId(Canon.bookNumberToId(scrRef.bookNum));\n setHighlightedChapter(scrRef.chapterNum > 0 ? scrRef.chapterNum : 0);\n setIsContentOpen(true);\n inputRef.current.focus();\n }}\n onFocus={() => {\n // Radix thinks we want to close because the input is being focused. Prevent that\n shouldPreventAutoClosing.current = true;\n }}\n handleSubmit={handleInputSubmit}\n placeholder={`${Canon.bookNumberToEnglishName(scrRef.bookNum)} ${scrRef.chapterNum}:${scrRef.verseNum}`}\n />\n \n \n console.log('sorting')}\n handleLocationHistory={() => console.log('location history')}\n handleBookmarks={() => console.log('bookmarks')}\n />\n {BOOK_TYPE_ARRAY.map(\n (bookType, bookTypeIndex) =>\n fetchFilteredBooks(bookType).length > 0 && (\n
    \n \n {BOOK_TYPE_LABELS[bookType]}\n \n\n {fetchFilteredBooks(bookType).map((bookId) => (\n
    \n updateReference(bookId, false)}\n isSelected={selectedBookId === bookId}\n handleHighlightBook={() => setHighlightedBookId(bookId)}\n handleKeyDown={handleKeyDownMenuItem}\n bookType={bookType}\n ref={(element: HTMLDivElement) => {\n if (selectedBookId === bookId) menuItemRef.current = element;\n }}\n >\n {\n setHighlightedChapter(chapterNumber);\n }}\n />\n \n
    \n ))}\n {BOOK_TYPE_ARRAY.length - 1 !== bookTypeIndex ? (\n \n ) : undefined}\n
    \n ),\n )}\n \n
    \n
    \n );\n}\n\nexport default BookChapterControl;\n","import React from 'react';\nimport { Slot } from '@radix-ui/react-slot';\nimport { cva, type VariantProps } from 'class-variance-authority';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport const buttonVariants = cva(\n 'pr-twp tw-inline-flex tw-items-center tw-justify-center tw-whitespace-nowrap tw-rounded-md tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-colors focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50',\n {\n variants: {\n variant: {\n default: 'tw-bg-primary tw-text-primary-foreground hover:tw-bg-primary/90',\n destructive: 'tw-bg-destructive tw-text-destructive-foreground hover:tw-bg-destructive/90',\n outline:\n 'tw-border tw-border-input tw-bg-background hover:tw-bg-accent hover:tw-text-accent-foreground',\n secondary: 'tw-bg-secondary tw-text-secondary-foreground hover:tw-bg-secondary/80',\n ghost: 'hover:tw-bg-accent hover:tw-text-accent-foreground',\n link: 'tw-text-primary tw-underline-offset-4 hover:tw-underline',\n },\n size: {\n default: 'tw-h-10 tw-px-4 tw-py-2',\n sm: 'tw-h-9 tw-rounded-md tw-px-3',\n lg: 'tw-h-11 tw-rounded-md tw-px-8',\n icon: 'tw-h-10 tw-w-10',\n },\n },\n defaultVariants: {\n variant: 'default',\n size: 'default',\n },\n },\n);\n\nexport interface ButtonProps\n extends React.ButtonHTMLAttributes,\n VariantProps {\n asChild?: boolean;\n}\n\nexport const Button = React.forwardRef(\n ({ className, variant, size, asChild = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'button';\n return (\n \n );\n },\n);\nButton.displayName = 'Button';\n","import React from 'react';\nimport * as LabelPrimitive from '@radix-ui/react-label';\nimport { cva, type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst labelVariants = cva(\n 'tw-text-sm tw-font-medium tw-leading-none peer-disabled:tw-cursor-not-allowed peer-disabled:tw-opacity-70',\n);\n\nexport const Label = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef & VariantProps\n>(({ className, ...props }, ref) => (\n \n));\nLabel.displayName = LabelPrimitive.Root.displayName;\n","import React from 'react';\nimport * as RadioGroupPrimitive from '@radix-ui/react-radio-group';\nimport { Circle } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst RadioGroup = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => {\n return (\n \n );\n});\nRadioGroup.displayName = RadioGroupPrimitive.Root.displayName;\n\nconst RadioGroupItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => {\n return (\n \n \n \n \n \n );\n});\nRadioGroupItem.displayName = RadioGroupPrimitive.Item.displayName;\n\nexport { RadioGroup, RadioGroupItem };\n","import React from 'react';\nimport * as PopoverPrimitive from '@radix-ui/react-popover';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Popover = PopoverPrimitive.Root;\n\nconst PopoverTrigger = PopoverPrimitive.Trigger;\n\nconst PopoverContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, align = 'center', sideOffset = 4, ...props }, ref) => (\n \n \n \n));\nPopoverContent.displayName = PopoverPrimitive.Content.displayName;\n\nexport { Popover, PopoverTrigger, PopoverContent };\n","import React from 'react';\nimport * as DialogPrimitive from '@radix-ui/react-dialog';\nimport { X } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Dialog = DialogPrimitive.Root;\n\nconst DialogTrigger = DialogPrimitive.Trigger;\n\nconst DialogPortal = DialogPrimitive.Portal;\n\nconst DialogClose = DialogPrimitive.Close;\n\nconst DialogOverlay = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nDialogOverlay.displayName = DialogPrimitive.Overlay.displayName;\n\nconst DialogContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, ...props }, ref) => (\n \n \n \n {children}\n \n \n Close\n \n \n \n));\nDialogContent.displayName = DialogPrimitive.Content.displayName;\n\nfunction DialogHeader({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nDialogHeader.displayName = 'DialogHeader';\n\nfunction DialogFooter({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nDialogFooter.displayName = 'DialogFooter';\n\nconst DialogTitle = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nDialogTitle.displayName = DialogPrimitive.Title.displayName;\n\nconst DialogDescription = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nDialogDescription.displayName = DialogPrimitive.Description.displayName;\n\nexport {\n Dialog,\n DialogPortal,\n DialogOverlay,\n DialogClose,\n DialogTrigger,\n DialogContent,\n DialogHeader,\n DialogFooter,\n DialogTitle,\n DialogDescription,\n};\n","import React from 'react';\nimport { type DialogProps } from '@radix-ui/react-dialog';\nimport { Command as CommandPrimitive } from 'cmdk';\nimport { Search } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Dialog, DialogContent } from '@/components/shadcn-ui/dialog';\n\nconst Command = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nCommand.displayName = CommandPrimitive.displayName;\n\ninterface CommandDialogProps extends DialogProps {}\n\nfunction CommandDialog({ children, ...props }: CommandDialogProps) {\n return (\n \n \n \n {children}\n \n \n \n );\n}\n\nconst CommandInput = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n
    \n \n \n
    \n));\n\nCommandInput.displayName = CommandPrimitive.Input.displayName;\n\nconst CommandList = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\n\nCommandList.displayName = CommandPrimitive.List.displayName;\n\nconst CommandEmpty = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>((props, ref) => (\n \n));\n\nCommandEmpty.displayName = CommandPrimitive.Empty.displayName;\n\nconst CommandGroup = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\n\nCommandGroup.displayName = CommandPrimitive.Group.displayName;\n\nconst CommandSeparator = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nCommandSeparator.displayName = CommandPrimitive.Separator.displayName;\n\nconst CommandItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\n\nCommandItem.displayName = CommandPrimitive.Item.displayName;\n\nfunction CommandShortcut({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nCommandShortcut.displayName = 'CommandShortcut';\n\nexport {\n Command,\n CommandDialog,\n CommandInput,\n CommandList,\n CommandEmpty,\n CommandGroup,\n CommandItem,\n CommandShortcut,\n CommandSeparator,\n};\n","import { useState } from 'react';\nimport { Check, ChevronsUpDown } from 'lucide-react';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport { Popover, PopoverContent, PopoverTrigger } from '@/components/shadcn-ui/popover';\nimport {\n Command,\n CommandEmpty,\n CommandInput,\n CommandItem,\n CommandList,\n} from '@/components/shadcn-ui/command';\nimport { PopoverProps } from '@radix-ui/react-popover';\n\nexport type ComboBoxLabelOption = { label: string };\nexport type ComboBoxOption = string | number | ComboBoxLabelOption;\n\nexport type ComboBoxProps = {\n /** Optional unique identifier */\n id?: string;\n /** Text label title for combobox */\n /** List of available options for the dropdown menu */\n options?: readonly T[];\n /** Additional css classes to help with unique styling of the combo box button */\n buttonClassName?: string;\n /** Additional css classes to help with unique styling of the combo box popover */\n popoverContentClassName?: string;\n /**\n * The selected value that the combo box currently holds. Must be shallow equal to one of the\n * options entries.\n */\n value?: T;\n /** Triggers when content of textfield is changed */\n onChange?: (newValue: T) => void;\n /** Used to determine the string value for a given option. */\n getOptionLabel?: (option: ComboBoxOption) => string;\n /** Text displayed on button if `value` is undefined */\n buttonPlaceholder?: string;\n /** Placeholder text for text field */\n textPlaceholder?: string;\n /** Text to display when no options match input */\n commandEmptyMessage?: string;\n /** Variant of button */\n buttonVariant?: ButtonProps['variant'];\n /** Text direction ltr or rtl */\n dir?: Direction;\n /** Optional boolean to set if trigger should be disabled */\n isDisabled?: boolean;\n} & PopoverProps;\n\ntype Direction = 'ltr' | 'rtl';\n\nfunction getOptionLabelDefault(option: ComboBoxOption): string {\n if (typeof option === 'string') {\n return option;\n }\n if (typeof option === 'number') {\n return option.toString();\n }\n return option.label;\n}\n\n/**\n * Autocomplete input and command palette with a list of suggestions.\n *\n * Thanks to Shadcn for heavy inspiration and documentation\n * https://ui.shadcn.com/docs/components/combobox\n */\nfunction ComboBox({\n id,\n options = [],\n buttonClassName,\n popoverContentClassName,\n value,\n onChange = () => {},\n getOptionLabel = getOptionLabelDefault,\n buttonPlaceholder = '',\n textPlaceholder = '',\n commandEmptyMessage = 'No option found',\n buttonVariant = 'outline',\n dir = 'ltr',\n isDisabled = false,\n ...props\n}: ComboBoxProps) {\n const [open, setOpen] = useState(false);\n\n return (\n \n \n \n \n {value ? getOptionLabel(value) : buttonPlaceholder}\n \n \n \n \n \n \n \n {commandEmptyMessage}\n \n {options.map((option) => (\n {\n onChange(option);\n setOpen(false);\n }}\n >\n \n {getOptionLabel(option)}\n \n ))}\n \n \n \n \n );\n}\n\nexport default ComboBox;\n","import { useMemo } from 'react';\nimport ComboBox from '@/components/basics/combo-box.component';\nimport { Label } from '@/components/shadcn-ui/label';\n\nexport type ChapterRangeSelectorProps = {\n startChapter: number;\n endChapter: number;\n handleSelectStartChapter: (chapter: number) => void;\n handleSelectEndChapter: (chapter: number) => void;\n isDisabled?: boolean;\n chapterCount: number;\n};\n\nexport default function ChapterRangeSelector({\n startChapter,\n endChapter,\n handleSelectStartChapter,\n handleSelectEndChapter,\n isDisabled = false,\n chapterCount,\n}: ChapterRangeSelectorProps) {\n const chapterOptions = useMemo(\n () => Array.from({ length: chapterCount }, (_, index) => index + 1),\n [chapterCount],\n );\n\n const onChangeStartChapter = (value: number) => {\n handleSelectStartChapter(value);\n if (value > endChapter) {\n handleSelectEndChapter(value);\n }\n };\n\n const onChangeEndChapter = (value: number) => {\n handleSelectEndChapter(value);\n if (value < startChapter) {\n handleSelectStartChapter(value);\n }\n };\n\n return (\n <>\n \n option.toString()}\n value={startChapter}\n />\n\n \n option.toString()}\n value={endChapter}\n />\n \n );\n}\n","import { Button } from '@/components/shadcn-ui/button';\nimport { Label } from '@/components/shadcn-ui/label';\nimport { RadioGroup, RadioGroupItem } from '@/components/shadcn-ui/radio-group';\nimport { Canon } from '@sillsdev/scripture';\nimport { LocalizedStringValue } from 'platform-bible-utils';\nimport { useState } from 'react';\nimport ChapterRangeSelector, {\n ChapterRangeSelectorProps,\n} from '../basics/chapter-range-selector.component';\n\nexport enum BookSelectionMode {\n CURRENT_BOOK = 'current book',\n CHOOSE_BOOKS = 'choose books',\n}\n\n/**\n * Object containing all keys used for localization in this component. If you're using this\n * component in an extension, you can pass it into the useLocalizedStrings hook to easily obtain the\n * localized strings and pass them into the localizedStrings prop of this component\n */\nexport const BOOK_SELECTOR_STRING_KEYS = Object.freeze([\n '%webView_bookSelector_currentBook%',\n '%webView_bookSelector_choose%',\n '%webView_bookSelector_chooseBooks%',\n] as const);\n\nexport type BookSelectorLocalizedStrings = {\n [localizedInventoryKey in (typeof BOOK_SELECTOR_STRING_KEYS)[number]]?: LocalizedStringValue;\n};\n\n/**\n * Gets the localized value for the provided key\n *\n * @param strings Object containing localized string\n * @param key Key for a localized string\n * @returns The localized value for the provided key, if available. Returns the key if no localized\n * value is available\n */\nconst localizeString = (\n strings: BookSelectorLocalizedStrings,\n key: keyof BookSelectorLocalizedStrings,\n) => {\n return strings[key] ?? key;\n};\n\ntype BookSelectorProps = ChapterRangeSelectorProps & {\n handleBookSelectionModeChange: (newMode: BookSelectionMode) => void;\n currentBookName: string;\n onSelectBooks: () => void;\n selectedBookIds: string[];\n localizedStrings: BookSelectorLocalizedStrings;\n};\n\nexport default function BookSelector({\n handleBookSelectionModeChange,\n currentBookName,\n onSelectBooks,\n selectedBookIds,\n chapterCount,\n endChapter,\n handleSelectEndChapter,\n startChapter,\n handleSelectStartChapter,\n localizedStrings,\n}: BookSelectorProps) {\n const currentBookText = localizeString(localizedStrings, '%webView_bookSelector_currentBook%');\n const chooseText = localizeString(localizedStrings, '%webView_bookSelector_choose%');\n const chooseBooksText = localizeString(localizedStrings, '%webView_bookSelector_chooseBooks%');\n\n const [bookSelectionMode, setBookSelectionMode] = useState(\n BookSelectionMode.CURRENT_BOOK,\n );\n\n const onSelectionModeChange = (newMode: BookSelectionMode) => {\n setBookSelectionMode(newMode);\n handleBookSelectionModeChange(newMode);\n };\n\n return (\n onSelectionModeChange(value as BookSelectionMode)}\n >\n
    \n
    \n
    \n \n \n
    \n \n
    \n \n
    \n
    \n
    \n
    \n \n \n
    \n \n onSelectBooks()}\n >\n {chooseText}\n \n
    \n
    \n \n );\n}\n","import { DropdownMenuTrigger } from '@radix-ui/react-dropdown-menu';\nimport { FilterIcon } from 'lucide-react';\nimport { Table } from '@tanstack/react-table';\n\nimport { Button } from '@/components/shadcn-ui/button';\nimport {\n DropdownMenu,\n DropdownMenuCheckboxItem,\n DropdownMenuContent,\n DropdownMenuLabel,\n DropdownMenuSeparator,\n} from '@/components/shadcn-ui/dropdown-menu';\n\ninterface DataTableViewOptionsProps {\n table: Table;\n}\n\nfunction DataTableViewOptions({ table }: DataTableViewOptionsProps) {\n return (\n \n \n \n \n \n Toggle columns\n \n {table\n .getAllColumns()\n .filter((column) => column.getCanHide())\n .map((column) => {\n return (\n column.toggleVisibility(!!value)}\n >\n {column.id}\n \n );\n })}\n \n \n );\n}\n\nexport default DataTableViewOptions;\n","import React from 'react';\nimport * as SelectPrimitive from '@radix-ui/react-select';\nimport { Check, ChevronDown, ChevronUp } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Select = SelectPrimitive.Root;\n\nconst SelectGroup = SelectPrimitive.Group;\n\nconst SelectValue = SelectPrimitive.Value;\n\nconst SelectTrigger = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, ...props }, ref) => (\n span]:tw-line-clamp-1',\n className,\n )}\n {...props}\n >\n {children}\n \n \n \n \n));\nSelectTrigger.displayName = SelectPrimitive.Trigger.displayName;\n\nconst SelectScrollUpButton = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n));\nSelectScrollUpButton.displayName = SelectPrimitive.ScrollUpButton.displayName;\n\nconst SelectScrollDownButton = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n));\nSelectScrollDownButton.displayName = SelectPrimitive.ScrollDownButton.displayName;\n\nconst SelectContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, position = 'popper', ...props }, ref) => (\n \n \n \n \n {children}\n \n \n \n \n));\nSelectContent.displayName = SelectPrimitive.Content.displayName;\n\nconst SelectLabel = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSelectLabel.displayName = SelectPrimitive.Label.displayName;\n\nconst SelectItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, ...props }, ref) => (\n \n \n \n \n \n \n\n {children}\n \n));\nSelectItem.displayName = SelectPrimitive.Item.displayName;\n\nconst SelectSeparator = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSelectSeparator.displayName = SelectPrimitive.Separator.displayName;\n\nexport {\n Select,\n SelectGroup,\n SelectValue,\n SelectTrigger,\n SelectContent,\n SelectLabel,\n SelectItem,\n SelectSeparator,\n SelectScrollUpButton,\n SelectScrollDownButton,\n};\n","import { ChevronLeftIcon, ChevronRightIcon, ArrowLeftIcon, ArrowRightIcon } from 'lucide-react';\nimport { Table } from '@tanstack/react-table';\n\nimport { Button } from '@/components/shadcn-ui/button';\nimport {\n Select,\n SelectContent,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\n\ninterface DataTablePaginationProps {\n table: Table;\n}\n\nfunction DataTablePagination({ table }: DataTablePaginationProps) {\n return (\n
    \n
    \n
    \n {table.getFilteredSelectedRowModel().rows.length} of{' '}\n {table.getFilteredRowModel().rows.length} row(s) selected\n
    \n
    \n

    Rows per page

    \n {\n table.setPageSize(Number(value));\n }}\n >\n \n \n \n \n {[10, 20, 30, 40, 50].map((pageSize) => (\n \n {pageSize}\n \n ))}\n \n \n
    \n
    \n Page {table.getState().pagination.pageIndex + 1} of {table.getPageCount()}\n
    \n
    \n table.setPageIndex(0)}\n disabled={!table.getCanPreviousPage()}\n >\n Go to first page\n \n \n table.previousPage()}\n disabled={!table.getCanPreviousPage()}\n >\n Go to previous page\n \n \n table.nextPage()}\n disabled={!table.getCanNextPage()}\n >\n Go to next page\n \n \n table.setPageIndex(table.getPageCount() - 1)}\n disabled={!table.getCanNextPage()}\n >\n Go to last page\n \n \n
    \n
    \n
    \n );\n}\n\nexport default DataTablePagination;\n","import React from 'react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Table = React.forwardRef<\n HTMLTableElement,\n React.HTMLAttributes & { stickyHeader?: boolean }\n>(({ className, stickyHeader, ...props }, ref) => (\n
    \n \n
    \n));\nTable.displayName = 'Table';\n\nconst TableHeader = React.forwardRef<\n HTMLTableSectionElement,\n React.HTMLAttributes & { stickyHeader?: boolean }\n>(({ className, stickyHeader, ...props }, ref) => (\n \n));\nTableHeader.displayName = 'TableHeader';\n\nconst TableBody = React.forwardRef<\n HTMLTableSectionElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableBody.displayName = 'TableBody';\n\nconst TableFooter = React.forwardRef<\n HTMLTableSectionElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n tr]:last:tw-border-b-0', className)}\n {...props}\n />\n));\nTableFooter.displayName = 'TableFooter';\n\nconst TableRow = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nTableRow.displayName = 'TableRow';\n\nconst TableHead = React.forwardRef<\n HTMLTableCellElement,\n React.ThHTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableHead.displayName = 'TableHead';\n\nconst TableCell = React.forwardRef<\n HTMLTableCellElement,\n React.TdHTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableCell.displayName = 'TableCell';\n\nconst TableCaption = React.forwardRef<\n HTMLTableCaptionElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableCaption.displayName = 'TableCaption';\n\nexport { Table, TableHeader, TableBody, TableFooter, TableHead, TableRow, TableCell, TableCaption };\n","import { useState } from 'react';\n\nimport {\n ColumnFiltersState,\n flexRender,\n getCoreRowModel,\n getFilteredRowModel,\n getPaginationRowModel,\n getSortedRowModel,\n SortingState,\n ColumnDef as TSColumnDef,\n Row as TSRow,\n RowSelectionState as TSRowSelectionState,\n SortDirection as TSSortDirection,\n Table as TSTable,\n useReactTable,\n VisibilityState,\n} from '@tanstack/react-table';\n\nimport DataTableViewOptions from '@/components/advanced/data-table/data-table-column-toggle.component';\nimport DataTablePagination from '@/components/advanced/data-table/data-table-pagination.component';\nimport { Button } from '@/components/shadcn-ui/button';\nimport {\n Table,\n TableBody,\n TableCell,\n TableHead,\n TableHeader,\n TableRow,\n} from '@/components/shadcn-ui/table';\n\nexport type ColumnDef = TSColumnDef;\nexport type RowContents = TSRow;\nexport type TableContents = TSTable;\nexport type SortDirection = TSSortDirection;\nexport type RowSelectionState = TSRowSelectionState;\n\ninterface DataTableProps {\n columns: ColumnDef[];\n data: TData[];\n enablePagination?: boolean;\n showPaginationControls?: boolean;\n showColumnVisibilityControls?: boolean;\n stickyHeader?: boolean;\n onRowClickHandler?: (row: RowContents, table: TableContents) => void;\n}\n\n/**\n * Feature-rich table component that infuses our basic shadcn-based Table component with features\n * from TanStack's React Table library\n */\nfunction DataTable({\n columns,\n data,\n enablePagination = false,\n showPaginationControls = false,\n showColumnVisibilityControls = false,\n stickyHeader = false,\n onRowClickHandler = () => {},\n}: DataTableProps) {\n const [sorting, setSorting] = useState([]);\n const [columnFilters, setColumnFilters] = useState([]);\n const [columnVisibility, setColumnVisibility] = useState({});\n const [rowSelection, setRowSelection] = useState({});\n\n const table = useReactTable({\n data,\n columns,\n getCoreRowModel: getCoreRowModel(),\n ...(enablePagination && { getPaginationRowModel: getPaginationRowModel() }),\n onSortingChange: setSorting,\n getSortedRowModel: getSortedRowModel(),\n onColumnFiltersChange: setColumnFilters,\n getFilteredRowModel: getFilteredRowModel(),\n onColumnVisibilityChange: setColumnVisibility,\n onRowSelectionChange: setRowSelection,\n state: {\n sorting,\n columnFilters,\n columnVisibility,\n rowSelection,\n },\n });\n\n return (\n
    \n {showColumnVisibilityControls && }\n \n \n {table.getHeaderGroups().map((headerGroup) => (\n \n {headerGroup.headers.map((header) => {\n return (\n \n {header.isPlaceholder\n ? undefined\n : flexRender(header.column.columnDef.header, header.getContext())}\n \n );\n })}\n \n ))}\n \n \n {table.getRowModel().rows?.length ? (\n table.getRowModel().rows.map((row) => (\n onRowClickHandler(row, table)}\n key={row.id}\n data-state={row.getIsSelected() && 'selected'}\n >\n {row.getVisibleCells().map((cell) => (\n \n {flexRender(cell.column.columnDef.cell, cell.getContext())}\n \n ))}\n \n ))\n ) : (\n \n \n No results.\n \n \n )}\n \n
    \n {enablePagination && (\n
    \n table.previousPage()}\n disabled={!table.getCanPreviousPage()}\n >\n Previous\n \n table.nextPage()}\n disabled={!table.getCanNextPage()}\n >\n Next\n \n
    \n )}\n {enablePagination && showPaginationControls && }\n
    \n );\n}\n\nexport default DataTable;\n","import {\n Table,\n TableBody,\n TableCell,\n TableHead,\n TableHeader,\n TableRow,\n} from '@/components/shadcn-ui/table';\nimport { Canon } from '@sillsdev/scripture';\nimport { deepEqual, LanguageStrings, ScriptureReference } from 'platform-bible-utils';\nimport { useMemo } from 'react';\nimport { InventoryItemOccurrence } from './inventory-utils';\n\n/** Props for the OccurrencesTable component */\ntype OccurrencesTableProps = {\n /** Data that contains scriptures references and snippets of scripture */\n occurrenceData: InventoryItemOccurrence[];\n /** Callback function that is executed when the scripture reference is changed */\n setScriptureReference: (scriptureReference: ScriptureReference) => void;\n /**\n * Object with all localized strings that the OccurrencesTable needs to work well across multiple\n * languages\n */\n localizedStrings: LanguageStrings;\n};\n\n/**\n * Table that shows occurrences of specified inventory item(s). The first column shows the related\n * scripture reference. The second column shows the snippet of scripture that contains the specified\n * inventory item\n */\nfunction OccurrencesTable({\n occurrenceData,\n setScriptureReference,\n localizedStrings,\n}: OccurrencesTableProps) {\n const referenceHeaderText =\n localizedStrings['%webView_inventory_occurrences_table_header_reference%'];\n const occurrenceHeaderText =\n localizedStrings['%webView_inventory_occurrences_table_header_occurrence%'];\n\n const occurrences: InventoryItemOccurrence[] = useMemo(() => {\n const uniqueOccurrences: InventoryItemOccurrence[] = [];\n\n occurrenceData.forEach((occurrence) => {\n if (!uniqueOccurrences.some((uniqueOccurrence) => deepEqual(uniqueOccurrence, occurrence))) {\n uniqueOccurrences.push(occurrence);\n }\n });\n\n return uniqueOccurrences;\n }, [occurrenceData]);\n\n return (\n \n \n \n {referenceHeaderText}\n {occurrenceHeaderText}\n \n \n \n {occurrences.length > 0 &&\n occurrences.map((occurrence) => (\n {\n setScriptureReference(occurrence.reference);\n }}\n >\n {`${Canon.bookNumberToEnglishName(occurrence.reference.bookNum)} ${occurrence.reference.chapterNum}:${occurrence.reference.verseNum}`}\n {occurrence.text}\n \n ))}\n \n
    \n );\n}\n\nexport default OccurrencesTable;\n","import React from 'react';\nimport * as CheckboxPrimitive from '@radix-ui/react-checkbox';\nimport { Check } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Checkbox = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n \n \n));\nCheckbox.displayName = CheckboxPrimitive.Root.displayName;\n\nexport default Checkbox;\n","import { Canon } from '@sillsdev/scripture';\nimport { ScriptureReference } from 'platform-bible-utils';\n\n/* #region Types */\n\n/**\n * Status of items that appear in inventories. 'approved' and 'unapproved' items are defined in the\n * project's `Settings.xml`. All other items are defined as 'unknown'\n */\nexport type Status = 'approved' | 'unapproved' | 'unknown';\n\n/** Occurrence of item in inventory. Primarily used by table that shows occurrences */\nexport type InventoryItemOccurrence = {\n /** Reference to scripture where the item appears */\n reference: ScriptureReference;\n /** Snippet of scripture that contains the occurrence */\n text: string;\n};\n\n/** Data structure that contains all information on an item that is shown in an inventory */\nexport type InventoryTableData = {\n /**\n * The item (e.g. a character in the characters inventory, a marker in the marker inventory) In\n * most cases the array will only have one element. In case of additional items (e.g. the\n * preceding marker in the markers check), the primary item should be stored in the first index.\n * To show additional items in the inventory, make sure to configure the `additionalItemsLabels`\n * prop for the Inventory component\n */\n items: string[];\n /** The number of times this item occurs in the selected scope */\n count: number;\n /** The status of this item (see documentation for `Status` type for more information) */\n status: Status;\n /** Occurrences of this item in the scripture text for the selected scope */\n occurrences: InventoryItemOccurrence[];\n};\n\n/* #endregion */\n\n/* #region Functions */\n\n/**\n * Splits USFM string into shorter line-like segments\n *\n * @param text A single (likely very large) USFM string\n * @returns An array containing the input text, split into shorter segments\n */\nexport const getLinesFromUSFM = (text: string) => {\n // Splits on (CR)LF, CR, \\v, \\c and \\id\n return text.split(/(?:\\r?\\n|\\r)|(?=(?:\\\\(?:v|c|id)))/g);\n};\n\n/**\n * Extracts chapter or verse number from USFM strings that start with a \\c or \\v marker\n *\n * @param text USFM string that is expected to start with \\c or \\v marker\n * @returns Chapter or verse number if one is found. Else returns 0.\n */\nexport const getNumberFromUSFM = (text: string): number | undefined => {\n // Captures all digits that follow \\v or \\c markers followed by whitespace located at the start of a string\n const regex = /^\\\\[vc]\\s+(\\d+)/;\n const match = text.match(regex);\n\n if (match) {\n return +match[1];\n }\n return undefined;\n};\n\n/**\n * Gets book ID from USFM string that starts with the \\id marker, and returns book number for it\n *\n * @param text USFM string that is expected to start with \\id marker\n * @returns Book number corresponding to the \\id marker in the input text. Returns 0 if no marker is\n * found or the marker is not valid\n */\nexport const getBookNumFromId = (text: string): number => {\n // Captures all digits that follow an \\id marker followed by whitespace located at the start of a string\n const match = text.match(/^\\\\id\\s+([A-Za-z]+)/);\n if (match) {\n return Canon.bookIdToNumber(match[1]);\n }\n return 0;\n};\n\n/**\n * Gets the status for an item, typically used in the Inventory component\n *\n * @param item The item for which the status is being requested\n * @param approvedItems Array of approved items, typically as defined in `Settings.xml`\n * @param unapprovedItems Array of unapproved items, typically as defined in `Settings.xml`\n * @returns The status for the specified item\n */\nexport const getStatusForItem = (\n item: string,\n approvedItems: string[],\n unapprovedItems: string[],\n): Status => {\n if (unapprovedItems.includes(item)) return 'unapproved';\n if (approvedItems.includes(item)) return 'approved';\n return 'unknown';\n};\n\n/* #endregion */\n","import React from 'react';\nimport * as TogglePrimitive from '@radix-ui/react-toggle';\nimport { cva, type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst toggleVariants = cva(\n 'pr-twp tw-inline-flex tw-items-center tw-justify-center tw-rounded-md tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-colors hover:tw-bg-muted hover:tw-text-muted-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50 data-[state=on]:tw-bg-accent data-[state=on]:tw-text-accent-foreground',\n {\n variants: {\n variant: {\n default: 'tw-bg-transparent',\n outline:\n 'tw-border tw-border-input tw-bg-transparent hover:tw-bg-accent hover:tw-text-accent-foreground',\n },\n size: {\n default: 'tw-h-10 tw-px-3',\n sm: 'tw-h-9 tw-px-2.5',\n lg: 'tw-h-11 tw-px-5',\n },\n },\n defaultVariants: {\n variant: 'default',\n size: 'default',\n },\n },\n);\n\nconst Toggle = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef & VariantProps\n>(({ className, variant, size, ...props }, ref) => (\n \n));\n\nToggle.displayName = TogglePrimitive.Root.displayName;\n\nexport { Toggle, toggleVariants };\n","import React from 'react';\nimport * as ToggleGroupPrimitive from '@radix-ui/react-toggle-group';\nimport { type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { toggleVariants } from '@/components/shadcn-ui/toggle';\n\nconst ToggleGroupContext = React.createContext>({\n size: 'default',\n variant: 'default',\n});\n\nconst ToggleGroup = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef &\n VariantProps\n>(({ className, variant, size, children, ...props }, ref) => (\n \n \n {children}\n \n \n));\n\nToggleGroup.displayName = ToggleGroupPrimitive.Root.displayName;\n\nconst ToggleGroupItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef &\n VariantProps\n>(({ className, children, variant, size, ...props }, ref) => {\n const context = React.useContext(ToggleGroupContext);\n\n return (\n \n {children}\n \n );\n});\n\nToggleGroupItem.displayName = ToggleGroupPrimitive.Item.displayName;\n\nexport { ToggleGroup, ToggleGroupItem };\n","import { ColumnDef, SortDirection } from '@/components/advanced/data-table/data-table.component';\nimport { Button } from '@/components/shadcn-ui/button';\nimport { ToggleGroup, ToggleGroupItem } from '@/components/shadcn-ui/toggle-group';\nimport {\n ArrowDownIcon,\n ArrowUpDownIcon,\n ArrowUpIcon,\n CircleCheckIcon,\n CircleHelpIcon,\n CircleXIcon,\n} from 'lucide-react';\nimport { ReactNode } from 'react';\nimport { InventoryTableData, Status } from './inventory-utils';\n\n/**\n * Gets an icon that indicates the current sorting direction based on the provided input\n *\n * @param sortDirection Sorting direction. Can be ascending ('asc'), descending ('desc') or false (\n * i.e. not sorted)\n * @returns The appropriate sorting icon for the provided sorting direction\n */\nconst getSortingIcon = (sortDirection: false | SortDirection): ReactNode => {\n if (sortDirection === 'asc') {\n return ;\n }\n if (sortDirection === 'desc') {\n return ;\n }\n return ;\n};\n\n/**\n * Function that creates the item column for inventories\n *\n * @param itemLabel Localized label for the item column (e.g. 'Character', 'Repeated Word', etc.)\n * @returns Column that shows the inventory items. Should be used with the DataTable component\n */\nexport const inventoryItemColumn = (itemLabel: string): ColumnDef => {\n return {\n accessorKey: 'item',\n accessorFn: (row: InventoryTableData) => row.items[0],\n header: ({ column }) => (\n \n ),\n };\n};\n\n/**\n * Function that creates the additional item columns for inventories\n *\n * @param additionalItemLabel Localized label for the additional item column (e.g. 'Preceding\n * Marker')\n * @param additionalItemIndex Index that locates the desired item in the items array of the\n * inventory\n * @returns Column that shows additional inventory items. Should be used with the DataTable\n * component\n */\nexport const inventoryAdditionalItemColumn = (\n additionalItemLabel: string,\n additionalItemIndex: number,\n): ColumnDef => {\n return {\n accessorKey: `item${additionalItemIndex}`,\n accessorFn: (row: InventoryTableData) => row.items[additionalItemIndex],\n header: ({ column }) => (\n \n ),\n };\n};\n\n/**\n * Function that creates the count column for inventories. Should be used with the DataTable\n * component.\n *\n * @param itemLabel Localized label for the count column\n * @returns Column that shows the number of occurrences of the related inventory items\n */\nexport const inventoryCountColumn = (countLabel: string): ColumnDef => {\n return {\n accessorKey: 'count',\n header: ({ column }) => (\n
    \n \n
    \n ),\n cell: ({ row }) =>
    {row.getValue('count')}
    ,\n };\n};\n\n/**\n * Function that updates project settings when status for item(s) changes\n *\n * @param changedItems Array of items for which the status is being updated\n * @param newStatus The status that the items are being given\n * @param approvedItems Array of currently approved items\n * @param onApprovedItemsChange Callback function that stores the updated list of approved items\n * @param unapprovedItems Array of currently unapproved items\n * @param onUnapprovedItemsChange Callback function that stores the updated list of unapproved items\n */\nconst statusChangeHandler = (\n changedItems: string[],\n newStatus: Status,\n approvedItems: string[],\n onApprovedItemsChange: (items: string[]) => void,\n unapprovedItems: string[],\n onUnapprovedItemsChange: (items: string[]) => void,\n) => {\n let newApprovedItems: string[] = [...approvedItems];\n changedItems.forEach((item) => {\n if (newStatus === 'approved') {\n if (!newApprovedItems.includes(item)) {\n newApprovedItems.push(item);\n }\n } else {\n newApprovedItems = newApprovedItems.filter((validItem) => validItem !== item);\n }\n });\n onApprovedItemsChange(newApprovedItems);\n\n let newUnapprovedItems: string[] = [...unapprovedItems];\n changedItems.forEach((item) => {\n if (newStatus === 'unapproved') {\n if (!newUnapprovedItems.includes(item)) {\n newUnapprovedItems.push(item);\n }\n } else {\n newUnapprovedItems = newUnapprovedItems.filter((unapprovedItem) => unapprovedItem !== item);\n }\n });\n onUnapprovedItemsChange(newUnapprovedItems);\n};\n\n/**\n * Function that creates the status column for inventories. Should be used with the DataTable\n * component.\n *\n * @param statusLabel Localized label for the status column\n * @param approvedItems Array of approved items, typically as defined in `Settings.xml`\n * @param onApprovedItemsChange Callback function that stores the updated list of approved items\n * @param unapprovedItems Array of unapproved items, typically as defined in `Settings.xml`\n * @param onUnapprovedItemsChange Callback function that stores the updated list of unapproved items\n * @returns Column that shows the status buttons for the related inventory item. The button for the\n * current status of the item is selected\n */\nexport const inventoryStatusColumn = (\n statusLabel: string,\n approvedItems: string[],\n onApprovedItemsChange: (items: string[]) => void,\n unapprovedItems: string[],\n onUnapprovedItemsChange: (items: string[]) => void,\n): ColumnDef => {\n return {\n accessorKey: 'status',\n header: ({ column }) => {\n return (\n
    \n \n
    \n );\n },\n cell: ({ row }) => {\n const status: Status = row.getValue('status');\n const item: string = row.getValue('item');\n return (\n \n \n statusChangeHandler(\n [item],\n 'approved',\n approvedItems,\n onApprovedItemsChange,\n unapprovedItems,\n onUnapprovedItemsChange,\n )\n }\n value=\"approved\"\n >\n \n \n \n statusChangeHandler(\n [item],\n 'unapproved',\n approvedItems,\n onApprovedItemsChange,\n unapprovedItems,\n onUnapprovedItemsChange,\n )\n }\n value=\"unapproved\"\n >\n \n \n \n statusChangeHandler(\n [item],\n 'unknown',\n approvedItems,\n onApprovedItemsChange,\n unapprovedItems,\n onUnapprovedItemsChange,\n )\n }\n value=\"unknown\"\n >\n \n \n \n );\n },\n };\n};\n","import DataTable, {\n ColumnDef,\n RowContents,\n RowSelectionState,\n TableContents,\n} from '@/components/advanced/data-table/data-table.component';\nimport OccurrencesTable from '@/components/advanced/inventory/occurrences-table.component';\nimport Checkbox from '@/components/shadcn-ui/checkbox';\nimport { Input } from '@/components/shadcn-ui/input';\nimport { Label } from '@/components/shadcn-ui/label';\nimport {\n Select,\n SelectContent,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\nimport {\n deepEqual,\n LocalizedStringValue,\n ScriptureReference,\n substring,\n} from 'platform-bible-utils';\nimport { useEffect, useMemo, useState } from 'react';\nimport {\n getBookNumFromId,\n getLinesFromUSFM,\n getNumberFromUSFM,\n getStatusForItem,\n InventoryItemOccurrence,\n InventoryTableData,\n Status,\n} from './inventory-utils';\nimport { inventoryAdditionalItemColumn } from './inventory-columns';\n\n/**\n * Object containing all keys used for localization in this component. If you're using this\n * component in an extension, you can pass it into the useLocalizedStrings hook to easily obtain the\n * localized strings and pass them into the localizedStrings prop of this component\n */\nexport const INVENTORY_STRING_KEYS = Object.freeze([\n '%webView_inventory_all%',\n '%webView_inventory_approved%',\n '%webView_inventory_unapproved%',\n '%webView_inventory_unknown%',\n '%webView_inventory_scope_currentBook%',\n '%webView_inventory_scope_chapter%',\n '%webView_inventory_scope_verse%',\n '%webView_inventory_filter_text%',\n '%webView_inventory_show_additional_items%',\n '%webView_inventory_occurrences_table_header_reference%',\n '%webView_inventory_occurrences_table_header_occurrence%',\n] as const);\n\nexport type InventoryLocalizedStrings = {\n [localizedInventoryKey in (typeof INVENTORY_STRING_KEYS)[number]]?: LocalizedStringValue;\n};\n\n/** Scope of scripture that the inventory can operate on */\nexport type Scope = 'book' | 'chapter' | 'verse';\n\n/** Status values that the status filter can select from */\ntype StatusFilter = Status | 'all';\n\n/** Text labels for the inventory columns and the control components of additional inventory items */\ntype AdditionalItemsLabels = {\n checkboxText?: string;\n tableHeaders?: string[];\n};\n\n/**\n * Filters data that is shown in the DataTable section of the Inventory\n *\n * @param itemData All inventory items and their related information\n * @param statusFilter Allows filtering by status (i.e. show all items, or only items that are\n * 'approved', 'unapproved' or 'unknown')\n * @param textFilter Allows filtering by text. All items that include the filter text will be\n * selected.\n * @returns Array of items and their related information that are matched by the specified filters\n */\nconst filterItemData = (\n itemData: InventoryTableData[],\n statusFilter: StatusFilter,\n textFilter: string,\n): InventoryTableData[] => {\n let filteredItemData: InventoryTableData[] = itemData;\n\n if (statusFilter !== 'all') {\n filteredItemData = filteredItemData.filter(\n (item) =>\n (statusFilter === 'approved' && item.status === 'approved') ||\n (statusFilter === 'unapproved' && item.status === 'unapproved') ||\n (statusFilter === 'unknown' && item.status === 'unknown'),\n );\n }\n\n if (textFilter !== '')\n filteredItemData = filteredItemData.filter((item) => item.items[0].includes(textFilter));\n\n return filteredItemData;\n};\n\n/**\n * Turns array of strings into array of inventory items, along with their count and status\n *\n * @param text The source scripture text that is searched for inventory items\n * @param scriptureRef The scripture reference that the application is currently set to\n * @param approvedItems Array of approved items, typically as defined in `Settings.xml`\n * @param unapprovedItems Array of unapproved items, typically as defined in `Settings.xml`\n * @param itemRegex Regular expression that describes what items this Inventory should extract from\n * the provided scripture text\n * @returns Array of inventory items, along with their count and status\n */\nconst createTableData = (\n text: string | undefined,\n scriptureRef: ScriptureReference,\n approvedItems: string[],\n unapprovedItems: string[],\n itemRegex: RegExp,\n): InventoryTableData[] => {\n if (!text) return [];\n\n const tableData: InventoryTableData[] = [];\n\n let currentBook: number | undefined = scriptureRef.bookNum;\n let currentChapter: number | undefined = scriptureRef.chapterNum;\n let currentVerse: number | undefined = scriptureRef.verseNum;\n\n const lines = getLinesFromUSFM(text);\n\n lines.forEach((line: string) => {\n if (line.startsWith('\\\\id')) {\n currentBook = getBookNumFromId(line);\n currentChapter = 0;\n currentVerse = 0;\n }\n if (line.startsWith('\\\\c')) {\n currentChapter = getNumberFromUSFM(line);\n currentVerse = 0;\n }\n if (line.startsWith('\\\\v')) {\n currentVerse = getNumberFromUSFM(line);\n if (currentChapter === 0) {\n currentChapter = scriptureRef.chapterNum;\n }\n }\n\n let match: RegExpExecArray | undefined = itemRegex.exec(line) ?? undefined;\n while (match) {\n const items: string[] = [];\n match.forEach((item) => items.push(item));\n const itemIndex = match.index;\n const existingItem = tableData.find((tableEntry) => deepEqual(tableEntry.items, items));\n const newReference: InventoryItemOccurrence = {\n reference: {\n bookNum: currentBook !== undefined ? currentBook : -1,\n chapterNum: currentChapter !== undefined ? currentChapter : -1,\n verseNum: currentVerse !== undefined ? currentVerse : -1,\n },\n text: substring(line, Math.max(0, itemIndex - 25), Math.min(itemIndex + 25, line.length)),\n };\n if (existingItem) {\n existingItem.count += 1;\n existingItem.occurrences.push(newReference);\n } else {\n const newItem: InventoryTableData = {\n items,\n count: 1,\n status: getStatusForItem(items[0], approvedItems, unapprovedItems),\n occurrences: [newReference],\n };\n tableData.push(newItem);\n }\n\n match = itemRegex.exec(line) ?? undefined;\n }\n });\n\n return tableData;\n};\n\n/**\n * Gets the localized value for the provided key\n *\n * @param strings Object containing localized string\n * @param key Key for a localized string\n * @returns The localized value for the provided key, if available. Returns the key if no localized\n * value is available\n */\nconst localizeString = (\n strings: InventoryLocalizedStrings,\n key: keyof InventoryLocalizedStrings,\n) => {\n return strings[key] ?? key;\n};\n\n/** Props for the Inventory component */\ntype InventoryProps = {\n /** The scripture reference that the application is currently set to */\n scriptureReference: ScriptureReference;\n /** Callback function that is executed when the scripture reference is changed */\n setScriptureReference: (scriptureReference: ScriptureReference) => void;\n /**\n * Object with all localized strings that the Inventory needs to work well across multiple\n * languages. When using this component with Platform.Bible, you can import\n * `INVENTORY_STRING_KEYS` from this library, pass it in to the Platform's localization hook, and\n * pass the localized keys that are returned by the hook into this prop.\n */\n localizedStrings: InventoryLocalizedStrings;\n /**\n * The logic that finds the desired items in the source text. This can either be a Regular\n * expression that captures one or multiple items (preferred), or a custom function that builds\n * and return an InventoryDataTable[] manually. Note: In case the logic captures more than one\n * item (i.e. InventoryTableData.items has a length greater than 1), you must provide text labels\n * for the related columns and control elements to show by setting the `additionalItemsLabels`\n * prop\n */\n extractItems:\n | RegExp\n | ((\n text: string | undefined,\n scriptureRef: ScriptureReference,\n approvedItems: string[],\n unapprovedItems: string[],\n ) => InventoryTableData[]);\n /**\n * Text labels for control elements and additional column headers in case your Inventory has more\n * than one item to show (e.g. The 'Preceding Marker' in the Markers Inventory)\n */\n additionalItemsLabels?: AdditionalItemsLabels;\n /** Array of approved items, typically as defined in `Settings.xml` */\n approvedItems: string[];\n /** Array of unapproved items, typically as defined in `Settings.xml` */\n unapprovedItems: string[];\n /** The source scripture text that is searched for in inventory items */\n text: string | undefined;\n /** Scope of scripture that the inventory will operate on */\n scope: Scope;\n /** Callback function that is executed when the scope is changed from the Inventory */\n onScopeChange: (scope: Scope) => void;\n /**\n * Column definitions for the Inventory data table. The most commonly used column definitions are\n * pre-configured for your convenience and can be imported (e.g. inventoryItemColumn,\n * inventoryAdditionalItemColumn inventoryCountColumn, and inventoryStatusColumn). If you need any\n * other columns you can add these yourself\n */\n columns: ColumnDef[];\n};\n\n/** Inventory component that is used to view and control the status of provided project settings */\nexport default function Inventory({\n scriptureReference,\n setScriptureReference,\n localizedStrings,\n extractItems,\n additionalItemsLabels,\n approvedItems,\n unapprovedItems,\n text,\n scope,\n onScopeChange,\n columns,\n}: InventoryProps) {\n const allItemsText = localizeString(localizedStrings, '%webView_inventory_all%');\n const approvedItemsText = localizeString(localizedStrings, '%webView_inventory_approved%');\n const unapprovedItemsText = localizeString(localizedStrings, '%webView_inventory_unapproved%');\n const unknownItemsText = localizeString(localizedStrings, '%webView_inventory_unknown%');\n const scopeBookText = localizeString(localizedStrings, '%webView_inventory_scope_currentBook%');\n const scopeChapterText = localizeString(localizedStrings, '%webView_inventory_scope_chapter%');\n const scopeVerseText = localizeString(localizedStrings, '%webView_inventory_scope_verse%');\n const filterText = localizeString(localizedStrings, '%webView_inventory_filter_text%');\n const showAdditionalItemsText = localizeString(\n localizedStrings,\n '%webView_inventory_show_additional_items%',\n );\n\n const [showAdditionalItems, setShowAdditionalItems] = useState(false);\n const [statusFilter, setStatusFilter] = useState('all');\n const [textFilter, setTextFilter] = useState('');\n const [selectedItem, setSelectedItem] = useState([]);\n\n const tableData: InventoryTableData[] = useMemo(() => {\n if (!text) return [];\n if (extractItems instanceof RegExp)\n return createTableData(\n text,\n scriptureReference,\n approvedItems,\n unapprovedItems,\n extractItems,\n );\n return extractItems(text, scriptureReference, approvedItems, unapprovedItems);\n }, [text, extractItems, scriptureReference, approvedItems, unapprovedItems]);\n\n const reducedTableData: InventoryTableData[] = useMemo(() => {\n if (showAdditionalItems) return tableData;\n\n const newTableData: InventoryTableData[] = [];\n\n tableData.forEach((tableEntry) => {\n const firstItem = tableEntry.items[0];\n\n const existingEntry = newTableData.find(\n (newTableEntry) => newTableEntry.items[0] === firstItem,\n );\n\n if (existingEntry) {\n existingEntry.count += tableEntry.count;\n existingEntry.occurrences = existingEntry.occurrences.concat(tableEntry.occurrences);\n } else {\n newTableData.push({\n items: [firstItem],\n count: tableEntry.count,\n occurrences: tableEntry.occurrences,\n status: tableEntry.status,\n });\n }\n });\n\n return newTableData;\n }, [showAdditionalItems, tableData]);\n\n const filteredTableData: InventoryTableData[] = useMemo(() => {\n return filterItemData(reducedTableData, statusFilter, textFilter);\n }, [reducedTableData, statusFilter, textFilter]);\n\n const allColumns: ColumnDef[] = useMemo(() => {\n if (!showAdditionalItems) return columns;\n\n const numberOfAdditionalItems = additionalItemsLabels?.tableHeaders?.length;\n if (!numberOfAdditionalItems) return columns;\n\n const additionalColumns: ColumnDef[] = [];\n\n for (let index = 0; index < numberOfAdditionalItems; index++) {\n additionalColumns.push(\n inventoryAdditionalItemColumn(\n additionalItemsLabels?.tableHeaders?.[index] || 'Additional Item',\n index + 1,\n ),\n );\n }\n\n return [...additionalColumns, ...columns];\n }, [additionalItemsLabels?.tableHeaders, columns, showAdditionalItems]);\n\n useEffect(() => {\n setSelectedItem([]);\n }, [filteredTableData]);\n\n const rowClickHandler = (\n row: RowContents,\n table: TableContents,\n ) => {\n table.setRowSelection(() => {\n const newSelection: RowSelectionState = {};\n newSelection[row.index] = true;\n return newSelection;\n });\n\n setSelectedItem(row.original.items);\n };\n\n const handleScopeChange = (value: string) => {\n if (value === 'book' || value === 'chapter' || value === 'verse') {\n onScopeChange(value);\n } else {\n throw new Error(`Invalid scope value: ${value}`);\n }\n };\n\n const handleStatusFilterChange = (value: string) => {\n if (value === 'all' || value === 'approved' || value === 'unapproved' || value === 'unknown') {\n setStatusFilter(value);\n } else {\n throw new Error(`Invalid status filter value: ${value}`);\n }\n };\n\n const occurrenceData: InventoryItemOccurrence[] = useMemo(() => {\n if (reducedTableData.length === 0 || selectedItem.length === 0) return [];\n const occurrence = reducedTableData.filter((tableEntry: InventoryTableData) => {\n return deepEqual(\n showAdditionalItems ? tableEntry.items : [tableEntry.items[0]],\n selectedItem,\n );\n });\n if (occurrence.length > 1) throw new Error('Selected item is not unique');\n return occurrence[0].occurrences;\n }, [selectedItem, showAdditionalItems, reducedTableData]);\n\n return (\n
    \n
    \n handleStatusFilterChange(value)}\n defaultValue={statusFilter}\n >\n \n \n \n \n {allItemsText}\n {approvedItemsText}\n {unapprovedItemsText}\n {unknownItemsText}\n \n \n \n {\n setTextFilter(event.target.value);\n }}\n />\n {additionalItemsLabels && (\n
    \n {\n setSelectedItem([]);\n setShowAdditionalItems(checked);\n }}\n />\n \n
    \n )}\n
    \n
    \n \n
    \n {occurrenceData.length > 0 && (\n
    \n \n
    \n )}\n
    \n );\n}\n","import { Input } from '@/components/shadcn-ui/input';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { useState } from 'react';\n\n/** Props for the SearchBar component. */\nexport type SearchBarProps = {\n className?: string;\n /**\n * Callback fired to handle the search query when button pressed\n *\n * @param searchQuery\n */\n onSearch: (searchQuery: string) => void;\n\n /** Optional string that appears in the search bar without a search string */\n placeholder?: string;\n\n /** Optional boolean to set the input base to full width */\n isFullWidth?: boolean;\n};\n\nexport default function SearchBar({\n className,\n onSearch,\n placeholder,\n isFullWidth,\n}: SearchBarProps) {\n const [searchQuery, setSearchQuery] = useState('');\n\n const handleInputChange = (searchString: string) => {\n setSearchQuery(searchString);\n onSearch(searchString);\n };\n\n return (\n handleInputChange(e.target.value)}\n />\n );\n}\n","// adapted from: https://github.com/shadcn-ui/ui/discussions/752\n\n'use client';\n\nimport { TabsContentProps, TabsListProps, TabsTriggerProps } from '@/components/shadcn-ui/tabs';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport * as TabsPrimitive from '@radix-ui/react-tabs';\nimport React from 'react';\n\nexport type VerticalTabsProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport type LeftTabsTriggerProps = TabsTriggerProps & {\n value: string;\n ref?: React.Ref;\n};\n\nexport const VerticalTabs = React.forwardRef<\n React.ElementRef,\n VerticalTabsProps\n>(({ className, ...props }, ref) => (\n \n));\n\nVerticalTabs.displayName = TabsPrimitive.List.displayName;\n\nexport const VerticalTabsList = React.forwardRef<\n React.ElementRef,\n TabsListProps\n>(({ className, ...props }, ref) => (\n \n));\nVerticalTabsList.displayName = TabsPrimitive.List.displayName;\n\nexport const VerticalTabsTrigger = React.forwardRef<\n React.ElementRef,\n LeftTabsTriggerProps\n>(({ className, ...props }, ref) => (\n \n));\n\nexport const VerticalTabsContent = React.forwardRef<\n React.ElementRef,\n TabsContentProps\n>(({ className, ...props }, ref) => (\n \n));\nVerticalTabsContent.displayName = TabsPrimitive.Content.displayName;\n","import SearchBar from '@/components/basics/search-bar.component';\nimport {\n VerticalTabs,\n VerticalTabsContent,\n VerticalTabsList,\n VerticalTabsTrigger,\n} from '@/components/basics/tabs-vertical';\nimport { ReactNode } from 'react';\n\nexport type TabKeyValueContent = {\n key: string;\n value: string;\n content: ReactNode;\n};\n\nexport type TabNavigationContentSearchProps = {\n /** List of values and keys for each tab this component should provide */\n tabList: TabKeyValueContent[];\n\n /** Handler to run when the value of the search bar changes */\n onSearch: (searchQuery: string) => void;\n\n /** Optional placeholder for the search bar */\n searchPlaceholder?: string;\n\n /** Optional title to include in the header */\n headerTitle?: string;\n\n /** Optional flag to make the search bar appear full width */\n isSearchBarFullWidth?: boolean;\n\n /** Text direction ltr or rtl */\n direction?: 'ltr' | 'rtl';\n};\n\nexport default function TabNavigationContentSearch({\n tabList,\n onSearch,\n searchPlaceholder,\n headerTitle,\n isSearchBarFullWidth = false,\n direction = 'ltr',\n}: TabNavigationContentSearchProps) {\n return (\n
    \n
    \n {headerTitle ?

    {headerTitle}

    : ''}\n \n
    \n \n \n {tabList.map((tab) => (\n \n {tab.value}\n \n ))}\n \n {tabList.map((tab) => (\n \n {tab.content}\n \n ))}\n \n
    \n );\n}\n","import React from 'react';\nimport * as SeparatorPrimitive from '@radix-ui/react-separator';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Separator = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, orientation = 'horizontal', decorative = true, ...props }, ref) => (\n \n));\nSeparator.displayName = SeparatorPrimitive.Root.displayName;\n\nexport { Separator };\n","import React from 'react';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nfunction Skeleton({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\n\nexport { Skeleton };\n","import React from 'react';\nimport * as TooltipPrimitive from '@radix-ui/react-tooltip';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst TooltipProvider = TooltipPrimitive.Provider;\n\nconst Tooltip = TooltipPrimitive.Root;\n\nconst TooltipTrigger = TooltipPrimitive.Trigger;\n\nconst TooltipContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, sideOffset = 4, ...props }, ref) => (\n \n));\nTooltipContent.displayName = TooltipPrimitive.Content.displayName;\n\nexport { Tooltip, TooltipTrigger, TooltipContent, TooltipProvider };\n","import React from 'react';\nimport { Slot } from '@radix-ui/react-slot';\nimport { VariantProps, cva } from 'class-variance-authority';\nimport { PanelLeft } from 'lucide-react';\n\nimport { Button } from '@/components/shadcn-ui/button';\nimport { Input } from '@/components/shadcn-ui/input';\nimport { Separator } from '@/components/shadcn-ui/separator';\nimport { Skeleton } from '@/components/shadcn-ui/skeleton';\nimport {\n Tooltip,\n TooltipContent,\n TooltipProvider,\n TooltipTrigger,\n} from '@/components/shadcn-ui/tooltip';\nimport { cn } from '@/utils/shadcn-ui.util';\n\n/**\n * Changes from the original code from Shadcn- Removed uses of useIsMobile, Sheet, and SheetContent.\n * Also removed the parts setting COOKIES.\n */\n\nconst SIDEBAR_WIDTH = '16rem';\nconst SIDEBAR_WIDTH_ICON = '3rem';\nconst SIDEBAR_KEYBOARD_SHORTCUT = 'b';\n\ntype SidebarContextProps = {\n state: 'expanded' | 'collapsed';\n open: boolean;\n setOpen: (open: boolean) => void;\n toggleSidebar: () => void;\n};\n\nconst SidebarContext = React.createContext(undefined);\n\nfunction useSidebar() {\n const context = React.useContext(SidebarContext);\n if (!context) {\n throw new Error('useSidebar must be used within a SidebarProvider.');\n }\n\n return context;\n}\n\nconst SidebarProvider = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & {\n defaultOpen?: boolean;\n open?: boolean;\n onOpenChange?: (open: boolean) => void;\n }\n>(\n (\n {\n defaultOpen = true,\n open: openProp,\n onOpenChange: setOpenProp,\n className,\n style,\n children,\n ...props\n },\n ref,\n ) => {\n // This is the internal state of the sidebar.\n // We use openProp and setOpenProp for control from outside the component.\n const [_open, _setOpen] = React.useState(defaultOpen);\n const isOpen = openProp ?? _open;\n const setOpen = React.useCallback(\n (value: boolean | ((value: boolean) => boolean)) => {\n const openState = typeof value === 'function' ? value(isOpen) : value;\n if (setOpenProp) {\n setOpenProp(openState);\n } else {\n _setOpen(openState);\n }\n },\n [setOpenProp, isOpen],\n );\n\n // Helper to toggle the sidebar.\n const toggleSidebar = React.useCallback(() => {\n return setOpen((open) => !open);\n }, [setOpen]);\n\n // Adds a keyboard shortcut to toggle the sidebar.\n React.useEffect(() => {\n const handleKeyDown = (event: KeyboardEvent) => {\n if (event.key === SIDEBAR_KEYBOARD_SHORTCUT && (event.metaKey || event.ctrlKey)) {\n event.preventDefault();\n toggleSidebar();\n }\n };\n\n window.addEventListener('keydown', handleKeyDown);\n return () => window.removeEventListener('keydown', handleKeyDown);\n }, [toggleSidebar]);\n\n // We add a state so that we can do data-state=\"expanded\" or \"collapsed\".\n // This makes it easier to style the sidebar with Tailwind classes.\n const state = isOpen ? 'expanded' : 'collapsed';\n\n const contextValue = React.useMemo(\n () => ({\n state,\n open: isOpen,\n setOpen,\n toggleSidebar,\n }),\n [state, isOpen, setOpen, toggleSidebar],\n );\n\n return (\n \n \n \n {children}\n
    \n \n \n );\n },\n);\nSidebarProvider.displayName = 'SidebarProvider';\n\nconst Sidebar = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & {\n side?: 'left' | 'right';\n variant?: 'sidebar' | 'floating' | 'inset';\n collapsible?: 'offcanvas' | 'icon' | 'none';\n }\n>(\n (\n {\n side = 'left',\n variant = 'sidebar',\n collapsible = 'offcanvas',\n className,\n children,\n ...props\n },\n ref,\n ) => {\n const { state } = useSidebar();\n\n if (collapsible === 'none') {\n return (\n \n {children}\n
    \n );\n }\n\n return (\n \n {/* This is what handles the sidebar gap on desktop */}\n \n \n \n {children}\n
    \n
    \n
    \n );\n },\n);\nSidebar.displayName = 'Sidebar';\n\nconst SidebarTrigger = React.forwardRef<\n React.ElementRef,\n React.ComponentProps\n>(({ className, onClick, ...props }, ref) => {\n const { toggleSidebar } = useSidebar();\n\n return (\n {\n onClick?.(event);\n toggleSidebar();\n }}\n {...props}\n >\n \n Toggle Sidebar\n \n );\n});\nSidebarTrigger.displayName = 'SidebarTrigger';\n\nconst SidebarRail = React.forwardRef>(\n ({ className, ...props }, ref) => {\n const { toggleSidebar } = useSidebar();\n\n return (\n \n );\n },\n);\nSidebarRail.displayName = 'SidebarRail';\n\nconst SidebarInset = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarInset.displayName = 'SidebarInset';\n\nconst SidebarInput = React.forwardRef<\n React.ElementRef,\n React.ComponentProps\n>(({ className, ...props }, ref) => {\n return (\n \n );\n});\nSidebarInput.displayName = 'SidebarInput';\n\nconst SidebarHeader = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarHeader.displayName = 'SidebarHeader';\n\nconst SidebarFooter = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarFooter.displayName = 'SidebarFooter';\n\nconst SidebarSeparator = React.forwardRef<\n React.ElementRef,\n React.ComponentProps\n>(({ className, ...props }, ref) => {\n return (\n \n );\n});\nSidebarSeparator.displayName = 'SidebarSeparator';\n\nconst SidebarContent = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarContent.displayName = 'SidebarContent';\n\nconst SidebarGroup = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarGroup.displayName = 'SidebarGroup';\n\nconst SidebarGroupLabel = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & { asChild?: boolean }\n>(({ className, asChild = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'div';\n\n return (\n svg]:tw-size-4 [&>svg]:tw-shrink-0',\n 'group-data-[collapsible=icon]:tw--mt-8 group-data-[collapsible=icon]:tw-opacity-0',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarGroupLabel.displayName = 'SidebarGroupLabel';\n\nconst SidebarGroupAction = React.forwardRef<\n HTMLButtonElement,\n React.ComponentProps<'button'> & { asChild?: boolean }\n>(({ className, asChild = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'button';\n\n return (\n svg]:tw-size-4 [&>svg]:tw-shrink-0',\n // Increases the hit area of the button on mobile.\n 'after:tw-absolute after:tw--inset-2 after:md:tw-hidden',\n 'group-data-[collapsible=icon]:tw-hidden',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarGroupAction.displayName = 'SidebarGroupAction';\n\nconst SidebarGroupContent = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarGroupContent.displayName = 'SidebarGroupContent';\n\nconst SidebarMenu = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenu.displayName = 'SidebarMenu';\n\nconst SidebarMenuItem = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenuItem.displayName = 'SidebarMenuItem';\n\nconst sidebarMenuButtonVariants = cva(\n // Removed data-[active=true]:tw-bg-sidebar-accent\n 'tw-peer/menu-button tw-flex tw-w-full tw-items-center tw-gap-2 tw-overflow-hidden tw-rounded-md tw-p-2 tw-text-left tw-text-sm tw-outline-none tw-ring-sidebar-ring tw-transition-[width,height,padding] hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground focus-visible:tw-ring-2 active:tw-bg-sidebar-accent active:tw-text-sidebar-accent-foreground disabled:tw-pointer-events-none disabled:tw-opacity-50 tw-group-has-[[data-sidebar=menu-action]]/menu-item:pr-8 aria-disabled:tw-pointer-events-none aria-disabled:tw-opacity-50 data-[active=true]:tw-font-medium data-[active=true]:tw-text-sidebar-accent-foreground data-[state=open]:hover:tw-bg-sidebar-accent data-[state=open]:hover:tw-text-sidebar-accent-foreground group-data-[collapsible=icon]:tw-!size-8 group-data-[collapsible=icon]:tw-!p-2 [&>span:last-child]:tw-truncate [&>svg]:tw-size-4 [&>svg]:tw-shrink-0',\n {\n variants: {\n variant: {\n default: 'hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground',\n outline:\n 'tw-bg-background tw-shadow-[0_0_0_1px_hsl(var(--sidebar-border))] hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground hover:tw-shadow-[0_0_0_1px_hsl(var(--sidebar-accent))]',\n },\n size: {\n default: 'tw-h-8 tw-text-sm',\n sm: 'tw-h-7 tw-text-xs',\n lg: 'tw-h-12 tw-text-sm group-data-[collapsible=icon]:tw-!p-0',\n },\n },\n defaultVariants: {\n variant: 'default',\n size: 'default',\n },\n },\n);\n\nconst SidebarMenuButton = React.forwardRef<\n HTMLButtonElement,\n React.ComponentProps<'button'> & {\n asChild?: boolean;\n isActive?: boolean;\n tooltip?: string | React.ComponentProps;\n } & VariantProps\n>(\n (\n {\n asChild = false,\n isActive = false,\n variant = 'default',\n size = 'default',\n tooltip,\n className,\n ...props\n },\n ref,\n ) => {\n const Comp = asChild ? Slot : 'button';\n const { state } = useSidebar();\n\n const button = (\n \n );\n\n if (!tooltip) {\n return button;\n }\n\n if (typeof tooltip === 'string') {\n // eslint-disable-next-line no-param-reassign\n tooltip = {\n children: tooltip,\n };\n }\n\n return (\n \n {button}\n \n );\n },\n);\nSidebarMenuButton.displayName = 'SidebarMenuButton';\n\nconst SidebarMenuAction = React.forwardRef<\n HTMLButtonElement,\n React.ComponentProps<'button'> & {\n asChild?: boolean;\n showOnHover?: boolean;\n }\n>(({ className, asChild = false, showOnHover = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'button';\n\n return (\n svg]:tw-size-4 [&>svg]:tw-shrink-0',\n // Increases the hit area of the button on mobile.\n 'after:tw-absolute after:tw--inset-2 after:md:tw-hidden',\n 'tw-peer-data-[size=sm]/menu-button:top-1',\n 'tw-peer-data-[size=default]/menu-button:top-1.5',\n 'tw-peer-data-[size=lg]/menu-button:top-2.5',\n 'group-data-[collapsible=icon]:tw-hidden',\n showOnHover &&\n 'tw-group-focus-within/menu-item:opacity-100 tw-group-hover/menu-item:opacity-100 tw-peer-data-[active=true]/menu-button:text-sidebar-accent-foreground data-[state=open]:tw-opacity-100 md:tw-opacity-0',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarMenuAction.displayName = 'SidebarMenuAction';\n\nconst SidebarMenuBadge = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenuBadge.displayName = 'SidebarMenuBadge';\n\nconst SidebarMenuSkeleton = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & {\n showIcon?: boolean;\n }\n>(({ className, showIcon = false, ...props }, ref) => {\n // Random width between 50 to 90%.\n const width = React.useMemo(() => {\n return `${Math.floor(Math.random() * 40) + 50}%`;\n }, []);\n\n return (\n \n {showIcon && (\n \n )}\n \n
    \n );\n});\nSidebarMenuSkeleton.displayName = 'SidebarMenuSkeleton';\n\nconst SidebarMenuSub = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenuSub.displayName = 'SidebarMenuSub';\n\nconst SidebarMenuSubItem = React.forwardRef>(\n ({ ...props }, ref) =>
  • ,\n);\nSidebarMenuSubItem.displayName = 'SidebarMenuSubItem';\n\nconst SidebarMenuSubButton = React.forwardRef<\n HTMLAnchorElement,\n React.ComponentProps<'a'> & {\n asChild?: boolean;\n size?: 'sm' | 'md';\n isActive?: boolean;\n }\n>(({ asChild = false, size = 'md', isActive, className, ...props }, ref) => {\n const Comp = asChild ? Slot : 'a';\n\n return (\n span:last-child]:tw-truncate [&>svg]:tw-size-4 [&>svg]:tw-shrink-0 [&>svg]:tw-text-sidebar-accent-foreground',\n 'data-[active=true]:tw-bg-sidebar-accent data-[active=true]:tw-text-sidebar-accent-foreground',\n size === 'sm' && 'tw-text-xs',\n size === 'md' && 'tw-text-sm',\n 'group-data-[collapsible=icon]:tw-hidden',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarMenuSubButton.displayName = 'SidebarMenuSubButton';\n\nexport {\n Sidebar,\n SidebarContent,\n SidebarFooter,\n SidebarGroup,\n SidebarGroupAction,\n SidebarGroupContent,\n SidebarGroupLabel,\n SidebarHeader,\n SidebarInput,\n SidebarInset,\n SidebarMenu,\n SidebarMenuAction,\n SidebarMenuBadge,\n SidebarMenuButton,\n SidebarMenuItem,\n SidebarMenuSkeleton,\n SidebarMenuSub,\n SidebarMenuSubButton,\n SidebarMenuSubItem,\n SidebarProvider,\n SidebarRail,\n SidebarSeparator,\n SidebarTrigger,\n useSidebar,\n};\n","import ComboBox, { ComboBoxOption } from '@/components/basics/combo-box.component';\nimport {\n Sidebar,\n SidebarContent,\n SidebarGroup,\n SidebarGroupLabel,\n SidebarGroupContent,\n SidebarMenu,\n SidebarMenuItem,\n SidebarMenuButton,\n} from '@/components/shadcn-ui/sidebar';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { useCallback } from 'react';\n\nexport type SelectedSettingsSidebarItem = {\n label: string;\n projectId?: string;\n};\n\nexport type ProjectInfo = { projectId: string; projectName: string };\n\nexport type SettingsSidebarProps = {\n /** Optional id for testing */\n id?: string;\n\n /** Extension labels from contribution */\n extensionLabels: string[];\n\n /** Project names and ids */\n projectOptions: ProjectInfo[];\n\n /** Handler for selecting a sidebar item */\n handleSelectSidebarItem: (key: string, projectId?: string) => void;\n\n /** The current selected value in the sidebar */\n selectedSidebarItem: SelectedSettingsSidebarItem;\n\n /** Label for the group of extensions setting groups */\n extensionsSidebarGroupLabel: string;\n\n /** Label for the group of projects settings */\n projectsSidebarGroupLabel: string;\n\n /** Placeholder text for the button */\n buttonPlaceholderText: string;\n};\n\nexport default function SettingsSidebar({\n id,\n extensionLabels,\n projectOptions,\n handleSelectSidebarItem,\n selectedSidebarItem,\n extensionsSidebarGroupLabel,\n projectsSidebarGroupLabel,\n buttonPlaceholderText,\n}: SettingsSidebarProps) {\n const handleSelectItem = useCallback(\n (item: string, projectId?: string) => {\n handleSelectSidebarItem(item, projectId);\n },\n [handleSelectSidebarItem],\n );\n\n const getProjectNameFromProjectId = useCallback(\n (projectId: string) => {\n const project = projectOptions.find((option) => option.projectId === projectId);\n return project ? project.projectName : projectId;\n },\n [projectOptions],\n );\n\n const getIsActive: (label: string) => boolean = useCallback(\n (label: string) => !selectedSidebarItem.projectId && label === selectedSidebarItem.label,\n [selectedSidebarItem],\n );\n\n return (\n \n \n \n \n {extensionsSidebarGroupLabel}\n \n \n \n {extensionLabels.map((label) => (\n \n handleSelectItem(label)}\n isActive={getIsActive(label)}\n >\n {label}\n \n \n ))}\n \n \n \n \n \n {projectsSidebarGroupLabel}\n \n \n option.projectId)}\n getOptionLabel={(projectId: ComboBoxOption) => {\n // This function expects a ComboBoxOption, but we know it is a string\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n return getProjectNameFromProjectId(projectId as string);\n }}\n buttonPlaceholder={buttonPlaceholderText}\n onChange={(projectId: string) => {\n const selectedProjectName = getProjectNameFromProjectId(projectId);\n handleSelectItem(selectedProjectName, projectId);\n }}\n value={selectedSidebarItem?.projectId ?? undefined}\n />\n \n \n \n \n );\n}\n","import { SidebarInset, SidebarProvider } from '@/components/shadcn-ui/sidebar';\nimport { PropsWithChildren } from 'react';\nimport SearchBar from '@/components/basics/search-bar.component';\nimport SettingsSidebar, { SettingsSidebarProps } from './settings-sidebar.component';\n\nexport type SettingsSidebarContentSearchProps = SettingsSidebarProps &\n PropsWithChildren & {\n /** Optional id for testing */\n id?: string;\n\n /** Handler to run when the value of the search bar changes */\n onSearch: (searchQuery: string) => void;\n };\n\nexport default function SettingsSidebarContentSearch({\n id,\n extensionLabels,\n projectOptions,\n children,\n handleSelectSidebarItem,\n selectedSidebarItem,\n onSearch,\n extensionsSidebarGroupLabel,\n projectsSidebarGroupLabel,\n buttonPlaceholderText,\n}: SettingsSidebarContentSearchProps) {\n return (\n
    \n
    \n \n
    \n \n \n {children}\n \n
    \n );\n}\n","import { Button } from '@/components/shadcn-ui/button';\nimport {\n Select,\n SelectContent,\n SelectGroup,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\nimport {\n Table,\n TableBody,\n TableCell,\n TableHead,\n TableHeader,\n TableRow,\n} from '@/components/shadcn-ui/table';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Canon } from '@sillsdev/scripture';\nimport {\n Cell,\n ColumnDef,\n flexRender,\n getCoreRowModel,\n getExpandedRowModel,\n getGroupedRowModel,\n getSortedRowModel,\n GroupingState,\n Row,\n RowSelectionState,\n SortingState,\n useReactTable,\n} from '@tanstack/react-table';\nimport '@/components/advanced/scripture-results-viewer/scripture-results-viewer.component.css';\nimport {\n compareScrRefs,\n formatScrRef,\n ScriptureSelection,\n scrRefToBBBCCCVVV,\n} from 'platform-bible-utils';\nimport { MouseEvent, useEffect, useMemo, useState } from 'react';\nimport { ChevronDown, ChevronLeft, ChevronRight } from 'lucide-react';\n\n/**\n * Information (e.g., a checking error or some other type of \"transient\" annotation) about something\n * noteworthy at a specific place in an instance of the Scriptures.\n */\nexport type ScriptureItemDetail = ScriptureSelection & {\n /**\n * Text of the error, note, etc. In the future, we might want to support something more than just\n * text so that a JSX element could be provided with a link or some other controls related to the\n * issue being reported.\n */\n detail: string;\n};\n\n/**\n * A uniquely identifiable source of results that can be displayed in the ScriptureResultsViewer.\n * Generally, the source will be a particular Scripture check, but there may be other types of\n * sources.\n */\nexport type ResultsSource = {\n /**\n * Uniquely identifies the source.\n *\n * @type {string}\n */\n id: string;\n\n /**\n * Name (potentially localized) of the source, suitable for display in the UI.\n *\n * @type {string}\n */\n displayName: string;\n};\n\nexport type ScriptureSrcItemDetail = ScriptureItemDetail & {\n /** Source/type of detail. Can be used for grouping. */\n source: ResultsSource;\n};\n\n/**\n * Represents a set of results keyed by Scripture reference. Generally, the source will be a\n * particular Scripture check, but this type also allows for other types of uniquely identifiable\n * sources.\n */\nexport type ResultsSet = {\n /**\n * The backing source associated with this set of results.\n *\n * @type {ResultsSource}\n */\n source: ResultsSource;\n\n /**\n * Array of Scripture item details (messages keyed by Scripture reference).\n *\n * @type {ScriptureItemDetail[]}\n */\n data: ScriptureItemDetail[];\n};\n\nconst scrBookColId = 'scrBook';\nconst scrRefColId = 'scrRef';\nconst typeColId = 'source';\nconst detailsColId = 'details';\n\nconst defaultScrRefColumnName = 'Scripture Reference';\nconst defaultScrBookGroupName = 'Scripture Book';\nconst defaultTypeColumnName = 'Type';\nconst defaultDetailsColumnName = 'Details';\n\nexport type ScriptureResultsViewerColumnInfo = {\n /** Optional header to display for the Reference column. Default value: 'Scripture Reference'. */\n scriptureReferenceColumnName?: string;\n\n /** Optional text to display to refer to the Scripture book group. Default value: 'Scripture Book'. */\n scriptureBookGroupName?: string;\n\n /** Optional header to display for the Type column. Default value: 'Type'. */\n typeColumnName?: string;\n\n /** Optional header to display for the Details column. Default value: 'Details' */\n detailsColumnName?: string;\n};\n\nexport type ScriptureResultsViewerProps = ScriptureResultsViewerColumnInfo & {\n /** Groups of ScriptureItemDetail objects from particular sources (e.g., Scripture checks) */\n sources: ResultsSet[];\n\n /** Flag indicating whether to display column headers. Default is false. */\n showColumnHeaders?: boolean;\n\n /** Flag indicating whether to display source column. Default is false. */\n showSourceColumn?: boolean;\n\n /** Callback function to notify when a row is selected */\n onRowSelected?: (selectedRow: ScriptureSrcItemDetail | undefined) => void;\n\n /** Text direction ltr or rtl */\n direction?: 'ltr' | 'rtl';\n};\n\nfunction getColumns(\n colInfo?: ScriptureResultsViewerColumnInfo,\n showSourceColumn?: boolean,\n): ColumnDef[] {\n const showSrcCol = showSourceColumn ?? false;\n return [\n {\n accessorFn: (row) =>\n `${Canon.bookNumberToId(row.start.bookNum)} ${row.start.chapterNum}:${row.start.verseNum}`,\n id: scrBookColId,\n header: colInfo?.scriptureReferenceColumnName ?? defaultScrRefColumnName,\n cell: (info) => {\n const row = info.row.original;\n if (info.row.getIsGrouped()) {\n return Canon.bookNumberToEnglishName(row.start.bookNum);\n }\n return info.row.groupingColumnId === scrBookColId ? formatScrRef(row.start) : undefined;\n },\n getGroupingValue: (row) => row.start.bookNum,\n sortingFn: (a, b) => {\n return compareScrRefs(a.original.start, b.original.start);\n },\n enableGrouping: true,\n },\n {\n accessorFn: (row) => formatScrRef(row.start),\n id: scrRefColId,\n header: undefined,\n cell: (info) => {\n const row = info.row.original;\n return info.row.getIsGrouped() ? undefined : formatScrRef(row.start);\n },\n sortingFn: (a, b) => {\n return compareScrRefs(a.original.start, b.original.start);\n },\n enableGrouping: false,\n },\n {\n accessorFn: (row) => row.source.displayName,\n id: typeColId,\n header: showSrcCol ? (colInfo?.typeColumnName ?? defaultTypeColumnName) : undefined,\n cell: (info) => (showSrcCol || info.row.getIsGrouped() ? info.getValue() : undefined),\n getGroupingValue: (row) => row.source.id,\n sortingFn: (a, b) =>\n a.original.source.displayName.localeCompare(b.original.source.displayName),\n enableGrouping: true,\n },\n {\n accessorFn: (row) => row.detail,\n id: detailsColId,\n header: colInfo?.detailsColumnName ?? defaultDetailsColumnName,\n cell: (info) => info.getValue(),\n enableGrouping: false,\n },\n ];\n}\n\nconst toRefOrRange = (scriptureSelection: ScriptureSelection) => {\n if (!('offset' in scriptureSelection.start))\n throw new Error('No offset available in range start');\n if (scriptureSelection.end && !('offset' in scriptureSelection.end))\n throw new Error('No offset available in range end');\n const { offset: offsetStart } = scriptureSelection.start;\n let offsetEnd: number = 0;\n if (scriptureSelection.end) ({ offset: offsetEnd } = scriptureSelection.end);\n if (\n !scriptureSelection.end ||\n compareScrRefs(scriptureSelection.start, scriptureSelection.end) === 0\n )\n return `${scrRefToBBBCCCVVV(scriptureSelection.start)}+${offsetStart}`;\n return `${scrRefToBBBCCCVVV(scriptureSelection.start)}+${offsetStart}-${scrRefToBBBCCCVVV(scriptureSelection.end)}+${offsetEnd}`;\n};\n\nconst getRowKey = (row: ScriptureSrcItemDetail) =>\n `${toRefOrRange({ start: row.start, end: row.end })} ${row.source.displayName} ${row.detail}`;\n\n/**\n * Component to display a combined list of detailed items from one or more sources, where the items\n * are keyed primarily by Scripture reference. This is particularly useful for displaying a list of\n * results from Scripture checks, but more generally could be used to display any \"results\" from any\n * source(s). The component allows for grouping by Scripture book, source, or both. By default, it\n * displays somewhat \"tree-like\" which allows it to be more horizontally compact and intuitive. But\n * it also has the option of displaying as a traditional table with column headings (with or without\n * the source column showing).\n */\nexport default function ScriptureResultsViewer({\n sources,\n showColumnHeaders = false,\n showSourceColumn = false,\n scriptureReferenceColumnName,\n scriptureBookGroupName,\n typeColumnName,\n detailsColumnName,\n onRowSelected,\n direction = 'ltr',\n}: ScriptureResultsViewerProps) {\n const [grouping, setGrouping] = useState([]);\n const [sorting, setSorting] = useState([{ id: scrBookColId, desc: false }]);\n const [rowSelection, setRowSelection] = useState({});\n\n const scriptureResults = useMemo(\n () =>\n sources.flatMap((source) => {\n return source.data.map((item) => ({\n ...item,\n source: source.source,\n }));\n }),\n [sources],\n );\n\n const columns = useMemo(\n () =>\n getColumns(\n {\n scriptureReferenceColumnName,\n typeColumnName,\n detailsColumnName,\n },\n showSourceColumn,\n ),\n [scriptureReferenceColumnName, typeColumnName, detailsColumnName, showSourceColumn],\n );\n\n useEffect(() => {\n // Ensure sorting is applied correctly when grouped by type\n if (grouping.includes(typeColId)) {\n setSorting([\n { id: typeColId, desc: false },\n { id: scrBookColId, desc: false },\n ]);\n } else {\n setSorting([{ id: scrBookColId, desc: false }]);\n }\n }, [grouping]);\n\n const table = useReactTable({\n data: scriptureResults,\n columns,\n state: {\n grouping,\n sorting,\n rowSelection,\n },\n onGroupingChange: setGrouping,\n onSortingChange: setSorting,\n onRowSelectionChange: setRowSelection,\n getExpandedRowModel: getExpandedRowModel(),\n getGroupedRowModel: getGroupedRowModel(),\n getCoreRowModel: getCoreRowModel(),\n getSortedRowModel: getSortedRowModel(),\n getRowId: getRowKey,\n autoResetExpanded: false,\n enableMultiRowSelection: false,\n enableSubRowSelection: false,\n });\n\n useEffect(() => {\n if (onRowSelected) {\n const selectedRows = table.getSelectedRowModel().rowsById;\n const keys = Object.keys(selectedRows);\n if (keys.length === 1) {\n const selectedRow = scriptureResults.find((row) => getRowKey(row) === keys[0]) || undefined;\n if (selectedRow) onRowSelected(selectedRow);\n }\n }\n }, [rowSelection, scriptureResults, onRowSelected, table]);\n\n // Define possible grouping options\n const scrBookGroupName = scriptureBookGroupName ?? defaultScrBookGroupName;\n const typeGroupName = typeColumnName ?? defaultTypeColumnName;\n\n const groupingOptions = [\n { label: 'No Grouping', value: [] },\n { label: `Group by ${scrBookGroupName}`, value: [scrBookColId] },\n { label: `Group by ${typeGroupName}`, value: [typeColId] },\n {\n label: `Group by ${scrBookGroupName} and ${typeGroupName}`,\n value: [scrBookColId, typeColId],\n },\n {\n label: `Group by ${typeGroupName} and ${scrBookGroupName}`,\n value: [typeColId, scrBookColId],\n },\n ];\n\n const handleSelectChange = (selectedGrouping: string) => {\n setGrouping(JSON.parse(selectedGrouping));\n };\n\n const handleRowClick = (row: Row, event: MouseEvent) => {\n if (!row.getIsGrouped() && !row.getIsSelected()) {\n row.getToggleSelectedHandler()(event);\n }\n };\n\n const getEvenOrOddBandingStyle = (row: Row, index: number) => {\n if (row.getIsGrouped()) return '';\n // UX has now said they don't think they want banding. I'm leaving in the code to\n // set even and odd styles, but there's nothing in the CSS to style them differently.\n // The \"even\" style used to also have tw-bg-neutral-300 (along with even) to create\n // a visual banding effect. That could be added back in if UX changes the decision.\n return cn('banded-row', index % 2 === 0 ? 'even' : 'odd');\n };\n\n const getIndent = (\n groupingState: GroupingState,\n row: Row,\n cell: Cell,\n ) => {\n if (groupingState?.length === 0 || row.depth < cell.column.getGroupedIndex()) return undefined;\n if (row.getIsGrouped()) {\n switch (row.depth) {\n case 1:\n return 'tw-ps-4';\n default:\n return undefined;\n }\n }\n switch (row.depth) {\n case 1:\n return 'tw-ps-8';\n case 2:\n return 'tw-ps-12';\n default:\n return undefined;\n }\n };\n\n return (\n
    \n {!showColumnHeaders && (\n {\n handleSelectChange(value);\n }}\n >\n \n \n \n \n \n {groupingOptions.map((option) => (\n \n {option.label}\n \n ))}\n \n \n \n )}\n \n {showColumnHeaders && (\n \n {table.getHeaderGroups().map((headerGroup) => (\n \n {headerGroup.headers\n .filter((h) => h.column.columnDef.header)\n .map((header) => (\n /* For sticky column headers to work, we probably need to change the default definition of the shadcn Table component. See https://github.com/shadcn-ui/ui/issues/1151 */\n \n {header.isPlaceholder ? undefined : (\n
    \n {header.column.getCanGroup() ? (\n \n {header.column.getIsGrouped() ? `🛑` : `👊 `}\n \n ) : undefined}{' '}\n {flexRender(header.column.columnDef.header, header.getContext())}\n
    \n )}\n
    \n ))}\n
    \n ))}\n
    \n )}\n \n {table.getRowModel().rows.map((row, rowIndex) => {\n return (\n handleRowClick(row, event)}\n >\n {row.getVisibleCells().map((cell) => {\n if (\n cell.getIsPlaceholder() ||\n (cell.column.columnDef.enableGrouping &&\n !cell.getIsGrouped() &&\n (cell.column.columnDef.id !== typeColId || !showSourceColumn))\n )\n return undefined;\n return (\n \n {(() => {\n if (cell.getIsGrouped()) {\n return (\n \n {row.getIsExpanded() && }\n {!row.getIsExpanded() &&\n (direction === 'ltr' ? : )}{' '}\n {flexRender(cell.column.columnDef.cell, cell.getContext())} (\n {row.subRows.length})\n \n );\n }\n\n // if (cell.getIsAggregated()) {\n // flexRender(\n // cell.column.columnDef.aggregatedCell ?? cell.column.columnDef.cell,\n // cell.getContext(),\n // );\n // }\n\n return flexRender(cell.column.columnDef.cell, cell.getContext());\n })()}\n \n );\n })}\n \n );\n })}\n \n
    \n
    \n );\n}\n","import {\n getLocalizeKeyForScrollGroupId,\n LanguageStrings,\n ScrollGroupId,\n} from 'platform-bible-utils';\nimport {\n Select,\n SelectContent,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\n\nconst DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS = {\n [getLocalizeKeyForScrollGroupId('undefined')]: 'Ø',\n [getLocalizeKeyForScrollGroupId(0)]: 'A',\n [getLocalizeKeyForScrollGroupId(1)]: 'B',\n [getLocalizeKeyForScrollGroupId(2)]: 'C',\n [getLocalizeKeyForScrollGroupId(3)]: 'D',\n [getLocalizeKeyForScrollGroupId(4)]: 'E',\n [getLocalizeKeyForScrollGroupId(5)]: 'F',\n [getLocalizeKeyForScrollGroupId(6)]: 'G',\n [getLocalizeKeyForScrollGroupId(7)]: 'H',\n [getLocalizeKeyForScrollGroupId(8)]: 'I',\n [getLocalizeKeyForScrollGroupId(9)]: 'J',\n [getLocalizeKeyForScrollGroupId(10)]: 'K',\n [getLocalizeKeyForScrollGroupId(11)]: 'L',\n [getLocalizeKeyForScrollGroupId(12)]: 'M',\n [getLocalizeKeyForScrollGroupId(13)]: 'N',\n [getLocalizeKeyForScrollGroupId(14)]: 'O',\n [getLocalizeKeyForScrollGroupId(15)]: 'P',\n [getLocalizeKeyForScrollGroupId(16)]: 'Q',\n [getLocalizeKeyForScrollGroupId(17)]: 'R',\n [getLocalizeKeyForScrollGroupId(18)]: 'S',\n [getLocalizeKeyForScrollGroupId(19)]: 'T',\n [getLocalizeKeyForScrollGroupId(20)]: 'U',\n [getLocalizeKeyForScrollGroupId(21)]: 'V',\n [getLocalizeKeyForScrollGroupId(22)]: 'W',\n [getLocalizeKeyForScrollGroupId(23)]: 'X',\n [getLocalizeKeyForScrollGroupId(24)]: 'Y',\n [getLocalizeKeyForScrollGroupId(25)]: 'Z',\n};\n\nexport type ScrollGroupSelectorProps = {\n /**\n * List of scroll group ids to show to the user. Either a {@link ScrollGroupId} or `undefined` for\n * no scroll group\n */\n availableScrollGroupIds: (ScrollGroupId | undefined)[];\n /** Currently selected scroll group id. `undefined` for no scroll group */\n scrollGroupId: ScrollGroupId | undefined;\n /** Callback function run when the user tries to change the scroll group id */\n onChangeScrollGroupId: (newScrollGroupId: ScrollGroupId | undefined) => void;\n /**\n * Localized strings to use for displaying scroll group ids. Must be an object whose keys are\n * `getLocalizeKeyForScrollGroupId(scrollGroupId)` for all scroll group ids (and `undefined` if\n * included) in {@link ScrollGroupSelectorProps.availableScrollGroupIds} and whose values are the\n * localized strings to use for those scroll group ids.\n *\n * Defaults to English localizations of English alphabet for scroll groups 0-25 (e.g. 0 is A) and\n * Ø for `undefined`. Will fill in any that are not provided with these English localizations.\n * Also, if any values match the keys, the English localization will be used. This is useful in\n * case you want to pass in a temporary version of the localized strings while your localized\n * strings load.\n *\n * @example\n *\n * ```typescript\n * const myScrollGroupIdLocalizedStrings = {\n * [getLocalizeKeyForScrollGroupId('undefined')]: 'Ø',\n * [getLocalizeKeyForScrollGroupId(0)]: 'A',\n * [getLocalizeKeyForScrollGroupId(1)]: 'B',\n * [getLocalizeKeyForScrollGroupId(2)]: 'C',\n * [getLocalizeKeyForScrollGroupId(3)]: 'D',\n * [getLocalizeKeyForScrollGroupId(4)]: 'E',\n * };\n * ```\n *\n * @example\n *\n * ```tsx\n * const availableScrollGroupIds = [undefined, 0, 1, 2, 3, 4];\n *\n * const localizeKeys = getLocalizeKeysForScrollGroupIds();\n *\n * const [localizedStrings] = useLocalizedStrings(localizeKeys);\n *\n * ...\n *\n * \n * ```\n */\n localizedStrings?: LanguageStrings;\n};\n\n/** Selector component for choosing a scroll group */\nexport default function ScrollGroupSelector({\n availableScrollGroupIds,\n scrollGroupId,\n onChangeScrollGroupId,\n localizedStrings = {},\n}: ScrollGroupSelectorProps) {\n const localizedStringsDefaulted = {\n ...DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS,\n ...Object.fromEntries(\n Object.entries(localizedStrings).map(\n ([localizedStringKey, localizedStringValue]: [string, string]) => [\n localizedStringKey,\n localizedStringKey === localizedStringValue &&\n localizedStringKey in DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS\n ? DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS[localizedStringKey]\n : localizedStringValue,\n ],\n ),\n ),\n };\n return (\n \n onChangeScrollGroupId(\n newScrollGroupString === 'undefined' ? undefined : parseInt(newScrollGroupString, 10),\n )\n }\n >\n \n \n \n \n {availableScrollGroupIds.map((scrollGroupOptionId) => (\n \n {localizedStringsDefaulted[getLocalizeKeyForScrollGroupId(scrollGroupOptionId)]}\n \n ))}\n \n \n );\n}\n","import { PropsWithChildren } from 'react';\nimport { Separator } from '@/components/shadcn-ui/separator';\n\n/** Props for the SettingsList component, currently just children */\ntype SettingsListProps = PropsWithChildren;\n\n/**\n * SettingsList component is a wrapper for list items. Rendered with a formatted div\n *\n * @param children To populate the list with\n * @returns Formatted div encompassing the children\n */\nexport function SettingsList({ children }: SettingsListProps) {\n return
    {children}
    ;\n}\n\n/** Props for SettingsListItem component */\ntype SettingsListItemProps = PropsWithChildren & {\n /** Primary text of the list item */\n primary: string;\n\n /** Optional text of the list item */\n secondary?: string | undefined;\n\n /** Optional boolean to display a message if the children aren't loaded yet. Defaults to false */\n isLoading?: boolean;\n\n /** Optional message to display if isLoading */\n loadingMessage?: string;\n};\n\n/**\n * SettingsListItem component is a common list item. Rendered with a formatted div\n *\n * @param primary Primary text of the list item\n * @param secondary Optional secondary text of the list item\n * @param isLoading Optional, to display a message if the action component isn't generated yet,\n * defaults to false\n * @param children The action component(s) to provide for this item\n * @param loadingMessage Optional, message to display if isLoading\n * @returns Formatted div encompassing the list item content\n */\nexport function SettingsListItem({\n primary,\n secondary,\n children,\n isLoading = false,\n loadingMessage,\n}: SettingsListItemProps) {\n return (\n
    \n
    \n

    {primary}

    \n

    \n {secondary}\n

    \n
    \n\n {isLoading ? (\n

    {loadingMessage}

    \n ) : (\n
    {children}
    \n )}\n
    \n );\n}\n\n/** Props for SettingsListHeader component */\ntype SettingsListHeaderProps = {\n /** The primary text of the list header */\n primary: string;\n\n /** Optional secondary text of the list header */\n secondary?: string | undefined;\n\n /** Optional boolean to include a separator underneath the secondary text. Defaults to false */\n includeSeparator?: boolean;\n};\n\n/**\n * SettingsListHeader component displays text above the list\n *\n * @param primary The primary text of the list header\n * @param secondary Optional secondary text of the list header\n * @param includeSeparator Optional boolean to include a separator underneath the secondary text.\n * Defaults to false\n * @returns Formatted div with list header content\n */\nexport function SettingsListHeader({\n primary,\n secondary,\n includeSeparator = false,\n}: SettingsListHeaderProps) {\n return (\n
    \n
    \n

    {primary}

    \n

    {secondary}

    \n
    \n {includeSeparator ? : ''}\n
    \n );\n}\n","import Checkbox from '@/components/shadcn-ui/checkbox';\nimport { Label } from '@/components/shadcn-ui/label';\n\nexport type ChecklistProps = {\n /** Optional string representing the id attribute of the Checklist */\n id?: string;\n /** Optional string representing CSS class name(s) for styling */\n className?: string;\n /** Array of strings representing the checkable items */\n listItems: string[];\n /** Array of strings representing the checked items */\n selectedListItems: string[];\n /**\n * Function that is called when a checkbox item is selected or deselected\n *\n * @param item The string description for this item\n * @param selected True if selected, false if not selected\n */\n handleSelectListItem: (item: string, selected: boolean) => void;\n\n /**\n * Optional function creates a label for a provided checkable item\n *\n * @param item The item for which a label is to be created\n * @returns A string representing the label text for the checkbox associated with that item\n */\n createLabel?: (item: string) => string;\n};\n\n/** Renders a list of checkboxes. Each checkbox corresponds to an item from the `listItems` array. */\nexport default function Checklist({\n id,\n className,\n listItems,\n selectedListItems,\n handleSelectListItem,\n createLabel,\n}: ChecklistProps) {\n return (\n
    \n {listItems.map((item) => (\n
    \n handleSelectListItem(item, value)}\n />\n \n
    \n ))}\n
    \n );\n}\n","function _interopRequireDefault(obj) {\n return obj && obj.__esModule ? obj : {\n \"default\": obj\n };\n}\nmodule.exports = _interopRequireDefault, module.exports.__esModule = true, module.exports[\"default\"] = module.exports;","export default function chainPropTypes(propType1, propType2) {\n if (process.env.NODE_ENV === 'production') {\n return () => null;\n }\n return function validate(...args) {\n return propType1(...args) || propType2(...args);\n };\n}","export default function _extends() {\n _extends = Object.assign ? Object.assign.bind() : function (target) {\n for (var i = 1; i < arguments.length; i++) {\n var source = arguments[i];\n for (var key in source) {\n if (Object.prototype.hasOwnProperty.call(source, key)) {\n target[key] = source[key];\n }\n }\n }\n return target;\n };\n return _extends.apply(this, arguments);\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\n// https://github.com/sindresorhus/is-plain-obj/blob/main/index.js\nexport function isPlainObject(item) {\n if (typeof item !== 'object' || item === null) {\n return false;\n }\n const prototype = Object.getPrototypeOf(item);\n return (prototype === null || prototype === Object.prototype || Object.getPrototypeOf(prototype) === null) && !(Symbol.toStringTag in item) && !(Symbol.iterator in item);\n}\nfunction deepClone(source) {\n if (!isPlainObject(source)) {\n return source;\n }\n const output = {};\n Object.keys(source).forEach(key => {\n output[key] = deepClone(source[key]);\n });\n return output;\n}\nexport default function deepmerge(target, source, options = {\n clone: true\n}) {\n const output = options.clone ? _extends({}, target) : target;\n if (isPlainObject(target) && isPlainObject(source)) {\n Object.keys(source).forEach(key => {\n // Avoid prototype pollution\n if (key === '__proto__') {\n return;\n }\n if (isPlainObject(source[key]) && key in target && isPlainObject(target[key])) {\n // Since `output` is a clone of `target` and we have narrowed `target` in this block we can cast to the same type.\n output[key] = deepmerge(target[key], source[key], options);\n } else if (options.clone) {\n output[key] = isPlainObject(source[key]) ? deepClone(source[key]) : source[key];\n } else {\n output[key] = source[key];\n }\n });\n }\n return output;\n}","/** @license React v16.13.1\n * react-is.production.min.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';var b=\"function\"===typeof Symbol&&Symbol.for,c=b?Symbol.for(\"react.element\"):60103,d=b?Symbol.for(\"react.portal\"):60106,e=b?Symbol.for(\"react.fragment\"):60107,f=b?Symbol.for(\"react.strict_mode\"):60108,g=b?Symbol.for(\"react.profiler\"):60114,h=b?Symbol.for(\"react.provider\"):60109,k=b?Symbol.for(\"react.context\"):60110,l=b?Symbol.for(\"react.async_mode\"):60111,m=b?Symbol.for(\"react.concurrent_mode\"):60111,n=b?Symbol.for(\"react.forward_ref\"):60112,p=b?Symbol.for(\"react.suspense\"):60113,q=b?\nSymbol.for(\"react.suspense_list\"):60120,r=b?Symbol.for(\"react.memo\"):60115,t=b?Symbol.for(\"react.lazy\"):60116,v=b?Symbol.for(\"react.block\"):60121,w=b?Symbol.for(\"react.fundamental\"):60117,x=b?Symbol.for(\"react.responder\"):60118,y=b?Symbol.for(\"react.scope\"):60119;\nfunction z(a){if(\"object\"===typeof a&&null!==a){var u=a.$$typeof;switch(u){case c:switch(a=a.type,a){case l:case m:case e:case g:case f:case p:return a;default:switch(a=a&&a.$$typeof,a){case k:case n:case t:case r:case h:return a;default:return u}}case d:return u}}}function A(a){return z(a)===m}exports.AsyncMode=l;exports.ConcurrentMode=m;exports.ContextConsumer=k;exports.ContextProvider=h;exports.Element=c;exports.ForwardRef=n;exports.Fragment=e;exports.Lazy=t;exports.Memo=r;exports.Portal=d;\nexports.Profiler=g;exports.StrictMode=f;exports.Suspense=p;exports.isAsyncMode=function(a){return A(a)||z(a)===l};exports.isConcurrentMode=A;exports.isContextConsumer=function(a){return z(a)===k};exports.isContextProvider=function(a){return z(a)===h};exports.isElement=function(a){return\"object\"===typeof a&&null!==a&&a.$$typeof===c};exports.isForwardRef=function(a){return z(a)===n};exports.isFragment=function(a){return z(a)===e};exports.isLazy=function(a){return z(a)===t};\nexports.isMemo=function(a){return z(a)===r};exports.isPortal=function(a){return z(a)===d};exports.isProfiler=function(a){return z(a)===g};exports.isStrictMode=function(a){return z(a)===f};exports.isSuspense=function(a){return z(a)===p};\nexports.isValidElementType=function(a){return\"string\"===typeof a||\"function\"===typeof a||a===e||a===m||a===g||a===f||a===p||a===q||\"object\"===typeof a&&null!==a&&(a.$$typeof===t||a.$$typeof===r||a.$$typeof===h||a.$$typeof===k||a.$$typeof===n||a.$$typeof===w||a.$$typeof===x||a.$$typeof===y||a.$$typeof===v)};exports.typeOf=z;\n","/** @license React v16.13.1\n * react-is.development.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\n\n\nif (process.env.NODE_ENV !== \"production\") {\n (function() {\n'use strict';\n\n// The Symbol used to tag the ReactElement-like types. If there is no native Symbol\n// nor polyfill, then a plain number is used for performance.\nvar hasSymbol = typeof Symbol === 'function' && Symbol.for;\nvar REACT_ELEMENT_TYPE = hasSymbol ? Symbol.for('react.element') : 0xeac7;\nvar REACT_PORTAL_TYPE = hasSymbol ? Symbol.for('react.portal') : 0xeaca;\nvar REACT_FRAGMENT_TYPE = hasSymbol ? Symbol.for('react.fragment') : 0xeacb;\nvar REACT_STRICT_MODE_TYPE = hasSymbol ? Symbol.for('react.strict_mode') : 0xeacc;\nvar REACT_PROFILER_TYPE = hasSymbol ? Symbol.for('react.profiler') : 0xead2;\nvar REACT_PROVIDER_TYPE = hasSymbol ? Symbol.for('react.provider') : 0xeacd;\nvar REACT_CONTEXT_TYPE = hasSymbol ? Symbol.for('react.context') : 0xeace; // TODO: We don't use AsyncMode or ConcurrentMode anymore. They were temporary\n// (unstable) APIs that have been removed. Can we remove the symbols?\n\nvar REACT_ASYNC_MODE_TYPE = hasSymbol ? Symbol.for('react.async_mode') : 0xeacf;\nvar REACT_CONCURRENT_MODE_TYPE = hasSymbol ? Symbol.for('react.concurrent_mode') : 0xeacf;\nvar REACT_FORWARD_REF_TYPE = hasSymbol ? Symbol.for('react.forward_ref') : 0xead0;\nvar REACT_SUSPENSE_TYPE = hasSymbol ? Symbol.for('react.suspense') : 0xead1;\nvar REACT_SUSPENSE_LIST_TYPE = hasSymbol ? Symbol.for('react.suspense_list') : 0xead8;\nvar REACT_MEMO_TYPE = hasSymbol ? Symbol.for('react.memo') : 0xead3;\nvar REACT_LAZY_TYPE = hasSymbol ? Symbol.for('react.lazy') : 0xead4;\nvar REACT_BLOCK_TYPE = hasSymbol ? Symbol.for('react.block') : 0xead9;\nvar REACT_FUNDAMENTAL_TYPE = hasSymbol ? Symbol.for('react.fundamental') : 0xead5;\nvar REACT_RESPONDER_TYPE = hasSymbol ? Symbol.for('react.responder') : 0xead6;\nvar REACT_SCOPE_TYPE = hasSymbol ? Symbol.for('react.scope') : 0xead7;\n\nfunction isValidElementType(type) {\n return typeof type === 'string' || typeof type === 'function' || // Note: its typeof might be other than 'symbol' or 'number' if it's a polyfill.\n type === REACT_FRAGMENT_TYPE || type === REACT_CONCURRENT_MODE_TYPE || type === REACT_PROFILER_TYPE || type === REACT_STRICT_MODE_TYPE || type === REACT_SUSPENSE_TYPE || type === REACT_SUSPENSE_LIST_TYPE || typeof type === 'object' && type !== null && (type.$$typeof === REACT_LAZY_TYPE || type.$$typeof === REACT_MEMO_TYPE || type.$$typeof === REACT_PROVIDER_TYPE || type.$$typeof === REACT_CONTEXT_TYPE || type.$$typeof === REACT_FORWARD_REF_TYPE || type.$$typeof === REACT_FUNDAMENTAL_TYPE || type.$$typeof === REACT_RESPONDER_TYPE || type.$$typeof === REACT_SCOPE_TYPE || type.$$typeof === REACT_BLOCK_TYPE);\n}\n\nfunction typeOf(object) {\n if (typeof object === 'object' && object !== null) {\n var $$typeof = object.$$typeof;\n\n switch ($$typeof) {\n case REACT_ELEMENT_TYPE:\n var type = object.type;\n\n switch (type) {\n case REACT_ASYNC_MODE_TYPE:\n case REACT_CONCURRENT_MODE_TYPE:\n case REACT_FRAGMENT_TYPE:\n case REACT_PROFILER_TYPE:\n case REACT_STRICT_MODE_TYPE:\n case REACT_SUSPENSE_TYPE:\n return type;\n\n default:\n var $$typeofType = type && type.$$typeof;\n\n switch ($$typeofType) {\n case REACT_CONTEXT_TYPE:\n case REACT_FORWARD_REF_TYPE:\n case REACT_LAZY_TYPE:\n case REACT_MEMO_TYPE:\n case REACT_PROVIDER_TYPE:\n return $$typeofType;\n\n default:\n return $$typeof;\n }\n\n }\n\n case REACT_PORTAL_TYPE:\n return $$typeof;\n }\n }\n\n return undefined;\n} // AsyncMode is deprecated along with isAsyncMode\n\nvar AsyncMode = REACT_ASYNC_MODE_TYPE;\nvar ConcurrentMode = REACT_CONCURRENT_MODE_TYPE;\nvar ContextConsumer = REACT_CONTEXT_TYPE;\nvar ContextProvider = REACT_PROVIDER_TYPE;\nvar Element = REACT_ELEMENT_TYPE;\nvar ForwardRef = REACT_FORWARD_REF_TYPE;\nvar Fragment = REACT_FRAGMENT_TYPE;\nvar Lazy = REACT_LAZY_TYPE;\nvar Memo = REACT_MEMO_TYPE;\nvar Portal = REACT_PORTAL_TYPE;\nvar Profiler = REACT_PROFILER_TYPE;\nvar StrictMode = REACT_STRICT_MODE_TYPE;\nvar Suspense = REACT_SUSPENSE_TYPE;\nvar hasWarnedAboutDeprecatedIsAsyncMode = false; // AsyncMode should be deprecated\n\nfunction isAsyncMode(object) {\n {\n if (!hasWarnedAboutDeprecatedIsAsyncMode) {\n hasWarnedAboutDeprecatedIsAsyncMode = true; // Using console['warn'] to evade Babel and ESLint\n\n console['warn']('The ReactIs.isAsyncMode() alias has been deprecated, ' + 'and will be removed in React 17+. Update your code to use ' + 'ReactIs.isConcurrentMode() instead. It has the exact same API.');\n }\n }\n\n return isConcurrentMode(object) || typeOf(object) === REACT_ASYNC_MODE_TYPE;\n}\nfunction isConcurrentMode(object) {\n return typeOf(object) === REACT_CONCURRENT_MODE_TYPE;\n}\nfunction isContextConsumer(object) {\n return typeOf(object) === REACT_CONTEXT_TYPE;\n}\nfunction isContextProvider(object) {\n return typeOf(object) === REACT_PROVIDER_TYPE;\n}\nfunction isElement(object) {\n return typeof object === 'object' && object !== null && object.$$typeof === REACT_ELEMENT_TYPE;\n}\nfunction isForwardRef(object) {\n return typeOf(object) === REACT_FORWARD_REF_TYPE;\n}\nfunction isFragment(object) {\n return typeOf(object) === REACT_FRAGMENT_TYPE;\n}\nfunction isLazy(object) {\n return typeOf(object) === REACT_LAZY_TYPE;\n}\nfunction isMemo(object) {\n return typeOf(object) === REACT_MEMO_TYPE;\n}\nfunction isPortal(object) {\n return typeOf(object) === REACT_PORTAL_TYPE;\n}\nfunction isProfiler(object) {\n return typeOf(object) === REACT_PROFILER_TYPE;\n}\nfunction isStrictMode(object) {\n return typeOf(object) === REACT_STRICT_MODE_TYPE;\n}\nfunction isSuspense(object) {\n return typeOf(object) === REACT_SUSPENSE_TYPE;\n}\n\nexports.AsyncMode = AsyncMode;\nexports.ConcurrentMode = ConcurrentMode;\nexports.ContextConsumer = ContextConsumer;\nexports.ContextProvider = ContextProvider;\nexports.Element = Element;\nexports.ForwardRef = ForwardRef;\nexports.Fragment = Fragment;\nexports.Lazy = Lazy;\nexports.Memo = Memo;\nexports.Portal = Portal;\nexports.Profiler = Profiler;\nexports.StrictMode = StrictMode;\nexports.Suspense = Suspense;\nexports.isAsyncMode = isAsyncMode;\nexports.isConcurrentMode = isConcurrentMode;\nexports.isContextConsumer = isContextConsumer;\nexports.isContextProvider = isContextProvider;\nexports.isElement = isElement;\nexports.isForwardRef = isForwardRef;\nexports.isFragment = isFragment;\nexports.isLazy = isLazy;\nexports.isMemo = isMemo;\nexports.isPortal = isPortal;\nexports.isProfiler = isProfiler;\nexports.isStrictMode = isStrictMode;\nexports.isSuspense = isSuspense;\nexports.isValidElementType = isValidElementType;\nexports.typeOf = typeOf;\n })();\n}\n","'use strict';\n\nif (process.env.NODE_ENV === 'production') {\n module.exports = require('./cjs/react-is.production.min.js');\n} else {\n module.exports = require('./cjs/react-is.development.js');\n}\n","/*\nobject-assign\n(c) Sindre Sorhus\n@license MIT\n*/\n\n'use strict';\n/* eslint-disable no-unused-vars */\nvar getOwnPropertySymbols = Object.getOwnPropertySymbols;\nvar hasOwnProperty = Object.prototype.hasOwnProperty;\nvar propIsEnumerable = Object.prototype.propertyIsEnumerable;\n\nfunction toObject(val) {\n\tif (val === null || val === undefined) {\n\t\tthrow new TypeError('Object.assign cannot be called with null or undefined');\n\t}\n\n\treturn Object(val);\n}\n\nfunction shouldUseNative() {\n\ttry {\n\t\tif (!Object.assign) {\n\t\t\treturn false;\n\t\t}\n\n\t\t// Detect buggy property enumeration order in older V8 versions.\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=4118\n\t\tvar test1 = new String('abc'); // eslint-disable-line no-new-wrappers\n\t\ttest1[5] = 'de';\n\t\tif (Object.getOwnPropertyNames(test1)[0] === '5') {\n\t\t\treturn false;\n\t\t}\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=3056\n\t\tvar test2 = {};\n\t\tfor (var i = 0; i < 10; i++) {\n\t\t\ttest2['_' + String.fromCharCode(i)] = i;\n\t\t}\n\t\tvar order2 = Object.getOwnPropertyNames(test2).map(function (n) {\n\t\t\treturn test2[n];\n\t\t});\n\t\tif (order2.join('') !== '0123456789') {\n\t\t\treturn false;\n\t\t}\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=3056\n\t\tvar test3 = {};\n\t\t'abcdefghijklmnopqrst'.split('').forEach(function (letter) {\n\t\t\ttest3[letter] = letter;\n\t\t});\n\t\tif (Object.keys(Object.assign({}, test3)).join('') !==\n\t\t\t\t'abcdefghijklmnopqrst') {\n\t\t\treturn false;\n\t\t}\n\n\t\treturn true;\n\t} catch (err) {\n\t\t// We don't expect any of the above to throw, but better to be safe.\n\t\treturn false;\n\t}\n}\n\nmodule.exports = shouldUseNative() ? Object.assign : function (target, source) {\n\tvar from;\n\tvar to = toObject(target);\n\tvar symbols;\n\n\tfor (var s = 1; s < arguments.length; s++) {\n\t\tfrom = Object(arguments[s]);\n\n\t\tfor (var key in from) {\n\t\t\tif (hasOwnProperty.call(from, key)) {\n\t\t\t\tto[key] = from[key];\n\t\t\t}\n\t\t}\n\n\t\tif (getOwnPropertySymbols) {\n\t\t\tsymbols = getOwnPropertySymbols(from);\n\t\t\tfor (var i = 0; i < symbols.length; i++) {\n\t\t\t\tif (propIsEnumerable.call(from, symbols[i])) {\n\t\t\t\t\tto[symbols[i]] = from[symbols[i]];\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\n\treturn to;\n};\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar ReactPropTypesSecret = 'SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED';\n\nmodule.exports = ReactPropTypesSecret;\n","module.exports = Function.call.bind(Object.prototype.hasOwnProperty);\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar printWarning = function() {};\n\nif (process.env.NODE_ENV !== 'production') {\n var ReactPropTypesSecret = require('./lib/ReactPropTypesSecret');\n var loggedTypeFailures = {};\n var has = require('./lib/has');\n\n printWarning = function(text) {\n var message = 'Warning: ' + text;\n if (typeof console !== 'undefined') {\n console.error(message);\n }\n try {\n // --- Welcome to debugging React ---\n // This error was thrown as a convenience so that you can use this stack\n // to find the callsite that caused this warning to fire.\n throw new Error(message);\n } catch (x) { /**/ }\n };\n}\n\n/**\n * Assert that the values match with the type specs.\n * Error messages are memorized and will only be shown once.\n *\n * @param {object} typeSpecs Map of name to a ReactPropType\n * @param {object} values Runtime values that need to be type-checked\n * @param {string} location e.g. \"prop\", \"context\", \"child context\"\n * @param {string} componentName Name of the component for error messages.\n * @param {?Function} getStack Returns the component stack.\n * @private\n */\nfunction checkPropTypes(typeSpecs, values, location, componentName, getStack) {\n if (process.env.NODE_ENV !== 'production') {\n for (var typeSpecName in typeSpecs) {\n if (has(typeSpecs, typeSpecName)) {\n var error;\n // Prop type validation may throw. In case they do, we don't want to\n // fail the render phase where it didn't fail before. So we log it.\n // After these have been cleaned up, we'll let them throw.\n try {\n // This is intentionally an invariant that gets caught. It's the same\n // behavior as without this statement except with a better message.\n if (typeof typeSpecs[typeSpecName] !== 'function') {\n var err = Error(\n (componentName || 'React class') + ': ' + location + ' type `' + typeSpecName + '` is invalid; ' +\n 'it must be a function, usually from the `prop-types` package, but received `' + typeof typeSpecs[typeSpecName] + '`.' +\n 'This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.'\n );\n err.name = 'Invariant Violation';\n throw err;\n }\n error = typeSpecs[typeSpecName](values, typeSpecName, componentName, location, null, ReactPropTypesSecret);\n } catch (ex) {\n error = ex;\n }\n if (error && !(error instanceof Error)) {\n printWarning(\n (componentName || 'React class') + ': type specification of ' +\n location + ' `' + typeSpecName + '` is invalid; the type checker ' +\n 'function must return `null` or an `Error` but returned a ' + typeof error + '. ' +\n 'You may have forgotten to pass an argument to the type checker ' +\n 'creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and ' +\n 'shape all require an argument).'\n );\n }\n if (error instanceof Error && !(error.message in loggedTypeFailures)) {\n // Only monitor this failure once because there tends to be a lot of the\n // same error.\n loggedTypeFailures[error.message] = true;\n\n var stack = getStack ? getStack() : '';\n\n printWarning(\n 'Failed ' + location + ' type: ' + error.message + (stack != null ? stack : '')\n );\n }\n }\n }\n }\n}\n\n/**\n * Resets warning cache when testing.\n *\n * @private\n */\ncheckPropTypes.resetWarningCache = function() {\n if (process.env.NODE_ENV !== 'production') {\n loggedTypeFailures = {};\n }\n}\n\nmodule.exports = checkPropTypes;\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar ReactIs = require('react-is');\nvar assign = require('object-assign');\n\nvar ReactPropTypesSecret = require('./lib/ReactPropTypesSecret');\nvar has = require('./lib/has');\nvar checkPropTypes = require('./checkPropTypes');\n\nvar printWarning = function() {};\n\nif (process.env.NODE_ENV !== 'production') {\n printWarning = function(text) {\n var message = 'Warning: ' + text;\n if (typeof console !== 'undefined') {\n console.error(message);\n }\n try {\n // --- Welcome to debugging React ---\n // This error was thrown as a convenience so that you can use this stack\n // to find the callsite that caused this warning to fire.\n throw new Error(message);\n } catch (x) {}\n };\n}\n\nfunction emptyFunctionThatReturnsNull() {\n return null;\n}\n\nmodule.exports = function(isValidElement, throwOnDirectAccess) {\n /* global Symbol */\n var ITERATOR_SYMBOL = typeof Symbol === 'function' && Symbol.iterator;\n var FAUX_ITERATOR_SYMBOL = '@@iterator'; // Before Symbol spec.\n\n /**\n * Returns the iterator method function contained on the iterable object.\n *\n * Be sure to invoke the function with the iterable as context:\n *\n * var iteratorFn = getIteratorFn(myIterable);\n * if (iteratorFn) {\n * var iterator = iteratorFn.call(myIterable);\n * ...\n * }\n *\n * @param {?object} maybeIterable\n * @return {?function}\n */\n function getIteratorFn(maybeIterable) {\n var iteratorFn = maybeIterable && (ITERATOR_SYMBOL && maybeIterable[ITERATOR_SYMBOL] || maybeIterable[FAUX_ITERATOR_SYMBOL]);\n if (typeof iteratorFn === 'function') {\n return iteratorFn;\n }\n }\n\n /**\n * Collection of methods that allow declaration and validation of props that are\n * supplied to React components. Example usage:\n *\n * var Props = require('ReactPropTypes');\n * var MyArticle = React.createClass({\n * propTypes: {\n * // An optional string prop named \"description\".\n * description: Props.string,\n *\n * // A required enum prop named \"category\".\n * category: Props.oneOf(['News','Photos']).isRequired,\n *\n * // A prop named \"dialog\" that requires an instance of Dialog.\n * dialog: Props.instanceOf(Dialog).isRequired\n * },\n * render: function() { ... }\n * });\n *\n * A more formal specification of how these methods are used:\n *\n * type := array|bool|func|object|number|string|oneOf([...])|instanceOf(...)\n * decl := ReactPropTypes.{type}(.isRequired)?\n *\n * Each and every declaration produces a function with the same signature. This\n * allows the creation of custom validation functions. For example:\n *\n * var MyLink = React.createClass({\n * propTypes: {\n * // An optional string or URI prop named \"href\".\n * href: function(props, propName, componentName) {\n * var propValue = props[propName];\n * if (propValue != null && typeof propValue !== 'string' &&\n * !(propValue instanceof URI)) {\n * return new Error(\n * 'Expected a string or an URI for ' + propName + ' in ' +\n * componentName\n * );\n * }\n * }\n * },\n * render: function() {...}\n * });\n *\n * @internal\n */\n\n var ANONYMOUS = '<>';\n\n // Important!\n // Keep this list in sync with production version in `./factoryWithThrowingShims.js`.\n var ReactPropTypes = {\n array: createPrimitiveTypeChecker('array'),\n bigint: createPrimitiveTypeChecker('bigint'),\n bool: createPrimitiveTypeChecker('boolean'),\n func: createPrimitiveTypeChecker('function'),\n number: createPrimitiveTypeChecker('number'),\n object: createPrimitiveTypeChecker('object'),\n string: createPrimitiveTypeChecker('string'),\n symbol: createPrimitiveTypeChecker('symbol'),\n\n any: createAnyTypeChecker(),\n arrayOf: createArrayOfTypeChecker,\n element: createElementTypeChecker(),\n elementType: createElementTypeTypeChecker(),\n instanceOf: createInstanceTypeChecker,\n node: createNodeChecker(),\n objectOf: createObjectOfTypeChecker,\n oneOf: createEnumTypeChecker,\n oneOfType: createUnionTypeChecker,\n shape: createShapeTypeChecker,\n exact: createStrictShapeTypeChecker,\n };\n\n /**\n * inlined Object.is polyfill to avoid requiring consumers ship their own\n * https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object/is\n */\n /*eslint-disable no-self-compare*/\n function is(x, y) {\n // SameValue algorithm\n if (x === y) {\n // Steps 1-5, 7-10\n // Steps 6.b-6.e: +0 != -0\n return x !== 0 || 1 / x === 1 / y;\n } else {\n // Step 6.a: NaN == NaN\n return x !== x && y !== y;\n }\n }\n /*eslint-enable no-self-compare*/\n\n /**\n * We use an Error-like object for backward compatibility as people may call\n * PropTypes directly and inspect their output. However, we don't use real\n * Errors anymore. We don't inspect their stack anyway, and creating them\n * is prohibitively expensive if they are created too often, such as what\n * happens in oneOfType() for any type before the one that matched.\n */\n function PropTypeError(message, data) {\n this.message = message;\n this.data = data && typeof data === 'object' ? data: {};\n this.stack = '';\n }\n // Make `instanceof Error` still work for returned errors.\n PropTypeError.prototype = Error.prototype;\n\n function createChainableTypeChecker(validate) {\n if (process.env.NODE_ENV !== 'production') {\n var manualPropTypeCallCache = {};\n var manualPropTypeWarningCount = 0;\n }\n function checkType(isRequired, props, propName, componentName, location, propFullName, secret) {\n componentName = componentName || ANONYMOUS;\n propFullName = propFullName || propName;\n\n if (secret !== ReactPropTypesSecret) {\n if (throwOnDirectAccess) {\n // New behavior only for users of `prop-types` package\n var err = new Error(\n 'Calling PropTypes validators directly is not supported by the `prop-types` package. ' +\n 'Use `PropTypes.checkPropTypes()` to call them. ' +\n 'Read more at http://fb.me/use-check-prop-types'\n );\n err.name = 'Invariant Violation';\n throw err;\n } else if (process.env.NODE_ENV !== 'production' && typeof console !== 'undefined') {\n // Old behavior for people using React.PropTypes\n var cacheKey = componentName + ':' + propName;\n if (\n !manualPropTypeCallCache[cacheKey] &&\n // Avoid spamming the console because they are often not actionable except for lib authors\n manualPropTypeWarningCount < 3\n ) {\n printWarning(\n 'You are manually calling a React.PropTypes validation ' +\n 'function for the `' + propFullName + '` prop on `' + componentName + '`. This is deprecated ' +\n 'and will throw in the standalone `prop-types` package. ' +\n 'You may be seeing this warning due to a third-party PropTypes ' +\n 'library. See https://fb.me/react-warning-dont-call-proptypes ' + 'for details.'\n );\n manualPropTypeCallCache[cacheKey] = true;\n manualPropTypeWarningCount++;\n }\n }\n }\n if (props[propName] == null) {\n if (isRequired) {\n if (props[propName] === null) {\n return new PropTypeError('The ' + location + ' `' + propFullName + '` is marked as required ' + ('in `' + componentName + '`, but its value is `null`.'));\n }\n return new PropTypeError('The ' + location + ' `' + propFullName + '` is marked as required in ' + ('`' + componentName + '`, but its value is `undefined`.'));\n }\n return null;\n } else {\n return validate(props, propName, componentName, location, propFullName);\n }\n }\n\n var chainedCheckType = checkType.bind(null, false);\n chainedCheckType.isRequired = checkType.bind(null, true);\n\n return chainedCheckType;\n }\n\n function createPrimitiveTypeChecker(expectedType) {\n function validate(props, propName, componentName, location, propFullName, secret) {\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== expectedType) {\n // `propValue` being instance of, say, date/regexp, pass the 'object'\n // check, but we can offer a more precise error message here rather than\n // 'of type `object`'.\n var preciseType = getPreciseType(propValue);\n\n return new PropTypeError(\n 'Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + preciseType + '` supplied to `' + componentName + '`, expected ') + ('`' + expectedType + '`.'),\n {expectedType: expectedType}\n );\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createAnyTypeChecker() {\n return createChainableTypeChecker(emptyFunctionThatReturnsNull);\n }\n\n function createArrayOfTypeChecker(typeChecker) {\n function validate(props, propName, componentName, location, propFullName) {\n if (typeof typeChecker !== 'function') {\n return new PropTypeError('Property `' + propFullName + '` of component `' + componentName + '` has invalid PropType notation inside arrayOf.');\n }\n var propValue = props[propName];\n if (!Array.isArray(propValue)) {\n var propType = getPropType(propValue);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected an array.'));\n }\n for (var i = 0; i < propValue.length; i++) {\n var error = typeChecker(propValue, i, componentName, location, propFullName + '[' + i + ']', ReactPropTypesSecret);\n if (error instanceof Error) {\n return error;\n }\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createElementTypeChecker() {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n if (!isValidElement(propValue)) {\n var propType = getPropType(propValue);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected a single ReactElement.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createElementTypeTypeChecker() {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n if (!ReactIs.isValidElementType(propValue)) {\n var propType = getPropType(propValue);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected a single ReactElement type.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createInstanceTypeChecker(expectedClass) {\n function validate(props, propName, componentName, location, propFullName) {\n if (!(props[propName] instanceof expectedClass)) {\n var expectedClassName = expectedClass.name || ANONYMOUS;\n var actualClassName = getClassName(props[propName]);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + actualClassName + '` supplied to `' + componentName + '`, expected ') + ('instance of `' + expectedClassName + '`.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createEnumTypeChecker(expectedValues) {\n if (!Array.isArray(expectedValues)) {\n if (process.env.NODE_ENV !== 'production') {\n if (arguments.length > 1) {\n printWarning(\n 'Invalid arguments supplied to oneOf, expected an array, got ' + arguments.length + ' arguments. ' +\n 'A common mistake is to write oneOf(x, y, z) instead of oneOf([x, y, z]).'\n );\n } else {\n printWarning('Invalid argument supplied to oneOf, expected an array.');\n }\n }\n return emptyFunctionThatReturnsNull;\n }\n\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n for (var i = 0; i < expectedValues.length; i++) {\n if (is(propValue, expectedValues[i])) {\n return null;\n }\n }\n\n var valuesString = JSON.stringify(expectedValues, function replacer(key, value) {\n var type = getPreciseType(value);\n if (type === 'symbol') {\n return String(value);\n }\n return value;\n });\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of value `' + String(propValue) + '` ' + ('supplied to `' + componentName + '`, expected one of ' + valuesString + '.'));\n }\n return createChainableTypeChecker(validate);\n }\n\n function createObjectOfTypeChecker(typeChecker) {\n function validate(props, propName, componentName, location, propFullName) {\n if (typeof typeChecker !== 'function') {\n return new PropTypeError('Property `' + propFullName + '` of component `' + componentName + '` has invalid PropType notation inside objectOf.');\n }\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== 'object') {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected an object.'));\n }\n for (var key in propValue) {\n if (has(propValue, key)) {\n var error = typeChecker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret);\n if (error instanceof Error) {\n return error;\n }\n }\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createUnionTypeChecker(arrayOfTypeCheckers) {\n if (!Array.isArray(arrayOfTypeCheckers)) {\n process.env.NODE_ENV !== 'production' ? printWarning('Invalid argument supplied to oneOfType, expected an instance of array.') : void 0;\n return emptyFunctionThatReturnsNull;\n }\n\n for (var i = 0; i < arrayOfTypeCheckers.length; i++) {\n var checker = arrayOfTypeCheckers[i];\n if (typeof checker !== 'function') {\n printWarning(\n 'Invalid argument supplied to oneOfType. Expected an array of check functions, but ' +\n 'received ' + getPostfixForTypeWarning(checker) + ' at index ' + i + '.'\n );\n return emptyFunctionThatReturnsNull;\n }\n }\n\n function validate(props, propName, componentName, location, propFullName) {\n var expectedTypes = [];\n for (var i = 0; i < arrayOfTypeCheckers.length; i++) {\n var checker = arrayOfTypeCheckers[i];\n var checkerResult = checker(props, propName, componentName, location, propFullName, ReactPropTypesSecret);\n if (checkerResult == null) {\n return null;\n }\n if (checkerResult.data && has(checkerResult.data, 'expectedType')) {\n expectedTypes.push(checkerResult.data.expectedType);\n }\n }\n var expectedTypesMessage = (expectedTypes.length > 0) ? ', expected one of type [' + expectedTypes.join(', ') + ']': '';\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` supplied to ' + ('`' + componentName + '`' + expectedTypesMessage + '.'));\n }\n return createChainableTypeChecker(validate);\n }\n\n function createNodeChecker() {\n function validate(props, propName, componentName, location, propFullName) {\n if (!isNode(props[propName])) {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` supplied to ' + ('`' + componentName + '`, expected a ReactNode.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function invalidValidatorError(componentName, location, propFullName, key, type) {\n return new PropTypeError(\n (componentName || 'React class') + ': ' + location + ' type `' + propFullName + '.' + key + '` is invalid; ' +\n 'it must be a function, usually from the `prop-types` package, but received `' + type + '`.'\n );\n }\n\n function createShapeTypeChecker(shapeTypes) {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== 'object') {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type `' + propType + '` ' + ('supplied to `' + componentName + '`, expected `object`.'));\n }\n for (var key in shapeTypes) {\n var checker = shapeTypes[key];\n if (typeof checker !== 'function') {\n return invalidValidatorError(componentName, location, propFullName, key, getPreciseType(checker));\n }\n var error = checker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret);\n if (error) {\n return error;\n }\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createStrictShapeTypeChecker(shapeTypes) {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== 'object') {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type `' + propType + '` ' + ('supplied to `' + componentName + '`, expected `object`.'));\n }\n // We need to check all keys in case some are required but missing from props.\n var allKeys = assign({}, props[propName], shapeTypes);\n for (var key in allKeys) {\n var checker = shapeTypes[key];\n if (has(shapeTypes, key) && typeof checker !== 'function') {\n return invalidValidatorError(componentName, location, propFullName, key, getPreciseType(checker));\n }\n if (!checker) {\n return new PropTypeError(\n 'Invalid ' + location + ' `' + propFullName + '` key `' + key + '` supplied to `' + componentName + '`.' +\n '\\nBad object: ' + JSON.stringify(props[propName], null, ' ') +\n '\\nValid keys: ' + JSON.stringify(Object.keys(shapeTypes), null, ' ')\n );\n }\n var error = checker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret);\n if (error) {\n return error;\n }\n }\n return null;\n }\n\n return createChainableTypeChecker(validate);\n }\n\n function isNode(propValue) {\n switch (typeof propValue) {\n case 'number':\n case 'string':\n case 'undefined':\n return true;\n case 'boolean':\n return !propValue;\n case 'object':\n if (Array.isArray(propValue)) {\n return propValue.every(isNode);\n }\n if (propValue === null || isValidElement(propValue)) {\n return true;\n }\n\n var iteratorFn = getIteratorFn(propValue);\n if (iteratorFn) {\n var iterator = iteratorFn.call(propValue);\n var step;\n if (iteratorFn !== propValue.entries) {\n while (!(step = iterator.next()).done) {\n if (!isNode(step.value)) {\n return false;\n }\n }\n } else {\n // Iterator will provide entry [k,v] tuples rather than values.\n while (!(step = iterator.next()).done) {\n var entry = step.value;\n if (entry) {\n if (!isNode(entry[1])) {\n return false;\n }\n }\n }\n }\n } else {\n return false;\n }\n\n return true;\n default:\n return false;\n }\n }\n\n function isSymbol(propType, propValue) {\n // Native Symbol.\n if (propType === 'symbol') {\n return true;\n }\n\n // falsy value can't be a Symbol\n if (!propValue) {\n return false;\n }\n\n // 19.4.3.5 Symbol.prototype[@@toStringTag] === 'Symbol'\n if (propValue['@@toStringTag'] === 'Symbol') {\n return true;\n }\n\n // Fallback for non-spec compliant Symbols which are polyfilled.\n if (typeof Symbol === 'function' && propValue instanceof Symbol) {\n return true;\n }\n\n return false;\n }\n\n // Equivalent of `typeof` but with special handling for array and regexp.\n function getPropType(propValue) {\n var propType = typeof propValue;\n if (Array.isArray(propValue)) {\n return 'array';\n }\n if (propValue instanceof RegExp) {\n // Old webkits (at least until Android 4.0) return 'function' rather than\n // 'object' for typeof a RegExp. We'll normalize this here so that /bla/\n // passes PropTypes.object.\n return 'object';\n }\n if (isSymbol(propType, propValue)) {\n return 'symbol';\n }\n return propType;\n }\n\n // This handles more types than `getPropType`. Only used for error messages.\n // See `createPrimitiveTypeChecker`.\n function getPreciseType(propValue) {\n if (typeof propValue === 'undefined' || propValue === null) {\n return '' + propValue;\n }\n var propType = getPropType(propValue);\n if (propType === 'object') {\n if (propValue instanceof Date) {\n return 'date';\n } else if (propValue instanceof RegExp) {\n return 'regexp';\n }\n }\n return propType;\n }\n\n // Returns a string that is postfixed to a warning about an invalid type.\n // For example, \"undefined\" or \"of type array\"\n function getPostfixForTypeWarning(value) {\n var type = getPreciseType(value);\n switch (type) {\n case 'array':\n case 'object':\n return 'an ' + type;\n case 'boolean':\n case 'date':\n case 'regexp':\n return 'a ' + type;\n default:\n return type;\n }\n }\n\n // Returns class name of the object, if any.\n function getClassName(propValue) {\n if (!propValue.constructor || !propValue.constructor.name) {\n return ANONYMOUS;\n }\n return propValue.constructor.name;\n }\n\n ReactPropTypes.checkPropTypes = checkPropTypes;\n ReactPropTypes.resetWarningCache = checkPropTypes.resetWarningCache;\n ReactPropTypes.PropTypes = ReactPropTypes;\n\n return ReactPropTypes;\n};\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar ReactPropTypesSecret = require('./lib/ReactPropTypesSecret');\n\nfunction emptyFunction() {}\nfunction emptyFunctionWithReset() {}\nemptyFunctionWithReset.resetWarningCache = emptyFunction;\n\nmodule.exports = function() {\n function shim(props, propName, componentName, location, propFullName, secret) {\n if (secret === ReactPropTypesSecret) {\n // It is still safe when called from React.\n return;\n }\n var err = new Error(\n 'Calling PropTypes validators directly is not supported by the `prop-types` package. ' +\n 'Use PropTypes.checkPropTypes() to call them. ' +\n 'Read more at http://fb.me/use-check-prop-types'\n );\n err.name = 'Invariant Violation';\n throw err;\n };\n shim.isRequired = shim;\n function getShim() {\n return shim;\n };\n // Important!\n // Keep this list in sync with production version in `./factoryWithTypeCheckers.js`.\n var ReactPropTypes = {\n array: shim,\n bigint: shim,\n bool: shim,\n func: shim,\n number: shim,\n object: shim,\n string: shim,\n symbol: shim,\n\n any: shim,\n arrayOf: getShim,\n element: shim,\n elementType: shim,\n instanceOf: getShim,\n node: shim,\n objectOf: getShim,\n oneOf: getShim,\n oneOfType: getShim,\n shape: getShim,\n exact: getShim,\n\n checkPropTypes: emptyFunctionWithReset,\n resetWarningCache: emptyFunction\n };\n\n ReactPropTypes.PropTypes = ReactPropTypes;\n\n return ReactPropTypes;\n};\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\nif (process.env.NODE_ENV !== 'production') {\n var ReactIs = require('react-is');\n\n // By explicitly using `prop-types` you are opting into new development behavior.\n // http://fb.me/prop-types-in-prod\n var throwOnDirectAccess = true;\n module.exports = require('./factoryWithTypeCheckers')(ReactIs.isElement, throwOnDirectAccess);\n} else {\n // By explicitly using `prop-types` you are opting into new production behavior.\n // http://fb.me/prop-types-in-prod\n module.exports = require('./factoryWithThrowingShims')();\n}\n","import PropTypes from 'prop-types';\nimport chainPropTypes from '../chainPropTypes';\nfunction isClassComponent(elementType) {\n // elementType.prototype?.isReactComponent\n const {\n prototype = {}\n } = elementType;\n return Boolean(prototype.isReactComponent);\n}\nfunction acceptingRef(props, propName, componentName, location, propFullName) {\n const element = props[propName];\n const safePropName = propFullName || propName;\n if (element == null ||\n // When server-side rendering React doesn't warn either.\n // This is not an accurate check for SSR.\n // This is only in place for Emotion compat.\n // TODO: Revisit once https://github.com/facebook/react/issues/20047 is resolved.\n typeof window === 'undefined') {\n return null;\n }\n let warningHint;\n const elementType = element.type;\n /**\n * Blacklisting instead of whitelisting\n *\n * Blacklisting will miss some components, such as React.Fragment. Those will at least\n * trigger a warning in React.\n * We can't whitelist because there is no safe way to detect React.forwardRef\n * or class components. \"Safe\" means there's no public API.\n *\n */\n if (typeof elementType === 'function' && !isClassComponent(elementType)) {\n warningHint = 'Did you accidentally use a plain function component for an element instead?';\n }\n if (warningHint !== undefined) {\n return new Error(`Invalid ${location} \\`${safePropName}\\` supplied to \\`${componentName}\\`. ` + `Expected an element that can hold a ref. ${warningHint} ` + 'For more information see https://mui.com/r/caveat-with-refs-guide');\n }\n return null;\n}\nconst elementAcceptingRef = chainPropTypes(PropTypes.element, acceptingRef);\nelementAcceptingRef.isRequired = chainPropTypes(PropTypes.element.isRequired, acceptingRef);\nexport default elementAcceptingRef;","import _extends from \"@babel/runtime/helpers/esm/extends\";\n// This module is based on https://github.com/airbnb/prop-types-exact repository.\n// However, in order to reduce the number of dependencies and to remove some extra safe checks\n// the module was forked.\n\nconst specialProperty = 'exact-prop: \\u200b';\nexport default function exactProp(propTypes) {\n if (process.env.NODE_ENV === 'production') {\n return propTypes;\n }\n return _extends({}, propTypes, {\n [specialProperty]: props => {\n const unsupportedProps = Object.keys(props).filter(prop => !propTypes.hasOwnProperty(prop));\n if (unsupportedProps.length > 0) {\n return new Error(`The following props are not supported: ${unsupportedProps.map(prop => `\\`${prop}\\``).join(', ')}. Please remove them.`);\n }\n return null;\n }\n });\n}","/**\n * WARNING: Don't import this directly.\n * Use `MuiError` from `@mui/internal-babel-macros/MuiError.macro` instead.\n * @param {number} code\n */\nexport default function formatMuiErrorMessage(code) {\n // Apply babel-plugin-transform-template-literals in loose mode\n // loose mode is safe if we're concatenating primitives\n // see https://babeljs.io/docs/en/babel-plugin-transform-template-literals#loose\n /* eslint-disable prefer-template */\n let url = 'https://mui.com/production-error/?code=' + code;\n for (let i = 1; i < arguments.length; i += 1) {\n // rest params over-transpile for this case\n // eslint-disable-next-line prefer-rest-params\n url += '&args[]=' + encodeURIComponent(arguments[i]);\n }\n return 'Minified MUI error #' + code + '; visit ' + url + ' for the full message.';\n /* eslint-enable prefer-template */\n}","/**\n * @license React\n * react-is.production.min.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n'use strict';var b=Symbol.for(\"react.element\"),c=Symbol.for(\"react.portal\"),d=Symbol.for(\"react.fragment\"),e=Symbol.for(\"react.strict_mode\"),f=Symbol.for(\"react.profiler\"),g=Symbol.for(\"react.provider\"),h=Symbol.for(\"react.context\"),k=Symbol.for(\"react.server_context\"),l=Symbol.for(\"react.forward_ref\"),m=Symbol.for(\"react.suspense\"),n=Symbol.for(\"react.suspense_list\"),p=Symbol.for(\"react.memo\"),q=Symbol.for(\"react.lazy\"),t=Symbol.for(\"react.offscreen\"),u;u=Symbol.for(\"react.module.reference\");\nfunction v(a){if(\"object\"===typeof a&&null!==a){var r=a.$$typeof;switch(r){case b:switch(a=a.type,a){case d:case f:case e:case m:case n:return a;default:switch(a=a&&a.$$typeof,a){case k:case h:case l:case q:case p:case g:return a;default:return r}}case c:return r}}}exports.ContextConsumer=h;exports.ContextProvider=g;exports.Element=b;exports.ForwardRef=l;exports.Fragment=d;exports.Lazy=q;exports.Memo=p;exports.Portal=c;exports.Profiler=f;exports.StrictMode=e;exports.Suspense=m;\nexports.SuspenseList=n;exports.isAsyncMode=function(){return!1};exports.isConcurrentMode=function(){return!1};exports.isContextConsumer=function(a){return v(a)===h};exports.isContextProvider=function(a){return v(a)===g};exports.isElement=function(a){return\"object\"===typeof a&&null!==a&&a.$$typeof===b};exports.isForwardRef=function(a){return v(a)===l};exports.isFragment=function(a){return v(a)===d};exports.isLazy=function(a){return v(a)===q};exports.isMemo=function(a){return v(a)===p};\nexports.isPortal=function(a){return v(a)===c};exports.isProfiler=function(a){return v(a)===f};exports.isStrictMode=function(a){return v(a)===e};exports.isSuspense=function(a){return v(a)===m};exports.isSuspenseList=function(a){return v(a)===n};\nexports.isValidElementType=function(a){return\"string\"===typeof a||\"function\"===typeof a||a===d||a===f||a===e||a===m||a===n||a===t||\"object\"===typeof a&&null!==a&&(a.$$typeof===q||a.$$typeof===p||a.$$typeof===g||a.$$typeof===h||a.$$typeof===l||a.$$typeof===u||void 0!==a.getModuleId)?!0:!1};exports.typeOf=v;\n","/**\n * @license React\n * react-is.development.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nif (process.env.NODE_ENV !== \"production\") {\n (function() {\n'use strict';\n\n// ATTENTION\n// When adding new symbols to this file,\n// Please consider also adding to 'react-devtools-shared/src/backend/ReactSymbols'\n// The Symbol used to tag the ReactElement-like types.\nvar REACT_ELEMENT_TYPE = Symbol.for('react.element');\nvar REACT_PORTAL_TYPE = Symbol.for('react.portal');\nvar REACT_FRAGMENT_TYPE = Symbol.for('react.fragment');\nvar REACT_STRICT_MODE_TYPE = Symbol.for('react.strict_mode');\nvar REACT_PROFILER_TYPE = Symbol.for('react.profiler');\nvar REACT_PROVIDER_TYPE = Symbol.for('react.provider');\nvar REACT_CONTEXT_TYPE = Symbol.for('react.context');\nvar REACT_SERVER_CONTEXT_TYPE = Symbol.for('react.server_context');\nvar REACT_FORWARD_REF_TYPE = Symbol.for('react.forward_ref');\nvar REACT_SUSPENSE_TYPE = Symbol.for('react.suspense');\nvar REACT_SUSPENSE_LIST_TYPE = Symbol.for('react.suspense_list');\nvar REACT_MEMO_TYPE = Symbol.for('react.memo');\nvar REACT_LAZY_TYPE = Symbol.for('react.lazy');\nvar REACT_OFFSCREEN_TYPE = Symbol.for('react.offscreen');\n\n// -----------------------------------------------------------------------------\n\nvar enableScopeAPI = false; // Experimental Create Event Handle API.\nvar enableCacheElement = false;\nvar enableTransitionTracing = false; // No known bugs, but needs performance testing\n\nvar enableLegacyHidden = false; // Enables unstable_avoidThisFallback feature in Fiber\n// stuff. Intended to enable React core members to more easily debug scheduling\n// issues in DEV builds.\n\nvar enableDebugTracing = false; // Track which Fiber(s) schedule render work.\n\nvar REACT_MODULE_REFERENCE;\n\n{\n REACT_MODULE_REFERENCE = Symbol.for('react.module.reference');\n}\n\nfunction isValidElementType(type) {\n if (typeof type === 'string' || typeof type === 'function') {\n return true;\n } // Note: typeof might be other than 'symbol' or 'number' (e.g. if it's a polyfill).\n\n\n if (type === REACT_FRAGMENT_TYPE || type === REACT_PROFILER_TYPE || enableDebugTracing || type === REACT_STRICT_MODE_TYPE || type === REACT_SUSPENSE_TYPE || type === REACT_SUSPENSE_LIST_TYPE || enableLegacyHidden || type === REACT_OFFSCREEN_TYPE || enableScopeAPI || enableCacheElement || enableTransitionTracing ) {\n return true;\n }\n\n if (typeof type === 'object' && type !== null) {\n if (type.$$typeof === REACT_LAZY_TYPE || type.$$typeof === REACT_MEMO_TYPE || type.$$typeof === REACT_PROVIDER_TYPE || type.$$typeof === REACT_CONTEXT_TYPE || type.$$typeof === REACT_FORWARD_REF_TYPE || // This needs to include all possible module reference object\n // types supported by any Flight configuration anywhere since\n // we don't know which Flight build this will end up being used\n // with.\n type.$$typeof === REACT_MODULE_REFERENCE || type.getModuleId !== undefined) {\n return true;\n }\n }\n\n return false;\n}\n\nfunction typeOf(object) {\n if (typeof object === 'object' && object !== null) {\n var $$typeof = object.$$typeof;\n\n switch ($$typeof) {\n case REACT_ELEMENT_TYPE:\n var type = object.type;\n\n switch (type) {\n case REACT_FRAGMENT_TYPE:\n case REACT_PROFILER_TYPE:\n case REACT_STRICT_MODE_TYPE:\n case REACT_SUSPENSE_TYPE:\n case REACT_SUSPENSE_LIST_TYPE:\n return type;\n\n default:\n var $$typeofType = type && type.$$typeof;\n\n switch ($$typeofType) {\n case REACT_SERVER_CONTEXT_TYPE:\n case REACT_CONTEXT_TYPE:\n case REACT_FORWARD_REF_TYPE:\n case REACT_LAZY_TYPE:\n case REACT_MEMO_TYPE:\n case REACT_PROVIDER_TYPE:\n return $$typeofType;\n\n default:\n return $$typeof;\n }\n\n }\n\n case REACT_PORTAL_TYPE:\n return $$typeof;\n }\n }\n\n return undefined;\n}\nvar ContextConsumer = REACT_CONTEXT_TYPE;\nvar ContextProvider = REACT_PROVIDER_TYPE;\nvar Element = REACT_ELEMENT_TYPE;\nvar ForwardRef = REACT_FORWARD_REF_TYPE;\nvar Fragment = REACT_FRAGMENT_TYPE;\nvar Lazy = REACT_LAZY_TYPE;\nvar Memo = REACT_MEMO_TYPE;\nvar Portal = REACT_PORTAL_TYPE;\nvar Profiler = REACT_PROFILER_TYPE;\nvar StrictMode = REACT_STRICT_MODE_TYPE;\nvar Suspense = REACT_SUSPENSE_TYPE;\nvar SuspenseList = REACT_SUSPENSE_LIST_TYPE;\nvar hasWarnedAboutDeprecatedIsAsyncMode = false;\nvar hasWarnedAboutDeprecatedIsConcurrentMode = false; // AsyncMode should be deprecated\n\nfunction isAsyncMode(object) {\n {\n if (!hasWarnedAboutDeprecatedIsAsyncMode) {\n hasWarnedAboutDeprecatedIsAsyncMode = true; // Using console['warn'] to evade Babel and ESLint\n\n console['warn']('The ReactIs.isAsyncMode() alias has been deprecated, ' + 'and will be removed in React 18+.');\n }\n }\n\n return false;\n}\nfunction isConcurrentMode(object) {\n {\n if (!hasWarnedAboutDeprecatedIsConcurrentMode) {\n hasWarnedAboutDeprecatedIsConcurrentMode = true; // Using console['warn'] to evade Babel and ESLint\n\n console['warn']('The ReactIs.isConcurrentMode() alias has been deprecated, ' + 'and will be removed in React 18+.');\n }\n }\n\n return false;\n}\nfunction isContextConsumer(object) {\n return typeOf(object) === REACT_CONTEXT_TYPE;\n}\nfunction isContextProvider(object) {\n return typeOf(object) === REACT_PROVIDER_TYPE;\n}\nfunction isElement(object) {\n return typeof object === 'object' && object !== null && object.$$typeof === REACT_ELEMENT_TYPE;\n}\nfunction isForwardRef(object) {\n return typeOf(object) === REACT_FORWARD_REF_TYPE;\n}\nfunction isFragment(object) {\n return typeOf(object) === REACT_FRAGMENT_TYPE;\n}\nfunction isLazy(object) {\n return typeOf(object) === REACT_LAZY_TYPE;\n}\nfunction isMemo(object) {\n return typeOf(object) === REACT_MEMO_TYPE;\n}\nfunction isPortal(object) {\n return typeOf(object) === REACT_PORTAL_TYPE;\n}\nfunction isProfiler(object) {\n return typeOf(object) === REACT_PROFILER_TYPE;\n}\nfunction isStrictMode(object) {\n return typeOf(object) === REACT_STRICT_MODE_TYPE;\n}\nfunction isSuspense(object) {\n return typeOf(object) === REACT_SUSPENSE_TYPE;\n}\nfunction isSuspenseList(object) {\n return typeOf(object) === REACT_SUSPENSE_LIST_TYPE;\n}\n\nexports.ContextConsumer = ContextConsumer;\nexports.ContextProvider = ContextProvider;\nexports.Element = Element;\nexports.ForwardRef = ForwardRef;\nexports.Fragment = Fragment;\nexports.Lazy = Lazy;\nexports.Memo = Memo;\nexports.Portal = Portal;\nexports.Profiler = Profiler;\nexports.StrictMode = StrictMode;\nexports.Suspense = Suspense;\nexports.SuspenseList = SuspenseList;\nexports.isAsyncMode = isAsyncMode;\nexports.isConcurrentMode = isConcurrentMode;\nexports.isContextConsumer = isContextConsumer;\nexports.isContextProvider = isContextProvider;\nexports.isElement = isElement;\nexports.isForwardRef = isForwardRef;\nexports.isFragment = isFragment;\nexports.isLazy = isLazy;\nexports.isMemo = isMemo;\nexports.isPortal = isPortal;\nexports.isProfiler = isProfiler;\nexports.isStrictMode = isStrictMode;\nexports.isSuspense = isSuspense;\nexports.isSuspenseList = isSuspenseList;\nexports.isValidElementType = isValidElementType;\nexports.typeOf = typeOf;\n })();\n}\n","'use strict';\n\nif (process.env.NODE_ENV === 'production') {\n module.exports = require('./cjs/react-is.production.min.js');\n} else {\n module.exports = require('./cjs/react-is.development.js');\n}\n","import { ForwardRef, Memo } from 'react-is';\n\n// Simplified polyfill for IE11 support\n// https://github.com/JamesMGreene/Function.name/blob/58b314d4a983110c3682f1228f845d39ccca1817/Function.name.js#L3\nconst fnNameMatchRegex = /^\\s*function(?:\\s|\\s*\\/\\*.*\\*\\/\\s*)+([^(\\s/]*)\\s*/;\nexport function getFunctionName(fn) {\n const match = `${fn}`.match(fnNameMatchRegex);\n const name = match && match[1];\n return name || '';\n}\nfunction getFunctionComponentName(Component, fallback = '') {\n return Component.displayName || Component.name || getFunctionName(Component) || fallback;\n}\nfunction getWrappedName(outerType, innerType, wrapperName) {\n const functionName = getFunctionComponentName(innerType);\n return outerType.displayName || (functionName !== '' ? `${wrapperName}(${functionName})` : wrapperName);\n}\n\n/**\n * cherry-pick from\n * https://github.com/facebook/react/blob/769b1f270e1251d9dbdce0fcbd9e92e502d059b8/packages/shared/getComponentName.js\n * originally forked from recompose/getDisplayName with added IE11 support\n */\nexport default function getDisplayName(Component) {\n if (Component == null) {\n return undefined;\n }\n if (typeof Component === 'string') {\n return Component;\n }\n if (typeof Component === 'function') {\n return getFunctionComponentName(Component, 'Component');\n }\n\n // TypeScript can't have components as objects but they exist in the form of `memo` or `Suspense`\n if (typeof Component === 'object') {\n switch (Component.$$typeof) {\n case ForwardRef:\n return getWrappedName(Component, Component.render, 'ForwardRef');\n case Memo:\n return getWrappedName(Component, Component.type, 'memo');\n default:\n return undefined;\n }\n }\n return undefined;\n}","export default function HTMLElementType(props, propName, componentName, location, propFullName) {\n if (process.env.NODE_ENV === 'production') {\n return null;\n }\n const propValue = props[propName];\n const safePropName = propFullName || propName;\n if (propValue == null) {\n return null;\n }\n if (propValue && propValue.nodeType !== 1) {\n return new Error(`Invalid ${location} \\`${safePropName}\\` supplied to \\`${componentName}\\`. ` + `Expected an HTMLElement.`);\n }\n return null;\n}","import PropTypes from 'prop-types';\nconst refType = PropTypes.oneOfType([PropTypes.func, PropTypes.object]);\nexport default refType;","import _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\n// It should to be noted that this function isn't equivalent to `text-transform: capitalize`.\n//\n// A strict capitalization should uppercase the first letter of each word in the sentence.\n// We only handle the first word.\nexport default function capitalize(string) {\n if (typeof string !== 'string') {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: \\`capitalize(string)\\` expects a string argument.` : _formatMuiErrorMessage(7));\n }\n return string.charAt(0).toUpperCase() + string.slice(1);\n}","/**\n * Safe chained function.\n *\n * Will only create a new function if needed,\n * otherwise will pass back existing functions or null.\n */\nexport default function createChainedFunction(...funcs) {\n return funcs.reduce((acc, func) => {\n if (func == null) {\n return acc;\n }\n return function chainedFunction(...args) {\n acc.apply(this, args);\n func.apply(this, args);\n };\n }, () => {});\n}","// Corresponds to 10 frames at 60 Hz.\n// A few bytes payload overhead when lodash/debounce is ~3 kB and debounce ~300 B.\nexport default function debounce(func, wait = 166) {\n let timeout;\n function debounced(...args) {\n const later = () => {\n // @ts-ignore\n func.apply(this, args);\n };\n clearTimeout(timeout);\n timeout = setTimeout(later, wait);\n }\n debounced.clear = () => {\n clearTimeout(timeout);\n };\n return debounced;\n}","export default function deprecatedPropType(validator, reason) {\n if (process.env.NODE_ENV === 'production') {\n return () => null;\n }\n return (props, propName, componentName, location, propFullName) => {\n const componentNameSafe = componentName || '<>';\n const propFullNameSafe = propFullName || propName;\n if (typeof props[propName] !== 'undefined') {\n return new Error(`The ${location} \\`${propFullNameSafe}\\` of ` + `\\`${componentNameSafe}\\` is deprecated. ${reason}`);\n }\n return null;\n };\n}","import * as React from 'react';\nexport default function isMuiElement(element, muiNames) {\n var _muiName, _element$type;\n return /*#__PURE__*/React.isValidElement(element) && muiNames.indexOf( // For server components `muiName` is avaialble in element.type._payload.value.muiName\n // relevant info - https://github.com/facebook/react/blob/2807d781a08db8e9873687fccc25c0f12b4fb3d4/packages/react/src/ReactLazy.js#L45\n // eslint-disable-next-line no-underscore-dangle\n (_muiName = element.type.muiName) != null ? _muiName : (_element$type = element.type) == null || (_element$type = _element$type._payload) == null || (_element$type = _element$type.value) == null ? void 0 : _element$type.muiName) !== -1;\n}","export default function ownerDocument(node) {\n return node && node.ownerDocument || document;\n}","import ownerDocument from '../ownerDocument';\nexport default function ownerWindow(node) {\n const doc = ownerDocument(node);\n return doc.defaultView || window;\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nexport default function requirePropFactory(componentNameInError, Component) {\n if (process.env.NODE_ENV === 'production') {\n return () => null;\n }\n\n // eslint-disable-next-line react/forbid-foreign-prop-types\n const prevPropTypes = Component ? _extends({}, Component.propTypes) : null;\n const requireProp = requiredProp => (props, propName, componentName, location, propFullName, ...args) => {\n const propFullNameSafe = propFullName || propName;\n const defaultTypeChecker = prevPropTypes == null ? void 0 : prevPropTypes[propFullNameSafe];\n if (defaultTypeChecker) {\n const typeCheckerResult = defaultTypeChecker(props, propName, componentName, location, propFullName, ...args);\n if (typeCheckerResult) {\n return typeCheckerResult;\n }\n }\n if (typeof props[propName] !== 'undefined' && !props[requiredProp]) {\n return new Error(`The prop \\`${propFullNameSafe}\\` of ` + `\\`${componentNameInError}\\` can only be used together with the \\`${requiredProp}\\` prop.`);\n }\n return null;\n };\n return requireProp;\n}","/**\n * TODO v5: consider making it private\n *\n * passes {value} to {ref}\n *\n * WARNING: Be sure to only call this inside a callback that is passed as a ref.\n * Otherwise, make sure to cleanup the previous {ref} if it changes. See\n * https://github.com/mui/material-ui/issues/13539\n *\n * Useful if you want to expose the ref of an inner component to the public API\n * while still using it inside the component.\n * @param ref A ref callback or ref object. If anything falsy, this is a no-op.\n */\nexport default function setRef(ref, value) {\n if (typeof ref === 'function') {\n ref(value);\n } else if (ref) {\n ref.current = value;\n }\n}","'use client';\n\nimport * as React from 'react';\n\n/**\n * A version of `React.useLayoutEffect` that does not show a warning when server-side rendering.\n * This is useful for effects that are only needed for client-side rendering but not for SSR.\n *\n * Before you use this hook, make sure to read https://gist.github.com/gaearon/e7d97cdf38a2907924ea12e4ebdf3c85\n * and confirm it doesn't apply to your use-case.\n */\nconst useEnhancedEffect = typeof window !== 'undefined' ? React.useLayoutEffect : React.useEffect;\nexport default useEnhancedEffect;","'use client';\n\nimport * as React from 'react';\nlet globalId = 0;\nfunction useGlobalId(idOverride) {\n const [defaultId, setDefaultId] = React.useState(idOverride);\n const id = idOverride || defaultId;\n React.useEffect(() => {\n if (defaultId == null) {\n // Fallback to this default id when possible.\n // Use the incrementing value for client-side rendering only.\n // We can't use it server-side.\n // If you want to use random values please consider the Birthday Problem: https://en.wikipedia.org/wiki/Birthday_problem\n globalId += 1;\n setDefaultId(`mui-${globalId}`);\n }\n }, [defaultId]);\n return id;\n}\n\n// downstream bundlers may remove unnecessary concatenation, but won't remove toString call -- Workaround for https://github.com/webpack/webpack/issues/14814\nconst maybeReactUseId = React['useId'.toString()];\n/**\n *\n * @example
    \n * @param idOverride\n * @returns {string}\n */\nexport default function useId(idOverride) {\n if (maybeReactUseId !== undefined) {\n const reactId = maybeReactUseId();\n return idOverride != null ? idOverride : reactId;\n }\n // eslint-disable-next-line react-hooks/rules-of-hooks -- `React.useId` is invariant at runtime.\n return useGlobalId(idOverride);\n}","export default function unsupportedProp(props, propName, componentName, location, propFullName) {\n if (process.env.NODE_ENV === 'production') {\n return null;\n }\n const propFullNameSafe = propFullName || propName;\n if (typeof props[propName] !== 'undefined') {\n return new Error(`The prop \\`${propFullNameSafe}\\` is not supported. Please remove it.`);\n }\n return null;\n}","'use client';\n\n/* eslint-disable react-hooks/rules-of-hooks, react-hooks/exhaustive-deps */\nimport * as React from 'react';\nexport default function useControlled({\n controlled,\n default: defaultProp,\n name,\n state = 'value'\n}) {\n // isControlled is ignored in the hook dependency lists as it should never change.\n const {\n current: isControlled\n } = React.useRef(controlled !== undefined);\n const [valueState, setValue] = React.useState(defaultProp);\n const value = isControlled ? controlled : valueState;\n if (process.env.NODE_ENV !== 'production') {\n React.useEffect(() => {\n if (isControlled !== (controlled !== undefined)) {\n console.error([`MUI: A component is changing the ${isControlled ? '' : 'un'}controlled ${state} state of ${name} to be ${isControlled ? 'un' : ''}controlled.`, 'Elements should not switch from uncontrolled to controlled (or vice versa).', `Decide between using a controlled or uncontrolled ${name} ` + 'element for the lifetime of the component.', \"The nature of the state is determined during the first render. It's considered controlled if the value is not `undefined`.\", 'More info: https://fb.me/react-controlled-components'].join('\\n'));\n }\n }, [state, name, controlled]);\n const {\n current: defaultValue\n } = React.useRef(defaultProp);\n React.useEffect(() => {\n if (!isControlled && defaultValue !== defaultProp) {\n console.error([`MUI: A component is changing the default ${state} state of an uncontrolled ${name} after being initialized. ` + `To suppress this warning opt to use a controlled ${name}.`].join('\\n'));\n }\n }, [JSON.stringify(defaultProp)]);\n }\n const setValueIfUncontrolled = React.useCallback(newValue => {\n if (!isControlled) {\n setValue(newValue);\n }\n }, []);\n return [value, setValueIfUncontrolled];\n}","'use client';\n\nimport * as React from 'react';\nimport useEnhancedEffect from '../useEnhancedEffect';\n\n/**\n * Inspired by https://github.com/facebook/react/issues/14099#issuecomment-440013892\n * See RFC in https://github.com/reactjs/rfcs/pull/220\n */\n\nfunction useEventCallback(fn) {\n const ref = React.useRef(fn);\n useEnhancedEffect(() => {\n ref.current = fn;\n });\n return React.useRef((...args) =>\n // @ts-expect-error hide `this`\n (0, ref.current)(...args)).current;\n}\nexport default useEventCallback;","'use client';\n\nimport * as React from 'react';\nimport setRef from '../setRef';\nexport default function useForkRef(...refs) {\n /**\n * This will create a new function if the refs passed to this hook change and are all defined.\n * This means react will call the old forkRef with `null` and the new forkRef\n * with the ref. Cleanup naturally emerges from this behavior.\n */\n return React.useMemo(() => {\n if (refs.every(ref => ref == null)) {\n return null;\n }\n return instance => {\n refs.forEach(ref => {\n setRef(ref, instance);\n });\n };\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, refs);\n}","'use client';\n\nimport * as React from 'react';\nconst UNINITIALIZED = {};\n\n/**\n * A React.useRef() that is initialized lazily with a function. Note that it accepts an optional\n * initialization argument, so the initialization function doesn't need to be an inline closure.\n *\n * @usage\n * const ref = useLazyRef(sortColumns, columns)\n */\nexport default function useLazyRef(init, initArg) {\n const ref = React.useRef(UNINITIALIZED);\n if (ref.current === UNINITIALIZED) {\n ref.current = init(initArg);\n }\n return ref;\n}","'use client';\n\nimport * as React from 'react';\nconst EMPTY = [];\n\n/**\n * A React.useEffect equivalent that runs once, when the component is mounted.\n */\nexport default function useOnMount(fn) {\n /* eslint-disable react-hooks/exhaustive-deps */\n React.useEffect(fn, EMPTY);\n /* eslint-enable react-hooks/exhaustive-deps */\n}","'use client';\n\nimport useLazyRef from '../useLazyRef/useLazyRef';\nimport useOnMount from '../useOnMount/useOnMount';\nexport class Timeout {\n constructor() {\n this.currentId = null;\n this.clear = () => {\n if (this.currentId !== null) {\n clearTimeout(this.currentId);\n this.currentId = null;\n }\n };\n this.disposeEffect = () => {\n return this.clear;\n };\n }\n static create() {\n return new Timeout();\n }\n /**\n * Executes `fn` after `delay`, clearing any previously scheduled call.\n */\n start(delay, fn) {\n this.clear();\n this.currentId = setTimeout(() => {\n this.currentId = null;\n fn();\n }, delay);\n }\n}\nexport default function useTimeout() {\n const timeout = useLazyRef(Timeout.create).current;\n useOnMount(timeout.disposeEffect);\n return timeout;\n}","'use client';\n\n// based on https://github.com/WICG/focus-visible/blob/v4.1.5/src/focus-visible.js\nimport * as React from 'react';\nimport { Timeout } from '../useTimeout/useTimeout';\nlet hadKeyboardEvent = true;\nlet hadFocusVisibleRecently = false;\nconst hadFocusVisibleRecentlyTimeout = new Timeout();\nconst inputTypesWhitelist = {\n text: true,\n search: true,\n url: true,\n tel: true,\n email: true,\n password: true,\n number: true,\n date: true,\n month: true,\n week: true,\n time: true,\n datetime: true,\n 'datetime-local': true\n};\n\n/**\n * Computes whether the given element should automatically trigger the\n * `focus-visible` class being added, i.e. whether it should always match\n * `:focus-visible` when focused.\n * @param {Element} node\n * @returns {boolean}\n */\nfunction focusTriggersKeyboardModality(node) {\n const {\n type,\n tagName\n } = node;\n if (tagName === 'INPUT' && inputTypesWhitelist[type] && !node.readOnly) {\n return true;\n }\n if (tagName === 'TEXTAREA' && !node.readOnly) {\n return true;\n }\n if (node.isContentEditable) {\n return true;\n }\n return false;\n}\n\n/**\n * Keep track of our keyboard modality state with `hadKeyboardEvent`.\n * If the most recent user interaction was via the keyboard;\n * and the key press did not include a meta, alt/option, or control key;\n * then the modality is keyboard. Otherwise, the modality is not keyboard.\n * @param {KeyboardEvent} event\n */\nfunction handleKeyDown(event) {\n if (event.metaKey || event.altKey || event.ctrlKey) {\n return;\n }\n hadKeyboardEvent = true;\n}\n\n/**\n * If at any point a user clicks with a pointing device, ensure that we change\n * the modality away from keyboard.\n * This avoids the situation where a user presses a key on an already focused\n * element, and then clicks on a different element, focusing it with a\n * pointing device, while we still think we're in keyboard modality.\n */\nfunction handlePointerDown() {\n hadKeyboardEvent = false;\n}\nfunction handleVisibilityChange() {\n if (this.visibilityState === 'hidden') {\n // If the tab becomes active again, the browser will handle calling focus\n // on the element (Safari actually calls it twice).\n // If this tab change caused a blur on an element with focus-visible,\n // re-apply the class when the user switches back to the tab.\n if (hadFocusVisibleRecently) {\n hadKeyboardEvent = true;\n }\n }\n}\nfunction prepare(doc) {\n doc.addEventListener('keydown', handleKeyDown, true);\n doc.addEventListener('mousedown', handlePointerDown, true);\n doc.addEventListener('pointerdown', handlePointerDown, true);\n doc.addEventListener('touchstart', handlePointerDown, true);\n doc.addEventListener('visibilitychange', handleVisibilityChange, true);\n}\nexport function teardown(doc) {\n doc.removeEventListener('keydown', handleKeyDown, true);\n doc.removeEventListener('mousedown', handlePointerDown, true);\n doc.removeEventListener('pointerdown', handlePointerDown, true);\n doc.removeEventListener('touchstart', handlePointerDown, true);\n doc.removeEventListener('visibilitychange', handleVisibilityChange, true);\n}\nfunction isFocusVisible(event) {\n const {\n target\n } = event;\n try {\n return target.matches(':focus-visible');\n } catch (error) {\n // Browsers not implementing :focus-visible will throw a SyntaxError.\n // We use our own heuristic for those browsers.\n // Rethrow might be better if it's not the expected error but do we really\n // want to crash if focus-visible malfunctioned?\n }\n\n // No need for validFocusTarget check. The user does that by attaching it to\n // focusable events only.\n return hadKeyboardEvent || focusTriggersKeyboardModality(target);\n}\nexport default function useIsFocusVisible() {\n const ref = React.useCallback(node => {\n if (node != null) {\n prepare(node.ownerDocument);\n }\n }, []);\n const isFocusVisibleRef = React.useRef(false);\n\n /**\n * Should be called if a blur event is fired\n */\n function handleBlurVisible() {\n // checking against potential state variable does not suffice if we focus and blur synchronously.\n // React wouldn't have time to trigger a re-render so `focusVisible` would be stale.\n // Ideally we would adjust `isFocusVisible(event)` to look at `relatedTarget` for blur events.\n // This doesn't work in IE11 due to https://github.com/facebook/react/issues/3751\n // TODO: check again if React releases their internal changes to focus event handling (https://github.com/facebook/react/pull/19186).\n if (isFocusVisibleRef.current) {\n // To detect a tab/window switch, we look for a blur event followed\n // rapidly by a visibility change.\n // If we don't see a visibility change within 100ms, it's probably a\n // regular focus change.\n hadFocusVisibleRecently = true;\n hadFocusVisibleRecentlyTimeout.start(100, () => {\n hadFocusVisibleRecently = false;\n });\n isFocusVisibleRef.current = false;\n return true;\n }\n return false;\n }\n\n /**\n * Should be called if a blur event is fired\n */\n function handleFocusVisible(event) {\n if (isFocusVisible(event)) {\n isFocusVisibleRef.current = true;\n return true;\n }\n return false;\n }\n return {\n isFocusVisibleRef,\n onFocus: handleFocusVisible,\n onBlur: handleBlurVisible,\n ref\n };\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\n/**\n * Add keys, values of `defaultProps` that does not exist in `props`\n * @param {object} defaultProps\n * @param {object} props\n * @returns {object} resolved props\n */\nexport default function resolveProps(defaultProps, props) {\n const output = _extends({}, props);\n Object.keys(defaultProps).forEach(propName => {\n if (propName.toString().match(/^(components|slots)$/)) {\n output[propName] = _extends({}, defaultProps[propName], output[propName]);\n } else if (propName.toString().match(/^(componentsProps|slotProps)$/)) {\n const defaultSlotProps = defaultProps[propName] || {};\n const slotProps = props[propName];\n output[propName] = {};\n if (!slotProps || !Object.keys(slotProps)) {\n // Reduce the iteration if the slot props is empty\n output[propName] = defaultSlotProps;\n } else if (!defaultSlotProps || !Object.keys(defaultSlotProps)) {\n // Reduce the iteration if the default slot props is empty\n output[propName] = slotProps;\n } else {\n output[propName] = _extends({}, slotProps);\n Object.keys(defaultSlotProps).forEach(slotPropName => {\n output[propName][slotPropName] = resolveProps(defaultSlotProps[slotPropName], slotProps[slotPropName]);\n });\n }\n } else if (output[propName] === undefined) {\n output[propName] = defaultProps[propName];\n }\n });\n return output;\n}","export default function composeClasses(slots, getUtilityClass, classes = undefined) {\n const output = {};\n Object.keys(slots).forEach(\n // `Object.keys(slots)` can't be wider than `T` because we infer `T` from `slots`.\n // @ts-expect-error https://github.com/microsoft/TypeScript/pull/12253#issuecomment-263132208\n slot => {\n output[slot] = slots[slot].reduce((acc, key) => {\n if (key) {\n const utilityClass = getUtilityClass(key);\n if (utilityClass !== '') {\n acc.push(utilityClass);\n }\n if (classes && classes[key]) {\n acc.push(classes[key]);\n }\n }\n return acc;\n }, []).join(' ');\n });\n return output;\n}","const defaultGenerator = componentName => componentName;\nconst createClassNameGenerator = () => {\n let generate = defaultGenerator;\n return {\n configure(generator) {\n generate = generator;\n },\n generate(componentName) {\n return generate(componentName);\n },\n reset() {\n generate = defaultGenerator;\n }\n };\n};\nconst ClassNameGenerator = createClassNameGenerator();\nexport default ClassNameGenerator;","import ClassNameGenerator from '../ClassNameGenerator';\nexport const globalStateClasses = {\n active: 'active',\n checked: 'checked',\n completed: 'completed',\n disabled: 'disabled',\n error: 'error',\n expanded: 'expanded',\n focused: 'focused',\n focusVisible: 'focusVisible',\n open: 'open',\n readOnly: 'readOnly',\n required: 'required',\n selected: 'selected'\n};\nexport default function generateUtilityClass(componentName, slot, globalStatePrefix = 'Mui') {\n const globalStateClass = globalStateClasses[slot];\n return globalStateClass ? `${globalStatePrefix}-${globalStateClass}` : `${ClassNameGenerator.generate(componentName)}-${slot}`;\n}\nexport function isGlobalState(slot) {\n return globalStateClasses[slot] !== undefined;\n}","import generateUtilityClass from '../generateUtilityClass';\nexport default function generateUtilityClasses(componentName, slots, globalStatePrefix = 'Mui') {\n const result = {};\n slots.forEach(slot => {\n result[slot] = generateUtilityClass(componentName, slot, globalStatePrefix);\n });\n return result;\n}","function clamp(val, min = Number.MIN_SAFE_INTEGER, max = Number.MAX_SAFE_INTEGER) {\n return Math.max(min, Math.min(val, max));\n}\nexport default clamp;","export default function _objectWithoutPropertiesLoose(source, excluded) {\n if (source == null) return {};\n var target = {};\n var sourceKeys = Object.keys(source);\n var key, i;\n for (i = 0; i < sourceKeys.length; i++) {\n key = sourceKeys[i];\n if (excluded.indexOf(key) >= 0) continue;\n target[key] = source[key];\n }\n return target;\n}","import _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nconst _excluded = [\"values\", \"unit\", \"step\"];\n// Sorted ASC by size. That's important.\n// It can't be configured as it's used statically for propTypes.\nexport const breakpointKeys = ['xs', 'sm', 'md', 'lg', 'xl'];\nconst sortBreakpointsValues = values => {\n const breakpointsAsArray = Object.keys(values).map(key => ({\n key,\n val: values[key]\n })) || [];\n // Sort in ascending order\n breakpointsAsArray.sort((breakpoint1, breakpoint2) => breakpoint1.val - breakpoint2.val);\n return breakpointsAsArray.reduce((acc, obj) => {\n return _extends({}, acc, {\n [obj.key]: obj.val\n });\n }, {});\n};\n\n// Keep in mind that @media is inclusive by the CSS specification.\nexport default function createBreakpoints(breakpoints) {\n const {\n // The breakpoint **start** at this value.\n // For instance with the first breakpoint xs: [xs, sm).\n values = {\n xs: 0,\n // phone\n sm: 600,\n // tablet\n md: 900,\n // small laptop\n lg: 1200,\n // desktop\n xl: 1536 // large screen\n },\n unit = 'px',\n step = 5\n } = breakpoints,\n other = _objectWithoutPropertiesLoose(breakpoints, _excluded);\n const sortedValues = sortBreakpointsValues(values);\n const keys = Object.keys(sortedValues);\n function up(key) {\n const value = typeof values[key] === 'number' ? values[key] : key;\n return `@media (min-width:${value}${unit})`;\n }\n function down(key) {\n const value = typeof values[key] === 'number' ? values[key] : key;\n return `@media (max-width:${value - step / 100}${unit})`;\n }\n function between(start, end) {\n const endIndex = keys.indexOf(end);\n return `@media (min-width:${typeof values[start] === 'number' ? values[start] : start}${unit}) and ` + `(max-width:${(endIndex !== -1 && typeof values[keys[endIndex]] === 'number' ? values[keys[endIndex]] : end) - step / 100}${unit})`;\n }\n function only(key) {\n if (keys.indexOf(key) + 1 < keys.length) {\n return between(key, keys[keys.indexOf(key) + 1]);\n }\n return up(key);\n }\n function not(key) {\n // handle first and last key separately, for better readability\n const keyIndex = keys.indexOf(key);\n if (keyIndex === 0) {\n return up(keys[1]);\n }\n if (keyIndex === keys.length - 1) {\n return down(keys[keyIndex]);\n }\n return between(key, keys[keys.indexOf(key) + 1]).replace('@media', '@media not all and');\n }\n return _extends({\n keys,\n values: sortedValues,\n up,\n down,\n between,\n only,\n not,\n unit\n }, other);\n}","const shape = {\n borderRadius: 4\n};\nexport default shape;","import PropTypes from 'prop-types';\nconst responsivePropType = process.env.NODE_ENV !== 'production' ? PropTypes.oneOfType([PropTypes.number, PropTypes.string, PropTypes.object, PropTypes.array]) : {};\nexport default responsivePropType;","import deepmerge from '@mui/utils/deepmerge';\nfunction merge(acc, item) {\n if (!item) {\n return acc;\n }\n return deepmerge(acc, item, {\n clone: false // No need to clone deep, it's way faster.\n });\n}\nexport default merge;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport PropTypes from 'prop-types';\nimport deepmerge from '@mui/utils/deepmerge';\nimport merge from './merge';\n\n// The breakpoint **start** at this value.\n// For instance with the first breakpoint xs: [xs, sm[.\nexport const values = {\n xs: 0,\n // phone\n sm: 600,\n // tablet\n md: 900,\n // small laptop\n lg: 1200,\n // desktop\n xl: 1536 // large screen\n};\nconst defaultBreakpoints = {\n // Sorted ASC by size. That's important.\n // It can't be configured as it's used statically for propTypes.\n keys: ['xs', 'sm', 'md', 'lg', 'xl'],\n up: key => `@media (min-width:${values[key]}px)`\n};\nexport function handleBreakpoints(props, propValue, styleFromPropValue) {\n const theme = props.theme || {};\n if (Array.isArray(propValue)) {\n const themeBreakpoints = theme.breakpoints || defaultBreakpoints;\n return propValue.reduce((acc, item, index) => {\n acc[themeBreakpoints.up(themeBreakpoints.keys[index])] = styleFromPropValue(propValue[index]);\n return acc;\n }, {});\n }\n if (typeof propValue === 'object') {\n const themeBreakpoints = theme.breakpoints || defaultBreakpoints;\n return Object.keys(propValue).reduce((acc, breakpoint) => {\n // key is breakpoint\n if (Object.keys(themeBreakpoints.values || values).indexOf(breakpoint) !== -1) {\n const mediaKey = themeBreakpoints.up(breakpoint);\n acc[mediaKey] = styleFromPropValue(propValue[breakpoint], breakpoint);\n } else {\n const cssKey = breakpoint;\n acc[cssKey] = propValue[cssKey];\n }\n return acc;\n }, {});\n }\n const output = styleFromPropValue(propValue);\n return output;\n}\nfunction breakpoints(styleFunction) {\n // false positive\n // eslint-disable-next-line react/function-component-definition\n const newStyleFunction = props => {\n const theme = props.theme || {};\n const base = styleFunction(props);\n const themeBreakpoints = theme.breakpoints || defaultBreakpoints;\n const extended = themeBreakpoints.keys.reduce((acc, key) => {\n if (props[key]) {\n acc = acc || {};\n acc[themeBreakpoints.up(key)] = styleFunction(_extends({\n theme\n }, props[key]));\n }\n return acc;\n }, null);\n return merge(base, extended);\n };\n newStyleFunction.propTypes = process.env.NODE_ENV !== 'production' ? _extends({}, styleFunction.propTypes, {\n xs: PropTypes.object,\n sm: PropTypes.object,\n md: PropTypes.object,\n lg: PropTypes.object,\n xl: PropTypes.object\n }) : {};\n newStyleFunction.filterProps = ['xs', 'sm', 'md', 'lg', 'xl', ...styleFunction.filterProps];\n return newStyleFunction;\n}\nexport function createEmptyBreakpointObject(breakpointsInput = {}) {\n var _breakpointsInput$key;\n const breakpointsInOrder = (_breakpointsInput$key = breakpointsInput.keys) == null ? void 0 : _breakpointsInput$key.reduce((acc, key) => {\n const breakpointStyleKey = breakpointsInput.up(key);\n acc[breakpointStyleKey] = {};\n return acc;\n }, {});\n return breakpointsInOrder || {};\n}\nexport function removeUnusedBreakpoints(breakpointKeys, style) {\n return breakpointKeys.reduce((acc, key) => {\n const breakpointOutput = acc[key];\n const isBreakpointUnused = !breakpointOutput || Object.keys(breakpointOutput).length === 0;\n if (isBreakpointUnused) {\n delete acc[key];\n }\n return acc;\n }, style);\n}\nexport function mergeBreakpointsInOrder(breakpointsInput, ...styles) {\n const emptyBreakpoints = createEmptyBreakpointObject(breakpointsInput);\n const mergedOutput = [emptyBreakpoints, ...styles].reduce((prev, next) => deepmerge(prev, next), {});\n return removeUnusedBreakpoints(Object.keys(emptyBreakpoints), mergedOutput);\n}\n\n// compute base for responsive values; e.g.,\n// [1,2,3] => {xs: true, sm: true, md: true}\n// {xs: 1, sm: 2, md: 3} => {xs: true, sm: true, md: true}\nexport function computeBreakpointsBase(breakpointValues, themeBreakpoints) {\n // fixed value\n if (typeof breakpointValues !== 'object') {\n return {};\n }\n const base = {};\n const breakpointsKeys = Object.keys(themeBreakpoints);\n if (Array.isArray(breakpointValues)) {\n breakpointsKeys.forEach((breakpoint, i) => {\n if (i < breakpointValues.length) {\n base[breakpoint] = true;\n }\n });\n } else {\n breakpointsKeys.forEach(breakpoint => {\n if (breakpointValues[breakpoint] != null) {\n base[breakpoint] = true;\n }\n });\n }\n return base;\n}\nexport function resolveBreakpointValues({\n values: breakpointValues,\n breakpoints: themeBreakpoints,\n base: customBase\n}) {\n const base = customBase || computeBreakpointsBase(breakpointValues, themeBreakpoints);\n const keys = Object.keys(base);\n if (keys.length === 0) {\n return breakpointValues;\n }\n let previous;\n return keys.reduce((acc, breakpoint, i) => {\n if (Array.isArray(breakpointValues)) {\n acc[breakpoint] = breakpointValues[i] != null ? breakpointValues[i] : breakpointValues[previous];\n previous = i;\n } else if (typeof breakpointValues === 'object') {\n acc[breakpoint] = breakpointValues[breakpoint] != null ? breakpointValues[breakpoint] : breakpointValues[previous];\n previous = breakpoint;\n } else {\n acc[breakpoint] = breakpointValues;\n }\n return acc;\n }, {});\n}\nexport default breakpoints;","import capitalize from '@mui/utils/capitalize';\nimport responsivePropType from './responsivePropType';\nimport { handleBreakpoints } from './breakpoints';\nexport function getPath(obj, path, checkVars = true) {\n if (!path || typeof path !== 'string') {\n return null;\n }\n\n // Check if CSS variables are used\n if (obj && obj.vars && checkVars) {\n const val = `vars.${path}`.split('.').reduce((acc, item) => acc && acc[item] ? acc[item] : null, obj);\n if (val != null) {\n return val;\n }\n }\n return path.split('.').reduce((acc, item) => {\n if (acc && acc[item] != null) {\n return acc[item];\n }\n return null;\n }, obj);\n}\nexport function getStyleValue(themeMapping, transform, propValueFinal, userValue = propValueFinal) {\n let value;\n if (typeof themeMapping === 'function') {\n value = themeMapping(propValueFinal);\n } else if (Array.isArray(themeMapping)) {\n value = themeMapping[propValueFinal] || userValue;\n } else {\n value = getPath(themeMapping, propValueFinal) || userValue;\n }\n if (transform) {\n value = transform(value, userValue, themeMapping);\n }\n return value;\n}\nfunction style(options) {\n const {\n prop,\n cssProperty = options.prop,\n themeKey,\n transform\n } = options;\n\n // false positive\n // eslint-disable-next-line react/function-component-definition\n const fn = props => {\n if (props[prop] == null) {\n return null;\n }\n const propValue = props[prop];\n const theme = props.theme;\n const themeMapping = getPath(theme, themeKey) || {};\n const styleFromPropValue = propValueFinal => {\n let value = getStyleValue(themeMapping, transform, propValueFinal);\n if (propValueFinal === value && typeof propValueFinal === 'string') {\n // Haven't found value\n value = getStyleValue(themeMapping, transform, `${prop}${propValueFinal === 'default' ? '' : capitalize(propValueFinal)}`, propValueFinal);\n }\n if (cssProperty === false) {\n return value;\n }\n return {\n [cssProperty]: value\n };\n };\n return handleBreakpoints(props, propValue, styleFromPropValue);\n };\n fn.propTypes = process.env.NODE_ENV !== 'production' ? {\n [prop]: responsivePropType\n } : {};\n fn.filterProps = [prop];\n return fn;\n}\nexport default style;","export default function memoize(fn) {\n const cache = {};\n return arg => {\n if (cache[arg] === undefined) {\n cache[arg] = fn(arg);\n }\n return cache[arg];\n };\n}","import responsivePropType from './responsivePropType';\nimport { handleBreakpoints } from './breakpoints';\nimport { getPath } from './style';\nimport merge from './merge';\nimport memoize from './memoize';\nconst properties = {\n m: 'margin',\n p: 'padding'\n};\nconst directions = {\n t: 'Top',\n r: 'Right',\n b: 'Bottom',\n l: 'Left',\n x: ['Left', 'Right'],\n y: ['Top', 'Bottom']\n};\nconst aliases = {\n marginX: 'mx',\n marginY: 'my',\n paddingX: 'px',\n paddingY: 'py'\n};\n\n// memoize() impact:\n// From 300,000 ops/sec\n// To 350,000 ops/sec\nconst getCssProperties = memoize(prop => {\n // It's not a shorthand notation.\n if (prop.length > 2) {\n if (aliases[prop]) {\n prop = aliases[prop];\n } else {\n return [prop];\n }\n }\n const [a, b] = prop.split('');\n const property = properties[a];\n const direction = directions[b] || '';\n return Array.isArray(direction) ? direction.map(dir => property + dir) : [property + direction];\n});\nexport const marginKeys = ['m', 'mt', 'mr', 'mb', 'ml', 'mx', 'my', 'margin', 'marginTop', 'marginRight', 'marginBottom', 'marginLeft', 'marginX', 'marginY', 'marginInline', 'marginInlineStart', 'marginInlineEnd', 'marginBlock', 'marginBlockStart', 'marginBlockEnd'];\nexport const paddingKeys = ['p', 'pt', 'pr', 'pb', 'pl', 'px', 'py', 'padding', 'paddingTop', 'paddingRight', 'paddingBottom', 'paddingLeft', 'paddingX', 'paddingY', 'paddingInline', 'paddingInlineStart', 'paddingInlineEnd', 'paddingBlock', 'paddingBlockStart', 'paddingBlockEnd'];\nconst spacingKeys = [...marginKeys, ...paddingKeys];\nexport function createUnaryUnit(theme, themeKey, defaultValue, propName) {\n var _getPath;\n const themeSpacing = (_getPath = getPath(theme, themeKey, false)) != null ? _getPath : defaultValue;\n if (typeof themeSpacing === 'number') {\n return abs => {\n if (typeof abs === 'string') {\n return abs;\n }\n if (process.env.NODE_ENV !== 'production') {\n if (typeof abs !== 'number') {\n console.error(`MUI: Expected ${propName} argument to be a number or a string, got ${abs}.`);\n }\n }\n return themeSpacing * abs;\n };\n }\n if (Array.isArray(themeSpacing)) {\n return abs => {\n if (typeof abs === 'string') {\n return abs;\n }\n if (process.env.NODE_ENV !== 'production') {\n if (!Number.isInteger(abs)) {\n console.error([`MUI: The \\`theme.${themeKey}\\` array type cannot be combined with non integer values.` + `You should either use an integer value that can be used as index, or define the \\`theme.${themeKey}\\` as a number.`].join('\\n'));\n } else if (abs > themeSpacing.length - 1) {\n console.error([`MUI: The value provided (${abs}) overflows.`, `The supported values are: ${JSON.stringify(themeSpacing)}.`, `${abs} > ${themeSpacing.length - 1}, you need to add the missing values.`].join('\\n'));\n }\n }\n return themeSpacing[abs];\n };\n }\n if (typeof themeSpacing === 'function') {\n return themeSpacing;\n }\n if (process.env.NODE_ENV !== 'production') {\n console.error([`MUI: The \\`theme.${themeKey}\\` value (${themeSpacing}) is invalid.`, 'It should be a number, an array or a function.'].join('\\n'));\n }\n return () => undefined;\n}\nexport function createUnarySpacing(theme) {\n return createUnaryUnit(theme, 'spacing', 8, 'spacing');\n}\nexport function getValue(transformer, propValue) {\n if (typeof propValue === 'string' || propValue == null) {\n return propValue;\n }\n const abs = Math.abs(propValue);\n const transformed = transformer(abs);\n if (propValue >= 0) {\n return transformed;\n }\n if (typeof transformed === 'number') {\n return -transformed;\n }\n return `-${transformed}`;\n}\nexport function getStyleFromPropValue(cssProperties, transformer) {\n return propValue => cssProperties.reduce((acc, cssProperty) => {\n acc[cssProperty] = getValue(transformer, propValue);\n return acc;\n }, {});\n}\nfunction resolveCssProperty(props, keys, prop, transformer) {\n // Using a hash computation over an array iteration could be faster, but with only 28 items,\n // it's doesn't worth the bundle size.\n if (keys.indexOf(prop) === -1) {\n return null;\n }\n const cssProperties = getCssProperties(prop);\n const styleFromPropValue = getStyleFromPropValue(cssProperties, transformer);\n const propValue = props[prop];\n return handleBreakpoints(props, propValue, styleFromPropValue);\n}\nfunction style(props, keys) {\n const transformer = createUnarySpacing(props.theme);\n return Object.keys(props).map(prop => resolveCssProperty(props, keys, prop, transformer)).reduce(merge, {});\n}\nexport function margin(props) {\n return style(props, marginKeys);\n}\nmargin.propTypes = process.env.NODE_ENV !== 'production' ? marginKeys.reduce((obj, key) => {\n obj[key] = responsivePropType;\n return obj;\n}, {}) : {};\nmargin.filterProps = marginKeys;\nexport function padding(props) {\n return style(props, paddingKeys);\n}\npadding.propTypes = process.env.NODE_ENV !== 'production' ? paddingKeys.reduce((obj, key) => {\n obj[key] = responsivePropType;\n return obj;\n}, {}) : {};\npadding.filterProps = paddingKeys;\nfunction spacing(props) {\n return style(props, spacingKeys);\n}\nspacing.propTypes = process.env.NODE_ENV !== 'production' ? spacingKeys.reduce((obj, key) => {\n obj[key] = responsivePropType;\n return obj;\n}, {}) : {};\nspacing.filterProps = spacingKeys;\nexport default spacing;","import { createUnarySpacing } from '../spacing';\n\n// The different signatures imply different meaning for their arguments that can't be expressed structurally.\n// We express the difference with variable names.\n\nexport default function createSpacing(spacingInput = 8) {\n // Already transformed.\n if (spacingInput.mui) {\n return spacingInput;\n }\n\n // Material Design layouts are visually balanced. Most measurements align to an 8dp grid, which aligns both spacing and the overall layout.\n // Smaller components, such as icons, can align to a 4dp grid.\n // https://m2.material.io/design/layout/understanding-layout.html\n const transform = createUnarySpacing({\n spacing: spacingInput\n });\n const spacing = (...argsInput) => {\n if (process.env.NODE_ENV !== 'production') {\n if (!(argsInput.length <= 4)) {\n console.error(`MUI: Too many arguments provided, expected between 0 and 4, got ${argsInput.length}`);\n }\n }\n const args = argsInput.length === 0 ? [1] : argsInput;\n return args.map(argument => {\n const output = transform(argument);\n return typeof output === 'number' ? `${output}px` : output;\n }).join(' ');\n };\n spacing.mui = true;\n return spacing;\n}","import merge from './merge';\nfunction compose(...styles) {\n const handlers = styles.reduce((acc, style) => {\n style.filterProps.forEach(prop => {\n acc[prop] = style;\n });\n return acc;\n }, {});\n\n // false positive\n // eslint-disable-next-line react/function-component-definition\n const fn = props => {\n return Object.keys(props).reduce((acc, prop) => {\n if (handlers[prop]) {\n return merge(acc, handlers[prop](props));\n }\n return acc;\n }, {});\n };\n fn.propTypes = process.env.NODE_ENV !== 'production' ? styles.reduce((acc, style) => Object.assign(acc, style.propTypes), {}) : {};\n fn.filterProps = styles.reduce((acc, style) => acc.concat(style.filterProps), []);\n return fn;\n}\nexport default compose;","import responsivePropType from './responsivePropType';\nimport style from './style';\nimport compose from './compose';\nimport { createUnaryUnit, getValue } from './spacing';\nimport { handleBreakpoints } from './breakpoints';\nexport function borderTransform(value) {\n if (typeof value !== 'number') {\n return value;\n }\n return `${value}px solid`;\n}\nfunction createBorderStyle(prop, transform) {\n return style({\n prop,\n themeKey: 'borders',\n transform\n });\n}\nexport const border = createBorderStyle('border', borderTransform);\nexport const borderTop = createBorderStyle('borderTop', borderTransform);\nexport const borderRight = createBorderStyle('borderRight', borderTransform);\nexport const borderBottom = createBorderStyle('borderBottom', borderTransform);\nexport const borderLeft = createBorderStyle('borderLeft', borderTransform);\nexport const borderColor = createBorderStyle('borderColor');\nexport const borderTopColor = createBorderStyle('borderTopColor');\nexport const borderRightColor = createBorderStyle('borderRightColor');\nexport const borderBottomColor = createBorderStyle('borderBottomColor');\nexport const borderLeftColor = createBorderStyle('borderLeftColor');\nexport const outline = createBorderStyle('outline', borderTransform);\nexport const outlineColor = createBorderStyle('outlineColor');\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const borderRadius = props => {\n if (props.borderRadius !== undefined && props.borderRadius !== null) {\n const transformer = createUnaryUnit(props.theme, 'shape.borderRadius', 4, 'borderRadius');\n const styleFromPropValue = propValue => ({\n borderRadius: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.borderRadius, styleFromPropValue);\n }\n return null;\n};\nborderRadius.propTypes = process.env.NODE_ENV !== 'production' ? {\n borderRadius: responsivePropType\n} : {};\nborderRadius.filterProps = ['borderRadius'];\nconst borders = compose(border, borderTop, borderRight, borderBottom, borderLeft, borderColor, borderTopColor, borderRightColor, borderBottomColor, borderLeftColor, borderRadius, outline, outlineColor);\nexport default borders;","import style from './style';\nimport compose from './compose';\nimport { createUnaryUnit, getValue } from './spacing';\nimport { handleBreakpoints } from './breakpoints';\nimport responsivePropType from './responsivePropType';\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const gap = props => {\n if (props.gap !== undefined && props.gap !== null) {\n const transformer = createUnaryUnit(props.theme, 'spacing', 8, 'gap');\n const styleFromPropValue = propValue => ({\n gap: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.gap, styleFromPropValue);\n }\n return null;\n};\ngap.propTypes = process.env.NODE_ENV !== 'production' ? {\n gap: responsivePropType\n} : {};\ngap.filterProps = ['gap'];\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const columnGap = props => {\n if (props.columnGap !== undefined && props.columnGap !== null) {\n const transformer = createUnaryUnit(props.theme, 'spacing', 8, 'columnGap');\n const styleFromPropValue = propValue => ({\n columnGap: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.columnGap, styleFromPropValue);\n }\n return null;\n};\ncolumnGap.propTypes = process.env.NODE_ENV !== 'production' ? {\n columnGap: responsivePropType\n} : {};\ncolumnGap.filterProps = ['columnGap'];\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const rowGap = props => {\n if (props.rowGap !== undefined && props.rowGap !== null) {\n const transformer = createUnaryUnit(props.theme, 'spacing', 8, 'rowGap');\n const styleFromPropValue = propValue => ({\n rowGap: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.rowGap, styleFromPropValue);\n }\n return null;\n};\nrowGap.propTypes = process.env.NODE_ENV !== 'production' ? {\n rowGap: responsivePropType\n} : {};\nrowGap.filterProps = ['rowGap'];\nexport const gridColumn = style({\n prop: 'gridColumn'\n});\nexport const gridRow = style({\n prop: 'gridRow'\n});\nexport const gridAutoFlow = style({\n prop: 'gridAutoFlow'\n});\nexport const gridAutoColumns = style({\n prop: 'gridAutoColumns'\n});\nexport const gridAutoRows = style({\n prop: 'gridAutoRows'\n});\nexport const gridTemplateColumns = style({\n prop: 'gridTemplateColumns'\n});\nexport const gridTemplateRows = style({\n prop: 'gridTemplateRows'\n});\nexport const gridTemplateAreas = style({\n prop: 'gridTemplateAreas'\n});\nexport const gridArea = style({\n prop: 'gridArea'\n});\nconst grid = compose(gap, columnGap, rowGap, gridColumn, gridRow, gridAutoFlow, gridAutoColumns, gridAutoRows, gridTemplateColumns, gridTemplateRows, gridTemplateAreas, gridArea);\nexport default grid;","import style from './style';\nimport compose from './compose';\nexport function paletteTransform(value, userValue) {\n if (userValue === 'grey') {\n return userValue;\n }\n return value;\n}\nexport const color = style({\n prop: 'color',\n themeKey: 'palette',\n transform: paletteTransform\n});\nexport const bgcolor = style({\n prop: 'bgcolor',\n cssProperty: 'backgroundColor',\n themeKey: 'palette',\n transform: paletteTransform\n});\nexport const backgroundColor = style({\n prop: 'backgroundColor',\n themeKey: 'palette',\n transform: paletteTransform\n});\nconst palette = compose(color, bgcolor, backgroundColor);\nexport default palette;","import style from './style';\nimport compose from './compose';\nimport { handleBreakpoints, values as breakpointsValues } from './breakpoints';\nexport function sizingTransform(value) {\n return value <= 1 && value !== 0 ? `${value * 100}%` : value;\n}\nexport const width = style({\n prop: 'width',\n transform: sizingTransform\n});\nexport const maxWidth = props => {\n if (props.maxWidth !== undefined && props.maxWidth !== null) {\n const styleFromPropValue = propValue => {\n var _props$theme, _props$theme2;\n const breakpoint = ((_props$theme = props.theme) == null || (_props$theme = _props$theme.breakpoints) == null || (_props$theme = _props$theme.values) == null ? void 0 : _props$theme[propValue]) || breakpointsValues[propValue];\n if (!breakpoint) {\n return {\n maxWidth: sizingTransform(propValue)\n };\n }\n if (((_props$theme2 = props.theme) == null || (_props$theme2 = _props$theme2.breakpoints) == null ? void 0 : _props$theme2.unit) !== 'px') {\n return {\n maxWidth: `${breakpoint}${props.theme.breakpoints.unit}`\n };\n }\n return {\n maxWidth: breakpoint\n };\n };\n return handleBreakpoints(props, props.maxWidth, styleFromPropValue);\n }\n return null;\n};\nmaxWidth.filterProps = ['maxWidth'];\nexport const minWidth = style({\n prop: 'minWidth',\n transform: sizingTransform\n});\nexport const height = style({\n prop: 'height',\n transform: sizingTransform\n});\nexport const maxHeight = style({\n prop: 'maxHeight',\n transform: sizingTransform\n});\nexport const minHeight = style({\n prop: 'minHeight',\n transform: sizingTransform\n});\nexport const sizeWidth = style({\n prop: 'size',\n cssProperty: 'width',\n transform: sizingTransform\n});\nexport const sizeHeight = style({\n prop: 'size',\n cssProperty: 'height',\n transform: sizingTransform\n});\nexport const boxSizing = style({\n prop: 'boxSizing'\n});\nconst sizing = compose(width, maxWidth, minWidth, height, maxHeight, minHeight, boxSizing);\nexport default sizing;","import { padding, margin } from '../spacing';\nimport { borderRadius, borderTransform } from '../borders';\nimport { gap, rowGap, columnGap } from '../cssGrid';\nimport { paletteTransform } from '../palette';\nimport { maxWidth, sizingTransform } from '../sizing';\nconst defaultSxConfig = {\n // borders\n border: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderTop: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderRight: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderBottom: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderLeft: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderColor: {\n themeKey: 'palette'\n },\n borderTopColor: {\n themeKey: 'palette'\n },\n borderRightColor: {\n themeKey: 'palette'\n },\n borderBottomColor: {\n themeKey: 'palette'\n },\n borderLeftColor: {\n themeKey: 'palette'\n },\n outline: {\n themeKey: 'borders',\n transform: borderTransform\n },\n outlineColor: {\n themeKey: 'palette'\n },\n borderRadius: {\n themeKey: 'shape.borderRadius',\n style: borderRadius\n },\n // palette\n color: {\n themeKey: 'palette',\n transform: paletteTransform\n },\n bgcolor: {\n themeKey: 'palette',\n cssProperty: 'backgroundColor',\n transform: paletteTransform\n },\n backgroundColor: {\n themeKey: 'palette',\n transform: paletteTransform\n },\n // spacing\n p: {\n style: padding\n },\n pt: {\n style: padding\n },\n pr: {\n style: padding\n },\n pb: {\n style: padding\n },\n pl: {\n style: padding\n },\n px: {\n style: padding\n },\n py: {\n style: padding\n },\n padding: {\n style: padding\n },\n paddingTop: {\n style: padding\n },\n paddingRight: {\n style: padding\n },\n paddingBottom: {\n style: padding\n },\n paddingLeft: {\n style: padding\n },\n paddingX: {\n style: padding\n },\n paddingY: {\n style: padding\n },\n paddingInline: {\n style: padding\n },\n paddingInlineStart: {\n style: padding\n },\n paddingInlineEnd: {\n style: padding\n },\n paddingBlock: {\n style: padding\n },\n paddingBlockStart: {\n style: padding\n },\n paddingBlockEnd: {\n style: padding\n },\n m: {\n style: margin\n },\n mt: {\n style: margin\n },\n mr: {\n style: margin\n },\n mb: {\n style: margin\n },\n ml: {\n style: margin\n },\n mx: {\n style: margin\n },\n my: {\n style: margin\n },\n margin: {\n style: margin\n },\n marginTop: {\n style: margin\n },\n marginRight: {\n style: margin\n },\n marginBottom: {\n style: margin\n },\n marginLeft: {\n style: margin\n },\n marginX: {\n style: margin\n },\n marginY: {\n style: margin\n },\n marginInline: {\n style: margin\n },\n marginInlineStart: {\n style: margin\n },\n marginInlineEnd: {\n style: margin\n },\n marginBlock: {\n style: margin\n },\n marginBlockStart: {\n style: margin\n },\n marginBlockEnd: {\n style: margin\n },\n // display\n displayPrint: {\n cssProperty: false,\n transform: value => ({\n '@media print': {\n display: value\n }\n })\n },\n display: {},\n overflow: {},\n textOverflow: {},\n visibility: {},\n whiteSpace: {},\n // flexbox\n flexBasis: {},\n flexDirection: {},\n flexWrap: {},\n justifyContent: {},\n alignItems: {},\n alignContent: {},\n order: {},\n flex: {},\n flexGrow: {},\n flexShrink: {},\n alignSelf: {},\n justifyItems: {},\n justifySelf: {},\n // grid\n gap: {\n style: gap\n },\n rowGap: {\n style: rowGap\n },\n columnGap: {\n style: columnGap\n },\n gridColumn: {},\n gridRow: {},\n gridAutoFlow: {},\n gridAutoColumns: {},\n gridAutoRows: {},\n gridTemplateColumns: {},\n gridTemplateRows: {},\n gridTemplateAreas: {},\n gridArea: {},\n // positions\n position: {},\n zIndex: {\n themeKey: 'zIndex'\n },\n top: {},\n right: {},\n bottom: {},\n left: {},\n // shadows\n boxShadow: {\n themeKey: 'shadows'\n },\n // sizing\n width: {\n transform: sizingTransform\n },\n maxWidth: {\n style: maxWidth\n },\n minWidth: {\n transform: sizingTransform\n },\n height: {\n transform: sizingTransform\n },\n maxHeight: {\n transform: sizingTransform\n },\n minHeight: {\n transform: sizingTransform\n },\n boxSizing: {},\n // typography\n fontFamily: {\n themeKey: 'typography'\n },\n fontSize: {\n themeKey: 'typography'\n },\n fontStyle: {\n themeKey: 'typography'\n },\n fontWeight: {\n themeKey: 'typography'\n },\n letterSpacing: {},\n textTransform: {},\n lineHeight: {},\n textAlign: {},\n typography: {\n cssProperty: false,\n themeKey: 'typography'\n }\n};\nexport default defaultSxConfig;","import capitalize from '@mui/utils/capitalize';\nimport merge from '../merge';\nimport { getPath, getStyleValue as getValue } from '../style';\nimport { handleBreakpoints, createEmptyBreakpointObject, removeUnusedBreakpoints } from '../breakpoints';\nimport defaultSxConfig from './defaultSxConfig';\nfunction objectsHaveSameKeys(...objects) {\n const allKeys = objects.reduce((keys, object) => keys.concat(Object.keys(object)), []);\n const union = new Set(allKeys);\n return objects.every(object => union.size === Object.keys(object).length);\n}\nfunction callIfFn(maybeFn, arg) {\n return typeof maybeFn === 'function' ? maybeFn(arg) : maybeFn;\n}\n\n// eslint-disable-next-line @typescript-eslint/naming-convention\nexport function unstable_createStyleFunctionSx() {\n function getThemeValue(prop, val, theme, config) {\n const props = {\n [prop]: val,\n theme\n };\n const options = config[prop];\n if (!options) {\n return {\n [prop]: val\n };\n }\n const {\n cssProperty = prop,\n themeKey,\n transform,\n style\n } = options;\n if (val == null) {\n return null;\n }\n\n // TODO v6: remove, see https://github.com/mui/material-ui/pull/38123\n if (themeKey === 'typography' && val === 'inherit') {\n return {\n [prop]: val\n };\n }\n const themeMapping = getPath(theme, themeKey) || {};\n if (style) {\n return style(props);\n }\n const styleFromPropValue = propValueFinal => {\n let value = getValue(themeMapping, transform, propValueFinal);\n if (propValueFinal === value && typeof propValueFinal === 'string') {\n // Haven't found value\n value = getValue(themeMapping, transform, `${prop}${propValueFinal === 'default' ? '' : capitalize(propValueFinal)}`, propValueFinal);\n }\n if (cssProperty === false) {\n return value;\n }\n return {\n [cssProperty]: value\n };\n };\n return handleBreakpoints(props, val, styleFromPropValue);\n }\n function styleFunctionSx(props) {\n var _theme$unstable_sxCon;\n const {\n sx,\n theme = {}\n } = props || {};\n if (!sx) {\n return null; // Emotion & styled-components will neglect null\n }\n const config = (_theme$unstable_sxCon = theme.unstable_sxConfig) != null ? _theme$unstable_sxCon : defaultSxConfig;\n\n /*\n * Receive `sxInput` as object or callback\n * and then recursively check keys & values to create media query object styles.\n * (the result will be used in `styled`)\n */\n function traverse(sxInput) {\n let sxObject = sxInput;\n if (typeof sxInput === 'function') {\n sxObject = sxInput(theme);\n } else if (typeof sxInput !== 'object') {\n // value\n return sxInput;\n }\n if (!sxObject) {\n return null;\n }\n const emptyBreakpoints = createEmptyBreakpointObject(theme.breakpoints);\n const breakpointsKeys = Object.keys(emptyBreakpoints);\n let css = emptyBreakpoints;\n Object.keys(sxObject).forEach(styleKey => {\n const value = callIfFn(sxObject[styleKey], theme);\n if (value !== null && value !== undefined) {\n if (typeof value === 'object') {\n if (config[styleKey]) {\n css = merge(css, getThemeValue(styleKey, value, theme, config));\n } else {\n const breakpointsValues = handleBreakpoints({\n theme\n }, value, x => ({\n [styleKey]: x\n }));\n if (objectsHaveSameKeys(breakpointsValues, value)) {\n css[styleKey] = styleFunctionSx({\n sx: value,\n theme\n });\n } else {\n css = merge(css, breakpointsValues);\n }\n }\n } else {\n css = merge(css, getThemeValue(styleKey, value, theme, config));\n }\n }\n });\n return removeUnusedBreakpoints(breakpointsKeys, css);\n }\n return Array.isArray(sx) ? sx.map(traverse) : traverse(sx);\n }\n return styleFunctionSx;\n}\nconst styleFunctionSx = unstable_createStyleFunctionSx();\nstyleFunctionSx.filterProps = ['sx'];\nexport default styleFunctionSx;","/**\n * A universal utility to style components with multiple color modes. Always use it from the theme object.\n * It works with:\n * - [Basic theme](https://mui.com/material-ui/customization/dark-mode/)\n * - [CSS theme variables](https://mui.com/material-ui/experimental-api/css-theme-variables/overview/)\n * - Zero-runtime engine\n *\n * Tips: Use an array over object spread and place `theme.applyStyles()` last.\n *\n * ✅ [{ background: '#e5e5e5' }, theme.applyStyles('dark', { background: '#1c1c1c' })]\n *\n * 🚫 { background: '#e5e5e5', ...theme.applyStyles('dark', { background: '#1c1c1c' })}\n *\n * @example\n * 1. using with `styled`:\n * ```jsx\n * const Component = styled('div')(({ theme }) => [\n * { background: '#e5e5e5' },\n * theme.applyStyles('dark', {\n * background: '#1c1c1c',\n * color: '#fff',\n * }),\n * ]);\n * ```\n *\n * @example\n * 2. using with `sx` prop:\n * ```jsx\n * [\n * { background: '#e5e5e5' },\n * theme.applyStyles('dark', {\n * background: '#1c1c1c',\n * color: '#fff',\n * }),\n * ]}\n * />\n * ```\n *\n * @example\n * 3. theming a component:\n * ```jsx\n * extendTheme({\n * components: {\n * MuiButton: {\n * styleOverrides: {\n * root: ({ theme }) => [\n * { background: '#e5e5e5' },\n * theme.applyStyles('dark', {\n * background: '#1c1c1c',\n * color: '#fff',\n * }),\n * ],\n * },\n * }\n * }\n * })\n *```\n */\nexport default function applyStyles(key, styles) {\n // @ts-expect-error this is 'any' type\n const theme = this;\n if (theme.vars && typeof theme.getColorSchemeSelector === 'function') {\n // If CssVarsProvider is used as a provider,\n // returns '* :where([data-mui-color-scheme=\"light|dark\"]) &'\n const selector = theme.getColorSchemeSelector(key).replace(/(\\[[^\\]]+\\])/, '*:where($1)');\n return {\n [selector]: styles\n };\n }\n if (theme.palette.mode === key) {\n return styles;\n }\n return {};\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"breakpoints\", \"palette\", \"spacing\", \"shape\"];\nimport deepmerge from '@mui/utils/deepmerge';\nimport createBreakpoints from './createBreakpoints';\nimport shape from './shape';\nimport createSpacing from './createSpacing';\nimport styleFunctionSx from '../styleFunctionSx/styleFunctionSx';\nimport defaultSxConfig from '../styleFunctionSx/defaultSxConfig';\nimport applyStyles from './applyStyles';\nfunction createTheme(options = {}, ...args) {\n const {\n breakpoints: breakpointsInput = {},\n palette: paletteInput = {},\n spacing: spacingInput,\n shape: shapeInput = {}\n } = options,\n other = _objectWithoutPropertiesLoose(options, _excluded);\n const breakpoints = createBreakpoints(breakpointsInput);\n const spacing = createSpacing(spacingInput);\n let muiTheme = deepmerge({\n breakpoints,\n direction: 'ltr',\n components: {},\n // Inject component definitions.\n palette: _extends({\n mode: 'light'\n }, paletteInput),\n spacing,\n shape: _extends({}, shape, shapeInput)\n }, other);\n muiTheme.applyStyles = applyStyles;\n muiTheme = args.reduce((acc, argument) => deepmerge(acc, argument), muiTheme);\n muiTheme.unstable_sxConfig = _extends({}, defaultSxConfig, other == null ? void 0 : other.unstable_sxConfig);\n muiTheme.unstable_sx = function sx(props) {\n return styleFunctionSx({\n sx: props,\n theme: this\n });\n };\n return muiTheme;\n}\nexport default createTheme;","'use client';\n\nimport * as React from 'react';\nimport { ThemeContext } from '@mui/styled-engine';\nfunction isObjectEmpty(obj) {\n return Object.keys(obj).length === 0;\n}\nfunction useTheme(defaultTheme = null) {\n const contextTheme = React.useContext(ThemeContext);\n return !contextTheme || isObjectEmpty(contextTheme) ? defaultTheme : contextTheme;\n}\nexport default useTheme;","'use client';\n\nimport createTheme from './createTheme';\nimport useThemeWithoutDefault from './useThemeWithoutDefault';\nexport const systemDefaultTheme = createTheme();\nfunction useTheme(defaultTheme = systemDefaultTheme) {\n return useThemeWithoutDefault(defaultTheme);\n}\nexport default useTheme;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"ownerState\"],\n _excluded2 = [\"variants\"],\n _excluded3 = [\"name\", \"slot\", \"skipVariantsResolver\", \"skipSx\", \"overridesResolver\"];\n/* eslint-disable no-underscore-dangle */\nimport styledEngineStyled, { internal_processStyles as processStyles } from '@mui/styled-engine';\nimport { isPlainObject } from '@mui/utils/deepmerge';\nimport capitalize from '@mui/utils/capitalize';\nimport getDisplayName from '@mui/utils/getDisplayName';\nimport createTheme from './createTheme';\nimport styleFunctionSx from './styleFunctionSx';\nfunction isEmpty(obj) {\n return Object.keys(obj).length === 0;\n}\n\n// https://github.com/emotion-js/emotion/blob/26ded6109fcd8ca9875cc2ce4564fee678a3f3c5/packages/styled/src/utils.js#L40\nfunction isStringTag(tag) {\n return typeof tag === 'string' &&\n // 96 is one less than the char code\n // for \"a\" so this is checking that\n // it's a lowercase character\n tag.charCodeAt(0) > 96;\n}\n\n// Update /system/styled/#api in case if this changes\nexport function shouldForwardProp(prop) {\n return prop !== 'ownerState' && prop !== 'theme' && prop !== 'sx' && prop !== 'as';\n}\nexport const systemDefaultTheme = createTheme();\nconst lowercaseFirstLetter = string => {\n if (!string) {\n return string;\n }\n return string.charAt(0).toLowerCase() + string.slice(1);\n};\nfunction resolveTheme({\n defaultTheme,\n theme,\n themeId\n}) {\n return isEmpty(theme) ? defaultTheme : theme[themeId] || theme;\n}\nfunction defaultOverridesResolver(slot) {\n if (!slot) {\n return null;\n }\n return (props, styles) => styles[slot];\n}\nfunction processStyleArg(callableStyle, _ref) {\n let {\n ownerState\n } = _ref,\n props = _objectWithoutPropertiesLoose(_ref, _excluded);\n const resolvedStylesArg = typeof callableStyle === 'function' ? callableStyle(_extends({\n ownerState\n }, props)) : callableStyle;\n if (Array.isArray(resolvedStylesArg)) {\n return resolvedStylesArg.flatMap(resolvedStyle => processStyleArg(resolvedStyle, _extends({\n ownerState\n }, props)));\n }\n if (!!resolvedStylesArg && typeof resolvedStylesArg === 'object' && Array.isArray(resolvedStylesArg.variants)) {\n const {\n variants = []\n } = resolvedStylesArg,\n otherStyles = _objectWithoutPropertiesLoose(resolvedStylesArg, _excluded2);\n let result = otherStyles;\n variants.forEach(variant => {\n let isMatch = true;\n if (typeof variant.props === 'function') {\n isMatch = variant.props(_extends({\n ownerState\n }, props, ownerState));\n } else {\n Object.keys(variant.props).forEach(key => {\n if ((ownerState == null ? void 0 : ownerState[key]) !== variant.props[key] && props[key] !== variant.props[key]) {\n isMatch = false;\n }\n });\n }\n if (isMatch) {\n if (!Array.isArray(result)) {\n result = [result];\n }\n result.push(typeof variant.style === 'function' ? variant.style(_extends({\n ownerState\n }, props, ownerState)) : variant.style);\n }\n });\n return result;\n }\n return resolvedStylesArg;\n}\nexport default function createStyled(input = {}) {\n const {\n themeId,\n defaultTheme = systemDefaultTheme,\n rootShouldForwardProp = shouldForwardProp,\n slotShouldForwardProp = shouldForwardProp\n } = input;\n const systemSx = props => {\n return styleFunctionSx(_extends({}, props, {\n theme: resolveTheme(_extends({}, props, {\n defaultTheme,\n themeId\n }))\n }));\n };\n systemSx.__mui_systemSx = true;\n return (tag, inputOptions = {}) => {\n // Filter out the `sx` style function from the previous styled component to prevent unnecessary styles generated by the composite components.\n processStyles(tag, styles => styles.filter(style => !(style != null && style.__mui_systemSx)));\n const {\n name: componentName,\n slot: componentSlot,\n skipVariantsResolver: inputSkipVariantsResolver,\n skipSx: inputSkipSx,\n // TODO v6: remove `lowercaseFirstLetter()` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n overridesResolver = defaultOverridesResolver(lowercaseFirstLetter(componentSlot))\n } = inputOptions,\n options = _objectWithoutPropertiesLoose(inputOptions, _excluded3);\n\n // if skipVariantsResolver option is defined, take the value, otherwise, true for root and false for other slots.\n const skipVariantsResolver = inputSkipVariantsResolver !== undefined ? inputSkipVariantsResolver :\n // TODO v6: remove `Root` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n componentSlot && componentSlot !== 'Root' && componentSlot !== 'root' || false;\n const skipSx = inputSkipSx || false;\n let label;\n if (process.env.NODE_ENV !== 'production') {\n if (componentName) {\n // TODO v6: remove `lowercaseFirstLetter()` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n label = `${componentName}-${lowercaseFirstLetter(componentSlot || 'Root')}`;\n }\n }\n let shouldForwardPropOption = shouldForwardProp;\n\n // TODO v6: remove `Root` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n if (componentSlot === 'Root' || componentSlot === 'root') {\n shouldForwardPropOption = rootShouldForwardProp;\n } else if (componentSlot) {\n // any other slot specified\n shouldForwardPropOption = slotShouldForwardProp;\n } else if (isStringTag(tag)) {\n // for string (html) tag, preserve the behavior in emotion & styled-components.\n shouldForwardPropOption = undefined;\n }\n const defaultStyledResolver = styledEngineStyled(tag, _extends({\n shouldForwardProp: shouldForwardPropOption,\n label\n }, options));\n const transformStyleArg = stylesArg => {\n // On the server Emotion doesn't use React.forwardRef for creating components, so the created\n // component stays as a function. This condition makes sure that we do not interpolate functions\n // which are basically components used as a selectors.\n if (typeof stylesArg === 'function' && stylesArg.__emotion_real !== stylesArg || isPlainObject(stylesArg)) {\n return props => processStyleArg(stylesArg, _extends({}, props, {\n theme: resolveTheme({\n theme: props.theme,\n defaultTheme,\n themeId\n })\n }));\n }\n return stylesArg;\n };\n const muiStyledResolver = (styleArg, ...expressions) => {\n let transformedStyleArg = transformStyleArg(styleArg);\n const expressionsWithDefaultTheme = expressions ? expressions.map(transformStyleArg) : [];\n if (componentName && overridesResolver) {\n expressionsWithDefaultTheme.push(props => {\n const theme = resolveTheme(_extends({}, props, {\n defaultTheme,\n themeId\n }));\n if (!theme.components || !theme.components[componentName] || !theme.components[componentName].styleOverrides) {\n return null;\n }\n const styleOverrides = theme.components[componentName].styleOverrides;\n const resolvedStyleOverrides = {};\n // TODO: v7 remove iteration and use `resolveStyleArg(styleOverrides[slot])` directly\n Object.entries(styleOverrides).forEach(([slotKey, slotStyle]) => {\n resolvedStyleOverrides[slotKey] = processStyleArg(slotStyle, _extends({}, props, {\n theme\n }));\n });\n return overridesResolver(props, resolvedStyleOverrides);\n });\n }\n if (componentName && !skipVariantsResolver) {\n expressionsWithDefaultTheme.push(props => {\n var _theme$components;\n const theme = resolveTheme(_extends({}, props, {\n defaultTheme,\n themeId\n }));\n const themeVariants = theme == null || (_theme$components = theme.components) == null || (_theme$components = _theme$components[componentName]) == null ? void 0 : _theme$components.variants;\n return processStyleArg({\n variants: themeVariants\n }, _extends({}, props, {\n theme\n }));\n });\n }\n if (!skipSx) {\n expressionsWithDefaultTheme.push(systemSx);\n }\n const numOfCustomFnsApplied = expressionsWithDefaultTheme.length - expressions.length;\n if (Array.isArray(styleArg) && numOfCustomFnsApplied > 0) {\n const placeholders = new Array(numOfCustomFnsApplied).fill('');\n // If the type is array, than we need to add placeholders in the template for the overrides, variants and the sx styles.\n transformedStyleArg = [...styleArg, ...placeholders];\n transformedStyleArg.raw = [...styleArg.raw, ...placeholders];\n }\n const Component = defaultStyledResolver(transformedStyleArg, ...expressionsWithDefaultTheme);\n if (process.env.NODE_ENV !== 'production') {\n let displayName;\n if (componentName) {\n displayName = `${componentName}${capitalize(componentSlot || '')}`;\n }\n if (displayName === undefined) {\n displayName = `Styled(${getDisplayName(tag)})`;\n }\n Component.displayName = displayName;\n }\n if (tag.muiName) {\n Component.muiName = tag.muiName;\n }\n return Component;\n };\n if (defaultStyledResolver.withConfig) {\n muiStyledResolver.withConfig = defaultStyledResolver.withConfig;\n }\n return muiStyledResolver;\n };\n}","import resolveProps from '@mui/utils/resolveProps';\nexport default function getThemeProps(params) {\n const {\n theme,\n name,\n props\n } = params;\n if (!theme || !theme.components || !theme.components[name] || !theme.components[name].defaultProps) {\n return props;\n }\n return resolveProps(theme.components[name].defaultProps, props);\n}","'use client';\n\nimport getThemeProps from './getThemeProps';\nimport useTheme from '../useTheme';\nexport default function useThemeProps({\n props,\n name,\n defaultTheme,\n themeId\n}) {\n let theme = useTheme(defaultTheme);\n if (themeId) {\n theme = theme[themeId] || theme;\n }\n const mergedProps = getThemeProps({\n theme,\n name,\n props\n });\n return mergedProps;\n}","import _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\n/* eslint-disable @typescript-eslint/naming-convention */\nimport clamp from '@mui/utils/clamp';\n/**\n * Returns a number whose value is limited to the given range.\n * @param {number} value The value to be clamped\n * @param {number} min The lower boundary of the output range\n * @param {number} max The upper boundary of the output range\n * @returns {number} A number in the range [min, max]\n */\nfunction clampWrapper(value, min = 0, max = 1) {\n if (process.env.NODE_ENV !== 'production') {\n if (value < min || value > max) {\n console.error(`MUI: The value provided ${value} is out of range [${min}, ${max}].`);\n }\n }\n return clamp(value, min, max);\n}\n\n/**\n * Converts a color from CSS hex format to CSS rgb format.\n * @param {string} color - Hex color, i.e. #nnn or #nnnnnn\n * @returns {string} A CSS rgb color string\n */\nexport function hexToRgb(color) {\n color = color.slice(1);\n const re = new RegExp(`.{1,${color.length >= 6 ? 2 : 1}}`, 'g');\n let colors = color.match(re);\n if (colors && colors[0].length === 1) {\n colors = colors.map(n => n + n);\n }\n return colors ? `rgb${colors.length === 4 ? 'a' : ''}(${colors.map((n, index) => {\n return index < 3 ? parseInt(n, 16) : Math.round(parseInt(n, 16) / 255 * 1000) / 1000;\n }).join(', ')})` : '';\n}\nfunction intToHex(int) {\n const hex = int.toString(16);\n return hex.length === 1 ? `0${hex}` : hex;\n}\n\n/**\n * Returns an object with the type and values of a color.\n *\n * Note: Does not support rgb % values.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @returns {object} - A MUI color object: {type: string, values: number[]}\n */\nexport function decomposeColor(color) {\n // Idempotent\n if (color.type) {\n return color;\n }\n if (color.charAt(0) === '#') {\n return decomposeColor(hexToRgb(color));\n }\n const marker = color.indexOf('(');\n const type = color.substring(0, marker);\n if (['rgb', 'rgba', 'hsl', 'hsla', 'color'].indexOf(type) === -1) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: Unsupported \\`${color}\\` color.\nThe following formats are supported: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color().` : _formatMuiErrorMessage(9, color));\n }\n let values = color.substring(marker + 1, color.length - 1);\n let colorSpace;\n if (type === 'color') {\n values = values.split(' ');\n colorSpace = values.shift();\n if (values.length === 4 && values[3].charAt(0) === '/') {\n values[3] = values[3].slice(1);\n }\n if (['srgb', 'display-p3', 'a98-rgb', 'prophoto-rgb', 'rec-2020'].indexOf(colorSpace) === -1) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: unsupported \\`${colorSpace}\\` color space.\nThe following color spaces are supported: srgb, display-p3, a98-rgb, prophoto-rgb, rec-2020.` : _formatMuiErrorMessage(10, colorSpace));\n }\n } else {\n values = values.split(',');\n }\n values = values.map(value => parseFloat(value));\n return {\n type,\n values,\n colorSpace\n };\n}\n\n/**\n * Returns a channel created from the input color.\n *\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @returns {string} - The channel for the color, that can be used in rgba or hsla colors\n */\nexport const colorChannel = color => {\n const decomposedColor = decomposeColor(color);\n return decomposedColor.values.slice(0, 3).map((val, idx) => decomposedColor.type.indexOf('hsl') !== -1 && idx !== 0 ? `${val}%` : val).join(' ');\n};\nexport const private_safeColorChannel = (color, warning) => {\n try {\n return colorChannel(color);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n};\n\n/**\n * Converts a color object with type and values to a string.\n * @param {object} color - Decomposed color\n * @param {string} color.type - One of: 'rgb', 'rgba', 'hsl', 'hsla', 'color'\n * @param {array} color.values - [n,n,n] or [n,n,n,n]\n * @returns {string} A CSS color string\n */\nexport function recomposeColor(color) {\n const {\n type,\n colorSpace\n } = color;\n let {\n values\n } = color;\n if (type.indexOf('rgb') !== -1) {\n // Only convert the first 3 values to int (i.e. not alpha)\n values = values.map((n, i) => i < 3 ? parseInt(n, 10) : n);\n } else if (type.indexOf('hsl') !== -1) {\n values[1] = `${values[1]}%`;\n values[2] = `${values[2]}%`;\n }\n if (type.indexOf('color') !== -1) {\n values = `${colorSpace} ${values.join(' ')}`;\n } else {\n values = `${values.join(', ')}`;\n }\n return `${type}(${values})`;\n}\n\n/**\n * Converts a color from CSS rgb format to CSS hex format.\n * @param {string} color - RGB color, i.e. rgb(n, n, n)\n * @returns {string} A CSS rgb color string, i.e. #nnnnnn\n */\nexport function rgbToHex(color) {\n // Idempotent\n if (color.indexOf('#') === 0) {\n return color;\n }\n const {\n values\n } = decomposeColor(color);\n return `#${values.map((n, i) => intToHex(i === 3 ? Math.round(255 * n) : n)).join('')}`;\n}\n\n/**\n * Converts a color from hsl format to rgb format.\n * @param {string} color - HSL color values\n * @returns {string} rgb color values\n */\nexport function hslToRgb(color) {\n color = decomposeColor(color);\n const {\n values\n } = color;\n const h = values[0];\n const s = values[1] / 100;\n const l = values[2] / 100;\n const a = s * Math.min(l, 1 - l);\n const f = (n, k = (n + h / 30) % 12) => l - a * Math.max(Math.min(k - 3, 9 - k, 1), -1);\n let type = 'rgb';\n const rgb = [Math.round(f(0) * 255), Math.round(f(8) * 255), Math.round(f(4) * 255)];\n if (color.type === 'hsla') {\n type += 'a';\n rgb.push(values[3]);\n }\n return recomposeColor({\n type,\n values: rgb\n });\n}\n/**\n * The relative brightness of any point in a color space,\n * normalized to 0 for darkest black and 1 for lightest white.\n *\n * Formula: https://www.w3.org/TR/WCAG20-TECHS/G17.html#G17-tests\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @returns {number} The relative brightness of the color in the range 0 - 1\n */\nexport function getLuminance(color) {\n color = decomposeColor(color);\n let rgb = color.type === 'hsl' || color.type === 'hsla' ? decomposeColor(hslToRgb(color)).values : color.values;\n rgb = rgb.map(val => {\n if (color.type !== 'color') {\n val /= 255; // normalized\n }\n return val <= 0.03928 ? val / 12.92 : ((val + 0.055) / 1.055) ** 2.4;\n });\n\n // Truncate at 3 digits\n return Number((0.2126 * rgb[0] + 0.7152 * rgb[1] + 0.0722 * rgb[2]).toFixed(3));\n}\n\n/**\n * Calculates the contrast ratio between two colors.\n *\n * Formula: https://www.w3.org/TR/WCAG20-TECHS/G17.html#G17-tests\n * @param {string} foreground - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla()\n * @param {string} background - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla()\n * @returns {number} A contrast ratio value in the range 0 - 21.\n */\nexport function getContrastRatio(foreground, background) {\n const lumA = getLuminance(foreground);\n const lumB = getLuminance(background);\n return (Math.max(lumA, lumB) + 0.05) / (Math.min(lumA, lumB) + 0.05);\n}\n\n/**\n * Sets the absolute transparency of a color.\n * Any existing alpha values are overwritten.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} value - value to set the alpha channel to in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function alpha(color, value) {\n color = decomposeColor(color);\n value = clampWrapper(value);\n if (color.type === 'rgb' || color.type === 'hsl') {\n color.type += 'a';\n }\n if (color.type === 'color') {\n color.values[3] = `/${value}`;\n } else {\n color.values[3] = value;\n }\n return recomposeColor(color);\n}\nexport function private_safeAlpha(color, value, warning) {\n try {\n return alpha(color, value);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Darkens a color.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} coefficient - multiplier in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function darken(color, coefficient) {\n color = decomposeColor(color);\n coefficient = clampWrapper(coefficient);\n if (color.type.indexOf('hsl') !== -1) {\n color.values[2] *= 1 - coefficient;\n } else if (color.type.indexOf('rgb') !== -1 || color.type.indexOf('color') !== -1) {\n for (let i = 0; i < 3; i += 1) {\n color.values[i] *= 1 - coefficient;\n }\n }\n return recomposeColor(color);\n}\nexport function private_safeDarken(color, coefficient, warning) {\n try {\n return darken(color, coefficient);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Lightens a color.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} coefficient - multiplier in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function lighten(color, coefficient) {\n color = decomposeColor(color);\n coefficient = clampWrapper(coefficient);\n if (color.type.indexOf('hsl') !== -1) {\n color.values[2] += (100 - color.values[2]) * coefficient;\n } else if (color.type.indexOf('rgb') !== -1) {\n for (let i = 0; i < 3; i += 1) {\n color.values[i] += (255 - color.values[i]) * coefficient;\n }\n } else if (color.type.indexOf('color') !== -1) {\n for (let i = 0; i < 3; i += 1) {\n color.values[i] += (1 - color.values[i]) * coefficient;\n }\n }\n return recomposeColor(color);\n}\nexport function private_safeLighten(color, coefficient, warning) {\n try {\n return lighten(color, coefficient);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Darken or lighten a color, depending on its luminance.\n * Light colors are darkened, dark colors are lightened.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} coefficient=0.15 - multiplier in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function emphasize(color, coefficient = 0.15) {\n return getLuminance(color) > 0.5 ? darken(color, coefficient) : lighten(color, coefficient);\n}\nexport function private_safeEmphasize(color, coefficient, warning) {\n try {\n return emphasize(color, coefficient);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Blend a transparent overlay color with a background color, resulting in a single\n * RGB color.\n * @param {string} background - CSS color\n * @param {string} overlay - CSS color\n * @param {number} opacity - Opacity multiplier in the range 0 - 1\n * @param {number} [gamma=1.0] - Gamma correction factor. For gamma-correct blending, 2.2 is usual.\n */\nexport function blend(background, overlay, opacity, gamma = 1.0) {\n const blendChannel = (b, o) => Math.round((b ** (1 / gamma) * (1 - opacity) + o ** (1 / gamma) * opacity) ** gamma);\n const backgroundColor = decomposeColor(background);\n const overlayColor = decomposeColor(overlay);\n const rgb = [blendChannel(backgroundColor.values[0], overlayColor.values[0]), blendChannel(backgroundColor.values[1], overlayColor.values[1]), blendChannel(backgroundColor.values[2], overlayColor.values[2])];\n return recomposeColor({\n type: 'rgb',\n values: rgb\n });\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nexport default function createMixins(breakpoints, mixins) {\n return _extends({\n toolbar: {\n minHeight: 56,\n [breakpoints.up('xs')]: {\n '@media (orientation: landscape)': {\n minHeight: 48\n }\n },\n [breakpoints.up('sm')]: {\n minHeight: 64\n }\n }\n }, mixins);\n}","const common = {\n black: '#000',\n white: '#fff'\n};\nexport default common;","const grey = {\n 50: '#fafafa',\n 100: '#f5f5f5',\n 200: '#eeeeee',\n 300: '#e0e0e0',\n 400: '#bdbdbd',\n 500: '#9e9e9e',\n 600: '#757575',\n 700: '#616161',\n 800: '#424242',\n 900: '#212121',\n A100: '#f5f5f5',\n A200: '#eeeeee',\n A400: '#bdbdbd',\n A700: '#616161'\n};\nexport default grey;","const purple = {\n 50: '#f3e5f5',\n 100: '#e1bee7',\n 200: '#ce93d8',\n 300: '#ba68c8',\n 400: '#ab47bc',\n 500: '#9c27b0',\n 600: '#8e24aa',\n 700: '#7b1fa2',\n 800: '#6a1b9a',\n 900: '#4a148c',\n A100: '#ea80fc',\n A200: '#e040fb',\n A400: '#d500f9',\n A700: '#aa00ff'\n};\nexport default purple;","const red = {\n 50: '#ffebee',\n 100: '#ffcdd2',\n 200: '#ef9a9a',\n 300: '#e57373',\n 400: '#ef5350',\n 500: '#f44336',\n 600: '#e53935',\n 700: '#d32f2f',\n 800: '#c62828',\n 900: '#b71c1c',\n A100: '#ff8a80',\n A200: '#ff5252',\n A400: '#ff1744',\n A700: '#d50000'\n};\nexport default red;","const orange = {\n 50: '#fff3e0',\n 100: '#ffe0b2',\n 200: '#ffcc80',\n 300: '#ffb74d',\n 400: '#ffa726',\n 500: '#ff9800',\n 600: '#fb8c00',\n 700: '#f57c00',\n 800: '#ef6c00',\n 900: '#e65100',\n A100: '#ffd180',\n A200: '#ffab40',\n A400: '#ff9100',\n A700: '#ff6d00'\n};\nexport default orange;","const blue = {\n 50: '#e3f2fd',\n 100: '#bbdefb',\n 200: '#90caf9',\n 300: '#64b5f6',\n 400: '#42a5f5',\n 500: '#2196f3',\n 600: '#1e88e5',\n 700: '#1976d2',\n 800: '#1565c0',\n 900: '#0d47a1',\n A100: '#82b1ff',\n A200: '#448aff',\n A400: '#2979ff',\n A700: '#2962ff'\n};\nexport default blue;","const lightBlue = {\n 50: '#e1f5fe',\n 100: '#b3e5fc',\n 200: '#81d4fa',\n 300: '#4fc3f7',\n 400: '#29b6f6',\n 500: '#03a9f4',\n 600: '#039be5',\n 700: '#0288d1',\n 800: '#0277bd',\n 900: '#01579b',\n A100: '#80d8ff',\n A200: '#40c4ff',\n A400: '#00b0ff',\n A700: '#0091ea'\n};\nexport default lightBlue;","const green = {\n 50: '#e8f5e9',\n 100: '#c8e6c9',\n 200: '#a5d6a7',\n 300: '#81c784',\n 400: '#66bb6a',\n 500: '#4caf50',\n 600: '#43a047',\n 700: '#388e3c',\n 800: '#2e7d32',\n 900: '#1b5e20',\n A100: '#b9f6ca',\n A200: '#69f0ae',\n A400: '#00e676',\n A700: '#00c853'\n};\nexport default green;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\nconst _excluded = [\"mode\", \"contrastThreshold\", \"tonalOffset\"];\nimport { deepmerge } from '@mui/utils';\nimport { darken, getContrastRatio, lighten } from '@mui/system';\nimport common from '../colors/common';\nimport grey from '../colors/grey';\nimport purple from '../colors/purple';\nimport red from '../colors/red';\nimport orange from '../colors/orange';\nimport blue from '../colors/blue';\nimport lightBlue from '../colors/lightBlue';\nimport green from '../colors/green';\nexport const light = {\n // The colors used to style the text.\n text: {\n // The most important text.\n primary: 'rgba(0, 0, 0, 0.87)',\n // Secondary text.\n secondary: 'rgba(0, 0, 0, 0.6)',\n // Disabled text have even lower visual prominence.\n disabled: 'rgba(0, 0, 0, 0.38)'\n },\n // The color used to divide different elements.\n divider: 'rgba(0, 0, 0, 0.12)',\n // The background colors used to style the surfaces.\n // Consistency between these values is important.\n background: {\n paper: common.white,\n default: common.white\n },\n // The colors used to style the action elements.\n action: {\n // The color of an active action like an icon button.\n active: 'rgba(0, 0, 0, 0.54)',\n // The color of an hovered action.\n hover: 'rgba(0, 0, 0, 0.04)',\n hoverOpacity: 0.04,\n // The color of a selected action.\n selected: 'rgba(0, 0, 0, 0.08)',\n selectedOpacity: 0.08,\n // The color of a disabled action.\n disabled: 'rgba(0, 0, 0, 0.26)',\n // The background color of a disabled action.\n disabledBackground: 'rgba(0, 0, 0, 0.12)',\n disabledOpacity: 0.38,\n focus: 'rgba(0, 0, 0, 0.12)',\n focusOpacity: 0.12,\n activatedOpacity: 0.12\n }\n};\nexport const dark = {\n text: {\n primary: common.white,\n secondary: 'rgba(255, 255, 255, 0.7)',\n disabled: 'rgba(255, 255, 255, 0.5)',\n icon: 'rgba(255, 255, 255, 0.5)'\n },\n divider: 'rgba(255, 255, 255, 0.12)',\n background: {\n paper: '#121212',\n default: '#121212'\n },\n action: {\n active: common.white,\n hover: 'rgba(255, 255, 255, 0.08)',\n hoverOpacity: 0.08,\n selected: 'rgba(255, 255, 255, 0.16)',\n selectedOpacity: 0.16,\n disabled: 'rgba(255, 255, 255, 0.3)',\n disabledBackground: 'rgba(255, 255, 255, 0.12)',\n disabledOpacity: 0.38,\n focus: 'rgba(255, 255, 255, 0.12)',\n focusOpacity: 0.12,\n activatedOpacity: 0.24\n }\n};\nfunction addLightOrDark(intent, direction, shade, tonalOffset) {\n const tonalOffsetLight = tonalOffset.light || tonalOffset;\n const tonalOffsetDark = tonalOffset.dark || tonalOffset * 1.5;\n if (!intent[direction]) {\n if (intent.hasOwnProperty(shade)) {\n intent[direction] = intent[shade];\n } else if (direction === 'light') {\n intent.light = lighten(intent.main, tonalOffsetLight);\n } else if (direction === 'dark') {\n intent.dark = darken(intent.main, tonalOffsetDark);\n }\n }\n}\nfunction getDefaultPrimary(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: blue[200],\n light: blue[50],\n dark: blue[400]\n };\n }\n return {\n main: blue[700],\n light: blue[400],\n dark: blue[800]\n };\n}\nfunction getDefaultSecondary(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: purple[200],\n light: purple[50],\n dark: purple[400]\n };\n }\n return {\n main: purple[500],\n light: purple[300],\n dark: purple[700]\n };\n}\nfunction getDefaultError(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: red[500],\n light: red[300],\n dark: red[700]\n };\n }\n return {\n main: red[700],\n light: red[400],\n dark: red[800]\n };\n}\nfunction getDefaultInfo(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: lightBlue[400],\n light: lightBlue[300],\n dark: lightBlue[700]\n };\n }\n return {\n main: lightBlue[700],\n light: lightBlue[500],\n dark: lightBlue[900]\n };\n}\nfunction getDefaultSuccess(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: green[400],\n light: green[300],\n dark: green[700]\n };\n }\n return {\n main: green[800],\n light: green[500],\n dark: green[900]\n };\n}\nfunction getDefaultWarning(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: orange[400],\n light: orange[300],\n dark: orange[700]\n };\n }\n return {\n main: '#ed6c02',\n // closest to orange[800] that pass 3:1.\n light: orange[500],\n dark: orange[900]\n };\n}\nexport default function createPalette(palette) {\n const {\n mode = 'light',\n contrastThreshold = 3,\n tonalOffset = 0.2\n } = palette,\n other = _objectWithoutPropertiesLoose(palette, _excluded);\n const primary = palette.primary || getDefaultPrimary(mode);\n const secondary = palette.secondary || getDefaultSecondary(mode);\n const error = palette.error || getDefaultError(mode);\n const info = palette.info || getDefaultInfo(mode);\n const success = palette.success || getDefaultSuccess(mode);\n const warning = palette.warning || getDefaultWarning(mode);\n\n // Use the same logic as\n // Bootstrap: https://github.com/twbs/bootstrap/blob/1d6e3710dd447de1a200f29e8fa521f8a0908f70/scss/_functions.scss#L59\n // and material-components-web https://github.com/material-components/material-components-web/blob/ac46b8863c4dab9fc22c4c662dc6bd1b65dd652f/packages/mdc-theme/_functions.scss#L54\n function getContrastText(background) {\n const contrastText = getContrastRatio(background, dark.text.primary) >= contrastThreshold ? dark.text.primary : light.text.primary;\n if (process.env.NODE_ENV !== 'production') {\n const contrast = getContrastRatio(background, contrastText);\n if (contrast < 3) {\n console.error([`MUI: The contrast ratio of ${contrast}:1 for ${contrastText} on ${background}`, 'falls below the WCAG recommended absolute minimum contrast ratio of 3:1.', 'https://www.w3.org/TR/2008/REC-WCAG20-20081211/#visual-audio-contrast-contrast'].join('\\n'));\n }\n }\n return contrastText;\n }\n const augmentColor = ({\n color,\n name,\n mainShade = 500,\n lightShade = 300,\n darkShade = 700\n }) => {\n color = _extends({}, color);\n if (!color.main && color[mainShade]) {\n color.main = color[mainShade];\n }\n if (!color.hasOwnProperty('main')) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: The color${name ? ` (${name})` : ''} provided to augmentColor(color) is invalid.\nThe color object needs to have a \\`main\\` property or a \\`${mainShade}\\` property.` : _formatMuiErrorMessage(11, name ? ` (${name})` : '', mainShade));\n }\n if (typeof color.main !== 'string') {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: The color${name ? ` (${name})` : ''} provided to augmentColor(color) is invalid.\n\\`color.main\\` should be a string, but \\`${JSON.stringify(color.main)}\\` was provided instead.\n\nDid you intend to use one of the following approaches?\n\nimport { green } from \"@mui/material/colors\";\n\nconst theme1 = createTheme({ palette: {\n primary: green,\n} });\n\nconst theme2 = createTheme({ palette: {\n primary: { main: green[500] },\n} });` : _formatMuiErrorMessage(12, name ? ` (${name})` : '', JSON.stringify(color.main)));\n }\n addLightOrDark(color, 'light', lightShade, tonalOffset);\n addLightOrDark(color, 'dark', darkShade, tonalOffset);\n if (!color.contrastText) {\n color.contrastText = getContrastText(color.main);\n }\n return color;\n };\n const modes = {\n dark,\n light\n };\n if (process.env.NODE_ENV !== 'production') {\n if (!modes[mode]) {\n console.error(`MUI: The palette mode \\`${mode}\\` is not supported.`);\n }\n }\n const paletteOutput = deepmerge(_extends({\n // A collection of common colors.\n common: _extends({}, common),\n // prevent mutable object.\n // The palette mode, can be light or dark.\n mode,\n // The colors used to represent primary interface elements for a user.\n primary: augmentColor({\n color: primary,\n name: 'primary'\n }),\n // The colors used to represent secondary interface elements for a user.\n secondary: augmentColor({\n color: secondary,\n name: 'secondary',\n mainShade: 'A400',\n lightShade: 'A200',\n darkShade: 'A700'\n }),\n // The colors used to represent interface elements that the user should be made aware of.\n error: augmentColor({\n color: error,\n name: 'error'\n }),\n // The colors used to represent potentially dangerous actions or important messages.\n warning: augmentColor({\n color: warning,\n name: 'warning'\n }),\n // The colors used to present information to the user that is neutral and not necessarily important.\n info: augmentColor({\n color: info,\n name: 'info'\n }),\n // The colors used to indicate the successful completion of an action that user triggered.\n success: augmentColor({\n color: success,\n name: 'success'\n }),\n // The grey colors.\n grey,\n // Used by `getContrastText()` to maximize the contrast between\n // the background and the text.\n contrastThreshold,\n // Takes a background color and returns the text color that maximizes the contrast.\n getContrastText,\n // Generate a rich color object.\n augmentColor,\n // Used by the functions below to shift a color's luminance by approximately\n // two indexes within its tonal palette.\n // E.g., shift from Red 500 to Red 300 or Red 700.\n tonalOffset\n }, modes[mode]), other);\n return paletteOutput;\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"fontFamily\", \"fontSize\", \"fontWeightLight\", \"fontWeightRegular\", \"fontWeightMedium\", \"fontWeightBold\", \"htmlFontSize\", \"allVariants\", \"pxToRem\"];\nimport { deepmerge } from '@mui/utils';\nfunction round(value) {\n return Math.round(value * 1e5) / 1e5;\n}\nconst caseAllCaps = {\n textTransform: 'uppercase'\n};\nconst defaultFontFamily = '\"Roboto\", \"Helvetica\", \"Arial\", sans-serif';\n\n/**\n * @see @link{https://m2.material.io/design/typography/the-type-system.html}\n * @see @link{https://m2.material.io/design/typography/understanding-typography.html}\n */\nexport default function createTypography(palette, typography) {\n const _ref = typeof typography === 'function' ? typography(palette) : typography,\n {\n fontFamily = defaultFontFamily,\n // The default font size of the Material Specification.\n fontSize = 14,\n // px\n fontWeightLight = 300,\n fontWeightRegular = 400,\n fontWeightMedium = 500,\n fontWeightBold = 700,\n // Tell MUI what's the font-size on the html element.\n // 16px is the default font-size used by browsers.\n htmlFontSize = 16,\n // Apply the CSS properties to all the variants.\n allVariants,\n pxToRem: pxToRem2\n } = _ref,\n other = _objectWithoutPropertiesLoose(_ref, _excluded);\n if (process.env.NODE_ENV !== 'production') {\n if (typeof fontSize !== 'number') {\n console.error('MUI: `fontSize` is required to be a number.');\n }\n if (typeof htmlFontSize !== 'number') {\n console.error('MUI: `htmlFontSize` is required to be a number.');\n }\n }\n const coef = fontSize / 14;\n const pxToRem = pxToRem2 || (size => `${size / htmlFontSize * coef}rem`);\n const buildVariant = (fontWeight, size, lineHeight, letterSpacing, casing) => _extends({\n fontFamily,\n fontWeight,\n fontSize: pxToRem(size),\n // Unitless following https://meyerweb.com/eric/thoughts/2006/02/08/unitless-line-heights/\n lineHeight\n }, fontFamily === defaultFontFamily ? {\n letterSpacing: `${round(letterSpacing / size)}em`\n } : {}, casing, allVariants);\n const variants = {\n h1: buildVariant(fontWeightLight, 96, 1.167, -1.5),\n h2: buildVariant(fontWeightLight, 60, 1.2, -0.5),\n h3: buildVariant(fontWeightRegular, 48, 1.167, 0),\n h4: buildVariant(fontWeightRegular, 34, 1.235, 0.25),\n h5: buildVariant(fontWeightRegular, 24, 1.334, 0),\n h6: buildVariant(fontWeightMedium, 20, 1.6, 0.15),\n subtitle1: buildVariant(fontWeightRegular, 16, 1.75, 0.15),\n subtitle2: buildVariant(fontWeightMedium, 14, 1.57, 0.1),\n body1: buildVariant(fontWeightRegular, 16, 1.5, 0.15),\n body2: buildVariant(fontWeightRegular, 14, 1.43, 0.15),\n button: buildVariant(fontWeightMedium, 14, 1.75, 0.4, caseAllCaps),\n caption: buildVariant(fontWeightRegular, 12, 1.66, 0.4),\n overline: buildVariant(fontWeightRegular, 12, 2.66, 1, caseAllCaps),\n // TODO v6: Remove handling of 'inherit' variant from the theme as it is already handled in Material UI's Typography component. Also, remember to remove the associated types.\n inherit: {\n fontFamily: 'inherit',\n fontWeight: 'inherit',\n fontSize: 'inherit',\n lineHeight: 'inherit',\n letterSpacing: 'inherit'\n }\n };\n return deepmerge(_extends({\n htmlFontSize,\n pxToRem,\n fontFamily,\n fontSize,\n fontWeightLight,\n fontWeightRegular,\n fontWeightMedium,\n fontWeightBold\n }, variants), other, {\n clone: false // No need to clone deep\n });\n}","const shadowKeyUmbraOpacity = 0.2;\nconst shadowKeyPenumbraOpacity = 0.14;\nconst shadowAmbientShadowOpacity = 0.12;\nfunction createShadow(...px) {\n return [`${px[0]}px ${px[1]}px ${px[2]}px ${px[3]}px rgba(0,0,0,${shadowKeyUmbraOpacity})`, `${px[4]}px ${px[5]}px ${px[6]}px ${px[7]}px rgba(0,0,0,${shadowKeyPenumbraOpacity})`, `${px[8]}px ${px[9]}px ${px[10]}px ${px[11]}px rgba(0,0,0,${shadowAmbientShadowOpacity})`].join(',');\n}\n\n// Values from https://github.com/material-components/material-components-web/blob/be8747f94574669cb5e7add1a7c54fa41a89cec7/packages/mdc-elevation/_variables.scss\nconst shadows = ['none', createShadow(0, 2, 1, -1, 0, 1, 1, 0, 0, 1, 3, 0), createShadow(0, 3, 1, -2, 0, 2, 2, 0, 0, 1, 5, 0), createShadow(0, 3, 3, -2, 0, 3, 4, 0, 0, 1, 8, 0), createShadow(0, 2, 4, -1, 0, 4, 5, 0, 0, 1, 10, 0), createShadow(0, 3, 5, -1, 0, 5, 8, 0, 0, 1, 14, 0), createShadow(0, 3, 5, -1, 0, 6, 10, 0, 0, 1, 18, 0), createShadow(0, 4, 5, -2, 0, 7, 10, 1, 0, 2, 16, 1), createShadow(0, 5, 5, -3, 0, 8, 10, 1, 0, 3, 14, 2), createShadow(0, 5, 6, -3, 0, 9, 12, 1, 0, 3, 16, 2), createShadow(0, 6, 6, -3, 0, 10, 14, 1, 0, 4, 18, 3), createShadow(0, 6, 7, -4, 0, 11, 15, 1, 0, 4, 20, 3), createShadow(0, 7, 8, -4, 0, 12, 17, 2, 0, 5, 22, 4), createShadow(0, 7, 8, -4, 0, 13, 19, 2, 0, 5, 24, 4), createShadow(0, 7, 9, -4, 0, 14, 21, 2, 0, 5, 26, 4), createShadow(0, 8, 9, -5, 0, 15, 22, 2, 0, 6, 28, 5), createShadow(0, 8, 10, -5, 0, 16, 24, 2, 0, 6, 30, 5), createShadow(0, 8, 11, -5, 0, 17, 26, 2, 0, 6, 32, 5), createShadow(0, 9, 11, -5, 0, 18, 28, 2, 0, 7, 34, 6), createShadow(0, 9, 12, -6, 0, 19, 29, 2, 0, 7, 36, 6), createShadow(0, 10, 13, -6, 0, 20, 31, 3, 0, 8, 38, 7), createShadow(0, 10, 13, -6, 0, 21, 33, 3, 0, 8, 40, 7), createShadow(0, 10, 14, -6, 0, 22, 35, 3, 0, 8, 42, 7), createShadow(0, 11, 14, -7, 0, 23, 36, 3, 0, 9, 44, 8), createShadow(0, 11, 15, -7, 0, 24, 38, 3, 0, 9, 46, 8)];\nexport default shadows;","import _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nconst _excluded = [\"duration\", \"easing\", \"delay\"];\n// Follow https://material.google.com/motion/duration-easing.html#duration-easing-natural-easing-curves\n// to learn the context in which each easing should be used.\nexport const easing = {\n // This is the most common easing curve.\n easeInOut: 'cubic-bezier(0.4, 0, 0.2, 1)',\n // Objects enter the screen at full velocity from off-screen and\n // slowly decelerate to a resting point.\n easeOut: 'cubic-bezier(0.0, 0, 0.2, 1)',\n // Objects leave the screen at full velocity. They do not decelerate when off-screen.\n easeIn: 'cubic-bezier(0.4, 0, 1, 1)',\n // The sharp curve is used by objects that may return to the screen at any time.\n sharp: 'cubic-bezier(0.4, 0, 0.6, 1)'\n};\n\n// Follow https://m2.material.io/guidelines/motion/duration-easing.html#duration-easing-common-durations\n// to learn when use what timing\nexport const duration = {\n shortest: 150,\n shorter: 200,\n short: 250,\n // most basic recommended timing\n standard: 300,\n // this is to be used in complex animations\n complex: 375,\n // recommended when something is entering screen\n enteringScreen: 225,\n // recommended when something is leaving screen\n leavingScreen: 195\n};\nfunction formatMs(milliseconds) {\n return `${Math.round(milliseconds)}ms`;\n}\nfunction getAutoHeightDuration(height) {\n if (!height) {\n return 0;\n }\n const constant = height / 36;\n\n // https://www.wolframalpha.com/input/?i=(4+%2B+15+*+(x+%2F+36+)+**+0.25+%2B+(x+%2F+36)+%2F+5)+*+10\n return Math.round((4 + 15 * constant ** 0.25 + constant / 5) * 10);\n}\nexport default function createTransitions(inputTransitions) {\n const mergedEasing = _extends({}, easing, inputTransitions.easing);\n const mergedDuration = _extends({}, duration, inputTransitions.duration);\n const create = (props = ['all'], options = {}) => {\n const {\n duration: durationOption = mergedDuration.standard,\n easing: easingOption = mergedEasing.easeInOut,\n delay = 0\n } = options,\n other = _objectWithoutPropertiesLoose(options, _excluded);\n if (process.env.NODE_ENV !== 'production') {\n const isString = value => typeof value === 'string';\n // IE11 support, replace with Number.isNaN\n // eslint-disable-next-line no-restricted-globals\n const isNumber = value => !isNaN(parseFloat(value));\n if (!isString(props) && !Array.isArray(props)) {\n console.error('MUI: Argument \"props\" must be a string or Array.');\n }\n if (!isNumber(durationOption) && !isString(durationOption)) {\n console.error(`MUI: Argument \"duration\" must be a number or a string but found ${durationOption}.`);\n }\n if (!isString(easingOption)) {\n console.error('MUI: Argument \"easing\" must be a string.');\n }\n if (!isNumber(delay) && !isString(delay)) {\n console.error('MUI: Argument \"delay\" must be a number or a string.');\n }\n if (typeof options !== 'object') {\n console.error(['MUI: Secong argument of transition.create must be an object.', \"Arguments should be either `create('prop1', options)` or `create(['prop1', 'prop2'], options)`\"].join('\\n'));\n }\n if (Object.keys(other).length !== 0) {\n console.error(`MUI: Unrecognized argument(s) [${Object.keys(other).join(',')}].`);\n }\n }\n return (Array.isArray(props) ? props : [props]).map(animatedProp => `${animatedProp} ${typeof durationOption === 'string' ? durationOption : formatMs(durationOption)} ${easingOption} ${typeof delay === 'string' ? delay : formatMs(delay)}`).join(',');\n };\n return _extends({\n getAutoHeightDuration,\n create\n }, inputTransitions, {\n easing: mergedEasing,\n duration: mergedDuration\n });\n}","// We need to centralize the zIndex definitions as they work\n// like global values in the browser.\nconst zIndex = {\n mobileStepper: 1000,\n fab: 1050,\n speedDial: 1050,\n appBar: 1100,\n drawer: 1200,\n modal: 1300,\n snackbar: 1400,\n tooltip: 1500\n};\nexport default zIndex;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\nconst _excluded = [\"breakpoints\", \"mixins\", \"spacing\", \"palette\", \"transitions\", \"typography\", \"shape\"];\nimport { deepmerge } from '@mui/utils';\nimport { createTheme as systemCreateTheme, unstable_defaultSxConfig as defaultSxConfig, unstable_styleFunctionSx as styleFunctionSx } from '@mui/system';\nimport generateUtilityClass from '@mui/utils/generateUtilityClass';\nimport createMixins from './createMixins';\nimport createPalette from './createPalette';\nimport createTypography from './createTypography';\nimport shadows from './shadows';\nimport createTransitions from './createTransitions';\nimport zIndex from './zIndex';\nfunction createTheme(options = {}, ...args) {\n const {\n mixins: mixinsInput = {},\n palette: paletteInput = {},\n transitions: transitionsInput = {},\n typography: typographyInput = {}\n } = options,\n other = _objectWithoutPropertiesLoose(options, _excluded);\n if (options.vars) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: \\`vars\\` is a private field used for CSS variables support.\nPlease use another name.` : _formatMuiErrorMessage(18));\n }\n const palette = createPalette(paletteInput);\n const systemTheme = systemCreateTheme(options);\n let muiTheme = deepmerge(systemTheme, {\n mixins: createMixins(systemTheme.breakpoints, mixinsInput),\n palette,\n // Don't use [...shadows] until you've verified its transpiled code is not invoking the iterator protocol.\n shadows: shadows.slice(),\n typography: createTypography(palette, typographyInput),\n transitions: createTransitions(transitionsInput),\n zIndex: _extends({}, zIndex)\n });\n muiTheme = deepmerge(muiTheme, other);\n muiTheme = args.reduce((acc, argument) => deepmerge(acc, argument), muiTheme);\n if (process.env.NODE_ENV !== 'production') {\n // TODO v6: Refactor to use globalStateClassesMapping from @mui/utils once `readOnly` state class is used in Rating component.\n const stateClasses = ['active', 'checked', 'completed', 'disabled', 'error', 'expanded', 'focused', 'focusVisible', 'required', 'selected'];\n const traverse = (node, component) => {\n let key;\n\n // eslint-disable-next-line guard-for-in, no-restricted-syntax\n for (key in node) {\n const child = node[key];\n if (stateClasses.indexOf(key) !== -1 && Object.keys(child).length > 0) {\n if (process.env.NODE_ENV !== 'production') {\n const stateClass = generateUtilityClass('', key);\n console.error([`MUI: The \\`${component}\\` component increases ` + `the CSS specificity of the \\`${key}\\` internal state.`, 'You can not override it like this: ', JSON.stringify(node, null, 2), '', `Instead, you need to use the '&.${stateClass}' syntax:`, JSON.stringify({\n root: {\n [`&.${stateClass}`]: child\n }\n }, null, 2), '', 'https://mui.com/r/state-classes-guide'].join('\\n'));\n }\n // Remove the style to prevent global conflicts.\n node[key] = {};\n }\n }\n };\n Object.keys(muiTheme.components).forEach(component => {\n const styleOverrides = muiTheme.components[component].styleOverrides;\n if (styleOverrides && component.indexOf('Mui') === 0) {\n traverse(styleOverrides, component);\n }\n });\n }\n muiTheme.unstable_sxConfig = _extends({}, defaultSxConfig, other == null ? void 0 : other.unstable_sxConfig);\n muiTheme.unstable_sx = function sx(props) {\n return styleFunctionSx({\n sx: props,\n theme: this\n });\n };\n return muiTheme;\n}\nlet warnedOnce = false;\nexport function createMuiTheme(...args) {\n if (process.env.NODE_ENV !== 'production') {\n if (!warnedOnce) {\n warnedOnce = true;\n console.error(['MUI: the createMuiTheme function was renamed to createTheme.', '', \"You should use `import { createTheme } from '@mui/material/styles'`\"].join('\\n'));\n }\n }\n return createTheme(...args);\n}\nexport default createTheme;","'use client';\n\nimport createTheme from './createTheme';\nconst defaultTheme = createTheme();\nexport default defaultTheme;","export default '$$material';","'use client';\n\nimport { useThemeProps as systemUseThemeProps } from '@mui/system';\nimport defaultTheme from './defaultTheme';\nimport THEME_ID from './identifier';\nexport default function useThemeProps({\n props,\n name\n}) {\n return systemUseThemeProps({\n props,\n name,\n defaultTheme,\n themeId: THEME_ID\n });\n}","'use client';\n\nimport { createStyled, shouldForwardProp } from '@mui/system';\nimport defaultTheme from './defaultTheme';\nimport THEME_ID from './identifier';\nexport const rootShouldForwardProp = prop => shouldForwardProp(prop) && prop !== 'classes';\nexport const slotShouldForwardProp = shouldForwardProp;\nconst styled = createStyled({\n themeId: THEME_ID,\n defaultTheme,\n rootShouldForwardProp\n});\nexport default styled;","import generateUtilityClasses from '@mui/utils/generateUtilityClasses';\nimport generateUtilityClass from '@mui/utils/generateUtilityClass';\nexport function getSvgIconUtilityClass(slot) {\n return generateUtilityClass('MuiSvgIcon', slot);\n}\nconst svgIconClasses = generateUtilityClasses('MuiSvgIcon', ['root', 'colorPrimary', 'colorSecondary', 'colorAction', 'colorError', 'colorDisabled', 'fontSizeInherit', 'fontSizeSmall', 'fontSizeMedium', 'fontSizeLarge']);\nexport default svgIconClasses;","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"children\", \"className\", \"color\", \"component\", \"fontSize\", \"htmlColor\", \"inheritViewBox\", \"titleAccess\", \"viewBox\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport clsx from 'clsx';\nimport { unstable_composeClasses as composeClasses } from '@mui/base/composeClasses';\nimport capitalize from '../utils/capitalize';\nimport useThemeProps from '../styles/useThemeProps';\nimport styled from '../styles/styled';\nimport { getSvgIconUtilityClass } from './svgIconClasses';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nimport { jsxs as _jsxs } from \"react/jsx-runtime\";\nconst useUtilityClasses = ownerState => {\n const {\n color,\n fontSize,\n classes\n } = ownerState;\n const slots = {\n root: ['root', color !== 'inherit' && `color${capitalize(color)}`, `fontSize${capitalize(fontSize)}`]\n };\n return composeClasses(slots, getSvgIconUtilityClass, classes);\n};\nconst SvgIconRoot = styled('svg', {\n name: 'MuiSvgIcon',\n slot: 'Root',\n overridesResolver: (props, styles) => {\n const {\n ownerState\n } = props;\n return [styles.root, ownerState.color !== 'inherit' && styles[`color${capitalize(ownerState.color)}`], styles[`fontSize${capitalize(ownerState.fontSize)}`]];\n }\n})(({\n theme,\n ownerState\n}) => {\n var _theme$transitions, _theme$transitions$cr, _theme$transitions2, _theme$typography, _theme$typography$pxT, _theme$typography2, _theme$typography2$px, _theme$typography3, _theme$typography3$px, _palette$ownerState$c, _palette, _palette2, _palette3;\n return {\n userSelect: 'none',\n width: '1em',\n height: '1em',\n display: 'inline-block',\n // the will define the property that has `currentColor`\n // e.g. heroicons uses fill=\"none\" and stroke=\"currentColor\"\n fill: ownerState.hasSvgAsChild ? undefined : 'currentColor',\n flexShrink: 0,\n transition: (_theme$transitions = theme.transitions) == null || (_theme$transitions$cr = _theme$transitions.create) == null ? void 0 : _theme$transitions$cr.call(_theme$transitions, 'fill', {\n duration: (_theme$transitions2 = theme.transitions) == null || (_theme$transitions2 = _theme$transitions2.duration) == null ? void 0 : _theme$transitions2.shorter\n }),\n fontSize: {\n inherit: 'inherit',\n small: ((_theme$typography = theme.typography) == null || (_theme$typography$pxT = _theme$typography.pxToRem) == null ? void 0 : _theme$typography$pxT.call(_theme$typography, 20)) || '1.25rem',\n medium: ((_theme$typography2 = theme.typography) == null || (_theme$typography2$px = _theme$typography2.pxToRem) == null ? void 0 : _theme$typography2$px.call(_theme$typography2, 24)) || '1.5rem',\n large: ((_theme$typography3 = theme.typography) == null || (_theme$typography3$px = _theme$typography3.pxToRem) == null ? void 0 : _theme$typography3$px.call(_theme$typography3, 35)) || '2.1875rem'\n }[ownerState.fontSize],\n // TODO v5 deprecate, v6 remove for sx\n color: (_palette$ownerState$c = (_palette = (theme.vars || theme).palette) == null || (_palette = _palette[ownerState.color]) == null ? void 0 : _palette.main) != null ? _palette$ownerState$c : {\n action: (_palette2 = (theme.vars || theme).palette) == null || (_palette2 = _palette2.action) == null ? void 0 : _palette2.active,\n disabled: (_palette3 = (theme.vars || theme).palette) == null || (_palette3 = _palette3.action) == null ? void 0 : _palette3.disabled,\n inherit: undefined\n }[ownerState.color]\n };\n});\nconst SvgIcon = /*#__PURE__*/React.forwardRef(function SvgIcon(inProps, ref) {\n const props = useThemeProps({\n props: inProps,\n name: 'MuiSvgIcon'\n });\n const {\n children,\n className,\n color = 'inherit',\n component = 'svg',\n fontSize = 'medium',\n htmlColor,\n inheritViewBox = false,\n titleAccess,\n viewBox = '0 0 24 24'\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const hasSvgAsChild = /*#__PURE__*/React.isValidElement(children) && children.type === 'svg';\n const ownerState = _extends({}, props, {\n color,\n component,\n fontSize,\n instanceFontSize: inProps.fontSize,\n inheritViewBox,\n viewBox,\n hasSvgAsChild\n });\n const more = {};\n if (!inheritViewBox) {\n more.viewBox = viewBox;\n }\n const classes = useUtilityClasses(ownerState);\n return /*#__PURE__*/_jsxs(SvgIconRoot, _extends({\n as: component,\n className: clsx(classes.root, className),\n focusable: \"false\",\n color: htmlColor,\n \"aria-hidden\": titleAccess ? undefined : true,\n role: titleAccess ? 'img' : undefined,\n ref: ref\n }, more, other, hasSvgAsChild && children.props, {\n ownerState: ownerState,\n children: [hasSvgAsChild ? children.props.children : children, titleAccess ? /*#__PURE__*/_jsx(\"title\", {\n children: titleAccess\n }) : null]\n }));\n});\nprocess.env.NODE_ENV !== \"production\" ? SvgIcon.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the d.ts file and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * Node passed into the SVG element.\n */\n children: PropTypes.node,\n /**\n * Override or extend the styles applied to the component.\n */\n classes: PropTypes.object,\n /**\n * @ignore\n */\n className: PropTypes.string,\n /**\n * The color of the component.\n * It supports both default and custom theme colors, which can be added as shown in the\n * [palette customization guide](https://mui.com/material-ui/customization/palette/#custom-colors).\n * You can use the `htmlColor` prop to apply a color attribute to the SVG element.\n * @default 'inherit'\n */\n color: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.oneOf(['inherit', 'action', 'disabled', 'primary', 'secondary', 'error', 'info', 'success', 'warning']), PropTypes.string]),\n /**\n * The component used for the root node.\n * Either a string to use a HTML element or a component.\n */\n component: PropTypes.elementType,\n /**\n * The fontSize applied to the icon. Defaults to 24px, but can be configure to inherit font size.\n * @default 'medium'\n */\n fontSize: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.oneOf(['inherit', 'large', 'medium', 'small']), PropTypes.string]),\n /**\n * Applies a color attribute to the SVG element.\n */\n htmlColor: PropTypes.string,\n /**\n * If `true`, the root node will inherit the custom `component`'s viewBox and the `viewBox`\n * prop will be ignored.\n * Useful when you want to reference a custom `component` and have `SvgIcon` pass that\n * `component`'s viewBox to the root node.\n * @default false\n */\n inheritViewBox: PropTypes.bool,\n /**\n * The shape-rendering attribute. The behavior of the different options is described on the\n * [MDN Web Docs](https://developer.mozilla.org/en-US/docs/Web/SVG/Attribute/shape-rendering).\n * If you are having issues with blurry icons you should investigate this prop.\n */\n shapeRendering: PropTypes.string,\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Provides a human-readable title for the element that contains it.\n * https://www.w3.org/TR/SVG-access/#Equivalent\n */\n titleAccess: PropTypes.string,\n /**\n * Allows you to redefine what the coordinates without units mean inside an SVG element.\n * For example, if the SVG element is 500 (width) by 200 (height),\n * and you pass viewBox=\"0 0 50 20\",\n * this means that the coordinates inside the SVG will go from the top left corner (0,0)\n * to bottom right (50,20) and each unit will be worth 10px.\n * @default '0 0 24 24'\n */\n viewBox: PropTypes.string\n} : void 0;\nSvgIcon.muiName = 'SvgIcon';\nexport default SvgIcon;","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport * as React from 'react';\nimport SvgIcon from '../SvgIcon';\n\n/**\n * Private module reserved for @mui packages.\n */\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nexport default function createSvgIcon(path, displayName) {\n function Component(props, ref) {\n return /*#__PURE__*/_jsx(SvgIcon, _extends({\n \"data-testid\": `${displayName}Icon`,\n ref: ref\n }, props, {\n children: path\n }));\n }\n if (process.env.NODE_ENV !== 'production') {\n // Need to set `displayName` on the inner component for React.memo.\n // React prior to 16.14 ignores `displayName` on the wrapper.\n Component.displayName = `${displayName}Icon`;\n }\n Component.muiName = SvgIcon.muiName;\n return /*#__PURE__*/React.memo( /*#__PURE__*/React.forwardRef(Component));\n}","'use client';\n\nimport { unstable_ClassNameGenerator as ClassNameGenerator } from '@mui/base/ClassNameGenerator';\nexport { default as capitalize } from './capitalize';\nexport { default as createChainedFunction } from './createChainedFunction';\nexport { default as createSvgIcon } from './createSvgIcon';\nexport { default as debounce } from './debounce';\nexport { default as deprecatedPropType } from './deprecatedPropType';\nexport { default as isMuiElement } from './isMuiElement';\nexport { default as ownerDocument } from './ownerDocument';\nexport { default as ownerWindow } from './ownerWindow';\nexport { default as requirePropFactory } from './requirePropFactory';\nexport { default as setRef } from './setRef';\nexport { default as unstable_useEnhancedEffect } from './useEnhancedEffect';\nexport { default as unstable_useId } from './useId';\nexport { default as unsupportedProp } from './unsupportedProp';\nexport { default as useControlled } from './useControlled';\nexport { default as useEventCallback } from './useEventCallback';\nexport { default as useForkRef } from './useForkRef';\nexport { default as useIsFocusVisible } from './useIsFocusVisible';\n// TODO: remove this export once ClassNameGenerator is stable\n// eslint-disable-next-line @typescript-eslint/naming-convention\nexport const unstable_ClassNameGenerator = {\n configure: generator => {\n if (process.env.NODE_ENV !== 'production') {\n console.warn(['MUI: `ClassNameGenerator` import from `@mui/material/utils` is outdated and might cause unexpected issues.', '', \"You should use `import { unstable_ClassNameGenerator } from '@mui/material/className'` instead\", '', 'The detail of the issue: https://github.com/mui/material-ui/issues/30011#issuecomment-1024993401', '', 'The updated documentation: https://mui.com/guides/classname-generator/'].join('\\n'));\n }\n ClassNameGenerator.configure(generator);\n }\n};","\"use strict\";\n'use client';\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nObject.defineProperty(exports, \"default\", {\n enumerable: true,\n get: function () {\n return _utils.createSvgIcon;\n }\n});\nvar _utils = require(\"@mui/material/utils\");","\"use strict\";\n\"use client\";\n\nvar _interopRequireDefault = require(\"@babel/runtime/helpers/interopRequireDefault\");\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = void 0;\nvar _createSvgIcon = _interopRequireDefault(require(\"./utils/createSvgIcon\"));\nvar _jsxRuntime = require(\"react/jsx-runtime\");\nvar _default = exports.default = (0, _createSvgIcon.default)( /*#__PURE__*/(0, _jsxRuntime.jsx)(\"path\", {\n d: \"m10 17 5-5-5-5z\"\n}), 'ArrowRight');","/**\n * Determines if a given element is a DOM element name (i.e. not a React component).\n */\nexport function isHostComponent(element) {\n return typeof element === 'string';\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport { isHostComponent } from './isHostComponent';\n\n/**\n * Type of the ownerState based on the type of an element it applies to.\n * This resolves to the provided OwnerState for React components and `undefined` for host components.\n * Falls back to `OwnerState | undefined` when the exact type can't be determined in development time.\n */\n\n/**\n * Appends the ownerState object to the props, merging with the existing one if necessary.\n *\n * @param elementType Type of the element that owns the `existingProps`. If the element is a DOM node or undefined, `ownerState` is not applied.\n * @param otherProps Props of the element.\n * @param ownerState\n */\nexport function appendOwnerState(elementType, otherProps, ownerState) {\n if (elementType === undefined || isHostComponent(elementType)) {\n return otherProps;\n }\n return _extends({}, otherProps, {\n ownerState: _extends({}, otherProps.ownerState, ownerState)\n });\n}","'use client';\n\nimport * as React from 'react';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nconst defaultContextValue = {\n disableDefaultClasses: false\n};\nconst ClassNameConfiguratorContext = /*#__PURE__*/React.createContext(defaultContextValue);\n/**\n * @ignore - internal hook.\n *\n * Wraps the `generateUtilityClass` function and controls how the classes are generated.\n * Currently it only affects whether the classes are applied or not.\n *\n * @returns Function to be called with the `generateUtilityClass` function specific to a component to generate the classes.\n */\nexport function useClassNamesOverride(generateUtilityClass) {\n const {\n disableDefaultClasses\n } = React.useContext(ClassNameConfiguratorContext);\n return slot => {\n if (disableDefaultClasses) {\n return '';\n }\n return generateUtilityClass(slot);\n };\n}\n\n/**\n * Allows to configure the components within to not apply any built-in classes.\n */\nexport function ClassNameConfigurator(props) {\n const {\n disableDefaultClasses,\n children\n } = props;\n const contextValue = React.useMemo(() => ({\n disableDefaultClasses: disableDefaultClasses != null ? disableDefaultClasses : false\n }), [disableDefaultClasses]);\n return /*#__PURE__*/_jsx(ClassNameConfiguratorContext.Provider, {\n value: contextValue,\n children: children\n });\n}","/**\n * Extracts event handlers from a given object.\n * A prop is considered an event handler if it is a function and its name starts with `on`.\n *\n * @param object An object to extract event handlers from.\n * @param excludeKeys An array of keys to exclude from the returned object.\n */\nexport function extractEventHandlers(object, excludeKeys = []) {\n if (object === undefined) {\n return {};\n }\n const result = {};\n Object.keys(object).filter(prop => prop.match(/^on[A-Z]/) && typeof object[prop] === 'function' && !excludeKeys.includes(prop)).forEach(prop => {\n result[prop] = object[prop];\n });\n return result;\n}","/**\n * If `componentProps` is a function, calls it with the provided `ownerState`.\n * Otherwise, just returns `componentProps`.\n */\nexport function resolveComponentProps(componentProps, ownerState, slotState) {\n if (typeof componentProps === 'function') {\n return componentProps(ownerState, slotState);\n }\n return componentProps;\n}","/**\n * Removes event handlers from the given object.\n * A field is considered an event handler if it is a function with a name beginning with `on`.\n *\n * @param object Object to remove event handlers from.\n * @returns Object with event handlers removed.\n */\nexport function omitEventHandlers(object) {\n if (object === undefined) {\n return {};\n }\n const result = {};\n Object.keys(object).filter(prop => !(prop.match(/^on[A-Z]/) && typeof object[prop] === 'function')).forEach(prop => {\n result[prop] = object[prop];\n });\n return result;\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport clsx from 'clsx';\nimport { extractEventHandlers } from './extractEventHandlers';\nimport { omitEventHandlers } from './omitEventHandlers';\n/**\n * Merges the slot component internal props (usually coming from a hook)\n * with the externally provided ones.\n *\n * The merge order is (the latter overrides the former):\n * 1. The internal props (specified as a getter function to work with get*Props hook result)\n * 2. Additional props (specified internally on a Base UI component)\n * 3. External props specified on the owner component. These should only be used on a root slot.\n * 4. External props specified in the `slotProps.*` prop.\n * 5. The `className` prop - combined from all the above.\n * @param parameters\n * @returns\n */\nexport function mergeSlotProps(parameters) {\n const {\n getSlotProps,\n additionalProps,\n externalSlotProps,\n externalForwardedProps,\n className\n } = parameters;\n if (!getSlotProps) {\n // The simpler case - getSlotProps is not defined, so no internal event handlers are defined,\n // so we can simply merge all the props without having to worry about extracting event handlers.\n const joinedClasses = clsx(additionalProps == null ? void 0 : additionalProps.className, className, externalForwardedProps == null ? void 0 : externalForwardedProps.className, externalSlotProps == null ? void 0 : externalSlotProps.className);\n const mergedStyle = _extends({}, additionalProps == null ? void 0 : additionalProps.style, externalForwardedProps == null ? void 0 : externalForwardedProps.style, externalSlotProps == null ? void 0 : externalSlotProps.style);\n const props = _extends({}, additionalProps, externalForwardedProps, externalSlotProps);\n if (joinedClasses.length > 0) {\n props.className = joinedClasses;\n }\n if (Object.keys(mergedStyle).length > 0) {\n props.style = mergedStyle;\n }\n return {\n props,\n internalRef: undefined\n };\n }\n\n // In this case, getSlotProps is responsible for calling the external event handlers.\n // We don't need to include them in the merged props because of this.\n\n const eventHandlers = extractEventHandlers(_extends({}, externalForwardedProps, externalSlotProps));\n const componentsPropsWithoutEventHandlers = omitEventHandlers(externalSlotProps);\n const otherPropsWithoutEventHandlers = omitEventHandlers(externalForwardedProps);\n const internalSlotProps = getSlotProps(eventHandlers);\n\n // The order of classes is important here.\n // Emotion (that we use in libraries consuming Base UI) depends on this order\n // to properly override style. It requires the most important classes to be last\n // (see https://github.com/mui/material-ui/pull/33205) for the related discussion.\n const joinedClasses = clsx(internalSlotProps == null ? void 0 : internalSlotProps.className, additionalProps == null ? void 0 : additionalProps.className, className, externalForwardedProps == null ? void 0 : externalForwardedProps.className, externalSlotProps == null ? void 0 : externalSlotProps.className);\n const mergedStyle = _extends({}, internalSlotProps == null ? void 0 : internalSlotProps.style, additionalProps == null ? void 0 : additionalProps.style, externalForwardedProps == null ? void 0 : externalForwardedProps.style, externalSlotProps == null ? void 0 : externalSlotProps.style);\n const props = _extends({}, internalSlotProps, additionalProps, otherPropsWithoutEventHandlers, componentsPropsWithoutEventHandlers);\n if (joinedClasses.length > 0) {\n props.className = joinedClasses;\n }\n if (Object.keys(mergedStyle).length > 0) {\n props.style = mergedStyle;\n }\n return {\n props,\n internalRef: internalSlotProps.ref\n };\n}","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"elementType\", \"externalSlotProps\", \"ownerState\", \"skipResolvingSlotProps\"];\nimport { unstable_useForkRef as useForkRef } from '@mui/utils';\nimport { appendOwnerState } from './appendOwnerState';\nimport { mergeSlotProps } from './mergeSlotProps';\nimport { resolveComponentProps } from './resolveComponentProps';\n/**\n * @ignore - do not document.\n * Builds the props to be passed into the slot of an unstyled component.\n * It merges the internal props of the component with the ones supplied by the user, allowing to customize the behavior.\n * If the slot component is not a host component, it also merges in the `ownerState`.\n *\n * @param parameters.getSlotProps - A function that returns the props to be passed to the slot component.\n */\nexport function useSlotProps(parameters) {\n var _parameters$additiona;\n const {\n elementType,\n externalSlotProps,\n ownerState,\n skipResolvingSlotProps = false\n } = parameters,\n rest = _objectWithoutPropertiesLoose(parameters, _excluded);\n const resolvedComponentsProps = skipResolvingSlotProps ? {} : resolveComponentProps(externalSlotProps, ownerState);\n const {\n props: mergedProps,\n internalRef\n } = mergeSlotProps(_extends({}, rest, {\n externalSlotProps: resolvedComponentsProps\n }));\n const ref = useForkRef(internalRef, resolvedComponentsProps == null ? void 0 : resolvedComponentsProps.ref, (_parameters$additiona = parameters.additionalProps) == null ? void 0 : _parameters$additiona.ref);\n const props = appendOwnerState(elementType, _extends({}, mergedProps, {\n ref\n }), ownerState);\n return props;\n}","import { globalStateClasses } from '@mui/utils/generateUtilityClass';\nconst GLOBAL_CLASS_PREFIX = 'base';\nfunction buildStateClass(state) {\n return `${GLOBAL_CLASS_PREFIX}--${state}`;\n}\nfunction buildSlotClass(componentName, slot) {\n return `${GLOBAL_CLASS_PREFIX}-${componentName}-${slot}`;\n}\nexport function generateUtilityClass(componentName, slot) {\n const globalStateClass = globalStateClasses[slot];\n return globalStateClass ? buildStateClass(globalStateClass) : buildSlotClass(componentName, slot);\n}\nexport function isGlobalState(slot) {\n return globalStateClasses[slot] !== undefined;\n}","import { generateUtilityClass } from '../generateUtilityClass';\nexport function generateUtilityClasses(componentName, slots) {\n const result = {};\n slots.forEach(slot => {\n result[slot] = generateUtilityClass(componentName, slot);\n });\n return result;\n}","'use client';\n\nimport * as React from 'react';\nimport * as ReactDOM from 'react-dom';\nimport PropTypes from 'prop-types';\nimport { exactProp, HTMLElementType, unstable_useEnhancedEffect as useEnhancedEffect, unstable_useForkRef as useForkRef, unstable_setRef as setRef } from '@mui/utils';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nfunction getContainer(container) {\n return typeof container === 'function' ? container() : container;\n}\n\n/**\n * Portals provide a first-class way to render children into a DOM node\n * that exists outside the DOM hierarchy of the parent component.\n *\n * Demos:\n *\n * - [Portal](https://mui.com/base-ui/react-portal/)\n *\n * API:\n *\n * - [Portal API](https://mui.com/base-ui/react-portal/components-api/#portal)\n */\nconst Portal = /*#__PURE__*/React.forwardRef(function Portal(props, forwardedRef) {\n const {\n children,\n container,\n disablePortal = false\n } = props;\n const [mountNode, setMountNode] = React.useState(null);\n // @ts-expect-error TODO upstream fix\n const handleRef = useForkRef( /*#__PURE__*/React.isValidElement(children) ? children.ref : null, forwardedRef);\n useEnhancedEffect(() => {\n if (!disablePortal) {\n setMountNode(getContainer(container) || document.body);\n }\n }, [container, disablePortal]);\n useEnhancedEffect(() => {\n if (mountNode && !disablePortal) {\n setRef(forwardedRef, mountNode);\n return () => {\n setRef(forwardedRef, null);\n };\n }\n return undefined;\n }, [forwardedRef, mountNode, disablePortal]);\n if (disablePortal) {\n if ( /*#__PURE__*/React.isValidElement(children)) {\n const newProps = {\n ref: handleRef\n };\n return /*#__PURE__*/React.cloneElement(children, newProps);\n }\n return /*#__PURE__*/_jsx(React.Fragment, {\n children: children\n });\n }\n return /*#__PURE__*/_jsx(React.Fragment, {\n children: mountNode ? /*#__PURE__*/ReactDOM.createPortal(children, mountNode) : mountNode\n });\n});\nprocess.env.NODE_ENV !== \"production\" ? Portal.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * The children to render into the `container`.\n */\n children: PropTypes.node,\n /**\n * An HTML element or function that returns one.\n * The `container` will have the portal children appended to it.\n *\n * You can also provide a callback, which is called in a React layout effect.\n * This lets you set the container from a ref, and also makes server-side rendering possible.\n *\n * By default, it uses the body of the top-level document object,\n * so it's simply `document.body` most of the time.\n */\n container: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.func]),\n /**\n * The `children` will be under the DOM hierarchy of the parent component.\n * @default false\n */\n disablePortal: PropTypes.bool\n} : void 0;\nif (process.env.NODE_ENV !== 'production') {\n // eslint-disable-next-line\n Portal['propTypes' + ''] = exactProp(Portal.propTypes);\n}\nexport { Portal };","export var top = 'top';\nexport var bottom = 'bottom';\nexport var right = 'right';\nexport var left = 'left';\nexport var auto = 'auto';\nexport var basePlacements = [top, bottom, right, left];\nexport var start = 'start';\nexport var end = 'end';\nexport var clippingParents = 'clippingParents';\nexport var viewport = 'viewport';\nexport var popper = 'popper';\nexport var reference = 'reference';\nexport var variationPlacements = /*#__PURE__*/basePlacements.reduce(function (acc, placement) {\n return acc.concat([placement + \"-\" + start, placement + \"-\" + end]);\n}, []);\nexport var placements = /*#__PURE__*/[].concat(basePlacements, [auto]).reduce(function (acc, placement) {\n return acc.concat([placement, placement + \"-\" + start, placement + \"-\" + end]);\n}, []); // modifiers that need to read the DOM\n\nexport var beforeRead = 'beforeRead';\nexport var read = 'read';\nexport var afterRead = 'afterRead'; // pure-logic modifiers\n\nexport var beforeMain = 'beforeMain';\nexport var main = 'main';\nexport var afterMain = 'afterMain'; // modifier with the purpose to write to the DOM (or write into a framework state)\n\nexport var beforeWrite = 'beforeWrite';\nexport var write = 'write';\nexport var afterWrite = 'afterWrite';\nexport var modifierPhases = [beforeRead, read, afterRead, beforeMain, main, afterMain, beforeWrite, write, afterWrite];","export default function getNodeName(element) {\n return element ? (element.nodeName || '').toLowerCase() : null;\n}","export default function getWindow(node) {\n if (node == null) {\n return window;\n }\n\n if (node.toString() !== '[object Window]') {\n var ownerDocument = node.ownerDocument;\n return ownerDocument ? ownerDocument.defaultView || window : window;\n }\n\n return node;\n}","import getWindow from \"./getWindow.js\";\n\nfunction isElement(node) {\n var OwnElement = getWindow(node).Element;\n return node instanceof OwnElement || node instanceof Element;\n}\n\nfunction isHTMLElement(node) {\n var OwnElement = getWindow(node).HTMLElement;\n return node instanceof OwnElement || node instanceof HTMLElement;\n}\n\nfunction isShadowRoot(node) {\n // IE 11 has no ShadowRoot\n if (typeof ShadowRoot === 'undefined') {\n return false;\n }\n\n var OwnElement = getWindow(node).ShadowRoot;\n return node instanceof OwnElement || node instanceof ShadowRoot;\n}\n\nexport { isElement, isHTMLElement, isShadowRoot };","import getNodeName from \"../dom-utils/getNodeName.js\";\nimport { isHTMLElement } from \"../dom-utils/instanceOf.js\"; // This modifier takes the styles prepared by the `computeStyles` modifier\n// and applies them to the HTMLElements such as popper and arrow\n\nfunction applyStyles(_ref) {\n var state = _ref.state;\n Object.keys(state.elements).forEach(function (name) {\n var style = state.styles[name] || {};\n var attributes = state.attributes[name] || {};\n var element = state.elements[name]; // arrow is optional + virtual elements\n\n if (!isHTMLElement(element) || !getNodeName(element)) {\n return;\n } // Flow doesn't support to extend this property, but it's the most\n // effective way to apply styles to an HTMLElement\n // $FlowFixMe[cannot-write]\n\n\n Object.assign(element.style, style);\n Object.keys(attributes).forEach(function (name) {\n var value = attributes[name];\n\n if (value === false) {\n element.removeAttribute(name);\n } else {\n element.setAttribute(name, value === true ? '' : value);\n }\n });\n });\n}\n\nfunction effect(_ref2) {\n var state = _ref2.state;\n var initialStyles = {\n popper: {\n position: state.options.strategy,\n left: '0',\n top: '0',\n margin: '0'\n },\n arrow: {\n position: 'absolute'\n },\n reference: {}\n };\n Object.assign(state.elements.popper.style, initialStyles.popper);\n state.styles = initialStyles;\n\n if (state.elements.arrow) {\n Object.assign(state.elements.arrow.style, initialStyles.arrow);\n }\n\n return function () {\n Object.keys(state.elements).forEach(function (name) {\n var element = state.elements[name];\n var attributes = state.attributes[name] || {};\n var styleProperties = Object.keys(state.styles.hasOwnProperty(name) ? state.styles[name] : initialStyles[name]); // Set all values to an empty string to unset them\n\n var style = styleProperties.reduce(function (style, property) {\n style[property] = '';\n return style;\n }, {}); // arrow is optional + virtual elements\n\n if (!isHTMLElement(element) || !getNodeName(element)) {\n return;\n }\n\n Object.assign(element.style, style);\n Object.keys(attributes).forEach(function (attribute) {\n element.removeAttribute(attribute);\n });\n });\n };\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'applyStyles',\n enabled: true,\n phase: 'write',\n fn: applyStyles,\n effect: effect,\n requires: ['computeStyles']\n};","import { auto } from \"../enums.js\";\nexport default function getBasePlacement(placement) {\n return placement.split('-')[0];\n}","export var max = Math.max;\nexport var min = Math.min;\nexport var round = Math.round;","export default function getUAString() {\n var uaData = navigator.userAgentData;\n\n if (uaData != null && uaData.brands && Array.isArray(uaData.brands)) {\n return uaData.brands.map(function (item) {\n return item.brand + \"/\" + item.version;\n }).join(' ');\n }\n\n return navigator.userAgent;\n}","import getUAString from \"../utils/userAgent.js\";\nexport default function isLayoutViewport() {\n return !/^((?!chrome|android).)*safari/i.test(getUAString());\n}","import { isElement, isHTMLElement } from \"./instanceOf.js\";\nimport { round } from \"../utils/math.js\";\nimport getWindow from \"./getWindow.js\";\nimport isLayoutViewport from \"./isLayoutViewport.js\";\nexport default function getBoundingClientRect(element, includeScale, isFixedStrategy) {\n if (includeScale === void 0) {\n includeScale = false;\n }\n\n if (isFixedStrategy === void 0) {\n isFixedStrategy = false;\n }\n\n var clientRect = element.getBoundingClientRect();\n var scaleX = 1;\n var scaleY = 1;\n\n if (includeScale && isHTMLElement(element)) {\n scaleX = element.offsetWidth > 0 ? round(clientRect.width) / element.offsetWidth || 1 : 1;\n scaleY = element.offsetHeight > 0 ? round(clientRect.height) / element.offsetHeight || 1 : 1;\n }\n\n var _ref = isElement(element) ? getWindow(element) : window,\n visualViewport = _ref.visualViewport;\n\n var addVisualOffsets = !isLayoutViewport() && isFixedStrategy;\n var x = (clientRect.left + (addVisualOffsets && visualViewport ? visualViewport.offsetLeft : 0)) / scaleX;\n var y = (clientRect.top + (addVisualOffsets && visualViewport ? visualViewport.offsetTop : 0)) / scaleY;\n var width = clientRect.width / scaleX;\n var height = clientRect.height / scaleY;\n return {\n width: width,\n height: height,\n top: y,\n right: x + width,\n bottom: y + height,\n left: x,\n x: x,\n y: y\n };\n}","import getBoundingClientRect from \"./getBoundingClientRect.js\"; // Returns the layout rect of an element relative to its offsetParent. Layout\n// means it doesn't take into account transforms.\n\nexport default function getLayoutRect(element) {\n var clientRect = getBoundingClientRect(element); // Use the clientRect sizes if it's not been transformed.\n // Fixes https://github.com/popperjs/popper-core/issues/1223\n\n var width = element.offsetWidth;\n var height = element.offsetHeight;\n\n if (Math.abs(clientRect.width - width) <= 1) {\n width = clientRect.width;\n }\n\n if (Math.abs(clientRect.height - height) <= 1) {\n height = clientRect.height;\n }\n\n return {\n x: element.offsetLeft,\n y: element.offsetTop,\n width: width,\n height: height\n };\n}","import { isShadowRoot } from \"./instanceOf.js\";\nexport default function contains(parent, child) {\n var rootNode = child.getRootNode && child.getRootNode(); // First, attempt with faster native method\n\n if (parent.contains(child)) {\n return true;\n } // then fallback to custom implementation with Shadow DOM support\n else if (rootNode && isShadowRoot(rootNode)) {\n var next = child;\n\n do {\n if (next && parent.isSameNode(next)) {\n return true;\n } // $FlowFixMe[prop-missing]: need a better way to handle this...\n\n\n next = next.parentNode || next.host;\n } while (next);\n } // Give up, the result is false\n\n\n return false;\n}","import getWindow from \"./getWindow.js\";\nexport default function getComputedStyle(element) {\n return getWindow(element).getComputedStyle(element);\n}","import getNodeName from \"./getNodeName.js\";\nexport default function isTableElement(element) {\n return ['table', 'td', 'th'].indexOf(getNodeName(element)) >= 0;\n}","import { isElement } from \"./instanceOf.js\";\nexport default function getDocumentElement(element) {\n // $FlowFixMe[incompatible-return]: assume body is always available\n return ((isElement(element) ? element.ownerDocument : // $FlowFixMe[prop-missing]\n element.document) || window.document).documentElement;\n}","import getNodeName from \"./getNodeName.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport { isShadowRoot } from \"./instanceOf.js\";\nexport default function getParentNode(element) {\n if (getNodeName(element) === 'html') {\n return element;\n }\n\n return (// this is a quicker (but less type safe) way to save quite some bytes from the bundle\n // $FlowFixMe[incompatible-return]\n // $FlowFixMe[prop-missing]\n element.assignedSlot || // step into the shadow DOM of the parent of a slotted node\n element.parentNode || ( // DOM Element detected\n isShadowRoot(element) ? element.host : null) || // ShadowRoot detected\n // $FlowFixMe[incompatible-call]: HTMLElement is a Node\n getDocumentElement(element) // fallback\n\n );\n}","import getWindow from \"./getWindow.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport getComputedStyle from \"./getComputedStyle.js\";\nimport { isHTMLElement, isShadowRoot } from \"./instanceOf.js\";\nimport isTableElement from \"./isTableElement.js\";\nimport getParentNode from \"./getParentNode.js\";\nimport getUAString from \"../utils/userAgent.js\";\n\nfunction getTrueOffsetParent(element) {\n if (!isHTMLElement(element) || // https://github.com/popperjs/popper-core/issues/837\n getComputedStyle(element).position === 'fixed') {\n return null;\n }\n\n return element.offsetParent;\n} // `.offsetParent` reports `null` for fixed elements, while absolute elements\n// return the containing block\n\n\nfunction getContainingBlock(element) {\n var isFirefox = /firefox/i.test(getUAString());\n var isIE = /Trident/i.test(getUAString());\n\n if (isIE && isHTMLElement(element)) {\n // In IE 9, 10 and 11 fixed elements containing block is always established by the viewport\n var elementCss = getComputedStyle(element);\n\n if (elementCss.position === 'fixed') {\n return null;\n }\n }\n\n var currentNode = getParentNode(element);\n\n if (isShadowRoot(currentNode)) {\n currentNode = currentNode.host;\n }\n\n while (isHTMLElement(currentNode) && ['html', 'body'].indexOf(getNodeName(currentNode)) < 0) {\n var css = getComputedStyle(currentNode); // This is non-exhaustive but covers the most common CSS properties that\n // create a containing block.\n // https://developer.mozilla.org/en-US/docs/Web/CSS/Containing_block#identifying_the_containing_block\n\n if (css.transform !== 'none' || css.perspective !== 'none' || css.contain === 'paint' || ['transform', 'perspective'].indexOf(css.willChange) !== -1 || isFirefox && css.willChange === 'filter' || isFirefox && css.filter && css.filter !== 'none') {\n return currentNode;\n } else {\n currentNode = currentNode.parentNode;\n }\n }\n\n return null;\n} // Gets the closest ancestor positioned element. Handles some edge cases,\n// such as table ancestors and cross browser bugs.\n\n\nexport default function getOffsetParent(element) {\n var window = getWindow(element);\n var offsetParent = getTrueOffsetParent(element);\n\n while (offsetParent && isTableElement(offsetParent) && getComputedStyle(offsetParent).position === 'static') {\n offsetParent = getTrueOffsetParent(offsetParent);\n }\n\n if (offsetParent && (getNodeName(offsetParent) === 'html' || getNodeName(offsetParent) === 'body' && getComputedStyle(offsetParent).position === 'static')) {\n return window;\n }\n\n return offsetParent || getContainingBlock(element) || window;\n}","export default function getMainAxisFromPlacement(placement) {\n return ['top', 'bottom'].indexOf(placement) >= 0 ? 'x' : 'y';\n}","import { max as mathMax, min as mathMin } from \"./math.js\";\nexport function within(min, value, max) {\n return mathMax(min, mathMin(value, max));\n}\nexport function withinMaxClamp(min, value, max) {\n var v = within(min, value, max);\n return v > max ? max : v;\n}","export default function getFreshSideObject() {\n return {\n top: 0,\n right: 0,\n bottom: 0,\n left: 0\n };\n}","import getFreshSideObject from \"./getFreshSideObject.js\";\nexport default function mergePaddingObject(paddingObject) {\n return Object.assign({}, getFreshSideObject(), paddingObject);\n}","export default function expandToHashMap(value, keys) {\n return keys.reduce(function (hashMap, key) {\n hashMap[key] = value;\n return hashMap;\n }, {});\n}","import getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getLayoutRect from \"../dom-utils/getLayoutRect.js\";\nimport contains from \"../dom-utils/contains.js\";\nimport getOffsetParent from \"../dom-utils/getOffsetParent.js\";\nimport getMainAxisFromPlacement from \"../utils/getMainAxisFromPlacement.js\";\nimport { within } from \"../utils/within.js\";\nimport mergePaddingObject from \"../utils/mergePaddingObject.js\";\nimport expandToHashMap from \"../utils/expandToHashMap.js\";\nimport { left, right, basePlacements, top, bottom } from \"../enums.js\"; // eslint-disable-next-line import/no-unused-modules\n\nvar toPaddingObject = function toPaddingObject(padding, state) {\n padding = typeof padding === 'function' ? padding(Object.assign({}, state.rects, {\n placement: state.placement\n })) : padding;\n return mergePaddingObject(typeof padding !== 'number' ? padding : expandToHashMap(padding, basePlacements));\n};\n\nfunction arrow(_ref) {\n var _state$modifiersData$;\n\n var state = _ref.state,\n name = _ref.name,\n options = _ref.options;\n var arrowElement = state.elements.arrow;\n var popperOffsets = state.modifiersData.popperOffsets;\n var basePlacement = getBasePlacement(state.placement);\n var axis = getMainAxisFromPlacement(basePlacement);\n var isVertical = [left, right].indexOf(basePlacement) >= 0;\n var len = isVertical ? 'height' : 'width';\n\n if (!arrowElement || !popperOffsets) {\n return;\n }\n\n var paddingObject = toPaddingObject(options.padding, state);\n var arrowRect = getLayoutRect(arrowElement);\n var minProp = axis === 'y' ? top : left;\n var maxProp = axis === 'y' ? bottom : right;\n var endDiff = state.rects.reference[len] + state.rects.reference[axis] - popperOffsets[axis] - state.rects.popper[len];\n var startDiff = popperOffsets[axis] - state.rects.reference[axis];\n var arrowOffsetParent = getOffsetParent(arrowElement);\n var clientSize = arrowOffsetParent ? axis === 'y' ? arrowOffsetParent.clientHeight || 0 : arrowOffsetParent.clientWidth || 0 : 0;\n var centerToReference = endDiff / 2 - startDiff / 2; // Make sure the arrow doesn't overflow the popper if the center point is\n // outside of the popper bounds\n\n var min = paddingObject[minProp];\n var max = clientSize - arrowRect[len] - paddingObject[maxProp];\n var center = clientSize / 2 - arrowRect[len] / 2 + centerToReference;\n var offset = within(min, center, max); // Prevents breaking syntax highlighting...\n\n var axisProp = axis;\n state.modifiersData[name] = (_state$modifiersData$ = {}, _state$modifiersData$[axisProp] = offset, _state$modifiersData$.centerOffset = offset - center, _state$modifiersData$);\n}\n\nfunction effect(_ref2) {\n var state = _ref2.state,\n options = _ref2.options;\n var _options$element = options.element,\n arrowElement = _options$element === void 0 ? '[data-popper-arrow]' : _options$element;\n\n if (arrowElement == null) {\n return;\n } // CSS selector\n\n\n if (typeof arrowElement === 'string') {\n arrowElement = state.elements.popper.querySelector(arrowElement);\n\n if (!arrowElement) {\n return;\n }\n }\n\n if (!contains(state.elements.popper, arrowElement)) {\n return;\n }\n\n state.elements.arrow = arrowElement;\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'arrow',\n enabled: true,\n phase: 'main',\n fn: arrow,\n effect: effect,\n requires: ['popperOffsets'],\n requiresIfExists: ['preventOverflow']\n};","export default function getVariation(placement) {\n return placement.split('-')[1];\n}","import { top, left, right, bottom, end } from \"../enums.js\";\nimport getOffsetParent from \"../dom-utils/getOffsetParent.js\";\nimport getWindow from \"../dom-utils/getWindow.js\";\nimport getDocumentElement from \"../dom-utils/getDocumentElement.js\";\nimport getComputedStyle from \"../dom-utils/getComputedStyle.js\";\nimport getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getVariation from \"../utils/getVariation.js\";\nimport { round } from \"../utils/math.js\"; // eslint-disable-next-line import/no-unused-modules\n\nvar unsetSides = {\n top: 'auto',\n right: 'auto',\n bottom: 'auto',\n left: 'auto'\n}; // Round the offsets to the nearest suitable subpixel based on the DPR.\n// Zooming can change the DPR, but it seems to report a value that will\n// cleanly divide the values into the appropriate subpixels.\n\nfunction roundOffsetsByDPR(_ref, win) {\n var x = _ref.x,\n y = _ref.y;\n var dpr = win.devicePixelRatio || 1;\n return {\n x: round(x * dpr) / dpr || 0,\n y: round(y * dpr) / dpr || 0\n };\n}\n\nexport function mapToStyles(_ref2) {\n var _Object$assign2;\n\n var popper = _ref2.popper,\n popperRect = _ref2.popperRect,\n placement = _ref2.placement,\n variation = _ref2.variation,\n offsets = _ref2.offsets,\n position = _ref2.position,\n gpuAcceleration = _ref2.gpuAcceleration,\n adaptive = _ref2.adaptive,\n roundOffsets = _ref2.roundOffsets,\n isFixed = _ref2.isFixed;\n var _offsets$x = offsets.x,\n x = _offsets$x === void 0 ? 0 : _offsets$x,\n _offsets$y = offsets.y,\n y = _offsets$y === void 0 ? 0 : _offsets$y;\n\n var _ref3 = typeof roundOffsets === 'function' ? roundOffsets({\n x: x,\n y: y\n }) : {\n x: x,\n y: y\n };\n\n x = _ref3.x;\n y = _ref3.y;\n var hasX = offsets.hasOwnProperty('x');\n var hasY = offsets.hasOwnProperty('y');\n var sideX = left;\n var sideY = top;\n var win = window;\n\n if (adaptive) {\n var offsetParent = getOffsetParent(popper);\n var heightProp = 'clientHeight';\n var widthProp = 'clientWidth';\n\n if (offsetParent === getWindow(popper)) {\n offsetParent = getDocumentElement(popper);\n\n if (getComputedStyle(offsetParent).position !== 'static' && position === 'absolute') {\n heightProp = 'scrollHeight';\n widthProp = 'scrollWidth';\n }\n } // $FlowFixMe[incompatible-cast]: force type refinement, we compare offsetParent with window above, but Flow doesn't detect it\n\n\n offsetParent = offsetParent;\n\n if (placement === top || (placement === left || placement === right) && variation === end) {\n sideY = bottom;\n var offsetY = isFixed && offsetParent === win && win.visualViewport ? win.visualViewport.height : // $FlowFixMe[prop-missing]\n offsetParent[heightProp];\n y -= offsetY - popperRect.height;\n y *= gpuAcceleration ? 1 : -1;\n }\n\n if (placement === left || (placement === top || placement === bottom) && variation === end) {\n sideX = right;\n var offsetX = isFixed && offsetParent === win && win.visualViewport ? win.visualViewport.width : // $FlowFixMe[prop-missing]\n offsetParent[widthProp];\n x -= offsetX - popperRect.width;\n x *= gpuAcceleration ? 1 : -1;\n }\n }\n\n var commonStyles = Object.assign({\n position: position\n }, adaptive && unsetSides);\n\n var _ref4 = roundOffsets === true ? roundOffsetsByDPR({\n x: x,\n y: y\n }, getWindow(popper)) : {\n x: x,\n y: y\n };\n\n x = _ref4.x;\n y = _ref4.y;\n\n if (gpuAcceleration) {\n var _Object$assign;\n\n return Object.assign({}, commonStyles, (_Object$assign = {}, _Object$assign[sideY] = hasY ? '0' : '', _Object$assign[sideX] = hasX ? '0' : '', _Object$assign.transform = (win.devicePixelRatio || 1) <= 1 ? \"translate(\" + x + \"px, \" + y + \"px)\" : \"translate3d(\" + x + \"px, \" + y + \"px, 0)\", _Object$assign));\n }\n\n return Object.assign({}, commonStyles, (_Object$assign2 = {}, _Object$assign2[sideY] = hasY ? y + \"px\" : '', _Object$assign2[sideX] = hasX ? x + \"px\" : '', _Object$assign2.transform = '', _Object$assign2));\n}\n\nfunction computeStyles(_ref5) {\n var state = _ref5.state,\n options = _ref5.options;\n var _options$gpuAccelerat = options.gpuAcceleration,\n gpuAcceleration = _options$gpuAccelerat === void 0 ? true : _options$gpuAccelerat,\n _options$adaptive = options.adaptive,\n adaptive = _options$adaptive === void 0 ? true : _options$adaptive,\n _options$roundOffsets = options.roundOffsets,\n roundOffsets = _options$roundOffsets === void 0 ? true : _options$roundOffsets;\n var commonStyles = {\n placement: getBasePlacement(state.placement),\n variation: getVariation(state.placement),\n popper: state.elements.popper,\n popperRect: state.rects.popper,\n gpuAcceleration: gpuAcceleration,\n isFixed: state.options.strategy === 'fixed'\n };\n\n if (state.modifiersData.popperOffsets != null) {\n state.styles.popper = Object.assign({}, state.styles.popper, mapToStyles(Object.assign({}, commonStyles, {\n offsets: state.modifiersData.popperOffsets,\n position: state.options.strategy,\n adaptive: adaptive,\n roundOffsets: roundOffsets\n })));\n }\n\n if (state.modifiersData.arrow != null) {\n state.styles.arrow = Object.assign({}, state.styles.arrow, mapToStyles(Object.assign({}, commonStyles, {\n offsets: state.modifiersData.arrow,\n position: 'absolute',\n adaptive: false,\n roundOffsets: roundOffsets\n })));\n }\n\n state.attributes.popper = Object.assign({}, state.attributes.popper, {\n 'data-popper-placement': state.placement\n });\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'computeStyles',\n enabled: true,\n phase: 'beforeWrite',\n fn: computeStyles,\n data: {}\n};","import getWindow from \"../dom-utils/getWindow.js\"; // eslint-disable-next-line import/no-unused-modules\n\nvar passive = {\n passive: true\n};\n\nfunction effect(_ref) {\n var state = _ref.state,\n instance = _ref.instance,\n options = _ref.options;\n var _options$scroll = options.scroll,\n scroll = _options$scroll === void 0 ? true : _options$scroll,\n _options$resize = options.resize,\n resize = _options$resize === void 0 ? true : _options$resize;\n var window = getWindow(state.elements.popper);\n var scrollParents = [].concat(state.scrollParents.reference, state.scrollParents.popper);\n\n if (scroll) {\n scrollParents.forEach(function (scrollParent) {\n scrollParent.addEventListener('scroll', instance.update, passive);\n });\n }\n\n if (resize) {\n window.addEventListener('resize', instance.update, passive);\n }\n\n return function () {\n if (scroll) {\n scrollParents.forEach(function (scrollParent) {\n scrollParent.removeEventListener('scroll', instance.update, passive);\n });\n }\n\n if (resize) {\n window.removeEventListener('resize', instance.update, passive);\n }\n };\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'eventListeners',\n enabled: true,\n phase: 'write',\n fn: function fn() {},\n effect: effect,\n data: {}\n};","var hash = {\n left: 'right',\n right: 'left',\n bottom: 'top',\n top: 'bottom'\n};\nexport default function getOppositePlacement(placement) {\n return placement.replace(/left|right|bottom|top/g, function (matched) {\n return hash[matched];\n });\n}","var hash = {\n start: 'end',\n end: 'start'\n};\nexport default function getOppositeVariationPlacement(placement) {\n return placement.replace(/start|end/g, function (matched) {\n return hash[matched];\n });\n}","import getWindow from \"./getWindow.js\";\nexport default function getWindowScroll(node) {\n var win = getWindow(node);\n var scrollLeft = win.pageXOffset;\n var scrollTop = win.pageYOffset;\n return {\n scrollLeft: scrollLeft,\n scrollTop: scrollTop\n };\n}","import getBoundingClientRect from \"./getBoundingClientRect.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport getWindowScroll from \"./getWindowScroll.js\";\nexport default function getWindowScrollBarX(element) {\n // If has a CSS width greater than the viewport, then this will be\n // incorrect for RTL.\n // Popper 1 is broken in this case and never had a bug report so let's assume\n // it's not an issue. I don't think anyone ever specifies width on \n // anyway.\n // Browsers where the left scrollbar doesn't cause an issue report `0` for\n // this (e.g. Edge 2019, IE11, Safari)\n return getBoundingClientRect(getDocumentElement(element)).left + getWindowScroll(element).scrollLeft;\n}","import getWindow from \"./getWindow.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport getWindowScrollBarX from \"./getWindowScrollBarX.js\";\nimport isLayoutViewport from \"./isLayoutViewport.js\";\nexport default function getViewportRect(element, strategy) {\n var win = getWindow(element);\n var html = getDocumentElement(element);\n var visualViewport = win.visualViewport;\n var width = html.clientWidth;\n var height = html.clientHeight;\n var x = 0;\n var y = 0;\n\n if (visualViewport) {\n width = visualViewport.width;\n height = visualViewport.height;\n var layoutViewport = isLayoutViewport();\n\n if (layoutViewport || !layoutViewport && strategy === 'fixed') {\n x = visualViewport.offsetLeft;\n y = visualViewport.offsetTop;\n }\n }\n\n return {\n width: width,\n height: height,\n x: x + getWindowScrollBarX(element),\n y: y\n };\n}","import getDocumentElement from \"./getDocumentElement.js\";\nimport getComputedStyle from \"./getComputedStyle.js\";\nimport getWindowScrollBarX from \"./getWindowScrollBarX.js\";\nimport getWindowScroll from \"./getWindowScroll.js\";\nimport { max } from \"../utils/math.js\"; // Gets the entire size of the scrollable document area, even extending outside\n// of the `` and `` rect bounds if horizontally scrollable\n\nexport default function getDocumentRect(element) {\n var _element$ownerDocumen;\n\n var html = getDocumentElement(element);\n var winScroll = getWindowScroll(element);\n var body = (_element$ownerDocumen = element.ownerDocument) == null ? void 0 : _element$ownerDocumen.body;\n var width = max(html.scrollWidth, html.clientWidth, body ? body.scrollWidth : 0, body ? body.clientWidth : 0);\n var height = max(html.scrollHeight, html.clientHeight, body ? body.scrollHeight : 0, body ? body.clientHeight : 0);\n var x = -winScroll.scrollLeft + getWindowScrollBarX(element);\n var y = -winScroll.scrollTop;\n\n if (getComputedStyle(body || html).direction === 'rtl') {\n x += max(html.clientWidth, body ? body.clientWidth : 0) - width;\n }\n\n return {\n width: width,\n height: height,\n x: x,\n y: y\n };\n}","import getComputedStyle from \"./getComputedStyle.js\";\nexport default function isScrollParent(element) {\n // Firefox wants us to check `-x` and `-y` variations as well\n var _getComputedStyle = getComputedStyle(element),\n overflow = _getComputedStyle.overflow,\n overflowX = _getComputedStyle.overflowX,\n overflowY = _getComputedStyle.overflowY;\n\n return /auto|scroll|overlay|hidden/.test(overflow + overflowY + overflowX);\n}","import getParentNode from \"./getParentNode.js\";\nimport isScrollParent from \"./isScrollParent.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport { isHTMLElement } from \"./instanceOf.js\";\nexport default function getScrollParent(node) {\n if (['html', 'body', '#document'].indexOf(getNodeName(node)) >= 0) {\n // $FlowFixMe[incompatible-return]: assume body is always available\n return node.ownerDocument.body;\n }\n\n if (isHTMLElement(node) && isScrollParent(node)) {\n return node;\n }\n\n return getScrollParent(getParentNode(node));\n}","import getScrollParent from \"./getScrollParent.js\";\nimport getParentNode from \"./getParentNode.js\";\nimport getWindow from \"./getWindow.js\";\nimport isScrollParent from \"./isScrollParent.js\";\n/*\ngiven a DOM element, return the list of all scroll parents, up the list of ancesors\nuntil we get to the top window object. This list is what we attach scroll listeners\nto, because if any of these parent elements scroll, we'll need to re-calculate the\nreference element's position.\n*/\n\nexport default function listScrollParents(element, list) {\n var _element$ownerDocumen;\n\n if (list === void 0) {\n list = [];\n }\n\n var scrollParent = getScrollParent(element);\n var isBody = scrollParent === ((_element$ownerDocumen = element.ownerDocument) == null ? void 0 : _element$ownerDocumen.body);\n var win = getWindow(scrollParent);\n var target = isBody ? [win].concat(win.visualViewport || [], isScrollParent(scrollParent) ? scrollParent : []) : scrollParent;\n var updatedList = list.concat(target);\n return isBody ? updatedList : // $FlowFixMe[incompatible-call]: isBody tells us target will be an HTMLElement here\n updatedList.concat(listScrollParents(getParentNode(target)));\n}","export default function rectToClientRect(rect) {\n return Object.assign({}, rect, {\n left: rect.x,\n top: rect.y,\n right: rect.x + rect.width,\n bottom: rect.y + rect.height\n });\n}","import { viewport } from \"../enums.js\";\nimport getViewportRect from \"./getViewportRect.js\";\nimport getDocumentRect from \"./getDocumentRect.js\";\nimport listScrollParents from \"./listScrollParents.js\";\nimport getOffsetParent from \"./getOffsetParent.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport getComputedStyle from \"./getComputedStyle.js\";\nimport { isElement, isHTMLElement } from \"./instanceOf.js\";\nimport getBoundingClientRect from \"./getBoundingClientRect.js\";\nimport getParentNode from \"./getParentNode.js\";\nimport contains from \"./contains.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport rectToClientRect from \"../utils/rectToClientRect.js\";\nimport { max, min } from \"../utils/math.js\";\n\nfunction getInnerBoundingClientRect(element, strategy) {\n var rect = getBoundingClientRect(element, false, strategy === 'fixed');\n rect.top = rect.top + element.clientTop;\n rect.left = rect.left + element.clientLeft;\n rect.bottom = rect.top + element.clientHeight;\n rect.right = rect.left + element.clientWidth;\n rect.width = element.clientWidth;\n rect.height = element.clientHeight;\n rect.x = rect.left;\n rect.y = rect.top;\n return rect;\n}\n\nfunction getClientRectFromMixedType(element, clippingParent, strategy) {\n return clippingParent === viewport ? rectToClientRect(getViewportRect(element, strategy)) : isElement(clippingParent) ? getInnerBoundingClientRect(clippingParent, strategy) : rectToClientRect(getDocumentRect(getDocumentElement(element)));\n} // A \"clipping parent\" is an overflowable container with the characteristic of\n// clipping (or hiding) overflowing elements with a position different from\n// `initial`\n\n\nfunction getClippingParents(element) {\n var clippingParents = listScrollParents(getParentNode(element));\n var canEscapeClipping = ['absolute', 'fixed'].indexOf(getComputedStyle(element).position) >= 0;\n var clipperElement = canEscapeClipping && isHTMLElement(element) ? getOffsetParent(element) : element;\n\n if (!isElement(clipperElement)) {\n return [];\n } // $FlowFixMe[incompatible-return]: https://github.com/facebook/flow/issues/1414\n\n\n return clippingParents.filter(function (clippingParent) {\n return isElement(clippingParent) && contains(clippingParent, clipperElement) && getNodeName(clippingParent) !== 'body';\n });\n} // Gets the maximum area that the element is visible in due to any number of\n// clipping parents\n\n\nexport default function getClippingRect(element, boundary, rootBoundary, strategy) {\n var mainClippingParents = boundary === 'clippingParents' ? getClippingParents(element) : [].concat(boundary);\n var clippingParents = [].concat(mainClippingParents, [rootBoundary]);\n var firstClippingParent = clippingParents[0];\n var clippingRect = clippingParents.reduce(function (accRect, clippingParent) {\n var rect = getClientRectFromMixedType(element, clippingParent, strategy);\n accRect.top = max(rect.top, accRect.top);\n accRect.right = min(rect.right, accRect.right);\n accRect.bottom = min(rect.bottom, accRect.bottom);\n accRect.left = max(rect.left, accRect.left);\n return accRect;\n }, getClientRectFromMixedType(element, firstClippingParent, strategy));\n clippingRect.width = clippingRect.right - clippingRect.left;\n clippingRect.height = clippingRect.bottom - clippingRect.top;\n clippingRect.x = clippingRect.left;\n clippingRect.y = clippingRect.top;\n return clippingRect;\n}","import getBasePlacement from \"./getBasePlacement.js\";\nimport getVariation from \"./getVariation.js\";\nimport getMainAxisFromPlacement from \"./getMainAxisFromPlacement.js\";\nimport { top, right, bottom, left, start, end } from \"../enums.js\";\nexport default function computeOffsets(_ref) {\n var reference = _ref.reference,\n element = _ref.element,\n placement = _ref.placement;\n var basePlacement = placement ? getBasePlacement(placement) : null;\n var variation = placement ? getVariation(placement) : null;\n var commonX = reference.x + reference.width / 2 - element.width / 2;\n var commonY = reference.y + reference.height / 2 - element.height / 2;\n var offsets;\n\n switch (basePlacement) {\n case top:\n offsets = {\n x: commonX,\n y: reference.y - element.height\n };\n break;\n\n case bottom:\n offsets = {\n x: commonX,\n y: reference.y + reference.height\n };\n break;\n\n case right:\n offsets = {\n x: reference.x + reference.width,\n y: commonY\n };\n break;\n\n case left:\n offsets = {\n x: reference.x - element.width,\n y: commonY\n };\n break;\n\n default:\n offsets = {\n x: reference.x,\n y: reference.y\n };\n }\n\n var mainAxis = basePlacement ? getMainAxisFromPlacement(basePlacement) : null;\n\n if (mainAxis != null) {\n var len = mainAxis === 'y' ? 'height' : 'width';\n\n switch (variation) {\n case start:\n offsets[mainAxis] = offsets[mainAxis] - (reference[len] / 2 - element[len] / 2);\n break;\n\n case end:\n offsets[mainAxis] = offsets[mainAxis] + (reference[len] / 2 - element[len] / 2);\n break;\n\n default:\n }\n }\n\n return offsets;\n}","import getClippingRect from \"../dom-utils/getClippingRect.js\";\nimport getDocumentElement from \"../dom-utils/getDocumentElement.js\";\nimport getBoundingClientRect from \"../dom-utils/getBoundingClientRect.js\";\nimport computeOffsets from \"./computeOffsets.js\";\nimport rectToClientRect from \"./rectToClientRect.js\";\nimport { clippingParents, reference, popper, bottom, top, right, basePlacements, viewport } from \"../enums.js\";\nimport { isElement } from \"../dom-utils/instanceOf.js\";\nimport mergePaddingObject from \"./mergePaddingObject.js\";\nimport expandToHashMap from \"./expandToHashMap.js\"; // eslint-disable-next-line import/no-unused-modules\n\nexport default function detectOverflow(state, options) {\n if (options === void 0) {\n options = {};\n }\n\n var _options = options,\n _options$placement = _options.placement,\n placement = _options$placement === void 0 ? state.placement : _options$placement,\n _options$strategy = _options.strategy,\n strategy = _options$strategy === void 0 ? state.strategy : _options$strategy,\n _options$boundary = _options.boundary,\n boundary = _options$boundary === void 0 ? clippingParents : _options$boundary,\n _options$rootBoundary = _options.rootBoundary,\n rootBoundary = _options$rootBoundary === void 0 ? viewport : _options$rootBoundary,\n _options$elementConte = _options.elementContext,\n elementContext = _options$elementConte === void 0 ? popper : _options$elementConte,\n _options$altBoundary = _options.altBoundary,\n altBoundary = _options$altBoundary === void 0 ? false : _options$altBoundary,\n _options$padding = _options.padding,\n padding = _options$padding === void 0 ? 0 : _options$padding;\n var paddingObject = mergePaddingObject(typeof padding !== 'number' ? padding : expandToHashMap(padding, basePlacements));\n var altContext = elementContext === popper ? reference : popper;\n var popperRect = state.rects.popper;\n var element = state.elements[altBoundary ? altContext : elementContext];\n var clippingClientRect = getClippingRect(isElement(element) ? element : element.contextElement || getDocumentElement(state.elements.popper), boundary, rootBoundary, strategy);\n var referenceClientRect = getBoundingClientRect(state.elements.reference);\n var popperOffsets = computeOffsets({\n reference: referenceClientRect,\n element: popperRect,\n strategy: 'absolute',\n placement: placement\n });\n var popperClientRect = rectToClientRect(Object.assign({}, popperRect, popperOffsets));\n var elementClientRect = elementContext === popper ? popperClientRect : referenceClientRect; // positive = overflowing the clipping rect\n // 0 or negative = within the clipping rect\n\n var overflowOffsets = {\n top: clippingClientRect.top - elementClientRect.top + paddingObject.top,\n bottom: elementClientRect.bottom - clippingClientRect.bottom + paddingObject.bottom,\n left: clippingClientRect.left - elementClientRect.left + paddingObject.left,\n right: elementClientRect.right - clippingClientRect.right + paddingObject.right\n };\n var offsetData = state.modifiersData.offset; // Offsets can be applied only to the popper element\n\n if (elementContext === popper && offsetData) {\n var offset = offsetData[placement];\n Object.keys(overflowOffsets).forEach(function (key) {\n var multiply = [right, bottom].indexOf(key) >= 0 ? 1 : -1;\n var axis = [top, bottom].indexOf(key) >= 0 ? 'y' : 'x';\n overflowOffsets[key] += offset[axis] * multiply;\n });\n }\n\n return overflowOffsets;\n}","import getVariation from \"./getVariation.js\";\nimport { variationPlacements, basePlacements, placements as allPlacements } from \"../enums.js\";\nimport detectOverflow from \"./detectOverflow.js\";\nimport getBasePlacement from \"./getBasePlacement.js\";\nexport default function computeAutoPlacement(state, options) {\n if (options === void 0) {\n options = {};\n }\n\n var _options = options,\n placement = _options.placement,\n boundary = _options.boundary,\n rootBoundary = _options.rootBoundary,\n padding = _options.padding,\n flipVariations = _options.flipVariations,\n _options$allowedAutoP = _options.allowedAutoPlacements,\n allowedAutoPlacements = _options$allowedAutoP === void 0 ? allPlacements : _options$allowedAutoP;\n var variation = getVariation(placement);\n var placements = variation ? flipVariations ? variationPlacements : variationPlacements.filter(function (placement) {\n return getVariation(placement) === variation;\n }) : basePlacements;\n var allowedPlacements = placements.filter(function (placement) {\n return allowedAutoPlacements.indexOf(placement) >= 0;\n });\n\n if (allowedPlacements.length === 0) {\n allowedPlacements = placements;\n } // $FlowFixMe[incompatible-type]: Flow seems to have problems with two array unions...\n\n\n var overflows = allowedPlacements.reduce(function (acc, placement) {\n acc[placement] = detectOverflow(state, {\n placement: placement,\n boundary: boundary,\n rootBoundary: rootBoundary,\n padding: padding\n })[getBasePlacement(placement)];\n return acc;\n }, {});\n return Object.keys(overflows).sort(function (a, b) {\n return overflows[a] - overflows[b];\n });\n}","import getOppositePlacement from \"../utils/getOppositePlacement.js\";\nimport getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getOppositeVariationPlacement from \"../utils/getOppositeVariationPlacement.js\";\nimport detectOverflow from \"../utils/detectOverflow.js\";\nimport computeAutoPlacement from \"../utils/computeAutoPlacement.js\";\nimport { bottom, top, start, right, left, auto } from \"../enums.js\";\nimport getVariation from \"../utils/getVariation.js\"; // eslint-disable-next-line import/no-unused-modules\n\nfunction getExpandedFallbackPlacements(placement) {\n if (getBasePlacement(placement) === auto) {\n return [];\n }\n\n var oppositePlacement = getOppositePlacement(placement);\n return [getOppositeVariationPlacement(placement), oppositePlacement, getOppositeVariationPlacement(oppositePlacement)];\n}\n\nfunction flip(_ref) {\n var state = _ref.state,\n options = _ref.options,\n name = _ref.name;\n\n if (state.modifiersData[name]._skip) {\n return;\n }\n\n var _options$mainAxis = options.mainAxis,\n checkMainAxis = _options$mainAxis === void 0 ? true : _options$mainAxis,\n _options$altAxis = options.altAxis,\n checkAltAxis = _options$altAxis === void 0 ? true : _options$altAxis,\n specifiedFallbackPlacements = options.fallbackPlacements,\n padding = options.padding,\n boundary = options.boundary,\n rootBoundary = options.rootBoundary,\n altBoundary = options.altBoundary,\n _options$flipVariatio = options.flipVariations,\n flipVariations = _options$flipVariatio === void 0 ? true : _options$flipVariatio,\n allowedAutoPlacements = options.allowedAutoPlacements;\n var preferredPlacement = state.options.placement;\n var basePlacement = getBasePlacement(preferredPlacement);\n var isBasePlacement = basePlacement === preferredPlacement;\n var fallbackPlacements = specifiedFallbackPlacements || (isBasePlacement || !flipVariations ? [getOppositePlacement(preferredPlacement)] : getExpandedFallbackPlacements(preferredPlacement));\n var placements = [preferredPlacement].concat(fallbackPlacements).reduce(function (acc, placement) {\n return acc.concat(getBasePlacement(placement) === auto ? computeAutoPlacement(state, {\n placement: placement,\n boundary: boundary,\n rootBoundary: rootBoundary,\n padding: padding,\n flipVariations: flipVariations,\n allowedAutoPlacements: allowedAutoPlacements\n }) : placement);\n }, []);\n var referenceRect = state.rects.reference;\n var popperRect = state.rects.popper;\n var checksMap = new Map();\n var makeFallbackChecks = true;\n var firstFittingPlacement = placements[0];\n\n for (var i = 0; i < placements.length; i++) {\n var placement = placements[i];\n\n var _basePlacement = getBasePlacement(placement);\n\n var isStartVariation = getVariation(placement) === start;\n var isVertical = [top, bottom].indexOf(_basePlacement) >= 0;\n var len = isVertical ? 'width' : 'height';\n var overflow = detectOverflow(state, {\n placement: placement,\n boundary: boundary,\n rootBoundary: rootBoundary,\n altBoundary: altBoundary,\n padding: padding\n });\n var mainVariationSide = isVertical ? isStartVariation ? right : left : isStartVariation ? bottom : top;\n\n if (referenceRect[len] > popperRect[len]) {\n mainVariationSide = getOppositePlacement(mainVariationSide);\n }\n\n var altVariationSide = getOppositePlacement(mainVariationSide);\n var checks = [];\n\n if (checkMainAxis) {\n checks.push(overflow[_basePlacement] <= 0);\n }\n\n if (checkAltAxis) {\n checks.push(overflow[mainVariationSide] <= 0, overflow[altVariationSide] <= 0);\n }\n\n if (checks.every(function (check) {\n return check;\n })) {\n firstFittingPlacement = placement;\n makeFallbackChecks = false;\n break;\n }\n\n checksMap.set(placement, checks);\n }\n\n if (makeFallbackChecks) {\n // `2` may be desired in some cases – research later\n var numberOfChecks = flipVariations ? 3 : 1;\n\n var _loop = function _loop(_i) {\n var fittingPlacement = placements.find(function (placement) {\n var checks = checksMap.get(placement);\n\n if (checks) {\n return checks.slice(0, _i).every(function (check) {\n return check;\n });\n }\n });\n\n if (fittingPlacement) {\n firstFittingPlacement = fittingPlacement;\n return \"break\";\n }\n };\n\n for (var _i = numberOfChecks; _i > 0; _i--) {\n var _ret = _loop(_i);\n\n if (_ret === \"break\") break;\n }\n }\n\n if (state.placement !== firstFittingPlacement) {\n state.modifiersData[name]._skip = true;\n state.placement = firstFittingPlacement;\n state.reset = true;\n }\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'flip',\n enabled: true,\n phase: 'main',\n fn: flip,\n requiresIfExists: ['offset'],\n data: {\n _skip: false\n }\n};","import { top, bottom, left, right } from \"../enums.js\";\nimport detectOverflow from \"../utils/detectOverflow.js\";\n\nfunction getSideOffsets(overflow, rect, preventedOffsets) {\n if (preventedOffsets === void 0) {\n preventedOffsets = {\n x: 0,\n y: 0\n };\n }\n\n return {\n top: overflow.top - rect.height - preventedOffsets.y,\n right: overflow.right - rect.width + preventedOffsets.x,\n bottom: overflow.bottom - rect.height + preventedOffsets.y,\n left: overflow.left - rect.width - preventedOffsets.x\n };\n}\n\nfunction isAnySideFullyClipped(overflow) {\n return [top, right, bottom, left].some(function (side) {\n return overflow[side] >= 0;\n });\n}\n\nfunction hide(_ref) {\n var state = _ref.state,\n name = _ref.name;\n var referenceRect = state.rects.reference;\n var popperRect = state.rects.popper;\n var preventedOffsets = state.modifiersData.preventOverflow;\n var referenceOverflow = detectOverflow(state, {\n elementContext: 'reference'\n });\n var popperAltOverflow = detectOverflow(state, {\n altBoundary: true\n });\n var referenceClippingOffsets = getSideOffsets(referenceOverflow, referenceRect);\n var popperEscapeOffsets = getSideOffsets(popperAltOverflow, popperRect, preventedOffsets);\n var isReferenceHidden = isAnySideFullyClipped(referenceClippingOffsets);\n var hasPopperEscaped = isAnySideFullyClipped(popperEscapeOffsets);\n state.modifiersData[name] = {\n referenceClippingOffsets: referenceClippingOffsets,\n popperEscapeOffsets: popperEscapeOffsets,\n isReferenceHidden: isReferenceHidden,\n hasPopperEscaped: hasPopperEscaped\n };\n state.attributes.popper = Object.assign({}, state.attributes.popper, {\n 'data-popper-reference-hidden': isReferenceHidden,\n 'data-popper-escaped': hasPopperEscaped\n });\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'hide',\n enabled: true,\n phase: 'main',\n requiresIfExists: ['preventOverflow'],\n fn: hide\n};","import getBasePlacement from \"../utils/getBasePlacement.js\";\nimport { top, left, right, placements } from \"../enums.js\"; // eslint-disable-next-line import/no-unused-modules\n\nexport function distanceAndSkiddingToXY(placement, rects, offset) {\n var basePlacement = getBasePlacement(placement);\n var invertDistance = [left, top].indexOf(basePlacement) >= 0 ? -1 : 1;\n\n var _ref = typeof offset === 'function' ? offset(Object.assign({}, rects, {\n placement: placement\n })) : offset,\n skidding = _ref[0],\n distance = _ref[1];\n\n skidding = skidding || 0;\n distance = (distance || 0) * invertDistance;\n return [left, right].indexOf(basePlacement) >= 0 ? {\n x: distance,\n y: skidding\n } : {\n x: skidding,\n y: distance\n };\n}\n\nfunction offset(_ref2) {\n var state = _ref2.state,\n options = _ref2.options,\n name = _ref2.name;\n var _options$offset = options.offset,\n offset = _options$offset === void 0 ? [0, 0] : _options$offset;\n var data = placements.reduce(function (acc, placement) {\n acc[placement] = distanceAndSkiddingToXY(placement, state.rects, offset);\n return acc;\n }, {});\n var _data$state$placement = data[state.placement],\n x = _data$state$placement.x,\n y = _data$state$placement.y;\n\n if (state.modifiersData.popperOffsets != null) {\n state.modifiersData.popperOffsets.x += x;\n state.modifiersData.popperOffsets.y += y;\n }\n\n state.modifiersData[name] = data;\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'offset',\n enabled: true,\n phase: 'main',\n requires: ['popperOffsets'],\n fn: offset\n};","import computeOffsets from \"../utils/computeOffsets.js\";\n\nfunction popperOffsets(_ref) {\n var state = _ref.state,\n name = _ref.name;\n // Offsets are the actual position the popper needs to have to be\n // properly positioned near its reference element\n // This is the most basic placement, and will be adjusted by\n // the modifiers in the next step\n state.modifiersData[name] = computeOffsets({\n reference: state.rects.reference,\n element: state.rects.popper,\n strategy: 'absolute',\n placement: state.placement\n });\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'popperOffsets',\n enabled: true,\n phase: 'read',\n fn: popperOffsets,\n data: {}\n};","export default function getAltAxis(axis) {\n return axis === 'x' ? 'y' : 'x';\n}","import { top, left, right, bottom, start } from \"../enums.js\";\nimport getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getMainAxisFromPlacement from \"../utils/getMainAxisFromPlacement.js\";\nimport getAltAxis from \"../utils/getAltAxis.js\";\nimport { within, withinMaxClamp } from \"../utils/within.js\";\nimport getLayoutRect from \"../dom-utils/getLayoutRect.js\";\nimport getOffsetParent from \"../dom-utils/getOffsetParent.js\";\nimport detectOverflow from \"../utils/detectOverflow.js\";\nimport getVariation from \"../utils/getVariation.js\";\nimport getFreshSideObject from \"../utils/getFreshSideObject.js\";\nimport { min as mathMin, max as mathMax } from \"../utils/math.js\";\n\nfunction preventOverflow(_ref) {\n var state = _ref.state,\n options = _ref.options,\n name = _ref.name;\n var _options$mainAxis = options.mainAxis,\n checkMainAxis = _options$mainAxis === void 0 ? true : _options$mainAxis,\n _options$altAxis = options.altAxis,\n checkAltAxis = _options$altAxis === void 0 ? false : _options$altAxis,\n boundary = options.boundary,\n rootBoundary = options.rootBoundary,\n altBoundary = options.altBoundary,\n padding = options.padding,\n _options$tether = options.tether,\n tether = _options$tether === void 0 ? true : _options$tether,\n _options$tetherOffset = options.tetherOffset,\n tetherOffset = _options$tetherOffset === void 0 ? 0 : _options$tetherOffset;\n var overflow = detectOverflow(state, {\n boundary: boundary,\n rootBoundary: rootBoundary,\n padding: padding,\n altBoundary: altBoundary\n });\n var basePlacement = getBasePlacement(state.placement);\n var variation = getVariation(state.placement);\n var isBasePlacement = !variation;\n var mainAxis = getMainAxisFromPlacement(basePlacement);\n var altAxis = getAltAxis(mainAxis);\n var popperOffsets = state.modifiersData.popperOffsets;\n var referenceRect = state.rects.reference;\n var popperRect = state.rects.popper;\n var tetherOffsetValue = typeof tetherOffset === 'function' ? tetherOffset(Object.assign({}, state.rects, {\n placement: state.placement\n })) : tetherOffset;\n var normalizedTetherOffsetValue = typeof tetherOffsetValue === 'number' ? {\n mainAxis: tetherOffsetValue,\n altAxis: tetherOffsetValue\n } : Object.assign({\n mainAxis: 0,\n altAxis: 0\n }, tetherOffsetValue);\n var offsetModifierState = state.modifiersData.offset ? state.modifiersData.offset[state.placement] : null;\n var data = {\n x: 0,\n y: 0\n };\n\n if (!popperOffsets) {\n return;\n }\n\n if (checkMainAxis) {\n var _offsetModifierState$;\n\n var mainSide = mainAxis === 'y' ? top : left;\n var altSide = mainAxis === 'y' ? bottom : right;\n var len = mainAxis === 'y' ? 'height' : 'width';\n var offset = popperOffsets[mainAxis];\n var min = offset + overflow[mainSide];\n var max = offset - overflow[altSide];\n var additive = tether ? -popperRect[len] / 2 : 0;\n var minLen = variation === start ? referenceRect[len] : popperRect[len];\n var maxLen = variation === start ? -popperRect[len] : -referenceRect[len]; // We need to include the arrow in the calculation so the arrow doesn't go\n // outside the reference bounds\n\n var arrowElement = state.elements.arrow;\n var arrowRect = tether && arrowElement ? getLayoutRect(arrowElement) : {\n width: 0,\n height: 0\n };\n var arrowPaddingObject = state.modifiersData['arrow#persistent'] ? state.modifiersData['arrow#persistent'].padding : getFreshSideObject();\n var arrowPaddingMin = arrowPaddingObject[mainSide];\n var arrowPaddingMax = arrowPaddingObject[altSide]; // If the reference length is smaller than the arrow length, we don't want\n // to include its full size in the calculation. If the reference is small\n // and near the edge of a boundary, the popper can overflow even if the\n // reference is not overflowing as well (e.g. virtual elements with no\n // width or height)\n\n var arrowLen = within(0, referenceRect[len], arrowRect[len]);\n var minOffset = isBasePlacement ? referenceRect[len] / 2 - additive - arrowLen - arrowPaddingMin - normalizedTetherOffsetValue.mainAxis : minLen - arrowLen - arrowPaddingMin - normalizedTetherOffsetValue.mainAxis;\n var maxOffset = isBasePlacement ? -referenceRect[len] / 2 + additive + arrowLen + arrowPaddingMax + normalizedTetherOffsetValue.mainAxis : maxLen + arrowLen + arrowPaddingMax + normalizedTetherOffsetValue.mainAxis;\n var arrowOffsetParent = state.elements.arrow && getOffsetParent(state.elements.arrow);\n var clientOffset = arrowOffsetParent ? mainAxis === 'y' ? arrowOffsetParent.clientTop || 0 : arrowOffsetParent.clientLeft || 0 : 0;\n var offsetModifierValue = (_offsetModifierState$ = offsetModifierState == null ? void 0 : offsetModifierState[mainAxis]) != null ? _offsetModifierState$ : 0;\n var tetherMin = offset + minOffset - offsetModifierValue - clientOffset;\n var tetherMax = offset + maxOffset - offsetModifierValue;\n var preventedOffset = within(tether ? mathMin(min, tetherMin) : min, offset, tether ? mathMax(max, tetherMax) : max);\n popperOffsets[mainAxis] = preventedOffset;\n data[mainAxis] = preventedOffset - offset;\n }\n\n if (checkAltAxis) {\n var _offsetModifierState$2;\n\n var _mainSide = mainAxis === 'x' ? top : left;\n\n var _altSide = mainAxis === 'x' ? bottom : right;\n\n var _offset = popperOffsets[altAxis];\n\n var _len = altAxis === 'y' ? 'height' : 'width';\n\n var _min = _offset + overflow[_mainSide];\n\n var _max = _offset - overflow[_altSide];\n\n var isOriginSide = [top, left].indexOf(basePlacement) !== -1;\n\n var _offsetModifierValue = (_offsetModifierState$2 = offsetModifierState == null ? void 0 : offsetModifierState[altAxis]) != null ? _offsetModifierState$2 : 0;\n\n var _tetherMin = isOriginSide ? _min : _offset - referenceRect[_len] - popperRect[_len] - _offsetModifierValue + normalizedTetherOffsetValue.altAxis;\n\n var _tetherMax = isOriginSide ? _offset + referenceRect[_len] + popperRect[_len] - _offsetModifierValue - normalizedTetherOffsetValue.altAxis : _max;\n\n var _preventedOffset = tether && isOriginSide ? withinMaxClamp(_tetherMin, _offset, _tetherMax) : within(tether ? _tetherMin : _min, _offset, tether ? _tetherMax : _max);\n\n popperOffsets[altAxis] = _preventedOffset;\n data[altAxis] = _preventedOffset - _offset;\n }\n\n state.modifiersData[name] = data;\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'preventOverflow',\n enabled: true,\n phase: 'main',\n fn: preventOverflow,\n requiresIfExists: ['offset']\n};","export default function getHTMLElementScroll(element) {\n return {\n scrollLeft: element.scrollLeft,\n scrollTop: element.scrollTop\n };\n}","import getWindowScroll from \"./getWindowScroll.js\";\nimport getWindow from \"./getWindow.js\";\nimport { isHTMLElement } from \"./instanceOf.js\";\nimport getHTMLElementScroll from \"./getHTMLElementScroll.js\";\nexport default function getNodeScroll(node) {\n if (node === getWindow(node) || !isHTMLElement(node)) {\n return getWindowScroll(node);\n } else {\n return getHTMLElementScroll(node);\n }\n}","import getBoundingClientRect from \"./getBoundingClientRect.js\";\nimport getNodeScroll from \"./getNodeScroll.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport { isHTMLElement } from \"./instanceOf.js\";\nimport getWindowScrollBarX from \"./getWindowScrollBarX.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport isScrollParent from \"./isScrollParent.js\";\nimport { round } from \"../utils/math.js\";\n\nfunction isElementScaled(element) {\n var rect = element.getBoundingClientRect();\n var scaleX = round(rect.width) / element.offsetWidth || 1;\n var scaleY = round(rect.height) / element.offsetHeight || 1;\n return scaleX !== 1 || scaleY !== 1;\n} // Returns the composite rect of an element relative to its offsetParent.\n// Composite means it takes into account transforms as well as layout.\n\n\nexport default function getCompositeRect(elementOrVirtualElement, offsetParent, isFixed) {\n if (isFixed === void 0) {\n isFixed = false;\n }\n\n var isOffsetParentAnElement = isHTMLElement(offsetParent);\n var offsetParentIsScaled = isHTMLElement(offsetParent) && isElementScaled(offsetParent);\n var documentElement = getDocumentElement(offsetParent);\n var rect = getBoundingClientRect(elementOrVirtualElement, offsetParentIsScaled, isFixed);\n var scroll = {\n scrollLeft: 0,\n scrollTop: 0\n };\n var offsets = {\n x: 0,\n y: 0\n };\n\n if (isOffsetParentAnElement || !isOffsetParentAnElement && !isFixed) {\n if (getNodeName(offsetParent) !== 'body' || // https://github.com/popperjs/popper-core/issues/1078\n isScrollParent(documentElement)) {\n scroll = getNodeScroll(offsetParent);\n }\n\n if (isHTMLElement(offsetParent)) {\n offsets = getBoundingClientRect(offsetParent, true);\n offsets.x += offsetParent.clientLeft;\n offsets.y += offsetParent.clientTop;\n } else if (documentElement) {\n offsets.x = getWindowScrollBarX(documentElement);\n }\n }\n\n return {\n x: rect.left + scroll.scrollLeft - offsets.x,\n y: rect.top + scroll.scrollTop - offsets.y,\n width: rect.width,\n height: rect.height\n };\n}","import { modifierPhases } from \"../enums.js\"; // source: https://stackoverflow.com/questions/49875255\n\nfunction order(modifiers) {\n var map = new Map();\n var visited = new Set();\n var result = [];\n modifiers.forEach(function (modifier) {\n map.set(modifier.name, modifier);\n }); // On visiting object, check for its dependencies and visit them recursively\n\n function sort(modifier) {\n visited.add(modifier.name);\n var requires = [].concat(modifier.requires || [], modifier.requiresIfExists || []);\n requires.forEach(function (dep) {\n if (!visited.has(dep)) {\n var depModifier = map.get(dep);\n\n if (depModifier) {\n sort(depModifier);\n }\n }\n });\n result.push(modifier);\n }\n\n modifiers.forEach(function (modifier) {\n if (!visited.has(modifier.name)) {\n // check for visited object\n sort(modifier);\n }\n });\n return result;\n}\n\nexport default function orderModifiers(modifiers) {\n // order based on dependencies\n var orderedModifiers = order(modifiers); // order based on phase\n\n return modifierPhases.reduce(function (acc, phase) {\n return acc.concat(orderedModifiers.filter(function (modifier) {\n return modifier.phase === phase;\n }));\n }, []);\n}","export default function debounce(fn) {\n var pending;\n return function () {\n if (!pending) {\n pending = new Promise(function (resolve) {\n Promise.resolve().then(function () {\n pending = undefined;\n resolve(fn());\n });\n });\n }\n\n return pending;\n };\n}","export default function mergeByName(modifiers) {\n var merged = modifiers.reduce(function (merged, current) {\n var existing = merged[current.name];\n merged[current.name] = existing ? Object.assign({}, existing, current, {\n options: Object.assign({}, existing.options, current.options),\n data: Object.assign({}, existing.data, current.data)\n }) : current;\n return merged;\n }, {}); // IE11 does not support Object.values\n\n return Object.keys(merged).map(function (key) {\n return merged[key];\n });\n}","import getCompositeRect from \"./dom-utils/getCompositeRect.js\";\nimport getLayoutRect from \"./dom-utils/getLayoutRect.js\";\nimport listScrollParents from \"./dom-utils/listScrollParents.js\";\nimport getOffsetParent from \"./dom-utils/getOffsetParent.js\";\nimport orderModifiers from \"./utils/orderModifiers.js\";\nimport debounce from \"./utils/debounce.js\";\nimport mergeByName from \"./utils/mergeByName.js\";\nimport detectOverflow from \"./utils/detectOverflow.js\";\nimport { isElement } from \"./dom-utils/instanceOf.js\";\nvar DEFAULT_OPTIONS = {\n placement: 'bottom',\n modifiers: [],\n strategy: 'absolute'\n};\n\nfunction areValidElements() {\n for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {\n args[_key] = arguments[_key];\n }\n\n return !args.some(function (element) {\n return !(element && typeof element.getBoundingClientRect === 'function');\n });\n}\n\nexport function popperGenerator(generatorOptions) {\n if (generatorOptions === void 0) {\n generatorOptions = {};\n }\n\n var _generatorOptions = generatorOptions,\n _generatorOptions$def = _generatorOptions.defaultModifiers,\n defaultModifiers = _generatorOptions$def === void 0 ? [] : _generatorOptions$def,\n _generatorOptions$def2 = _generatorOptions.defaultOptions,\n defaultOptions = _generatorOptions$def2 === void 0 ? DEFAULT_OPTIONS : _generatorOptions$def2;\n return function createPopper(reference, popper, options) {\n if (options === void 0) {\n options = defaultOptions;\n }\n\n var state = {\n placement: 'bottom',\n orderedModifiers: [],\n options: Object.assign({}, DEFAULT_OPTIONS, defaultOptions),\n modifiersData: {},\n elements: {\n reference: reference,\n popper: popper\n },\n attributes: {},\n styles: {}\n };\n var effectCleanupFns = [];\n var isDestroyed = false;\n var instance = {\n state: state,\n setOptions: function setOptions(setOptionsAction) {\n var options = typeof setOptionsAction === 'function' ? setOptionsAction(state.options) : setOptionsAction;\n cleanupModifierEffects();\n state.options = Object.assign({}, defaultOptions, state.options, options);\n state.scrollParents = {\n reference: isElement(reference) ? listScrollParents(reference) : reference.contextElement ? listScrollParents(reference.contextElement) : [],\n popper: listScrollParents(popper)\n }; // Orders the modifiers based on their dependencies and `phase`\n // properties\n\n var orderedModifiers = orderModifiers(mergeByName([].concat(defaultModifiers, state.options.modifiers))); // Strip out disabled modifiers\n\n state.orderedModifiers = orderedModifiers.filter(function (m) {\n return m.enabled;\n });\n runModifierEffects();\n return instance.update();\n },\n // Sync update – it will always be executed, even if not necessary. This\n // is useful for low frequency updates where sync behavior simplifies the\n // logic.\n // For high frequency updates (e.g. `resize` and `scroll` events), always\n // prefer the async Popper#update method\n forceUpdate: function forceUpdate() {\n if (isDestroyed) {\n return;\n }\n\n var _state$elements = state.elements,\n reference = _state$elements.reference,\n popper = _state$elements.popper; // Don't proceed if `reference` or `popper` are not valid elements\n // anymore\n\n if (!areValidElements(reference, popper)) {\n return;\n } // Store the reference and popper rects to be read by modifiers\n\n\n state.rects = {\n reference: getCompositeRect(reference, getOffsetParent(popper), state.options.strategy === 'fixed'),\n popper: getLayoutRect(popper)\n }; // Modifiers have the ability to reset the current update cycle. The\n // most common use case for this is the `flip` modifier changing the\n // placement, which then needs to re-run all the modifiers, because the\n // logic was previously ran for the previous placement and is therefore\n // stale/incorrect\n\n state.reset = false;\n state.placement = state.options.placement; // On each update cycle, the `modifiersData` property for each modifier\n // is filled with the initial data specified by the modifier. This means\n // it doesn't persist and is fresh on each update.\n // To ensure persistent data, use `${name}#persistent`\n\n state.orderedModifiers.forEach(function (modifier) {\n return state.modifiersData[modifier.name] = Object.assign({}, modifier.data);\n });\n\n for (var index = 0; index < state.orderedModifiers.length; index++) {\n if (state.reset === true) {\n state.reset = false;\n index = -1;\n continue;\n }\n\n var _state$orderedModifie = state.orderedModifiers[index],\n fn = _state$orderedModifie.fn,\n _state$orderedModifie2 = _state$orderedModifie.options,\n _options = _state$orderedModifie2 === void 0 ? {} : _state$orderedModifie2,\n name = _state$orderedModifie.name;\n\n if (typeof fn === 'function') {\n state = fn({\n state: state,\n options: _options,\n name: name,\n instance: instance\n }) || state;\n }\n }\n },\n // Async and optimistically optimized update – it will not be executed if\n // not necessary (debounced to run at most once-per-tick)\n update: debounce(function () {\n return new Promise(function (resolve) {\n instance.forceUpdate();\n resolve(state);\n });\n }),\n destroy: function destroy() {\n cleanupModifierEffects();\n isDestroyed = true;\n }\n };\n\n if (!areValidElements(reference, popper)) {\n return instance;\n }\n\n instance.setOptions(options).then(function (state) {\n if (!isDestroyed && options.onFirstUpdate) {\n options.onFirstUpdate(state);\n }\n }); // Modifiers have the ability to execute arbitrary code before the first\n // update cycle runs. They will be executed in the same order as the update\n // cycle. This is useful when a modifier adds some persistent data that\n // other modifiers need to use, but the modifier is run after the dependent\n // one.\n\n function runModifierEffects() {\n state.orderedModifiers.forEach(function (_ref) {\n var name = _ref.name,\n _ref$options = _ref.options,\n options = _ref$options === void 0 ? {} : _ref$options,\n effect = _ref.effect;\n\n if (typeof effect === 'function') {\n var cleanupFn = effect({\n state: state,\n name: name,\n instance: instance,\n options: options\n });\n\n var noopFn = function noopFn() {};\n\n effectCleanupFns.push(cleanupFn || noopFn);\n }\n });\n }\n\n function cleanupModifierEffects() {\n effectCleanupFns.forEach(function (fn) {\n return fn();\n });\n effectCleanupFns = [];\n }\n\n return instance;\n };\n}\nexport var createPopper = /*#__PURE__*/popperGenerator(); // eslint-disable-next-line import/no-unused-modules\n\nexport { detectOverflow };","import { popperGenerator, detectOverflow } from \"./createPopper.js\";\nimport eventListeners from \"./modifiers/eventListeners.js\";\nimport popperOffsets from \"./modifiers/popperOffsets.js\";\nimport computeStyles from \"./modifiers/computeStyles.js\";\nimport applyStyles from \"./modifiers/applyStyles.js\";\nimport offset from \"./modifiers/offset.js\";\nimport flip from \"./modifiers/flip.js\";\nimport preventOverflow from \"./modifiers/preventOverflow.js\";\nimport arrow from \"./modifiers/arrow.js\";\nimport hide from \"./modifiers/hide.js\";\nvar defaultModifiers = [eventListeners, popperOffsets, computeStyles, applyStyles, offset, flip, preventOverflow, arrow, hide];\nvar createPopper = /*#__PURE__*/popperGenerator({\n defaultModifiers: defaultModifiers\n}); // eslint-disable-next-line import/no-unused-modules\n\nexport { createPopper, popperGenerator, defaultModifiers, detectOverflow }; // eslint-disable-next-line import/no-unused-modules\n\nexport { createPopper as createPopperLite } from \"./popper-lite.js\"; // eslint-disable-next-line import/no-unused-modules\n\nexport * from \"./modifiers/index.js\";","import { generateUtilityClass } from '../generateUtilityClass';\nimport { generateUtilityClasses } from '../generateUtilityClasses';\nconst COMPONENT_NAME = 'Popper';\nexport function getPopperUtilityClass(slot) {\n return generateUtilityClass(COMPONENT_NAME, slot);\n}\nexport const popperClasses = generateUtilityClasses(COMPONENT_NAME, ['root']);","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"anchorEl\", \"children\", \"direction\", \"disablePortal\", \"modifiers\", \"open\", \"placement\", \"popperOptions\", \"popperRef\", \"slotProps\", \"slots\", \"TransitionProps\", \"ownerState\"],\n _excluded2 = [\"anchorEl\", \"children\", \"container\", \"direction\", \"disablePortal\", \"keepMounted\", \"modifiers\", \"open\", \"placement\", \"popperOptions\", \"popperRef\", \"style\", \"transition\", \"slotProps\", \"slots\"];\nimport * as React from 'react';\nimport { chainPropTypes, HTMLElementType, refType, unstable_ownerDocument as ownerDocument, unstable_useEnhancedEffect as useEnhancedEffect, unstable_useForkRef as useForkRef } from '@mui/utils';\nimport { createPopper } from '@popperjs/core';\nimport PropTypes from 'prop-types';\nimport { unstable_composeClasses as composeClasses } from '../composeClasses';\nimport { Portal } from '../Portal';\nimport { getPopperUtilityClass } from './popperClasses';\nimport { useSlotProps } from '../utils';\nimport { useClassNamesOverride } from '../utils/ClassNameConfigurator';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nfunction flipPlacement(placement, direction) {\n if (direction === 'ltr') {\n return placement;\n }\n switch (placement) {\n case 'bottom-end':\n return 'bottom-start';\n case 'bottom-start':\n return 'bottom-end';\n case 'top-end':\n return 'top-start';\n case 'top-start':\n return 'top-end';\n default:\n return placement;\n }\n}\nfunction resolveAnchorEl(anchorEl) {\n return typeof anchorEl === 'function' ? anchorEl() : anchorEl;\n}\nfunction isHTMLElement(element) {\n return element.nodeType !== undefined;\n}\nfunction isVirtualElement(element) {\n return !isHTMLElement(element);\n}\nconst useUtilityClasses = () => {\n const slots = {\n root: ['root']\n };\n return composeClasses(slots, useClassNamesOverride(getPopperUtilityClass));\n};\nconst defaultPopperOptions = {};\nconst PopperTooltip = /*#__PURE__*/React.forwardRef(function PopperTooltip(props, forwardedRef) {\n var _slots$root;\n const {\n anchorEl,\n children,\n direction,\n disablePortal,\n modifiers,\n open,\n placement: initialPlacement,\n popperOptions,\n popperRef: popperRefProp,\n slotProps = {},\n slots = {},\n TransitionProps\n // @ts-ignore internal logic\n // prevent from spreading to DOM, it can come from the parent component e.g. Select.\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const tooltipRef = React.useRef(null);\n const ownRef = useForkRef(tooltipRef, forwardedRef);\n const popperRef = React.useRef(null);\n const handlePopperRef = useForkRef(popperRef, popperRefProp);\n const handlePopperRefRef = React.useRef(handlePopperRef);\n useEnhancedEffect(() => {\n handlePopperRefRef.current = handlePopperRef;\n }, [handlePopperRef]);\n React.useImperativeHandle(popperRefProp, () => popperRef.current, []);\n const rtlPlacement = flipPlacement(initialPlacement, direction);\n /**\n * placement initialized from prop but can change during lifetime if modifiers.flip.\n * modifiers.flip is essentially a flip for controlled/uncontrolled behavior\n */\n const [placement, setPlacement] = React.useState(rtlPlacement);\n const [resolvedAnchorElement, setResolvedAnchorElement] = React.useState(resolveAnchorEl(anchorEl));\n React.useEffect(() => {\n if (popperRef.current) {\n popperRef.current.forceUpdate();\n }\n });\n React.useEffect(() => {\n if (anchorEl) {\n setResolvedAnchorElement(resolveAnchorEl(anchorEl));\n }\n }, [anchorEl]);\n useEnhancedEffect(() => {\n if (!resolvedAnchorElement || !open) {\n return undefined;\n }\n const handlePopperUpdate = data => {\n setPlacement(data.placement);\n };\n if (process.env.NODE_ENV !== 'production') {\n if (resolvedAnchorElement && isHTMLElement(resolvedAnchorElement) && resolvedAnchorElement.nodeType === 1) {\n const box = resolvedAnchorElement.getBoundingClientRect();\n if (process.env.NODE_ENV !== 'test' && box.top === 0 && box.left === 0 && box.right === 0 && box.bottom === 0) {\n console.warn(['MUI: The `anchorEl` prop provided to the component is invalid.', 'The anchor element should be part of the document layout.', \"Make sure the element is present in the document or that it's not display none.\"].join('\\n'));\n }\n }\n }\n let popperModifiers = [{\n name: 'preventOverflow',\n options: {\n altBoundary: disablePortal\n }\n }, {\n name: 'flip',\n options: {\n altBoundary: disablePortal\n }\n }, {\n name: 'onUpdate',\n enabled: true,\n phase: 'afterWrite',\n fn: ({\n state\n }) => {\n handlePopperUpdate(state);\n }\n }];\n if (modifiers != null) {\n popperModifiers = popperModifiers.concat(modifiers);\n }\n if (popperOptions && popperOptions.modifiers != null) {\n popperModifiers = popperModifiers.concat(popperOptions.modifiers);\n }\n const popper = createPopper(resolvedAnchorElement, tooltipRef.current, _extends({\n placement: rtlPlacement\n }, popperOptions, {\n modifiers: popperModifiers\n }));\n handlePopperRefRef.current(popper);\n return () => {\n popper.destroy();\n handlePopperRefRef.current(null);\n };\n }, [resolvedAnchorElement, disablePortal, modifiers, open, popperOptions, rtlPlacement]);\n const childProps = {\n placement: placement\n };\n if (TransitionProps !== null) {\n childProps.TransitionProps = TransitionProps;\n }\n const classes = useUtilityClasses();\n const Root = (_slots$root = slots.root) != null ? _slots$root : 'div';\n const rootProps = useSlotProps({\n elementType: Root,\n externalSlotProps: slotProps.root,\n externalForwardedProps: other,\n additionalProps: {\n role: 'tooltip',\n ref: ownRef\n },\n ownerState: props,\n className: classes.root\n });\n return /*#__PURE__*/_jsx(Root, _extends({}, rootProps, {\n children: typeof children === 'function' ? children(childProps) : children\n }));\n});\n\n/**\n * Poppers rely on the 3rd party library [Popper.js](https://popper.js.org/docs/v2/) for positioning.\n *\n * Demos:\n *\n * - [Popper](https://mui.com/base-ui/react-popper/)\n *\n * API:\n *\n * - [Popper API](https://mui.com/base-ui/react-popper/components-api/#popper)\n */\nconst Popper = /*#__PURE__*/React.forwardRef(function Popper(props, forwardedRef) {\n const {\n anchorEl,\n children,\n container: containerProp,\n direction = 'ltr',\n disablePortal = false,\n keepMounted = false,\n modifiers,\n open,\n placement = 'bottom',\n popperOptions = defaultPopperOptions,\n popperRef,\n style,\n transition = false,\n slotProps = {},\n slots = {}\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded2);\n const [exited, setExited] = React.useState(true);\n const handleEnter = () => {\n setExited(false);\n };\n const handleExited = () => {\n setExited(true);\n };\n if (!keepMounted && !open && (!transition || exited)) {\n return null;\n }\n\n // If the container prop is provided, use that\n // If the anchorEl prop is provided, use its parent body element as the container\n // If neither are provided let the Modal take care of choosing the container\n let container;\n if (containerProp) {\n container = containerProp;\n } else if (anchorEl) {\n const resolvedAnchorEl = resolveAnchorEl(anchorEl);\n container = resolvedAnchorEl && isHTMLElement(resolvedAnchorEl) ? ownerDocument(resolvedAnchorEl).body : ownerDocument(null).body;\n }\n const display = !open && keepMounted && (!transition || exited) ? 'none' : undefined;\n const transitionProps = transition ? {\n in: open,\n onEnter: handleEnter,\n onExited: handleExited\n } : undefined;\n return /*#__PURE__*/_jsx(Portal, {\n disablePortal: disablePortal,\n container: container,\n children: /*#__PURE__*/_jsx(PopperTooltip, _extends({\n anchorEl: anchorEl,\n direction: direction,\n disablePortal: disablePortal,\n modifiers: modifiers,\n ref: forwardedRef,\n open: transition ? !exited : open,\n placement: placement,\n popperOptions: popperOptions,\n popperRef: popperRef,\n slotProps: slotProps,\n slots: slots\n }, other, {\n style: _extends({\n // Prevents scroll issue, waiting for Popper.js to add this style once initiated.\n position: 'fixed',\n // Fix Popper.js display issue\n top: 0,\n left: 0,\n display\n }, style),\n TransitionProps: transitionProps,\n children: children\n }))\n });\n});\nprocess.env.NODE_ENV !== \"production\" ? Popper.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * An HTML element, [virtualElement](https://popper.js.org/docs/v2/virtual-elements/),\n * or a function that returns either.\n * It's used to set the position of the popper.\n * The return value will passed as the reference object of the Popper instance.\n */\n anchorEl: chainPropTypes(PropTypes.oneOfType([HTMLElementType, PropTypes.object, PropTypes.func]), props => {\n if (props.open) {\n const resolvedAnchorEl = resolveAnchorEl(props.anchorEl);\n if (resolvedAnchorEl && isHTMLElement(resolvedAnchorEl) && resolvedAnchorEl.nodeType === 1) {\n const box = resolvedAnchorEl.getBoundingClientRect();\n if (process.env.NODE_ENV !== 'test' && box.top === 0 && box.left === 0 && box.right === 0 && box.bottom === 0) {\n return new Error(['MUI: The `anchorEl` prop provided to the component is invalid.', 'The anchor element should be part of the document layout.', \"Make sure the element is present in the document or that it's not display none.\"].join('\\n'));\n }\n } else if (!resolvedAnchorEl || typeof resolvedAnchorEl.getBoundingClientRect !== 'function' || isVirtualElement(resolvedAnchorEl) && resolvedAnchorEl.contextElement != null && resolvedAnchorEl.contextElement.nodeType !== 1) {\n return new Error(['MUI: The `anchorEl` prop provided to the component is invalid.', 'It should be an HTML element instance or a virtualElement ', '(https://popper.js.org/docs/v2/virtual-elements/).'].join('\\n'));\n }\n }\n return null;\n }),\n /**\n * Popper render function or node.\n */\n children: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.node, PropTypes.func]),\n /**\n * An HTML element or function that returns one.\n * The `container` will have the portal children appended to it.\n *\n * You can also provide a callback, which is called in a React layout effect.\n * This lets you set the container from a ref, and also makes server-side rendering possible.\n *\n * By default, it uses the body of the top-level document object,\n * so it's simply `document.body` most of the time.\n */\n container: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.func]),\n /**\n * Direction of the text.\n * @default 'ltr'\n */\n direction: PropTypes.oneOf(['ltr', 'rtl']),\n /**\n * The `children` will be under the DOM hierarchy of the parent component.\n * @default false\n */\n disablePortal: PropTypes.bool,\n /**\n * Always keep the children in the DOM.\n * This prop can be useful in SEO situation or\n * when you want to maximize the responsiveness of the Popper.\n * @default false\n */\n keepMounted: PropTypes.bool,\n /**\n * Popper.js is based on a \"plugin-like\" architecture,\n * most of its features are fully encapsulated \"modifiers\".\n *\n * A modifier is a function that is called each time Popper.js needs to\n * compute the position of the popper.\n * For this reason, modifiers should be very performant to avoid bottlenecks.\n * To learn how to create a modifier, [read the modifiers documentation](https://popper.js.org/docs/v2/modifiers/).\n */\n modifiers: PropTypes.arrayOf(PropTypes.shape({\n data: PropTypes.object,\n effect: PropTypes.func,\n enabled: PropTypes.bool,\n fn: PropTypes.func,\n name: PropTypes.any,\n options: PropTypes.object,\n phase: PropTypes.oneOf(['afterMain', 'afterRead', 'afterWrite', 'beforeMain', 'beforeRead', 'beforeWrite', 'main', 'read', 'write']),\n requires: PropTypes.arrayOf(PropTypes.string),\n requiresIfExists: PropTypes.arrayOf(PropTypes.string)\n })),\n /**\n * If `true`, the component is shown.\n */\n open: PropTypes.bool.isRequired,\n /**\n * Popper placement.\n * @default 'bottom'\n */\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n /**\n * Options provided to the [`Popper.js`](https://popper.js.org/docs/v2/constructors/#options) instance.\n * @default {}\n */\n popperOptions: PropTypes.shape({\n modifiers: PropTypes.array,\n onFirstUpdate: PropTypes.func,\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n strategy: PropTypes.oneOf(['absolute', 'fixed'])\n }),\n /**\n * A ref that points to the used popper instance.\n */\n popperRef: refType,\n /**\n * The props used for each slot inside the Popper.\n * @default {}\n */\n slotProps: PropTypes.shape({\n root: PropTypes.oneOfType([PropTypes.func, PropTypes.object])\n }),\n /**\n * The components used for each slot inside the Popper.\n * Either a string to use a HTML element or a component.\n * @default {}\n */\n slots: PropTypes.shape({\n root: PropTypes.elementType\n }),\n /**\n * Help supporting a react-transition-group/Transition component.\n * @default false\n */\n transition: PropTypes.bool\n} : void 0;\nexport { Popper };","'use client';\n\nimport * as React from 'react';\nimport { useTheme as useThemeSystem } from '@mui/system';\nimport defaultTheme from './defaultTheme';\nimport THEME_ID from './identifier';\nexport default function useTheme() {\n const theme = useThemeSystem(defaultTheme);\n if (process.env.NODE_ENV !== 'production') {\n // eslint-disable-next-line react-hooks/rules-of-hooks\n React.useDebugValue(theme);\n }\n return theme[THEME_ID] || theme;\n}","export default function _setPrototypeOf(o, p) {\n _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function _setPrototypeOf(o, p) {\n o.__proto__ = p;\n return o;\n };\n return _setPrototypeOf(o, p);\n}","import setPrototypeOf from \"./setPrototypeOf.js\";\nexport default function _inheritsLoose(subClass, superClass) {\n subClass.prototype = Object.create(superClass.prototype);\n subClass.prototype.constructor = subClass;\n setPrototypeOf(subClass, superClass);\n}","export default {\n disabled: false\n};","import PropTypes from 'prop-types';\nexport var timeoutsShape = process.env.NODE_ENV !== 'production' ? PropTypes.oneOfType([PropTypes.number, PropTypes.shape({\n enter: PropTypes.number,\n exit: PropTypes.number,\n appear: PropTypes.number\n}).isRequired]) : null;\nexport var classNamesShape = process.env.NODE_ENV !== 'production' ? PropTypes.oneOfType([PropTypes.string, PropTypes.shape({\n enter: PropTypes.string,\n exit: PropTypes.string,\n active: PropTypes.string\n}), PropTypes.shape({\n enter: PropTypes.string,\n enterDone: PropTypes.string,\n enterActive: PropTypes.string,\n exit: PropTypes.string,\n exitDone: PropTypes.string,\n exitActive: PropTypes.string\n})]) : null;","import React from 'react';\nexport default React.createContext(null);","export var forceReflow = function forceReflow(node) {\n return node.scrollTop;\n};","import _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _inheritsLoose from \"@babel/runtime/helpers/esm/inheritsLoose\";\nimport PropTypes from 'prop-types';\nimport React from 'react';\nimport ReactDOM from 'react-dom';\nimport config from './config';\nimport { timeoutsShape } from './utils/PropTypes';\nimport TransitionGroupContext from './TransitionGroupContext';\nimport { forceReflow } from './utils/reflow';\nexport var UNMOUNTED = 'unmounted';\nexport var EXITED = 'exited';\nexport var ENTERING = 'entering';\nexport var ENTERED = 'entered';\nexport var EXITING = 'exiting';\n/**\n * The Transition component lets you describe a transition from one component\n * state to another _over time_ with a simple declarative API. Most commonly\n * it's used to animate the mounting and unmounting of a component, but can also\n * be used to describe in-place transition states as well.\n *\n * ---\n *\n * **Note**: `Transition` is a platform-agnostic base component. If you're using\n * transitions in CSS, you'll probably want to use\n * [`CSSTransition`](https://reactcommunity.org/react-transition-group/css-transition)\n * instead. It inherits all the features of `Transition`, but contains\n * additional features necessary to play nice with CSS transitions (hence the\n * name of the component).\n *\n * ---\n *\n * By default the `Transition` component does not alter the behavior of the\n * component it renders, it only tracks \"enter\" and \"exit\" states for the\n * components. It's up to you to give meaning and effect to those states. For\n * example we can add styles to a component when it enters or exits:\n *\n * ```jsx\n * import { Transition } from 'react-transition-group';\n *\n * const duration = 300;\n *\n * const defaultStyle = {\n * transition: `opacity ${duration}ms ease-in-out`,\n * opacity: 0,\n * }\n *\n * const transitionStyles = {\n * entering: { opacity: 1 },\n * entered: { opacity: 1 },\n * exiting: { opacity: 0 },\n * exited: { opacity: 0 },\n * };\n *\n * const Fade = ({ in: inProp }) => (\n * \n * {state => (\n *
    \n * I'm a fade Transition!\n *
    \n * )}\n *
    \n * );\n * ```\n *\n * There are 4 main states a Transition can be in:\n * - `'entering'`\n * - `'entered'`\n * - `'exiting'`\n * - `'exited'`\n *\n * Transition state is toggled via the `in` prop. When `true` the component\n * begins the \"Enter\" stage. During this stage, the component will shift from\n * its current transition state, to `'entering'` for the duration of the\n * transition and then to the `'entered'` stage once it's complete. Let's take\n * the following example (we'll use the\n * [useState](https://reactjs.org/docs/hooks-reference.html#usestate) hook):\n *\n * ```jsx\n * function App() {\n * const [inProp, setInProp] = useState(false);\n * return (\n *
    \n * \n * {state => (\n * // ...\n * )}\n * \n * \n *
    \n * );\n * }\n * ```\n *\n * When the button is clicked the component will shift to the `'entering'` state\n * and stay there for 500ms (the value of `timeout`) before it finally switches\n * to `'entered'`.\n *\n * When `in` is `false` the same thing happens except the state moves from\n * `'exiting'` to `'exited'`.\n */\n\nvar Transition = /*#__PURE__*/function (_React$Component) {\n _inheritsLoose(Transition, _React$Component);\n\n function Transition(props, context) {\n var _this;\n\n _this = _React$Component.call(this, props, context) || this;\n var parentGroup = context; // In the context of a TransitionGroup all enters are really appears\n\n var appear = parentGroup && !parentGroup.isMounting ? props.enter : props.appear;\n var initialStatus;\n _this.appearStatus = null;\n\n if (props.in) {\n if (appear) {\n initialStatus = EXITED;\n _this.appearStatus = ENTERING;\n } else {\n initialStatus = ENTERED;\n }\n } else {\n if (props.unmountOnExit || props.mountOnEnter) {\n initialStatus = UNMOUNTED;\n } else {\n initialStatus = EXITED;\n }\n }\n\n _this.state = {\n status: initialStatus\n };\n _this.nextCallback = null;\n return _this;\n }\n\n Transition.getDerivedStateFromProps = function getDerivedStateFromProps(_ref, prevState) {\n var nextIn = _ref.in;\n\n if (nextIn && prevState.status === UNMOUNTED) {\n return {\n status: EXITED\n };\n }\n\n return null;\n } // getSnapshotBeforeUpdate(prevProps) {\n // let nextStatus = null\n // if (prevProps !== this.props) {\n // const { status } = this.state\n // if (this.props.in) {\n // if (status !== ENTERING && status !== ENTERED) {\n // nextStatus = ENTERING\n // }\n // } else {\n // if (status === ENTERING || status === ENTERED) {\n // nextStatus = EXITING\n // }\n // }\n // }\n // return { nextStatus }\n // }\n ;\n\n var _proto = Transition.prototype;\n\n _proto.componentDidMount = function componentDidMount() {\n this.updateStatus(true, this.appearStatus);\n };\n\n _proto.componentDidUpdate = function componentDidUpdate(prevProps) {\n var nextStatus = null;\n\n if (prevProps !== this.props) {\n var status = this.state.status;\n\n if (this.props.in) {\n if (status !== ENTERING && status !== ENTERED) {\n nextStatus = ENTERING;\n }\n } else {\n if (status === ENTERING || status === ENTERED) {\n nextStatus = EXITING;\n }\n }\n }\n\n this.updateStatus(false, nextStatus);\n };\n\n _proto.componentWillUnmount = function componentWillUnmount() {\n this.cancelNextCallback();\n };\n\n _proto.getTimeouts = function getTimeouts() {\n var timeout = this.props.timeout;\n var exit, enter, appear;\n exit = enter = appear = timeout;\n\n if (timeout != null && typeof timeout !== 'number') {\n exit = timeout.exit;\n enter = timeout.enter; // TODO: remove fallback for next major\n\n appear = timeout.appear !== undefined ? timeout.appear : enter;\n }\n\n return {\n exit: exit,\n enter: enter,\n appear: appear\n };\n };\n\n _proto.updateStatus = function updateStatus(mounting, nextStatus) {\n if (mounting === void 0) {\n mounting = false;\n }\n\n if (nextStatus !== null) {\n // nextStatus will always be ENTERING or EXITING.\n this.cancelNextCallback();\n\n if (nextStatus === ENTERING) {\n if (this.props.unmountOnExit || this.props.mountOnEnter) {\n var node = this.props.nodeRef ? this.props.nodeRef.current : ReactDOM.findDOMNode(this); // https://github.com/reactjs/react-transition-group/pull/749\n // With unmountOnExit or mountOnEnter, the enter animation should happen at the transition between `exited` and `entering`.\n // To make the animation happen, we have to separate each rendering and avoid being processed as batched.\n\n if (node) forceReflow(node);\n }\n\n this.performEnter(mounting);\n } else {\n this.performExit();\n }\n } else if (this.props.unmountOnExit && this.state.status === EXITED) {\n this.setState({\n status: UNMOUNTED\n });\n }\n };\n\n _proto.performEnter = function performEnter(mounting) {\n var _this2 = this;\n\n var enter = this.props.enter;\n var appearing = this.context ? this.context.isMounting : mounting;\n\n var _ref2 = this.props.nodeRef ? [appearing] : [ReactDOM.findDOMNode(this), appearing],\n maybeNode = _ref2[0],\n maybeAppearing = _ref2[1];\n\n var timeouts = this.getTimeouts();\n var enterTimeout = appearing ? timeouts.appear : timeouts.enter; // no enter animation skip right to ENTERED\n // if we are mounting and running this it means appear _must_ be set\n\n if (!mounting && !enter || config.disabled) {\n this.safeSetState({\n status: ENTERED\n }, function () {\n _this2.props.onEntered(maybeNode);\n });\n return;\n }\n\n this.props.onEnter(maybeNode, maybeAppearing);\n this.safeSetState({\n status: ENTERING\n }, function () {\n _this2.props.onEntering(maybeNode, maybeAppearing);\n\n _this2.onTransitionEnd(enterTimeout, function () {\n _this2.safeSetState({\n status: ENTERED\n }, function () {\n _this2.props.onEntered(maybeNode, maybeAppearing);\n });\n });\n });\n };\n\n _proto.performExit = function performExit() {\n var _this3 = this;\n\n var exit = this.props.exit;\n var timeouts = this.getTimeouts();\n var maybeNode = this.props.nodeRef ? undefined : ReactDOM.findDOMNode(this); // no exit animation skip right to EXITED\n\n if (!exit || config.disabled) {\n this.safeSetState({\n status: EXITED\n }, function () {\n _this3.props.onExited(maybeNode);\n });\n return;\n }\n\n this.props.onExit(maybeNode);\n this.safeSetState({\n status: EXITING\n }, function () {\n _this3.props.onExiting(maybeNode);\n\n _this3.onTransitionEnd(timeouts.exit, function () {\n _this3.safeSetState({\n status: EXITED\n }, function () {\n _this3.props.onExited(maybeNode);\n });\n });\n });\n };\n\n _proto.cancelNextCallback = function cancelNextCallback() {\n if (this.nextCallback !== null) {\n this.nextCallback.cancel();\n this.nextCallback = null;\n }\n };\n\n _proto.safeSetState = function safeSetState(nextState, callback) {\n // This shouldn't be necessary, but there are weird race conditions with\n // setState callbacks and unmounting in testing, so always make sure that\n // we can cancel any pending setState callbacks after we unmount.\n callback = this.setNextCallback(callback);\n this.setState(nextState, callback);\n };\n\n _proto.setNextCallback = function setNextCallback(callback) {\n var _this4 = this;\n\n var active = true;\n\n this.nextCallback = function (event) {\n if (active) {\n active = false;\n _this4.nextCallback = null;\n callback(event);\n }\n };\n\n this.nextCallback.cancel = function () {\n active = false;\n };\n\n return this.nextCallback;\n };\n\n _proto.onTransitionEnd = function onTransitionEnd(timeout, handler) {\n this.setNextCallback(handler);\n var node = this.props.nodeRef ? this.props.nodeRef.current : ReactDOM.findDOMNode(this);\n var doesNotHaveTimeoutOrListener = timeout == null && !this.props.addEndListener;\n\n if (!node || doesNotHaveTimeoutOrListener) {\n setTimeout(this.nextCallback, 0);\n return;\n }\n\n if (this.props.addEndListener) {\n var _ref3 = this.props.nodeRef ? [this.nextCallback] : [node, this.nextCallback],\n maybeNode = _ref3[0],\n maybeNextCallback = _ref3[1];\n\n this.props.addEndListener(maybeNode, maybeNextCallback);\n }\n\n if (timeout != null) {\n setTimeout(this.nextCallback, timeout);\n }\n };\n\n _proto.render = function render() {\n var status = this.state.status;\n\n if (status === UNMOUNTED) {\n return null;\n }\n\n var _this$props = this.props,\n children = _this$props.children,\n _in = _this$props.in,\n _mountOnEnter = _this$props.mountOnEnter,\n _unmountOnExit = _this$props.unmountOnExit,\n _appear = _this$props.appear,\n _enter = _this$props.enter,\n _exit = _this$props.exit,\n _timeout = _this$props.timeout,\n _addEndListener = _this$props.addEndListener,\n _onEnter = _this$props.onEnter,\n _onEntering = _this$props.onEntering,\n _onEntered = _this$props.onEntered,\n _onExit = _this$props.onExit,\n _onExiting = _this$props.onExiting,\n _onExited = _this$props.onExited,\n _nodeRef = _this$props.nodeRef,\n childProps = _objectWithoutPropertiesLoose(_this$props, [\"children\", \"in\", \"mountOnEnter\", \"unmountOnExit\", \"appear\", \"enter\", \"exit\", \"timeout\", \"addEndListener\", \"onEnter\", \"onEntering\", \"onEntered\", \"onExit\", \"onExiting\", \"onExited\", \"nodeRef\"]);\n\n return (\n /*#__PURE__*/\n // allows for nested Transitions\n React.createElement(TransitionGroupContext.Provider, {\n value: null\n }, typeof children === 'function' ? children(status, childProps) : React.cloneElement(React.Children.only(children), childProps))\n );\n };\n\n return Transition;\n}(React.Component);\n\nTransition.contextType = TransitionGroupContext;\nTransition.propTypes = process.env.NODE_ENV !== \"production\" ? {\n /**\n * A React reference to DOM element that need to transition:\n * https://stackoverflow.com/a/51127130/4671932\n *\n * - When `nodeRef` prop is used, `node` is not passed to callback functions\n * (e.g. `onEnter`) because user already has direct access to the node.\n * - When changing `key` prop of `Transition` in a `TransitionGroup` a new\n * `nodeRef` need to be provided to `Transition` with changed `key` prop\n * (see\n * [test/CSSTransition-test.js](https://github.com/reactjs/react-transition-group/blob/13435f897b3ab71f6e19d724f145596f5910581c/test/CSSTransition-test.js#L362-L437)).\n */\n nodeRef: PropTypes.shape({\n current: typeof Element === 'undefined' ? PropTypes.any : function (propValue, key, componentName, location, propFullName, secret) {\n var value = propValue[key];\n return PropTypes.instanceOf(value && 'ownerDocument' in value ? value.ownerDocument.defaultView.Element : Element)(propValue, key, componentName, location, propFullName, secret);\n }\n }),\n\n /**\n * A `function` child can be used instead of a React element. This function is\n * called with the current transition status (`'entering'`, `'entered'`,\n * `'exiting'`, `'exited'`), which can be used to apply context\n * specific props to a component.\n *\n * ```jsx\n * \n * {state => (\n * \n * )}\n * \n * ```\n */\n children: PropTypes.oneOfType([PropTypes.func.isRequired, PropTypes.element.isRequired]).isRequired,\n\n /**\n * Show the component; triggers the enter or exit states\n */\n in: PropTypes.bool,\n\n /**\n * By default the child component is mounted immediately along with\n * the parent `Transition` component. If you want to \"lazy mount\" the component on the\n * first `in={true}` you can set `mountOnEnter`. After the first enter transition the component will stay\n * mounted, even on \"exited\", unless you also specify `unmountOnExit`.\n */\n mountOnEnter: PropTypes.bool,\n\n /**\n * By default the child component stays mounted after it reaches the `'exited'` state.\n * Set `unmountOnExit` if you'd prefer to unmount the component after it finishes exiting.\n */\n unmountOnExit: PropTypes.bool,\n\n /**\n * By default the child component does not perform the enter transition when\n * it first mounts, regardless of the value of `in`. If you want this\n * behavior, set both `appear` and `in` to `true`.\n *\n * > **Note**: there are no special appear states like `appearing`/`appeared`, this prop\n * > only adds an additional enter transition. However, in the\n * > `` component that first enter transition does result in\n * > additional `.appear-*` classes, that way you can choose to style it\n * > differently.\n */\n appear: PropTypes.bool,\n\n /**\n * Enable or disable enter transitions.\n */\n enter: PropTypes.bool,\n\n /**\n * Enable or disable exit transitions.\n */\n exit: PropTypes.bool,\n\n /**\n * The duration of the transition, in milliseconds.\n * Required unless `addEndListener` is provided.\n *\n * You may specify a single timeout for all transitions:\n *\n * ```jsx\n * timeout={500}\n * ```\n *\n * or individually:\n *\n * ```jsx\n * timeout={{\n * appear: 500,\n * enter: 300,\n * exit: 500,\n * }}\n * ```\n *\n * - `appear` defaults to the value of `enter`\n * - `enter` defaults to `0`\n * - `exit` defaults to `0`\n *\n * @type {number | { enter?: number, exit?: number, appear?: number }}\n */\n timeout: function timeout(props) {\n var pt = timeoutsShape;\n if (!props.addEndListener) pt = pt.isRequired;\n\n for (var _len = arguments.length, args = new Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) {\n args[_key - 1] = arguments[_key];\n }\n\n return pt.apply(void 0, [props].concat(args));\n },\n\n /**\n * Add a custom transition end trigger. Called with the transitioning\n * DOM node and a `done` callback. Allows for more fine grained transition end\n * logic. Timeouts are still used as a fallback if provided.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * ```jsx\n * addEndListener={(node, done) => {\n * // use the css transitionend event to mark the finish of a transition\n * node.addEventListener('transitionend', done, false);\n * }}\n * ```\n */\n addEndListener: PropTypes.func,\n\n /**\n * Callback fired before the \"entering\" status is applied. An extra parameter\n * `isAppearing` is supplied to indicate if the enter stage is occurring on the initial mount\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement, isAppearing: bool) -> void\n */\n onEnter: PropTypes.func,\n\n /**\n * Callback fired after the \"entering\" status is applied. An extra parameter\n * `isAppearing` is supplied to indicate if the enter stage is occurring on the initial mount\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement, isAppearing: bool)\n */\n onEntering: PropTypes.func,\n\n /**\n * Callback fired after the \"entered\" status is applied. An extra parameter\n * `isAppearing` is supplied to indicate if the enter stage is occurring on the initial mount\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement, isAppearing: bool) -> void\n */\n onEntered: PropTypes.func,\n\n /**\n * Callback fired before the \"exiting\" status is applied.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement) -> void\n */\n onExit: PropTypes.func,\n\n /**\n * Callback fired after the \"exiting\" status is applied.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement) -> void\n */\n onExiting: PropTypes.func,\n\n /**\n * Callback fired after the \"exited\" status is applied.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed\n *\n * @type Function(node: HtmlElement) -> void\n */\n onExited: PropTypes.func\n} : {}; // Name the function so it is clearer in the documentation\n\nfunction noop() {}\n\nTransition.defaultProps = {\n in: false,\n mountOnEnter: false,\n unmountOnExit: false,\n appear: false,\n enter: true,\n exit: true,\n onEnter: noop,\n onEntering: noop,\n onEntered: noop,\n onExit: noop,\n onExiting: noop,\n onExited: noop\n};\nTransition.UNMOUNTED = UNMOUNTED;\nTransition.EXITED = EXITED;\nTransition.ENTERING = ENTERING;\nTransition.ENTERED = ENTERED;\nTransition.EXITING = EXITING;\nexport default Transition;","export const reflow = node => node.scrollTop;\nexport function getTransitionProps(props, options) {\n var _style$transitionDura, _style$transitionTimi;\n const {\n timeout,\n easing,\n style = {}\n } = props;\n return {\n duration: (_style$transitionDura = style.transitionDuration) != null ? _style$transitionDura : typeof timeout === 'number' ? timeout : timeout[options.mode] || 0,\n easing: (_style$transitionTimi = style.transitionTimingFunction) != null ? _style$transitionTimi : typeof easing === 'object' ? easing[options.mode] : easing,\n delay: style.transitionDelay\n };\n}","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"addEndListener\", \"appear\", \"children\", \"easing\", \"in\", \"onEnter\", \"onEntered\", \"onEntering\", \"onExit\", \"onExited\", \"onExiting\", \"style\", \"timeout\", \"TransitionComponent\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport { elementAcceptingRef, unstable_useTimeout as useTimeout } from '@mui/utils';\nimport { Transition } from 'react-transition-group';\nimport useTheme from '../styles/useTheme';\nimport { getTransitionProps, reflow } from '../transitions/utils';\nimport useForkRef from '../utils/useForkRef';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nfunction getScale(value) {\n return `scale(${value}, ${value ** 2})`;\n}\nconst styles = {\n entering: {\n opacity: 1,\n transform: getScale(1)\n },\n entered: {\n opacity: 1,\n transform: 'none'\n }\n};\n\n/*\n TODO v6: remove\n Conditionally apply a workaround for the CSS transition bug in Safari 15.4 / WebKit browsers.\n */\nconst isWebKit154 = typeof navigator !== 'undefined' && /^((?!chrome|android).)*(safari|mobile)/i.test(navigator.userAgent) && /(os |version\\/)15(.|_)4/i.test(navigator.userAgent);\n\n/**\n * The Grow transition is used by the [Tooltip](/material-ui/react-tooltip/) and\n * [Popover](/material-ui/react-popover/) components.\n * It uses [react-transition-group](https://github.com/reactjs/react-transition-group) internally.\n */\nconst Grow = /*#__PURE__*/React.forwardRef(function Grow(props, ref) {\n const {\n addEndListener,\n appear = true,\n children,\n easing,\n in: inProp,\n onEnter,\n onEntered,\n onEntering,\n onExit,\n onExited,\n onExiting,\n style,\n timeout = 'auto',\n // eslint-disable-next-line react/prop-types\n TransitionComponent = Transition\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const timer = useTimeout();\n const autoTimeout = React.useRef();\n const theme = useTheme();\n const nodeRef = React.useRef(null);\n const handleRef = useForkRef(nodeRef, children.ref, ref);\n const normalizedTransitionCallback = callback => maybeIsAppearing => {\n if (callback) {\n const node = nodeRef.current;\n\n // onEnterXxx and onExitXxx callbacks have a different arguments.length value.\n if (maybeIsAppearing === undefined) {\n callback(node);\n } else {\n callback(node, maybeIsAppearing);\n }\n }\n };\n const handleEntering = normalizedTransitionCallback(onEntering);\n const handleEnter = normalizedTransitionCallback((node, isAppearing) => {\n reflow(node); // So the animation always start from the start.\n\n const {\n duration: transitionDuration,\n delay,\n easing: transitionTimingFunction\n } = getTransitionProps({\n style,\n timeout,\n easing\n }, {\n mode: 'enter'\n });\n let duration;\n if (timeout === 'auto') {\n duration = theme.transitions.getAutoHeightDuration(node.clientHeight);\n autoTimeout.current = duration;\n } else {\n duration = transitionDuration;\n }\n node.style.transition = [theme.transitions.create('opacity', {\n duration,\n delay\n }), theme.transitions.create('transform', {\n duration: isWebKit154 ? duration : duration * 0.666,\n delay,\n easing: transitionTimingFunction\n })].join(',');\n if (onEnter) {\n onEnter(node, isAppearing);\n }\n });\n const handleEntered = normalizedTransitionCallback(onEntered);\n const handleExiting = normalizedTransitionCallback(onExiting);\n const handleExit = normalizedTransitionCallback(node => {\n const {\n duration: transitionDuration,\n delay,\n easing: transitionTimingFunction\n } = getTransitionProps({\n style,\n timeout,\n easing\n }, {\n mode: 'exit'\n });\n let duration;\n if (timeout === 'auto') {\n duration = theme.transitions.getAutoHeightDuration(node.clientHeight);\n autoTimeout.current = duration;\n } else {\n duration = transitionDuration;\n }\n node.style.transition = [theme.transitions.create('opacity', {\n duration,\n delay\n }), theme.transitions.create('transform', {\n duration: isWebKit154 ? duration : duration * 0.666,\n delay: isWebKit154 ? delay : delay || duration * 0.333,\n easing: transitionTimingFunction\n })].join(',');\n node.style.opacity = 0;\n node.style.transform = getScale(0.75);\n if (onExit) {\n onExit(node);\n }\n });\n const handleExited = normalizedTransitionCallback(onExited);\n const handleAddEndListener = next => {\n if (timeout === 'auto') {\n timer.start(autoTimeout.current || 0, next);\n }\n if (addEndListener) {\n // Old call signature before `react-transition-group` implemented `nodeRef`\n addEndListener(nodeRef.current, next);\n }\n };\n return /*#__PURE__*/_jsx(TransitionComponent, _extends({\n appear: appear,\n in: inProp,\n nodeRef: nodeRef,\n onEnter: handleEnter,\n onEntered: handleEntered,\n onEntering: handleEntering,\n onExit: handleExit,\n onExited: handleExited,\n onExiting: handleExiting,\n addEndListener: handleAddEndListener,\n timeout: timeout === 'auto' ? null : timeout\n }, other, {\n children: (state, childProps) => {\n return /*#__PURE__*/React.cloneElement(children, _extends({\n style: _extends({\n opacity: 0,\n transform: getScale(0.75),\n visibility: state === 'exited' && !inProp ? 'hidden' : undefined\n }, styles[state], style, children.props.style),\n ref: handleRef\n }, childProps));\n }\n }));\n});\nprocess.env.NODE_ENV !== \"production\" ? Grow.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the d.ts file and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * Add a custom transition end trigger. Called with the transitioning DOM\n * node and a done callback. Allows for more fine grained transition end\n * logic. Note: Timeouts are still used as a fallback if provided.\n */\n addEndListener: PropTypes.func,\n /**\n * Perform the enter transition when it first mounts if `in` is also `true`.\n * Set this to `false` to disable this behavior.\n * @default true\n */\n appear: PropTypes.bool,\n /**\n * A single child content element.\n */\n children: elementAcceptingRef.isRequired,\n /**\n * The transition timing function.\n * You may specify a single easing or a object containing enter and exit values.\n */\n easing: PropTypes.oneOfType([PropTypes.shape({\n enter: PropTypes.string,\n exit: PropTypes.string\n }), PropTypes.string]),\n /**\n * If `true`, the component will transition in.\n */\n in: PropTypes.bool,\n /**\n * @ignore\n */\n onEnter: PropTypes.func,\n /**\n * @ignore\n */\n onEntered: PropTypes.func,\n /**\n * @ignore\n */\n onEntering: PropTypes.func,\n /**\n * @ignore\n */\n onExit: PropTypes.func,\n /**\n * @ignore\n */\n onExited: PropTypes.func,\n /**\n * @ignore\n */\n onExiting: PropTypes.func,\n /**\n * @ignore\n */\n style: PropTypes.object,\n /**\n * The duration for the transition, in milliseconds.\n * You may specify a single timeout for all transitions, or individually with an object.\n *\n * Set to 'auto' to automatically calculate transition time based on height.\n * @default 'auto'\n */\n timeout: PropTypes.oneOfType([PropTypes.oneOf(['auto']), PropTypes.number, PropTypes.shape({\n appear: PropTypes.number,\n enter: PropTypes.number,\n exit: PropTypes.number\n })])\n} : void 0;\nGrow.muiSupportAuto = true;\nexport default Grow;","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"anchorEl\", \"component\", \"components\", \"componentsProps\", \"container\", \"disablePortal\", \"keepMounted\", \"modifiers\", \"open\", \"placement\", \"popperOptions\", \"popperRef\", \"transition\", \"slots\", \"slotProps\"];\nimport { Popper as BasePopper } from '@mui/base/Popper';\nimport { useThemeWithoutDefault as useTheme } from '@mui/system';\nimport { HTMLElementType, refType } from '@mui/utils';\nimport PropTypes from 'prop-types';\nimport * as React from 'react';\nimport { styled, useThemeProps } from '../styles';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nconst PopperRoot = styled(BasePopper, {\n name: 'MuiPopper',\n slot: 'Root',\n overridesResolver: (props, styles) => styles.root\n})({});\n\n/**\n *\n * Demos:\n *\n * - [Autocomplete](https://mui.com/material-ui/react-autocomplete/)\n * - [Menu](https://mui.com/material-ui/react-menu/)\n * - [Popper](https://mui.com/material-ui/react-popper/)\n *\n * API:\n *\n * - [Popper API](https://mui.com/material-ui/api/popper/)\n */\nconst Popper = /*#__PURE__*/React.forwardRef(function Popper(inProps, ref) {\n var _slots$root;\n const theme = useTheme();\n const props = useThemeProps({\n props: inProps,\n name: 'MuiPopper'\n });\n const {\n anchorEl,\n component,\n components,\n componentsProps,\n container,\n disablePortal,\n keepMounted,\n modifiers,\n open,\n placement,\n popperOptions,\n popperRef,\n transition,\n slots,\n slotProps\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const RootComponent = (_slots$root = slots == null ? void 0 : slots.root) != null ? _slots$root : components == null ? void 0 : components.Root;\n const otherProps = _extends({\n anchorEl,\n container,\n disablePortal,\n keepMounted,\n modifiers,\n open,\n placement,\n popperOptions,\n popperRef,\n transition\n }, other);\n return /*#__PURE__*/_jsx(PopperRoot, _extends({\n as: component,\n direction: theme == null ? void 0 : theme.direction,\n slots: {\n root: RootComponent\n },\n slotProps: slotProps != null ? slotProps : componentsProps\n }, otherProps, {\n ref: ref\n }));\n});\nprocess.env.NODE_ENV !== \"production\" ? Popper.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * An HTML element, [virtualElement](https://popper.js.org/docs/v2/virtual-elements/),\n * or a function that returns either.\n * It's used to set the position of the popper.\n * The return value will passed as the reference object of the Popper instance.\n */\n anchorEl: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.object, PropTypes.func]),\n /**\n * Popper render function or node.\n */\n children: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.node, PropTypes.func]),\n /**\n * The component used for the root node.\n * Either a string to use a HTML element or a component.\n */\n component: PropTypes.elementType,\n /**\n * The components used for each slot inside the Popper.\n * Either a string to use a HTML element or a component.\n * @default {}\n */\n components: PropTypes.shape({\n Root: PropTypes.elementType\n }),\n /**\n * The props used for each slot inside the Popper.\n * @default {}\n */\n componentsProps: PropTypes.shape({\n root: PropTypes.oneOfType([PropTypes.func, PropTypes.object])\n }),\n /**\n * An HTML element or function that returns one.\n * The `container` will have the portal children appended to it.\n *\n * You can also provide a callback, which is called in a React layout effect.\n * This lets you set the container from a ref, and also makes server-side rendering possible.\n *\n * By default, it uses the body of the top-level document object,\n * so it's simply `document.body` most of the time.\n */\n container: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.func]),\n /**\n * The `children` will be under the DOM hierarchy of the parent component.\n * @default false\n */\n disablePortal: PropTypes.bool,\n /**\n * Always keep the children in the DOM.\n * This prop can be useful in SEO situation or\n * when you want to maximize the responsiveness of the Popper.\n * @default false\n */\n keepMounted: PropTypes.bool,\n /**\n * Popper.js is based on a \"plugin-like\" architecture,\n * most of its features are fully encapsulated \"modifiers\".\n *\n * A modifier is a function that is called each time Popper.js needs to\n * compute the position of the popper.\n * For this reason, modifiers should be very performant to avoid bottlenecks.\n * To learn how to create a modifier, [read the modifiers documentation](https://popper.js.org/docs/v2/modifiers/).\n */\n modifiers: PropTypes.arrayOf(PropTypes.shape({\n data: PropTypes.object,\n effect: PropTypes.func,\n enabled: PropTypes.bool,\n fn: PropTypes.func,\n name: PropTypes.any,\n options: PropTypes.object,\n phase: PropTypes.oneOf(['afterMain', 'afterRead', 'afterWrite', 'beforeMain', 'beforeRead', 'beforeWrite', 'main', 'read', 'write']),\n requires: PropTypes.arrayOf(PropTypes.string),\n requiresIfExists: PropTypes.arrayOf(PropTypes.string)\n })),\n /**\n * If `true`, the component is shown.\n */\n open: PropTypes.bool.isRequired,\n /**\n * Popper placement.\n * @default 'bottom'\n */\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n /**\n * Options provided to the [`Popper.js`](https://popper.js.org/docs/v2/constructors/#options) instance.\n * @default {}\n */\n popperOptions: PropTypes.shape({\n modifiers: PropTypes.array,\n onFirstUpdate: PropTypes.func,\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n strategy: PropTypes.oneOf(['absolute', 'fixed'])\n }),\n /**\n * A ref that points to the used popper instance.\n */\n popperRef: refType,\n /**\n * The props used for each slot inside the Popper.\n * @default {}\n */\n slotProps: PropTypes.shape({\n root: PropTypes.oneOfType([PropTypes.func, PropTypes.object])\n }),\n /**\n * The components used for each slot inside the Popper.\n * Either a string to use a HTML element or a component.\n * @default {}\n */\n slots: PropTypes.shape({\n root: PropTypes.elementType\n }),\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Help supporting a react-transition-group/Transition component.\n * @default false\n */\n transition: PropTypes.bool\n} : void 0;\nexport default Popper;","import generateUtilityClasses from '@mui/utils/generateUtilityClasses';\nimport generateUtilityClass from '@mui/utils/generateUtilityClass';\nexport function getTooltipUtilityClass(slot) {\n return generateUtilityClass('MuiTooltip', slot);\n}\nconst tooltipClasses = generateUtilityClasses('MuiTooltip', ['popper', 'popperInteractive', 'popperArrow', 'popperClose', 'tooltip', 'tooltipArrow', 'touch', 'tooltipPlacementLeft', 'tooltipPlacementRight', 'tooltipPlacementTop', 'tooltipPlacementBottom', 'arrow']);\nexport default tooltipClasses;","'use client';\n\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nconst _excluded = [\"arrow\", \"children\", \"classes\", \"components\", \"componentsProps\", \"describeChild\", \"disableFocusListener\", \"disableHoverListener\", \"disableInteractive\", \"disableTouchListener\", \"enterDelay\", \"enterNextDelay\", \"enterTouchDelay\", \"followCursor\", \"id\", \"leaveDelay\", \"leaveTouchDelay\", \"onClose\", \"onOpen\", \"open\", \"placement\", \"PopperComponent\", \"PopperProps\", \"slotProps\", \"slots\", \"title\", \"TransitionComponent\", \"TransitionProps\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport clsx from 'clsx';\nimport { elementAcceptingRef, unstable_useTimeout as useTimeout, unstable_Timeout as Timeout } from '@mui/utils';\nimport { unstable_composeClasses as composeClasses, appendOwnerState } from '@mui/base';\nimport { alpha } from '@mui/system';\nimport styled from '../styles/styled';\nimport useTheme from '../styles/useTheme';\nimport useThemeProps from '../styles/useThemeProps';\nimport capitalize from '../utils/capitalize';\nimport Grow from '../Grow';\nimport Popper from '../Popper';\nimport useEventCallback from '../utils/useEventCallback';\nimport useForkRef from '../utils/useForkRef';\nimport useId from '../utils/useId';\nimport useIsFocusVisible from '../utils/useIsFocusVisible';\nimport useControlled from '../utils/useControlled';\nimport tooltipClasses, { getTooltipUtilityClass } from './tooltipClasses';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nimport { jsxs as _jsxs } from \"react/jsx-runtime\";\nfunction round(value) {\n return Math.round(value * 1e5) / 1e5;\n}\nconst useUtilityClasses = ownerState => {\n const {\n classes,\n disableInteractive,\n arrow,\n touch,\n placement\n } = ownerState;\n const slots = {\n popper: ['popper', !disableInteractive && 'popperInteractive', arrow && 'popperArrow'],\n tooltip: ['tooltip', arrow && 'tooltipArrow', touch && 'touch', `tooltipPlacement${capitalize(placement.split('-')[0])}`],\n arrow: ['arrow']\n };\n return composeClasses(slots, getTooltipUtilityClass, classes);\n};\nconst TooltipPopper = styled(Popper, {\n name: 'MuiTooltip',\n slot: 'Popper',\n overridesResolver: (props, styles) => {\n const {\n ownerState\n } = props;\n return [styles.popper, !ownerState.disableInteractive && styles.popperInteractive, ownerState.arrow && styles.popperArrow, !ownerState.open && styles.popperClose];\n }\n})(({\n theme,\n ownerState,\n open\n}) => _extends({\n zIndex: (theme.vars || theme).zIndex.tooltip,\n pointerEvents: 'none'\n}, !ownerState.disableInteractive && {\n pointerEvents: 'auto'\n}, !open && {\n pointerEvents: 'none'\n}, ownerState.arrow && {\n [`&[data-popper-placement*=\"bottom\"] .${tooltipClasses.arrow}`]: {\n top: 0,\n marginTop: '-0.71em',\n '&::before': {\n transformOrigin: '0 100%'\n }\n },\n [`&[data-popper-placement*=\"top\"] .${tooltipClasses.arrow}`]: {\n bottom: 0,\n marginBottom: '-0.71em',\n '&::before': {\n transformOrigin: '100% 0'\n }\n },\n [`&[data-popper-placement*=\"right\"] .${tooltipClasses.arrow}`]: _extends({}, !ownerState.isRtl ? {\n left: 0,\n marginLeft: '-0.71em'\n } : {\n right: 0,\n marginRight: '-0.71em'\n }, {\n height: '1em',\n width: '0.71em',\n '&::before': {\n transformOrigin: '100% 100%'\n }\n }),\n [`&[data-popper-placement*=\"left\"] .${tooltipClasses.arrow}`]: _extends({}, !ownerState.isRtl ? {\n right: 0,\n marginRight: '-0.71em'\n } : {\n left: 0,\n marginLeft: '-0.71em'\n }, {\n height: '1em',\n width: '0.71em',\n '&::before': {\n transformOrigin: '0 0'\n }\n })\n}));\nconst TooltipTooltip = styled('div', {\n name: 'MuiTooltip',\n slot: 'Tooltip',\n overridesResolver: (props, styles) => {\n const {\n ownerState\n } = props;\n return [styles.tooltip, ownerState.touch && styles.touch, ownerState.arrow && styles.tooltipArrow, styles[`tooltipPlacement${capitalize(ownerState.placement.split('-')[0])}`]];\n }\n})(({\n theme,\n ownerState\n}) => _extends({\n backgroundColor: theme.vars ? theme.vars.palette.Tooltip.bg : alpha(theme.palette.grey[700], 0.92),\n borderRadius: (theme.vars || theme).shape.borderRadius,\n color: (theme.vars || theme).palette.common.white,\n fontFamily: theme.typography.fontFamily,\n padding: '4px 8px',\n fontSize: theme.typography.pxToRem(11),\n maxWidth: 300,\n margin: 2,\n wordWrap: 'break-word',\n fontWeight: theme.typography.fontWeightMedium\n}, ownerState.arrow && {\n position: 'relative',\n margin: 0\n}, ownerState.touch && {\n padding: '8px 16px',\n fontSize: theme.typography.pxToRem(14),\n lineHeight: `${round(16 / 14)}em`,\n fontWeight: theme.typography.fontWeightRegular\n}, {\n [`.${tooltipClasses.popper}[data-popper-placement*=\"left\"] &`]: _extends({\n transformOrigin: 'right center'\n }, !ownerState.isRtl ? _extends({\n marginRight: '14px'\n }, ownerState.touch && {\n marginRight: '24px'\n }) : _extends({\n marginLeft: '14px'\n }, ownerState.touch && {\n marginLeft: '24px'\n })),\n [`.${tooltipClasses.popper}[data-popper-placement*=\"right\"] &`]: _extends({\n transformOrigin: 'left center'\n }, !ownerState.isRtl ? _extends({\n marginLeft: '14px'\n }, ownerState.touch && {\n marginLeft: '24px'\n }) : _extends({\n marginRight: '14px'\n }, ownerState.touch && {\n marginRight: '24px'\n })),\n [`.${tooltipClasses.popper}[data-popper-placement*=\"top\"] &`]: _extends({\n transformOrigin: 'center bottom',\n marginBottom: '14px'\n }, ownerState.touch && {\n marginBottom: '24px'\n }),\n [`.${tooltipClasses.popper}[data-popper-placement*=\"bottom\"] &`]: _extends({\n transformOrigin: 'center top',\n marginTop: '14px'\n }, ownerState.touch && {\n marginTop: '24px'\n })\n}));\nconst TooltipArrow = styled('span', {\n name: 'MuiTooltip',\n slot: 'Arrow',\n overridesResolver: (props, styles) => styles.arrow\n})(({\n theme\n}) => ({\n overflow: 'hidden',\n position: 'absolute',\n width: '1em',\n height: '0.71em' /* = width / sqrt(2) = (length of the hypotenuse) */,\n boxSizing: 'border-box',\n color: theme.vars ? theme.vars.palette.Tooltip.bg : alpha(theme.palette.grey[700], 0.9),\n '&::before': {\n content: '\"\"',\n margin: 'auto',\n display: 'block',\n width: '100%',\n height: '100%',\n backgroundColor: 'currentColor',\n transform: 'rotate(45deg)'\n }\n}));\nlet hystersisOpen = false;\nconst hystersisTimer = new Timeout();\nlet cursorPosition = {\n x: 0,\n y: 0\n};\nexport function testReset() {\n hystersisOpen = false;\n hystersisTimer.clear();\n}\nfunction composeEventHandler(handler, eventHandler) {\n return event => {\n if (eventHandler) {\n eventHandler(event);\n }\n handler(event);\n };\n}\n\n// TODO v6: Remove PopperComponent, PopperProps, TransitionComponent and TransitionProps.\nconst Tooltip = /*#__PURE__*/React.forwardRef(function Tooltip(inProps, ref) {\n var _ref, _slots$popper, _ref2, _ref3, _slots$transition, _ref4, _slots$tooltip, _ref5, _slots$arrow, _slotProps$popper, _ref6, _slotProps$popper2, _slotProps$transition, _slotProps$tooltip, _ref7, _slotProps$tooltip2, _slotProps$arrow, _ref8, _slotProps$arrow2;\n const props = useThemeProps({\n props: inProps,\n name: 'MuiTooltip'\n });\n const {\n arrow = false,\n children: childrenProp,\n components = {},\n componentsProps = {},\n describeChild = false,\n disableFocusListener = false,\n disableHoverListener = false,\n disableInteractive: disableInteractiveProp = false,\n disableTouchListener = false,\n enterDelay = 100,\n enterNextDelay = 0,\n enterTouchDelay = 700,\n followCursor = false,\n id: idProp,\n leaveDelay = 0,\n leaveTouchDelay = 1500,\n onClose,\n onOpen,\n open: openProp,\n placement = 'bottom',\n PopperComponent: PopperComponentProp,\n PopperProps = {},\n slotProps = {},\n slots = {},\n title,\n TransitionComponent: TransitionComponentProp = Grow,\n TransitionProps\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n\n // to prevent runtime errors, developers will need to provide a child as a React element anyway.\n const children = /*#__PURE__*/React.isValidElement(childrenProp) ? childrenProp : /*#__PURE__*/_jsx(\"span\", {\n children: childrenProp\n });\n const theme = useTheme();\n const isRtl = theme.direction === 'rtl';\n const [childNode, setChildNode] = React.useState();\n const [arrowRef, setArrowRef] = React.useState(null);\n const ignoreNonTouchEvents = React.useRef(false);\n const disableInteractive = disableInteractiveProp || followCursor;\n const closeTimer = useTimeout();\n const enterTimer = useTimeout();\n const leaveTimer = useTimeout();\n const touchTimer = useTimeout();\n const [openState, setOpenState] = useControlled({\n controlled: openProp,\n default: false,\n name: 'Tooltip',\n state: 'open'\n });\n let open = openState;\n if (process.env.NODE_ENV !== 'production') {\n // eslint-disable-next-line react-hooks/rules-of-hooks\n const {\n current: isControlled\n } = React.useRef(openProp !== undefined);\n\n // eslint-disable-next-line react-hooks/rules-of-hooks\n React.useEffect(() => {\n if (childNode && childNode.disabled && !isControlled && title !== '' && childNode.tagName.toLowerCase() === 'button') {\n console.error(['MUI: You are providing a disabled `button` child to the Tooltip component.', 'A disabled element does not fire events.', \"Tooltip needs to listen to the child element's events to display the title.\", '', 'Add a simple wrapper element, such as a `span`.'].join('\\n'));\n }\n }, [title, childNode, isControlled]);\n }\n const id = useId(idProp);\n const prevUserSelect = React.useRef();\n const stopTouchInteraction = useEventCallback(() => {\n if (prevUserSelect.current !== undefined) {\n document.body.style.WebkitUserSelect = prevUserSelect.current;\n prevUserSelect.current = undefined;\n }\n touchTimer.clear();\n });\n React.useEffect(() => stopTouchInteraction, [stopTouchInteraction]);\n const handleOpen = event => {\n hystersisTimer.clear();\n hystersisOpen = true;\n\n // The mouseover event will trigger for every nested element in the tooltip.\n // We can skip rerendering when the tooltip is already open.\n // We are using the mouseover event instead of the mouseenter event to fix a hide/show issue.\n setOpenState(true);\n if (onOpen && !open) {\n onOpen(event);\n }\n };\n const handleClose = useEventCallback(\n /**\n * @param {React.SyntheticEvent | Event} event\n */\n event => {\n hystersisTimer.start(800 + leaveDelay, () => {\n hystersisOpen = false;\n });\n setOpenState(false);\n if (onClose && open) {\n onClose(event);\n }\n closeTimer.start(theme.transitions.duration.shortest, () => {\n ignoreNonTouchEvents.current = false;\n });\n });\n const handleEnter = event => {\n if (ignoreNonTouchEvents.current && event.type !== 'touchstart') {\n return;\n }\n\n // Remove the title ahead of time.\n // We don't want to wait for the next render commit.\n // We would risk displaying two tooltips at the same time (native + this one).\n if (childNode) {\n childNode.removeAttribute('title');\n }\n enterTimer.clear();\n leaveTimer.clear();\n if (enterDelay || hystersisOpen && enterNextDelay) {\n enterTimer.start(hystersisOpen ? enterNextDelay : enterDelay, () => {\n handleOpen(event);\n });\n } else {\n handleOpen(event);\n }\n };\n const handleLeave = event => {\n enterTimer.clear();\n leaveTimer.start(leaveDelay, () => {\n handleClose(event);\n });\n };\n const {\n isFocusVisibleRef,\n onBlur: handleBlurVisible,\n onFocus: handleFocusVisible,\n ref: focusVisibleRef\n } = useIsFocusVisible();\n // We don't necessarily care about the focusVisible state (which is safe to access via ref anyway).\n // We just need to re-render the Tooltip if the focus-visible state changes.\n const [, setChildIsFocusVisible] = React.useState(false);\n const handleBlur = event => {\n handleBlurVisible(event);\n if (isFocusVisibleRef.current === false) {\n setChildIsFocusVisible(false);\n handleLeave(event);\n }\n };\n const handleFocus = event => {\n // Workaround for https://github.com/facebook/react/issues/7769\n // The autoFocus of React might trigger the event before the componentDidMount.\n // We need to account for this eventuality.\n if (!childNode) {\n setChildNode(event.currentTarget);\n }\n handleFocusVisible(event);\n if (isFocusVisibleRef.current === true) {\n setChildIsFocusVisible(true);\n handleEnter(event);\n }\n };\n const detectTouchStart = event => {\n ignoreNonTouchEvents.current = true;\n const childrenProps = children.props;\n if (childrenProps.onTouchStart) {\n childrenProps.onTouchStart(event);\n }\n };\n const handleMouseOver = handleEnter;\n const handleMouseLeave = handleLeave;\n const handleTouchStart = event => {\n detectTouchStart(event);\n leaveTimer.clear();\n closeTimer.clear();\n stopTouchInteraction();\n prevUserSelect.current = document.body.style.WebkitUserSelect;\n // Prevent iOS text selection on long-tap.\n document.body.style.WebkitUserSelect = 'none';\n touchTimer.start(enterTouchDelay, () => {\n document.body.style.WebkitUserSelect = prevUserSelect.current;\n handleEnter(event);\n });\n };\n const handleTouchEnd = event => {\n if (children.props.onTouchEnd) {\n children.props.onTouchEnd(event);\n }\n stopTouchInteraction();\n leaveTimer.start(leaveTouchDelay, () => {\n handleClose(event);\n });\n };\n React.useEffect(() => {\n if (!open) {\n return undefined;\n }\n\n /**\n * @param {KeyboardEvent} nativeEvent\n */\n function handleKeyDown(nativeEvent) {\n // IE11, Edge (prior to using Bink?) use 'Esc'\n if (nativeEvent.key === 'Escape' || nativeEvent.key === 'Esc') {\n handleClose(nativeEvent);\n }\n }\n document.addEventListener('keydown', handleKeyDown);\n return () => {\n document.removeEventListener('keydown', handleKeyDown);\n };\n }, [handleClose, open]);\n const handleRef = useForkRef(children.ref, focusVisibleRef, setChildNode, ref);\n\n // There is no point in displaying an empty tooltip.\n // So we exclude all falsy values, except 0, which is valid.\n if (!title && title !== 0) {\n open = false;\n }\n const popperRef = React.useRef();\n const handleMouseMove = event => {\n const childrenProps = children.props;\n if (childrenProps.onMouseMove) {\n childrenProps.onMouseMove(event);\n }\n cursorPosition = {\n x: event.clientX,\n y: event.clientY\n };\n if (popperRef.current) {\n popperRef.current.update();\n }\n };\n const nameOrDescProps = {};\n const titleIsString = typeof title === 'string';\n if (describeChild) {\n nameOrDescProps.title = !open && titleIsString && !disableHoverListener ? title : null;\n nameOrDescProps['aria-describedby'] = open ? id : null;\n } else {\n nameOrDescProps['aria-label'] = titleIsString ? title : null;\n nameOrDescProps['aria-labelledby'] = open && !titleIsString ? id : null;\n }\n const childrenProps = _extends({}, nameOrDescProps, other, children.props, {\n className: clsx(other.className, children.props.className),\n onTouchStart: detectTouchStart,\n ref: handleRef\n }, followCursor ? {\n onMouseMove: handleMouseMove\n } : {});\n if (process.env.NODE_ENV !== 'production') {\n childrenProps['data-mui-internal-clone-element'] = true;\n\n // eslint-disable-next-line react-hooks/rules-of-hooks\n React.useEffect(() => {\n if (childNode && !childNode.getAttribute('data-mui-internal-clone-element')) {\n console.error(['MUI: The `children` component of the Tooltip is not forwarding its props correctly.', 'Please make sure that props are spread on the same element that the ref is applied to.'].join('\\n'));\n }\n }, [childNode]);\n }\n const interactiveWrapperListeners = {};\n if (!disableTouchListener) {\n childrenProps.onTouchStart = handleTouchStart;\n childrenProps.onTouchEnd = handleTouchEnd;\n }\n if (!disableHoverListener) {\n childrenProps.onMouseOver = composeEventHandler(handleMouseOver, childrenProps.onMouseOver);\n childrenProps.onMouseLeave = composeEventHandler(handleMouseLeave, childrenProps.onMouseLeave);\n if (!disableInteractive) {\n interactiveWrapperListeners.onMouseOver = handleMouseOver;\n interactiveWrapperListeners.onMouseLeave = handleMouseLeave;\n }\n }\n if (!disableFocusListener) {\n childrenProps.onFocus = composeEventHandler(handleFocus, childrenProps.onFocus);\n childrenProps.onBlur = composeEventHandler(handleBlur, childrenProps.onBlur);\n if (!disableInteractive) {\n interactiveWrapperListeners.onFocus = handleFocus;\n interactiveWrapperListeners.onBlur = handleBlur;\n }\n }\n if (process.env.NODE_ENV !== 'production') {\n if (children.props.title) {\n console.error(['MUI: You have provided a `title` prop to the child of .', `Remove this title prop \\`${children.props.title}\\` or the Tooltip component.`].join('\\n'));\n }\n }\n const popperOptions = React.useMemo(() => {\n var _PopperProps$popperOp;\n let tooltipModifiers = [{\n name: 'arrow',\n enabled: Boolean(arrowRef),\n options: {\n element: arrowRef,\n padding: 4\n }\n }];\n if ((_PopperProps$popperOp = PopperProps.popperOptions) != null && _PopperProps$popperOp.modifiers) {\n tooltipModifiers = tooltipModifiers.concat(PopperProps.popperOptions.modifiers);\n }\n return _extends({}, PopperProps.popperOptions, {\n modifiers: tooltipModifiers\n });\n }, [arrowRef, PopperProps]);\n const ownerState = _extends({}, props, {\n isRtl,\n arrow,\n disableInteractive,\n placement,\n PopperComponentProp,\n touch: ignoreNonTouchEvents.current\n });\n const classes = useUtilityClasses(ownerState);\n const PopperComponent = (_ref = (_slots$popper = slots.popper) != null ? _slots$popper : components.Popper) != null ? _ref : TooltipPopper;\n const TransitionComponent = (_ref2 = (_ref3 = (_slots$transition = slots.transition) != null ? _slots$transition : components.Transition) != null ? _ref3 : TransitionComponentProp) != null ? _ref2 : Grow;\n const TooltipComponent = (_ref4 = (_slots$tooltip = slots.tooltip) != null ? _slots$tooltip : components.Tooltip) != null ? _ref4 : TooltipTooltip;\n const ArrowComponent = (_ref5 = (_slots$arrow = slots.arrow) != null ? _slots$arrow : components.Arrow) != null ? _ref5 : TooltipArrow;\n const popperProps = appendOwnerState(PopperComponent, _extends({}, PopperProps, (_slotProps$popper = slotProps.popper) != null ? _slotProps$popper : componentsProps.popper, {\n className: clsx(classes.popper, PopperProps == null ? void 0 : PopperProps.className, (_ref6 = (_slotProps$popper2 = slotProps.popper) != null ? _slotProps$popper2 : componentsProps.popper) == null ? void 0 : _ref6.className)\n }), ownerState);\n const transitionProps = appendOwnerState(TransitionComponent, _extends({}, TransitionProps, (_slotProps$transition = slotProps.transition) != null ? _slotProps$transition : componentsProps.transition), ownerState);\n const tooltipProps = appendOwnerState(TooltipComponent, _extends({}, (_slotProps$tooltip = slotProps.tooltip) != null ? _slotProps$tooltip : componentsProps.tooltip, {\n className: clsx(classes.tooltip, (_ref7 = (_slotProps$tooltip2 = slotProps.tooltip) != null ? _slotProps$tooltip2 : componentsProps.tooltip) == null ? void 0 : _ref7.className)\n }), ownerState);\n const tooltipArrowProps = appendOwnerState(ArrowComponent, _extends({}, (_slotProps$arrow = slotProps.arrow) != null ? _slotProps$arrow : componentsProps.arrow, {\n className: clsx(classes.arrow, (_ref8 = (_slotProps$arrow2 = slotProps.arrow) != null ? _slotProps$arrow2 : componentsProps.arrow) == null ? void 0 : _ref8.className)\n }), ownerState);\n return /*#__PURE__*/_jsxs(React.Fragment, {\n children: [/*#__PURE__*/React.cloneElement(children, childrenProps), /*#__PURE__*/_jsx(PopperComponent, _extends({\n as: PopperComponentProp != null ? PopperComponentProp : Popper,\n placement: placement,\n anchorEl: followCursor ? {\n getBoundingClientRect: () => ({\n top: cursorPosition.y,\n left: cursorPosition.x,\n right: cursorPosition.x,\n bottom: cursorPosition.y,\n width: 0,\n height: 0\n })\n } : childNode,\n popperRef: popperRef,\n open: childNode ? open : false,\n id: id,\n transition: true\n }, interactiveWrapperListeners, popperProps, {\n popperOptions: popperOptions,\n children: ({\n TransitionProps: TransitionPropsInner\n }) => /*#__PURE__*/_jsx(TransitionComponent, _extends({\n timeout: theme.transitions.duration.shorter\n }, TransitionPropsInner, transitionProps, {\n children: /*#__PURE__*/_jsxs(TooltipComponent, _extends({}, tooltipProps, {\n children: [title, arrow ? /*#__PURE__*/_jsx(ArrowComponent, _extends({}, tooltipArrowProps, {\n ref: setArrowRef\n })) : null]\n }))\n }))\n }))]\n });\n});\nprocess.env.NODE_ENV !== \"production\" ? Tooltip.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the d.ts file and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * If `true`, adds an arrow to the tooltip.\n * @default false\n */\n arrow: PropTypes.bool,\n /**\n * Tooltip reference element.\n */\n children: elementAcceptingRef.isRequired,\n /**\n * Override or extend the styles applied to the component.\n */\n classes: PropTypes.object,\n /**\n * @ignore\n */\n className: PropTypes.string,\n /**\n * The components used for each slot inside.\n *\n * This prop is an alias for the `slots` prop.\n * It's recommended to use the `slots` prop instead.\n *\n * @default {}\n */\n components: PropTypes.shape({\n Arrow: PropTypes.elementType,\n Popper: PropTypes.elementType,\n Tooltip: PropTypes.elementType,\n Transition: PropTypes.elementType\n }),\n /**\n * The extra props for the slot components.\n * You can override the existing props or add new ones.\n *\n * This prop is an alias for the `slotProps` prop.\n * It's recommended to use the `slotProps` prop instead, as `componentsProps` will be deprecated in the future.\n *\n * @default {}\n */\n componentsProps: PropTypes.shape({\n arrow: PropTypes.object,\n popper: PropTypes.object,\n tooltip: PropTypes.object,\n transition: PropTypes.object\n }),\n /**\n * Set to `true` if the `title` acts as an accessible description.\n * By default the `title` acts as an accessible label for the child.\n * @default false\n */\n describeChild: PropTypes.bool,\n /**\n * Do not respond to focus-visible events.\n * @default false\n */\n disableFocusListener: PropTypes.bool,\n /**\n * Do not respond to hover events.\n * @default false\n */\n disableHoverListener: PropTypes.bool,\n /**\n * Makes a tooltip not interactive, i.e. it will close when the user\n * hovers over the tooltip before the `leaveDelay` is expired.\n * @default false\n */\n disableInteractive: PropTypes.bool,\n /**\n * Do not respond to long press touch events.\n * @default false\n */\n disableTouchListener: PropTypes.bool,\n /**\n * The number of milliseconds to wait before showing the tooltip.\n * This prop won't impact the enter touch delay (`enterTouchDelay`).\n * @default 100\n */\n enterDelay: PropTypes.number,\n /**\n * The number of milliseconds to wait before showing the tooltip when one was already recently opened.\n * @default 0\n */\n enterNextDelay: PropTypes.number,\n /**\n * The number of milliseconds a user must touch the element before showing the tooltip.\n * @default 700\n */\n enterTouchDelay: PropTypes.number,\n /**\n * If `true`, the tooltip follow the cursor over the wrapped element.\n * @default false\n */\n followCursor: PropTypes.bool,\n /**\n * This prop is used to help implement the accessibility logic.\n * If you don't provide this prop. It falls back to a randomly generated id.\n */\n id: PropTypes.string,\n /**\n * The number of milliseconds to wait before hiding the tooltip.\n * This prop won't impact the leave touch delay (`leaveTouchDelay`).\n * @default 0\n */\n leaveDelay: PropTypes.number,\n /**\n * The number of milliseconds after the user stops touching an element before hiding the tooltip.\n * @default 1500\n */\n leaveTouchDelay: PropTypes.number,\n /**\n * Callback fired when the component requests to be closed.\n *\n * @param {React.SyntheticEvent} event The event source of the callback.\n */\n onClose: PropTypes.func,\n /**\n * Callback fired when the component requests to be open.\n *\n * @param {React.SyntheticEvent} event The event source of the callback.\n */\n onOpen: PropTypes.func,\n /**\n * If `true`, the component is shown.\n */\n open: PropTypes.bool,\n /**\n * Tooltip placement.\n * @default 'bottom'\n */\n placement: PropTypes.oneOf(['bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n /**\n * The component used for the popper.\n * @default Popper\n */\n PopperComponent: PropTypes.elementType,\n /**\n * Props applied to the [`Popper`](/material-ui/api/popper/) element.\n * @default {}\n */\n PopperProps: PropTypes.object,\n /**\n * The extra props for the slot components.\n * You can override the existing props or add new ones.\n *\n * This prop is an alias for the `componentsProps` prop, which will be deprecated in the future.\n *\n * @default {}\n */\n slotProps: PropTypes.shape({\n arrow: PropTypes.object,\n popper: PropTypes.object,\n tooltip: PropTypes.object,\n transition: PropTypes.object\n }),\n /**\n * The components used for each slot inside.\n *\n * This prop is an alias for the `components` prop, which will be deprecated in the future.\n *\n * @default {}\n */\n slots: PropTypes.shape({\n arrow: PropTypes.elementType,\n popper: PropTypes.elementType,\n tooltip: PropTypes.elementType,\n transition: PropTypes.elementType\n }),\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Tooltip title. Zero-length titles string, undefined, null and false are never displayed.\n */\n title: PropTypes.node,\n /**\n * The component used for the transition.\n * [Follow this guide](/material-ui/transitions/#transitioncomponent-prop) to learn more about the requirements for this component.\n * @default Grow\n */\n TransitionComponent: PropTypes.elementType,\n /**\n * Props applied to the transition element.\n * By default, the element is based on this [`Transition`](http://reactcommunity.org/react-transition-group/transition/) component.\n */\n TransitionProps: PropTypes.object\n} : void 0;\nexport default Tooltip;","import '@/components/mui/menu-item.component.css';\nimport ArrowRightIcon from '@mui/icons-material/ArrowRight';\nimport {\n ListItemIcon as MuiListItemIcon,\n ListItemText as MuiListItemText,\n MenuItem as MuiMenuItem,\n} from '@mui/material';\nimport Tooltip from '@mui/material/Tooltip';\nimport { Localized, ReferencedItem, SingleColumnMenu } from 'platform-bible-utils';\nimport { MouseEvent, PropsWithChildren } from 'react';\n\ntype MenuItemInfoBase = {\n /** Text (displayable in the UI) as the name of the menu item */\n label: string;\n /** Text to display when the mouse hovers over the menu item */\n tooltip?: string;\n};\n\nexport type Command = MenuItemInfoBase & {\n /** Command to execute (string.string) */\n command: string;\n};\n\ntype SubMenu = MenuItemInfoBase & {\n /** Command to execute (string.string) */\n items: MenuItemInfo[];\n};\n\nexport interface CommandHandler {\n (command: Command): void;\n}\n\nexport type MenuPropsBase = {\n /*\n * The JSON defining the menu whose items are to be rendered. This will typically be one of the\n * menus in the \"defs\" in a Platform.Bible menu (see PlatformMenus). The schema for this is\n * menuDocumentSchema (at the end of menus.model.ts). Note that while this is a\n * \"SingleColumnMenu\", somewhat bizarrely, a MultiColumnMenu is a SingleColumnMenu, so it really\n * could be a MultiColumnMenu, in which case, column had better be defined so it can be used\n * to filter out the actual groups and items to display on the column.\n */\n menuDefinition: Localized;\n\n commandHandler: CommandHandler;\n\n /**\n * Additional action to perform when any menu item is clicked. Allows the caller to handle event\n * (e.g., to close the menu).\n */\n onClick?: (event: MouseEvent) => void;\n};\n\nexport type MenuItemListProps = MenuPropsBase & {\n /** Optional unique (column) identifier */\n columnId?: ReferencedItem;\n};\n\nexport type MenuItemProps = Omit &\n PropsWithChildren<{\n /** Optional unique identifier */\n id?: string;\n\n onClick: (event: MouseEvent) => void;\n }>;\n\ntype MenuItemInfo = (Command | SubMenu) & {\n /**\n * If specified, menu item will be inset if it does not have a leading icon.\n *\n * @default true\n */\n allowForLeadingIcons?: boolean;\n /**\n * If specified, the path to the icon image to display on the leading side of the menu text.\n *\n * @default undefined (no leading icon will be shown)\n */\n iconPathBefore?: string;\n /**\n * If specified, the path to the icon image to display on the trailing side of the menu text.\n *\n * @default undefined (no trailing icon will be shown)\n */\n iconPathAfter?: string;\n /**\n * If true, list item is focused during the first mount\n *\n * @default false\n */\n hasAutoFocus?: boolean;\n\n /** Additional css classes to help with unique styling of the menu item */\n className?: string;\n\n /**\n * If true, the menu item will appear disabled and it will not respond to clicks or mouse hovers.\n *\n * @default false\n */\n isDisabled?: boolean;\n\n /**\n * If true, compact vertical padding designed for keyboard and mouse input is used.\n *\n * @default true\n */\n isDense?: boolean;\n\n /**\n * If true, a right-arrow icon will be displayed (iconPathAfter, if specified, will be ignored).\n *\n * @default false\n */\n isSubMenuParent?: boolean;\n\n /**\n * If true, the left and right padding is removed\n *\n * @default false\n */\n hasDisabledGutters?: boolean;\n\n /**\n * If true, a 1px light border is added to bottom of menu item\n *\n * @default false\n */\n hasDivider?: boolean;\n\n /** Help identify which element has keyboard focus */\n focusVisibleClassName?: string;\n\n /** If it's a submenu, it should have the items property */\n items?: MenuItemInfo[];\n};\n\nfunction getIcon(icon: string | undefined, menuLabel: string, leading: boolean) {\n return icon ? (\n \n {`${leading\n \n ) : undefined;\n}\n\nexport default function MenuItem(props: MenuItemProps) {\n const {\n onClick,\n label,\n tooltip,\n allowForLeadingIcons = true,\n iconPathBefore = undefined,\n iconPathAfter = undefined,\n hasAutoFocus = false,\n className,\n isDisabled = false,\n isDense = true,\n isSubMenuParent = false,\n hasDisabledGutters = false,\n hasDivider = false,\n focusVisibleClassName,\n id,\n children,\n } = props;\n\n const menuItem = (\n \n {label ? (\n <>\n {getIcon(iconPathBefore, label, true)}\n \n {isSubMenuParent ? (\n \n \n \n ) : (\n getIcon(iconPathAfter, label, false)\n )}\n \n ) : (\n children\n )}\n \n );\n\n return tooltip ? (\n \n
    {menuItem}
    \n
    \n ) : (\n menuItem\n );\n}\n","import MenuItem, {\n MenuItemListProps,\n MenuItemProps,\n MenuPropsBase,\n} from '@/components/mui/menu-item.component';\nimport { Menu } from '@mui/material';\nimport {\n Localized,\n MenuGroupDetailsInSubMenu,\n MenuItemContainingCommand,\n MenuItemContainingSubmenu,\n OrderedExtensibleContainer,\n ReferencedItem,\n SingleColumnMenu,\n} from 'platform-bible-utils';\nimport { MouseEvent, useMemo, useState } from 'react';\n\n/**\n * All the exported types in this file should be regarded as \"internal\" (i.e., they should not be\n * exposed via index.ts).\n */\n\nexport type GroupedMenuPropsBase = MenuPropsBase & {\n /** Optional unique (column) identifier */\n columnId?: ReferencedItem;\n};\n\nexport type GroupedMenuItemListProps = MenuItemListProps & {\n /**\n * If the menuDefinition includes \"top-level\" groups (i.e., those that belong to a column as\n * opposed to those that belong to a submenu) that should not be included in the list, then this\n * array specifies which groups to include. Likewise, for a submenu, this list indicates which\n * groups are pertinent for that submenu. So then for a context menu this property need not be\n * specified since it is a top-level menu based on a \"true\" SingleColumnMenu (i.e., one that is\n * not a MultiColumnMenu).\n */\n includedGroups?: {\n id: string;\n group: Localized;\n }[];\n};\n\ninterface ItemInfo {\n item: Localized;\n isLastItemInGroup: boolean;\n}\n\ntype SubMenuProps = MenuPropsBase & {\n parentMenuItem: Localized;\n parentItemProps: Omit, 'iconPathAfter'>;\n};\n\nfunction getAllGroups(menuDefinition: Localized) {\n const groupEntries = Object.entries(menuDefinition.groups);\n // Convert array of entries to array of objects with id and group properties\n return groupEntries.map(([key, value]) => ({ id: key, group: value }));\n}\n\nfunction SubMenu(props: SubMenuProps) {\n const [anchorEl, setAnchorEl] = useState(undefined);\n\n const { parentMenuItem, parentItemProps, menuDefinition } = props;\n\n const handleParentMenuItemClick = (event: MouseEvent) => {\n setAnchorEl(event.currentTarget);\n };\n\n const handleClose = () => {\n setAnchorEl(undefined);\n };\n\n const renderSubMenuItems = () => {\n let includedGroups = getAllGroups(menuDefinition).filter((g) => 'menuItem' in g.group);\n\n // Ensure valid parent menu was provided. (If not, submenu will contain all groups!)\n if (!parentMenuItem?.id) throw new Error('A valid parent menu item is required for submenus.');\n\n // When laying out a submenu, only include groups associated with the provided parent menu.\n // Note: without the (annoying) redundant check that the included groups\n // have the menuItem field, TS doesn't think it exists.\n includedGroups = includedGroups.filter(\n (group) => 'menuItem' in group.group && group.group.menuItem === parentMenuItem.id,\n );\n\n return ;\n };\n\n return (\n <>\n \n \n {renderSubMenuItems()}\n \n \n );\n}\n\nconst getOrderedGroupItems = (\n groupId: string,\n allItems: Localized[],\n) => {\n // Filter items that belong to the specified group\n const itemsForGroup = allItems.filter((item) => item.group === groupId);\n // Sort items based on order\n const sortedItems = itemsForGroup.sort((a, b) => (a.order || 0) - (b.order || 0));\n return sortedItems;\n};\n\n/**\n * This component is internal; it does not need to be exposed to the outside world since it is not\n * useful on its own. It is used to generate and lay out the MenuItems that appear either on a\n * top-level menu (in a GridMenu or ContextMenu) or in a submenu.\n */\nexport default function GroupedMenuItemList(menuProps: GroupedMenuItemListProps) {\n const { menuDefinition, onClick, commandHandler, includedGroups } = menuProps;\n\n const { items, allowForLeadingIcons } = useMemo(() => {\n const groupsToInclude =\n includedGroups && includedGroups.length > 0\n ? includedGroups\n : // We're apparently laying out a single-column menu (presumably a context menu). In this\n // case, all groups should be included except ones that belong to a submenu.\n getAllGroups(menuDefinition).filter((g) => !('menuItem' in g.group));\n\n const sortedGroups = Object.values(groupsToInclude).sort(\n (a, b) => (a.group.order || 0) - (b.group.order || 0),\n );\n\n const itemArray: ItemInfo[] = [];\n\n sortedGroups.forEach((group) => {\n getOrderedGroupItems(group.id, menuDefinition.items).forEach((item) =>\n itemArray.push({ item, isLastItemInGroup: false }),\n );\n if (itemArray.length > 0) itemArray[itemArray.length - 1].isLastItemInGroup = true;\n });\n\n // No divider after last item in final group.\n if (itemArray.length > 0) itemArray[itemArray.length - 1].isLastItemInGroup = false;\n\n const allowSpaceForLeadingIcons = itemArray.some(\n (i) => 'iconPathBefore' in i.item && i.item.iconPathBefore,\n );\n\n return { items: itemArray, allowForLeadingIcons: allowSpaceForLeadingIcons };\n }, [includedGroups, menuDefinition]);\n\n // Create props for MenuItem component including setting hasDivider for the last item in a group\n const createMenuItemProps = ({ item, isLastItemInGroup }: ItemInfo) => {\n const menuItemProps = {\n className: 'papi-menu-item',\n label: item.label,\n tooltip: item.tooltip,\n iconPathBefore: 'iconPathBefore' in item ? item.iconPathBefore : undefined,\n iconPathAfter: 'iconPathAfter' in item ? item.iconPathAfter : undefined,\n hasDivider: isLastItemInGroup, // Set hasDivider to true for the last item in a group\n allowForLeadingIcons,\n };\n\n return menuItemProps;\n };\n\n const [firstItem] = items;\n\n if (!firstItem) return
    ;\n\n const divKey = firstItem.item.group;\n\n return (\n
    \n {items.map((itemInfo, index) => {\n const { item } = itemInfo;\n const menuItemProps = createMenuItemProps(itemInfo);\n if ('command' in item) {\n const key = item.group + index;\n return (\n ) => {\n onClick?.(event);\n commandHandler(item);\n }}\n {...menuItemProps}\n />\n );\n }\n return (\n \n );\n })}\n
    \n );\n}\n","import GroupedMenuItemList from '@/components/mui/grouped-menu-item-list.component';\nimport { MenuItemListProps } from '@/components/mui/menu-item.component';\nimport { MultiColumnMenu } from 'platform-bible-utils';\n\n/**\n * This component is internal; it does not need to be exposed to the outside world since it is not\n * useful on its own. Use either GridMenu or ContextMenu.\n */\nexport default function TopLevelMenu(props: MenuItemListProps) {\n const { menuDefinition, columnId } = props;\n\n const groupEntries = Object.entries(menuDefinition.groups);\n // Convert array of entries to array of objects with id and group properties\n const groups = groupEntries.map(([key, value]) => ({ id: key, group: value }));\n let includedGroups = groups.filter((g) => 'column' in g.group);\n\n // Check if column is provided and menuDefinition is a MultiColumnMenu\n if (\n columnId &&\n 'columns' in menuDefinition &&\n // Without this type assertion, TS doesn't know what columns is.\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n (menuDefinition as MultiColumnMenu).columns[columnId]\n ) {\n // When laying out a single column in a MultiColumnMenu, only include groups associated with\n // the provided column. Note: without the (annoying) redundant check that the included groups\n // have the colum field, TS doesn't think it exists.\n includedGroups = includedGroups.filter(\n (g) => 'column' in g.group && g.group.column === columnId,\n );\n }\n\n return ;\n}\n","import '@/components/mui/grid-menu.component.css';\nimport { GroupedMenuPropsBase } from '@/components/mui/grouped-menu-item-list.component';\nimport { CommandHandler } from '@/components/mui/menu-item.component';\nimport TopLevelMenu from '@/components/mui/top-level-menu.component';\nimport { Grid, List } from '@mui/material';\nimport {\n Localized,\n MenuColumnWithHeader,\n MultiColumnMenu,\n ReferencedItem,\n} from 'platform-bible-utils';\nimport { useMemo } from 'react';\n\ntype ColumnInfo = {\n /*\n * The ID (`${string}.${string}`) of a specific menu column.\n */\n id: ReferencedItem;\n\n /*\n * Metadata (label, order, etc.) for a specific menu column.\n */\n metadata: Localized;\n};\n\ntype MenuColumnProps = ColumnInfo &\n GroupedMenuPropsBase & {\n /** Additional css classes to help with unique styling of the menu column */\n className?: string;\n };\n\nexport type GridMenuInfo = {\n /** The menu object containing information about the columns, groups, and items to display. */\n multiColumnMenu: Localized;\n};\n\nexport type GridMenuProps = GridMenuInfo & {\n /** Optional unique identifier */\n id?: string;\n\n commandHandler: CommandHandler;\n\n /** Additional css classes to help with unique styling of the grid menu */\n className?: string;\n};\n\nfunction MenuColumn({\n commandHandler,\n menuDefinition,\n id,\n metadata,\n onClick,\n className,\n}: MenuColumnProps) {\n return (\n \n

    \n {metadata.label}\n

    \n {/* It would seem as though this List component were unnecessary, since it only contains one\n thing, but the \"dense\" property does affect the layout of the items (in a way I don't fully\n understand). There might be a better way. */}\n \n \n \n \n );\n}\n\nexport default function GridMenu({\n commandHandler,\n className,\n multiColumnMenu,\n id,\n}: GridMenuProps) {\n const { columns } = multiColumnMenu;\n\n const sortedColumns = useMemo(() => {\n const columnNumbers = new Map();\n Object.getOwnPropertyNames(columns).forEach((columnName: string) => {\n // We know for sure there is a (boolean) property 'isExtensible' that we are not interested in.\n if (columnName === 'isExtensible') return;\n // TS doesn't allow `columnName` above to be a ReferencedItem even though the type says it is\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const columnId = columnName as ReferencedItem;\n const column = columns[columnId];\n // As of right now (and hopefully forever after), all remaining properties of the\n // ColumnsWithHeaders object are columns whose property names are the IDs of the columns.\n // This is an additional (redundant) sanity check. Specifically we're interested in\n // MenuColumnWithHeader objects, which TypeScript now \"knows\" we have, but at runtime all we\n // can check for is that it's an object with a valid numeric order field. That's likely good\n // enough.\n if (\n typeof column === 'object' &&\n typeof column.order === 'number' &&\n !Number.isNaN(column.order)\n )\n columnNumbers.set(column.order, { id: columnId, metadata: column });\n else\n console.warn(\n `Property ${columnName} (${typeof column}) on menu ${id} is not a valid column and is being ignored. This might indicate data corruption`,\n );\n });\n\n // Extract values and sort them based on the 'order' property\n return Array.from(columnNumbers.values()).sort((a, b) => {\n return (a.metadata.order || 0) - (b.metadata.order || 0);\n });\n }, [columns, id]);\n\n // We might need something like this if we need to be able to prevent empty columns\n // sortedColumns.filter((c) => multiColumnMenu.groups.some((g) => 'column' in g && (g as .column)...\n\n return (\n \n {sortedColumns.map((col, index) => (\n \n ))}\n \n );\n}\n","import { useEffect, useRef, useState } from 'react';\n\nexport type UsePromiseOptions = {\n /**\n * Whether to leave the value as the most recent resolved promise value or set it back to\n * defaultValue while running the promise again. Defaults to true\n */\n preserveValue?: boolean;\n};\n\n/** Set up defaults for options for usePromise hook */\nfunction getUsePromiseOptionsDefaults(options: UsePromiseOptions): UsePromiseOptions {\n return {\n preserveValue: true,\n ...options,\n };\n}\n\n/**\n * Awaits a promise and returns a loading value while the promise is unresolved\n *\n * @param promiseFactoryCallback A function that returns the promise to await. If this callback is\n * undefined, the current value will be returned (defaultValue unless it was previously changed\n * and `options.preserveValue` is true), and there will be no loading.\n *\n * WARNING: MUST BE STABLE - const or wrapped in useCallback. The reference must not be updated\n * every render\n * @param defaultValue The initial value to return while first awaiting the promise. If\n * `options.preserveValue` is false, this value is also shown while awaiting the promise on\n * subsequent calls.\n *\n * Note: this parameter is internally assigned to a `ref`, so changing it will not cause any hooks\n * to re-run with its new value. This means that, if the `promiseFactoryCallback` changes and\n * `options.preserveValue` is `false`, the returned value will be set to the current\n * `defaultValue`. However, the returned value will not be updated if`defaultValue` changes.\n * @param options Various options for adjusting how this hook runs the `promiseFactoryCallback`\n *\n * Note: this parameter is internally assigned to a `ref`, so changing it will not cause any hooks\n * to re-run with its new value. However, the latest `options.preserveValue` will always be used\n * appropriately to determine whether to preserve the returned value when changing the\n * `promiseFactoryCallback`\n * @returns `[value, isLoading]`\n *\n * - `value`: the current value for the promise, either the defaultValue or the resolved promise value\n * - `isLoading`: whether the promise is waiting to be resolved\n */\nconst usePromise = (\n promiseFactoryCallback: (() => Promise) | undefined,\n defaultValue: T,\n options: UsePromiseOptions = {},\n): [value: T, isLoading: boolean] => {\n // Use defaultValue as a ref so it doesn't update dependency arrays\n const defaultValueRef = useRef(defaultValue);\n defaultValueRef.current = defaultValue;\n // Use options as a ref so it doesn't update dependency arrays\n const optionsDefaultedRef = useRef(options);\n optionsDefaultedRef.current = getUsePromiseOptionsDefaults(optionsDefaultedRef.current);\n\n const [value, setValue] = useState(() => defaultValueRef.current);\n const [isLoading, setIsLoading] = useState(true);\n useEffect(() => {\n let promiseIsCurrent = true;\n // If a promiseFactoryCallback was provided, we are loading. Otherwise, there is no loading to do\n setIsLoading(!!promiseFactoryCallback);\n (async () => {\n // If there is a callback to run, run it\n if (promiseFactoryCallback) {\n const result = await promiseFactoryCallback();\n // If the promise was not already replaced, update the value\n if (promiseIsCurrent) {\n setValue(() => result);\n setIsLoading(false);\n }\n }\n })();\n\n return () => {\n // Mark this promise as old and not to be used\n promiseIsCurrent = false;\n if (!optionsDefaultedRef.current.preserveValue) setValue(() => defaultValueRef.current);\n };\n }, [promiseFactoryCallback]);\n\n return [value, isLoading];\n};\nexport default usePromise;\n","\"use client\";\n\nimport createSvgIcon from './utils/createSvgIcon';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nexport default createSvgIcon( /*#__PURE__*/_jsx(\"path\", {\n d: \"M3 18h18v-2H3zm0-5h18v-2H3zm0-7v2h18V6z\"\n}), 'Menu');","import GridMenu from '@/components/mui/grid-menu.component';\nimport { Command, CommandHandler } from '@/components/mui/menu-item.component';\nimport usePromise from '@/hooks/use-promise.hook';\nimport { Menu as MenuIcon } from '@mui/icons-material';\nimport { Drawer, IconButton } from '@mui/material';\nimport { Localized, MultiColumnMenu } from 'platform-bible-utils';\nimport {\n MouseEvent,\n MutableRefObject,\n PropsWithChildren,\n useCallback,\n useEffect,\n useState,\n} from 'react';\n\nexport interface MultiColumnMenuProvider {\n (isSupportAndDevelopment: boolean): Promise>;\n}\n\nexport type HamburgerMenuButtonProps = PropsWithChildren & {\n /** The handler to use for menu commands (and eventually toolbar commands). */\n commandHandler: CommandHandler;\n\n /**\n * Optional reference to the \"div\" container that determines the where the menu should appear. If\n * not defined, then (1,1) used.\n */\n containerRef?: MutableRefObject;\n\n /**\n * The delegate to use to get the menu data. If not specified or if it returns undefined, the data\n * in normalMenu or fullMenu property will be used.\n */\n menuProvider?: MultiColumnMenuProvider;\n\n /**\n * The menu data to show when the menu is opened if the menuProvider property is not defined.\n * (This allows for a default or test-only static menu to be used.)\n */\n normalMenu?: Localized;\n\n /**\n * The menu data to show for \"full\" menu (when opened with the SHIFT key pressed) if the\n * menuProvider property is not defined. (This allows for a default or test-only static menu to be\n * used.)\n */\n fullMenu?: Localized;\n\n /** Additional css class(es) to help with unique styling of the sub-components */\n className?: string;\n\n /** Value to use as prefix for ARIA labels on interactive sub-components */\n ariaLabelPrefix?: string;\n};\n\nexport default function HamburgerMenuButton({\n menuProvider,\n normalMenu,\n fullMenu,\n commandHandler,\n containerRef,\n className,\n ariaLabelPrefix,\n children,\n}: HamburgerMenuButtonProps) {\n const [isMenuOpen, setMenuOpen] = useState(false);\n const [showFullMenu, setShowFullMenu] = useState(false);\n\n const handleMenuItemClick = useCallback(() => {\n if (isMenuOpen) setMenuOpen(false);\n setShowFullMenu(false);\n }, [isMenuOpen]);\n\n const handleMenuButtonClick = useCallback((e: MouseEvent) => {\n e.stopPropagation();\n setMenuOpen((prevIsOpen) => {\n const isOpening = !prevIsOpen;\n if (isOpening && e.shiftKey) setShowFullMenu(true);\n else if (!isOpening) setShowFullMenu(false);\n return isOpening;\n });\n }, []);\n\n const menuCommandHandler = useCallback(\n (command: Command) => {\n handleMenuItemClick();\n return commandHandler(command);\n },\n [commandHandler, handleMenuItemClick],\n );\n\n const [offset, setOffset] = useState({ top: 1, left: 1 });\n\n useEffect(() => {\n if (isMenuOpen) {\n const node = containerRef?.current;\n if (node) {\n const rect = node.getBoundingClientRect();\n const scrollTop = window.scrollY;\n const scrollLeft = window.scrollX;\n const top = rect.top + scrollTop + node.clientHeight;\n const left = rect.left + scrollLeft;\n setOffset({ top, left });\n }\n }\n }, [isMenuOpen, containerRef]);\n\n const [normalMenuData] = usePromise(\n useCallback(async () => {\n return menuProvider?.(false) ?? normalMenu;\n // isMenuOpen needs to be included for the menu contents to reevaluate when reopened\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [menuProvider, normalMenu, isMenuOpen]),\n normalMenu,\n );\n\n const [fullMenuData] = usePromise(\n useCallback(async () => {\n return menuProvider?.(true) ?? fullMenu ?? normalMenuData;\n // isMenuOpen needs to be included for the menu contents to reevaluate when reopened\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [menuProvider, fullMenu, normalMenuData, isMenuOpen]),\n fullMenu ?? normalMenuData,\n );\n\n const menu = showFullMenu && fullMenuData ? fullMenuData : normalMenuData;\n\n return (\n <>\n \n {children ?? }\n \n \n {menu ? (\n \n ) : undefined}\n \n \n );\n}\n","import '@/components/mui/icon-button.component.css';\nimport { IconButton as MuiIconButton } from '@mui/material';\nimport { MouseEventHandler, PropsWithChildren } from 'react';\n\nexport type IconButtonProps = PropsWithChildren<{\n /** Optional unique identifier */\n id?: string;\n /**\n * Required. Used as both the tooltip (aka, title) and the aria-label (used for accessibility,\n * testing, etc.), unless a distinct tooltip is supplied.\n */\n label: string;\n /**\n * Enabled status of button\n *\n * @default false\n */\n isDisabled?: boolean;\n /** Optional tooltip to display if different from the aria-label. */\n tooltip?: string;\n /** If true, no tooltip will be displayed. */\n isTooltipSuppressed?: boolean;\n /**\n * If given, uses a negative margin to counteract the padding on one side (this is often helpful\n * for aligning the left or right side of the icon with content above or below, without ruining\n * the border size and shape).\n *\n * @default false\n */\n adjustMarginToAlignToEdge?: 'end' | 'start' | false;\n /**\n * The size of the component. small is equivalent to the dense button styling.\n *\n * @default false\n */\n size: 'small' | 'medium' | 'large';\n /** Additional css classes to help with unique styling of the button */\n className?: string;\n /** Optional click handler */\n onClick?: MouseEventHandler;\n}>;\n\n/**\n * Iconic button a user can click to do something\n *\n * Thanks to MUI for heavy inspiration and documentation\n * https://mui.com/material-ui/getting-started/overview/\n */\nfunction IconButton({\n id,\n label,\n isDisabled = false,\n tooltip,\n isTooltipSuppressed = false,\n adjustMarginToAlignToEdge = false,\n size = 'medium',\n className,\n onClick,\n children,\n}: IconButtonProps) {\n return (\n \n {children /* the icon to display */}\n \n );\n}\n\nexport default IconButton;\n","import { cn } from '@/utils/shadcn-ui.util';\nimport { LoaderCircle, LucideProps } from 'lucide-react';\nimport { forwardRef } from 'react';\n\nexport type SpinnerProps = LucideProps;\n\nconst Spinner = forwardRef(({ className, ...props }, ref) => {\n return (\n \n );\n});\n\nSpinner.displayName = 'Spinner';\n\nexport default Spinner;\n","import { Input as ShadInput } from '@/components/shadcn-ui/input';\nimport { Label as ShadLabel } from '@/components/shadcn-ui/label';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { ChangeEventHandler, FocusEventHandler } from 'react';\n\nexport type TextFieldProps = {\n /** Optional unique identifier */\n id?: string;\n /**\n * If `true`, the component is disabled.\n *\n * @default false\n */\n isDisabled?: boolean;\n /**\n * If `true`, the label is displayed in an error state.\n *\n * @default false\n */\n hasError?: boolean;\n /**\n * If `true`, the input will take up the full width of its container.\n *\n * @default false\n */\n isFullWidth?: boolean;\n /** Text that gives the user instructions on what contents the TextField expects */\n helperText?: string;\n /** The title of the TextField */\n label?: string;\n /** The short hint displayed in the `input` before the user enters a value. */\n placeholder?: string;\n /**\n * If `true`, the label is displayed as required and the `input` element is required.\n *\n * @default false\n */\n isRequired?: boolean;\n /** Additional css classes to help with unique styling of the text field */\n className?: string;\n /** Starting value for the text field if it is not controlled */\n defaultValue?: string | number;\n /** Value of the text field if controlled */\n value?: string | number;\n /** Triggers when content of textfield is changed */\n onChange?: ChangeEventHandler;\n /** Triggers when textfield gets focus */\n onFocus?: FocusEventHandler;\n /** Triggers when textfield loses focus */\n onBlur?: FocusEventHandler;\n};\n\n/**\n * Text input field\n *\n * Thanks to Shadcn for heavy inspiration and documentation\n * https://ui.shadcn.com/docs/components/input#with-label\n */\nfunction TextField({\n id,\n isDisabled = false,\n hasError = false,\n isFullWidth = false,\n helperText,\n label,\n placeholder,\n isRequired = false,\n className,\n defaultValue,\n value,\n onChange,\n onFocus,\n onBlur,\n}: TextFieldProps) {\n return (\n
    \n {`${label}${isRequired ? '*' : ''}`}\n \n

    {helperText}

    \n
    \n );\n}\n\nexport default TextField;\n","import HamburgerMenuButton, {\n MultiColumnMenuProvider,\n} from '@/components/mui/hamburger-menu-button.component';\nimport { CommandHandler } from '@/components/mui/menu-item.component';\nimport '@/components/mui/toolbar.component.css';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { AppBar, Toolbar as MuiToolbar } from '@mui/material';\nimport { PropsWithChildren, useRef } from 'react';\n\nexport type ToolbarProps = PropsWithChildren<{\n /** The handler to use for menu commands (and eventually toolbar commands). */\n commandHandler: CommandHandler;\n\n /**\n * The optional delegate to use to get the menu data. If not specified, the \"hamburger\" menu will\n * not display.\n */\n menuProvider?: MultiColumnMenuProvider;\n\n /** Optional unique identifier */\n id?: string;\n\n /** Additional css classes to help with unique styling of the toolbar */\n className?: string;\n}>;\n\nexport default function Toolbar({\n menuProvider,\n commandHandler,\n className,\n id,\n children,\n}: ToolbarProps) {\n // This ref will always be defined\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const containerRef = useRef(undefined!);\n\n return (\n
    \n \n \n {menuProvider ? (\n \n ) : undefined}\n {children ?
    {children}
    : undefined}\n \n
    \n
    \n );\n}\n","import React from 'react';\nimport { cva, type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst alertVariants = cva(\n 'tw-relative tw-w-full tw-rounded-lg tw-border tw-p-4 [&>svg~*]:tw-pl-7 [&>svg+div]:tw-translate-y-[-3px] [&>svg]:tw-absolute [&>svg]:tw-left-4 [&>svg]:tw-top-4 [&>svg]:tw-text-foreground',\n {\n variants: {\n variant: {\n default: 'tw-bg-background tw-text-foreground',\n destructive:\n 'tw-border-destructive/50 tw-text-destructive dark:tw-border-destructive [&>svg]:tw-text-destructive',\n },\n },\n defaultVariants: {\n variant: 'default',\n },\n },\n);\n\nconst Alert = React.forwardRef<\n HTMLDivElement,\n React.HTMLAttributes & VariantProps\n>(({ className, variant, ...props }, ref) => (\n
    \n));\nAlert.displayName = 'Alert';\n\nconst AlertTitle = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n {/* added because of https://github.com/jsx-eslint/eslint-plugin-jsx-a11y/blob/main/docs/rules/heading-has-content.md */}\n {props.children}{' '}\n \n ),\n);\nAlertTitle.displayName = 'AlertTitle';\n\nconst AlertDescription = React.forwardRef<\n HTMLParagraphElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n
    \n));\nAlertDescription.displayName = 'AlertDescription';\n\nexport { Alert, AlertTitle, AlertDescription };\n","import React from 'react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Card = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nCard.displayName = 'Card';\n\nconst CardHeader = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nCardHeader.displayName = 'CardHeader';\n\nconst CardTitle = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n {/* added because of https://github.com/jsx-eslint/eslint-plugin-jsx-a11y/blob/main/docs/rules/heading-has-content.md */}\n {props.children}\n \n ),\n);\nCardTitle.displayName = 'CardTitle';\n\nconst CardDescription = React.forwardRef<\n HTMLParagraphElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n

    \n));\nCardDescription.displayName = 'CardDescription';\n\nconst CardContent = React.forwardRef>(\n ({ className, ...props }, ref) => (\n

    \n ),\n);\nCardContent.displayName = 'CardContent';\n\nconst CardFooter = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nCardFooter.displayName = 'CardFooter';\n\nexport { Card, CardHeader, CardFooter, CardTitle, CardDescription, CardContent };\n","import { ComponentProps } from 'react';\nimport { toast as sonner, Toaster } from 'sonner';\n\ntype SonnerProps = ComponentProps;\n\nfunction Sonner({ ...props }: SonnerProps) {\n return (\n \n );\n}\n\n// The re-export of the sonner function was added manually\nexport { Sonner, sonner };\n","import React from 'react';\nimport * as SliderPrimitive from '@radix-ui/react-slider';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Slider = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n \n \n \n));\nSlider.displayName = SliderPrimitive.Root.displayName;\n\nexport { Slider };\n","import React from 'react';\nimport * as SwitchPrimitives from '@radix-ui/react-switch';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Switch = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n));\nSwitch.displayName = SwitchPrimitives.Root.displayName;\n\nexport { Switch };\n","import React from 'react';\nimport * as TabsPrimitive from '@radix-ui/react-tabs';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport const Tabs = TabsPrimitive.Root;\n\nexport type TabsListProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport type TabsTriggerProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport type TabsContentProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport const TabsList = React.forwardRef<\n React.ElementRef,\n TabsListProps\n>(({ className, ...props }, ref) => (\n \n));\nTabsList.displayName = TabsPrimitive.List.displayName;\n\nexport const TabsTrigger = React.forwardRef<\n React.ElementRef,\n TabsTriggerProps\n>(({ className, ...props }, ref) => (\n \n));\nTabsTrigger.displayName = TabsPrimitive.Trigger.displayName;\n\nexport const TabsContent = React.forwardRef<\n React.ElementRef,\n TabsContentProps\n>(({ className, ...props }, ref) => (\n \n));\nTabsContent.displayName = TabsPrimitive.Content.displayName;\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Download } from 'lucide-react';\n\ntype InstallButtonProps = {\n /** The installing boolean value determines the state of the button. */\n isInstalling: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n /** Optional text for the button. */\n buttonText?: string;\n} & ButtonProps;\n\n/**\n * The InstallButton component is a button designed for initiating installs. It includes visuals for\n * active installing and idle states.\n *\n * @param isInstalling The installing boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @param buttonText Optional text for the button.\n * @returns A install button.\n */\nexport default function InstallButton({\n isInstalling,\n handleClick,\n buttonText,\n className,\n ...props\n}: InstallButtonProps) {\n return (\n \n {isInstalling ? (\n \n ) : (\n <>\n \n {buttonText}\n \n )}\n \n );\n}\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\n\ntype EnableButtonProps = {\n /** The enabling boolean value determines the state of the button. */\n isEnabling: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n} & ButtonProps;\n\n/**\n * The EnableButton component is a button designed for initiating enabling of downloads. It includes\n * visuals for active enabling and idle states.\n *\n * @param isEnabling The enabling boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @returns A button that can be used to enable.\n */\nexport default function EnableButton({\n isEnabling,\n handleClick,\n className,\n ...props\n}: EnableButtonProps) {\n return (\n \n {isEnabling ? (\n <>\n \n Enabling...\n \n ) : (\n 'Enable'\n )}\n \n );\n}\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\n\ntype DisableButtonProps = {\n /** The disabling boolean value determines the state of the button. */\n isDisabling: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n} & ButtonProps;\n\n/**\n * The DisableButton component is a button designed for initiating disabling of downloads. It\n * includes visuals for active disabling and idle states.\n *\n * @param isDisabling The disabling boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @returns A button that can be used to disable.\n */\nexport default function DisableButton({\n isDisabling,\n handleClick,\n className,\n ...props\n}: DisableButtonProps) {\n return (\n \n {isDisabling ? (\n <>\n \n Disabling...\n \n ) : (\n 'Disable'\n )}\n \n );\n}\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\n\ntype UpdateButtonProps = {\n /** The updating boolean value determines the state of the button. */\n isUpdating: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n} & ButtonProps;\n\n/**\n * The UpdateButton component is a button designed for initiating updates for downloaded extensions.\n * It includes visuals for active updating and idle states.\n *\n * @param isUpdating The updating boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @returns A button that can be used to update.\n */\nexport default function UpdateButton({\n isUpdating,\n handleClick,\n className,\n ...props\n}: UpdateButtonProps) {\n return (\n \n {isUpdating ? (\n <>\n \n Updating...\n \n ) : (\n 'Update'\n )}\n \n );\n}\n","import { cn } from '@/utils/shadcn-ui.util';\nimport Markdown, { MarkdownToJSX } from 'markdown-to-jsx';\nimport { useMemo } from 'react';\n\ninterface MarkdownRendererProps {\n /** Optional unique identifier */\n id?: string;\n /** The markdown string to render */\n markdown: string;\n className?: string;\n /**\n * The [`target` attribute for `a` html\n * tags](https://developer.mozilla.org/en-US/docs/Web/HTML/Element/a#target). Defaults to not\n * adding a `target` to `a` tags\n */\n anchorTarget?: string;\n}\n\n/**\n * This component renders markdown content given a markdown string. It uses typography styles from\n * the platform.\n *\n * @param markdown The markdown string to render.\n * @param id Optional unique identifier\n * @returns A div containing the rendered markdown content.\n */\nexport default function MarkdownRenderer({\n id,\n markdown,\n className,\n anchorTarget,\n}: MarkdownRendererProps) {\n const options: MarkdownToJSX.Options = useMemo(\n () => ({\n overrides: {\n a: {\n props: {\n target: anchorTarget,\n },\n },\n },\n }),\n [anchorTarget],\n );\n return (\n
    \n {markdown}\n
    \n );\n}\n","import { Filter, ChevronDown } from 'lucide-react';\nimport { forwardRef } from 'react';\nimport { Button } from '@/components/shadcn-ui/button';\n\n/**\n * The FilterButton component is a button designed for initiating filtering of data. It is designed\n * to be used with the dropdown menu. It uses forwardRef to pass the button to the dropdown trigger\n * asChild.\n *\n * @returns A button that can be used to filter.\n */\nconst FilterButton = forwardRef((props, ref) => {\n return (\n \n \n Filter\n \n \n );\n});\n\nexport default FilterButton;\n","import {\n DropdownMenu,\n DropdownMenuTrigger,\n DropdownMenuContent,\n DropdownMenuLabel,\n DropdownMenuGroup,\n DropdownMenuCheckboxItem,\n DropdownMenuRadioItem,\n DropdownMenuSeparator,\n} from '@/components/shadcn-ui/dropdown-menu';\nimport FilterButton from './buttons/filter-button.component';\n\nexport enum DropdownMenuItemType {\n Check,\n Radio,\n}\n\nexport type DropdownItem = {\n /** The label is the text that will be displayed on the dropdown item. */\n label: string;\n /** The itemType determines the DropdownMenuItemType type as either Check or Radio. */\n itemType: DropdownMenuItemType;\n /** The onClick function is called when the item is clicked. */\n onClick: () => void;\n};\n\nexport type DropdownGroup = {\n /**\n * The label is the text that will be displayed on the dropdown group. It is used to categorize\n * the items in the group.\n */\n label: string;\n /** The items array contains the items that will be displayed in the dropdown group */\n items: DropdownItem[];\n};\n\nexport type FilterDropdownProps = {\n /** Object unique identifier */\n id?: string;\n /** The groups array contains the groups that will be displayed in the dropdown */\n groups: DropdownGroup[];\n}; // TODO: extend the props later\n\n/**\n * The FilterDropdown component is a dropdown designed for filtering content. It includes groups of\n * items that can be checkboxes or radio items.\n *\n * @param id Optional unique identifier\n * @param groups The groups array contains the groups that will be displayed in the dropdown\n * @returns A filter dropdown.\n */\nexport default function FilterDropdown({ id, groups }: FilterDropdownProps) {\n return (\n
    \n {/* TODO: remove this once the DropDown Menu shadcn has an id prop */}\n \n \n \n \n \n {groups.map((group) => (\n
    \n {group.label}\n \n {group.items.map((item) => (\n
    \n {item.itemType === DropdownMenuItemType.Check ? (\n \n {item.label}\n \n ) : (\n \n {item.label}\n \n )}\n
    \n ))}\n
    \n \n
    \n ))}\n
    \n
    \n
    \n );\n}\n","interface NoExtensionsFoundProps {\n /** Optional unique identifier */\n id?: string;\n /** The message to display */\n message: string;\n}\n/**\n * This component displays a message to the user when no extensions are found in the marketplace.\n *\n * @param id Optional unique identifier\n * @param message The message to display.\n * @returns {JSX.Element} - Returns the message component that displays the message to the user.\n */\nexport default function NoExtensionsFound({ id, message }: NoExtensionsFoundProps) {\n return (\n
    \n
    \n

    {message}

    \n
    \n
    \n );\n}\n","import { CircleHelp, Link as LucideLink, User } from 'lucide-react';\nimport { NumberFormat } from 'platform-bible-utils';\n\n/** Interface that stores the parameters passed to the More Info component */\ninterface MoreInfoProps {\n /** Optional unique identifier */\n id?: string;\n /** The category of the extension */\n category: string;\n /** The number of downloads for the extension */\n downloads: Record;\n /** The languages supported by the extension */\n languages: string[];\n /** The URL to the more info page of the extension */\n moreInfoUrl: string;\n}\n/**\n * This component displays the more info section of the extension which includes the category,\n * number of downloads, languages, and links to the website and support\n *\n * @param id Optional unique identifier\n * @param category The category of the extension\n * @param downloads The number of downloads for the extension\n * @param languages The languages supported by the extension\n * @param moreInfoUrl The URL to the more info page of the extension\n * @returns {JSX.Element} - Returns the more info component that displays the category, number of\n * downloads, languages, and links to the website and support\n */\nexport default function MoreInfo({\n id,\n category,\n downloads,\n languages,\n moreInfoUrl,\n}: MoreInfoProps) {\n /**\n * This constant formats the number of downloads into a more readable format.\n *\n * @example 1000 -> 1K\n *\n * @example 1000000 -> 1M\n *\n * @returns The formatted number of downloads\n */\n const numberFormatted = new NumberFormat('en', {\n notation: 'compact',\n compactDisplay: 'short',\n }).format(Object.values(downloads).reduce((a: number, b: number) => a + b, 0));\n\n /** This function scrolls the window to the bottom of the page. */\n const handleScrollToBottom = () => {\n window.scrollTo(0, document.body.scrollHeight);\n };\n\n return (\n \n
    \n
    \n {category}\n
    \n CATEGORY\n
    \n
    \n
    \n
    \n \n {numberFormatted}\n
    \n USERS\n
    \n
    \n
    \n
    \n {languages.slice(0, 3).map((locale) => (\n \n {locale.toUpperCase()}\n \n ))}\n
    \n {languages.length > 3 && (\n handleScrollToBottom()}\n className=\"tw-text-xs tw-text-gray-500 tw-underline\"\n >\n +{languages.length - 3} more languages\n \n )}\n
    \n
    \n
    \n \n Website\n \n \n \n Support\n \n \n
    \n
    \n );\n}\n","import { useState } from 'react';\n\nexport type VersionInformation = {\n /** Date the version was published */\n date: string;\n /** Description of the changes in the version */\n description: string;\n};\n\n/** Type to store the version history information */\nexport type VersionHistoryType = Record;\n\n/** Interface that stores the parameters passed to the Version History component */\ninterface VersionHistoryProps {\n /** Optional unique identifier */\n id?: string;\n /** Object containing the versions mapped with their information */\n versionHistory: VersionHistoryType;\n}\n\n/**\n * Component to render the version history information shown in the footer component. Lists the 5\n * most recent versions, with the options to show all versions by pressing a button.\n *\n * @param versionHistory Object containing the versions mapped with their information\n * @param id Optional unique identifier\n * @returns Rendered version history for the Footer component\n */\nexport default function VersionHistory({ id, versionHistory }: VersionHistoryProps) {\n const [showAllVersions, setShowAllVersions] = useState(false);\n const currentDate = new Date();\n\n /**\n * Function to format the time string for the version history in the form of 'X year(s) ago'.\n *\n * @param dateString ISO Date string to determine the time string from\n * @returns Formatted time string\n */\n function formatTimeString(dateString: string) {\n const date = new Date(dateString);\n const dateDiff = new Date(currentDate.getTime() - date.getTime());\n const yearDiff = dateDiff.getUTCFullYear() - 1970;\n const monthDiff = dateDiff.getUTCMonth();\n const dayDiff = dateDiff.getUTCDate() - 1;\n\n // Determines how long ago the version was published\n let timeString = '';\n if (yearDiff > 0) {\n timeString = `${yearDiff.toString()} year${yearDiff === 1 ? '' : 's'} ago`;\n } else if (monthDiff > 0) {\n timeString = `${monthDiff.toString()} month${monthDiff === 1 ? '' : 's'} ago`;\n } else if (dayDiff === 0) {\n timeString = 'today';\n } else {\n timeString = `${dayDiff.toString()} day${dayDiff === 1 ? '' : 's'} ago`;\n }\n\n return timeString;\n }\n\n // Sorts the version history by version number\n const sortedEntries = Object.entries(versionHistory).sort((a, b) => b[0].localeCompare(a[0]));\n\n return (\n
    \n

    What`s New

    \n
      \n {(showAllVersions ? sortedEntries : sortedEntries.slice(0, 5)).map((entry) => (\n
      \n
      \n
    • \n {entry[1].description}\n
    • \n
      \n
      \n
      Version {entry[0]}
      \n
      {formatTimeString(entry[1].date)}
      \n
      \n
      \n ))}\n
    \n {sortedEntries.length > 5 && (\n setShowAllVersions(!showAllVersions)}\n className=\"tw-text-xs tw-text-gray-500 tw-underline\"\n >\n {showAllVersions ? 'Show Less Version History' : 'Show All Version History'}\n \n )}\n
    \n );\n}\n","import { useMemo } from 'react';\nimport { formatBytes } from 'platform-bible-utils';\nimport VersionHistory, { VersionHistoryType } from './version-history.component';\n\n/** Interface to store the parameters passed to the Footer component */\ninterface FooterProps {\n /** Optional unique identifier */\n id?: string;\n /** Name of the publisher */\n publisherDisplayName: string;\n /** Size of the extension file in bytes */\n fileSize: number;\n /** List of language codes supported by the extension */\n locales: string[];\n /** Object containing the version history mapped with their information */\n versionHistory: VersionHistoryType;\n}\n\n/**\n * Component to render the footer for the extension details which contains information on the\n * publisher, version history, languages, and file size.\n *\n * @param id Optional unique identifier\n * @param publisherDisplayName Name of the publisher\n * @param fileSize Size of the extension file in bytes\n * @param locales List of language codes supported by the extension\n * @param versionHistory Object containing the version history mapped with their information\n * @returns The rendered Footer component\n */\nexport default function Footer({\n id,\n publisherDisplayName,\n fileSize,\n locales,\n versionHistory,\n}: FooterProps) {\n /** Formats the file size into a human-readable format */\n const formattedFileSize = useMemo(() => formatBytes(fileSize), [fileSize]);\n\n /**\n * This function gets the display names of the languages based on the language codes.\n *\n * @param codes The list of language codes\n * @returns The list of language names\n */\n const getLanguageNames = (codes: string[]) => {\n const displayNames = new Intl.DisplayNames(navigator.language, { type: 'language' });\n return codes.map((code) => displayNames.of(code));\n };\n\n const languageNames = getLanguageNames(locales);\n\n return (\n
    \n
    \n \n
    \n
    \n

    Information

    \n
    \n

    \n Publisher\n {publisherDisplayName}\n Size\n {formattedFileSize}\n

    \n
    \n

    \n Languages\n {languageNames.join(', ')}\n

    \n
    \n
    \n
    \n
    \n
    \n );\n}\n","import { PlatformEvent, PlatformEventHandler } from 'platform-bible-utils';\nimport { useEffect } from 'react';\n\n/**\n * Adds an event handler to an event so the event handler runs when the event is emitted. Use\n * `papi.network.getNetworkEvent` to use a networked event with this hook.\n *\n * @param event The event to subscribe to.\n *\n * - If event is a `PlatformEvent`, that event will be used\n * - If event is undefined, the callback will not be subscribed. Useful if the event is not yet\n * available for example\n *\n * @param eventHandler The callback to run when the event is emitted\n *\n * WARNING: MUST BE STABLE - const or wrapped in useCallback. The reference must not be updated\n * every render\n */\nconst useEvent = (\n event: PlatformEvent | undefined,\n eventHandler: PlatformEventHandler,\n) => {\n useEffect(() => {\n // Do nothing if the event is not provided (in case the event is not yet available, for example)\n if (!event) return () => {};\n\n const unsubscriber = event(eventHandler);\n return () => {\n unsubscriber();\n };\n }, [event, eventHandler]);\n};\nexport default useEvent;\n","import { useCallback, useEffect } from 'react';\nimport { PlatformEvent, PlatformEventAsync, PlatformEventHandler } from 'platform-bible-utils';\nimport usePromise from './use-promise.hook';\n\nconst noopUnsubscriber = () => false;\n\n/**\n * Adds an event handler to an asynchronously subscribing/unsubscribing event so the event handler\n * runs when the event is emitted. Use `papi.network.getNetworkEvent` to use a networked event with\n * this hook.\n *\n * @param event The asynchronously (un)subscribing event to subscribe to.\n *\n * - If event is a `PlatformEvent` or `PlatformEventAsync`, that event will be used\n * - If event is undefined, the callback will not be subscribed. Useful if the event is not yet\n * available for example\n *\n * @param eventHandler The callback to run when the event is emitted\n *\n * WARNING: MUST BE STABLE - const or wrapped in useCallback. The reference must not be updated\n * every render\n */\nconst useEventAsync = (\n event: PlatformEvent | PlatformEventAsync | undefined,\n eventHandler: PlatformEventHandler,\n) => {\n // Subscribe to the event asynchronously\n const [unsubscribe] = usePromise(\n useCallback(async () => {\n // Do nothing if the event is not provided (in case the event is not yet available, for example)\n if (!event) return noopUnsubscriber;\n\n // Wrap subscribe and unsubscribe in promises to allow normal events to be used as well\n const unsub = await Promise.resolve(event(eventHandler));\n return async () => unsub();\n }, [eventHandler, event]),\n noopUnsubscriber,\n // We want the unsubscriber to return to default value immediately upon changing subscription\n // So the useEffect below will unsubscribe asap\n { preserveValue: false },\n );\n\n // Unsubscribe from the event asynchronously (but we aren't awaiting the unsub)\n useEffect(() => {\n return () => {\n if (unsubscribe !== noopUnsubscriber) {\n unsubscribe();\n }\n };\n }, [unsubscribe]);\n};\n\nexport default useEventAsync;\n"],"names":["twMergeCustom","extendTailwindMerge","cn","inputs","clsx","Input","React","className","type","props","ref","jsx","BookChapterInput","forwardRef","handleSearch","handleKeyDown","handleOnClick","handleSubmit","jsxs","ShadInput","event","e","History","P","R","t","s","n","N","B","O","S","K","g","k","x","T","X","V","w","L","G","A","H","C","I","y","q","U","m","l","h","c","E","D","i","a","o","u","v","f","d","b","p","J","DropdownMenu","DropdownMenuPrimitive","DropdownMenuTrigger","DropdownMenuGroup","DropdownMenuPortal","DropdownMenuSub","DropdownMenuRadioGroup","DropdownMenuSubTrigger","inset","children","ChevronRight","DropdownMenuSubContent","DropdownMenuContent","sideOffset","DropdownMenuItem","DropdownMenuCheckboxItem","checked","Check","DropdownMenuRadioItem","Circle","DropdownMenuLabel","DropdownMenuSeparator","DropdownMenuShortcut","BookMenuItem","bookId","handleSelectBook","isSelected","handleHighlightBook","bookType","ShadDropdownMenuItem","Canon","ChapterSelect","handleSelectChapter","endChapter","activeChapter","highlightedChapter","handleHighlightedChapter","chapters","_","handleMouse","useCallback","chapterNumber","chapter","GoToMenuItem","handleSort","handleLocationHistory","handleBookmarks","ShadDropdownMenuLabel","ArrowDownWideNarrow","Clock","Bookmark","ALL_BOOK_IDS","BOOK_TYPE_LABELS","BOOK_TYPE_ARRAY","SCROLL_OFFSET","SEARCH_QUERY_FORMATS","fetchGroupedBooks","fetchEndChapter","getChaptersForBook","getAllEnglishNames","isValidBookEnglishName","bookName","getBookIdFromEnglishName","formattedBookName","BookChapterControl","scrRef","searchQuery","setSearchQuery","useState","selectedBookId","setSelectedBookId","setHighlightedChapter","highlightedBookId","setHighlightedBookId","isContentOpen","setIsContentOpen","isContentOpenDelayed","setIsContentOpenDelayed","inputRef","useRef","contentRef","menuItemRef","fetchFilteredBooks","englishNameLowerCase","normalizedQuery","handleSearchInput","searchString","shouldPreventAutoClosing","controlMenuState","open","updateReference","shouldClose","verse","handleInputSubmit","format","matches","book","englishName","handleKeyDownInput","handleKeyDownContent","key","handleKeyDownMenuItem","chapterOffSet","useEffect","useLayoutEffect","scrollTimeout","scrollPosition","ShadDropdownMenu","ShadDropdownMenuTrigger","ShadDropdownMenuContent","bookTypeIndex","element","ShadDropdownMenuSeparator","buttonVariants","cva","Button","variant","size","asChild","Comp","Slot","labelVariants","Label","LabelPrimitive","RadioGroup","RadioGroupPrimitive","RadioGroupItem","Popover","PopoverPrimitive","PopoverTrigger","PopoverContent","align","DialogPortal","DialogPrimitive","DialogOverlay","DialogContent","DialogTitle","DialogDescription","Command","CommandPrimitive","CommandInput","Search","CommandList","CommandEmpty","CommandGroup","CommandSeparator","CommandItem","getOptionLabelDefault","option","ComboBox","id","options","buttonClassName","popoverContentClassName","value","onChange","getOptionLabel","buttonPlaceholder","textPlaceholder","commandEmptyMessage","buttonVariant","dir","isDisabled","setOpen","ChevronsUpDown","ChapterRangeSelector","startChapter","handleSelectStartChapter","handleSelectEndChapter","chapterCount","chapterOptions","useMemo","index","onChangeStartChapter","onChangeEndChapter","Fragment","BookSelectionMode","BOOK_SELECTOR_STRING_KEYS","localizeString","strings","BookSelector","handleBookSelectionModeChange","currentBookName","onSelectBooks","selectedBookIds","localizedStrings","currentBookText","chooseText","chooseBooksText","bookSelectionMode","setBookSelectionMode","onSelectionModeChange","newMode","DataTableViewOptions","table","FilterIcon","column","Select","SelectPrimitive","SelectGroup","SelectValue","SelectTrigger","ChevronDown","SelectScrollUpButton","ChevronUp","SelectScrollDownButton","SelectContent","position","SelectLabel","SelectItem","SelectSeparator","DataTablePagination","pageSize","ArrowLeftIcon","ChevronLeftIcon","ChevronRightIcon","ArrowRightIcon","Table","stickyHeader","TableHeader","TableBody","TableFooter","TableRow","TableHead","TableCell","TableCaption","DataTable","columns","data","enablePagination","showPaginationControls","showColumnVisibilityControls","onRowClickHandler","sorting","setSorting","columnFilters","setColumnFilters","columnVisibility","setColumnVisibility","rowSelection","setRowSelection","useReactTable","getCoreRowModel","getPaginationRowModel","getSortedRowModel","getFilteredRowModel","headerGroup","header","flexRender","_a","row","cell","OccurrencesTable","occurrenceData","setScriptureReference","referenceHeaderText","occurrenceHeaderText","occurrences","uniqueOccurrences","occurrence","uniqueOccurrence","deepEqual","Checkbox","CheckboxPrimitive","getLinesFromUSFM","text","getNumberFromUSFM","regex","match","getBookNumFromId","getStatusForItem","item","approvedItems","unapprovedItems","toggleVariants","Toggle","TogglePrimitive","ToggleGroupContext","ToggleGroup","ToggleGroupPrimitive","ToggleGroupItem","context","getSortingIcon","sortDirection","ArrowUpIcon","ArrowDownIcon","ArrowUpDownIcon","inventoryItemColumn","itemLabel","inventoryAdditionalItemColumn","additionalItemLabel","additionalItemIndex","inventoryCountColumn","countLabel","statusChangeHandler","changedItems","newStatus","onApprovedItemsChange","onUnapprovedItemsChange","newApprovedItems","validItem","newUnapprovedItems","unapprovedItem","inventoryStatusColumn","statusLabel","status","CircleCheckIcon","CircleXIcon","CircleHelpIcon","INVENTORY_STRING_KEYS","filterItemData","itemData","statusFilter","textFilter","filteredItemData","createTableData","scriptureRef","itemRegex","tableData","currentBook","currentChapter","currentVerse","line","items","itemIndex","existingItem","tableEntry","newReference","substring","newItem","Inventory","scriptureReference","extractItems","additionalItemsLabels","scope","onScopeChange","allItemsText","approvedItemsText","unapprovedItemsText","unknownItemsText","scopeBookText","scopeChapterText","scopeVerseText","filterText","showAdditionalItemsText","showAdditionalItems","setShowAdditionalItems","setStatusFilter","setTextFilter","selectedItem","setSelectedItem","reducedTableData","newTableData","firstItem","existingEntry","newTableEntry","filteredTableData","allColumns","numberOfAdditionalItems","additionalColumns","_b","rowClickHandler","newSelection","handleScopeChange","handleStatusFilterChange","SearchBar","onSearch","placeholder","isFullWidth","handleInputChange","VerticalTabs","TabsPrimitive","VerticalTabsList","VerticalTabsTrigger","VerticalTabsContent","TabNavigationContentSearch","tabList","searchPlaceholder","headerTitle","isSearchBarFullWidth","direction","tab","Separator","orientation","decorative","SeparatorPrimitive","Skeleton","TooltipProvider","TooltipPrimitive","Tooltip","TooltipTrigger","TooltipContent","SIDEBAR_WIDTH","SIDEBAR_WIDTH_ICON","SIDEBAR_KEYBOARD_SHORTCUT","SidebarContext","useSidebar","SidebarProvider","defaultOpen","openProp","setOpenProp","style","_open","_setOpen","isOpen","openState","toggleSidebar","state","contextValue","Sidebar","side","collapsible","SidebarTrigger","onClick","PanelLeft","SidebarRail","SidebarInset","SidebarInput","SidebarHeader","SidebarFooter","SidebarSeparator","SidebarContent","SidebarGroup","SidebarGroupLabel","SidebarGroupAction","SidebarGroupContent","SidebarMenu","SidebarMenuItem","sidebarMenuButtonVariants","SidebarMenuButton","isActive","tooltip","button","SidebarMenuAction","showOnHover","SidebarMenuBadge","SidebarMenuSkeleton","showIcon","width","SidebarMenuSub","SidebarMenuSubItem","SidebarMenuSubButton","SettingsSidebar","extensionLabels","projectOptions","handleSelectSidebarItem","selectedSidebarItem","extensionsSidebarGroupLabel","projectsSidebarGroupLabel","buttonPlaceholderText","handleSelectItem","projectId","getProjectNameFromProjectId","project","getIsActive","label","selectedProjectName","SettingsSidebarContentSearch","scrBookColId","scrRefColId","typeColId","detailsColId","defaultScrRefColumnName","defaultScrBookGroupName","defaultTypeColumnName","defaultDetailsColumnName","getColumns","colInfo","showSourceColumn","showSrcCol","info","formatScrRef","compareScrRefs","toRefOrRange","scriptureSelection","offsetStart","offsetEnd","scrRefToBBBCCCVVV","getRowKey","ScriptureResultsViewer","sources","showColumnHeaders","scriptureReferenceColumnName","scriptureBookGroupName","typeColumnName","detailsColumnName","onRowSelected","grouping","setGrouping","scriptureResults","source","getExpandedRowModel","getGroupedRowModel","selectedRows","keys","selectedRow","scrBookGroupName","typeGroupName","groupingOptions","handleSelectChange","selectedGrouping","handleRowClick","getEvenOrOddBandingStyle","getIndent","groupingState","rowIndex","ChevronLeft","DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS","getLocalizeKeyForScrollGroupId","ScrollGroupSelector","availableScrollGroupIds","scrollGroupId","onChangeScrollGroupId","localizedStringsDefaulted","localizedStringKey","localizedStringValue","newScrollGroupString","scrollGroupOptionId","SettingsList","SettingsListItem","primary","secondary","isLoading","loadingMessage","SettingsListHeader","includeSeparator","Checklist","listItems","selectedListItems","handleSelectListItem","createLabel","_interopRequireDefault","obj","module","chainPropTypes","propType1","propType2","args","_extends","target","isPlainObject","prototype","deepClone","output","deepmerge","r","z","reactIs_production_min","hasSymbol","REACT_ELEMENT_TYPE","REACT_PORTAL_TYPE","REACT_FRAGMENT_TYPE","REACT_STRICT_MODE_TYPE","REACT_PROFILER_TYPE","REACT_PROVIDER_TYPE","REACT_CONTEXT_TYPE","REACT_ASYNC_MODE_TYPE","REACT_CONCURRENT_MODE_TYPE","REACT_FORWARD_REF_TYPE","REACT_SUSPENSE_TYPE","REACT_SUSPENSE_LIST_TYPE","REACT_MEMO_TYPE","REACT_LAZY_TYPE","REACT_BLOCK_TYPE","REACT_FUNDAMENTAL_TYPE","REACT_RESPONDER_TYPE","REACT_SCOPE_TYPE","isValidElementType","typeOf","object","$$typeof","$$typeofType","AsyncMode","ConcurrentMode","ContextConsumer","ContextProvider","Element","ForwardRef","Lazy","Memo","Portal","Profiler","StrictMode","Suspense","hasWarnedAboutDeprecatedIsAsyncMode","isAsyncMode","isConcurrentMode","isContextConsumer","isContextProvider","isElement","isForwardRef","isFragment","isLazy","isMemo","isPortal","isProfiler","isStrictMode","isSuspense","reactIs_development","reactIsModule","require$$0","require$$1","getOwnPropertySymbols","hasOwnProperty","propIsEnumerable","toObject","val","shouldUseNative","test1","test2","order2","test3","letter","objectAssign","from","to","symbols","ReactPropTypesSecret","ReactPropTypesSecret_1","has","printWarning","loggedTypeFailures","message","checkPropTypes","typeSpecs","values","location","componentName","getStack","typeSpecName","error","err","ex","stack","checkPropTypes_1","ReactIs","assign","require$$2","require$$3","require$$4","emptyFunctionThatReturnsNull","factoryWithTypeCheckers","isValidElement","throwOnDirectAccess","ITERATOR_SYMBOL","FAUX_ITERATOR_SYMBOL","getIteratorFn","maybeIterable","iteratorFn","ANONYMOUS","ReactPropTypes","createPrimitiveTypeChecker","createAnyTypeChecker","createArrayOfTypeChecker","createElementTypeChecker","createElementTypeTypeChecker","createInstanceTypeChecker","createNodeChecker","createObjectOfTypeChecker","createEnumTypeChecker","createUnionTypeChecker","createShapeTypeChecker","createStrictShapeTypeChecker","is","PropTypeError","createChainableTypeChecker","validate","manualPropTypeCallCache","manualPropTypeWarningCount","checkType","isRequired","propName","propFullName","secret","cacheKey","chainedCheckType","expectedType","propValue","propType","getPropType","preciseType","getPreciseType","typeChecker","expectedClass","expectedClassName","actualClassName","getClassName","expectedValues","valuesString","arrayOfTypeCheckers","checker","getPostfixForTypeWarning","expectedTypes","checkerResult","expectedTypesMessage","isNode","invalidValidatorError","shapeTypes","allKeys","iterator","step","entry","isSymbol","emptyFunction","emptyFunctionWithReset","factoryWithThrowingShims","shim","getShim","propTypesModule","isClassComponent","elementType","acceptingRef","safePropName","warningHint","elementAcceptingRef","PropTypes","elementAcceptingRef$1","specialProperty","exactProp","propTypes","unsupportedProps","prop","formatMuiErrorMessage","code","url","REACT_SERVER_CONTEXT_TYPE","REACT_OFFSCREEN_TYPE","enableScopeAPI","enableCacheElement","enableTransitionTracing","enableLegacyHidden","enableDebugTracing","REACT_MODULE_REFERENCE","SuspenseList","hasWarnedAboutDeprecatedIsConcurrentMode","isSuspenseList","fnNameMatchRegex","getFunctionName","fn","getFunctionComponentName","Component","fallback","getWrappedName","outerType","innerType","wrapperName","functionName","getDisplayName","HTMLElementType","refType","refType$1","capitalize","string","_formatMuiErrorMessage","createChainedFunction","funcs","acc","func","debounce","wait","timeout","debounced","later","deprecatedPropType","validator","reason","componentNameSafe","propFullNameSafe","isMuiElement","muiNames","_muiName","_element$type","ownerDocument","node","ownerWindow","requirePropFactory","componentNameInError","prevPropTypes","requiredProp","defaultTypeChecker","typeCheckerResult","setRef","useEnhancedEffect","useEnhancedEffect$1","globalId","useGlobalId","idOverride","defaultId","setDefaultId","maybeReactUseId","useId","reactId","unsupportedProp","useControlled","controlled","defaultProp","name","isControlled","valueState","setValue","defaultValue","setValueIfUncontrolled","newValue","useEventCallback","useForkRef","refs","instance","UNINITIALIZED","useLazyRef","init","initArg","EMPTY","useOnMount","Timeout","delay","useTimeout","hadKeyboardEvent","hadFocusVisibleRecently","hadFocusVisibleRecentlyTimeout","inputTypesWhitelist","focusTriggersKeyboardModality","tagName","handlePointerDown","handleVisibilityChange","prepare","doc","isFocusVisible","useIsFocusVisible","isFocusVisibleRef","handleBlurVisible","handleFocusVisible","resolveProps","defaultProps","defaultSlotProps","slotProps","slotPropName","composeClasses","slots","getUtilityClass","classes","slot","utilityClass","defaultGenerator","createClassNameGenerator","generate","generator","ClassNameGenerator","ClassNameGenerator$1","globalStateClasses","generateUtilityClass","globalStatePrefix","globalStateClass","generateUtilityClasses","result","clamp","min","max","_objectWithoutPropertiesLoose","excluded","sourceKeys","_excluded","sortBreakpointsValues","breakpointsAsArray","breakpoint1","breakpoint2","createBreakpoints","breakpoints","unit","other","sortedValues","up","down","between","start","end","endIndex","only","not","keyIndex","shape","shape$1","responsivePropType","responsivePropType$1","merge","defaultBreakpoints","handleBreakpoints","styleFromPropValue","theme","themeBreakpoints","breakpoint","mediaKey","cssKey","createEmptyBreakpointObject","breakpointsInput","_breakpointsInput$key","breakpointStyleKey","removeUnusedBreakpoints","breakpointKeys","breakpointOutput","getPath","path","checkVars","getStyleValue","themeMapping","transform","propValueFinal","userValue","cssProperty","themeKey","memoize","cache","arg","properties","directions","aliases","getCssProperties","property","marginKeys","paddingKeys","spacingKeys","createUnaryUnit","_getPath","themeSpacing","abs","createUnarySpacing","getValue","transformer","transformed","getStyleFromPropValue","cssProperties","resolveCssProperty","margin","padding","createSpacing","spacingInput","spacing","argsInput","argument","compose","styles","handlers","borderTransform","createBorderStyle","border","borderTop","borderRight","borderBottom","borderLeft","borderColor","borderTopColor","borderRightColor","borderBottomColor","borderLeftColor","outline","outlineColor","borderRadius","gap","columnGap","rowGap","gridColumn","gridRow","gridAutoFlow","gridAutoColumns","gridAutoRows","gridTemplateColumns","gridTemplateRows","gridTemplateAreas","gridArea","paletteTransform","color","bgcolor","backgroundColor","sizingTransform","maxWidth","_props$theme","_props$theme2","breakpointsValues","minWidth","height","maxHeight","minHeight","boxSizing","defaultSxConfig","defaultSxConfig$1","objectsHaveSameKeys","objects","union","callIfFn","maybeFn","unstable_createStyleFunctionSx","getThemeValue","config","styleFunctionSx","_theme$unstable_sxCon","sx","traverse","sxInput","sxObject","emptyBreakpoints","breakpointsKeys","css","styleKey","styleFunctionSx$1","applyStyles","createTheme","paletteInput","shapeInput","muiTheme","isObjectEmpty","useTheme","defaultTheme","contextTheme","ThemeContext","systemDefaultTheme","useThemeWithoutDefault","_excluded2","_excluded3","isEmpty","isStringTag","tag","shouldForwardProp","lowercaseFirstLetter","resolveTheme","themeId","defaultOverridesResolver","processStyleArg","callableStyle","_ref","ownerState","resolvedStylesArg","resolvedStyle","variants","isMatch","createStyled","input","rootShouldForwardProp","slotShouldForwardProp","systemSx","inputOptions","processStyles","componentSlot","inputSkipVariantsResolver","inputSkipSx","overridesResolver","skipVariantsResolver","skipSx","shouldForwardPropOption","defaultStyledResolver","styledEngineStyled","transformStyleArg","stylesArg","muiStyledResolver","styleArg","expressions","transformedStyleArg","expressionsWithDefaultTheme","styleOverrides","resolvedStyleOverrides","slotKey","slotStyle","_theme$components","themeVariants","numOfCustomFnsApplied","placeholders","displayName","getThemeProps","params","useThemeProps","clampWrapper","hexToRgb","re","colors","decomposeColor","marker","colorSpace","recomposeColor","hslToRgb","rgb","getLuminance","getContrastRatio","foreground","background","lumA","lumB","alpha","darken","coefficient","lighten","createMixins","mixins","common","common$1","grey","grey$1","purple","purple$1","red","red$1","orange","orange$1","blue","blue$1","lightBlue","lightBlue$1","green","green$1","light","dark","addLightOrDark","intent","shade","tonalOffset","tonalOffsetLight","tonalOffsetDark","getDefaultPrimary","mode","getDefaultSecondary","getDefaultError","getDefaultInfo","getDefaultSuccess","getDefaultWarning","createPalette","palette","contrastThreshold","success","warning","getContrastText","contrastText","contrast","augmentColor","mainShade","lightShade","darkShade","modes","round","caseAllCaps","defaultFontFamily","createTypography","typography","fontFamily","fontSize","fontWeightLight","fontWeightRegular","fontWeightMedium","fontWeightBold","htmlFontSize","allVariants","pxToRem2","coef","pxToRem","buildVariant","fontWeight","lineHeight","letterSpacing","casing","shadowKeyUmbraOpacity","shadowKeyPenumbraOpacity","shadowAmbientShadowOpacity","createShadow","px","shadows","shadows$1","easing","duration","formatMs","milliseconds","getAutoHeightDuration","constant","createTransitions","inputTransitions","mergedEasing","mergedDuration","durationOption","easingOption","isString","isNumber","animatedProp","zIndex","zIndex$1","mixinsInput","transitionsInput","typographyInput","systemTheme","systemCreateTheme","stateClasses","component","child","stateClass","defaultTheme$1","THEME_ID","systemUseThemeProps","styled","styled$1","getSvgIconUtilityClass","useUtilityClasses","SvgIconRoot","_theme$transitions","_theme$transitions$cr","_theme$transitions2","_theme$typography","_theme$typography$pxT","_theme$typography2","_theme$typography2$px","_theme$typography3","_theme$typography3$px","_palette$ownerState$c","_palette","_palette2","_palette3","SvgIcon","inProps","htmlColor","inheritViewBox","titleAccess","viewBox","hasSvgAsChild","more","_jsxs","_jsx","SvgIcon$1","createSvgIcon","unstable_ClassNameGenerator","exports","_utils","ArrowRight","default_1","_createSvgIcon","_jsxRuntime","isHostComponent","appendOwnerState","otherProps","defaultContextValue","ClassNameConfiguratorContext","useClassNamesOverride","disableDefaultClasses","extractEventHandlers","excludeKeys","resolveComponentProps","componentProps","slotState","omitEventHandlers","mergeSlotProps","parameters","getSlotProps","additionalProps","externalSlotProps","externalForwardedProps","joinedClasses","mergedStyle","eventHandlers","componentsPropsWithoutEventHandlers","otherPropsWithoutEventHandlers","internalSlotProps","useSlotProps","_parameters$additiona","skipResolvingSlotProps","rest","resolvedComponentsProps","mergedProps","internalRef","GLOBAL_CLASS_PREFIX","buildStateClass","buildSlotClass","getContainer","container","forwardedRef","disablePortal","mountNode","setMountNode","handleRef","newProps","ReactDOM","top","bottom","right","left","auto","basePlacements","clippingParents","viewport","popper","reference","variationPlacements","placement","placements","beforeRead","read","afterRead","beforeMain","main","afterMain","beforeWrite","write","afterWrite","modifierPhases","getNodeName","getWindow","OwnElement","isHTMLElement","isShadowRoot","attributes","effect","_ref2","initialStyles","styleProperties","attribute","applyStyles$1","getBasePlacement","getUAString","uaData","isLayoutViewport","getBoundingClientRect","includeScale","isFixedStrategy","clientRect","scaleX","scaleY","visualViewport","addVisualOffsets","getLayoutRect","contains","parent","rootNode","next","getComputedStyle","isTableElement","getDocumentElement","getParentNode","getTrueOffsetParent","getContainingBlock","isFirefox","isIE","elementCss","currentNode","getOffsetParent","window","offsetParent","getMainAxisFromPlacement","within","mathMax","mathMin","withinMaxClamp","getFreshSideObject","mergePaddingObject","paddingObject","expandToHashMap","hashMap","toPaddingObject","arrow","_state$modifiersData$","arrowElement","popperOffsets","basePlacement","axis","isVertical","len","arrowRect","minProp","maxProp","endDiff","startDiff","arrowOffsetParent","clientSize","centerToReference","center","offset","axisProp","_options$element","arrow$1","getVariation","unsetSides","roundOffsetsByDPR","win","dpr","mapToStyles","_Object$assign2","popperRect","variation","offsets","gpuAcceleration","adaptive","roundOffsets","isFixed","_offsets$x","_offsets$y","_ref3","hasX","hasY","sideX","sideY","heightProp","widthProp","offsetY","offsetX","commonStyles","_ref4","_Object$assign","computeStyles","_ref5","_options$gpuAccelerat","_options$adaptive","_options$roundOffsets","computeStyles$1","passive","_options$scroll","scroll","_options$resize","resize","scrollParents","scrollParent","eventListeners","hash","getOppositePlacement","matched","getOppositeVariationPlacement","getWindowScroll","scrollLeft","scrollTop","getWindowScrollBarX","getViewportRect","strategy","html","layoutViewport","getDocumentRect","_element$ownerDocumen","winScroll","body","isScrollParent","_getComputedStyle","overflow","overflowX","overflowY","getScrollParent","listScrollParents","list","isBody","updatedList","rectToClientRect","rect","getInnerBoundingClientRect","getClientRectFromMixedType","clippingParent","getClippingParents","canEscapeClipping","clipperElement","getClippingRect","boundary","rootBoundary","mainClippingParents","firstClippingParent","clippingRect","accRect","computeOffsets","commonX","commonY","mainAxis","detectOverflow","_options","_options$placement","_options$strategy","_options$boundary","_options$rootBoundary","_options$elementConte","elementContext","_options$altBoundary","altBoundary","_options$padding","altContext","clippingClientRect","referenceClientRect","popperClientRect","elementClientRect","overflowOffsets","offsetData","multiply","computeAutoPlacement","flipVariations","_options$allowedAutoP","allowedAutoPlacements","allPlacements","allowedPlacements","overflows","getExpandedFallbackPlacements","oppositePlacement","flip","_options$mainAxis","checkMainAxis","_options$altAxis","checkAltAxis","specifiedFallbackPlacements","_options$flipVariatio","preferredPlacement","isBasePlacement","fallbackPlacements","referenceRect","checksMap","makeFallbackChecks","firstFittingPlacement","_basePlacement","isStartVariation","mainVariationSide","altVariationSide","checks","check","numberOfChecks","_loop","_i","fittingPlacement","_ret","flip$1","getSideOffsets","preventedOffsets","isAnySideFullyClipped","hide","referenceOverflow","popperAltOverflow","referenceClippingOffsets","popperEscapeOffsets","isReferenceHidden","hasPopperEscaped","hide$1","distanceAndSkiddingToXY","rects","invertDistance","skidding","distance","_options$offset","_data$state$placement","offset$1","popperOffsets$1","getAltAxis","preventOverflow","_options$tether","tether","_options$tetherOffset","tetherOffset","altAxis","tetherOffsetValue","normalizedTetherOffsetValue","offsetModifierState","_offsetModifierState$","mainSide","altSide","additive","minLen","maxLen","arrowPaddingObject","arrowPaddingMin","arrowPaddingMax","arrowLen","minOffset","maxOffset","clientOffset","offsetModifierValue","tetherMin","tetherMax","preventedOffset","_offsetModifierState$2","_mainSide","_altSide","_offset","_len","_min","_max","isOriginSide","_offsetModifierValue","_tetherMin","_tetherMax","_preventedOffset","preventOverflow$1","getHTMLElementScroll","getNodeScroll","isElementScaled","getCompositeRect","elementOrVirtualElement","isOffsetParentAnElement","offsetParentIsScaled","documentElement","order","modifiers","map","visited","modifier","sort","requires","dep","depModifier","orderModifiers","orderedModifiers","phase","pending","resolve","mergeByName","merged","current","existing","DEFAULT_OPTIONS","areValidElements","_key","popperGenerator","generatorOptions","_generatorOptions","_generatorOptions$def","defaultModifiers","_generatorOptions$def2","defaultOptions","effectCleanupFns","isDestroyed","setOptionsAction","cleanupModifierEffects","runModifierEffects","_state$elements","_state$orderedModifie","_state$orderedModifie2","_ref$options","cleanupFn","noopFn","createPopper","COMPONENT_NAME","getPopperUtilityClass","flipPlacement","resolveAnchorEl","anchorEl","isVirtualElement","defaultPopperOptions","PopperTooltip","_slots$root","initialPlacement","popperOptions","popperRefProp","TransitionProps","tooltipRef","ownRef","popperRef","handlePopperRef","handlePopperRefRef","rtlPlacement","setPlacement","resolvedAnchorElement","setResolvedAnchorElement","handlePopperUpdate","box","popperModifiers","childProps","Root","rootProps","Popper","containerProp","keepMounted","transition","exited","setExited","handleEnter","handleExited","resolvedAnchorEl","display","transitionProps","useThemeSystem","_setPrototypeOf","_inheritsLoose","subClass","superClass","setPrototypeOf","timeoutsShape","TransitionGroupContext","forceReflow","UNMOUNTED","EXITED","ENTERING","ENTERED","EXITING","Transition","_React$Component","_this","parentGroup","appear","initialStatus","prevState","nextIn","_proto","prevProps","nextStatus","exit","enter","mounting","_this2","appearing","maybeNode","maybeAppearing","timeouts","enterTimeout","_this3","nextState","callback","_this4","active","handler","doesNotHaveTimeoutOrListener","maybeNextCallback","_this$props","pt","noop","Transition$1","reflow","getTransitionProps","_style$transitionDura","_style$transitionTimi","getScale","isWebKit154","Grow","addEndListener","inProp","onEnter","onEntered","onEntering","onExit","onExited","onExiting","TransitionComponent","timer","autoTimeout","nodeRef","normalizedTransitionCallback","maybeIsAppearing","handleEntering","isAppearing","transitionDuration","transitionTimingFunction","handleEntered","handleExiting","handleExit","handleAddEndListener","Grow$1","PopperRoot","BasePopper","components","componentsProps","RootComponent","Popper$1","getTooltipUtilityClass","tooltipClasses","tooltipClasses$1","disableInteractive","touch","TooltipPopper","TooltipTooltip","TooltipArrow","hystersisOpen","hystersisTimer","cursorPosition","composeEventHandler","eventHandler","_slots$popper","_slots$transition","_slots$tooltip","_slots$arrow","_slotProps$popper","_ref6","_slotProps$popper2","_slotProps$transition","_slotProps$tooltip","_ref7","_slotProps$tooltip2","_slotProps$arrow","_ref8","_slotProps$arrow2","childrenProp","describeChild","disableFocusListener","disableHoverListener","disableInteractiveProp","disableTouchListener","enterDelay","enterNextDelay","enterTouchDelay","followCursor","idProp","leaveDelay","leaveTouchDelay","onClose","onOpen","PopperComponentProp","PopperProps","title","TransitionComponentProp","isRtl","childNode","setChildNode","arrowRef","setArrowRef","ignoreNonTouchEvents","closeTimer","enterTimer","leaveTimer","touchTimer","setOpenState","prevUserSelect","stopTouchInteraction","handleOpen","handleClose","handleLeave","focusVisibleRef","setChildIsFocusVisible","handleBlur","handleFocus","detectTouchStart","childrenProps","handleMouseOver","handleMouseLeave","handleTouchStart","handleTouchEnd","nativeEvent","handleMouseMove","nameOrDescProps","titleIsString","interactiveWrapperListeners","_PopperProps$popperOp","tooltipModifiers","PopperComponent","TooltipComponent","ArrowComponent","popperProps","tooltipProps","tooltipArrowProps","TransitionPropsInner","Tooltip$1","getIcon","icon","menuLabel","leading","MuiListItemIcon","MenuItem","allowForLeadingIcons","iconPathBefore","iconPathAfter","hasAutoFocus","isDense","isSubMenuParent","hasDisabledGutters","hasDivider","focusVisibleClassName","menuItem","MuiMenuItem","MuiListItemText","getAllGroups","menuDefinition","SubMenu","setAnchorEl","parentMenuItem","parentItemProps","handleParentMenuItemClick","renderSubMenuItems","includedGroups","group","GroupedMenuItemList","Menu","getOrderedGroupItems","groupId","allItems","menuProps","commandHandler","groupsToInclude","sortedGroups","itemArray","allowSpaceForLeadingIcons","createMenuItemProps","isLastItemInGroup","divKey","itemInfo","menuItemProps","TopLevelMenu","columnId","MenuColumn","metadata","Grid","List","GridMenu","multiColumnMenu","sortedColumns","columnNumbers","columnName","col","getUsePromiseOptionsDefaults","usePromise","promiseFactoryCallback","defaultValueRef","optionsDefaultedRef","setIsLoading","promiseIsCurrent","MenuIcon","HamburgerMenuButton","menuProvider","normalMenu","fullMenu","containerRef","ariaLabelPrefix","isMenuOpen","setMenuOpen","showFullMenu","setShowFullMenu","handleMenuItemClick","handleMenuButtonClick","prevIsOpen","isOpening","menuCommandHandler","command","setOffset","normalMenuData","fullMenuData","menu","IconButton","Drawer","isTooltipSuppressed","adjustMarginToAlignToEdge","MuiIconButton","Spinner","LoaderCircle","TextField","hasError","helperText","onFocus","onBlur","ShadLabel","Toolbar","AppBar","MuiToolbar","alertVariants","Alert","AlertTitle","AlertDescription","Card","CardHeader","CardTitle","CardDescription","CardContent","CardFooter","Sonner","Toaster","Slider","SliderPrimitive","Switch","SwitchPrimitives","Tabs","TabsList","TabsTrigger","TabsContent","InstallButton","isInstalling","handleClick","buttonText","Download","EnableButton","isEnabling","DisableButton","isDisabling","UpdateButton","isUpdating","MarkdownRenderer","markdown","anchorTarget","Markdown","FilterButton","Filter","DropdownMenuItemType","DropdownMenuItemType2","FilterDropdown","groups","NoExtensionsFound","MoreInfo","category","downloads","languages","moreInfoUrl","numberFormatted","NumberFormat","handleScrollToBottom","User","locale","LucideLink","CircleHelp","VersionHistory","versionHistory","showAllVersions","setShowAllVersions","currentDate","formatTimeString","dateString","date","dateDiff","yearDiff","monthDiff","dayDiff","timeString","sortedEntries","Footer","publisherDisplayName","fileSize","locales","formattedFileSize","formatBytes","languageNames","codes","displayNames","useEvent","unsubscriber","noopUnsubscriber","useEventAsync","unsubscribe","unsub"],"mappings":"48CAGA,MAAMA,GAAgBC,GAAAA,oBAAoB,CAAE,O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MACA,MACA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MAEA,MAEA,MAEA,MAEA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,MAEA,MAEA,MAEA,MAEA,MACA,MACA,MACA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,KACF,EAAGC,GAAI,CACL,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,KACF,EAAGC,GAAI,CACL,UACA,SACA,YACA,UACA,cACA,SACA,SACA,OACA,WACA,WACA,UACA,UACA,eACA,eACA,OACA,WACA,kBACA,MACA,SACA,WACA,eACA,gBACA,SACA,WACA,eACA,UACA,kBACA,QACA,OACA,OACA,UACA,QACA,QACA,QACA,WACA,YACA,SACA,YACA,UACA,UACA,OACA,OACA,OACA,OACA,SACA,gBACA,gBACA,YACA,YACA,cACA,aACA,kBACA,kBACA,YACA,YACA,QACA,WACA,UACA,QACA,UACA,UACA,SACA,SACA,SACA,OACA,aACA,QACA,SACA,eACA,oBACA,0BACA,SACA,qBACA,sBACA,UACA,qBACA,cACA,cACA,cACA,cACA,mBACA,mBACA,qBACA,YACA,OACA,oBAGA,uBACA,uBACA,sBACA,yBACA,wBACA,qBACA,UACA,UACA,UACA,UACA,UACA,UACA,UACA,eACA,cACA,eACA,oBACA,qBACA,0BACA,0BACA,eACA,eACA,YACA,gBACA,cACA,eACA,iBACA,wBACA,mBACA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B,CACjB,SAAU,SACX,EACD,gBAAiB,CACf,SAAU,SACX,EACD,QAAS,CACP,SAAU,UACV,UAAWA,EACZ,EACD,aAAc,CACZ,SAAU,SACX,EACD,aAAc,CACZ,SAAU,qBACV,MAAOc,EACR,EAED,MAAO,CACL,SAAU,UACV,UAAWa,EACZ,EACD,QAAS,CACP,SAAU,UACV,YAAa,kBACb,UAAWA,EACZ,EACD,gBAAiB,CACf,SAAU,UACV,UAAWA,EACZ,EAED,EAAG,CACD,MAAOpC,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,QAAS,CACP,MAAOA,EACR,EACD,WAAY,CACV,MAAOA,EACR,EACD,aAAc,CACZ,MAAOA,EACR,EACD,cAAe,CACb,MAAOA,EACR,EACD,YAAa,CACX,MAAOA,EACR,EACD,SAAU,CACR,MAAOA,EACR,EACD,SAAU,CACR,MAAOA,EACR,EACD,cAAe,CACb,MAAOA,EACR,EACD,mBAAoB,CAClB,MAAOA,EACR,EACD,iBAAkB,CAChB,MAAOA,EACR,EACD,aAAc,CACZ,MAAOA,EACR,EACD,kBAAmB,CACjB,MAAOA,EACR,EACD,gBAAiB,CACf,MAAOA,EACR,EACD,EAAG,CACD,MAAOD,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,OAAQ,CACN,MAAOA,EACR,EACD,UAAW,CACT,MAAOA,EACR,EACD,YAAa,CACX,MAAOA,EACR,EACD,aAAc,CACZ,MAAOA,EACR,EACD,WAAY,CACV,MAAOA,EACR,EACD,QAAS,CACP,MAAOA,EACR,EACD,QAAS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;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","x_google_ignoreList":[3,43,44,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,83,84,85,86,87,88,89,90,91,92,93,94,95,96,97,98,99,100,101,102,103,104,105,106,107,108,109,110,111,112,113,114,115,116,117,118,119,120,121,122,123,124,125,126,127,128,129,130,131,132,133,134,135,136,137,138,139,140,141,142,143,144,145,146,147,148,149,150,151,152,153,154,155,156,157,158,159,160,161,162,163,164,165,166,167,168,169,170,171,172,173,174,175,176,177,178,179,180,181,182,183,184,185,186,187,188,189,190,191,192,193,194,195,196,197,198,199,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,226]} \ No newline at end of file diff --git a/lib/platform-bible-react/dist/index.js b/lib/platform-bible-react/dist/index.js index ee9424f7b9..82793edf02 100644 --- a/lib/platform-bible-react/dist/index.js +++ b/lib/platform-bible-react/dist/index.js @@ -1,46 +1,46 @@ -import Ks, { jsx as s, jsxs as N, Fragment as ie } from "react/jsx-runtime"; -import * as M from "react"; -import E, { forwardRef as Qn, useCallback as Et, useState as ut, useRef as ge, useEffect as ae, useLayoutEffect as ta, useMemo as It } from "react"; -import { History as Js, ChevronRight as Ja, Check as tr, Circle as Za, ArrowDownWideNarrow as Zs, Clock as Qs, Bookmark as tl, X as Qa, Search as el, ChevronsUpDown as nl, FilterIcon as rl, ChevronDown as er, ChevronUp as ol, ArrowLeftIcon as al, ChevronLeftIcon as il, ChevronRightIcon as sl, ArrowRightIcon as ll, CircleCheckIcon as cl, CircleXIcon as dl, CircleHelpIcon as pl, ArrowUpIcon as ul, ArrowDownIcon as wl, ArrowUpDownIcon as fl, PanelLeft as ml, ChevronLeft as hl, LoaderCircle as gl, Download as bl, Filter as vl, User as yl, Link as xl, CircleHelp as Nl } from "lucide-react"; -import be, { clsx as kl } from "clsx"; -import { extendTailwindMerge as El } from "tailwind-merge"; +import Xs, { jsx as s, jsxs as x, Fragment as ie } from "react/jsx-runtime"; +import * as D from "react"; +import S, { forwardRef as Qn, useCallback as kt, useState as ut, useRef as ge, useEffect as ae, useLayoutEffect as Qo, useMemo as $t } from "react"; +import { History as Ys, ChevronRight as Ka, Check as tr, Circle as Ja, ArrowDownWideNarrow as Ws, Clock as qs, Bookmark as Ks, X as Js, Search as Zs, ChevronsUpDown as Qs, FilterIcon as tl, ChevronDown as er, ChevronUp as el, ArrowLeftIcon as nl, ChevronLeftIcon as rl, ChevronRightIcon as ol, ArrowRightIcon as al, CircleCheckIcon as il, CircleXIcon as sl, CircleHelpIcon as ll, ArrowUpIcon as cl, ArrowDownIcon as dl, ArrowUpDownIcon as pl, PanelLeft as ul, ChevronLeft as wl, LoaderCircle as fl, Download as ml, Filter as hl, User as gl, Link as bl, CircleHelp as vl } from "lucide-react"; +import be, { clsx as yl } from "clsx"; +import { extendTailwindMerge as xl } from "tailwind-merge"; import * as wt from "@radix-ui/react-dropdown-menu"; -import { DropdownMenuTrigger as Sl } from "@radix-ui/react-dropdown-menu"; -import { getChaptersForBook as Tl, deepEqual as co, substring as Cl, formatScrRef as Or, compareScrRefs as Hr, scrRefToBBBCCCVVV as Rr, getLocalizeKeyForScrollGroupId as pt, NumberFormat as Ol, formatBytes as Rl } from "platform-bible-utils"; +import { DropdownMenuTrigger as Nl } from "@radix-ui/react-dropdown-menu"; +import { getChaptersForBook as kl, deepEqual as lo, substring as El, formatScrRef as Or, compareScrRefs as Gr, scrRefToBBBCCCVVV as Rr, getLocalizeKeyForScrollGroupId as pt, NumberFormat as Sl, formatBytes as Tl } from "platform-bible-utils"; import { Slot as He } from "@radix-ui/react-slot"; -import { cva as Xe } from "class-variance-authority"; -import * as ti from "@radix-ui/react-label"; -import * as mn from "@radix-ui/react-radio-group"; -import * as hn from "@radix-ui/react-popover"; -import { Command as Rt } from "cmdk"; -import * as vt from "@radix-ui/react-dialog"; -import { useReactTable as ei, getCoreRowModel as ni, getPaginationRowModel as _l, getSortedRowModel as ri, getFilteredRowModel as Pl, flexRender as dn, getExpandedRowModel as $l, getGroupedRowModel as Il } from "@tanstack/react-table"; +import { cva as kn } from "class-variance-authority"; +import * as Za from "@radix-ui/react-label"; +import * as fn from "@radix-ui/react-radio-group"; +import * as mn from "@radix-ui/react-popover"; +import { Command as Ot } from "cmdk"; +import * as Yt from "@radix-ui/react-dialog"; +import { useReactTable as Qa, getCoreRowModel as ti, getPaginationRowModel as Cl, getSortedRowModel as ei, getFilteredRowModel as Ol, flexRender as cn, getExpandedRowModel as Rl, getGroupedRowModel as _l } from "@tanstack/react-table"; import * as bt from "@radix-ui/react-select"; -import * as Xr from "@radix-ui/react-checkbox"; +import * as Hr from "@radix-ui/react-checkbox"; import * as nr from "@radix-ui/react-toggle-group"; -import * as oi from "@radix-ui/react-toggle"; -import * as _t from "@radix-ui/react-tabs"; -import * as ai from "@radix-ui/react-separator"; +import * as ni from "@radix-ui/react-toggle"; +import * as Rt from "@radix-ui/react-tabs"; +import * as ri from "@radix-ui/react-separator"; import * as En from "@radix-ui/react-tooltip"; -import Al, { ThemeContext as Ml, internal_processStyles as Dl } from "@mui/styled-engine"; -import { MenuItem as Bl, ListItemText as jl, ListItemIcon as ii, Menu as Vl, Grid as si, List as zl, IconButton as li, Drawer as Ll, AppBar as Fl, Toolbar as Ul } from "@mui/material"; -import * as Gl from "react-dom"; +import Pl, { ThemeContext as $l, internal_processStyles as Il } from "@mui/styled-engine"; +import { MenuItem as Al, ListItemText as Ml, ListItemIcon as oi, Menu as Dl, Grid as ai, List as Bl, IconButton as ii, Drawer as jl, AppBar as Vl, Toolbar as zl } from "@mui/material"; +import * as Ll from "react-dom"; import Bn from "react-dom"; -import { Toaster as Hl } from "sonner"; -import { toast as Jh } from "sonner"; -import * as an from "@radix-ui/react-slider"; -import * as Yr from "@radix-ui/react-switch"; -import Xl from "markdown-to-jsx"; -const Yl = El({ prefix: "tw-" }); -function x(...t) { - return Yl(kl(t)); -} -const Ye = E.forwardRef( +import { Toaster as Fl } from "sonner"; +import { toast as Vh } from "sonner"; +import * as on from "@radix-ui/react-slider"; +import * as Xr from "@radix-ui/react-switch"; +import Ul from "markdown-to-jsx"; +const Gl = xl({ prefix: "tw-" }); +function N(...t) { + return Gl(yl(t)); +} +const Xe = S.forwardRef( ({ className: t, type: e, ...n }, r) => /* @__PURE__ */ s( "input", { type: e, - className: x( + className: N( "pr-twp tw-flex tw-h-10 tw-rounded-md tw-border tw-border-input tw-bg-background tw-px-3 tw-py-2 tw-text-sm tw-ring-offset-background file:tw-border-0 file:tw-bg-transparent file:tw-text-sm file:tw-font-medium file:tw-text-foreground placeholder:tw-text-muted-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-cursor-not-allowed disabled:tw-opacity-50", t ), @@ -49,11 +49,11 @@ const Ye = E.forwardRef( } ) ); -Ye.displayName = "Input"; -const Wl = Qn( - ({ handleSearch: t, handleKeyDown: e, handleOnClick: n, handleSubmit: r, ...o }, a) => /* @__PURE__ */ N("div", { className: "tw-relative", children: [ +Xe.displayName = "Input"; +const Hl = Qn( + ({ handleSearch: t, handleKeyDown: e, handleOnClick: n, handleSubmit: r, ...o }, a) => /* @__PURE__ */ x("div", { className: "tw-relative", children: [ /* @__PURE__ */ s( - Ye, + Xe, { ...o, type: "text", @@ -67,7 +67,7 @@ const Wl = Qn( } ), /* @__PURE__ */ s( - Js, + Ys, { className: "tw-absolute tw-right-3 tw-top-1/2 tw-h-4 tw-w-4 tw--translate-y-1/2 tw-transform tw-cursor-pointer tw-text-muted-foreground", onClick: () => { @@ -77,7 +77,7 @@ const Wl = Qn( ) ] }) ); -var ql = Object.defineProperty, Kl = (t, e, n) => e in t ? ql(t, e, { enumerable: !0, configurable: !0, writable: !0, value: n }) : t[e] = n, et = (t, e, n) => Kl(t, typeof e != "symbol" ? e + "" : e, n); +var Xl = Object.defineProperty, Yl = (t, e, n) => e in t ? Xl(t, e, { enumerable: !0, configurable: !0, writable: !0, value: n }) : t[e] = n, et = (t, e, n) => Yl(t, typeof e != "symbol" ? e + "" : e, n); const ye = [ "GEN", "EXO", @@ -223,7 +223,7 @@ const ye = [ "REP", "4BA", "LAO" -], po = [ +], co = [ "XXA", "XXB", "XXC", @@ -239,7 +239,7 @@ const ye = [ "GLO", "TDX", "NDX" -], ci = [ +], si = [ "Genesis", "Exodus", "Leviticus", @@ -365,57 +365,57 @@ const ye = [ "Reproof (Proverbs 25-31)", "4 Baruch (Rest of Baruch)", "Laodiceans" -], ea = ic(); -function We(t, e = !0) { - return e && (t = t.toUpperCase()), t in ea ? ea[t] : 0; +], ta = rc(); +function Ye(t, e = !0) { + return e && (t = t.toUpperCase()), t in ta ? ta[t] : 0; } -function uo(t) { - return We(t) > 0; +function po(t) { + return Ye(t) > 0; } -function Jl(t) { - const e = typeof t == "string" ? We(t) : t; +function Wl(t) { + const e = typeof t == "string" ? Ye(t) : t; return e >= 40 && e <= 66; } -function Zl(t) { - return (typeof t == "string" ? We(t) : t) <= 39; +function ql(t) { + return (typeof t == "string" ? Ye(t) : t) <= 39; } -function di(t) { +function li(t) { return t <= 66; } -function Ql(t) { - const e = typeof t == "string" ? We(t) : t; - return wi(e) && !di(e); +function Kl(t) { + const e = typeof t == "string" ? Ye(t) : t; + return pi(e) && !li(e); } -function* tc() { +function* Jl() { for (let t = 1; t <= ye.length; t++) yield t; } -const ec = 1, pi = ye.length; -function nc() { +const Zl = 1, ci = ye.length; +function Ql() { return ["XXA", "XXB", "XXC", "XXD", "XXE", "XXF", "XXG"]; } -function wo(t, e = "***") { +function uo(t, e = "***") { const n = t - 1; return n < 0 || n >= ye.length ? e : ye[n]; } -function ui(t) { - return t <= 0 || t > pi ? "******" : ci[t - 1]; +function di(t) { + return t <= 0 || t > ci ? "******" : si[t - 1]; } -function rc(t) { - return ui(We(t)); +function tc(t) { + return di(Ye(t)); } -function wi(t) { - const e = typeof t == "number" ? wo(t) : t; - return uo(e) && !po.includes(e); +function pi(t) { + const e = typeof t == "number" ? uo(t) : t; + return po(e) && !co.includes(e); } -function oc(t) { - const e = typeof t == "number" ? wo(t) : t; - return uo(e) && po.includes(e); +function ec(t) { + const e = typeof t == "number" ? uo(t) : t; + return po(e) && co.includes(e); } -function ac(t) { - return ci[t - 1].includes("*obsolete*"); +function nc(t) { + return si[t - 1].includes("*obsolete*"); } -function ic() { +function rc() { const t = {}; for (let e = 0; e < ye.length; e++) t[ye[e]] = e + 1; @@ -423,31 +423,31 @@ function ic() { } const ot = { allBookIds: ye, - nonCanonicalIds: po, - bookIdToNumber: We, - isBookIdValid: uo, - isBookNT: Jl, - isBookOT: Zl, - isBookOTNT: di, - isBookDC: Ql, - allBookNumbers: tc, - firstBook: ec, - lastBook: pi, - extraBooks: nc, - bookNumberToId: wo, - bookNumberToEnglishName: ui, - bookIdToEnglishName: rc, - isCanonical: wi, - isExtraMaterial: oc, - isObsolete: ac + nonCanonicalIds: co, + bookIdToNumber: Ye, + isBookIdValid: po, + isBookNT: Wl, + isBookOT: ql, + isBookOTNT: li, + isBookDC: Kl, + allBookNumbers: Jl, + firstBook: Zl, + lastBook: ci, + extraBooks: Ql, + bookNumberToId: uo, + bookNumberToEnglishName: di, + bookIdToEnglishName: tc, + isCanonical: pi, + isExtraMaterial: ec, + isObsolete: nc }; -var Ht = /* @__PURE__ */ ((t) => (t[t.Unknown = 0] = "Unknown", t[t.Original = 1] = "Original", t[t.Septuagint = 2] = "Septuagint", t[t.Vulgate = 3] = "Vulgate", t[t.English = 4] = "English", t[t.RussianProtestant = 5] = "RussianProtestant", t[t.RussianOrthodox = 6] = "RussianOrthodox", t))(Ht || {}); -const $t = class { +var Gt = /* @__PURE__ */ ((t) => (t[t.Unknown = 0] = "Unknown", t[t.Original = 1] = "Original", t[t.Septuagint = 2] = "Septuagint", t[t.Vulgate = 3] = "Vulgate", t[t.English = 4] = "English", t[t.RussianProtestant = 5] = "RussianProtestant", t[t.RussianOrthodox = 6] = "RussianOrthodox", t))(Gt || {}); +const Pt = class { // private versInfo: Versification; constructor(e) { if (et(this, "name"), et(this, "fullPath"), et(this, "isPresent"), et(this, "hasVerseSegments"), et(this, "isCustomized"), et(this, "baseVersification"), et(this, "scriptureBooks"), et(this, "_type"), e == null) throw new Error("Argument undefined"); - typeof e == "string" ? (this.name = e, this._type = Ht[e]) : (this._type = e, this.name = Ht[e]); + typeof e == "string" ? (this.name = e, this._type = Gt[e]) : (this._type = e, this.name = Gt[e]); } get type() { return this._type; @@ -456,16 +456,16 @@ const $t = class { return !e.type || !this.type ? !1 : e.type === this.type; } }; -et($t, "Original", new $t(Ht.Original)), et($t, "Septuagint", new $t(Ht.Septuagint)), et($t, "Vulgate", new $t(Ht.Vulgate)), et($t, "English", new $t(Ht.English)), et($t, "RussianProtestant", new $t(Ht.RussianProtestant)), et($t, "RussianOrthodox", new $t(Ht.RussianOrthodox)); -let ue = $t; -function na(t, e) { +et(Pt, "Original", new Pt(Gt.Original)), et(Pt, "Septuagint", new Pt(Gt.Septuagint)), et(Pt, "Vulgate", new Pt(Gt.Vulgate)), et(Pt, "English", new Pt(Gt.English)), et(Pt, "RussianProtestant", new Pt(Gt.RussianProtestant)), et(Pt, "RussianOrthodox", new Pt(Gt.RussianOrthodox)); +let ue = Pt; +function ea(t, e) { const n = e[0]; for (let r = 1; r < e.length; r++) t = t.split(e[r]).join(n); return t.split(n); } -var fi = /* @__PURE__ */ ((t) => (t[t.Valid = 0] = "Valid", t[t.UnknownVersification = 1] = "UnknownVersification", t[t.OutOfRange = 2] = "OutOfRange", t[t.VerseOutOfOrder = 3] = "VerseOutOfOrder", t[t.VerseRepeated = 4] = "VerseRepeated", t))(fi || {}); -const Tt = class nt { +var ui = /* @__PURE__ */ ((t) => (t[t.Valid = 0] = "Valid", t[t.UnknownVersification = 1] = "UnknownVersification", t[t.OutOfRange = 2] = "OutOfRange", t[t.VerseOutOfOrder = 3] = "VerseOutOfOrder", t[t.VerseRepeated = 4] = "VerseRepeated", t))(ui || {}); +const St = class nt { constructor(e, n, r, o) { if (et(this, "firstChapter"), et(this, "lastChapter"), et(this, "lastVerse"), et(this, "hasSegmentsDefined"), et(this, "text"), et(this, "BBBCCCVVVS"), et(this, "longHashCode"), et(this, "versification"), et(this, "rtlMark", "‏"), et(this, "_bookNum", 0), et(this, "_chapterNum", 0), et(this, "_verseNum", 0), et(this, "_verse"), r == null && o == null) if (e != null && typeof e == "string") { @@ -515,7 +515,7 @@ const Tt = class nt { try { return n = new nt(e), { success: !0, verseRef: n }; } catch (r) { - if (r instanceof tn) + if (r instanceof Qe) return n = new nt(), { success: !1, verseRef: n }; throw r; } @@ -613,7 +613,7 @@ const Tt = class nt { } set bookNum(e) { if (e <= 0 || e > ot.lastBook) - throw new tn( + throw new Qe( "BookNum must be greater than zero and less than or equal to last book" ); this._bookNum = e; @@ -700,17 +700,17 @@ const Tt = class nt { if (e = a[0], a.length > 1) try { const i = +a[1].trim(); - this.versification = new ue(Ht[i]); + this.versification = new ue(Gt[i]); } catch { - throw new tn("Invalid reference : " + e); + throw new Qe("Invalid reference : " + e); } } const n = e.trim().split(" "); if (n.length !== 2) - throw new tn("Invalid reference : " + e); + throw new Qe("Invalid reference : " + e); const r = n[1].split(":"), o = +r[0]; if (r.length !== 2 || ot.bookIdToNumber(n[0]) === 0 || !Number.isInteger(o) || o < 0 || !nt.isVerseParseable(r[1])) - throw new tn("Invalid reference : " + e); + throw new Qe("Invalid reference : " + e); this.updateInternal(n[0], r[0], r[1]); } /** @@ -771,8 +771,8 @@ const Tt = class nt { allVerses(e = !1, n = nt.verseRangeSeparators, r = nt.verseSequenceIndicators) { if (this._verse == null || this.chapterNum <= 0) return [this.clone()]; - const o = [], a = na(this._verse, r); - for (const i of a.map((l) => na(l, n))) { + const o = [], a = ea(this._verse, r); + for (const i of a.map((l) => ea(l, n))) { const l = this.clone(); l.verse = i[0]; const c = l.verseNum; @@ -826,17 +826,17 @@ const Tt = class nt { this.bookNum = ot.bookIdToNumber(e), this.chapter = n, this.verse = r; } }; -et(Tt, "defaultVersification", ue.English), et(Tt, "verseRangeSeparator", "-"), et(Tt, "verseSequenceIndicator", ","), et(Tt, "verseRangeSeparators", [Tt.verseRangeSeparator]), et(Tt, "verseSequenceIndicators", [Tt.verseSequenceIndicator]), et(Tt, "chapterDigitShifter", 1e3), et(Tt, "bookDigitShifter", Tt.chapterDigitShifter * Tt.chapterDigitShifter), et(Tt, "bcvMaxValue", Tt.chapterDigitShifter - 1), /** +et(St, "defaultVersification", ue.English), et(St, "verseRangeSeparator", "-"), et(St, "verseSequenceIndicator", ","), et(St, "verseRangeSeparators", [St.verseRangeSeparator]), et(St, "verseSequenceIndicators", [St.verseSequenceIndicator]), et(St, "chapterDigitShifter", 1e3), et(St, "bookDigitShifter", St.chapterDigitShifter * St.chapterDigitShifter), et(St, "bcvMaxValue", St.chapterDigitShifter - 1), /** * The valid status of the VerseRef. */ -et(Tt, "ValidStatusType", fi); -class tn extends Error { +et(St, "ValidStatusType", ui); +class Qe extends Error { } -const fo = wt.Root, mi = wt.Trigger, sc = wt.Group, fh = wt.Portal, mh = wt.Sub, hh = wt.RadioGroup, lc = E.forwardRef(({ className: t, inset: e, children: n, ...r }, o) => /* @__PURE__ */ N( +const wo = wt.Root, wi = wt.Trigger, oc = wt.Group, nh = wt.Portal, rh = wt.Sub, oh = wt.RadioGroup, ac = S.forwardRef(({ className: t, inset: e, children: n, ...r }, o) => /* @__PURE__ */ x( wt.SubTrigger, { ref: o, - className: x( + className: N( "tw-flex tw-cursor-default tw-select-none tw-items-center tw-rounded-sm tw-px-2 tw-py-1.5 tw-text-sm tw-outline-none focus:tw-bg-accent data-[state=open]:tw-bg-accent", e && "tw-pl-8", t @@ -844,29 +844,29 @@ const fo = wt.Root, mi = wt.Trigger, sc = wt.Group, fh = wt.Portal, mh = wt.Sub, ...r, children: [ n, - /* @__PURE__ */ s(Ja, { className: "tw-ml-auto tw-h-4 tw-w-4" }) + /* @__PURE__ */ s(Ka, { className: "tw-ml-auto tw-h-4 tw-w-4" }) ] } )); -lc.displayName = wt.SubTrigger.displayName; -const cc = E.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( +ac.displayName = wt.SubTrigger.displayName; +const ic = S.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( wt.SubContent, { ref: n, - className: x( + className: N( "tw-z-50 tw-min-w-[8rem] tw-overflow-hidden tw-rounded-md tw-border tw-bg-popover tw-p-1 tw-text-popover-foreground tw-shadow-lg data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0 data-[state=closed]:tw-zoom-out-95 data-[state=open]:tw-zoom-in-95 data-[side=bottom]:tw-slide-in-from-top-2 data-[side=left]:tw-slide-in-from-right-2 data-[side=right]:tw-slide-in-from-left-2 data-[side=top]:tw-slide-in-from-bottom-2", t ), ...e } )); -cc.displayName = wt.SubContent.displayName; -const rr = E.forwardRef(({ className: t, sideOffset: e = 4, ...n }, r) => /* @__PURE__ */ s(wt.Portal, { children: /* @__PURE__ */ s( +ic.displayName = wt.SubContent.displayName; +const rr = S.forwardRef(({ className: t, sideOffset: e = 4, ...n }, r) => /* @__PURE__ */ s(wt.Portal, { children: /* @__PURE__ */ s( wt.Content, { ref: r, sideOffset: e, - className: x( + className: N( /* adding pr-twp because the dropdown content is added to the dom as a sibling to the app root */ "pr-twp tw-z-50 tw-min-w-[8rem] tw-overflow-hidden tw-rounded-md tw-border tw-bg-popover tw-p-1 tw-text-popover-foreground tw-shadow-md data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0 data-[state=closed]:tw-zoom-out-95 data-[state=open]:tw-zoom-in-95 data-[side=bottom]:tw-slide-in-from-top-2 data-[side=left]:tw-slide-in-from-right-2 data-[side=right]:tw-slide-in-from-left-2 data-[side=top]:tw-slide-in-from-bottom-2", t @@ -875,11 +875,11 @@ const rr = E.forwardRef(({ className: t, sideOffset: e = 4, ...n }, r) => /* @__ } ) })); rr.displayName = wt.Content.displayName; -const hi = E.forwardRef(({ className: t, inset: e, ...n }, r) => /* @__PURE__ */ s( +const fi = S.forwardRef(({ className: t, inset: e, ...n }, r) => /* @__PURE__ */ s( wt.Item, { ref: r, - className: x( + className: N( // removed: tw-relative tw-flex focus:tw-text-accent-foreground "tw-cursor-default tw-select-none tw-items-center tw-rounded-sm tw-px-2 tw-py-1.5 tw-text-sm tw-outline-none tw-transition-colors focus:tw-bg-accent data-[disabled]:tw-pointer-events-none data-[disabled]:tw-opacity-50", e && "tw-pl-8", @@ -888,12 +888,12 @@ const hi = E.forwardRef(({ className: t, inset: e, ...n }, r) => /* @__PURE__ */ ...n } )); -hi.displayName = wt.Item.displayName; -const mo = E.forwardRef(({ className: t, children: e, checked: n, ...r }, o) => /* @__PURE__ */ N( +fi.displayName = wt.Item.displayName; +const fo = S.forwardRef(({ className: t, children: e, checked: n, ...r }, o) => /* @__PURE__ */ x( wt.CheckboxItem, { ref: o, - className: x( + className: N( "tw-relative tw-flex tw-cursor-default tw-select-none tw-items-center tw-rounded-sm tw-py-1.5 tw-pl-8 tw-pr-2 tw-text-sm tw-outline-none tw-transition-colors focus:tw-bg-accent focus:tw-text-accent-foreground data-[disabled]:tw-pointer-events-none data-[disabled]:tw-opacity-50", t ), @@ -905,52 +905,52 @@ const mo = E.forwardRef(({ className: t, children: e, checked: n, ...r }, o) => ] } )); -mo.displayName = wt.CheckboxItem.displayName; -const gi = E.forwardRef(({ className: t, children: e, ...n }, r) => /* @__PURE__ */ N( +fo.displayName = wt.CheckboxItem.displayName; +const mi = S.forwardRef(({ className: t, children: e, ...n }, r) => /* @__PURE__ */ x( wt.RadioItem, { ref: r, - className: x( + className: N( "tw-relative tw-flex tw-cursor-default tw-select-none tw-items-center tw-rounded-sm tw-py-1.5 tw-pl-8 tw-pr-2 tw-text-sm tw-outline-none tw-transition-colors focus:tw-bg-accent focus:tw-text-accent-foreground data-[disabled]:tw-pointer-events-none data-[disabled]:tw-opacity-50", t ), ...n, children: [ - /* @__PURE__ */ s("span", { className: "tw-absolute tw-left-2 tw-flex tw-h-3.5 tw-w-3.5 tw-items-center tw-justify-center", children: /* @__PURE__ */ s(wt.ItemIndicator, { children: /* @__PURE__ */ s(Za, { className: "tw-h-2 tw-w-2 tw-fill-current" }) }) }), + /* @__PURE__ */ s("span", { className: "tw-absolute tw-left-2 tw-flex tw-h-3.5 tw-w-3.5 tw-items-center tw-justify-center", children: /* @__PURE__ */ s(wt.ItemIndicator, { children: /* @__PURE__ */ s(Ja, { className: "tw-h-2 tw-w-2 tw-fill-current" }) }) }), e ] } )); -gi.displayName = wt.RadioItem.displayName; -const Sn = E.forwardRef(({ className: t, inset: e, ...n }, r) => /* @__PURE__ */ s( +mi.displayName = wt.RadioItem.displayName; +const Sn = S.forwardRef(({ className: t, inset: e, ...n }, r) => /* @__PURE__ */ s( wt.Label, { ref: r, - className: x("tw-px-2 tw-py-1.5 tw-text-sm tw-font-semibold", e && "tw-pl-8", t), + className: N("tw-px-2 tw-py-1.5 tw-text-sm tw-font-semibold", e && "tw-pl-8", t), ...n } )); Sn.displayName = wt.Label.displayName; -const or = E.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( +const or = S.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( wt.Separator, { ref: n, - className: x("tw--mx-1 tw-my-1 tw-h-px tw-bg-muted", t), + className: N("tw--mx-1 tw-my-1 tw-h-px tw-bg-muted", t), ...e } )); or.displayName = wt.Separator.displayName; -function dc({ className: t, ...e }) { +function sc({ className: t, ...e }) { return /* @__PURE__ */ s( "span", { - className: x("tw-ml-auto tw-text-xs tw-tracking-widest tw-opacity-60", t), + className: N("tw-ml-auto tw-text-xs tw-tracking-widest tw-opacity-60", t), ...e } ); } -dc.displayName = "DropdownMenuShortcut"; -const pc = Qn( +sc.displayName = "DropdownMenuShortcut"; +const lc = Qn( ({ bookId: t, handleSelectBook: e, @@ -959,12 +959,12 @@ const pc = Qn( handleKeyDown: o, bookType: a, children: i - }, l) => /* @__PURE__ */ N( - hi, + }, l) => /* @__PURE__ */ x( + fi, { ref: l, textValue: t, - className: x("tw-mx-1 tw-px-1 tw-font-normal tw-text-foreground/80", { + className: N("tw-mx-1 tw-px-1 tw-font-normal tw-text-foreground/80", { // Overriding `data-[highlighted]` changes the default gray background that is normally shown on hover "tw-bg-amber-50 tw-text-yellow-900 data-[highlighted]:tw-bg-amber-100": n }), @@ -980,7 +980,7 @@ const pc = Qn( /* @__PURE__ */ s( "span", { - className: x( + className: N( "tw-border-b-0 tw-border-l-2 tw-border-r-0 tw-border-t-0 tw-border-solid tw-px-2", { "tw-font-bold": n, @@ -998,23 +998,23 @@ const pc = Qn( t ) ); -function uc({ +function cc({ handleSelectChapter: t, endChapter: e, activeChapter: n, highlightedChapter: r, handleHighlightedChapter: o }) { - const a = Array.from({ length: e }, (l, c) => c + 1), i = Et( + const a = Array.from({ length: e }, (l, c) => c + 1), i = kt( (l) => { o(l); }, [o] ); - return /* @__PURE__ */ s("div", { className: x("tw-flex tw-flex-wrap tw-items-start tw-justify-start tw-self-stretch"), children: a.map((l) => /* @__PURE__ */ s( + return /* @__PURE__ */ s("div", { className: N("tw-flex tw-flex-wrap tw-items-start tw-justify-start tw-self-stretch"), children: a.map((l) => /* @__PURE__ */ s( "div", { - className: x( + className: N( "tw-box-content tw-flex tw-h-4 tw-w-4 tw-cursor-pointer tw-items-center tw-justify-end tw-rounded-md tw-p-2 tw-text-amber-800", { "tw-font-semibold tw-text-amber-900": l === n, @@ -1035,26 +1035,26 @@ function uc({ l )) }); } -function wc({ handleSort: t, handleLocationHistory: e, handleBookmarks: n }) { - return /* @__PURE__ */ N(Sn, { className: "tw-flex tw-justify-between", children: [ +function dc({ handleSort: t, handleLocationHistory: e, handleBookmarks: n }) { + return /* @__PURE__ */ x(Sn, { className: "tw-flex tw-justify-between", children: [ /* @__PURE__ */ s("p", { className: "tw-inline-block tw-align-middle", children: "Go To" }), - /* @__PURE__ */ N("div", { className: "tw-flex tw-items-center", children: [ + /* @__PURE__ */ x("div", { className: "tw-flex tw-items-center", children: [ /* @__PURE__ */ s( - Zs, + Ws, { onClick: t, className: "tw-m-2 tw-h-4 tw-w-4 tw-cursor-pointer tw-gap-2" } ), /* @__PURE__ */ s( - Qs, + qs, { onClick: e, className: "tw-m-2 tw-h-4 tw-w-4 tw-cursor-pointer tw-gap-2" } ), /* @__PURE__ */ s( - tl, + Ks, { onClick: n, className: "tw-m-2 tw-h-4 tw-w-4 tw-cursor-pointer tw-gap-2" @@ -1063,61 +1063,61 @@ function wc({ handleSort: t, handleLocationHistory: e, handleBookmarks: n }) { ] }) ] }); } -const pn = ot.allBookIds, fc = { +const dn = ot.allBookIds, pc = { OT: "Old Testament", NT: "New Testament", DC: "Deuterocanon" -}, ra = ["OT", "NT", "DC"], mc = 32 + 32 + 32, hc = [ +}, na = ["OT", "NT", "DC"], uc = 32 + 32 + 32, wc = [ /^(\w+)$/i, // Matches a single word (book name or id) /^(\w+)(?:\s(\d+))$/i, // Matches a word followed by a chapter number /^(\w+)(?:\s(\d+):(\d+))$/i // Matches a word followed by a chapter and verse number -], gc = (t) => ({ - OT: pn.filter((n) => ot.isBookOT(n)), - NT: pn.filter((n) => ot.isBookNT(n)), - DC: pn.filter((n) => ot.isBookDC(n)) -})[t], en = (t) => Tl(ot.bookIdToNumber(t)); -function bc() { - return pn.map((e) => ot.bookIdToEnglishName(e)); -} -function vc(t) { - return bc().includes(t); -} -function yc(t) { +], fc = (t) => ({ + OT: dn.filter((n) => ot.isBookOT(n)), + NT: dn.filter((n) => ot.isBookNT(n)), + DC: dn.filter((n) => ot.isBookDC(n)) +})[t], tn = (t) => kl(ot.bookIdToNumber(t)); +function mc() { + return dn.map((e) => ot.bookIdToEnglishName(e)); +} +function hc(t) { + return mc().includes(t); +} +function gc(t) { const e = t.toLowerCase().replace(/^\w/, (n) => n.toUpperCase()); - if (vc(e)) - return pn.find((r) => ot.bookIdToEnglishName(r) === e); + if (hc(e)) + return dn.find((r) => ot.bookIdToEnglishName(r) === e); } -function gh({ scrRef: t, handleSubmit: e }) { +function ah({ scrRef: t, handleSubmit: e }) { const [n, r] = ut(""), [o, a] = ut( ot.bookNumberToId(t.bookNum) ), [i, l] = ut(t.chapterNum ?? 0), [c, d] = ut( ot.bookNumberToId(t.bookNum) - ), [p, f] = ut(!1), [w, g] = ut(p), v = ge(void 0), m = ge(void 0), h = ge(void 0), S = Et( - (k) => gc(k).filter((B) => { - const D = ot.bookIdToEnglishName(B).toLowerCase(), J = n.replace(/[^a-zA-Z]/g, "").toLowerCase(); - return D.includes(J) || // Match book name + ), [p, f] = ut(!1), [w, g] = ut(p), v = ge(void 0), m = ge(void 0), h = ge(void 0), T = kt( + (k) => fc(k).filter((B) => { + const M = ot.bookIdToEnglishName(B).toLowerCase(), J = n.replace(/[^a-zA-Z]/g, "").toLowerCase(); + return M.includes(J) || // Match book name B.toLowerCase().includes(J); }), [n] - ), _ = (k) => { + ), A = (k) => { r(k); - }, C = ge(!1), T = Et((k) => { - if (C.current) { - C.current = !1; + }, R = ge(!1), E = kt((k) => { + if (R.current) { + R.current = !1; return; } f(k); - }, []), b = Et( - (k, B, D, J) => { + }, []), b = kt( + (k, B, M, J) => { if (l( ot.bookNumberToId(t.bookNum) !== k ? 1 : t.chapterNum - ), B || en(k) === -1) { + ), B || tn(k) === -1) { e({ bookNum: ot.bookIdToNumber(k), - chapterNum: D || 1, + chapterNum: M || 1, verseNum: J || 1 }), f(!1), r(""); return; @@ -1125,22 +1125,22 @@ function gh({ scrRef: t, handleSubmit: e }) { a(o !== k ? k : ""), f(!B); }, [e, t.bookNum, t.chapterNum, o] - ), I = (k) => { - k <= 0 || k > en(o) || b(o, !0, k); - }, z = Et(() => { - hc.forEach((k) => { + ), $ = (k) => { + k <= 0 || k > tn(o) || b(o, !0, k); + }, z = kt(() => { + wc.forEach((k) => { const B = n.match(k); if (B) { - const [D, J = void 0, q = void 0] = B.slice(1), U = yc(D); - (ot.isBookIdValid(D) || U) && b( - U ?? D, + const [M, J = void 0, q = void 0] = B.slice(1), U = gc(M); + (ot.isBookIdValid(M) || U) && b( + U ?? M, !0, J ? parseInt(J, 10) : 1, q ? parseInt(q, 10) : 1 ); } }); - }, [b, n]), H = Et( + }, [b, n]), H = kt( (k) => { p ? (k.key === "ArrowDown" || k.key === "ArrowUp") && (typeof h < "u" && // Ref uses null // eslint-disable-next-line no-null/no-null @@ -1149,106 +1149,106 @@ function gh({ scrRef: t, handleSubmit: e }) { m.current !== null && m.current.focus(), k.preventDefault()) : f(!0); }, [p] - ), O = (k) => { + ), C = (k) => { const { key: B } = k; B === "ArrowRight" || B === "ArrowLeft" || B === "ArrowDown" || B === "ArrowUp" || B === "Enter" || (v.current.dispatchEvent(new KeyboardEvent("keydown", { key: B })), v.current.focus()); - }, $ = (k) => { + }, P = (k) => { const { key: B } = k; if (c === o) { if (B === "Enter") { k.preventDefault(), b(o, !0, i); return; } - let D = 0; + let M = 0; if (B === "ArrowRight") - if (i < en(c)) - D = 1; + if (i < tn(c)) + M = 1; else { k.preventDefault(); return; } else if (B === "ArrowLeft") if (i > 1) - D = -1; + M = -1; else { k.preventDefault(); return; } else - B === "ArrowDown" ? D = 6 : B === "ArrowUp" && (D = -6); - i + D <= 0 || i + D > en(c) ? l(0) : D !== 0 && (l(i + D), k.preventDefault()); + B === "ArrowDown" ? M = 6 : B === "ArrowUp" && (M = -6); + i + M <= 0 || i + M > tn(c) ? l(0) : M !== 0 && (l(i + M), k.preventDefault()); } }; return ae(() => { o === c ? o === ot.bookNumberToId(t.bookNum) ? l(t.chapterNum) : l(1) : l(0); - }, [c, t.bookNum, t.chapterNum, o]), ta(() => { + }, [c, t.bookNum, t.chapterNum, o]), Qo(() => { g(p); - }, [p]), ta(() => { + }, [p]), Qo(() => { const k = setTimeout(() => { if (w && m.current && h.current) { - const D = h.current.offsetTop - mc; - m.current.scrollTo({ top: D, behavior: "instant" }); + const M = h.current.offsetTop - uc; + m.current.scrollTo({ top: M, behavior: "instant" }); } }, 10); return () => { clearTimeout(k); }; - }, [w]), /* @__PURE__ */ s("div", { className: "pr-twp tw-flex", children: /* @__PURE__ */ N(fo, { modal: !1, open: p, onOpenChange: T, children: [ - /* @__PURE__ */ s(mi, { asChild: !0, children: /* @__PURE__ */ s( - Wl, + }, [w]), /* @__PURE__ */ s("div", { className: "pr-twp tw-flex", children: /* @__PURE__ */ x(wo, { modal: !1, open: p, onOpenChange: E, children: [ + /* @__PURE__ */ s(wi, { asChild: !0, children: /* @__PURE__ */ s( + Hl, { ref: v, value: n, - handleSearch: _, + handleSearch: A, handleKeyDown: H, handleOnClick: () => { a(ot.bookNumberToId(t.bookNum)), d(ot.bookNumberToId(t.bookNum)), l(t.chapterNum > 0 ? t.chapterNum : 0), f(!0), v.current.focus(); }, onFocus: () => { - C.current = !0; + R.current = !0; }, handleSubmit: z, placeholder: `${ot.bookNumberToEnglishName(t.bookNum)} ${t.chapterNum}:${t.verseNum}` } ) }), - /* @__PURE__ */ N( + /* @__PURE__ */ x( rr, { className: "tw-m-1 tw-overflow-y-auto tw-p-0 tw-font-normal tw-text-foreground/80", style: { width: "233px", maxHeight: "500px", zIndex: "250" }, - onKeyDown: O, + onKeyDown: C, align: "start", ref: m, children: [ /* @__PURE__ */ s( - wc, + dc, { handleSort: () => console.log("sorting"), handleLocationHistory: () => console.log("location history"), handleBookmarks: () => console.log("bookmarks") } ), - ra.map( - (k, B) => S(k).length > 0 && /* @__PURE__ */ N("div", { children: [ - /* @__PURE__ */ s(Sn, { className: "tw-font-semibold tw-text-foreground/80", children: fc[k] }), - S(k).map((D) => /* @__PURE__ */ s("div", { children: /* @__PURE__ */ s( - pc, + na.map( + (k, B) => T(k).length > 0 && /* @__PURE__ */ x("div", { children: [ + /* @__PURE__ */ s(Sn, { className: "tw-font-semibold tw-text-foreground/80", children: pc[k] }), + T(k).map((M) => /* @__PURE__ */ s("div", { children: /* @__PURE__ */ s( + lc, { - bookId: D, - handleSelectBook: () => b(D, !1), - isSelected: o === D, - handleHighlightBook: () => d(D), - handleKeyDown: $, + bookId: M, + handleSelectBook: () => b(M, !1), + isSelected: o === M, + handleHighlightBook: () => d(M), + handleKeyDown: P, bookType: k, ref: (J) => { - o === D && (h.current = J); + o === M && (h.current = J); }, children: /* @__PURE__ */ s( - uc, + cc, { - handleSelectChapter: I, - endChapter: en(D), - activeChapter: t.bookNum === ot.bookIdToNumber(D) ? t.chapterNum : 0, + handleSelectChapter: $, + endChapter: tn(M), + activeChapter: t.bookNum === ot.bookIdToNumber(M) ? t.chapterNum : 0, highlightedChapter: i, handleHighlightedChapter: (J) => { l(J); @@ -1256,8 +1256,8 @@ function gh({ scrRef: t, handleSubmit: e }) { } ) } - ) }, D)), - ra.length - 1 !== B ? /* @__PURE__ */ s(or, {}) : void 0 + ) }, M)), + na.length - 1 !== B ? /* @__PURE__ */ s(or, {}) : void 0 ] }, k) ) ] @@ -1265,7 +1265,7 @@ function gh({ scrRef: t, handleSubmit: e }) { ) ] }) }); } -const xc = Xe( +const bc = kn( "pr-twp tw-inline-flex tw-items-center tw-justify-center tw-whitespace-nowrap tw-rounded-md tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-colors focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50", { variants: { @@ -1289,121 +1289,121 @@ const xc = Xe( size: "default" } } -), gt = E.forwardRef( - ({ className: t, variant: e, size: n, asChild: r = !1, ...o }, a) => /* @__PURE__ */ s(r ? He : "button", { className: x(xc({ variant: e, size: n, className: t })), ref: a, ...o }) +), gt = S.forwardRef( + ({ className: t, variant: e, size: n, asChild: r = !1, ...o }, a) => /* @__PURE__ */ s(r ? He : "button", { className: N(bc({ variant: e, size: n, className: t })), ref: a, ...o }) ); gt.displayName = "Button"; -const Nc = Xe( +const vc = kn( "tw-text-sm tw-font-medium tw-leading-none peer-disabled:tw-cursor-not-allowed peer-disabled:tw-opacity-70" -), Xt = E.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s(ti.Root, { ref: n, className: x("pr-twp", Nc(), t), ...e })); -Xt.displayName = ti.Root.displayName; -const bi = E.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( - mn.Root, +), Ht = S.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s(Za.Root, { ref: n, className: N("pr-twp", vc(), t), ...e })); +Ht.displayName = Za.Root.displayName; +const hi = S.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( + fn.Root, { - className: x("pr-twp tw-grid tw-gap-2", t), + className: N("pr-twp tw-grid tw-gap-2", t), ...e, ref: n } )); -bi.displayName = mn.Root.displayName; -const Wr = E.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( - mn.Item, +hi.displayName = fn.Root.displayName; +const Yr = S.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( + fn.Item, { ref: n, - className: x( + className: N( "pr-twp tw-aspect-square tw-h-4 tw-w-4 tw-rounded-full tw-border tw-border-primary tw-text-primary tw-ring-offset-background focus:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-cursor-not-allowed disabled:tw-opacity-50", t ), ...e, - children: /* @__PURE__ */ s(mn.Indicator, { className: "tw-flex tw-items-center tw-justify-center", children: /* @__PURE__ */ s(Za, { className: "tw-h-2.5 tw-w-2.5 tw-fill-current tw-text-current" }) }) + children: /* @__PURE__ */ s(fn.Indicator, { className: "tw-flex tw-items-center tw-justify-center", children: /* @__PURE__ */ s(Ja, { className: "tw-h-2.5 tw-w-2.5 tw-fill-current tw-text-current" }) }) } )); -Wr.displayName = mn.Item.displayName; -const kc = hn.Root, Ec = hn.Trigger, vi = E.forwardRef(({ className: t, align: e = "center", sideOffset: n = 4, ...r }, o) => /* @__PURE__ */ s(hn.Portal, { children: /* @__PURE__ */ s( - hn.Content, +Yr.displayName = fn.Item.displayName; +const yc = mn.Root, xc = mn.Trigger, gi = S.forwardRef(({ className: t, align: e = "center", sideOffset: n = 4, ...r }, o) => /* @__PURE__ */ s(mn.Portal, { children: /* @__PURE__ */ s( + mn.Content, { ref: o, align: e, sideOffset: n, - className: x( + className: N( "pr-twp tw-z-50 tw-w-72 tw-rounded-md tw-border tw-bg-popover tw-p-4 tw-text-popover-foreground tw-shadow-md tw-outline-none data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0 data-[state=closed]:tw-zoom-out-95 data-[state=open]:tw-zoom-in-95 data-[side=bottom]:tw-slide-in-from-top-2 data-[side=left]:tw-slide-in-from-right-2 data-[side=right]:tw-slide-in-from-left-2 data-[side=top]:tw-slide-in-from-bottom-2", t ), ...r } ) })); -vi.displayName = hn.Content.displayName; -const Sc = vt.Portal, yi = E.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( - vt.Overlay, +gi.displayName = mn.Content.displayName; +const Nc = Yt.Portal, bi = S.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( + Yt.Overlay, { ref: n, - className: x( + className: N( "tw-fixed tw-inset-0 tw-z-50 tw-bg-black/80 data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0", t ), ...e } )); -yi.displayName = vt.Overlay.displayName; -const Tc = E.forwardRef(({ className: t, children: e, ...n }, r) => /* @__PURE__ */ N(Sc, { children: [ - /* @__PURE__ */ s(yi, {}), - /* @__PURE__ */ N( - vt.Content, +bi.displayName = Yt.Overlay.displayName; +const kc = S.forwardRef(({ className: t, children: e, ...n }, r) => /* @__PURE__ */ x(Nc, { children: [ + /* @__PURE__ */ s(bi, {}), + /* @__PURE__ */ x( + Yt.Content, { ref: r, - className: x( + className: N( "tw-fixed tw-left-[50%] tw-top-[50%] tw-z-50 tw-grid tw-w-full tw-max-w-lg tw-translate-x-[-50%] tw-translate-y-[-50%] tw-gap-4 tw-border tw-bg-background tw-p-6 tw-shadow-lg tw-duration-200 data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0 data-[state=closed]:tw-zoom-out-95 data-[state=open]:tw-zoom-in-95 data-[state=closed]:tw-slide-out-to-left-1/2 data-[state=closed]:tw-slide-out-to-top-[48%] data-[state=open]:tw-slide-in-from-left-1/2 data-[state=open]:tw-slide-in-from-top-[48%] sm:tw-rounded-lg", t ), ...n, children: [ e, - /* @__PURE__ */ N(vt.Close, { className: "tw-absolute tw-right-4 tw-top-4 tw-rounded-sm tw-opacity-70 tw-ring-offset-background tw-transition-opacity hover:tw-opacity-100 focus:tw-outline-none focus:tw-ring-2 focus:tw-ring-ring focus:tw-ring-offset-2 disabled:tw-pointer-events-none data-[state=open]:tw-bg-accent data-[state=open]:tw-text-muted-foreground", children: [ - /* @__PURE__ */ s(Qa, { className: "tw-h-4 tw-w-4" }), + /* @__PURE__ */ x(Yt.Close, { className: "tw-absolute tw-right-4 tw-top-4 tw-rounded-sm tw-opacity-70 tw-ring-offset-background tw-transition-opacity hover:tw-opacity-100 focus:tw-outline-none focus:tw-ring-2 focus:tw-ring-ring focus:tw-ring-offset-2 disabled:tw-pointer-events-none data-[state=open]:tw-bg-accent data-[state=open]:tw-text-muted-foreground", children: [ + /* @__PURE__ */ s(Js, { className: "tw-h-4 tw-w-4" }), /* @__PURE__ */ s("span", { className: "tw-sr-only", children: "Close" }) ] }) ] } ) ] })); -Tc.displayName = vt.Content.displayName; -const Cc = E.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( - vt.Title, +kc.displayName = Yt.Content.displayName; +const Ec = S.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( + Yt.Title, { ref: n, - className: x("tw-text-lg tw-font-semibold tw-leading-none tw-tracking-tight", t), + className: N("tw-text-lg tw-font-semibold tw-leading-none tw-tracking-tight", t), ...e } )); -Cc.displayName = vt.Title.displayName; -const Oc = E.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( - vt.Description, +Ec.displayName = Yt.Title.displayName; +const Sc = S.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( + Yt.Description, { ref: n, - className: x("tw-text-sm tw-text-muted-foreground", t), + className: N("tw-text-sm tw-text-muted-foreground", t), ...e } )); -Oc.displayName = vt.Description.displayName; -const xi = E.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( - Rt, +Sc.displayName = Yt.Description.displayName; +const vi = S.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( + Ot, { ref: n, - className: x( + className: N( "tw-flex tw-h-full tw-w-full tw-flex-col tw-overflow-hidden tw-rounded-md tw-bg-popover tw-text-popover-foreground", t ), ...e } )); -xi.displayName = Rt.displayName; -const Ni = E.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ N("div", { className: "tw-flex tw-items-center tw-border-b tw-px-3", children: [ - /* @__PURE__ */ s(el, { className: "tw-me-2 tw-h-4 tw-w-4 tw-shrink-0 tw-opacity-50" }), +vi.displayName = Ot.displayName; +const yi = S.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ x("div", { className: "tw-flex tw-items-center tw-border-b tw-px-3", children: [ + /* @__PURE__ */ s(Zs, { className: "tw-me-2 tw-h-4 tw-w-4 tw-shrink-0 tw-opacity-50" }), /* @__PURE__ */ s( - Rt.Input, + Ot.Input, { ref: n, - className: x( + className: N( "tw-flex tw-h-11 tw-w-full tw-rounded-md tw-bg-transparent tw-py-3 tw-text-sm tw-outline-none placeholder:tw-text-muted-foreground disabled:tw-cursor-not-allowed disabled:tw-opacity-50", t ), @@ -1411,55 +1411,55 @@ const Ni = E.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ N("div", } ) ] })); -Ni.displayName = Rt.Input.displayName; -const ki = E.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( - Rt.List, +yi.displayName = Ot.Input.displayName; +const xi = S.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( + Ot.List, { ref: n, - className: x("tw-max-h-[300px] tw-overflow-y-auto tw-overflow-x-hidden", t), + className: N("tw-max-h-[300px] tw-overflow-y-auto tw-overflow-x-hidden", t), ...e } )); -ki.displayName = Rt.List.displayName; -const Ei = E.forwardRef((t, e) => /* @__PURE__ */ s(Rt.Empty, { ref: e, className: "tw-py-6 tw-text-center tw-text-sm", ...t })); -Ei.displayName = Rt.Empty.displayName; -const Rc = E.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( - Rt.Group, +xi.displayName = Ot.List.displayName; +const Ni = S.forwardRef((t, e) => /* @__PURE__ */ s(Ot.Empty, { ref: e, className: "tw-py-6 tw-text-center tw-text-sm", ...t })); +Ni.displayName = Ot.Empty.displayName; +const Tc = S.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( + Ot.Group, { ref: n, - className: x( + className: N( "tw-overflow-hidden tw-p-1 tw-text-foreground [&_[cmdk-group-heading]]:tw-px-2 [&_[cmdk-group-heading]]:tw-py-1.5 [&_[cmdk-group-heading]]:tw-text-xs [&_[cmdk-group-heading]]:tw-font-medium [&_[cmdk-group-heading]]:tw-text-muted-foreground", t ), ...e } )); -Rc.displayName = Rt.Group.displayName; -const _c = E.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( - Rt.Separator, +Tc.displayName = Ot.Group.displayName; +const Cc = S.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( + Ot.Separator, { ref: n, - className: x("tw--mx-1 tw-h-px tw-bg-border", t), + className: N("tw--mx-1 tw-h-px tw-bg-border", t), ...e } )); -_c.displayName = Rt.Separator.displayName; -const Si = E.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( - Rt.Item, +Cc.displayName = Ot.Separator.displayName; +const ki = S.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( + Ot.Item, { ref: n, - className: x( + className: N( "tw-relative tw-flex tw-cursor-default tw-select-none tw-items-center tw-rounded-sm tw-px-2 tw-py-1.5 tw-text-sm tw-outline-none data-[disabled=true]:tw-pointer-events-none data-[selected=true]:tw-bg-accent data-[selected=true]:tw-text-accent-foreground data-[disabled=true]:tw-opacity-50", t ), ...e } )); -Si.displayName = Rt.Item.displayName; -function Pc(t) { +ki.displayName = Ot.Item.displayName; +function Oc(t) { return typeof t == "string" ? t : typeof t == "number" ? t.toString() : t.label; } -function qr({ +function Wr({ id: t, options: e = [], buttonClassName: n, @@ -1467,7 +1467,7 @@ function qr({ value: o, onChange: a = () => { }, - getOptionLabel: i = Pc, + getOptionLabel: i = Oc, buttonPlaceholder: l = "", textPlaceholder: c = "", commandEmptyMessage: d = "No option found", @@ -1477,27 +1477,27 @@ function qr({ ...g }) { const [v, m] = ut(!1); - return /* @__PURE__ */ N(kc, { open: v, onOpenChange: m, ...g, children: [ - /* @__PURE__ */ s(Ec, { asChild: !0, children: /* @__PURE__ */ N( + return /* @__PURE__ */ x(yc, { open: v, onOpenChange: m, ...g, children: [ + /* @__PURE__ */ s(xc, { asChild: !0, children: /* @__PURE__ */ x( gt, { variant: p, role: "combobox", "aria-expanded": v, id: t, - className: x("tw-w-[200px] tw-justify-between", n), + className: N("tw-w-[200px] tw-justify-between", n), disabled: w, children: [ /* @__PURE__ */ s("span", { className: "tw-overflow-hidden tw-text-ellipsis tw-whitespace-nowrap", children: o ? i(o) : l }), - /* @__PURE__ */ s(nl, { className: "tw-ms-2 tw-h-4 tw-w-4 tw-shrink-0 tw-opacity-50" }) + /* @__PURE__ */ s(Qs, { className: "tw-ms-2 tw-h-4 tw-w-4 tw-shrink-0 tw-opacity-50" }) ] } ) }), - /* @__PURE__ */ s(vi, { className: x("tw-w-[200px] tw-p-0", r), dir: f, children: /* @__PURE__ */ N(xi, { children: [ - /* @__PURE__ */ s(Ni, { dir: f, placeholder: c, className: "tw-text-inherit" }), - /* @__PURE__ */ s(Ei, { children: d }), - /* @__PURE__ */ s(ki, { children: e.map((h) => /* @__PURE__ */ N( - Si, + /* @__PURE__ */ s(gi, { className: N("tw-w-[200px] tw-p-0", r), dir: f, children: /* @__PURE__ */ x(vi, { children: [ + /* @__PURE__ */ s(yi, { dir: f, placeholder: c, className: "tw-text-inherit" }), + /* @__PURE__ */ s(Ni, { children: d }), + /* @__PURE__ */ s(xi, { children: e.map((h) => /* @__PURE__ */ x( + ki, { value: i(h), onSelect: () => { @@ -1507,7 +1507,7 @@ function qr({ /* @__PURE__ */ s( tr, { - className: x("tw-me-2 tw-h-4 tw-w-4", { + className: N("tw-me-2 tw-h-4 tw-w-4", { "tw-opacity-0": !o || i(o) !== i(h) }) } @@ -1520,7 +1520,7 @@ function qr({ ] }) }) ] }); } -function $c({ +function Rc({ startChapter: t, endChapter: e, handleSelectStartChapter: n, @@ -1528,14 +1528,14 @@ function $c({ isDisabled: o = !1, chapterCount: a }) { - const i = It( + const i = $t( () => Array.from({ length: a }, (d, p) => p + 1), [a] ); - return /* @__PURE__ */ N(ie, { children: [ - /* @__PURE__ */ s(Xt, { htmlFor: "start-chapters-combobox", children: "Chapters" }), + return /* @__PURE__ */ x(ie, { children: [ + /* @__PURE__ */ s(Ht, { htmlFor: "start-chapters-combobox", children: "Chapters" }), /* @__PURE__ */ s( - qr, + Wr, { isDisabled: o, onChange: (d) => { @@ -1548,9 +1548,9 @@ function $c({ }, "start chapter" ), - /* @__PURE__ */ s(Xt, { htmlFor: "end-chapters-combobox", children: "to" }), + /* @__PURE__ */ s(Ht, { htmlFor: "end-chapters-combobox", children: "to" }), /* @__PURE__ */ s( - qr, + Wr, { isDisabled: o, onChange: (d) => { @@ -1565,13 +1565,13 @@ function $c({ ) ] }); } -var Ic = /* @__PURE__ */ ((t) => (t.CURRENT_BOOK = "current book", t.CHOOSE_BOOKS = "choose books", t))(Ic || {}); -const bh = Object.freeze([ +var _c = /* @__PURE__ */ ((t) => (t.CURRENT_BOOK = "current book", t.CHOOSE_BOOKS = "choose books", t))(_c || {}); +const ih = Object.freeze([ "%webView_bookSelector_currentBook%", "%webView_bookSelector_choose%", "%webView_bookSelector_chooseBooks%" ]), _r = (t, e) => t[e] ?? e; -function vh({ +function sh({ handleBookSelectionModeChange: t, currentBookName: e, onSelectBooks: n, @@ -1590,23 +1590,23 @@ function vh({ v(h), t(h); }; return /* @__PURE__ */ s( - bi, + hi, { className: "pr-twp tw-flex", value: g, onValueChange: (h) => m(h), - children: /* @__PURE__ */ N("div", { className: "tw-flex tw-w-full tw-flex-col tw-gap-4", children: [ - /* @__PURE__ */ N("div", { className: "tw-grid tw-grid-cols-[25%,25%,50%]", children: [ - /* @__PURE__ */ N("div", { className: "tw-flex tw-items-center", children: [ - /* @__PURE__ */ s(Wr, { + children: /* @__PURE__ */ x("div", { className: "tw-flex tw-w-full tw-flex-col tw-gap-4", children: [ + /* @__PURE__ */ x("div", { className: "tw-grid tw-grid-cols-[25%,25%,50%]", children: [ + /* @__PURE__ */ x("div", { className: "tw-flex tw-items-center", children: [ + /* @__PURE__ */ s(Yr, { value: "current book" /* CURRENT_BOOK */ }), - /* @__PURE__ */ s(Xt, { className: "tw-ml-1", children: p }) + /* @__PURE__ */ s(Ht, { className: "tw-ml-1", children: p }) ] }), - /* @__PURE__ */ s(Xt, { className: "tw-flex tw-items-center", children: e }), + /* @__PURE__ */ s(Ht, { className: "tw-flex tw-items-center", children: e }), /* @__PURE__ */ s("div", { className: "tw-flex tw-items-center tw-justify-end", children: /* @__PURE__ */ s( - $c, + Rc, { isDisabled: g === "choose books", handleSelectStartChapter: c, @@ -1617,15 +1617,15 @@ function vh({ } ) }) ] }), - /* @__PURE__ */ N("div", { className: "tw-grid tw-grid-cols-[25%,50%,25%]", children: [ - /* @__PURE__ */ N("div", { className: "tw-flex tw-items-center", children: [ - /* @__PURE__ */ s(Wr, { + /* @__PURE__ */ x("div", { className: "tw-grid tw-grid-cols-[25%,50%,25%]", children: [ + /* @__PURE__ */ x("div", { className: "tw-flex tw-items-center", children: [ + /* @__PURE__ */ s(Yr, { value: "choose books" /* CHOOSE_BOOKS */ }), - /* @__PURE__ */ s(Xt, { className: "tw-ml-1", children: w }) + /* @__PURE__ */ s(Ht, { className: "tw-ml-1", children: w }) ] }), - /* @__PURE__ */ s(Xt, { className: "tw-flex tw-items-center", children: r.map((h) => ot.bookIdToEnglishName(h)).join(", ") }), + /* @__PURE__ */ s(Ht, { className: "tw-flex tw-items-center", children: r.map((h) => ot.bookIdToEnglishName(h)).join(", ") }), /* @__PURE__ */ s( gt, { @@ -1639,17 +1639,17 @@ function vh({ } ); } -function Ac({ table: t }) { - return /* @__PURE__ */ N(fo, { children: [ - /* @__PURE__ */ s(Sl, { asChild: !0, children: /* @__PURE__ */ N(gt, { variant: "outline", size: "sm", className: "tw-ml-auto tw-hidden tw-h-8 lg:tw-flex", children: [ - /* @__PURE__ */ s(rl, { className: "tw-mr-2 tw-h-4 tw-w-4" }), +function Pc({ table: t }) { + return /* @__PURE__ */ x(wo, { children: [ + /* @__PURE__ */ s(Nl, { asChild: !0, children: /* @__PURE__ */ x(gt, { variant: "outline", size: "sm", className: "tw-ml-auto tw-hidden tw-h-8 lg:tw-flex", children: [ + /* @__PURE__ */ s(tl, { className: "tw-mr-2 tw-h-4 tw-w-4" }), "View" ] }) }), - /* @__PURE__ */ N(rr, { align: "end", className: "tw-w-[150px]", children: [ + /* @__PURE__ */ x(rr, { align: "end", className: "tw-w-[150px]", children: [ /* @__PURE__ */ s(Sn, { children: "Toggle columns" }), /* @__PURE__ */ s(or, {}), t.getAllColumns().filter((e) => e.getCanHide()).map((e) => /* @__PURE__ */ s( - mo, + fo, { className: "tw-capitalize", checked: e.getIsVisible(), @@ -1661,11 +1661,11 @@ function Ac({ table: t }) { ] }) ] }); } -const gn = bt.Root, Mc = bt.Group, bn = bt.Value, De = E.forwardRef(({ className: t, children: e, ...n }, r) => /* @__PURE__ */ N( +const hn = bt.Root, $c = bt.Group, gn = bt.Value, De = S.forwardRef(({ className: t, children: e, ...n }, r) => /* @__PURE__ */ x( bt.Trigger, { ref: r, - className: x( + className: N( "tw-flex tw-h-10 tw-w-full tw-items-center tw-justify-between tw-rounded-md tw-border tw-border-input tw-bg-background tw-px-3 tw-py-2 tw-text-sm tw-ring-offset-background placeholder:tw-text-muted-foreground focus:tw-outline-none focus:tw-ring-2 focus:tw-ring-ring focus:tw-ring-offset-2 disabled:tw-cursor-not-allowed disabled:tw-opacity-50 [&>span]:tw-line-clamp-1", t ), @@ -1677,31 +1677,31 @@ const gn = bt.Root, Mc = bt.Group, bn = bt.Value, De = E.forwardRef(({ className } )); De.displayName = bt.Trigger.displayName; -const Ti = E.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( +const Ei = S.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( bt.ScrollUpButton, { ref: n, - className: x("tw-flex tw-cursor-default tw-items-center tw-justify-center tw-py-1", t), + className: N("tw-flex tw-cursor-default tw-items-center tw-justify-center tw-py-1", t), ...e, - children: /* @__PURE__ */ s(ol, { className: "tw-h-4 tw-w-4" }) + children: /* @__PURE__ */ s(el, { className: "tw-h-4 tw-w-4" }) } )); -Ti.displayName = bt.ScrollUpButton.displayName; -const Ci = E.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( +Ei.displayName = bt.ScrollUpButton.displayName; +const Si = S.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( bt.ScrollDownButton, { ref: n, - className: x("tw-flex tw-cursor-default tw-items-center tw-justify-center tw-py-1", t), + className: N("tw-flex tw-cursor-default tw-items-center tw-justify-center tw-py-1", t), ...e, children: /* @__PURE__ */ s(er, { className: "tw-h-4 tw-w-4" }) } )); -Ci.displayName = bt.ScrollDownButton.displayName; -const Be = E.forwardRef(({ className: t, children: e, position: n = "popper", ...r }, o) => /* @__PURE__ */ s(bt.Portal, { children: /* @__PURE__ */ N( +Si.displayName = bt.ScrollDownButton.displayName; +const Be = S.forwardRef(({ className: t, children: e, position: n = "popper", ...r }, o) => /* @__PURE__ */ s(bt.Portal, { children: /* @__PURE__ */ x( bt.Content, { ref: o, - className: x( + className: N( "pr-twp tw-relative tw-z-50 tw-max-h-96 tw-min-w-[8rem] tw-overflow-hidden tw-rounded-md tw-border tw-bg-popover tw-text-popover-foreground tw-shadow-md data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0 data-[state=closed]:tw-zoom-out-95 data-[state=open]:tw-zoom-in-95 data-[side=bottom]:tw-slide-in-from-top-2 data-[side=left]:tw-slide-in-from-right-2 data-[side=right]:tw-slide-in-from-left-2 data-[side=top]:tw-slide-in-from-bottom-2", n === "popper" && "data-[side=bottom]:tw-translate-y-1 data-[side=left]:tw--translate-x-1 data-[side=right]:tw-translate-x-1 data-[side=top]:tw--translate-y-1", t @@ -1709,36 +1709,36 @@ const Be = E.forwardRef(({ className: t, children: e, position: n = "popper", .. position: n, ...r, children: [ - /* @__PURE__ */ s(Ti, {}), + /* @__PURE__ */ s(Ei, {}), /* @__PURE__ */ s( bt.Viewport, { - className: x( + className: N( "tw-p-1", n === "popper" && "tw-h-[var(--radix-select-trigger-height)] tw-w-full tw-min-w-[var(--radix-select-trigger-width)]" ), children: e } ), - /* @__PURE__ */ s(Ci, {}) + /* @__PURE__ */ s(Si, {}) ] } ) })); Be.displayName = bt.Content.displayName; -const Dc = E.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( +const Ic = S.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( bt.Label, { ref: n, - className: x("tw-py-1.5 tw-pl-8 tw-pr-2 tw-text-sm tw-font-semibold", t), + className: N("tw-py-1.5 tw-pl-8 tw-pr-2 tw-text-sm tw-font-semibold", t), ...e } )); -Dc.displayName = bt.Label.displayName; -const Gt = E.forwardRef(({ className: t, children: e, ...n }, r) => /* @__PURE__ */ N( +Ic.displayName = bt.Label.displayName; +const Ut = S.forwardRef(({ className: t, children: e, ...n }, r) => /* @__PURE__ */ x( bt.Item, { ref: r, - className: x( + className: N( "tw-relative tw-flex tw-w-full tw-cursor-default tw-select-none tw-items-center tw-rounded-sm tw-py-1.5 tw-pl-8 tw-pr-2 tw-text-sm tw-outline-none focus:tw-bg-accent focus:tw-text-accent-foreground data-[disabled]:tw-pointer-events-none data-[disabled]:tw-opacity-50", t ), @@ -1749,49 +1749,49 @@ const Gt = E.forwardRef(({ className: t, children: e, ...n }, r) => /* @__PURE__ ] } )); -Gt.displayName = bt.Item.displayName; -const Bc = E.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( +Ut.displayName = bt.Item.displayName; +const Ac = S.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( bt.Separator, { ref: n, - className: x("tw--mx-1 tw-my-1 tw-h-px tw-bg-muted", t), + className: N("tw--mx-1 tw-my-1 tw-h-px tw-bg-muted", t), ...e } )); -Bc.displayName = bt.Separator.displayName; -function jc({ table: t }) { - return /* @__PURE__ */ s("div", { className: "tw-flex tw-items-center tw-justify-between tw-px-2 tw-pb-3 tw-pt-3", children: /* @__PURE__ */ N("div", { className: "tw-flex tw-items-center tw-space-x-6 lg:tw-space-x-8", children: [ - /* @__PURE__ */ N("div", { className: "tw-flex-1 tw-text-sm tw-text-muted-foreground", children: [ +Ac.displayName = bt.Separator.displayName; +function Mc({ table: t }) { + return /* @__PURE__ */ s("div", { className: "tw-flex tw-items-center tw-justify-between tw-px-2 tw-pb-3 tw-pt-3", children: /* @__PURE__ */ x("div", { className: "tw-flex tw-items-center tw-space-x-6 lg:tw-space-x-8", children: [ + /* @__PURE__ */ x("div", { className: "tw-flex-1 tw-text-sm tw-text-muted-foreground", children: [ t.getFilteredSelectedRowModel().rows.length, " of", " ", t.getFilteredRowModel().rows.length, " row(s) selected" ] }), - /* @__PURE__ */ N("div", { className: "tw-flex tw-items-center tw-space-x-2", children: [ + /* @__PURE__ */ x("div", { className: "tw-flex tw-items-center tw-space-x-2", children: [ /* @__PURE__ */ s("p", { className: "tw-text-nowrap tw-text-sm tw-font-medium", children: "Rows per page" }), - /* @__PURE__ */ N( - gn, + /* @__PURE__ */ x( + hn, { value: `${t.getState().pagination.pageSize}`, onValueChange: (e) => { t.setPageSize(Number(e)); }, children: [ - /* @__PURE__ */ s(De, { className: "tw-h-8 tw-w-[70px]", children: /* @__PURE__ */ s(bn, { placeholder: t.getState().pagination.pageSize }) }), - /* @__PURE__ */ s(Be, { side: "top", children: [10, 20, 30, 40, 50].map((e) => /* @__PURE__ */ s(Gt, { value: `${e}`, children: e }, e)) }) + /* @__PURE__ */ s(De, { className: "tw-h-8 tw-w-[70px]", children: /* @__PURE__ */ s(gn, { placeholder: t.getState().pagination.pageSize }) }), + /* @__PURE__ */ s(Be, { side: "top", children: [10, 20, 30, 40, 50].map((e) => /* @__PURE__ */ s(Ut, { value: `${e}`, children: e }, e)) }) ] } ) ] }), - /* @__PURE__ */ N("div", { className: "tw-flex tw-w-[100px] tw-items-center tw-justify-center tw-text-sm tw-font-medium", children: [ + /* @__PURE__ */ x("div", { className: "tw-flex tw-w-[100px] tw-items-center tw-justify-center tw-text-sm tw-font-medium", children: [ "Page ", t.getState().pagination.pageIndex + 1, " of ", t.getPageCount() ] }), - /* @__PURE__ */ N("div", { className: "tw-flex tw-items-center tw-space-x-2", children: [ - /* @__PURE__ */ N( + /* @__PURE__ */ x("div", { className: "tw-flex tw-items-center tw-space-x-2", children: [ + /* @__PURE__ */ x( gt, { variant: "outline", @@ -1801,11 +1801,11 @@ function jc({ table: t }) { disabled: !t.getCanPreviousPage(), children: [ /* @__PURE__ */ s("span", { className: "tw-sr-only", children: "Go to first page" }), - /* @__PURE__ */ s(al, { className: "tw-h-4 tw-w-4" }) + /* @__PURE__ */ s(nl, { className: "tw-h-4 tw-w-4" }) ] } ), - /* @__PURE__ */ N( + /* @__PURE__ */ x( gt, { variant: "outline", @@ -1815,11 +1815,11 @@ function jc({ table: t }) { disabled: !t.getCanPreviousPage(), children: [ /* @__PURE__ */ s("span", { className: "tw-sr-only", children: "Go to previous page" }), - /* @__PURE__ */ s(il, { className: "tw-h-4 tw-w-4" }) + /* @__PURE__ */ s(rl, { className: "tw-h-4 tw-w-4" }) ] } ), - /* @__PURE__ */ N( + /* @__PURE__ */ x( gt, { variant: "outline", @@ -1829,11 +1829,11 @@ function jc({ table: t }) { disabled: !t.getCanNextPage(), children: [ /* @__PURE__ */ s("span", { className: "tw-sr-only", children: "Go to next page" }), - /* @__PURE__ */ s(sl, { className: "tw-h-4 tw-w-4" }) + /* @__PURE__ */ s(ol, { className: "tw-h-4 tw-w-4" }) ] } ), - /* @__PURE__ */ N( + /* @__PURE__ */ x( gt, { variant: "outline", @@ -1843,27 +1843,27 @@ function jc({ table: t }) { disabled: !t.getCanNextPage(), children: [ /* @__PURE__ */ s("span", { className: "tw-sr-only", children: "Go to last page" }), - /* @__PURE__ */ s(ll, { className: "tw-h-4 tw-w-4" }) + /* @__PURE__ */ s(al, { className: "tw-h-4 tw-w-4" }) ] } ) ] }) ] }) }); } -const ar = E.forwardRef(({ className: t, stickyHeader: e, ...n }, r) => /* @__PURE__ */ s("div", { className: x("pr-twp tw-relative tw-w-full", { "tw-overflow-auto": !e }), children: /* @__PURE__ */ s( +const ar = S.forwardRef(({ className: t, stickyHeader: e, ...n }, r) => /* @__PURE__ */ s("div", { className: N("pr-twp tw-relative tw-w-full", { "tw-overflow-auto": !e }), children: /* @__PURE__ */ s( "table", { ref: r, - className: x("tw-w-full tw-caption-bottom tw-text-sm", t), + className: N("tw-w-full tw-caption-bottom tw-text-sm", t), ...n } ) })); ar.displayName = "Table"; -const ir = E.forwardRef(({ className: t, stickyHeader: e, ...n }, r) => /* @__PURE__ */ s( +const ir = S.forwardRef(({ className: t, stickyHeader: e, ...n }, r) => /* @__PURE__ */ s( "thead", { ref: r, - className: x( + className: N( { "tw-sticky tw-top-[-1px] tw-bg-background tw-drop-shadow-sm": e }, "[&_tr]:tw-border-b", t @@ -1872,23 +1872,23 @@ const ir = E.forwardRef(({ className: t, stickyHeader: e, ...n }, r) => /* @__PU } )); ir.displayName = "TableHeader"; -const sr = E.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s("tbody", { ref: n, className: x("[&_tr:last-child]:tw-border-0", t), ...e })); +const sr = S.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s("tbody", { ref: n, className: N("[&_tr:last-child]:tw-border-0", t), ...e })); sr.displayName = "TableBody"; -const Vc = E.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( +const Dc = S.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( "tfoot", { ref: n, - className: x("tw-border-t tw-bg-muted/50 tw-font-medium [&>tr]:last:tw-border-b-0", t), + className: N("tw-border-t tw-bg-muted/50 tw-font-medium [&>tr]:last:tw-border-b-0", t), ...e } )); -Vc.displayName = "TableFooter"; -const oe = E.forwardRef( +Dc.displayName = "TableFooter"; +const oe = S.forwardRef( ({ className: t, ...e }, n) => /* @__PURE__ */ s( "tr", { ref: n, - className: x( + className: N( "tw-border-b tw-transition-colors hover:tw-bg-muted/50 data-[state=selected]:tw-bg-muted", t ), @@ -1897,37 +1897,37 @@ const oe = E.forwardRef( ) ); oe.displayName = "TableRow"; -const vn = E.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( +const bn = S.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( "th", { ref: n, - className: x( + className: N( "tw-h-12 tw-px-4 tw-text-start tw-align-middle tw-font-medium tw-text-muted-foreground [&:has([role=checkbox])]:tw-pe-0", t ), ...e } )); -vn.displayName = "TableHead"; -const je = E.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( +bn.displayName = "TableHead"; +const je = S.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( "td", { ref: n, - className: x("tw-p-4 tw-align-middle [&:has([role=checkbox])]:tw-pe-0", t), + className: N("tw-p-4 tw-align-middle [&:has([role=checkbox])]:tw-pe-0", t), ...e } )); je.displayName = "TableCell"; -const zc = E.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( +const Bc = S.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( "caption", { ref: n, - className: x("tw-mt-4 tw-text-sm tw-text-muted-foreground", t), + className: N("tw-mt-4 tw-text-sm tw-text-muted-foreground", t), ...e } )); -zc.displayName = "TableCaption"; -function Lc({ +Bc.displayName = "TableCaption"; +function jc({ columns: t, data: e, enablePagination: n = !1, @@ -1938,15 +1938,15 @@ function Lc({ } }) { var h; - const [l, c] = ut([]), [d, p] = ut([]), [f, w] = ut({}), [g, v] = ut({}), m = ei({ + const [l, c] = ut([]), [d, p] = ut([]), [f, w] = ut({}), [g, v] = ut({}), m = Qa({ data: e, columns: t, - getCoreRowModel: ni(), - ...n && { getPaginationRowModel: _l() }, + getCoreRowModel: ti(), + ...n && { getPaginationRowModel: Cl() }, onSortingChange: c, - getSortedRowModel: ri(), + getSortedRowModel: ei(), onColumnFiltersChange: p, - getFilteredRowModel: Pl(), + getFilteredRowModel: Ol(), onColumnVisibilityChange: w, onRowSelectionChange: v, state: { @@ -1956,21 +1956,21 @@ function Lc({ rowSelection: g } }); - return /* @__PURE__ */ N("div", { className: "pr-twp", children: [ - o && /* @__PURE__ */ s(Ac, { table: m }), - /* @__PURE__ */ N(ar, { stickyHeader: a, children: [ - /* @__PURE__ */ s(ir, { stickyHeader: a, children: m.getHeaderGroups().map((S) => /* @__PURE__ */ s(oe, { children: S.headers.map((_) => /* @__PURE__ */ s(vn, { children: _.isPlaceholder ? void 0 : dn(_.column.columnDef.header, _.getContext()) }, _.id)) }, S.id)) }), - /* @__PURE__ */ s(sr, { children: (h = m.getRowModel().rows) != null && h.length ? m.getRowModel().rows.map((S) => /* @__PURE__ */ s( + return /* @__PURE__ */ x("div", { className: "pr-twp", children: [ + o && /* @__PURE__ */ s(Pc, { table: m }), + /* @__PURE__ */ x(ar, { stickyHeader: a, children: [ + /* @__PURE__ */ s(ir, { stickyHeader: a, children: m.getHeaderGroups().map((T) => /* @__PURE__ */ s(oe, { children: T.headers.map((A) => /* @__PURE__ */ s(bn, { children: A.isPlaceholder ? void 0 : cn(A.column.columnDef.header, A.getContext()) }, A.id)) }, T.id)) }), + /* @__PURE__ */ s(sr, { children: (h = m.getRowModel().rows) != null && h.length ? m.getRowModel().rows.map((T) => /* @__PURE__ */ s( oe, { - onClick: () => i(S, m), - "data-state": S.getIsSelected() && "selected", - children: S.getVisibleCells().map((_) => /* @__PURE__ */ s(je, { children: dn(_.column.columnDef.cell, _.getContext()) }, _.id)) + onClick: () => i(T, m), + "data-state": T.getIsSelected() && "selected", + children: T.getVisibleCells().map((A) => /* @__PURE__ */ s(je, { children: cn(A.column.columnDef.cell, A.getContext()) }, A.id)) }, - S.id + T.id )) : /* @__PURE__ */ s(oe, { children: /* @__PURE__ */ s(je, { colSpan: t.length, className: "tw-h-24 tw-text-center", children: "No results." }) }) }) ] }), - n && /* @__PURE__ */ N("div", { className: "tw-flex tw-items-center tw-justify-end tw-space-x-2 tw-py-4", children: [ + n && /* @__PURE__ */ x("div", { className: "tw-flex tw-items-center tw-justify-end tw-space-x-2 tw-py-4", children: [ /* @__PURE__ */ s( gt, { @@ -1992,26 +1992,26 @@ function Lc({ } ) ] }), - n && r && /* @__PURE__ */ s(jc, { table: m }) + n && r && /* @__PURE__ */ s(Mc, { table: m }) ] }); } -function Fc({ +function Vc({ occurrenceData: t, setScriptureReference: e, localizedStrings: n }) { - const r = n["%webView_inventory_occurrences_table_header_reference%"], o = n["%webView_inventory_occurrences_table_header_occurrence%"], a = It(() => { + const r = n["%webView_inventory_occurrences_table_header_reference%"], o = n["%webView_inventory_occurrences_table_header_occurrence%"], a = $t(() => { const i = []; return t.forEach((l) => { - i.some((c) => co(c, l)) || i.push(l); + i.some((c) => lo(c, l)) || i.push(l); }), i; }, [t]); - return /* @__PURE__ */ N(ar, { stickyHeader: !0, children: [ - /* @__PURE__ */ s(ir, { stickyHeader: !0, children: /* @__PURE__ */ N(oe, { children: [ - /* @__PURE__ */ s(vn, { children: r }), - /* @__PURE__ */ s(vn, { children: o }) + return /* @__PURE__ */ x(ar, { stickyHeader: !0, children: [ + /* @__PURE__ */ s(ir, { stickyHeader: !0, children: /* @__PURE__ */ x(oe, { children: [ + /* @__PURE__ */ s(bn, { children: r }), + /* @__PURE__ */ s(bn, { children: o }) ] }) }), - /* @__PURE__ */ s(sr, { children: a.length > 0 && a.map((i) => /* @__PURE__ */ N( + /* @__PURE__ */ s(sr, { children: a.length > 0 && a.map((i) => /* @__PURE__ */ x( oe, { onClick: () => { @@ -2026,33 +2026,33 @@ function Fc({ )) }) ] }); } -const ho = E.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( - Xr.Root, +const mo = S.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( + Hr.Root, { ref: n, - className: x( + className: N( "tw-peer pr-twp tw-h-4 tw-w-4 tw-shrink-0 tw-rounded-sm tw-border tw-border-primary tw-ring-offset-background focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-cursor-not-allowed disabled:tw-opacity-50 data-[state=checked]:tw-bg-primary data-[state=checked]:tw-text-primary-foreground", t ), ...e, children: /* @__PURE__ */ s( - Xr.Indicator, + Hr.Indicator, { - className: x("tw-flex tw-items-center tw-justify-center tw-text-current"), + className: N("tw-flex tw-items-center tw-justify-center tw-text-current"), children: /* @__PURE__ */ s(tr, { className: "tw-h-4 tw-w-4" }) } ) } )); -ho.displayName = Xr.Root.displayName; -const Uc = (t) => t.split(/(?:\r?\n|\r)|(?=(?:\\(?:v|c|id)))/g), oa = (t) => { +mo.displayName = Hr.Root.displayName; +const zc = (t) => t.split(/(?:\r?\n|\r)|(?=(?:\\(?:v|c|id)))/g), ra = (t) => { const e = /^\\[vc]\s+(\d+)/, n = t.match(e); if (n) return +n[1]; -}, Gc = (t) => { +}, Lc = (t) => { const e = t.match(/^\\id\s+([A-Za-z]+)/); return e ? ot.bookIdToNumber(e[1]) : 0; -}, Hc = (t, e, n) => n.includes(t) ? "unapproved" : e.includes(t) ? "approved" : "unknown", Oi = Xe( +}, Fc = (t, e, n) => n.includes(t) ? "unapproved" : e.includes(t) ? "approved" : "unknown", Ti = kn( "pr-twp tw-inline-flex tw-items-center tw-justify-center tw-rounded-md tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-colors hover:tw-bg-muted hover:tw-text-muted-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50 data-[state=on]:tw-bg-accent data-[state=on]:tw-text-accent-foreground", { variants: { @@ -2071,26 +2071,26 @@ const Uc = (t) => t.split(/(?:\r?\n|\r)|(?=(?:\\(?:v|c|id)))/g), oa = (t) => { size: "default" } } -), Xc = E.forwardRef(({ className: t, variant: e, size: n, ...r }, o) => /* @__PURE__ */ s( - oi.Root, +), Uc = S.forwardRef(({ className: t, variant: e, size: n, ...r }, o) => /* @__PURE__ */ s( + ni.Root, { ref: o, - className: x(Oi({ variant: e, size: n, className: t })), + className: N(Ti({ variant: e, size: n, className: t })), ...r } )); -Xc.displayName = oi.Root.displayName; -const Ri = E.createContext({ +Uc.displayName = ni.Root.displayName; +const Ci = S.createContext({ size: "default", variant: "default" -}), _i = E.forwardRef(({ className: t, variant: e, size: n, children: r, ...o }, a) => /* @__PURE__ */ s( +}), Oi = S.forwardRef(({ className: t, variant: e, size: n, children: r, ...o }, a) => /* @__PURE__ */ s( nr.Root, { ref: a, - className: x("pr-twp tw-flex tw-items-center tw-justify-center tw-gap-1", t), + className: N("pr-twp tw-flex tw-items-center tw-justify-center tw-gap-1", t), ...o, children: /* @__PURE__ */ s( - Ri.Provider, + Ci.Provider, { value: { variant: e, size: n }, children: r @@ -2098,15 +2098,15 @@ const Ri = E.createContext({ ) } )); -_i.displayName = nr.Root.displayName; -const Un = E.forwardRef(({ className: t, children: e, variant: n, size: r, ...o }, a) => { - const i = E.useContext(Ri); +Oi.displayName = nr.Root.displayName; +const Un = S.forwardRef(({ className: t, children: e, variant: n, size: r, ...o }, a) => { + const i = S.useContext(Ci); return /* @__PURE__ */ s( nr.Item, { ref: a, - className: x( - Oi({ + className: N( + Ti({ variant: i.variant || n, size: i.size || r }), @@ -2118,23 +2118,23 @@ const Un = E.forwardRef(({ className: t, children: e, variant: n, size: r, ...o ); }); Un.displayName = nr.Item.displayName; -const lr = (t) => t === "asc" ? /* @__PURE__ */ s(ul, { className: "tw-ms-2 tw-h-4 tw-w-4" }) : t === "desc" ? /* @__PURE__ */ s(wl, { className: "tw-ms-2 tw-h-4 tw-w-4" }) : /* @__PURE__ */ s(fl, { className: "tw-ms-2 tw-h-4 tw-w-4" }), yh = (t) => ({ +const lr = (t) => t === "asc" ? /* @__PURE__ */ s(cl, { className: "tw-ms-2 tw-h-4 tw-w-4" }) : t === "desc" ? /* @__PURE__ */ s(dl, { className: "tw-ms-2 tw-h-4 tw-w-4" }) : /* @__PURE__ */ s(pl, { className: "tw-ms-2 tw-h-4 tw-w-4" }), lh = (t) => ({ accessorKey: "item", accessorFn: (e) => e.items[0], - header: ({ column: e }) => /* @__PURE__ */ N(gt, { variant: "ghost", onClick: () => e.toggleSorting(void 0), children: [ + header: ({ column: e }) => /* @__PURE__ */ x(gt, { variant: "ghost", onClick: () => e.toggleSorting(void 0), children: [ t, lr(e.getIsSorted()) ] }) -}), Yc = (t, e) => ({ +}), Gc = (t, e) => ({ accessorKey: `item${e}`, accessorFn: (n) => n.items[e], - header: ({ column: n }) => /* @__PURE__ */ N(gt, { variant: "ghost", onClick: () => n.toggleSorting(void 0), children: [ + header: ({ column: n }) => /* @__PURE__ */ x(gt, { variant: "ghost", onClick: () => n.toggleSorting(void 0), children: [ t, lr(n.getIsSorted()) ] }) -}), xh = (t) => ({ +}), ch = (t) => ({ accessorKey: "count", - header: ({ column: e }) => /* @__PURE__ */ s("div", { className: "tw-flex tw-justify-end tw-tabular-nums", children: /* @__PURE__ */ N(gt, { variant: "ghost", onClick: () => e.toggleSorting(void 0), children: [ + header: ({ column: e }) => /* @__PURE__ */ s("div", { className: "tw-flex tw-justify-end tw-tabular-nums", children: /* @__PURE__ */ x(gt, { variant: "ghost", onClick: () => e.toggleSorting(void 0), children: [ t, lr(e.getIsSorted()) ] }) }), @@ -2148,15 +2148,15 @@ const lr = (t) => t === "asc" ? /* @__PURE__ */ s(ul, { className: "tw-ms-2 tw-h t.forEach((c) => { e === "unapproved" ? l.includes(c) || l.push(c) : l = l.filter((d) => d !== c); }), a(l); -}, Nh = (t, e, n, r, o) => ({ +}, dh = (t, e, n, r, o) => ({ accessorKey: "status", - header: ({ column: a }) => /* @__PURE__ */ s("div", { className: "tw-flex tw-justify-center", children: /* @__PURE__ */ N(gt, { variant: "ghost", onClick: () => a.toggleSorting(void 0), children: [ + header: ({ column: a }) => /* @__PURE__ */ s("div", { className: "tw-flex tw-justify-center", children: /* @__PURE__ */ x(gt, { variant: "ghost", onClick: () => a.toggleSorting(void 0), children: [ t, lr(a.getIsSorted()) ] }) }), cell: ({ row: a }) => { const i = a.getValue("status"), l = a.getValue("item"); - return /* @__PURE__ */ N(_i, { value: i, variant: "outline", type: "single", children: [ + return /* @__PURE__ */ x(Oi, { value: i, variant: "outline", type: "single", children: [ /* @__PURE__ */ s( Un, { @@ -2169,7 +2169,7 @@ const lr = (t) => t === "asc" ? /* @__PURE__ */ s(ul, { className: "tw-ms-2 tw-h o ), value: "approved", - children: /* @__PURE__ */ s(cl, {}) + children: /* @__PURE__ */ s(il, {}) } ), /* @__PURE__ */ s( @@ -2184,7 +2184,7 @@ const lr = (t) => t === "asc" ? /* @__PURE__ */ s(ul, { className: "tw-ms-2 tw-h o ), value: "unapproved", - children: /* @__PURE__ */ s(dl, {}) + children: /* @__PURE__ */ s(sl, {}) } ), /* @__PURE__ */ s( @@ -2199,12 +2199,12 @@ const lr = (t) => t === "asc" ? /* @__PURE__ */ s(ul, { className: "tw-ms-2 tw-h o ), value: "unknown", - children: /* @__PURE__ */ s(pl, {}) + children: /* @__PURE__ */ s(ll, {}) } ) ] }); } -}), kh = Object.freeze([ +}), ph = Object.freeze([ "%webView_inventory_all%", "%webView_inventory_approved%", "%webView_inventory_unapproved%", @@ -2216,29 +2216,29 @@ const lr = (t) => t === "asc" ? /* @__PURE__ */ s(ul, { className: "tw-ms-2 tw-h "%webView_inventory_show_additional_items%", "%webView_inventory_occurrences_table_header_reference%", "%webView_inventory_occurrences_table_header_occurrence%" -]), Wc = (t, e, n) => { +]), Hc = (t, e, n) => { let r = t; return e !== "all" && (r = r.filter( (o) => e === "approved" && o.status === "approved" || e === "unapproved" && o.status === "unapproved" || e === "unknown" && o.status === "unknown" )), n !== "" && (r = r.filter((o) => o.items[0].includes(n))), r; -}, qc = (t, e, n, r, o) => { +}, Xc = (t, e, n, r, o) => { if (!t) return []; const a = []; let i = e.bookNum, l = e.chapterNum, c = e.verseNum; - return Uc(t).forEach((p) => { - p.startsWith("\\id") && (i = Gc(p), l = 0, c = 0), p.startsWith("\\c") && (l = oa(p), c = 0), p.startsWith("\\v") && (c = oa(p), l === 0 && (l = e.chapterNum)); + return zc(t).forEach((p) => { + p.startsWith("\\id") && (i = Lc(p), l = 0, c = 0), p.startsWith("\\c") && (l = ra(p), c = 0), p.startsWith("\\v") && (c = ra(p), l === 0 && (l = e.chapterNum)); let f = o.exec(p) ?? void 0; for (; f; ) { const w = []; f.forEach((h) => w.push(h)); - const g = f.index, v = a.find((h) => co(h.items, w)), m = { + const g = f.index, v = a.find((h) => lo(h.items, w)), m = { reference: { bookNum: i !== void 0 ? i : -1, chapterNum: l !== void 0 ? l : -1, verseNum: c !== void 0 ? c : -1 }, - text: Cl(p, Math.max(0, g - 25), Math.min(g + 25, p.length)) + text: El(p, Math.max(0, g - 25), Math.min(g + 25, p.length)) }; if (v) v.count += 1, v.occurrences.push(m); @@ -2246,7 +2246,7 @@ const lr = (t) => t === "asc" ? /* @__PURE__ */ s(ul, { className: "tw-ms-2 tw-h const h = { items: w, count: 1, - status: Hc(w[0], n, r), + status: Fc(w[0], n, r), occurrences: [m] }; a.push(h); @@ -2255,7 +2255,7 @@ const lr = (t) => t === "asc" ? /* @__PURE__ */ s(ul, { className: "tw-ms-2 tw-h } }), a; }, Jt = (t, e) => t[e] ?? e; -function Eh({ +function uh({ scriptureReference: t, setScriptureReference: e, localizedStrings: n, @@ -2268,52 +2268,52 @@ function Eh({ onScopeChange: d, columns: p }) { - const f = Jt(n, "%webView_inventory_all%"), w = Jt(n, "%webView_inventory_approved%"), g = Jt(n, "%webView_inventory_unapproved%"), v = Jt(n, "%webView_inventory_unknown%"), m = Jt(n, "%webView_inventory_scope_currentBook%"), h = Jt(n, "%webView_inventory_scope_chapter%"), S = Jt(n, "%webView_inventory_scope_verse%"), _ = Jt(n, "%webView_inventory_filter_text%"), C = Jt( + const f = Jt(n, "%webView_inventory_all%"), w = Jt(n, "%webView_inventory_approved%"), g = Jt(n, "%webView_inventory_unapproved%"), v = Jt(n, "%webView_inventory_unknown%"), m = Jt(n, "%webView_inventory_scope_currentBook%"), h = Jt(n, "%webView_inventory_scope_chapter%"), T = Jt(n, "%webView_inventory_scope_verse%"), A = Jt(n, "%webView_inventory_filter_text%"), R = Jt( n, "%webView_inventory_show_additional_items%" - ), [T, b] = ut(!1), [I, z] = ut("all"), [H, O] = ut(""), [$, k] = ut([]), B = It(() => l ? r instanceof RegExp ? qc( + ), [E, b] = ut(!1), [$, z] = ut("all"), [H, C] = ut(""), [P, k] = ut([]), B = $t(() => l ? r instanceof RegExp ? Xc( l, t, a, i, r - ) : r(l, t, a, i) : [], [l, r, t, a, i]), D = It(() => { - if (T) + ) : r(l, t, a, i) : [], [l, r, t, a, i]), M = $t(() => { + if (E) return B; const y = []; - return B.forEach((R) => { - const L = R.items[0], F = y.find( + return B.forEach((O) => { + const L = O.items[0], F = y.find( (V) => V.items[0] === L ); - F ? (F.count += R.count, F.occurrences = F.occurrences.concat(R.occurrences)) : y.push({ + F ? (F.count += O.count, F.occurrences = F.occurrences.concat(O.occurrences)) : y.push({ items: [L], - count: R.count, - occurrences: R.occurrences, - status: R.status + count: O.count, + occurrences: O.occurrences, + status: O.status }); }), y; - }, [T, B]), J = It(() => Wc(D, I, H), [D, I, H]), q = It(() => { + }, [E, B]), J = $t(() => Hc(M, $, H), [M, $, H]), q = $t(() => { var L, F; - if (!T) + if (!E) return p; const y = (L = o == null ? void 0 : o.tableHeaders) == null ? void 0 : L.length; if (!y) return p; - const R = []; + const O = []; for (let V = 0; V < y; V++) - R.push( - Yc( + O.push( + Gc( ((F = o == null ? void 0 : o.tableHeaders) == null ? void 0 : F[V]) || "Additional Item", V + 1 ) ); - return [...R, ...p]; - }, [o == null ? void 0 : o.tableHeaders, p, T]); + return [...O, ...p]; + }, [o == null ? void 0 : o.tableHeaders, p, E]); ae(() => { k([]); }, [J]); - const U = (y, R) => { - R.setRowSelection(() => { + const U = (y, O) => { + O.setRowSelection(() => { const L = {}; return L[y.index] = !0, L; }), k(y.original.items); @@ -2327,70 +2327,70 @@ function Eh({ z(y); else throw new Error(`Invalid status filter value: ${y}`); - }, rt = It(() => { - if (D.length === 0 || $.length === 0) + }, rt = $t(() => { + if (M.length === 0 || P.length === 0) return []; - const y = D.filter((R) => co( - T ? R.items : [R.items[0]], - $ + const y = M.filter((O) => lo( + E ? O.items : [O.items[0]], + P )); if (y.length > 1) throw new Error("Selected item is not unique"); return y[0].occurrences; - }, [$, T, D]); - return /* @__PURE__ */ N("div", { className: "pr-twp tw-flex tw-h-full tw-flex-col", children: [ - /* @__PURE__ */ N("div", { className: "tw-flex tw-items-stretch", children: [ - /* @__PURE__ */ N( - gn, + }, [P, E, M]); + return /* @__PURE__ */ x("div", { className: "pr-twp tw-flex tw-h-full tw-flex-col", children: [ + /* @__PURE__ */ x("div", { className: "tw-flex tw-items-stretch", children: [ + /* @__PURE__ */ x( + hn, { onValueChange: (y) => at(y), - defaultValue: I, + defaultValue: $, children: [ - /* @__PURE__ */ s(De, { className: "tw-m-1", children: /* @__PURE__ */ s(bn, { placeholder: "Select filter" }) }), - /* @__PURE__ */ N(Be, { children: [ - /* @__PURE__ */ s(Gt, { value: "all", children: f }), - /* @__PURE__ */ s(Gt, { value: "approved", children: w }), - /* @__PURE__ */ s(Gt, { value: "unapproved", children: g }), - /* @__PURE__ */ s(Gt, { value: "unknown", children: v }) + /* @__PURE__ */ s(De, { className: "tw-m-1", children: /* @__PURE__ */ s(gn, { placeholder: "Select filter" }) }), + /* @__PURE__ */ x(Be, { children: [ + /* @__PURE__ */ s(Ut, { value: "all", children: f }), + /* @__PURE__ */ s(Ut, { value: "approved", children: w }), + /* @__PURE__ */ s(Ut, { value: "unapproved", children: g }), + /* @__PURE__ */ s(Ut, { value: "unknown", children: v }) ] }) ] } ), - /* @__PURE__ */ N(gn, { onValueChange: (y) => tt(y), defaultValue: c, children: [ - /* @__PURE__ */ s(De, { className: "tw-m-1", children: /* @__PURE__ */ s(bn, { placeholder: "Select scope" }) }), - /* @__PURE__ */ N(Be, { children: [ - /* @__PURE__ */ s(Gt, { value: "book", children: m }), - /* @__PURE__ */ s(Gt, { value: "chapter", children: h }), - /* @__PURE__ */ s(Gt, { value: "verse", children: S }) + /* @__PURE__ */ x(hn, { onValueChange: (y) => tt(y), defaultValue: c, children: [ + /* @__PURE__ */ s(De, { className: "tw-m-1", children: /* @__PURE__ */ s(gn, { placeholder: "Select scope" }) }), + /* @__PURE__ */ x(Be, { children: [ + /* @__PURE__ */ s(Ut, { value: "book", children: m }), + /* @__PURE__ */ s(Ut, { value: "chapter", children: h }), + /* @__PURE__ */ s(Ut, { value: "verse", children: T }) ] }) ] }), /* @__PURE__ */ s( - Ye, + Xe, { className: "tw-m-1 tw-rounded-md tw-border", - placeholder: _, + placeholder: A, value: H, onChange: (y) => { - O(y.target.value); + C(y.target.value); } } ), - o && /* @__PURE__ */ N("div", { className: "tw-m-1 tw-flex tw-items-center tw-rounded-md tw-border", children: [ + o && /* @__PURE__ */ x("div", { className: "tw-m-1 tw-flex tw-items-center tw-rounded-md tw-border", children: [ /* @__PURE__ */ s( - ho, + mo, { className: "tw-m-1", - checked: T, + checked: E, onCheckedChange: (y) => { k([]), b(y); } } ), - /* @__PURE__ */ s(Xt, { className: "tw-m-1 tw-flex-shrink-0 tw-whitespace-nowrap", children: (o == null ? void 0 : o.checkboxText) ?? C }) + /* @__PURE__ */ s(Ht, { className: "tw-m-1 tw-flex-shrink-0 tw-whitespace-nowrap", children: (o == null ? void 0 : o.checkboxText) ?? R }) ] }) ] }), /* @__PURE__ */ s("div", { className: "tw-m-1 tw-flex-1 tw-overflow-auto tw-rounded-md tw-border", children: /* @__PURE__ */ s( - Lc, + jc, { columns: q, data: J, @@ -2399,7 +2399,7 @@ function Eh({ } ) }), rt.length > 0 && /* @__PURE__ */ s("div", { className: "tw-m-1 tw-flex-1 tw-overflow-auto tw-rounded-md tw-border", children: /* @__PURE__ */ s( - Fc, + Vc, { occurrenceData: rt, setScriptureReference: e, @@ -2408,7 +2408,7 @@ function Eh({ ) }) ] }); } -function Pi({ +function Ri({ className: t, onSearch: e, placeholder: n, @@ -2418,9 +2418,9 @@ function Pi({ a(l), e(l); }; return /* @__PURE__ */ s( - Ye, + Xe, { - className: x( + className: N( "tw-flex tw-h-10 tw-rounded-md tw-border tw-border-input tw-bg-background tw-px-3 tw-py-2 tw-text-sm tw-ring-offset-background file:tw-border-0 file:tw-bg-transparent file:tw-text-sm file:tw-font-medium placeholder:tw-text-muted-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-[color:hsl(240,5%,64.9%)] focus-visible:tw-ring-offset-2 disabled:tw-cursor-not-allowed disabled:tw-opacity-50", { "tw-w-full": r }, t @@ -2431,43 +2431,43 @@ function Pi({ } ); } -const $i = E.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( - _t.Root, +const _i = S.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( + Rt.Root, { orientation: "vertical", ref: n, - className: x("tw-flex tw-gap-1 tw-rounded-md tw-text-muted-foreground", t), + className: N("tw-flex tw-gap-1 tw-rounded-md tw-text-muted-foreground", t), ...e } )); -$i.displayName = _t.List.displayName; -const Ii = E.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( - _t.List, +_i.displayName = Rt.List.displayName; +const Pi = S.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( + Rt.List, { ref: n, - className: x( + className: N( "tw-flex-fit tw-mlk-items-center tw-w-[124px] tw-justify-center tw-rounded-md tw-bg-muted tw-p-1 tw-text-muted-foreground", t ), ...e } )); -Ii.displayName = _t.List.displayName; -const Kc = E.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( - _t.Trigger, +Pi.displayName = Rt.List.displayName; +const Yc = S.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( + Rt.Trigger, { ref: n, ...e, - className: x( + className: N( "overflow-clip tw-inline-flex tw-w-[116px] tw-cursor-pointer tw-items-center tw-justify-center tw-break-words tw-rounded-sm tw-border-0 tw-bg-muted tw-px-3 tw-py-1.5 tw-text-sm tw-font-medium tw-text-inherit tw-ring-offset-background tw-transition-all hover:tw-text-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50 data-[state=active]:tw-bg-background data-[state=active]:tw-text-foreground data-[state=active]:tw-shadow-sm", t ) } -)), Ai = E.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( - _t.Content, +)), $i = S.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( + Rt.Content, { ref: n, - className: x( + className: N( // Removed tw-mt-2 because Sebastian said so "tw-ms-5 tw-flex-grow tw-text-foreground tw-ring-offset-background focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2", t @@ -2475,8 +2475,8 @@ const Kc = E.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( ...e } )); -Ai.displayName = _t.Content.displayName; -function Sh({ +$i.displayName = Rt.Content.displayName; +function wh({ tabList: t, onSearch: e, searchPlaceholder: n, @@ -2484,11 +2484,11 @@ function Sh({ isSearchBarFullWidth: o = !1, direction: a = "ltr" }) { - return /* @__PURE__ */ N("div", { className: "pr-twp", children: [ - /* @__PURE__ */ N("div", { className: "tw-sticky tw-top-0 tw-space-y-2 tw-pb-2", children: [ + return /* @__PURE__ */ x("div", { className: "pr-twp", children: [ + /* @__PURE__ */ x("div", { className: "tw-sticky tw-top-0 tw-space-y-2 tw-pb-2", children: [ r ? /* @__PURE__ */ s("h1", { children: r }) : "", /* @__PURE__ */ s( - Pi, + Ri, { isFullWidth: o, onSearch: e, @@ -2496,19 +2496,19 @@ function Sh({ } ) ] }), - /* @__PURE__ */ N($i, { dir: a, children: [ - /* @__PURE__ */ s(Ii, { children: t.map((i) => /* @__PURE__ */ s(Kc, { value: i.value, children: i.value }, i.key)) }), - t.map((i) => /* @__PURE__ */ s(Ai, { value: i.value, children: i.content }, i.key)) + /* @__PURE__ */ x(_i, { dir: a, children: [ + /* @__PURE__ */ s(Pi, { children: t.map((i) => /* @__PURE__ */ s(Yc, { value: i.value, children: i.value }, i.key)) }), + t.map((i) => /* @__PURE__ */ s($i, { value: i.value, children: i.content }, i.key)) ] }) ] }); } -const go = E.forwardRef(({ className: t, orientation: e = "horizontal", decorative: n = !0, ...r }, o) => /* @__PURE__ */ s( - ai.Root, +const ho = S.forwardRef(({ className: t, orientation: e = "horizontal", decorative: n = !0, ...r }, o) => /* @__PURE__ */ s( + ri.Root, { ref: o, decorative: n, orientation: e, - className: x( + className: N( "pr-twp tw-shrink-0 tw-bg-border", e === "horizontal" ? "tw-h-[1px] tw-w-full" : "tw-h-full tw-w-[1px]", t @@ -2516,103 +2516,37 @@ const go = E.forwardRef(({ className: t, orientation: e = "horizontal", decorati ...r } )); -go.displayName = ai.Root.displayName; -const Jc = vt.Root, Zc = vt.Portal, Mi = M.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( - vt.Overlay, - { - className: x( - "tw-fixed tw-inset-0 tw-z-50 tw-bg-black/80 data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0", - t - ), - ...e, - ref: n - } -)); -Mi.displayName = vt.Overlay.displayName; -const Qc = Xe( - "pr-twp tw-fixed tw-z-50 tw-gap-4 tw-bg-background tw-p-6 tw-shadow-lg tw-transition tw-ease-in-out data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-duration-300 data-[state=open]:tw-duration-500", - { - variants: { - side: { - top: "tw-inset-x-0 tw-top-0 tw-border-b data-[state=closed]:tw-slide-out-to-top data-[state=open]:tw-slide-in-from-top", - bottom: "tw-inset-x-0 tw-bottom-0 tw-border-t data-[state=closed]:tw-slide-out-to-bottom data-[state=open]:tw-slide-in-from-bottom", - left: "tw-inset-y-0 tw-left-0 tw-h-full tw-w-3/4 tw-border-r data-[state=closed]:tw-slide-out-to-left data-[state=open]:tw-slide-in-from-left sm:tw-max-w-sm", - right: "tw-inset-y-0 tw-right-0 tw-h-full tw-w-3/4 tw- tw-border-l data-[state=closed]:tw-slide-out-to-right data-[state=open]:tw-slide-in-from-right sm:tw-max-w-sm" - } - }, - defaultVariants: { - side: "right" - } - } -), Di = M.forwardRef(({ side: t = "right", className: e, children: n, ...r }, o) => /* @__PURE__ */ N(Zc, { children: [ - /* @__PURE__ */ s(Mi, {}), - /* @__PURE__ */ N(vt.Content, { ref: o, className: x(Qc({ side: t }), e), ...r, children: [ - n, - /* @__PURE__ */ N(vt.Close, { className: "tw-absolute tw-right-4 tw-top-4 tw-rounded-sm tw-opacity-70 tw-ring-offset-background tw-transition-opacity hover:tw-opacity-100 focus:tw-outline-none focus:tw-ring-2 focus:tw-ring-ring focus:tw-ring-offset-2 disabled:tw-pointer-events-none data-[state=open]:tw-bg-secondary", children: [ - /* @__PURE__ */ s(Qa, { className: "tw-h-4 tw-w-4" }), - /* @__PURE__ */ s("span", { className: "tw-sr-only", children: "Close" }) - ] }) - ] }) -] })); -Di.displayName = vt.Content.displayName; -const td = M.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( - vt.Title, - { - ref: n, - className: x("tw-text-lg tw-font-semibold tw-text-foreground", t), - ...e - } -)); -td.displayName = vt.Title.displayName; -const ed = M.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( - vt.Description, - { - ref: n, - className: x("tw-text-sm tw-text-muted-foreground", t), - ...e - } -)); -ed.displayName = vt.Description.displayName; -function aa({ className: t, ...e }) { +ho.displayName = ri.Root.displayName; +function oa({ className: t, ...e }) { return /* @__PURE__ */ s( "div", { - className: x("pr-twp tw-animate-pulse tw-rounded-md tw-bg-muted", t), + className: N("pr-twp tw-animate-pulse tw-rounded-md tw-bg-muted", t), ...e } ); } -const nd = En.Provider, rd = En.Root, od = En.Trigger, Bi = E.forwardRef(({ className: t, sideOffset: e = 4, ...n }, r) => /* @__PURE__ */ s( +const Wc = En.Provider, qc = En.Root, Kc = En.Trigger, Ii = S.forwardRef(({ className: t, sideOffset: e = 4, ...n }, r) => /* @__PURE__ */ s( En.Content, { ref: r, sideOffset: e, - className: x( + className: N( "pr-twp tw-z-50 tw-overflow-hidden tw-rounded-md tw-border tw-bg-popover tw-px-3 tw-py-1.5 tw-text-sm tw-text-popover-foreground tw-shadow-md tw-animate-in tw-fade-in-0 tw-zoom-in-95 data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=closed]:tw-zoom-out-95 data-[side=bottom]:tw-slide-in-from-top-2 data-[side=left]:tw-slide-in-from-right-2 data-[side=right]:tw-slide-in-from-left-2 data-[side=top]:tw-slide-in-from-bottom-2", t ), ...n } )); -Bi.displayName = En.Content.displayName; -const $r = 768; -function ad() { - const [t, e] = E.useState(void 0); - return E.useEffect(() => { - const n = window.matchMedia(`(max-width: ${$r - 1}px)`), r = () => { - e(window.innerWidth < $r); - }; - return n.addEventListener("change", r), e(window.innerWidth < $r), () => n.removeEventListener("change", r); - }, []), !!t; -} -const id = "sidebar:state", sd = 60 * 60 * 24 * 7, ld = "16rem", cd = "18rem", dd = "3rem", pd = "b", ji = E.createContext(void 0); +Ii.displayName = En.Content.displayName; +const Jc = "16rem", Zc = "3rem", Qc = "b", Ai = S.createContext(void 0); function cr() { - const t = E.useContext(ji); + const t = S.useContext(Ai); if (!t) throw new Error("useSidebar must be used within a SidebarProvider."); return t; } -const Vi = E.forwardRef( +const Mi = S.forwardRef( ({ defaultOpen: t = !0, open: e, @@ -2622,43 +2556,40 @@ const Vi = E.forwardRef( children: a, ...i }, l) => { - const c = ad(), [d, p] = E.useState(!1), [f, w] = E.useState(t), g = e ?? f, v = E.useCallback( - (_) => { - const C = typeof _ == "function" ? _(g) : _; - n ? n(C) : w(C), document.cookie = `${id}=${C}; path=/; max-age=${sd}`; + const [c, d] = S.useState(t), p = e ?? c, f = S.useCallback( + (m) => { + const h = typeof m == "function" ? m(p) : m; + n ? n(h) : d(h); }, - [n, g] - ), m = E.useCallback(() => c ? p((_) => !_) : v((_) => !_), [c, v, p]); - E.useEffect(() => { - const _ = (C) => { - C.key === pd && (C.metaKey || C.ctrlKey) && (C.preventDefault(), m()); + [n, p] + ), w = S.useCallback(() => f((m) => !m), [f]); + S.useEffect(() => { + const m = (h) => { + h.key === Qc && (h.metaKey || h.ctrlKey) && (h.preventDefault(), w()); }; - return window.addEventListener("keydown", _), () => window.removeEventListener("keydown", _); - }, [m]); - const h = g ? "expanded" : "collapsed", S = E.useMemo( + return window.addEventListener("keydown", m), () => window.removeEventListener("keydown", m); + }, [w]); + const g = p ? "expanded" : "collapsed", v = S.useMemo( () => ({ - state: h, - open: g, - setOpen: v, - isMobile: c, - openMobile: d, - setOpenMobile: p, - toggleSidebar: m + state: g, + open: p, + setOpen: f, + toggleSidebar: w }), - [h, g, v, c, d, p, m] + [g, p, f, w] ); - return /* @__PURE__ */ s(ji.Provider, { value: S, children: /* @__PURE__ */ s(nd, { delayDuration: 0, children: /* @__PURE__ */ s( + return /* @__PURE__ */ s(Ai.Provider, { value: v, children: /* @__PURE__ */ s(Wc, { delayDuration: 0, children: /* @__PURE__ */ s( "div", { style: ( // eslint-disable-next-line no-type-assertion/no-type-assertion { - "--sidebar-width": ld, - "--sidebar-width-icon": dd, + "--sidebar-width": Jc, + "--sidebar-width-icon": Zc, ...o } ), - className: x( + className: N( // Removed tw-min-h-svh "tw-group/sidebar-wrapper pr-twp tw-flex tw-w-full has-[[data-variant=inset]]:tw-bg-sidebar", r @@ -2670,8 +2601,8 @@ const Vi = E.forwardRef( ) }) }); } ); -Vi.displayName = "SidebarProvider"; -const zi = E.forwardRef( +Mi.displayName = "SidebarProvider"; +const Di = S.forwardRef( ({ side: t = "left", variant: e = "sidebar", @@ -2680,11 +2611,11 @@ const zi = E.forwardRef( children: o, ...a }, i) => { - const { isMobile: l, state: c, openMobile: d, setOpenMobile: p } = cr(); + const { state: l } = cr(); return n === "none" ? /* @__PURE__ */ s( "div", { - className: x( + className: N( "tw-flex tw-h-full tw-w-[--sidebar-width] tw-flex-col tw-bg-sidebar tw-text-sidebar-foreground", r ), @@ -2692,35 +2623,20 @@ const zi = E.forwardRef( ...a, children: o } - ) : l ? /* @__PURE__ */ s(Jc, { open: d, onOpenChange: p, ...a, children: /* @__PURE__ */ s( - Di, - { - "data-sidebar": "sidebar", - "data-mobile": "true", - className: "tw-w-[--sidebar-width] tw-bg-sidebar tw-p-0 tw-text-sidebar-foreground [&>button]:tw-hidden", - style: ( - // eslint-disable-next-line no-type-assertion/no-type-assertion - { - "--sidebar-width": cd - } - ), - side: t, - children: /* @__PURE__ */ s("div", { className: "tw-flex tw-h-full tw-w-full tw-flex-col", children: o }) - } - ) }) : /* @__PURE__ */ N( + ) : /* @__PURE__ */ x( "div", { ref: i, className: "tw-group tw-peer tw-hidden tw-text-sidebar-foreground md:tw-block", - "data-state": c, - "data-collapsible": c === "collapsed" ? n : "", + "data-state": l, + "data-collapsible": l === "collapsed" ? n : "", "data-variant": e, "data-side": t, children: [ /* @__PURE__ */ s( "div", { - className: x( + className: N( "tw-relative tw-h-svh tw-w-[--sidebar-width] tw-bg-transparent tw-transition-[width] tw-duration-200 tw-ease-linear", "group-data-[collapsible=offcanvas]:tw-w-0", "group-data-[side=right]:tw-rotate-180", @@ -2731,7 +2647,7 @@ const zi = E.forwardRef( /* @__PURE__ */ s( "div", { - className: x( + className: N( // Switched tw-fixed to tw-absolute here to scope the sidebar inside of it's container "tw-absolute tw-inset-y-0 tw-z-10 tw-hidden tw-h-svh tw-w-[--sidebar-width] tw-transition-[left,right,width] tw-duration-200 tw-ease-linear md:tw-flex", t === "left" ? "tw-left-0 group-data-[collapsible=offcanvas]:tw-left-[calc(var(--sidebar-width)*-1)]" : "tw-right-0 group-data-[collapsible=offcanvas]:tw-right-[calc(var(--sidebar-width)*-1)]", @@ -2755,30 +2671,30 @@ const zi = E.forwardRef( ); } ); -zi.displayName = "Sidebar"; -const ud = E.forwardRef(({ className: t, onClick: e, ...n }, r) => { +Di.displayName = "Sidebar"; +const td = S.forwardRef(({ className: t, onClick: e, ...n }, r) => { const { toggleSidebar: o } = cr(); - return /* @__PURE__ */ N( + return /* @__PURE__ */ x( gt, { ref: r, "data-sidebar": "trigger", variant: "ghost", size: "icon", - className: x("tw-h-7 tw-w-7", t), + className: N("tw-h-7 tw-w-7", t), onClick: (a) => { e == null || e(a), o(); }, ...n, children: [ - /* @__PURE__ */ s(ml, {}), + /* @__PURE__ */ s(ul, {}), /* @__PURE__ */ s("span", { className: "tw-sr-only", children: "Toggle Sidebar" }) ] } ); }); -ud.displayName = "SidebarTrigger"; -const wd = E.forwardRef( +td.displayName = "SidebarTrigger"; +const ed = S.forwardRef( ({ className: t, ...e }, n) => { const { toggleSidebar: r } = cr(); return /* @__PURE__ */ s( @@ -2791,7 +2707,7 @@ const wd = E.forwardRef( tabIndex: -1, onClick: r, title: "Toggle Sidebar", - className: x( + className: N( "tw-absolute tw-inset-y-0 tw-z-20 tw-hidden tw-w-4 tw--translate-x-1/2 tw-transition-all tw-ease-linear after:tw-absolute after:tw-inset-y-0 after:tw-left-1/2 after:tw-w-[2px] hover:after:tw-bg-sidebar-border group-data-[side=left]:tw--right-4 group-data-[side=right]:tw-left-0 sm:tw-flex", "[[data-side=left]_&]:tw-cursor-w-resize [[data-side=right]_&]:tw-cursor-e-resize", "[[data-side=left][data-state=collapsed]_&]:tw-cursor-e-resize [[data-side=right][data-state=collapsed]_&]:tw-cursor-w-resize", @@ -2805,13 +2721,13 @@ const wd = E.forwardRef( ); } ); -wd.displayName = "SidebarRail"; -const Li = E.forwardRef( +ed.displayName = "SidebarRail"; +const Bi = S.forwardRef( ({ className: t, ...e }, n) => /* @__PURE__ */ s( "main", { ref: n, - className: x( + className: N( // Removed tw-min-h-svh "tw-relative tw-flex tw-flex-1 tw-flex-col tw-bg-background", "peer-data-[variant=inset]:tw-min-h-[calc(100svh-theme(spacing.4))] md:peer-data-[variant=inset]:tw-m-2 md:peer-data-[state=collapsed]:peer-data-[variant=inset]:tw-ml-2 md:peer-data-[variant=inset]:tw-ml-0 md:peer-data-[variant=inset]:tw-rounded-xl md:peer-data-[variant=inset]:tw-shadow", @@ -2821,61 +2737,61 @@ const Li = E.forwardRef( } ) ); -Li.displayName = "SidebarInset"; -const fd = E.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( - Ye, +Bi.displayName = "SidebarInset"; +const nd = S.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( + Xe, { ref: n, "data-sidebar": "input", - className: x( + className: N( "tw-h-8 tw-w-full tw-bg-background tw-shadow-none focus-visible:tw-ring-2 focus-visible:tw-ring-sidebar-ring", t ), ...e } )); -fd.displayName = "SidebarInput"; -const md = E.forwardRef( +nd.displayName = "SidebarInput"; +const rd = S.forwardRef( ({ className: t, ...e }, n) => /* @__PURE__ */ s( "div", { ref: n, "data-sidebar": "header", - className: x("tw-flex tw-flex-col tw-gap-2 tw-p-2", t), + className: N("tw-flex tw-flex-col tw-gap-2 tw-p-2", t), ...e } ) ); -md.displayName = "SidebarHeader"; -const hd = E.forwardRef( +rd.displayName = "SidebarHeader"; +const od = S.forwardRef( ({ className: t, ...e }, n) => /* @__PURE__ */ s( "div", { ref: n, "data-sidebar": "footer", - className: x("tw-flex tw-flex-col tw-gap-2 tw-p-2", t), + className: N("tw-flex tw-flex-col tw-gap-2 tw-p-2", t), ...e } ) ); -hd.displayName = "SidebarFooter"; -const gd = E.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( - go, +od.displayName = "SidebarFooter"; +const ad = S.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( + ho, { ref: n, "data-sidebar": "separator", - className: x("tw-mx-2 tw-w-auto tw-bg-sidebar-border", t), + className: N("tw-mx-2 tw-w-auto tw-bg-sidebar-border", t), ...e } )); -gd.displayName = "SidebarSeparator"; -const Fi = E.forwardRef( +ad.displayName = "SidebarSeparator"; +const ji = S.forwardRef( ({ className: t, ...e }, n) => /* @__PURE__ */ s( "div", { ref: n, "data-sidebar": "content", - className: x( + className: N( "tw-flex tw-min-h-0 tw-flex-1 tw-flex-col tw-gap-2 tw-overflow-auto group-data-[collapsible=icon]:tw-overflow-hidden", t ), @@ -2883,25 +2799,25 @@ const Fi = E.forwardRef( } ) ); -Fi.displayName = "SidebarContent"; -const Kr = E.forwardRef( +ji.displayName = "SidebarContent"; +const qr = S.forwardRef( ({ className: t, ...e }, n) => /* @__PURE__ */ s( "div", { ref: n, "data-sidebar": "group", - className: x("tw-relative tw-flex tw-w-full tw-min-w-0 tw-flex-col tw-p-2", t), + className: N("tw-relative tw-flex tw-w-full tw-min-w-0 tw-flex-col tw-p-2", t), ...e } ) ); -Kr.displayName = "SidebarGroup"; -const Jr = E.forwardRef(({ className: t, asChild: e = !1, ...n }, r) => /* @__PURE__ */ s( +qr.displayName = "SidebarGroup"; +const Kr = S.forwardRef(({ className: t, asChild: e = !1, ...n }, r) => /* @__PURE__ */ s( e ? He : "div", { ref: r, "data-sidebar": "group-label", - className: x( + className: N( "tw-flex tw-h-8 tw-shrink-0 tw-items-center tw-rounded-md tw-px-2 tw-text-xs tw-font-medium tw-text-sidebar-foreground/70 tw-outline-none tw-ring-sidebar-ring tw-transition-[margin,opa] tw-duration-200 tw-ease-linear focus-visible:tw-ring-2 [&>svg]:tw-size-4 [&>svg]:tw-shrink-0", "group-data-[collapsible=icon]:tw--mt-8 group-data-[collapsible=icon]:tw-opacity-0", t @@ -2909,13 +2825,13 @@ const Jr = E.forwardRef(({ className: t, asChild: e = !1, ...n }, r) => /* @__PU ...n } )); -Jr.displayName = "SidebarGroupLabel"; -const bd = E.forwardRef(({ className: t, asChild: e = !1, ...n }, r) => /* @__PURE__ */ s( +Kr.displayName = "SidebarGroupLabel"; +const id = S.forwardRef(({ className: t, asChild: e = !1, ...n }, r) => /* @__PURE__ */ s( e ? He : "button", { ref: r, "data-sidebar": "group-action", - className: x( + className: N( "tw-absolute tw-right-3 tw-top-3.5 tw-flex tw-aspect-square tw-w-5 tw-items-center tw-justify-center tw-rounded-md tw-p-0 tw-text-sidebar-foreground tw-outline-none tw-ring-sidebar-ring tw-transition-transform hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground focus-visible:tw-ring-2 [&>svg]:tw-size-4 [&>svg]:tw-shrink-0", // Increases the hit area of the button on mobile. "after:tw-absolute after:tw--inset-2 after:md:tw-hidden", @@ -2925,44 +2841,44 @@ const bd = E.forwardRef(({ className: t, asChild: e = !1, ...n }, r) => /* @__PU ...n } )); -bd.displayName = "SidebarGroupAction"; -const Zr = E.forwardRef( +id.displayName = "SidebarGroupAction"; +const Jr = S.forwardRef( ({ className: t, ...e }, n) => /* @__PURE__ */ s( "div", { ref: n, "data-sidebar": "group-content", - className: x("tw-w-full tw-text-sm", t), + className: N("tw-w-full tw-text-sm", t), ...e } ) ); -Zr.displayName = "SidebarGroupContent"; -const Ui = E.forwardRef( +Jr.displayName = "SidebarGroupContent"; +const Vi = S.forwardRef( ({ className: t, ...e }, n) => /* @__PURE__ */ s( "ul", { ref: n, "data-sidebar": "menu", - className: x("tw-flex tw-w-full tw-min-w-0 tw-flex-col tw-gap-1", t), + className: N("tw-flex tw-w-full tw-min-w-0 tw-flex-col tw-gap-1", t), ...e } ) ); -Ui.displayName = "SidebarMenu"; -const Gi = E.forwardRef( +Vi.displayName = "SidebarMenu"; +const zi = S.forwardRef( ({ className: t, ...e }, n) => /* @__PURE__ */ s( "li", { ref: n, "data-sidebar": "menu-item", - className: x("tw-group/menu-item tw-relative", t), + className: N("tw-group/menu-item tw-relative", t), ...e } ) ); -Gi.displayName = "SidebarMenuItem"; -const vd = Xe( +zi.displayName = "SidebarMenuItem"; +const sd = kn( // Removed data-[active=true]:tw-bg-sidebar-accent "tw-peer/menu-button tw-flex tw-w-full tw-items-center tw-gap-2 tw-overflow-hidden tw-rounded-md tw-p-2 tw-text-left tw-text-sm tw-outline-none tw-ring-sidebar-ring tw-transition-[width,height,padding] hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground focus-visible:tw-ring-2 active:tw-bg-sidebar-accent active:tw-text-sidebar-accent-foreground disabled:tw-pointer-events-none disabled:tw-opacity-50 tw-group-has-[[data-sidebar=menu-action]]/menu-item:pr-8 aria-disabled:tw-pointer-events-none aria-disabled:tw-opacity-50 data-[active=true]:tw-font-medium data-[active=true]:tw-text-sidebar-accent-foreground data-[state=open]:hover:tw-bg-sidebar-accent data-[state=open]:hover:tw-text-sidebar-accent-foreground group-data-[collapsible=icon]:tw-!size-8 group-data-[collapsible=icon]:tw-!p-2 [&>span:last-child]:tw-truncate [&>svg]:tw-size-4 [&>svg]:tw-shrink-0", { @@ -2982,7 +2898,7 @@ const vd = Xe( size: "default" } } -), Hi = E.forwardRef( +), Li = S.forwardRef( ({ asChild: t = !1, isActive: e = !1, @@ -2992,40 +2908,32 @@ const vd = Xe( className: a, ...i }, l) => { - const c = t ? He : "button", { isMobile: d, state: p } = cr(), f = /* @__PURE__ */ s( + const c = t ? He : "button", { state: d } = cr(), p = /* @__PURE__ */ s( c, { ref: l, "data-sidebar": "menu-button", "data-size": r, "data-active": e, - className: x(vd({ variant: n, size: r }), a), + className: N(sd({ variant: n, size: r }), a), ...i } ); return o ? (typeof o == "string" && (o = { children: o - }), /* @__PURE__ */ N(rd, { children: [ - /* @__PURE__ */ s(od, { asChild: !0, children: f }), - /* @__PURE__ */ s( - Bi, - { - side: "right", - align: "center", - hidden: p !== "collapsed" || d, - ...o - } - ) - ] })) : f; + }), /* @__PURE__ */ x(qc, { children: [ + /* @__PURE__ */ s(Kc, { asChild: !0, children: p }), + /* @__PURE__ */ s(Ii, { side: "right", align: "center", hidden: d !== "collapsed", ...o }) + ] })) : p; } ); -Hi.displayName = "SidebarMenuButton"; -const yd = E.forwardRef(({ className: t, asChild: e = !1, showOnHover: n = !1, ...r }, o) => /* @__PURE__ */ s( +Li.displayName = "SidebarMenuButton"; +const ld = S.forwardRef(({ className: t, asChild: e = !1, showOnHover: n = !1, ...r }, o) => /* @__PURE__ */ s( e ? He : "button", { ref: o, "data-sidebar": "menu-action", - className: x( + className: N( "tw-peer-hover/menu-button:text-sidebar-accent-foreground tw-absolute tw-right-1 tw-top-1.5 tw-flex tw-aspect-square tw-w-5 tw-items-center tw-justify-center tw-rounded-md tw-p-0 tw-text-sidebar-foreground tw-outline-none tw-ring-sidebar-ring tw-transition-transform hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground focus-visible:tw-ring-2 [&>svg]:tw-size-4 [&>svg]:tw-shrink-0", // Increases the hit area of the button on mobile. "after:tw-absolute after:tw--inset-2 after:md:tw-hidden", @@ -3039,14 +2947,14 @@ const yd = E.forwardRef(({ className: t, asChild: e = !1, showOnHover: n = !1, . ...r } )); -yd.displayName = "SidebarMenuAction"; -const xd = E.forwardRef( +ld.displayName = "SidebarMenuAction"; +const cd = S.forwardRef( ({ className: t, ...e }, n) => /* @__PURE__ */ s( "div", { ref: n, "data-sidebar": "menu-badge", - className: x( + className: N( "tw-pointer-events-none tw-absolute tw-right-1 tw-flex tw-h-5 tw-min-w-5 tw-select-none tw-items-center tw-justify-center tw-rounded-md tw-px-1 tw-text-xs tw-font-medium tw-tabular-nums tw-text-sidebar-foreground", "tw-peer-hover/menu-button:text-sidebar-accent-foreground tw-peer-data-[active=true]/menu-button:text-sidebar-accent-foreground", "tw-peer-data-[size=sm]/menu-button:top-1", @@ -3059,20 +2967,20 @@ const xd = E.forwardRef( } ) ); -xd.displayName = "SidebarMenuBadge"; -const Nd = E.forwardRef(({ className: t, showIcon: e = !1, ...n }, r) => { - const o = E.useMemo(() => `${Math.floor(Math.random() * 40) + 50}%`, []); - return /* @__PURE__ */ N( +cd.displayName = "SidebarMenuBadge"; +const dd = S.forwardRef(({ className: t, showIcon: e = !1, ...n }, r) => { + const o = S.useMemo(() => `${Math.floor(Math.random() * 40) + 50}%`, []); + return /* @__PURE__ */ x( "div", { ref: r, "data-sidebar": "menu-skeleton", - className: x("tw-flex tw-h-8 tw-items-center tw-gap-2 tw-rounded-md tw-px-2", t), + className: N("tw-flex tw-h-8 tw-items-center tw-gap-2 tw-rounded-md tw-px-2", t), ...n, children: [ - e && /* @__PURE__ */ s(aa, { className: "tw-size-4 tw-rounded-md", "data-sidebar": "menu-skeleton-icon" }), + e && /* @__PURE__ */ s(oa, { className: "tw-size-4 tw-rounded-md", "data-sidebar": "menu-skeleton-icon" }), /* @__PURE__ */ s( - aa, + oa, { className: "tw-h-4 tw-max-w-[--skeleton-width] tw-flex-1", "data-sidebar": "menu-skeleton-text", @@ -3088,14 +2996,14 @@ const Nd = E.forwardRef(({ className: t, showIcon: e = !1, ...n }, r) => { } ); }); -Nd.displayName = "SidebarMenuSkeleton"; -const kd = E.forwardRef( +dd.displayName = "SidebarMenuSkeleton"; +const pd = S.forwardRef( ({ className: t, ...e }, n) => /* @__PURE__ */ s( "ul", { ref: n, "data-sidebar": "menu-sub", - className: x( + className: N( "tw-mx-3.5 tw-flex tw-min-w-0 tw-translate-x-px tw-flex-col tw-gap-1 tw-border-l tw-border-sidebar-border tw-px-2.5 tw-py-0.5", "group-data-[collapsible=icon]:tw-hidden", t @@ -3104,19 +3012,19 @@ const kd = E.forwardRef( } ) ); -kd.displayName = "SidebarMenuSub"; -const Ed = E.forwardRef( +pd.displayName = "SidebarMenuSub"; +const ud = S.forwardRef( ({ ...t }, e) => /* @__PURE__ */ s("li", { ref: e, ...t }) ); -Ed.displayName = "SidebarMenuSubItem"; -const Sd = E.forwardRef(({ asChild: t = !1, size: e = "md", isActive: n, className: r, ...o }, a) => /* @__PURE__ */ s( +ud.displayName = "SidebarMenuSubItem"; +const wd = S.forwardRef(({ asChild: t = !1, size: e = "md", isActive: n, className: r, ...o }, a) => /* @__PURE__ */ s( t ? He : "a", { ref: a, "data-sidebar": "menu-sub-button", "data-size": e, "data-active": n, - className: x( + className: N( "tw-flex tw-h-7 tw-min-w-0 tw--translate-x-px tw-items-center tw-gap-2 tw-overflow-hidden tw-rounded-md tw-px-2 tw-text-sidebar-foreground tw-outline-none tw-ring-sidebar-ring hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground focus-visible:tw-ring-2 active:tw-bg-sidebar-accent active:tw-text-sidebar-accent-foreground disabled:tw-pointer-events-none disabled:tw-opacity-50 aria-disabled:tw-pointer-events-none aria-disabled:tw-opacity-50 [&>span:last-child]:tw-truncate [&>svg]:tw-size-4 [&>svg]:tw-shrink-0 [&>svg]:tw-text-sidebar-accent-foreground", "data-[active=true]:tw-bg-sidebar-accent data-[active=true]:tw-text-sidebar-accent-foreground", e === "sm" && "tw-text-xs", @@ -3127,8 +3035,8 @@ const Sd = E.forwardRef(({ asChild: t = !1, size: e = "md", isActive: n, classNa ...o } )); -Sd.displayName = "SidebarMenuSubButton"; -function Td({ +wd.displayName = "SidebarMenuSubButton"; +function fd({ id: t, extensionLabels: e, projectOptions: n, @@ -3138,35 +3046,35 @@ function Td({ projectsSidebarGroupLabel: i, buttonPlaceholderText: l }) { - const c = Et( + const c = kt( (f, w) => { r(f, w); }, [r] - ), d = Et( + ), d = kt( (f) => { const w = n.find((g) => g.projectId === f); return w ? w.projectName : f; }, [n] - ), p = Et( + ), p = kt( (f) => !o.projectId && f === o.label, [o] ); return /* @__PURE__ */ s( - zi, + Di, { id: t, collapsible: "none", variant: "inset", className: "tw-w-96 tw-gap-2 tw-overflow-y-auto tw-rounded tw-bg-slate-100", - children: /* @__PURE__ */ N(Fi, { children: [ - /* @__PURE__ */ N(Kr, { children: [ - /* @__PURE__ */ s(Jr, { className: "tw-text-sm tw-text-gray-400", children: a }), - /* @__PURE__ */ s(Zr, { children: /* @__PURE__ */ s(Ui, { children: e.map((f) => /* @__PURE__ */ s(Gi, { children: /* @__PURE__ */ s( - Hi, + children: /* @__PURE__ */ x(ji, { children: [ + /* @__PURE__ */ x(qr, { children: [ + /* @__PURE__ */ s(Kr, { className: "tw-text-sm tw-text-gray-400", children: a }), + /* @__PURE__ */ s(Jr, { children: /* @__PURE__ */ s(Vi, { children: e.map((f) => /* @__PURE__ */ s(zi, { children: /* @__PURE__ */ s( + Li, { - className: x( + className: N( "tw-rounded tw-py-2 tw-text-sm tw-text-gray-500 hover:tw-bg-white hover:tw-text-gray-900 hover:tw-shadow-sm active:tw-bg-white", { "tw-bg-white tw-text-gray-900 tw-shadow-sm": p(f) } ), @@ -3176,10 +3084,10 @@ function Td({ } ) }, f)) }) }) ] }), - /* @__PURE__ */ N(Kr, { children: [ - /* @__PURE__ */ s(Jr, { className: "tw-text-sm tw-text-gray-400", children: i }), - /* @__PURE__ */ s(Zr, { className: "tw-pl-3", children: /* @__PURE__ */ s( - qr, + /* @__PURE__ */ x(qr, { children: [ + /* @__PURE__ */ s(Kr, { className: "tw-text-sm tw-text-gray-400", children: i }), + /* @__PURE__ */ s(Jr, { className: "tw-pl-3", children: /* @__PURE__ */ s( + Wr, { popoverContentClassName: "tw-z-[1000]", options: n.flatMap((f) => f.projectId), @@ -3197,7 +3105,7 @@ function Td({ } ); } -function Th({ +function fh({ id: t, extensionLabels: e, projectOptions: n, @@ -3209,18 +3117,18 @@ function Th({ projectsSidebarGroupLabel: c, buttonPlaceholderText: d }) { - return /* @__PURE__ */ N("div", { className: "tw-box-border tw-flex tw-h-full tw-flex-col tw-p-3", children: [ + return /* @__PURE__ */ x("div", { className: "tw-box-border tw-flex tw-h-full tw-flex-col tw-p-3", children: [ /* @__PURE__ */ s("div", { className: "tw-box-border tw-flex tw-items-center tw-justify-center tw-py-4", children: /* @__PURE__ */ s( - Pi, + Ri, { className: "tw-w-9/12", onSearch: i, placeholder: "Search app settings, extension settings, and project settings" } ) }), - /* @__PURE__ */ N(Vi, { id: t, className: "tw-h-full tw-flex-1 tw-gap-4 tw-overflow-auto", children: [ + /* @__PURE__ */ x(Mi, { id: t, className: "tw-h-full tw-flex-1 tw-gap-4 tw-overflow-auto", children: [ /* @__PURE__ */ s( - Td, + fd, { extensionLabels: e, projectOptions: n, @@ -3231,41 +3139,41 @@ function Th({ buttonPlaceholderText: d } ), - /* @__PURE__ */ s(Li, { className: "tw-overflow-y-auto", children: r }) + /* @__PURE__ */ s(Bi, { className: "tw-overflow-y-auto", children: r }) ] }) ] }); } -const ne = "scrBook", Cd = "scrRef", we = "source", Od = "details", Rd = "Scripture Reference", _d = "Scripture Book", Xi = "Type", Pd = "Details"; -function $d(t, e) { +const ne = "scrBook", md = "scrRef", we = "source", hd = "details", gd = "Scripture Reference", bd = "Scripture Book", Fi = "Type", vd = "Details"; +function yd(t, e) { const n = e ?? !1; return [ { accessorFn: (r) => `${ot.bookNumberToId(r.start.bookNum)} ${r.start.chapterNum}:${r.start.verseNum}`, id: ne, - header: (t == null ? void 0 : t.scriptureReferenceColumnName) ?? Rd, + header: (t == null ? void 0 : t.scriptureReferenceColumnName) ?? gd, cell: (r) => { const o = r.row.original; return r.row.getIsGrouped() ? ot.bookNumberToEnglishName(o.start.bookNum) : r.row.groupingColumnId === ne ? Or(o.start) : void 0; }, getGroupingValue: (r) => r.start.bookNum, - sortingFn: (r, o) => Hr(r.original.start, o.original.start), + sortingFn: (r, o) => Gr(r.original.start, o.original.start), enableGrouping: !0 }, { accessorFn: (r) => Or(r.start), - id: Cd, + id: md, header: void 0, cell: (r) => { const o = r.row.original; return r.row.getIsGrouped() ? void 0 : Or(o.start); }, - sortingFn: (r, o) => Hr(r.original.start, o.original.start), + sortingFn: (r, o) => Gr(r.original.start, o.original.start), enableGrouping: !1 }, { accessorFn: (r) => r.source.displayName, id: we, - header: n ? (t == null ? void 0 : t.typeColumnName) ?? Xi : void 0, + header: n ? (t == null ? void 0 : t.typeColumnName) ?? Fi : void 0, cell: (r) => n || r.row.getIsGrouped() ? r.getValue() : void 0, getGroupingValue: (r) => r.source.id, sortingFn: (r, o) => r.original.source.displayName.localeCompare(o.original.source.displayName), @@ -3273,23 +3181,23 @@ function $d(t, e) { }, { accessorFn: (r) => r.detail, - id: Od, - header: (t == null ? void 0 : t.detailsColumnName) ?? Pd, + id: hd, + header: (t == null ? void 0 : t.detailsColumnName) ?? vd, cell: (r) => r.getValue(), enableGrouping: !1 } ]; } -const Id = (t) => { +const xd = (t) => { if (!("offset" in t.start)) throw new Error("No offset available in range start"); if (t.end && !("offset" in t.end)) throw new Error("No offset available in range end"); const { offset: e } = t.start; let n = 0; - return t.end && ({ offset: n } = t.end), !t.end || Hr(t.start, t.end) === 0 ? `${Rr(t.start)}+${e}` : `${Rr(t.start)}+${e}-${Rr(t.end)}+${n}`; -}, ia = (t) => `${Id({ start: t.start, end: t.end })} ${t.source.displayName} ${t.detail}`; -function Ch({ + return t.end && ({ offset: n } = t.end), !t.end || Gr(t.start, t.end) === 0 ? `${Rr(t.start)}+${e}` : `${Rr(t.start)}+${e}-${Rr(t.end)}+${n}`; +}, aa = (t) => `${xd({ start: t.start, end: t.end })} ${t.source.displayName} ${t.detail}`; +function mh({ sources: t, showColumnHeaders: e = !1, showSourceColumn: n = !1, @@ -3300,14 +3208,14 @@ function Ch({ onRowSelected: l, direction: c = "ltr" }) { - const [d, p] = ut([]), [f, w] = ut([{ id: ne, desc: !1 }]), [g, v] = ut({}), m = It( - () => t.flatMap((O) => O.data.map(($) => ({ - ...$, - source: O.source + const [d, p] = ut([]), [f, w] = ut([{ id: ne, desc: !1 }]), [g, v] = ut({}), m = $t( + () => t.flatMap((C) => C.data.map((P) => ({ + ...P, + source: C.source }))), [t] - ), h = It( - () => $d( + ), h = $t( + () => yd( { scriptureReferenceColumnName: r, typeColumnName: a, @@ -3323,7 +3231,7 @@ function Ch({ { id: ne, desc: !1 } ]) : w([{ id: ne, desc: !1 }]); }, [d]); - const S = ei({ + const T = Qa({ data: m, columns: h, state: { @@ -3334,50 +3242,50 @@ function Ch({ onGroupingChange: p, onSortingChange: w, onRowSelectionChange: v, - getExpandedRowModel: $l(), - getGroupedRowModel: Il(), - getCoreRowModel: ni(), - getSortedRowModel: ri(), - getRowId: ia, + getExpandedRowModel: Rl(), + getGroupedRowModel: _l(), + getCoreRowModel: ti(), + getSortedRowModel: ei(), + getRowId: aa, autoResetExpanded: !1, enableMultiRowSelection: !1, enableSubRowSelection: !1 }); ae(() => { if (l) { - const O = S.getSelectedRowModel().rowsById, $ = Object.keys(O); - if ($.length === 1) { - const k = m.find((B) => ia(B) === $[0]) || void 0; + const C = T.getSelectedRowModel().rowsById, P = Object.keys(C); + if (P.length === 1) { + const k = m.find((B) => aa(B) === P[0]) || void 0; k && l(k); } } - }, [g, m, l, S]); - const _ = o ?? _d, C = a ?? Xi, T = [ + }, [g, m, l, T]); + const A = o ?? bd, R = a ?? Fi, E = [ { label: "No Grouping", value: [] }, - { label: `Group by ${_}`, value: [ne] }, - { label: `Group by ${C}`, value: [we] }, + { label: `Group by ${A}`, value: [ne] }, + { label: `Group by ${R}`, value: [we] }, { - label: `Group by ${_} and ${C}`, + label: `Group by ${A} and ${R}`, value: [ne, we] }, { - label: `Group by ${C} and ${_}`, + label: `Group by ${R} and ${A}`, value: [we, ne] } - ], b = (O) => { - p(JSON.parse(O)); - }, I = (O, $) => { - !O.getIsGrouped() && !O.getIsSelected() && O.getToggleSelectedHandler()($); - }, z = (O, $) => O.getIsGrouped() ? "" : x("banded-row", $ % 2 === 0 ? "even" : "odd"), H = (O, $, k) => { - if (!((O == null ? void 0 : O.length) === 0 || $.depth < k.column.getGroupedIndex())) { - if ($.getIsGrouped()) - switch ($.depth) { + ], b = (C) => { + p(JSON.parse(C)); + }, $ = (C, P) => { + !C.getIsGrouped() && !C.getIsSelected() && C.getToggleSelectedHandler()(P); + }, z = (C, P) => C.getIsGrouped() ? "" : N("banded-row", P % 2 === 0 ? "even" : "odd"), H = (C, P, k) => { + if (!((C == null ? void 0 : C.length) === 0 || P.depth < k.column.getGroupedIndex())) { + if (P.getIsGrouped()) + switch (P.depth) { case 1: return "tw-ps-4"; default: return; } - switch ($.depth) { + switch (P.depth) { case 1: return "tw-ps-8"; case 2: @@ -3387,82 +3295,82 @@ function Ch({ } } }; - return /* @__PURE__ */ N("div", { className: "pr-twp tw-flex tw-h-full tw-w-full tw-flex-col", children: [ - !e && /* @__PURE__ */ N( - gn, + return /* @__PURE__ */ x("div", { className: "pr-twp tw-flex tw-h-full tw-w-full tw-flex-col", children: [ + !e && /* @__PURE__ */ x( + hn, { value: JSON.stringify(d), - onValueChange: (O) => { - b(O); + onValueChange: (C) => { + b(C); }, children: [ - /* @__PURE__ */ s(De, { className: "tw-mb-1 tw-mt-2", children: /* @__PURE__ */ s(bn, {}) }), - /* @__PURE__ */ s(Be, { position: "item-aligned", children: /* @__PURE__ */ s(Mc, { children: T.map((O) => /* @__PURE__ */ s(Gt, { value: JSON.stringify(O.value), children: O.label }, O.label)) }) }) + /* @__PURE__ */ s(De, { className: "tw-mb-1 tw-mt-2", children: /* @__PURE__ */ s(gn, {}) }), + /* @__PURE__ */ s(Be, { position: "item-aligned", children: /* @__PURE__ */ s($c, { children: E.map((C) => /* @__PURE__ */ s(Ut, { value: JSON.stringify(C.value), children: C.label }, C.label)) }) }) ] } ), - /* @__PURE__ */ N(ar, { className: "tw-relative tw-flex tw-flex-col tw-overflow-y-auto tw-p-0", children: [ - e && /* @__PURE__ */ s(ir, { children: S.getHeaderGroups().map((O) => /* @__PURE__ */ s(oe, { children: O.headers.filter(($) => $.column.columnDef.header).map(($) => ( + /* @__PURE__ */ x(ar, { className: "tw-relative tw-flex tw-flex-col tw-overflow-y-auto tw-p-0", children: [ + e && /* @__PURE__ */ s(ir, { children: T.getHeaderGroups().map((C) => /* @__PURE__ */ s(oe, { children: C.headers.filter((P) => P.column.columnDef.header).map((P) => ( /* For sticky column headers to work, we probably need to change the default definition of the shadcn Table component. See https://github.com/shadcn-ui/ui/issues/1151 */ - /* @__PURE__ */ s(vn, { colSpan: $.colSpan, className: "top-0 tw-sticky", children: $.isPlaceholder ? void 0 : /* @__PURE__ */ N("div", { children: [ - $.column.getCanGroup() ? /* @__PURE__ */ s( + /* @__PURE__ */ s(bn, { colSpan: P.colSpan, className: "top-0 tw-sticky", children: P.isPlaceholder ? void 0 : /* @__PURE__ */ x("div", { children: [ + P.column.getCanGroup() ? /* @__PURE__ */ s( gt, { variant: "ghost", - title: `Toggle grouping by ${$.column.columnDef.header}`, - onClick: $.column.getToggleGroupingHandler(), + title: `Toggle grouping by ${P.column.columnDef.header}`, + onClick: P.column.getToggleGroupingHandler(), type: "button", - children: $.column.getIsGrouped() ? "🛑" : "👊 " + children: P.column.getIsGrouped() ? "🛑" : "👊 " } ) : void 0, " ", - dn($.column.columnDef.header, $.getContext()) - ] }) }, $.id) - )) }, O.id)) }), - /* @__PURE__ */ s(sr, { children: S.getRowModel().rows.map((O, $) => /* @__PURE__ */ s( + cn(P.column.columnDef.header, P.getContext()) + ] }) }, P.id) + )) }, C.id)) }), + /* @__PURE__ */ s(sr, { children: T.getRowModel().rows.map((C, P) => /* @__PURE__ */ s( oe, { - "data-state": O.getIsSelected() ? "selected" : "", - className: x(z(O, $)), - onClick: (k) => I(O, k), - children: O.getVisibleCells().map((k) => { + "data-state": C.getIsSelected() ? "selected" : "", + className: N(z(C, P)), + onClick: (k) => $(C, k), + children: C.getVisibleCells().map((k) => { if (!(k.getIsPlaceholder() || k.column.columnDef.enableGrouping && !k.getIsGrouped() && (k.column.columnDef.id !== we || !n))) return /* @__PURE__ */ s( je, { - className: x( + className: N( k.column.columnDef.id, "tw-p-[1px]", - H(d, O, k) + H(d, C, k) ), - children: (() => k.getIsGrouped() ? /* @__PURE__ */ N( + children: (() => k.getIsGrouped() ? /* @__PURE__ */ x( gt, { variant: "link", - onClick: O.getToggleExpandedHandler(), + onClick: C.getToggleExpandedHandler(), type: "button", children: [ - O.getIsExpanded() && /* @__PURE__ */ s(er, {}), - !O.getIsExpanded() && (c === "ltr" ? /* @__PURE__ */ s(Ja, {}) : /* @__PURE__ */ s(hl, {})), + C.getIsExpanded() && /* @__PURE__ */ s(er, {}), + !C.getIsExpanded() && (c === "ltr" ? /* @__PURE__ */ s(Ka, {}) : /* @__PURE__ */ s(wl, {})), " ", - dn(k.column.columnDef.cell, k.getContext()), + cn(k.column.columnDef.cell, k.getContext()), " (", - O.subRows.length, + C.subRows.length, ")" ] } - ) : dn(k.column.columnDef.cell, k.getContext()))() + ) : cn(k.column.columnDef.cell, k.getContext()))() }, k.id ); }) }, - O.id + C.id )) }) ] }) ] }); } -const Ir = { +const $r = { [pt("undefined")]: "Ø", [pt(0)]: "A", [pt(1)]: "B", @@ -3491,25 +3399,25 @@ const Ir = { [pt(24)]: "Y", [pt(25)]: "Z" }; -function Oh({ +function hh({ availableScrollGroupIds: t, scrollGroupId: e, onChangeScrollGroupId: n, localizedStrings: r = {} }) { const o = { - ...Ir, + ...$r, ...Object.fromEntries( Object.entries(r).map( ([a, i]) => [ a, - a === i && a in Ir ? Ir[a] : i + a === i && a in $r ? $r[a] : i ] ) ) }; - return /* @__PURE__ */ N( - gn, + return /* @__PURE__ */ x( + hn, { value: `${e}`, onValueChange: (a) => n( @@ -3517,7 +3425,7 @@ function Oh({ ), children: [ /* @__PURE__ */ s(De, { className: "pr-twp tw-w-auto", children: /* @__PURE__ */ s( - bn, + gn, { placeholder: o[pt(e)] ?? e } @@ -3526,45 +3434,45 @@ function Oh({ Be, { style: { zIndex: 250 }, - children: t.map((a) => /* @__PURE__ */ s(Gt, { value: `${a}`, children: o[pt(a)] }, `${a}`)) + children: t.map((a) => /* @__PURE__ */ s(Ut, { value: `${a}`, children: o[pt(a)] }, `${a}`)) } ) ] } ); } -function Rh({ children: t }) { +function gh({ children: t }) { return /* @__PURE__ */ s("div", { className: "pr-twp tw-grid", children: t }); } -function _h({ +function bh({ primary: t, secondary: e, children: n, isLoading: r = !1, loadingMessage: o }) { - return /* @__PURE__ */ N("div", { className: "tw-flex tw-items-center tw-justify-between tw-space-x-4 tw-py-2", children: [ - /* @__PURE__ */ N("div", { children: [ + return /* @__PURE__ */ x("div", { className: "tw-flex tw-items-center tw-justify-between tw-space-x-4 tw-py-2", children: [ + /* @__PURE__ */ x("div", { children: [ /* @__PURE__ */ s("p", { className: "tw-text-sm tw-font-medium tw-leading-none", children: t }), /* @__PURE__ */ s("p", { className: "tw-whitespace-normal tw-break-words tw-text-sm tw-text-muted-foreground", children: e }) ] }), r ? /* @__PURE__ */ s("p", { className: "tw-text-sm tw-text-muted-foreground", children: o }) : /* @__PURE__ */ s("div", { children: n }) ] }); } -function Ph({ +function vh({ primary: t, secondary: e, includeSeparator: n = !1 }) { - return /* @__PURE__ */ N("div", { className: "tw-space-y-4 tw-py-2", children: [ - /* @__PURE__ */ N("div", { children: [ + return /* @__PURE__ */ x("div", { className: "tw-space-y-4 tw-py-2", children: [ + /* @__PURE__ */ x("div", { children: [ /* @__PURE__ */ s("h3", { className: "tw-text-lg tw-font-medium", children: t }), /* @__PURE__ */ s("p", { className: "tw-text-sm tw-text-muted-foreground", children: e }) ] }), - n ? /* @__PURE__ */ s(go, {}) : "" + n ? /* @__PURE__ */ s(ho, {}) : "" ] }); } -function $h({ +function yh({ id: t, className: e, listItems: n, @@ -3572,22 +3480,22 @@ function $h({ handleSelectListItem: o, createLabel: a }) { - return /* @__PURE__ */ s("div", { id: t, className: e, children: n.map((i) => /* @__PURE__ */ N("div", { className: "tw-m-2 tw-flex tw-items-center", children: [ + return /* @__PURE__ */ s("div", { id: t, className: e, children: n.map((i) => /* @__PURE__ */ x("div", { className: "tw-m-2 tw-flex tw-items-center", children: [ /* @__PURE__ */ s( - ho, + mo, { className: "tw-mr-2 tw-align-middle", checked: r.includes(i), onCheckedChange: (l) => o(i, l) } ), - /* @__PURE__ */ s(Xt, { children: a ? a(i) : i }) + /* @__PURE__ */ s(Ht, { children: a ? a(i) : i }) ] }, i)) }); } -function Ad(t) { +function Nd(t) { return t && t.__esModule && Object.prototype.hasOwnProperty.call(t, "default") ? t.default : t; } -function Md(t) { +function kd(t) { if (t.__esModule) return t; var e = t.default; @@ -3608,7 +3516,7 @@ function Md(t) { }); }), n; } -var bo = {}, Yi = { exports: {} }; +var go = {}, Ui = { exports: {} }; (function(t) { function e(n) { return n && n.__esModule ? n : { @@ -3616,22 +3524,22 @@ var bo = {}, Yi = { exports: {} }; }; } t.exports = e, t.exports.__esModule = !0, t.exports.default = t.exports; -})(Yi); -var Dd = Yi.exports, Ar = {}; -function vo(t, e) { +})(Ui); +var Ed = Ui.exports, Ir = {}; +function bo(t, e) { return process.env.NODE_ENV === "production" ? () => null : function(...r) { return t(...r) || e(...r); }; } -function P() { - return P = Object.assign ? Object.assign.bind() : function(t) { +function _() { + return _ = Object.assign ? Object.assign.bind() : function(t) { for (var e = 1; e < arguments.length; e++) { var n = arguments[e]; for (var r in n) Object.prototype.hasOwnProperty.call(n, r) && (t[r] = n[r]); } return t; - }, P.apply(this, arguments); + }, _.apply(this, arguments); } function he(t) { if (typeof t != "object" || t === null) @@ -3639,23 +3547,23 @@ function he(t) { const e = Object.getPrototypeOf(t); return (e === null || e === Object.prototype || Object.getPrototypeOf(e) === null) && !(Symbol.toStringTag in t) && !(Symbol.iterator in t); } -function Wi(t) { +function Gi(t) { if (!he(t)) return t; const e = {}; return Object.keys(t).forEach((n) => { - e[n] = Wi(t[n]); + e[n] = Gi(t[n]); }), e; } function Zt(t, e, n = { clone: !0 }) { - const r = n.clone ? P({}, t) : t; + const r = n.clone ? _({}, t) : t; return he(t) && he(e) && Object.keys(e).forEach((o) => { - o !== "__proto__" && (he(e[o]) && o in t && he(t[o]) ? r[o] = Zt(t[o], e[o], n) : n.clone ? r[o] = he(e[o]) ? Wi(e[o]) : e[o] : r[o] = e[o]); + o !== "__proto__" && (he(e[o]) && o in t && he(t[o]) ? r[o] = Zt(t[o], e[o], n) : n.clone ? r[o] = he(e[o]) ? Gi(e[o]) : e[o] : r[o] = e[o]); }), r; } -var Qr = { exports: {} }, jn = { exports: {} }, it = {}; +var Zr = { exports: {} }, jn = { exports: {} }, it = {}; /** @license React v16.13.1 * react-is.production.min.js * @@ -3664,16 +3572,16 @@ var Qr = { exports: {} }, jn = { exports: {} }, it = {}; * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. */ -var sa; -function Bd() { - if (sa) +var ia; +function Sd() { + if (ia) return it; - sa = 1; - var t = typeof Symbol == "function" && Symbol.for, e = t ? Symbol.for("react.element") : 60103, n = t ? Symbol.for("react.portal") : 60106, r = t ? Symbol.for("react.fragment") : 60107, o = t ? Symbol.for("react.strict_mode") : 60108, a = t ? Symbol.for("react.profiler") : 60114, i = t ? Symbol.for("react.provider") : 60109, l = t ? Symbol.for("react.context") : 60110, c = t ? Symbol.for("react.async_mode") : 60111, d = t ? Symbol.for("react.concurrent_mode") : 60111, p = t ? Symbol.for("react.forward_ref") : 60112, f = t ? Symbol.for("react.suspense") : 60113, w = t ? Symbol.for("react.suspense_list") : 60120, g = t ? Symbol.for("react.memo") : 60115, v = t ? Symbol.for("react.lazy") : 60116, m = t ? Symbol.for("react.block") : 60121, h = t ? Symbol.for("react.fundamental") : 60117, S = t ? Symbol.for("react.responder") : 60118, _ = t ? Symbol.for("react.scope") : 60119; - function C(b) { + ia = 1; + var t = typeof Symbol == "function" && Symbol.for, e = t ? Symbol.for("react.element") : 60103, n = t ? Symbol.for("react.portal") : 60106, r = t ? Symbol.for("react.fragment") : 60107, o = t ? Symbol.for("react.strict_mode") : 60108, a = t ? Symbol.for("react.profiler") : 60114, i = t ? Symbol.for("react.provider") : 60109, l = t ? Symbol.for("react.context") : 60110, c = t ? Symbol.for("react.async_mode") : 60111, d = t ? Symbol.for("react.concurrent_mode") : 60111, p = t ? Symbol.for("react.forward_ref") : 60112, f = t ? Symbol.for("react.suspense") : 60113, w = t ? Symbol.for("react.suspense_list") : 60120, g = t ? Symbol.for("react.memo") : 60115, v = t ? Symbol.for("react.lazy") : 60116, m = t ? Symbol.for("react.block") : 60121, h = t ? Symbol.for("react.fundamental") : 60117, T = t ? Symbol.for("react.responder") : 60118, A = t ? Symbol.for("react.scope") : 60119; + function R(b) { if (typeof b == "object" && b !== null) { - var I = b.$$typeof; - switch (I) { + var $ = b.$$typeof; + switch ($) { case e: switch (b = b.type, b) { case c: @@ -3692,44 +3600,44 @@ function Bd() { case i: return b; default: - return I; + return $; } } case n: - return I; + return $; } } } - function T(b) { - return C(b) === d; + function E(b) { + return R(b) === d; } return it.AsyncMode = c, it.ConcurrentMode = d, it.ContextConsumer = l, it.ContextProvider = i, it.Element = e, it.ForwardRef = p, it.Fragment = r, it.Lazy = v, it.Memo = g, it.Portal = n, it.Profiler = a, it.StrictMode = o, it.Suspense = f, it.isAsyncMode = function(b) { - return T(b) || C(b) === c; - }, it.isConcurrentMode = T, it.isContextConsumer = function(b) { - return C(b) === l; + return E(b) || R(b) === c; + }, it.isConcurrentMode = E, it.isContextConsumer = function(b) { + return R(b) === l; }, it.isContextProvider = function(b) { - return C(b) === i; + return R(b) === i; }, it.isElement = function(b) { return typeof b == "object" && b !== null && b.$$typeof === e; }, it.isForwardRef = function(b) { - return C(b) === p; + return R(b) === p; }, it.isFragment = function(b) { - return C(b) === r; + return R(b) === r; }, it.isLazy = function(b) { - return C(b) === v; + return R(b) === v; }, it.isMemo = function(b) { - return C(b) === g; + return R(b) === g; }, it.isPortal = function(b) { - return C(b) === n; + return R(b) === n; }, it.isProfiler = function(b) { - return C(b) === a; + return R(b) === a; }, it.isStrictMode = function(b) { - return C(b) === o; + return R(b) === o; }, it.isSuspense = function(b) { - return C(b) === f; + return R(b) === f; }, it.isValidElementType = function(b) { - return typeof b == "string" || typeof b == "function" || b === r || b === d || b === a || b === o || b === f || b === w || typeof b == "object" && b !== null && (b.$$typeof === v || b.$$typeof === g || b.$$typeof === i || b.$$typeof === l || b.$$typeof === p || b.$$typeof === h || b.$$typeof === S || b.$$typeof === _ || b.$$typeof === m); - }, it.typeOf = C, it; + return typeof b == "string" || typeof b == "function" || b === r || b === d || b === a || b === o || b === f || b === w || typeof b == "object" && b !== null && (b.$$typeof === v || b.$$typeof === g || b.$$typeof === i || b.$$typeof === l || b.$$typeof === p || b.$$typeof === h || b.$$typeof === T || b.$$typeof === A || b.$$typeof === m); + }, it.typeOf = R, it; } var st = {}; /** @license React v16.13.1 @@ -3740,20 +3648,20 @@ var st = {}; * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. */ -var la; -function jd() { - return la || (la = 1, process.env.NODE_ENV !== "production" && function() { - var t = typeof Symbol == "function" && Symbol.for, e = t ? Symbol.for("react.element") : 60103, n = t ? Symbol.for("react.portal") : 60106, r = t ? Symbol.for("react.fragment") : 60107, o = t ? Symbol.for("react.strict_mode") : 60108, a = t ? Symbol.for("react.profiler") : 60114, i = t ? Symbol.for("react.provider") : 60109, l = t ? Symbol.for("react.context") : 60110, c = t ? Symbol.for("react.async_mode") : 60111, d = t ? Symbol.for("react.concurrent_mode") : 60111, p = t ? Symbol.for("react.forward_ref") : 60112, f = t ? Symbol.for("react.suspense") : 60113, w = t ? Symbol.for("react.suspense_list") : 60120, g = t ? Symbol.for("react.memo") : 60115, v = t ? Symbol.for("react.lazy") : 60116, m = t ? Symbol.for("react.block") : 60121, h = t ? Symbol.for("react.fundamental") : 60117, S = t ? Symbol.for("react.responder") : 60118, _ = t ? Symbol.for("react.scope") : 60119; - function C(A) { - return typeof A == "string" || typeof A == "function" || // Note: its typeof might be other than 'symbol' or 'number' if it's a polyfill. - A === r || A === d || A === a || A === o || A === f || A === w || typeof A == "object" && A !== null && (A.$$typeof === v || A.$$typeof === g || A.$$typeof === i || A.$$typeof === l || A.$$typeof === p || A.$$typeof === h || A.$$typeof === S || A.$$typeof === _ || A.$$typeof === m); - } - function T(A) { - if (typeof A == "object" && A !== null) { - var Nt = A.$$typeof; - switch (Nt) { +var sa; +function Td() { + return sa || (sa = 1, process.env.NODE_ENV !== "production" && function() { + var t = typeof Symbol == "function" && Symbol.for, e = t ? Symbol.for("react.element") : 60103, n = t ? Symbol.for("react.portal") : 60106, r = t ? Symbol.for("react.fragment") : 60107, o = t ? Symbol.for("react.strict_mode") : 60108, a = t ? Symbol.for("react.profiler") : 60114, i = t ? Symbol.for("react.provider") : 60109, l = t ? Symbol.for("react.context") : 60110, c = t ? Symbol.for("react.async_mode") : 60111, d = t ? Symbol.for("react.concurrent_mode") : 60111, p = t ? Symbol.for("react.forward_ref") : 60112, f = t ? Symbol.for("react.suspense") : 60113, w = t ? Symbol.for("react.suspense_list") : 60120, g = t ? Symbol.for("react.memo") : 60115, v = t ? Symbol.for("react.lazy") : 60116, m = t ? Symbol.for("react.block") : 60121, h = t ? Symbol.for("react.fundamental") : 60117, T = t ? Symbol.for("react.responder") : 60118, A = t ? Symbol.for("react.scope") : 60119; + function R(I) { + return typeof I == "string" || typeof I == "function" || // Note: its typeof might be other than 'symbol' or 'number' if it's a polyfill. + I === r || I === d || I === a || I === o || I === f || I === w || typeof I == "object" && I !== null && (I.$$typeof === v || I.$$typeof === g || I.$$typeof === i || I.$$typeof === l || I.$$typeof === p || I.$$typeof === h || I.$$typeof === T || I.$$typeof === A || I.$$typeof === m); + } + function E(I) { + if (typeof I == "object" && I !== null) { + var xt = I.$$typeof; + switch (xt) { case e: - var j = A.type; + var j = I.type; switch (j) { case c: case d: @@ -3763,80 +3671,80 @@ function jd() { case f: return j; default: - var xt = j && j.$$typeof; - switch (xt) { + var yt = j && j.$$typeof; + switch (yt) { case l: case p: case v: case g: case i: - return xt; + return yt; default: - return Nt; + return xt; } } case n: - return Nt; + return xt; } } } - var b = c, I = d, z = l, H = i, O = e, $ = p, k = r, B = v, D = g, J = n, q = a, U = o, tt = f, at = !1; - function rt(A) { - return at || (at = !0, console.warn("The ReactIs.isAsyncMode() alias has been deprecated, and will be removed in React 17+. Update your code to use ReactIs.isConcurrentMode() instead. It has the exact same API.")), y(A) || T(A) === c; + var b = c, $ = d, z = l, H = i, C = e, P = p, k = r, B = v, M = g, J = n, q = a, U = o, tt = f, at = !1; + function rt(I) { + return at || (at = !0, console.warn("The ReactIs.isAsyncMode() alias has been deprecated, and will be removed in React 17+. Update your code to use ReactIs.isConcurrentMode() instead. It has the exact same API.")), y(I) || E(I) === c; } - function y(A) { - return T(A) === d; + function y(I) { + return E(I) === d; } - function R(A) { - return T(A) === l; + function O(I) { + return E(I) === l; } - function L(A) { - return T(A) === i; + function L(I) { + return E(I) === i; } - function F(A) { - return typeof A == "object" && A !== null && A.$$typeof === e; + function F(I) { + return typeof I == "object" && I !== null && I.$$typeof === e; } - function V(A) { - return T(A) === p; + function V(I) { + return E(I) === p; } - function W(A) { - return T(A) === r; + function W(I) { + return E(I) === r; } - function X(A) { - return T(A) === v; + function X(I) { + return E(I) === v; } - function Y(A) { - return T(A) === g; + function Y(I) { + return E(I) === g; } - function G(A) { - return T(A) === n; + function G(I) { + return E(I) === n; } - function K(A) { - return T(A) === a; + function K(I) { + return E(I) === a; } - function Z(A) { - return T(A) === o; + function Z(I) { + return E(I) === o; } - function dt(A) { - return T(A) === f; + function dt(I) { + return E(I) === f; } - st.AsyncMode = b, st.ConcurrentMode = I, st.ContextConsumer = z, st.ContextProvider = H, st.Element = O, st.ForwardRef = $, st.Fragment = k, st.Lazy = B, st.Memo = D, st.Portal = J, st.Profiler = q, st.StrictMode = U, st.Suspense = tt, st.isAsyncMode = rt, st.isConcurrentMode = y, st.isContextConsumer = R, st.isContextProvider = L, st.isElement = F, st.isForwardRef = V, st.isFragment = W, st.isLazy = X, st.isMemo = Y, st.isPortal = G, st.isProfiler = K, st.isStrictMode = Z, st.isSuspense = dt, st.isValidElementType = C, st.typeOf = T; + st.AsyncMode = b, st.ConcurrentMode = $, st.ContextConsumer = z, st.ContextProvider = H, st.Element = C, st.ForwardRef = P, st.Fragment = k, st.Lazy = B, st.Memo = M, st.Portal = J, st.Profiler = q, st.StrictMode = U, st.Suspense = tt, st.isAsyncMode = rt, st.isConcurrentMode = y, st.isContextConsumer = O, st.isContextProvider = L, st.isElement = F, st.isForwardRef = V, st.isFragment = W, st.isLazy = X, st.isMemo = Y, st.isPortal = G, st.isProfiler = K, st.isStrictMode = Z, st.isSuspense = dt, st.isValidElementType = R, st.typeOf = E; }()), st; } -var ca; -function qi() { - return ca || (ca = 1, process.env.NODE_ENV === "production" ? jn.exports = Bd() : jn.exports = jd()), jn.exports; +var la; +function Hi() { + return la || (la = 1, process.env.NODE_ENV === "production" ? jn.exports = Sd() : jn.exports = Td()), jn.exports; } /* object-assign (c) Sindre Sorhus @license MIT */ -var Mr, da; -function Vd() { - if (da) - return Mr; - da = 1; +var Ar, ca; +function Cd() { + if (ca) + return Ar; + ca = 1; var t = Object.getOwnPropertySymbols, e = Object.prototype.hasOwnProperty, n = Object.prototype.propertyIsEnumerable; function r(a) { if (a == null) @@ -3865,7 +3773,7 @@ function Vd() { return !1; } } - return Mr = o() ? Object.assign : function(a, i) { + return Ar = o() ? Object.assign : function(a, i) { for (var l, c = r(a), d, p = 1; p < arguments.length; p++) { l = Object(arguments[p]); for (var f in l) @@ -3877,29 +3785,29 @@ function Vd() { } } return c; - }, Mr; + }, Ar; } -var Dr, pa; -function yo() { - if (pa) - return Dr; - pa = 1; +var Mr, da; +function vo() { + if (da) + return Mr; + da = 1; var t = "SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED"; - return Dr = t, Dr; + return Mr = t, Mr; } -var Br, ua; -function Ki() { - return ua || (ua = 1, Br = Function.call.bind(Object.prototype.hasOwnProperty)), Br; +var Dr, pa; +function Xi() { + return pa || (pa = 1, Dr = Function.call.bind(Object.prototype.hasOwnProperty)), Dr; } -var jr, wa; -function zd() { - if (wa) - return jr; - wa = 1; +var Br, ua; +function Od() { + if (ua) + return Br; + ua = 1; var t = function() { }; if (process.env.NODE_ENV !== "production") { - var e = yo(), n = {}, r = Ki(); + var e = vo(), n = {}, r = Xi(); t = function(a) { var i = "Warning: " + a; typeof console < "u" && console.error(i); @@ -3939,14 +3847,14 @@ function zd() { } return o.resetWarningCache = function() { process.env.NODE_ENV !== "production" && (n = {}); - }, jr = o, jr; + }, Br = o, Br; } -var Vr, fa; -function Ld() { - if (fa) - return Vr; - fa = 1; - var t = qi(), e = Vd(), n = yo(), r = Ki(), o = zd(), a = function() { +var jr, wa; +function Rd() { + if (wa) + return jr; + wa = 1; + var t = Hi(), e = Cd(), n = vo(), r = Xi(), o = Od(), a = function() { }; process.env.NODE_ENV !== "production" && (a = function(l) { var c = "Warning: " + l; @@ -3959,57 +3867,57 @@ function Ld() { function i() { return null; } - return Vr = function(l, c) { + return jr = function(l, c) { var d = typeof Symbol == "function" && Symbol.iterator, p = "@@iterator"; function f(y) { - var R = y && (d && y[d] || y[p]); - if (typeof R == "function") - return R; + var O = y && (d && y[d] || y[p]); + if (typeof O == "function") + return O; } var w = "<>", g = { - array: S("array"), - bigint: S("bigint"), - bool: S("boolean"), - func: S("function"), - number: S("number"), - object: S("object"), - string: S("string"), - symbol: S("symbol"), - any: _(), - arrayOf: C, - element: T(), + array: T("array"), + bigint: T("bigint"), + bool: T("boolean"), + func: T("function"), + number: T("number"), + object: T("object"), + string: T("string"), + symbol: T("symbol"), + any: A(), + arrayOf: R, + element: E(), elementType: b(), - instanceOf: I, - node: $(), + instanceOf: $, + node: P(), objectOf: H, oneOf: z, - oneOfType: O, + oneOfType: C, shape: B, - exact: D + exact: M }; - function v(y, R) { - return y === R ? y !== 0 || 1 / y === 1 / R : y !== y && R !== R; + function v(y, O) { + return y === O ? y !== 0 || 1 / y === 1 / O : y !== y && O !== O; } - function m(y, R) { - this.message = y, this.data = R && typeof R == "object" ? R : {}, this.stack = ""; + function m(y, O) { + this.message = y, this.data = O && typeof O == "object" ? O : {}, this.stack = ""; } m.prototype = Error.prototype; function h(y) { if (process.env.NODE_ENV !== "production") - var R = {}, L = 0; + var O = {}, L = 0; function F(W, X, Y, G, K, Z, dt) { if (G = G || w, Z = Z || Y, dt !== n) { if (c) { - var A = new Error( + var I = new Error( "Calling PropTypes validators directly is not supported by the `prop-types` package. Use `PropTypes.checkPropTypes()` to call them. Read more at http://fb.me/use-check-prop-types" ); - throw A.name = "Invariant Violation", A; + throw I.name = "Invariant Violation", I; } else if (process.env.NODE_ENV !== "production" && typeof console < "u") { - var Nt = G + ":" + Y; - !R[Nt] && // Avoid spamming the console because they are often not actionable except for lib authors + var xt = G + ":" + Y; + !O[xt] && // Avoid spamming the console because they are often not actionable except for lib authors L < 3 && (a( "You are manually calling a React.PropTypes validation function for the `" + Z + "` prop on `" + G + "`. This is deprecated and will throw in the standalone `prop-types` package. You may be seeing this warning due to a third-party PropTypes library. See https://fb.me/react-warning-dont-call-proptypes for details." - ), R[Nt] = !0, L++); + ), O[xt] = !0, L++); } } return X[Y] == null ? W ? X[Y] === null ? new m("The " + K + " `" + Z + "` is marked as required " + ("in `" + G + "`, but its value is `null`.")) : new m("The " + K + " `" + Z + "` is marked as required in " + ("`" + G + "`, but its value is `undefined`.")) : null : y(X, Y, G, K, Z); @@ -4017,8 +3925,8 @@ function Ld() { var V = F.bind(null, !1); return V.isRequired = F.bind(null, !0), V; } - function S(y) { - function R(L, F, V, W, X, Y) { + function T(y) { + function O(L, F, V, W, X, Y) { var G = L[F], K = U(G); if (K !== y) { var Z = tt(G); @@ -4029,13 +3937,13 @@ function Ld() { } return null; } - return h(R); + return h(O); } - function _() { + function A() { return h(i); } - function C(y) { - function R(L, F, V, W, X) { + function R(y) { + function O(L, F, V, W, X) { if (typeof y != "function") return new m("Property `" + X + "` of component `" + V + "` has invalid PropType notation inside arrayOf."); var Y = L[F]; @@ -4050,11 +3958,11 @@ function Ld() { } return null; } - return h(R); + return h(O); } - function T() { - function y(R, L, F, V, W) { - var X = R[L]; + function E() { + function y(O, L, F, V, W) { + var X = O[L]; if (!l(X)) { var Y = U(X); return new m("Invalid " + V + " `" + W + "` of type " + ("`" + Y + "` supplied to `" + F + "`, expected a single ReactElement.")); @@ -4064,8 +3972,8 @@ function Ld() { return h(y); } function b() { - function y(R, L, F, V, W) { - var X = R[L]; + function y(O, L, F, V, W) { + var X = O[L]; if (!t.isValidElementType(X)) { var Y = U(X); return new m("Invalid " + V + " `" + W + "` of type " + ("`" + Y + "` supplied to `" + F + "`, expected a single ReactElement type.")); @@ -4074,35 +3982,35 @@ function Ld() { } return h(y); } - function I(y) { - function R(L, F, V, W, X) { + function $(y) { + function O(L, F, V, W, X) { if (!(L[F] instanceof y)) { var Y = y.name || w, G = rt(L[F]); return new m("Invalid " + W + " `" + X + "` of type " + ("`" + G + "` supplied to `" + V + "`, expected ") + ("instance of `" + Y + "`.")); } return null; } - return h(R); + return h(O); } function z(y) { if (!Array.isArray(y)) return process.env.NODE_ENV !== "production" && (arguments.length > 1 ? a( "Invalid arguments supplied to oneOf, expected an array, got " + arguments.length + " arguments. A common mistake is to write oneOf(x, y, z) instead of oneOf([x, y, z])." ) : a("Invalid argument supplied to oneOf, expected an array.")), i; - function R(L, F, V, W, X) { + function O(L, F, V, W, X) { for (var Y = L[F], G = 0; G < y.length; G++) if (v(Y, y[G])) return null; - var K = JSON.stringify(y, function(dt, A) { - var Nt = tt(A); - return Nt === "symbol" ? String(A) : A; + var K = JSON.stringify(y, function(dt, I) { + var xt = tt(I); + return xt === "symbol" ? String(I) : I; }); return new m("Invalid " + W + " `" + X + "` of value `" + String(Y) + "` " + ("supplied to `" + V + "`, expected one of " + K + ".")); } - return h(R); + return h(O); } function H(y) { - function R(L, F, V, W, X) { + function O(L, F, V, W, X) { if (typeof y != "function") return new m("Property `" + X + "` of component `" + V + "` has invalid PropType notation inside objectOf."); var Y = L[F], G = U(Y); @@ -4116,43 +4024,43 @@ function Ld() { } return null; } - return h(R); + return h(O); } - function O(y) { + function C(y) { if (!Array.isArray(y)) return process.env.NODE_ENV !== "production" && a("Invalid argument supplied to oneOfType, expected an instance of array."), i; - for (var R = 0; R < y.length; R++) { - var L = y[R]; + for (var O = 0; O < y.length; O++) { + var L = y[O]; if (typeof L != "function") return a( - "Invalid argument supplied to oneOfType. Expected an array of check functions, but received " + at(L) + " at index " + R + "." + "Invalid argument supplied to oneOfType. Expected an array of check functions, but received " + at(L) + " at index " + O + "." ), i; } function F(V, W, X, Y, G) { for (var K = [], Z = 0; Z < y.length; Z++) { - var dt = y[Z], A = dt(V, W, X, Y, G, n); - if (A == null) + var dt = y[Z], I = dt(V, W, X, Y, G, n); + if (I == null) return null; - A.data && r(A.data, "expectedType") && K.push(A.data.expectedType); + I.data && r(I.data, "expectedType") && K.push(I.data.expectedType); } - var Nt = K.length > 0 ? ", expected one of type [" + K.join(", ") + "]" : ""; - return new m("Invalid " + Y + " `" + G + "` supplied to " + ("`" + X + "`" + Nt + ".")); + var xt = K.length > 0 ? ", expected one of type [" + K.join(", ") + "]" : ""; + return new m("Invalid " + Y + " `" + G + "` supplied to " + ("`" + X + "`" + xt + ".")); } return h(F); } - function $() { - function y(R, L, F, V, W) { - return J(R[L]) ? null : new m("Invalid " + V + " `" + W + "` supplied to " + ("`" + F + "`, expected a ReactNode.")); + function P() { + function y(O, L, F, V, W) { + return J(O[L]) ? null : new m("Invalid " + V + " `" + W + "` supplied to " + ("`" + F + "`, expected a ReactNode.")); } return h(y); } - function k(y, R, L, F, V) { + function k(y, O, L, F, V) { return new m( - (y || "React class") + ": " + R + " type `" + L + "." + F + "` is invalid; it must be a function, usually from the `prop-types` package, but received `" + V + "`." + (y || "React class") + ": " + O + " type `" + L + "." + F + "` is invalid; it must be a function, usually from the `prop-types` package, but received `" + V + "`." ); } function B(y) { - function R(L, F, V, W, X) { + function O(L, F, V, W, X) { var Y = L[F], G = U(Y); if (G !== "object") return new m("Invalid " + W + " `" + X + "` of type `" + G + "` " + ("supplied to `" + V + "`, expected `object`.")); @@ -4166,10 +4074,10 @@ function Ld() { } return null; } - return h(R); + return h(O); } - function D(y) { - function R(L, F, V, W, X) { + function M(y) { + function O(L, F, V, W, X) { var Y = L[F], G = U(Y); if (G !== "object") return new m("Invalid " + W + " `" + X + "` of type `" + G + "` " + ("supplied to `" + V + "`, expected `object`.")); @@ -4183,13 +4091,13 @@ function Ld() { "Invalid " + W + " `" + X + "` key `" + Z + "` supplied to `" + V + "`.\nBad object: " + JSON.stringify(L[F], null, " ") + ` Valid keys: ` + JSON.stringify(Object.keys(y), null, " ") ); - var A = dt(Y, Z, V, W, X + "." + Z, n); - if (A) - return A; + var I = dt(Y, Z, V, W, X + "." + Z, n); + if (I) + return I; } return null; } - return h(R); + return h(O); } function J(y) { switch (typeof y) { @@ -4204,10 +4112,10 @@ Valid keys: ` + JSON.stringify(Object.keys(y), null, " ") return y.every(J); if (y === null || l(y)) return !0; - var R = f(y); - if (R) { - var L = R.call(y), F; - if (R !== y.entries) { + var O = f(y); + if (O) { + var L = O.call(y), F; + if (O !== y.entries) { for (; !(F = L.next()).done; ) if (!J(F.value)) return !1; @@ -4224,56 +4132,56 @@ Valid keys: ` + JSON.stringify(Object.keys(y), null, " ") return !1; } } - function q(y, R) { - return y === "symbol" ? !0 : R ? R["@@toStringTag"] === "Symbol" || typeof Symbol == "function" && R instanceof Symbol : !1; + function q(y, O) { + return y === "symbol" ? !0 : O ? O["@@toStringTag"] === "Symbol" || typeof Symbol == "function" && O instanceof Symbol : !1; } function U(y) { - var R = typeof y; - return Array.isArray(y) ? "array" : y instanceof RegExp ? "object" : q(R, y) ? "symbol" : R; + var O = typeof y; + return Array.isArray(y) ? "array" : y instanceof RegExp ? "object" : q(O, y) ? "symbol" : O; } function tt(y) { if (typeof y > "u" || y === null) return "" + y; - var R = U(y); - if (R === "object") { + var O = U(y); + if (O === "object") { if (y instanceof Date) return "date"; if (y instanceof RegExp) return "regexp"; } - return R; + return O; } function at(y) { - var R = tt(y); - switch (R) { + var O = tt(y); + switch (O) { case "array": case "object": - return "an " + R; + return "an " + O; case "boolean": case "date": case "regexp": - return "a " + R; + return "a " + O; default: - return R; + return O; } } function rt(y) { return !y.constructor || !y.constructor.name ? w : y.constructor.name; } return g.checkPropTypes = o, g.resetWarningCache = o.resetWarningCache, g.PropTypes = g, g; - }, Vr; + }, jr; } -var zr, ma; -function Fd() { - if (ma) - return zr; - ma = 1; - var t = yo(); +var Vr, fa; +function _d() { + if (fa) + return Vr; + fa = 1; + var t = vo(); function e() { } function n() { } - return n.resetWarningCache = e, zr = function() { + return n.resetWarningCache = e, Vr = function() { function r(i, l, c, d, p, f) { if (f !== t) { var w = new Error( @@ -4310,22 +4218,22 @@ function Fd() { resetWarningCache: e }; return a.PropTypes = a, a; - }, zr; + }, Vr; } if (process.env.NODE_ENV !== "production") { - var Ud = qi(), Gd = !0; - Qr.exports = Ld()(Ud.isElement, Gd); + var Pd = Hi(), $d = !0; + Zr.exports = Rd()(Pd.isElement, $d); } else - Qr.exports = Fd()(); -var Hd = Qr.exports; -const u = /* @__PURE__ */ Ad(Hd); -function Xd(t) { + Zr.exports = _d()(); +var Id = Zr.exports; +const u = /* @__PURE__ */ Nd(Id); +function Ad(t) { const { prototype: e = {} } = t; return !!e.isReactComponent; } -function Ji(t, e, n, r, o) { +function Yi(t, e, n, r, o) { const a = t[e], i = o || e; if (a == null || // When server-side rendering React doesn't warn either. // This is not an accurate check for SSR. @@ -4335,14 +4243,14 @@ function Ji(t, e, n, r, o) { return null; let l; const c = a.type; - return typeof c == "function" && !Xd(c) && (l = "Did you accidentally use a plain function component for an element instead?"), l !== void 0 ? new Error(`Invalid ${r} \`${i}\` supplied to \`${n}\`. Expected an element that can hold a ref. ${l} For more information see https://mui.com/r/caveat-with-refs-guide`) : null; -} -const Zi = vo(u.element, Ji); -Zi.isRequired = vo(u.element.isRequired, Ji); -const Qi = Zi, Yd = "exact-prop: ​"; -function Wd(t) { - return process.env.NODE_ENV === "production" ? t : P({}, t, { - [Yd]: (e) => { + return typeof c == "function" && !Ad(c) && (l = "Did you accidentally use a plain function component for an element instead?"), l !== void 0 ? new Error(`Invalid ${r} \`${i}\` supplied to \`${n}\`. Expected an element that can hold a ref. ${l} For more information see https://mui.com/r/caveat-with-refs-guide`) : null; +} +const Wi = bo(u.element, Yi); +Wi.isRequired = bo(u.element.isRequired, Yi); +const qi = Wi, Md = "exact-prop: ​"; +function Dd(t) { + return process.env.NODE_ENV === "production" ? t : _({}, t, { + [Md]: (e) => { const n = Object.keys(e).filter((r) => !t.hasOwnProperty(r)); return n.length > 0 ? new Error(`The following props are not supported: ${n.map((r) => `\`${r}\``).join(", ")}. Please remove them.`) : null; } @@ -4354,7 +4262,7 @@ function Ve(t) { e += "&args[]=" + encodeURIComponent(arguments[n]); return "Minified MUI error #" + t + "; visit " + e + " for the full message."; } -var to = { exports: {} }, lt = {}; +var Qr = { exports: {} }, lt = {}; /** * @license React * react-is.production.min.js @@ -4364,17 +4272,17 @@ var to = { exports: {} }, lt = {}; * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. */ -var ha; -function qd() { - if (ha) +var ma; +function Bd() { + if (ma) return lt; - ha = 1; + ma = 1; var t = Symbol.for("react.element"), e = Symbol.for("react.portal"), n = Symbol.for("react.fragment"), r = Symbol.for("react.strict_mode"), o = Symbol.for("react.profiler"), a = Symbol.for("react.provider"), i = Symbol.for("react.context"), l = Symbol.for("react.server_context"), c = Symbol.for("react.forward_ref"), d = Symbol.for("react.suspense"), p = Symbol.for("react.suspense_list"), f = Symbol.for("react.memo"), w = Symbol.for("react.lazy"), g = Symbol.for("react.offscreen"), v; v = Symbol.for("react.module.reference"); function m(h) { if (typeof h == "object" && h !== null) { - var S = h.$$typeof; - switch (S) { + var T = h.$$typeof; + switch (T) { case t: switch (h = h.type, h) { case n: @@ -4393,11 +4301,11 @@ function qd() { case a: return h; default: - return S; + return T; } } case e: - return S; + return T; } } } @@ -4443,33 +4351,33 @@ var ct = {}; * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. */ -var ga; -function Kd() { - return ga || (ga = 1, process.env.NODE_ENV !== "production" && function() { - var t = Symbol.for("react.element"), e = Symbol.for("react.portal"), n = Symbol.for("react.fragment"), r = Symbol.for("react.strict_mode"), o = Symbol.for("react.profiler"), a = Symbol.for("react.provider"), i = Symbol.for("react.context"), l = Symbol.for("react.server_context"), c = Symbol.for("react.forward_ref"), d = Symbol.for("react.suspense"), p = Symbol.for("react.suspense_list"), f = Symbol.for("react.memo"), w = Symbol.for("react.lazy"), g = Symbol.for("react.offscreen"), v = !1, m = !1, h = !1, S = !1, _ = !1, C; - C = Symbol.for("react.module.reference"); - function T(j) { - return !!(typeof j == "string" || typeof j == "function" || j === n || j === o || _ || j === r || j === d || j === p || S || j === g || v || m || h || typeof j == "object" && j !== null && (j.$$typeof === w || j.$$typeof === f || j.$$typeof === a || j.$$typeof === i || j.$$typeof === c || // This needs to include all possible module reference object +var ha; +function jd() { + return ha || (ha = 1, process.env.NODE_ENV !== "production" && function() { + var t = Symbol.for("react.element"), e = Symbol.for("react.portal"), n = Symbol.for("react.fragment"), r = Symbol.for("react.strict_mode"), o = Symbol.for("react.profiler"), a = Symbol.for("react.provider"), i = Symbol.for("react.context"), l = Symbol.for("react.server_context"), c = Symbol.for("react.forward_ref"), d = Symbol.for("react.suspense"), p = Symbol.for("react.suspense_list"), f = Symbol.for("react.memo"), w = Symbol.for("react.lazy"), g = Symbol.for("react.offscreen"), v = !1, m = !1, h = !1, T = !1, A = !1, R; + R = Symbol.for("react.module.reference"); + function E(j) { + return !!(typeof j == "string" || typeof j == "function" || j === n || j === o || A || j === r || j === d || j === p || T || j === g || v || m || h || typeof j == "object" && j !== null && (j.$$typeof === w || j.$$typeof === f || j.$$typeof === a || j.$$typeof === i || j.$$typeof === c || // This needs to include all possible module reference object // types supported by any Flight configuration anywhere since // we don't know which Flight build this will end up being used // with. - j.$$typeof === C || j.getModuleId !== void 0)); + j.$$typeof === R || j.getModuleId !== void 0)); } function b(j) { if (typeof j == "object" && j !== null) { - var xt = j.$$typeof; - switch (xt) { + var yt = j.$$typeof; + switch (yt) { case t: - var Ft = j.type; - switch (Ft) { + var Lt = j.type; + switch (Lt) { case n: case o: case r: case d: case p: - return Ft; + return Lt; default: - var ce = Ft && Ft.$$typeof; + var ce = Lt && Lt.$$typeof; switch (ce) { case l: case i: @@ -4479,19 +4387,19 @@ function Kd() { case a: return ce; default: - return xt; + return yt; } } case e: - return xt; + return yt; } } } - var I = i, z = a, H = t, O = c, $ = n, k = w, B = f, D = e, J = o, q = r, U = d, tt = p, at = !1, rt = !1; + var $ = i, z = a, H = t, C = c, P = n, k = w, B = f, M = e, J = o, q = r, U = d, tt = p, at = !1, rt = !1; function y(j) { return at || (at = !0, console.warn("The ReactIs.isAsyncMode() alias has been deprecated, and will be removed in React 18+.")), !1; } - function R(j) { + function O(j) { return rt || (rt = !0, console.warn("The ReactIs.isConcurrentMode() alias has been deprecated, and will be removed in React 18+.")), !1; } function L(j) { @@ -4524,65 +4432,65 @@ function Kd() { function dt(j) { return b(j) === r; } - function A(j) { + function I(j) { return b(j) === d; } - function Nt(j) { + function xt(j) { return b(j) === p; } - ct.ContextConsumer = I, ct.ContextProvider = z, ct.Element = H, ct.ForwardRef = O, ct.Fragment = $, ct.Lazy = k, ct.Memo = B, ct.Portal = D, ct.Profiler = J, ct.StrictMode = q, ct.Suspense = U, ct.SuspenseList = tt, ct.isAsyncMode = y, ct.isConcurrentMode = R, ct.isContextConsumer = L, ct.isContextProvider = F, ct.isElement = V, ct.isForwardRef = W, ct.isFragment = X, ct.isLazy = Y, ct.isMemo = G, ct.isPortal = K, ct.isProfiler = Z, ct.isStrictMode = dt, ct.isSuspense = A, ct.isSuspenseList = Nt, ct.isValidElementType = T, ct.typeOf = b; + ct.ContextConsumer = $, ct.ContextProvider = z, ct.Element = H, ct.ForwardRef = C, ct.Fragment = P, ct.Lazy = k, ct.Memo = B, ct.Portal = M, ct.Profiler = J, ct.StrictMode = q, ct.Suspense = U, ct.SuspenseList = tt, ct.isAsyncMode = y, ct.isConcurrentMode = O, ct.isContextConsumer = L, ct.isContextProvider = F, ct.isElement = V, ct.isForwardRef = W, ct.isFragment = X, ct.isLazy = Y, ct.isMemo = G, ct.isPortal = K, ct.isProfiler = Z, ct.isStrictMode = dt, ct.isSuspense = I, ct.isSuspenseList = xt, ct.isValidElementType = E, ct.typeOf = b; }()), ct; } -process.env.NODE_ENV === "production" ? to.exports = qd() : to.exports = Kd(); -var ba = to.exports; -const Jd = /^\s*function(?:\s|\s*\/\*.*\*\/\s*)+([^(\s/]*)\s*/; -function Zd(t) { - const e = `${t}`.match(Jd); +process.env.NODE_ENV === "production" ? Qr.exports = Bd() : Qr.exports = jd(); +var ga = Qr.exports; +const Vd = /^\s*function(?:\s|\s*\/\*.*\*\/\s*)+([^(\s/]*)\s*/; +function zd(t) { + const e = `${t}`.match(Vd); return e && e[1] || ""; } -function ts(t, e = "") { - return t.displayName || t.name || Zd(t) || e; +function Ki(t, e = "") { + return t.displayName || t.name || zd(t) || e; } -function va(t, e, n) { - const r = ts(e); +function ba(t, e, n) { + const r = Ki(e); return t.displayName || (r !== "" ? `${n}(${r})` : n); } -function Qd(t) { +function Ld(t) { if (t != null) { if (typeof t == "string") return t; if (typeof t == "function") - return ts(t, "Component"); + return Ki(t, "Component"); if (typeof t == "object") switch (t.$$typeof) { - case ba.ForwardRef: - return va(t, t.render, "ForwardRef"); - case ba.Memo: - return va(t, t.type, "memo"); + case ga.ForwardRef: + return ba(t, t.render, "ForwardRef"); + case ga.Memo: + return ba(t, t.type, "memo"); default: return; } } } -function yn(t, e, n, r, o) { +function vn(t, e, n, r, o) { if (process.env.NODE_ENV === "production") return null; const a = t[e], i = o || e; return a == null ? null : a && a.nodeType !== 1 ? new Error(`Invalid ${r} \`${i}\` supplied to \`${n}\`. Expected an HTMLElement.`) : null; } -const tp = u.oneOfType([u.func, u.object]), es = tp; +const Fd = u.oneOfType([u.func, u.object]), Ji = Fd; function Wt(t) { if (typeof t != "string") throw new Error(process.env.NODE_ENV !== "production" ? "MUI: `capitalize(string)` expects a string argument." : Ve(7)); return t.charAt(0).toUpperCase() + t.slice(1); } -function ep(...t) { +function Ud(...t) { return t.reduce((e, n) => n == null ? e : function(...o) { e.apply(this, o), n.apply(this, o); }, () => { }); } -function np(t, e = 166) { +function Gd(t, e = 166) { let n; function r(...o) { const a = () => { @@ -4594,15 +4502,15 @@ function np(t, e = 166) { clearTimeout(n); }, r; } -function rp(t, e) { +function Hd(t, e) { return process.env.NODE_ENV === "production" ? () => null : (n, r, o, a, i) => { const l = o || "<>", c = i || r; return typeof n[r] < "u" ? new Error(`The ${a} \`${c}\` of \`${l}\` is deprecated. ${e}`) : null; }; } -function op(t, e) { +function Xd(t, e) { var n, r; - return /* @__PURE__ */ M.isValidElement(t) && e.indexOf( + return /* @__PURE__ */ D.isValidElement(t) && e.indexOf( // For server components `muiName` is avaialble in element.type._payload.value.muiName // relevant info - https://github.com/facebook/react/blob/2807d781a08db8e9873687fccc25c0f12b4fb3d4/packages/react/src/ReactLazy.js#L45 // eslint-disable-next-line no-underscore-dangle @@ -4612,13 +4520,13 @@ function op(t, e) { function Yn(t) { return t && t.ownerDocument || document; } -function ap(t) { +function Yd(t) { return Yn(t).defaultView || window; } -function ip(t, e) { +function Wd(t, e) { if (process.env.NODE_ENV === "production") return () => null; - const n = e ? P({}, e.propTypes) : null; + const n = e ? _({}, e.propTypes) : null; return (o) => (a, i, l, c, d, ...p) => { const f = d || i, w = n == null ? void 0 : n[f]; if (w) { @@ -4632,29 +4540,29 @@ function ip(t, e) { function Wn(t, e) { typeof t == "function" ? t(e) : t && (t.current = e); } -const sp = typeof window < "u" ? M.useLayoutEffect : M.useEffect, ze = sp; -let ya = 0; -function lp(t) { - const [e, n] = M.useState(t), r = t || e; - return M.useEffect(() => { - e == null && (ya += 1, n(`mui-${ya}`)); +const qd = typeof window < "u" ? D.useLayoutEffect : D.useEffect, ze = qd; +let va = 0; +function Kd(t) { + const [e, n] = D.useState(t), r = t || e; + return D.useEffect(() => { + e == null && (va += 1, n(`mui-${va}`)); }, [e]), r; } -const xa = M["useId".toString()]; -function ns(t) { - if (xa !== void 0) { - const e = xa(); +const ya = D["useId".toString()]; +function Zi(t) { + if (ya !== void 0) { + const e = ya(); return t ?? e; } - return lp(t); + return Kd(t); } -function cp(t, e, n, r, o) { +function Jd(t, e, n, r, o) { if (process.env.NODE_ENV === "production") return null; const a = o || e; return typeof t[e] < "u" ? new Error(`The prop \`${a}\` is not supported. Please remove it.`) : null; } -function rs({ +function Qi({ controlled: t, default: e, name: n, @@ -4662,49 +4570,49 @@ function rs({ }) { const { current: o - } = M.useRef(t !== void 0), [a, i] = M.useState(e), l = o ? t : a; + } = D.useRef(t !== void 0), [a, i] = D.useState(e), l = o ? t : a; if (process.env.NODE_ENV !== "production") { - M.useEffect(() => { + D.useEffect(() => { o !== (t !== void 0) && console.error([`MUI: A component is changing the ${o ? "" : "un"}controlled ${r} state of ${n} to be ${o ? "un" : ""}controlled.`, "Elements should not switch from uncontrolled to controlled (or vice versa).", `Decide between using a controlled or uncontrolled ${n} element for the lifetime of the component.`, "The nature of the state is determined during the first render. It's considered controlled if the value is not `undefined`.", "More info: https://fb.me/react-controlled-components"].join(` `)); }, [r, n, t]); const { current: d - } = M.useRef(e); - M.useEffect(() => { + } = D.useRef(e); + D.useEffect(() => { !o && d !== e && console.error([`MUI: A component is changing the default ${r} state of an uncontrolled ${n} after being initialized. To suppress this warning opt to use a controlled ${n}.`].join(` `)); }, [JSON.stringify(e)]); } - const c = M.useCallback((d) => { + const c = D.useCallback((d) => { o || i(d); }, []); return [l, c]; } -function eo(t) { - const e = M.useRef(t); +function to(t) { + const e = D.useRef(t); return ze(() => { e.current = t; - }), M.useRef((...n) => ( + }), D.useRef((...n) => ( // @ts-expect-error hide `this` (0, e.current)(...n) )).current; } function xe(...t) { - return M.useMemo(() => t.every((e) => e == null) ? null : (e) => { + return D.useMemo(() => t.every((e) => e == null) ? null : (e) => { t.forEach((n) => { Wn(n, e); }); }, t); } -const Na = {}; -function dp(t, e) { - const n = M.useRef(Na); - return n.current === Na && (n.current = t(e)), n; +const xa = {}; +function Zd(t, e) { + const n = D.useRef(xa); + return n.current === xa && (n.current = t(e)), n; } -const pp = []; -function up(t) { - M.useEffect(t, pp); +const Qd = []; +function tp(t) { + D.useEffect(t, Qd); } class Tn { constructor() { @@ -4724,12 +4632,12 @@ class Tn { }, e); } } -function sn() { - const t = dp(Tn.create).current; - return up(t.disposeEffect), t; +function an() { + const t = Zd(Tn.create).current; + return tp(t.disposeEffect), t; } -let dr = !0, no = !1; -const wp = new Tn(), fp = { +let dr = !0, eo = !1; +const ep = new Tn(), np = { text: !0, search: !0, url: !0, @@ -4744,26 +4652,26 @@ const wp = new Tn(), fp = { datetime: !0, "datetime-local": !0 }; -function mp(t) { +function rp(t) { const { type: e, tagName: n } = t; - return !!(n === "INPUT" && fp[e] && !t.readOnly || n === "TEXTAREA" && !t.readOnly || t.isContentEditable); + return !!(n === "INPUT" && np[e] && !t.readOnly || n === "TEXTAREA" && !t.readOnly || t.isContentEditable); } -function hp(t) { +function op(t) { t.metaKey || t.altKey || t.ctrlKey || (dr = !0); } -function Lr() { +function zr() { dr = !1; } -function gp() { - this.visibilityState === "hidden" && no && (dr = !0); +function ap() { + this.visibilityState === "hidden" && eo && (dr = !0); } -function bp(t) { - t.addEventListener("keydown", hp, !0), t.addEventListener("mousedown", Lr, !0), t.addEventListener("pointerdown", Lr, !0), t.addEventListener("touchstart", Lr, !0), t.addEventListener("visibilitychange", gp, !0); +function ip(t) { + t.addEventListener("keydown", op, !0), t.addEventListener("mousedown", zr, !0), t.addEventListener("pointerdown", zr, !0), t.addEventListener("touchstart", zr, !0), t.addEventListener("visibilitychange", ap, !0); } -function vp(t) { +function sp(t) { const { target: e } = t; @@ -4771,19 +4679,19 @@ function vp(t) { return e.matches(":focus-visible"); } catch { } - return dr || mp(e); + return dr || rp(e); } -function os() { - const t = M.useCallback((o) => { - o != null && bp(o.ownerDocument); - }, []), e = M.useRef(!1); +function ts() { + const t = D.useCallback((o) => { + o != null && ip(o.ownerDocument); + }, []), e = D.useRef(!1); function n() { - return e.current ? (no = !0, wp.start(100, () => { - no = !1; + return e.current ? (eo = !0, ep.start(100, () => { + eo = !1; }), e.current = !1, !0) : !1; } function r(o) { - return vp(o) ? (e.current = !0, !0) : !1; + return sp(o) ? (e.current = !0, !0) : !1; } return { isFocusVisibleRef: e, @@ -4792,21 +4700,21 @@ function os() { ref: t }; } -function as(t, e) { - const n = P({}, e); +function es(t, e) { + const n = _({}, e); return Object.keys(t).forEach((r) => { if (r.toString().match(/^(components|slots)$/)) - n[r] = P({}, t[r], n[r]); + n[r] = _({}, t[r], n[r]); else if (r.toString().match(/^(componentsProps|slotProps)$/)) { const o = t[r] || {}, a = e[r]; - n[r] = {}, !a || !Object.keys(a) ? n[r] = o : !o || !Object.keys(o) ? n[r] = a : (n[r] = P({}, a), Object.keys(o).forEach((i) => { - n[r][i] = as(o[i], a[i]); + n[r] = {}, !a || !Object.keys(a) ? n[r] = o : !o || !Object.keys(o) ? n[r] = a : (n[r] = _({}, a), Object.keys(o).forEach((i) => { + n[r][i] = es(o[i], a[i]); })); } else n[r] === void 0 && (n[r] = t[r]); }), n; } -function xo(t, e, n = void 0) { +function yo(t, e, n = void 0) { const r = {}; return Object.keys(t).forEach( // `Object.keys(slots)` can't be wider than `T` because we infer `T` from `slots`. @@ -4822,8 +4730,8 @@ function xo(t, e, n = void 0) { } ), r; } -const ka = (t) => t, yp = () => { - let t = ka; +const Na = (t) => t, lp = () => { + let t = Na; return { configure(e) { t = e; @@ -4832,10 +4740,10 @@ const ka = (t) => t, yp = () => { return t(e); }, reset() { - t = ka; + t = Na; } }; -}, xp = yp(), is = xp, ss = { +}, cp = lp(), ns = cp, rs = { active: "active", checked: "checked", completed: "completed", @@ -4850,19 +4758,19 @@ const ka = (t) => t, yp = () => { selected: "selected" }; function pr(t, e, n = "Mui") { - const r = ss[e]; - return r ? `${n}-${r}` : `${is.generate(t)}-${e}`; + const r = rs[e]; + return r ? `${n}-${r}` : `${ns.generate(t)}-${e}`; } -function ls(t, e, n = "Mui") { +function os(t, e, n = "Mui") { const r = {}; return e.forEach((o) => { r[o] = pr(t, o, n); }), r; } -function Np(t, e = Number.MIN_SAFE_INTEGER, n = Number.MAX_SAFE_INTEGER) { +function dp(t, e = Number.MIN_SAFE_INTEGER, n = Number.MAX_SAFE_INTEGER) { return Math.max(e, Math.min(t, n)); } -function kt(t, e) { +function Nt(t, e) { if (t == null) return {}; var n = {}, r = Object.keys(t), o, a; @@ -4870,16 +4778,16 @@ function kt(t, e) { o = r[a], !(e.indexOf(o) >= 0) && (n[o] = t[o]); return n; } -const kp = ["values", "unit", "step"], Ep = (t) => { +const pp = ["values", "unit", "step"], up = (t) => { const e = Object.keys(t).map((n) => ({ key: n, val: t[n] })) || []; - return e.sort((n, r) => n.val - r.val), e.reduce((n, r) => P({}, n, { + return e.sort((n, r) => n.val - r.val), e.reduce((n, r) => _({}, n, { [r.key]: r.val }), {}); }; -function Sp(t) { +function wp(t) { const { // The breakpoint **start** at this value. // For instance with the first breakpoint xs: [xs, sm). @@ -4897,7 +4805,7 @@ function Sp(t) { }, unit: n = "px", step: r = 5 - } = t, o = kt(t, kp), a = Ep(e), i = Object.keys(a); + } = t, o = Nt(t, pp), a = up(e), i = Object.keys(a); function l(w) { return `@media (min-width:${typeof e[w] == "number" ? e[w] : w}${n})`; } @@ -4915,7 +4823,7 @@ function Sp(t) { const g = i.indexOf(w); return g === 0 ? l(i[1]) : g === i.length - 1 ? c(i[g]) : d(w, i[i.indexOf(w) + 1]).replace("@media", "@media not all and"); } - return P({ + return _({ keys: i, values: a, up: l, @@ -4926,16 +4834,16 @@ function Sp(t) { unit: n }, o); } -const Tp = { +const fp = { borderRadius: 4 -}, Cp = Tp, Op = process.env.NODE_ENV !== "production" ? u.oneOfType([u.number, u.string, u.object, u.array]) : {}, se = Op; -function un(t, e) { +}, mp = fp, hp = process.env.NODE_ENV !== "production" ? u.oneOfType([u.number, u.string, u.object, u.array]) : {}, se = hp; +function pn(t, e) { return e ? Zt(t, e, { clone: !1 // No need to clone deep, it's way faster. }) : t; } -const No = { +const xo = { xs: 0, // phone sm: 600, @@ -4946,22 +4854,22 @@ const No = { // desktop xl: 1536 // large screen -}, Ea = { +}, ka = { // Sorted ASC by size. That's important. // It can't be configured as it's used statically for propTypes. keys: ["xs", "sm", "md", "lg", "xl"], - up: (t) => `@media (min-width:${No[t]}px)` + up: (t) => `@media (min-width:${xo[t]}px)` }; function Qt(t, e, n) { const r = t.theme || {}; if (Array.isArray(e)) { - const a = r.breakpoints || Ea; + const a = r.breakpoints || ka; return e.reduce((i, l, c) => (i[a.up(a.keys[c])] = n(e[c]), i), {}); } if (typeof e == "object") { - const a = r.breakpoints || Ea; + const a = r.breakpoints || ka; return Object.keys(e).reduce((i, l) => { - if (Object.keys(a.values || No).indexOf(l) !== -1) { + if (Object.keys(a.values || xo).indexOf(l) !== -1) { const c = a.up(l); i[c] = n(e[l], l); } else { @@ -4973,14 +4881,14 @@ function Qt(t, e, n) { } return n(e); } -function Rp(t = {}) { +function gp(t = {}) { var e; return ((e = t.keys) == null ? void 0 : e.reduce((r, o) => { const a = t.up(o); return r[a] = {}, r; }, {})) || {}; } -function _p(t, e) { +function bp(t, e) { return t.reduce((n, r) => { const o = n[r]; return (!o || Object.keys(o).length === 0) && delete n[r], n; @@ -5000,7 +4908,7 @@ function qn(t, e, n, r = n) { let o; return typeof t == "function" ? o = t(n) : Array.isArray(t) ? o = t[n] || r : o = ur(t, n) || r, e && (o = e(o, r, t)), o; } -function yt(t) { +function vt(t) { const { prop: e, cssProperty: n = t.prop, @@ -5021,34 +4929,34 @@ function yt(t) { [e]: se } : {}, a.filterProps = [e], a; } -function Pp(t) { +function vp(t) { const e = {}; return (n) => (e[n] === void 0 && (e[n] = t(n)), e[n]); } -const $p = { +const yp = { m: "margin", p: "padding" -}, Ip = { +}, xp = { t: "Top", r: "Right", b: "Bottom", l: "Left", x: ["Left", "Right"], y: ["Top", "Bottom"] -}, Sa = { +}, Ea = { marginX: "mx", marginY: "my", paddingX: "px", paddingY: "py" -}, Ap = Pp((t) => { +}, Np = vp((t) => { if (t.length > 2) - if (Sa[t]) - t = Sa[t]; + if (Ea[t]) + t = Ea[t]; else return [t]; - const [e, n] = t.split(""), r = $p[e], o = Ip[n] || ""; + const [e, n] = t.split(""), r = yp[e], o = xp[n] || ""; return Array.isArray(o) ? o.map((a) => r + a) : [r + o]; -}), wr = ["m", "mt", "mr", "mb", "ml", "mx", "my", "margin", "marginTop", "marginRight", "marginBottom", "marginLeft", "marginX", "marginY", "marginInline", "marginInlineStart", "marginInlineEnd", "marginBlock", "marginBlockStart", "marginBlockEnd"], fr = ["p", "pt", "pr", "pb", "pl", "px", "py", "padding", "paddingTop", "paddingRight", "paddingBottom", "paddingLeft", "paddingX", "paddingY", "paddingInline", "paddingInlineStart", "paddingInlineEnd", "paddingBlock", "paddingBlockStart", "paddingBlockEnd"], Mp = [...wr, ...fr]; +}), wr = ["m", "mt", "mr", "mb", "ml", "mx", "my", "margin", "marginTop", "marginRight", "marginBottom", "marginLeft", "marginX", "marginY", "marginInline", "marginInlineStart", "marginInlineEnd", "marginBlock", "marginBlockStart", "marginBlockEnd"], fr = ["p", "pt", "pr", "pb", "pl", "px", "py", "padding", "paddingTop", "paddingRight", "paddingBottom", "paddingLeft", "paddingX", "paddingY", "paddingInline", "paddingInlineStart", "paddingInlineEnd", "paddingBlock", "paddingBlockStart", "paddingBlockEnd"], kp = [...wr, ...fr]; function Cn(t, e, n, r) { var o; const a = (o = ur(t, e, !1)) != null ? o : n; @@ -5058,7 +4966,7 @@ function Cn(t, e, n, r) { `)), () => { }); } -function cs(t) { +function as(t) { return Cn(t, "spacing", 8, "spacing"); } function On(t, e) { @@ -5067,34 +4975,34 @@ function On(t, e) { const n = Math.abs(e), r = t(n); return e >= 0 ? r : typeof r == "number" ? -r : `-${r}`; } -function Dp(t, e) { +function Ep(t, e) { return (n) => t.reduce((r, o) => (r[o] = On(e, n), r), {}); } -function Bp(t, e, n, r) { +function Sp(t, e, n, r) { if (e.indexOf(n) === -1) return null; - const o = Ap(n), a = Dp(o, r), i = t[n]; + const o = Np(n), a = Ep(o, r), i = t[n]; return Qt(t, i, a); } -function ds(t, e) { - const n = cs(t.theme); - return Object.keys(t).map((r) => Bp(t, e, r, n)).reduce(un, {}); +function is(t, e) { + const n = as(t.theme); + return Object.keys(t).map((r) => Sp(t, e, r, n)).reduce(pn, {}); } function mt(t) { - return ds(t, wr); + return is(t, wr); } mt.propTypes = process.env.NODE_ENV !== "production" ? wr.reduce((t, e) => (t[e] = se, t), {}) : {}; mt.filterProps = wr; function ht(t) { - return ds(t, fr); + return is(t, fr); } ht.propTypes = process.env.NODE_ENV !== "production" ? fr.reduce((t, e) => (t[e] = se, t), {}) : {}; ht.filterProps = fr; -process.env.NODE_ENV !== "production" && Mp.reduce((t, e) => (t[e] = se, t), {}); -function jp(t = 8) { +process.env.NODE_ENV !== "production" && kp.reduce((t, e) => (t[e] = se, t), {}); +function Tp(t = 8) { if (t.mui) return t; - const e = cs({ + const e = as({ spacing: t }), n = (...r) => (process.env.NODE_ENV !== "production" && (r.length <= 4 || console.error(`MUI: Too many arguments provided, expected between 0 and 4, got ${r.length}`)), (r.length === 0 ? [1] : r).map((a) => { const i = e(a); @@ -5105,20 +5013,20 @@ function jp(t = 8) { function mr(...t) { const e = t.reduce((r, o) => (o.filterProps.forEach((a) => { r[a] = o; - }), r), {}), n = (r) => Object.keys(r).reduce((o, a) => e[a] ? un(o, e[a](r)) : o, {}); + }), r), {}), n = (r) => Object.keys(r).reduce((o, a) => e[a] ? pn(o, e[a](r)) : o, {}); return n.propTypes = process.env.NODE_ENV !== "production" ? t.reduce((r, o) => Object.assign(r, o.propTypes), {}) : {}, n.filterProps = t.reduce((r, o) => r.concat(o.filterProps), []), n; } -function Bt(t) { +function Dt(t) { return typeof t != "number" ? t : `${t}px solid`; } -function Lt(t, e) { - return yt({ +function zt(t, e) { + return vt({ prop: t, themeKey: "borders", transform: e }); } -const Vp = Lt("border", Bt), zp = Lt("borderTop", Bt), Lp = Lt("borderRight", Bt), Fp = Lt("borderBottom", Bt), Up = Lt("borderLeft", Bt), Gp = Lt("borderColor"), Hp = Lt("borderTopColor"), Xp = Lt("borderRightColor"), Yp = Lt("borderBottomColor"), Wp = Lt("borderLeftColor"), qp = Lt("outline", Bt), Kp = Lt("outlineColor"), hr = (t) => { +const Cp = zt("border", Dt), Op = zt("borderTop", Dt), Rp = zt("borderRight", Dt), _p = zt("borderBottom", Dt), Pp = zt("borderLeft", Dt), $p = zt("borderColor"), Ip = zt("borderTopColor"), Ap = zt("borderRightColor"), Mp = zt("borderBottomColor"), Dp = zt("borderLeftColor"), Bp = zt("outline", Dt), jp = zt("outlineColor"), hr = (t) => { if (t.borderRadius !== void 0 && t.borderRadius !== null) { const e = Cn(t.theme, "shape.borderRadius", 4, "borderRadius"), n = (r) => ({ borderRadius: On(e, r) @@ -5131,7 +5039,7 @@ hr.propTypes = process.env.NODE_ENV !== "production" ? { borderRadius: se } : {}; hr.filterProps = ["borderRadius"]; -mr(Vp, zp, Lp, Fp, Up, Gp, Hp, Xp, Yp, Wp, hr, qp, Kp); +mr(Cp, Op, Rp, _p, Pp, $p, Ip, Ap, Mp, Dp, hr, Bp, jp); const gr = (t) => { if (t.gap !== void 0 && t.gap !== null) { const e = Cn(t.theme, "spacing", 8, "gap"), n = (r) => ({ @@ -5171,116 +5079,116 @@ vr.propTypes = process.env.NODE_ENV !== "production" ? { rowGap: se } : {}; vr.filterProps = ["rowGap"]; -const Jp = yt({ +const Vp = vt({ prop: "gridColumn" -}), Zp = yt({ +}), zp = vt({ prop: "gridRow" -}), Qp = yt({ +}), Lp = vt({ prop: "gridAutoFlow" -}), tu = yt({ +}), Fp = vt({ prop: "gridAutoColumns" -}), eu = yt({ +}), Up = vt({ prop: "gridAutoRows" -}), nu = yt({ +}), Gp = vt({ prop: "gridTemplateColumns" -}), ru = yt({ +}), Hp = vt({ prop: "gridTemplateRows" -}), ou = yt({ +}), Xp = vt({ prop: "gridTemplateAreas" -}), au = yt({ +}), Yp = vt({ prop: "gridArea" }); -mr(gr, br, vr, Jp, Zp, Qp, tu, eu, nu, ru, ou, au); +mr(gr, br, vr, Vp, zp, Lp, Fp, Up, Gp, Hp, Xp, Yp); function Me(t, e) { return e === "grey" ? e : t; } -const iu = yt({ +const Wp = vt({ prop: "color", themeKey: "palette", transform: Me -}), su = yt({ +}), qp = vt({ prop: "bgcolor", cssProperty: "backgroundColor", themeKey: "palette", transform: Me -}), lu = yt({ +}), Kp = vt({ prop: "backgroundColor", themeKey: "palette", transform: Me }); -mr(iu, su, lu); -function At(t) { +mr(Wp, qp, Kp); +function It(t) { return t <= 1 && t !== 0 ? `${t * 100}%` : t; } -const cu = yt({ +const Jp = vt({ prop: "width", - transform: At -}), ko = (t) => { + transform: It +}), No = (t) => { if (t.maxWidth !== void 0 && t.maxWidth !== null) { const e = (n) => { var r, o; - const a = ((r = t.theme) == null || (r = r.breakpoints) == null || (r = r.values) == null ? void 0 : r[n]) || No[n]; + const a = ((r = t.theme) == null || (r = r.breakpoints) == null || (r = r.values) == null ? void 0 : r[n]) || xo[n]; return a ? ((o = t.theme) == null || (o = o.breakpoints) == null ? void 0 : o.unit) !== "px" ? { maxWidth: `${a}${t.theme.breakpoints.unit}` } : { maxWidth: a } : { - maxWidth: At(n) + maxWidth: It(n) }; }; return Qt(t, t.maxWidth, e); } return null; }; -ko.filterProps = ["maxWidth"]; -const du = yt({ +No.filterProps = ["maxWidth"]; +const Zp = vt({ prop: "minWidth", - transform: At -}), pu = yt({ + transform: It +}), Qp = vt({ prop: "height", - transform: At -}), uu = yt({ + transform: It +}), tu = vt({ prop: "maxHeight", - transform: At -}), wu = yt({ + transform: It +}), eu = vt({ prop: "minHeight", - transform: At + transform: It }); -yt({ +vt({ prop: "size", cssProperty: "width", - transform: At + transform: It }); -yt({ +vt({ prop: "size", cssProperty: "height", - transform: At + transform: It }); -const fu = yt({ +const nu = vt({ prop: "boxSizing" }); -mr(cu, ko, du, pu, uu, wu, fu); -const mu = { +mr(Jp, No, Zp, Qp, tu, eu, nu); +const ru = { // borders border: { themeKey: "borders", - transform: Bt + transform: Dt }, borderTop: { themeKey: "borders", - transform: Bt + transform: Dt }, borderRight: { themeKey: "borders", - transform: Bt + transform: Dt }, borderBottom: { themeKey: "borders", - transform: Bt + transform: Dt }, borderLeft: { themeKey: "borders", - transform: Bt + transform: Dt }, borderColor: { themeKey: "palette" @@ -5299,7 +5207,7 @@ const mu = { }, outline: { themeKey: "borders", - transform: Bt + transform: Dt }, outlineColor: { themeKey: "palette" @@ -5505,22 +5413,22 @@ const mu = { }, // sizing width: { - transform: At + transform: It }, maxWidth: { - style: ko + style: No }, minWidth: { - transform: At + transform: It }, height: { - transform: At + transform: It }, maxHeight: { - transform: At + transform: It }, minHeight: { - transform: At + transform: It }, boxSizing: {}, // typography @@ -5544,15 +5452,15 @@ const mu = { cssProperty: !1, themeKey: "typography" } -}, Eo = mu; -function hu(...t) { +}, ko = ru; +function ou(...t) { const e = t.reduce((r, o) => r.concat(Object.keys(o)), []), n = new Set(e); return t.every((r) => n.size === Object.keys(r).length); } -function gu(t, e) { +function au(t, e) { return typeof t == "function" ? t(e) : t; } -function bu() { +function iu() { function t(n, r, o, a) { const i = { [n]: r, @@ -5590,7 +5498,7 @@ function bu() { } = n || {}; if (!o) return null; - const i = (r = a.unstable_sxConfig) != null ? r : Eo; + const i = (r = a.unstable_sxConfig) != null ? r : ko; function l(c) { let d = c; if (typeof c == "function") @@ -5599,84 +5507,84 @@ function bu() { return c; if (!d) return null; - const p = Rp(a.breakpoints), f = Object.keys(p); + const p = gp(a.breakpoints), f = Object.keys(p); let w = p; return Object.keys(d).forEach((g) => { - const v = gu(d[g], a); + const v = au(d[g], a); if (v != null) if (typeof v == "object") if (i[g]) - w = un(w, t(g, v, a, i)); + w = pn(w, t(g, v, a, i)); else { const m = Qt({ theme: a }, v, (h) => ({ [g]: h })); - hu(m, v) ? w[g] = e({ + ou(m, v) ? w[g] = e({ sx: v, theme: a - }) : w = un(w, m); + }) : w = pn(w, m); } else - w = un(w, t(g, v, a, i)); - }), _p(f, w); + w = pn(w, t(g, v, a, i)); + }), bp(f, w); } return Array.isArray(o) ? o.map(l) : l(o); } return e; } -const ps = bu(); -ps.filterProps = ["sx"]; -const So = ps; -function vu(t, e) { +const ss = iu(); +ss.filterProps = ["sx"]; +const Eo = ss; +function su(t, e) { const n = this; return n.vars && typeof n.getColorSchemeSelector == "function" ? { [n.getColorSchemeSelector(t).replace(/(\[[^\]]+\])/, "*:where($1)")]: e } : n.palette.mode === t ? e : {}; } -const yu = ["breakpoints", "palette", "spacing", "shape"]; -function To(t = {}, ...e) { +const lu = ["breakpoints", "palette", "spacing", "shape"]; +function So(t = {}, ...e) { const { breakpoints: n = {}, palette: r = {}, spacing: o, shape: a = {} - } = t, i = kt(t, yu), l = Sp(n), c = jp(o); + } = t, i = Nt(t, lu), l = wp(n), c = Tp(o); let d = Zt({ breakpoints: l, direction: "ltr", components: {}, // Inject component definitions. - palette: P({ + palette: _({ mode: "light" }, r), spacing: c, - shape: P({}, Cp, a) + shape: _({}, mp, a) }, i); - return d.applyStyles = vu, d = e.reduce((p, f) => Zt(p, f), d), d.unstable_sxConfig = P({}, Eo, i == null ? void 0 : i.unstable_sxConfig), d.unstable_sx = function(f) { - return So({ + return d.applyStyles = su, d = e.reduce((p, f) => Zt(p, f), d), d.unstable_sxConfig = _({}, ko, i == null ? void 0 : i.unstable_sxConfig), d.unstable_sx = function(f) { + return Eo({ sx: f, theme: this }); }, d; } -function xu(t) { +function cu(t) { return Object.keys(t).length === 0; } -function us(t = null) { - const e = M.useContext(Ml); - return !e || xu(e) ? t : e; +function ls(t = null) { + const e = D.useContext($l); + return !e || cu(e) ? t : e; } -const Nu = To(); -function ws(t = Nu) { - return us(t); +const du = So(); +function cs(t = du) { + return ls(t); } -const ku = ["ownerState"], Eu = ["variants"], Su = ["name", "slot", "skipVariantsResolver", "skipSx", "overridesResolver"]; -function Tu(t) { +const pu = ["ownerState"], uu = ["variants"], wu = ["name", "slot", "skipVariantsResolver", "skipSx", "overridesResolver"]; +function fu(t) { return Object.keys(t).length === 0; } -function Cu(t) { +function mu(t) { return typeof t == "string" && // 96 is one less than the char code // for "a" so this is checking that // it's a lowercase character @@ -5685,60 +5593,60 @@ function Cu(t) { function Gn(t) { return t !== "ownerState" && t !== "theme" && t !== "sx" && t !== "as"; } -const Ou = To(), Ta = (t) => t && t.charAt(0).toLowerCase() + t.slice(1); +const hu = So(), Sa = (t) => t && t.charAt(0).toLowerCase() + t.slice(1); function Vn({ defaultTheme: t, theme: e, themeId: n }) { - return Tu(e) ? t : e[n] || e; + return fu(e) ? t : e[n] || e; } -function Ru(t) { +function gu(t) { return t ? (e, n) => n[t] : null; } function Hn(t, e) { let { ownerState: n - } = e, r = kt(e, ku); - const o = typeof t == "function" ? t(P({ + } = e, r = Nt(e, pu); + const o = typeof t == "function" ? t(_({ ownerState: n }, r)) : t; if (Array.isArray(o)) - return o.flatMap((a) => Hn(a, P({ + return o.flatMap((a) => Hn(a, _({ ownerState: n }, r))); if (o && typeof o == "object" && Array.isArray(o.variants)) { const { variants: a = [] } = o; - let l = kt(o, Eu); + let l = Nt(o, uu); return a.forEach((c) => { let d = !0; - typeof c.props == "function" ? d = c.props(P({ + typeof c.props == "function" ? d = c.props(_({ ownerState: n }, r, n)) : Object.keys(c.props).forEach((p) => { (n == null ? void 0 : n[p]) !== c.props[p] && r[p] !== c.props[p] && (d = !1); - }), d && (Array.isArray(l) || (l = [l]), l.push(typeof c.style == "function" ? c.style(P({ + }), d && (Array.isArray(l) || (l = [l]), l.push(typeof c.style == "function" ? c.style(_({ ownerState: n }, r, n)) : c.style)); }), l; } return o; } -function _u(t = {}) { +function bu(t = {}) { const { themeId: e, - defaultTheme: n = Ou, + defaultTheme: n = hu, rootShouldForwardProp: r = Gn, slotShouldForwardProp: o = Gn - } = t, a = (i) => So(P({}, i, { - theme: Vn(P({}, i, { + } = t, a = (i) => Eo(_({}, i, { + theme: Vn(_({}, i, { defaultTheme: n, themeId: e })) })); return a.__mui_systemSx = !0, (i, l = {}) => { - Dl(i, (b) => b.filter((I) => !(I != null && I.__mui_systemSx))); + Il(i, (b) => b.filter(($) => !($ != null && $.__mui_systemSx))); const { name: c, slot: d, @@ -5746,93 +5654,93 @@ function _u(t = {}) { skipSx: f, // TODO v6: remove `lowercaseFirstLetter()` in the next major release // For more details: https://github.com/mui/material-ui/pull/37908 - overridesResolver: w = Ru(Ta(d)) - } = l, g = kt(l, Su), v = p !== void 0 ? p : ( + overridesResolver: w = gu(Sa(d)) + } = l, g = Nt(l, wu), v = p !== void 0 ? p : ( // TODO v6: remove `Root` in the next major release // For more details: https://github.com/mui/material-ui/pull/37908 d && d !== "Root" && d !== "root" || !1 ), m = f || !1; let h; - process.env.NODE_ENV !== "production" && c && (h = `${c}-${Ta(d || "Root")}`); - let S = Gn; - d === "Root" || d === "root" ? S = r : d ? S = o : Cu(i) && (S = void 0); - const _ = Al(i, P({ - shouldForwardProp: S, + process.env.NODE_ENV !== "production" && c && (h = `${c}-${Sa(d || "Root")}`); + let T = Gn; + d === "Root" || d === "root" ? T = r : d ? T = o : mu(i) && (T = void 0); + const A = Pl(i, _({ + shouldForwardProp: T, label: h - }, g)), C = (b) => typeof b == "function" && b.__emotion_real !== b || he(b) ? (I) => Hn(b, P({}, I, { + }, g)), R = (b) => typeof b == "function" && b.__emotion_real !== b || he(b) ? ($) => Hn(b, _({}, $, { theme: Vn({ - theme: I.theme, + theme: $.theme, defaultTheme: n, themeId: e }) - })) : b, T = (b, ...I) => { - let z = C(b); - const H = I ? I.map(C) : []; + })) : b, E = (b, ...$) => { + let z = R(b); + const H = $ ? $.map(R) : []; c && w && H.push((k) => { - const B = Vn(P({}, k, { + const B = Vn(_({}, k, { defaultTheme: n, themeId: e })); if (!B.components || !B.components[c] || !B.components[c].styleOverrides) return null; - const D = B.components[c].styleOverrides, J = {}; - return Object.entries(D).forEach(([q, U]) => { - J[q] = Hn(U, P({}, k, { + const M = B.components[c].styleOverrides, J = {}; + return Object.entries(M).forEach(([q, U]) => { + J[q] = Hn(U, _({}, k, { theme: B })); }), w(k, J); }), c && !v && H.push((k) => { var B; - const D = Vn(P({}, k, { + const M = Vn(_({}, k, { defaultTheme: n, themeId: e - })), J = D == null || (B = D.components) == null || (B = B[c]) == null ? void 0 : B.variants; + })), J = M == null || (B = M.components) == null || (B = B[c]) == null ? void 0 : B.variants; return Hn({ variants: J - }, P({}, k, { - theme: D + }, _({}, k, { + theme: M })); }), m || H.push(a); - const O = H.length - I.length; - if (Array.isArray(b) && O > 0) { - const k = new Array(O).fill(""); + const C = H.length - $.length; + if (Array.isArray(b) && C > 0) { + const k = new Array(C).fill(""); z = [...b, ...k], z.raw = [...b.raw, ...k]; } - const $ = _(z, ...H); + const P = A(z, ...H); if (process.env.NODE_ENV !== "production") { let k; - c && (k = `${c}${Wt(d || "")}`), k === void 0 && (k = `Styled(${Qd(i)})`), $.displayName = k; + c && (k = `${c}${Wt(d || "")}`), k === void 0 && (k = `Styled(${Ld(i)})`), P.displayName = k; } - return i.muiName && ($.muiName = i.muiName), $; + return i.muiName && (P.muiName = i.muiName), P; }; - return _.withConfig && (T.withConfig = _.withConfig), T; + return A.withConfig && (E.withConfig = A.withConfig), E; }; } -function Pu(t) { +function vu(t) { const { theme: e, name: n, props: r } = t; - return !e || !e.components || !e.components[n] || !e.components[n].defaultProps ? r : as(e.components[n].defaultProps, r); + return !e || !e.components || !e.components[n] || !e.components[n].defaultProps ? r : es(e.components[n].defaultProps, r); } -function $u({ +function yu({ props: t, name: e, defaultTheme: n, themeId: r }) { - let o = ws(n); - return r && (o = o[r] || o), Pu({ + let o = cs(n); + return r && (o = o[r] || o), vu({ theme: o, name: e, props: t }); } -function Co(t, e = 0, n = 1) { - return process.env.NODE_ENV !== "production" && (t < e || t > n) && console.error(`MUI: The value provided ${t} is out of range [${e}, ${n}].`), Np(t, e, n); +function To(t, e = 0, n = 1) { + return process.env.NODE_ENV !== "production" && (t < e || t > n) && console.error(`MUI: The value provided ${t} is out of range [${e}, ${n}].`), dp(t, e, n); } -function Iu(t) { +function xu(t) { t = t.slice(1); const e = new RegExp(`.{1,${t.length >= 6 ? 2 : 1}}`, "g"); let n = t.match(e); @@ -5842,7 +5750,7 @@ function Ne(t) { if (t.type) return t; if (t.charAt(0) === "#") - return Ne(Iu(t)); + return Ne(xu(t)); const e = t.indexOf("("), n = t.substring(0, e); if (["rgb", "rgba", "hsl", "hsla", "color"].indexOf(n) === -1) throw new Error(process.env.NODE_ENV !== "production" ? `MUI: Unsupported \`${t}\` color. @@ -5870,7 +5778,7 @@ function yr(t) { } = t; return e.indexOf("rgb") !== -1 ? r = r.map((o, a) => a < 3 ? parseInt(o, 10) : o) : e.indexOf("hsl") !== -1 && (r[1] = `${r[1]}%`, r[2] = `${r[2]}%`), e.indexOf("color") !== -1 ? r = `${n} ${r.join(" ")}` : r = `${r.join(", ")}`, `${e}(${r})`; } -function Au(t) { +function Nu(t) { t = Ne(t); const { values: e @@ -5882,28 +5790,28 @@ function Au(t) { values: c }); } -function Ca(t) { +function Ta(t) { t = Ne(t); - let e = t.type === "hsl" || t.type === "hsla" ? Ne(Au(t)).values : t.values; + let e = t.type === "hsl" || t.type === "hsla" ? Ne(Nu(t)).values : t.values; return e = e.map((n) => (t.type !== "color" && (n /= 255), n <= 0.03928 ? n / 12.92 : ((n + 0.055) / 1.055) ** 2.4)), Number((0.2126 * e[0] + 0.7152 * e[1] + 0.0722 * e[2]).toFixed(3)); } -function Oa(t, e) { - const n = Ca(t), r = Ca(e); +function Ca(t, e) { + const n = Ta(t), r = Ta(e); return (Math.max(n, r) + 0.05) / (Math.min(n, r) + 0.05); } -function fs(t, e) { - return t = Ne(t), e = Co(e), (t.type === "rgb" || t.type === "hsl") && (t.type += "a"), t.type === "color" ? t.values[3] = `/${e}` : t.values[3] = e, yr(t); +function ds(t, e) { + return t = Ne(t), e = To(e), (t.type === "rgb" || t.type === "hsl") && (t.type += "a"), t.type === "color" ? t.values[3] = `/${e}` : t.values[3] = e, yr(t); } -function Mu(t, e) { - if (t = Ne(t), e = Co(e), t.type.indexOf("hsl") !== -1) +function ku(t, e) { + if (t = Ne(t), e = To(e), t.type.indexOf("hsl") !== -1) t.values[2] *= 1 - e; else if (t.type.indexOf("rgb") !== -1 || t.type.indexOf("color") !== -1) for (let n = 0; n < 3; n += 1) t.values[n] *= 1 - e; return yr(t); } -function Du(t, e) { - if (t = Ne(t), e = Co(e), t.type.indexOf("hsl") !== -1) +function Eu(t, e) { + if (t = Ne(t), e = To(e), t.type.indexOf("hsl") !== -1) t.values[2] += (100 - t.values[2]) * e; else if (t.type.indexOf("rgb") !== -1) for (let n = 0; n < 3; n += 1) @@ -5913,8 +5821,8 @@ function Du(t, e) { t.values[n] += (1 - t.values[n]) * e; return yr(t); } -function Bu(t, e) { - return P({ +function Su(t, e) { + return _({ toolbar: { minHeight: 56, [t.up("xs")]: { @@ -5928,10 +5836,10 @@ function Bu(t, e) { } }, e); } -const ju = { +const Tu = { black: "#000", white: "#fff" -}, xn = ju, Vu = { +}, yn = Tu, Cu = { 50: "#fafafa", 100: "#f5f5f5", 200: "#eeeeee", @@ -5946,7 +5854,7 @@ const ju = { A200: "#eeeeee", A400: "#bdbdbd", A700: "#616161" -}, zu = Vu, Lu = { +}, Ou = Cu, Ru = { 50: "#f3e5f5", 100: "#e1bee7", 200: "#ce93d8", @@ -5961,7 +5869,7 @@ const ju = { A200: "#e040fb", A400: "#d500f9", A700: "#aa00ff" -}, Oe = Lu, Fu = { +}, Oe = Ru, _u = { 50: "#ffebee", 100: "#ffcdd2", 200: "#ef9a9a", @@ -5976,7 +5884,7 @@ const ju = { A200: "#ff5252", A400: "#ff1744", A700: "#d50000" -}, Re = Fu, Uu = { +}, Re = _u, Pu = { 50: "#fff3e0", 100: "#ffe0b2", 200: "#ffcc80", @@ -5991,7 +5899,7 @@ const ju = { A200: "#ffab40", A400: "#ff9100", A700: "#ff6d00" -}, nn = Uu, Gu = { +}, en = Pu, $u = { 50: "#e3f2fd", 100: "#bbdefb", 200: "#90caf9", @@ -6006,7 +5914,7 @@ const ju = { A200: "#448aff", A400: "#2979ff", A700: "#2962ff" -}, _e = Gu, Hu = { +}, _e = $u, Iu = { 50: "#e1f5fe", 100: "#b3e5fc", 200: "#81d4fa", @@ -6021,7 +5929,7 @@ const ju = { A200: "#40c4ff", A400: "#00b0ff", A700: "#0091ea" -}, Pe = Hu, Xu = { +}, Pe = Iu, Au = { 50: "#e8f5e9", 100: "#c8e6c9", 200: "#a5d6a7", @@ -6036,7 +5944,7 @@ const ju = { A200: "#69f0ae", A400: "#00e676", A700: "#00c853" -}, $e = Xu, Yu = ["mode", "contrastThreshold", "tonalOffset"], Ra = { +}, $e = Au, Mu = ["mode", "contrastThreshold", "tonalOffset"], Oa = { // The colors used to style the text. text: { // The most important text. @@ -6051,8 +5959,8 @@ const ju = { // The background colors used to style the surfaces. // Consistency between these values is important. background: { - paper: xn.white, - default: xn.white + paper: yn.white, + default: yn.white }, // The colors used to style the action elements. action: { @@ -6073,9 +5981,9 @@ const ju = { focusOpacity: 0.12, activatedOpacity: 0.12 } -}, Fr = { +}, Lr = { text: { - primary: xn.white, + primary: yn.white, secondary: "rgba(255, 255, 255, 0.7)", disabled: "rgba(255, 255, 255, 0.5)", icon: "rgba(255, 255, 255, 0.5)" @@ -6086,7 +5994,7 @@ const ju = { default: "#121212" }, action: { - active: xn.white, + active: yn.white, hover: "rgba(255, 255, 255, 0.08)", hoverOpacity: 0.08, selected: "rgba(255, 255, 255, 0.16)", @@ -6099,11 +6007,11 @@ const ju = { activatedOpacity: 0.24 } }; -function _a(t, e, n, r) { +function Ra(t, e, n, r) { const o = r.light || r, a = r.dark || r * 1.5; - t[e] || (t.hasOwnProperty(n) ? t[e] = t[n] : e === "light" ? t.light = Du(t.main, o) : e === "dark" && (t.dark = Mu(t.main, a))); + t[e] || (t.hasOwnProperty(n) ? t[e] = t[n] : e === "light" ? t.light = Eu(t.main, o) : e === "dark" && (t.dark = ku(t.main, a))); } -function Wu(t = "light") { +function Du(t = "light") { return t === "dark" ? { main: _e[200], light: _e[50], @@ -6114,7 +6022,7 @@ function Wu(t = "light") { dark: _e[800] }; } -function qu(t = "light") { +function Bu(t = "light") { return t === "dark" ? { main: Oe[200], light: Oe[50], @@ -6125,7 +6033,7 @@ function qu(t = "light") { dark: Oe[700] }; } -function Ku(t = "light") { +function ju(t = "light") { return t === "dark" ? { main: Re[500], light: Re[300], @@ -6136,7 +6044,7 @@ function Ku(t = "light") { dark: Re[800] }; } -function Ju(t = "light") { +function Vu(t = "light") { return t === "dark" ? { main: Pe[400], light: Pe[300], @@ -6147,7 +6055,7 @@ function Ju(t = "light") { dark: Pe[900] }; } -function Zu(t = "light") { +function zu(t = "light") { return t === "dark" ? { main: $e[400], light: $e[300], @@ -6158,29 +6066,29 @@ function Zu(t = "light") { dark: $e[900] }; } -function Qu(t = "light") { +function Lu(t = "light") { return t === "dark" ? { - main: nn[400], - light: nn[300], - dark: nn[700] + main: en[400], + light: en[300], + dark: en[700] } : { main: "#ed6c02", // closest to orange[800] that pass 3:1. - light: nn[500], - dark: nn[900] + light: en[500], + dark: en[900] }; } -function tw(t) { +function Fu(t) { const { mode: e = "light", contrastThreshold: n = 3, tonalOffset: r = 0.2 - } = t, o = kt(t, Yu), a = t.primary || Wu(e), i = t.secondary || qu(e), l = t.error || Ku(e), c = t.info || Ju(e), d = t.success || Zu(e), p = t.warning || Qu(e); + } = t, o = Nt(t, Mu), a = t.primary || Du(e), i = t.secondary || Bu(e), l = t.error || ju(e), c = t.info || Vu(e), d = t.success || zu(e), p = t.warning || Lu(e); function f(m) { - const h = Oa(m, Fr.text.primary) >= n ? Fr.text.primary : Ra.text.primary; + const h = Ca(m, Lr.text.primary) >= n ? Lr.text.primary : Oa.text.primary; if (process.env.NODE_ENV !== "production") { - const S = Oa(m, h); - S < 3 && console.error([`MUI: The contrast ratio of ${S}:1 for ${h} on ${m}`, "falls below the WCAG recommended absolute minimum contrast ratio of 3:1.", "https://www.w3.org/TR/2008/REC-WCAG20-20081211/#visual-audio-contrast-contrast"].join(` + const T = Ca(m, h); + T < 3 && console.error([`MUI: The contrast ratio of ${T}:1 for ${h} on ${m}`, "falls below the WCAG recommended absolute minimum contrast ratio of 3:1.", "https://www.w3.org/TR/2008/REC-WCAG20-20081211/#visual-audio-contrast-contrast"].join(` `)); } return h; @@ -6188,13 +6096,13 @@ function tw(t) { const w = ({ color: m, name: h, - mainShade: S = 500, - lightShade: _ = 300, - darkShade: C = 700 + mainShade: T = 500, + lightShade: A = 300, + darkShade: R = 700 }) => { - if (m = P({}, m), !m.main && m[S] && (m.main = m[S]), !m.hasOwnProperty("main")) + if (m = _({}, m), !m.main && m[T] && (m.main = m[T]), !m.hasOwnProperty("main")) throw new Error(process.env.NODE_ENV !== "production" ? `MUI: The color${h ? ` (${h})` : ""} provided to augmentColor(color) is invalid. -The color object needs to have a \`main\` property or a \`${S}\` property.` : Ve(11, h ? ` (${h})` : "", S)); +The color object needs to have a \`main\` property or a \`${T}\` property.` : Ve(11, h ? ` (${h})` : "", T)); if (typeof m.main != "string") throw new Error(process.env.NODE_ENV !== "production" ? `MUI: The color${h ? ` (${h})` : ""} provided to augmentColor(color) is invalid. \`color.main\` should be a string, but \`${JSON.stringify(m.main)}\` was provided instead. @@ -6210,14 +6118,14 @@ const theme1 = createTheme({ palette: { const theme2 = createTheme({ palette: { primary: { main: green[500] }, } });` : Ve(12, h ? ` (${h})` : "", JSON.stringify(m.main))); - return _a(m, "light", _, r), _a(m, "dark", C, r), m.contrastText || (m.contrastText = f(m.main)), m; + return Ra(m, "light", A, r), Ra(m, "dark", R, r), m.contrastText || (m.contrastText = f(m.main)), m; }, g = { - dark: Fr, - light: Ra + dark: Lr, + light: Oa }; - return process.env.NODE_ENV !== "production" && (g[e] || console.error(`MUI: The palette mode \`${e}\` is not supported.`)), Zt(P({ + return process.env.NODE_ENV !== "production" && (g[e] || console.error(`MUI: The palette mode \`${e}\` is not supported.`)), Zt(_({ // A collection of common colors. - common: P({}, xn), + common: _({}, yn), // prevent mutable object. // The palette mode, can be light or dark. mode: e, @@ -6255,7 +6163,7 @@ const theme2 = createTheme({ palette: { name: "success" }), // The grey colors. - grey: zu, + grey: Ou, // Used by `getContrastText()` to maximize the contrast between // the background and the text. contrastThreshold: n, @@ -6269,16 +6177,16 @@ const theme2 = createTheme({ palette: { tonalOffset: r }, g[e]), o); } -const ew = ["fontFamily", "fontSize", "fontWeightLight", "fontWeightRegular", "fontWeightMedium", "fontWeightBold", "htmlFontSize", "allVariants", "pxToRem"]; -function nw(t) { +const Uu = ["fontFamily", "fontSize", "fontWeightLight", "fontWeightRegular", "fontWeightMedium", "fontWeightBold", "htmlFontSize", "allVariants", "pxToRem"]; +function Gu(t) { return Math.round(t * 1e5) / 1e5; } -const Pa = { +const _a = { textTransform: "uppercase" -}, $a = '"Roboto", "Helvetica", "Arial", sans-serif'; -function rw(t, e) { +}, Pa = '"Roboto", "Helvetica", "Arial", sans-serif'; +function Hu(t, e) { const n = typeof e == "function" ? e(t) : e, { - fontFamily: r = $a, + fontFamily: r = Pa, // The default font size of the Material Specification. fontSize: o = 14, // px @@ -6292,16 +6200,16 @@ function rw(t, e) { // Apply the CSS properties to all the variants. allVariants: p, pxToRem: f - } = n, w = kt(n, ew); + } = n, w = Nt(n, Uu); process.env.NODE_ENV !== "production" && (typeof o != "number" && console.error("MUI: `fontSize` is required to be a number."), typeof d != "number" && console.error("MUI: `htmlFontSize` is required to be a number.")); - const g = o / 14, v = f || ((S) => `${S / d * g}rem`), m = (S, _, C, T, b) => P({ + const g = o / 14, v = f || ((T) => `${T / d * g}rem`), m = (T, A, R, E, b) => _({ fontFamily: r, - fontWeight: S, - fontSize: v(_), + fontWeight: T, + fontSize: v(A), // Unitless following https://meyerweb.com/eric/thoughts/2006/02/08/unitless-line-heights/ - lineHeight: C - }, r === $a ? { - letterSpacing: `${nw(T / _)}em` + lineHeight: R + }, r === Pa ? { + letterSpacing: `${Gu(E / A)}em` } : {}, b, p), h = { h1: m(a, 96, 1.167, -1.5), h2: m(a, 60, 1.2, -0.5), @@ -6313,9 +6221,9 @@ function rw(t, e) { subtitle2: m(l, 14, 1.57, 0.1), body1: m(i, 16, 1.5, 0.15), body2: m(i, 14, 1.43, 0.15), - button: m(l, 14, 1.75, 0.4, Pa), + button: m(l, 14, 1.75, 0.4, _a), caption: m(i, 12, 1.66, 0.4), - overline: m(i, 12, 2.66, 1, Pa), + overline: m(i, 12, 2.66, 1, _a), // TODO v6: Remove handling of 'inherit' variant from the theme as it is already handled in Material UI's Typography component. Also, remember to remove the associated types. inherit: { fontFamily: "inherit", @@ -6325,7 +6233,7 @@ function rw(t, e) { letterSpacing: "inherit" } }; - return Zt(P({ + return Zt(_({ htmlFontSize: d, pxToRem: v, fontFamily: r, @@ -6339,11 +6247,11 @@ function rw(t, e) { // No need to clone deep }); } -const ow = 0.2, aw = 0.14, iw = 0.12; +const Xu = 0.2, Yu = 0.14, Wu = 0.12; function ft(...t) { - return [`${t[0]}px ${t[1]}px ${t[2]}px ${t[3]}px rgba(0,0,0,${ow})`, `${t[4]}px ${t[5]}px ${t[6]}px ${t[7]}px rgba(0,0,0,${aw})`, `${t[8]}px ${t[9]}px ${t[10]}px ${t[11]}px rgba(0,0,0,${iw})`].join(","); + return [`${t[0]}px ${t[1]}px ${t[2]}px ${t[3]}px rgba(0,0,0,${Xu})`, `${t[4]}px ${t[5]}px ${t[6]}px ${t[7]}px rgba(0,0,0,${Yu})`, `${t[8]}px ${t[9]}px ${t[10]}px ${t[11]}px rgba(0,0,0,${Wu})`].join(","); } -const sw = ["none", ft(0, 2, 1, -1, 0, 1, 1, 0, 0, 1, 3, 0), ft(0, 3, 1, -2, 0, 2, 2, 0, 0, 1, 5, 0), ft(0, 3, 3, -2, 0, 3, 4, 0, 0, 1, 8, 0), ft(0, 2, 4, -1, 0, 4, 5, 0, 0, 1, 10, 0), ft(0, 3, 5, -1, 0, 5, 8, 0, 0, 1, 14, 0), ft(0, 3, 5, -1, 0, 6, 10, 0, 0, 1, 18, 0), ft(0, 4, 5, -2, 0, 7, 10, 1, 0, 2, 16, 1), ft(0, 5, 5, -3, 0, 8, 10, 1, 0, 3, 14, 2), ft(0, 5, 6, -3, 0, 9, 12, 1, 0, 3, 16, 2), ft(0, 6, 6, -3, 0, 10, 14, 1, 0, 4, 18, 3), ft(0, 6, 7, -4, 0, 11, 15, 1, 0, 4, 20, 3), ft(0, 7, 8, -4, 0, 12, 17, 2, 0, 5, 22, 4), ft(0, 7, 8, -4, 0, 13, 19, 2, 0, 5, 24, 4), ft(0, 7, 9, -4, 0, 14, 21, 2, 0, 5, 26, 4), ft(0, 8, 9, -5, 0, 15, 22, 2, 0, 6, 28, 5), ft(0, 8, 10, -5, 0, 16, 24, 2, 0, 6, 30, 5), ft(0, 8, 11, -5, 0, 17, 26, 2, 0, 6, 32, 5), ft(0, 9, 11, -5, 0, 18, 28, 2, 0, 7, 34, 6), ft(0, 9, 12, -6, 0, 19, 29, 2, 0, 7, 36, 6), ft(0, 10, 13, -6, 0, 20, 31, 3, 0, 8, 38, 7), ft(0, 10, 13, -6, 0, 21, 33, 3, 0, 8, 40, 7), ft(0, 10, 14, -6, 0, 22, 35, 3, 0, 8, 42, 7), ft(0, 11, 14, -7, 0, 23, 36, 3, 0, 9, 44, 8), ft(0, 11, 15, -7, 0, 24, 38, 3, 0, 9, 46, 8)], lw = sw, cw = ["duration", "easing", "delay"], dw = { +const qu = ["none", ft(0, 2, 1, -1, 0, 1, 1, 0, 0, 1, 3, 0), ft(0, 3, 1, -2, 0, 2, 2, 0, 0, 1, 5, 0), ft(0, 3, 3, -2, 0, 3, 4, 0, 0, 1, 8, 0), ft(0, 2, 4, -1, 0, 4, 5, 0, 0, 1, 10, 0), ft(0, 3, 5, -1, 0, 5, 8, 0, 0, 1, 14, 0), ft(0, 3, 5, -1, 0, 6, 10, 0, 0, 1, 18, 0), ft(0, 4, 5, -2, 0, 7, 10, 1, 0, 2, 16, 1), ft(0, 5, 5, -3, 0, 8, 10, 1, 0, 3, 14, 2), ft(0, 5, 6, -3, 0, 9, 12, 1, 0, 3, 16, 2), ft(0, 6, 6, -3, 0, 10, 14, 1, 0, 4, 18, 3), ft(0, 6, 7, -4, 0, 11, 15, 1, 0, 4, 20, 3), ft(0, 7, 8, -4, 0, 12, 17, 2, 0, 5, 22, 4), ft(0, 7, 8, -4, 0, 13, 19, 2, 0, 5, 24, 4), ft(0, 7, 9, -4, 0, 14, 21, 2, 0, 5, 26, 4), ft(0, 8, 9, -5, 0, 15, 22, 2, 0, 6, 28, 5), ft(0, 8, 10, -5, 0, 16, 24, 2, 0, 6, 30, 5), ft(0, 8, 11, -5, 0, 17, 26, 2, 0, 6, 32, 5), ft(0, 9, 11, -5, 0, 18, 28, 2, 0, 7, 34, 6), ft(0, 9, 12, -6, 0, 19, 29, 2, 0, 7, 36, 6), ft(0, 10, 13, -6, 0, 20, 31, 3, 0, 8, 38, 7), ft(0, 10, 13, -6, 0, 21, 33, 3, 0, 8, 40, 7), ft(0, 10, 14, -6, 0, 22, 35, 3, 0, 8, 42, 7), ft(0, 11, 14, -7, 0, 23, 36, 3, 0, 9, 44, 8), ft(0, 11, 15, -7, 0, 24, 38, 3, 0, 9, 46, 8)], Ku = qu, Ju = ["duration", "easing", "delay"], Zu = { // This is the most common easing curve. easeInOut: "cubic-bezier(0.4, 0, 0.2, 1)", // Objects enter the screen at full velocity from off-screen and @@ -6353,7 +6261,7 @@ const sw = ["none", ft(0, 2, 1, -1, 0, 1, 1, 0, 0, 1, 3, 0), ft(0, 3, 1, -2, 0, easeIn: "cubic-bezier(0.4, 0, 1, 1)", // The sharp curve is used by objects that may return to the screen at any time. sharp: "cubic-bezier(0.4, 0, 0.6, 1)" -}, pw = { +}, Qu = { shortest: 150, shorter: 200, short: 250, @@ -6366,38 +6274,38 @@ const sw = ["none", ft(0, 2, 1, -1, 0, 1, 1, 0, 0, 1, 3, 0), ft(0, 3, 1, -2, 0, // recommended when something is leaving screen leavingScreen: 195 }; -function Ia(t) { +function $a(t) { return `${Math.round(t)}ms`; } -function uw(t) { +function tw(t) { if (!t) return 0; const e = t / 36; return Math.round((4 + 15 * e ** 0.25 + e / 5) * 10); } -function ww(t) { - const e = P({}, dw, t.easing), n = P({}, pw, t.duration); - return P({ - getAutoHeightDuration: uw, +function ew(t) { + const e = _({}, Zu, t.easing), n = _({}, Qu, t.duration); + return _({ + getAutoHeightDuration: tw, create: (o = ["all"], a = {}) => { const { duration: i = n.standard, easing: l = e.easeInOut, delay: c = 0 - } = a, d = kt(a, cw); + } = a, d = Nt(a, Ju); if (process.env.NODE_ENV !== "production") { const p = (w) => typeof w == "string", f = (w) => !isNaN(parseFloat(w)); !p(o) && !Array.isArray(o) && console.error('MUI: Argument "props" must be a string or Array.'), !f(i) && !p(i) && console.error(`MUI: Argument "duration" must be a number or a string but found ${i}.`), p(l) || console.error('MUI: Argument "easing" must be a string.'), !f(c) && !p(c) && console.error('MUI: Argument "delay" must be a number or a string.'), typeof a != "object" && console.error(["MUI: Secong argument of transition.create must be an object.", "Arguments should be either `create('prop1', options)` or `create(['prop1', 'prop2'], options)`"].join(` `)), Object.keys(d).length !== 0 && console.error(`MUI: Unrecognized argument(s) [${Object.keys(d).join(",")}].`); } - return (Array.isArray(o) ? o : [o]).map((p) => `${p} ${typeof i == "string" ? i : Ia(i)} ${l} ${typeof c == "string" ? c : Ia(c)}`).join(","); + return (Array.isArray(o) ? o : [o]).map((p) => `${p} ${typeof i == "string" ? i : $a(i)} ${l} ${typeof c == "string" ? c : $a(c)}`).join(","); } }, t, { easing: e, duration: n }); } -const fw = { +const nw = { mobileStepper: 1e3, fab: 1050, speedDial: 1050, @@ -6406,25 +6314,25 @@ const fw = { modal: 1300, snackbar: 1400, tooltip: 1500 -}, mw = fw, hw = ["breakpoints", "mixins", "spacing", "palette", "transitions", "typography", "shape"]; -function gw(t = {}, ...e) { +}, rw = nw, ow = ["breakpoints", "mixins", "spacing", "palette", "transitions", "typography", "shape"]; +function aw(t = {}, ...e) { const { mixins: n = {}, palette: r = {}, transitions: o = {}, typography: a = {} - } = t, i = kt(t, hw); + } = t, i = Nt(t, ow); if (t.vars) throw new Error(process.env.NODE_ENV !== "production" ? "MUI: `vars` is a private field used for CSS variables support.\nPlease use another name." : Ve(18)); - const l = tw(r), c = To(t); + const l = Fu(r), c = So(t); let d = Zt(c, { - mixins: Bu(c.breakpoints, n), + mixins: Su(c.breakpoints, n), palette: l, // Don't use [...shadows] until you've verified its transpiled code is not invoking the iterator protocol. - shadows: lw.slice(), - typography: rw(l, a), - transitions: ww(o), - zIndex: P({}, mw) + shadows: Ku.slice(), + typography: Hu(l, a), + transitions: ew(o), + zIndex: _({}, rw) }); if (d = Zt(d, i), d = e.reduce((p, f) => Zt(p, f), d), process.env.NODE_ENV !== "production") { const p = ["active", "checked", "completed", "disabled", "error", "expanded", "focused", "focusVisible", "required", "selected"], f = (w, g) => { @@ -6450,35 +6358,35 @@ function gw(t = {}, ...e) { g && w.indexOf("Mui") === 0 && f(g, w); }); } - return d.unstable_sxConfig = P({}, Eo, i == null ? void 0 : i.unstable_sxConfig), d.unstable_sx = function(f) { - return So({ + return d.unstable_sxConfig = _({}, ko, i == null ? void 0 : i.unstable_sxConfig), d.unstable_sx = function(f) { + return Eo({ sx: f, theme: this }); }, d; } -const bw = gw(), Oo = bw, Ro = "$$material"; -function _o({ +const iw = aw(), Co = iw, Oo = "$$material"; +function Ro({ props: t, name: e }) { - return $u({ + return yu({ props: t, name: e, - defaultTheme: Oo, - themeId: Ro + defaultTheme: Co, + themeId: Oo }); } -const vw = (t) => Gn(t) && t !== "classes", yw = _u({ - themeId: Ro, - defaultTheme: Oo, - rootShouldForwardProp: vw -}), Rn = yw; -function xw(t) { +const sw = (t) => Gn(t) && t !== "classes", lw = bu({ + themeId: Oo, + defaultTheme: Co, + rootShouldForwardProp: sw +}), Rn = lw; +function cw(t) { return pr("MuiSvgIcon", t); } -ls("MuiSvgIcon", ["root", "colorPrimary", "colorSecondary", "colorAction", "colorError", "colorDisabled", "fontSizeInherit", "fontSizeSmall", "fontSizeMedium", "fontSizeLarge"]); -const Nw = ["children", "className", "color", "component", "fontSize", "htmlColor", "inheritViewBox", "titleAccess", "viewBox"], kw = (t) => { +os("MuiSvgIcon", ["root", "colorPrimary", "colorSecondary", "colorAction", "colorError", "colorDisabled", "fontSizeInherit", "fontSizeSmall", "fontSizeMedium", "fontSizeLarge"]); +const dw = ["children", "className", "color", "component", "fontSize", "htmlColor", "inheritViewBox", "titleAccess", "viewBox"], pw = (t) => { const { color: e, fontSize: n, @@ -6486,8 +6394,8 @@ const Nw = ["children", "className", "color", "component", "fontSize", "htmlColo } = t, o = { root: ["root", e !== "inherit" && `color${Wt(e)}`, `fontSize${Wt(n)}`] }; - return xo(o, xw, r); -}, Ew = Rn("svg", { + return yo(o, cw, r); +}, uw = Rn("svg", { name: "MuiSvgIcon", slot: "Root", overridesResolver: (t, e) => { @@ -6526,8 +6434,8 @@ const Nw = ["children", "className", "color", "component", "fontSize", "htmlColo inherit: void 0 }[e.color] }; -}), Po = /* @__PURE__ */ M.forwardRef(function(e, n) { - const r = _o({ +}), _o = /* @__PURE__ */ D.forwardRef(function(e, n) { + const r = Ro({ props: e, name: "MuiSvgIcon" }), { @@ -6540,7 +6448,7 @@ const Nw = ["children", "className", "color", "component", "fontSize", "htmlColo inheritViewBox: p = !1, titleAccess: f, viewBox: w = "0 0 24 24" - } = r, g = kt(r, Nw), v = /* @__PURE__ */ M.isValidElement(o) && o.type === "svg", m = P({}, r, { + } = r, g = Nt(r, dw), v = /* @__PURE__ */ D.isValidElement(o) && o.type === "svg", m = _({}, r, { color: i, component: l, fontSize: c, @@ -6550,10 +6458,10 @@ const Nw = ["children", "className", "color", "component", "fontSize", "htmlColo hasSvgAsChild: v }), h = {}; p || (h.viewBox = w); - const S = kw(m); - return /* @__PURE__ */ N(Ew, P({ + const T = pw(m); + return /* @__PURE__ */ x(uw, _({ as: l, - className: be(S.root, a), + className: be(T.root, a), focusable: "false", color: d, "aria-hidden": f ? void 0 : !0, @@ -6566,7 +6474,7 @@ const Nw = ["children", "className", "color", "component", "fontSize", "htmlColo }) : null] })); }); -process.env.NODE_ENV !== "production" && (Po.propTypes = { +process.env.NODE_ENV !== "production" && (_o.propTypes = { // ┌────────────────────────────── Warning ──────────────────────────────┐ // │ These PropTypes are generated from the TypeScript type definitions. │ // │ To update them, edit the d.ts file and run `pnpm proptypes`. │ @@ -6638,48 +6546,48 @@ process.env.NODE_ENV !== "production" && (Po.propTypes = { */ viewBox: u.string }); -Po.muiName = "SvgIcon"; -const Aa = Po; -function ms(t, e) { +_o.muiName = "SvgIcon"; +const Ia = _o; +function ps(t, e) { function n(r, o) { - return /* @__PURE__ */ s(Aa, P({ + return /* @__PURE__ */ s(Ia, _({ "data-testid": `${e}Icon`, ref: o }, r, { children: t })); } - return process.env.NODE_ENV !== "production" && (n.displayName = `${e}Icon`), n.muiName = Aa.muiName, /* @__PURE__ */ M.memo(/* @__PURE__ */ M.forwardRef(n)); + return process.env.NODE_ENV !== "production" && (n.displayName = `${e}Icon`), n.muiName = Ia.muiName, /* @__PURE__ */ D.memo(/* @__PURE__ */ D.forwardRef(n)); } -const Sw = { +const ww = { configure: (t) => { process.env.NODE_ENV !== "production" && console.warn(["MUI: `ClassNameGenerator` import from `@mui/material/utils` is outdated and might cause unexpected issues.", "", "You should use `import { unstable_ClassNameGenerator } from '@mui/material/className'` instead", "", "The detail of the issue: https://github.com/mui/material-ui/issues/30011#issuecomment-1024993401", "", "The updated documentation: https://mui.com/guides/classname-generator/"].join(` -`)), is.configure(t); +`)), ns.configure(t); } -}, Tw = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({ +}, fw = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({ __proto__: null, capitalize: Wt, - createChainedFunction: ep, - createSvgIcon: ms, - debounce: np, - deprecatedPropType: rp, - isMuiElement: op, + createChainedFunction: Ud, + createSvgIcon: ps, + debounce: Gd, + deprecatedPropType: Hd, + isMuiElement: Xd, ownerDocument: Yn, - ownerWindow: ap, - requirePropFactory: ip, + ownerWindow: Yd, + requirePropFactory: Wd, setRef: Wn, - unstable_ClassNameGenerator: Sw, + unstable_ClassNameGenerator: ww, unstable_useEnhancedEffect: ze, - unstable_useId: ns, - unsupportedProp: cp, - useControlled: rs, - useEventCallback: eo, + unstable_useId: Zi, + unsupportedProp: Jd, + useControlled: Qi, + useEventCallback: to, useForkRef: xe, - useIsFocusVisible: os -}, Symbol.toStringTag, { value: "Module" })), Cw = /* @__PURE__ */ Md(Tw); -var Ma; -function Ow() { - return Ma || (Ma = 1, function(t) { + useIsFocusVisible: ts +}, Symbol.toStringTag, { value: "Module" })), mw = /* @__PURE__ */ kd(fw); +var Aa; +function hw() { + return Aa || (Aa = 1, function(t) { "use client"; Object.defineProperty(t, "__esModule", { value: !0 @@ -6689,35 +6597,35 @@ function Ow() { return e.createSvgIcon; } }); - var e = Cw; - }(Ar)), Ar; + var e = mw; + }(Ir)), Ir; } -var Rw = Dd; -Object.defineProperty(bo, "__esModule", { +var gw = Ed; +Object.defineProperty(go, "__esModule", { value: !0 }); -var hs = bo.default = void 0, _w = Rw(Ow()), Pw = Ks; -hs = bo.default = (0, _w.default)(/* @__PURE__ */ (0, Pw.jsx)("path", { +var us = go.default = void 0, bw = gw(hw()), vw = Xs; +us = go.default = (0, bw.default)(/* @__PURE__ */ (0, vw.jsx)("path", { d: "m10 17 5-5-5-5z" }), "ArrowRight"); -function $w(t) { +function yw(t) { return typeof t == "string"; } -function ln(t, e, n) { - return t === void 0 || $w(t) ? e : P({}, e, { - ownerState: P({}, e.ownerState, n) +function sn(t, e, n) { + return t === void 0 || yw(t) ? e : _({}, e, { + ownerState: _({}, e.ownerState, n) }); } -const Iw = { +const xw = { disableDefaultClasses: !1 -}, Aw = /* @__PURE__ */ M.createContext(Iw); -function Mw(t) { +}, Nw = /* @__PURE__ */ D.createContext(xw); +function kw(t) { const { disableDefaultClasses: e - } = M.useContext(Aw); + } = D.useContext(Nw); return (n) => e ? "" : t(n); } -function Dw(t, e = []) { +function Ew(t, e = []) { if (t === void 0) return {}; const n = {}; @@ -6725,10 +6633,10 @@ function Dw(t, e = []) { n[r] = t[r]; }), n; } -function Bw(t, e, n) { +function Sw(t, e, n) { return typeof t == "function" ? t(e, n) : t; } -function Da(t) { +function Ma(t) { if (t === void 0) return {}; const e = {}; @@ -6736,7 +6644,7 @@ function Da(t) { e[n] = t[n]; }), e; } -function jw(t) { +function Tw(t) { const { getSlotProps: e, additionalProps: n, @@ -6745,82 +6653,82 @@ function jw(t) { className: a } = t; if (!e) { - const g = be(n == null ? void 0 : n.className, a, o == null ? void 0 : o.className, r == null ? void 0 : r.className), v = P({}, n == null ? void 0 : n.style, o == null ? void 0 : o.style, r == null ? void 0 : r.style), m = P({}, n, o, r); + const g = be(n == null ? void 0 : n.className, a, o == null ? void 0 : o.className, r == null ? void 0 : r.className), v = _({}, n == null ? void 0 : n.style, o == null ? void 0 : o.style, r == null ? void 0 : r.style), m = _({}, n, o, r); return g.length > 0 && (m.className = g), Object.keys(v).length > 0 && (m.style = v), { props: m, internalRef: void 0 }; } - const i = Dw(P({}, o, r)), l = Da(r), c = Da(o), d = e(i), p = be(d == null ? void 0 : d.className, n == null ? void 0 : n.className, a, o == null ? void 0 : o.className, r == null ? void 0 : r.className), f = P({}, d == null ? void 0 : d.style, n == null ? void 0 : n.style, o == null ? void 0 : o.style, r == null ? void 0 : r.style), w = P({}, d, n, c, l); + const i = Ew(_({}, o, r)), l = Ma(r), c = Ma(o), d = e(i), p = be(d == null ? void 0 : d.className, n == null ? void 0 : n.className, a, o == null ? void 0 : o.className, r == null ? void 0 : r.className), f = _({}, d == null ? void 0 : d.style, n == null ? void 0 : n.style, o == null ? void 0 : o.style, r == null ? void 0 : r.style), w = _({}, d, n, c, l); return p.length > 0 && (w.className = p), Object.keys(f).length > 0 && (w.style = f), { props: w, internalRef: d.ref }; } -const Vw = ["elementType", "externalSlotProps", "ownerState", "skipResolvingSlotProps"]; -function zw(t) { +const Cw = ["elementType", "externalSlotProps", "ownerState", "skipResolvingSlotProps"]; +function Ow(t) { var e; const { elementType: n, externalSlotProps: r, ownerState: o, skipResolvingSlotProps: a = !1 - } = t, i = kt(t, Vw), l = a ? {} : Bw(r, o), { + } = t, i = Nt(t, Cw), l = a ? {} : Sw(r, o), { props: c, internalRef: d - } = jw(P({}, i, { + } = Tw(_({}, i, { externalSlotProps: l })), p = xe(d, l == null ? void 0 : l.ref, (e = t.additionalProps) == null ? void 0 : e.ref); - return ln(n, P({}, c, { + return sn(n, _({}, c, { ref: p }), o); } -const gs = "base"; -function Lw(t) { - return `${gs}--${t}`; +const ws = "base"; +function Rw(t) { + return `${ws}--${t}`; } -function Fw(t, e) { - return `${gs}-${t}-${e}`; +function _w(t, e) { + return `${ws}-${t}-${e}`; } -function bs(t, e) { - const n = ss[e]; - return n ? Lw(n) : Fw(t, e); +function fs(t, e) { + const n = rs[e]; + return n ? Rw(n) : _w(t, e); } -function Uw(t, e) { +function Pw(t, e) { const n = {}; return e.forEach((r) => { - n[r] = bs(t, r); + n[r] = fs(t, r); }), n; } -function Gw(t) { +function $w(t) { return typeof t == "function" ? t() : t; } -const Kn = /* @__PURE__ */ M.forwardRef(function(e, n) { +const Kn = /* @__PURE__ */ D.forwardRef(function(e, n) { const { children: r, container: o, disablePortal: a = !1 - } = e, [i, l] = M.useState(null), c = xe(/* @__PURE__ */ M.isValidElement(r) ? r.ref : null, n); + } = e, [i, l] = D.useState(null), c = xe(/* @__PURE__ */ D.isValidElement(r) ? r.ref : null, n); if (ze(() => { - a || l(Gw(o) || document.body); + a || l($w(o) || document.body); }, [o, a]), ze(() => { if (i && !a) return Wn(n, i), () => { Wn(n, null); }; }, [n, i, a]), a) { - if (/* @__PURE__ */ M.isValidElement(r)) { + if (/* @__PURE__ */ D.isValidElement(r)) { const d = { ref: c }; - return /* @__PURE__ */ M.cloneElement(r, d); + return /* @__PURE__ */ D.cloneElement(r, d); } - return /* @__PURE__ */ s(M.Fragment, { + return /* @__PURE__ */ s(D.Fragment, { children: r }); } - return /* @__PURE__ */ s(M.Fragment, { - children: i && /* @__PURE__ */ Gl.createPortal(r, i) + return /* @__PURE__ */ s(D.Fragment, { + children: i && /* @__PURE__ */ Ll.createPortal(r, i) }); }); process.env.NODE_ENV !== "production" && (Kn.propTypes = { @@ -6842,23 +6750,23 @@ process.env.NODE_ENV !== "production" && (Kn.propTypes = { * By default, it uses the body of the top-level document object, * so it's simply `document.body` most of the time. */ - container: u.oneOfType([yn, u.func]), + container: u.oneOfType([vn, u.func]), /** * The `children` will be under the DOM hierarchy of the parent component. * @default false */ disablePortal: u.bool }); -process.env.NODE_ENV !== "production" && (Kn["propTypes"] = Wd(Kn.propTypes)); -var Ct = "top", Vt = "bottom", zt = "right", Ot = "left", $o = "auto", _n = [Ct, Vt, zt, Ot], Le = "start", Nn = "end", Hw = "clippingParents", vs = "viewport", rn = "popper", Xw = "reference", Ba = /* @__PURE__ */ _n.reduce(function(t, e) { - return t.concat([e + "-" + Le, e + "-" + Nn]); -}, []), ys = /* @__PURE__ */ [].concat(_n, [$o]).reduce(function(t, e) { - return t.concat([e, e + "-" + Le, e + "-" + Nn]); -}, []), Yw = "beforeRead", Ww = "read", qw = "afterRead", Kw = "beforeMain", Jw = "main", Zw = "afterMain", Qw = "beforeWrite", tf = "write", ef = "afterWrite", nf = [Yw, Ww, qw, Kw, Jw, Zw, Qw, tf, ef]; +process.env.NODE_ENV !== "production" && (Kn["propTypes"] = Dd(Kn.propTypes)); +var Tt = "top", jt = "bottom", Vt = "right", Ct = "left", Po = "auto", _n = [Tt, jt, Vt, Ct], Le = "start", xn = "end", Iw = "clippingParents", ms = "viewport", nn = "popper", Aw = "reference", Da = /* @__PURE__ */ _n.reduce(function(t, e) { + return t.concat([e + "-" + Le, e + "-" + xn]); +}, []), hs = /* @__PURE__ */ [].concat(_n, [Po]).reduce(function(t, e) { + return t.concat([e, e + "-" + Le, e + "-" + xn]); +}, []), Mw = "beforeRead", Dw = "read", Bw = "afterRead", jw = "beforeMain", Vw = "main", zw = "afterMain", Lw = "beforeWrite", Fw = "write", Uw = "afterWrite", Gw = [Mw, Dw, Bw, jw, Vw, zw, Lw, Fw, Uw]; function qt(t) { return t ? (t.nodeName || "").toLowerCase() : null; } -function Mt(t) { +function At(t) { if (t == null) return window; if (t.toString() !== "[object Window]") { @@ -6868,30 +6776,30 @@ function Mt(t) { return t; } function ke(t) { - var e = Mt(t).Element; + var e = At(t).Element; return t instanceof e || t instanceof Element; } -function jt(t) { - var e = Mt(t).HTMLElement; +function Bt(t) { + var e = At(t).HTMLElement; return t instanceof e || t instanceof HTMLElement; } -function Io(t) { +function $o(t) { if (typeof ShadowRoot > "u") return !1; - var e = Mt(t).ShadowRoot; + var e = At(t).ShadowRoot; return t instanceof e || t instanceof ShadowRoot; } -function rf(t) { +function Hw(t) { var e = t.state; Object.keys(e.elements).forEach(function(n) { var r = e.styles[n] || {}, o = e.attributes[n] || {}, a = e.elements[n]; - !jt(a) || !qt(a) || (Object.assign(a.style, r), Object.keys(o).forEach(function(i) { + !Bt(a) || !qt(a) || (Object.assign(a.style, r), Object.keys(o).forEach(function(i) { var l = o[i]; l === !1 ? a.removeAttribute(i) : a.setAttribute(i, l === !0 ? "" : l); })); }); } -function of(t) { +function Xw(t) { var e = t.state, n = { popper: { position: e.options.strategy, @@ -6909,38 +6817,38 @@ function of(t) { var o = e.elements[r], a = e.attributes[r] || {}, i = Object.keys(e.styles.hasOwnProperty(r) ? e.styles[r] : n[r]), l = i.reduce(function(c, d) { return c[d] = "", c; }, {}); - !jt(o) || !qt(o) || (Object.assign(o.style, l), Object.keys(a).forEach(function(c) { + !Bt(o) || !qt(o) || (Object.assign(o.style, l), Object.keys(a).forEach(function(c) { o.removeAttribute(c); })); }); }; } -const af = { +const Yw = { name: "applyStyles", enabled: !0, phase: "write", - fn: rf, - effect: of, + fn: Hw, + effect: Xw, requires: ["computeStyles"] }; -function Yt(t) { +function Xt(t) { return t.split("-")[0]; } var ve = Math.max, Jn = Math.min, Fe = Math.round; -function ro() { +function no() { var t = navigator.userAgentData; return t != null && t.brands && Array.isArray(t.brands) ? t.brands.map(function(e) { return e.brand + "/" + e.version; }).join(" ") : navigator.userAgent; } -function xs() { - return !/^((?!chrome|android).)*safari/i.test(ro()); +function gs() { + return !/^((?!chrome|android).)*safari/i.test(no()); } function Ue(t, e, n) { e === void 0 && (e = !1), n === void 0 && (n = !1); var r = t.getBoundingClientRect(), o = 1, a = 1; - e && jt(t) && (o = t.offsetWidth > 0 && Fe(r.width) / t.offsetWidth || 1, a = t.offsetHeight > 0 && Fe(r.height) / t.offsetHeight || 1); - var i = ke(t) ? Mt(t) : window, l = i.visualViewport, c = !xs() && n, d = (r.left + (c && l ? l.offsetLeft : 0)) / o, p = (r.top + (c && l ? l.offsetTop : 0)) / a, f = r.width / o, w = r.height / a; + e && Bt(t) && (o = t.offsetWidth > 0 && Fe(r.width) / t.offsetWidth || 1, a = t.offsetHeight > 0 && Fe(r.height) / t.offsetHeight || 1); + var i = ke(t) ? At(t) : window, l = i.visualViewport, c = !gs() && n, d = (r.left + (c && l ? l.offsetLeft : 0)) / o, p = (r.top + (c && l ? l.offsetTop : 0)) / a, f = r.width / o, w = r.height / a; return { width: f, height: w, @@ -6952,7 +6860,7 @@ function Ue(t, e, n) { y: p }; } -function Ao(t) { +function Io(t) { var e = Ue(t), n = t.offsetWidth, r = t.offsetHeight; return Math.abs(e.width - n) <= 1 && (n = e.width), Math.abs(e.height - r) <= 1 && (r = e.height), { x: t.offsetLeft, @@ -6961,11 +6869,11 @@ function Ao(t) { height: r }; } -function Ns(t, e) { +function bs(t, e) { var n = e.getRootNode && e.getRootNode(); if (t.contains(e)) return !0; - if (n && Io(n)) { + if (n && $o(n)) { var r = e; do { if (r && t.isSameNode(r)) @@ -6976,9 +6884,9 @@ function Ns(t, e) { return !1; } function te(t) { - return Mt(t).getComputedStyle(t); + return At(t).getComputedStyle(t); } -function sf(t) { +function Ww(t) { return ["table", "td", "th"].indexOf(qt(t)) >= 0; } function le(t) { @@ -6994,24 +6902,24 @@ function xr(t) { // $FlowFixMe[prop-missing] t.assignedSlot || // step into the shadow DOM of the parent of a slotted node t.parentNode || // DOM Element detected - (Io(t) ? t.host : null) || // ShadowRoot detected + ($o(t) ? t.host : null) || // ShadowRoot detected // $FlowFixMe[incompatible-call]: HTMLElement is a Node le(t) ); } -function ja(t) { - return !jt(t) || // https://github.com/popperjs/popper-core/issues/837 +function Ba(t) { + return !Bt(t) || // https://github.com/popperjs/popper-core/issues/837 te(t).position === "fixed" ? null : t.offsetParent; } -function lf(t) { - var e = /firefox/i.test(ro()), n = /Trident/i.test(ro()); - if (n && jt(t)) { +function qw(t) { + var e = /firefox/i.test(no()), n = /Trident/i.test(no()); + if (n && Bt(t)) { var r = te(t); if (r.position === "fixed") return null; } var o = xr(t); - for (Io(o) && (o = o.host); jt(o) && ["html", "body"].indexOf(qt(o)) < 0; ) { + for ($o(o) && (o = o.host); Bt(o) && ["html", "body"].indexOf(qt(o)) < 0; ) { var a = te(o); if (a.transform !== "none" || a.perspective !== "none" || a.contain === "paint" || ["transform", "perspective"].indexOf(a.willChange) !== -1 || e && a.willChange === "filter" || e && a.filter && a.filter !== "none") return o; @@ -7020,21 +6928,21 @@ function lf(t) { return null; } function Pn(t) { - for (var e = Mt(t), n = ja(t); n && sf(n) && te(n).position === "static"; ) - n = ja(n); - return n && (qt(n) === "html" || qt(n) === "body" && te(n).position === "static") ? e : n || lf(t) || e; + for (var e = At(t), n = Ba(t); n && Ww(n) && te(n).position === "static"; ) + n = Ba(n); + return n && (qt(n) === "html" || qt(n) === "body" && te(n).position === "static") ? e : n || qw(t) || e; } -function Mo(t) { +function Ao(t) { return ["top", "bottom"].indexOf(t) >= 0 ? "x" : "y"; } -function wn(t, e, n) { +function un(t, e, n) { return ve(t, Jn(e, n)); } -function cf(t, e, n) { - var r = wn(t, e, n); +function Kw(t, e, n) { + var r = un(t, e, n); return r > n ? n : r; } -function ks() { +function vs() { return { top: 0, right: 0, @@ -7042,56 +6950,56 @@ function ks() { left: 0 }; } -function Es(t) { - return Object.assign({}, ks(), t); +function ys(t) { + return Object.assign({}, vs(), t); } -function Ss(t, e) { +function xs(t, e) { return e.reduce(function(n, r) { return n[r] = t, n; }, {}); } -var df = function(e, n) { +var Jw = function(e, n) { return e = typeof e == "function" ? e(Object.assign({}, n.rects, { placement: n.placement - })) : e, Es(typeof e != "number" ? e : Ss(e, _n)); + })) : e, ys(typeof e != "number" ? e : xs(e, _n)); }; -function pf(t) { - var e, n = t.state, r = t.name, o = t.options, a = n.elements.arrow, i = n.modifiersData.popperOffsets, l = Yt(n.placement), c = Mo(l), d = [Ot, zt].indexOf(l) >= 0, p = d ? "height" : "width"; +function Zw(t) { + var e, n = t.state, r = t.name, o = t.options, a = n.elements.arrow, i = n.modifiersData.popperOffsets, l = Xt(n.placement), c = Ao(l), d = [Ct, Vt].indexOf(l) >= 0, p = d ? "height" : "width"; if (!(!a || !i)) { - var f = df(o.padding, n), w = Ao(a), g = c === "y" ? Ct : Ot, v = c === "y" ? Vt : zt, m = n.rects.reference[p] + n.rects.reference[c] - i[c] - n.rects.popper[p], h = i[c] - n.rects.reference[c], S = Pn(a), _ = S ? c === "y" ? S.clientHeight || 0 : S.clientWidth || 0 : 0, C = m / 2 - h / 2, T = f[g], b = _ - w[p] - f[v], I = _ / 2 - w[p] / 2 + C, z = wn(T, I, b), H = c; - n.modifiersData[r] = (e = {}, e[H] = z, e.centerOffset = z - I, e); + var f = Jw(o.padding, n), w = Io(a), g = c === "y" ? Tt : Ct, v = c === "y" ? jt : Vt, m = n.rects.reference[p] + n.rects.reference[c] - i[c] - n.rects.popper[p], h = i[c] - n.rects.reference[c], T = Pn(a), A = T ? c === "y" ? T.clientHeight || 0 : T.clientWidth || 0 : 0, R = m / 2 - h / 2, E = f[g], b = A - w[p] - f[v], $ = A / 2 - w[p] / 2 + R, z = un(E, $, b), H = c; + n.modifiersData[r] = (e = {}, e[H] = z, e.centerOffset = z - $, e); } } -function uf(t) { +function Qw(t) { var e = t.state, n = t.options, r = n.element, o = r === void 0 ? "[data-popper-arrow]" : r; - o != null && (typeof o == "string" && (o = e.elements.popper.querySelector(o), !o) || Ns(e.elements.popper, o) && (e.elements.arrow = o)); + o != null && (typeof o == "string" && (o = e.elements.popper.querySelector(o), !o) || bs(e.elements.popper, o) && (e.elements.arrow = o)); } -const wf = { +const tf = { name: "arrow", enabled: !0, phase: "main", - fn: pf, - effect: uf, + fn: Zw, + effect: Qw, requires: ["popperOffsets"], requiresIfExists: ["preventOverflow"] }; function Ge(t) { return t.split("-")[1]; } -var ff = { +var ef = { top: "auto", right: "auto", bottom: "auto", left: "auto" }; -function mf(t, e) { +function nf(t, e) { var n = t.x, r = t.y, o = e.devicePixelRatio || 1; return { x: Fe(n * o) / o || 0, y: Fe(r * o) / o || 0 }; } -function Va(t) { +function ja(t) { var e, n = t.popper, r = t.popperRect, o = t.placement, a = t.variation, i = t.offsets, l = t.position, c = t.gpuAcceleration, d = t.adaptive, p = t.roundOffsets, f = t.isFixed, w = i.x, g = w === void 0 ? 0 : w, v = i.y, m = v === void 0 ? 0 : v, h = typeof p == "function" ? p({ x: g, y: m @@ -7100,56 +7008,56 @@ function Va(t) { y: m }; g = h.x, m = h.y; - var S = i.hasOwnProperty("x"), _ = i.hasOwnProperty("y"), C = Ot, T = Ct, b = window; + var T = i.hasOwnProperty("x"), A = i.hasOwnProperty("y"), R = Ct, E = Tt, b = window; if (d) { - var I = Pn(n), z = "clientHeight", H = "clientWidth"; - if (I === Mt(n) && (I = le(n), te(I).position !== "static" && l === "absolute" && (z = "scrollHeight", H = "scrollWidth")), I = I, o === Ct || (o === Ot || o === zt) && a === Nn) { - T = Vt; - var O = f && I === b && b.visualViewport ? b.visualViewport.height : ( + var $ = Pn(n), z = "clientHeight", H = "clientWidth"; + if ($ === At(n) && ($ = le(n), te($).position !== "static" && l === "absolute" && (z = "scrollHeight", H = "scrollWidth")), $ = $, o === Tt || (o === Ct || o === Vt) && a === xn) { + E = jt; + var C = f && $ === b && b.visualViewport ? b.visualViewport.height : ( // $FlowFixMe[prop-missing] - I[z] + $[z] ); - m -= O - r.height, m *= c ? 1 : -1; + m -= C - r.height, m *= c ? 1 : -1; } - if (o === Ot || (o === Ct || o === Vt) && a === Nn) { - C = zt; - var $ = f && I === b && b.visualViewport ? b.visualViewport.width : ( + if (o === Ct || (o === Tt || o === jt) && a === xn) { + R = Vt; + var P = f && $ === b && b.visualViewport ? b.visualViewport.width : ( // $FlowFixMe[prop-missing] - I[H] + $[H] ); - g -= $ - r.width, g *= c ? 1 : -1; + g -= P - r.width, g *= c ? 1 : -1; } } var k = Object.assign({ position: l - }, d && ff), B = p === !0 ? mf({ + }, d && ef), B = p === !0 ? nf({ x: g, y: m - }, Mt(n)) : { + }, At(n)) : { x: g, y: m }; if (g = B.x, m = B.y, c) { - var D; - return Object.assign({}, k, (D = {}, D[T] = _ ? "0" : "", D[C] = S ? "0" : "", D.transform = (b.devicePixelRatio || 1) <= 1 ? "translate(" + g + "px, " + m + "px)" : "translate3d(" + g + "px, " + m + "px, 0)", D)); + var M; + return Object.assign({}, k, (M = {}, M[E] = A ? "0" : "", M[R] = T ? "0" : "", M.transform = (b.devicePixelRatio || 1) <= 1 ? "translate(" + g + "px, " + m + "px)" : "translate3d(" + g + "px, " + m + "px, 0)", M)); } - return Object.assign({}, k, (e = {}, e[T] = _ ? m + "px" : "", e[C] = S ? g + "px" : "", e.transform = "", e)); + return Object.assign({}, k, (e = {}, e[E] = A ? m + "px" : "", e[R] = T ? g + "px" : "", e.transform = "", e)); } -function hf(t) { +function rf(t) { var e = t.state, n = t.options, r = n.gpuAcceleration, o = r === void 0 ? !0 : r, a = n.adaptive, i = a === void 0 ? !0 : a, l = n.roundOffsets, c = l === void 0 ? !0 : l, d = { - placement: Yt(e.placement), + placement: Xt(e.placement), variation: Ge(e.placement), popper: e.elements.popper, popperRect: e.rects.popper, gpuAcceleration: o, isFixed: e.options.strategy === "fixed" }; - e.modifiersData.popperOffsets != null && (e.styles.popper = Object.assign({}, e.styles.popper, Va(Object.assign({}, d, { + e.modifiersData.popperOffsets != null && (e.styles.popper = Object.assign({}, e.styles.popper, ja(Object.assign({}, d, { offsets: e.modifiersData.popperOffsets, position: e.options.strategy, adaptive: i, roundOffsets: c - })))), e.modifiersData.arrow != null && (e.styles.arrow = Object.assign({}, e.styles.arrow, Va(Object.assign({}, d, { + })))), e.modifiersData.arrow != null && (e.styles.arrow = Object.assign({}, e.styles.arrow, ja(Object.assign({}, d, { offsets: e.modifiersData.arrow, position: "absolute", adaptive: !1, @@ -7158,18 +7066,18 @@ function hf(t) { "data-popper-placement": e.placement }); } -const gf = { +const of = { name: "computeStyles", enabled: !0, phase: "beforeWrite", - fn: hf, + fn: rf, data: {} }; var zn = { passive: !0 }; -function bf(t) { - var e = t.state, n = t.instance, r = t.options, o = r.scroll, a = o === void 0 ? !0 : o, i = r.resize, l = i === void 0 ? !0 : i, c = Mt(e.elements.popper), d = [].concat(e.scrollParents.reference, e.scrollParents.popper); +function af(t) { + var e = t.state, n = t.instance, r = t.options, o = r.scroll, a = o === void 0 ? !0 : o, i = r.resize, l = i === void 0 ? !0 : i, c = At(e.elements.popper), d = [].concat(e.scrollParents.reference, e.scrollParents.popper); return a && d.forEach(function(p) { p.addEventListener("scroll", n.update, zn); }), l && c.addEventListener("resize", n.update, zn), function() { @@ -7178,16 +7086,16 @@ function bf(t) { }), l && c.removeEventListener("resize", n.update, zn); }; } -const vf = { +const sf = { name: "eventListeners", enabled: !0, phase: "write", fn: function() { }, - effect: bf, + effect: af, data: {} }; -var yf = { +var lf = { left: "right", right: "left", bottom: "top", @@ -7195,44 +7103,44 @@ var yf = { }; function Xn(t) { return t.replace(/left|right|bottom|top/g, function(e) { - return yf[e]; + return lf[e]; }); } -var xf = { +var cf = { start: "end", end: "start" }; -function za(t) { +function Va(t) { return t.replace(/start|end/g, function(e) { - return xf[e]; + return cf[e]; }); } -function Do(t) { - var e = Mt(t), n = e.pageXOffset, r = e.pageYOffset; +function Mo(t) { + var e = At(t), n = e.pageXOffset, r = e.pageYOffset; return { scrollLeft: n, scrollTop: r }; } -function Bo(t) { - return Ue(le(t)).left + Do(t).scrollLeft; +function Do(t) { + return Ue(le(t)).left + Mo(t).scrollLeft; } -function Nf(t, e) { - var n = Mt(t), r = le(t), o = n.visualViewport, a = r.clientWidth, i = r.clientHeight, l = 0, c = 0; +function df(t, e) { + var n = At(t), r = le(t), o = n.visualViewport, a = r.clientWidth, i = r.clientHeight, l = 0, c = 0; if (o) { a = o.width, i = o.height; - var d = xs(); + var d = gs(); (d || !d && e === "fixed") && (l = o.offsetLeft, c = o.offsetTop); } return { width: a, height: i, - x: l + Bo(t), + x: l + Do(t), y: c }; } -function kf(t) { - var e, n = le(t), r = Do(t), o = (e = t.ownerDocument) == null ? void 0 : e.body, a = ve(n.scrollWidth, n.clientWidth, o ? o.scrollWidth : 0, o ? o.clientWidth : 0), i = ve(n.scrollHeight, n.clientHeight, o ? o.scrollHeight : 0, o ? o.clientHeight : 0), l = -r.scrollLeft + Bo(t), c = -r.scrollTop; +function pf(t) { + var e, n = le(t), r = Mo(t), o = (e = t.ownerDocument) == null ? void 0 : e.body, a = ve(n.scrollWidth, n.clientWidth, o ? o.scrollWidth : 0, o ? o.clientWidth : 0), i = ve(n.scrollHeight, n.clientHeight, o ? o.scrollHeight : 0, o ? o.clientHeight : 0), l = -r.scrollLeft + Do(t), c = -r.scrollTop; return te(o || n).direction === "rtl" && (l += ve(n.clientWidth, o ? o.clientWidth : 0) - a), { width: a, height: i, @@ -7240,23 +7148,23 @@ function kf(t) { y: c }; } -function jo(t) { +function Bo(t) { var e = te(t), n = e.overflow, r = e.overflowX, o = e.overflowY; return /auto|scroll|overlay|hidden/.test(n + o + r); } -function Ts(t) { - return ["html", "body", "#document"].indexOf(qt(t)) >= 0 ? t.ownerDocument.body : jt(t) && jo(t) ? t : Ts(xr(t)); +function Ns(t) { + return ["html", "body", "#document"].indexOf(qt(t)) >= 0 ? t.ownerDocument.body : Bt(t) && Bo(t) ? t : Ns(xr(t)); } -function fn(t, e) { +function wn(t, e) { var n; e === void 0 && (e = []); - var r = Ts(t), o = r === ((n = t.ownerDocument) == null ? void 0 : n.body), a = Mt(r), i = o ? [a].concat(a.visualViewport || [], jo(r) ? r : []) : r, l = e.concat(i); + var r = Ns(t), o = r === ((n = t.ownerDocument) == null ? void 0 : n.body), a = At(r), i = o ? [a].concat(a.visualViewport || [], Bo(r) ? r : []) : r, l = e.concat(i); return o ? l : ( // $FlowFixMe[incompatible-call]: isBody tells us target will be an HTMLElement here - l.concat(fn(xr(i))) + l.concat(wn(xr(i))) ); } -function oo(t) { +function ro(t) { return Object.assign({}, t, { left: t.x, top: t.y, @@ -7264,48 +7172,48 @@ function oo(t) { bottom: t.y + t.height }); } -function Ef(t, e) { +function uf(t, e) { var n = Ue(t, !1, e === "fixed"); return n.top = n.top + t.clientTop, n.left = n.left + t.clientLeft, n.bottom = n.top + t.clientHeight, n.right = n.left + t.clientWidth, n.width = t.clientWidth, n.height = t.clientHeight, n.x = n.left, n.y = n.top, n; } -function La(t, e, n) { - return e === vs ? oo(Nf(t, n)) : ke(e) ? Ef(e, n) : oo(kf(le(t))); +function za(t, e, n) { + return e === ms ? ro(df(t, n)) : ke(e) ? uf(e, n) : ro(pf(le(t))); } -function Sf(t) { - var e = fn(xr(t)), n = ["absolute", "fixed"].indexOf(te(t).position) >= 0, r = n && jt(t) ? Pn(t) : t; +function wf(t) { + var e = wn(xr(t)), n = ["absolute", "fixed"].indexOf(te(t).position) >= 0, r = n && Bt(t) ? Pn(t) : t; return ke(r) ? e.filter(function(o) { - return ke(o) && Ns(o, r) && qt(o) !== "body"; + return ke(o) && bs(o, r) && qt(o) !== "body"; }) : []; } -function Tf(t, e, n, r) { - var o = e === "clippingParents" ? Sf(t) : [].concat(e), a = [].concat(o, [n]), i = a[0], l = a.reduce(function(c, d) { - var p = La(t, d, r); +function ff(t, e, n, r) { + var o = e === "clippingParents" ? wf(t) : [].concat(e), a = [].concat(o, [n]), i = a[0], l = a.reduce(function(c, d) { + var p = za(t, d, r); return c.top = ve(p.top, c.top), c.right = Jn(p.right, c.right), c.bottom = Jn(p.bottom, c.bottom), c.left = ve(p.left, c.left), c; - }, La(t, i, r)); + }, za(t, i, r)); return l.width = l.right - l.left, l.height = l.bottom - l.top, l.x = l.left, l.y = l.top, l; } -function Cs(t) { - var e = t.reference, n = t.element, r = t.placement, o = r ? Yt(r) : null, a = r ? Ge(r) : null, i = e.x + e.width / 2 - n.width / 2, l = e.y + e.height / 2 - n.height / 2, c; +function ks(t) { + var e = t.reference, n = t.element, r = t.placement, o = r ? Xt(r) : null, a = r ? Ge(r) : null, i = e.x + e.width / 2 - n.width / 2, l = e.y + e.height / 2 - n.height / 2, c; switch (o) { - case Ct: + case Tt: c = { x: i, y: e.y - n.height }; break; - case Vt: + case jt: c = { x: i, y: e.y + e.height }; break; - case zt: + case Vt: c = { x: e.x + e.width, y: l }; break; - case Ot: + case Ct: c = { x: e.x - n.width, y: l @@ -7317,73 +7225,73 @@ function Cs(t) { y: e.y }; } - var d = o ? Mo(o) : null; + var d = o ? Ao(o) : null; if (d != null) { var p = d === "y" ? "height" : "width"; switch (a) { case Le: c[d] = c[d] - (e[p] / 2 - n[p] / 2); break; - case Nn: + case xn: c[d] = c[d] + (e[p] / 2 - n[p] / 2); break; } } return c; } -function kn(t, e) { +function Nn(t, e) { e === void 0 && (e = {}); - var n = e, r = n.placement, o = r === void 0 ? t.placement : r, a = n.strategy, i = a === void 0 ? t.strategy : a, l = n.boundary, c = l === void 0 ? Hw : l, d = n.rootBoundary, p = d === void 0 ? vs : d, f = n.elementContext, w = f === void 0 ? rn : f, g = n.altBoundary, v = g === void 0 ? !1 : g, m = n.padding, h = m === void 0 ? 0 : m, S = Es(typeof h != "number" ? h : Ss(h, _n)), _ = w === rn ? Xw : rn, C = t.rects.popper, T = t.elements[v ? _ : w], b = Tf(ke(T) ? T : T.contextElement || le(t.elements.popper), c, p, i), I = Ue(t.elements.reference), z = Cs({ - reference: I, - element: C, + var n = e, r = n.placement, o = r === void 0 ? t.placement : r, a = n.strategy, i = a === void 0 ? t.strategy : a, l = n.boundary, c = l === void 0 ? Iw : l, d = n.rootBoundary, p = d === void 0 ? ms : d, f = n.elementContext, w = f === void 0 ? nn : f, g = n.altBoundary, v = g === void 0 ? !1 : g, m = n.padding, h = m === void 0 ? 0 : m, T = ys(typeof h != "number" ? h : xs(h, _n)), A = w === nn ? Aw : nn, R = t.rects.popper, E = t.elements[v ? A : w], b = ff(ke(E) ? E : E.contextElement || le(t.elements.popper), c, p, i), $ = Ue(t.elements.reference), z = ks({ + reference: $, + element: R, strategy: "absolute", placement: o - }), H = oo(Object.assign({}, C, z)), O = w === rn ? H : I, $ = { - top: b.top - O.top + S.top, - bottom: O.bottom - b.bottom + S.bottom, - left: b.left - O.left + S.left, - right: O.right - b.right + S.right + }), H = ro(Object.assign({}, R, z)), C = w === nn ? H : $, P = { + top: b.top - C.top + T.top, + bottom: C.bottom - b.bottom + T.bottom, + left: b.left - C.left + T.left, + right: C.right - b.right + T.right }, k = t.modifiersData.offset; - if (w === rn && k) { + if (w === nn && k) { var B = k[o]; - Object.keys($).forEach(function(D) { - var J = [zt, Vt].indexOf(D) >= 0 ? 1 : -1, q = [Ct, Vt].indexOf(D) >= 0 ? "y" : "x"; - $[D] += B[q] * J; + Object.keys(P).forEach(function(M) { + var J = [Vt, jt].indexOf(M) >= 0 ? 1 : -1, q = [Tt, jt].indexOf(M) >= 0 ? "y" : "x"; + P[M] += B[q] * J; }); } - return $; + return P; } -function Cf(t, e) { +function mf(t, e) { e === void 0 && (e = {}); - var n = e, r = n.placement, o = n.boundary, a = n.rootBoundary, i = n.padding, l = n.flipVariations, c = n.allowedAutoPlacements, d = c === void 0 ? ys : c, p = Ge(r), f = p ? l ? Ba : Ba.filter(function(v) { + var n = e, r = n.placement, o = n.boundary, a = n.rootBoundary, i = n.padding, l = n.flipVariations, c = n.allowedAutoPlacements, d = c === void 0 ? hs : c, p = Ge(r), f = p ? l ? Da : Da.filter(function(v) { return Ge(v) === p; }) : _n, w = f.filter(function(v) { return d.indexOf(v) >= 0; }); w.length === 0 && (w = f); var g = w.reduce(function(v, m) { - return v[m] = kn(t, { + return v[m] = Nn(t, { placement: m, boundary: o, rootBoundary: a, padding: i - })[Yt(m)], v; + })[Xt(m)], v; }, {}); return Object.keys(g).sort(function(v, m) { return g[v] - g[m]; }); } -function Of(t) { - if (Yt(t) === $o) +function hf(t) { + if (Xt(t) === Po) return []; var e = Xn(t); - return [za(t), e, za(e)]; + return [Va(t), e, Va(e)]; } -function Rf(t) { +function gf(t) { var e = t.state, n = t.options, r = t.name; if (!e.modifiersData[r]._skip) { - for (var o = n.mainAxis, a = o === void 0 ? !0 : o, i = n.altAxis, l = i === void 0 ? !0 : i, c = n.fallbackPlacements, d = n.padding, p = n.boundary, f = n.rootBoundary, w = n.altBoundary, g = n.flipVariations, v = g === void 0 ? !0 : g, m = n.allowedAutoPlacements, h = e.options.placement, S = Yt(h), _ = S === h, C = c || (_ || !v ? [Xn(h)] : Of(h)), T = [h].concat(C).reduce(function(V, W) { - return V.concat(Yt(W) === $o ? Cf(e, { + for (var o = n.mainAxis, a = o === void 0 ? !0 : o, i = n.altAxis, l = i === void 0 ? !0 : i, c = n.fallbackPlacements, d = n.padding, p = n.boundary, f = n.rootBoundary, w = n.altBoundary, g = n.flipVariations, v = g === void 0 ? !0 : g, m = n.allowedAutoPlacements, h = e.options.placement, T = Xt(h), A = T === h, R = c || (A || !v ? [Xn(h)] : hf(h)), E = [h].concat(R).reduce(function(V, W) { + return V.concat(Xt(W) === Po ? mf(e, { placement: W, boundary: p, rootBoundary: f, @@ -7391,27 +7299,27 @@ function Rf(t) { flipVariations: v, allowedAutoPlacements: m }) : W); - }, []), b = e.rects.reference, I = e.rects.popper, z = /* @__PURE__ */ new Map(), H = !0, O = T[0], $ = 0; $ < T.length; $++) { - var k = T[$], B = Yt(k), D = Ge(k) === Le, J = [Ct, Vt].indexOf(B) >= 0, q = J ? "width" : "height", U = kn(e, { + }, []), b = e.rects.reference, $ = e.rects.popper, z = /* @__PURE__ */ new Map(), H = !0, C = E[0], P = 0; P < E.length; P++) { + var k = E[P], B = Xt(k), M = Ge(k) === Le, J = [Tt, jt].indexOf(B) >= 0, q = J ? "width" : "height", U = Nn(e, { placement: k, boundary: p, rootBoundary: f, altBoundary: w, padding: d - }), tt = J ? D ? zt : Ot : D ? Vt : Ct; - b[q] > I[q] && (tt = Xn(tt)); + }), tt = J ? M ? Vt : Ct : M ? jt : Tt; + b[q] > $[q] && (tt = Xn(tt)); var at = Xn(tt), rt = []; if (a && rt.push(U[B] <= 0), l && rt.push(U[tt] <= 0, U[at] <= 0), rt.every(function(V) { return V; })) { - O = k, H = !1; + C = k, H = !1; break; } z.set(k, rt); } if (H) - for (var y = v ? 3 : 1, R = function(W) { - var X = T.find(function(Y) { + for (var y = v ? 3 : 1, O = function(W) { + var X = E.find(function(Y) { var G = z.get(Y); if (G) return G.slice(0, W).every(function(K) { @@ -7419,26 +7327,26 @@ function Rf(t) { }); }); if (X) - return O = X, "break"; + return C = X, "break"; }, L = y; L > 0; L--) { - var F = R(L); + var F = O(L); if (F === "break") break; } - e.placement !== O && (e.modifiersData[r]._skip = !0, e.placement = O, e.reset = !0); + e.placement !== C && (e.modifiersData[r]._skip = !0, e.placement = C, e.reset = !0); } } -const _f = { +const bf = { name: "flip", enabled: !0, phase: "main", - fn: Rf, + fn: gf, requiresIfExists: ["offset"], data: { _skip: !1 } }; -function Fa(t, e, n) { +function La(t, e, n) { return n === void 0 && (n = { x: 0, y: 0 @@ -7449,17 +7357,17 @@ function Fa(t, e, n) { left: t.left - e.width - n.x }; } -function Ua(t) { - return [Ct, zt, Vt, Ot].some(function(e) { +function Fa(t) { + return [Tt, Vt, jt, Ct].some(function(e) { return t[e] >= 0; }); } -function Pf(t) { - var e = t.state, n = t.name, r = e.rects.reference, o = e.rects.popper, a = e.modifiersData.preventOverflow, i = kn(e, { +function vf(t) { + var e = t.state, n = t.name, r = e.rects.reference, o = e.rects.popper, a = e.modifiersData.preventOverflow, i = Nn(e, { elementContext: "reference" - }), l = kn(e, { + }), l = Nn(e, { altBoundary: !0 - }), c = Fa(i, r), d = Fa(l, o, a), p = Ua(c), f = Ua(d); + }), c = La(i, r), d = La(l, o, a), p = Fa(c), f = Fa(d); e.modifiersData[n] = { referenceClippingOffsets: c, popperEscapeOffsets: d, @@ -7470,18 +7378,18 @@ function Pf(t) { "data-popper-escaped": f }); } -const $f = { +const yf = { name: "hide", enabled: !0, phase: "main", requiresIfExists: ["preventOverflow"], - fn: Pf + fn: vf }; -function If(t, e, n) { - var r = Yt(t), o = [Ot, Ct].indexOf(r) >= 0 ? -1 : 1, a = typeof n == "function" ? n(Object.assign({}, e, { +function xf(t, e, n) { + var r = Xt(t), o = [Ct, Tt].indexOf(r) >= 0 ? -1 : 1, a = typeof n == "function" ? n(Object.assign({}, e, { placement: t })) : n, i = a[0], l = a[1]; - return i = i || 0, l = (l || 0) * o, [Ot, zt].indexOf(r) >= 0 ? { + return i = i || 0, l = (l || 0) * o, [Ct, Vt].indexOf(r) >= 0 ? { x: l, y: i } : { @@ -7489,94 +7397,94 @@ function If(t, e, n) { y: l }; } -function Af(t) { - var e = t.state, n = t.options, r = t.name, o = n.offset, a = o === void 0 ? [0, 0] : o, i = ys.reduce(function(p, f) { - return p[f] = If(f, e.rects, a), p; +function Nf(t) { + var e = t.state, n = t.options, r = t.name, o = n.offset, a = o === void 0 ? [0, 0] : o, i = hs.reduce(function(p, f) { + return p[f] = xf(f, e.rects, a), p; }, {}), l = i[e.placement], c = l.x, d = l.y; e.modifiersData.popperOffsets != null && (e.modifiersData.popperOffsets.x += c, e.modifiersData.popperOffsets.y += d), e.modifiersData[r] = i; } -const Mf = { +const kf = { name: "offset", enabled: !0, phase: "main", requires: ["popperOffsets"], - fn: Af + fn: Nf }; -function Df(t) { +function Ef(t) { var e = t.state, n = t.name; - e.modifiersData[n] = Cs({ + e.modifiersData[n] = ks({ reference: e.rects.reference, element: e.rects.popper, strategy: "absolute", placement: e.placement }); } -const Bf = { +const Sf = { name: "popperOffsets", enabled: !0, phase: "read", - fn: Df, + fn: Ef, data: {} }; -function jf(t) { +function Tf(t) { return t === "x" ? "y" : "x"; } -function Vf(t) { - var e = t.state, n = t.options, r = t.name, o = n.mainAxis, a = o === void 0 ? !0 : o, i = n.altAxis, l = i === void 0 ? !1 : i, c = n.boundary, d = n.rootBoundary, p = n.altBoundary, f = n.padding, w = n.tether, g = w === void 0 ? !0 : w, v = n.tetherOffset, m = v === void 0 ? 0 : v, h = kn(e, { +function Cf(t) { + var e = t.state, n = t.options, r = t.name, o = n.mainAxis, a = o === void 0 ? !0 : o, i = n.altAxis, l = i === void 0 ? !1 : i, c = n.boundary, d = n.rootBoundary, p = n.altBoundary, f = n.padding, w = n.tether, g = w === void 0 ? !0 : w, v = n.tetherOffset, m = v === void 0 ? 0 : v, h = Nn(e, { boundary: c, rootBoundary: d, padding: f, altBoundary: p - }), S = Yt(e.placement), _ = Ge(e.placement), C = !_, T = Mo(S), b = jf(T), I = e.modifiersData.popperOffsets, z = e.rects.reference, H = e.rects.popper, O = typeof m == "function" ? m(Object.assign({}, e.rects, { + }), T = Xt(e.placement), A = Ge(e.placement), R = !A, E = Ao(T), b = Tf(E), $ = e.modifiersData.popperOffsets, z = e.rects.reference, H = e.rects.popper, C = typeof m == "function" ? m(Object.assign({}, e.rects, { placement: e.placement - })) : m, $ = typeof O == "number" ? { - mainAxis: O, - altAxis: O + })) : m, P = typeof C == "number" ? { + mainAxis: C, + altAxis: C } : Object.assign({ mainAxis: 0, altAxis: 0 - }, O), k = e.modifiersData.offset ? e.modifiersData.offset[e.placement] : null, B = { + }, C), k = e.modifiersData.offset ? e.modifiersData.offset[e.placement] : null, B = { x: 0, y: 0 }; - if (I) { + if ($) { if (a) { - var D, J = T === "y" ? Ct : Ot, q = T === "y" ? Vt : zt, U = T === "y" ? "height" : "width", tt = I[T], at = tt + h[J], rt = tt - h[q], y = g ? -H[U] / 2 : 0, R = _ === Le ? z[U] : H[U], L = _ === Le ? -H[U] : -z[U], F = e.elements.arrow, V = g && F ? Ao(F) : { + var M, J = E === "y" ? Tt : Ct, q = E === "y" ? jt : Vt, U = E === "y" ? "height" : "width", tt = $[E], at = tt + h[J], rt = tt - h[q], y = g ? -H[U] / 2 : 0, O = A === Le ? z[U] : H[U], L = A === Le ? -H[U] : -z[U], F = e.elements.arrow, V = g && F ? Io(F) : { width: 0, height: 0 - }, W = e.modifiersData["arrow#persistent"] ? e.modifiersData["arrow#persistent"].padding : ks(), X = W[J], Y = W[q], G = wn(0, z[U], V[U]), K = C ? z[U] / 2 - y - G - X - $.mainAxis : R - G - X - $.mainAxis, Z = C ? -z[U] / 2 + y + G + Y + $.mainAxis : L + G + Y + $.mainAxis, dt = e.elements.arrow && Pn(e.elements.arrow), A = dt ? T === "y" ? dt.clientTop || 0 : dt.clientLeft || 0 : 0, Nt = (D = k == null ? void 0 : k[T]) != null ? D : 0, j = tt + K - Nt - A, xt = tt + Z - Nt, Ft = wn(g ? Jn(at, j) : at, tt, g ? ve(rt, xt) : rt); - I[T] = Ft, B[T] = Ft - tt; + }, W = e.modifiersData["arrow#persistent"] ? e.modifiersData["arrow#persistent"].padding : vs(), X = W[J], Y = W[q], G = un(0, z[U], V[U]), K = R ? z[U] / 2 - y - G - X - P.mainAxis : O - G - X - P.mainAxis, Z = R ? -z[U] / 2 + y + G + Y + P.mainAxis : L + G + Y + P.mainAxis, dt = e.elements.arrow && Pn(e.elements.arrow), I = dt ? E === "y" ? dt.clientTop || 0 : dt.clientLeft || 0 : 0, xt = (M = k == null ? void 0 : k[E]) != null ? M : 0, j = tt + K - xt - I, yt = tt + Z - xt, Lt = un(g ? Jn(at, j) : at, tt, g ? ve(rt, yt) : rt); + $[E] = Lt, B[E] = Lt - tt; } if (l) { - var ce, St = T === "x" ? Ct : Ot, In = T === "x" ? Vt : zt, Ut = I[b], Ee = b === "y" ? "height" : "width", de = Ut + h[St], Se = Ut - h[In], Te = [Ct, Ot].indexOf(S) !== -1, Ce = (ce = k == null ? void 0 : k[b]) != null ? ce : 0, pe = Te ? de : Ut - z[Ee] - H[Ee] - Ce + $.altAxis, qe = Te ? Ut + z[Ee] + H[Ee] - Ce - $.altAxis : Se, An = g && Te ? cf(pe, Ut, qe) : wn(g ? pe : de, Ut, g ? qe : Se); - I[b] = An, B[b] = An - Ut; + var ce, Et = E === "x" ? Tt : Ct, In = E === "x" ? jt : Vt, Ft = $[b], Ee = b === "y" ? "height" : "width", de = Ft + h[Et], Se = Ft - h[In], Te = [Tt, Ct].indexOf(T) !== -1, Ce = (ce = k == null ? void 0 : k[b]) != null ? ce : 0, pe = Te ? de : Ft - z[Ee] - H[Ee] - Ce + P.altAxis, We = Te ? Ft + z[Ee] + H[Ee] - Ce - P.altAxis : Se, An = g && Te ? Kw(pe, Ft, We) : un(g ? pe : de, Ft, g ? We : Se); + $[b] = An, B[b] = An - Ft; } e.modifiersData[r] = B; } } -const zf = { +const Of = { name: "preventOverflow", enabled: !0, phase: "main", - fn: Vf, + fn: Cf, requiresIfExists: ["offset"] }; -function Lf(t) { +function Rf(t) { return { scrollLeft: t.scrollLeft, scrollTop: t.scrollTop }; } -function Ff(t) { - return t === Mt(t) || !jt(t) ? Do(t) : Lf(t); +function _f(t) { + return t === At(t) || !Bt(t) ? Mo(t) : Rf(t); } -function Uf(t) { +function Pf(t) { var e = t.getBoundingClientRect(), n = Fe(e.width) / t.offsetWidth || 1, r = Fe(e.height) / t.offsetHeight || 1; return n !== 1 || r !== 1; } -function Gf(t, e, n) { +function $f(t, e, n) { n === void 0 && (n = !1); - var r = jt(e), o = jt(e) && Uf(e), a = le(e), i = Ue(t, o, n), l = { + var r = Bt(e), o = Bt(e) && Pf(e), a = le(e), i = Ue(t, o, n), l = { scrollLeft: 0, scrollTop: 0 }, c = { @@ -7584,14 +7492,14 @@ function Gf(t, e, n) { y: 0 }; return (r || !r && !n) && ((qt(e) !== "body" || // https://github.com/popperjs/popper-core/issues/1078 - jo(a)) && (l = Ff(e)), jt(e) ? (c = Ue(e, !0), c.x += e.clientLeft, c.y += e.clientTop) : a && (c.x = Bo(a))), { + Bo(a)) && (l = _f(e)), Bt(e) ? (c = Ue(e, !0), c.x += e.clientLeft, c.y += e.clientTop) : a && (c.x = Do(a))), { x: i.left + l.scrollLeft - c.x, y: i.top + l.scrollTop - c.y, width: i.width, height: i.height }; } -function Hf(t) { +function If(t) { var e = /* @__PURE__ */ new Map(), n = /* @__PURE__ */ new Set(), r = []; t.forEach(function(a) { e.set(a.name, a); @@ -7610,15 +7518,15 @@ function Hf(t) { n.has(a.name) || o(a); }), r; } -function Xf(t) { - var e = Hf(t); - return nf.reduce(function(n, r) { +function Af(t) { + var e = If(t); + return Gw.reduce(function(n, r) { return n.concat(e.filter(function(o) { return o.phase === r; })); }, []); } -function Yf(t) { +function Mf(t) { var e; return function() { return e || (e = new Promise(function(n) { @@ -7628,7 +7536,7 @@ function Yf(t) { })), e; }; } -function Wf(t) { +function Df(t) { var e = t.reduce(function(n, r) { var o = n[r.name]; return n[r.name] = o ? Object.assign({}, o, r, { @@ -7640,27 +7548,27 @@ function Wf(t) { return e[n]; }); } -var Ga = { +var Ua = { placement: "bottom", modifiers: [], strategy: "absolute" }; -function Ha() { +function Ga() { for (var t = arguments.length, e = new Array(t), n = 0; n < t; n++) e[n] = arguments[n]; return !e.some(function(r) { return !(r && typeof r.getBoundingClientRect == "function"); }); } -function qf(t) { +function Bf(t) { t === void 0 && (t = {}); - var e = t, n = e.defaultModifiers, r = n === void 0 ? [] : n, o = e.defaultOptions, a = o === void 0 ? Ga : o; + var e = t, n = e.defaultModifiers, r = n === void 0 ? [] : n, o = e.defaultOptions, a = o === void 0 ? Ua : o; return function(l, c, d) { d === void 0 && (d = a); var p = { placement: "bottom", orderedModifiers: [], - options: Object.assign({}, Ga, a), + options: Object.assign({}, Ua, a), modifiersData: {}, elements: { reference: l, @@ -7670,15 +7578,15 @@ function qf(t) { styles: {} }, f = [], w = !1, g = { state: p, - setOptions: function(S) { - var _ = typeof S == "function" ? S(p.options) : S; - m(), p.options = Object.assign({}, a, p.options, _), p.scrollParents = { - reference: ke(l) ? fn(l) : l.contextElement ? fn(l.contextElement) : [], - popper: fn(c) + setOptions: function(T) { + var A = typeof T == "function" ? T(p.options) : T; + m(), p.options = Object.assign({}, a, p.options, A), p.scrollParents = { + reference: ke(l) ? wn(l) : l.contextElement ? wn(l.contextElement) : [], + popper: wn(c) }; - var C = Xf(Wf([].concat(r, p.options.modifiers))); - return p.orderedModifiers = C.filter(function(T) { - return T.enabled; + var R = Af(Df([].concat(r, p.options.modifiers))); + return p.orderedModifiers = R.filter(function(E) { + return E.enabled; }), v(), g.update(); }, // Sync update – it will always be executed, even if not necessary. This @@ -7688,24 +7596,24 @@ function qf(t) { // prefer the async Popper#update method forceUpdate: function() { if (!w) { - var S = p.elements, _ = S.reference, C = S.popper; - if (Ha(_, C)) { + var T = p.elements, A = T.reference, R = T.popper; + if (Ga(A, R)) { p.rects = { - reference: Gf(_, Pn(C), p.options.strategy === "fixed"), - popper: Ao(C) - }, p.reset = !1, p.placement = p.options.placement, p.orderedModifiers.forEach(function($) { - return p.modifiersData[$.name] = Object.assign({}, $.data); + reference: $f(A, Pn(R), p.options.strategy === "fixed"), + popper: Io(R) + }, p.reset = !1, p.placement = p.options.placement, p.orderedModifiers.forEach(function(P) { + return p.modifiersData[P.name] = Object.assign({}, P.data); }); - for (var T = 0; T < p.orderedModifiers.length; T++) { + for (var E = 0; E < p.orderedModifiers.length; E++) { if (p.reset === !0) { - p.reset = !1, T = -1; + p.reset = !1, E = -1; continue; } - var b = p.orderedModifiers[T], I = b.fn, z = b.options, H = z === void 0 ? {} : z, O = b.name; - typeof I == "function" && (p = I({ + var b = p.orderedModifiers[E], $ = b.fn, z = b.options, H = z === void 0 ? {} : z, C = b.name; + typeof $ == "function" && (p = $({ state: p, options: H, - name: O, + name: C, instance: g }) || p); } @@ -7714,7 +7622,7 @@ function qf(t) { }, // Async and optimistically optimized update – it will not be executed if // not necessary (debounced to run at most once-per-tick) - update: Yf(function() { + update: Mf(function() { return new Promise(function(h) { g.forceUpdate(), h(p); }); @@ -7723,23 +7631,23 @@ function qf(t) { m(), w = !0; } }; - if (!Ha(l, c)) + if (!Ga(l, c)) return g; g.setOptions(d).then(function(h) { !w && d.onFirstUpdate && d.onFirstUpdate(h); }); function v() { p.orderedModifiers.forEach(function(h) { - var S = h.name, _ = h.options, C = _ === void 0 ? {} : _, T = h.effect; - if (typeof T == "function") { - var b = T({ + var T = h.name, A = h.options, R = A === void 0 ? {} : A, E = h.effect; + if (typeof E == "function") { + var b = E({ state: p, - name: S, + name: T, instance: g, - options: C - }), I = function() { + options: R + }), $ = function() { }; - f.push(b || I); + f.push(b || $); } }); } @@ -7751,16 +7659,16 @@ function qf(t) { return g; }; } -var Kf = [vf, Bf, gf, af, Mf, _f, zf, wf, $f], Jf = /* @__PURE__ */ qf({ - defaultModifiers: Kf +var jf = [sf, Sf, of, Yw, kf, bf, Of, tf, yf], Vf = /* @__PURE__ */ Bf({ + defaultModifiers: jf }); -const Os = "Popper"; -function Zf(t) { - return bs(Os, t); +const Es = "Popper"; +function zf(t) { + return fs(Es, t); } -Uw(Os, ["root"]); -const Qf = ["anchorEl", "children", "direction", "disablePortal", "modifiers", "open", "placement", "popperOptions", "popperRef", "slotProps", "slots", "TransitionProps", "ownerState"], tm = ["anchorEl", "children", "container", "direction", "disablePortal", "keepMounted", "modifiers", "open", "placement", "popperOptions", "popperRef", "style", "transition", "slotProps", "slots"]; -function em(t, e) { +Pw(Es, ["root"]); +const Lf = ["anchorEl", "children", "direction", "disablePortal", "modifiers", "open", "placement", "popperOptions", "popperRef", "slotProps", "slots", "TransitionProps", "ownerState"], Ff = ["anchorEl", "children", "container", "direction", "disablePortal", "keepMounted", "modifiers", "open", "placement", "popperOptions", "popperRef", "style", "transition", "slotProps", "slots"]; +function Uf(t, e) { if (e === "ltr") return t; switch (t) { @@ -7782,12 +7690,12 @@ function Zn(t) { function Nr(t) { return t.nodeType !== void 0; } -function nm(t) { +function Gf(t) { return !Nr(t); } -const rm = () => xo({ +const Hf = () => yo({ root: ["root"] -}, Mw(Zf)), om = {}, am = /* @__PURE__ */ M.forwardRef(function(e, n) { +}, kw(zf)), Xf = {}, Yf = /* @__PURE__ */ D.forwardRef(function(e, n) { var r; const { anchorEl: o, @@ -7804,23 +7712,23 @@ const rm = () => xo({ TransitionProps: m // @ts-ignore internal logic // prevent from spreading to DOM, it can come from the parent component e.g. Select. - } = e, h = kt(e, Qf), S = M.useRef(null), _ = xe(S, n), C = M.useRef(null), T = xe(C, w), b = M.useRef(T); + } = e, h = Nt(e, Lf), T = D.useRef(null), A = xe(T, n), R = D.useRef(null), E = xe(R, w), b = D.useRef(E); ze(() => { - b.current = T; - }, [T]), M.useImperativeHandle(w, () => C.current, []); - const I = em(p, i), [z, H] = M.useState(I), [O, $] = M.useState(Zn(o)); - M.useEffect(() => { - C.current && C.current.forceUpdate(); - }), M.useEffect(() => { - o && $(Zn(o)); + b.current = E; + }, [E]), D.useImperativeHandle(w, () => R.current, []); + const $ = Uf(p, i), [z, H] = D.useState($), [C, P] = D.useState(Zn(o)); + D.useEffect(() => { + R.current && R.current.forceUpdate(); + }), D.useEffect(() => { + o && P(Zn(o)); }, [o]), ze(() => { - if (!O || !d) + if (!C || !d) return; const q = (at) => { H(at.placement); }; - if (process.env.NODE_ENV !== "production" && O && Nr(O) && O.nodeType === 1) { - const at = O.getBoundingClientRect(); + if (process.env.NODE_ENV !== "production" && C && Nr(C) && C.nodeType === 1) { + const at = C.getBoundingClientRect(); process.env.NODE_ENV !== "test" && at.top === 0 && at.left === 0 && at.right === 0 && at.bottom === 0 && console.warn(["MUI: The `anchorEl` prop provided to the component is invalid.", "The anchor element should be part of the document layout.", "Make sure the element is present in the document or that it's not display none."].join(` `)); } @@ -7845,34 +7753,34 @@ const rm = () => xo({ } }]; c != null && (U = U.concat(c)), f && f.modifiers != null && (U = U.concat(f.modifiers)); - const tt = Jf(O, S.current, P({ - placement: I + const tt = Vf(C, T.current, _({ + placement: $ }, f, { modifiers: U })); return b.current(tt), () => { tt.destroy(), b.current(null); }; - }, [O, l, c, d, f, I]); + }, [C, l, c, d, f, $]); const k = { placement: z }; m !== null && (k.TransitionProps = m); - const B = rm(), D = (r = v.root) != null ? r : "div", J = zw({ - elementType: D, + const B = Hf(), M = (r = v.root) != null ? r : "div", J = Ow({ + elementType: M, externalSlotProps: g.root, externalForwardedProps: h, additionalProps: { role: "tooltip", - ref: _ + ref: A }, ownerState: e, className: B.root }); - return /* @__PURE__ */ s(D, P({}, J, { + return /* @__PURE__ */ s(M, _({}, J, { children: typeof a == "function" ? a(k) : a })); -}), Rs = /* @__PURE__ */ M.forwardRef(function(e, n) { +}), Ss = /* @__PURE__ */ D.forwardRef(function(e, n) { const { anchorEl: r, children: o, @@ -7883,48 +7791,48 @@ const rm = () => xo({ modifiers: d, open: p, placement: f = "bottom", - popperOptions: w = om, + popperOptions: w = Xf, popperRef: g, style: v, transition: m = !1, slotProps: h = {}, - slots: S = {} - } = e, _ = kt(e, tm), [C, T] = M.useState(!0), b = () => { - T(!1); - }, I = () => { - T(!0); + slots: T = {} + } = e, A = Nt(e, Ff), [R, E] = D.useState(!0), b = () => { + E(!1); + }, $ = () => { + E(!0); }; - if (!c && !p && (!m || C)) + if (!c && !p && (!m || R)) return null; let z; if (a) z = a; else if (r) { - const $ = Zn(r); - z = $ && Nr($) ? Yn($).body : Yn(null).body; + const P = Zn(r); + z = P && Nr(P) ? Yn(P).body : Yn(null).body; } - const H = !p && c && (!m || C) ? "none" : void 0, O = m ? { + const H = !p && c && (!m || R) ? "none" : void 0, C = m ? { in: p, onEnter: b, - onExited: I + onExited: $ } : void 0; return /* @__PURE__ */ s(Kn, { disablePortal: l, container: z, - children: /* @__PURE__ */ s(am, P({ + children: /* @__PURE__ */ s(Yf, _({ anchorEl: r, direction: i, disablePortal: l, modifiers: d, ref: n, - open: m ? !C : p, + open: m ? !R : p, placement: f, popperOptions: w, popperRef: g, slotProps: h, - slots: S - }, _, { - style: P({ + slots: T + }, A, { + style: _({ // Prevents scroll issue, waiting for Popper.js to add this style once initiated. position: "fixed", // Fix Popper.js display issue @@ -7932,12 +7840,12 @@ const rm = () => xo({ left: 0, display: H }, v), - TransitionProps: O, + TransitionProps: C, children: o })) }); }); -process.env.NODE_ENV !== "production" && (Rs.propTypes = { +process.env.NODE_ENV !== "production" && (Ss.propTypes = { // ┌────────────────────────────── Warning ──────────────────────────────┐ // │ These PropTypes are generated from the TypeScript type definitions. │ // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │ @@ -7948,7 +7856,7 @@ process.env.NODE_ENV !== "production" && (Rs.propTypes = { * It's used to set the position of the popper. * The return value will passed as the reference object of the Popper instance. */ - anchorEl: vo(u.oneOfType([yn, u.object, u.func]), (t) => { + anchorEl: bo(u.oneOfType([vn, u.object, u.func]), (t) => { if (t.open) { const e = Zn(t.anchorEl); if (e && Nr(e) && e.nodeType === 1) { @@ -7956,7 +7864,7 @@ process.env.NODE_ENV !== "production" && (Rs.propTypes = { if (process.env.NODE_ENV !== "test" && n.top === 0 && n.left === 0 && n.right === 0 && n.bottom === 0) return new Error(["MUI: The `anchorEl` prop provided to the component is invalid.", "The anchor element should be part of the document layout.", "Make sure the element is present in the document or that it's not display none."].join(` `)); - } else if (!e || typeof e.getBoundingClientRect != "function" || nm(e) && e.contextElement != null && e.contextElement.nodeType !== 1) + } else if (!e || typeof e.getBoundingClientRect != "function" || Gf(e) && e.contextElement != null && e.contextElement.nodeType !== 1) return new Error(["MUI: The `anchorEl` prop provided to the component is invalid.", "It should be an HTML element instance or a virtualElement ", "(https://popper.js.org/docs/v2/virtual-elements/)."].join(` `)); } @@ -7976,7 +7884,7 @@ process.env.NODE_ENV !== "production" && (Rs.propTypes = { * By default, it uses the body of the top-level document object, * so it's simply `document.body` most of the time. */ - container: u.oneOfType([yn, u.func]), + container: u.oneOfType([vn, u.func]), /** * Direction of the text. * @default 'ltr' @@ -8036,7 +7944,7 @@ process.env.NODE_ENV !== "production" && (Rs.propTypes = { /** * A ref that points to the used popper instance. */ - popperRef: es, + popperRef: Ji, /** * The props used for each slot inside the Popper. * @default {} @@ -8058,22 +7966,22 @@ process.env.NODE_ENV !== "production" && (Rs.propTypes = { */ transition: u.bool }); -function _s() { - const t = ws(Oo); - return process.env.NODE_ENV !== "production" && M.useDebugValue(t), t[Ro] || t; +function Ts() { + const t = cs(Co); + return process.env.NODE_ENV !== "production" && D.useDebugValue(t), t[Oo] || t; } -function ao(t, e) { - return ao = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function(r, o) { +function oo(t, e) { + return oo = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function(r, o) { return r.__proto__ = o, r; - }, ao(t, e); + }, oo(t, e); } -function im(t, e) { - t.prototype = Object.create(e.prototype), t.prototype.constructor = t, ao(t, e); +function Wf(t, e) { + t.prototype = Object.create(e.prototype), t.prototype.constructor = t, oo(t, e); } -const Xa = { +const Ha = { disabled: !1 }; -var sm = process.env.NODE_ENV !== "production" ? u.oneOfType([u.number, u.shape({ +var qf = process.env.NODE_ENV !== "production" ? u.oneOfType([u.number, u.shape({ enter: u.number, exit: u.number, appear: u.number @@ -8090,22 +7998,22 @@ process.env.NODE_ENV !== "production" && u.oneOfType([u.string, u.shape({ exitDone: u.string, exitActive: u.string })]); -const Ps = E.createContext(null); -var lm = function(e) { +const Cs = S.createContext(null); +var Kf = function(e) { return e.scrollTop; -}, cn = "unmounted", fe = "exited", me = "entering", Ae = "entered", io = "exiting", ee = /* @__PURE__ */ function(t) { - im(e, t); +}, ln = "unmounted", fe = "exited", me = "entering", Ae = "entered", ao = "exiting", ee = /* @__PURE__ */ function(t) { + Wf(e, t); function e(r, o) { var a; a = t.call(this, r, o) || this; var i = o, l = i && !i.isMounting ? r.enter : r.appear, c; - return a.appearStatus = null, r.in ? l ? (c = fe, a.appearStatus = me) : c = Ae : r.unmountOnExit || r.mountOnEnter ? c = cn : c = fe, a.state = { + return a.appearStatus = null, r.in ? l ? (c = fe, a.appearStatus = me) : c = Ae : r.unmountOnExit || r.mountOnEnter ? c = ln : c = fe, a.state = { status: c }, a.nextCallback = null, a; } e.getDerivedStateFromProps = function(o, a) { var i = o.in; - return i && a.status === cn ? { + return i && a.status === ln ? { status: fe } : null; }; @@ -8116,7 +8024,7 @@ var lm = function(e) { var a = null; if (o !== this.props) { var i = this.state.status; - this.props.in ? i !== me && i !== Ae && (a = me) : (i === me || i === Ae) && (a = io); + this.props.in ? i !== me && i !== Ae && (a = me) : (i === me || i === Ae) && (a = ao); } this.updateStatus(!1, a); }, n.componentWillUnmount = function() { @@ -8133,18 +8041,18 @@ var lm = function(e) { if (this.cancelNextCallback(), a === me) { if (this.props.unmountOnExit || this.props.mountOnEnter) { var i = this.props.nodeRef ? this.props.nodeRef.current : Bn.findDOMNode(this); - i && lm(i); + i && Kf(i); } this.performEnter(o); } else this.performExit(); else this.props.unmountOnExit && this.state.status === fe && this.setState({ - status: cn + status: ln }); }, n.performEnter = function(o) { var a = this, i = this.props.enter, l = this.context ? this.context.isMounting : o, c = this.props.nodeRef ? [l] : [Bn.findDOMNode(this), l], d = c[0], p = c[1], f = this.getTimeouts(), w = l ? f.appear : f.enter; - if (!o && !i || Xa.disabled) { + if (!o && !i || Ha.disabled) { this.safeSetState({ status: Ae }, function() { @@ -8165,7 +8073,7 @@ var lm = function(e) { }); }, n.performExit = function() { var o = this, a = this.props.exit, i = this.getTimeouts(), l = this.props.nodeRef ? void 0 : Bn.findDOMNode(this); - if (!a || Xa.disabled) { + if (!a || Ha.disabled) { this.safeSetState({ status: fe }, function() { @@ -8174,7 +8082,7 @@ var lm = function(e) { return; } this.props.onExit(l), this.safeSetState({ - status: io + status: ao }, function() { o.props.onExiting(l), o.onTransitionEnd(i.exit, function() { o.safeSetState({ @@ -8209,20 +8117,20 @@ var lm = function(e) { o != null && setTimeout(this.nextCallback, o); }, n.render = function() { var o = this.state.status; - if (o === cn) + if (o === ln) return null; var a = this.props, i = a.children; a.in, a.mountOnEnter, a.unmountOnExit, a.appear, a.enter, a.exit, a.timeout, a.addEndListener, a.onEnter, a.onEntering, a.onEntered, a.onExit, a.onExiting, a.onExited, a.nodeRef; - var l = kt(a, ["children", "in", "mountOnEnter", "unmountOnExit", "appear", "enter", "exit", "timeout", "addEndListener", "onEnter", "onEntering", "onEntered", "onExit", "onExiting", "onExited", "nodeRef"]); + var l = Nt(a, ["children", "in", "mountOnEnter", "unmountOnExit", "appear", "enter", "exit", "timeout", "addEndListener", "onEnter", "onEntering", "onEntered", "onExit", "onExiting", "onExited", "nodeRef"]); return ( // allows for nested Transitions - /* @__PURE__ */ E.createElement(Ps.Provider, { + /* @__PURE__ */ S.createElement(Cs.Provider, { value: null - }, typeof i == "function" ? i(o, l) : E.cloneElement(E.Children.only(i), l)) + }, typeof i == "function" ? i(o, l) : S.cloneElement(S.Children.only(i), l)) ); }, e; -}(E.Component); -ee.contextType = Ps; +}(S.Component); +ee.contextType = Cs; ee.propTypes = process.env.NODE_ENV !== "production" ? { /** * A React reference to DOM element that need to transition: @@ -8319,7 +8227,7 @@ ee.propTypes = process.env.NODE_ENV !== "production" ? { * @type {number | { enter?: number, exit?: number, appear?: number }} */ timeout: function(e) { - var n = sm; + var n = qf; e.addEndListener || (n = n.isRequired); for (var r = arguments.length, o = new Array(r > 1 ? r - 1 : 0), a = 1; a < r; a++) o[a - 1] = arguments[a]; @@ -8408,13 +8316,13 @@ ee.defaultProps = { onExiting: Ie, onExited: Ie }; -ee.UNMOUNTED = cn; +ee.UNMOUNTED = ln; ee.EXITED = fe; ee.ENTERING = me; ee.ENTERED = Ae; -ee.EXITING = io; -const cm = ee, dm = (t) => t.scrollTop; -function Ya(t, e) { +ee.EXITING = ao; +const Jf = ee, Zf = (t) => t.scrollTop; +function Xa(t, e) { var n, r; const { timeout: o, @@ -8427,20 +8335,20 @@ function Ya(t, e) { delay: i.transitionDelay }; } -const pm = ["addEndListener", "appear", "children", "easing", "in", "onEnter", "onEntered", "onEntering", "onExit", "onExited", "onExiting", "style", "timeout", "TransitionComponent"]; -function so(t) { +const Qf = ["addEndListener", "appear", "children", "easing", "in", "onEnter", "onEntered", "onEntering", "onExit", "onExited", "onExiting", "style", "timeout", "TransitionComponent"]; +function io(t) { return `scale(${t}, ${t ** 2})`; } -const um = { +const tm = { entering: { opacity: 1, - transform: so(1) + transform: io(1) }, entered: { opacity: 1, transform: "none" } -}, Ur = typeof navigator < "u" && /^((?!chrome|android).)*(safari|mobile)/i.test(navigator.userAgent) && /(os |version\/)15(.|_)4/i.test(navigator.userAgent), Vo = /* @__PURE__ */ M.forwardRef(function(e, n) { +}, Fr = typeof navigator < "u" && /^((?!chrome|android).)*(safari|mobile)/i.test(navigator.userAgent) && /(os |version\/)15(.|_)4/i.test(navigator.userAgent), jo = /* @__PURE__ */ D.forwardRef(function(e, n) { const { addEndListener: r, appear: o = !0, @@ -8456,19 +8364,19 @@ const um = { style: v, timeout: m = "auto", // eslint-disable-next-line react/prop-types - TransitionComponent: h = cm - } = e, S = kt(e, pm), _ = sn(), C = M.useRef(), T = _s(), b = M.useRef(null), I = xe(b, a.ref, n), z = (q) => (U) => { + TransitionComponent: h = Jf + } = e, T = Nt(e, Qf), A = an(), R = D.useRef(), E = Ts(), b = D.useRef(null), $ = xe(b, a.ref, n), z = (q) => (U) => { if (q) { const tt = b.current; U === void 0 ? q(tt) : q(tt, U); } - }, H = z(p), O = z((q, U) => { - dm(q); + }, H = z(p), C = z((q, U) => { + Zf(q); const { duration: tt, delay: at, easing: rt - } = Ya({ + } = Xa({ style: v, timeout: m, easing: i @@ -8476,20 +8384,20 @@ const um = { mode: "enter" }); let y; - m === "auto" ? (y = T.transitions.getAutoHeightDuration(q.clientHeight), C.current = y) : y = tt, q.style.transition = [T.transitions.create("opacity", { + m === "auto" ? (y = E.transitions.getAutoHeightDuration(q.clientHeight), R.current = y) : y = tt, q.style.transition = [E.transitions.create("opacity", { duration: y, delay: at - }), T.transitions.create("transform", { - duration: Ur ? y : y * 0.666, + }), E.transitions.create("transform", { + duration: Fr ? y : y * 0.666, delay: at, easing: rt })].join(","), c && c(q, U); - }), $ = z(d), k = z(g), B = z((q) => { + }), P = z(d), k = z(g), B = z((q) => { const { duration: U, delay: tt, easing: at - } = Ya({ + } = Xa({ style: v, timeout: m, easing: i @@ -8497,41 +8405,41 @@ const um = { mode: "exit" }); let rt; - m === "auto" ? (rt = T.transitions.getAutoHeightDuration(q.clientHeight), C.current = rt) : rt = U, q.style.transition = [T.transitions.create("opacity", { + m === "auto" ? (rt = E.transitions.getAutoHeightDuration(q.clientHeight), R.current = rt) : rt = U, q.style.transition = [E.transitions.create("opacity", { duration: rt, delay: tt - }), T.transitions.create("transform", { - duration: Ur ? rt : rt * 0.666, - delay: Ur ? tt : tt || rt * 0.333, + }), E.transitions.create("transform", { + duration: Fr ? rt : rt * 0.666, + delay: Fr ? tt : tt || rt * 0.333, easing: at - })].join(","), q.style.opacity = 0, q.style.transform = so(0.75), f && f(q); - }), D = z(w); - return /* @__PURE__ */ s(h, P({ + })].join(","), q.style.opacity = 0, q.style.transform = io(0.75), f && f(q); + }), M = z(w); + return /* @__PURE__ */ s(h, _({ appear: o, in: l, nodeRef: b, - onEnter: O, - onEntered: $, + onEnter: C, + onEntered: P, onEntering: H, onExit: B, - onExited: D, + onExited: M, onExiting: k, addEndListener: (q) => { - m === "auto" && _.start(C.current || 0, q), r && r(b.current, q); + m === "auto" && A.start(R.current || 0, q), r && r(b.current, q); }, timeout: m === "auto" ? null : m - }, S, { - children: (q, U) => /* @__PURE__ */ M.cloneElement(a, P({ - style: P({ + }, T, { + children: (q, U) => /* @__PURE__ */ D.cloneElement(a, _({ + style: _({ opacity: 0, - transform: so(0.75), + transform: io(0.75), visibility: q === "exited" && !l ? "hidden" : void 0 - }, um[q], v, a.props.style), - ref: I + }, tm[q], v, a.props.style), + ref: $ }, U)) })); }); -process.env.NODE_ENV !== "production" && (Vo.propTypes = { +process.env.NODE_ENV !== "production" && (jo.propTypes = { // ┌────────────────────────────── Warning ──────────────────────────────┐ // │ These PropTypes are generated from the TypeScript type definitions. │ // │ To update them, edit the d.ts file and run `pnpm proptypes`. │ @@ -8551,7 +8459,7 @@ process.env.NODE_ENV !== "production" && (Vo.propTypes = { /** * A single child content element. */ - children: Qi.isRequired, + children: qi.isRequired, /** * The transition timing function. * You may specify a single easing or a object containing enter and exit values. @@ -8605,14 +8513,14 @@ process.env.NODE_ENV !== "production" && (Vo.propTypes = { exit: u.number })]) }); -Vo.muiSupportAuto = !0; -const Wa = Vo, wm = ["anchorEl", "component", "components", "componentsProps", "container", "disablePortal", "keepMounted", "modifiers", "open", "placement", "popperOptions", "popperRef", "transition", "slots", "slotProps"], fm = Rn(Rs, { +jo.muiSupportAuto = !0; +const Ya = jo, em = ["anchorEl", "component", "components", "componentsProps", "container", "disablePortal", "keepMounted", "modifiers", "open", "placement", "popperOptions", "popperRef", "transition", "slots", "slotProps"], nm = Rn(Ss, { name: "MuiPopper", slot: "Root", overridesResolver: (t, e) => e.root -})({}), $s = /* @__PURE__ */ M.forwardRef(function(e, n) { +})({}), Os = /* @__PURE__ */ D.forwardRef(function(e, n) { var r; - const o = us(), a = _o({ + const o = ls(), a = Ro({ props: e, name: "MuiPopper" }), { @@ -8627,11 +8535,11 @@ const Wa = Vo, wm = ["anchorEl", "component", "components", "componentsProps", " open: v, placement: m, popperOptions: h, - popperRef: S, - transition: _, - slots: C, - slotProps: T - } = a, b = kt(a, wm), I = (r = C == null ? void 0 : C.root) != null ? r : c == null ? void 0 : c.Root, z = P({ + popperRef: T, + transition: A, + slots: R, + slotProps: E + } = a, b = Nt(a, em), $ = (r = R == null ? void 0 : R.root) != null ? r : c == null ? void 0 : c.Root, z = _({ anchorEl: i, container: p, disablePortal: f, @@ -8640,21 +8548,21 @@ const Wa = Vo, wm = ["anchorEl", "component", "components", "componentsProps", " open: v, placement: m, popperOptions: h, - popperRef: S, - transition: _ + popperRef: T, + transition: A }, b); - return /* @__PURE__ */ s(fm, P({ + return /* @__PURE__ */ s(nm, _({ as: l, direction: o == null ? void 0 : o.direction, slots: { - root: I + root: $ }, - slotProps: T ?? d + slotProps: E ?? d }, z, { ref: n })); }); -process.env.NODE_ENV !== "production" && ($s.propTypes = { +process.env.NODE_ENV !== "production" && (Os.propTypes = { // ┌────────────────────────────── Warning ──────────────────────────────┐ // │ These PropTypes are generated from the TypeScript type definitions. │ // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │ @@ -8665,7 +8573,7 @@ process.env.NODE_ENV !== "production" && ($s.propTypes = { * It's used to set the position of the popper. * The return value will passed as the reference object of the Popper instance. */ - anchorEl: u.oneOfType([yn, u.object, u.func]), + anchorEl: u.oneOfType([vn, u.object, u.func]), /** * Popper render function or node. */ @@ -8700,7 +8608,7 @@ process.env.NODE_ENV !== "production" && ($s.propTypes = { * By default, it uses the body of the top-level document object, * so it's simply `document.body` most of the time. */ - container: u.oneOfType([yn, u.func]), + container: u.oneOfType([vn, u.func]), /** * The `children` will be under the DOM hierarchy of the parent component. * @default false @@ -8755,7 +8663,7 @@ process.env.NODE_ENV !== "production" && ($s.propTypes = { /** * A ref that points to the used popper instance. */ - popperRef: es, + popperRef: Ji, /** * The props used for each slot inside the Popper. * @default {} @@ -8781,15 +8689,15 @@ process.env.NODE_ENV !== "production" && ($s.propTypes = { */ transition: u.bool }); -const Is = $s; -function mm(t) { +const Rs = Os; +function rm(t) { return pr("MuiTooltip", t); } -const hm = ls("MuiTooltip", ["popper", "popperInteractive", "popperArrow", "popperClose", "tooltip", "tooltipArrow", "touch", "tooltipPlacementLeft", "tooltipPlacementRight", "tooltipPlacementTop", "tooltipPlacementBottom", "arrow"]), re = hm, gm = ["arrow", "children", "classes", "components", "componentsProps", "describeChild", "disableFocusListener", "disableHoverListener", "disableInteractive", "disableTouchListener", "enterDelay", "enterNextDelay", "enterTouchDelay", "followCursor", "id", "leaveDelay", "leaveTouchDelay", "onClose", "onOpen", "open", "placement", "PopperComponent", "PopperProps", "slotProps", "slots", "title", "TransitionComponent", "TransitionProps"]; -function bm(t) { +const om = os("MuiTooltip", ["popper", "popperInteractive", "popperArrow", "popperClose", "tooltip", "tooltipArrow", "touch", "tooltipPlacementLeft", "tooltipPlacementRight", "tooltipPlacementTop", "tooltipPlacementBottom", "arrow"]), re = om, am = ["arrow", "children", "classes", "components", "componentsProps", "describeChild", "disableFocusListener", "disableHoverListener", "disableInteractive", "disableTouchListener", "enterDelay", "enterNextDelay", "enterTouchDelay", "followCursor", "id", "leaveDelay", "leaveTouchDelay", "onClose", "onOpen", "open", "placement", "PopperComponent", "PopperProps", "slotProps", "slots", "title", "TransitionComponent", "TransitionProps"]; +function im(t) { return Math.round(t * 1e5) / 1e5; } -const vm = (t) => { +const sm = (t) => { const { classes: e, disableInteractive: n, @@ -8801,8 +8709,8 @@ const vm = (t) => { tooltip: ["tooltip", r && "tooltipArrow", o && "touch", `tooltipPlacement${Wt(a.split("-")[0])}`], arrow: ["arrow"] }; - return xo(i, mm, e); -}, ym = Rn(Is, { + return yo(i, rm, e); +}, lm = Rn(Rs, { name: "MuiTooltip", slot: "Popper", overridesResolver: (t, e) => { @@ -8815,7 +8723,7 @@ const vm = (t) => { theme: t, ownerState: e, open: n -}) => P({ +}) => _({ zIndex: (t.vars || t).zIndex.tooltip, pointerEvents: "none" }, !e.disableInteractive && { @@ -8837,7 +8745,7 @@ const vm = (t) => { transformOrigin: "100% 0" } }, - [`&[data-popper-placement*="right"] .${re.arrow}`]: P({}, e.isRtl ? { + [`&[data-popper-placement*="right"] .${re.arrow}`]: _({}, e.isRtl ? { right: 0, marginRight: "-0.71em" } : { @@ -8850,7 +8758,7 @@ const vm = (t) => { transformOrigin: "100% 100%" } }), - [`&[data-popper-placement*="left"] .${re.arrow}`]: P({}, e.isRtl ? { + [`&[data-popper-placement*="left"] .${re.arrow}`]: _({}, e.isRtl ? { left: 0, marginLeft: "-0.71em" } : { @@ -8863,7 +8771,7 @@ const vm = (t) => { transformOrigin: "0 0" } }) -})), xm = Rn("div", { +})), cm = Rn("div", { name: "MuiTooltip", slot: "Tooltip", overridesResolver: (t, e) => { @@ -8875,8 +8783,8 @@ const vm = (t) => { })(({ theme: t, ownerState: e -}) => P({ - backgroundColor: t.vars ? t.vars.palette.Tooltip.bg : fs(t.palette.grey[700], 0.92), +}) => _({ + backgroundColor: t.vars ? t.vars.palette.Tooltip.bg : ds(t.palette.grey[700], 0.92), borderRadius: (t.vars || t).shape.borderRadius, color: (t.vars || t).palette.common.white, fontFamily: t.typography.fontFamily, @@ -8892,44 +8800,44 @@ const vm = (t) => { }, e.touch && { padding: "8px 16px", fontSize: t.typography.pxToRem(14), - lineHeight: `${bm(16 / 14)}em`, + lineHeight: `${im(16 / 14)}em`, fontWeight: t.typography.fontWeightRegular }, { - [`.${re.popper}[data-popper-placement*="left"] &`]: P({ + [`.${re.popper}[data-popper-placement*="left"] &`]: _({ transformOrigin: "right center" - }, e.isRtl ? P({ + }, e.isRtl ? _({ marginLeft: "14px" }, e.touch && { marginLeft: "24px" - }) : P({ + }) : _({ marginRight: "14px" }, e.touch && { marginRight: "24px" })), - [`.${re.popper}[data-popper-placement*="right"] &`]: P({ + [`.${re.popper}[data-popper-placement*="right"] &`]: _({ transformOrigin: "left center" - }, e.isRtl ? P({ + }, e.isRtl ? _({ marginRight: "14px" }, e.touch && { marginRight: "24px" - }) : P({ + }) : _({ marginLeft: "14px" }, e.touch && { marginLeft: "24px" })), - [`.${re.popper}[data-popper-placement*="top"] &`]: P({ + [`.${re.popper}[data-popper-placement*="top"] &`]: _({ transformOrigin: "center bottom", marginBottom: "14px" }, e.touch && { marginBottom: "24px" }), - [`.${re.popper}[data-popper-placement*="bottom"] &`]: P({ + [`.${re.popper}[data-popper-placement*="bottom"] &`]: _({ transformOrigin: "center top", marginTop: "14px" }, e.touch && { marginTop: "24px" }) -})), Nm = Rn("span", { +})), dm = Rn("span", { name: "MuiTooltip", slot: "Arrow", overridesResolver: (t, e) => e.arrow @@ -8941,7 +8849,7 @@ const vm = (t) => { width: "1em", height: "0.71em", boxSizing: "border-box", - color: t.vars ? t.vars.palette.Tooltip.bg : fs(t.palette.grey[700], 0.9), + color: t.vars ? t.vars.palette.Tooltip.bg : ds(t.palette.grey[700], 0.9), "&::before": { content: '""', margin: "auto", @@ -8953,8 +8861,8 @@ const vm = (t) => { } })); let Ln = !1; -const qa = new Tn(); -let on = { +const Wa = new Tn(); +let rn = { x: 0, y: 0 }; @@ -8963,19 +8871,19 @@ function Fn(t, e) { e && e(n), t(n); }; } -const As = /* @__PURE__ */ M.forwardRef(function(e, n) { - var r, o, a, i, l, c, d, p, f, w, g, v, m, h, S, _, C, T, b; - const I = _o({ +const _s = /* @__PURE__ */ D.forwardRef(function(e, n) { + var r, o, a, i, l, c, d, p, f, w, g, v, m, h, T, A, R, E, b; + const $ = Ro({ props: e, name: "MuiTooltip" }), { arrow: z = !1, children: H, - components: O = {}, - componentsProps: $ = {}, + components: C = {}, + componentsProps: P = {}, describeChild: k = !1, disableFocusListener: B = !1, - disableHoverListener: D = !1, + disableHoverListener: M = !1, disableInteractive: J = !1, disableTouchListener: q = !1, enterDelay: U = 100, @@ -8983,7 +8891,7 @@ const As = /* @__PURE__ */ M.forwardRef(function(e, n) { enterTouchDelay: at = 700, followCursor: rt = !1, id: y, - leaveDelay: R = 0, + leaveDelay: O = 0, leaveTouchDelay: L = 1500, onClose: F, onOpen: V, @@ -8994,11 +8902,11 @@ const As = /* @__PURE__ */ M.forwardRef(function(e, n) { slotProps: K = {}, slots: Z = {}, title: dt, - TransitionComponent: A = Wa, - TransitionProps: Nt - } = I, j = kt(I, gm), xt = /* @__PURE__ */ M.isValidElement(H) ? H : /* @__PURE__ */ s("span", { + TransitionComponent: I = Ya, + TransitionProps: xt + } = $, j = Nt($, am), yt = /* @__PURE__ */ D.isValidElement(H) ? H : /* @__PURE__ */ s("span", { children: H - }), Ft = _s(), ce = Ft.direction === "rtl", [St, In] = M.useState(), [Ut, Ee] = M.useState(null), de = M.useRef(!1), Se = J || rt, Te = sn(), Ce = sn(), pe = sn(), qe = sn(), [An, zo] = rs({ + }), Lt = Ts(), ce = Lt.direction === "rtl", [Et, In] = D.useState(), [Ft, Ee] = D.useState(null), de = D.useRef(!1), Se = J || rt, Te = an(), Ce = an(), pe = an(), We = an(), [An, Vo] = Qi({ controlled: W, default: !1, name: "Tooltip", @@ -9008,147 +8916,147 @@ const As = /* @__PURE__ */ M.forwardRef(function(e, n) { if (process.env.NODE_ENV !== "production") { const { current: Q - } = M.useRef(W !== void 0); - M.useEffect(() => { - St && St.disabled && !Q && dt !== "" && St.tagName.toLowerCase() === "button" && console.error(["MUI: You are providing a disabled `button` child to the Tooltip component.", "A disabled element does not fire events.", "Tooltip needs to listen to the child element's events to display the title.", "", "Add a simple wrapper element, such as a `span`."].join(` + } = D.useRef(W !== void 0); + D.useEffect(() => { + Et && Et.disabled && !Q && dt !== "" && Et.tagName.toLowerCase() === "button" && console.error(["MUI: You are providing a disabled `button` child to the Tooltip component.", "A disabled element does not fire events.", "Tooltip needs to listen to the child element's events to display the title.", "", "Add a simple wrapper element, such as a `span`."].join(` `)); - }, [dt, St, Q]); + }, [dt, Et, Q]); } - const kr = ns(y), Ke = M.useRef(), Mn = eo(() => { - Ke.current !== void 0 && (document.body.style.WebkitUserSelect = Ke.current, Ke.current = void 0), qe.clear(); + const kr = Zi(y), qe = D.useRef(), Mn = to(() => { + qe.current !== void 0 && (document.body.style.WebkitUserSelect = qe.current, qe.current = void 0), We.clear(); }); - M.useEffect(() => Mn, [Mn]); - const Lo = (Q) => { - qa.clear(), Ln = !0, zo(!0), V && !Kt && V(Q); - }, Dn = eo( + D.useEffect(() => Mn, [Mn]); + const zo = (Q) => { + Wa.clear(), Ln = !0, Vo(!0), V && !Kt && V(Q); + }, Dn = to( /** * @param {React.SyntheticEvent | Event} event */ (Q) => { - qa.start(800 + R, () => { + Wa.start(800 + O, () => { Ln = !1; - }), zo(!1), F && Kt && F(Q), Te.start(Ft.transitions.duration.shortest, () => { + }), Vo(!1), F && Kt && F(Q), Te.start(Lt.transitions.duration.shortest, () => { de.current = !1; }); } ), Er = (Q) => { - de.current && Q.type !== "touchstart" || (St && St.removeAttribute("title"), Ce.clear(), pe.clear(), U || Ln && tt ? Ce.start(Ln ? tt : U, () => { - Lo(Q); - }) : Lo(Q)); - }, Fo = (Q) => { - Ce.clear(), pe.start(R, () => { + de.current && Q.type !== "touchstart" || (Et && Et.removeAttribute("title"), Ce.clear(), pe.clear(), U || Ln && tt ? Ce.start(Ln ? tt : U, () => { + zo(Q); + }) : zo(Q)); + }, Lo = (Q) => { + Ce.clear(), pe.start(O, () => { Dn(Q); }); }, { - isFocusVisibleRef: Uo, - onBlur: js, - onFocus: Vs, - ref: zs - } = os(), [, Go] = M.useState(!1), Ho = (Q) => { - js(Q), Uo.current === !1 && (Go(!1), Fo(Q)); + isFocusVisibleRef: Fo, + onBlur: As, + onFocus: Ms, + ref: Ds + } = ts(), [, Uo] = D.useState(!1), Go = (Q) => { + As(Q), Fo.current === !1 && (Uo(!1), Lo(Q)); + }, Ho = (Q) => { + Et || In(Q.currentTarget), Ms(Q), Fo.current === !0 && (Uo(!0), Er(Q)); }, Xo = (Q) => { - St || In(Q.currentTarget), Vs(Q), Uo.current === !0 && (Go(!0), Er(Q)); - }, Yo = (Q) => { de.current = !0; - const Pt = xt.props; - Pt.onTouchStart && Pt.onTouchStart(Q); - }, Wo = Er, qo = Fo, Ls = (Q) => { - Yo(Q), pe.clear(), Te.clear(), Mn(), Ke.current = document.body.style.WebkitUserSelect, document.body.style.WebkitUserSelect = "none", qe.start(at, () => { - document.body.style.WebkitUserSelect = Ke.current, Er(Q); + const _t = yt.props; + _t.onTouchStart && _t.onTouchStart(Q); + }, Yo = Er, Wo = Lo, Bs = (Q) => { + Xo(Q), pe.clear(), Te.clear(), Mn(), qe.current = document.body.style.WebkitUserSelect, document.body.style.WebkitUserSelect = "none", We.start(at, () => { + document.body.style.WebkitUserSelect = qe.current, Er(Q); }); - }, Fs = (Q) => { - xt.props.onTouchEnd && xt.props.onTouchEnd(Q), Mn(), pe.start(L, () => { + }, js = (Q) => { + yt.props.onTouchEnd && yt.props.onTouchEnd(Q), Mn(), pe.start(L, () => { Dn(Q); }); }; - M.useEffect(() => { + D.useEffect(() => { if (!Kt) return; - function Q(Pt) { - (Pt.key === "Escape" || Pt.key === "Esc") && Dn(Pt); + function Q(_t) { + (_t.key === "Escape" || _t.key === "Esc") && Dn(_t); } return document.addEventListener("keydown", Q), () => { document.removeEventListener("keydown", Q); }; }, [Dn, Kt]); - const Us = xe(xt.ref, zs, In, n); + const Vs = xe(yt.ref, Ds, In, n); !dt && dt !== 0 && (Kt = !1); - const Sr = M.useRef(), Gs = (Q) => { - const Pt = xt.props; - Pt.onMouseMove && Pt.onMouseMove(Q), on = { + const Sr = D.useRef(), zs = (Q) => { + const _t = yt.props; + _t.onMouseMove && _t.onMouseMove(Q), rn = { x: Q.clientX, y: Q.clientY }, Sr.current && Sr.current.update(); - }, Je = {}, Tr = typeof dt == "string"; - k ? (Je.title = !Kt && Tr && !D ? dt : null, Je["aria-describedby"] = Kt ? kr : null) : (Je["aria-label"] = Tr ? dt : null, Je["aria-labelledby"] = Kt && !Tr ? kr : null); - const Dt = P({}, Je, j, xt.props, { - className: be(j.className, xt.props.className), - onTouchStart: Yo, - ref: Us + }, Ke = {}, Tr = typeof dt == "string"; + k ? (Ke.title = !Kt && Tr && !M ? dt : null, Ke["aria-describedby"] = Kt ? kr : null) : (Ke["aria-label"] = Tr ? dt : null, Ke["aria-labelledby"] = Kt && !Tr ? kr : null); + const Mt = _({}, Ke, j, yt.props, { + className: be(j.className, yt.props.className), + onTouchStart: Xo, + ref: Vs }, rt ? { - onMouseMove: Gs + onMouseMove: zs } : {}); - process.env.NODE_ENV !== "production" && (Dt["data-mui-internal-clone-element"] = !0, M.useEffect(() => { - St && !St.getAttribute("data-mui-internal-clone-element") && console.error(["MUI: The `children` component of the Tooltip is not forwarding its props correctly.", "Please make sure that props are spread on the same element that the ref is applied to."].join(` + process.env.NODE_ENV !== "production" && (Mt["data-mui-internal-clone-element"] = !0, D.useEffect(() => { + Et && !Et.getAttribute("data-mui-internal-clone-element") && console.error(["MUI: The `children` component of the Tooltip is not forwarding its props correctly.", "Please make sure that props are spread on the same element that the ref is applied to."].join(` `)); - }, [St])); - const Ze = {}; - q || (Dt.onTouchStart = Ls, Dt.onTouchEnd = Fs), D || (Dt.onMouseOver = Fn(Wo, Dt.onMouseOver), Dt.onMouseLeave = Fn(qo, Dt.onMouseLeave), Se || (Ze.onMouseOver = Wo, Ze.onMouseLeave = qo)), B || (Dt.onFocus = Fn(Xo, Dt.onFocus), Dt.onBlur = Fn(Ho, Dt.onBlur), Se || (Ze.onFocus = Xo, Ze.onBlur = Ho)), process.env.NODE_ENV !== "production" && xt.props.title && console.error(["MUI: You have provided a `title` prop to the child of .", `Remove this title prop \`${xt.props.title}\` or the Tooltip component.`].join(` + }, [Et])); + const Je = {}; + q || (Mt.onTouchStart = Bs, Mt.onTouchEnd = js), M || (Mt.onMouseOver = Fn(Yo, Mt.onMouseOver), Mt.onMouseLeave = Fn(Wo, Mt.onMouseLeave), Se || (Je.onMouseOver = Yo, Je.onMouseLeave = Wo)), B || (Mt.onFocus = Fn(Ho, Mt.onFocus), Mt.onBlur = Fn(Go, Mt.onBlur), Se || (Je.onFocus = Ho, Je.onBlur = Go)), process.env.NODE_ENV !== "production" && yt.props.title && console.error(["MUI: You have provided a `title` prop to the child of .", `Remove this title prop \`${yt.props.title}\` or the Tooltip component.`].join(` `)); - const Hs = M.useMemo(() => { + const Ls = D.useMemo(() => { var Q; - let Pt = [{ + let _t = [{ name: "arrow", - enabled: !!Ut, + enabled: !!Ft, options: { - element: Ut, + element: Ft, padding: 4 } }]; - return (Q = G.popperOptions) != null && Q.modifiers && (Pt = Pt.concat(G.popperOptions.modifiers)), P({}, G.popperOptions, { - modifiers: Pt + return (Q = G.popperOptions) != null && Q.modifiers && (_t = _t.concat(G.popperOptions.modifiers)), _({}, G.popperOptions, { + modifiers: _t }); - }, [Ut, G]), Qe = P({}, I, { + }, [Ft, G]), Ze = _({}, $, { isRtl: ce, arrow: z, disableInteractive: Se, placement: X, PopperComponentProp: Y, touch: de.current - }), Cr = vm(Qe), Ko = (r = (o = Z.popper) != null ? o : O.Popper) != null ? r : ym, Jo = (a = (i = (l = Z.transition) != null ? l : O.Transition) != null ? i : A) != null ? a : Wa, Zo = (c = (d = Z.tooltip) != null ? d : O.Tooltip) != null ? c : xm, Qo = (p = (f = Z.arrow) != null ? f : O.Arrow) != null ? p : Nm, Xs = ln(Ko, P({}, G, (w = K.popper) != null ? w : $.popper, { - className: be(Cr.popper, G == null ? void 0 : G.className, (g = (v = K.popper) != null ? v : $.popper) == null ? void 0 : g.className) - }), Qe), Ys = ln(Jo, P({}, Nt, (m = K.transition) != null ? m : $.transition), Qe), Ws = ln(Zo, P({}, (h = K.tooltip) != null ? h : $.tooltip, { - className: be(Cr.tooltip, (S = (_ = K.tooltip) != null ? _ : $.tooltip) == null ? void 0 : S.className) - }), Qe), qs = ln(Qo, P({}, (C = K.arrow) != null ? C : $.arrow, { - className: be(Cr.arrow, (T = (b = K.arrow) != null ? b : $.arrow) == null ? void 0 : T.className) - }), Qe); - return /* @__PURE__ */ N(M.Fragment, { - children: [/* @__PURE__ */ M.cloneElement(xt, Dt), /* @__PURE__ */ s(Ko, P({ - as: Y ?? Is, + }), Cr = sm(Ze), qo = (r = (o = Z.popper) != null ? o : C.Popper) != null ? r : lm, Ko = (a = (i = (l = Z.transition) != null ? l : C.Transition) != null ? i : I) != null ? a : Ya, Jo = (c = (d = Z.tooltip) != null ? d : C.Tooltip) != null ? c : cm, Zo = (p = (f = Z.arrow) != null ? f : C.Arrow) != null ? p : dm, Fs = sn(qo, _({}, G, (w = K.popper) != null ? w : P.popper, { + className: be(Cr.popper, G == null ? void 0 : G.className, (g = (v = K.popper) != null ? v : P.popper) == null ? void 0 : g.className) + }), Ze), Us = sn(Ko, _({}, xt, (m = K.transition) != null ? m : P.transition), Ze), Gs = sn(Jo, _({}, (h = K.tooltip) != null ? h : P.tooltip, { + className: be(Cr.tooltip, (T = (A = K.tooltip) != null ? A : P.tooltip) == null ? void 0 : T.className) + }), Ze), Hs = sn(Zo, _({}, (R = K.arrow) != null ? R : P.arrow, { + className: be(Cr.arrow, (E = (b = K.arrow) != null ? b : P.arrow) == null ? void 0 : E.className) + }), Ze); + return /* @__PURE__ */ x(D.Fragment, { + children: [/* @__PURE__ */ D.cloneElement(yt, Mt), /* @__PURE__ */ s(qo, _({ + as: Y ?? Rs, placement: X, anchorEl: rt ? { getBoundingClientRect: () => ({ - top: on.y, - left: on.x, - right: on.x, - bottom: on.y, + top: rn.y, + left: rn.x, + right: rn.x, + bottom: rn.y, width: 0, height: 0 }) - } : St, + } : Et, popperRef: Sr, - open: St ? Kt : !1, + open: Et ? Kt : !1, id: kr, transition: !0 - }, Ze, Xs, { - popperOptions: Hs, + }, Je, Fs, { + popperOptions: Ls, children: ({ TransitionProps: Q - }) => /* @__PURE__ */ s(Jo, P({ - timeout: Ft.transitions.duration.shorter - }, Q, Ys, { - children: /* @__PURE__ */ N(Zo, P({}, Ws, { - children: [dt, z ? /* @__PURE__ */ s(Qo, P({}, qs, { + }) => /* @__PURE__ */ s(Ko, _({ + timeout: Lt.transitions.duration.shorter + }, Q, Us, { + children: /* @__PURE__ */ x(Jo, _({}, Gs, { + children: [dt, z ? /* @__PURE__ */ s(Zo, _({}, Hs, { ref: Ee })) : null] })) @@ -9156,7 +9064,7 @@ const As = /* @__PURE__ */ M.forwardRef(function(e, n) { }))] }); }); -process.env.NODE_ENV !== "production" && (As.propTypes = { +process.env.NODE_ENV !== "production" && (_s.propTypes = { // ┌────────────────────────────── Warning ──────────────────────────────┐ // │ These PropTypes are generated from the TypeScript type definitions. │ // │ To update them, edit the d.ts file and run `pnpm proptypes`. │ @@ -9169,7 +9077,7 @@ process.env.NODE_ENV !== "production" && (As.propTypes = { /** * Tooltip reference element. */ - children: Qi.isRequired, + children: qi.isRequired, /** * Override or extend the styles applied to the component. */ @@ -9349,11 +9257,11 @@ process.env.NODE_ENV !== "production" && (As.propTypes = { */ TransitionProps: u.object }); -const km = As; -function Ka(t, e, n) { - return t ? /* @__PURE__ */ s(ii, { className: `papi-menu-icon-${n ? "leading" : "trailing"}`, children: /* @__PURE__ */ s("img", { src: t, alt: `${n ? "Leading" : "Trailing"} icon for ${e}` }) }) : void 0; +const pm = _s; +function qa(t, e, n) { + return t ? /* @__PURE__ */ s(oi, { className: `papi-menu-icon-${n ? "leading" : "trailing"}`, children: /* @__PURE__ */ s("img", { src: t, alt: `${n ? "Leading" : "Trailing"} icon for ${e}` }) }) : void 0; } -function Ms(t) { +function Ps(t) { const { onClick: e, label: n, @@ -9371,8 +9279,8 @@ function Ms(t) { focusVisibleClassName: v, id: m, children: h - } = t, S = /* @__PURE__ */ s( - Bl, + } = t, T = /* @__PURE__ */ s( + Al, { sx: { lineHeight: 0.8 }, autoFocus: l, @@ -9384,35 +9292,35 @@ function Ms(t) { focusVisibleClassName: v, onClick: e, id: m, - children: n ? /* @__PURE__ */ N(ie, { children: [ - Ka(a, n, !0), - /* @__PURE__ */ s(jl, { primary: n, inset: !a && o }), - f ? /* @__PURE__ */ s(ii, { className: "papi-menu-icon-trailing", children: /* @__PURE__ */ s(hs, {}) }) : Ka(i, n, !1) + children: n ? /* @__PURE__ */ x(ie, { children: [ + qa(a, n, !0), + /* @__PURE__ */ s(Ml, { primary: n, inset: !a && o }), + f ? /* @__PURE__ */ s(oi, { className: "papi-menu-icon-trailing", children: /* @__PURE__ */ s(us, {}) }) : qa(i, n, !1) ] }) : h } ); - return r ? /* @__PURE__ */ s(km, { title: r, placement: "right", children: /* @__PURE__ */ s("div", { children: S }) }) : S; + return r ? /* @__PURE__ */ s(pm, { title: r, placement: "right", children: /* @__PURE__ */ s("div", { children: T }) }) : T; } -function Ds(t) { +function $s(t) { return Object.entries(t.groups).map(([n, r]) => ({ id: n, group: r })); } -function Em(t) { +function um(t) { const [e, n] = ut(void 0), { parentMenuItem: r, parentItemProps: o, menuDefinition: a } = t, i = (d) => { n(d.currentTarget); }, l = () => { n(void 0); }, c = () => { - let d = Ds(a).filter((p) => "menuItem" in p.group); + let d = $s(a).filter((p) => "menuItem" in p.group); if (!(r != null && r.id)) throw new Error("A valid parent menu item is required for submenus."); return d = d.filter( (p) => "menuItem" in p.group && p.group.menuItem === r.id - ), /* @__PURE__ */ s(Bs, { ...t, includedGroups: d }); + ), /* @__PURE__ */ s(Is, { ...t, includedGroups: d }); }; - return /* @__PURE__ */ N(ie, { children: [ - /* @__PURE__ */ s(Ms, { onClick: i, ...o, isSubMenuParent: !0 }), + return /* @__PURE__ */ x(ie, { children: [ + /* @__PURE__ */ s(Ps, { onClick: i, ...o, isSubMenuParent: !0 }), /* @__PURE__ */ s( - Vl, + Dl, { anchorEl: e, open: !!e, @@ -9431,18 +9339,18 @@ function Em(t) { ) ] }); } -const Sm = (t, e) => e.filter((o) => o.group === t).sort((o, a) => (o.order || 0) - (a.order || 0)); -function Bs(t) { - const { menuDefinition: e, onClick: n, commandHandler: r, includedGroups: o } = t, { items: a, allowForLeadingIcons: i } = It(() => { +const wm = (t, e) => e.filter((o) => o.group === t).sort((o, a) => (o.order || 0) - (a.order || 0)); +function Is(t) { + const { menuDefinition: e, onClick: n, commandHandler: r, includedGroups: o } = t, { items: a, allowForLeadingIcons: i } = $t(() => { const p = o && o.length > 0 ? o : ( // We're apparently laying out a single-column menu (presumably a context menu). In this // case, all groups should be included except ones that belong to a submenu. - Ds(e).filter((v) => !("menuItem" in v.group)) + $s(e).filter((v) => !("menuItem" in v.group)) ), f = Object.values(p).sort( (v, m) => (v.group.order || 0) - (m.group.order || 0) ), w = []; f.forEach((v) => { - Sm(v.id, e.items).forEach( + wm(v.id, e.items).forEach( (m) => w.push({ item: m, isLastItemInGroup: !1 }) ), w.length > 0 && (w[w.length - 1].isLastItemInGroup = !0); }), w.length > 0 && (w[w.length - 1].isLastItemInGroup = !1); @@ -9468,7 +9376,7 @@ function Bs(t) { if ("command" in w) { const v = w.group + f; return /* @__PURE__ */ s( - Ms, + Ps, { onClick: (m) => { n == null || n(m), r(w); @@ -9479,7 +9387,7 @@ function Bs(t) { ); } return /* @__PURE__ */ s( - Em, + um, { parentMenuItem: w, parentItemProps: g, @@ -9489,16 +9397,16 @@ function Bs(t) { ); }) }, d); } -function Tm(t) { +function fm(t) { const { menuDefinition: e, columnId: n } = t; let a = Object.entries(e.groups).map(([i, l]) => ({ id: i, group: l })).filter((i) => "column" in i.group); return n && "columns" in e && // Without this type assertion, TS doesn't know what columns is. // eslint-disable-next-line no-type-assertion/no-type-assertion e.columns[n] && (a = a.filter( (i) => "column" in i.group && i.group.column === n - )), /* @__PURE__ */ s(Bs, { ...t, includedGroups: a }); + )), /* @__PURE__ */ s(Is, { ...t, includedGroups: a }); } -function Cm({ +function mm({ commandHandler: t, menuDefinition: e, id: n, @@ -9506,8 +9414,8 @@ function Cm({ onClick: o, className: a }) { - return /* @__PURE__ */ N( - si, + return /* @__PURE__ */ x( + ai, { id: n, item: !0, @@ -9517,8 +9425,8 @@ function Cm({ className: `papi-menu-column ${a ?? ""}`, children: [ /* @__PURE__ */ s("h3", { "aria-label": r.label, className: `papi-menu-column-header ${a ?? ""}`, children: r.label }), - /* @__PURE__ */ s(zl, { id: n, dense: !0, className: a ?? "", children: /* @__PURE__ */ s( - Tm, + /* @__PURE__ */ s(Bl, { id: n, dense: !0, className: a ?? "", children: /* @__PURE__ */ s( + fm, { commandHandler: t, menuDefinition: e, @@ -9530,13 +9438,13 @@ function Cm({ } ); } -function Om({ +function hm({ commandHandler: t, className: e, multiColumnMenu: n, id: r }) { - const { columns: o } = n, a = It(() => { + const { columns: o } = n, a = $t(() => { const i = /* @__PURE__ */ new Map(); return Object.getOwnPropertyNames(o).forEach((l) => { if (l === "isExtensible") @@ -9548,7 +9456,7 @@ function Om({ }), Array.from(i.values()).sort((l, c) => (l.metadata.order || 0) - (c.metadata.order || 0)); }, [o, r]); return /* @__PURE__ */ s( - si, + ai, { container: !0, spacing: 0, @@ -9558,7 +9466,7 @@ function Om({ "aria-label": "GridMenu", id: r, children: a.map((i, l) => /* @__PURE__ */ s( - Cm, + mm, { commandHandler: t, menuDefinition: n, @@ -9570,17 +9478,17 @@ function Om({ } ); } -function Rm(t) { +function gm(t) { return { preserveValue: !0, ...t }; } -const lo = (t, e, n = {}) => { +const so = (t, e, n = {}) => { const r = ge(e); r.current = e; const o = ge(n); - o.current = Rm(o.current); + o.current = gm(o.current); const [a, i] = ut(() => r.current), [l, c] = ut(!0); return ae(() => { let d = !0; @@ -9593,10 +9501,10 @@ const lo = (t, e, n = {}) => { d = !1, o.current.preserveValue || i(() => r.current); }; }, [t]), [a, l]; -}, _m = ms(/* @__PURE__ */ s("path", { +}, bm = ps(/* @__PURE__ */ s("path", { d: "M3 18h18v-2H3zm0-5h18v-2H3zm0-7v2h18V6z" }), "Menu"); -function Pm({ +function vm({ menuProvider: t, normalMenu: e, fullMenu: n, @@ -9606,36 +9514,36 @@ function Pm({ ariaLabelPrefix: i, children: l }) { - const [c, d] = ut(!1), [p, f] = ut(!1), w = Et(() => { + const [c, d] = ut(!1), [p, f] = ut(!1), w = kt(() => { c && d(!1), f(!1); - }, [c]), g = Et((T) => { - T.stopPropagation(), d((b) => { - const I = !b; - return I && T.shiftKey ? f(!0) : I || f(!1), I; + }, [c]), g = kt((E) => { + E.stopPropagation(), d((b) => { + const $ = !b; + return $ && E.shiftKey ? f(!0) : $ || f(!1), $; }); - }, []), v = Et( - (T) => (w(), r(T)), + }, []), v = kt( + (E) => (w(), r(E)), [r, w] ), [m, h] = ut({ top: 1, left: 1 }); ae(() => { if (c) { - const T = o == null ? void 0 : o.current; - if (T) { - const b = T.getBoundingClientRect(), I = window.scrollY, z = window.scrollX, H = b.top + I + T.clientHeight, O = b.left + z; - h({ top: H, left: O }); + const E = o == null ? void 0 : o.current; + if (E) { + const b = E.getBoundingClientRect(), $ = window.scrollY, z = window.scrollX, H = b.top + $ + E.clientHeight, C = b.left + z; + h({ top: H, left: C }); } } }, [c, o]); - const [S] = lo( - Et(async () => (t == null ? void 0 : t(!1)) ?? e, [t, e, c]), + const [T] = so( + kt(async () => (t == null ? void 0 : t(!1)) ?? e, [t, e, c]), e - ), [_] = lo( - Et(async () => (t == null ? void 0 : t(!0)) ?? n ?? S, [t, n, S, c]), - n ?? S - ), C = p && _ ? _ : S; - return /* @__PURE__ */ N(ie, { children: [ + ), [A] = so( + kt(async () => (t == null ? void 0 : t(!0)) ?? n ?? T, [t, n, T, c]), + n ?? T + ), R = p && A ? A : T; + return /* @__PURE__ */ x(ie, { children: [ /* @__PURE__ */ s( - li, + ii, { sx: { paddingTop: 0, @@ -9646,11 +9554,11 @@ function Pm({ color: "inherit", "aria-label": `${i ?? ""} menu button`, onClick: g, - children: l ?? /* @__PURE__ */ s(_m, {}) + children: l ?? /* @__PURE__ */ s(bm, {}) } ), /* @__PURE__ */ s( - Ll, + jl, { className: `papi-menu-drawer ${a ?? ""}`, anchor: "left", @@ -9664,20 +9572,20 @@ function Pm({ left: m.left } }, - children: C ? /* @__PURE__ */ s( - Om, + children: R ? /* @__PURE__ */ s( + hm, { className: a, id: `${i ?? ""} main menu`, commandHandler: v, - multiColumnMenu: C + multiColumnMenu: R } ) : void 0 } ) ] }); } -function Ih({ +function xh({ id: t, label: e, isDisabled: n = !1, @@ -9690,7 +9598,7 @@ function Ih({ children: d }) { return /* @__PURE__ */ s( - li, + ii, { id: t, disabled: n, @@ -9704,9 +9612,9 @@ function Ih({ } ); } -const $n = Qn(({ className: t, ...e }, n) => /* @__PURE__ */ s(gl, { size: 35, className: x("tw-animate-spin", t), ...e, ref: n })); +const $n = Qn(({ className: t, ...e }, n) => /* @__PURE__ */ s(fl, { size: 35, className: N("tw-animate-spin", t), ...e, ref: n })); $n.displayName = "Spinner"; -function Ah({ +function Nh({ id: t, isDisabled: e = !1, hasError: n = !1, @@ -9722,12 +9630,12 @@ function Ah({ onFocus: w, onBlur: g }) { - return /* @__PURE__ */ N("div", { className: x("tw-inline-grid tw-items-center tw-gap-1.5", { "tw-w-full": r }), children: [ + return /* @__PURE__ */ x("div", { className: N("tw-inline-grid tw-items-center tw-gap-1.5", { "tw-w-full": r }), children: [ /* @__PURE__ */ s( - Xt, + Ht, { htmlFor: t, - className: x({ + className: N({ "tw-text-red-600": n, "tw-hidden": !a }), @@ -9735,13 +9643,13 @@ function Ah({ } ), /* @__PURE__ */ s( - Ye, + Xe, { id: t, disabled: e, placeholder: i, required: l, - className: x(c, { "tw-border-red-600": n }), + className: N(c, { "tw-border-red-600": n }), defaultValue: d, value: p, onChange: f, @@ -9749,10 +9657,10 @@ function Ah({ onBlur: g } ), - /* @__PURE__ */ s("p", { className: x({ "tw-hidden": !o }), children: o }) + /* @__PURE__ */ s("p", { className: N({ "tw-hidden": !o }), children: o }) ] }); } -function Mh({ +function kh({ menuProvider: t, commandHandler: e, className: n, @@ -9760,14 +9668,14 @@ function Mh({ children: o }) { const a = ge(void 0); - return /* @__PURE__ */ s("div", { ref: a, style: { position: "relative" }, children: /* @__PURE__ */ s(Fl, { position: "static", id: r, children: /* @__PURE__ */ N( - Ul, + return /* @__PURE__ */ s("div", { ref: a, style: { position: "relative" }, children: /* @__PURE__ */ s(Vl, { position: "static", id: r, children: /* @__PURE__ */ x( + zl, { - className: x("tw-bg-muted tw-text-muted-foreground", n), + className: N("tw-bg-muted tw-text-muted-foreground", n), variant: "dense", children: [ t ? /* @__PURE__ */ s( - Pm, + vm, { commandHandler: e, containerRef: a, @@ -9779,7 +9687,7 @@ function Mh({ } ) }) }); } -const $m = Xe( +const ym = kn( "tw-relative tw-w-full tw-rounded-lg tw-border tw-p-4 [&>svg~*]:tw-pl-7 [&>svg+div]:tw-translate-y-[-3px] [&>svg]:tw-absolute [&>svg]:tw-left-4 [&>svg]:tw-top-4 [&>svg]:tw-text-foreground", { variants: { @@ -9792,14 +9700,14 @@ const $m = Xe( variant: "default" } } -), Im = E.forwardRef(({ className: t, variant: e, ...n }, r) => /* @__PURE__ */ s("div", { ref: r, role: "alert", className: x($m({ variant: e }), t), ...n })); -Im.displayName = "Alert"; -const Am = E.forwardRef( - ({ className: t, ...e }, n) => /* @__PURE__ */ N( +), xm = S.forwardRef(({ className: t, variant: e, ...n }, r) => /* @__PURE__ */ s("div", { ref: r, role: "alert", className: N(ym({ variant: e }), t), ...n })); +xm.displayName = "Alert"; +const Nm = S.forwardRef( + ({ className: t, ...e }, n) => /* @__PURE__ */ x( "h5", { ref: n, - className: x("tw-mb-1 tw-font-medium tw-leading-none tw-tracking-tight", t), + className: N("tw-mb-1 tw-font-medium tw-leading-none tw-tracking-tight", t), ...e, children: [ e.children, @@ -9808,15 +9716,15 @@ const Am = E.forwardRef( } ) ); -Am.displayName = "AlertTitle"; -const Mm = E.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s("div", { ref: n, className: x("tw-text-sm [&_p]:tw-leading-relaxed", t), ...e })); -Mm.displayName = "AlertDescription"; -const Dm = E.forwardRef( +Nm.displayName = "AlertTitle"; +const km = S.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s("div", { ref: n, className: N("tw-text-sm [&_p]:tw-leading-relaxed", t), ...e })); +km.displayName = "AlertDescription"; +const Em = S.forwardRef( ({ className: t, ...e }, n) => /* @__PURE__ */ s( "div", { ref: n, - className: x( + className: N( "pr-twp tw-rounded-lg tw-border tw-bg-card tw-text-card-foreground tw-shadow-sm", t ), @@ -9824,24 +9732,24 @@ const Dm = E.forwardRef( } ) ); -Dm.displayName = "Card"; -const Bm = E.forwardRef( +Em.displayName = "Card"; +const Sm = S.forwardRef( ({ className: t, ...e }, n) => /* @__PURE__ */ s( "div", { ref: n, - className: x("pr-twp tw-flex tw-flex-col tw-space-y-1.5 tw-p-6", t), + className: N("pr-twp tw-flex tw-flex-col tw-space-y-1.5 tw-p-6", t), ...e } ) ); -Bm.displayName = "CardHeader"; -const jm = E.forwardRef( +Sm.displayName = "CardHeader"; +const Tm = S.forwardRef( ({ className: t, ...e }, n) => /* @__PURE__ */ s( "h3", { ref: n, - className: x( + className: N( "pr-twp tw-text-2xl tw-font-semibold tw-leading-none tw-tracking-tight", t ), @@ -9850,27 +9758,27 @@ const jm = E.forwardRef( } ) ); -jm.displayName = "CardTitle"; -const Vm = E.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s("p", { ref: n, className: x("pr-twp tw-text-sm tw-text-muted-foreground", t), ...e })); -Vm.displayName = "CardDescription"; -const zm = E.forwardRef( - ({ className: t, ...e }, n) => /* @__PURE__ */ s("div", { ref: n, className: x("pr-twp tw-p-6 tw-pt-0", t), ...e }) +Tm.displayName = "CardTitle"; +const Cm = S.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s("p", { ref: n, className: N("pr-twp tw-text-sm tw-text-muted-foreground", t), ...e })); +Cm.displayName = "CardDescription"; +const Om = S.forwardRef( + ({ className: t, ...e }, n) => /* @__PURE__ */ s("div", { ref: n, className: N("pr-twp tw-p-6 tw-pt-0", t), ...e }) ); -zm.displayName = "CardContent"; -const Lm = E.forwardRef( +Om.displayName = "CardContent"; +const Rm = S.forwardRef( ({ className: t, ...e }, n) => /* @__PURE__ */ s( "div", { ref: n, - className: x("pr-twp tw-flex tw-items-center tw-p-6 tw-pt-0", t), + className: N("pr-twp tw-flex tw-items-center tw-p-6 tw-pt-0", t), ...e } ) ); -Lm.displayName = "CardFooter"; -function Dh({ ...t }) { +Rm.displayName = "CardFooter"; +function Eh({ ...t }) { return /* @__PURE__ */ s( - Hl, + Fl, { className: "tw-toaster tw-group", toastOptions: { @@ -9885,79 +9793,79 @@ function Dh({ ...t }) { } ); } -const Fm = E.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ N( - an.Root, +const _m = S.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ x( + on.Root, { ref: n, - className: x( + className: N( "pr-twp tw-relative tw-flex tw-w-full tw-touch-none tw-select-none tw-items-center", t ), ...e, children: [ - /* @__PURE__ */ s(an.Track, { className: "tw-relative tw-h-2 tw-w-full tw-grow tw-overflow-hidden tw-rounded-full tw-bg-secondary", children: /* @__PURE__ */ s(an.Range, { className: "tw-absolute tw-h-full tw-bg-primary" }) }), - /* @__PURE__ */ s(an.Thumb, { className: "tw-block tw-h-5 tw-w-5 tw-rounded-full tw-border-2 tw-border-primary tw-bg-background tw-ring-offset-background tw-transition-colors focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50" }) + /* @__PURE__ */ s(on.Track, { className: "tw-relative tw-h-2 tw-w-full tw-grow tw-overflow-hidden tw-rounded-full tw-bg-secondary", children: /* @__PURE__ */ s(on.Range, { className: "tw-absolute tw-h-full tw-bg-primary" }) }), + /* @__PURE__ */ s(on.Thumb, { className: "tw-block tw-h-5 tw-w-5 tw-rounded-full tw-border-2 tw-border-primary tw-bg-background tw-ring-offset-background tw-transition-colors focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50" }) ] } )); -Fm.displayName = an.Root.displayName; -const Um = E.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( - Yr.Root, +_m.displayName = on.Root.displayName; +const Pm = S.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( + Xr.Root, { - className: x( + className: N( "tw-peer pr-twp tw-inline-flex tw-h-6 tw-w-11 tw-shrink-0 tw-cursor-pointer tw-items-center tw-rounded-full tw-border-2 tw-border-transparent tw-transition-colors focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 focus-visible:tw-ring-offset-background disabled:tw-cursor-not-allowed disabled:tw-opacity-50 data-[state=checked]:tw-bg-primary data-[state=unchecked]:tw-bg-input", t ), ...e, ref: n, children: /* @__PURE__ */ s( - Yr.Thumb, + Xr.Thumb, { - className: x( + className: N( "pr-twp tw-pointer-events-none tw-block tw-h-5 tw-w-5 tw-rounded-full tw-bg-background tw-shadow-lg tw-ring-0 tw-transition-transform data-[state=checked]:tw-translate-x-5 data-[state=unchecked]:tw-translate-x-0" ) } ) } )); -Um.displayName = Yr.Root.displayName; -const Bh = _t.Root, Gm = E.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( - _t.List, +Pm.displayName = Xr.Root.displayName; +const Sh = Rt.Root, $m = S.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( + Rt.List, { ref: n, - className: x( + className: N( "tw-inline-flex tw-h-10 tw-items-center tw-justify-center tw-rounded-md tw-bg-muted tw-p-1 tw-text-muted-foreground", t ), ...e } )); -Gm.displayName = _t.List.displayName; -const Hm = E.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( - _t.Trigger, +$m.displayName = Rt.List.displayName; +const Im = S.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( + Rt.Trigger, { ref: n, - className: x( + className: N( "tw-inline-flex tw-items-center tw-justify-center tw-whitespace-nowrap tw-rounded-sm tw-px-3 tw-py-1.5 tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-all hover:tw-text-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50 data-[state=active]:tw-bg-background data-[state=active]:tw-text-foreground data-[state=active]:tw-shadow-sm", t ), ...e } )); -Hm.displayName = _t.Trigger.displayName; -const Xm = E.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( - _t.Content, +Im.displayName = Rt.Trigger.displayName; +const Am = S.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( + Rt.Content, { ref: n, - className: x( + className: N( "tw-mt-2 tw-ring-offset-background focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2", t ), ...e } )); -Xm.displayName = _t.Content.displayName; -function jh({ +Am.displayName = Rt.Content.displayName; +function Th({ isInstalling: t, handleClick: e, buttonText: n, @@ -9967,7 +9875,7 @@ function jh({ return /* @__PURE__ */ s( gt, { - className: x( + className: N( "tw-h-8 tw-rounded-md tw-text-white tw-transition tw-duration-300 tw-ease-in-out hover:tw-bg-blue-700", { "tw-cursor-not-allowed tw-bg-blue-700": t, @@ -9979,14 +9887,14 @@ function jh({ ), onClick: e, ...o, - children: t ? /* @__PURE__ */ s($n, { size: 15 }) : /* @__PURE__ */ N(ie, { children: [ - /* @__PURE__ */ s(bl, { size: 25, className: x("tw-h-4 tw-w-4", { "tw-mr-1": n }) }), + children: t ? /* @__PURE__ */ s($n, { size: 15 }) : /* @__PURE__ */ x(ie, { children: [ + /* @__PURE__ */ s(ml, { size: 25, className: N("tw-h-4 tw-w-4", { "tw-mr-1": n }) }), n ] }) } ); } -function Vh({ +function Ch({ isEnabling: t, handleClick: e, className: n, @@ -9995,7 +9903,7 @@ function Vh({ return /* @__PURE__ */ s( gt, { - className: x( + className: N( "tw-h-8 tw-rounded-md tw-bg-blue-600 tw-px-4 tw-text-white tw-transition tw-duration-300 tw-ease-in-out hover:tw-bg-blue-700", { "tw-cursor-not-allowed tw-bg-blue-700": t @@ -10004,14 +9912,14 @@ function Vh({ ), onClick: e, ...r, - children: t ? /* @__PURE__ */ N(ie, { children: [ + children: t ? /* @__PURE__ */ x(ie, { children: [ /* @__PURE__ */ s($n, { size: 15, className: "tw-mr-1 tw-text-white" }), "Enabling..." ] }) : "Enable" } ); } -function zh({ +function Oh({ isDisabling: t, handleClick: e, className: n, @@ -10020,7 +9928,7 @@ function zh({ return /* @__PURE__ */ s( gt, { - className: x( + className: N( "tw-h-8 tw-rounded-md tw-bg-gray-300 tw-text-black tw-transition tw-duration-300 tw-ease-in-out hover:tw-bg-gray-400", { "tw-cursor-not-allowed tw-bg-gray-400": t @@ -10029,14 +9937,14 @@ function zh({ ), onClick: e, ...r, - children: t ? /* @__PURE__ */ N(ie, { children: [ + children: t ? /* @__PURE__ */ x(ie, { children: [ /* @__PURE__ */ s($n, { size: 15, className: "tw-mr-1 tw-text-black" }), "Disabling..." ] }) : "Disable" } ); } -function Lh({ +function Rh({ isUpdating: t, handleClick: e, className: n, @@ -10045,7 +9953,7 @@ function Lh({ return /* @__PURE__ */ s( gt, { - className: x( + className: N( "tw-h-8 tw-rounded-md tw-bg-blue-600 tw-px-4 tw-text-white tw-transition tw-duration-300 tw-ease-in-out hover:tw-bg-blue-700 hover:tw-text-white", { "tw-cursor-not-allowed tw-bg-blue-700": t @@ -10054,20 +9962,20 @@ function Lh({ ), onClick: e, ...r, - children: t ? /* @__PURE__ */ N(ie, { children: [ + children: t ? /* @__PURE__ */ x(ie, { children: [ /* @__PURE__ */ s($n, { size: 15, className: "tw-mr-1 tw-text-white" }), "Updating..." ] }) : "Update" } ); } -function Fh({ +function _h({ id: t, markdown: e, className: n, anchorTarget: r }) { - const o = It( + const o = $t( () => ({ overrides: { a: { @@ -10079,16 +9987,16 @@ function Fh({ }), [r] ); - return /* @__PURE__ */ s("div", { id: t, className: x("pr-twp tw-prose", n), children: /* @__PURE__ */ s(Xl, { options: o, children: e }) }); + return /* @__PURE__ */ s("div", { id: t, className: N("pr-twp tw-prose", n), children: /* @__PURE__ */ s(Ul, { options: o, children: e }) }); } -const Ym = Qn((t, e) => /* @__PURE__ */ N( +const Mm = Qn((t, e) => /* @__PURE__ */ x( gt, { ref: e, className: "tw-rounded-md tw-border tw-border-dashed tw-border-gray-400 tw-bg-white tw-px-4 tw-py-2 tw-text-black tw-transition tw-duration-300 tw-ease-in-out hover:tw-border-blue-600 hover:tw-bg-white hover:tw-text-blue-600", ...t, children: [ - /* @__PURE__ */ s(vl, { size: 16, className: "tw-mr-2 tw-h-4 tw-w-4 tw-text-gray-700 hover:tw-text-blue-600" }), + /* @__PURE__ */ s(hl, { size: 16, className: "tw-mr-2 tw-h-4 tw-w-4 tw-text-gray-700 hover:tw-text-blue-600" }), "Filter", /* @__PURE__ */ s( er, @@ -10100,53 +10008,53 @@ const Ym = Qn((t, e) => /* @__PURE__ */ N( ] } )); -var Wm = /* @__PURE__ */ ((t) => (t[t.Check = 0] = "Check", t[t.Radio = 1] = "Radio", t))(Wm || {}); -function Uh({ id: t, groups: e }) { - return /* @__PURE__ */ s("div", { id: t, children: /* @__PURE__ */ N(fo, { children: [ - /* @__PURE__ */ s(mi, { asChild: !0, children: /* @__PURE__ */ s(Ym, {}) }), - /* @__PURE__ */ s(rr, { children: e.map((n) => /* @__PURE__ */ N("div", { children: [ +var Dm = /* @__PURE__ */ ((t) => (t[t.Check = 0] = "Check", t[t.Radio = 1] = "Radio", t))(Dm || {}); +function Ph({ id: t, groups: e }) { + return /* @__PURE__ */ s("div", { id: t, children: /* @__PURE__ */ x(wo, { children: [ + /* @__PURE__ */ s(wi, { asChild: !0, children: /* @__PURE__ */ s(Mm, {}) }), + /* @__PURE__ */ s(rr, { children: e.map((n) => /* @__PURE__ */ x("div", { children: [ /* @__PURE__ */ s(Sn, { children: n.label }), - /* @__PURE__ */ s(sc, { children: n.items.map((r) => /* @__PURE__ */ s("div", { children: r.itemType === 0 ? /* @__PURE__ */ s(mo, { onClick: r.onClick, children: r.label }) : /* @__PURE__ */ s(gi, { onClick: r.onClick, value: r.label, children: r.label }) }, r.label)) }), + /* @__PURE__ */ s(oc, { children: n.items.map((r) => /* @__PURE__ */ s("div", { children: r.itemType === 0 ? /* @__PURE__ */ s(fo, { onClick: r.onClick, children: r.label }) : /* @__PURE__ */ s(mi, { onClick: r.onClick, value: r.label, children: r.label }) }, r.label)) }), /* @__PURE__ */ s(or, {}) ] }, n.label)) }) ] }) }); } -function Gh({ id: t, message: e }) { +function $h({ id: t, message: e }) { return /* @__PURE__ */ s("div", { id: t, className: "tw-mb-20 tw-mt-20 tw-flex tw-items-center tw-justify-center", children: /* @__PURE__ */ s("div", { className: "tw-w-3/4 tw-rounded-lg tw-bg-gray-100 tw-p-8 tw-text-center", children: /* @__PURE__ */ s("p", { className: "tw-text-lg tw-text-gray-800", children: e }) }) }); } -function Hh({ +function Ih({ id: t, category: e, downloads: n, languages: r, moreInfoUrl: o }) { - const a = new Ol("en", { + const a = new Sl("en", { notation: "compact", compactDisplay: "short" }).format(Object.values(n).reduce((l, c) => l + c, 0)), i = () => { window.scrollTo(0, document.body.scrollHeight); }; - return /* @__PURE__ */ N( + return /* @__PURE__ */ x( "div", { id: t, className: "tw-flex tw-flex-wrap tw-items-start tw-space-x-4 tw-border-b tw-border-t tw-bg-white tw-pb-4 tw-pt-4", children: [ - /* @__PURE__ */ N("div", { className: "tw-flex tw-flex-col tw-items-center", children: [ + /* @__PURE__ */ x("div", { className: "tw-flex tw-flex-col tw-items-center", children: [ /* @__PURE__ */ s("div", { className: "tw-flex tw-items-center tw-rounded-md tw-bg-gray-100 tw-px-2 tw-py-1", children: /* @__PURE__ */ s("span", { className: "tw-text-xs tw-font-semibold tw-text-gray-700", children: e }) }), /* @__PURE__ */ s("span", { className: "tw-text-xs tw-text-gray-500", children: "CATEGORY" }) ] }), /* @__PURE__ */ s("div", { className: "tw-mx-2 tw-h-10 tw-border-l tw-border-gray-300" }), - /* @__PURE__ */ N("div", { className: "tw-flex tw-flex-col tw-items-center", children: [ - /* @__PURE__ */ N("div", { className: "tw-flex tw-items-center tw-rounded-md tw-bg-gray-100 tw-px-2 tw-py-1", children: [ - /* @__PURE__ */ s(yl, { className: "tw-mr-1 tw-h-4 tw-w-4" }), + /* @__PURE__ */ x("div", { className: "tw-flex tw-flex-col tw-items-center", children: [ + /* @__PURE__ */ x("div", { className: "tw-flex tw-items-center tw-rounded-md tw-bg-gray-100 tw-px-2 tw-py-1", children: [ + /* @__PURE__ */ s(gl, { className: "tw-mr-1 tw-h-4 tw-w-4" }), /* @__PURE__ */ s("span", { className: "tw-text-xs tw-font-semibold tw-text-gray-700", children: a }) ] }), /* @__PURE__ */ s("span", { className: "tw-text-xs tw-text-gray-500", children: "USERS" }) ] }), /* @__PURE__ */ s("div", { className: "tw-mx-2 tw-h-10 tw-border-l tw-border-gray-300" }), - /* @__PURE__ */ N("div", { className: "tw-flex tw-flex-col tw-items-center", children: [ + /* @__PURE__ */ x("div", { className: "tw-flex tw-flex-col tw-items-center", children: [ /* @__PURE__ */ s("div", { className: "tw-flex tw-items-center", children: r.slice(0, 3).map((l) => /* @__PURE__ */ s( "span", { @@ -10155,7 +10063,7 @@ function Hh({ }, l )) }), - r.length > 3 && /* @__PURE__ */ N( + r.length > 3 && /* @__PURE__ */ x( "button", { type: "button", @@ -10170,8 +10078,8 @@ function Hh({ ) ] }), /* @__PURE__ */ s("div", { className: "tw-mx-2 tw-h-10 tw-border-l tw-border-gray-300" }), - /* @__PURE__ */ N("div", { className: "tw-ml-auto tw-flex tw-flex-col tw-space-y-2", children: [ - /* @__PURE__ */ N( + /* @__PURE__ */ x("div", { className: "tw-ml-auto tw-flex tw-flex-col tw-space-y-2", children: [ + /* @__PURE__ */ x( "a", { href: o, @@ -10180,11 +10088,11 @@ function Hh({ className: "tw-flex tw-items-center tw-text-xs tw-font-semibold tw-text-gray-500 tw-underline", children: [ "Website", - /* @__PURE__ */ s(xl, { className: "tw-ml-1 tw-inline tw-h-4 tw-w-4" }) + /* @__PURE__ */ s(bl, { className: "tw-ml-1 tw-inline tw-h-4 tw-w-4" }) ] } ), - /* @__PURE__ */ N( + /* @__PURE__ */ x( "a", { href: "https://example.com", @@ -10193,7 +10101,7 @@ function Hh({ className: "tw-flex tw-items-center tw-text-xs tw-font-semibold tw-text-gray-500 tw-underline", children: [ "Support", - /* @__PURE__ */ s(Nl, { className: "tw-ml-1 tw-inline tw-h-4 tw-w-4" }) + /* @__PURE__ */ s(vl, { className: "tw-ml-1 tw-inline tw-h-4 tw-w-4" }) ] } ) @@ -10202,7 +10110,7 @@ function Hh({ } ); } -function qm({ id: t, versionHistory: e }) { +function Bm({ id: t, versionHistory: e }) { const [n, r] = ut(!1), o = /* @__PURE__ */ new Date(); function a(l) { const c = new Date(l), d = new Date(o.getTime() - c.getTime()), p = d.getUTCFullYear() - 1970, f = d.getUTCMonth(), w = d.getUTCDate() - 1; @@ -10210,12 +10118,12 @@ function qm({ id: t, versionHistory: e }) { return p > 0 ? g = `${p.toString()} year${p === 1 ? "" : "s"} ago` : f > 0 ? g = `${f.toString()} month${f === 1 ? "" : "s"} ago` : w === 0 ? g = "today" : g = `${w.toString()} day${w === 1 ? "" : "s"} ago`, g; } const i = Object.entries(e).sort((l, c) => c[0].localeCompare(l[0])); - return /* @__PURE__ */ N("div", { id: t, children: [ + return /* @__PURE__ */ x("div", { id: t, children: [ /* @__PURE__ */ s("h3", { className: "tw-text-md tw-font-semibold", children: "What`s New" }), - /* @__PURE__ */ s("ul", { className: "tw-list-disc tw-pl-5 tw-pr-4 tw-text-xs tw-text-gray-600", children: (n ? i : i.slice(0, 5)).map((l) => /* @__PURE__ */ N("div", { className: "tw-mt-3 tw-flex tw-justify-between", children: [ + /* @__PURE__ */ s("ul", { className: "tw-list-disc tw-pl-5 tw-pr-4 tw-text-xs tw-text-gray-600", children: (n ? i : i.slice(0, 5)).map((l) => /* @__PURE__ */ x("div", { className: "tw-mt-3 tw-flex tw-justify-between", children: [ /* @__PURE__ */ s("div", { className: "tw-text-gray-600", children: /* @__PURE__ */ s("li", { className: "tw-prose tw-text-xs", children: /* @__PURE__ */ s("span", { children: l[1].description }) }) }), - /* @__PURE__ */ N("div", { className: "tw-justify-end tw-text-right", children: [ - /* @__PURE__ */ N("div", { children: [ + /* @__PURE__ */ x("div", { className: "tw-justify-end tw-text-right", children: [ + /* @__PURE__ */ x("div", { children: [ "Version ", l[0] ] }), @@ -10233,30 +10141,30 @@ function qm({ id: t, versionHistory: e }) { ) ] }); } -function Xh({ +function Ah({ id: t, publisherDisplayName: e, fileSize: n, locales: r, versionHistory: o }) { - const a = It(() => Rl(n), [n]), l = ((c) => { + const a = $t(() => Tl(n), [n]), l = ((c) => { const d = new Intl.DisplayNames(navigator.language, { type: "language" }); return c.map((p) => d.of(p)); })(r); - return /* @__PURE__ */ s("div", { id: t, className: "tw-border-t tw-pb-4 tw-pt-4", children: /* @__PURE__ */ N("div", { className: "tw-md:flex-row tw-md:space-x-8 tw-flex tw-flex-col tw-space-x-0", children: [ - /* @__PURE__ */ s(qm, { versionHistory: o }), + return /* @__PURE__ */ s("div", { id: t, className: "tw-border-t tw-pb-4 tw-pt-4", children: /* @__PURE__ */ x("div", { className: "tw-md:flex-row tw-md:space-x-8 tw-flex tw-flex-col tw-space-x-0", children: [ + /* @__PURE__ */ s(Bm, { versionHistory: o }), /* @__PURE__ */ s("div", { className: "tw-md:border-t-0 tw-md:border-l tw-md-h-auto tw-md-ml-8 tw-mt-4 tw-border-t tw-border-gray-300" }), - /* @__PURE__ */ N("div", { className: "tw-md:mt-0 tw-mt-4 tw-flex-1 tw-space-y-3", children: [ + /* @__PURE__ */ x("div", { className: "tw-md:mt-0 tw-mt-4 tw-flex-1 tw-space-y-3", children: [ /* @__PURE__ */ s("h2", { className: "tw-text-md tw-font-semibold", children: "Information" }), - /* @__PURE__ */ N("div", { className: "tw-flex tw-items-start tw-justify-between tw-pr-4 tw-text-xs tw-text-gray-600", children: [ - /* @__PURE__ */ N("p", { className: "tw-flex tw-flex-col tw-justify-start", children: [ + /* @__PURE__ */ x("div", { className: "tw-flex tw-items-start tw-justify-between tw-pr-4 tw-text-xs tw-text-gray-600", children: [ + /* @__PURE__ */ x("p", { className: "tw-flex tw-flex-col tw-justify-start", children: [ /* @__PURE__ */ s("span", { className: "tw-mb-2", children: "Publisher" }), /* @__PURE__ */ s("span", { className: "tw-font-semibold", children: e }), /* @__PURE__ */ s("span", { className: "tw-mb-2 tw-mt-4", children: "Size" }), /* @__PURE__ */ s("span", { className: "tw-font-semibold", children: a }) ] }), - /* @__PURE__ */ s("div", { className: "tw-flex tw-w-3/4 tw-items-center tw-justify-between tw-text-xs tw-text-gray-600", children: /* @__PURE__ */ N("p", { className: "tw-flex tw-flex-col tw-justify-start", children: [ + /* @__PURE__ */ s("div", { className: "tw-flex tw-w-3/4 tw-items-center tw-justify-between tw-text-xs tw-text-gray-600", children: /* @__PURE__ */ x("p", { className: "tw-flex tw-flex-col tw-justify-start", children: [ /* @__PURE__ */ s("span", { className: "tw-mb-2", children: "Languages" }), /* @__PURE__ */ s("span", { className: "tw-font-semibold", children: l.join(", ") }) ] }) }) @@ -10264,7 +10172,7 @@ function Xh({ ] }) ] }) }); } -const Yh = (t, e) => { +const Mh = (t, e) => { ae(() => { if (!t) return () => { @@ -10274,30 +10182,30 @@ const Yh = (t, e) => { n(); }; }, [t, e]); -}, Gr = () => !1, Wh = (t, e) => { - const [n] = lo( - Et(async () => { +}, Ur = () => !1, Dh = (t, e) => { + const [n] = so( + kt(async () => { if (!t) - return Gr; + return Ur; const r = await Promise.resolve(t(e)); return async () => r(); }, [e, t]), - Gr, + Ur, // We want the unsubscriber to return to default value immediately upon changing subscription // So the useEffect below will unsubscribe asap { preserveValue: !1 } ); ae(() => () => { - n !== Gr && n(); + n !== Ur && n(); }, [n]); }; -function Km(t, e = "top") { +function jm(t, e = "top") { if (!t || typeof document > "u") return; const n = document.head || document.querySelector("head"), r = n.querySelector(":first-child"), o = document.createElement("style"); o.appendChild(document.createTextNode(t)), e === "top" && r ? n.insertBefore(o, r) : n.appendChild(o); } -Km(`*, ::before, ::after { +jm(`*, ::before, ::after { --tw-border-spacing-x: 0; --tw-border-spacing-y: 0; --tw-translate-x: 0; @@ -11367,17 +11275,10 @@ video:where(.pr-twp,.pr-twp *) { .tw-inset-0 { inset: 0px; } -.tw-inset-x-0 { - left: 0px; - right: 0px; -} .tw-inset-y-0 { top: 0px; bottom: 0px; } -.tw-bottom-0 { - bottom: 0px; -} .tw-bottom-2 { bottom: 0.5rem; } @@ -12089,9 +11990,6 @@ video:where(.pr-twp,.pr-twp *) { .tw-border-l-2 { border-left-width: 2px; } -.tw-border-r { - border-right-width: 1px; -} .tw-border-r-0 { border-right-width: 0px; } @@ -13101,10 +12999,6 @@ video:where(.pr-twp,.pr-twp *) { background-color: hsl(var(--accent)); } -.data-\\[state\\=open\\]\\:tw-bg-secondary[data-state="open"] { - background-color: hsl(var(--secondary)); -} - .data-\\[state\\=selected\\]\\:tw-bg-muted[data-state="selected"] { background-color: hsl(var(--muted)); } @@ -13159,14 +13053,6 @@ video:where(.pr-twp,.pr-twp *) { box-shadow: var(--tw-ring-offset-shadow, 0 0 #0000), var(--tw-ring-shadow, 0 0 #0000), var(--tw-shadow); } -.data-\\[state\\=closed\\]\\:tw-duration-300[data-state="closed"] { - transition-duration: 300ms; -} - -.data-\\[state\\=open\\]\\:tw-duration-500[data-state="open"] { - transition-duration: 500ms; -} - .data-\\[state\\=open\\]\\:tw-animate-in[data-state="open"] { animation-name: enter; animation-duration: 150ms; @@ -13219,62 +13105,22 @@ video:where(.pr-twp,.pr-twp *) { --tw-enter-translate-y: 0.5rem; } -.data-\\[state\\=closed\\]\\:tw-slide-out-to-bottom[data-state="closed"] { - --tw-exit-translate-y: 100%; -} - -.data-\\[state\\=closed\\]\\:tw-slide-out-to-left[data-state="closed"] { - --tw-exit-translate-x: -100%; -} - .data-\\[state\\=closed\\]\\:tw-slide-out-to-left-1\\/2[data-state="closed"] { --tw-exit-translate-x: -50%; } -.data-\\[state\\=closed\\]\\:tw-slide-out-to-right[data-state="closed"] { - --tw-exit-translate-x: 100%; -} - -.data-\\[state\\=closed\\]\\:tw-slide-out-to-top[data-state="closed"] { - --tw-exit-translate-y: -100%; -} - .data-\\[state\\=closed\\]\\:tw-slide-out-to-top-\\[48\\%\\][data-state="closed"] { --tw-exit-translate-y: -48%; } -.data-\\[state\\=open\\]\\:tw-slide-in-from-bottom[data-state="open"] { - --tw-enter-translate-y: 100%; -} - -.data-\\[state\\=open\\]\\:tw-slide-in-from-left[data-state="open"] { - --tw-enter-translate-x: -100%; -} - .data-\\[state\\=open\\]\\:tw-slide-in-from-left-1\\/2[data-state="open"] { --tw-enter-translate-x: -50%; } -.data-\\[state\\=open\\]\\:tw-slide-in-from-right[data-state="open"] { - --tw-enter-translate-x: 100%; -} - -.data-\\[state\\=open\\]\\:tw-slide-in-from-top[data-state="open"] { - --tw-enter-translate-y: -100%; -} - .data-\\[state\\=open\\]\\:tw-slide-in-from-top-\\[48\\%\\][data-state="open"] { --tw-enter-translate-y: -48%; } -.data-\\[state\\=closed\\]\\:tw-duration-300[data-state="closed"] { - animation-duration: 300ms; -} - -.data-\\[state\\=open\\]\\:tw-duration-500[data-state="open"] { - animation-duration: 500ms; -} - .data-\\[state\\=open\\]\\:hover\\:tw-bg-sidebar-accent:hover[data-state="open"] { background-color: hsl(var(--sidebar-accent)); } @@ -13413,10 +13259,6 @@ video:where(.pr-twp,.pr-twp *) { display: none; } - .sm\\:tw-max-w-sm { - max-width: 24rem; - } - .sm\\:tw-grid-cols-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); } @@ -13659,10 +13501,6 @@ video:where(.pr-twp,.pr-twp *) { padding-inline-end: 0px; } -.\\[\\&\\>button\\]\\:tw-hidden>button { - display: none; -} - .\\[\\&\\>span\\:last-child\\]\\:tw-truncate>span:last-child { overflow: hidden; text-overflow: ellipsis; @@ -13826,28 +13664,39 @@ video:where(.pr-twp,.pr-twp *) { .banded-row[data-state='selected']:hover { cursor: default; } -.papi-menu-item { - background-color: transparent; +.papi-multi-column-menu { + background-color: rgb(222, 222, 222); + display: flex; + flex-direction: column; + padding-left: 3px; + padding-right: 3px; } -.papi-menu-icon-trailing { - margin-left: 10px; - place-content: flex-end; +.papi-menu-column { + font-size: 11pt; + font-weight: 600; + padding-bottom: 2px; } -.papi-menu-item img { - max-width: 24px; - max-height: 24px; +.papi-menu-column ul { + padding-top: 0; } -.papi-menu-drawer-paper { - height: fit-content !important; - position: absolute !important; + +.papi-menu-column-header { + background-color: rgb(181, 181, 181); + padding-left: 24px; + margin-top: 0; + margin-bottom: 0; } -.papi-toolbar-children { - padding: 10px; - display: flex; - gap: 8px; +.papi-multi-column-menu.paratext { + background-color: rgb(76, 106, 76); + color: rgb(214, 255, 152); +} + +.papi-multi-column-menu.paratext.bright { + color: rgb(76, 106, 76); + background-color: rgb(214, 255, 152); } .papi-icon-button { border: 0; @@ -13875,154 +13724,143 @@ video:where(.pr-twp,.pr-twp *) { background-color: greenyellow; color: darkgreen; } -.papi-multi-column-menu { - background-color: rgb(222, 222, 222); - display: flex; - flex-direction: column; - padding-left: 3px; - padding-right: 3px; -} - -.papi-menu-column { - font-size: 11pt; - font-weight: 600; - padding-bottom: 2px; +.papi-menu-drawer-paper { + height: fit-content !important; + position: absolute !important; } -.papi-menu-column ul { - padding-top: 0; +.papi-toolbar-children { + padding: 10px; + display: flex; + gap: 8px; } - -.papi-menu-column-header { - background-color: rgb(181, 181, 181); - padding-left: 24px; - margin-top: 0; - margin-bottom: 0; +.papi-menu-item { + background-color: transparent; } -.papi-multi-column-menu.paratext { - background-color: rgb(76, 106, 76); - color: rgb(214, 255, 152); +.papi-menu-icon-trailing { + margin-left: 10px; + place-content: flex-end; } -.papi-multi-column-menu.paratext.bright { - color: rgb(76, 106, 76); - background-color: rgb(214, 255, 152); +.papi-menu-item img { + max-width: 24px; + max-height: 24px; } `, "top"); export { - Im as Alert, - Mm as AlertDescription, - Am as AlertTitle, - bh as BOOK_SELECTOR_STRING_KEYS, - gh as BookChapterControl, - Ic as BookSelectionMode, - vh as BookSelector, + xm as Alert, + km as AlertDescription, + Nm as AlertTitle, + ih as BOOK_SELECTOR_STRING_KEYS, + ah as BookChapterControl, + _c as BookSelectionMode, + sh as BookSelector, gt as Button, - Dm as Card, - zm as CardContent, - Vm as CardDescription, - Lm as CardFooter, - Bm as CardHeader, - jm as CardTitle, - $c as ChapterRangeSelector, - ho as Checkbox, - $h as Checklist, - qr as ComboBox, - Lc as DataTable, - zh as DisableButton, - fo as DropdownMenu, - mo as DropdownMenuCheckboxItem, + Em as Card, + Om as CardContent, + Cm as CardDescription, + Rm as CardFooter, + Sm as CardHeader, + Tm as CardTitle, + Rc as ChapterRangeSelector, + mo as Checkbox, + yh as Checklist, + Wr as ComboBox, + jc as DataTable, + Oh as DisableButton, + wo as DropdownMenu, + fo as DropdownMenuCheckboxItem, rr as DropdownMenuContent, - sc as DropdownMenuGroup, - hi as DropdownMenuItem, - Wm as DropdownMenuItemType, + oc as DropdownMenuGroup, + fi as DropdownMenuItem, + Dm as DropdownMenuItemType, Sn as DropdownMenuLabel, - fh as DropdownMenuPortal, - hh as DropdownMenuRadioGroup, - gi as DropdownMenuRadioItem, + nh as DropdownMenuPortal, + oh as DropdownMenuRadioGroup, + mi as DropdownMenuRadioItem, or as DropdownMenuSeparator, - dc as DropdownMenuShortcut, - mh as DropdownMenuSub, - cc as DropdownMenuSubContent, - lc as DropdownMenuSubTrigger, - mi as DropdownMenuTrigger, - Vh as EnableButton, - Ym as FilterButton, - Uh as FilterDropdown, - Xh as Footer, - Om as GridMenu, - Pm as HamburgerMenuButton, - kh as INVENTORY_STRING_KEYS, - Ih as IconButton, - Ye as Input, - jh as InstallButton, - Eh as Inventory, - Xt as Label, - Fh as MarkdownRenderer, - Ms as MenuItem, - Hh as MoreInfo, - Sh as NavigationContentSearch, - Gh as NoExtensionsFound, - bi as RadioGroup, - Wr as RadioGroupItem, - Ch as ScriptureResultsViewer, - Oh as ScrollGroupSelector, - Pi as SearchBar, - gn as Select, + sc as DropdownMenuShortcut, + rh as DropdownMenuSub, + ic as DropdownMenuSubContent, + ac as DropdownMenuSubTrigger, + wi as DropdownMenuTrigger, + Ch as EnableButton, + Mm as FilterButton, + Ph as FilterDropdown, + Ah as Footer, + hm as GridMenu, + vm as HamburgerMenuButton, + ph as INVENTORY_STRING_KEYS, + xh as IconButton, + Xe as Input, + Th as InstallButton, + uh as Inventory, + Ht as Label, + _h as MarkdownRenderer, + Ps as MenuItem, + Ih as MoreInfo, + wh as NavigationContentSearch, + $h as NoExtensionsFound, + hi as RadioGroup, + Yr as RadioGroupItem, + mh as ScriptureResultsViewer, + hh as ScrollGroupSelector, + Ri as SearchBar, + hn as Select, Be as SelectContent, - Mc as SelectGroup, - Gt as SelectItem, - Dc as SelectLabel, - Ci as SelectScrollDownButton, - Ti as SelectScrollUpButton, - Bc as SelectSeparator, + $c as SelectGroup, + Ut as SelectItem, + Ic as SelectLabel, + Si as SelectScrollDownButton, + Ei as SelectScrollUpButton, + Ac as SelectSeparator, De as SelectTrigger, - bn as SelectValue, - go as Separator, - Rh as SettingsList, - Ph as SettingsListHeader, - _h as SettingsListItem, - Td as SettingsSidebar, - Th as SettingsSidebarContentSearch, - Fm as Slider, - Dh as Sonner, + gn as SelectValue, + ho as Separator, + gh as SettingsList, + vh as SettingsListHeader, + bh as SettingsListItem, + fd as SettingsSidebar, + fh as SettingsSidebarContentSearch, + _m as Slider, + Eh as Sonner, $n as Spinner, - Um as Switch, + Pm as Switch, ar as Table, sr as TableBody, - zc as TableCaption, + Bc as TableCaption, je as TableCell, - Vc as TableFooter, - vn as TableHead, + Dc as TableFooter, + bn as TableHead, ir as TableHeader, oe as TableRow, - Bh as Tabs, - Xm as TabsContent, - Gm as TabsList, - Hm as TabsTrigger, - Ah as TextField, - _i as ToggleGroup, + Sh as Tabs, + Am as TabsContent, + $m as TabsList, + Im as TabsTrigger, + Nh as TextField, + Oi as ToggleGroup, Un as ToggleGroupItem, - Mh as Toolbar, - Lh as UpdateButton, - qm as VersionHistory, - $i as VerticalTabs, - Ai as VerticalTabsContent, - Ii as VerticalTabsList, - Kc as VerticalTabsTrigger, - xc as buttonVariants, - x as cn, - Gc as getBookNumFromId, - Uc as getLinesFromUSFM, - oa as getNumberFromUSFM, - Hc as getStatusForItem, - xh as inventoryCountColumn, - yh as inventoryItemColumn, - Nh as inventoryStatusColumn, - Jh as sonner, - Yh as useEvent, - Wh as useEventAsync, - lo as usePromise + kh as Toolbar, + Rh as UpdateButton, + Bm as VersionHistory, + _i as VerticalTabs, + $i as VerticalTabsContent, + Pi as VerticalTabsList, + Yc as VerticalTabsTrigger, + bc as buttonVariants, + N as cn, + Lc as getBookNumFromId, + zc as getLinesFromUSFM, + ra as getNumberFromUSFM, + Fc as getStatusForItem, + ch as inventoryCountColumn, + lh as inventoryItemColumn, + dh as inventoryStatusColumn, + Vh as sonner, + Mh as useEvent, + Dh as useEventAsync, + so as usePromise }; //# sourceMappingURL=index.js.map diff --git a/lib/platform-bible-react/dist/index.js.map b/lib/platform-bible-react/dist/index.js.map index 09b33e438b..d3c282bcee 100644 --- a/lib/platform-bible-react/dist/index.js.map +++ b/lib/platform-bible-react/dist/index.js.map @@ -1 +1 @@ -{"version":3,"file":"index.js","sources":["../src/utils/shadcn-ui.util.ts","../src/components/shadcn-ui/input.tsx","../src/components/advanced/book-chapter-control/book-chapter-input.component.tsx","../../../node_modules/@sillsdev/scripture/dist/index.es.js","../src/components/shadcn-ui/dropdown-menu.tsx","../src/components/advanced/book-chapter-control/book-menu-item.component.tsx","../src/components/advanced/book-chapter-control/chapter-select.component.tsx","../src/components/advanced/book-chapter-control/go-to-menu-item.component.tsx","../src/components/advanced/book-chapter-control/book-chapter-control.component.tsx","../src/components/shadcn-ui/button.tsx","../src/components/shadcn-ui/label.tsx","../src/components/shadcn-ui/radio-group.tsx","../src/components/shadcn-ui/popover.tsx","../src/components/shadcn-ui/dialog.tsx","../src/components/shadcn-ui/command.tsx","../src/components/basics/combo-box.component.tsx","../src/components/basics/chapter-range-selector.component.tsx","../src/components/advanced/book-selector.component.tsx","../src/components/advanced/data-table/data-table-column-toggle.component.tsx","../src/components/shadcn-ui/select.tsx","../src/components/advanced/data-table/data-table-pagination.component.tsx","../src/components/shadcn-ui/table.tsx","../src/components/advanced/data-table/data-table.component.tsx","../src/components/advanced/inventory/occurrences-table.component.tsx","../src/components/shadcn-ui/checkbox.tsx","../src/components/advanced/inventory/inventory-utils.ts","../src/components/shadcn-ui/toggle.tsx","../src/components/shadcn-ui/toggle-group.tsx","../src/components/advanced/inventory/inventory-columns.tsx","../src/components/advanced/inventory/inventory.component.tsx","../src/components/basics/search-bar.component.tsx","../src/components/basics/tabs-vertical.tsx","../src/components/advanced/tab-navigation-content-search.component.tsx","../src/components/shadcn-ui/separator.tsx","../src/components/shadcn-ui/sheet.tsx","../src/components/shadcn-ui/skeleton.tsx","../src/components/shadcn-ui/tooltip.tsx","../src/components/hooks/use-mobile.tsx","../src/components/shadcn-ui/sidebar.tsx","../src/components/advanced/settings-components/settings-sidebar.component.tsx","../src/components/advanced/settings-components/settings-sidebar-content-search.component.tsx","../src/components/advanced/scripture-results-viewer/scripture-results-viewer.component.tsx","../src/components/advanced/scroll-group-selector.component.tsx","../src/components/advanced/settings-components/settings-list.component.tsx","../src/components/basics/checklist.component.tsx","../../../node_modules/@babel/runtime/helpers/interopRequireDefault.js","../../../node_modules/@mui/utils/chainPropTypes/chainPropTypes.js","../../../node_modules/@babel/runtime/helpers/esm/extends.js","../../../node_modules/@mui/utils/deepmerge/deepmerge.js","../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.production.min.js","../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.development.js","../../../node_modules/prop-types/node_modules/react-is/index.js","../../../node_modules/object-assign/index.js","../../../node_modules/prop-types/lib/ReactPropTypesSecret.js","../../../node_modules/prop-types/lib/has.js","../../../node_modules/prop-types/checkPropTypes.js","../../../node_modules/prop-types/factoryWithTypeCheckers.js","../../../node_modules/prop-types/factoryWithThrowingShims.js","../../../node_modules/prop-types/index.js","../../../node_modules/@mui/utils/elementAcceptingRef/elementAcceptingRef.js","../../../node_modules/@mui/utils/exactProp/exactProp.js","../../../node_modules/@mui/utils/formatMuiErrorMessage/formatMuiErrorMessage.js","../../../node_modules/react-is/cjs/react-is.production.min.js","../../../node_modules/react-is/cjs/react-is.development.js","../../../node_modules/react-is/index.js","../../../node_modules/@mui/utils/getDisplayName/getDisplayName.js","../../../node_modules/@mui/utils/HTMLElementType/HTMLElementType.js","../../../node_modules/@mui/utils/refType/refType.js","../../../node_modules/@mui/utils/capitalize/capitalize.js","../../../node_modules/@mui/utils/createChainedFunction/createChainedFunction.js","../../../node_modules/@mui/utils/debounce/debounce.js","../../../node_modules/@mui/utils/deprecatedPropType/deprecatedPropType.js","../../../node_modules/@mui/utils/isMuiElement/isMuiElement.js","../../../node_modules/@mui/utils/ownerDocument/ownerDocument.js","../../../node_modules/@mui/utils/ownerWindow/ownerWindow.js","../../../node_modules/@mui/utils/requirePropFactory/requirePropFactory.js","../../../node_modules/@mui/utils/setRef/setRef.js","../../../node_modules/@mui/utils/useEnhancedEffect/useEnhancedEffect.js","../../../node_modules/@mui/utils/useId/useId.js","../../../node_modules/@mui/utils/unsupportedProp/unsupportedProp.js","../../../node_modules/@mui/utils/useControlled/useControlled.js","../../../node_modules/@mui/utils/useEventCallback/useEventCallback.js","../../../node_modules/@mui/utils/useForkRef/useForkRef.js","../../../node_modules/@mui/utils/useLazyRef/useLazyRef.js","../../../node_modules/@mui/utils/useOnMount/useOnMount.js","../../../node_modules/@mui/utils/useTimeout/useTimeout.js","../../../node_modules/@mui/utils/useIsFocusVisible/useIsFocusVisible.js","../../../node_modules/@mui/utils/resolveProps/resolveProps.js","../../../node_modules/@mui/utils/composeClasses/composeClasses.js","../../../node_modules/@mui/utils/ClassNameGenerator/ClassNameGenerator.js","../../../node_modules/@mui/utils/generateUtilityClass/generateUtilityClass.js","../../../node_modules/@mui/utils/generateUtilityClasses/generateUtilityClasses.js","../../../node_modules/@mui/utils/clamp/clamp.js","../../../node_modules/@babel/runtime/helpers/esm/objectWithoutPropertiesLoose.js","../../../node_modules/@mui/system/esm/createTheme/createBreakpoints.js","../../../node_modules/@mui/system/esm/createTheme/shape.js","../../../node_modules/@mui/system/esm/responsivePropType.js","../../../node_modules/@mui/system/esm/merge.js","../../../node_modules/@mui/system/esm/breakpoints.js","../../../node_modules/@mui/system/esm/style.js","../../../node_modules/@mui/system/esm/memoize.js","../../../node_modules/@mui/system/esm/spacing.js","../../../node_modules/@mui/system/esm/createTheme/createSpacing.js","../../../node_modules/@mui/system/esm/compose.js","../../../node_modules/@mui/system/esm/borders.js","../../../node_modules/@mui/system/esm/cssGrid.js","../../../node_modules/@mui/system/esm/palette.js","../../../node_modules/@mui/system/esm/sizing.js","../../../node_modules/@mui/system/esm/styleFunctionSx/defaultSxConfig.js","../../../node_modules/@mui/system/esm/styleFunctionSx/styleFunctionSx.js","../../../node_modules/@mui/system/esm/createTheme/applyStyles.js","../../../node_modules/@mui/system/esm/createTheme/createTheme.js","../../../node_modules/@mui/system/esm/useThemeWithoutDefault.js","../../../node_modules/@mui/system/esm/useTheme.js","../../../node_modules/@mui/system/esm/createStyled.js","../../../node_modules/@mui/system/esm/useThemeProps/getThemeProps.js","../../../node_modules/@mui/system/esm/useThemeProps/useThemeProps.js","../../../node_modules/@mui/system/esm/colorManipulator.js","../../../node_modules/@mui/material/styles/createMixins.js","../../../node_modules/@mui/material/colors/common.js","../../../node_modules/@mui/material/colors/grey.js","../../../node_modules/@mui/material/colors/purple.js","../../../node_modules/@mui/material/colors/red.js","../../../node_modules/@mui/material/colors/orange.js","../../../node_modules/@mui/material/colors/blue.js","../../../node_modules/@mui/material/colors/lightBlue.js","../../../node_modules/@mui/material/colors/green.js","../../../node_modules/@mui/material/styles/createPalette.js","../../../node_modules/@mui/material/styles/createTypography.js","../../../node_modules/@mui/material/styles/shadows.js","../../../node_modules/@mui/material/styles/createTransitions.js","../../../node_modules/@mui/material/styles/zIndex.js","../../../node_modules/@mui/material/styles/createTheme.js","../../../node_modules/@mui/material/styles/defaultTheme.js","../../../node_modules/@mui/material/styles/identifier.js","../../../node_modules/@mui/material/styles/useThemeProps.js","../../../node_modules/@mui/material/styles/styled.js","../../../node_modules/@mui/material/SvgIcon/svgIconClasses.js","../../../node_modules/@mui/material/SvgIcon/SvgIcon.js","../../../node_modules/@mui/material/utils/createSvgIcon.js","../../../node_modules/@mui/material/utils/index.js","../../../node_modules/@mui/icons-material/utils/createSvgIcon.js","../../../node_modules/@mui/icons-material/ArrowRight.js","../../../node_modules/@mui/base/utils/isHostComponent.js","../../../node_modules/@mui/base/utils/appendOwnerState.js","../../../node_modules/@mui/base/utils/ClassNameConfigurator.js","../../../node_modules/@mui/base/utils/extractEventHandlers.js","../../../node_modules/@mui/base/utils/resolveComponentProps.js","../../../node_modules/@mui/base/utils/omitEventHandlers.js","../../../node_modules/@mui/base/utils/mergeSlotProps.js","../../../node_modules/@mui/base/utils/useSlotProps.js","../../../node_modules/@mui/base/generateUtilityClass/index.js","../../../node_modules/@mui/base/generateUtilityClasses/index.js","../../../node_modules/@mui/base/Portal/Portal.js","../../../node_modules/@popperjs/core/lib/enums.js","../../../node_modules/@popperjs/core/lib/dom-utils/getNodeName.js","../../../node_modules/@popperjs/core/lib/dom-utils/getWindow.js","../../../node_modules/@popperjs/core/lib/dom-utils/instanceOf.js","../../../node_modules/@popperjs/core/lib/modifiers/applyStyles.js","../../../node_modules/@popperjs/core/lib/utils/getBasePlacement.js","../../../node_modules/@popperjs/core/lib/utils/math.js","../../../node_modules/@popperjs/core/lib/utils/userAgent.js","../../../node_modules/@popperjs/core/lib/dom-utils/isLayoutViewport.js","../../../node_modules/@popperjs/core/lib/dom-utils/getBoundingClientRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/getLayoutRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/contains.js","../../../node_modules/@popperjs/core/lib/dom-utils/getComputedStyle.js","../../../node_modules/@popperjs/core/lib/dom-utils/isTableElement.js","../../../node_modules/@popperjs/core/lib/dom-utils/getDocumentElement.js","../../../node_modules/@popperjs/core/lib/dom-utils/getParentNode.js","../../../node_modules/@popperjs/core/lib/dom-utils/getOffsetParent.js","../../../node_modules/@popperjs/core/lib/utils/getMainAxisFromPlacement.js","../../../node_modules/@popperjs/core/lib/utils/within.js","../../../node_modules/@popperjs/core/lib/utils/getFreshSideObject.js","../../../node_modules/@popperjs/core/lib/utils/mergePaddingObject.js","../../../node_modules/@popperjs/core/lib/utils/expandToHashMap.js","../../../node_modules/@popperjs/core/lib/modifiers/arrow.js","../../../node_modules/@popperjs/core/lib/utils/getVariation.js","../../../node_modules/@popperjs/core/lib/modifiers/computeStyles.js","../../../node_modules/@popperjs/core/lib/modifiers/eventListeners.js","../../../node_modules/@popperjs/core/lib/utils/getOppositePlacement.js","../../../node_modules/@popperjs/core/lib/utils/getOppositeVariationPlacement.js","../../../node_modules/@popperjs/core/lib/dom-utils/getWindowScroll.js","../../../node_modules/@popperjs/core/lib/dom-utils/getWindowScrollBarX.js","../../../node_modules/@popperjs/core/lib/dom-utils/getViewportRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/getDocumentRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/isScrollParent.js","../../../node_modules/@popperjs/core/lib/dom-utils/getScrollParent.js","../../../node_modules/@popperjs/core/lib/dom-utils/listScrollParents.js","../../../node_modules/@popperjs/core/lib/utils/rectToClientRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/getClippingRect.js","../../../node_modules/@popperjs/core/lib/utils/computeOffsets.js","../../../node_modules/@popperjs/core/lib/utils/detectOverflow.js","../../../node_modules/@popperjs/core/lib/utils/computeAutoPlacement.js","../../../node_modules/@popperjs/core/lib/modifiers/flip.js","../../../node_modules/@popperjs/core/lib/modifiers/hide.js","../../../node_modules/@popperjs/core/lib/modifiers/offset.js","../../../node_modules/@popperjs/core/lib/modifiers/popperOffsets.js","../../../node_modules/@popperjs/core/lib/utils/getAltAxis.js","../../../node_modules/@popperjs/core/lib/modifiers/preventOverflow.js","../../../node_modules/@popperjs/core/lib/dom-utils/getHTMLElementScroll.js","../../../node_modules/@popperjs/core/lib/dom-utils/getNodeScroll.js","../../../node_modules/@popperjs/core/lib/dom-utils/getCompositeRect.js","../../../node_modules/@popperjs/core/lib/utils/orderModifiers.js","../../../node_modules/@popperjs/core/lib/utils/debounce.js","../../../node_modules/@popperjs/core/lib/utils/mergeByName.js","../../../node_modules/@popperjs/core/lib/createPopper.js","../../../node_modules/@popperjs/core/lib/popper.js","../../../node_modules/@mui/base/Popper/popperClasses.js","../../../node_modules/@mui/base/Popper/Popper.js","../../../node_modules/@mui/material/styles/useTheme.js","../../../node_modules/@babel/runtime/helpers/esm/setPrototypeOf.js","../../../node_modules/@babel/runtime/helpers/esm/inheritsLoose.js","../../../node_modules/react-transition-group/esm/config.js","../../../node_modules/react-transition-group/esm/utils/PropTypes.js","../../../node_modules/react-transition-group/esm/TransitionGroupContext.js","../../../node_modules/react-transition-group/esm/utils/reflow.js","../../../node_modules/react-transition-group/esm/Transition.js","../../../node_modules/@mui/material/transitions/utils.js","../../../node_modules/@mui/material/Grow/Grow.js","../../../node_modules/@mui/material/Popper/Popper.js","../../../node_modules/@mui/material/Tooltip/tooltipClasses.js","../../../node_modules/@mui/material/Tooltip/Tooltip.js","../src/components/mui/menu-item.component.tsx","../src/components/mui/grouped-menu-item-list.component.tsx","../src/components/mui/top-level-menu.component.tsx","../src/components/mui/grid-menu.component.tsx","../src/hooks/use-promise.hook.ts","../../../node_modules/@mui/icons-material/esm/Menu.js","../src/components/mui/hamburger-menu-button.component.tsx","../src/components/mui/icon-button.component.tsx","../src/components/basics/spinner.component.tsx","../src/components/basics/text-field.component.tsx","../src/components/mui/toolbar.component.tsx","../src/components/shadcn-ui/alert.tsx","../src/components/shadcn-ui/card.tsx","../src/components/shadcn-ui/sonner.tsx","../src/components/shadcn-ui/slider.tsx","../src/components/shadcn-ui/switch.tsx","../src/components/shadcn-ui/tabs.tsx","../src/components/advanced/extension-marketplace/buttons/install-button.component.tsx","../src/components/advanced/extension-marketplace/buttons/enable-button.component.tsx","../src/components/advanced/extension-marketplace/buttons/disable-button.component.tsx","../src/components/advanced/extension-marketplace/buttons/update-button.component.tsx","../src/components/advanced/extension-marketplace/markdown-renderer.component.tsx","../src/components/advanced/extension-marketplace/buttons/filter-button.component.tsx","../src/components/advanced/extension-marketplace/filter-dropdown.component.tsx","../src/components/advanced/extension-marketplace/no-extensions-found.component.tsx","../src/components/advanced/extension-marketplace/more-info.component.tsx","../src/components/advanced/extension-marketplace/version-history.component.tsx","../src/components/advanced/extension-marketplace/footer.component.tsx","../src/hooks/use-event.hook.ts","../src/hooks/use-event-async.hook.ts"],"sourcesContent":["import { type ClassValue, clsx } from 'clsx';\nimport { extendTailwindMerge } from 'tailwind-merge';\n\nconst twMergeCustom = extendTailwindMerge({ prefix: 'tw-' });\n\n/**\n * Tailwind and CSS class application helper function. Uses\n * [`clsx`](https://www.npmjs.com/package/clsx) to make it easy to apply classes conditionally using\n * object syntax, and uses [`tailwind-merge`](https://www.npmjs.com/package/tailwind-merge) to make\n * it easy to merge/overwrite Tailwind classes in a programmer-logic-friendly way.\n *\n * Note: `tailwind-merge` is configured to use the prefix `tw-`, so you must use the same prefix\n * with any Tailwind classes you use with this function to successfully overwrite other Tailwind\n * classes. `platform-bible-react` is configured to use `tw-` as its Tailwind prefix, so any\n * Tailwind classes you pass into `platform-bible-react` components will be compared using the `tw-`\n * prefix.\n *\n * This function was popularized by\n * [shadcn/ui](https://ui.shadcn.com/docs/installation/manual#add-a-cn-helper). See [ByteGrad's\n * explanation video](https://www.youtube.com/watch?v=re2JFITR7TI) for more information.\n *\n * @example\n *\n * ```typescript\n * const borderShouldBeBlue = true;\n * const textShouldBeRed = true;\n * const heightShouldBe20 = false;\n * const classString = cn(\n * 'tw-bg-primary tw-h-10 tw-text-primary-foreground',\n * 'tw-bg-secondary',\n * {\n * 'tw-border-blue-500': borderShouldBeBlue,\n * 'tw-text-red-500': textShouldBeRed,\n * 'tw-h-20': heightShouldBe20,\n * },\n * 'some-class',\n * );\n * ```\n *\n * The resulting `classString` is `'tw-h-10 tw-bg-secondary tw-border-blue-500 tw-text-red-500\n * some-class'`\n *\n * - Notice that `'tw-bg-secondary'`, specified later, overwrote `'tw-bg-primary'`, specified earlier,\n * because they are Tailwind classes that affect the same css property\n * - Notice that `'tw-text-red-500'`, specified later, overwrote `'tw-text-primary-foreground'`,\n * specified earlier, because they are Tailwind classes that affect the same css property\n * - Notice that `'tw-h-20'`, specified later, did not overwrite `'tw-h-10'`, specified earlier,\n * because `'tw-h-20'` is part of a conditional class object and its value evaluated to `false`;\n * therefore it was not applied\n * - Notice that `'some-class'` was applied. This function is not limited only to Tailwind classes.\n *\n *\n * @param inputs Class strings or `clsx` conditional class objects to merge. Tailwind classes\n * specified later in the arguments overwrite similar Tailwind classes specified earlier in the\n * arguments\n * @returns Class string containing all applicable classes from the arguments based on the rules\n * described above\n */\n// shadcn/ui uses this export in its boilerplate code\n// eslint-disable-next-line import/prefer-default-export\nexport function cn(...inputs: ClassValue[]) {\n return twMergeCustom(clsx(inputs));\n}\n","import React from 'react';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport interface InputProps extends React.InputHTMLAttributes {}\n\nexport const Input = React.forwardRef(\n ({ className, type, ...props }, ref) => {\n return (\n \n );\n },\n);\nInput.displayName = 'Input';\n","import { FocusEventHandler, forwardRef, KeyboardEvent, MouseEventHandler } from 'react';\nimport { History } from 'lucide-react';\nimport { Input as ShadInput } from '@/components/shadcn-ui/input';\n\nexport type BookChapterInputProps = {\n handleSearch: (searchString: string) => void;\n handleKeyDown: (event: KeyboardEvent) => void;\n handleOnClick: MouseEventHandler;\n handleSubmit: () => void;\n onFocus?: FocusEventHandler;\n value: string;\n placeholder: string;\n};\n\n// Shadcn Input sets type to \"button\"- HAVE to prop spread before setting type\nconst BookChapterInput = forwardRef(\n (\n { handleSearch, handleKeyDown, handleOnClick, handleSubmit, ...props }: BookChapterInputProps,\n ref,\n ) => {\n return (\n
    \n handleSearch(event.target.value)}\n onKeyDown={(e) => {\n if (e.key === 'Enter') {\n handleSubmit();\n }\n handleKeyDown(e);\n }}\n onClick={handleOnClick}\n ref={ref}\n />\n {\n // eslint-disable-next-line no-console\n console.log('back in history');\n }}\n />\n
    \n );\n },\n);\n\nexport default BookChapterInput;\n","var P = Object.defineProperty;\nvar R = (t, e, s) => e in t ? P(t, e, { enumerable: !0, configurable: !0, writable: !0, value: s }) : t[e] = s;\nvar n = (t, e, s) => R(t, typeof e != \"symbol\" ? e + \"\" : e, s);\nclass _ {\n constructor() {\n n(this, \"books\");\n n(this, \"firstSelectedBookNum\");\n n(this, \"lastSelectedBookNum\");\n n(this, \"count\");\n n(this, \"selectedBookNumbers\");\n n(this, \"selectedBookIds\");\n }\n}\nconst N = [\n \"GEN\",\n \"EXO\",\n \"LEV\",\n \"NUM\",\n \"DEU\",\n \"JOS\",\n \"JDG\",\n \"RUT\",\n \"1SA\",\n \"2SA\",\n // 10\n \"1KI\",\n \"2KI\",\n \"1CH\",\n \"2CH\",\n \"EZR\",\n \"NEH\",\n \"EST\",\n \"JOB\",\n \"PSA\",\n \"PRO\",\n // 20\n \"ECC\",\n \"SNG\",\n \"ISA\",\n \"JER\",\n \"LAM\",\n \"EZK\",\n \"DAN\",\n \"HOS\",\n \"JOL\",\n \"AMO\",\n // 30\n \"OBA\",\n \"JON\",\n \"MIC\",\n \"NAM\",\n \"HAB\",\n \"ZEP\",\n \"HAG\",\n \"ZEC\",\n \"MAL\",\n \"MAT\",\n // 40\n \"MRK\",\n \"LUK\",\n \"JHN\",\n \"ACT\",\n \"ROM\",\n \"1CO\",\n \"2CO\",\n \"GAL\",\n \"EPH\",\n \"PHP\",\n // 50\n \"COL\",\n \"1TH\",\n \"2TH\",\n \"1TI\",\n \"2TI\",\n \"TIT\",\n \"PHM\",\n \"HEB\",\n \"JAS\",\n \"1PE\",\n // 60\n \"2PE\",\n \"1JN\",\n \"2JN\",\n \"3JN\",\n \"JUD\",\n \"REV\",\n \"TOB\",\n \"JDT\",\n \"ESG\",\n \"WIS\",\n // 70\n \"SIR\",\n \"BAR\",\n \"LJE\",\n \"S3Y\",\n \"SUS\",\n \"BEL\",\n \"1MA\",\n \"2MA\",\n \"3MA\",\n \"4MA\",\n // 80\n \"1ES\",\n \"2ES\",\n \"MAN\",\n \"PS2\",\n \"ODA\",\n \"PSS\",\n \"JSA\",\n // actual variant text for JOS, now in LXA text\n \"JDB\",\n // actual variant text for JDG, now in LXA text\n \"TBS\",\n // actual variant text for TOB, now in LXA text\n \"SST\",\n // actual variant text for SUS, now in LXA text // 90\n \"DNT\",\n // actual variant text for DAN, now in LXA text\n \"BLT\",\n // actual variant text for BEL, now in LXA text\n \"XXA\",\n \"XXB\",\n \"XXC\",\n \"XXD\",\n \"XXE\",\n \"XXF\",\n \"XXG\",\n \"FRT\",\n // 100\n \"BAK\",\n \"OTH\",\n \"3ES\",\n // Used previously but really should be 2ES\n \"EZA\",\n // Used to be called 4ES, but not actually in any known project\n \"5EZ\",\n // Used to be called 5ES, but not actually in any known project\n \"6EZ\",\n // Used to be called 6ES, but not actually in any known project\n \"INT\",\n \"CNC\",\n \"GLO\",\n \"TDX\",\n // 110\n \"NDX\",\n \"DAG\",\n \"PS3\",\n \"2BA\",\n \"LBA\",\n \"JUB\",\n \"ENO\",\n \"1MQ\",\n \"2MQ\",\n \"3MQ\",\n // 120\n \"REP\",\n \"4BA\",\n \"LAO\"\n], B = [\n \"XXA\",\n \"XXB\",\n \"XXC\",\n \"XXD\",\n \"XXE\",\n \"XXF\",\n \"XXG\",\n \"FRT\",\n \"BAK\",\n \"OTH\",\n \"INT\",\n \"CNC\",\n \"GLO\",\n \"TDX\",\n \"NDX\"\n], O = [\n \"Genesis\",\n \"Exodus\",\n \"Leviticus\",\n \"Numbers\",\n \"Deuteronomy\",\n \"Joshua\",\n \"Judges\",\n \"Ruth\",\n \"1 Samuel\",\n \"2 Samuel\",\n \"1 Kings\",\n \"2 Kings\",\n \"1 Chronicles\",\n \"2 Chronicles\",\n \"Ezra\",\n \"Nehemiah\",\n \"Esther (Hebrew)\",\n \"Job\",\n \"Psalms\",\n \"Proverbs\",\n \"Ecclesiastes\",\n \"Song of Songs\",\n \"Isaiah\",\n \"Jeremiah\",\n \"Lamentations\",\n \"Ezekiel\",\n \"Daniel (Hebrew)\",\n \"Hosea\",\n \"Joel\",\n \"Amos\",\n \"Obadiah\",\n \"Jonah\",\n \"Micah\",\n \"Nahum\",\n \"Habakkuk\",\n \"Zephaniah\",\n \"Haggai\",\n \"Zechariah\",\n \"Malachi\",\n \"Matthew\",\n \"Mark\",\n \"Luke\",\n \"John\",\n \"Acts\",\n \"Romans\",\n \"1 Corinthians\",\n \"2 Corinthians\",\n \"Galatians\",\n \"Ephesians\",\n \"Philippians\",\n \"Colossians\",\n \"1 Thessalonians\",\n \"2 Thessalonians\",\n \"1 Timothy\",\n \"2 Timothy\",\n \"Titus\",\n \"Philemon\",\n \"Hebrews\",\n \"James\",\n \"1 Peter\",\n \"2 Peter\",\n \"1 John\",\n \"2 John\",\n \"3 John\",\n \"Jude\",\n \"Revelation\",\n \"Tobit\",\n \"Judith\",\n \"Esther Greek\",\n \"Wisdom of Solomon\",\n \"Sirach (Ecclesiasticus)\",\n \"Baruch\",\n \"Letter of Jeremiah\",\n \"Song of 3 Young Men\",\n \"Susanna\",\n \"Bel and the Dragon\",\n \"1 Maccabees\",\n \"2 Maccabees\",\n \"3 Maccabees\",\n \"4 Maccabees\",\n \"1 Esdras (Greek)\",\n \"2 Esdras (Latin)\",\n \"Prayer of Manasseh\",\n \"Psalm 151\",\n \"Odes\",\n \"Psalms of Solomon\",\n // WARNING, if you change the spelling of the *obsolete* tag be sure to update\n // IsObsolete routine\n \"Joshua A. *obsolete*\",\n \"Judges B. *obsolete*\",\n \"Tobit S. *obsolete*\",\n \"Susanna Th. *obsolete*\",\n \"Daniel Th. *obsolete*\",\n \"Bel Th. *obsolete*\",\n \"Extra A\",\n \"Extra B\",\n \"Extra C\",\n \"Extra D\",\n \"Extra E\",\n \"Extra F\",\n \"Extra G\",\n \"Front Matter\",\n \"Back Matter\",\n \"Other Matter\",\n \"3 Ezra *obsolete*\",\n \"Apocalypse of Ezra\",\n \"5 Ezra (Latin Prologue)\",\n \"6 Ezra (Latin Epilogue)\",\n \"Introduction\",\n \"Concordance \",\n \"Glossary \",\n \"Topical Index\",\n \"Names Index\",\n \"Daniel Greek\",\n \"Psalms 152-155\",\n \"2 Baruch (Apocalypse)\",\n \"Letter of Baruch\",\n \"Jubilees\",\n \"Enoch\",\n \"1 Meqabyan\",\n \"2 Meqabyan\",\n \"3 Meqabyan\",\n \"Reproof (Proverbs 25-31)\",\n \"4 Baruch (Rest of Baruch)\",\n \"Laodiceans\"\n], S = K();\nfunction g(t, e = !0) {\n return e && (t = t.toUpperCase()), t in S ? S[t] : 0;\n}\nfunction k(t) {\n return g(t) > 0;\n}\nfunction x(t) {\n const e = typeof t == \"string\" ? g(t) : t;\n return e >= 40 && e <= 66;\n}\nfunction T(t) {\n return (typeof t == \"string\" ? g(t) : t) <= 39;\n}\nfunction X(t) {\n return t <= 66;\n}\nfunction V(t) {\n const e = typeof t == \"string\" ? g(t) : t;\n return w(e) && !X(e);\n}\nfunction* L() {\n for (let t = 1; t <= N.length; t++) yield t;\n}\nconst G = 1, A = N.length;\nfunction H() {\n return [\"XXA\", \"XXB\", \"XXC\", \"XXD\", \"XXE\", \"XXF\", \"XXG\"];\n}\nfunction C(t, e = \"***\") {\n const s = t - 1;\n return s < 0 || s >= N.length ? e : N[s];\n}\nfunction I(t) {\n return t <= 0 || t > A ? \"******\" : O[t - 1];\n}\nfunction y(t) {\n return I(g(t));\n}\nfunction w(t) {\n const e = typeof t == \"number\" ? C(t) : t;\n return k(e) && !B.includes(e);\n}\nfunction q(t) {\n const e = typeof t == \"number\" ? C(t) : t;\n return k(e) && B.includes(e);\n}\nfunction U(t) {\n return O[t - 1].includes(\"*obsolete*\");\n}\nfunction K() {\n const t = {};\n for (let e = 0; e < N.length; e++)\n t[N[e]] = e + 1;\n return t;\n}\nconst m = {\n allBookIds: N,\n nonCanonicalIds: B,\n bookIdToNumber: g,\n isBookIdValid: k,\n isBookNT: x,\n isBookOT: T,\n isBookOTNT: X,\n isBookDC: V,\n allBookNumbers: L,\n firstBook: G,\n lastBook: A,\n extraBooks: H,\n bookNumberToId: C,\n bookNumberToEnglishName: I,\n bookIdToEnglishName: y,\n isCanonical: w,\n isExtraMaterial: q,\n isObsolete: U\n};\nvar l = /* @__PURE__ */ ((t) => (t[t.Unknown = 0] = \"Unknown\", t[t.Original = 1] = \"Original\", t[t.Septuagint = 2] = \"Septuagint\", t[t.Vulgate = 3] = \"Vulgate\", t[t.English = 4] = \"English\", t[t.RussianProtestant = 5] = \"RussianProtestant\", t[t.RussianOrthodox = 6] = \"RussianOrthodox\", t))(l || {});\nconst h = class h {\n // private versInfo: Versification;\n constructor(e) {\n n(this, \"name\");\n n(this, \"fullPath\");\n n(this, \"isPresent\");\n n(this, \"hasVerseSegments\");\n n(this, \"isCustomized\");\n n(this, \"baseVersification\");\n n(this, \"scriptureBooks\");\n n(this, \"_type\");\n if (e == null)\n throw new Error(\"Argument undefined\");\n typeof e == \"string\" ? (this.name = e, this._type = l[e]) : (this._type = e, this.name = l[e]);\n }\n get type() {\n return this._type;\n }\n equals(e) {\n return !e.type || !this.type ? !1 : e.type === this.type;\n }\n};\nn(h, \"Original\", new h(l.Original)), n(h, \"Septuagint\", new h(l.Septuagint)), n(h, \"Vulgate\", new h(l.Vulgate)), n(h, \"English\", new h(l.English)), n(h, \"RussianProtestant\", new h(l.RussianProtestant)), n(h, \"RussianOrthodox\", new h(l.RussianOrthodox));\nlet c = h;\nfunction E(t, e) {\n const s = e[0];\n for (let r = 1; r < e.length; r++)\n t = t.split(e[r]).join(s);\n return t.split(s);\n}\nvar D = /* @__PURE__ */ ((t) => (t[t.Valid = 0] = \"Valid\", t[t.UnknownVersification = 1] = \"UnknownVersification\", t[t.OutOfRange = 2] = \"OutOfRange\", t[t.VerseOutOfOrder = 3] = \"VerseOutOfOrder\", t[t.VerseRepeated = 4] = \"VerseRepeated\", t))(D || {});\nconst i = class i {\n constructor(e, s, r, a) {\n /** Not yet implemented. */\n n(this, \"firstChapter\");\n /** Not yet implemented. */\n n(this, \"lastChapter\");\n /** Not yet implemented. */\n n(this, \"lastVerse\");\n /** Not yet implemented. */\n n(this, \"hasSegmentsDefined\");\n /** Not yet implemented. */\n n(this, \"text\");\n /** Not yet implemented. */\n n(this, \"BBBCCCVVVS\");\n /** Not yet implemented. */\n n(this, \"longHashCode\");\n /** The versification of the reference. */\n n(this, \"versification\");\n n(this, \"rtlMark\", \"‏\");\n n(this, \"_bookNum\", 0);\n n(this, \"_chapterNum\", 0);\n n(this, \"_verseNum\", 0);\n n(this, \"_verse\");\n if (r == null && a == null)\n if (e != null && typeof e == \"string\") {\n const o = e, u = s != null && s instanceof c ? s : void 0;\n this.setEmpty(u), this.parse(o);\n } else if (e != null && typeof e == \"number\") {\n const o = s != null && s instanceof c ? s : void 0;\n this.setEmpty(o), this._verseNum = e % i.chapterDigitShifter, this._chapterNum = Math.floor(\n e % i.bookDigitShifter / i.chapterDigitShifter\n ), this._bookNum = Math.floor(e / i.bookDigitShifter);\n } else if (s == null)\n if (e != null && e instanceof i) {\n const o = e;\n this._bookNum = o.bookNum, this._chapterNum = o.chapterNum, this._verseNum = o.verseNum, this._verse = o.verse, this.versification = o.versification;\n } else {\n if (e == null) return;\n const o = e instanceof c ? e : i.defaultVersification;\n this.setEmpty(o);\n }\n else\n throw new Error(\"VerseRef constructor not supported.\");\n else if (e != null && s != null && r != null)\n if (typeof e == \"string\" && typeof s == \"string\" && typeof r == \"string\")\n this.setEmpty(a), this.updateInternal(e, s, r);\n else if (typeof e == \"number\" && typeof s == \"number\" && typeof r == \"number\")\n this._bookNum = e, this._chapterNum = s, this._verseNum = r, this.versification = a ?? i.defaultVersification;\n else\n throw new Error(\"VerseRef constructor not supported.\");\n else\n throw new Error(\"VerseRef constructor not supported.\");\n }\n /**\n * Determines if the verse string is in a valid format (does not consider versification).\n */\n static isVerseParseable(e) {\n return e.length > 0 && \"0123456789\".includes(e[0]) && !e.endsWith(this.verseRangeSeparator) && !e.endsWith(this.verseSequenceIndicator);\n }\n /**\n * Tries to parse the specified string into a verse reference.\n * @param str - The string to attempt to parse.\n * @returns success: `true` if the specified string was successfully parsed, `false` otherwise.\n * @returns verseRef: The result of the parse if successful, or empty VerseRef if it failed\n */\n static tryParse(e) {\n let s;\n try {\n return s = new i(e), { success: !0, verseRef: s };\n } catch (r) {\n if (r instanceof v)\n return s = new i(), { success: !1, verseRef: s };\n throw r;\n }\n }\n /**\n * Gets the reference as a comparable integer where the book, chapter, and verse each occupy 3\n * digits.\n * @param bookNum - Book number (this is 1-based, not an index).\n * @param chapterNum - Chapter number.\n * @param verseNum - Verse number.\n * @returns The reference as a comparable integer where the book, chapter, and verse each occupy 3\n * digits.\n */\n static getBBBCCCVVV(e, s, r) {\n return e % i.bcvMaxValue * i.bookDigitShifter + (s >= 0 ? s % i.bcvMaxValue * i.chapterDigitShifter : 0) + (r >= 0 ? r % i.bcvMaxValue : 0);\n }\n /**\n * Deserializes a serialized VerseRef.\n * @param serializedVerseRef - Serialized VerseRef to create from.\n * @returns the deserialized VerseRef.\n */\n static fromJSON(e) {\n const { book: s, chapterNum: r, verseNum: a, verse: o, versificationStr: u } = e, f = o || a.toString();\n let d;\n return u && (d = new c(u)), s ? new i(s, r.toString(), f, d) : new i();\n }\n /**\n * Parses a verse string and gets the leading numeric portion as a number.\n * @param verseStr - verse string to parse\n * @returns true if the entire string could be parsed as a single, simple verse number (1-999);\n * false if the verse string represented a verse bridge, contained segment letters, or was invalid\n */\n static tryGetVerseNum(e) {\n let s;\n if (!e)\n return s = -1, { success: !0, vNum: s };\n s = 0;\n let r;\n for (let a = 0; a < e.length; a++) {\n if (r = e[a], r < \"0\" || r > \"9\")\n return a === 0 && (s = -1), { success: !1, vNum: s };\n if (s = s * 10 + +r - 0, s > i.bcvMaxValue)\n return s = -1, { success: !1, vNum: s };\n }\n return { success: !0, vNum: s };\n }\n /**\n * Checks to see if a VerseRef hasn't been set - all values are the default.\n */\n get isDefault() {\n return this.bookNum === 0 && this.chapterNum === 0 && this.verseNum === 0 && this.versification == null;\n }\n /**\n * Gets whether the verse contains multiple verses.\n */\n get hasMultiple() {\n return this._verse != null && (this._verse.includes(i.verseRangeSeparator) || this._verse.includes(i.verseSequenceIndicator));\n }\n /**\n * Gets or sets the book of the reference. Book is the 3-letter abbreviation in capital letters,\n * e.g. `'MAT'`.\n */\n get book() {\n return m.bookNumberToId(this.bookNum, \"\");\n }\n set book(e) {\n this.bookNum = m.bookIdToNumber(e);\n }\n /**\n * Gets or sets the chapter of the reference,. e.g. `'3'`.\n */\n get chapter() {\n return this.isDefault || this._chapterNum < 0 ? \"\" : this._chapterNum.toString();\n }\n set chapter(e) {\n const s = +e;\n this._chapterNum = Number.isInteger(s) ? s : -1;\n }\n /**\n * Gets or sets the verse of the reference, including range, segments, and sequences, e.g. `'4'`,\n * or `'4b-5a, 7'`.\n */\n get verse() {\n return this._verse != null ? this._verse : this.isDefault || this._verseNum < 0 ? \"\" : this._verseNum.toString();\n }\n set verse(e) {\n const { success: s, vNum: r } = i.tryGetVerseNum(e);\n this._verse = s ? void 0 : e.replace(this.rtlMark, \"\"), this._verseNum = r, !(this._verseNum >= 0) && ({ vNum: this._verseNum } = i.tryGetVerseNum(this._verse));\n }\n /**\n * Get or set Book based on book number, e.g. `42`.\n */\n get bookNum() {\n return this._bookNum;\n }\n set bookNum(e) {\n if (e <= 0 || e > m.lastBook)\n throw new v(\n \"BookNum must be greater than zero and less than or equal to last book\"\n );\n this._bookNum = e;\n }\n /**\n * Gets or sets the chapter number, e.g. `3`. `-1` if not valid.\n */\n get chapterNum() {\n return this._chapterNum;\n }\n set chapterNum(e) {\n this.chapterNum = e;\n }\n /**\n * Gets or sets verse start number, e.g. `4`. `-1` if not valid.\n */\n get verseNum() {\n return this._verseNum;\n }\n set verseNum(e) {\n this._verseNum = e;\n }\n /**\n * String representing the versification (should ONLY be used for serialization/deserialization).\n *\n * @remarks This is for backwards compatibility when ScrVers was an enumeration.\n */\n get versificationStr() {\n var e;\n return (e = this.versification) == null ? void 0 : e.name;\n }\n set versificationStr(e) {\n this.versification = this.versification != null ? new c(e) : void 0;\n }\n /**\n * Determines if the reference is valid.\n */\n get valid() {\n return this.validStatus === 0;\n }\n /**\n * Get the valid status for this reference.\n */\n get validStatus() {\n return this.validateVerse(i.verseRangeSeparators, i.verseSequenceIndicators);\n }\n /**\n * Gets the reference as a comparable integer where the book,\n * chapter, and verse each occupy three digits and the verse is 0.\n */\n get BBBCCC() {\n return i.getBBBCCCVVV(this._bookNum, this._chapterNum, 0);\n }\n /**\n * Gets the reference as a comparable integer where the book,\n * chapter, and verse each occupy three digits. If verse is not null\n * (i.e., this reference represents a complex reference with verse\n * segments or bridge) this cannot be used for an exact comparison.\n */\n get BBBCCCVVV() {\n return i.getBBBCCCVVV(this._bookNum, this._chapterNum, this._verseNum);\n }\n /**\n * Gets whether the verse is defined as an excluded verse in the versification.\n * Does not handle verse ranges.\n */\n // eslint-disable-next-line @typescript-eslint/class-literal-property-style\n get isExcluded() {\n return !1;\n }\n /**\n * Parses the reference in the specified string.\n * Optionally versification can follow reference as in GEN 3:11/4\n * Throw an exception if\n * - invalid book name\n * - chapter number is missing or not a number\n * - verse number is missing or does not start with a number\n * - versification is invalid\n * @param verseStr - string to parse e.g. 'MAT 3:11'\n */\n parse(e) {\n if (e = e.replace(this.rtlMark, \"\"), e.includes(\"/\")) {\n const o = e.split(\"/\");\n if (e = o[0], o.length > 1)\n try {\n const u = +o[1].trim();\n this.versification = new c(l[u]);\n } catch {\n throw new v(\"Invalid reference : \" + e);\n }\n }\n const s = e.trim().split(\" \");\n if (s.length !== 2)\n throw new v(\"Invalid reference : \" + e);\n const r = s[1].split(\":\"), a = +r[0];\n if (r.length !== 2 || m.bookIdToNumber(s[0]) === 0 || !Number.isInteger(a) || a < 0 || !i.isVerseParseable(r[1]))\n throw new v(\"Invalid reference : \" + e);\n this.updateInternal(s[0], r[0], r[1]);\n }\n /**\n * Simplifies this verse ref so that it has no bridging of verses or\n * verse segments like `'1a'`.\n */\n simplify() {\n this._verse = void 0;\n }\n /**\n * Makes a clone of the reference.\n *\n * @returns The cloned VerseRef.\n */\n clone() {\n return new i(this);\n }\n toString() {\n const e = this.book;\n return e === \"\" ? \"\" : `${e} ${this.chapter}:${this.verse}`;\n }\n toJSON() {\n let e = this.verse;\n (e === \"\" || e === this.verseNum.toString()) && (e = void 0);\n const s = {\n book: this.book,\n chapterNum: this.chapterNum,\n verseNum: this.verseNum,\n verse: e,\n versificationStr: this.versificationStr\n };\n return e || delete s.verse, s;\n }\n /**\n * Compares this `VerseRef` with supplied one.\n * @param verseRef - object to compare this one to.\n * @returns `true` if this `VerseRef` is equal to the supplied one, `false` otherwise.\n */\n equals(e) {\n return e instanceof i ? e._bookNum === this._bookNum && e._chapterNum === this._chapterNum && e._verseNum === this._verseNum && e.verse === this.verse && (e.versification == null && this.versification == null || e.versification != null && this.versification != null && e.versification.equals(this.versification)) : !1;\n }\n /**\n * Enumerate all individual verses contained in a VerseRef.\n * Verse ranges are indicated by \"-\" and consecutive verses by \",\"s.\n * Examples:\n * GEN 1:2 returns GEN 1:2\n * GEN 1:1a-3b,5 returns GEN 1:1a, GEN 1:2, GEN 1:3b, GEN 1:5\n * GEN 1:2a-2c returns //! ??????\n *\n * @param specifiedVersesOnly - if set to true return only verses that are\n * explicitly specified only, not verses within a range. Defaults to `false`.\n * @param verseRangeSeparators - Verse range separators.\n * Defaults to `VerseRef.verseRangeSeparators`.\n * @param verseSequenceSeparators - Verse sequence separators.\n * Defaults to `VerseRef.verseSequenceIndicators`.\n * @returns An array of all single verse references in this VerseRef.\n */\n allVerses(e = !1, s = i.verseRangeSeparators, r = i.verseSequenceIndicators) {\n if (this._verse == null || this.chapterNum <= 0)\n return [this.clone()];\n const a = [], o = E(this._verse, r);\n for (const u of o.map((f) => E(f, s))) {\n const f = this.clone();\n f.verse = u[0];\n const d = f.verseNum;\n if (a.push(f), u.length > 1) {\n const b = this.clone();\n if (b.verse = u[1], !e)\n for (let p = d + 1; p < b.verseNum; p++) {\n const J = new i(\n this._bookNum,\n this._chapterNum,\n p,\n this.versification\n );\n this.isExcluded || a.push(J);\n }\n a.push(b);\n }\n }\n return a;\n }\n /**\n * Validates a verse number using the supplied separators rather than the defaults.\n */\n validateVerse(e, s) {\n if (!this.verse)\n return this.internalValid;\n let r = 0;\n for (const a of this.allVerses(!0, e, s)) {\n const o = a.internalValid;\n if (o !== 0)\n return o;\n const u = a.BBBCCCVVV;\n if (r > u)\n return 3;\n if (r === u)\n return 4;\n r = u;\n }\n return 0;\n }\n /**\n * Gets whether a single verse reference is valid.\n */\n get internalValid() {\n return this.versification == null ? 1 : this._bookNum <= 0 || this._bookNum > m.lastBook ? 2 : (m.isCanonical(this._bookNum), 0);\n }\n setEmpty(e = i.defaultVersification) {\n this._bookNum = 0, this._chapterNum = -1, this._verse = void 0, this.versification = e;\n }\n updateInternal(e, s, r) {\n this.bookNum = m.bookIdToNumber(e), this.chapter = s, this.verse = r;\n }\n};\nn(i, \"defaultVersification\", c.English), n(i, \"verseRangeSeparator\", \"-\"), n(i, \"verseSequenceIndicator\", \",\"), n(i, \"verseRangeSeparators\", [i.verseRangeSeparator]), n(i, \"verseSequenceIndicators\", [i.verseSequenceIndicator]), n(i, \"chapterDigitShifter\", 1e3), n(i, \"bookDigitShifter\", i.chapterDigitShifter * i.chapterDigitShifter), n(i, \"bcvMaxValue\", i.chapterDigitShifter - 1), /**\n * The valid status of the VerseRef.\n */\nn(i, \"ValidStatusType\", D);\nlet M = i;\nclass v extends Error {\n}\nexport {\n _ as BookSet,\n m as Canon,\n c as ScrVers,\n l as ScrVersType,\n M as VerseRef,\n v as VerseRefException\n};\n//# sourceMappingURL=index.es.js.map\n","import React from 'react';\nimport * as DropdownMenuPrimitive from '@radix-ui/react-dropdown-menu';\nimport { Check, ChevronRight, Circle } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport const DropdownMenu = DropdownMenuPrimitive.Root;\n\nexport const DropdownMenuTrigger = DropdownMenuPrimitive.Trigger;\n\nexport const DropdownMenuGroup = DropdownMenuPrimitive.Group;\n\nexport const DropdownMenuPortal = DropdownMenuPrimitive.Portal;\n\nexport const DropdownMenuSub = DropdownMenuPrimitive.Sub;\n\nexport const DropdownMenuRadioGroup = DropdownMenuPrimitive.RadioGroup;\n\nexport type DropdownMenuSubTriggerProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.SubTrigger\n> & {\n className?: string;\n inset?: boolean;\n};\n\nexport type DropdownMenuSubContentProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.SubContent\n> & {\n className?: string;\n};\n\nexport type DropdownMenuContentProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Content\n> & {\n className?: string;\n sideOffset?: number;\n};\n\nexport type DropdownMenuItemProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Item\n> & {\n className?: string;\n inset?: boolean;\n};\n\nexport type DropdownMenuCheckboxItemProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.CheckboxItem\n> & {\n className?: string;\n checked?: boolean;\n};\n\nexport type DropdownMenuRadioItemProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.RadioItem\n> & {\n className?: string;\n};\n\nexport type DropdownMenuLabelProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Label\n> & {\n className?: string;\n inset?: boolean;\n};\n\nexport type DropdownMenuSeparatorProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Separator\n> & {\n className?: string;\n};\n\nexport type DropdownMenuShortcutProps = React.HTMLAttributes & {\n className?: string;\n};\n\nexport const DropdownMenuSubTrigger = React.forwardRef<\n React.ElementRef,\n DropdownMenuSubTriggerProps\n>(({ className, inset, children, ...props }, ref) => (\n \n {children}\n \n \n));\nDropdownMenuSubTrigger.displayName = DropdownMenuPrimitive.SubTrigger.displayName;\n\nexport const DropdownMenuSubContent = React.forwardRef<\n React.ElementRef,\n DropdownMenuSubContentProps\n>(({ className, ...props }, ref) => (\n \n));\nDropdownMenuSubContent.displayName = DropdownMenuPrimitive.SubContent.displayName;\n\nexport const DropdownMenuContent = React.forwardRef<\n React.ElementRef,\n DropdownMenuContentProps\n>(({ className, sideOffset = 4, ...props }, ref) => (\n \n \n \n));\nDropdownMenuContent.displayName = DropdownMenuPrimitive.Content.displayName;\n\n/**\n * TODO: fix: direction is not automatically handled by this component, so that shortcuts are\n * display always to the right\n */\nexport const DropdownMenuItem = React.forwardRef<\n React.ElementRef,\n DropdownMenuItemProps\n>(({ className, inset, ...props }, ref) => (\n \n));\nDropdownMenuItem.displayName = DropdownMenuPrimitive.Item.displayName;\n\nexport const DropdownMenuCheckboxItem = React.forwardRef<\n React.ElementRef,\n DropdownMenuCheckboxItemProps\n>(({ className, children, checked, ...props }, ref) => (\n \n \n \n \n \n \n {children}\n \n));\nDropdownMenuCheckboxItem.displayName = DropdownMenuPrimitive.CheckboxItem.displayName;\n\nexport const DropdownMenuRadioItem = React.forwardRef<\n React.ElementRef,\n DropdownMenuRadioItemProps\n>(({ className, children, ...props }, ref) => (\n \n \n \n \n \n \n {children}\n \n));\nDropdownMenuRadioItem.displayName = DropdownMenuPrimitive.RadioItem.displayName;\n\nexport const DropdownMenuLabel = React.forwardRef<\n React.ElementRef,\n DropdownMenuLabelProps\n>(({ className, inset, ...props }, ref) => (\n \n));\nDropdownMenuLabel.displayName = DropdownMenuPrimitive.Label.displayName;\n\nexport const DropdownMenuSeparator = React.forwardRef<\n React.ElementRef,\n DropdownMenuSeparatorProps\n>(({ className, ...props }, ref) => (\n \n));\nDropdownMenuSeparator.displayName = DropdownMenuPrimitive.Separator.displayName;\n\nexport function DropdownMenuShortcut({ className, ...props }: DropdownMenuShortcutProps) {\n return (\n \n );\n}\nDropdownMenuShortcut.displayName = 'DropdownMenuShortcut';\n","import { Canon } from '@sillsdev/scripture';\nimport { PropsWithChildren, KeyboardEvent, forwardRef } from 'react';\nimport { DropdownMenuItem as ShadDropdownMenuItem } from '@/components/shadcn-ui/dropdown-menu';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport type BookType = 'OT' | 'NT' | 'DC';\n\ntype BookMenuItemProps = PropsWithChildren<{\n /** String id of book */\n bookId: string;\n /** Callback to run when a book menu item is selected */\n handleSelectBook: () => void;\n /** Indicates if this menu item is currently selected */\n isSelected: boolean;\n /** Function that is called upon highlighting a book in the dropdown menu */\n handleHighlightBook: () => void;\n /**\n * Function that is called on pressing a key\n *\n * @param event Event that contains information about the key stroke\n */\n handleKeyDown: (event: KeyboardEvent) => void;\n /**\n * Type of book associated with this menu item, coordinates color labels ? Mock up has the labels\n * coordinated to genre\n */\n bookType: BookType;\n}>;\n\nconst BookMenuItem = forwardRef(\n (\n {\n bookId,\n handleSelectBook,\n isSelected,\n handleHighlightBook,\n handleKeyDown,\n bookType,\n children,\n }: BookMenuItemProps,\n ref,\n ) => {\n return (\n {\n // preventDefault() here prevents the entire dropdown menu from closing when selecting this item\n event.preventDefault();\n handleSelectBook();\n }}\n onKeyDown={(event: KeyboardEvent) => {\n handleKeyDown(event);\n }}\n onFocus={handleHighlightBook}\n onMouseMove={handleHighlightBook}\n >\n \n {Canon.bookIdToEnglishName(bookId)}\n \n {isSelected &&
    {children}
    }\n \n );\n },\n);\n\nexport default BookMenuItem;\n","import { cn } from '@/utils/shadcn-ui.util';\nimport { useCallback } from 'react';\n\nexport type ChapterSelectProps = {\n /**\n * Callback to run when a chapter div is selected\n *\n * @param chapterNumber Number of the chapter that has been selected\n */\n handleSelectChapter: (chapterNumber: number) => void;\n /** The highest chapter number in the book (of course equal to number of chapters in the book) */\n endChapter: number;\n /** The chapter number that is currently selected */\n activeChapter: number;\n /** The chapter number that is currently highlighted using keyboard or mouse navigation */\n highlightedChapter: number;\n /**\n * Callback to run when a chapter is highlighted by the user\n *\n * @param chapterNumber The chapter that is highlighted\n */\n handleHighlightedChapter: (chapterNumber: number) => void;\n};\n\nfunction ChapterSelect({\n handleSelectChapter,\n endChapter,\n activeChapter,\n highlightedChapter,\n handleHighlightedChapter,\n}: ChapterSelectProps) {\n const chapters = Array.from({ length: endChapter }, (_, i) => i + 1);\n\n const handleMouse = useCallback(\n (chapterNumber: number) => {\n handleHighlightedChapter(chapterNumber);\n },\n [handleHighlightedChapter],\n );\n\n return (\n
    \n {chapters.map((chapter) => (\n {\n event.preventDefault();\n event.stopPropagation();\n handleSelectChapter(chapter);\n }}\n role=\"button\"\n onKeyDown={(event) => {\n if (event.key === 'Enter') {\n handleSelectChapter(chapter);\n }\n }}\n tabIndex={0}\n onMouseMove={() => handleMouse(chapter)}\n >\n {chapter}\n
    \n ))}\n
    \n );\n}\n\nexport default ChapterSelect;\n","import { DropdownMenuLabel as ShadDropdownMenuLabel } from '@/components/shadcn-ui/dropdown-menu';\nimport { Bookmark, Clock, ArrowDownWideNarrow } from 'lucide-react';\n\nexport type GoToMenuItemProps = {\n handleSort: () => void;\n handleLocationHistory: () => void;\n handleBookmarks: () => void;\n};\n\nfunction GoToMenuItem({ handleSort, handleLocationHistory, handleBookmarks }: GoToMenuItemProps) {\n return (\n \n

    Go To

    \n
    \n \n \n \n
    \n
    \n );\n}\n\nexport default GoToMenuItem;\n","import BookChapterInput from '@/components/advanced/book-chapter-control/book-chapter-input.component';\nimport BookMenuItem, {\n BookType,\n} from '@/components/advanced/book-chapter-control/book-menu-item.component';\nimport ChapterSelect from '@/components/advanced/book-chapter-control/chapter-select.component';\nimport GoToMenuItem from '@/components/advanced/book-chapter-control/go-to-menu-item.component';\nimport {\n DropdownMenu as ShadDropdownMenu,\n DropdownMenuContent as ShadDropdownMenuContent,\n DropdownMenuLabel as ShadDropdownMenuLabel,\n DropdownMenuSeparator as ShadDropdownMenuSeparator,\n DropdownMenuTrigger as ShadDropdownMenuTrigger,\n} from '@/components/shadcn-ui/dropdown-menu';\nimport { Canon } from '@sillsdev/scripture';\nimport { ScriptureReference, getChaptersForBook } from 'platform-bible-utils';\nimport {\n KeyboardEvent as ReactKeyboardEvent,\n useCallback,\n useEffect,\n useLayoutEffect,\n useRef,\n useState,\n} from 'react';\n\ntype BookTypeLabels = {\n [bookType in BookType]: string;\n};\ntype BookChapterControlProps = {\n scrRef: ScriptureReference;\n handleSubmit: (scrRef: ScriptureReference) => void;\n};\n\nconst ALL_BOOK_IDS = Canon.allBookIds;\nconst BOOK_TYPE_LABELS: BookTypeLabels = {\n OT: 'Old Testament',\n NT: 'New Testament',\n DC: 'Deuterocanon',\n};\nconst BOOK_TYPE_ARRAY: BookType[] = ['OT', 'NT', 'DC'];\n// This is the height of three menu items to offset scrolling to the selected menu item\n// If you use menuItemRef.clientHeight- includes height of chapter div which is too big\nconst SCROLL_OFFSET = 32 + 32 + 32;\nconst SEARCH_QUERY_FORMATS = [\n /^(\\w+)$/i, // Matches a single word (book name or id)\n /^(\\w+)(?:\\s(\\d+))$/i, // Matches a word followed by a chapter number\n /^(\\w+)(?:\\s(\\d+):(\\d+))$/i, // Matches a word followed by a chapter and verse number\n];\nconst fetchGroupedBooks = (bookType: BookType) => {\n const groupedBooks = {\n OT: ALL_BOOK_IDS.filter((bookId) => Canon.isBookOT(bookId)),\n NT: ALL_BOOK_IDS.filter((bookId) => Canon.isBookNT(bookId)),\n DC: ALL_BOOK_IDS.filter((bookId) => Canon.isBookDC(bookId)),\n };\n return groupedBooks[bookType];\n};\nconst fetchEndChapter = (bookId: string) => {\n // getChaptersForBook returns -1 if not found in scrBookData\n // scrBookData only includes OT and NT, so all DC will return -1\n return getChaptersForBook(Canon.bookIdToNumber(bookId));\n};\n\n/**\n * Gets all of the English names from book ids\n *\n * @returns String[]\n */\nfunction getAllEnglishNames(): string[] {\n const allEnglishNames = ALL_BOOK_IDS.map((bookId) => {\n return Canon.bookIdToEnglishName(bookId);\n });\n return allEnglishNames;\n}\n\n/**\n * Determines if bookName is in allEnglishNames\n *\n * @param bookName Book English name\n * @returns True if bookName is included, false otherwise\n */\nfunction isValidBookEnglishName(bookName: string): boolean {\n return getAllEnglishNames().includes(bookName);\n}\n\n/**\n * Gets a bookId from given English name\n *\n * @param bookName Book English name\n * @returns BookId of provided bookName, undefined otherwise\n */\nfunction getBookIdFromEnglishName(bookName: string): string | undefined {\n // Convert bookName to lowercase and then capitalize the first letter\n const formattedBookName = bookName.toLowerCase().replace(/^\\w/, (c) => c.toUpperCase());\n\n if (isValidBookEnglishName(formattedBookName)) {\n const matchingBookId = ALL_BOOK_IDS.find((bookId) => {\n return Canon.bookIdToEnglishName(bookId) === formattedBookName;\n });\n return matchingBookId;\n }\n\n return undefined;\n}\n\nfunction BookChapterControl({ scrRef, handleSubmit }: BookChapterControlProps) {\n const [searchQuery, setSearchQuery] = useState('');\n const [selectedBookId, setSelectedBookId] = useState(\n Canon.bookNumberToId(scrRef.bookNum),\n );\n const [highlightedChapter, setHighlightedChapter] = useState(scrRef.chapterNum ?? 0);\n const [highlightedBookId, setHighlightedBookId] = useState(\n Canon.bookNumberToId(scrRef.bookNum),\n );\n const [isContentOpen, setIsContentOpen] = useState(false);\n const [isContentOpenDelayed, setIsContentOpenDelayed] = useState(isContentOpen);\n\n // This ref will always be defined\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const inputRef = useRef(undefined!);\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const contentRef = useRef(undefined!);\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const menuItemRef = useRef(undefined!);\n\n const fetchFilteredBooks = useCallback(\n (bookType: BookType) => {\n return fetchGroupedBooks(bookType).filter((bookId: string) => {\n const englishNameLowerCase = Canon.bookIdToEnglishName(bookId).toLowerCase();\n const normalizedQuery = searchQuery.replace(/[^a-zA-Z]/g, '').toLowerCase();\n return (\n englishNameLowerCase.includes(normalizedQuery) || // Match book name\n bookId.toLowerCase().includes(normalizedQuery) // Match book ID\n );\n });\n },\n [searchQuery],\n );\n\n const handleSearchInput = (searchString: string) => {\n setSearchQuery(searchString);\n };\n\n /**\n * Whether to prevent radix's logic from closing the dropdown. This is important because radix\n * tries to close the dropdown when the input first focuses, and we don't want it to do that. But\n * we don't want to prevent the dropdown from closing when we click away from the input, so we\n * don't want to just keep it open if the input is focused\n */\n const shouldPreventAutoClosing = useRef(false);\n\n const controlMenuState = useCallback((open: boolean) => {\n if (shouldPreventAutoClosing.current) {\n shouldPreventAutoClosing.current = false;\n return;\n }\n setIsContentOpen(open);\n }, []);\n\n const updateReference = useCallback(\n (bookId: string, shouldClose: boolean, chapter?: number, verse?: number) => {\n setHighlightedChapter(\n Canon.bookNumberToId(scrRef.bookNum) !== bookId ? 1 : scrRef.chapterNum,\n );\n\n if (shouldClose || fetchEndChapter(bookId) === -1) {\n handleSubmit({\n bookNum: Canon.bookIdToNumber(bookId),\n chapterNum: chapter || 1,\n verseNum: verse || 1,\n });\n\n setIsContentOpen(false);\n setSearchQuery('');\n return;\n }\n\n setSelectedBookId(selectedBookId !== bookId ? bookId : '');\n setIsContentOpen(!shouldClose);\n },\n [handleSubmit, scrRef.bookNum, scrRef.chapterNum, selectedBookId],\n );\n\n const handleSelectChapter = (chapterNumber: number) => {\n if (chapterNumber <= 0 || chapterNumber > fetchEndChapter(selectedBookId)) {\n return;\n }\n updateReference(selectedBookId, true, chapterNumber);\n };\n\n const handleInputSubmit = useCallback(() => {\n SEARCH_QUERY_FORMATS.forEach((format) => {\n const matches = searchQuery.match(format);\n if (matches) {\n // Book should be a bookId or an english name\n const [book, chapter = undefined, verse = undefined] = matches.slice(1);\n const englishName = getBookIdFromEnglishName(book);\n\n if (Canon.isBookIdValid(book) || englishName) {\n updateReference(\n englishName ?? book,\n true,\n chapter ? parseInt(chapter, 10) : 1,\n verse ? parseInt(verse, 10) : 1,\n );\n }\n }\n });\n }, [updateReference, searchQuery]);\n\n const handleKeyDownInput = useCallback(\n (event: ReactKeyboardEvent) => {\n if (!isContentOpen) {\n setIsContentOpen(true);\n } else if (event.key === 'ArrowDown' || event.key === 'ArrowUp') {\n if (\n typeof menuItemRef !== 'undefined' &&\n // Ref uses null\n // eslint-disable-next-line no-null/no-null\n menuItemRef.current !== null\n ) {\n menuItemRef.current.focus();\n } else if (\n typeof contentRef !== 'undefined' &&\n // Ref uses null\n // eslint-disable-next-line no-null/no-null\n contentRef.current !== null\n ) {\n contentRef.current.focus();\n }\n event.preventDefault();\n }\n },\n [isContentOpen],\n );\n\n const handleKeyDownContent = (event: ReactKeyboardEvent) => {\n // When the dropdown menu has focus, key strokes should give focus to the input component,\n // unless they're navigation keys (arrows and enter)\n const { key } = event;\n if (\n key === 'ArrowRight' ||\n key === 'ArrowLeft' ||\n key === 'ArrowDown' ||\n key === 'ArrowUp' ||\n key === 'Enter'\n ) {\n return;\n }\n\n inputRef.current.dispatchEvent(new KeyboardEvent('keydown', { key }));\n inputRef.current.focus();\n };\n\n const handleKeyDownMenuItem = (event: ReactKeyboardEvent) => {\n const { key } = event;\n if (highlightedBookId === selectedBookId) {\n if (key === 'Enter') {\n event.preventDefault();\n updateReference(selectedBookId, true, highlightedChapter);\n return;\n }\n\n let chapterOffSet = 0;\n if (key === 'ArrowRight') {\n if (highlightedChapter < fetchEndChapter(highlightedBookId)) {\n chapterOffSet = 1;\n } else {\n event.preventDefault();\n return;\n }\n } else if (key === 'ArrowLeft') {\n if (highlightedChapter > 1) {\n chapterOffSet = -1;\n } else {\n event.preventDefault();\n return;\n }\n } else if (key === 'ArrowDown') {\n chapterOffSet = 6;\n } else if (key === 'ArrowUp') {\n chapterOffSet = -6;\n }\n if (\n highlightedChapter + chapterOffSet <= 0 ||\n highlightedChapter + chapterOffSet > fetchEndChapter(highlightedBookId)\n ) {\n setHighlightedChapter(0);\n } else if (chapterOffSet !== 0) {\n setHighlightedChapter(highlightedChapter + chapterOffSet);\n event.preventDefault();\n }\n }\n };\n\n useEffect(() => {\n if (selectedBookId === highlightedBookId) {\n if (selectedBookId === Canon.bookNumberToId(scrRef.bookNum)) {\n setHighlightedChapter(scrRef.chapterNum);\n } else {\n setHighlightedChapter(1);\n }\n } else {\n setHighlightedChapter(0);\n }\n }, [highlightedBookId, scrRef.bookNum, scrRef.chapterNum, selectedBookId]);\n\n // The purpose of these useLayoutEffects and timeout is to delay the scroll just\n // enough so that the refs are defined and available when they are used after the timeout\n useLayoutEffect(() => {\n setIsContentOpenDelayed(isContentOpen);\n }, [isContentOpen]);\n\n useLayoutEffect(() => {\n const scrollTimeout = setTimeout(() => {\n if (isContentOpenDelayed && contentRef.current && menuItemRef.current) {\n const menuItemOffsetTop = menuItemRef.current.offsetTop;\n const scrollPosition = menuItemOffsetTop - SCROLL_OFFSET;\n contentRef.current.scrollTo({ top: scrollPosition, behavior: 'instant' });\n }\n }, 10);\n return () => {\n clearTimeout(scrollTimeout);\n };\n }, [isContentOpenDelayed]);\n\n return (\n
    \n \n \n {\n setSelectedBookId(Canon.bookNumberToId(scrRef.bookNum));\n setHighlightedBookId(Canon.bookNumberToId(scrRef.bookNum));\n setHighlightedChapter(scrRef.chapterNum > 0 ? scrRef.chapterNum : 0);\n setIsContentOpen(true);\n inputRef.current.focus();\n }}\n onFocus={() => {\n // Radix thinks we want to close because the input is being focused. Prevent that\n shouldPreventAutoClosing.current = true;\n }}\n handleSubmit={handleInputSubmit}\n placeholder={`${Canon.bookNumberToEnglishName(scrRef.bookNum)} ${scrRef.chapterNum}:${scrRef.verseNum}`}\n />\n \n \n console.log('sorting')}\n handleLocationHistory={() => console.log('location history')}\n handleBookmarks={() => console.log('bookmarks')}\n />\n {BOOK_TYPE_ARRAY.map(\n (bookType, bookTypeIndex) =>\n fetchFilteredBooks(bookType).length > 0 && (\n
    \n \n {BOOK_TYPE_LABELS[bookType]}\n \n\n {fetchFilteredBooks(bookType).map((bookId) => (\n
    \n updateReference(bookId, false)}\n isSelected={selectedBookId === bookId}\n handleHighlightBook={() => setHighlightedBookId(bookId)}\n handleKeyDown={handleKeyDownMenuItem}\n bookType={bookType}\n ref={(element: HTMLDivElement) => {\n if (selectedBookId === bookId) menuItemRef.current = element;\n }}\n >\n {\n setHighlightedChapter(chapterNumber);\n }}\n />\n \n
    \n ))}\n {BOOK_TYPE_ARRAY.length - 1 !== bookTypeIndex ? (\n \n ) : undefined}\n
    \n ),\n )}\n \n
    \n
    \n );\n}\n\nexport default BookChapterControl;\n","import React from 'react';\nimport { Slot } from '@radix-ui/react-slot';\nimport { cva, type VariantProps } from 'class-variance-authority';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport const buttonVariants = cva(\n 'pr-twp tw-inline-flex tw-items-center tw-justify-center tw-whitespace-nowrap tw-rounded-md tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-colors focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50',\n {\n variants: {\n variant: {\n default: 'tw-bg-primary tw-text-primary-foreground hover:tw-bg-primary/90',\n destructive: 'tw-bg-destructive tw-text-destructive-foreground hover:tw-bg-destructive/90',\n outline:\n 'tw-border tw-border-input tw-bg-background hover:tw-bg-accent hover:tw-text-accent-foreground',\n secondary: 'tw-bg-secondary tw-text-secondary-foreground hover:tw-bg-secondary/80',\n ghost: 'hover:tw-bg-accent hover:tw-text-accent-foreground',\n link: 'tw-text-primary tw-underline-offset-4 hover:tw-underline',\n },\n size: {\n default: 'tw-h-10 tw-px-4 tw-py-2',\n sm: 'tw-h-9 tw-rounded-md tw-px-3',\n lg: 'tw-h-11 tw-rounded-md tw-px-8',\n icon: 'tw-h-10 tw-w-10',\n },\n },\n defaultVariants: {\n variant: 'default',\n size: 'default',\n },\n },\n);\n\nexport interface ButtonProps\n extends React.ButtonHTMLAttributes,\n VariantProps {\n asChild?: boolean;\n}\n\nexport const Button = React.forwardRef(\n ({ className, variant, size, asChild = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'button';\n return (\n \n );\n },\n);\nButton.displayName = 'Button';\n","import React from 'react';\nimport * as LabelPrimitive from '@radix-ui/react-label';\nimport { cva, type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst labelVariants = cva(\n 'tw-text-sm tw-font-medium tw-leading-none peer-disabled:tw-cursor-not-allowed peer-disabled:tw-opacity-70',\n);\n\nexport const Label = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef & VariantProps\n>(({ className, ...props }, ref) => (\n \n));\nLabel.displayName = LabelPrimitive.Root.displayName;\n","import React from 'react';\nimport * as RadioGroupPrimitive from '@radix-ui/react-radio-group';\nimport { Circle } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst RadioGroup = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => {\n return (\n \n );\n});\nRadioGroup.displayName = RadioGroupPrimitive.Root.displayName;\n\nconst RadioGroupItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => {\n return (\n \n \n \n \n \n );\n});\nRadioGroupItem.displayName = RadioGroupPrimitive.Item.displayName;\n\nexport { RadioGroup, RadioGroupItem };\n","import React from 'react';\nimport * as PopoverPrimitive from '@radix-ui/react-popover';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Popover = PopoverPrimitive.Root;\n\nconst PopoverTrigger = PopoverPrimitive.Trigger;\n\nconst PopoverContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, align = 'center', sideOffset = 4, ...props }, ref) => (\n \n \n \n));\nPopoverContent.displayName = PopoverPrimitive.Content.displayName;\n\nexport { Popover, PopoverTrigger, PopoverContent };\n","import React from 'react';\nimport * as DialogPrimitive from '@radix-ui/react-dialog';\nimport { X } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Dialog = DialogPrimitive.Root;\n\nconst DialogTrigger = DialogPrimitive.Trigger;\n\nconst DialogPortal = DialogPrimitive.Portal;\n\nconst DialogClose = DialogPrimitive.Close;\n\nconst DialogOverlay = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nDialogOverlay.displayName = DialogPrimitive.Overlay.displayName;\n\nconst DialogContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, ...props }, ref) => (\n \n \n \n {children}\n \n \n Close\n \n \n \n));\nDialogContent.displayName = DialogPrimitive.Content.displayName;\n\nfunction DialogHeader({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nDialogHeader.displayName = 'DialogHeader';\n\nfunction DialogFooter({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nDialogFooter.displayName = 'DialogFooter';\n\nconst DialogTitle = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nDialogTitle.displayName = DialogPrimitive.Title.displayName;\n\nconst DialogDescription = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nDialogDescription.displayName = DialogPrimitive.Description.displayName;\n\nexport {\n Dialog,\n DialogPortal,\n DialogOverlay,\n DialogClose,\n DialogTrigger,\n DialogContent,\n DialogHeader,\n DialogFooter,\n DialogTitle,\n DialogDescription,\n};\n","import React from 'react';\nimport { type DialogProps } from '@radix-ui/react-dialog';\nimport { Command as CommandPrimitive } from 'cmdk';\nimport { Search } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Dialog, DialogContent } from '@/components/shadcn-ui/dialog';\n\nconst Command = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nCommand.displayName = CommandPrimitive.displayName;\n\ninterface CommandDialogProps extends DialogProps {}\n\nfunction CommandDialog({ children, ...props }: CommandDialogProps) {\n return (\n \n \n \n {children}\n \n \n \n );\n}\n\nconst CommandInput = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n
    \n \n \n
    \n));\n\nCommandInput.displayName = CommandPrimitive.Input.displayName;\n\nconst CommandList = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\n\nCommandList.displayName = CommandPrimitive.List.displayName;\n\nconst CommandEmpty = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>((props, ref) => (\n \n));\n\nCommandEmpty.displayName = CommandPrimitive.Empty.displayName;\n\nconst CommandGroup = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\n\nCommandGroup.displayName = CommandPrimitive.Group.displayName;\n\nconst CommandSeparator = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nCommandSeparator.displayName = CommandPrimitive.Separator.displayName;\n\nconst CommandItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\n\nCommandItem.displayName = CommandPrimitive.Item.displayName;\n\nfunction CommandShortcut({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nCommandShortcut.displayName = 'CommandShortcut';\n\nexport {\n Command,\n CommandDialog,\n CommandInput,\n CommandList,\n CommandEmpty,\n CommandGroup,\n CommandItem,\n CommandShortcut,\n CommandSeparator,\n};\n","import { useState } from 'react';\nimport { Check, ChevronsUpDown } from 'lucide-react';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport { Popover, PopoverContent, PopoverTrigger } from '@/components/shadcn-ui/popover';\nimport {\n Command,\n CommandEmpty,\n CommandInput,\n CommandItem,\n CommandList,\n} from '@/components/shadcn-ui/command';\nimport { PopoverProps } from '@radix-ui/react-popover';\n\nexport type ComboBoxLabelOption = { label: string };\nexport type ComboBoxOption = string | number | ComboBoxLabelOption;\n\nexport type ComboBoxProps = {\n /** Optional unique identifier */\n id?: string;\n /** Text label title for combobox */\n /** List of available options for the dropdown menu */\n options?: readonly T[];\n /** Additional css classes to help with unique styling of the combo box button */\n buttonClassName?: string;\n /** Additional css classes to help with unique styling of the combo box popover */\n popoverContentClassName?: string;\n /**\n * The selected value that the combo box currently holds. Must be shallow equal to one of the\n * options entries.\n */\n value?: T;\n /** Triggers when content of textfield is changed */\n onChange?: (newValue: T) => void;\n /** Used to determine the string value for a given option. */\n getOptionLabel?: (option: ComboBoxOption) => string;\n /** Text displayed on button if `value` is undefined */\n buttonPlaceholder?: string;\n /** Placeholder text for text field */\n textPlaceholder?: string;\n /** Text to display when no options match input */\n commandEmptyMessage?: string;\n /** Variant of button */\n buttonVariant?: ButtonProps['variant'];\n /** Text direction ltr or rtl */\n dir?: Direction;\n /** Optional boolean to set if trigger should be disabled */\n isDisabled?: boolean;\n} & PopoverProps;\n\ntype Direction = 'ltr' | 'rtl';\n\nfunction getOptionLabelDefault(option: ComboBoxOption): string {\n if (typeof option === 'string') {\n return option;\n }\n if (typeof option === 'number') {\n return option.toString();\n }\n return option.label;\n}\n\n/**\n * Autocomplete input and command palette with a list of suggestions.\n *\n * Thanks to Shadcn for heavy inspiration and documentation\n * https://ui.shadcn.com/docs/components/combobox\n */\nfunction ComboBox({\n id,\n options = [],\n buttonClassName,\n popoverContentClassName,\n value,\n onChange = () => {},\n getOptionLabel = getOptionLabelDefault,\n buttonPlaceholder = '',\n textPlaceholder = '',\n commandEmptyMessage = 'No option found',\n buttonVariant = 'outline',\n dir = 'ltr',\n isDisabled = false,\n ...props\n}: ComboBoxProps) {\n const [open, setOpen] = useState(false);\n\n return (\n \n \n \n \n {value ? getOptionLabel(value) : buttonPlaceholder}\n \n \n \n \n \n \n \n {commandEmptyMessage}\n \n {options.map((option) => (\n {\n onChange(option);\n setOpen(false);\n }}\n >\n \n {getOptionLabel(option)}\n \n ))}\n \n \n \n \n );\n}\n\nexport default ComboBox;\n","import { useMemo } from 'react';\nimport ComboBox from '@/components/basics/combo-box.component';\nimport { Label } from '@/components/shadcn-ui/label';\n\nexport type ChapterRangeSelectorProps = {\n startChapter: number;\n endChapter: number;\n handleSelectStartChapter: (chapter: number) => void;\n handleSelectEndChapter: (chapter: number) => void;\n isDisabled?: boolean;\n chapterCount: number;\n};\n\nexport default function ChapterRangeSelector({\n startChapter,\n endChapter,\n handleSelectStartChapter,\n handleSelectEndChapter,\n isDisabled = false,\n chapterCount,\n}: ChapterRangeSelectorProps) {\n const chapterOptions = useMemo(\n () => Array.from({ length: chapterCount }, (_, index) => index + 1),\n [chapterCount],\n );\n\n const onChangeStartChapter = (value: number) => {\n handleSelectStartChapter(value);\n if (value > endChapter) {\n handleSelectEndChapter(value);\n }\n };\n\n const onChangeEndChapter = (value: number) => {\n handleSelectEndChapter(value);\n if (value < startChapter) {\n handleSelectStartChapter(value);\n }\n };\n\n return (\n <>\n \n option.toString()}\n value={startChapter}\n />\n\n \n option.toString()}\n value={endChapter}\n />\n \n );\n}\n","import { Button } from '@/components/shadcn-ui/button';\nimport { Label } from '@/components/shadcn-ui/label';\nimport { RadioGroup, RadioGroupItem } from '@/components/shadcn-ui/radio-group';\nimport { Canon } from '@sillsdev/scripture';\nimport { LocalizedStringValue } from 'platform-bible-utils';\nimport { useState } from 'react';\nimport ChapterRangeSelector, {\n ChapterRangeSelectorProps,\n} from '../basics/chapter-range-selector.component';\n\nexport enum BookSelectionMode {\n CURRENT_BOOK = 'current book',\n CHOOSE_BOOKS = 'choose books',\n}\n\n/**\n * Object containing all keys used for localization in this component. If you're using this\n * component in an extension, you can pass it into the useLocalizedStrings hook to easily obtain the\n * localized strings and pass them into the localizedStrings prop of this component\n */\nexport const BOOK_SELECTOR_STRING_KEYS = Object.freeze([\n '%webView_bookSelector_currentBook%',\n '%webView_bookSelector_choose%',\n '%webView_bookSelector_chooseBooks%',\n] as const);\n\nexport type BookSelectorLocalizedStrings = {\n [localizedInventoryKey in (typeof BOOK_SELECTOR_STRING_KEYS)[number]]?: LocalizedStringValue;\n};\n\n/**\n * Gets the localized value for the provided key\n *\n * @param strings Object containing localized string\n * @param key Key for a localized string\n * @returns The localized value for the provided key, if available. Returns the key if no localized\n * value is available\n */\nconst localizeString = (\n strings: BookSelectorLocalizedStrings,\n key: keyof BookSelectorLocalizedStrings,\n) => {\n return strings[key] ?? key;\n};\n\ntype BookSelectorProps = ChapterRangeSelectorProps & {\n handleBookSelectionModeChange: (newMode: BookSelectionMode) => void;\n currentBookName: string;\n onSelectBooks: () => void;\n selectedBookIds: string[];\n localizedStrings: BookSelectorLocalizedStrings;\n};\n\nexport default function BookSelector({\n handleBookSelectionModeChange,\n currentBookName,\n onSelectBooks,\n selectedBookIds,\n chapterCount,\n endChapter,\n handleSelectEndChapter,\n startChapter,\n handleSelectStartChapter,\n localizedStrings,\n}: BookSelectorProps) {\n const currentBookText = localizeString(localizedStrings, '%webView_bookSelector_currentBook%');\n const chooseText = localizeString(localizedStrings, '%webView_bookSelector_choose%');\n const chooseBooksText = localizeString(localizedStrings, '%webView_bookSelector_chooseBooks%');\n\n const [bookSelectionMode, setBookSelectionMode] = useState(\n BookSelectionMode.CURRENT_BOOK,\n );\n\n const onSelectionModeChange = (newMode: BookSelectionMode) => {\n setBookSelectionMode(newMode);\n handleBookSelectionModeChange(newMode);\n };\n\n return (\n onSelectionModeChange(value as BookSelectionMode)}\n >\n
    \n
    \n
    \n \n \n
    \n \n
    \n \n
    \n
    \n
    \n
    \n \n \n
    \n \n onSelectBooks()}\n >\n {chooseText}\n \n
    \n
    \n \n );\n}\n","import { DropdownMenuTrigger } from '@radix-ui/react-dropdown-menu';\nimport { FilterIcon } from 'lucide-react';\nimport { Table } from '@tanstack/react-table';\n\nimport { Button } from '@/components/shadcn-ui/button';\nimport {\n DropdownMenu,\n DropdownMenuCheckboxItem,\n DropdownMenuContent,\n DropdownMenuLabel,\n DropdownMenuSeparator,\n} from '@/components/shadcn-ui/dropdown-menu';\n\ninterface DataTableViewOptionsProps {\n table: Table;\n}\n\nfunction DataTableViewOptions({ table }: DataTableViewOptionsProps) {\n return (\n \n \n \n \n \n Toggle columns\n \n {table\n .getAllColumns()\n .filter((column) => column.getCanHide())\n .map((column) => {\n return (\n column.toggleVisibility(!!value)}\n >\n {column.id}\n \n );\n })}\n \n \n );\n}\n\nexport default DataTableViewOptions;\n","import React from 'react';\nimport * as SelectPrimitive from '@radix-ui/react-select';\nimport { Check, ChevronDown, ChevronUp } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Select = SelectPrimitive.Root;\n\nconst SelectGroup = SelectPrimitive.Group;\n\nconst SelectValue = SelectPrimitive.Value;\n\nconst SelectTrigger = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, ...props }, ref) => (\n span]:tw-line-clamp-1',\n className,\n )}\n {...props}\n >\n {children}\n \n \n \n \n));\nSelectTrigger.displayName = SelectPrimitive.Trigger.displayName;\n\nconst SelectScrollUpButton = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n));\nSelectScrollUpButton.displayName = SelectPrimitive.ScrollUpButton.displayName;\n\nconst SelectScrollDownButton = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n));\nSelectScrollDownButton.displayName = SelectPrimitive.ScrollDownButton.displayName;\n\nconst SelectContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, position = 'popper', ...props }, ref) => (\n \n \n \n \n {children}\n \n \n \n \n));\nSelectContent.displayName = SelectPrimitive.Content.displayName;\n\nconst SelectLabel = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSelectLabel.displayName = SelectPrimitive.Label.displayName;\n\nconst SelectItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, ...props }, ref) => (\n \n \n \n \n \n \n\n {children}\n \n));\nSelectItem.displayName = SelectPrimitive.Item.displayName;\n\nconst SelectSeparator = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSelectSeparator.displayName = SelectPrimitive.Separator.displayName;\n\nexport {\n Select,\n SelectGroup,\n SelectValue,\n SelectTrigger,\n SelectContent,\n SelectLabel,\n SelectItem,\n SelectSeparator,\n SelectScrollUpButton,\n SelectScrollDownButton,\n};\n","import { ChevronLeftIcon, ChevronRightIcon, ArrowLeftIcon, ArrowRightIcon } from 'lucide-react';\nimport { Table } from '@tanstack/react-table';\n\nimport { Button } from '@/components/shadcn-ui/button';\nimport {\n Select,\n SelectContent,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\n\ninterface DataTablePaginationProps {\n table: Table;\n}\n\nfunction DataTablePagination({ table }: DataTablePaginationProps) {\n return (\n
    \n
    \n
    \n {table.getFilteredSelectedRowModel().rows.length} of{' '}\n {table.getFilteredRowModel().rows.length} row(s) selected\n
    \n
    \n

    Rows per page

    \n {\n table.setPageSize(Number(value));\n }}\n >\n \n \n \n \n {[10, 20, 30, 40, 50].map((pageSize) => (\n \n {pageSize}\n \n ))}\n \n \n
    \n
    \n Page {table.getState().pagination.pageIndex + 1} of {table.getPageCount()}\n
    \n
    \n table.setPageIndex(0)}\n disabled={!table.getCanPreviousPage()}\n >\n Go to first page\n \n \n table.previousPage()}\n disabled={!table.getCanPreviousPage()}\n >\n Go to previous page\n \n \n table.nextPage()}\n disabled={!table.getCanNextPage()}\n >\n Go to next page\n \n \n table.setPageIndex(table.getPageCount() - 1)}\n disabled={!table.getCanNextPage()}\n >\n Go to last page\n \n \n
    \n
    \n
    \n );\n}\n\nexport default DataTablePagination;\n","import React from 'react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Table = React.forwardRef<\n HTMLTableElement,\n React.HTMLAttributes & { stickyHeader?: boolean }\n>(({ className, stickyHeader, ...props }, ref) => (\n
    \n \n
    \n));\nTable.displayName = 'Table';\n\nconst TableHeader = React.forwardRef<\n HTMLTableSectionElement,\n React.HTMLAttributes & { stickyHeader?: boolean }\n>(({ className, stickyHeader, ...props }, ref) => (\n \n));\nTableHeader.displayName = 'TableHeader';\n\nconst TableBody = React.forwardRef<\n HTMLTableSectionElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableBody.displayName = 'TableBody';\n\nconst TableFooter = React.forwardRef<\n HTMLTableSectionElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n tr]:last:tw-border-b-0', className)}\n {...props}\n />\n));\nTableFooter.displayName = 'TableFooter';\n\nconst TableRow = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nTableRow.displayName = 'TableRow';\n\nconst TableHead = React.forwardRef<\n HTMLTableCellElement,\n React.ThHTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableHead.displayName = 'TableHead';\n\nconst TableCell = React.forwardRef<\n HTMLTableCellElement,\n React.TdHTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableCell.displayName = 'TableCell';\n\nconst TableCaption = React.forwardRef<\n HTMLTableCaptionElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableCaption.displayName = 'TableCaption';\n\nexport { Table, TableHeader, TableBody, TableFooter, TableHead, TableRow, TableCell, TableCaption };\n","import { useState } from 'react';\n\nimport {\n ColumnFiltersState,\n flexRender,\n getCoreRowModel,\n getFilteredRowModel,\n getPaginationRowModel,\n getSortedRowModel,\n SortingState,\n ColumnDef as TSColumnDef,\n Row as TSRow,\n RowSelectionState as TSRowSelectionState,\n SortDirection as TSSortDirection,\n Table as TSTable,\n useReactTable,\n VisibilityState,\n} from '@tanstack/react-table';\n\nimport DataTableViewOptions from '@/components/advanced/data-table/data-table-column-toggle.component';\nimport DataTablePagination from '@/components/advanced/data-table/data-table-pagination.component';\nimport { Button } from '@/components/shadcn-ui/button';\nimport {\n Table,\n TableBody,\n TableCell,\n TableHead,\n TableHeader,\n TableRow,\n} from '@/components/shadcn-ui/table';\n\nexport type ColumnDef = TSColumnDef;\nexport type RowContents = TSRow;\nexport type TableContents = TSTable;\nexport type SortDirection = TSSortDirection;\nexport type RowSelectionState = TSRowSelectionState;\n\ninterface DataTableProps {\n columns: ColumnDef[];\n data: TData[];\n enablePagination?: boolean;\n showPaginationControls?: boolean;\n showColumnVisibilityControls?: boolean;\n stickyHeader?: boolean;\n onRowClickHandler?: (row: RowContents, table: TableContents) => void;\n}\n\n/**\n * Feature-rich table component that infuses our basic shadcn-based Table component with features\n * from TanStack's React Table library\n */\nfunction DataTable({\n columns,\n data,\n enablePagination = false,\n showPaginationControls = false,\n showColumnVisibilityControls = false,\n stickyHeader = false,\n onRowClickHandler = () => {},\n}: DataTableProps) {\n const [sorting, setSorting] = useState([]);\n const [columnFilters, setColumnFilters] = useState([]);\n const [columnVisibility, setColumnVisibility] = useState({});\n const [rowSelection, setRowSelection] = useState({});\n\n const table = useReactTable({\n data,\n columns,\n getCoreRowModel: getCoreRowModel(),\n ...(enablePagination && { getPaginationRowModel: getPaginationRowModel() }),\n onSortingChange: setSorting,\n getSortedRowModel: getSortedRowModel(),\n onColumnFiltersChange: setColumnFilters,\n getFilteredRowModel: getFilteredRowModel(),\n onColumnVisibilityChange: setColumnVisibility,\n onRowSelectionChange: setRowSelection,\n state: {\n sorting,\n columnFilters,\n columnVisibility,\n rowSelection,\n },\n });\n\n return (\n
    \n {showColumnVisibilityControls && }\n \n \n {table.getHeaderGroups().map((headerGroup) => (\n \n {headerGroup.headers.map((header) => {\n return (\n \n {header.isPlaceholder\n ? undefined\n : flexRender(header.column.columnDef.header, header.getContext())}\n \n );\n })}\n \n ))}\n \n \n {table.getRowModel().rows?.length ? (\n table.getRowModel().rows.map((row) => (\n onRowClickHandler(row, table)}\n key={row.id}\n data-state={row.getIsSelected() && 'selected'}\n >\n {row.getVisibleCells().map((cell) => (\n \n {flexRender(cell.column.columnDef.cell, cell.getContext())}\n \n ))}\n \n ))\n ) : (\n \n \n No results.\n \n \n )}\n \n
    \n {enablePagination && (\n
    \n table.previousPage()}\n disabled={!table.getCanPreviousPage()}\n >\n Previous\n \n table.nextPage()}\n disabled={!table.getCanNextPage()}\n >\n Next\n \n
    \n )}\n {enablePagination && showPaginationControls && }\n
    \n );\n}\n\nexport default DataTable;\n","import {\n Table,\n TableBody,\n TableCell,\n TableHead,\n TableHeader,\n TableRow,\n} from '@/components/shadcn-ui/table';\nimport { Canon } from '@sillsdev/scripture';\nimport { deepEqual, LanguageStrings, ScriptureReference } from 'platform-bible-utils';\nimport { useMemo } from 'react';\nimport { InventoryItemOccurrence } from './inventory-utils';\n\n/** Props for the OccurrencesTable component */\ntype OccurrencesTableProps = {\n /** Data that contains scriptures references and snippets of scripture */\n occurrenceData: InventoryItemOccurrence[];\n /** Callback function that is executed when the scripture reference is changed */\n setScriptureReference: (scriptureReference: ScriptureReference) => void;\n /**\n * Object with all localized strings that the OccurrencesTable needs to work well across multiple\n * languages\n */\n localizedStrings: LanguageStrings;\n};\n\n/**\n * Table that shows occurrences of specified inventory item(s). The first column shows the related\n * scripture reference. The second column shows the snippet of scripture that contains the specified\n * inventory item\n */\nfunction OccurrencesTable({\n occurrenceData,\n setScriptureReference,\n localizedStrings,\n}: OccurrencesTableProps) {\n const referenceHeaderText =\n localizedStrings['%webView_inventory_occurrences_table_header_reference%'];\n const occurrenceHeaderText =\n localizedStrings['%webView_inventory_occurrences_table_header_occurrence%'];\n\n const occurrences: InventoryItemOccurrence[] = useMemo(() => {\n const uniqueOccurrences: InventoryItemOccurrence[] = [];\n\n occurrenceData.forEach((occurrence) => {\n if (!uniqueOccurrences.some((uniqueOccurrence) => deepEqual(uniqueOccurrence, occurrence))) {\n uniqueOccurrences.push(occurrence);\n }\n });\n\n return uniqueOccurrences;\n }, [occurrenceData]);\n\n return (\n \n \n \n {referenceHeaderText}\n {occurrenceHeaderText}\n \n \n \n {occurrences.length > 0 &&\n occurrences.map((occurrence) => (\n {\n setScriptureReference(occurrence.reference);\n }}\n >\n {`${Canon.bookNumberToEnglishName(occurrence.reference.bookNum)} ${occurrence.reference.chapterNum}:${occurrence.reference.verseNum}`}\n {occurrence.text}\n \n ))}\n \n
    \n );\n}\n\nexport default OccurrencesTable;\n","import React from 'react';\nimport * as CheckboxPrimitive from '@radix-ui/react-checkbox';\nimport { Check } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Checkbox = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n \n \n));\nCheckbox.displayName = CheckboxPrimitive.Root.displayName;\n\nexport default Checkbox;\n","import { Canon } from '@sillsdev/scripture';\nimport { ScriptureReference } from 'platform-bible-utils';\n\n/* #region Types */\n\n/**\n * Status of items that appear in inventories. 'approved' and 'unapproved' items are defined in the\n * project's `Settings.xml`. All other items are defined as 'unknown'\n */\nexport type Status = 'approved' | 'unapproved' | 'unknown';\n\n/** Occurrence of item in inventory. Primarily used by table that shows occurrences */\nexport type InventoryItemOccurrence = {\n /** Reference to scripture where the item appears */\n reference: ScriptureReference;\n /** Snippet of scripture that contains the occurrence */\n text: string;\n};\n\n/** Data structure that contains all information on an item that is shown in an inventory */\nexport type InventoryTableData = {\n /**\n * The item (e.g. a character in the characters inventory, a marker in the marker inventory) In\n * most cases the array will only have one element. In case of additional items (e.g. the\n * preceding marker in the markers check), the primary item should be stored in the first index.\n * To show additional items in the inventory, make sure to configure the `additionalItemsLabels`\n * prop for the Inventory component\n */\n items: string[];\n /** The number of times this item occurs in the selected scope */\n count: number;\n /** The status of this item (see documentation for `Status` type for more information) */\n status: Status;\n /** Occurrences of this item in the scripture text for the selected scope */\n occurrences: InventoryItemOccurrence[];\n};\n\n/* #endregion */\n\n/* #region Functions */\n\n/**\n * Splits USFM string into shorter line-like segments\n *\n * @param text A single (likely very large) USFM string\n * @returns An array containing the input text, split into shorter segments\n */\nexport const getLinesFromUSFM = (text: string) => {\n // Splits on (CR)LF, CR, \\v, \\c and \\id\n return text.split(/(?:\\r?\\n|\\r)|(?=(?:\\\\(?:v|c|id)))/g);\n};\n\n/**\n * Extracts chapter or verse number from USFM strings that start with a \\c or \\v marker\n *\n * @param text USFM string that is expected to start with \\c or \\v marker\n * @returns Chapter or verse number if one is found. Else returns 0.\n */\nexport const getNumberFromUSFM = (text: string): number | undefined => {\n // Captures all digits that follow \\v or \\c markers followed by whitespace located at the start of a string\n const regex = /^\\\\[vc]\\s+(\\d+)/;\n const match = text.match(regex);\n\n if (match) {\n return +match[1];\n }\n return undefined;\n};\n\n/**\n * Gets book ID from USFM string that starts with the \\id marker, and returns book number for it\n *\n * @param text USFM string that is expected to start with \\id marker\n * @returns Book number corresponding to the \\id marker in the input text. Returns 0 if no marker is\n * found or the marker is not valid\n */\nexport const getBookNumFromId = (text: string): number => {\n // Captures all digits that follow an \\id marker followed by whitespace located at the start of a string\n const match = text.match(/^\\\\id\\s+([A-Za-z]+)/);\n if (match) {\n return Canon.bookIdToNumber(match[1]);\n }\n return 0;\n};\n\n/**\n * Gets the status for an item, typically used in the Inventory component\n *\n * @param item The item for which the status is being requested\n * @param approvedItems Array of approved items, typically as defined in `Settings.xml`\n * @param unapprovedItems Array of unapproved items, typically as defined in `Settings.xml`\n * @returns The status for the specified item\n */\nexport const getStatusForItem = (\n item: string,\n approvedItems: string[],\n unapprovedItems: string[],\n): Status => {\n if (unapprovedItems.includes(item)) return 'unapproved';\n if (approvedItems.includes(item)) return 'approved';\n return 'unknown';\n};\n\n/* #endregion */\n","import React from 'react';\nimport * as TogglePrimitive from '@radix-ui/react-toggle';\nimport { cva, type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst toggleVariants = cva(\n 'pr-twp tw-inline-flex tw-items-center tw-justify-center tw-rounded-md tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-colors hover:tw-bg-muted hover:tw-text-muted-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50 data-[state=on]:tw-bg-accent data-[state=on]:tw-text-accent-foreground',\n {\n variants: {\n variant: {\n default: 'tw-bg-transparent',\n outline:\n 'tw-border tw-border-input tw-bg-transparent hover:tw-bg-accent hover:tw-text-accent-foreground',\n },\n size: {\n default: 'tw-h-10 tw-px-3',\n sm: 'tw-h-9 tw-px-2.5',\n lg: 'tw-h-11 tw-px-5',\n },\n },\n defaultVariants: {\n variant: 'default',\n size: 'default',\n },\n },\n);\n\nconst Toggle = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef & VariantProps\n>(({ className, variant, size, ...props }, ref) => (\n \n));\n\nToggle.displayName = TogglePrimitive.Root.displayName;\n\nexport { Toggle, toggleVariants };\n","import React from 'react';\nimport * as ToggleGroupPrimitive from '@radix-ui/react-toggle-group';\nimport { type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { toggleVariants } from '@/components/shadcn-ui/toggle';\n\nconst ToggleGroupContext = React.createContext>({\n size: 'default',\n variant: 'default',\n});\n\nconst ToggleGroup = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef &\n VariantProps\n>(({ className, variant, size, children, ...props }, ref) => (\n \n \n {children}\n \n \n));\n\nToggleGroup.displayName = ToggleGroupPrimitive.Root.displayName;\n\nconst ToggleGroupItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef &\n VariantProps\n>(({ className, children, variant, size, ...props }, ref) => {\n const context = React.useContext(ToggleGroupContext);\n\n return (\n \n {children}\n \n );\n});\n\nToggleGroupItem.displayName = ToggleGroupPrimitive.Item.displayName;\n\nexport { ToggleGroup, ToggleGroupItem };\n","import { ColumnDef, SortDirection } from '@/components/advanced/data-table/data-table.component';\nimport { Button } from '@/components/shadcn-ui/button';\nimport { ToggleGroup, ToggleGroupItem } from '@/components/shadcn-ui/toggle-group';\nimport {\n ArrowDownIcon,\n ArrowUpDownIcon,\n ArrowUpIcon,\n CircleCheckIcon,\n CircleHelpIcon,\n CircleXIcon,\n} from 'lucide-react';\nimport { ReactNode } from 'react';\nimport { InventoryTableData, Status } from './inventory-utils';\n\n/**\n * Gets an icon that indicates the current sorting direction based on the provided input\n *\n * @param sortDirection Sorting direction. Can be ascending ('asc'), descending ('desc') or false (\n * i.e. not sorted)\n * @returns The appropriate sorting icon for the provided sorting direction\n */\nconst getSortingIcon = (sortDirection: false | SortDirection): ReactNode => {\n if (sortDirection === 'asc') {\n return ;\n }\n if (sortDirection === 'desc') {\n return ;\n }\n return ;\n};\n\n/**\n * Function that creates the item column for inventories\n *\n * @param itemLabel Localized label for the item column (e.g. 'Character', 'Repeated Word', etc.)\n * @returns Column that shows the inventory items. Should be used with the DataTable component\n */\nexport const inventoryItemColumn = (itemLabel: string): ColumnDef => {\n return {\n accessorKey: 'item',\n accessorFn: (row: InventoryTableData) => row.items[0],\n header: ({ column }) => (\n \n ),\n };\n};\n\n/**\n * Function that creates the additional item columns for inventories\n *\n * @param additionalItemLabel Localized label for the additional item column (e.g. 'Preceding\n * Marker')\n * @param additionalItemIndex Index that locates the desired item in the items array of the\n * inventory\n * @returns Column that shows additional inventory items. Should be used with the DataTable\n * component\n */\nexport const inventoryAdditionalItemColumn = (\n additionalItemLabel: string,\n additionalItemIndex: number,\n): ColumnDef => {\n return {\n accessorKey: `item${additionalItemIndex}`,\n accessorFn: (row: InventoryTableData) => row.items[additionalItemIndex],\n header: ({ column }) => (\n \n ),\n };\n};\n\n/**\n * Function that creates the count column for inventories. Should be used with the DataTable\n * component.\n *\n * @param itemLabel Localized label for the count column\n * @returns Column that shows the number of occurrences of the related inventory items\n */\nexport const inventoryCountColumn = (countLabel: string): ColumnDef => {\n return {\n accessorKey: 'count',\n header: ({ column }) => (\n
    \n \n
    \n ),\n cell: ({ row }) =>
    {row.getValue('count')}
    ,\n };\n};\n\n/**\n * Function that updates project settings when status for item(s) changes\n *\n * @param changedItems Array of items for which the status is being updated\n * @param newStatus The status that the items are being given\n * @param approvedItems Array of currently approved items\n * @param onApprovedItemsChange Callback function that stores the updated list of approved items\n * @param unapprovedItems Array of currently unapproved items\n * @param onUnapprovedItemsChange Callback function that stores the updated list of unapproved items\n */\nconst statusChangeHandler = (\n changedItems: string[],\n newStatus: Status,\n approvedItems: string[],\n onApprovedItemsChange: (items: string[]) => void,\n unapprovedItems: string[],\n onUnapprovedItemsChange: (items: string[]) => void,\n) => {\n let newApprovedItems: string[] = [...approvedItems];\n changedItems.forEach((item) => {\n if (newStatus === 'approved') {\n if (!newApprovedItems.includes(item)) {\n newApprovedItems.push(item);\n }\n } else {\n newApprovedItems = newApprovedItems.filter((validItem) => validItem !== item);\n }\n });\n onApprovedItemsChange(newApprovedItems);\n\n let newUnapprovedItems: string[] = [...unapprovedItems];\n changedItems.forEach((item) => {\n if (newStatus === 'unapproved') {\n if (!newUnapprovedItems.includes(item)) {\n newUnapprovedItems.push(item);\n }\n } else {\n newUnapprovedItems = newUnapprovedItems.filter((unapprovedItem) => unapprovedItem !== item);\n }\n });\n onUnapprovedItemsChange(newUnapprovedItems);\n};\n\n/**\n * Function that creates the status column for inventories. Should be used with the DataTable\n * component.\n *\n * @param statusLabel Localized label for the status column\n * @param approvedItems Array of approved items, typically as defined in `Settings.xml`\n * @param onApprovedItemsChange Callback function that stores the updated list of approved items\n * @param unapprovedItems Array of unapproved items, typically as defined in `Settings.xml`\n * @param onUnapprovedItemsChange Callback function that stores the updated list of unapproved items\n * @returns Column that shows the status buttons for the related inventory item. The button for the\n * current status of the item is selected\n */\nexport const inventoryStatusColumn = (\n statusLabel: string,\n approvedItems: string[],\n onApprovedItemsChange: (items: string[]) => void,\n unapprovedItems: string[],\n onUnapprovedItemsChange: (items: string[]) => void,\n): ColumnDef => {\n return {\n accessorKey: 'status',\n header: ({ column }) => {\n return (\n
    \n \n
    \n );\n },\n cell: ({ row }) => {\n const status: Status = row.getValue('status');\n const item: string = row.getValue('item');\n return (\n \n \n statusChangeHandler(\n [item],\n 'approved',\n approvedItems,\n onApprovedItemsChange,\n unapprovedItems,\n onUnapprovedItemsChange,\n )\n }\n value=\"approved\"\n >\n \n \n \n statusChangeHandler(\n [item],\n 'unapproved',\n approvedItems,\n onApprovedItemsChange,\n unapprovedItems,\n onUnapprovedItemsChange,\n )\n }\n value=\"unapproved\"\n >\n \n \n \n statusChangeHandler(\n [item],\n 'unknown',\n approvedItems,\n onApprovedItemsChange,\n unapprovedItems,\n onUnapprovedItemsChange,\n )\n }\n value=\"unknown\"\n >\n \n \n \n );\n },\n };\n};\n","import DataTable, {\n ColumnDef,\n RowContents,\n RowSelectionState,\n TableContents,\n} from '@/components/advanced/data-table/data-table.component';\nimport OccurrencesTable from '@/components/advanced/inventory/occurrences-table.component';\nimport Checkbox from '@/components/shadcn-ui/checkbox';\nimport { Input } from '@/components/shadcn-ui/input';\nimport { Label } from '@/components/shadcn-ui/label';\nimport {\n Select,\n SelectContent,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\nimport {\n deepEqual,\n LocalizedStringValue,\n ScriptureReference,\n substring,\n} from 'platform-bible-utils';\nimport { useEffect, useMemo, useState } from 'react';\nimport {\n getBookNumFromId,\n getLinesFromUSFM,\n getNumberFromUSFM,\n getStatusForItem,\n InventoryItemOccurrence,\n InventoryTableData,\n Status,\n} from './inventory-utils';\nimport { inventoryAdditionalItemColumn } from './inventory-columns';\n\n/**\n * Object containing all keys used for localization in this component. If you're using this\n * component in an extension, you can pass it into the useLocalizedStrings hook to easily obtain the\n * localized strings and pass them into the localizedStrings prop of this component\n */\nexport const INVENTORY_STRING_KEYS = Object.freeze([\n '%webView_inventory_all%',\n '%webView_inventory_approved%',\n '%webView_inventory_unapproved%',\n '%webView_inventory_unknown%',\n '%webView_inventory_scope_currentBook%',\n '%webView_inventory_scope_chapter%',\n '%webView_inventory_scope_verse%',\n '%webView_inventory_filter_text%',\n '%webView_inventory_show_additional_items%',\n '%webView_inventory_occurrences_table_header_reference%',\n '%webView_inventory_occurrences_table_header_occurrence%',\n] as const);\n\nexport type InventoryLocalizedStrings = {\n [localizedInventoryKey in (typeof INVENTORY_STRING_KEYS)[number]]?: LocalizedStringValue;\n};\n\n/** Scope of scripture that the inventory can operate on */\nexport type Scope = 'book' | 'chapter' | 'verse';\n\n/** Status values that the status filter can select from */\ntype StatusFilter = Status | 'all';\n\n/** Text labels for the inventory columns and the control components of additional inventory items */\ntype AdditionalItemsLabels = {\n checkboxText?: string;\n tableHeaders?: string[];\n};\n\n/**\n * Filters data that is shown in the DataTable section of the Inventory\n *\n * @param itemData All inventory items and their related information\n * @param statusFilter Allows filtering by status (i.e. show all items, or only items that are\n * 'approved', 'unapproved' or 'unknown')\n * @param textFilter Allows filtering by text. All items that include the filter text will be\n * selected.\n * @returns Array of items and their related information that are matched by the specified filters\n */\nconst filterItemData = (\n itemData: InventoryTableData[],\n statusFilter: StatusFilter,\n textFilter: string,\n): InventoryTableData[] => {\n let filteredItemData: InventoryTableData[] = itemData;\n\n if (statusFilter !== 'all') {\n filteredItemData = filteredItemData.filter(\n (item) =>\n (statusFilter === 'approved' && item.status === 'approved') ||\n (statusFilter === 'unapproved' && item.status === 'unapproved') ||\n (statusFilter === 'unknown' && item.status === 'unknown'),\n );\n }\n\n if (textFilter !== '')\n filteredItemData = filteredItemData.filter((item) => item.items[0].includes(textFilter));\n\n return filteredItemData;\n};\n\n/**\n * Turns array of strings into array of inventory items, along with their count and status\n *\n * @param text The source scripture text that is searched for inventory items\n * @param scriptureRef The scripture reference that the application is currently set to\n * @param approvedItems Array of approved items, typically as defined in `Settings.xml`\n * @param unapprovedItems Array of unapproved items, typically as defined in `Settings.xml`\n * @param itemRegex Regular expression that describes what items this Inventory should extract from\n * the provided scripture text\n * @returns Array of inventory items, along with their count and status\n */\nconst createTableData = (\n text: string | undefined,\n scriptureRef: ScriptureReference,\n approvedItems: string[],\n unapprovedItems: string[],\n itemRegex: RegExp,\n): InventoryTableData[] => {\n if (!text) return [];\n\n const tableData: InventoryTableData[] = [];\n\n let currentBook: number | undefined = scriptureRef.bookNum;\n let currentChapter: number | undefined = scriptureRef.chapterNum;\n let currentVerse: number | undefined = scriptureRef.verseNum;\n\n const lines = getLinesFromUSFM(text);\n\n lines.forEach((line: string) => {\n if (line.startsWith('\\\\id')) {\n currentBook = getBookNumFromId(line);\n currentChapter = 0;\n currentVerse = 0;\n }\n if (line.startsWith('\\\\c')) {\n currentChapter = getNumberFromUSFM(line);\n currentVerse = 0;\n }\n if (line.startsWith('\\\\v')) {\n currentVerse = getNumberFromUSFM(line);\n if (currentChapter === 0) {\n currentChapter = scriptureRef.chapterNum;\n }\n }\n\n let match: RegExpExecArray | undefined = itemRegex.exec(line) ?? undefined;\n while (match) {\n const items: string[] = [];\n match.forEach((item) => items.push(item));\n const itemIndex = match.index;\n const existingItem = tableData.find((tableEntry) => deepEqual(tableEntry.items, items));\n const newReference: InventoryItemOccurrence = {\n reference: {\n bookNum: currentBook !== undefined ? currentBook : -1,\n chapterNum: currentChapter !== undefined ? currentChapter : -1,\n verseNum: currentVerse !== undefined ? currentVerse : -1,\n },\n text: substring(line, Math.max(0, itemIndex - 25), Math.min(itemIndex + 25, line.length)),\n };\n if (existingItem) {\n existingItem.count += 1;\n existingItem.occurrences.push(newReference);\n } else {\n const newItem: InventoryTableData = {\n items,\n count: 1,\n status: getStatusForItem(items[0], approvedItems, unapprovedItems),\n occurrences: [newReference],\n };\n tableData.push(newItem);\n }\n\n match = itemRegex.exec(line) ?? undefined;\n }\n });\n\n return tableData;\n};\n\n/**\n * Gets the localized value for the provided key\n *\n * @param strings Object containing localized string\n * @param key Key for a localized string\n * @returns The localized value for the provided key, if available. Returns the key if no localized\n * value is available\n */\nconst localizeString = (\n strings: InventoryLocalizedStrings,\n key: keyof InventoryLocalizedStrings,\n) => {\n return strings[key] ?? key;\n};\n\n/** Props for the Inventory component */\ntype InventoryProps = {\n /** The scripture reference that the application is currently set to */\n scriptureReference: ScriptureReference;\n /** Callback function that is executed when the scripture reference is changed */\n setScriptureReference: (scriptureReference: ScriptureReference) => void;\n /**\n * Object with all localized strings that the Inventory needs to work well across multiple\n * languages. When using this component with Platform.Bible, you can import\n * `INVENTORY_STRING_KEYS` from this library, pass it in to the Platform's localization hook, and\n * pass the localized keys that are returned by the hook into this prop.\n */\n localizedStrings: InventoryLocalizedStrings;\n /**\n * The logic that finds the desired items in the source text. This can either be a Regular\n * expression that captures one or multiple items (preferred), or a custom function that builds\n * and return an InventoryDataTable[] manually. Note: In case the logic captures more than one\n * item (i.e. InventoryTableData.items has a length greater than 1), you must provide text labels\n * for the related columns and control elements to show by setting the `additionalItemsLabels`\n * prop\n */\n extractItems:\n | RegExp\n | ((\n text: string | undefined,\n scriptureRef: ScriptureReference,\n approvedItems: string[],\n unapprovedItems: string[],\n ) => InventoryTableData[]);\n /**\n * Text labels for control elements and additional column headers in case your Inventory has more\n * than one item to show (e.g. The 'Preceding Marker' in the Markers Inventory)\n */\n additionalItemsLabels?: AdditionalItemsLabels;\n /** Array of approved items, typically as defined in `Settings.xml` */\n approvedItems: string[];\n /** Array of unapproved items, typically as defined in `Settings.xml` */\n unapprovedItems: string[];\n /** The source scripture text that is searched for in inventory items */\n text: string | undefined;\n /** Scope of scripture that the inventory will operate on */\n scope: Scope;\n /** Callback function that is executed when the scope is changed from the Inventory */\n onScopeChange: (scope: Scope) => void;\n /**\n * Column definitions for the Inventory data table. The most commonly used column definitions are\n * pre-configured for your convenience and can be imported (e.g. inventoryItemColumn,\n * inventoryAdditionalItemColumn inventoryCountColumn, and inventoryStatusColumn). If you need any\n * other columns you can add these yourself\n */\n columns: ColumnDef[];\n};\n\n/** Inventory component that is used to view and control the status of provided project settings */\nexport default function Inventory({\n scriptureReference,\n setScriptureReference,\n localizedStrings,\n extractItems,\n additionalItemsLabels,\n approvedItems,\n unapprovedItems,\n text,\n scope,\n onScopeChange,\n columns,\n}: InventoryProps) {\n const allItemsText = localizeString(localizedStrings, '%webView_inventory_all%');\n const approvedItemsText = localizeString(localizedStrings, '%webView_inventory_approved%');\n const unapprovedItemsText = localizeString(localizedStrings, '%webView_inventory_unapproved%');\n const unknownItemsText = localizeString(localizedStrings, '%webView_inventory_unknown%');\n const scopeBookText = localizeString(localizedStrings, '%webView_inventory_scope_currentBook%');\n const scopeChapterText = localizeString(localizedStrings, '%webView_inventory_scope_chapter%');\n const scopeVerseText = localizeString(localizedStrings, '%webView_inventory_scope_verse%');\n const filterText = localizeString(localizedStrings, '%webView_inventory_filter_text%');\n const showAdditionalItemsText = localizeString(\n localizedStrings,\n '%webView_inventory_show_additional_items%',\n );\n\n const [showAdditionalItems, setShowAdditionalItems] = useState(false);\n const [statusFilter, setStatusFilter] = useState('all');\n const [textFilter, setTextFilter] = useState('');\n const [selectedItem, setSelectedItem] = useState([]);\n\n const tableData: InventoryTableData[] = useMemo(() => {\n if (!text) return [];\n if (extractItems instanceof RegExp)\n return createTableData(\n text,\n scriptureReference,\n approvedItems,\n unapprovedItems,\n extractItems,\n );\n return extractItems(text, scriptureReference, approvedItems, unapprovedItems);\n }, [text, extractItems, scriptureReference, approvedItems, unapprovedItems]);\n\n const reducedTableData: InventoryTableData[] = useMemo(() => {\n if (showAdditionalItems) return tableData;\n\n const newTableData: InventoryTableData[] = [];\n\n tableData.forEach((tableEntry) => {\n const firstItem = tableEntry.items[0];\n\n const existingEntry = newTableData.find(\n (newTableEntry) => newTableEntry.items[0] === firstItem,\n );\n\n if (existingEntry) {\n existingEntry.count += tableEntry.count;\n existingEntry.occurrences = existingEntry.occurrences.concat(tableEntry.occurrences);\n } else {\n newTableData.push({\n items: [firstItem],\n count: tableEntry.count,\n occurrences: tableEntry.occurrences,\n status: tableEntry.status,\n });\n }\n });\n\n return newTableData;\n }, [showAdditionalItems, tableData]);\n\n const filteredTableData: InventoryTableData[] = useMemo(() => {\n return filterItemData(reducedTableData, statusFilter, textFilter);\n }, [reducedTableData, statusFilter, textFilter]);\n\n const allColumns: ColumnDef[] = useMemo(() => {\n if (!showAdditionalItems) return columns;\n\n const numberOfAdditionalItems = additionalItemsLabels?.tableHeaders?.length;\n if (!numberOfAdditionalItems) return columns;\n\n const additionalColumns: ColumnDef[] = [];\n\n for (let index = 0; index < numberOfAdditionalItems; index++) {\n additionalColumns.push(\n inventoryAdditionalItemColumn(\n additionalItemsLabels?.tableHeaders?.[index] || 'Additional Item',\n index + 1,\n ),\n );\n }\n\n return [...additionalColumns, ...columns];\n }, [additionalItemsLabels?.tableHeaders, columns, showAdditionalItems]);\n\n useEffect(() => {\n setSelectedItem([]);\n }, [filteredTableData]);\n\n const rowClickHandler = (\n row: RowContents,\n table: TableContents,\n ) => {\n table.setRowSelection(() => {\n const newSelection: RowSelectionState = {};\n newSelection[row.index] = true;\n return newSelection;\n });\n\n setSelectedItem(row.original.items);\n };\n\n const handleScopeChange = (value: string) => {\n if (value === 'book' || value === 'chapter' || value === 'verse') {\n onScopeChange(value);\n } else {\n throw new Error(`Invalid scope value: ${value}`);\n }\n };\n\n const handleStatusFilterChange = (value: string) => {\n if (value === 'all' || value === 'approved' || value === 'unapproved' || value === 'unknown') {\n setStatusFilter(value);\n } else {\n throw new Error(`Invalid status filter value: ${value}`);\n }\n };\n\n const occurrenceData: InventoryItemOccurrence[] = useMemo(() => {\n if (reducedTableData.length === 0 || selectedItem.length === 0) return [];\n const occurrence = reducedTableData.filter((tableEntry: InventoryTableData) => {\n return deepEqual(\n showAdditionalItems ? tableEntry.items : [tableEntry.items[0]],\n selectedItem,\n );\n });\n if (occurrence.length > 1) throw new Error('Selected item is not unique');\n return occurrence[0].occurrences;\n }, [selectedItem, showAdditionalItems, reducedTableData]);\n\n return (\n
    \n
    \n handleStatusFilterChange(value)}\n defaultValue={statusFilter}\n >\n \n \n \n \n {allItemsText}\n {approvedItemsText}\n {unapprovedItemsText}\n {unknownItemsText}\n \n \n \n {\n setTextFilter(event.target.value);\n }}\n />\n {additionalItemsLabels && (\n
    \n {\n setSelectedItem([]);\n setShowAdditionalItems(checked);\n }}\n />\n \n
    \n )}\n
    \n
    \n \n
    \n {occurrenceData.length > 0 && (\n
    \n \n
    \n )}\n
    \n );\n}\n","import { Input } from '@/components/shadcn-ui/input';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { useState } from 'react';\n\n/** Props for the SearchBar component. */\nexport type SearchBarProps = {\n className?: string;\n /**\n * Callback fired to handle the search query when button pressed\n *\n * @param searchQuery\n */\n onSearch: (searchQuery: string) => void;\n\n /** Optional string that appears in the search bar without a search string */\n placeholder?: string;\n\n /** Optional boolean to set the input base to full width */\n isFullWidth?: boolean;\n};\n\nexport default function SearchBar({\n className,\n onSearch,\n placeholder,\n isFullWidth,\n}: SearchBarProps) {\n const [searchQuery, setSearchQuery] = useState('');\n\n const handleInputChange = (searchString: string) => {\n setSearchQuery(searchString);\n onSearch(searchString);\n };\n\n return (\n handleInputChange(e.target.value)}\n />\n );\n}\n","// adapted from: https://github.com/shadcn-ui/ui/discussions/752\n\n'use client';\n\nimport { TabsContentProps, TabsListProps, TabsTriggerProps } from '@/components/shadcn-ui/tabs';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport * as TabsPrimitive from '@radix-ui/react-tabs';\nimport React from 'react';\n\nexport type VerticalTabsProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport type LeftTabsTriggerProps = TabsTriggerProps & {\n value: string;\n ref?: React.Ref;\n};\n\nexport const VerticalTabs = React.forwardRef<\n React.ElementRef,\n VerticalTabsProps\n>(({ className, ...props }, ref) => (\n \n));\n\nVerticalTabs.displayName = TabsPrimitive.List.displayName;\n\nexport const VerticalTabsList = React.forwardRef<\n React.ElementRef,\n TabsListProps\n>(({ className, ...props }, ref) => (\n \n));\nVerticalTabsList.displayName = TabsPrimitive.List.displayName;\n\nexport const VerticalTabsTrigger = React.forwardRef<\n React.ElementRef,\n LeftTabsTriggerProps\n>(({ className, ...props }, ref) => (\n \n));\n\nexport const VerticalTabsContent = React.forwardRef<\n React.ElementRef,\n TabsContentProps\n>(({ className, ...props }, ref) => (\n \n));\nVerticalTabsContent.displayName = TabsPrimitive.Content.displayName;\n","import SearchBar from '@/components/basics/search-bar.component';\nimport {\n VerticalTabs,\n VerticalTabsContent,\n VerticalTabsList,\n VerticalTabsTrigger,\n} from '@/components/basics/tabs-vertical';\nimport { ReactNode } from 'react';\n\nexport type TabKeyValueContent = {\n key: string;\n value: string;\n content: ReactNode;\n};\n\nexport type TabNavigationContentSearchProps = {\n /** List of values and keys for each tab this component should provide */\n tabList: TabKeyValueContent[];\n\n /** Handler to run when the value of the search bar changes */\n onSearch: (searchQuery: string) => void;\n\n /** Optional placeholder for the search bar */\n searchPlaceholder?: string;\n\n /** Optional title to include in the header */\n headerTitle?: string;\n\n /** Optional flag to make the search bar appear full width */\n isSearchBarFullWidth?: boolean;\n\n /** Text direction ltr or rtl */\n direction?: 'ltr' | 'rtl';\n};\n\nexport default function TabNavigationContentSearch({\n tabList,\n onSearch,\n searchPlaceholder,\n headerTitle,\n isSearchBarFullWidth = false,\n direction = 'ltr',\n}: TabNavigationContentSearchProps) {\n return (\n
    \n
    \n {headerTitle ?

    {headerTitle}

    : ''}\n \n
    \n \n \n {tabList.map((tab) => (\n \n {tab.value}\n \n ))}\n \n {tabList.map((tab) => (\n \n {tab.content}\n \n ))}\n \n
    \n );\n}\n","import React from 'react';\nimport * as SeparatorPrimitive from '@radix-ui/react-separator';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Separator = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, orientation = 'horizontal', decorative = true, ...props }, ref) => (\n \n));\nSeparator.displayName = SeparatorPrimitive.Root.displayName;\n\nexport { Separator };\n","'use client';\n\nimport * as React from 'react';\nimport * as SheetPrimitive from '@radix-ui/react-dialog';\nimport { cva, type VariantProps } from 'class-variance-authority';\nimport { X } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Sheet = SheetPrimitive.Root;\n\nconst SheetTrigger = SheetPrimitive.Trigger;\n\nconst SheetClose = SheetPrimitive.Close;\n\nconst SheetPortal = SheetPrimitive.Portal;\n\nconst SheetOverlay = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSheetOverlay.displayName = SheetPrimitive.Overlay.displayName;\n\nconst sheetVariants = cva(\n 'pr-twp tw-fixed tw-z-50 tw-gap-4 tw-bg-background tw-p-6 tw-shadow-lg tw-transition tw-ease-in-out data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-duration-300 data-[state=open]:tw-duration-500',\n {\n variants: {\n side: {\n top: 'tw-inset-x-0 tw-top-0 tw-border-b data-[state=closed]:tw-slide-out-to-top data-[state=open]:tw-slide-in-from-top',\n bottom:\n 'tw-inset-x-0 tw-bottom-0 tw-border-t data-[state=closed]:tw-slide-out-to-bottom data-[state=open]:tw-slide-in-from-bottom',\n left: 'tw-inset-y-0 tw-left-0 tw-h-full tw-w-3/4 tw-border-r data-[state=closed]:tw-slide-out-to-left data-[state=open]:tw-slide-in-from-left sm:tw-max-w-sm',\n right:\n 'tw-inset-y-0 tw-right-0 tw-h-full tw-w-3/4 tw- tw-border-l data-[state=closed]:tw-slide-out-to-right data-[state=open]:tw-slide-in-from-right sm:tw-max-w-sm',\n },\n },\n defaultVariants: {\n side: 'right',\n },\n },\n);\n\ninterface SheetContentProps\n extends React.ComponentPropsWithoutRef,\n VariantProps {}\n\nconst SheetContent = React.forwardRef<\n React.ElementRef,\n SheetContentProps\n>(({ side = 'right', className, children, ...props }, ref) => (\n \n \n \n {children}\n \n \n Close\n \n \n \n));\nSheetContent.displayName = SheetPrimitive.Content.displayName;\n\nfunction SheetHeader({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nSheetHeader.displayName = 'SheetHeader';\n\nfunction SheetFooter({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nSheetFooter.displayName = 'SheetFooter';\n\nconst SheetTitle = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSheetTitle.displayName = SheetPrimitive.Title.displayName;\n\nconst SheetDescription = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSheetDescription.displayName = SheetPrimitive.Description.displayName;\n\nexport {\n Sheet,\n SheetPortal,\n SheetOverlay,\n SheetTrigger,\n SheetClose,\n SheetContent,\n SheetHeader,\n SheetFooter,\n SheetTitle,\n SheetDescription,\n};\n","import React from 'react';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nfunction Skeleton({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\n\nexport { Skeleton };\n","import React from 'react';\nimport * as TooltipPrimitive from '@radix-ui/react-tooltip';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst TooltipProvider = TooltipPrimitive.Provider;\n\nconst Tooltip = TooltipPrimitive.Root;\n\nconst TooltipTrigger = TooltipPrimitive.Trigger;\n\nconst TooltipContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, sideOffset = 4, ...props }, ref) => (\n \n));\nTooltipContent.displayName = TooltipPrimitive.Content.displayName;\n\nexport { Tooltip, TooltipTrigger, TooltipContent, TooltipProvider };\n","import React from 'react';\n\nconst MOBILE_BREAKPOINT = 768;\n\nexport default function useIsMobile() {\n const [isMobile, setIsMobile] = React.useState(undefined);\n\n React.useEffect(() => {\n const mql = window.matchMedia(`(max-width: ${MOBILE_BREAKPOINT - 1}px)`);\n const onChange = () => {\n setIsMobile(window.innerWidth < MOBILE_BREAKPOINT);\n };\n mql.addEventListener('change', onChange);\n setIsMobile(window.innerWidth < MOBILE_BREAKPOINT);\n return () => mql.removeEventListener('change', onChange);\n }, []);\n\n return !!isMobile;\n}\n","import React from 'react';\nimport { Slot } from '@radix-ui/react-slot';\nimport { VariantProps, cva } from 'class-variance-authority';\nimport { PanelLeft } from 'lucide-react';\n\nimport { Button } from '@/components/shadcn-ui/button';\nimport { Input } from '@/components/shadcn-ui/input';\nimport { Separator } from '@/components/shadcn-ui/separator';\nimport { Sheet, SheetContent } from '@/components/shadcn-ui/sheet';\nimport { Skeleton } from '@/components/shadcn-ui/skeleton';\nimport {\n Tooltip,\n TooltipContent,\n TooltipProvider,\n TooltipTrigger,\n} from '@/components/shadcn-ui/tooltip';\nimport useIsMobile from '@/components/hooks/use-mobile';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst SIDEBAR_COOKIE_NAME = 'sidebar:state';\nconst SIDEBAR_COOKIE_MAX_AGE = 60 * 60 * 24 * 7;\nconst SIDEBAR_WIDTH = '16rem';\nconst SIDEBAR_WIDTH_MOBILE = '18rem';\nconst SIDEBAR_WIDTH_ICON = '3rem';\nconst SIDEBAR_KEYBOARD_SHORTCUT = 'b';\n\ntype SidebarContextProps = {\n state: 'expanded' | 'collapsed';\n open: boolean;\n setOpen: (open: boolean) => void;\n openMobile: boolean;\n setOpenMobile: (open: boolean) => void;\n isMobile: boolean;\n toggleSidebar: () => void;\n};\n\nconst SidebarContext = React.createContext(undefined);\n\nfunction useSidebar() {\n const context = React.useContext(SidebarContext);\n if (!context) {\n throw new Error('useSidebar must be used within a SidebarProvider.');\n }\n\n return context;\n}\n\nconst SidebarProvider = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & {\n defaultOpen?: boolean;\n open?: boolean;\n onOpenChange?: (open: boolean) => void;\n }\n>(\n (\n {\n defaultOpen = true,\n open: openProp,\n onOpenChange: setOpenProp,\n className,\n style,\n children,\n ...props\n },\n ref,\n ) => {\n const isMobile = useIsMobile();\n const [openMobile, setOpenMobile] = React.useState(false);\n\n // This is the internal state of the sidebar.\n // We use openProp and setOpenProp for control from outside the component.\n const [_open, _setOpen] = React.useState(defaultOpen);\n const isOpen = openProp ?? _open;\n const setOpen = React.useCallback(\n (value: boolean | ((value: boolean) => boolean)) => {\n const openState = typeof value === 'function' ? value(isOpen) : value;\n if (setOpenProp) {\n setOpenProp(openState);\n } else {\n _setOpen(openState);\n }\n\n // This sets the cookie to keep the sidebar state.\n document.cookie = `${SIDEBAR_COOKIE_NAME}=${openState}; path=/; max-age=${SIDEBAR_COOKIE_MAX_AGE}`;\n },\n [setOpenProp, isOpen],\n );\n\n // Helper to toggle the sidebar.\n const toggleSidebar = React.useCallback(() => {\n return isMobile ? setOpenMobile((open) => !open) : setOpen((open) => !open);\n }, [isMobile, setOpen, setOpenMobile]);\n\n // Adds a keyboard shortcut to toggle the sidebar.\n React.useEffect(() => {\n const handleKeyDown = (event: KeyboardEvent) => {\n if (event.key === SIDEBAR_KEYBOARD_SHORTCUT && (event.metaKey || event.ctrlKey)) {\n event.preventDefault();\n toggleSidebar();\n }\n };\n\n window.addEventListener('keydown', handleKeyDown);\n return () => window.removeEventListener('keydown', handleKeyDown);\n }, [toggleSidebar]);\n\n // We add a state so that we can do data-state=\"expanded\" or \"collapsed\".\n // This makes it easier to style the sidebar with Tailwind classes.\n const state = isOpen ? 'expanded' : 'collapsed';\n\n const contextValue = React.useMemo(\n () => ({\n state,\n open: isOpen,\n setOpen,\n isMobile,\n openMobile,\n setOpenMobile,\n toggleSidebar,\n }),\n [state, isOpen, setOpen, isMobile, openMobile, setOpenMobile, toggleSidebar],\n );\n\n return (\n \n \n \n {children}\n
    \n \n \n );\n },\n);\nSidebarProvider.displayName = 'SidebarProvider';\n\nconst Sidebar = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & {\n side?: 'left' | 'right';\n variant?: 'sidebar' | 'floating' | 'inset';\n collapsible?: 'offcanvas' | 'icon' | 'none';\n }\n>(\n (\n {\n side = 'left',\n variant = 'sidebar',\n collapsible = 'offcanvas',\n className,\n children,\n ...props\n },\n ref,\n ) => {\n const { isMobile, state, openMobile, setOpenMobile } = useSidebar();\n\n if (collapsible === 'none') {\n return (\n \n {children}\n
    \n );\n }\n\n if (isMobile) {\n return (\n \n button]:tw-hidden\"\n style={\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n {\n '--sidebar-width': SIDEBAR_WIDTH_MOBILE,\n } as React.CSSProperties\n }\n side={side}\n >\n
    {children}
    \n \n
    \n );\n }\n\n return (\n \n {/* This is what handles the sidebar gap on desktop */}\n \n \n \n {children}\n
    \n
    \n
    \n );\n },\n);\nSidebar.displayName = 'Sidebar';\n\nconst SidebarTrigger = React.forwardRef<\n React.ElementRef,\n React.ComponentProps\n>(({ className, onClick, ...props }, ref) => {\n const { toggleSidebar } = useSidebar();\n\n return (\n {\n onClick?.(event);\n toggleSidebar();\n }}\n {...props}\n >\n \n Toggle Sidebar\n \n );\n});\nSidebarTrigger.displayName = 'SidebarTrigger';\n\nconst SidebarRail = React.forwardRef>(\n ({ className, ...props }, ref) => {\n const { toggleSidebar } = useSidebar();\n\n return (\n \n );\n },\n);\nSidebarRail.displayName = 'SidebarRail';\n\nconst SidebarInset = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarInset.displayName = 'SidebarInset';\n\nconst SidebarInput = React.forwardRef<\n React.ElementRef,\n React.ComponentProps\n>(({ className, ...props }, ref) => {\n return (\n \n );\n});\nSidebarInput.displayName = 'SidebarInput';\n\nconst SidebarHeader = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarHeader.displayName = 'SidebarHeader';\n\nconst SidebarFooter = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarFooter.displayName = 'SidebarFooter';\n\nconst SidebarSeparator = React.forwardRef<\n React.ElementRef,\n React.ComponentProps\n>(({ className, ...props }, ref) => {\n return (\n \n );\n});\nSidebarSeparator.displayName = 'SidebarSeparator';\n\nconst SidebarContent = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarContent.displayName = 'SidebarContent';\n\nconst SidebarGroup = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarGroup.displayName = 'SidebarGroup';\n\nconst SidebarGroupLabel = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & { asChild?: boolean }\n>(({ className, asChild = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'div';\n\n return (\n svg]:tw-size-4 [&>svg]:tw-shrink-0',\n 'group-data-[collapsible=icon]:tw--mt-8 group-data-[collapsible=icon]:tw-opacity-0',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarGroupLabel.displayName = 'SidebarGroupLabel';\n\nconst SidebarGroupAction = React.forwardRef<\n HTMLButtonElement,\n React.ComponentProps<'button'> & { asChild?: boolean }\n>(({ className, asChild = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'button';\n\n return (\n svg]:tw-size-4 [&>svg]:tw-shrink-0',\n // Increases the hit area of the button on mobile.\n 'after:tw-absolute after:tw--inset-2 after:md:tw-hidden',\n 'group-data-[collapsible=icon]:tw-hidden',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarGroupAction.displayName = 'SidebarGroupAction';\n\nconst SidebarGroupContent = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarGroupContent.displayName = 'SidebarGroupContent';\n\nconst SidebarMenu = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenu.displayName = 'SidebarMenu';\n\nconst SidebarMenuItem = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenuItem.displayName = 'SidebarMenuItem';\n\nconst sidebarMenuButtonVariants = cva(\n // Removed data-[active=true]:tw-bg-sidebar-accent\n 'tw-peer/menu-button tw-flex tw-w-full tw-items-center tw-gap-2 tw-overflow-hidden tw-rounded-md tw-p-2 tw-text-left tw-text-sm tw-outline-none tw-ring-sidebar-ring tw-transition-[width,height,padding] hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground focus-visible:tw-ring-2 active:tw-bg-sidebar-accent active:tw-text-sidebar-accent-foreground disabled:tw-pointer-events-none disabled:tw-opacity-50 tw-group-has-[[data-sidebar=menu-action]]/menu-item:pr-8 aria-disabled:tw-pointer-events-none aria-disabled:tw-opacity-50 data-[active=true]:tw-font-medium data-[active=true]:tw-text-sidebar-accent-foreground data-[state=open]:hover:tw-bg-sidebar-accent data-[state=open]:hover:tw-text-sidebar-accent-foreground group-data-[collapsible=icon]:tw-!size-8 group-data-[collapsible=icon]:tw-!p-2 [&>span:last-child]:tw-truncate [&>svg]:tw-size-4 [&>svg]:tw-shrink-0',\n {\n variants: {\n variant: {\n default: 'hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground',\n outline:\n 'tw-bg-background tw-shadow-[0_0_0_1px_hsl(var(--sidebar-border))] hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground hover:tw-shadow-[0_0_0_1px_hsl(var(--sidebar-accent))]',\n },\n size: {\n default: 'tw-h-8 tw-text-sm',\n sm: 'tw-h-7 tw-text-xs',\n lg: 'tw-h-12 tw-text-sm group-data-[collapsible=icon]:tw-!p-0',\n },\n },\n defaultVariants: {\n variant: 'default',\n size: 'default',\n },\n },\n);\n\nconst SidebarMenuButton = React.forwardRef<\n HTMLButtonElement,\n React.ComponentProps<'button'> & {\n asChild?: boolean;\n isActive?: boolean;\n tooltip?: string | React.ComponentProps;\n } & VariantProps\n>(\n (\n {\n asChild = false,\n isActive = false,\n variant = 'default',\n size = 'default',\n tooltip,\n className,\n ...props\n },\n ref,\n ) => {\n const Comp = asChild ? Slot : 'button';\n const { isMobile, state } = useSidebar();\n\n const button = (\n \n );\n\n if (!tooltip) {\n return button;\n }\n\n if (typeof tooltip === 'string') {\n // eslint-disable-next-line no-param-reassign\n tooltip = {\n children: tooltip,\n };\n }\n\n return (\n \n {button}\n \n );\n },\n);\nSidebarMenuButton.displayName = 'SidebarMenuButton';\n\nconst SidebarMenuAction = React.forwardRef<\n HTMLButtonElement,\n React.ComponentProps<'button'> & {\n asChild?: boolean;\n showOnHover?: boolean;\n }\n>(({ className, asChild = false, showOnHover = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'button';\n\n return (\n svg]:tw-size-4 [&>svg]:tw-shrink-0',\n // Increases the hit area of the button on mobile.\n 'after:tw-absolute after:tw--inset-2 after:md:tw-hidden',\n 'tw-peer-data-[size=sm]/menu-button:top-1',\n 'tw-peer-data-[size=default]/menu-button:top-1.5',\n 'tw-peer-data-[size=lg]/menu-button:top-2.5',\n 'group-data-[collapsible=icon]:tw-hidden',\n showOnHover &&\n 'tw-group-focus-within/menu-item:opacity-100 tw-group-hover/menu-item:opacity-100 tw-peer-data-[active=true]/menu-button:text-sidebar-accent-foreground data-[state=open]:tw-opacity-100 md:tw-opacity-0',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarMenuAction.displayName = 'SidebarMenuAction';\n\nconst SidebarMenuBadge = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenuBadge.displayName = 'SidebarMenuBadge';\n\nconst SidebarMenuSkeleton = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & {\n showIcon?: boolean;\n }\n>(({ className, showIcon = false, ...props }, ref) => {\n // Random width between 50 to 90%.\n const width = React.useMemo(() => {\n return `${Math.floor(Math.random() * 40) + 50}%`;\n }, []);\n\n return (\n \n {showIcon && (\n \n )}\n \n
    \n );\n});\nSidebarMenuSkeleton.displayName = 'SidebarMenuSkeleton';\n\nconst SidebarMenuSub = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenuSub.displayName = 'SidebarMenuSub';\n\nconst SidebarMenuSubItem = React.forwardRef>(\n ({ ...props }, ref) =>
  • ,\n);\nSidebarMenuSubItem.displayName = 'SidebarMenuSubItem';\n\nconst SidebarMenuSubButton = React.forwardRef<\n HTMLAnchorElement,\n React.ComponentProps<'a'> & {\n asChild?: boolean;\n size?: 'sm' | 'md';\n isActive?: boolean;\n }\n>(({ asChild = false, size = 'md', isActive, className, ...props }, ref) => {\n const Comp = asChild ? Slot : 'a';\n\n return (\n span:last-child]:tw-truncate [&>svg]:tw-size-4 [&>svg]:tw-shrink-0 [&>svg]:tw-text-sidebar-accent-foreground',\n 'data-[active=true]:tw-bg-sidebar-accent data-[active=true]:tw-text-sidebar-accent-foreground',\n size === 'sm' && 'tw-text-xs',\n size === 'md' && 'tw-text-sm',\n 'group-data-[collapsible=icon]:tw-hidden',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarMenuSubButton.displayName = 'SidebarMenuSubButton';\n\nexport {\n Sidebar,\n SidebarContent,\n SidebarFooter,\n SidebarGroup,\n SidebarGroupAction,\n SidebarGroupContent,\n SidebarGroupLabel,\n SidebarHeader,\n SidebarInput,\n SidebarInset,\n SidebarMenu,\n SidebarMenuAction,\n SidebarMenuBadge,\n SidebarMenuButton,\n SidebarMenuItem,\n SidebarMenuSkeleton,\n SidebarMenuSub,\n SidebarMenuSubButton,\n SidebarMenuSubItem,\n SidebarProvider,\n SidebarRail,\n SidebarSeparator,\n SidebarTrigger,\n useSidebar,\n};\n","import ComboBox, { ComboBoxOption } from '@/components/basics/combo-box.component';\nimport {\n Sidebar,\n SidebarContent,\n SidebarGroup,\n SidebarGroupLabel,\n SidebarGroupContent,\n SidebarMenu,\n SidebarMenuItem,\n SidebarMenuButton,\n} from '@/components/shadcn-ui/sidebar';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { useCallback } from 'react';\n\nexport type SelectedSettingsSidebarItem = {\n label: string;\n projectId?: string;\n};\n\nexport type ProjectInfo = { projectId: string; projectName: string };\n\nexport type SettingsSidebarProps = {\n /** Optional id for testing */\n id?: string;\n\n /** Extension labels from contribution */\n extensionLabels: string[];\n\n /** Project names and ids */\n projectOptions: ProjectInfo[];\n\n /** Handler for selecting a sidebar item */\n handleSelectSidebarItem: (key: string, projectId?: string) => void;\n\n /** The current selected value in the sidebar */\n selectedSidebarItem: SelectedSettingsSidebarItem;\n\n /** Label for the group of extensions setting groups */\n extensionsSidebarGroupLabel: string;\n\n /** Label for the group of projects settings */\n projectsSidebarGroupLabel: string;\n\n /** Placeholder text for the button */\n buttonPlaceholderText: string;\n};\n\nexport default function SettingsSidebar({\n id,\n extensionLabels,\n projectOptions,\n handleSelectSidebarItem,\n selectedSidebarItem,\n extensionsSidebarGroupLabel,\n projectsSidebarGroupLabel,\n buttonPlaceholderText,\n}: SettingsSidebarProps) {\n const handleSelectItem = useCallback(\n (item: string, projectId?: string) => {\n handleSelectSidebarItem(item, projectId);\n },\n [handleSelectSidebarItem],\n );\n\n const getProjectNameFromProjectId = useCallback(\n (projectId: string) => {\n const project = projectOptions.find((option) => option.projectId === projectId);\n return project ? project.projectName : projectId;\n },\n [projectOptions],\n );\n\n const getIsActive: (label: string) => boolean = useCallback(\n (label: string) => !selectedSidebarItem.projectId && label === selectedSidebarItem.label,\n [selectedSidebarItem],\n );\n\n return (\n \n \n \n \n {extensionsSidebarGroupLabel}\n \n \n \n {extensionLabels.map((label) => (\n \n handleSelectItem(label)}\n isActive={getIsActive(label)}\n >\n {label}\n \n \n ))}\n \n \n \n \n \n {projectsSidebarGroupLabel}\n \n \n option.projectId)}\n getOptionLabel={(projectId: ComboBoxOption) => {\n // This function expects a ComboBoxOption, but we know it is a string\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n return getProjectNameFromProjectId(projectId as string);\n }}\n buttonPlaceholder={buttonPlaceholderText}\n onChange={(projectId: string) => {\n const selectedProjectName = getProjectNameFromProjectId(projectId);\n handleSelectItem(selectedProjectName, projectId);\n }}\n value={selectedSidebarItem?.projectId ?? undefined}\n />\n \n \n \n \n );\n}\n","import { SidebarInset, SidebarProvider } from '@/components/shadcn-ui/sidebar';\nimport { PropsWithChildren } from 'react';\nimport SearchBar from '@/components/basics/search-bar.component';\nimport SettingsSidebar, { SettingsSidebarProps } from './settings-sidebar.component';\n\nexport type SettingsSidebarContentSearchProps = SettingsSidebarProps &\n PropsWithChildren & {\n /** Optional id for testing */\n id?: string;\n\n /** Handler to run when the value of the search bar changes */\n onSearch: (searchQuery: string) => void;\n };\n\nexport default function SettingsSidebarContentSearch({\n id,\n extensionLabels,\n projectOptions,\n children,\n handleSelectSidebarItem,\n selectedSidebarItem,\n onSearch,\n extensionsSidebarGroupLabel,\n projectsSidebarGroupLabel,\n buttonPlaceholderText,\n}: SettingsSidebarContentSearchProps) {\n return (\n
    \n
    \n \n
    \n \n \n {children}\n \n
    \n );\n}\n","import { Button } from '@/components/shadcn-ui/button';\nimport {\n Select,\n SelectContent,\n SelectGroup,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\nimport {\n Table,\n TableBody,\n TableCell,\n TableHead,\n TableHeader,\n TableRow,\n} from '@/components/shadcn-ui/table';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Canon } from '@sillsdev/scripture';\nimport {\n Cell,\n ColumnDef,\n flexRender,\n getCoreRowModel,\n getExpandedRowModel,\n getGroupedRowModel,\n getSortedRowModel,\n GroupingState,\n Row,\n RowSelectionState,\n SortingState,\n useReactTable,\n} from '@tanstack/react-table';\nimport '@/components/advanced/scripture-results-viewer/scripture-results-viewer.component.css';\nimport {\n compareScrRefs,\n formatScrRef,\n ScriptureSelection,\n scrRefToBBBCCCVVV,\n} from 'platform-bible-utils';\nimport { MouseEvent, useEffect, useMemo, useState } from 'react';\nimport { ChevronDown, ChevronLeft, ChevronRight } from 'lucide-react';\n\n/**\n * Information (e.g., a checking error or some other type of \"transient\" annotation) about something\n * noteworthy at a specific place in an instance of the Scriptures.\n */\nexport type ScriptureItemDetail = ScriptureSelection & {\n /**\n * Text of the error, note, etc. In the future, we might want to support something more than just\n * text so that a JSX element could be provided with a link or some other controls related to the\n * issue being reported.\n */\n detail: string;\n};\n\n/**\n * A uniquely identifiable source of results that can be displayed in the ScriptureResultsViewer.\n * Generally, the source will be a particular Scripture check, but there may be other types of\n * sources.\n */\nexport type ResultsSource = {\n /**\n * Uniquely identifies the source.\n *\n * @type {string}\n */\n id: string;\n\n /**\n * Name (potentially localized) of the source, suitable for display in the UI.\n *\n * @type {string}\n */\n displayName: string;\n};\n\nexport type ScriptureSrcItemDetail = ScriptureItemDetail & {\n /** Source/type of detail. Can be used for grouping. */\n source: ResultsSource;\n};\n\n/**\n * Represents a set of results keyed by Scripture reference. Generally, the source will be a\n * particular Scripture check, but this type also allows for other types of uniquely identifiable\n * sources.\n */\nexport type ResultsSet = {\n /**\n * The backing source associated with this set of results.\n *\n * @type {ResultsSource}\n */\n source: ResultsSource;\n\n /**\n * Array of Scripture item details (messages keyed by Scripture reference).\n *\n * @type {ScriptureItemDetail[]}\n */\n data: ScriptureItemDetail[];\n};\n\nconst scrBookColId = 'scrBook';\nconst scrRefColId = 'scrRef';\nconst typeColId = 'source';\nconst detailsColId = 'details';\n\nconst defaultScrRefColumnName = 'Scripture Reference';\nconst defaultScrBookGroupName = 'Scripture Book';\nconst defaultTypeColumnName = 'Type';\nconst defaultDetailsColumnName = 'Details';\n\nexport type ScriptureResultsViewerColumnInfo = {\n /** Optional header to display for the Reference column. Default value: 'Scripture Reference'. */\n scriptureReferenceColumnName?: string;\n\n /** Optional text to display to refer to the Scripture book group. Default value: 'Scripture Book'. */\n scriptureBookGroupName?: string;\n\n /** Optional header to display for the Type column. Default value: 'Type'. */\n typeColumnName?: string;\n\n /** Optional header to display for the Details column. Default value: 'Details' */\n detailsColumnName?: string;\n};\n\nexport type ScriptureResultsViewerProps = ScriptureResultsViewerColumnInfo & {\n /** Groups of ScriptureItemDetail objects from particular sources (e.g., Scripture checks) */\n sources: ResultsSet[];\n\n /** Flag indicating whether to display column headers. Default is false. */\n showColumnHeaders?: boolean;\n\n /** Flag indicating whether to display source column. Default is false. */\n showSourceColumn?: boolean;\n\n /** Callback function to notify when a row is selected */\n onRowSelected?: (selectedRow: ScriptureSrcItemDetail | undefined) => void;\n\n /** Text direction ltr or rtl */\n direction?: 'ltr' | 'rtl';\n};\n\nfunction getColumns(\n colInfo?: ScriptureResultsViewerColumnInfo,\n showSourceColumn?: boolean,\n): ColumnDef[] {\n const showSrcCol = showSourceColumn ?? false;\n return [\n {\n accessorFn: (row) =>\n `${Canon.bookNumberToId(row.start.bookNum)} ${row.start.chapterNum}:${row.start.verseNum}`,\n id: scrBookColId,\n header: colInfo?.scriptureReferenceColumnName ?? defaultScrRefColumnName,\n cell: (info) => {\n const row = info.row.original;\n if (info.row.getIsGrouped()) {\n return Canon.bookNumberToEnglishName(row.start.bookNum);\n }\n return info.row.groupingColumnId === scrBookColId ? formatScrRef(row.start) : undefined;\n },\n getGroupingValue: (row) => row.start.bookNum,\n sortingFn: (a, b) => {\n return compareScrRefs(a.original.start, b.original.start);\n },\n enableGrouping: true,\n },\n {\n accessorFn: (row) => formatScrRef(row.start),\n id: scrRefColId,\n header: undefined,\n cell: (info) => {\n const row = info.row.original;\n return info.row.getIsGrouped() ? undefined : formatScrRef(row.start);\n },\n sortingFn: (a, b) => {\n return compareScrRefs(a.original.start, b.original.start);\n },\n enableGrouping: false,\n },\n {\n accessorFn: (row) => row.source.displayName,\n id: typeColId,\n header: showSrcCol ? (colInfo?.typeColumnName ?? defaultTypeColumnName) : undefined,\n cell: (info) => (showSrcCol || info.row.getIsGrouped() ? info.getValue() : undefined),\n getGroupingValue: (row) => row.source.id,\n sortingFn: (a, b) =>\n a.original.source.displayName.localeCompare(b.original.source.displayName),\n enableGrouping: true,\n },\n {\n accessorFn: (row) => row.detail,\n id: detailsColId,\n header: colInfo?.detailsColumnName ?? defaultDetailsColumnName,\n cell: (info) => info.getValue(),\n enableGrouping: false,\n },\n ];\n}\n\nconst toRefOrRange = (scriptureSelection: ScriptureSelection) => {\n if (!('offset' in scriptureSelection.start))\n throw new Error('No offset available in range start');\n if (scriptureSelection.end && !('offset' in scriptureSelection.end))\n throw new Error('No offset available in range end');\n const { offset: offsetStart } = scriptureSelection.start;\n let offsetEnd: number = 0;\n if (scriptureSelection.end) ({ offset: offsetEnd } = scriptureSelection.end);\n if (\n !scriptureSelection.end ||\n compareScrRefs(scriptureSelection.start, scriptureSelection.end) === 0\n )\n return `${scrRefToBBBCCCVVV(scriptureSelection.start)}+${offsetStart}`;\n return `${scrRefToBBBCCCVVV(scriptureSelection.start)}+${offsetStart}-${scrRefToBBBCCCVVV(scriptureSelection.end)}+${offsetEnd}`;\n};\n\nconst getRowKey = (row: ScriptureSrcItemDetail) =>\n `${toRefOrRange({ start: row.start, end: row.end })} ${row.source.displayName} ${row.detail}`;\n\n/**\n * Component to display a combined list of detailed items from one or more sources, where the items\n * are keyed primarily by Scripture reference. This is particularly useful for displaying a list of\n * results from Scripture checks, but more generally could be used to display any \"results\" from any\n * source(s). The component allows for grouping by Scripture book, source, or both. By default, it\n * displays somewhat \"tree-like\" which allows it to be more horizontally compact and intuitive. But\n * it also has the option of displaying as a traditional table with column headings (with or without\n * the source column showing).\n */\nexport default function ScriptureResultsViewer({\n sources,\n showColumnHeaders = false,\n showSourceColumn = false,\n scriptureReferenceColumnName,\n scriptureBookGroupName,\n typeColumnName,\n detailsColumnName,\n onRowSelected,\n direction = 'ltr',\n}: ScriptureResultsViewerProps) {\n const [grouping, setGrouping] = useState([]);\n const [sorting, setSorting] = useState([{ id: scrBookColId, desc: false }]);\n const [rowSelection, setRowSelection] = useState({});\n\n const scriptureResults = useMemo(\n () =>\n sources.flatMap((source) => {\n return source.data.map((item) => ({\n ...item,\n source: source.source,\n }));\n }),\n [sources],\n );\n\n const columns = useMemo(\n () =>\n getColumns(\n {\n scriptureReferenceColumnName,\n typeColumnName,\n detailsColumnName,\n },\n showSourceColumn,\n ),\n [scriptureReferenceColumnName, typeColumnName, detailsColumnName, showSourceColumn],\n );\n\n useEffect(() => {\n // Ensure sorting is applied correctly when grouped by type\n if (grouping.includes(typeColId)) {\n setSorting([\n { id: typeColId, desc: false },\n { id: scrBookColId, desc: false },\n ]);\n } else {\n setSorting([{ id: scrBookColId, desc: false }]);\n }\n }, [grouping]);\n\n const table = useReactTable({\n data: scriptureResults,\n columns,\n state: {\n grouping,\n sorting,\n rowSelection,\n },\n onGroupingChange: setGrouping,\n onSortingChange: setSorting,\n onRowSelectionChange: setRowSelection,\n getExpandedRowModel: getExpandedRowModel(),\n getGroupedRowModel: getGroupedRowModel(),\n getCoreRowModel: getCoreRowModel(),\n getSortedRowModel: getSortedRowModel(),\n getRowId: getRowKey,\n autoResetExpanded: false,\n enableMultiRowSelection: false,\n enableSubRowSelection: false,\n });\n\n useEffect(() => {\n if (onRowSelected) {\n const selectedRows = table.getSelectedRowModel().rowsById;\n const keys = Object.keys(selectedRows);\n if (keys.length === 1) {\n const selectedRow = scriptureResults.find((row) => getRowKey(row) === keys[0]) || undefined;\n if (selectedRow) onRowSelected(selectedRow);\n }\n }\n }, [rowSelection, scriptureResults, onRowSelected, table]);\n\n // Define possible grouping options\n const scrBookGroupName = scriptureBookGroupName ?? defaultScrBookGroupName;\n const typeGroupName = typeColumnName ?? defaultTypeColumnName;\n\n const groupingOptions = [\n { label: 'No Grouping', value: [] },\n { label: `Group by ${scrBookGroupName}`, value: [scrBookColId] },\n { label: `Group by ${typeGroupName}`, value: [typeColId] },\n {\n label: `Group by ${scrBookGroupName} and ${typeGroupName}`,\n value: [scrBookColId, typeColId],\n },\n {\n label: `Group by ${typeGroupName} and ${scrBookGroupName}`,\n value: [typeColId, scrBookColId],\n },\n ];\n\n const handleSelectChange = (selectedGrouping: string) => {\n setGrouping(JSON.parse(selectedGrouping));\n };\n\n const handleRowClick = (row: Row, event: MouseEvent) => {\n if (!row.getIsGrouped() && !row.getIsSelected()) {\n row.getToggleSelectedHandler()(event);\n }\n };\n\n const getEvenOrOddBandingStyle = (row: Row, index: number) => {\n if (row.getIsGrouped()) return '';\n // UX has now said they don't think they want banding. I'm leaving in the code to\n // set even and odd styles, but there's nothing in the CSS to style them differently.\n // The \"even\" style used to also have tw-bg-neutral-300 (along with even) to create\n // a visual banding effect. That could be added back in if UX changes the decision.\n return cn('banded-row', index % 2 === 0 ? 'even' : 'odd');\n };\n\n const getIndent = (\n groupingState: GroupingState,\n row: Row,\n cell: Cell,\n ) => {\n if (groupingState?.length === 0 || row.depth < cell.column.getGroupedIndex()) return undefined;\n if (row.getIsGrouped()) {\n switch (row.depth) {\n case 1:\n return 'tw-ps-4';\n default:\n return undefined;\n }\n }\n switch (row.depth) {\n case 1:\n return 'tw-ps-8';\n case 2:\n return 'tw-ps-12';\n default:\n return undefined;\n }\n };\n\n return (\n
    \n {!showColumnHeaders && (\n {\n handleSelectChange(value);\n }}\n >\n \n \n \n \n \n {groupingOptions.map((option) => (\n \n {option.label}\n \n ))}\n \n \n \n )}\n \n {showColumnHeaders && (\n \n {table.getHeaderGroups().map((headerGroup) => (\n \n {headerGroup.headers\n .filter((h) => h.column.columnDef.header)\n .map((header) => (\n /* For sticky column headers to work, we probably need to change the default definition of the shadcn Table component. See https://github.com/shadcn-ui/ui/issues/1151 */\n \n {header.isPlaceholder ? undefined : (\n
    \n {header.column.getCanGroup() ? (\n \n {header.column.getIsGrouped() ? `🛑` : `👊 `}\n \n ) : undefined}{' '}\n {flexRender(header.column.columnDef.header, header.getContext())}\n
    \n )}\n
    \n ))}\n
    \n ))}\n
    \n )}\n \n {table.getRowModel().rows.map((row, rowIndex) => {\n return (\n handleRowClick(row, event)}\n >\n {row.getVisibleCells().map((cell) => {\n if (\n cell.getIsPlaceholder() ||\n (cell.column.columnDef.enableGrouping &&\n !cell.getIsGrouped() &&\n (cell.column.columnDef.id !== typeColId || !showSourceColumn))\n )\n return undefined;\n return (\n \n {(() => {\n if (cell.getIsGrouped()) {\n return (\n \n {row.getIsExpanded() && }\n {!row.getIsExpanded() &&\n (direction === 'ltr' ? : )}{' '}\n {flexRender(cell.column.columnDef.cell, cell.getContext())} (\n {row.subRows.length})\n \n );\n }\n\n // if (cell.getIsAggregated()) {\n // flexRender(\n // cell.column.columnDef.aggregatedCell ?? cell.column.columnDef.cell,\n // cell.getContext(),\n // );\n // }\n\n return flexRender(cell.column.columnDef.cell, cell.getContext());\n })()}\n \n );\n })}\n \n );\n })}\n \n
    \n
    \n );\n}\n","import {\n getLocalizeKeyForScrollGroupId,\n LanguageStrings,\n ScrollGroupId,\n} from 'platform-bible-utils';\nimport {\n Select,\n SelectContent,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\n\nconst DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS = {\n [getLocalizeKeyForScrollGroupId('undefined')]: 'Ø',\n [getLocalizeKeyForScrollGroupId(0)]: 'A',\n [getLocalizeKeyForScrollGroupId(1)]: 'B',\n [getLocalizeKeyForScrollGroupId(2)]: 'C',\n [getLocalizeKeyForScrollGroupId(3)]: 'D',\n [getLocalizeKeyForScrollGroupId(4)]: 'E',\n [getLocalizeKeyForScrollGroupId(5)]: 'F',\n [getLocalizeKeyForScrollGroupId(6)]: 'G',\n [getLocalizeKeyForScrollGroupId(7)]: 'H',\n [getLocalizeKeyForScrollGroupId(8)]: 'I',\n [getLocalizeKeyForScrollGroupId(9)]: 'J',\n [getLocalizeKeyForScrollGroupId(10)]: 'K',\n [getLocalizeKeyForScrollGroupId(11)]: 'L',\n [getLocalizeKeyForScrollGroupId(12)]: 'M',\n [getLocalizeKeyForScrollGroupId(13)]: 'N',\n [getLocalizeKeyForScrollGroupId(14)]: 'O',\n [getLocalizeKeyForScrollGroupId(15)]: 'P',\n [getLocalizeKeyForScrollGroupId(16)]: 'Q',\n [getLocalizeKeyForScrollGroupId(17)]: 'R',\n [getLocalizeKeyForScrollGroupId(18)]: 'S',\n [getLocalizeKeyForScrollGroupId(19)]: 'T',\n [getLocalizeKeyForScrollGroupId(20)]: 'U',\n [getLocalizeKeyForScrollGroupId(21)]: 'V',\n [getLocalizeKeyForScrollGroupId(22)]: 'W',\n [getLocalizeKeyForScrollGroupId(23)]: 'X',\n [getLocalizeKeyForScrollGroupId(24)]: 'Y',\n [getLocalizeKeyForScrollGroupId(25)]: 'Z',\n};\n\nexport type ScrollGroupSelectorProps = {\n /**\n * List of scroll group ids to show to the user. Either a {@link ScrollGroupId} or `undefined` for\n * no scroll group\n */\n availableScrollGroupIds: (ScrollGroupId | undefined)[];\n /** Currently selected scroll group id. `undefined` for no scroll group */\n scrollGroupId: ScrollGroupId | undefined;\n /** Callback function run when the user tries to change the scroll group id */\n onChangeScrollGroupId: (newScrollGroupId: ScrollGroupId | undefined) => void;\n /**\n * Localized strings to use for displaying scroll group ids. Must be an object whose keys are\n * `getLocalizeKeyForScrollGroupId(scrollGroupId)` for all scroll group ids (and `undefined` if\n * included) in {@link ScrollGroupSelectorProps.availableScrollGroupIds} and whose values are the\n * localized strings to use for those scroll group ids.\n *\n * Defaults to English localizations of English alphabet for scroll groups 0-25 (e.g. 0 is A) and\n * Ø for `undefined`. Will fill in any that are not provided with these English localizations.\n * Also, if any values match the keys, the English localization will be used. This is useful in\n * case you want to pass in a temporary version of the localized strings while your localized\n * strings load.\n *\n * @example\n *\n * ```typescript\n * const myScrollGroupIdLocalizedStrings = {\n * [getLocalizeKeyForScrollGroupId('undefined')]: 'Ø',\n * [getLocalizeKeyForScrollGroupId(0)]: 'A',\n * [getLocalizeKeyForScrollGroupId(1)]: 'B',\n * [getLocalizeKeyForScrollGroupId(2)]: 'C',\n * [getLocalizeKeyForScrollGroupId(3)]: 'D',\n * [getLocalizeKeyForScrollGroupId(4)]: 'E',\n * };\n * ```\n *\n * @example\n *\n * ```tsx\n * const availableScrollGroupIds = [undefined, 0, 1, 2, 3, 4];\n *\n * const localizeKeys = getLocalizeKeysForScrollGroupIds();\n *\n * const [localizedStrings] = useLocalizedStrings(localizeKeys);\n *\n * ...\n *\n * \n * ```\n */\n localizedStrings?: LanguageStrings;\n};\n\n/** Selector component for choosing a scroll group */\nexport default function ScrollGroupSelector({\n availableScrollGroupIds,\n scrollGroupId,\n onChangeScrollGroupId,\n localizedStrings = {},\n}: ScrollGroupSelectorProps) {\n const localizedStringsDefaulted = {\n ...DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS,\n ...Object.fromEntries(\n Object.entries(localizedStrings).map(\n ([localizedStringKey, localizedStringValue]: [string, string]) => [\n localizedStringKey,\n localizedStringKey === localizedStringValue &&\n localizedStringKey in DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS\n ? DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS[localizedStringKey]\n : localizedStringValue,\n ],\n ),\n ),\n };\n return (\n \n onChangeScrollGroupId(\n newScrollGroupString === 'undefined' ? undefined : parseInt(newScrollGroupString, 10),\n )\n }\n >\n \n \n \n \n {availableScrollGroupIds.map((scrollGroupOptionId) => (\n \n {localizedStringsDefaulted[getLocalizeKeyForScrollGroupId(scrollGroupOptionId)]}\n \n ))}\n \n \n );\n}\n","import { PropsWithChildren } from 'react';\nimport { Separator } from '@/components/shadcn-ui/separator';\n\n/** Props for the SettingsList component, currently just children */\ntype SettingsListProps = PropsWithChildren;\n\n/**\n * SettingsList component is a wrapper for list items. Rendered with a formatted div\n *\n * @param children To populate the list with\n * @returns Formatted div encompassing the children\n */\nexport function SettingsList({ children }: SettingsListProps) {\n return
    {children}
    ;\n}\n\n/** Props for SettingsListItem component */\ntype SettingsListItemProps = PropsWithChildren & {\n /** Primary text of the list item */\n primary: string;\n\n /** Optional text of the list item */\n secondary?: string | undefined;\n\n /** Optional boolean to display a message if the children aren't loaded yet. Defaults to false */\n isLoading?: boolean;\n\n /** Optional message to display if isLoading */\n loadingMessage?: string;\n};\n\n/**\n * SettingsListItem component is a common list item. Rendered with a formatted div\n *\n * @param primary Primary text of the list item\n * @param secondary Optional secondary text of the list item\n * @param isLoading Optional, to display a message if the action component isn't generated yet,\n * defaults to false\n * @param children The action component(s) to provide for this item\n * @param loadingMessage Optional, message to display if isLoading\n * @returns Formatted div encompassing the list item content\n */\nexport function SettingsListItem({\n primary,\n secondary,\n children,\n isLoading = false,\n loadingMessage,\n}: SettingsListItemProps) {\n return (\n
    \n
    \n

    {primary}

    \n

    \n {secondary}\n

    \n
    \n\n {isLoading ? (\n

    {loadingMessage}

    \n ) : (\n
    {children}
    \n )}\n
    \n );\n}\n\n/** Props for SettingsListHeader component */\ntype SettingsListHeaderProps = {\n /** The primary text of the list header */\n primary: string;\n\n /** Optional secondary text of the list header */\n secondary?: string | undefined;\n\n /** Optional boolean to include a separator underneath the secondary text. Defaults to false */\n includeSeparator?: boolean;\n};\n\n/**\n * SettingsListHeader component displays text above the list\n *\n * @param primary The primary text of the list header\n * @param secondary Optional secondary text of the list header\n * @param includeSeparator Optional boolean to include a separator underneath the secondary text.\n * Defaults to false\n * @returns Formatted div with list header content\n */\nexport function SettingsListHeader({\n primary,\n secondary,\n includeSeparator = false,\n}: SettingsListHeaderProps) {\n return (\n
    \n
    \n

    {primary}

    \n

    {secondary}

    \n
    \n {includeSeparator ? : ''}\n
    \n );\n}\n","import Checkbox from '@/components/shadcn-ui/checkbox';\nimport { Label } from '@/components/shadcn-ui/label';\n\nexport type ChecklistProps = {\n /** Optional string representing the id attribute of the Checklist */\n id?: string;\n /** Optional string representing CSS class name(s) for styling */\n className?: string;\n /** Array of strings representing the checkable items */\n listItems: string[];\n /** Array of strings representing the checked items */\n selectedListItems: string[];\n /**\n * Function that is called when a checkbox item is selected or deselected\n *\n * @param item The string description for this item\n * @param selected True if selected, false if not selected\n */\n handleSelectListItem: (item: string, selected: boolean) => void;\n\n /**\n * Optional function creates a label for a provided checkable item\n *\n * @param item The item for which a label is to be created\n * @returns A string representing the label text for the checkbox associated with that item\n */\n createLabel?: (item: string) => string;\n};\n\n/** Renders a list of checkboxes. Each checkbox corresponds to an item from the `listItems` array. */\nexport default function Checklist({\n id,\n className,\n listItems,\n selectedListItems,\n handleSelectListItem,\n createLabel,\n}: ChecklistProps) {\n return (\n
    \n {listItems.map((item) => (\n
    \n handleSelectListItem(item, value)}\n />\n \n
    \n ))}\n
    \n );\n}\n","function _interopRequireDefault(obj) {\n return obj && obj.__esModule ? obj : {\n \"default\": obj\n };\n}\nmodule.exports = _interopRequireDefault, module.exports.__esModule = true, module.exports[\"default\"] = module.exports;","export default function chainPropTypes(propType1, propType2) {\n if (process.env.NODE_ENV === 'production') {\n return () => null;\n }\n return function validate(...args) {\n return propType1(...args) || propType2(...args);\n };\n}","export default function _extends() {\n _extends = Object.assign ? Object.assign.bind() : function (target) {\n for (var i = 1; i < arguments.length; i++) {\n var source = arguments[i];\n for (var key in source) {\n if (Object.prototype.hasOwnProperty.call(source, key)) {\n target[key] = source[key];\n }\n }\n }\n return target;\n };\n return _extends.apply(this, arguments);\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\n// https://github.com/sindresorhus/is-plain-obj/blob/main/index.js\nexport function isPlainObject(item) {\n if (typeof item !== 'object' || item === null) {\n return false;\n }\n const prototype = Object.getPrototypeOf(item);\n return (prototype === null || prototype === Object.prototype || Object.getPrototypeOf(prototype) === null) && !(Symbol.toStringTag in item) && !(Symbol.iterator in item);\n}\nfunction deepClone(source) {\n if (!isPlainObject(source)) {\n return source;\n }\n const output = {};\n Object.keys(source).forEach(key => {\n output[key] = deepClone(source[key]);\n });\n return output;\n}\nexport default function deepmerge(target, source, options = {\n clone: true\n}) {\n const output = options.clone ? _extends({}, target) : target;\n if (isPlainObject(target) && isPlainObject(source)) {\n Object.keys(source).forEach(key => {\n // Avoid prototype pollution\n if (key === '__proto__') {\n return;\n }\n if (isPlainObject(source[key]) && key in target && isPlainObject(target[key])) {\n // Since `output` is a clone of `target` and we have narrowed `target` in this block we can cast to the same type.\n output[key] = deepmerge(target[key], source[key], options);\n } else if (options.clone) {\n output[key] = isPlainObject(source[key]) ? deepClone(source[key]) : source[key];\n } else {\n output[key] = source[key];\n }\n });\n }\n return output;\n}","/** @license React v16.13.1\n * react-is.production.min.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';var b=\"function\"===typeof Symbol&&Symbol.for,c=b?Symbol.for(\"react.element\"):60103,d=b?Symbol.for(\"react.portal\"):60106,e=b?Symbol.for(\"react.fragment\"):60107,f=b?Symbol.for(\"react.strict_mode\"):60108,g=b?Symbol.for(\"react.profiler\"):60114,h=b?Symbol.for(\"react.provider\"):60109,k=b?Symbol.for(\"react.context\"):60110,l=b?Symbol.for(\"react.async_mode\"):60111,m=b?Symbol.for(\"react.concurrent_mode\"):60111,n=b?Symbol.for(\"react.forward_ref\"):60112,p=b?Symbol.for(\"react.suspense\"):60113,q=b?\nSymbol.for(\"react.suspense_list\"):60120,r=b?Symbol.for(\"react.memo\"):60115,t=b?Symbol.for(\"react.lazy\"):60116,v=b?Symbol.for(\"react.block\"):60121,w=b?Symbol.for(\"react.fundamental\"):60117,x=b?Symbol.for(\"react.responder\"):60118,y=b?Symbol.for(\"react.scope\"):60119;\nfunction z(a){if(\"object\"===typeof a&&null!==a){var u=a.$$typeof;switch(u){case c:switch(a=a.type,a){case l:case m:case e:case g:case f:case p:return a;default:switch(a=a&&a.$$typeof,a){case k:case n:case t:case r:case h:return a;default:return u}}case d:return u}}}function A(a){return z(a)===m}exports.AsyncMode=l;exports.ConcurrentMode=m;exports.ContextConsumer=k;exports.ContextProvider=h;exports.Element=c;exports.ForwardRef=n;exports.Fragment=e;exports.Lazy=t;exports.Memo=r;exports.Portal=d;\nexports.Profiler=g;exports.StrictMode=f;exports.Suspense=p;exports.isAsyncMode=function(a){return A(a)||z(a)===l};exports.isConcurrentMode=A;exports.isContextConsumer=function(a){return z(a)===k};exports.isContextProvider=function(a){return z(a)===h};exports.isElement=function(a){return\"object\"===typeof a&&null!==a&&a.$$typeof===c};exports.isForwardRef=function(a){return z(a)===n};exports.isFragment=function(a){return z(a)===e};exports.isLazy=function(a){return z(a)===t};\nexports.isMemo=function(a){return z(a)===r};exports.isPortal=function(a){return z(a)===d};exports.isProfiler=function(a){return z(a)===g};exports.isStrictMode=function(a){return z(a)===f};exports.isSuspense=function(a){return z(a)===p};\nexports.isValidElementType=function(a){return\"string\"===typeof a||\"function\"===typeof a||a===e||a===m||a===g||a===f||a===p||a===q||\"object\"===typeof a&&null!==a&&(a.$$typeof===t||a.$$typeof===r||a.$$typeof===h||a.$$typeof===k||a.$$typeof===n||a.$$typeof===w||a.$$typeof===x||a.$$typeof===y||a.$$typeof===v)};exports.typeOf=z;\n","/** @license React v16.13.1\n * react-is.development.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\n\n\nif (process.env.NODE_ENV !== \"production\") {\n (function() {\n'use strict';\n\n// The Symbol used to tag the ReactElement-like types. If there is no native Symbol\n// nor polyfill, then a plain number is used for performance.\nvar hasSymbol = typeof Symbol === 'function' && Symbol.for;\nvar REACT_ELEMENT_TYPE = hasSymbol ? Symbol.for('react.element') : 0xeac7;\nvar REACT_PORTAL_TYPE = hasSymbol ? Symbol.for('react.portal') : 0xeaca;\nvar REACT_FRAGMENT_TYPE = hasSymbol ? Symbol.for('react.fragment') : 0xeacb;\nvar REACT_STRICT_MODE_TYPE = hasSymbol ? Symbol.for('react.strict_mode') : 0xeacc;\nvar REACT_PROFILER_TYPE = hasSymbol ? Symbol.for('react.profiler') : 0xead2;\nvar REACT_PROVIDER_TYPE = hasSymbol ? Symbol.for('react.provider') : 0xeacd;\nvar REACT_CONTEXT_TYPE = hasSymbol ? Symbol.for('react.context') : 0xeace; // TODO: We don't use AsyncMode or ConcurrentMode anymore. They were temporary\n// (unstable) APIs that have been removed. Can we remove the symbols?\n\nvar REACT_ASYNC_MODE_TYPE = hasSymbol ? Symbol.for('react.async_mode') : 0xeacf;\nvar REACT_CONCURRENT_MODE_TYPE = hasSymbol ? Symbol.for('react.concurrent_mode') : 0xeacf;\nvar REACT_FORWARD_REF_TYPE = hasSymbol ? Symbol.for('react.forward_ref') : 0xead0;\nvar REACT_SUSPENSE_TYPE = hasSymbol ? Symbol.for('react.suspense') : 0xead1;\nvar REACT_SUSPENSE_LIST_TYPE = hasSymbol ? Symbol.for('react.suspense_list') : 0xead8;\nvar REACT_MEMO_TYPE = hasSymbol ? Symbol.for('react.memo') : 0xead3;\nvar REACT_LAZY_TYPE = hasSymbol ? Symbol.for('react.lazy') : 0xead4;\nvar REACT_BLOCK_TYPE = hasSymbol ? Symbol.for('react.block') : 0xead9;\nvar REACT_FUNDAMENTAL_TYPE = hasSymbol ? Symbol.for('react.fundamental') : 0xead5;\nvar REACT_RESPONDER_TYPE = hasSymbol ? Symbol.for('react.responder') : 0xead6;\nvar REACT_SCOPE_TYPE = hasSymbol ? Symbol.for('react.scope') : 0xead7;\n\nfunction isValidElementType(type) {\n return typeof type === 'string' || typeof type === 'function' || // Note: its typeof might be other than 'symbol' or 'number' if it's a polyfill.\n type === REACT_FRAGMENT_TYPE || type === REACT_CONCURRENT_MODE_TYPE || type === REACT_PROFILER_TYPE || type === REACT_STRICT_MODE_TYPE || type === REACT_SUSPENSE_TYPE || type === REACT_SUSPENSE_LIST_TYPE || typeof type === 'object' && type !== null && (type.$$typeof === REACT_LAZY_TYPE || type.$$typeof === REACT_MEMO_TYPE || type.$$typeof === REACT_PROVIDER_TYPE || type.$$typeof === REACT_CONTEXT_TYPE || type.$$typeof === REACT_FORWARD_REF_TYPE || type.$$typeof === REACT_FUNDAMENTAL_TYPE || type.$$typeof === REACT_RESPONDER_TYPE || type.$$typeof === REACT_SCOPE_TYPE || type.$$typeof === REACT_BLOCK_TYPE);\n}\n\nfunction typeOf(object) {\n if (typeof object === 'object' && object !== null) {\n var $$typeof = object.$$typeof;\n\n switch ($$typeof) {\n case REACT_ELEMENT_TYPE:\n var type = object.type;\n\n switch (type) {\n case REACT_ASYNC_MODE_TYPE:\n case REACT_CONCURRENT_MODE_TYPE:\n case REACT_FRAGMENT_TYPE:\n case REACT_PROFILER_TYPE:\n case REACT_STRICT_MODE_TYPE:\n case REACT_SUSPENSE_TYPE:\n return type;\n\n default:\n var $$typeofType = type && type.$$typeof;\n\n switch ($$typeofType) {\n case REACT_CONTEXT_TYPE:\n case REACT_FORWARD_REF_TYPE:\n case REACT_LAZY_TYPE:\n case REACT_MEMO_TYPE:\n case REACT_PROVIDER_TYPE:\n return $$typeofType;\n\n default:\n return $$typeof;\n }\n\n }\n\n case REACT_PORTAL_TYPE:\n return $$typeof;\n }\n }\n\n return undefined;\n} // AsyncMode is deprecated along with isAsyncMode\n\nvar AsyncMode = REACT_ASYNC_MODE_TYPE;\nvar ConcurrentMode = REACT_CONCURRENT_MODE_TYPE;\nvar ContextConsumer = REACT_CONTEXT_TYPE;\nvar ContextProvider = REACT_PROVIDER_TYPE;\nvar Element = REACT_ELEMENT_TYPE;\nvar ForwardRef = REACT_FORWARD_REF_TYPE;\nvar Fragment = REACT_FRAGMENT_TYPE;\nvar Lazy = REACT_LAZY_TYPE;\nvar Memo = REACT_MEMO_TYPE;\nvar Portal = REACT_PORTAL_TYPE;\nvar Profiler = REACT_PROFILER_TYPE;\nvar StrictMode = REACT_STRICT_MODE_TYPE;\nvar Suspense = REACT_SUSPENSE_TYPE;\nvar hasWarnedAboutDeprecatedIsAsyncMode = false; // AsyncMode should be deprecated\n\nfunction isAsyncMode(object) {\n {\n if (!hasWarnedAboutDeprecatedIsAsyncMode) {\n hasWarnedAboutDeprecatedIsAsyncMode = true; // Using console['warn'] to evade Babel and ESLint\n\n console['warn']('The ReactIs.isAsyncMode() alias has been deprecated, ' + 'and will be removed in React 17+. Update your code to use ' + 'ReactIs.isConcurrentMode() instead. It has the exact same API.');\n }\n }\n\n return isConcurrentMode(object) || typeOf(object) === REACT_ASYNC_MODE_TYPE;\n}\nfunction isConcurrentMode(object) {\n return typeOf(object) === REACT_CONCURRENT_MODE_TYPE;\n}\nfunction isContextConsumer(object) {\n return typeOf(object) === REACT_CONTEXT_TYPE;\n}\nfunction isContextProvider(object) {\n return typeOf(object) === REACT_PROVIDER_TYPE;\n}\nfunction isElement(object) {\n return typeof object === 'object' && object !== null && object.$$typeof === REACT_ELEMENT_TYPE;\n}\nfunction isForwardRef(object) {\n return typeOf(object) === REACT_FORWARD_REF_TYPE;\n}\nfunction isFragment(object) {\n return typeOf(object) === REACT_FRAGMENT_TYPE;\n}\nfunction isLazy(object) {\n return typeOf(object) === REACT_LAZY_TYPE;\n}\nfunction isMemo(object) {\n return typeOf(object) === REACT_MEMO_TYPE;\n}\nfunction isPortal(object) {\n return typeOf(object) === REACT_PORTAL_TYPE;\n}\nfunction isProfiler(object) {\n return typeOf(object) === REACT_PROFILER_TYPE;\n}\nfunction isStrictMode(object) {\n return typeOf(object) === REACT_STRICT_MODE_TYPE;\n}\nfunction isSuspense(object) {\n return typeOf(object) === REACT_SUSPENSE_TYPE;\n}\n\nexports.AsyncMode = AsyncMode;\nexports.ConcurrentMode = ConcurrentMode;\nexports.ContextConsumer = ContextConsumer;\nexports.ContextProvider = ContextProvider;\nexports.Element = Element;\nexports.ForwardRef = ForwardRef;\nexports.Fragment = Fragment;\nexports.Lazy = Lazy;\nexports.Memo = Memo;\nexports.Portal = Portal;\nexports.Profiler = Profiler;\nexports.StrictMode = StrictMode;\nexports.Suspense = Suspense;\nexports.isAsyncMode = isAsyncMode;\nexports.isConcurrentMode = isConcurrentMode;\nexports.isContextConsumer = isContextConsumer;\nexports.isContextProvider = isContextProvider;\nexports.isElement = isElement;\nexports.isForwardRef = isForwardRef;\nexports.isFragment = isFragment;\nexports.isLazy = isLazy;\nexports.isMemo = isMemo;\nexports.isPortal = isPortal;\nexports.isProfiler = isProfiler;\nexports.isStrictMode = isStrictMode;\nexports.isSuspense = isSuspense;\nexports.isValidElementType = isValidElementType;\nexports.typeOf = typeOf;\n })();\n}\n","'use strict';\n\nif (process.env.NODE_ENV === 'production') {\n module.exports = require('./cjs/react-is.production.min.js');\n} else {\n module.exports = require('./cjs/react-is.development.js');\n}\n","/*\nobject-assign\n(c) Sindre Sorhus\n@license MIT\n*/\n\n'use strict';\n/* eslint-disable no-unused-vars */\nvar getOwnPropertySymbols = Object.getOwnPropertySymbols;\nvar hasOwnProperty = Object.prototype.hasOwnProperty;\nvar propIsEnumerable = Object.prototype.propertyIsEnumerable;\n\nfunction toObject(val) {\n\tif (val === null || val === undefined) {\n\t\tthrow new TypeError('Object.assign cannot be called with null or undefined');\n\t}\n\n\treturn Object(val);\n}\n\nfunction shouldUseNative() {\n\ttry {\n\t\tif (!Object.assign) {\n\t\t\treturn false;\n\t\t}\n\n\t\t// Detect buggy property enumeration order in older V8 versions.\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=4118\n\t\tvar test1 = new String('abc'); // eslint-disable-line no-new-wrappers\n\t\ttest1[5] = 'de';\n\t\tif (Object.getOwnPropertyNames(test1)[0] === '5') {\n\t\t\treturn false;\n\t\t}\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=3056\n\t\tvar test2 = {};\n\t\tfor (var i = 0; i < 10; i++) {\n\t\t\ttest2['_' + String.fromCharCode(i)] = i;\n\t\t}\n\t\tvar order2 = Object.getOwnPropertyNames(test2).map(function (n) {\n\t\t\treturn test2[n];\n\t\t});\n\t\tif (order2.join('') !== '0123456789') {\n\t\t\treturn false;\n\t\t}\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=3056\n\t\tvar test3 = {};\n\t\t'abcdefghijklmnopqrst'.split('').forEach(function (letter) {\n\t\t\ttest3[letter] = letter;\n\t\t});\n\t\tif (Object.keys(Object.assign({}, test3)).join('') !==\n\t\t\t\t'abcdefghijklmnopqrst') {\n\t\t\treturn false;\n\t\t}\n\n\t\treturn true;\n\t} catch (err) {\n\t\t// We don't expect any of the above to throw, but better to be safe.\n\t\treturn false;\n\t}\n}\n\nmodule.exports = shouldUseNative() ? Object.assign : function (target, source) {\n\tvar from;\n\tvar to = toObject(target);\n\tvar symbols;\n\n\tfor (var s = 1; s < arguments.length; s++) {\n\t\tfrom = Object(arguments[s]);\n\n\t\tfor (var key in from) {\n\t\t\tif (hasOwnProperty.call(from, key)) {\n\t\t\t\tto[key] = from[key];\n\t\t\t}\n\t\t}\n\n\t\tif (getOwnPropertySymbols) {\n\t\t\tsymbols = getOwnPropertySymbols(from);\n\t\t\tfor (var i = 0; i < symbols.length; i++) {\n\t\t\t\tif (propIsEnumerable.call(from, symbols[i])) {\n\t\t\t\t\tto[symbols[i]] = from[symbols[i]];\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\n\treturn to;\n};\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar ReactPropTypesSecret = 'SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED';\n\nmodule.exports = ReactPropTypesSecret;\n","module.exports = Function.call.bind(Object.prototype.hasOwnProperty);\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar printWarning = function() {};\n\nif (process.env.NODE_ENV !== 'production') {\n var ReactPropTypesSecret = require('./lib/ReactPropTypesSecret');\n var loggedTypeFailures = {};\n var has = require('./lib/has');\n\n printWarning = function(text) {\n var message = 'Warning: ' + text;\n if (typeof console !== 'undefined') {\n console.error(message);\n }\n try {\n // --- Welcome to debugging React ---\n // This error was thrown as a convenience so that you can use this stack\n // to find the callsite that caused this warning to fire.\n throw new Error(message);\n } catch (x) { /**/ }\n };\n}\n\n/**\n * Assert that the values match with the type specs.\n * Error messages are memorized and will only be shown once.\n *\n * @param {object} typeSpecs Map of name to a ReactPropType\n * @param {object} values Runtime values that need to be type-checked\n * @param {string} location e.g. \"prop\", \"context\", \"child context\"\n * @param {string} componentName Name of the component for error messages.\n * @param {?Function} getStack Returns the component stack.\n * @private\n */\nfunction checkPropTypes(typeSpecs, values, location, componentName, getStack) {\n if (process.env.NODE_ENV !== 'production') {\n for (var typeSpecName in typeSpecs) {\n if (has(typeSpecs, typeSpecName)) {\n var error;\n // Prop type validation may throw. In case they do, we don't want to\n // fail the render phase where it didn't fail before. So we log it.\n // After these have been cleaned up, we'll let them throw.\n try {\n // This is intentionally an invariant that gets caught. It's the same\n // behavior as without this statement except with a better message.\n if (typeof typeSpecs[typeSpecName] !== 'function') {\n var err = Error(\n (componentName || 'React class') + ': ' + location + ' type `' + typeSpecName + '` is invalid; ' +\n 'it must be a function, usually from the `prop-types` package, but received `' + typeof typeSpecs[typeSpecName] + '`.' +\n 'This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.'\n );\n err.name = 'Invariant Violation';\n throw err;\n }\n error = typeSpecs[typeSpecName](values, typeSpecName, componentName, location, null, ReactPropTypesSecret);\n } catch (ex) {\n error = ex;\n }\n if (error && !(error instanceof Error)) {\n printWarning(\n (componentName || 'React class') + ': type specification of ' +\n location + ' `' + typeSpecName + '` is invalid; the type checker ' +\n 'function must return `null` or an `Error` but returned a ' + typeof error + '. ' +\n 'You may have forgotten to pass an argument to the type checker ' +\n 'creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and ' +\n 'shape all require an argument).'\n );\n }\n if (error instanceof Error && !(error.message in loggedTypeFailures)) {\n // Only monitor this failure once because there tends to be a lot of the\n // same error.\n loggedTypeFailures[error.message] = true;\n\n var stack = getStack ? getStack() : '';\n\n printWarning(\n 'Failed ' + location + ' type: ' + error.message + (stack != null ? stack : '')\n );\n }\n }\n }\n }\n}\n\n/**\n * Resets warning cache when testing.\n *\n * @private\n */\ncheckPropTypes.resetWarningCache = function() {\n if (process.env.NODE_ENV !== 'production') {\n loggedTypeFailures = {};\n }\n}\n\nmodule.exports = checkPropTypes;\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar ReactIs = require('react-is');\nvar assign = require('object-assign');\n\nvar ReactPropTypesSecret = require('./lib/ReactPropTypesSecret');\nvar has = require('./lib/has');\nvar checkPropTypes = require('./checkPropTypes');\n\nvar printWarning = function() {};\n\nif (process.env.NODE_ENV !== 'production') {\n printWarning = function(text) {\n var message = 'Warning: ' + text;\n if (typeof console !== 'undefined') {\n console.error(message);\n }\n try {\n // --- Welcome to debugging React ---\n // This error was thrown as a convenience so that you can use this stack\n // to find the callsite that caused this warning to fire.\n throw new Error(message);\n } catch (x) {}\n };\n}\n\nfunction emptyFunctionThatReturnsNull() {\n return null;\n}\n\nmodule.exports = function(isValidElement, throwOnDirectAccess) {\n /* global Symbol */\n var ITERATOR_SYMBOL = typeof Symbol === 'function' && Symbol.iterator;\n var FAUX_ITERATOR_SYMBOL = '@@iterator'; // Before Symbol spec.\n\n /**\n * Returns the iterator method function contained on the iterable object.\n *\n * Be sure to invoke the function with the iterable as context:\n *\n * var iteratorFn = getIteratorFn(myIterable);\n * if (iteratorFn) {\n * var iterator = iteratorFn.call(myIterable);\n * ...\n * }\n *\n * @param {?object} maybeIterable\n * @return {?function}\n */\n function getIteratorFn(maybeIterable) {\n var iteratorFn = maybeIterable && (ITERATOR_SYMBOL && maybeIterable[ITERATOR_SYMBOL] || maybeIterable[FAUX_ITERATOR_SYMBOL]);\n if (typeof iteratorFn === 'function') {\n return iteratorFn;\n }\n }\n\n /**\n * Collection of methods that allow declaration and validation of props that are\n * supplied to React components. Example usage:\n *\n * var Props = require('ReactPropTypes');\n * var MyArticle = React.createClass({\n * propTypes: {\n * // An optional string prop named \"description\".\n * description: Props.string,\n *\n * // A required enum prop named \"category\".\n * category: Props.oneOf(['News','Photos']).isRequired,\n *\n * // A prop named \"dialog\" that requires an instance of Dialog.\n * dialog: Props.instanceOf(Dialog).isRequired\n * },\n * render: function() { ... }\n * });\n *\n * A more formal specification of how these methods are used:\n *\n * type := array|bool|func|object|number|string|oneOf([...])|instanceOf(...)\n * decl := ReactPropTypes.{type}(.isRequired)?\n *\n * Each and every declaration produces a function with the same signature. This\n * allows the creation of custom validation functions. For example:\n *\n * var MyLink = React.createClass({\n * propTypes: {\n * // An optional string or URI prop named \"href\".\n * href: function(props, propName, componentName) {\n * var propValue = props[propName];\n * if (propValue != null && typeof propValue !== 'string' &&\n * !(propValue instanceof URI)) {\n * return new Error(\n * 'Expected a string or an URI for ' + propName + ' in ' +\n * componentName\n * );\n * }\n * }\n * },\n * render: function() {...}\n * });\n *\n * @internal\n */\n\n var ANONYMOUS = '<>';\n\n // Important!\n // Keep this list in sync with production version in `./factoryWithThrowingShims.js`.\n var ReactPropTypes = {\n array: createPrimitiveTypeChecker('array'),\n bigint: createPrimitiveTypeChecker('bigint'),\n bool: createPrimitiveTypeChecker('boolean'),\n func: createPrimitiveTypeChecker('function'),\n number: createPrimitiveTypeChecker('number'),\n object: createPrimitiveTypeChecker('object'),\n string: createPrimitiveTypeChecker('string'),\n symbol: createPrimitiveTypeChecker('symbol'),\n\n any: createAnyTypeChecker(),\n arrayOf: createArrayOfTypeChecker,\n element: createElementTypeChecker(),\n elementType: createElementTypeTypeChecker(),\n instanceOf: createInstanceTypeChecker,\n node: createNodeChecker(),\n objectOf: createObjectOfTypeChecker,\n oneOf: createEnumTypeChecker,\n oneOfType: createUnionTypeChecker,\n shape: createShapeTypeChecker,\n exact: createStrictShapeTypeChecker,\n };\n\n /**\n * inlined Object.is polyfill to avoid requiring consumers ship their own\n * https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object/is\n */\n /*eslint-disable no-self-compare*/\n function is(x, y) {\n // SameValue algorithm\n if (x === y) {\n // Steps 1-5, 7-10\n // Steps 6.b-6.e: +0 != -0\n return x !== 0 || 1 / x === 1 / y;\n } else {\n // Step 6.a: NaN == NaN\n return x !== x && y !== y;\n }\n }\n /*eslint-enable no-self-compare*/\n\n /**\n * We use an Error-like object for backward compatibility as people may call\n * PropTypes directly and inspect their output. However, we don't use real\n * Errors anymore. We don't inspect their stack anyway, and creating them\n * is prohibitively expensive if they are created too often, such as what\n * happens in oneOfType() for any type before the one that matched.\n */\n function PropTypeError(message, data) {\n this.message = message;\n this.data = data && typeof data === 'object' ? data: {};\n this.stack = '';\n }\n // Make `instanceof Error` still work for returned errors.\n PropTypeError.prototype = Error.prototype;\n\n function createChainableTypeChecker(validate) {\n if (process.env.NODE_ENV !== 'production') {\n var manualPropTypeCallCache = {};\n var manualPropTypeWarningCount = 0;\n }\n function checkType(isRequired, props, propName, componentName, location, propFullName, secret) {\n componentName = componentName || ANONYMOUS;\n propFullName = propFullName || propName;\n\n if (secret !== ReactPropTypesSecret) {\n if (throwOnDirectAccess) {\n // New behavior only for users of `prop-types` package\n var err = new Error(\n 'Calling PropTypes validators directly is not supported by the `prop-types` package. ' +\n 'Use `PropTypes.checkPropTypes()` to call them. ' +\n 'Read more at http://fb.me/use-check-prop-types'\n );\n err.name = 'Invariant Violation';\n throw err;\n } else if (process.env.NODE_ENV !== 'production' && typeof console !== 'undefined') {\n // Old behavior for people using React.PropTypes\n var cacheKey = componentName + ':' + propName;\n if (\n !manualPropTypeCallCache[cacheKey] &&\n // Avoid spamming the console because they are often not actionable except for lib authors\n manualPropTypeWarningCount < 3\n ) {\n printWarning(\n 'You are manually calling a React.PropTypes validation ' +\n 'function for the `' + propFullName + '` prop on `' + componentName + '`. This is deprecated ' +\n 'and will throw in the standalone `prop-types` package. ' +\n 'You may be seeing this warning due to a third-party PropTypes ' +\n 'library. See https://fb.me/react-warning-dont-call-proptypes ' + 'for details.'\n );\n manualPropTypeCallCache[cacheKey] = true;\n manualPropTypeWarningCount++;\n }\n }\n }\n if (props[propName] == null) {\n if (isRequired) {\n if (props[propName] === null) {\n return new PropTypeError('The ' + location + ' `' + propFullName + '` is marked as required ' + ('in `' + componentName + '`, but its value is `null`.'));\n }\n return new PropTypeError('The ' + location + ' `' + propFullName + '` is marked as required in ' + ('`' + componentName + '`, but its value is `undefined`.'));\n }\n return null;\n } else {\n return validate(props, propName, componentName, location, propFullName);\n }\n }\n\n var chainedCheckType = checkType.bind(null, false);\n chainedCheckType.isRequired = checkType.bind(null, true);\n\n return chainedCheckType;\n }\n\n function createPrimitiveTypeChecker(expectedType) {\n function validate(props, propName, componentName, location, propFullName, secret) {\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== expectedType) {\n // `propValue` being instance of, say, date/regexp, pass the 'object'\n // check, but we can offer a more precise error message here rather than\n // 'of type `object`'.\n var preciseType = getPreciseType(propValue);\n\n return new PropTypeError(\n 'Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + preciseType + '` supplied to `' + componentName + '`, expected ') + ('`' + expectedType + '`.'),\n {expectedType: expectedType}\n );\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createAnyTypeChecker() {\n return createChainableTypeChecker(emptyFunctionThatReturnsNull);\n }\n\n function createArrayOfTypeChecker(typeChecker) {\n function validate(props, propName, componentName, location, propFullName) {\n if (typeof typeChecker !== 'function') {\n return new PropTypeError('Property `' + propFullName + '` of component `' + componentName + '` has invalid PropType notation inside arrayOf.');\n }\n var propValue = props[propName];\n if (!Array.isArray(propValue)) {\n var propType = getPropType(propValue);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected an array.'));\n }\n for (var i = 0; i < propValue.length; i++) {\n var error = typeChecker(propValue, i, componentName, location, propFullName + '[' + i + ']', ReactPropTypesSecret);\n if (error instanceof Error) {\n return error;\n }\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createElementTypeChecker() {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n if (!isValidElement(propValue)) {\n var propType = getPropType(propValue);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected a single ReactElement.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createElementTypeTypeChecker() {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n if (!ReactIs.isValidElementType(propValue)) {\n var propType = getPropType(propValue);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected a single ReactElement type.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createInstanceTypeChecker(expectedClass) {\n function validate(props, propName, componentName, location, propFullName) {\n if (!(props[propName] instanceof expectedClass)) {\n var expectedClassName = expectedClass.name || ANONYMOUS;\n var actualClassName = getClassName(props[propName]);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + actualClassName + '` supplied to `' + componentName + '`, expected ') + ('instance of `' + expectedClassName + '`.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createEnumTypeChecker(expectedValues) {\n if (!Array.isArray(expectedValues)) {\n if (process.env.NODE_ENV !== 'production') {\n if (arguments.length > 1) {\n printWarning(\n 'Invalid arguments supplied to oneOf, expected an array, got ' + arguments.length + ' arguments. ' +\n 'A common mistake is to write oneOf(x, y, z) instead of oneOf([x, y, z]).'\n );\n } else {\n printWarning('Invalid argument supplied to oneOf, expected an array.');\n }\n }\n return emptyFunctionThatReturnsNull;\n }\n\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n for (var i = 0; i < expectedValues.length; i++) {\n if (is(propValue, expectedValues[i])) {\n return null;\n }\n }\n\n var valuesString = JSON.stringify(expectedValues, function replacer(key, value) {\n var type = getPreciseType(value);\n if (type === 'symbol') {\n return String(value);\n }\n return value;\n });\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of value `' + String(propValue) + '` ' + ('supplied to `' + componentName + '`, expected one of ' + valuesString + '.'));\n }\n return createChainableTypeChecker(validate);\n }\n\n function createObjectOfTypeChecker(typeChecker) {\n function validate(props, propName, componentName, location, propFullName) {\n if (typeof typeChecker !== 'function') {\n return new PropTypeError('Property `' + propFullName + '` of component `' + componentName + '` has invalid PropType notation inside objectOf.');\n }\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== 'object') {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected an object.'));\n }\n for (var key in propValue) {\n if (has(propValue, key)) {\n var error = typeChecker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret);\n if (error instanceof Error) {\n return error;\n }\n }\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createUnionTypeChecker(arrayOfTypeCheckers) {\n if (!Array.isArray(arrayOfTypeCheckers)) {\n process.env.NODE_ENV !== 'production' ? printWarning('Invalid argument supplied to oneOfType, expected an instance of array.') : void 0;\n return emptyFunctionThatReturnsNull;\n }\n\n for (var i = 0; i < arrayOfTypeCheckers.length; i++) {\n var checker = arrayOfTypeCheckers[i];\n if (typeof checker !== 'function') {\n printWarning(\n 'Invalid argument supplied to oneOfType. Expected an array of check functions, but ' +\n 'received ' + getPostfixForTypeWarning(checker) + ' at index ' + i + '.'\n );\n return emptyFunctionThatReturnsNull;\n }\n }\n\n function validate(props, propName, componentName, location, propFullName) {\n var expectedTypes = [];\n for (var i = 0; i < arrayOfTypeCheckers.length; i++) {\n var checker = arrayOfTypeCheckers[i];\n var checkerResult = checker(props, propName, componentName, location, propFullName, ReactPropTypesSecret);\n if (checkerResult == null) {\n return null;\n }\n if (checkerResult.data && has(checkerResult.data, 'expectedType')) {\n expectedTypes.push(checkerResult.data.expectedType);\n }\n }\n var expectedTypesMessage = (expectedTypes.length > 0) ? ', expected one of type [' + expectedTypes.join(', ') + ']': '';\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` supplied to ' + ('`' + componentName + '`' + expectedTypesMessage + '.'));\n }\n return createChainableTypeChecker(validate);\n }\n\n function createNodeChecker() {\n function validate(props, propName, componentName, location, propFullName) {\n if (!isNode(props[propName])) {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` supplied to ' + ('`' + componentName + '`, expected a ReactNode.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function invalidValidatorError(componentName, location, propFullName, key, type) {\n return new PropTypeError(\n (componentName || 'React class') + ': ' + location + ' type `' + propFullName + '.' + key + '` is invalid; ' +\n 'it must be a function, usually from the `prop-types` package, but received `' + type + '`.'\n );\n }\n\n function createShapeTypeChecker(shapeTypes) {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== 'object') {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type `' + propType + '` ' + ('supplied to `' + componentName + '`, expected `object`.'));\n }\n for (var key in shapeTypes) {\n var checker = shapeTypes[key];\n if (typeof checker !== 'function') {\n return invalidValidatorError(componentName, location, propFullName, key, getPreciseType(checker));\n }\n var error = checker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret);\n if (error) {\n return error;\n }\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createStrictShapeTypeChecker(shapeTypes) {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== 'object') {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type `' + propType + '` ' + ('supplied to `' + componentName + '`, expected `object`.'));\n }\n // We need to check all keys in case some are required but missing from props.\n var allKeys = assign({}, props[propName], shapeTypes);\n for (var key in allKeys) {\n var checker = shapeTypes[key];\n if (has(shapeTypes, key) && typeof checker !== 'function') {\n return invalidValidatorError(componentName, location, propFullName, key, getPreciseType(checker));\n }\n if (!checker) {\n return new PropTypeError(\n 'Invalid ' + location + ' `' + propFullName + '` key `' + key + '` supplied to `' + componentName + '`.' +\n '\\nBad object: ' + JSON.stringify(props[propName], null, ' ') +\n '\\nValid keys: ' + JSON.stringify(Object.keys(shapeTypes), null, ' ')\n );\n }\n var error = checker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret);\n if (error) {\n return error;\n }\n }\n return null;\n }\n\n return createChainableTypeChecker(validate);\n }\n\n function isNode(propValue) {\n switch (typeof propValue) {\n case 'number':\n case 'string':\n case 'undefined':\n return true;\n case 'boolean':\n return !propValue;\n case 'object':\n if (Array.isArray(propValue)) {\n return propValue.every(isNode);\n }\n if (propValue === null || isValidElement(propValue)) {\n return true;\n }\n\n var iteratorFn = getIteratorFn(propValue);\n if (iteratorFn) {\n var iterator = iteratorFn.call(propValue);\n var step;\n if (iteratorFn !== propValue.entries) {\n while (!(step = iterator.next()).done) {\n if (!isNode(step.value)) {\n return false;\n }\n }\n } else {\n // Iterator will provide entry [k,v] tuples rather than values.\n while (!(step = iterator.next()).done) {\n var entry = step.value;\n if (entry) {\n if (!isNode(entry[1])) {\n return false;\n }\n }\n }\n }\n } else {\n return false;\n }\n\n return true;\n default:\n return false;\n }\n }\n\n function isSymbol(propType, propValue) {\n // Native Symbol.\n if (propType === 'symbol') {\n return true;\n }\n\n // falsy value can't be a Symbol\n if (!propValue) {\n return false;\n }\n\n // 19.4.3.5 Symbol.prototype[@@toStringTag] === 'Symbol'\n if (propValue['@@toStringTag'] === 'Symbol') {\n return true;\n }\n\n // Fallback for non-spec compliant Symbols which are polyfilled.\n if (typeof Symbol === 'function' && propValue instanceof Symbol) {\n return true;\n }\n\n return false;\n }\n\n // Equivalent of `typeof` but with special handling for array and regexp.\n function getPropType(propValue) {\n var propType = typeof propValue;\n if (Array.isArray(propValue)) {\n return 'array';\n }\n if (propValue instanceof RegExp) {\n // Old webkits (at least until Android 4.0) return 'function' rather than\n // 'object' for typeof a RegExp. We'll normalize this here so that /bla/\n // passes PropTypes.object.\n return 'object';\n }\n if (isSymbol(propType, propValue)) {\n return 'symbol';\n }\n return propType;\n }\n\n // This handles more types than `getPropType`. Only used for error messages.\n // See `createPrimitiveTypeChecker`.\n function getPreciseType(propValue) {\n if (typeof propValue === 'undefined' || propValue === null) {\n return '' + propValue;\n }\n var propType = getPropType(propValue);\n if (propType === 'object') {\n if (propValue instanceof Date) {\n return 'date';\n } else if (propValue instanceof RegExp) {\n return 'regexp';\n }\n }\n return propType;\n }\n\n // Returns a string that is postfixed to a warning about an invalid type.\n // For example, \"undefined\" or \"of type array\"\n function getPostfixForTypeWarning(value) {\n var type = getPreciseType(value);\n switch (type) {\n case 'array':\n case 'object':\n return 'an ' + type;\n case 'boolean':\n case 'date':\n case 'regexp':\n return 'a ' + type;\n default:\n return type;\n }\n }\n\n // Returns class name of the object, if any.\n function getClassName(propValue) {\n if (!propValue.constructor || !propValue.constructor.name) {\n return ANONYMOUS;\n }\n return propValue.constructor.name;\n }\n\n ReactPropTypes.checkPropTypes = checkPropTypes;\n ReactPropTypes.resetWarningCache = checkPropTypes.resetWarningCache;\n ReactPropTypes.PropTypes = ReactPropTypes;\n\n return ReactPropTypes;\n};\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar ReactPropTypesSecret = require('./lib/ReactPropTypesSecret');\n\nfunction emptyFunction() {}\nfunction emptyFunctionWithReset() {}\nemptyFunctionWithReset.resetWarningCache = emptyFunction;\n\nmodule.exports = function() {\n function shim(props, propName, componentName, location, propFullName, secret) {\n if (secret === ReactPropTypesSecret) {\n // It is still safe when called from React.\n return;\n }\n var err = new Error(\n 'Calling PropTypes validators directly is not supported by the `prop-types` package. ' +\n 'Use PropTypes.checkPropTypes() to call them. ' +\n 'Read more at http://fb.me/use-check-prop-types'\n );\n err.name = 'Invariant Violation';\n throw err;\n };\n shim.isRequired = shim;\n function getShim() {\n return shim;\n };\n // Important!\n // Keep this list in sync with production version in `./factoryWithTypeCheckers.js`.\n var ReactPropTypes = {\n array: shim,\n bigint: shim,\n bool: shim,\n func: shim,\n number: shim,\n object: shim,\n string: shim,\n symbol: shim,\n\n any: shim,\n arrayOf: getShim,\n element: shim,\n elementType: shim,\n instanceOf: getShim,\n node: shim,\n objectOf: getShim,\n oneOf: getShim,\n oneOfType: getShim,\n shape: getShim,\n exact: getShim,\n\n checkPropTypes: emptyFunctionWithReset,\n resetWarningCache: emptyFunction\n };\n\n ReactPropTypes.PropTypes = ReactPropTypes;\n\n return ReactPropTypes;\n};\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\nif (process.env.NODE_ENV !== 'production') {\n var ReactIs = require('react-is');\n\n // By explicitly using `prop-types` you are opting into new development behavior.\n // http://fb.me/prop-types-in-prod\n var throwOnDirectAccess = true;\n module.exports = require('./factoryWithTypeCheckers')(ReactIs.isElement, throwOnDirectAccess);\n} else {\n // By explicitly using `prop-types` you are opting into new production behavior.\n // http://fb.me/prop-types-in-prod\n module.exports = require('./factoryWithThrowingShims')();\n}\n","import PropTypes from 'prop-types';\nimport chainPropTypes from '../chainPropTypes';\nfunction isClassComponent(elementType) {\n // elementType.prototype?.isReactComponent\n const {\n prototype = {}\n } = elementType;\n return Boolean(prototype.isReactComponent);\n}\nfunction acceptingRef(props, propName, componentName, location, propFullName) {\n const element = props[propName];\n const safePropName = propFullName || propName;\n if (element == null ||\n // When server-side rendering React doesn't warn either.\n // This is not an accurate check for SSR.\n // This is only in place for Emotion compat.\n // TODO: Revisit once https://github.com/facebook/react/issues/20047 is resolved.\n typeof window === 'undefined') {\n return null;\n }\n let warningHint;\n const elementType = element.type;\n /**\n * Blacklisting instead of whitelisting\n *\n * Blacklisting will miss some components, such as React.Fragment. Those will at least\n * trigger a warning in React.\n * We can't whitelist because there is no safe way to detect React.forwardRef\n * or class components. \"Safe\" means there's no public API.\n *\n */\n if (typeof elementType === 'function' && !isClassComponent(elementType)) {\n warningHint = 'Did you accidentally use a plain function component for an element instead?';\n }\n if (warningHint !== undefined) {\n return new Error(`Invalid ${location} \\`${safePropName}\\` supplied to \\`${componentName}\\`. ` + `Expected an element that can hold a ref. ${warningHint} ` + 'For more information see https://mui.com/r/caveat-with-refs-guide');\n }\n return null;\n}\nconst elementAcceptingRef = chainPropTypes(PropTypes.element, acceptingRef);\nelementAcceptingRef.isRequired = chainPropTypes(PropTypes.element.isRequired, acceptingRef);\nexport default elementAcceptingRef;","import _extends from \"@babel/runtime/helpers/esm/extends\";\n// This module is based on https://github.com/airbnb/prop-types-exact repository.\n// However, in order to reduce the number of dependencies and to remove some extra safe checks\n// the module was forked.\n\nconst specialProperty = 'exact-prop: \\u200b';\nexport default function exactProp(propTypes) {\n if (process.env.NODE_ENV === 'production') {\n return propTypes;\n }\n return _extends({}, propTypes, {\n [specialProperty]: props => {\n const unsupportedProps = Object.keys(props).filter(prop => !propTypes.hasOwnProperty(prop));\n if (unsupportedProps.length > 0) {\n return new Error(`The following props are not supported: ${unsupportedProps.map(prop => `\\`${prop}\\``).join(', ')}. Please remove them.`);\n }\n return null;\n }\n });\n}","/**\n * WARNING: Don't import this directly.\n * Use `MuiError` from `@mui/internal-babel-macros/MuiError.macro` instead.\n * @param {number} code\n */\nexport default function formatMuiErrorMessage(code) {\n // Apply babel-plugin-transform-template-literals in loose mode\n // loose mode is safe if we're concatenating primitives\n // see https://babeljs.io/docs/en/babel-plugin-transform-template-literals#loose\n /* eslint-disable prefer-template */\n let url = 'https://mui.com/production-error/?code=' + code;\n for (let i = 1; i < arguments.length; i += 1) {\n // rest params over-transpile for this case\n // eslint-disable-next-line prefer-rest-params\n url += '&args[]=' + encodeURIComponent(arguments[i]);\n }\n return 'Minified MUI error #' + code + '; visit ' + url + ' for the full message.';\n /* eslint-enable prefer-template */\n}","/**\n * @license React\n * react-is.production.min.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n'use strict';var b=Symbol.for(\"react.element\"),c=Symbol.for(\"react.portal\"),d=Symbol.for(\"react.fragment\"),e=Symbol.for(\"react.strict_mode\"),f=Symbol.for(\"react.profiler\"),g=Symbol.for(\"react.provider\"),h=Symbol.for(\"react.context\"),k=Symbol.for(\"react.server_context\"),l=Symbol.for(\"react.forward_ref\"),m=Symbol.for(\"react.suspense\"),n=Symbol.for(\"react.suspense_list\"),p=Symbol.for(\"react.memo\"),q=Symbol.for(\"react.lazy\"),t=Symbol.for(\"react.offscreen\"),u;u=Symbol.for(\"react.module.reference\");\nfunction v(a){if(\"object\"===typeof a&&null!==a){var r=a.$$typeof;switch(r){case b:switch(a=a.type,a){case d:case f:case e:case m:case n:return a;default:switch(a=a&&a.$$typeof,a){case k:case h:case l:case q:case p:case g:return a;default:return r}}case c:return r}}}exports.ContextConsumer=h;exports.ContextProvider=g;exports.Element=b;exports.ForwardRef=l;exports.Fragment=d;exports.Lazy=q;exports.Memo=p;exports.Portal=c;exports.Profiler=f;exports.StrictMode=e;exports.Suspense=m;\nexports.SuspenseList=n;exports.isAsyncMode=function(){return!1};exports.isConcurrentMode=function(){return!1};exports.isContextConsumer=function(a){return v(a)===h};exports.isContextProvider=function(a){return v(a)===g};exports.isElement=function(a){return\"object\"===typeof a&&null!==a&&a.$$typeof===b};exports.isForwardRef=function(a){return v(a)===l};exports.isFragment=function(a){return v(a)===d};exports.isLazy=function(a){return v(a)===q};exports.isMemo=function(a){return v(a)===p};\nexports.isPortal=function(a){return v(a)===c};exports.isProfiler=function(a){return v(a)===f};exports.isStrictMode=function(a){return v(a)===e};exports.isSuspense=function(a){return v(a)===m};exports.isSuspenseList=function(a){return v(a)===n};\nexports.isValidElementType=function(a){return\"string\"===typeof a||\"function\"===typeof a||a===d||a===f||a===e||a===m||a===n||a===t||\"object\"===typeof a&&null!==a&&(a.$$typeof===q||a.$$typeof===p||a.$$typeof===g||a.$$typeof===h||a.$$typeof===l||a.$$typeof===u||void 0!==a.getModuleId)?!0:!1};exports.typeOf=v;\n","/**\n * @license React\n * react-is.development.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nif (process.env.NODE_ENV !== \"production\") {\n (function() {\n'use strict';\n\n// ATTENTION\n// When adding new symbols to this file,\n// Please consider also adding to 'react-devtools-shared/src/backend/ReactSymbols'\n// The Symbol used to tag the ReactElement-like types.\nvar REACT_ELEMENT_TYPE = Symbol.for('react.element');\nvar REACT_PORTAL_TYPE = Symbol.for('react.portal');\nvar REACT_FRAGMENT_TYPE = Symbol.for('react.fragment');\nvar REACT_STRICT_MODE_TYPE = Symbol.for('react.strict_mode');\nvar REACT_PROFILER_TYPE = Symbol.for('react.profiler');\nvar REACT_PROVIDER_TYPE = Symbol.for('react.provider');\nvar REACT_CONTEXT_TYPE = Symbol.for('react.context');\nvar REACT_SERVER_CONTEXT_TYPE = Symbol.for('react.server_context');\nvar REACT_FORWARD_REF_TYPE = Symbol.for('react.forward_ref');\nvar REACT_SUSPENSE_TYPE = Symbol.for('react.suspense');\nvar REACT_SUSPENSE_LIST_TYPE = Symbol.for('react.suspense_list');\nvar REACT_MEMO_TYPE = Symbol.for('react.memo');\nvar REACT_LAZY_TYPE = Symbol.for('react.lazy');\nvar REACT_OFFSCREEN_TYPE = Symbol.for('react.offscreen');\n\n// -----------------------------------------------------------------------------\n\nvar enableScopeAPI = false; // Experimental Create Event Handle API.\nvar enableCacheElement = false;\nvar enableTransitionTracing = false; // No known bugs, but needs performance testing\n\nvar enableLegacyHidden = false; // Enables unstable_avoidThisFallback feature in Fiber\n// stuff. Intended to enable React core members to more easily debug scheduling\n// issues in DEV builds.\n\nvar enableDebugTracing = false; // Track which Fiber(s) schedule render work.\n\nvar REACT_MODULE_REFERENCE;\n\n{\n REACT_MODULE_REFERENCE = Symbol.for('react.module.reference');\n}\n\nfunction isValidElementType(type) {\n if (typeof type === 'string' || typeof type === 'function') {\n return true;\n } // Note: typeof might be other than 'symbol' or 'number' (e.g. if it's a polyfill).\n\n\n if (type === REACT_FRAGMENT_TYPE || type === REACT_PROFILER_TYPE || enableDebugTracing || type === REACT_STRICT_MODE_TYPE || type === REACT_SUSPENSE_TYPE || type === REACT_SUSPENSE_LIST_TYPE || enableLegacyHidden || type === REACT_OFFSCREEN_TYPE || enableScopeAPI || enableCacheElement || enableTransitionTracing ) {\n return true;\n }\n\n if (typeof type === 'object' && type !== null) {\n if (type.$$typeof === REACT_LAZY_TYPE || type.$$typeof === REACT_MEMO_TYPE || type.$$typeof === REACT_PROVIDER_TYPE || type.$$typeof === REACT_CONTEXT_TYPE || type.$$typeof === REACT_FORWARD_REF_TYPE || // This needs to include all possible module reference object\n // types supported by any Flight configuration anywhere since\n // we don't know which Flight build this will end up being used\n // with.\n type.$$typeof === REACT_MODULE_REFERENCE || type.getModuleId !== undefined) {\n return true;\n }\n }\n\n return false;\n}\n\nfunction typeOf(object) {\n if (typeof object === 'object' && object !== null) {\n var $$typeof = object.$$typeof;\n\n switch ($$typeof) {\n case REACT_ELEMENT_TYPE:\n var type = object.type;\n\n switch (type) {\n case REACT_FRAGMENT_TYPE:\n case REACT_PROFILER_TYPE:\n case REACT_STRICT_MODE_TYPE:\n case REACT_SUSPENSE_TYPE:\n case REACT_SUSPENSE_LIST_TYPE:\n return type;\n\n default:\n var $$typeofType = type && type.$$typeof;\n\n switch ($$typeofType) {\n case REACT_SERVER_CONTEXT_TYPE:\n case REACT_CONTEXT_TYPE:\n case REACT_FORWARD_REF_TYPE:\n case REACT_LAZY_TYPE:\n case REACT_MEMO_TYPE:\n case REACT_PROVIDER_TYPE:\n return $$typeofType;\n\n default:\n return $$typeof;\n }\n\n }\n\n case REACT_PORTAL_TYPE:\n return $$typeof;\n }\n }\n\n return undefined;\n}\nvar ContextConsumer = REACT_CONTEXT_TYPE;\nvar ContextProvider = REACT_PROVIDER_TYPE;\nvar Element = REACT_ELEMENT_TYPE;\nvar ForwardRef = REACT_FORWARD_REF_TYPE;\nvar Fragment = REACT_FRAGMENT_TYPE;\nvar Lazy = REACT_LAZY_TYPE;\nvar Memo = REACT_MEMO_TYPE;\nvar Portal = REACT_PORTAL_TYPE;\nvar Profiler = REACT_PROFILER_TYPE;\nvar StrictMode = REACT_STRICT_MODE_TYPE;\nvar Suspense = REACT_SUSPENSE_TYPE;\nvar SuspenseList = REACT_SUSPENSE_LIST_TYPE;\nvar hasWarnedAboutDeprecatedIsAsyncMode = false;\nvar hasWarnedAboutDeprecatedIsConcurrentMode = false; // AsyncMode should be deprecated\n\nfunction isAsyncMode(object) {\n {\n if (!hasWarnedAboutDeprecatedIsAsyncMode) {\n hasWarnedAboutDeprecatedIsAsyncMode = true; // Using console['warn'] to evade Babel and ESLint\n\n console['warn']('The ReactIs.isAsyncMode() alias has been deprecated, ' + 'and will be removed in React 18+.');\n }\n }\n\n return false;\n}\nfunction isConcurrentMode(object) {\n {\n if (!hasWarnedAboutDeprecatedIsConcurrentMode) {\n hasWarnedAboutDeprecatedIsConcurrentMode = true; // Using console['warn'] to evade Babel and ESLint\n\n console['warn']('The ReactIs.isConcurrentMode() alias has been deprecated, ' + 'and will be removed in React 18+.');\n }\n }\n\n return false;\n}\nfunction isContextConsumer(object) {\n return typeOf(object) === REACT_CONTEXT_TYPE;\n}\nfunction isContextProvider(object) {\n return typeOf(object) === REACT_PROVIDER_TYPE;\n}\nfunction isElement(object) {\n return typeof object === 'object' && object !== null && object.$$typeof === REACT_ELEMENT_TYPE;\n}\nfunction isForwardRef(object) {\n return typeOf(object) === REACT_FORWARD_REF_TYPE;\n}\nfunction isFragment(object) {\n return typeOf(object) === REACT_FRAGMENT_TYPE;\n}\nfunction isLazy(object) {\n return typeOf(object) === REACT_LAZY_TYPE;\n}\nfunction isMemo(object) {\n return typeOf(object) === REACT_MEMO_TYPE;\n}\nfunction isPortal(object) {\n return typeOf(object) === REACT_PORTAL_TYPE;\n}\nfunction isProfiler(object) {\n return typeOf(object) === REACT_PROFILER_TYPE;\n}\nfunction isStrictMode(object) {\n return typeOf(object) === REACT_STRICT_MODE_TYPE;\n}\nfunction isSuspense(object) {\n return typeOf(object) === REACT_SUSPENSE_TYPE;\n}\nfunction isSuspenseList(object) {\n return typeOf(object) === REACT_SUSPENSE_LIST_TYPE;\n}\n\nexports.ContextConsumer = ContextConsumer;\nexports.ContextProvider = ContextProvider;\nexports.Element = Element;\nexports.ForwardRef = ForwardRef;\nexports.Fragment = Fragment;\nexports.Lazy = Lazy;\nexports.Memo = Memo;\nexports.Portal = Portal;\nexports.Profiler = Profiler;\nexports.StrictMode = StrictMode;\nexports.Suspense = Suspense;\nexports.SuspenseList = SuspenseList;\nexports.isAsyncMode = isAsyncMode;\nexports.isConcurrentMode = isConcurrentMode;\nexports.isContextConsumer = isContextConsumer;\nexports.isContextProvider = isContextProvider;\nexports.isElement = isElement;\nexports.isForwardRef = isForwardRef;\nexports.isFragment = isFragment;\nexports.isLazy = isLazy;\nexports.isMemo = isMemo;\nexports.isPortal = isPortal;\nexports.isProfiler = isProfiler;\nexports.isStrictMode = isStrictMode;\nexports.isSuspense = isSuspense;\nexports.isSuspenseList = isSuspenseList;\nexports.isValidElementType = isValidElementType;\nexports.typeOf = typeOf;\n })();\n}\n","'use strict';\n\nif (process.env.NODE_ENV === 'production') {\n module.exports = require('./cjs/react-is.production.min.js');\n} else {\n module.exports = require('./cjs/react-is.development.js');\n}\n","import { ForwardRef, Memo } from 'react-is';\n\n// Simplified polyfill for IE11 support\n// https://github.com/JamesMGreene/Function.name/blob/58b314d4a983110c3682f1228f845d39ccca1817/Function.name.js#L3\nconst fnNameMatchRegex = /^\\s*function(?:\\s|\\s*\\/\\*.*\\*\\/\\s*)+([^(\\s/]*)\\s*/;\nexport function getFunctionName(fn) {\n const match = `${fn}`.match(fnNameMatchRegex);\n const name = match && match[1];\n return name || '';\n}\nfunction getFunctionComponentName(Component, fallback = '') {\n return Component.displayName || Component.name || getFunctionName(Component) || fallback;\n}\nfunction getWrappedName(outerType, innerType, wrapperName) {\n const functionName = getFunctionComponentName(innerType);\n return outerType.displayName || (functionName !== '' ? `${wrapperName}(${functionName})` : wrapperName);\n}\n\n/**\n * cherry-pick from\n * https://github.com/facebook/react/blob/769b1f270e1251d9dbdce0fcbd9e92e502d059b8/packages/shared/getComponentName.js\n * originally forked from recompose/getDisplayName with added IE11 support\n */\nexport default function getDisplayName(Component) {\n if (Component == null) {\n return undefined;\n }\n if (typeof Component === 'string') {\n return Component;\n }\n if (typeof Component === 'function') {\n return getFunctionComponentName(Component, 'Component');\n }\n\n // TypeScript can't have components as objects but they exist in the form of `memo` or `Suspense`\n if (typeof Component === 'object') {\n switch (Component.$$typeof) {\n case ForwardRef:\n return getWrappedName(Component, Component.render, 'ForwardRef');\n case Memo:\n return getWrappedName(Component, Component.type, 'memo');\n default:\n return undefined;\n }\n }\n return undefined;\n}","export default function HTMLElementType(props, propName, componentName, location, propFullName) {\n if (process.env.NODE_ENV === 'production') {\n return null;\n }\n const propValue = props[propName];\n const safePropName = propFullName || propName;\n if (propValue == null) {\n return null;\n }\n if (propValue && propValue.nodeType !== 1) {\n return new Error(`Invalid ${location} \\`${safePropName}\\` supplied to \\`${componentName}\\`. ` + `Expected an HTMLElement.`);\n }\n return null;\n}","import PropTypes from 'prop-types';\nconst refType = PropTypes.oneOfType([PropTypes.func, PropTypes.object]);\nexport default refType;","import _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\n// It should to be noted that this function isn't equivalent to `text-transform: capitalize`.\n//\n// A strict capitalization should uppercase the first letter of each word in the sentence.\n// We only handle the first word.\nexport default function capitalize(string) {\n if (typeof string !== 'string') {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: \\`capitalize(string)\\` expects a string argument.` : _formatMuiErrorMessage(7));\n }\n return string.charAt(0).toUpperCase() + string.slice(1);\n}","/**\n * Safe chained function.\n *\n * Will only create a new function if needed,\n * otherwise will pass back existing functions or null.\n */\nexport default function createChainedFunction(...funcs) {\n return funcs.reduce((acc, func) => {\n if (func == null) {\n return acc;\n }\n return function chainedFunction(...args) {\n acc.apply(this, args);\n func.apply(this, args);\n };\n }, () => {});\n}","// Corresponds to 10 frames at 60 Hz.\n// A few bytes payload overhead when lodash/debounce is ~3 kB and debounce ~300 B.\nexport default function debounce(func, wait = 166) {\n let timeout;\n function debounced(...args) {\n const later = () => {\n // @ts-ignore\n func.apply(this, args);\n };\n clearTimeout(timeout);\n timeout = setTimeout(later, wait);\n }\n debounced.clear = () => {\n clearTimeout(timeout);\n };\n return debounced;\n}","export default function deprecatedPropType(validator, reason) {\n if (process.env.NODE_ENV === 'production') {\n return () => null;\n }\n return (props, propName, componentName, location, propFullName) => {\n const componentNameSafe = componentName || '<>';\n const propFullNameSafe = propFullName || propName;\n if (typeof props[propName] !== 'undefined') {\n return new Error(`The ${location} \\`${propFullNameSafe}\\` of ` + `\\`${componentNameSafe}\\` is deprecated. ${reason}`);\n }\n return null;\n };\n}","import * as React from 'react';\nexport default function isMuiElement(element, muiNames) {\n var _muiName, _element$type;\n return /*#__PURE__*/React.isValidElement(element) && muiNames.indexOf( // For server components `muiName` is avaialble in element.type._payload.value.muiName\n // relevant info - https://github.com/facebook/react/blob/2807d781a08db8e9873687fccc25c0f12b4fb3d4/packages/react/src/ReactLazy.js#L45\n // eslint-disable-next-line no-underscore-dangle\n (_muiName = element.type.muiName) != null ? _muiName : (_element$type = element.type) == null || (_element$type = _element$type._payload) == null || (_element$type = _element$type.value) == null ? void 0 : _element$type.muiName) !== -1;\n}","export default function ownerDocument(node) {\n return node && node.ownerDocument || document;\n}","import ownerDocument from '../ownerDocument';\nexport default function ownerWindow(node) {\n const doc = ownerDocument(node);\n return doc.defaultView || window;\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nexport default function requirePropFactory(componentNameInError, Component) {\n if (process.env.NODE_ENV === 'production') {\n return () => null;\n }\n\n // eslint-disable-next-line react/forbid-foreign-prop-types\n const prevPropTypes = Component ? _extends({}, Component.propTypes) : null;\n const requireProp = requiredProp => (props, propName, componentName, location, propFullName, ...args) => {\n const propFullNameSafe = propFullName || propName;\n const defaultTypeChecker = prevPropTypes == null ? void 0 : prevPropTypes[propFullNameSafe];\n if (defaultTypeChecker) {\n const typeCheckerResult = defaultTypeChecker(props, propName, componentName, location, propFullName, ...args);\n if (typeCheckerResult) {\n return typeCheckerResult;\n }\n }\n if (typeof props[propName] !== 'undefined' && !props[requiredProp]) {\n return new Error(`The prop \\`${propFullNameSafe}\\` of ` + `\\`${componentNameInError}\\` can only be used together with the \\`${requiredProp}\\` prop.`);\n }\n return null;\n };\n return requireProp;\n}","/**\n * TODO v5: consider making it private\n *\n * passes {value} to {ref}\n *\n * WARNING: Be sure to only call this inside a callback that is passed as a ref.\n * Otherwise, make sure to cleanup the previous {ref} if it changes. See\n * https://github.com/mui/material-ui/issues/13539\n *\n * Useful if you want to expose the ref of an inner component to the public API\n * while still using it inside the component.\n * @param ref A ref callback or ref object. If anything falsy, this is a no-op.\n */\nexport default function setRef(ref, value) {\n if (typeof ref === 'function') {\n ref(value);\n } else if (ref) {\n ref.current = value;\n }\n}","'use client';\n\nimport * as React from 'react';\n\n/**\n * A version of `React.useLayoutEffect` that does not show a warning when server-side rendering.\n * This is useful for effects that are only needed for client-side rendering but not for SSR.\n *\n * Before you use this hook, make sure to read https://gist.github.com/gaearon/e7d97cdf38a2907924ea12e4ebdf3c85\n * and confirm it doesn't apply to your use-case.\n */\nconst useEnhancedEffect = typeof window !== 'undefined' ? React.useLayoutEffect : React.useEffect;\nexport default useEnhancedEffect;","'use client';\n\nimport * as React from 'react';\nlet globalId = 0;\nfunction useGlobalId(idOverride) {\n const [defaultId, setDefaultId] = React.useState(idOverride);\n const id = idOverride || defaultId;\n React.useEffect(() => {\n if (defaultId == null) {\n // Fallback to this default id when possible.\n // Use the incrementing value for client-side rendering only.\n // We can't use it server-side.\n // If you want to use random values please consider the Birthday Problem: https://en.wikipedia.org/wiki/Birthday_problem\n globalId += 1;\n setDefaultId(`mui-${globalId}`);\n }\n }, [defaultId]);\n return id;\n}\n\n// downstream bundlers may remove unnecessary concatenation, but won't remove toString call -- Workaround for https://github.com/webpack/webpack/issues/14814\nconst maybeReactUseId = React['useId'.toString()];\n/**\n *\n * @example
    \n * @param idOverride\n * @returns {string}\n */\nexport default function useId(idOverride) {\n if (maybeReactUseId !== undefined) {\n const reactId = maybeReactUseId();\n return idOverride != null ? idOverride : reactId;\n }\n // eslint-disable-next-line react-hooks/rules-of-hooks -- `React.useId` is invariant at runtime.\n return useGlobalId(idOverride);\n}","export default function unsupportedProp(props, propName, componentName, location, propFullName) {\n if (process.env.NODE_ENV === 'production') {\n return null;\n }\n const propFullNameSafe = propFullName || propName;\n if (typeof props[propName] !== 'undefined') {\n return new Error(`The prop \\`${propFullNameSafe}\\` is not supported. Please remove it.`);\n }\n return null;\n}","'use client';\n\n/* eslint-disable react-hooks/rules-of-hooks, react-hooks/exhaustive-deps */\nimport * as React from 'react';\nexport default function useControlled({\n controlled,\n default: defaultProp,\n name,\n state = 'value'\n}) {\n // isControlled is ignored in the hook dependency lists as it should never change.\n const {\n current: isControlled\n } = React.useRef(controlled !== undefined);\n const [valueState, setValue] = React.useState(defaultProp);\n const value = isControlled ? controlled : valueState;\n if (process.env.NODE_ENV !== 'production') {\n React.useEffect(() => {\n if (isControlled !== (controlled !== undefined)) {\n console.error([`MUI: A component is changing the ${isControlled ? '' : 'un'}controlled ${state} state of ${name} to be ${isControlled ? 'un' : ''}controlled.`, 'Elements should not switch from uncontrolled to controlled (or vice versa).', `Decide between using a controlled or uncontrolled ${name} ` + 'element for the lifetime of the component.', \"The nature of the state is determined during the first render. It's considered controlled if the value is not `undefined`.\", 'More info: https://fb.me/react-controlled-components'].join('\\n'));\n }\n }, [state, name, controlled]);\n const {\n current: defaultValue\n } = React.useRef(defaultProp);\n React.useEffect(() => {\n if (!isControlled && defaultValue !== defaultProp) {\n console.error([`MUI: A component is changing the default ${state} state of an uncontrolled ${name} after being initialized. ` + `To suppress this warning opt to use a controlled ${name}.`].join('\\n'));\n }\n }, [JSON.stringify(defaultProp)]);\n }\n const setValueIfUncontrolled = React.useCallback(newValue => {\n if (!isControlled) {\n setValue(newValue);\n }\n }, []);\n return [value, setValueIfUncontrolled];\n}","'use client';\n\nimport * as React from 'react';\nimport useEnhancedEffect from '../useEnhancedEffect';\n\n/**\n * Inspired by https://github.com/facebook/react/issues/14099#issuecomment-440013892\n * See RFC in https://github.com/reactjs/rfcs/pull/220\n */\n\nfunction useEventCallback(fn) {\n const ref = React.useRef(fn);\n useEnhancedEffect(() => {\n ref.current = fn;\n });\n return React.useRef((...args) =>\n // @ts-expect-error hide `this`\n (0, ref.current)(...args)).current;\n}\nexport default useEventCallback;","'use client';\n\nimport * as React from 'react';\nimport setRef from '../setRef';\nexport default function useForkRef(...refs) {\n /**\n * This will create a new function if the refs passed to this hook change and are all defined.\n * This means react will call the old forkRef with `null` and the new forkRef\n * with the ref. Cleanup naturally emerges from this behavior.\n */\n return React.useMemo(() => {\n if (refs.every(ref => ref == null)) {\n return null;\n }\n return instance => {\n refs.forEach(ref => {\n setRef(ref, instance);\n });\n };\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, refs);\n}","'use client';\n\nimport * as React from 'react';\nconst UNINITIALIZED = {};\n\n/**\n * A React.useRef() that is initialized lazily with a function. Note that it accepts an optional\n * initialization argument, so the initialization function doesn't need to be an inline closure.\n *\n * @usage\n * const ref = useLazyRef(sortColumns, columns)\n */\nexport default function useLazyRef(init, initArg) {\n const ref = React.useRef(UNINITIALIZED);\n if (ref.current === UNINITIALIZED) {\n ref.current = init(initArg);\n }\n return ref;\n}","'use client';\n\nimport * as React from 'react';\nconst EMPTY = [];\n\n/**\n * A React.useEffect equivalent that runs once, when the component is mounted.\n */\nexport default function useOnMount(fn) {\n /* eslint-disable react-hooks/exhaustive-deps */\n React.useEffect(fn, EMPTY);\n /* eslint-enable react-hooks/exhaustive-deps */\n}","'use client';\n\nimport useLazyRef from '../useLazyRef/useLazyRef';\nimport useOnMount from '../useOnMount/useOnMount';\nexport class Timeout {\n constructor() {\n this.currentId = null;\n this.clear = () => {\n if (this.currentId !== null) {\n clearTimeout(this.currentId);\n this.currentId = null;\n }\n };\n this.disposeEffect = () => {\n return this.clear;\n };\n }\n static create() {\n return new Timeout();\n }\n /**\n * Executes `fn` after `delay`, clearing any previously scheduled call.\n */\n start(delay, fn) {\n this.clear();\n this.currentId = setTimeout(() => {\n this.currentId = null;\n fn();\n }, delay);\n }\n}\nexport default function useTimeout() {\n const timeout = useLazyRef(Timeout.create).current;\n useOnMount(timeout.disposeEffect);\n return timeout;\n}","'use client';\n\n// based on https://github.com/WICG/focus-visible/blob/v4.1.5/src/focus-visible.js\nimport * as React from 'react';\nimport { Timeout } from '../useTimeout/useTimeout';\nlet hadKeyboardEvent = true;\nlet hadFocusVisibleRecently = false;\nconst hadFocusVisibleRecentlyTimeout = new Timeout();\nconst inputTypesWhitelist = {\n text: true,\n search: true,\n url: true,\n tel: true,\n email: true,\n password: true,\n number: true,\n date: true,\n month: true,\n week: true,\n time: true,\n datetime: true,\n 'datetime-local': true\n};\n\n/**\n * Computes whether the given element should automatically trigger the\n * `focus-visible` class being added, i.e. whether it should always match\n * `:focus-visible` when focused.\n * @param {Element} node\n * @returns {boolean}\n */\nfunction focusTriggersKeyboardModality(node) {\n const {\n type,\n tagName\n } = node;\n if (tagName === 'INPUT' && inputTypesWhitelist[type] && !node.readOnly) {\n return true;\n }\n if (tagName === 'TEXTAREA' && !node.readOnly) {\n return true;\n }\n if (node.isContentEditable) {\n return true;\n }\n return false;\n}\n\n/**\n * Keep track of our keyboard modality state with `hadKeyboardEvent`.\n * If the most recent user interaction was via the keyboard;\n * and the key press did not include a meta, alt/option, or control key;\n * then the modality is keyboard. Otherwise, the modality is not keyboard.\n * @param {KeyboardEvent} event\n */\nfunction handleKeyDown(event) {\n if (event.metaKey || event.altKey || event.ctrlKey) {\n return;\n }\n hadKeyboardEvent = true;\n}\n\n/**\n * If at any point a user clicks with a pointing device, ensure that we change\n * the modality away from keyboard.\n * This avoids the situation where a user presses a key on an already focused\n * element, and then clicks on a different element, focusing it with a\n * pointing device, while we still think we're in keyboard modality.\n */\nfunction handlePointerDown() {\n hadKeyboardEvent = false;\n}\nfunction handleVisibilityChange() {\n if (this.visibilityState === 'hidden') {\n // If the tab becomes active again, the browser will handle calling focus\n // on the element (Safari actually calls it twice).\n // If this tab change caused a blur on an element with focus-visible,\n // re-apply the class when the user switches back to the tab.\n if (hadFocusVisibleRecently) {\n hadKeyboardEvent = true;\n }\n }\n}\nfunction prepare(doc) {\n doc.addEventListener('keydown', handleKeyDown, true);\n doc.addEventListener('mousedown', handlePointerDown, true);\n doc.addEventListener('pointerdown', handlePointerDown, true);\n doc.addEventListener('touchstart', handlePointerDown, true);\n doc.addEventListener('visibilitychange', handleVisibilityChange, true);\n}\nexport function teardown(doc) {\n doc.removeEventListener('keydown', handleKeyDown, true);\n doc.removeEventListener('mousedown', handlePointerDown, true);\n doc.removeEventListener('pointerdown', handlePointerDown, true);\n doc.removeEventListener('touchstart', handlePointerDown, true);\n doc.removeEventListener('visibilitychange', handleVisibilityChange, true);\n}\nfunction isFocusVisible(event) {\n const {\n target\n } = event;\n try {\n return target.matches(':focus-visible');\n } catch (error) {\n // Browsers not implementing :focus-visible will throw a SyntaxError.\n // We use our own heuristic for those browsers.\n // Rethrow might be better if it's not the expected error but do we really\n // want to crash if focus-visible malfunctioned?\n }\n\n // No need for validFocusTarget check. The user does that by attaching it to\n // focusable events only.\n return hadKeyboardEvent || focusTriggersKeyboardModality(target);\n}\nexport default function useIsFocusVisible() {\n const ref = React.useCallback(node => {\n if (node != null) {\n prepare(node.ownerDocument);\n }\n }, []);\n const isFocusVisibleRef = React.useRef(false);\n\n /**\n * Should be called if a blur event is fired\n */\n function handleBlurVisible() {\n // checking against potential state variable does not suffice if we focus and blur synchronously.\n // React wouldn't have time to trigger a re-render so `focusVisible` would be stale.\n // Ideally we would adjust `isFocusVisible(event)` to look at `relatedTarget` for blur events.\n // This doesn't work in IE11 due to https://github.com/facebook/react/issues/3751\n // TODO: check again if React releases their internal changes to focus event handling (https://github.com/facebook/react/pull/19186).\n if (isFocusVisibleRef.current) {\n // To detect a tab/window switch, we look for a blur event followed\n // rapidly by a visibility change.\n // If we don't see a visibility change within 100ms, it's probably a\n // regular focus change.\n hadFocusVisibleRecently = true;\n hadFocusVisibleRecentlyTimeout.start(100, () => {\n hadFocusVisibleRecently = false;\n });\n isFocusVisibleRef.current = false;\n return true;\n }\n return false;\n }\n\n /**\n * Should be called if a blur event is fired\n */\n function handleFocusVisible(event) {\n if (isFocusVisible(event)) {\n isFocusVisibleRef.current = true;\n return true;\n }\n return false;\n }\n return {\n isFocusVisibleRef,\n onFocus: handleFocusVisible,\n onBlur: handleBlurVisible,\n ref\n };\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\n/**\n * Add keys, values of `defaultProps` that does not exist in `props`\n * @param {object} defaultProps\n * @param {object} props\n * @returns {object} resolved props\n */\nexport default function resolveProps(defaultProps, props) {\n const output = _extends({}, props);\n Object.keys(defaultProps).forEach(propName => {\n if (propName.toString().match(/^(components|slots)$/)) {\n output[propName] = _extends({}, defaultProps[propName], output[propName]);\n } else if (propName.toString().match(/^(componentsProps|slotProps)$/)) {\n const defaultSlotProps = defaultProps[propName] || {};\n const slotProps = props[propName];\n output[propName] = {};\n if (!slotProps || !Object.keys(slotProps)) {\n // Reduce the iteration if the slot props is empty\n output[propName] = defaultSlotProps;\n } else if (!defaultSlotProps || !Object.keys(defaultSlotProps)) {\n // Reduce the iteration if the default slot props is empty\n output[propName] = slotProps;\n } else {\n output[propName] = _extends({}, slotProps);\n Object.keys(defaultSlotProps).forEach(slotPropName => {\n output[propName][slotPropName] = resolveProps(defaultSlotProps[slotPropName], slotProps[slotPropName]);\n });\n }\n } else if (output[propName] === undefined) {\n output[propName] = defaultProps[propName];\n }\n });\n return output;\n}","export default function composeClasses(slots, getUtilityClass, classes = undefined) {\n const output = {};\n Object.keys(slots).forEach(\n // `Object.keys(slots)` can't be wider than `T` because we infer `T` from `slots`.\n // @ts-expect-error https://github.com/microsoft/TypeScript/pull/12253#issuecomment-263132208\n slot => {\n output[slot] = slots[slot].reduce((acc, key) => {\n if (key) {\n const utilityClass = getUtilityClass(key);\n if (utilityClass !== '') {\n acc.push(utilityClass);\n }\n if (classes && classes[key]) {\n acc.push(classes[key]);\n }\n }\n return acc;\n }, []).join(' ');\n });\n return output;\n}","const defaultGenerator = componentName => componentName;\nconst createClassNameGenerator = () => {\n let generate = defaultGenerator;\n return {\n configure(generator) {\n generate = generator;\n },\n generate(componentName) {\n return generate(componentName);\n },\n reset() {\n generate = defaultGenerator;\n }\n };\n};\nconst ClassNameGenerator = createClassNameGenerator();\nexport default ClassNameGenerator;","import ClassNameGenerator from '../ClassNameGenerator';\nexport const globalStateClasses = {\n active: 'active',\n checked: 'checked',\n completed: 'completed',\n disabled: 'disabled',\n error: 'error',\n expanded: 'expanded',\n focused: 'focused',\n focusVisible: 'focusVisible',\n open: 'open',\n readOnly: 'readOnly',\n required: 'required',\n selected: 'selected'\n};\nexport default function generateUtilityClass(componentName, slot, globalStatePrefix = 'Mui') {\n const globalStateClass = globalStateClasses[slot];\n return globalStateClass ? `${globalStatePrefix}-${globalStateClass}` : `${ClassNameGenerator.generate(componentName)}-${slot}`;\n}\nexport function isGlobalState(slot) {\n return globalStateClasses[slot] !== undefined;\n}","import generateUtilityClass from '../generateUtilityClass';\nexport default function generateUtilityClasses(componentName, slots, globalStatePrefix = 'Mui') {\n const result = {};\n slots.forEach(slot => {\n result[slot] = generateUtilityClass(componentName, slot, globalStatePrefix);\n });\n return result;\n}","function clamp(val, min = Number.MIN_SAFE_INTEGER, max = Number.MAX_SAFE_INTEGER) {\n return Math.max(min, Math.min(val, max));\n}\nexport default clamp;","export default function _objectWithoutPropertiesLoose(source, excluded) {\n if (source == null) return {};\n var target = {};\n var sourceKeys = Object.keys(source);\n var key, i;\n for (i = 0; i < sourceKeys.length; i++) {\n key = sourceKeys[i];\n if (excluded.indexOf(key) >= 0) continue;\n target[key] = source[key];\n }\n return target;\n}","import _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nconst _excluded = [\"values\", \"unit\", \"step\"];\n// Sorted ASC by size. That's important.\n// It can't be configured as it's used statically for propTypes.\nexport const breakpointKeys = ['xs', 'sm', 'md', 'lg', 'xl'];\nconst sortBreakpointsValues = values => {\n const breakpointsAsArray = Object.keys(values).map(key => ({\n key,\n val: values[key]\n })) || [];\n // Sort in ascending order\n breakpointsAsArray.sort((breakpoint1, breakpoint2) => breakpoint1.val - breakpoint2.val);\n return breakpointsAsArray.reduce((acc, obj) => {\n return _extends({}, acc, {\n [obj.key]: obj.val\n });\n }, {});\n};\n\n// Keep in mind that @media is inclusive by the CSS specification.\nexport default function createBreakpoints(breakpoints) {\n const {\n // The breakpoint **start** at this value.\n // For instance with the first breakpoint xs: [xs, sm).\n values = {\n xs: 0,\n // phone\n sm: 600,\n // tablet\n md: 900,\n // small laptop\n lg: 1200,\n // desktop\n xl: 1536 // large screen\n },\n unit = 'px',\n step = 5\n } = breakpoints,\n other = _objectWithoutPropertiesLoose(breakpoints, _excluded);\n const sortedValues = sortBreakpointsValues(values);\n const keys = Object.keys(sortedValues);\n function up(key) {\n const value = typeof values[key] === 'number' ? values[key] : key;\n return `@media (min-width:${value}${unit})`;\n }\n function down(key) {\n const value = typeof values[key] === 'number' ? values[key] : key;\n return `@media (max-width:${value - step / 100}${unit})`;\n }\n function between(start, end) {\n const endIndex = keys.indexOf(end);\n return `@media (min-width:${typeof values[start] === 'number' ? values[start] : start}${unit}) and ` + `(max-width:${(endIndex !== -1 && typeof values[keys[endIndex]] === 'number' ? values[keys[endIndex]] : end) - step / 100}${unit})`;\n }\n function only(key) {\n if (keys.indexOf(key) + 1 < keys.length) {\n return between(key, keys[keys.indexOf(key) + 1]);\n }\n return up(key);\n }\n function not(key) {\n // handle first and last key separately, for better readability\n const keyIndex = keys.indexOf(key);\n if (keyIndex === 0) {\n return up(keys[1]);\n }\n if (keyIndex === keys.length - 1) {\n return down(keys[keyIndex]);\n }\n return between(key, keys[keys.indexOf(key) + 1]).replace('@media', '@media not all and');\n }\n return _extends({\n keys,\n values: sortedValues,\n up,\n down,\n between,\n only,\n not,\n unit\n }, other);\n}","const shape = {\n borderRadius: 4\n};\nexport default shape;","import PropTypes from 'prop-types';\nconst responsivePropType = process.env.NODE_ENV !== 'production' ? PropTypes.oneOfType([PropTypes.number, PropTypes.string, PropTypes.object, PropTypes.array]) : {};\nexport default responsivePropType;","import deepmerge from '@mui/utils/deepmerge';\nfunction merge(acc, item) {\n if (!item) {\n return acc;\n }\n return deepmerge(acc, item, {\n clone: false // No need to clone deep, it's way faster.\n });\n}\nexport default merge;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport PropTypes from 'prop-types';\nimport deepmerge from '@mui/utils/deepmerge';\nimport merge from './merge';\n\n// The breakpoint **start** at this value.\n// For instance with the first breakpoint xs: [xs, sm[.\nexport const values = {\n xs: 0,\n // phone\n sm: 600,\n // tablet\n md: 900,\n // small laptop\n lg: 1200,\n // desktop\n xl: 1536 // large screen\n};\nconst defaultBreakpoints = {\n // Sorted ASC by size. That's important.\n // It can't be configured as it's used statically for propTypes.\n keys: ['xs', 'sm', 'md', 'lg', 'xl'],\n up: key => `@media (min-width:${values[key]}px)`\n};\nexport function handleBreakpoints(props, propValue, styleFromPropValue) {\n const theme = props.theme || {};\n if (Array.isArray(propValue)) {\n const themeBreakpoints = theme.breakpoints || defaultBreakpoints;\n return propValue.reduce((acc, item, index) => {\n acc[themeBreakpoints.up(themeBreakpoints.keys[index])] = styleFromPropValue(propValue[index]);\n return acc;\n }, {});\n }\n if (typeof propValue === 'object') {\n const themeBreakpoints = theme.breakpoints || defaultBreakpoints;\n return Object.keys(propValue).reduce((acc, breakpoint) => {\n // key is breakpoint\n if (Object.keys(themeBreakpoints.values || values).indexOf(breakpoint) !== -1) {\n const mediaKey = themeBreakpoints.up(breakpoint);\n acc[mediaKey] = styleFromPropValue(propValue[breakpoint], breakpoint);\n } else {\n const cssKey = breakpoint;\n acc[cssKey] = propValue[cssKey];\n }\n return acc;\n }, {});\n }\n const output = styleFromPropValue(propValue);\n return output;\n}\nfunction breakpoints(styleFunction) {\n // false positive\n // eslint-disable-next-line react/function-component-definition\n const newStyleFunction = props => {\n const theme = props.theme || {};\n const base = styleFunction(props);\n const themeBreakpoints = theme.breakpoints || defaultBreakpoints;\n const extended = themeBreakpoints.keys.reduce((acc, key) => {\n if (props[key]) {\n acc = acc || {};\n acc[themeBreakpoints.up(key)] = styleFunction(_extends({\n theme\n }, props[key]));\n }\n return acc;\n }, null);\n return merge(base, extended);\n };\n newStyleFunction.propTypes = process.env.NODE_ENV !== 'production' ? _extends({}, styleFunction.propTypes, {\n xs: PropTypes.object,\n sm: PropTypes.object,\n md: PropTypes.object,\n lg: PropTypes.object,\n xl: PropTypes.object\n }) : {};\n newStyleFunction.filterProps = ['xs', 'sm', 'md', 'lg', 'xl', ...styleFunction.filterProps];\n return newStyleFunction;\n}\nexport function createEmptyBreakpointObject(breakpointsInput = {}) {\n var _breakpointsInput$key;\n const breakpointsInOrder = (_breakpointsInput$key = breakpointsInput.keys) == null ? void 0 : _breakpointsInput$key.reduce((acc, key) => {\n const breakpointStyleKey = breakpointsInput.up(key);\n acc[breakpointStyleKey] = {};\n return acc;\n }, {});\n return breakpointsInOrder || {};\n}\nexport function removeUnusedBreakpoints(breakpointKeys, style) {\n return breakpointKeys.reduce((acc, key) => {\n const breakpointOutput = acc[key];\n const isBreakpointUnused = !breakpointOutput || Object.keys(breakpointOutput).length === 0;\n if (isBreakpointUnused) {\n delete acc[key];\n }\n return acc;\n }, style);\n}\nexport function mergeBreakpointsInOrder(breakpointsInput, ...styles) {\n const emptyBreakpoints = createEmptyBreakpointObject(breakpointsInput);\n const mergedOutput = [emptyBreakpoints, ...styles].reduce((prev, next) => deepmerge(prev, next), {});\n return removeUnusedBreakpoints(Object.keys(emptyBreakpoints), mergedOutput);\n}\n\n// compute base for responsive values; e.g.,\n// [1,2,3] => {xs: true, sm: true, md: true}\n// {xs: 1, sm: 2, md: 3} => {xs: true, sm: true, md: true}\nexport function computeBreakpointsBase(breakpointValues, themeBreakpoints) {\n // fixed value\n if (typeof breakpointValues !== 'object') {\n return {};\n }\n const base = {};\n const breakpointsKeys = Object.keys(themeBreakpoints);\n if (Array.isArray(breakpointValues)) {\n breakpointsKeys.forEach((breakpoint, i) => {\n if (i < breakpointValues.length) {\n base[breakpoint] = true;\n }\n });\n } else {\n breakpointsKeys.forEach(breakpoint => {\n if (breakpointValues[breakpoint] != null) {\n base[breakpoint] = true;\n }\n });\n }\n return base;\n}\nexport function resolveBreakpointValues({\n values: breakpointValues,\n breakpoints: themeBreakpoints,\n base: customBase\n}) {\n const base = customBase || computeBreakpointsBase(breakpointValues, themeBreakpoints);\n const keys = Object.keys(base);\n if (keys.length === 0) {\n return breakpointValues;\n }\n let previous;\n return keys.reduce((acc, breakpoint, i) => {\n if (Array.isArray(breakpointValues)) {\n acc[breakpoint] = breakpointValues[i] != null ? breakpointValues[i] : breakpointValues[previous];\n previous = i;\n } else if (typeof breakpointValues === 'object') {\n acc[breakpoint] = breakpointValues[breakpoint] != null ? breakpointValues[breakpoint] : breakpointValues[previous];\n previous = breakpoint;\n } else {\n acc[breakpoint] = breakpointValues;\n }\n return acc;\n }, {});\n}\nexport default breakpoints;","import capitalize from '@mui/utils/capitalize';\nimport responsivePropType from './responsivePropType';\nimport { handleBreakpoints } from './breakpoints';\nexport function getPath(obj, path, checkVars = true) {\n if (!path || typeof path !== 'string') {\n return null;\n }\n\n // Check if CSS variables are used\n if (obj && obj.vars && checkVars) {\n const val = `vars.${path}`.split('.').reduce((acc, item) => acc && acc[item] ? acc[item] : null, obj);\n if (val != null) {\n return val;\n }\n }\n return path.split('.').reduce((acc, item) => {\n if (acc && acc[item] != null) {\n return acc[item];\n }\n return null;\n }, obj);\n}\nexport function getStyleValue(themeMapping, transform, propValueFinal, userValue = propValueFinal) {\n let value;\n if (typeof themeMapping === 'function') {\n value = themeMapping(propValueFinal);\n } else if (Array.isArray(themeMapping)) {\n value = themeMapping[propValueFinal] || userValue;\n } else {\n value = getPath(themeMapping, propValueFinal) || userValue;\n }\n if (transform) {\n value = transform(value, userValue, themeMapping);\n }\n return value;\n}\nfunction style(options) {\n const {\n prop,\n cssProperty = options.prop,\n themeKey,\n transform\n } = options;\n\n // false positive\n // eslint-disable-next-line react/function-component-definition\n const fn = props => {\n if (props[prop] == null) {\n return null;\n }\n const propValue = props[prop];\n const theme = props.theme;\n const themeMapping = getPath(theme, themeKey) || {};\n const styleFromPropValue = propValueFinal => {\n let value = getStyleValue(themeMapping, transform, propValueFinal);\n if (propValueFinal === value && typeof propValueFinal === 'string') {\n // Haven't found value\n value = getStyleValue(themeMapping, transform, `${prop}${propValueFinal === 'default' ? '' : capitalize(propValueFinal)}`, propValueFinal);\n }\n if (cssProperty === false) {\n return value;\n }\n return {\n [cssProperty]: value\n };\n };\n return handleBreakpoints(props, propValue, styleFromPropValue);\n };\n fn.propTypes = process.env.NODE_ENV !== 'production' ? {\n [prop]: responsivePropType\n } : {};\n fn.filterProps = [prop];\n return fn;\n}\nexport default style;","export default function memoize(fn) {\n const cache = {};\n return arg => {\n if (cache[arg] === undefined) {\n cache[arg] = fn(arg);\n }\n return cache[arg];\n };\n}","import responsivePropType from './responsivePropType';\nimport { handleBreakpoints } from './breakpoints';\nimport { getPath } from './style';\nimport merge from './merge';\nimport memoize from './memoize';\nconst properties = {\n m: 'margin',\n p: 'padding'\n};\nconst directions = {\n t: 'Top',\n r: 'Right',\n b: 'Bottom',\n l: 'Left',\n x: ['Left', 'Right'],\n y: ['Top', 'Bottom']\n};\nconst aliases = {\n marginX: 'mx',\n marginY: 'my',\n paddingX: 'px',\n paddingY: 'py'\n};\n\n// memoize() impact:\n// From 300,000 ops/sec\n// To 350,000 ops/sec\nconst getCssProperties = memoize(prop => {\n // It's not a shorthand notation.\n if (prop.length > 2) {\n if (aliases[prop]) {\n prop = aliases[prop];\n } else {\n return [prop];\n }\n }\n const [a, b] = prop.split('');\n const property = properties[a];\n const direction = directions[b] || '';\n return Array.isArray(direction) ? direction.map(dir => property + dir) : [property + direction];\n});\nexport const marginKeys = ['m', 'mt', 'mr', 'mb', 'ml', 'mx', 'my', 'margin', 'marginTop', 'marginRight', 'marginBottom', 'marginLeft', 'marginX', 'marginY', 'marginInline', 'marginInlineStart', 'marginInlineEnd', 'marginBlock', 'marginBlockStart', 'marginBlockEnd'];\nexport const paddingKeys = ['p', 'pt', 'pr', 'pb', 'pl', 'px', 'py', 'padding', 'paddingTop', 'paddingRight', 'paddingBottom', 'paddingLeft', 'paddingX', 'paddingY', 'paddingInline', 'paddingInlineStart', 'paddingInlineEnd', 'paddingBlock', 'paddingBlockStart', 'paddingBlockEnd'];\nconst spacingKeys = [...marginKeys, ...paddingKeys];\nexport function createUnaryUnit(theme, themeKey, defaultValue, propName) {\n var _getPath;\n const themeSpacing = (_getPath = getPath(theme, themeKey, false)) != null ? _getPath : defaultValue;\n if (typeof themeSpacing === 'number') {\n return abs => {\n if (typeof abs === 'string') {\n return abs;\n }\n if (process.env.NODE_ENV !== 'production') {\n if (typeof abs !== 'number') {\n console.error(`MUI: Expected ${propName} argument to be a number or a string, got ${abs}.`);\n }\n }\n return themeSpacing * abs;\n };\n }\n if (Array.isArray(themeSpacing)) {\n return abs => {\n if (typeof abs === 'string') {\n return abs;\n }\n if (process.env.NODE_ENV !== 'production') {\n if (!Number.isInteger(abs)) {\n console.error([`MUI: The \\`theme.${themeKey}\\` array type cannot be combined with non integer values.` + `You should either use an integer value that can be used as index, or define the \\`theme.${themeKey}\\` as a number.`].join('\\n'));\n } else if (abs > themeSpacing.length - 1) {\n console.error([`MUI: The value provided (${abs}) overflows.`, `The supported values are: ${JSON.stringify(themeSpacing)}.`, `${abs} > ${themeSpacing.length - 1}, you need to add the missing values.`].join('\\n'));\n }\n }\n return themeSpacing[abs];\n };\n }\n if (typeof themeSpacing === 'function') {\n return themeSpacing;\n }\n if (process.env.NODE_ENV !== 'production') {\n console.error([`MUI: The \\`theme.${themeKey}\\` value (${themeSpacing}) is invalid.`, 'It should be a number, an array or a function.'].join('\\n'));\n }\n return () => undefined;\n}\nexport function createUnarySpacing(theme) {\n return createUnaryUnit(theme, 'spacing', 8, 'spacing');\n}\nexport function getValue(transformer, propValue) {\n if (typeof propValue === 'string' || propValue == null) {\n return propValue;\n }\n const abs = Math.abs(propValue);\n const transformed = transformer(abs);\n if (propValue >= 0) {\n return transformed;\n }\n if (typeof transformed === 'number') {\n return -transformed;\n }\n return `-${transformed}`;\n}\nexport function getStyleFromPropValue(cssProperties, transformer) {\n return propValue => cssProperties.reduce((acc, cssProperty) => {\n acc[cssProperty] = getValue(transformer, propValue);\n return acc;\n }, {});\n}\nfunction resolveCssProperty(props, keys, prop, transformer) {\n // Using a hash computation over an array iteration could be faster, but with only 28 items,\n // it's doesn't worth the bundle size.\n if (keys.indexOf(prop) === -1) {\n return null;\n }\n const cssProperties = getCssProperties(prop);\n const styleFromPropValue = getStyleFromPropValue(cssProperties, transformer);\n const propValue = props[prop];\n return handleBreakpoints(props, propValue, styleFromPropValue);\n}\nfunction style(props, keys) {\n const transformer = createUnarySpacing(props.theme);\n return Object.keys(props).map(prop => resolveCssProperty(props, keys, prop, transformer)).reduce(merge, {});\n}\nexport function margin(props) {\n return style(props, marginKeys);\n}\nmargin.propTypes = process.env.NODE_ENV !== 'production' ? marginKeys.reduce((obj, key) => {\n obj[key] = responsivePropType;\n return obj;\n}, {}) : {};\nmargin.filterProps = marginKeys;\nexport function padding(props) {\n return style(props, paddingKeys);\n}\npadding.propTypes = process.env.NODE_ENV !== 'production' ? paddingKeys.reduce((obj, key) => {\n obj[key] = responsivePropType;\n return obj;\n}, {}) : {};\npadding.filterProps = paddingKeys;\nfunction spacing(props) {\n return style(props, spacingKeys);\n}\nspacing.propTypes = process.env.NODE_ENV !== 'production' ? spacingKeys.reduce((obj, key) => {\n obj[key] = responsivePropType;\n return obj;\n}, {}) : {};\nspacing.filterProps = spacingKeys;\nexport default spacing;","import { createUnarySpacing } from '../spacing';\n\n// The different signatures imply different meaning for their arguments that can't be expressed structurally.\n// We express the difference with variable names.\n\nexport default function createSpacing(spacingInput = 8) {\n // Already transformed.\n if (spacingInput.mui) {\n return spacingInput;\n }\n\n // Material Design layouts are visually balanced. Most measurements align to an 8dp grid, which aligns both spacing and the overall layout.\n // Smaller components, such as icons, can align to a 4dp grid.\n // https://m2.material.io/design/layout/understanding-layout.html\n const transform = createUnarySpacing({\n spacing: spacingInput\n });\n const spacing = (...argsInput) => {\n if (process.env.NODE_ENV !== 'production') {\n if (!(argsInput.length <= 4)) {\n console.error(`MUI: Too many arguments provided, expected between 0 and 4, got ${argsInput.length}`);\n }\n }\n const args = argsInput.length === 0 ? [1] : argsInput;\n return args.map(argument => {\n const output = transform(argument);\n return typeof output === 'number' ? `${output}px` : output;\n }).join(' ');\n };\n spacing.mui = true;\n return spacing;\n}","import merge from './merge';\nfunction compose(...styles) {\n const handlers = styles.reduce((acc, style) => {\n style.filterProps.forEach(prop => {\n acc[prop] = style;\n });\n return acc;\n }, {});\n\n // false positive\n // eslint-disable-next-line react/function-component-definition\n const fn = props => {\n return Object.keys(props).reduce((acc, prop) => {\n if (handlers[prop]) {\n return merge(acc, handlers[prop](props));\n }\n return acc;\n }, {});\n };\n fn.propTypes = process.env.NODE_ENV !== 'production' ? styles.reduce((acc, style) => Object.assign(acc, style.propTypes), {}) : {};\n fn.filterProps = styles.reduce((acc, style) => acc.concat(style.filterProps), []);\n return fn;\n}\nexport default compose;","import responsivePropType from './responsivePropType';\nimport style from './style';\nimport compose from './compose';\nimport { createUnaryUnit, getValue } from './spacing';\nimport { handleBreakpoints } from './breakpoints';\nexport function borderTransform(value) {\n if (typeof value !== 'number') {\n return value;\n }\n return `${value}px solid`;\n}\nfunction createBorderStyle(prop, transform) {\n return style({\n prop,\n themeKey: 'borders',\n transform\n });\n}\nexport const border = createBorderStyle('border', borderTransform);\nexport const borderTop = createBorderStyle('borderTop', borderTransform);\nexport const borderRight = createBorderStyle('borderRight', borderTransform);\nexport const borderBottom = createBorderStyle('borderBottom', borderTransform);\nexport const borderLeft = createBorderStyle('borderLeft', borderTransform);\nexport const borderColor = createBorderStyle('borderColor');\nexport const borderTopColor = createBorderStyle('borderTopColor');\nexport const borderRightColor = createBorderStyle('borderRightColor');\nexport const borderBottomColor = createBorderStyle('borderBottomColor');\nexport const borderLeftColor = createBorderStyle('borderLeftColor');\nexport const outline = createBorderStyle('outline', borderTransform);\nexport const outlineColor = createBorderStyle('outlineColor');\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const borderRadius = props => {\n if (props.borderRadius !== undefined && props.borderRadius !== null) {\n const transformer = createUnaryUnit(props.theme, 'shape.borderRadius', 4, 'borderRadius');\n const styleFromPropValue = propValue => ({\n borderRadius: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.borderRadius, styleFromPropValue);\n }\n return null;\n};\nborderRadius.propTypes = process.env.NODE_ENV !== 'production' ? {\n borderRadius: responsivePropType\n} : {};\nborderRadius.filterProps = ['borderRadius'];\nconst borders = compose(border, borderTop, borderRight, borderBottom, borderLeft, borderColor, borderTopColor, borderRightColor, borderBottomColor, borderLeftColor, borderRadius, outline, outlineColor);\nexport default borders;","import style from './style';\nimport compose from './compose';\nimport { createUnaryUnit, getValue } from './spacing';\nimport { handleBreakpoints } from './breakpoints';\nimport responsivePropType from './responsivePropType';\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const gap = props => {\n if (props.gap !== undefined && props.gap !== null) {\n const transformer = createUnaryUnit(props.theme, 'spacing', 8, 'gap');\n const styleFromPropValue = propValue => ({\n gap: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.gap, styleFromPropValue);\n }\n return null;\n};\ngap.propTypes = process.env.NODE_ENV !== 'production' ? {\n gap: responsivePropType\n} : {};\ngap.filterProps = ['gap'];\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const columnGap = props => {\n if (props.columnGap !== undefined && props.columnGap !== null) {\n const transformer = createUnaryUnit(props.theme, 'spacing', 8, 'columnGap');\n const styleFromPropValue = propValue => ({\n columnGap: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.columnGap, styleFromPropValue);\n }\n return null;\n};\ncolumnGap.propTypes = process.env.NODE_ENV !== 'production' ? {\n columnGap: responsivePropType\n} : {};\ncolumnGap.filterProps = ['columnGap'];\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const rowGap = props => {\n if (props.rowGap !== undefined && props.rowGap !== null) {\n const transformer = createUnaryUnit(props.theme, 'spacing', 8, 'rowGap');\n const styleFromPropValue = propValue => ({\n rowGap: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.rowGap, styleFromPropValue);\n }\n return null;\n};\nrowGap.propTypes = process.env.NODE_ENV !== 'production' ? {\n rowGap: responsivePropType\n} : {};\nrowGap.filterProps = ['rowGap'];\nexport const gridColumn = style({\n prop: 'gridColumn'\n});\nexport const gridRow = style({\n prop: 'gridRow'\n});\nexport const gridAutoFlow = style({\n prop: 'gridAutoFlow'\n});\nexport const gridAutoColumns = style({\n prop: 'gridAutoColumns'\n});\nexport const gridAutoRows = style({\n prop: 'gridAutoRows'\n});\nexport const gridTemplateColumns = style({\n prop: 'gridTemplateColumns'\n});\nexport const gridTemplateRows = style({\n prop: 'gridTemplateRows'\n});\nexport const gridTemplateAreas = style({\n prop: 'gridTemplateAreas'\n});\nexport const gridArea = style({\n prop: 'gridArea'\n});\nconst grid = compose(gap, columnGap, rowGap, gridColumn, gridRow, gridAutoFlow, gridAutoColumns, gridAutoRows, gridTemplateColumns, gridTemplateRows, gridTemplateAreas, gridArea);\nexport default grid;","import style from './style';\nimport compose from './compose';\nexport function paletteTransform(value, userValue) {\n if (userValue === 'grey') {\n return userValue;\n }\n return value;\n}\nexport const color = style({\n prop: 'color',\n themeKey: 'palette',\n transform: paletteTransform\n});\nexport const bgcolor = style({\n prop: 'bgcolor',\n cssProperty: 'backgroundColor',\n themeKey: 'palette',\n transform: paletteTransform\n});\nexport const backgroundColor = style({\n prop: 'backgroundColor',\n themeKey: 'palette',\n transform: paletteTransform\n});\nconst palette = compose(color, bgcolor, backgroundColor);\nexport default palette;","import style from './style';\nimport compose from './compose';\nimport { handleBreakpoints, values as breakpointsValues } from './breakpoints';\nexport function sizingTransform(value) {\n return value <= 1 && value !== 0 ? `${value * 100}%` : value;\n}\nexport const width = style({\n prop: 'width',\n transform: sizingTransform\n});\nexport const maxWidth = props => {\n if (props.maxWidth !== undefined && props.maxWidth !== null) {\n const styleFromPropValue = propValue => {\n var _props$theme, _props$theme2;\n const breakpoint = ((_props$theme = props.theme) == null || (_props$theme = _props$theme.breakpoints) == null || (_props$theme = _props$theme.values) == null ? void 0 : _props$theme[propValue]) || breakpointsValues[propValue];\n if (!breakpoint) {\n return {\n maxWidth: sizingTransform(propValue)\n };\n }\n if (((_props$theme2 = props.theme) == null || (_props$theme2 = _props$theme2.breakpoints) == null ? void 0 : _props$theme2.unit) !== 'px') {\n return {\n maxWidth: `${breakpoint}${props.theme.breakpoints.unit}`\n };\n }\n return {\n maxWidth: breakpoint\n };\n };\n return handleBreakpoints(props, props.maxWidth, styleFromPropValue);\n }\n return null;\n};\nmaxWidth.filterProps = ['maxWidth'];\nexport const minWidth = style({\n prop: 'minWidth',\n transform: sizingTransform\n});\nexport const height = style({\n prop: 'height',\n transform: sizingTransform\n});\nexport const maxHeight = style({\n prop: 'maxHeight',\n transform: sizingTransform\n});\nexport const minHeight = style({\n prop: 'minHeight',\n transform: sizingTransform\n});\nexport const sizeWidth = style({\n prop: 'size',\n cssProperty: 'width',\n transform: sizingTransform\n});\nexport const sizeHeight = style({\n prop: 'size',\n cssProperty: 'height',\n transform: sizingTransform\n});\nexport const boxSizing = style({\n prop: 'boxSizing'\n});\nconst sizing = compose(width, maxWidth, minWidth, height, maxHeight, minHeight, boxSizing);\nexport default sizing;","import { padding, margin } from '../spacing';\nimport { borderRadius, borderTransform } from '../borders';\nimport { gap, rowGap, columnGap } from '../cssGrid';\nimport { paletteTransform } from '../palette';\nimport { maxWidth, sizingTransform } from '../sizing';\nconst defaultSxConfig = {\n // borders\n border: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderTop: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderRight: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderBottom: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderLeft: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderColor: {\n themeKey: 'palette'\n },\n borderTopColor: {\n themeKey: 'palette'\n },\n borderRightColor: {\n themeKey: 'palette'\n },\n borderBottomColor: {\n themeKey: 'palette'\n },\n borderLeftColor: {\n themeKey: 'palette'\n },\n outline: {\n themeKey: 'borders',\n transform: borderTransform\n },\n outlineColor: {\n themeKey: 'palette'\n },\n borderRadius: {\n themeKey: 'shape.borderRadius',\n style: borderRadius\n },\n // palette\n color: {\n themeKey: 'palette',\n transform: paletteTransform\n },\n bgcolor: {\n themeKey: 'palette',\n cssProperty: 'backgroundColor',\n transform: paletteTransform\n },\n backgroundColor: {\n themeKey: 'palette',\n transform: paletteTransform\n },\n // spacing\n p: {\n style: padding\n },\n pt: {\n style: padding\n },\n pr: {\n style: padding\n },\n pb: {\n style: padding\n },\n pl: {\n style: padding\n },\n px: {\n style: padding\n },\n py: {\n style: padding\n },\n padding: {\n style: padding\n },\n paddingTop: {\n style: padding\n },\n paddingRight: {\n style: padding\n },\n paddingBottom: {\n style: padding\n },\n paddingLeft: {\n style: padding\n },\n paddingX: {\n style: padding\n },\n paddingY: {\n style: padding\n },\n paddingInline: {\n style: padding\n },\n paddingInlineStart: {\n style: padding\n },\n paddingInlineEnd: {\n style: padding\n },\n paddingBlock: {\n style: padding\n },\n paddingBlockStart: {\n style: padding\n },\n paddingBlockEnd: {\n style: padding\n },\n m: {\n style: margin\n },\n mt: {\n style: margin\n },\n mr: {\n style: margin\n },\n mb: {\n style: margin\n },\n ml: {\n style: margin\n },\n mx: {\n style: margin\n },\n my: {\n style: margin\n },\n margin: {\n style: margin\n },\n marginTop: {\n style: margin\n },\n marginRight: {\n style: margin\n },\n marginBottom: {\n style: margin\n },\n marginLeft: {\n style: margin\n },\n marginX: {\n style: margin\n },\n marginY: {\n style: margin\n },\n marginInline: {\n style: margin\n },\n marginInlineStart: {\n style: margin\n },\n marginInlineEnd: {\n style: margin\n },\n marginBlock: {\n style: margin\n },\n marginBlockStart: {\n style: margin\n },\n marginBlockEnd: {\n style: margin\n },\n // display\n displayPrint: {\n cssProperty: false,\n transform: value => ({\n '@media print': {\n display: value\n }\n })\n },\n display: {},\n overflow: {},\n textOverflow: {},\n visibility: {},\n whiteSpace: {},\n // flexbox\n flexBasis: {},\n flexDirection: {},\n flexWrap: {},\n justifyContent: {},\n alignItems: {},\n alignContent: {},\n order: {},\n flex: {},\n flexGrow: {},\n flexShrink: {},\n alignSelf: {},\n justifyItems: {},\n justifySelf: {},\n // grid\n gap: {\n style: gap\n },\n rowGap: {\n style: rowGap\n },\n columnGap: {\n style: columnGap\n },\n gridColumn: {},\n gridRow: {},\n gridAutoFlow: {},\n gridAutoColumns: {},\n gridAutoRows: {},\n gridTemplateColumns: {},\n gridTemplateRows: {},\n gridTemplateAreas: {},\n gridArea: {},\n // positions\n position: {},\n zIndex: {\n themeKey: 'zIndex'\n },\n top: {},\n right: {},\n bottom: {},\n left: {},\n // shadows\n boxShadow: {\n themeKey: 'shadows'\n },\n // sizing\n width: {\n transform: sizingTransform\n },\n maxWidth: {\n style: maxWidth\n },\n minWidth: {\n transform: sizingTransform\n },\n height: {\n transform: sizingTransform\n },\n maxHeight: {\n transform: sizingTransform\n },\n minHeight: {\n transform: sizingTransform\n },\n boxSizing: {},\n // typography\n fontFamily: {\n themeKey: 'typography'\n },\n fontSize: {\n themeKey: 'typography'\n },\n fontStyle: {\n themeKey: 'typography'\n },\n fontWeight: {\n themeKey: 'typography'\n },\n letterSpacing: {},\n textTransform: {},\n lineHeight: {},\n textAlign: {},\n typography: {\n cssProperty: false,\n themeKey: 'typography'\n }\n};\nexport default defaultSxConfig;","import capitalize from '@mui/utils/capitalize';\nimport merge from '../merge';\nimport { getPath, getStyleValue as getValue } from '../style';\nimport { handleBreakpoints, createEmptyBreakpointObject, removeUnusedBreakpoints } from '../breakpoints';\nimport defaultSxConfig from './defaultSxConfig';\nfunction objectsHaveSameKeys(...objects) {\n const allKeys = objects.reduce((keys, object) => keys.concat(Object.keys(object)), []);\n const union = new Set(allKeys);\n return objects.every(object => union.size === Object.keys(object).length);\n}\nfunction callIfFn(maybeFn, arg) {\n return typeof maybeFn === 'function' ? maybeFn(arg) : maybeFn;\n}\n\n// eslint-disable-next-line @typescript-eslint/naming-convention\nexport function unstable_createStyleFunctionSx() {\n function getThemeValue(prop, val, theme, config) {\n const props = {\n [prop]: val,\n theme\n };\n const options = config[prop];\n if (!options) {\n return {\n [prop]: val\n };\n }\n const {\n cssProperty = prop,\n themeKey,\n transform,\n style\n } = options;\n if (val == null) {\n return null;\n }\n\n // TODO v6: remove, see https://github.com/mui/material-ui/pull/38123\n if (themeKey === 'typography' && val === 'inherit') {\n return {\n [prop]: val\n };\n }\n const themeMapping = getPath(theme, themeKey) || {};\n if (style) {\n return style(props);\n }\n const styleFromPropValue = propValueFinal => {\n let value = getValue(themeMapping, transform, propValueFinal);\n if (propValueFinal === value && typeof propValueFinal === 'string') {\n // Haven't found value\n value = getValue(themeMapping, transform, `${prop}${propValueFinal === 'default' ? '' : capitalize(propValueFinal)}`, propValueFinal);\n }\n if (cssProperty === false) {\n return value;\n }\n return {\n [cssProperty]: value\n };\n };\n return handleBreakpoints(props, val, styleFromPropValue);\n }\n function styleFunctionSx(props) {\n var _theme$unstable_sxCon;\n const {\n sx,\n theme = {}\n } = props || {};\n if (!sx) {\n return null; // Emotion & styled-components will neglect null\n }\n const config = (_theme$unstable_sxCon = theme.unstable_sxConfig) != null ? _theme$unstable_sxCon : defaultSxConfig;\n\n /*\n * Receive `sxInput` as object or callback\n * and then recursively check keys & values to create media query object styles.\n * (the result will be used in `styled`)\n */\n function traverse(sxInput) {\n let sxObject = sxInput;\n if (typeof sxInput === 'function') {\n sxObject = sxInput(theme);\n } else if (typeof sxInput !== 'object') {\n // value\n return sxInput;\n }\n if (!sxObject) {\n return null;\n }\n const emptyBreakpoints = createEmptyBreakpointObject(theme.breakpoints);\n const breakpointsKeys = Object.keys(emptyBreakpoints);\n let css = emptyBreakpoints;\n Object.keys(sxObject).forEach(styleKey => {\n const value = callIfFn(sxObject[styleKey], theme);\n if (value !== null && value !== undefined) {\n if (typeof value === 'object') {\n if (config[styleKey]) {\n css = merge(css, getThemeValue(styleKey, value, theme, config));\n } else {\n const breakpointsValues = handleBreakpoints({\n theme\n }, value, x => ({\n [styleKey]: x\n }));\n if (objectsHaveSameKeys(breakpointsValues, value)) {\n css[styleKey] = styleFunctionSx({\n sx: value,\n theme\n });\n } else {\n css = merge(css, breakpointsValues);\n }\n }\n } else {\n css = merge(css, getThemeValue(styleKey, value, theme, config));\n }\n }\n });\n return removeUnusedBreakpoints(breakpointsKeys, css);\n }\n return Array.isArray(sx) ? sx.map(traverse) : traverse(sx);\n }\n return styleFunctionSx;\n}\nconst styleFunctionSx = unstable_createStyleFunctionSx();\nstyleFunctionSx.filterProps = ['sx'];\nexport default styleFunctionSx;","/**\n * A universal utility to style components with multiple color modes. Always use it from the theme object.\n * It works with:\n * - [Basic theme](https://mui.com/material-ui/customization/dark-mode/)\n * - [CSS theme variables](https://mui.com/material-ui/experimental-api/css-theme-variables/overview/)\n * - Zero-runtime engine\n *\n * Tips: Use an array over object spread and place `theme.applyStyles()` last.\n *\n * ✅ [{ background: '#e5e5e5' }, theme.applyStyles('dark', { background: '#1c1c1c' })]\n *\n * 🚫 { background: '#e5e5e5', ...theme.applyStyles('dark', { background: '#1c1c1c' })}\n *\n * @example\n * 1. using with `styled`:\n * ```jsx\n * const Component = styled('div')(({ theme }) => [\n * { background: '#e5e5e5' },\n * theme.applyStyles('dark', {\n * background: '#1c1c1c',\n * color: '#fff',\n * }),\n * ]);\n * ```\n *\n * @example\n * 2. using with `sx` prop:\n * ```jsx\n * [\n * { background: '#e5e5e5' },\n * theme.applyStyles('dark', {\n * background: '#1c1c1c',\n * color: '#fff',\n * }),\n * ]}\n * />\n * ```\n *\n * @example\n * 3. theming a component:\n * ```jsx\n * extendTheme({\n * components: {\n * MuiButton: {\n * styleOverrides: {\n * root: ({ theme }) => [\n * { background: '#e5e5e5' },\n * theme.applyStyles('dark', {\n * background: '#1c1c1c',\n * color: '#fff',\n * }),\n * ],\n * },\n * }\n * }\n * })\n *```\n */\nexport default function applyStyles(key, styles) {\n // @ts-expect-error this is 'any' type\n const theme = this;\n if (theme.vars && typeof theme.getColorSchemeSelector === 'function') {\n // If CssVarsProvider is used as a provider,\n // returns '* :where([data-mui-color-scheme=\"light|dark\"]) &'\n const selector = theme.getColorSchemeSelector(key).replace(/(\\[[^\\]]+\\])/, '*:where($1)');\n return {\n [selector]: styles\n };\n }\n if (theme.palette.mode === key) {\n return styles;\n }\n return {};\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"breakpoints\", \"palette\", \"spacing\", \"shape\"];\nimport deepmerge from '@mui/utils/deepmerge';\nimport createBreakpoints from './createBreakpoints';\nimport shape from './shape';\nimport createSpacing from './createSpacing';\nimport styleFunctionSx from '../styleFunctionSx/styleFunctionSx';\nimport defaultSxConfig from '../styleFunctionSx/defaultSxConfig';\nimport applyStyles from './applyStyles';\nfunction createTheme(options = {}, ...args) {\n const {\n breakpoints: breakpointsInput = {},\n palette: paletteInput = {},\n spacing: spacingInput,\n shape: shapeInput = {}\n } = options,\n other = _objectWithoutPropertiesLoose(options, _excluded);\n const breakpoints = createBreakpoints(breakpointsInput);\n const spacing = createSpacing(spacingInput);\n let muiTheme = deepmerge({\n breakpoints,\n direction: 'ltr',\n components: {},\n // Inject component definitions.\n palette: _extends({\n mode: 'light'\n }, paletteInput),\n spacing,\n shape: _extends({}, shape, shapeInput)\n }, other);\n muiTheme.applyStyles = applyStyles;\n muiTheme = args.reduce((acc, argument) => deepmerge(acc, argument), muiTheme);\n muiTheme.unstable_sxConfig = _extends({}, defaultSxConfig, other == null ? void 0 : other.unstable_sxConfig);\n muiTheme.unstable_sx = function sx(props) {\n return styleFunctionSx({\n sx: props,\n theme: this\n });\n };\n return muiTheme;\n}\nexport default createTheme;","'use client';\n\nimport * as React from 'react';\nimport { ThemeContext } from '@mui/styled-engine';\nfunction isObjectEmpty(obj) {\n return Object.keys(obj).length === 0;\n}\nfunction useTheme(defaultTheme = null) {\n const contextTheme = React.useContext(ThemeContext);\n return !contextTheme || isObjectEmpty(contextTheme) ? defaultTheme : contextTheme;\n}\nexport default useTheme;","'use client';\n\nimport createTheme from './createTheme';\nimport useThemeWithoutDefault from './useThemeWithoutDefault';\nexport const systemDefaultTheme = createTheme();\nfunction useTheme(defaultTheme = systemDefaultTheme) {\n return useThemeWithoutDefault(defaultTheme);\n}\nexport default useTheme;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"ownerState\"],\n _excluded2 = [\"variants\"],\n _excluded3 = [\"name\", \"slot\", \"skipVariantsResolver\", \"skipSx\", \"overridesResolver\"];\n/* eslint-disable no-underscore-dangle */\nimport styledEngineStyled, { internal_processStyles as processStyles } from '@mui/styled-engine';\nimport { isPlainObject } from '@mui/utils/deepmerge';\nimport capitalize from '@mui/utils/capitalize';\nimport getDisplayName from '@mui/utils/getDisplayName';\nimport createTheme from './createTheme';\nimport styleFunctionSx from './styleFunctionSx';\nfunction isEmpty(obj) {\n return Object.keys(obj).length === 0;\n}\n\n// https://github.com/emotion-js/emotion/blob/26ded6109fcd8ca9875cc2ce4564fee678a3f3c5/packages/styled/src/utils.js#L40\nfunction isStringTag(tag) {\n return typeof tag === 'string' &&\n // 96 is one less than the char code\n // for \"a\" so this is checking that\n // it's a lowercase character\n tag.charCodeAt(0) > 96;\n}\n\n// Update /system/styled/#api in case if this changes\nexport function shouldForwardProp(prop) {\n return prop !== 'ownerState' && prop !== 'theme' && prop !== 'sx' && prop !== 'as';\n}\nexport const systemDefaultTheme = createTheme();\nconst lowercaseFirstLetter = string => {\n if (!string) {\n return string;\n }\n return string.charAt(0).toLowerCase() + string.slice(1);\n};\nfunction resolveTheme({\n defaultTheme,\n theme,\n themeId\n}) {\n return isEmpty(theme) ? defaultTheme : theme[themeId] || theme;\n}\nfunction defaultOverridesResolver(slot) {\n if (!slot) {\n return null;\n }\n return (props, styles) => styles[slot];\n}\nfunction processStyleArg(callableStyle, _ref) {\n let {\n ownerState\n } = _ref,\n props = _objectWithoutPropertiesLoose(_ref, _excluded);\n const resolvedStylesArg = typeof callableStyle === 'function' ? callableStyle(_extends({\n ownerState\n }, props)) : callableStyle;\n if (Array.isArray(resolvedStylesArg)) {\n return resolvedStylesArg.flatMap(resolvedStyle => processStyleArg(resolvedStyle, _extends({\n ownerState\n }, props)));\n }\n if (!!resolvedStylesArg && typeof resolvedStylesArg === 'object' && Array.isArray(resolvedStylesArg.variants)) {\n const {\n variants = []\n } = resolvedStylesArg,\n otherStyles = _objectWithoutPropertiesLoose(resolvedStylesArg, _excluded2);\n let result = otherStyles;\n variants.forEach(variant => {\n let isMatch = true;\n if (typeof variant.props === 'function') {\n isMatch = variant.props(_extends({\n ownerState\n }, props, ownerState));\n } else {\n Object.keys(variant.props).forEach(key => {\n if ((ownerState == null ? void 0 : ownerState[key]) !== variant.props[key] && props[key] !== variant.props[key]) {\n isMatch = false;\n }\n });\n }\n if (isMatch) {\n if (!Array.isArray(result)) {\n result = [result];\n }\n result.push(typeof variant.style === 'function' ? variant.style(_extends({\n ownerState\n }, props, ownerState)) : variant.style);\n }\n });\n return result;\n }\n return resolvedStylesArg;\n}\nexport default function createStyled(input = {}) {\n const {\n themeId,\n defaultTheme = systemDefaultTheme,\n rootShouldForwardProp = shouldForwardProp,\n slotShouldForwardProp = shouldForwardProp\n } = input;\n const systemSx = props => {\n return styleFunctionSx(_extends({}, props, {\n theme: resolveTheme(_extends({}, props, {\n defaultTheme,\n themeId\n }))\n }));\n };\n systemSx.__mui_systemSx = true;\n return (tag, inputOptions = {}) => {\n // Filter out the `sx` style function from the previous styled component to prevent unnecessary styles generated by the composite components.\n processStyles(tag, styles => styles.filter(style => !(style != null && style.__mui_systemSx)));\n const {\n name: componentName,\n slot: componentSlot,\n skipVariantsResolver: inputSkipVariantsResolver,\n skipSx: inputSkipSx,\n // TODO v6: remove `lowercaseFirstLetter()` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n overridesResolver = defaultOverridesResolver(lowercaseFirstLetter(componentSlot))\n } = inputOptions,\n options = _objectWithoutPropertiesLoose(inputOptions, _excluded3);\n\n // if skipVariantsResolver option is defined, take the value, otherwise, true for root and false for other slots.\n const skipVariantsResolver = inputSkipVariantsResolver !== undefined ? inputSkipVariantsResolver :\n // TODO v6: remove `Root` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n componentSlot && componentSlot !== 'Root' && componentSlot !== 'root' || false;\n const skipSx = inputSkipSx || false;\n let label;\n if (process.env.NODE_ENV !== 'production') {\n if (componentName) {\n // TODO v6: remove `lowercaseFirstLetter()` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n label = `${componentName}-${lowercaseFirstLetter(componentSlot || 'Root')}`;\n }\n }\n let shouldForwardPropOption = shouldForwardProp;\n\n // TODO v6: remove `Root` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n if (componentSlot === 'Root' || componentSlot === 'root') {\n shouldForwardPropOption = rootShouldForwardProp;\n } else if (componentSlot) {\n // any other slot specified\n shouldForwardPropOption = slotShouldForwardProp;\n } else if (isStringTag(tag)) {\n // for string (html) tag, preserve the behavior in emotion & styled-components.\n shouldForwardPropOption = undefined;\n }\n const defaultStyledResolver = styledEngineStyled(tag, _extends({\n shouldForwardProp: shouldForwardPropOption,\n label\n }, options));\n const transformStyleArg = stylesArg => {\n // On the server Emotion doesn't use React.forwardRef for creating components, so the created\n // component stays as a function. This condition makes sure that we do not interpolate functions\n // which are basically components used as a selectors.\n if (typeof stylesArg === 'function' && stylesArg.__emotion_real !== stylesArg || isPlainObject(stylesArg)) {\n return props => processStyleArg(stylesArg, _extends({}, props, {\n theme: resolveTheme({\n theme: props.theme,\n defaultTheme,\n themeId\n })\n }));\n }\n return stylesArg;\n };\n const muiStyledResolver = (styleArg, ...expressions) => {\n let transformedStyleArg = transformStyleArg(styleArg);\n const expressionsWithDefaultTheme = expressions ? expressions.map(transformStyleArg) : [];\n if (componentName && overridesResolver) {\n expressionsWithDefaultTheme.push(props => {\n const theme = resolveTheme(_extends({}, props, {\n defaultTheme,\n themeId\n }));\n if (!theme.components || !theme.components[componentName] || !theme.components[componentName].styleOverrides) {\n return null;\n }\n const styleOverrides = theme.components[componentName].styleOverrides;\n const resolvedStyleOverrides = {};\n // TODO: v7 remove iteration and use `resolveStyleArg(styleOverrides[slot])` directly\n Object.entries(styleOverrides).forEach(([slotKey, slotStyle]) => {\n resolvedStyleOverrides[slotKey] = processStyleArg(slotStyle, _extends({}, props, {\n theme\n }));\n });\n return overridesResolver(props, resolvedStyleOverrides);\n });\n }\n if (componentName && !skipVariantsResolver) {\n expressionsWithDefaultTheme.push(props => {\n var _theme$components;\n const theme = resolveTheme(_extends({}, props, {\n defaultTheme,\n themeId\n }));\n const themeVariants = theme == null || (_theme$components = theme.components) == null || (_theme$components = _theme$components[componentName]) == null ? void 0 : _theme$components.variants;\n return processStyleArg({\n variants: themeVariants\n }, _extends({}, props, {\n theme\n }));\n });\n }\n if (!skipSx) {\n expressionsWithDefaultTheme.push(systemSx);\n }\n const numOfCustomFnsApplied = expressionsWithDefaultTheme.length - expressions.length;\n if (Array.isArray(styleArg) && numOfCustomFnsApplied > 0) {\n const placeholders = new Array(numOfCustomFnsApplied).fill('');\n // If the type is array, than we need to add placeholders in the template for the overrides, variants and the sx styles.\n transformedStyleArg = [...styleArg, ...placeholders];\n transformedStyleArg.raw = [...styleArg.raw, ...placeholders];\n }\n const Component = defaultStyledResolver(transformedStyleArg, ...expressionsWithDefaultTheme);\n if (process.env.NODE_ENV !== 'production') {\n let displayName;\n if (componentName) {\n displayName = `${componentName}${capitalize(componentSlot || '')}`;\n }\n if (displayName === undefined) {\n displayName = `Styled(${getDisplayName(tag)})`;\n }\n Component.displayName = displayName;\n }\n if (tag.muiName) {\n Component.muiName = tag.muiName;\n }\n return Component;\n };\n if (defaultStyledResolver.withConfig) {\n muiStyledResolver.withConfig = defaultStyledResolver.withConfig;\n }\n return muiStyledResolver;\n };\n}","import resolveProps from '@mui/utils/resolveProps';\nexport default function getThemeProps(params) {\n const {\n theme,\n name,\n props\n } = params;\n if (!theme || !theme.components || !theme.components[name] || !theme.components[name].defaultProps) {\n return props;\n }\n return resolveProps(theme.components[name].defaultProps, props);\n}","'use client';\n\nimport getThemeProps from './getThemeProps';\nimport useTheme from '../useTheme';\nexport default function useThemeProps({\n props,\n name,\n defaultTheme,\n themeId\n}) {\n let theme = useTheme(defaultTheme);\n if (themeId) {\n theme = theme[themeId] || theme;\n }\n const mergedProps = getThemeProps({\n theme,\n name,\n props\n });\n return mergedProps;\n}","import _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\n/* eslint-disable @typescript-eslint/naming-convention */\nimport clamp from '@mui/utils/clamp';\n/**\n * Returns a number whose value is limited to the given range.\n * @param {number} value The value to be clamped\n * @param {number} min The lower boundary of the output range\n * @param {number} max The upper boundary of the output range\n * @returns {number} A number in the range [min, max]\n */\nfunction clampWrapper(value, min = 0, max = 1) {\n if (process.env.NODE_ENV !== 'production') {\n if (value < min || value > max) {\n console.error(`MUI: The value provided ${value} is out of range [${min}, ${max}].`);\n }\n }\n return clamp(value, min, max);\n}\n\n/**\n * Converts a color from CSS hex format to CSS rgb format.\n * @param {string} color - Hex color, i.e. #nnn or #nnnnnn\n * @returns {string} A CSS rgb color string\n */\nexport function hexToRgb(color) {\n color = color.slice(1);\n const re = new RegExp(`.{1,${color.length >= 6 ? 2 : 1}}`, 'g');\n let colors = color.match(re);\n if (colors && colors[0].length === 1) {\n colors = colors.map(n => n + n);\n }\n return colors ? `rgb${colors.length === 4 ? 'a' : ''}(${colors.map((n, index) => {\n return index < 3 ? parseInt(n, 16) : Math.round(parseInt(n, 16) / 255 * 1000) / 1000;\n }).join(', ')})` : '';\n}\nfunction intToHex(int) {\n const hex = int.toString(16);\n return hex.length === 1 ? `0${hex}` : hex;\n}\n\n/**\n * Returns an object with the type and values of a color.\n *\n * Note: Does not support rgb % values.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @returns {object} - A MUI color object: {type: string, values: number[]}\n */\nexport function decomposeColor(color) {\n // Idempotent\n if (color.type) {\n return color;\n }\n if (color.charAt(0) === '#') {\n return decomposeColor(hexToRgb(color));\n }\n const marker = color.indexOf('(');\n const type = color.substring(0, marker);\n if (['rgb', 'rgba', 'hsl', 'hsla', 'color'].indexOf(type) === -1) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: Unsupported \\`${color}\\` color.\nThe following formats are supported: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color().` : _formatMuiErrorMessage(9, color));\n }\n let values = color.substring(marker + 1, color.length - 1);\n let colorSpace;\n if (type === 'color') {\n values = values.split(' ');\n colorSpace = values.shift();\n if (values.length === 4 && values[3].charAt(0) === '/') {\n values[3] = values[3].slice(1);\n }\n if (['srgb', 'display-p3', 'a98-rgb', 'prophoto-rgb', 'rec-2020'].indexOf(colorSpace) === -1) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: unsupported \\`${colorSpace}\\` color space.\nThe following color spaces are supported: srgb, display-p3, a98-rgb, prophoto-rgb, rec-2020.` : _formatMuiErrorMessage(10, colorSpace));\n }\n } else {\n values = values.split(',');\n }\n values = values.map(value => parseFloat(value));\n return {\n type,\n values,\n colorSpace\n };\n}\n\n/**\n * Returns a channel created from the input color.\n *\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @returns {string} - The channel for the color, that can be used in rgba or hsla colors\n */\nexport const colorChannel = color => {\n const decomposedColor = decomposeColor(color);\n return decomposedColor.values.slice(0, 3).map((val, idx) => decomposedColor.type.indexOf('hsl') !== -1 && idx !== 0 ? `${val}%` : val).join(' ');\n};\nexport const private_safeColorChannel = (color, warning) => {\n try {\n return colorChannel(color);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n};\n\n/**\n * Converts a color object with type and values to a string.\n * @param {object} color - Decomposed color\n * @param {string} color.type - One of: 'rgb', 'rgba', 'hsl', 'hsla', 'color'\n * @param {array} color.values - [n,n,n] or [n,n,n,n]\n * @returns {string} A CSS color string\n */\nexport function recomposeColor(color) {\n const {\n type,\n colorSpace\n } = color;\n let {\n values\n } = color;\n if (type.indexOf('rgb') !== -1) {\n // Only convert the first 3 values to int (i.e. not alpha)\n values = values.map((n, i) => i < 3 ? parseInt(n, 10) : n);\n } else if (type.indexOf('hsl') !== -1) {\n values[1] = `${values[1]}%`;\n values[2] = `${values[2]}%`;\n }\n if (type.indexOf('color') !== -1) {\n values = `${colorSpace} ${values.join(' ')}`;\n } else {\n values = `${values.join(', ')}`;\n }\n return `${type}(${values})`;\n}\n\n/**\n * Converts a color from CSS rgb format to CSS hex format.\n * @param {string} color - RGB color, i.e. rgb(n, n, n)\n * @returns {string} A CSS rgb color string, i.e. #nnnnnn\n */\nexport function rgbToHex(color) {\n // Idempotent\n if (color.indexOf('#') === 0) {\n return color;\n }\n const {\n values\n } = decomposeColor(color);\n return `#${values.map((n, i) => intToHex(i === 3 ? Math.round(255 * n) : n)).join('')}`;\n}\n\n/**\n * Converts a color from hsl format to rgb format.\n * @param {string} color - HSL color values\n * @returns {string} rgb color values\n */\nexport function hslToRgb(color) {\n color = decomposeColor(color);\n const {\n values\n } = color;\n const h = values[0];\n const s = values[1] / 100;\n const l = values[2] / 100;\n const a = s * Math.min(l, 1 - l);\n const f = (n, k = (n + h / 30) % 12) => l - a * Math.max(Math.min(k - 3, 9 - k, 1), -1);\n let type = 'rgb';\n const rgb = [Math.round(f(0) * 255), Math.round(f(8) * 255), Math.round(f(4) * 255)];\n if (color.type === 'hsla') {\n type += 'a';\n rgb.push(values[3]);\n }\n return recomposeColor({\n type,\n values: rgb\n });\n}\n/**\n * The relative brightness of any point in a color space,\n * normalized to 0 for darkest black and 1 for lightest white.\n *\n * Formula: https://www.w3.org/TR/WCAG20-TECHS/G17.html#G17-tests\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @returns {number} The relative brightness of the color in the range 0 - 1\n */\nexport function getLuminance(color) {\n color = decomposeColor(color);\n let rgb = color.type === 'hsl' || color.type === 'hsla' ? decomposeColor(hslToRgb(color)).values : color.values;\n rgb = rgb.map(val => {\n if (color.type !== 'color') {\n val /= 255; // normalized\n }\n return val <= 0.03928 ? val / 12.92 : ((val + 0.055) / 1.055) ** 2.4;\n });\n\n // Truncate at 3 digits\n return Number((0.2126 * rgb[0] + 0.7152 * rgb[1] + 0.0722 * rgb[2]).toFixed(3));\n}\n\n/**\n * Calculates the contrast ratio between two colors.\n *\n * Formula: https://www.w3.org/TR/WCAG20-TECHS/G17.html#G17-tests\n * @param {string} foreground - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla()\n * @param {string} background - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla()\n * @returns {number} A contrast ratio value in the range 0 - 21.\n */\nexport function getContrastRatio(foreground, background) {\n const lumA = getLuminance(foreground);\n const lumB = getLuminance(background);\n return (Math.max(lumA, lumB) + 0.05) / (Math.min(lumA, lumB) + 0.05);\n}\n\n/**\n * Sets the absolute transparency of a color.\n * Any existing alpha values are overwritten.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} value - value to set the alpha channel to in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function alpha(color, value) {\n color = decomposeColor(color);\n value = clampWrapper(value);\n if (color.type === 'rgb' || color.type === 'hsl') {\n color.type += 'a';\n }\n if (color.type === 'color') {\n color.values[3] = `/${value}`;\n } else {\n color.values[3] = value;\n }\n return recomposeColor(color);\n}\nexport function private_safeAlpha(color, value, warning) {\n try {\n return alpha(color, value);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Darkens a color.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} coefficient - multiplier in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function darken(color, coefficient) {\n color = decomposeColor(color);\n coefficient = clampWrapper(coefficient);\n if (color.type.indexOf('hsl') !== -1) {\n color.values[2] *= 1 - coefficient;\n } else if (color.type.indexOf('rgb') !== -1 || color.type.indexOf('color') !== -1) {\n for (let i = 0; i < 3; i += 1) {\n color.values[i] *= 1 - coefficient;\n }\n }\n return recomposeColor(color);\n}\nexport function private_safeDarken(color, coefficient, warning) {\n try {\n return darken(color, coefficient);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Lightens a color.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} coefficient - multiplier in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function lighten(color, coefficient) {\n color = decomposeColor(color);\n coefficient = clampWrapper(coefficient);\n if (color.type.indexOf('hsl') !== -1) {\n color.values[2] += (100 - color.values[2]) * coefficient;\n } else if (color.type.indexOf('rgb') !== -1) {\n for (let i = 0; i < 3; i += 1) {\n color.values[i] += (255 - color.values[i]) * coefficient;\n }\n } else if (color.type.indexOf('color') !== -1) {\n for (let i = 0; i < 3; i += 1) {\n color.values[i] += (1 - color.values[i]) * coefficient;\n }\n }\n return recomposeColor(color);\n}\nexport function private_safeLighten(color, coefficient, warning) {\n try {\n return lighten(color, coefficient);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Darken or lighten a color, depending on its luminance.\n * Light colors are darkened, dark colors are lightened.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} coefficient=0.15 - multiplier in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function emphasize(color, coefficient = 0.15) {\n return getLuminance(color) > 0.5 ? darken(color, coefficient) : lighten(color, coefficient);\n}\nexport function private_safeEmphasize(color, coefficient, warning) {\n try {\n return emphasize(color, coefficient);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Blend a transparent overlay color with a background color, resulting in a single\n * RGB color.\n * @param {string} background - CSS color\n * @param {string} overlay - CSS color\n * @param {number} opacity - Opacity multiplier in the range 0 - 1\n * @param {number} [gamma=1.0] - Gamma correction factor. For gamma-correct blending, 2.2 is usual.\n */\nexport function blend(background, overlay, opacity, gamma = 1.0) {\n const blendChannel = (b, o) => Math.round((b ** (1 / gamma) * (1 - opacity) + o ** (1 / gamma) * opacity) ** gamma);\n const backgroundColor = decomposeColor(background);\n const overlayColor = decomposeColor(overlay);\n const rgb = [blendChannel(backgroundColor.values[0], overlayColor.values[0]), blendChannel(backgroundColor.values[1], overlayColor.values[1]), blendChannel(backgroundColor.values[2], overlayColor.values[2])];\n return recomposeColor({\n type: 'rgb',\n values: rgb\n });\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nexport default function createMixins(breakpoints, mixins) {\n return _extends({\n toolbar: {\n minHeight: 56,\n [breakpoints.up('xs')]: {\n '@media (orientation: landscape)': {\n minHeight: 48\n }\n },\n [breakpoints.up('sm')]: {\n minHeight: 64\n }\n }\n }, mixins);\n}","const common = {\n black: '#000',\n white: '#fff'\n};\nexport default common;","const grey = {\n 50: '#fafafa',\n 100: '#f5f5f5',\n 200: '#eeeeee',\n 300: '#e0e0e0',\n 400: '#bdbdbd',\n 500: '#9e9e9e',\n 600: '#757575',\n 700: '#616161',\n 800: '#424242',\n 900: '#212121',\n A100: '#f5f5f5',\n A200: '#eeeeee',\n A400: '#bdbdbd',\n A700: '#616161'\n};\nexport default grey;","const purple = {\n 50: '#f3e5f5',\n 100: '#e1bee7',\n 200: '#ce93d8',\n 300: '#ba68c8',\n 400: '#ab47bc',\n 500: '#9c27b0',\n 600: '#8e24aa',\n 700: '#7b1fa2',\n 800: '#6a1b9a',\n 900: '#4a148c',\n A100: '#ea80fc',\n A200: '#e040fb',\n A400: '#d500f9',\n A700: '#aa00ff'\n};\nexport default purple;","const red = {\n 50: '#ffebee',\n 100: '#ffcdd2',\n 200: '#ef9a9a',\n 300: '#e57373',\n 400: '#ef5350',\n 500: '#f44336',\n 600: '#e53935',\n 700: '#d32f2f',\n 800: '#c62828',\n 900: '#b71c1c',\n A100: '#ff8a80',\n A200: '#ff5252',\n A400: '#ff1744',\n A700: '#d50000'\n};\nexport default red;","const orange = {\n 50: '#fff3e0',\n 100: '#ffe0b2',\n 200: '#ffcc80',\n 300: '#ffb74d',\n 400: '#ffa726',\n 500: '#ff9800',\n 600: '#fb8c00',\n 700: '#f57c00',\n 800: '#ef6c00',\n 900: '#e65100',\n A100: '#ffd180',\n A200: '#ffab40',\n A400: '#ff9100',\n A700: '#ff6d00'\n};\nexport default orange;","const blue = {\n 50: '#e3f2fd',\n 100: '#bbdefb',\n 200: '#90caf9',\n 300: '#64b5f6',\n 400: '#42a5f5',\n 500: '#2196f3',\n 600: '#1e88e5',\n 700: '#1976d2',\n 800: '#1565c0',\n 900: '#0d47a1',\n A100: '#82b1ff',\n A200: '#448aff',\n A400: '#2979ff',\n A700: '#2962ff'\n};\nexport default blue;","const lightBlue = {\n 50: '#e1f5fe',\n 100: '#b3e5fc',\n 200: '#81d4fa',\n 300: '#4fc3f7',\n 400: '#29b6f6',\n 500: '#03a9f4',\n 600: '#039be5',\n 700: '#0288d1',\n 800: '#0277bd',\n 900: '#01579b',\n A100: '#80d8ff',\n A200: '#40c4ff',\n A400: '#00b0ff',\n A700: '#0091ea'\n};\nexport default lightBlue;","const green = {\n 50: '#e8f5e9',\n 100: '#c8e6c9',\n 200: '#a5d6a7',\n 300: '#81c784',\n 400: '#66bb6a',\n 500: '#4caf50',\n 600: '#43a047',\n 700: '#388e3c',\n 800: '#2e7d32',\n 900: '#1b5e20',\n A100: '#b9f6ca',\n A200: '#69f0ae',\n A400: '#00e676',\n A700: '#00c853'\n};\nexport default green;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\nconst _excluded = [\"mode\", \"contrastThreshold\", \"tonalOffset\"];\nimport { deepmerge } from '@mui/utils';\nimport { darken, getContrastRatio, lighten } from '@mui/system';\nimport common from '../colors/common';\nimport grey from '../colors/grey';\nimport purple from '../colors/purple';\nimport red from '../colors/red';\nimport orange from '../colors/orange';\nimport blue from '../colors/blue';\nimport lightBlue from '../colors/lightBlue';\nimport green from '../colors/green';\nexport const light = {\n // The colors used to style the text.\n text: {\n // The most important text.\n primary: 'rgba(0, 0, 0, 0.87)',\n // Secondary text.\n secondary: 'rgba(0, 0, 0, 0.6)',\n // Disabled text have even lower visual prominence.\n disabled: 'rgba(0, 0, 0, 0.38)'\n },\n // The color used to divide different elements.\n divider: 'rgba(0, 0, 0, 0.12)',\n // The background colors used to style the surfaces.\n // Consistency between these values is important.\n background: {\n paper: common.white,\n default: common.white\n },\n // The colors used to style the action elements.\n action: {\n // The color of an active action like an icon button.\n active: 'rgba(0, 0, 0, 0.54)',\n // The color of an hovered action.\n hover: 'rgba(0, 0, 0, 0.04)',\n hoverOpacity: 0.04,\n // The color of a selected action.\n selected: 'rgba(0, 0, 0, 0.08)',\n selectedOpacity: 0.08,\n // The color of a disabled action.\n disabled: 'rgba(0, 0, 0, 0.26)',\n // The background color of a disabled action.\n disabledBackground: 'rgba(0, 0, 0, 0.12)',\n disabledOpacity: 0.38,\n focus: 'rgba(0, 0, 0, 0.12)',\n focusOpacity: 0.12,\n activatedOpacity: 0.12\n }\n};\nexport const dark = {\n text: {\n primary: common.white,\n secondary: 'rgba(255, 255, 255, 0.7)',\n disabled: 'rgba(255, 255, 255, 0.5)',\n icon: 'rgba(255, 255, 255, 0.5)'\n },\n divider: 'rgba(255, 255, 255, 0.12)',\n background: {\n paper: '#121212',\n default: '#121212'\n },\n action: {\n active: common.white,\n hover: 'rgba(255, 255, 255, 0.08)',\n hoverOpacity: 0.08,\n selected: 'rgba(255, 255, 255, 0.16)',\n selectedOpacity: 0.16,\n disabled: 'rgba(255, 255, 255, 0.3)',\n disabledBackground: 'rgba(255, 255, 255, 0.12)',\n disabledOpacity: 0.38,\n focus: 'rgba(255, 255, 255, 0.12)',\n focusOpacity: 0.12,\n activatedOpacity: 0.24\n }\n};\nfunction addLightOrDark(intent, direction, shade, tonalOffset) {\n const tonalOffsetLight = tonalOffset.light || tonalOffset;\n const tonalOffsetDark = tonalOffset.dark || tonalOffset * 1.5;\n if (!intent[direction]) {\n if (intent.hasOwnProperty(shade)) {\n intent[direction] = intent[shade];\n } else if (direction === 'light') {\n intent.light = lighten(intent.main, tonalOffsetLight);\n } else if (direction === 'dark') {\n intent.dark = darken(intent.main, tonalOffsetDark);\n }\n }\n}\nfunction getDefaultPrimary(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: blue[200],\n light: blue[50],\n dark: blue[400]\n };\n }\n return {\n main: blue[700],\n light: blue[400],\n dark: blue[800]\n };\n}\nfunction getDefaultSecondary(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: purple[200],\n light: purple[50],\n dark: purple[400]\n };\n }\n return {\n main: purple[500],\n light: purple[300],\n dark: purple[700]\n };\n}\nfunction getDefaultError(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: red[500],\n light: red[300],\n dark: red[700]\n };\n }\n return {\n main: red[700],\n light: red[400],\n dark: red[800]\n };\n}\nfunction getDefaultInfo(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: lightBlue[400],\n light: lightBlue[300],\n dark: lightBlue[700]\n };\n }\n return {\n main: lightBlue[700],\n light: lightBlue[500],\n dark: lightBlue[900]\n };\n}\nfunction getDefaultSuccess(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: green[400],\n light: green[300],\n dark: green[700]\n };\n }\n return {\n main: green[800],\n light: green[500],\n dark: green[900]\n };\n}\nfunction getDefaultWarning(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: orange[400],\n light: orange[300],\n dark: orange[700]\n };\n }\n return {\n main: '#ed6c02',\n // closest to orange[800] that pass 3:1.\n light: orange[500],\n dark: orange[900]\n };\n}\nexport default function createPalette(palette) {\n const {\n mode = 'light',\n contrastThreshold = 3,\n tonalOffset = 0.2\n } = palette,\n other = _objectWithoutPropertiesLoose(palette, _excluded);\n const primary = palette.primary || getDefaultPrimary(mode);\n const secondary = palette.secondary || getDefaultSecondary(mode);\n const error = palette.error || getDefaultError(mode);\n const info = palette.info || getDefaultInfo(mode);\n const success = palette.success || getDefaultSuccess(mode);\n const warning = palette.warning || getDefaultWarning(mode);\n\n // Use the same logic as\n // Bootstrap: https://github.com/twbs/bootstrap/blob/1d6e3710dd447de1a200f29e8fa521f8a0908f70/scss/_functions.scss#L59\n // and material-components-web https://github.com/material-components/material-components-web/blob/ac46b8863c4dab9fc22c4c662dc6bd1b65dd652f/packages/mdc-theme/_functions.scss#L54\n function getContrastText(background) {\n const contrastText = getContrastRatio(background, dark.text.primary) >= contrastThreshold ? dark.text.primary : light.text.primary;\n if (process.env.NODE_ENV !== 'production') {\n const contrast = getContrastRatio(background, contrastText);\n if (contrast < 3) {\n console.error([`MUI: The contrast ratio of ${contrast}:1 for ${contrastText} on ${background}`, 'falls below the WCAG recommended absolute minimum contrast ratio of 3:1.', 'https://www.w3.org/TR/2008/REC-WCAG20-20081211/#visual-audio-contrast-contrast'].join('\\n'));\n }\n }\n return contrastText;\n }\n const augmentColor = ({\n color,\n name,\n mainShade = 500,\n lightShade = 300,\n darkShade = 700\n }) => {\n color = _extends({}, color);\n if (!color.main && color[mainShade]) {\n color.main = color[mainShade];\n }\n if (!color.hasOwnProperty('main')) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: The color${name ? ` (${name})` : ''} provided to augmentColor(color) is invalid.\nThe color object needs to have a \\`main\\` property or a \\`${mainShade}\\` property.` : _formatMuiErrorMessage(11, name ? ` (${name})` : '', mainShade));\n }\n if (typeof color.main !== 'string') {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: The color${name ? ` (${name})` : ''} provided to augmentColor(color) is invalid.\n\\`color.main\\` should be a string, but \\`${JSON.stringify(color.main)}\\` was provided instead.\n\nDid you intend to use one of the following approaches?\n\nimport { green } from \"@mui/material/colors\";\n\nconst theme1 = createTheme({ palette: {\n primary: green,\n} });\n\nconst theme2 = createTheme({ palette: {\n primary: { main: green[500] },\n} });` : _formatMuiErrorMessage(12, name ? ` (${name})` : '', JSON.stringify(color.main)));\n }\n addLightOrDark(color, 'light', lightShade, tonalOffset);\n addLightOrDark(color, 'dark', darkShade, tonalOffset);\n if (!color.contrastText) {\n color.contrastText = getContrastText(color.main);\n }\n return color;\n };\n const modes = {\n dark,\n light\n };\n if (process.env.NODE_ENV !== 'production') {\n if (!modes[mode]) {\n console.error(`MUI: The palette mode \\`${mode}\\` is not supported.`);\n }\n }\n const paletteOutput = deepmerge(_extends({\n // A collection of common colors.\n common: _extends({}, common),\n // prevent mutable object.\n // The palette mode, can be light or dark.\n mode,\n // The colors used to represent primary interface elements for a user.\n primary: augmentColor({\n color: primary,\n name: 'primary'\n }),\n // The colors used to represent secondary interface elements for a user.\n secondary: augmentColor({\n color: secondary,\n name: 'secondary',\n mainShade: 'A400',\n lightShade: 'A200',\n darkShade: 'A700'\n }),\n // The colors used to represent interface elements that the user should be made aware of.\n error: augmentColor({\n color: error,\n name: 'error'\n }),\n // The colors used to represent potentially dangerous actions or important messages.\n warning: augmentColor({\n color: warning,\n name: 'warning'\n }),\n // The colors used to present information to the user that is neutral and not necessarily important.\n info: augmentColor({\n color: info,\n name: 'info'\n }),\n // The colors used to indicate the successful completion of an action that user triggered.\n success: augmentColor({\n color: success,\n name: 'success'\n }),\n // The grey colors.\n grey,\n // Used by `getContrastText()` to maximize the contrast between\n // the background and the text.\n contrastThreshold,\n // Takes a background color and returns the text color that maximizes the contrast.\n getContrastText,\n // Generate a rich color object.\n augmentColor,\n // Used by the functions below to shift a color's luminance by approximately\n // two indexes within its tonal palette.\n // E.g., shift from Red 500 to Red 300 or Red 700.\n tonalOffset\n }, modes[mode]), other);\n return paletteOutput;\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"fontFamily\", \"fontSize\", \"fontWeightLight\", \"fontWeightRegular\", \"fontWeightMedium\", \"fontWeightBold\", \"htmlFontSize\", \"allVariants\", \"pxToRem\"];\nimport { deepmerge } from '@mui/utils';\nfunction round(value) {\n return Math.round(value * 1e5) / 1e5;\n}\nconst caseAllCaps = {\n textTransform: 'uppercase'\n};\nconst defaultFontFamily = '\"Roboto\", \"Helvetica\", \"Arial\", sans-serif';\n\n/**\n * @see @link{https://m2.material.io/design/typography/the-type-system.html}\n * @see @link{https://m2.material.io/design/typography/understanding-typography.html}\n */\nexport default function createTypography(palette, typography) {\n const _ref = typeof typography === 'function' ? typography(palette) : typography,\n {\n fontFamily = defaultFontFamily,\n // The default font size of the Material Specification.\n fontSize = 14,\n // px\n fontWeightLight = 300,\n fontWeightRegular = 400,\n fontWeightMedium = 500,\n fontWeightBold = 700,\n // Tell MUI what's the font-size on the html element.\n // 16px is the default font-size used by browsers.\n htmlFontSize = 16,\n // Apply the CSS properties to all the variants.\n allVariants,\n pxToRem: pxToRem2\n } = _ref,\n other = _objectWithoutPropertiesLoose(_ref, _excluded);\n if (process.env.NODE_ENV !== 'production') {\n if (typeof fontSize !== 'number') {\n console.error('MUI: `fontSize` is required to be a number.');\n }\n if (typeof htmlFontSize !== 'number') {\n console.error('MUI: `htmlFontSize` is required to be a number.');\n }\n }\n const coef = fontSize / 14;\n const pxToRem = pxToRem2 || (size => `${size / htmlFontSize * coef}rem`);\n const buildVariant = (fontWeight, size, lineHeight, letterSpacing, casing) => _extends({\n fontFamily,\n fontWeight,\n fontSize: pxToRem(size),\n // Unitless following https://meyerweb.com/eric/thoughts/2006/02/08/unitless-line-heights/\n lineHeight\n }, fontFamily === defaultFontFamily ? {\n letterSpacing: `${round(letterSpacing / size)}em`\n } : {}, casing, allVariants);\n const variants = {\n h1: buildVariant(fontWeightLight, 96, 1.167, -1.5),\n h2: buildVariant(fontWeightLight, 60, 1.2, -0.5),\n h3: buildVariant(fontWeightRegular, 48, 1.167, 0),\n h4: buildVariant(fontWeightRegular, 34, 1.235, 0.25),\n h5: buildVariant(fontWeightRegular, 24, 1.334, 0),\n h6: buildVariant(fontWeightMedium, 20, 1.6, 0.15),\n subtitle1: buildVariant(fontWeightRegular, 16, 1.75, 0.15),\n subtitle2: buildVariant(fontWeightMedium, 14, 1.57, 0.1),\n body1: buildVariant(fontWeightRegular, 16, 1.5, 0.15),\n body2: buildVariant(fontWeightRegular, 14, 1.43, 0.15),\n button: buildVariant(fontWeightMedium, 14, 1.75, 0.4, caseAllCaps),\n caption: buildVariant(fontWeightRegular, 12, 1.66, 0.4),\n overline: buildVariant(fontWeightRegular, 12, 2.66, 1, caseAllCaps),\n // TODO v6: Remove handling of 'inherit' variant from the theme as it is already handled in Material UI's Typography component. Also, remember to remove the associated types.\n inherit: {\n fontFamily: 'inherit',\n fontWeight: 'inherit',\n fontSize: 'inherit',\n lineHeight: 'inherit',\n letterSpacing: 'inherit'\n }\n };\n return deepmerge(_extends({\n htmlFontSize,\n pxToRem,\n fontFamily,\n fontSize,\n fontWeightLight,\n fontWeightRegular,\n fontWeightMedium,\n fontWeightBold\n }, variants), other, {\n clone: false // No need to clone deep\n });\n}","const shadowKeyUmbraOpacity = 0.2;\nconst shadowKeyPenumbraOpacity = 0.14;\nconst shadowAmbientShadowOpacity = 0.12;\nfunction createShadow(...px) {\n return [`${px[0]}px ${px[1]}px ${px[2]}px ${px[3]}px rgba(0,0,0,${shadowKeyUmbraOpacity})`, `${px[4]}px ${px[5]}px ${px[6]}px ${px[7]}px rgba(0,0,0,${shadowKeyPenumbraOpacity})`, `${px[8]}px ${px[9]}px ${px[10]}px ${px[11]}px rgba(0,0,0,${shadowAmbientShadowOpacity})`].join(',');\n}\n\n// Values from https://github.com/material-components/material-components-web/blob/be8747f94574669cb5e7add1a7c54fa41a89cec7/packages/mdc-elevation/_variables.scss\nconst shadows = ['none', createShadow(0, 2, 1, -1, 0, 1, 1, 0, 0, 1, 3, 0), createShadow(0, 3, 1, -2, 0, 2, 2, 0, 0, 1, 5, 0), createShadow(0, 3, 3, -2, 0, 3, 4, 0, 0, 1, 8, 0), createShadow(0, 2, 4, -1, 0, 4, 5, 0, 0, 1, 10, 0), createShadow(0, 3, 5, -1, 0, 5, 8, 0, 0, 1, 14, 0), createShadow(0, 3, 5, -1, 0, 6, 10, 0, 0, 1, 18, 0), createShadow(0, 4, 5, -2, 0, 7, 10, 1, 0, 2, 16, 1), createShadow(0, 5, 5, -3, 0, 8, 10, 1, 0, 3, 14, 2), createShadow(0, 5, 6, -3, 0, 9, 12, 1, 0, 3, 16, 2), createShadow(0, 6, 6, -3, 0, 10, 14, 1, 0, 4, 18, 3), createShadow(0, 6, 7, -4, 0, 11, 15, 1, 0, 4, 20, 3), createShadow(0, 7, 8, -4, 0, 12, 17, 2, 0, 5, 22, 4), createShadow(0, 7, 8, -4, 0, 13, 19, 2, 0, 5, 24, 4), createShadow(0, 7, 9, -4, 0, 14, 21, 2, 0, 5, 26, 4), createShadow(0, 8, 9, -5, 0, 15, 22, 2, 0, 6, 28, 5), createShadow(0, 8, 10, -5, 0, 16, 24, 2, 0, 6, 30, 5), createShadow(0, 8, 11, -5, 0, 17, 26, 2, 0, 6, 32, 5), createShadow(0, 9, 11, -5, 0, 18, 28, 2, 0, 7, 34, 6), createShadow(0, 9, 12, -6, 0, 19, 29, 2, 0, 7, 36, 6), createShadow(0, 10, 13, -6, 0, 20, 31, 3, 0, 8, 38, 7), createShadow(0, 10, 13, -6, 0, 21, 33, 3, 0, 8, 40, 7), createShadow(0, 10, 14, -6, 0, 22, 35, 3, 0, 8, 42, 7), createShadow(0, 11, 14, -7, 0, 23, 36, 3, 0, 9, 44, 8), createShadow(0, 11, 15, -7, 0, 24, 38, 3, 0, 9, 46, 8)];\nexport default shadows;","import _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nconst _excluded = [\"duration\", \"easing\", \"delay\"];\n// Follow https://material.google.com/motion/duration-easing.html#duration-easing-natural-easing-curves\n// to learn the context in which each easing should be used.\nexport const easing = {\n // This is the most common easing curve.\n easeInOut: 'cubic-bezier(0.4, 0, 0.2, 1)',\n // Objects enter the screen at full velocity from off-screen and\n // slowly decelerate to a resting point.\n easeOut: 'cubic-bezier(0.0, 0, 0.2, 1)',\n // Objects leave the screen at full velocity. They do not decelerate when off-screen.\n easeIn: 'cubic-bezier(0.4, 0, 1, 1)',\n // The sharp curve is used by objects that may return to the screen at any time.\n sharp: 'cubic-bezier(0.4, 0, 0.6, 1)'\n};\n\n// Follow https://m2.material.io/guidelines/motion/duration-easing.html#duration-easing-common-durations\n// to learn when use what timing\nexport const duration = {\n shortest: 150,\n shorter: 200,\n short: 250,\n // most basic recommended timing\n standard: 300,\n // this is to be used in complex animations\n complex: 375,\n // recommended when something is entering screen\n enteringScreen: 225,\n // recommended when something is leaving screen\n leavingScreen: 195\n};\nfunction formatMs(milliseconds) {\n return `${Math.round(milliseconds)}ms`;\n}\nfunction getAutoHeightDuration(height) {\n if (!height) {\n return 0;\n }\n const constant = height / 36;\n\n // https://www.wolframalpha.com/input/?i=(4+%2B+15+*+(x+%2F+36+)+**+0.25+%2B+(x+%2F+36)+%2F+5)+*+10\n return Math.round((4 + 15 * constant ** 0.25 + constant / 5) * 10);\n}\nexport default function createTransitions(inputTransitions) {\n const mergedEasing = _extends({}, easing, inputTransitions.easing);\n const mergedDuration = _extends({}, duration, inputTransitions.duration);\n const create = (props = ['all'], options = {}) => {\n const {\n duration: durationOption = mergedDuration.standard,\n easing: easingOption = mergedEasing.easeInOut,\n delay = 0\n } = options,\n other = _objectWithoutPropertiesLoose(options, _excluded);\n if (process.env.NODE_ENV !== 'production') {\n const isString = value => typeof value === 'string';\n // IE11 support, replace with Number.isNaN\n // eslint-disable-next-line no-restricted-globals\n const isNumber = value => !isNaN(parseFloat(value));\n if (!isString(props) && !Array.isArray(props)) {\n console.error('MUI: Argument \"props\" must be a string or Array.');\n }\n if (!isNumber(durationOption) && !isString(durationOption)) {\n console.error(`MUI: Argument \"duration\" must be a number or a string but found ${durationOption}.`);\n }\n if (!isString(easingOption)) {\n console.error('MUI: Argument \"easing\" must be a string.');\n }\n if (!isNumber(delay) && !isString(delay)) {\n console.error('MUI: Argument \"delay\" must be a number or a string.');\n }\n if (typeof options !== 'object') {\n console.error(['MUI: Secong argument of transition.create must be an object.', \"Arguments should be either `create('prop1', options)` or `create(['prop1', 'prop2'], options)`\"].join('\\n'));\n }\n if (Object.keys(other).length !== 0) {\n console.error(`MUI: Unrecognized argument(s) [${Object.keys(other).join(',')}].`);\n }\n }\n return (Array.isArray(props) ? props : [props]).map(animatedProp => `${animatedProp} ${typeof durationOption === 'string' ? durationOption : formatMs(durationOption)} ${easingOption} ${typeof delay === 'string' ? delay : formatMs(delay)}`).join(',');\n };\n return _extends({\n getAutoHeightDuration,\n create\n }, inputTransitions, {\n easing: mergedEasing,\n duration: mergedDuration\n });\n}","// We need to centralize the zIndex definitions as they work\n// like global values in the browser.\nconst zIndex = {\n mobileStepper: 1000,\n fab: 1050,\n speedDial: 1050,\n appBar: 1100,\n drawer: 1200,\n modal: 1300,\n snackbar: 1400,\n tooltip: 1500\n};\nexport default zIndex;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\nconst _excluded = [\"breakpoints\", \"mixins\", \"spacing\", \"palette\", \"transitions\", \"typography\", \"shape\"];\nimport { deepmerge } from '@mui/utils';\nimport { createTheme as systemCreateTheme, unstable_defaultSxConfig as defaultSxConfig, unstable_styleFunctionSx as styleFunctionSx } from '@mui/system';\nimport generateUtilityClass from '@mui/utils/generateUtilityClass';\nimport createMixins from './createMixins';\nimport createPalette from './createPalette';\nimport createTypography from './createTypography';\nimport shadows from './shadows';\nimport createTransitions from './createTransitions';\nimport zIndex from './zIndex';\nfunction createTheme(options = {}, ...args) {\n const {\n mixins: mixinsInput = {},\n palette: paletteInput = {},\n transitions: transitionsInput = {},\n typography: typographyInput = {}\n } = options,\n other = _objectWithoutPropertiesLoose(options, _excluded);\n if (options.vars) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: \\`vars\\` is a private field used for CSS variables support.\nPlease use another name.` : _formatMuiErrorMessage(18));\n }\n const palette = createPalette(paletteInput);\n const systemTheme = systemCreateTheme(options);\n let muiTheme = deepmerge(systemTheme, {\n mixins: createMixins(systemTheme.breakpoints, mixinsInput),\n palette,\n // Don't use [...shadows] until you've verified its transpiled code is not invoking the iterator protocol.\n shadows: shadows.slice(),\n typography: createTypography(palette, typographyInput),\n transitions: createTransitions(transitionsInput),\n zIndex: _extends({}, zIndex)\n });\n muiTheme = deepmerge(muiTheme, other);\n muiTheme = args.reduce((acc, argument) => deepmerge(acc, argument), muiTheme);\n if (process.env.NODE_ENV !== 'production') {\n // TODO v6: Refactor to use globalStateClassesMapping from @mui/utils once `readOnly` state class is used in Rating component.\n const stateClasses = ['active', 'checked', 'completed', 'disabled', 'error', 'expanded', 'focused', 'focusVisible', 'required', 'selected'];\n const traverse = (node, component) => {\n let key;\n\n // eslint-disable-next-line guard-for-in, no-restricted-syntax\n for (key in node) {\n const child = node[key];\n if (stateClasses.indexOf(key) !== -1 && Object.keys(child).length > 0) {\n if (process.env.NODE_ENV !== 'production') {\n const stateClass = generateUtilityClass('', key);\n console.error([`MUI: The \\`${component}\\` component increases ` + `the CSS specificity of the \\`${key}\\` internal state.`, 'You can not override it like this: ', JSON.stringify(node, null, 2), '', `Instead, you need to use the '&.${stateClass}' syntax:`, JSON.stringify({\n root: {\n [`&.${stateClass}`]: child\n }\n }, null, 2), '', 'https://mui.com/r/state-classes-guide'].join('\\n'));\n }\n // Remove the style to prevent global conflicts.\n node[key] = {};\n }\n }\n };\n Object.keys(muiTheme.components).forEach(component => {\n const styleOverrides = muiTheme.components[component].styleOverrides;\n if (styleOverrides && component.indexOf('Mui') === 0) {\n traverse(styleOverrides, component);\n }\n });\n }\n muiTheme.unstable_sxConfig = _extends({}, defaultSxConfig, other == null ? void 0 : other.unstable_sxConfig);\n muiTheme.unstable_sx = function sx(props) {\n return styleFunctionSx({\n sx: props,\n theme: this\n });\n };\n return muiTheme;\n}\nlet warnedOnce = false;\nexport function createMuiTheme(...args) {\n if (process.env.NODE_ENV !== 'production') {\n if (!warnedOnce) {\n warnedOnce = true;\n console.error(['MUI: the createMuiTheme function was renamed to createTheme.', '', \"You should use `import { createTheme } from '@mui/material/styles'`\"].join('\\n'));\n }\n }\n return createTheme(...args);\n}\nexport default createTheme;","'use client';\n\nimport createTheme from './createTheme';\nconst defaultTheme = createTheme();\nexport default defaultTheme;","export default '$$material';","'use client';\n\nimport { useThemeProps as systemUseThemeProps } from '@mui/system';\nimport defaultTheme from './defaultTheme';\nimport THEME_ID from './identifier';\nexport default function useThemeProps({\n props,\n name\n}) {\n return systemUseThemeProps({\n props,\n name,\n defaultTheme,\n themeId: THEME_ID\n });\n}","'use client';\n\nimport { createStyled, shouldForwardProp } from '@mui/system';\nimport defaultTheme from './defaultTheme';\nimport THEME_ID from './identifier';\nexport const rootShouldForwardProp = prop => shouldForwardProp(prop) && prop !== 'classes';\nexport const slotShouldForwardProp = shouldForwardProp;\nconst styled = createStyled({\n themeId: THEME_ID,\n defaultTheme,\n rootShouldForwardProp\n});\nexport default styled;","import generateUtilityClasses from '@mui/utils/generateUtilityClasses';\nimport generateUtilityClass from '@mui/utils/generateUtilityClass';\nexport function getSvgIconUtilityClass(slot) {\n return generateUtilityClass('MuiSvgIcon', slot);\n}\nconst svgIconClasses = generateUtilityClasses('MuiSvgIcon', ['root', 'colorPrimary', 'colorSecondary', 'colorAction', 'colorError', 'colorDisabled', 'fontSizeInherit', 'fontSizeSmall', 'fontSizeMedium', 'fontSizeLarge']);\nexport default svgIconClasses;","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"children\", \"className\", \"color\", \"component\", \"fontSize\", \"htmlColor\", \"inheritViewBox\", \"titleAccess\", \"viewBox\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport clsx from 'clsx';\nimport { unstable_composeClasses as composeClasses } from '@mui/base/composeClasses';\nimport capitalize from '../utils/capitalize';\nimport useThemeProps from '../styles/useThemeProps';\nimport styled from '../styles/styled';\nimport { getSvgIconUtilityClass } from './svgIconClasses';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nimport { jsxs as _jsxs } from \"react/jsx-runtime\";\nconst useUtilityClasses = ownerState => {\n const {\n color,\n fontSize,\n classes\n } = ownerState;\n const slots = {\n root: ['root', color !== 'inherit' && `color${capitalize(color)}`, `fontSize${capitalize(fontSize)}`]\n };\n return composeClasses(slots, getSvgIconUtilityClass, classes);\n};\nconst SvgIconRoot = styled('svg', {\n name: 'MuiSvgIcon',\n slot: 'Root',\n overridesResolver: (props, styles) => {\n const {\n ownerState\n } = props;\n return [styles.root, ownerState.color !== 'inherit' && styles[`color${capitalize(ownerState.color)}`], styles[`fontSize${capitalize(ownerState.fontSize)}`]];\n }\n})(({\n theme,\n ownerState\n}) => {\n var _theme$transitions, _theme$transitions$cr, _theme$transitions2, _theme$typography, _theme$typography$pxT, _theme$typography2, _theme$typography2$px, _theme$typography3, _theme$typography3$px, _palette$ownerState$c, _palette, _palette2, _palette3;\n return {\n userSelect: 'none',\n width: '1em',\n height: '1em',\n display: 'inline-block',\n // the will define the property that has `currentColor`\n // e.g. heroicons uses fill=\"none\" and stroke=\"currentColor\"\n fill: ownerState.hasSvgAsChild ? undefined : 'currentColor',\n flexShrink: 0,\n transition: (_theme$transitions = theme.transitions) == null || (_theme$transitions$cr = _theme$transitions.create) == null ? void 0 : _theme$transitions$cr.call(_theme$transitions, 'fill', {\n duration: (_theme$transitions2 = theme.transitions) == null || (_theme$transitions2 = _theme$transitions2.duration) == null ? void 0 : _theme$transitions2.shorter\n }),\n fontSize: {\n inherit: 'inherit',\n small: ((_theme$typography = theme.typography) == null || (_theme$typography$pxT = _theme$typography.pxToRem) == null ? void 0 : _theme$typography$pxT.call(_theme$typography, 20)) || '1.25rem',\n medium: ((_theme$typography2 = theme.typography) == null || (_theme$typography2$px = _theme$typography2.pxToRem) == null ? void 0 : _theme$typography2$px.call(_theme$typography2, 24)) || '1.5rem',\n large: ((_theme$typography3 = theme.typography) == null || (_theme$typography3$px = _theme$typography3.pxToRem) == null ? void 0 : _theme$typography3$px.call(_theme$typography3, 35)) || '2.1875rem'\n }[ownerState.fontSize],\n // TODO v5 deprecate, v6 remove for sx\n color: (_palette$ownerState$c = (_palette = (theme.vars || theme).palette) == null || (_palette = _palette[ownerState.color]) == null ? void 0 : _palette.main) != null ? _palette$ownerState$c : {\n action: (_palette2 = (theme.vars || theme).palette) == null || (_palette2 = _palette2.action) == null ? void 0 : _palette2.active,\n disabled: (_palette3 = (theme.vars || theme).palette) == null || (_palette3 = _palette3.action) == null ? void 0 : _palette3.disabled,\n inherit: undefined\n }[ownerState.color]\n };\n});\nconst SvgIcon = /*#__PURE__*/React.forwardRef(function SvgIcon(inProps, ref) {\n const props = useThemeProps({\n props: inProps,\n name: 'MuiSvgIcon'\n });\n const {\n children,\n className,\n color = 'inherit',\n component = 'svg',\n fontSize = 'medium',\n htmlColor,\n inheritViewBox = false,\n titleAccess,\n viewBox = '0 0 24 24'\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const hasSvgAsChild = /*#__PURE__*/React.isValidElement(children) && children.type === 'svg';\n const ownerState = _extends({}, props, {\n color,\n component,\n fontSize,\n instanceFontSize: inProps.fontSize,\n inheritViewBox,\n viewBox,\n hasSvgAsChild\n });\n const more = {};\n if (!inheritViewBox) {\n more.viewBox = viewBox;\n }\n const classes = useUtilityClasses(ownerState);\n return /*#__PURE__*/_jsxs(SvgIconRoot, _extends({\n as: component,\n className: clsx(classes.root, className),\n focusable: \"false\",\n color: htmlColor,\n \"aria-hidden\": titleAccess ? undefined : true,\n role: titleAccess ? 'img' : undefined,\n ref: ref\n }, more, other, hasSvgAsChild && children.props, {\n ownerState: ownerState,\n children: [hasSvgAsChild ? children.props.children : children, titleAccess ? /*#__PURE__*/_jsx(\"title\", {\n children: titleAccess\n }) : null]\n }));\n});\nprocess.env.NODE_ENV !== \"production\" ? SvgIcon.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the d.ts file and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * Node passed into the SVG element.\n */\n children: PropTypes.node,\n /**\n * Override or extend the styles applied to the component.\n */\n classes: PropTypes.object,\n /**\n * @ignore\n */\n className: PropTypes.string,\n /**\n * The color of the component.\n * It supports both default and custom theme colors, which can be added as shown in the\n * [palette customization guide](https://mui.com/material-ui/customization/palette/#custom-colors).\n * You can use the `htmlColor` prop to apply a color attribute to the SVG element.\n * @default 'inherit'\n */\n color: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.oneOf(['inherit', 'action', 'disabled', 'primary', 'secondary', 'error', 'info', 'success', 'warning']), PropTypes.string]),\n /**\n * The component used for the root node.\n * Either a string to use a HTML element or a component.\n */\n component: PropTypes.elementType,\n /**\n * The fontSize applied to the icon. Defaults to 24px, but can be configure to inherit font size.\n * @default 'medium'\n */\n fontSize: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.oneOf(['inherit', 'large', 'medium', 'small']), PropTypes.string]),\n /**\n * Applies a color attribute to the SVG element.\n */\n htmlColor: PropTypes.string,\n /**\n * If `true`, the root node will inherit the custom `component`'s viewBox and the `viewBox`\n * prop will be ignored.\n * Useful when you want to reference a custom `component` and have `SvgIcon` pass that\n * `component`'s viewBox to the root node.\n * @default false\n */\n inheritViewBox: PropTypes.bool,\n /**\n * The shape-rendering attribute. The behavior of the different options is described on the\n * [MDN Web Docs](https://developer.mozilla.org/en-US/docs/Web/SVG/Attribute/shape-rendering).\n * If you are having issues with blurry icons you should investigate this prop.\n */\n shapeRendering: PropTypes.string,\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Provides a human-readable title for the element that contains it.\n * https://www.w3.org/TR/SVG-access/#Equivalent\n */\n titleAccess: PropTypes.string,\n /**\n * Allows you to redefine what the coordinates without units mean inside an SVG element.\n * For example, if the SVG element is 500 (width) by 200 (height),\n * and you pass viewBox=\"0 0 50 20\",\n * this means that the coordinates inside the SVG will go from the top left corner (0,0)\n * to bottom right (50,20) and each unit will be worth 10px.\n * @default '0 0 24 24'\n */\n viewBox: PropTypes.string\n} : void 0;\nSvgIcon.muiName = 'SvgIcon';\nexport default SvgIcon;","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport * as React from 'react';\nimport SvgIcon from '../SvgIcon';\n\n/**\n * Private module reserved for @mui packages.\n */\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nexport default function createSvgIcon(path, displayName) {\n function Component(props, ref) {\n return /*#__PURE__*/_jsx(SvgIcon, _extends({\n \"data-testid\": `${displayName}Icon`,\n ref: ref\n }, props, {\n children: path\n }));\n }\n if (process.env.NODE_ENV !== 'production') {\n // Need to set `displayName` on the inner component for React.memo.\n // React prior to 16.14 ignores `displayName` on the wrapper.\n Component.displayName = `${displayName}Icon`;\n }\n Component.muiName = SvgIcon.muiName;\n return /*#__PURE__*/React.memo( /*#__PURE__*/React.forwardRef(Component));\n}","'use client';\n\nimport { unstable_ClassNameGenerator as ClassNameGenerator } from '@mui/base/ClassNameGenerator';\nexport { default as capitalize } from './capitalize';\nexport { default as createChainedFunction } from './createChainedFunction';\nexport { default as createSvgIcon } from './createSvgIcon';\nexport { default as debounce } from './debounce';\nexport { default as deprecatedPropType } from './deprecatedPropType';\nexport { default as isMuiElement } from './isMuiElement';\nexport { default as ownerDocument } from './ownerDocument';\nexport { default as ownerWindow } from './ownerWindow';\nexport { default as requirePropFactory } from './requirePropFactory';\nexport { default as setRef } from './setRef';\nexport { default as unstable_useEnhancedEffect } from './useEnhancedEffect';\nexport { default as unstable_useId } from './useId';\nexport { default as unsupportedProp } from './unsupportedProp';\nexport { default as useControlled } from './useControlled';\nexport { default as useEventCallback } from './useEventCallback';\nexport { default as useForkRef } from './useForkRef';\nexport { default as useIsFocusVisible } from './useIsFocusVisible';\n// TODO: remove this export once ClassNameGenerator is stable\n// eslint-disable-next-line @typescript-eslint/naming-convention\nexport const unstable_ClassNameGenerator = {\n configure: generator => {\n if (process.env.NODE_ENV !== 'production') {\n console.warn(['MUI: `ClassNameGenerator` import from `@mui/material/utils` is outdated and might cause unexpected issues.', '', \"You should use `import { unstable_ClassNameGenerator } from '@mui/material/className'` instead\", '', 'The detail of the issue: https://github.com/mui/material-ui/issues/30011#issuecomment-1024993401', '', 'The updated documentation: https://mui.com/guides/classname-generator/'].join('\\n'));\n }\n ClassNameGenerator.configure(generator);\n }\n};","\"use strict\";\n'use client';\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nObject.defineProperty(exports, \"default\", {\n enumerable: true,\n get: function () {\n return _utils.createSvgIcon;\n }\n});\nvar _utils = require(\"@mui/material/utils\");","\"use strict\";\n\"use client\";\n\nvar _interopRequireDefault = require(\"@babel/runtime/helpers/interopRequireDefault\");\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = void 0;\nvar _createSvgIcon = _interopRequireDefault(require(\"./utils/createSvgIcon\"));\nvar _jsxRuntime = require(\"react/jsx-runtime\");\nvar _default = exports.default = (0, _createSvgIcon.default)( /*#__PURE__*/(0, _jsxRuntime.jsx)(\"path\", {\n d: \"m10 17 5-5-5-5z\"\n}), 'ArrowRight');","/**\n * Determines if a given element is a DOM element name (i.e. not a React component).\n */\nexport function isHostComponent(element) {\n return typeof element === 'string';\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport { isHostComponent } from './isHostComponent';\n\n/**\n * Type of the ownerState based on the type of an element it applies to.\n * This resolves to the provided OwnerState for React components and `undefined` for host components.\n * Falls back to `OwnerState | undefined` when the exact type can't be determined in development time.\n */\n\n/**\n * Appends the ownerState object to the props, merging with the existing one if necessary.\n *\n * @param elementType Type of the element that owns the `existingProps`. If the element is a DOM node or undefined, `ownerState` is not applied.\n * @param otherProps Props of the element.\n * @param ownerState\n */\nexport function appendOwnerState(elementType, otherProps, ownerState) {\n if (elementType === undefined || isHostComponent(elementType)) {\n return otherProps;\n }\n return _extends({}, otherProps, {\n ownerState: _extends({}, otherProps.ownerState, ownerState)\n });\n}","'use client';\n\nimport * as React from 'react';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nconst defaultContextValue = {\n disableDefaultClasses: false\n};\nconst ClassNameConfiguratorContext = /*#__PURE__*/React.createContext(defaultContextValue);\n/**\n * @ignore - internal hook.\n *\n * Wraps the `generateUtilityClass` function and controls how the classes are generated.\n * Currently it only affects whether the classes are applied or not.\n *\n * @returns Function to be called with the `generateUtilityClass` function specific to a component to generate the classes.\n */\nexport function useClassNamesOverride(generateUtilityClass) {\n const {\n disableDefaultClasses\n } = React.useContext(ClassNameConfiguratorContext);\n return slot => {\n if (disableDefaultClasses) {\n return '';\n }\n return generateUtilityClass(slot);\n };\n}\n\n/**\n * Allows to configure the components within to not apply any built-in classes.\n */\nexport function ClassNameConfigurator(props) {\n const {\n disableDefaultClasses,\n children\n } = props;\n const contextValue = React.useMemo(() => ({\n disableDefaultClasses: disableDefaultClasses != null ? disableDefaultClasses : false\n }), [disableDefaultClasses]);\n return /*#__PURE__*/_jsx(ClassNameConfiguratorContext.Provider, {\n value: contextValue,\n children: children\n });\n}","/**\n * Extracts event handlers from a given object.\n * A prop is considered an event handler if it is a function and its name starts with `on`.\n *\n * @param object An object to extract event handlers from.\n * @param excludeKeys An array of keys to exclude from the returned object.\n */\nexport function extractEventHandlers(object, excludeKeys = []) {\n if (object === undefined) {\n return {};\n }\n const result = {};\n Object.keys(object).filter(prop => prop.match(/^on[A-Z]/) && typeof object[prop] === 'function' && !excludeKeys.includes(prop)).forEach(prop => {\n result[prop] = object[prop];\n });\n return result;\n}","/**\n * If `componentProps` is a function, calls it with the provided `ownerState`.\n * Otherwise, just returns `componentProps`.\n */\nexport function resolveComponentProps(componentProps, ownerState, slotState) {\n if (typeof componentProps === 'function') {\n return componentProps(ownerState, slotState);\n }\n return componentProps;\n}","/**\n * Removes event handlers from the given object.\n * A field is considered an event handler if it is a function with a name beginning with `on`.\n *\n * @param object Object to remove event handlers from.\n * @returns Object with event handlers removed.\n */\nexport function omitEventHandlers(object) {\n if (object === undefined) {\n return {};\n }\n const result = {};\n Object.keys(object).filter(prop => !(prop.match(/^on[A-Z]/) && typeof object[prop] === 'function')).forEach(prop => {\n result[prop] = object[prop];\n });\n return result;\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport clsx from 'clsx';\nimport { extractEventHandlers } from './extractEventHandlers';\nimport { omitEventHandlers } from './omitEventHandlers';\n/**\n * Merges the slot component internal props (usually coming from a hook)\n * with the externally provided ones.\n *\n * The merge order is (the latter overrides the former):\n * 1. The internal props (specified as a getter function to work with get*Props hook result)\n * 2. Additional props (specified internally on a Base UI component)\n * 3. External props specified on the owner component. These should only be used on a root slot.\n * 4. External props specified in the `slotProps.*` prop.\n * 5. The `className` prop - combined from all the above.\n * @param parameters\n * @returns\n */\nexport function mergeSlotProps(parameters) {\n const {\n getSlotProps,\n additionalProps,\n externalSlotProps,\n externalForwardedProps,\n className\n } = parameters;\n if (!getSlotProps) {\n // The simpler case - getSlotProps is not defined, so no internal event handlers are defined,\n // so we can simply merge all the props without having to worry about extracting event handlers.\n const joinedClasses = clsx(additionalProps == null ? void 0 : additionalProps.className, className, externalForwardedProps == null ? void 0 : externalForwardedProps.className, externalSlotProps == null ? void 0 : externalSlotProps.className);\n const mergedStyle = _extends({}, additionalProps == null ? void 0 : additionalProps.style, externalForwardedProps == null ? void 0 : externalForwardedProps.style, externalSlotProps == null ? void 0 : externalSlotProps.style);\n const props = _extends({}, additionalProps, externalForwardedProps, externalSlotProps);\n if (joinedClasses.length > 0) {\n props.className = joinedClasses;\n }\n if (Object.keys(mergedStyle).length > 0) {\n props.style = mergedStyle;\n }\n return {\n props,\n internalRef: undefined\n };\n }\n\n // In this case, getSlotProps is responsible for calling the external event handlers.\n // We don't need to include them in the merged props because of this.\n\n const eventHandlers = extractEventHandlers(_extends({}, externalForwardedProps, externalSlotProps));\n const componentsPropsWithoutEventHandlers = omitEventHandlers(externalSlotProps);\n const otherPropsWithoutEventHandlers = omitEventHandlers(externalForwardedProps);\n const internalSlotProps = getSlotProps(eventHandlers);\n\n // The order of classes is important here.\n // Emotion (that we use in libraries consuming Base UI) depends on this order\n // to properly override style. It requires the most important classes to be last\n // (see https://github.com/mui/material-ui/pull/33205) for the related discussion.\n const joinedClasses = clsx(internalSlotProps == null ? void 0 : internalSlotProps.className, additionalProps == null ? void 0 : additionalProps.className, className, externalForwardedProps == null ? void 0 : externalForwardedProps.className, externalSlotProps == null ? void 0 : externalSlotProps.className);\n const mergedStyle = _extends({}, internalSlotProps == null ? void 0 : internalSlotProps.style, additionalProps == null ? void 0 : additionalProps.style, externalForwardedProps == null ? void 0 : externalForwardedProps.style, externalSlotProps == null ? void 0 : externalSlotProps.style);\n const props = _extends({}, internalSlotProps, additionalProps, otherPropsWithoutEventHandlers, componentsPropsWithoutEventHandlers);\n if (joinedClasses.length > 0) {\n props.className = joinedClasses;\n }\n if (Object.keys(mergedStyle).length > 0) {\n props.style = mergedStyle;\n }\n return {\n props,\n internalRef: internalSlotProps.ref\n };\n}","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"elementType\", \"externalSlotProps\", \"ownerState\", \"skipResolvingSlotProps\"];\nimport { unstable_useForkRef as useForkRef } from '@mui/utils';\nimport { appendOwnerState } from './appendOwnerState';\nimport { mergeSlotProps } from './mergeSlotProps';\nimport { resolveComponentProps } from './resolveComponentProps';\n/**\n * @ignore - do not document.\n * Builds the props to be passed into the slot of an unstyled component.\n * It merges the internal props of the component with the ones supplied by the user, allowing to customize the behavior.\n * If the slot component is not a host component, it also merges in the `ownerState`.\n *\n * @param parameters.getSlotProps - A function that returns the props to be passed to the slot component.\n */\nexport function useSlotProps(parameters) {\n var _parameters$additiona;\n const {\n elementType,\n externalSlotProps,\n ownerState,\n skipResolvingSlotProps = false\n } = parameters,\n rest = _objectWithoutPropertiesLoose(parameters, _excluded);\n const resolvedComponentsProps = skipResolvingSlotProps ? {} : resolveComponentProps(externalSlotProps, ownerState);\n const {\n props: mergedProps,\n internalRef\n } = mergeSlotProps(_extends({}, rest, {\n externalSlotProps: resolvedComponentsProps\n }));\n const ref = useForkRef(internalRef, resolvedComponentsProps == null ? void 0 : resolvedComponentsProps.ref, (_parameters$additiona = parameters.additionalProps) == null ? void 0 : _parameters$additiona.ref);\n const props = appendOwnerState(elementType, _extends({}, mergedProps, {\n ref\n }), ownerState);\n return props;\n}","import { globalStateClasses } from '@mui/utils/generateUtilityClass';\nconst GLOBAL_CLASS_PREFIX = 'base';\nfunction buildStateClass(state) {\n return `${GLOBAL_CLASS_PREFIX}--${state}`;\n}\nfunction buildSlotClass(componentName, slot) {\n return `${GLOBAL_CLASS_PREFIX}-${componentName}-${slot}`;\n}\nexport function generateUtilityClass(componentName, slot) {\n const globalStateClass = globalStateClasses[slot];\n return globalStateClass ? buildStateClass(globalStateClass) : buildSlotClass(componentName, slot);\n}\nexport function isGlobalState(slot) {\n return globalStateClasses[slot] !== undefined;\n}","import { generateUtilityClass } from '../generateUtilityClass';\nexport function generateUtilityClasses(componentName, slots) {\n const result = {};\n slots.forEach(slot => {\n result[slot] = generateUtilityClass(componentName, slot);\n });\n return result;\n}","'use client';\n\nimport * as React from 'react';\nimport * as ReactDOM from 'react-dom';\nimport PropTypes from 'prop-types';\nimport { exactProp, HTMLElementType, unstable_useEnhancedEffect as useEnhancedEffect, unstable_useForkRef as useForkRef, unstable_setRef as setRef } from '@mui/utils';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nfunction getContainer(container) {\n return typeof container === 'function' ? container() : container;\n}\n\n/**\n * Portals provide a first-class way to render children into a DOM node\n * that exists outside the DOM hierarchy of the parent component.\n *\n * Demos:\n *\n * - [Portal](https://mui.com/base-ui/react-portal/)\n *\n * API:\n *\n * - [Portal API](https://mui.com/base-ui/react-portal/components-api/#portal)\n */\nconst Portal = /*#__PURE__*/React.forwardRef(function Portal(props, forwardedRef) {\n const {\n children,\n container,\n disablePortal = false\n } = props;\n const [mountNode, setMountNode] = React.useState(null);\n // @ts-expect-error TODO upstream fix\n const handleRef = useForkRef( /*#__PURE__*/React.isValidElement(children) ? children.ref : null, forwardedRef);\n useEnhancedEffect(() => {\n if (!disablePortal) {\n setMountNode(getContainer(container) || document.body);\n }\n }, [container, disablePortal]);\n useEnhancedEffect(() => {\n if (mountNode && !disablePortal) {\n setRef(forwardedRef, mountNode);\n return () => {\n setRef(forwardedRef, null);\n };\n }\n return undefined;\n }, [forwardedRef, mountNode, disablePortal]);\n if (disablePortal) {\n if ( /*#__PURE__*/React.isValidElement(children)) {\n const newProps = {\n ref: handleRef\n };\n return /*#__PURE__*/React.cloneElement(children, newProps);\n }\n return /*#__PURE__*/_jsx(React.Fragment, {\n children: children\n });\n }\n return /*#__PURE__*/_jsx(React.Fragment, {\n children: mountNode ? /*#__PURE__*/ReactDOM.createPortal(children, mountNode) : mountNode\n });\n});\nprocess.env.NODE_ENV !== \"production\" ? Portal.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * The children to render into the `container`.\n */\n children: PropTypes.node,\n /**\n * An HTML element or function that returns one.\n * The `container` will have the portal children appended to it.\n *\n * You can also provide a callback, which is called in a React layout effect.\n * This lets you set the container from a ref, and also makes server-side rendering possible.\n *\n * By default, it uses the body of the top-level document object,\n * so it's simply `document.body` most of the time.\n */\n container: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.func]),\n /**\n * The `children` will be under the DOM hierarchy of the parent component.\n * @default false\n */\n disablePortal: PropTypes.bool\n} : void 0;\nif (process.env.NODE_ENV !== 'production') {\n // eslint-disable-next-line\n Portal['propTypes' + ''] = exactProp(Portal.propTypes);\n}\nexport { Portal };","export var top = 'top';\nexport var bottom = 'bottom';\nexport var right = 'right';\nexport var left = 'left';\nexport var auto = 'auto';\nexport var basePlacements = [top, bottom, right, left];\nexport var start = 'start';\nexport var end = 'end';\nexport var clippingParents = 'clippingParents';\nexport var viewport = 'viewport';\nexport var popper = 'popper';\nexport var reference = 'reference';\nexport var variationPlacements = /*#__PURE__*/basePlacements.reduce(function (acc, placement) {\n return acc.concat([placement + \"-\" + start, placement + \"-\" + end]);\n}, []);\nexport var placements = /*#__PURE__*/[].concat(basePlacements, [auto]).reduce(function (acc, placement) {\n return acc.concat([placement, placement + \"-\" + start, placement + \"-\" + end]);\n}, []); // modifiers that need to read the DOM\n\nexport var beforeRead = 'beforeRead';\nexport var read = 'read';\nexport var afterRead = 'afterRead'; // pure-logic modifiers\n\nexport var beforeMain = 'beforeMain';\nexport var main = 'main';\nexport var afterMain = 'afterMain'; // modifier with the purpose to write to the DOM (or write into a framework state)\n\nexport var beforeWrite = 'beforeWrite';\nexport var write = 'write';\nexport var afterWrite = 'afterWrite';\nexport var modifierPhases = [beforeRead, read, afterRead, beforeMain, main, afterMain, beforeWrite, write, afterWrite];","export default function getNodeName(element) {\n return element ? (element.nodeName || '').toLowerCase() : null;\n}","export default function getWindow(node) {\n if (node == null) {\n return window;\n }\n\n if (node.toString() !== '[object Window]') {\n var ownerDocument = node.ownerDocument;\n return ownerDocument ? ownerDocument.defaultView || window : window;\n }\n\n return node;\n}","import getWindow from \"./getWindow.js\";\n\nfunction isElement(node) {\n var OwnElement = getWindow(node).Element;\n return node instanceof OwnElement || node instanceof Element;\n}\n\nfunction isHTMLElement(node) {\n var OwnElement = getWindow(node).HTMLElement;\n return node instanceof OwnElement || node instanceof HTMLElement;\n}\n\nfunction isShadowRoot(node) {\n // IE 11 has no ShadowRoot\n if (typeof ShadowRoot === 'undefined') {\n return false;\n }\n\n var OwnElement = getWindow(node).ShadowRoot;\n return node instanceof OwnElement || node instanceof ShadowRoot;\n}\n\nexport { isElement, isHTMLElement, isShadowRoot };","import getNodeName from \"../dom-utils/getNodeName.js\";\nimport { isHTMLElement } from \"../dom-utils/instanceOf.js\"; // This modifier takes the styles prepared by the `computeStyles` modifier\n// and applies them to the HTMLElements such as popper and arrow\n\nfunction applyStyles(_ref) {\n var state = _ref.state;\n Object.keys(state.elements).forEach(function (name) {\n var style = state.styles[name] || {};\n var attributes = state.attributes[name] || {};\n var element = state.elements[name]; // arrow is optional + virtual elements\n\n if (!isHTMLElement(element) || !getNodeName(element)) {\n return;\n } // Flow doesn't support to extend this property, but it's the most\n // effective way to apply styles to an HTMLElement\n // $FlowFixMe[cannot-write]\n\n\n Object.assign(element.style, style);\n Object.keys(attributes).forEach(function (name) {\n var value = attributes[name];\n\n if (value === false) {\n element.removeAttribute(name);\n } else {\n element.setAttribute(name, value === true ? '' : value);\n }\n });\n });\n}\n\nfunction effect(_ref2) {\n var state = _ref2.state;\n var initialStyles = {\n popper: {\n position: state.options.strategy,\n left: '0',\n top: '0',\n margin: '0'\n },\n arrow: {\n position: 'absolute'\n },\n reference: {}\n };\n Object.assign(state.elements.popper.style, initialStyles.popper);\n state.styles = initialStyles;\n\n if (state.elements.arrow) {\n Object.assign(state.elements.arrow.style, initialStyles.arrow);\n }\n\n return function () {\n Object.keys(state.elements).forEach(function (name) {\n var element = state.elements[name];\n var attributes = state.attributes[name] || {};\n var styleProperties = Object.keys(state.styles.hasOwnProperty(name) ? state.styles[name] : initialStyles[name]); // Set all values to an empty string to unset them\n\n var style = styleProperties.reduce(function (style, property) {\n style[property] = '';\n return style;\n }, {}); // arrow is optional + virtual elements\n\n if (!isHTMLElement(element) || !getNodeName(element)) {\n return;\n }\n\n Object.assign(element.style, style);\n Object.keys(attributes).forEach(function (attribute) {\n element.removeAttribute(attribute);\n });\n });\n };\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'applyStyles',\n enabled: true,\n phase: 'write',\n fn: applyStyles,\n effect: effect,\n requires: ['computeStyles']\n};","import { auto } from \"../enums.js\";\nexport default function getBasePlacement(placement) {\n return placement.split('-')[0];\n}","export var max = Math.max;\nexport var min = Math.min;\nexport var round = Math.round;","export default function getUAString() {\n var uaData = navigator.userAgentData;\n\n if (uaData != null && uaData.brands && Array.isArray(uaData.brands)) {\n return uaData.brands.map(function (item) {\n return item.brand + \"/\" + item.version;\n }).join(' ');\n }\n\n return navigator.userAgent;\n}","import getUAString from \"../utils/userAgent.js\";\nexport default function isLayoutViewport() {\n return !/^((?!chrome|android).)*safari/i.test(getUAString());\n}","import { isElement, isHTMLElement } from \"./instanceOf.js\";\nimport { round } from \"../utils/math.js\";\nimport getWindow from \"./getWindow.js\";\nimport isLayoutViewport from \"./isLayoutViewport.js\";\nexport default function getBoundingClientRect(element, includeScale, isFixedStrategy) {\n if (includeScale === void 0) {\n includeScale = false;\n }\n\n if (isFixedStrategy === void 0) {\n isFixedStrategy = false;\n }\n\n var clientRect = element.getBoundingClientRect();\n var scaleX = 1;\n var scaleY = 1;\n\n if (includeScale && isHTMLElement(element)) {\n scaleX = element.offsetWidth > 0 ? round(clientRect.width) / element.offsetWidth || 1 : 1;\n scaleY = element.offsetHeight > 0 ? round(clientRect.height) / element.offsetHeight || 1 : 1;\n }\n\n var _ref = isElement(element) ? getWindow(element) : window,\n visualViewport = _ref.visualViewport;\n\n var addVisualOffsets = !isLayoutViewport() && isFixedStrategy;\n var x = (clientRect.left + (addVisualOffsets && visualViewport ? visualViewport.offsetLeft : 0)) / scaleX;\n var y = (clientRect.top + (addVisualOffsets && visualViewport ? visualViewport.offsetTop : 0)) / scaleY;\n var width = clientRect.width / scaleX;\n var height = clientRect.height / scaleY;\n return {\n width: width,\n height: height,\n top: y,\n right: x + width,\n bottom: y + height,\n left: x,\n x: x,\n y: y\n };\n}","import getBoundingClientRect from \"./getBoundingClientRect.js\"; // Returns the layout rect of an element relative to its offsetParent. Layout\n// means it doesn't take into account transforms.\n\nexport default function getLayoutRect(element) {\n var clientRect = getBoundingClientRect(element); // Use the clientRect sizes if it's not been transformed.\n // Fixes https://github.com/popperjs/popper-core/issues/1223\n\n var width = element.offsetWidth;\n var height = element.offsetHeight;\n\n if (Math.abs(clientRect.width - width) <= 1) {\n width = clientRect.width;\n }\n\n if (Math.abs(clientRect.height - height) <= 1) {\n height = clientRect.height;\n }\n\n return {\n x: element.offsetLeft,\n y: element.offsetTop,\n width: width,\n height: height\n };\n}","import { isShadowRoot } from \"./instanceOf.js\";\nexport default function contains(parent, child) {\n var rootNode = child.getRootNode && child.getRootNode(); // First, attempt with faster native method\n\n if (parent.contains(child)) {\n return true;\n } // then fallback to custom implementation with Shadow DOM support\n else if (rootNode && isShadowRoot(rootNode)) {\n var next = child;\n\n do {\n if (next && parent.isSameNode(next)) {\n return true;\n } // $FlowFixMe[prop-missing]: need a better way to handle this...\n\n\n next = next.parentNode || next.host;\n } while (next);\n } // Give up, the result is false\n\n\n return false;\n}","import getWindow from \"./getWindow.js\";\nexport default function getComputedStyle(element) {\n return getWindow(element).getComputedStyle(element);\n}","import getNodeName from \"./getNodeName.js\";\nexport default function isTableElement(element) {\n return ['table', 'td', 'th'].indexOf(getNodeName(element)) >= 0;\n}","import { isElement } from \"./instanceOf.js\";\nexport default function getDocumentElement(element) {\n // $FlowFixMe[incompatible-return]: assume body is always available\n return ((isElement(element) ? element.ownerDocument : // $FlowFixMe[prop-missing]\n element.document) || window.document).documentElement;\n}","import getNodeName from \"./getNodeName.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport { isShadowRoot } from \"./instanceOf.js\";\nexport default function getParentNode(element) {\n if (getNodeName(element) === 'html') {\n return element;\n }\n\n return (// this is a quicker (but less type safe) way to save quite some bytes from the bundle\n // $FlowFixMe[incompatible-return]\n // $FlowFixMe[prop-missing]\n element.assignedSlot || // step into the shadow DOM of the parent of a slotted node\n element.parentNode || ( // DOM Element detected\n isShadowRoot(element) ? element.host : null) || // ShadowRoot detected\n // $FlowFixMe[incompatible-call]: HTMLElement is a Node\n getDocumentElement(element) // fallback\n\n );\n}","import getWindow from \"./getWindow.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport getComputedStyle from \"./getComputedStyle.js\";\nimport { isHTMLElement, isShadowRoot } from \"./instanceOf.js\";\nimport isTableElement from \"./isTableElement.js\";\nimport getParentNode from \"./getParentNode.js\";\nimport getUAString from \"../utils/userAgent.js\";\n\nfunction getTrueOffsetParent(element) {\n if (!isHTMLElement(element) || // https://github.com/popperjs/popper-core/issues/837\n getComputedStyle(element).position === 'fixed') {\n return null;\n }\n\n return element.offsetParent;\n} // `.offsetParent` reports `null` for fixed elements, while absolute elements\n// return the containing block\n\n\nfunction getContainingBlock(element) {\n var isFirefox = /firefox/i.test(getUAString());\n var isIE = /Trident/i.test(getUAString());\n\n if (isIE && isHTMLElement(element)) {\n // In IE 9, 10 and 11 fixed elements containing block is always established by the viewport\n var elementCss = getComputedStyle(element);\n\n if (elementCss.position === 'fixed') {\n return null;\n }\n }\n\n var currentNode = getParentNode(element);\n\n if (isShadowRoot(currentNode)) {\n currentNode = currentNode.host;\n }\n\n while (isHTMLElement(currentNode) && ['html', 'body'].indexOf(getNodeName(currentNode)) < 0) {\n var css = getComputedStyle(currentNode); // This is non-exhaustive but covers the most common CSS properties that\n // create a containing block.\n // https://developer.mozilla.org/en-US/docs/Web/CSS/Containing_block#identifying_the_containing_block\n\n if (css.transform !== 'none' || css.perspective !== 'none' || css.contain === 'paint' || ['transform', 'perspective'].indexOf(css.willChange) !== -1 || isFirefox && css.willChange === 'filter' || isFirefox && css.filter && css.filter !== 'none') {\n return currentNode;\n } else {\n currentNode = currentNode.parentNode;\n }\n }\n\n return null;\n} // Gets the closest ancestor positioned element. Handles some edge cases,\n// such as table ancestors and cross browser bugs.\n\n\nexport default function getOffsetParent(element) {\n var window = getWindow(element);\n var offsetParent = getTrueOffsetParent(element);\n\n while (offsetParent && isTableElement(offsetParent) && getComputedStyle(offsetParent).position === 'static') {\n offsetParent = getTrueOffsetParent(offsetParent);\n }\n\n if (offsetParent && (getNodeName(offsetParent) === 'html' || getNodeName(offsetParent) === 'body' && getComputedStyle(offsetParent).position === 'static')) {\n return window;\n }\n\n return offsetParent || getContainingBlock(element) || window;\n}","export default function getMainAxisFromPlacement(placement) {\n return ['top', 'bottom'].indexOf(placement) >= 0 ? 'x' : 'y';\n}","import { max as mathMax, min as mathMin } from \"./math.js\";\nexport function within(min, value, max) {\n return mathMax(min, mathMin(value, max));\n}\nexport function withinMaxClamp(min, value, max) {\n var v = within(min, value, max);\n return v > max ? max : v;\n}","export default function getFreshSideObject() {\n return {\n top: 0,\n right: 0,\n bottom: 0,\n left: 0\n };\n}","import getFreshSideObject from \"./getFreshSideObject.js\";\nexport default function mergePaddingObject(paddingObject) {\n return Object.assign({}, getFreshSideObject(), paddingObject);\n}","export default function expandToHashMap(value, keys) {\n return keys.reduce(function (hashMap, key) {\n hashMap[key] = value;\n return hashMap;\n }, {});\n}","import getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getLayoutRect from \"../dom-utils/getLayoutRect.js\";\nimport contains from \"../dom-utils/contains.js\";\nimport getOffsetParent from \"../dom-utils/getOffsetParent.js\";\nimport getMainAxisFromPlacement from \"../utils/getMainAxisFromPlacement.js\";\nimport { within } from \"../utils/within.js\";\nimport mergePaddingObject from \"../utils/mergePaddingObject.js\";\nimport expandToHashMap from \"../utils/expandToHashMap.js\";\nimport { left, right, basePlacements, top, bottom } from \"../enums.js\"; // eslint-disable-next-line import/no-unused-modules\n\nvar toPaddingObject = function toPaddingObject(padding, state) {\n padding = typeof padding === 'function' ? padding(Object.assign({}, state.rects, {\n placement: state.placement\n })) : padding;\n return mergePaddingObject(typeof padding !== 'number' ? padding : expandToHashMap(padding, basePlacements));\n};\n\nfunction arrow(_ref) {\n var _state$modifiersData$;\n\n var state = _ref.state,\n name = _ref.name,\n options = _ref.options;\n var arrowElement = state.elements.arrow;\n var popperOffsets = state.modifiersData.popperOffsets;\n var basePlacement = getBasePlacement(state.placement);\n var axis = getMainAxisFromPlacement(basePlacement);\n var isVertical = [left, right].indexOf(basePlacement) >= 0;\n var len = isVertical ? 'height' : 'width';\n\n if (!arrowElement || !popperOffsets) {\n return;\n }\n\n var paddingObject = toPaddingObject(options.padding, state);\n var arrowRect = getLayoutRect(arrowElement);\n var minProp = axis === 'y' ? top : left;\n var maxProp = axis === 'y' ? bottom : right;\n var endDiff = state.rects.reference[len] + state.rects.reference[axis] - popperOffsets[axis] - state.rects.popper[len];\n var startDiff = popperOffsets[axis] - state.rects.reference[axis];\n var arrowOffsetParent = getOffsetParent(arrowElement);\n var clientSize = arrowOffsetParent ? axis === 'y' ? arrowOffsetParent.clientHeight || 0 : arrowOffsetParent.clientWidth || 0 : 0;\n var centerToReference = endDiff / 2 - startDiff / 2; // Make sure the arrow doesn't overflow the popper if the center point is\n // outside of the popper bounds\n\n var min = paddingObject[minProp];\n var max = clientSize - arrowRect[len] - paddingObject[maxProp];\n var center = clientSize / 2 - arrowRect[len] / 2 + centerToReference;\n var offset = within(min, center, max); // Prevents breaking syntax highlighting...\n\n var axisProp = axis;\n state.modifiersData[name] = (_state$modifiersData$ = {}, _state$modifiersData$[axisProp] = offset, _state$modifiersData$.centerOffset = offset - center, _state$modifiersData$);\n}\n\nfunction effect(_ref2) {\n var state = _ref2.state,\n options = _ref2.options;\n var _options$element = options.element,\n arrowElement = _options$element === void 0 ? '[data-popper-arrow]' : _options$element;\n\n if (arrowElement == null) {\n return;\n } // CSS selector\n\n\n if (typeof arrowElement === 'string') {\n arrowElement = state.elements.popper.querySelector(arrowElement);\n\n if (!arrowElement) {\n return;\n }\n }\n\n if (!contains(state.elements.popper, arrowElement)) {\n return;\n }\n\n state.elements.arrow = arrowElement;\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'arrow',\n enabled: true,\n phase: 'main',\n fn: arrow,\n effect: effect,\n requires: ['popperOffsets'],\n requiresIfExists: ['preventOverflow']\n};","export default function getVariation(placement) {\n return placement.split('-')[1];\n}","import { top, left, right, bottom, end } from \"../enums.js\";\nimport getOffsetParent from \"../dom-utils/getOffsetParent.js\";\nimport getWindow from \"../dom-utils/getWindow.js\";\nimport getDocumentElement from \"../dom-utils/getDocumentElement.js\";\nimport getComputedStyle from \"../dom-utils/getComputedStyle.js\";\nimport getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getVariation from \"../utils/getVariation.js\";\nimport { round } from \"../utils/math.js\"; // eslint-disable-next-line import/no-unused-modules\n\nvar unsetSides = {\n top: 'auto',\n right: 'auto',\n bottom: 'auto',\n left: 'auto'\n}; // Round the offsets to the nearest suitable subpixel based on the DPR.\n// Zooming can change the DPR, but it seems to report a value that will\n// cleanly divide the values into the appropriate subpixels.\n\nfunction roundOffsetsByDPR(_ref, win) {\n var x = _ref.x,\n y = _ref.y;\n var dpr = win.devicePixelRatio || 1;\n return {\n x: round(x * dpr) / dpr || 0,\n y: round(y * dpr) / dpr || 0\n };\n}\n\nexport function mapToStyles(_ref2) {\n var _Object$assign2;\n\n var popper = _ref2.popper,\n popperRect = _ref2.popperRect,\n placement = _ref2.placement,\n variation = _ref2.variation,\n offsets = _ref2.offsets,\n position = _ref2.position,\n gpuAcceleration = _ref2.gpuAcceleration,\n adaptive = _ref2.adaptive,\n roundOffsets = _ref2.roundOffsets,\n isFixed = _ref2.isFixed;\n var _offsets$x = offsets.x,\n x = _offsets$x === void 0 ? 0 : _offsets$x,\n _offsets$y = offsets.y,\n y = _offsets$y === void 0 ? 0 : _offsets$y;\n\n var _ref3 = typeof roundOffsets === 'function' ? roundOffsets({\n x: x,\n y: y\n }) : {\n x: x,\n y: y\n };\n\n x = _ref3.x;\n y = _ref3.y;\n var hasX = offsets.hasOwnProperty('x');\n var hasY = offsets.hasOwnProperty('y');\n var sideX = left;\n var sideY = top;\n var win = window;\n\n if (adaptive) {\n var offsetParent = getOffsetParent(popper);\n var heightProp = 'clientHeight';\n var widthProp = 'clientWidth';\n\n if (offsetParent === getWindow(popper)) {\n offsetParent = getDocumentElement(popper);\n\n if (getComputedStyle(offsetParent).position !== 'static' && position === 'absolute') {\n heightProp = 'scrollHeight';\n widthProp = 'scrollWidth';\n }\n } // $FlowFixMe[incompatible-cast]: force type refinement, we compare offsetParent with window above, but Flow doesn't detect it\n\n\n offsetParent = offsetParent;\n\n if (placement === top || (placement === left || placement === right) && variation === end) {\n sideY = bottom;\n var offsetY = isFixed && offsetParent === win && win.visualViewport ? win.visualViewport.height : // $FlowFixMe[prop-missing]\n offsetParent[heightProp];\n y -= offsetY - popperRect.height;\n y *= gpuAcceleration ? 1 : -1;\n }\n\n if (placement === left || (placement === top || placement === bottom) && variation === end) {\n sideX = right;\n var offsetX = isFixed && offsetParent === win && win.visualViewport ? win.visualViewport.width : // $FlowFixMe[prop-missing]\n offsetParent[widthProp];\n x -= offsetX - popperRect.width;\n x *= gpuAcceleration ? 1 : -1;\n }\n }\n\n var commonStyles = Object.assign({\n position: position\n }, adaptive && unsetSides);\n\n var _ref4 = roundOffsets === true ? roundOffsetsByDPR({\n x: x,\n y: y\n }, getWindow(popper)) : {\n x: x,\n y: y\n };\n\n x = _ref4.x;\n y = _ref4.y;\n\n if (gpuAcceleration) {\n var _Object$assign;\n\n return Object.assign({}, commonStyles, (_Object$assign = {}, _Object$assign[sideY] = hasY ? '0' : '', _Object$assign[sideX] = hasX ? '0' : '', _Object$assign.transform = (win.devicePixelRatio || 1) <= 1 ? \"translate(\" + x + \"px, \" + y + \"px)\" : \"translate3d(\" + x + \"px, \" + y + \"px, 0)\", _Object$assign));\n }\n\n return Object.assign({}, commonStyles, (_Object$assign2 = {}, _Object$assign2[sideY] = hasY ? y + \"px\" : '', _Object$assign2[sideX] = hasX ? x + \"px\" : '', _Object$assign2.transform = '', _Object$assign2));\n}\n\nfunction computeStyles(_ref5) {\n var state = _ref5.state,\n options = _ref5.options;\n var _options$gpuAccelerat = options.gpuAcceleration,\n gpuAcceleration = _options$gpuAccelerat === void 0 ? true : _options$gpuAccelerat,\n _options$adaptive = options.adaptive,\n adaptive = _options$adaptive === void 0 ? true : _options$adaptive,\n _options$roundOffsets = options.roundOffsets,\n roundOffsets = _options$roundOffsets === void 0 ? true : _options$roundOffsets;\n var commonStyles = {\n placement: getBasePlacement(state.placement),\n variation: getVariation(state.placement),\n popper: state.elements.popper,\n popperRect: state.rects.popper,\n gpuAcceleration: gpuAcceleration,\n isFixed: state.options.strategy === 'fixed'\n };\n\n if (state.modifiersData.popperOffsets != null) {\n state.styles.popper = Object.assign({}, state.styles.popper, mapToStyles(Object.assign({}, commonStyles, {\n offsets: state.modifiersData.popperOffsets,\n position: state.options.strategy,\n adaptive: adaptive,\n roundOffsets: roundOffsets\n })));\n }\n\n if (state.modifiersData.arrow != null) {\n state.styles.arrow = Object.assign({}, state.styles.arrow, mapToStyles(Object.assign({}, commonStyles, {\n offsets: state.modifiersData.arrow,\n position: 'absolute',\n adaptive: false,\n roundOffsets: roundOffsets\n })));\n }\n\n state.attributes.popper = Object.assign({}, state.attributes.popper, {\n 'data-popper-placement': state.placement\n });\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'computeStyles',\n enabled: true,\n phase: 'beforeWrite',\n fn: computeStyles,\n data: {}\n};","import getWindow from \"../dom-utils/getWindow.js\"; // eslint-disable-next-line import/no-unused-modules\n\nvar passive = {\n passive: true\n};\n\nfunction effect(_ref) {\n var state = _ref.state,\n instance = _ref.instance,\n options = _ref.options;\n var _options$scroll = options.scroll,\n scroll = _options$scroll === void 0 ? true : _options$scroll,\n _options$resize = options.resize,\n resize = _options$resize === void 0 ? true : _options$resize;\n var window = getWindow(state.elements.popper);\n var scrollParents = [].concat(state.scrollParents.reference, state.scrollParents.popper);\n\n if (scroll) {\n scrollParents.forEach(function (scrollParent) {\n scrollParent.addEventListener('scroll', instance.update, passive);\n });\n }\n\n if (resize) {\n window.addEventListener('resize', instance.update, passive);\n }\n\n return function () {\n if (scroll) {\n scrollParents.forEach(function (scrollParent) {\n scrollParent.removeEventListener('scroll', instance.update, passive);\n });\n }\n\n if (resize) {\n window.removeEventListener('resize', instance.update, passive);\n }\n };\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'eventListeners',\n enabled: true,\n phase: 'write',\n fn: function fn() {},\n effect: effect,\n data: {}\n};","var hash = {\n left: 'right',\n right: 'left',\n bottom: 'top',\n top: 'bottom'\n};\nexport default function getOppositePlacement(placement) {\n return placement.replace(/left|right|bottom|top/g, function (matched) {\n return hash[matched];\n });\n}","var hash = {\n start: 'end',\n end: 'start'\n};\nexport default function getOppositeVariationPlacement(placement) {\n return placement.replace(/start|end/g, function (matched) {\n return hash[matched];\n });\n}","import getWindow from \"./getWindow.js\";\nexport default function getWindowScroll(node) {\n var win = getWindow(node);\n var scrollLeft = win.pageXOffset;\n var scrollTop = win.pageYOffset;\n return {\n scrollLeft: scrollLeft,\n scrollTop: scrollTop\n };\n}","import getBoundingClientRect from \"./getBoundingClientRect.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport getWindowScroll from \"./getWindowScroll.js\";\nexport default function getWindowScrollBarX(element) {\n // If has a CSS width greater than the viewport, then this will be\n // incorrect for RTL.\n // Popper 1 is broken in this case and never had a bug report so let's assume\n // it's not an issue. I don't think anyone ever specifies width on \n // anyway.\n // Browsers where the left scrollbar doesn't cause an issue report `0` for\n // this (e.g. Edge 2019, IE11, Safari)\n return getBoundingClientRect(getDocumentElement(element)).left + getWindowScroll(element).scrollLeft;\n}","import getWindow from \"./getWindow.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport getWindowScrollBarX from \"./getWindowScrollBarX.js\";\nimport isLayoutViewport from \"./isLayoutViewport.js\";\nexport default function getViewportRect(element, strategy) {\n var win = getWindow(element);\n var html = getDocumentElement(element);\n var visualViewport = win.visualViewport;\n var width = html.clientWidth;\n var height = html.clientHeight;\n var x = 0;\n var y = 0;\n\n if (visualViewport) {\n width = visualViewport.width;\n height = visualViewport.height;\n var layoutViewport = isLayoutViewport();\n\n if (layoutViewport || !layoutViewport && strategy === 'fixed') {\n x = visualViewport.offsetLeft;\n y = visualViewport.offsetTop;\n }\n }\n\n return {\n width: width,\n height: height,\n x: x + getWindowScrollBarX(element),\n y: y\n };\n}","import getDocumentElement from \"./getDocumentElement.js\";\nimport getComputedStyle from \"./getComputedStyle.js\";\nimport getWindowScrollBarX from \"./getWindowScrollBarX.js\";\nimport getWindowScroll from \"./getWindowScroll.js\";\nimport { max } from \"../utils/math.js\"; // Gets the entire size of the scrollable document area, even extending outside\n// of the `` and `` rect bounds if horizontally scrollable\n\nexport default function getDocumentRect(element) {\n var _element$ownerDocumen;\n\n var html = getDocumentElement(element);\n var winScroll = getWindowScroll(element);\n var body = (_element$ownerDocumen = element.ownerDocument) == null ? void 0 : _element$ownerDocumen.body;\n var width = max(html.scrollWidth, html.clientWidth, body ? body.scrollWidth : 0, body ? body.clientWidth : 0);\n var height = max(html.scrollHeight, html.clientHeight, body ? body.scrollHeight : 0, body ? body.clientHeight : 0);\n var x = -winScroll.scrollLeft + getWindowScrollBarX(element);\n var y = -winScroll.scrollTop;\n\n if (getComputedStyle(body || html).direction === 'rtl') {\n x += max(html.clientWidth, body ? body.clientWidth : 0) - width;\n }\n\n return {\n width: width,\n height: height,\n x: x,\n y: y\n };\n}","import getComputedStyle from \"./getComputedStyle.js\";\nexport default function isScrollParent(element) {\n // Firefox wants us to check `-x` and `-y` variations as well\n var _getComputedStyle = getComputedStyle(element),\n overflow = _getComputedStyle.overflow,\n overflowX = _getComputedStyle.overflowX,\n overflowY = _getComputedStyle.overflowY;\n\n return /auto|scroll|overlay|hidden/.test(overflow + overflowY + overflowX);\n}","import getParentNode from \"./getParentNode.js\";\nimport isScrollParent from \"./isScrollParent.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport { isHTMLElement } from \"./instanceOf.js\";\nexport default function getScrollParent(node) {\n if (['html', 'body', '#document'].indexOf(getNodeName(node)) >= 0) {\n // $FlowFixMe[incompatible-return]: assume body is always available\n return node.ownerDocument.body;\n }\n\n if (isHTMLElement(node) && isScrollParent(node)) {\n return node;\n }\n\n return getScrollParent(getParentNode(node));\n}","import getScrollParent from \"./getScrollParent.js\";\nimport getParentNode from \"./getParentNode.js\";\nimport getWindow from \"./getWindow.js\";\nimport isScrollParent from \"./isScrollParent.js\";\n/*\ngiven a DOM element, return the list of all scroll parents, up the list of ancesors\nuntil we get to the top window object. This list is what we attach scroll listeners\nto, because if any of these parent elements scroll, we'll need to re-calculate the\nreference element's position.\n*/\n\nexport default function listScrollParents(element, list) {\n var _element$ownerDocumen;\n\n if (list === void 0) {\n list = [];\n }\n\n var scrollParent = getScrollParent(element);\n var isBody = scrollParent === ((_element$ownerDocumen = element.ownerDocument) == null ? void 0 : _element$ownerDocumen.body);\n var win = getWindow(scrollParent);\n var target = isBody ? [win].concat(win.visualViewport || [], isScrollParent(scrollParent) ? scrollParent : []) : scrollParent;\n var updatedList = list.concat(target);\n return isBody ? updatedList : // $FlowFixMe[incompatible-call]: isBody tells us target will be an HTMLElement here\n updatedList.concat(listScrollParents(getParentNode(target)));\n}","export default function rectToClientRect(rect) {\n return Object.assign({}, rect, {\n left: rect.x,\n top: rect.y,\n right: rect.x + rect.width,\n bottom: rect.y + rect.height\n });\n}","import { viewport } from \"../enums.js\";\nimport getViewportRect from \"./getViewportRect.js\";\nimport getDocumentRect from \"./getDocumentRect.js\";\nimport listScrollParents from \"./listScrollParents.js\";\nimport getOffsetParent from \"./getOffsetParent.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport getComputedStyle from \"./getComputedStyle.js\";\nimport { isElement, isHTMLElement } from \"./instanceOf.js\";\nimport getBoundingClientRect from \"./getBoundingClientRect.js\";\nimport getParentNode from \"./getParentNode.js\";\nimport contains from \"./contains.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport rectToClientRect from \"../utils/rectToClientRect.js\";\nimport { max, min } from \"../utils/math.js\";\n\nfunction getInnerBoundingClientRect(element, strategy) {\n var rect = getBoundingClientRect(element, false, strategy === 'fixed');\n rect.top = rect.top + element.clientTop;\n rect.left = rect.left + element.clientLeft;\n rect.bottom = rect.top + element.clientHeight;\n rect.right = rect.left + element.clientWidth;\n rect.width = element.clientWidth;\n rect.height = element.clientHeight;\n rect.x = rect.left;\n rect.y = rect.top;\n return rect;\n}\n\nfunction getClientRectFromMixedType(element, clippingParent, strategy) {\n return clippingParent === viewport ? rectToClientRect(getViewportRect(element, strategy)) : isElement(clippingParent) ? getInnerBoundingClientRect(clippingParent, strategy) : rectToClientRect(getDocumentRect(getDocumentElement(element)));\n} // A \"clipping parent\" is an overflowable container with the characteristic of\n// clipping (or hiding) overflowing elements with a position different from\n// `initial`\n\n\nfunction getClippingParents(element) {\n var clippingParents = listScrollParents(getParentNode(element));\n var canEscapeClipping = ['absolute', 'fixed'].indexOf(getComputedStyle(element).position) >= 0;\n var clipperElement = canEscapeClipping && isHTMLElement(element) ? getOffsetParent(element) : element;\n\n if (!isElement(clipperElement)) {\n return [];\n } // $FlowFixMe[incompatible-return]: https://github.com/facebook/flow/issues/1414\n\n\n return clippingParents.filter(function (clippingParent) {\n return isElement(clippingParent) && contains(clippingParent, clipperElement) && getNodeName(clippingParent) !== 'body';\n });\n} // Gets the maximum area that the element is visible in due to any number of\n// clipping parents\n\n\nexport default function getClippingRect(element, boundary, rootBoundary, strategy) {\n var mainClippingParents = boundary === 'clippingParents' ? getClippingParents(element) : [].concat(boundary);\n var clippingParents = [].concat(mainClippingParents, [rootBoundary]);\n var firstClippingParent = clippingParents[0];\n var clippingRect = clippingParents.reduce(function (accRect, clippingParent) {\n var rect = getClientRectFromMixedType(element, clippingParent, strategy);\n accRect.top = max(rect.top, accRect.top);\n accRect.right = min(rect.right, accRect.right);\n accRect.bottom = min(rect.bottom, accRect.bottom);\n accRect.left = max(rect.left, accRect.left);\n return accRect;\n }, getClientRectFromMixedType(element, firstClippingParent, strategy));\n clippingRect.width = clippingRect.right - clippingRect.left;\n clippingRect.height = clippingRect.bottom - clippingRect.top;\n clippingRect.x = clippingRect.left;\n clippingRect.y = clippingRect.top;\n return clippingRect;\n}","import getBasePlacement from \"./getBasePlacement.js\";\nimport getVariation from \"./getVariation.js\";\nimport getMainAxisFromPlacement from \"./getMainAxisFromPlacement.js\";\nimport { top, right, bottom, left, start, end } from \"../enums.js\";\nexport default function computeOffsets(_ref) {\n var reference = _ref.reference,\n element = _ref.element,\n placement = _ref.placement;\n var basePlacement = placement ? getBasePlacement(placement) : null;\n var variation = placement ? getVariation(placement) : null;\n var commonX = reference.x + reference.width / 2 - element.width / 2;\n var commonY = reference.y + reference.height / 2 - element.height / 2;\n var offsets;\n\n switch (basePlacement) {\n case top:\n offsets = {\n x: commonX,\n y: reference.y - element.height\n };\n break;\n\n case bottom:\n offsets = {\n x: commonX,\n y: reference.y + reference.height\n };\n break;\n\n case right:\n offsets = {\n x: reference.x + reference.width,\n y: commonY\n };\n break;\n\n case left:\n offsets = {\n x: reference.x - element.width,\n y: commonY\n };\n break;\n\n default:\n offsets = {\n x: reference.x,\n y: reference.y\n };\n }\n\n var mainAxis = basePlacement ? getMainAxisFromPlacement(basePlacement) : null;\n\n if (mainAxis != null) {\n var len = mainAxis === 'y' ? 'height' : 'width';\n\n switch (variation) {\n case start:\n offsets[mainAxis] = offsets[mainAxis] - (reference[len] / 2 - element[len] / 2);\n break;\n\n case end:\n offsets[mainAxis] = offsets[mainAxis] + (reference[len] / 2 - element[len] / 2);\n break;\n\n default:\n }\n }\n\n return offsets;\n}","import getClippingRect from \"../dom-utils/getClippingRect.js\";\nimport getDocumentElement from \"../dom-utils/getDocumentElement.js\";\nimport getBoundingClientRect from \"../dom-utils/getBoundingClientRect.js\";\nimport computeOffsets from \"./computeOffsets.js\";\nimport rectToClientRect from \"./rectToClientRect.js\";\nimport { clippingParents, reference, popper, bottom, top, right, basePlacements, viewport } from \"../enums.js\";\nimport { isElement } from \"../dom-utils/instanceOf.js\";\nimport mergePaddingObject from \"./mergePaddingObject.js\";\nimport expandToHashMap from \"./expandToHashMap.js\"; // eslint-disable-next-line import/no-unused-modules\n\nexport default function detectOverflow(state, options) {\n if (options === void 0) {\n options = {};\n }\n\n var _options = options,\n _options$placement = _options.placement,\n placement = _options$placement === void 0 ? state.placement : _options$placement,\n _options$strategy = _options.strategy,\n strategy = _options$strategy === void 0 ? state.strategy : _options$strategy,\n _options$boundary = _options.boundary,\n boundary = _options$boundary === void 0 ? clippingParents : _options$boundary,\n _options$rootBoundary = _options.rootBoundary,\n rootBoundary = _options$rootBoundary === void 0 ? viewport : _options$rootBoundary,\n _options$elementConte = _options.elementContext,\n elementContext = _options$elementConte === void 0 ? popper : _options$elementConte,\n _options$altBoundary = _options.altBoundary,\n altBoundary = _options$altBoundary === void 0 ? false : _options$altBoundary,\n _options$padding = _options.padding,\n padding = _options$padding === void 0 ? 0 : _options$padding;\n var paddingObject = mergePaddingObject(typeof padding !== 'number' ? padding : expandToHashMap(padding, basePlacements));\n var altContext = elementContext === popper ? reference : popper;\n var popperRect = state.rects.popper;\n var element = state.elements[altBoundary ? altContext : elementContext];\n var clippingClientRect = getClippingRect(isElement(element) ? element : element.contextElement || getDocumentElement(state.elements.popper), boundary, rootBoundary, strategy);\n var referenceClientRect = getBoundingClientRect(state.elements.reference);\n var popperOffsets = computeOffsets({\n reference: referenceClientRect,\n element: popperRect,\n strategy: 'absolute',\n placement: placement\n });\n var popperClientRect = rectToClientRect(Object.assign({}, popperRect, popperOffsets));\n var elementClientRect = elementContext === popper ? popperClientRect : referenceClientRect; // positive = overflowing the clipping rect\n // 0 or negative = within the clipping rect\n\n var overflowOffsets = {\n top: clippingClientRect.top - elementClientRect.top + paddingObject.top,\n bottom: elementClientRect.bottom - clippingClientRect.bottom + paddingObject.bottom,\n left: clippingClientRect.left - elementClientRect.left + paddingObject.left,\n right: elementClientRect.right - clippingClientRect.right + paddingObject.right\n };\n var offsetData = state.modifiersData.offset; // Offsets can be applied only to the popper element\n\n if (elementContext === popper && offsetData) {\n var offset = offsetData[placement];\n Object.keys(overflowOffsets).forEach(function (key) {\n var multiply = [right, bottom].indexOf(key) >= 0 ? 1 : -1;\n var axis = [top, bottom].indexOf(key) >= 0 ? 'y' : 'x';\n overflowOffsets[key] += offset[axis] * multiply;\n });\n }\n\n return overflowOffsets;\n}","import getVariation from \"./getVariation.js\";\nimport { variationPlacements, basePlacements, placements as allPlacements } from \"../enums.js\";\nimport detectOverflow from \"./detectOverflow.js\";\nimport getBasePlacement from \"./getBasePlacement.js\";\nexport default function computeAutoPlacement(state, options) {\n if (options === void 0) {\n options = {};\n }\n\n var _options = options,\n placement = _options.placement,\n boundary = _options.boundary,\n rootBoundary = _options.rootBoundary,\n padding = _options.padding,\n flipVariations = _options.flipVariations,\n _options$allowedAutoP = _options.allowedAutoPlacements,\n allowedAutoPlacements = _options$allowedAutoP === void 0 ? allPlacements : _options$allowedAutoP;\n var variation = getVariation(placement);\n var placements = variation ? flipVariations ? variationPlacements : variationPlacements.filter(function (placement) {\n return getVariation(placement) === variation;\n }) : basePlacements;\n var allowedPlacements = placements.filter(function (placement) {\n return allowedAutoPlacements.indexOf(placement) >= 0;\n });\n\n if (allowedPlacements.length === 0) {\n allowedPlacements = placements;\n } // $FlowFixMe[incompatible-type]: Flow seems to have problems with two array unions...\n\n\n var overflows = allowedPlacements.reduce(function (acc, placement) {\n acc[placement] = detectOverflow(state, {\n placement: placement,\n boundary: boundary,\n rootBoundary: rootBoundary,\n padding: padding\n })[getBasePlacement(placement)];\n return acc;\n }, {});\n return Object.keys(overflows).sort(function (a, b) {\n return overflows[a] - overflows[b];\n });\n}","import getOppositePlacement from \"../utils/getOppositePlacement.js\";\nimport getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getOppositeVariationPlacement from \"../utils/getOppositeVariationPlacement.js\";\nimport detectOverflow from \"../utils/detectOverflow.js\";\nimport computeAutoPlacement from \"../utils/computeAutoPlacement.js\";\nimport { bottom, top, start, right, left, auto } from \"../enums.js\";\nimport getVariation from \"../utils/getVariation.js\"; // eslint-disable-next-line import/no-unused-modules\n\nfunction getExpandedFallbackPlacements(placement) {\n if (getBasePlacement(placement) === auto) {\n return [];\n }\n\n var oppositePlacement = getOppositePlacement(placement);\n return [getOppositeVariationPlacement(placement), oppositePlacement, getOppositeVariationPlacement(oppositePlacement)];\n}\n\nfunction flip(_ref) {\n var state = _ref.state,\n options = _ref.options,\n name = _ref.name;\n\n if (state.modifiersData[name]._skip) {\n return;\n }\n\n var _options$mainAxis = options.mainAxis,\n checkMainAxis = _options$mainAxis === void 0 ? true : _options$mainAxis,\n _options$altAxis = options.altAxis,\n checkAltAxis = _options$altAxis === void 0 ? true : _options$altAxis,\n specifiedFallbackPlacements = options.fallbackPlacements,\n padding = options.padding,\n boundary = options.boundary,\n rootBoundary = options.rootBoundary,\n altBoundary = options.altBoundary,\n _options$flipVariatio = options.flipVariations,\n flipVariations = _options$flipVariatio === void 0 ? true : _options$flipVariatio,\n allowedAutoPlacements = options.allowedAutoPlacements;\n var preferredPlacement = state.options.placement;\n var basePlacement = getBasePlacement(preferredPlacement);\n var isBasePlacement = basePlacement === preferredPlacement;\n var fallbackPlacements = specifiedFallbackPlacements || (isBasePlacement || !flipVariations ? [getOppositePlacement(preferredPlacement)] : getExpandedFallbackPlacements(preferredPlacement));\n var placements = [preferredPlacement].concat(fallbackPlacements).reduce(function (acc, placement) {\n return acc.concat(getBasePlacement(placement) === auto ? computeAutoPlacement(state, {\n placement: placement,\n boundary: boundary,\n rootBoundary: rootBoundary,\n padding: padding,\n flipVariations: flipVariations,\n allowedAutoPlacements: allowedAutoPlacements\n }) : placement);\n }, []);\n var referenceRect = state.rects.reference;\n var popperRect = state.rects.popper;\n var checksMap = new Map();\n var makeFallbackChecks = true;\n var firstFittingPlacement = placements[0];\n\n for (var i = 0; i < placements.length; i++) {\n var placement = placements[i];\n\n var _basePlacement = getBasePlacement(placement);\n\n var isStartVariation = getVariation(placement) === start;\n var isVertical = [top, bottom].indexOf(_basePlacement) >= 0;\n var len = isVertical ? 'width' : 'height';\n var overflow = detectOverflow(state, {\n placement: placement,\n boundary: boundary,\n rootBoundary: rootBoundary,\n altBoundary: altBoundary,\n padding: padding\n });\n var mainVariationSide = isVertical ? isStartVariation ? right : left : isStartVariation ? bottom : top;\n\n if (referenceRect[len] > popperRect[len]) {\n mainVariationSide = getOppositePlacement(mainVariationSide);\n }\n\n var altVariationSide = getOppositePlacement(mainVariationSide);\n var checks = [];\n\n if (checkMainAxis) {\n checks.push(overflow[_basePlacement] <= 0);\n }\n\n if (checkAltAxis) {\n checks.push(overflow[mainVariationSide] <= 0, overflow[altVariationSide] <= 0);\n }\n\n if (checks.every(function (check) {\n return check;\n })) {\n firstFittingPlacement = placement;\n makeFallbackChecks = false;\n break;\n }\n\n checksMap.set(placement, checks);\n }\n\n if (makeFallbackChecks) {\n // `2` may be desired in some cases – research later\n var numberOfChecks = flipVariations ? 3 : 1;\n\n var _loop = function _loop(_i) {\n var fittingPlacement = placements.find(function (placement) {\n var checks = checksMap.get(placement);\n\n if (checks) {\n return checks.slice(0, _i).every(function (check) {\n return check;\n });\n }\n });\n\n if (fittingPlacement) {\n firstFittingPlacement = fittingPlacement;\n return \"break\";\n }\n };\n\n for (var _i = numberOfChecks; _i > 0; _i--) {\n var _ret = _loop(_i);\n\n if (_ret === \"break\") break;\n }\n }\n\n if (state.placement !== firstFittingPlacement) {\n state.modifiersData[name]._skip = true;\n state.placement = firstFittingPlacement;\n state.reset = true;\n }\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'flip',\n enabled: true,\n phase: 'main',\n fn: flip,\n requiresIfExists: ['offset'],\n data: {\n _skip: false\n }\n};","import { top, bottom, left, right } from \"../enums.js\";\nimport detectOverflow from \"../utils/detectOverflow.js\";\n\nfunction getSideOffsets(overflow, rect, preventedOffsets) {\n if (preventedOffsets === void 0) {\n preventedOffsets = {\n x: 0,\n y: 0\n };\n }\n\n return {\n top: overflow.top - rect.height - preventedOffsets.y,\n right: overflow.right - rect.width + preventedOffsets.x,\n bottom: overflow.bottom - rect.height + preventedOffsets.y,\n left: overflow.left - rect.width - preventedOffsets.x\n };\n}\n\nfunction isAnySideFullyClipped(overflow) {\n return [top, right, bottom, left].some(function (side) {\n return overflow[side] >= 0;\n });\n}\n\nfunction hide(_ref) {\n var state = _ref.state,\n name = _ref.name;\n var referenceRect = state.rects.reference;\n var popperRect = state.rects.popper;\n var preventedOffsets = state.modifiersData.preventOverflow;\n var referenceOverflow = detectOverflow(state, {\n elementContext: 'reference'\n });\n var popperAltOverflow = detectOverflow(state, {\n altBoundary: true\n });\n var referenceClippingOffsets = getSideOffsets(referenceOverflow, referenceRect);\n var popperEscapeOffsets = getSideOffsets(popperAltOverflow, popperRect, preventedOffsets);\n var isReferenceHidden = isAnySideFullyClipped(referenceClippingOffsets);\n var hasPopperEscaped = isAnySideFullyClipped(popperEscapeOffsets);\n state.modifiersData[name] = {\n referenceClippingOffsets: referenceClippingOffsets,\n popperEscapeOffsets: popperEscapeOffsets,\n isReferenceHidden: isReferenceHidden,\n hasPopperEscaped: hasPopperEscaped\n };\n state.attributes.popper = Object.assign({}, state.attributes.popper, {\n 'data-popper-reference-hidden': isReferenceHidden,\n 'data-popper-escaped': hasPopperEscaped\n });\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'hide',\n enabled: true,\n phase: 'main',\n requiresIfExists: ['preventOverflow'],\n fn: hide\n};","import getBasePlacement from \"../utils/getBasePlacement.js\";\nimport { top, left, right, placements } from \"../enums.js\"; // eslint-disable-next-line import/no-unused-modules\n\nexport function distanceAndSkiddingToXY(placement, rects, offset) {\n var basePlacement = getBasePlacement(placement);\n var invertDistance = [left, top].indexOf(basePlacement) >= 0 ? -1 : 1;\n\n var _ref = typeof offset === 'function' ? offset(Object.assign({}, rects, {\n placement: placement\n })) : offset,\n skidding = _ref[0],\n distance = _ref[1];\n\n skidding = skidding || 0;\n distance = (distance || 0) * invertDistance;\n return [left, right].indexOf(basePlacement) >= 0 ? {\n x: distance,\n y: skidding\n } : {\n x: skidding,\n y: distance\n };\n}\n\nfunction offset(_ref2) {\n var state = _ref2.state,\n options = _ref2.options,\n name = _ref2.name;\n var _options$offset = options.offset,\n offset = _options$offset === void 0 ? [0, 0] : _options$offset;\n var data = placements.reduce(function (acc, placement) {\n acc[placement] = distanceAndSkiddingToXY(placement, state.rects, offset);\n return acc;\n }, {});\n var _data$state$placement = data[state.placement],\n x = _data$state$placement.x,\n y = _data$state$placement.y;\n\n if (state.modifiersData.popperOffsets != null) {\n state.modifiersData.popperOffsets.x += x;\n state.modifiersData.popperOffsets.y += y;\n }\n\n state.modifiersData[name] = data;\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'offset',\n enabled: true,\n phase: 'main',\n requires: ['popperOffsets'],\n fn: offset\n};","import computeOffsets from \"../utils/computeOffsets.js\";\n\nfunction popperOffsets(_ref) {\n var state = _ref.state,\n name = _ref.name;\n // Offsets are the actual position the popper needs to have to be\n // properly positioned near its reference element\n // This is the most basic placement, and will be adjusted by\n // the modifiers in the next step\n state.modifiersData[name] = computeOffsets({\n reference: state.rects.reference,\n element: state.rects.popper,\n strategy: 'absolute',\n placement: state.placement\n });\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'popperOffsets',\n enabled: true,\n phase: 'read',\n fn: popperOffsets,\n data: {}\n};","export default function getAltAxis(axis) {\n return axis === 'x' ? 'y' : 'x';\n}","import { top, left, right, bottom, start } from \"../enums.js\";\nimport getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getMainAxisFromPlacement from \"../utils/getMainAxisFromPlacement.js\";\nimport getAltAxis from \"../utils/getAltAxis.js\";\nimport { within, withinMaxClamp } from \"../utils/within.js\";\nimport getLayoutRect from \"../dom-utils/getLayoutRect.js\";\nimport getOffsetParent from \"../dom-utils/getOffsetParent.js\";\nimport detectOverflow from \"../utils/detectOverflow.js\";\nimport getVariation from \"../utils/getVariation.js\";\nimport getFreshSideObject from \"../utils/getFreshSideObject.js\";\nimport { min as mathMin, max as mathMax } from \"../utils/math.js\";\n\nfunction preventOverflow(_ref) {\n var state = _ref.state,\n options = _ref.options,\n name = _ref.name;\n var _options$mainAxis = options.mainAxis,\n checkMainAxis = _options$mainAxis === void 0 ? true : _options$mainAxis,\n _options$altAxis = options.altAxis,\n checkAltAxis = _options$altAxis === void 0 ? false : _options$altAxis,\n boundary = options.boundary,\n rootBoundary = options.rootBoundary,\n altBoundary = options.altBoundary,\n padding = options.padding,\n _options$tether = options.tether,\n tether = _options$tether === void 0 ? true : _options$tether,\n _options$tetherOffset = options.tetherOffset,\n tetherOffset = _options$tetherOffset === void 0 ? 0 : _options$tetherOffset;\n var overflow = detectOverflow(state, {\n boundary: boundary,\n rootBoundary: rootBoundary,\n padding: padding,\n altBoundary: altBoundary\n });\n var basePlacement = getBasePlacement(state.placement);\n var variation = getVariation(state.placement);\n var isBasePlacement = !variation;\n var mainAxis = getMainAxisFromPlacement(basePlacement);\n var altAxis = getAltAxis(mainAxis);\n var popperOffsets = state.modifiersData.popperOffsets;\n var referenceRect = state.rects.reference;\n var popperRect = state.rects.popper;\n var tetherOffsetValue = typeof tetherOffset === 'function' ? tetherOffset(Object.assign({}, state.rects, {\n placement: state.placement\n })) : tetherOffset;\n var normalizedTetherOffsetValue = typeof tetherOffsetValue === 'number' ? {\n mainAxis: tetherOffsetValue,\n altAxis: tetherOffsetValue\n } : Object.assign({\n mainAxis: 0,\n altAxis: 0\n }, tetherOffsetValue);\n var offsetModifierState = state.modifiersData.offset ? state.modifiersData.offset[state.placement] : null;\n var data = {\n x: 0,\n y: 0\n };\n\n if (!popperOffsets) {\n return;\n }\n\n if (checkMainAxis) {\n var _offsetModifierState$;\n\n var mainSide = mainAxis === 'y' ? top : left;\n var altSide = mainAxis === 'y' ? bottom : right;\n var len = mainAxis === 'y' ? 'height' : 'width';\n var offset = popperOffsets[mainAxis];\n var min = offset + overflow[mainSide];\n var max = offset - overflow[altSide];\n var additive = tether ? -popperRect[len] / 2 : 0;\n var minLen = variation === start ? referenceRect[len] : popperRect[len];\n var maxLen = variation === start ? -popperRect[len] : -referenceRect[len]; // We need to include the arrow in the calculation so the arrow doesn't go\n // outside the reference bounds\n\n var arrowElement = state.elements.arrow;\n var arrowRect = tether && arrowElement ? getLayoutRect(arrowElement) : {\n width: 0,\n height: 0\n };\n var arrowPaddingObject = state.modifiersData['arrow#persistent'] ? state.modifiersData['arrow#persistent'].padding : getFreshSideObject();\n var arrowPaddingMin = arrowPaddingObject[mainSide];\n var arrowPaddingMax = arrowPaddingObject[altSide]; // If the reference length is smaller than the arrow length, we don't want\n // to include its full size in the calculation. If the reference is small\n // and near the edge of a boundary, the popper can overflow even if the\n // reference is not overflowing as well (e.g. virtual elements with no\n // width or height)\n\n var arrowLen = within(0, referenceRect[len], arrowRect[len]);\n var minOffset = isBasePlacement ? referenceRect[len] / 2 - additive - arrowLen - arrowPaddingMin - normalizedTetherOffsetValue.mainAxis : minLen - arrowLen - arrowPaddingMin - normalizedTetherOffsetValue.mainAxis;\n var maxOffset = isBasePlacement ? -referenceRect[len] / 2 + additive + arrowLen + arrowPaddingMax + normalizedTetherOffsetValue.mainAxis : maxLen + arrowLen + arrowPaddingMax + normalizedTetherOffsetValue.mainAxis;\n var arrowOffsetParent = state.elements.arrow && getOffsetParent(state.elements.arrow);\n var clientOffset = arrowOffsetParent ? mainAxis === 'y' ? arrowOffsetParent.clientTop || 0 : arrowOffsetParent.clientLeft || 0 : 0;\n var offsetModifierValue = (_offsetModifierState$ = offsetModifierState == null ? void 0 : offsetModifierState[mainAxis]) != null ? _offsetModifierState$ : 0;\n var tetherMin = offset + minOffset - offsetModifierValue - clientOffset;\n var tetherMax = offset + maxOffset - offsetModifierValue;\n var preventedOffset = within(tether ? mathMin(min, tetherMin) : min, offset, tether ? mathMax(max, tetherMax) : max);\n popperOffsets[mainAxis] = preventedOffset;\n data[mainAxis] = preventedOffset - offset;\n }\n\n if (checkAltAxis) {\n var _offsetModifierState$2;\n\n var _mainSide = mainAxis === 'x' ? top : left;\n\n var _altSide = mainAxis === 'x' ? bottom : right;\n\n var _offset = popperOffsets[altAxis];\n\n var _len = altAxis === 'y' ? 'height' : 'width';\n\n var _min = _offset + overflow[_mainSide];\n\n var _max = _offset - overflow[_altSide];\n\n var isOriginSide = [top, left].indexOf(basePlacement) !== -1;\n\n var _offsetModifierValue = (_offsetModifierState$2 = offsetModifierState == null ? void 0 : offsetModifierState[altAxis]) != null ? _offsetModifierState$2 : 0;\n\n var _tetherMin = isOriginSide ? _min : _offset - referenceRect[_len] - popperRect[_len] - _offsetModifierValue + normalizedTetherOffsetValue.altAxis;\n\n var _tetherMax = isOriginSide ? _offset + referenceRect[_len] + popperRect[_len] - _offsetModifierValue - normalizedTetherOffsetValue.altAxis : _max;\n\n var _preventedOffset = tether && isOriginSide ? withinMaxClamp(_tetherMin, _offset, _tetherMax) : within(tether ? _tetherMin : _min, _offset, tether ? _tetherMax : _max);\n\n popperOffsets[altAxis] = _preventedOffset;\n data[altAxis] = _preventedOffset - _offset;\n }\n\n state.modifiersData[name] = data;\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'preventOverflow',\n enabled: true,\n phase: 'main',\n fn: preventOverflow,\n requiresIfExists: ['offset']\n};","export default function getHTMLElementScroll(element) {\n return {\n scrollLeft: element.scrollLeft,\n scrollTop: element.scrollTop\n };\n}","import getWindowScroll from \"./getWindowScroll.js\";\nimport getWindow from \"./getWindow.js\";\nimport { isHTMLElement } from \"./instanceOf.js\";\nimport getHTMLElementScroll from \"./getHTMLElementScroll.js\";\nexport default function getNodeScroll(node) {\n if (node === getWindow(node) || !isHTMLElement(node)) {\n return getWindowScroll(node);\n } else {\n return getHTMLElementScroll(node);\n }\n}","import getBoundingClientRect from \"./getBoundingClientRect.js\";\nimport getNodeScroll from \"./getNodeScroll.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport { isHTMLElement } from \"./instanceOf.js\";\nimport getWindowScrollBarX from \"./getWindowScrollBarX.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport isScrollParent from \"./isScrollParent.js\";\nimport { round } from \"../utils/math.js\";\n\nfunction isElementScaled(element) {\n var rect = element.getBoundingClientRect();\n var scaleX = round(rect.width) / element.offsetWidth || 1;\n var scaleY = round(rect.height) / element.offsetHeight || 1;\n return scaleX !== 1 || scaleY !== 1;\n} // Returns the composite rect of an element relative to its offsetParent.\n// Composite means it takes into account transforms as well as layout.\n\n\nexport default function getCompositeRect(elementOrVirtualElement, offsetParent, isFixed) {\n if (isFixed === void 0) {\n isFixed = false;\n }\n\n var isOffsetParentAnElement = isHTMLElement(offsetParent);\n var offsetParentIsScaled = isHTMLElement(offsetParent) && isElementScaled(offsetParent);\n var documentElement = getDocumentElement(offsetParent);\n var rect = getBoundingClientRect(elementOrVirtualElement, offsetParentIsScaled, isFixed);\n var scroll = {\n scrollLeft: 0,\n scrollTop: 0\n };\n var offsets = {\n x: 0,\n y: 0\n };\n\n if (isOffsetParentAnElement || !isOffsetParentAnElement && !isFixed) {\n if (getNodeName(offsetParent) !== 'body' || // https://github.com/popperjs/popper-core/issues/1078\n isScrollParent(documentElement)) {\n scroll = getNodeScroll(offsetParent);\n }\n\n if (isHTMLElement(offsetParent)) {\n offsets = getBoundingClientRect(offsetParent, true);\n offsets.x += offsetParent.clientLeft;\n offsets.y += offsetParent.clientTop;\n } else if (documentElement) {\n offsets.x = getWindowScrollBarX(documentElement);\n }\n }\n\n return {\n x: rect.left + scroll.scrollLeft - offsets.x,\n y: rect.top + scroll.scrollTop - offsets.y,\n width: rect.width,\n height: rect.height\n };\n}","import { modifierPhases } from \"../enums.js\"; // source: https://stackoverflow.com/questions/49875255\n\nfunction order(modifiers) {\n var map = new Map();\n var visited = new Set();\n var result = [];\n modifiers.forEach(function (modifier) {\n map.set(modifier.name, modifier);\n }); // On visiting object, check for its dependencies and visit them recursively\n\n function sort(modifier) {\n visited.add(modifier.name);\n var requires = [].concat(modifier.requires || [], modifier.requiresIfExists || []);\n requires.forEach(function (dep) {\n if (!visited.has(dep)) {\n var depModifier = map.get(dep);\n\n if (depModifier) {\n sort(depModifier);\n }\n }\n });\n result.push(modifier);\n }\n\n modifiers.forEach(function (modifier) {\n if (!visited.has(modifier.name)) {\n // check for visited object\n sort(modifier);\n }\n });\n return result;\n}\n\nexport default function orderModifiers(modifiers) {\n // order based on dependencies\n var orderedModifiers = order(modifiers); // order based on phase\n\n return modifierPhases.reduce(function (acc, phase) {\n return acc.concat(orderedModifiers.filter(function (modifier) {\n return modifier.phase === phase;\n }));\n }, []);\n}","export default function debounce(fn) {\n var pending;\n return function () {\n if (!pending) {\n pending = new Promise(function (resolve) {\n Promise.resolve().then(function () {\n pending = undefined;\n resolve(fn());\n });\n });\n }\n\n return pending;\n };\n}","export default function mergeByName(modifiers) {\n var merged = modifiers.reduce(function (merged, current) {\n var existing = merged[current.name];\n merged[current.name] = existing ? Object.assign({}, existing, current, {\n options: Object.assign({}, existing.options, current.options),\n data: Object.assign({}, existing.data, current.data)\n }) : current;\n return merged;\n }, {}); // IE11 does not support Object.values\n\n return Object.keys(merged).map(function (key) {\n return merged[key];\n });\n}","import getCompositeRect from \"./dom-utils/getCompositeRect.js\";\nimport getLayoutRect from \"./dom-utils/getLayoutRect.js\";\nimport listScrollParents from \"./dom-utils/listScrollParents.js\";\nimport getOffsetParent from \"./dom-utils/getOffsetParent.js\";\nimport orderModifiers from \"./utils/orderModifiers.js\";\nimport debounce from \"./utils/debounce.js\";\nimport mergeByName from \"./utils/mergeByName.js\";\nimport detectOverflow from \"./utils/detectOverflow.js\";\nimport { isElement } from \"./dom-utils/instanceOf.js\";\nvar DEFAULT_OPTIONS = {\n placement: 'bottom',\n modifiers: [],\n strategy: 'absolute'\n};\n\nfunction areValidElements() {\n for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {\n args[_key] = arguments[_key];\n }\n\n return !args.some(function (element) {\n return !(element && typeof element.getBoundingClientRect === 'function');\n });\n}\n\nexport function popperGenerator(generatorOptions) {\n if (generatorOptions === void 0) {\n generatorOptions = {};\n }\n\n var _generatorOptions = generatorOptions,\n _generatorOptions$def = _generatorOptions.defaultModifiers,\n defaultModifiers = _generatorOptions$def === void 0 ? [] : _generatorOptions$def,\n _generatorOptions$def2 = _generatorOptions.defaultOptions,\n defaultOptions = _generatorOptions$def2 === void 0 ? DEFAULT_OPTIONS : _generatorOptions$def2;\n return function createPopper(reference, popper, options) {\n if (options === void 0) {\n options = defaultOptions;\n }\n\n var state = {\n placement: 'bottom',\n orderedModifiers: [],\n options: Object.assign({}, DEFAULT_OPTIONS, defaultOptions),\n modifiersData: {},\n elements: {\n reference: reference,\n popper: popper\n },\n attributes: {},\n styles: {}\n };\n var effectCleanupFns = [];\n var isDestroyed = false;\n var instance = {\n state: state,\n setOptions: function setOptions(setOptionsAction) {\n var options = typeof setOptionsAction === 'function' ? setOptionsAction(state.options) : setOptionsAction;\n cleanupModifierEffects();\n state.options = Object.assign({}, defaultOptions, state.options, options);\n state.scrollParents = {\n reference: isElement(reference) ? listScrollParents(reference) : reference.contextElement ? listScrollParents(reference.contextElement) : [],\n popper: listScrollParents(popper)\n }; // Orders the modifiers based on their dependencies and `phase`\n // properties\n\n var orderedModifiers = orderModifiers(mergeByName([].concat(defaultModifiers, state.options.modifiers))); // Strip out disabled modifiers\n\n state.orderedModifiers = orderedModifiers.filter(function (m) {\n return m.enabled;\n });\n runModifierEffects();\n return instance.update();\n },\n // Sync update – it will always be executed, even if not necessary. This\n // is useful for low frequency updates where sync behavior simplifies the\n // logic.\n // For high frequency updates (e.g. `resize` and `scroll` events), always\n // prefer the async Popper#update method\n forceUpdate: function forceUpdate() {\n if (isDestroyed) {\n return;\n }\n\n var _state$elements = state.elements,\n reference = _state$elements.reference,\n popper = _state$elements.popper; // Don't proceed if `reference` or `popper` are not valid elements\n // anymore\n\n if (!areValidElements(reference, popper)) {\n return;\n } // Store the reference and popper rects to be read by modifiers\n\n\n state.rects = {\n reference: getCompositeRect(reference, getOffsetParent(popper), state.options.strategy === 'fixed'),\n popper: getLayoutRect(popper)\n }; // Modifiers have the ability to reset the current update cycle. The\n // most common use case for this is the `flip` modifier changing the\n // placement, which then needs to re-run all the modifiers, because the\n // logic was previously ran for the previous placement and is therefore\n // stale/incorrect\n\n state.reset = false;\n state.placement = state.options.placement; // On each update cycle, the `modifiersData` property for each modifier\n // is filled with the initial data specified by the modifier. This means\n // it doesn't persist and is fresh on each update.\n // To ensure persistent data, use `${name}#persistent`\n\n state.orderedModifiers.forEach(function (modifier) {\n return state.modifiersData[modifier.name] = Object.assign({}, modifier.data);\n });\n\n for (var index = 0; index < state.orderedModifiers.length; index++) {\n if (state.reset === true) {\n state.reset = false;\n index = -1;\n continue;\n }\n\n var _state$orderedModifie = state.orderedModifiers[index],\n fn = _state$orderedModifie.fn,\n _state$orderedModifie2 = _state$orderedModifie.options,\n _options = _state$orderedModifie2 === void 0 ? {} : _state$orderedModifie2,\n name = _state$orderedModifie.name;\n\n if (typeof fn === 'function') {\n state = fn({\n state: state,\n options: _options,\n name: name,\n instance: instance\n }) || state;\n }\n }\n },\n // Async and optimistically optimized update – it will not be executed if\n // not necessary (debounced to run at most once-per-tick)\n update: debounce(function () {\n return new Promise(function (resolve) {\n instance.forceUpdate();\n resolve(state);\n });\n }),\n destroy: function destroy() {\n cleanupModifierEffects();\n isDestroyed = true;\n }\n };\n\n if (!areValidElements(reference, popper)) {\n return instance;\n }\n\n instance.setOptions(options).then(function (state) {\n if (!isDestroyed && options.onFirstUpdate) {\n options.onFirstUpdate(state);\n }\n }); // Modifiers have the ability to execute arbitrary code before the first\n // update cycle runs. They will be executed in the same order as the update\n // cycle. This is useful when a modifier adds some persistent data that\n // other modifiers need to use, but the modifier is run after the dependent\n // one.\n\n function runModifierEffects() {\n state.orderedModifiers.forEach(function (_ref) {\n var name = _ref.name,\n _ref$options = _ref.options,\n options = _ref$options === void 0 ? {} : _ref$options,\n effect = _ref.effect;\n\n if (typeof effect === 'function') {\n var cleanupFn = effect({\n state: state,\n name: name,\n instance: instance,\n options: options\n });\n\n var noopFn = function noopFn() {};\n\n effectCleanupFns.push(cleanupFn || noopFn);\n }\n });\n }\n\n function cleanupModifierEffects() {\n effectCleanupFns.forEach(function (fn) {\n return fn();\n });\n effectCleanupFns = [];\n }\n\n return instance;\n };\n}\nexport var createPopper = /*#__PURE__*/popperGenerator(); // eslint-disable-next-line import/no-unused-modules\n\nexport { detectOverflow };","import { popperGenerator, detectOverflow } from \"./createPopper.js\";\nimport eventListeners from \"./modifiers/eventListeners.js\";\nimport popperOffsets from \"./modifiers/popperOffsets.js\";\nimport computeStyles from \"./modifiers/computeStyles.js\";\nimport applyStyles from \"./modifiers/applyStyles.js\";\nimport offset from \"./modifiers/offset.js\";\nimport flip from \"./modifiers/flip.js\";\nimport preventOverflow from \"./modifiers/preventOverflow.js\";\nimport arrow from \"./modifiers/arrow.js\";\nimport hide from \"./modifiers/hide.js\";\nvar defaultModifiers = [eventListeners, popperOffsets, computeStyles, applyStyles, offset, flip, preventOverflow, arrow, hide];\nvar createPopper = /*#__PURE__*/popperGenerator({\n defaultModifiers: defaultModifiers\n}); // eslint-disable-next-line import/no-unused-modules\n\nexport { createPopper, popperGenerator, defaultModifiers, detectOverflow }; // eslint-disable-next-line import/no-unused-modules\n\nexport { createPopper as createPopperLite } from \"./popper-lite.js\"; // eslint-disable-next-line import/no-unused-modules\n\nexport * from \"./modifiers/index.js\";","import { generateUtilityClass } from '../generateUtilityClass';\nimport { generateUtilityClasses } from '../generateUtilityClasses';\nconst COMPONENT_NAME = 'Popper';\nexport function getPopperUtilityClass(slot) {\n return generateUtilityClass(COMPONENT_NAME, slot);\n}\nexport const popperClasses = generateUtilityClasses(COMPONENT_NAME, ['root']);","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"anchorEl\", \"children\", \"direction\", \"disablePortal\", \"modifiers\", \"open\", \"placement\", \"popperOptions\", \"popperRef\", \"slotProps\", \"slots\", \"TransitionProps\", \"ownerState\"],\n _excluded2 = [\"anchorEl\", \"children\", \"container\", \"direction\", \"disablePortal\", \"keepMounted\", \"modifiers\", \"open\", \"placement\", \"popperOptions\", \"popperRef\", \"style\", \"transition\", \"slotProps\", \"slots\"];\nimport * as React from 'react';\nimport { chainPropTypes, HTMLElementType, refType, unstable_ownerDocument as ownerDocument, unstable_useEnhancedEffect as useEnhancedEffect, unstable_useForkRef as useForkRef } from '@mui/utils';\nimport { createPopper } from '@popperjs/core';\nimport PropTypes from 'prop-types';\nimport { unstable_composeClasses as composeClasses } from '../composeClasses';\nimport { Portal } from '../Portal';\nimport { getPopperUtilityClass } from './popperClasses';\nimport { useSlotProps } from '../utils';\nimport { useClassNamesOverride } from '../utils/ClassNameConfigurator';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nfunction flipPlacement(placement, direction) {\n if (direction === 'ltr') {\n return placement;\n }\n switch (placement) {\n case 'bottom-end':\n return 'bottom-start';\n case 'bottom-start':\n return 'bottom-end';\n case 'top-end':\n return 'top-start';\n case 'top-start':\n return 'top-end';\n default:\n return placement;\n }\n}\nfunction resolveAnchorEl(anchorEl) {\n return typeof anchorEl === 'function' ? anchorEl() : anchorEl;\n}\nfunction isHTMLElement(element) {\n return element.nodeType !== undefined;\n}\nfunction isVirtualElement(element) {\n return !isHTMLElement(element);\n}\nconst useUtilityClasses = () => {\n const slots = {\n root: ['root']\n };\n return composeClasses(slots, useClassNamesOverride(getPopperUtilityClass));\n};\nconst defaultPopperOptions = {};\nconst PopperTooltip = /*#__PURE__*/React.forwardRef(function PopperTooltip(props, forwardedRef) {\n var _slots$root;\n const {\n anchorEl,\n children,\n direction,\n disablePortal,\n modifiers,\n open,\n placement: initialPlacement,\n popperOptions,\n popperRef: popperRefProp,\n slotProps = {},\n slots = {},\n TransitionProps\n // @ts-ignore internal logic\n // prevent from spreading to DOM, it can come from the parent component e.g. Select.\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const tooltipRef = React.useRef(null);\n const ownRef = useForkRef(tooltipRef, forwardedRef);\n const popperRef = React.useRef(null);\n const handlePopperRef = useForkRef(popperRef, popperRefProp);\n const handlePopperRefRef = React.useRef(handlePopperRef);\n useEnhancedEffect(() => {\n handlePopperRefRef.current = handlePopperRef;\n }, [handlePopperRef]);\n React.useImperativeHandle(popperRefProp, () => popperRef.current, []);\n const rtlPlacement = flipPlacement(initialPlacement, direction);\n /**\n * placement initialized from prop but can change during lifetime if modifiers.flip.\n * modifiers.flip is essentially a flip for controlled/uncontrolled behavior\n */\n const [placement, setPlacement] = React.useState(rtlPlacement);\n const [resolvedAnchorElement, setResolvedAnchorElement] = React.useState(resolveAnchorEl(anchorEl));\n React.useEffect(() => {\n if (popperRef.current) {\n popperRef.current.forceUpdate();\n }\n });\n React.useEffect(() => {\n if (anchorEl) {\n setResolvedAnchorElement(resolveAnchorEl(anchorEl));\n }\n }, [anchorEl]);\n useEnhancedEffect(() => {\n if (!resolvedAnchorElement || !open) {\n return undefined;\n }\n const handlePopperUpdate = data => {\n setPlacement(data.placement);\n };\n if (process.env.NODE_ENV !== 'production') {\n if (resolvedAnchorElement && isHTMLElement(resolvedAnchorElement) && resolvedAnchorElement.nodeType === 1) {\n const box = resolvedAnchorElement.getBoundingClientRect();\n if (process.env.NODE_ENV !== 'test' && box.top === 0 && box.left === 0 && box.right === 0 && box.bottom === 0) {\n console.warn(['MUI: The `anchorEl` prop provided to the component is invalid.', 'The anchor element should be part of the document layout.', \"Make sure the element is present in the document or that it's not display none.\"].join('\\n'));\n }\n }\n }\n let popperModifiers = [{\n name: 'preventOverflow',\n options: {\n altBoundary: disablePortal\n }\n }, {\n name: 'flip',\n options: {\n altBoundary: disablePortal\n }\n }, {\n name: 'onUpdate',\n enabled: true,\n phase: 'afterWrite',\n fn: ({\n state\n }) => {\n handlePopperUpdate(state);\n }\n }];\n if (modifiers != null) {\n popperModifiers = popperModifiers.concat(modifiers);\n }\n if (popperOptions && popperOptions.modifiers != null) {\n popperModifiers = popperModifiers.concat(popperOptions.modifiers);\n }\n const popper = createPopper(resolvedAnchorElement, tooltipRef.current, _extends({\n placement: rtlPlacement\n }, popperOptions, {\n modifiers: popperModifiers\n }));\n handlePopperRefRef.current(popper);\n return () => {\n popper.destroy();\n handlePopperRefRef.current(null);\n };\n }, [resolvedAnchorElement, disablePortal, modifiers, open, popperOptions, rtlPlacement]);\n const childProps = {\n placement: placement\n };\n if (TransitionProps !== null) {\n childProps.TransitionProps = TransitionProps;\n }\n const classes = useUtilityClasses();\n const Root = (_slots$root = slots.root) != null ? _slots$root : 'div';\n const rootProps = useSlotProps({\n elementType: Root,\n externalSlotProps: slotProps.root,\n externalForwardedProps: other,\n additionalProps: {\n role: 'tooltip',\n ref: ownRef\n },\n ownerState: props,\n className: classes.root\n });\n return /*#__PURE__*/_jsx(Root, _extends({}, rootProps, {\n children: typeof children === 'function' ? children(childProps) : children\n }));\n});\n\n/**\n * Poppers rely on the 3rd party library [Popper.js](https://popper.js.org/docs/v2/) for positioning.\n *\n * Demos:\n *\n * - [Popper](https://mui.com/base-ui/react-popper/)\n *\n * API:\n *\n * - [Popper API](https://mui.com/base-ui/react-popper/components-api/#popper)\n */\nconst Popper = /*#__PURE__*/React.forwardRef(function Popper(props, forwardedRef) {\n const {\n anchorEl,\n children,\n container: containerProp,\n direction = 'ltr',\n disablePortal = false,\n keepMounted = false,\n modifiers,\n open,\n placement = 'bottom',\n popperOptions = defaultPopperOptions,\n popperRef,\n style,\n transition = false,\n slotProps = {},\n slots = {}\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded2);\n const [exited, setExited] = React.useState(true);\n const handleEnter = () => {\n setExited(false);\n };\n const handleExited = () => {\n setExited(true);\n };\n if (!keepMounted && !open && (!transition || exited)) {\n return null;\n }\n\n // If the container prop is provided, use that\n // If the anchorEl prop is provided, use its parent body element as the container\n // If neither are provided let the Modal take care of choosing the container\n let container;\n if (containerProp) {\n container = containerProp;\n } else if (anchorEl) {\n const resolvedAnchorEl = resolveAnchorEl(anchorEl);\n container = resolvedAnchorEl && isHTMLElement(resolvedAnchorEl) ? ownerDocument(resolvedAnchorEl).body : ownerDocument(null).body;\n }\n const display = !open && keepMounted && (!transition || exited) ? 'none' : undefined;\n const transitionProps = transition ? {\n in: open,\n onEnter: handleEnter,\n onExited: handleExited\n } : undefined;\n return /*#__PURE__*/_jsx(Portal, {\n disablePortal: disablePortal,\n container: container,\n children: /*#__PURE__*/_jsx(PopperTooltip, _extends({\n anchorEl: anchorEl,\n direction: direction,\n disablePortal: disablePortal,\n modifiers: modifiers,\n ref: forwardedRef,\n open: transition ? !exited : open,\n placement: placement,\n popperOptions: popperOptions,\n popperRef: popperRef,\n slotProps: slotProps,\n slots: slots\n }, other, {\n style: _extends({\n // Prevents scroll issue, waiting for Popper.js to add this style once initiated.\n position: 'fixed',\n // Fix Popper.js display issue\n top: 0,\n left: 0,\n display\n }, style),\n TransitionProps: transitionProps,\n children: children\n }))\n });\n});\nprocess.env.NODE_ENV !== \"production\" ? Popper.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * An HTML element, [virtualElement](https://popper.js.org/docs/v2/virtual-elements/),\n * or a function that returns either.\n * It's used to set the position of the popper.\n * The return value will passed as the reference object of the Popper instance.\n */\n anchorEl: chainPropTypes(PropTypes.oneOfType([HTMLElementType, PropTypes.object, PropTypes.func]), props => {\n if (props.open) {\n const resolvedAnchorEl = resolveAnchorEl(props.anchorEl);\n if (resolvedAnchorEl && isHTMLElement(resolvedAnchorEl) && resolvedAnchorEl.nodeType === 1) {\n const box = resolvedAnchorEl.getBoundingClientRect();\n if (process.env.NODE_ENV !== 'test' && box.top === 0 && box.left === 0 && box.right === 0 && box.bottom === 0) {\n return new Error(['MUI: The `anchorEl` prop provided to the component is invalid.', 'The anchor element should be part of the document layout.', \"Make sure the element is present in the document or that it's not display none.\"].join('\\n'));\n }\n } else if (!resolvedAnchorEl || typeof resolvedAnchorEl.getBoundingClientRect !== 'function' || isVirtualElement(resolvedAnchorEl) && resolvedAnchorEl.contextElement != null && resolvedAnchorEl.contextElement.nodeType !== 1) {\n return new Error(['MUI: The `anchorEl` prop provided to the component is invalid.', 'It should be an HTML element instance or a virtualElement ', '(https://popper.js.org/docs/v2/virtual-elements/).'].join('\\n'));\n }\n }\n return null;\n }),\n /**\n * Popper render function or node.\n */\n children: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.node, PropTypes.func]),\n /**\n * An HTML element or function that returns one.\n * The `container` will have the portal children appended to it.\n *\n * You can also provide a callback, which is called in a React layout effect.\n * This lets you set the container from a ref, and also makes server-side rendering possible.\n *\n * By default, it uses the body of the top-level document object,\n * so it's simply `document.body` most of the time.\n */\n container: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.func]),\n /**\n * Direction of the text.\n * @default 'ltr'\n */\n direction: PropTypes.oneOf(['ltr', 'rtl']),\n /**\n * The `children` will be under the DOM hierarchy of the parent component.\n * @default false\n */\n disablePortal: PropTypes.bool,\n /**\n * Always keep the children in the DOM.\n * This prop can be useful in SEO situation or\n * when you want to maximize the responsiveness of the Popper.\n * @default false\n */\n keepMounted: PropTypes.bool,\n /**\n * Popper.js is based on a \"plugin-like\" architecture,\n * most of its features are fully encapsulated \"modifiers\".\n *\n * A modifier is a function that is called each time Popper.js needs to\n * compute the position of the popper.\n * For this reason, modifiers should be very performant to avoid bottlenecks.\n * To learn how to create a modifier, [read the modifiers documentation](https://popper.js.org/docs/v2/modifiers/).\n */\n modifiers: PropTypes.arrayOf(PropTypes.shape({\n data: PropTypes.object,\n effect: PropTypes.func,\n enabled: PropTypes.bool,\n fn: PropTypes.func,\n name: PropTypes.any,\n options: PropTypes.object,\n phase: PropTypes.oneOf(['afterMain', 'afterRead', 'afterWrite', 'beforeMain', 'beforeRead', 'beforeWrite', 'main', 'read', 'write']),\n requires: PropTypes.arrayOf(PropTypes.string),\n requiresIfExists: PropTypes.arrayOf(PropTypes.string)\n })),\n /**\n * If `true`, the component is shown.\n */\n open: PropTypes.bool.isRequired,\n /**\n * Popper placement.\n * @default 'bottom'\n */\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n /**\n * Options provided to the [`Popper.js`](https://popper.js.org/docs/v2/constructors/#options) instance.\n * @default {}\n */\n popperOptions: PropTypes.shape({\n modifiers: PropTypes.array,\n onFirstUpdate: PropTypes.func,\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n strategy: PropTypes.oneOf(['absolute', 'fixed'])\n }),\n /**\n * A ref that points to the used popper instance.\n */\n popperRef: refType,\n /**\n * The props used for each slot inside the Popper.\n * @default {}\n */\n slotProps: PropTypes.shape({\n root: PropTypes.oneOfType([PropTypes.func, PropTypes.object])\n }),\n /**\n * The components used for each slot inside the Popper.\n * Either a string to use a HTML element or a component.\n * @default {}\n */\n slots: PropTypes.shape({\n root: PropTypes.elementType\n }),\n /**\n * Help supporting a react-transition-group/Transition component.\n * @default false\n */\n transition: PropTypes.bool\n} : void 0;\nexport { Popper };","'use client';\n\nimport * as React from 'react';\nimport { useTheme as useThemeSystem } from '@mui/system';\nimport defaultTheme from './defaultTheme';\nimport THEME_ID from './identifier';\nexport default function useTheme() {\n const theme = useThemeSystem(defaultTheme);\n if (process.env.NODE_ENV !== 'production') {\n // eslint-disable-next-line react-hooks/rules-of-hooks\n React.useDebugValue(theme);\n }\n return theme[THEME_ID] || theme;\n}","export default function _setPrototypeOf(o, p) {\n _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function _setPrototypeOf(o, p) {\n o.__proto__ = p;\n return o;\n };\n return _setPrototypeOf(o, p);\n}","import setPrototypeOf from \"./setPrototypeOf.js\";\nexport default function _inheritsLoose(subClass, superClass) {\n subClass.prototype = Object.create(superClass.prototype);\n subClass.prototype.constructor = subClass;\n setPrototypeOf(subClass, superClass);\n}","export default {\n disabled: false\n};","import PropTypes from 'prop-types';\nexport var timeoutsShape = process.env.NODE_ENV !== 'production' ? PropTypes.oneOfType([PropTypes.number, PropTypes.shape({\n enter: PropTypes.number,\n exit: PropTypes.number,\n appear: PropTypes.number\n}).isRequired]) : null;\nexport var classNamesShape = process.env.NODE_ENV !== 'production' ? PropTypes.oneOfType([PropTypes.string, PropTypes.shape({\n enter: PropTypes.string,\n exit: PropTypes.string,\n active: PropTypes.string\n}), PropTypes.shape({\n enter: PropTypes.string,\n enterDone: PropTypes.string,\n enterActive: PropTypes.string,\n exit: PropTypes.string,\n exitDone: PropTypes.string,\n exitActive: PropTypes.string\n})]) : null;","import React from 'react';\nexport default React.createContext(null);","export var forceReflow = function forceReflow(node) {\n return node.scrollTop;\n};","import _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _inheritsLoose from \"@babel/runtime/helpers/esm/inheritsLoose\";\nimport PropTypes from 'prop-types';\nimport React from 'react';\nimport ReactDOM from 'react-dom';\nimport config from './config';\nimport { timeoutsShape } from './utils/PropTypes';\nimport TransitionGroupContext from './TransitionGroupContext';\nimport { forceReflow } from './utils/reflow';\nexport var UNMOUNTED = 'unmounted';\nexport var EXITED = 'exited';\nexport var ENTERING = 'entering';\nexport var ENTERED = 'entered';\nexport var EXITING = 'exiting';\n/**\n * The Transition component lets you describe a transition from one component\n * state to another _over time_ with a simple declarative API. Most commonly\n * it's used to animate the mounting and unmounting of a component, but can also\n * be used to describe in-place transition states as well.\n *\n * ---\n *\n * **Note**: `Transition` is a platform-agnostic base component. If you're using\n * transitions in CSS, you'll probably want to use\n * [`CSSTransition`](https://reactcommunity.org/react-transition-group/css-transition)\n * instead. It inherits all the features of `Transition`, but contains\n * additional features necessary to play nice with CSS transitions (hence the\n * name of the component).\n *\n * ---\n *\n * By default the `Transition` component does not alter the behavior of the\n * component it renders, it only tracks \"enter\" and \"exit\" states for the\n * components. It's up to you to give meaning and effect to those states. For\n * example we can add styles to a component when it enters or exits:\n *\n * ```jsx\n * import { Transition } from 'react-transition-group';\n *\n * const duration = 300;\n *\n * const defaultStyle = {\n * transition: `opacity ${duration}ms ease-in-out`,\n * opacity: 0,\n * }\n *\n * const transitionStyles = {\n * entering: { opacity: 1 },\n * entered: { opacity: 1 },\n * exiting: { opacity: 0 },\n * exited: { opacity: 0 },\n * };\n *\n * const Fade = ({ in: inProp }) => (\n * \n * {state => (\n *
    \n * I'm a fade Transition!\n *
    \n * )}\n *
    \n * );\n * ```\n *\n * There are 4 main states a Transition can be in:\n * - `'entering'`\n * - `'entered'`\n * - `'exiting'`\n * - `'exited'`\n *\n * Transition state is toggled via the `in` prop. When `true` the component\n * begins the \"Enter\" stage. During this stage, the component will shift from\n * its current transition state, to `'entering'` for the duration of the\n * transition and then to the `'entered'` stage once it's complete. Let's take\n * the following example (we'll use the\n * [useState](https://reactjs.org/docs/hooks-reference.html#usestate) hook):\n *\n * ```jsx\n * function App() {\n * const [inProp, setInProp] = useState(false);\n * return (\n *
    \n * \n * {state => (\n * // ...\n * )}\n * \n * \n *
    \n * );\n * }\n * ```\n *\n * When the button is clicked the component will shift to the `'entering'` state\n * and stay there for 500ms (the value of `timeout`) before it finally switches\n * to `'entered'`.\n *\n * When `in` is `false` the same thing happens except the state moves from\n * `'exiting'` to `'exited'`.\n */\n\nvar Transition = /*#__PURE__*/function (_React$Component) {\n _inheritsLoose(Transition, _React$Component);\n\n function Transition(props, context) {\n var _this;\n\n _this = _React$Component.call(this, props, context) || this;\n var parentGroup = context; // In the context of a TransitionGroup all enters are really appears\n\n var appear = parentGroup && !parentGroup.isMounting ? props.enter : props.appear;\n var initialStatus;\n _this.appearStatus = null;\n\n if (props.in) {\n if (appear) {\n initialStatus = EXITED;\n _this.appearStatus = ENTERING;\n } else {\n initialStatus = ENTERED;\n }\n } else {\n if (props.unmountOnExit || props.mountOnEnter) {\n initialStatus = UNMOUNTED;\n } else {\n initialStatus = EXITED;\n }\n }\n\n _this.state = {\n status: initialStatus\n };\n _this.nextCallback = null;\n return _this;\n }\n\n Transition.getDerivedStateFromProps = function getDerivedStateFromProps(_ref, prevState) {\n var nextIn = _ref.in;\n\n if (nextIn && prevState.status === UNMOUNTED) {\n return {\n status: EXITED\n };\n }\n\n return null;\n } // getSnapshotBeforeUpdate(prevProps) {\n // let nextStatus = null\n // if (prevProps !== this.props) {\n // const { status } = this.state\n // if (this.props.in) {\n // if (status !== ENTERING && status !== ENTERED) {\n // nextStatus = ENTERING\n // }\n // } else {\n // if (status === ENTERING || status === ENTERED) {\n // nextStatus = EXITING\n // }\n // }\n // }\n // return { nextStatus }\n // }\n ;\n\n var _proto = Transition.prototype;\n\n _proto.componentDidMount = function componentDidMount() {\n this.updateStatus(true, this.appearStatus);\n };\n\n _proto.componentDidUpdate = function componentDidUpdate(prevProps) {\n var nextStatus = null;\n\n if (prevProps !== this.props) {\n var status = this.state.status;\n\n if (this.props.in) {\n if (status !== ENTERING && status !== ENTERED) {\n nextStatus = ENTERING;\n }\n } else {\n if (status === ENTERING || status === ENTERED) {\n nextStatus = EXITING;\n }\n }\n }\n\n this.updateStatus(false, nextStatus);\n };\n\n _proto.componentWillUnmount = function componentWillUnmount() {\n this.cancelNextCallback();\n };\n\n _proto.getTimeouts = function getTimeouts() {\n var timeout = this.props.timeout;\n var exit, enter, appear;\n exit = enter = appear = timeout;\n\n if (timeout != null && typeof timeout !== 'number') {\n exit = timeout.exit;\n enter = timeout.enter; // TODO: remove fallback for next major\n\n appear = timeout.appear !== undefined ? timeout.appear : enter;\n }\n\n return {\n exit: exit,\n enter: enter,\n appear: appear\n };\n };\n\n _proto.updateStatus = function updateStatus(mounting, nextStatus) {\n if (mounting === void 0) {\n mounting = false;\n }\n\n if (nextStatus !== null) {\n // nextStatus will always be ENTERING or EXITING.\n this.cancelNextCallback();\n\n if (nextStatus === ENTERING) {\n if (this.props.unmountOnExit || this.props.mountOnEnter) {\n var node = this.props.nodeRef ? this.props.nodeRef.current : ReactDOM.findDOMNode(this); // https://github.com/reactjs/react-transition-group/pull/749\n // With unmountOnExit or mountOnEnter, the enter animation should happen at the transition between `exited` and `entering`.\n // To make the animation happen, we have to separate each rendering and avoid being processed as batched.\n\n if (node) forceReflow(node);\n }\n\n this.performEnter(mounting);\n } else {\n this.performExit();\n }\n } else if (this.props.unmountOnExit && this.state.status === EXITED) {\n this.setState({\n status: UNMOUNTED\n });\n }\n };\n\n _proto.performEnter = function performEnter(mounting) {\n var _this2 = this;\n\n var enter = this.props.enter;\n var appearing = this.context ? this.context.isMounting : mounting;\n\n var _ref2 = this.props.nodeRef ? [appearing] : [ReactDOM.findDOMNode(this), appearing],\n maybeNode = _ref2[0],\n maybeAppearing = _ref2[1];\n\n var timeouts = this.getTimeouts();\n var enterTimeout = appearing ? timeouts.appear : timeouts.enter; // no enter animation skip right to ENTERED\n // if we are mounting and running this it means appear _must_ be set\n\n if (!mounting && !enter || config.disabled) {\n this.safeSetState({\n status: ENTERED\n }, function () {\n _this2.props.onEntered(maybeNode);\n });\n return;\n }\n\n this.props.onEnter(maybeNode, maybeAppearing);\n this.safeSetState({\n status: ENTERING\n }, function () {\n _this2.props.onEntering(maybeNode, maybeAppearing);\n\n _this2.onTransitionEnd(enterTimeout, function () {\n _this2.safeSetState({\n status: ENTERED\n }, function () {\n _this2.props.onEntered(maybeNode, maybeAppearing);\n });\n });\n });\n };\n\n _proto.performExit = function performExit() {\n var _this3 = this;\n\n var exit = this.props.exit;\n var timeouts = this.getTimeouts();\n var maybeNode = this.props.nodeRef ? undefined : ReactDOM.findDOMNode(this); // no exit animation skip right to EXITED\n\n if (!exit || config.disabled) {\n this.safeSetState({\n status: EXITED\n }, function () {\n _this3.props.onExited(maybeNode);\n });\n return;\n }\n\n this.props.onExit(maybeNode);\n this.safeSetState({\n status: EXITING\n }, function () {\n _this3.props.onExiting(maybeNode);\n\n _this3.onTransitionEnd(timeouts.exit, function () {\n _this3.safeSetState({\n status: EXITED\n }, function () {\n _this3.props.onExited(maybeNode);\n });\n });\n });\n };\n\n _proto.cancelNextCallback = function cancelNextCallback() {\n if (this.nextCallback !== null) {\n this.nextCallback.cancel();\n this.nextCallback = null;\n }\n };\n\n _proto.safeSetState = function safeSetState(nextState, callback) {\n // This shouldn't be necessary, but there are weird race conditions with\n // setState callbacks and unmounting in testing, so always make sure that\n // we can cancel any pending setState callbacks after we unmount.\n callback = this.setNextCallback(callback);\n this.setState(nextState, callback);\n };\n\n _proto.setNextCallback = function setNextCallback(callback) {\n var _this4 = this;\n\n var active = true;\n\n this.nextCallback = function (event) {\n if (active) {\n active = false;\n _this4.nextCallback = null;\n callback(event);\n }\n };\n\n this.nextCallback.cancel = function () {\n active = false;\n };\n\n return this.nextCallback;\n };\n\n _proto.onTransitionEnd = function onTransitionEnd(timeout, handler) {\n this.setNextCallback(handler);\n var node = this.props.nodeRef ? this.props.nodeRef.current : ReactDOM.findDOMNode(this);\n var doesNotHaveTimeoutOrListener = timeout == null && !this.props.addEndListener;\n\n if (!node || doesNotHaveTimeoutOrListener) {\n setTimeout(this.nextCallback, 0);\n return;\n }\n\n if (this.props.addEndListener) {\n var _ref3 = this.props.nodeRef ? [this.nextCallback] : [node, this.nextCallback],\n maybeNode = _ref3[0],\n maybeNextCallback = _ref3[1];\n\n this.props.addEndListener(maybeNode, maybeNextCallback);\n }\n\n if (timeout != null) {\n setTimeout(this.nextCallback, timeout);\n }\n };\n\n _proto.render = function render() {\n var status = this.state.status;\n\n if (status === UNMOUNTED) {\n return null;\n }\n\n var _this$props = this.props,\n children = _this$props.children,\n _in = _this$props.in,\n _mountOnEnter = _this$props.mountOnEnter,\n _unmountOnExit = _this$props.unmountOnExit,\n _appear = _this$props.appear,\n _enter = _this$props.enter,\n _exit = _this$props.exit,\n _timeout = _this$props.timeout,\n _addEndListener = _this$props.addEndListener,\n _onEnter = _this$props.onEnter,\n _onEntering = _this$props.onEntering,\n _onEntered = _this$props.onEntered,\n _onExit = _this$props.onExit,\n _onExiting = _this$props.onExiting,\n _onExited = _this$props.onExited,\n _nodeRef = _this$props.nodeRef,\n childProps = _objectWithoutPropertiesLoose(_this$props, [\"children\", \"in\", \"mountOnEnter\", \"unmountOnExit\", \"appear\", \"enter\", \"exit\", \"timeout\", \"addEndListener\", \"onEnter\", \"onEntering\", \"onEntered\", \"onExit\", \"onExiting\", \"onExited\", \"nodeRef\"]);\n\n return (\n /*#__PURE__*/\n // allows for nested Transitions\n React.createElement(TransitionGroupContext.Provider, {\n value: null\n }, typeof children === 'function' ? children(status, childProps) : React.cloneElement(React.Children.only(children), childProps))\n );\n };\n\n return Transition;\n}(React.Component);\n\nTransition.contextType = TransitionGroupContext;\nTransition.propTypes = process.env.NODE_ENV !== \"production\" ? {\n /**\n * A React reference to DOM element that need to transition:\n * https://stackoverflow.com/a/51127130/4671932\n *\n * - When `nodeRef` prop is used, `node` is not passed to callback functions\n * (e.g. `onEnter`) because user already has direct access to the node.\n * - When changing `key` prop of `Transition` in a `TransitionGroup` a new\n * `nodeRef` need to be provided to `Transition` with changed `key` prop\n * (see\n * [test/CSSTransition-test.js](https://github.com/reactjs/react-transition-group/blob/13435f897b3ab71f6e19d724f145596f5910581c/test/CSSTransition-test.js#L362-L437)).\n */\n nodeRef: PropTypes.shape({\n current: typeof Element === 'undefined' ? PropTypes.any : function (propValue, key, componentName, location, propFullName, secret) {\n var value = propValue[key];\n return PropTypes.instanceOf(value && 'ownerDocument' in value ? value.ownerDocument.defaultView.Element : Element)(propValue, key, componentName, location, propFullName, secret);\n }\n }),\n\n /**\n * A `function` child can be used instead of a React element. This function is\n * called with the current transition status (`'entering'`, `'entered'`,\n * `'exiting'`, `'exited'`), which can be used to apply context\n * specific props to a component.\n *\n * ```jsx\n * \n * {state => (\n * \n * )}\n * \n * ```\n */\n children: PropTypes.oneOfType([PropTypes.func.isRequired, PropTypes.element.isRequired]).isRequired,\n\n /**\n * Show the component; triggers the enter or exit states\n */\n in: PropTypes.bool,\n\n /**\n * By default the child component is mounted immediately along with\n * the parent `Transition` component. If you want to \"lazy mount\" the component on the\n * first `in={true}` you can set `mountOnEnter`. After the first enter transition the component will stay\n * mounted, even on \"exited\", unless you also specify `unmountOnExit`.\n */\n mountOnEnter: PropTypes.bool,\n\n /**\n * By default the child component stays mounted after it reaches the `'exited'` state.\n * Set `unmountOnExit` if you'd prefer to unmount the component after it finishes exiting.\n */\n unmountOnExit: PropTypes.bool,\n\n /**\n * By default the child component does not perform the enter transition when\n * it first mounts, regardless of the value of `in`. If you want this\n * behavior, set both `appear` and `in` to `true`.\n *\n * > **Note**: there are no special appear states like `appearing`/`appeared`, this prop\n * > only adds an additional enter transition. However, in the\n * > `` component that first enter transition does result in\n * > additional `.appear-*` classes, that way you can choose to style it\n * > differently.\n */\n appear: PropTypes.bool,\n\n /**\n * Enable or disable enter transitions.\n */\n enter: PropTypes.bool,\n\n /**\n * Enable or disable exit transitions.\n */\n exit: PropTypes.bool,\n\n /**\n * The duration of the transition, in milliseconds.\n * Required unless `addEndListener` is provided.\n *\n * You may specify a single timeout for all transitions:\n *\n * ```jsx\n * timeout={500}\n * ```\n *\n * or individually:\n *\n * ```jsx\n * timeout={{\n * appear: 500,\n * enter: 300,\n * exit: 500,\n * }}\n * ```\n *\n * - `appear` defaults to the value of `enter`\n * - `enter` defaults to `0`\n * - `exit` defaults to `0`\n *\n * @type {number | { enter?: number, exit?: number, appear?: number }}\n */\n timeout: function timeout(props) {\n var pt = timeoutsShape;\n if (!props.addEndListener) pt = pt.isRequired;\n\n for (var _len = arguments.length, args = new Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) {\n args[_key - 1] = arguments[_key];\n }\n\n return pt.apply(void 0, [props].concat(args));\n },\n\n /**\n * Add a custom transition end trigger. Called with the transitioning\n * DOM node and a `done` callback. Allows for more fine grained transition end\n * logic. Timeouts are still used as a fallback if provided.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * ```jsx\n * addEndListener={(node, done) => {\n * // use the css transitionend event to mark the finish of a transition\n * node.addEventListener('transitionend', done, false);\n * }}\n * ```\n */\n addEndListener: PropTypes.func,\n\n /**\n * Callback fired before the \"entering\" status is applied. An extra parameter\n * `isAppearing` is supplied to indicate if the enter stage is occurring on the initial mount\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement, isAppearing: bool) -> void\n */\n onEnter: PropTypes.func,\n\n /**\n * Callback fired after the \"entering\" status is applied. An extra parameter\n * `isAppearing` is supplied to indicate if the enter stage is occurring on the initial mount\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement, isAppearing: bool)\n */\n onEntering: PropTypes.func,\n\n /**\n * Callback fired after the \"entered\" status is applied. An extra parameter\n * `isAppearing` is supplied to indicate if the enter stage is occurring on the initial mount\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement, isAppearing: bool) -> void\n */\n onEntered: PropTypes.func,\n\n /**\n * Callback fired before the \"exiting\" status is applied.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement) -> void\n */\n onExit: PropTypes.func,\n\n /**\n * Callback fired after the \"exiting\" status is applied.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement) -> void\n */\n onExiting: PropTypes.func,\n\n /**\n * Callback fired after the \"exited\" status is applied.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed\n *\n * @type Function(node: HtmlElement) -> void\n */\n onExited: PropTypes.func\n} : {}; // Name the function so it is clearer in the documentation\n\nfunction noop() {}\n\nTransition.defaultProps = {\n in: false,\n mountOnEnter: false,\n unmountOnExit: false,\n appear: false,\n enter: true,\n exit: true,\n onEnter: noop,\n onEntering: noop,\n onEntered: noop,\n onExit: noop,\n onExiting: noop,\n onExited: noop\n};\nTransition.UNMOUNTED = UNMOUNTED;\nTransition.EXITED = EXITED;\nTransition.ENTERING = ENTERING;\nTransition.ENTERED = ENTERED;\nTransition.EXITING = EXITING;\nexport default Transition;","export const reflow = node => node.scrollTop;\nexport function getTransitionProps(props, options) {\n var _style$transitionDura, _style$transitionTimi;\n const {\n timeout,\n easing,\n style = {}\n } = props;\n return {\n duration: (_style$transitionDura = style.transitionDuration) != null ? _style$transitionDura : typeof timeout === 'number' ? timeout : timeout[options.mode] || 0,\n easing: (_style$transitionTimi = style.transitionTimingFunction) != null ? _style$transitionTimi : typeof easing === 'object' ? easing[options.mode] : easing,\n delay: style.transitionDelay\n };\n}","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"addEndListener\", \"appear\", \"children\", \"easing\", \"in\", \"onEnter\", \"onEntered\", \"onEntering\", \"onExit\", \"onExited\", \"onExiting\", \"style\", \"timeout\", \"TransitionComponent\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport { elementAcceptingRef, unstable_useTimeout as useTimeout } from '@mui/utils';\nimport { Transition } from 'react-transition-group';\nimport useTheme from '../styles/useTheme';\nimport { getTransitionProps, reflow } from '../transitions/utils';\nimport useForkRef from '../utils/useForkRef';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nfunction getScale(value) {\n return `scale(${value}, ${value ** 2})`;\n}\nconst styles = {\n entering: {\n opacity: 1,\n transform: getScale(1)\n },\n entered: {\n opacity: 1,\n transform: 'none'\n }\n};\n\n/*\n TODO v6: remove\n Conditionally apply a workaround for the CSS transition bug in Safari 15.4 / WebKit browsers.\n */\nconst isWebKit154 = typeof navigator !== 'undefined' && /^((?!chrome|android).)*(safari|mobile)/i.test(navigator.userAgent) && /(os |version\\/)15(.|_)4/i.test(navigator.userAgent);\n\n/**\n * The Grow transition is used by the [Tooltip](/material-ui/react-tooltip/) and\n * [Popover](/material-ui/react-popover/) components.\n * It uses [react-transition-group](https://github.com/reactjs/react-transition-group) internally.\n */\nconst Grow = /*#__PURE__*/React.forwardRef(function Grow(props, ref) {\n const {\n addEndListener,\n appear = true,\n children,\n easing,\n in: inProp,\n onEnter,\n onEntered,\n onEntering,\n onExit,\n onExited,\n onExiting,\n style,\n timeout = 'auto',\n // eslint-disable-next-line react/prop-types\n TransitionComponent = Transition\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const timer = useTimeout();\n const autoTimeout = React.useRef();\n const theme = useTheme();\n const nodeRef = React.useRef(null);\n const handleRef = useForkRef(nodeRef, children.ref, ref);\n const normalizedTransitionCallback = callback => maybeIsAppearing => {\n if (callback) {\n const node = nodeRef.current;\n\n // onEnterXxx and onExitXxx callbacks have a different arguments.length value.\n if (maybeIsAppearing === undefined) {\n callback(node);\n } else {\n callback(node, maybeIsAppearing);\n }\n }\n };\n const handleEntering = normalizedTransitionCallback(onEntering);\n const handleEnter = normalizedTransitionCallback((node, isAppearing) => {\n reflow(node); // So the animation always start from the start.\n\n const {\n duration: transitionDuration,\n delay,\n easing: transitionTimingFunction\n } = getTransitionProps({\n style,\n timeout,\n easing\n }, {\n mode: 'enter'\n });\n let duration;\n if (timeout === 'auto') {\n duration = theme.transitions.getAutoHeightDuration(node.clientHeight);\n autoTimeout.current = duration;\n } else {\n duration = transitionDuration;\n }\n node.style.transition = [theme.transitions.create('opacity', {\n duration,\n delay\n }), theme.transitions.create('transform', {\n duration: isWebKit154 ? duration : duration * 0.666,\n delay,\n easing: transitionTimingFunction\n })].join(',');\n if (onEnter) {\n onEnter(node, isAppearing);\n }\n });\n const handleEntered = normalizedTransitionCallback(onEntered);\n const handleExiting = normalizedTransitionCallback(onExiting);\n const handleExit = normalizedTransitionCallback(node => {\n const {\n duration: transitionDuration,\n delay,\n easing: transitionTimingFunction\n } = getTransitionProps({\n style,\n timeout,\n easing\n }, {\n mode: 'exit'\n });\n let duration;\n if (timeout === 'auto') {\n duration = theme.transitions.getAutoHeightDuration(node.clientHeight);\n autoTimeout.current = duration;\n } else {\n duration = transitionDuration;\n }\n node.style.transition = [theme.transitions.create('opacity', {\n duration,\n delay\n }), theme.transitions.create('transform', {\n duration: isWebKit154 ? duration : duration * 0.666,\n delay: isWebKit154 ? delay : delay || duration * 0.333,\n easing: transitionTimingFunction\n })].join(',');\n node.style.opacity = 0;\n node.style.transform = getScale(0.75);\n if (onExit) {\n onExit(node);\n }\n });\n const handleExited = normalizedTransitionCallback(onExited);\n const handleAddEndListener = next => {\n if (timeout === 'auto') {\n timer.start(autoTimeout.current || 0, next);\n }\n if (addEndListener) {\n // Old call signature before `react-transition-group` implemented `nodeRef`\n addEndListener(nodeRef.current, next);\n }\n };\n return /*#__PURE__*/_jsx(TransitionComponent, _extends({\n appear: appear,\n in: inProp,\n nodeRef: nodeRef,\n onEnter: handleEnter,\n onEntered: handleEntered,\n onEntering: handleEntering,\n onExit: handleExit,\n onExited: handleExited,\n onExiting: handleExiting,\n addEndListener: handleAddEndListener,\n timeout: timeout === 'auto' ? null : timeout\n }, other, {\n children: (state, childProps) => {\n return /*#__PURE__*/React.cloneElement(children, _extends({\n style: _extends({\n opacity: 0,\n transform: getScale(0.75),\n visibility: state === 'exited' && !inProp ? 'hidden' : undefined\n }, styles[state], style, children.props.style),\n ref: handleRef\n }, childProps));\n }\n }));\n});\nprocess.env.NODE_ENV !== \"production\" ? Grow.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the d.ts file and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * Add a custom transition end trigger. Called with the transitioning DOM\n * node and a done callback. Allows for more fine grained transition end\n * logic. Note: Timeouts are still used as a fallback if provided.\n */\n addEndListener: PropTypes.func,\n /**\n * Perform the enter transition when it first mounts if `in` is also `true`.\n * Set this to `false` to disable this behavior.\n * @default true\n */\n appear: PropTypes.bool,\n /**\n * A single child content element.\n */\n children: elementAcceptingRef.isRequired,\n /**\n * The transition timing function.\n * You may specify a single easing or a object containing enter and exit values.\n */\n easing: PropTypes.oneOfType([PropTypes.shape({\n enter: PropTypes.string,\n exit: PropTypes.string\n }), PropTypes.string]),\n /**\n * If `true`, the component will transition in.\n */\n in: PropTypes.bool,\n /**\n * @ignore\n */\n onEnter: PropTypes.func,\n /**\n * @ignore\n */\n onEntered: PropTypes.func,\n /**\n * @ignore\n */\n onEntering: PropTypes.func,\n /**\n * @ignore\n */\n onExit: PropTypes.func,\n /**\n * @ignore\n */\n onExited: PropTypes.func,\n /**\n * @ignore\n */\n onExiting: PropTypes.func,\n /**\n * @ignore\n */\n style: PropTypes.object,\n /**\n * The duration for the transition, in milliseconds.\n * You may specify a single timeout for all transitions, or individually with an object.\n *\n * Set to 'auto' to automatically calculate transition time based on height.\n * @default 'auto'\n */\n timeout: PropTypes.oneOfType([PropTypes.oneOf(['auto']), PropTypes.number, PropTypes.shape({\n appear: PropTypes.number,\n enter: PropTypes.number,\n exit: PropTypes.number\n })])\n} : void 0;\nGrow.muiSupportAuto = true;\nexport default Grow;","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"anchorEl\", \"component\", \"components\", \"componentsProps\", \"container\", \"disablePortal\", \"keepMounted\", \"modifiers\", \"open\", \"placement\", \"popperOptions\", \"popperRef\", \"transition\", \"slots\", \"slotProps\"];\nimport { Popper as BasePopper } from '@mui/base/Popper';\nimport { useThemeWithoutDefault as useTheme } from '@mui/system';\nimport { HTMLElementType, refType } from '@mui/utils';\nimport PropTypes from 'prop-types';\nimport * as React from 'react';\nimport { styled, useThemeProps } from '../styles';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nconst PopperRoot = styled(BasePopper, {\n name: 'MuiPopper',\n slot: 'Root',\n overridesResolver: (props, styles) => styles.root\n})({});\n\n/**\n *\n * Demos:\n *\n * - [Autocomplete](https://mui.com/material-ui/react-autocomplete/)\n * - [Menu](https://mui.com/material-ui/react-menu/)\n * - [Popper](https://mui.com/material-ui/react-popper/)\n *\n * API:\n *\n * - [Popper API](https://mui.com/material-ui/api/popper/)\n */\nconst Popper = /*#__PURE__*/React.forwardRef(function Popper(inProps, ref) {\n var _slots$root;\n const theme = useTheme();\n const props = useThemeProps({\n props: inProps,\n name: 'MuiPopper'\n });\n const {\n anchorEl,\n component,\n components,\n componentsProps,\n container,\n disablePortal,\n keepMounted,\n modifiers,\n open,\n placement,\n popperOptions,\n popperRef,\n transition,\n slots,\n slotProps\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const RootComponent = (_slots$root = slots == null ? void 0 : slots.root) != null ? _slots$root : components == null ? void 0 : components.Root;\n const otherProps = _extends({\n anchorEl,\n container,\n disablePortal,\n keepMounted,\n modifiers,\n open,\n placement,\n popperOptions,\n popperRef,\n transition\n }, other);\n return /*#__PURE__*/_jsx(PopperRoot, _extends({\n as: component,\n direction: theme == null ? void 0 : theme.direction,\n slots: {\n root: RootComponent\n },\n slotProps: slotProps != null ? slotProps : componentsProps\n }, otherProps, {\n ref: ref\n }));\n});\nprocess.env.NODE_ENV !== \"production\" ? Popper.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * An HTML element, [virtualElement](https://popper.js.org/docs/v2/virtual-elements/),\n * or a function that returns either.\n * It's used to set the position of the popper.\n * The return value will passed as the reference object of the Popper instance.\n */\n anchorEl: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.object, PropTypes.func]),\n /**\n * Popper render function or node.\n */\n children: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.node, PropTypes.func]),\n /**\n * The component used for the root node.\n * Either a string to use a HTML element or a component.\n */\n component: PropTypes.elementType,\n /**\n * The components used for each slot inside the Popper.\n * Either a string to use a HTML element or a component.\n * @default {}\n */\n components: PropTypes.shape({\n Root: PropTypes.elementType\n }),\n /**\n * The props used for each slot inside the Popper.\n * @default {}\n */\n componentsProps: PropTypes.shape({\n root: PropTypes.oneOfType([PropTypes.func, PropTypes.object])\n }),\n /**\n * An HTML element or function that returns one.\n * The `container` will have the portal children appended to it.\n *\n * You can also provide a callback, which is called in a React layout effect.\n * This lets you set the container from a ref, and also makes server-side rendering possible.\n *\n * By default, it uses the body of the top-level document object,\n * so it's simply `document.body` most of the time.\n */\n container: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.func]),\n /**\n * The `children` will be under the DOM hierarchy of the parent component.\n * @default false\n */\n disablePortal: PropTypes.bool,\n /**\n * Always keep the children in the DOM.\n * This prop can be useful in SEO situation or\n * when you want to maximize the responsiveness of the Popper.\n * @default false\n */\n keepMounted: PropTypes.bool,\n /**\n * Popper.js is based on a \"plugin-like\" architecture,\n * most of its features are fully encapsulated \"modifiers\".\n *\n * A modifier is a function that is called each time Popper.js needs to\n * compute the position of the popper.\n * For this reason, modifiers should be very performant to avoid bottlenecks.\n * To learn how to create a modifier, [read the modifiers documentation](https://popper.js.org/docs/v2/modifiers/).\n */\n modifiers: PropTypes.arrayOf(PropTypes.shape({\n data: PropTypes.object,\n effect: PropTypes.func,\n enabled: PropTypes.bool,\n fn: PropTypes.func,\n name: PropTypes.any,\n options: PropTypes.object,\n phase: PropTypes.oneOf(['afterMain', 'afterRead', 'afterWrite', 'beforeMain', 'beforeRead', 'beforeWrite', 'main', 'read', 'write']),\n requires: PropTypes.arrayOf(PropTypes.string),\n requiresIfExists: PropTypes.arrayOf(PropTypes.string)\n })),\n /**\n * If `true`, the component is shown.\n */\n open: PropTypes.bool.isRequired,\n /**\n * Popper placement.\n * @default 'bottom'\n */\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n /**\n * Options provided to the [`Popper.js`](https://popper.js.org/docs/v2/constructors/#options) instance.\n * @default {}\n */\n popperOptions: PropTypes.shape({\n modifiers: PropTypes.array,\n onFirstUpdate: PropTypes.func,\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n strategy: PropTypes.oneOf(['absolute', 'fixed'])\n }),\n /**\n * A ref that points to the used popper instance.\n */\n popperRef: refType,\n /**\n * The props used for each slot inside the Popper.\n * @default {}\n */\n slotProps: PropTypes.shape({\n root: PropTypes.oneOfType([PropTypes.func, PropTypes.object])\n }),\n /**\n * The components used for each slot inside the Popper.\n * Either a string to use a HTML element or a component.\n * @default {}\n */\n slots: PropTypes.shape({\n root: PropTypes.elementType\n }),\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Help supporting a react-transition-group/Transition component.\n * @default false\n */\n transition: PropTypes.bool\n} : void 0;\nexport default Popper;","import generateUtilityClasses from '@mui/utils/generateUtilityClasses';\nimport generateUtilityClass from '@mui/utils/generateUtilityClass';\nexport function getTooltipUtilityClass(slot) {\n return generateUtilityClass('MuiTooltip', slot);\n}\nconst tooltipClasses = generateUtilityClasses('MuiTooltip', ['popper', 'popperInteractive', 'popperArrow', 'popperClose', 'tooltip', 'tooltipArrow', 'touch', 'tooltipPlacementLeft', 'tooltipPlacementRight', 'tooltipPlacementTop', 'tooltipPlacementBottom', 'arrow']);\nexport default tooltipClasses;","'use client';\n\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nconst _excluded = [\"arrow\", \"children\", \"classes\", \"components\", \"componentsProps\", \"describeChild\", \"disableFocusListener\", \"disableHoverListener\", \"disableInteractive\", \"disableTouchListener\", \"enterDelay\", \"enterNextDelay\", \"enterTouchDelay\", \"followCursor\", \"id\", \"leaveDelay\", \"leaveTouchDelay\", \"onClose\", \"onOpen\", \"open\", \"placement\", \"PopperComponent\", \"PopperProps\", \"slotProps\", \"slots\", \"title\", \"TransitionComponent\", \"TransitionProps\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport clsx from 'clsx';\nimport { elementAcceptingRef, unstable_useTimeout as useTimeout, unstable_Timeout as Timeout } from '@mui/utils';\nimport { unstable_composeClasses as composeClasses, appendOwnerState } from '@mui/base';\nimport { alpha } from '@mui/system';\nimport styled from '../styles/styled';\nimport useTheme from '../styles/useTheme';\nimport useThemeProps from '../styles/useThemeProps';\nimport capitalize from '../utils/capitalize';\nimport Grow from '../Grow';\nimport Popper from '../Popper';\nimport useEventCallback from '../utils/useEventCallback';\nimport useForkRef from '../utils/useForkRef';\nimport useId from '../utils/useId';\nimport useIsFocusVisible from '../utils/useIsFocusVisible';\nimport useControlled from '../utils/useControlled';\nimport tooltipClasses, { getTooltipUtilityClass } from './tooltipClasses';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nimport { jsxs as _jsxs } from \"react/jsx-runtime\";\nfunction round(value) {\n return Math.round(value * 1e5) / 1e5;\n}\nconst useUtilityClasses = ownerState => {\n const {\n classes,\n disableInteractive,\n arrow,\n touch,\n placement\n } = ownerState;\n const slots = {\n popper: ['popper', !disableInteractive && 'popperInteractive', arrow && 'popperArrow'],\n tooltip: ['tooltip', arrow && 'tooltipArrow', touch && 'touch', `tooltipPlacement${capitalize(placement.split('-')[0])}`],\n arrow: ['arrow']\n };\n return composeClasses(slots, getTooltipUtilityClass, classes);\n};\nconst TooltipPopper = styled(Popper, {\n name: 'MuiTooltip',\n slot: 'Popper',\n overridesResolver: (props, styles) => {\n const {\n ownerState\n } = props;\n return [styles.popper, !ownerState.disableInteractive && styles.popperInteractive, ownerState.arrow && styles.popperArrow, !ownerState.open && styles.popperClose];\n }\n})(({\n theme,\n ownerState,\n open\n}) => _extends({\n zIndex: (theme.vars || theme).zIndex.tooltip,\n pointerEvents: 'none'\n}, !ownerState.disableInteractive && {\n pointerEvents: 'auto'\n}, !open && {\n pointerEvents: 'none'\n}, ownerState.arrow && {\n [`&[data-popper-placement*=\"bottom\"] .${tooltipClasses.arrow}`]: {\n top: 0,\n marginTop: '-0.71em',\n '&::before': {\n transformOrigin: '0 100%'\n }\n },\n [`&[data-popper-placement*=\"top\"] .${tooltipClasses.arrow}`]: {\n bottom: 0,\n marginBottom: '-0.71em',\n '&::before': {\n transformOrigin: '100% 0'\n }\n },\n [`&[data-popper-placement*=\"right\"] .${tooltipClasses.arrow}`]: _extends({}, !ownerState.isRtl ? {\n left: 0,\n marginLeft: '-0.71em'\n } : {\n right: 0,\n marginRight: '-0.71em'\n }, {\n height: '1em',\n width: '0.71em',\n '&::before': {\n transformOrigin: '100% 100%'\n }\n }),\n [`&[data-popper-placement*=\"left\"] .${tooltipClasses.arrow}`]: _extends({}, !ownerState.isRtl ? {\n right: 0,\n marginRight: '-0.71em'\n } : {\n left: 0,\n marginLeft: '-0.71em'\n }, {\n height: '1em',\n width: '0.71em',\n '&::before': {\n transformOrigin: '0 0'\n }\n })\n}));\nconst TooltipTooltip = styled('div', {\n name: 'MuiTooltip',\n slot: 'Tooltip',\n overridesResolver: (props, styles) => {\n const {\n ownerState\n } = props;\n return [styles.tooltip, ownerState.touch && styles.touch, ownerState.arrow && styles.tooltipArrow, styles[`tooltipPlacement${capitalize(ownerState.placement.split('-')[0])}`]];\n }\n})(({\n theme,\n ownerState\n}) => _extends({\n backgroundColor: theme.vars ? theme.vars.palette.Tooltip.bg : alpha(theme.palette.grey[700], 0.92),\n borderRadius: (theme.vars || theme).shape.borderRadius,\n color: (theme.vars || theme).palette.common.white,\n fontFamily: theme.typography.fontFamily,\n padding: '4px 8px',\n fontSize: theme.typography.pxToRem(11),\n maxWidth: 300,\n margin: 2,\n wordWrap: 'break-word',\n fontWeight: theme.typography.fontWeightMedium\n}, ownerState.arrow && {\n position: 'relative',\n margin: 0\n}, ownerState.touch && {\n padding: '8px 16px',\n fontSize: theme.typography.pxToRem(14),\n lineHeight: `${round(16 / 14)}em`,\n fontWeight: theme.typography.fontWeightRegular\n}, {\n [`.${tooltipClasses.popper}[data-popper-placement*=\"left\"] &`]: _extends({\n transformOrigin: 'right center'\n }, !ownerState.isRtl ? _extends({\n marginRight: '14px'\n }, ownerState.touch && {\n marginRight: '24px'\n }) : _extends({\n marginLeft: '14px'\n }, ownerState.touch && {\n marginLeft: '24px'\n })),\n [`.${tooltipClasses.popper}[data-popper-placement*=\"right\"] &`]: _extends({\n transformOrigin: 'left center'\n }, !ownerState.isRtl ? _extends({\n marginLeft: '14px'\n }, ownerState.touch && {\n marginLeft: '24px'\n }) : _extends({\n marginRight: '14px'\n }, ownerState.touch && {\n marginRight: '24px'\n })),\n [`.${tooltipClasses.popper}[data-popper-placement*=\"top\"] &`]: _extends({\n transformOrigin: 'center bottom',\n marginBottom: '14px'\n }, ownerState.touch && {\n marginBottom: '24px'\n }),\n [`.${tooltipClasses.popper}[data-popper-placement*=\"bottom\"] &`]: _extends({\n transformOrigin: 'center top',\n marginTop: '14px'\n }, ownerState.touch && {\n marginTop: '24px'\n })\n}));\nconst TooltipArrow = styled('span', {\n name: 'MuiTooltip',\n slot: 'Arrow',\n overridesResolver: (props, styles) => styles.arrow\n})(({\n theme\n}) => ({\n overflow: 'hidden',\n position: 'absolute',\n width: '1em',\n height: '0.71em' /* = width / sqrt(2) = (length of the hypotenuse) */,\n boxSizing: 'border-box',\n color: theme.vars ? theme.vars.palette.Tooltip.bg : alpha(theme.palette.grey[700], 0.9),\n '&::before': {\n content: '\"\"',\n margin: 'auto',\n display: 'block',\n width: '100%',\n height: '100%',\n backgroundColor: 'currentColor',\n transform: 'rotate(45deg)'\n }\n}));\nlet hystersisOpen = false;\nconst hystersisTimer = new Timeout();\nlet cursorPosition = {\n x: 0,\n y: 0\n};\nexport function testReset() {\n hystersisOpen = false;\n hystersisTimer.clear();\n}\nfunction composeEventHandler(handler, eventHandler) {\n return event => {\n if (eventHandler) {\n eventHandler(event);\n }\n handler(event);\n };\n}\n\n// TODO v6: Remove PopperComponent, PopperProps, TransitionComponent and TransitionProps.\nconst Tooltip = /*#__PURE__*/React.forwardRef(function Tooltip(inProps, ref) {\n var _ref, _slots$popper, _ref2, _ref3, _slots$transition, _ref4, _slots$tooltip, _ref5, _slots$arrow, _slotProps$popper, _ref6, _slotProps$popper2, _slotProps$transition, _slotProps$tooltip, _ref7, _slotProps$tooltip2, _slotProps$arrow, _ref8, _slotProps$arrow2;\n const props = useThemeProps({\n props: inProps,\n name: 'MuiTooltip'\n });\n const {\n arrow = false,\n children: childrenProp,\n components = {},\n componentsProps = {},\n describeChild = false,\n disableFocusListener = false,\n disableHoverListener = false,\n disableInteractive: disableInteractiveProp = false,\n disableTouchListener = false,\n enterDelay = 100,\n enterNextDelay = 0,\n enterTouchDelay = 700,\n followCursor = false,\n id: idProp,\n leaveDelay = 0,\n leaveTouchDelay = 1500,\n onClose,\n onOpen,\n open: openProp,\n placement = 'bottom',\n PopperComponent: PopperComponentProp,\n PopperProps = {},\n slotProps = {},\n slots = {},\n title,\n TransitionComponent: TransitionComponentProp = Grow,\n TransitionProps\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n\n // to prevent runtime errors, developers will need to provide a child as a React element anyway.\n const children = /*#__PURE__*/React.isValidElement(childrenProp) ? childrenProp : /*#__PURE__*/_jsx(\"span\", {\n children: childrenProp\n });\n const theme = useTheme();\n const isRtl = theme.direction === 'rtl';\n const [childNode, setChildNode] = React.useState();\n const [arrowRef, setArrowRef] = React.useState(null);\n const ignoreNonTouchEvents = React.useRef(false);\n const disableInteractive = disableInteractiveProp || followCursor;\n const closeTimer = useTimeout();\n const enterTimer = useTimeout();\n const leaveTimer = useTimeout();\n const touchTimer = useTimeout();\n const [openState, setOpenState] = useControlled({\n controlled: openProp,\n default: false,\n name: 'Tooltip',\n state: 'open'\n });\n let open = openState;\n if (process.env.NODE_ENV !== 'production') {\n // eslint-disable-next-line react-hooks/rules-of-hooks\n const {\n current: isControlled\n } = React.useRef(openProp !== undefined);\n\n // eslint-disable-next-line react-hooks/rules-of-hooks\n React.useEffect(() => {\n if (childNode && childNode.disabled && !isControlled && title !== '' && childNode.tagName.toLowerCase() === 'button') {\n console.error(['MUI: You are providing a disabled `button` child to the Tooltip component.', 'A disabled element does not fire events.', \"Tooltip needs to listen to the child element's events to display the title.\", '', 'Add a simple wrapper element, such as a `span`.'].join('\\n'));\n }\n }, [title, childNode, isControlled]);\n }\n const id = useId(idProp);\n const prevUserSelect = React.useRef();\n const stopTouchInteraction = useEventCallback(() => {\n if (prevUserSelect.current !== undefined) {\n document.body.style.WebkitUserSelect = prevUserSelect.current;\n prevUserSelect.current = undefined;\n }\n touchTimer.clear();\n });\n React.useEffect(() => stopTouchInteraction, [stopTouchInteraction]);\n const handleOpen = event => {\n hystersisTimer.clear();\n hystersisOpen = true;\n\n // The mouseover event will trigger for every nested element in the tooltip.\n // We can skip rerendering when the tooltip is already open.\n // We are using the mouseover event instead of the mouseenter event to fix a hide/show issue.\n setOpenState(true);\n if (onOpen && !open) {\n onOpen(event);\n }\n };\n const handleClose = useEventCallback(\n /**\n * @param {React.SyntheticEvent | Event} event\n */\n event => {\n hystersisTimer.start(800 + leaveDelay, () => {\n hystersisOpen = false;\n });\n setOpenState(false);\n if (onClose && open) {\n onClose(event);\n }\n closeTimer.start(theme.transitions.duration.shortest, () => {\n ignoreNonTouchEvents.current = false;\n });\n });\n const handleEnter = event => {\n if (ignoreNonTouchEvents.current && event.type !== 'touchstart') {\n return;\n }\n\n // Remove the title ahead of time.\n // We don't want to wait for the next render commit.\n // We would risk displaying two tooltips at the same time (native + this one).\n if (childNode) {\n childNode.removeAttribute('title');\n }\n enterTimer.clear();\n leaveTimer.clear();\n if (enterDelay || hystersisOpen && enterNextDelay) {\n enterTimer.start(hystersisOpen ? enterNextDelay : enterDelay, () => {\n handleOpen(event);\n });\n } else {\n handleOpen(event);\n }\n };\n const handleLeave = event => {\n enterTimer.clear();\n leaveTimer.start(leaveDelay, () => {\n handleClose(event);\n });\n };\n const {\n isFocusVisibleRef,\n onBlur: handleBlurVisible,\n onFocus: handleFocusVisible,\n ref: focusVisibleRef\n } = useIsFocusVisible();\n // We don't necessarily care about the focusVisible state (which is safe to access via ref anyway).\n // We just need to re-render the Tooltip if the focus-visible state changes.\n const [, setChildIsFocusVisible] = React.useState(false);\n const handleBlur = event => {\n handleBlurVisible(event);\n if (isFocusVisibleRef.current === false) {\n setChildIsFocusVisible(false);\n handleLeave(event);\n }\n };\n const handleFocus = event => {\n // Workaround for https://github.com/facebook/react/issues/7769\n // The autoFocus of React might trigger the event before the componentDidMount.\n // We need to account for this eventuality.\n if (!childNode) {\n setChildNode(event.currentTarget);\n }\n handleFocusVisible(event);\n if (isFocusVisibleRef.current === true) {\n setChildIsFocusVisible(true);\n handleEnter(event);\n }\n };\n const detectTouchStart = event => {\n ignoreNonTouchEvents.current = true;\n const childrenProps = children.props;\n if (childrenProps.onTouchStart) {\n childrenProps.onTouchStart(event);\n }\n };\n const handleMouseOver = handleEnter;\n const handleMouseLeave = handleLeave;\n const handleTouchStart = event => {\n detectTouchStart(event);\n leaveTimer.clear();\n closeTimer.clear();\n stopTouchInteraction();\n prevUserSelect.current = document.body.style.WebkitUserSelect;\n // Prevent iOS text selection on long-tap.\n document.body.style.WebkitUserSelect = 'none';\n touchTimer.start(enterTouchDelay, () => {\n document.body.style.WebkitUserSelect = prevUserSelect.current;\n handleEnter(event);\n });\n };\n const handleTouchEnd = event => {\n if (children.props.onTouchEnd) {\n children.props.onTouchEnd(event);\n }\n stopTouchInteraction();\n leaveTimer.start(leaveTouchDelay, () => {\n handleClose(event);\n });\n };\n React.useEffect(() => {\n if (!open) {\n return undefined;\n }\n\n /**\n * @param {KeyboardEvent} nativeEvent\n */\n function handleKeyDown(nativeEvent) {\n // IE11, Edge (prior to using Bink?) use 'Esc'\n if (nativeEvent.key === 'Escape' || nativeEvent.key === 'Esc') {\n handleClose(nativeEvent);\n }\n }\n document.addEventListener('keydown', handleKeyDown);\n return () => {\n document.removeEventListener('keydown', handleKeyDown);\n };\n }, [handleClose, open]);\n const handleRef = useForkRef(children.ref, focusVisibleRef, setChildNode, ref);\n\n // There is no point in displaying an empty tooltip.\n // So we exclude all falsy values, except 0, which is valid.\n if (!title && title !== 0) {\n open = false;\n }\n const popperRef = React.useRef();\n const handleMouseMove = event => {\n const childrenProps = children.props;\n if (childrenProps.onMouseMove) {\n childrenProps.onMouseMove(event);\n }\n cursorPosition = {\n x: event.clientX,\n y: event.clientY\n };\n if (popperRef.current) {\n popperRef.current.update();\n }\n };\n const nameOrDescProps = {};\n const titleIsString = typeof title === 'string';\n if (describeChild) {\n nameOrDescProps.title = !open && titleIsString && !disableHoverListener ? title : null;\n nameOrDescProps['aria-describedby'] = open ? id : null;\n } else {\n nameOrDescProps['aria-label'] = titleIsString ? title : null;\n nameOrDescProps['aria-labelledby'] = open && !titleIsString ? id : null;\n }\n const childrenProps = _extends({}, nameOrDescProps, other, children.props, {\n className: clsx(other.className, children.props.className),\n onTouchStart: detectTouchStart,\n ref: handleRef\n }, followCursor ? {\n onMouseMove: handleMouseMove\n } : {});\n if (process.env.NODE_ENV !== 'production') {\n childrenProps['data-mui-internal-clone-element'] = true;\n\n // eslint-disable-next-line react-hooks/rules-of-hooks\n React.useEffect(() => {\n if (childNode && !childNode.getAttribute('data-mui-internal-clone-element')) {\n console.error(['MUI: The `children` component of the Tooltip is not forwarding its props correctly.', 'Please make sure that props are spread on the same element that the ref is applied to.'].join('\\n'));\n }\n }, [childNode]);\n }\n const interactiveWrapperListeners = {};\n if (!disableTouchListener) {\n childrenProps.onTouchStart = handleTouchStart;\n childrenProps.onTouchEnd = handleTouchEnd;\n }\n if (!disableHoverListener) {\n childrenProps.onMouseOver = composeEventHandler(handleMouseOver, childrenProps.onMouseOver);\n childrenProps.onMouseLeave = composeEventHandler(handleMouseLeave, childrenProps.onMouseLeave);\n if (!disableInteractive) {\n interactiveWrapperListeners.onMouseOver = handleMouseOver;\n interactiveWrapperListeners.onMouseLeave = handleMouseLeave;\n }\n }\n if (!disableFocusListener) {\n childrenProps.onFocus = composeEventHandler(handleFocus, childrenProps.onFocus);\n childrenProps.onBlur = composeEventHandler(handleBlur, childrenProps.onBlur);\n if (!disableInteractive) {\n interactiveWrapperListeners.onFocus = handleFocus;\n interactiveWrapperListeners.onBlur = handleBlur;\n }\n }\n if (process.env.NODE_ENV !== 'production') {\n if (children.props.title) {\n console.error(['MUI: You have provided a `title` prop to the child of .', `Remove this title prop \\`${children.props.title}\\` or the Tooltip component.`].join('\\n'));\n }\n }\n const popperOptions = React.useMemo(() => {\n var _PopperProps$popperOp;\n let tooltipModifiers = [{\n name: 'arrow',\n enabled: Boolean(arrowRef),\n options: {\n element: arrowRef,\n padding: 4\n }\n }];\n if ((_PopperProps$popperOp = PopperProps.popperOptions) != null && _PopperProps$popperOp.modifiers) {\n tooltipModifiers = tooltipModifiers.concat(PopperProps.popperOptions.modifiers);\n }\n return _extends({}, PopperProps.popperOptions, {\n modifiers: tooltipModifiers\n });\n }, [arrowRef, PopperProps]);\n const ownerState = _extends({}, props, {\n isRtl,\n arrow,\n disableInteractive,\n placement,\n PopperComponentProp,\n touch: ignoreNonTouchEvents.current\n });\n const classes = useUtilityClasses(ownerState);\n const PopperComponent = (_ref = (_slots$popper = slots.popper) != null ? _slots$popper : components.Popper) != null ? _ref : TooltipPopper;\n const TransitionComponent = (_ref2 = (_ref3 = (_slots$transition = slots.transition) != null ? _slots$transition : components.Transition) != null ? _ref3 : TransitionComponentProp) != null ? _ref2 : Grow;\n const TooltipComponent = (_ref4 = (_slots$tooltip = slots.tooltip) != null ? _slots$tooltip : components.Tooltip) != null ? _ref4 : TooltipTooltip;\n const ArrowComponent = (_ref5 = (_slots$arrow = slots.arrow) != null ? _slots$arrow : components.Arrow) != null ? _ref5 : TooltipArrow;\n const popperProps = appendOwnerState(PopperComponent, _extends({}, PopperProps, (_slotProps$popper = slotProps.popper) != null ? _slotProps$popper : componentsProps.popper, {\n className: clsx(classes.popper, PopperProps == null ? void 0 : PopperProps.className, (_ref6 = (_slotProps$popper2 = slotProps.popper) != null ? _slotProps$popper2 : componentsProps.popper) == null ? void 0 : _ref6.className)\n }), ownerState);\n const transitionProps = appendOwnerState(TransitionComponent, _extends({}, TransitionProps, (_slotProps$transition = slotProps.transition) != null ? _slotProps$transition : componentsProps.transition), ownerState);\n const tooltipProps = appendOwnerState(TooltipComponent, _extends({}, (_slotProps$tooltip = slotProps.tooltip) != null ? _slotProps$tooltip : componentsProps.tooltip, {\n className: clsx(classes.tooltip, (_ref7 = (_slotProps$tooltip2 = slotProps.tooltip) != null ? _slotProps$tooltip2 : componentsProps.tooltip) == null ? void 0 : _ref7.className)\n }), ownerState);\n const tooltipArrowProps = appendOwnerState(ArrowComponent, _extends({}, (_slotProps$arrow = slotProps.arrow) != null ? _slotProps$arrow : componentsProps.arrow, {\n className: clsx(classes.arrow, (_ref8 = (_slotProps$arrow2 = slotProps.arrow) != null ? _slotProps$arrow2 : componentsProps.arrow) == null ? void 0 : _ref8.className)\n }), ownerState);\n return /*#__PURE__*/_jsxs(React.Fragment, {\n children: [/*#__PURE__*/React.cloneElement(children, childrenProps), /*#__PURE__*/_jsx(PopperComponent, _extends({\n as: PopperComponentProp != null ? PopperComponentProp : Popper,\n placement: placement,\n anchorEl: followCursor ? {\n getBoundingClientRect: () => ({\n top: cursorPosition.y,\n left: cursorPosition.x,\n right: cursorPosition.x,\n bottom: cursorPosition.y,\n width: 0,\n height: 0\n })\n } : childNode,\n popperRef: popperRef,\n open: childNode ? open : false,\n id: id,\n transition: true\n }, interactiveWrapperListeners, popperProps, {\n popperOptions: popperOptions,\n children: ({\n TransitionProps: TransitionPropsInner\n }) => /*#__PURE__*/_jsx(TransitionComponent, _extends({\n timeout: theme.transitions.duration.shorter\n }, TransitionPropsInner, transitionProps, {\n children: /*#__PURE__*/_jsxs(TooltipComponent, _extends({}, tooltipProps, {\n children: [title, arrow ? /*#__PURE__*/_jsx(ArrowComponent, _extends({}, tooltipArrowProps, {\n ref: setArrowRef\n })) : null]\n }))\n }))\n }))]\n });\n});\nprocess.env.NODE_ENV !== \"production\" ? Tooltip.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the d.ts file and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * If `true`, adds an arrow to the tooltip.\n * @default false\n */\n arrow: PropTypes.bool,\n /**\n * Tooltip reference element.\n */\n children: elementAcceptingRef.isRequired,\n /**\n * Override or extend the styles applied to the component.\n */\n classes: PropTypes.object,\n /**\n * @ignore\n */\n className: PropTypes.string,\n /**\n * The components used for each slot inside.\n *\n * This prop is an alias for the `slots` prop.\n * It's recommended to use the `slots` prop instead.\n *\n * @default {}\n */\n components: PropTypes.shape({\n Arrow: PropTypes.elementType,\n Popper: PropTypes.elementType,\n Tooltip: PropTypes.elementType,\n Transition: PropTypes.elementType\n }),\n /**\n * The extra props for the slot components.\n * You can override the existing props or add new ones.\n *\n * This prop is an alias for the `slotProps` prop.\n * It's recommended to use the `slotProps` prop instead, as `componentsProps` will be deprecated in the future.\n *\n * @default {}\n */\n componentsProps: PropTypes.shape({\n arrow: PropTypes.object,\n popper: PropTypes.object,\n tooltip: PropTypes.object,\n transition: PropTypes.object\n }),\n /**\n * Set to `true` if the `title` acts as an accessible description.\n * By default the `title` acts as an accessible label for the child.\n * @default false\n */\n describeChild: PropTypes.bool,\n /**\n * Do not respond to focus-visible events.\n * @default false\n */\n disableFocusListener: PropTypes.bool,\n /**\n * Do not respond to hover events.\n * @default false\n */\n disableHoverListener: PropTypes.bool,\n /**\n * Makes a tooltip not interactive, i.e. it will close when the user\n * hovers over the tooltip before the `leaveDelay` is expired.\n * @default false\n */\n disableInteractive: PropTypes.bool,\n /**\n * Do not respond to long press touch events.\n * @default false\n */\n disableTouchListener: PropTypes.bool,\n /**\n * The number of milliseconds to wait before showing the tooltip.\n * This prop won't impact the enter touch delay (`enterTouchDelay`).\n * @default 100\n */\n enterDelay: PropTypes.number,\n /**\n * The number of milliseconds to wait before showing the tooltip when one was already recently opened.\n * @default 0\n */\n enterNextDelay: PropTypes.number,\n /**\n * The number of milliseconds a user must touch the element before showing the tooltip.\n * @default 700\n */\n enterTouchDelay: PropTypes.number,\n /**\n * If `true`, the tooltip follow the cursor over the wrapped element.\n * @default false\n */\n followCursor: PropTypes.bool,\n /**\n * This prop is used to help implement the accessibility logic.\n * If you don't provide this prop. It falls back to a randomly generated id.\n */\n id: PropTypes.string,\n /**\n * The number of milliseconds to wait before hiding the tooltip.\n * This prop won't impact the leave touch delay (`leaveTouchDelay`).\n * @default 0\n */\n leaveDelay: PropTypes.number,\n /**\n * The number of milliseconds after the user stops touching an element before hiding the tooltip.\n * @default 1500\n */\n leaveTouchDelay: PropTypes.number,\n /**\n * Callback fired when the component requests to be closed.\n *\n * @param {React.SyntheticEvent} event The event source of the callback.\n */\n onClose: PropTypes.func,\n /**\n * Callback fired when the component requests to be open.\n *\n * @param {React.SyntheticEvent} event The event source of the callback.\n */\n onOpen: PropTypes.func,\n /**\n * If `true`, the component is shown.\n */\n open: PropTypes.bool,\n /**\n * Tooltip placement.\n * @default 'bottom'\n */\n placement: PropTypes.oneOf(['bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n /**\n * The component used for the popper.\n * @default Popper\n */\n PopperComponent: PropTypes.elementType,\n /**\n * Props applied to the [`Popper`](/material-ui/api/popper/) element.\n * @default {}\n */\n PopperProps: PropTypes.object,\n /**\n * The extra props for the slot components.\n * You can override the existing props or add new ones.\n *\n * This prop is an alias for the `componentsProps` prop, which will be deprecated in the future.\n *\n * @default {}\n */\n slotProps: PropTypes.shape({\n arrow: PropTypes.object,\n popper: PropTypes.object,\n tooltip: PropTypes.object,\n transition: PropTypes.object\n }),\n /**\n * The components used for each slot inside.\n *\n * This prop is an alias for the `components` prop, which will be deprecated in the future.\n *\n * @default {}\n */\n slots: PropTypes.shape({\n arrow: PropTypes.elementType,\n popper: PropTypes.elementType,\n tooltip: PropTypes.elementType,\n transition: PropTypes.elementType\n }),\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Tooltip title. Zero-length titles string, undefined, null and false are never displayed.\n */\n title: PropTypes.node,\n /**\n * The component used for the transition.\n * [Follow this guide](/material-ui/transitions/#transitioncomponent-prop) to learn more about the requirements for this component.\n * @default Grow\n */\n TransitionComponent: PropTypes.elementType,\n /**\n * Props applied to the transition element.\n * By default, the element is based on this [`Transition`](http://reactcommunity.org/react-transition-group/transition/) component.\n */\n TransitionProps: PropTypes.object\n} : void 0;\nexport default Tooltip;","import '@/components/mui/menu-item.component.css';\nimport ArrowRightIcon from '@mui/icons-material/ArrowRight';\nimport {\n ListItemIcon as MuiListItemIcon,\n ListItemText as MuiListItemText,\n MenuItem as MuiMenuItem,\n} from '@mui/material';\nimport Tooltip from '@mui/material/Tooltip';\nimport { Localized, ReferencedItem, SingleColumnMenu } from 'platform-bible-utils';\nimport { MouseEvent, PropsWithChildren } from 'react';\n\ntype MenuItemInfoBase = {\n /** Text (displayable in the UI) as the name of the menu item */\n label: string;\n /** Text to display when the mouse hovers over the menu item */\n tooltip?: string;\n};\n\nexport type Command = MenuItemInfoBase & {\n /** Command to execute (string.string) */\n command: string;\n};\n\ntype SubMenu = MenuItemInfoBase & {\n /** Command to execute (string.string) */\n items: MenuItemInfo[];\n};\n\nexport interface CommandHandler {\n (command: Command): void;\n}\n\nexport type MenuPropsBase = {\n /*\n * The JSON defining the menu whose items are to be rendered. This will typically be one of the\n * menus in the \"defs\" in a Platform.Bible menu (see PlatformMenus). The schema for this is\n * menuDocumentSchema (at the end of menus.model.ts). Note that while this is a\n * \"SingleColumnMenu\", somewhat bizarrely, a MultiColumnMenu is a SingleColumnMenu, so it really\n * could be a MultiColumnMenu, in which case, column had better be defined so it can be used\n * to filter out the actual groups and items to display on the column.\n */\n menuDefinition: Localized;\n\n commandHandler: CommandHandler;\n\n /**\n * Additional action to perform when any menu item is clicked. Allows the caller to handle event\n * (e.g., to close the menu).\n */\n onClick?: (event: MouseEvent) => void;\n};\n\nexport type MenuItemListProps = MenuPropsBase & {\n /** Optional unique (column) identifier */\n columnId?: ReferencedItem;\n};\n\nexport type MenuItemProps = Omit &\n PropsWithChildren<{\n /** Optional unique identifier */\n id?: string;\n\n onClick: (event: MouseEvent) => void;\n }>;\n\ntype MenuItemInfo = (Command | SubMenu) & {\n /**\n * If specified, menu item will be inset if it does not have a leading icon.\n *\n * @default true\n */\n allowForLeadingIcons?: boolean;\n /**\n * If specified, the path to the icon image to display on the leading side of the menu text.\n *\n * @default undefined (no leading icon will be shown)\n */\n iconPathBefore?: string;\n /**\n * If specified, the path to the icon image to display on the trailing side of the menu text.\n *\n * @default undefined (no trailing icon will be shown)\n */\n iconPathAfter?: string;\n /**\n * If true, list item is focused during the first mount\n *\n * @default false\n */\n hasAutoFocus?: boolean;\n\n /** Additional css classes to help with unique styling of the menu item */\n className?: string;\n\n /**\n * If true, the menu item will appear disabled and it will not respond to clicks or mouse hovers.\n *\n * @default false\n */\n isDisabled?: boolean;\n\n /**\n * If true, compact vertical padding designed for keyboard and mouse input is used.\n *\n * @default true\n */\n isDense?: boolean;\n\n /**\n * If true, a right-arrow icon will be displayed (iconPathAfter, if specified, will be ignored).\n *\n * @default false\n */\n isSubMenuParent?: boolean;\n\n /**\n * If true, the left and right padding is removed\n *\n * @default false\n */\n hasDisabledGutters?: boolean;\n\n /**\n * If true, a 1px light border is added to bottom of menu item\n *\n * @default false\n */\n hasDivider?: boolean;\n\n /** Help identify which element has keyboard focus */\n focusVisibleClassName?: string;\n\n /** If it's a submenu, it should have the items property */\n items?: MenuItemInfo[];\n};\n\nfunction getIcon(icon: string | undefined, menuLabel: string, leading: boolean) {\n return icon ? (\n \n {`${leading\n \n ) : undefined;\n}\n\nexport default function MenuItem(props: MenuItemProps) {\n const {\n onClick,\n label,\n tooltip,\n allowForLeadingIcons = true,\n iconPathBefore = undefined,\n iconPathAfter = undefined,\n hasAutoFocus = false,\n className,\n isDisabled = false,\n isDense = true,\n isSubMenuParent = false,\n hasDisabledGutters = false,\n hasDivider = false,\n focusVisibleClassName,\n id,\n children,\n } = props;\n\n const menuItem = (\n \n {label ? (\n <>\n {getIcon(iconPathBefore, label, true)}\n \n {isSubMenuParent ? (\n \n \n \n ) : (\n getIcon(iconPathAfter, label, false)\n )}\n \n ) : (\n children\n )}\n \n );\n\n return tooltip ? (\n \n
    {menuItem}
    \n
    \n ) : (\n menuItem\n );\n}\n","import MenuItem, {\n MenuItemListProps,\n MenuItemProps,\n MenuPropsBase,\n} from '@/components/mui/menu-item.component';\nimport { Menu } from '@mui/material';\nimport {\n Localized,\n MenuGroupDetailsInSubMenu,\n MenuItemContainingCommand,\n MenuItemContainingSubmenu,\n OrderedExtensibleContainer,\n ReferencedItem,\n SingleColumnMenu,\n} from 'platform-bible-utils';\nimport { MouseEvent, useMemo, useState } from 'react';\n\n/**\n * All the exported types in this file should be regarded as \"internal\" (i.e., they should not be\n * exposed via index.ts).\n */\n\nexport type GroupedMenuPropsBase = MenuPropsBase & {\n /** Optional unique (column) identifier */\n columnId?: ReferencedItem;\n};\n\nexport type GroupedMenuItemListProps = MenuItemListProps & {\n /**\n * If the menuDefinition includes \"top-level\" groups (i.e., those that belong to a column as\n * opposed to those that belong to a submenu) that should not be included in the list, then this\n * array specifies which groups to include. Likewise, for a submenu, this list indicates which\n * groups are pertinent for that submenu. So then for a context menu this property need not be\n * specified since it is a top-level menu based on a \"true\" SingleColumnMenu (i.e., one that is\n * not a MultiColumnMenu).\n */\n includedGroups?: {\n id: string;\n group: Localized;\n }[];\n};\n\ninterface ItemInfo {\n item: Localized;\n isLastItemInGroup: boolean;\n}\n\ntype SubMenuProps = MenuPropsBase & {\n parentMenuItem: Localized;\n parentItemProps: Omit, 'iconPathAfter'>;\n};\n\nfunction getAllGroups(menuDefinition: Localized) {\n const groupEntries = Object.entries(menuDefinition.groups);\n // Convert array of entries to array of objects with id and group properties\n return groupEntries.map(([key, value]) => ({ id: key, group: value }));\n}\n\nfunction SubMenu(props: SubMenuProps) {\n const [anchorEl, setAnchorEl] = useState(undefined);\n\n const { parentMenuItem, parentItemProps, menuDefinition } = props;\n\n const handleParentMenuItemClick = (event: MouseEvent) => {\n setAnchorEl(event.currentTarget);\n };\n\n const handleClose = () => {\n setAnchorEl(undefined);\n };\n\n const renderSubMenuItems = () => {\n let includedGroups = getAllGroups(menuDefinition).filter((g) => 'menuItem' in g.group);\n\n // Ensure valid parent menu was provided. (If not, submenu will contain all groups!)\n if (!parentMenuItem?.id) throw new Error('A valid parent menu item is required for submenus.');\n\n // When laying out a submenu, only include groups associated with the provided parent menu.\n // Note: without the (annoying) redundant check that the included groups\n // have the menuItem field, TS doesn't think it exists.\n includedGroups = includedGroups.filter(\n (group) => 'menuItem' in group.group && group.group.menuItem === parentMenuItem.id,\n );\n\n return ;\n };\n\n return (\n <>\n \n \n {renderSubMenuItems()}\n \n \n );\n}\n\nconst getOrderedGroupItems = (\n groupId: string,\n allItems: Localized[],\n) => {\n // Filter items that belong to the specified group\n const itemsForGroup = allItems.filter((item) => item.group === groupId);\n // Sort items based on order\n const sortedItems = itemsForGroup.sort((a, b) => (a.order || 0) - (b.order || 0));\n return sortedItems;\n};\n\n/**\n * This component is internal; it does not need to be exposed to the outside world since it is not\n * useful on its own. It is used to generate and lay out the MenuItems that appear either on a\n * top-level menu (in a GridMenu or ContextMenu) or in a submenu.\n */\nexport default function GroupedMenuItemList(menuProps: GroupedMenuItemListProps) {\n const { menuDefinition, onClick, commandHandler, includedGroups } = menuProps;\n\n const { items, allowForLeadingIcons } = useMemo(() => {\n const groupsToInclude =\n includedGroups && includedGroups.length > 0\n ? includedGroups\n : // We're apparently laying out a single-column menu (presumably a context menu). In this\n // case, all groups should be included except ones that belong to a submenu.\n getAllGroups(menuDefinition).filter((g) => !('menuItem' in g.group));\n\n const sortedGroups = Object.values(groupsToInclude).sort(\n (a, b) => (a.group.order || 0) - (b.group.order || 0),\n );\n\n const itemArray: ItemInfo[] = [];\n\n sortedGroups.forEach((group) => {\n getOrderedGroupItems(group.id, menuDefinition.items).forEach((item) =>\n itemArray.push({ item, isLastItemInGroup: false }),\n );\n if (itemArray.length > 0) itemArray[itemArray.length - 1].isLastItemInGroup = true;\n });\n\n // No divider after last item in final group.\n if (itemArray.length > 0) itemArray[itemArray.length - 1].isLastItemInGroup = false;\n\n const allowSpaceForLeadingIcons = itemArray.some(\n (i) => 'iconPathBefore' in i.item && i.item.iconPathBefore,\n );\n\n return { items: itemArray, allowForLeadingIcons: allowSpaceForLeadingIcons };\n }, [includedGroups, menuDefinition]);\n\n // Create props for MenuItem component including setting hasDivider for the last item in a group\n const createMenuItemProps = ({ item, isLastItemInGroup }: ItemInfo) => {\n const menuItemProps = {\n className: 'papi-menu-item',\n label: item.label,\n tooltip: item.tooltip,\n iconPathBefore: 'iconPathBefore' in item ? item.iconPathBefore : undefined,\n iconPathAfter: 'iconPathAfter' in item ? item.iconPathAfter : undefined,\n hasDivider: isLastItemInGroup, // Set hasDivider to true for the last item in a group\n allowForLeadingIcons,\n };\n\n return menuItemProps;\n };\n\n const [firstItem] = items;\n\n if (!firstItem) return
    ;\n\n const divKey = firstItem.item.group;\n\n return (\n
    \n {items.map((itemInfo, index) => {\n const { item } = itemInfo;\n const menuItemProps = createMenuItemProps(itemInfo);\n if ('command' in item) {\n const key = item.group + index;\n return (\n ) => {\n onClick?.(event);\n commandHandler(item);\n }}\n {...menuItemProps}\n />\n );\n }\n return (\n \n );\n })}\n
    \n );\n}\n","import GroupedMenuItemList from '@/components/mui/grouped-menu-item-list.component';\nimport { MenuItemListProps } from '@/components/mui/menu-item.component';\nimport { MultiColumnMenu } from 'platform-bible-utils';\n\n/**\n * This component is internal; it does not need to be exposed to the outside world since it is not\n * useful on its own. Use either GridMenu or ContextMenu.\n */\nexport default function TopLevelMenu(props: MenuItemListProps) {\n const { menuDefinition, columnId } = props;\n\n const groupEntries = Object.entries(menuDefinition.groups);\n // Convert array of entries to array of objects with id and group properties\n const groups = groupEntries.map(([key, value]) => ({ id: key, group: value }));\n let includedGroups = groups.filter((g) => 'column' in g.group);\n\n // Check if column is provided and menuDefinition is a MultiColumnMenu\n if (\n columnId &&\n 'columns' in menuDefinition &&\n // Without this type assertion, TS doesn't know what columns is.\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n (menuDefinition as MultiColumnMenu).columns[columnId]\n ) {\n // When laying out a single column in a MultiColumnMenu, only include groups associated with\n // the provided column. Note: without the (annoying) redundant check that the included groups\n // have the colum field, TS doesn't think it exists.\n includedGroups = includedGroups.filter(\n (g) => 'column' in g.group && g.group.column === columnId,\n );\n }\n\n return ;\n}\n","import '@/components/mui/grid-menu.component.css';\nimport { GroupedMenuPropsBase } from '@/components/mui/grouped-menu-item-list.component';\nimport { CommandHandler } from '@/components/mui/menu-item.component';\nimport TopLevelMenu from '@/components/mui/top-level-menu.component';\nimport { Grid, List } from '@mui/material';\nimport {\n Localized,\n MenuColumnWithHeader,\n MultiColumnMenu,\n ReferencedItem,\n} from 'platform-bible-utils';\nimport { useMemo } from 'react';\n\ntype ColumnInfo = {\n /*\n * The ID (`${string}.${string}`) of a specific menu column.\n */\n id: ReferencedItem;\n\n /*\n * Metadata (label, order, etc.) for a specific menu column.\n */\n metadata: Localized;\n};\n\ntype MenuColumnProps = ColumnInfo &\n GroupedMenuPropsBase & {\n /** Additional css classes to help with unique styling of the menu column */\n className?: string;\n };\n\nexport type GridMenuInfo = {\n /** The menu object containing information about the columns, groups, and items to display. */\n multiColumnMenu: Localized;\n};\n\nexport type GridMenuProps = GridMenuInfo & {\n /** Optional unique identifier */\n id?: string;\n\n commandHandler: CommandHandler;\n\n /** Additional css classes to help with unique styling of the grid menu */\n className?: string;\n};\n\nfunction MenuColumn({\n commandHandler,\n menuDefinition,\n id,\n metadata,\n onClick,\n className,\n}: MenuColumnProps) {\n return (\n \n

    \n {metadata.label}\n

    \n {/* It would seem as though this List component were unnecessary, since it only contains one\n thing, but the \"dense\" property does affect the layout of the items (in a way I don't fully\n understand). There might be a better way. */}\n \n \n \n \n );\n}\n\nexport default function GridMenu({\n commandHandler,\n className,\n multiColumnMenu,\n id,\n}: GridMenuProps) {\n const { columns } = multiColumnMenu;\n\n const sortedColumns = useMemo(() => {\n const columnNumbers = new Map();\n Object.getOwnPropertyNames(columns).forEach((columnName: string) => {\n // We know for sure there is a (boolean) property 'isExtensible' that we are not interested in.\n if (columnName === 'isExtensible') return;\n // TS doesn't allow `columnName` above to be a ReferencedItem even though the type says it is\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const columnId = columnName as ReferencedItem;\n const column = columns[columnId];\n // As of right now (and hopefully forever after), all remaining properties of the\n // ColumnsWithHeaders object are columns whose property names are the IDs of the columns.\n // This is an additional (redundant) sanity check. Specifically we're interested in\n // MenuColumnWithHeader objects, which TypeScript now \"knows\" we have, but at runtime all we\n // can check for is that it's an object with a valid numeric order field. That's likely good\n // enough.\n if (\n typeof column === 'object' &&\n typeof column.order === 'number' &&\n !Number.isNaN(column.order)\n )\n columnNumbers.set(column.order, { id: columnId, metadata: column });\n else\n console.warn(\n `Property ${columnName} (${typeof column}) on menu ${id} is not a valid column and is being ignored. This might indicate data corruption`,\n );\n });\n\n // Extract values and sort them based on the 'order' property\n return Array.from(columnNumbers.values()).sort((a, b) => {\n return (a.metadata.order || 0) - (b.metadata.order || 0);\n });\n }, [columns, id]);\n\n // We might need something like this if we need to be able to prevent empty columns\n // sortedColumns.filter((c) => multiColumnMenu.groups.some((g) => 'column' in g && (g as .column)...\n\n return (\n \n {sortedColumns.map((col, index) => (\n \n ))}\n \n );\n}\n","import { useEffect, useRef, useState } from 'react';\n\nexport type UsePromiseOptions = {\n /**\n * Whether to leave the value as the most recent resolved promise value or set it back to\n * defaultValue while running the promise again. Defaults to true\n */\n preserveValue?: boolean;\n};\n\n/** Set up defaults for options for usePromise hook */\nfunction getUsePromiseOptionsDefaults(options: UsePromiseOptions): UsePromiseOptions {\n return {\n preserveValue: true,\n ...options,\n };\n}\n\n/**\n * Awaits a promise and returns a loading value while the promise is unresolved\n *\n * @param promiseFactoryCallback A function that returns the promise to await. If this callback is\n * undefined, the current value will be returned (defaultValue unless it was previously changed\n * and `options.preserveValue` is true), and there will be no loading.\n *\n * WARNING: MUST BE STABLE - const or wrapped in useCallback. The reference must not be updated\n * every render\n * @param defaultValue The initial value to return while first awaiting the promise. If\n * `options.preserveValue` is false, this value is also shown while awaiting the promise on\n * subsequent calls.\n *\n * Note: this parameter is internally assigned to a `ref`, so changing it will not cause any hooks\n * to re-run with its new value. This means that, if the `promiseFactoryCallback` changes and\n * `options.preserveValue` is `false`, the returned value will be set to the current\n * `defaultValue`. However, the returned value will not be updated if`defaultValue` changes.\n * @param options Various options for adjusting how this hook runs the `promiseFactoryCallback`\n *\n * Note: this parameter is internally assigned to a `ref`, so changing it will not cause any hooks\n * to re-run with its new value. However, the latest `options.preserveValue` will always be used\n * appropriately to determine whether to preserve the returned value when changing the\n * `promiseFactoryCallback`\n * @returns `[value, isLoading]`\n *\n * - `value`: the current value for the promise, either the defaultValue or the resolved promise value\n * - `isLoading`: whether the promise is waiting to be resolved\n */\nconst usePromise = (\n promiseFactoryCallback: (() => Promise) | undefined,\n defaultValue: T,\n options: UsePromiseOptions = {},\n): [value: T, isLoading: boolean] => {\n // Use defaultValue as a ref so it doesn't update dependency arrays\n const defaultValueRef = useRef(defaultValue);\n defaultValueRef.current = defaultValue;\n // Use options as a ref so it doesn't update dependency arrays\n const optionsDefaultedRef = useRef(options);\n optionsDefaultedRef.current = getUsePromiseOptionsDefaults(optionsDefaultedRef.current);\n\n const [value, setValue] = useState(() => defaultValueRef.current);\n const [isLoading, setIsLoading] = useState(true);\n useEffect(() => {\n let promiseIsCurrent = true;\n // If a promiseFactoryCallback was provided, we are loading. Otherwise, there is no loading to do\n setIsLoading(!!promiseFactoryCallback);\n (async () => {\n // If there is a callback to run, run it\n if (promiseFactoryCallback) {\n const result = await promiseFactoryCallback();\n // If the promise was not already replaced, update the value\n if (promiseIsCurrent) {\n setValue(() => result);\n setIsLoading(false);\n }\n }\n })();\n\n return () => {\n // Mark this promise as old and not to be used\n promiseIsCurrent = false;\n if (!optionsDefaultedRef.current.preserveValue) setValue(() => defaultValueRef.current);\n };\n }, [promiseFactoryCallback]);\n\n return [value, isLoading];\n};\nexport default usePromise;\n","\"use client\";\n\nimport createSvgIcon from './utils/createSvgIcon';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nexport default createSvgIcon( /*#__PURE__*/_jsx(\"path\", {\n d: \"M3 18h18v-2H3zm0-5h18v-2H3zm0-7v2h18V6z\"\n}), 'Menu');","import GridMenu from '@/components/mui/grid-menu.component';\nimport { Command, CommandHandler } from '@/components/mui/menu-item.component';\nimport usePromise from '@/hooks/use-promise.hook';\nimport { Menu as MenuIcon } from '@mui/icons-material';\nimport { Drawer, IconButton } from '@mui/material';\nimport { Localized, MultiColumnMenu } from 'platform-bible-utils';\nimport {\n MouseEvent,\n MutableRefObject,\n PropsWithChildren,\n useCallback,\n useEffect,\n useState,\n} from 'react';\n\nexport interface MultiColumnMenuProvider {\n (isSupportAndDevelopment: boolean): Promise>;\n}\n\nexport type HamburgerMenuButtonProps = PropsWithChildren & {\n /** The handler to use for menu commands (and eventually toolbar commands). */\n commandHandler: CommandHandler;\n\n /**\n * Optional reference to the \"div\" container that determines the where the menu should appear. If\n * not defined, then (1,1) used.\n */\n containerRef?: MutableRefObject;\n\n /**\n * The delegate to use to get the menu data. If not specified or if it returns undefined, the data\n * in normalMenu or fullMenu property will be used.\n */\n menuProvider?: MultiColumnMenuProvider;\n\n /**\n * The menu data to show when the menu is opened if the menuProvider property is not defined.\n * (This allows for a default or test-only static menu to be used.)\n */\n normalMenu?: Localized;\n\n /**\n * The menu data to show for \"full\" menu (when opened with the SHIFT key pressed) if the\n * menuProvider property is not defined. (This allows for a default or test-only static menu to be\n * used.)\n */\n fullMenu?: Localized;\n\n /** Additional css class(es) to help with unique styling of the sub-components */\n className?: string;\n\n /** Value to use as prefix for ARIA labels on interactive sub-components */\n ariaLabelPrefix?: string;\n};\n\nexport default function HamburgerMenuButton({\n menuProvider,\n normalMenu,\n fullMenu,\n commandHandler,\n containerRef,\n className,\n ariaLabelPrefix,\n children,\n}: HamburgerMenuButtonProps) {\n const [isMenuOpen, setMenuOpen] = useState(false);\n const [showFullMenu, setShowFullMenu] = useState(false);\n\n const handleMenuItemClick = useCallback(() => {\n if (isMenuOpen) setMenuOpen(false);\n setShowFullMenu(false);\n }, [isMenuOpen]);\n\n const handleMenuButtonClick = useCallback((e: MouseEvent) => {\n e.stopPropagation();\n setMenuOpen((prevIsOpen) => {\n const isOpening = !prevIsOpen;\n if (isOpening && e.shiftKey) setShowFullMenu(true);\n else if (!isOpening) setShowFullMenu(false);\n return isOpening;\n });\n }, []);\n\n const menuCommandHandler = useCallback(\n (command: Command) => {\n handleMenuItemClick();\n return commandHandler(command);\n },\n [commandHandler, handleMenuItemClick],\n );\n\n const [offset, setOffset] = useState({ top: 1, left: 1 });\n\n useEffect(() => {\n if (isMenuOpen) {\n const node = containerRef?.current;\n if (node) {\n const rect = node.getBoundingClientRect();\n const scrollTop = window.scrollY;\n const scrollLeft = window.scrollX;\n const top = rect.top + scrollTop + node.clientHeight;\n const left = rect.left + scrollLeft;\n setOffset({ top, left });\n }\n }\n }, [isMenuOpen, containerRef]);\n\n const [normalMenuData] = usePromise(\n useCallback(async () => {\n return menuProvider?.(false) ?? normalMenu;\n // isMenuOpen needs to be included for the menu contents to reevaluate when reopened\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [menuProvider, normalMenu, isMenuOpen]),\n normalMenu,\n );\n\n const [fullMenuData] = usePromise(\n useCallback(async () => {\n return menuProvider?.(true) ?? fullMenu ?? normalMenuData;\n // isMenuOpen needs to be included for the menu contents to reevaluate when reopened\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [menuProvider, fullMenu, normalMenuData, isMenuOpen]),\n fullMenu ?? normalMenuData,\n );\n\n const menu = showFullMenu && fullMenuData ? fullMenuData : normalMenuData;\n\n return (\n <>\n \n {children ?? }\n \n \n {menu ? (\n \n ) : undefined}\n \n \n );\n}\n","import '@/components/mui/icon-button.component.css';\nimport { IconButton as MuiIconButton } from '@mui/material';\nimport { MouseEventHandler, PropsWithChildren } from 'react';\n\nexport type IconButtonProps = PropsWithChildren<{\n /** Optional unique identifier */\n id?: string;\n /**\n * Required. Used as both the tooltip (aka, title) and the aria-label (used for accessibility,\n * testing, etc.), unless a distinct tooltip is supplied.\n */\n label: string;\n /**\n * Enabled status of button\n *\n * @default false\n */\n isDisabled?: boolean;\n /** Optional tooltip to display if different from the aria-label. */\n tooltip?: string;\n /** If true, no tooltip will be displayed. */\n isTooltipSuppressed?: boolean;\n /**\n * If given, uses a negative margin to counteract the padding on one side (this is often helpful\n * for aligning the left or right side of the icon with content above or below, without ruining\n * the border size and shape).\n *\n * @default false\n */\n adjustMarginToAlignToEdge?: 'end' | 'start' | false;\n /**\n * The size of the component. small is equivalent to the dense button styling.\n *\n * @default false\n */\n size: 'small' | 'medium' | 'large';\n /** Additional css classes to help with unique styling of the button */\n className?: string;\n /** Optional click handler */\n onClick?: MouseEventHandler;\n}>;\n\n/**\n * Iconic button a user can click to do something\n *\n * Thanks to MUI for heavy inspiration and documentation\n * https://mui.com/material-ui/getting-started/overview/\n */\nfunction IconButton({\n id,\n label,\n isDisabled = false,\n tooltip,\n isTooltipSuppressed = false,\n adjustMarginToAlignToEdge = false,\n size = 'medium',\n className,\n onClick,\n children,\n}: IconButtonProps) {\n return (\n \n {children /* the icon to display */}\n \n );\n}\n\nexport default IconButton;\n","import { cn } from '@/utils/shadcn-ui.util';\nimport { LoaderCircle, LucideProps } from 'lucide-react';\nimport { forwardRef } from 'react';\n\nexport type SpinnerProps = LucideProps;\n\nconst Spinner = forwardRef(({ className, ...props }, ref) => {\n return (\n \n );\n});\n\nSpinner.displayName = 'Spinner';\n\nexport default Spinner;\n","import { Input as ShadInput } from '@/components/shadcn-ui/input';\nimport { Label as ShadLabel } from '@/components/shadcn-ui/label';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { ChangeEventHandler, FocusEventHandler } from 'react';\n\nexport type TextFieldProps = {\n /** Optional unique identifier */\n id?: string;\n /**\n * If `true`, the component is disabled.\n *\n * @default false\n */\n isDisabled?: boolean;\n /**\n * If `true`, the label is displayed in an error state.\n *\n * @default false\n */\n hasError?: boolean;\n /**\n * If `true`, the input will take up the full width of its container.\n *\n * @default false\n */\n isFullWidth?: boolean;\n /** Text that gives the user instructions on what contents the TextField expects */\n helperText?: string;\n /** The title of the TextField */\n label?: string;\n /** The short hint displayed in the `input` before the user enters a value. */\n placeholder?: string;\n /**\n * If `true`, the label is displayed as required and the `input` element is required.\n *\n * @default false\n */\n isRequired?: boolean;\n /** Additional css classes to help with unique styling of the text field */\n className?: string;\n /** Starting value for the text field if it is not controlled */\n defaultValue?: string | number;\n /** Value of the text field if controlled */\n value?: string | number;\n /** Triggers when content of textfield is changed */\n onChange?: ChangeEventHandler;\n /** Triggers when textfield gets focus */\n onFocus?: FocusEventHandler;\n /** Triggers when textfield loses focus */\n onBlur?: FocusEventHandler;\n};\n\n/**\n * Text input field\n *\n * Thanks to Shadcn for heavy inspiration and documentation\n * https://ui.shadcn.com/docs/components/input#with-label\n */\nfunction TextField({\n id,\n isDisabled = false,\n hasError = false,\n isFullWidth = false,\n helperText,\n label,\n placeholder,\n isRequired = false,\n className,\n defaultValue,\n value,\n onChange,\n onFocus,\n onBlur,\n}: TextFieldProps) {\n return (\n
    \n {`${label}${isRequired ? '*' : ''}`}\n \n

    {helperText}

    \n
    \n );\n}\n\nexport default TextField;\n","import HamburgerMenuButton, {\n MultiColumnMenuProvider,\n} from '@/components/mui/hamburger-menu-button.component';\nimport { CommandHandler } from '@/components/mui/menu-item.component';\nimport '@/components/mui/toolbar.component.css';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { AppBar, Toolbar as MuiToolbar } from '@mui/material';\nimport { PropsWithChildren, useRef } from 'react';\n\nexport type ToolbarProps = PropsWithChildren<{\n /** The handler to use for menu commands (and eventually toolbar commands). */\n commandHandler: CommandHandler;\n\n /**\n * The optional delegate to use to get the menu data. If not specified, the \"hamburger\" menu will\n * not display.\n */\n menuProvider?: MultiColumnMenuProvider;\n\n /** Optional unique identifier */\n id?: string;\n\n /** Additional css classes to help with unique styling of the toolbar */\n className?: string;\n}>;\n\nexport default function Toolbar({\n menuProvider,\n commandHandler,\n className,\n id,\n children,\n}: ToolbarProps) {\n // This ref will always be defined\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const containerRef = useRef(undefined!);\n\n return (\n
    \n \n \n {menuProvider ? (\n \n ) : undefined}\n {children ?
    {children}
    : undefined}\n \n
    \n
    \n );\n}\n","import React from 'react';\nimport { cva, type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst alertVariants = cva(\n 'tw-relative tw-w-full tw-rounded-lg tw-border tw-p-4 [&>svg~*]:tw-pl-7 [&>svg+div]:tw-translate-y-[-3px] [&>svg]:tw-absolute [&>svg]:tw-left-4 [&>svg]:tw-top-4 [&>svg]:tw-text-foreground',\n {\n variants: {\n variant: {\n default: 'tw-bg-background tw-text-foreground',\n destructive:\n 'tw-border-destructive/50 tw-text-destructive dark:tw-border-destructive [&>svg]:tw-text-destructive',\n },\n },\n defaultVariants: {\n variant: 'default',\n },\n },\n);\n\nconst Alert = React.forwardRef<\n HTMLDivElement,\n React.HTMLAttributes & VariantProps\n>(({ className, variant, ...props }, ref) => (\n
    \n));\nAlert.displayName = 'Alert';\n\nconst AlertTitle = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n {/* added because of https://github.com/jsx-eslint/eslint-plugin-jsx-a11y/blob/main/docs/rules/heading-has-content.md */}\n {props.children}{' '}\n \n ),\n);\nAlertTitle.displayName = 'AlertTitle';\n\nconst AlertDescription = React.forwardRef<\n HTMLParagraphElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n
    \n));\nAlertDescription.displayName = 'AlertDescription';\n\nexport { Alert, AlertTitle, AlertDescription };\n","import React from 'react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Card = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nCard.displayName = 'Card';\n\nconst CardHeader = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nCardHeader.displayName = 'CardHeader';\n\nconst CardTitle = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n {/* added because of https://github.com/jsx-eslint/eslint-plugin-jsx-a11y/blob/main/docs/rules/heading-has-content.md */}\n {props.children}\n \n ),\n);\nCardTitle.displayName = 'CardTitle';\n\nconst CardDescription = React.forwardRef<\n HTMLParagraphElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n

    \n));\nCardDescription.displayName = 'CardDescription';\n\nconst CardContent = React.forwardRef>(\n ({ className, ...props }, ref) => (\n

    \n ),\n);\nCardContent.displayName = 'CardContent';\n\nconst CardFooter = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nCardFooter.displayName = 'CardFooter';\n\nexport { Card, CardHeader, CardFooter, CardTitle, CardDescription, CardContent };\n","import { ComponentProps } from 'react';\nimport { toast as sonner, Toaster } from 'sonner';\n\ntype SonnerProps = ComponentProps;\n\nfunction Sonner({ ...props }: SonnerProps) {\n return (\n \n );\n}\n\n// The re-export of the sonner function was added manually\nexport { Sonner, sonner };\n","import React from 'react';\nimport * as SliderPrimitive from '@radix-ui/react-slider';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Slider = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n \n \n \n));\nSlider.displayName = SliderPrimitive.Root.displayName;\n\nexport { Slider };\n","import React from 'react';\nimport * as SwitchPrimitives from '@radix-ui/react-switch';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Switch = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n));\nSwitch.displayName = SwitchPrimitives.Root.displayName;\n\nexport { Switch };\n","import React from 'react';\nimport * as TabsPrimitive from '@radix-ui/react-tabs';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport const Tabs = TabsPrimitive.Root;\n\nexport type TabsListProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport type TabsTriggerProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport type TabsContentProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport const TabsList = React.forwardRef<\n React.ElementRef,\n TabsListProps\n>(({ className, ...props }, ref) => (\n \n));\nTabsList.displayName = TabsPrimitive.List.displayName;\n\nexport const TabsTrigger = React.forwardRef<\n React.ElementRef,\n TabsTriggerProps\n>(({ className, ...props }, ref) => (\n \n));\nTabsTrigger.displayName = TabsPrimitive.Trigger.displayName;\n\nexport const TabsContent = React.forwardRef<\n React.ElementRef,\n TabsContentProps\n>(({ className, ...props }, ref) => (\n \n));\nTabsContent.displayName = TabsPrimitive.Content.displayName;\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Download } from 'lucide-react';\n\ntype InstallButtonProps = {\n /** The installing boolean value determines the state of the button. */\n isInstalling: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n /** Optional text for the button. */\n buttonText?: string;\n} & ButtonProps;\n\n/**\n * The InstallButton component is a button designed for initiating installs. It includes visuals for\n * active installing and idle states.\n *\n * @param isInstalling The installing boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @param buttonText Optional text for the button.\n * @returns A install button.\n */\nexport default function InstallButton({\n isInstalling,\n handleClick,\n buttonText,\n className,\n ...props\n}: InstallButtonProps) {\n return (\n \n {isInstalling ? (\n \n ) : (\n <>\n \n {buttonText}\n \n )}\n \n );\n}\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\n\ntype EnableButtonProps = {\n /** The enabling boolean value determines the state of the button. */\n isEnabling: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n} & ButtonProps;\n\n/**\n * The EnableButton component is a button designed for initiating enabling of downloads. It includes\n * visuals for active enabling and idle states.\n *\n * @param isEnabling The enabling boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @returns A button that can be used to enable.\n */\nexport default function EnableButton({\n isEnabling,\n handleClick,\n className,\n ...props\n}: EnableButtonProps) {\n return (\n \n {isEnabling ? (\n <>\n \n Enabling...\n \n ) : (\n 'Enable'\n )}\n \n );\n}\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\n\ntype DisableButtonProps = {\n /** The disabling boolean value determines the state of the button. */\n isDisabling: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n} & ButtonProps;\n\n/**\n * The DisableButton component is a button designed for initiating disabling of downloads. It\n * includes visuals for active disabling and idle states.\n *\n * @param isDisabling The disabling boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @returns A button that can be used to disable.\n */\nexport default function DisableButton({\n isDisabling,\n handleClick,\n className,\n ...props\n}: DisableButtonProps) {\n return (\n \n {isDisabling ? (\n <>\n \n Disabling...\n \n ) : (\n 'Disable'\n )}\n \n );\n}\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\n\ntype UpdateButtonProps = {\n /** The updating boolean value determines the state of the button. */\n isUpdating: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n} & ButtonProps;\n\n/**\n * The UpdateButton component is a button designed for initiating updates for downloaded extensions.\n * It includes visuals for active updating and idle states.\n *\n * @param isUpdating The updating boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @returns A button that can be used to update.\n */\nexport default function UpdateButton({\n isUpdating,\n handleClick,\n className,\n ...props\n}: UpdateButtonProps) {\n return (\n \n {isUpdating ? (\n <>\n \n Updating...\n \n ) : (\n 'Update'\n )}\n \n );\n}\n","import { cn } from '@/utils/shadcn-ui.util';\nimport Markdown, { MarkdownToJSX } from 'markdown-to-jsx';\nimport { useMemo } from 'react';\n\ninterface MarkdownRendererProps {\n /** Optional unique identifier */\n id?: string;\n /** The markdown string to render */\n markdown: string;\n className?: string;\n /**\n * The [`target` attribute for `a` html\n * tags](https://developer.mozilla.org/en-US/docs/Web/HTML/Element/a#target). Defaults to not\n * adding a `target` to `a` tags\n */\n anchorTarget?: string;\n}\n\n/**\n * This component renders markdown content given a markdown string. It uses typography styles from\n * the platform.\n *\n * @param markdown The markdown string to render.\n * @param id Optional unique identifier\n * @returns A div containing the rendered markdown content.\n */\nexport default function MarkdownRenderer({\n id,\n markdown,\n className,\n anchorTarget,\n}: MarkdownRendererProps) {\n const options: MarkdownToJSX.Options = useMemo(\n () => ({\n overrides: {\n a: {\n props: {\n target: anchorTarget,\n },\n },\n },\n }),\n [anchorTarget],\n );\n return (\n
    \n {markdown}\n
    \n );\n}\n","import { Filter, ChevronDown } from 'lucide-react';\nimport { forwardRef } from 'react';\nimport { Button } from '@/components/shadcn-ui/button';\n\n/**\n * The FilterButton component is a button designed for initiating filtering of data. It is designed\n * to be used with the dropdown menu. It uses forwardRef to pass the button to the dropdown trigger\n * asChild.\n *\n * @returns A button that can be used to filter.\n */\nconst FilterButton = forwardRef((props, ref) => {\n return (\n \n \n Filter\n \n \n );\n});\n\nexport default FilterButton;\n","import {\n DropdownMenu,\n DropdownMenuTrigger,\n DropdownMenuContent,\n DropdownMenuLabel,\n DropdownMenuGroup,\n DropdownMenuCheckboxItem,\n DropdownMenuRadioItem,\n DropdownMenuSeparator,\n} from '@/components/shadcn-ui/dropdown-menu';\nimport FilterButton from './buttons/filter-button.component';\n\nexport enum DropdownMenuItemType {\n Check,\n Radio,\n}\n\nexport type DropdownItem = {\n /** The label is the text that will be displayed on the dropdown item. */\n label: string;\n /** The itemType determines the DropdownMenuItemType type as either Check or Radio. */\n itemType: DropdownMenuItemType;\n /** The onClick function is called when the item is clicked. */\n onClick: () => void;\n};\n\nexport type DropdownGroup = {\n /**\n * The label is the text that will be displayed on the dropdown group. It is used to categorize\n * the items in the group.\n */\n label: string;\n /** The items array contains the items that will be displayed in the dropdown group */\n items: DropdownItem[];\n};\n\nexport type FilterDropdownProps = {\n /** Object unique identifier */\n id?: string;\n /** The groups array contains the groups that will be displayed in the dropdown */\n groups: DropdownGroup[];\n}; // TODO: extend the props later\n\n/**\n * The FilterDropdown component is a dropdown designed for filtering content. It includes groups of\n * items that can be checkboxes or radio items.\n *\n * @param id Optional unique identifier\n * @param groups The groups array contains the groups that will be displayed in the dropdown\n * @returns A filter dropdown.\n */\nexport default function FilterDropdown({ id, groups }: FilterDropdownProps) {\n return (\n
    \n {/* TODO: remove this once the DropDown Menu shadcn has an id prop */}\n \n \n \n \n \n {groups.map((group) => (\n
    \n {group.label}\n \n {group.items.map((item) => (\n
    \n {item.itemType === DropdownMenuItemType.Check ? (\n \n {item.label}\n \n ) : (\n \n {item.label}\n \n )}\n
    \n ))}\n
    \n \n
    \n ))}\n
    \n
    \n
    \n );\n}\n","interface NoExtensionsFoundProps {\n /** Optional unique identifier */\n id?: string;\n /** The message to display */\n message: string;\n}\n/**\n * This component displays a message to the user when no extensions are found in the marketplace.\n *\n * @param id Optional unique identifier\n * @param message The message to display.\n * @returns {JSX.Element} - Returns the message component that displays the message to the user.\n */\nexport default function NoExtensionsFound({ id, message }: NoExtensionsFoundProps) {\n return (\n
    \n
    \n

    {message}

    \n
    \n
    \n );\n}\n","import { CircleHelp, Link as LucideLink, User } from 'lucide-react';\nimport { NumberFormat } from 'platform-bible-utils';\n\n/** Interface that stores the parameters passed to the More Info component */\ninterface MoreInfoProps {\n /** Optional unique identifier */\n id?: string;\n /** The category of the extension */\n category: string;\n /** The number of downloads for the extension */\n downloads: Record;\n /** The languages supported by the extension */\n languages: string[];\n /** The URL to the more info page of the extension */\n moreInfoUrl: string;\n}\n/**\n * This component displays the more info section of the extension which includes the category,\n * number of downloads, languages, and links to the website and support\n *\n * @param id Optional unique identifier\n * @param category The category of the extension\n * @param downloads The number of downloads for the extension\n * @param languages The languages supported by the extension\n * @param moreInfoUrl The URL to the more info page of the extension\n * @returns {JSX.Element} - Returns the more info component that displays the category, number of\n * downloads, languages, and links to the website and support\n */\nexport default function MoreInfo({\n id,\n category,\n downloads,\n languages,\n moreInfoUrl,\n}: MoreInfoProps) {\n /**\n * This constant formats the number of downloads into a more readable format.\n *\n * @example 1000 -> 1K\n *\n * @example 1000000 -> 1M\n *\n * @returns The formatted number of downloads\n */\n const numberFormatted = new NumberFormat('en', {\n notation: 'compact',\n compactDisplay: 'short',\n }).format(Object.values(downloads).reduce((a: number, b: number) => a + b, 0));\n\n /** This function scrolls the window to the bottom of the page. */\n const handleScrollToBottom = () => {\n window.scrollTo(0, document.body.scrollHeight);\n };\n\n return (\n \n
    \n
    \n {category}\n
    \n CATEGORY\n
    \n
    \n
    \n
    \n \n {numberFormatted}\n
    \n USERS\n
    \n
    \n
    \n
    \n {languages.slice(0, 3).map((locale) => (\n \n {locale.toUpperCase()}\n \n ))}\n
    \n {languages.length > 3 && (\n handleScrollToBottom()}\n className=\"tw-text-xs tw-text-gray-500 tw-underline\"\n >\n +{languages.length - 3} more languages\n \n )}\n
    \n
    \n
    \n \n Website\n \n \n \n Support\n \n \n
    \n
    \n );\n}\n","import { useState } from 'react';\n\nexport type VersionInformation = {\n /** Date the version was published */\n date: string;\n /** Description of the changes in the version */\n description: string;\n};\n\n/** Type to store the version history information */\nexport type VersionHistoryType = Record;\n\n/** Interface that stores the parameters passed to the Version History component */\ninterface VersionHistoryProps {\n /** Optional unique identifier */\n id?: string;\n /** Object containing the versions mapped with their information */\n versionHistory: VersionHistoryType;\n}\n\n/**\n * Component to render the version history information shown in the footer component. Lists the 5\n * most recent versions, with the options to show all versions by pressing a button.\n *\n * @param versionHistory Object containing the versions mapped with their information\n * @param id Optional unique identifier\n * @returns Rendered version history for the Footer component\n */\nexport default function VersionHistory({ id, versionHistory }: VersionHistoryProps) {\n const [showAllVersions, setShowAllVersions] = useState(false);\n const currentDate = new Date();\n\n /**\n * Function to format the time string for the version history in the form of 'X year(s) ago'.\n *\n * @param dateString ISO Date string to determine the time string from\n * @returns Formatted time string\n */\n function formatTimeString(dateString: string) {\n const date = new Date(dateString);\n const dateDiff = new Date(currentDate.getTime() - date.getTime());\n const yearDiff = dateDiff.getUTCFullYear() - 1970;\n const monthDiff = dateDiff.getUTCMonth();\n const dayDiff = dateDiff.getUTCDate() - 1;\n\n // Determines how long ago the version was published\n let timeString = '';\n if (yearDiff > 0) {\n timeString = `${yearDiff.toString()} year${yearDiff === 1 ? '' : 's'} ago`;\n } else if (monthDiff > 0) {\n timeString = `${monthDiff.toString()} month${monthDiff === 1 ? '' : 's'} ago`;\n } else if (dayDiff === 0) {\n timeString = 'today';\n } else {\n timeString = `${dayDiff.toString()} day${dayDiff === 1 ? '' : 's'} ago`;\n }\n\n return timeString;\n }\n\n // Sorts the version history by version number\n const sortedEntries = Object.entries(versionHistory).sort((a, b) => b[0].localeCompare(a[0]));\n\n return (\n
    \n

    What`s New

    \n
      \n {(showAllVersions ? sortedEntries : sortedEntries.slice(0, 5)).map((entry) => (\n
      \n
      \n
    • \n {entry[1].description}\n
    • \n
      \n
      \n
      Version {entry[0]}
      \n
      {formatTimeString(entry[1].date)}
      \n
      \n
      \n ))}\n
    \n {sortedEntries.length > 5 && (\n setShowAllVersions(!showAllVersions)}\n className=\"tw-text-xs tw-text-gray-500 tw-underline\"\n >\n {showAllVersions ? 'Show Less Version History' : 'Show All Version History'}\n \n )}\n
    \n );\n}\n","import { useMemo } from 'react';\nimport { formatBytes } from 'platform-bible-utils';\nimport VersionHistory, { VersionHistoryType } from './version-history.component';\n\n/** Interface to store the parameters passed to the Footer component */\ninterface FooterProps {\n /** Optional unique identifier */\n id?: string;\n /** Name of the publisher */\n publisherDisplayName: string;\n /** Size of the extension file in bytes */\n fileSize: number;\n /** List of language codes supported by the extension */\n locales: string[];\n /** Object containing the version history mapped with their information */\n versionHistory: VersionHistoryType;\n}\n\n/**\n * Component to render the footer for the extension details which contains information on the\n * publisher, version history, languages, and file size.\n *\n * @param id Optional unique identifier\n * @param publisherDisplayName Name of the publisher\n * @param fileSize Size of the extension file in bytes\n * @param locales List of language codes supported by the extension\n * @param versionHistory Object containing the version history mapped with their information\n * @returns The rendered Footer component\n */\nexport default function Footer({\n id,\n publisherDisplayName,\n fileSize,\n locales,\n versionHistory,\n}: FooterProps) {\n /** Formats the file size into a human-readable format */\n const formattedFileSize = useMemo(() => formatBytes(fileSize), [fileSize]);\n\n /**\n * This function gets the display names of the languages based on the language codes.\n *\n * @param codes The list of language codes\n * @returns The list of language names\n */\n const getLanguageNames = (codes: string[]) => {\n const displayNames = new Intl.DisplayNames(navigator.language, { type: 'language' });\n return codes.map((code) => displayNames.of(code));\n };\n\n const languageNames = getLanguageNames(locales);\n\n return (\n
    \n
    \n \n
    \n
    \n

    Information

    \n
    \n

    \n Publisher\n {publisherDisplayName}\n Size\n {formattedFileSize}\n

    \n
    \n

    \n Languages\n {languageNames.join(', ')}\n

    \n
    \n
    \n
    \n
    \n
    \n );\n}\n","import { PlatformEvent, PlatformEventHandler } from 'platform-bible-utils';\nimport { useEffect } from 'react';\n\n/**\n * Adds an event handler to an event so the event handler runs when the event is emitted. Use\n * `papi.network.getNetworkEvent` to use a networked event with this hook.\n *\n * @param event The event to subscribe to.\n *\n * - If event is a `PlatformEvent`, that event will be used\n * - If event is undefined, the callback will not be subscribed. Useful if the event is not yet\n * available for example\n *\n * @param eventHandler The callback to run when the event is emitted\n *\n * WARNING: MUST BE STABLE - const or wrapped in useCallback. The reference must not be updated\n * every render\n */\nconst useEvent = (\n event: PlatformEvent | undefined,\n eventHandler: PlatformEventHandler,\n) => {\n useEffect(() => {\n // Do nothing if the event is not provided (in case the event is not yet available, for example)\n if (!event) return () => {};\n\n const unsubscriber = event(eventHandler);\n return () => {\n unsubscriber();\n };\n }, [event, eventHandler]);\n};\nexport default useEvent;\n","import { useCallback, useEffect } from 'react';\nimport { PlatformEvent, PlatformEventAsync, PlatformEventHandler } from 'platform-bible-utils';\nimport usePromise from './use-promise.hook';\n\nconst noopUnsubscriber = () => false;\n\n/**\n * Adds an event handler to an asynchronously subscribing/unsubscribing event so the event handler\n * runs when the event is emitted. Use `papi.network.getNetworkEvent` to use a networked event with\n * this hook.\n *\n * @param event The asynchronously (un)subscribing event to subscribe to.\n *\n * - If event is a `PlatformEvent` or `PlatformEventAsync`, that event will be used\n * - If event is undefined, the callback will not be subscribed. Useful if the event is not yet\n * available for example\n *\n * @param eventHandler The callback to run when the event is emitted\n *\n * WARNING: MUST BE STABLE - const or wrapped in useCallback. The reference must not be updated\n * every render\n */\nconst useEventAsync = (\n event: PlatformEvent | PlatformEventAsync | undefined,\n eventHandler: PlatformEventHandler,\n) => {\n // Subscribe to the event asynchronously\n const [unsubscribe] = usePromise(\n useCallback(async () => {\n // Do nothing if the event is not provided (in case the event is not yet available, for example)\n if (!event) return noopUnsubscriber;\n\n // Wrap subscribe and unsubscribe in promises to allow normal events to be used as well\n const unsub = await Promise.resolve(event(eventHandler));\n return async () => unsub();\n }, [eventHandler, event]),\n noopUnsubscriber,\n // We want the unsubscriber to return to default value immediately upon changing subscription\n // So the useEffect below will unsubscribe asap\n { preserveValue: false },\n );\n\n // Unsubscribe from the event asynchronously (but we aren't awaiting the unsub)\n useEffect(() => {\n return () => {\n if (unsubscribe !== noopUnsubscriber) {\n unsubscribe();\n }\n };\n }, [unsubscribe]);\n};\n\nexport default useEventAsync;\n"],"names":["twMergeCustom","extendTailwindMerge","cn","inputs","clsx","Input","React","className","type","props","ref","jsx","BookChapterInput","forwardRef","handleSearch","handleKeyDown","handleOnClick","handleSubmit","jsxs","ShadInput","event","e","History","P","R","s","n","N","B","O","S","K","g","k","x","T","X","V","w","L","G","A","H","C","I","y","q","U","m","l","h","c","E","D","i","a","o","u","v","f","d","b","J","DropdownMenu","DropdownMenuPrimitive","DropdownMenuTrigger","DropdownMenuGroup","DropdownMenuPortal","DropdownMenuSub","DropdownMenuRadioGroup","DropdownMenuSubTrigger","inset","children","ChevronRight","DropdownMenuSubContent","DropdownMenuContent","sideOffset","DropdownMenuItem","DropdownMenuCheckboxItem","checked","Check","DropdownMenuRadioItem","Circle","DropdownMenuLabel","DropdownMenuSeparator","DropdownMenuShortcut","BookMenuItem","bookId","handleSelectBook","isSelected","handleHighlightBook","bookType","ShadDropdownMenuItem","Canon","ChapterSelect","handleSelectChapter","endChapter","activeChapter","highlightedChapter","handleHighlightedChapter","chapters","_","handleMouse","useCallback","chapterNumber","chapter","GoToMenuItem","handleSort","handleLocationHistory","handleBookmarks","ShadDropdownMenuLabel","ArrowDownWideNarrow","Clock","Bookmark","ALL_BOOK_IDS","BOOK_TYPE_LABELS","BOOK_TYPE_ARRAY","SCROLL_OFFSET","SEARCH_QUERY_FORMATS","fetchGroupedBooks","fetchEndChapter","getChaptersForBook","getAllEnglishNames","isValidBookEnglishName","bookName","getBookIdFromEnglishName","formattedBookName","BookChapterControl","scrRef","searchQuery","setSearchQuery","useState","selectedBookId","setSelectedBookId","setHighlightedChapter","highlightedBookId","setHighlightedBookId","isContentOpen","setIsContentOpen","isContentOpenDelayed","setIsContentOpenDelayed","inputRef","useRef","contentRef","menuItemRef","fetchFilteredBooks","englishNameLowerCase","normalizedQuery","handleSearchInput","searchString","shouldPreventAutoClosing","controlMenuState","open","updateReference","shouldClose","verse","handleInputSubmit","format","matches","book","englishName","handleKeyDownInput","handleKeyDownContent","key","handleKeyDownMenuItem","chapterOffSet","useEffect","useLayoutEffect","scrollTimeout","scrollPosition","ShadDropdownMenu","ShadDropdownMenuTrigger","ShadDropdownMenuContent","bookTypeIndex","element","ShadDropdownMenuSeparator","buttonVariants","cva","Button","variant","size","asChild","Slot","labelVariants","Label","LabelPrimitive","RadioGroup","RadioGroupPrimitive","RadioGroupItem","Popover","PopoverPrimitive","PopoverTrigger","PopoverContent","align","DialogPortal","DialogPrimitive","DialogOverlay","DialogContent","DialogTitle","DialogDescription","Command","CommandPrimitive","CommandInput","Search","CommandList","CommandEmpty","CommandGroup","CommandSeparator","CommandItem","getOptionLabelDefault","option","ComboBox","id","options","buttonClassName","popoverContentClassName","value","onChange","getOptionLabel","buttonPlaceholder","textPlaceholder","commandEmptyMessage","buttonVariant","dir","isDisabled","setOpen","ChevronsUpDown","ChapterRangeSelector","startChapter","handleSelectStartChapter","handleSelectEndChapter","chapterCount","chapterOptions","useMemo","index","Fragment","BookSelectionMode","BOOK_SELECTOR_STRING_KEYS","localizeString","strings","BookSelector","handleBookSelectionModeChange","currentBookName","onSelectBooks","selectedBookIds","localizedStrings","currentBookText","chooseText","chooseBooksText","bookSelectionMode","setBookSelectionMode","onSelectionModeChange","newMode","DataTableViewOptions","table","FilterIcon","column","Select","SelectPrimitive","SelectGroup","SelectValue","SelectTrigger","ChevronDown","SelectScrollUpButton","ChevronUp","SelectScrollDownButton","SelectContent","position","SelectLabel","SelectItem","SelectSeparator","DataTablePagination","pageSize","ArrowLeftIcon","ChevronLeftIcon","ChevronRightIcon","ArrowRightIcon","Table","stickyHeader","TableHeader","TableBody","TableFooter","TableRow","TableHead","TableCell","TableCaption","DataTable","columns","data","enablePagination","showPaginationControls","showColumnVisibilityControls","onRowClickHandler","sorting","setSorting","columnFilters","setColumnFilters","columnVisibility","setColumnVisibility","rowSelection","setRowSelection","useReactTable","getCoreRowModel","getPaginationRowModel","getSortedRowModel","getFilteredRowModel","headerGroup","header","flexRender","_a","row","cell","OccurrencesTable","occurrenceData","setScriptureReference","referenceHeaderText","occurrenceHeaderText","occurrences","uniqueOccurrences","occurrence","uniqueOccurrence","deepEqual","Checkbox","CheckboxPrimitive","getLinesFromUSFM","text","getNumberFromUSFM","regex","match","getBookNumFromId","getStatusForItem","item","approvedItems","unapprovedItems","toggleVariants","Toggle","TogglePrimitive","ToggleGroupContext","ToggleGroup","ToggleGroupPrimitive","ToggleGroupItem","context","getSortingIcon","sortDirection","ArrowUpIcon","ArrowDownIcon","ArrowUpDownIcon","inventoryItemColumn","itemLabel","inventoryAdditionalItemColumn","additionalItemLabel","additionalItemIndex","inventoryCountColumn","countLabel","statusChangeHandler","changedItems","newStatus","onApprovedItemsChange","onUnapprovedItemsChange","newApprovedItems","validItem","newUnapprovedItems","unapprovedItem","inventoryStatusColumn","statusLabel","status","CircleCheckIcon","CircleXIcon","CircleHelpIcon","INVENTORY_STRING_KEYS","filterItemData","itemData","statusFilter","textFilter","filteredItemData","createTableData","scriptureRef","itemRegex","tableData","currentBook","currentChapter","currentVerse","line","items","itemIndex","existingItem","tableEntry","newReference","substring","newItem","Inventory","scriptureReference","extractItems","additionalItemsLabels","scope","onScopeChange","allItemsText","approvedItemsText","unapprovedItemsText","unknownItemsText","scopeBookText","scopeChapterText","scopeVerseText","filterText","showAdditionalItemsText","showAdditionalItems","setShowAdditionalItems","setStatusFilter","setTextFilter","selectedItem","setSelectedItem","reducedTableData","newTableData","firstItem","existingEntry","newTableEntry","filteredTableData","allColumns","numberOfAdditionalItems","additionalColumns","_b","rowClickHandler","newSelection","handleScopeChange","handleStatusFilterChange","SearchBar","onSearch","placeholder","isFullWidth","handleInputChange","VerticalTabs","TabsPrimitive","VerticalTabsList","VerticalTabsTrigger","VerticalTabsContent","TabNavigationContentSearch","tabList","searchPlaceholder","headerTitle","isSearchBarFullWidth","direction","tab","Separator","orientation","decorative","SeparatorPrimitive","Sheet","SheetPrimitive","SheetPortal","SheetOverlay","sheetVariants","SheetContent","side","SheetTitle","SheetDescription","Skeleton","TooltipProvider","TooltipPrimitive","Tooltip","TooltipTrigger","TooltipContent","MOBILE_BREAKPOINT","useIsMobile","isMobile","setIsMobile","mql","SIDEBAR_COOKIE_NAME","SIDEBAR_COOKIE_MAX_AGE","SIDEBAR_WIDTH","SIDEBAR_WIDTH_MOBILE","SIDEBAR_WIDTH_ICON","SIDEBAR_KEYBOARD_SHORTCUT","SidebarContext","useSidebar","SidebarProvider","defaultOpen","openProp","setOpenProp","style","openMobile","setOpenMobile","_open","_setOpen","isOpen","openState","toggleSidebar","state","contextValue","Sidebar","collapsible","SidebarTrigger","onClick","PanelLeft","SidebarRail","SidebarInset","SidebarInput","SidebarHeader","SidebarFooter","SidebarSeparator","SidebarContent","SidebarGroup","SidebarGroupLabel","SidebarGroupAction","SidebarGroupContent","SidebarMenu","SidebarMenuItem","sidebarMenuButtonVariants","SidebarMenuButton","isActive","tooltip","Comp","button","SidebarMenuAction","showOnHover","SidebarMenuBadge","SidebarMenuSkeleton","showIcon","width","SidebarMenuSub","SidebarMenuSubItem","SidebarMenuSubButton","SettingsSidebar","extensionLabels","projectOptions","handleSelectSidebarItem","selectedSidebarItem","extensionsSidebarGroupLabel","projectsSidebarGroupLabel","buttonPlaceholderText","handleSelectItem","projectId","getProjectNameFromProjectId","project","getIsActive","label","selectedProjectName","SettingsSidebarContentSearch","scrBookColId","scrRefColId","typeColId","detailsColId","defaultScrRefColumnName","defaultScrBookGroupName","defaultTypeColumnName","defaultDetailsColumnName","getColumns","colInfo","showSourceColumn","showSrcCol","info","formatScrRef","compareScrRefs","toRefOrRange","scriptureSelection","offsetStart","offsetEnd","scrRefToBBBCCCVVV","getRowKey","ScriptureResultsViewer","sources","showColumnHeaders","scriptureReferenceColumnName","scriptureBookGroupName","typeColumnName","detailsColumnName","onRowSelected","grouping","setGrouping","scriptureResults","source","getExpandedRowModel","getGroupedRowModel","selectedRows","keys","selectedRow","scrBookGroupName","typeGroupName","groupingOptions","handleSelectChange","selectedGrouping","handleRowClick","getEvenOrOddBandingStyle","getIndent","groupingState","rowIndex","ChevronLeft","DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS","getLocalizeKeyForScrollGroupId","ScrollGroupSelector","availableScrollGroupIds","scrollGroupId","onChangeScrollGroupId","localizedStringsDefaulted","localizedStringKey","localizedStringValue","newScrollGroupString","scrollGroupOptionId","SettingsList","SettingsListItem","primary","secondary","isLoading","loadingMessage","SettingsListHeader","includeSeparator","Checklist","listItems","selectedListItems","handleSelectListItem","createLabel","_interopRequireDefault","obj","module","chainPropTypes","propType1","propType2","args","_extends","target","isPlainObject","prototype","deepClone","output","deepmerge","p","r","t","z","reactIs_production_min","hasSymbol","REACT_ELEMENT_TYPE","REACT_PORTAL_TYPE","REACT_FRAGMENT_TYPE","REACT_STRICT_MODE_TYPE","REACT_PROFILER_TYPE","REACT_PROVIDER_TYPE","REACT_CONTEXT_TYPE","REACT_ASYNC_MODE_TYPE","REACT_CONCURRENT_MODE_TYPE","REACT_FORWARD_REF_TYPE","REACT_SUSPENSE_TYPE","REACT_SUSPENSE_LIST_TYPE","REACT_MEMO_TYPE","REACT_LAZY_TYPE","REACT_BLOCK_TYPE","REACT_FUNDAMENTAL_TYPE","REACT_RESPONDER_TYPE","REACT_SCOPE_TYPE","isValidElementType","typeOf","object","$$typeof","$$typeofType","AsyncMode","ConcurrentMode","ContextConsumer","ContextProvider","Element","ForwardRef","Lazy","Memo","Portal","Profiler","StrictMode","Suspense","hasWarnedAboutDeprecatedIsAsyncMode","isAsyncMode","isConcurrentMode","isContextConsumer","isContextProvider","isElement","isForwardRef","isFragment","isLazy","isMemo","isPortal","isProfiler","isStrictMode","isSuspense","reactIs_development","reactIsModule","require$$0","require$$1","getOwnPropertySymbols","hasOwnProperty","propIsEnumerable","toObject","val","shouldUseNative","test1","test2","order2","test3","letter","objectAssign","from","to","symbols","ReactPropTypesSecret","ReactPropTypesSecret_1","has","printWarning","loggedTypeFailures","message","checkPropTypes","typeSpecs","values","location","componentName","getStack","typeSpecName","error","err","ex","stack","checkPropTypes_1","ReactIs","assign","require$$2","require$$3","require$$4","emptyFunctionThatReturnsNull","factoryWithTypeCheckers","isValidElement","throwOnDirectAccess","ITERATOR_SYMBOL","FAUX_ITERATOR_SYMBOL","getIteratorFn","maybeIterable","iteratorFn","ANONYMOUS","ReactPropTypes","createPrimitiveTypeChecker","createAnyTypeChecker","createArrayOfTypeChecker","createElementTypeChecker","createElementTypeTypeChecker","createInstanceTypeChecker","createNodeChecker","createObjectOfTypeChecker","createEnumTypeChecker","createUnionTypeChecker","createShapeTypeChecker","createStrictShapeTypeChecker","is","PropTypeError","createChainableTypeChecker","validate","manualPropTypeCallCache","manualPropTypeWarningCount","checkType","isRequired","propName","propFullName","secret","cacheKey","chainedCheckType","expectedType","propValue","propType","getPropType","preciseType","getPreciseType","typeChecker","expectedClass","expectedClassName","actualClassName","getClassName","expectedValues","valuesString","arrayOfTypeCheckers","checker","getPostfixForTypeWarning","expectedTypes","checkerResult","expectedTypesMessage","isNode","invalidValidatorError","shapeTypes","allKeys","iterator","step","entry","isSymbol","emptyFunction","emptyFunctionWithReset","factoryWithThrowingShims","shim","getShim","propTypesModule","isClassComponent","elementType","acceptingRef","safePropName","warningHint","elementAcceptingRef","PropTypes","elementAcceptingRef$1","specialProperty","exactProp","propTypes","unsupportedProps","prop","formatMuiErrorMessage","code","url","REACT_SERVER_CONTEXT_TYPE","REACT_OFFSCREEN_TYPE","enableScopeAPI","enableCacheElement","enableTransitionTracing","enableLegacyHidden","enableDebugTracing","REACT_MODULE_REFERENCE","SuspenseList","hasWarnedAboutDeprecatedIsConcurrentMode","isSuspenseList","fnNameMatchRegex","getFunctionName","fn","getFunctionComponentName","Component","fallback","getWrappedName","outerType","innerType","wrapperName","functionName","getDisplayName","HTMLElementType","refType","refType$1","capitalize","string","_formatMuiErrorMessage","createChainedFunction","funcs","acc","func","debounce","wait","timeout","debounced","later","deprecatedPropType","validator","reason","componentNameSafe","propFullNameSafe","isMuiElement","muiNames","_muiName","_element$type","ownerDocument","node","ownerWindow","requirePropFactory","componentNameInError","prevPropTypes","requiredProp","defaultTypeChecker","typeCheckerResult","setRef","useEnhancedEffect","useEnhancedEffect$1","globalId","useGlobalId","idOverride","defaultId","setDefaultId","maybeReactUseId","useId","reactId","unsupportedProp","useControlled","controlled","defaultProp","name","isControlled","valueState","setValue","defaultValue","setValueIfUncontrolled","newValue","useEventCallback","useForkRef","refs","instance","UNINITIALIZED","useLazyRef","init","initArg","EMPTY","useOnMount","Timeout","delay","useTimeout","hadKeyboardEvent","hadFocusVisibleRecently","hadFocusVisibleRecentlyTimeout","inputTypesWhitelist","focusTriggersKeyboardModality","tagName","handlePointerDown","handleVisibilityChange","prepare","doc","isFocusVisible","useIsFocusVisible","isFocusVisibleRef","handleBlurVisible","handleFocusVisible","resolveProps","defaultProps","defaultSlotProps","slotProps","slotPropName","composeClasses","slots","getUtilityClass","classes","slot","utilityClass","defaultGenerator","createClassNameGenerator","generate","generator","ClassNameGenerator","ClassNameGenerator$1","globalStateClasses","generateUtilityClass","globalStatePrefix","globalStateClass","generateUtilityClasses","result","clamp","min","max","_objectWithoutPropertiesLoose","excluded","sourceKeys","_excluded","sortBreakpointsValues","breakpointsAsArray","breakpoint1","breakpoint2","createBreakpoints","breakpoints","unit","other","sortedValues","up","down","between","start","end","endIndex","only","not","keyIndex","shape","shape$1","responsivePropType","responsivePropType$1","merge","defaultBreakpoints","handleBreakpoints","styleFromPropValue","theme","themeBreakpoints","breakpoint","mediaKey","cssKey","createEmptyBreakpointObject","breakpointsInput","_breakpointsInput$key","breakpointStyleKey","removeUnusedBreakpoints","breakpointKeys","breakpointOutput","getPath","path","checkVars","getStyleValue","themeMapping","transform","propValueFinal","userValue","cssProperty","themeKey","memoize","cache","arg","properties","directions","aliases","getCssProperties","property","marginKeys","paddingKeys","spacingKeys","createUnaryUnit","_getPath","themeSpacing","abs","createUnarySpacing","getValue","transformer","transformed","getStyleFromPropValue","cssProperties","resolveCssProperty","margin","padding","createSpacing","spacingInput","spacing","argsInput","argument","compose","styles","handlers","borderTransform","createBorderStyle","border","borderTop","borderRight","borderBottom","borderLeft","borderColor","borderTopColor","borderRightColor","borderBottomColor","borderLeftColor","outline","outlineColor","borderRadius","gap","columnGap","rowGap","gridColumn","gridRow","gridAutoFlow","gridAutoColumns","gridAutoRows","gridTemplateColumns","gridTemplateRows","gridTemplateAreas","gridArea","paletteTransform","color","bgcolor","backgroundColor","sizingTransform","maxWidth","_props$theme","_props$theme2","breakpointsValues","minWidth","height","maxHeight","minHeight","boxSizing","defaultSxConfig","defaultSxConfig$1","objectsHaveSameKeys","objects","union","callIfFn","maybeFn","unstable_createStyleFunctionSx","getThemeValue","config","styleFunctionSx","_theme$unstable_sxCon","sx","traverse","sxInput","sxObject","emptyBreakpoints","breakpointsKeys","css","styleKey","styleFunctionSx$1","applyStyles","createTheme","paletteInput","shapeInput","muiTheme","isObjectEmpty","useTheme","defaultTheme","contextTheme","ThemeContext","systemDefaultTheme","useThemeWithoutDefault","_excluded2","_excluded3","isEmpty","isStringTag","tag","shouldForwardProp","lowercaseFirstLetter","resolveTheme","themeId","defaultOverridesResolver","processStyleArg","callableStyle","_ref","ownerState","resolvedStylesArg","resolvedStyle","variants","isMatch","createStyled","input","rootShouldForwardProp","slotShouldForwardProp","systemSx","inputOptions","processStyles","componentSlot","inputSkipVariantsResolver","inputSkipSx","overridesResolver","skipVariantsResolver","skipSx","shouldForwardPropOption","defaultStyledResolver","styledEngineStyled","transformStyleArg","stylesArg","muiStyledResolver","styleArg","expressions","transformedStyleArg","expressionsWithDefaultTheme","styleOverrides","resolvedStyleOverrides","slotKey","slotStyle","_theme$components","themeVariants","numOfCustomFnsApplied","placeholders","displayName","getThemeProps","params","useThemeProps","clampWrapper","hexToRgb","re","colors","decomposeColor","marker","colorSpace","recomposeColor","hslToRgb","rgb","getLuminance","getContrastRatio","foreground","background","lumA","lumB","alpha","darken","coefficient","lighten","createMixins","mixins","common","common$1","grey","grey$1","purple","purple$1","red","red$1","orange","orange$1","blue","blue$1","lightBlue","lightBlue$1","green","green$1","light","dark","addLightOrDark","intent","shade","tonalOffset","tonalOffsetLight","tonalOffsetDark","getDefaultPrimary","mode","getDefaultSecondary","getDefaultError","getDefaultInfo","getDefaultSuccess","getDefaultWarning","createPalette","palette","contrastThreshold","success","warning","getContrastText","contrastText","contrast","augmentColor","mainShade","lightShade","darkShade","modes","round","caseAllCaps","defaultFontFamily","createTypography","typography","fontFamily","fontSize","fontWeightLight","fontWeightRegular","fontWeightMedium","fontWeightBold","htmlFontSize","allVariants","pxToRem2","coef","pxToRem","buildVariant","fontWeight","lineHeight","letterSpacing","casing","shadowKeyUmbraOpacity","shadowKeyPenumbraOpacity","shadowAmbientShadowOpacity","createShadow","px","shadows","shadows$1","easing","duration","formatMs","milliseconds","getAutoHeightDuration","constant","createTransitions","inputTransitions","mergedEasing","mergedDuration","durationOption","easingOption","isString","isNumber","animatedProp","zIndex","zIndex$1","mixinsInput","transitionsInput","typographyInput","systemTheme","systemCreateTheme","stateClasses","component","child","stateClass","defaultTheme$1","THEME_ID","systemUseThemeProps","styled","styled$1","getSvgIconUtilityClass","useUtilityClasses","SvgIconRoot","_theme$transitions","_theme$transitions$cr","_theme$transitions2","_theme$typography","_theme$typography$pxT","_theme$typography2","_theme$typography2$px","_theme$typography3","_theme$typography3$px","_palette$ownerState$c","_palette","_palette2","_palette3","SvgIcon","inProps","htmlColor","inheritViewBox","titleAccess","viewBox","hasSvgAsChild","more","_jsxs","_jsx","SvgIcon$1","createSvgIcon","unstable_ClassNameGenerator","exports","_utils","ArrowRight","default_1","_createSvgIcon","_jsxRuntime","isHostComponent","appendOwnerState","otherProps","defaultContextValue","ClassNameConfiguratorContext","useClassNamesOverride","disableDefaultClasses","extractEventHandlers","excludeKeys","resolveComponentProps","componentProps","slotState","omitEventHandlers","mergeSlotProps","parameters","getSlotProps","additionalProps","externalSlotProps","externalForwardedProps","joinedClasses","mergedStyle","eventHandlers","componentsPropsWithoutEventHandlers","otherPropsWithoutEventHandlers","internalSlotProps","useSlotProps","_parameters$additiona","skipResolvingSlotProps","rest","resolvedComponentsProps","mergedProps","internalRef","GLOBAL_CLASS_PREFIX","buildStateClass","buildSlotClass","getContainer","container","forwardedRef","disablePortal","mountNode","setMountNode","handleRef","newProps","ReactDOM","top","bottom","right","left","auto","basePlacements","clippingParents","viewport","popper","reference","variationPlacements","placement","placements","beforeRead","read","afterRead","beforeMain","main","afterMain","beforeWrite","write","afterWrite","modifierPhases","getNodeName","getWindow","OwnElement","isHTMLElement","isShadowRoot","attributes","effect","_ref2","initialStyles","styleProperties","attribute","applyStyles$1","getBasePlacement","getUAString","uaData","isLayoutViewport","getBoundingClientRect","includeScale","isFixedStrategy","clientRect","scaleX","scaleY","visualViewport","addVisualOffsets","getLayoutRect","contains","parent","rootNode","next","getComputedStyle","isTableElement","getDocumentElement","getParentNode","getTrueOffsetParent","getContainingBlock","isFirefox","isIE","elementCss","currentNode","getOffsetParent","window","offsetParent","getMainAxisFromPlacement","within","mathMax","mathMin","withinMaxClamp","getFreshSideObject","mergePaddingObject","paddingObject","expandToHashMap","hashMap","toPaddingObject","arrow","_state$modifiersData$","arrowElement","popperOffsets","basePlacement","axis","isVertical","len","arrowRect","minProp","maxProp","endDiff","startDiff","arrowOffsetParent","clientSize","centerToReference","center","offset","axisProp","_options$element","arrow$1","getVariation","unsetSides","roundOffsetsByDPR","win","dpr","mapToStyles","_Object$assign2","popperRect","variation","offsets","gpuAcceleration","adaptive","roundOffsets","isFixed","_offsets$x","_offsets$y","_ref3","hasX","hasY","sideX","sideY","heightProp","widthProp","offsetY","offsetX","commonStyles","_ref4","_Object$assign","computeStyles","_ref5","_options$gpuAccelerat","_options$adaptive","_options$roundOffsets","computeStyles$1","passive","_options$scroll","scroll","_options$resize","resize","scrollParents","scrollParent","eventListeners","hash","getOppositePlacement","matched","getOppositeVariationPlacement","getWindowScroll","scrollLeft","scrollTop","getWindowScrollBarX","getViewportRect","strategy","html","layoutViewport","getDocumentRect","_element$ownerDocumen","winScroll","body","isScrollParent","_getComputedStyle","overflow","overflowX","overflowY","getScrollParent","listScrollParents","list","isBody","updatedList","rectToClientRect","rect","getInnerBoundingClientRect","getClientRectFromMixedType","clippingParent","getClippingParents","canEscapeClipping","clipperElement","getClippingRect","boundary","rootBoundary","mainClippingParents","firstClippingParent","clippingRect","accRect","computeOffsets","commonX","commonY","mainAxis","detectOverflow","_options","_options$placement","_options$strategy","_options$boundary","_options$rootBoundary","_options$elementConte","elementContext","_options$altBoundary","altBoundary","_options$padding","altContext","clippingClientRect","referenceClientRect","popperClientRect","elementClientRect","overflowOffsets","offsetData","multiply","computeAutoPlacement","flipVariations","_options$allowedAutoP","allowedAutoPlacements","allPlacements","allowedPlacements","overflows","getExpandedFallbackPlacements","oppositePlacement","flip","_options$mainAxis","checkMainAxis","_options$altAxis","checkAltAxis","specifiedFallbackPlacements","_options$flipVariatio","preferredPlacement","isBasePlacement","fallbackPlacements","referenceRect","checksMap","makeFallbackChecks","firstFittingPlacement","_basePlacement","isStartVariation","mainVariationSide","altVariationSide","checks","check","numberOfChecks","_loop","_i","fittingPlacement","_ret","flip$1","getSideOffsets","preventedOffsets","isAnySideFullyClipped","hide","referenceOverflow","popperAltOverflow","referenceClippingOffsets","popperEscapeOffsets","isReferenceHidden","hasPopperEscaped","hide$1","distanceAndSkiddingToXY","rects","invertDistance","skidding","distance","_options$offset","_data$state$placement","offset$1","popperOffsets$1","getAltAxis","preventOverflow","_options$tether","tether","_options$tetherOffset","tetherOffset","altAxis","tetherOffsetValue","normalizedTetherOffsetValue","offsetModifierState","_offsetModifierState$","mainSide","altSide","additive","minLen","maxLen","arrowPaddingObject","arrowPaddingMin","arrowPaddingMax","arrowLen","minOffset","maxOffset","clientOffset","offsetModifierValue","tetherMin","tetherMax","preventedOffset","_offsetModifierState$2","_mainSide","_altSide","_offset","_len","_min","_max","isOriginSide","_offsetModifierValue","_tetherMin","_tetherMax","_preventedOffset","preventOverflow$1","getHTMLElementScroll","getNodeScroll","isElementScaled","getCompositeRect","elementOrVirtualElement","isOffsetParentAnElement","offsetParentIsScaled","documentElement","order","modifiers","map","visited","modifier","sort","requires","dep","depModifier","orderModifiers","orderedModifiers","phase","pending","resolve","mergeByName","merged","current","existing","DEFAULT_OPTIONS","areValidElements","_key","popperGenerator","generatorOptions","_generatorOptions","_generatorOptions$def","defaultModifiers","_generatorOptions$def2","defaultOptions","effectCleanupFns","isDestroyed","setOptionsAction","cleanupModifierEffects","runModifierEffects","_state$elements","_state$orderedModifie","_state$orderedModifie2","_ref$options","cleanupFn","noopFn","createPopper","COMPONENT_NAME","getPopperUtilityClass","flipPlacement","resolveAnchorEl","anchorEl","isVirtualElement","defaultPopperOptions","PopperTooltip","_slots$root","initialPlacement","popperOptions","popperRefProp","TransitionProps","tooltipRef","ownRef","popperRef","handlePopperRef","handlePopperRefRef","rtlPlacement","setPlacement","resolvedAnchorElement","setResolvedAnchorElement","handlePopperUpdate","box","popperModifiers","childProps","Root","rootProps","Popper","containerProp","keepMounted","transition","exited","setExited","handleEnter","handleExited","resolvedAnchorEl","display","transitionProps","useThemeSystem","_setPrototypeOf","_inheritsLoose","subClass","superClass","setPrototypeOf","timeoutsShape","TransitionGroupContext","forceReflow","UNMOUNTED","EXITED","ENTERING","ENTERED","EXITING","Transition","_React$Component","_this","parentGroup","appear","initialStatus","prevState","nextIn","_proto","prevProps","nextStatus","exit","enter","mounting","_this2","appearing","maybeNode","maybeAppearing","timeouts","enterTimeout","_this3","nextState","callback","_this4","active","handler","doesNotHaveTimeoutOrListener","maybeNextCallback","_this$props","pt","noop","Transition$1","reflow","getTransitionProps","_style$transitionDura","_style$transitionTimi","getScale","isWebKit154","Grow","addEndListener","inProp","onEnter","onEntered","onEntering","onExit","onExited","onExiting","TransitionComponent","timer","autoTimeout","nodeRef","normalizedTransitionCallback","maybeIsAppearing","handleEntering","isAppearing","transitionDuration","transitionTimingFunction","handleEntered","handleExiting","handleExit","Grow$1","PopperRoot","BasePopper","components","componentsProps","RootComponent","Popper$1","getTooltipUtilityClass","tooltipClasses","tooltipClasses$1","disableInteractive","touch","TooltipPopper","TooltipTooltip","TooltipArrow","hystersisOpen","hystersisTimer","cursorPosition","composeEventHandler","eventHandler","_slots$popper","_slots$transition","_slots$tooltip","_slots$arrow","_slotProps$popper","_ref6","_slotProps$popper2","_slotProps$transition","_slotProps$tooltip","_ref7","_slotProps$tooltip2","_slotProps$arrow","_ref8","_slotProps$arrow2","childrenProp","describeChild","disableFocusListener","disableHoverListener","disableInteractiveProp","disableTouchListener","enterDelay","enterNextDelay","enterTouchDelay","followCursor","idProp","leaveDelay","leaveTouchDelay","onClose","onOpen","PopperComponentProp","PopperProps","title","TransitionComponentProp","isRtl","childNode","setChildNode","arrowRef","setArrowRef","ignoreNonTouchEvents","closeTimer","enterTimer","leaveTimer","touchTimer","setOpenState","prevUserSelect","stopTouchInteraction","handleOpen","handleClose","handleLeave","focusVisibleRef","setChildIsFocusVisible","handleBlur","handleFocus","detectTouchStart","childrenProps","handleMouseOver","handleMouseLeave","handleTouchStart","handleTouchEnd","nativeEvent","handleMouseMove","nameOrDescProps","titleIsString","interactiveWrapperListeners","_PopperProps$popperOp","tooltipModifiers","PopperComponent","TooltipComponent","ArrowComponent","popperProps","tooltipProps","tooltipArrowProps","TransitionPropsInner","Tooltip$1","getIcon","icon","menuLabel","leading","MuiListItemIcon","MenuItem","allowForLeadingIcons","iconPathBefore","iconPathAfter","hasAutoFocus","isDense","isSubMenuParent","hasDisabledGutters","hasDivider","focusVisibleClassName","menuItem","MuiMenuItem","MuiListItemText","getAllGroups","menuDefinition","SubMenu","setAnchorEl","parentMenuItem","parentItemProps","handleParentMenuItemClick","renderSubMenuItems","includedGroups","group","GroupedMenuItemList","Menu","getOrderedGroupItems","groupId","allItems","menuProps","commandHandler","groupsToInclude","sortedGroups","itemArray","allowSpaceForLeadingIcons","createMenuItemProps","isLastItemInGroup","divKey","itemInfo","menuItemProps","TopLevelMenu","columnId","MenuColumn","metadata","Grid","List","GridMenu","multiColumnMenu","sortedColumns","columnNumbers","columnName","col","getUsePromiseOptionsDefaults","usePromise","promiseFactoryCallback","defaultValueRef","optionsDefaultedRef","setIsLoading","promiseIsCurrent","MenuIcon","HamburgerMenuButton","menuProvider","normalMenu","fullMenu","containerRef","ariaLabelPrefix","isMenuOpen","setMenuOpen","showFullMenu","setShowFullMenu","handleMenuItemClick","handleMenuButtonClick","prevIsOpen","isOpening","menuCommandHandler","command","setOffset","normalMenuData","fullMenuData","menu","IconButton","Drawer","isTooltipSuppressed","adjustMarginToAlignToEdge","MuiIconButton","Spinner","LoaderCircle","TextField","hasError","helperText","onFocus","onBlur","ShadLabel","Toolbar","AppBar","MuiToolbar","alertVariants","Alert","AlertTitle","AlertDescription","Card","CardHeader","CardTitle","CardDescription","CardContent","CardFooter","Sonner","Toaster","Slider","SliderPrimitive","Switch","SwitchPrimitives","Tabs","TabsList","TabsTrigger","TabsContent","InstallButton","isInstalling","handleClick","buttonText","Download","EnableButton","isEnabling","DisableButton","isDisabling","UpdateButton","isUpdating","MarkdownRenderer","markdown","anchorTarget","Markdown","FilterButton","Filter","DropdownMenuItemType","DropdownMenuItemType2","FilterDropdown","groups","NoExtensionsFound","MoreInfo","category","downloads","languages","moreInfoUrl","numberFormatted","NumberFormat","handleScrollToBottom","User","locale","LucideLink","CircleHelp","VersionHistory","versionHistory","showAllVersions","setShowAllVersions","currentDate","formatTimeString","dateString","date","dateDiff","yearDiff","monthDiff","dayDiff","timeString","sortedEntries","Footer","publisherDisplayName","fileSize","locales","formattedFileSize","formatBytes","languageNames","codes","displayNames","useEvent","unsubscriber","noopUnsubscriber","useEventAsync","unsubscribe","unsub"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAGA,MAAMA,KAAgBC,GAAoB,EAAE,QAAQ,MAAO,CAAA;AAyDpD,SAASC,KAAMC,GAAsB;AACnC,SAAAH,GAAcI,GAAKD,CAAM,CAAC;AACnC;ACzDO,MAAME,KAAQC,EAAM;AAAA,EACzB,CAAC,EAAE,WAAAC,GAAW,MAAAC,GAAM,GAAGC,EAAA,GAASC,MAE5B,gBAAAC;AAAA,IAAC;AAAA,IAAA;AAAA,MACC,MAAAH;AAAA,MACA,WAAWN;AAAA,QACT;AAAA,QACAK;AAAA,MACF;AAAA,MACA,KAAAG;AAAA,MAEC,GAAGD;AAAA,IAAA;AAAA,EAAA;AAIZ;AACAJ,GAAM,cAAc;ACNpB,MAAMO,KAAmBC;AAAA,EACvB,CACE,EAAE,cAAAC,GAAc,eAAAC,GAAe,eAAAC,GAAe,cAAAC,GAAc,GAAGR,EAAM,GACrEC,MAGE,gBAAAQ,EAAC,OAAI,EAAA,WAAU,eACb,UAAA;AAAA,IAAA,gBAAAP;AAAA,MAACQ;AAAAA,MAAA;AAAA,QACE,GAAGV;AAAA,QACJ,MAAK;AAAA,QACL,WAAU;AAAA,QACV,UAAU,CAACW,MAAUN,EAAaM,E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ACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA;AAAA;AAAA,EAGA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AACF,GAAGC,KAAIC;AACP,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;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","x_google_ignoreList":[3,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,83,84,85,86,87,88,89,90,91,92,93,94,95,96,97,98,99,100,101,102,103,104,105,106,107,108,109,110,111,112,113,114,115,116,117,118,119,120,121,122,123,124,125,126,127,128,129,130,131,132,133,134,135,136,137,138,139,140,141,142,143,144,145,146,147,148,149,150,151,152,153,154,155,156,157,158,159,160,161,162,163,164,165,166,167,168,169,170,171,172,173,174,175,176,177,178,179,180,181,182,183,184,185,186,187,188,189,190,191,192,193,194,195,196,197,198,199,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,228]} \ No newline at end of file +{"version":3,"file":"index.js","sources":["../src/utils/shadcn-ui.util.ts","../src/components/shadcn-ui/input.tsx","../src/components/advanced/book-chapter-control/book-chapter-input.component.tsx","../../../node_modules/@sillsdev/scripture/dist/index.es.js","../src/components/shadcn-ui/dropdown-menu.tsx","../src/components/advanced/book-chapter-control/book-menu-item.component.tsx","../src/components/advanced/book-chapter-control/chapter-select.component.tsx","../src/components/advanced/book-chapter-control/go-to-menu-item.component.tsx","../src/components/advanced/book-chapter-control/book-chapter-control.component.tsx","../src/components/shadcn-ui/button.tsx","../src/components/shadcn-ui/label.tsx","../src/components/shadcn-ui/radio-group.tsx","../src/components/shadcn-ui/popover.tsx","../src/components/shadcn-ui/dialog.tsx","../src/components/shadcn-ui/command.tsx","../src/components/basics/combo-box.component.tsx","../src/components/basics/chapter-range-selector.component.tsx","../src/components/advanced/book-selector.component.tsx","../src/components/advanced/data-table/data-table-column-toggle.component.tsx","../src/components/shadcn-ui/select.tsx","../src/components/advanced/data-table/data-table-pagination.component.tsx","../src/components/shadcn-ui/table.tsx","../src/components/advanced/data-table/data-table.component.tsx","../src/components/advanced/inventory/occurrences-table.component.tsx","../src/components/shadcn-ui/checkbox.tsx","../src/components/advanced/inventory/inventory-utils.ts","../src/components/shadcn-ui/toggle.tsx","../src/components/shadcn-ui/toggle-group.tsx","../src/components/advanced/inventory/inventory-columns.tsx","../src/components/advanced/inventory/inventory.component.tsx","../src/components/basics/search-bar.component.tsx","../src/components/basics/tabs-vertical.tsx","../src/components/advanced/tab-navigation-content-search.component.tsx","../src/components/shadcn-ui/separator.tsx","../src/components/shadcn-ui/skeleton.tsx","../src/components/shadcn-ui/tooltip.tsx","../src/components/shadcn-ui/sidebar.tsx","../src/components/advanced/settings-components/settings-sidebar.component.tsx","../src/components/advanced/settings-components/settings-sidebar-content-search.component.tsx","../src/components/advanced/scripture-results-viewer/scripture-results-viewer.component.tsx","../src/components/advanced/scroll-group-selector.component.tsx","../src/components/advanced/settings-components/settings-list.component.tsx","../src/components/basics/checklist.component.tsx","../../../node_modules/@babel/runtime/helpers/interopRequireDefault.js","../../../node_modules/@mui/utils/chainPropTypes/chainPropTypes.js","../../../node_modules/@babel/runtime/helpers/esm/extends.js","../../../node_modules/@mui/utils/deepmerge/deepmerge.js","../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.production.min.js","../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.development.js","../../../node_modules/prop-types/node_modules/react-is/index.js","../../../node_modules/object-assign/index.js","../../../node_modules/prop-types/lib/ReactPropTypesSecret.js","../../../node_modules/prop-types/lib/has.js","../../../node_modules/prop-types/checkPropTypes.js","../../../node_modules/prop-types/factoryWithTypeCheckers.js","../../../node_modules/prop-types/factoryWithThrowingShims.js","../../../node_modules/prop-types/index.js","../../../node_modules/@mui/utils/elementAcceptingRef/elementAcceptingRef.js","../../../node_modules/@mui/utils/exactProp/exactProp.js","../../../node_modules/@mui/utils/formatMuiErrorMessage/formatMuiErrorMessage.js","../../../node_modules/react-is/cjs/react-is.production.min.js","../../../node_modules/react-is/cjs/react-is.development.js","../../../node_modules/react-is/index.js","../../../node_modules/@mui/utils/getDisplayName/getDisplayName.js","../../../node_modules/@mui/utils/HTMLElementType/HTMLElementType.js","../../../node_modules/@mui/utils/refType/refType.js","../../../node_modules/@mui/utils/capitalize/capitalize.js","../../../node_modules/@mui/utils/createChainedFunction/createChainedFunction.js","../../../node_modules/@mui/utils/debounce/debounce.js","../../../node_modules/@mui/utils/deprecatedPropType/deprecatedPropType.js","../../../node_modules/@mui/utils/isMuiElement/isMuiElement.js","../../../node_modules/@mui/utils/ownerDocument/ownerDocument.js","../../../node_modules/@mui/utils/ownerWindow/ownerWindow.js","../../../node_modules/@mui/utils/requirePropFactory/requirePropFactory.js","../../../node_modules/@mui/utils/setRef/setRef.js","../../../node_modules/@mui/utils/useEnhancedEffect/useEnhancedEffect.js","../../../node_modules/@mui/utils/useId/useId.js","../../../node_modules/@mui/utils/unsupportedProp/unsupportedProp.js","../../../node_modules/@mui/utils/useControlled/useControlled.js","../../../node_modules/@mui/utils/useEventCallback/useEventCallback.js","../../../node_modules/@mui/utils/useForkRef/useForkRef.js","../../../node_modules/@mui/utils/useLazyRef/useLazyRef.js","../../../node_modules/@mui/utils/useOnMount/useOnMount.js","../../../node_modules/@mui/utils/useTimeout/useTimeout.js","../../../node_modules/@mui/utils/useIsFocusVisible/useIsFocusVisible.js","../../../node_modules/@mui/utils/resolveProps/resolveProps.js","../../../node_modules/@mui/utils/composeClasses/composeClasses.js","../../../node_modules/@mui/utils/ClassNameGenerator/ClassNameGenerator.js","../../../node_modules/@mui/utils/generateUtilityClass/generateUtilityClass.js","../../../node_modules/@mui/utils/generateUtilityClasses/generateUtilityClasses.js","../../../node_modules/@mui/utils/clamp/clamp.js","../../../node_modules/@babel/runtime/helpers/esm/objectWithoutPropertiesLoose.js","../../../node_modules/@mui/system/esm/createTheme/createBreakpoints.js","../../../node_modules/@mui/system/esm/createTheme/shape.js","../../../node_modules/@mui/system/esm/responsivePropType.js","../../../node_modules/@mui/system/esm/merge.js","../../../node_modules/@mui/system/esm/breakpoints.js","../../../node_modules/@mui/system/esm/style.js","../../../node_modules/@mui/system/esm/memoize.js","../../../node_modules/@mui/system/esm/spacing.js","../../../node_modules/@mui/system/esm/createTheme/createSpacing.js","../../../node_modules/@mui/system/esm/compose.js","../../../node_modules/@mui/system/esm/borders.js","../../../node_modules/@mui/system/esm/cssGrid.js","../../../node_modules/@mui/system/esm/palette.js","../../../node_modules/@mui/system/esm/sizing.js","../../../node_modules/@mui/system/esm/styleFunctionSx/defaultSxConfig.js","../../../node_modules/@mui/system/esm/styleFunctionSx/styleFunctionSx.js","../../../node_modules/@mui/system/esm/createTheme/applyStyles.js","../../../node_modules/@mui/system/esm/createTheme/createTheme.js","../../../node_modules/@mui/system/esm/useThemeWithoutDefault.js","../../../node_modules/@mui/system/esm/useTheme.js","../../../node_modules/@mui/system/esm/createStyled.js","../../../node_modules/@mui/system/esm/useThemeProps/getThemeProps.js","../../../node_modules/@mui/system/esm/useThemeProps/useThemeProps.js","../../../node_modules/@mui/system/esm/colorManipulator.js","../../../node_modules/@mui/material/styles/createMixins.js","../../../node_modules/@mui/material/colors/common.js","../../../node_modules/@mui/material/colors/grey.js","../../../node_modules/@mui/material/colors/purple.js","../../../node_modules/@mui/material/colors/red.js","../../../node_modules/@mui/material/colors/orange.js","../../../node_modules/@mui/material/colors/blue.js","../../../node_modules/@mui/material/colors/lightBlue.js","../../../node_modules/@mui/material/colors/green.js","../../../node_modules/@mui/material/styles/createPalette.js","../../../node_modules/@mui/material/styles/createTypography.js","../../../node_modules/@mui/material/styles/shadows.js","../../../node_modules/@mui/material/styles/createTransitions.js","../../../node_modules/@mui/material/styles/zIndex.js","../../../node_modules/@mui/material/styles/createTheme.js","../../../node_modules/@mui/material/styles/defaultTheme.js","../../../node_modules/@mui/material/styles/identifier.js","../../../node_modules/@mui/material/styles/useThemeProps.js","../../../node_modules/@mui/material/styles/styled.js","../../../node_modules/@mui/material/SvgIcon/svgIconClasses.js","../../../node_modules/@mui/material/SvgIcon/SvgIcon.js","../../../node_modules/@mui/material/utils/createSvgIcon.js","../../../node_modules/@mui/material/utils/index.js","../../../node_modules/@mui/icons-material/utils/createSvgIcon.js","../../../node_modules/@mui/icons-material/ArrowRight.js","../../../node_modules/@mui/base/utils/isHostComponent.js","../../../node_modules/@mui/base/utils/appendOwnerState.js","../../../node_modules/@mui/base/utils/ClassNameConfigurator.js","../../../node_modules/@mui/base/utils/extractEventHandlers.js","../../../node_modules/@mui/base/utils/resolveComponentProps.js","../../../node_modules/@mui/base/utils/omitEventHandlers.js","../../../node_modules/@mui/base/utils/mergeSlotProps.js","../../../node_modules/@mui/base/utils/useSlotProps.js","../../../node_modules/@mui/base/generateUtilityClass/index.js","../../../node_modules/@mui/base/generateUtilityClasses/index.js","../../../node_modules/@mui/base/Portal/Portal.js","../../../node_modules/@popperjs/core/lib/enums.js","../../../node_modules/@popperjs/core/lib/dom-utils/getNodeName.js","../../../node_modules/@popperjs/core/lib/dom-utils/getWindow.js","../../../node_modules/@popperjs/core/lib/dom-utils/instanceOf.js","../../../node_modules/@popperjs/core/lib/modifiers/applyStyles.js","../../../node_modules/@popperjs/core/lib/utils/getBasePlacement.js","../../../node_modules/@popperjs/core/lib/utils/math.js","../../../node_modules/@popperjs/core/lib/utils/userAgent.js","../../../node_modules/@popperjs/core/lib/dom-utils/isLayoutViewport.js","../../../node_modules/@popperjs/core/lib/dom-utils/getBoundingClientRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/getLayoutRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/contains.js","../../../node_modules/@popperjs/core/lib/dom-utils/getComputedStyle.js","../../../node_modules/@popperjs/core/lib/dom-utils/isTableElement.js","../../../node_modules/@popperjs/core/lib/dom-utils/getDocumentElement.js","../../../node_modules/@popperjs/core/lib/dom-utils/getParentNode.js","../../../node_modules/@popperjs/core/lib/dom-utils/getOffsetParent.js","../../../node_modules/@popperjs/core/lib/utils/getMainAxisFromPlacement.js","../../../node_modules/@popperjs/core/lib/utils/within.js","../../../node_modules/@popperjs/core/lib/utils/getFreshSideObject.js","../../../node_modules/@popperjs/core/lib/utils/mergePaddingObject.js","../../../node_modules/@popperjs/core/lib/utils/expandToHashMap.js","../../../node_modules/@popperjs/core/lib/modifiers/arrow.js","../../../node_modules/@popperjs/core/lib/utils/getVariation.js","../../../node_modules/@popperjs/core/lib/modifiers/computeStyles.js","../../../node_modules/@popperjs/core/lib/modifiers/eventListeners.js","../../../node_modules/@popperjs/core/lib/utils/getOppositePlacement.js","../../../node_modules/@popperjs/core/lib/utils/getOppositeVariationPlacement.js","../../../node_modules/@popperjs/core/lib/dom-utils/getWindowScroll.js","../../../node_modules/@popperjs/core/lib/dom-utils/getWindowScrollBarX.js","../../../node_modules/@popperjs/core/lib/dom-utils/getViewportRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/getDocumentRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/isScrollParent.js","../../../node_modules/@popperjs/core/lib/dom-utils/getScrollParent.js","../../../node_modules/@popperjs/core/lib/dom-utils/listScrollParents.js","../../../node_modules/@popperjs/core/lib/utils/rectToClientRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/getClippingRect.js","../../../node_modules/@popperjs/core/lib/utils/computeOffsets.js","../../../node_modules/@popperjs/core/lib/utils/detectOverflow.js","../../../node_modules/@popperjs/core/lib/utils/computeAutoPlacement.js","../../../node_modules/@popperjs/core/lib/modifiers/flip.js","../../../node_modules/@popperjs/core/lib/modifiers/hide.js","../../../node_modules/@popperjs/core/lib/modifiers/offset.js","../../../node_modules/@popperjs/core/lib/modifiers/popperOffsets.js","../../../node_modules/@popperjs/core/lib/utils/getAltAxis.js","../../../node_modules/@popperjs/core/lib/modifiers/preventOverflow.js","../../../node_modules/@popperjs/core/lib/dom-utils/getHTMLElementScroll.js","../../../node_modules/@popperjs/core/lib/dom-utils/getNodeScroll.js","../../../node_modules/@popperjs/core/lib/dom-utils/getCompositeRect.js","../../../node_modules/@popperjs/core/lib/utils/orderModifiers.js","../../../node_modules/@popperjs/core/lib/utils/debounce.js","../../../node_modules/@popperjs/core/lib/utils/mergeByName.js","../../../node_modules/@popperjs/core/lib/createPopper.js","../../../node_modules/@popperjs/core/lib/popper.js","../../../node_modules/@mui/base/Popper/popperClasses.js","../../../node_modules/@mui/base/Popper/Popper.js","../../../node_modules/@mui/material/styles/useTheme.js","../../../node_modules/@babel/runtime/helpers/esm/setPrototypeOf.js","../../../node_modules/@babel/runtime/helpers/esm/inheritsLoose.js","../../../node_modules/react-transition-group/esm/config.js","../../../node_modules/react-transition-group/esm/utils/PropTypes.js","../../../node_modules/react-transition-group/esm/TransitionGroupContext.js","../../../node_modules/react-transition-group/esm/utils/reflow.js","../../../node_modules/react-transition-group/esm/Transition.js","../../../node_modules/@mui/material/transitions/utils.js","../../../node_modules/@mui/material/Grow/Grow.js","../../../node_modules/@mui/material/Popper/Popper.js","../../../node_modules/@mui/material/Tooltip/tooltipClasses.js","../../../node_modules/@mui/material/Tooltip/Tooltip.js","../src/components/mui/menu-item.component.tsx","../src/components/mui/grouped-menu-item-list.component.tsx","../src/components/mui/top-level-menu.component.tsx","../src/components/mui/grid-menu.component.tsx","../src/hooks/use-promise.hook.ts","../../../node_modules/@mui/icons-material/esm/Menu.js","../src/components/mui/hamburger-menu-button.component.tsx","../src/components/mui/icon-button.component.tsx","../src/components/basics/spinner.component.tsx","../src/components/basics/text-field.component.tsx","../src/components/mui/toolbar.component.tsx","../src/components/shadcn-ui/alert.tsx","../src/components/shadcn-ui/card.tsx","../src/components/shadcn-ui/sonner.tsx","../src/components/shadcn-ui/slider.tsx","../src/components/shadcn-ui/switch.tsx","../src/components/shadcn-ui/tabs.tsx","../src/components/advanced/extension-marketplace/buttons/install-button.component.tsx","../src/components/advanced/extension-marketplace/buttons/enable-button.component.tsx","../src/components/advanced/extension-marketplace/buttons/disable-button.component.tsx","../src/components/advanced/extension-marketplace/buttons/update-button.component.tsx","../src/components/advanced/extension-marketplace/markdown-renderer.component.tsx","../src/components/advanced/extension-marketplace/buttons/filter-button.component.tsx","../src/components/advanced/extension-marketplace/filter-dropdown.component.tsx","../src/components/advanced/extension-marketplace/no-extensions-found.component.tsx","../src/components/advanced/extension-marketplace/more-info.component.tsx","../src/components/advanced/extension-marketplace/version-history.component.tsx","../src/components/advanced/extension-marketplace/footer.component.tsx","../src/hooks/use-event.hook.ts","../src/hooks/use-event-async.hook.ts"],"sourcesContent":["import { type ClassValue, clsx } from 'clsx';\nimport { extendTailwindMerge } from 'tailwind-merge';\n\nconst twMergeCustom = extendTailwindMerge({ prefix: 'tw-' });\n\n/**\n * Tailwind and CSS class application helper function. Uses\n * [`clsx`](https://www.npmjs.com/package/clsx) to make it easy to apply classes conditionally using\n * object syntax, and uses [`tailwind-merge`](https://www.npmjs.com/package/tailwind-merge) to make\n * it easy to merge/overwrite Tailwind classes in a programmer-logic-friendly way.\n *\n * Note: `tailwind-merge` is configured to use the prefix `tw-`, so you must use the same prefix\n * with any Tailwind classes you use with this function to successfully overwrite other Tailwind\n * classes. `platform-bible-react` is configured to use `tw-` as its Tailwind prefix, so any\n * Tailwind classes you pass into `platform-bible-react` components will be compared using the `tw-`\n * prefix.\n *\n * This function was popularized by\n * [shadcn/ui](https://ui.shadcn.com/docs/installation/manual#add-a-cn-helper). See [ByteGrad's\n * explanation video](https://www.youtube.com/watch?v=re2JFITR7TI) for more information.\n *\n * @example\n *\n * ```typescript\n * const borderShouldBeBlue = true;\n * const textShouldBeRed = true;\n * const heightShouldBe20 = false;\n * const classString = cn(\n * 'tw-bg-primary tw-h-10 tw-text-primary-foreground',\n * 'tw-bg-secondary',\n * {\n * 'tw-border-blue-500': borderShouldBeBlue,\n * 'tw-text-red-500': textShouldBeRed,\n * 'tw-h-20': heightShouldBe20,\n * },\n * 'some-class',\n * );\n * ```\n *\n * The resulting `classString` is `'tw-h-10 tw-bg-secondary tw-border-blue-500 tw-text-red-500\n * some-class'`\n *\n * - Notice that `'tw-bg-secondary'`, specified later, overwrote `'tw-bg-primary'`, specified earlier,\n * because they are Tailwind classes that affect the same css property\n * - Notice that `'tw-text-red-500'`, specified later, overwrote `'tw-text-primary-foreground'`,\n * specified earlier, because they are Tailwind classes that affect the same css property\n * - Notice that `'tw-h-20'`, specified later, did not overwrite `'tw-h-10'`, specified earlier,\n * because `'tw-h-20'` is part of a conditional class object and its value evaluated to `false`;\n * therefore it was not applied\n * - Notice that `'some-class'` was applied. This function is not limited only to Tailwind classes.\n *\n *\n * @param inputs Class strings or `clsx` conditional class objects to merge. Tailwind classes\n * specified later in the arguments overwrite similar Tailwind classes specified earlier in the\n * arguments\n * @returns Class string containing all applicable classes from the arguments based on the rules\n * described above\n */\n// shadcn/ui uses this export in its boilerplate code\n// eslint-disable-next-line import/prefer-default-export\nexport function cn(...inputs: ClassValue[]) {\n return twMergeCustom(clsx(inputs));\n}\n","import React from 'react';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport interface InputProps extends React.InputHTMLAttributes {}\n\nexport const Input = React.forwardRef(\n ({ className, type, ...props }, ref) => {\n return (\n \n );\n },\n);\nInput.displayName = 'Input';\n","import { FocusEventHandler, forwardRef, KeyboardEvent, MouseEventHandler } from 'react';\nimport { History } from 'lucide-react';\nimport { Input as ShadInput } from '@/components/shadcn-ui/input';\n\nexport type BookChapterInputProps = {\n handleSearch: (searchString: string) => void;\n handleKeyDown: (event: KeyboardEvent) => void;\n handleOnClick: MouseEventHandler;\n handleSubmit: () => void;\n onFocus?: FocusEventHandler;\n value: string;\n placeholder: string;\n};\n\n// Shadcn Input sets type to \"button\"- HAVE to prop spread before setting type\nconst BookChapterInput = forwardRef(\n (\n { handleSearch, handleKeyDown, handleOnClick, handleSubmit, ...props }: BookChapterInputProps,\n ref,\n ) => {\n return (\n
    \n handleSearch(event.target.value)}\n onKeyDown={(e) => {\n if (e.key === 'Enter') {\n handleSubmit();\n }\n handleKeyDown(e);\n }}\n onClick={handleOnClick}\n ref={ref}\n />\n {\n // eslint-disable-next-line no-console\n console.log('back in history');\n }}\n />\n
    \n );\n },\n);\n\nexport default BookChapterInput;\n","var P = Object.defineProperty;\nvar R = (t, e, s) => e in t ? P(t, e, { enumerable: !0, configurable: !0, writable: !0, value: s }) : t[e] = s;\nvar n = (t, e, s) => R(t, typeof e != \"symbol\" ? e + \"\" : e, s);\nclass _ {\n constructor() {\n n(this, \"books\");\n n(this, \"firstSelectedBookNum\");\n n(this, \"lastSelectedBookNum\");\n n(this, \"count\");\n n(this, \"selectedBookNumbers\");\n n(this, \"selectedBookIds\");\n }\n}\nconst N = [\n \"GEN\",\n \"EXO\",\n \"LEV\",\n \"NUM\",\n \"DEU\",\n \"JOS\",\n \"JDG\",\n \"RUT\",\n \"1SA\",\n \"2SA\",\n // 10\n \"1KI\",\n \"2KI\",\n \"1CH\",\n \"2CH\",\n \"EZR\",\n \"NEH\",\n \"EST\",\n \"JOB\",\n \"PSA\",\n \"PRO\",\n // 20\n \"ECC\",\n \"SNG\",\n \"ISA\",\n \"JER\",\n \"LAM\",\n \"EZK\",\n \"DAN\",\n \"HOS\",\n \"JOL\",\n \"AMO\",\n // 30\n \"OBA\",\n \"JON\",\n \"MIC\",\n \"NAM\",\n \"HAB\",\n \"ZEP\",\n \"HAG\",\n \"ZEC\",\n \"MAL\",\n \"MAT\",\n // 40\n \"MRK\",\n \"LUK\",\n \"JHN\",\n \"ACT\",\n \"ROM\",\n \"1CO\",\n \"2CO\",\n \"GAL\",\n \"EPH\",\n \"PHP\",\n // 50\n \"COL\",\n \"1TH\",\n \"2TH\",\n \"1TI\",\n \"2TI\",\n \"TIT\",\n \"PHM\",\n \"HEB\",\n \"JAS\",\n \"1PE\",\n // 60\n \"2PE\",\n \"1JN\",\n \"2JN\",\n \"3JN\",\n \"JUD\",\n \"REV\",\n \"TOB\",\n \"JDT\",\n \"ESG\",\n \"WIS\",\n // 70\n \"SIR\",\n \"BAR\",\n \"LJE\",\n \"S3Y\",\n \"SUS\",\n \"BEL\",\n \"1MA\",\n \"2MA\",\n \"3MA\",\n \"4MA\",\n // 80\n \"1ES\",\n \"2ES\",\n \"MAN\",\n \"PS2\",\n \"ODA\",\n \"PSS\",\n \"JSA\",\n // actual variant text for JOS, now in LXA text\n \"JDB\",\n // actual variant text for JDG, now in LXA text\n \"TBS\",\n // actual variant text for TOB, now in LXA text\n \"SST\",\n // actual variant text for SUS, now in LXA text // 90\n \"DNT\",\n // actual variant text for DAN, now in LXA text\n \"BLT\",\n // actual variant text for BEL, now in LXA text\n \"XXA\",\n \"XXB\",\n \"XXC\",\n \"XXD\",\n \"XXE\",\n \"XXF\",\n \"XXG\",\n \"FRT\",\n // 100\n \"BAK\",\n \"OTH\",\n \"3ES\",\n // Used previously but really should be 2ES\n \"EZA\",\n // Used to be called 4ES, but not actually in any known project\n \"5EZ\",\n // Used to be called 5ES, but not actually in any known project\n \"6EZ\",\n // Used to be called 6ES, but not actually in any known project\n \"INT\",\n \"CNC\",\n \"GLO\",\n \"TDX\",\n // 110\n \"NDX\",\n \"DAG\",\n \"PS3\",\n \"2BA\",\n \"LBA\",\n \"JUB\",\n \"ENO\",\n \"1MQ\",\n \"2MQ\",\n \"3MQ\",\n // 120\n \"REP\",\n \"4BA\",\n \"LAO\"\n], B = [\n \"XXA\",\n \"XXB\",\n \"XXC\",\n \"XXD\",\n \"XXE\",\n \"XXF\",\n \"XXG\",\n \"FRT\",\n \"BAK\",\n \"OTH\",\n \"INT\",\n \"CNC\",\n \"GLO\",\n \"TDX\",\n \"NDX\"\n], O = [\n \"Genesis\",\n \"Exodus\",\n \"Leviticus\",\n \"Numbers\",\n \"Deuteronomy\",\n \"Joshua\",\n \"Judges\",\n \"Ruth\",\n \"1 Samuel\",\n \"2 Samuel\",\n \"1 Kings\",\n \"2 Kings\",\n \"1 Chronicles\",\n \"2 Chronicles\",\n \"Ezra\",\n \"Nehemiah\",\n \"Esther (Hebrew)\",\n \"Job\",\n \"Psalms\",\n \"Proverbs\",\n \"Ecclesiastes\",\n \"Song of Songs\",\n \"Isaiah\",\n \"Jeremiah\",\n \"Lamentations\",\n \"Ezekiel\",\n \"Daniel (Hebrew)\",\n \"Hosea\",\n \"Joel\",\n \"Amos\",\n \"Obadiah\",\n \"Jonah\",\n \"Micah\",\n \"Nahum\",\n \"Habakkuk\",\n \"Zephaniah\",\n \"Haggai\",\n \"Zechariah\",\n \"Malachi\",\n \"Matthew\",\n \"Mark\",\n \"Luke\",\n \"John\",\n \"Acts\",\n \"Romans\",\n \"1 Corinthians\",\n \"2 Corinthians\",\n \"Galatians\",\n \"Ephesians\",\n \"Philippians\",\n \"Colossians\",\n \"1 Thessalonians\",\n \"2 Thessalonians\",\n \"1 Timothy\",\n \"2 Timothy\",\n \"Titus\",\n \"Philemon\",\n \"Hebrews\",\n \"James\",\n \"1 Peter\",\n \"2 Peter\",\n \"1 John\",\n \"2 John\",\n \"3 John\",\n \"Jude\",\n \"Revelation\",\n \"Tobit\",\n \"Judith\",\n \"Esther Greek\",\n \"Wisdom of Solomon\",\n \"Sirach (Ecclesiasticus)\",\n \"Baruch\",\n \"Letter of Jeremiah\",\n \"Song of 3 Young Men\",\n \"Susanna\",\n \"Bel and the Dragon\",\n \"1 Maccabees\",\n \"2 Maccabees\",\n \"3 Maccabees\",\n \"4 Maccabees\",\n \"1 Esdras (Greek)\",\n \"2 Esdras (Latin)\",\n \"Prayer of Manasseh\",\n \"Psalm 151\",\n \"Odes\",\n \"Psalms of Solomon\",\n // WARNING, if you change the spelling of the *obsolete* tag be sure to update\n // IsObsolete routine\n \"Joshua A. *obsolete*\",\n \"Judges B. *obsolete*\",\n \"Tobit S. *obsolete*\",\n \"Susanna Th. *obsolete*\",\n \"Daniel Th. *obsolete*\",\n \"Bel Th. *obsolete*\",\n \"Extra A\",\n \"Extra B\",\n \"Extra C\",\n \"Extra D\",\n \"Extra E\",\n \"Extra F\",\n \"Extra G\",\n \"Front Matter\",\n \"Back Matter\",\n \"Other Matter\",\n \"3 Ezra *obsolete*\",\n \"Apocalypse of Ezra\",\n \"5 Ezra (Latin Prologue)\",\n \"6 Ezra (Latin Epilogue)\",\n \"Introduction\",\n \"Concordance \",\n \"Glossary \",\n \"Topical Index\",\n \"Names Index\",\n \"Daniel Greek\",\n \"Psalms 152-155\",\n \"2 Baruch (Apocalypse)\",\n \"Letter of Baruch\",\n \"Jubilees\",\n \"Enoch\",\n \"1 Meqabyan\",\n \"2 Meqabyan\",\n \"3 Meqabyan\",\n \"Reproof (Proverbs 25-31)\",\n \"4 Baruch (Rest of Baruch)\",\n \"Laodiceans\"\n], S = K();\nfunction g(t, e = !0) {\n return e && (t = t.toUpperCase()), t in S ? S[t] : 0;\n}\nfunction k(t) {\n return g(t) > 0;\n}\nfunction x(t) {\n const e = typeof t == \"string\" ? g(t) : t;\n return e >= 40 && e <= 66;\n}\nfunction T(t) {\n return (typeof t == \"string\" ? g(t) : t) <= 39;\n}\nfunction X(t) {\n return t <= 66;\n}\nfunction V(t) {\n const e = typeof t == \"string\" ? g(t) : t;\n return w(e) && !X(e);\n}\nfunction* L() {\n for (let t = 1; t <= N.length; t++) yield t;\n}\nconst G = 1, A = N.length;\nfunction H() {\n return [\"XXA\", \"XXB\", \"XXC\", \"XXD\", \"XXE\", \"XXF\", \"XXG\"];\n}\nfunction C(t, e = \"***\") {\n const s = t - 1;\n return s < 0 || s >= N.length ? e : N[s];\n}\nfunction I(t) {\n return t <= 0 || t > A ? \"******\" : O[t - 1];\n}\nfunction y(t) {\n return I(g(t));\n}\nfunction w(t) {\n const e = typeof t == \"number\" ? C(t) : t;\n return k(e) && !B.includes(e);\n}\nfunction q(t) {\n const e = typeof t == \"number\" ? C(t) : t;\n return k(e) && B.includes(e);\n}\nfunction U(t) {\n return O[t - 1].includes(\"*obsolete*\");\n}\nfunction K() {\n const t = {};\n for (let e = 0; e < N.length; e++)\n t[N[e]] = e + 1;\n return t;\n}\nconst m = {\n allBookIds: N,\n nonCanonicalIds: B,\n bookIdToNumber: g,\n isBookIdValid: k,\n isBookNT: x,\n isBookOT: T,\n isBookOTNT: X,\n isBookDC: V,\n allBookNumbers: L,\n firstBook: G,\n lastBook: A,\n extraBooks: H,\n bookNumberToId: C,\n bookNumberToEnglishName: I,\n bookIdToEnglishName: y,\n isCanonical: w,\n isExtraMaterial: q,\n isObsolete: U\n};\nvar l = /* @__PURE__ */ ((t) => (t[t.Unknown = 0] = \"Unknown\", t[t.Original = 1] = \"Original\", t[t.Septuagint = 2] = \"Septuagint\", t[t.Vulgate = 3] = \"Vulgate\", t[t.English = 4] = \"English\", t[t.RussianProtestant = 5] = \"RussianProtestant\", t[t.RussianOrthodox = 6] = \"RussianOrthodox\", t))(l || {});\nconst h = class h {\n // private versInfo: Versification;\n constructor(e) {\n n(this, \"name\");\n n(this, \"fullPath\");\n n(this, \"isPresent\");\n n(this, \"hasVerseSegments\");\n n(this, \"isCustomized\");\n n(this, \"baseVersification\");\n n(this, \"scriptureBooks\");\n n(this, \"_type\");\n if (e == null)\n throw new Error(\"Argument undefined\");\n typeof e == \"string\" ? (this.name = e, this._type = l[e]) : (this._type = e, this.name = l[e]);\n }\n get type() {\n return this._type;\n }\n equals(e) {\n return !e.type || !this.type ? !1 : e.type === this.type;\n }\n};\nn(h, \"Original\", new h(l.Original)), n(h, \"Septuagint\", new h(l.Septuagint)), n(h, \"Vulgate\", new h(l.Vulgate)), n(h, \"English\", new h(l.English)), n(h, \"RussianProtestant\", new h(l.RussianProtestant)), n(h, \"RussianOrthodox\", new h(l.RussianOrthodox));\nlet c = h;\nfunction E(t, e) {\n const s = e[0];\n for (let r = 1; r < e.length; r++)\n t = t.split(e[r]).join(s);\n return t.split(s);\n}\nvar D = /* @__PURE__ */ ((t) => (t[t.Valid = 0] = \"Valid\", t[t.UnknownVersification = 1] = \"UnknownVersification\", t[t.OutOfRange = 2] = \"OutOfRange\", t[t.VerseOutOfOrder = 3] = \"VerseOutOfOrder\", t[t.VerseRepeated = 4] = \"VerseRepeated\", t))(D || {});\nconst i = class i {\n constructor(e, s, r, a) {\n /** Not yet implemented. */\n n(this, \"firstChapter\");\n /** Not yet implemented. */\n n(this, \"lastChapter\");\n /** Not yet implemented. */\n n(this, \"lastVerse\");\n /** Not yet implemented. */\n n(this, \"hasSegmentsDefined\");\n /** Not yet implemented. */\n n(this, \"text\");\n /** Not yet implemented. */\n n(this, \"BBBCCCVVVS\");\n /** Not yet implemented. */\n n(this, \"longHashCode\");\n /** The versification of the reference. */\n n(this, \"versification\");\n n(this, \"rtlMark\", \"‏\");\n n(this, \"_bookNum\", 0);\n n(this, \"_chapterNum\", 0);\n n(this, \"_verseNum\", 0);\n n(this, \"_verse\");\n if (r == null && a == null)\n if (e != null && typeof e == \"string\") {\n const o = e, u = s != null && s instanceof c ? s : void 0;\n this.setEmpty(u), this.parse(o);\n } else if (e != null && typeof e == \"number\") {\n const o = s != null && s instanceof c ? s : void 0;\n this.setEmpty(o), this._verseNum = e % i.chapterDigitShifter, this._chapterNum = Math.floor(\n e % i.bookDigitShifter / i.chapterDigitShifter\n ), this._bookNum = Math.floor(e / i.bookDigitShifter);\n } else if (s == null)\n if (e != null && e instanceof i) {\n const o = e;\n this._bookNum = o.bookNum, this._chapterNum = o.chapterNum, this._verseNum = o.verseNum, this._verse = o.verse, this.versification = o.versification;\n } else {\n if (e == null) return;\n const o = e instanceof c ? e : i.defaultVersification;\n this.setEmpty(o);\n }\n else\n throw new Error(\"VerseRef constructor not supported.\");\n else if (e != null && s != null && r != null)\n if (typeof e == \"string\" && typeof s == \"string\" && typeof r == \"string\")\n this.setEmpty(a), this.updateInternal(e, s, r);\n else if (typeof e == \"number\" && typeof s == \"number\" && typeof r == \"number\")\n this._bookNum = e, this._chapterNum = s, this._verseNum = r, this.versification = a ?? i.defaultVersification;\n else\n throw new Error(\"VerseRef constructor not supported.\");\n else\n throw new Error(\"VerseRef constructor not supported.\");\n }\n /**\n * Determines if the verse string is in a valid format (does not consider versification).\n */\n static isVerseParseable(e) {\n return e.length > 0 && \"0123456789\".includes(e[0]) && !e.endsWith(this.verseRangeSeparator) && !e.endsWith(this.verseSequenceIndicator);\n }\n /**\n * Tries to parse the specified string into a verse reference.\n * @param str - The string to attempt to parse.\n * @returns success: `true` if the specified string was successfully parsed, `false` otherwise.\n * @returns verseRef: The result of the parse if successful, or empty VerseRef if it failed\n */\n static tryParse(e) {\n let s;\n try {\n return s = new i(e), { success: !0, verseRef: s };\n } catch (r) {\n if (r instanceof v)\n return s = new i(), { success: !1, verseRef: s };\n throw r;\n }\n }\n /**\n * Gets the reference as a comparable integer where the book, chapter, and verse each occupy 3\n * digits.\n * @param bookNum - Book number (this is 1-based, not an index).\n * @param chapterNum - Chapter number.\n * @param verseNum - Verse number.\n * @returns The reference as a comparable integer where the book, chapter, and verse each occupy 3\n * digits.\n */\n static getBBBCCCVVV(e, s, r) {\n return e % i.bcvMaxValue * i.bookDigitShifter + (s >= 0 ? s % i.bcvMaxValue * i.chapterDigitShifter : 0) + (r >= 0 ? r % i.bcvMaxValue : 0);\n }\n /**\n * Deserializes a serialized VerseRef.\n * @param serializedVerseRef - Serialized VerseRef to create from.\n * @returns the deserialized VerseRef.\n */\n static fromJSON(e) {\n const { book: s, chapterNum: r, verseNum: a, verse: o, versificationStr: u } = e, f = o || a.toString();\n let d;\n return u && (d = new c(u)), s ? new i(s, r.toString(), f, d) : new i();\n }\n /**\n * Parses a verse string and gets the leading numeric portion as a number.\n * @param verseStr - verse string to parse\n * @returns true if the entire string could be parsed as a single, simple verse number (1-999);\n * false if the verse string represented a verse bridge, contained segment letters, or was invalid\n */\n static tryGetVerseNum(e) {\n let s;\n if (!e)\n return s = -1, { success: !0, vNum: s };\n s = 0;\n let r;\n for (let a = 0; a < e.length; a++) {\n if (r = e[a], r < \"0\" || r > \"9\")\n return a === 0 && (s = -1), { success: !1, vNum: s };\n if (s = s * 10 + +r - 0, s > i.bcvMaxValue)\n return s = -1, { success: !1, vNum: s };\n }\n return { success: !0, vNum: s };\n }\n /**\n * Checks to see if a VerseRef hasn't been set - all values are the default.\n */\n get isDefault() {\n return this.bookNum === 0 && this.chapterNum === 0 && this.verseNum === 0 && this.versification == null;\n }\n /**\n * Gets whether the verse contains multiple verses.\n */\n get hasMultiple() {\n return this._verse != null && (this._verse.includes(i.verseRangeSeparator) || this._verse.includes(i.verseSequenceIndicator));\n }\n /**\n * Gets or sets the book of the reference. Book is the 3-letter abbreviation in capital letters,\n * e.g. `'MAT'`.\n */\n get book() {\n return m.bookNumberToId(this.bookNum, \"\");\n }\n set book(e) {\n this.bookNum = m.bookIdToNumber(e);\n }\n /**\n * Gets or sets the chapter of the reference,. e.g. `'3'`.\n */\n get chapter() {\n return this.isDefault || this._chapterNum < 0 ? \"\" : this._chapterNum.toString();\n }\n set chapter(e) {\n const s = +e;\n this._chapterNum = Number.isInteger(s) ? s : -1;\n }\n /**\n * Gets or sets the verse of the reference, including range, segments, and sequences, e.g. `'4'`,\n * or `'4b-5a, 7'`.\n */\n get verse() {\n return this._verse != null ? this._verse : this.isDefault || this._verseNum < 0 ? \"\" : this._verseNum.toString();\n }\n set verse(e) {\n const { success: s, vNum: r } = i.tryGetVerseNum(e);\n this._verse = s ? void 0 : e.replace(this.rtlMark, \"\"), this._verseNum = r, !(this._verseNum >= 0) && ({ vNum: this._verseNum } = i.tryGetVerseNum(this._verse));\n }\n /**\n * Get or set Book based on book number, e.g. `42`.\n */\n get bookNum() {\n return this._bookNum;\n }\n set bookNum(e) {\n if (e <= 0 || e > m.lastBook)\n throw new v(\n \"BookNum must be greater than zero and less than or equal to last book\"\n );\n this._bookNum = e;\n }\n /**\n * Gets or sets the chapter number, e.g. `3`. `-1` if not valid.\n */\n get chapterNum() {\n return this._chapterNum;\n }\n set chapterNum(e) {\n this.chapterNum = e;\n }\n /**\n * Gets or sets verse start number, e.g. `4`. `-1` if not valid.\n */\n get verseNum() {\n return this._verseNum;\n }\n set verseNum(e) {\n this._verseNum = e;\n }\n /**\n * String representing the versification (should ONLY be used for serialization/deserialization).\n *\n * @remarks This is for backwards compatibility when ScrVers was an enumeration.\n */\n get versificationStr() {\n var e;\n return (e = this.versification) == null ? void 0 : e.name;\n }\n set versificationStr(e) {\n this.versification = this.versification != null ? new c(e) : void 0;\n }\n /**\n * Determines if the reference is valid.\n */\n get valid() {\n return this.validStatus === 0;\n }\n /**\n * Get the valid status for this reference.\n */\n get validStatus() {\n return this.validateVerse(i.verseRangeSeparators, i.verseSequenceIndicators);\n }\n /**\n * Gets the reference as a comparable integer where the book,\n * chapter, and verse each occupy three digits and the verse is 0.\n */\n get BBBCCC() {\n return i.getBBBCCCVVV(this._bookNum, this._chapterNum, 0);\n }\n /**\n * Gets the reference as a comparable integer where the book,\n * chapter, and verse each occupy three digits. If verse is not null\n * (i.e., this reference represents a complex reference with verse\n * segments or bridge) this cannot be used for an exact comparison.\n */\n get BBBCCCVVV() {\n return i.getBBBCCCVVV(this._bookNum, this._chapterNum, this._verseNum);\n }\n /**\n * Gets whether the verse is defined as an excluded verse in the versification.\n * Does not handle verse ranges.\n */\n // eslint-disable-next-line @typescript-eslint/class-literal-property-style\n get isExcluded() {\n return !1;\n }\n /**\n * Parses the reference in the specified string.\n * Optionally versification can follow reference as in GEN 3:11/4\n * Throw an exception if\n * - invalid book name\n * - chapter number is missing or not a number\n * - verse number is missing or does not start with a number\n * - versification is invalid\n * @param verseStr - string to parse e.g. 'MAT 3:11'\n */\n parse(e) {\n if (e = e.replace(this.rtlMark, \"\"), e.includes(\"/\")) {\n const o = e.split(\"/\");\n if (e = o[0], o.length > 1)\n try {\n const u = +o[1].trim();\n this.versification = new c(l[u]);\n } catch {\n throw new v(\"Invalid reference : \" + e);\n }\n }\n const s = e.trim().split(\" \");\n if (s.length !== 2)\n throw new v(\"Invalid reference : \" + e);\n const r = s[1].split(\":\"), a = +r[0];\n if (r.length !== 2 || m.bookIdToNumber(s[0]) === 0 || !Number.isInteger(a) || a < 0 || !i.isVerseParseable(r[1]))\n throw new v(\"Invalid reference : \" + e);\n this.updateInternal(s[0], r[0], r[1]);\n }\n /**\n * Simplifies this verse ref so that it has no bridging of verses or\n * verse segments like `'1a'`.\n */\n simplify() {\n this._verse = void 0;\n }\n /**\n * Makes a clone of the reference.\n *\n * @returns The cloned VerseRef.\n */\n clone() {\n return new i(this);\n }\n toString() {\n const e = this.book;\n return e === \"\" ? \"\" : `${e} ${this.chapter}:${this.verse}`;\n }\n toJSON() {\n let e = this.verse;\n (e === \"\" || e === this.verseNum.toString()) && (e = void 0);\n const s = {\n book: this.book,\n chapterNum: this.chapterNum,\n verseNum: this.verseNum,\n verse: e,\n versificationStr: this.versificationStr\n };\n return e || delete s.verse, s;\n }\n /**\n * Compares this `VerseRef` with supplied one.\n * @param verseRef - object to compare this one to.\n * @returns `true` if this `VerseRef` is equal to the supplied one, `false` otherwise.\n */\n equals(e) {\n return e instanceof i ? e._bookNum === this._bookNum && e._chapterNum === this._chapterNum && e._verseNum === this._verseNum && e.verse === this.verse && (e.versification == null && this.versification == null || e.versification != null && this.versification != null && e.versification.equals(this.versification)) : !1;\n }\n /**\n * Enumerate all individual verses contained in a VerseRef.\n * Verse ranges are indicated by \"-\" and consecutive verses by \",\"s.\n * Examples:\n * GEN 1:2 returns GEN 1:2\n * GEN 1:1a-3b,5 returns GEN 1:1a, GEN 1:2, GEN 1:3b, GEN 1:5\n * GEN 1:2a-2c returns //! ??????\n *\n * @param specifiedVersesOnly - if set to true return only verses that are\n * explicitly specified only, not verses within a range. Defaults to `false`.\n * @param verseRangeSeparators - Verse range separators.\n * Defaults to `VerseRef.verseRangeSeparators`.\n * @param verseSequenceSeparators - Verse sequence separators.\n * Defaults to `VerseRef.verseSequenceIndicators`.\n * @returns An array of all single verse references in this VerseRef.\n */\n allVerses(e = !1, s = i.verseRangeSeparators, r = i.verseSequenceIndicators) {\n if (this._verse == null || this.chapterNum <= 0)\n return [this.clone()];\n const a = [], o = E(this._verse, r);\n for (const u of o.map((f) => E(f, s))) {\n const f = this.clone();\n f.verse = u[0];\n const d = f.verseNum;\n if (a.push(f), u.length > 1) {\n const b = this.clone();\n if (b.verse = u[1], !e)\n for (let p = d + 1; p < b.verseNum; p++) {\n const J = new i(\n this._bookNum,\n this._chapterNum,\n p,\n this.versification\n );\n this.isExcluded || a.push(J);\n }\n a.push(b);\n }\n }\n return a;\n }\n /**\n * Validates a verse number using the supplied separators rather than the defaults.\n */\n validateVerse(e, s) {\n if (!this.verse)\n return this.internalValid;\n let r = 0;\n for (const a of this.allVerses(!0, e, s)) {\n const o = a.internalValid;\n if (o !== 0)\n return o;\n const u = a.BBBCCCVVV;\n if (r > u)\n return 3;\n if (r === u)\n return 4;\n r = u;\n }\n return 0;\n }\n /**\n * Gets whether a single verse reference is valid.\n */\n get internalValid() {\n return this.versification == null ? 1 : this._bookNum <= 0 || this._bookNum > m.lastBook ? 2 : (m.isCanonical(this._bookNum), 0);\n }\n setEmpty(e = i.defaultVersification) {\n this._bookNum = 0, this._chapterNum = -1, this._verse = void 0, this.versification = e;\n }\n updateInternal(e, s, r) {\n this.bookNum = m.bookIdToNumber(e), this.chapter = s, this.verse = r;\n }\n};\nn(i, \"defaultVersification\", c.English), n(i, \"verseRangeSeparator\", \"-\"), n(i, \"verseSequenceIndicator\", \",\"), n(i, \"verseRangeSeparators\", [i.verseRangeSeparator]), n(i, \"verseSequenceIndicators\", [i.verseSequenceIndicator]), n(i, \"chapterDigitShifter\", 1e3), n(i, \"bookDigitShifter\", i.chapterDigitShifter * i.chapterDigitShifter), n(i, \"bcvMaxValue\", i.chapterDigitShifter - 1), /**\n * The valid status of the VerseRef.\n */\nn(i, \"ValidStatusType\", D);\nlet M = i;\nclass v extends Error {\n}\nexport {\n _ as BookSet,\n m as Canon,\n c as ScrVers,\n l as ScrVersType,\n M as VerseRef,\n v as VerseRefException\n};\n//# sourceMappingURL=index.es.js.map\n","import React from 'react';\nimport * as DropdownMenuPrimitive from '@radix-ui/react-dropdown-menu';\nimport { Check, ChevronRight, Circle } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport const DropdownMenu = DropdownMenuPrimitive.Root;\n\nexport const DropdownMenuTrigger = DropdownMenuPrimitive.Trigger;\n\nexport const DropdownMenuGroup = DropdownMenuPrimitive.Group;\n\nexport const DropdownMenuPortal = DropdownMenuPrimitive.Portal;\n\nexport const DropdownMenuSub = DropdownMenuPrimitive.Sub;\n\nexport const DropdownMenuRadioGroup = DropdownMenuPrimitive.RadioGroup;\n\nexport type DropdownMenuSubTriggerProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.SubTrigger\n> & {\n className?: string;\n inset?: boolean;\n};\n\nexport type DropdownMenuSubContentProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.SubContent\n> & {\n className?: string;\n};\n\nexport type DropdownMenuContentProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Content\n> & {\n className?: string;\n sideOffset?: number;\n};\n\nexport type DropdownMenuItemProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Item\n> & {\n className?: string;\n inset?: boolean;\n};\n\nexport type DropdownMenuCheckboxItemProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.CheckboxItem\n> & {\n className?: string;\n checked?: boolean;\n};\n\nexport type DropdownMenuRadioItemProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.RadioItem\n> & {\n className?: string;\n};\n\nexport type DropdownMenuLabelProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Label\n> & {\n className?: string;\n inset?: boolean;\n};\n\nexport type DropdownMenuSeparatorProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Separator\n> & {\n className?: string;\n};\n\nexport type DropdownMenuShortcutProps = React.HTMLAttributes & {\n className?: string;\n};\n\nexport const DropdownMenuSubTrigger = React.forwardRef<\n React.ElementRef,\n DropdownMenuSubTriggerProps\n>(({ className, inset, children, ...props }, ref) => (\n \n {children}\n \n \n));\nDropdownMenuSubTrigger.displayName = DropdownMenuPrimitive.SubTrigger.displayName;\n\nexport const DropdownMenuSubContent = React.forwardRef<\n React.ElementRef,\n DropdownMenuSubContentProps\n>(({ className, ...props }, ref) => (\n \n));\nDropdownMenuSubContent.displayName = DropdownMenuPrimitive.SubContent.displayName;\n\nexport const DropdownMenuContent = React.forwardRef<\n React.ElementRef,\n DropdownMenuContentProps\n>(({ className, sideOffset = 4, ...props }, ref) => (\n \n \n \n));\nDropdownMenuContent.displayName = DropdownMenuPrimitive.Content.displayName;\n\n/**\n * TODO: fix: direction is not automatically handled by this component, so that shortcuts are\n * display always to the right\n */\nexport const DropdownMenuItem = React.forwardRef<\n React.ElementRef,\n DropdownMenuItemProps\n>(({ className, inset, ...props }, ref) => (\n \n));\nDropdownMenuItem.displayName = DropdownMenuPrimitive.Item.displayName;\n\nexport const DropdownMenuCheckboxItem = React.forwardRef<\n React.ElementRef,\n DropdownMenuCheckboxItemProps\n>(({ className, children, checked, ...props }, ref) => (\n \n \n \n \n \n \n {children}\n \n));\nDropdownMenuCheckboxItem.displayName = DropdownMenuPrimitive.CheckboxItem.displayName;\n\nexport const DropdownMenuRadioItem = React.forwardRef<\n React.ElementRef,\n DropdownMenuRadioItemProps\n>(({ className, children, ...props }, ref) => (\n \n \n \n \n \n \n {children}\n \n));\nDropdownMenuRadioItem.displayName = DropdownMenuPrimitive.RadioItem.displayName;\n\nexport const DropdownMenuLabel = React.forwardRef<\n React.ElementRef,\n DropdownMenuLabelProps\n>(({ className, inset, ...props }, ref) => (\n \n));\nDropdownMenuLabel.displayName = DropdownMenuPrimitive.Label.displayName;\n\nexport const DropdownMenuSeparator = React.forwardRef<\n React.ElementRef,\n DropdownMenuSeparatorProps\n>(({ className, ...props }, ref) => (\n \n));\nDropdownMenuSeparator.displayName = DropdownMenuPrimitive.Separator.displayName;\n\nexport function DropdownMenuShortcut({ className, ...props }: DropdownMenuShortcutProps) {\n return (\n \n );\n}\nDropdownMenuShortcut.displayName = 'DropdownMenuShortcut';\n","import { Canon } from '@sillsdev/scripture';\nimport { PropsWithChildren, KeyboardEvent, forwardRef } from 'react';\nimport { DropdownMenuItem as ShadDropdownMenuItem } from '@/components/shadcn-ui/dropdown-menu';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport type BookType = 'OT' | 'NT' | 'DC';\n\ntype BookMenuItemProps = PropsWithChildren<{\n /** String id of book */\n bookId: string;\n /** Callback to run when a book menu item is selected */\n handleSelectBook: () => void;\n /** Indicates if this menu item is currently selected */\n isSelected: boolean;\n /** Function that is called upon highlighting a book in the dropdown menu */\n handleHighlightBook: () => void;\n /**\n * Function that is called on pressing a key\n *\n * @param event Event that contains information about the key stroke\n */\n handleKeyDown: (event: KeyboardEvent) => void;\n /**\n * Type of book associated with this menu item, coordinates color labels ? Mock up has the labels\n * coordinated to genre\n */\n bookType: BookType;\n}>;\n\nconst BookMenuItem = forwardRef(\n (\n {\n bookId,\n handleSelectBook,\n isSelected,\n handleHighlightBook,\n handleKeyDown,\n bookType,\n children,\n }: BookMenuItemProps,\n ref,\n ) => {\n return (\n {\n // preventDefault() here prevents the entire dropdown menu from closing when selecting this item\n event.preventDefault();\n handleSelectBook();\n }}\n onKeyDown={(event: KeyboardEvent) => {\n handleKeyDown(event);\n }}\n onFocus={handleHighlightBook}\n onMouseMove={handleHighlightBook}\n >\n \n {Canon.bookIdToEnglishName(bookId)}\n \n {isSelected &&
    {children}
    }\n \n );\n },\n);\n\nexport default BookMenuItem;\n","import { cn } from '@/utils/shadcn-ui.util';\nimport { useCallback } from 'react';\n\nexport type ChapterSelectProps = {\n /**\n * Callback to run when a chapter div is selected\n *\n * @param chapterNumber Number of the chapter that has been selected\n */\n handleSelectChapter: (chapterNumber: number) => void;\n /** The highest chapter number in the book (of course equal to number of chapters in the book) */\n endChapter: number;\n /** The chapter number that is currently selected */\n activeChapter: number;\n /** The chapter number that is currently highlighted using keyboard or mouse navigation */\n highlightedChapter: number;\n /**\n * Callback to run when a chapter is highlighted by the user\n *\n * @param chapterNumber The chapter that is highlighted\n */\n handleHighlightedChapter: (chapterNumber: number) => void;\n};\n\nfunction ChapterSelect({\n handleSelectChapter,\n endChapter,\n activeChapter,\n highlightedChapter,\n handleHighlightedChapter,\n}: ChapterSelectProps) {\n const chapters = Array.from({ length: endChapter }, (_, i) => i + 1);\n\n const handleMouse = useCallback(\n (chapterNumber: number) => {\n handleHighlightedChapter(chapterNumber);\n },\n [handleHighlightedChapter],\n );\n\n return (\n
    \n {chapters.map((chapter) => (\n {\n event.preventDefault();\n event.stopPropagation();\n handleSelectChapter(chapter);\n }}\n role=\"button\"\n onKeyDown={(event) => {\n if (event.key === 'Enter') {\n handleSelectChapter(chapter);\n }\n }}\n tabIndex={0}\n onMouseMove={() => handleMouse(chapter)}\n >\n {chapter}\n
    \n ))}\n
    \n );\n}\n\nexport default ChapterSelect;\n","import { DropdownMenuLabel as ShadDropdownMenuLabel } from '@/components/shadcn-ui/dropdown-menu';\nimport { Bookmark, Clock, ArrowDownWideNarrow } from 'lucide-react';\n\nexport type GoToMenuItemProps = {\n handleSort: () => void;\n handleLocationHistory: () => void;\n handleBookmarks: () => void;\n};\n\nfunction GoToMenuItem({ handleSort, handleLocationHistory, handleBookmarks }: GoToMenuItemProps) {\n return (\n \n

    Go To

    \n
    \n \n \n \n
    \n
    \n );\n}\n\nexport default GoToMenuItem;\n","import BookChapterInput from '@/components/advanced/book-chapter-control/book-chapter-input.component';\nimport BookMenuItem, {\n BookType,\n} from '@/components/advanced/book-chapter-control/book-menu-item.component';\nimport ChapterSelect from '@/components/advanced/book-chapter-control/chapter-select.component';\nimport GoToMenuItem from '@/components/advanced/book-chapter-control/go-to-menu-item.component';\nimport {\n DropdownMenu as ShadDropdownMenu,\n DropdownMenuContent as ShadDropdownMenuContent,\n DropdownMenuLabel as ShadDropdownMenuLabel,\n DropdownMenuSeparator as ShadDropdownMenuSeparator,\n DropdownMenuTrigger as ShadDropdownMenuTrigger,\n} from '@/components/shadcn-ui/dropdown-menu';\nimport { Canon } from '@sillsdev/scripture';\nimport { ScriptureReference, getChaptersForBook } from 'platform-bible-utils';\nimport {\n KeyboardEvent as ReactKeyboardEvent,\n useCallback,\n useEffect,\n useLayoutEffect,\n useRef,\n useState,\n} from 'react';\n\ntype BookTypeLabels = {\n [bookType in BookType]: string;\n};\ntype BookChapterControlProps = {\n scrRef: ScriptureReference;\n handleSubmit: (scrRef: ScriptureReference) => void;\n};\n\nconst ALL_BOOK_IDS = Canon.allBookIds;\nconst BOOK_TYPE_LABELS: BookTypeLabels = {\n OT: 'Old Testament',\n NT: 'New Testament',\n DC: 'Deuterocanon',\n};\nconst BOOK_TYPE_ARRAY: BookType[] = ['OT', 'NT', 'DC'];\n// This is the height of three menu items to offset scrolling to the selected menu item\n// If you use menuItemRef.clientHeight- includes height of chapter div which is too big\nconst SCROLL_OFFSET = 32 + 32 + 32;\nconst SEARCH_QUERY_FORMATS = [\n /^(\\w+)$/i, // Matches a single word (book name or id)\n /^(\\w+)(?:\\s(\\d+))$/i, // Matches a word followed by a chapter number\n /^(\\w+)(?:\\s(\\d+):(\\d+))$/i, // Matches a word followed by a chapter and verse number\n];\nconst fetchGroupedBooks = (bookType: BookType) => {\n const groupedBooks = {\n OT: ALL_BOOK_IDS.filter((bookId) => Canon.isBookOT(bookId)),\n NT: ALL_BOOK_IDS.filter((bookId) => Canon.isBookNT(bookId)),\n DC: ALL_BOOK_IDS.filter((bookId) => Canon.isBookDC(bookId)),\n };\n return groupedBooks[bookType];\n};\nconst fetchEndChapter = (bookId: string) => {\n // getChaptersForBook returns -1 if not found in scrBookData\n // scrBookData only includes OT and NT, so all DC will return -1\n return getChaptersForBook(Canon.bookIdToNumber(bookId));\n};\n\n/**\n * Gets all of the English names from book ids\n *\n * @returns String[]\n */\nfunction getAllEnglishNames(): string[] {\n const allEnglishNames = ALL_BOOK_IDS.map((bookId) => {\n return Canon.bookIdToEnglishName(bookId);\n });\n return allEnglishNames;\n}\n\n/**\n * Determines if bookName is in allEnglishNames\n *\n * @param bookName Book English name\n * @returns True if bookName is included, false otherwise\n */\nfunction isValidBookEnglishName(bookName: string): boolean {\n return getAllEnglishNames().includes(bookName);\n}\n\n/**\n * Gets a bookId from given English name\n *\n * @param bookName Book English name\n * @returns BookId of provided bookName, undefined otherwise\n */\nfunction getBookIdFromEnglishName(bookName: string): string | undefined {\n // Convert bookName to lowercase and then capitalize the first letter\n const formattedBookName = bookName.toLowerCase().replace(/^\\w/, (c) => c.toUpperCase());\n\n if (isValidBookEnglishName(formattedBookName)) {\n const matchingBookId = ALL_BOOK_IDS.find((bookId) => {\n return Canon.bookIdToEnglishName(bookId) === formattedBookName;\n });\n return matchingBookId;\n }\n\n return undefined;\n}\n\nfunction BookChapterControl({ scrRef, handleSubmit }: BookChapterControlProps) {\n const [searchQuery, setSearchQuery] = useState('');\n const [selectedBookId, setSelectedBookId] = useState(\n Canon.bookNumberToId(scrRef.bookNum),\n );\n const [highlightedChapter, setHighlightedChapter] = useState(scrRef.chapterNum ?? 0);\n const [highlightedBookId, setHighlightedBookId] = useState(\n Canon.bookNumberToId(scrRef.bookNum),\n );\n const [isContentOpen, setIsContentOpen] = useState(false);\n const [isContentOpenDelayed, setIsContentOpenDelayed] = useState(isContentOpen);\n\n // This ref will always be defined\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const inputRef = useRef(undefined!);\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const contentRef = useRef(undefined!);\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const menuItemRef = useRef(undefined!);\n\n const fetchFilteredBooks = useCallback(\n (bookType: BookType) => {\n return fetchGroupedBooks(bookType).filter((bookId: string) => {\n const englishNameLowerCase = Canon.bookIdToEnglishName(bookId).toLowerCase();\n const normalizedQuery = searchQuery.replace(/[^a-zA-Z]/g, '').toLowerCase();\n return (\n englishNameLowerCase.includes(normalizedQuery) || // Match book name\n bookId.toLowerCase().includes(normalizedQuery) // Match book ID\n );\n });\n },\n [searchQuery],\n );\n\n const handleSearchInput = (searchString: string) => {\n setSearchQuery(searchString);\n };\n\n /**\n * Whether to prevent radix's logic from closing the dropdown. This is important because radix\n * tries to close the dropdown when the input first focuses, and we don't want it to do that. But\n * we don't want to prevent the dropdown from closing when we click away from the input, so we\n * don't want to just keep it open if the input is focused\n */\n const shouldPreventAutoClosing = useRef(false);\n\n const controlMenuState = useCallback((open: boolean) => {\n if (shouldPreventAutoClosing.current) {\n shouldPreventAutoClosing.current = false;\n return;\n }\n setIsContentOpen(open);\n }, []);\n\n const updateReference = useCallback(\n (bookId: string, shouldClose: boolean, chapter?: number, verse?: number) => {\n setHighlightedChapter(\n Canon.bookNumberToId(scrRef.bookNum) !== bookId ? 1 : scrRef.chapterNum,\n );\n\n if (shouldClose || fetchEndChapter(bookId) === -1) {\n handleSubmit({\n bookNum: Canon.bookIdToNumber(bookId),\n chapterNum: chapter || 1,\n verseNum: verse || 1,\n });\n\n setIsContentOpen(false);\n setSearchQuery('');\n return;\n }\n\n setSelectedBookId(selectedBookId !== bookId ? bookId : '');\n setIsContentOpen(!shouldClose);\n },\n [handleSubmit, scrRef.bookNum, scrRef.chapterNum, selectedBookId],\n );\n\n const handleSelectChapter = (chapterNumber: number) => {\n if (chapterNumber <= 0 || chapterNumber > fetchEndChapter(selectedBookId)) {\n return;\n }\n updateReference(selectedBookId, true, chapterNumber);\n };\n\n const handleInputSubmit = useCallback(() => {\n SEARCH_QUERY_FORMATS.forEach((format) => {\n const matches = searchQuery.match(format);\n if (matches) {\n // Book should be a bookId or an english name\n const [book, chapter = undefined, verse = undefined] = matches.slice(1);\n const englishName = getBookIdFromEnglishName(book);\n\n if (Canon.isBookIdValid(book) || englishName) {\n updateReference(\n englishName ?? book,\n true,\n chapter ? parseInt(chapter, 10) : 1,\n verse ? parseInt(verse, 10) : 1,\n );\n }\n }\n });\n }, [updateReference, searchQuery]);\n\n const handleKeyDownInput = useCallback(\n (event: ReactKeyboardEvent) => {\n if (!isContentOpen) {\n setIsContentOpen(true);\n } else if (event.key === 'ArrowDown' || event.key === 'ArrowUp') {\n if (\n typeof menuItemRef !== 'undefined' &&\n // Ref uses null\n // eslint-disable-next-line no-null/no-null\n menuItemRef.current !== null\n ) {\n menuItemRef.current.focus();\n } else if (\n typeof contentRef !== 'undefined' &&\n // Ref uses null\n // eslint-disable-next-line no-null/no-null\n contentRef.current !== null\n ) {\n contentRef.current.focus();\n }\n event.preventDefault();\n }\n },\n [isContentOpen],\n );\n\n const handleKeyDownContent = (event: ReactKeyboardEvent) => {\n // When the dropdown menu has focus, key strokes should give focus to the input component,\n // unless they're navigation keys (arrows and enter)\n const { key } = event;\n if (\n key === 'ArrowRight' ||\n key === 'ArrowLeft' ||\n key === 'ArrowDown' ||\n key === 'ArrowUp' ||\n key === 'Enter'\n ) {\n return;\n }\n\n inputRef.current.dispatchEvent(new KeyboardEvent('keydown', { key }));\n inputRef.current.focus();\n };\n\n const handleKeyDownMenuItem = (event: ReactKeyboardEvent) => {\n const { key } = event;\n if (highlightedBookId === selectedBookId) {\n if (key === 'Enter') {\n event.preventDefault();\n updateReference(selectedBookId, true, highlightedChapter);\n return;\n }\n\n let chapterOffSet = 0;\n if (key === 'ArrowRight') {\n if (highlightedChapter < fetchEndChapter(highlightedBookId)) {\n chapterOffSet = 1;\n } else {\n event.preventDefault();\n return;\n }\n } else if (key === 'ArrowLeft') {\n if (highlightedChapter > 1) {\n chapterOffSet = -1;\n } else {\n event.preventDefault();\n return;\n }\n } else if (key === 'ArrowDown') {\n chapterOffSet = 6;\n } else if (key === 'ArrowUp') {\n chapterOffSet = -6;\n }\n if (\n highlightedChapter + chapterOffSet <= 0 ||\n highlightedChapter + chapterOffSet > fetchEndChapter(highlightedBookId)\n ) {\n setHighlightedChapter(0);\n } else if (chapterOffSet !== 0) {\n setHighlightedChapter(highlightedChapter + chapterOffSet);\n event.preventDefault();\n }\n }\n };\n\n useEffect(() => {\n if (selectedBookId === highlightedBookId) {\n if (selectedBookId === Canon.bookNumberToId(scrRef.bookNum)) {\n setHighlightedChapter(scrRef.chapterNum);\n } else {\n setHighlightedChapter(1);\n }\n } else {\n setHighlightedChapter(0);\n }\n }, [highlightedBookId, scrRef.bookNum, scrRef.chapterNum, selectedBookId]);\n\n // The purpose of these useLayoutEffects and timeout is to delay the scroll just\n // enough so that the refs are defined and available when they are used after the timeout\n useLayoutEffect(() => {\n setIsContentOpenDelayed(isContentOpen);\n }, [isContentOpen]);\n\n useLayoutEffect(() => {\n const scrollTimeout = setTimeout(() => {\n if (isContentOpenDelayed && contentRef.current && menuItemRef.current) {\n const menuItemOffsetTop = menuItemRef.current.offsetTop;\n const scrollPosition = menuItemOffsetTop - SCROLL_OFFSET;\n contentRef.current.scrollTo({ top: scrollPosition, behavior: 'instant' });\n }\n }, 10);\n return () => {\n clearTimeout(scrollTimeout);\n };\n }, [isContentOpenDelayed]);\n\n return (\n
    \n \n \n {\n setSelectedBookId(Canon.bookNumberToId(scrRef.bookNum));\n setHighlightedBookId(Canon.bookNumberToId(scrRef.bookNum));\n setHighlightedChapter(scrRef.chapterNum > 0 ? scrRef.chapterNum : 0);\n setIsContentOpen(true);\n inputRef.current.focus();\n }}\n onFocus={() => {\n // Radix thinks we want to close because the input is being focused. Prevent that\n shouldPreventAutoClosing.current = true;\n }}\n handleSubmit={handleInputSubmit}\n placeholder={`${Canon.bookNumberToEnglishName(scrRef.bookNum)} ${scrRef.chapterNum}:${scrRef.verseNum}`}\n />\n \n \n console.log('sorting')}\n handleLocationHistory={() => console.log('location history')}\n handleBookmarks={() => console.log('bookmarks')}\n />\n {BOOK_TYPE_ARRAY.map(\n (bookType, bookTypeIndex) =>\n fetchFilteredBooks(bookType).length > 0 && (\n
    \n \n {BOOK_TYPE_LABELS[bookType]}\n \n\n {fetchFilteredBooks(bookType).map((bookId) => (\n
    \n updateReference(bookId, false)}\n isSelected={selectedBookId === bookId}\n handleHighlightBook={() => setHighlightedBookId(bookId)}\n handleKeyDown={handleKeyDownMenuItem}\n bookType={bookType}\n ref={(element: HTMLDivElement) => {\n if (selectedBookId === bookId) menuItemRef.current = element;\n }}\n >\n {\n setHighlightedChapter(chapterNumber);\n }}\n />\n \n
    \n ))}\n {BOOK_TYPE_ARRAY.length - 1 !== bookTypeIndex ? (\n \n ) : undefined}\n
    \n ),\n )}\n \n
    \n
    \n );\n}\n\nexport default BookChapterControl;\n","import React from 'react';\nimport { Slot } from '@radix-ui/react-slot';\nimport { cva, type VariantProps } from 'class-variance-authority';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport const buttonVariants = cva(\n 'pr-twp tw-inline-flex tw-items-center tw-justify-center tw-whitespace-nowrap tw-rounded-md tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-colors focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50',\n {\n variants: {\n variant: {\n default: 'tw-bg-primary tw-text-primary-foreground hover:tw-bg-primary/90',\n destructive: 'tw-bg-destructive tw-text-destructive-foreground hover:tw-bg-destructive/90',\n outline:\n 'tw-border tw-border-input tw-bg-background hover:tw-bg-accent hover:tw-text-accent-foreground',\n secondary: 'tw-bg-secondary tw-text-secondary-foreground hover:tw-bg-secondary/80',\n ghost: 'hover:tw-bg-accent hover:tw-text-accent-foreground',\n link: 'tw-text-primary tw-underline-offset-4 hover:tw-underline',\n },\n size: {\n default: 'tw-h-10 tw-px-4 tw-py-2',\n sm: 'tw-h-9 tw-rounded-md tw-px-3',\n lg: 'tw-h-11 tw-rounded-md tw-px-8',\n icon: 'tw-h-10 tw-w-10',\n },\n },\n defaultVariants: {\n variant: 'default',\n size: 'default',\n },\n },\n);\n\nexport interface ButtonProps\n extends React.ButtonHTMLAttributes,\n VariantProps {\n asChild?: boolean;\n}\n\nexport const Button = React.forwardRef(\n ({ className, variant, size, asChild = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'button';\n return (\n \n );\n },\n);\nButton.displayName = 'Button';\n","import React from 'react';\nimport * as LabelPrimitive from '@radix-ui/react-label';\nimport { cva, type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst labelVariants = cva(\n 'tw-text-sm tw-font-medium tw-leading-none peer-disabled:tw-cursor-not-allowed peer-disabled:tw-opacity-70',\n);\n\nexport const Label = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef & VariantProps\n>(({ className, ...props }, ref) => (\n \n));\nLabel.displayName = LabelPrimitive.Root.displayName;\n","import React from 'react';\nimport * as RadioGroupPrimitive from '@radix-ui/react-radio-group';\nimport { Circle } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst RadioGroup = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => {\n return (\n \n );\n});\nRadioGroup.displayName = RadioGroupPrimitive.Root.displayName;\n\nconst RadioGroupItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => {\n return (\n \n \n \n \n \n );\n});\nRadioGroupItem.displayName = RadioGroupPrimitive.Item.displayName;\n\nexport { RadioGroup, RadioGroupItem };\n","import React from 'react';\nimport * as PopoverPrimitive from '@radix-ui/react-popover';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Popover = PopoverPrimitive.Root;\n\nconst PopoverTrigger = PopoverPrimitive.Trigger;\n\nconst PopoverContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, align = 'center', sideOffset = 4, ...props }, ref) => (\n \n \n \n));\nPopoverContent.displayName = PopoverPrimitive.Content.displayName;\n\nexport { Popover, PopoverTrigger, PopoverContent };\n","import React from 'react';\nimport * as DialogPrimitive from '@radix-ui/react-dialog';\nimport { X } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Dialog = DialogPrimitive.Root;\n\nconst DialogTrigger = DialogPrimitive.Trigger;\n\nconst DialogPortal = DialogPrimitive.Portal;\n\nconst DialogClose = DialogPrimitive.Close;\n\nconst DialogOverlay = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nDialogOverlay.displayName = DialogPrimitive.Overlay.displayName;\n\nconst DialogContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, ...props }, ref) => (\n \n \n \n {children}\n \n \n Close\n \n \n \n));\nDialogContent.displayName = DialogPrimitive.Content.displayName;\n\nfunction DialogHeader({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nDialogHeader.displayName = 'DialogHeader';\n\nfunction DialogFooter({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nDialogFooter.displayName = 'DialogFooter';\n\nconst DialogTitle = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nDialogTitle.displayName = DialogPrimitive.Title.displayName;\n\nconst DialogDescription = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nDialogDescription.displayName = DialogPrimitive.Description.displayName;\n\nexport {\n Dialog,\n DialogPortal,\n DialogOverlay,\n DialogClose,\n DialogTrigger,\n DialogContent,\n DialogHeader,\n DialogFooter,\n DialogTitle,\n DialogDescription,\n};\n","import React from 'react';\nimport { type DialogProps } from '@radix-ui/react-dialog';\nimport { Command as CommandPrimitive } from 'cmdk';\nimport { Search } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Dialog, DialogContent } from '@/components/shadcn-ui/dialog';\n\nconst Command = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nCommand.displayName = CommandPrimitive.displayName;\n\ninterface CommandDialogProps extends DialogProps {}\n\nfunction CommandDialog({ children, ...props }: CommandDialogProps) {\n return (\n \n \n \n {children}\n \n \n \n );\n}\n\nconst CommandInput = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n
    \n \n \n
    \n));\n\nCommandInput.displayName = CommandPrimitive.Input.displayName;\n\nconst CommandList = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\n\nCommandList.displayName = CommandPrimitive.List.displayName;\n\nconst CommandEmpty = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>((props, ref) => (\n \n));\n\nCommandEmpty.displayName = CommandPrimitive.Empty.displayName;\n\nconst CommandGroup = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\n\nCommandGroup.displayName = CommandPrimitive.Group.displayName;\n\nconst CommandSeparator = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nCommandSeparator.displayName = CommandPrimitive.Separator.displayName;\n\nconst CommandItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\n\nCommandItem.displayName = CommandPrimitive.Item.displayName;\n\nfunction CommandShortcut({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nCommandShortcut.displayName = 'CommandShortcut';\n\nexport {\n Command,\n CommandDialog,\n CommandInput,\n CommandList,\n CommandEmpty,\n CommandGroup,\n CommandItem,\n CommandShortcut,\n CommandSeparator,\n};\n","import { useState } from 'react';\nimport { Check, ChevronsUpDown } from 'lucide-react';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport { Popover, PopoverContent, PopoverTrigger } from '@/components/shadcn-ui/popover';\nimport {\n Command,\n CommandEmpty,\n CommandInput,\n CommandItem,\n CommandList,\n} from '@/components/shadcn-ui/command';\nimport { PopoverProps } from '@radix-ui/react-popover';\n\nexport type ComboBoxLabelOption = { label: string };\nexport type ComboBoxOption = string | number | ComboBoxLabelOption;\n\nexport type ComboBoxProps = {\n /** Optional unique identifier */\n id?: string;\n /** Text label title for combobox */\n /** List of available options for the dropdown menu */\n options?: readonly T[];\n /** Additional css classes to help with unique styling of the combo box button */\n buttonClassName?: string;\n /** Additional css classes to help with unique styling of the combo box popover */\n popoverContentClassName?: string;\n /**\n * The selected value that the combo box currently holds. Must be shallow equal to one of the\n * options entries.\n */\n value?: T;\n /** Triggers when content of textfield is changed */\n onChange?: (newValue: T) => void;\n /** Used to determine the string value for a given option. */\n getOptionLabel?: (option: ComboBoxOption) => string;\n /** Text displayed on button if `value` is undefined */\n buttonPlaceholder?: string;\n /** Placeholder text for text field */\n textPlaceholder?: string;\n /** Text to display when no options match input */\n commandEmptyMessage?: string;\n /** Variant of button */\n buttonVariant?: ButtonProps['variant'];\n /** Text direction ltr or rtl */\n dir?: Direction;\n /** Optional boolean to set if trigger should be disabled */\n isDisabled?: boolean;\n} & PopoverProps;\n\ntype Direction = 'ltr' | 'rtl';\n\nfunction getOptionLabelDefault(option: ComboBoxOption): string {\n if (typeof option === 'string') {\n return option;\n }\n if (typeof option === 'number') {\n return option.toString();\n }\n return option.label;\n}\n\n/**\n * Autocomplete input and command palette with a list of suggestions.\n *\n * Thanks to Shadcn for heavy inspiration and documentation\n * https://ui.shadcn.com/docs/components/combobox\n */\nfunction ComboBox({\n id,\n options = [],\n buttonClassName,\n popoverContentClassName,\n value,\n onChange = () => {},\n getOptionLabel = getOptionLabelDefault,\n buttonPlaceholder = '',\n textPlaceholder = '',\n commandEmptyMessage = 'No option found',\n buttonVariant = 'outline',\n dir = 'ltr',\n isDisabled = false,\n ...props\n}: ComboBoxProps) {\n const [open, setOpen] = useState(false);\n\n return (\n \n \n \n \n {value ? getOptionLabel(value) : buttonPlaceholder}\n \n \n \n \n \n \n \n {commandEmptyMessage}\n \n {options.map((option) => (\n {\n onChange(option);\n setOpen(false);\n }}\n >\n \n {getOptionLabel(option)}\n \n ))}\n \n \n \n \n );\n}\n\nexport default ComboBox;\n","import { useMemo } from 'react';\nimport ComboBox from '@/components/basics/combo-box.component';\nimport { Label } from '@/components/shadcn-ui/label';\n\nexport type ChapterRangeSelectorProps = {\n startChapter: number;\n endChapter: number;\n handleSelectStartChapter: (chapter: number) => void;\n handleSelectEndChapter: (chapter: number) => void;\n isDisabled?: boolean;\n chapterCount: number;\n};\n\nexport default function ChapterRangeSelector({\n startChapter,\n endChapter,\n handleSelectStartChapter,\n handleSelectEndChapter,\n isDisabled = false,\n chapterCount,\n}: ChapterRangeSelectorProps) {\n const chapterOptions = useMemo(\n () => Array.from({ length: chapterCount }, (_, index) => index + 1),\n [chapterCount],\n );\n\n const onChangeStartChapter = (value: number) => {\n handleSelectStartChapter(value);\n if (value > endChapter) {\n handleSelectEndChapter(value);\n }\n };\n\n const onChangeEndChapter = (value: number) => {\n handleSelectEndChapter(value);\n if (value < startChapter) {\n handleSelectStartChapter(value);\n }\n };\n\n return (\n <>\n \n option.toString()}\n value={startChapter}\n />\n\n \n option.toString()}\n value={endChapter}\n />\n \n );\n}\n","import { Button } from '@/components/shadcn-ui/button';\nimport { Label } from '@/components/shadcn-ui/label';\nimport { RadioGroup, RadioGroupItem } from '@/components/shadcn-ui/radio-group';\nimport { Canon } from '@sillsdev/scripture';\nimport { LocalizedStringValue } from 'platform-bible-utils';\nimport { useState } from 'react';\nimport ChapterRangeSelector, {\n ChapterRangeSelectorProps,\n} from '../basics/chapter-range-selector.component';\n\nexport enum BookSelectionMode {\n CURRENT_BOOK = 'current book',\n CHOOSE_BOOKS = 'choose books',\n}\n\n/**\n * Object containing all keys used for localization in this component. If you're using this\n * component in an extension, you can pass it into the useLocalizedStrings hook to easily obtain the\n * localized strings and pass them into the localizedStrings prop of this component\n */\nexport const BOOK_SELECTOR_STRING_KEYS = Object.freeze([\n '%webView_bookSelector_currentBook%',\n '%webView_bookSelector_choose%',\n '%webView_bookSelector_chooseBooks%',\n] as const);\n\nexport type BookSelectorLocalizedStrings = {\n [localizedInventoryKey in (typeof BOOK_SELECTOR_STRING_KEYS)[number]]?: LocalizedStringValue;\n};\n\n/**\n * Gets the localized value for the provided key\n *\n * @param strings Object containing localized string\n * @param key Key for a localized string\n * @returns The localized value for the provided key, if available. Returns the key if no localized\n * value is available\n */\nconst localizeString = (\n strings: BookSelectorLocalizedStrings,\n key: keyof BookSelectorLocalizedStrings,\n) => {\n return strings[key] ?? key;\n};\n\ntype BookSelectorProps = ChapterRangeSelectorProps & {\n handleBookSelectionModeChange: (newMode: BookSelectionMode) => void;\n currentBookName: string;\n onSelectBooks: () => void;\n selectedBookIds: string[];\n localizedStrings: BookSelectorLocalizedStrings;\n};\n\nexport default function BookSelector({\n handleBookSelectionModeChange,\n currentBookName,\n onSelectBooks,\n selectedBookIds,\n chapterCount,\n endChapter,\n handleSelectEndChapter,\n startChapter,\n handleSelectStartChapter,\n localizedStrings,\n}: BookSelectorProps) {\n const currentBookText = localizeString(localizedStrings, '%webView_bookSelector_currentBook%');\n const chooseText = localizeString(localizedStrings, '%webView_bookSelector_choose%');\n const chooseBooksText = localizeString(localizedStrings, '%webView_bookSelector_chooseBooks%');\n\n const [bookSelectionMode, setBookSelectionMode] = useState(\n BookSelectionMode.CURRENT_BOOK,\n );\n\n const onSelectionModeChange = (newMode: BookSelectionMode) => {\n setBookSelectionMode(newMode);\n handleBookSelectionModeChange(newMode);\n };\n\n return (\n onSelectionModeChange(value as BookSelectionMode)}\n >\n
    \n
    \n
    \n \n \n
    \n \n
    \n \n
    \n
    \n
    \n
    \n \n \n
    \n \n onSelectBooks()}\n >\n {chooseText}\n \n
    \n
    \n \n );\n}\n","import { DropdownMenuTrigger } from '@radix-ui/react-dropdown-menu';\nimport { FilterIcon } from 'lucide-react';\nimport { Table } from '@tanstack/react-table';\n\nimport { Button } from '@/components/shadcn-ui/button';\nimport {\n DropdownMenu,\n DropdownMenuCheckboxItem,\n DropdownMenuContent,\n DropdownMenuLabel,\n DropdownMenuSeparator,\n} from '@/components/shadcn-ui/dropdown-menu';\n\ninterface DataTableViewOptionsProps {\n table: Table;\n}\n\nfunction DataTableViewOptions({ table }: DataTableViewOptionsProps) {\n return (\n \n \n \n \n \n Toggle columns\n \n {table\n .getAllColumns()\n .filter((column) => column.getCanHide())\n .map((column) => {\n return (\n column.toggleVisibility(!!value)}\n >\n {column.id}\n \n );\n })}\n \n \n );\n}\n\nexport default DataTableViewOptions;\n","import React from 'react';\nimport * as SelectPrimitive from '@radix-ui/react-select';\nimport { Check, ChevronDown, ChevronUp } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Select = SelectPrimitive.Root;\n\nconst SelectGroup = SelectPrimitive.Group;\n\nconst SelectValue = SelectPrimitive.Value;\n\nconst SelectTrigger = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, ...props }, ref) => (\n span]:tw-line-clamp-1',\n className,\n )}\n {...props}\n >\n {children}\n \n \n \n \n));\nSelectTrigger.displayName = SelectPrimitive.Trigger.displayName;\n\nconst SelectScrollUpButton = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n));\nSelectScrollUpButton.displayName = SelectPrimitive.ScrollUpButton.displayName;\n\nconst SelectScrollDownButton = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n));\nSelectScrollDownButton.displayName = SelectPrimitive.ScrollDownButton.displayName;\n\nconst SelectContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, position = 'popper', ...props }, ref) => (\n \n \n \n \n {children}\n \n \n \n \n));\nSelectContent.displayName = SelectPrimitive.Content.displayName;\n\nconst SelectLabel = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSelectLabel.displayName = SelectPrimitive.Label.displayName;\n\nconst SelectItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, ...props }, ref) => (\n \n \n \n \n \n \n\n {children}\n \n));\nSelectItem.displayName = SelectPrimitive.Item.displayName;\n\nconst SelectSeparator = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSelectSeparator.displayName = SelectPrimitive.Separator.displayName;\n\nexport {\n Select,\n SelectGroup,\n SelectValue,\n SelectTrigger,\n SelectContent,\n SelectLabel,\n SelectItem,\n SelectSeparator,\n SelectScrollUpButton,\n SelectScrollDownButton,\n};\n","import { ChevronLeftIcon, ChevronRightIcon, ArrowLeftIcon, ArrowRightIcon } from 'lucide-react';\nimport { Table } from '@tanstack/react-table';\n\nimport { Button } from '@/components/shadcn-ui/button';\nimport {\n Select,\n SelectContent,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\n\ninterface DataTablePaginationProps {\n table: Table;\n}\n\nfunction DataTablePagination({ table }: DataTablePaginationProps) {\n return (\n
    \n
    \n
    \n {table.getFilteredSelectedRowModel().rows.length} of{' '}\n {table.getFilteredRowModel().rows.length} row(s) selected\n
    \n
    \n

    Rows per page

    \n {\n table.setPageSize(Number(value));\n }}\n >\n \n \n \n \n {[10, 20, 30, 40, 50].map((pageSize) => (\n \n {pageSize}\n \n ))}\n \n \n
    \n
    \n Page {table.getState().pagination.pageIndex + 1} of {table.getPageCount()}\n
    \n
    \n table.setPageIndex(0)}\n disabled={!table.getCanPreviousPage()}\n >\n Go to first page\n \n \n table.previousPage()}\n disabled={!table.getCanPreviousPage()}\n >\n Go to previous page\n \n \n table.nextPage()}\n disabled={!table.getCanNextPage()}\n >\n Go to next page\n \n \n table.setPageIndex(table.getPageCount() - 1)}\n disabled={!table.getCanNextPage()}\n >\n Go to last page\n \n \n
    \n
    \n
    \n );\n}\n\nexport default DataTablePagination;\n","import React from 'react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Table = React.forwardRef<\n HTMLTableElement,\n React.HTMLAttributes & { stickyHeader?: boolean }\n>(({ className, stickyHeader, ...props }, ref) => (\n
    \n \n
    \n));\nTable.displayName = 'Table';\n\nconst TableHeader = React.forwardRef<\n HTMLTableSectionElement,\n React.HTMLAttributes & { stickyHeader?: boolean }\n>(({ className, stickyHeader, ...props }, ref) => (\n \n));\nTableHeader.displayName = 'TableHeader';\n\nconst TableBody = React.forwardRef<\n HTMLTableSectionElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableBody.displayName = 'TableBody';\n\nconst TableFooter = React.forwardRef<\n HTMLTableSectionElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n tr]:last:tw-border-b-0', className)}\n {...props}\n />\n));\nTableFooter.displayName = 'TableFooter';\n\nconst TableRow = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nTableRow.displayName = 'TableRow';\n\nconst TableHead = React.forwardRef<\n HTMLTableCellElement,\n React.ThHTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableHead.displayName = 'TableHead';\n\nconst TableCell = React.forwardRef<\n HTMLTableCellElement,\n React.TdHTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableCell.displayName = 'TableCell';\n\nconst TableCaption = React.forwardRef<\n HTMLTableCaptionElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableCaption.displayName = 'TableCaption';\n\nexport { Table, TableHeader, TableBody, TableFooter, TableHead, TableRow, TableCell, TableCaption };\n","import { useState } from 'react';\n\nimport {\n ColumnFiltersState,\n flexRender,\n getCoreRowModel,\n getFilteredRowModel,\n getPaginationRowModel,\n getSortedRowModel,\n SortingState,\n ColumnDef as TSColumnDef,\n Row as TSRow,\n RowSelectionState as TSRowSelectionState,\n SortDirection as TSSortDirection,\n Table as TSTable,\n useReactTable,\n VisibilityState,\n} from '@tanstack/react-table';\n\nimport DataTableViewOptions from '@/components/advanced/data-table/data-table-column-toggle.component';\nimport DataTablePagination from '@/components/advanced/data-table/data-table-pagination.component';\nimport { Button } from '@/components/shadcn-ui/button';\nimport {\n Table,\n TableBody,\n TableCell,\n TableHead,\n TableHeader,\n TableRow,\n} from '@/components/shadcn-ui/table';\n\nexport type ColumnDef = TSColumnDef;\nexport type RowContents = TSRow;\nexport type TableContents = TSTable;\nexport type SortDirection = TSSortDirection;\nexport type RowSelectionState = TSRowSelectionState;\n\ninterface DataTableProps {\n columns: ColumnDef[];\n data: TData[];\n enablePagination?: boolean;\n showPaginationControls?: boolean;\n showColumnVisibilityControls?: boolean;\n stickyHeader?: boolean;\n onRowClickHandler?: (row: RowContents, table: TableContents) => void;\n}\n\n/**\n * Feature-rich table component that infuses our basic shadcn-based Table component with features\n * from TanStack's React Table library\n */\nfunction DataTable({\n columns,\n data,\n enablePagination = false,\n showPaginationControls = false,\n showColumnVisibilityControls = false,\n stickyHeader = false,\n onRowClickHandler = () => {},\n}: DataTableProps) {\n const [sorting, setSorting] = useState([]);\n const [columnFilters, setColumnFilters] = useState([]);\n const [columnVisibility, setColumnVisibility] = useState({});\n const [rowSelection, setRowSelection] = useState({});\n\n const table = useReactTable({\n data,\n columns,\n getCoreRowModel: getCoreRowModel(),\n ...(enablePagination && { getPaginationRowModel: getPaginationRowModel() }),\n onSortingChange: setSorting,\n getSortedRowModel: getSortedRowModel(),\n onColumnFiltersChange: setColumnFilters,\n getFilteredRowModel: getFilteredRowModel(),\n onColumnVisibilityChange: setColumnVisibility,\n onRowSelectionChange: setRowSelection,\n state: {\n sorting,\n columnFilters,\n columnVisibility,\n rowSelection,\n },\n });\n\n return (\n
    \n {showColumnVisibilityControls && }\n \n \n {table.getHeaderGroups().map((headerGroup) => (\n \n {headerGroup.headers.map((header) => {\n return (\n \n {header.isPlaceholder\n ? undefined\n : flexRender(header.column.columnDef.header, header.getContext())}\n \n );\n })}\n \n ))}\n \n \n {table.getRowModel().rows?.length ? (\n table.getRowModel().rows.map((row) => (\n onRowClickHandler(row, table)}\n key={row.id}\n data-state={row.getIsSelected() && 'selected'}\n >\n {row.getVisibleCells().map((cell) => (\n \n {flexRender(cell.column.columnDef.cell, cell.getContext())}\n \n ))}\n \n ))\n ) : (\n \n \n No results.\n \n \n )}\n \n
    \n {enablePagination && (\n
    \n table.previousPage()}\n disabled={!table.getCanPreviousPage()}\n >\n Previous\n \n table.nextPage()}\n disabled={!table.getCanNextPage()}\n >\n Next\n \n
    \n )}\n {enablePagination && showPaginationControls && }\n
    \n );\n}\n\nexport default DataTable;\n","import {\n Table,\n TableBody,\n TableCell,\n TableHead,\n TableHeader,\n TableRow,\n} from '@/components/shadcn-ui/table';\nimport { Canon } from '@sillsdev/scripture';\nimport { deepEqual, LanguageStrings, ScriptureReference } from 'platform-bible-utils';\nimport { useMemo } from 'react';\nimport { InventoryItemOccurrence } from './inventory-utils';\n\n/** Props for the OccurrencesTable component */\ntype OccurrencesTableProps = {\n /** Data that contains scriptures references and snippets of scripture */\n occurrenceData: InventoryItemOccurrence[];\n /** Callback function that is executed when the scripture reference is changed */\n setScriptureReference: (scriptureReference: ScriptureReference) => void;\n /**\n * Object with all localized strings that the OccurrencesTable needs to work well across multiple\n * languages\n */\n localizedStrings: LanguageStrings;\n};\n\n/**\n * Table that shows occurrences of specified inventory item(s). The first column shows the related\n * scripture reference. The second column shows the snippet of scripture that contains the specified\n * inventory item\n */\nfunction OccurrencesTable({\n occurrenceData,\n setScriptureReference,\n localizedStrings,\n}: OccurrencesTableProps) {\n const referenceHeaderText =\n localizedStrings['%webView_inventory_occurrences_table_header_reference%'];\n const occurrenceHeaderText =\n localizedStrings['%webView_inventory_occurrences_table_header_occurrence%'];\n\n const occurrences: InventoryItemOccurrence[] = useMemo(() => {\n const uniqueOccurrences: InventoryItemOccurrence[] = [];\n\n occurrenceData.forEach((occurrence) => {\n if (!uniqueOccurrences.some((uniqueOccurrence) => deepEqual(uniqueOccurrence, occurrence))) {\n uniqueOccurrences.push(occurrence);\n }\n });\n\n return uniqueOccurrences;\n }, [occurrenceData]);\n\n return (\n \n \n \n {referenceHeaderText}\n {occurrenceHeaderText}\n \n \n \n {occurrences.length > 0 &&\n occurrences.map((occurrence) => (\n {\n setScriptureReference(occurrence.reference);\n }}\n >\n {`${Canon.bookNumberToEnglishName(occurrence.reference.bookNum)} ${occurrence.reference.chapterNum}:${occurrence.reference.verseNum}`}\n {occurrence.text}\n \n ))}\n \n
    \n );\n}\n\nexport default OccurrencesTable;\n","import React from 'react';\nimport * as CheckboxPrimitive from '@radix-ui/react-checkbox';\nimport { Check } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Checkbox = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n \n \n));\nCheckbox.displayName = CheckboxPrimitive.Root.displayName;\n\nexport default Checkbox;\n","import { Canon } from '@sillsdev/scripture';\nimport { ScriptureReference } from 'platform-bible-utils';\n\n/* #region Types */\n\n/**\n * Status of items that appear in inventories. 'approved' and 'unapproved' items are defined in the\n * project's `Settings.xml`. All other items are defined as 'unknown'\n */\nexport type Status = 'approved' | 'unapproved' | 'unknown';\n\n/** Occurrence of item in inventory. Primarily used by table that shows occurrences */\nexport type InventoryItemOccurrence = {\n /** Reference to scripture where the item appears */\n reference: ScriptureReference;\n /** Snippet of scripture that contains the occurrence */\n text: string;\n};\n\n/** Data structure that contains all information on an item that is shown in an inventory */\nexport type InventoryTableData = {\n /**\n * The item (e.g. a character in the characters inventory, a marker in the marker inventory) In\n * most cases the array will only have one element. In case of additional items (e.g. the\n * preceding marker in the markers check), the primary item should be stored in the first index.\n * To show additional items in the inventory, make sure to configure the `additionalItemsLabels`\n * prop for the Inventory component\n */\n items: string[];\n /** The number of times this item occurs in the selected scope */\n count: number;\n /** The status of this item (see documentation for `Status` type for more information) */\n status: Status;\n /** Occurrences of this item in the scripture text for the selected scope */\n occurrences: InventoryItemOccurrence[];\n};\n\n/* #endregion */\n\n/* #region Functions */\n\n/**\n * Splits USFM string into shorter line-like segments\n *\n * @param text A single (likely very large) USFM string\n * @returns An array containing the input text, split into shorter segments\n */\nexport const getLinesFromUSFM = (text: string) => {\n // Splits on (CR)LF, CR, \\v, \\c and \\id\n return text.split(/(?:\\r?\\n|\\r)|(?=(?:\\\\(?:v|c|id)))/g);\n};\n\n/**\n * Extracts chapter or verse number from USFM strings that start with a \\c or \\v marker\n *\n * @param text USFM string that is expected to start with \\c or \\v marker\n * @returns Chapter or verse number if one is found. Else returns 0.\n */\nexport const getNumberFromUSFM = (text: string): number | undefined => {\n // Captures all digits that follow \\v or \\c markers followed by whitespace located at the start of a string\n const regex = /^\\\\[vc]\\s+(\\d+)/;\n const match = text.match(regex);\n\n if (match) {\n return +match[1];\n }\n return undefined;\n};\n\n/**\n * Gets book ID from USFM string that starts with the \\id marker, and returns book number for it\n *\n * @param text USFM string that is expected to start with \\id marker\n * @returns Book number corresponding to the \\id marker in the input text. Returns 0 if no marker is\n * found or the marker is not valid\n */\nexport const getBookNumFromId = (text: string): number => {\n // Captures all digits that follow an \\id marker followed by whitespace located at the start of a string\n const match = text.match(/^\\\\id\\s+([A-Za-z]+)/);\n if (match) {\n return Canon.bookIdToNumber(match[1]);\n }\n return 0;\n};\n\n/**\n * Gets the status for an item, typically used in the Inventory component\n *\n * @param item The item for which the status is being requested\n * @param approvedItems Array of approved items, typically as defined in `Settings.xml`\n * @param unapprovedItems Array of unapproved items, typically as defined in `Settings.xml`\n * @returns The status for the specified item\n */\nexport const getStatusForItem = (\n item: string,\n approvedItems: string[],\n unapprovedItems: string[],\n): Status => {\n if (unapprovedItems.includes(item)) return 'unapproved';\n if (approvedItems.includes(item)) return 'approved';\n return 'unknown';\n};\n\n/* #endregion */\n","import React from 'react';\nimport * as TogglePrimitive from '@radix-ui/react-toggle';\nimport { cva, type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst toggleVariants = cva(\n 'pr-twp tw-inline-flex tw-items-center tw-justify-center tw-rounded-md tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-colors hover:tw-bg-muted hover:tw-text-muted-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50 data-[state=on]:tw-bg-accent data-[state=on]:tw-text-accent-foreground',\n {\n variants: {\n variant: {\n default: 'tw-bg-transparent',\n outline:\n 'tw-border tw-border-input tw-bg-transparent hover:tw-bg-accent hover:tw-text-accent-foreground',\n },\n size: {\n default: 'tw-h-10 tw-px-3',\n sm: 'tw-h-9 tw-px-2.5',\n lg: 'tw-h-11 tw-px-5',\n },\n },\n defaultVariants: {\n variant: 'default',\n size: 'default',\n },\n },\n);\n\nconst Toggle = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef & VariantProps\n>(({ className, variant, size, ...props }, ref) => (\n \n));\n\nToggle.displayName = TogglePrimitive.Root.displayName;\n\nexport { Toggle, toggleVariants };\n","import React from 'react';\nimport * as ToggleGroupPrimitive from '@radix-ui/react-toggle-group';\nimport { type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { toggleVariants } from '@/components/shadcn-ui/toggle';\n\nconst ToggleGroupContext = React.createContext>({\n size: 'default',\n variant: 'default',\n});\n\nconst ToggleGroup = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef &\n VariantProps\n>(({ className, variant, size, children, ...props }, ref) => (\n \n \n {children}\n \n \n));\n\nToggleGroup.displayName = ToggleGroupPrimitive.Root.displayName;\n\nconst ToggleGroupItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef &\n VariantProps\n>(({ className, children, variant, size, ...props }, ref) => {\n const context = React.useContext(ToggleGroupContext);\n\n return (\n \n {children}\n \n );\n});\n\nToggleGroupItem.displayName = ToggleGroupPrimitive.Item.displayName;\n\nexport { ToggleGroup, ToggleGroupItem };\n","import { ColumnDef, SortDirection } from '@/components/advanced/data-table/data-table.component';\nimport { Button } from '@/components/shadcn-ui/button';\nimport { ToggleGroup, ToggleGroupItem } from '@/components/shadcn-ui/toggle-group';\nimport {\n ArrowDownIcon,\n ArrowUpDownIcon,\n ArrowUpIcon,\n CircleCheckIcon,\n CircleHelpIcon,\n CircleXIcon,\n} from 'lucide-react';\nimport { ReactNode } from 'react';\nimport { InventoryTableData, Status } from './inventory-utils';\n\n/**\n * Gets an icon that indicates the current sorting direction based on the provided input\n *\n * @param sortDirection Sorting direction. Can be ascending ('asc'), descending ('desc') or false (\n * i.e. not sorted)\n * @returns The appropriate sorting icon for the provided sorting direction\n */\nconst getSortingIcon = (sortDirection: false | SortDirection): ReactNode => {\n if (sortDirection === 'asc') {\n return ;\n }\n if (sortDirection === 'desc') {\n return ;\n }\n return ;\n};\n\n/**\n * Function that creates the item column for inventories\n *\n * @param itemLabel Localized label for the item column (e.g. 'Character', 'Repeated Word', etc.)\n * @returns Column that shows the inventory items. Should be used with the DataTable component\n */\nexport const inventoryItemColumn = (itemLabel: string): ColumnDef => {\n return {\n accessorKey: 'item',\n accessorFn: (row: InventoryTableData) => row.items[0],\n header: ({ column }) => (\n \n ),\n };\n};\n\n/**\n * Function that creates the additional item columns for inventories\n *\n * @param additionalItemLabel Localized label for the additional item column (e.g. 'Preceding\n * Marker')\n * @param additionalItemIndex Index that locates the desired item in the items array of the\n * inventory\n * @returns Column that shows additional inventory items. Should be used with the DataTable\n * component\n */\nexport const inventoryAdditionalItemColumn = (\n additionalItemLabel: string,\n additionalItemIndex: number,\n): ColumnDef => {\n return {\n accessorKey: `item${additionalItemIndex}`,\n accessorFn: (row: InventoryTableData) => row.items[additionalItemIndex],\n header: ({ column }) => (\n \n ),\n };\n};\n\n/**\n * Function that creates the count column for inventories. Should be used with the DataTable\n * component.\n *\n * @param itemLabel Localized label for the count column\n * @returns Column that shows the number of occurrences of the related inventory items\n */\nexport const inventoryCountColumn = (countLabel: string): ColumnDef => {\n return {\n accessorKey: 'count',\n header: ({ column }) => (\n
    \n \n
    \n ),\n cell: ({ row }) =>
    {row.getValue('count')}
    ,\n };\n};\n\n/**\n * Function that updates project settings when status for item(s) changes\n *\n * @param changedItems Array of items for which the status is being updated\n * @param newStatus The status that the items are being given\n * @param approvedItems Array of currently approved items\n * @param onApprovedItemsChange Callback function that stores the updated list of approved items\n * @param unapprovedItems Array of currently unapproved items\n * @param onUnapprovedItemsChange Callback function that stores the updated list of unapproved items\n */\nconst statusChangeHandler = (\n changedItems: string[],\n newStatus: Status,\n approvedItems: string[],\n onApprovedItemsChange: (items: string[]) => void,\n unapprovedItems: string[],\n onUnapprovedItemsChange: (items: string[]) => void,\n) => {\n let newApprovedItems: string[] = [...approvedItems];\n changedItems.forEach((item) => {\n if (newStatus === 'approved') {\n if (!newApprovedItems.includes(item)) {\n newApprovedItems.push(item);\n }\n } else {\n newApprovedItems = newApprovedItems.filter((validItem) => validItem !== item);\n }\n });\n onApprovedItemsChange(newApprovedItems);\n\n let newUnapprovedItems: string[] = [...unapprovedItems];\n changedItems.forEach((item) => {\n if (newStatus === 'unapproved') {\n if (!newUnapprovedItems.includes(item)) {\n newUnapprovedItems.push(item);\n }\n } else {\n newUnapprovedItems = newUnapprovedItems.filter((unapprovedItem) => unapprovedItem !== item);\n }\n });\n onUnapprovedItemsChange(newUnapprovedItems);\n};\n\n/**\n * Function that creates the status column for inventories. Should be used with the DataTable\n * component.\n *\n * @param statusLabel Localized label for the status column\n * @param approvedItems Array of approved items, typically as defined in `Settings.xml`\n * @param onApprovedItemsChange Callback function that stores the updated list of approved items\n * @param unapprovedItems Array of unapproved items, typically as defined in `Settings.xml`\n * @param onUnapprovedItemsChange Callback function that stores the updated list of unapproved items\n * @returns Column that shows the status buttons for the related inventory item. The button for the\n * current status of the item is selected\n */\nexport const inventoryStatusColumn = (\n statusLabel: string,\n approvedItems: string[],\n onApprovedItemsChange: (items: string[]) => void,\n unapprovedItems: string[],\n onUnapprovedItemsChange: (items: string[]) => void,\n): ColumnDef => {\n return {\n accessorKey: 'status',\n header: ({ column }) => {\n return (\n
    \n \n
    \n );\n },\n cell: ({ row }) => {\n const status: Status = row.getValue('status');\n const item: string = row.getValue('item');\n return (\n \n \n statusChangeHandler(\n [item],\n 'approved',\n approvedItems,\n onApprovedItemsChange,\n unapprovedItems,\n onUnapprovedItemsChange,\n )\n }\n value=\"approved\"\n >\n \n \n \n statusChangeHandler(\n [item],\n 'unapproved',\n approvedItems,\n onApprovedItemsChange,\n unapprovedItems,\n onUnapprovedItemsChange,\n )\n }\n value=\"unapproved\"\n >\n \n \n \n statusChangeHandler(\n [item],\n 'unknown',\n approvedItems,\n onApprovedItemsChange,\n unapprovedItems,\n onUnapprovedItemsChange,\n )\n }\n value=\"unknown\"\n >\n \n \n \n );\n },\n };\n};\n","import DataTable, {\n ColumnDef,\n RowContents,\n RowSelectionState,\n TableContents,\n} from '@/components/advanced/data-table/data-table.component';\nimport OccurrencesTable from '@/components/advanced/inventory/occurrences-table.component';\nimport Checkbox from '@/components/shadcn-ui/checkbox';\nimport { Input } from '@/components/shadcn-ui/input';\nimport { Label } from '@/components/shadcn-ui/label';\nimport {\n Select,\n SelectContent,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\nimport {\n deepEqual,\n LocalizedStringValue,\n ScriptureReference,\n substring,\n} from 'platform-bible-utils';\nimport { useEffect, useMemo, useState } from 'react';\nimport {\n getBookNumFromId,\n getLinesFromUSFM,\n getNumberFromUSFM,\n getStatusForItem,\n InventoryItemOccurrence,\n InventoryTableData,\n Status,\n} from './inventory-utils';\nimport { inventoryAdditionalItemColumn } from './inventory-columns';\n\n/**\n * Object containing all keys used for localization in this component. If you're using this\n * component in an extension, you can pass it into the useLocalizedStrings hook to easily obtain the\n * localized strings and pass them into the localizedStrings prop of this component\n */\nexport const INVENTORY_STRING_KEYS = Object.freeze([\n '%webView_inventory_all%',\n '%webView_inventory_approved%',\n '%webView_inventory_unapproved%',\n '%webView_inventory_unknown%',\n '%webView_inventory_scope_currentBook%',\n '%webView_inventory_scope_chapter%',\n '%webView_inventory_scope_verse%',\n '%webView_inventory_filter_text%',\n '%webView_inventory_show_additional_items%',\n '%webView_inventory_occurrences_table_header_reference%',\n '%webView_inventory_occurrences_table_header_occurrence%',\n] as const);\n\nexport type InventoryLocalizedStrings = {\n [localizedInventoryKey in (typeof INVENTORY_STRING_KEYS)[number]]?: LocalizedStringValue;\n};\n\n/** Scope of scripture that the inventory can operate on */\nexport type Scope = 'book' | 'chapter' | 'verse';\n\n/** Status values that the status filter can select from */\ntype StatusFilter = Status | 'all';\n\n/** Text labels for the inventory columns and the control components of additional inventory items */\ntype AdditionalItemsLabels = {\n checkboxText?: string;\n tableHeaders?: string[];\n};\n\n/**\n * Filters data that is shown in the DataTable section of the Inventory\n *\n * @param itemData All inventory items and their related information\n * @param statusFilter Allows filtering by status (i.e. show all items, or only items that are\n * 'approved', 'unapproved' or 'unknown')\n * @param textFilter Allows filtering by text. All items that include the filter text will be\n * selected.\n * @returns Array of items and their related information that are matched by the specified filters\n */\nconst filterItemData = (\n itemData: InventoryTableData[],\n statusFilter: StatusFilter,\n textFilter: string,\n): InventoryTableData[] => {\n let filteredItemData: InventoryTableData[] = itemData;\n\n if (statusFilter !== 'all') {\n filteredItemData = filteredItemData.filter(\n (item) =>\n (statusFilter === 'approved' && item.status === 'approved') ||\n (statusFilter === 'unapproved' && item.status === 'unapproved') ||\n (statusFilter === 'unknown' && item.status === 'unknown'),\n );\n }\n\n if (textFilter !== '')\n filteredItemData = filteredItemData.filter((item) => item.items[0].includes(textFilter));\n\n return filteredItemData;\n};\n\n/**\n * Turns array of strings into array of inventory items, along with their count and status\n *\n * @param text The source scripture text that is searched for inventory items\n * @param scriptureRef The scripture reference that the application is currently set to\n * @param approvedItems Array of approved items, typically as defined in `Settings.xml`\n * @param unapprovedItems Array of unapproved items, typically as defined in `Settings.xml`\n * @param itemRegex Regular expression that describes what items this Inventory should extract from\n * the provided scripture text\n * @returns Array of inventory items, along with their count and status\n */\nconst createTableData = (\n text: string | undefined,\n scriptureRef: ScriptureReference,\n approvedItems: string[],\n unapprovedItems: string[],\n itemRegex: RegExp,\n): InventoryTableData[] => {\n if (!text) return [];\n\n const tableData: InventoryTableData[] = [];\n\n let currentBook: number | undefined = scriptureRef.bookNum;\n let currentChapter: number | undefined = scriptureRef.chapterNum;\n let currentVerse: number | undefined = scriptureRef.verseNum;\n\n const lines = getLinesFromUSFM(text);\n\n lines.forEach((line: string) => {\n if (line.startsWith('\\\\id')) {\n currentBook = getBookNumFromId(line);\n currentChapter = 0;\n currentVerse = 0;\n }\n if (line.startsWith('\\\\c')) {\n currentChapter = getNumberFromUSFM(line);\n currentVerse = 0;\n }\n if (line.startsWith('\\\\v')) {\n currentVerse = getNumberFromUSFM(line);\n if (currentChapter === 0) {\n currentChapter = scriptureRef.chapterNum;\n }\n }\n\n let match: RegExpExecArray | undefined = itemRegex.exec(line) ?? undefined;\n while (match) {\n const items: string[] = [];\n match.forEach((item) => items.push(item));\n const itemIndex = match.index;\n const existingItem = tableData.find((tableEntry) => deepEqual(tableEntry.items, items));\n const newReference: InventoryItemOccurrence = {\n reference: {\n bookNum: currentBook !== undefined ? currentBook : -1,\n chapterNum: currentChapter !== undefined ? currentChapter : -1,\n verseNum: currentVerse !== undefined ? currentVerse : -1,\n },\n text: substring(line, Math.max(0, itemIndex - 25), Math.min(itemIndex + 25, line.length)),\n };\n if (existingItem) {\n existingItem.count += 1;\n existingItem.occurrences.push(newReference);\n } else {\n const newItem: InventoryTableData = {\n items,\n count: 1,\n status: getStatusForItem(items[0], approvedItems, unapprovedItems),\n occurrences: [newReference],\n };\n tableData.push(newItem);\n }\n\n match = itemRegex.exec(line) ?? undefined;\n }\n });\n\n return tableData;\n};\n\n/**\n * Gets the localized value for the provided key\n *\n * @param strings Object containing localized string\n * @param key Key for a localized string\n * @returns The localized value for the provided key, if available. Returns the key if no localized\n * value is available\n */\nconst localizeString = (\n strings: InventoryLocalizedStrings,\n key: keyof InventoryLocalizedStrings,\n) => {\n return strings[key] ?? key;\n};\n\n/** Props for the Inventory component */\ntype InventoryProps = {\n /** The scripture reference that the application is currently set to */\n scriptureReference: ScriptureReference;\n /** Callback function that is executed when the scripture reference is changed */\n setScriptureReference: (scriptureReference: ScriptureReference) => void;\n /**\n * Object with all localized strings that the Inventory needs to work well across multiple\n * languages. When using this component with Platform.Bible, you can import\n * `INVENTORY_STRING_KEYS` from this library, pass it in to the Platform's localization hook, and\n * pass the localized keys that are returned by the hook into this prop.\n */\n localizedStrings: InventoryLocalizedStrings;\n /**\n * The logic that finds the desired items in the source text. This can either be a Regular\n * expression that captures one or multiple items (preferred), or a custom function that builds\n * and return an InventoryDataTable[] manually. Note: In case the logic captures more than one\n * item (i.e. InventoryTableData.items has a length greater than 1), you must provide text labels\n * for the related columns and control elements to show by setting the `additionalItemsLabels`\n * prop\n */\n extractItems:\n | RegExp\n | ((\n text: string | undefined,\n scriptureRef: ScriptureReference,\n approvedItems: string[],\n unapprovedItems: string[],\n ) => InventoryTableData[]);\n /**\n * Text labels for control elements and additional column headers in case your Inventory has more\n * than one item to show (e.g. The 'Preceding Marker' in the Markers Inventory)\n */\n additionalItemsLabels?: AdditionalItemsLabels;\n /** Array of approved items, typically as defined in `Settings.xml` */\n approvedItems: string[];\n /** Array of unapproved items, typically as defined in `Settings.xml` */\n unapprovedItems: string[];\n /** The source scripture text that is searched for in inventory items */\n text: string | undefined;\n /** Scope of scripture that the inventory will operate on */\n scope: Scope;\n /** Callback function that is executed when the scope is changed from the Inventory */\n onScopeChange: (scope: Scope) => void;\n /**\n * Column definitions for the Inventory data table. The most commonly used column definitions are\n * pre-configured for your convenience and can be imported (e.g. inventoryItemColumn,\n * inventoryAdditionalItemColumn inventoryCountColumn, and inventoryStatusColumn). If you need any\n * other columns you can add these yourself\n */\n columns: ColumnDef[];\n};\n\n/** Inventory component that is used to view and control the status of provided project settings */\nexport default function Inventory({\n scriptureReference,\n setScriptureReference,\n localizedStrings,\n extractItems,\n additionalItemsLabels,\n approvedItems,\n unapprovedItems,\n text,\n scope,\n onScopeChange,\n columns,\n}: InventoryProps) {\n const allItemsText = localizeString(localizedStrings, '%webView_inventory_all%');\n const approvedItemsText = localizeString(localizedStrings, '%webView_inventory_approved%');\n const unapprovedItemsText = localizeString(localizedStrings, '%webView_inventory_unapproved%');\n const unknownItemsText = localizeString(localizedStrings, '%webView_inventory_unknown%');\n const scopeBookText = localizeString(localizedStrings, '%webView_inventory_scope_currentBook%');\n const scopeChapterText = localizeString(localizedStrings, '%webView_inventory_scope_chapter%');\n const scopeVerseText = localizeString(localizedStrings, '%webView_inventory_scope_verse%');\n const filterText = localizeString(localizedStrings, '%webView_inventory_filter_text%');\n const showAdditionalItemsText = localizeString(\n localizedStrings,\n '%webView_inventory_show_additional_items%',\n );\n\n const [showAdditionalItems, setShowAdditionalItems] = useState(false);\n const [statusFilter, setStatusFilter] = useState('all');\n const [textFilter, setTextFilter] = useState('');\n const [selectedItem, setSelectedItem] = useState([]);\n\n const tableData: InventoryTableData[] = useMemo(() => {\n if (!text) return [];\n if (extractItems instanceof RegExp)\n return createTableData(\n text,\n scriptureReference,\n approvedItems,\n unapprovedItems,\n extractItems,\n );\n return extractItems(text, scriptureReference, approvedItems, unapprovedItems);\n }, [text, extractItems, scriptureReference, approvedItems, unapprovedItems]);\n\n const reducedTableData: InventoryTableData[] = useMemo(() => {\n if (showAdditionalItems) return tableData;\n\n const newTableData: InventoryTableData[] = [];\n\n tableData.forEach((tableEntry) => {\n const firstItem = tableEntry.items[0];\n\n const existingEntry = newTableData.find(\n (newTableEntry) => newTableEntry.items[0] === firstItem,\n );\n\n if (existingEntry) {\n existingEntry.count += tableEntry.count;\n existingEntry.occurrences = existingEntry.occurrences.concat(tableEntry.occurrences);\n } else {\n newTableData.push({\n items: [firstItem],\n count: tableEntry.count,\n occurrences: tableEntry.occurrences,\n status: tableEntry.status,\n });\n }\n });\n\n return newTableData;\n }, [showAdditionalItems, tableData]);\n\n const filteredTableData: InventoryTableData[] = useMemo(() => {\n return filterItemData(reducedTableData, statusFilter, textFilter);\n }, [reducedTableData, statusFilter, textFilter]);\n\n const allColumns: ColumnDef[] = useMemo(() => {\n if (!showAdditionalItems) return columns;\n\n const numberOfAdditionalItems = additionalItemsLabels?.tableHeaders?.length;\n if (!numberOfAdditionalItems) return columns;\n\n const additionalColumns: ColumnDef[] = [];\n\n for (let index = 0; index < numberOfAdditionalItems; index++) {\n additionalColumns.push(\n inventoryAdditionalItemColumn(\n additionalItemsLabels?.tableHeaders?.[index] || 'Additional Item',\n index + 1,\n ),\n );\n }\n\n return [...additionalColumns, ...columns];\n }, [additionalItemsLabels?.tableHeaders, columns, showAdditionalItems]);\n\n useEffect(() => {\n setSelectedItem([]);\n }, [filteredTableData]);\n\n const rowClickHandler = (\n row: RowContents,\n table: TableContents,\n ) => {\n table.setRowSelection(() => {\n const newSelection: RowSelectionState = {};\n newSelection[row.index] = true;\n return newSelection;\n });\n\n setSelectedItem(row.original.items);\n };\n\n const handleScopeChange = (value: string) => {\n if (value === 'book' || value === 'chapter' || value === 'verse') {\n onScopeChange(value);\n } else {\n throw new Error(`Invalid scope value: ${value}`);\n }\n };\n\n const handleStatusFilterChange = (value: string) => {\n if (value === 'all' || value === 'approved' || value === 'unapproved' || value === 'unknown') {\n setStatusFilter(value);\n } else {\n throw new Error(`Invalid status filter value: ${value}`);\n }\n };\n\n const occurrenceData: InventoryItemOccurrence[] = useMemo(() => {\n if (reducedTableData.length === 0 || selectedItem.length === 0) return [];\n const occurrence = reducedTableData.filter((tableEntry: InventoryTableData) => {\n return deepEqual(\n showAdditionalItems ? tableEntry.items : [tableEntry.items[0]],\n selectedItem,\n );\n });\n if (occurrence.length > 1) throw new Error('Selected item is not unique');\n return occurrence[0].occurrences;\n }, [selectedItem, showAdditionalItems, reducedTableData]);\n\n return (\n
    \n
    \n handleStatusFilterChange(value)}\n defaultValue={statusFilter}\n >\n \n \n \n \n {allItemsText}\n {approvedItemsText}\n {unapprovedItemsText}\n {unknownItemsText}\n \n \n \n {\n setTextFilter(event.target.value);\n }}\n />\n {additionalItemsLabels && (\n
    \n {\n setSelectedItem([]);\n setShowAdditionalItems(checked);\n }}\n />\n \n
    \n )}\n
    \n
    \n \n
    \n {occurrenceData.length > 0 && (\n
    \n \n
    \n )}\n
    \n );\n}\n","import { Input } from '@/components/shadcn-ui/input';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { useState } from 'react';\n\n/** Props for the SearchBar component. */\nexport type SearchBarProps = {\n className?: string;\n /**\n * Callback fired to handle the search query when button pressed\n *\n * @param searchQuery\n */\n onSearch: (searchQuery: string) => void;\n\n /** Optional string that appears in the search bar without a search string */\n placeholder?: string;\n\n /** Optional boolean to set the input base to full width */\n isFullWidth?: boolean;\n};\n\nexport default function SearchBar({\n className,\n onSearch,\n placeholder,\n isFullWidth,\n}: SearchBarProps) {\n const [searchQuery, setSearchQuery] = useState('');\n\n const handleInputChange = (searchString: string) => {\n setSearchQuery(searchString);\n onSearch(searchString);\n };\n\n return (\n handleInputChange(e.target.value)}\n />\n );\n}\n","// adapted from: https://github.com/shadcn-ui/ui/discussions/752\n\n'use client';\n\nimport { TabsContentProps, TabsListProps, TabsTriggerProps } from '@/components/shadcn-ui/tabs';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport * as TabsPrimitive from '@radix-ui/react-tabs';\nimport React from 'react';\n\nexport type VerticalTabsProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport type LeftTabsTriggerProps = TabsTriggerProps & {\n value: string;\n ref?: React.Ref;\n};\n\nexport const VerticalTabs = React.forwardRef<\n React.ElementRef,\n VerticalTabsProps\n>(({ className, ...props }, ref) => (\n \n));\n\nVerticalTabs.displayName = TabsPrimitive.List.displayName;\n\nexport const VerticalTabsList = React.forwardRef<\n React.ElementRef,\n TabsListProps\n>(({ className, ...props }, ref) => (\n \n));\nVerticalTabsList.displayName = TabsPrimitive.List.displayName;\n\nexport const VerticalTabsTrigger = React.forwardRef<\n React.ElementRef,\n LeftTabsTriggerProps\n>(({ className, ...props }, ref) => (\n \n));\n\nexport const VerticalTabsContent = React.forwardRef<\n React.ElementRef,\n TabsContentProps\n>(({ className, ...props }, ref) => (\n \n));\nVerticalTabsContent.displayName = TabsPrimitive.Content.displayName;\n","import SearchBar from '@/components/basics/search-bar.component';\nimport {\n VerticalTabs,\n VerticalTabsContent,\n VerticalTabsList,\n VerticalTabsTrigger,\n} from '@/components/basics/tabs-vertical';\nimport { ReactNode } from 'react';\n\nexport type TabKeyValueContent = {\n key: string;\n value: string;\n content: ReactNode;\n};\n\nexport type TabNavigationContentSearchProps = {\n /** List of values and keys for each tab this component should provide */\n tabList: TabKeyValueContent[];\n\n /** Handler to run when the value of the search bar changes */\n onSearch: (searchQuery: string) => void;\n\n /** Optional placeholder for the search bar */\n searchPlaceholder?: string;\n\n /** Optional title to include in the header */\n headerTitle?: string;\n\n /** Optional flag to make the search bar appear full width */\n isSearchBarFullWidth?: boolean;\n\n /** Text direction ltr or rtl */\n direction?: 'ltr' | 'rtl';\n};\n\nexport default function TabNavigationContentSearch({\n tabList,\n onSearch,\n searchPlaceholder,\n headerTitle,\n isSearchBarFullWidth = false,\n direction = 'ltr',\n}: TabNavigationContentSearchProps) {\n return (\n
    \n
    \n {headerTitle ?

    {headerTitle}

    : ''}\n \n
    \n \n \n {tabList.map((tab) => (\n \n {tab.value}\n \n ))}\n \n {tabList.map((tab) => (\n \n {tab.content}\n \n ))}\n \n
    \n );\n}\n","import React from 'react';\nimport * as SeparatorPrimitive from '@radix-ui/react-separator';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Separator = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, orientation = 'horizontal', decorative = true, ...props }, ref) => (\n \n));\nSeparator.displayName = SeparatorPrimitive.Root.displayName;\n\nexport { Separator };\n","import React from 'react';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nfunction Skeleton({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\n\nexport { Skeleton };\n","import React from 'react';\nimport * as TooltipPrimitive from '@radix-ui/react-tooltip';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst TooltipProvider = TooltipPrimitive.Provider;\n\nconst Tooltip = TooltipPrimitive.Root;\n\nconst TooltipTrigger = TooltipPrimitive.Trigger;\n\nconst TooltipContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, sideOffset = 4, ...props }, ref) => (\n \n));\nTooltipContent.displayName = TooltipPrimitive.Content.displayName;\n\nexport { Tooltip, TooltipTrigger, TooltipContent, TooltipProvider };\n","import React from 'react';\nimport { Slot } from '@radix-ui/react-slot';\nimport { VariantProps, cva } from 'class-variance-authority';\nimport { PanelLeft } from 'lucide-react';\n\nimport { Button } from '@/components/shadcn-ui/button';\nimport { Input } from '@/components/shadcn-ui/input';\nimport { Separator } from '@/components/shadcn-ui/separator';\nimport { Skeleton } from '@/components/shadcn-ui/skeleton';\nimport {\n Tooltip,\n TooltipContent,\n TooltipProvider,\n TooltipTrigger,\n} from '@/components/shadcn-ui/tooltip';\nimport { cn } from '@/utils/shadcn-ui.util';\n\n/**\n * Changes from the original code from Shadcn- Removed uses of useIsMobile, Sheet, and SheetContent.\n * Also removed the parts setting COOKIES.\n */\n\nconst SIDEBAR_WIDTH = '16rem';\nconst SIDEBAR_WIDTH_ICON = '3rem';\nconst SIDEBAR_KEYBOARD_SHORTCUT = 'b';\n\ntype SidebarContextProps = {\n state: 'expanded' | 'collapsed';\n open: boolean;\n setOpen: (open: boolean) => void;\n toggleSidebar: () => void;\n};\n\nconst SidebarContext = React.createContext(undefined);\n\nfunction useSidebar() {\n const context = React.useContext(SidebarContext);\n if (!context) {\n throw new Error('useSidebar must be used within a SidebarProvider.');\n }\n\n return context;\n}\n\nconst SidebarProvider = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & {\n defaultOpen?: boolean;\n open?: boolean;\n onOpenChange?: (open: boolean) => void;\n }\n>(\n (\n {\n defaultOpen = true,\n open: openProp,\n onOpenChange: setOpenProp,\n className,\n style,\n children,\n ...props\n },\n ref,\n ) => {\n // This is the internal state of the sidebar.\n // We use openProp and setOpenProp for control from outside the component.\n const [_open, _setOpen] = React.useState(defaultOpen);\n const isOpen = openProp ?? _open;\n const setOpen = React.useCallback(\n (value: boolean | ((value: boolean) => boolean)) => {\n const openState = typeof value === 'function' ? value(isOpen) : value;\n if (setOpenProp) {\n setOpenProp(openState);\n } else {\n _setOpen(openState);\n }\n },\n [setOpenProp, isOpen],\n );\n\n // Helper to toggle the sidebar.\n const toggleSidebar = React.useCallback(() => {\n return setOpen((open) => !open);\n }, [setOpen]);\n\n // Adds a keyboard shortcut to toggle the sidebar.\n React.useEffect(() => {\n const handleKeyDown = (event: KeyboardEvent) => {\n if (event.key === SIDEBAR_KEYBOARD_SHORTCUT && (event.metaKey || event.ctrlKey)) {\n event.preventDefault();\n toggleSidebar();\n }\n };\n\n window.addEventListener('keydown', handleKeyDown);\n return () => window.removeEventListener('keydown', handleKeyDown);\n }, [toggleSidebar]);\n\n // We add a state so that we can do data-state=\"expanded\" or \"collapsed\".\n // This makes it easier to style the sidebar with Tailwind classes.\n const state = isOpen ? 'expanded' : 'collapsed';\n\n const contextValue = React.useMemo(\n () => ({\n state,\n open: isOpen,\n setOpen,\n toggleSidebar,\n }),\n [state, isOpen, setOpen, toggleSidebar],\n );\n\n return (\n \n \n \n {children}\n
    \n \n \n );\n },\n);\nSidebarProvider.displayName = 'SidebarProvider';\n\nconst Sidebar = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & {\n side?: 'left' | 'right';\n variant?: 'sidebar' | 'floating' | 'inset';\n collapsible?: 'offcanvas' | 'icon' | 'none';\n }\n>(\n (\n {\n side = 'left',\n variant = 'sidebar',\n collapsible = 'offcanvas',\n className,\n children,\n ...props\n },\n ref,\n ) => {\n const { state } = useSidebar();\n\n if (collapsible === 'none') {\n return (\n \n {children}\n
    \n );\n }\n\n return (\n \n {/* This is what handles the sidebar gap on desktop */}\n \n \n \n {children}\n
    \n
    \n
    \n );\n },\n);\nSidebar.displayName = 'Sidebar';\n\nconst SidebarTrigger = React.forwardRef<\n React.ElementRef,\n React.ComponentProps\n>(({ className, onClick, ...props }, ref) => {\n const { toggleSidebar } = useSidebar();\n\n return (\n {\n onClick?.(event);\n toggleSidebar();\n }}\n {...props}\n >\n \n Toggle Sidebar\n \n );\n});\nSidebarTrigger.displayName = 'SidebarTrigger';\n\nconst SidebarRail = React.forwardRef>(\n ({ className, ...props }, ref) => {\n const { toggleSidebar } = useSidebar();\n\n return (\n \n );\n },\n);\nSidebarRail.displayName = 'SidebarRail';\n\nconst SidebarInset = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarInset.displayName = 'SidebarInset';\n\nconst SidebarInput = React.forwardRef<\n React.ElementRef,\n React.ComponentProps\n>(({ className, ...props }, ref) => {\n return (\n \n );\n});\nSidebarInput.displayName = 'SidebarInput';\n\nconst SidebarHeader = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarHeader.displayName = 'SidebarHeader';\n\nconst SidebarFooter = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarFooter.displayName = 'SidebarFooter';\n\nconst SidebarSeparator = React.forwardRef<\n React.ElementRef,\n React.ComponentProps\n>(({ className, ...props }, ref) => {\n return (\n \n );\n});\nSidebarSeparator.displayName = 'SidebarSeparator';\n\nconst SidebarContent = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarContent.displayName = 'SidebarContent';\n\nconst SidebarGroup = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarGroup.displayName = 'SidebarGroup';\n\nconst SidebarGroupLabel = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & { asChild?: boolean }\n>(({ className, asChild = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'div';\n\n return (\n svg]:tw-size-4 [&>svg]:tw-shrink-0',\n 'group-data-[collapsible=icon]:tw--mt-8 group-data-[collapsible=icon]:tw-opacity-0',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarGroupLabel.displayName = 'SidebarGroupLabel';\n\nconst SidebarGroupAction = React.forwardRef<\n HTMLButtonElement,\n React.ComponentProps<'button'> & { asChild?: boolean }\n>(({ className, asChild = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'button';\n\n return (\n svg]:tw-size-4 [&>svg]:tw-shrink-0',\n // Increases the hit area of the button on mobile.\n 'after:tw-absolute after:tw--inset-2 after:md:tw-hidden',\n 'group-data-[collapsible=icon]:tw-hidden',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarGroupAction.displayName = 'SidebarGroupAction';\n\nconst SidebarGroupContent = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarGroupContent.displayName = 'SidebarGroupContent';\n\nconst SidebarMenu = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenu.displayName = 'SidebarMenu';\n\nconst SidebarMenuItem = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenuItem.displayName = 'SidebarMenuItem';\n\nconst sidebarMenuButtonVariants = cva(\n // Removed data-[active=true]:tw-bg-sidebar-accent\n 'tw-peer/menu-button tw-flex tw-w-full tw-items-center tw-gap-2 tw-overflow-hidden tw-rounded-md tw-p-2 tw-text-left tw-text-sm tw-outline-none tw-ring-sidebar-ring tw-transition-[width,height,padding] hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground focus-visible:tw-ring-2 active:tw-bg-sidebar-accent active:tw-text-sidebar-accent-foreground disabled:tw-pointer-events-none disabled:tw-opacity-50 tw-group-has-[[data-sidebar=menu-action]]/menu-item:pr-8 aria-disabled:tw-pointer-events-none aria-disabled:tw-opacity-50 data-[active=true]:tw-font-medium data-[active=true]:tw-text-sidebar-accent-foreground data-[state=open]:hover:tw-bg-sidebar-accent data-[state=open]:hover:tw-text-sidebar-accent-foreground group-data-[collapsible=icon]:tw-!size-8 group-data-[collapsible=icon]:tw-!p-2 [&>span:last-child]:tw-truncate [&>svg]:tw-size-4 [&>svg]:tw-shrink-0',\n {\n variants: {\n variant: {\n default: 'hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground',\n outline:\n 'tw-bg-background tw-shadow-[0_0_0_1px_hsl(var(--sidebar-border))] hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground hover:tw-shadow-[0_0_0_1px_hsl(var(--sidebar-accent))]',\n },\n size: {\n default: 'tw-h-8 tw-text-sm',\n sm: 'tw-h-7 tw-text-xs',\n lg: 'tw-h-12 tw-text-sm group-data-[collapsible=icon]:tw-!p-0',\n },\n },\n defaultVariants: {\n variant: 'default',\n size: 'default',\n },\n },\n);\n\nconst SidebarMenuButton = React.forwardRef<\n HTMLButtonElement,\n React.ComponentProps<'button'> & {\n asChild?: boolean;\n isActive?: boolean;\n tooltip?: string | React.ComponentProps;\n } & VariantProps\n>(\n (\n {\n asChild = false,\n isActive = false,\n variant = 'default',\n size = 'default',\n tooltip,\n className,\n ...props\n },\n ref,\n ) => {\n const Comp = asChild ? Slot : 'button';\n const { state } = useSidebar();\n\n const button = (\n \n );\n\n if (!tooltip) {\n return button;\n }\n\n if (typeof tooltip === 'string') {\n // eslint-disable-next-line no-param-reassign\n tooltip = {\n children: tooltip,\n };\n }\n\n return (\n \n {button}\n \n );\n },\n);\nSidebarMenuButton.displayName = 'SidebarMenuButton';\n\nconst SidebarMenuAction = React.forwardRef<\n HTMLButtonElement,\n React.ComponentProps<'button'> & {\n asChild?: boolean;\n showOnHover?: boolean;\n }\n>(({ className, asChild = false, showOnHover = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'button';\n\n return (\n svg]:tw-size-4 [&>svg]:tw-shrink-0',\n // Increases the hit area of the button on mobile.\n 'after:tw-absolute after:tw--inset-2 after:md:tw-hidden',\n 'tw-peer-data-[size=sm]/menu-button:top-1',\n 'tw-peer-data-[size=default]/menu-button:top-1.5',\n 'tw-peer-data-[size=lg]/menu-button:top-2.5',\n 'group-data-[collapsible=icon]:tw-hidden',\n showOnHover &&\n 'tw-group-focus-within/menu-item:opacity-100 tw-group-hover/menu-item:opacity-100 tw-peer-data-[active=true]/menu-button:text-sidebar-accent-foreground data-[state=open]:tw-opacity-100 md:tw-opacity-0',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarMenuAction.displayName = 'SidebarMenuAction';\n\nconst SidebarMenuBadge = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenuBadge.displayName = 'SidebarMenuBadge';\n\nconst SidebarMenuSkeleton = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & {\n showIcon?: boolean;\n }\n>(({ className, showIcon = false, ...props }, ref) => {\n // Random width between 50 to 90%.\n const width = React.useMemo(() => {\n return `${Math.floor(Math.random() * 40) + 50}%`;\n }, []);\n\n return (\n \n {showIcon && (\n \n )}\n \n
    \n );\n});\nSidebarMenuSkeleton.displayName = 'SidebarMenuSkeleton';\n\nconst SidebarMenuSub = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenuSub.displayName = 'SidebarMenuSub';\n\nconst SidebarMenuSubItem = React.forwardRef>(\n ({ ...props }, ref) =>
  • ,\n);\nSidebarMenuSubItem.displayName = 'SidebarMenuSubItem';\n\nconst SidebarMenuSubButton = React.forwardRef<\n HTMLAnchorElement,\n React.ComponentProps<'a'> & {\n asChild?: boolean;\n size?: 'sm' | 'md';\n isActive?: boolean;\n }\n>(({ asChild = false, size = 'md', isActive, className, ...props }, ref) => {\n const Comp = asChild ? Slot : 'a';\n\n return (\n span:last-child]:tw-truncate [&>svg]:tw-size-4 [&>svg]:tw-shrink-0 [&>svg]:tw-text-sidebar-accent-foreground',\n 'data-[active=true]:tw-bg-sidebar-accent data-[active=true]:tw-text-sidebar-accent-foreground',\n size === 'sm' && 'tw-text-xs',\n size === 'md' && 'tw-text-sm',\n 'group-data-[collapsible=icon]:tw-hidden',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarMenuSubButton.displayName = 'SidebarMenuSubButton';\n\nexport {\n Sidebar,\n SidebarContent,\n SidebarFooter,\n SidebarGroup,\n SidebarGroupAction,\n SidebarGroupContent,\n SidebarGroupLabel,\n SidebarHeader,\n SidebarInput,\n SidebarInset,\n SidebarMenu,\n SidebarMenuAction,\n SidebarMenuBadge,\n SidebarMenuButton,\n SidebarMenuItem,\n SidebarMenuSkeleton,\n SidebarMenuSub,\n SidebarMenuSubButton,\n SidebarMenuSubItem,\n SidebarProvider,\n SidebarRail,\n SidebarSeparator,\n SidebarTrigger,\n useSidebar,\n};\n","import ComboBox, { ComboBoxOption } from '@/components/basics/combo-box.component';\nimport {\n Sidebar,\n SidebarContent,\n SidebarGroup,\n SidebarGroupLabel,\n SidebarGroupContent,\n SidebarMenu,\n SidebarMenuItem,\n SidebarMenuButton,\n} from '@/components/shadcn-ui/sidebar';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { useCallback } from 'react';\n\nexport type SelectedSettingsSidebarItem = {\n label: string;\n projectId?: string;\n};\n\nexport type ProjectInfo = { projectId: string; projectName: string };\n\nexport type SettingsSidebarProps = {\n /** Optional id for testing */\n id?: string;\n\n /** Extension labels from contribution */\n extensionLabels: string[];\n\n /** Project names and ids */\n projectOptions: ProjectInfo[];\n\n /** Handler for selecting a sidebar item */\n handleSelectSidebarItem: (key: string, projectId?: string) => void;\n\n /** The current selected value in the sidebar */\n selectedSidebarItem: SelectedSettingsSidebarItem;\n\n /** Label for the group of extensions setting groups */\n extensionsSidebarGroupLabel: string;\n\n /** Label for the group of projects settings */\n projectsSidebarGroupLabel: string;\n\n /** Placeholder text for the button */\n buttonPlaceholderText: string;\n};\n\nexport default function SettingsSidebar({\n id,\n extensionLabels,\n projectOptions,\n handleSelectSidebarItem,\n selectedSidebarItem,\n extensionsSidebarGroupLabel,\n projectsSidebarGroupLabel,\n buttonPlaceholderText,\n}: SettingsSidebarProps) {\n const handleSelectItem = useCallback(\n (item: string, projectId?: string) => {\n handleSelectSidebarItem(item, projectId);\n },\n [handleSelectSidebarItem],\n );\n\n const getProjectNameFromProjectId = useCallback(\n (projectId: string) => {\n const project = projectOptions.find((option) => option.projectId === projectId);\n return project ? project.projectName : projectId;\n },\n [projectOptions],\n );\n\n const getIsActive: (label: string) => boolean = useCallback(\n (label: string) => !selectedSidebarItem.projectId && label === selectedSidebarItem.label,\n [selectedSidebarItem],\n );\n\n return (\n \n \n \n \n {extensionsSidebarGroupLabel}\n \n \n \n {extensionLabels.map((label) => (\n \n handleSelectItem(label)}\n isActive={getIsActive(label)}\n >\n {label}\n \n \n ))}\n \n \n \n \n \n {projectsSidebarGroupLabel}\n \n \n option.projectId)}\n getOptionLabel={(projectId: ComboBoxOption) => {\n // This function expects a ComboBoxOption, but we know it is a string\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n return getProjectNameFromProjectId(projectId as string);\n }}\n buttonPlaceholder={buttonPlaceholderText}\n onChange={(projectId: string) => {\n const selectedProjectName = getProjectNameFromProjectId(projectId);\n handleSelectItem(selectedProjectName, projectId);\n }}\n value={selectedSidebarItem?.projectId ?? undefined}\n />\n \n \n \n \n );\n}\n","import { SidebarInset, SidebarProvider } from '@/components/shadcn-ui/sidebar';\nimport { PropsWithChildren } from 'react';\nimport SearchBar from '@/components/basics/search-bar.component';\nimport SettingsSidebar, { SettingsSidebarProps } from './settings-sidebar.component';\n\nexport type SettingsSidebarContentSearchProps = SettingsSidebarProps &\n PropsWithChildren & {\n /** Optional id for testing */\n id?: string;\n\n /** Handler to run when the value of the search bar changes */\n onSearch: (searchQuery: string) => void;\n };\n\nexport default function SettingsSidebarContentSearch({\n id,\n extensionLabels,\n projectOptions,\n children,\n handleSelectSidebarItem,\n selectedSidebarItem,\n onSearch,\n extensionsSidebarGroupLabel,\n projectsSidebarGroupLabel,\n buttonPlaceholderText,\n}: SettingsSidebarContentSearchProps) {\n return (\n
    \n
    \n \n
    \n \n \n {children}\n \n
    \n );\n}\n","import { Button } from '@/components/shadcn-ui/button';\nimport {\n Select,\n SelectContent,\n SelectGroup,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\nimport {\n Table,\n TableBody,\n TableCell,\n TableHead,\n TableHeader,\n TableRow,\n} from '@/components/shadcn-ui/table';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Canon } from '@sillsdev/scripture';\nimport {\n Cell,\n ColumnDef,\n flexRender,\n getCoreRowModel,\n getExpandedRowModel,\n getGroupedRowModel,\n getSortedRowModel,\n GroupingState,\n Row,\n RowSelectionState,\n SortingState,\n useReactTable,\n} from '@tanstack/react-table';\nimport '@/components/advanced/scripture-results-viewer/scripture-results-viewer.component.css';\nimport {\n compareScrRefs,\n formatScrRef,\n ScriptureSelection,\n scrRefToBBBCCCVVV,\n} from 'platform-bible-utils';\nimport { MouseEvent, useEffect, useMemo, useState } from 'react';\nimport { ChevronDown, ChevronLeft, ChevronRight } from 'lucide-react';\n\n/**\n * Information (e.g., a checking error or some other type of \"transient\" annotation) about something\n * noteworthy at a specific place in an instance of the Scriptures.\n */\nexport type ScriptureItemDetail = ScriptureSelection & {\n /**\n * Text of the error, note, etc. In the future, we might want to support something more than just\n * text so that a JSX element could be provided with a link or some other controls related to the\n * issue being reported.\n */\n detail: string;\n};\n\n/**\n * A uniquely identifiable source of results that can be displayed in the ScriptureResultsViewer.\n * Generally, the source will be a particular Scripture check, but there may be other types of\n * sources.\n */\nexport type ResultsSource = {\n /**\n * Uniquely identifies the source.\n *\n * @type {string}\n */\n id: string;\n\n /**\n * Name (potentially localized) of the source, suitable for display in the UI.\n *\n * @type {string}\n */\n displayName: string;\n};\n\nexport type ScriptureSrcItemDetail = ScriptureItemDetail & {\n /** Source/type of detail. Can be used for grouping. */\n source: ResultsSource;\n};\n\n/**\n * Represents a set of results keyed by Scripture reference. Generally, the source will be a\n * particular Scripture check, but this type also allows for other types of uniquely identifiable\n * sources.\n */\nexport type ResultsSet = {\n /**\n * The backing source associated with this set of results.\n *\n * @type {ResultsSource}\n */\n source: ResultsSource;\n\n /**\n * Array of Scripture item details (messages keyed by Scripture reference).\n *\n * @type {ScriptureItemDetail[]}\n */\n data: ScriptureItemDetail[];\n};\n\nconst scrBookColId = 'scrBook';\nconst scrRefColId = 'scrRef';\nconst typeColId = 'source';\nconst detailsColId = 'details';\n\nconst defaultScrRefColumnName = 'Scripture Reference';\nconst defaultScrBookGroupName = 'Scripture Book';\nconst defaultTypeColumnName = 'Type';\nconst defaultDetailsColumnName = 'Details';\n\nexport type ScriptureResultsViewerColumnInfo = {\n /** Optional header to display for the Reference column. Default value: 'Scripture Reference'. */\n scriptureReferenceColumnName?: string;\n\n /** Optional text to display to refer to the Scripture book group. Default value: 'Scripture Book'. */\n scriptureBookGroupName?: string;\n\n /** Optional header to display for the Type column. Default value: 'Type'. */\n typeColumnName?: string;\n\n /** Optional header to display for the Details column. Default value: 'Details' */\n detailsColumnName?: string;\n};\n\nexport type ScriptureResultsViewerProps = ScriptureResultsViewerColumnInfo & {\n /** Groups of ScriptureItemDetail objects from particular sources (e.g., Scripture checks) */\n sources: ResultsSet[];\n\n /** Flag indicating whether to display column headers. Default is false. */\n showColumnHeaders?: boolean;\n\n /** Flag indicating whether to display source column. Default is false. */\n showSourceColumn?: boolean;\n\n /** Callback function to notify when a row is selected */\n onRowSelected?: (selectedRow: ScriptureSrcItemDetail | undefined) => void;\n\n /** Text direction ltr or rtl */\n direction?: 'ltr' | 'rtl';\n};\n\nfunction getColumns(\n colInfo?: ScriptureResultsViewerColumnInfo,\n showSourceColumn?: boolean,\n): ColumnDef[] {\n const showSrcCol = showSourceColumn ?? false;\n return [\n {\n accessorFn: (row) =>\n `${Canon.bookNumberToId(row.start.bookNum)} ${row.start.chapterNum}:${row.start.verseNum}`,\n id: scrBookColId,\n header: colInfo?.scriptureReferenceColumnName ?? defaultScrRefColumnName,\n cell: (info) => {\n const row = info.row.original;\n if (info.row.getIsGrouped()) {\n return Canon.bookNumberToEnglishName(row.start.bookNum);\n }\n return info.row.groupingColumnId === scrBookColId ? formatScrRef(row.start) : undefined;\n },\n getGroupingValue: (row) => row.start.bookNum,\n sortingFn: (a, b) => {\n return compareScrRefs(a.original.start, b.original.start);\n },\n enableGrouping: true,\n },\n {\n accessorFn: (row) => formatScrRef(row.start),\n id: scrRefColId,\n header: undefined,\n cell: (info) => {\n const row = info.row.original;\n return info.row.getIsGrouped() ? undefined : formatScrRef(row.start);\n },\n sortingFn: (a, b) => {\n return compareScrRefs(a.original.start, b.original.start);\n },\n enableGrouping: false,\n },\n {\n accessorFn: (row) => row.source.displayName,\n id: typeColId,\n header: showSrcCol ? (colInfo?.typeColumnName ?? defaultTypeColumnName) : undefined,\n cell: (info) => (showSrcCol || info.row.getIsGrouped() ? info.getValue() : undefined),\n getGroupingValue: (row) => row.source.id,\n sortingFn: (a, b) =>\n a.original.source.displayName.localeCompare(b.original.source.displayName),\n enableGrouping: true,\n },\n {\n accessorFn: (row) => row.detail,\n id: detailsColId,\n header: colInfo?.detailsColumnName ?? defaultDetailsColumnName,\n cell: (info) => info.getValue(),\n enableGrouping: false,\n },\n ];\n}\n\nconst toRefOrRange = (scriptureSelection: ScriptureSelection) => {\n if (!('offset' in scriptureSelection.start))\n throw new Error('No offset available in range start');\n if (scriptureSelection.end && !('offset' in scriptureSelection.end))\n throw new Error('No offset available in range end');\n const { offset: offsetStart } = scriptureSelection.start;\n let offsetEnd: number = 0;\n if (scriptureSelection.end) ({ offset: offsetEnd } = scriptureSelection.end);\n if (\n !scriptureSelection.end ||\n compareScrRefs(scriptureSelection.start, scriptureSelection.end) === 0\n )\n return `${scrRefToBBBCCCVVV(scriptureSelection.start)}+${offsetStart}`;\n return `${scrRefToBBBCCCVVV(scriptureSelection.start)}+${offsetStart}-${scrRefToBBBCCCVVV(scriptureSelection.end)}+${offsetEnd}`;\n};\n\nconst getRowKey = (row: ScriptureSrcItemDetail) =>\n `${toRefOrRange({ start: row.start, end: row.end })} ${row.source.displayName} ${row.detail}`;\n\n/**\n * Component to display a combined list of detailed items from one or more sources, where the items\n * are keyed primarily by Scripture reference. This is particularly useful for displaying a list of\n * results from Scripture checks, but more generally could be used to display any \"results\" from any\n * source(s). The component allows for grouping by Scripture book, source, or both. By default, it\n * displays somewhat \"tree-like\" which allows it to be more horizontally compact and intuitive. But\n * it also has the option of displaying as a traditional table with column headings (with or without\n * the source column showing).\n */\nexport default function ScriptureResultsViewer({\n sources,\n showColumnHeaders = false,\n showSourceColumn = false,\n scriptureReferenceColumnName,\n scriptureBookGroupName,\n typeColumnName,\n detailsColumnName,\n onRowSelected,\n direction = 'ltr',\n}: ScriptureResultsViewerProps) {\n const [grouping, setGrouping] = useState([]);\n const [sorting, setSorting] = useState([{ id: scrBookColId, desc: false }]);\n const [rowSelection, setRowSelection] = useState({});\n\n const scriptureResults = useMemo(\n () =>\n sources.flatMap((source) => {\n return source.data.map((item) => ({\n ...item,\n source: source.source,\n }));\n }),\n [sources],\n );\n\n const columns = useMemo(\n () =>\n getColumns(\n {\n scriptureReferenceColumnName,\n typeColumnName,\n detailsColumnName,\n },\n showSourceColumn,\n ),\n [scriptureReferenceColumnName, typeColumnName, detailsColumnName, showSourceColumn],\n );\n\n useEffect(() => {\n // Ensure sorting is applied correctly when grouped by type\n if (grouping.includes(typeColId)) {\n setSorting([\n { id: typeColId, desc: false },\n { id: scrBookColId, desc: false },\n ]);\n } else {\n setSorting([{ id: scrBookColId, desc: false }]);\n }\n }, [grouping]);\n\n const table = useReactTable({\n data: scriptureResults,\n columns,\n state: {\n grouping,\n sorting,\n rowSelection,\n },\n onGroupingChange: setGrouping,\n onSortingChange: setSorting,\n onRowSelectionChange: setRowSelection,\n getExpandedRowModel: getExpandedRowModel(),\n getGroupedRowModel: getGroupedRowModel(),\n getCoreRowModel: getCoreRowModel(),\n getSortedRowModel: getSortedRowModel(),\n getRowId: getRowKey,\n autoResetExpanded: false,\n enableMultiRowSelection: false,\n enableSubRowSelection: false,\n });\n\n useEffect(() => {\n if (onRowSelected) {\n const selectedRows = table.getSelectedRowModel().rowsById;\n const keys = Object.keys(selectedRows);\n if (keys.length === 1) {\n const selectedRow = scriptureResults.find((row) => getRowKey(row) === keys[0]) || undefined;\n if (selectedRow) onRowSelected(selectedRow);\n }\n }\n }, [rowSelection, scriptureResults, onRowSelected, table]);\n\n // Define possible grouping options\n const scrBookGroupName = scriptureBookGroupName ?? defaultScrBookGroupName;\n const typeGroupName = typeColumnName ?? defaultTypeColumnName;\n\n const groupingOptions = [\n { label: 'No Grouping', value: [] },\n { label: `Group by ${scrBookGroupName}`, value: [scrBookColId] },\n { label: `Group by ${typeGroupName}`, value: [typeColId] },\n {\n label: `Group by ${scrBookGroupName} and ${typeGroupName}`,\n value: [scrBookColId, typeColId],\n },\n {\n label: `Group by ${typeGroupName} and ${scrBookGroupName}`,\n value: [typeColId, scrBookColId],\n },\n ];\n\n const handleSelectChange = (selectedGrouping: string) => {\n setGrouping(JSON.parse(selectedGrouping));\n };\n\n const handleRowClick = (row: Row, event: MouseEvent) => {\n if (!row.getIsGrouped() && !row.getIsSelected()) {\n row.getToggleSelectedHandler()(event);\n }\n };\n\n const getEvenOrOddBandingStyle = (row: Row, index: number) => {\n if (row.getIsGrouped()) return '';\n // UX has now said they don't think they want banding. I'm leaving in the code to\n // set even and odd styles, but there's nothing in the CSS to style them differently.\n // The \"even\" style used to also have tw-bg-neutral-300 (along with even) to create\n // a visual banding effect. That could be added back in if UX changes the decision.\n return cn('banded-row', index % 2 === 0 ? 'even' : 'odd');\n };\n\n const getIndent = (\n groupingState: GroupingState,\n row: Row,\n cell: Cell,\n ) => {\n if (groupingState?.length === 0 || row.depth < cell.column.getGroupedIndex()) return undefined;\n if (row.getIsGrouped()) {\n switch (row.depth) {\n case 1:\n return 'tw-ps-4';\n default:\n return undefined;\n }\n }\n switch (row.depth) {\n case 1:\n return 'tw-ps-8';\n case 2:\n return 'tw-ps-12';\n default:\n return undefined;\n }\n };\n\n return (\n
    \n {!showColumnHeaders && (\n {\n handleSelectChange(value);\n }}\n >\n \n \n \n \n \n {groupingOptions.map((option) => (\n \n {option.label}\n \n ))}\n \n \n \n )}\n \n {showColumnHeaders && (\n \n {table.getHeaderGroups().map((headerGroup) => (\n \n {headerGroup.headers\n .filter((h) => h.column.columnDef.header)\n .map((header) => (\n /* For sticky column headers to work, we probably need to change the default definition of the shadcn Table component. See https://github.com/shadcn-ui/ui/issues/1151 */\n \n {header.isPlaceholder ? undefined : (\n
    \n {header.column.getCanGroup() ? (\n \n {header.column.getIsGrouped() ? `🛑` : `👊 `}\n \n ) : undefined}{' '}\n {flexRender(header.column.columnDef.header, header.getContext())}\n
    \n )}\n
    \n ))}\n
    \n ))}\n
    \n )}\n \n {table.getRowModel().rows.map((row, rowIndex) => {\n return (\n handleRowClick(row, event)}\n >\n {row.getVisibleCells().map((cell) => {\n if (\n cell.getIsPlaceholder() ||\n (cell.column.columnDef.enableGrouping &&\n !cell.getIsGrouped() &&\n (cell.column.columnDef.id !== typeColId || !showSourceColumn))\n )\n return undefined;\n return (\n \n {(() => {\n if (cell.getIsGrouped()) {\n return (\n \n {row.getIsExpanded() && }\n {!row.getIsExpanded() &&\n (direction === 'ltr' ? : )}{' '}\n {flexRender(cell.column.columnDef.cell, cell.getContext())} (\n {row.subRows.length})\n \n );\n }\n\n // if (cell.getIsAggregated()) {\n // flexRender(\n // cell.column.columnDef.aggregatedCell ?? cell.column.columnDef.cell,\n // cell.getContext(),\n // );\n // }\n\n return flexRender(cell.column.columnDef.cell, cell.getContext());\n })()}\n \n );\n })}\n \n );\n })}\n \n
    \n
    \n );\n}\n","import {\n getLocalizeKeyForScrollGroupId,\n LanguageStrings,\n ScrollGroupId,\n} from 'platform-bible-utils';\nimport {\n Select,\n SelectContent,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\n\nconst DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS = {\n [getLocalizeKeyForScrollGroupId('undefined')]: 'Ø',\n [getLocalizeKeyForScrollGroupId(0)]: 'A',\n [getLocalizeKeyForScrollGroupId(1)]: 'B',\n [getLocalizeKeyForScrollGroupId(2)]: 'C',\n [getLocalizeKeyForScrollGroupId(3)]: 'D',\n [getLocalizeKeyForScrollGroupId(4)]: 'E',\n [getLocalizeKeyForScrollGroupId(5)]: 'F',\n [getLocalizeKeyForScrollGroupId(6)]: 'G',\n [getLocalizeKeyForScrollGroupId(7)]: 'H',\n [getLocalizeKeyForScrollGroupId(8)]: 'I',\n [getLocalizeKeyForScrollGroupId(9)]: 'J',\n [getLocalizeKeyForScrollGroupId(10)]: 'K',\n [getLocalizeKeyForScrollGroupId(11)]: 'L',\n [getLocalizeKeyForScrollGroupId(12)]: 'M',\n [getLocalizeKeyForScrollGroupId(13)]: 'N',\n [getLocalizeKeyForScrollGroupId(14)]: 'O',\n [getLocalizeKeyForScrollGroupId(15)]: 'P',\n [getLocalizeKeyForScrollGroupId(16)]: 'Q',\n [getLocalizeKeyForScrollGroupId(17)]: 'R',\n [getLocalizeKeyForScrollGroupId(18)]: 'S',\n [getLocalizeKeyForScrollGroupId(19)]: 'T',\n [getLocalizeKeyForScrollGroupId(20)]: 'U',\n [getLocalizeKeyForScrollGroupId(21)]: 'V',\n [getLocalizeKeyForScrollGroupId(22)]: 'W',\n [getLocalizeKeyForScrollGroupId(23)]: 'X',\n [getLocalizeKeyForScrollGroupId(24)]: 'Y',\n [getLocalizeKeyForScrollGroupId(25)]: 'Z',\n};\n\nexport type ScrollGroupSelectorProps = {\n /**\n * List of scroll group ids to show to the user. Either a {@link ScrollGroupId} or `undefined` for\n * no scroll group\n */\n availableScrollGroupIds: (ScrollGroupId | undefined)[];\n /** Currently selected scroll group id. `undefined` for no scroll group */\n scrollGroupId: ScrollGroupId | undefined;\n /** Callback function run when the user tries to change the scroll group id */\n onChangeScrollGroupId: (newScrollGroupId: ScrollGroupId | undefined) => void;\n /**\n * Localized strings to use for displaying scroll group ids. Must be an object whose keys are\n * `getLocalizeKeyForScrollGroupId(scrollGroupId)` for all scroll group ids (and `undefined` if\n * included) in {@link ScrollGroupSelectorProps.availableScrollGroupIds} and whose values are the\n * localized strings to use for those scroll group ids.\n *\n * Defaults to English localizations of English alphabet for scroll groups 0-25 (e.g. 0 is A) and\n * Ø for `undefined`. Will fill in any that are not provided with these English localizations.\n * Also, if any values match the keys, the English localization will be used. This is useful in\n * case you want to pass in a temporary version of the localized strings while your localized\n * strings load.\n *\n * @example\n *\n * ```typescript\n * const myScrollGroupIdLocalizedStrings = {\n * [getLocalizeKeyForScrollGroupId('undefined')]: 'Ø',\n * [getLocalizeKeyForScrollGroupId(0)]: 'A',\n * [getLocalizeKeyForScrollGroupId(1)]: 'B',\n * [getLocalizeKeyForScrollGroupId(2)]: 'C',\n * [getLocalizeKeyForScrollGroupId(3)]: 'D',\n * [getLocalizeKeyForScrollGroupId(4)]: 'E',\n * };\n * ```\n *\n * @example\n *\n * ```tsx\n * const availableScrollGroupIds = [undefined, 0, 1, 2, 3, 4];\n *\n * const localizeKeys = getLocalizeKeysForScrollGroupIds();\n *\n * const [localizedStrings] = useLocalizedStrings(localizeKeys);\n *\n * ...\n *\n * \n * ```\n */\n localizedStrings?: LanguageStrings;\n};\n\n/** Selector component for choosing a scroll group */\nexport default function ScrollGroupSelector({\n availableScrollGroupIds,\n scrollGroupId,\n onChangeScrollGroupId,\n localizedStrings = {},\n}: ScrollGroupSelectorProps) {\n const localizedStringsDefaulted = {\n ...DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS,\n ...Object.fromEntries(\n Object.entries(localizedStrings).map(\n ([localizedStringKey, localizedStringValue]: [string, string]) => [\n localizedStringKey,\n localizedStringKey === localizedStringValue &&\n localizedStringKey in DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS\n ? DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS[localizedStringKey]\n : localizedStringValue,\n ],\n ),\n ),\n };\n return (\n \n onChangeScrollGroupId(\n newScrollGroupString === 'undefined' ? undefined : parseInt(newScrollGroupString, 10),\n )\n }\n >\n \n \n \n \n {availableScrollGroupIds.map((scrollGroupOptionId) => (\n \n {localizedStringsDefaulted[getLocalizeKeyForScrollGroupId(scrollGroupOptionId)]}\n \n ))}\n \n \n );\n}\n","import { PropsWithChildren } from 'react';\nimport { Separator } from '@/components/shadcn-ui/separator';\n\n/** Props for the SettingsList component, currently just children */\ntype SettingsListProps = PropsWithChildren;\n\n/**\n * SettingsList component is a wrapper for list items. Rendered with a formatted div\n *\n * @param children To populate the list with\n * @returns Formatted div encompassing the children\n */\nexport function SettingsList({ children }: SettingsListProps) {\n return
    {children}
    ;\n}\n\n/** Props for SettingsListItem component */\ntype SettingsListItemProps = PropsWithChildren & {\n /** Primary text of the list item */\n primary: string;\n\n /** Optional text of the list item */\n secondary?: string | undefined;\n\n /** Optional boolean to display a message if the children aren't loaded yet. Defaults to false */\n isLoading?: boolean;\n\n /** Optional message to display if isLoading */\n loadingMessage?: string;\n};\n\n/**\n * SettingsListItem component is a common list item. Rendered with a formatted div\n *\n * @param primary Primary text of the list item\n * @param secondary Optional secondary text of the list item\n * @param isLoading Optional, to display a message if the action component isn't generated yet,\n * defaults to false\n * @param children The action component(s) to provide for this item\n * @param loadingMessage Optional, message to display if isLoading\n * @returns Formatted div encompassing the list item content\n */\nexport function SettingsListItem({\n primary,\n secondary,\n children,\n isLoading = false,\n loadingMessage,\n}: SettingsListItemProps) {\n return (\n
    \n
    \n

    {primary}

    \n

    \n {secondary}\n

    \n
    \n\n {isLoading ? (\n

    {loadingMessage}

    \n ) : (\n
    {children}
    \n )}\n
    \n );\n}\n\n/** Props for SettingsListHeader component */\ntype SettingsListHeaderProps = {\n /** The primary text of the list header */\n primary: string;\n\n /** Optional secondary text of the list header */\n secondary?: string | undefined;\n\n /** Optional boolean to include a separator underneath the secondary text. Defaults to false */\n includeSeparator?: boolean;\n};\n\n/**\n * SettingsListHeader component displays text above the list\n *\n * @param primary The primary text of the list header\n * @param secondary Optional secondary text of the list header\n * @param includeSeparator Optional boolean to include a separator underneath the secondary text.\n * Defaults to false\n * @returns Formatted div with list header content\n */\nexport function SettingsListHeader({\n primary,\n secondary,\n includeSeparator = false,\n}: SettingsListHeaderProps) {\n return (\n
    \n
    \n

    {primary}

    \n

    {secondary}

    \n
    \n {includeSeparator ? : ''}\n
    \n );\n}\n","import Checkbox from '@/components/shadcn-ui/checkbox';\nimport { Label } from '@/components/shadcn-ui/label';\n\nexport type ChecklistProps = {\n /** Optional string representing the id attribute of the Checklist */\n id?: string;\n /** Optional string representing CSS class name(s) for styling */\n className?: string;\n /** Array of strings representing the checkable items */\n listItems: string[];\n /** Array of strings representing the checked items */\n selectedListItems: string[];\n /**\n * Function that is called when a checkbox item is selected or deselected\n *\n * @param item The string description for this item\n * @param selected True if selected, false if not selected\n */\n handleSelectListItem: (item: string, selected: boolean) => void;\n\n /**\n * Optional function creates a label for a provided checkable item\n *\n * @param item The item for which a label is to be created\n * @returns A string representing the label text for the checkbox associated with that item\n */\n createLabel?: (item: string) => string;\n};\n\n/** Renders a list of checkboxes. Each checkbox corresponds to an item from the `listItems` array. */\nexport default function Checklist({\n id,\n className,\n listItems,\n selectedListItems,\n handleSelectListItem,\n createLabel,\n}: ChecklistProps) {\n return (\n
    \n {listItems.map((item) => (\n
    \n handleSelectListItem(item, value)}\n />\n \n
    \n ))}\n
    \n );\n}\n","function _interopRequireDefault(obj) {\n return obj && obj.__esModule ? obj : {\n \"default\": obj\n };\n}\nmodule.exports = _interopRequireDefault, module.exports.__esModule = true, module.exports[\"default\"] = module.exports;","export default function chainPropTypes(propType1, propType2) {\n if (process.env.NODE_ENV === 'production') {\n return () => null;\n }\n return function validate(...args) {\n return propType1(...args) || propType2(...args);\n };\n}","export default function _extends() {\n _extends = Object.assign ? Object.assign.bind() : function (target) {\n for (var i = 1; i < arguments.length; i++) {\n var source = arguments[i];\n for (var key in source) {\n if (Object.prototype.hasOwnProperty.call(source, key)) {\n target[key] = source[key];\n }\n }\n }\n return target;\n };\n return _extends.apply(this, arguments);\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\n// https://github.com/sindresorhus/is-plain-obj/blob/main/index.js\nexport function isPlainObject(item) {\n if (typeof item !== 'object' || item === null) {\n return false;\n }\n const prototype = Object.getPrototypeOf(item);\n return (prototype === null || prototype === Object.prototype || Object.getPrototypeOf(prototype) === null) && !(Symbol.toStringTag in item) && !(Symbol.iterator in item);\n}\nfunction deepClone(source) {\n if (!isPlainObject(source)) {\n return source;\n }\n const output = {};\n Object.keys(source).forEach(key => {\n output[key] = deepClone(source[key]);\n });\n return output;\n}\nexport default function deepmerge(target, source, options = {\n clone: true\n}) {\n const output = options.clone ? _extends({}, target) : target;\n if (isPlainObject(target) && isPlainObject(source)) {\n Object.keys(source).forEach(key => {\n // Avoid prototype pollution\n if (key === '__proto__') {\n return;\n }\n if (isPlainObject(source[key]) && key in target && isPlainObject(target[key])) {\n // Since `output` is a clone of `target` and we have narrowed `target` in this block we can cast to the same type.\n output[key] = deepmerge(target[key], source[key], options);\n } else if (options.clone) {\n output[key] = isPlainObject(source[key]) ? deepClone(source[key]) : source[key];\n } else {\n output[key] = source[key];\n }\n });\n }\n return output;\n}","/** @license React v16.13.1\n * react-is.production.min.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';var b=\"function\"===typeof Symbol&&Symbol.for,c=b?Symbol.for(\"react.element\"):60103,d=b?Symbol.for(\"react.portal\"):60106,e=b?Symbol.for(\"react.fragment\"):60107,f=b?Symbol.for(\"react.strict_mode\"):60108,g=b?Symbol.for(\"react.profiler\"):60114,h=b?Symbol.for(\"react.provider\"):60109,k=b?Symbol.for(\"react.context\"):60110,l=b?Symbol.for(\"react.async_mode\"):60111,m=b?Symbol.for(\"react.concurrent_mode\"):60111,n=b?Symbol.for(\"react.forward_ref\"):60112,p=b?Symbol.for(\"react.suspense\"):60113,q=b?\nSymbol.for(\"react.suspense_list\"):60120,r=b?Symbol.for(\"react.memo\"):60115,t=b?Symbol.for(\"react.lazy\"):60116,v=b?Symbol.for(\"react.block\"):60121,w=b?Symbol.for(\"react.fundamental\"):60117,x=b?Symbol.for(\"react.responder\"):60118,y=b?Symbol.for(\"react.scope\"):60119;\nfunction z(a){if(\"object\"===typeof a&&null!==a){var u=a.$$typeof;switch(u){case c:switch(a=a.type,a){case l:case m:case e:case g:case f:case p:return a;default:switch(a=a&&a.$$typeof,a){case k:case n:case t:case r:case h:return a;default:return u}}case d:return u}}}function A(a){return z(a)===m}exports.AsyncMode=l;exports.ConcurrentMode=m;exports.ContextConsumer=k;exports.ContextProvider=h;exports.Element=c;exports.ForwardRef=n;exports.Fragment=e;exports.Lazy=t;exports.Memo=r;exports.Portal=d;\nexports.Profiler=g;exports.StrictMode=f;exports.Suspense=p;exports.isAsyncMode=function(a){return A(a)||z(a)===l};exports.isConcurrentMode=A;exports.isContextConsumer=function(a){return z(a)===k};exports.isContextProvider=function(a){return z(a)===h};exports.isElement=function(a){return\"object\"===typeof a&&null!==a&&a.$$typeof===c};exports.isForwardRef=function(a){return z(a)===n};exports.isFragment=function(a){return z(a)===e};exports.isLazy=function(a){return z(a)===t};\nexports.isMemo=function(a){return z(a)===r};exports.isPortal=function(a){return z(a)===d};exports.isProfiler=function(a){return z(a)===g};exports.isStrictMode=function(a){return z(a)===f};exports.isSuspense=function(a){return z(a)===p};\nexports.isValidElementType=function(a){return\"string\"===typeof a||\"function\"===typeof a||a===e||a===m||a===g||a===f||a===p||a===q||\"object\"===typeof a&&null!==a&&(a.$$typeof===t||a.$$typeof===r||a.$$typeof===h||a.$$typeof===k||a.$$typeof===n||a.$$typeof===w||a.$$typeof===x||a.$$typeof===y||a.$$typeof===v)};exports.typeOf=z;\n","/** @license React v16.13.1\n * react-is.development.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\n\n\nif (process.env.NODE_ENV !== \"production\") {\n (function() {\n'use strict';\n\n// The Symbol used to tag the ReactElement-like types. If there is no native Symbol\n// nor polyfill, then a plain number is used for performance.\nvar hasSymbol = typeof Symbol === 'function' && Symbol.for;\nvar REACT_ELEMENT_TYPE = hasSymbol ? Symbol.for('react.element') : 0xeac7;\nvar REACT_PORTAL_TYPE = hasSymbol ? Symbol.for('react.portal') : 0xeaca;\nvar REACT_FRAGMENT_TYPE = hasSymbol ? Symbol.for('react.fragment') : 0xeacb;\nvar REACT_STRICT_MODE_TYPE = hasSymbol ? Symbol.for('react.strict_mode') : 0xeacc;\nvar REACT_PROFILER_TYPE = hasSymbol ? Symbol.for('react.profiler') : 0xead2;\nvar REACT_PROVIDER_TYPE = hasSymbol ? Symbol.for('react.provider') : 0xeacd;\nvar REACT_CONTEXT_TYPE = hasSymbol ? Symbol.for('react.context') : 0xeace; // TODO: We don't use AsyncMode or ConcurrentMode anymore. They were temporary\n// (unstable) APIs that have been removed. Can we remove the symbols?\n\nvar REACT_ASYNC_MODE_TYPE = hasSymbol ? Symbol.for('react.async_mode') : 0xeacf;\nvar REACT_CONCURRENT_MODE_TYPE = hasSymbol ? Symbol.for('react.concurrent_mode') : 0xeacf;\nvar REACT_FORWARD_REF_TYPE = hasSymbol ? Symbol.for('react.forward_ref') : 0xead0;\nvar REACT_SUSPENSE_TYPE = hasSymbol ? Symbol.for('react.suspense') : 0xead1;\nvar REACT_SUSPENSE_LIST_TYPE = hasSymbol ? Symbol.for('react.suspense_list') : 0xead8;\nvar REACT_MEMO_TYPE = hasSymbol ? Symbol.for('react.memo') : 0xead3;\nvar REACT_LAZY_TYPE = hasSymbol ? Symbol.for('react.lazy') : 0xead4;\nvar REACT_BLOCK_TYPE = hasSymbol ? Symbol.for('react.block') : 0xead9;\nvar REACT_FUNDAMENTAL_TYPE = hasSymbol ? Symbol.for('react.fundamental') : 0xead5;\nvar REACT_RESPONDER_TYPE = hasSymbol ? Symbol.for('react.responder') : 0xead6;\nvar REACT_SCOPE_TYPE = hasSymbol ? Symbol.for('react.scope') : 0xead7;\n\nfunction isValidElementType(type) {\n return typeof type === 'string' || typeof type === 'function' || // Note: its typeof might be other than 'symbol' or 'number' if it's a polyfill.\n type === REACT_FRAGMENT_TYPE || type === REACT_CONCURRENT_MODE_TYPE || type === REACT_PROFILER_TYPE || type === REACT_STRICT_MODE_TYPE || type === REACT_SUSPENSE_TYPE || type === REACT_SUSPENSE_LIST_TYPE || typeof type === 'object' && type !== null && (type.$$typeof === REACT_LAZY_TYPE || type.$$typeof === REACT_MEMO_TYPE || type.$$typeof === REACT_PROVIDER_TYPE || type.$$typeof === REACT_CONTEXT_TYPE || type.$$typeof === REACT_FORWARD_REF_TYPE || type.$$typeof === REACT_FUNDAMENTAL_TYPE || type.$$typeof === REACT_RESPONDER_TYPE || type.$$typeof === REACT_SCOPE_TYPE || type.$$typeof === REACT_BLOCK_TYPE);\n}\n\nfunction typeOf(object) {\n if (typeof object === 'object' && object !== null) {\n var $$typeof = object.$$typeof;\n\n switch ($$typeof) {\n case REACT_ELEMENT_TYPE:\n var type = object.type;\n\n switch (type) {\n case REACT_ASYNC_MODE_TYPE:\n case REACT_CONCURRENT_MODE_TYPE:\n case REACT_FRAGMENT_TYPE:\n case REACT_PROFILER_TYPE:\n case REACT_STRICT_MODE_TYPE:\n case REACT_SUSPENSE_TYPE:\n return type;\n\n default:\n var $$typeofType = type && type.$$typeof;\n\n switch ($$typeofType) {\n case REACT_CONTEXT_TYPE:\n case REACT_FORWARD_REF_TYPE:\n case REACT_LAZY_TYPE:\n case REACT_MEMO_TYPE:\n case REACT_PROVIDER_TYPE:\n return $$typeofType;\n\n default:\n return $$typeof;\n }\n\n }\n\n case REACT_PORTAL_TYPE:\n return $$typeof;\n }\n }\n\n return undefined;\n} // AsyncMode is deprecated along with isAsyncMode\n\nvar AsyncMode = REACT_ASYNC_MODE_TYPE;\nvar ConcurrentMode = REACT_CONCURRENT_MODE_TYPE;\nvar ContextConsumer = REACT_CONTEXT_TYPE;\nvar ContextProvider = REACT_PROVIDER_TYPE;\nvar Element = REACT_ELEMENT_TYPE;\nvar ForwardRef = REACT_FORWARD_REF_TYPE;\nvar Fragment = REACT_FRAGMENT_TYPE;\nvar Lazy = REACT_LAZY_TYPE;\nvar Memo = REACT_MEMO_TYPE;\nvar Portal = REACT_PORTAL_TYPE;\nvar Profiler = REACT_PROFILER_TYPE;\nvar StrictMode = REACT_STRICT_MODE_TYPE;\nvar Suspense = REACT_SUSPENSE_TYPE;\nvar hasWarnedAboutDeprecatedIsAsyncMode = false; // AsyncMode should be deprecated\n\nfunction isAsyncMode(object) {\n {\n if (!hasWarnedAboutDeprecatedIsAsyncMode) {\n hasWarnedAboutDeprecatedIsAsyncMode = true; // Using console['warn'] to evade Babel and ESLint\n\n console['warn']('The ReactIs.isAsyncMode() alias has been deprecated, ' + 'and will be removed in React 17+. Update your code to use ' + 'ReactIs.isConcurrentMode() instead. It has the exact same API.');\n }\n }\n\n return isConcurrentMode(object) || typeOf(object) === REACT_ASYNC_MODE_TYPE;\n}\nfunction isConcurrentMode(object) {\n return typeOf(object) === REACT_CONCURRENT_MODE_TYPE;\n}\nfunction isContextConsumer(object) {\n return typeOf(object) === REACT_CONTEXT_TYPE;\n}\nfunction isContextProvider(object) {\n return typeOf(object) === REACT_PROVIDER_TYPE;\n}\nfunction isElement(object) {\n return typeof object === 'object' && object !== null && object.$$typeof === REACT_ELEMENT_TYPE;\n}\nfunction isForwardRef(object) {\n return typeOf(object) === REACT_FORWARD_REF_TYPE;\n}\nfunction isFragment(object) {\n return typeOf(object) === REACT_FRAGMENT_TYPE;\n}\nfunction isLazy(object) {\n return typeOf(object) === REACT_LAZY_TYPE;\n}\nfunction isMemo(object) {\n return typeOf(object) === REACT_MEMO_TYPE;\n}\nfunction isPortal(object) {\n return typeOf(object) === REACT_PORTAL_TYPE;\n}\nfunction isProfiler(object) {\n return typeOf(object) === REACT_PROFILER_TYPE;\n}\nfunction isStrictMode(object) {\n return typeOf(object) === REACT_STRICT_MODE_TYPE;\n}\nfunction isSuspense(object) {\n return typeOf(object) === REACT_SUSPENSE_TYPE;\n}\n\nexports.AsyncMode = AsyncMode;\nexports.ConcurrentMode = ConcurrentMode;\nexports.ContextConsumer = ContextConsumer;\nexports.ContextProvider = ContextProvider;\nexports.Element = Element;\nexports.ForwardRef = ForwardRef;\nexports.Fragment = Fragment;\nexports.Lazy = Lazy;\nexports.Memo = Memo;\nexports.Portal = Portal;\nexports.Profiler = Profiler;\nexports.StrictMode = StrictMode;\nexports.Suspense = Suspense;\nexports.isAsyncMode = isAsyncMode;\nexports.isConcurrentMode = isConcurrentMode;\nexports.isContextConsumer = isContextConsumer;\nexports.isContextProvider = isContextProvider;\nexports.isElement = isElement;\nexports.isForwardRef = isForwardRef;\nexports.isFragment = isFragment;\nexports.isLazy = isLazy;\nexports.isMemo = isMemo;\nexports.isPortal = isPortal;\nexports.isProfiler = isProfiler;\nexports.isStrictMode = isStrictMode;\nexports.isSuspense = isSuspense;\nexports.isValidElementType = isValidElementType;\nexports.typeOf = typeOf;\n })();\n}\n","'use strict';\n\nif (process.env.NODE_ENV === 'production') {\n module.exports = require('./cjs/react-is.production.min.js');\n} else {\n module.exports = require('./cjs/react-is.development.js');\n}\n","/*\nobject-assign\n(c) Sindre Sorhus\n@license MIT\n*/\n\n'use strict';\n/* eslint-disable no-unused-vars */\nvar getOwnPropertySymbols = Object.getOwnPropertySymbols;\nvar hasOwnProperty = Object.prototype.hasOwnProperty;\nvar propIsEnumerable = Object.prototype.propertyIsEnumerable;\n\nfunction toObject(val) {\n\tif (val === null || val === undefined) {\n\t\tthrow new TypeError('Object.assign cannot be called with null or undefined');\n\t}\n\n\treturn Object(val);\n}\n\nfunction shouldUseNative() {\n\ttry {\n\t\tif (!Object.assign) {\n\t\t\treturn false;\n\t\t}\n\n\t\t// Detect buggy property enumeration order in older V8 versions.\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=4118\n\t\tvar test1 = new String('abc'); // eslint-disable-line no-new-wrappers\n\t\ttest1[5] = 'de';\n\t\tif (Object.getOwnPropertyNames(test1)[0] === '5') {\n\t\t\treturn false;\n\t\t}\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=3056\n\t\tvar test2 = {};\n\t\tfor (var i = 0; i < 10; i++) {\n\t\t\ttest2['_' + String.fromCharCode(i)] = i;\n\t\t}\n\t\tvar order2 = Object.getOwnPropertyNames(test2).map(function (n) {\n\t\t\treturn test2[n];\n\t\t});\n\t\tif (order2.join('') !== '0123456789') {\n\t\t\treturn false;\n\t\t}\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=3056\n\t\tvar test3 = {};\n\t\t'abcdefghijklmnopqrst'.split('').forEach(function (letter) {\n\t\t\ttest3[letter] = letter;\n\t\t});\n\t\tif (Object.keys(Object.assign({}, test3)).join('') !==\n\t\t\t\t'abcdefghijklmnopqrst') {\n\t\t\treturn false;\n\t\t}\n\n\t\treturn true;\n\t} catch (err) {\n\t\t// We don't expect any of the above to throw, but better to be safe.\n\t\treturn false;\n\t}\n}\n\nmodule.exports = shouldUseNative() ? Object.assign : function (target, source) {\n\tvar from;\n\tvar to = toObject(target);\n\tvar symbols;\n\n\tfor (var s = 1; s < arguments.length; s++) {\n\t\tfrom = Object(arguments[s]);\n\n\t\tfor (var key in from) {\n\t\t\tif (hasOwnProperty.call(from, key)) {\n\t\t\t\tto[key] = from[key];\n\t\t\t}\n\t\t}\n\n\t\tif (getOwnPropertySymbols) {\n\t\t\tsymbols = getOwnPropertySymbols(from);\n\t\t\tfor (var i = 0; i < symbols.length; i++) {\n\t\t\t\tif (propIsEnumerable.call(from, symbols[i])) {\n\t\t\t\t\tto[symbols[i]] = from[symbols[i]];\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\n\treturn to;\n};\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar ReactPropTypesSecret = 'SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED';\n\nmodule.exports = ReactPropTypesSecret;\n","module.exports = Function.call.bind(Object.prototype.hasOwnProperty);\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar printWarning = function() {};\n\nif (process.env.NODE_ENV !== 'production') {\n var ReactPropTypesSecret = require('./lib/ReactPropTypesSecret');\n var loggedTypeFailures = {};\n var has = require('./lib/has');\n\n printWarning = function(text) {\n var message = 'Warning: ' + text;\n if (typeof console !== 'undefined') {\n console.error(message);\n }\n try {\n // --- Welcome to debugging React ---\n // This error was thrown as a convenience so that you can use this stack\n // to find the callsite that caused this warning to fire.\n throw new Error(message);\n } catch (x) { /**/ }\n };\n}\n\n/**\n * Assert that the values match with the type specs.\n * Error messages are memorized and will only be shown once.\n *\n * @param {object} typeSpecs Map of name to a ReactPropType\n * @param {object} values Runtime values that need to be type-checked\n * @param {string} location e.g. \"prop\", \"context\", \"child context\"\n * @param {string} componentName Name of the component for error messages.\n * @param {?Function} getStack Returns the component stack.\n * @private\n */\nfunction checkPropTypes(typeSpecs, values, location, componentName, getStack) {\n if (process.env.NODE_ENV !== 'production') {\n for (var typeSpecName in typeSpecs) {\n if (has(typeSpecs, typeSpecName)) {\n var error;\n // Prop type validation may throw. In case they do, we don't want to\n // fail the render phase where it didn't fail before. So we log it.\n // After these have been cleaned up, we'll let them throw.\n try {\n // This is intentionally an invariant that gets caught. It's the same\n // behavior as without this statement except with a better message.\n if (typeof typeSpecs[typeSpecName] !== 'function') {\n var err = Error(\n (componentName || 'React class') + ': ' + location + ' type `' + typeSpecName + '` is invalid; ' +\n 'it must be a function, usually from the `prop-types` package, but received `' + typeof typeSpecs[typeSpecName] + '`.' +\n 'This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.'\n );\n err.name = 'Invariant Violation';\n throw err;\n }\n error = typeSpecs[typeSpecName](values, typeSpecName, componentName, location, null, ReactPropTypesSecret);\n } catch (ex) {\n error = ex;\n }\n if (error && !(error instanceof Error)) {\n printWarning(\n (componentName || 'React class') + ': type specification of ' +\n location + ' `' + typeSpecName + '` is invalid; the type checker ' +\n 'function must return `null` or an `Error` but returned a ' + typeof error + '. ' +\n 'You may have forgotten to pass an argument to the type checker ' +\n 'creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and ' +\n 'shape all require an argument).'\n );\n }\n if (error instanceof Error && !(error.message in loggedTypeFailures)) {\n // Only monitor this failure once because there tends to be a lot of the\n // same error.\n loggedTypeFailures[error.message] = true;\n\n var stack = getStack ? getStack() : '';\n\n printWarning(\n 'Failed ' + location + ' type: ' + error.message + (stack != null ? stack : '')\n );\n }\n }\n }\n }\n}\n\n/**\n * Resets warning cache when testing.\n *\n * @private\n */\ncheckPropTypes.resetWarningCache = function() {\n if (process.env.NODE_ENV !== 'production') {\n loggedTypeFailures = {};\n }\n}\n\nmodule.exports = checkPropTypes;\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar ReactIs = require('react-is');\nvar assign = require('object-assign');\n\nvar ReactPropTypesSecret = require('./lib/ReactPropTypesSecret');\nvar has = require('./lib/has');\nvar checkPropTypes = require('./checkPropTypes');\n\nvar printWarning = function() {};\n\nif (process.env.NODE_ENV !== 'production') {\n printWarning = function(text) {\n var message = 'Warning: ' + text;\n if (typeof console !== 'undefined') {\n console.error(message);\n }\n try {\n // --- Welcome to debugging React ---\n // This error was thrown as a convenience so that you can use this stack\n // to find the callsite that caused this warning to fire.\n throw new Error(message);\n } catch (x) {}\n };\n}\n\nfunction emptyFunctionThatReturnsNull() {\n return null;\n}\n\nmodule.exports = function(isValidElement, throwOnDirectAccess) {\n /* global Symbol */\n var ITERATOR_SYMBOL = typeof Symbol === 'function' && Symbol.iterator;\n var FAUX_ITERATOR_SYMBOL = '@@iterator'; // Before Symbol spec.\n\n /**\n * Returns the iterator method function contained on the iterable object.\n *\n * Be sure to invoke the function with the iterable as context:\n *\n * var iteratorFn = getIteratorFn(myIterable);\n * if (iteratorFn) {\n * var iterator = iteratorFn.call(myIterable);\n * ...\n * }\n *\n * @param {?object} maybeIterable\n * @return {?function}\n */\n function getIteratorFn(maybeIterable) {\n var iteratorFn = maybeIterable && (ITERATOR_SYMBOL && maybeIterable[ITERATOR_SYMBOL] || maybeIterable[FAUX_ITERATOR_SYMBOL]);\n if (typeof iteratorFn === 'function') {\n return iteratorFn;\n }\n }\n\n /**\n * Collection of methods that allow declaration and validation of props that are\n * supplied to React components. Example usage:\n *\n * var Props = require('ReactPropTypes');\n * var MyArticle = React.createClass({\n * propTypes: {\n * // An optional string prop named \"description\".\n * description: Props.string,\n *\n * // A required enum prop named \"category\".\n * category: Props.oneOf(['News','Photos']).isRequired,\n *\n * // A prop named \"dialog\" that requires an instance of Dialog.\n * dialog: Props.instanceOf(Dialog).isRequired\n * },\n * render: function() { ... }\n * });\n *\n * A more formal specification of how these methods are used:\n *\n * type := array|bool|func|object|number|string|oneOf([...])|instanceOf(...)\n * decl := ReactPropTypes.{type}(.isRequired)?\n *\n * Each and every declaration produces a function with the same signature. This\n * allows the creation of custom validation functions. For example:\n *\n * var MyLink = React.createClass({\n * propTypes: {\n * // An optional string or URI prop named \"href\".\n * href: function(props, propName, componentName) {\n * var propValue = props[propName];\n * if (propValue != null && typeof propValue !== 'string' &&\n * !(propValue instanceof URI)) {\n * return new Error(\n * 'Expected a string or an URI for ' + propName + ' in ' +\n * componentName\n * );\n * }\n * }\n * },\n * render: function() {...}\n * });\n *\n * @internal\n */\n\n var ANONYMOUS = '<>';\n\n // Important!\n // Keep this list in sync with production version in `./factoryWithThrowingShims.js`.\n var ReactPropTypes = {\n array: createPrimitiveTypeChecker('array'),\n bigint: createPrimitiveTypeChecker('bigint'),\n bool: createPrimitiveTypeChecker('boolean'),\n func: createPrimitiveTypeChecker('function'),\n number: createPrimitiveTypeChecker('number'),\n object: createPrimitiveTypeChecker('object'),\n string: createPrimitiveTypeChecker('string'),\n symbol: createPrimitiveTypeChecker('symbol'),\n\n any: createAnyTypeChecker(),\n arrayOf: createArrayOfTypeChecker,\n element: createElementTypeChecker(),\n elementType: createElementTypeTypeChecker(),\n instanceOf: createInstanceTypeChecker,\n node: createNodeChecker(),\n objectOf: createObjectOfTypeChecker,\n oneOf: createEnumTypeChecker,\n oneOfType: createUnionTypeChecker,\n shape: createShapeTypeChecker,\n exact: createStrictShapeTypeChecker,\n };\n\n /**\n * inlined Object.is polyfill to avoid requiring consumers ship their own\n * https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object/is\n */\n /*eslint-disable no-self-compare*/\n function is(x, y) {\n // SameValue algorithm\n if (x === y) {\n // Steps 1-5, 7-10\n // Steps 6.b-6.e: +0 != -0\n return x !== 0 || 1 / x === 1 / y;\n } else {\n // Step 6.a: NaN == NaN\n return x !== x && y !== y;\n }\n }\n /*eslint-enable no-self-compare*/\n\n /**\n * We use an Error-like object for backward compatibility as people may call\n * PropTypes directly and inspect their output. However, we don't use real\n * Errors anymore. We don't inspect their stack anyway, and creating them\n * is prohibitively expensive if they are created too often, such as what\n * happens in oneOfType() for any type before the one that matched.\n */\n function PropTypeError(message, data) {\n this.message = message;\n this.data = data && typeof data === 'object' ? data: {};\n this.stack = '';\n }\n // Make `instanceof Error` still work for returned errors.\n PropTypeError.prototype = Error.prototype;\n\n function createChainableTypeChecker(validate) {\n if (process.env.NODE_ENV !== 'production') {\n var manualPropTypeCallCache = {};\n var manualPropTypeWarningCount = 0;\n }\n function checkType(isRequired, props, propName, componentName, location, propFullName, secret) {\n componentName = componentName || ANONYMOUS;\n propFullName = propFullName || propName;\n\n if (secret !== ReactPropTypesSecret) {\n if (throwOnDirectAccess) {\n // New behavior only for users of `prop-types` package\n var err = new Error(\n 'Calling PropTypes validators directly is not supported by the `prop-types` package. ' +\n 'Use `PropTypes.checkPropTypes()` to call them. ' +\n 'Read more at http://fb.me/use-check-prop-types'\n );\n err.name = 'Invariant Violation';\n throw err;\n } else if (process.env.NODE_ENV !== 'production' && typeof console !== 'undefined') {\n // Old behavior for people using React.PropTypes\n var cacheKey = componentName + ':' + propName;\n if (\n !manualPropTypeCallCache[cacheKey] &&\n // Avoid spamming the console because they are often not actionable except for lib authors\n manualPropTypeWarningCount < 3\n ) {\n printWarning(\n 'You are manually calling a React.PropTypes validation ' +\n 'function for the `' + propFullName + '` prop on `' + componentName + '`. This is deprecated ' +\n 'and will throw in the standalone `prop-types` package. ' +\n 'You may be seeing this warning due to a third-party PropTypes ' +\n 'library. See https://fb.me/react-warning-dont-call-proptypes ' + 'for details.'\n );\n manualPropTypeCallCache[cacheKey] = true;\n manualPropTypeWarningCount++;\n }\n }\n }\n if (props[propName] == null) {\n if (isRequired) {\n if (props[propName] === null) {\n return new PropTypeError('The ' + location + ' `' + propFullName + '` is marked as required ' + ('in `' + componentName + '`, but its value is `null`.'));\n }\n return new PropTypeError('The ' + location + ' `' + propFullName + '` is marked as required in ' + ('`' + componentName + '`, but its value is `undefined`.'));\n }\n return null;\n } else {\n return validate(props, propName, componentName, location, propFullName);\n }\n }\n\n var chainedCheckType = checkType.bind(null, false);\n chainedCheckType.isRequired = checkType.bind(null, true);\n\n return chainedCheckType;\n }\n\n function createPrimitiveTypeChecker(expectedType) {\n function validate(props, propName, componentName, location, propFullName, secret) {\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== expectedType) {\n // `propValue` being instance of, say, date/regexp, pass the 'object'\n // check, but we can offer a more precise error message here rather than\n // 'of type `object`'.\n var preciseType = getPreciseType(propValue);\n\n return new PropTypeError(\n 'Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + preciseType + '` supplied to `' + componentName + '`, expected ') + ('`' + expectedType + '`.'),\n {expectedType: expectedType}\n );\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createAnyTypeChecker() {\n return createChainableTypeChecker(emptyFunctionThatReturnsNull);\n }\n\n function createArrayOfTypeChecker(typeChecker) {\n function validate(props, propName, componentName, location, propFullName) {\n if (typeof typeChecker !== 'function') {\n return new PropTypeError('Property `' + propFullName + '` of component `' + componentName + '` has invalid PropType notation inside arrayOf.');\n }\n var propValue = props[propName];\n if (!Array.isArray(propValue)) {\n var propType = getPropType(propValue);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected an array.'));\n }\n for (var i = 0; i < propValue.length; i++) {\n var error = typeChecker(propValue, i, componentName, location, propFullName + '[' + i + ']', ReactPropTypesSecret);\n if (error instanceof Error) {\n return error;\n }\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createElementTypeChecker() {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n if (!isValidElement(propValue)) {\n var propType = getPropType(propValue);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected a single ReactElement.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createElementTypeTypeChecker() {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n if (!ReactIs.isValidElementType(propValue)) {\n var propType = getPropType(propValue);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected a single ReactElement type.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createInstanceTypeChecker(expectedClass) {\n function validate(props, propName, componentName, location, propFullName) {\n if (!(props[propName] instanceof expectedClass)) {\n var expectedClassName = expectedClass.name || ANONYMOUS;\n var actualClassName = getClassName(props[propName]);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + actualClassName + '` supplied to `' + componentName + '`, expected ') + ('instance of `' + expectedClassName + '`.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createEnumTypeChecker(expectedValues) {\n if (!Array.isArray(expectedValues)) {\n if (process.env.NODE_ENV !== 'production') {\n if (arguments.length > 1) {\n printWarning(\n 'Invalid arguments supplied to oneOf, expected an array, got ' + arguments.length + ' arguments. ' +\n 'A common mistake is to write oneOf(x, y, z) instead of oneOf([x, y, z]).'\n );\n } else {\n printWarning('Invalid argument supplied to oneOf, expected an array.');\n }\n }\n return emptyFunctionThatReturnsNull;\n }\n\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n for (var i = 0; i < expectedValues.length; i++) {\n if (is(propValue, expectedValues[i])) {\n return null;\n }\n }\n\n var valuesString = JSON.stringify(expectedValues, function replacer(key, value) {\n var type = getPreciseType(value);\n if (type === 'symbol') {\n return String(value);\n }\n return value;\n });\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of value `' + String(propValue) + '` ' + ('supplied to `' + componentName + '`, expected one of ' + valuesString + '.'));\n }\n return createChainableTypeChecker(validate);\n }\n\n function createObjectOfTypeChecker(typeChecker) {\n function validate(props, propName, componentName, location, propFullName) {\n if (typeof typeChecker !== 'function') {\n return new PropTypeError('Property `' + propFullName + '` of component `' + componentName + '` has invalid PropType notation inside objectOf.');\n }\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== 'object') {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected an object.'));\n }\n for (var key in propValue) {\n if (has(propValue, key)) {\n var error = typeChecker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret);\n if (error instanceof Error) {\n return error;\n }\n }\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createUnionTypeChecker(arrayOfTypeCheckers) {\n if (!Array.isArray(arrayOfTypeCheckers)) {\n process.env.NODE_ENV !== 'production' ? printWarning('Invalid argument supplied to oneOfType, expected an instance of array.') : void 0;\n return emptyFunctionThatReturnsNull;\n }\n\n for (var i = 0; i < arrayOfTypeCheckers.length; i++) {\n var checker = arrayOfTypeCheckers[i];\n if (typeof checker !== 'function') {\n printWarning(\n 'Invalid argument supplied to oneOfType. Expected an array of check functions, but ' +\n 'received ' + getPostfixForTypeWarning(checker) + ' at index ' + i + '.'\n );\n return emptyFunctionThatReturnsNull;\n }\n }\n\n function validate(props, propName, componentName, location, propFullName) {\n var expectedTypes = [];\n for (var i = 0; i < arrayOfTypeCheckers.length; i++) {\n var checker = arrayOfTypeCheckers[i];\n var checkerResult = checker(props, propName, componentName, location, propFullName, ReactPropTypesSecret);\n if (checkerResult == null) {\n return null;\n }\n if (checkerResult.data && has(checkerResult.data, 'expectedType')) {\n expectedTypes.push(checkerResult.data.expectedType);\n }\n }\n var expectedTypesMessage = (expectedTypes.length > 0) ? ', expected one of type [' + expectedTypes.join(', ') + ']': '';\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` supplied to ' + ('`' + componentName + '`' + expectedTypesMessage + '.'));\n }\n return createChainableTypeChecker(validate);\n }\n\n function createNodeChecker() {\n function validate(props, propName, componentName, location, propFullName) {\n if (!isNode(props[propName])) {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` supplied to ' + ('`' + componentName + '`, expected a ReactNode.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function invalidValidatorError(componentName, location, propFullName, key, type) {\n return new PropTypeError(\n (componentName || 'React class') + ': ' + location + ' type `' + propFullName + '.' + key + '` is invalid; ' +\n 'it must be a function, usually from the `prop-types` package, but received `' + type + '`.'\n );\n }\n\n function createShapeTypeChecker(shapeTypes) {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== 'object') {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type `' + propType + '` ' + ('supplied to `' + componentName + '`, expected `object`.'));\n }\n for (var key in shapeTypes) {\n var checker = shapeTypes[key];\n if (typeof checker !== 'function') {\n return invalidValidatorError(componentName, location, propFullName, key, getPreciseType(checker));\n }\n var error = checker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret);\n if (error) {\n return error;\n }\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createStrictShapeTypeChecker(shapeTypes) {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== 'object') {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type `' + propType + '` ' + ('supplied to `' + componentName + '`, expected `object`.'));\n }\n // We need to check all keys in case some are required but missing from props.\n var allKeys = assign({}, props[propName], shapeTypes);\n for (var key in allKeys) {\n var checker = shapeTypes[key];\n if (has(shapeTypes, key) && typeof checker !== 'function') {\n return invalidValidatorError(componentName, location, propFullName, key, getPreciseType(checker));\n }\n if (!checker) {\n return new PropTypeError(\n 'Invalid ' + location + ' `' + propFullName + '` key `' + key + '` supplied to `' + componentName + '`.' +\n '\\nBad object: ' + JSON.stringify(props[propName], null, ' ') +\n '\\nValid keys: ' + JSON.stringify(Object.keys(shapeTypes), null, ' ')\n );\n }\n var error = checker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret);\n if (error) {\n return error;\n }\n }\n return null;\n }\n\n return createChainableTypeChecker(validate);\n }\n\n function isNode(propValue) {\n switch (typeof propValue) {\n case 'number':\n case 'string':\n case 'undefined':\n return true;\n case 'boolean':\n return !propValue;\n case 'object':\n if (Array.isArray(propValue)) {\n return propValue.every(isNode);\n }\n if (propValue === null || isValidElement(propValue)) {\n return true;\n }\n\n var iteratorFn = getIteratorFn(propValue);\n if (iteratorFn) {\n var iterator = iteratorFn.call(propValue);\n var step;\n if (iteratorFn !== propValue.entries) {\n while (!(step = iterator.next()).done) {\n if (!isNode(step.value)) {\n return false;\n }\n }\n } else {\n // Iterator will provide entry [k,v] tuples rather than values.\n while (!(step = iterator.next()).done) {\n var entry = step.value;\n if (entry) {\n if (!isNode(entry[1])) {\n return false;\n }\n }\n }\n }\n } else {\n return false;\n }\n\n return true;\n default:\n return false;\n }\n }\n\n function isSymbol(propType, propValue) {\n // Native Symbol.\n if (propType === 'symbol') {\n return true;\n }\n\n // falsy value can't be a Symbol\n if (!propValue) {\n return false;\n }\n\n // 19.4.3.5 Symbol.prototype[@@toStringTag] === 'Symbol'\n if (propValue['@@toStringTag'] === 'Symbol') {\n return true;\n }\n\n // Fallback for non-spec compliant Symbols which are polyfilled.\n if (typeof Symbol === 'function' && propValue instanceof Symbol) {\n return true;\n }\n\n return false;\n }\n\n // Equivalent of `typeof` but with special handling for array and regexp.\n function getPropType(propValue) {\n var propType = typeof propValue;\n if (Array.isArray(propValue)) {\n return 'array';\n }\n if (propValue instanceof RegExp) {\n // Old webkits (at least until Android 4.0) return 'function' rather than\n // 'object' for typeof a RegExp. We'll normalize this here so that /bla/\n // passes PropTypes.object.\n return 'object';\n }\n if (isSymbol(propType, propValue)) {\n return 'symbol';\n }\n return propType;\n }\n\n // This handles more types than `getPropType`. Only used for error messages.\n // See `createPrimitiveTypeChecker`.\n function getPreciseType(propValue) {\n if (typeof propValue === 'undefined' || propValue === null) {\n return '' + propValue;\n }\n var propType = getPropType(propValue);\n if (propType === 'object') {\n if (propValue instanceof Date) {\n return 'date';\n } else if (propValue instanceof RegExp) {\n return 'regexp';\n }\n }\n return propType;\n }\n\n // Returns a string that is postfixed to a warning about an invalid type.\n // For example, \"undefined\" or \"of type array\"\n function getPostfixForTypeWarning(value) {\n var type = getPreciseType(value);\n switch (type) {\n case 'array':\n case 'object':\n return 'an ' + type;\n case 'boolean':\n case 'date':\n case 'regexp':\n return 'a ' + type;\n default:\n return type;\n }\n }\n\n // Returns class name of the object, if any.\n function getClassName(propValue) {\n if (!propValue.constructor || !propValue.constructor.name) {\n return ANONYMOUS;\n }\n return propValue.constructor.name;\n }\n\n ReactPropTypes.checkPropTypes = checkPropTypes;\n ReactPropTypes.resetWarningCache = checkPropTypes.resetWarningCache;\n ReactPropTypes.PropTypes = ReactPropTypes;\n\n return ReactPropTypes;\n};\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar ReactPropTypesSecret = require('./lib/ReactPropTypesSecret');\n\nfunction emptyFunction() {}\nfunction emptyFunctionWithReset() {}\nemptyFunctionWithReset.resetWarningCache = emptyFunction;\n\nmodule.exports = function() {\n function shim(props, propName, componentName, location, propFullName, secret) {\n if (secret === ReactPropTypesSecret) {\n // It is still safe when called from React.\n return;\n }\n var err = new Error(\n 'Calling PropTypes validators directly is not supported by the `prop-types` package. ' +\n 'Use PropTypes.checkPropTypes() to call them. ' +\n 'Read more at http://fb.me/use-check-prop-types'\n );\n err.name = 'Invariant Violation';\n throw err;\n };\n shim.isRequired = shim;\n function getShim() {\n return shim;\n };\n // Important!\n // Keep this list in sync with production version in `./factoryWithTypeCheckers.js`.\n var ReactPropTypes = {\n array: shim,\n bigint: shim,\n bool: shim,\n func: shim,\n number: shim,\n object: shim,\n string: shim,\n symbol: shim,\n\n any: shim,\n arrayOf: getShim,\n element: shim,\n elementType: shim,\n instanceOf: getShim,\n node: shim,\n objectOf: getShim,\n oneOf: getShim,\n oneOfType: getShim,\n shape: getShim,\n exact: getShim,\n\n checkPropTypes: emptyFunctionWithReset,\n resetWarningCache: emptyFunction\n };\n\n ReactPropTypes.PropTypes = ReactPropTypes;\n\n return ReactPropTypes;\n};\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\nif (process.env.NODE_ENV !== 'production') {\n var ReactIs = require('react-is');\n\n // By explicitly using `prop-types` you are opting into new development behavior.\n // http://fb.me/prop-types-in-prod\n var throwOnDirectAccess = true;\n module.exports = require('./factoryWithTypeCheckers')(ReactIs.isElement, throwOnDirectAccess);\n} else {\n // By explicitly using `prop-types` you are opting into new production behavior.\n // http://fb.me/prop-types-in-prod\n module.exports = require('./factoryWithThrowingShims')();\n}\n","import PropTypes from 'prop-types';\nimport chainPropTypes from '../chainPropTypes';\nfunction isClassComponent(elementType) {\n // elementType.prototype?.isReactComponent\n const {\n prototype = {}\n } = elementType;\n return Boolean(prototype.isReactComponent);\n}\nfunction acceptingRef(props, propName, componentName, location, propFullName) {\n const element = props[propName];\n const safePropName = propFullName || propName;\n if (element == null ||\n // When server-side rendering React doesn't warn either.\n // This is not an accurate check for SSR.\n // This is only in place for Emotion compat.\n // TODO: Revisit once https://github.com/facebook/react/issues/20047 is resolved.\n typeof window === 'undefined') {\n return null;\n }\n let warningHint;\n const elementType = element.type;\n /**\n * Blacklisting instead of whitelisting\n *\n * Blacklisting will miss some components, such as React.Fragment. Those will at least\n * trigger a warning in React.\n * We can't whitelist because there is no safe way to detect React.forwardRef\n * or class components. \"Safe\" means there's no public API.\n *\n */\n if (typeof elementType === 'function' && !isClassComponent(elementType)) {\n warningHint = 'Did you accidentally use a plain function component for an element instead?';\n }\n if (warningHint !== undefined) {\n return new Error(`Invalid ${location} \\`${safePropName}\\` supplied to \\`${componentName}\\`. ` + `Expected an element that can hold a ref. ${warningHint} ` + 'For more information see https://mui.com/r/caveat-with-refs-guide');\n }\n return null;\n}\nconst elementAcceptingRef = chainPropTypes(PropTypes.element, acceptingRef);\nelementAcceptingRef.isRequired = chainPropTypes(PropTypes.element.isRequired, acceptingRef);\nexport default elementAcceptingRef;","import _extends from \"@babel/runtime/helpers/esm/extends\";\n// This module is based on https://github.com/airbnb/prop-types-exact repository.\n// However, in order to reduce the number of dependencies and to remove some extra safe checks\n// the module was forked.\n\nconst specialProperty = 'exact-prop: \\u200b';\nexport default function exactProp(propTypes) {\n if (process.env.NODE_ENV === 'production') {\n return propTypes;\n }\n return _extends({}, propTypes, {\n [specialProperty]: props => {\n const unsupportedProps = Object.keys(props).filter(prop => !propTypes.hasOwnProperty(prop));\n if (unsupportedProps.length > 0) {\n return new Error(`The following props are not supported: ${unsupportedProps.map(prop => `\\`${prop}\\``).join(', ')}. Please remove them.`);\n }\n return null;\n }\n });\n}","/**\n * WARNING: Don't import this directly.\n * Use `MuiError` from `@mui/internal-babel-macros/MuiError.macro` instead.\n * @param {number} code\n */\nexport default function formatMuiErrorMessage(code) {\n // Apply babel-plugin-transform-template-literals in loose mode\n // loose mode is safe if we're concatenating primitives\n // see https://babeljs.io/docs/en/babel-plugin-transform-template-literals#loose\n /* eslint-disable prefer-template */\n let url = 'https://mui.com/production-error/?code=' + code;\n for (let i = 1; i < arguments.length; i += 1) {\n // rest params over-transpile for this case\n // eslint-disable-next-line prefer-rest-params\n url += '&args[]=' + encodeURIComponent(arguments[i]);\n }\n return 'Minified MUI error #' + code + '; visit ' + url + ' for the full message.';\n /* eslint-enable prefer-template */\n}","/**\n * @license React\n * react-is.production.min.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n'use strict';var b=Symbol.for(\"react.element\"),c=Symbol.for(\"react.portal\"),d=Symbol.for(\"react.fragment\"),e=Symbol.for(\"react.strict_mode\"),f=Symbol.for(\"react.profiler\"),g=Symbol.for(\"react.provider\"),h=Symbol.for(\"react.context\"),k=Symbol.for(\"react.server_context\"),l=Symbol.for(\"react.forward_ref\"),m=Symbol.for(\"react.suspense\"),n=Symbol.for(\"react.suspense_list\"),p=Symbol.for(\"react.memo\"),q=Symbol.for(\"react.lazy\"),t=Symbol.for(\"react.offscreen\"),u;u=Symbol.for(\"react.module.reference\");\nfunction v(a){if(\"object\"===typeof a&&null!==a){var r=a.$$typeof;switch(r){case b:switch(a=a.type,a){case d:case f:case e:case m:case n:return a;default:switch(a=a&&a.$$typeof,a){case k:case h:case l:case q:case p:case g:return a;default:return r}}case c:return r}}}exports.ContextConsumer=h;exports.ContextProvider=g;exports.Element=b;exports.ForwardRef=l;exports.Fragment=d;exports.Lazy=q;exports.Memo=p;exports.Portal=c;exports.Profiler=f;exports.StrictMode=e;exports.Suspense=m;\nexports.SuspenseList=n;exports.isAsyncMode=function(){return!1};exports.isConcurrentMode=function(){return!1};exports.isContextConsumer=function(a){return v(a)===h};exports.isContextProvider=function(a){return v(a)===g};exports.isElement=function(a){return\"object\"===typeof a&&null!==a&&a.$$typeof===b};exports.isForwardRef=function(a){return v(a)===l};exports.isFragment=function(a){return v(a)===d};exports.isLazy=function(a){return v(a)===q};exports.isMemo=function(a){return v(a)===p};\nexports.isPortal=function(a){return v(a)===c};exports.isProfiler=function(a){return v(a)===f};exports.isStrictMode=function(a){return v(a)===e};exports.isSuspense=function(a){return v(a)===m};exports.isSuspenseList=function(a){return v(a)===n};\nexports.isValidElementType=function(a){return\"string\"===typeof a||\"function\"===typeof a||a===d||a===f||a===e||a===m||a===n||a===t||\"object\"===typeof a&&null!==a&&(a.$$typeof===q||a.$$typeof===p||a.$$typeof===g||a.$$typeof===h||a.$$typeof===l||a.$$typeof===u||void 0!==a.getModuleId)?!0:!1};exports.typeOf=v;\n","/**\n * @license React\n * react-is.development.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nif (process.env.NODE_ENV !== \"production\") {\n (function() {\n'use strict';\n\n// ATTENTION\n// When adding new symbols to this file,\n// Please consider also adding to 'react-devtools-shared/src/backend/ReactSymbols'\n// The Symbol used to tag the ReactElement-like types.\nvar REACT_ELEMENT_TYPE = Symbol.for('react.element');\nvar REACT_PORTAL_TYPE = Symbol.for('react.portal');\nvar REACT_FRAGMENT_TYPE = Symbol.for('react.fragment');\nvar REACT_STRICT_MODE_TYPE = Symbol.for('react.strict_mode');\nvar REACT_PROFILER_TYPE = Symbol.for('react.profiler');\nvar REACT_PROVIDER_TYPE = Symbol.for('react.provider');\nvar REACT_CONTEXT_TYPE = Symbol.for('react.context');\nvar REACT_SERVER_CONTEXT_TYPE = Symbol.for('react.server_context');\nvar REACT_FORWARD_REF_TYPE = Symbol.for('react.forward_ref');\nvar REACT_SUSPENSE_TYPE = Symbol.for('react.suspense');\nvar REACT_SUSPENSE_LIST_TYPE = Symbol.for('react.suspense_list');\nvar REACT_MEMO_TYPE = Symbol.for('react.memo');\nvar REACT_LAZY_TYPE = Symbol.for('react.lazy');\nvar REACT_OFFSCREEN_TYPE = Symbol.for('react.offscreen');\n\n// -----------------------------------------------------------------------------\n\nvar enableScopeAPI = false; // Experimental Create Event Handle API.\nvar enableCacheElement = false;\nvar enableTransitionTracing = false; // No known bugs, but needs performance testing\n\nvar enableLegacyHidden = false; // Enables unstable_avoidThisFallback feature in Fiber\n// stuff. Intended to enable React core members to more easily debug scheduling\n// issues in DEV builds.\n\nvar enableDebugTracing = false; // Track which Fiber(s) schedule render work.\n\nvar REACT_MODULE_REFERENCE;\n\n{\n REACT_MODULE_REFERENCE = Symbol.for('react.module.reference');\n}\n\nfunction isValidElementType(type) {\n if (typeof type === 'string' || typeof type === 'function') {\n return true;\n } // Note: typeof might be other than 'symbol' or 'number' (e.g. if it's a polyfill).\n\n\n if (type === REACT_FRAGMENT_TYPE || type === REACT_PROFILER_TYPE || enableDebugTracing || type === REACT_STRICT_MODE_TYPE || type === REACT_SUSPENSE_TYPE || type === REACT_SUSPENSE_LIST_TYPE || enableLegacyHidden || type === REACT_OFFSCREEN_TYPE || enableScopeAPI || enableCacheElement || enableTransitionTracing ) {\n return true;\n }\n\n if (typeof type === 'object' && type !== null) {\n if (type.$$typeof === REACT_LAZY_TYPE || type.$$typeof === REACT_MEMO_TYPE || type.$$typeof === REACT_PROVIDER_TYPE || type.$$typeof === REACT_CONTEXT_TYPE || type.$$typeof === REACT_FORWARD_REF_TYPE || // This needs to include all possible module reference object\n // types supported by any Flight configuration anywhere since\n // we don't know which Flight build this will end up being used\n // with.\n type.$$typeof === REACT_MODULE_REFERENCE || type.getModuleId !== undefined) {\n return true;\n }\n }\n\n return false;\n}\n\nfunction typeOf(object) {\n if (typeof object === 'object' && object !== null) {\n var $$typeof = object.$$typeof;\n\n switch ($$typeof) {\n case REACT_ELEMENT_TYPE:\n var type = object.type;\n\n switch (type) {\n case REACT_FRAGMENT_TYPE:\n case REACT_PROFILER_TYPE:\n case REACT_STRICT_MODE_TYPE:\n case REACT_SUSPENSE_TYPE:\n case REACT_SUSPENSE_LIST_TYPE:\n return type;\n\n default:\n var $$typeofType = type && type.$$typeof;\n\n switch ($$typeofType) {\n case REACT_SERVER_CONTEXT_TYPE:\n case REACT_CONTEXT_TYPE:\n case REACT_FORWARD_REF_TYPE:\n case REACT_LAZY_TYPE:\n case REACT_MEMO_TYPE:\n case REACT_PROVIDER_TYPE:\n return $$typeofType;\n\n default:\n return $$typeof;\n }\n\n }\n\n case REACT_PORTAL_TYPE:\n return $$typeof;\n }\n }\n\n return undefined;\n}\nvar ContextConsumer = REACT_CONTEXT_TYPE;\nvar ContextProvider = REACT_PROVIDER_TYPE;\nvar Element = REACT_ELEMENT_TYPE;\nvar ForwardRef = REACT_FORWARD_REF_TYPE;\nvar Fragment = REACT_FRAGMENT_TYPE;\nvar Lazy = REACT_LAZY_TYPE;\nvar Memo = REACT_MEMO_TYPE;\nvar Portal = REACT_PORTAL_TYPE;\nvar Profiler = REACT_PROFILER_TYPE;\nvar StrictMode = REACT_STRICT_MODE_TYPE;\nvar Suspense = REACT_SUSPENSE_TYPE;\nvar SuspenseList = REACT_SUSPENSE_LIST_TYPE;\nvar hasWarnedAboutDeprecatedIsAsyncMode = false;\nvar hasWarnedAboutDeprecatedIsConcurrentMode = false; // AsyncMode should be deprecated\n\nfunction isAsyncMode(object) {\n {\n if (!hasWarnedAboutDeprecatedIsAsyncMode) {\n hasWarnedAboutDeprecatedIsAsyncMode = true; // Using console['warn'] to evade Babel and ESLint\n\n console['warn']('The ReactIs.isAsyncMode() alias has been deprecated, ' + 'and will be removed in React 18+.');\n }\n }\n\n return false;\n}\nfunction isConcurrentMode(object) {\n {\n if (!hasWarnedAboutDeprecatedIsConcurrentMode) {\n hasWarnedAboutDeprecatedIsConcurrentMode = true; // Using console['warn'] to evade Babel and ESLint\n\n console['warn']('The ReactIs.isConcurrentMode() alias has been deprecated, ' + 'and will be removed in React 18+.');\n }\n }\n\n return false;\n}\nfunction isContextConsumer(object) {\n return typeOf(object) === REACT_CONTEXT_TYPE;\n}\nfunction isContextProvider(object) {\n return typeOf(object) === REACT_PROVIDER_TYPE;\n}\nfunction isElement(object) {\n return typeof object === 'object' && object !== null && object.$$typeof === REACT_ELEMENT_TYPE;\n}\nfunction isForwardRef(object) {\n return typeOf(object) === REACT_FORWARD_REF_TYPE;\n}\nfunction isFragment(object) {\n return typeOf(object) === REACT_FRAGMENT_TYPE;\n}\nfunction isLazy(object) {\n return typeOf(object) === REACT_LAZY_TYPE;\n}\nfunction isMemo(object) {\n return typeOf(object) === REACT_MEMO_TYPE;\n}\nfunction isPortal(object) {\n return typeOf(object) === REACT_PORTAL_TYPE;\n}\nfunction isProfiler(object) {\n return typeOf(object) === REACT_PROFILER_TYPE;\n}\nfunction isStrictMode(object) {\n return typeOf(object) === REACT_STRICT_MODE_TYPE;\n}\nfunction isSuspense(object) {\n return typeOf(object) === REACT_SUSPENSE_TYPE;\n}\nfunction isSuspenseList(object) {\n return typeOf(object) === REACT_SUSPENSE_LIST_TYPE;\n}\n\nexports.ContextConsumer = ContextConsumer;\nexports.ContextProvider = ContextProvider;\nexports.Element = Element;\nexports.ForwardRef = ForwardRef;\nexports.Fragment = Fragment;\nexports.Lazy = Lazy;\nexports.Memo = Memo;\nexports.Portal = Portal;\nexports.Profiler = Profiler;\nexports.StrictMode = StrictMode;\nexports.Suspense = Suspense;\nexports.SuspenseList = SuspenseList;\nexports.isAsyncMode = isAsyncMode;\nexports.isConcurrentMode = isConcurrentMode;\nexports.isContextConsumer = isContextConsumer;\nexports.isContextProvider = isContextProvider;\nexports.isElement = isElement;\nexports.isForwardRef = isForwardRef;\nexports.isFragment = isFragment;\nexports.isLazy = isLazy;\nexports.isMemo = isMemo;\nexports.isPortal = isPortal;\nexports.isProfiler = isProfiler;\nexports.isStrictMode = isStrictMode;\nexports.isSuspense = isSuspense;\nexports.isSuspenseList = isSuspenseList;\nexports.isValidElementType = isValidElementType;\nexports.typeOf = typeOf;\n })();\n}\n","'use strict';\n\nif (process.env.NODE_ENV === 'production') {\n module.exports = require('./cjs/react-is.production.min.js');\n} else {\n module.exports = require('./cjs/react-is.development.js');\n}\n","import { ForwardRef, Memo } from 'react-is';\n\n// Simplified polyfill for IE11 support\n// https://github.com/JamesMGreene/Function.name/blob/58b314d4a983110c3682f1228f845d39ccca1817/Function.name.js#L3\nconst fnNameMatchRegex = /^\\s*function(?:\\s|\\s*\\/\\*.*\\*\\/\\s*)+([^(\\s/]*)\\s*/;\nexport function getFunctionName(fn) {\n const match = `${fn}`.match(fnNameMatchRegex);\n const name = match && match[1];\n return name || '';\n}\nfunction getFunctionComponentName(Component, fallback = '') {\n return Component.displayName || Component.name || getFunctionName(Component) || fallback;\n}\nfunction getWrappedName(outerType, innerType, wrapperName) {\n const functionName = getFunctionComponentName(innerType);\n return outerType.displayName || (functionName !== '' ? `${wrapperName}(${functionName})` : wrapperName);\n}\n\n/**\n * cherry-pick from\n * https://github.com/facebook/react/blob/769b1f270e1251d9dbdce0fcbd9e92e502d059b8/packages/shared/getComponentName.js\n * originally forked from recompose/getDisplayName with added IE11 support\n */\nexport default function getDisplayName(Component) {\n if (Component == null) {\n return undefined;\n }\n if (typeof Component === 'string') {\n return Component;\n }\n if (typeof Component === 'function') {\n return getFunctionComponentName(Component, 'Component');\n }\n\n // TypeScript can't have components as objects but they exist in the form of `memo` or `Suspense`\n if (typeof Component === 'object') {\n switch (Component.$$typeof) {\n case ForwardRef:\n return getWrappedName(Component, Component.render, 'ForwardRef');\n case Memo:\n return getWrappedName(Component, Component.type, 'memo');\n default:\n return undefined;\n }\n }\n return undefined;\n}","export default function HTMLElementType(props, propName, componentName, location, propFullName) {\n if (process.env.NODE_ENV === 'production') {\n return null;\n }\n const propValue = props[propName];\n const safePropName = propFullName || propName;\n if (propValue == null) {\n return null;\n }\n if (propValue && propValue.nodeType !== 1) {\n return new Error(`Invalid ${location} \\`${safePropName}\\` supplied to \\`${componentName}\\`. ` + `Expected an HTMLElement.`);\n }\n return null;\n}","import PropTypes from 'prop-types';\nconst refType = PropTypes.oneOfType([PropTypes.func, PropTypes.object]);\nexport default refType;","import _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\n// It should to be noted that this function isn't equivalent to `text-transform: capitalize`.\n//\n// A strict capitalization should uppercase the first letter of each word in the sentence.\n// We only handle the first word.\nexport default function capitalize(string) {\n if (typeof string !== 'string') {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: \\`capitalize(string)\\` expects a string argument.` : _formatMuiErrorMessage(7));\n }\n return string.charAt(0).toUpperCase() + string.slice(1);\n}","/**\n * Safe chained function.\n *\n * Will only create a new function if needed,\n * otherwise will pass back existing functions or null.\n */\nexport default function createChainedFunction(...funcs) {\n return funcs.reduce((acc, func) => {\n if (func == null) {\n return acc;\n }\n return function chainedFunction(...args) {\n acc.apply(this, args);\n func.apply(this, args);\n };\n }, () => {});\n}","// Corresponds to 10 frames at 60 Hz.\n// A few bytes payload overhead when lodash/debounce is ~3 kB and debounce ~300 B.\nexport default function debounce(func, wait = 166) {\n let timeout;\n function debounced(...args) {\n const later = () => {\n // @ts-ignore\n func.apply(this, args);\n };\n clearTimeout(timeout);\n timeout = setTimeout(later, wait);\n }\n debounced.clear = () => {\n clearTimeout(timeout);\n };\n return debounced;\n}","export default function deprecatedPropType(validator, reason) {\n if (process.env.NODE_ENV === 'production') {\n return () => null;\n }\n return (props, propName, componentName, location, propFullName) => {\n const componentNameSafe = componentName || '<>';\n const propFullNameSafe = propFullName || propName;\n if (typeof props[propName] !== 'undefined') {\n return new Error(`The ${location} \\`${propFullNameSafe}\\` of ` + `\\`${componentNameSafe}\\` is deprecated. ${reason}`);\n }\n return null;\n };\n}","import * as React from 'react';\nexport default function isMuiElement(element, muiNames) {\n var _muiName, _element$type;\n return /*#__PURE__*/React.isValidElement(element) && muiNames.indexOf( // For server components `muiName` is avaialble in element.type._payload.value.muiName\n // relevant info - https://github.com/facebook/react/blob/2807d781a08db8e9873687fccc25c0f12b4fb3d4/packages/react/src/ReactLazy.js#L45\n // eslint-disable-next-line no-underscore-dangle\n (_muiName = element.type.muiName) != null ? _muiName : (_element$type = element.type) == null || (_element$type = _element$type._payload) == null || (_element$type = _element$type.value) == null ? void 0 : _element$type.muiName) !== -1;\n}","export default function ownerDocument(node) {\n return node && node.ownerDocument || document;\n}","import ownerDocument from '../ownerDocument';\nexport default function ownerWindow(node) {\n const doc = ownerDocument(node);\n return doc.defaultView || window;\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nexport default function requirePropFactory(componentNameInError, Component) {\n if (process.env.NODE_ENV === 'production') {\n return () => null;\n }\n\n // eslint-disable-next-line react/forbid-foreign-prop-types\n const prevPropTypes = Component ? _extends({}, Component.propTypes) : null;\n const requireProp = requiredProp => (props, propName, componentName, location, propFullName, ...args) => {\n const propFullNameSafe = propFullName || propName;\n const defaultTypeChecker = prevPropTypes == null ? void 0 : prevPropTypes[propFullNameSafe];\n if (defaultTypeChecker) {\n const typeCheckerResult = defaultTypeChecker(props, propName, componentName, location, propFullName, ...args);\n if (typeCheckerResult) {\n return typeCheckerResult;\n }\n }\n if (typeof props[propName] !== 'undefined' && !props[requiredProp]) {\n return new Error(`The prop \\`${propFullNameSafe}\\` of ` + `\\`${componentNameInError}\\` can only be used together with the \\`${requiredProp}\\` prop.`);\n }\n return null;\n };\n return requireProp;\n}","/**\n * TODO v5: consider making it private\n *\n * passes {value} to {ref}\n *\n * WARNING: Be sure to only call this inside a callback that is passed as a ref.\n * Otherwise, make sure to cleanup the previous {ref} if it changes. See\n * https://github.com/mui/material-ui/issues/13539\n *\n * Useful if you want to expose the ref of an inner component to the public API\n * while still using it inside the component.\n * @param ref A ref callback or ref object. If anything falsy, this is a no-op.\n */\nexport default function setRef(ref, value) {\n if (typeof ref === 'function') {\n ref(value);\n } else if (ref) {\n ref.current = value;\n }\n}","'use client';\n\nimport * as React from 'react';\n\n/**\n * A version of `React.useLayoutEffect` that does not show a warning when server-side rendering.\n * This is useful for effects that are only needed for client-side rendering but not for SSR.\n *\n * Before you use this hook, make sure to read https://gist.github.com/gaearon/e7d97cdf38a2907924ea12e4ebdf3c85\n * and confirm it doesn't apply to your use-case.\n */\nconst useEnhancedEffect = typeof window !== 'undefined' ? React.useLayoutEffect : React.useEffect;\nexport default useEnhancedEffect;","'use client';\n\nimport * as React from 'react';\nlet globalId = 0;\nfunction useGlobalId(idOverride) {\n const [defaultId, setDefaultId] = React.useState(idOverride);\n const id = idOverride || defaultId;\n React.useEffect(() => {\n if (defaultId == null) {\n // Fallback to this default id when possible.\n // Use the incrementing value for client-side rendering only.\n // We can't use it server-side.\n // If you want to use random values please consider the Birthday Problem: https://en.wikipedia.org/wiki/Birthday_problem\n globalId += 1;\n setDefaultId(`mui-${globalId}`);\n }\n }, [defaultId]);\n return id;\n}\n\n// downstream bundlers may remove unnecessary concatenation, but won't remove toString call -- Workaround for https://github.com/webpack/webpack/issues/14814\nconst maybeReactUseId = React['useId'.toString()];\n/**\n *\n * @example
    \n * @param idOverride\n * @returns {string}\n */\nexport default function useId(idOverride) {\n if (maybeReactUseId !== undefined) {\n const reactId = maybeReactUseId();\n return idOverride != null ? idOverride : reactId;\n }\n // eslint-disable-next-line react-hooks/rules-of-hooks -- `React.useId` is invariant at runtime.\n return useGlobalId(idOverride);\n}","export default function unsupportedProp(props, propName, componentName, location, propFullName) {\n if (process.env.NODE_ENV === 'production') {\n return null;\n }\n const propFullNameSafe = propFullName || propName;\n if (typeof props[propName] !== 'undefined') {\n return new Error(`The prop \\`${propFullNameSafe}\\` is not supported. Please remove it.`);\n }\n return null;\n}","'use client';\n\n/* eslint-disable react-hooks/rules-of-hooks, react-hooks/exhaustive-deps */\nimport * as React from 'react';\nexport default function useControlled({\n controlled,\n default: defaultProp,\n name,\n state = 'value'\n}) {\n // isControlled is ignored in the hook dependency lists as it should never change.\n const {\n current: isControlled\n } = React.useRef(controlled !== undefined);\n const [valueState, setValue] = React.useState(defaultProp);\n const value = isControlled ? controlled : valueState;\n if (process.env.NODE_ENV !== 'production') {\n React.useEffect(() => {\n if (isControlled !== (controlled !== undefined)) {\n console.error([`MUI: A component is changing the ${isControlled ? '' : 'un'}controlled ${state} state of ${name} to be ${isControlled ? 'un' : ''}controlled.`, 'Elements should not switch from uncontrolled to controlled (or vice versa).', `Decide between using a controlled or uncontrolled ${name} ` + 'element for the lifetime of the component.', \"The nature of the state is determined during the first render. It's considered controlled if the value is not `undefined`.\", 'More info: https://fb.me/react-controlled-components'].join('\\n'));\n }\n }, [state, name, controlled]);\n const {\n current: defaultValue\n } = React.useRef(defaultProp);\n React.useEffect(() => {\n if (!isControlled && defaultValue !== defaultProp) {\n console.error([`MUI: A component is changing the default ${state} state of an uncontrolled ${name} after being initialized. ` + `To suppress this warning opt to use a controlled ${name}.`].join('\\n'));\n }\n }, [JSON.stringify(defaultProp)]);\n }\n const setValueIfUncontrolled = React.useCallback(newValue => {\n if (!isControlled) {\n setValue(newValue);\n }\n }, []);\n return [value, setValueIfUncontrolled];\n}","'use client';\n\nimport * as React from 'react';\nimport useEnhancedEffect from '../useEnhancedEffect';\n\n/**\n * Inspired by https://github.com/facebook/react/issues/14099#issuecomment-440013892\n * See RFC in https://github.com/reactjs/rfcs/pull/220\n */\n\nfunction useEventCallback(fn) {\n const ref = React.useRef(fn);\n useEnhancedEffect(() => {\n ref.current = fn;\n });\n return React.useRef((...args) =>\n // @ts-expect-error hide `this`\n (0, ref.current)(...args)).current;\n}\nexport default useEventCallback;","'use client';\n\nimport * as React from 'react';\nimport setRef from '../setRef';\nexport default function useForkRef(...refs) {\n /**\n * This will create a new function if the refs passed to this hook change and are all defined.\n * This means react will call the old forkRef with `null` and the new forkRef\n * with the ref. Cleanup naturally emerges from this behavior.\n */\n return React.useMemo(() => {\n if (refs.every(ref => ref == null)) {\n return null;\n }\n return instance => {\n refs.forEach(ref => {\n setRef(ref, instance);\n });\n };\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, refs);\n}","'use client';\n\nimport * as React from 'react';\nconst UNINITIALIZED = {};\n\n/**\n * A React.useRef() that is initialized lazily with a function. Note that it accepts an optional\n * initialization argument, so the initialization function doesn't need to be an inline closure.\n *\n * @usage\n * const ref = useLazyRef(sortColumns, columns)\n */\nexport default function useLazyRef(init, initArg) {\n const ref = React.useRef(UNINITIALIZED);\n if (ref.current === UNINITIALIZED) {\n ref.current = init(initArg);\n }\n return ref;\n}","'use client';\n\nimport * as React from 'react';\nconst EMPTY = [];\n\n/**\n * A React.useEffect equivalent that runs once, when the component is mounted.\n */\nexport default function useOnMount(fn) {\n /* eslint-disable react-hooks/exhaustive-deps */\n React.useEffect(fn, EMPTY);\n /* eslint-enable react-hooks/exhaustive-deps */\n}","'use client';\n\nimport useLazyRef from '../useLazyRef/useLazyRef';\nimport useOnMount from '../useOnMount/useOnMount';\nexport class Timeout {\n constructor() {\n this.currentId = null;\n this.clear = () => {\n if (this.currentId !== null) {\n clearTimeout(this.currentId);\n this.currentId = null;\n }\n };\n this.disposeEffect = () => {\n return this.clear;\n };\n }\n static create() {\n return new Timeout();\n }\n /**\n * Executes `fn` after `delay`, clearing any previously scheduled call.\n */\n start(delay, fn) {\n this.clear();\n this.currentId = setTimeout(() => {\n this.currentId = null;\n fn();\n }, delay);\n }\n}\nexport default function useTimeout() {\n const timeout = useLazyRef(Timeout.create).current;\n useOnMount(timeout.disposeEffect);\n return timeout;\n}","'use client';\n\n// based on https://github.com/WICG/focus-visible/blob/v4.1.5/src/focus-visible.js\nimport * as React from 'react';\nimport { Timeout } from '../useTimeout/useTimeout';\nlet hadKeyboardEvent = true;\nlet hadFocusVisibleRecently = false;\nconst hadFocusVisibleRecentlyTimeout = new Timeout();\nconst inputTypesWhitelist = {\n text: true,\n search: true,\n url: true,\n tel: true,\n email: true,\n password: true,\n number: true,\n date: true,\n month: true,\n week: true,\n time: true,\n datetime: true,\n 'datetime-local': true\n};\n\n/**\n * Computes whether the given element should automatically trigger the\n * `focus-visible` class being added, i.e. whether it should always match\n * `:focus-visible` when focused.\n * @param {Element} node\n * @returns {boolean}\n */\nfunction focusTriggersKeyboardModality(node) {\n const {\n type,\n tagName\n } = node;\n if (tagName === 'INPUT' && inputTypesWhitelist[type] && !node.readOnly) {\n return true;\n }\n if (tagName === 'TEXTAREA' && !node.readOnly) {\n return true;\n }\n if (node.isContentEditable) {\n return true;\n }\n return false;\n}\n\n/**\n * Keep track of our keyboard modality state with `hadKeyboardEvent`.\n * If the most recent user interaction was via the keyboard;\n * and the key press did not include a meta, alt/option, or control key;\n * then the modality is keyboard. Otherwise, the modality is not keyboard.\n * @param {KeyboardEvent} event\n */\nfunction handleKeyDown(event) {\n if (event.metaKey || event.altKey || event.ctrlKey) {\n return;\n }\n hadKeyboardEvent = true;\n}\n\n/**\n * If at any point a user clicks with a pointing device, ensure that we change\n * the modality away from keyboard.\n * This avoids the situation where a user presses a key on an already focused\n * element, and then clicks on a different element, focusing it with a\n * pointing device, while we still think we're in keyboard modality.\n */\nfunction handlePointerDown() {\n hadKeyboardEvent = false;\n}\nfunction handleVisibilityChange() {\n if (this.visibilityState === 'hidden') {\n // If the tab becomes active again, the browser will handle calling focus\n // on the element (Safari actually calls it twice).\n // If this tab change caused a blur on an element with focus-visible,\n // re-apply the class when the user switches back to the tab.\n if (hadFocusVisibleRecently) {\n hadKeyboardEvent = true;\n }\n }\n}\nfunction prepare(doc) {\n doc.addEventListener('keydown', handleKeyDown, true);\n doc.addEventListener('mousedown', handlePointerDown, true);\n doc.addEventListener('pointerdown', handlePointerDown, true);\n doc.addEventListener('touchstart', handlePointerDown, true);\n doc.addEventListener('visibilitychange', handleVisibilityChange, true);\n}\nexport function teardown(doc) {\n doc.removeEventListener('keydown', handleKeyDown, true);\n doc.removeEventListener('mousedown', handlePointerDown, true);\n doc.removeEventListener('pointerdown', handlePointerDown, true);\n doc.removeEventListener('touchstart', handlePointerDown, true);\n doc.removeEventListener('visibilitychange', handleVisibilityChange, true);\n}\nfunction isFocusVisible(event) {\n const {\n target\n } = event;\n try {\n return target.matches(':focus-visible');\n } catch (error) {\n // Browsers not implementing :focus-visible will throw a SyntaxError.\n // We use our own heuristic for those browsers.\n // Rethrow might be better if it's not the expected error but do we really\n // want to crash if focus-visible malfunctioned?\n }\n\n // No need for validFocusTarget check. The user does that by attaching it to\n // focusable events only.\n return hadKeyboardEvent || focusTriggersKeyboardModality(target);\n}\nexport default function useIsFocusVisible() {\n const ref = React.useCallback(node => {\n if (node != null) {\n prepare(node.ownerDocument);\n }\n }, []);\n const isFocusVisibleRef = React.useRef(false);\n\n /**\n * Should be called if a blur event is fired\n */\n function handleBlurVisible() {\n // checking against potential state variable does not suffice if we focus and blur synchronously.\n // React wouldn't have time to trigger a re-render so `focusVisible` would be stale.\n // Ideally we would adjust `isFocusVisible(event)` to look at `relatedTarget` for blur events.\n // This doesn't work in IE11 due to https://github.com/facebook/react/issues/3751\n // TODO: check again if React releases their internal changes to focus event handling (https://github.com/facebook/react/pull/19186).\n if (isFocusVisibleRef.current) {\n // To detect a tab/window switch, we look for a blur event followed\n // rapidly by a visibility change.\n // If we don't see a visibility change within 100ms, it's probably a\n // regular focus change.\n hadFocusVisibleRecently = true;\n hadFocusVisibleRecentlyTimeout.start(100, () => {\n hadFocusVisibleRecently = false;\n });\n isFocusVisibleRef.current = false;\n return true;\n }\n return false;\n }\n\n /**\n * Should be called if a blur event is fired\n */\n function handleFocusVisible(event) {\n if (isFocusVisible(event)) {\n isFocusVisibleRef.current = true;\n return true;\n }\n return false;\n }\n return {\n isFocusVisibleRef,\n onFocus: handleFocusVisible,\n onBlur: handleBlurVisible,\n ref\n };\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\n/**\n * Add keys, values of `defaultProps` that does not exist in `props`\n * @param {object} defaultProps\n * @param {object} props\n * @returns {object} resolved props\n */\nexport default function resolveProps(defaultProps, props) {\n const output = _extends({}, props);\n Object.keys(defaultProps).forEach(propName => {\n if (propName.toString().match(/^(components|slots)$/)) {\n output[propName] = _extends({}, defaultProps[propName], output[propName]);\n } else if (propName.toString().match(/^(componentsProps|slotProps)$/)) {\n const defaultSlotProps = defaultProps[propName] || {};\n const slotProps = props[propName];\n output[propName] = {};\n if (!slotProps || !Object.keys(slotProps)) {\n // Reduce the iteration if the slot props is empty\n output[propName] = defaultSlotProps;\n } else if (!defaultSlotProps || !Object.keys(defaultSlotProps)) {\n // Reduce the iteration if the default slot props is empty\n output[propName] = slotProps;\n } else {\n output[propName] = _extends({}, slotProps);\n Object.keys(defaultSlotProps).forEach(slotPropName => {\n output[propName][slotPropName] = resolveProps(defaultSlotProps[slotPropName], slotProps[slotPropName]);\n });\n }\n } else if (output[propName] === undefined) {\n output[propName] = defaultProps[propName];\n }\n });\n return output;\n}","export default function composeClasses(slots, getUtilityClass, classes = undefined) {\n const output = {};\n Object.keys(slots).forEach(\n // `Object.keys(slots)` can't be wider than `T` because we infer `T` from `slots`.\n // @ts-expect-error https://github.com/microsoft/TypeScript/pull/12253#issuecomment-263132208\n slot => {\n output[slot] = slots[slot].reduce((acc, key) => {\n if (key) {\n const utilityClass = getUtilityClass(key);\n if (utilityClass !== '') {\n acc.push(utilityClass);\n }\n if (classes && classes[key]) {\n acc.push(classes[key]);\n }\n }\n return acc;\n }, []).join(' ');\n });\n return output;\n}","const defaultGenerator = componentName => componentName;\nconst createClassNameGenerator = () => {\n let generate = defaultGenerator;\n return {\n configure(generator) {\n generate = generator;\n },\n generate(componentName) {\n return generate(componentName);\n },\n reset() {\n generate = defaultGenerator;\n }\n };\n};\nconst ClassNameGenerator = createClassNameGenerator();\nexport default ClassNameGenerator;","import ClassNameGenerator from '../ClassNameGenerator';\nexport const globalStateClasses = {\n active: 'active',\n checked: 'checked',\n completed: 'completed',\n disabled: 'disabled',\n error: 'error',\n expanded: 'expanded',\n focused: 'focused',\n focusVisible: 'focusVisible',\n open: 'open',\n readOnly: 'readOnly',\n required: 'required',\n selected: 'selected'\n};\nexport default function generateUtilityClass(componentName, slot, globalStatePrefix = 'Mui') {\n const globalStateClass = globalStateClasses[slot];\n return globalStateClass ? `${globalStatePrefix}-${globalStateClass}` : `${ClassNameGenerator.generate(componentName)}-${slot}`;\n}\nexport function isGlobalState(slot) {\n return globalStateClasses[slot] !== undefined;\n}","import generateUtilityClass from '../generateUtilityClass';\nexport default function generateUtilityClasses(componentName, slots, globalStatePrefix = 'Mui') {\n const result = {};\n slots.forEach(slot => {\n result[slot] = generateUtilityClass(componentName, slot, globalStatePrefix);\n });\n return result;\n}","function clamp(val, min = Number.MIN_SAFE_INTEGER, max = Number.MAX_SAFE_INTEGER) {\n return Math.max(min, Math.min(val, max));\n}\nexport default clamp;","export default function _objectWithoutPropertiesLoose(source, excluded) {\n if (source == null) return {};\n var target = {};\n var sourceKeys = Object.keys(source);\n var key, i;\n for (i = 0; i < sourceKeys.length; i++) {\n key = sourceKeys[i];\n if (excluded.indexOf(key) >= 0) continue;\n target[key] = source[key];\n }\n return target;\n}","import _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nconst _excluded = [\"values\", \"unit\", \"step\"];\n// Sorted ASC by size. That's important.\n// It can't be configured as it's used statically for propTypes.\nexport const breakpointKeys = ['xs', 'sm', 'md', 'lg', 'xl'];\nconst sortBreakpointsValues = values => {\n const breakpointsAsArray = Object.keys(values).map(key => ({\n key,\n val: values[key]\n })) || [];\n // Sort in ascending order\n breakpointsAsArray.sort((breakpoint1, breakpoint2) => breakpoint1.val - breakpoint2.val);\n return breakpointsAsArray.reduce((acc, obj) => {\n return _extends({}, acc, {\n [obj.key]: obj.val\n });\n }, {});\n};\n\n// Keep in mind that @media is inclusive by the CSS specification.\nexport default function createBreakpoints(breakpoints) {\n const {\n // The breakpoint **start** at this value.\n // For instance with the first breakpoint xs: [xs, sm).\n values = {\n xs: 0,\n // phone\n sm: 600,\n // tablet\n md: 900,\n // small laptop\n lg: 1200,\n // desktop\n xl: 1536 // large screen\n },\n unit = 'px',\n step = 5\n } = breakpoints,\n other = _objectWithoutPropertiesLoose(breakpoints, _excluded);\n const sortedValues = sortBreakpointsValues(values);\n const keys = Object.keys(sortedValues);\n function up(key) {\n const value = typeof values[key] === 'number' ? values[key] : key;\n return `@media (min-width:${value}${unit})`;\n }\n function down(key) {\n const value = typeof values[key] === 'number' ? values[key] : key;\n return `@media (max-width:${value - step / 100}${unit})`;\n }\n function between(start, end) {\n const endIndex = keys.indexOf(end);\n return `@media (min-width:${typeof values[start] === 'number' ? values[start] : start}${unit}) and ` + `(max-width:${(endIndex !== -1 && typeof values[keys[endIndex]] === 'number' ? values[keys[endIndex]] : end) - step / 100}${unit})`;\n }\n function only(key) {\n if (keys.indexOf(key) + 1 < keys.length) {\n return between(key, keys[keys.indexOf(key) + 1]);\n }\n return up(key);\n }\n function not(key) {\n // handle first and last key separately, for better readability\n const keyIndex = keys.indexOf(key);\n if (keyIndex === 0) {\n return up(keys[1]);\n }\n if (keyIndex === keys.length - 1) {\n return down(keys[keyIndex]);\n }\n return between(key, keys[keys.indexOf(key) + 1]).replace('@media', '@media not all and');\n }\n return _extends({\n keys,\n values: sortedValues,\n up,\n down,\n between,\n only,\n not,\n unit\n }, other);\n}","const shape = {\n borderRadius: 4\n};\nexport default shape;","import PropTypes from 'prop-types';\nconst responsivePropType = process.env.NODE_ENV !== 'production' ? PropTypes.oneOfType([PropTypes.number, PropTypes.string, PropTypes.object, PropTypes.array]) : {};\nexport default responsivePropType;","import deepmerge from '@mui/utils/deepmerge';\nfunction merge(acc, item) {\n if (!item) {\n return acc;\n }\n return deepmerge(acc, item, {\n clone: false // No need to clone deep, it's way faster.\n });\n}\nexport default merge;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport PropTypes from 'prop-types';\nimport deepmerge from '@mui/utils/deepmerge';\nimport merge from './merge';\n\n// The breakpoint **start** at this value.\n// For instance with the first breakpoint xs: [xs, sm[.\nexport const values = {\n xs: 0,\n // phone\n sm: 600,\n // tablet\n md: 900,\n // small laptop\n lg: 1200,\n // desktop\n xl: 1536 // large screen\n};\nconst defaultBreakpoints = {\n // Sorted ASC by size. That's important.\n // It can't be configured as it's used statically for propTypes.\n keys: ['xs', 'sm', 'md', 'lg', 'xl'],\n up: key => `@media (min-width:${values[key]}px)`\n};\nexport function handleBreakpoints(props, propValue, styleFromPropValue) {\n const theme = props.theme || {};\n if (Array.isArray(propValue)) {\n const themeBreakpoints = theme.breakpoints || defaultBreakpoints;\n return propValue.reduce((acc, item, index) => {\n acc[themeBreakpoints.up(themeBreakpoints.keys[index])] = styleFromPropValue(propValue[index]);\n return acc;\n }, {});\n }\n if (typeof propValue === 'object') {\n const themeBreakpoints = theme.breakpoints || defaultBreakpoints;\n return Object.keys(propValue).reduce((acc, breakpoint) => {\n // key is breakpoint\n if (Object.keys(themeBreakpoints.values || values).indexOf(breakpoint) !== -1) {\n const mediaKey = themeBreakpoints.up(breakpoint);\n acc[mediaKey] = styleFromPropValue(propValue[breakpoint], breakpoint);\n } else {\n const cssKey = breakpoint;\n acc[cssKey] = propValue[cssKey];\n }\n return acc;\n }, {});\n }\n const output = styleFromPropValue(propValue);\n return output;\n}\nfunction breakpoints(styleFunction) {\n // false positive\n // eslint-disable-next-line react/function-component-definition\n const newStyleFunction = props => {\n const theme = props.theme || {};\n const base = styleFunction(props);\n const themeBreakpoints = theme.breakpoints || defaultBreakpoints;\n const extended = themeBreakpoints.keys.reduce((acc, key) => {\n if (props[key]) {\n acc = acc || {};\n acc[themeBreakpoints.up(key)] = styleFunction(_extends({\n theme\n }, props[key]));\n }\n return acc;\n }, null);\n return merge(base, extended);\n };\n newStyleFunction.propTypes = process.env.NODE_ENV !== 'production' ? _extends({}, styleFunction.propTypes, {\n xs: PropTypes.object,\n sm: PropTypes.object,\n md: PropTypes.object,\n lg: PropTypes.object,\n xl: PropTypes.object\n }) : {};\n newStyleFunction.filterProps = ['xs', 'sm', 'md', 'lg', 'xl', ...styleFunction.filterProps];\n return newStyleFunction;\n}\nexport function createEmptyBreakpointObject(breakpointsInput = {}) {\n var _breakpointsInput$key;\n const breakpointsInOrder = (_breakpointsInput$key = breakpointsInput.keys) == null ? void 0 : _breakpointsInput$key.reduce((acc, key) => {\n const breakpointStyleKey = breakpointsInput.up(key);\n acc[breakpointStyleKey] = {};\n return acc;\n }, {});\n return breakpointsInOrder || {};\n}\nexport function removeUnusedBreakpoints(breakpointKeys, style) {\n return breakpointKeys.reduce((acc, key) => {\n const breakpointOutput = acc[key];\n const isBreakpointUnused = !breakpointOutput || Object.keys(breakpointOutput).length === 0;\n if (isBreakpointUnused) {\n delete acc[key];\n }\n return acc;\n }, style);\n}\nexport function mergeBreakpointsInOrder(breakpointsInput, ...styles) {\n const emptyBreakpoints = createEmptyBreakpointObject(breakpointsInput);\n const mergedOutput = [emptyBreakpoints, ...styles].reduce((prev, next) => deepmerge(prev, next), {});\n return removeUnusedBreakpoints(Object.keys(emptyBreakpoints), mergedOutput);\n}\n\n// compute base for responsive values; e.g.,\n// [1,2,3] => {xs: true, sm: true, md: true}\n// {xs: 1, sm: 2, md: 3} => {xs: true, sm: true, md: true}\nexport function computeBreakpointsBase(breakpointValues, themeBreakpoints) {\n // fixed value\n if (typeof breakpointValues !== 'object') {\n return {};\n }\n const base = {};\n const breakpointsKeys = Object.keys(themeBreakpoints);\n if (Array.isArray(breakpointValues)) {\n breakpointsKeys.forEach((breakpoint, i) => {\n if (i < breakpointValues.length) {\n base[breakpoint] = true;\n }\n });\n } else {\n breakpointsKeys.forEach(breakpoint => {\n if (breakpointValues[breakpoint] != null) {\n base[breakpoint] = true;\n }\n });\n }\n return base;\n}\nexport function resolveBreakpointValues({\n values: breakpointValues,\n breakpoints: themeBreakpoints,\n base: customBase\n}) {\n const base = customBase || computeBreakpointsBase(breakpointValues, themeBreakpoints);\n const keys = Object.keys(base);\n if (keys.length === 0) {\n return breakpointValues;\n }\n let previous;\n return keys.reduce((acc, breakpoint, i) => {\n if (Array.isArray(breakpointValues)) {\n acc[breakpoint] = breakpointValues[i] != null ? breakpointValues[i] : breakpointValues[previous];\n previous = i;\n } else if (typeof breakpointValues === 'object') {\n acc[breakpoint] = breakpointValues[breakpoint] != null ? breakpointValues[breakpoint] : breakpointValues[previous];\n previous = breakpoint;\n } else {\n acc[breakpoint] = breakpointValues;\n }\n return acc;\n }, {});\n}\nexport default breakpoints;","import capitalize from '@mui/utils/capitalize';\nimport responsivePropType from './responsivePropType';\nimport { handleBreakpoints } from './breakpoints';\nexport function getPath(obj, path, checkVars = true) {\n if (!path || typeof path !== 'string') {\n return null;\n }\n\n // Check if CSS variables are used\n if (obj && obj.vars && checkVars) {\n const val = `vars.${path}`.split('.').reduce((acc, item) => acc && acc[item] ? acc[item] : null, obj);\n if (val != null) {\n return val;\n }\n }\n return path.split('.').reduce((acc, item) => {\n if (acc && acc[item] != null) {\n return acc[item];\n }\n return null;\n }, obj);\n}\nexport function getStyleValue(themeMapping, transform, propValueFinal, userValue = propValueFinal) {\n let value;\n if (typeof themeMapping === 'function') {\n value = themeMapping(propValueFinal);\n } else if (Array.isArray(themeMapping)) {\n value = themeMapping[propValueFinal] || userValue;\n } else {\n value = getPath(themeMapping, propValueFinal) || userValue;\n }\n if (transform) {\n value = transform(value, userValue, themeMapping);\n }\n return value;\n}\nfunction style(options) {\n const {\n prop,\n cssProperty = options.prop,\n themeKey,\n transform\n } = options;\n\n // false positive\n // eslint-disable-next-line react/function-component-definition\n const fn = props => {\n if (props[prop] == null) {\n return null;\n }\n const propValue = props[prop];\n const theme = props.theme;\n const themeMapping = getPath(theme, themeKey) || {};\n const styleFromPropValue = propValueFinal => {\n let value = getStyleValue(themeMapping, transform, propValueFinal);\n if (propValueFinal === value && typeof propValueFinal === 'string') {\n // Haven't found value\n value = getStyleValue(themeMapping, transform, `${prop}${propValueFinal === 'default' ? '' : capitalize(propValueFinal)}`, propValueFinal);\n }\n if (cssProperty === false) {\n return value;\n }\n return {\n [cssProperty]: value\n };\n };\n return handleBreakpoints(props, propValue, styleFromPropValue);\n };\n fn.propTypes = process.env.NODE_ENV !== 'production' ? {\n [prop]: responsivePropType\n } : {};\n fn.filterProps = [prop];\n return fn;\n}\nexport default style;","export default function memoize(fn) {\n const cache = {};\n return arg => {\n if (cache[arg] === undefined) {\n cache[arg] = fn(arg);\n }\n return cache[arg];\n };\n}","import responsivePropType from './responsivePropType';\nimport { handleBreakpoints } from './breakpoints';\nimport { getPath } from './style';\nimport merge from './merge';\nimport memoize from './memoize';\nconst properties = {\n m: 'margin',\n p: 'padding'\n};\nconst directions = {\n t: 'Top',\n r: 'Right',\n b: 'Bottom',\n l: 'Left',\n x: ['Left', 'Right'],\n y: ['Top', 'Bottom']\n};\nconst aliases = {\n marginX: 'mx',\n marginY: 'my',\n paddingX: 'px',\n paddingY: 'py'\n};\n\n// memoize() impact:\n// From 300,000 ops/sec\n// To 350,000 ops/sec\nconst getCssProperties = memoize(prop => {\n // It's not a shorthand notation.\n if (prop.length > 2) {\n if (aliases[prop]) {\n prop = aliases[prop];\n } else {\n return [prop];\n }\n }\n const [a, b] = prop.split('');\n const property = properties[a];\n const direction = directions[b] || '';\n return Array.isArray(direction) ? direction.map(dir => property + dir) : [property + direction];\n});\nexport const marginKeys = ['m', 'mt', 'mr', 'mb', 'ml', 'mx', 'my', 'margin', 'marginTop', 'marginRight', 'marginBottom', 'marginLeft', 'marginX', 'marginY', 'marginInline', 'marginInlineStart', 'marginInlineEnd', 'marginBlock', 'marginBlockStart', 'marginBlockEnd'];\nexport const paddingKeys = ['p', 'pt', 'pr', 'pb', 'pl', 'px', 'py', 'padding', 'paddingTop', 'paddingRight', 'paddingBottom', 'paddingLeft', 'paddingX', 'paddingY', 'paddingInline', 'paddingInlineStart', 'paddingInlineEnd', 'paddingBlock', 'paddingBlockStart', 'paddingBlockEnd'];\nconst spacingKeys = [...marginKeys, ...paddingKeys];\nexport function createUnaryUnit(theme, themeKey, defaultValue, propName) {\n var _getPath;\n const themeSpacing = (_getPath = getPath(theme, themeKey, false)) != null ? _getPath : defaultValue;\n if (typeof themeSpacing === 'number') {\n return abs => {\n if (typeof abs === 'string') {\n return abs;\n }\n if (process.env.NODE_ENV !== 'production') {\n if (typeof abs !== 'number') {\n console.error(`MUI: Expected ${propName} argument to be a number or a string, got ${abs}.`);\n }\n }\n return themeSpacing * abs;\n };\n }\n if (Array.isArray(themeSpacing)) {\n return abs => {\n if (typeof abs === 'string') {\n return abs;\n }\n if (process.env.NODE_ENV !== 'production') {\n if (!Number.isInteger(abs)) {\n console.error([`MUI: The \\`theme.${themeKey}\\` array type cannot be combined with non integer values.` + `You should either use an integer value that can be used as index, or define the \\`theme.${themeKey}\\` as a number.`].join('\\n'));\n } else if (abs > themeSpacing.length - 1) {\n console.error([`MUI: The value provided (${abs}) overflows.`, `The supported values are: ${JSON.stringify(themeSpacing)}.`, `${abs} > ${themeSpacing.length - 1}, you need to add the missing values.`].join('\\n'));\n }\n }\n return themeSpacing[abs];\n };\n }\n if (typeof themeSpacing === 'function') {\n return themeSpacing;\n }\n if (process.env.NODE_ENV !== 'production') {\n console.error([`MUI: The \\`theme.${themeKey}\\` value (${themeSpacing}) is invalid.`, 'It should be a number, an array or a function.'].join('\\n'));\n }\n return () => undefined;\n}\nexport function createUnarySpacing(theme) {\n return createUnaryUnit(theme, 'spacing', 8, 'spacing');\n}\nexport function getValue(transformer, propValue) {\n if (typeof propValue === 'string' || propValue == null) {\n return propValue;\n }\n const abs = Math.abs(propValue);\n const transformed = transformer(abs);\n if (propValue >= 0) {\n return transformed;\n }\n if (typeof transformed === 'number') {\n return -transformed;\n }\n return `-${transformed}`;\n}\nexport function getStyleFromPropValue(cssProperties, transformer) {\n return propValue => cssProperties.reduce((acc, cssProperty) => {\n acc[cssProperty] = getValue(transformer, propValue);\n return acc;\n }, {});\n}\nfunction resolveCssProperty(props, keys, prop, transformer) {\n // Using a hash computation over an array iteration could be faster, but with only 28 items,\n // it's doesn't worth the bundle size.\n if (keys.indexOf(prop) === -1) {\n return null;\n }\n const cssProperties = getCssProperties(prop);\n const styleFromPropValue = getStyleFromPropValue(cssProperties, transformer);\n const propValue = props[prop];\n return handleBreakpoints(props, propValue, styleFromPropValue);\n}\nfunction style(props, keys) {\n const transformer = createUnarySpacing(props.theme);\n return Object.keys(props).map(prop => resolveCssProperty(props, keys, prop, transformer)).reduce(merge, {});\n}\nexport function margin(props) {\n return style(props, marginKeys);\n}\nmargin.propTypes = process.env.NODE_ENV !== 'production' ? marginKeys.reduce((obj, key) => {\n obj[key] = responsivePropType;\n return obj;\n}, {}) : {};\nmargin.filterProps = marginKeys;\nexport function padding(props) {\n return style(props, paddingKeys);\n}\npadding.propTypes = process.env.NODE_ENV !== 'production' ? paddingKeys.reduce((obj, key) => {\n obj[key] = responsivePropType;\n return obj;\n}, {}) : {};\npadding.filterProps = paddingKeys;\nfunction spacing(props) {\n return style(props, spacingKeys);\n}\nspacing.propTypes = process.env.NODE_ENV !== 'production' ? spacingKeys.reduce((obj, key) => {\n obj[key] = responsivePropType;\n return obj;\n}, {}) : {};\nspacing.filterProps = spacingKeys;\nexport default spacing;","import { createUnarySpacing } from '../spacing';\n\n// The different signatures imply different meaning for their arguments that can't be expressed structurally.\n// We express the difference with variable names.\n\nexport default function createSpacing(spacingInput = 8) {\n // Already transformed.\n if (spacingInput.mui) {\n return spacingInput;\n }\n\n // Material Design layouts are visually balanced. Most measurements align to an 8dp grid, which aligns both spacing and the overall layout.\n // Smaller components, such as icons, can align to a 4dp grid.\n // https://m2.material.io/design/layout/understanding-layout.html\n const transform = createUnarySpacing({\n spacing: spacingInput\n });\n const spacing = (...argsInput) => {\n if (process.env.NODE_ENV !== 'production') {\n if (!(argsInput.length <= 4)) {\n console.error(`MUI: Too many arguments provided, expected between 0 and 4, got ${argsInput.length}`);\n }\n }\n const args = argsInput.length === 0 ? [1] : argsInput;\n return args.map(argument => {\n const output = transform(argument);\n return typeof output === 'number' ? `${output}px` : output;\n }).join(' ');\n };\n spacing.mui = true;\n return spacing;\n}","import merge from './merge';\nfunction compose(...styles) {\n const handlers = styles.reduce((acc, style) => {\n style.filterProps.forEach(prop => {\n acc[prop] = style;\n });\n return acc;\n }, {});\n\n // false positive\n // eslint-disable-next-line react/function-component-definition\n const fn = props => {\n return Object.keys(props).reduce((acc, prop) => {\n if (handlers[prop]) {\n return merge(acc, handlers[prop](props));\n }\n return acc;\n }, {});\n };\n fn.propTypes = process.env.NODE_ENV !== 'production' ? styles.reduce((acc, style) => Object.assign(acc, style.propTypes), {}) : {};\n fn.filterProps = styles.reduce((acc, style) => acc.concat(style.filterProps), []);\n return fn;\n}\nexport default compose;","import responsivePropType from './responsivePropType';\nimport style from './style';\nimport compose from './compose';\nimport { createUnaryUnit, getValue } from './spacing';\nimport { handleBreakpoints } from './breakpoints';\nexport function borderTransform(value) {\n if (typeof value !== 'number') {\n return value;\n }\n return `${value}px solid`;\n}\nfunction createBorderStyle(prop, transform) {\n return style({\n prop,\n themeKey: 'borders',\n transform\n });\n}\nexport const border = createBorderStyle('border', borderTransform);\nexport const borderTop = createBorderStyle('borderTop', borderTransform);\nexport const borderRight = createBorderStyle('borderRight', borderTransform);\nexport const borderBottom = createBorderStyle('borderBottom', borderTransform);\nexport const borderLeft = createBorderStyle('borderLeft', borderTransform);\nexport const borderColor = createBorderStyle('borderColor');\nexport const borderTopColor = createBorderStyle('borderTopColor');\nexport const borderRightColor = createBorderStyle('borderRightColor');\nexport const borderBottomColor = createBorderStyle('borderBottomColor');\nexport const borderLeftColor = createBorderStyle('borderLeftColor');\nexport const outline = createBorderStyle('outline', borderTransform);\nexport const outlineColor = createBorderStyle('outlineColor');\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const borderRadius = props => {\n if (props.borderRadius !== undefined && props.borderRadius !== null) {\n const transformer = createUnaryUnit(props.theme, 'shape.borderRadius', 4, 'borderRadius');\n const styleFromPropValue = propValue => ({\n borderRadius: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.borderRadius, styleFromPropValue);\n }\n return null;\n};\nborderRadius.propTypes = process.env.NODE_ENV !== 'production' ? {\n borderRadius: responsivePropType\n} : {};\nborderRadius.filterProps = ['borderRadius'];\nconst borders = compose(border, borderTop, borderRight, borderBottom, borderLeft, borderColor, borderTopColor, borderRightColor, borderBottomColor, borderLeftColor, borderRadius, outline, outlineColor);\nexport default borders;","import style from './style';\nimport compose from './compose';\nimport { createUnaryUnit, getValue } from './spacing';\nimport { handleBreakpoints } from './breakpoints';\nimport responsivePropType from './responsivePropType';\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const gap = props => {\n if (props.gap !== undefined && props.gap !== null) {\n const transformer = createUnaryUnit(props.theme, 'spacing', 8, 'gap');\n const styleFromPropValue = propValue => ({\n gap: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.gap, styleFromPropValue);\n }\n return null;\n};\ngap.propTypes = process.env.NODE_ENV !== 'production' ? {\n gap: responsivePropType\n} : {};\ngap.filterProps = ['gap'];\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const columnGap = props => {\n if (props.columnGap !== undefined && props.columnGap !== null) {\n const transformer = createUnaryUnit(props.theme, 'spacing', 8, 'columnGap');\n const styleFromPropValue = propValue => ({\n columnGap: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.columnGap, styleFromPropValue);\n }\n return null;\n};\ncolumnGap.propTypes = process.env.NODE_ENV !== 'production' ? {\n columnGap: responsivePropType\n} : {};\ncolumnGap.filterProps = ['columnGap'];\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const rowGap = props => {\n if (props.rowGap !== undefined && props.rowGap !== null) {\n const transformer = createUnaryUnit(props.theme, 'spacing', 8, 'rowGap');\n const styleFromPropValue = propValue => ({\n rowGap: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.rowGap, styleFromPropValue);\n }\n return null;\n};\nrowGap.propTypes = process.env.NODE_ENV !== 'production' ? {\n rowGap: responsivePropType\n} : {};\nrowGap.filterProps = ['rowGap'];\nexport const gridColumn = style({\n prop: 'gridColumn'\n});\nexport const gridRow = style({\n prop: 'gridRow'\n});\nexport const gridAutoFlow = style({\n prop: 'gridAutoFlow'\n});\nexport const gridAutoColumns = style({\n prop: 'gridAutoColumns'\n});\nexport const gridAutoRows = style({\n prop: 'gridAutoRows'\n});\nexport const gridTemplateColumns = style({\n prop: 'gridTemplateColumns'\n});\nexport const gridTemplateRows = style({\n prop: 'gridTemplateRows'\n});\nexport const gridTemplateAreas = style({\n prop: 'gridTemplateAreas'\n});\nexport const gridArea = style({\n prop: 'gridArea'\n});\nconst grid = compose(gap, columnGap, rowGap, gridColumn, gridRow, gridAutoFlow, gridAutoColumns, gridAutoRows, gridTemplateColumns, gridTemplateRows, gridTemplateAreas, gridArea);\nexport default grid;","import style from './style';\nimport compose from './compose';\nexport function paletteTransform(value, userValue) {\n if (userValue === 'grey') {\n return userValue;\n }\n return value;\n}\nexport const color = style({\n prop: 'color',\n themeKey: 'palette',\n transform: paletteTransform\n});\nexport const bgcolor = style({\n prop: 'bgcolor',\n cssProperty: 'backgroundColor',\n themeKey: 'palette',\n transform: paletteTransform\n});\nexport const backgroundColor = style({\n prop: 'backgroundColor',\n themeKey: 'palette',\n transform: paletteTransform\n});\nconst palette = compose(color, bgcolor, backgroundColor);\nexport default palette;","import style from './style';\nimport compose from './compose';\nimport { handleBreakpoints, values as breakpointsValues } from './breakpoints';\nexport function sizingTransform(value) {\n return value <= 1 && value !== 0 ? `${value * 100}%` : value;\n}\nexport const width = style({\n prop: 'width',\n transform: sizingTransform\n});\nexport const maxWidth = props => {\n if (props.maxWidth !== undefined && props.maxWidth !== null) {\n const styleFromPropValue = propValue => {\n var _props$theme, _props$theme2;\n const breakpoint = ((_props$theme = props.theme) == null || (_props$theme = _props$theme.breakpoints) == null || (_props$theme = _props$theme.values) == null ? void 0 : _props$theme[propValue]) || breakpointsValues[propValue];\n if (!breakpoint) {\n return {\n maxWidth: sizingTransform(propValue)\n };\n }\n if (((_props$theme2 = props.theme) == null || (_props$theme2 = _props$theme2.breakpoints) == null ? void 0 : _props$theme2.unit) !== 'px') {\n return {\n maxWidth: `${breakpoint}${props.theme.breakpoints.unit}`\n };\n }\n return {\n maxWidth: breakpoint\n };\n };\n return handleBreakpoints(props, props.maxWidth, styleFromPropValue);\n }\n return null;\n};\nmaxWidth.filterProps = ['maxWidth'];\nexport const minWidth = style({\n prop: 'minWidth',\n transform: sizingTransform\n});\nexport const height = style({\n prop: 'height',\n transform: sizingTransform\n});\nexport const maxHeight = style({\n prop: 'maxHeight',\n transform: sizingTransform\n});\nexport const minHeight = style({\n prop: 'minHeight',\n transform: sizingTransform\n});\nexport const sizeWidth = style({\n prop: 'size',\n cssProperty: 'width',\n transform: sizingTransform\n});\nexport const sizeHeight = style({\n prop: 'size',\n cssProperty: 'height',\n transform: sizingTransform\n});\nexport const boxSizing = style({\n prop: 'boxSizing'\n});\nconst sizing = compose(width, maxWidth, minWidth, height, maxHeight, minHeight, boxSizing);\nexport default sizing;","import { padding, margin } from '../spacing';\nimport { borderRadius, borderTransform } from '../borders';\nimport { gap, rowGap, columnGap } from '../cssGrid';\nimport { paletteTransform } from '../palette';\nimport { maxWidth, sizingTransform } from '../sizing';\nconst defaultSxConfig = {\n // borders\n border: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderTop: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderRight: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderBottom: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderLeft: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderColor: {\n themeKey: 'palette'\n },\n borderTopColor: {\n themeKey: 'palette'\n },\n borderRightColor: {\n themeKey: 'palette'\n },\n borderBottomColor: {\n themeKey: 'palette'\n },\n borderLeftColor: {\n themeKey: 'palette'\n },\n outline: {\n themeKey: 'borders',\n transform: borderTransform\n },\n outlineColor: {\n themeKey: 'palette'\n },\n borderRadius: {\n themeKey: 'shape.borderRadius',\n style: borderRadius\n },\n // palette\n color: {\n themeKey: 'palette',\n transform: paletteTransform\n },\n bgcolor: {\n themeKey: 'palette',\n cssProperty: 'backgroundColor',\n transform: paletteTransform\n },\n backgroundColor: {\n themeKey: 'palette',\n transform: paletteTransform\n },\n // spacing\n p: {\n style: padding\n },\n pt: {\n style: padding\n },\n pr: {\n style: padding\n },\n pb: {\n style: padding\n },\n pl: {\n style: padding\n },\n px: {\n style: padding\n },\n py: {\n style: padding\n },\n padding: {\n style: padding\n },\n paddingTop: {\n style: padding\n },\n paddingRight: {\n style: padding\n },\n paddingBottom: {\n style: padding\n },\n paddingLeft: {\n style: padding\n },\n paddingX: {\n style: padding\n },\n paddingY: {\n style: padding\n },\n paddingInline: {\n style: padding\n },\n paddingInlineStart: {\n style: padding\n },\n paddingInlineEnd: {\n style: padding\n },\n paddingBlock: {\n style: padding\n },\n paddingBlockStart: {\n style: padding\n },\n paddingBlockEnd: {\n style: padding\n },\n m: {\n style: margin\n },\n mt: {\n style: margin\n },\n mr: {\n style: margin\n },\n mb: {\n style: margin\n },\n ml: {\n style: margin\n },\n mx: {\n style: margin\n },\n my: {\n style: margin\n },\n margin: {\n style: margin\n },\n marginTop: {\n style: margin\n },\n marginRight: {\n style: margin\n },\n marginBottom: {\n style: margin\n },\n marginLeft: {\n style: margin\n },\n marginX: {\n style: margin\n },\n marginY: {\n style: margin\n },\n marginInline: {\n style: margin\n },\n marginInlineStart: {\n style: margin\n },\n marginInlineEnd: {\n style: margin\n },\n marginBlock: {\n style: margin\n },\n marginBlockStart: {\n style: margin\n },\n marginBlockEnd: {\n style: margin\n },\n // display\n displayPrint: {\n cssProperty: false,\n transform: value => ({\n '@media print': {\n display: value\n }\n })\n },\n display: {},\n overflow: {},\n textOverflow: {},\n visibility: {},\n whiteSpace: {},\n // flexbox\n flexBasis: {},\n flexDirection: {},\n flexWrap: {},\n justifyContent: {},\n alignItems: {},\n alignContent: {},\n order: {},\n flex: {},\n flexGrow: {},\n flexShrink: {},\n alignSelf: {},\n justifyItems: {},\n justifySelf: {},\n // grid\n gap: {\n style: gap\n },\n rowGap: {\n style: rowGap\n },\n columnGap: {\n style: columnGap\n },\n gridColumn: {},\n gridRow: {},\n gridAutoFlow: {},\n gridAutoColumns: {},\n gridAutoRows: {},\n gridTemplateColumns: {},\n gridTemplateRows: {},\n gridTemplateAreas: {},\n gridArea: {},\n // positions\n position: {},\n zIndex: {\n themeKey: 'zIndex'\n },\n top: {},\n right: {},\n bottom: {},\n left: {},\n // shadows\n boxShadow: {\n themeKey: 'shadows'\n },\n // sizing\n width: {\n transform: sizingTransform\n },\n maxWidth: {\n style: maxWidth\n },\n minWidth: {\n transform: sizingTransform\n },\n height: {\n transform: sizingTransform\n },\n maxHeight: {\n transform: sizingTransform\n },\n minHeight: {\n transform: sizingTransform\n },\n boxSizing: {},\n // typography\n fontFamily: {\n themeKey: 'typography'\n },\n fontSize: {\n themeKey: 'typography'\n },\n fontStyle: {\n themeKey: 'typography'\n },\n fontWeight: {\n themeKey: 'typography'\n },\n letterSpacing: {},\n textTransform: {},\n lineHeight: {},\n textAlign: {},\n typography: {\n cssProperty: false,\n themeKey: 'typography'\n }\n};\nexport default defaultSxConfig;","import capitalize from '@mui/utils/capitalize';\nimport merge from '../merge';\nimport { getPath, getStyleValue as getValue } from '../style';\nimport { handleBreakpoints, createEmptyBreakpointObject, removeUnusedBreakpoints } from '../breakpoints';\nimport defaultSxConfig from './defaultSxConfig';\nfunction objectsHaveSameKeys(...objects) {\n const allKeys = objects.reduce((keys, object) => keys.concat(Object.keys(object)), []);\n const union = new Set(allKeys);\n return objects.every(object => union.size === Object.keys(object).length);\n}\nfunction callIfFn(maybeFn, arg) {\n return typeof maybeFn === 'function' ? maybeFn(arg) : maybeFn;\n}\n\n// eslint-disable-next-line @typescript-eslint/naming-convention\nexport function unstable_createStyleFunctionSx() {\n function getThemeValue(prop, val, theme, config) {\n const props = {\n [prop]: val,\n theme\n };\n const options = config[prop];\n if (!options) {\n return {\n [prop]: val\n };\n }\n const {\n cssProperty = prop,\n themeKey,\n transform,\n style\n } = options;\n if (val == null) {\n return null;\n }\n\n // TODO v6: remove, see https://github.com/mui/material-ui/pull/38123\n if (themeKey === 'typography' && val === 'inherit') {\n return {\n [prop]: val\n };\n }\n const themeMapping = getPath(theme, themeKey) || {};\n if (style) {\n return style(props);\n }\n const styleFromPropValue = propValueFinal => {\n let value = getValue(themeMapping, transform, propValueFinal);\n if (propValueFinal === value && typeof propValueFinal === 'string') {\n // Haven't found value\n value = getValue(themeMapping, transform, `${prop}${propValueFinal === 'default' ? '' : capitalize(propValueFinal)}`, propValueFinal);\n }\n if (cssProperty === false) {\n return value;\n }\n return {\n [cssProperty]: value\n };\n };\n return handleBreakpoints(props, val, styleFromPropValue);\n }\n function styleFunctionSx(props) {\n var _theme$unstable_sxCon;\n const {\n sx,\n theme = {}\n } = props || {};\n if (!sx) {\n return null; // Emotion & styled-components will neglect null\n }\n const config = (_theme$unstable_sxCon = theme.unstable_sxConfig) != null ? _theme$unstable_sxCon : defaultSxConfig;\n\n /*\n * Receive `sxInput` as object or callback\n * and then recursively check keys & values to create media query object styles.\n * (the result will be used in `styled`)\n */\n function traverse(sxInput) {\n let sxObject = sxInput;\n if (typeof sxInput === 'function') {\n sxObject = sxInput(theme);\n } else if (typeof sxInput !== 'object') {\n // value\n return sxInput;\n }\n if (!sxObject) {\n return null;\n }\n const emptyBreakpoints = createEmptyBreakpointObject(theme.breakpoints);\n const breakpointsKeys = Object.keys(emptyBreakpoints);\n let css = emptyBreakpoints;\n Object.keys(sxObject).forEach(styleKey => {\n const value = callIfFn(sxObject[styleKey], theme);\n if (value !== null && value !== undefined) {\n if (typeof value === 'object') {\n if (config[styleKey]) {\n css = merge(css, getThemeValue(styleKey, value, theme, config));\n } else {\n const breakpointsValues = handleBreakpoints({\n theme\n }, value, x => ({\n [styleKey]: x\n }));\n if (objectsHaveSameKeys(breakpointsValues, value)) {\n css[styleKey] = styleFunctionSx({\n sx: value,\n theme\n });\n } else {\n css = merge(css, breakpointsValues);\n }\n }\n } else {\n css = merge(css, getThemeValue(styleKey, value, theme, config));\n }\n }\n });\n return removeUnusedBreakpoints(breakpointsKeys, css);\n }\n return Array.isArray(sx) ? sx.map(traverse) : traverse(sx);\n }\n return styleFunctionSx;\n}\nconst styleFunctionSx = unstable_createStyleFunctionSx();\nstyleFunctionSx.filterProps = ['sx'];\nexport default styleFunctionSx;","/**\n * A universal utility to style components with multiple color modes. Always use it from the theme object.\n * It works with:\n * - [Basic theme](https://mui.com/material-ui/customization/dark-mode/)\n * - [CSS theme variables](https://mui.com/material-ui/experimental-api/css-theme-variables/overview/)\n * - Zero-runtime engine\n *\n * Tips: Use an array over object spread and place `theme.applyStyles()` last.\n *\n * ✅ [{ background: '#e5e5e5' }, theme.applyStyles('dark', { background: '#1c1c1c' })]\n *\n * 🚫 { background: '#e5e5e5', ...theme.applyStyles('dark', { background: '#1c1c1c' })}\n *\n * @example\n * 1. using with `styled`:\n * ```jsx\n * const Component = styled('div')(({ theme }) => [\n * { background: '#e5e5e5' },\n * theme.applyStyles('dark', {\n * background: '#1c1c1c',\n * color: '#fff',\n * }),\n * ]);\n * ```\n *\n * @example\n * 2. using with `sx` prop:\n * ```jsx\n * [\n * { background: '#e5e5e5' },\n * theme.applyStyles('dark', {\n * background: '#1c1c1c',\n * color: '#fff',\n * }),\n * ]}\n * />\n * ```\n *\n * @example\n * 3. theming a component:\n * ```jsx\n * extendTheme({\n * components: {\n * MuiButton: {\n * styleOverrides: {\n * root: ({ theme }) => [\n * { background: '#e5e5e5' },\n * theme.applyStyles('dark', {\n * background: '#1c1c1c',\n * color: '#fff',\n * }),\n * ],\n * },\n * }\n * }\n * })\n *```\n */\nexport default function applyStyles(key, styles) {\n // @ts-expect-error this is 'any' type\n const theme = this;\n if (theme.vars && typeof theme.getColorSchemeSelector === 'function') {\n // If CssVarsProvider is used as a provider,\n // returns '* :where([data-mui-color-scheme=\"light|dark\"]) &'\n const selector = theme.getColorSchemeSelector(key).replace(/(\\[[^\\]]+\\])/, '*:where($1)');\n return {\n [selector]: styles\n };\n }\n if (theme.palette.mode === key) {\n return styles;\n }\n return {};\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"breakpoints\", \"palette\", \"spacing\", \"shape\"];\nimport deepmerge from '@mui/utils/deepmerge';\nimport createBreakpoints from './createBreakpoints';\nimport shape from './shape';\nimport createSpacing from './createSpacing';\nimport styleFunctionSx from '../styleFunctionSx/styleFunctionSx';\nimport defaultSxConfig from '../styleFunctionSx/defaultSxConfig';\nimport applyStyles from './applyStyles';\nfunction createTheme(options = {}, ...args) {\n const {\n breakpoints: breakpointsInput = {},\n palette: paletteInput = {},\n spacing: spacingInput,\n shape: shapeInput = {}\n } = options,\n other = _objectWithoutPropertiesLoose(options, _excluded);\n const breakpoints = createBreakpoints(breakpointsInput);\n const spacing = createSpacing(spacingInput);\n let muiTheme = deepmerge({\n breakpoints,\n direction: 'ltr',\n components: {},\n // Inject component definitions.\n palette: _extends({\n mode: 'light'\n }, paletteInput),\n spacing,\n shape: _extends({}, shape, shapeInput)\n }, other);\n muiTheme.applyStyles = applyStyles;\n muiTheme = args.reduce((acc, argument) => deepmerge(acc, argument), muiTheme);\n muiTheme.unstable_sxConfig = _extends({}, defaultSxConfig, other == null ? void 0 : other.unstable_sxConfig);\n muiTheme.unstable_sx = function sx(props) {\n return styleFunctionSx({\n sx: props,\n theme: this\n });\n };\n return muiTheme;\n}\nexport default createTheme;","'use client';\n\nimport * as React from 'react';\nimport { ThemeContext } from '@mui/styled-engine';\nfunction isObjectEmpty(obj) {\n return Object.keys(obj).length === 0;\n}\nfunction useTheme(defaultTheme = null) {\n const contextTheme = React.useContext(ThemeContext);\n return !contextTheme || isObjectEmpty(contextTheme) ? defaultTheme : contextTheme;\n}\nexport default useTheme;","'use client';\n\nimport createTheme from './createTheme';\nimport useThemeWithoutDefault from './useThemeWithoutDefault';\nexport const systemDefaultTheme = createTheme();\nfunction useTheme(defaultTheme = systemDefaultTheme) {\n return useThemeWithoutDefault(defaultTheme);\n}\nexport default useTheme;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"ownerState\"],\n _excluded2 = [\"variants\"],\n _excluded3 = [\"name\", \"slot\", \"skipVariantsResolver\", \"skipSx\", \"overridesResolver\"];\n/* eslint-disable no-underscore-dangle */\nimport styledEngineStyled, { internal_processStyles as processStyles } from '@mui/styled-engine';\nimport { isPlainObject } from '@mui/utils/deepmerge';\nimport capitalize from '@mui/utils/capitalize';\nimport getDisplayName from '@mui/utils/getDisplayName';\nimport createTheme from './createTheme';\nimport styleFunctionSx from './styleFunctionSx';\nfunction isEmpty(obj) {\n return Object.keys(obj).length === 0;\n}\n\n// https://github.com/emotion-js/emotion/blob/26ded6109fcd8ca9875cc2ce4564fee678a3f3c5/packages/styled/src/utils.js#L40\nfunction isStringTag(tag) {\n return typeof tag === 'string' &&\n // 96 is one less than the char code\n // for \"a\" so this is checking that\n // it's a lowercase character\n tag.charCodeAt(0) > 96;\n}\n\n// Update /system/styled/#api in case if this changes\nexport function shouldForwardProp(prop) {\n return prop !== 'ownerState' && prop !== 'theme' && prop !== 'sx' && prop !== 'as';\n}\nexport const systemDefaultTheme = createTheme();\nconst lowercaseFirstLetter = string => {\n if (!string) {\n return string;\n }\n return string.charAt(0).toLowerCase() + string.slice(1);\n};\nfunction resolveTheme({\n defaultTheme,\n theme,\n themeId\n}) {\n return isEmpty(theme) ? defaultTheme : theme[themeId] || theme;\n}\nfunction defaultOverridesResolver(slot) {\n if (!slot) {\n return null;\n }\n return (props, styles) => styles[slot];\n}\nfunction processStyleArg(callableStyle, _ref) {\n let {\n ownerState\n } = _ref,\n props = _objectWithoutPropertiesLoose(_ref, _excluded);\n const resolvedStylesArg = typeof callableStyle === 'function' ? callableStyle(_extends({\n ownerState\n }, props)) : callableStyle;\n if (Array.isArray(resolvedStylesArg)) {\n return resolvedStylesArg.flatMap(resolvedStyle => processStyleArg(resolvedStyle, _extends({\n ownerState\n }, props)));\n }\n if (!!resolvedStylesArg && typeof resolvedStylesArg === 'object' && Array.isArray(resolvedStylesArg.variants)) {\n const {\n variants = []\n } = resolvedStylesArg,\n otherStyles = _objectWithoutPropertiesLoose(resolvedStylesArg, _excluded2);\n let result = otherStyles;\n variants.forEach(variant => {\n let isMatch = true;\n if (typeof variant.props === 'function') {\n isMatch = variant.props(_extends({\n ownerState\n }, props, ownerState));\n } else {\n Object.keys(variant.props).forEach(key => {\n if ((ownerState == null ? void 0 : ownerState[key]) !== variant.props[key] && props[key] !== variant.props[key]) {\n isMatch = false;\n }\n });\n }\n if (isMatch) {\n if (!Array.isArray(result)) {\n result = [result];\n }\n result.push(typeof variant.style === 'function' ? variant.style(_extends({\n ownerState\n }, props, ownerState)) : variant.style);\n }\n });\n return result;\n }\n return resolvedStylesArg;\n}\nexport default function createStyled(input = {}) {\n const {\n themeId,\n defaultTheme = systemDefaultTheme,\n rootShouldForwardProp = shouldForwardProp,\n slotShouldForwardProp = shouldForwardProp\n } = input;\n const systemSx = props => {\n return styleFunctionSx(_extends({}, props, {\n theme: resolveTheme(_extends({}, props, {\n defaultTheme,\n themeId\n }))\n }));\n };\n systemSx.__mui_systemSx = true;\n return (tag, inputOptions = {}) => {\n // Filter out the `sx` style function from the previous styled component to prevent unnecessary styles generated by the composite components.\n processStyles(tag, styles => styles.filter(style => !(style != null && style.__mui_systemSx)));\n const {\n name: componentName,\n slot: componentSlot,\n skipVariantsResolver: inputSkipVariantsResolver,\n skipSx: inputSkipSx,\n // TODO v6: remove `lowercaseFirstLetter()` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n overridesResolver = defaultOverridesResolver(lowercaseFirstLetter(componentSlot))\n } = inputOptions,\n options = _objectWithoutPropertiesLoose(inputOptions, _excluded3);\n\n // if skipVariantsResolver option is defined, take the value, otherwise, true for root and false for other slots.\n const skipVariantsResolver = inputSkipVariantsResolver !== undefined ? inputSkipVariantsResolver :\n // TODO v6: remove `Root` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n componentSlot && componentSlot !== 'Root' && componentSlot !== 'root' || false;\n const skipSx = inputSkipSx || false;\n let label;\n if (process.env.NODE_ENV !== 'production') {\n if (componentName) {\n // TODO v6: remove `lowercaseFirstLetter()` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n label = `${componentName}-${lowercaseFirstLetter(componentSlot || 'Root')}`;\n }\n }\n let shouldForwardPropOption = shouldForwardProp;\n\n // TODO v6: remove `Root` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n if (componentSlot === 'Root' || componentSlot === 'root') {\n shouldForwardPropOption = rootShouldForwardProp;\n } else if (componentSlot) {\n // any other slot specified\n shouldForwardPropOption = slotShouldForwardProp;\n } else if (isStringTag(tag)) {\n // for string (html) tag, preserve the behavior in emotion & styled-components.\n shouldForwardPropOption = undefined;\n }\n const defaultStyledResolver = styledEngineStyled(tag, _extends({\n shouldForwardProp: shouldForwardPropOption,\n label\n }, options));\n const transformStyleArg = stylesArg => {\n // On the server Emotion doesn't use React.forwardRef for creating components, so the created\n // component stays as a function. This condition makes sure that we do not interpolate functions\n // which are basically components used as a selectors.\n if (typeof stylesArg === 'function' && stylesArg.__emotion_real !== stylesArg || isPlainObject(stylesArg)) {\n return props => processStyleArg(stylesArg, _extends({}, props, {\n theme: resolveTheme({\n theme: props.theme,\n defaultTheme,\n themeId\n })\n }));\n }\n return stylesArg;\n };\n const muiStyledResolver = (styleArg, ...expressions) => {\n let transformedStyleArg = transformStyleArg(styleArg);\n const expressionsWithDefaultTheme = expressions ? expressions.map(transformStyleArg) : [];\n if (componentName && overridesResolver) {\n expressionsWithDefaultTheme.push(props => {\n const theme = resolveTheme(_extends({}, props, {\n defaultTheme,\n themeId\n }));\n if (!theme.components || !theme.components[componentName] || !theme.components[componentName].styleOverrides) {\n return null;\n }\n const styleOverrides = theme.components[componentName].styleOverrides;\n const resolvedStyleOverrides = {};\n // TODO: v7 remove iteration and use `resolveStyleArg(styleOverrides[slot])` directly\n Object.entries(styleOverrides).forEach(([slotKey, slotStyle]) => {\n resolvedStyleOverrides[slotKey] = processStyleArg(slotStyle, _extends({}, props, {\n theme\n }));\n });\n return overridesResolver(props, resolvedStyleOverrides);\n });\n }\n if (componentName && !skipVariantsResolver) {\n expressionsWithDefaultTheme.push(props => {\n var _theme$components;\n const theme = resolveTheme(_extends({}, props, {\n defaultTheme,\n themeId\n }));\n const themeVariants = theme == null || (_theme$components = theme.components) == null || (_theme$components = _theme$components[componentName]) == null ? void 0 : _theme$components.variants;\n return processStyleArg({\n variants: themeVariants\n }, _extends({}, props, {\n theme\n }));\n });\n }\n if (!skipSx) {\n expressionsWithDefaultTheme.push(systemSx);\n }\n const numOfCustomFnsApplied = expressionsWithDefaultTheme.length - expressions.length;\n if (Array.isArray(styleArg) && numOfCustomFnsApplied > 0) {\n const placeholders = new Array(numOfCustomFnsApplied).fill('');\n // If the type is array, than we need to add placeholders in the template for the overrides, variants and the sx styles.\n transformedStyleArg = [...styleArg, ...placeholders];\n transformedStyleArg.raw = [...styleArg.raw, ...placeholders];\n }\n const Component = defaultStyledResolver(transformedStyleArg, ...expressionsWithDefaultTheme);\n if (process.env.NODE_ENV !== 'production') {\n let displayName;\n if (componentName) {\n displayName = `${componentName}${capitalize(componentSlot || '')}`;\n }\n if (displayName === undefined) {\n displayName = `Styled(${getDisplayName(tag)})`;\n }\n Component.displayName = displayName;\n }\n if (tag.muiName) {\n Component.muiName = tag.muiName;\n }\n return Component;\n };\n if (defaultStyledResolver.withConfig) {\n muiStyledResolver.withConfig = defaultStyledResolver.withConfig;\n }\n return muiStyledResolver;\n };\n}","import resolveProps from '@mui/utils/resolveProps';\nexport default function getThemeProps(params) {\n const {\n theme,\n name,\n props\n } = params;\n if (!theme || !theme.components || !theme.components[name] || !theme.components[name].defaultProps) {\n return props;\n }\n return resolveProps(theme.components[name].defaultProps, props);\n}","'use client';\n\nimport getThemeProps from './getThemeProps';\nimport useTheme from '../useTheme';\nexport default function useThemeProps({\n props,\n name,\n defaultTheme,\n themeId\n}) {\n let theme = useTheme(defaultTheme);\n if (themeId) {\n theme = theme[themeId] || theme;\n }\n const mergedProps = getThemeProps({\n theme,\n name,\n props\n });\n return mergedProps;\n}","import _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\n/* eslint-disable @typescript-eslint/naming-convention */\nimport clamp from '@mui/utils/clamp';\n/**\n * Returns a number whose value is limited to the given range.\n * @param {number} value The value to be clamped\n * @param {number} min The lower boundary of the output range\n * @param {number} max The upper boundary of the output range\n * @returns {number} A number in the range [min, max]\n */\nfunction clampWrapper(value, min = 0, max = 1) {\n if (process.env.NODE_ENV !== 'production') {\n if (value < min || value > max) {\n console.error(`MUI: The value provided ${value} is out of range [${min}, ${max}].`);\n }\n }\n return clamp(value, min, max);\n}\n\n/**\n * Converts a color from CSS hex format to CSS rgb format.\n * @param {string} color - Hex color, i.e. #nnn or #nnnnnn\n * @returns {string} A CSS rgb color string\n */\nexport function hexToRgb(color) {\n color = color.slice(1);\n const re = new RegExp(`.{1,${color.length >= 6 ? 2 : 1}}`, 'g');\n let colors = color.match(re);\n if (colors && colors[0].length === 1) {\n colors = colors.map(n => n + n);\n }\n return colors ? `rgb${colors.length === 4 ? 'a' : ''}(${colors.map((n, index) => {\n return index < 3 ? parseInt(n, 16) : Math.round(parseInt(n, 16) / 255 * 1000) / 1000;\n }).join(', ')})` : '';\n}\nfunction intToHex(int) {\n const hex = int.toString(16);\n return hex.length === 1 ? `0${hex}` : hex;\n}\n\n/**\n * Returns an object with the type and values of a color.\n *\n * Note: Does not support rgb % values.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @returns {object} - A MUI color object: {type: string, values: number[]}\n */\nexport function decomposeColor(color) {\n // Idempotent\n if (color.type) {\n return color;\n }\n if (color.charAt(0) === '#') {\n return decomposeColor(hexToRgb(color));\n }\n const marker = color.indexOf('(');\n const type = color.substring(0, marker);\n if (['rgb', 'rgba', 'hsl', 'hsla', 'color'].indexOf(type) === -1) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: Unsupported \\`${color}\\` color.\nThe following formats are supported: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color().` : _formatMuiErrorMessage(9, color));\n }\n let values = color.substring(marker + 1, color.length - 1);\n let colorSpace;\n if (type === 'color') {\n values = values.split(' ');\n colorSpace = values.shift();\n if (values.length === 4 && values[3].charAt(0) === '/') {\n values[3] = values[3].slice(1);\n }\n if (['srgb', 'display-p3', 'a98-rgb', 'prophoto-rgb', 'rec-2020'].indexOf(colorSpace) === -1) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: unsupported \\`${colorSpace}\\` color space.\nThe following color spaces are supported: srgb, display-p3, a98-rgb, prophoto-rgb, rec-2020.` : _formatMuiErrorMessage(10, colorSpace));\n }\n } else {\n values = values.split(',');\n }\n values = values.map(value => parseFloat(value));\n return {\n type,\n values,\n colorSpace\n };\n}\n\n/**\n * Returns a channel created from the input color.\n *\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @returns {string} - The channel for the color, that can be used in rgba or hsla colors\n */\nexport const colorChannel = color => {\n const decomposedColor = decomposeColor(color);\n return decomposedColor.values.slice(0, 3).map((val, idx) => decomposedColor.type.indexOf('hsl') !== -1 && idx !== 0 ? `${val}%` : val).join(' ');\n};\nexport const private_safeColorChannel = (color, warning) => {\n try {\n return colorChannel(color);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n};\n\n/**\n * Converts a color object with type and values to a string.\n * @param {object} color - Decomposed color\n * @param {string} color.type - One of: 'rgb', 'rgba', 'hsl', 'hsla', 'color'\n * @param {array} color.values - [n,n,n] or [n,n,n,n]\n * @returns {string} A CSS color string\n */\nexport function recomposeColor(color) {\n const {\n type,\n colorSpace\n } = color;\n let {\n values\n } = color;\n if (type.indexOf('rgb') !== -1) {\n // Only convert the first 3 values to int (i.e. not alpha)\n values = values.map((n, i) => i < 3 ? parseInt(n, 10) : n);\n } else if (type.indexOf('hsl') !== -1) {\n values[1] = `${values[1]}%`;\n values[2] = `${values[2]}%`;\n }\n if (type.indexOf('color') !== -1) {\n values = `${colorSpace} ${values.join(' ')}`;\n } else {\n values = `${values.join(', ')}`;\n }\n return `${type}(${values})`;\n}\n\n/**\n * Converts a color from CSS rgb format to CSS hex format.\n * @param {string} color - RGB color, i.e. rgb(n, n, n)\n * @returns {string} A CSS rgb color string, i.e. #nnnnnn\n */\nexport function rgbToHex(color) {\n // Idempotent\n if (color.indexOf('#') === 0) {\n return color;\n }\n const {\n values\n } = decomposeColor(color);\n return `#${values.map((n, i) => intToHex(i === 3 ? Math.round(255 * n) : n)).join('')}`;\n}\n\n/**\n * Converts a color from hsl format to rgb format.\n * @param {string} color - HSL color values\n * @returns {string} rgb color values\n */\nexport function hslToRgb(color) {\n color = decomposeColor(color);\n const {\n values\n } = color;\n const h = values[0];\n const s = values[1] / 100;\n const l = values[2] / 100;\n const a = s * Math.min(l, 1 - l);\n const f = (n, k = (n + h / 30) % 12) => l - a * Math.max(Math.min(k - 3, 9 - k, 1), -1);\n let type = 'rgb';\n const rgb = [Math.round(f(0) * 255), Math.round(f(8) * 255), Math.round(f(4) * 255)];\n if (color.type === 'hsla') {\n type += 'a';\n rgb.push(values[3]);\n }\n return recomposeColor({\n type,\n values: rgb\n });\n}\n/**\n * The relative brightness of any point in a color space,\n * normalized to 0 for darkest black and 1 for lightest white.\n *\n * Formula: https://www.w3.org/TR/WCAG20-TECHS/G17.html#G17-tests\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @returns {number} The relative brightness of the color in the range 0 - 1\n */\nexport function getLuminance(color) {\n color = decomposeColor(color);\n let rgb = color.type === 'hsl' || color.type === 'hsla' ? decomposeColor(hslToRgb(color)).values : color.values;\n rgb = rgb.map(val => {\n if (color.type !== 'color') {\n val /= 255; // normalized\n }\n return val <= 0.03928 ? val / 12.92 : ((val + 0.055) / 1.055) ** 2.4;\n });\n\n // Truncate at 3 digits\n return Number((0.2126 * rgb[0] + 0.7152 * rgb[1] + 0.0722 * rgb[2]).toFixed(3));\n}\n\n/**\n * Calculates the contrast ratio between two colors.\n *\n * Formula: https://www.w3.org/TR/WCAG20-TECHS/G17.html#G17-tests\n * @param {string} foreground - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla()\n * @param {string} background - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla()\n * @returns {number} A contrast ratio value in the range 0 - 21.\n */\nexport function getContrastRatio(foreground, background) {\n const lumA = getLuminance(foreground);\n const lumB = getLuminance(background);\n return (Math.max(lumA, lumB) + 0.05) / (Math.min(lumA, lumB) + 0.05);\n}\n\n/**\n * Sets the absolute transparency of a color.\n * Any existing alpha values are overwritten.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} value - value to set the alpha channel to in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function alpha(color, value) {\n color = decomposeColor(color);\n value = clampWrapper(value);\n if (color.type === 'rgb' || color.type === 'hsl') {\n color.type += 'a';\n }\n if (color.type === 'color') {\n color.values[3] = `/${value}`;\n } else {\n color.values[3] = value;\n }\n return recomposeColor(color);\n}\nexport function private_safeAlpha(color, value, warning) {\n try {\n return alpha(color, value);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Darkens a color.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} coefficient - multiplier in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function darken(color, coefficient) {\n color = decomposeColor(color);\n coefficient = clampWrapper(coefficient);\n if (color.type.indexOf('hsl') !== -1) {\n color.values[2] *= 1 - coefficient;\n } else if (color.type.indexOf('rgb') !== -1 || color.type.indexOf('color') !== -1) {\n for (let i = 0; i < 3; i += 1) {\n color.values[i] *= 1 - coefficient;\n }\n }\n return recomposeColor(color);\n}\nexport function private_safeDarken(color, coefficient, warning) {\n try {\n return darken(color, coefficient);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Lightens a color.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} coefficient - multiplier in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function lighten(color, coefficient) {\n color = decomposeColor(color);\n coefficient = clampWrapper(coefficient);\n if (color.type.indexOf('hsl') !== -1) {\n color.values[2] += (100 - color.values[2]) * coefficient;\n } else if (color.type.indexOf('rgb') !== -1) {\n for (let i = 0; i < 3; i += 1) {\n color.values[i] += (255 - color.values[i]) * coefficient;\n }\n } else if (color.type.indexOf('color') !== -1) {\n for (let i = 0; i < 3; i += 1) {\n color.values[i] += (1 - color.values[i]) * coefficient;\n }\n }\n return recomposeColor(color);\n}\nexport function private_safeLighten(color, coefficient, warning) {\n try {\n return lighten(color, coefficient);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Darken or lighten a color, depending on its luminance.\n * Light colors are darkened, dark colors are lightened.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} coefficient=0.15 - multiplier in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function emphasize(color, coefficient = 0.15) {\n return getLuminance(color) > 0.5 ? darken(color, coefficient) : lighten(color, coefficient);\n}\nexport function private_safeEmphasize(color, coefficient, warning) {\n try {\n return emphasize(color, coefficient);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Blend a transparent overlay color with a background color, resulting in a single\n * RGB color.\n * @param {string} background - CSS color\n * @param {string} overlay - CSS color\n * @param {number} opacity - Opacity multiplier in the range 0 - 1\n * @param {number} [gamma=1.0] - Gamma correction factor. For gamma-correct blending, 2.2 is usual.\n */\nexport function blend(background, overlay, opacity, gamma = 1.0) {\n const blendChannel = (b, o) => Math.round((b ** (1 / gamma) * (1 - opacity) + o ** (1 / gamma) * opacity) ** gamma);\n const backgroundColor = decomposeColor(background);\n const overlayColor = decomposeColor(overlay);\n const rgb = [blendChannel(backgroundColor.values[0], overlayColor.values[0]), blendChannel(backgroundColor.values[1], overlayColor.values[1]), blendChannel(backgroundColor.values[2], overlayColor.values[2])];\n return recomposeColor({\n type: 'rgb',\n values: rgb\n });\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nexport default function createMixins(breakpoints, mixins) {\n return _extends({\n toolbar: {\n minHeight: 56,\n [breakpoints.up('xs')]: {\n '@media (orientation: landscape)': {\n minHeight: 48\n }\n },\n [breakpoints.up('sm')]: {\n minHeight: 64\n }\n }\n }, mixins);\n}","const common = {\n black: '#000',\n white: '#fff'\n};\nexport default common;","const grey = {\n 50: '#fafafa',\n 100: '#f5f5f5',\n 200: '#eeeeee',\n 300: '#e0e0e0',\n 400: '#bdbdbd',\n 500: '#9e9e9e',\n 600: '#757575',\n 700: '#616161',\n 800: '#424242',\n 900: '#212121',\n A100: '#f5f5f5',\n A200: '#eeeeee',\n A400: '#bdbdbd',\n A700: '#616161'\n};\nexport default grey;","const purple = {\n 50: '#f3e5f5',\n 100: '#e1bee7',\n 200: '#ce93d8',\n 300: '#ba68c8',\n 400: '#ab47bc',\n 500: '#9c27b0',\n 600: '#8e24aa',\n 700: '#7b1fa2',\n 800: '#6a1b9a',\n 900: '#4a148c',\n A100: '#ea80fc',\n A200: '#e040fb',\n A400: '#d500f9',\n A700: '#aa00ff'\n};\nexport default purple;","const red = {\n 50: '#ffebee',\n 100: '#ffcdd2',\n 200: '#ef9a9a',\n 300: '#e57373',\n 400: '#ef5350',\n 500: '#f44336',\n 600: '#e53935',\n 700: '#d32f2f',\n 800: '#c62828',\n 900: '#b71c1c',\n A100: '#ff8a80',\n A200: '#ff5252',\n A400: '#ff1744',\n A700: '#d50000'\n};\nexport default red;","const orange = {\n 50: '#fff3e0',\n 100: '#ffe0b2',\n 200: '#ffcc80',\n 300: '#ffb74d',\n 400: '#ffa726',\n 500: '#ff9800',\n 600: '#fb8c00',\n 700: '#f57c00',\n 800: '#ef6c00',\n 900: '#e65100',\n A100: '#ffd180',\n A200: '#ffab40',\n A400: '#ff9100',\n A700: '#ff6d00'\n};\nexport default orange;","const blue = {\n 50: '#e3f2fd',\n 100: '#bbdefb',\n 200: '#90caf9',\n 300: '#64b5f6',\n 400: '#42a5f5',\n 500: '#2196f3',\n 600: '#1e88e5',\n 700: '#1976d2',\n 800: '#1565c0',\n 900: '#0d47a1',\n A100: '#82b1ff',\n A200: '#448aff',\n A400: '#2979ff',\n A700: '#2962ff'\n};\nexport default blue;","const lightBlue = {\n 50: '#e1f5fe',\n 100: '#b3e5fc',\n 200: '#81d4fa',\n 300: '#4fc3f7',\n 400: '#29b6f6',\n 500: '#03a9f4',\n 600: '#039be5',\n 700: '#0288d1',\n 800: '#0277bd',\n 900: '#01579b',\n A100: '#80d8ff',\n A200: '#40c4ff',\n A400: '#00b0ff',\n A700: '#0091ea'\n};\nexport default lightBlue;","const green = {\n 50: '#e8f5e9',\n 100: '#c8e6c9',\n 200: '#a5d6a7',\n 300: '#81c784',\n 400: '#66bb6a',\n 500: '#4caf50',\n 600: '#43a047',\n 700: '#388e3c',\n 800: '#2e7d32',\n 900: '#1b5e20',\n A100: '#b9f6ca',\n A200: '#69f0ae',\n A400: '#00e676',\n A700: '#00c853'\n};\nexport default green;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\nconst _excluded = [\"mode\", \"contrastThreshold\", \"tonalOffset\"];\nimport { deepmerge } from '@mui/utils';\nimport { darken, getContrastRatio, lighten } from '@mui/system';\nimport common from '../colors/common';\nimport grey from '../colors/grey';\nimport purple from '../colors/purple';\nimport red from '../colors/red';\nimport orange from '../colors/orange';\nimport blue from '../colors/blue';\nimport lightBlue from '../colors/lightBlue';\nimport green from '../colors/green';\nexport const light = {\n // The colors used to style the text.\n text: {\n // The most important text.\n primary: 'rgba(0, 0, 0, 0.87)',\n // Secondary text.\n secondary: 'rgba(0, 0, 0, 0.6)',\n // Disabled text have even lower visual prominence.\n disabled: 'rgba(0, 0, 0, 0.38)'\n },\n // The color used to divide different elements.\n divider: 'rgba(0, 0, 0, 0.12)',\n // The background colors used to style the surfaces.\n // Consistency between these values is important.\n background: {\n paper: common.white,\n default: common.white\n },\n // The colors used to style the action elements.\n action: {\n // The color of an active action like an icon button.\n active: 'rgba(0, 0, 0, 0.54)',\n // The color of an hovered action.\n hover: 'rgba(0, 0, 0, 0.04)',\n hoverOpacity: 0.04,\n // The color of a selected action.\n selected: 'rgba(0, 0, 0, 0.08)',\n selectedOpacity: 0.08,\n // The color of a disabled action.\n disabled: 'rgba(0, 0, 0, 0.26)',\n // The background color of a disabled action.\n disabledBackground: 'rgba(0, 0, 0, 0.12)',\n disabledOpacity: 0.38,\n focus: 'rgba(0, 0, 0, 0.12)',\n focusOpacity: 0.12,\n activatedOpacity: 0.12\n }\n};\nexport const dark = {\n text: {\n primary: common.white,\n secondary: 'rgba(255, 255, 255, 0.7)',\n disabled: 'rgba(255, 255, 255, 0.5)',\n icon: 'rgba(255, 255, 255, 0.5)'\n },\n divider: 'rgba(255, 255, 255, 0.12)',\n background: {\n paper: '#121212',\n default: '#121212'\n },\n action: {\n active: common.white,\n hover: 'rgba(255, 255, 255, 0.08)',\n hoverOpacity: 0.08,\n selected: 'rgba(255, 255, 255, 0.16)',\n selectedOpacity: 0.16,\n disabled: 'rgba(255, 255, 255, 0.3)',\n disabledBackground: 'rgba(255, 255, 255, 0.12)',\n disabledOpacity: 0.38,\n focus: 'rgba(255, 255, 255, 0.12)',\n focusOpacity: 0.12,\n activatedOpacity: 0.24\n }\n};\nfunction addLightOrDark(intent, direction, shade, tonalOffset) {\n const tonalOffsetLight = tonalOffset.light || tonalOffset;\n const tonalOffsetDark = tonalOffset.dark || tonalOffset * 1.5;\n if (!intent[direction]) {\n if (intent.hasOwnProperty(shade)) {\n intent[direction] = intent[shade];\n } else if (direction === 'light') {\n intent.light = lighten(intent.main, tonalOffsetLight);\n } else if (direction === 'dark') {\n intent.dark = darken(intent.main, tonalOffsetDark);\n }\n }\n}\nfunction getDefaultPrimary(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: blue[200],\n light: blue[50],\n dark: blue[400]\n };\n }\n return {\n main: blue[700],\n light: blue[400],\n dark: blue[800]\n };\n}\nfunction getDefaultSecondary(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: purple[200],\n light: purple[50],\n dark: purple[400]\n };\n }\n return {\n main: purple[500],\n light: purple[300],\n dark: purple[700]\n };\n}\nfunction getDefaultError(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: red[500],\n light: red[300],\n dark: red[700]\n };\n }\n return {\n main: red[700],\n light: red[400],\n dark: red[800]\n };\n}\nfunction getDefaultInfo(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: lightBlue[400],\n light: lightBlue[300],\n dark: lightBlue[700]\n };\n }\n return {\n main: lightBlue[700],\n light: lightBlue[500],\n dark: lightBlue[900]\n };\n}\nfunction getDefaultSuccess(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: green[400],\n light: green[300],\n dark: green[700]\n };\n }\n return {\n main: green[800],\n light: green[500],\n dark: green[900]\n };\n}\nfunction getDefaultWarning(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: orange[400],\n light: orange[300],\n dark: orange[700]\n };\n }\n return {\n main: '#ed6c02',\n // closest to orange[800] that pass 3:1.\n light: orange[500],\n dark: orange[900]\n };\n}\nexport default function createPalette(palette) {\n const {\n mode = 'light',\n contrastThreshold = 3,\n tonalOffset = 0.2\n } = palette,\n other = _objectWithoutPropertiesLoose(palette, _excluded);\n const primary = palette.primary || getDefaultPrimary(mode);\n const secondary = palette.secondary || getDefaultSecondary(mode);\n const error = palette.error || getDefaultError(mode);\n const info = palette.info || getDefaultInfo(mode);\n const success = palette.success || getDefaultSuccess(mode);\n const warning = palette.warning || getDefaultWarning(mode);\n\n // Use the same logic as\n // Bootstrap: https://github.com/twbs/bootstrap/blob/1d6e3710dd447de1a200f29e8fa521f8a0908f70/scss/_functions.scss#L59\n // and material-components-web https://github.com/material-components/material-components-web/blob/ac46b8863c4dab9fc22c4c662dc6bd1b65dd652f/packages/mdc-theme/_functions.scss#L54\n function getContrastText(background) {\n const contrastText = getContrastRatio(background, dark.text.primary) >= contrastThreshold ? dark.text.primary : light.text.primary;\n if (process.env.NODE_ENV !== 'production') {\n const contrast = getContrastRatio(background, contrastText);\n if (contrast < 3) {\n console.error([`MUI: The contrast ratio of ${contrast}:1 for ${contrastText} on ${background}`, 'falls below the WCAG recommended absolute minimum contrast ratio of 3:1.', 'https://www.w3.org/TR/2008/REC-WCAG20-20081211/#visual-audio-contrast-contrast'].join('\\n'));\n }\n }\n return contrastText;\n }\n const augmentColor = ({\n color,\n name,\n mainShade = 500,\n lightShade = 300,\n darkShade = 700\n }) => {\n color = _extends({}, color);\n if (!color.main && color[mainShade]) {\n color.main = color[mainShade];\n }\n if (!color.hasOwnProperty('main')) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: The color${name ? ` (${name})` : ''} provided to augmentColor(color) is invalid.\nThe color object needs to have a \\`main\\` property or a \\`${mainShade}\\` property.` : _formatMuiErrorMessage(11, name ? ` (${name})` : '', mainShade));\n }\n if (typeof color.main !== 'string') {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: The color${name ? ` (${name})` : ''} provided to augmentColor(color) is invalid.\n\\`color.main\\` should be a string, but \\`${JSON.stringify(color.main)}\\` was provided instead.\n\nDid you intend to use one of the following approaches?\n\nimport { green } from \"@mui/material/colors\";\n\nconst theme1 = createTheme({ palette: {\n primary: green,\n} });\n\nconst theme2 = createTheme({ palette: {\n primary: { main: green[500] },\n} });` : _formatMuiErrorMessage(12, name ? ` (${name})` : '', JSON.stringify(color.main)));\n }\n addLightOrDark(color, 'light', lightShade, tonalOffset);\n addLightOrDark(color, 'dark', darkShade, tonalOffset);\n if (!color.contrastText) {\n color.contrastText = getContrastText(color.main);\n }\n return color;\n };\n const modes = {\n dark,\n light\n };\n if (process.env.NODE_ENV !== 'production') {\n if (!modes[mode]) {\n console.error(`MUI: The palette mode \\`${mode}\\` is not supported.`);\n }\n }\n const paletteOutput = deepmerge(_extends({\n // A collection of common colors.\n common: _extends({}, common),\n // prevent mutable object.\n // The palette mode, can be light or dark.\n mode,\n // The colors used to represent primary interface elements for a user.\n primary: augmentColor({\n color: primary,\n name: 'primary'\n }),\n // The colors used to represent secondary interface elements for a user.\n secondary: augmentColor({\n color: secondary,\n name: 'secondary',\n mainShade: 'A400',\n lightShade: 'A200',\n darkShade: 'A700'\n }),\n // The colors used to represent interface elements that the user should be made aware of.\n error: augmentColor({\n color: error,\n name: 'error'\n }),\n // The colors used to represent potentially dangerous actions or important messages.\n warning: augmentColor({\n color: warning,\n name: 'warning'\n }),\n // The colors used to present information to the user that is neutral and not necessarily important.\n info: augmentColor({\n color: info,\n name: 'info'\n }),\n // The colors used to indicate the successful completion of an action that user triggered.\n success: augmentColor({\n color: success,\n name: 'success'\n }),\n // The grey colors.\n grey,\n // Used by `getContrastText()` to maximize the contrast between\n // the background and the text.\n contrastThreshold,\n // Takes a background color and returns the text color that maximizes the contrast.\n getContrastText,\n // Generate a rich color object.\n augmentColor,\n // Used by the functions below to shift a color's luminance by approximately\n // two indexes within its tonal palette.\n // E.g., shift from Red 500 to Red 300 or Red 700.\n tonalOffset\n }, modes[mode]), other);\n return paletteOutput;\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"fontFamily\", \"fontSize\", \"fontWeightLight\", \"fontWeightRegular\", \"fontWeightMedium\", \"fontWeightBold\", \"htmlFontSize\", \"allVariants\", \"pxToRem\"];\nimport { deepmerge } from '@mui/utils';\nfunction round(value) {\n return Math.round(value * 1e5) / 1e5;\n}\nconst caseAllCaps = {\n textTransform: 'uppercase'\n};\nconst defaultFontFamily = '\"Roboto\", \"Helvetica\", \"Arial\", sans-serif';\n\n/**\n * @see @link{https://m2.material.io/design/typography/the-type-system.html}\n * @see @link{https://m2.material.io/design/typography/understanding-typography.html}\n */\nexport default function createTypography(palette, typography) {\n const _ref = typeof typography === 'function' ? typography(palette) : typography,\n {\n fontFamily = defaultFontFamily,\n // The default font size of the Material Specification.\n fontSize = 14,\n // px\n fontWeightLight = 300,\n fontWeightRegular = 400,\n fontWeightMedium = 500,\n fontWeightBold = 700,\n // Tell MUI what's the font-size on the html element.\n // 16px is the default font-size used by browsers.\n htmlFontSize = 16,\n // Apply the CSS properties to all the variants.\n allVariants,\n pxToRem: pxToRem2\n } = _ref,\n other = _objectWithoutPropertiesLoose(_ref, _excluded);\n if (process.env.NODE_ENV !== 'production') {\n if (typeof fontSize !== 'number') {\n console.error('MUI: `fontSize` is required to be a number.');\n }\n if (typeof htmlFontSize !== 'number') {\n console.error('MUI: `htmlFontSize` is required to be a number.');\n }\n }\n const coef = fontSize / 14;\n const pxToRem = pxToRem2 || (size => `${size / htmlFontSize * coef}rem`);\n const buildVariant = (fontWeight, size, lineHeight, letterSpacing, casing) => _extends({\n fontFamily,\n fontWeight,\n fontSize: pxToRem(size),\n // Unitless following https://meyerweb.com/eric/thoughts/2006/02/08/unitless-line-heights/\n lineHeight\n }, fontFamily === defaultFontFamily ? {\n letterSpacing: `${round(letterSpacing / size)}em`\n } : {}, casing, allVariants);\n const variants = {\n h1: buildVariant(fontWeightLight, 96, 1.167, -1.5),\n h2: buildVariant(fontWeightLight, 60, 1.2, -0.5),\n h3: buildVariant(fontWeightRegular, 48, 1.167, 0),\n h4: buildVariant(fontWeightRegular, 34, 1.235, 0.25),\n h5: buildVariant(fontWeightRegular, 24, 1.334, 0),\n h6: buildVariant(fontWeightMedium, 20, 1.6, 0.15),\n subtitle1: buildVariant(fontWeightRegular, 16, 1.75, 0.15),\n subtitle2: buildVariant(fontWeightMedium, 14, 1.57, 0.1),\n body1: buildVariant(fontWeightRegular, 16, 1.5, 0.15),\n body2: buildVariant(fontWeightRegular, 14, 1.43, 0.15),\n button: buildVariant(fontWeightMedium, 14, 1.75, 0.4, caseAllCaps),\n caption: buildVariant(fontWeightRegular, 12, 1.66, 0.4),\n overline: buildVariant(fontWeightRegular, 12, 2.66, 1, caseAllCaps),\n // TODO v6: Remove handling of 'inherit' variant from the theme as it is already handled in Material UI's Typography component. Also, remember to remove the associated types.\n inherit: {\n fontFamily: 'inherit',\n fontWeight: 'inherit',\n fontSize: 'inherit',\n lineHeight: 'inherit',\n letterSpacing: 'inherit'\n }\n };\n return deepmerge(_extends({\n htmlFontSize,\n pxToRem,\n fontFamily,\n fontSize,\n fontWeightLight,\n fontWeightRegular,\n fontWeightMedium,\n fontWeightBold\n }, variants), other, {\n clone: false // No need to clone deep\n });\n}","const shadowKeyUmbraOpacity = 0.2;\nconst shadowKeyPenumbraOpacity = 0.14;\nconst shadowAmbientShadowOpacity = 0.12;\nfunction createShadow(...px) {\n return [`${px[0]}px ${px[1]}px ${px[2]}px ${px[3]}px rgba(0,0,0,${shadowKeyUmbraOpacity})`, `${px[4]}px ${px[5]}px ${px[6]}px ${px[7]}px rgba(0,0,0,${shadowKeyPenumbraOpacity})`, `${px[8]}px ${px[9]}px ${px[10]}px ${px[11]}px rgba(0,0,0,${shadowAmbientShadowOpacity})`].join(',');\n}\n\n// Values from https://github.com/material-components/material-components-web/blob/be8747f94574669cb5e7add1a7c54fa41a89cec7/packages/mdc-elevation/_variables.scss\nconst shadows = ['none', createShadow(0, 2, 1, -1, 0, 1, 1, 0, 0, 1, 3, 0), createShadow(0, 3, 1, -2, 0, 2, 2, 0, 0, 1, 5, 0), createShadow(0, 3, 3, -2, 0, 3, 4, 0, 0, 1, 8, 0), createShadow(0, 2, 4, -1, 0, 4, 5, 0, 0, 1, 10, 0), createShadow(0, 3, 5, -1, 0, 5, 8, 0, 0, 1, 14, 0), createShadow(0, 3, 5, -1, 0, 6, 10, 0, 0, 1, 18, 0), createShadow(0, 4, 5, -2, 0, 7, 10, 1, 0, 2, 16, 1), createShadow(0, 5, 5, -3, 0, 8, 10, 1, 0, 3, 14, 2), createShadow(0, 5, 6, -3, 0, 9, 12, 1, 0, 3, 16, 2), createShadow(0, 6, 6, -3, 0, 10, 14, 1, 0, 4, 18, 3), createShadow(0, 6, 7, -4, 0, 11, 15, 1, 0, 4, 20, 3), createShadow(0, 7, 8, -4, 0, 12, 17, 2, 0, 5, 22, 4), createShadow(0, 7, 8, -4, 0, 13, 19, 2, 0, 5, 24, 4), createShadow(0, 7, 9, -4, 0, 14, 21, 2, 0, 5, 26, 4), createShadow(0, 8, 9, -5, 0, 15, 22, 2, 0, 6, 28, 5), createShadow(0, 8, 10, -5, 0, 16, 24, 2, 0, 6, 30, 5), createShadow(0, 8, 11, -5, 0, 17, 26, 2, 0, 6, 32, 5), createShadow(0, 9, 11, -5, 0, 18, 28, 2, 0, 7, 34, 6), createShadow(0, 9, 12, -6, 0, 19, 29, 2, 0, 7, 36, 6), createShadow(0, 10, 13, -6, 0, 20, 31, 3, 0, 8, 38, 7), createShadow(0, 10, 13, -6, 0, 21, 33, 3, 0, 8, 40, 7), createShadow(0, 10, 14, -6, 0, 22, 35, 3, 0, 8, 42, 7), createShadow(0, 11, 14, -7, 0, 23, 36, 3, 0, 9, 44, 8), createShadow(0, 11, 15, -7, 0, 24, 38, 3, 0, 9, 46, 8)];\nexport default shadows;","import _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nconst _excluded = [\"duration\", \"easing\", \"delay\"];\n// Follow https://material.google.com/motion/duration-easing.html#duration-easing-natural-easing-curves\n// to learn the context in which each easing should be used.\nexport const easing = {\n // This is the most common easing curve.\n easeInOut: 'cubic-bezier(0.4, 0, 0.2, 1)',\n // Objects enter the screen at full velocity from off-screen and\n // slowly decelerate to a resting point.\n easeOut: 'cubic-bezier(0.0, 0, 0.2, 1)',\n // Objects leave the screen at full velocity. They do not decelerate when off-screen.\n easeIn: 'cubic-bezier(0.4, 0, 1, 1)',\n // The sharp curve is used by objects that may return to the screen at any time.\n sharp: 'cubic-bezier(0.4, 0, 0.6, 1)'\n};\n\n// Follow https://m2.material.io/guidelines/motion/duration-easing.html#duration-easing-common-durations\n// to learn when use what timing\nexport const duration = {\n shortest: 150,\n shorter: 200,\n short: 250,\n // most basic recommended timing\n standard: 300,\n // this is to be used in complex animations\n complex: 375,\n // recommended when something is entering screen\n enteringScreen: 225,\n // recommended when something is leaving screen\n leavingScreen: 195\n};\nfunction formatMs(milliseconds) {\n return `${Math.round(milliseconds)}ms`;\n}\nfunction getAutoHeightDuration(height) {\n if (!height) {\n return 0;\n }\n const constant = height / 36;\n\n // https://www.wolframalpha.com/input/?i=(4+%2B+15+*+(x+%2F+36+)+**+0.25+%2B+(x+%2F+36)+%2F+5)+*+10\n return Math.round((4 + 15 * constant ** 0.25 + constant / 5) * 10);\n}\nexport default function createTransitions(inputTransitions) {\n const mergedEasing = _extends({}, easing, inputTransitions.easing);\n const mergedDuration = _extends({}, duration, inputTransitions.duration);\n const create = (props = ['all'], options = {}) => {\n const {\n duration: durationOption = mergedDuration.standard,\n easing: easingOption = mergedEasing.easeInOut,\n delay = 0\n } = options,\n other = _objectWithoutPropertiesLoose(options, _excluded);\n if (process.env.NODE_ENV !== 'production') {\n const isString = value => typeof value === 'string';\n // IE11 support, replace with Number.isNaN\n // eslint-disable-next-line no-restricted-globals\n const isNumber = value => !isNaN(parseFloat(value));\n if (!isString(props) && !Array.isArray(props)) {\n console.error('MUI: Argument \"props\" must be a string or Array.');\n }\n if (!isNumber(durationOption) && !isString(durationOption)) {\n console.error(`MUI: Argument \"duration\" must be a number or a string but found ${durationOption}.`);\n }\n if (!isString(easingOption)) {\n console.error('MUI: Argument \"easing\" must be a string.');\n }\n if (!isNumber(delay) && !isString(delay)) {\n console.error('MUI: Argument \"delay\" must be a number or a string.');\n }\n if (typeof options !== 'object') {\n console.error(['MUI: Secong argument of transition.create must be an object.', \"Arguments should be either `create('prop1', options)` or `create(['prop1', 'prop2'], options)`\"].join('\\n'));\n }\n if (Object.keys(other).length !== 0) {\n console.error(`MUI: Unrecognized argument(s) [${Object.keys(other).join(',')}].`);\n }\n }\n return (Array.isArray(props) ? props : [props]).map(animatedProp => `${animatedProp} ${typeof durationOption === 'string' ? durationOption : formatMs(durationOption)} ${easingOption} ${typeof delay === 'string' ? delay : formatMs(delay)}`).join(',');\n };\n return _extends({\n getAutoHeightDuration,\n create\n }, inputTransitions, {\n easing: mergedEasing,\n duration: mergedDuration\n });\n}","// We need to centralize the zIndex definitions as they work\n// like global values in the browser.\nconst zIndex = {\n mobileStepper: 1000,\n fab: 1050,\n speedDial: 1050,\n appBar: 1100,\n drawer: 1200,\n modal: 1300,\n snackbar: 1400,\n tooltip: 1500\n};\nexport default zIndex;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\nconst _excluded = [\"breakpoints\", \"mixins\", \"spacing\", \"palette\", \"transitions\", \"typography\", \"shape\"];\nimport { deepmerge } from '@mui/utils';\nimport { createTheme as systemCreateTheme, unstable_defaultSxConfig as defaultSxConfig, unstable_styleFunctionSx as styleFunctionSx } from '@mui/system';\nimport generateUtilityClass from '@mui/utils/generateUtilityClass';\nimport createMixins from './createMixins';\nimport createPalette from './createPalette';\nimport createTypography from './createTypography';\nimport shadows from './shadows';\nimport createTransitions from './createTransitions';\nimport zIndex from './zIndex';\nfunction createTheme(options = {}, ...args) {\n const {\n mixins: mixinsInput = {},\n palette: paletteInput = {},\n transitions: transitionsInput = {},\n typography: typographyInput = {}\n } = options,\n other = _objectWithoutPropertiesLoose(options, _excluded);\n if (options.vars) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: \\`vars\\` is a private field used for CSS variables support.\nPlease use another name.` : _formatMuiErrorMessage(18));\n }\n const palette = createPalette(paletteInput);\n const systemTheme = systemCreateTheme(options);\n let muiTheme = deepmerge(systemTheme, {\n mixins: createMixins(systemTheme.breakpoints, mixinsInput),\n palette,\n // Don't use [...shadows] until you've verified its transpiled code is not invoking the iterator protocol.\n shadows: shadows.slice(),\n typography: createTypography(palette, typographyInput),\n transitions: createTransitions(transitionsInput),\n zIndex: _extends({}, zIndex)\n });\n muiTheme = deepmerge(muiTheme, other);\n muiTheme = args.reduce((acc, argument) => deepmerge(acc, argument), muiTheme);\n if (process.env.NODE_ENV !== 'production') {\n // TODO v6: Refactor to use globalStateClassesMapping from @mui/utils once `readOnly` state class is used in Rating component.\n const stateClasses = ['active', 'checked', 'completed', 'disabled', 'error', 'expanded', 'focused', 'focusVisible', 'required', 'selected'];\n const traverse = (node, component) => {\n let key;\n\n // eslint-disable-next-line guard-for-in, no-restricted-syntax\n for (key in node) {\n const child = node[key];\n if (stateClasses.indexOf(key) !== -1 && Object.keys(child).length > 0) {\n if (process.env.NODE_ENV !== 'production') {\n const stateClass = generateUtilityClass('', key);\n console.error([`MUI: The \\`${component}\\` component increases ` + `the CSS specificity of the \\`${key}\\` internal state.`, 'You can not override it like this: ', JSON.stringify(node, null, 2), '', `Instead, you need to use the '&.${stateClass}' syntax:`, JSON.stringify({\n root: {\n [`&.${stateClass}`]: child\n }\n }, null, 2), '', 'https://mui.com/r/state-classes-guide'].join('\\n'));\n }\n // Remove the style to prevent global conflicts.\n node[key] = {};\n }\n }\n };\n Object.keys(muiTheme.components).forEach(component => {\n const styleOverrides = muiTheme.components[component].styleOverrides;\n if (styleOverrides && component.indexOf('Mui') === 0) {\n traverse(styleOverrides, component);\n }\n });\n }\n muiTheme.unstable_sxConfig = _extends({}, defaultSxConfig, other == null ? void 0 : other.unstable_sxConfig);\n muiTheme.unstable_sx = function sx(props) {\n return styleFunctionSx({\n sx: props,\n theme: this\n });\n };\n return muiTheme;\n}\nlet warnedOnce = false;\nexport function createMuiTheme(...args) {\n if (process.env.NODE_ENV !== 'production') {\n if (!warnedOnce) {\n warnedOnce = true;\n console.error(['MUI: the createMuiTheme function was renamed to createTheme.', '', \"You should use `import { createTheme } from '@mui/material/styles'`\"].join('\\n'));\n }\n }\n return createTheme(...args);\n}\nexport default createTheme;","'use client';\n\nimport createTheme from './createTheme';\nconst defaultTheme = createTheme();\nexport default defaultTheme;","export default '$$material';","'use client';\n\nimport { useThemeProps as systemUseThemeProps } from '@mui/system';\nimport defaultTheme from './defaultTheme';\nimport THEME_ID from './identifier';\nexport default function useThemeProps({\n props,\n name\n}) {\n return systemUseThemeProps({\n props,\n name,\n defaultTheme,\n themeId: THEME_ID\n });\n}","'use client';\n\nimport { createStyled, shouldForwardProp } from '@mui/system';\nimport defaultTheme from './defaultTheme';\nimport THEME_ID from './identifier';\nexport const rootShouldForwardProp = prop => shouldForwardProp(prop) && prop !== 'classes';\nexport const slotShouldForwardProp = shouldForwardProp;\nconst styled = createStyled({\n themeId: THEME_ID,\n defaultTheme,\n rootShouldForwardProp\n});\nexport default styled;","import generateUtilityClasses from '@mui/utils/generateUtilityClasses';\nimport generateUtilityClass from '@mui/utils/generateUtilityClass';\nexport function getSvgIconUtilityClass(slot) {\n return generateUtilityClass('MuiSvgIcon', slot);\n}\nconst svgIconClasses = generateUtilityClasses('MuiSvgIcon', ['root', 'colorPrimary', 'colorSecondary', 'colorAction', 'colorError', 'colorDisabled', 'fontSizeInherit', 'fontSizeSmall', 'fontSizeMedium', 'fontSizeLarge']);\nexport default svgIconClasses;","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"children\", \"className\", \"color\", \"component\", \"fontSize\", \"htmlColor\", \"inheritViewBox\", \"titleAccess\", \"viewBox\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport clsx from 'clsx';\nimport { unstable_composeClasses as composeClasses } from '@mui/base/composeClasses';\nimport capitalize from '../utils/capitalize';\nimport useThemeProps from '../styles/useThemeProps';\nimport styled from '../styles/styled';\nimport { getSvgIconUtilityClass } from './svgIconClasses';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nimport { jsxs as _jsxs } from \"react/jsx-runtime\";\nconst useUtilityClasses = ownerState => {\n const {\n color,\n fontSize,\n classes\n } = ownerState;\n const slots = {\n root: ['root', color !== 'inherit' && `color${capitalize(color)}`, `fontSize${capitalize(fontSize)}`]\n };\n return composeClasses(slots, getSvgIconUtilityClass, classes);\n};\nconst SvgIconRoot = styled('svg', {\n name: 'MuiSvgIcon',\n slot: 'Root',\n overridesResolver: (props, styles) => {\n const {\n ownerState\n } = props;\n return [styles.root, ownerState.color !== 'inherit' && styles[`color${capitalize(ownerState.color)}`], styles[`fontSize${capitalize(ownerState.fontSize)}`]];\n }\n})(({\n theme,\n ownerState\n}) => {\n var _theme$transitions, _theme$transitions$cr, _theme$transitions2, _theme$typography, _theme$typography$pxT, _theme$typography2, _theme$typography2$px, _theme$typography3, _theme$typography3$px, _palette$ownerState$c, _palette, _palette2, _palette3;\n return {\n userSelect: 'none',\n width: '1em',\n height: '1em',\n display: 'inline-block',\n // the will define the property that has `currentColor`\n // e.g. heroicons uses fill=\"none\" and stroke=\"currentColor\"\n fill: ownerState.hasSvgAsChild ? undefined : 'currentColor',\n flexShrink: 0,\n transition: (_theme$transitions = theme.transitions) == null || (_theme$transitions$cr = _theme$transitions.create) == null ? void 0 : _theme$transitions$cr.call(_theme$transitions, 'fill', {\n duration: (_theme$transitions2 = theme.transitions) == null || (_theme$transitions2 = _theme$transitions2.duration) == null ? void 0 : _theme$transitions2.shorter\n }),\n fontSize: {\n inherit: 'inherit',\n small: ((_theme$typography = theme.typography) == null || (_theme$typography$pxT = _theme$typography.pxToRem) == null ? void 0 : _theme$typography$pxT.call(_theme$typography, 20)) || '1.25rem',\n medium: ((_theme$typography2 = theme.typography) == null || (_theme$typography2$px = _theme$typography2.pxToRem) == null ? void 0 : _theme$typography2$px.call(_theme$typography2, 24)) || '1.5rem',\n large: ((_theme$typography3 = theme.typography) == null || (_theme$typography3$px = _theme$typography3.pxToRem) == null ? void 0 : _theme$typography3$px.call(_theme$typography3, 35)) || '2.1875rem'\n }[ownerState.fontSize],\n // TODO v5 deprecate, v6 remove for sx\n color: (_palette$ownerState$c = (_palette = (theme.vars || theme).palette) == null || (_palette = _palette[ownerState.color]) == null ? void 0 : _palette.main) != null ? _palette$ownerState$c : {\n action: (_palette2 = (theme.vars || theme).palette) == null || (_palette2 = _palette2.action) == null ? void 0 : _palette2.active,\n disabled: (_palette3 = (theme.vars || theme).palette) == null || (_palette3 = _palette3.action) == null ? void 0 : _palette3.disabled,\n inherit: undefined\n }[ownerState.color]\n };\n});\nconst SvgIcon = /*#__PURE__*/React.forwardRef(function SvgIcon(inProps, ref) {\n const props = useThemeProps({\n props: inProps,\n name: 'MuiSvgIcon'\n });\n const {\n children,\n className,\n color = 'inherit',\n component = 'svg',\n fontSize = 'medium',\n htmlColor,\n inheritViewBox = false,\n titleAccess,\n viewBox = '0 0 24 24'\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const hasSvgAsChild = /*#__PURE__*/React.isValidElement(children) && children.type === 'svg';\n const ownerState = _extends({}, props, {\n color,\n component,\n fontSize,\n instanceFontSize: inProps.fontSize,\n inheritViewBox,\n viewBox,\n hasSvgAsChild\n });\n const more = {};\n if (!inheritViewBox) {\n more.viewBox = viewBox;\n }\n const classes = useUtilityClasses(ownerState);\n return /*#__PURE__*/_jsxs(SvgIconRoot, _extends({\n as: component,\n className: clsx(classes.root, className),\n focusable: \"false\",\n color: htmlColor,\n \"aria-hidden\": titleAccess ? undefined : true,\n role: titleAccess ? 'img' : undefined,\n ref: ref\n }, more, other, hasSvgAsChild && children.props, {\n ownerState: ownerState,\n children: [hasSvgAsChild ? children.props.children : children, titleAccess ? /*#__PURE__*/_jsx(\"title\", {\n children: titleAccess\n }) : null]\n }));\n});\nprocess.env.NODE_ENV !== \"production\" ? SvgIcon.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the d.ts file and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * Node passed into the SVG element.\n */\n children: PropTypes.node,\n /**\n * Override or extend the styles applied to the component.\n */\n classes: PropTypes.object,\n /**\n * @ignore\n */\n className: PropTypes.string,\n /**\n * The color of the component.\n * It supports both default and custom theme colors, which can be added as shown in the\n * [palette customization guide](https://mui.com/material-ui/customization/palette/#custom-colors).\n * You can use the `htmlColor` prop to apply a color attribute to the SVG element.\n * @default 'inherit'\n */\n color: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.oneOf(['inherit', 'action', 'disabled', 'primary', 'secondary', 'error', 'info', 'success', 'warning']), PropTypes.string]),\n /**\n * The component used for the root node.\n * Either a string to use a HTML element or a component.\n */\n component: PropTypes.elementType,\n /**\n * The fontSize applied to the icon. Defaults to 24px, but can be configure to inherit font size.\n * @default 'medium'\n */\n fontSize: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.oneOf(['inherit', 'large', 'medium', 'small']), PropTypes.string]),\n /**\n * Applies a color attribute to the SVG element.\n */\n htmlColor: PropTypes.string,\n /**\n * If `true`, the root node will inherit the custom `component`'s viewBox and the `viewBox`\n * prop will be ignored.\n * Useful when you want to reference a custom `component` and have `SvgIcon` pass that\n * `component`'s viewBox to the root node.\n * @default false\n */\n inheritViewBox: PropTypes.bool,\n /**\n * The shape-rendering attribute. The behavior of the different options is described on the\n * [MDN Web Docs](https://developer.mozilla.org/en-US/docs/Web/SVG/Attribute/shape-rendering).\n * If you are having issues with blurry icons you should investigate this prop.\n */\n shapeRendering: PropTypes.string,\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Provides a human-readable title for the element that contains it.\n * https://www.w3.org/TR/SVG-access/#Equivalent\n */\n titleAccess: PropTypes.string,\n /**\n * Allows you to redefine what the coordinates without units mean inside an SVG element.\n * For example, if the SVG element is 500 (width) by 200 (height),\n * and you pass viewBox=\"0 0 50 20\",\n * this means that the coordinates inside the SVG will go from the top left corner (0,0)\n * to bottom right (50,20) and each unit will be worth 10px.\n * @default '0 0 24 24'\n */\n viewBox: PropTypes.string\n} : void 0;\nSvgIcon.muiName = 'SvgIcon';\nexport default SvgIcon;","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport * as React from 'react';\nimport SvgIcon from '../SvgIcon';\n\n/**\n * Private module reserved for @mui packages.\n */\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nexport default function createSvgIcon(path, displayName) {\n function Component(props, ref) {\n return /*#__PURE__*/_jsx(SvgIcon, _extends({\n \"data-testid\": `${displayName}Icon`,\n ref: ref\n }, props, {\n children: path\n }));\n }\n if (process.env.NODE_ENV !== 'production') {\n // Need to set `displayName` on the inner component for React.memo.\n // React prior to 16.14 ignores `displayName` on the wrapper.\n Component.displayName = `${displayName}Icon`;\n }\n Component.muiName = SvgIcon.muiName;\n return /*#__PURE__*/React.memo( /*#__PURE__*/React.forwardRef(Component));\n}","'use client';\n\nimport { unstable_ClassNameGenerator as ClassNameGenerator } from '@mui/base/ClassNameGenerator';\nexport { default as capitalize } from './capitalize';\nexport { default as createChainedFunction } from './createChainedFunction';\nexport { default as createSvgIcon } from './createSvgIcon';\nexport { default as debounce } from './debounce';\nexport { default as deprecatedPropType } from './deprecatedPropType';\nexport { default as isMuiElement } from './isMuiElement';\nexport { default as ownerDocument } from './ownerDocument';\nexport { default as ownerWindow } from './ownerWindow';\nexport { default as requirePropFactory } from './requirePropFactory';\nexport { default as setRef } from './setRef';\nexport { default as unstable_useEnhancedEffect } from './useEnhancedEffect';\nexport { default as unstable_useId } from './useId';\nexport { default as unsupportedProp } from './unsupportedProp';\nexport { default as useControlled } from './useControlled';\nexport { default as useEventCallback } from './useEventCallback';\nexport { default as useForkRef } from './useForkRef';\nexport { default as useIsFocusVisible } from './useIsFocusVisible';\n// TODO: remove this export once ClassNameGenerator is stable\n// eslint-disable-next-line @typescript-eslint/naming-convention\nexport const unstable_ClassNameGenerator = {\n configure: generator => {\n if (process.env.NODE_ENV !== 'production') {\n console.warn(['MUI: `ClassNameGenerator` import from `@mui/material/utils` is outdated and might cause unexpected issues.', '', \"You should use `import { unstable_ClassNameGenerator } from '@mui/material/className'` instead\", '', 'The detail of the issue: https://github.com/mui/material-ui/issues/30011#issuecomment-1024993401', '', 'The updated documentation: https://mui.com/guides/classname-generator/'].join('\\n'));\n }\n ClassNameGenerator.configure(generator);\n }\n};","\"use strict\";\n'use client';\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nObject.defineProperty(exports, \"default\", {\n enumerable: true,\n get: function () {\n return _utils.createSvgIcon;\n }\n});\nvar _utils = require(\"@mui/material/utils\");","\"use strict\";\n\"use client\";\n\nvar _interopRequireDefault = require(\"@babel/runtime/helpers/interopRequireDefault\");\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = void 0;\nvar _createSvgIcon = _interopRequireDefault(require(\"./utils/createSvgIcon\"));\nvar _jsxRuntime = require(\"react/jsx-runtime\");\nvar _default = exports.default = (0, _createSvgIcon.default)( /*#__PURE__*/(0, _jsxRuntime.jsx)(\"path\", {\n d: \"m10 17 5-5-5-5z\"\n}), 'ArrowRight');","/**\n * Determines if a given element is a DOM element name (i.e. not a React component).\n */\nexport function isHostComponent(element) {\n return typeof element === 'string';\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport { isHostComponent } from './isHostComponent';\n\n/**\n * Type of the ownerState based on the type of an element it applies to.\n * This resolves to the provided OwnerState for React components and `undefined` for host components.\n * Falls back to `OwnerState | undefined` when the exact type can't be determined in development time.\n */\n\n/**\n * Appends the ownerState object to the props, merging with the existing one if necessary.\n *\n * @param elementType Type of the element that owns the `existingProps`. If the element is a DOM node or undefined, `ownerState` is not applied.\n * @param otherProps Props of the element.\n * @param ownerState\n */\nexport function appendOwnerState(elementType, otherProps, ownerState) {\n if (elementType === undefined || isHostComponent(elementType)) {\n return otherProps;\n }\n return _extends({}, otherProps, {\n ownerState: _extends({}, otherProps.ownerState, ownerState)\n });\n}","'use client';\n\nimport * as React from 'react';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nconst defaultContextValue = {\n disableDefaultClasses: false\n};\nconst ClassNameConfiguratorContext = /*#__PURE__*/React.createContext(defaultContextValue);\n/**\n * @ignore - internal hook.\n *\n * Wraps the `generateUtilityClass` function and controls how the classes are generated.\n * Currently it only affects whether the classes are applied or not.\n *\n * @returns Function to be called with the `generateUtilityClass` function specific to a component to generate the classes.\n */\nexport function useClassNamesOverride(generateUtilityClass) {\n const {\n disableDefaultClasses\n } = React.useContext(ClassNameConfiguratorContext);\n return slot => {\n if (disableDefaultClasses) {\n return '';\n }\n return generateUtilityClass(slot);\n };\n}\n\n/**\n * Allows to configure the components within to not apply any built-in classes.\n */\nexport function ClassNameConfigurator(props) {\n const {\n disableDefaultClasses,\n children\n } = props;\n const contextValue = React.useMemo(() => ({\n disableDefaultClasses: disableDefaultClasses != null ? disableDefaultClasses : false\n }), [disableDefaultClasses]);\n return /*#__PURE__*/_jsx(ClassNameConfiguratorContext.Provider, {\n value: contextValue,\n children: children\n });\n}","/**\n * Extracts event handlers from a given object.\n * A prop is considered an event handler if it is a function and its name starts with `on`.\n *\n * @param object An object to extract event handlers from.\n * @param excludeKeys An array of keys to exclude from the returned object.\n */\nexport function extractEventHandlers(object, excludeKeys = []) {\n if (object === undefined) {\n return {};\n }\n const result = {};\n Object.keys(object).filter(prop => prop.match(/^on[A-Z]/) && typeof object[prop] === 'function' && !excludeKeys.includes(prop)).forEach(prop => {\n result[prop] = object[prop];\n });\n return result;\n}","/**\n * If `componentProps` is a function, calls it with the provided `ownerState`.\n * Otherwise, just returns `componentProps`.\n */\nexport function resolveComponentProps(componentProps, ownerState, slotState) {\n if (typeof componentProps === 'function') {\n return componentProps(ownerState, slotState);\n }\n return componentProps;\n}","/**\n * Removes event handlers from the given object.\n * A field is considered an event handler if it is a function with a name beginning with `on`.\n *\n * @param object Object to remove event handlers from.\n * @returns Object with event handlers removed.\n */\nexport function omitEventHandlers(object) {\n if (object === undefined) {\n return {};\n }\n const result = {};\n Object.keys(object).filter(prop => !(prop.match(/^on[A-Z]/) && typeof object[prop] === 'function')).forEach(prop => {\n result[prop] = object[prop];\n });\n return result;\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport clsx from 'clsx';\nimport { extractEventHandlers } from './extractEventHandlers';\nimport { omitEventHandlers } from './omitEventHandlers';\n/**\n * Merges the slot component internal props (usually coming from a hook)\n * with the externally provided ones.\n *\n * The merge order is (the latter overrides the former):\n * 1. The internal props (specified as a getter function to work with get*Props hook result)\n * 2. Additional props (specified internally on a Base UI component)\n * 3. External props specified on the owner component. These should only be used on a root slot.\n * 4. External props specified in the `slotProps.*` prop.\n * 5. The `className` prop - combined from all the above.\n * @param parameters\n * @returns\n */\nexport function mergeSlotProps(parameters) {\n const {\n getSlotProps,\n additionalProps,\n externalSlotProps,\n externalForwardedProps,\n className\n } = parameters;\n if (!getSlotProps) {\n // The simpler case - getSlotProps is not defined, so no internal event handlers are defined,\n // so we can simply merge all the props without having to worry about extracting event handlers.\n const joinedClasses = clsx(additionalProps == null ? void 0 : additionalProps.className, className, externalForwardedProps == null ? void 0 : externalForwardedProps.className, externalSlotProps == null ? void 0 : externalSlotProps.className);\n const mergedStyle = _extends({}, additionalProps == null ? void 0 : additionalProps.style, externalForwardedProps == null ? void 0 : externalForwardedProps.style, externalSlotProps == null ? void 0 : externalSlotProps.style);\n const props = _extends({}, additionalProps, externalForwardedProps, externalSlotProps);\n if (joinedClasses.length > 0) {\n props.className = joinedClasses;\n }\n if (Object.keys(mergedStyle).length > 0) {\n props.style = mergedStyle;\n }\n return {\n props,\n internalRef: undefined\n };\n }\n\n // In this case, getSlotProps is responsible for calling the external event handlers.\n // We don't need to include them in the merged props because of this.\n\n const eventHandlers = extractEventHandlers(_extends({}, externalForwardedProps, externalSlotProps));\n const componentsPropsWithoutEventHandlers = omitEventHandlers(externalSlotProps);\n const otherPropsWithoutEventHandlers = omitEventHandlers(externalForwardedProps);\n const internalSlotProps = getSlotProps(eventHandlers);\n\n // The order of classes is important here.\n // Emotion (that we use in libraries consuming Base UI) depends on this order\n // to properly override style. It requires the most important classes to be last\n // (see https://github.com/mui/material-ui/pull/33205) for the related discussion.\n const joinedClasses = clsx(internalSlotProps == null ? void 0 : internalSlotProps.className, additionalProps == null ? void 0 : additionalProps.className, className, externalForwardedProps == null ? void 0 : externalForwardedProps.className, externalSlotProps == null ? void 0 : externalSlotProps.className);\n const mergedStyle = _extends({}, internalSlotProps == null ? void 0 : internalSlotProps.style, additionalProps == null ? void 0 : additionalProps.style, externalForwardedProps == null ? void 0 : externalForwardedProps.style, externalSlotProps == null ? void 0 : externalSlotProps.style);\n const props = _extends({}, internalSlotProps, additionalProps, otherPropsWithoutEventHandlers, componentsPropsWithoutEventHandlers);\n if (joinedClasses.length > 0) {\n props.className = joinedClasses;\n }\n if (Object.keys(mergedStyle).length > 0) {\n props.style = mergedStyle;\n }\n return {\n props,\n internalRef: internalSlotProps.ref\n };\n}","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"elementType\", \"externalSlotProps\", \"ownerState\", \"skipResolvingSlotProps\"];\nimport { unstable_useForkRef as useForkRef } from '@mui/utils';\nimport { appendOwnerState } from './appendOwnerState';\nimport { mergeSlotProps } from './mergeSlotProps';\nimport { resolveComponentProps } from './resolveComponentProps';\n/**\n * @ignore - do not document.\n * Builds the props to be passed into the slot of an unstyled component.\n * It merges the internal props of the component with the ones supplied by the user, allowing to customize the behavior.\n * If the slot component is not a host component, it also merges in the `ownerState`.\n *\n * @param parameters.getSlotProps - A function that returns the props to be passed to the slot component.\n */\nexport function useSlotProps(parameters) {\n var _parameters$additiona;\n const {\n elementType,\n externalSlotProps,\n ownerState,\n skipResolvingSlotProps = false\n } = parameters,\n rest = _objectWithoutPropertiesLoose(parameters, _excluded);\n const resolvedComponentsProps = skipResolvingSlotProps ? {} : resolveComponentProps(externalSlotProps, ownerState);\n const {\n props: mergedProps,\n internalRef\n } = mergeSlotProps(_extends({}, rest, {\n externalSlotProps: resolvedComponentsProps\n }));\n const ref = useForkRef(internalRef, resolvedComponentsProps == null ? void 0 : resolvedComponentsProps.ref, (_parameters$additiona = parameters.additionalProps) == null ? void 0 : _parameters$additiona.ref);\n const props = appendOwnerState(elementType, _extends({}, mergedProps, {\n ref\n }), ownerState);\n return props;\n}","import { globalStateClasses } from '@mui/utils/generateUtilityClass';\nconst GLOBAL_CLASS_PREFIX = 'base';\nfunction buildStateClass(state) {\n return `${GLOBAL_CLASS_PREFIX}--${state}`;\n}\nfunction buildSlotClass(componentName, slot) {\n return `${GLOBAL_CLASS_PREFIX}-${componentName}-${slot}`;\n}\nexport function generateUtilityClass(componentName, slot) {\n const globalStateClass = globalStateClasses[slot];\n return globalStateClass ? buildStateClass(globalStateClass) : buildSlotClass(componentName, slot);\n}\nexport function isGlobalState(slot) {\n return globalStateClasses[slot] !== undefined;\n}","import { generateUtilityClass } from '../generateUtilityClass';\nexport function generateUtilityClasses(componentName, slots) {\n const result = {};\n slots.forEach(slot => {\n result[slot] = generateUtilityClass(componentName, slot);\n });\n return result;\n}","'use client';\n\nimport * as React from 'react';\nimport * as ReactDOM from 'react-dom';\nimport PropTypes from 'prop-types';\nimport { exactProp, HTMLElementType, unstable_useEnhancedEffect as useEnhancedEffect, unstable_useForkRef as useForkRef, unstable_setRef as setRef } from '@mui/utils';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nfunction getContainer(container) {\n return typeof container === 'function' ? container() : container;\n}\n\n/**\n * Portals provide a first-class way to render children into a DOM node\n * that exists outside the DOM hierarchy of the parent component.\n *\n * Demos:\n *\n * - [Portal](https://mui.com/base-ui/react-portal/)\n *\n * API:\n *\n * - [Portal API](https://mui.com/base-ui/react-portal/components-api/#portal)\n */\nconst Portal = /*#__PURE__*/React.forwardRef(function Portal(props, forwardedRef) {\n const {\n children,\n container,\n disablePortal = false\n } = props;\n const [mountNode, setMountNode] = React.useState(null);\n // @ts-expect-error TODO upstream fix\n const handleRef = useForkRef( /*#__PURE__*/React.isValidElement(children) ? children.ref : null, forwardedRef);\n useEnhancedEffect(() => {\n if (!disablePortal) {\n setMountNode(getContainer(container) || document.body);\n }\n }, [container, disablePortal]);\n useEnhancedEffect(() => {\n if (mountNode && !disablePortal) {\n setRef(forwardedRef, mountNode);\n return () => {\n setRef(forwardedRef, null);\n };\n }\n return undefined;\n }, [forwardedRef, mountNode, disablePortal]);\n if (disablePortal) {\n if ( /*#__PURE__*/React.isValidElement(children)) {\n const newProps = {\n ref: handleRef\n };\n return /*#__PURE__*/React.cloneElement(children, newProps);\n }\n return /*#__PURE__*/_jsx(React.Fragment, {\n children: children\n });\n }\n return /*#__PURE__*/_jsx(React.Fragment, {\n children: mountNode ? /*#__PURE__*/ReactDOM.createPortal(children, mountNode) : mountNode\n });\n});\nprocess.env.NODE_ENV !== \"production\" ? Portal.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * The children to render into the `container`.\n */\n children: PropTypes.node,\n /**\n * An HTML element or function that returns one.\n * The `container` will have the portal children appended to it.\n *\n * You can also provide a callback, which is called in a React layout effect.\n * This lets you set the container from a ref, and also makes server-side rendering possible.\n *\n * By default, it uses the body of the top-level document object,\n * so it's simply `document.body` most of the time.\n */\n container: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.func]),\n /**\n * The `children` will be under the DOM hierarchy of the parent component.\n * @default false\n */\n disablePortal: PropTypes.bool\n} : void 0;\nif (process.env.NODE_ENV !== 'production') {\n // eslint-disable-next-line\n Portal['propTypes' + ''] = exactProp(Portal.propTypes);\n}\nexport { Portal };","export var top = 'top';\nexport var bottom = 'bottom';\nexport var right = 'right';\nexport var left = 'left';\nexport var auto = 'auto';\nexport var basePlacements = [top, bottom, right, left];\nexport var start = 'start';\nexport var end = 'end';\nexport var clippingParents = 'clippingParents';\nexport var viewport = 'viewport';\nexport var popper = 'popper';\nexport var reference = 'reference';\nexport var variationPlacements = /*#__PURE__*/basePlacements.reduce(function (acc, placement) {\n return acc.concat([placement + \"-\" + start, placement + \"-\" + end]);\n}, []);\nexport var placements = /*#__PURE__*/[].concat(basePlacements, [auto]).reduce(function (acc, placement) {\n return acc.concat([placement, placement + \"-\" + start, placement + \"-\" + end]);\n}, []); // modifiers that need to read the DOM\n\nexport var beforeRead = 'beforeRead';\nexport var read = 'read';\nexport var afterRead = 'afterRead'; // pure-logic modifiers\n\nexport var beforeMain = 'beforeMain';\nexport var main = 'main';\nexport var afterMain = 'afterMain'; // modifier with the purpose to write to the DOM (or write into a framework state)\n\nexport var beforeWrite = 'beforeWrite';\nexport var write = 'write';\nexport var afterWrite = 'afterWrite';\nexport var modifierPhases = [beforeRead, read, afterRead, beforeMain, main, afterMain, beforeWrite, write, afterWrite];","export default function getNodeName(element) {\n return element ? (element.nodeName || '').toLowerCase() : null;\n}","export default function getWindow(node) {\n if (node == null) {\n return window;\n }\n\n if (node.toString() !== '[object Window]') {\n var ownerDocument = node.ownerDocument;\n return ownerDocument ? ownerDocument.defaultView || window : window;\n }\n\n return node;\n}","import getWindow from \"./getWindow.js\";\n\nfunction isElement(node) {\n var OwnElement = getWindow(node).Element;\n return node instanceof OwnElement || node instanceof Element;\n}\n\nfunction isHTMLElement(node) {\n var OwnElement = getWindow(node).HTMLElement;\n return node instanceof OwnElement || node instanceof HTMLElement;\n}\n\nfunction isShadowRoot(node) {\n // IE 11 has no ShadowRoot\n if (typeof ShadowRoot === 'undefined') {\n return false;\n }\n\n var OwnElement = getWindow(node).ShadowRoot;\n return node instanceof OwnElement || node instanceof ShadowRoot;\n}\n\nexport { isElement, isHTMLElement, isShadowRoot };","import getNodeName from \"../dom-utils/getNodeName.js\";\nimport { isHTMLElement } from \"../dom-utils/instanceOf.js\"; // This modifier takes the styles prepared by the `computeStyles` modifier\n// and applies them to the HTMLElements such as popper and arrow\n\nfunction applyStyles(_ref) {\n var state = _ref.state;\n Object.keys(state.elements).forEach(function (name) {\n var style = state.styles[name] || {};\n var attributes = state.attributes[name] || {};\n var element = state.elements[name]; // arrow is optional + virtual elements\n\n if (!isHTMLElement(element) || !getNodeName(element)) {\n return;\n } // Flow doesn't support to extend this property, but it's the most\n // effective way to apply styles to an HTMLElement\n // $FlowFixMe[cannot-write]\n\n\n Object.assign(element.style, style);\n Object.keys(attributes).forEach(function (name) {\n var value = attributes[name];\n\n if (value === false) {\n element.removeAttribute(name);\n } else {\n element.setAttribute(name, value === true ? '' : value);\n }\n });\n });\n}\n\nfunction effect(_ref2) {\n var state = _ref2.state;\n var initialStyles = {\n popper: {\n position: state.options.strategy,\n left: '0',\n top: '0',\n margin: '0'\n },\n arrow: {\n position: 'absolute'\n },\n reference: {}\n };\n Object.assign(state.elements.popper.style, initialStyles.popper);\n state.styles = initialStyles;\n\n if (state.elements.arrow) {\n Object.assign(state.elements.arrow.style, initialStyles.arrow);\n }\n\n return function () {\n Object.keys(state.elements).forEach(function (name) {\n var element = state.elements[name];\n var attributes = state.attributes[name] || {};\n var styleProperties = Object.keys(state.styles.hasOwnProperty(name) ? state.styles[name] : initialStyles[name]); // Set all values to an empty string to unset them\n\n var style = styleProperties.reduce(function (style, property) {\n style[property] = '';\n return style;\n }, {}); // arrow is optional + virtual elements\n\n if (!isHTMLElement(element) || !getNodeName(element)) {\n return;\n }\n\n Object.assign(element.style, style);\n Object.keys(attributes).forEach(function (attribute) {\n element.removeAttribute(attribute);\n });\n });\n };\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'applyStyles',\n enabled: true,\n phase: 'write',\n fn: applyStyles,\n effect: effect,\n requires: ['computeStyles']\n};","import { auto } from \"../enums.js\";\nexport default function getBasePlacement(placement) {\n return placement.split('-')[0];\n}","export var max = Math.max;\nexport var min = Math.min;\nexport var round = Math.round;","export default function getUAString() {\n var uaData = navigator.userAgentData;\n\n if (uaData != null && uaData.brands && Array.isArray(uaData.brands)) {\n return uaData.brands.map(function (item) {\n return item.brand + \"/\" + item.version;\n }).join(' ');\n }\n\n return navigator.userAgent;\n}","import getUAString from \"../utils/userAgent.js\";\nexport default function isLayoutViewport() {\n return !/^((?!chrome|android).)*safari/i.test(getUAString());\n}","import { isElement, isHTMLElement } from \"./instanceOf.js\";\nimport { round } from \"../utils/math.js\";\nimport getWindow from \"./getWindow.js\";\nimport isLayoutViewport from \"./isLayoutViewport.js\";\nexport default function getBoundingClientRect(element, includeScale, isFixedStrategy) {\n if (includeScale === void 0) {\n includeScale = false;\n }\n\n if (isFixedStrategy === void 0) {\n isFixedStrategy = false;\n }\n\n var clientRect = element.getBoundingClientRect();\n var scaleX = 1;\n var scaleY = 1;\n\n if (includeScale && isHTMLElement(element)) {\n scaleX = element.offsetWidth > 0 ? round(clientRect.width) / element.offsetWidth || 1 : 1;\n scaleY = element.offsetHeight > 0 ? round(clientRect.height) / element.offsetHeight || 1 : 1;\n }\n\n var _ref = isElement(element) ? getWindow(element) : window,\n visualViewport = _ref.visualViewport;\n\n var addVisualOffsets = !isLayoutViewport() && isFixedStrategy;\n var x = (clientRect.left + (addVisualOffsets && visualViewport ? visualViewport.offsetLeft : 0)) / scaleX;\n var y = (clientRect.top + (addVisualOffsets && visualViewport ? visualViewport.offsetTop : 0)) / scaleY;\n var width = clientRect.width / scaleX;\n var height = clientRect.height / scaleY;\n return {\n width: width,\n height: height,\n top: y,\n right: x + width,\n bottom: y + height,\n left: x,\n x: x,\n y: y\n };\n}","import getBoundingClientRect from \"./getBoundingClientRect.js\"; // Returns the layout rect of an element relative to its offsetParent. Layout\n// means it doesn't take into account transforms.\n\nexport default function getLayoutRect(element) {\n var clientRect = getBoundingClientRect(element); // Use the clientRect sizes if it's not been transformed.\n // Fixes https://github.com/popperjs/popper-core/issues/1223\n\n var width = element.offsetWidth;\n var height = element.offsetHeight;\n\n if (Math.abs(clientRect.width - width) <= 1) {\n width = clientRect.width;\n }\n\n if (Math.abs(clientRect.height - height) <= 1) {\n height = clientRect.height;\n }\n\n return {\n x: element.offsetLeft,\n y: element.offsetTop,\n width: width,\n height: height\n };\n}","import { isShadowRoot } from \"./instanceOf.js\";\nexport default function contains(parent, child) {\n var rootNode = child.getRootNode && child.getRootNode(); // First, attempt with faster native method\n\n if (parent.contains(child)) {\n return true;\n } // then fallback to custom implementation with Shadow DOM support\n else if (rootNode && isShadowRoot(rootNode)) {\n var next = child;\n\n do {\n if (next && parent.isSameNode(next)) {\n return true;\n } // $FlowFixMe[prop-missing]: need a better way to handle this...\n\n\n next = next.parentNode || next.host;\n } while (next);\n } // Give up, the result is false\n\n\n return false;\n}","import getWindow from \"./getWindow.js\";\nexport default function getComputedStyle(element) {\n return getWindow(element).getComputedStyle(element);\n}","import getNodeName from \"./getNodeName.js\";\nexport default function isTableElement(element) {\n return ['table', 'td', 'th'].indexOf(getNodeName(element)) >= 0;\n}","import { isElement } from \"./instanceOf.js\";\nexport default function getDocumentElement(element) {\n // $FlowFixMe[incompatible-return]: assume body is always available\n return ((isElement(element) ? element.ownerDocument : // $FlowFixMe[prop-missing]\n element.document) || window.document).documentElement;\n}","import getNodeName from \"./getNodeName.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport { isShadowRoot } from \"./instanceOf.js\";\nexport default function getParentNode(element) {\n if (getNodeName(element) === 'html') {\n return element;\n }\n\n return (// this is a quicker (but less type safe) way to save quite some bytes from the bundle\n // $FlowFixMe[incompatible-return]\n // $FlowFixMe[prop-missing]\n element.assignedSlot || // step into the shadow DOM of the parent of a slotted node\n element.parentNode || ( // DOM Element detected\n isShadowRoot(element) ? element.host : null) || // ShadowRoot detected\n // $FlowFixMe[incompatible-call]: HTMLElement is a Node\n getDocumentElement(element) // fallback\n\n );\n}","import getWindow from \"./getWindow.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport getComputedStyle from \"./getComputedStyle.js\";\nimport { isHTMLElement, isShadowRoot } from \"./instanceOf.js\";\nimport isTableElement from \"./isTableElement.js\";\nimport getParentNode from \"./getParentNode.js\";\nimport getUAString from \"../utils/userAgent.js\";\n\nfunction getTrueOffsetParent(element) {\n if (!isHTMLElement(element) || // https://github.com/popperjs/popper-core/issues/837\n getComputedStyle(element).position === 'fixed') {\n return null;\n }\n\n return element.offsetParent;\n} // `.offsetParent` reports `null` for fixed elements, while absolute elements\n// return the containing block\n\n\nfunction getContainingBlock(element) {\n var isFirefox = /firefox/i.test(getUAString());\n var isIE = /Trident/i.test(getUAString());\n\n if (isIE && isHTMLElement(element)) {\n // In IE 9, 10 and 11 fixed elements containing block is always established by the viewport\n var elementCss = getComputedStyle(element);\n\n if (elementCss.position === 'fixed') {\n return null;\n }\n }\n\n var currentNode = getParentNode(element);\n\n if (isShadowRoot(currentNode)) {\n currentNode = currentNode.host;\n }\n\n while (isHTMLElement(currentNode) && ['html', 'body'].indexOf(getNodeName(currentNode)) < 0) {\n var css = getComputedStyle(currentNode); // This is non-exhaustive but covers the most common CSS properties that\n // create a containing block.\n // https://developer.mozilla.org/en-US/docs/Web/CSS/Containing_block#identifying_the_containing_block\n\n if (css.transform !== 'none' || css.perspective !== 'none' || css.contain === 'paint' || ['transform', 'perspective'].indexOf(css.willChange) !== -1 || isFirefox && css.willChange === 'filter' || isFirefox && css.filter && css.filter !== 'none') {\n return currentNode;\n } else {\n currentNode = currentNode.parentNode;\n }\n }\n\n return null;\n} // Gets the closest ancestor positioned element. Handles some edge cases,\n// such as table ancestors and cross browser bugs.\n\n\nexport default function getOffsetParent(element) {\n var window = getWindow(element);\n var offsetParent = getTrueOffsetParent(element);\n\n while (offsetParent && isTableElement(offsetParent) && getComputedStyle(offsetParent).position === 'static') {\n offsetParent = getTrueOffsetParent(offsetParent);\n }\n\n if (offsetParent && (getNodeName(offsetParent) === 'html' || getNodeName(offsetParent) === 'body' && getComputedStyle(offsetParent).position === 'static')) {\n return window;\n }\n\n return offsetParent || getContainingBlock(element) || window;\n}","export default function getMainAxisFromPlacement(placement) {\n return ['top', 'bottom'].indexOf(placement) >= 0 ? 'x' : 'y';\n}","import { max as mathMax, min as mathMin } from \"./math.js\";\nexport function within(min, value, max) {\n return mathMax(min, mathMin(value, max));\n}\nexport function withinMaxClamp(min, value, max) {\n var v = within(min, value, max);\n return v > max ? max : v;\n}","export default function getFreshSideObject() {\n return {\n top: 0,\n right: 0,\n bottom: 0,\n left: 0\n };\n}","import getFreshSideObject from \"./getFreshSideObject.js\";\nexport default function mergePaddingObject(paddingObject) {\n return Object.assign({}, getFreshSideObject(), paddingObject);\n}","export default function expandToHashMap(value, keys) {\n return keys.reduce(function (hashMap, key) {\n hashMap[key] = value;\n return hashMap;\n }, {});\n}","import getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getLayoutRect from \"../dom-utils/getLayoutRect.js\";\nimport contains from \"../dom-utils/contains.js\";\nimport getOffsetParent from \"../dom-utils/getOffsetParent.js\";\nimport getMainAxisFromPlacement from \"../utils/getMainAxisFromPlacement.js\";\nimport { within } from \"../utils/within.js\";\nimport mergePaddingObject from \"../utils/mergePaddingObject.js\";\nimport expandToHashMap from \"../utils/expandToHashMap.js\";\nimport { left, right, basePlacements, top, bottom } from \"../enums.js\"; // eslint-disable-next-line import/no-unused-modules\n\nvar toPaddingObject = function toPaddingObject(padding, state) {\n padding = typeof padding === 'function' ? padding(Object.assign({}, state.rects, {\n placement: state.placement\n })) : padding;\n return mergePaddingObject(typeof padding !== 'number' ? padding : expandToHashMap(padding, basePlacements));\n};\n\nfunction arrow(_ref) {\n var _state$modifiersData$;\n\n var state = _ref.state,\n name = _ref.name,\n options = _ref.options;\n var arrowElement = state.elements.arrow;\n var popperOffsets = state.modifiersData.popperOffsets;\n var basePlacement = getBasePlacement(state.placement);\n var axis = getMainAxisFromPlacement(basePlacement);\n var isVertical = [left, right].indexOf(basePlacement) >= 0;\n var len = isVertical ? 'height' : 'width';\n\n if (!arrowElement || !popperOffsets) {\n return;\n }\n\n var paddingObject = toPaddingObject(options.padding, state);\n var arrowRect = getLayoutRect(arrowElement);\n var minProp = axis === 'y' ? top : left;\n var maxProp = axis === 'y' ? bottom : right;\n var endDiff = state.rects.reference[len] + state.rects.reference[axis] - popperOffsets[axis] - state.rects.popper[len];\n var startDiff = popperOffsets[axis] - state.rects.reference[axis];\n var arrowOffsetParent = getOffsetParent(arrowElement);\n var clientSize = arrowOffsetParent ? axis === 'y' ? arrowOffsetParent.clientHeight || 0 : arrowOffsetParent.clientWidth || 0 : 0;\n var centerToReference = endDiff / 2 - startDiff / 2; // Make sure the arrow doesn't overflow the popper if the center point is\n // outside of the popper bounds\n\n var min = paddingObject[minProp];\n var max = clientSize - arrowRect[len] - paddingObject[maxProp];\n var center = clientSize / 2 - arrowRect[len] / 2 + centerToReference;\n var offset = within(min, center, max); // Prevents breaking syntax highlighting...\n\n var axisProp = axis;\n state.modifiersData[name] = (_state$modifiersData$ = {}, _state$modifiersData$[axisProp] = offset, _state$modifiersData$.centerOffset = offset - center, _state$modifiersData$);\n}\n\nfunction effect(_ref2) {\n var state = _ref2.state,\n options = _ref2.options;\n var _options$element = options.element,\n arrowElement = _options$element === void 0 ? '[data-popper-arrow]' : _options$element;\n\n if (arrowElement == null) {\n return;\n } // CSS selector\n\n\n if (typeof arrowElement === 'string') {\n arrowElement = state.elements.popper.querySelector(arrowElement);\n\n if (!arrowElement) {\n return;\n }\n }\n\n if (!contains(state.elements.popper, arrowElement)) {\n return;\n }\n\n state.elements.arrow = arrowElement;\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'arrow',\n enabled: true,\n phase: 'main',\n fn: arrow,\n effect: effect,\n requires: ['popperOffsets'],\n requiresIfExists: ['preventOverflow']\n};","export default function getVariation(placement) {\n return placement.split('-')[1];\n}","import { top, left, right, bottom, end } from \"../enums.js\";\nimport getOffsetParent from \"../dom-utils/getOffsetParent.js\";\nimport getWindow from \"../dom-utils/getWindow.js\";\nimport getDocumentElement from \"../dom-utils/getDocumentElement.js\";\nimport getComputedStyle from \"../dom-utils/getComputedStyle.js\";\nimport getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getVariation from \"../utils/getVariation.js\";\nimport { round } from \"../utils/math.js\"; // eslint-disable-next-line import/no-unused-modules\n\nvar unsetSides = {\n top: 'auto',\n right: 'auto',\n bottom: 'auto',\n left: 'auto'\n}; // Round the offsets to the nearest suitable subpixel based on the DPR.\n// Zooming can change the DPR, but it seems to report a value that will\n// cleanly divide the values into the appropriate subpixels.\n\nfunction roundOffsetsByDPR(_ref, win) {\n var x = _ref.x,\n y = _ref.y;\n var dpr = win.devicePixelRatio || 1;\n return {\n x: round(x * dpr) / dpr || 0,\n y: round(y * dpr) / dpr || 0\n };\n}\n\nexport function mapToStyles(_ref2) {\n var _Object$assign2;\n\n var popper = _ref2.popper,\n popperRect = _ref2.popperRect,\n placement = _ref2.placement,\n variation = _ref2.variation,\n offsets = _ref2.offsets,\n position = _ref2.position,\n gpuAcceleration = _ref2.gpuAcceleration,\n adaptive = _ref2.adaptive,\n roundOffsets = _ref2.roundOffsets,\n isFixed = _ref2.isFixed;\n var _offsets$x = offsets.x,\n x = _offsets$x === void 0 ? 0 : _offsets$x,\n _offsets$y = offsets.y,\n y = _offsets$y === void 0 ? 0 : _offsets$y;\n\n var _ref3 = typeof roundOffsets === 'function' ? roundOffsets({\n x: x,\n y: y\n }) : {\n x: x,\n y: y\n };\n\n x = _ref3.x;\n y = _ref3.y;\n var hasX = offsets.hasOwnProperty('x');\n var hasY = offsets.hasOwnProperty('y');\n var sideX = left;\n var sideY = top;\n var win = window;\n\n if (adaptive) {\n var offsetParent = getOffsetParent(popper);\n var heightProp = 'clientHeight';\n var widthProp = 'clientWidth';\n\n if (offsetParent === getWindow(popper)) {\n offsetParent = getDocumentElement(popper);\n\n if (getComputedStyle(offsetParent).position !== 'static' && position === 'absolute') {\n heightProp = 'scrollHeight';\n widthProp = 'scrollWidth';\n }\n } // $FlowFixMe[incompatible-cast]: force type refinement, we compare offsetParent with window above, but Flow doesn't detect it\n\n\n offsetParent = offsetParent;\n\n if (placement === top || (placement === left || placement === right) && variation === end) {\n sideY = bottom;\n var offsetY = isFixed && offsetParent === win && win.visualViewport ? win.visualViewport.height : // $FlowFixMe[prop-missing]\n offsetParent[heightProp];\n y -= offsetY - popperRect.height;\n y *= gpuAcceleration ? 1 : -1;\n }\n\n if (placement === left || (placement === top || placement === bottom) && variation === end) {\n sideX = right;\n var offsetX = isFixed && offsetParent === win && win.visualViewport ? win.visualViewport.width : // $FlowFixMe[prop-missing]\n offsetParent[widthProp];\n x -= offsetX - popperRect.width;\n x *= gpuAcceleration ? 1 : -1;\n }\n }\n\n var commonStyles = Object.assign({\n position: position\n }, adaptive && unsetSides);\n\n var _ref4 = roundOffsets === true ? roundOffsetsByDPR({\n x: x,\n y: y\n }, getWindow(popper)) : {\n x: x,\n y: y\n };\n\n x = _ref4.x;\n y = _ref4.y;\n\n if (gpuAcceleration) {\n var _Object$assign;\n\n return Object.assign({}, commonStyles, (_Object$assign = {}, _Object$assign[sideY] = hasY ? '0' : '', _Object$assign[sideX] = hasX ? '0' : '', _Object$assign.transform = (win.devicePixelRatio || 1) <= 1 ? \"translate(\" + x + \"px, \" + y + \"px)\" : \"translate3d(\" + x + \"px, \" + y + \"px, 0)\", _Object$assign));\n }\n\n return Object.assign({}, commonStyles, (_Object$assign2 = {}, _Object$assign2[sideY] = hasY ? y + \"px\" : '', _Object$assign2[sideX] = hasX ? x + \"px\" : '', _Object$assign2.transform = '', _Object$assign2));\n}\n\nfunction computeStyles(_ref5) {\n var state = _ref5.state,\n options = _ref5.options;\n var _options$gpuAccelerat = options.gpuAcceleration,\n gpuAcceleration = _options$gpuAccelerat === void 0 ? true : _options$gpuAccelerat,\n _options$adaptive = options.adaptive,\n adaptive = _options$adaptive === void 0 ? true : _options$adaptive,\n _options$roundOffsets = options.roundOffsets,\n roundOffsets = _options$roundOffsets === void 0 ? true : _options$roundOffsets;\n var commonStyles = {\n placement: getBasePlacement(state.placement),\n variation: getVariation(state.placement),\n popper: state.elements.popper,\n popperRect: state.rects.popper,\n gpuAcceleration: gpuAcceleration,\n isFixed: state.options.strategy === 'fixed'\n };\n\n if (state.modifiersData.popperOffsets != null) {\n state.styles.popper = Object.assign({}, state.styles.popper, mapToStyles(Object.assign({}, commonStyles, {\n offsets: state.modifiersData.popperOffsets,\n position: state.options.strategy,\n adaptive: adaptive,\n roundOffsets: roundOffsets\n })));\n }\n\n if (state.modifiersData.arrow != null) {\n state.styles.arrow = Object.assign({}, state.styles.arrow, mapToStyles(Object.assign({}, commonStyles, {\n offsets: state.modifiersData.arrow,\n position: 'absolute',\n adaptive: false,\n roundOffsets: roundOffsets\n })));\n }\n\n state.attributes.popper = Object.assign({}, state.attributes.popper, {\n 'data-popper-placement': state.placement\n });\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'computeStyles',\n enabled: true,\n phase: 'beforeWrite',\n fn: computeStyles,\n data: {}\n};","import getWindow from \"../dom-utils/getWindow.js\"; // eslint-disable-next-line import/no-unused-modules\n\nvar passive = {\n passive: true\n};\n\nfunction effect(_ref) {\n var state = _ref.state,\n instance = _ref.instance,\n options = _ref.options;\n var _options$scroll = options.scroll,\n scroll = _options$scroll === void 0 ? true : _options$scroll,\n _options$resize = options.resize,\n resize = _options$resize === void 0 ? true : _options$resize;\n var window = getWindow(state.elements.popper);\n var scrollParents = [].concat(state.scrollParents.reference, state.scrollParents.popper);\n\n if (scroll) {\n scrollParents.forEach(function (scrollParent) {\n scrollParent.addEventListener('scroll', instance.update, passive);\n });\n }\n\n if (resize) {\n window.addEventListener('resize', instance.update, passive);\n }\n\n return function () {\n if (scroll) {\n scrollParents.forEach(function (scrollParent) {\n scrollParent.removeEventListener('scroll', instance.update, passive);\n });\n }\n\n if (resize) {\n window.removeEventListener('resize', instance.update, passive);\n }\n };\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'eventListeners',\n enabled: true,\n phase: 'write',\n fn: function fn() {},\n effect: effect,\n data: {}\n};","var hash = {\n left: 'right',\n right: 'left',\n bottom: 'top',\n top: 'bottom'\n};\nexport default function getOppositePlacement(placement) {\n return placement.replace(/left|right|bottom|top/g, function (matched) {\n return hash[matched];\n });\n}","var hash = {\n start: 'end',\n end: 'start'\n};\nexport default function getOppositeVariationPlacement(placement) {\n return placement.replace(/start|end/g, function (matched) {\n return hash[matched];\n });\n}","import getWindow from \"./getWindow.js\";\nexport default function getWindowScroll(node) {\n var win = getWindow(node);\n var scrollLeft = win.pageXOffset;\n var scrollTop = win.pageYOffset;\n return {\n scrollLeft: scrollLeft,\n scrollTop: scrollTop\n };\n}","import getBoundingClientRect from \"./getBoundingClientRect.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport getWindowScroll from \"./getWindowScroll.js\";\nexport default function getWindowScrollBarX(element) {\n // If has a CSS width greater than the viewport, then this will be\n // incorrect for RTL.\n // Popper 1 is broken in this case and never had a bug report so let's assume\n // it's not an issue. I don't think anyone ever specifies width on \n // anyway.\n // Browsers where the left scrollbar doesn't cause an issue report `0` for\n // this (e.g. Edge 2019, IE11, Safari)\n return getBoundingClientRect(getDocumentElement(element)).left + getWindowScroll(element).scrollLeft;\n}","import getWindow from \"./getWindow.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport getWindowScrollBarX from \"./getWindowScrollBarX.js\";\nimport isLayoutViewport from \"./isLayoutViewport.js\";\nexport default function getViewportRect(element, strategy) {\n var win = getWindow(element);\n var html = getDocumentElement(element);\n var visualViewport = win.visualViewport;\n var width = html.clientWidth;\n var height = html.clientHeight;\n var x = 0;\n var y = 0;\n\n if (visualViewport) {\n width = visualViewport.width;\n height = visualViewport.height;\n var layoutViewport = isLayoutViewport();\n\n if (layoutViewport || !layoutViewport && strategy === 'fixed') {\n x = visualViewport.offsetLeft;\n y = visualViewport.offsetTop;\n }\n }\n\n return {\n width: width,\n height: height,\n x: x + getWindowScrollBarX(element),\n y: y\n };\n}","import getDocumentElement from \"./getDocumentElement.js\";\nimport getComputedStyle from \"./getComputedStyle.js\";\nimport getWindowScrollBarX from \"./getWindowScrollBarX.js\";\nimport getWindowScroll from \"./getWindowScroll.js\";\nimport { max } from \"../utils/math.js\"; // Gets the entire size of the scrollable document area, even extending outside\n// of the `` and `` rect bounds if horizontally scrollable\n\nexport default function getDocumentRect(element) {\n var _element$ownerDocumen;\n\n var html = getDocumentElement(element);\n var winScroll = getWindowScroll(element);\n var body = (_element$ownerDocumen = element.ownerDocument) == null ? void 0 : _element$ownerDocumen.body;\n var width = max(html.scrollWidth, html.clientWidth, body ? body.scrollWidth : 0, body ? body.clientWidth : 0);\n var height = max(html.scrollHeight, html.clientHeight, body ? body.scrollHeight : 0, body ? body.clientHeight : 0);\n var x = -winScroll.scrollLeft + getWindowScrollBarX(element);\n var y = -winScroll.scrollTop;\n\n if (getComputedStyle(body || html).direction === 'rtl') {\n x += max(html.clientWidth, body ? body.clientWidth : 0) - width;\n }\n\n return {\n width: width,\n height: height,\n x: x,\n y: y\n };\n}","import getComputedStyle from \"./getComputedStyle.js\";\nexport default function isScrollParent(element) {\n // Firefox wants us to check `-x` and `-y` variations as well\n var _getComputedStyle = getComputedStyle(element),\n overflow = _getComputedStyle.overflow,\n overflowX = _getComputedStyle.overflowX,\n overflowY = _getComputedStyle.overflowY;\n\n return /auto|scroll|overlay|hidden/.test(overflow + overflowY + overflowX);\n}","import getParentNode from \"./getParentNode.js\";\nimport isScrollParent from \"./isScrollParent.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport { isHTMLElement } from \"./instanceOf.js\";\nexport default function getScrollParent(node) {\n if (['html', 'body', '#document'].indexOf(getNodeName(node)) >= 0) {\n // $FlowFixMe[incompatible-return]: assume body is always available\n return node.ownerDocument.body;\n }\n\n if (isHTMLElement(node) && isScrollParent(node)) {\n return node;\n }\n\n return getScrollParent(getParentNode(node));\n}","import getScrollParent from \"./getScrollParent.js\";\nimport getParentNode from \"./getParentNode.js\";\nimport getWindow from \"./getWindow.js\";\nimport isScrollParent from \"./isScrollParent.js\";\n/*\ngiven a DOM element, return the list of all scroll parents, up the list of ancesors\nuntil we get to the top window object. This list is what we attach scroll listeners\nto, because if any of these parent elements scroll, we'll need to re-calculate the\nreference element's position.\n*/\n\nexport default function listScrollParents(element, list) {\n var _element$ownerDocumen;\n\n if (list === void 0) {\n list = [];\n }\n\n var scrollParent = getScrollParent(element);\n var isBody = scrollParent === ((_element$ownerDocumen = element.ownerDocument) == null ? void 0 : _element$ownerDocumen.body);\n var win = getWindow(scrollParent);\n var target = isBody ? [win].concat(win.visualViewport || [], isScrollParent(scrollParent) ? scrollParent : []) : scrollParent;\n var updatedList = list.concat(target);\n return isBody ? updatedList : // $FlowFixMe[incompatible-call]: isBody tells us target will be an HTMLElement here\n updatedList.concat(listScrollParents(getParentNode(target)));\n}","export default function rectToClientRect(rect) {\n return Object.assign({}, rect, {\n left: rect.x,\n top: rect.y,\n right: rect.x + rect.width,\n bottom: rect.y + rect.height\n });\n}","import { viewport } from \"../enums.js\";\nimport getViewportRect from \"./getViewportRect.js\";\nimport getDocumentRect from \"./getDocumentRect.js\";\nimport listScrollParents from \"./listScrollParents.js\";\nimport getOffsetParent from \"./getOffsetParent.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport getComputedStyle from \"./getComputedStyle.js\";\nimport { isElement, isHTMLElement } from \"./instanceOf.js\";\nimport getBoundingClientRect from \"./getBoundingClientRect.js\";\nimport getParentNode from \"./getParentNode.js\";\nimport contains from \"./contains.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport rectToClientRect from \"../utils/rectToClientRect.js\";\nimport { max, min } from \"../utils/math.js\";\n\nfunction getInnerBoundingClientRect(element, strategy) {\n var rect = getBoundingClientRect(element, false, strategy === 'fixed');\n rect.top = rect.top + element.clientTop;\n rect.left = rect.left + element.clientLeft;\n rect.bottom = rect.top + element.clientHeight;\n rect.right = rect.left + element.clientWidth;\n rect.width = element.clientWidth;\n rect.height = element.clientHeight;\n rect.x = rect.left;\n rect.y = rect.top;\n return rect;\n}\n\nfunction getClientRectFromMixedType(element, clippingParent, strategy) {\n return clippingParent === viewport ? rectToClientRect(getViewportRect(element, strategy)) : isElement(clippingParent) ? getInnerBoundingClientRect(clippingParent, strategy) : rectToClientRect(getDocumentRect(getDocumentElement(element)));\n} // A \"clipping parent\" is an overflowable container with the characteristic of\n// clipping (or hiding) overflowing elements with a position different from\n// `initial`\n\n\nfunction getClippingParents(element) {\n var clippingParents = listScrollParents(getParentNode(element));\n var canEscapeClipping = ['absolute', 'fixed'].indexOf(getComputedStyle(element).position) >= 0;\n var clipperElement = canEscapeClipping && isHTMLElement(element) ? getOffsetParent(element) : element;\n\n if (!isElement(clipperElement)) {\n return [];\n } // $FlowFixMe[incompatible-return]: https://github.com/facebook/flow/issues/1414\n\n\n return clippingParents.filter(function (clippingParent) {\n return isElement(clippingParent) && contains(clippingParent, clipperElement) && getNodeName(clippingParent) !== 'body';\n });\n} // Gets the maximum area that the element is visible in due to any number of\n// clipping parents\n\n\nexport default function getClippingRect(element, boundary, rootBoundary, strategy) {\n var mainClippingParents = boundary === 'clippingParents' ? getClippingParents(element) : [].concat(boundary);\n var clippingParents = [].concat(mainClippingParents, [rootBoundary]);\n var firstClippingParent = clippingParents[0];\n var clippingRect = clippingParents.reduce(function (accRect, clippingParent) {\n var rect = getClientRectFromMixedType(element, clippingParent, strategy);\n accRect.top = max(rect.top, accRect.top);\n accRect.right = min(rect.right, accRect.right);\n accRect.bottom = min(rect.bottom, accRect.bottom);\n accRect.left = max(rect.left, accRect.left);\n return accRect;\n }, getClientRectFromMixedType(element, firstClippingParent, strategy));\n clippingRect.width = clippingRect.right - clippingRect.left;\n clippingRect.height = clippingRect.bottom - clippingRect.top;\n clippingRect.x = clippingRect.left;\n clippingRect.y = clippingRect.top;\n return clippingRect;\n}","import getBasePlacement from \"./getBasePlacement.js\";\nimport getVariation from \"./getVariation.js\";\nimport getMainAxisFromPlacement from \"./getMainAxisFromPlacement.js\";\nimport { top, right, bottom, left, start, end } from \"../enums.js\";\nexport default function computeOffsets(_ref) {\n var reference = _ref.reference,\n element = _ref.element,\n placement = _ref.placement;\n var basePlacement = placement ? getBasePlacement(placement) : null;\n var variation = placement ? getVariation(placement) : null;\n var commonX = reference.x + reference.width / 2 - element.width / 2;\n var commonY = reference.y + reference.height / 2 - element.height / 2;\n var offsets;\n\n switch (basePlacement) {\n case top:\n offsets = {\n x: commonX,\n y: reference.y - element.height\n };\n break;\n\n case bottom:\n offsets = {\n x: commonX,\n y: reference.y + reference.height\n };\n break;\n\n case right:\n offsets = {\n x: reference.x + reference.width,\n y: commonY\n };\n break;\n\n case left:\n offsets = {\n x: reference.x - element.width,\n y: commonY\n };\n break;\n\n default:\n offsets = {\n x: reference.x,\n y: reference.y\n };\n }\n\n var mainAxis = basePlacement ? getMainAxisFromPlacement(basePlacement) : null;\n\n if (mainAxis != null) {\n var len = mainAxis === 'y' ? 'height' : 'width';\n\n switch (variation) {\n case start:\n offsets[mainAxis] = offsets[mainAxis] - (reference[len] / 2 - element[len] / 2);\n break;\n\n case end:\n offsets[mainAxis] = offsets[mainAxis] + (reference[len] / 2 - element[len] / 2);\n break;\n\n default:\n }\n }\n\n return offsets;\n}","import getClippingRect from \"../dom-utils/getClippingRect.js\";\nimport getDocumentElement from \"../dom-utils/getDocumentElement.js\";\nimport getBoundingClientRect from \"../dom-utils/getBoundingClientRect.js\";\nimport computeOffsets from \"./computeOffsets.js\";\nimport rectToClientRect from \"./rectToClientRect.js\";\nimport { clippingParents, reference, popper, bottom, top, right, basePlacements, viewport } from \"../enums.js\";\nimport { isElement } from \"../dom-utils/instanceOf.js\";\nimport mergePaddingObject from \"./mergePaddingObject.js\";\nimport expandToHashMap from \"./expandToHashMap.js\"; // eslint-disable-next-line import/no-unused-modules\n\nexport default function detectOverflow(state, options) {\n if (options === void 0) {\n options = {};\n }\n\n var _options = options,\n _options$placement = _options.placement,\n placement = _options$placement === void 0 ? state.placement : _options$placement,\n _options$strategy = _options.strategy,\n strategy = _options$strategy === void 0 ? state.strategy : _options$strategy,\n _options$boundary = _options.boundary,\n boundary = _options$boundary === void 0 ? clippingParents : _options$boundary,\n _options$rootBoundary = _options.rootBoundary,\n rootBoundary = _options$rootBoundary === void 0 ? viewport : _options$rootBoundary,\n _options$elementConte = _options.elementContext,\n elementContext = _options$elementConte === void 0 ? popper : _options$elementConte,\n _options$altBoundary = _options.altBoundary,\n altBoundary = _options$altBoundary === void 0 ? false : _options$altBoundary,\n _options$padding = _options.padding,\n padding = _options$padding === void 0 ? 0 : _options$padding;\n var paddingObject = mergePaddingObject(typeof padding !== 'number' ? padding : expandToHashMap(padding, basePlacements));\n var altContext = elementContext === popper ? reference : popper;\n var popperRect = state.rects.popper;\n var element = state.elements[altBoundary ? altContext : elementContext];\n var clippingClientRect = getClippingRect(isElement(element) ? element : element.contextElement || getDocumentElement(state.elements.popper), boundary, rootBoundary, strategy);\n var referenceClientRect = getBoundingClientRect(state.elements.reference);\n var popperOffsets = computeOffsets({\n reference: referenceClientRect,\n element: popperRect,\n strategy: 'absolute',\n placement: placement\n });\n var popperClientRect = rectToClientRect(Object.assign({}, popperRect, popperOffsets));\n var elementClientRect = elementContext === popper ? popperClientRect : referenceClientRect; // positive = overflowing the clipping rect\n // 0 or negative = within the clipping rect\n\n var overflowOffsets = {\n top: clippingClientRect.top - elementClientRect.top + paddingObject.top,\n bottom: elementClientRect.bottom - clippingClientRect.bottom + paddingObject.bottom,\n left: clippingClientRect.left - elementClientRect.left + paddingObject.left,\n right: elementClientRect.right - clippingClientRect.right + paddingObject.right\n };\n var offsetData = state.modifiersData.offset; // Offsets can be applied only to the popper element\n\n if (elementContext === popper && offsetData) {\n var offset = offsetData[placement];\n Object.keys(overflowOffsets).forEach(function (key) {\n var multiply = [right, bottom].indexOf(key) >= 0 ? 1 : -1;\n var axis = [top, bottom].indexOf(key) >= 0 ? 'y' : 'x';\n overflowOffsets[key] += offset[axis] * multiply;\n });\n }\n\n return overflowOffsets;\n}","import getVariation from \"./getVariation.js\";\nimport { variationPlacements, basePlacements, placements as allPlacements } from \"../enums.js\";\nimport detectOverflow from \"./detectOverflow.js\";\nimport getBasePlacement from \"./getBasePlacement.js\";\nexport default function computeAutoPlacement(state, options) {\n if (options === void 0) {\n options = {};\n }\n\n var _options = options,\n placement = _options.placement,\n boundary = _options.boundary,\n rootBoundary = _options.rootBoundary,\n padding = _options.padding,\n flipVariations = _options.flipVariations,\n _options$allowedAutoP = _options.allowedAutoPlacements,\n allowedAutoPlacements = _options$allowedAutoP === void 0 ? allPlacements : _options$allowedAutoP;\n var variation = getVariation(placement);\n var placements = variation ? flipVariations ? variationPlacements : variationPlacements.filter(function (placement) {\n return getVariation(placement) === variation;\n }) : basePlacements;\n var allowedPlacements = placements.filter(function (placement) {\n return allowedAutoPlacements.indexOf(placement) >= 0;\n });\n\n if (allowedPlacements.length === 0) {\n allowedPlacements = placements;\n } // $FlowFixMe[incompatible-type]: Flow seems to have problems with two array unions...\n\n\n var overflows = allowedPlacements.reduce(function (acc, placement) {\n acc[placement] = detectOverflow(state, {\n placement: placement,\n boundary: boundary,\n rootBoundary: rootBoundary,\n padding: padding\n })[getBasePlacement(placement)];\n return acc;\n }, {});\n return Object.keys(overflows).sort(function (a, b) {\n return overflows[a] - overflows[b];\n });\n}","import getOppositePlacement from \"../utils/getOppositePlacement.js\";\nimport getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getOppositeVariationPlacement from \"../utils/getOppositeVariationPlacement.js\";\nimport detectOverflow from \"../utils/detectOverflow.js\";\nimport computeAutoPlacement from \"../utils/computeAutoPlacement.js\";\nimport { bottom, top, start, right, left, auto } from \"../enums.js\";\nimport getVariation from \"../utils/getVariation.js\"; // eslint-disable-next-line import/no-unused-modules\n\nfunction getExpandedFallbackPlacements(placement) {\n if (getBasePlacement(placement) === auto) {\n return [];\n }\n\n var oppositePlacement = getOppositePlacement(placement);\n return [getOppositeVariationPlacement(placement), oppositePlacement, getOppositeVariationPlacement(oppositePlacement)];\n}\n\nfunction flip(_ref) {\n var state = _ref.state,\n options = _ref.options,\n name = _ref.name;\n\n if (state.modifiersData[name]._skip) {\n return;\n }\n\n var _options$mainAxis = options.mainAxis,\n checkMainAxis = _options$mainAxis === void 0 ? true : _options$mainAxis,\n _options$altAxis = options.altAxis,\n checkAltAxis = _options$altAxis === void 0 ? true : _options$altAxis,\n specifiedFallbackPlacements = options.fallbackPlacements,\n padding = options.padding,\n boundary = options.boundary,\n rootBoundary = options.rootBoundary,\n altBoundary = options.altBoundary,\n _options$flipVariatio = options.flipVariations,\n flipVariations = _options$flipVariatio === void 0 ? true : _options$flipVariatio,\n allowedAutoPlacements = options.allowedAutoPlacements;\n var preferredPlacement = state.options.placement;\n var basePlacement = getBasePlacement(preferredPlacement);\n var isBasePlacement = basePlacement === preferredPlacement;\n var fallbackPlacements = specifiedFallbackPlacements || (isBasePlacement || !flipVariations ? [getOppositePlacement(preferredPlacement)] : getExpandedFallbackPlacements(preferredPlacement));\n var placements = [preferredPlacement].concat(fallbackPlacements).reduce(function (acc, placement) {\n return acc.concat(getBasePlacement(placement) === auto ? computeAutoPlacement(state, {\n placement: placement,\n boundary: boundary,\n rootBoundary: rootBoundary,\n padding: padding,\n flipVariations: flipVariations,\n allowedAutoPlacements: allowedAutoPlacements\n }) : placement);\n }, []);\n var referenceRect = state.rects.reference;\n var popperRect = state.rects.popper;\n var checksMap = new Map();\n var makeFallbackChecks = true;\n var firstFittingPlacement = placements[0];\n\n for (var i = 0; i < placements.length; i++) {\n var placement = placements[i];\n\n var _basePlacement = getBasePlacement(placement);\n\n var isStartVariation = getVariation(placement) === start;\n var isVertical = [top, bottom].indexOf(_basePlacement) >= 0;\n var len = isVertical ? 'width' : 'height';\n var overflow = detectOverflow(state, {\n placement: placement,\n boundary: boundary,\n rootBoundary: rootBoundary,\n altBoundary: altBoundary,\n padding: padding\n });\n var mainVariationSide = isVertical ? isStartVariation ? right : left : isStartVariation ? bottom : top;\n\n if (referenceRect[len] > popperRect[len]) {\n mainVariationSide = getOppositePlacement(mainVariationSide);\n }\n\n var altVariationSide = getOppositePlacement(mainVariationSide);\n var checks = [];\n\n if (checkMainAxis) {\n checks.push(overflow[_basePlacement] <= 0);\n }\n\n if (checkAltAxis) {\n checks.push(overflow[mainVariationSide] <= 0, overflow[altVariationSide] <= 0);\n }\n\n if (checks.every(function (check) {\n return check;\n })) {\n firstFittingPlacement = placement;\n makeFallbackChecks = false;\n break;\n }\n\n checksMap.set(placement, checks);\n }\n\n if (makeFallbackChecks) {\n // `2` may be desired in some cases – research later\n var numberOfChecks = flipVariations ? 3 : 1;\n\n var _loop = function _loop(_i) {\n var fittingPlacement = placements.find(function (placement) {\n var checks = checksMap.get(placement);\n\n if (checks) {\n return checks.slice(0, _i).every(function (check) {\n return check;\n });\n }\n });\n\n if (fittingPlacement) {\n firstFittingPlacement = fittingPlacement;\n return \"break\";\n }\n };\n\n for (var _i = numberOfChecks; _i > 0; _i--) {\n var _ret = _loop(_i);\n\n if (_ret === \"break\") break;\n }\n }\n\n if (state.placement !== firstFittingPlacement) {\n state.modifiersData[name]._skip = true;\n state.placement = firstFittingPlacement;\n state.reset = true;\n }\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'flip',\n enabled: true,\n phase: 'main',\n fn: flip,\n requiresIfExists: ['offset'],\n data: {\n _skip: false\n }\n};","import { top, bottom, left, right } from \"../enums.js\";\nimport detectOverflow from \"../utils/detectOverflow.js\";\n\nfunction getSideOffsets(overflow, rect, preventedOffsets) {\n if (preventedOffsets === void 0) {\n preventedOffsets = {\n x: 0,\n y: 0\n };\n }\n\n return {\n top: overflow.top - rect.height - preventedOffsets.y,\n right: overflow.right - rect.width + preventedOffsets.x,\n bottom: overflow.bottom - rect.height + preventedOffsets.y,\n left: overflow.left - rect.width - preventedOffsets.x\n };\n}\n\nfunction isAnySideFullyClipped(overflow) {\n return [top, right, bottom, left].some(function (side) {\n return overflow[side] >= 0;\n });\n}\n\nfunction hide(_ref) {\n var state = _ref.state,\n name = _ref.name;\n var referenceRect = state.rects.reference;\n var popperRect = state.rects.popper;\n var preventedOffsets = state.modifiersData.preventOverflow;\n var referenceOverflow = detectOverflow(state, {\n elementContext: 'reference'\n });\n var popperAltOverflow = detectOverflow(state, {\n altBoundary: true\n });\n var referenceClippingOffsets = getSideOffsets(referenceOverflow, referenceRect);\n var popperEscapeOffsets = getSideOffsets(popperAltOverflow, popperRect, preventedOffsets);\n var isReferenceHidden = isAnySideFullyClipped(referenceClippingOffsets);\n var hasPopperEscaped = isAnySideFullyClipped(popperEscapeOffsets);\n state.modifiersData[name] = {\n referenceClippingOffsets: referenceClippingOffsets,\n popperEscapeOffsets: popperEscapeOffsets,\n isReferenceHidden: isReferenceHidden,\n hasPopperEscaped: hasPopperEscaped\n };\n state.attributes.popper = Object.assign({}, state.attributes.popper, {\n 'data-popper-reference-hidden': isReferenceHidden,\n 'data-popper-escaped': hasPopperEscaped\n });\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'hide',\n enabled: true,\n phase: 'main',\n requiresIfExists: ['preventOverflow'],\n fn: hide\n};","import getBasePlacement from \"../utils/getBasePlacement.js\";\nimport { top, left, right, placements } from \"../enums.js\"; // eslint-disable-next-line import/no-unused-modules\n\nexport function distanceAndSkiddingToXY(placement, rects, offset) {\n var basePlacement = getBasePlacement(placement);\n var invertDistance = [left, top].indexOf(basePlacement) >= 0 ? -1 : 1;\n\n var _ref = typeof offset === 'function' ? offset(Object.assign({}, rects, {\n placement: placement\n })) : offset,\n skidding = _ref[0],\n distance = _ref[1];\n\n skidding = skidding || 0;\n distance = (distance || 0) * invertDistance;\n return [left, right].indexOf(basePlacement) >= 0 ? {\n x: distance,\n y: skidding\n } : {\n x: skidding,\n y: distance\n };\n}\n\nfunction offset(_ref2) {\n var state = _ref2.state,\n options = _ref2.options,\n name = _ref2.name;\n var _options$offset = options.offset,\n offset = _options$offset === void 0 ? [0, 0] : _options$offset;\n var data = placements.reduce(function (acc, placement) {\n acc[placement] = distanceAndSkiddingToXY(placement, state.rects, offset);\n return acc;\n }, {});\n var _data$state$placement = data[state.placement],\n x = _data$state$placement.x,\n y = _data$state$placement.y;\n\n if (state.modifiersData.popperOffsets != null) {\n state.modifiersData.popperOffsets.x += x;\n state.modifiersData.popperOffsets.y += y;\n }\n\n state.modifiersData[name] = data;\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'offset',\n enabled: true,\n phase: 'main',\n requires: ['popperOffsets'],\n fn: offset\n};","import computeOffsets from \"../utils/computeOffsets.js\";\n\nfunction popperOffsets(_ref) {\n var state = _ref.state,\n name = _ref.name;\n // Offsets are the actual position the popper needs to have to be\n // properly positioned near its reference element\n // This is the most basic placement, and will be adjusted by\n // the modifiers in the next step\n state.modifiersData[name] = computeOffsets({\n reference: state.rects.reference,\n element: state.rects.popper,\n strategy: 'absolute',\n placement: state.placement\n });\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'popperOffsets',\n enabled: true,\n phase: 'read',\n fn: popperOffsets,\n data: {}\n};","export default function getAltAxis(axis) {\n return axis === 'x' ? 'y' : 'x';\n}","import { top, left, right, bottom, start } from \"../enums.js\";\nimport getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getMainAxisFromPlacement from \"../utils/getMainAxisFromPlacement.js\";\nimport getAltAxis from \"../utils/getAltAxis.js\";\nimport { within, withinMaxClamp } from \"../utils/within.js\";\nimport getLayoutRect from \"../dom-utils/getLayoutRect.js\";\nimport getOffsetParent from \"../dom-utils/getOffsetParent.js\";\nimport detectOverflow from \"../utils/detectOverflow.js\";\nimport getVariation from \"../utils/getVariation.js\";\nimport getFreshSideObject from \"../utils/getFreshSideObject.js\";\nimport { min as mathMin, max as mathMax } from \"../utils/math.js\";\n\nfunction preventOverflow(_ref) {\n var state = _ref.state,\n options = _ref.options,\n name = _ref.name;\n var _options$mainAxis = options.mainAxis,\n checkMainAxis = _options$mainAxis === void 0 ? true : _options$mainAxis,\n _options$altAxis = options.altAxis,\n checkAltAxis = _options$altAxis === void 0 ? false : _options$altAxis,\n boundary = options.boundary,\n rootBoundary = options.rootBoundary,\n altBoundary = options.altBoundary,\n padding = options.padding,\n _options$tether = options.tether,\n tether = _options$tether === void 0 ? true : _options$tether,\n _options$tetherOffset = options.tetherOffset,\n tetherOffset = _options$tetherOffset === void 0 ? 0 : _options$tetherOffset;\n var overflow = detectOverflow(state, {\n boundary: boundary,\n rootBoundary: rootBoundary,\n padding: padding,\n altBoundary: altBoundary\n });\n var basePlacement = getBasePlacement(state.placement);\n var variation = getVariation(state.placement);\n var isBasePlacement = !variation;\n var mainAxis = getMainAxisFromPlacement(basePlacement);\n var altAxis = getAltAxis(mainAxis);\n var popperOffsets = state.modifiersData.popperOffsets;\n var referenceRect = state.rects.reference;\n var popperRect = state.rects.popper;\n var tetherOffsetValue = typeof tetherOffset === 'function' ? tetherOffset(Object.assign({}, state.rects, {\n placement: state.placement\n })) : tetherOffset;\n var normalizedTetherOffsetValue = typeof tetherOffsetValue === 'number' ? {\n mainAxis: tetherOffsetValue,\n altAxis: tetherOffsetValue\n } : Object.assign({\n mainAxis: 0,\n altAxis: 0\n }, tetherOffsetValue);\n var offsetModifierState = state.modifiersData.offset ? state.modifiersData.offset[state.placement] : null;\n var data = {\n x: 0,\n y: 0\n };\n\n if (!popperOffsets) {\n return;\n }\n\n if (checkMainAxis) {\n var _offsetModifierState$;\n\n var mainSide = mainAxis === 'y' ? top : left;\n var altSide = mainAxis === 'y' ? bottom : right;\n var len = mainAxis === 'y' ? 'height' : 'width';\n var offset = popperOffsets[mainAxis];\n var min = offset + overflow[mainSide];\n var max = offset - overflow[altSide];\n var additive = tether ? -popperRect[len] / 2 : 0;\n var minLen = variation === start ? referenceRect[len] : popperRect[len];\n var maxLen = variation === start ? -popperRect[len] : -referenceRect[len]; // We need to include the arrow in the calculation so the arrow doesn't go\n // outside the reference bounds\n\n var arrowElement = state.elements.arrow;\n var arrowRect = tether && arrowElement ? getLayoutRect(arrowElement) : {\n width: 0,\n height: 0\n };\n var arrowPaddingObject = state.modifiersData['arrow#persistent'] ? state.modifiersData['arrow#persistent'].padding : getFreshSideObject();\n var arrowPaddingMin = arrowPaddingObject[mainSide];\n var arrowPaddingMax = arrowPaddingObject[altSide]; // If the reference length is smaller than the arrow length, we don't want\n // to include its full size in the calculation. If the reference is small\n // and near the edge of a boundary, the popper can overflow even if the\n // reference is not overflowing as well (e.g. virtual elements with no\n // width or height)\n\n var arrowLen = within(0, referenceRect[len], arrowRect[len]);\n var minOffset = isBasePlacement ? referenceRect[len] / 2 - additive - arrowLen - arrowPaddingMin - normalizedTetherOffsetValue.mainAxis : minLen - arrowLen - arrowPaddingMin - normalizedTetherOffsetValue.mainAxis;\n var maxOffset = isBasePlacement ? -referenceRect[len] / 2 + additive + arrowLen + arrowPaddingMax + normalizedTetherOffsetValue.mainAxis : maxLen + arrowLen + arrowPaddingMax + normalizedTetherOffsetValue.mainAxis;\n var arrowOffsetParent = state.elements.arrow && getOffsetParent(state.elements.arrow);\n var clientOffset = arrowOffsetParent ? mainAxis === 'y' ? arrowOffsetParent.clientTop || 0 : arrowOffsetParent.clientLeft || 0 : 0;\n var offsetModifierValue = (_offsetModifierState$ = offsetModifierState == null ? void 0 : offsetModifierState[mainAxis]) != null ? _offsetModifierState$ : 0;\n var tetherMin = offset + minOffset - offsetModifierValue - clientOffset;\n var tetherMax = offset + maxOffset - offsetModifierValue;\n var preventedOffset = within(tether ? mathMin(min, tetherMin) : min, offset, tether ? mathMax(max, tetherMax) : max);\n popperOffsets[mainAxis] = preventedOffset;\n data[mainAxis] = preventedOffset - offset;\n }\n\n if (checkAltAxis) {\n var _offsetModifierState$2;\n\n var _mainSide = mainAxis === 'x' ? top : left;\n\n var _altSide = mainAxis === 'x' ? bottom : right;\n\n var _offset = popperOffsets[altAxis];\n\n var _len = altAxis === 'y' ? 'height' : 'width';\n\n var _min = _offset + overflow[_mainSide];\n\n var _max = _offset - overflow[_altSide];\n\n var isOriginSide = [top, left].indexOf(basePlacement) !== -1;\n\n var _offsetModifierValue = (_offsetModifierState$2 = offsetModifierState == null ? void 0 : offsetModifierState[altAxis]) != null ? _offsetModifierState$2 : 0;\n\n var _tetherMin = isOriginSide ? _min : _offset - referenceRect[_len] - popperRect[_len] - _offsetModifierValue + normalizedTetherOffsetValue.altAxis;\n\n var _tetherMax = isOriginSide ? _offset + referenceRect[_len] + popperRect[_len] - _offsetModifierValue - normalizedTetherOffsetValue.altAxis : _max;\n\n var _preventedOffset = tether && isOriginSide ? withinMaxClamp(_tetherMin, _offset, _tetherMax) : within(tether ? _tetherMin : _min, _offset, tether ? _tetherMax : _max);\n\n popperOffsets[altAxis] = _preventedOffset;\n data[altAxis] = _preventedOffset - _offset;\n }\n\n state.modifiersData[name] = data;\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'preventOverflow',\n enabled: true,\n phase: 'main',\n fn: preventOverflow,\n requiresIfExists: ['offset']\n};","export default function getHTMLElementScroll(element) {\n return {\n scrollLeft: element.scrollLeft,\n scrollTop: element.scrollTop\n };\n}","import getWindowScroll from \"./getWindowScroll.js\";\nimport getWindow from \"./getWindow.js\";\nimport { isHTMLElement } from \"./instanceOf.js\";\nimport getHTMLElementScroll from \"./getHTMLElementScroll.js\";\nexport default function getNodeScroll(node) {\n if (node === getWindow(node) || !isHTMLElement(node)) {\n return getWindowScroll(node);\n } else {\n return getHTMLElementScroll(node);\n }\n}","import getBoundingClientRect from \"./getBoundingClientRect.js\";\nimport getNodeScroll from \"./getNodeScroll.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport { isHTMLElement } from \"./instanceOf.js\";\nimport getWindowScrollBarX from \"./getWindowScrollBarX.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport isScrollParent from \"./isScrollParent.js\";\nimport { round } from \"../utils/math.js\";\n\nfunction isElementScaled(element) {\n var rect = element.getBoundingClientRect();\n var scaleX = round(rect.width) / element.offsetWidth || 1;\n var scaleY = round(rect.height) / element.offsetHeight || 1;\n return scaleX !== 1 || scaleY !== 1;\n} // Returns the composite rect of an element relative to its offsetParent.\n// Composite means it takes into account transforms as well as layout.\n\n\nexport default function getCompositeRect(elementOrVirtualElement, offsetParent, isFixed) {\n if (isFixed === void 0) {\n isFixed = false;\n }\n\n var isOffsetParentAnElement = isHTMLElement(offsetParent);\n var offsetParentIsScaled = isHTMLElement(offsetParent) && isElementScaled(offsetParent);\n var documentElement = getDocumentElement(offsetParent);\n var rect = getBoundingClientRect(elementOrVirtualElement, offsetParentIsScaled, isFixed);\n var scroll = {\n scrollLeft: 0,\n scrollTop: 0\n };\n var offsets = {\n x: 0,\n y: 0\n };\n\n if (isOffsetParentAnElement || !isOffsetParentAnElement && !isFixed) {\n if (getNodeName(offsetParent) !== 'body' || // https://github.com/popperjs/popper-core/issues/1078\n isScrollParent(documentElement)) {\n scroll = getNodeScroll(offsetParent);\n }\n\n if (isHTMLElement(offsetParent)) {\n offsets = getBoundingClientRect(offsetParent, true);\n offsets.x += offsetParent.clientLeft;\n offsets.y += offsetParent.clientTop;\n } else if (documentElement) {\n offsets.x = getWindowScrollBarX(documentElement);\n }\n }\n\n return {\n x: rect.left + scroll.scrollLeft - offsets.x,\n y: rect.top + scroll.scrollTop - offsets.y,\n width: rect.width,\n height: rect.height\n };\n}","import { modifierPhases } from \"../enums.js\"; // source: https://stackoverflow.com/questions/49875255\n\nfunction order(modifiers) {\n var map = new Map();\n var visited = new Set();\n var result = [];\n modifiers.forEach(function (modifier) {\n map.set(modifier.name, modifier);\n }); // On visiting object, check for its dependencies and visit them recursively\n\n function sort(modifier) {\n visited.add(modifier.name);\n var requires = [].concat(modifier.requires || [], modifier.requiresIfExists || []);\n requires.forEach(function (dep) {\n if (!visited.has(dep)) {\n var depModifier = map.get(dep);\n\n if (depModifier) {\n sort(depModifier);\n }\n }\n });\n result.push(modifier);\n }\n\n modifiers.forEach(function (modifier) {\n if (!visited.has(modifier.name)) {\n // check for visited object\n sort(modifier);\n }\n });\n return result;\n}\n\nexport default function orderModifiers(modifiers) {\n // order based on dependencies\n var orderedModifiers = order(modifiers); // order based on phase\n\n return modifierPhases.reduce(function (acc, phase) {\n return acc.concat(orderedModifiers.filter(function (modifier) {\n return modifier.phase === phase;\n }));\n }, []);\n}","export default function debounce(fn) {\n var pending;\n return function () {\n if (!pending) {\n pending = new Promise(function (resolve) {\n Promise.resolve().then(function () {\n pending = undefined;\n resolve(fn());\n });\n });\n }\n\n return pending;\n };\n}","export default function mergeByName(modifiers) {\n var merged = modifiers.reduce(function (merged, current) {\n var existing = merged[current.name];\n merged[current.name] = existing ? Object.assign({}, existing, current, {\n options: Object.assign({}, existing.options, current.options),\n data: Object.assign({}, existing.data, current.data)\n }) : current;\n return merged;\n }, {}); // IE11 does not support Object.values\n\n return Object.keys(merged).map(function (key) {\n return merged[key];\n });\n}","import getCompositeRect from \"./dom-utils/getCompositeRect.js\";\nimport getLayoutRect from \"./dom-utils/getLayoutRect.js\";\nimport listScrollParents from \"./dom-utils/listScrollParents.js\";\nimport getOffsetParent from \"./dom-utils/getOffsetParent.js\";\nimport orderModifiers from \"./utils/orderModifiers.js\";\nimport debounce from \"./utils/debounce.js\";\nimport mergeByName from \"./utils/mergeByName.js\";\nimport detectOverflow from \"./utils/detectOverflow.js\";\nimport { isElement } from \"./dom-utils/instanceOf.js\";\nvar DEFAULT_OPTIONS = {\n placement: 'bottom',\n modifiers: [],\n strategy: 'absolute'\n};\n\nfunction areValidElements() {\n for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {\n args[_key] = arguments[_key];\n }\n\n return !args.some(function (element) {\n return !(element && typeof element.getBoundingClientRect === 'function');\n });\n}\n\nexport function popperGenerator(generatorOptions) {\n if (generatorOptions === void 0) {\n generatorOptions = {};\n }\n\n var _generatorOptions = generatorOptions,\n _generatorOptions$def = _generatorOptions.defaultModifiers,\n defaultModifiers = _generatorOptions$def === void 0 ? [] : _generatorOptions$def,\n _generatorOptions$def2 = _generatorOptions.defaultOptions,\n defaultOptions = _generatorOptions$def2 === void 0 ? DEFAULT_OPTIONS : _generatorOptions$def2;\n return function createPopper(reference, popper, options) {\n if (options === void 0) {\n options = defaultOptions;\n }\n\n var state = {\n placement: 'bottom',\n orderedModifiers: [],\n options: Object.assign({}, DEFAULT_OPTIONS, defaultOptions),\n modifiersData: {},\n elements: {\n reference: reference,\n popper: popper\n },\n attributes: {},\n styles: {}\n };\n var effectCleanupFns = [];\n var isDestroyed = false;\n var instance = {\n state: state,\n setOptions: function setOptions(setOptionsAction) {\n var options = typeof setOptionsAction === 'function' ? setOptionsAction(state.options) : setOptionsAction;\n cleanupModifierEffects();\n state.options = Object.assign({}, defaultOptions, state.options, options);\n state.scrollParents = {\n reference: isElement(reference) ? listScrollParents(reference) : reference.contextElement ? listScrollParents(reference.contextElement) : [],\n popper: listScrollParents(popper)\n }; // Orders the modifiers based on their dependencies and `phase`\n // properties\n\n var orderedModifiers = orderModifiers(mergeByName([].concat(defaultModifiers, state.options.modifiers))); // Strip out disabled modifiers\n\n state.orderedModifiers = orderedModifiers.filter(function (m) {\n return m.enabled;\n });\n runModifierEffects();\n return instance.update();\n },\n // Sync update – it will always be executed, even if not necessary. This\n // is useful for low frequency updates where sync behavior simplifies the\n // logic.\n // For high frequency updates (e.g. `resize` and `scroll` events), always\n // prefer the async Popper#update method\n forceUpdate: function forceUpdate() {\n if (isDestroyed) {\n return;\n }\n\n var _state$elements = state.elements,\n reference = _state$elements.reference,\n popper = _state$elements.popper; // Don't proceed if `reference` or `popper` are not valid elements\n // anymore\n\n if (!areValidElements(reference, popper)) {\n return;\n } // Store the reference and popper rects to be read by modifiers\n\n\n state.rects = {\n reference: getCompositeRect(reference, getOffsetParent(popper), state.options.strategy === 'fixed'),\n popper: getLayoutRect(popper)\n }; // Modifiers have the ability to reset the current update cycle. The\n // most common use case for this is the `flip` modifier changing the\n // placement, which then needs to re-run all the modifiers, because the\n // logic was previously ran for the previous placement and is therefore\n // stale/incorrect\n\n state.reset = false;\n state.placement = state.options.placement; // On each update cycle, the `modifiersData` property for each modifier\n // is filled with the initial data specified by the modifier. This means\n // it doesn't persist and is fresh on each update.\n // To ensure persistent data, use `${name}#persistent`\n\n state.orderedModifiers.forEach(function (modifier) {\n return state.modifiersData[modifier.name] = Object.assign({}, modifier.data);\n });\n\n for (var index = 0; index < state.orderedModifiers.length; index++) {\n if (state.reset === true) {\n state.reset = false;\n index = -1;\n continue;\n }\n\n var _state$orderedModifie = state.orderedModifiers[index],\n fn = _state$orderedModifie.fn,\n _state$orderedModifie2 = _state$orderedModifie.options,\n _options = _state$orderedModifie2 === void 0 ? {} : _state$orderedModifie2,\n name = _state$orderedModifie.name;\n\n if (typeof fn === 'function') {\n state = fn({\n state: state,\n options: _options,\n name: name,\n instance: instance\n }) || state;\n }\n }\n },\n // Async and optimistically optimized update – it will not be executed if\n // not necessary (debounced to run at most once-per-tick)\n update: debounce(function () {\n return new Promise(function (resolve) {\n instance.forceUpdate();\n resolve(state);\n });\n }),\n destroy: function destroy() {\n cleanupModifierEffects();\n isDestroyed = true;\n }\n };\n\n if (!areValidElements(reference, popper)) {\n return instance;\n }\n\n instance.setOptions(options).then(function (state) {\n if (!isDestroyed && options.onFirstUpdate) {\n options.onFirstUpdate(state);\n }\n }); // Modifiers have the ability to execute arbitrary code before the first\n // update cycle runs. They will be executed in the same order as the update\n // cycle. This is useful when a modifier adds some persistent data that\n // other modifiers need to use, but the modifier is run after the dependent\n // one.\n\n function runModifierEffects() {\n state.orderedModifiers.forEach(function (_ref) {\n var name = _ref.name,\n _ref$options = _ref.options,\n options = _ref$options === void 0 ? {} : _ref$options,\n effect = _ref.effect;\n\n if (typeof effect === 'function') {\n var cleanupFn = effect({\n state: state,\n name: name,\n instance: instance,\n options: options\n });\n\n var noopFn = function noopFn() {};\n\n effectCleanupFns.push(cleanupFn || noopFn);\n }\n });\n }\n\n function cleanupModifierEffects() {\n effectCleanupFns.forEach(function (fn) {\n return fn();\n });\n effectCleanupFns = [];\n }\n\n return instance;\n };\n}\nexport var createPopper = /*#__PURE__*/popperGenerator(); // eslint-disable-next-line import/no-unused-modules\n\nexport { detectOverflow };","import { popperGenerator, detectOverflow } from \"./createPopper.js\";\nimport eventListeners from \"./modifiers/eventListeners.js\";\nimport popperOffsets from \"./modifiers/popperOffsets.js\";\nimport computeStyles from \"./modifiers/computeStyles.js\";\nimport applyStyles from \"./modifiers/applyStyles.js\";\nimport offset from \"./modifiers/offset.js\";\nimport flip from \"./modifiers/flip.js\";\nimport preventOverflow from \"./modifiers/preventOverflow.js\";\nimport arrow from \"./modifiers/arrow.js\";\nimport hide from \"./modifiers/hide.js\";\nvar defaultModifiers = [eventListeners, popperOffsets, computeStyles, applyStyles, offset, flip, preventOverflow, arrow, hide];\nvar createPopper = /*#__PURE__*/popperGenerator({\n defaultModifiers: defaultModifiers\n}); // eslint-disable-next-line import/no-unused-modules\n\nexport { createPopper, popperGenerator, defaultModifiers, detectOverflow }; // eslint-disable-next-line import/no-unused-modules\n\nexport { createPopper as createPopperLite } from \"./popper-lite.js\"; // eslint-disable-next-line import/no-unused-modules\n\nexport * from \"./modifiers/index.js\";","import { generateUtilityClass } from '../generateUtilityClass';\nimport { generateUtilityClasses } from '../generateUtilityClasses';\nconst COMPONENT_NAME = 'Popper';\nexport function getPopperUtilityClass(slot) {\n return generateUtilityClass(COMPONENT_NAME, slot);\n}\nexport const popperClasses = generateUtilityClasses(COMPONENT_NAME, ['root']);","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"anchorEl\", \"children\", \"direction\", \"disablePortal\", \"modifiers\", \"open\", \"placement\", \"popperOptions\", \"popperRef\", \"slotProps\", \"slots\", \"TransitionProps\", \"ownerState\"],\n _excluded2 = [\"anchorEl\", \"children\", \"container\", \"direction\", \"disablePortal\", \"keepMounted\", \"modifiers\", \"open\", \"placement\", \"popperOptions\", \"popperRef\", \"style\", \"transition\", \"slotProps\", \"slots\"];\nimport * as React from 'react';\nimport { chainPropTypes, HTMLElementType, refType, unstable_ownerDocument as ownerDocument, unstable_useEnhancedEffect as useEnhancedEffect, unstable_useForkRef as useForkRef } from '@mui/utils';\nimport { createPopper } from '@popperjs/core';\nimport PropTypes from 'prop-types';\nimport { unstable_composeClasses as composeClasses } from '../composeClasses';\nimport { Portal } from '../Portal';\nimport { getPopperUtilityClass } from './popperClasses';\nimport { useSlotProps } from '../utils';\nimport { useClassNamesOverride } from '../utils/ClassNameConfigurator';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nfunction flipPlacement(placement, direction) {\n if (direction === 'ltr') {\n return placement;\n }\n switch (placement) {\n case 'bottom-end':\n return 'bottom-start';\n case 'bottom-start':\n return 'bottom-end';\n case 'top-end':\n return 'top-start';\n case 'top-start':\n return 'top-end';\n default:\n return placement;\n }\n}\nfunction resolveAnchorEl(anchorEl) {\n return typeof anchorEl === 'function' ? anchorEl() : anchorEl;\n}\nfunction isHTMLElement(element) {\n return element.nodeType !== undefined;\n}\nfunction isVirtualElement(element) {\n return !isHTMLElement(element);\n}\nconst useUtilityClasses = () => {\n const slots = {\n root: ['root']\n };\n return composeClasses(slots, useClassNamesOverride(getPopperUtilityClass));\n};\nconst defaultPopperOptions = {};\nconst PopperTooltip = /*#__PURE__*/React.forwardRef(function PopperTooltip(props, forwardedRef) {\n var _slots$root;\n const {\n anchorEl,\n children,\n direction,\n disablePortal,\n modifiers,\n open,\n placement: initialPlacement,\n popperOptions,\n popperRef: popperRefProp,\n slotProps = {},\n slots = {},\n TransitionProps\n // @ts-ignore internal logic\n // prevent from spreading to DOM, it can come from the parent component e.g. Select.\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const tooltipRef = React.useRef(null);\n const ownRef = useForkRef(tooltipRef, forwardedRef);\n const popperRef = React.useRef(null);\n const handlePopperRef = useForkRef(popperRef, popperRefProp);\n const handlePopperRefRef = React.useRef(handlePopperRef);\n useEnhancedEffect(() => {\n handlePopperRefRef.current = handlePopperRef;\n }, [handlePopperRef]);\n React.useImperativeHandle(popperRefProp, () => popperRef.current, []);\n const rtlPlacement = flipPlacement(initialPlacement, direction);\n /**\n * placement initialized from prop but can change during lifetime if modifiers.flip.\n * modifiers.flip is essentially a flip for controlled/uncontrolled behavior\n */\n const [placement, setPlacement] = React.useState(rtlPlacement);\n const [resolvedAnchorElement, setResolvedAnchorElement] = React.useState(resolveAnchorEl(anchorEl));\n React.useEffect(() => {\n if (popperRef.current) {\n popperRef.current.forceUpdate();\n }\n });\n React.useEffect(() => {\n if (anchorEl) {\n setResolvedAnchorElement(resolveAnchorEl(anchorEl));\n }\n }, [anchorEl]);\n useEnhancedEffect(() => {\n if (!resolvedAnchorElement || !open) {\n return undefined;\n }\n const handlePopperUpdate = data => {\n setPlacement(data.placement);\n };\n if (process.env.NODE_ENV !== 'production') {\n if (resolvedAnchorElement && isHTMLElement(resolvedAnchorElement) && resolvedAnchorElement.nodeType === 1) {\n const box = resolvedAnchorElement.getBoundingClientRect();\n if (process.env.NODE_ENV !== 'test' && box.top === 0 && box.left === 0 && box.right === 0 && box.bottom === 0) {\n console.warn(['MUI: The `anchorEl` prop provided to the component is invalid.', 'The anchor element should be part of the document layout.', \"Make sure the element is present in the document or that it's not display none.\"].join('\\n'));\n }\n }\n }\n let popperModifiers = [{\n name: 'preventOverflow',\n options: {\n altBoundary: disablePortal\n }\n }, {\n name: 'flip',\n options: {\n altBoundary: disablePortal\n }\n }, {\n name: 'onUpdate',\n enabled: true,\n phase: 'afterWrite',\n fn: ({\n state\n }) => {\n handlePopperUpdate(state);\n }\n }];\n if (modifiers != null) {\n popperModifiers = popperModifiers.concat(modifiers);\n }\n if (popperOptions && popperOptions.modifiers != null) {\n popperModifiers = popperModifiers.concat(popperOptions.modifiers);\n }\n const popper = createPopper(resolvedAnchorElement, tooltipRef.current, _extends({\n placement: rtlPlacement\n }, popperOptions, {\n modifiers: popperModifiers\n }));\n handlePopperRefRef.current(popper);\n return () => {\n popper.destroy();\n handlePopperRefRef.current(null);\n };\n }, [resolvedAnchorElement, disablePortal, modifiers, open, popperOptions, rtlPlacement]);\n const childProps = {\n placement: placement\n };\n if (TransitionProps !== null) {\n childProps.TransitionProps = TransitionProps;\n }\n const classes = useUtilityClasses();\n const Root = (_slots$root = slots.root) != null ? _slots$root : 'div';\n const rootProps = useSlotProps({\n elementType: Root,\n externalSlotProps: slotProps.root,\n externalForwardedProps: other,\n additionalProps: {\n role: 'tooltip',\n ref: ownRef\n },\n ownerState: props,\n className: classes.root\n });\n return /*#__PURE__*/_jsx(Root, _extends({}, rootProps, {\n children: typeof children === 'function' ? children(childProps) : children\n }));\n});\n\n/**\n * Poppers rely on the 3rd party library [Popper.js](https://popper.js.org/docs/v2/) for positioning.\n *\n * Demos:\n *\n * - [Popper](https://mui.com/base-ui/react-popper/)\n *\n * API:\n *\n * - [Popper API](https://mui.com/base-ui/react-popper/components-api/#popper)\n */\nconst Popper = /*#__PURE__*/React.forwardRef(function Popper(props, forwardedRef) {\n const {\n anchorEl,\n children,\n container: containerProp,\n direction = 'ltr',\n disablePortal = false,\n keepMounted = false,\n modifiers,\n open,\n placement = 'bottom',\n popperOptions = defaultPopperOptions,\n popperRef,\n style,\n transition = false,\n slotProps = {},\n slots = {}\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded2);\n const [exited, setExited] = React.useState(true);\n const handleEnter = () => {\n setExited(false);\n };\n const handleExited = () => {\n setExited(true);\n };\n if (!keepMounted && !open && (!transition || exited)) {\n return null;\n }\n\n // If the container prop is provided, use that\n // If the anchorEl prop is provided, use its parent body element as the container\n // If neither are provided let the Modal take care of choosing the container\n let container;\n if (containerProp) {\n container = containerProp;\n } else if (anchorEl) {\n const resolvedAnchorEl = resolveAnchorEl(anchorEl);\n container = resolvedAnchorEl && isHTMLElement(resolvedAnchorEl) ? ownerDocument(resolvedAnchorEl).body : ownerDocument(null).body;\n }\n const display = !open && keepMounted && (!transition || exited) ? 'none' : undefined;\n const transitionProps = transition ? {\n in: open,\n onEnter: handleEnter,\n onExited: handleExited\n } : undefined;\n return /*#__PURE__*/_jsx(Portal, {\n disablePortal: disablePortal,\n container: container,\n children: /*#__PURE__*/_jsx(PopperTooltip, _extends({\n anchorEl: anchorEl,\n direction: direction,\n disablePortal: disablePortal,\n modifiers: modifiers,\n ref: forwardedRef,\n open: transition ? !exited : open,\n placement: placement,\n popperOptions: popperOptions,\n popperRef: popperRef,\n slotProps: slotProps,\n slots: slots\n }, other, {\n style: _extends({\n // Prevents scroll issue, waiting for Popper.js to add this style once initiated.\n position: 'fixed',\n // Fix Popper.js display issue\n top: 0,\n left: 0,\n display\n }, style),\n TransitionProps: transitionProps,\n children: children\n }))\n });\n});\nprocess.env.NODE_ENV !== \"production\" ? Popper.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * An HTML element, [virtualElement](https://popper.js.org/docs/v2/virtual-elements/),\n * or a function that returns either.\n * It's used to set the position of the popper.\n * The return value will passed as the reference object of the Popper instance.\n */\n anchorEl: chainPropTypes(PropTypes.oneOfType([HTMLElementType, PropTypes.object, PropTypes.func]), props => {\n if (props.open) {\n const resolvedAnchorEl = resolveAnchorEl(props.anchorEl);\n if (resolvedAnchorEl && isHTMLElement(resolvedAnchorEl) && resolvedAnchorEl.nodeType === 1) {\n const box = resolvedAnchorEl.getBoundingClientRect();\n if (process.env.NODE_ENV !== 'test' && box.top === 0 && box.left === 0 && box.right === 0 && box.bottom === 0) {\n return new Error(['MUI: The `anchorEl` prop provided to the component is invalid.', 'The anchor element should be part of the document layout.', \"Make sure the element is present in the document or that it's not display none.\"].join('\\n'));\n }\n } else if (!resolvedAnchorEl || typeof resolvedAnchorEl.getBoundingClientRect !== 'function' || isVirtualElement(resolvedAnchorEl) && resolvedAnchorEl.contextElement != null && resolvedAnchorEl.contextElement.nodeType !== 1) {\n return new Error(['MUI: The `anchorEl` prop provided to the component is invalid.', 'It should be an HTML element instance or a virtualElement ', '(https://popper.js.org/docs/v2/virtual-elements/).'].join('\\n'));\n }\n }\n return null;\n }),\n /**\n * Popper render function or node.\n */\n children: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.node, PropTypes.func]),\n /**\n * An HTML element or function that returns one.\n * The `container` will have the portal children appended to it.\n *\n * You can also provide a callback, which is called in a React layout effect.\n * This lets you set the container from a ref, and also makes server-side rendering possible.\n *\n * By default, it uses the body of the top-level document object,\n * so it's simply `document.body` most of the time.\n */\n container: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.func]),\n /**\n * Direction of the text.\n * @default 'ltr'\n */\n direction: PropTypes.oneOf(['ltr', 'rtl']),\n /**\n * The `children` will be under the DOM hierarchy of the parent component.\n * @default false\n */\n disablePortal: PropTypes.bool,\n /**\n * Always keep the children in the DOM.\n * This prop can be useful in SEO situation or\n * when you want to maximize the responsiveness of the Popper.\n * @default false\n */\n keepMounted: PropTypes.bool,\n /**\n * Popper.js is based on a \"plugin-like\" architecture,\n * most of its features are fully encapsulated \"modifiers\".\n *\n * A modifier is a function that is called each time Popper.js needs to\n * compute the position of the popper.\n * For this reason, modifiers should be very performant to avoid bottlenecks.\n * To learn how to create a modifier, [read the modifiers documentation](https://popper.js.org/docs/v2/modifiers/).\n */\n modifiers: PropTypes.arrayOf(PropTypes.shape({\n data: PropTypes.object,\n effect: PropTypes.func,\n enabled: PropTypes.bool,\n fn: PropTypes.func,\n name: PropTypes.any,\n options: PropTypes.object,\n phase: PropTypes.oneOf(['afterMain', 'afterRead', 'afterWrite', 'beforeMain', 'beforeRead', 'beforeWrite', 'main', 'read', 'write']),\n requires: PropTypes.arrayOf(PropTypes.string),\n requiresIfExists: PropTypes.arrayOf(PropTypes.string)\n })),\n /**\n * If `true`, the component is shown.\n */\n open: PropTypes.bool.isRequired,\n /**\n * Popper placement.\n * @default 'bottom'\n */\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n /**\n * Options provided to the [`Popper.js`](https://popper.js.org/docs/v2/constructors/#options) instance.\n * @default {}\n */\n popperOptions: PropTypes.shape({\n modifiers: PropTypes.array,\n onFirstUpdate: PropTypes.func,\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n strategy: PropTypes.oneOf(['absolute', 'fixed'])\n }),\n /**\n * A ref that points to the used popper instance.\n */\n popperRef: refType,\n /**\n * The props used for each slot inside the Popper.\n * @default {}\n */\n slotProps: PropTypes.shape({\n root: PropTypes.oneOfType([PropTypes.func, PropTypes.object])\n }),\n /**\n * The components used for each slot inside the Popper.\n * Either a string to use a HTML element or a component.\n * @default {}\n */\n slots: PropTypes.shape({\n root: PropTypes.elementType\n }),\n /**\n * Help supporting a react-transition-group/Transition component.\n * @default false\n */\n transition: PropTypes.bool\n} : void 0;\nexport { Popper };","'use client';\n\nimport * as React from 'react';\nimport { useTheme as useThemeSystem } from '@mui/system';\nimport defaultTheme from './defaultTheme';\nimport THEME_ID from './identifier';\nexport default function useTheme() {\n const theme = useThemeSystem(defaultTheme);\n if (process.env.NODE_ENV !== 'production') {\n // eslint-disable-next-line react-hooks/rules-of-hooks\n React.useDebugValue(theme);\n }\n return theme[THEME_ID] || theme;\n}","export default function _setPrototypeOf(o, p) {\n _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function _setPrototypeOf(o, p) {\n o.__proto__ = p;\n return o;\n };\n return _setPrototypeOf(o, p);\n}","import setPrototypeOf from \"./setPrototypeOf.js\";\nexport default function _inheritsLoose(subClass, superClass) {\n subClass.prototype = Object.create(superClass.prototype);\n subClass.prototype.constructor = subClass;\n setPrototypeOf(subClass, superClass);\n}","export default {\n disabled: false\n};","import PropTypes from 'prop-types';\nexport var timeoutsShape = process.env.NODE_ENV !== 'production' ? PropTypes.oneOfType([PropTypes.number, PropTypes.shape({\n enter: PropTypes.number,\n exit: PropTypes.number,\n appear: PropTypes.number\n}).isRequired]) : null;\nexport var classNamesShape = process.env.NODE_ENV !== 'production' ? PropTypes.oneOfType([PropTypes.string, PropTypes.shape({\n enter: PropTypes.string,\n exit: PropTypes.string,\n active: PropTypes.string\n}), PropTypes.shape({\n enter: PropTypes.string,\n enterDone: PropTypes.string,\n enterActive: PropTypes.string,\n exit: PropTypes.string,\n exitDone: PropTypes.string,\n exitActive: PropTypes.string\n})]) : null;","import React from 'react';\nexport default React.createContext(null);","export var forceReflow = function forceReflow(node) {\n return node.scrollTop;\n};","import _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _inheritsLoose from \"@babel/runtime/helpers/esm/inheritsLoose\";\nimport PropTypes from 'prop-types';\nimport React from 'react';\nimport ReactDOM from 'react-dom';\nimport config from './config';\nimport { timeoutsShape } from './utils/PropTypes';\nimport TransitionGroupContext from './TransitionGroupContext';\nimport { forceReflow } from './utils/reflow';\nexport var UNMOUNTED = 'unmounted';\nexport var EXITED = 'exited';\nexport var ENTERING = 'entering';\nexport var ENTERED = 'entered';\nexport var EXITING = 'exiting';\n/**\n * The Transition component lets you describe a transition from one component\n * state to another _over time_ with a simple declarative API. Most commonly\n * it's used to animate the mounting and unmounting of a component, but can also\n * be used to describe in-place transition states as well.\n *\n * ---\n *\n * **Note**: `Transition` is a platform-agnostic base component. If you're using\n * transitions in CSS, you'll probably want to use\n * [`CSSTransition`](https://reactcommunity.org/react-transition-group/css-transition)\n * instead. It inherits all the features of `Transition`, but contains\n * additional features necessary to play nice with CSS transitions (hence the\n * name of the component).\n *\n * ---\n *\n * By default the `Transition` component does not alter the behavior of the\n * component it renders, it only tracks \"enter\" and \"exit\" states for the\n * components. It's up to you to give meaning and effect to those states. For\n * example we can add styles to a component when it enters or exits:\n *\n * ```jsx\n * import { Transition } from 'react-transition-group';\n *\n * const duration = 300;\n *\n * const defaultStyle = {\n * transition: `opacity ${duration}ms ease-in-out`,\n * opacity: 0,\n * }\n *\n * const transitionStyles = {\n * entering: { opacity: 1 },\n * entered: { opacity: 1 },\n * exiting: { opacity: 0 },\n * exited: { opacity: 0 },\n * };\n *\n * const Fade = ({ in: inProp }) => (\n * \n * {state => (\n *
    \n * I'm a fade Transition!\n *
    \n * )}\n *
    \n * );\n * ```\n *\n * There are 4 main states a Transition can be in:\n * - `'entering'`\n * - `'entered'`\n * - `'exiting'`\n * - `'exited'`\n *\n * Transition state is toggled via the `in` prop. When `true` the component\n * begins the \"Enter\" stage. During this stage, the component will shift from\n * its current transition state, to `'entering'` for the duration of the\n * transition and then to the `'entered'` stage once it's complete. Let's take\n * the following example (we'll use the\n * [useState](https://reactjs.org/docs/hooks-reference.html#usestate) hook):\n *\n * ```jsx\n * function App() {\n * const [inProp, setInProp] = useState(false);\n * return (\n *
    \n * \n * {state => (\n * // ...\n * )}\n * \n * \n *
    \n * );\n * }\n * ```\n *\n * When the button is clicked the component will shift to the `'entering'` state\n * and stay there for 500ms (the value of `timeout`) before it finally switches\n * to `'entered'`.\n *\n * When `in` is `false` the same thing happens except the state moves from\n * `'exiting'` to `'exited'`.\n */\n\nvar Transition = /*#__PURE__*/function (_React$Component) {\n _inheritsLoose(Transition, _React$Component);\n\n function Transition(props, context) {\n var _this;\n\n _this = _React$Component.call(this, props, context) || this;\n var parentGroup = context; // In the context of a TransitionGroup all enters are really appears\n\n var appear = parentGroup && !parentGroup.isMounting ? props.enter : props.appear;\n var initialStatus;\n _this.appearStatus = null;\n\n if (props.in) {\n if (appear) {\n initialStatus = EXITED;\n _this.appearStatus = ENTERING;\n } else {\n initialStatus = ENTERED;\n }\n } else {\n if (props.unmountOnExit || props.mountOnEnter) {\n initialStatus = UNMOUNTED;\n } else {\n initialStatus = EXITED;\n }\n }\n\n _this.state = {\n status: initialStatus\n };\n _this.nextCallback = null;\n return _this;\n }\n\n Transition.getDerivedStateFromProps = function getDerivedStateFromProps(_ref, prevState) {\n var nextIn = _ref.in;\n\n if (nextIn && prevState.status === UNMOUNTED) {\n return {\n status: EXITED\n };\n }\n\n return null;\n } // getSnapshotBeforeUpdate(prevProps) {\n // let nextStatus = null\n // if (prevProps !== this.props) {\n // const { status } = this.state\n // if (this.props.in) {\n // if (status !== ENTERING && status !== ENTERED) {\n // nextStatus = ENTERING\n // }\n // } else {\n // if (status === ENTERING || status === ENTERED) {\n // nextStatus = EXITING\n // }\n // }\n // }\n // return { nextStatus }\n // }\n ;\n\n var _proto = Transition.prototype;\n\n _proto.componentDidMount = function componentDidMount() {\n this.updateStatus(true, this.appearStatus);\n };\n\n _proto.componentDidUpdate = function componentDidUpdate(prevProps) {\n var nextStatus = null;\n\n if (prevProps !== this.props) {\n var status = this.state.status;\n\n if (this.props.in) {\n if (status !== ENTERING && status !== ENTERED) {\n nextStatus = ENTERING;\n }\n } else {\n if (status === ENTERING || status === ENTERED) {\n nextStatus = EXITING;\n }\n }\n }\n\n this.updateStatus(false, nextStatus);\n };\n\n _proto.componentWillUnmount = function componentWillUnmount() {\n this.cancelNextCallback();\n };\n\n _proto.getTimeouts = function getTimeouts() {\n var timeout = this.props.timeout;\n var exit, enter, appear;\n exit = enter = appear = timeout;\n\n if (timeout != null && typeof timeout !== 'number') {\n exit = timeout.exit;\n enter = timeout.enter; // TODO: remove fallback for next major\n\n appear = timeout.appear !== undefined ? timeout.appear : enter;\n }\n\n return {\n exit: exit,\n enter: enter,\n appear: appear\n };\n };\n\n _proto.updateStatus = function updateStatus(mounting, nextStatus) {\n if (mounting === void 0) {\n mounting = false;\n }\n\n if (nextStatus !== null) {\n // nextStatus will always be ENTERING or EXITING.\n this.cancelNextCallback();\n\n if (nextStatus === ENTERING) {\n if (this.props.unmountOnExit || this.props.mountOnEnter) {\n var node = this.props.nodeRef ? this.props.nodeRef.current : ReactDOM.findDOMNode(this); // https://github.com/reactjs/react-transition-group/pull/749\n // With unmountOnExit or mountOnEnter, the enter animation should happen at the transition between `exited` and `entering`.\n // To make the animation happen, we have to separate each rendering and avoid being processed as batched.\n\n if (node) forceReflow(node);\n }\n\n this.performEnter(mounting);\n } else {\n this.performExit();\n }\n } else if (this.props.unmountOnExit && this.state.status === EXITED) {\n this.setState({\n status: UNMOUNTED\n });\n }\n };\n\n _proto.performEnter = function performEnter(mounting) {\n var _this2 = this;\n\n var enter = this.props.enter;\n var appearing = this.context ? this.context.isMounting : mounting;\n\n var _ref2 = this.props.nodeRef ? [appearing] : [ReactDOM.findDOMNode(this), appearing],\n maybeNode = _ref2[0],\n maybeAppearing = _ref2[1];\n\n var timeouts = this.getTimeouts();\n var enterTimeout = appearing ? timeouts.appear : timeouts.enter; // no enter animation skip right to ENTERED\n // if we are mounting and running this it means appear _must_ be set\n\n if (!mounting && !enter || config.disabled) {\n this.safeSetState({\n status: ENTERED\n }, function () {\n _this2.props.onEntered(maybeNode);\n });\n return;\n }\n\n this.props.onEnter(maybeNode, maybeAppearing);\n this.safeSetState({\n status: ENTERING\n }, function () {\n _this2.props.onEntering(maybeNode, maybeAppearing);\n\n _this2.onTransitionEnd(enterTimeout, function () {\n _this2.safeSetState({\n status: ENTERED\n }, function () {\n _this2.props.onEntered(maybeNode, maybeAppearing);\n });\n });\n });\n };\n\n _proto.performExit = function performExit() {\n var _this3 = this;\n\n var exit = this.props.exit;\n var timeouts = this.getTimeouts();\n var maybeNode = this.props.nodeRef ? undefined : ReactDOM.findDOMNode(this); // no exit animation skip right to EXITED\n\n if (!exit || config.disabled) {\n this.safeSetState({\n status: EXITED\n }, function () {\n _this3.props.onExited(maybeNode);\n });\n return;\n }\n\n this.props.onExit(maybeNode);\n this.safeSetState({\n status: EXITING\n }, function () {\n _this3.props.onExiting(maybeNode);\n\n _this3.onTransitionEnd(timeouts.exit, function () {\n _this3.safeSetState({\n status: EXITED\n }, function () {\n _this3.props.onExited(maybeNode);\n });\n });\n });\n };\n\n _proto.cancelNextCallback = function cancelNextCallback() {\n if (this.nextCallback !== null) {\n this.nextCallback.cancel();\n this.nextCallback = null;\n }\n };\n\n _proto.safeSetState = function safeSetState(nextState, callback) {\n // This shouldn't be necessary, but there are weird race conditions with\n // setState callbacks and unmounting in testing, so always make sure that\n // we can cancel any pending setState callbacks after we unmount.\n callback = this.setNextCallback(callback);\n this.setState(nextState, callback);\n };\n\n _proto.setNextCallback = function setNextCallback(callback) {\n var _this4 = this;\n\n var active = true;\n\n this.nextCallback = function (event) {\n if (active) {\n active = false;\n _this4.nextCallback = null;\n callback(event);\n }\n };\n\n this.nextCallback.cancel = function () {\n active = false;\n };\n\n return this.nextCallback;\n };\n\n _proto.onTransitionEnd = function onTransitionEnd(timeout, handler) {\n this.setNextCallback(handler);\n var node = this.props.nodeRef ? this.props.nodeRef.current : ReactDOM.findDOMNode(this);\n var doesNotHaveTimeoutOrListener = timeout == null && !this.props.addEndListener;\n\n if (!node || doesNotHaveTimeoutOrListener) {\n setTimeout(this.nextCallback, 0);\n return;\n }\n\n if (this.props.addEndListener) {\n var _ref3 = this.props.nodeRef ? [this.nextCallback] : [node, this.nextCallback],\n maybeNode = _ref3[0],\n maybeNextCallback = _ref3[1];\n\n this.props.addEndListener(maybeNode, maybeNextCallback);\n }\n\n if (timeout != null) {\n setTimeout(this.nextCallback, timeout);\n }\n };\n\n _proto.render = function render() {\n var status = this.state.status;\n\n if (status === UNMOUNTED) {\n return null;\n }\n\n var _this$props = this.props,\n children = _this$props.children,\n _in = _this$props.in,\n _mountOnEnter = _this$props.mountOnEnter,\n _unmountOnExit = _this$props.unmountOnExit,\n _appear = _this$props.appear,\n _enter = _this$props.enter,\n _exit = _this$props.exit,\n _timeout = _this$props.timeout,\n _addEndListener = _this$props.addEndListener,\n _onEnter = _this$props.onEnter,\n _onEntering = _this$props.onEntering,\n _onEntered = _this$props.onEntered,\n _onExit = _this$props.onExit,\n _onExiting = _this$props.onExiting,\n _onExited = _this$props.onExited,\n _nodeRef = _this$props.nodeRef,\n childProps = _objectWithoutPropertiesLoose(_this$props, [\"children\", \"in\", \"mountOnEnter\", \"unmountOnExit\", \"appear\", \"enter\", \"exit\", \"timeout\", \"addEndListener\", \"onEnter\", \"onEntering\", \"onEntered\", \"onExit\", \"onExiting\", \"onExited\", \"nodeRef\"]);\n\n return (\n /*#__PURE__*/\n // allows for nested Transitions\n React.createElement(TransitionGroupContext.Provider, {\n value: null\n }, typeof children === 'function' ? children(status, childProps) : React.cloneElement(React.Children.only(children), childProps))\n );\n };\n\n return Transition;\n}(React.Component);\n\nTransition.contextType = TransitionGroupContext;\nTransition.propTypes = process.env.NODE_ENV !== \"production\" ? {\n /**\n * A React reference to DOM element that need to transition:\n * https://stackoverflow.com/a/51127130/4671932\n *\n * - When `nodeRef` prop is used, `node` is not passed to callback functions\n * (e.g. `onEnter`) because user already has direct access to the node.\n * - When changing `key` prop of `Transition` in a `TransitionGroup` a new\n * `nodeRef` need to be provided to `Transition` with changed `key` prop\n * (see\n * [test/CSSTransition-test.js](https://github.com/reactjs/react-transition-group/blob/13435f897b3ab71f6e19d724f145596f5910581c/test/CSSTransition-test.js#L362-L437)).\n */\n nodeRef: PropTypes.shape({\n current: typeof Element === 'undefined' ? PropTypes.any : function (propValue, key, componentName, location, propFullName, secret) {\n var value = propValue[key];\n return PropTypes.instanceOf(value && 'ownerDocument' in value ? value.ownerDocument.defaultView.Element : Element)(propValue, key, componentName, location, propFullName, secret);\n }\n }),\n\n /**\n * A `function` child can be used instead of a React element. This function is\n * called with the current transition status (`'entering'`, `'entered'`,\n * `'exiting'`, `'exited'`), which can be used to apply context\n * specific props to a component.\n *\n * ```jsx\n * \n * {state => (\n * \n * )}\n * \n * ```\n */\n children: PropTypes.oneOfType([PropTypes.func.isRequired, PropTypes.element.isRequired]).isRequired,\n\n /**\n * Show the component; triggers the enter or exit states\n */\n in: PropTypes.bool,\n\n /**\n * By default the child component is mounted immediately along with\n * the parent `Transition` component. If you want to \"lazy mount\" the component on the\n * first `in={true}` you can set `mountOnEnter`. After the first enter transition the component will stay\n * mounted, even on \"exited\", unless you also specify `unmountOnExit`.\n */\n mountOnEnter: PropTypes.bool,\n\n /**\n * By default the child component stays mounted after it reaches the `'exited'` state.\n * Set `unmountOnExit` if you'd prefer to unmount the component after it finishes exiting.\n */\n unmountOnExit: PropTypes.bool,\n\n /**\n * By default the child component does not perform the enter transition when\n * it first mounts, regardless of the value of `in`. If you want this\n * behavior, set both `appear` and `in` to `true`.\n *\n * > **Note**: there are no special appear states like `appearing`/`appeared`, this prop\n * > only adds an additional enter transition. However, in the\n * > `` component that first enter transition does result in\n * > additional `.appear-*` classes, that way you can choose to style it\n * > differently.\n */\n appear: PropTypes.bool,\n\n /**\n * Enable or disable enter transitions.\n */\n enter: PropTypes.bool,\n\n /**\n * Enable or disable exit transitions.\n */\n exit: PropTypes.bool,\n\n /**\n * The duration of the transition, in milliseconds.\n * Required unless `addEndListener` is provided.\n *\n * You may specify a single timeout for all transitions:\n *\n * ```jsx\n * timeout={500}\n * ```\n *\n * or individually:\n *\n * ```jsx\n * timeout={{\n * appear: 500,\n * enter: 300,\n * exit: 500,\n * }}\n * ```\n *\n * - `appear` defaults to the value of `enter`\n * - `enter` defaults to `0`\n * - `exit` defaults to `0`\n *\n * @type {number | { enter?: number, exit?: number, appear?: number }}\n */\n timeout: function timeout(props) {\n var pt = timeoutsShape;\n if (!props.addEndListener) pt = pt.isRequired;\n\n for (var _len = arguments.length, args = new Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) {\n args[_key - 1] = arguments[_key];\n }\n\n return pt.apply(void 0, [props].concat(args));\n },\n\n /**\n * Add a custom transition end trigger. Called with the transitioning\n * DOM node and a `done` callback. Allows for more fine grained transition end\n * logic. Timeouts are still used as a fallback if provided.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * ```jsx\n * addEndListener={(node, done) => {\n * // use the css transitionend event to mark the finish of a transition\n * node.addEventListener('transitionend', done, false);\n * }}\n * ```\n */\n addEndListener: PropTypes.func,\n\n /**\n * Callback fired before the \"entering\" status is applied. An extra parameter\n * `isAppearing` is supplied to indicate if the enter stage is occurring on the initial mount\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement, isAppearing: bool) -> void\n */\n onEnter: PropTypes.func,\n\n /**\n * Callback fired after the \"entering\" status is applied. An extra parameter\n * `isAppearing` is supplied to indicate if the enter stage is occurring on the initial mount\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement, isAppearing: bool)\n */\n onEntering: PropTypes.func,\n\n /**\n * Callback fired after the \"entered\" status is applied. An extra parameter\n * `isAppearing` is supplied to indicate if the enter stage is occurring on the initial mount\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement, isAppearing: bool) -> void\n */\n onEntered: PropTypes.func,\n\n /**\n * Callback fired before the \"exiting\" status is applied.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement) -> void\n */\n onExit: PropTypes.func,\n\n /**\n * Callback fired after the \"exiting\" status is applied.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement) -> void\n */\n onExiting: PropTypes.func,\n\n /**\n * Callback fired after the \"exited\" status is applied.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed\n *\n * @type Function(node: HtmlElement) -> void\n */\n onExited: PropTypes.func\n} : {}; // Name the function so it is clearer in the documentation\n\nfunction noop() {}\n\nTransition.defaultProps = {\n in: false,\n mountOnEnter: false,\n unmountOnExit: false,\n appear: false,\n enter: true,\n exit: true,\n onEnter: noop,\n onEntering: noop,\n onEntered: noop,\n onExit: noop,\n onExiting: noop,\n onExited: noop\n};\nTransition.UNMOUNTED = UNMOUNTED;\nTransition.EXITED = EXITED;\nTransition.ENTERING = ENTERING;\nTransition.ENTERED = ENTERED;\nTransition.EXITING = EXITING;\nexport default Transition;","export const reflow = node => node.scrollTop;\nexport function getTransitionProps(props, options) {\n var _style$transitionDura, _style$transitionTimi;\n const {\n timeout,\n easing,\n style = {}\n } = props;\n return {\n duration: (_style$transitionDura = style.transitionDuration) != null ? _style$transitionDura : typeof timeout === 'number' ? timeout : timeout[options.mode] || 0,\n easing: (_style$transitionTimi = style.transitionTimingFunction) != null ? _style$transitionTimi : typeof easing === 'object' ? easing[options.mode] : easing,\n delay: style.transitionDelay\n };\n}","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"addEndListener\", \"appear\", \"children\", \"easing\", \"in\", \"onEnter\", \"onEntered\", \"onEntering\", \"onExit\", \"onExited\", \"onExiting\", \"style\", \"timeout\", \"TransitionComponent\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport { elementAcceptingRef, unstable_useTimeout as useTimeout } from '@mui/utils';\nimport { Transition } from 'react-transition-group';\nimport useTheme from '../styles/useTheme';\nimport { getTransitionProps, reflow } from '../transitions/utils';\nimport useForkRef from '../utils/useForkRef';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nfunction getScale(value) {\n return `scale(${value}, ${value ** 2})`;\n}\nconst styles = {\n entering: {\n opacity: 1,\n transform: getScale(1)\n },\n entered: {\n opacity: 1,\n transform: 'none'\n }\n};\n\n/*\n TODO v6: remove\n Conditionally apply a workaround for the CSS transition bug in Safari 15.4 / WebKit browsers.\n */\nconst isWebKit154 = typeof navigator !== 'undefined' && /^((?!chrome|android).)*(safari|mobile)/i.test(navigator.userAgent) && /(os |version\\/)15(.|_)4/i.test(navigator.userAgent);\n\n/**\n * The Grow transition is used by the [Tooltip](/material-ui/react-tooltip/) and\n * [Popover](/material-ui/react-popover/) components.\n * It uses [react-transition-group](https://github.com/reactjs/react-transition-group) internally.\n */\nconst Grow = /*#__PURE__*/React.forwardRef(function Grow(props, ref) {\n const {\n addEndListener,\n appear = true,\n children,\n easing,\n in: inProp,\n onEnter,\n onEntered,\n onEntering,\n onExit,\n onExited,\n onExiting,\n style,\n timeout = 'auto',\n // eslint-disable-next-line react/prop-types\n TransitionComponent = Transition\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const timer = useTimeout();\n const autoTimeout = React.useRef();\n const theme = useTheme();\n const nodeRef = React.useRef(null);\n const handleRef = useForkRef(nodeRef, children.ref, ref);\n const normalizedTransitionCallback = callback => maybeIsAppearing => {\n if (callback) {\n const node = nodeRef.current;\n\n // onEnterXxx and onExitXxx callbacks have a different arguments.length value.\n if (maybeIsAppearing === undefined) {\n callback(node);\n } else {\n callback(node, maybeIsAppearing);\n }\n }\n };\n const handleEntering = normalizedTransitionCallback(onEntering);\n const handleEnter = normalizedTransitionCallback((node, isAppearing) => {\n reflow(node); // So the animation always start from the start.\n\n const {\n duration: transitionDuration,\n delay,\n easing: transitionTimingFunction\n } = getTransitionProps({\n style,\n timeout,\n easing\n }, {\n mode: 'enter'\n });\n let duration;\n if (timeout === 'auto') {\n duration = theme.transitions.getAutoHeightDuration(node.clientHeight);\n autoTimeout.current = duration;\n } else {\n duration = transitionDuration;\n }\n node.style.transition = [theme.transitions.create('opacity', {\n duration,\n delay\n }), theme.transitions.create('transform', {\n duration: isWebKit154 ? duration : duration * 0.666,\n delay,\n easing: transitionTimingFunction\n })].join(',');\n if (onEnter) {\n onEnter(node, isAppearing);\n }\n });\n const handleEntered = normalizedTransitionCallback(onEntered);\n const handleExiting = normalizedTransitionCallback(onExiting);\n const handleExit = normalizedTransitionCallback(node => {\n const {\n duration: transitionDuration,\n delay,\n easing: transitionTimingFunction\n } = getTransitionProps({\n style,\n timeout,\n easing\n }, {\n mode: 'exit'\n });\n let duration;\n if (timeout === 'auto') {\n duration = theme.transitions.getAutoHeightDuration(node.clientHeight);\n autoTimeout.current = duration;\n } else {\n duration = transitionDuration;\n }\n node.style.transition = [theme.transitions.create('opacity', {\n duration,\n delay\n }), theme.transitions.create('transform', {\n duration: isWebKit154 ? duration : duration * 0.666,\n delay: isWebKit154 ? delay : delay || duration * 0.333,\n easing: transitionTimingFunction\n })].join(',');\n node.style.opacity = 0;\n node.style.transform = getScale(0.75);\n if (onExit) {\n onExit(node);\n }\n });\n const handleExited = normalizedTransitionCallback(onExited);\n const handleAddEndListener = next => {\n if (timeout === 'auto') {\n timer.start(autoTimeout.current || 0, next);\n }\n if (addEndListener) {\n // Old call signature before `react-transition-group` implemented `nodeRef`\n addEndListener(nodeRef.current, next);\n }\n };\n return /*#__PURE__*/_jsx(TransitionComponent, _extends({\n appear: appear,\n in: inProp,\n nodeRef: nodeRef,\n onEnter: handleEnter,\n onEntered: handleEntered,\n onEntering: handleEntering,\n onExit: handleExit,\n onExited: handleExited,\n onExiting: handleExiting,\n addEndListener: handleAddEndListener,\n timeout: timeout === 'auto' ? null : timeout\n }, other, {\n children: (state, childProps) => {\n return /*#__PURE__*/React.cloneElement(children, _extends({\n style: _extends({\n opacity: 0,\n transform: getScale(0.75),\n visibility: state === 'exited' && !inProp ? 'hidden' : undefined\n }, styles[state], style, children.props.style),\n ref: handleRef\n }, childProps));\n }\n }));\n});\nprocess.env.NODE_ENV !== \"production\" ? Grow.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the d.ts file and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * Add a custom transition end trigger. Called with the transitioning DOM\n * node and a done callback. Allows for more fine grained transition end\n * logic. Note: Timeouts are still used as a fallback if provided.\n */\n addEndListener: PropTypes.func,\n /**\n * Perform the enter transition when it first mounts if `in` is also `true`.\n * Set this to `false` to disable this behavior.\n * @default true\n */\n appear: PropTypes.bool,\n /**\n * A single child content element.\n */\n children: elementAcceptingRef.isRequired,\n /**\n * The transition timing function.\n * You may specify a single easing or a object containing enter and exit values.\n */\n easing: PropTypes.oneOfType([PropTypes.shape({\n enter: PropTypes.string,\n exit: PropTypes.string\n }), PropTypes.string]),\n /**\n * If `true`, the component will transition in.\n */\n in: PropTypes.bool,\n /**\n * @ignore\n */\n onEnter: PropTypes.func,\n /**\n * @ignore\n */\n onEntered: PropTypes.func,\n /**\n * @ignore\n */\n onEntering: PropTypes.func,\n /**\n * @ignore\n */\n onExit: PropTypes.func,\n /**\n * @ignore\n */\n onExited: PropTypes.func,\n /**\n * @ignore\n */\n onExiting: PropTypes.func,\n /**\n * @ignore\n */\n style: PropTypes.object,\n /**\n * The duration for the transition, in milliseconds.\n * You may specify a single timeout for all transitions, or individually with an object.\n *\n * Set to 'auto' to automatically calculate transition time based on height.\n * @default 'auto'\n */\n timeout: PropTypes.oneOfType([PropTypes.oneOf(['auto']), PropTypes.number, PropTypes.shape({\n appear: PropTypes.number,\n enter: PropTypes.number,\n exit: PropTypes.number\n })])\n} : void 0;\nGrow.muiSupportAuto = true;\nexport default Grow;","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"anchorEl\", \"component\", \"components\", \"componentsProps\", \"container\", \"disablePortal\", \"keepMounted\", \"modifiers\", \"open\", \"placement\", \"popperOptions\", \"popperRef\", \"transition\", \"slots\", \"slotProps\"];\nimport { Popper as BasePopper } from '@mui/base/Popper';\nimport { useThemeWithoutDefault as useTheme } from '@mui/system';\nimport { HTMLElementType, refType } from '@mui/utils';\nimport PropTypes from 'prop-types';\nimport * as React from 'react';\nimport { styled, useThemeProps } from '../styles';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nconst PopperRoot = styled(BasePopper, {\n name: 'MuiPopper',\n slot: 'Root',\n overridesResolver: (props, styles) => styles.root\n})({});\n\n/**\n *\n * Demos:\n *\n * - [Autocomplete](https://mui.com/material-ui/react-autocomplete/)\n * - [Menu](https://mui.com/material-ui/react-menu/)\n * - [Popper](https://mui.com/material-ui/react-popper/)\n *\n * API:\n *\n * - [Popper API](https://mui.com/material-ui/api/popper/)\n */\nconst Popper = /*#__PURE__*/React.forwardRef(function Popper(inProps, ref) {\n var _slots$root;\n const theme = useTheme();\n const props = useThemeProps({\n props: inProps,\n name: 'MuiPopper'\n });\n const {\n anchorEl,\n component,\n components,\n componentsProps,\n container,\n disablePortal,\n keepMounted,\n modifiers,\n open,\n placement,\n popperOptions,\n popperRef,\n transition,\n slots,\n slotProps\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const RootComponent = (_slots$root = slots == null ? void 0 : slots.root) != null ? _slots$root : components == null ? void 0 : components.Root;\n const otherProps = _extends({\n anchorEl,\n container,\n disablePortal,\n keepMounted,\n modifiers,\n open,\n placement,\n popperOptions,\n popperRef,\n transition\n }, other);\n return /*#__PURE__*/_jsx(PopperRoot, _extends({\n as: component,\n direction: theme == null ? void 0 : theme.direction,\n slots: {\n root: RootComponent\n },\n slotProps: slotProps != null ? slotProps : componentsProps\n }, otherProps, {\n ref: ref\n }));\n});\nprocess.env.NODE_ENV !== \"production\" ? Popper.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * An HTML element, [virtualElement](https://popper.js.org/docs/v2/virtual-elements/),\n * or a function that returns either.\n * It's used to set the position of the popper.\n * The return value will passed as the reference object of the Popper instance.\n */\n anchorEl: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.object, PropTypes.func]),\n /**\n * Popper render function or node.\n */\n children: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.node, PropTypes.func]),\n /**\n * The component used for the root node.\n * Either a string to use a HTML element or a component.\n */\n component: PropTypes.elementType,\n /**\n * The components used for each slot inside the Popper.\n * Either a string to use a HTML element or a component.\n * @default {}\n */\n components: PropTypes.shape({\n Root: PropTypes.elementType\n }),\n /**\n * The props used for each slot inside the Popper.\n * @default {}\n */\n componentsProps: PropTypes.shape({\n root: PropTypes.oneOfType([PropTypes.func, PropTypes.object])\n }),\n /**\n * An HTML element or function that returns one.\n * The `container` will have the portal children appended to it.\n *\n * You can also provide a callback, which is called in a React layout effect.\n * This lets you set the container from a ref, and also makes server-side rendering possible.\n *\n * By default, it uses the body of the top-level document object,\n * so it's simply `document.body` most of the time.\n */\n container: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.func]),\n /**\n * The `children` will be under the DOM hierarchy of the parent component.\n * @default false\n */\n disablePortal: PropTypes.bool,\n /**\n * Always keep the children in the DOM.\n * This prop can be useful in SEO situation or\n * when you want to maximize the responsiveness of the Popper.\n * @default false\n */\n keepMounted: PropTypes.bool,\n /**\n * Popper.js is based on a \"plugin-like\" architecture,\n * most of its features are fully encapsulated \"modifiers\".\n *\n * A modifier is a function that is called each time Popper.js needs to\n * compute the position of the popper.\n * For this reason, modifiers should be very performant to avoid bottlenecks.\n * To learn how to create a modifier, [read the modifiers documentation](https://popper.js.org/docs/v2/modifiers/).\n */\n modifiers: PropTypes.arrayOf(PropTypes.shape({\n data: PropTypes.object,\n effect: PropTypes.func,\n enabled: PropTypes.bool,\n fn: PropTypes.func,\n name: PropTypes.any,\n options: PropTypes.object,\n phase: PropTypes.oneOf(['afterMain', 'afterRead', 'afterWrite', 'beforeMain', 'beforeRead', 'beforeWrite', 'main', 'read', 'write']),\n requires: PropTypes.arrayOf(PropTypes.string),\n requiresIfExists: PropTypes.arrayOf(PropTypes.string)\n })),\n /**\n * If `true`, the component is shown.\n */\n open: PropTypes.bool.isRequired,\n /**\n * Popper placement.\n * @default 'bottom'\n */\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n /**\n * Options provided to the [`Popper.js`](https://popper.js.org/docs/v2/constructors/#options) instance.\n * @default {}\n */\n popperOptions: PropTypes.shape({\n modifiers: PropTypes.array,\n onFirstUpdate: PropTypes.func,\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n strategy: PropTypes.oneOf(['absolute', 'fixed'])\n }),\n /**\n * A ref that points to the used popper instance.\n */\n popperRef: refType,\n /**\n * The props used for each slot inside the Popper.\n * @default {}\n */\n slotProps: PropTypes.shape({\n root: PropTypes.oneOfType([PropTypes.func, PropTypes.object])\n }),\n /**\n * The components used for each slot inside the Popper.\n * Either a string to use a HTML element or a component.\n * @default {}\n */\n slots: PropTypes.shape({\n root: PropTypes.elementType\n }),\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Help supporting a react-transition-group/Transition component.\n * @default false\n */\n transition: PropTypes.bool\n} : void 0;\nexport default Popper;","import generateUtilityClasses from '@mui/utils/generateUtilityClasses';\nimport generateUtilityClass from '@mui/utils/generateUtilityClass';\nexport function getTooltipUtilityClass(slot) {\n return generateUtilityClass('MuiTooltip', slot);\n}\nconst tooltipClasses = generateUtilityClasses('MuiTooltip', ['popper', 'popperInteractive', 'popperArrow', 'popperClose', 'tooltip', 'tooltipArrow', 'touch', 'tooltipPlacementLeft', 'tooltipPlacementRight', 'tooltipPlacementTop', 'tooltipPlacementBottom', 'arrow']);\nexport default tooltipClasses;","'use client';\n\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nconst _excluded = [\"arrow\", \"children\", \"classes\", \"components\", \"componentsProps\", \"describeChild\", \"disableFocusListener\", \"disableHoverListener\", \"disableInteractive\", \"disableTouchListener\", \"enterDelay\", \"enterNextDelay\", \"enterTouchDelay\", \"followCursor\", \"id\", \"leaveDelay\", \"leaveTouchDelay\", \"onClose\", \"onOpen\", \"open\", \"placement\", \"PopperComponent\", \"PopperProps\", \"slotProps\", \"slots\", \"title\", \"TransitionComponent\", \"TransitionProps\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport clsx from 'clsx';\nimport { elementAcceptingRef, unstable_useTimeout as useTimeout, unstable_Timeout as Timeout } from '@mui/utils';\nimport { unstable_composeClasses as composeClasses, appendOwnerState } from '@mui/base';\nimport { alpha } from '@mui/system';\nimport styled from '../styles/styled';\nimport useTheme from '../styles/useTheme';\nimport useThemeProps from '../styles/useThemeProps';\nimport capitalize from '../utils/capitalize';\nimport Grow from '../Grow';\nimport Popper from '../Popper';\nimport useEventCallback from '../utils/useEventCallback';\nimport useForkRef from '../utils/useForkRef';\nimport useId from '../utils/useId';\nimport useIsFocusVisible from '../utils/useIsFocusVisible';\nimport useControlled from '../utils/useControlled';\nimport tooltipClasses, { getTooltipUtilityClass } from './tooltipClasses';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nimport { jsxs as _jsxs } from \"react/jsx-runtime\";\nfunction round(value) {\n return Math.round(value * 1e5) / 1e5;\n}\nconst useUtilityClasses = ownerState => {\n const {\n classes,\n disableInteractive,\n arrow,\n touch,\n placement\n } = ownerState;\n const slots = {\n popper: ['popper', !disableInteractive && 'popperInteractive', arrow && 'popperArrow'],\n tooltip: ['tooltip', arrow && 'tooltipArrow', touch && 'touch', `tooltipPlacement${capitalize(placement.split('-')[0])}`],\n arrow: ['arrow']\n };\n return composeClasses(slots, getTooltipUtilityClass, classes);\n};\nconst TooltipPopper = styled(Popper, {\n name: 'MuiTooltip',\n slot: 'Popper',\n overridesResolver: (props, styles) => {\n const {\n ownerState\n } = props;\n return [styles.popper, !ownerState.disableInteractive && styles.popperInteractive, ownerState.arrow && styles.popperArrow, !ownerState.open && styles.popperClose];\n }\n})(({\n theme,\n ownerState,\n open\n}) => _extends({\n zIndex: (theme.vars || theme).zIndex.tooltip,\n pointerEvents: 'none'\n}, !ownerState.disableInteractive && {\n pointerEvents: 'auto'\n}, !open && {\n pointerEvents: 'none'\n}, ownerState.arrow && {\n [`&[data-popper-placement*=\"bottom\"] .${tooltipClasses.arrow}`]: {\n top: 0,\n marginTop: '-0.71em',\n '&::before': {\n transformOrigin: '0 100%'\n }\n },\n [`&[data-popper-placement*=\"top\"] .${tooltipClasses.arrow}`]: {\n bottom: 0,\n marginBottom: '-0.71em',\n '&::before': {\n transformOrigin: '100% 0'\n }\n },\n [`&[data-popper-placement*=\"right\"] .${tooltipClasses.arrow}`]: _extends({}, !ownerState.isRtl ? {\n left: 0,\n marginLeft: '-0.71em'\n } : {\n right: 0,\n marginRight: '-0.71em'\n }, {\n height: '1em',\n width: '0.71em',\n '&::before': {\n transformOrigin: '100% 100%'\n }\n }),\n [`&[data-popper-placement*=\"left\"] .${tooltipClasses.arrow}`]: _extends({}, !ownerState.isRtl ? {\n right: 0,\n marginRight: '-0.71em'\n } : {\n left: 0,\n marginLeft: '-0.71em'\n }, {\n height: '1em',\n width: '0.71em',\n '&::before': {\n transformOrigin: '0 0'\n }\n })\n}));\nconst TooltipTooltip = styled('div', {\n name: 'MuiTooltip',\n slot: 'Tooltip',\n overridesResolver: (props, styles) => {\n const {\n ownerState\n } = props;\n return [styles.tooltip, ownerState.touch && styles.touch, ownerState.arrow && styles.tooltipArrow, styles[`tooltipPlacement${capitalize(ownerState.placement.split('-')[0])}`]];\n }\n})(({\n theme,\n ownerState\n}) => _extends({\n backgroundColor: theme.vars ? theme.vars.palette.Tooltip.bg : alpha(theme.palette.grey[700], 0.92),\n borderRadius: (theme.vars || theme).shape.borderRadius,\n color: (theme.vars || theme).palette.common.white,\n fontFamily: theme.typography.fontFamily,\n padding: '4px 8px',\n fontSize: theme.typography.pxToRem(11),\n maxWidth: 300,\n margin: 2,\n wordWrap: 'break-word',\n fontWeight: theme.typography.fontWeightMedium\n}, ownerState.arrow && {\n position: 'relative',\n margin: 0\n}, ownerState.touch && {\n padding: '8px 16px',\n fontSize: theme.typography.pxToRem(14),\n lineHeight: `${round(16 / 14)}em`,\n fontWeight: theme.typography.fontWeightRegular\n}, {\n [`.${tooltipClasses.popper}[data-popper-placement*=\"left\"] &`]: _extends({\n transformOrigin: 'right center'\n }, !ownerState.isRtl ? _extends({\n marginRight: '14px'\n }, ownerState.touch && {\n marginRight: '24px'\n }) : _extends({\n marginLeft: '14px'\n }, ownerState.touch && {\n marginLeft: '24px'\n })),\n [`.${tooltipClasses.popper}[data-popper-placement*=\"right\"] &`]: _extends({\n transformOrigin: 'left center'\n }, !ownerState.isRtl ? _extends({\n marginLeft: '14px'\n }, ownerState.touch && {\n marginLeft: '24px'\n }) : _extends({\n marginRight: '14px'\n }, ownerState.touch && {\n marginRight: '24px'\n })),\n [`.${tooltipClasses.popper}[data-popper-placement*=\"top\"] &`]: _extends({\n transformOrigin: 'center bottom',\n marginBottom: '14px'\n }, ownerState.touch && {\n marginBottom: '24px'\n }),\n [`.${tooltipClasses.popper}[data-popper-placement*=\"bottom\"] &`]: _extends({\n transformOrigin: 'center top',\n marginTop: '14px'\n }, ownerState.touch && {\n marginTop: '24px'\n })\n}));\nconst TooltipArrow = styled('span', {\n name: 'MuiTooltip',\n slot: 'Arrow',\n overridesResolver: (props, styles) => styles.arrow\n})(({\n theme\n}) => ({\n overflow: 'hidden',\n position: 'absolute',\n width: '1em',\n height: '0.71em' /* = width / sqrt(2) = (length of the hypotenuse) */,\n boxSizing: 'border-box',\n color: theme.vars ? theme.vars.palette.Tooltip.bg : alpha(theme.palette.grey[700], 0.9),\n '&::before': {\n content: '\"\"',\n margin: 'auto',\n display: 'block',\n width: '100%',\n height: '100%',\n backgroundColor: 'currentColor',\n transform: 'rotate(45deg)'\n }\n}));\nlet hystersisOpen = false;\nconst hystersisTimer = new Timeout();\nlet cursorPosition = {\n x: 0,\n y: 0\n};\nexport function testReset() {\n hystersisOpen = false;\n hystersisTimer.clear();\n}\nfunction composeEventHandler(handler, eventHandler) {\n return event => {\n if (eventHandler) {\n eventHandler(event);\n }\n handler(event);\n };\n}\n\n// TODO v6: Remove PopperComponent, PopperProps, TransitionComponent and TransitionProps.\nconst Tooltip = /*#__PURE__*/React.forwardRef(function Tooltip(inProps, ref) {\n var _ref, _slots$popper, _ref2, _ref3, _slots$transition, _ref4, _slots$tooltip, _ref5, _slots$arrow, _slotProps$popper, _ref6, _slotProps$popper2, _slotProps$transition, _slotProps$tooltip, _ref7, _slotProps$tooltip2, _slotProps$arrow, _ref8, _slotProps$arrow2;\n const props = useThemeProps({\n props: inProps,\n name: 'MuiTooltip'\n });\n const {\n arrow = false,\n children: childrenProp,\n components = {},\n componentsProps = {},\n describeChild = false,\n disableFocusListener = false,\n disableHoverListener = false,\n disableInteractive: disableInteractiveProp = false,\n disableTouchListener = false,\n enterDelay = 100,\n enterNextDelay = 0,\n enterTouchDelay = 700,\n followCursor = false,\n id: idProp,\n leaveDelay = 0,\n leaveTouchDelay = 1500,\n onClose,\n onOpen,\n open: openProp,\n placement = 'bottom',\n PopperComponent: PopperComponentProp,\n PopperProps = {},\n slotProps = {},\n slots = {},\n title,\n TransitionComponent: TransitionComponentProp = Grow,\n TransitionProps\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n\n // to prevent runtime errors, developers will need to provide a child as a React element anyway.\n const children = /*#__PURE__*/React.isValidElement(childrenProp) ? childrenProp : /*#__PURE__*/_jsx(\"span\", {\n children: childrenProp\n });\n const theme = useTheme();\n const isRtl = theme.direction === 'rtl';\n const [childNode, setChildNode] = React.useState();\n const [arrowRef, setArrowRef] = React.useState(null);\n const ignoreNonTouchEvents = React.useRef(false);\n const disableInteractive = disableInteractiveProp || followCursor;\n const closeTimer = useTimeout();\n const enterTimer = useTimeout();\n const leaveTimer = useTimeout();\n const touchTimer = useTimeout();\n const [openState, setOpenState] = useControlled({\n controlled: openProp,\n default: false,\n name: 'Tooltip',\n state: 'open'\n });\n let open = openState;\n if (process.env.NODE_ENV !== 'production') {\n // eslint-disable-next-line react-hooks/rules-of-hooks\n const {\n current: isControlled\n } = React.useRef(openProp !== undefined);\n\n // eslint-disable-next-line react-hooks/rules-of-hooks\n React.useEffect(() => {\n if (childNode && childNode.disabled && !isControlled && title !== '' && childNode.tagName.toLowerCase() === 'button') {\n console.error(['MUI: You are providing a disabled `button` child to the Tooltip component.', 'A disabled element does not fire events.', \"Tooltip needs to listen to the child element's events to display the title.\", '', 'Add a simple wrapper element, such as a `span`.'].join('\\n'));\n }\n }, [title, childNode, isControlled]);\n }\n const id = useId(idProp);\n const prevUserSelect = React.useRef();\n const stopTouchInteraction = useEventCallback(() => {\n if (prevUserSelect.current !== undefined) {\n document.body.style.WebkitUserSelect = prevUserSelect.current;\n prevUserSelect.current = undefined;\n }\n touchTimer.clear();\n });\n React.useEffect(() => stopTouchInteraction, [stopTouchInteraction]);\n const handleOpen = event => {\n hystersisTimer.clear();\n hystersisOpen = true;\n\n // The mouseover event will trigger for every nested element in the tooltip.\n // We can skip rerendering when the tooltip is already open.\n // We are using the mouseover event instead of the mouseenter event to fix a hide/show issue.\n setOpenState(true);\n if (onOpen && !open) {\n onOpen(event);\n }\n };\n const handleClose = useEventCallback(\n /**\n * @param {React.SyntheticEvent | Event} event\n */\n event => {\n hystersisTimer.start(800 + leaveDelay, () => {\n hystersisOpen = false;\n });\n setOpenState(false);\n if (onClose && open) {\n onClose(event);\n }\n closeTimer.start(theme.transitions.duration.shortest, () => {\n ignoreNonTouchEvents.current = false;\n });\n });\n const handleEnter = event => {\n if (ignoreNonTouchEvents.current && event.type !== 'touchstart') {\n return;\n }\n\n // Remove the title ahead of time.\n // We don't want to wait for the next render commit.\n // We would risk displaying two tooltips at the same time (native + this one).\n if (childNode) {\n childNode.removeAttribute('title');\n }\n enterTimer.clear();\n leaveTimer.clear();\n if (enterDelay || hystersisOpen && enterNextDelay) {\n enterTimer.start(hystersisOpen ? enterNextDelay : enterDelay, () => {\n handleOpen(event);\n });\n } else {\n handleOpen(event);\n }\n };\n const handleLeave = event => {\n enterTimer.clear();\n leaveTimer.start(leaveDelay, () => {\n handleClose(event);\n });\n };\n const {\n isFocusVisibleRef,\n onBlur: handleBlurVisible,\n onFocus: handleFocusVisible,\n ref: focusVisibleRef\n } = useIsFocusVisible();\n // We don't necessarily care about the focusVisible state (which is safe to access via ref anyway).\n // We just need to re-render the Tooltip if the focus-visible state changes.\n const [, setChildIsFocusVisible] = React.useState(false);\n const handleBlur = event => {\n handleBlurVisible(event);\n if (isFocusVisibleRef.current === false) {\n setChildIsFocusVisible(false);\n handleLeave(event);\n }\n };\n const handleFocus = event => {\n // Workaround for https://github.com/facebook/react/issues/7769\n // The autoFocus of React might trigger the event before the componentDidMount.\n // We need to account for this eventuality.\n if (!childNode) {\n setChildNode(event.currentTarget);\n }\n handleFocusVisible(event);\n if (isFocusVisibleRef.current === true) {\n setChildIsFocusVisible(true);\n handleEnter(event);\n }\n };\n const detectTouchStart = event => {\n ignoreNonTouchEvents.current = true;\n const childrenProps = children.props;\n if (childrenProps.onTouchStart) {\n childrenProps.onTouchStart(event);\n }\n };\n const handleMouseOver = handleEnter;\n const handleMouseLeave = handleLeave;\n const handleTouchStart = event => {\n detectTouchStart(event);\n leaveTimer.clear();\n closeTimer.clear();\n stopTouchInteraction();\n prevUserSelect.current = document.body.style.WebkitUserSelect;\n // Prevent iOS text selection on long-tap.\n document.body.style.WebkitUserSelect = 'none';\n touchTimer.start(enterTouchDelay, () => {\n document.body.style.WebkitUserSelect = prevUserSelect.current;\n handleEnter(event);\n });\n };\n const handleTouchEnd = event => {\n if (children.props.onTouchEnd) {\n children.props.onTouchEnd(event);\n }\n stopTouchInteraction();\n leaveTimer.start(leaveTouchDelay, () => {\n handleClose(event);\n });\n };\n React.useEffect(() => {\n if (!open) {\n return undefined;\n }\n\n /**\n * @param {KeyboardEvent} nativeEvent\n */\n function handleKeyDown(nativeEvent) {\n // IE11, Edge (prior to using Bink?) use 'Esc'\n if (nativeEvent.key === 'Escape' || nativeEvent.key === 'Esc') {\n handleClose(nativeEvent);\n }\n }\n document.addEventListener('keydown', handleKeyDown);\n return () => {\n document.removeEventListener('keydown', handleKeyDown);\n };\n }, [handleClose, open]);\n const handleRef = useForkRef(children.ref, focusVisibleRef, setChildNode, ref);\n\n // There is no point in displaying an empty tooltip.\n // So we exclude all falsy values, except 0, which is valid.\n if (!title && title !== 0) {\n open = false;\n }\n const popperRef = React.useRef();\n const handleMouseMove = event => {\n const childrenProps = children.props;\n if (childrenProps.onMouseMove) {\n childrenProps.onMouseMove(event);\n }\n cursorPosition = {\n x: event.clientX,\n y: event.clientY\n };\n if (popperRef.current) {\n popperRef.current.update();\n }\n };\n const nameOrDescProps = {};\n const titleIsString = typeof title === 'string';\n if (describeChild) {\n nameOrDescProps.title = !open && titleIsString && !disableHoverListener ? title : null;\n nameOrDescProps['aria-describedby'] = open ? id : null;\n } else {\n nameOrDescProps['aria-label'] = titleIsString ? title : null;\n nameOrDescProps['aria-labelledby'] = open && !titleIsString ? id : null;\n }\n const childrenProps = _extends({}, nameOrDescProps, other, children.props, {\n className: clsx(other.className, children.props.className),\n onTouchStart: detectTouchStart,\n ref: handleRef\n }, followCursor ? {\n onMouseMove: handleMouseMove\n } : {});\n if (process.env.NODE_ENV !== 'production') {\n childrenProps['data-mui-internal-clone-element'] = true;\n\n // eslint-disable-next-line react-hooks/rules-of-hooks\n React.useEffect(() => {\n if (childNode && !childNode.getAttribute('data-mui-internal-clone-element')) {\n console.error(['MUI: The `children` component of the Tooltip is not forwarding its props correctly.', 'Please make sure that props are spread on the same element that the ref is applied to.'].join('\\n'));\n }\n }, [childNode]);\n }\n const interactiveWrapperListeners = {};\n if (!disableTouchListener) {\n childrenProps.onTouchStart = handleTouchStart;\n childrenProps.onTouchEnd = handleTouchEnd;\n }\n if (!disableHoverListener) {\n childrenProps.onMouseOver = composeEventHandler(handleMouseOver, childrenProps.onMouseOver);\n childrenProps.onMouseLeave = composeEventHandler(handleMouseLeave, childrenProps.onMouseLeave);\n if (!disableInteractive) {\n interactiveWrapperListeners.onMouseOver = handleMouseOver;\n interactiveWrapperListeners.onMouseLeave = handleMouseLeave;\n }\n }\n if (!disableFocusListener) {\n childrenProps.onFocus = composeEventHandler(handleFocus, childrenProps.onFocus);\n childrenProps.onBlur = composeEventHandler(handleBlur, childrenProps.onBlur);\n if (!disableInteractive) {\n interactiveWrapperListeners.onFocus = handleFocus;\n interactiveWrapperListeners.onBlur = handleBlur;\n }\n }\n if (process.env.NODE_ENV !== 'production') {\n if (children.props.title) {\n console.error(['MUI: You have provided a `title` prop to the child of .', `Remove this title prop \\`${children.props.title}\\` or the Tooltip component.`].join('\\n'));\n }\n }\n const popperOptions = React.useMemo(() => {\n var _PopperProps$popperOp;\n let tooltipModifiers = [{\n name: 'arrow',\n enabled: Boolean(arrowRef),\n options: {\n element: arrowRef,\n padding: 4\n }\n }];\n if ((_PopperProps$popperOp = PopperProps.popperOptions) != null && _PopperProps$popperOp.modifiers) {\n tooltipModifiers = tooltipModifiers.concat(PopperProps.popperOptions.modifiers);\n }\n return _extends({}, PopperProps.popperOptions, {\n modifiers: tooltipModifiers\n });\n }, [arrowRef, PopperProps]);\n const ownerState = _extends({}, props, {\n isRtl,\n arrow,\n disableInteractive,\n placement,\n PopperComponentProp,\n touch: ignoreNonTouchEvents.current\n });\n const classes = useUtilityClasses(ownerState);\n const PopperComponent = (_ref = (_slots$popper = slots.popper) != null ? _slots$popper : components.Popper) != null ? _ref : TooltipPopper;\n const TransitionComponent = (_ref2 = (_ref3 = (_slots$transition = slots.transition) != null ? _slots$transition : components.Transition) != null ? _ref3 : TransitionComponentProp) != null ? _ref2 : Grow;\n const TooltipComponent = (_ref4 = (_slots$tooltip = slots.tooltip) != null ? _slots$tooltip : components.Tooltip) != null ? _ref4 : TooltipTooltip;\n const ArrowComponent = (_ref5 = (_slots$arrow = slots.arrow) != null ? _slots$arrow : components.Arrow) != null ? _ref5 : TooltipArrow;\n const popperProps = appendOwnerState(PopperComponent, _extends({}, PopperProps, (_slotProps$popper = slotProps.popper) != null ? _slotProps$popper : componentsProps.popper, {\n className: clsx(classes.popper, PopperProps == null ? void 0 : PopperProps.className, (_ref6 = (_slotProps$popper2 = slotProps.popper) != null ? _slotProps$popper2 : componentsProps.popper) == null ? void 0 : _ref6.className)\n }), ownerState);\n const transitionProps = appendOwnerState(TransitionComponent, _extends({}, TransitionProps, (_slotProps$transition = slotProps.transition) != null ? _slotProps$transition : componentsProps.transition), ownerState);\n const tooltipProps = appendOwnerState(TooltipComponent, _extends({}, (_slotProps$tooltip = slotProps.tooltip) != null ? _slotProps$tooltip : componentsProps.tooltip, {\n className: clsx(classes.tooltip, (_ref7 = (_slotProps$tooltip2 = slotProps.tooltip) != null ? _slotProps$tooltip2 : componentsProps.tooltip) == null ? void 0 : _ref7.className)\n }), ownerState);\n const tooltipArrowProps = appendOwnerState(ArrowComponent, _extends({}, (_slotProps$arrow = slotProps.arrow) != null ? _slotProps$arrow : componentsProps.arrow, {\n className: clsx(classes.arrow, (_ref8 = (_slotProps$arrow2 = slotProps.arrow) != null ? _slotProps$arrow2 : componentsProps.arrow) == null ? void 0 : _ref8.className)\n }), ownerState);\n return /*#__PURE__*/_jsxs(React.Fragment, {\n children: [/*#__PURE__*/React.cloneElement(children, childrenProps), /*#__PURE__*/_jsx(PopperComponent, _extends({\n as: PopperComponentProp != null ? PopperComponentProp : Popper,\n placement: placement,\n anchorEl: followCursor ? {\n getBoundingClientRect: () => ({\n top: cursorPosition.y,\n left: cursorPosition.x,\n right: cursorPosition.x,\n bottom: cursorPosition.y,\n width: 0,\n height: 0\n })\n } : childNode,\n popperRef: popperRef,\n open: childNode ? open : false,\n id: id,\n transition: true\n }, interactiveWrapperListeners, popperProps, {\n popperOptions: popperOptions,\n children: ({\n TransitionProps: TransitionPropsInner\n }) => /*#__PURE__*/_jsx(TransitionComponent, _extends({\n timeout: theme.transitions.duration.shorter\n }, TransitionPropsInner, transitionProps, {\n children: /*#__PURE__*/_jsxs(TooltipComponent, _extends({}, tooltipProps, {\n children: [title, arrow ? /*#__PURE__*/_jsx(ArrowComponent, _extends({}, tooltipArrowProps, {\n ref: setArrowRef\n })) : null]\n }))\n }))\n }))]\n });\n});\nprocess.env.NODE_ENV !== \"production\" ? Tooltip.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the d.ts file and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * If `true`, adds an arrow to the tooltip.\n * @default false\n */\n arrow: PropTypes.bool,\n /**\n * Tooltip reference element.\n */\n children: elementAcceptingRef.isRequired,\n /**\n * Override or extend the styles applied to the component.\n */\n classes: PropTypes.object,\n /**\n * @ignore\n */\n className: PropTypes.string,\n /**\n * The components used for each slot inside.\n *\n * This prop is an alias for the `slots` prop.\n * It's recommended to use the `slots` prop instead.\n *\n * @default {}\n */\n components: PropTypes.shape({\n Arrow: PropTypes.elementType,\n Popper: PropTypes.elementType,\n Tooltip: PropTypes.elementType,\n Transition: PropTypes.elementType\n }),\n /**\n * The extra props for the slot components.\n * You can override the existing props or add new ones.\n *\n * This prop is an alias for the `slotProps` prop.\n * It's recommended to use the `slotProps` prop instead, as `componentsProps` will be deprecated in the future.\n *\n * @default {}\n */\n componentsProps: PropTypes.shape({\n arrow: PropTypes.object,\n popper: PropTypes.object,\n tooltip: PropTypes.object,\n transition: PropTypes.object\n }),\n /**\n * Set to `true` if the `title` acts as an accessible description.\n * By default the `title` acts as an accessible label for the child.\n * @default false\n */\n describeChild: PropTypes.bool,\n /**\n * Do not respond to focus-visible events.\n * @default false\n */\n disableFocusListener: PropTypes.bool,\n /**\n * Do not respond to hover events.\n * @default false\n */\n disableHoverListener: PropTypes.bool,\n /**\n * Makes a tooltip not interactive, i.e. it will close when the user\n * hovers over the tooltip before the `leaveDelay` is expired.\n * @default false\n */\n disableInteractive: PropTypes.bool,\n /**\n * Do not respond to long press touch events.\n * @default false\n */\n disableTouchListener: PropTypes.bool,\n /**\n * The number of milliseconds to wait before showing the tooltip.\n * This prop won't impact the enter touch delay (`enterTouchDelay`).\n * @default 100\n */\n enterDelay: PropTypes.number,\n /**\n * The number of milliseconds to wait before showing the tooltip when one was already recently opened.\n * @default 0\n */\n enterNextDelay: PropTypes.number,\n /**\n * The number of milliseconds a user must touch the element before showing the tooltip.\n * @default 700\n */\n enterTouchDelay: PropTypes.number,\n /**\n * If `true`, the tooltip follow the cursor over the wrapped element.\n * @default false\n */\n followCursor: PropTypes.bool,\n /**\n * This prop is used to help implement the accessibility logic.\n * If you don't provide this prop. It falls back to a randomly generated id.\n */\n id: PropTypes.string,\n /**\n * The number of milliseconds to wait before hiding the tooltip.\n * This prop won't impact the leave touch delay (`leaveTouchDelay`).\n * @default 0\n */\n leaveDelay: PropTypes.number,\n /**\n * The number of milliseconds after the user stops touching an element before hiding the tooltip.\n * @default 1500\n */\n leaveTouchDelay: PropTypes.number,\n /**\n * Callback fired when the component requests to be closed.\n *\n * @param {React.SyntheticEvent} event The event source of the callback.\n */\n onClose: PropTypes.func,\n /**\n * Callback fired when the component requests to be open.\n *\n * @param {React.SyntheticEvent} event The event source of the callback.\n */\n onOpen: PropTypes.func,\n /**\n * If `true`, the component is shown.\n */\n open: PropTypes.bool,\n /**\n * Tooltip placement.\n * @default 'bottom'\n */\n placement: PropTypes.oneOf(['bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n /**\n * The component used for the popper.\n * @default Popper\n */\n PopperComponent: PropTypes.elementType,\n /**\n * Props applied to the [`Popper`](/material-ui/api/popper/) element.\n * @default {}\n */\n PopperProps: PropTypes.object,\n /**\n * The extra props for the slot components.\n * You can override the existing props or add new ones.\n *\n * This prop is an alias for the `componentsProps` prop, which will be deprecated in the future.\n *\n * @default {}\n */\n slotProps: PropTypes.shape({\n arrow: PropTypes.object,\n popper: PropTypes.object,\n tooltip: PropTypes.object,\n transition: PropTypes.object\n }),\n /**\n * The components used for each slot inside.\n *\n * This prop is an alias for the `components` prop, which will be deprecated in the future.\n *\n * @default {}\n */\n slots: PropTypes.shape({\n arrow: PropTypes.elementType,\n popper: PropTypes.elementType,\n tooltip: PropTypes.elementType,\n transition: PropTypes.elementType\n }),\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Tooltip title. Zero-length titles string, undefined, null and false are never displayed.\n */\n title: PropTypes.node,\n /**\n * The component used for the transition.\n * [Follow this guide](/material-ui/transitions/#transitioncomponent-prop) to learn more about the requirements for this component.\n * @default Grow\n */\n TransitionComponent: PropTypes.elementType,\n /**\n * Props applied to the transition element.\n * By default, the element is based on this [`Transition`](http://reactcommunity.org/react-transition-group/transition/) component.\n */\n TransitionProps: PropTypes.object\n} : void 0;\nexport default Tooltip;","import '@/components/mui/menu-item.component.css';\nimport ArrowRightIcon from '@mui/icons-material/ArrowRight';\nimport {\n ListItemIcon as MuiListItemIcon,\n ListItemText as MuiListItemText,\n MenuItem as MuiMenuItem,\n} from '@mui/material';\nimport Tooltip from '@mui/material/Tooltip';\nimport { Localized, ReferencedItem, SingleColumnMenu } from 'platform-bible-utils';\nimport { MouseEvent, PropsWithChildren } from 'react';\n\ntype MenuItemInfoBase = {\n /** Text (displayable in the UI) as the name of the menu item */\n label: string;\n /** Text to display when the mouse hovers over the menu item */\n tooltip?: string;\n};\n\nexport type Command = MenuItemInfoBase & {\n /** Command to execute (string.string) */\n command: string;\n};\n\ntype SubMenu = MenuItemInfoBase & {\n /** Command to execute (string.string) */\n items: MenuItemInfo[];\n};\n\nexport interface CommandHandler {\n (command: Command): void;\n}\n\nexport type MenuPropsBase = {\n /*\n * The JSON defining the menu whose items are to be rendered. This will typically be one of the\n * menus in the \"defs\" in a Platform.Bible menu (see PlatformMenus). The schema for this is\n * menuDocumentSchema (at the end of menus.model.ts). Note that while this is a\n * \"SingleColumnMenu\", somewhat bizarrely, a MultiColumnMenu is a SingleColumnMenu, so it really\n * could be a MultiColumnMenu, in which case, column had better be defined so it can be used\n * to filter out the actual groups and items to display on the column.\n */\n menuDefinition: Localized;\n\n commandHandler: CommandHandler;\n\n /**\n * Additional action to perform when any menu item is clicked. Allows the caller to handle event\n * (e.g., to close the menu).\n */\n onClick?: (event: MouseEvent) => void;\n};\n\nexport type MenuItemListProps = MenuPropsBase & {\n /** Optional unique (column) identifier */\n columnId?: ReferencedItem;\n};\n\nexport type MenuItemProps = Omit &\n PropsWithChildren<{\n /** Optional unique identifier */\n id?: string;\n\n onClick: (event: MouseEvent) => void;\n }>;\n\ntype MenuItemInfo = (Command | SubMenu) & {\n /**\n * If specified, menu item will be inset if it does not have a leading icon.\n *\n * @default true\n */\n allowForLeadingIcons?: boolean;\n /**\n * If specified, the path to the icon image to display on the leading side of the menu text.\n *\n * @default undefined (no leading icon will be shown)\n */\n iconPathBefore?: string;\n /**\n * If specified, the path to the icon image to display on the trailing side of the menu text.\n *\n * @default undefined (no trailing icon will be shown)\n */\n iconPathAfter?: string;\n /**\n * If true, list item is focused during the first mount\n *\n * @default false\n */\n hasAutoFocus?: boolean;\n\n /** Additional css classes to help with unique styling of the menu item */\n className?: string;\n\n /**\n * If true, the menu item will appear disabled and it will not respond to clicks or mouse hovers.\n *\n * @default false\n */\n isDisabled?: boolean;\n\n /**\n * If true, compact vertical padding designed for keyboard and mouse input is used.\n *\n * @default true\n */\n isDense?: boolean;\n\n /**\n * If true, a right-arrow icon will be displayed (iconPathAfter, if specified, will be ignored).\n *\n * @default false\n */\n isSubMenuParent?: boolean;\n\n /**\n * If true, the left and right padding is removed\n *\n * @default false\n */\n hasDisabledGutters?: boolean;\n\n /**\n * If true, a 1px light border is added to bottom of menu item\n *\n * @default false\n */\n hasDivider?: boolean;\n\n /** Help identify which element has keyboard focus */\n focusVisibleClassName?: string;\n\n /** If it's a submenu, it should have the items property */\n items?: MenuItemInfo[];\n};\n\nfunction getIcon(icon: string | undefined, menuLabel: string, leading: boolean) {\n return icon ? (\n \n {`${leading\n \n ) : undefined;\n}\n\nexport default function MenuItem(props: MenuItemProps) {\n const {\n onClick,\n label,\n tooltip,\n allowForLeadingIcons = true,\n iconPathBefore = undefined,\n iconPathAfter = undefined,\n hasAutoFocus = false,\n className,\n isDisabled = false,\n isDense = true,\n isSubMenuParent = false,\n hasDisabledGutters = false,\n hasDivider = false,\n focusVisibleClassName,\n id,\n children,\n } = props;\n\n const menuItem = (\n \n {label ? (\n <>\n {getIcon(iconPathBefore, label, true)}\n \n {isSubMenuParent ? (\n \n \n \n ) : (\n getIcon(iconPathAfter, label, false)\n )}\n \n ) : (\n children\n )}\n \n );\n\n return tooltip ? (\n \n
    {menuItem}
    \n
    \n ) : (\n menuItem\n );\n}\n","import MenuItem, {\n MenuItemListProps,\n MenuItemProps,\n MenuPropsBase,\n} from '@/components/mui/menu-item.component';\nimport { Menu } from '@mui/material';\nimport {\n Localized,\n MenuGroupDetailsInSubMenu,\n MenuItemContainingCommand,\n MenuItemContainingSubmenu,\n OrderedExtensibleContainer,\n ReferencedItem,\n SingleColumnMenu,\n} from 'platform-bible-utils';\nimport { MouseEvent, useMemo, useState } from 'react';\n\n/**\n * All the exported types in this file should be regarded as \"internal\" (i.e., they should not be\n * exposed via index.ts).\n */\n\nexport type GroupedMenuPropsBase = MenuPropsBase & {\n /** Optional unique (column) identifier */\n columnId?: ReferencedItem;\n};\n\nexport type GroupedMenuItemListProps = MenuItemListProps & {\n /**\n * If the menuDefinition includes \"top-level\" groups (i.e., those that belong to a column as\n * opposed to those that belong to a submenu) that should not be included in the list, then this\n * array specifies which groups to include. Likewise, for a submenu, this list indicates which\n * groups are pertinent for that submenu. So then for a context menu this property need not be\n * specified since it is a top-level menu based on a \"true\" SingleColumnMenu (i.e., one that is\n * not a MultiColumnMenu).\n */\n includedGroups?: {\n id: string;\n group: Localized;\n }[];\n};\n\ninterface ItemInfo {\n item: Localized;\n isLastItemInGroup: boolean;\n}\n\ntype SubMenuProps = MenuPropsBase & {\n parentMenuItem: Localized;\n parentItemProps: Omit, 'iconPathAfter'>;\n};\n\nfunction getAllGroups(menuDefinition: Localized) {\n const groupEntries = Object.entries(menuDefinition.groups);\n // Convert array of entries to array of objects with id and group properties\n return groupEntries.map(([key, value]) => ({ id: key, group: value }));\n}\n\nfunction SubMenu(props: SubMenuProps) {\n const [anchorEl, setAnchorEl] = useState(undefined);\n\n const { parentMenuItem, parentItemProps, menuDefinition } = props;\n\n const handleParentMenuItemClick = (event: MouseEvent) => {\n setAnchorEl(event.currentTarget);\n };\n\n const handleClose = () => {\n setAnchorEl(undefined);\n };\n\n const renderSubMenuItems = () => {\n let includedGroups = getAllGroups(menuDefinition).filter((g) => 'menuItem' in g.group);\n\n // Ensure valid parent menu was provided. (If not, submenu will contain all groups!)\n if (!parentMenuItem?.id) throw new Error('A valid parent menu item is required for submenus.');\n\n // When laying out a submenu, only include groups associated with the provided parent menu.\n // Note: without the (annoying) redundant check that the included groups\n // have the menuItem field, TS doesn't think it exists.\n includedGroups = includedGroups.filter(\n (group) => 'menuItem' in group.group && group.group.menuItem === parentMenuItem.id,\n );\n\n return ;\n };\n\n return (\n <>\n \n \n {renderSubMenuItems()}\n \n \n );\n}\n\nconst getOrderedGroupItems = (\n groupId: string,\n allItems: Localized[],\n) => {\n // Filter items that belong to the specified group\n const itemsForGroup = allItems.filter((item) => item.group === groupId);\n // Sort items based on order\n const sortedItems = itemsForGroup.sort((a, b) => (a.order || 0) - (b.order || 0));\n return sortedItems;\n};\n\n/**\n * This component is internal; it does not need to be exposed to the outside world since it is not\n * useful on its own. It is used to generate and lay out the MenuItems that appear either on a\n * top-level menu (in a GridMenu or ContextMenu) or in a submenu.\n */\nexport default function GroupedMenuItemList(menuProps: GroupedMenuItemListProps) {\n const { menuDefinition, onClick, commandHandler, includedGroups } = menuProps;\n\n const { items, allowForLeadingIcons } = useMemo(() => {\n const groupsToInclude =\n includedGroups && includedGroups.length > 0\n ? includedGroups\n : // We're apparently laying out a single-column menu (presumably a context menu). In this\n // case, all groups should be included except ones that belong to a submenu.\n getAllGroups(menuDefinition).filter((g) => !('menuItem' in g.group));\n\n const sortedGroups = Object.values(groupsToInclude).sort(\n (a, b) => (a.group.order || 0) - (b.group.order || 0),\n );\n\n const itemArray: ItemInfo[] = [];\n\n sortedGroups.forEach((group) => {\n getOrderedGroupItems(group.id, menuDefinition.items).forEach((item) =>\n itemArray.push({ item, isLastItemInGroup: false }),\n );\n if (itemArray.length > 0) itemArray[itemArray.length - 1].isLastItemInGroup = true;\n });\n\n // No divider after last item in final group.\n if (itemArray.length > 0) itemArray[itemArray.length - 1].isLastItemInGroup = false;\n\n const allowSpaceForLeadingIcons = itemArray.some(\n (i) => 'iconPathBefore' in i.item && i.item.iconPathBefore,\n );\n\n return { items: itemArray, allowForLeadingIcons: allowSpaceForLeadingIcons };\n }, [includedGroups, menuDefinition]);\n\n // Create props for MenuItem component including setting hasDivider for the last item in a group\n const createMenuItemProps = ({ item, isLastItemInGroup }: ItemInfo) => {\n const menuItemProps = {\n className: 'papi-menu-item',\n label: item.label,\n tooltip: item.tooltip,\n iconPathBefore: 'iconPathBefore' in item ? item.iconPathBefore : undefined,\n iconPathAfter: 'iconPathAfter' in item ? item.iconPathAfter : undefined,\n hasDivider: isLastItemInGroup, // Set hasDivider to true for the last item in a group\n allowForLeadingIcons,\n };\n\n return menuItemProps;\n };\n\n const [firstItem] = items;\n\n if (!firstItem) return
    ;\n\n const divKey = firstItem.item.group;\n\n return (\n
    \n {items.map((itemInfo, index) => {\n const { item } = itemInfo;\n const menuItemProps = createMenuItemProps(itemInfo);\n if ('command' in item) {\n const key = item.group + index;\n return (\n ) => {\n onClick?.(event);\n commandHandler(item);\n }}\n {...menuItemProps}\n />\n );\n }\n return (\n \n );\n })}\n
    \n );\n}\n","import GroupedMenuItemList from '@/components/mui/grouped-menu-item-list.component';\nimport { MenuItemListProps } from '@/components/mui/menu-item.component';\nimport { MultiColumnMenu } from 'platform-bible-utils';\n\n/**\n * This component is internal; it does not need to be exposed to the outside world since it is not\n * useful on its own. Use either GridMenu or ContextMenu.\n */\nexport default function TopLevelMenu(props: MenuItemListProps) {\n const { menuDefinition, columnId } = props;\n\n const groupEntries = Object.entries(menuDefinition.groups);\n // Convert array of entries to array of objects with id and group properties\n const groups = groupEntries.map(([key, value]) => ({ id: key, group: value }));\n let includedGroups = groups.filter((g) => 'column' in g.group);\n\n // Check if column is provided and menuDefinition is a MultiColumnMenu\n if (\n columnId &&\n 'columns' in menuDefinition &&\n // Without this type assertion, TS doesn't know what columns is.\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n (menuDefinition as MultiColumnMenu).columns[columnId]\n ) {\n // When laying out a single column in a MultiColumnMenu, only include groups associated with\n // the provided column. Note: without the (annoying) redundant check that the included groups\n // have the colum field, TS doesn't think it exists.\n includedGroups = includedGroups.filter(\n (g) => 'column' in g.group && g.group.column === columnId,\n );\n }\n\n return ;\n}\n","import '@/components/mui/grid-menu.component.css';\nimport { GroupedMenuPropsBase } from '@/components/mui/grouped-menu-item-list.component';\nimport { CommandHandler } from '@/components/mui/menu-item.component';\nimport TopLevelMenu from '@/components/mui/top-level-menu.component';\nimport { Grid, List } from '@mui/material';\nimport {\n Localized,\n MenuColumnWithHeader,\n MultiColumnMenu,\n ReferencedItem,\n} from 'platform-bible-utils';\nimport { useMemo } from 'react';\n\ntype ColumnInfo = {\n /*\n * The ID (`${string}.${string}`) of a specific menu column.\n */\n id: ReferencedItem;\n\n /*\n * Metadata (label, order, etc.) for a specific menu column.\n */\n metadata: Localized;\n};\n\ntype MenuColumnProps = ColumnInfo &\n GroupedMenuPropsBase & {\n /** Additional css classes to help with unique styling of the menu column */\n className?: string;\n };\n\nexport type GridMenuInfo = {\n /** The menu object containing information about the columns, groups, and items to display. */\n multiColumnMenu: Localized;\n};\n\nexport type GridMenuProps = GridMenuInfo & {\n /** Optional unique identifier */\n id?: string;\n\n commandHandler: CommandHandler;\n\n /** Additional css classes to help with unique styling of the grid menu */\n className?: string;\n};\n\nfunction MenuColumn({\n commandHandler,\n menuDefinition,\n id,\n metadata,\n onClick,\n className,\n}: MenuColumnProps) {\n return (\n \n

    \n {metadata.label}\n

    \n {/* It would seem as though this List component were unnecessary, since it only contains one\n thing, but the \"dense\" property does affect the layout of the items (in a way I don't fully\n understand). There might be a better way. */}\n \n \n \n \n );\n}\n\nexport default function GridMenu({\n commandHandler,\n className,\n multiColumnMenu,\n id,\n}: GridMenuProps) {\n const { columns } = multiColumnMenu;\n\n const sortedColumns = useMemo(() => {\n const columnNumbers = new Map();\n Object.getOwnPropertyNames(columns).forEach((columnName: string) => {\n // We know for sure there is a (boolean) property 'isExtensible' that we are not interested in.\n if (columnName === 'isExtensible') return;\n // TS doesn't allow `columnName` above to be a ReferencedItem even though the type says it is\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const columnId = columnName as ReferencedItem;\n const column = columns[columnId];\n // As of right now (and hopefully forever after), all remaining properties of the\n // ColumnsWithHeaders object are columns whose property names are the IDs of the columns.\n // This is an additional (redundant) sanity check. Specifically we're interested in\n // MenuColumnWithHeader objects, which TypeScript now \"knows\" we have, but at runtime all we\n // can check for is that it's an object with a valid numeric order field. That's likely good\n // enough.\n if (\n typeof column === 'object' &&\n typeof column.order === 'number' &&\n !Number.isNaN(column.order)\n )\n columnNumbers.set(column.order, { id: columnId, metadata: column });\n else\n console.warn(\n `Property ${columnName} (${typeof column}) on menu ${id} is not a valid column and is being ignored. This might indicate data corruption`,\n );\n });\n\n // Extract values and sort them based on the 'order' property\n return Array.from(columnNumbers.values()).sort((a, b) => {\n return (a.metadata.order || 0) - (b.metadata.order || 0);\n });\n }, [columns, id]);\n\n // We might need something like this if we need to be able to prevent empty columns\n // sortedColumns.filter((c) => multiColumnMenu.groups.some((g) => 'column' in g && (g as .column)...\n\n return (\n \n {sortedColumns.map((col, index) => (\n \n ))}\n \n );\n}\n","import { useEffect, useRef, useState } from 'react';\n\nexport type UsePromiseOptions = {\n /**\n * Whether to leave the value as the most recent resolved promise value or set it back to\n * defaultValue while running the promise again. Defaults to true\n */\n preserveValue?: boolean;\n};\n\n/** Set up defaults for options for usePromise hook */\nfunction getUsePromiseOptionsDefaults(options: UsePromiseOptions): UsePromiseOptions {\n return {\n preserveValue: true,\n ...options,\n };\n}\n\n/**\n * Awaits a promise and returns a loading value while the promise is unresolved\n *\n * @param promiseFactoryCallback A function that returns the promise to await. If this callback is\n * undefined, the current value will be returned (defaultValue unless it was previously changed\n * and `options.preserveValue` is true), and there will be no loading.\n *\n * WARNING: MUST BE STABLE - const or wrapped in useCallback. The reference must not be updated\n * every render\n * @param defaultValue The initial value to return while first awaiting the promise. If\n * `options.preserveValue` is false, this value is also shown while awaiting the promise on\n * subsequent calls.\n *\n * Note: this parameter is internally assigned to a `ref`, so changing it will not cause any hooks\n * to re-run with its new value. This means that, if the `promiseFactoryCallback` changes and\n * `options.preserveValue` is `false`, the returned value will be set to the current\n * `defaultValue`. However, the returned value will not be updated if`defaultValue` changes.\n * @param options Various options for adjusting how this hook runs the `promiseFactoryCallback`\n *\n * Note: this parameter is internally assigned to a `ref`, so changing it will not cause any hooks\n * to re-run with its new value. However, the latest `options.preserveValue` will always be used\n * appropriately to determine whether to preserve the returned value when changing the\n * `promiseFactoryCallback`\n * @returns `[value, isLoading]`\n *\n * - `value`: the current value for the promise, either the defaultValue or the resolved promise value\n * - `isLoading`: whether the promise is waiting to be resolved\n */\nconst usePromise = (\n promiseFactoryCallback: (() => Promise) | undefined,\n defaultValue: T,\n options: UsePromiseOptions = {},\n): [value: T, isLoading: boolean] => {\n // Use defaultValue as a ref so it doesn't update dependency arrays\n const defaultValueRef = useRef(defaultValue);\n defaultValueRef.current = defaultValue;\n // Use options as a ref so it doesn't update dependency arrays\n const optionsDefaultedRef = useRef(options);\n optionsDefaultedRef.current = getUsePromiseOptionsDefaults(optionsDefaultedRef.current);\n\n const [value, setValue] = useState(() => defaultValueRef.current);\n const [isLoading, setIsLoading] = useState(true);\n useEffect(() => {\n let promiseIsCurrent = true;\n // If a promiseFactoryCallback was provided, we are loading. Otherwise, there is no loading to do\n setIsLoading(!!promiseFactoryCallback);\n (async () => {\n // If there is a callback to run, run it\n if (promiseFactoryCallback) {\n const result = await promiseFactoryCallback();\n // If the promise was not already replaced, update the value\n if (promiseIsCurrent) {\n setValue(() => result);\n setIsLoading(false);\n }\n }\n })();\n\n return () => {\n // Mark this promise as old and not to be used\n promiseIsCurrent = false;\n if (!optionsDefaultedRef.current.preserveValue) setValue(() => defaultValueRef.current);\n };\n }, [promiseFactoryCallback]);\n\n return [value, isLoading];\n};\nexport default usePromise;\n","\"use client\";\n\nimport createSvgIcon from './utils/createSvgIcon';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nexport default createSvgIcon( /*#__PURE__*/_jsx(\"path\", {\n d: \"M3 18h18v-2H3zm0-5h18v-2H3zm0-7v2h18V6z\"\n}), 'Menu');","import GridMenu from '@/components/mui/grid-menu.component';\nimport { Command, CommandHandler } from '@/components/mui/menu-item.component';\nimport usePromise from '@/hooks/use-promise.hook';\nimport { Menu as MenuIcon } from '@mui/icons-material';\nimport { Drawer, IconButton } from '@mui/material';\nimport { Localized, MultiColumnMenu } from 'platform-bible-utils';\nimport {\n MouseEvent,\n MutableRefObject,\n PropsWithChildren,\n useCallback,\n useEffect,\n useState,\n} from 'react';\n\nexport interface MultiColumnMenuProvider {\n (isSupportAndDevelopment: boolean): Promise>;\n}\n\nexport type HamburgerMenuButtonProps = PropsWithChildren & {\n /** The handler to use for menu commands (and eventually toolbar commands). */\n commandHandler: CommandHandler;\n\n /**\n * Optional reference to the \"div\" container that determines the where the menu should appear. If\n * not defined, then (1,1) used.\n */\n containerRef?: MutableRefObject;\n\n /**\n * The delegate to use to get the menu data. If not specified or if it returns undefined, the data\n * in normalMenu or fullMenu property will be used.\n */\n menuProvider?: MultiColumnMenuProvider;\n\n /**\n * The menu data to show when the menu is opened if the menuProvider property is not defined.\n * (This allows for a default or test-only static menu to be used.)\n */\n normalMenu?: Localized;\n\n /**\n * The menu data to show for \"full\" menu (when opened with the SHIFT key pressed) if the\n * menuProvider property is not defined. (This allows for a default or test-only static menu to be\n * used.)\n */\n fullMenu?: Localized;\n\n /** Additional css class(es) to help with unique styling of the sub-components */\n className?: string;\n\n /** Value to use as prefix for ARIA labels on interactive sub-components */\n ariaLabelPrefix?: string;\n};\n\nexport default function HamburgerMenuButton({\n menuProvider,\n normalMenu,\n fullMenu,\n commandHandler,\n containerRef,\n className,\n ariaLabelPrefix,\n children,\n}: HamburgerMenuButtonProps) {\n const [isMenuOpen, setMenuOpen] = useState(false);\n const [showFullMenu, setShowFullMenu] = useState(false);\n\n const handleMenuItemClick = useCallback(() => {\n if (isMenuOpen) setMenuOpen(false);\n setShowFullMenu(false);\n }, [isMenuOpen]);\n\n const handleMenuButtonClick = useCallback((e: MouseEvent) => {\n e.stopPropagation();\n setMenuOpen((prevIsOpen) => {\n const isOpening = !prevIsOpen;\n if (isOpening && e.shiftKey) setShowFullMenu(true);\n else if (!isOpening) setShowFullMenu(false);\n return isOpening;\n });\n }, []);\n\n const menuCommandHandler = useCallback(\n (command: Command) => {\n handleMenuItemClick();\n return commandHandler(command);\n },\n [commandHandler, handleMenuItemClick],\n );\n\n const [offset, setOffset] = useState({ top: 1, left: 1 });\n\n useEffect(() => {\n if (isMenuOpen) {\n const node = containerRef?.current;\n if (node) {\n const rect = node.getBoundingClientRect();\n const scrollTop = window.scrollY;\n const scrollLeft = window.scrollX;\n const top = rect.top + scrollTop + node.clientHeight;\n const left = rect.left + scrollLeft;\n setOffset({ top, left });\n }\n }\n }, [isMenuOpen, containerRef]);\n\n const [normalMenuData] = usePromise(\n useCallback(async () => {\n return menuProvider?.(false) ?? normalMenu;\n // isMenuOpen needs to be included for the menu contents to reevaluate when reopened\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [menuProvider, normalMenu, isMenuOpen]),\n normalMenu,\n );\n\n const [fullMenuData] = usePromise(\n useCallback(async () => {\n return menuProvider?.(true) ?? fullMenu ?? normalMenuData;\n // isMenuOpen needs to be included for the menu contents to reevaluate when reopened\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [menuProvider, fullMenu, normalMenuData, isMenuOpen]),\n fullMenu ?? normalMenuData,\n );\n\n const menu = showFullMenu && fullMenuData ? fullMenuData : normalMenuData;\n\n return (\n <>\n \n {children ?? }\n \n \n {menu ? (\n \n ) : undefined}\n \n \n );\n}\n","import '@/components/mui/icon-button.component.css';\nimport { IconButton as MuiIconButton } from '@mui/material';\nimport { MouseEventHandler, PropsWithChildren } from 'react';\n\nexport type IconButtonProps = PropsWithChildren<{\n /** Optional unique identifier */\n id?: string;\n /**\n * Required. Used as both the tooltip (aka, title) and the aria-label (used for accessibility,\n * testing, etc.), unless a distinct tooltip is supplied.\n */\n label: string;\n /**\n * Enabled status of button\n *\n * @default false\n */\n isDisabled?: boolean;\n /** Optional tooltip to display if different from the aria-label. */\n tooltip?: string;\n /** If true, no tooltip will be displayed. */\n isTooltipSuppressed?: boolean;\n /**\n * If given, uses a negative margin to counteract the padding on one side (this is often helpful\n * for aligning the left or right side of the icon with content above or below, without ruining\n * the border size and shape).\n *\n * @default false\n */\n adjustMarginToAlignToEdge?: 'end' | 'start' | false;\n /**\n * The size of the component. small is equivalent to the dense button styling.\n *\n * @default false\n */\n size: 'small' | 'medium' | 'large';\n /** Additional css classes to help with unique styling of the button */\n className?: string;\n /** Optional click handler */\n onClick?: MouseEventHandler;\n}>;\n\n/**\n * Iconic button a user can click to do something\n *\n * Thanks to MUI for heavy inspiration and documentation\n * https://mui.com/material-ui/getting-started/overview/\n */\nfunction IconButton({\n id,\n label,\n isDisabled = false,\n tooltip,\n isTooltipSuppressed = false,\n adjustMarginToAlignToEdge = false,\n size = 'medium',\n className,\n onClick,\n children,\n}: IconButtonProps) {\n return (\n \n {children /* the icon to display */}\n \n );\n}\n\nexport default IconButton;\n","import { cn } from '@/utils/shadcn-ui.util';\nimport { LoaderCircle, LucideProps } from 'lucide-react';\nimport { forwardRef } from 'react';\n\nexport type SpinnerProps = LucideProps;\n\nconst Spinner = forwardRef(({ className, ...props }, ref) => {\n return (\n \n );\n});\n\nSpinner.displayName = 'Spinner';\n\nexport default Spinner;\n","import { Input as ShadInput } from '@/components/shadcn-ui/input';\nimport { Label as ShadLabel } from '@/components/shadcn-ui/label';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { ChangeEventHandler, FocusEventHandler } from 'react';\n\nexport type TextFieldProps = {\n /** Optional unique identifier */\n id?: string;\n /**\n * If `true`, the component is disabled.\n *\n * @default false\n */\n isDisabled?: boolean;\n /**\n * If `true`, the label is displayed in an error state.\n *\n * @default false\n */\n hasError?: boolean;\n /**\n * If `true`, the input will take up the full width of its container.\n *\n * @default false\n */\n isFullWidth?: boolean;\n /** Text that gives the user instructions on what contents the TextField expects */\n helperText?: string;\n /** The title of the TextField */\n label?: string;\n /** The short hint displayed in the `input` before the user enters a value. */\n placeholder?: string;\n /**\n * If `true`, the label is displayed as required and the `input` element is required.\n *\n * @default false\n */\n isRequired?: boolean;\n /** Additional css classes to help with unique styling of the text field */\n className?: string;\n /** Starting value for the text field if it is not controlled */\n defaultValue?: string | number;\n /** Value of the text field if controlled */\n value?: string | number;\n /** Triggers when content of textfield is changed */\n onChange?: ChangeEventHandler;\n /** Triggers when textfield gets focus */\n onFocus?: FocusEventHandler;\n /** Triggers when textfield loses focus */\n onBlur?: FocusEventHandler;\n};\n\n/**\n * Text input field\n *\n * Thanks to Shadcn for heavy inspiration and documentation\n * https://ui.shadcn.com/docs/components/input#with-label\n */\nfunction TextField({\n id,\n isDisabled = false,\n hasError = false,\n isFullWidth = false,\n helperText,\n label,\n placeholder,\n isRequired = false,\n className,\n defaultValue,\n value,\n onChange,\n onFocus,\n onBlur,\n}: TextFieldProps) {\n return (\n
    \n {`${label}${isRequired ? '*' : ''}`}\n \n

    {helperText}

    \n
    \n );\n}\n\nexport default TextField;\n","import HamburgerMenuButton, {\n MultiColumnMenuProvider,\n} from '@/components/mui/hamburger-menu-button.component';\nimport { CommandHandler } from '@/components/mui/menu-item.component';\nimport '@/components/mui/toolbar.component.css';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { AppBar, Toolbar as MuiToolbar } from '@mui/material';\nimport { PropsWithChildren, useRef } from 'react';\n\nexport type ToolbarProps = PropsWithChildren<{\n /** The handler to use for menu commands (and eventually toolbar commands). */\n commandHandler: CommandHandler;\n\n /**\n * The optional delegate to use to get the menu data. If not specified, the \"hamburger\" menu will\n * not display.\n */\n menuProvider?: MultiColumnMenuProvider;\n\n /** Optional unique identifier */\n id?: string;\n\n /** Additional css classes to help with unique styling of the toolbar */\n className?: string;\n}>;\n\nexport default function Toolbar({\n menuProvider,\n commandHandler,\n className,\n id,\n children,\n}: ToolbarProps) {\n // This ref will always be defined\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const containerRef = useRef(undefined!);\n\n return (\n
    \n \n \n {menuProvider ? (\n \n ) : undefined}\n {children ?
    {children}
    : undefined}\n \n
    \n
    \n );\n}\n","import React from 'react';\nimport { cva, type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst alertVariants = cva(\n 'tw-relative tw-w-full tw-rounded-lg tw-border tw-p-4 [&>svg~*]:tw-pl-7 [&>svg+div]:tw-translate-y-[-3px] [&>svg]:tw-absolute [&>svg]:tw-left-4 [&>svg]:tw-top-4 [&>svg]:tw-text-foreground',\n {\n variants: {\n variant: {\n default: 'tw-bg-background tw-text-foreground',\n destructive:\n 'tw-border-destructive/50 tw-text-destructive dark:tw-border-destructive [&>svg]:tw-text-destructive',\n },\n },\n defaultVariants: {\n variant: 'default',\n },\n },\n);\n\nconst Alert = React.forwardRef<\n HTMLDivElement,\n React.HTMLAttributes & VariantProps\n>(({ className, variant, ...props }, ref) => (\n
    \n));\nAlert.displayName = 'Alert';\n\nconst AlertTitle = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n {/* added because of https://github.com/jsx-eslint/eslint-plugin-jsx-a11y/blob/main/docs/rules/heading-has-content.md */}\n {props.children}{' '}\n \n ),\n);\nAlertTitle.displayName = 'AlertTitle';\n\nconst AlertDescription = React.forwardRef<\n HTMLParagraphElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n
    \n));\nAlertDescription.displayName = 'AlertDescription';\n\nexport { Alert, AlertTitle, AlertDescription };\n","import React from 'react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Card = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nCard.displayName = 'Card';\n\nconst CardHeader = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nCardHeader.displayName = 'CardHeader';\n\nconst CardTitle = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n {/* added because of https://github.com/jsx-eslint/eslint-plugin-jsx-a11y/blob/main/docs/rules/heading-has-content.md */}\n {props.children}\n \n ),\n);\nCardTitle.displayName = 'CardTitle';\n\nconst CardDescription = React.forwardRef<\n HTMLParagraphElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n

    \n));\nCardDescription.displayName = 'CardDescription';\n\nconst CardContent = React.forwardRef>(\n ({ className, ...props }, ref) => (\n

    \n ),\n);\nCardContent.displayName = 'CardContent';\n\nconst CardFooter = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nCardFooter.displayName = 'CardFooter';\n\nexport { Card, CardHeader, CardFooter, CardTitle, CardDescription, CardContent };\n","import { ComponentProps } from 'react';\nimport { toast as sonner, Toaster } from 'sonner';\n\ntype SonnerProps = ComponentProps;\n\nfunction Sonner({ ...props }: SonnerProps) {\n return (\n \n );\n}\n\n// The re-export of the sonner function was added manually\nexport { Sonner, sonner };\n","import React from 'react';\nimport * as SliderPrimitive from '@radix-ui/react-slider';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Slider = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n \n \n \n));\nSlider.displayName = SliderPrimitive.Root.displayName;\n\nexport { Slider };\n","import React from 'react';\nimport * as SwitchPrimitives from '@radix-ui/react-switch';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Switch = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n));\nSwitch.displayName = SwitchPrimitives.Root.displayName;\n\nexport { Switch };\n","import React from 'react';\nimport * as TabsPrimitive from '@radix-ui/react-tabs';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport const Tabs = TabsPrimitive.Root;\n\nexport type TabsListProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport type TabsTriggerProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport type TabsContentProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport const TabsList = React.forwardRef<\n React.ElementRef,\n TabsListProps\n>(({ className, ...props }, ref) => (\n \n));\nTabsList.displayName = TabsPrimitive.List.displayName;\n\nexport const TabsTrigger = React.forwardRef<\n React.ElementRef,\n TabsTriggerProps\n>(({ className, ...props }, ref) => (\n \n));\nTabsTrigger.displayName = TabsPrimitive.Trigger.displayName;\n\nexport const TabsContent = React.forwardRef<\n React.ElementRef,\n TabsContentProps\n>(({ className, ...props }, ref) => (\n \n));\nTabsContent.displayName = TabsPrimitive.Content.displayName;\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Download } from 'lucide-react';\n\ntype InstallButtonProps = {\n /** The installing boolean value determines the state of the button. */\n isInstalling: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n /** Optional text for the button. */\n buttonText?: string;\n} & ButtonProps;\n\n/**\n * The InstallButton component is a button designed for initiating installs. It includes visuals for\n * active installing and idle states.\n *\n * @param isInstalling The installing boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @param buttonText Optional text for the button.\n * @returns A install button.\n */\nexport default function InstallButton({\n isInstalling,\n handleClick,\n buttonText,\n className,\n ...props\n}: InstallButtonProps) {\n return (\n \n {isInstalling ? (\n \n ) : (\n <>\n \n {buttonText}\n \n )}\n \n );\n}\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\n\ntype EnableButtonProps = {\n /** The enabling boolean value determines the state of the button. */\n isEnabling: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n} & ButtonProps;\n\n/**\n * The EnableButton component is a button designed for initiating enabling of downloads. It includes\n * visuals for active enabling and idle states.\n *\n * @param isEnabling The enabling boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @returns A button that can be used to enable.\n */\nexport default function EnableButton({\n isEnabling,\n handleClick,\n className,\n ...props\n}: EnableButtonProps) {\n return (\n \n {isEnabling ? (\n <>\n \n Enabling...\n \n ) : (\n 'Enable'\n )}\n \n );\n}\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\n\ntype DisableButtonProps = {\n /** The disabling boolean value determines the state of the button. */\n isDisabling: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n} & ButtonProps;\n\n/**\n * The DisableButton component is a button designed for initiating disabling of downloads. It\n * includes visuals for active disabling and idle states.\n *\n * @param isDisabling The disabling boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @returns A button that can be used to disable.\n */\nexport default function DisableButton({\n isDisabling,\n handleClick,\n className,\n ...props\n}: DisableButtonProps) {\n return (\n \n {isDisabling ? (\n <>\n \n Disabling...\n \n ) : (\n 'Disable'\n )}\n \n );\n}\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\n\ntype UpdateButtonProps = {\n /** The updating boolean value determines the state of the button. */\n isUpdating: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n} & ButtonProps;\n\n/**\n * The UpdateButton component is a button designed for initiating updates for downloaded extensions.\n * It includes visuals for active updating and idle states.\n *\n * @param isUpdating The updating boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @returns A button that can be used to update.\n */\nexport default function UpdateButton({\n isUpdating,\n handleClick,\n className,\n ...props\n}: UpdateButtonProps) {\n return (\n \n {isUpdating ? (\n <>\n \n Updating...\n \n ) : (\n 'Update'\n )}\n \n );\n}\n","import { cn } from '@/utils/shadcn-ui.util';\nimport Markdown, { MarkdownToJSX } from 'markdown-to-jsx';\nimport { useMemo } from 'react';\n\ninterface MarkdownRendererProps {\n /** Optional unique identifier */\n id?: string;\n /** The markdown string to render */\n markdown: string;\n className?: string;\n /**\n * The [`target` attribute for `a` html\n * tags](https://developer.mozilla.org/en-US/docs/Web/HTML/Element/a#target). Defaults to not\n * adding a `target` to `a` tags\n */\n anchorTarget?: string;\n}\n\n/**\n * This component renders markdown content given a markdown string. It uses typography styles from\n * the platform.\n *\n * @param markdown The markdown string to render.\n * @param id Optional unique identifier\n * @returns A div containing the rendered markdown content.\n */\nexport default function MarkdownRenderer({\n id,\n markdown,\n className,\n anchorTarget,\n}: MarkdownRendererProps) {\n const options: MarkdownToJSX.Options = useMemo(\n () => ({\n overrides: {\n a: {\n props: {\n target: anchorTarget,\n },\n },\n },\n }),\n [anchorTarget],\n );\n return (\n
    \n {markdown}\n
    \n );\n}\n","import { Filter, ChevronDown } from 'lucide-react';\nimport { forwardRef } from 'react';\nimport { Button } from '@/components/shadcn-ui/button';\n\n/**\n * The FilterButton component is a button designed for initiating filtering of data. It is designed\n * to be used with the dropdown menu. It uses forwardRef to pass the button to the dropdown trigger\n * asChild.\n *\n * @returns A button that can be used to filter.\n */\nconst FilterButton = forwardRef((props, ref) => {\n return (\n \n \n Filter\n \n \n );\n});\n\nexport default FilterButton;\n","import {\n DropdownMenu,\n DropdownMenuTrigger,\n DropdownMenuContent,\n DropdownMenuLabel,\n DropdownMenuGroup,\n DropdownMenuCheckboxItem,\n DropdownMenuRadioItem,\n DropdownMenuSeparator,\n} from '@/components/shadcn-ui/dropdown-menu';\nimport FilterButton from './buttons/filter-button.component';\n\nexport enum DropdownMenuItemType {\n Check,\n Radio,\n}\n\nexport type DropdownItem = {\n /** The label is the text that will be displayed on the dropdown item. */\n label: string;\n /** The itemType determines the DropdownMenuItemType type as either Check or Radio. */\n itemType: DropdownMenuItemType;\n /** The onClick function is called when the item is clicked. */\n onClick: () => void;\n};\n\nexport type DropdownGroup = {\n /**\n * The label is the text that will be displayed on the dropdown group. It is used to categorize\n * the items in the group.\n */\n label: string;\n /** The items array contains the items that will be displayed in the dropdown group */\n items: DropdownItem[];\n};\n\nexport type FilterDropdownProps = {\n /** Object unique identifier */\n id?: string;\n /** The groups array contains the groups that will be displayed in the dropdown */\n groups: DropdownGroup[];\n}; // TODO: extend the props later\n\n/**\n * The FilterDropdown component is a dropdown designed for filtering content. It includes groups of\n * items that can be checkboxes or radio items.\n *\n * @param id Optional unique identifier\n * @param groups The groups array contains the groups that will be displayed in the dropdown\n * @returns A filter dropdown.\n */\nexport default function FilterDropdown({ id, groups }: FilterDropdownProps) {\n return (\n
    \n {/* TODO: remove this once the DropDown Menu shadcn has an id prop */}\n \n \n \n \n \n {groups.map((group) => (\n
    \n {group.label}\n \n {group.items.map((item) => (\n
    \n {item.itemType === DropdownMenuItemType.Check ? (\n \n {item.label}\n \n ) : (\n \n {item.label}\n \n )}\n
    \n ))}\n
    \n \n
    \n ))}\n
    \n
    \n
    \n );\n}\n","interface NoExtensionsFoundProps {\n /** Optional unique identifier */\n id?: string;\n /** The message to display */\n message: string;\n}\n/**\n * This component displays a message to the user when no extensions are found in the marketplace.\n *\n * @param id Optional unique identifier\n * @param message The message to display.\n * @returns {JSX.Element} - Returns the message component that displays the message to the user.\n */\nexport default function NoExtensionsFound({ id, message }: NoExtensionsFoundProps) {\n return (\n
    \n
    \n

    {message}

    \n
    \n
    \n );\n}\n","import { CircleHelp, Link as LucideLink, User } from 'lucide-react';\nimport { NumberFormat } from 'platform-bible-utils';\n\n/** Interface that stores the parameters passed to the More Info component */\ninterface MoreInfoProps {\n /** Optional unique identifier */\n id?: string;\n /** The category of the extension */\n category: string;\n /** The number of downloads for the extension */\n downloads: Record;\n /** The languages supported by the extension */\n languages: string[];\n /** The URL to the more info page of the extension */\n moreInfoUrl: string;\n}\n/**\n * This component displays the more info section of the extension which includes the category,\n * number of downloads, languages, and links to the website and support\n *\n * @param id Optional unique identifier\n * @param category The category of the extension\n * @param downloads The number of downloads for the extension\n * @param languages The languages supported by the extension\n * @param moreInfoUrl The URL to the more info page of the extension\n * @returns {JSX.Element} - Returns the more info component that displays the category, number of\n * downloads, languages, and links to the website and support\n */\nexport default function MoreInfo({\n id,\n category,\n downloads,\n languages,\n moreInfoUrl,\n}: MoreInfoProps) {\n /**\n * This constant formats the number of downloads into a more readable format.\n *\n * @example 1000 -> 1K\n *\n * @example 1000000 -> 1M\n *\n * @returns The formatted number of downloads\n */\n const numberFormatted = new NumberFormat('en', {\n notation: 'compact',\n compactDisplay: 'short',\n }).format(Object.values(downloads).reduce((a: number, b: number) => a + b, 0));\n\n /** This function scrolls the window to the bottom of the page. */\n const handleScrollToBottom = () => {\n window.scrollTo(0, document.body.scrollHeight);\n };\n\n return (\n \n
    \n
    \n {category}\n
    \n CATEGORY\n
    \n
    \n
    \n
    \n \n {numberFormatted}\n
    \n USERS\n
    \n
    \n
    \n
    \n {languages.slice(0, 3).map((locale) => (\n \n {locale.toUpperCase()}\n \n ))}\n
    \n {languages.length > 3 && (\n handleScrollToBottom()}\n className=\"tw-text-xs tw-text-gray-500 tw-underline\"\n >\n +{languages.length - 3} more languages\n \n )}\n
    \n
    \n
    \n \n Website\n \n \n \n Support\n \n \n
    \n
    \n );\n}\n","import { useState } from 'react';\n\nexport type VersionInformation = {\n /** Date the version was published */\n date: string;\n /** Description of the changes in the version */\n description: string;\n};\n\n/** Type to store the version history information */\nexport type VersionHistoryType = Record;\n\n/** Interface that stores the parameters passed to the Version History component */\ninterface VersionHistoryProps {\n /** Optional unique identifier */\n id?: string;\n /** Object containing the versions mapped with their information */\n versionHistory: VersionHistoryType;\n}\n\n/**\n * Component to render the version history information shown in the footer component. Lists the 5\n * most recent versions, with the options to show all versions by pressing a button.\n *\n * @param versionHistory Object containing the versions mapped with their information\n * @param id Optional unique identifier\n * @returns Rendered version history for the Footer component\n */\nexport default function VersionHistory({ id, versionHistory }: VersionHistoryProps) {\n const [showAllVersions, setShowAllVersions] = useState(false);\n const currentDate = new Date();\n\n /**\n * Function to format the time string for the version history in the form of 'X year(s) ago'.\n *\n * @param dateString ISO Date string to determine the time string from\n * @returns Formatted time string\n */\n function formatTimeString(dateString: string) {\n const date = new Date(dateString);\n const dateDiff = new Date(currentDate.getTime() - date.getTime());\n const yearDiff = dateDiff.getUTCFullYear() - 1970;\n const monthDiff = dateDiff.getUTCMonth();\n const dayDiff = dateDiff.getUTCDate() - 1;\n\n // Determines how long ago the version was published\n let timeString = '';\n if (yearDiff > 0) {\n timeString = `${yearDiff.toString()} year${yearDiff === 1 ? '' : 's'} ago`;\n } else if (monthDiff > 0) {\n timeString = `${monthDiff.toString()} month${monthDiff === 1 ? '' : 's'} ago`;\n } else if (dayDiff === 0) {\n timeString = 'today';\n } else {\n timeString = `${dayDiff.toString()} day${dayDiff === 1 ? '' : 's'} ago`;\n }\n\n return timeString;\n }\n\n // Sorts the version history by version number\n const sortedEntries = Object.entries(versionHistory).sort((a, b) => b[0].localeCompare(a[0]));\n\n return (\n
    \n

    What`s New

    \n
      \n {(showAllVersions ? sortedEntries : sortedEntries.slice(0, 5)).map((entry) => (\n
      \n
      \n
    • \n {entry[1].description}\n
    • \n
      \n
      \n
      Version {entry[0]}
      \n
      {formatTimeString(entry[1].date)}
      \n
      \n
      \n ))}\n
    \n {sortedEntries.length > 5 && (\n setShowAllVersions(!showAllVersions)}\n className=\"tw-text-xs tw-text-gray-500 tw-underline\"\n >\n {showAllVersions ? 'Show Less Version History' : 'Show All Version History'}\n \n )}\n
    \n );\n}\n","import { useMemo } from 'react';\nimport { formatBytes } from 'platform-bible-utils';\nimport VersionHistory, { VersionHistoryType } from './version-history.component';\n\n/** Interface to store the parameters passed to the Footer component */\ninterface FooterProps {\n /** Optional unique identifier */\n id?: string;\n /** Name of the publisher */\n publisherDisplayName: string;\n /** Size of the extension file in bytes */\n fileSize: number;\n /** List of language codes supported by the extension */\n locales: string[];\n /** Object containing the version history mapped with their information */\n versionHistory: VersionHistoryType;\n}\n\n/**\n * Component to render the footer for the extension details which contains information on the\n * publisher, version history, languages, and file size.\n *\n * @param id Optional unique identifier\n * @param publisherDisplayName Name of the publisher\n * @param fileSize Size of the extension file in bytes\n * @param locales List of language codes supported by the extension\n * @param versionHistory Object containing the version history mapped with their information\n * @returns The rendered Footer component\n */\nexport default function Footer({\n id,\n publisherDisplayName,\n fileSize,\n locales,\n versionHistory,\n}: FooterProps) {\n /** Formats the file size into a human-readable format */\n const formattedFileSize = useMemo(() => formatBytes(fileSize), [fileSize]);\n\n /**\n * This function gets the display names of the languages based on the language codes.\n *\n * @param codes The list of language codes\n * @returns The list of language names\n */\n const getLanguageNames = (codes: string[]) => {\n const displayNames = new Intl.DisplayNames(navigator.language, { type: 'language' });\n return codes.map((code) => displayNames.of(code));\n };\n\n const languageNames = getLanguageNames(locales);\n\n return (\n
    \n
    \n \n
    \n
    \n

    Information

    \n
    \n

    \n Publisher\n {publisherDisplayName}\n Size\n {formattedFileSize}\n

    \n
    \n

    \n Languages\n {languageNames.join(', ')}\n

    \n
    \n
    \n
    \n
    \n
    \n );\n}\n","import { PlatformEvent, PlatformEventHandler } from 'platform-bible-utils';\nimport { useEffect } from 'react';\n\n/**\n * Adds an event handler to an event so the event handler runs when the event is emitted. Use\n * `papi.network.getNetworkEvent` to use a networked event with this hook.\n *\n * @param event The event to subscribe to.\n *\n * - If event is a `PlatformEvent`, that event will be used\n * - If event is undefined, the callback will not be subscribed. Useful if the event is not yet\n * available for example\n *\n * @param eventHandler The callback to run when the event is emitted\n *\n * WARNING: MUST BE STABLE - const or wrapped in useCallback. The reference must not be updated\n * every render\n */\nconst useEvent = (\n event: PlatformEvent | undefined,\n eventHandler: PlatformEventHandler,\n) => {\n useEffect(() => {\n // Do nothing if the event is not provided (in case the event is not yet available, for example)\n if (!event) return () => {};\n\n const unsubscriber = event(eventHandler);\n return () => {\n unsubscriber();\n };\n }, [event, eventHandler]);\n};\nexport default useEvent;\n","import { useCallback, useEffect } from 'react';\nimport { PlatformEvent, PlatformEventAsync, PlatformEventHandler } from 'platform-bible-utils';\nimport usePromise from './use-promise.hook';\n\nconst noopUnsubscriber = () => false;\n\n/**\n * Adds an event handler to an asynchronously subscribing/unsubscribing event so the event handler\n * runs when the event is emitted. Use `papi.network.getNetworkEvent` to use a networked event with\n * this hook.\n *\n * @param event The asynchronously (un)subscribing event to subscribe to.\n *\n * - If event is a `PlatformEvent` or `PlatformEventAsync`, that event will be used\n * - If event is undefined, the callback will not be subscribed. Useful if the event is not yet\n * available for example\n *\n * @param eventHandler The callback to run when the event is emitted\n *\n * WARNING: MUST BE STABLE - const or wrapped in useCallback. The reference must not be updated\n * every render\n */\nconst useEventAsync = (\n event: PlatformEvent | PlatformEventAsync | undefined,\n eventHandler: PlatformEventHandler,\n) => {\n // Subscribe to the event asynchronously\n const [unsubscribe] = usePromise(\n useCallback(async () => {\n // Do nothing if the event is not provided (in case the event is not yet available, for example)\n if (!event) return noopUnsubscriber;\n\n // Wrap subscribe and unsubscribe in promises to allow normal events to be used as well\n const unsub = await Promise.resolve(event(eventHandler));\n return async () => unsub();\n }, [eventHandler, event]),\n noopUnsubscriber,\n // We want the unsubscriber to return to default value immediately upon changing subscription\n // So the useEffect below will unsubscribe asap\n { preserveValue: false },\n );\n\n // Unsubscribe from the event asynchronously (but we aren't awaiting the unsub)\n useEffect(() => {\n return () => {\n if (unsubscribe !== noopUnsubscriber) {\n unsubscribe();\n }\n };\n }, [unsubscribe]);\n};\n\nexport default useEventAsync;\n"],"names":["twMergeCustom","extendTailwindMerge","cn","inputs","clsx","Input","React","className","type","props","ref","jsx","BookChapterInput","forwardRef","handleSearch","handleKeyDown","handleOnClick","handleSubmit","jsxs","ShadInput","event","e","History","P","R","s","n","N","B","O","S","K","g","k","x","T","X","V","w","L","G","A","H","C","I","y","q","U","m","l","h","c","E","D","i","a","o","u","v","f","d","b","J","DropdownMenu","DropdownMenuPrimitive","DropdownMenuTrigger","DropdownMenuGroup","DropdownMenuPortal","DropdownMenuSub","DropdownMenuRadioGroup","DropdownMenuSubTrigger","inset","children","ChevronRight","DropdownMenuSubContent","DropdownMenuContent","sideOffset","DropdownMenuItem","DropdownMenuCheckboxItem","checked","Check","DropdownMenuRadioItem","Circle","DropdownMenuLabel","DropdownMenuSeparator","DropdownMenuShortcut","BookMenuItem","bookId","handleSelectBook","isSelected","handleHighlightBook","bookType","ShadDropdownMenuItem","Canon","ChapterSelect","handleSelectChapter","endChapter","activeChapter","highlightedChapter","handleHighlightedChapter","chapters","_","handleMouse","useCallback","chapterNumber","chapter","GoToMenuItem","handleSort","handleLocationHistory","handleBookmarks","ShadDropdownMenuLabel","ArrowDownWideNarrow","Clock","Bookmark","ALL_BOOK_IDS","BOOK_TYPE_LABELS","BOOK_TYPE_ARRAY","SCROLL_OFFSET","SEARCH_QUERY_FORMATS","fetchGroupedBooks","fetchEndChapter","getChaptersForBook","getAllEnglishNames","isValidBookEnglishName","bookName","getBookIdFromEnglishName","formattedBookName","BookChapterControl","scrRef","searchQuery","setSearchQuery","useState","selectedBookId","setSelectedBookId","setHighlightedChapter","highlightedBookId","setHighlightedBookId","isContentOpen","setIsContentOpen","isContentOpenDelayed","setIsContentOpenDelayed","inputRef","useRef","contentRef","menuItemRef","fetchFilteredBooks","englishNameLowerCase","normalizedQuery","handleSearchInput","searchString","shouldPreventAutoClosing","controlMenuState","open","updateReference","shouldClose","verse","handleInputSubmit","format","matches","book","englishName","handleKeyDownInput","handleKeyDownContent","key","handleKeyDownMenuItem","chapterOffSet","useEffect","useLayoutEffect","scrollTimeout","scrollPosition","ShadDropdownMenu","ShadDropdownMenuTrigger","ShadDropdownMenuContent","bookTypeIndex","element","ShadDropdownMenuSeparator","buttonVariants","cva","Button","variant","size","asChild","Slot","labelVariants","Label","LabelPrimitive","RadioGroup","RadioGroupPrimitive","RadioGroupItem","Popover","PopoverPrimitive","PopoverTrigger","PopoverContent","align","DialogPortal","DialogPrimitive","DialogOverlay","DialogContent","DialogTitle","DialogDescription","Command","CommandPrimitive","CommandInput","Search","CommandList","CommandEmpty","CommandGroup","CommandSeparator","CommandItem","getOptionLabelDefault","option","ComboBox","id","options","buttonClassName","popoverContentClassName","value","onChange","getOptionLabel","buttonPlaceholder","textPlaceholder","commandEmptyMessage","buttonVariant","dir","isDisabled","setOpen","ChevronsUpDown","ChapterRangeSelector","startChapter","handleSelectStartChapter","handleSelectEndChapter","chapterCount","chapterOptions","useMemo","index","Fragment","BookSelectionMode","BOOK_SELECTOR_STRING_KEYS","localizeString","strings","BookSelector","handleBookSelectionModeChange","currentBookName","onSelectBooks","selectedBookIds","localizedStrings","currentBookText","chooseText","chooseBooksText","bookSelectionMode","setBookSelectionMode","onSelectionModeChange","newMode","DataTableViewOptions","table","FilterIcon","column","Select","SelectPrimitive","SelectGroup","SelectValue","SelectTrigger","ChevronDown","SelectScrollUpButton","ChevronUp","SelectScrollDownButton","SelectContent","position","SelectLabel","SelectItem","SelectSeparator","DataTablePagination","pageSize","ArrowLeftIcon","ChevronLeftIcon","ChevronRightIcon","ArrowRightIcon","Table","stickyHeader","TableHeader","TableBody","TableFooter","TableRow","TableHead","TableCell","TableCaption","DataTable","columns","data","enablePagination","showPaginationControls","showColumnVisibilityControls","onRowClickHandler","sorting","setSorting","columnFilters","setColumnFilters","columnVisibility","setColumnVisibility","rowSelection","setRowSelection","useReactTable","getCoreRowModel","getPaginationRowModel","getSortedRowModel","getFilteredRowModel","headerGroup","header","flexRender","_a","row","cell","OccurrencesTable","occurrenceData","setScriptureReference","referenceHeaderText","occurrenceHeaderText","occurrences","uniqueOccurrences","occurrence","uniqueOccurrence","deepEqual","Checkbox","CheckboxPrimitive","getLinesFromUSFM","text","getNumberFromUSFM","regex","match","getBookNumFromId","getStatusForItem","item","approvedItems","unapprovedItems","toggleVariants","Toggle","TogglePrimitive","ToggleGroupContext","ToggleGroup","ToggleGroupPrimitive","ToggleGroupItem","context","getSortingIcon","sortDirection","ArrowUpIcon","ArrowDownIcon","ArrowUpDownIcon","inventoryItemColumn","itemLabel","inventoryAdditionalItemColumn","additionalItemLabel","additionalItemIndex","inventoryCountColumn","countLabel","statusChangeHandler","changedItems","newStatus","onApprovedItemsChange","onUnapprovedItemsChange","newApprovedItems","validItem","newUnapprovedItems","unapprovedItem","inventoryStatusColumn","statusLabel","status","CircleCheckIcon","CircleXIcon","CircleHelpIcon","INVENTORY_STRING_KEYS","filterItemData","itemData","statusFilter","textFilter","filteredItemData","createTableData","scriptureRef","itemRegex","tableData","currentBook","currentChapter","currentVerse","line","items","itemIndex","existingItem","tableEntry","newReference","substring","newItem","Inventory","scriptureReference","extractItems","additionalItemsLabels","scope","onScopeChange","allItemsText","approvedItemsText","unapprovedItemsText","unknownItemsText","scopeBookText","scopeChapterText","scopeVerseText","filterText","showAdditionalItemsText","showAdditionalItems","setShowAdditionalItems","setStatusFilter","setTextFilter","selectedItem","setSelectedItem","reducedTableData","newTableData","firstItem","existingEntry","newTableEntry","filteredTableData","allColumns","numberOfAdditionalItems","additionalColumns","_b","rowClickHandler","newSelection","handleScopeChange","handleStatusFilterChange","SearchBar","onSearch","placeholder","isFullWidth","handleInputChange","VerticalTabs","TabsPrimitive","VerticalTabsList","VerticalTabsTrigger","VerticalTabsContent","TabNavigationContentSearch","tabList","searchPlaceholder","headerTitle","isSearchBarFullWidth","direction","tab","Separator","orientation","decorative","SeparatorPrimitive","Skeleton","TooltipProvider","TooltipPrimitive","Tooltip","TooltipTrigger","TooltipContent","SIDEBAR_WIDTH","SIDEBAR_WIDTH_ICON","SIDEBAR_KEYBOARD_SHORTCUT","SidebarContext","useSidebar","SidebarProvider","defaultOpen","openProp","setOpenProp","style","_open","_setOpen","isOpen","openState","toggleSidebar","state","contextValue","Sidebar","side","collapsible","SidebarTrigger","onClick","PanelLeft","SidebarRail","SidebarInset","SidebarInput","SidebarHeader","SidebarFooter","SidebarSeparator","SidebarContent","SidebarGroup","SidebarGroupLabel","SidebarGroupAction","SidebarGroupContent","SidebarMenu","SidebarMenuItem","sidebarMenuButtonVariants","SidebarMenuButton","isActive","tooltip","Comp","button","SidebarMenuAction","showOnHover","SidebarMenuBadge","SidebarMenuSkeleton","showIcon","width","SidebarMenuSub","SidebarMenuSubItem","SidebarMenuSubButton","SettingsSidebar","extensionLabels","projectOptions","handleSelectSidebarItem","selectedSidebarItem","extensionsSidebarGroupLabel","projectsSidebarGroupLabel","buttonPlaceholderText","handleSelectItem","projectId","getProjectNameFromProjectId","project","getIsActive","label","selectedProjectName","SettingsSidebarContentSearch","scrBookColId","scrRefColId","typeColId","detailsColId","defaultScrRefColumnName","defaultScrBookGroupName","defaultTypeColumnName","defaultDetailsColumnName","getColumns","colInfo","showSourceColumn","showSrcCol","info","formatScrRef","compareScrRefs","toRefOrRange","scriptureSelection","offsetStart","offsetEnd","scrRefToBBBCCCVVV","getRowKey","ScriptureResultsViewer","sources","showColumnHeaders","scriptureReferenceColumnName","scriptureBookGroupName","typeColumnName","detailsColumnName","onRowSelected","grouping","setGrouping","scriptureResults","source","getExpandedRowModel","getGroupedRowModel","selectedRows","keys","selectedRow","scrBookGroupName","typeGroupName","groupingOptions","handleSelectChange","selectedGrouping","handleRowClick","getEvenOrOddBandingStyle","getIndent","groupingState","rowIndex","ChevronLeft","DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS","getLocalizeKeyForScrollGroupId","ScrollGroupSelector","availableScrollGroupIds","scrollGroupId","onChangeScrollGroupId","localizedStringsDefaulted","localizedStringKey","localizedStringValue","newScrollGroupString","scrollGroupOptionId","SettingsList","SettingsListItem","primary","secondary","isLoading","loadingMessage","SettingsListHeader","includeSeparator","Checklist","listItems","selectedListItems","handleSelectListItem","createLabel","_interopRequireDefault","obj","module","chainPropTypes","propType1","propType2","args","_extends","target","isPlainObject","prototype","deepClone","output","deepmerge","p","r","t","z","reactIs_production_min","hasSymbol","REACT_ELEMENT_TYPE","REACT_PORTAL_TYPE","REACT_FRAGMENT_TYPE","REACT_STRICT_MODE_TYPE","REACT_PROFILER_TYPE","REACT_PROVIDER_TYPE","REACT_CONTEXT_TYPE","REACT_ASYNC_MODE_TYPE","REACT_CONCURRENT_MODE_TYPE","REACT_FORWARD_REF_TYPE","REACT_SUSPENSE_TYPE","REACT_SUSPENSE_LIST_TYPE","REACT_MEMO_TYPE","REACT_LAZY_TYPE","REACT_BLOCK_TYPE","REACT_FUNDAMENTAL_TYPE","REACT_RESPONDER_TYPE","REACT_SCOPE_TYPE","isValidElementType","typeOf","object","$$typeof","$$typeofType","AsyncMode","ConcurrentMode","ContextConsumer","ContextProvider","Element","ForwardRef","Lazy","Memo","Portal","Profiler","StrictMode","Suspense","hasWarnedAboutDeprecatedIsAsyncMode","isAsyncMode","isConcurrentMode","isContextConsumer","isContextProvider","isElement","isForwardRef","isFragment","isLazy","isMemo","isPortal","isProfiler","isStrictMode","isSuspense","reactIs_development","reactIsModule","require$$0","require$$1","getOwnPropertySymbols","hasOwnProperty","propIsEnumerable","toObject","val","shouldUseNative","test1","test2","order2","test3","letter","objectAssign","from","to","symbols","ReactPropTypesSecret","ReactPropTypesSecret_1","has","printWarning","loggedTypeFailures","message","checkPropTypes","typeSpecs","values","location","componentName","getStack","typeSpecName","error","err","ex","stack","checkPropTypes_1","ReactIs","assign","require$$2","require$$3","require$$4","emptyFunctionThatReturnsNull","factoryWithTypeCheckers","isValidElement","throwOnDirectAccess","ITERATOR_SYMBOL","FAUX_ITERATOR_SYMBOL","getIteratorFn","maybeIterable","iteratorFn","ANONYMOUS","ReactPropTypes","createPrimitiveTypeChecker","createAnyTypeChecker","createArrayOfTypeChecker","createElementTypeChecker","createElementTypeTypeChecker","createInstanceTypeChecker","createNodeChecker","createObjectOfTypeChecker","createEnumTypeChecker","createUnionTypeChecker","createShapeTypeChecker","createStrictShapeTypeChecker","is","PropTypeError","createChainableTypeChecker","validate","manualPropTypeCallCache","manualPropTypeWarningCount","checkType","isRequired","propName","propFullName","secret","cacheKey","chainedCheckType","expectedType","propValue","propType","getPropType","preciseType","getPreciseType","typeChecker","expectedClass","expectedClassName","actualClassName","getClassName","expectedValues","valuesString","arrayOfTypeCheckers","checker","getPostfixForTypeWarning","expectedTypes","checkerResult","expectedTypesMessage","isNode","invalidValidatorError","shapeTypes","allKeys","iterator","step","entry","isSymbol","emptyFunction","emptyFunctionWithReset","factoryWithThrowingShims","shim","getShim","propTypesModule","isClassComponent","elementType","acceptingRef","safePropName","warningHint","elementAcceptingRef","PropTypes","elementAcceptingRef$1","specialProperty","exactProp","propTypes","unsupportedProps","prop","formatMuiErrorMessage","code","url","REACT_SERVER_CONTEXT_TYPE","REACT_OFFSCREEN_TYPE","enableScopeAPI","enableCacheElement","enableTransitionTracing","enableLegacyHidden","enableDebugTracing","REACT_MODULE_REFERENCE","SuspenseList","hasWarnedAboutDeprecatedIsConcurrentMode","isSuspenseList","fnNameMatchRegex","getFunctionName","fn","getFunctionComponentName","Component","fallback","getWrappedName","outerType","innerType","wrapperName","functionName","getDisplayName","HTMLElementType","refType","refType$1","capitalize","string","_formatMuiErrorMessage","createChainedFunction","funcs","acc","func","debounce","wait","timeout","debounced","later","deprecatedPropType","validator","reason","componentNameSafe","propFullNameSafe","isMuiElement","muiNames","_muiName","_element$type","ownerDocument","node","ownerWindow","requirePropFactory","componentNameInError","prevPropTypes","requiredProp","defaultTypeChecker","typeCheckerResult","setRef","useEnhancedEffect","useEnhancedEffect$1","globalId","useGlobalId","idOverride","defaultId","setDefaultId","maybeReactUseId","useId","reactId","unsupportedProp","useControlled","controlled","defaultProp","name","isControlled","valueState","setValue","defaultValue","setValueIfUncontrolled","newValue","useEventCallback","useForkRef","refs","instance","UNINITIALIZED","useLazyRef","init","initArg","EMPTY","useOnMount","Timeout","delay","useTimeout","hadKeyboardEvent","hadFocusVisibleRecently","hadFocusVisibleRecentlyTimeout","inputTypesWhitelist","focusTriggersKeyboardModality","tagName","handlePointerDown","handleVisibilityChange","prepare","doc","isFocusVisible","useIsFocusVisible","isFocusVisibleRef","handleBlurVisible","handleFocusVisible","resolveProps","defaultProps","defaultSlotProps","slotProps","slotPropName","composeClasses","slots","getUtilityClass","classes","slot","utilityClass","defaultGenerator","createClassNameGenerator","generate","generator","ClassNameGenerator","ClassNameGenerator$1","globalStateClasses","generateUtilityClass","globalStatePrefix","globalStateClass","generateUtilityClasses","result","clamp","min","max","_objectWithoutPropertiesLoose","excluded","sourceKeys","_excluded","sortBreakpointsValues","breakpointsAsArray","breakpoint1","breakpoint2","createBreakpoints","breakpoints","unit","other","sortedValues","up","down","between","start","end","endIndex","only","not","keyIndex","shape","shape$1","responsivePropType","responsivePropType$1","merge","defaultBreakpoints","handleBreakpoints","styleFromPropValue","theme","themeBreakpoints","breakpoint","mediaKey","cssKey","createEmptyBreakpointObject","breakpointsInput","_breakpointsInput$key","breakpointStyleKey","removeUnusedBreakpoints","breakpointKeys","breakpointOutput","getPath","path","checkVars","getStyleValue","themeMapping","transform","propValueFinal","userValue","cssProperty","themeKey","memoize","cache","arg","properties","directions","aliases","getCssProperties","property","marginKeys","paddingKeys","spacingKeys","createUnaryUnit","_getPath","themeSpacing","abs","createUnarySpacing","getValue","transformer","transformed","getStyleFromPropValue","cssProperties","resolveCssProperty","margin","padding","createSpacing","spacingInput","spacing","argsInput","argument","compose","styles","handlers","borderTransform","createBorderStyle","border","borderTop","borderRight","borderBottom","borderLeft","borderColor","borderTopColor","borderRightColor","borderBottomColor","borderLeftColor","outline","outlineColor","borderRadius","gap","columnGap","rowGap","gridColumn","gridRow","gridAutoFlow","gridAutoColumns","gridAutoRows","gridTemplateColumns","gridTemplateRows","gridTemplateAreas","gridArea","paletteTransform","color","bgcolor","backgroundColor","sizingTransform","maxWidth","_props$theme","_props$theme2","breakpointsValues","minWidth","height","maxHeight","minHeight","boxSizing","defaultSxConfig","defaultSxConfig$1","objectsHaveSameKeys","objects","union","callIfFn","maybeFn","unstable_createStyleFunctionSx","getThemeValue","config","styleFunctionSx","_theme$unstable_sxCon","sx","traverse","sxInput","sxObject","emptyBreakpoints","breakpointsKeys","css","styleKey","styleFunctionSx$1","applyStyles","createTheme","paletteInput","shapeInput","muiTheme","isObjectEmpty","useTheme","defaultTheme","contextTheme","ThemeContext","systemDefaultTheme","useThemeWithoutDefault","_excluded2","_excluded3","isEmpty","isStringTag","tag","shouldForwardProp","lowercaseFirstLetter","resolveTheme","themeId","defaultOverridesResolver","processStyleArg","callableStyle","_ref","ownerState","resolvedStylesArg","resolvedStyle","variants","isMatch","createStyled","input","rootShouldForwardProp","slotShouldForwardProp","systemSx","inputOptions","processStyles","componentSlot","inputSkipVariantsResolver","inputSkipSx","overridesResolver","skipVariantsResolver","skipSx","shouldForwardPropOption","defaultStyledResolver","styledEngineStyled","transformStyleArg","stylesArg","muiStyledResolver","styleArg","expressions","transformedStyleArg","expressionsWithDefaultTheme","styleOverrides","resolvedStyleOverrides","slotKey","slotStyle","_theme$components","themeVariants","numOfCustomFnsApplied","placeholders","displayName","getThemeProps","params","useThemeProps","clampWrapper","hexToRgb","re","colors","decomposeColor","marker","colorSpace","recomposeColor","hslToRgb","rgb","getLuminance","getContrastRatio","foreground","background","lumA","lumB","alpha","darken","coefficient","lighten","createMixins","mixins","common","common$1","grey","grey$1","purple","purple$1","red","red$1","orange","orange$1","blue","blue$1","lightBlue","lightBlue$1","green","green$1","light","dark","addLightOrDark","intent","shade","tonalOffset","tonalOffsetLight","tonalOffsetDark","getDefaultPrimary","mode","getDefaultSecondary","getDefaultError","getDefaultInfo","getDefaultSuccess","getDefaultWarning","createPalette","palette","contrastThreshold","success","warning","getContrastText","contrastText","contrast","augmentColor","mainShade","lightShade","darkShade","modes","round","caseAllCaps","defaultFontFamily","createTypography","typography","fontFamily","fontSize","fontWeightLight","fontWeightRegular","fontWeightMedium","fontWeightBold","htmlFontSize","allVariants","pxToRem2","coef","pxToRem","buildVariant","fontWeight","lineHeight","letterSpacing","casing","shadowKeyUmbraOpacity","shadowKeyPenumbraOpacity","shadowAmbientShadowOpacity","createShadow","px","shadows","shadows$1","easing","duration","formatMs","milliseconds","getAutoHeightDuration","constant","createTransitions","inputTransitions","mergedEasing","mergedDuration","durationOption","easingOption","isString","isNumber","animatedProp","zIndex","zIndex$1","mixinsInput","transitionsInput","typographyInput","systemTheme","systemCreateTheme","stateClasses","component","child","stateClass","defaultTheme$1","THEME_ID","systemUseThemeProps","styled","styled$1","getSvgIconUtilityClass","useUtilityClasses","SvgIconRoot","_theme$transitions","_theme$transitions$cr","_theme$transitions2","_theme$typography","_theme$typography$pxT","_theme$typography2","_theme$typography2$px","_theme$typography3","_theme$typography3$px","_palette$ownerState$c","_palette","_palette2","_palette3","SvgIcon","inProps","htmlColor","inheritViewBox","titleAccess","viewBox","hasSvgAsChild","more","_jsxs","_jsx","SvgIcon$1","createSvgIcon","unstable_ClassNameGenerator","exports","_utils","ArrowRight","default_1","_createSvgIcon","_jsxRuntime","isHostComponent","appendOwnerState","otherProps","defaultContextValue","ClassNameConfiguratorContext","useClassNamesOverride","disableDefaultClasses","extractEventHandlers","excludeKeys","resolveComponentProps","componentProps","slotState","omitEventHandlers","mergeSlotProps","parameters","getSlotProps","additionalProps","externalSlotProps","externalForwardedProps","joinedClasses","mergedStyle","eventHandlers","componentsPropsWithoutEventHandlers","otherPropsWithoutEventHandlers","internalSlotProps","useSlotProps","_parameters$additiona","skipResolvingSlotProps","rest","resolvedComponentsProps","mergedProps","internalRef","GLOBAL_CLASS_PREFIX","buildStateClass","buildSlotClass","getContainer","container","forwardedRef","disablePortal","mountNode","setMountNode","handleRef","newProps","ReactDOM","top","bottom","right","left","auto","basePlacements","clippingParents","viewport","popper","reference","variationPlacements","placement","placements","beforeRead","read","afterRead","beforeMain","main","afterMain","beforeWrite","write","afterWrite","modifierPhases","getNodeName","getWindow","OwnElement","isHTMLElement","isShadowRoot","attributes","effect","_ref2","initialStyles","styleProperties","attribute","applyStyles$1","getBasePlacement","getUAString","uaData","isLayoutViewport","getBoundingClientRect","includeScale","isFixedStrategy","clientRect","scaleX","scaleY","visualViewport","addVisualOffsets","getLayoutRect","contains","parent","rootNode","next","getComputedStyle","isTableElement","getDocumentElement","getParentNode","getTrueOffsetParent","getContainingBlock","isFirefox","isIE","elementCss","currentNode","getOffsetParent","window","offsetParent","getMainAxisFromPlacement","within","mathMax","mathMin","withinMaxClamp","getFreshSideObject","mergePaddingObject","paddingObject","expandToHashMap","hashMap","toPaddingObject","arrow","_state$modifiersData$","arrowElement","popperOffsets","basePlacement","axis","isVertical","len","arrowRect","minProp","maxProp","endDiff","startDiff","arrowOffsetParent","clientSize","centerToReference","center","offset","axisProp","_options$element","arrow$1","getVariation","unsetSides","roundOffsetsByDPR","win","dpr","mapToStyles","_Object$assign2","popperRect","variation","offsets","gpuAcceleration","adaptive","roundOffsets","isFixed","_offsets$x","_offsets$y","_ref3","hasX","hasY","sideX","sideY","heightProp","widthProp","offsetY","offsetX","commonStyles","_ref4","_Object$assign","computeStyles","_ref5","_options$gpuAccelerat","_options$adaptive","_options$roundOffsets","computeStyles$1","passive","_options$scroll","scroll","_options$resize","resize","scrollParents","scrollParent","eventListeners","hash","getOppositePlacement","matched","getOppositeVariationPlacement","getWindowScroll","scrollLeft","scrollTop","getWindowScrollBarX","getViewportRect","strategy","html","layoutViewport","getDocumentRect","_element$ownerDocumen","winScroll","body","isScrollParent","_getComputedStyle","overflow","overflowX","overflowY","getScrollParent","listScrollParents","list","isBody","updatedList","rectToClientRect","rect","getInnerBoundingClientRect","getClientRectFromMixedType","clippingParent","getClippingParents","canEscapeClipping","clipperElement","getClippingRect","boundary","rootBoundary","mainClippingParents","firstClippingParent","clippingRect","accRect","computeOffsets","commonX","commonY","mainAxis","detectOverflow","_options","_options$placement","_options$strategy","_options$boundary","_options$rootBoundary","_options$elementConte","elementContext","_options$altBoundary","altBoundary","_options$padding","altContext","clippingClientRect","referenceClientRect","popperClientRect","elementClientRect","overflowOffsets","offsetData","multiply","computeAutoPlacement","flipVariations","_options$allowedAutoP","allowedAutoPlacements","allPlacements","allowedPlacements","overflows","getExpandedFallbackPlacements","oppositePlacement","flip","_options$mainAxis","checkMainAxis","_options$altAxis","checkAltAxis","specifiedFallbackPlacements","_options$flipVariatio","preferredPlacement","isBasePlacement","fallbackPlacements","referenceRect","checksMap","makeFallbackChecks","firstFittingPlacement","_basePlacement","isStartVariation","mainVariationSide","altVariationSide","checks","check","numberOfChecks","_loop","_i","fittingPlacement","_ret","flip$1","getSideOffsets","preventedOffsets","isAnySideFullyClipped","hide","referenceOverflow","popperAltOverflow","referenceClippingOffsets","popperEscapeOffsets","isReferenceHidden","hasPopperEscaped","hide$1","distanceAndSkiddingToXY","rects","invertDistance","skidding","distance","_options$offset","_data$state$placement","offset$1","popperOffsets$1","getAltAxis","preventOverflow","_options$tether","tether","_options$tetherOffset","tetherOffset","altAxis","tetherOffsetValue","normalizedTetherOffsetValue","offsetModifierState","_offsetModifierState$","mainSide","altSide","additive","minLen","maxLen","arrowPaddingObject","arrowPaddingMin","arrowPaddingMax","arrowLen","minOffset","maxOffset","clientOffset","offsetModifierValue","tetherMin","tetherMax","preventedOffset","_offsetModifierState$2","_mainSide","_altSide","_offset","_len","_min","_max","isOriginSide","_offsetModifierValue","_tetherMin","_tetherMax","_preventedOffset","preventOverflow$1","getHTMLElementScroll","getNodeScroll","isElementScaled","getCompositeRect","elementOrVirtualElement","isOffsetParentAnElement","offsetParentIsScaled","documentElement","order","modifiers","map","visited","modifier","sort","requires","dep","depModifier","orderModifiers","orderedModifiers","phase","pending","resolve","mergeByName","merged","current","existing","DEFAULT_OPTIONS","areValidElements","_key","popperGenerator","generatorOptions","_generatorOptions","_generatorOptions$def","defaultModifiers","_generatorOptions$def2","defaultOptions","effectCleanupFns","isDestroyed","setOptionsAction","cleanupModifierEffects","runModifierEffects","_state$elements","_state$orderedModifie","_state$orderedModifie2","_ref$options","cleanupFn","noopFn","createPopper","COMPONENT_NAME","getPopperUtilityClass","flipPlacement","resolveAnchorEl","anchorEl","isVirtualElement","defaultPopperOptions","PopperTooltip","_slots$root","initialPlacement","popperOptions","popperRefProp","TransitionProps","tooltipRef","ownRef","popperRef","handlePopperRef","handlePopperRefRef","rtlPlacement","setPlacement","resolvedAnchorElement","setResolvedAnchorElement","handlePopperUpdate","box","popperModifiers","childProps","Root","rootProps","Popper","containerProp","keepMounted","transition","exited","setExited","handleEnter","handleExited","resolvedAnchorEl","display","transitionProps","useThemeSystem","_setPrototypeOf","_inheritsLoose","subClass","superClass","setPrototypeOf","timeoutsShape","TransitionGroupContext","forceReflow","UNMOUNTED","EXITED","ENTERING","ENTERED","EXITING","Transition","_React$Component","_this","parentGroup","appear","initialStatus","prevState","nextIn","_proto","prevProps","nextStatus","exit","enter","mounting","_this2","appearing","maybeNode","maybeAppearing","timeouts","enterTimeout","_this3","nextState","callback","_this4","active","handler","doesNotHaveTimeoutOrListener","maybeNextCallback","_this$props","pt","noop","Transition$1","reflow","getTransitionProps","_style$transitionDura","_style$transitionTimi","getScale","isWebKit154","Grow","addEndListener","inProp","onEnter","onEntered","onEntering","onExit","onExited","onExiting","TransitionComponent","timer","autoTimeout","nodeRef","normalizedTransitionCallback","maybeIsAppearing","handleEntering","isAppearing","transitionDuration","transitionTimingFunction","handleEntered","handleExiting","handleExit","Grow$1","PopperRoot","BasePopper","components","componentsProps","RootComponent","Popper$1","getTooltipUtilityClass","tooltipClasses","tooltipClasses$1","disableInteractive","touch","TooltipPopper","TooltipTooltip","TooltipArrow","hystersisOpen","hystersisTimer","cursorPosition","composeEventHandler","eventHandler","_slots$popper","_slots$transition","_slots$tooltip","_slots$arrow","_slotProps$popper","_ref6","_slotProps$popper2","_slotProps$transition","_slotProps$tooltip","_ref7","_slotProps$tooltip2","_slotProps$arrow","_ref8","_slotProps$arrow2","childrenProp","describeChild","disableFocusListener","disableHoverListener","disableInteractiveProp","disableTouchListener","enterDelay","enterNextDelay","enterTouchDelay","followCursor","idProp","leaveDelay","leaveTouchDelay","onClose","onOpen","PopperComponentProp","PopperProps","title","TransitionComponentProp","isRtl","childNode","setChildNode","arrowRef","setArrowRef","ignoreNonTouchEvents","closeTimer","enterTimer","leaveTimer","touchTimer","setOpenState","prevUserSelect","stopTouchInteraction","handleOpen","handleClose","handleLeave","focusVisibleRef","setChildIsFocusVisible","handleBlur","handleFocus","detectTouchStart","childrenProps","handleMouseOver","handleMouseLeave","handleTouchStart","handleTouchEnd","nativeEvent","handleMouseMove","nameOrDescProps","titleIsString","interactiveWrapperListeners","_PopperProps$popperOp","tooltipModifiers","PopperComponent","TooltipComponent","ArrowComponent","popperProps","tooltipProps","tooltipArrowProps","TransitionPropsInner","Tooltip$1","getIcon","icon","menuLabel","leading","MuiListItemIcon","MenuItem","allowForLeadingIcons","iconPathBefore","iconPathAfter","hasAutoFocus","isDense","isSubMenuParent","hasDisabledGutters","hasDivider","focusVisibleClassName","menuItem","MuiMenuItem","MuiListItemText","getAllGroups","menuDefinition","SubMenu","setAnchorEl","parentMenuItem","parentItemProps","handleParentMenuItemClick","renderSubMenuItems","includedGroups","group","GroupedMenuItemList","Menu","getOrderedGroupItems","groupId","allItems","menuProps","commandHandler","groupsToInclude","sortedGroups","itemArray","allowSpaceForLeadingIcons","createMenuItemProps","isLastItemInGroup","divKey","itemInfo","menuItemProps","TopLevelMenu","columnId","MenuColumn","metadata","Grid","List","GridMenu","multiColumnMenu","sortedColumns","columnNumbers","columnName","col","getUsePromiseOptionsDefaults","usePromise","promiseFactoryCallback","defaultValueRef","optionsDefaultedRef","setIsLoading","promiseIsCurrent","MenuIcon","HamburgerMenuButton","menuProvider","normalMenu","fullMenu","containerRef","ariaLabelPrefix","isMenuOpen","setMenuOpen","showFullMenu","setShowFullMenu","handleMenuItemClick","handleMenuButtonClick","prevIsOpen","isOpening","menuCommandHandler","command","setOffset","normalMenuData","fullMenuData","menu","IconButton","Drawer","isTooltipSuppressed","adjustMarginToAlignToEdge","MuiIconButton","Spinner","LoaderCircle","TextField","hasError","helperText","onFocus","onBlur","ShadLabel","Toolbar","AppBar","MuiToolbar","alertVariants","Alert","AlertTitle","AlertDescription","Card","CardHeader","CardTitle","CardDescription","CardContent","CardFooter","Sonner","Toaster","Slider","SliderPrimitive","Switch","SwitchPrimitives","Tabs","TabsList","TabsTrigger","TabsContent","InstallButton","isInstalling","handleClick","buttonText","Download","EnableButton","isEnabling","DisableButton","isDisabling","UpdateButton","isUpdating","MarkdownRenderer","markdown","anchorTarget","Markdown","FilterButton","Filter","DropdownMenuItemType","DropdownMenuItemType2","FilterDropdown","groups","NoExtensionsFound","MoreInfo","category","downloads","languages","moreInfoUrl","numberFormatted","NumberFormat","handleScrollToBottom","User","locale","LucideLink","CircleHelp","VersionHistory","versionHistory","showAllVersions","setShowAllVersions","currentDate","formatTimeString","dateString","date","dateDiff","yearDiff","monthDiff","dayDiff","timeString","sortedEntries","Footer","publisherDisplayName","fileSize","locales","formattedFileSize","formatBytes","languageNames","codes","displayNames","useEvent","unsubscriber","noopUnsubscriber","useEventAsync","unsubscribe","unsub"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAGA,MAAMA,KAAgBC,GAAoB,EAAE,QAAQ,MAAO,CAAA;AAyDpD,SAASC,KAAMC,GAAsB;AACnC,SAAAH,GAAcI,GAAKD,CAAM,CAAC;AACnC;ACzDO,MAAME,KAAQC,EAAM;AAAA,EACzB,CAAC,EAAE,WAAAC,GAAW,MAAAC,GAAM,GAAGC,EAAA,GAASC,MAE5B,gBAAAC;AAAA,IAAC;AAAA,IAAA;AAAA,MACC,MAAAH;AAAA,MACA,WAAWN;AAAA,QACT;AAAA,QACAK;AAAA,MACF;AAAA,MACA,KAAAG;AAAA,MAEC,GAAGD;AAAA,IAAA;AAAA,EAAA;AAIZ;AACAJ,GAAM,cAAc;ACNpB,MAAMO,KAAmBC;AAAA,EACvB,CACE,EAAE,cAAAC,GAAc,eAAAC,GAAe,eAAAC,GAAe,cAAAC,GAAc,GAAGR,EAAM,GACrEC,MAGE,gBAAAQ,EAAC,OAAI,EAAA,WAAU,eACb,UAAA;AAAA,IAAA,gBAAAP;AAAA,MAACQ;AAAAA,MAAA;AAAA,QACE,GAAGV;AAAA,QACJ,MAAK;AAAA,QACL,WAAU;AAAA,QACV,UAAU,CAACW,MAAUN,EAAaM,EAAM,OAAO,KAAK;AAAA,QACpD,WAAW,CAACC,MAAM;AACZ,UAAAA,EAAE,QAAQ,WACCJ,KAEfF,EAAcM,CAAC;AAAA,QACjB;AAAA,QACA,SAASL;AAAA,QACT,KAAAN;AAAA,MAAA;AAAA,IACF;AAAA,IACA,gBAAAC;AAAA,MAACW;AAAA,MAAA;AAAA,QACC,W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;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","x_google_ignoreList":[3,43,44,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,83,84,85,86,87,88,89,90,91,92,93,94,95,96,97,98,99,100,101,102,103,104,105,106,107,108,109,110,111,112,113,114,115,116,117,118,119,120,121,122,123,124,125,126,127,128,129,130,131,132,133,134,135,136,137,138,139,140,141,142,143,144,145,146,147,148,149,150,151,152,153,154,155,156,157,158,159,160,161,162,163,164,165,166,167,168,169,170,171,172,173,174,175,176,177,178,179,180,181,182,183,184,185,186,187,188,189,190,191,192,193,194,195,196,197,198,199,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,226]} \ No newline at end of file diff --git a/lib/platform-bible-react/src/components/basics/combo-box.component.tsx b/lib/platform-bible-react/src/components/basics/combo-box.component.tsx index 47e4cb7366..75078a2096 100644 --- a/lib/platform-bible-react/src/components/basics/combo-box.component.tsx +++ b/lib/platform-bible-react/src/components/basics/combo-box.component.tsx @@ -21,6 +21,8 @@ export type ComboBoxProps = { /** Text label title for combobox */ /** List of available options for the dropdown menu */ options?: readonly T[]; + /** @deprecated 3 December 2024. Renamed to {@link buttonClassName} */ + className?: string; /** Additional css classes to help with unique styling of the combo box button */ buttonClassName?: string; /** Additional css classes to help with unique styling of the combo box popover */ diff --git a/lib/platform-bible-react/src/components/hooks/use-mobile.tsx b/lib/platform-bible-react/src/components/hooks/use-mobile.tsx deleted file mode 100644 index 972c7d6d27..0000000000 --- a/lib/platform-bible-react/src/components/hooks/use-mobile.tsx +++ /dev/null @@ -1,19 +0,0 @@ -import React from 'react'; - -const MOBILE_BREAKPOINT = 768; - -export default function useIsMobile() { - const [isMobile, setIsMobile] = React.useState(undefined); - - React.useEffect(() => { - const mql = window.matchMedia(`(max-width: ${MOBILE_BREAKPOINT - 1}px)`); - const onChange = () => { - setIsMobile(window.innerWidth < MOBILE_BREAKPOINT); - }; - mql.addEventListener('change', onChange); - setIsMobile(window.innerWidth < MOBILE_BREAKPOINT); - return () => mql.removeEventListener('change', onChange); - }, []); - - return !!isMobile; -} diff --git a/lib/platform-bible-react/src/components/shadcn-ui/sheet.tsx b/lib/platform-bible-react/src/components/shadcn-ui/sheet.tsx deleted file mode 100644 index 5b2d96a454..0000000000 --- a/lib/platform-bible-react/src/components/shadcn-ui/sheet.tsx +++ /dev/null @@ -1,131 +0,0 @@ -'use client'; - -import * as React from 'react'; -import * as SheetPrimitive from '@radix-ui/react-dialog'; -import { cva, type VariantProps } from 'class-variance-authority'; -import { X } from 'lucide-react'; - -import { cn } from '@/utils/shadcn-ui.util'; - -const Sheet = SheetPrimitive.Root; - -const SheetTrigger = SheetPrimitive.Trigger; - -const SheetClose = SheetPrimitive.Close; - -const SheetPortal = SheetPrimitive.Portal; - -const SheetOverlay = React.forwardRef< - React.ElementRef, - React.ComponentPropsWithoutRef ->(({ className, ...props }, ref) => ( - -)); -SheetOverlay.displayName = SheetPrimitive.Overlay.displayName; - -const sheetVariants = cva( - 'pr-twp tw-fixed tw-z-50 tw-gap-4 tw-bg-background tw-p-6 tw-shadow-lg tw-transition tw-ease-in-out data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-duration-300 data-[state=open]:tw-duration-500', - { - variants: { - side: { - top: 'tw-inset-x-0 tw-top-0 tw-border-b data-[state=closed]:tw-slide-out-to-top data-[state=open]:tw-slide-in-from-top', - bottom: - 'tw-inset-x-0 tw-bottom-0 tw-border-t data-[state=closed]:tw-slide-out-to-bottom data-[state=open]:tw-slide-in-from-bottom', - left: 'tw-inset-y-0 tw-left-0 tw-h-full tw-w-3/4 tw-border-r data-[state=closed]:tw-slide-out-to-left data-[state=open]:tw-slide-in-from-left sm:tw-max-w-sm', - right: - 'tw-inset-y-0 tw-right-0 tw-h-full tw-w-3/4 tw- tw-border-l data-[state=closed]:tw-slide-out-to-right data-[state=open]:tw-slide-in-from-right sm:tw-max-w-sm', - }, - }, - defaultVariants: { - side: 'right', - }, - }, -); - -interface SheetContentProps - extends React.ComponentPropsWithoutRef, - VariantProps {} - -const SheetContent = React.forwardRef< - React.ElementRef, - SheetContentProps ->(({ side = 'right', className, children, ...props }, ref) => ( - - - - {children} - - - Close - - - -)); -SheetContent.displayName = SheetPrimitive.Content.displayName; - -function SheetHeader({ className, ...props }: React.HTMLAttributes) { - return ( -
    - ); -} -SheetHeader.displayName = 'SheetHeader'; - -function SheetFooter({ className, ...props }: React.HTMLAttributes) { - return ( -
    - ); -} -SheetFooter.displayName = 'SheetFooter'; - -const SheetTitle = React.forwardRef< - React.ElementRef, - React.ComponentPropsWithoutRef ->(({ className, ...props }, ref) => ( - -)); -SheetTitle.displayName = SheetPrimitive.Title.displayName; - -const SheetDescription = React.forwardRef< - React.ElementRef, - React.ComponentPropsWithoutRef ->(({ className, ...props }, ref) => ( - -)); -SheetDescription.displayName = SheetPrimitive.Description.displayName; - -export { - Sheet, - SheetPortal, - SheetOverlay, - SheetTrigger, - SheetClose, - SheetContent, - SheetHeader, - SheetFooter, - SheetTitle, - SheetDescription, -}; diff --git a/lib/platform-bible-react/src/components/shadcn-ui/sidebar.tsx b/lib/platform-bible-react/src/components/shadcn-ui/sidebar.tsx index 4afc8f245d..4a4a4a1a9a 100644 --- a/lib/platform-bible-react/src/components/shadcn-ui/sidebar.tsx +++ b/lib/platform-bible-react/src/components/shadcn-ui/sidebar.tsx @@ -6,7 +6,6 @@ import { PanelLeft } from 'lucide-react'; import { Button } from '@/components/shadcn-ui/button'; import { Input } from '@/components/shadcn-ui/input'; import { Separator } from '@/components/shadcn-ui/separator'; -import { Sheet, SheetContent } from '@/components/shadcn-ui/sheet'; import { Skeleton } from '@/components/shadcn-ui/skeleton'; import { Tooltip, @@ -14,13 +13,14 @@ import { TooltipProvider, TooltipTrigger, } from '@/components/shadcn-ui/tooltip'; -import useIsMobile from '@/components/hooks/use-mobile'; import { cn } from '@/utils/shadcn-ui.util'; -const SIDEBAR_COOKIE_NAME = 'sidebar:state'; -const SIDEBAR_COOKIE_MAX_AGE = 60 * 60 * 24 * 7; +/** + * Changes from the original code from Shadcn- Removed uses of useIsMobile, Sheet, and SheetContent. + * Also removed the parts setting COOKIES. + */ + const SIDEBAR_WIDTH = '16rem'; -const SIDEBAR_WIDTH_MOBILE = '18rem'; const SIDEBAR_WIDTH_ICON = '3rem'; const SIDEBAR_KEYBOARD_SHORTCUT = 'b'; @@ -28,9 +28,6 @@ type SidebarContextProps = { state: 'expanded' | 'collapsed'; open: boolean; setOpen: (open: boolean) => void; - openMobile: boolean; - setOpenMobile: (open: boolean) => void; - isMobile: boolean; toggleSidebar: () => void; }; @@ -65,9 +62,6 @@ const SidebarProvider = React.forwardRef< }, ref, ) => { - const isMobile = useIsMobile(); - const [openMobile, setOpenMobile] = React.useState(false); - // This is the internal state of the sidebar. // We use openProp and setOpenProp for control from outside the component. const [_open, _setOpen] = React.useState(defaultOpen); @@ -80,17 +74,14 @@ const SidebarProvider = React.forwardRef< } else { _setOpen(openState); } - - // This sets the cookie to keep the sidebar state. - document.cookie = `${SIDEBAR_COOKIE_NAME}=${openState}; path=/; max-age=${SIDEBAR_COOKIE_MAX_AGE}`; }, [setOpenProp, isOpen], ); // Helper to toggle the sidebar. const toggleSidebar = React.useCallback(() => { - return isMobile ? setOpenMobile((open) => !open) : setOpen((open) => !open); - }, [isMobile, setOpen, setOpenMobile]); + return setOpen((open) => !open); + }, [setOpen]); // Adds a keyboard shortcut to toggle the sidebar. React.useEffect(() => { @@ -114,12 +105,9 @@ const SidebarProvider = React.forwardRef< state, open: isOpen, setOpen, - isMobile, - openMobile, - setOpenMobile, toggleSidebar, }), - [state, isOpen, setOpen, isMobile, openMobile, setOpenMobile, toggleSidebar], + [state, isOpen, setOpen, toggleSidebar], ); return ( @@ -170,7 +158,7 @@ const Sidebar = React.forwardRef< }, ref, ) => { - const { isMobile, state, openMobile, setOpenMobile } = useSidebar(); + const { state } = useSidebar(); if (collapsible === 'none') { return ( @@ -187,27 +175,6 @@ const Sidebar = React.forwardRef< ); } - if (isMobile) { - return ( - - -
    {children}
    -
    -
    - ); - } - return (
    { const Comp = asChild ? Slot : 'button'; - const { isMobile, state } = useSidebar(); + const { state } = useSidebar(); const button = ( {button} -
    \n );\n}\n\nexport default ChapterSelect;\n","import { DropdownMenuLabel as ShadDropdownMenuLabel } from '@/components/shadcn-ui/dropdown-menu';\nimport { Bookmark, Clock, ArrowDownWideNarrow } from 'lucide-react';\n\nexport type GoToMenuItemProps = {\n handleSort: () => void;\n handleLocationHistory: () => void;\n handleBookmarks: () => void;\n};\n\nfunction GoToMenuItem({ handleSort, handleLocationHistory, handleBookmarks }: GoToMenuItemProps) {\n return (\n \n

    Go To

    \n
    \n \n \n \n
    \n
    \n );\n}\n\nexport default GoToMenuItem;\n","import BookChapterInput from '@/components/advanced/book-chapter-control/book-chapter-input.component';\nimport BookMenuItem, {\n BookType,\n} from '@/components/advanced/book-chapter-control/book-menu-item.component';\nimport ChapterSelect from '@/components/advanced/book-chapter-control/chapter-select.component';\nimport GoToMenuItem from '@/components/advanced/book-chapter-control/go-to-menu-item.component';\nimport {\n DropdownMenu as ShadDropdownMenu,\n DropdownMenuContent as ShadDropdownMenuContent,\n DropdownMenuLabel as ShadDropdownMenuLabel,\n DropdownMenuSeparator as ShadDropdownMenuSeparator,\n DropdownMenuTrigger as ShadDropdownMenuTrigger,\n} from '@/components/shadcn-ui/dropdown-menu';\nimport { Canon } from '@sillsdev/scripture';\nimport { ScriptureReference, getChaptersForBook } from 'platform-bible-utils';\nimport {\n KeyboardEvent as ReactKeyboardEvent,\n useCallback,\n useEffect,\n useLayoutEffect,\n useRef,\n useState,\n} from 'react';\n\ntype BookTypeLabels = {\n [bookType in BookType]: string;\n};\ntype BookChapterControlProps = {\n scrRef: ScriptureReference;\n handleSubmit: (scrRef: ScriptureReference) => void;\n};\n\nconst ALL_BOOK_IDS = Canon.allBookIds;\nconst BOOK_TYPE_LABELS: BookTypeLabels = {\n OT: 'Old Testament',\n NT: 'New Testament',\n DC: 'Deuterocanon',\n};\nconst BOOK_TYPE_ARRAY: BookType[] = ['OT', 'NT', 'DC'];\n// This is the height of three menu items to offset scrolling to the selected menu item\n// If you use menuItemRef.clientHeight- includes height of chapter div which is too big\nconst SCROLL_OFFSET = 32 + 32 + 32;\nconst SEARCH_QUERY_FORMATS = [\n /^(\\w+)$/i, // Matches a single word (book name or id)\n /^(\\w+)(?:\\s(\\d+))$/i, // Matches a word followed by a chapter number\n /^(\\w+)(?:\\s(\\d+):(\\d+))$/i, // Matches a word followed by a chapter and verse number\n];\nconst fetchGroupedBooks = (bookType: BookType) => {\n const groupedBooks = {\n OT: ALL_BOOK_IDS.filter((bookId) => Canon.isBookOT(bookId)),\n NT: ALL_BOOK_IDS.filter((bookId) => Canon.isBookNT(bookId)),\n DC: ALL_BOOK_IDS.filter((bookId) => Canon.isBookDC(bookId)),\n };\n return groupedBooks[bookType];\n};\nconst fetchEndChapter = (bookId: string) => {\n // getChaptersForBook returns -1 if not found in scrBookData\n // scrBookData only includes OT and NT, so all DC will return -1\n return getChaptersForBook(Canon.bookIdToNumber(bookId));\n};\n\n/**\n * Gets all of the English names from book ids\n *\n * @returns String[]\n */\nfunction getAllEnglishNames(): string[] {\n const allEnglishNames = ALL_BOOK_IDS.map((bookId) => {\n return Canon.bookIdToEnglishName(bookId);\n });\n return allEnglishNames;\n}\n\n/**\n * Determines if bookName is in allEnglishNames\n *\n * @param bookName Book English name\n * @returns True if bookName is included, false otherwise\n */\nfunction isValidBookEnglishName(bookName: string): boolean {\n return getAllEnglishNames().includes(bookName);\n}\n\n/**\n * Gets a bookId from given English name\n *\n * @param bookName Book English name\n * @returns BookId of provided bookName, undefined otherwise\n */\nfunction getBookIdFromEnglishName(bookName: string): string | undefined {\n // Convert bookName to lowercase and then capitalize the first letter\n const formattedBookName = bookName.toLowerCase().replace(/^\\w/, (c) => c.toUpperCase());\n\n if (isValidBookEnglishName(formattedBookName)) {\n const matchingBookId = ALL_BOOK_IDS.find((bookId) => {\n return Canon.bookIdToEnglishName(bookId) === formattedBookName;\n });\n return matchingBookId;\n }\n\n return undefined;\n}\n\nfunction BookChapterControl({ scrRef, handleSubmit }: BookChapterControlProps) {\n const [searchQuery, setSearchQuery] = useState('');\n const [selectedBookId, setSelectedBookId] = useState(\n Canon.bookNumberToId(scrRef.bookNum),\n );\n const [highlightedChapter, setHighlightedChapter] = useState(scrRef.chapterNum ?? 0);\n const [highlightedBookId, setHighlightedBookId] = useState(\n Canon.bookNumberToId(scrRef.bookNum),\n );\n const [isContentOpen, setIsContentOpen] = useState(false);\n const [isContentOpenDelayed, setIsContentOpenDelayed] = useState(isContentOpen);\n\n // This ref will always be defined\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const inputRef = useRef(undefined!);\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const contentRef = useRef(undefined!);\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const menuItemRef = useRef(undefined!);\n\n const fetchFilteredBooks = useCallback(\n (bookType: BookType) => {\n return fetchGroupedBooks(bookType).filter((bookId: string) => {\n const englishNameLowerCase = Canon.bookIdToEnglishName(bookId).toLowerCase();\n const normalizedQuery = searchQuery.replace(/[^a-zA-Z]/g, '').toLowerCase();\n return (\n englishNameLowerCase.includes(normalizedQuery) || // Match book name\n bookId.toLowerCase().includes(normalizedQuery) // Match book ID\n );\n });\n },\n [searchQuery],\n );\n\n const handleSearchInput = (searchString: string) => {\n setSearchQuery(searchString);\n };\n\n /**\n * Whether to prevent radix's logic from closing the dropdown. This is important because radix\n * tries to close the dropdown when the input first focuses, and we don't want it to do that. But\n * we don't want to prevent the dropdown from closing when we click away from the input, so we\n * don't want to just keep it open if the input is focused\n */\n const shouldPreventAutoClosing = useRef(false);\n\n const controlMenuState = useCallback((open: boolean) => {\n if (shouldPreventAutoClosing.current) {\n shouldPreventAutoClosing.current = false;\n return;\n }\n setIsContentOpen(open);\n }, []);\n\n const updateReference = useCallback(\n (bookId: string, shouldClose: boolean, chapter?: number, verse?: number) => {\n setHighlightedChapter(\n Canon.bookNumberToId(scrRef.bookNum) !== bookId ? 1 : scrRef.chapterNum,\n );\n\n if (shouldClose || fetchEndChapter(bookId) === -1) {\n handleSubmit({\n bookNum: Canon.bookIdToNumber(bookId),\n chapterNum: chapter || 1,\n verseNum: verse || 1,\n });\n\n setIsContentOpen(false);\n setSearchQuery('');\n return;\n }\n\n setSelectedBookId(selectedBookId !== bookId ? bookId : '');\n setIsContentOpen(!shouldClose);\n },\n [handleSubmit, scrRef.bookNum, scrRef.chapterNum, selectedBookId],\n );\n\n const handleSelectChapter = (chapterNumber: number) => {\n if (chapterNumber <= 0 || chapterNumber > fetchEndChapter(selectedBookId)) {\n return;\n }\n updateReference(selectedBookId, true, chapterNumber);\n };\n\n const handleInputSubmit = useCallback(() => {\n SEARCH_QUERY_FORMATS.forEach((format) => {\n const matches = searchQuery.match(format);\n if (matches) {\n // Book should be a bookId or an english name\n const [book, chapter = undefined, verse = undefined] = matches.slice(1);\n const englishName = getBookIdFromEnglishName(book);\n\n if (Canon.isBookIdValid(book) || englishName) {\n updateReference(\n englishName ?? book,\n true,\n chapter ? parseInt(chapter, 10) : 1,\n verse ? parseInt(verse, 10) : 1,\n );\n }\n }\n });\n }, [updateReference, searchQuery]);\n\n const handleKeyDownInput = useCallback(\n (event: ReactKeyboardEvent) => {\n if (!isContentOpen) {\n setIsContentOpen(true);\n } else if (event.key === 'ArrowDown' || event.key === 'ArrowUp') {\n if (\n typeof menuItemRef !== 'undefined' &&\n // Ref uses null\n // eslint-disable-next-line no-null/no-null\n menuItemRef.current !== null\n ) {\n menuItemRef.current.focus();\n } else if (\n typeof contentRef !== 'undefined' &&\n // Ref uses null\n // eslint-disable-next-line no-null/no-null\n contentRef.current !== null\n ) {\n contentRef.current.focus();\n }\n event.preventDefault();\n }\n },\n [isContentOpen],\n );\n\n const handleKeyDownContent = (event: ReactKeyboardEvent) => {\n // When the dropdown menu has focus, key strokes should give focus to the input component,\n // unless they're navigation keys (arrows and enter)\n const { key } = event;\n if (\n key === 'ArrowRight' ||\n key === 'ArrowLeft' ||\n key === 'ArrowDown' ||\n key === 'ArrowUp' ||\n key === 'Enter'\n ) {\n return;\n }\n\n inputRef.current.dispatchEvent(new KeyboardEvent('keydown', { key }));\n inputRef.current.focus();\n };\n\n const handleKeyDownMenuItem = (event: ReactKeyboardEvent) => {\n const { key } = event;\n if (highlightedBookId === selectedBookId) {\n if (key === 'Enter') {\n event.preventDefault();\n updateReference(selectedBookId, true, highlightedChapter);\n return;\n }\n\n let chapterOffSet = 0;\n if (key === 'ArrowRight') {\n if (highlightedChapter < fetchEndChapter(highlightedBookId)) {\n chapterOffSet = 1;\n } else {\n event.preventDefault();\n return;\n }\n } else if (key === 'ArrowLeft') {\n if (highlightedChapter > 1) {\n chapterOffSet = -1;\n } else {\n event.preventDefault();\n return;\n }\n } else if (key === 'ArrowDown') {\n chapterOffSet = 6;\n } else if (key === 'ArrowUp') {\n chapterOffSet = -6;\n }\n if (\n highlightedChapter + chapterOffSet <= 0 ||\n highlightedChapter + chapterOffSet > fetchEndChapter(highlightedBookId)\n ) {\n setHighlightedChapter(0);\n } else if (chapterOffSet !== 0) {\n setHighlightedChapter(highlightedChapter + chapterOffSet);\n event.preventDefault();\n }\n }\n };\n\n useEffect(() => {\n if (selectedBookId === highlightedBookId) {\n if (selectedBookId === Canon.bookNumberToId(scrRef.bookNum)) {\n setHighlightedChapter(scrRef.chapterNum);\n } else {\n setHighlightedChapter(1);\n }\n } else {\n setHighlightedChapter(0);\n }\n }, [highlightedBookId, scrRef.bookNum, scrRef.chapterNum, selectedBookId]);\n\n // The purpose of these useLayoutEffects and timeout is to delay the scroll just\n // enough so that the refs are defined and available when they are used after the timeout\n useLayoutEffect(() => {\n setIsContentOpenDelayed(isContentOpen);\n }, [isContentOpen]);\n\n useLayoutEffect(() => {\n const scrollTimeout = setTimeout(() => {\n if (isContentOpenDelayed && contentRef.current && menuItemRef.current) {\n const menuItemOffsetTop = menuItemRef.current.offsetTop;\n const scrollPosition = menuItemOffsetTop - SCROLL_OFFSET;\n contentRef.current.scrollTo({ top: scrollPosition, behavior: 'instant' });\n }\n }, 10);\n return () => {\n clearTimeout(scrollTimeout);\n };\n }, [isContentOpenDelayed]);\n\n return (\n
    \n \n \n {\n setSelectedBookId(Canon.bookNumberToId(scrRef.bookNum));\n setHighlightedBookId(Canon.bookNumberToId(scrRef.bookNum));\n setHighlightedChapter(scrRef.chapterNum > 0 ? scrRef.chapterNum : 0);\n setIsContentOpen(true);\n inputRef.current.focus();\n }}\n onFocus={() => {\n // Radix thinks we want to close because the input is being focused. Prevent that\n shouldPreventAutoClosing.current = true;\n }}\n handleSubmit={handleInputSubmit}\n placeholder={`${Canon.bookNumberToEnglishName(scrRef.bookNum)} ${scrRef.chapterNum}:${scrRef.verseNum}`}\n />\n \n \n console.log('sorting')}\n handleLocationHistory={() => console.log('location history')}\n handleBookmarks={() => console.log('bookmarks')}\n />\n {BOOK_TYPE_ARRAY.map(\n (bookType, bookTypeIndex) =>\n fetchFilteredBooks(bookType).length > 0 && (\n
    \n \n {BOOK_TYPE_LABELS[bookType]}\n \n\n {fetchFilteredBooks(bookType).map((bookId) => (\n
    \n updateReference(bookId, false)}\n isSelected={selectedBookId === bookId}\n handleHighlightBook={() => setHighlightedBookId(bookId)}\n handleKeyDown={handleKeyDownMenuItem}\n bookType={bookType}\n ref={(element: HTMLDivElement) => {\n if (selectedBookId === bookId) menuItemRef.current = element;\n }}\n >\n {\n setHighlightedChapter(chapterNumber);\n }}\n />\n \n
    \n ))}\n {BOOK_TYPE_ARRAY.length - 1 !== bookTypeIndex ? (\n \n ) : undefined}\n
    \n ),\n )}\n \n
    \n
    \n );\n}\n\nexport default BookChapterControl;\n","import React from 'react';\nimport { Slot } from '@radix-ui/react-slot';\nimport { cva, type VariantProps } from 'class-variance-authority';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport const buttonVariants = cva(\n 'pr-twp tw-inline-flex tw-items-center tw-justify-center tw-whitespace-nowrap tw-rounded-md tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-colors focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50',\n {\n variants: {\n variant: {\n default: 'tw-bg-primary tw-text-primary-foreground hover:tw-bg-primary/90',\n destructive: 'tw-bg-destructive tw-text-destructive-foreground hover:tw-bg-destructive/90',\n outline:\n 'tw-border tw-border-input tw-bg-background hover:tw-bg-accent hover:tw-text-accent-foreground',\n secondary: 'tw-bg-secondary tw-text-secondary-foreground hover:tw-bg-secondary/80',\n ghost: 'hover:tw-bg-accent hover:tw-text-accent-foreground',\n link: 'tw-text-primary tw-underline-offset-4 hover:tw-underline',\n },\n size: {\n default: 'tw-h-10 tw-px-4 tw-py-2',\n sm: 'tw-h-9 tw-rounded-md tw-px-3',\n lg: 'tw-h-11 tw-rounded-md tw-px-8',\n icon: 'tw-h-10 tw-w-10',\n },\n },\n defaultVariants: {\n variant: 'default',\n size: 'default',\n },\n },\n);\n\nexport interface ButtonProps\n extends React.ButtonHTMLAttributes,\n VariantProps {\n asChild?: boolean;\n}\n\nexport const Button = React.forwardRef(\n ({ className, variant, size, asChild = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'button';\n return (\n \n );\n },\n);\nButton.displayName = 'Button';\n","import React from 'react';\nimport * as LabelPrimitive from '@radix-ui/react-label';\nimport { cva, type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst labelVariants = cva(\n 'tw-text-sm tw-font-medium tw-leading-none peer-disabled:tw-cursor-not-allowed peer-disabled:tw-opacity-70',\n);\n\nexport const Label = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef & VariantProps\n>(({ className, ...props }, ref) => (\n \n));\nLabel.displayName = LabelPrimitive.Root.displayName;\n","import React from 'react';\nimport * as RadioGroupPrimitive from '@radix-ui/react-radio-group';\nimport { Circle } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst RadioGroup = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => {\n return (\n \n );\n});\nRadioGroup.displayName = RadioGroupPrimitive.Root.displayName;\n\nconst RadioGroupItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => {\n return (\n \n \n \n \n \n );\n});\nRadioGroupItem.displayName = RadioGroupPrimitive.Item.displayName;\n\nexport { RadioGroup, RadioGroupItem };\n","import React from 'react';\nimport * as PopoverPrimitive from '@radix-ui/react-popover';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Popover = PopoverPrimitive.Root;\n\nconst PopoverTrigger = PopoverPrimitive.Trigger;\n\nconst PopoverContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, align = 'center', sideOffset = 4, ...props }, ref) => (\n \n \n \n));\nPopoverContent.displayName = PopoverPrimitive.Content.displayName;\n\nexport { Popover, PopoverTrigger, PopoverContent };\n","import React from 'react';\nimport * as DialogPrimitive from '@radix-ui/react-dialog';\nimport { X } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Dialog = DialogPrimitive.Root;\n\nconst DialogTrigger = DialogPrimitive.Trigger;\n\nconst DialogPortal = DialogPrimitive.Portal;\n\nconst DialogClose = DialogPrimitive.Close;\n\nconst DialogOverlay = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nDialogOverlay.displayName = DialogPrimitive.Overlay.displayName;\n\nconst DialogContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, ...props }, ref) => (\n \n \n \n {children}\n \n \n Close\n \n \n \n));\nDialogContent.displayName = DialogPrimitive.Content.displayName;\n\nfunction DialogHeader({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nDialogHeader.displayName = 'DialogHeader';\n\nfunction DialogFooter({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nDialogFooter.displayName = 'DialogFooter';\n\nconst DialogTitle = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nDialogTitle.displayName = DialogPrimitive.Title.displayName;\n\nconst DialogDescription = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nDialogDescription.displayName = DialogPrimitive.Description.displayName;\n\nexport {\n Dialog,\n DialogPortal,\n DialogOverlay,\n DialogClose,\n DialogTrigger,\n DialogContent,\n DialogHeader,\n DialogFooter,\n DialogTitle,\n DialogDescription,\n};\n","import React from 'react';\nimport { type DialogProps } from '@radix-ui/react-dialog';\nimport { Command as CommandPrimitive } from 'cmdk';\nimport { Search } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Dialog, DialogContent } from '@/components/shadcn-ui/dialog';\n\nconst Command = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nCommand.displayName = CommandPrimitive.displayName;\n\ninterface CommandDialogProps extends DialogProps {}\n\nfunction CommandDialog({ children, ...props }: CommandDialogProps) {\n return (\n \n \n \n {children}\n \n \n \n );\n}\n\nconst CommandInput = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n
    \n \n \n
    \n));\n\nCommandInput.displayName = CommandPrimitive.Input.displayName;\n\nconst CommandList = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\n\nCommandList.displayName = CommandPrimitive.List.displayName;\n\nconst CommandEmpty = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>((props, ref) => (\n \n));\n\nCommandEmpty.displayName = CommandPrimitive.Empty.displayName;\n\nconst CommandGroup = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\n\nCommandGroup.displayName = CommandPrimitive.Group.displayName;\n\nconst CommandSeparator = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nCommandSeparator.displayName = CommandPrimitive.Separator.displayName;\n\nconst CommandItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\n\nCommandItem.displayName = CommandPrimitive.Item.displayName;\n\nfunction CommandShortcut({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nCommandShortcut.displayName = 'CommandShortcut';\n\nexport {\n Command,\n CommandDialog,\n CommandInput,\n CommandList,\n CommandEmpty,\n CommandGroup,\n CommandItem,\n CommandShortcut,\n CommandSeparator,\n};\n","import { useState } from 'react';\nimport { Check, ChevronsUpDown } from 'lucide-react';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport { Popover, PopoverContent, PopoverTrigger } from '@/components/shadcn-ui/popover';\nimport {\n Command,\n CommandEmpty,\n CommandInput,\n CommandItem,\n CommandList,\n} from '@/components/shadcn-ui/command';\nimport { PopoverProps } from '@radix-ui/react-popover';\n\nexport type ComboBoxLabelOption = { label: string };\nexport type ComboBoxOption = string | number | ComboBoxLabelOption;\n\nexport type ComboBoxProps = {\n /** Optional unique identifier */\n id?: string;\n /** Text label title for combobox */\n /** List of available options for the dropdown menu */\n options?: readonly T[];\n /** @deprecated 3 December 2024. Renamed to {@link buttonClassName} */\n className?: string;\n /** Additional css classes to help with unique styling of the combo box button */\n buttonClassName?: string;\n /** Additional css classes to help with unique styling of the combo box popover */\n popoverContentClassName?: string;\n /**\n * The selected value that the combo box currently holds. Must be shallow equal to one of the\n * options entries.\n */\n value?: T;\n /** Triggers when content of textfield is changed */\n onChange?: (newValue: T) => void;\n /** Used to determine the string value for a given option. */\n getOptionLabel?: (option: ComboBoxOption) => string;\n /** Text displayed on button if `value` is undefined */\n buttonPlaceholder?: string;\n /** Placeholder text for text field */\n textPlaceholder?: string;\n /** Text to display when no options match input */\n commandEmptyMessage?: string;\n /** Variant of button */\n buttonVariant?: ButtonProps['variant'];\n /** Text direction ltr or rtl */\n dir?: Direction;\n /** Optional boolean to set if trigger should be disabled */\n isDisabled?: boolean;\n} & PopoverProps;\n\ntype Direction = 'ltr' | 'rtl';\n\nfunction getOptionLabelDefault(option: ComboBoxOption): string {\n if (typeof option === 'string') {\n return option;\n }\n if (typeof option === 'number') {\n return option.toString();\n }\n return option.label;\n}\n\n/**\n * Autocomplete input and command palette with a list of suggestions.\n *\n * Thanks to Shadcn for heavy inspiration and documentation\n * https://ui.shadcn.com/docs/components/combobox\n */\nfunction ComboBox({\n id,\n options = [],\n buttonClassName,\n popoverContentClassName,\n value,\n onChange = () => {},\n getOptionLabel = getOptionLabelDefault,\n buttonPlaceholder = '',\n textPlaceholder = '',\n commandEmptyMessage = 'No option found',\n buttonVariant = 'outline',\n dir = 'ltr',\n isDisabled = false,\n ...props\n}: ComboBoxProps) {\n const [open, setOpen] = useState(false);\n\n return (\n \n \n \n \n {value ? getOptionLabel(value) : buttonPlaceholder}\n \n \n \n \n \n \n \n {commandEmptyMessage}\n \n {options.map((option) => (\n {\n onChange(option);\n setOpen(false);\n }}\n >\n \n {getOptionLabel(option)}\n \n ))}\n \n \n \n \n );\n}\n\nexport default ComboBox;\n","import { useMemo } from 'react';\nimport ComboBox from '@/components/basics/combo-box.component';\nimport { Label } from '@/components/shadcn-ui/label';\n\nexport type ChapterRangeSelectorProps = {\n startChapter: number;\n endChapter: number;\n handleSelectStartChapter: (chapter: number) => void;\n handleSelectEndChapter: (chapter: number) => void;\n isDisabled?: boolean;\n chapterCount: number;\n};\n\nexport default function ChapterRangeSelector({\n startChapter,\n endChapter,\n handleSelectStartChapter,\n handleSelectEndChapter,\n isDisabled = false,\n chapterCount,\n}: ChapterRangeSelectorProps) {\n const chapterOptions = useMemo(\n () => Array.from({ length: chapterCount }, (_, index) => index + 1),\n [chapterCount],\n );\n\n const onChangeStartChapter = (value: number) => {\n handleSelectStartChapter(value);\n if (value > endChapter) {\n handleSelectEndChapter(value);\n }\n };\n\n const onChangeEndChapter = (value: number) => {\n handleSelectEndChapter(value);\n if (value < startChapter) {\n handleSelectStartChapter(value);\n }\n };\n\n return (\n <>\n \n option.toString()}\n value={startChapter}\n />\n\n \n option.toString()}\n value={endChapter}\n />\n \n );\n}\n","import { Button } from '@/components/shadcn-ui/button';\nimport { Label } from '@/components/shadcn-ui/label';\nimport { RadioGroup, RadioGroupItem } from '@/components/shadcn-ui/radio-group';\nimport { Canon } from '@sillsdev/scripture';\nimport { LocalizedStringValue } from 'platform-bible-utils';\nimport { useState } from 'react';\nimport ChapterRangeSelector, {\n ChapterRangeSelectorProps,\n} from '../basics/chapter-range-selector.component';\n\nexport enum BookSelectionMode {\n CURRENT_BOOK = 'current book',\n CHOOSE_BOOKS = 'choose books',\n}\n\n/**\n * Object containing all keys used for localization in this component. If you're using this\n * component in an extension, you can pass it into the useLocalizedStrings hook to easily obtain the\n * localized strings and pass them into the localizedStrings prop of this component\n */\nexport const BOOK_SELECTOR_STRING_KEYS = Object.freeze([\n '%webView_bookSelector_currentBook%',\n '%webView_bookSelector_choose%',\n '%webView_bookSelector_chooseBooks%',\n] as const);\n\nexport type BookSelectorLocalizedStrings = {\n [localizedInventoryKey in (typeof BOOK_SELECTOR_STRING_KEYS)[number]]?: LocalizedStringValue;\n};\n\n/**\n * Gets the localized value for the provided key\n *\n * @param strings Object containing localized string\n * @param key Key for a localized string\n * @returns The localized value for the provided key, if available. Returns the key if no localized\n * value is available\n */\nconst localizeString = (\n strings: BookSelectorLocalizedStrings,\n key: keyof BookSelectorLocalizedStrings,\n) => {\n return strings[key] ?? key;\n};\n\ntype BookSelectorProps = ChapterRangeSelectorProps & {\n handleBookSelectionModeChange: (newMode: BookSelectionMode) => void;\n currentBookName: string;\n onSelectBooks: () => void;\n selectedBookIds: string[];\n localizedStrings: BookSelectorLocalizedStrings;\n};\n\nexport default function BookSelector({\n handleBookSelectionModeChange,\n currentBookName,\n onSelectBooks,\n selectedBookIds,\n chapterCount,\n endChapter,\n handleSelectEndChapter,\n startChapter,\n handleSelectStartChapter,\n localizedStrings,\n}: BookSelectorProps) {\n const currentBookText = localizeString(localizedStrings, '%webView_bookSelector_currentBook%');\n const chooseText = localizeString(localizedStrings, '%webView_bookSelector_choose%');\n const chooseBooksText = localizeString(localizedStrings, '%webView_bookSelector_chooseBooks%');\n\n const [bookSelectionMode, setBookSelectionMode] = useState(\n BookSelectionMode.CURRENT_BOOK,\n );\n\n const onSelectionModeChange = (newMode: BookSelectionMode) => {\n setBookSelectionMode(newMode);\n handleBookSelectionModeChange(newMode);\n };\n\n return (\n onSelectionModeChange(value as BookSelectionMode)}\n >\n
    \n
    \n
    \n \n \n
    \n \n
    \n \n
    \n
    \n
    \n
    \n \n \n
    \n \n onSelectBooks()}\n >\n {chooseText}\n \n
    \n
    \n \n );\n}\n","import { DropdownMenuTrigger } from '@radix-ui/react-dropdown-menu';\nimport { FilterIcon } from 'lucide-react';\nimport { Table } from '@tanstack/react-table';\n\nimport { Button } from '@/components/shadcn-ui/button';\nimport {\n DropdownMenu,\n DropdownMenuCheckboxItem,\n DropdownMenuContent,\n DropdownMenuLabel,\n DropdownMenuSeparator,\n} from '@/components/shadcn-ui/dropdown-menu';\n\ninterface DataTableViewOptionsProps {\n table: Table;\n}\n\nfunction DataTableViewOptions({ table }: DataTableViewOptionsProps) {\n return (\n \n \n \n \n \n Toggle columns\n \n {table\n .getAllColumns()\n .filter((column) => column.getCanHide())\n .map((column) => {\n return (\n column.toggleVisibility(!!value)}\n >\n {column.id}\n \n );\n })}\n \n \n );\n}\n\nexport default DataTableViewOptions;\n","import React from 'react';\nimport * as SelectPrimitive from '@radix-ui/react-select';\nimport { Check, ChevronDown, ChevronUp } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Select = SelectPrimitive.Root;\n\nconst SelectGroup = SelectPrimitive.Group;\n\nconst SelectValue = SelectPrimitive.Value;\n\nconst SelectTrigger = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, ...props }, ref) => (\n span]:tw-line-clamp-1',\n className,\n )}\n {...props}\n >\n {children}\n \n \n \n \n));\nSelectTrigger.displayName = SelectPrimitive.Trigger.displayName;\n\nconst SelectScrollUpButton = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n));\nSelectScrollUpButton.displayName = SelectPrimitive.ScrollUpButton.displayName;\n\nconst SelectScrollDownButton = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n));\nSelectScrollDownButton.displayName = SelectPrimitive.ScrollDownButton.displayName;\n\nconst SelectContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, position = 'popper', ...props }, ref) => (\n \n \n \n \n {children}\n \n \n \n \n));\nSelectContent.displayName = SelectPrimitive.Content.displayName;\n\nconst SelectLabel = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSelectLabel.displayName = SelectPrimitive.Label.displayName;\n\nconst SelectItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, ...props }, ref) => (\n \n \n \n \n \n \n\n {children}\n \n));\nSelectItem.displayName = SelectPrimitive.Item.displayName;\n\nconst SelectSeparator = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSelectSeparator.displayName = SelectPrimitive.Separator.displayName;\n\nexport {\n Select,\n SelectGroup,\n SelectValue,\n SelectTrigger,\n SelectContent,\n SelectLabel,\n SelectItem,\n SelectSeparator,\n SelectScrollUpButton,\n SelectScrollDownButton,\n};\n","import { ChevronLeftIcon, ChevronRightIcon, ArrowLeftIcon, ArrowRightIcon } from 'lucide-react';\nimport { Table } from '@tanstack/react-table';\n\nimport { Button } from '@/components/shadcn-ui/button';\nimport {\n Select,\n SelectContent,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\n\ninterface DataTablePaginationProps {\n table: Table;\n}\n\nfunction DataTablePagination({ table }: DataTablePaginationProps) {\n return (\n
    \n
    \n
    \n {table.getFilteredSelectedRowModel().rows.length} of{' '}\n {table.getFilteredRowModel().rows.length} row(s) selected\n
    \n
    \n

    Rows per page

    \n {\n table.setPageSize(Number(value));\n }}\n >\n \n \n \n \n {[10, 20, 30, 40, 50].map((pageSize) => (\n \n {pageSize}\n \n ))}\n \n \n
    \n
    \n Page {table.getState().pagination.pageIndex + 1} of {table.getPageCount()}\n
    \n
    \n table.setPageIndex(0)}\n disabled={!table.getCanPreviousPage()}\n >\n Go to first page\n \n \n table.previousPage()}\n disabled={!table.getCanPreviousPage()}\n >\n Go to previous page\n \n \n table.nextPage()}\n disabled={!table.getCanNextPage()}\n >\n Go to next page\n \n \n table.setPageIndex(table.getPageCount() - 1)}\n disabled={!table.getCanNextPage()}\n >\n Go to last page\n \n \n
    \n
    \n
    \n );\n}\n\nexport default DataTablePagination;\n","import React from 'react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Table = React.forwardRef<\n HTMLTableElement,\n React.HTMLAttributes & { stickyHeader?: boolean }\n>(({ className, stickyHeader, ...props }, ref) => (\n
    \n \n
    \n));\nTable.displayName = 'Table';\n\nconst TableHeader = React.forwardRef<\n HTMLTableSectionElement,\n React.HTMLAttributes & { stickyHeader?: boolean }\n>(({ className, stickyHeader, ...props }, ref) => (\n \n));\nTableHeader.displayName = 'TableHeader';\n\nconst TableBody = React.forwardRef<\n HTMLTableSectionElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableBody.displayName = 'TableBody';\n\nconst TableFooter = React.forwardRef<\n HTMLTableSectionElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n tr]:last:tw-border-b-0', className)}\n {...props}\n />\n));\nTableFooter.displayName = 'TableFooter';\n\nconst TableRow = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nTableRow.displayName = 'TableRow';\n\nconst TableHead = React.forwardRef<\n HTMLTableCellElement,\n React.ThHTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableHead.displayName = 'TableHead';\n\nconst TableCell = React.forwardRef<\n HTMLTableCellElement,\n React.TdHTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableCell.displayName = 'TableCell';\n\nconst TableCaption = React.forwardRef<\n HTMLTableCaptionElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableCaption.displayName = 'TableCaption';\n\nexport { Table, TableHeader, TableBody, TableFooter, TableHead, TableRow, TableCell, TableCaption };\n","import { useState } from 'react';\n\nimport {\n ColumnFiltersState,\n flexRender,\n getCoreRowModel,\n getFilteredRowModel,\n getPaginationRowModel,\n getSortedRowModel,\n SortingState,\n ColumnDef as TSColumnDef,\n Row as TSRow,\n RowSelectionState as TSRowSelectionState,\n SortDirection as TSSortDirection,\n Table as TSTable,\n useReactTable,\n VisibilityState,\n} from '@tanstack/react-table';\n\nimport DataTableViewOptions from '@/components/advanced/data-table/data-table-column-toggle.component';\nimport DataTablePagination from '@/components/advanced/data-table/data-table-pagination.component';\nimport { Button } from '@/components/shadcn-ui/button';\nimport {\n Table,\n TableBody,\n TableCell,\n TableHead,\n TableHeader,\n TableRow,\n} from '@/components/shadcn-ui/table';\n\nexport type ColumnDef = TSColumnDef;\nexport type RowContents = TSRow;\nexport type TableContents = TSTable;\nexport type SortDirection = TSSortDirection;\nexport type RowSelectionState = TSRowSelectionState;\n\ninterface DataTableProps {\n columns: ColumnDef[];\n data: TData[];\n enablePagination?: boolean;\n showPaginationControls?: boolean;\n showColumnVisibilityControls?: boolean;\n stickyHeader?: boolean;\n onRowClickHandler?: (row: RowContents, table: TableContents) => void;\n}\n\n/**\n * Feature-rich table component that infuses our basic shadcn-based Table component with features\n * from TanStack's React Table library\n */\nfunction DataTable({\n columns,\n data,\n enablePagination = false,\n showPaginationControls = false,\n showColumnVisibilityControls = false,\n stickyHeader = false,\n onRowClickHandler = () => {},\n}: DataTableProps) {\n const [sorting, setSorting] = useState([]);\n const [columnFilters, setColumnFilters] = useState([]);\n const [columnVisibility, setColumnVisibility] = useState({});\n const [rowSelection, setRowSelection] = useState({});\n\n const table = useReactTable({\n data,\n columns,\n getCoreRowModel: getCoreRowModel(),\n ...(enablePagination && { getPaginationRowModel: getPaginationRowModel() }),\n onSortingChange: setSorting,\n getSortedRowModel: getSortedRowModel(),\n onColumnFiltersChange: setColumnFilters,\n getFilteredRowModel: getFilteredRowModel(),\n onColumnVisibilityChange: setColumnVisibility,\n onRowSelectionChange: setRowSelection,\n state: {\n sorting,\n columnFilters,\n columnVisibility,\n rowSelection,\n },\n });\n\n return (\n
    \n {showColumnVisibilityControls && }\n \n \n {table.getHeaderGroups().map((headerGroup) => (\n \n {headerGroup.headers.map((header) => {\n return (\n \n {header.isPlaceholder\n ? undefined\n : flexRender(header.column.columnDef.header, header.getContext())}\n \n );\n })}\n \n ))}\n \n \n {table.getRowModel().rows?.length ? (\n table.getRowModel().rows.map((row) => (\n onRowClickHandler(row, table)}\n key={row.id}\n data-state={row.getIsSelected() && 'selected'}\n >\n {row.getVisibleCells().map((cell) => (\n \n {flexRender(cell.column.columnDef.cell, cell.getContext())}\n \n ))}\n \n ))\n ) : (\n \n \n No results.\n \n \n )}\n \n
    \n {enablePagination && (\n
    \n table.previousPage()}\n disabled={!table.getCanPreviousPage()}\n >\n Previous\n \n table.nextPage()}\n disabled={!table.getCanNextPage()}\n >\n Next\n \n
    \n )}\n {enablePagination && showPaginationControls && }\n
    \n );\n}\n\nexport default DataTable;\n","import {\n Table,\n TableBody,\n TableCell,\n TableHead,\n TableHeader,\n TableRow,\n} from '@/components/shadcn-ui/table';\nimport { Canon } from '@sillsdev/scripture';\nimport { deepEqual, LanguageStrings, ScriptureReference } from 'platform-bible-utils';\nimport { useMemo } from 'react';\nimport { InventoryItemOccurrence } from './inventory-utils';\n\n/** Props for the OccurrencesTable component */\ntype OccurrencesTableProps = {\n /** Data that contains scriptures references and snippets of scripture */\n occurrenceData: InventoryItemOccurrence[];\n /** Callback function that is executed when the scripture reference is changed */\n setScriptureReference: (scriptureReference: ScriptureReference) => void;\n /**\n * Object with all localized strings that the OccurrencesTable needs to work well across multiple\n * languages\n */\n localizedStrings: LanguageStrings;\n};\n\n/**\n * Table that shows occurrences of specified inventory item(s). The first column shows the related\n * scripture reference. The second column shows the snippet of scripture that contains the specified\n * inventory item\n */\nfunction OccurrencesTable({\n occurrenceData,\n setScriptureReference,\n localizedStrings,\n}: OccurrencesTableProps) {\n const referenceHeaderText =\n localizedStrings['%webView_inventory_occurrences_table_header_reference%'];\n const occurrenceHeaderText =\n localizedStrings['%webView_inventory_occurrences_table_header_occurrence%'];\n\n const occurrences: InventoryItemOccurrence[] = useMemo(() => {\n const uniqueOccurrences: InventoryItemOccurrence[] = [];\n\n occurrenceData.forEach((occurrence) => {\n if (!uniqueOccurrences.some((uniqueOccurrence) => deepEqual(uniqueOccurrence, occurrence))) {\n uniqueOccurrences.push(occurrence);\n }\n });\n\n return uniqueOccurrences;\n }, [occurrenceData]);\n\n return (\n \n \n \n {referenceHeaderText}\n {occurrenceHeaderText}\n \n \n \n {occurrences.length > 0 &&\n occurrences.map((occurrence) => (\n {\n setScriptureReference(occurrence.reference);\n }}\n >\n {`${Canon.bookNumberToEnglishName(occurrence.reference.bookNum)} ${occurrence.reference.chapterNum}:${occurrence.reference.verseNum}`}\n {occurrence.text}\n \n ))}\n \n
    \n );\n}\n\nexport default OccurrencesTable;\n","import React from 'react';\nimport * as CheckboxPrimitive from '@radix-ui/react-checkbox';\nimport { Check } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Checkbox = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n \n \n));\nCheckbox.displayName = CheckboxPrimitive.Root.displayName;\n\nexport default Checkbox;\n","import { Canon } from '@sillsdev/scripture';\nimport { ScriptureReference } from 'platform-bible-utils';\n\n/* #region Types */\n\n/**\n * Status of items that appear in inventories. 'approved' and 'unapproved' items are defined in the\n * project's `Settings.xml`. All other items are defined as 'unknown'\n */\nexport type Status = 'approved' | 'unapproved' | 'unknown';\n\n/** Occurrence of item in inventory. Primarily used by table that shows occurrences */\nexport type InventoryItemOccurrence = {\n /** Reference to scripture where the item appears */\n reference: ScriptureReference;\n /** Snippet of scripture that contains the occurrence */\n text: string;\n};\n\n/** Data structure that contains all information on an item that is shown in an inventory */\nexport type InventoryTableData = {\n /**\n * The item (e.g. a character in the characters inventory, a marker in the marker inventory) In\n * most cases the array will only have one element. In case of additional items (e.g. the\n * preceding marker in the markers check), the primary item should be stored in the first index.\n * To show additional items in the inventory, make sure to configure the `additionalItemsLabels`\n * prop for the Inventory component\n */\n items: string[];\n /** The number of times this item occurs in the selected scope */\n count: number;\n /** The status of this item (see documentation for `Status` type for more information) */\n status: Status;\n /** Occurrences of this item in the scripture text for the selected scope */\n occurrences: InventoryItemOccurrence[];\n};\n\n/* #endregion */\n\n/* #region Functions */\n\n/**\n * Splits USFM string into shorter line-like segments\n *\n * @param text A single (likely very large) USFM string\n * @returns An array containing the input text, split into shorter segments\n */\nexport const getLinesFromUSFM = (text: string) => {\n // Splits on (CR)LF, CR, \\v, \\c and \\id\n return text.split(/(?:\\r?\\n|\\r)|(?=(?:\\\\(?:v|c|id)))/g);\n};\n\n/**\n * Extracts chapter or verse number from USFM strings that start with a \\c or \\v marker\n *\n * @param text USFM string that is expected to start with \\c or \\v marker\n * @returns Chapter or verse number if one is found. Else returns 0.\n */\nexport const getNumberFromUSFM = (text: string): number | undefined => {\n // Captures all digits that follow \\v or \\c markers followed by whitespace located at the start of a string\n const regex = /^\\\\[vc]\\s+(\\d+)/;\n const match = text.match(regex);\n\n if (match) {\n return +match[1];\n }\n return undefined;\n};\n\n/**\n * Gets book ID from USFM string that starts with the \\id marker, and returns book number for it\n *\n * @param text USFM string that is expected to start with \\id marker\n * @returns Book number corresponding to the \\id marker in the input text. Returns 0 if no marker is\n * found or the marker is not valid\n */\nexport const getBookNumFromId = (text: string): number => {\n // Captures all digits that follow an \\id marker followed by whitespace located at the start of a string\n const match = text.match(/^\\\\id\\s+([A-Za-z]+)/);\n if (match) {\n return Canon.bookIdToNumber(match[1]);\n }\n return 0;\n};\n\n/**\n * Gets the status for an item, typically used in the Inventory component\n *\n * @param item The item for which the status is being requested\n * @param approvedItems Array of approved items, typically as defined in `Settings.xml`\n * @param unapprovedItems Array of unapproved items, typically as defined in `Settings.xml`\n * @returns The status for the specified item\n */\nexport const getStatusForItem = (\n item: string,\n approvedItems: string[],\n unapprovedItems: string[],\n): Status => {\n if (unapprovedItems.includes(item)) return 'unapproved';\n if (approvedItems.includes(item)) return 'approved';\n return 'unknown';\n};\n\n/* #endregion */\n","import React from 'react';\nimport * as TogglePrimitive from '@radix-ui/react-toggle';\nimport { cva, type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst toggleVariants = cva(\n 'pr-twp tw-inline-flex tw-items-center tw-justify-center tw-rounded-md tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-colors hover:tw-bg-muted hover:tw-text-muted-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50 data-[state=on]:tw-bg-accent data-[state=on]:tw-text-accent-foreground',\n {\n variants: {\n variant: {\n default: 'tw-bg-transparent',\n outline:\n 'tw-border tw-border-input tw-bg-transparent hover:tw-bg-accent hover:tw-text-accent-foreground',\n },\n size: {\n default: 'tw-h-10 tw-px-3',\n sm: 'tw-h-9 tw-px-2.5',\n lg: 'tw-h-11 tw-px-5',\n },\n },\n defaultVariants: {\n variant: 'default',\n size: 'default',\n },\n },\n);\n\nconst Toggle = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef & VariantProps\n>(({ className, variant, size, ...props }, ref) => (\n \n));\n\nToggle.displayName = TogglePrimitive.Root.displayName;\n\nexport { Toggle, toggleVariants };\n","import React from 'react';\nimport * as ToggleGroupPrimitive from '@radix-ui/react-toggle-group';\nimport { type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { toggleVariants } from '@/components/shadcn-ui/toggle';\n\nconst ToggleGroupContext = React.createContext>({\n size: 'default',\n variant: 'default',\n});\n\nconst ToggleGroup = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef &\n VariantProps\n>(({ className, variant, size, children, ...props }, ref) => (\n \n \n {children}\n \n \n));\n\nToggleGroup.displayName = ToggleGroupPrimitive.Root.displayName;\n\nconst ToggleGroupItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef &\n VariantProps\n>(({ className, children, variant, size, ...props }, ref) => {\n const context = React.useContext(ToggleGroupContext);\n\n return (\n \n {children}\n \n );\n});\n\nToggleGroupItem.displayName = ToggleGroupPrimitive.Item.displayName;\n\nexport { ToggleGroup, ToggleGroupItem };\n","import { ColumnDef, SortDirection } from '@/components/advanced/data-table/data-table.component';\nimport { Button } from '@/components/shadcn-ui/button';\nimport { ToggleGroup, ToggleGroupItem } from '@/components/shadcn-ui/toggle-group';\nimport {\n ArrowDownIcon,\n ArrowUpDownIcon,\n ArrowUpIcon,\n CircleCheckIcon,\n CircleHelpIcon,\n CircleXIcon,\n} from 'lucide-react';\nimport { ReactNode } from 'react';\nimport { InventoryTableData, Status } from './inventory-utils';\n\n/**\n * Gets an icon that indicates the current sorting direction based on the provided input\n *\n * @param sortDirection Sorting direction. Can be ascending ('asc'), descending ('desc') or false (\n * i.e. not sorted)\n * @returns The appropriate sorting icon for the provided sorting direction\n */\nconst getSortingIcon = (sortDirection: false | SortDirection): ReactNode => {\n if (sortDirection === 'asc') {\n return ;\n }\n if (sortDirection === 'desc') {\n return ;\n }\n return ;\n};\n\n/**\n * Function that creates the item column for inventories\n *\n * @param itemLabel Localized label for the item column (e.g. 'Character', 'Repeated Word', etc.)\n * @returns Column that shows the inventory items. Should be used with the DataTable component\n */\nexport const inventoryItemColumn = (itemLabel: string): ColumnDef => {\n return {\n accessorKey: 'item',\n accessorFn: (row: InventoryTableData) => row.items[0],\n header: ({ column }) => (\n \n ),\n };\n};\n\n/**\n * Function that creates the additional item columns for inventories\n *\n * @param additionalItemLabel Localized label for the additional item column (e.g. 'Preceding\n * Marker')\n * @param additionalItemIndex Index that locates the desired item in the items array of the\n * inventory\n * @returns Column that shows additional inventory items. Should be used with the DataTable\n * component\n */\nexport const inventoryAdditionalItemColumn = (\n additionalItemLabel: string,\n additionalItemIndex: number,\n): ColumnDef => {\n return {\n accessorKey: `item${additionalItemIndex}`,\n accessorFn: (row: InventoryTableData) => row.items[additionalItemIndex],\n header: ({ column }) => (\n \n ),\n };\n};\n\n/**\n * Function that creates the count column for inventories. Should be used with the DataTable\n * component.\n *\n * @param itemLabel Localized label for the count column\n * @returns Column that shows the number of occurrences of the related inventory items\n */\nexport const inventoryCountColumn = (countLabel: string): ColumnDef => {\n return {\n accessorKey: 'count',\n header: ({ column }) => (\n
    \n \n
    \n ),\n cell: ({ row }) =>
    {row.getValue('count')}
    ,\n };\n};\n\n/**\n * Function that updates project settings when status for item(s) changes\n *\n * @param changedItems Array of items for which the status is being updated\n * @param newStatus The status that the items are being given\n * @param approvedItems Array of currently approved items\n * @param onApprovedItemsChange Callback function that stores the updated list of approved items\n * @param unapprovedItems Array of currently unapproved items\n * @param onUnapprovedItemsChange Callback function that stores the updated list of unapproved items\n */\nconst statusChangeHandler = (\n changedItems: string[],\n newStatus: Status,\n approvedItems: string[],\n onApprovedItemsChange: (items: string[]) => void,\n unapprovedItems: string[],\n onUnapprovedItemsChange: (items: string[]) => void,\n) => {\n let newApprovedItems: string[] = [...approvedItems];\n changedItems.forEach((item) => {\n if (newStatus === 'approved') {\n if (!newApprovedItems.includes(item)) {\n newApprovedItems.push(item);\n }\n } else {\n newApprovedItems = newApprovedItems.filter((validItem) => validItem !== item);\n }\n });\n onApprovedItemsChange(newApprovedItems);\n\n let newUnapprovedItems: string[] = [...unapprovedItems];\n changedItems.forEach((item) => {\n if (newStatus === 'unapproved') {\n if (!newUnapprovedItems.includes(item)) {\n newUnapprovedItems.push(item);\n }\n } else {\n newUnapprovedItems = newUnapprovedItems.filter((unapprovedItem) => unapprovedItem !== item);\n }\n });\n onUnapprovedItemsChange(newUnapprovedItems);\n};\n\n/**\n * Function that creates the status column for inventories. Should be used with the DataTable\n * component.\n *\n * @param statusLabel Localized label for the status column\n * @param approvedItems Array of approved items, typically as defined in `Settings.xml`\n * @param onApprovedItemsChange Callback function that stores the updated list of approved items\n * @param unapprovedItems Array of unapproved items, typically as defined in `Settings.xml`\n * @param onUnapprovedItemsChange Callback function that stores the updated list of unapproved items\n * @returns Column that shows the status buttons for the related inventory item. The button for the\n * current status of the item is selected\n */\nexport const inventoryStatusColumn = (\n statusLabel: string,\n approvedItems: string[],\n onApprovedItemsChange: (items: string[]) => void,\n unapprovedItems: string[],\n onUnapprovedItemsChange: (items: string[]) => void,\n): ColumnDef => {\n return {\n accessorKey: 'status',\n header: ({ column }) => {\n return (\n
    \n \n
    \n );\n },\n cell: ({ row }) => {\n const status: Status = row.getValue('status');\n const item: string = row.getValue('item');\n return (\n \n \n statusChangeHandler(\n [item],\n 'approved',\n approvedItems,\n onApprovedItemsChange,\n unapprovedItems,\n onUnapprovedItemsChange,\n )\n }\n value=\"approved\"\n >\n \n \n \n statusChangeHandler(\n [item],\n 'unapproved',\n approvedItems,\n onApprovedItemsChange,\n unapprovedItems,\n onUnapprovedItemsChange,\n )\n }\n value=\"unapproved\"\n >\n \n \n \n statusChangeHandler(\n [item],\n 'unknown',\n approvedItems,\n onApprovedItemsChange,\n unapprovedItems,\n onUnapprovedItemsChange,\n )\n }\n value=\"unknown\"\n >\n \n \n \n );\n },\n };\n};\n","import DataTable, {\n ColumnDef,\n RowContents,\n RowSelectionState,\n TableContents,\n} from '@/components/advanced/data-table/data-table.component';\nimport OccurrencesTable from '@/components/advanced/inventory/occurrences-table.component';\nimport Checkbox from '@/components/shadcn-ui/checkbox';\nimport { Input } from '@/components/shadcn-ui/input';\nimport { Label } from '@/components/shadcn-ui/label';\nimport {\n Select,\n SelectContent,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\nimport {\n deepEqual,\n LocalizedStringValue,\n ScriptureReference,\n substring,\n} from 'platform-bible-utils';\nimport { useEffect, useMemo, useState } from 'react';\nimport {\n getBookNumFromId,\n getLinesFromUSFM,\n getNumberFromUSFM,\n getStatusForItem,\n InventoryItemOccurrence,\n InventoryTableData,\n Status,\n} from './inventory-utils';\nimport { inventoryAdditionalItemColumn } from './inventory-columns';\n\n/**\n * Object containing all keys used for localization in this component. If you're using this\n * component in an extension, you can pass it into the useLocalizedStrings hook to easily obtain the\n * localized strings and pass them into the localizedStrings prop of this component\n */\nexport const INVENTORY_STRING_KEYS = Object.freeze([\n '%webView_inventory_all%',\n '%webView_inventory_approved%',\n '%webView_inventory_unapproved%',\n '%webView_inventory_unknown%',\n '%webView_inventory_scope_currentBook%',\n '%webView_inventory_scope_chapter%',\n '%webView_inventory_scope_verse%',\n '%webView_inventory_filter_text%',\n '%webView_inventory_show_additional_items%',\n '%webView_inventory_occurrences_table_header_reference%',\n '%webView_inventory_occurrences_table_header_occurrence%',\n] as const);\n\nexport type InventoryLocalizedStrings = {\n [localizedInventoryKey in (typeof INVENTORY_STRING_KEYS)[number]]?: LocalizedStringValue;\n};\n\n/** Scope of scripture that the inventory can operate on */\nexport type Scope = 'book' | 'chapter' | 'verse';\n\n/** Status values that the status filter can select from */\ntype StatusFilter = Status | 'all';\n\n/** Text labels for the inventory columns and the control components of additional inventory items */\ntype AdditionalItemsLabels = {\n checkboxText?: string;\n tableHeaders?: string[];\n};\n\n/**\n * Filters data that is shown in the DataTable section of the Inventory\n *\n * @param itemData All inventory items and their related information\n * @param statusFilter Allows filtering by status (i.e. show all items, or only items that are\n * 'approved', 'unapproved' or 'unknown')\n * @param textFilter Allows filtering by text. All items that include the filter text will be\n * selected.\n * @returns Array of items and their related information that are matched by the specified filters\n */\nconst filterItemData = (\n itemData: InventoryTableData[],\n statusFilter: StatusFilter,\n textFilter: string,\n): InventoryTableData[] => {\n let filteredItemData: InventoryTableData[] = itemData;\n\n if (statusFilter !== 'all') {\n filteredItemData = filteredItemData.filter(\n (item) =>\n (statusFilter === 'approved' && item.status === 'approved') ||\n (statusFilter === 'unapproved' && item.status === 'unapproved') ||\n (statusFilter === 'unknown' && item.status === 'unknown'),\n );\n }\n\n if (textFilter !== '')\n filteredItemData = filteredItemData.filter((item) => item.items[0].includes(textFilter));\n\n return filteredItemData;\n};\n\n/**\n * Turns array of strings into array of inventory items, along with their count and status\n *\n * @param text The source scripture text that is searched for inventory items\n * @param scriptureRef The scripture reference that the application is currently set to\n * @param approvedItems Array of approved items, typically as defined in `Settings.xml`\n * @param unapprovedItems Array of unapproved items, typically as defined in `Settings.xml`\n * @param itemRegex Regular expression that describes what items this Inventory should extract from\n * the provided scripture text\n * @returns Array of inventory items, along with their count and status\n */\nconst createTableData = (\n text: string | undefined,\n scriptureRef: ScriptureReference,\n approvedItems: string[],\n unapprovedItems: string[],\n itemRegex: RegExp,\n): InventoryTableData[] => {\n if (!text) return [];\n\n const tableData: InventoryTableData[] = [];\n\n let currentBook: number | undefined = scriptureRef.bookNum;\n let currentChapter: number | undefined = scriptureRef.chapterNum;\n let currentVerse: number | undefined = scriptureRef.verseNum;\n\n const lines = getLinesFromUSFM(text);\n\n lines.forEach((line: string) => {\n if (line.startsWith('\\\\id')) {\n currentBook = getBookNumFromId(line);\n currentChapter = 0;\n currentVerse = 0;\n }\n if (line.startsWith('\\\\c')) {\n currentChapter = getNumberFromUSFM(line);\n currentVerse = 0;\n }\n if (line.startsWith('\\\\v')) {\n currentVerse = getNumberFromUSFM(line);\n if (currentChapter === 0) {\n currentChapter = scriptureRef.chapterNum;\n }\n }\n\n let match: RegExpExecArray | undefined = itemRegex.exec(line) ?? undefined;\n while (match) {\n const items: string[] = [];\n match.forEach((item) => items.push(item));\n const itemIndex = match.index;\n const existingItem = tableData.find((tableEntry) => deepEqual(tableEntry.items, items));\n const newReference: InventoryItemOccurrence = {\n reference: {\n bookNum: currentBook !== undefined ? currentBook : -1,\n chapterNum: currentChapter !== undefined ? currentChapter : -1,\n verseNum: currentVerse !== undefined ? currentVerse : -1,\n },\n text: substring(line, Math.max(0, itemIndex - 25), Math.min(itemIndex + 25, line.length)),\n };\n if (existingItem) {\n existingItem.count += 1;\n existingItem.occurrences.push(newReference);\n } else {\n const newItem: InventoryTableData = {\n items,\n count: 1,\n status: getStatusForItem(items[0], approvedItems, unapprovedItems),\n occurrences: [newReference],\n };\n tableData.push(newItem);\n }\n\n match = itemRegex.exec(line) ?? undefined;\n }\n });\n\n return tableData;\n};\n\n/**\n * Gets the localized value for the provided key\n *\n * @param strings Object containing localized string\n * @param key Key for a localized string\n * @returns The localized value for the provided key, if available. Returns the key if no localized\n * value is available\n */\nconst localizeString = (\n strings: InventoryLocalizedStrings,\n key: keyof InventoryLocalizedStrings,\n) => {\n return strings[key] ?? key;\n};\n\n/** Props for the Inventory component */\ntype InventoryProps = {\n /** The scripture reference that the application is currently set to */\n scriptureReference: ScriptureReference;\n /** Callback function that is executed when the scripture reference is changed */\n setScriptureReference: (scriptureReference: ScriptureReference) => void;\n /**\n * Object with all localized strings that the Inventory needs to work well across multiple\n * languages. When using this component with Platform.Bible, you can import\n * `INVENTORY_STRING_KEYS` from this library, pass it in to the Platform's localization hook, and\n * pass the localized keys that are returned by the hook into this prop.\n */\n localizedStrings: InventoryLocalizedStrings;\n /**\n * The logic that finds the desired items in the source text. This can either be a Regular\n * expression that captures one or multiple items (preferred), or a custom function that builds\n * and return an InventoryDataTable[] manually. Note: In case the logic captures more than one\n * item (i.e. InventoryTableData.items has a length greater than 1), you must provide text labels\n * for the related columns and control elements to show by setting the `additionalItemsLabels`\n * prop\n */\n extractItems:\n | RegExp\n | ((\n text: string | undefined,\n scriptureRef: ScriptureReference,\n approvedItems: string[],\n unapprovedItems: string[],\n ) => InventoryTableData[]);\n /**\n * Text labels for control elements and additional column headers in case your Inventory has more\n * than one item to show (e.g. The 'Preceding Marker' in the Markers Inventory)\n */\n additionalItemsLabels?: AdditionalItemsLabels;\n /** Array of approved items, typically as defined in `Settings.xml` */\n approvedItems: string[];\n /** Array of unapproved items, typically as defined in `Settings.xml` */\n unapprovedItems: string[];\n /** The source scripture text that is searched for in inventory items */\n text: string | undefined;\n /** Scope of scripture that the inventory will operate on */\n scope: Scope;\n /** Callback function that is executed when the scope is changed from the Inventory */\n onScopeChange: (scope: Scope) => void;\n /**\n * Column definitions for the Inventory data table. The most commonly used column definitions are\n * pre-configured for your convenience and can be imported (e.g. inventoryItemColumn,\n * inventoryAdditionalItemColumn inventoryCountColumn, and inventoryStatusColumn). If you need any\n * other columns you can add these yourself\n */\n columns: ColumnDef[];\n};\n\n/** Inventory component that is used to view and control the status of provided project settings */\nexport default function Inventory({\n scriptureReference,\n setScriptureReference,\n localizedStrings,\n extractItems,\n additionalItemsLabels,\n approvedItems,\n unapprovedItems,\n text,\n scope,\n onScopeChange,\n columns,\n}: InventoryProps) {\n const allItemsText = localizeString(localizedStrings, '%webView_inventory_all%');\n const approvedItemsText = localizeString(localizedStrings, '%webView_inventory_approved%');\n const unapprovedItemsText = localizeString(localizedStrings, '%webView_inventory_unapproved%');\n const unknownItemsText = localizeString(localizedStrings, '%webView_inventory_unknown%');\n const scopeBookText = localizeString(localizedStrings, '%webView_inventory_scope_currentBook%');\n const scopeChapterText = localizeString(localizedStrings, '%webView_inventory_scope_chapter%');\n const scopeVerseText = localizeString(localizedStrings, '%webView_inventory_scope_verse%');\n const filterText = localizeString(localizedStrings, '%webView_inventory_filter_text%');\n const showAdditionalItemsText = localizeString(\n localizedStrings,\n '%webView_inventory_show_additional_items%',\n );\n\n const [showAdditionalItems, setShowAdditionalItems] = useState(false);\n const [statusFilter, setStatusFilter] = useState('all');\n const [textFilter, setTextFilter] = useState('');\n const [selectedItem, setSelectedItem] = useState([]);\n\n const tableData: InventoryTableData[] = useMemo(() => {\n if (!text) return [];\n if (extractItems instanceof RegExp)\n return createTableData(\n text,\n scriptureReference,\n approvedItems,\n unapprovedItems,\n extractItems,\n );\n return extractItems(text, scriptureReference, approvedItems, unapprovedItems);\n }, [text, extractItems, scriptureReference, approvedItems, unapprovedItems]);\n\n const reducedTableData: InventoryTableData[] = useMemo(() => {\n if (showAdditionalItems) return tableData;\n\n const newTableData: InventoryTableData[] = [];\n\n tableData.forEach((tableEntry) => {\n const firstItem = tableEntry.items[0];\n\n const existingEntry = newTableData.find(\n (newTableEntry) => newTableEntry.items[0] === firstItem,\n );\n\n if (existingEntry) {\n existingEntry.count += tableEntry.count;\n existingEntry.occurrences = existingEntry.occurrences.concat(tableEntry.occurrences);\n } else {\n newTableData.push({\n items: [firstItem],\n count: tableEntry.count,\n occurrences: tableEntry.occurrences,\n status: tableEntry.status,\n });\n }\n });\n\n return newTableData;\n }, [showAdditionalItems, tableData]);\n\n const filteredTableData: InventoryTableData[] = useMemo(() => {\n return filterItemData(reducedTableData, statusFilter, textFilter);\n }, [reducedTableData, statusFilter, textFilter]);\n\n const allColumns: ColumnDef[] = useMemo(() => {\n if (!showAdditionalItems) return columns;\n\n const numberOfAdditionalItems = additionalItemsLabels?.tableHeaders?.length;\n if (!numberOfAdditionalItems) return columns;\n\n const additionalColumns: ColumnDef[] = [];\n\n for (let index = 0; index < numberOfAdditionalItems; index++) {\n additionalColumns.push(\n inventoryAdditionalItemColumn(\n additionalItemsLabels?.tableHeaders?.[index] || 'Additional Item',\n index + 1,\n ),\n );\n }\n\n return [...additionalColumns, ...columns];\n }, [additionalItemsLabels?.tableHeaders, columns, showAdditionalItems]);\n\n useEffect(() => {\n setSelectedItem([]);\n }, [filteredTableData]);\n\n const rowClickHandler = (\n row: RowContents,\n table: TableContents,\n ) => {\n table.setRowSelection(() => {\n const newSelection: RowSelectionState = {};\n newSelection[row.index] = true;\n return newSelection;\n });\n\n setSelectedItem(row.original.items);\n };\n\n const handleScopeChange = (value: string) => {\n if (value === 'book' || value === 'chapter' || value === 'verse') {\n onScopeChange(value);\n } else {\n throw new Error(`Invalid scope value: ${value}`);\n }\n };\n\n const handleStatusFilterChange = (value: string) => {\n if (value === 'all' || value === 'approved' || value === 'unapproved' || value === 'unknown') {\n setStatusFilter(value);\n } else {\n throw new Error(`Invalid status filter value: ${value}`);\n }\n };\n\n const occurrenceData: InventoryItemOccurrence[] = useMemo(() => {\n if (reducedTableData.length === 0 || selectedItem.length === 0) return [];\n const occurrence = reducedTableData.filter((tableEntry: InventoryTableData) => {\n return deepEqual(\n showAdditionalItems ? tableEntry.items : [tableEntry.items[0]],\n selectedItem,\n );\n });\n if (occurrence.length > 1) throw new Error('Selected item is not unique');\n return occurrence[0].occurrences;\n }, [selectedItem, showAdditionalItems, reducedTableData]);\n\n return (\n
    \n
    \n handleStatusFilterChange(value)}\n defaultValue={statusFilter}\n >\n \n \n \n \n {allItemsText}\n {approvedItemsText}\n {unapprovedItemsText}\n {unknownItemsText}\n \n \n \n {\n setTextFilter(event.target.value);\n }}\n />\n {additionalItemsLabels && (\n
    \n {\n setSelectedItem([]);\n setShowAdditionalItems(checked);\n }}\n />\n \n
    \n )}\n
    \n
    \n \n
    \n {occurrenceData.length > 0 && (\n
    \n \n
    \n )}\n
    \n );\n}\n","import { Input } from '@/components/shadcn-ui/input';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { useState } from 'react';\n\n/** Props for the SearchBar component. */\nexport type SearchBarProps = {\n className?: string;\n /**\n * Callback fired to handle the search query when button pressed\n *\n * @param searchQuery\n */\n onSearch: (searchQuery: string) => void;\n\n /** Optional string that appears in the search bar without a search string */\n placeholder?: string;\n\n /** Optional boolean to set the input base to full width */\n isFullWidth?: boolean;\n};\n\nexport default function SearchBar({\n className,\n onSearch,\n placeholder,\n isFullWidth,\n}: SearchBarProps) {\n const [searchQuery, setSearchQuery] = useState('');\n\n const handleInputChange = (searchString: string) => {\n setSearchQuery(searchString);\n onSearch(searchString);\n };\n\n return (\n handleInputChange(e.target.value)}\n />\n );\n}\n","// adapted from: https://github.com/shadcn-ui/ui/discussions/752\n\n'use client';\n\nimport { TabsContentProps, TabsListProps, TabsTriggerProps } from '@/components/shadcn-ui/tabs';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport * as TabsPrimitive from '@radix-ui/react-tabs';\nimport React from 'react';\n\nexport type VerticalTabsProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport type LeftTabsTriggerProps = TabsTriggerProps & {\n value: string;\n ref?: React.Ref;\n};\n\nexport const VerticalTabs = React.forwardRef<\n React.ElementRef,\n VerticalTabsProps\n>(({ className, ...props }, ref) => (\n \n));\n\nVerticalTabs.displayName = TabsPrimitive.List.displayName;\n\nexport const VerticalTabsList = React.forwardRef<\n React.ElementRef,\n TabsListProps\n>(({ className, ...props }, ref) => (\n \n));\nVerticalTabsList.displayName = TabsPrimitive.List.displayName;\n\nexport const VerticalTabsTrigger = React.forwardRef<\n React.ElementRef,\n LeftTabsTriggerProps\n>(({ className, ...props }, ref) => (\n \n));\n\nexport const VerticalTabsContent = React.forwardRef<\n React.ElementRef,\n TabsContentProps\n>(({ className, ...props }, ref) => (\n \n));\nVerticalTabsContent.displayName = TabsPrimitive.Content.displayName;\n","import SearchBar from '@/components/basics/search-bar.component';\nimport {\n VerticalTabs,\n VerticalTabsContent,\n VerticalTabsList,\n VerticalTabsTrigger,\n} from '@/components/basics/tabs-vertical';\nimport { ReactNode } from 'react';\n\nexport type TabKeyValueContent = {\n key: string;\n value: string;\n content: ReactNode;\n};\n\nexport type TabNavigationContentSearchProps = {\n /** List of values and keys for each tab this component should provide */\n tabList: TabKeyValueContent[];\n\n /** Handler to run when the value of the search bar changes */\n onSearch: (searchQuery: string) => void;\n\n /** Optional placeholder for the search bar */\n searchPlaceholder?: string;\n\n /** Optional title to include in the header */\n headerTitle?: string;\n\n /** Optional flag to make the search bar appear full width */\n isSearchBarFullWidth?: boolean;\n\n /** Text direction ltr or rtl */\n direction?: 'ltr' | 'rtl';\n};\n\nexport default function TabNavigationContentSearch({\n tabList,\n onSearch,\n searchPlaceholder,\n headerTitle,\n isSearchBarFullWidth = false,\n direction = 'ltr',\n}: TabNavigationContentSearchProps) {\n return (\n
    \n
    \n {headerTitle ?

    {headerTitle}

    : ''}\n \n
    \n \n \n {tabList.map((tab) => (\n \n {tab.value}\n \n ))}\n \n {tabList.map((tab) => (\n \n {tab.content}\n \n ))}\n \n
    \n );\n}\n","import React from 'react';\nimport * as SeparatorPrimitive from '@radix-ui/react-separator';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Separator = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, orientation = 'horizontal', decorative = true, ...props }, ref) => (\n \n));\nSeparator.displayName = SeparatorPrimitive.Root.displayName;\n\nexport { Separator };\n","import React from 'react';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nfunction Skeleton({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\n\nexport { Skeleton };\n","import React from 'react';\nimport * as TooltipPrimitive from '@radix-ui/react-tooltip';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst TooltipProvider = TooltipPrimitive.Provider;\n\nconst Tooltip = TooltipPrimitive.Root;\n\nconst TooltipTrigger = TooltipPrimitive.Trigger;\n\nconst TooltipContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, sideOffset = 4, ...props }, ref) => (\n \n));\nTooltipContent.displayName = TooltipPrimitive.Content.displayName;\n\nexport { Tooltip, TooltipTrigger, TooltipContent, TooltipProvider };\n","import React from 'react';\nimport { Slot } from '@radix-ui/react-slot';\nimport { VariantProps, cva } from 'class-variance-authority';\nimport { PanelLeft } from 'lucide-react';\n\nimport { Button } from '@/components/shadcn-ui/button';\nimport { Input } from '@/components/shadcn-ui/input';\nimport { Separator } from '@/components/shadcn-ui/separator';\nimport { Skeleton } from '@/components/shadcn-ui/skeleton';\nimport {\n Tooltip,\n TooltipContent,\n TooltipProvider,\n TooltipTrigger,\n} from '@/components/shadcn-ui/tooltip';\nimport { cn } from '@/utils/shadcn-ui.util';\n\n/**\n * Changes from the original code from Shadcn- Removed uses of useIsMobile, Sheet, and SheetContent.\n * Also removed the parts setting COOKIES.\n */\n\nconst SIDEBAR_WIDTH = '16rem';\nconst SIDEBAR_WIDTH_ICON = '3rem';\nconst SIDEBAR_KEYBOARD_SHORTCUT = 'b';\n\ntype SidebarContextProps = {\n state: 'expanded' | 'collapsed';\n open: boolean;\n setOpen: (open: boolean) => void;\n toggleSidebar: () => void;\n};\n\nconst SidebarContext = React.createContext(undefined);\n\nfunction useSidebar() {\n const context = React.useContext(SidebarContext);\n if (!context) {\n throw new Error('useSidebar must be used within a SidebarProvider.');\n }\n\n return context;\n}\n\nconst SidebarProvider = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & {\n defaultOpen?: boolean;\n open?: boolean;\n onOpenChange?: (open: boolean) => void;\n }\n>(\n (\n {\n defaultOpen = true,\n open: openProp,\n onOpenChange: setOpenProp,\n className,\n style,\n children,\n ...props\n },\n ref,\n ) => {\n // This is the internal state of the sidebar.\n // We use openProp and setOpenProp for control from outside the component.\n const [_open, _setOpen] = React.useState(defaultOpen);\n const isOpen = openProp ?? _open;\n const setOpen = React.useCallback(\n (value: boolean | ((value: boolean) => boolean)) => {\n const openState = typeof value === 'function' ? value(isOpen) : value;\n if (setOpenProp) {\n setOpenProp(openState);\n } else {\n _setOpen(openState);\n }\n },\n [setOpenProp, isOpen],\n );\n\n // Helper to toggle the sidebar.\n const toggleSidebar = React.useCallback(() => {\n return setOpen((open) => !open);\n }, [setOpen]);\n\n // Adds a keyboard shortcut to toggle the sidebar.\n React.useEffect(() => {\n const handleKeyDown = (event: KeyboardEvent) => {\n if (event.key === SIDEBAR_KEYBOARD_SHORTCUT && (event.metaKey || event.ctrlKey)) {\n event.preventDefault();\n toggleSidebar();\n }\n };\n\n window.addEventListener('keydown', handleKeyDown);\n return () => window.removeEventListener('keydown', handleKeyDown);\n }, [toggleSidebar]);\n\n // We add a state so that we can do data-state=\"expanded\" or \"collapsed\".\n // This makes it easier to style the sidebar with Tailwind classes.\n const state = isOpen ? 'expanded' : 'collapsed';\n\n const contextValue = React.useMemo(\n () => ({\n state,\n open: isOpen,\n setOpen,\n toggleSidebar,\n }),\n [state, isOpen, setOpen, toggleSidebar],\n );\n\n return (\n \n \n \n {children}\n
    \n \n \n );\n },\n);\nSidebarProvider.displayName = 'SidebarProvider';\n\nconst Sidebar = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & {\n side?: 'left' | 'right';\n variant?: 'sidebar' | 'floating' | 'inset';\n collapsible?: 'offcanvas' | 'icon' | 'none';\n }\n>(\n (\n {\n side = 'left',\n variant = 'sidebar',\n collapsible = 'offcanvas',\n className,\n children,\n ...props\n },\n ref,\n ) => {\n const { state } = useSidebar();\n\n if (collapsible === 'none') {\n return (\n \n {children}\n
    \n );\n }\n\n return (\n \n {/* This is what handles the sidebar gap on desktop */}\n \n \n \n {children}\n
    \n
    \n
    \n );\n },\n);\nSidebar.displayName = 'Sidebar';\n\nconst SidebarTrigger = React.forwardRef<\n React.ElementRef,\n React.ComponentProps\n>(({ className, onClick, ...props }, ref) => {\n const { toggleSidebar } = useSidebar();\n\n return (\n {\n onClick?.(event);\n toggleSidebar();\n }}\n {...props}\n >\n \n Toggle Sidebar\n \n );\n});\nSidebarTrigger.displayName = 'SidebarTrigger';\n\nconst SidebarRail = React.forwardRef>(\n ({ className, ...props }, ref) => {\n const { toggleSidebar } = useSidebar();\n\n return (\n \n );\n },\n);\nSidebarRail.displayName = 'SidebarRail';\n\nconst SidebarInset = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarInset.displayName = 'SidebarInset';\n\nconst SidebarInput = React.forwardRef<\n React.ElementRef,\n React.ComponentProps\n>(({ className, ...props }, ref) => {\n return (\n \n );\n});\nSidebarInput.displayName = 'SidebarInput';\n\nconst SidebarHeader = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarHeader.displayName = 'SidebarHeader';\n\nconst SidebarFooter = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarFooter.displayName = 'SidebarFooter';\n\nconst SidebarSeparator = React.forwardRef<\n React.ElementRef,\n React.ComponentProps\n>(({ className, ...props }, ref) => {\n return (\n \n );\n});\nSidebarSeparator.displayName = 'SidebarSeparator';\n\nconst SidebarContent = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarContent.displayName = 'SidebarContent';\n\nconst SidebarGroup = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarGroup.displayName = 'SidebarGroup';\n\nconst SidebarGroupLabel = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & { asChild?: boolean }\n>(({ className, asChild = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'div';\n\n return (\n svg]:tw-size-4 [&>svg]:tw-shrink-0',\n 'group-data-[collapsible=icon]:tw--mt-8 group-data-[collapsible=icon]:tw-opacity-0',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarGroupLabel.displayName = 'SidebarGroupLabel';\n\nconst SidebarGroupAction = React.forwardRef<\n HTMLButtonElement,\n React.ComponentProps<'button'> & { asChild?: boolean }\n>(({ className, asChild = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'button';\n\n return (\n svg]:tw-size-4 [&>svg]:tw-shrink-0',\n // Increases the hit area of the button on mobile.\n 'after:tw-absolute after:tw--inset-2 after:md:tw-hidden',\n 'group-data-[collapsible=icon]:tw-hidden',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarGroupAction.displayName = 'SidebarGroupAction';\n\nconst SidebarGroupContent = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarGroupContent.displayName = 'SidebarGroupContent';\n\nconst SidebarMenu = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenu.displayName = 'SidebarMenu';\n\nconst SidebarMenuItem = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenuItem.displayName = 'SidebarMenuItem';\n\nconst sidebarMenuButtonVariants = cva(\n // Removed data-[active=true]:tw-bg-sidebar-accent\n 'tw-peer/menu-button tw-flex tw-w-full tw-items-center tw-gap-2 tw-overflow-hidden tw-rounded-md tw-p-2 tw-text-left tw-text-sm tw-outline-none tw-ring-sidebar-ring tw-transition-[width,height,padding] hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground focus-visible:tw-ring-2 active:tw-bg-sidebar-accent active:tw-text-sidebar-accent-foreground disabled:tw-pointer-events-none disabled:tw-opacity-50 tw-group-has-[[data-sidebar=menu-action]]/menu-item:pr-8 aria-disabled:tw-pointer-events-none aria-disabled:tw-opacity-50 data-[active=true]:tw-font-medium data-[active=true]:tw-text-sidebar-accent-foreground data-[state=open]:hover:tw-bg-sidebar-accent data-[state=open]:hover:tw-text-sidebar-accent-foreground group-data-[collapsible=icon]:tw-!size-8 group-data-[collapsible=icon]:tw-!p-2 [&>span:last-child]:tw-truncate [&>svg]:tw-size-4 [&>svg]:tw-shrink-0',\n {\n variants: {\n variant: {\n default: 'hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground',\n outline:\n 'tw-bg-background tw-shadow-[0_0_0_1px_hsl(var(--sidebar-border))] hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground hover:tw-shadow-[0_0_0_1px_hsl(var(--sidebar-accent))]',\n },\n size: {\n default: 'tw-h-8 tw-text-sm',\n sm: 'tw-h-7 tw-text-xs',\n lg: 'tw-h-12 tw-text-sm group-data-[collapsible=icon]:tw-!p-0',\n },\n },\n defaultVariants: {\n variant: 'default',\n size: 'default',\n },\n },\n);\n\nconst SidebarMenuButton = React.forwardRef<\n HTMLButtonElement,\n React.ComponentProps<'button'> & {\n asChild?: boolean;\n isActive?: boolean;\n tooltip?: string | React.ComponentProps;\n } & VariantProps\n>(\n (\n {\n asChild = false,\n isActive = false,\n variant = 'default',\n size = 'default',\n tooltip,\n className,\n ...props\n },\n ref,\n ) => {\n const Comp = asChild ? Slot : 'button';\n const { state } = useSidebar();\n\n const button = (\n \n );\n\n if (!tooltip) {\n return button;\n }\n\n if (typeof tooltip === 'string') {\n // eslint-disable-next-line no-param-reassign\n tooltip = {\n children: tooltip,\n };\n }\n\n return (\n \n {button}\n \n );\n },\n);\nSidebarMenuButton.displayName = 'SidebarMenuButton';\n\nconst SidebarMenuAction = React.forwardRef<\n HTMLButtonElement,\n React.ComponentProps<'button'> & {\n asChild?: boolean;\n showOnHover?: boolean;\n }\n>(({ className, asChild = false, showOnHover = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'button';\n\n return (\n svg]:tw-size-4 [&>svg]:tw-shrink-0',\n // Increases the hit area of the button on mobile.\n 'after:tw-absolute after:tw--inset-2 after:md:tw-hidden',\n 'tw-peer-data-[size=sm]/menu-button:top-1',\n 'tw-peer-data-[size=default]/menu-button:top-1.5',\n 'tw-peer-data-[size=lg]/menu-button:top-2.5',\n 'group-data-[collapsible=icon]:tw-hidden',\n showOnHover &&\n 'tw-group-focus-within/menu-item:opacity-100 tw-group-hover/menu-item:opacity-100 tw-peer-data-[active=true]/menu-button:text-sidebar-accent-foreground data-[state=open]:tw-opacity-100 md:tw-opacity-0',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarMenuAction.displayName = 'SidebarMenuAction';\n\nconst SidebarMenuBadge = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenuBadge.displayName = 'SidebarMenuBadge';\n\nconst SidebarMenuSkeleton = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & {\n showIcon?: boolean;\n }\n>(({ className, showIcon = false, ...props }, ref) => {\n // Random width between 50 to 90%.\n const width = React.useMemo(() => {\n return `${Math.floor(Math.random() * 40) + 50}%`;\n }, []);\n\n return (\n \n {showIcon && (\n \n )}\n \n
    \n );\n});\nSidebarMenuSkeleton.displayName = 'SidebarMenuSkeleton';\n\nconst SidebarMenuSub = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenuSub.displayName = 'SidebarMenuSub';\n\nconst SidebarMenuSubItem = React.forwardRef>(\n ({ ...props }, ref) =>
  • ,\n);\nSidebarMenuSubItem.displayName = 'SidebarMenuSubItem';\n\nconst SidebarMenuSubButton = React.forwardRef<\n HTMLAnchorElement,\n React.ComponentProps<'a'> & {\n asChild?: boolean;\n size?: 'sm' | 'md';\n isActive?: boolean;\n }\n>(({ asChild = false, size = 'md', isActive, className, ...props }, ref) => {\n const Comp = asChild ? Slot : 'a';\n\n return (\n span:last-child]:tw-truncate [&>svg]:tw-size-4 [&>svg]:tw-shrink-0 [&>svg]:tw-text-sidebar-accent-foreground',\n 'data-[active=true]:tw-bg-sidebar-accent data-[active=true]:tw-text-sidebar-accent-foreground',\n size === 'sm' && 'tw-text-xs',\n size === 'md' && 'tw-text-sm',\n 'group-data-[collapsible=icon]:tw-hidden',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarMenuSubButton.displayName = 'SidebarMenuSubButton';\n\nexport {\n Sidebar,\n SidebarContent,\n SidebarFooter,\n SidebarGroup,\n SidebarGroupAction,\n SidebarGroupContent,\n SidebarGroupLabel,\n SidebarHeader,\n SidebarInput,\n SidebarInset,\n SidebarMenu,\n SidebarMenuAction,\n SidebarMenuBadge,\n SidebarMenuButton,\n SidebarMenuItem,\n SidebarMenuSkeleton,\n SidebarMenuSub,\n SidebarMenuSubButton,\n SidebarMenuSubItem,\n SidebarProvider,\n SidebarRail,\n SidebarSeparator,\n SidebarTrigger,\n useSidebar,\n};\n","import ComboBox, { ComboBoxOption } from '@/components/basics/combo-box.component';\nimport {\n Sidebar,\n SidebarContent,\n SidebarGroup,\n SidebarGroupLabel,\n SidebarGroupContent,\n SidebarMenu,\n SidebarMenuItem,\n SidebarMenuButton,\n} from '@/components/shadcn-ui/sidebar';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { useCallback } from 'react';\n\nexport type SelectedSettingsSidebarItem = {\n label: string;\n projectId?: string;\n};\n\nexport type ProjectInfo = { projectId: string; projectName: string };\n\nexport type SettingsSidebarProps = {\n /** Optional id for testing */\n id?: string;\n\n /** Extension labels from contribution */\n extensionLabels: string[];\n\n /** Project names and ids */\n projectOptions: ProjectInfo[];\n\n /** Handler for selecting a sidebar item */\n handleSelectSidebarItem: (key: string, projectId?: string) => void;\n\n /** The current selected value in the sidebar */\n selectedSidebarItem: SelectedSettingsSidebarItem;\n\n /** Label for the group of extensions setting groups */\n extensionsSidebarGroupLabel: string;\n\n /** Label for the group of projects settings */\n projectsSidebarGroupLabel: string;\n\n /** Placeholder text for the button */\n buttonPlaceholderText: string;\n};\n\nexport default function SettingsSidebar({\n id,\n extensionLabels,\n projectOptions,\n handleSelectSidebarItem,\n selectedSidebarItem,\n extensionsSidebarGroupLabel,\n projectsSidebarGroupLabel,\n buttonPlaceholderText,\n}: SettingsSidebarProps) {\n const handleSelectItem = useCallback(\n (item: string, projectId?: string) => {\n handleSelectSidebarItem(item, projectId);\n },\n [handleSelectSidebarItem],\n );\n\n const getProjectNameFromProjectId = useCallback(\n (projectId: string) => {\n const project = projectOptions.find((option) => option.projectId === projectId);\n return project ? project.projectName : projectId;\n },\n [projectOptions],\n );\n\n const getIsActive: (label: string) => boolean = useCallback(\n (label: string) => !selectedSidebarItem.projectId && label === selectedSidebarItem.label,\n [selectedSidebarItem],\n );\n\n return (\n \n \n \n \n {extensionsSidebarGroupLabel}\n \n \n \n {extensionLabels.map((label) => (\n \n handleSelectItem(label)}\n isActive={getIsActive(label)}\n >\n {label}\n \n \n ))}\n \n \n \n \n \n {projectsSidebarGroupLabel}\n \n \n option.projectId)}\n getOptionLabel={(projectId: ComboBoxOption) => {\n // This function expects a ComboBoxOption, but we know it is a string\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n return getProjectNameFromProjectId(projectId as string);\n }}\n buttonPlaceholder={buttonPlaceholderText}\n onChange={(projectId: string) => {\n const selectedProjectName = getProjectNameFromProjectId(projectId);\n handleSelectItem(selectedProjectName, projectId);\n }}\n value={selectedSidebarItem?.projectId ?? undefined}\n />\n \n \n \n \n );\n}\n","import { SidebarInset, SidebarProvider } from '@/components/shadcn-ui/sidebar';\nimport { PropsWithChildren } from 'react';\nimport SearchBar from '@/components/basics/search-bar.component';\nimport SettingsSidebar, { SettingsSidebarProps } from './settings-sidebar.component';\n\nexport type SettingsSidebarContentSearchProps = SettingsSidebarProps &\n PropsWithChildren & {\n /** Optional id for testing */\n id?: string;\n\n /** Handler to run when the value of the search bar changes */\n onSearch: (searchQuery: string) => void;\n };\n\nexport default function SettingsSidebarContentSearch({\n id,\n extensionLabels,\n projectOptions,\n children,\n handleSelectSidebarItem,\n selectedSidebarItem,\n onSearch,\n extensionsSidebarGroupLabel,\n projectsSidebarGroupLabel,\n buttonPlaceholderText,\n}: SettingsSidebarContentSearchProps) {\n return (\n
    \n
    \n \n
    \n \n \n {children}\n \n
    \n );\n}\n","import { Button } from '@/components/shadcn-ui/button';\nimport {\n Select,\n SelectContent,\n SelectGroup,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\nimport {\n Table,\n TableBody,\n TableCell,\n TableHead,\n TableHeader,\n TableRow,\n} from '@/components/shadcn-ui/table';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Canon } from '@sillsdev/scripture';\nimport {\n Cell,\n ColumnDef,\n flexRender,\n getCoreRowModel,\n getExpandedRowModel,\n getGroupedRowModel,\n getSortedRowModel,\n GroupingState,\n Row,\n RowSelectionState,\n SortingState,\n useReactTable,\n} from '@tanstack/react-table';\nimport '@/components/advanced/scripture-results-viewer/scripture-results-viewer.component.css';\nimport {\n compareScrRefs,\n formatScrRef,\n ScriptureSelection,\n scrRefToBBBCCCVVV,\n} from 'platform-bible-utils';\nimport { MouseEvent, useEffect, useMemo, useState } from 'react';\nimport { ChevronDown, ChevronLeft, ChevronRight } from 'lucide-react';\n\n/**\n * Information (e.g., a checking error or some other type of \"transient\" annotation) about something\n * noteworthy at a specific place in an instance of the Scriptures.\n */\nexport type ScriptureItemDetail = ScriptureSelection & {\n /**\n * Text of the error, note, etc. In the future, we might want to support something more than just\n * text so that a JSX element could be provided with a link or some other controls related to the\n * issue being reported.\n */\n detail: string;\n};\n\n/**\n * A uniquely identifiable source of results that can be displayed in the ScriptureResultsViewer.\n * Generally, the source will be a particular Scripture check, but there may be other types of\n * sources.\n */\nexport type ResultsSource = {\n /**\n * Uniquely identifies the source.\n *\n * @type {string}\n */\n id: string;\n\n /**\n * Name (potentially localized) of the source, suitable for display in the UI.\n *\n * @type {string}\n */\n displayName: string;\n};\n\nexport type ScriptureSrcItemDetail = ScriptureItemDetail & {\n /** Source/type of detail. Can be used for grouping. */\n source: ResultsSource;\n};\n\n/**\n * Represents a set of results keyed by Scripture reference. Generally, the source will be a\n * particular Scripture check, but this type also allows for other types of uniquely identifiable\n * sources.\n */\nexport type ResultsSet = {\n /**\n * The backing source associated with this set of results.\n *\n * @type {ResultsSource}\n */\n source: ResultsSource;\n\n /**\n * Array of Scripture item details (messages keyed by Scripture reference).\n *\n * @type {ScriptureItemDetail[]}\n */\n data: ScriptureItemDetail[];\n};\n\nconst scrBookColId = 'scrBook';\nconst scrRefColId = 'scrRef';\nconst typeColId = 'source';\nconst detailsColId = 'details';\n\nconst defaultScrRefColumnName = 'Scripture Reference';\nconst defaultScrBookGroupName = 'Scripture Book';\nconst defaultTypeColumnName = 'Type';\nconst defaultDetailsColumnName = 'Details';\n\nexport type ScriptureResultsViewerColumnInfo = {\n /** Optional header to display for the Reference column. Default value: 'Scripture Reference'. */\n scriptureReferenceColumnName?: string;\n\n /** Optional text to display to refer to the Scripture book group. Default value: 'Scripture Book'. */\n scriptureBookGroupName?: string;\n\n /** Optional header to display for the Type column. Default value: 'Type'. */\n typeColumnName?: string;\n\n /** Optional header to display for the Details column. Default value: 'Details' */\n detailsColumnName?: string;\n};\n\nexport type ScriptureResultsViewerProps = ScriptureResultsViewerColumnInfo & {\n /** Groups of ScriptureItemDetail objects from particular sources (e.g., Scripture checks) */\n sources: ResultsSet[];\n\n /** Flag indicating whether to display column headers. Default is false. */\n showColumnHeaders?: boolean;\n\n /** Flag indicating whether to display source column. Default is false. */\n showSourceColumn?: boolean;\n\n /** Callback function to notify when a row is selected */\n onRowSelected?: (selectedRow: ScriptureSrcItemDetail | undefined) => void;\n\n /** Text direction ltr or rtl */\n direction?: 'ltr' | 'rtl';\n};\n\nfunction getColumns(\n colInfo?: ScriptureResultsViewerColumnInfo,\n showSourceColumn?: boolean,\n): ColumnDef[] {\n const showSrcCol = showSourceColumn ?? false;\n return [\n {\n accessorFn: (row) =>\n `${Canon.bookNumberToId(row.start.bookNum)} ${row.start.chapterNum}:${row.start.verseNum}`,\n id: scrBookColId,\n header: colInfo?.scriptureReferenceColumnName ?? defaultScrRefColumnName,\n cell: (info) => {\n const row = info.row.original;\n if (info.row.getIsGrouped()) {\n return Canon.bookNumberToEnglishName(row.start.bookNum);\n }\n return info.row.groupingColumnId === scrBookColId ? formatScrRef(row.start) : undefined;\n },\n getGroupingValue: (row) => row.start.bookNum,\n sortingFn: (a, b) => {\n return compareScrRefs(a.original.start, b.original.start);\n },\n enableGrouping: true,\n },\n {\n accessorFn: (row) => formatScrRef(row.start),\n id: scrRefColId,\n header: undefined,\n cell: (info) => {\n const row = info.row.original;\n return info.row.getIsGrouped() ? undefined : formatScrRef(row.start);\n },\n sortingFn: (a, b) => {\n return compareScrRefs(a.original.start, b.original.start);\n },\n enableGrouping: false,\n },\n {\n accessorFn: (row) => row.source.displayName,\n id: typeColId,\n header: showSrcCol ? (colInfo?.typeColumnName ?? defaultTypeColumnName) : undefined,\n cell: (info) => (showSrcCol || info.row.getIsGrouped() ? info.getValue() : undefined),\n getGroupingValue: (row) => row.source.id,\n sortingFn: (a, b) =>\n a.original.source.displayName.localeCompare(b.original.source.displayName),\n enableGrouping: true,\n },\n {\n accessorFn: (row) => row.detail,\n id: detailsColId,\n header: colInfo?.detailsColumnName ?? defaultDetailsColumnName,\n cell: (info) => info.getValue(),\n enableGrouping: false,\n },\n ];\n}\n\nconst toRefOrRange = (scriptureSelection: ScriptureSelection) => {\n if (!('offset' in scriptureSelection.start))\n throw new Error('No offset available in range start');\n if (scriptureSelection.end && !('offset' in scriptureSelection.end))\n throw new Error('No offset available in range end');\n const { offset: offsetStart } = scriptureSelection.start;\n let offsetEnd: number = 0;\n if (scriptureSelection.end) ({ offset: offsetEnd } = scriptureSelection.end);\n if (\n !scriptureSelection.end ||\n compareScrRefs(scriptureSelection.start, scriptureSelection.end) === 0\n )\n return `${scrRefToBBBCCCVVV(scriptureSelection.start)}+${offsetStart}`;\n return `${scrRefToBBBCCCVVV(scriptureSelection.start)}+${offsetStart}-${scrRefToBBBCCCVVV(scriptureSelection.end)}+${offsetEnd}`;\n};\n\nconst getRowKey = (row: ScriptureSrcItemDetail) =>\n `${toRefOrRange({ start: row.start, end: row.end })} ${row.source.displayName} ${row.detail}`;\n\n/**\n * Component to display a combined list of detailed items from one or more sources, where the items\n * are keyed primarily by Scripture reference. This is particularly useful for displaying a list of\n * results from Scripture checks, but more generally could be used to display any \"results\" from any\n * source(s). The component allows for grouping by Scripture book, source, or both. By default, it\n * displays somewhat \"tree-like\" which allows it to be more horizontally compact and intuitive. But\n * it also has the option of displaying as a traditional table with column headings (with or without\n * the source column showing).\n */\nexport default function ScriptureResultsViewer({\n sources,\n showColumnHeaders = false,\n showSourceColumn = false,\n scriptureReferenceColumnName,\n scriptureBookGroupName,\n typeColumnName,\n detailsColumnName,\n onRowSelected,\n direction = 'ltr',\n}: ScriptureResultsViewerProps) {\n const [grouping, setGrouping] = useState([]);\n const [sorting, setSorting] = useState([{ id: scrBookColId, desc: false }]);\n const [rowSelection, setRowSelection] = useState({});\n\n const scriptureResults = useMemo(\n () =>\n sources.flatMap((source) => {\n return source.data.map((item) => ({\n ...item,\n source: source.source,\n }));\n }),\n [sources],\n );\n\n const columns = useMemo(\n () =>\n getColumns(\n {\n scriptureReferenceColumnName,\n typeColumnName,\n detailsColumnName,\n },\n showSourceColumn,\n ),\n [scriptureReferenceColumnName, typeColumnName, detailsColumnName, showSourceColumn],\n );\n\n useEffect(() => {\n // Ensure sorting is applied correctly when grouped by type\n if (grouping.includes(typeColId)) {\n setSorting([\n { id: typeColId, desc: false },\n { id: scrBookColId, desc: false },\n ]);\n } else {\n setSorting([{ id: scrBookColId, desc: false }]);\n }\n }, [grouping]);\n\n const table = useReactTable({\n data: scriptureResults,\n columns,\n state: {\n grouping,\n sorting,\n rowSelection,\n },\n onGroupingChange: setGrouping,\n onSortingChange: setSorting,\n onRowSelectionChange: setRowSelection,\n getExpandedRowModel: getExpandedRowModel(),\n getGroupedRowModel: getGroupedRowModel(),\n getCoreRowModel: getCoreRowModel(),\n getSortedRowModel: getSortedRowModel(),\n getRowId: getRowKey,\n autoResetExpanded: false,\n enableMultiRowSelection: false,\n enableSubRowSelection: false,\n });\n\n useEffect(() => {\n if (onRowSelected) {\n const selectedRows = table.getSelectedRowModel().rowsById;\n const keys = Object.keys(selectedRows);\n if (keys.length === 1) {\n const selectedRow = scriptureResults.find((row) => getRowKey(row) === keys[0]) || undefined;\n if (selectedRow) onRowSelected(selectedRow);\n }\n }\n }, [rowSelection, scriptureResults, onRowSelected, table]);\n\n // Define possible grouping options\n const scrBookGroupName = scriptureBookGroupName ?? defaultScrBookGroupName;\n const typeGroupName = typeColumnName ?? defaultTypeColumnName;\n\n const groupingOptions = [\n { label: 'No Grouping', value: [] },\n { label: `Group by ${scrBookGroupName}`, value: [scrBookColId] },\n { label: `Group by ${typeGroupName}`, value: [typeColId] },\n {\n label: `Group by ${scrBookGroupName} and ${typeGroupName}`,\n value: [scrBookColId, typeColId],\n },\n {\n label: `Group by ${typeGroupName} and ${scrBookGroupName}`,\n value: [typeColId, scrBookColId],\n },\n ];\n\n const handleSelectChange = (selectedGrouping: string) => {\n setGrouping(JSON.parse(selectedGrouping));\n };\n\n const handleRowClick = (row: Row, event: MouseEvent) => {\n if (!row.getIsGrouped() && !row.getIsSelected()) {\n row.getToggleSelectedHandler()(event);\n }\n };\n\n const getEvenOrOddBandingStyle = (row: Row, index: number) => {\n if (row.getIsGrouped()) return '';\n // UX has now said they don't think they want banding. I'm leaving in the code to\n // set even and odd styles, but there's nothing in the CSS to style them differently.\n // The \"even\" style used to also have tw-bg-neutral-300 (along with even) to create\n // a visual banding effect. That could be added back in if UX changes the decision.\n return cn('banded-row', index % 2 === 0 ? 'even' : 'odd');\n };\n\n const getIndent = (\n groupingState: GroupingState,\n row: Row,\n cell: Cell,\n ) => {\n if (groupingState?.length === 0 || row.depth < cell.column.getGroupedIndex()) return undefined;\n if (row.getIsGrouped()) {\n switch (row.depth) {\n case 1:\n return 'tw-ps-4';\n default:\n return undefined;\n }\n }\n switch (row.depth) {\n case 1:\n return 'tw-ps-8';\n case 2:\n return 'tw-ps-12';\n default:\n return undefined;\n }\n };\n\n return (\n
    \n {!showColumnHeaders && (\n {\n handleSelectChange(value);\n }}\n >\n \n \n \n \n \n {groupingOptions.map((option) => (\n \n {option.label}\n \n ))}\n \n \n \n )}\n \n {showColumnHeaders && (\n \n {table.getHeaderGroups().map((headerGroup) => (\n \n {headerGroup.headers\n .filter((h) => h.column.columnDef.header)\n .map((header) => (\n /* For sticky column headers to work, we probably need to change the default definition of the shadcn Table component. See https://github.com/shadcn-ui/ui/issues/1151 */\n \n {header.isPlaceholder ? undefined : (\n
    \n {header.column.getCanGroup() ? (\n \n {header.column.getIsGrouped() ? `🛑` : `👊 `}\n \n ) : undefined}{' '}\n {flexRender(header.column.columnDef.header, header.getContext())}\n
    \n )}\n
    \n ))}\n
    \n ))}\n
    \n )}\n \n {table.getRowModel().rows.map((row, rowIndex) => {\n return (\n handleRowClick(row, event)}\n >\n {row.getVisibleCells().map((cell) => {\n if (\n cell.getIsPlaceholder() ||\n (cell.column.columnDef.enableGrouping &&\n !cell.getIsGrouped() &&\n (cell.column.columnDef.id !== typeColId || !showSourceColumn))\n )\n return undefined;\n return (\n \n {(() => {\n if (cell.getIsGrouped()) {\n return (\n \n {row.getIsExpanded() && }\n {!row.getIsExpanded() &&\n (direction === 'ltr' ? : )}{' '}\n {flexRender(cell.column.columnDef.cell, cell.getContext())} (\n {row.subRows.length})\n \n );\n }\n\n // if (cell.getIsAggregated()) {\n // flexRender(\n // cell.column.columnDef.aggregatedCell ?? cell.column.columnDef.cell,\n // cell.getContext(),\n // );\n // }\n\n return flexRender(cell.column.columnDef.cell, cell.getContext());\n })()}\n \n );\n })}\n \n );\n })}\n \n
    \n
    \n );\n}\n","import {\n getLocalizeKeyForScrollGroupId,\n LanguageStrings,\n ScrollGroupId,\n} from 'platform-bible-utils';\nimport {\n Select,\n SelectContent,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\n\nconst DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS = {\n [getLocalizeKeyForScrollGroupId('undefined')]: 'Ø',\n [getLocalizeKeyForScrollGroupId(0)]: 'A',\n [getLocalizeKeyForScrollGroupId(1)]: 'B',\n [getLocalizeKeyForScrollGroupId(2)]: 'C',\n [getLocalizeKeyForScrollGroupId(3)]: 'D',\n [getLocalizeKeyForScrollGroupId(4)]: 'E',\n [getLocalizeKeyForScrollGroupId(5)]: 'F',\n [getLocalizeKeyForScrollGroupId(6)]: 'G',\n [getLocalizeKeyForScrollGroupId(7)]: 'H',\n [getLocalizeKeyForScrollGroupId(8)]: 'I',\n [getLocalizeKeyForScrollGroupId(9)]: 'J',\n [getLocalizeKeyForScrollGroupId(10)]: 'K',\n [getLocalizeKeyForScrollGroupId(11)]: 'L',\n [getLocalizeKeyForScrollGroupId(12)]: 'M',\n [getLocalizeKeyForScrollGroupId(13)]: 'N',\n [getLocalizeKeyForScrollGroupId(14)]: 'O',\n [getLocalizeKeyForScrollGroupId(15)]: 'P',\n [getLocalizeKeyForScrollGroupId(16)]: 'Q',\n [getLocalizeKeyForScrollGroupId(17)]: 'R',\n [getLocalizeKeyForScrollGroupId(18)]: 'S',\n [getLocalizeKeyForScrollGroupId(19)]: 'T',\n [getLocalizeKeyForScrollGroupId(20)]: 'U',\n [getLocalizeKeyForScrollGroupId(21)]: 'V',\n [getLocalizeKeyForScrollGroupId(22)]: 'W',\n [getLocalizeKeyForScrollGroupId(23)]: 'X',\n [getLocalizeKeyForScrollGroupId(24)]: 'Y',\n [getLocalizeKeyForScrollGroupId(25)]: 'Z',\n};\n\nexport type ScrollGroupSelectorProps = {\n /**\n * List of scroll group ids to show to the user. Either a {@link ScrollGroupId} or `undefined` for\n * no scroll group\n */\n availableScrollGroupIds: (ScrollGroupId | undefined)[];\n /** Currently selected scroll group id. `undefined` for no scroll group */\n scrollGroupId: ScrollGroupId | undefined;\n /** Callback function run when the user tries to change the scroll group id */\n onChangeScrollGroupId: (newScrollGroupId: ScrollGroupId | undefined) => void;\n /**\n * Localized strings to use for displaying scroll group ids. Must be an object whose keys are\n * `getLocalizeKeyForScrollGroupId(scrollGroupId)` for all scroll group ids (and `undefined` if\n * included) in {@link ScrollGroupSelectorProps.availableScrollGroupIds} and whose values are the\n * localized strings to use for those scroll group ids.\n *\n * Defaults to English localizations of English alphabet for scroll groups 0-25 (e.g. 0 is A) and\n * Ø for `undefined`. Will fill in any that are not provided with these English localizations.\n * Also, if any values match the keys, the English localization will be used. This is useful in\n * case you want to pass in a temporary version of the localized strings while your localized\n * strings load.\n *\n * @example\n *\n * ```typescript\n * const myScrollGroupIdLocalizedStrings = {\n * [getLocalizeKeyForScrollGroupId('undefined')]: 'Ø',\n * [getLocalizeKeyForScrollGroupId(0)]: 'A',\n * [getLocalizeKeyForScrollGroupId(1)]: 'B',\n * [getLocalizeKeyForScrollGroupId(2)]: 'C',\n * [getLocalizeKeyForScrollGroupId(3)]: 'D',\n * [getLocalizeKeyForScrollGroupId(4)]: 'E',\n * };\n * ```\n *\n * @example\n *\n * ```tsx\n * const availableScrollGroupIds = [undefined, 0, 1, 2, 3, 4];\n *\n * const localizeKeys = getLocalizeKeysForScrollGroupIds();\n *\n * const [localizedStrings] = useLocalizedStrings(localizeKeys);\n *\n * ...\n *\n * \n * ```\n */\n localizedStrings?: LanguageStrings;\n};\n\n/** Selector component for choosing a scroll group */\nexport default function ScrollGroupSelector({\n availableScrollGroupIds,\n scrollGroupId,\n onChangeScrollGroupId,\n localizedStrings = {},\n}: ScrollGroupSelectorProps) {\n const localizedStringsDefaulted = {\n ...DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS,\n ...Object.fromEntries(\n Object.entries(localizedStrings).map(\n ([localizedStringKey, localizedStringValue]: [string, string]) => [\n localizedStringKey,\n localizedStringKey === localizedStringValue &&\n localizedStringKey in DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS\n ? DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS[localizedStringKey]\n : localizedStringValue,\n ],\n ),\n ),\n };\n return (\n \n onChangeScrollGroupId(\n newScrollGroupString === 'undefined' ? undefined : parseInt(newScrollGroupString, 10),\n )\n }\n >\n \n \n \n \n {availableScrollGroupIds.map((scrollGroupOptionId) => (\n \n {localizedStringsDefaulted[getLocalizeKeyForScrollGroupId(scrollGroupOptionId)]}\n \n ))}\n \n \n );\n}\n","import { PropsWithChildren } from 'react';\nimport { Separator } from '@/components/shadcn-ui/separator';\n\n/** Props for the SettingsList component, currently just children */\ntype SettingsListProps = PropsWithChildren;\n\n/**\n * SettingsList component is a wrapper for list items. Rendered with a formatted div\n *\n * @param children To populate the list with\n * @returns Formatted div encompassing the children\n */\nexport function SettingsList({ children }: SettingsListProps) {\n return
    {children}
    ;\n}\n\n/** Props for SettingsListItem component */\ntype SettingsListItemProps = PropsWithChildren & {\n /** Primary text of the list item */\n primary: string;\n\n /** Optional text of the list item */\n secondary?: string | undefined;\n\n /** Optional boolean to display a message if the children aren't loaded yet. Defaults to false */\n isLoading?: boolean;\n\n /** Optional message to display if isLoading */\n loadingMessage?: string;\n};\n\n/**\n * SettingsListItem component is a common list item. Rendered with a formatted div\n *\n * @param primary Primary text of the list item\n * @param secondary Optional secondary text of the list item\n * @param isLoading Optional, to display a message if the action component isn't generated yet,\n * defaults to false\n * @param children The action component(s) to provide for this item\n * @param loadingMessage Optional, message to display if isLoading\n * @returns Formatted div encompassing the list item content\n */\nexport function SettingsListItem({\n primary,\n secondary,\n children,\n isLoading = false,\n loadingMessage,\n}: SettingsListItemProps) {\n return (\n
    \n
    \n

    {primary}

    \n

    \n {secondary}\n

    \n
    \n\n {isLoading ? (\n

    {loadingMessage}

    \n ) : (\n
    {children}
    \n )}\n
    \n );\n}\n\n/** Props for SettingsListHeader component */\ntype SettingsListHeaderProps = {\n /** The primary text of the list header */\n primary: string;\n\n /** Optional secondary text of the list header */\n secondary?: string | undefined;\n\n /** Optional boolean to include a separator underneath the secondary text. Defaults to false */\n includeSeparator?: boolean;\n};\n\n/**\n * SettingsListHeader component displays text above the list\n *\n * @param primary The primary text of the list header\n * @param secondary Optional secondary text of the list header\n * @param includeSeparator Optional boolean to include a separator underneath the secondary text.\n * Defaults to false\n * @returns Formatted div with list header content\n */\nexport function SettingsListHeader({\n primary,\n secondary,\n includeSeparator = false,\n}: SettingsListHeaderProps) {\n return (\n
    \n
    \n

    {primary}

    \n

    {secondary}

    \n
    \n {includeSeparator ? : ''}\n
    \n );\n}\n","import Checkbox from '@/components/shadcn-ui/checkbox';\nimport { Label } from '@/components/shadcn-ui/label';\n\nexport type ChecklistProps = {\n /** Optional string representing the id attribute of the Checklist */\n id?: string;\n /** Optional string representing CSS class name(s) for styling */\n className?: string;\n /** Array of strings representing the checkable items */\n listItems: string[];\n /** Array of strings representing the checked items */\n selectedListItems: string[];\n /**\n * Function that is called when a checkbox item is selected or deselected\n *\n * @param item The string description for this item\n * @param selected True if selected, false if not selected\n */\n handleSelectListItem: (item: string, selected: boolean) => void;\n\n /**\n * Optional function creates a label for a provided checkable item\n *\n * @param item The item for which a label is to be created\n * @returns A string representing the label text for the checkbox associated with that item\n */\n createLabel?: (item: string) => string;\n};\n\n/** Renders a list of checkboxes. Each checkbox corresponds to an item from the `listItems` array. */\nexport default function Checklist({\n id,\n className,\n listItems,\n selectedListItems,\n handleSelectListItem,\n createLabel,\n}: ChecklistProps) {\n return (\n
    \n {listItems.map((item) => (\n
    \n handleSelectListItem(item, value)}\n />\n \n
    \n ))}\n
    \n );\n}\n","function _interopRequireDefault(obj) {\n return obj && obj.__esModule ? obj : {\n \"default\": obj\n };\n}\nmodule.exports = _interopRequireDefault, module.exports.__esModule = true, module.exports[\"default\"] = module.exports;","export default function chainPropTypes(propType1, propType2) {\n if (process.env.NODE_ENV === 'production') {\n return () => null;\n }\n return function validate(...args) {\n return propType1(...args) || propType2(...args);\n };\n}","export default function _extends() {\n _extends = Object.assign ? Object.assign.bind() : function (target) {\n for (var i = 1; i < arguments.length; i++) {\n var source = arguments[i];\n for (var key in source) {\n if (Object.prototype.hasOwnProperty.call(source, key)) {\n target[key] = source[key];\n }\n }\n }\n return target;\n };\n return _extends.apply(this, arguments);\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\n// https://github.com/sindresorhus/is-plain-obj/blob/main/index.js\nexport function isPlainObject(item) {\n if (typeof item !== 'object' || item === null) {\n return false;\n }\n const prototype = Object.getPrototypeOf(item);\n return (prototype === null || prototype === Object.prototype || Object.getPrototypeOf(prototype) === null) && !(Symbol.toStringTag in item) && !(Symbol.iterator in item);\n}\nfunction deepClone(source) {\n if (!isPlainObject(source)) {\n return source;\n }\n const output = {};\n Object.keys(source).forEach(key => {\n output[key] = deepClone(source[key]);\n });\n return output;\n}\nexport default function deepmerge(target, source, options = {\n clone: true\n}) {\n const output = options.clone ? _extends({}, target) : target;\n if (isPlainObject(target) && isPlainObject(source)) {\n Object.keys(source).forEach(key => {\n // Avoid prototype pollution\n if (key === '__proto__') {\n return;\n }\n if (isPlainObject(source[key]) && key in target && isPlainObject(target[key])) {\n // Since `output` is a clone of `target` and we have narrowed `target` in this block we can cast to the same type.\n output[key] = deepmerge(target[key], source[key], options);\n } else if (options.clone) {\n output[key] = isPlainObject(source[key]) ? deepClone(source[key]) : source[key];\n } else {\n output[key] = source[key];\n }\n });\n }\n return output;\n}","/** @license React v16.13.1\n * react-is.production.min.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';var b=\"function\"===typeof Symbol&&Symbol.for,c=b?Symbol.for(\"react.element\"):60103,d=b?Symbol.for(\"react.portal\"):60106,e=b?Symbol.for(\"react.fragment\"):60107,f=b?Symbol.for(\"react.strict_mode\"):60108,g=b?Symbol.for(\"react.profiler\"):60114,h=b?Symbol.for(\"react.provider\"):60109,k=b?Symbol.for(\"react.context\"):60110,l=b?Symbol.for(\"react.async_mode\"):60111,m=b?Symbol.for(\"react.concurrent_mode\"):60111,n=b?Symbol.for(\"react.forward_ref\"):60112,p=b?Symbol.for(\"react.suspense\"):60113,q=b?\nSymbol.for(\"react.suspense_list\"):60120,r=b?Symbol.for(\"react.memo\"):60115,t=b?Symbol.for(\"react.lazy\"):60116,v=b?Symbol.for(\"react.block\"):60121,w=b?Symbol.for(\"react.fundamental\"):60117,x=b?Symbol.for(\"react.responder\"):60118,y=b?Symbol.for(\"react.scope\"):60119;\nfunction z(a){if(\"object\"===typeof a&&null!==a){var u=a.$$typeof;switch(u){case c:switch(a=a.type,a){case l:case m:case e:case g:case f:case p:return a;default:switch(a=a&&a.$$typeof,a){case k:case n:case t:case r:case h:return a;default:return u}}case d:return u}}}function A(a){return z(a)===m}exports.AsyncMode=l;exports.ConcurrentMode=m;exports.ContextConsumer=k;exports.ContextProvider=h;exports.Element=c;exports.ForwardRef=n;exports.Fragment=e;exports.Lazy=t;exports.Memo=r;exports.Portal=d;\nexports.Profiler=g;exports.StrictMode=f;exports.Suspense=p;exports.isAsyncMode=function(a){return A(a)||z(a)===l};exports.isConcurrentMode=A;exports.isContextConsumer=function(a){return z(a)===k};exports.isContextProvider=function(a){return z(a)===h};exports.isElement=function(a){return\"object\"===typeof a&&null!==a&&a.$$typeof===c};exports.isForwardRef=function(a){return z(a)===n};exports.isFragment=function(a){return z(a)===e};exports.isLazy=function(a){return z(a)===t};\nexports.isMemo=function(a){return z(a)===r};exports.isPortal=function(a){return z(a)===d};exports.isProfiler=function(a){return z(a)===g};exports.isStrictMode=function(a){return z(a)===f};exports.isSuspense=function(a){return z(a)===p};\nexports.isValidElementType=function(a){return\"string\"===typeof a||\"function\"===typeof a||a===e||a===m||a===g||a===f||a===p||a===q||\"object\"===typeof a&&null!==a&&(a.$$typeof===t||a.$$typeof===r||a.$$typeof===h||a.$$typeof===k||a.$$typeof===n||a.$$typeof===w||a.$$typeof===x||a.$$typeof===y||a.$$typeof===v)};exports.typeOf=z;\n","/** @license React v16.13.1\n * react-is.development.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\n\n\nif (process.env.NODE_ENV !== \"production\") {\n (function() {\n'use strict';\n\n// The Symbol used to tag the ReactElement-like types. If there is no native Symbol\n// nor polyfill, then a plain number is used for performance.\nvar hasSymbol = typeof Symbol === 'function' && Symbol.for;\nvar REACT_ELEMENT_TYPE = hasSymbol ? Symbol.for('react.element') : 0xeac7;\nvar REACT_PORTAL_TYPE = hasSymbol ? Symbol.for('react.portal') : 0xeaca;\nvar REACT_FRAGMENT_TYPE = hasSymbol ? Symbol.for('react.fragment') : 0xeacb;\nvar REACT_STRICT_MODE_TYPE = hasSymbol ? Symbol.for('react.strict_mode') : 0xeacc;\nvar REACT_PROFILER_TYPE = hasSymbol ? Symbol.for('react.profiler') : 0xead2;\nvar REACT_PROVIDER_TYPE = hasSymbol ? Symbol.for('react.provider') : 0xeacd;\nvar REACT_CONTEXT_TYPE = hasSymbol ? Symbol.for('react.context') : 0xeace; // TODO: We don't use AsyncMode or ConcurrentMode anymore. They were temporary\n// (unstable) APIs that have been removed. Can we remove the symbols?\n\nvar REACT_ASYNC_MODE_TYPE = hasSymbol ? Symbol.for('react.async_mode') : 0xeacf;\nvar REACT_CONCURRENT_MODE_TYPE = hasSymbol ? Symbol.for('react.concurrent_mode') : 0xeacf;\nvar REACT_FORWARD_REF_TYPE = hasSymbol ? Symbol.for('react.forward_ref') : 0xead0;\nvar REACT_SUSPENSE_TYPE = hasSymbol ? Symbol.for('react.suspense') : 0xead1;\nvar REACT_SUSPENSE_LIST_TYPE = hasSymbol ? Symbol.for('react.suspense_list') : 0xead8;\nvar REACT_MEMO_TYPE = hasSymbol ? Symbol.for('react.memo') : 0xead3;\nvar REACT_LAZY_TYPE = hasSymbol ? Symbol.for('react.lazy') : 0xead4;\nvar REACT_BLOCK_TYPE = hasSymbol ? Symbol.for('react.block') : 0xead9;\nvar REACT_FUNDAMENTAL_TYPE = hasSymbol ? Symbol.for('react.fundamental') : 0xead5;\nvar REACT_RESPONDER_TYPE = hasSymbol ? Symbol.for('react.responder') : 0xead6;\nvar REACT_SCOPE_TYPE = hasSymbol ? Symbol.for('react.scope') : 0xead7;\n\nfunction isValidElementType(type) {\n return typeof type === 'string' || typeof type === 'function' || // Note: its typeof might be other than 'symbol' or 'number' if it's a polyfill.\n type === REACT_FRAGMENT_TYPE || type === REACT_CONCURRENT_MODE_TYPE || type === REACT_PROFILER_TYPE || type === REACT_STRICT_MODE_TYPE || type === REACT_SUSPENSE_TYPE || type === REACT_SUSPENSE_LIST_TYPE || typeof type === 'object' && type !== null && (type.$$typeof === REACT_LAZY_TYPE || type.$$typeof === REACT_MEMO_TYPE || type.$$typeof === REACT_PROVIDER_TYPE || type.$$typeof === REACT_CONTEXT_TYPE || type.$$typeof === REACT_FORWARD_REF_TYPE || type.$$typeof === REACT_FUNDAMENTAL_TYPE || type.$$typeof === REACT_RESPONDER_TYPE || type.$$typeof === REACT_SCOPE_TYPE || type.$$typeof === REACT_BLOCK_TYPE);\n}\n\nfunction typeOf(object) {\n if (typeof object === 'object' && object !== null) {\n var $$typeof = object.$$typeof;\n\n switch ($$typeof) {\n case REACT_ELEMENT_TYPE:\n var type = object.type;\n\n switch (type) {\n case REACT_ASYNC_MODE_TYPE:\n case REACT_CONCURRENT_MODE_TYPE:\n case REACT_FRAGMENT_TYPE:\n case REACT_PROFILER_TYPE:\n case REACT_STRICT_MODE_TYPE:\n case REACT_SUSPENSE_TYPE:\n return type;\n\n default:\n var $$typeofType = type && type.$$typeof;\n\n switch ($$typeofType) {\n case REACT_CONTEXT_TYPE:\n case REACT_FORWARD_REF_TYPE:\n case REACT_LAZY_TYPE:\n case REACT_MEMO_TYPE:\n case REACT_PROVIDER_TYPE:\n return $$typeofType;\n\n default:\n return $$typeof;\n }\n\n }\n\n case REACT_PORTAL_TYPE:\n return $$typeof;\n }\n }\n\n return undefined;\n} // AsyncMode is deprecated along with isAsyncMode\n\nvar AsyncMode = REACT_ASYNC_MODE_TYPE;\nvar ConcurrentMode = REACT_CONCURRENT_MODE_TYPE;\nvar ContextConsumer = REACT_CONTEXT_TYPE;\nvar ContextProvider = REACT_PROVIDER_TYPE;\nvar Element = REACT_ELEMENT_TYPE;\nvar ForwardRef = REACT_FORWARD_REF_TYPE;\nvar Fragment = REACT_FRAGMENT_TYPE;\nvar Lazy = REACT_LAZY_TYPE;\nvar Memo = REACT_MEMO_TYPE;\nvar Portal = REACT_PORTAL_TYPE;\nvar Profiler = REACT_PROFILER_TYPE;\nvar StrictMode = REACT_STRICT_MODE_TYPE;\nvar Suspense = REACT_SUSPENSE_TYPE;\nvar hasWarnedAboutDeprecatedIsAsyncMode = false; // AsyncMode should be deprecated\n\nfunction isAsyncMode(object) {\n {\n if (!hasWarnedAboutDeprecatedIsAsyncMode) {\n hasWarnedAboutDeprecatedIsAsyncMode = true; // Using console['warn'] to evade Babel and ESLint\n\n console['warn']('The ReactIs.isAsyncMode() alias has been deprecated, ' + 'and will be removed in React 17+. Update your code to use ' + 'ReactIs.isConcurrentMode() instead. It has the exact same API.');\n }\n }\n\n return isConcurrentMode(object) || typeOf(object) === REACT_ASYNC_MODE_TYPE;\n}\nfunction isConcurrentMode(object) {\n return typeOf(object) === REACT_CONCURRENT_MODE_TYPE;\n}\nfunction isContextConsumer(object) {\n return typeOf(object) === REACT_CONTEXT_TYPE;\n}\nfunction isContextProvider(object) {\n return typeOf(object) === REACT_PROVIDER_TYPE;\n}\nfunction isElement(object) {\n return typeof object === 'object' && object !== null && object.$$typeof === REACT_ELEMENT_TYPE;\n}\nfunction isForwardRef(object) {\n return typeOf(object) === REACT_FORWARD_REF_TYPE;\n}\nfunction isFragment(object) {\n return typeOf(object) === REACT_FRAGMENT_TYPE;\n}\nfunction isLazy(object) {\n return typeOf(object) === REACT_LAZY_TYPE;\n}\nfunction isMemo(object) {\n return typeOf(object) === REACT_MEMO_TYPE;\n}\nfunction isPortal(object) {\n return typeOf(object) === REACT_PORTAL_TYPE;\n}\nfunction isProfiler(object) {\n return typeOf(object) === REACT_PROFILER_TYPE;\n}\nfunction isStrictMode(object) {\n return typeOf(object) === REACT_STRICT_MODE_TYPE;\n}\nfunction isSuspense(object) {\n return typeOf(object) === REACT_SUSPENSE_TYPE;\n}\n\nexports.AsyncMode = AsyncMode;\nexports.ConcurrentMode = ConcurrentMode;\nexports.ContextConsumer = ContextConsumer;\nexports.ContextProvider = ContextProvider;\nexports.Element = Element;\nexports.ForwardRef = ForwardRef;\nexports.Fragment = Fragment;\nexports.Lazy = Lazy;\nexports.Memo = Memo;\nexports.Portal = Portal;\nexports.Profiler = Profiler;\nexports.StrictMode = StrictMode;\nexports.Suspense = Suspense;\nexports.isAsyncMode = isAsyncMode;\nexports.isConcurrentMode = isConcurrentMode;\nexports.isContextConsumer = isContextConsumer;\nexports.isContextProvider = isContextProvider;\nexports.isElement = isElement;\nexports.isForwardRef = isForwardRef;\nexports.isFragment = isFragment;\nexports.isLazy = isLazy;\nexports.isMemo = isMemo;\nexports.isPortal = isPortal;\nexports.isProfiler = isProfiler;\nexports.isStrictMode = isStrictMode;\nexports.isSuspense = isSuspense;\nexports.isValidElementType = isValidElementType;\nexports.typeOf = typeOf;\n })();\n}\n","'use strict';\n\nif (process.env.NODE_ENV === 'production') {\n module.exports = require('./cjs/react-is.production.min.js');\n} else {\n module.exports = require('./cjs/react-is.development.js');\n}\n","/*\nobject-assign\n(c) Sindre Sorhus\n@license MIT\n*/\n\n'use strict';\n/* eslint-disable no-unused-vars */\nvar getOwnPropertySymbols = Object.getOwnPropertySymbols;\nvar hasOwnProperty = Object.prototype.hasOwnProperty;\nvar propIsEnumerable = Object.prototype.propertyIsEnumerable;\n\nfunction toObject(val) {\n\tif (val === null || val === undefined) {\n\t\tthrow new TypeError('Object.assign cannot be called with null or undefined');\n\t}\n\n\treturn Object(val);\n}\n\nfunction shouldUseNative() {\n\ttry {\n\t\tif (!Object.assign) {\n\t\t\treturn false;\n\t\t}\n\n\t\t// Detect buggy property enumeration order in older V8 versions.\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=4118\n\t\tvar test1 = new String('abc'); // eslint-disable-line no-new-wrappers\n\t\ttest1[5] = 'de';\n\t\tif (Object.getOwnPropertyNames(test1)[0] === '5') {\n\t\t\treturn false;\n\t\t}\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=3056\n\t\tvar test2 = {};\n\t\tfor (var i = 0; i < 10; i++) {\n\t\t\ttest2['_' + String.fromCharCode(i)] = i;\n\t\t}\n\t\tvar order2 = Object.getOwnPropertyNames(test2).map(function (n) {\n\t\t\treturn test2[n];\n\t\t});\n\t\tif (order2.join('') !== '0123456789') {\n\t\t\treturn false;\n\t\t}\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=3056\n\t\tvar test3 = {};\n\t\t'abcdefghijklmnopqrst'.split('').forEach(function (letter) {\n\t\t\ttest3[letter] = letter;\n\t\t});\n\t\tif (Object.keys(Object.assign({}, test3)).join('') !==\n\t\t\t\t'abcdefghijklmnopqrst') {\n\t\t\treturn false;\n\t\t}\n\n\t\treturn true;\n\t} catch (err) {\n\t\t// We don't expect any of the above to throw, but better to be safe.\n\t\treturn false;\n\t}\n}\n\nmodule.exports = shouldUseNative() ? Object.assign : function (target, source) {\n\tvar from;\n\tvar to = toObject(target);\n\tvar symbols;\n\n\tfor (var s = 1; s < arguments.length; s++) {\n\t\tfrom = Object(arguments[s]);\n\n\t\tfor (var key in from) {\n\t\t\tif (hasOwnProperty.call(from, key)) {\n\t\t\t\tto[key] = from[key];\n\t\t\t}\n\t\t}\n\n\t\tif (getOwnPropertySymbols) {\n\t\t\tsymbols = getOwnPropertySymbols(from);\n\t\t\tfor (var i = 0; i < symbols.length; i++) {\n\t\t\t\tif (propIsEnumerable.call(from, symbols[i])) {\n\t\t\t\t\tto[symbols[i]] = from[symbols[i]];\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\n\treturn to;\n};\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar ReactPropTypesSecret = 'SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED';\n\nmodule.exports = ReactPropTypesSecret;\n","module.exports = Function.call.bind(Object.prototype.hasOwnProperty);\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar printWarning = function() {};\n\nif (process.env.NODE_ENV !== 'production') {\n var ReactPropTypesSecret = require('./lib/ReactPropTypesSecret');\n var loggedTypeFailures = {};\n var has = require('./lib/has');\n\n printWarning = function(text) {\n var message = 'Warning: ' + text;\n if (typeof console !== 'undefined') {\n console.error(message);\n }\n try {\n // --- Welcome to debugging React ---\n // This error was thrown as a convenience so that you can use this stack\n // to find the callsite that caused this warning to fire.\n throw new Error(message);\n } catch (x) { /**/ }\n };\n}\n\n/**\n * Assert that the values match with the type specs.\n * Error messages are memorized and will only be shown once.\n *\n * @param {object} typeSpecs Map of name to a ReactPropType\n * @param {object} values Runtime values that need to be type-checked\n * @param {string} location e.g. \"prop\", \"context\", \"child context\"\n * @param {string} componentName Name of the component for error messages.\n * @param {?Function} getStack Returns the component stack.\n * @private\n */\nfunction checkPropTypes(typeSpecs, values, location, componentName, getStack) {\n if (process.env.NODE_ENV !== 'production') {\n for (var typeSpecName in typeSpecs) {\n if (has(typeSpecs, typeSpecName)) {\n var error;\n // Prop type validation may throw. In case they do, we don't want to\n // fail the render phase where it didn't fail before. So we log it.\n // After these have been cleaned up, we'll let them throw.\n try {\n // This is intentionally an invariant that gets caught. It's the same\n // behavior as without this statement except with a better message.\n if (typeof typeSpecs[typeSpecName] !== 'function') {\n var err = Error(\n (componentName || 'React class') + ': ' + location + ' type `' + typeSpecName + '` is invalid; ' +\n 'it must be a function, usually from the `prop-types` package, but received `' + typeof typeSpecs[typeSpecName] + '`.' +\n 'This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.'\n );\n err.name = 'Invariant Violation';\n throw err;\n }\n error = typeSpecs[typeSpecName](values, typeSpecName, componentName, location, null, ReactPropTypesSecret);\n } catch (ex) {\n error = ex;\n }\n if (error && !(error instanceof Error)) {\n printWarning(\n (componentName || 'React class') + ': type specification of ' +\n location + ' `' + typeSpecName + '` is invalid; the type checker ' +\n 'function must return `null` or an `Error` but returned a ' + typeof error + '. ' +\n 'You may have forgotten to pass an argument to the type checker ' +\n 'creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and ' +\n 'shape all require an argument).'\n );\n }\n if (error instanceof Error && !(error.message in loggedTypeFailures)) {\n // Only monitor this failure once because there tends to be a lot of the\n // same error.\n loggedTypeFailures[error.message] = true;\n\n var stack = getStack ? getStack() : '';\n\n printWarning(\n 'Failed ' + location + ' type: ' + error.message + (stack != null ? stack : '')\n );\n }\n }\n }\n }\n}\n\n/**\n * Resets warning cache when testing.\n *\n * @private\n */\ncheckPropTypes.resetWarningCache = function() {\n if (process.env.NODE_ENV !== 'production') {\n loggedTypeFailures = {};\n }\n}\n\nmodule.exports = checkPropTypes;\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar ReactIs = require('react-is');\nvar assign = require('object-assign');\n\nvar ReactPropTypesSecret = require('./lib/ReactPropTypesSecret');\nvar has = require('./lib/has');\nvar checkPropTypes = require('./checkPropTypes');\n\nvar printWarning = function() {};\n\nif (process.env.NODE_ENV !== 'production') {\n printWarning = function(text) {\n var message = 'Warning: ' + text;\n if (typeof console !== 'undefined') {\n console.error(message);\n }\n try {\n // --- Welcome to debugging React ---\n // This error was thrown as a convenience so that you can use this stack\n // to find the callsite that caused this warning to fire.\n throw new Error(message);\n } catch (x) {}\n };\n}\n\nfunction emptyFunctionThatReturnsNull() {\n return null;\n}\n\nmodule.exports = function(isValidElement, throwOnDirectAccess) {\n /* global Symbol */\n var ITERATOR_SYMBOL = typeof Symbol === 'function' && Symbol.iterator;\n var FAUX_ITERATOR_SYMBOL = '@@iterator'; // Before Symbol spec.\n\n /**\n * Returns the iterator method function contained on the iterable object.\n *\n * Be sure to invoke the function with the iterable as context:\n *\n * var iteratorFn = getIteratorFn(myIterable);\n * if (iteratorFn) {\n * var iterator = iteratorFn.call(myIterable);\n * ...\n * }\n *\n * @param {?object} maybeIterable\n * @return {?function}\n */\n function getIteratorFn(maybeIterable) {\n var iteratorFn = maybeIterable && (ITERATOR_SYMBOL && maybeIterable[ITERATOR_SYMBOL] || maybeIterable[FAUX_ITERATOR_SYMBOL]);\n if (typeof iteratorFn === 'function') {\n return iteratorFn;\n }\n }\n\n /**\n * Collection of methods that allow declaration and validation of props that are\n * supplied to React components. Example usage:\n *\n * var Props = require('ReactPropTypes');\n * var MyArticle = React.createClass({\n * propTypes: {\n * // An optional string prop named \"description\".\n * description: Props.string,\n *\n * // A required enum prop named \"category\".\n * category: Props.oneOf(['News','Photos']).isRequired,\n *\n * // A prop named \"dialog\" that requires an instance of Dialog.\n * dialog: Props.instanceOf(Dialog).isRequired\n * },\n * render: function() { ... }\n * });\n *\n * A more formal specification of how these methods are used:\n *\n * type := array|bool|func|object|number|string|oneOf([...])|instanceOf(...)\n * decl := ReactPropTypes.{type}(.isRequired)?\n *\n * Each and every declaration produces a function with the same signature. This\n * allows the creation of custom validation functions. For example:\n *\n * var MyLink = React.createClass({\n * propTypes: {\n * // An optional string or URI prop named \"href\".\n * href: function(props, propName, componentName) {\n * var propValue = props[propName];\n * if (propValue != null && typeof propValue !== 'string' &&\n * !(propValue instanceof URI)) {\n * return new Error(\n * 'Expected a string or an URI for ' + propName + ' in ' +\n * componentName\n * );\n * }\n * }\n * },\n * render: function() {...}\n * });\n *\n * @internal\n */\n\n var ANONYMOUS = '<>';\n\n // Important!\n // Keep this list in sync with production version in `./factoryWithThrowingShims.js`.\n var ReactPropTypes = {\n array: createPrimitiveTypeChecker('array'),\n bigint: createPrimitiveTypeChecker('bigint'),\n bool: createPrimitiveTypeChecker('boolean'),\n func: createPrimitiveTypeChecker('function'),\n number: createPrimitiveTypeChecker('number'),\n object: createPrimitiveTypeChecker('object'),\n string: createPrimitiveTypeChecker('string'),\n symbol: createPrimitiveTypeChecker('symbol'),\n\n any: createAnyTypeChecker(),\n arrayOf: createArrayOfTypeChecker,\n element: createElementTypeChecker(),\n elementType: createElementTypeTypeChecker(),\n instanceOf: createInstanceTypeChecker,\n node: createNodeChecker(),\n objectOf: createObjectOfTypeChecker,\n oneOf: createEnumTypeChecker,\n oneOfType: createUnionTypeChecker,\n shape: createShapeTypeChecker,\n exact: createStrictShapeTypeChecker,\n };\n\n /**\n * inlined Object.is polyfill to avoid requiring consumers ship their own\n * https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object/is\n */\n /*eslint-disable no-self-compare*/\n function is(x, y) {\n // SameValue algorithm\n if (x === y) {\n // Steps 1-5, 7-10\n // Steps 6.b-6.e: +0 != -0\n return x !== 0 || 1 / x === 1 / y;\n } else {\n // Step 6.a: NaN == NaN\n return x !== x && y !== y;\n }\n }\n /*eslint-enable no-self-compare*/\n\n /**\n * We use an Error-like object for backward compatibility as people may call\n * PropTypes directly and inspect their output. However, we don't use real\n * Errors anymore. We don't inspect their stack anyway, and creating them\n * is prohibitively expensive if they are created too often, such as what\n * happens in oneOfType() for any type before the one that matched.\n */\n function PropTypeError(message, data) {\n this.message = message;\n this.data = data && typeof data === 'object' ? data: {};\n this.stack = '';\n }\n // Make `instanceof Error` still work for returned errors.\n PropTypeError.prototype = Error.prototype;\n\n function createChainableTypeChecker(validate) {\n if (process.env.NODE_ENV !== 'production') {\n var manualPropTypeCallCache = {};\n var manualPropTypeWarningCount = 0;\n }\n function checkType(isRequired, props, propName, componentName, location, propFullName, secret) {\n componentName = componentName || ANONYMOUS;\n propFullName = propFullName || propName;\n\n if (secret !== ReactPropTypesSecret) {\n if (throwOnDirectAccess) {\n // New behavior only for users of `prop-types` package\n var err = new Error(\n 'Calling PropTypes validators directly is not supported by the `prop-types` package. ' +\n 'Use `PropTypes.checkPropTypes()` to call them. ' +\n 'Read more at http://fb.me/use-check-prop-types'\n );\n err.name = 'Invariant Violation';\n throw err;\n } else if (process.env.NODE_ENV !== 'production' && typeof console !== 'undefined') {\n // Old behavior for people using React.PropTypes\n var cacheKey = componentName + ':' + propName;\n if (\n !manualPropTypeCallCache[cacheKey] &&\n // Avoid spamming the console because they are often not actionable except for lib authors\n manualPropTypeWarningCount < 3\n ) {\n printWarning(\n 'You are manually calling a React.PropTypes validation ' +\n 'function for the `' + propFullName + '` prop on `' + componentName + '`. This is deprecated ' +\n 'and will throw in the standalone `prop-types` package. ' +\n 'You may be seeing this warning due to a third-party PropTypes ' +\n 'library. See https://fb.me/react-warning-dont-call-proptypes ' + 'for details.'\n );\n manualPropTypeCallCache[cacheKey] = true;\n manualPropTypeWarningCount++;\n }\n }\n }\n if (props[propName] == null) {\n if (isRequired) {\n if (props[propName] === null) {\n return new PropTypeError('The ' + location + ' `' + propFullName + '` is marked as required ' + ('in `' + componentName + '`, but its value is `null`.'));\n }\n return new PropTypeError('The ' + location + ' `' + propFullName + '` is marked as required in ' + ('`' + componentName + '`, but its value is `undefined`.'));\n }\n return null;\n } else {\n return validate(props, propName, componentName, location, propFullName);\n }\n }\n\n var chainedCheckType = checkType.bind(null, false);\n chainedCheckType.isRequired = checkType.bind(null, true);\n\n return chainedCheckType;\n }\n\n function createPrimitiveTypeChecker(expectedType) {\n function validate(props, propName, componentName, location, propFullName, secret) {\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== expectedType) {\n // `propValue` being instance of, say, date/regexp, pass the 'object'\n // check, but we can offer a more precise error message here rather than\n // 'of type `object`'.\n var preciseType = getPreciseType(propValue);\n\n return new PropTypeError(\n 'Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + preciseType + '` supplied to `' + componentName + '`, expected ') + ('`' + expectedType + '`.'),\n {expectedType: expectedType}\n );\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createAnyTypeChecker() {\n return createChainableTypeChecker(emptyFunctionThatReturnsNull);\n }\n\n function createArrayOfTypeChecker(typeChecker) {\n function validate(props, propName, componentName, location, propFullName) {\n if (typeof typeChecker !== 'function') {\n return new PropTypeError('Property `' + propFullName + '` of component `' + componentName + '` has invalid PropType notation inside arrayOf.');\n }\n var propValue = props[propName];\n if (!Array.isArray(propValue)) {\n var propType = getPropType(propValue);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected an array.'));\n }\n for (var i = 0; i < propValue.length; i++) {\n var error = typeChecker(propValue, i, componentName, location, propFullName + '[' + i + ']', ReactPropTypesSecret);\n if (error instanceof Error) {\n return error;\n }\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createElementTypeChecker() {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n if (!isValidElement(propValue)) {\n var propType = getPropType(propValue);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected a single ReactElement.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createElementTypeTypeChecker() {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n if (!ReactIs.isValidElementType(propValue)) {\n var propType = getPropType(propValue);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected a single ReactElement type.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createInstanceTypeChecker(expectedClass) {\n function validate(props, propName, componentName, location, propFullName) {\n if (!(props[propName] instanceof expectedClass)) {\n var expectedClassName = expectedClass.name || ANONYMOUS;\n var actualClassName = getClassName(props[propName]);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + actualClassName + '` supplied to `' + componentName + '`, expected ') + ('instance of `' + expectedClassName + '`.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createEnumTypeChecker(expectedValues) {\n if (!Array.isArray(expectedValues)) {\n if (process.env.NODE_ENV !== 'production') {\n if (arguments.length > 1) {\n printWarning(\n 'Invalid arguments supplied to oneOf, expected an array, got ' + arguments.length + ' arguments. ' +\n 'A common mistake is to write oneOf(x, y, z) instead of oneOf([x, y, z]).'\n );\n } else {\n printWarning('Invalid argument supplied to oneOf, expected an array.');\n }\n }\n return emptyFunctionThatReturnsNull;\n }\n\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n for (var i = 0; i < expectedValues.length; i++) {\n if (is(propValue, expectedValues[i])) {\n return null;\n }\n }\n\n var valuesString = JSON.stringify(expectedValues, function replacer(key, value) {\n var type = getPreciseType(value);\n if (type === 'symbol') {\n return String(value);\n }\n return value;\n });\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of value `' + String(propValue) + '` ' + ('supplied to `' + componentName + '`, expected one of ' + valuesString + '.'));\n }\n return createChainableTypeChecker(validate);\n }\n\n function createObjectOfTypeChecker(typeChecker) {\n function validate(props, propName, componentName, location, propFullName) {\n if (typeof typeChecker !== 'function') {\n return new PropTypeError('Property `' + propFullName + '` of component `' + componentName + '` has invalid PropType notation inside objectOf.');\n }\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== 'object') {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected an object.'));\n }\n for (var key in propValue) {\n if (has(propValue, key)) {\n var error = typeChecker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret);\n if (error instanceof Error) {\n return error;\n }\n }\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createUnionTypeChecker(arrayOfTypeCheckers) {\n if (!Array.isArray(arrayOfTypeCheckers)) {\n process.env.NODE_ENV !== 'production' ? printWarning('Invalid argument supplied to oneOfType, expected an instance of array.') : void 0;\n return emptyFunctionThatReturnsNull;\n }\n\n for (var i = 0; i < arrayOfTypeCheckers.length; i++) {\n var checker = arrayOfTypeCheckers[i];\n if (typeof checker !== 'function') {\n printWarning(\n 'Invalid argument supplied to oneOfType. Expected an array of check functions, but ' +\n 'received ' + getPostfixForTypeWarning(checker) + ' at index ' + i + '.'\n );\n return emptyFunctionThatReturnsNull;\n }\n }\n\n function validate(props, propName, componentName, location, propFullName) {\n var expectedTypes = [];\n for (var i = 0; i < arrayOfTypeCheckers.length; i++) {\n var checker = arrayOfTypeCheckers[i];\n var checkerResult = checker(props, propName, componentName, location, propFullName, ReactPropTypesSecret);\n if (checkerResult == null) {\n return null;\n }\n if (checkerResult.data && has(checkerResult.data, 'expectedType')) {\n expectedTypes.push(checkerResult.data.expectedType);\n }\n }\n var expectedTypesMessage = (expectedTypes.length > 0) ? ', expected one of type [' + expectedTypes.join(', ') + ']': '';\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` supplied to ' + ('`' + componentName + '`' + expectedTypesMessage + '.'));\n }\n return createChainableTypeChecker(validate);\n }\n\n function createNodeChecker() {\n function validate(props, propName, componentName, location, propFullName) {\n if (!isNode(props[propName])) {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` supplied to ' + ('`' + componentName + '`, expected a ReactNode.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function invalidValidatorError(componentName, location, propFullName, key, type) {\n return new PropTypeError(\n (componentName || 'React class') + ': ' + location + ' type `' + propFullName + '.' + key + '` is invalid; ' +\n 'it must be a function, usually from the `prop-types` package, but received `' + type + '`.'\n );\n }\n\n function createShapeTypeChecker(shapeTypes) {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== 'object') {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type `' + propType + '` ' + ('supplied to `' + componentName + '`, expected `object`.'));\n }\n for (var key in shapeTypes) {\n var checker = shapeTypes[key];\n if (typeof checker !== 'function') {\n return invalidValidatorError(componentName, location, propFullName, key, getPreciseType(checker));\n }\n var error = checker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret);\n if (error) {\n return error;\n }\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createStrictShapeTypeChecker(shapeTypes) {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== 'object') {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type `' + propType + '` ' + ('supplied to `' + componentName + '`, expected `object`.'));\n }\n // We need to check all keys in case some are required but missing from props.\n var allKeys = assign({}, props[propName], shapeTypes);\n for (var key in allKeys) {\n var checker = shapeTypes[key];\n if (has(shapeTypes, key) && typeof checker !== 'function') {\n return invalidValidatorError(componentName, location, propFullName, key, getPreciseType(checker));\n }\n if (!checker) {\n return new PropTypeError(\n 'Invalid ' + location + ' `' + propFullName + '` key `' + key + '` supplied to `' + componentName + '`.' +\n '\\nBad object: ' + JSON.stringify(props[propName], null, ' ') +\n '\\nValid keys: ' + JSON.stringify(Object.keys(shapeTypes), null, ' ')\n );\n }\n var error = checker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret);\n if (error) {\n return error;\n }\n }\n return null;\n }\n\n return createChainableTypeChecker(validate);\n }\n\n function isNode(propValue) {\n switch (typeof propValue) {\n case 'number':\n case 'string':\n case 'undefined':\n return true;\n case 'boolean':\n return !propValue;\n case 'object':\n if (Array.isArray(propValue)) {\n return propValue.every(isNode);\n }\n if (propValue === null || isValidElement(propValue)) {\n return true;\n }\n\n var iteratorFn = getIteratorFn(propValue);\n if (iteratorFn) {\n var iterator = iteratorFn.call(propValue);\n var step;\n if (iteratorFn !== propValue.entries) {\n while (!(step = iterator.next()).done) {\n if (!isNode(step.value)) {\n return false;\n }\n }\n } else {\n // Iterator will provide entry [k,v] tuples rather than values.\n while (!(step = iterator.next()).done) {\n var entry = step.value;\n if (entry) {\n if (!isNode(entry[1])) {\n return false;\n }\n }\n }\n }\n } else {\n return false;\n }\n\n return true;\n default:\n return false;\n }\n }\n\n function isSymbol(propType, propValue) {\n // Native Symbol.\n if (propType === 'symbol') {\n return true;\n }\n\n // falsy value can't be a Symbol\n if (!propValue) {\n return false;\n }\n\n // 19.4.3.5 Symbol.prototype[@@toStringTag] === 'Symbol'\n if (propValue['@@toStringTag'] === 'Symbol') {\n return true;\n }\n\n // Fallback for non-spec compliant Symbols which are polyfilled.\n if (typeof Symbol === 'function' && propValue instanceof Symbol) {\n return true;\n }\n\n return false;\n }\n\n // Equivalent of `typeof` but with special handling for array and regexp.\n function getPropType(propValue) {\n var propType = typeof propValue;\n if (Array.isArray(propValue)) {\n return 'array';\n }\n if (propValue instanceof RegExp) {\n // Old webkits (at least until Android 4.0) return 'function' rather than\n // 'object' for typeof a RegExp. We'll normalize this here so that /bla/\n // passes PropTypes.object.\n return 'object';\n }\n if (isSymbol(propType, propValue)) {\n return 'symbol';\n }\n return propType;\n }\n\n // This handles more types than `getPropType`. Only used for error messages.\n // See `createPrimitiveTypeChecker`.\n function getPreciseType(propValue) {\n if (typeof propValue === 'undefined' || propValue === null) {\n return '' + propValue;\n }\n var propType = getPropType(propValue);\n if (propType === 'object') {\n if (propValue instanceof Date) {\n return 'date';\n } else if (propValue instanceof RegExp) {\n return 'regexp';\n }\n }\n return propType;\n }\n\n // Returns a string that is postfixed to a warning about an invalid type.\n // For example, \"undefined\" or \"of type array\"\n function getPostfixForTypeWarning(value) {\n var type = getPreciseType(value);\n switch (type) {\n case 'array':\n case 'object':\n return 'an ' + type;\n case 'boolean':\n case 'date':\n case 'regexp':\n return 'a ' + type;\n default:\n return type;\n }\n }\n\n // Returns class name of the object, if any.\n function getClassName(propValue) {\n if (!propValue.constructor || !propValue.constructor.name) {\n return ANONYMOUS;\n }\n return propValue.constructor.name;\n }\n\n ReactPropTypes.checkPropTypes = checkPropTypes;\n ReactPropTypes.resetWarningCache = checkPropTypes.resetWarningCache;\n ReactPropTypes.PropTypes = ReactPropTypes;\n\n return ReactPropTypes;\n};\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar ReactPropTypesSecret = require('./lib/ReactPropTypesSecret');\n\nfunction emptyFunction() {}\nfunction emptyFunctionWithReset() {}\nemptyFunctionWithReset.resetWarningCache = emptyFunction;\n\nmodule.exports = function() {\n function shim(props, propName, componentName, location, propFullName, secret) {\n if (secret === ReactPropTypesSecret) {\n // It is still safe when called from React.\n return;\n }\n var err = new Error(\n 'Calling PropTypes validators directly is not supported by the `prop-types` package. ' +\n 'Use PropTypes.checkPropTypes() to call them. ' +\n 'Read more at http://fb.me/use-check-prop-types'\n );\n err.name = 'Invariant Violation';\n throw err;\n };\n shim.isRequired = shim;\n function getShim() {\n return shim;\n };\n // Important!\n // Keep this list in sync with production version in `./factoryWithTypeCheckers.js`.\n var ReactPropTypes = {\n array: shim,\n bigint: shim,\n bool: shim,\n func: shim,\n number: shim,\n object: shim,\n string: shim,\n symbol: shim,\n\n any: shim,\n arrayOf: getShim,\n element: shim,\n elementType: shim,\n instanceOf: getShim,\n node: shim,\n objectOf: getShim,\n oneOf: getShim,\n oneOfType: getShim,\n shape: getShim,\n exact: getShim,\n\n checkPropTypes: emptyFunctionWithReset,\n resetWarningCache: emptyFunction\n };\n\n ReactPropTypes.PropTypes = ReactPropTypes;\n\n return ReactPropTypes;\n};\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\nif (process.env.NODE_ENV !== 'production') {\n var ReactIs = require('react-is');\n\n // By explicitly using `prop-types` you are opting into new development behavior.\n // http://fb.me/prop-types-in-prod\n var throwOnDirectAccess = true;\n module.exports = require('./factoryWithTypeCheckers')(ReactIs.isElement, throwOnDirectAccess);\n} else {\n // By explicitly using `prop-types` you are opting into new production behavior.\n // http://fb.me/prop-types-in-prod\n module.exports = require('./factoryWithThrowingShims')();\n}\n","import PropTypes from 'prop-types';\nimport chainPropTypes from '../chainPropTypes';\nfunction isClassComponent(elementType) {\n // elementType.prototype?.isReactComponent\n const {\n prototype = {}\n } = elementType;\n return Boolean(prototype.isReactComponent);\n}\nfunction acceptingRef(props, propName, componentName, location, propFullName) {\n const element = props[propName];\n const safePropName = propFullName || propName;\n if (element == null ||\n // When server-side rendering React doesn't warn either.\n // This is not an accurate check for SSR.\n // This is only in place for Emotion compat.\n // TODO: Revisit once https://github.com/facebook/react/issues/20047 is resolved.\n typeof window === 'undefined') {\n return null;\n }\n let warningHint;\n const elementType = element.type;\n /**\n * Blacklisting instead of whitelisting\n *\n * Blacklisting will miss some components, such as React.Fragment. Those will at least\n * trigger a warning in React.\n * We can't whitelist because there is no safe way to detect React.forwardRef\n * or class components. \"Safe\" means there's no public API.\n *\n */\n if (typeof elementType === 'function' && !isClassComponent(elementType)) {\n warningHint = 'Did you accidentally use a plain function component for an element instead?';\n }\n if (warningHint !== undefined) {\n return new Error(`Invalid ${location} \\`${safePropName}\\` supplied to \\`${componentName}\\`. ` + `Expected an element that can hold a ref. ${warningHint} ` + 'For more information see https://mui.com/r/caveat-with-refs-guide');\n }\n return null;\n}\nconst elementAcceptingRef = chainPropTypes(PropTypes.element, acceptingRef);\nelementAcceptingRef.isRequired = chainPropTypes(PropTypes.element.isRequired, acceptingRef);\nexport default elementAcceptingRef;","import _extends from \"@babel/runtime/helpers/esm/extends\";\n// This module is based on https://github.com/airbnb/prop-types-exact repository.\n// However, in order to reduce the number of dependencies and to remove some extra safe checks\n// the module was forked.\n\nconst specialProperty = 'exact-prop: \\u200b';\nexport default function exactProp(propTypes) {\n if (process.env.NODE_ENV === 'production') {\n return propTypes;\n }\n return _extends({}, propTypes, {\n [specialProperty]: props => {\n const unsupportedProps = Object.keys(props).filter(prop => !propTypes.hasOwnProperty(prop));\n if (unsupportedProps.length > 0) {\n return new Error(`The following props are not supported: ${unsupportedProps.map(prop => `\\`${prop}\\``).join(', ')}. Please remove them.`);\n }\n return null;\n }\n });\n}","/**\n * WARNING: Don't import this directly.\n * Use `MuiError` from `@mui/internal-babel-macros/MuiError.macro` instead.\n * @param {number} code\n */\nexport default function formatMuiErrorMessage(code) {\n // Apply babel-plugin-transform-template-literals in loose mode\n // loose mode is safe if we're concatenating primitives\n // see https://babeljs.io/docs/en/babel-plugin-transform-template-literals#loose\n /* eslint-disable prefer-template */\n let url = 'https://mui.com/production-error/?code=' + code;\n for (let i = 1; i < arguments.length; i += 1) {\n // rest params over-transpile for this case\n // eslint-disable-next-line prefer-rest-params\n url += '&args[]=' + encodeURIComponent(arguments[i]);\n }\n return 'Minified MUI error #' + code + '; visit ' + url + ' for the full message.';\n /* eslint-enable prefer-template */\n}","/**\n * @license React\n * react-is.production.min.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n'use strict';var b=Symbol.for(\"react.element\"),c=Symbol.for(\"react.portal\"),d=Symbol.for(\"react.fragment\"),e=Symbol.for(\"react.strict_mode\"),f=Symbol.for(\"react.profiler\"),g=Symbol.for(\"react.provider\"),h=Symbol.for(\"react.context\"),k=Symbol.for(\"react.server_context\"),l=Symbol.for(\"react.forward_ref\"),m=Symbol.for(\"react.suspense\"),n=Symbol.for(\"react.suspense_list\"),p=Symbol.for(\"react.memo\"),q=Symbol.for(\"react.lazy\"),t=Symbol.for(\"react.offscreen\"),u;u=Symbol.for(\"react.module.reference\");\nfunction v(a){if(\"object\"===typeof a&&null!==a){var r=a.$$typeof;switch(r){case b:switch(a=a.type,a){case d:case f:case e:case m:case n:return a;default:switch(a=a&&a.$$typeof,a){case k:case h:case l:case q:case p:case g:return a;default:return r}}case c:return r}}}exports.ContextConsumer=h;exports.ContextProvider=g;exports.Element=b;exports.ForwardRef=l;exports.Fragment=d;exports.Lazy=q;exports.Memo=p;exports.Portal=c;exports.Profiler=f;exports.StrictMode=e;exports.Suspense=m;\nexports.SuspenseList=n;exports.isAsyncMode=function(){return!1};exports.isConcurrentMode=function(){return!1};exports.isContextConsumer=function(a){return v(a)===h};exports.isContextProvider=function(a){return v(a)===g};exports.isElement=function(a){return\"object\"===typeof a&&null!==a&&a.$$typeof===b};exports.isForwardRef=function(a){return v(a)===l};exports.isFragment=function(a){return v(a)===d};exports.isLazy=function(a){return v(a)===q};exports.isMemo=function(a){return v(a)===p};\nexports.isPortal=function(a){return v(a)===c};exports.isProfiler=function(a){return v(a)===f};exports.isStrictMode=function(a){return v(a)===e};exports.isSuspense=function(a){return v(a)===m};exports.isSuspenseList=function(a){return v(a)===n};\nexports.isValidElementType=function(a){return\"string\"===typeof a||\"function\"===typeof a||a===d||a===f||a===e||a===m||a===n||a===t||\"object\"===typeof a&&null!==a&&(a.$$typeof===q||a.$$typeof===p||a.$$typeof===g||a.$$typeof===h||a.$$typeof===l||a.$$typeof===u||void 0!==a.getModuleId)?!0:!1};exports.typeOf=v;\n","/**\n * @license React\n * react-is.development.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nif (process.env.NODE_ENV !== \"production\") {\n (function() {\n'use strict';\n\n// ATTENTION\n// When adding new symbols to this file,\n// Please consider also adding to 'react-devtools-shared/src/backend/ReactSymbols'\n// The Symbol used to tag the ReactElement-like types.\nvar REACT_ELEMENT_TYPE = Symbol.for('react.element');\nvar REACT_PORTAL_TYPE = Symbol.for('react.portal');\nvar REACT_FRAGMENT_TYPE = Symbol.for('react.fragment');\nvar REACT_STRICT_MODE_TYPE = Symbol.for('react.strict_mode');\nvar REACT_PROFILER_TYPE = Symbol.for('react.profiler');\nvar REACT_PROVIDER_TYPE = Symbol.for('react.provider');\nvar REACT_CONTEXT_TYPE = Symbol.for('react.context');\nvar REACT_SERVER_CONTEXT_TYPE = Symbol.for('react.server_context');\nvar REACT_FORWARD_REF_TYPE = Symbol.for('react.forward_ref');\nvar REACT_SUSPENSE_TYPE = Symbol.for('react.suspense');\nvar REACT_SUSPENSE_LIST_TYPE = Symbol.for('react.suspense_list');\nvar REACT_MEMO_TYPE = Symbol.for('react.memo');\nvar REACT_LAZY_TYPE = Symbol.for('react.lazy');\nvar REACT_OFFSCREEN_TYPE = Symbol.for('react.offscreen');\n\n// -----------------------------------------------------------------------------\n\nvar enableScopeAPI = false; // Experimental Create Event Handle API.\nvar enableCacheElement = false;\nvar enableTransitionTracing = false; // No known bugs, but needs performance testing\n\nvar enableLegacyHidden = false; // Enables unstable_avoidThisFallback feature in Fiber\n// stuff. Intended to enable React core members to more easily debug scheduling\n// issues in DEV builds.\n\nvar enableDebugTracing = false; // Track which Fiber(s) schedule render work.\n\nvar REACT_MODULE_REFERENCE;\n\n{\n REACT_MODULE_REFERENCE = Symbol.for('react.module.reference');\n}\n\nfunction isValidElementType(type) {\n if (typeof type === 'string' || typeof type === 'function') {\n return true;\n } // Note: typeof might be other than 'symbol' or 'number' (e.g. if it's a polyfill).\n\n\n if (type === REACT_FRAGMENT_TYPE || type === REACT_PROFILER_TYPE || enableDebugTracing || type === REACT_STRICT_MODE_TYPE || type === REACT_SUSPENSE_TYPE || type === REACT_SUSPENSE_LIST_TYPE || enableLegacyHidden || type === REACT_OFFSCREEN_TYPE || enableScopeAPI || enableCacheElement || enableTransitionTracing ) {\n return true;\n }\n\n if (typeof type === 'object' && type !== null) {\n if (type.$$typeof === REACT_LAZY_TYPE || type.$$typeof === REACT_MEMO_TYPE || type.$$typeof === REACT_PROVIDER_TYPE || type.$$typeof === REACT_CONTEXT_TYPE || type.$$typeof === REACT_FORWARD_REF_TYPE || // This needs to include all possible module reference object\n // types supported by any Flight configuration anywhere since\n // we don't know which Flight build this will end up being used\n // with.\n type.$$typeof === REACT_MODULE_REFERENCE || type.getModuleId !== undefined) {\n return true;\n }\n }\n\n return false;\n}\n\nfunction typeOf(object) {\n if (typeof object === 'object' && object !== null) {\n var $$typeof = object.$$typeof;\n\n switch ($$typeof) {\n case REACT_ELEMENT_TYPE:\n var type = object.type;\n\n switch (type) {\n case REACT_FRAGMENT_TYPE:\n case REACT_PROFILER_TYPE:\n case REACT_STRICT_MODE_TYPE:\n case REACT_SUSPENSE_TYPE:\n case REACT_SUSPENSE_LIST_TYPE:\n return type;\n\n default:\n var $$typeofType = type && type.$$typeof;\n\n switch ($$typeofType) {\n case REACT_SERVER_CONTEXT_TYPE:\n case REACT_CONTEXT_TYPE:\n case REACT_FORWARD_REF_TYPE:\n case REACT_LAZY_TYPE:\n case REACT_MEMO_TYPE:\n case REACT_PROVIDER_TYPE:\n return $$typeofType;\n\n default:\n return $$typeof;\n }\n\n }\n\n case REACT_PORTAL_TYPE:\n return $$typeof;\n }\n }\n\n return undefined;\n}\nvar ContextConsumer = REACT_CONTEXT_TYPE;\nvar ContextProvider = REACT_PROVIDER_TYPE;\nvar Element = REACT_ELEMENT_TYPE;\nvar ForwardRef = REACT_FORWARD_REF_TYPE;\nvar Fragment = REACT_FRAGMENT_TYPE;\nvar Lazy = REACT_LAZY_TYPE;\nvar Memo = REACT_MEMO_TYPE;\nvar Portal = REACT_PORTAL_TYPE;\nvar Profiler = REACT_PROFILER_TYPE;\nvar StrictMode = REACT_STRICT_MODE_TYPE;\nvar Suspense = REACT_SUSPENSE_TYPE;\nvar SuspenseList = REACT_SUSPENSE_LIST_TYPE;\nvar hasWarnedAboutDeprecatedIsAsyncMode = false;\nvar hasWarnedAboutDeprecatedIsConcurrentMode = false; // AsyncMode should be deprecated\n\nfunction isAsyncMode(object) {\n {\n if (!hasWarnedAboutDeprecatedIsAsyncMode) {\n hasWarnedAboutDeprecatedIsAsyncMode = true; // Using console['warn'] to evade Babel and ESLint\n\n console['warn']('The ReactIs.isAsyncMode() alias has been deprecated, ' + 'and will be removed in React 18+.');\n }\n }\n\n return false;\n}\nfunction isConcurrentMode(object) {\n {\n if (!hasWarnedAboutDeprecatedIsConcurrentMode) {\n hasWarnedAboutDeprecatedIsConcurrentMode = true; // Using console['warn'] to evade Babel and ESLint\n\n console['warn']('The ReactIs.isConcurrentMode() alias has been deprecated, ' + 'and will be removed in React 18+.');\n }\n }\n\n return false;\n}\nfunction isContextConsumer(object) {\n return typeOf(object) === REACT_CONTEXT_TYPE;\n}\nfunction isContextProvider(object) {\n return typeOf(object) === REACT_PROVIDER_TYPE;\n}\nfunction isElement(object) {\n return typeof object === 'object' && object !== null && object.$$typeof === REACT_ELEMENT_TYPE;\n}\nfunction isForwardRef(object) {\n return typeOf(object) === REACT_FORWARD_REF_TYPE;\n}\nfunction isFragment(object) {\n return typeOf(object) === REACT_FRAGMENT_TYPE;\n}\nfunction isLazy(object) {\n return typeOf(object) === REACT_LAZY_TYPE;\n}\nfunction isMemo(object) {\n return typeOf(object) === REACT_MEMO_TYPE;\n}\nfunction isPortal(object) {\n return typeOf(object) === REACT_PORTAL_TYPE;\n}\nfunction isProfiler(object) {\n return typeOf(object) === REACT_PROFILER_TYPE;\n}\nfunction isStrictMode(object) {\n return typeOf(object) === REACT_STRICT_MODE_TYPE;\n}\nfunction isSuspense(object) {\n return typeOf(object) === REACT_SUSPENSE_TYPE;\n}\nfunction isSuspenseList(object) {\n return typeOf(object) === REACT_SUSPENSE_LIST_TYPE;\n}\n\nexports.ContextConsumer = ContextConsumer;\nexports.ContextProvider = ContextProvider;\nexports.Element = Element;\nexports.ForwardRef = ForwardRef;\nexports.Fragment = Fragment;\nexports.Lazy = Lazy;\nexports.Memo = Memo;\nexports.Portal = Portal;\nexports.Profiler = Profiler;\nexports.StrictMode = StrictMode;\nexports.Suspense = Suspense;\nexports.SuspenseList = SuspenseList;\nexports.isAsyncMode = isAsyncMode;\nexports.isConcurrentMode = isConcurrentMode;\nexports.isContextConsumer = isContextConsumer;\nexports.isContextProvider = isContextProvider;\nexports.isElement = isElement;\nexports.isForwardRef = isForwardRef;\nexports.isFragment = isFragment;\nexports.isLazy = isLazy;\nexports.isMemo = isMemo;\nexports.isPortal = isPortal;\nexports.isProfiler = isProfiler;\nexports.isStrictMode = isStrictMode;\nexports.isSuspense = isSuspense;\nexports.isSuspenseList = isSuspenseList;\nexports.isValidElementType = isValidElementType;\nexports.typeOf = typeOf;\n })();\n}\n","'use strict';\n\nif (process.env.NODE_ENV === 'production') {\n module.exports = require('./cjs/react-is.production.min.js');\n} else {\n module.exports = require('./cjs/react-is.development.js');\n}\n","import { ForwardRef, Memo } from 'react-is';\n\n// Simplified polyfill for IE11 support\n// https://github.com/JamesMGreene/Function.name/blob/58b314d4a983110c3682f1228f845d39ccca1817/Function.name.js#L3\nconst fnNameMatchRegex = /^\\s*function(?:\\s|\\s*\\/\\*.*\\*\\/\\s*)+([^(\\s/]*)\\s*/;\nexport function getFunctionName(fn) {\n const match = `${fn}`.match(fnNameMatchRegex);\n const name = match && match[1];\n return name || '';\n}\nfunction getFunctionComponentName(Component, fallback = '') {\n return Component.displayName || Component.name || getFunctionName(Component) || fallback;\n}\nfunction getWrappedName(outerType, innerType, wrapperName) {\n const functionName = getFunctionComponentName(innerType);\n return outerType.displayName || (functionName !== '' ? `${wrapperName}(${functionName})` : wrapperName);\n}\n\n/**\n * cherry-pick from\n * https://github.com/facebook/react/blob/769b1f270e1251d9dbdce0fcbd9e92e502d059b8/packages/shared/getComponentName.js\n * originally forked from recompose/getDisplayName with added IE11 support\n */\nexport default function getDisplayName(Component) {\n if (Component == null) {\n return undefined;\n }\n if (typeof Component === 'string') {\n return Component;\n }\n if (typeof Component === 'function') {\n return getFunctionComponentName(Component, 'Component');\n }\n\n // TypeScript can't have components as objects but they exist in the form of `memo` or `Suspense`\n if (typeof Component === 'object') {\n switch (Component.$$typeof) {\n case ForwardRef:\n return getWrappedName(Component, Component.render, 'ForwardRef');\n case Memo:\n return getWrappedName(Component, Component.type, 'memo');\n default:\n return undefined;\n }\n }\n return undefined;\n}","export default function HTMLElementType(props, propName, componentName, location, propFullName) {\n if (process.env.NODE_ENV === 'production') {\n return null;\n }\n const propValue = props[propName];\n const safePropName = propFullName || propName;\n if (propValue == null) {\n return null;\n }\n if (propValue && propValue.nodeType !== 1) {\n return new Error(`Invalid ${location} \\`${safePropName}\\` supplied to \\`${componentName}\\`. ` + `Expected an HTMLElement.`);\n }\n return null;\n}","import PropTypes from 'prop-types';\nconst refType = PropTypes.oneOfType([PropTypes.func, PropTypes.object]);\nexport default refType;","import _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\n// It should to be noted that this function isn't equivalent to `text-transform: capitalize`.\n//\n// A strict capitalization should uppercase the first letter of each word in the sentence.\n// We only handle the first word.\nexport default function capitalize(string) {\n if (typeof string !== 'string') {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: \\`capitalize(string)\\` expects a string argument.` : _formatMuiErrorMessage(7));\n }\n return string.charAt(0).toUpperCase() + string.slice(1);\n}","/**\n * Safe chained function.\n *\n * Will only create a new function if needed,\n * otherwise will pass back existing functions or null.\n */\nexport default function createChainedFunction(...funcs) {\n return funcs.reduce((acc, func) => {\n if (func == null) {\n return acc;\n }\n return function chainedFunction(...args) {\n acc.apply(this, args);\n func.apply(this, args);\n };\n }, () => {});\n}","// Corresponds to 10 frames at 60 Hz.\n// A few bytes payload overhead when lodash/debounce is ~3 kB and debounce ~300 B.\nexport default function debounce(func, wait = 166) {\n let timeout;\n function debounced(...args) {\n const later = () => {\n // @ts-ignore\n func.apply(this, args);\n };\n clearTimeout(timeout);\n timeout = setTimeout(later, wait);\n }\n debounced.clear = () => {\n clearTimeout(timeout);\n };\n return debounced;\n}","export default function deprecatedPropType(validator, reason) {\n if (process.env.NODE_ENV === 'production') {\n return () => null;\n }\n return (props, propName, componentName, location, propFullName) => {\n const componentNameSafe = componentName || '<>';\n const propFullNameSafe = propFullName || propName;\n if (typeof props[propName] !== 'undefined') {\n return new Error(`The ${location} \\`${propFullNameSafe}\\` of ` + `\\`${componentNameSafe}\\` is deprecated. ${reason}`);\n }\n return null;\n };\n}","import * as React from 'react';\nexport default function isMuiElement(element, muiNames) {\n var _muiName, _element$type;\n return /*#__PURE__*/React.isValidElement(element) && muiNames.indexOf( // For server components `muiName` is avaialble in element.type._payload.value.muiName\n // relevant info - https://github.com/facebook/react/blob/2807d781a08db8e9873687fccc25c0f12b4fb3d4/packages/react/src/ReactLazy.js#L45\n // eslint-disable-next-line no-underscore-dangle\n (_muiName = element.type.muiName) != null ? _muiName : (_element$type = element.type) == null || (_element$type = _element$type._payload) == null || (_element$type = _element$type.value) == null ? void 0 : _element$type.muiName) !== -1;\n}","export default function ownerDocument(node) {\n return node && node.ownerDocument || document;\n}","import ownerDocument from '../ownerDocument';\nexport default function ownerWindow(node) {\n const doc = ownerDocument(node);\n return doc.defaultView || window;\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nexport default function requirePropFactory(componentNameInError, Component) {\n if (process.env.NODE_ENV === 'production') {\n return () => null;\n }\n\n // eslint-disable-next-line react/forbid-foreign-prop-types\n const prevPropTypes = Component ? _extends({}, Component.propTypes) : null;\n const requireProp = requiredProp => (props, propName, componentName, location, propFullName, ...args) => {\n const propFullNameSafe = propFullName || propName;\n const defaultTypeChecker = prevPropTypes == null ? void 0 : prevPropTypes[propFullNameSafe];\n if (defaultTypeChecker) {\n const typeCheckerResult = defaultTypeChecker(props, propName, componentName, location, propFullName, ...args);\n if (typeCheckerResult) {\n return typeCheckerResult;\n }\n }\n if (typeof props[propName] !== 'undefined' && !props[requiredProp]) {\n return new Error(`The prop \\`${propFullNameSafe}\\` of ` + `\\`${componentNameInError}\\` can only be used together with the \\`${requiredProp}\\` prop.`);\n }\n return null;\n };\n return requireProp;\n}","/**\n * TODO v5: consider making it private\n *\n * passes {value} to {ref}\n *\n * WARNING: Be sure to only call this inside a callback that is passed as a ref.\n * Otherwise, make sure to cleanup the previous {ref} if it changes. See\n * https://github.com/mui/material-ui/issues/13539\n *\n * Useful if you want to expose the ref of an inner component to the public API\n * while still using it inside the component.\n * @param ref A ref callback or ref object. If anything falsy, this is a no-op.\n */\nexport default function setRef(ref, value) {\n if (typeof ref === 'function') {\n ref(value);\n } else if (ref) {\n ref.current = value;\n }\n}","'use client';\n\nimport * as React from 'react';\n\n/**\n * A version of `React.useLayoutEffect` that does not show a warning when server-side rendering.\n * This is useful for effects that are only needed for client-side rendering but not for SSR.\n *\n * Before you use this hook, make sure to read https://gist.github.com/gaearon/e7d97cdf38a2907924ea12e4ebdf3c85\n * and confirm it doesn't apply to your use-case.\n */\nconst useEnhancedEffect = typeof window !== 'undefined' ? React.useLayoutEffect : React.useEffect;\nexport default useEnhancedEffect;","'use client';\n\nimport * as React from 'react';\nlet globalId = 0;\nfunction useGlobalId(idOverride) {\n const [defaultId, setDefaultId] = React.useState(idOverride);\n const id = idOverride || defaultId;\n React.useEffect(() => {\n if (defaultId == null) {\n // Fallback to this default id when possible.\n // Use the incrementing value for client-side rendering only.\n // We can't use it server-side.\n // If you want to use random values please consider the Birthday Problem: https://en.wikipedia.org/wiki/Birthday_problem\n globalId += 1;\n setDefaultId(`mui-${globalId}`);\n }\n }, [defaultId]);\n return id;\n}\n\n// downstream bundlers may remove unnecessary concatenation, but won't remove toString call -- Workaround for https://github.com/webpack/webpack/issues/14814\nconst maybeReactUseId = React['useId'.toString()];\n/**\n *\n * @example
    \n * @param idOverride\n * @returns {string}\n */\nexport default function useId(idOverride) {\n if (maybeReactUseId !== undefined) {\n const reactId = maybeReactUseId();\n return idOverride != null ? idOverride : reactId;\n }\n // eslint-disable-next-line react-hooks/rules-of-hooks -- `React.useId` is invariant at runtime.\n return useGlobalId(idOverride);\n}","export default function unsupportedProp(props, propName, componentName, location, propFullName) {\n if (process.env.NODE_ENV === 'production') {\n return null;\n }\n const propFullNameSafe = propFullName || propName;\n if (typeof props[propName] !== 'undefined') {\n return new Error(`The prop \\`${propFullNameSafe}\\` is not supported. Please remove it.`);\n }\n return null;\n}","'use client';\n\n/* eslint-disable react-hooks/rules-of-hooks, react-hooks/exhaustive-deps */\nimport * as React from 'react';\nexport default function useControlled({\n controlled,\n default: defaultProp,\n name,\n state = 'value'\n}) {\n // isControlled is ignored in the hook dependency lists as it should never change.\n const {\n current: isControlled\n } = React.useRef(controlled !== undefined);\n const [valueState, setValue] = React.useState(defaultProp);\n const value = isControlled ? controlled : valueState;\n if (process.env.NODE_ENV !== 'production') {\n React.useEffect(() => {\n if (isControlled !== (controlled !== undefined)) {\n console.error([`MUI: A component is changing the ${isControlled ? '' : 'un'}controlled ${state} state of ${name} to be ${isControlled ? 'un' : ''}controlled.`, 'Elements should not switch from uncontrolled to controlled (or vice versa).', `Decide between using a controlled or uncontrolled ${name} ` + 'element for the lifetime of the component.', \"The nature of the state is determined during the first render. It's considered controlled if the value is not `undefined`.\", 'More info: https://fb.me/react-controlled-components'].join('\\n'));\n }\n }, [state, name, controlled]);\n const {\n current: defaultValue\n } = React.useRef(defaultProp);\n React.useEffect(() => {\n if (!isControlled && defaultValue !== defaultProp) {\n console.error([`MUI: A component is changing the default ${state} state of an uncontrolled ${name} after being initialized. ` + `To suppress this warning opt to use a controlled ${name}.`].join('\\n'));\n }\n }, [JSON.stringify(defaultProp)]);\n }\n const setValueIfUncontrolled = React.useCallback(newValue => {\n if (!isControlled) {\n setValue(newValue);\n }\n }, []);\n return [value, setValueIfUncontrolled];\n}","'use client';\n\nimport * as React from 'react';\nimport useEnhancedEffect from '../useEnhancedEffect';\n\n/**\n * Inspired by https://github.com/facebook/react/issues/14099#issuecomment-440013892\n * See RFC in https://github.com/reactjs/rfcs/pull/220\n */\n\nfunction useEventCallback(fn) {\n const ref = React.useRef(fn);\n useEnhancedEffect(() => {\n ref.current = fn;\n });\n return React.useRef((...args) =>\n // @ts-expect-error hide `this`\n (0, ref.current)(...args)).current;\n}\nexport default useEventCallback;","'use client';\n\nimport * as React from 'react';\nimport setRef from '../setRef';\nexport default function useForkRef(...refs) {\n /**\n * This will create a new function if the refs passed to this hook change and are all defined.\n * This means react will call the old forkRef with `null` and the new forkRef\n * with the ref. Cleanup naturally emerges from this behavior.\n */\n return React.useMemo(() => {\n if (refs.every(ref => ref == null)) {\n return null;\n }\n return instance => {\n refs.forEach(ref => {\n setRef(ref, instance);\n });\n };\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, refs);\n}","'use client';\n\nimport * as React from 'react';\nconst UNINITIALIZED = {};\n\n/**\n * A React.useRef() that is initialized lazily with a function. Note that it accepts an optional\n * initialization argument, so the initialization function doesn't need to be an inline closure.\n *\n * @usage\n * const ref = useLazyRef(sortColumns, columns)\n */\nexport default function useLazyRef(init, initArg) {\n const ref = React.useRef(UNINITIALIZED);\n if (ref.current === UNINITIALIZED) {\n ref.current = init(initArg);\n }\n return ref;\n}","'use client';\n\nimport * as React from 'react';\nconst EMPTY = [];\n\n/**\n * A React.useEffect equivalent that runs once, when the component is mounted.\n */\nexport default function useOnMount(fn) {\n /* eslint-disable react-hooks/exhaustive-deps */\n React.useEffect(fn, EMPTY);\n /* eslint-enable react-hooks/exhaustive-deps */\n}","'use client';\n\nimport useLazyRef from '../useLazyRef/useLazyRef';\nimport useOnMount from '../useOnMount/useOnMount';\nexport class Timeout {\n constructor() {\n this.currentId = null;\n this.clear = () => {\n if (this.currentId !== null) {\n clearTimeout(this.currentId);\n this.currentId = null;\n }\n };\n this.disposeEffect = () => {\n return this.clear;\n };\n }\n static create() {\n return new Timeout();\n }\n /**\n * Executes `fn` after `delay`, clearing any previously scheduled call.\n */\n start(delay, fn) {\n this.clear();\n this.currentId = setTimeout(() => {\n this.currentId = null;\n fn();\n }, delay);\n }\n}\nexport default function useTimeout() {\n const timeout = useLazyRef(Timeout.create).current;\n useOnMount(timeout.disposeEffect);\n return timeout;\n}","'use client';\n\n// based on https://github.com/WICG/focus-visible/blob/v4.1.5/src/focus-visible.js\nimport * as React from 'react';\nimport { Timeout } from '../useTimeout/useTimeout';\nlet hadKeyboardEvent = true;\nlet hadFocusVisibleRecently = false;\nconst hadFocusVisibleRecentlyTimeout = new Timeout();\nconst inputTypesWhitelist = {\n text: true,\n search: true,\n url: true,\n tel: true,\n email: true,\n password: true,\n number: true,\n date: true,\n month: true,\n week: true,\n time: true,\n datetime: true,\n 'datetime-local': true\n};\n\n/**\n * Computes whether the given element should automatically trigger the\n * `focus-visible` class being added, i.e. whether it should always match\n * `:focus-visible` when focused.\n * @param {Element} node\n * @returns {boolean}\n */\nfunction focusTriggersKeyboardModality(node) {\n const {\n type,\n tagName\n } = node;\n if (tagName === 'INPUT' && inputTypesWhitelist[type] && !node.readOnly) {\n return true;\n }\n if (tagName === 'TEXTAREA' && !node.readOnly) {\n return true;\n }\n if (node.isContentEditable) {\n return true;\n }\n return false;\n}\n\n/**\n * Keep track of our keyboard modality state with `hadKeyboardEvent`.\n * If the most recent user interaction was via the keyboard;\n * and the key press did not include a meta, alt/option, or control key;\n * then the modality is keyboard. Otherwise, the modality is not keyboard.\n * @param {KeyboardEvent} event\n */\nfunction handleKeyDown(event) {\n if (event.metaKey || event.altKey || event.ctrlKey) {\n return;\n }\n hadKeyboardEvent = true;\n}\n\n/**\n * If at any point a user clicks with a pointing device, ensure that we change\n * the modality away from keyboard.\n * This avoids the situation where a user presses a key on an already focused\n * element, and then clicks on a different element, focusing it with a\n * pointing device, while we still think we're in keyboard modality.\n */\nfunction handlePointerDown() {\n hadKeyboardEvent = false;\n}\nfunction handleVisibilityChange() {\n if (this.visibilityState === 'hidden') {\n // If the tab becomes active again, the browser will handle calling focus\n // on the element (Safari actually calls it twice).\n // If this tab change caused a blur on an element with focus-visible,\n // re-apply the class when the user switches back to the tab.\n if (hadFocusVisibleRecently) {\n hadKeyboardEvent = true;\n }\n }\n}\nfunction prepare(doc) {\n doc.addEventListener('keydown', handleKeyDown, true);\n doc.addEventListener('mousedown', handlePointerDown, true);\n doc.addEventListener('pointerdown', handlePointerDown, true);\n doc.addEventListener('touchstart', handlePointerDown, true);\n doc.addEventListener('visibilitychange', handleVisibilityChange, true);\n}\nexport function teardown(doc) {\n doc.removeEventListener('keydown', handleKeyDown, true);\n doc.removeEventListener('mousedown', handlePointerDown, true);\n doc.removeEventListener('pointerdown', handlePointerDown, true);\n doc.removeEventListener('touchstart', handlePointerDown, true);\n doc.removeEventListener('visibilitychange', handleVisibilityChange, true);\n}\nfunction isFocusVisible(event) {\n const {\n target\n } = event;\n try {\n return target.matches(':focus-visible');\n } catch (error) {\n // Browsers not implementing :focus-visible will throw a SyntaxError.\n // We use our own heuristic for those browsers.\n // Rethrow might be better if it's not the expected error but do we really\n // want to crash if focus-visible malfunctioned?\n }\n\n // No need for validFocusTarget check. The user does that by attaching it to\n // focusable events only.\n return hadKeyboardEvent || focusTriggersKeyboardModality(target);\n}\nexport default function useIsFocusVisible() {\n const ref = React.useCallback(node => {\n if (node != null) {\n prepare(node.ownerDocument);\n }\n }, []);\n const isFocusVisibleRef = React.useRef(false);\n\n /**\n * Should be called if a blur event is fired\n */\n function handleBlurVisible() {\n // checking against potential state variable does not suffice if we focus and blur synchronously.\n // React wouldn't have time to trigger a re-render so `focusVisible` would be stale.\n // Ideally we would adjust `isFocusVisible(event)` to look at `relatedTarget` for blur events.\n // This doesn't work in IE11 due to https://github.com/facebook/react/issues/3751\n // TODO: check again if React releases their internal changes to focus event handling (https://github.com/facebook/react/pull/19186).\n if (isFocusVisibleRef.current) {\n // To detect a tab/window switch, we look for a blur event followed\n // rapidly by a visibility change.\n // If we don't see a visibility change within 100ms, it's probably a\n // regular focus change.\n hadFocusVisibleRecently = true;\n hadFocusVisibleRecentlyTimeout.start(100, () => {\n hadFocusVisibleRecently = false;\n });\n isFocusVisibleRef.current = false;\n return true;\n }\n return false;\n }\n\n /**\n * Should be called if a blur event is fired\n */\n function handleFocusVisible(event) {\n if (isFocusVisible(event)) {\n isFocusVisibleRef.current = true;\n return true;\n }\n return false;\n }\n return {\n isFocusVisibleRef,\n onFocus: handleFocusVisible,\n onBlur: handleBlurVisible,\n ref\n };\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\n/**\n * Add keys, values of `defaultProps` that does not exist in `props`\n * @param {object} defaultProps\n * @param {object} props\n * @returns {object} resolved props\n */\nexport default function resolveProps(defaultProps, props) {\n const output = _extends({}, props);\n Object.keys(defaultProps).forEach(propName => {\n if (propName.toString().match(/^(components|slots)$/)) {\n output[propName] = _extends({}, defaultProps[propName], output[propName]);\n } else if (propName.toString().match(/^(componentsProps|slotProps)$/)) {\n const defaultSlotProps = defaultProps[propName] || {};\n const slotProps = props[propName];\n output[propName] = {};\n if (!slotProps || !Object.keys(slotProps)) {\n // Reduce the iteration if the slot props is empty\n output[propName] = defaultSlotProps;\n } else if (!defaultSlotProps || !Object.keys(defaultSlotProps)) {\n // Reduce the iteration if the default slot props is empty\n output[propName] = slotProps;\n } else {\n output[propName] = _extends({}, slotProps);\n Object.keys(defaultSlotProps).forEach(slotPropName => {\n output[propName][slotPropName] = resolveProps(defaultSlotProps[slotPropName], slotProps[slotPropName]);\n });\n }\n } else if (output[propName] === undefined) {\n output[propName] = defaultProps[propName];\n }\n });\n return output;\n}","export default function composeClasses(slots, getUtilityClass, classes = undefined) {\n const output = {};\n Object.keys(slots).forEach(\n // `Object.keys(slots)` can't be wider than `T` because we infer `T` from `slots`.\n // @ts-expect-error https://github.com/microsoft/TypeScript/pull/12253#issuecomment-263132208\n slot => {\n output[slot] = slots[slot].reduce((acc, key) => {\n if (key) {\n const utilityClass = getUtilityClass(key);\n if (utilityClass !== '') {\n acc.push(utilityClass);\n }\n if (classes && classes[key]) {\n acc.push(classes[key]);\n }\n }\n return acc;\n }, []).join(' ');\n });\n return output;\n}","const defaultGenerator = componentName => componentName;\nconst createClassNameGenerator = () => {\n let generate = defaultGenerator;\n return {\n configure(generator) {\n generate = generator;\n },\n generate(componentName) {\n return generate(componentName);\n },\n reset() {\n generate = defaultGenerator;\n }\n };\n};\nconst ClassNameGenerator = createClassNameGenerator();\nexport default ClassNameGenerator;","import ClassNameGenerator from '../ClassNameGenerator';\nexport const globalStateClasses = {\n active: 'active',\n checked: 'checked',\n completed: 'completed',\n disabled: 'disabled',\n error: 'error',\n expanded: 'expanded',\n focused: 'focused',\n focusVisible: 'focusVisible',\n open: 'open',\n readOnly: 'readOnly',\n required: 'required',\n selected: 'selected'\n};\nexport default function generateUtilityClass(componentName, slot, globalStatePrefix = 'Mui') {\n const globalStateClass = globalStateClasses[slot];\n return globalStateClass ? `${globalStatePrefix}-${globalStateClass}` : `${ClassNameGenerator.generate(componentName)}-${slot}`;\n}\nexport function isGlobalState(slot) {\n return globalStateClasses[slot] !== undefined;\n}","import generateUtilityClass from '../generateUtilityClass';\nexport default function generateUtilityClasses(componentName, slots, globalStatePrefix = 'Mui') {\n const result = {};\n slots.forEach(slot => {\n result[slot] = generateUtilityClass(componentName, slot, globalStatePrefix);\n });\n return result;\n}","function clamp(val, min = Number.MIN_SAFE_INTEGER, max = Number.MAX_SAFE_INTEGER) {\n return Math.max(min, Math.min(val, max));\n}\nexport default clamp;","export default function _objectWithoutPropertiesLoose(source, excluded) {\n if (source == null) return {};\n var target = {};\n var sourceKeys = Object.keys(source);\n var key, i;\n for (i = 0; i < sourceKeys.length; i++) {\n key = sourceKeys[i];\n if (excluded.indexOf(key) >= 0) continue;\n target[key] = source[key];\n }\n return target;\n}","import _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nconst _excluded = [\"values\", \"unit\", \"step\"];\n// Sorted ASC by size. That's important.\n// It can't be configured as it's used statically for propTypes.\nexport const breakpointKeys = ['xs', 'sm', 'md', 'lg', 'xl'];\nconst sortBreakpointsValues = values => {\n const breakpointsAsArray = Object.keys(values).map(key => ({\n key,\n val: values[key]\n })) || [];\n // Sort in ascending order\n breakpointsAsArray.sort((breakpoint1, breakpoint2) => breakpoint1.val - breakpoint2.val);\n return breakpointsAsArray.reduce((acc, obj) => {\n return _extends({}, acc, {\n [obj.key]: obj.val\n });\n }, {});\n};\n\n// Keep in mind that @media is inclusive by the CSS specification.\nexport default function createBreakpoints(breakpoints) {\n const {\n // The breakpoint **start** at this value.\n // For instance with the first breakpoint xs: [xs, sm).\n values = {\n xs: 0,\n // phone\n sm: 600,\n // tablet\n md: 900,\n // small laptop\n lg: 1200,\n // desktop\n xl: 1536 // large screen\n },\n unit = 'px',\n step = 5\n } = breakpoints,\n other = _objectWithoutPropertiesLoose(breakpoints, _excluded);\n const sortedValues = sortBreakpointsValues(values);\n const keys = Object.keys(sortedValues);\n function up(key) {\n const value = typeof values[key] === 'number' ? values[key] : key;\n return `@media (min-width:${value}${unit})`;\n }\n function down(key) {\n const value = typeof values[key] === 'number' ? values[key] : key;\n return `@media (max-width:${value - step / 100}${unit})`;\n }\n function between(start, end) {\n const endIndex = keys.indexOf(end);\n return `@media (min-width:${typeof values[start] === 'number' ? values[start] : start}${unit}) and ` + `(max-width:${(endIndex !== -1 && typeof values[keys[endIndex]] === 'number' ? values[keys[endIndex]] : end) - step / 100}${unit})`;\n }\n function only(key) {\n if (keys.indexOf(key) + 1 < keys.length) {\n return between(key, keys[keys.indexOf(key) + 1]);\n }\n return up(key);\n }\n function not(key) {\n // handle first and last key separately, for better readability\n const keyIndex = keys.indexOf(key);\n if (keyIndex === 0) {\n return up(keys[1]);\n }\n if (keyIndex === keys.length - 1) {\n return down(keys[keyIndex]);\n }\n return between(key, keys[keys.indexOf(key) + 1]).replace('@media', '@media not all and');\n }\n return _extends({\n keys,\n values: sortedValues,\n up,\n down,\n between,\n only,\n not,\n unit\n }, other);\n}","const shape = {\n borderRadius: 4\n};\nexport default shape;","import PropTypes from 'prop-types';\nconst responsivePropType = process.env.NODE_ENV !== 'production' ? PropTypes.oneOfType([PropTypes.number, PropTypes.string, PropTypes.object, PropTypes.array]) : {};\nexport default responsivePropType;","import deepmerge from '@mui/utils/deepmerge';\nfunction merge(acc, item) {\n if (!item) {\n return acc;\n }\n return deepmerge(acc, item, {\n clone: false // No need to clone deep, it's way faster.\n });\n}\nexport default merge;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport PropTypes from 'prop-types';\nimport deepmerge from '@mui/utils/deepmerge';\nimport merge from './merge';\n\n// The breakpoint **start** at this value.\n// For instance with the first breakpoint xs: [xs, sm[.\nexport const values = {\n xs: 0,\n // phone\n sm: 600,\n // tablet\n md: 900,\n // small laptop\n lg: 1200,\n // desktop\n xl: 1536 // large screen\n};\nconst defaultBreakpoints = {\n // Sorted ASC by size. That's important.\n // It can't be configured as it's used statically for propTypes.\n keys: ['xs', 'sm', 'md', 'lg', 'xl'],\n up: key => `@media (min-width:${values[key]}px)`\n};\nexport function handleBreakpoints(props, propValue, styleFromPropValue) {\n const theme = props.theme || {};\n if (Array.isArray(propValue)) {\n const themeBreakpoints = theme.breakpoints || defaultBreakpoints;\n return propValue.reduce((acc, item, index) => {\n acc[themeBreakpoints.up(themeBreakpoints.keys[index])] = styleFromPropValue(propValue[index]);\n return acc;\n }, {});\n }\n if (typeof propValue === 'object') {\n const themeBreakpoints = theme.breakpoints || defaultBreakpoints;\n return Object.keys(propValue).reduce((acc, breakpoint) => {\n // key is breakpoint\n if (Object.keys(themeBreakpoints.values || values).indexOf(breakpoint) !== -1) {\n const mediaKey = themeBreakpoints.up(breakpoint);\n acc[mediaKey] = styleFromPropValue(propValue[breakpoint], breakpoint);\n } else {\n const cssKey = breakpoint;\n acc[cssKey] = propValue[cssKey];\n }\n return acc;\n }, {});\n }\n const output = styleFromPropValue(propValue);\n return output;\n}\nfunction breakpoints(styleFunction) {\n // false positive\n // eslint-disable-next-line react/function-component-definition\n const newStyleFunction = props => {\n const theme = props.theme || {};\n const base = styleFunction(props);\n const themeBreakpoints = theme.breakpoints || defaultBreakpoints;\n const extended = themeBreakpoints.keys.reduce((acc, key) => {\n if (props[key]) {\n acc = acc || {};\n acc[themeBreakpoints.up(key)] = styleFunction(_extends({\n theme\n }, props[key]));\n }\n return acc;\n }, null);\n return merge(base, extended);\n };\n newStyleFunction.propTypes = process.env.NODE_ENV !== 'production' ? _extends({}, styleFunction.propTypes, {\n xs: PropTypes.object,\n sm: PropTypes.object,\n md: PropTypes.object,\n lg: PropTypes.object,\n xl: PropTypes.object\n }) : {};\n newStyleFunction.filterProps = ['xs', 'sm', 'md', 'lg', 'xl', ...styleFunction.filterProps];\n return newStyleFunction;\n}\nexport function createEmptyBreakpointObject(breakpointsInput = {}) {\n var _breakpointsInput$key;\n const breakpointsInOrder = (_breakpointsInput$key = breakpointsInput.keys) == null ? void 0 : _breakpointsInput$key.reduce((acc, key) => {\n const breakpointStyleKey = breakpointsInput.up(key);\n acc[breakpointStyleKey] = {};\n return acc;\n }, {});\n return breakpointsInOrder || {};\n}\nexport function removeUnusedBreakpoints(breakpointKeys, style) {\n return breakpointKeys.reduce((acc, key) => {\n const breakpointOutput = acc[key];\n const isBreakpointUnused = !breakpointOutput || Object.keys(breakpointOutput).length === 0;\n if (isBreakpointUnused) {\n delete acc[key];\n }\n return acc;\n }, style);\n}\nexport function mergeBreakpointsInOrder(breakpointsInput, ...styles) {\n const emptyBreakpoints = createEmptyBreakpointObject(breakpointsInput);\n const mergedOutput = [emptyBreakpoints, ...styles].reduce((prev, next) => deepmerge(prev, next), {});\n return removeUnusedBreakpoints(Object.keys(emptyBreakpoints), mergedOutput);\n}\n\n// compute base for responsive values; e.g.,\n// [1,2,3] => {xs: true, sm: true, md: true}\n// {xs: 1, sm: 2, md: 3} => {xs: true, sm: true, md: true}\nexport function computeBreakpointsBase(breakpointValues, themeBreakpoints) {\n // fixed value\n if (typeof breakpointValues !== 'object') {\n return {};\n }\n const base = {};\n const breakpointsKeys = Object.keys(themeBreakpoints);\n if (Array.isArray(breakpointValues)) {\n breakpointsKeys.forEach((breakpoint, i) => {\n if (i < breakpointValues.length) {\n base[breakpoint] = true;\n }\n });\n } else {\n breakpointsKeys.forEach(breakpoint => {\n if (breakpointValues[breakpoint] != null) {\n base[breakpoint] = true;\n }\n });\n }\n return base;\n}\nexport function resolveBreakpointValues({\n values: breakpointValues,\n breakpoints: themeBreakpoints,\n base: customBase\n}) {\n const base = customBase || computeBreakpointsBase(breakpointValues, themeBreakpoints);\n const keys = Object.keys(base);\n if (keys.length === 0) {\n return breakpointValues;\n }\n let previous;\n return keys.reduce((acc, breakpoint, i) => {\n if (Array.isArray(breakpointValues)) {\n acc[breakpoint] = breakpointValues[i] != null ? breakpointValues[i] : breakpointValues[previous];\n previous = i;\n } else if (typeof breakpointValues === 'object') {\n acc[breakpoint] = breakpointValues[breakpoint] != null ? breakpointValues[breakpoint] : breakpointValues[previous];\n previous = breakpoint;\n } else {\n acc[breakpoint] = breakpointValues;\n }\n return acc;\n }, {});\n}\nexport default breakpoints;","import capitalize from '@mui/utils/capitalize';\nimport responsivePropType from './responsivePropType';\nimport { handleBreakpoints } from './breakpoints';\nexport function getPath(obj, path, checkVars = true) {\n if (!path || typeof path !== 'string') {\n return null;\n }\n\n // Check if CSS variables are used\n if (obj && obj.vars && checkVars) {\n const val = `vars.${path}`.split('.').reduce((acc, item) => acc && acc[item] ? acc[item] : null, obj);\n if (val != null) {\n return val;\n }\n }\n return path.split('.').reduce((acc, item) => {\n if (acc && acc[item] != null) {\n return acc[item];\n }\n return null;\n }, obj);\n}\nexport function getStyleValue(themeMapping, transform, propValueFinal, userValue = propValueFinal) {\n let value;\n if (typeof themeMapping === 'function') {\n value = themeMapping(propValueFinal);\n } else if (Array.isArray(themeMapping)) {\n value = themeMapping[propValueFinal] || userValue;\n } else {\n value = getPath(themeMapping, propValueFinal) || userValue;\n }\n if (transform) {\n value = transform(value, userValue, themeMapping);\n }\n return value;\n}\nfunction style(options) {\n const {\n prop,\n cssProperty = options.prop,\n themeKey,\n transform\n } = options;\n\n // false positive\n // eslint-disable-next-line react/function-component-definition\n const fn = props => {\n if (props[prop] == null) {\n return null;\n }\n const propValue = props[prop];\n const theme = props.theme;\n const themeMapping = getPath(theme, themeKey) || {};\n const styleFromPropValue = propValueFinal => {\n let value = getStyleValue(themeMapping, transform, propValueFinal);\n if (propValueFinal === value && typeof propValueFinal === 'string') {\n // Haven't found value\n value = getStyleValue(themeMapping, transform, `${prop}${propValueFinal === 'default' ? '' : capitalize(propValueFinal)}`, propValueFinal);\n }\n if (cssProperty === false) {\n return value;\n }\n return {\n [cssProperty]: value\n };\n };\n return handleBreakpoints(props, propValue, styleFromPropValue);\n };\n fn.propTypes = process.env.NODE_ENV !== 'production' ? {\n [prop]: responsivePropType\n } : {};\n fn.filterProps = [prop];\n return fn;\n}\nexport default style;","export default function memoize(fn) {\n const cache = {};\n return arg => {\n if (cache[arg] === undefined) {\n cache[arg] = fn(arg);\n }\n return cache[arg];\n };\n}","import responsivePropType from './responsivePropType';\nimport { handleBreakpoints } from './breakpoints';\nimport { getPath } from './style';\nimport merge from './merge';\nimport memoize from './memoize';\nconst properties = {\n m: 'margin',\n p: 'padding'\n};\nconst directions = {\n t: 'Top',\n r: 'Right',\n b: 'Bottom',\n l: 'Left',\n x: ['Left', 'Right'],\n y: ['Top', 'Bottom']\n};\nconst aliases = {\n marginX: 'mx',\n marginY: 'my',\n paddingX: 'px',\n paddingY: 'py'\n};\n\n// memoize() impact:\n// From 300,000 ops/sec\n// To 350,000 ops/sec\nconst getCssProperties = memoize(prop => {\n // It's not a shorthand notation.\n if (prop.length > 2) {\n if (aliases[prop]) {\n prop = aliases[prop];\n } else {\n return [prop];\n }\n }\n const [a, b] = prop.split('');\n const property = properties[a];\n const direction = directions[b] || '';\n return Array.isArray(direction) ? direction.map(dir => property + dir) : [property + direction];\n});\nexport const marginKeys = ['m', 'mt', 'mr', 'mb', 'ml', 'mx', 'my', 'margin', 'marginTop', 'marginRight', 'marginBottom', 'marginLeft', 'marginX', 'marginY', 'marginInline', 'marginInlineStart', 'marginInlineEnd', 'marginBlock', 'marginBlockStart', 'marginBlockEnd'];\nexport const paddingKeys = ['p', 'pt', 'pr', 'pb', 'pl', 'px', 'py', 'padding', 'paddingTop', 'paddingRight', 'paddingBottom', 'paddingLeft', 'paddingX', 'paddingY', 'paddingInline', 'paddingInlineStart', 'paddingInlineEnd', 'paddingBlock', 'paddingBlockStart', 'paddingBlockEnd'];\nconst spacingKeys = [...marginKeys, ...paddingKeys];\nexport function createUnaryUnit(theme, themeKey, defaultValue, propName) {\n var _getPath;\n const themeSpacing = (_getPath = getPath(theme, themeKey, false)) != null ? _getPath : defaultValue;\n if (typeof themeSpacing === 'number') {\n return abs => {\n if (typeof abs === 'string') {\n return abs;\n }\n if (process.env.NODE_ENV !== 'production') {\n if (typeof abs !== 'number') {\n console.error(`MUI: Expected ${propName} argument to be a number or a string, got ${abs}.`);\n }\n }\n return themeSpacing * abs;\n };\n }\n if (Array.isArray(themeSpacing)) {\n return abs => {\n if (typeof abs === 'string') {\n return abs;\n }\n if (process.env.NODE_ENV !== 'production') {\n if (!Number.isInteger(abs)) {\n console.error([`MUI: The \\`theme.${themeKey}\\` array type cannot be combined with non integer values.` + `You should either use an integer value that can be used as index, or define the \\`theme.${themeKey}\\` as a number.`].join('\\n'));\n } else if (abs > themeSpacing.length - 1) {\n console.error([`MUI: The value provided (${abs}) overflows.`, `The supported values are: ${JSON.stringify(themeSpacing)}.`, `${abs} > ${themeSpacing.length - 1}, you need to add the missing values.`].join('\\n'));\n }\n }\n return themeSpacing[abs];\n };\n }\n if (typeof themeSpacing === 'function') {\n return themeSpacing;\n }\n if (process.env.NODE_ENV !== 'production') {\n console.error([`MUI: The \\`theme.${themeKey}\\` value (${themeSpacing}) is invalid.`, 'It should be a number, an array or a function.'].join('\\n'));\n }\n return () => undefined;\n}\nexport function createUnarySpacing(theme) {\n return createUnaryUnit(theme, 'spacing', 8, 'spacing');\n}\nexport function getValue(transformer, propValue) {\n if (typeof propValue === 'string' || propValue == null) {\n return propValue;\n }\n const abs = Math.abs(propValue);\n const transformed = transformer(abs);\n if (propValue >= 0) {\n return transformed;\n }\n if (typeof transformed === 'number') {\n return -transformed;\n }\n return `-${transformed}`;\n}\nexport function getStyleFromPropValue(cssProperties, transformer) {\n return propValue => cssProperties.reduce((acc, cssProperty) => {\n acc[cssProperty] = getValue(transformer, propValue);\n return acc;\n }, {});\n}\nfunction resolveCssProperty(props, keys, prop, transformer) {\n // Using a hash computation over an array iteration could be faster, but with only 28 items,\n // it's doesn't worth the bundle size.\n if (keys.indexOf(prop) === -1) {\n return null;\n }\n const cssProperties = getCssProperties(prop);\n const styleFromPropValue = getStyleFromPropValue(cssProperties, transformer);\n const propValue = props[prop];\n return handleBreakpoints(props, propValue, styleFromPropValue);\n}\nfunction style(props, keys) {\n const transformer = createUnarySpacing(props.theme);\n return Object.keys(props).map(prop => resolveCssProperty(props, keys, prop, transformer)).reduce(merge, {});\n}\nexport function margin(props) {\n return style(props, marginKeys);\n}\nmargin.propTypes = process.env.NODE_ENV !== 'production' ? marginKeys.reduce((obj, key) => {\n obj[key] = responsivePropType;\n return obj;\n}, {}) : {};\nmargin.filterProps = marginKeys;\nexport function padding(props) {\n return style(props, paddingKeys);\n}\npadding.propTypes = process.env.NODE_ENV !== 'production' ? paddingKeys.reduce((obj, key) => {\n obj[key] = responsivePropType;\n return obj;\n}, {}) : {};\npadding.filterProps = paddingKeys;\nfunction spacing(props) {\n return style(props, spacingKeys);\n}\nspacing.propTypes = process.env.NODE_ENV !== 'production' ? spacingKeys.reduce((obj, key) => {\n obj[key] = responsivePropType;\n return obj;\n}, {}) : {};\nspacing.filterProps = spacingKeys;\nexport default spacing;","import { createUnarySpacing } from '../spacing';\n\n// The different signatures imply different meaning for their arguments that can't be expressed structurally.\n// We express the difference with variable names.\n\nexport default function createSpacing(spacingInput = 8) {\n // Already transformed.\n if (spacingInput.mui) {\n return spacingInput;\n }\n\n // Material Design layouts are visually balanced. Most measurements align to an 8dp grid, which aligns both spacing and the overall layout.\n // Smaller components, such as icons, can align to a 4dp grid.\n // https://m2.material.io/design/layout/understanding-layout.html\n const transform = createUnarySpacing({\n spacing: spacingInput\n });\n const spacing = (...argsInput) => {\n if (process.env.NODE_ENV !== 'production') {\n if (!(argsInput.length <= 4)) {\n console.error(`MUI: Too many arguments provided, expected between 0 and 4, got ${argsInput.length}`);\n }\n }\n const args = argsInput.length === 0 ? [1] : argsInput;\n return args.map(argument => {\n const output = transform(argument);\n return typeof output === 'number' ? `${output}px` : output;\n }).join(' ');\n };\n spacing.mui = true;\n return spacing;\n}","import merge from './merge';\nfunction compose(...styles) {\n const handlers = styles.reduce((acc, style) => {\n style.filterProps.forEach(prop => {\n acc[prop] = style;\n });\n return acc;\n }, {});\n\n // false positive\n // eslint-disable-next-line react/function-component-definition\n const fn = props => {\n return Object.keys(props).reduce((acc, prop) => {\n if (handlers[prop]) {\n return merge(acc, handlers[prop](props));\n }\n return acc;\n }, {});\n };\n fn.propTypes = process.env.NODE_ENV !== 'production' ? styles.reduce((acc, style) => Object.assign(acc, style.propTypes), {}) : {};\n fn.filterProps = styles.reduce((acc, style) => acc.concat(style.filterProps), []);\n return fn;\n}\nexport default compose;","import responsivePropType from './responsivePropType';\nimport style from './style';\nimport compose from './compose';\nimport { createUnaryUnit, getValue } from './spacing';\nimport { handleBreakpoints } from './breakpoints';\nexport function borderTransform(value) {\n if (typeof value !== 'number') {\n return value;\n }\n return `${value}px solid`;\n}\nfunction createBorderStyle(prop, transform) {\n return style({\n prop,\n themeKey: 'borders',\n transform\n });\n}\nexport const border = createBorderStyle('border', borderTransform);\nexport const borderTop = createBorderStyle('borderTop', borderTransform);\nexport const borderRight = createBorderStyle('borderRight', borderTransform);\nexport const borderBottom = createBorderStyle('borderBottom', borderTransform);\nexport const borderLeft = createBorderStyle('borderLeft', borderTransform);\nexport const borderColor = createBorderStyle('borderColor');\nexport const borderTopColor = createBorderStyle('borderTopColor');\nexport const borderRightColor = createBorderStyle('borderRightColor');\nexport const borderBottomColor = createBorderStyle('borderBottomColor');\nexport const borderLeftColor = createBorderStyle('borderLeftColor');\nexport const outline = createBorderStyle('outline', borderTransform);\nexport const outlineColor = createBorderStyle('outlineColor');\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const borderRadius = props => {\n if (props.borderRadius !== undefined && props.borderRadius !== null) {\n const transformer = createUnaryUnit(props.theme, 'shape.borderRadius', 4, 'borderRadius');\n const styleFromPropValue = propValue => ({\n borderRadius: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.borderRadius, styleFromPropValue);\n }\n return null;\n};\nborderRadius.propTypes = process.env.NODE_ENV !== 'production' ? {\n borderRadius: responsivePropType\n} : {};\nborderRadius.filterProps = ['borderRadius'];\nconst borders = compose(border, borderTop, borderRight, borderBottom, borderLeft, borderColor, borderTopColor, borderRightColor, borderBottomColor, borderLeftColor, borderRadius, outline, outlineColor);\nexport default borders;","import style from './style';\nimport compose from './compose';\nimport { createUnaryUnit, getValue } from './spacing';\nimport { handleBreakpoints } from './breakpoints';\nimport responsivePropType from './responsivePropType';\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const gap = props => {\n if (props.gap !== undefined && props.gap !== null) {\n const transformer = createUnaryUnit(props.theme, 'spacing', 8, 'gap');\n const styleFromPropValue = propValue => ({\n gap: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.gap, styleFromPropValue);\n }\n return null;\n};\ngap.propTypes = process.env.NODE_ENV !== 'production' ? {\n gap: responsivePropType\n} : {};\ngap.filterProps = ['gap'];\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const columnGap = props => {\n if (props.columnGap !== undefined && props.columnGap !== null) {\n const transformer = createUnaryUnit(props.theme, 'spacing', 8, 'columnGap');\n const styleFromPropValue = propValue => ({\n columnGap: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.columnGap, styleFromPropValue);\n }\n return null;\n};\ncolumnGap.propTypes = process.env.NODE_ENV !== 'production' ? {\n columnGap: responsivePropType\n} : {};\ncolumnGap.filterProps = ['columnGap'];\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const rowGap = props => {\n if (props.rowGap !== undefined && props.rowGap !== null) {\n const transformer = createUnaryUnit(props.theme, 'spacing', 8, 'rowGap');\n const styleFromPropValue = propValue => ({\n rowGap: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.rowGap, styleFromPropValue);\n }\n return null;\n};\nrowGap.propTypes = process.env.NODE_ENV !== 'production' ? {\n rowGap: responsivePropType\n} : {};\nrowGap.filterProps = ['rowGap'];\nexport const gridColumn = style({\n prop: 'gridColumn'\n});\nexport const gridRow = style({\n prop: 'gridRow'\n});\nexport const gridAutoFlow = style({\n prop: 'gridAutoFlow'\n});\nexport const gridAutoColumns = style({\n prop: 'gridAutoColumns'\n});\nexport const gridAutoRows = style({\n prop: 'gridAutoRows'\n});\nexport const gridTemplateColumns = style({\n prop: 'gridTemplateColumns'\n});\nexport const gridTemplateRows = style({\n prop: 'gridTemplateRows'\n});\nexport const gridTemplateAreas = style({\n prop: 'gridTemplateAreas'\n});\nexport const gridArea = style({\n prop: 'gridArea'\n});\nconst grid = compose(gap, columnGap, rowGap, gridColumn, gridRow, gridAutoFlow, gridAutoColumns, gridAutoRows, gridTemplateColumns, gridTemplateRows, gridTemplateAreas, gridArea);\nexport default grid;","import style from './style';\nimport compose from './compose';\nexport function paletteTransform(value, userValue) {\n if (userValue === 'grey') {\n return userValue;\n }\n return value;\n}\nexport const color = style({\n prop: 'color',\n themeKey: 'palette',\n transform: paletteTransform\n});\nexport const bgcolor = style({\n prop: 'bgcolor',\n cssProperty: 'backgroundColor',\n themeKey: 'palette',\n transform: paletteTransform\n});\nexport const backgroundColor = style({\n prop: 'backgroundColor',\n themeKey: 'palette',\n transform: paletteTransform\n});\nconst palette = compose(color, bgcolor, backgroundColor);\nexport default palette;","import style from './style';\nimport compose from './compose';\nimport { handleBreakpoints, values as breakpointsValues } from './breakpoints';\nexport function sizingTransform(value) {\n return value <= 1 && value !== 0 ? `${value * 100}%` : value;\n}\nexport const width = style({\n prop: 'width',\n transform: sizingTransform\n});\nexport const maxWidth = props => {\n if (props.maxWidth !== undefined && props.maxWidth !== null) {\n const styleFromPropValue = propValue => {\n var _props$theme, _props$theme2;\n const breakpoint = ((_props$theme = props.theme) == null || (_props$theme = _props$theme.breakpoints) == null || (_props$theme = _props$theme.values) == null ? void 0 : _props$theme[propValue]) || breakpointsValues[propValue];\n if (!breakpoint) {\n return {\n maxWidth: sizingTransform(propValue)\n };\n }\n if (((_props$theme2 = props.theme) == null || (_props$theme2 = _props$theme2.breakpoints) == null ? void 0 : _props$theme2.unit) !== 'px') {\n return {\n maxWidth: `${breakpoint}${props.theme.breakpoints.unit}`\n };\n }\n return {\n maxWidth: breakpoint\n };\n };\n return handleBreakpoints(props, props.maxWidth, styleFromPropValue);\n }\n return null;\n};\nmaxWidth.filterProps = ['maxWidth'];\nexport const minWidth = style({\n prop: 'minWidth',\n transform: sizingTransform\n});\nexport const height = style({\n prop: 'height',\n transform: sizingTransform\n});\nexport const maxHeight = style({\n prop: 'maxHeight',\n transform: sizingTransform\n});\nexport const minHeight = style({\n prop: 'minHeight',\n transform: sizingTransform\n});\nexport const sizeWidth = style({\n prop: 'size',\n cssProperty: 'width',\n transform: sizingTransform\n});\nexport const sizeHeight = style({\n prop: 'size',\n cssProperty: 'height',\n transform: sizingTransform\n});\nexport const boxSizing = style({\n prop: 'boxSizing'\n});\nconst sizing = compose(width, maxWidth, minWidth, height, maxHeight, minHeight, boxSizing);\nexport default sizing;","import { padding, margin } from '../spacing';\nimport { borderRadius, borderTransform } from '../borders';\nimport { gap, rowGap, columnGap } from '../cssGrid';\nimport { paletteTransform } from '../palette';\nimport { maxWidth, sizingTransform } from '../sizing';\nconst defaultSxConfig = {\n // borders\n border: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderTop: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderRight: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderBottom: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderLeft: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderColor: {\n themeKey: 'palette'\n },\n borderTopColor: {\n themeKey: 'palette'\n },\n borderRightColor: {\n themeKey: 'palette'\n },\n borderBottomColor: {\n themeKey: 'palette'\n },\n borderLeftColor: {\n themeKey: 'palette'\n },\n outline: {\n themeKey: 'borders',\n transform: borderTransform\n },\n outlineColor: {\n themeKey: 'palette'\n },\n borderRadius: {\n themeKey: 'shape.borderRadius',\n style: borderRadius\n },\n // palette\n color: {\n themeKey: 'palette',\n transform: paletteTransform\n },\n bgcolor: {\n themeKey: 'palette',\n cssProperty: 'backgroundColor',\n transform: paletteTransform\n },\n backgroundColor: {\n themeKey: 'palette',\n transform: paletteTransform\n },\n // spacing\n p: {\n style: padding\n },\n pt: {\n style: padding\n },\n pr: {\n style: padding\n },\n pb: {\n style: padding\n },\n pl: {\n style: padding\n },\n px: {\n style: padding\n },\n py: {\n style: padding\n },\n padding: {\n style: padding\n },\n paddingTop: {\n style: padding\n },\n paddingRight: {\n style: padding\n },\n paddingBottom: {\n style: padding\n },\n paddingLeft: {\n style: padding\n },\n paddingX: {\n style: padding\n },\n paddingY: {\n style: padding\n },\n paddingInline: {\n style: padding\n },\n paddingInlineStart: {\n style: padding\n },\n paddingInlineEnd: {\n style: padding\n },\n paddingBlock: {\n style: padding\n },\n paddingBlockStart: {\n style: padding\n },\n paddingBlockEnd: {\n style: padding\n },\n m: {\n style: margin\n },\n mt: {\n style: margin\n },\n mr: {\n style: margin\n },\n mb: {\n style: margin\n },\n ml: {\n style: margin\n },\n mx: {\n style: margin\n },\n my: {\n style: margin\n },\n margin: {\n style: margin\n },\n marginTop: {\n style: margin\n },\n marginRight: {\n style: margin\n },\n marginBottom: {\n style: margin\n },\n marginLeft: {\n style: margin\n },\n marginX: {\n style: margin\n },\n marginY: {\n style: margin\n },\n marginInline: {\n style: margin\n },\n marginInlineStart: {\n style: margin\n },\n marginInlineEnd: {\n style: margin\n },\n marginBlock: {\n style: margin\n },\n marginBlockStart: {\n style: margin\n },\n marginBlockEnd: {\n style: margin\n },\n // display\n displayPrint: {\n cssProperty: false,\n transform: value => ({\n '@media print': {\n display: value\n }\n })\n },\n display: {},\n overflow: {},\n textOverflow: {},\n visibility: {},\n whiteSpace: {},\n // flexbox\n flexBasis: {},\n flexDirection: {},\n flexWrap: {},\n justifyContent: {},\n alignItems: {},\n alignContent: {},\n order: {},\n flex: {},\n flexGrow: {},\n flexShrink: {},\n alignSelf: {},\n justifyItems: {},\n justifySelf: {},\n // grid\n gap: {\n style: gap\n },\n rowGap: {\n style: rowGap\n },\n columnGap: {\n style: columnGap\n },\n gridColumn: {},\n gridRow: {},\n gridAutoFlow: {},\n gridAutoColumns: {},\n gridAutoRows: {},\n gridTemplateColumns: {},\n gridTemplateRows: {},\n gridTemplateAreas: {},\n gridArea: {},\n // positions\n position: {},\n zIndex: {\n themeKey: 'zIndex'\n },\n top: {},\n right: {},\n bottom: {},\n left: {},\n // shadows\n boxShadow: {\n themeKey: 'shadows'\n },\n // sizing\n width: {\n transform: sizingTransform\n },\n maxWidth: {\n style: maxWidth\n },\n minWidth: {\n transform: sizingTransform\n },\n height: {\n transform: sizingTransform\n },\n maxHeight: {\n transform: sizingTransform\n },\n minHeight: {\n transform: sizingTransform\n },\n boxSizing: {},\n // typography\n fontFamily: {\n themeKey: 'typography'\n },\n fontSize: {\n themeKey: 'typography'\n },\n fontStyle: {\n themeKey: 'typography'\n },\n fontWeight: {\n themeKey: 'typography'\n },\n letterSpacing: {},\n textTransform: {},\n lineHeight: {},\n textAlign: {},\n typography: {\n cssProperty: false,\n themeKey: 'typography'\n }\n};\nexport default defaultSxConfig;","import capitalize from '@mui/utils/capitalize';\nimport merge from '../merge';\nimport { getPath, getStyleValue as getValue } from '../style';\nimport { handleBreakpoints, createEmptyBreakpointObject, removeUnusedBreakpoints } from '../breakpoints';\nimport defaultSxConfig from './defaultSxConfig';\nfunction objectsHaveSameKeys(...objects) {\n const allKeys = objects.reduce((keys, object) => keys.concat(Object.keys(object)), []);\n const union = new Set(allKeys);\n return objects.every(object => union.size === Object.keys(object).length);\n}\nfunction callIfFn(maybeFn, arg) {\n return typeof maybeFn === 'function' ? maybeFn(arg) : maybeFn;\n}\n\n// eslint-disable-next-line @typescript-eslint/naming-convention\nexport function unstable_createStyleFunctionSx() {\n function getThemeValue(prop, val, theme, config) {\n const props = {\n [prop]: val,\n theme\n };\n const options = config[prop];\n if (!options) {\n return {\n [prop]: val\n };\n }\n const {\n cssProperty = prop,\n themeKey,\n transform,\n style\n } = options;\n if (val == null) {\n return null;\n }\n\n // TODO v6: remove, see https://github.com/mui/material-ui/pull/38123\n if (themeKey === 'typography' && val === 'inherit') {\n return {\n [prop]: val\n };\n }\n const themeMapping = getPath(theme, themeKey) || {};\n if (style) {\n return style(props);\n }\n const styleFromPropValue = propValueFinal => {\n let value = getValue(themeMapping, transform, propValueFinal);\n if (propValueFinal === value && typeof propValueFinal === 'string') {\n // Haven't found value\n value = getValue(themeMapping, transform, `${prop}${propValueFinal === 'default' ? '' : capitalize(propValueFinal)}`, propValueFinal);\n }\n if (cssProperty === false) {\n return value;\n }\n return {\n [cssProperty]: value\n };\n };\n return handleBreakpoints(props, val, styleFromPropValue);\n }\n function styleFunctionSx(props) {\n var _theme$unstable_sxCon;\n const {\n sx,\n theme = {}\n } = props || {};\n if (!sx) {\n return null; // Emotion & styled-components will neglect null\n }\n const config = (_theme$unstable_sxCon = theme.unstable_sxConfig) != null ? _theme$unstable_sxCon : defaultSxConfig;\n\n /*\n * Receive `sxInput` as object or callback\n * and then recursively check keys & values to create media query object styles.\n * (the result will be used in `styled`)\n */\n function traverse(sxInput) {\n let sxObject = sxInput;\n if (typeof sxInput === 'function') {\n sxObject = sxInput(theme);\n } else if (typeof sxInput !== 'object') {\n // value\n return sxInput;\n }\n if (!sxObject) {\n return null;\n }\n const emptyBreakpoints = createEmptyBreakpointObject(theme.breakpoints);\n const breakpointsKeys = Object.keys(emptyBreakpoints);\n let css = emptyBreakpoints;\n Object.keys(sxObject).forEach(styleKey => {\n const value = callIfFn(sxObject[styleKey], theme);\n if (value !== null && value !== undefined) {\n if (typeof value === 'object') {\n if (config[styleKey]) {\n css = merge(css, getThemeValue(styleKey, value, theme, config));\n } else {\n const breakpointsValues = handleBreakpoints({\n theme\n }, value, x => ({\n [styleKey]: x\n }));\n if (objectsHaveSameKeys(breakpointsValues, value)) {\n css[styleKey] = styleFunctionSx({\n sx: value,\n theme\n });\n } else {\n css = merge(css, breakpointsValues);\n }\n }\n } else {\n css = merge(css, getThemeValue(styleKey, value, theme, config));\n }\n }\n });\n return removeUnusedBreakpoints(breakpointsKeys, css);\n }\n return Array.isArray(sx) ? sx.map(traverse) : traverse(sx);\n }\n return styleFunctionSx;\n}\nconst styleFunctionSx = unstable_createStyleFunctionSx();\nstyleFunctionSx.filterProps = ['sx'];\nexport default styleFunctionSx;","/**\n * A universal utility to style components with multiple color modes. Always use it from the theme object.\n * It works with:\n * - [Basic theme](https://mui.com/material-ui/customization/dark-mode/)\n * - [CSS theme variables](https://mui.com/material-ui/experimental-api/css-theme-variables/overview/)\n * - Zero-runtime engine\n *\n * Tips: Use an array over object spread and place `theme.applyStyles()` last.\n *\n * ✅ [{ background: '#e5e5e5' }, theme.applyStyles('dark', { background: '#1c1c1c' })]\n *\n * 🚫 { background: '#e5e5e5', ...theme.applyStyles('dark', { background: '#1c1c1c' })}\n *\n * @example\n * 1. using with `styled`:\n * ```jsx\n * const Component = styled('div')(({ theme }) => [\n * { background: '#e5e5e5' },\n * theme.applyStyles('dark', {\n * background: '#1c1c1c',\n * color: '#fff',\n * }),\n * ]);\n * ```\n *\n * @example\n * 2. using with `sx` prop:\n * ```jsx\n * [\n * { background: '#e5e5e5' },\n * theme.applyStyles('dark', {\n * background: '#1c1c1c',\n * color: '#fff',\n * }),\n * ]}\n * />\n * ```\n *\n * @example\n * 3. theming a component:\n * ```jsx\n * extendTheme({\n * components: {\n * MuiButton: {\n * styleOverrides: {\n * root: ({ theme }) => [\n * { background: '#e5e5e5' },\n * theme.applyStyles('dark', {\n * background: '#1c1c1c',\n * color: '#fff',\n * }),\n * ],\n * },\n * }\n * }\n * })\n *```\n */\nexport default function applyStyles(key, styles) {\n // @ts-expect-error this is 'any' type\n const theme = this;\n if (theme.vars && typeof theme.getColorSchemeSelector === 'function') {\n // If CssVarsProvider is used as a provider,\n // returns '* :where([data-mui-color-scheme=\"light|dark\"]) &'\n const selector = theme.getColorSchemeSelector(key).replace(/(\\[[^\\]]+\\])/, '*:where($1)');\n return {\n [selector]: styles\n };\n }\n if (theme.palette.mode === key) {\n return styles;\n }\n return {};\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"breakpoints\", \"palette\", \"spacing\", \"shape\"];\nimport deepmerge from '@mui/utils/deepmerge';\nimport createBreakpoints from './createBreakpoints';\nimport shape from './shape';\nimport createSpacing from './createSpacing';\nimport styleFunctionSx from '../styleFunctionSx/styleFunctionSx';\nimport defaultSxConfig from '../styleFunctionSx/defaultSxConfig';\nimport applyStyles from './applyStyles';\nfunction createTheme(options = {}, ...args) {\n const {\n breakpoints: breakpointsInput = {},\n palette: paletteInput = {},\n spacing: spacingInput,\n shape: shapeInput = {}\n } = options,\n other = _objectWithoutPropertiesLoose(options, _excluded);\n const breakpoints = createBreakpoints(breakpointsInput);\n const spacing = createSpacing(spacingInput);\n let muiTheme = deepmerge({\n breakpoints,\n direction: 'ltr',\n components: {},\n // Inject component definitions.\n palette: _extends({\n mode: 'light'\n }, paletteInput),\n spacing,\n shape: _extends({}, shape, shapeInput)\n }, other);\n muiTheme.applyStyles = applyStyles;\n muiTheme = args.reduce((acc, argument) => deepmerge(acc, argument), muiTheme);\n muiTheme.unstable_sxConfig = _extends({}, defaultSxConfig, other == null ? void 0 : other.unstable_sxConfig);\n muiTheme.unstable_sx = function sx(props) {\n return styleFunctionSx({\n sx: props,\n theme: this\n });\n };\n return muiTheme;\n}\nexport default createTheme;","'use client';\n\nimport * as React from 'react';\nimport { ThemeContext } from '@mui/styled-engine';\nfunction isObjectEmpty(obj) {\n return Object.keys(obj).length === 0;\n}\nfunction useTheme(defaultTheme = null) {\n const contextTheme = React.useContext(ThemeContext);\n return !contextTheme || isObjectEmpty(contextTheme) ? defaultTheme : contextTheme;\n}\nexport default useTheme;","'use client';\n\nimport createTheme from './createTheme';\nimport useThemeWithoutDefault from './useThemeWithoutDefault';\nexport const systemDefaultTheme = createTheme();\nfunction useTheme(defaultTheme = systemDefaultTheme) {\n return useThemeWithoutDefault(defaultTheme);\n}\nexport default useTheme;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"ownerState\"],\n _excluded2 = [\"variants\"],\n _excluded3 = [\"name\", \"slot\", \"skipVariantsResolver\", \"skipSx\", \"overridesResolver\"];\n/* eslint-disable no-underscore-dangle */\nimport styledEngineStyled, { internal_processStyles as processStyles } from '@mui/styled-engine';\nimport { isPlainObject } from '@mui/utils/deepmerge';\nimport capitalize from '@mui/utils/capitalize';\nimport getDisplayName from '@mui/utils/getDisplayName';\nimport createTheme from './createTheme';\nimport styleFunctionSx from './styleFunctionSx';\nfunction isEmpty(obj) {\n return Object.keys(obj).length === 0;\n}\n\n// https://github.com/emotion-js/emotion/blob/26ded6109fcd8ca9875cc2ce4564fee678a3f3c5/packages/styled/src/utils.js#L40\nfunction isStringTag(tag) {\n return typeof tag === 'string' &&\n // 96 is one less than the char code\n // for \"a\" so this is checking that\n // it's a lowercase character\n tag.charCodeAt(0) > 96;\n}\n\n// Update /system/styled/#api in case if this changes\nexport function shouldForwardProp(prop) {\n return prop !== 'ownerState' && prop !== 'theme' && prop !== 'sx' && prop !== 'as';\n}\nexport const systemDefaultTheme = createTheme();\nconst lowercaseFirstLetter = string => {\n if (!string) {\n return string;\n }\n return string.charAt(0).toLowerCase() + string.slice(1);\n};\nfunction resolveTheme({\n defaultTheme,\n theme,\n themeId\n}) {\n return isEmpty(theme) ? defaultTheme : theme[themeId] || theme;\n}\nfunction defaultOverridesResolver(slot) {\n if (!slot) {\n return null;\n }\n return (props, styles) => styles[slot];\n}\nfunction processStyleArg(callableStyle, _ref) {\n let {\n ownerState\n } = _ref,\n props = _objectWithoutPropertiesLoose(_ref, _excluded);\n const resolvedStylesArg = typeof callableStyle === 'function' ? callableStyle(_extends({\n ownerState\n }, props)) : callableStyle;\n if (Array.isArray(resolvedStylesArg)) {\n return resolvedStylesArg.flatMap(resolvedStyle => processStyleArg(resolvedStyle, _extends({\n ownerState\n }, props)));\n }\n if (!!resolvedStylesArg && typeof resolvedStylesArg === 'object' && Array.isArray(resolvedStylesArg.variants)) {\n const {\n variants = []\n } = resolvedStylesArg,\n otherStyles = _objectWithoutPropertiesLoose(resolvedStylesArg, _excluded2);\n let result = otherStyles;\n variants.forEach(variant => {\n let isMatch = true;\n if (typeof variant.props === 'function') {\n isMatch = variant.props(_extends({\n ownerState\n }, props, ownerState));\n } else {\n Object.keys(variant.props).forEach(key => {\n if ((ownerState == null ? void 0 : ownerState[key]) !== variant.props[key] && props[key] !== variant.props[key]) {\n isMatch = false;\n }\n });\n }\n if (isMatch) {\n if (!Array.isArray(result)) {\n result = [result];\n }\n result.push(typeof variant.style === 'function' ? variant.style(_extends({\n ownerState\n }, props, ownerState)) : variant.style);\n }\n });\n return result;\n }\n return resolvedStylesArg;\n}\nexport default function createStyled(input = {}) {\n const {\n themeId,\n defaultTheme = systemDefaultTheme,\n rootShouldForwardProp = shouldForwardProp,\n slotShouldForwardProp = shouldForwardProp\n } = input;\n const systemSx = props => {\n return styleFunctionSx(_extends({}, props, {\n theme: resolveTheme(_extends({}, props, {\n defaultTheme,\n themeId\n }))\n }));\n };\n systemSx.__mui_systemSx = true;\n return (tag, inputOptions = {}) => {\n // Filter out the `sx` style function from the previous styled component to prevent unnecessary styles generated by the composite components.\n processStyles(tag, styles => styles.filter(style => !(style != null && style.__mui_systemSx)));\n const {\n name: componentName,\n slot: componentSlot,\n skipVariantsResolver: inputSkipVariantsResolver,\n skipSx: inputSkipSx,\n // TODO v6: remove `lowercaseFirstLetter()` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n overridesResolver = defaultOverridesResolver(lowercaseFirstLetter(componentSlot))\n } = inputOptions,\n options = _objectWithoutPropertiesLoose(inputOptions, _excluded3);\n\n // if skipVariantsResolver option is defined, take the value, otherwise, true for root and false for other slots.\n const skipVariantsResolver = inputSkipVariantsResolver !== undefined ? inputSkipVariantsResolver :\n // TODO v6: remove `Root` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n componentSlot && componentSlot !== 'Root' && componentSlot !== 'root' || false;\n const skipSx = inputSkipSx || false;\n let label;\n if (process.env.NODE_ENV !== 'production') {\n if (componentName) {\n // TODO v6: remove `lowercaseFirstLetter()` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n label = `${componentName}-${lowercaseFirstLetter(componentSlot || 'Root')}`;\n }\n }\n let shouldForwardPropOption = shouldForwardProp;\n\n // TODO v6: remove `Root` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n if (componentSlot === 'Root' || componentSlot === 'root') {\n shouldForwardPropOption = rootShouldForwardProp;\n } else if (componentSlot) {\n // any other slot specified\n shouldForwardPropOption = slotShouldForwardProp;\n } else if (isStringTag(tag)) {\n // for string (html) tag, preserve the behavior in emotion & styled-components.\n shouldForwardPropOption = undefined;\n }\n const defaultStyledResolver = styledEngineStyled(tag, _extends({\n shouldForwardProp: shouldForwardPropOption,\n label\n }, options));\n const transformStyleArg = stylesArg => {\n // On the server Emotion doesn't use React.forwardRef for creating components, so the created\n // component stays as a function. This condition makes sure that we do not interpolate functions\n // which are basically components used as a selectors.\n if (typeof stylesArg === 'function' && stylesArg.__emotion_real !== stylesArg || isPlainObject(stylesArg)) {\n return props => processStyleArg(stylesArg, _extends({}, props, {\n theme: resolveTheme({\n theme: props.theme,\n defaultTheme,\n themeId\n })\n }));\n }\n return stylesArg;\n };\n const muiStyledResolver = (styleArg, ...expressions) => {\n let transformedStyleArg = transformStyleArg(styleArg);\n const expressionsWithDefaultTheme = expressions ? expressions.map(transformStyleArg) : [];\n if (componentName && overridesResolver) {\n expressionsWithDefaultTheme.push(props => {\n const theme = resolveTheme(_extends({}, props, {\n defaultTheme,\n themeId\n }));\n if (!theme.components || !theme.components[componentName] || !theme.components[componentName].styleOverrides) {\n return null;\n }\n const styleOverrides = theme.components[componentName].styleOverrides;\n const resolvedStyleOverrides = {};\n // TODO: v7 remove iteration and use `resolveStyleArg(styleOverrides[slot])` directly\n Object.entries(styleOverrides).forEach(([slotKey, slotStyle]) => {\n resolvedStyleOverrides[slotKey] = processStyleArg(slotStyle, _extends({}, props, {\n theme\n }));\n });\n return overridesResolver(props, resolvedStyleOverrides);\n });\n }\n if (componentName && !skipVariantsResolver) {\n expressionsWithDefaultTheme.push(props => {\n var _theme$components;\n const theme = resolveTheme(_extends({}, props, {\n defaultTheme,\n themeId\n }));\n const themeVariants = theme == null || (_theme$components = theme.components) == null || (_theme$components = _theme$components[componentName]) == null ? void 0 : _theme$components.variants;\n return processStyleArg({\n variants: themeVariants\n }, _extends({}, props, {\n theme\n }));\n });\n }\n if (!skipSx) {\n expressionsWithDefaultTheme.push(systemSx);\n }\n const numOfCustomFnsApplied = expressionsWithDefaultTheme.length - expressions.length;\n if (Array.isArray(styleArg) && numOfCustomFnsApplied > 0) {\n const placeholders = new Array(numOfCustomFnsApplied).fill('');\n // If the type is array, than we need to add placeholders in the template for the overrides, variants and the sx styles.\n transformedStyleArg = [...styleArg, ...placeholders];\n transformedStyleArg.raw = [...styleArg.raw, ...placeholders];\n }\n const Component = defaultStyledResolver(transformedStyleArg, ...expressionsWithDefaultTheme);\n if (process.env.NODE_ENV !== 'production') {\n let displayName;\n if (componentName) {\n displayName = `${componentName}${capitalize(componentSlot || '')}`;\n }\n if (displayName === undefined) {\n displayName = `Styled(${getDisplayName(tag)})`;\n }\n Component.displayName = displayName;\n }\n if (tag.muiName) {\n Component.muiName = tag.muiName;\n }\n return Component;\n };\n if (defaultStyledResolver.withConfig) {\n muiStyledResolver.withConfig = defaultStyledResolver.withConfig;\n }\n return muiStyledResolver;\n };\n}","import resolveProps from '@mui/utils/resolveProps';\nexport default function getThemeProps(params) {\n const {\n theme,\n name,\n props\n } = params;\n if (!theme || !theme.components || !theme.components[name] || !theme.components[name].defaultProps) {\n return props;\n }\n return resolveProps(theme.components[name].defaultProps, props);\n}","'use client';\n\nimport getThemeProps from './getThemeProps';\nimport useTheme from '../useTheme';\nexport default function useThemeProps({\n props,\n name,\n defaultTheme,\n themeId\n}) {\n let theme = useTheme(defaultTheme);\n if (themeId) {\n theme = theme[themeId] || theme;\n }\n const mergedProps = getThemeProps({\n theme,\n name,\n props\n });\n return mergedProps;\n}","import _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\n/* eslint-disable @typescript-eslint/naming-convention */\nimport clamp from '@mui/utils/clamp';\n/**\n * Returns a number whose value is limited to the given range.\n * @param {number} value The value to be clamped\n * @param {number} min The lower boundary of the output range\n * @param {number} max The upper boundary of the output range\n * @returns {number} A number in the range [min, max]\n */\nfunction clampWrapper(value, min = 0, max = 1) {\n if (process.env.NODE_ENV !== 'production') {\n if (value < min || value > max) {\n console.error(`MUI: The value provided ${value} is out of range [${min}, ${max}].`);\n }\n }\n return clamp(value, min, max);\n}\n\n/**\n * Converts a color from CSS hex format to CSS rgb format.\n * @param {string} color - Hex color, i.e. #nnn or #nnnnnn\n * @returns {string} A CSS rgb color string\n */\nexport function hexToRgb(color) {\n color = color.slice(1);\n const re = new RegExp(`.{1,${color.length >= 6 ? 2 : 1}}`, 'g');\n let colors = color.match(re);\n if (colors && colors[0].length === 1) {\n colors = colors.map(n => n + n);\n }\n return colors ? `rgb${colors.length === 4 ? 'a' : ''}(${colors.map((n, index) => {\n return index < 3 ? parseInt(n, 16) : Math.round(parseInt(n, 16) / 255 * 1000) / 1000;\n }).join(', ')})` : '';\n}\nfunction intToHex(int) {\n const hex = int.toString(16);\n return hex.length === 1 ? `0${hex}` : hex;\n}\n\n/**\n * Returns an object with the type and values of a color.\n *\n * Note: Does not support rgb % values.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @returns {object} - A MUI color object: {type: string, values: number[]}\n */\nexport function decomposeColor(color) {\n // Idempotent\n if (color.type) {\n return color;\n }\n if (color.charAt(0) === '#') {\n return decomposeColor(hexToRgb(color));\n }\n const marker = color.indexOf('(');\n const type = color.substring(0, marker);\n if (['rgb', 'rgba', 'hsl', 'hsla', 'color'].indexOf(type) === -1) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: Unsupported \\`${color}\\` color.\nThe following formats are supported: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color().` : _formatMuiErrorMessage(9, color));\n }\n let values = color.substring(marker + 1, color.length - 1);\n let colorSpace;\n if (type === 'color') {\n values = values.split(' ');\n colorSpace = values.shift();\n if (values.length === 4 && values[3].charAt(0) === '/') {\n values[3] = values[3].slice(1);\n }\n if (['srgb', 'display-p3', 'a98-rgb', 'prophoto-rgb', 'rec-2020'].indexOf(colorSpace) === -1) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: unsupported \\`${colorSpace}\\` color space.\nThe following color spaces are supported: srgb, display-p3, a98-rgb, prophoto-rgb, rec-2020.` : _formatMuiErrorMessage(10, colorSpace));\n }\n } else {\n values = values.split(',');\n }\n values = values.map(value => parseFloat(value));\n return {\n type,\n values,\n colorSpace\n };\n}\n\n/**\n * Returns a channel created from the input color.\n *\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @returns {string} - The channel for the color, that can be used in rgba or hsla colors\n */\nexport const colorChannel = color => {\n const decomposedColor = decomposeColor(color);\n return decomposedColor.values.slice(0, 3).map((val, idx) => decomposedColor.type.indexOf('hsl') !== -1 && idx !== 0 ? `${val}%` : val).join(' ');\n};\nexport const private_safeColorChannel = (color, warning) => {\n try {\n return colorChannel(color);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n};\n\n/**\n * Converts a color object with type and values to a string.\n * @param {object} color - Decomposed color\n * @param {string} color.type - One of: 'rgb', 'rgba', 'hsl', 'hsla', 'color'\n * @param {array} color.values - [n,n,n] or [n,n,n,n]\n * @returns {string} A CSS color string\n */\nexport function recomposeColor(color) {\n const {\n type,\n colorSpace\n } = color;\n let {\n values\n } = color;\n if (type.indexOf('rgb') !== -1) {\n // Only convert the first 3 values to int (i.e. not alpha)\n values = values.map((n, i) => i < 3 ? parseInt(n, 10) : n);\n } else if (type.indexOf('hsl') !== -1) {\n values[1] = `${values[1]}%`;\n values[2] = `${values[2]}%`;\n }\n if (type.indexOf('color') !== -1) {\n values = `${colorSpace} ${values.join(' ')}`;\n } else {\n values = `${values.join(', ')}`;\n }\n return `${type}(${values})`;\n}\n\n/**\n * Converts a color from CSS rgb format to CSS hex format.\n * @param {string} color - RGB color, i.e. rgb(n, n, n)\n * @returns {string} A CSS rgb color string, i.e. #nnnnnn\n */\nexport function rgbToHex(color) {\n // Idempotent\n if (color.indexOf('#') === 0) {\n return color;\n }\n const {\n values\n } = decomposeColor(color);\n return `#${values.map((n, i) => intToHex(i === 3 ? Math.round(255 * n) : n)).join('')}`;\n}\n\n/**\n * Converts a color from hsl format to rgb format.\n * @param {string} color - HSL color values\n * @returns {string} rgb color values\n */\nexport function hslToRgb(color) {\n color = decomposeColor(color);\n const {\n values\n } = color;\n const h = values[0];\n const s = values[1] / 100;\n const l = values[2] / 100;\n const a = s * Math.min(l, 1 - l);\n const f = (n, k = (n + h / 30) % 12) => l - a * Math.max(Math.min(k - 3, 9 - k, 1), -1);\n let type = 'rgb';\n const rgb = [Math.round(f(0) * 255), Math.round(f(8) * 255), Math.round(f(4) * 255)];\n if (color.type === 'hsla') {\n type += 'a';\n rgb.push(values[3]);\n }\n return recomposeColor({\n type,\n values: rgb\n });\n}\n/**\n * The relative brightness of any point in a color space,\n * normalized to 0 for darkest black and 1 for lightest white.\n *\n * Formula: https://www.w3.org/TR/WCAG20-TECHS/G17.html#G17-tests\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @returns {number} The relative brightness of the color in the range 0 - 1\n */\nexport function getLuminance(color) {\n color = decomposeColor(color);\n let rgb = color.type === 'hsl' || color.type === 'hsla' ? decomposeColor(hslToRgb(color)).values : color.values;\n rgb = rgb.map(val => {\n if (color.type !== 'color') {\n val /= 255; // normalized\n }\n return val <= 0.03928 ? val / 12.92 : ((val + 0.055) / 1.055) ** 2.4;\n });\n\n // Truncate at 3 digits\n return Number((0.2126 * rgb[0] + 0.7152 * rgb[1] + 0.0722 * rgb[2]).toFixed(3));\n}\n\n/**\n * Calculates the contrast ratio between two colors.\n *\n * Formula: https://www.w3.org/TR/WCAG20-TECHS/G17.html#G17-tests\n * @param {string} foreground - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla()\n * @param {string} background - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla()\n * @returns {number} A contrast ratio value in the range 0 - 21.\n */\nexport function getContrastRatio(foreground, background) {\n const lumA = getLuminance(foreground);\n const lumB = getLuminance(background);\n return (Math.max(lumA, lumB) + 0.05) / (Math.min(lumA, lumB) + 0.05);\n}\n\n/**\n * Sets the absolute transparency of a color.\n * Any existing alpha values are overwritten.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} value - value to set the alpha channel to in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function alpha(color, value) {\n color = decomposeColor(color);\n value = clampWrapper(value);\n if (color.type === 'rgb' || color.type === 'hsl') {\n color.type += 'a';\n }\n if (color.type === 'color') {\n color.values[3] = `/${value}`;\n } else {\n color.values[3] = value;\n }\n return recomposeColor(color);\n}\nexport function private_safeAlpha(color, value, warning) {\n try {\n return alpha(color, value);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Darkens a color.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} coefficient - multiplier in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function darken(color, coefficient) {\n color = decomposeColor(color);\n coefficient = clampWrapper(coefficient);\n if (color.type.indexOf('hsl') !== -1) {\n color.values[2] *= 1 - coefficient;\n } else if (color.type.indexOf('rgb') !== -1 || color.type.indexOf('color') !== -1) {\n for (let i = 0; i < 3; i += 1) {\n color.values[i] *= 1 - coefficient;\n }\n }\n return recomposeColor(color);\n}\nexport function private_safeDarken(color, coefficient, warning) {\n try {\n return darken(color, coefficient);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Lightens a color.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} coefficient - multiplier in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function lighten(color, coefficient) {\n color = decomposeColor(color);\n coefficient = clampWrapper(coefficient);\n if (color.type.indexOf('hsl') !== -1) {\n color.values[2] += (100 - color.values[2]) * coefficient;\n } else if (color.type.indexOf('rgb') !== -1) {\n for (let i = 0; i < 3; i += 1) {\n color.values[i] += (255 - color.values[i]) * coefficient;\n }\n } else if (color.type.indexOf('color') !== -1) {\n for (let i = 0; i < 3; i += 1) {\n color.values[i] += (1 - color.values[i]) * coefficient;\n }\n }\n return recomposeColor(color);\n}\nexport function private_safeLighten(color, coefficient, warning) {\n try {\n return lighten(color, coefficient);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Darken or lighten a color, depending on its luminance.\n * Light colors are darkened, dark colors are lightened.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} coefficient=0.15 - multiplier in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function emphasize(color, coefficient = 0.15) {\n return getLuminance(color) > 0.5 ? darken(color, coefficient) : lighten(color, coefficient);\n}\nexport function private_safeEmphasize(color, coefficient, warning) {\n try {\n return emphasize(color, coefficient);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Blend a transparent overlay color with a background color, resulting in a single\n * RGB color.\n * @param {string} background - CSS color\n * @param {string} overlay - CSS color\n * @param {number} opacity - Opacity multiplier in the range 0 - 1\n * @param {number} [gamma=1.0] - Gamma correction factor. For gamma-correct blending, 2.2 is usual.\n */\nexport function blend(background, overlay, opacity, gamma = 1.0) {\n const blendChannel = (b, o) => Math.round((b ** (1 / gamma) * (1 - opacity) + o ** (1 / gamma) * opacity) ** gamma);\n const backgroundColor = decomposeColor(background);\n const overlayColor = decomposeColor(overlay);\n const rgb = [blendChannel(backgroundColor.values[0], overlayColor.values[0]), blendChannel(backgroundColor.values[1], overlayColor.values[1]), blendChannel(backgroundColor.values[2], overlayColor.values[2])];\n return recomposeColor({\n type: 'rgb',\n values: rgb\n });\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nexport default function createMixins(breakpoints, mixins) {\n return _extends({\n toolbar: {\n minHeight: 56,\n [breakpoints.up('xs')]: {\n '@media (orientation: landscape)': {\n minHeight: 48\n }\n },\n [breakpoints.up('sm')]: {\n minHeight: 64\n }\n }\n }, mixins);\n}","const common = {\n black: '#000',\n white: '#fff'\n};\nexport default common;","const grey = {\n 50: '#fafafa',\n 100: '#f5f5f5',\n 200: '#eeeeee',\n 300: '#e0e0e0',\n 400: '#bdbdbd',\n 500: '#9e9e9e',\n 600: '#757575',\n 700: '#616161',\n 800: '#424242',\n 900: '#212121',\n A100: '#f5f5f5',\n A200: '#eeeeee',\n A400: '#bdbdbd',\n A700: '#616161'\n};\nexport default grey;","const purple = {\n 50: '#f3e5f5',\n 100: '#e1bee7',\n 200: '#ce93d8',\n 300: '#ba68c8',\n 400: '#ab47bc',\n 500: '#9c27b0',\n 600: '#8e24aa',\n 700: '#7b1fa2',\n 800: '#6a1b9a',\n 900: '#4a148c',\n A100: '#ea80fc',\n A200: '#e040fb',\n A400: '#d500f9',\n A700: '#aa00ff'\n};\nexport default purple;","const red = {\n 50: '#ffebee',\n 100: '#ffcdd2',\n 200: '#ef9a9a',\n 300: '#e57373',\n 400: '#ef5350',\n 500: '#f44336',\n 600: '#e53935',\n 700: '#d32f2f',\n 800: '#c62828',\n 900: '#b71c1c',\n A100: '#ff8a80',\n A200: '#ff5252',\n A400: '#ff1744',\n A700: '#d50000'\n};\nexport default red;","const orange = {\n 50: '#fff3e0',\n 100: '#ffe0b2',\n 200: '#ffcc80',\n 300: '#ffb74d',\n 400: '#ffa726',\n 500: '#ff9800',\n 600: '#fb8c00',\n 700: '#f57c00',\n 800: '#ef6c00',\n 900: '#e65100',\n A100: '#ffd180',\n A200: '#ffab40',\n A400: '#ff9100',\n A700: '#ff6d00'\n};\nexport default orange;","const blue = {\n 50: '#e3f2fd',\n 100: '#bbdefb',\n 200: '#90caf9',\n 300: '#64b5f6',\n 400: '#42a5f5',\n 500: '#2196f3',\n 600: '#1e88e5',\n 700: '#1976d2',\n 800: '#1565c0',\n 900: '#0d47a1',\n A100: '#82b1ff',\n A200: '#448aff',\n A400: '#2979ff',\n A700: '#2962ff'\n};\nexport default blue;","const lightBlue = {\n 50: '#e1f5fe',\n 100: '#b3e5fc',\n 200: '#81d4fa',\n 300: '#4fc3f7',\n 400: '#29b6f6',\n 500: '#03a9f4',\n 600: '#039be5',\n 700: '#0288d1',\n 800: '#0277bd',\n 900: '#01579b',\n A100: '#80d8ff',\n A200: '#40c4ff',\n A400: '#00b0ff',\n A700: '#0091ea'\n};\nexport default lightBlue;","const green = {\n 50: '#e8f5e9',\n 100: '#c8e6c9',\n 200: '#a5d6a7',\n 300: '#81c784',\n 400: '#66bb6a',\n 500: '#4caf50',\n 600: '#43a047',\n 700: '#388e3c',\n 800: '#2e7d32',\n 900: '#1b5e20',\n A100: '#b9f6ca',\n A200: '#69f0ae',\n A400: '#00e676',\n A700: '#00c853'\n};\nexport default green;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\nconst _excluded = [\"mode\", \"contrastThreshold\", \"tonalOffset\"];\nimport { deepmerge } from '@mui/utils';\nimport { darken, getContrastRatio, lighten } from '@mui/system';\nimport common from '../colors/common';\nimport grey from '../colors/grey';\nimport purple from '../colors/purple';\nimport red from '../colors/red';\nimport orange from '../colors/orange';\nimport blue from '../colors/blue';\nimport lightBlue from '../colors/lightBlue';\nimport green from '../colors/green';\nexport const light = {\n // The colors used to style the text.\n text: {\n // The most important text.\n primary: 'rgba(0, 0, 0, 0.87)',\n // Secondary text.\n secondary: 'rgba(0, 0, 0, 0.6)',\n // Disabled text have even lower visual prominence.\n disabled: 'rgba(0, 0, 0, 0.38)'\n },\n // The color used to divide different elements.\n divider: 'rgba(0, 0, 0, 0.12)',\n // The background colors used to style the surfaces.\n // Consistency between these values is important.\n background: {\n paper: common.white,\n default: common.white\n },\n // The colors used to style the action elements.\n action: {\n // The color of an active action like an icon button.\n active: 'rgba(0, 0, 0, 0.54)',\n // The color of an hovered action.\n hover: 'rgba(0, 0, 0, 0.04)',\n hoverOpacity: 0.04,\n // The color of a selected action.\n selected: 'rgba(0, 0, 0, 0.08)',\n selectedOpacity: 0.08,\n // The color of a disabled action.\n disabled: 'rgba(0, 0, 0, 0.26)',\n // The background color of a disabled action.\n disabledBackground: 'rgba(0, 0, 0, 0.12)',\n disabledOpacity: 0.38,\n focus: 'rgba(0, 0, 0, 0.12)',\n focusOpacity: 0.12,\n activatedOpacity: 0.12\n }\n};\nexport const dark = {\n text: {\n primary: common.white,\n secondary: 'rgba(255, 255, 255, 0.7)',\n disabled: 'rgba(255, 255, 255, 0.5)',\n icon: 'rgba(255, 255, 255, 0.5)'\n },\n divider: 'rgba(255, 255, 255, 0.12)',\n background: {\n paper: '#121212',\n default: '#121212'\n },\n action: {\n active: common.white,\n hover: 'rgba(255, 255, 255, 0.08)',\n hoverOpacity: 0.08,\n selected: 'rgba(255, 255, 255, 0.16)',\n selectedOpacity: 0.16,\n disabled: 'rgba(255, 255, 255, 0.3)',\n disabledBackground: 'rgba(255, 255, 255, 0.12)',\n disabledOpacity: 0.38,\n focus: 'rgba(255, 255, 255, 0.12)',\n focusOpacity: 0.12,\n activatedOpacity: 0.24\n }\n};\nfunction addLightOrDark(intent, direction, shade, tonalOffset) {\n const tonalOffsetLight = tonalOffset.light || tonalOffset;\n const tonalOffsetDark = tonalOffset.dark || tonalOffset * 1.5;\n if (!intent[direction]) {\n if (intent.hasOwnProperty(shade)) {\n intent[direction] = intent[shade];\n } else if (direction === 'light') {\n intent.light = lighten(intent.main, tonalOffsetLight);\n } else if (direction === 'dark') {\n intent.dark = darken(intent.main, tonalOffsetDark);\n }\n }\n}\nfunction getDefaultPrimary(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: blue[200],\n light: blue[50],\n dark: blue[400]\n };\n }\n return {\n main: blue[700],\n light: blue[400],\n dark: blue[800]\n };\n}\nfunction getDefaultSecondary(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: purple[200],\n light: purple[50],\n dark: purple[400]\n };\n }\n return {\n main: purple[500],\n light: purple[300],\n dark: purple[700]\n };\n}\nfunction getDefaultError(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: red[500],\n light: red[300],\n dark: red[700]\n };\n }\n return {\n main: red[700],\n light: red[400],\n dark: red[800]\n };\n}\nfunction getDefaultInfo(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: lightBlue[400],\n light: lightBlue[300],\n dark: lightBlue[700]\n };\n }\n return {\n main: lightBlue[700],\n light: lightBlue[500],\n dark: lightBlue[900]\n };\n}\nfunction getDefaultSuccess(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: green[400],\n light: green[300],\n dark: green[700]\n };\n }\n return {\n main: green[800],\n light: green[500],\n dark: green[900]\n };\n}\nfunction getDefaultWarning(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: orange[400],\n light: orange[300],\n dark: orange[700]\n };\n }\n return {\n main: '#ed6c02',\n // closest to orange[800] that pass 3:1.\n light: orange[500],\n dark: orange[900]\n };\n}\nexport default function createPalette(palette) {\n const {\n mode = 'light',\n contrastThreshold = 3,\n tonalOffset = 0.2\n } = palette,\n other = _objectWithoutPropertiesLoose(palette, _excluded);\n const primary = palette.primary || getDefaultPrimary(mode);\n const secondary = palette.secondary || getDefaultSecondary(mode);\n const error = palette.error || getDefaultError(mode);\n const info = palette.info || getDefaultInfo(mode);\n const success = palette.success || getDefaultSuccess(mode);\n const warning = palette.warning || getDefaultWarning(mode);\n\n // Use the same logic as\n // Bootstrap: https://github.com/twbs/bootstrap/blob/1d6e3710dd447de1a200f29e8fa521f8a0908f70/scss/_functions.scss#L59\n // and material-components-web https://github.com/material-components/material-components-web/blob/ac46b8863c4dab9fc22c4c662dc6bd1b65dd652f/packages/mdc-theme/_functions.scss#L54\n function getContrastText(background) {\n const contrastText = getContrastRatio(background, dark.text.primary) >= contrastThreshold ? dark.text.primary : light.text.primary;\n if (process.env.NODE_ENV !== 'production') {\n const contrast = getContrastRatio(background, contrastText);\n if (contrast < 3) {\n console.error([`MUI: The contrast ratio of ${contrast}:1 for ${contrastText} on ${background}`, 'falls below the WCAG recommended absolute minimum contrast ratio of 3:1.', 'https://www.w3.org/TR/2008/REC-WCAG20-20081211/#visual-audio-contrast-contrast'].join('\\n'));\n }\n }\n return contrastText;\n }\n const augmentColor = ({\n color,\n name,\n mainShade = 500,\n lightShade = 300,\n darkShade = 700\n }) => {\n color = _extends({}, color);\n if (!color.main && color[mainShade]) {\n color.main = color[mainShade];\n }\n if (!color.hasOwnProperty('main')) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: The color${name ? ` (${name})` : ''} provided to augmentColor(color) is invalid.\nThe color object needs to have a \\`main\\` property or a \\`${mainShade}\\` property.` : _formatMuiErrorMessage(11, name ? ` (${name})` : '', mainShade));\n }\n if (typeof color.main !== 'string') {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: The color${name ? ` (${name})` : ''} provided to augmentColor(color) is invalid.\n\\`color.main\\` should be a string, but \\`${JSON.stringify(color.main)}\\` was provided instead.\n\nDid you intend to use one of the following approaches?\n\nimport { green } from \"@mui/material/colors\";\n\nconst theme1 = createTheme({ palette: {\n primary: green,\n} });\n\nconst theme2 = createTheme({ palette: {\n primary: { main: green[500] },\n} });` : _formatMuiErrorMessage(12, name ? ` (${name})` : '', JSON.stringify(color.main)));\n }\n addLightOrDark(color, 'light', lightShade, tonalOffset);\n addLightOrDark(color, 'dark', darkShade, tonalOffset);\n if (!color.contrastText) {\n color.contrastText = getContrastText(color.main);\n }\n return color;\n };\n const modes = {\n dark,\n light\n };\n if (process.env.NODE_ENV !== 'production') {\n if (!modes[mode]) {\n console.error(`MUI: The palette mode \\`${mode}\\` is not supported.`);\n }\n }\n const paletteOutput = deepmerge(_extends({\n // A collection of common colors.\n common: _extends({}, common),\n // prevent mutable object.\n // The palette mode, can be light or dark.\n mode,\n // The colors used to represent primary interface elements for a user.\n primary: augmentColor({\n color: primary,\n name: 'primary'\n }),\n // The colors used to represent secondary interface elements for a user.\n secondary: augmentColor({\n color: secondary,\n name: 'secondary',\n mainShade: 'A400',\n lightShade: 'A200',\n darkShade: 'A700'\n }),\n // The colors used to represent interface elements that the user should be made aware of.\n error: augmentColor({\n color: error,\n name: 'error'\n }),\n // The colors used to represent potentially dangerous actions or important messages.\n warning: augmentColor({\n color: warning,\n name: 'warning'\n }),\n // The colors used to present information to the user that is neutral and not necessarily important.\n info: augmentColor({\n color: info,\n name: 'info'\n }),\n // The colors used to indicate the successful completion of an action that user triggered.\n success: augmentColor({\n color: success,\n name: 'success'\n }),\n // The grey colors.\n grey,\n // Used by `getContrastText()` to maximize the contrast between\n // the background and the text.\n contrastThreshold,\n // Takes a background color and returns the text color that maximizes the contrast.\n getContrastText,\n // Generate a rich color object.\n augmentColor,\n // Used by the functions below to shift a color's luminance by approximately\n // two indexes within its tonal palette.\n // E.g., shift from Red 500 to Red 300 or Red 700.\n tonalOffset\n }, modes[mode]), other);\n return paletteOutput;\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"fontFamily\", \"fontSize\", \"fontWeightLight\", \"fontWeightRegular\", \"fontWeightMedium\", \"fontWeightBold\", \"htmlFontSize\", \"allVariants\", \"pxToRem\"];\nimport { deepmerge } from '@mui/utils';\nfunction round(value) {\n return Math.round(value * 1e5) / 1e5;\n}\nconst caseAllCaps = {\n textTransform: 'uppercase'\n};\nconst defaultFontFamily = '\"Roboto\", \"Helvetica\", \"Arial\", sans-serif';\n\n/**\n * @see @link{https://m2.material.io/design/typography/the-type-system.html}\n * @see @link{https://m2.material.io/design/typography/understanding-typography.html}\n */\nexport default function createTypography(palette, typography) {\n const _ref = typeof typography === 'function' ? typography(palette) : typography,\n {\n fontFamily = defaultFontFamily,\n // The default font size of the Material Specification.\n fontSize = 14,\n // px\n fontWeightLight = 300,\n fontWeightRegular = 400,\n fontWeightMedium = 500,\n fontWeightBold = 700,\n // Tell MUI what's the font-size on the html element.\n // 16px is the default font-size used by browsers.\n htmlFontSize = 16,\n // Apply the CSS properties to all the variants.\n allVariants,\n pxToRem: pxToRem2\n } = _ref,\n other = _objectWithoutPropertiesLoose(_ref, _excluded);\n if (process.env.NODE_ENV !== 'production') {\n if (typeof fontSize !== 'number') {\n console.error('MUI: `fontSize` is required to be a number.');\n }\n if (typeof htmlFontSize !== 'number') {\n console.error('MUI: `htmlFontSize` is required to be a number.');\n }\n }\n const coef = fontSize / 14;\n const pxToRem = pxToRem2 || (size => `${size / htmlFontSize * coef}rem`);\n const buildVariant = (fontWeight, size, lineHeight, letterSpacing, casing) => _extends({\n fontFamily,\n fontWeight,\n fontSize: pxToRem(size),\n // Unitless following https://meyerweb.com/eric/thoughts/2006/02/08/unitless-line-heights/\n lineHeight\n }, fontFamily === defaultFontFamily ? {\n letterSpacing: `${round(letterSpacing / size)}em`\n } : {}, casing, allVariants);\n const variants = {\n h1: buildVariant(fontWeightLight, 96, 1.167, -1.5),\n h2: buildVariant(fontWeightLight, 60, 1.2, -0.5),\n h3: buildVariant(fontWeightRegular, 48, 1.167, 0),\n h4: buildVariant(fontWeightRegular, 34, 1.235, 0.25),\n h5: buildVariant(fontWeightRegular, 24, 1.334, 0),\n h6: buildVariant(fontWeightMedium, 20, 1.6, 0.15),\n subtitle1: buildVariant(fontWeightRegular, 16, 1.75, 0.15),\n subtitle2: buildVariant(fontWeightMedium, 14, 1.57, 0.1),\n body1: buildVariant(fontWeightRegular, 16, 1.5, 0.15),\n body2: buildVariant(fontWeightRegular, 14, 1.43, 0.15),\n button: buildVariant(fontWeightMedium, 14, 1.75, 0.4, caseAllCaps),\n caption: buildVariant(fontWeightRegular, 12, 1.66, 0.4),\n overline: buildVariant(fontWeightRegular, 12, 2.66, 1, caseAllCaps),\n // TODO v6: Remove handling of 'inherit' variant from the theme as it is already handled in Material UI's Typography component. Also, remember to remove the associated types.\n inherit: {\n fontFamily: 'inherit',\n fontWeight: 'inherit',\n fontSize: 'inherit',\n lineHeight: 'inherit',\n letterSpacing: 'inherit'\n }\n };\n return deepmerge(_extends({\n htmlFontSize,\n pxToRem,\n fontFamily,\n fontSize,\n fontWeightLight,\n fontWeightRegular,\n fontWeightMedium,\n fontWeightBold\n }, variants), other, {\n clone: false // No need to clone deep\n });\n}","const shadowKeyUmbraOpacity = 0.2;\nconst shadowKeyPenumbraOpacity = 0.14;\nconst shadowAmbientShadowOpacity = 0.12;\nfunction createShadow(...px) {\n return [`${px[0]}px ${px[1]}px ${px[2]}px ${px[3]}px rgba(0,0,0,${shadowKeyUmbraOpacity})`, `${px[4]}px ${px[5]}px ${px[6]}px ${px[7]}px rgba(0,0,0,${shadowKeyPenumbraOpacity})`, `${px[8]}px ${px[9]}px ${px[10]}px ${px[11]}px rgba(0,0,0,${shadowAmbientShadowOpacity})`].join(',');\n}\n\n// Values from https://github.com/material-components/material-components-web/blob/be8747f94574669cb5e7add1a7c54fa41a89cec7/packages/mdc-elevation/_variables.scss\nconst shadows = ['none', createShadow(0, 2, 1, -1, 0, 1, 1, 0, 0, 1, 3, 0), createShadow(0, 3, 1, -2, 0, 2, 2, 0, 0, 1, 5, 0), createShadow(0, 3, 3, -2, 0, 3, 4, 0, 0, 1, 8, 0), createShadow(0, 2, 4, -1, 0, 4, 5, 0, 0, 1, 10, 0), createShadow(0, 3, 5, -1, 0, 5, 8, 0, 0, 1, 14, 0), createShadow(0, 3, 5, -1, 0, 6, 10, 0, 0, 1, 18, 0), createShadow(0, 4, 5, -2, 0, 7, 10, 1, 0, 2, 16, 1), createShadow(0, 5, 5, -3, 0, 8, 10, 1, 0, 3, 14, 2), createShadow(0, 5, 6, -3, 0, 9, 12, 1, 0, 3, 16, 2), createShadow(0, 6, 6, -3, 0, 10, 14, 1, 0, 4, 18, 3), createShadow(0, 6, 7, -4, 0, 11, 15, 1, 0, 4, 20, 3), createShadow(0, 7, 8, -4, 0, 12, 17, 2, 0, 5, 22, 4), createShadow(0, 7, 8, -4, 0, 13, 19, 2, 0, 5, 24, 4), createShadow(0, 7, 9, -4, 0, 14, 21, 2, 0, 5, 26, 4), createShadow(0, 8, 9, -5, 0, 15, 22, 2, 0, 6, 28, 5), createShadow(0, 8, 10, -5, 0, 16, 24, 2, 0, 6, 30, 5), createShadow(0, 8, 11, -5, 0, 17, 26, 2, 0, 6, 32, 5), createShadow(0, 9, 11, -5, 0, 18, 28, 2, 0, 7, 34, 6), createShadow(0, 9, 12, -6, 0, 19, 29, 2, 0, 7, 36, 6), createShadow(0, 10, 13, -6, 0, 20, 31, 3, 0, 8, 38, 7), createShadow(0, 10, 13, -6, 0, 21, 33, 3, 0, 8, 40, 7), createShadow(0, 10, 14, -6, 0, 22, 35, 3, 0, 8, 42, 7), createShadow(0, 11, 14, -7, 0, 23, 36, 3, 0, 9, 44, 8), createShadow(0, 11, 15, -7, 0, 24, 38, 3, 0, 9, 46, 8)];\nexport default shadows;","import _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nconst _excluded = [\"duration\", \"easing\", \"delay\"];\n// Follow https://material.google.com/motion/duration-easing.html#duration-easing-natural-easing-curves\n// to learn the context in which each easing should be used.\nexport const easing = {\n // This is the most common easing curve.\n easeInOut: 'cubic-bezier(0.4, 0, 0.2, 1)',\n // Objects enter the screen at full velocity from off-screen and\n // slowly decelerate to a resting point.\n easeOut: 'cubic-bezier(0.0, 0, 0.2, 1)',\n // Objects leave the screen at full velocity. They do not decelerate when off-screen.\n easeIn: 'cubic-bezier(0.4, 0, 1, 1)',\n // The sharp curve is used by objects that may return to the screen at any time.\n sharp: 'cubic-bezier(0.4, 0, 0.6, 1)'\n};\n\n// Follow https://m2.material.io/guidelines/motion/duration-easing.html#duration-easing-common-durations\n// to learn when use what timing\nexport const duration = {\n shortest: 150,\n shorter: 200,\n short: 250,\n // most basic recommended timing\n standard: 300,\n // this is to be used in complex animations\n complex: 375,\n // recommended when something is entering screen\n enteringScreen: 225,\n // recommended when something is leaving screen\n leavingScreen: 195\n};\nfunction formatMs(milliseconds) {\n return `${Math.round(milliseconds)}ms`;\n}\nfunction getAutoHeightDuration(height) {\n if (!height) {\n return 0;\n }\n const constant = height / 36;\n\n // https://www.wolframalpha.com/input/?i=(4+%2B+15+*+(x+%2F+36+)+**+0.25+%2B+(x+%2F+36)+%2F+5)+*+10\n return Math.round((4 + 15 * constant ** 0.25 + constant / 5) * 10);\n}\nexport default function createTransitions(inputTransitions) {\n const mergedEasing = _extends({}, easing, inputTransitions.easing);\n const mergedDuration = _extends({}, duration, inputTransitions.duration);\n const create = (props = ['all'], options = {}) => {\n const {\n duration: durationOption = mergedDuration.standard,\n easing: easingOption = mergedEasing.easeInOut,\n delay = 0\n } = options,\n other = _objectWithoutPropertiesLoose(options, _excluded);\n if (process.env.NODE_ENV !== 'production') {\n const isString = value => typeof value === 'string';\n // IE11 support, replace with Number.isNaN\n // eslint-disable-next-line no-restricted-globals\n const isNumber = value => !isNaN(parseFloat(value));\n if (!isString(props) && !Array.isArray(props)) {\n console.error('MUI: Argument \"props\" must be a string or Array.');\n }\n if (!isNumber(durationOption) && !isString(durationOption)) {\n console.error(`MUI: Argument \"duration\" must be a number or a string but found ${durationOption}.`);\n }\n if (!isString(easingOption)) {\n console.error('MUI: Argument \"easing\" must be a string.');\n }\n if (!isNumber(delay) && !isString(delay)) {\n console.error('MUI: Argument \"delay\" must be a number or a string.');\n }\n if (typeof options !== 'object') {\n console.error(['MUI: Secong argument of transition.create must be an object.', \"Arguments should be either `create('prop1', options)` or `create(['prop1', 'prop2'], options)`\"].join('\\n'));\n }\n if (Object.keys(other).length !== 0) {\n console.error(`MUI: Unrecognized argument(s) [${Object.keys(other).join(',')}].`);\n }\n }\n return (Array.isArray(props) ? props : [props]).map(animatedProp => `${animatedProp} ${typeof durationOption === 'string' ? durationOption : formatMs(durationOption)} ${easingOption} ${typeof delay === 'string' ? delay : formatMs(delay)}`).join(',');\n };\n return _extends({\n getAutoHeightDuration,\n create\n }, inputTransitions, {\n easing: mergedEasing,\n duration: mergedDuration\n });\n}","// We need to centralize the zIndex definitions as they work\n// like global values in the browser.\nconst zIndex = {\n mobileStepper: 1000,\n fab: 1050,\n speedDial: 1050,\n appBar: 1100,\n drawer: 1200,\n modal: 1300,\n snackbar: 1400,\n tooltip: 1500\n};\nexport default zIndex;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\nconst _excluded = [\"breakpoints\", \"mixins\", \"spacing\", \"palette\", \"transitions\", \"typography\", \"shape\"];\nimport { deepmerge } from '@mui/utils';\nimport { createTheme as systemCreateTheme, unstable_defaultSxConfig as defaultSxConfig, unstable_styleFunctionSx as styleFunctionSx } from '@mui/system';\nimport generateUtilityClass from '@mui/utils/generateUtilityClass';\nimport createMixins from './createMixins';\nimport createPalette from './createPalette';\nimport createTypography from './createTypography';\nimport shadows from './shadows';\nimport createTransitions from './createTransitions';\nimport zIndex from './zIndex';\nfunction createTheme(options = {}, ...args) {\n const {\n mixins: mixinsInput = {},\n palette: paletteInput = {},\n transitions: transitionsInput = {},\n typography: typographyInput = {}\n } = options,\n other = _objectWithoutPropertiesLoose(options, _excluded);\n if (options.vars) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: \\`vars\\` is a private field used for CSS variables support.\nPlease use another name.` : _formatMuiErrorMessage(18));\n }\n const palette = createPalette(paletteInput);\n const systemTheme = systemCreateTheme(options);\n let muiTheme = deepmerge(systemTheme, {\n mixins: createMixins(systemTheme.breakpoints, mixinsInput),\n palette,\n // Don't use [...shadows] until you've verified its transpiled code is not invoking the iterator protocol.\n shadows: shadows.slice(),\n typography: createTypography(palette, typographyInput),\n transitions: createTransitions(transitionsInput),\n zIndex: _extends({}, zIndex)\n });\n muiTheme = deepmerge(muiTheme, other);\n muiTheme = args.reduce((acc, argument) => deepmerge(acc, argument), muiTheme);\n if (process.env.NODE_ENV !== 'production') {\n // TODO v6: Refactor to use globalStateClassesMapping from @mui/utils once `readOnly` state class is used in Rating component.\n const stateClasses = ['active', 'checked', 'completed', 'disabled', 'error', 'expanded', 'focused', 'focusVisible', 'required', 'selected'];\n const traverse = (node, component) => {\n let key;\n\n // eslint-disable-next-line guard-for-in, no-restricted-syntax\n for (key in node) {\n const child = node[key];\n if (stateClasses.indexOf(key) !== -1 && Object.keys(child).length > 0) {\n if (process.env.NODE_ENV !== 'production') {\n const stateClass = generateUtilityClass('', key);\n console.error([`MUI: The \\`${component}\\` component increases ` + `the CSS specificity of the \\`${key}\\` internal state.`, 'You can not override it like this: ', JSON.stringify(node, null, 2), '', `Instead, you need to use the '&.${stateClass}' syntax:`, JSON.stringify({\n root: {\n [`&.${stateClass}`]: child\n }\n }, null, 2), '', 'https://mui.com/r/state-classes-guide'].join('\\n'));\n }\n // Remove the style to prevent global conflicts.\n node[key] = {};\n }\n }\n };\n Object.keys(muiTheme.components).forEach(component => {\n const styleOverrides = muiTheme.components[component].styleOverrides;\n if (styleOverrides && component.indexOf('Mui') === 0) {\n traverse(styleOverrides, component);\n }\n });\n }\n muiTheme.unstable_sxConfig = _extends({}, defaultSxConfig, other == null ? void 0 : other.unstable_sxConfig);\n muiTheme.unstable_sx = function sx(props) {\n return styleFunctionSx({\n sx: props,\n theme: this\n });\n };\n return muiTheme;\n}\nlet warnedOnce = false;\nexport function createMuiTheme(...args) {\n if (process.env.NODE_ENV !== 'production') {\n if (!warnedOnce) {\n warnedOnce = true;\n console.error(['MUI: the createMuiTheme function was renamed to createTheme.', '', \"You should use `import { createTheme } from '@mui/material/styles'`\"].join('\\n'));\n }\n }\n return createTheme(...args);\n}\nexport default createTheme;","'use client';\n\nimport createTheme from './createTheme';\nconst defaultTheme = createTheme();\nexport default defaultTheme;","export default '$$material';","'use client';\n\nimport { useThemeProps as systemUseThemeProps } from '@mui/system';\nimport defaultTheme from './defaultTheme';\nimport THEME_ID from './identifier';\nexport default function useThemeProps({\n props,\n name\n}) {\n return systemUseThemeProps({\n props,\n name,\n defaultTheme,\n themeId: THEME_ID\n });\n}","'use client';\n\nimport { createStyled, shouldForwardProp } from '@mui/system';\nimport defaultTheme from './defaultTheme';\nimport THEME_ID from './identifier';\nexport const rootShouldForwardProp = prop => shouldForwardProp(prop) && prop !== 'classes';\nexport const slotShouldForwardProp = shouldForwardProp;\nconst styled = createStyled({\n themeId: THEME_ID,\n defaultTheme,\n rootShouldForwardProp\n});\nexport default styled;","import generateUtilityClasses from '@mui/utils/generateUtilityClasses';\nimport generateUtilityClass from '@mui/utils/generateUtilityClass';\nexport function getSvgIconUtilityClass(slot) {\n return generateUtilityClass('MuiSvgIcon', slot);\n}\nconst svgIconClasses = generateUtilityClasses('MuiSvgIcon', ['root', 'colorPrimary', 'colorSecondary', 'colorAction', 'colorError', 'colorDisabled', 'fontSizeInherit', 'fontSizeSmall', 'fontSizeMedium', 'fontSizeLarge']);\nexport default svgIconClasses;","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"children\", \"className\", \"color\", \"component\", \"fontSize\", \"htmlColor\", \"inheritViewBox\", \"titleAccess\", \"viewBox\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport clsx from 'clsx';\nimport { unstable_composeClasses as composeClasses } from '@mui/base/composeClasses';\nimport capitalize from '../utils/capitalize';\nimport useThemeProps from '../styles/useThemeProps';\nimport styled from '../styles/styled';\nimport { getSvgIconUtilityClass } from './svgIconClasses';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nimport { jsxs as _jsxs } from \"react/jsx-runtime\";\nconst useUtilityClasses = ownerState => {\n const {\n color,\n fontSize,\n classes\n } = ownerState;\n const slots = {\n root: ['root', color !== 'inherit' && `color${capitalize(color)}`, `fontSize${capitalize(fontSize)}`]\n };\n return composeClasses(slots, getSvgIconUtilityClass, classes);\n};\nconst SvgIconRoot = styled('svg', {\n name: 'MuiSvgIcon',\n slot: 'Root',\n overridesResolver: (props, styles) => {\n const {\n ownerState\n } = props;\n return [styles.root, ownerState.color !== 'inherit' && styles[`color${capitalize(ownerState.color)}`], styles[`fontSize${capitalize(ownerState.fontSize)}`]];\n }\n})(({\n theme,\n ownerState\n}) => {\n var _theme$transitions, _theme$transitions$cr, _theme$transitions2, _theme$typography, _theme$typography$pxT, _theme$typography2, _theme$typography2$px, _theme$typography3, _theme$typography3$px, _palette$ownerState$c, _palette, _palette2, _palette3;\n return {\n userSelect: 'none',\n width: '1em',\n height: '1em',\n display: 'inline-block',\n // the will define the property that has `currentColor`\n // e.g. heroicons uses fill=\"none\" and stroke=\"currentColor\"\n fill: ownerState.hasSvgAsChild ? undefined : 'currentColor',\n flexShrink: 0,\n transition: (_theme$transitions = theme.transitions) == null || (_theme$transitions$cr = _theme$transitions.create) == null ? void 0 : _theme$transitions$cr.call(_theme$transitions, 'fill', {\n duration: (_theme$transitions2 = theme.transitions) == null || (_theme$transitions2 = _theme$transitions2.duration) == null ? void 0 : _theme$transitions2.shorter\n }),\n fontSize: {\n inherit: 'inherit',\n small: ((_theme$typography = theme.typography) == null || (_theme$typography$pxT = _theme$typography.pxToRem) == null ? void 0 : _theme$typography$pxT.call(_theme$typography, 20)) || '1.25rem',\n medium: ((_theme$typography2 = theme.typography) == null || (_theme$typography2$px = _theme$typography2.pxToRem) == null ? void 0 : _theme$typography2$px.call(_theme$typography2, 24)) || '1.5rem',\n large: ((_theme$typography3 = theme.typography) == null || (_theme$typography3$px = _theme$typography3.pxToRem) == null ? void 0 : _theme$typography3$px.call(_theme$typography3, 35)) || '2.1875rem'\n }[ownerState.fontSize],\n // TODO v5 deprecate, v6 remove for sx\n color: (_palette$ownerState$c = (_palette = (theme.vars || theme).palette) == null || (_palette = _palette[ownerState.color]) == null ? void 0 : _palette.main) != null ? _palette$ownerState$c : {\n action: (_palette2 = (theme.vars || theme).palette) == null || (_palette2 = _palette2.action) == null ? void 0 : _palette2.active,\n disabled: (_palette3 = (theme.vars || theme).palette) == null || (_palette3 = _palette3.action) == null ? void 0 : _palette3.disabled,\n inherit: undefined\n }[ownerState.color]\n };\n});\nconst SvgIcon = /*#__PURE__*/React.forwardRef(function SvgIcon(inProps, ref) {\n const props = useThemeProps({\n props: inProps,\n name: 'MuiSvgIcon'\n });\n const {\n children,\n className,\n color = 'inherit',\n component = 'svg',\n fontSize = 'medium',\n htmlColor,\n inheritViewBox = false,\n titleAccess,\n viewBox = '0 0 24 24'\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const hasSvgAsChild = /*#__PURE__*/React.isValidElement(children) && children.type === 'svg';\n const ownerState = _extends({}, props, {\n color,\n component,\n fontSize,\n instanceFontSize: inProps.fontSize,\n inheritViewBox,\n viewBox,\n hasSvgAsChild\n });\n const more = {};\n if (!inheritViewBox) {\n more.viewBox = viewBox;\n }\n const classes = useUtilityClasses(ownerState);\n return /*#__PURE__*/_jsxs(SvgIconRoot, _extends({\n as: component,\n className: clsx(classes.root, className),\n focusable: \"false\",\n color: htmlColor,\n \"aria-hidden\": titleAccess ? undefined : true,\n role: titleAccess ? 'img' : undefined,\n ref: ref\n }, more, other, hasSvgAsChild && children.props, {\n ownerState: ownerState,\n children: [hasSvgAsChild ? children.props.children : children, titleAccess ? /*#__PURE__*/_jsx(\"title\", {\n children: titleAccess\n }) : null]\n }));\n});\nprocess.env.NODE_ENV !== \"production\" ? SvgIcon.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the d.ts file and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * Node passed into the SVG element.\n */\n children: PropTypes.node,\n /**\n * Override or extend the styles applied to the component.\n */\n classes: PropTypes.object,\n /**\n * @ignore\n */\n className: PropTypes.string,\n /**\n * The color of the component.\n * It supports both default and custom theme colors, which can be added as shown in the\n * [palette customization guide](https://mui.com/material-ui/customization/palette/#custom-colors).\n * You can use the `htmlColor` prop to apply a color attribute to the SVG element.\n * @default 'inherit'\n */\n color: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.oneOf(['inherit', 'action', 'disabled', 'primary', 'secondary', 'error', 'info', 'success', 'warning']), PropTypes.string]),\n /**\n * The component used for the root node.\n * Either a string to use a HTML element or a component.\n */\n component: PropTypes.elementType,\n /**\n * The fontSize applied to the icon. Defaults to 24px, but can be configure to inherit font size.\n * @default 'medium'\n */\n fontSize: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.oneOf(['inherit', 'large', 'medium', 'small']), PropTypes.string]),\n /**\n * Applies a color attribute to the SVG element.\n */\n htmlColor: PropTypes.string,\n /**\n * If `true`, the root node will inherit the custom `component`'s viewBox and the `viewBox`\n * prop will be ignored.\n * Useful when you want to reference a custom `component` and have `SvgIcon` pass that\n * `component`'s viewBox to the root node.\n * @default false\n */\n inheritViewBox: PropTypes.bool,\n /**\n * The shape-rendering attribute. The behavior of the different options is described on the\n * [MDN Web Docs](https://developer.mozilla.org/en-US/docs/Web/SVG/Attribute/shape-rendering).\n * If you are having issues with blurry icons you should investigate this prop.\n */\n shapeRendering: PropTypes.string,\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Provides a human-readable title for the element that contains it.\n * https://www.w3.org/TR/SVG-access/#Equivalent\n */\n titleAccess: PropTypes.string,\n /**\n * Allows you to redefine what the coordinates without units mean inside an SVG element.\n * For example, if the SVG element is 500 (width) by 200 (height),\n * and you pass viewBox=\"0 0 50 20\",\n * this means that the coordinates inside the SVG will go from the top left corner (0,0)\n * to bottom right (50,20) and each unit will be worth 10px.\n * @default '0 0 24 24'\n */\n viewBox: PropTypes.string\n} : void 0;\nSvgIcon.muiName = 'SvgIcon';\nexport default SvgIcon;","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport * as React from 'react';\nimport SvgIcon from '../SvgIcon';\n\n/**\n * Private module reserved for @mui packages.\n */\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nexport default function createSvgIcon(path, displayName) {\n function Component(props, ref) {\n return /*#__PURE__*/_jsx(SvgIcon, _extends({\n \"data-testid\": `${displayName}Icon`,\n ref: ref\n }, props, {\n children: path\n }));\n }\n if (process.env.NODE_ENV !== 'production') {\n // Need to set `displayName` on the inner component for React.memo.\n // React prior to 16.14 ignores `displayName` on the wrapper.\n Component.displayName = `${displayName}Icon`;\n }\n Component.muiName = SvgIcon.muiName;\n return /*#__PURE__*/React.memo( /*#__PURE__*/React.forwardRef(Component));\n}","'use client';\n\nimport { unstable_ClassNameGenerator as ClassNameGenerator } from '@mui/base/ClassNameGenerator';\nexport { default as capitalize } from './capitalize';\nexport { default as createChainedFunction } from './createChainedFunction';\nexport { default as createSvgIcon } from './createSvgIcon';\nexport { default as debounce } from './debounce';\nexport { default as deprecatedPropType } from './deprecatedPropType';\nexport { default as isMuiElement } from './isMuiElement';\nexport { default as ownerDocument } from './ownerDocument';\nexport { default as ownerWindow } from './ownerWindow';\nexport { default as requirePropFactory } from './requirePropFactory';\nexport { default as setRef } from './setRef';\nexport { default as unstable_useEnhancedEffect } from './useEnhancedEffect';\nexport { default as unstable_useId } from './useId';\nexport { default as unsupportedProp } from './unsupportedProp';\nexport { default as useControlled } from './useControlled';\nexport { default as useEventCallback } from './useEventCallback';\nexport { default as useForkRef } from './useForkRef';\nexport { default as useIsFocusVisible } from './useIsFocusVisible';\n// TODO: remove this export once ClassNameGenerator is stable\n// eslint-disable-next-line @typescript-eslint/naming-convention\nexport const unstable_ClassNameGenerator = {\n configure: generator => {\n if (process.env.NODE_ENV !== 'production') {\n console.warn(['MUI: `ClassNameGenerator` import from `@mui/material/utils` is outdated and might cause unexpected issues.', '', \"You should use `import { unstable_ClassNameGenerator } from '@mui/material/className'` instead\", '', 'The detail of the issue: https://github.com/mui/material-ui/issues/30011#issuecomment-1024993401', '', 'The updated documentation: https://mui.com/guides/classname-generator/'].join('\\n'));\n }\n ClassNameGenerator.configure(generator);\n }\n};","\"use strict\";\n'use client';\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nObject.defineProperty(exports, \"default\", {\n enumerable: true,\n get: function () {\n return _utils.createSvgIcon;\n }\n});\nvar _utils = require(\"@mui/material/utils\");","\"use strict\";\n\"use client\";\n\nvar _interopRequireDefault = require(\"@babel/runtime/helpers/interopRequireDefault\");\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = void 0;\nvar _createSvgIcon = _interopRequireDefault(require(\"./utils/createSvgIcon\"));\nvar _jsxRuntime = require(\"react/jsx-runtime\");\nvar _default = exports.default = (0, _createSvgIcon.default)( /*#__PURE__*/(0, _jsxRuntime.jsx)(\"path\", {\n d: \"m10 17 5-5-5-5z\"\n}), 'ArrowRight');","/**\n * Determines if a given element is a DOM element name (i.e. not a React component).\n */\nexport function isHostComponent(element) {\n return typeof element === 'string';\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport { isHostComponent } from './isHostComponent';\n\n/**\n * Type of the ownerState based on the type of an element it applies to.\n * This resolves to the provided OwnerState for React components and `undefined` for host components.\n * Falls back to `OwnerState | undefined` when the exact type can't be determined in development time.\n */\n\n/**\n * Appends the ownerState object to the props, merging with the existing one if necessary.\n *\n * @param elementType Type of the element that owns the `existingProps`. If the element is a DOM node or undefined, `ownerState` is not applied.\n * @param otherProps Props of the element.\n * @param ownerState\n */\nexport function appendOwnerState(elementType, otherProps, ownerState) {\n if (elementType === undefined || isHostComponent(elementType)) {\n return otherProps;\n }\n return _extends({}, otherProps, {\n ownerState: _extends({}, otherProps.ownerState, ownerState)\n });\n}","'use client';\n\nimport * as React from 'react';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nconst defaultContextValue = {\n disableDefaultClasses: false\n};\nconst ClassNameConfiguratorContext = /*#__PURE__*/React.createContext(defaultContextValue);\n/**\n * @ignore - internal hook.\n *\n * Wraps the `generateUtilityClass` function and controls how the classes are generated.\n * Currently it only affects whether the classes are applied or not.\n *\n * @returns Function to be called with the `generateUtilityClass` function specific to a component to generate the classes.\n */\nexport function useClassNamesOverride(generateUtilityClass) {\n const {\n disableDefaultClasses\n } = React.useContext(ClassNameConfiguratorContext);\n return slot => {\n if (disableDefaultClasses) {\n return '';\n }\n return generateUtilityClass(slot);\n };\n}\n\n/**\n * Allows to configure the components within to not apply any built-in classes.\n */\nexport function ClassNameConfigurator(props) {\n const {\n disableDefaultClasses,\n children\n } = props;\n const contextValue = React.useMemo(() => ({\n disableDefaultClasses: disableDefaultClasses != null ? disableDefaultClasses : false\n }), [disableDefaultClasses]);\n return /*#__PURE__*/_jsx(ClassNameConfiguratorContext.Provider, {\n value: contextValue,\n children: children\n });\n}","/**\n * Extracts event handlers from a given object.\n * A prop is considered an event handler if it is a function and its name starts with `on`.\n *\n * @param object An object to extract event handlers from.\n * @param excludeKeys An array of keys to exclude from the returned object.\n */\nexport function extractEventHandlers(object, excludeKeys = []) {\n if (object === undefined) {\n return {};\n }\n const result = {};\n Object.keys(object).filter(prop => prop.match(/^on[A-Z]/) && typeof object[prop] === 'function' && !excludeKeys.includes(prop)).forEach(prop => {\n result[prop] = object[prop];\n });\n return result;\n}","/**\n * If `componentProps` is a function, calls it with the provided `ownerState`.\n * Otherwise, just returns `componentProps`.\n */\nexport function resolveComponentProps(componentProps, ownerState, slotState) {\n if (typeof componentProps === 'function') {\n return componentProps(ownerState, slotState);\n }\n return componentProps;\n}","/**\n * Removes event handlers from the given object.\n * A field is considered an event handler if it is a function with a name beginning with `on`.\n *\n * @param object Object to remove event handlers from.\n * @returns Object with event handlers removed.\n */\nexport function omitEventHandlers(object) {\n if (object === undefined) {\n return {};\n }\n const result = {};\n Object.keys(object).filter(prop => !(prop.match(/^on[A-Z]/) && typeof object[prop] === 'function')).forEach(prop => {\n result[prop] = object[prop];\n });\n return result;\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport clsx from 'clsx';\nimport { extractEventHandlers } from './extractEventHandlers';\nimport { omitEventHandlers } from './omitEventHandlers';\n/**\n * Merges the slot component internal props (usually coming from a hook)\n * with the externally provided ones.\n *\n * The merge order is (the latter overrides the former):\n * 1. The internal props (specified as a getter function to work with get*Props hook result)\n * 2. Additional props (specified internally on a Base UI component)\n * 3. External props specified on the owner component. These should only be used on a root slot.\n * 4. External props specified in the `slotProps.*` prop.\n * 5. The `className` prop - combined from all the above.\n * @param parameters\n * @returns\n */\nexport function mergeSlotProps(parameters) {\n const {\n getSlotProps,\n additionalProps,\n externalSlotProps,\n externalForwardedProps,\n className\n } = parameters;\n if (!getSlotProps) {\n // The simpler case - getSlotProps is not defined, so no internal event handlers are defined,\n // so we can simply merge all the props without having to worry about extracting event handlers.\n const joinedClasses = clsx(additionalProps == null ? void 0 : additionalProps.className, className, externalForwardedProps == null ? void 0 : externalForwardedProps.className, externalSlotProps == null ? void 0 : externalSlotProps.className);\n const mergedStyle = _extends({}, additionalProps == null ? void 0 : additionalProps.style, externalForwardedProps == null ? void 0 : externalForwardedProps.style, externalSlotProps == null ? void 0 : externalSlotProps.style);\n const props = _extends({}, additionalProps, externalForwardedProps, externalSlotProps);\n if (joinedClasses.length > 0) {\n props.className = joinedClasses;\n }\n if (Object.keys(mergedStyle).length > 0) {\n props.style = mergedStyle;\n }\n return {\n props,\n internalRef: undefined\n };\n }\n\n // In this case, getSlotProps is responsible for calling the external event handlers.\n // We don't need to include them in the merged props because of this.\n\n const eventHandlers = extractEventHandlers(_extends({}, externalForwardedProps, externalSlotProps));\n const componentsPropsWithoutEventHandlers = omitEventHandlers(externalSlotProps);\n const otherPropsWithoutEventHandlers = omitEventHandlers(externalForwardedProps);\n const internalSlotProps = getSlotProps(eventHandlers);\n\n // The order of classes is important here.\n // Emotion (that we use in libraries consuming Base UI) depends on this order\n // to properly override style. It requires the most important classes to be last\n // (see https://github.com/mui/material-ui/pull/33205) for the related discussion.\n const joinedClasses = clsx(internalSlotProps == null ? void 0 : internalSlotProps.className, additionalProps == null ? void 0 : additionalProps.className, className, externalForwardedProps == null ? void 0 : externalForwardedProps.className, externalSlotProps == null ? void 0 : externalSlotProps.className);\n const mergedStyle = _extends({}, internalSlotProps == null ? void 0 : internalSlotProps.style, additionalProps == null ? void 0 : additionalProps.style, externalForwardedProps == null ? void 0 : externalForwardedProps.style, externalSlotProps == null ? void 0 : externalSlotProps.style);\n const props = _extends({}, internalSlotProps, additionalProps, otherPropsWithoutEventHandlers, componentsPropsWithoutEventHandlers);\n if (joinedClasses.length > 0) {\n props.className = joinedClasses;\n }\n if (Object.keys(mergedStyle).length > 0) {\n props.style = mergedStyle;\n }\n return {\n props,\n internalRef: internalSlotProps.ref\n };\n}","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"elementType\", \"externalSlotProps\", \"ownerState\", \"skipResolvingSlotProps\"];\nimport { unstable_useForkRef as useForkRef } from '@mui/utils';\nimport { appendOwnerState } from './appendOwnerState';\nimport { mergeSlotProps } from './mergeSlotProps';\nimport { resolveComponentProps } from './resolveComponentProps';\n/**\n * @ignore - do not document.\n * Builds the props to be passed into the slot of an unstyled component.\n * It merges the internal props of the component with the ones supplied by the user, allowing to customize the behavior.\n * If the slot component is not a host component, it also merges in the `ownerState`.\n *\n * @param parameters.getSlotProps - A function that returns the props to be passed to the slot component.\n */\nexport function useSlotProps(parameters) {\n var _parameters$additiona;\n const {\n elementType,\n externalSlotProps,\n ownerState,\n skipResolvingSlotProps = false\n } = parameters,\n rest = _objectWithoutPropertiesLoose(parameters, _excluded);\n const resolvedComponentsProps = skipResolvingSlotProps ? {} : resolveComponentProps(externalSlotProps, ownerState);\n const {\n props: mergedProps,\n internalRef\n } = mergeSlotProps(_extends({}, rest, {\n externalSlotProps: resolvedComponentsProps\n }));\n const ref = useForkRef(internalRef, resolvedComponentsProps == null ? void 0 : resolvedComponentsProps.ref, (_parameters$additiona = parameters.additionalProps) == null ? void 0 : _parameters$additiona.ref);\n const props = appendOwnerState(elementType, _extends({}, mergedProps, {\n ref\n }), ownerState);\n return props;\n}","import { globalStateClasses } from '@mui/utils/generateUtilityClass';\nconst GLOBAL_CLASS_PREFIX = 'base';\nfunction buildStateClass(state) {\n return `${GLOBAL_CLASS_PREFIX}--${state}`;\n}\nfunction buildSlotClass(componentName, slot) {\n return `${GLOBAL_CLASS_PREFIX}-${componentName}-${slot}`;\n}\nexport function generateUtilityClass(componentName, slot) {\n const globalStateClass = globalStateClasses[slot];\n return globalStateClass ? buildStateClass(globalStateClass) : buildSlotClass(componentName, slot);\n}\nexport function isGlobalState(slot) {\n return globalStateClasses[slot] !== undefined;\n}","import { generateUtilityClass } from '../generateUtilityClass';\nexport function generateUtilityClasses(componentName, slots) {\n const result = {};\n slots.forEach(slot => {\n result[slot] = generateUtilityClass(componentName, slot);\n });\n return result;\n}","'use client';\n\nimport * as React from 'react';\nimport * as ReactDOM from 'react-dom';\nimport PropTypes from 'prop-types';\nimport { exactProp, HTMLElementType, unstable_useEnhancedEffect as useEnhancedEffect, unstable_useForkRef as useForkRef, unstable_setRef as setRef } from '@mui/utils';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nfunction getContainer(container) {\n return typeof container === 'function' ? container() : container;\n}\n\n/**\n * Portals provide a first-class way to render children into a DOM node\n * that exists outside the DOM hierarchy of the parent component.\n *\n * Demos:\n *\n * - [Portal](https://mui.com/base-ui/react-portal/)\n *\n * API:\n *\n * - [Portal API](https://mui.com/base-ui/react-portal/components-api/#portal)\n */\nconst Portal = /*#__PURE__*/React.forwardRef(function Portal(props, forwardedRef) {\n const {\n children,\n container,\n disablePortal = false\n } = props;\n const [mountNode, setMountNode] = React.useState(null);\n // @ts-expect-error TODO upstream fix\n const handleRef = useForkRef( /*#__PURE__*/React.isValidElement(children) ? children.ref : null, forwardedRef);\n useEnhancedEffect(() => {\n if (!disablePortal) {\n setMountNode(getContainer(container) || document.body);\n }\n }, [container, disablePortal]);\n useEnhancedEffect(() => {\n if (mountNode && !disablePortal) {\n setRef(forwardedRef, mountNode);\n return () => {\n setRef(forwardedRef, null);\n };\n }\n return undefined;\n }, [forwardedRef, mountNode, disablePortal]);\n if (disablePortal) {\n if ( /*#__PURE__*/React.isValidElement(children)) {\n const newProps = {\n ref: handleRef\n };\n return /*#__PURE__*/React.cloneElement(children, newProps);\n }\n return /*#__PURE__*/_jsx(React.Fragment, {\n children: children\n });\n }\n return /*#__PURE__*/_jsx(React.Fragment, {\n children: mountNode ? /*#__PURE__*/ReactDOM.createPortal(children, mountNode) : mountNode\n });\n});\nprocess.env.NODE_ENV !== \"production\" ? Portal.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * The children to render into the `container`.\n */\n children: PropTypes.node,\n /**\n * An HTML element or function that returns one.\n * The `container` will have the portal children appended to it.\n *\n * You can also provide a callback, which is called in a React layout effect.\n * This lets you set the container from a ref, and also makes server-side rendering possible.\n *\n * By default, it uses the body of the top-level document object,\n * so it's simply `document.body` most of the time.\n */\n container: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.func]),\n /**\n * The `children` will be under the DOM hierarchy of the parent component.\n * @default false\n */\n disablePortal: PropTypes.bool\n} : void 0;\nif (process.env.NODE_ENV !== 'production') {\n // eslint-disable-next-line\n Portal['propTypes' + ''] = exactProp(Portal.propTypes);\n}\nexport { Portal };","export var top = 'top';\nexport var bottom = 'bottom';\nexport var right = 'right';\nexport var left = 'left';\nexport var auto = 'auto';\nexport var basePlacements = [top, bottom, right, left];\nexport var start = 'start';\nexport var end = 'end';\nexport var clippingParents = 'clippingParents';\nexport var viewport = 'viewport';\nexport var popper = 'popper';\nexport var reference = 'reference';\nexport var variationPlacements = /*#__PURE__*/basePlacements.reduce(function (acc, placement) {\n return acc.concat([placement + \"-\" + start, placement + \"-\" + end]);\n}, []);\nexport var placements = /*#__PURE__*/[].concat(basePlacements, [auto]).reduce(function (acc, placement) {\n return acc.concat([placement, placement + \"-\" + start, placement + \"-\" + end]);\n}, []); // modifiers that need to read the DOM\n\nexport var beforeRead = 'beforeRead';\nexport var read = 'read';\nexport var afterRead = 'afterRead'; // pure-logic modifiers\n\nexport var beforeMain = 'beforeMain';\nexport var main = 'main';\nexport var afterMain = 'afterMain'; // modifier with the purpose to write to the DOM (or write into a framework state)\n\nexport var beforeWrite = 'beforeWrite';\nexport var write = 'write';\nexport var afterWrite = 'afterWrite';\nexport var modifierPhases = [beforeRead, read, afterRead, beforeMain, main, afterMain, beforeWrite, write, afterWrite];","export default function getNodeName(element) {\n return element ? (element.nodeName || '').toLowerCase() : null;\n}","export default function getWindow(node) {\n if (node == null) {\n return window;\n }\n\n if (node.toString() !== '[object Window]') {\n var ownerDocument = node.ownerDocument;\n return ownerDocument ? ownerDocument.defaultView || window : window;\n }\n\n return node;\n}","import getWindow from \"./getWindow.js\";\n\nfunction isElement(node) {\n var OwnElement = getWindow(node).Element;\n return node instanceof OwnElement || node instanceof Element;\n}\n\nfunction isHTMLElement(node) {\n var OwnElement = getWindow(node).HTMLElement;\n return node instanceof OwnElement || node instanceof HTMLElement;\n}\n\nfunction isShadowRoot(node) {\n // IE 11 has no ShadowRoot\n if (typeof ShadowRoot === 'undefined') {\n return false;\n }\n\n var OwnElement = getWindow(node).ShadowRoot;\n return node instanceof OwnElement || node instanceof ShadowRoot;\n}\n\nexport { isElement, isHTMLElement, isShadowRoot };","import getNodeName from \"../dom-utils/getNodeName.js\";\nimport { isHTMLElement } from \"../dom-utils/instanceOf.js\"; // This modifier takes the styles prepared by the `computeStyles` modifier\n// and applies them to the HTMLElements such as popper and arrow\n\nfunction applyStyles(_ref) {\n var state = _ref.state;\n Object.keys(state.elements).forEach(function (name) {\n var style = state.styles[name] || {};\n var attributes = state.attributes[name] || {};\n var element = state.elements[name]; // arrow is optional + virtual elements\n\n if (!isHTMLElement(element) || !getNodeName(element)) {\n return;\n } // Flow doesn't support to extend this property, but it's the most\n // effective way to apply styles to an HTMLElement\n // $FlowFixMe[cannot-write]\n\n\n Object.assign(element.style, style);\n Object.keys(attributes).forEach(function (name) {\n var value = attributes[name];\n\n if (value === false) {\n element.removeAttribute(name);\n } else {\n element.setAttribute(name, value === true ? '' : value);\n }\n });\n });\n}\n\nfunction effect(_ref2) {\n var state = _ref2.state;\n var initialStyles = {\n popper: {\n position: state.options.strategy,\n left: '0',\n top: '0',\n margin: '0'\n },\n arrow: {\n position: 'absolute'\n },\n reference: {}\n };\n Object.assign(state.elements.popper.style, initialStyles.popper);\n state.styles = initialStyles;\n\n if (state.elements.arrow) {\n Object.assign(state.elements.arrow.style, initialStyles.arrow);\n }\n\n return function () {\n Object.keys(state.elements).forEach(function (name) {\n var element = state.elements[name];\n var attributes = state.attributes[name] || {};\n var styleProperties = Object.keys(state.styles.hasOwnProperty(name) ? state.styles[name] : initialStyles[name]); // Set all values to an empty string to unset them\n\n var style = styleProperties.reduce(function (style, property) {\n style[property] = '';\n return style;\n }, {}); // arrow is optional + virtual elements\n\n if (!isHTMLElement(element) || !getNodeName(element)) {\n return;\n }\n\n Object.assign(element.style, style);\n Object.keys(attributes).forEach(function (attribute) {\n element.removeAttribute(attribute);\n });\n });\n };\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'applyStyles',\n enabled: true,\n phase: 'write',\n fn: applyStyles,\n effect: effect,\n requires: ['computeStyles']\n};","import { auto } from \"../enums.js\";\nexport default function getBasePlacement(placement) {\n return placement.split('-')[0];\n}","export var max = Math.max;\nexport var min = Math.min;\nexport var round = Math.round;","export default function getUAString() {\n var uaData = navigator.userAgentData;\n\n if (uaData != null && uaData.brands && Array.isArray(uaData.brands)) {\n return uaData.brands.map(function (item) {\n return item.brand + \"/\" + item.version;\n }).join(' ');\n }\n\n return navigator.userAgent;\n}","import getUAString from \"../utils/userAgent.js\";\nexport default function isLayoutViewport() {\n return !/^((?!chrome|android).)*safari/i.test(getUAString());\n}","import { isElement, isHTMLElement } from \"./instanceOf.js\";\nimport { round } from \"../utils/math.js\";\nimport getWindow from \"./getWindow.js\";\nimport isLayoutViewport from \"./isLayoutViewport.js\";\nexport default function getBoundingClientRect(element, includeScale, isFixedStrategy) {\n if (includeScale === void 0) {\n includeScale = false;\n }\n\n if (isFixedStrategy === void 0) {\n isFixedStrategy = false;\n }\n\n var clientRect = element.getBoundingClientRect();\n var scaleX = 1;\n var scaleY = 1;\n\n if (includeScale && isHTMLElement(element)) {\n scaleX = element.offsetWidth > 0 ? round(clientRect.width) / element.offsetWidth || 1 : 1;\n scaleY = element.offsetHeight > 0 ? round(clientRect.height) / element.offsetHeight || 1 : 1;\n }\n\n var _ref = isElement(element) ? getWindow(element) : window,\n visualViewport = _ref.visualViewport;\n\n var addVisualOffsets = !isLayoutViewport() && isFixedStrategy;\n var x = (clientRect.left + (addVisualOffsets && visualViewport ? visualViewport.offsetLeft : 0)) / scaleX;\n var y = (clientRect.top + (addVisualOffsets && visualViewport ? visualViewport.offsetTop : 0)) / scaleY;\n var width = clientRect.width / scaleX;\n var height = clientRect.height / scaleY;\n return {\n width: width,\n height: height,\n top: y,\n right: x + width,\n bottom: y + height,\n left: x,\n x: x,\n y: y\n };\n}","import getBoundingClientRect from \"./getBoundingClientRect.js\"; // Returns the layout rect of an element relative to its offsetParent. Layout\n// means it doesn't take into account transforms.\n\nexport default function getLayoutRect(element) {\n var clientRect = getBoundingClientRect(element); // Use the clientRect sizes if it's not been transformed.\n // Fixes https://github.com/popperjs/popper-core/issues/1223\n\n var width = element.offsetWidth;\n var height = element.offsetHeight;\n\n if (Math.abs(clientRect.width - width) <= 1) {\n width = clientRect.width;\n }\n\n if (Math.abs(clientRect.height - height) <= 1) {\n height = clientRect.height;\n }\n\n return {\n x: element.offsetLeft,\n y: element.offsetTop,\n width: width,\n height: height\n };\n}","import { isShadowRoot } from \"./instanceOf.js\";\nexport default function contains(parent, child) {\n var rootNode = child.getRootNode && child.getRootNode(); // First, attempt with faster native method\n\n if (parent.contains(child)) {\n return true;\n } // then fallback to custom implementation with Shadow DOM support\n else if (rootNode && isShadowRoot(rootNode)) {\n var next = child;\n\n do {\n if (next && parent.isSameNode(next)) {\n return true;\n } // $FlowFixMe[prop-missing]: need a better way to handle this...\n\n\n next = next.parentNode || next.host;\n } while (next);\n } // Give up, the result is false\n\n\n return false;\n}","import getWindow from \"./getWindow.js\";\nexport default function getComputedStyle(element) {\n return getWindow(element).getComputedStyle(element);\n}","import getNodeName from \"./getNodeName.js\";\nexport default function isTableElement(element) {\n return ['table', 'td', 'th'].indexOf(getNodeName(element)) >= 0;\n}","import { isElement } from \"./instanceOf.js\";\nexport default function getDocumentElement(element) {\n // $FlowFixMe[incompatible-return]: assume body is always available\n return ((isElement(element) ? element.ownerDocument : // $FlowFixMe[prop-missing]\n element.document) || window.document).documentElement;\n}","import getNodeName from \"./getNodeName.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport { isShadowRoot } from \"./instanceOf.js\";\nexport default function getParentNode(element) {\n if (getNodeName(element) === 'html') {\n return element;\n }\n\n return (// this is a quicker (but less type safe) way to save quite some bytes from the bundle\n // $FlowFixMe[incompatible-return]\n // $FlowFixMe[prop-missing]\n element.assignedSlot || // step into the shadow DOM of the parent of a slotted node\n element.parentNode || ( // DOM Element detected\n isShadowRoot(element) ? element.host : null) || // ShadowRoot detected\n // $FlowFixMe[incompatible-call]: HTMLElement is a Node\n getDocumentElement(element) // fallback\n\n );\n}","import getWindow from \"./getWindow.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport getComputedStyle from \"./getComputedStyle.js\";\nimport { isHTMLElement, isShadowRoot } from \"./instanceOf.js\";\nimport isTableElement from \"./isTableElement.js\";\nimport getParentNode from \"./getParentNode.js\";\nimport getUAString from \"../utils/userAgent.js\";\n\nfunction getTrueOffsetParent(element) {\n if (!isHTMLElement(element) || // https://github.com/popperjs/popper-core/issues/837\n getComputedStyle(element).position === 'fixed') {\n return null;\n }\n\n return element.offsetParent;\n} // `.offsetParent` reports `null` for fixed elements, while absolute elements\n// return the containing block\n\n\nfunction getContainingBlock(element) {\n var isFirefox = /firefox/i.test(getUAString());\n var isIE = /Trident/i.test(getUAString());\n\n if (isIE && isHTMLElement(element)) {\n // In IE 9, 10 and 11 fixed elements containing block is always established by the viewport\n var elementCss = getComputedStyle(element);\n\n if (elementCss.position === 'fixed') {\n return null;\n }\n }\n\n var currentNode = getParentNode(element);\n\n if (isShadowRoot(currentNode)) {\n currentNode = currentNode.host;\n }\n\n while (isHTMLElement(currentNode) && ['html', 'body'].indexOf(getNodeName(currentNode)) < 0) {\n var css = getComputedStyle(currentNode); // This is non-exhaustive but covers the most common CSS properties that\n // create a containing block.\n // https://developer.mozilla.org/en-US/docs/Web/CSS/Containing_block#identifying_the_containing_block\n\n if (css.transform !== 'none' || css.perspective !== 'none' || css.contain === 'paint' || ['transform', 'perspective'].indexOf(css.willChange) !== -1 || isFirefox && css.willChange === 'filter' || isFirefox && css.filter && css.filter !== 'none') {\n return currentNode;\n } else {\n currentNode = currentNode.parentNode;\n }\n }\n\n return null;\n} // Gets the closest ancestor positioned element. Handles some edge cases,\n// such as table ancestors and cross browser bugs.\n\n\nexport default function getOffsetParent(element) {\n var window = getWindow(element);\n var offsetParent = getTrueOffsetParent(element);\n\n while (offsetParent && isTableElement(offsetParent) && getComputedStyle(offsetParent).position === 'static') {\n offsetParent = getTrueOffsetParent(offsetParent);\n }\n\n if (offsetParent && (getNodeName(offsetParent) === 'html' || getNodeName(offsetParent) === 'body' && getComputedStyle(offsetParent).position === 'static')) {\n return window;\n }\n\n return offsetParent || getContainingBlock(element) || window;\n}","export default function getMainAxisFromPlacement(placement) {\n return ['top', 'bottom'].indexOf(placement) >= 0 ? 'x' : 'y';\n}","import { max as mathMax, min as mathMin } from \"./math.js\";\nexport function within(min, value, max) {\n return mathMax(min, mathMin(value, max));\n}\nexport function withinMaxClamp(min, value, max) {\n var v = within(min, value, max);\n return v > max ? max : v;\n}","export default function getFreshSideObject() {\n return {\n top: 0,\n right: 0,\n bottom: 0,\n left: 0\n };\n}","import getFreshSideObject from \"./getFreshSideObject.js\";\nexport default function mergePaddingObject(paddingObject) {\n return Object.assign({}, getFreshSideObject(), paddingObject);\n}","export default function expandToHashMap(value, keys) {\n return keys.reduce(function (hashMap, key) {\n hashMap[key] = value;\n return hashMap;\n }, {});\n}","import getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getLayoutRect from \"../dom-utils/getLayoutRect.js\";\nimport contains from \"../dom-utils/contains.js\";\nimport getOffsetParent from \"../dom-utils/getOffsetParent.js\";\nimport getMainAxisFromPlacement from \"../utils/getMainAxisFromPlacement.js\";\nimport { within } from \"../utils/within.js\";\nimport mergePaddingObject from \"../utils/mergePaddingObject.js\";\nimport expandToHashMap from \"../utils/expandToHashMap.js\";\nimport { left, right, basePlacements, top, bottom } from \"../enums.js\"; // eslint-disable-next-line import/no-unused-modules\n\nvar toPaddingObject = function toPaddingObject(padding, state) {\n padding = typeof padding === 'function' ? padding(Object.assign({}, state.rects, {\n placement: state.placement\n })) : padding;\n return mergePaddingObject(typeof padding !== 'number' ? padding : expandToHashMap(padding, basePlacements));\n};\n\nfunction arrow(_ref) {\n var _state$modifiersData$;\n\n var state = _ref.state,\n name = _ref.name,\n options = _ref.options;\n var arrowElement = state.elements.arrow;\n var popperOffsets = state.modifiersData.popperOffsets;\n var basePlacement = getBasePlacement(state.placement);\n var axis = getMainAxisFromPlacement(basePlacement);\n var isVertical = [left, right].indexOf(basePlacement) >= 0;\n var len = isVertical ? 'height' : 'width';\n\n if (!arrowElement || !popperOffsets) {\n return;\n }\n\n var paddingObject = toPaddingObject(options.padding, state);\n var arrowRect = getLayoutRect(arrowElement);\n var minProp = axis === 'y' ? top : left;\n var maxProp = axis === 'y' ? bottom : right;\n var endDiff = state.rects.reference[len] + state.rects.reference[axis] - popperOffsets[axis] - state.rects.popper[len];\n var startDiff = popperOffsets[axis] - state.rects.reference[axis];\n var arrowOffsetParent = getOffsetParent(arrowElement);\n var clientSize = arrowOffsetParent ? axis === 'y' ? arrowOffsetParent.clientHeight || 0 : arrowOffsetParent.clientWidth || 0 : 0;\n var centerToReference = endDiff / 2 - startDiff / 2; // Make sure the arrow doesn't overflow the popper if the center point is\n // outside of the popper bounds\n\n var min = paddingObject[minProp];\n var max = clientSize - arrowRect[len] - paddingObject[maxProp];\n var center = clientSize / 2 - arrowRect[len] / 2 + centerToReference;\n var offset = within(min, center, max); // Prevents breaking syntax highlighting...\n\n var axisProp = axis;\n state.modifiersData[name] = (_state$modifiersData$ = {}, _state$modifiersData$[axisProp] = offset, _state$modifiersData$.centerOffset = offset - center, _state$modifiersData$);\n}\n\nfunction effect(_ref2) {\n var state = _ref2.state,\n options = _ref2.options;\n var _options$element = options.element,\n arrowElement = _options$element === void 0 ? '[data-popper-arrow]' : _options$element;\n\n if (arrowElement == null) {\n return;\n } // CSS selector\n\n\n if (typeof arrowElement === 'string') {\n arrowElement = state.elements.popper.querySelector(arrowElement);\n\n if (!arrowElement) {\n return;\n }\n }\n\n if (!contains(state.elements.popper, arrowElement)) {\n return;\n }\n\n state.elements.arrow = arrowElement;\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'arrow',\n enabled: true,\n phase: 'main',\n fn: arrow,\n effect: effect,\n requires: ['popperOffsets'],\n requiresIfExists: ['preventOverflow']\n};","export default function getVariation(placement) {\n return placement.split('-')[1];\n}","import { top, left, right, bottom, end } from \"../enums.js\";\nimport getOffsetParent from \"../dom-utils/getOffsetParent.js\";\nimport getWindow from \"../dom-utils/getWindow.js\";\nimport getDocumentElement from \"../dom-utils/getDocumentElement.js\";\nimport getComputedStyle from \"../dom-utils/getComputedStyle.js\";\nimport getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getVariation from \"../utils/getVariation.js\";\nimport { round } from \"../utils/math.js\"; // eslint-disable-next-line import/no-unused-modules\n\nvar unsetSides = {\n top: 'auto',\n right: 'auto',\n bottom: 'auto',\n left: 'auto'\n}; // Round the offsets to the nearest suitable subpixel based on the DPR.\n// Zooming can change the DPR, but it seems to report a value that will\n// cleanly divide the values into the appropriate subpixels.\n\nfunction roundOffsetsByDPR(_ref, win) {\n var x = _ref.x,\n y = _ref.y;\n var dpr = win.devicePixelRatio || 1;\n return {\n x: round(x * dpr) / dpr || 0,\n y: round(y * dpr) / dpr || 0\n };\n}\n\nexport function mapToStyles(_ref2) {\n var _Object$assign2;\n\n var popper = _ref2.popper,\n popperRect = _ref2.popperRect,\n placement = _ref2.placement,\n variation = _ref2.variation,\n offsets = _ref2.offsets,\n position = _ref2.position,\n gpuAcceleration = _ref2.gpuAcceleration,\n adaptive = _ref2.adaptive,\n roundOffsets = _ref2.roundOffsets,\n isFixed = _ref2.isFixed;\n var _offsets$x = offsets.x,\n x = _offsets$x === void 0 ? 0 : _offsets$x,\n _offsets$y = offsets.y,\n y = _offsets$y === void 0 ? 0 : _offsets$y;\n\n var _ref3 = typeof roundOffsets === 'function' ? roundOffsets({\n x: x,\n y: y\n }) : {\n x: x,\n y: y\n };\n\n x = _ref3.x;\n y = _ref3.y;\n var hasX = offsets.hasOwnProperty('x');\n var hasY = offsets.hasOwnProperty('y');\n var sideX = left;\n var sideY = top;\n var win = window;\n\n if (adaptive) {\n var offsetParent = getOffsetParent(popper);\n var heightProp = 'clientHeight';\n var widthProp = 'clientWidth';\n\n if (offsetParent === getWindow(popper)) {\n offsetParent = getDocumentElement(popper);\n\n if (getComputedStyle(offsetParent).position !== 'static' && position === 'absolute') {\n heightProp = 'scrollHeight';\n widthProp = 'scrollWidth';\n }\n } // $FlowFixMe[incompatible-cast]: force type refinement, we compare offsetParent with window above, but Flow doesn't detect it\n\n\n offsetParent = offsetParent;\n\n if (placement === top || (placement === left || placement === right) && variation === end) {\n sideY = bottom;\n var offsetY = isFixed && offsetParent === win && win.visualViewport ? win.visualViewport.height : // $FlowFixMe[prop-missing]\n offsetParent[heightProp];\n y -= offsetY - popperRect.height;\n y *= gpuAcceleration ? 1 : -1;\n }\n\n if (placement === left || (placement === top || placement === bottom) && variation === end) {\n sideX = right;\n var offsetX = isFixed && offsetParent === win && win.visualViewport ? win.visualViewport.width : // $FlowFixMe[prop-missing]\n offsetParent[widthProp];\n x -= offsetX - popperRect.width;\n x *= gpuAcceleration ? 1 : -1;\n }\n }\n\n var commonStyles = Object.assign({\n position: position\n }, adaptive && unsetSides);\n\n var _ref4 = roundOffsets === true ? roundOffsetsByDPR({\n x: x,\n y: y\n }, getWindow(popper)) : {\n x: x,\n y: y\n };\n\n x = _ref4.x;\n y = _ref4.y;\n\n if (gpuAcceleration) {\n var _Object$assign;\n\n return Object.assign({}, commonStyles, (_Object$assign = {}, _Object$assign[sideY] = hasY ? '0' : '', _Object$assign[sideX] = hasX ? '0' : '', _Object$assign.transform = (win.devicePixelRatio || 1) <= 1 ? \"translate(\" + x + \"px, \" + y + \"px)\" : \"translate3d(\" + x + \"px, \" + y + \"px, 0)\", _Object$assign));\n }\n\n return Object.assign({}, commonStyles, (_Object$assign2 = {}, _Object$assign2[sideY] = hasY ? y + \"px\" : '', _Object$assign2[sideX] = hasX ? x + \"px\" : '', _Object$assign2.transform = '', _Object$assign2));\n}\n\nfunction computeStyles(_ref5) {\n var state = _ref5.state,\n options = _ref5.options;\n var _options$gpuAccelerat = options.gpuAcceleration,\n gpuAcceleration = _options$gpuAccelerat === void 0 ? true : _options$gpuAccelerat,\n _options$adaptive = options.adaptive,\n adaptive = _options$adaptive === void 0 ? true : _options$adaptive,\n _options$roundOffsets = options.roundOffsets,\n roundOffsets = _options$roundOffsets === void 0 ? true : _options$roundOffsets;\n var commonStyles = {\n placement: getBasePlacement(state.placement),\n variation: getVariation(state.placement),\n popper: state.elements.popper,\n popperRect: state.rects.popper,\n gpuAcceleration: gpuAcceleration,\n isFixed: state.options.strategy === 'fixed'\n };\n\n if (state.modifiersData.popperOffsets != null) {\n state.styles.popper = Object.assign({}, state.styles.popper, mapToStyles(Object.assign({}, commonStyles, {\n offsets: state.modifiersData.popperOffsets,\n position: state.options.strategy,\n adaptive: adaptive,\n roundOffsets: roundOffsets\n })));\n }\n\n if (state.modifiersData.arrow != null) {\n state.styles.arrow = Object.assign({}, state.styles.arrow, mapToStyles(Object.assign({}, commonStyles, {\n offsets: state.modifiersData.arrow,\n position: 'absolute',\n adaptive: false,\n roundOffsets: roundOffsets\n })));\n }\n\n state.attributes.popper = Object.assign({}, state.attributes.popper, {\n 'data-popper-placement': state.placement\n });\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'computeStyles',\n enabled: true,\n phase: 'beforeWrite',\n fn: computeStyles,\n data: {}\n};","import getWindow from \"../dom-utils/getWindow.js\"; // eslint-disable-next-line import/no-unused-modules\n\nvar passive = {\n passive: true\n};\n\nfunction effect(_ref) {\n var state = _ref.state,\n instance = _ref.instance,\n options = _ref.options;\n var _options$scroll = options.scroll,\n scroll = _options$scroll === void 0 ? true : _options$scroll,\n _options$resize = options.resize,\n resize = _options$resize === void 0 ? true : _options$resize;\n var window = getWindow(state.elements.popper);\n var scrollParents = [].concat(state.scrollParents.reference, state.scrollParents.popper);\n\n if (scroll) {\n scrollParents.forEach(function (scrollParent) {\n scrollParent.addEventListener('scroll', instance.update, passive);\n });\n }\n\n if (resize) {\n window.addEventListener('resize', instance.update, passive);\n }\n\n return function () {\n if (scroll) {\n scrollParents.forEach(function (scrollParent) {\n scrollParent.removeEventListener('scroll', instance.update, passive);\n });\n }\n\n if (resize) {\n window.removeEventListener('resize', instance.update, passive);\n }\n };\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'eventListeners',\n enabled: true,\n phase: 'write',\n fn: function fn() {},\n effect: effect,\n data: {}\n};","var hash = {\n left: 'right',\n right: 'left',\n bottom: 'top',\n top: 'bottom'\n};\nexport default function getOppositePlacement(placement) {\n return placement.replace(/left|right|bottom|top/g, function (matched) {\n return hash[matched];\n });\n}","var hash = {\n start: 'end',\n end: 'start'\n};\nexport default function getOppositeVariationPlacement(placement) {\n return placement.replace(/start|end/g, function (matched) {\n return hash[matched];\n });\n}","import getWindow from \"./getWindow.js\";\nexport default function getWindowScroll(node) {\n var win = getWindow(node);\n var scrollLeft = win.pageXOffset;\n var scrollTop = win.pageYOffset;\n return {\n scrollLeft: scrollLeft,\n scrollTop: scrollTop\n };\n}","import getBoundingClientRect from \"./getBoundingClientRect.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport getWindowScroll from \"./getWindowScroll.js\";\nexport default function getWindowScrollBarX(element) {\n // If has a CSS width greater than the viewport, then this will be\n // incorrect for RTL.\n // Popper 1 is broken in this case and never had a bug report so let's assume\n // it's not an issue. I don't think anyone ever specifies width on \n // anyway.\n // Browsers where the left scrollbar doesn't cause an issue report `0` for\n // this (e.g. Edge 2019, IE11, Safari)\n return getBoundingClientRect(getDocumentElement(element)).left + getWindowScroll(element).scrollLeft;\n}","import getWindow from \"./getWindow.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport getWindowScrollBarX from \"./getWindowScrollBarX.js\";\nimport isLayoutViewport from \"./isLayoutViewport.js\";\nexport default function getViewportRect(element, strategy) {\n var win = getWindow(element);\n var html = getDocumentElement(element);\n var visualViewport = win.visualViewport;\n var width = html.clientWidth;\n var height = html.clientHeight;\n var x = 0;\n var y = 0;\n\n if (visualViewport) {\n width = visualViewport.width;\n height = visualViewport.height;\n var layoutViewport = isLayoutViewport();\n\n if (layoutViewport || !layoutViewport && strategy === 'fixed') {\n x = visualViewport.offsetLeft;\n y = visualViewport.offsetTop;\n }\n }\n\n return {\n width: width,\n height: height,\n x: x + getWindowScrollBarX(element),\n y: y\n };\n}","import getDocumentElement from \"./getDocumentElement.js\";\nimport getComputedStyle from \"./getComputedStyle.js\";\nimport getWindowScrollBarX from \"./getWindowScrollBarX.js\";\nimport getWindowScroll from \"./getWindowScroll.js\";\nimport { max } from \"../utils/math.js\"; // Gets the entire size of the scrollable document area, even extending outside\n// of the `` and `` rect bounds if horizontally scrollable\n\nexport default function getDocumentRect(element) {\n var _element$ownerDocumen;\n\n var html = getDocumentElement(element);\n var winScroll = getWindowScroll(element);\n var body = (_element$ownerDocumen = element.ownerDocument) == null ? void 0 : _element$ownerDocumen.body;\n var width = max(html.scrollWidth, html.clientWidth, body ? body.scrollWidth : 0, body ? body.clientWidth : 0);\n var height = max(html.scrollHeight, html.clientHeight, body ? body.scrollHeight : 0, body ? body.clientHeight : 0);\n var x = -winScroll.scrollLeft + getWindowScrollBarX(element);\n var y = -winScroll.scrollTop;\n\n if (getComputedStyle(body || html).direction === 'rtl') {\n x += max(html.clientWidth, body ? body.clientWidth : 0) - width;\n }\n\n return {\n width: width,\n height: height,\n x: x,\n y: y\n };\n}","import getComputedStyle from \"./getComputedStyle.js\";\nexport default function isScrollParent(element) {\n // Firefox wants us to check `-x` and `-y` variations as well\n var _getComputedStyle = getComputedStyle(element),\n overflow = _getComputedStyle.overflow,\n overflowX = _getComputedStyle.overflowX,\n overflowY = _getComputedStyle.overflowY;\n\n return /auto|scroll|overlay|hidden/.test(overflow + overflowY + overflowX);\n}","import getParentNode from \"./getParentNode.js\";\nimport isScrollParent from \"./isScrollParent.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport { isHTMLElement } from \"./instanceOf.js\";\nexport default function getScrollParent(node) {\n if (['html', 'body', '#document'].indexOf(getNodeName(node)) >= 0) {\n // $FlowFixMe[incompatible-return]: assume body is always available\n return node.ownerDocument.body;\n }\n\n if (isHTMLElement(node) && isScrollParent(node)) {\n return node;\n }\n\n return getScrollParent(getParentNode(node));\n}","import getScrollParent from \"./getScrollParent.js\";\nimport getParentNode from \"./getParentNode.js\";\nimport getWindow from \"./getWindow.js\";\nimport isScrollParent from \"./isScrollParent.js\";\n/*\ngiven a DOM element, return the list of all scroll parents, up the list of ancesors\nuntil we get to the top window object. This list is what we attach scroll listeners\nto, because if any of these parent elements scroll, we'll need to re-calculate the\nreference element's position.\n*/\n\nexport default function listScrollParents(element, list) {\n var _element$ownerDocumen;\n\n if (list === void 0) {\n list = [];\n }\n\n var scrollParent = getScrollParent(element);\n var isBody = scrollParent === ((_element$ownerDocumen = element.ownerDocument) == null ? void 0 : _element$ownerDocumen.body);\n var win = getWindow(scrollParent);\n var target = isBody ? [win].concat(win.visualViewport || [], isScrollParent(scrollParent) ? scrollParent : []) : scrollParent;\n var updatedList = list.concat(target);\n return isBody ? updatedList : // $FlowFixMe[incompatible-call]: isBody tells us target will be an HTMLElement here\n updatedList.concat(listScrollParents(getParentNode(target)));\n}","export default function rectToClientRect(rect) {\n return Object.assign({}, rect, {\n left: rect.x,\n top: rect.y,\n right: rect.x + rect.width,\n bottom: rect.y + rect.height\n });\n}","import { viewport } from \"../enums.js\";\nimport getViewportRect from \"./getViewportRect.js\";\nimport getDocumentRect from \"./getDocumentRect.js\";\nimport listScrollParents from \"./listScrollParents.js\";\nimport getOffsetParent from \"./getOffsetParent.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport getComputedStyle from \"./getComputedStyle.js\";\nimport { isElement, isHTMLElement } from \"./instanceOf.js\";\nimport getBoundingClientRect from \"./getBoundingClientRect.js\";\nimport getParentNode from \"./getParentNode.js\";\nimport contains from \"./contains.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport rectToClientRect from \"../utils/rectToClientRect.js\";\nimport { max, min } from \"../utils/math.js\";\n\nfunction getInnerBoundingClientRect(element, strategy) {\n var rect = getBoundingClientRect(element, false, strategy === 'fixed');\n rect.top = rect.top + element.clientTop;\n rect.left = rect.left + element.clientLeft;\n rect.bottom = rect.top + element.clientHeight;\n rect.right = rect.left + element.clientWidth;\n rect.width = element.clientWidth;\n rect.height = element.clientHeight;\n rect.x = rect.left;\n rect.y = rect.top;\n return rect;\n}\n\nfunction getClientRectFromMixedType(element, clippingParent, strategy) {\n return clippingParent === viewport ? rectToClientRect(getViewportRect(element, strategy)) : isElement(clippingParent) ? getInnerBoundingClientRect(clippingParent, strategy) : rectToClientRect(getDocumentRect(getDocumentElement(element)));\n} // A \"clipping parent\" is an overflowable container with the characteristic of\n// clipping (or hiding) overflowing elements with a position different from\n// `initial`\n\n\nfunction getClippingParents(element) {\n var clippingParents = listScrollParents(getParentNode(element));\n var canEscapeClipping = ['absolute', 'fixed'].indexOf(getComputedStyle(element).position) >= 0;\n var clipperElement = canEscapeClipping && isHTMLElement(element) ? getOffsetParent(element) : element;\n\n if (!isElement(clipperElement)) {\n return [];\n } // $FlowFixMe[incompatible-return]: https://github.com/facebook/flow/issues/1414\n\n\n return clippingParents.filter(function (clippingParent) {\n return isElement(clippingParent) && contains(clippingParent, clipperElement) && getNodeName(clippingParent) !== 'body';\n });\n} // Gets the maximum area that the element is visible in due to any number of\n// clipping parents\n\n\nexport default function getClippingRect(element, boundary, rootBoundary, strategy) {\n var mainClippingParents = boundary === 'clippingParents' ? getClippingParents(element) : [].concat(boundary);\n var clippingParents = [].concat(mainClippingParents, [rootBoundary]);\n var firstClippingParent = clippingParents[0];\n var clippingRect = clippingParents.reduce(function (accRect, clippingParent) {\n var rect = getClientRectFromMixedType(element, clippingParent, strategy);\n accRect.top = max(rect.top, accRect.top);\n accRect.right = min(rect.right, accRect.right);\n accRect.bottom = min(rect.bottom, accRect.bottom);\n accRect.left = max(rect.left, accRect.left);\n return accRect;\n }, getClientRectFromMixedType(element, firstClippingParent, strategy));\n clippingRect.width = clippingRect.right - clippingRect.left;\n clippingRect.height = clippingRect.bottom - clippingRect.top;\n clippingRect.x = clippingRect.left;\n clippingRect.y = clippingRect.top;\n return clippingRect;\n}","import getBasePlacement from \"./getBasePlacement.js\";\nimport getVariation from \"./getVariation.js\";\nimport getMainAxisFromPlacement from \"./getMainAxisFromPlacement.js\";\nimport { top, right, bottom, left, start, end } from \"../enums.js\";\nexport default function computeOffsets(_ref) {\n var reference = _ref.reference,\n element = _ref.element,\n placement = _ref.placement;\n var basePlacement = placement ? getBasePlacement(placement) : null;\n var variation = placement ? getVariation(placement) : null;\n var commonX = reference.x + reference.width / 2 - element.width / 2;\n var commonY = reference.y + reference.height / 2 - element.height / 2;\n var offsets;\n\n switch (basePlacement) {\n case top:\n offsets = {\n x: commonX,\n y: reference.y - element.height\n };\n break;\n\n case bottom:\n offsets = {\n x: commonX,\n y: reference.y + reference.height\n };\n break;\n\n case right:\n offsets = {\n x: reference.x + reference.width,\n y: commonY\n };\n break;\n\n case left:\n offsets = {\n x: reference.x - element.width,\n y: commonY\n };\n break;\n\n default:\n offsets = {\n x: reference.x,\n y: reference.y\n };\n }\n\n var mainAxis = basePlacement ? getMainAxisFromPlacement(basePlacement) : null;\n\n if (mainAxis != null) {\n var len = mainAxis === 'y' ? 'height' : 'width';\n\n switch (variation) {\n case start:\n offsets[mainAxis] = offsets[mainAxis] - (reference[len] / 2 - element[len] / 2);\n break;\n\n case end:\n offsets[mainAxis] = offsets[mainAxis] + (reference[len] / 2 - element[len] / 2);\n break;\n\n default:\n }\n }\n\n return offsets;\n}","import getClippingRect from \"../dom-utils/getClippingRect.js\";\nimport getDocumentElement from \"../dom-utils/getDocumentElement.js\";\nimport getBoundingClientRect from \"../dom-utils/getBoundingClientRect.js\";\nimport computeOffsets from \"./computeOffsets.js\";\nimport rectToClientRect from \"./rectToClientRect.js\";\nimport { clippingParents, reference, popper, bottom, top, right, basePlacements, viewport } from \"../enums.js\";\nimport { isElement } from \"../dom-utils/instanceOf.js\";\nimport mergePaddingObject from \"./mergePaddingObject.js\";\nimport expandToHashMap from \"./expandToHashMap.js\"; // eslint-disable-next-line import/no-unused-modules\n\nexport default function detectOverflow(state, options) {\n if (options === void 0) {\n options = {};\n }\n\n var _options = options,\n _options$placement = _options.placement,\n placement = _options$placement === void 0 ? state.placement : _options$placement,\n _options$strategy = _options.strategy,\n strategy = _options$strategy === void 0 ? state.strategy : _options$strategy,\n _options$boundary = _options.boundary,\n boundary = _options$boundary === void 0 ? clippingParents : _options$boundary,\n _options$rootBoundary = _options.rootBoundary,\n rootBoundary = _options$rootBoundary === void 0 ? viewport : _options$rootBoundary,\n _options$elementConte = _options.elementContext,\n elementContext = _options$elementConte === void 0 ? popper : _options$elementConte,\n _options$altBoundary = _options.altBoundary,\n altBoundary = _options$altBoundary === void 0 ? false : _options$altBoundary,\n _options$padding = _options.padding,\n padding = _options$padding === void 0 ? 0 : _options$padding;\n var paddingObject = mergePaddingObject(typeof padding !== 'number' ? padding : expandToHashMap(padding, basePlacements));\n var altContext = elementContext === popper ? reference : popper;\n var popperRect = state.rects.popper;\n var element = state.elements[altBoundary ? altContext : elementContext];\n var clippingClientRect = getClippingRect(isElement(element) ? element : element.contextElement || getDocumentElement(state.elements.popper), boundary, rootBoundary, strategy);\n var referenceClientRect = getBoundingClientRect(state.elements.reference);\n var popperOffsets = computeOffsets({\n reference: referenceClientRect,\n element: popperRect,\n strategy: 'absolute',\n placement: placement\n });\n var popperClientRect = rectToClientRect(Object.assign({}, popperRect, popperOffsets));\n var elementClientRect = elementContext === popper ? popperClientRect : referenceClientRect; // positive = overflowing the clipping rect\n // 0 or negative = within the clipping rect\n\n var overflowOffsets = {\n top: clippingClientRect.top - elementClientRect.top + paddingObject.top,\n bottom: elementClientRect.bottom - clippingClientRect.bottom + paddingObject.bottom,\n left: clippingClientRect.left - elementClientRect.left + paddingObject.left,\n right: elementClientRect.right - clippingClientRect.right + paddingObject.right\n };\n var offsetData = state.modifiersData.offset; // Offsets can be applied only to the popper element\n\n if (elementContext === popper && offsetData) {\n var offset = offsetData[placement];\n Object.keys(overflowOffsets).forEach(function (key) {\n var multiply = [right, bottom].indexOf(key) >= 0 ? 1 : -1;\n var axis = [top, bottom].indexOf(key) >= 0 ? 'y' : 'x';\n overflowOffsets[key] += offset[axis] * multiply;\n });\n }\n\n return overflowOffsets;\n}","import getVariation from \"./getVariation.js\";\nimport { variationPlacements, basePlacements, placements as allPlacements } from \"../enums.js\";\nimport detectOverflow from \"./detectOverflow.js\";\nimport getBasePlacement from \"./getBasePlacement.js\";\nexport default function computeAutoPlacement(state, options) {\n if (options === void 0) {\n options = {};\n }\n\n var _options = options,\n placement = _options.placement,\n boundary = _options.boundary,\n rootBoundary = _options.rootBoundary,\n padding = _options.padding,\n flipVariations = _options.flipVariations,\n _options$allowedAutoP = _options.allowedAutoPlacements,\n allowedAutoPlacements = _options$allowedAutoP === void 0 ? allPlacements : _options$allowedAutoP;\n var variation = getVariation(placement);\n var placements = variation ? flipVariations ? variationPlacements : variationPlacements.filter(function (placement) {\n return getVariation(placement) === variation;\n }) : basePlacements;\n var allowedPlacements = placements.filter(function (placement) {\n return allowedAutoPlacements.indexOf(placement) >= 0;\n });\n\n if (allowedPlacements.length === 0) {\n allowedPlacements = placements;\n } // $FlowFixMe[incompatible-type]: Flow seems to have problems with two array unions...\n\n\n var overflows = allowedPlacements.reduce(function (acc, placement) {\n acc[placement] = detectOverflow(state, {\n placement: placement,\n boundary: boundary,\n rootBoundary: rootBoundary,\n padding: padding\n })[getBasePlacement(placement)];\n return acc;\n }, {});\n return Object.keys(overflows).sort(function (a, b) {\n return overflows[a] - overflows[b];\n });\n}","import getOppositePlacement from \"../utils/getOppositePlacement.js\";\nimport getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getOppositeVariationPlacement from \"../utils/getOppositeVariationPlacement.js\";\nimport detectOverflow from \"../utils/detectOverflow.js\";\nimport computeAutoPlacement from \"../utils/computeAutoPlacement.js\";\nimport { bottom, top, start, right, left, auto } from \"../enums.js\";\nimport getVariation from \"../utils/getVariation.js\"; // eslint-disable-next-line import/no-unused-modules\n\nfunction getExpandedFallbackPlacements(placement) {\n if (getBasePlacement(placement) === auto) {\n return [];\n }\n\n var oppositePlacement = getOppositePlacement(placement);\n return [getOppositeVariationPlacement(placement), oppositePlacement, getOppositeVariationPlacement(oppositePlacement)];\n}\n\nfunction flip(_ref) {\n var state = _ref.state,\n options = _ref.options,\n name = _ref.name;\n\n if (state.modifiersData[name]._skip) {\n return;\n }\n\n var _options$mainAxis = options.mainAxis,\n checkMainAxis = _options$mainAxis === void 0 ? true : _options$mainAxis,\n _options$altAxis = options.altAxis,\n checkAltAxis = _options$altAxis === void 0 ? true : _options$altAxis,\n specifiedFallbackPlacements = options.fallbackPlacements,\n padding = options.padding,\n boundary = options.boundary,\n rootBoundary = options.rootBoundary,\n altBoundary = options.altBoundary,\n _options$flipVariatio = options.flipVariations,\n flipVariations = _options$flipVariatio === void 0 ? true : _options$flipVariatio,\n allowedAutoPlacements = options.allowedAutoPlacements;\n var preferredPlacement = state.options.placement;\n var basePlacement = getBasePlacement(preferredPlacement);\n var isBasePlacement = basePlacement === preferredPlacement;\n var fallbackPlacements = specifiedFallbackPlacements || (isBasePlacement || !flipVariations ? [getOppositePlacement(preferredPlacement)] : getExpandedFallbackPlacements(preferredPlacement));\n var placements = [preferredPlacement].concat(fallbackPlacements).reduce(function (acc, placement) {\n return acc.concat(getBasePlacement(placement) === auto ? computeAutoPlacement(state, {\n placement: placement,\n boundary: boundary,\n rootBoundary: rootBoundary,\n padding: padding,\n flipVariations: flipVariations,\n allowedAutoPlacements: allowedAutoPlacements\n }) : placement);\n }, []);\n var referenceRect = state.rects.reference;\n var popperRect = state.rects.popper;\n var checksMap = new Map();\n var makeFallbackChecks = true;\n var firstFittingPlacement = placements[0];\n\n for (var i = 0; i < placements.length; i++) {\n var placement = placements[i];\n\n var _basePlacement = getBasePlacement(placement);\n\n var isStartVariation = getVariation(placement) === start;\n var isVertical = [top, bottom].indexOf(_basePlacement) >= 0;\n var len = isVertical ? 'width' : 'height';\n var overflow = detectOverflow(state, {\n placement: placement,\n boundary: boundary,\n rootBoundary: rootBoundary,\n altBoundary: altBoundary,\n padding: padding\n });\n var mainVariationSide = isVertical ? isStartVariation ? right : left : isStartVariation ? bottom : top;\n\n if (referenceRect[len] > popperRect[len]) {\n mainVariationSide = getOppositePlacement(mainVariationSide);\n }\n\n var altVariationSide = getOppositePlacement(mainVariationSide);\n var checks = [];\n\n if (checkMainAxis) {\n checks.push(overflow[_basePlacement] <= 0);\n }\n\n if (checkAltAxis) {\n checks.push(overflow[mainVariationSide] <= 0, overflow[altVariationSide] <= 0);\n }\n\n if (checks.every(function (check) {\n return check;\n })) {\n firstFittingPlacement = placement;\n makeFallbackChecks = false;\n break;\n }\n\n checksMap.set(placement, checks);\n }\n\n if (makeFallbackChecks) {\n // `2` may be desired in some cases – research later\n var numberOfChecks = flipVariations ? 3 : 1;\n\n var _loop = function _loop(_i) {\n var fittingPlacement = placements.find(function (placement) {\n var checks = checksMap.get(placement);\n\n if (checks) {\n return checks.slice(0, _i).every(function (check) {\n return check;\n });\n }\n });\n\n if (fittingPlacement) {\n firstFittingPlacement = fittingPlacement;\n return \"break\";\n }\n };\n\n for (var _i = numberOfChecks; _i > 0; _i--) {\n var _ret = _loop(_i);\n\n if (_ret === \"break\") break;\n }\n }\n\n if (state.placement !== firstFittingPlacement) {\n state.modifiersData[name]._skip = true;\n state.placement = firstFittingPlacement;\n state.reset = true;\n }\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'flip',\n enabled: true,\n phase: 'main',\n fn: flip,\n requiresIfExists: ['offset'],\n data: {\n _skip: false\n }\n};","import { top, bottom, left, right } from \"../enums.js\";\nimport detectOverflow from \"../utils/detectOverflow.js\";\n\nfunction getSideOffsets(overflow, rect, preventedOffsets) {\n if (preventedOffsets === void 0) {\n preventedOffsets = {\n x: 0,\n y: 0\n };\n }\n\n return {\n top: overflow.top - rect.height - preventedOffsets.y,\n right: overflow.right - rect.width + preventedOffsets.x,\n bottom: overflow.bottom - rect.height + preventedOffsets.y,\n left: overflow.left - rect.width - preventedOffsets.x\n };\n}\n\nfunction isAnySideFullyClipped(overflow) {\n return [top, right, bottom, left].some(function (side) {\n return overflow[side] >= 0;\n });\n}\n\nfunction hide(_ref) {\n var state = _ref.state,\n name = _ref.name;\n var referenceRect = state.rects.reference;\n var popperRect = state.rects.popper;\n var preventedOffsets = state.modifiersData.preventOverflow;\n var referenceOverflow = detectOverflow(state, {\n elementContext: 'reference'\n });\n var popperAltOverflow = detectOverflow(state, {\n altBoundary: true\n });\n var referenceClippingOffsets = getSideOffsets(referenceOverflow, referenceRect);\n var popperEscapeOffsets = getSideOffsets(popperAltOverflow, popperRect, preventedOffsets);\n var isReferenceHidden = isAnySideFullyClipped(referenceClippingOffsets);\n var hasPopperEscaped = isAnySideFullyClipped(popperEscapeOffsets);\n state.modifiersData[name] = {\n referenceClippingOffsets: referenceClippingOffsets,\n popperEscapeOffsets: popperEscapeOffsets,\n isReferenceHidden: isReferenceHidden,\n hasPopperEscaped: hasPopperEscaped\n };\n state.attributes.popper = Object.assign({}, state.attributes.popper, {\n 'data-popper-reference-hidden': isReferenceHidden,\n 'data-popper-escaped': hasPopperEscaped\n });\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'hide',\n enabled: true,\n phase: 'main',\n requiresIfExists: ['preventOverflow'],\n fn: hide\n};","import getBasePlacement from \"../utils/getBasePlacement.js\";\nimport { top, left, right, placements } from \"../enums.js\"; // eslint-disable-next-line import/no-unused-modules\n\nexport function distanceAndSkiddingToXY(placement, rects, offset) {\n var basePlacement = getBasePlacement(placement);\n var invertDistance = [left, top].indexOf(basePlacement) >= 0 ? -1 : 1;\n\n var _ref = typeof offset === 'function' ? offset(Object.assign({}, rects, {\n placement: placement\n })) : offset,\n skidding = _ref[0],\n distance = _ref[1];\n\n skidding = skidding || 0;\n distance = (distance || 0) * invertDistance;\n return [left, right].indexOf(basePlacement) >= 0 ? {\n x: distance,\n y: skidding\n } : {\n x: skidding,\n y: distance\n };\n}\n\nfunction offset(_ref2) {\n var state = _ref2.state,\n options = _ref2.options,\n name = _ref2.name;\n var _options$offset = options.offset,\n offset = _options$offset === void 0 ? [0, 0] : _options$offset;\n var data = placements.reduce(function (acc, placement) {\n acc[placement] = distanceAndSkiddingToXY(placement, state.rects, offset);\n return acc;\n }, {});\n var _data$state$placement = data[state.placement],\n x = _data$state$placement.x,\n y = _data$state$placement.y;\n\n if (state.modifiersData.popperOffsets != null) {\n state.modifiersData.popperOffsets.x += x;\n state.modifiersData.popperOffsets.y += y;\n }\n\n state.modifiersData[name] = data;\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'offset',\n enabled: true,\n phase: 'main',\n requires: ['popperOffsets'],\n fn: offset\n};","import computeOffsets from \"../utils/computeOffsets.js\";\n\nfunction popperOffsets(_ref) {\n var state = _ref.state,\n name = _ref.name;\n // Offsets are the actual position the popper needs to have to be\n // properly positioned near its reference element\n // This is the most basic placement, and will be adjusted by\n // the modifiers in the next step\n state.modifiersData[name] = computeOffsets({\n reference: state.rects.reference,\n element: state.rects.popper,\n strategy: 'absolute',\n placement: state.placement\n });\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'popperOffsets',\n enabled: true,\n phase: 'read',\n fn: popperOffsets,\n data: {}\n};","export default function getAltAxis(axis) {\n return axis === 'x' ? 'y' : 'x';\n}","import { top, left, right, bottom, start } from \"../enums.js\";\nimport getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getMainAxisFromPlacement from \"../utils/getMainAxisFromPlacement.js\";\nimport getAltAxis from \"../utils/getAltAxis.js\";\nimport { within, withinMaxClamp } from \"../utils/within.js\";\nimport getLayoutRect from \"../dom-utils/getLayoutRect.js\";\nimport getOffsetParent from \"../dom-utils/getOffsetParent.js\";\nimport detectOverflow from \"../utils/detectOverflow.js\";\nimport getVariation from \"../utils/getVariation.js\";\nimport getFreshSideObject from \"../utils/getFreshSideObject.js\";\nimport { min as mathMin, max as mathMax } from \"../utils/math.js\";\n\nfunction preventOverflow(_ref) {\n var state = _ref.state,\n options = _ref.options,\n name = _ref.name;\n var _options$mainAxis = options.mainAxis,\n checkMainAxis = _options$mainAxis === void 0 ? true : _options$mainAxis,\n _options$altAxis = options.altAxis,\n checkAltAxis = _options$altAxis === void 0 ? false : _options$altAxis,\n boundary = options.boundary,\n rootBoundary = options.rootBoundary,\n altBoundary = options.altBoundary,\n padding = options.padding,\n _options$tether = options.tether,\n tether = _options$tether === void 0 ? true : _options$tether,\n _options$tetherOffset = options.tetherOffset,\n tetherOffset = _options$tetherOffset === void 0 ? 0 : _options$tetherOffset;\n var overflow = detectOverflow(state, {\n boundary: boundary,\n rootBoundary: rootBoundary,\n padding: padding,\n altBoundary: altBoundary\n });\n var basePlacement = getBasePlacement(state.placement);\n var variation = getVariation(state.placement);\n var isBasePlacement = !variation;\n var mainAxis = getMainAxisFromPlacement(basePlacement);\n var altAxis = getAltAxis(mainAxis);\n var popperOffsets = state.modifiersData.popperOffsets;\n var referenceRect = state.rects.reference;\n var popperRect = state.rects.popper;\n var tetherOffsetValue = typeof tetherOffset === 'function' ? tetherOffset(Object.assign({}, state.rects, {\n placement: state.placement\n })) : tetherOffset;\n var normalizedTetherOffsetValue = typeof tetherOffsetValue === 'number' ? {\n mainAxis: tetherOffsetValue,\n altAxis: tetherOffsetValue\n } : Object.assign({\n mainAxis: 0,\n altAxis: 0\n }, tetherOffsetValue);\n var offsetModifierState = state.modifiersData.offset ? state.modifiersData.offset[state.placement] : null;\n var data = {\n x: 0,\n y: 0\n };\n\n if (!popperOffsets) {\n return;\n }\n\n if (checkMainAxis) {\n var _offsetModifierState$;\n\n var mainSide = mainAxis === 'y' ? top : left;\n var altSide = mainAxis === 'y' ? bottom : right;\n var len = mainAxis === 'y' ? 'height' : 'width';\n var offset = popperOffsets[mainAxis];\n var min = offset + overflow[mainSide];\n var max = offset - overflow[altSide];\n var additive = tether ? -popperRect[len] / 2 : 0;\n var minLen = variation === start ? referenceRect[len] : popperRect[len];\n var maxLen = variation === start ? -popperRect[len] : -referenceRect[len]; // We need to include the arrow in the calculation so the arrow doesn't go\n // outside the reference bounds\n\n var arrowElement = state.elements.arrow;\n var arrowRect = tether && arrowElement ? getLayoutRect(arrowElement) : {\n width: 0,\n height: 0\n };\n var arrowPaddingObject = state.modifiersData['arrow#persistent'] ? state.modifiersData['arrow#persistent'].padding : getFreshSideObject();\n var arrowPaddingMin = arrowPaddingObject[mainSide];\n var arrowPaddingMax = arrowPaddingObject[altSide]; // If the reference length is smaller than the arrow length, we don't want\n // to include its full size in the calculation. If the reference is small\n // and near the edge of a boundary, the popper can overflow even if the\n // reference is not overflowing as well (e.g. virtual elements with no\n // width or height)\n\n var arrowLen = within(0, referenceRect[len], arrowRect[len]);\n var minOffset = isBasePlacement ? referenceRect[len] / 2 - additive - arrowLen - arrowPaddingMin - normalizedTetherOffsetValue.mainAxis : minLen - arrowLen - arrowPaddingMin - normalizedTetherOffsetValue.mainAxis;\n var maxOffset = isBasePlacement ? -referenceRect[len] / 2 + additive + arrowLen + arrowPaddingMax + normalizedTetherOffsetValue.mainAxis : maxLen + arrowLen + arrowPaddingMax + normalizedTetherOffsetValue.mainAxis;\n var arrowOffsetParent = state.elements.arrow && getOffsetParent(state.elements.arrow);\n var clientOffset = arrowOffsetParent ? mainAxis === 'y' ? arrowOffsetParent.clientTop || 0 : arrowOffsetParent.clientLeft || 0 : 0;\n var offsetModifierValue = (_offsetModifierState$ = offsetModifierState == null ? void 0 : offsetModifierState[mainAxis]) != null ? _offsetModifierState$ : 0;\n var tetherMin = offset + minOffset - offsetModifierValue - clientOffset;\n var tetherMax = offset + maxOffset - offsetModifierValue;\n var preventedOffset = within(tether ? mathMin(min, tetherMin) : min, offset, tether ? mathMax(max, tetherMax) : max);\n popperOffsets[mainAxis] = preventedOffset;\n data[mainAxis] = preventedOffset - offset;\n }\n\n if (checkAltAxis) {\n var _offsetModifierState$2;\n\n var _mainSide = mainAxis === 'x' ? top : left;\n\n var _altSide = mainAxis === 'x' ? bottom : right;\n\n var _offset = popperOffsets[altAxis];\n\n var _len = altAxis === 'y' ? 'height' : 'width';\n\n var _min = _offset + overflow[_mainSide];\n\n var _max = _offset - overflow[_altSide];\n\n var isOriginSide = [top, left].indexOf(basePlacement) !== -1;\n\n var _offsetModifierValue = (_offsetModifierState$2 = offsetModifierState == null ? void 0 : offsetModifierState[altAxis]) != null ? _offsetModifierState$2 : 0;\n\n var _tetherMin = isOriginSide ? _min : _offset - referenceRect[_len] - popperRect[_len] - _offsetModifierValue + normalizedTetherOffsetValue.altAxis;\n\n var _tetherMax = isOriginSide ? _offset + referenceRect[_len] + popperRect[_len] - _offsetModifierValue - normalizedTetherOffsetValue.altAxis : _max;\n\n var _preventedOffset = tether && isOriginSide ? withinMaxClamp(_tetherMin, _offset, _tetherMax) : within(tether ? _tetherMin : _min, _offset, tether ? _tetherMax : _max);\n\n popperOffsets[altAxis] = _preventedOffset;\n data[altAxis] = _preventedOffset - _offset;\n }\n\n state.modifiersData[name] = data;\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'preventOverflow',\n enabled: true,\n phase: 'main',\n fn: preventOverflow,\n requiresIfExists: ['offset']\n};","export default function getHTMLElementScroll(element) {\n return {\n scrollLeft: element.scrollLeft,\n scrollTop: element.scrollTop\n };\n}","import getWindowScroll from \"./getWindowScroll.js\";\nimport getWindow from \"./getWindow.js\";\nimport { isHTMLElement } from \"./instanceOf.js\";\nimport getHTMLElementScroll from \"./getHTMLElementScroll.js\";\nexport default function getNodeScroll(node) {\n if (node === getWindow(node) || !isHTMLElement(node)) {\n return getWindowScroll(node);\n } else {\n return getHTMLElementScroll(node);\n }\n}","import getBoundingClientRect from \"./getBoundingClientRect.js\";\nimport getNodeScroll from \"./getNodeScroll.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport { isHTMLElement } from \"./instanceOf.js\";\nimport getWindowScrollBarX from \"./getWindowScrollBarX.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport isScrollParent from \"./isScrollParent.js\";\nimport { round } from \"../utils/math.js\";\n\nfunction isElementScaled(element) {\n var rect = element.getBoundingClientRect();\n var scaleX = round(rect.width) / element.offsetWidth || 1;\n var scaleY = round(rect.height) / element.offsetHeight || 1;\n return scaleX !== 1 || scaleY !== 1;\n} // Returns the composite rect of an element relative to its offsetParent.\n// Composite means it takes into account transforms as well as layout.\n\n\nexport default function getCompositeRect(elementOrVirtualElement, offsetParent, isFixed) {\n if (isFixed === void 0) {\n isFixed = false;\n }\n\n var isOffsetParentAnElement = isHTMLElement(offsetParent);\n var offsetParentIsScaled = isHTMLElement(offsetParent) && isElementScaled(offsetParent);\n var documentElement = getDocumentElement(offsetParent);\n var rect = getBoundingClientRect(elementOrVirtualElement, offsetParentIsScaled, isFixed);\n var scroll = {\n scrollLeft: 0,\n scrollTop: 0\n };\n var offsets = {\n x: 0,\n y: 0\n };\n\n if (isOffsetParentAnElement || !isOffsetParentAnElement && !isFixed) {\n if (getNodeName(offsetParent) !== 'body' || // https://github.com/popperjs/popper-core/issues/1078\n isScrollParent(documentElement)) {\n scroll = getNodeScroll(offsetParent);\n }\n\n if (isHTMLElement(offsetParent)) {\n offsets = getBoundingClientRect(offsetParent, true);\n offsets.x += offsetParent.clientLeft;\n offsets.y += offsetParent.clientTop;\n } else if (documentElement) {\n offsets.x = getWindowScrollBarX(documentElement);\n }\n }\n\n return {\n x: rect.left + scroll.scrollLeft - offsets.x,\n y: rect.top + scroll.scrollTop - offsets.y,\n width: rect.width,\n height: rect.height\n };\n}","import { modifierPhases } from \"../enums.js\"; // source: https://stackoverflow.com/questions/49875255\n\nfunction order(modifiers) {\n var map = new Map();\n var visited = new Set();\n var result = [];\n modifiers.forEach(function (modifier) {\n map.set(modifier.name, modifier);\n }); // On visiting object, check for its dependencies and visit them recursively\n\n function sort(modifier) {\n visited.add(modifier.name);\n var requires = [].concat(modifier.requires || [], modifier.requiresIfExists || []);\n requires.forEach(function (dep) {\n if (!visited.has(dep)) {\n var depModifier = map.get(dep);\n\n if (depModifier) {\n sort(depModifier);\n }\n }\n });\n result.push(modifier);\n }\n\n modifiers.forEach(function (modifier) {\n if (!visited.has(modifier.name)) {\n // check for visited object\n sort(modifier);\n }\n });\n return result;\n}\n\nexport default function orderModifiers(modifiers) {\n // order based on dependencies\n var orderedModifiers = order(modifiers); // order based on phase\n\n return modifierPhases.reduce(function (acc, phase) {\n return acc.concat(orderedModifiers.filter(function (modifier) {\n return modifier.phase === phase;\n }));\n }, []);\n}","export default function debounce(fn) {\n var pending;\n return function () {\n if (!pending) {\n pending = new Promise(function (resolve) {\n Promise.resolve().then(function () {\n pending = undefined;\n resolve(fn());\n });\n });\n }\n\n return pending;\n };\n}","export default function mergeByName(modifiers) {\n var merged = modifiers.reduce(function (merged, current) {\n var existing = merged[current.name];\n merged[current.name] = existing ? Object.assign({}, existing, current, {\n options: Object.assign({}, existing.options, current.options),\n data: Object.assign({}, existing.data, current.data)\n }) : current;\n return merged;\n }, {}); // IE11 does not support Object.values\n\n return Object.keys(merged).map(function (key) {\n return merged[key];\n });\n}","import getCompositeRect from \"./dom-utils/getCompositeRect.js\";\nimport getLayoutRect from \"./dom-utils/getLayoutRect.js\";\nimport listScrollParents from \"./dom-utils/listScrollParents.js\";\nimport getOffsetParent from \"./dom-utils/getOffsetParent.js\";\nimport orderModifiers from \"./utils/orderModifiers.js\";\nimport debounce from \"./utils/debounce.js\";\nimport mergeByName from \"./utils/mergeByName.js\";\nimport detectOverflow from \"./utils/detectOverflow.js\";\nimport { isElement } from \"./dom-utils/instanceOf.js\";\nvar DEFAULT_OPTIONS = {\n placement: 'bottom',\n modifiers: [],\n strategy: 'absolute'\n};\n\nfunction areValidElements() {\n for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {\n args[_key] = arguments[_key];\n }\n\n return !args.some(function (element) {\n return !(element && typeof element.getBoundingClientRect === 'function');\n });\n}\n\nexport function popperGenerator(generatorOptions) {\n if (generatorOptions === void 0) {\n generatorOptions = {};\n }\n\n var _generatorOptions = generatorOptions,\n _generatorOptions$def = _generatorOptions.defaultModifiers,\n defaultModifiers = _generatorOptions$def === void 0 ? [] : _generatorOptions$def,\n _generatorOptions$def2 = _generatorOptions.defaultOptions,\n defaultOptions = _generatorOptions$def2 === void 0 ? DEFAULT_OPTIONS : _generatorOptions$def2;\n return function createPopper(reference, popper, options) {\n if (options === void 0) {\n options = defaultOptions;\n }\n\n var state = {\n placement: 'bottom',\n orderedModifiers: [],\n options: Object.assign({}, DEFAULT_OPTIONS, defaultOptions),\n modifiersData: {},\n elements: {\n reference: reference,\n popper: popper\n },\n attributes: {},\n styles: {}\n };\n var effectCleanupFns = [];\n var isDestroyed = false;\n var instance = {\n state: state,\n setOptions: function setOptions(setOptionsAction) {\n var options = typeof setOptionsAction === 'function' ? setOptionsAction(state.options) : setOptionsAction;\n cleanupModifierEffects();\n state.options = Object.assign({}, defaultOptions, state.options, options);\n state.scrollParents = {\n reference: isElement(reference) ? listScrollParents(reference) : reference.contextElement ? listScrollParents(reference.contextElement) : [],\n popper: listScrollParents(popper)\n }; // Orders the modifiers based on their dependencies and `phase`\n // properties\n\n var orderedModifiers = orderModifiers(mergeByName([].concat(defaultModifiers, state.options.modifiers))); // Strip out disabled modifiers\n\n state.orderedModifiers = orderedModifiers.filter(function (m) {\n return m.enabled;\n });\n runModifierEffects();\n return instance.update();\n },\n // Sync update – it will always be executed, even if not necessary. This\n // is useful for low frequency updates where sync behavior simplifies the\n // logic.\n // For high frequency updates (e.g. `resize` and `scroll` events), always\n // prefer the async Popper#update method\n forceUpdate: function forceUpdate() {\n if (isDestroyed) {\n return;\n }\n\n var _state$elements = state.elements,\n reference = _state$elements.reference,\n popper = _state$elements.popper; // Don't proceed if `reference` or `popper` are not valid elements\n // anymore\n\n if (!areValidElements(reference, popper)) {\n return;\n } // Store the reference and popper rects to be read by modifiers\n\n\n state.rects = {\n reference: getCompositeRect(reference, getOffsetParent(popper), state.options.strategy === 'fixed'),\n popper: getLayoutRect(popper)\n }; // Modifiers have the ability to reset the current update cycle. The\n // most common use case for this is the `flip` modifier changing the\n // placement, which then needs to re-run all the modifiers, because the\n // logic was previously ran for the previous placement and is therefore\n // stale/incorrect\n\n state.reset = false;\n state.placement = state.options.placement; // On each update cycle, the `modifiersData` property for each modifier\n // is filled with the initial data specified by the modifier. This means\n // it doesn't persist and is fresh on each update.\n // To ensure persistent data, use `${name}#persistent`\n\n state.orderedModifiers.forEach(function (modifier) {\n return state.modifiersData[modifier.name] = Object.assign({}, modifier.data);\n });\n\n for (var index = 0; index < state.orderedModifiers.length; index++) {\n if (state.reset === true) {\n state.reset = false;\n index = -1;\n continue;\n }\n\n var _state$orderedModifie = state.orderedModifiers[index],\n fn = _state$orderedModifie.fn,\n _state$orderedModifie2 = _state$orderedModifie.options,\n _options = _state$orderedModifie2 === void 0 ? {} : _state$orderedModifie2,\n name = _state$orderedModifie.name;\n\n if (typeof fn === 'function') {\n state = fn({\n state: state,\n options: _options,\n name: name,\n instance: instance\n }) || state;\n }\n }\n },\n // Async and optimistically optimized update – it will not be executed if\n // not necessary (debounced to run at most once-per-tick)\n update: debounce(function () {\n return new Promise(function (resolve) {\n instance.forceUpdate();\n resolve(state);\n });\n }),\n destroy: function destroy() {\n cleanupModifierEffects();\n isDestroyed = true;\n }\n };\n\n if (!areValidElements(reference, popper)) {\n return instance;\n }\n\n instance.setOptions(options).then(function (state) {\n if (!isDestroyed && options.onFirstUpdate) {\n options.onFirstUpdate(state);\n }\n }); // Modifiers have the ability to execute arbitrary code before the first\n // update cycle runs. They will be executed in the same order as the update\n // cycle. This is useful when a modifier adds some persistent data that\n // other modifiers need to use, but the modifier is run after the dependent\n // one.\n\n function runModifierEffects() {\n state.orderedModifiers.forEach(function (_ref) {\n var name = _ref.name,\n _ref$options = _ref.options,\n options = _ref$options === void 0 ? {} : _ref$options,\n effect = _ref.effect;\n\n if (typeof effect === 'function') {\n var cleanupFn = effect({\n state: state,\n name: name,\n instance: instance,\n options: options\n });\n\n var noopFn = function noopFn() {};\n\n effectCleanupFns.push(cleanupFn || noopFn);\n }\n });\n }\n\n function cleanupModifierEffects() {\n effectCleanupFns.forEach(function (fn) {\n return fn();\n });\n effectCleanupFns = [];\n }\n\n return instance;\n };\n}\nexport var createPopper = /*#__PURE__*/popperGenerator(); // eslint-disable-next-line import/no-unused-modules\n\nexport { detectOverflow };","import { popperGenerator, detectOverflow } from \"./createPopper.js\";\nimport eventListeners from \"./modifiers/eventListeners.js\";\nimport popperOffsets from \"./modifiers/popperOffsets.js\";\nimport computeStyles from \"./modifiers/computeStyles.js\";\nimport applyStyles from \"./modifiers/applyStyles.js\";\nimport offset from \"./modifiers/offset.js\";\nimport flip from \"./modifiers/flip.js\";\nimport preventOverflow from \"./modifiers/preventOverflow.js\";\nimport arrow from \"./modifiers/arrow.js\";\nimport hide from \"./modifiers/hide.js\";\nvar defaultModifiers = [eventListeners, popperOffsets, computeStyles, applyStyles, offset, flip, preventOverflow, arrow, hide];\nvar createPopper = /*#__PURE__*/popperGenerator({\n defaultModifiers: defaultModifiers\n}); // eslint-disable-next-line import/no-unused-modules\n\nexport { createPopper, popperGenerator, defaultModifiers, detectOverflow }; // eslint-disable-next-line import/no-unused-modules\n\nexport { createPopper as createPopperLite } from \"./popper-lite.js\"; // eslint-disable-next-line import/no-unused-modules\n\nexport * from \"./modifiers/index.js\";","import { generateUtilityClass } from '../generateUtilityClass';\nimport { generateUtilityClasses } from '../generateUtilityClasses';\nconst COMPONENT_NAME = 'Popper';\nexport function getPopperUtilityClass(slot) {\n return generateUtilityClass(COMPONENT_NAME, slot);\n}\nexport const popperClasses = generateUtilityClasses(COMPONENT_NAME, ['root']);","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"anchorEl\", \"children\", \"direction\", \"disablePortal\", \"modifiers\", \"open\", \"placement\", \"popperOptions\", \"popperRef\", \"slotProps\", \"slots\", \"TransitionProps\", \"ownerState\"],\n _excluded2 = [\"anchorEl\", \"children\", \"container\", \"direction\", \"disablePortal\", \"keepMounted\", \"modifiers\", \"open\", \"placement\", \"popperOptions\", \"popperRef\", \"style\", \"transition\", \"slotProps\", \"slots\"];\nimport * as React from 'react';\nimport { chainPropTypes, HTMLElementType, refType, unstable_ownerDocument as ownerDocument, unstable_useEnhancedEffect as useEnhancedEffect, unstable_useForkRef as useForkRef } from '@mui/utils';\nimport { createPopper } from '@popperjs/core';\nimport PropTypes from 'prop-types';\nimport { unstable_composeClasses as composeClasses } from '../composeClasses';\nimport { Portal } from '../Portal';\nimport { getPopperUtilityClass } from './popperClasses';\nimport { useSlotProps } from '../utils';\nimport { useClassNamesOverride } from '../utils/ClassNameConfigurator';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nfunction flipPlacement(placement, direction) {\n if (direction === 'ltr') {\n return placement;\n }\n switch (placement) {\n case 'bottom-end':\n return 'bottom-start';\n case 'bottom-start':\n return 'bottom-end';\n case 'top-end':\n return 'top-start';\n case 'top-start':\n return 'top-end';\n default:\n return placement;\n }\n}\nfunction resolveAnchorEl(anchorEl) {\n return typeof anchorEl === 'function' ? anchorEl() : anchorEl;\n}\nfunction isHTMLElement(element) {\n return element.nodeType !== undefined;\n}\nfunction isVirtualElement(element) {\n return !isHTMLElement(element);\n}\nconst useUtilityClasses = () => {\n const slots = {\n root: ['root']\n };\n return composeClasses(slots, useClassNamesOverride(getPopperUtilityClass));\n};\nconst defaultPopperOptions = {};\nconst PopperTooltip = /*#__PURE__*/React.forwardRef(function PopperTooltip(props, forwardedRef) {\n var _slots$root;\n const {\n anchorEl,\n children,\n direction,\n disablePortal,\n modifiers,\n open,\n placement: initialPlacement,\n popperOptions,\n popperRef: popperRefProp,\n slotProps = {},\n slots = {},\n TransitionProps\n // @ts-ignore internal logic\n // prevent from spreading to DOM, it can come from the parent component e.g. Select.\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const tooltipRef = React.useRef(null);\n const ownRef = useForkRef(tooltipRef, forwardedRef);\n const popperRef = React.useRef(null);\n const handlePopperRef = useForkRef(popperRef, popperRefProp);\n const handlePopperRefRef = React.useRef(handlePopperRef);\n useEnhancedEffect(() => {\n handlePopperRefRef.current = handlePopperRef;\n }, [handlePopperRef]);\n React.useImperativeHandle(popperRefProp, () => popperRef.current, []);\n const rtlPlacement = flipPlacement(initialPlacement, direction);\n /**\n * placement initialized from prop but can change during lifetime if modifiers.flip.\n * modifiers.flip is essentially a flip for controlled/uncontrolled behavior\n */\n const [placement, setPlacement] = React.useState(rtlPlacement);\n const [resolvedAnchorElement, setResolvedAnchorElement] = React.useState(resolveAnchorEl(anchorEl));\n React.useEffect(() => {\n if (popperRef.current) {\n popperRef.current.forceUpdate();\n }\n });\n React.useEffect(() => {\n if (anchorEl) {\n setResolvedAnchorElement(resolveAnchorEl(anchorEl));\n }\n }, [anchorEl]);\n useEnhancedEffect(() => {\n if (!resolvedAnchorElement || !open) {\n return undefined;\n }\n const handlePopperUpdate = data => {\n setPlacement(data.placement);\n };\n if (process.env.NODE_ENV !== 'production') {\n if (resolvedAnchorElement && isHTMLElement(resolvedAnchorElement) && resolvedAnchorElement.nodeType === 1) {\n const box = resolvedAnchorElement.getBoundingClientRect();\n if (process.env.NODE_ENV !== 'test' && box.top === 0 && box.left === 0 && box.right === 0 && box.bottom === 0) {\n console.warn(['MUI: The `anchorEl` prop provided to the component is invalid.', 'The anchor element should be part of the document layout.', \"Make sure the element is present in the document or that it's not display none.\"].join('\\n'));\n }\n }\n }\n let popperModifiers = [{\n name: 'preventOverflow',\n options: {\n altBoundary: disablePortal\n }\n }, {\n name: 'flip',\n options: {\n altBoundary: disablePortal\n }\n }, {\n name: 'onUpdate',\n enabled: true,\n phase: 'afterWrite',\n fn: ({\n state\n }) => {\n handlePopperUpdate(state);\n }\n }];\n if (modifiers != null) {\n popperModifiers = popperModifiers.concat(modifiers);\n }\n if (popperOptions && popperOptions.modifiers != null) {\n popperModifiers = popperModifiers.concat(popperOptions.modifiers);\n }\n const popper = createPopper(resolvedAnchorElement, tooltipRef.current, _extends({\n placement: rtlPlacement\n }, popperOptions, {\n modifiers: popperModifiers\n }));\n handlePopperRefRef.current(popper);\n return () => {\n popper.destroy();\n handlePopperRefRef.current(null);\n };\n }, [resolvedAnchorElement, disablePortal, modifiers, open, popperOptions, rtlPlacement]);\n const childProps = {\n placement: placement\n };\n if (TransitionProps !== null) {\n childProps.TransitionProps = TransitionProps;\n }\n const classes = useUtilityClasses();\n const Root = (_slots$root = slots.root) != null ? _slots$root : 'div';\n const rootProps = useSlotProps({\n elementType: Root,\n externalSlotProps: slotProps.root,\n externalForwardedProps: other,\n additionalProps: {\n role: 'tooltip',\n ref: ownRef\n },\n ownerState: props,\n className: classes.root\n });\n return /*#__PURE__*/_jsx(Root, _extends({}, rootProps, {\n children: typeof children === 'function' ? children(childProps) : children\n }));\n});\n\n/**\n * Poppers rely on the 3rd party library [Popper.js](https://popper.js.org/docs/v2/) for positioning.\n *\n * Demos:\n *\n * - [Popper](https://mui.com/base-ui/react-popper/)\n *\n * API:\n *\n * - [Popper API](https://mui.com/base-ui/react-popper/components-api/#popper)\n */\nconst Popper = /*#__PURE__*/React.forwardRef(function Popper(props, forwardedRef) {\n const {\n anchorEl,\n children,\n container: containerProp,\n direction = 'ltr',\n disablePortal = false,\n keepMounted = false,\n modifiers,\n open,\n placement = 'bottom',\n popperOptions = defaultPopperOptions,\n popperRef,\n style,\n transition = false,\n slotProps = {},\n slots = {}\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded2);\n const [exited, setExited] = React.useState(true);\n const handleEnter = () => {\n setExited(false);\n };\n const handleExited = () => {\n setExited(true);\n };\n if (!keepMounted && !open && (!transition || exited)) {\n return null;\n }\n\n // If the container prop is provided, use that\n // If the anchorEl prop is provided, use its parent body element as the container\n // If neither are provided let the Modal take care of choosing the container\n let container;\n if (containerProp) {\n container = containerProp;\n } else if (anchorEl) {\n const resolvedAnchorEl = resolveAnchorEl(anchorEl);\n container = resolvedAnchorEl && isHTMLElement(resolvedAnchorEl) ? ownerDocument(resolvedAnchorEl).body : ownerDocument(null).body;\n }\n const display = !open && keepMounted && (!transition || exited) ? 'none' : undefined;\n const transitionProps = transition ? {\n in: open,\n onEnter: handleEnter,\n onExited: handleExited\n } : undefined;\n return /*#__PURE__*/_jsx(Portal, {\n disablePortal: disablePortal,\n container: container,\n children: /*#__PURE__*/_jsx(PopperTooltip, _extends({\n anchorEl: anchorEl,\n direction: direction,\n disablePortal: disablePortal,\n modifiers: modifiers,\n ref: forwardedRef,\n open: transition ? !exited : open,\n placement: placement,\n popperOptions: popperOptions,\n popperRef: popperRef,\n slotProps: slotProps,\n slots: slots\n }, other, {\n style: _extends({\n // Prevents scroll issue, waiting for Popper.js to add this style once initiated.\n position: 'fixed',\n // Fix Popper.js display issue\n top: 0,\n left: 0,\n display\n }, style),\n TransitionProps: transitionProps,\n children: children\n }))\n });\n});\nprocess.env.NODE_ENV !== \"production\" ? Popper.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * An HTML element, [virtualElement](https://popper.js.org/docs/v2/virtual-elements/),\n * or a function that returns either.\n * It's used to set the position of the popper.\n * The return value will passed as the reference object of the Popper instance.\n */\n anchorEl: chainPropTypes(PropTypes.oneOfType([HTMLElementType, PropTypes.object, PropTypes.func]), props => {\n if (props.open) {\n const resolvedAnchorEl = resolveAnchorEl(props.anchorEl);\n if (resolvedAnchorEl && isHTMLElement(resolvedAnchorEl) && resolvedAnchorEl.nodeType === 1) {\n const box = resolvedAnchorEl.getBoundingClientRect();\n if (process.env.NODE_ENV !== 'test' && box.top === 0 && box.left === 0 && box.right === 0 && box.bottom === 0) {\n return new Error(['MUI: The `anchorEl` prop provided to the component is invalid.', 'The anchor element should be part of the document layout.', \"Make sure the element is present in the document or that it's not display none.\"].join('\\n'));\n }\n } else if (!resolvedAnchorEl || typeof resolvedAnchorEl.getBoundingClientRect !== 'function' || isVirtualElement(resolvedAnchorEl) && resolvedAnchorEl.contextElement != null && resolvedAnchorEl.contextElement.nodeType !== 1) {\n return new Error(['MUI: The `anchorEl` prop provided to the component is invalid.', 'It should be an HTML element instance or a virtualElement ', '(https://popper.js.org/docs/v2/virtual-elements/).'].join('\\n'));\n }\n }\n return null;\n }),\n /**\n * Popper render function or node.\n */\n children: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.node, PropTypes.func]),\n /**\n * An HTML element or function that returns one.\n * The `container` will have the portal children appended to it.\n *\n * You can also provide a callback, which is called in a React layout effect.\n * This lets you set the container from a ref, and also makes server-side rendering possible.\n *\n * By default, it uses the body of the top-level document object,\n * so it's simply `document.body` most of the time.\n */\n container: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.func]),\n /**\n * Direction of the text.\n * @default 'ltr'\n */\n direction: PropTypes.oneOf(['ltr', 'rtl']),\n /**\n * The `children` will be under the DOM hierarchy of the parent component.\n * @default false\n */\n disablePortal: PropTypes.bool,\n /**\n * Always keep the children in the DOM.\n * This prop can be useful in SEO situation or\n * when you want to maximize the responsiveness of the Popper.\n * @default false\n */\n keepMounted: PropTypes.bool,\n /**\n * Popper.js is based on a \"plugin-like\" architecture,\n * most of its features are fully encapsulated \"modifiers\".\n *\n * A modifier is a function that is called each time Popper.js needs to\n * compute the position of the popper.\n * For this reason, modifiers should be very performant to avoid bottlenecks.\n * To learn how to create a modifier, [read the modifiers documentation](https://popper.js.org/docs/v2/modifiers/).\n */\n modifiers: PropTypes.arrayOf(PropTypes.shape({\n data: PropTypes.object,\n effect: PropTypes.func,\n enabled: PropTypes.bool,\n fn: PropTypes.func,\n name: PropTypes.any,\n options: PropTypes.object,\n phase: PropTypes.oneOf(['afterMain', 'afterRead', 'afterWrite', 'beforeMain', 'beforeRead', 'beforeWrite', 'main', 'read', 'write']),\n requires: PropTypes.arrayOf(PropTypes.string),\n requiresIfExists: PropTypes.arrayOf(PropTypes.string)\n })),\n /**\n * If `true`, the component is shown.\n */\n open: PropTypes.bool.isRequired,\n /**\n * Popper placement.\n * @default 'bottom'\n */\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n /**\n * Options provided to the [`Popper.js`](https://popper.js.org/docs/v2/constructors/#options) instance.\n * @default {}\n */\n popperOptions: PropTypes.shape({\n modifiers: PropTypes.array,\n onFirstUpdate: PropTypes.func,\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n strategy: PropTypes.oneOf(['absolute', 'fixed'])\n }),\n /**\n * A ref that points to the used popper instance.\n */\n popperRef: refType,\n /**\n * The props used for each slot inside the Popper.\n * @default {}\n */\n slotProps: PropTypes.shape({\n root: PropTypes.oneOfType([PropTypes.func, PropTypes.object])\n }),\n /**\n * The components used for each slot inside the Popper.\n * Either a string to use a HTML element or a component.\n * @default {}\n */\n slots: PropTypes.shape({\n root: PropTypes.elementType\n }),\n /**\n * Help supporting a react-transition-group/Transition component.\n * @default false\n */\n transition: PropTypes.bool\n} : void 0;\nexport { Popper };","'use client';\n\nimport * as React from 'react';\nimport { useTheme as useThemeSystem } from '@mui/system';\nimport defaultTheme from './defaultTheme';\nimport THEME_ID from './identifier';\nexport default function useTheme() {\n const theme = useThemeSystem(defaultTheme);\n if (process.env.NODE_ENV !== 'production') {\n // eslint-disable-next-line react-hooks/rules-of-hooks\n React.useDebugValue(theme);\n }\n return theme[THEME_ID] || theme;\n}","export default function _setPrototypeOf(o, p) {\n _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function _setPrototypeOf(o, p) {\n o.__proto__ = p;\n return o;\n };\n return _setPrototypeOf(o, p);\n}","import setPrototypeOf from \"./setPrototypeOf.js\";\nexport default function _inheritsLoose(subClass, superClass) {\n subClass.prototype = Object.create(superClass.prototype);\n subClass.prototype.constructor = subClass;\n setPrototypeOf(subClass, superClass);\n}","export default {\n disabled: false\n};","import PropTypes from 'prop-types';\nexport var timeoutsShape = process.env.NODE_ENV !== 'production' ? PropTypes.oneOfType([PropTypes.number, PropTypes.shape({\n enter: PropTypes.number,\n exit: PropTypes.number,\n appear: PropTypes.number\n}).isRequired]) : null;\nexport var classNamesShape = process.env.NODE_ENV !== 'production' ? PropTypes.oneOfType([PropTypes.string, PropTypes.shape({\n enter: PropTypes.string,\n exit: PropTypes.string,\n active: PropTypes.string\n}), PropTypes.shape({\n enter: PropTypes.string,\n enterDone: PropTypes.string,\n enterActive: PropTypes.string,\n exit: PropTypes.string,\n exitDone: PropTypes.string,\n exitActive: PropTypes.string\n})]) : null;","import React from 'react';\nexport default React.createContext(null);","export var forceReflow = function forceReflow(node) {\n return node.scrollTop;\n};","import _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _inheritsLoose from \"@babel/runtime/helpers/esm/inheritsLoose\";\nimport PropTypes from 'prop-types';\nimport React from 'react';\nimport ReactDOM from 'react-dom';\nimport config from './config';\nimport { timeoutsShape } from './utils/PropTypes';\nimport TransitionGroupContext from './TransitionGroupContext';\nimport { forceReflow } from './utils/reflow';\nexport var UNMOUNTED = 'unmounted';\nexport var EXITED = 'exited';\nexport var ENTERING = 'entering';\nexport var ENTERED = 'entered';\nexport var EXITING = 'exiting';\n/**\n * The Transition component lets you describe a transition from one component\n * state to another _over time_ with a simple declarative API. Most commonly\n * it's used to animate the mounting and unmounting of a component, but can also\n * be used to describe in-place transition states as well.\n *\n * ---\n *\n * **Note**: `Transition` is a platform-agnostic base component. If you're using\n * transitions in CSS, you'll probably want to use\n * [`CSSTransition`](https://reactcommunity.org/react-transition-group/css-transition)\n * instead. It inherits all the features of `Transition`, but contains\n * additional features necessary to play nice with CSS transitions (hence the\n * name of the component).\n *\n * ---\n *\n * By default the `Transition` component does not alter the behavior of the\n * component it renders, it only tracks \"enter\" and \"exit\" states for the\n * components. It's up to you to give meaning and effect to those states. For\n * example we can add styles to a component when it enters or exits:\n *\n * ```jsx\n * import { Transition } from 'react-transition-group';\n *\n * const duration = 300;\n *\n * const defaultStyle = {\n * transition: `opacity ${duration}ms ease-in-out`,\n * opacity: 0,\n * }\n *\n * const transitionStyles = {\n * entering: { opacity: 1 },\n * entered: { opacity: 1 },\n * exiting: { opacity: 0 },\n * exited: { opacity: 0 },\n * };\n *\n * const Fade = ({ in: inProp }) => (\n * \n * {state => (\n *
    \n * I'm a fade Transition!\n *
    \n * )}\n *
    \n * );\n * ```\n *\n * There are 4 main states a Transition can be in:\n * - `'entering'`\n * - `'entered'`\n * - `'exiting'`\n * - `'exited'`\n *\n * Transition state is toggled via the `in` prop. When `true` the component\n * begins the \"Enter\" stage. During this stage, the component will shift from\n * its current transition state, to `'entering'` for the duration of the\n * transition and then to the `'entered'` stage once it's complete. Let's take\n * the following example (we'll use the\n * [useState](https://reactjs.org/docs/hooks-reference.html#usestate) hook):\n *\n * ```jsx\n * function App() {\n * const [inProp, setInProp] = useState(false);\n * return (\n *
    \n * \n * {state => (\n * // ...\n * )}\n * \n * \n *
    \n * );\n * }\n * ```\n *\n * When the button is clicked the component will shift to the `'entering'` state\n * and stay there for 500ms (the value of `timeout`) before it finally switches\n * to `'entered'`.\n *\n * When `in` is `false` the same thing happens except the state moves from\n * `'exiting'` to `'exited'`.\n */\n\nvar Transition = /*#__PURE__*/function (_React$Component) {\n _inheritsLoose(Transition, _React$Component);\n\n function Transition(props, context) {\n var _this;\n\n _this = _React$Component.call(this, props, context) || this;\n var parentGroup = context; // In the context of a TransitionGroup all enters are really appears\n\n var appear = parentGroup && !parentGroup.isMounting ? props.enter : props.appear;\n var initialStatus;\n _this.appearStatus = null;\n\n if (props.in) {\n if (appear) {\n initialStatus = EXITED;\n _this.appearStatus = ENTERING;\n } else {\n initialStatus = ENTERED;\n }\n } else {\n if (props.unmountOnExit || props.mountOnEnter) {\n initialStatus = UNMOUNTED;\n } else {\n initialStatus = EXITED;\n }\n }\n\n _this.state = {\n status: initialStatus\n };\n _this.nextCallback = null;\n return _this;\n }\n\n Transition.getDerivedStateFromProps = function getDerivedStateFromProps(_ref, prevState) {\n var nextIn = _ref.in;\n\n if (nextIn && prevState.status === UNMOUNTED) {\n return {\n status: EXITED\n };\n }\n\n return null;\n } // getSnapshotBeforeUpdate(prevProps) {\n // let nextStatus = null\n // if (prevProps !== this.props) {\n // const { status } = this.state\n // if (this.props.in) {\n // if (status !== ENTERING && status !== ENTERED) {\n // nextStatus = ENTERING\n // }\n // } else {\n // if (status === ENTERING || status === ENTERED) {\n // nextStatus = EXITING\n // }\n // }\n // }\n // return { nextStatus }\n // }\n ;\n\n var _proto = Transition.prototype;\n\n _proto.componentDidMount = function componentDidMount() {\n this.updateStatus(true, this.appearStatus);\n };\n\n _proto.componentDidUpdate = function componentDidUpdate(prevProps) {\n var nextStatus = null;\n\n if (prevProps !== this.props) {\n var status = this.state.status;\n\n if (this.props.in) {\n if (status !== ENTERING && status !== ENTERED) {\n nextStatus = ENTERING;\n }\n } else {\n if (status === ENTERING || status === ENTERED) {\n nextStatus = EXITING;\n }\n }\n }\n\n this.updateStatus(false, nextStatus);\n };\n\n _proto.componentWillUnmount = function componentWillUnmount() {\n this.cancelNextCallback();\n };\n\n _proto.getTimeouts = function getTimeouts() {\n var timeout = this.props.timeout;\n var exit, enter, appear;\n exit = enter = appear = timeout;\n\n if (timeout != null && typeof timeout !== 'number') {\n exit = timeout.exit;\n enter = timeout.enter; // TODO: remove fallback for next major\n\n appear = timeout.appear !== undefined ? timeout.appear : enter;\n }\n\n return {\n exit: exit,\n enter: enter,\n appear: appear\n };\n };\n\n _proto.updateStatus = function updateStatus(mounting, nextStatus) {\n if (mounting === void 0) {\n mounting = false;\n }\n\n if (nextStatus !== null) {\n // nextStatus will always be ENTERING or EXITING.\n this.cancelNextCallback();\n\n if (nextStatus === ENTERING) {\n if (this.props.unmountOnExit || this.props.mountOnEnter) {\n var node = this.props.nodeRef ? this.props.nodeRef.current : ReactDOM.findDOMNode(this); // https://github.com/reactjs/react-transition-group/pull/749\n // With unmountOnExit or mountOnEnter, the enter animation should happen at the transition between `exited` and `entering`.\n // To make the animation happen, we have to separate each rendering and avoid being processed as batched.\n\n if (node) forceReflow(node);\n }\n\n this.performEnter(mounting);\n } else {\n this.performExit();\n }\n } else if (this.props.unmountOnExit && this.state.status === EXITED) {\n this.setState({\n status: UNMOUNTED\n });\n }\n };\n\n _proto.performEnter = function performEnter(mounting) {\n var _this2 = this;\n\n var enter = this.props.enter;\n var appearing = this.context ? this.context.isMounting : mounting;\n\n var _ref2 = this.props.nodeRef ? [appearing] : [ReactDOM.findDOMNode(this), appearing],\n maybeNode = _ref2[0],\n maybeAppearing = _ref2[1];\n\n var timeouts = this.getTimeouts();\n var enterTimeout = appearing ? timeouts.appear : timeouts.enter; // no enter animation skip right to ENTERED\n // if we are mounting and running this it means appear _must_ be set\n\n if (!mounting && !enter || config.disabled) {\n this.safeSetState({\n status: ENTERED\n }, function () {\n _this2.props.onEntered(maybeNode);\n });\n return;\n }\n\n this.props.onEnter(maybeNode, maybeAppearing);\n this.safeSetState({\n status: ENTERING\n }, function () {\n _this2.props.onEntering(maybeNode, maybeAppearing);\n\n _this2.onTransitionEnd(enterTimeout, function () {\n _this2.safeSetState({\n status: ENTERED\n }, function () {\n _this2.props.onEntered(maybeNode, maybeAppearing);\n });\n });\n });\n };\n\n _proto.performExit = function performExit() {\n var _this3 = this;\n\n var exit = this.props.exit;\n var timeouts = this.getTimeouts();\n var maybeNode = this.props.nodeRef ? undefined : ReactDOM.findDOMNode(this); // no exit animation skip right to EXITED\n\n if (!exit || config.disabled) {\n this.safeSetState({\n status: EXITED\n }, function () {\n _this3.props.onExited(maybeNode);\n });\n return;\n }\n\n this.props.onExit(maybeNode);\n this.safeSetState({\n status: EXITING\n }, function () {\n _this3.props.onExiting(maybeNode);\n\n _this3.onTransitionEnd(timeouts.exit, function () {\n _this3.safeSetState({\n status: EXITED\n }, function () {\n _this3.props.onExited(maybeNode);\n });\n });\n });\n };\n\n _proto.cancelNextCallback = function cancelNextCallback() {\n if (this.nextCallback !== null) {\n this.nextCallback.cancel();\n this.nextCallback = null;\n }\n };\n\n _proto.safeSetState = function safeSetState(nextState, callback) {\n // This shouldn't be necessary, but there are weird race conditions with\n // setState callbacks and unmounting in testing, so always make sure that\n // we can cancel any pending setState callbacks after we unmount.\n callback = this.setNextCallback(callback);\n this.setState(nextState, callback);\n };\n\n _proto.setNextCallback = function setNextCallback(callback) {\n var _this4 = this;\n\n var active = true;\n\n this.nextCallback = function (event) {\n if (active) {\n active = false;\n _this4.nextCallback = null;\n callback(event);\n }\n };\n\n this.nextCallback.cancel = function () {\n active = false;\n };\n\n return this.nextCallback;\n };\n\n _proto.onTransitionEnd = function onTransitionEnd(timeout, handler) {\n this.setNextCallback(handler);\n var node = this.props.nodeRef ? this.props.nodeRef.current : ReactDOM.findDOMNode(this);\n var doesNotHaveTimeoutOrListener = timeout == null && !this.props.addEndListener;\n\n if (!node || doesNotHaveTimeoutOrListener) {\n setTimeout(this.nextCallback, 0);\n return;\n }\n\n if (this.props.addEndListener) {\n var _ref3 = this.props.nodeRef ? [this.nextCallback] : [node, this.nextCallback],\n maybeNode = _ref3[0],\n maybeNextCallback = _ref3[1];\n\n this.props.addEndListener(maybeNode, maybeNextCallback);\n }\n\n if (timeout != null) {\n setTimeout(this.nextCallback, timeout);\n }\n };\n\n _proto.render = function render() {\n var status = this.state.status;\n\n if (status === UNMOUNTED) {\n return null;\n }\n\n var _this$props = this.props,\n children = _this$props.children,\n _in = _this$props.in,\n _mountOnEnter = _this$props.mountOnEnter,\n _unmountOnExit = _this$props.unmountOnExit,\n _appear = _this$props.appear,\n _enter = _this$props.enter,\n _exit = _this$props.exit,\n _timeout = _this$props.timeout,\n _addEndListener = _this$props.addEndListener,\n _onEnter = _this$props.onEnter,\n _onEntering = _this$props.onEntering,\n _onEntered = _this$props.onEntered,\n _onExit = _this$props.onExit,\n _onExiting = _this$props.onExiting,\n _onExited = _this$props.onExited,\n _nodeRef = _this$props.nodeRef,\n childProps = _objectWithoutPropertiesLoose(_this$props, [\"children\", \"in\", \"mountOnEnter\", \"unmountOnExit\", \"appear\", \"enter\", \"exit\", \"timeout\", \"addEndListener\", \"onEnter\", \"onEntering\", \"onEntered\", \"onExit\", \"onExiting\", \"onExited\", \"nodeRef\"]);\n\n return (\n /*#__PURE__*/\n // allows for nested Transitions\n React.createElement(TransitionGroupContext.Provider, {\n value: null\n }, typeof children === 'function' ? children(status, childProps) : React.cloneElement(React.Children.only(children), childProps))\n );\n };\n\n return Transition;\n}(React.Component);\n\nTransition.contextType = TransitionGroupContext;\nTransition.propTypes = process.env.NODE_ENV !== \"production\" ? {\n /**\n * A React reference to DOM element that need to transition:\n * https://stackoverflow.com/a/51127130/4671932\n *\n * - When `nodeRef` prop is used, `node` is not passed to callback functions\n * (e.g. `onEnter`) because user already has direct access to the node.\n * - When changing `key` prop of `Transition` in a `TransitionGroup` a new\n * `nodeRef` need to be provided to `Transition` with changed `key` prop\n * (see\n * [test/CSSTransition-test.js](https://github.com/reactjs/react-transition-group/blob/13435f897b3ab71f6e19d724f145596f5910581c/test/CSSTransition-test.js#L362-L437)).\n */\n nodeRef: PropTypes.shape({\n current: typeof Element === 'undefined' ? PropTypes.any : function (propValue, key, componentName, location, propFullName, secret) {\n var value = propValue[key];\n return PropTypes.instanceOf(value && 'ownerDocument' in value ? value.ownerDocument.defaultView.Element : Element)(propValue, key, componentName, location, propFullName, secret);\n }\n }),\n\n /**\n * A `function` child can be used instead of a React element. This function is\n * called with the current transition status (`'entering'`, `'entered'`,\n * `'exiting'`, `'exited'`), which can be used to apply context\n * specific props to a component.\n *\n * ```jsx\n * \n * {state => (\n * \n * )}\n * \n * ```\n */\n children: PropTypes.oneOfType([PropTypes.func.isRequired, PropTypes.element.isRequired]).isRequired,\n\n /**\n * Show the component; triggers the enter or exit states\n */\n in: PropTypes.bool,\n\n /**\n * By default the child component is mounted immediately along with\n * the parent `Transition` component. If you want to \"lazy mount\" the component on the\n * first `in={true}` you can set `mountOnEnter`. After the first enter transition the component will stay\n * mounted, even on \"exited\", unless you also specify `unmountOnExit`.\n */\n mountOnEnter: PropTypes.bool,\n\n /**\n * By default the child component stays mounted after it reaches the `'exited'` state.\n * Set `unmountOnExit` if you'd prefer to unmount the component after it finishes exiting.\n */\n unmountOnExit: PropTypes.bool,\n\n /**\n * By default the child component does not perform the enter transition when\n * it first mounts, regardless of the value of `in`. If you want this\n * behavior, set both `appear` and `in` to `true`.\n *\n * > **Note**: there are no special appear states like `appearing`/`appeared`, this prop\n * > only adds an additional enter transition. However, in the\n * > `` component that first enter transition does result in\n * > additional `.appear-*` classes, that way you can choose to style it\n * > differently.\n */\n appear: PropTypes.bool,\n\n /**\n * Enable or disable enter transitions.\n */\n enter: PropTypes.bool,\n\n /**\n * Enable or disable exit transitions.\n */\n exit: PropTypes.bool,\n\n /**\n * The duration of the transition, in milliseconds.\n * Required unless `addEndListener` is provided.\n *\n * You may specify a single timeout for all transitions:\n *\n * ```jsx\n * timeout={500}\n * ```\n *\n * or individually:\n *\n * ```jsx\n * timeout={{\n * appear: 500,\n * enter: 300,\n * exit: 500,\n * }}\n * ```\n *\n * - `appear` defaults to the value of `enter`\n * - `enter` defaults to `0`\n * - `exit` defaults to `0`\n *\n * @type {number | { enter?: number, exit?: number, appear?: number }}\n */\n timeout: function timeout(props) {\n var pt = timeoutsShape;\n if (!props.addEndListener) pt = pt.isRequired;\n\n for (var _len = arguments.length, args = new Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) {\n args[_key - 1] = arguments[_key];\n }\n\n return pt.apply(void 0, [props].concat(args));\n },\n\n /**\n * Add a custom transition end trigger. Called with the transitioning\n * DOM node and a `done` callback. Allows for more fine grained transition end\n * logic. Timeouts are still used as a fallback if provided.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * ```jsx\n * addEndListener={(node, done) => {\n * // use the css transitionend event to mark the finish of a transition\n * node.addEventListener('transitionend', done, false);\n * }}\n * ```\n */\n addEndListener: PropTypes.func,\n\n /**\n * Callback fired before the \"entering\" status is applied. An extra parameter\n * `isAppearing` is supplied to indicate if the enter stage is occurring on the initial mount\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement, isAppearing: bool) -> void\n */\n onEnter: PropTypes.func,\n\n /**\n * Callback fired after the \"entering\" status is applied. An extra parameter\n * `isAppearing` is supplied to indicate if the enter stage is occurring on the initial mount\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement, isAppearing: bool)\n */\n onEntering: PropTypes.func,\n\n /**\n * Callback fired after the \"entered\" status is applied. An extra parameter\n * `isAppearing` is supplied to indicate if the enter stage is occurring on the initial mount\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement, isAppearing: bool) -> void\n */\n onEntered: PropTypes.func,\n\n /**\n * Callback fired before the \"exiting\" status is applied.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement) -> void\n */\n onExit: PropTypes.func,\n\n /**\n * Callback fired after the \"exiting\" status is applied.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement) -> void\n */\n onExiting: PropTypes.func,\n\n /**\n * Callback fired after the \"exited\" status is applied.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed\n *\n * @type Function(node: HtmlElement) -> void\n */\n onExited: PropTypes.func\n} : {}; // Name the function so it is clearer in the documentation\n\nfunction noop() {}\n\nTransition.defaultProps = {\n in: false,\n mountOnEnter: false,\n unmountOnExit: false,\n appear: false,\n enter: true,\n exit: true,\n onEnter: noop,\n onEntering: noop,\n onEntered: noop,\n onExit: noop,\n onExiting: noop,\n onExited: noop\n};\nTransition.UNMOUNTED = UNMOUNTED;\nTransition.EXITED = EXITED;\nTransition.ENTERING = ENTERING;\nTransition.ENTERED = ENTERED;\nTransition.EXITING = EXITING;\nexport default Transition;","export const reflow = node => node.scrollTop;\nexport function getTransitionProps(props, options) {\n var _style$transitionDura, _style$transitionTimi;\n const {\n timeout,\n easing,\n style = {}\n } = props;\n return {\n duration: (_style$transitionDura = style.transitionDuration) != null ? _style$transitionDura : typeof timeout === 'number' ? timeout : timeout[options.mode] || 0,\n easing: (_style$transitionTimi = style.transitionTimingFunction) != null ? _style$transitionTimi : typeof easing === 'object' ? easing[options.mode] : easing,\n delay: style.transitionDelay\n };\n}","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"addEndListener\", \"appear\", \"children\", \"easing\", \"in\", \"onEnter\", \"onEntered\", \"onEntering\", \"onExit\", \"onExited\", \"onExiting\", \"style\", \"timeout\", \"TransitionComponent\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport { elementAcceptingRef, unstable_useTimeout as useTimeout } from '@mui/utils';\nimport { Transition } from 'react-transition-group';\nimport useTheme from '../styles/useTheme';\nimport { getTransitionProps, reflow } from '../transitions/utils';\nimport useForkRef from '../utils/useForkRef';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nfunction getScale(value) {\n return `scale(${value}, ${value ** 2})`;\n}\nconst styles = {\n entering: {\n opacity: 1,\n transform: getScale(1)\n },\n entered: {\n opacity: 1,\n transform: 'none'\n }\n};\n\n/*\n TODO v6: remove\n Conditionally apply a workaround for the CSS transition bug in Safari 15.4 / WebKit browsers.\n */\nconst isWebKit154 = typeof navigator !== 'undefined' && /^((?!chrome|android).)*(safari|mobile)/i.test(navigator.userAgent) && /(os |version\\/)15(.|_)4/i.test(navigator.userAgent);\n\n/**\n * The Grow transition is used by the [Tooltip](/material-ui/react-tooltip/) and\n * [Popover](/material-ui/react-popover/) components.\n * It uses [react-transition-group](https://github.com/reactjs/react-transition-group) internally.\n */\nconst Grow = /*#__PURE__*/React.forwardRef(function Grow(props, ref) {\n const {\n addEndListener,\n appear = true,\n children,\n easing,\n in: inProp,\n onEnter,\n onEntered,\n onEntering,\n onExit,\n onExited,\n onExiting,\n style,\n timeout = 'auto',\n // eslint-disable-next-line react/prop-types\n TransitionComponent = Transition\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const timer = useTimeout();\n const autoTimeout = React.useRef();\n const theme = useTheme();\n const nodeRef = React.useRef(null);\n const handleRef = useForkRef(nodeRef, children.ref, ref);\n const normalizedTransitionCallback = callback => maybeIsAppearing => {\n if (callback) {\n const node = nodeRef.current;\n\n // onEnterXxx and onExitXxx callbacks have a different arguments.length value.\n if (maybeIsAppearing === undefined) {\n callback(node);\n } else {\n callback(node, maybeIsAppearing);\n }\n }\n };\n const handleEntering = normalizedTransitionCallback(onEntering);\n const handleEnter = normalizedTransitionCallback((node, isAppearing) => {\n reflow(node); // So the animation always start from the start.\n\n const {\n duration: transitionDuration,\n delay,\n easing: transitionTimingFunction\n } = getTransitionProps({\n style,\n timeout,\n easing\n }, {\n mode: 'enter'\n });\n let duration;\n if (timeout === 'auto') {\n duration = theme.transitions.getAutoHeightDuration(node.clientHeight);\n autoTimeout.current = duration;\n } else {\n duration = transitionDuration;\n }\n node.style.transition = [theme.transitions.create('opacity', {\n duration,\n delay\n }), theme.transitions.create('transform', {\n duration: isWebKit154 ? duration : duration * 0.666,\n delay,\n easing: transitionTimingFunction\n })].join(',');\n if (onEnter) {\n onEnter(node, isAppearing);\n }\n });\n const handleEntered = normalizedTransitionCallback(onEntered);\n const handleExiting = normalizedTransitionCallback(onExiting);\n const handleExit = normalizedTransitionCallback(node => {\n const {\n duration: transitionDuration,\n delay,\n easing: transitionTimingFunction\n } = getTransitionProps({\n style,\n timeout,\n easing\n }, {\n mode: 'exit'\n });\n let duration;\n if (timeout === 'auto') {\n duration = theme.transitions.getAutoHeightDuration(node.clientHeight);\n autoTimeout.current = duration;\n } else {\n duration = transitionDuration;\n }\n node.style.transition = [theme.transitions.create('opacity', {\n duration,\n delay\n }), theme.transitions.create('transform', {\n duration: isWebKit154 ? duration : duration * 0.666,\n delay: isWebKit154 ? delay : delay || duration * 0.333,\n easing: transitionTimingFunction\n })].join(',');\n node.style.opacity = 0;\n node.style.transform = getScale(0.75);\n if (onExit) {\n onExit(node);\n }\n });\n const handleExited = normalizedTransitionCallback(onExited);\n const handleAddEndListener = next => {\n if (timeout === 'auto') {\n timer.start(autoTimeout.current || 0, next);\n }\n if (addEndListener) {\n // Old call signature before `react-transition-group` implemented `nodeRef`\n addEndListener(nodeRef.current, next);\n }\n };\n return /*#__PURE__*/_jsx(TransitionComponent, _extends({\n appear: appear,\n in: inProp,\n nodeRef: nodeRef,\n onEnter: handleEnter,\n onEntered: handleEntered,\n onEntering: handleEntering,\n onExit: handleExit,\n onExited: handleExited,\n onExiting: handleExiting,\n addEndListener: handleAddEndListener,\n timeout: timeout === 'auto' ? null : timeout\n }, other, {\n children: (state, childProps) => {\n return /*#__PURE__*/React.cloneElement(children, _extends({\n style: _extends({\n opacity: 0,\n transform: getScale(0.75),\n visibility: state === 'exited' && !inProp ? 'hidden' : undefined\n }, styles[state], style, children.props.style),\n ref: handleRef\n }, childProps));\n }\n }));\n});\nprocess.env.NODE_ENV !== \"production\" ? Grow.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the d.ts file and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * Add a custom transition end trigger. Called with the transitioning DOM\n * node and a done callback. Allows for more fine grained transition end\n * logic. Note: Timeouts are still used as a fallback if provided.\n */\n addEndListener: PropTypes.func,\n /**\n * Perform the enter transition when it first mounts if `in` is also `true`.\n * Set this to `false` to disable this behavior.\n * @default true\n */\n appear: PropTypes.bool,\n /**\n * A single child content element.\n */\n children: elementAcceptingRef.isRequired,\n /**\n * The transition timing function.\n * You may specify a single easing or a object containing enter and exit values.\n */\n easing: PropTypes.oneOfType([PropTypes.shape({\n enter: PropTypes.string,\n exit: PropTypes.string\n }), PropTypes.string]),\n /**\n * If `true`, the component will transition in.\n */\n in: PropTypes.bool,\n /**\n * @ignore\n */\n onEnter: PropTypes.func,\n /**\n * @ignore\n */\n onEntered: PropTypes.func,\n /**\n * @ignore\n */\n onEntering: PropTypes.func,\n /**\n * @ignore\n */\n onExit: PropTypes.func,\n /**\n * @ignore\n */\n onExited: PropTypes.func,\n /**\n * @ignore\n */\n onExiting: PropTypes.func,\n /**\n * @ignore\n */\n style: PropTypes.object,\n /**\n * The duration for the transition, in milliseconds.\n * You may specify a single timeout for all transitions, or individually with an object.\n *\n * Set to 'auto' to automatically calculate transition time based on height.\n * @default 'auto'\n */\n timeout: PropTypes.oneOfType([PropTypes.oneOf(['auto']), PropTypes.number, PropTypes.shape({\n appear: PropTypes.number,\n enter: PropTypes.number,\n exit: PropTypes.number\n })])\n} : void 0;\nGrow.muiSupportAuto = true;\nexport default Grow;","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"anchorEl\", \"component\", \"components\", \"componentsProps\", \"container\", \"disablePortal\", \"keepMounted\", \"modifiers\", \"open\", \"placement\", \"popperOptions\", \"popperRef\", \"transition\", \"slots\", \"slotProps\"];\nimport { Popper as BasePopper } from '@mui/base/Popper';\nimport { useThemeWithoutDefault as useTheme } from '@mui/system';\nimport { HTMLElementType, refType } from '@mui/utils';\nimport PropTypes from 'prop-types';\nimport * as React from 'react';\nimport { styled, useThemeProps } from '../styles';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nconst PopperRoot = styled(BasePopper, {\n name: 'MuiPopper',\n slot: 'Root',\n overridesResolver: (props, styles) => styles.root\n})({});\n\n/**\n *\n * Demos:\n *\n * - [Autocomplete](https://mui.com/material-ui/react-autocomplete/)\n * - [Menu](https://mui.com/material-ui/react-menu/)\n * - [Popper](https://mui.com/material-ui/react-popper/)\n *\n * API:\n *\n * - [Popper API](https://mui.com/material-ui/api/popper/)\n */\nconst Popper = /*#__PURE__*/React.forwardRef(function Popper(inProps, ref) {\n var _slots$root;\n const theme = useTheme();\n const props = useThemeProps({\n props: inProps,\n name: 'MuiPopper'\n });\n const {\n anchorEl,\n component,\n components,\n componentsProps,\n container,\n disablePortal,\n keepMounted,\n modifiers,\n open,\n placement,\n popperOptions,\n popperRef,\n transition,\n slots,\n slotProps\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const RootComponent = (_slots$root = slots == null ? void 0 : slots.root) != null ? _slots$root : components == null ? void 0 : components.Root;\n const otherProps = _extends({\n anchorEl,\n container,\n disablePortal,\n keepMounted,\n modifiers,\n open,\n placement,\n popperOptions,\n popperRef,\n transition\n }, other);\n return /*#__PURE__*/_jsx(PopperRoot, _extends({\n as: component,\n direction: theme == null ? void 0 : theme.direction,\n slots: {\n root: RootComponent\n },\n slotProps: slotProps != null ? slotProps : componentsProps\n }, otherProps, {\n ref: ref\n }));\n});\nprocess.env.NODE_ENV !== \"production\" ? Popper.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * An HTML element, [virtualElement](https://popper.js.org/docs/v2/virtual-elements/),\n * or a function that returns either.\n * It's used to set the position of the popper.\n * The return value will passed as the reference object of the Popper instance.\n */\n anchorEl: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.object, PropTypes.func]),\n /**\n * Popper render function or node.\n */\n children: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.node, PropTypes.func]),\n /**\n * The component used for the root node.\n * Either a string to use a HTML element or a component.\n */\n component: PropTypes.elementType,\n /**\n * The components used for each slot inside the Popper.\n * Either a string to use a HTML element or a component.\n * @default {}\n */\n components: PropTypes.shape({\n Root: PropTypes.elementType\n }),\n /**\n * The props used for each slot inside the Popper.\n * @default {}\n */\n componentsProps: PropTypes.shape({\n root: PropTypes.oneOfType([PropTypes.func, PropTypes.object])\n }),\n /**\n * An HTML element or function that returns one.\n * The `container` will have the portal children appended to it.\n *\n * You can also provide a callback, which is called in a React layout effect.\n * This lets you set the container from a ref, and also makes server-side rendering possible.\n *\n * By default, it uses the body of the top-level document object,\n * so it's simply `document.body` most of the time.\n */\n container: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.func]),\n /**\n * The `children` will be under the DOM hierarchy of the parent component.\n * @default false\n */\n disablePortal: PropTypes.bool,\n /**\n * Always keep the children in the DOM.\n * This prop can be useful in SEO situation or\n * when you want to maximize the responsiveness of the Popper.\n * @default false\n */\n keepMounted: PropTypes.bool,\n /**\n * Popper.js is based on a \"plugin-like\" architecture,\n * most of its features are fully encapsulated \"modifiers\".\n *\n * A modifier is a function that is called each time Popper.js needs to\n * compute the position of the popper.\n * For this reason, modifiers should be very performant to avoid bottlenecks.\n * To learn how to create a modifier, [read the modifiers documentation](https://popper.js.org/docs/v2/modifiers/).\n */\n modifiers: PropTypes.arrayOf(PropTypes.shape({\n data: PropTypes.object,\n effect: PropTypes.func,\n enabled: PropTypes.bool,\n fn: PropTypes.func,\n name: PropTypes.any,\n options: PropTypes.object,\n phase: PropTypes.oneOf(['afterMain', 'afterRead', 'afterWrite', 'beforeMain', 'beforeRead', 'beforeWrite', 'main', 'read', 'write']),\n requires: PropTypes.arrayOf(PropTypes.string),\n requiresIfExists: PropTypes.arrayOf(PropTypes.string)\n })),\n /**\n * If `true`, the component is shown.\n */\n open: PropTypes.bool.isRequired,\n /**\n * Popper placement.\n * @default 'bottom'\n */\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n /**\n * Options provided to the [`Popper.js`](https://popper.js.org/docs/v2/constructors/#options) instance.\n * @default {}\n */\n popperOptions: PropTypes.shape({\n modifiers: PropTypes.array,\n onFirstUpdate: PropTypes.func,\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n strategy: PropTypes.oneOf(['absolute', 'fixed'])\n }),\n /**\n * A ref that points to the used popper instance.\n */\n popperRef: refType,\n /**\n * The props used for each slot inside the Popper.\n * @default {}\n */\n slotProps: PropTypes.shape({\n root: PropTypes.oneOfType([PropTypes.func, PropTypes.object])\n }),\n /**\n * The components used for each slot inside the Popper.\n * Either a string to use a HTML element or a component.\n * @default {}\n */\n slots: PropTypes.shape({\n root: PropTypes.elementType\n }),\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Help supporting a react-transition-group/Transition component.\n * @default false\n */\n transition: PropTypes.bool\n} : void 0;\nexport default Popper;","import generateUtilityClasses from '@mui/utils/generateUtilityClasses';\nimport generateUtilityClass from '@mui/utils/generateUtilityClass';\nexport function getTooltipUtilityClass(slot) {\n return generateUtilityClass('MuiTooltip', slot);\n}\nconst tooltipClasses = generateUtilityClasses('MuiTooltip', ['popper', 'popperInteractive', 'popperArrow', 'popperClose', 'tooltip', 'tooltipArrow', 'touch', 'tooltipPlacementLeft', 'tooltipPlacementRight', 'tooltipPlacementTop', 'tooltipPlacementBottom', 'arrow']);\nexport default tooltipClasses;","'use client';\n\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nconst _excluded = [\"arrow\", \"children\", \"classes\", \"components\", \"componentsProps\", \"describeChild\", \"disableFocusListener\", \"disableHoverListener\", \"disableInteractive\", \"disableTouchListener\", \"enterDelay\", \"enterNextDelay\", \"enterTouchDelay\", \"followCursor\", \"id\", \"leaveDelay\", \"leaveTouchDelay\", \"onClose\", \"onOpen\", \"open\", \"placement\", \"PopperComponent\", \"PopperProps\", \"slotProps\", \"slots\", \"title\", \"TransitionComponent\", \"TransitionProps\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport clsx from 'clsx';\nimport { elementAcceptingRef, unstable_useTimeout as useTimeout, unstable_Timeout as Timeout } from '@mui/utils';\nimport { unstable_composeClasses as composeClasses, appendOwnerState } from '@mui/base';\nimport { alpha } from '@mui/system';\nimport styled from '../styles/styled';\nimport useTheme from '../styles/useTheme';\nimport useThemeProps from '../styles/useThemeProps';\nimport capitalize from '../utils/capitalize';\nimport Grow from '../Grow';\nimport Popper from '../Popper';\nimport useEventCallback from '../utils/useEventCallback';\nimport useForkRef from '../utils/useForkRef';\nimport useId from '../utils/useId';\nimport useIsFocusVisible from '../utils/useIsFocusVisible';\nimport useControlled from '../utils/useControlled';\nimport tooltipClasses, { getTooltipUtilityClass } from './tooltipClasses';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nimport { jsxs as _jsxs } from \"react/jsx-runtime\";\nfunction round(value) {\n return Math.round(value * 1e5) / 1e5;\n}\nconst useUtilityClasses = ownerState => {\n const {\n classes,\n disableInteractive,\n arrow,\n touch,\n placement\n } = ownerState;\n const slots = {\n popper: ['popper', !disableInteractive && 'popperInteractive', arrow && 'popperArrow'],\n tooltip: ['tooltip', arrow && 'tooltipArrow', touch && 'touch', `tooltipPlacement${capitalize(placement.split('-')[0])}`],\n arrow: ['arrow']\n };\n return composeClasses(slots, getTooltipUtilityClass, classes);\n};\nconst TooltipPopper = styled(Popper, {\n name: 'MuiTooltip',\n slot: 'Popper',\n overridesResolver: (props, styles) => {\n const {\n ownerState\n } = props;\n return [styles.popper, !ownerState.disableInteractive && styles.popperInteractive, ownerState.arrow && styles.popperArrow, !ownerState.open && styles.popperClose];\n }\n})(({\n theme,\n ownerState,\n open\n}) => _extends({\n zIndex: (theme.vars || theme).zIndex.tooltip,\n pointerEvents: 'none'\n}, !ownerState.disableInteractive && {\n pointerEvents: 'auto'\n}, !open && {\n pointerEvents: 'none'\n}, ownerState.arrow && {\n [`&[data-popper-placement*=\"bottom\"] .${tooltipClasses.arrow}`]: {\n top: 0,\n marginTop: '-0.71em',\n '&::before': {\n transformOrigin: '0 100%'\n }\n },\n [`&[data-popper-placement*=\"top\"] .${tooltipClasses.arrow}`]: {\n bottom: 0,\n marginBottom: '-0.71em',\n '&::before': {\n transformOrigin: '100% 0'\n }\n },\n [`&[data-popper-placement*=\"right\"] .${tooltipClasses.arrow}`]: _extends({}, !ownerState.isRtl ? {\n left: 0,\n marginLeft: '-0.71em'\n } : {\n right: 0,\n marginRight: '-0.71em'\n }, {\n height: '1em',\n width: '0.71em',\n '&::before': {\n transformOrigin: '100% 100%'\n }\n }),\n [`&[data-popper-placement*=\"left\"] .${tooltipClasses.arrow}`]: _extends({}, !ownerState.isRtl ? {\n right: 0,\n marginRight: '-0.71em'\n } : {\n left: 0,\n marginLeft: '-0.71em'\n }, {\n height: '1em',\n width: '0.71em',\n '&::before': {\n transformOrigin: '0 0'\n }\n })\n}));\nconst TooltipTooltip = styled('div', {\n name: 'MuiTooltip',\n slot: 'Tooltip',\n overridesResolver: (props, styles) => {\n const {\n ownerState\n } = props;\n return [styles.tooltip, ownerState.touch && styles.touch, ownerState.arrow && styles.tooltipArrow, styles[`tooltipPlacement${capitalize(ownerState.placement.split('-')[0])}`]];\n }\n})(({\n theme,\n ownerState\n}) => _extends({\n backgroundColor: theme.vars ? theme.vars.palette.Tooltip.bg : alpha(theme.palette.grey[700], 0.92),\n borderRadius: (theme.vars || theme).shape.borderRadius,\n color: (theme.vars || theme).palette.common.white,\n fontFamily: theme.typography.fontFamily,\n padding: '4px 8px',\n fontSize: theme.typography.pxToRem(11),\n maxWidth: 300,\n margin: 2,\n wordWrap: 'break-word',\n fontWeight: theme.typography.fontWeightMedium\n}, ownerState.arrow && {\n position: 'relative',\n margin: 0\n}, ownerState.touch && {\n padding: '8px 16px',\n fontSize: theme.typography.pxToRem(14),\n lineHeight: `${round(16 / 14)}em`,\n fontWeight: theme.typography.fontWeightRegular\n}, {\n [`.${tooltipClasses.popper}[data-popper-placement*=\"left\"] &`]: _extends({\n transformOrigin: 'right center'\n }, !ownerState.isRtl ? _extends({\n marginRight: '14px'\n }, ownerState.touch && {\n marginRight: '24px'\n }) : _extends({\n marginLeft: '14px'\n }, ownerState.touch && {\n marginLeft: '24px'\n })),\n [`.${tooltipClasses.popper}[data-popper-placement*=\"right\"] &`]: _extends({\n transformOrigin: 'left center'\n }, !ownerState.isRtl ? _extends({\n marginLeft: '14px'\n }, ownerState.touch && {\n marginLeft: '24px'\n }) : _extends({\n marginRight: '14px'\n }, ownerState.touch && {\n marginRight: '24px'\n })),\n [`.${tooltipClasses.popper}[data-popper-placement*=\"top\"] &`]: _extends({\n transformOrigin: 'center bottom',\n marginBottom: '14px'\n }, ownerState.touch && {\n marginBottom: '24px'\n }),\n [`.${tooltipClasses.popper}[data-popper-placement*=\"bottom\"] &`]: _extends({\n transformOrigin: 'center top',\n marginTop: '14px'\n }, ownerState.touch && {\n marginTop: '24px'\n })\n}));\nconst TooltipArrow = styled('span', {\n name: 'MuiTooltip',\n slot: 'Arrow',\n overridesResolver: (props, styles) => styles.arrow\n})(({\n theme\n}) => ({\n overflow: 'hidden',\n position: 'absolute',\n width: '1em',\n height: '0.71em' /* = width / sqrt(2) = (length of the hypotenuse) */,\n boxSizing: 'border-box',\n color: theme.vars ? theme.vars.palette.Tooltip.bg : alpha(theme.palette.grey[700], 0.9),\n '&::before': {\n content: '\"\"',\n margin: 'auto',\n display: 'block',\n width: '100%',\n height: '100%',\n backgroundColor: 'currentColor',\n transform: 'rotate(45deg)'\n }\n}));\nlet hystersisOpen = false;\nconst hystersisTimer = new Timeout();\nlet cursorPosition = {\n x: 0,\n y: 0\n};\nexport function testReset() {\n hystersisOpen = false;\n hystersisTimer.clear();\n}\nfunction composeEventHandler(handler, eventHandler) {\n return event => {\n if (eventHandler) {\n eventHandler(event);\n }\n handler(event);\n };\n}\n\n// TODO v6: Remove PopperComponent, PopperProps, TransitionComponent and TransitionProps.\nconst Tooltip = /*#__PURE__*/React.forwardRef(function Tooltip(inProps, ref) {\n var _ref, _slots$popper, _ref2, _ref3, _slots$transition, _ref4, _slots$tooltip, _ref5, _slots$arrow, _slotProps$popper, _ref6, _slotProps$popper2, _slotProps$transition, _slotProps$tooltip, _ref7, _slotProps$tooltip2, _slotProps$arrow, _ref8, _slotProps$arrow2;\n const props = useThemeProps({\n props: inProps,\n name: 'MuiTooltip'\n });\n const {\n arrow = false,\n children: childrenProp,\n components = {},\n componentsProps = {},\n describeChild = false,\n disableFocusListener = false,\n disableHoverListener = false,\n disableInteractive: disableInteractiveProp = false,\n disableTouchListener = false,\n enterDelay = 100,\n enterNextDelay = 0,\n enterTouchDelay = 700,\n followCursor = false,\n id: idProp,\n leaveDelay = 0,\n leaveTouchDelay = 1500,\n onClose,\n onOpen,\n open: openProp,\n placement = 'bottom',\n PopperComponent: PopperComponentProp,\n PopperProps = {},\n slotProps = {},\n slots = {},\n title,\n TransitionComponent: TransitionComponentProp = Grow,\n TransitionProps\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n\n // to prevent runtime errors, developers will need to provide a child as a React element anyway.\n const children = /*#__PURE__*/React.isValidElement(childrenProp) ? childrenProp : /*#__PURE__*/_jsx(\"span\", {\n children: childrenProp\n });\n const theme = useTheme();\n const isRtl = theme.direction === 'rtl';\n const [childNode, setChildNode] = React.useState();\n const [arrowRef, setArrowRef] = React.useState(null);\n const ignoreNonTouchEvents = React.useRef(false);\n const disableInteractive = disableInteractiveProp || followCursor;\n const closeTimer = useTimeout();\n const enterTimer = useTimeout();\n const leaveTimer = useTimeout();\n const touchTimer = useTimeout();\n const [openState, setOpenState] = useControlled({\n controlled: openProp,\n default: false,\n name: 'Tooltip',\n state: 'open'\n });\n let open = openState;\n if (process.env.NODE_ENV !== 'production') {\n // eslint-disable-next-line react-hooks/rules-of-hooks\n const {\n current: isControlled\n } = React.useRef(openProp !== undefined);\n\n // eslint-disable-next-line react-hooks/rules-of-hooks\n React.useEffect(() => {\n if (childNode && childNode.disabled && !isControlled && title !== '' && childNode.tagName.toLowerCase() === 'button') {\n console.error(['MUI: You are providing a disabled `button` child to the Tooltip component.', 'A disabled element does not fire events.', \"Tooltip needs to listen to the child element's events to display the title.\", '', 'Add a simple wrapper element, such as a `span`.'].join('\\n'));\n }\n }, [title, childNode, isControlled]);\n }\n const id = useId(idProp);\n const prevUserSelect = React.useRef();\n const stopTouchInteraction = useEventCallback(() => {\n if (prevUserSelect.current !== undefined) {\n document.body.style.WebkitUserSelect = prevUserSelect.current;\n prevUserSelect.current = undefined;\n }\n touchTimer.clear();\n });\n React.useEffect(() => stopTouchInteraction, [stopTouchInteraction]);\n const handleOpen = event => {\n hystersisTimer.clear();\n hystersisOpen = true;\n\n // The mouseover event will trigger for every nested element in the tooltip.\n // We can skip rerendering when the tooltip is already open.\n // We are using the mouseover event instead of the mouseenter event to fix a hide/show issue.\n setOpenState(true);\n if (onOpen && !open) {\n onOpen(event);\n }\n };\n const handleClose = useEventCallback(\n /**\n * @param {React.SyntheticEvent | Event} event\n */\n event => {\n hystersisTimer.start(800 + leaveDelay, () => {\n hystersisOpen = false;\n });\n setOpenState(false);\n if (onClose && open) {\n onClose(event);\n }\n closeTimer.start(theme.transitions.duration.shortest, () => {\n ignoreNonTouchEvents.current = false;\n });\n });\n const handleEnter = event => {\n if (ignoreNonTouchEvents.current && event.type !== 'touchstart') {\n return;\n }\n\n // Remove the title ahead of time.\n // We don't want to wait for the next render commit.\n // We would risk displaying two tooltips at the same time (native + this one).\n if (childNode) {\n childNode.removeAttribute('title');\n }\n enterTimer.clear();\n leaveTimer.clear();\n if (enterDelay || hystersisOpen && enterNextDelay) {\n enterTimer.start(hystersisOpen ? enterNextDelay : enterDelay, () => {\n handleOpen(event);\n });\n } else {\n handleOpen(event);\n }\n };\n const handleLeave = event => {\n enterTimer.clear();\n leaveTimer.start(leaveDelay, () => {\n handleClose(event);\n });\n };\n const {\n isFocusVisibleRef,\n onBlur: handleBlurVisible,\n onFocus: handleFocusVisible,\n ref: focusVisibleRef\n } = useIsFocusVisible();\n // We don't necessarily care about the focusVisible state (which is safe to access via ref anyway).\n // We just need to re-render the Tooltip if the focus-visible state changes.\n const [, setChildIsFocusVisible] = React.useState(false);\n const handleBlur = event => {\n handleBlurVisible(event);\n if (isFocusVisibleRef.current === false) {\n setChildIsFocusVisible(false);\n handleLeave(event);\n }\n };\n const handleFocus = event => {\n // Workaround for https://github.com/facebook/react/issues/7769\n // The autoFocus of React might trigger the event before the componentDidMount.\n // We need to account for this eventuality.\n if (!childNode) {\n setChildNode(event.currentTarget);\n }\n handleFocusVisible(event);\n if (isFocusVisibleRef.current === true) {\n setChildIsFocusVisible(true);\n handleEnter(event);\n }\n };\n const detectTouchStart = event => {\n ignoreNonTouchEvents.current = true;\n const childrenProps = children.props;\n if (childrenProps.onTouchStart) {\n childrenProps.onTouchStart(event);\n }\n };\n const handleMouseOver = handleEnter;\n const handleMouseLeave = handleLeave;\n const handleTouchStart = event => {\n detectTouchStart(event);\n leaveTimer.clear();\n closeTimer.clear();\n stopTouchInteraction();\n prevUserSelect.current = document.body.style.WebkitUserSelect;\n // Prevent iOS text selection on long-tap.\n document.body.style.WebkitUserSelect = 'none';\n touchTimer.start(enterTouchDelay, () => {\n document.body.style.WebkitUserSelect = prevUserSelect.current;\n handleEnter(event);\n });\n };\n const handleTouchEnd = event => {\n if (children.props.onTouchEnd) {\n children.props.onTouchEnd(event);\n }\n stopTouchInteraction();\n leaveTimer.start(leaveTouchDelay, () => {\n handleClose(event);\n });\n };\n React.useEffect(() => {\n if (!open) {\n return undefined;\n }\n\n /**\n * @param {KeyboardEvent} nativeEvent\n */\n function handleKeyDown(nativeEvent) {\n // IE11, Edge (prior to using Bink?) use 'Esc'\n if (nativeEvent.key === 'Escape' || nativeEvent.key === 'Esc') {\n handleClose(nativeEvent);\n }\n }\n document.addEventListener('keydown', handleKeyDown);\n return () => {\n document.removeEventListener('keydown', handleKeyDown);\n };\n }, [handleClose, open]);\n const handleRef = useForkRef(children.ref, focusVisibleRef, setChildNode, ref);\n\n // There is no point in displaying an empty tooltip.\n // So we exclude all falsy values, except 0, which is valid.\n if (!title && title !== 0) {\n open = false;\n }\n const popperRef = React.useRef();\n const handleMouseMove = event => {\n const childrenProps = children.props;\n if (childrenProps.onMouseMove) {\n childrenProps.onMouseMove(event);\n }\n cursorPosition = {\n x: event.clientX,\n y: event.clientY\n };\n if (popperRef.current) {\n popperRef.current.update();\n }\n };\n const nameOrDescProps = {};\n const titleIsString = typeof title === 'string';\n if (describeChild) {\n nameOrDescProps.title = !open && titleIsString && !disableHoverListener ? title : null;\n nameOrDescProps['aria-describedby'] = open ? id : null;\n } else {\n nameOrDescProps['aria-label'] = titleIsString ? title : null;\n nameOrDescProps['aria-labelledby'] = open && !titleIsString ? id : null;\n }\n const childrenProps = _extends({}, nameOrDescProps, other, children.props, {\n className: clsx(other.className, children.props.className),\n onTouchStart: detectTouchStart,\n ref: handleRef\n }, followCursor ? {\n onMouseMove: handleMouseMove\n } : {});\n if (process.env.NODE_ENV !== 'production') {\n childrenProps['data-mui-internal-clone-element'] = true;\n\n // eslint-disable-next-line react-hooks/rules-of-hooks\n React.useEffect(() => {\n if (childNode && !childNode.getAttribute('data-mui-internal-clone-element')) {\n console.error(['MUI: The `children` component of the Tooltip is not forwarding its props correctly.', 'Please make sure that props are spread on the same element that the ref is applied to.'].join('\\n'));\n }\n }, [childNode]);\n }\n const interactiveWrapperListeners = {};\n if (!disableTouchListener) {\n childrenProps.onTouchStart = handleTouchStart;\n childrenProps.onTouchEnd = handleTouchEnd;\n }\n if (!disableHoverListener) {\n childrenProps.onMouseOver = composeEventHandler(handleMouseOver, childrenProps.onMouseOver);\n childrenProps.onMouseLeave = composeEventHandler(handleMouseLeave, childrenProps.onMouseLeave);\n if (!disableInteractive) {\n interactiveWrapperListeners.onMouseOver = handleMouseOver;\n interactiveWrapperListeners.onMouseLeave = handleMouseLeave;\n }\n }\n if (!disableFocusListener) {\n childrenProps.onFocus = composeEventHandler(handleFocus, childrenProps.onFocus);\n childrenProps.onBlur = composeEventHandler(handleBlur, childrenProps.onBlur);\n if (!disableInteractive) {\n interactiveWrapperListeners.onFocus = handleFocus;\n interactiveWrapperListeners.onBlur = handleBlur;\n }\n }\n if (process.env.NODE_ENV !== 'production') {\n if (children.props.title) {\n console.error(['MUI: You have provided a `title` prop to the child of .', `Remove this title prop \\`${children.props.title}\\` or the Tooltip component.`].join('\\n'));\n }\n }\n const popperOptions = React.useMemo(() => {\n var _PopperProps$popperOp;\n let tooltipModifiers = [{\n name: 'arrow',\n enabled: Boolean(arrowRef),\n options: {\n element: arrowRef,\n padding: 4\n }\n }];\n if ((_PopperProps$popperOp = PopperProps.popperOptions) != null && _PopperProps$popperOp.modifiers) {\n tooltipModifiers = tooltipModifiers.concat(PopperProps.popperOptions.modifiers);\n }\n return _extends({}, PopperProps.popperOptions, {\n modifiers: tooltipModifiers\n });\n }, [arrowRef, PopperProps]);\n const ownerState = _extends({}, props, {\n isRtl,\n arrow,\n disableInteractive,\n placement,\n PopperComponentProp,\n touch: ignoreNonTouchEvents.current\n });\n const classes = useUtilityClasses(ownerState);\n const PopperComponent = (_ref = (_slots$popper = slots.popper) != null ? _slots$popper : components.Popper) != null ? _ref : TooltipPopper;\n const TransitionComponent = (_ref2 = (_ref3 = (_slots$transition = slots.transition) != null ? _slots$transition : components.Transition) != null ? _ref3 : TransitionComponentProp) != null ? _ref2 : Grow;\n const TooltipComponent = (_ref4 = (_slots$tooltip = slots.tooltip) != null ? _slots$tooltip : components.Tooltip) != null ? _ref4 : TooltipTooltip;\n const ArrowComponent = (_ref5 = (_slots$arrow = slots.arrow) != null ? _slots$arrow : components.Arrow) != null ? _ref5 : TooltipArrow;\n const popperProps = appendOwnerState(PopperComponent, _extends({}, PopperProps, (_slotProps$popper = slotProps.popper) != null ? _slotProps$popper : componentsProps.popper, {\n className: clsx(classes.popper, PopperProps == null ? void 0 : PopperProps.className, (_ref6 = (_slotProps$popper2 = slotProps.popper) != null ? _slotProps$popper2 : componentsProps.popper) == null ? void 0 : _ref6.className)\n }), ownerState);\n const transitionProps = appendOwnerState(TransitionComponent, _extends({}, TransitionProps, (_slotProps$transition = slotProps.transition) != null ? _slotProps$transition : componentsProps.transition), ownerState);\n const tooltipProps = appendOwnerState(TooltipComponent, _extends({}, (_slotProps$tooltip = slotProps.tooltip) != null ? _slotProps$tooltip : componentsProps.tooltip, {\n className: clsx(classes.tooltip, (_ref7 = (_slotProps$tooltip2 = slotProps.tooltip) != null ? _slotProps$tooltip2 : componentsProps.tooltip) == null ? void 0 : _ref7.className)\n }), ownerState);\n const tooltipArrowProps = appendOwnerState(ArrowComponent, _extends({}, (_slotProps$arrow = slotProps.arrow) != null ? _slotProps$arrow : componentsProps.arrow, {\n className: clsx(classes.arrow, (_ref8 = (_slotProps$arrow2 = slotProps.arrow) != null ? _slotProps$arrow2 : componentsProps.arrow) == null ? void 0 : _ref8.className)\n }), ownerState);\n return /*#__PURE__*/_jsxs(React.Fragment, {\n children: [/*#__PURE__*/React.cloneElement(children, childrenProps), /*#__PURE__*/_jsx(PopperComponent, _extends({\n as: PopperComponentProp != null ? PopperComponentProp : Popper,\n placement: placement,\n anchorEl: followCursor ? {\n getBoundingClientRect: () => ({\n top: cursorPosition.y,\n left: cursorPosition.x,\n right: cursorPosition.x,\n bottom: cursorPosition.y,\n width: 0,\n height: 0\n })\n } : childNode,\n popperRef: popperRef,\n open: childNode ? open : false,\n id: id,\n transition: true\n }, interactiveWrapperListeners, popperProps, {\n popperOptions: popperOptions,\n children: ({\n TransitionProps: TransitionPropsInner\n }) => /*#__PURE__*/_jsx(TransitionComponent, _extends({\n timeout: theme.transitions.duration.shorter\n }, TransitionPropsInner, transitionProps, {\n children: /*#__PURE__*/_jsxs(TooltipComponent, _extends({}, tooltipProps, {\n children: [title, arrow ? /*#__PURE__*/_jsx(ArrowComponent, _extends({}, tooltipArrowProps, {\n ref: setArrowRef\n })) : null]\n }))\n }))\n }))]\n });\n});\nprocess.env.NODE_ENV !== \"production\" ? Tooltip.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the d.ts file and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * If `true`, adds an arrow to the tooltip.\n * @default false\n */\n arrow: PropTypes.bool,\n /**\n * Tooltip reference element.\n */\n children: elementAcceptingRef.isRequired,\n /**\n * Override or extend the styles applied to the component.\n */\n classes: PropTypes.object,\n /**\n * @ignore\n */\n className: PropTypes.string,\n /**\n * The components used for each slot inside.\n *\n * This prop is an alias for the `slots` prop.\n * It's recommended to use the `slots` prop instead.\n *\n * @default {}\n */\n components: PropTypes.shape({\n Arrow: PropTypes.elementType,\n Popper: PropTypes.elementType,\n Tooltip: PropTypes.elementType,\n Transition: PropTypes.elementType\n }),\n /**\n * The extra props for the slot components.\n * You can override the existing props or add new ones.\n *\n * This prop is an alias for the `slotProps` prop.\n * It's recommended to use the `slotProps` prop instead, as `componentsProps` will be deprecated in the future.\n *\n * @default {}\n */\n componentsProps: PropTypes.shape({\n arrow: PropTypes.object,\n popper: PropTypes.object,\n tooltip: PropTypes.object,\n transition: PropTypes.object\n }),\n /**\n * Set to `true` if the `title` acts as an accessible description.\n * By default the `title` acts as an accessible label for the child.\n * @default false\n */\n describeChild: PropTypes.bool,\n /**\n * Do not respond to focus-visible events.\n * @default false\n */\n disableFocusListener: PropTypes.bool,\n /**\n * Do not respond to hover events.\n * @default false\n */\n disableHoverListener: PropTypes.bool,\n /**\n * Makes a tooltip not interactive, i.e. it will close when the user\n * hovers over the tooltip before the `leaveDelay` is expired.\n * @default false\n */\n disableInteractive: PropTypes.bool,\n /**\n * Do not respond to long press touch events.\n * @default false\n */\n disableTouchListener: PropTypes.bool,\n /**\n * The number of milliseconds to wait before showing the tooltip.\n * This prop won't impact the enter touch delay (`enterTouchDelay`).\n * @default 100\n */\n enterDelay: PropTypes.number,\n /**\n * The number of milliseconds to wait before showing the tooltip when one was already recently opened.\n * @default 0\n */\n enterNextDelay: PropTypes.number,\n /**\n * The number of milliseconds a user must touch the element before showing the tooltip.\n * @default 700\n */\n enterTouchDelay: PropTypes.number,\n /**\n * If `true`, the tooltip follow the cursor over the wrapped element.\n * @default false\n */\n followCursor: PropTypes.bool,\n /**\n * This prop is used to help implement the accessibility logic.\n * If you don't provide this prop. It falls back to a randomly generated id.\n */\n id: PropTypes.string,\n /**\n * The number of milliseconds to wait before hiding the tooltip.\n * This prop won't impact the leave touch delay (`leaveTouchDelay`).\n * @default 0\n */\n leaveDelay: PropTypes.number,\n /**\n * The number of milliseconds after the user stops touching an element before hiding the tooltip.\n * @default 1500\n */\n leaveTouchDelay: PropTypes.number,\n /**\n * Callback fired when the component requests to be closed.\n *\n * @param {React.SyntheticEvent} event The event source of the callback.\n */\n onClose: PropTypes.func,\n /**\n * Callback fired when the component requests to be open.\n *\n * @param {React.SyntheticEvent} event The event source of the callback.\n */\n onOpen: PropTypes.func,\n /**\n * If `true`, the component is shown.\n */\n open: PropTypes.bool,\n /**\n * Tooltip placement.\n * @default 'bottom'\n */\n placement: PropTypes.oneOf(['bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n /**\n * The component used for the popper.\n * @default Popper\n */\n PopperComponent: PropTypes.elementType,\n /**\n * Props applied to the [`Popper`](/material-ui/api/popper/) element.\n * @default {}\n */\n PopperProps: PropTypes.object,\n /**\n * The extra props for the slot components.\n * You can override the existing props or add new ones.\n *\n * This prop is an alias for the `componentsProps` prop, which will be deprecated in the future.\n *\n * @default {}\n */\n slotProps: PropTypes.shape({\n arrow: PropTypes.object,\n popper: PropTypes.object,\n tooltip: PropTypes.object,\n transition: PropTypes.object\n }),\n /**\n * The components used for each slot inside.\n *\n * This prop is an alias for the `components` prop, which will be deprecated in the future.\n *\n * @default {}\n */\n slots: PropTypes.shape({\n arrow: PropTypes.elementType,\n popper: PropTypes.elementType,\n tooltip: PropTypes.elementType,\n transition: PropTypes.elementType\n }),\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Tooltip title. Zero-length titles string, undefined, null and false are never displayed.\n */\n title: PropTypes.node,\n /**\n * The component used for the transition.\n * [Follow this guide](/material-ui/transitions/#transitioncomponent-prop) to learn more about the requirements for this component.\n * @default Grow\n */\n TransitionComponent: PropTypes.elementType,\n /**\n * Props applied to the transition element.\n * By default, the element is based on this [`Transition`](http://reactcommunity.org/react-transition-group/transition/) component.\n */\n TransitionProps: PropTypes.object\n} : void 0;\nexport default Tooltip;","import '@/components/mui/menu-item.component.css';\nimport ArrowRightIcon from '@mui/icons-material/ArrowRight';\nimport {\n ListItemIcon as MuiListItemIcon,\n ListItemText as MuiListItemText,\n MenuItem as MuiMenuItem,\n} from '@mui/material';\nimport Tooltip from '@mui/material/Tooltip';\nimport { Localized, ReferencedItem, SingleColumnMenu } from 'platform-bible-utils';\nimport { MouseEvent, PropsWithChildren } from 'react';\n\ntype MenuItemInfoBase = {\n /** Text (displayable in the UI) as the name of the menu item */\n label: string;\n /** Text to display when the mouse hovers over the menu item */\n tooltip?: string;\n};\n\nexport type Command = MenuItemInfoBase & {\n /** Command to execute (string.string) */\n command: string;\n};\n\ntype SubMenu = MenuItemInfoBase & {\n /** Command to execute (string.string) */\n items: MenuItemInfo[];\n};\n\nexport interface CommandHandler {\n (command: Command): void;\n}\n\nexport type MenuPropsBase = {\n /*\n * The JSON defining the menu whose items are to be rendered. This will typically be one of the\n * menus in the \"defs\" in a Platform.Bible menu (see PlatformMenus). The schema for this is\n * menuDocumentSchema (at the end of menus.model.ts). Note that while this is a\n * \"SingleColumnMenu\", somewhat bizarrely, a MultiColumnMenu is a SingleColumnMenu, so it really\n * could be a MultiColumnMenu, in which case, column had better be defined so it can be used\n * to filter out the actual groups and items to display on the column.\n */\n menuDefinition: Localized;\n\n commandHandler: CommandHandler;\n\n /**\n * Additional action to perform when any menu item is clicked. Allows the caller to handle event\n * (e.g., to close the menu).\n */\n onClick?: (event: MouseEvent) => void;\n};\n\nexport type MenuItemListProps = MenuPropsBase & {\n /** Optional unique (column) identifier */\n columnId?: ReferencedItem;\n};\n\nexport type MenuItemProps = Omit &\n PropsWithChildren<{\n /** Optional unique identifier */\n id?: string;\n\n onClick: (event: MouseEvent) => void;\n }>;\n\ntype MenuItemInfo = (Command | SubMenu) & {\n /**\n * If specified, menu item will be inset if it does not have a leading icon.\n *\n * @default true\n */\n allowForLeadingIcons?: boolean;\n /**\n * If specified, the path to the icon image to display on the leading side of the menu text.\n *\n * @default undefined (no leading icon will be shown)\n */\n iconPathBefore?: string;\n /**\n * If specified, the path to the icon image to display on the trailing side of the menu text.\n *\n * @default undefined (no trailing icon will be shown)\n */\n iconPathAfter?: string;\n /**\n * If true, list item is focused during the first mount\n *\n * @default false\n */\n hasAutoFocus?: boolean;\n\n /** Additional css classes to help with unique styling of the menu item */\n className?: string;\n\n /**\n * If true, the menu item will appear disabled and it will not respond to clicks or mouse hovers.\n *\n * @default false\n */\n isDisabled?: boolean;\n\n /**\n * If true, compact vertical padding designed for keyboard and mouse input is used.\n *\n * @default true\n */\n isDense?: boolean;\n\n /**\n * If true, a right-arrow icon will be displayed (iconPathAfter, if specified, will be ignored).\n *\n * @default false\n */\n isSubMenuParent?: boolean;\n\n /**\n * If true, the left and right padding is removed\n *\n * @default false\n */\n hasDisabledGutters?: boolean;\n\n /**\n * If true, a 1px light border is added to bottom of menu item\n *\n * @default false\n */\n hasDivider?: boolean;\n\n /** Help identify which element has keyboard focus */\n focusVisibleClassName?: string;\n\n /** If it's a submenu, it should have the items property */\n items?: MenuItemInfo[];\n};\n\nfunction getIcon(icon: string | undefined, menuLabel: string, leading: boolean) {\n return icon ? (\n \n {`${leading\n \n ) : undefined;\n}\n\nexport default function MenuItem(props: MenuItemProps) {\n const {\n onClick,\n label,\n tooltip,\n allowForLeadingIcons = true,\n iconPathBefore = undefined,\n iconPathAfter = undefined,\n hasAutoFocus = false,\n className,\n isDisabled = false,\n isDense = true,\n isSubMenuParent = false,\n hasDisabledGutters = false,\n hasDivider = false,\n focusVisibleClassName,\n id,\n children,\n } = props;\n\n const menuItem = (\n \n {label ? (\n <>\n {getIcon(iconPathBefore, label, true)}\n \n {isSubMenuParent ? (\n \n \n \n ) : (\n getIcon(iconPathAfter, label, false)\n )}\n \n ) : (\n children\n )}\n \n );\n\n return tooltip ? (\n \n
    {menuItem}
    \n
    \n ) : (\n menuItem\n );\n}\n","import MenuItem, {\n MenuItemListProps,\n MenuItemProps,\n MenuPropsBase,\n} from '@/components/mui/menu-item.component';\nimport { Menu } from '@mui/material';\nimport {\n Localized,\n MenuGroupDetailsInSubMenu,\n MenuItemContainingCommand,\n MenuItemContainingSubmenu,\n OrderedExtensibleContainer,\n ReferencedItem,\n SingleColumnMenu,\n} from 'platform-bible-utils';\nimport { MouseEvent, useMemo, useState } from 'react';\n\n/**\n * All the exported types in this file should be regarded as \"internal\" (i.e., they should not be\n * exposed via index.ts).\n */\n\nexport type GroupedMenuPropsBase = MenuPropsBase & {\n /** Optional unique (column) identifier */\n columnId?: ReferencedItem;\n};\n\nexport type GroupedMenuItemListProps = MenuItemListProps & {\n /**\n * If the menuDefinition includes \"top-level\" groups (i.e., those that belong to a column as\n * opposed to those that belong to a submenu) that should not be included in the list, then this\n * array specifies which groups to include. Likewise, for a submenu, this list indicates which\n * groups are pertinent for that submenu. So then for a context menu this property need not be\n * specified since it is a top-level menu based on a \"true\" SingleColumnMenu (i.e., one that is\n * not a MultiColumnMenu).\n */\n includedGroups?: {\n id: string;\n group: Localized;\n }[];\n};\n\ninterface ItemInfo {\n item: Localized;\n isLastItemInGroup: boolean;\n}\n\ntype SubMenuProps = MenuPropsBase & {\n parentMenuItem: Localized;\n parentItemProps: Omit, 'iconPathAfter'>;\n};\n\nfunction getAllGroups(menuDefinition: Localized) {\n const groupEntries = Object.entries(menuDefinition.groups);\n // Convert array of entries to array of objects with id and group properties\n return groupEntries.map(([key, value]) => ({ id: key, group: value }));\n}\n\nfunction SubMenu(props: SubMenuProps) {\n const [anchorEl, setAnchorEl] = useState(undefined);\n\n const { parentMenuItem, parentItemProps, menuDefinition } = props;\n\n const handleParentMenuItemClick = (event: MouseEvent) => {\n setAnchorEl(event.currentTarget);\n };\n\n const handleClose = () => {\n setAnchorEl(undefined);\n };\n\n const renderSubMenuItems = () => {\n let includedGroups = getAllGroups(menuDefinition).filter((g) => 'menuItem' in g.group);\n\n // Ensure valid parent menu was provided. (If not, submenu will contain all groups!)\n if (!parentMenuItem?.id) throw new Error('A valid parent menu item is required for submenus.');\n\n // When laying out a submenu, only include groups associated with the provided parent menu.\n // Note: without the (annoying) redundant check that the included groups\n // have the menuItem field, TS doesn't think it exists.\n includedGroups = includedGroups.filter(\n (group) => 'menuItem' in group.group && group.group.menuItem === parentMenuItem.id,\n );\n\n return ;\n };\n\n return (\n <>\n \n \n {renderSubMenuItems()}\n \n \n );\n}\n\nconst getOrderedGroupItems = (\n groupId: string,\n allItems: Localized[],\n) => {\n // Filter items that belong to the specified group\n const itemsForGroup = allItems.filter((item) => item.group === groupId);\n // Sort items based on order\n const sortedItems = itemsForGroup.sort((a, b) => (a.order || 0) - (b.order || 0));\n return sortedItems;\n};\n\n/**\n * This component is internal; it does not need to be exposed to the outside world since it is not\n * useful on its own. It is used to generate and lay out the MenuItems that appear either on a\n * top-level menu (in a GridMenu or ContextMenu) or in a submenu.\n */\nexport default function GroupedMenuItemList(menuProps: GroupedMenuItemListProps) {\n const { menuDefinition, onClick, commandHandler, includedGroups } = menuProps;\n\n const { items, allowForLeadingIcons } = useMemo(() => {\n const groupsToInclude =\n includedGroups && includedGroups.length > 0\n ? includedGroups\n : // We're apparently laying out a single-column menu (presumably a context menu). In this\n // case, all groups should be included except ones that belong to a submenu.\n getAllGroups(menuDefinition).filter((g) => !('menuItem' in g.group));\n\n const sortedGroups = Object.values(groupsToInclude).sort(\n (a, b) => (a.group.order || 0) - (b.group.order || 0),\n );\n\n const itemArray: ItemInfo[] = [];\n\n sortedGroups.forEach((group) => {\n getOrderedGroupItems(group.id, menuDefinition.items).forEach((item) =>\n itemArray.push({ item, isLastItemInGroup: false }),\n );\n if (itemArray.length > 0) itemArray[itemArray.length - 1].isLastItemInGroup = true;\n });\n\n // No divider after last item in final group.\n if (itemArray.length > 0) itemArray[itemArray.length - 1].isLastItemInGroup = false;\n\n const allowSpaceForLeadingIcons = itemArray.some(\n (i) => 'iconPathBefore' in i.item && i.item.iconPathBefore,\n );\n\n return { items: itemArray, allowForLeadingIcons: allowSpaceForLeadingIcons };\n }, [includedGroups, menuDefinition]);\n\n // Create props for MenuItem component including setting hasDivider for the last item in a group\n const createMenuItemProps = ({ item, isLastItemInGroup }: ItemInfo) => {\n const menuItemProps = {\n className: 'papi-menu-item',\n label: item.label,\n tooltip: item.tooltip,\n iconPathBefore: 'iconPathBefore' in item ? item.iconPathBefore : undefined,\n iconPathAfter: 'iconPathAfter' in item ? item.iconPathAfter : undefined,\n hasDivider: isLastItemInGroup, // Set hasDivider to true for the last item in a group\n allowForLeadingIcons,\n };\n\n return menuItemProps;\n };\n\n const [firstItem] = items;\n\n if (!firstItem) return
    ;\n\n const divKey = firstItem.item.group;\n\n return (\n
    \n {items.map((itemInfo, index) => {\n const { item } = itemInfo;\n const menuItemProps = createMenuItemProps(itemInfo);\n if ('command' in item) {\n const key = item.group + index;\n return (\n ) => {\n onClick?.(event);\n commandHandler(item);\n }}\n {...menuItemProps}\n />\n );\n }\n return (\n \n );\n })}\n
    \n );\n}\n","import GroupedMenuItemList from '@/components/mui/grouped-menu-item-list.component';\nimport { MenuItemListProps } from '@/components/mui/menu-item.component';\nimport { MultiColumnMenu } from 'platform-bible-utils';\n\n/**\n * This component is internal; it does not need to be exposed to the outside world since it is not\n * useful on its own. Use either GridMenu or ContextMenu.\n */\nexport default function TopLevelMenu(props: MenuItemListProps) {\n const { menuDefinition, columnId } = props;\n\n const groupEntries = Object.entries(menuDefinition.groups);\n // Convert array of entries to array of objects with id and group properties\n const groups = groupEntries.map(([key, value]) => ({ id: key, group: value }));\n let includedGroups = groups.filter((g) => 'column' in g.group);\n\n // Check if column is provided and menuDefinition is a MultiColumnMenu\n if (\n columnId &&\n 'columns' in menuDefinition &&\n // Without this type assertion, TS doesn't know what columns is.\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n (menuDefinition as MultiColumnMenu).columns[columnId]\n ) {\n // When laying out a single column in a MultiColumnMenu, only include groups associated with\n // the provided column. Note: without the (annoying) redundant check that the included groups\n // have the colum field, TS doesn't think it exists.\n includedGroups = includedGroups.filter(\n (g) => 'column' in g.group && g.group.column === columnId,\n );\n }\n\n return ;\n}\n","import '@/components/mui/grid-menu.component.css';\nimport { GroupedMenuPropsBase } from '@/components/mui/grouped-menu-item-list.component';\nimport { CommandHandler } from '@/components/mui/menu-item.component';\nimport TopLevelMenu from '@/components/mui/top-level-menu.component';\nimport { Grid, List } from '@mui/material';\nimport {\n Localized,\n MenuColumnWithHeader,\n MultiColumnMenu,\n ReferencedItem,\n} from 'platform-bible-utils';\nimport { useMemo } from 'react';\n\ntype ColumnInfo = {\n /*\n * The ID (`${string}.${string}`) of a specific menu column.\n */\n id: ReferencedItem;\n\n /*\n * Metadata (label, order, etc.) for a specific menu column.\n */\n metadata: Localized;\n};\n\ntype MenuColumnProps = ColumnInfo &\n GroupedMenuPropsBase & {\n /** Additional css classes to help with unique styling of the menu column */\n className?: string;\n };\n\nexport type GridMenuInfo = {\n /** The menu object containing information about the columns, groups, and items to display. */\n multiColumnMenu: Localized;\n};\n\nexport type GridMenuProps = GridMenuInfo & {\n /** Optional unique identifier */\n id?: string;\n\n commandHandler: CommandHandler;\n\n /** Additional css classes to help with unique styling of the grid menu */\n className?: string;\n};\n\nfunction MenuColumn({\n commandHandler,\n menuDefinition,\n id,\n metadata,\n onClick,\n className,\n}: MenuColumnProps) {\n return (\n \n

    \n {metadata.label}\n

    \n {/* It would seem as though this List component were unnecessary, since it only contains one\n thing, but the \"dense\" property does affect the layout of the items (in a way I don't fully\n understand). There might be a better way. */}\n \n \n \n \n );\n}\n\nexport default function GridMenu({\n commandHandler,\n className,\n multiColumnMenu,\n id,\n}: GridMenuProps) {\n const { columns } = multiColumnMenu;\n\n const sortedColumns = useMemo(() => {\n const columnNumbers = new Map();\n Object.getOwnPropertyNames(columns).forEach((columnName: string) => {\n // We know for sure there is a (boolean) property 'isExtensible' that we are not interested in.\n if (columnName === 'isExtensible') return;\n // TS doesn't allow `columnName` above to be a ReferencedItem even though the type says it is\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const columnId = columnName as ReferencedItem;\n const column = columns[columnId];\n // As of right now (and hopefully forever after), all remaining properties of the\n // ColumnsWithHeaders object are columns whose property names are the IDs of the columns.\n // This is an additional (redundant) sanity check. Specifically we're interested in\n // MenuColumnWithHeader objects, which TypeScript now \"knows\" we have, but at runtime all we\n // can check for is that it's an object with a valid numeric order field. That's likely good\n // enough.\n if (\n typeof column === 'object' &&\n typeof column.order === 'number' &&\n !Number.isNaN(column.order)\n )\n columnNumbers.set(column.order, { id: columnId, metadata: column });\n else\n console.warn(\n `Property ${columnName} (${typeof column}) on menu ${id} is not a valid column and is being ignored. This might indicate data corruption`,\n );\n });\n\n // Extract values and sort them based on the 'order' property\n return Array.from(columnNumbers.values()).sort((a, b) => {\n return (a.metadata.order || 0) - (b.metadata.order || 0);\n });\n }, [columns, id]);\n\n // We might need something like this if we need to be able to prevent empty columns\n // sortedColumns.filter((c) => multiColumnMenu.groups.some((g) => 'column' in g && (g as .column)...\n\n return (\n \n {sortedColumns.map((col, index) => (\n \n ))}\n \n );\n}\n","import { useEffect, useRef, useState } from 'react';\n\nexport type UsePromiseOptions = {\n /**\n * Whether to leave the value as the most recent resolved promise value or set it back to\n * defaultValue while running the promise again. Defaults to true\n */\n preserveValue?: boolean;\n};\n\n/** Set up defaults for options for usePromise hook */\nfunction getUsePromiseOptionsDefaults(options: UsePromiseOptions): UsePromiseOptions {\n return {\n preserveValue: true,\n ...options,\n };\n}\n\n/**\n * Awaits a promise and returns a loading value while the promise is unresolved\n *\n * @param promiseFactoryCallback A function that returns the promise to await. If this callback is\n * undefined, the current value will be returned (defaultValue unless it was previously changed\n * and `options.preserveValue` is true), and there will be no loading.\n *\n * WARNING: MUST BE STABLE - const or wrapped in useCallback. The reference must not be updated\n * every render\n * @param defaultValue The initial value to return while first awaiting the promise. If\n * `options.preserveValue` is false, this value is also shown while awaiting the promise on\n * subsequent calls.\n *\n * Note: this parameter is internally assigned to a `ref`, so changing it will not cause any hooks\n * to re-run with its new value. This means that, if the `promiseFactoryCallback` changes and\n * `options.preserveValue` is `false`, the returned value will be set to the current\n * `defaultValue`. However, the returned value will not be updated if`defaultValue` changes.\n * @param options Various options for adjusting how this hook runs the `promiseFactoryCallback`\n *\n * Note: this parameter is internally assigned to a `ref`, so changing it will not cause any hooks\n * to re-run with its new value. However, the latest `options.preserveValue` will always be used\n * appropriately to determine whether to preserve the returned value when changing the\n * `promiseFactoryCallback`\n * @returns `[value, isLoading]`\n *\n * - `value`: the current value for the promise, either the defaultValue or the resolved promise value\n * - `isLoading`: whether the promise is waiting to be resolved\n */\nconst usePromise = (\n promiseFactoryCallback: (() => Promise) | undefined,\n defaultValue: T,\n options: UsePromiseOptions = {},\n): [value: T, isLoading: boolean] => {\n // Use defaultValue as a ref so it doesn't update dependency arrays\n const defaultValueRef = useRef(defaultValue);\n defaultValueRef.current = defaultValue;\n // Use options as a ref so it doesn't update dependency arrays\n const optionsDefaultedRef = useRef(options);\n optionsDefaultedRef.current = getUsePromiseOptionsDefaults(optionsDefaultedRef.current);\n\n const [value, setValue] = useState(() => defaultValueRef.current);\n const [isLoading, setIsLoading] = useState(true);\n useEffect(() => {\n let promiseIsCurrent = true;\n // If a promiseFactoryCallback was provided, we are loading. Otherwise, there is no loading to do\n setIsLoading(!!promiseFactoryCallback);\n (async () => {\n // If there is a callback to run, run it\n if (promiseFactoryCallback) {\n const result = await promiseFactoryCallback();\n // If the promise was not already replaced, update the value\n if (promiseIsCurrent) {\n setValue(() => result);\n setIsLoading(false);\n }\n }\n })();\n\n return () => {\n // Mark this promise as old and not to be used\n promiseIsCurrent = false;\n if (!optionsDefaultedRef.current.preserveValue) setValue(() => defaultValueRef.current);\n };\n }, [promiseFactoryCallback]);\n\n return [value, isLoading];\n};\nexport default usePromise;\n","\"use client\";\n\nimport createSvgIcon from './utils/createSvgIcon';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nexport default createSvgIcon( /*#__PURE__*/_jsx(\"path\", {\n d: \"M3 18h18v-2H3zm0-5h18v-2H3zm0-7v2h18V6z\"\n}), 'Menu');","import GridMenu from '@/components/mui/grid-menu.component';\nimport { Command, CommandHandler } from '@/components/mui/menu-item.component';\nimport usePromise from '@/hooks/use-promise.hook';\nimport { Menu as MenuIcon } from '@mui/icons-material';\nimport { Drawer, IconButton } from '@mui/material';\nimport { Localized, MultiColumnMenu } from 'platform-bible-utils';\nimport {\n MouseEvent,\n MutableRefObject,\n PropsWithChildren,\n useCallback,\n useEffect,\n useState,\n} from 'react';\n\nexport interface MultiColumnMenuProvider {\n (isSupportAndDevelopment: boolean): Promise>;\n}\n\nexport type HamburgerMenuButtonProps = PropsWithChildren & {\n /** The handler to use for menu commands (and eventually toolbar commands). */\n commandHandler: CommandHandler;\n\n /**\n * Optional reference to the \"div\" container that determines the where the menu should appear. If\n * not defined, then (1,1) used.\n */\n containerRef?: MutableRefObject;\n\n /**\n * The delegate to use to get the menu data. If not specified or if it returns undefined, the data\n * in normalMenu or fullMenu property will be used.\n */\n menuProvider?: MultiColumnMenuProvider;\n\n /**\n * The menu data to show when the menu is opened if the menuProvider property is not defined.\n * (This allows for a default or test-only static menu to be used.)\n */\n normalMenu?: Localized;\n\n /**\n * The menu data to show for \"full\" menu (when opened with the SHIFT key pressed) if the\n * menuProvider property is not defined. (This allows for a default or test-only static menu to be\n * used.)\n */\n fullMenu?: Localized;\n\n /** Additional css class(es) to help with unique styling of the sub-components */\n className?: string;\n\n /** Value to use as prefix for ARIA labels on interactive sub-components */\n ariaLabelPrefix?: string;\n};\n\nexport default function HamburgerMenuButton({\n menuProvider,\n normalMenu,\n fullMenu,\n commandHandler,\n containerRef,\n className,\n ariaLabelPrefix,\n children,\n}: HamburgerMenuButtonProps) {\n const [isMenuOpen, setMenuOpen] = useState(false);\n const [showFullMenu, setShowFullMenu] = useState(false);\n\n const handleMenuItemClick = useCallback(() => {\n if (isMenuOpen) setMenuOpen(false);\n setShowFullMenu(false);\n }, [isMenuOpen]);\n\n const handleMenuButtonClick = useCallback((e: MouseEvent) => {\n e.stopPropagation();\n setMenuOpen((prevIsOpen) => {\n const isOpening = !prevIsOpen;\n if (isOpening && e.shiftKey) setShowFullMenu(true);\n else if (!isOpening) setShowFullMenu(false);\n return isOpening;\n });\n }, []);\n\n const menuCommandHandler = useCallback(\n (command: Command) => {\n handleMenuItemClick();\n return commandHandler(command);\n },\n [commandHandler, handleMenuItemClick],\n );\n\n const [offset, setOffset] = useState({ top: 1, left: 1 });\n\n useEffect(() => {\n if (isMenuOpen) {\n const node = containerRef?.current;\n if (node) {\n const rect = node.getBoundingClientRect();\n const scrollTop = window.scrollY;\n const scrollLeft = window.scrollX;\n const top = rect.top + scrollTop + node.clientHeight;\n const left = rect.left + scrollLeft;\n setOffset({ top, left });\n }\n }\n }, [isMenuOpen, containerRef]);\n\n const [normalMenuData] = usePromise(\n useCallback(async () => {\n return menuProvider?.(false) ?? normalMenu;\n // isMenuOpen needs to be included for the menu contents to reevaluate when reopened\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [menuProvider, normalMenu, isMenuOpen]),\n normalMenu,\n );\n\n const [fullMenuData] = usePromise(\n useCallback(async () => {\n return menuProvider?.(true) ?? fullMenu ?? normalMenuData;\n // isMenuOpen needs to be included for the menu contents to reevaluate when reopened\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [menuProvider, fullMenu, normalMenuData, isMenuOpen]),\n fullMenu ?? normalMenuData,\n );\n\n const menu = showFullMenu && fullMenuData ? fullMenuData : normalMenuData;\n\n return (\n <>\n \n {children ?? }\n \n \n {menu ? (\n \n ) : undefined}\n \n \n );\n}\n","import '@/components/mui/icon-button.component.css';\nimport { IconButton as MuiIconButton } from '@mui/material';\nimport { MouseEventHandler, PropsWithChildren } from 'react';\n\nexport type IconButtonProps = PropsWithChildren<{\n /** Optional unique identifier */\n id?: string;\n /**\n * Required. Used as both the tooltip (aka, title) and the aria-label (used for accessibility,\n * testing, etc.), unless a distinct tooltip is supplied.\n */\n label: string;\n /**\n * Enabled status of button\n *\n * @default false\n */\n isDisabled?: boolean;\n /** Optional tooltip to display if different from the aria-label. */\n tooltip?: string;\n /** If true, no tooltip will be displayed. */\n isTooltipSuppressed?: boolean;\n /**\n * If given, uses a negative margin to counteract the padding on one side (this is often helpful\n * for aligning the left or right side of the icon with content above or below, without ruining\n * the border size and shape).\n *\n * @default false\n */\n adjustMarginToAlignToEdge?: 'end' | 'start' | false;\n /**\n * The size of the component. small is equivalent to the dense button styling.\n *\n * @default false\n */\n size: 'small' | 'medium' | 'large';\n /** Additional css classes to help with unique styling of the button */\n className?: string;\n /** Optional click handler */\n onClick?: MouseEventHandler;\n}>;\n\n/**\n * Iconic button a user can click to do something\n *\n * Thanks to MUI for heavy inspiration and documentation\n * https://mui.com/material-ui/getting-started/overview/\n */\nfunction IconButton({\n id,\n label,\n isDisabled = false,\n tooltip,\n isTooltipSuppressed = false,\n adjustMarginToAlignToEdge = false,\n size = 'medium',\n className,\n onClick,\n children,\n}: IconButtonProps) {\n return (\n \n {children /* the icon to display */}\n \n );\n}\n\nexport default IconButton;\n","import { cn } from '@/utils/shadcn-ui.util';\nimport { LoaderCircle, LucideProps } from 'lucide-react';\nimport { forwardRef } from 'react';\n\nexport type SpinnerProps = LucideProps;\n\nconst Spinner = forwardRef(({ className, ...props }, ref) => {\n return (\n \n );\n});\n\nSpinner.displayName = 'Spinner';\n\nexport default Spinner;\n","import { Input as ShadInput } from '@/components/shadcn-ui/input';\nimport { Label as ShadLabel } from '@/components/shadcn-ui/label';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { ChangeEventHandler, FocusEventHandler } from 'react';\n\nexport type TextFieldProps = {\n /** Optional unique identifier */\n id?: string;\n /**\n * If `true`, the component is disabled.\n *\n * @default false\n */\n isDisabled?: boolean;\n /**\n * If `true`, the label is displayed in an error state.\n *\n * @default false\n */\n hasError?: boolean;\n /**\n * If `true`, the input will take up the full width of its container.\n *\n * @default false\n */\n isFullWidth?: boolean;\n /** Text that gives the user instructions on what contents the TextField expects */\n helperText?: string;\n /** The title of the TextField */\n label?: string;\n /** The short hint displayed in the `input` before the user enters a value. */\n placeholder?: string;\n /**\n * If `true`, the label is displayed as required and the `input` element is required.\n *\n * @default false\n */\n isRequired?: boolean;\n /** Additional css classes to help with unique styling of the text field */\n className?: string;\n /** Starting value for the text field if it is not controlled */\n defaultValue?: string | number;\n /** Value of the text field if controlled */\n value?: string | number;\n /** Triggers when content of textfield is changed */\n onChange?: ChangeEventHandler;\n /** Triggers when textfield gets focus */\n onFocus?: FocusEventHandler;\n /** Triggers when textfield loses focus */\n onBlur?: FocusEventHandler;\n};\n\n/**\n * Text input field\n *\n * Thanks to Shadcn for heavy inspiration and documentation\n * https://ui.shadcn.com/docs/components/input#with-label\n */\nfunction TextField({\n id,\n isDisabled = false,\n hasError = false,\n isFullWidth = false,\n helperText,\n label,\n placeholder,\n isRequired = false,\n className,\n defaultValue,\n value,\n onChange,\n onFocus,\n onBlur,\n}: TextFieldProps) {\n return (\n
    \n {`${label}${isRequired ? '*' : ''}`}\n \n

    {helperText}

    \n
    \n );\n}\n\nexport default TextField;\n","import HamburgerMenuButton, {\n MultiColumnMenuProvider,\n} from '@/components/mui/hamburger-menu-button.component';\nimport { CommandHandler } from '@/components/mui/menu-item.component';\nimport '@/components/mui/toolbar.component.css';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { AppBar, Toolbar as MuiToolbar } from '@mui/material';\nimport { PropsWithChildren, useRef } from 'react';\n\nexport type ToolbarProps = PropsWithChildren<{\n /** The handler to use for menu commands (and eventually toolbar commands). */\n commandHandler: CommandHandler;\n\n /**\n * The optional delegate to use to get the menu data. If not specified, the \"hamburger\" menu will\n * not display.\n */\n menuProvider?: MultiColumnMenuProvider;\n\n /** Optional unique identifier */\n id?: string;\n\n /** Additional css classes to help with unique styling of the toolbar */\n className?: string;\n}>;\n\nexport default function Toolbar({\n menuProvider,\n commandHandler,\n className,\n id,\n children,\n}: ToolbarProps) {\n // This ref will always be defined\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const containerRef = useRef(undefined!);\n\n return (\n
    \n \n \n {menuProvider ? (\n \n ) : undefined}\n {children ?
    {children}
    : undefined}\n \n
    \n
    \n );\n}\n","import React from 'react';\nimport { cva, type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst alertVariants = cva(\n 'tw-relative tw-w-full tw-rounded-lg tw-border tw-p-4 [&>svg~*]:tw-pl-7 [&>svg+div]:tw-translate-y-[-3px] [&>svg]:tw-absolute [&>svg]:tw-left-4 [&>svg]:tw-top-4 [&>svg]:tw-text-foreground',\n {\n variants: {\n variant: {\n default: 'tw-bg-background tw-text-foreground',\n destructive:\n 'tw-border-destructive/50 tw-text-destructive dark:tw-border-destructive [&>svg]:tw-text-destructive',\n },\n },\n defaultVariants: {\n variant: 'default',\n },\n },\n);\n\nconst Alert = React.forwardRef<\n HTMLDivElement,\n React.HTMLAttributes & VariantProps\n>(({ className, variant, ...props }, ref) => (\n
    \n));\nAlert.displayName = 'Alert';\n\nconst AlertTitle = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n {/* added because of https://github.com/jsx-eslint/eslint-plugin-jsx-a11y/blob/main/docs/rules/heading-has-content.md */}\n {props.children}{' '}\n \n ),\n);\nAlertTitle.displayName = 'AlertTitle';\n\nconst AlertDescription = React.forwardRef<\n HTMLParagraphElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n
    \n));\nAlertDescription.displayName = 'AlertDescription';\n\nexport { Alert, AlertTitle, AlertDescription };\n","import React from 'react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Card = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nCard.displayName = 'Card';\n\nconst CardHeader = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nCardHeader.displayName = 'CardHeader';\n\nconst CardTitle = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n {/* added because of https://github.com/jsx-eslint/eslint-plugin-jsx-a11y/blob/main/docs/rules/heading-has-content.md */}\n {props.children}\n \n ),\n);\nCardTitle.displayName = 'CardTitle';\n\nconst CardDescription = React.forwardRef<\n HTMLParagraphElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n

    \n));\nCardDescription.displayName = 'CardDescription';\n\nconst CardContent = React.forwardRef>(\n ({ className, ...props }, ref) => (\n

    \n ),\n);\nCardContent.displayName = 'CardContent';\n\nconst CardFooter = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nCardFooter.displayName = 'CardFooter';\n\nexport { Card, CardHeader, CardFooter, CardTitle, CardDescription, CardContent };\n","import { ComponentProps } from 'react';\nimport { toast as sonner, Toaster } from 'sonner';\n\ntype SonnerProps = ComponentProps;\n\nfunction Sonner({ ...props }: SonnerProps) {\n return (\n \n );\n}\n\n// The re-export of the sonner function was added manually\nexport { Sonner, sonner };\n","import React from 'react';\nimport * as SliderPrimitive from '@radix-ui/react-slider';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Slider = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n \n \n \n));\nSlider.displayName = SliderPrimitive.Root.displayName;\n\nexport { Slider };\n","import React from 'react';\nimport * as SwitchPrimitives from '@radix-ui/react-switch';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Switch = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n));\nSwitch.displayName = SwitchPrimitives.Root.displayName;\n\nexport { Switch };\n","import React from 'react';\nimport * as TabsPrimitive from '@radix-ui/react-tabs';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport const Tabs = TabsPrimitive.Root;\n\nexport type TabsListProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport type TabsTriggerProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport type TabsContentProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport const TabsList = React.forwardRef<\n React.ElementRef,\n TabsListProps\n>(({ className, ...props }, ref) => (\n \n));\nTabsList.displayName = TabsPrimitive.List.displayName;\n\nexport const TabsTrigger = React.forwardRef<\n React.ElementRef,\n TabsTriggerProps\n>(({ className, ...props }, ref) => (\n \n));\nTabsTrigger.displayName = TabsPrimitive.Trigger.displayName;\n\nexport const TabsContent = React.forwardRef<\n React.ElementRef,\n TabsContentProps\n>(({ className, ...props }, ref) => (\n \n));\nTabsContent.displayName = TabsPrimitive.Content.displayName;\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Download } from 'lucide-react';\n\ntype InstallButtonProps = {\n /** The installing boolean value determines the state of the button. */\n isInstalling: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n /** Optional text for the button. */\n buttonText?: string;\n} & ButtonProps;\n\n/**\n * The InstallButton component is a button designed for initiating installs. It includes visuals for\n * active installing and idle states.\n *\n * @param isInstalling The installing boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @param buttonText Optional text for the button.\n * @returns A install button.\n */\nexport default function InstallButton({\n isInstalling,\n handleClick,\n buttonText,\n className,\n ...props\n}: InstallButtonProps) {\n return (\n \n {isInstalling ? (\n \n ) : (\n <>\n \n {buttonText}\n \n )}\n \n );\n}\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\n\ntype EnableButtonProps = {\n /** The enabling boolean value determines the state of the button. */\n isEnabling: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n} & ButtonProps;\n\n/**\n * The EnableButton component is a button designed for initiating enabling of downloads. It includes\n * visuals for active enabling and idle states.\n *\n * @param isEnabling The enabling boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @returns A button that can be used to enable.\n */\nexport default function EnableButton({\n isEnabling,\n handleClick,\n className,\n ...props\n}: EnableButtonProps) {\n return (\n \n {isEnabling ? (\n <>\n \n Enabling...\n \n ) : (\n 'Enable'\n )}\n \n );\n}\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\n\ntype DisableButtonProps = {\n /** The disabling boolean value determines the state of the button. */\n isDisabling: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n} & ButtonProps;\n\n/**\n * The DisableButton component is a button designed for initiating disabling of downloads. It\n * includes visuals for active disabling and idle states.\n *\n * @param isDisabling The disabling boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @returns A button that can be used to disable.\n */\nexport default function DisableButton({\n isDisabling,\n handleClick,\n className,\n ...props\n}: DisableButtonProps) {\n return (\n \n {isDisabling ? (\n <>\n \n Disabling...\n \n ) : (\n 'Disable'\n )}\n \n );\n}\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\n\ntype UpdateButtonProps = {\n /** The updating boolean value determines the state of the button. */\n isUpdating: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n} & ButtonProps;\n\n/**\n * The UpdateButton component is a button designed for initiating updates for downloaded extensions.\n * It includes visuals for active updating and idle states.\n *\n * @param isUpdating The updating boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @returns A button that can be used to update.\n */\nexport default function UpdateButton({\n isUpdating,\n handleClick,\n className,\n ...props\n}: UpdateButtonProps) {\n return (\n \n {isUpdating ? (\n <>\n \n Updating...\n \n ) : (\n 'Update'\n )}\n \n );\n}\n","import { cn } from '@/utils/shadcn-ui.util';\nimport Markdown, { MarkdownToJSX } from 'markdown-to-jsx';\nimport { useMemo } from 'react';\n\ninterface MarkdownRendererProps {\n /** Optional unique identifier */\n id?: string;\n /** The markdown string to render */\n markdown: string;\n className?: string;\n /**\n * The [`target` attribute for `a` html\n * tags](https://developer.mozilla.org/en-US/docs/Web/HTML/Element/a#target). Defaults to not\n * adding a `target` to `a` tags\n */\n anchorTarget?: string;\n}\n\n/**\n * This component renders markdown content given a markdown string. It uses typography styles from\n * the platform.\n *\n * @param markdown The markdown string to render.\n * @param id Optional unique identifier\n * @returns A div containing the rendered markdown content.\n */\nexport default function MarkdownRenderer({\n id,\n markdown,\n className,\n anchorTarget,\n}: MarkdownRendererProps) {\n const options: MarkdownToJSX.Options = useMemo(\n () => ({\n overrides: {\n a: {\n props: {\n target: anchorTarget,\n },\n },\n },\n }),\n [anchorTarget],\n );\n return (\n
    \n {markdown}\n
    \n );\n}\n","import { Filter, ChevronDown } from 'lucide-react';\nimport { forwardRef } from 'react';\nimport { Button } from '@/components/shadcn-ui/button';\n\n/**\n * The FilterButton component is a button designed for initiating filtering of data. It is designed\n * to be used with the dropdown menu. It uses forwardRef to pass the button to the dropdown trigger\n * asChild.\n *\n * @returns A button that can be used to filter.\n */\nconst FilterButton = forwardRef((props, ref) => {\n return (\n \n \n Filter\n \n \n );\n});\n\nexport default FilterButton;\n","import {\n DropdownMenu,\n DropdownMenuTrigger,\n DropdownMenuContent,\n DropdownMenuLabel,\n DropdownMenuGroup,\n DropdownMenuCheckboxItem,\n DropdownMenuRadioItem,\n DropdownMenuSeparator,\n} from '@/components/shadcn-ui/dropdown-menu';\nimport FilterButton from './buttons/filter-button.component';\n\nexport enum DropdownMenuItemType {\n Check,\n Radio,\n}\n\nexport type DropdownItem = {\n /** The label is the text that will be displayed on the dropdown item. */\n label: string;\n /** The itemType determines the DropdownMenuItemType type as either Check or Radio. */\n itemType: DropdownMenuItemType;\n /** The onClick function is called when the item is clicked. */\n onClick: () => void;\n};\n\nexport type DropdownGroup = {\n /**\n * The label is the text that will be displayed on the dropdown group. It is used to categorize\n * the items in the group.\n */\n label: string;\n /** The items array contains the items that will be displayed in the dropdown group */\n items: DropdownItem[];\n};\n\nexport type FilterDropdownProps = {\n /** Object unique identifier */\n id?: string;\n /** The groups array contains the groups that will be displayed in the dropdown */\n groups: DropdownGroup[];\n}; // TODO: extend the props later\n\n/**\n * The FilterDropdown component is a dropdown designed for filtering content. It includes groups of\n * items that can be checkboxes or radio items.\n *\n * @param id Optional unique identifier\n * @param groups The groups array contains the groups that will be displayed in the dropdown\n * @returns A filter dropdown.\n */\nexport default function FilterDropdown({ id, groups }: FilterDropdownProps) {\n return (\n
    \n {/* TODO: remove this once the DropDown Menu shadcn has an id prop */}\n \n \n \n \n \n {groups.map((group) => (\n
    \n {group.label}\n \n {group.items.map((item) => (\n
    \n {item.itemType === DropdownMenuItemType.Check ? (\n \n {item.label}\n \n ) : (\n \n {item.label}\n \n )}\n
    \n ))}\n
    \n \n
    \n ))}\n
    \n
    \n
    \n );\n}\n","interface NoExtensionsFoundProps {\n /** Optional unique identifier */\n id?: string;\n /** The message to display */\n message: string;\n}\n/**\n * This component displays a message to the user when no extensions are found in the marketplace.\n *\n * @param id Optional unique identifier\n * @param message The message to display.\n * @returns {JSX.Element} - Returns the message component that displays the message to the user.\n */\nexport default function NoExtensionsFound({ id, message }: NoExtensionsFoundProps) {\n return (\n
    \n
    \n

    {message}

    \n
    \n
    \n );\n}\n","import { CircleHelp, Link as LucideLink, User } from 'lucide-react';\nimport { NumberFormat } from 'platform-bible-utils';\n\n/** Interface that stores the parameters passed to the More Info component */\ninterface MoreInfoProps {\n /** Optional unique identifier */\n id?: string;\n /** The category of the extension */\n category: string;\n /** The number of downloads for the extension */\n downloads: Record;\n /** The languages supported by the extension */\n languages: string[];\n /** The URL to the more info page of the extension */\n moreInfoUrl: string;\n}\n/**\n * This component displays the more info section of the extension which includes the category,\n * number of downloads, languages, and links to the website and support\n *\n * @param id Optional unique identifier\n * @param category The category of the extension\n * @param downloads The number of downloads for the extension\n * @param languages The languages supported by the extension\n * @param moreInfoUrl The URL to the more info page of the extension\n * @returns {JSX.Element} - Returns the more info component that displays the category, number of\n * downloads, languages, and links to the website and support\n */\nexport default function MoreInfo({\n id,\n category,\n downloads,\n languages,\n moreInfoUrl,\n}: MoreInfoProps) {\n /**\n * This constant formats the number of downloads into a more readable format.\n *\n * @example 1000 -> 1K\n *\n * @example 1000000 -> 1M\n *\n * @returns The formatted number of downloads\n */\n const numberFormatted = new NumberFormat('en', {\n notation: 'compact',\n compactDisplay: 'short',\n }).format(Object.values(downloads).reduce((a: number, b: number) => a + b, 0));\n\n /** This function scrolls the window to the bottom of the page. */\n const handleScrollToBottom = () => {\n window.scrollTo(0, document.body.scrollHeight);\n };\n\n return (\n \n
    \n
    \n {category}\n
    \n CATEGORY\n
    \n
    \n
    \n
    \n \n {numberFormatted}\n
    \n USERS\n
    \n
    \n
    \n
    \n {languages.slice(0, 3).map((locale) => (\n \n {locale.toUpperCase()}\n \n ))}\n
    \n {languages.length > 3 && (\n handleScrollToBottom()}\n className=\"tw-text-xs tw-text-gray-500 tw-underline\"\n >\n +{languages.length - 3} more languages\n \n )}\n
    \n
    \n
    \n \n Website\n \n \n \n Support\n \n \n
    \n
    \n );\n}\n","import { useState } from 'react';\n\nexport type VersionInformation = {\n /** Date the version was published */\n date: string;\n /** Description of the changes in the version */\n description: string;\n};\n\n/** Type to store the version history information */\nexport type VersionHistoryType = Record;\n\n/** Interface that stores the parameters passed to the Version History component */\ninterface VersionHistoryProps {\n /** Optional unique identifier */\n id?: string;\n /** Object containing the versions mapped with their information */\n versionHistory: VersionHistoryType;\n}\n\n/**\n * Component to render the version history information shown in the footer component. Lists the 5\n * most recent versions, with the options to show all versions by pressing a button.\n *\n * @param versionHistory Object containing the versions mapped with their information\n * @param id Optional unique identifier\n * @returns Rendered version history for the Footer component\n */\nexport default function VersionHistory({ id, versionHistory }: VersionHistoryProps) {\n const [showAllVersions, setShowAllVersions] = useState(false);\n const currentDate = new Date();\n\n /**\n * Function to format the time string for the version history in the form of 'X year(s) ago'.\n *\n * @param dateString ISO Date string to determine the time string from\n * @returns Formatted time string\n */\n function formatTimeString(dateString: string) {\n const date = new Date(dateString);\n const dateDiff = new Date(currentDate.getTime() - date.getTime());\n const yearDiff = dateDiff.getUTCFullYear() - 1970;\n const monthDiff = dateDiff.getUTCMonth();\n const dayDiff = dateDiff.getUTCDate() - 1;\n\n // Determines how long ago the version was published\n let timeString = '';\n if (yearDiff > 0) {\n timeString = `${yearDiff.toString()} year${yearDiff === 1 ? '' : 's'} ago`;\n } else if (monthDiff > 0) {\n timeString = `${monthDiff.toString()} month${monthDiff === 1 ? '' : 's'} ago`;\n } else if (dayDiff === 0) {\n timeString = 'today';\n } else {\n timeString = `${dayDiff.toString()} day${dayDiff === 1 ? '' : 's'} ago`;\n }\n\n return timeString;\n }\n\n // Sorts the version history by version number\n const sortedEntries = Object.entries(versionHistory).sort((a, b) => b[0].localeCompare(a[0]));\n\n return (\n
    \n

    What`s New

    \n
      \n {(showAllVersions ? sortedEntries : sortedEntries.slice(0, 5)).map((entry) => (\n
      \n
      \n
    • \n {entry[1].description}\n
    • \n
      \n
      \n
      Version {entry[0]}
      \n
      {formatTimeString(entry[1].date)}
      \n
      \n
      \n ))}\n
    \n {sortedEntries.length > 5 && (\n setShowAllVersions(!showAllVersions)}\n className=\"tw-text-xs tw-text-gray-500 tw-underline\"\n >\n {showAllVersions ? 'Show Less Version History' : 'Show All Version History'}\n \n )}\n
    \n );\n}\n","import { useMemo } from 'react';\nimport { formatBytes } from 'platform-bible-utils';\nimport VersionHistory, { VersionHistoryType } from './version-history.component';\n\n/** Interface to store the parameters passed to the Footer component */\ninterface FooterProps {\n /** Optional unique identifier */\n id?: string;\n /** Name of the publisher */\n publisherDisplayName: string;\n /** Size of the extension file in bytes */\n fileSize: number;\n /** List of language codes supported by the extension */\n locales: string[];\n /** Object containing the version history mapped with their information */\n versionHistory: VersionHistoryType;\n}\n\n/**\n * Component to render the footer for the extension details which contains information on the\n * publisher, version history, languages, and file size.\n *\n * @param id Optional unique identifier\n * @param publisherDisplayName Name of the publisher\n * @param fileSize Size of the extension file in bytes\n * @param locales List of language codes supported by the extension\n * @param versionHistory Object containing the version history mapped with their information\n * @returns The rendered Footer component\n */\nexport default function Footer({\n id,\n publisherDisplayName,\n fileSize,\n locales,\n versionHistory,\n}: FooterProps) {\n /** Formats the file size into a human-readable format */\n const formattedFileSize = useMemo(() => formatBytes(fileSize), [fileSize]);\n\n /**\n * This function gets the display names of the languages based on the language codes.\n *\n * @param codes The list of language codes\n * @returns The list of language names\n */\n const getLanguageNames = (codes: string[]) => {\n const displayNames = new Intl.DisplayNames(navigator.language, { type: 'language' });\n return codes.map((code) => displayNames.of(code));\n };\n\n const languageNames = getLanguageNames(locales);\n\n return (\n
    \n
    \n \n
    \n
    \n

    Information

    \n
    \n

    \n Publisher\n {publisherDisplayName}\n Size\n {formattedFileSize}\n

    \n
    \n

    \n Languages\n {languageNames.join(', ')}\n

    \n
    \n
    \n
    \n
    \n
    \n );\n}\n","import { PlatformEvent, PlatformEventHandler } from 'platform-bible-utils';\nimport { useEffect } from 'react';\n\n/**\n * Adds an event handler to an event so the event handler runs when the event is emitted. Use\n * `papi.network.getNetworkEvent` to use a networked event with this hook.\n *\n * @param event The event to subscribe to.\n *\n * - If event is a `PlatformEvent`, that event will be used\n * - If event is undefined, the callback will not be subscribed. Useful if the event is not yet\n * available for example\n *\n * @param eventHandler The callback to run when the event is emitted\n *\n * WARNING: MUST BE STABLE - const or wrapped in useCallback. The reference must not be updated\n * every render\n */\nconst useEvent = (\n event: PlatformEvent | undefined,\n eventHandler: PlatformEventHandler,\n) => {\n useEffect(() => {\n // Do nothing if the event is not provided (in case the event is not yet available, for example)\n if (!event) return () => {};\n\n const unsubscriber = event(eventHandler);\n return () => {\n unsubscriber();\n };\n }, [event, eventHandler]);\n};\nexport default useEvent;\n","import { useCallback, useEffect } from 'react';\nimport { PlatformEvent, PlatformEventAsync, PlatformEventHandler } from 'platform-bible-utils';\nimport usePromise from './use-promise.hook';\n\nconst noopUnsubscriber = () => false;\n\n/**\n * Adds an event handler to an asynchronously subscribing/unsubscribing event so the event handler\n * runs when the event is emitted. Use `papi.network.getNetworkEvent` to use a networked event with\n * this hook.\n *\n * @param event The asynchronously (un)subscribing event to subscribe to.\n *\n * - If event is a `PlatformEvent` or `PlatformEventAsync`, that event will be used\n * - If event is undefined, the callback will not be subscribed. Useful if the event is not yet\n * available for example\n *\n * @param eventHandler The callback to run when the event is emitted\n *\n * WARNING: MUST BE STABLE - const or wrapped in useCallback. The reference must not be updated\n * every render\n */\nconst useEventAsync = (\n event: PlatformEvent | PlatformEventAsync | undefined,\n eventHandler: PlatformEventHandler,\n) => {\n // Subscribe to the event asynchronously\n const [unsubscribe] = usePromise(\n useCallback(async () => {\n // Do nothing if the event is not provided (in case the event is not yet available, for example)\n if (!event) return noopUnsubscriber;\n\n // Wrap subscribe and unsubscribe in promises to allow normal events to be used as well\n const unsub = await Promise.resolve(event(eventHandler));\n return async () => unsub();\n }, [eventHandler, event]),\n noopUnsubscriber,\n // We want the unsubscriber to return to default value immediately upon changing subscription\n // So the useEffect below will unsubscribe asap\n { preserveValue: false },\n );\n\n // Unsubscribe from the event asynchronously (but we aren't awaiting the unsub)\n useEffect(() => {\n return () => {\n if (unsubscribe !== noopUnsubscriber) {\n unsubscribe();\n }\n };\n }, [unsubscribe]);\n};\n\nexport default useEventAsync;\n"],"names":["twMergeCustom","extendTailwindMerge","cn","inputs","clsx","Input","React","className","type","props","ref","jsx","BookChapterInput","forwardRef","handleSearch","handleKeyDown","handleOnClick","handleSubmit","jsxs","ShadInput","event","e","History","P","R","t","s","n","N","B","O","S","K","g","k","x","T","X","V","w","L","G","A","H","C","I","y","q","U","m","l","h","c","E","D","i","a","o","u","v","f","d","b","p","J","DropdownMenu","DropdownMenuPrimitive","DropdownMenuTrigger","DropdownMenuGroup","DropdownMenuPortal","DropdownMenuSub","DropdownMenuRadioGroup","DropdownMenuSubTrigger","inset","children","ChevronRight","DropdownMenuSubContent","DropdownMenuContent","sideOffset","DropdownMenuItem","DropdownMenuCheckboxItem","checked","Check","DropdownMenuRadioItem","Circle","DropdownMenuLabel","DropdownMenuSeparator","DropdownMenuShortcut","BookMenuItem","bookId","handleSelectBook","isSelected","handleHighlightBook","bookType","ShadDropdownMenuItem","Canon","ChapterSelect","handleSelectChapter","endChapter","activeChapter","highlightedChapter","handleHighlightedChapter","chapters","_","handleMouse","useCallback","chapterNumber","chapter","GoToMenuItem","handleSort","handleLocationHistory","handleBookmarks","ShadDropdownMenuLabel","ArrowDownWideNarrow","Clock","Bookmark","ALL_BOOK_IDS","BOOK_TYPE_LABELS","BOOK_TYPE_ARRAY","SCROLL_OFFSET","SEARCH_QUERY_FORMATS","fetchGroupedBooks","fetchEndChapter","getChaptersForBook","getAllEnglishNames","isValidBookEnglishName","bookName","getBookIdFromEnglishName","formattedBookName","BookChapterControl","scrRef","searchQuery","setSearchQuery","useState","selectedBookId","setSelectedBookId","setHighlightedChapter","highlightedBookId","setHighlightedBookId","isContentOpen","setIsContentOpen","isContentOpenDelayed","setIsContentOpenDelayed","inputRef","useRef","contentRef","menuItemRef","fetchFilteredBooks","englishNameLowerCase","normalizedQuery","handleSearchInput","searchString","shouldPreventAutoClosing","controlMenuState","open","updateReference","shouldClose","verse","handleInputSubmit","format","matches","book","englishName","handleKeyDownInput","handleKeyDownContent","key","handleKeyDownMenuItem","chapterOffSet","useEffect","useLayoutEffect","scrollTimeout","scrollPosition","ShadDropdownMenu","ShadDropdownMenuTrigger","ShadDropdownMenuContent","bookTypeIndex","element","ShadDropdownMenuSeparator","buttonVariants","cva","Button","variant","size","asChild","Comp","Slot","labelVariants","Label","LabelPrimitive","RadioGroup","RadioGroupPrimitive","RadioGroupItem","Popover","PopoverPrimitive","PopoverTrigger","PopoverContent","align","DialogPortal","DialogPrimitive","DialogOverlay","DialogContent","DialogTitle","DialogDescription","Command","CommandPrimitive","CommandInput","Search","CommandList","CommandEmpty","CommandGroup","CommandSeparator","CommandItem","getOptionLabelDefault","option","ComboBox","id","options","buttonClassName","popoverContentClassName","value","onChange","getOptionLabel","buttonPlaceholder","textPlaceholder","commandEmptyMessage","buttonVariant","dir","isDisabled","setOpen","ChevronsUpDown","ChapterRangeSelector","startChapter","handleSelectStartChapter","handleSelectEndChapter","chapterCount","chapterOptions","useMemo","index","onChangeStartChapter","onChangeEndChapter","Fragment","BookSelectionMode","BOOK_SELECTOR_STRING_KEYS","localizeString","strings","BookSelector","handleBookSelectionModeChange","currentBookName","onSelectBooks","selectedBookIds","localizedStrings","currentBookText","chooseText","chooseBooksText","bookSelectionMode","setBookSelectionMode","onSelectionModeChange","newMode","DataTableViewOptions","table","FilterIcon","column","Select","SelectPrimitive","SelectGroup","SelectValue","SelectTrigger","ChevronDown","SelectScrollUpButton","ChevronUp","SelectScrollDownButton","SelectContent","position","SelectLabel","SelectItem","SelectSeparator","DataTablePagination","pageSize","ArrowLeftIcon","ChevronLeftIcon","ChevronRightIcon","ArrowRightIcon","Table","stickyHeader","TableHeader","TableBody","TableFooter","TableRow","TableHead","TableCell","TableCaption","DataTable","columns","data","enablePagination","showPaginationControls","showColumnVisibilityControls","onRowClickHandler","sorting","setSorting","columnFilters","setColumnFilters","columnVisibility","setColumnVisibility","rowSelection","setRowSelection","useReactTable","getCoreRowModel","getPaginationRowModel","getSortedRowModel","getFilteredRowModel","headerGroup","header","flexRender","_a","row","cell","OccurrencesTable","occurrenceData","setScriptureReference","referenceHeaderText","occurrenceHeaderText","occurrences","uniqueOccurrences","occurrence","uniqueOccurrence","deepEqual","Checkbox","CheckboxPrimitive","getLinesFromUSFM","text","getNumberFromUSFM","regex","match","getBookNumFromId","getStatusForItem","item","approvedItems","unapprovedItems","toggleVariants","Toggle","TogglePrimitive","ToggleGroupContext","ToggleGroup","ToggleGroupPrimitive","ToggleGroupItem","context","getSortingIcon","sortDirection","ArrowUpIcon","ArrowDownIcon","ArrowUpDownIcon","inventoryItemColumn","itemLabel","inventoryAdditionalItemColumn","additionalItemLabel","additionalItemIndex","inventoryCountColumn","countLabel","statusChangeHandler","changedItems","newStatus","onApprovedItemsChange","onUnapprovedItemsChange","newApprovedItems","validItem","newUnapprovedItems","unapprovedItem","inventoryStatusColumn","statusLabel","status","CircleCheckIcon","CircleXIcon","CircleHelpIcon","INVENTORY_STRING_KEYS","filterItemData","itemData","statusFilter","textFilter","filteredItemData","createTableData","scriptureRef","itemRegex","tableData","currentBook","currentChapter","currentVerse","line","items","itemIndex","existingItem","tableEntry","newReference","substring","newItem","Inventory","scriptureReference","extractItems","additionalItemsLabels","scope","onScopeChange","allItemsText","approvedItemsText","unapprovedItemsText","unknownItemsText","scopeBookText","scopeChapterText","scopeVerseText","filterText","showAdditionalItemsText","showAdditionalItems","setShowAdditionalItems","setStatusFilter","setTextFilter","selectedItem","setSelectedItem","reducedTableData","newTableData","firstItem","existingEntry","newTableEntry","filteredTableData","allColumns","numberOfAdditionalItems","additionalColumns","_b","rowClickHandler","newSelection","handleScopeChange","handleStatusFilterChange","SearchBar","onSearch","placeholder","isFullWidth","handleInputChange","VerticalTabs","TabsPrimitive","VerticalTabsList","VerticalTabsTrigger","VerticalTabsContent","TabNavigationContentSearch","tabList","searchPlaceholder","headerTitle","isSearchBarFullWidth","direction","tab","Separator","orientation","decorative","SeparatorPrimitive","Skeleton","TooltipProvider","TooltipPrimitive","Tooltip","TooltipTrigger","TooltipContent","SIDEBAR_WIDTH","SIDEBAR_WIDTH_ICON","SIDEBAR_KEYBOARD_SHORTCUT","SidebarContext","useSidebar","SidebarProvider","defaultOpen","openProp","setOpenProp","style","_open","_setOpen","isOpen","openState","toggleSidebar","state","contextValue","Sidebar","side","collapsible","SidebarTrigger","onClick","PanelLeft","SidebarRail","SidebarInset","SidebarInput","SidebarHeader","SidebarFooter","SidebarSeparator","SidebarContent","SidebarGroup","SidebarGroupLabel","SidebarGroupAction","SidebarGroupContent","SidebarMenu","SidebarMenuItem","sidebarMenuButtonVariants","SidebarMenuButton","isActive","tooltip","button","SidebarMenuAction","showOnHover","SidebarMenuBadge","SidebarMenuSkeleton","showIcon","width","SidebarMenuSub","SidebarMenuSubItem","SidebarMenuSubButton","SettingsSidebar","extensionLabels","projectOptions","handleSelectSidebarItem","selectedSidebarItem","extensionsSidebarGroupLabel","projectsSidebarGroupLabel","buttonPlaceholderText","handleSelectItem","projectId","getProjectNameFromProjectId","project","getIsActive","label","selectedProjectName","SettingsSidebarContentSearch","scrBookColId","scrRefColId","typeColId","detailsColId","defaultScrRefColumnName","defaultScrBookGroupName","defaultTypeColumnName","defaultDetailsColumnName","getColumns","colInfo","showSourceColumn","showSrcCol","info","formatScrRef","compareScrRefs","toRefOrRange","scriptureSelection","offsetStart","offsetEnd","scrRefToBBBCCCVVV","getRowKey","ScriptureResultsViewer","sources","showColumnHeaders","scriptureReferenceColumnName","scriptureBookGroupName","typeColumnName","detailsColumnName","onRowSelected","grouping","setGrouping","scriptureResults","source","getExpandedRowModel","getGroupedRowModel","selectedRows","keys","selectedRow","scrBookGroupName","typeGroupName","groupingOptions","handleSelectChange","selectedGrouping","handleRowClick","getEvenOrOddBandingStyle","getIndent","groupingState","rowIndex","ChevronLeft","DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS","getLocalizeKeyForScrollGroupId","ScrollGroupSelector","availableScrollGroupIds","scrollGroupId","onChangeScrollGroupId","localizedStringsDefaulted","localizedStringKey","localizedStringValue","newScrollGroupString","scrollGroupOptionId","SettingsList","SettingsListItem","primary","secondary","isLoading","loadingMessage","SettingsListHeader","includeSeparator","Checklist","listItems","selectedListItems","handleSelectListItem","createLabel","_interopRequireDefault","obj","module","chainPropTypes","propType1","propType2","args","_extends","target","isPlainObject","prototype","deepClone","output","deepmerge","r","z","reactIs_production_min","hasSymbol","REACT_ELEMENT_TYPE","REACT_PORTAL_TYPE","REACT_FRAGMENT_TYPE","REACT_STRICT_MODE_TYPE","REACT_PROFILER_TYPE","REACT_PROVIDER_TYPE","REACT_CONTEXT_TYPE","REACT_ASYNC_MODE_TYPE","REACT_CONCURRENT_MODE_TYPE","REACT_FORWARD_REF_TYPE","REACT_SUSPENSE_TYPE","REACT_SUSPENSE_LIST_TYPE","REACT_MEMO_TYPE","REACT_LAZY_TYPE","REACT_BLOCK_TYPE","REACT_FUNDAMENTAL_TYPE","REACT_RESPONDER_TYPE","REACT_SCOPE_TYPE","isValidElementType","typeOf","object","$$typeof","$$typeofType","AsyncMode","ConcurrentMode","ContextConsumer","ContextProvider","Element","ForwardRef","Lazy","Memo","Portal","Profiler","StrictMode","Suspense","hasWarnedAboutDeprecatedIsAsyncMode","isAsyncMode","isConcurrentMode","isContextConsumer","isContextProvider","isElement","isForwardRef","isFragment","isLazy","isMemo","isPortal","isProfiler","isStrictMode","isSuspense","reactIs_development","reactIsModule","require$$0","require$$1","getOwnPropertySymbols","hasOwnProperty","propIsEnumerable","toObject","val","shouldUseNative","test1","test2","order2","test3","letter","objectAssign","from","to","symbols","ReactPropTypesSecret","ReactPropTypesSecret_1","has","printWarning","loggedTypeFailures","message","checkPropTypes","typeSpecs","values","location","componentName","getStack","typeSpecName","error","err","ex","stack","checkPropTypes_1","ReactIs","assign","require$$2","require$$3","require$$4","emptyFunctionThatReturnsNull","factoryWithTypeCheckers","isValidElement","throwOnDirectAccess","ITERATOR_SYMBOL","FAUX_ITERATOR_SYMBOL","getIteratorFn","maybeIterable","iteratorFn","ANONYMOUS","ReactPropTypes","createPrimitiveTypeChecker","createAnyTypeChecker","createArrayOfTypeChecker","createElementTypeChecker","createElementTypeTypeChecker","createInstanceTypeChecker","createNodeChecker","createObjectOfTypeChecker","createEnumTypeChecker","createUnionTypeChecker","createShapeTypeChecker","createStrictShapeTypeChecker","is","PropTypeError","createChainableTypeChecker","validate","manualPropTypeCallCache","manualPropTypeWarningCount","checkType","isRequired","propName","propFullName","secret","cacheKey","chainedCheckType","expectedType","propValue","propType","getPropType","preciseType","getPreciseType","typeChecker","expectedClass","expectedClassName","actualClassName","getClassName","expectedValues","valuesString","arrayOfTypeCheckers","checker","getPostfixForTypeWarning","expectedTypes","checkerResult","expectedTypesMessage","isNode","invalidValidatorError","shapeTypes","allKeys","iterator","step","entry","isSymbol","emptyFunction","emptyFunctionWithReset","factoryWithThrowingShims","shim","getShim","propTypesModule","isClassComponent","elementType","acceptingRef","safePropName","warningHint","elementAcceptingRef","PropTypes","elementAcceptingRef$1","specialProperty","exactProp","propTypes","unsupportedProps","prop","formatMuiErrorMessage","code","url","REACT_SERVER_CONTEXT_TYPE","REACT_OFFSCREEN_TYPE","enableScopeAPI","enableCacheElement","enableTransitionTracing","enableLegacyHidden","enableDebugTracing","REACT_MODULE_REFERENCE","SuspenseList","hasWarnedAboutDeprecatedIsConcurrentMode","isSuspenseList","fnNameMatchRegex","getFunctionName","fn","getFunctionComponentName","Component","fallback","getWrappedName","outerType","innerType","wrapperName","functionName","getDisplayName","HTMLElementType","refType","refType$1","capitalize","string","_formatMuiErrorMessage","createChainedFunction","funcs","acc","func","debounce","wait","timeout","debounced","later","deprecatedPropType","validator","reason","componentNameSafe","propFullNameSafe","isMuiElement","muiNames","_muiName","_element$type","ownerDocument","node","ownerWindow","requirePropFactory","componentNameInError","prevPropTypes","requiredProp","defaultTypeChecker","typeCheckerResult","setRef","useEnhancedEffect","useEnhancedEffect$1","globalId","useGlobalId","idOverride","defaultId","setDefaultId","maybeReactUseId","useId","reactId","unsupportedProp","useControlled","controlled","defaultProp","name","isControlled","valueState","setValue","defaultValue","setValueIfUncontrolled","newValue","useEventCallback","useForkRef","refs","instance","UNINITIALIZED","useLazyRef","init","initArg","EMPTY","useOnMount","Timeout","delay","useTimeout","hadKeyboardEvent","hadFocusVisibleRecently","hadFocusVisibleRecentlyTimeout","inputTypesWhitelist","focusTriggersKeyboardModality","tagName","handlePointerDown","handleVisibilityChange","prepare","doc","isFocusVisible","useIsFocusVisible","isFocusVisibleRef","handleBlurVisible","handleFocusVisible","resolveProps","defaultProps","defaultSlotProps","slotProps","slotPropName","composeClasses","slots","getUtilityClass","classes","slot","utilityClass","defaultGenerator","createClassNameGenerator","generate","generator","ClassNameGenerator","ClassNameGenerator$1","globalStateClasses","generateUtilityClass","globalStatePrefix","globalStateClass","generateUtilityClasses","result","clamp","min","max","_objectWithoutPropertiesLoose","excluded","sourceKeys","_excluded","sortBreakpointsValues","breakpointsAsArray","breakpoint1","breakpoint2","createBreakpoints","breakpoints","unit","other","sortedValues","up","down","between","start","end","endIndex","only","not","keyIndex","shape","shape$1","responsivePropType","responsivePropType$1","merge","defaultBreakpoints","handleBreakpoints","styleFromPropValue","theme","themeBreakpoints","breakpoint","mediaKey","cssKey","createEmptyBreakpointObject","breakpointsInput","_breakpointsInput$key","breakpointStyleKey","removeUnusedBreakpoints","breakpointKeys","breakpointOutput","getPath","path","checkVars","getStyleValue","themeMapping","transform","propValueFinal","userValue","cssProperty","themeKey","memoize","cache","arg","properties","directions","aliases","getCssProperties","property","marginKeys","paddingKeys","spacingKeys","createUnaryUnit","_getPath","themeSpacing","abs","createUnarySpacing","getValue","transformer","transformed","getStyleFromPropValue","cssProperties","resolveCssProperty","margin","padding","createSpacing","spacingInput","spacing","argsInput","argument","compose","styles","handlers","borderTransform","createBorderStyle","border","borderTop","borderRight","borderBottom","borderLeft","borderColor","borderTopColor","borderRightColor","borderBottomColor","borderLeftColor","outline","outlineColor","borderRadius","gap","columnGap","rowGap","gridColumn","gridRow","gridAutoFlow","gridAutoColumns","gridAutoRows","gridTemplateColumns","gridTemplateRows","gridTemplateAreas","gridArea","paletteTransform","color","bgcolor","backgroundColor","sizingTransform","maxWidth","_props$theme","_props$theme2","breakpointsValues","minWidth","height","maxHeight","minHeight","boxSizing","defaultSxConfig","defaultSxConfig$1","objectsHaveSameKeys","objects","union","callIfFn","maybeFn","unstable_createStyleFunctionSx","getThemeValue","config","styleFunctionSx","_theme$unstable_sxCon","sx","traverse","sxInput","sxObject","emptyBreakpoints","breakpointsKeys","css","styleKey","styleFunctionSx$1","applyStyles","createTheme","paletteInput","shapeInput","muiTheme","isObjectEmpty","useTheme","defaultTheme","contextTheme","ThemeContext","systemDefaultTheme","useThemeWithoutDefault","_excluded2","_excluded3","isEmpty","isStringTag","tag","shouldForwardProp","lowercaseFirstLetter","resolveTheme","themeId","defaultOverridesResolver","processStyleArg","callableStyle","_ref","ownerState","resolvedStylesArg","resolvedStyle","variants","isMatch","createStyled","input","rootShouldForwardProp","slotShouldForwardProp","systemSx","inputOptions","processStyles","componentSlot","inputSkipVariantsResolver","inputSkipSx","overridesResolver","skipVariantsResolver","skipSx","shouldForwardPropOption","defaultStyledResolver","styledEngineStyled","transformStyleArg","stylesArg","muiStyledResolver","styleArg","expressions","transformedStyleArg","expressionsWithDefaultTheme","styleOverrides","resolvedStyleOverrides","slotKey","slotStyle","_theme$components","themeVariants","numOfCustomFnsApplied","placeholders","displayName","getThemeProps","params","useThemeProps","clampWrapper","hexToRgb","re","colors","decomposeColor","marker","colorSpace","recomposeColor","hslToRgb","rgb","getLuminance","getContrastRatio","foreground","background","lumA","lumB","alpha","darken","coefficient","lighten","createMixins","mixins","common","common$1","grey","grey$1","purple","purple$1","red","red$1","orange","orange$1","blue","blue$1","lightBlue","lightBlue$1","green","green$1","light","dark","addLightOrDark","intent","shade","tonalOffset","tonalOffsetLight","tonalOffsetDark","getDefaultPrimary","mode","getDefaultSecondary","getDefaultError","getDefaultInfo","getDefaultSuccess","getDefaultWarning","createPalette","palette","contrastThreshold","success","warning","getContrastText","contrastText","contrast","augmentColor","mainShade","lightShade","darkShade","modes","round","caseAllCaps","defaultFontFamily","createTypography","typography","fontFamily","fontSize","fontWeightLight","fontWeightRegular","fontWeightMedium","fontWeightBold","htmlFontSize","allVariants","pxToRem2","coef","pxToRem","buildVariant","fontWeight","lineHeight","letterSpacing","casing","shadowKeyUmbraOpacity","shadowKeyPenumbraOpacity","shadowAmbientShadowOpacity","createShadow","px","shadows","shadows$1","easing","duration","formatMs","milliseconds","getAutoHeightDuration","constant","createTransitions","inputTransitions","mergedEasing","mergedDuration","durationOption","easingOption","isString","isNumber","animatedProp","zIndex","zIndex$1","mixinsInput","transitionsInput","typographyInput","systemTheme","systemCreateTheme","stateClasses","component","child","stateClass","defaultTheme$1","THEME_ID","systemUseThemeProps","styled","styled$1","getSvgIconUtilityClass","useUtilityClasses","SvgIconRoot","_theme$transitions","_theme$transitions$cr","_theme$transitions2","_theme$typography","_theme$typography$pxT","_theme$typography2","_theme$typography2$px","_theme$typography3","_theme$typography3$px","_palette$ownerState$c","_palette","_palette2","_palette3","SvgIcon","inProps","htmlColor","inheritViewBox","titleAccess","viewBox","hasSvgAsChild","more","_jsxs","_jsx","SvgIcon$1","createSvgIcon","unstable_ClassNameGenerator","exports","_utils","ArrowRight","default_1","_createSvgIcon","_jsxRuntime","isHostComponent","appendOwnerState","otherProps","defaultContextValue","ClassNameConfiguratorContext","useClassNamesOverride","disableDefaultClasses","extractEventHandlers","excludeKeys","resolveComponentProps","componentProps","slotState","omitEventHandlers","mergeSlotProps","parameters","getSlotProps","additionalProps","externalSlotProps","externalForwardedProps","joinedClasses","mergedStyle","eventHandlers","componentsPropsWithoutEventHandlers","otherPropsWithoutEventHandlers","internalSlotProps","useSlotProps","_parameters$additiona","skipResolvingSlotProps","rest","resolvedComponentsProps","mergedProps","internalRef","GLOBAL_CLASS_PREFIX","buildStateClass","buildSlotClass","getContainer","container","forwardedRef","disablePortal","mountNode","setMountNode","handleRef","newProps","ReactDOM","top","bottom","right","left","auto","basePlacements","clippingParents","viewport","popper","reference","variationPlacements","placement","placements","beforeRead","read","afterRead","beforeMain","main","afterMain","beforeWrite","write","afterWrite","modifierPhases","getNodeName","getWindow","OwnElement","isHTMLElement","isShadowRoot","attributes","effect","_ref2","initialStyles","styleProperties","attribute","applyStyles$1","getBasePlacement","getUAString","uaData","isLayoutViewport","getBoundingClientRect","includeScale","isFixedStrategy","clientRect","scaleX","scaleY","visualViewport","addVisualOffsets","getLayoutRect","contains","parent","rootNode","next","getComputedStyle","isTableElement","getDocumentElement","getParentNode","getTrueOffsetParent","getContainingBlock","isFirefox","isIE","elementCss","currentNode","getOffsetParent","window","offsetParent","getMainAxisFromPlacement","within","mathMax","mathMin","withinMaxClamp","getFreshSideObject","mergePaddingObject","paddingObject","expandToHashMap","hashMap","toPaddingObject","arrow","_state$modifiersData$","arrowElement","popperOffsets","basePlacement","axis","isVertical","len","arrowRect","minProp","maxProp","endDiff","startDiff","arrowOffsetParent","clientSize","centerToReference","center","offset","axisProp","_options$element","arrow$1","getVariation","unsetSides","roundOffsetsByDPR","win","dpr","mapToStyles","_Object$assign2","popperRect","variation","offsets","gpuAcceleration","adaptive","roundOffsets","isFixed","_offsets$x","_offsets$y","_ref3","hasX","hasY","sideX","sideY","heightProp","widthProp","offsetY","offsetX","commonStyles","_ref4","_Object$assign","computeStyles","_ref5","_options$gpuAccelerat","_options$adaptive","_options$roundOffsets","computeStyles$1","passive","_options$scroll","scroll","_options$resize","resize","scrollParents","scrollParent","eventListeners","hash","getOppositePlacement","matched","getOppositeVariationPlacement","getWindowScroll","scrollLeft","scrollTop","getWindowScrollBarX","getViewportRect","strategy","html","layoutViewport","getDocumentRect","_element$ownerDocumen","winScroll","body","isScrollParent","_getComputedStyle","overflow","overflowX","overflowY","getScrollParent","listScrollParents","list","isBody","updatedList","rectToClientRect","rect","getInnerBoundingClientRect","getClientRectFromMixedType","clippingParent","getClippingParents","canEscapeClipping","clipperElement","getClippingRect","boundary","rootBoundary","mainClippingParents","firstClippingParent","clippingRect","accRect","computeOffsets","commonX","commonY","mainAxis","detectOverflow","_options","_options$placement","_options$strategy","_options$boundary","_options$rootBoundary","_options$elementConte","elementContext","_options$altBoundary","altBoundary","_options$padding","altContext","clippingClientRect","referenceClientRect","popperClientRect","elementClientRect","overflowOffsets","offsetData","multiply","computeAutoPlacement","flipVariations","_options$allowedAutoP","allowedAutoPlacements","allPlacements","allowedPlacements","overflows","getExpandedFallbackPlacements","oppositePlacement","flip","_options$mainAxis","checkMainAxis","_options$altAxis","checkAltAxis","specifiedFallbackPlacements","_options$flipVariatio","preferredPlacement","isBasePlacement","fallbackPlacements","referenceRect","checksMap","makeFallbackChecks","firstFittingPlacement","_basePlacement","isStartVariation","mainVariationSide","altVariationSide","checks","check","numberOfChecks","_loop","_i","fittingPlacement","_ret","flip$1","getSideOffsets","preventedOffsets","isAnySideFullyClipped","hide","referenceOverflow","popperAltOverflow","referenceClippingOffsets","popperEscapeOffsets","isReferenceHidden","hasPopperEscaped","hide$1","distanceAndSkiddingToXY","rects","invertDistance","skidding","distance","_options$offset","_data$state$placement","offset$1","popperOffsets$1","getAltAxis","preventOverflow","_options$tether","tether","_options$tetherOffset","tetherOffset","altAxis","tetherOffsetValue","normalizedTetherOffsetValue","offsetModifierState","_offsetModifierState$","mainSide","altSide","additive","minLen","maxLen","arrowPaddingObject","arrowPaddingMin","arrowPaddingMax","arrowLen","minOffset","maxOffset","clientOffset","offsetModifierValue","tetherMin","tetherMax","preventedOffset","_offsetModifierState$2","_mainSide","_altSide","_offset","_len","_min","_max","isOriginSide","_offsetModifierValue","_tetherMin","_tetherMax","_preventedOffset","preventOverflow$1","getHTMLElementScroll","getNodeScroll","isElementScaled","getCompositeRect","elementOrVirtualElement","isOffsetParentAnElement","offsetParentIsScaled","documentElement","order","modifiers","map","visited","modifier","sort","requires","dep","depModifier","orderModifiers","orderedModifiers","phase","pending","resolve","mergeByName","merged","current","existing","DEFAULT_OPTIONS","areValidElements","_key","popperGenerator","generatorOptions","_generatorOptions","_generatorOptions$def","defaultModifiers","_generatorOptions$def2","defaultOptions","effectCleanupFns","isDestroyed","setOptionsAction","cleanupModifierEffects","runModifierEffects","_state$elements","_state$orderedModifie","_state$orderedModifie2","_ref$options","cleanupFn","noopFn","createPopper","COMPONENT_NAME","getPopperUtilityClass","flipPlacement","resolveAnchorEl","anchorEl","isVirtualElement","defaultPopperOptions","PopperTooltip","_slots$root","initialPlacement","popperOptions","popperRefProp","TransitionProps","tooltipRef","ownRef","popperRef","handlePopperRef","handlePopperRefRef","rtlPlacement","setPlacement","resolvedAnchorElement","setResolvedAnchorElement","handlePopperUpdate","box","popperModifiers","childProps","Root","rootProps","Popper","containerProp","keepMounted","transition","exited","setExited","handleEnter","handleExited","resolvedAnchorEl","display","transitionProps","useThemeSystem","_setPrototypeOf","_inheritsLoose","subClass","superClass","setPrototypeOf","timeoutsShape","TransitionGroupContext","forceReflow","UNMOUNTED","EXITED","ENTERING","ENTERED","EXITING","Transition","_React$Component","_this","parentGroup","appear","initialStatus","prevState","nextIn","_proto","prevProps","nextStatus","exit","enter","mounting","_this2","appearing","maybeNode","maybeAppearing","timeouts","enterTimeout","_this3","nextState","callback","_this4","active","handler","doesNotHaveTimeoutOrListener","maybeNextCallback","_this$props","pt","noop","Transition$1","reflow","getTransitionProps","_style$transitionDura","_style$transitionTimi","getScale","isWebKit154","Grow","addEndListener","inProp","onEnter","onEntered","onEntering","onExit","onExited","onExiting","TransitionComponent","timer","autoTimeout","nodeRef","normalizedTransitionCallback","maybeIsAppearing","handleEntering","isAppearing","transitionDuration","transitionTimingFunction","handleEntered","handleExiting","handleExit","handleAddEndListener","Grow$1","PopperRoot","BasePopper","components","componentsProps","RootComponent","Popper$1","getTooltipUtilityClass","tooltipClasses","tooltipClasses$1","disableInteractive","touch","TooltipPopper","TooltipTooltip","TooltipArrow","hystersisOpen","hystersisTimer","cursorPosition","composeEventHandler","eventHandler","_slots$popper","_slots$transition","_slots$tooltip","_slots$arrow","_slotProps$popper","_ref6","_slotProps$popper2","_slotProps$transition","_slotProps$tooltip","_ref7","_slotProps$tooltip2","_slotProps$arrow","_ref8","_slotProps$arrow2","childrenProp","describeChild","disableFocusListener","disableHoverListener","disableInteractiveProp","disableTouchListener","enterDelay","enterNextDelay","enterTouchDelay","followCursor","idProp","leaveDelay","leaveTouchDelay","onClose","onOpen","PopperComponentProp","PopperProps","title","TransitionComponentProp","isRtl","childNode","setChildNode","arrowRef","setArrowRef","ignoreNonTouchEvents","closeTimer","enterTimer","leaveTimer","touchTimer","setOpenState","prevUserSelect","stopTouchInteraction","handleOpen","handleClose","handleLeave","focusVisibleRef","setChildIsFocusVisible","handleBlur","handleFocus","detectTouchStart","childrenProps","handleMouseOver","handleMouseLeave","handleTouchStart","handleTouchEnd","nativeEvent","handleMouseMove","nameOrDescProps","titleIsString","interactiveWrapperListeners","_PopperProps$popperOp","tooltipModifiers","PopperComponent","TooltipComponent","ArrowComponent","popperProps","tooltipProps","tooltipArrowProps","TransitionPropsInner","Tooltip$1","getIcon","icon","menuLabel","leading","MuiListItemIcon","MenuItem","allowForLeadingIcons","iconPathBefore","iconPathAfter","hasAutoFocus","isDense","isSubMenuParent","hasDisabledGutters","hasDivider","focusVisibleClassName","menuItem","MuiMenuItem","MuiListItemText","getAllGroups","menuDefinition","SubMenu","setAnchorEl","parentMenuItem","parentItemProps","handleParentMenuItemClick","renderSubMenuItems","includedGroups","group","GroupedMenuItemList","Menu","getOrderedGroupItems","groupId","allItems","menuProps","commandHandler","groupsToInclude","sortedGroups","itemArray","allowSpaceForLeadingIcons","createMenuItemProps","isLastItemInGroup","divKey","itemInfo","menuItemProps","TopLevelMenu","columnId","MenuColumn","metadata","Grid","List","GridMenu","multiColumnMenu","sortedColumns","columnNumbers","columnName","col","getUsePromiseOptionsDefaults","usePromise","promiseFactoryCallback","defaultValueRef","optionsDefaultedRef","setIsLoading","promiseIsCurrent","MenuIcon","HamburgerMenuButton","menuProvider","normalMenu","fullMenu","containerRef","ariaLabelPrefix","isMenuOpen","setMenuOpen","showFullMenu","setShowFullMenu","handleMenuItemClick","handleMenuButtonClick","prevIsOpen","isOpening","menuCommandHandler","command","setOffset","normalMenuData","fullMenuData","menu","IconButton","Drawer","isTooltipSuppressed","adjustMarginToAlignToEdge","MuiIconButton","Spinner","LoaderCircle","TextField","hasError","helperText","onFocus","onBlur","ShadLabel","Toolbar","AppBar","MuiToolbar","alertVariants","Alert","AlertTitle","AlertDescription","Card","CardHeader","CardTitle","CardDescription","CardContent","CardFooter","Sonner","Toaster","Slider","SliderPrimitive","Switch","SwitchPrimitives","Tabs","TabsList","TabsTrigger","TabsContent","InstallButton","isInstalling","handleClick","buttonText","Download","EnableButton","isEnabling","DisableButton","isDisabling","UpdateButton","isUpdating","MarkdownRenderer","markdown","anchorTarget","Markdown","FilterButton","Filter","DropdownMenuItemType","DropdownMenuItemType2","FilterDropdown","groups","NoExtensionsFound","MoreInfo","category","downloads","languages","moreInfoUrl","numberFormatted","NumberFormat","handleScrollToBottom","User","locale","LucideLink","CircleHelp","VersionHistory","versionHistory","showAllVersions","setShowAllVersions","currentDate","formatTimeString","dateString","date","dateDiff","yearDiff","monthDiff","dayDiff","timeString","sortedEntries","Footer","publisherDisplayName","fileSize","locales","formattedFileSize","formatBytes","languageNames","codes","displayNames","useEvent","unsubscriber","noopUnsubscriber","useEventAsync","unsubscribe","unsub"],"mappings":"48CAGA,MAAMA,GAAgBC,GAAAA,oBAAoB,CAAE,OAAQ,KAAO,CAAA,EAyDpD,SAASC,KAAMC,EAAsB,CACnC,OAAAH,GAAcI,GAAAA,KAAKD,CAAM,CAAC,CACnC,CCzDO,MAAME,GAAQC,EAAM,WACzB,CAAC,CAAE,UAAAC,EAAW,KAAAC,EAAM,GAAGC,CAAA,EAASC,IAE5BC,EAAA,IAAC,QAAA,CACC,KAAAH,EACA,UAAWN,EACT,sbACAK,CACF,EACA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,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MAEA,MAEA,MAEA,MAEA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,MAEA,MAEA,MAEA,MAEA,MACA,MACA,MACA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,KACF,EAAGC,GAAI,CACL,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,KACF,EAAGC,GAAI,CACL,UACA,SACA,YACA,UACA,cACA,SACA,SACA,OACA,WACA,WACA,UACA,UACA,eACA,eACA,OACA,WACA,kBACA,MACA,SACA,WACA,eACA,gBACA,SACA,WACA,eACA,UACA,kBACA,QACA,OACA,OACA,UACA,QACA,QACA,QACA,WACA,YACA,SACA,YACA,UACA,UACA,OACA,OACA,OACA,OACA,SACA,gBACA,gBACA,YACA,YACA,cACA,aACA,kBACA,kBACA,YACA,YACA,QACA,WACA,UACA,QACA,UACA,UACA,SACA,SACA,SACA,OACA,aACA,QACA,SACA,eACA,oBACA,0BACA,SACA,qBACA,sBACA,UACA,qBACA,cACA,cACA,cACA,cACA,mBACA,mBACA,qBACA,YACA,OACA,oBAGA,uBACA,uBACA,sBACA,yBACA,wBACA,qBACA,UACA,UACA,UACA,UACA,UACA,UACA,UACA,eACA,cACA,eACA,oBACA,qBACA,0BACA,0BACA,eACA,eACA,YACA,gBACA,cACA,eACA,iBACA,wBACA,mBACA,WACA,QACA,aACA,aACA,aACA,2BACA,4BACA,YACF,EAAGC,GAAIC,KACP,SAASC,GAAER,EAAGJ,EAAI,GAAI,CACpB,OAAOA,IAAMI,EAAIA,EAAE,YAAa,GAAGA,KAAKM,GAAIA,GAAEN,CAAC,EAAI,CACrD,CACA,SAASS,GAAET,EAAG,CACZ,OAAOQ,GAAER,CAAC,EAAI,CAChB,CACA,SAASU,GAAEV,E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ACf,SAAU,UACV,UAAWA,EACZ,EAED,EAAG,CACD,MAAOpC,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,QAAS,CACP,MAAOA,EACR,EACD,WAAY,CACV,MAAOA,EACR,EACD,aAAc,CACZ,MAAOA,EACR,EACD,cAAe,CACb,MAAOA,EACR,EACD,YAAa,CACX,MAAOA,EACR,EACD,SAAU,CACR,MAAOA,EACR,EACD,SAAU,CACR,MAAOA,EACR,EACD,cAAe,CACb,MAAOA,EACR,EACD,mBAAoB,CAClB,MAAOA,EACR,EACD,iBAAkB,CAChB,MAAOA,EACR,EACD,aAAc,CACZ,MAAOA,EACR,EACD,kBAAmB,CACjB,MAAOA,EACR,EACD,gBAAiB,CACf,MAAOA,EACR,EACD,EAAG,CACD,MAAOD,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,OAAQ,CACN,MAAOA,EACR,EACD,UAAW,CACT,MAAOA,EACR,EACD,YAAa,CACX,MAAOA,EACR,EACD,aAAc,CACZ,MAAOA,EACR,EACD,WAAY,CACV,MAAOA,EACR,EACD,QAAS,CACP,MAAOA,EACR,EACD,QAAS,CACP,MAAOA,EACR,EACD,aAAc,CACZ,MAAOA,EACR,EACD,kBAAmB,CACjB,MAAOA,EACR,EACD,gBAAiB,CACf,MAAOA,EACR,EACD,YAAa,CACX,MAAOA,EACR,EACD,iBAAkB,CAChB,MAAOA,EACR,EACD,eAAgB,CACd,MAAOA,EACR,EAED,aAAc,CACZ,YAAa,GACb,UAAWzwB,IAAU,CACnB,eAAgB,CACd,QAASA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GCJTE,GAAO,CACX,GAAI,UACJ,IAAK,UACL,IAAK,UACL,IAAK,UACL,IAAK,UACL,IAAK,UACL,IAAK,UACL,IAAK,UACL,IAAK,UACL,IAAK,UACL,KAAM,UACN,KAAM,UACN,KAAM,UACN,KAAM,SACR,EACAC,GAAeD,GChBTE,GAAS,CACb,GAAI,UACJ,IAAK,UACL,IAAK,UACL,IAAK,UACL,IAAK,UACL,IAAK,UACL,IAAK,UACL,IAAK,UACL,IAAK,UACL,IAAK,UACL,KAAM,UACN,KAAM,UACN,KAAM,UACN,KAAM,SACR,EACAC,GAAeD,GChBTE,GAAM,CACV,GAAI,UACJ,IAAK,UACL,IAAK,UACL,IAAK,UACL,IAAK,UACL,IAAK,UACL,IAAK,UACL,IAAK,UACL,IAAK,UACL,IAAK,UACL,KAAM,UACN,KAAM,UACN,KAAM,UACN,KAAM,SACR,EACAC,GAAeD,GChBTE,GAAS,CACb,GAAI,UACJ,IAAK,UACL,IAAK,UACL,IAAK,UACL,IAAK,UACL,IAAK,UACL,IAAK,UACL,IAAK,UACL,IAAK,UACL,IAAK,UACL,KAAM,UACN,KAAM,UACN,KAAM,UACN,KAAM,SACR,EACAC,GAAeD,GChBTE,GAAO,CACX,GAAI,UACJ,IAAK,UACL,IAAK,UACL,IAAK,UACL,IAAK,UACL,IAAK,UACL,IAAK,UACL,IAAK,UACL,IAAK,UACL,IAAK,UACL,KAAM,UACN,KAAM,UACN,KAAM,UACN,KAAM,SACR,EACAC,GAAeD,GChBTE,GAAY,CAChB,GAAI,UACJ,IAAK,UACL,IAAK,UACL,IAAK,UACL,IAAK,UACL,IAAK,UACL,IAAK,UACL,IAAK,UACL,IAAK,UACL,IAAK,UACL,KAAM,UACN,KAAM,UACN,KAAM,UACN,KAAM,SACR,EACAC,GAAeD,GChBTE,GAAQ,CACZ,GAAI,UACJ,IAAK,UACL,IAAK,UACL,IAAK,UACL,IAAK,UACL,IAAK,UACL,IAAK,UACL,IAAK,UACL,IAAK,UACL,IAAK,U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;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","x_google_ignoreList":[3,43,44,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,83,84,85,86,87,88,89,90,91,92,93,94,95,96,97,98,99,100,101,102,103,104,105,106,107,108,109,110,111,112,113,114,115,116,117,118,119,120,121,122,123,124,125,126,127,128,129,130,131,132,133,134,135,136,137,138,139,140,141,142,143,144,145,146,147,148,149,150,151,152,153,154,155,156,157,158,159,160,161,162,163,164,165,166,167,168,169,170,171,172,173,174,175,176,177,178,179,180,181,182,183,184,185,186,187,188,189,190,191,192,193,194,195,196,197,198,199,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,226]} \ No newline at end of file +{"version":3,"file":"index.cjs","sources":["../src/utils/shadcn-ui.util.ts","../src/components/shadcn-ui/input.tsx","../src/components/advanced/book-chapter-control/book-chapter-input.component.tsx","../../../node_modules/@sillsdev/scripture/dist/index.es.js","../src/components/shadcn-ui/dropdown-menu.tsx","../src/components/advanced/book-chapter-control/book-menu-item.component.tsx","../src/components/advanced/book-chapter-control/chapter-select.component.tsx","../src/components/advanced/book-chapter-control/go-to-menu-item.component.tsx","../src/components/advanced/book-chapter-control/book-chapter-control.component.tsx","../src/components/shadcn-ui/button.tsx","../src/components/shadcn-ui/label.tsx","../src/components/shadcn-ui/radio-group.tsx","../src/components/shadcn-ui/popover.tsx","../src/components/shadcn-ui/dialog.tsx","../src/components/shadcn-ui/command.tsx","../src/components/basics/combo-box.component.tsx","../src/components/basics/chapter-range-selector.component.tsx","../src/components/advanced/book-selector.component.tsx","../src/components/advanced/data-table/data-table-column-toggle.component.tsx","../src/components/shadcn-ui/select.tsx","../src/components/advanced/data-table/data-table-pagination.component.tsx","../src/components/shadcn-ui/table.tsx","../src/components/advanced/data-table/data-table.component.tsx","../src/components/advanced/inventory/occurrences-table.component.tsx","../src/components/shadcn-ui/checkbox.tsx","../src/components/advanced/inventory/inventory-utils.ts","../src/components/shadcn-ui/toggle.tsx","../src/components/shadcn-ui/toggle-group.tsx","../src/components/advanced/inventory/inventory-columns.tsx","../src/components/advanced/inventory/inventory.component.tsx","../src/components/basics/search-bar.component.tsx","../src/components/basics/tabs-vertical.tsx","../src/components/advanced/tab-navigation-content-search.component.tsx","../src/components/shadcn-ui/separator.tsx","../src/components/shadcn-ui/skeleton.tsx","../src/components/shadcn-ui/tooltip.tsx","../src/components/shadcn-ui/sidebar.tsx","../src/components/advanced/settings-components/settings-sidebar.component.tsx","../src/components/advanced/settings-components/settings-sidebar-content-search.component.tsx","../src/components/advanced/scripture-results-viewer/scripture-results-viewer.component.tsx","../src/components/advanced/scroll-group-selector.component.tsx","../src/components/advanced/settings-components/settings-list.component.tsx","../src/components/basics/checklist.component.tsx","../../../node_modules/@babel/runtime/helpers/interopRequireDefault.js","../../../node_modules/@mui/utils/chainPropTypes/chainPropTypes.js","../../../node_modules/@babel/runtime/helpers/esm/extends.js","../../../node_modules/@mui/utils/deepmerge/deepmerge.js","../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.production.min.js","../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.development.js","../../../node_modules/prop-types/node_modules/react-is/index.js","../../../node_modules/object-assign/index.js","../../../node_modules/prop-types/lib/ReactPropTypesSecret.js","../../../node_modules/prop-types/lib/has.js","../../../node_modules/prop-types/checkPropTypes.js","../../../node_modules/prop-types/factoryWithTypeCheckers.js","../../../node_modules/prop-types/factoryWithThrowingShims.js","../../../node_modules/prop-types/index.js","../../../node_modules/@mui/utils/elementAcceptingRef/elementAcceptingRef.js","../../../node_modules/@mui/utils/exactProp/exactProp.js","../../../node_modules/@mui/utils/formatMuiErrorMessage/formatMuiErrorMessage.js","../../../node_modules/react-is/cjs/react-is.production.min.js","../../../node_modules/react-is/cjs/react-is.development.js","../../../node_modules/react-is/index.js","../../../node_modules/@mui/utils/getDisplayName/getDisplayName.js","../../../node_modules/@mui/utils/HTMLElementType/HTMLElementType.js","../../../node_modules/@mui/utils/refType/refType.js","../../../node_modules/@mui/utils/capitalize/capitalize.js","../../../node_modules/@mui/utils/createChainedFunction/createChainedFunction.js","../../../node_modules/@mui/utils/debounce/debounce.js","../../../node_modules/@mui/utils/deprecatedPropType/deprecatedPropType.js","../../../node_modules/@mui/utils/isMuiElement/isMuiElement.js","../../../node_modules/@mui/utils/ownerDocument/ownerDocument.js","../../../node_modules/@mui/utils/ownerWindow/ownerWindow.js","../../../node_modules/@mui/utils/requirePropFactory/requirePropFactory.js","../../../node_modules/@mui/utils/setRef/setRef.js","../../../node_modules/@mui/utils/useEnhancedEffect/useEnhancedEffect.js","../../../node_modules/@mui/utils/useId/useId.js","../../../node_modules/@mui/utils/unsupportedProp/unsupportedProp.js","../../../node_modules/@mui/utils/useControlled/useControlled.js","../../../node_modules/@mui/utils/useEventCallback/useEventCallback.js","../../../node_modules/@mui/utils/useForkRef/useForkRef.js","../../../node_modules/@mui/utils/useLazyRef/useLazyRef.js","../../../node_modules/@mui/utils/useOnMount/useOnMount.js","../../../node_modules/@mui/utils/useTimeout/useTimeout.js","../../../node_modules/@mui/utils/useIsFocusVisible/useIsFocusVisible.js","../../../node_modules/@mui/utils/resolveProps/resolveProps.js","../../../node_modules/@mui/utils/composeClasses/composeClasses.js","../../../node_modules/@mui/utils/ClassNameGenerator/ClassNameGenerator.js","../../../node_modules/@mui/utils/generateUtilityClass/generateUtilityClass.js","../../../node_modules/@mui/utils/generateUtilityClasses/generateUtilityClasses.js","../../../node_modules/@mui/utils/clamp/clamp.js","../../../node_modules/@babel/runtime/helpers/esm/objectWithoutPropertiesLoose.js","../../../node_modules/@mui/system/esm/createTheme/createBreakpoints.js","../../../node_modules/@mui/system/esm/createTheme/shape.js","../../../node_modules/@mui/system/esm/responsivePropType.js","../../../node_modules/@mui/system/esm/merge.js","../../../node_modules/@mui/system/esm/breakpoints.js","../../../node_modules/@mui/system/esm/style.js","../../../node_modules/@mui/system/esm/memoize.js","../../../node_modules/@mui/system/esm/spacing.js","../../../node_modules/@mui/system/esm/createTheme/createSpacing.js","../../../node_modules/@mui/system/esm/compose.js","../../../node_modules/@mui/system/esm/borders.js","../../../node_modules/@mui/system/esm/cssGrid.js","../../../node_modules/@mui/system/esm/palette.js","../../../node_modules/@mui/system/esm/sizing.js","../../../node_modules/@mui/system/esm/styleFunctionSx/defaultSxConfig.js","../../../node_modules/@mui/system/esm/styleFunctionSx/styleFunctionSx.js","../../../node_modules/@mui/system/esm/createTheme/applyStyles.js","../../../node_modules/@mui/system/esm/createTheme/createTheme.js","../../../node_modules/@mui/system/esm/useThemeWithoutDefault.js","../../../node_modules/@mui/system/esm/useTheme.js","../../../node_modules/@mui/system/esm/createStyled.js","../../../node_modules/@mui/system/esm/useThemeProps/getThemeProps.js","../../../node_modules/@mui/system/esm/useThemeProps/useThemeProps.js","../../../node_modules/@mui/system/esm/colorManipulator.js","../../../node_modules/@mui/material/styles/createMixins.js","../../../node_modules/@mui/material/colors/common.js","../../../node_modules/@mui/material/colors/grey.js","../../../node_modules/@mui/material/colors/purple.js","../../../node_modules/@mui/material/colors/red.js","../../../node_modules/@mui/material/colors/orange.js","../../../node_modules/@mui/material/colors/blue.js","../../../node_modules/@mui/material/colors/lightBlue.js","../../../node_modules/@mui/material/colors/green.js","../../../node_modules/@mui/material/styles/createPalette.js","../../../node_modules/@mui/material/styles/createTypography.js","../../../node_modules/@mui/material/styles/shadows.js","../../../node_modules/@mui/material/styles/createTransitions.js","../../../node_modules/@mui/material/styles/zIndex.js","../../../node_modules/@mui/material/styles/createTheme.js","../../../node_modules/@mui/material/styles/defaultTheme.js","../../../node_modules/@mui/material/styles/identifier.js","../../../node_modules/@mui/material/styles/useThemeProps.js","../../../node_modules/@mui/material/styles/styled.js","../../../node_modules/@mui/material/SvgIcon/svgIconClasses.js","../../../node_modules/@mui/material/SvgIcon/SvgIcon.js","../../../node_modules/@mui/material/utils/createSvgIcon.js","../../../node_modules/@mui/material/utils/index.js","../../../node_modules/@mui/icons-material/utils/createSvgIcon.js","../../../node_modules/@mui/icons-material/ArrowRight.js","../../../node_modules/@mui/base/utils/isHostComponent.js","../../../node_modules/@mui/base/utils/appendOwnerState.js","../../../node_modules/@mui/base/utils/ClassNameConfigurator.js","../../../node_modules/@mui/base/utils/extractEventHandlers.js","../../../node_modules/@mui/base/utils/resolveComponentProps.js","../../../node_modules/@mui/base/utils/omitEventHandlers.js","../../../node_modules/@mui/base/utils/mergeSlotProps.js","../../../node_modules/@mui/base/utils/useSlotProps.js","../../../node_modules/@mui/base/generateUtilityClass/index.js","../../../node_modules/@mui/base/generateUtilityClasses/index.js","../../../node_modules/@mui/base/Portal/Portal.js","../../../node_modules/@popperjs/core/lib/enums.js","../../../node_modules/@popperjs/core/lib/dom-utils/getNodeName.js","../../../node_modules/@popperjs/core/lib/dom-utils/getWindow.js","../../../node_modules/@popperjs/core/lib/dom-utils/instanceOf.js","../../../node_modules/@popperjs/core/lib/modifiers/applyStyles.js","../../../node_modules/@popperjs/core/lib/utils/getBasePlacement.js","../../../node_modules/@popperjs/core/lib/utils/math.js","../../../node_modules/@popperjs/core/lib/utils/userAgent.js","../../../node_modules/@popperjs/core/lib/dom-utils/isLayoutViewport.js","../../../node_modules/@popperjs/core/lib/dom-utils/getBoundingClientRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/getLayoutRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/contains.js","../../../node_modules/@popperjs/core/lib/dom-utils/getComputedStyle.js","../../../node_modules/@popperjs/core/lib/dom-utils/isTableElement.js","../../../node_modules/@popperjs/core/lib/dom-utils/getDocumentElement.js","../../../node_modules/@popperjs/core/lib/dom-utils/getParentNode.js","../../../node_modules/@popperjs/core/lib/dom-utils/getOffsetParent.js","../../../node_modules/@popperjs/core/lib/utils/getMainAxisFromPlacement.js","../../../node_modules/@popperjs/core/lib/utils/within.js","../../../node_modules/@popperjs/core/lib/utils/getFreshSideObject.js","../../../node_modules/@popperjs/core/lib/utils/mergePaddingObject.js","../../../node_modules/@popperjs/core/lib/utils/expandToHashMap.js","../../../node_modules/@popperjs/core/lib/modifiers/arrow.js","../../../node_modules/@popperjs/core/lib/utils/getVariation.js","../../../node_modules/@popperjs/core/lib/modifiers/computeStyles.js","../../../node_modules/@popperjs/core/lib/modifiers/eventListeners.js","../../../node_modules/@popperjs/core/lib/utils/getOppositePlacement.js","../../../node_modules/@popperjs/core/lib/utils/getOppositeVariationPlacement.js","../../../node_modules/@popperjs/core/lib/dom-utils/getWindowScroll.js","../../../node_modules/@popperjs/core/lib/dom-utils/getWindowScrollBarX.js","../../../node_modules/@popperjs/core/lib/dom-utils/getViewportRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/getDocumentRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/isScrollParent.js","../../../node_modules/@popperjs/core/lib/dom-utils/getScrollParent.js","../../../node_modules/@popperjs/core/lib/dom-utils/listScrollParents.js","../../../node_modules/@popperjs/core/lib/utils/rectToClientRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/getClippingRect.js","../../../node_modules/@popperjs/core/lib/utils/computeOffsets.js","../../../node_modules/@popperjs/core/lib/utils/detectOverflow.js","../../../node_modules/@popperjs/core/lib/utils/computeAutoPlacement.js","../../../node_modules/@popperjs/core/lib/modifiers/flip.js","../../../node_modules/@popperjs/core/lib/modifiers/hide.js","../../../node_modules/@popperjs/core/lib/modifiers/offset.js","../../../node_modules/@popperjs/core/lib/modifiers/popperOffsets.js","../../../node_modules/@popperjs/core/lib/utils/getAltAxis.js","../../../node_modules/@popperjs/core/lib/modifiers/preventOverflow.js","../../../node_modules/@popperjs/core/lib/dom-utils/getHTMLElementScroll.js","../../../node_modules/@popperjs/core/lib/dom-utils/getNodeScroll.js","../../../node_modules/@popperjs/core/lib/dom-utils/getCompositeRect.js","../../../node_modules/@popperjs/core/lib/utils/orderModifiers.js","../../../node_modules/@popperjs/core/lib/utils/debounce.js","../../../node_modules/@popperjs/core/lib/utils/mergeByName.js","../../../node_modules/@popperjs/core/lib/createPopper.js","../../../node_modules/@popperjs/core/lib/popper.js","../../../node_modules/@mui/base/Popper/popperClasses.js","../../../node_modules/@mui/base/Popper/Popper.js","../../../node_modules/@mui/material/styles/useTheme.js","../../../node_modules/@babel/runtime/helpers/esm/setPrototypeOf.js","../../../node_modules/@babel/runtime/helpers/esm/inheritsLoose.js","../../../node_modules/react-transition-group/esm/config.js","../../../node_modules/react-transition-group/esm/utils/PropTypes.js","../../../node_modules/react-transition-group/esm/TransitionGroupContext.js","../../../node_modules/react-transition-group/esm/utils/reflow.js","../../../node_modules/react-transition-group/esm/Transition.js","../../../node_modules/@mui/material/transitions/utils.js","../../../node_modules/@mui/material/Grow/Grow.js","../../../node_modules/@mui/material/Popper/Popper.js","../../../node_modules/@mui/material/Tooltip/tooltipClasses.js","../../../node_modules/@mui/material/Tooltip/Tooltip.js","../src/components/mui/menu-item.component.tsx","../src/components/mui/grouped-menu-item-list.component.tsx","../src/components/mui/top-level-menu.component.tsx","../src/components/mui/grid-menu.component.tsx","../src/hooks/use-promise.hook.ts","../../../node_modules/@mui/icons-material/esm/Menu.js","../src/components/mui/hamburger-menu-button.component.tsx","../src/components/mui/icon-button.component.tsx","../src/components/basics/spinner.component.tsx","../src/components/basics/text-field.component.tsx","../src/components/mui/toolbar.component.tsx","../src/components/shadcn-ui/alert.tsx","../src/components/shadcn-ui/card.tsx","../src/components/shadcn-ui/sonner.tsx","../src/components/shadcn-ui/slider.tsx","../src/components/shadcn-ui/switch.tsx","../src/components/shadcn-ui/tabs.tsx","../src/components/advanced/extension-marketplace/buttons/install-button.component.tsx","../src/components/advanced/extension-marketplace/buttons/enable-button.component.tsx","../src/components/advanced/extension-marketplace/buttons/disable-button.component.tsx","../src/components/advanced/extension-marketplace/buttons/update-button.component.tsx","../src/components/advanced/extension-marketplace/markdown-renderer.component.tsx","../src/components/advanced/extension-marketplace/buttons/filter-button.component.tsx","../src/components/advanced/extension-marketplace/filter-dropdown.component.tsx","../src/components/advanced/extension-marketplace/no-extensions-found.component.tsx","../src/components/advanced/extension-marketplace/more-info.component.tsx","../src/components/advanced/extension-marketplace/version-history.component.tsx","../src/components/advanced/extension-marketplace/footer.component.tsx","../src/hooks/use-event.hook.ts","../src/hooks/use-event-async.hook.ts"],"sourcesContent":["import { type ClassValue, clsx } from 'clsx';\nimport { extendTailwindMerge } from 'tailwind-merge';\n\nconst twMergeCustom = extendTailwindMerge({ prefix: 'tw-' });\n\n/**\n * Tailwind and CSS class application helper function. Uses\n * [`clsx`](https://www.npmjs.com/package/clsx) to make it easy to apply classes conditionally using\n * object syntax, and uses [`tailwind-merge`](https://www.npmjs.com/package/tailwind-merge) to make\n * it easy to merge/overwrite Tailwind classes in a programmer-logic-friendly way.\n *\n * Note: `tailwind-merge` is configured to use the prefix `tw-`, so you must use the same prefix\n * with any Tailwind classes you use with this function to successfully overwrite other Tailwind\n * classes. `platform-bible-react` is configured to use `tw-` as its Tailwind prefix, so any\n * Tailwind classes you pass into `platform-bible-react` components will be compared using the `tw-`\n * prefix.\n *\n * This function was popularized by\n * [shadcn/ui](https://ui.shadcn.com/docs/installation/manual#add-a-cn-helper). See [ByteGrad's\n * explanation video](https://www.youtube.com/watch?v=re2JFITR7TI) for more information.\n *\n * @example\n *\n * ```typescript\n * const borderShouldBeBlue = true;\n * const textShouldBeRed = true;\n * const heightShouldBe20 = false;\n * const classString = cn(\n * 'tw-bg-primary tw-h-10 tw-text-primary-foreground',\n * 'tw-bg-secondary',\n * {\n * 'tw-border-blue-500': borderShouldBeBlue,\n * 'tw-text-red-500': textShouldBeRed,\n * 'tw-h-20': heightShouldBe20,\n * },\n * 'some-class',\n * );\n * ```\n *\n * The resulting `classString` is `'tw-h-10 tw-bg-secondary tw-border-blue-500 tw-text-red-500\n * some-class'`\n *\n * - Notice that `'tw-bg-secondary'`, specified later, overwrote `'tw-bg-primary'`, specified earlier,\n * because they are Tailwind classes that affect the same css property\n * - Notice that `'tw-text-red-500'`, specified later, overwrote `'tw-text-primary-foreground'`,\n * specified earlier, because they are Tailwind classes that affect the same css property\n * - Notice that `'tw-h-20'`, specified later, did not overwrite `'tw-h-10'`, specified earlier,\n * because `'tw-h-20'` is part of a conditional class object and its value evaluated to `false`;\n * therefore it was not applied\n * - Notice that `'some-class'` was applied. This function is not limited only to Tailwind classes.\n *\n *\n * @param inputs Class strings or `clsx` conditional class objects to merge. Tailwind classes\n * specified later in the arguments overwrite similar Tailwind classes specified earlier in the\n * arguments\n * @returns Class string containing all applicable classes from the arguments based on the rules\n * described above\n */\n// shadcn/ui uses this export in its boilerplate code\n// eslint-disable-next-line import/prefer-default-export\nexport function cn(...inputs: ClassValue[]) {\n return twMergeCustom(clsx(inputs));\n}\n","import React from 'react';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport interface InputProps extends React.InputHTMLAttributes {}\n\nexport const Input = React.forwardRef(\n ({ className, type, ...props }, ref) => {\n return (\n \n );\n },\n);\nInput.displayName = 'Input';\n","import { FocusEventHandler, forwardRef, KeyboardEvent, MouseEventHandler } from 'react';\nimport { History } from 'lucide-react';\nimport { Input as ShadInput } from '@/components/shadcn-ui/input';\n\nexport type BookChapterInputProps = {\n handleSearch: (searchString: string) => void;\n handleKeyDown: (event: KeyboardEvent) => void;\n handleOnClick: MouseEventHandler;\n handleSubmit: () => void;\n onFocus?: FocusEventHandler;\n value: string;\n placeholder: string;\n};\n\n// Shadcn Input sets type to \"button\"- HAVE to prop spread before setting type\nconst BookChapterInput = forwardRef(\n (\n { handleSearch, handleKeyDown, handleOnClick, handleSubmit, ...props }: BookChapterInputProps,\n ref,\n ) => {\n return (\n
    \n handleSearch(event.target.value)}\n onKeyDown={(e) => {\n if (e.key === 'Enter') {\n handleSubmit();\n }\n handleKeyDown(e);\n }}\n onClick={handleOnClick}\n ref={ref}\n />\n {\n // eslint-disable-next-line no-console\n console.log('back in history');\n }}\n />\n
    \n );\n },\n);\n\nexport default BookChapterInput;\n","var P = Object.defineProperty;\nvar R = (t, e, s) => e in t ? P(t, e, { enumerable: !0, configurable: !0, writable: !0, value: s }) : t[e] = s;\nvar n = (t, e, s) => R(t, typeof e != \"symbol\" ? e + \"\" : e, s);\nclass _ {\n constructor() {\n n(this, \"books\");\n n(this, \"firstSelectedBookNum\");\n n(this, \"lastSelectedBookNum\");\n n(this, \"count\");\n n(this, \"selectedBookNumbers\");\n n(this, \"selectedBookIds\");\n }\n}\nconst N = [\n \"GEN\",\n \"EXO\",\n \"LEV\",\n \"NUM\",\n \"DEU\",\n \"JOS\",\n \"JDG\",\n \"RUT\",\n \"1SA\",\n \"2SA\",\n // 10\n \"1KI\",\n \"2KI\",\n \"1CH\",\n \"2CH\",\n \"EZR\",\n \"NEH\",\n \"EST\",\n \"JOB\",\n \"PSA\",\n \"PRO\",\n // 20\n \"ECC\",\n \"SNG\",\n \"ISA\",\n \"JER\",\n \"LAM\",\n \"EZK\",\n \"DAN\",\n \"HOS\",\n \"JOL\",\n \"AMO\",\n // 30\n \"OBA\",\n \"JON\",\n \"MIC\",\n \"NAM\",\n \"HAB\",\n \"ZEP\",\n \"HAG\",\n \"ZEC\",\n \"MAL\",\n \"MAT\",\n // 40\n \"MRK\",\n \"LUK\",\n \"JHN\",\n \"ACT\",\n \"ROM\",\n \"1CO\",\n \"2CO\",\n \"GAL\",\n \"EPH\",\n \"PHP\",\n // 50\n \"COL\",\n \"1TH\",\n \"2TH\",\n \"1TI\",\n \"2TI\",\n \"TIT\",\n \"PHM\",\n \"HEB\",\n \"JAS\",\n \"1PE\",\n // 60\n \"2PE\",\n \"1JN\",\n \"2JN\",\n \"3JN\",\n \"JUD\",\n \"REV\",\n \"TOB\",\n \"JDT\",\n \"ESG\",\n \"WIS\",\n // 70\n \"SIR\",\n \"BAR\",\n \"LJE\",\n \"S3Y\",\n \"SUS\",\n \"BEL\",\n \"1MA\",\n \"2MA\",\n \"3MA\",\n \"4MA\",\n // 80\n \"1ES\",\n \"2ES\",\n \"MAN\",\n \"PS2\",\n \"ODA\",\n \"PSS\",\n \"JSA\",\n // actual variant text for JOS, now in LXA text\n \"JDB\",\n // actual variant text for JDG, now in LXA text\n \"TBS\",\n // actual variant text for TOB, now in LXA text\n \"SST\",\n // actual variant text for SUS, now in LXA text // 90\n \"DNT\",\n // actual variant text for DAN, now in LXA text\n \"BLT\",\n // actual variant text for BEL, now in LXA text\n \"XXA\",\n \"XXB\",\n \"XXC\",\n \"XXD\",\n \"XXE\",\n \"XXF\",\n \"XXG\",\n \"FRT\",\n // 100\n \"BAK\",\n \"OTH\",\n \"3ES\",\n // Used previously but really should be 2ES\n \"EZA\",\n // Used to be called 4ES, but not actually in any known project\n \"5EZ\",\n // Used to be called 5ES, but not actually in any known project\n \"6EZ\",\n // Used to be called 6ES, but not actually in any known project\n \"INT\",\n \"CNC\",\n \"GLO\",\n \"TDX\",\n // 110\n \"NDX\",\n \"DAG\",\n \"PS3\",\n \"2BA\",\n \"LBA\",\n \"JUB\",\n \"ENO\",\n \"1MQ\",\n \"2MQ\",\n \"3MQ\",\n // 120\n \"REP\",\n \"4BA\",\n \"LAO\"\n], B = [\n \"XXA\",\n \"XXB\",\n \"XXC\",\n \"XXD\",\n \"XXE\",\n \"XXF\",\n \"XXG\",\n \"FRT\",\n \"BAK\",\n \"OTH\",\n \"INT\",\n \"CNC\",\n \"GLO\",\n \"TDX\",\n \"NDX\"\n], O = [\n \"Genesis\",\n \"Exodus\",\n \"Leviticus\",\n \"Numbers\",\n \"Deuteronomy\",\n \"Joshua\",\n \"Judges\",\n \"Ruth\",\n \"1 Samuel\",\n \"2 Samuel\",\n \"1 Kings\",\n \"2 Kings\",\n \"1 Chronicles\",\n \"2 Chronicles\",\n \"Ezra\",\n \"Nehemiah\",\n \"Esther (Hebrew)\",\n \"Job\",\n \"Psalms\",\n \"Proverbs\",\n \"Ecclesiastes\",\n \"Song of Songs\",\n \"Isaiah\",\n \"Jeremiah\",\n \"Lamentations\",\n \"Ezekiel\",\n \"Daniel (Hebrew)\",\n \"Hosea\",\n \"Joel\",\n \"Amos\",\n \"Obadiah\",\n \"Jonah\",\n \"Micah\",\n \"Nahum\",\n \"Habakkuk\",\n \"Zephaniah\",\n \"Haggai\",\n \"Zechariah\",\n \"Malachi\",\n \"Matthew\",\n \"Mark\",\n \"Luke\",\n \"John\",\n \"Acts\",\n \"Romans\",\n \"1 Corinthians\",\n \"2 Corinthians\",\n \"Galatians\",\n \"Ephesians\",\n \"Philippians\",\n \"Colossians\",\n \"1 Thessalonians\",\n \"2 Thessalonians\",\n \"1 Timothy\",\n \"2 Timothy\",\n \"Titus\",\n \"Philemon\",\n \"Hebrews\",\n \"James\",\n \"1 Peter\",\n \"2 Peter\",\n \"1 John\",\n \"2 John\",\n \"3 John\",\n \"Jude\",\n \"Revelation\",\n \"Tobit\",\n \"Judith\",\n \"Esther Greek\",\n \"Wisdom of Solomon\",\n \"Sirach (Ecclesiasticus)\",\n \"Baruch\",\n \"Letter of Jeremiah\",\n \"Song of 3 Young Men\",\n \"Susanna\",\n \"Bel and the Dragon\",\n \"1 Maccabees\",\n \"2 Maccabees\",\n \"3 Maccabees\",\n \"4 Maccabees\",\n \"1 Esdras (Greek)\",\n \"2 Esdras (Latin)\",\n \"Prayer of Manasseh\",\n \"Psalm 151\",\n \"Odes\",\n \"Psalms of Solomon\",\n // WARNING, if you change the spelling of the *obsolete* tag be sure to update\n // IsObsolete routine\n \"Joshua A. *obsolete*\",\n \"Judges B. *obsolete*\",\n \"Tobit S. *obsolete*\",\n \"Susanna Th. *obsolete*\",\n \"Daniel Th. *obsolete*\",\n \"Bel Th. *obsolete*\",\n \"Extra A\",\n \"Extra B\",\n \"Extra C\",\n \"Extra D\",\n \"Extra E\",\n \"Extra F\",\n \"Extra G\",\n \"Front Matter\",\n \"Back Matter\",\n \"Other Matter\",\n \"3 Ezra *obsolete*\",\n \"Apocalypse of Ezra\",\n \"5 Ezra (Latin Prologue)\",\n \"6 Ezra (Latin Epilogue)\",\n \"Introduction\",\n \"Concordance \",\n \"Glossary \",\n \"Topical Index\",\n \"Names Index\",\n \"Daniel Greek\",\n \"Psalms 152-155\",\n \"2 Baruch (Apocalypse)\",\n \"Letter of Baruch\",\n \"Jubilees\",\n \"Enoch\",\n \"1 Meqabyan\",\n \"2 Meqabyan\",\n \"3 Meqabyan\",\n \"Reproof (Proverbs 25-31)\",\n \"4 Baruch (Rest of Baruch)\",\n \"Laodiceans\"\n], S = K();\nfunction g(t, e = !0) {\n return e && (t = t.toUpperCase()), t in S ? S[t] : 0;\n}\nfunction k(t) {\n return g(t) > 0;\n}\nfunction x(t) {\n const e = typeof t == \"string\" ? g(t) : t;\n return e >= 40 && e <= 66;\n}\nfunction T(t) {\n return (typeof t == \"string\" ? g(t) : t) <= 39;\n}\nfunction X(t) {\n return t <= 66;\n}\nfunction V(t) {\n const e = typeof t == \"string\" ? g(t) : t;\n return w(e) && !X(e);\n}\nfunction* L() {\n for (let t = 1; t <= N.length; t++) yield t;\n}\nconst G = 1, A = N.length;\nfunction H() {\n return [\"XXA\", \"XXB\", \"XXC\", \"XXD\", \"XXE\", \"XXF\", \"XXG\"];\n}\nfunction C(t, e = \"***\") {\n const s = t - 1;\n return s < 0 || s >= N.length ? e : N[s];\n}\nfunction I(t) {\n return t <= 0 || t > A ? \"******\" : O[t - 1];\n}\nfunction y(t) {\n return I(g(t));\n}\nfunction w(t) {\n const e = typeof t == \"number\" ? C(t) : t;\n return k(e) && !B.includes(e);\n}\nfunction q(t) {\n const e = typeof t == \"number\" ? C(t) : t;\n return k(e) && B.includes(e);\n}\nfunction U(t) {\n return O[t - 1].includes(\"*obsolete*\");\n}\nfunction K() {\n const t = {};\n for (let e = 0; e < N.length; e++)\n t[N[e]] = e + 1;\n return t;\n}\nconst m = {\n allBookIds: N,\n nonCanonicalIds: B,\n bookIdToNumber: g,\n isBookIdValid: k,\n isBookNT: x,\n isBookOT: T,\n isBookOTNT: X,\n isBookDC: V,\n allBookNumbers: L,\n firstBook: G,\n lastBook: A,\n extraBooks: H,\n bookNumberToId: C,\n bookNumberToEnglishName: I,\n bookIdToEnglishName: y,\n isCanonical: w,\n isExtraMaterial: q,\n isObsolete: U\n};\nvar l = /* @__PURE__ */ ((t) => (t[t.Unknown = 0] = \"Unknown\", t[t.Original = 1] = \"Original\", t[t.Septuagint = 2] = \"Septuagint\", t[t.Vulgate = 3] = \"Vulgate\", t[t.English = 4] = \"English\", t[t.RussianProtestant = 5] = \"RussianProtestant\", t[t.RussianOrthodox = 6] = \"RussianOrthodox\", t))(l || {});\nconst h = class h {\n // private versInfo: Versification;\n constructor(e) {\n n(this, \"name\");\n n(this, \"fullPath\");\n n(this, \"isPresent\");\n n(this, \"hasVerseSegments\");\n n(this, \"isCustomized\");\n n(this, \"baseVersification\");\n n(this, \"scriptureBooks\");\n n(this, \"_type\");\n if (e == null)\n throw new Error(\"Argument undefined\");\n typeof e == \"string\" ? (this.name = e, this._type = l[e]) : (this._type = e, this.name = l[e]);\n }\n get type() {\n return this._type;\n }\n equals(e) {\n return !e.type || !this.type ? !1 : e.type === this.type;\n }\n};\nn(h, \"Original\", new h(l.Original)), n(h, \"Septuagint\", new h(l.Septuagint)), n(h, \"Vulgate\", new h(l.Vulgate)), n(h, \"English\", new h(l.English)), n(h, \"RussianProtestant\", new h(l.RussianProtestant)), n(h, \"RussianOrthodox\", new h(l.RussianOrthodox));\nlet c = h;\nfunction E(t, e) {\n const s = e[0];\n for (let r = 1; r < e.length; r++)\n t = t.split(e[r]).join(s);\n return t.split(s);\n}\nvar D = /* @__PURE__ */ ((t) => (t[t.Valid = 0] = \"Valid\", t[t.UnknownVersification = 1] = \"UnknownVersification\", t[t.OutOfRange = 2] = \"OutOfRange\", t[t.VerseOutOfOrder = 3] = \"VerseOutOfOrder\", t[t.VerseRepeated = 4] = \"VerseRepeated\", t))(D || {});\nconst i = class i {\n constructor(e, s, r, a) {\n /** Not yet implemented. */\n n(this, \"firstChapter\");\n /** Not yet implemented. */\n n(this, \"lastChapter\");\n /** Not yet implemented. */\n n(this, \"lastVerse\");\n /** Not yet implemented. */\n n(this, \"hasSegmentsDefined\");\n /** Not yet implemented. */\n n(this, \"text\");\n /** Not yet implemented. */\n n(this, \"BBBCCCVVVS\");\n /** Not yet implemented. */\n n(this, \"longHashCode\");\n /** The versification of the reference. */\n n(this, \"versification\");\n n(this, \"rtlMark\", \"‏\");\n n(this, \"_bookNum\", 0);\n n(this, \"_chapterNum\", 0);\n n(this, \"_verseNum\", 0);\n n(this, \"_verse\");\n if (r == null && a == null)\n if (e != null && typeof e == \"string\") {\n const o = e, u = s != null && s instanceof c ? s : void 0;\n this.setEmpty(u), this.parse(o);\n } else if (e != null && typeof e == \"number\") {\n const o = s != null && s instanceof c ? s : void 0;\n this.setEmpty(o), this._verseNum = e % i.chapterDigitShifter, this._chapterNum = Math.floor(\n e % i.bookDigitShifter / i.chapterDigitShifter\n ), this._bookNum = Math.floor(e / i.bookDigitShifter);\n } else if (s == null)\n if (e != null && e instanceof i) {\n const o = e;\n this._bookNum = o.bookNum, this._chapterNum = o.chapterNum, this._verseNum = o.verseNum, this._verse = o.verse, this.versification = o.versification;\n } else {\n if (e == null) return;\n const o = e instanceof c ? e : i.defaultVersification;\n this.setEmpty(o);\n }\n else\n throw new Error(\"VerseRef constructor not supported.\");\n else if (e != null && s != null && r != null)\n if (typeof e == \"string\" && typeof s == \"string\" && typeof r == \"string\")\n this.setEmpty(a), this.updateInternal(e, s, r);\n else if (typeof e == \"number\" && typeof s == \"number\" && typeof r == \"number\")\n this._bookNum = e, this._chapterNum = s, this._verseNum = r, this.versification = a ?? i.defaultVersification;\n else\n throw new Error(\"VerseRef constructor not supported.\");\n else\n throw new Error(\"VerseRef constructor not supported.\");\n }\n /**\n * Determines if the verse string is in a valid format (does not consider versification).\n */\n static isVerseParseable(e) {\n return e.length > 0 && \"0123456789\".includes(e[0]) && !e.endsWith(this.verseRangeSeparator) && !e.endsWith(this.verseSequenceIndicator);\n }\n /**\n * Tries to parse the specified string into a verse reference.\n * @param str - The string to attempt to parse.\n * @returns success: `true` if the specified string was successfully parsed, `false` otherwise.\n * @returns verseRef: The result of the parse if successful, or empty VerseRef if it failed\n */\n static tryParse(e) {\n let s;\n try {\n return s = new i(e), { success: !0, verseRef: s };\n } catch (r) {\n if (r instanceof v)\n return s = new i(), { success: !1, verseRef: s };\n throw r;\n }\n }\n /**\n * Gets the reference as a comparable integer where the book, chapter, and verse each occupy 3\n * digits.\n * @param bookNum - Book number (this is 1-based, not an index).\n * @param chapterNum - Chapter number.\n * @param verseNum - Verse number.\n * @returns The reference as a comparable integer where the book, chapter, and verse each occupy 3\n * digits.\n */\n static getBBBCCCVVV(e, s, r) {\n return e % i.bcvMaxValue * i.bookDigitShifter + (s >= 0 ? s % i.bcvMaxValue * i.chapterDigitShifter : 0) + (r >= 0 ? r % i.bcvMaxValue : 0);\n }\n /**\n * Deserializes a serialized VerseRef.\n * @param serializedVerseRef - Serialized VerseRef to create from.\n * @returns the deserialized VerseRef.\n */\n static fromJSON(e) {\n const { book: s, chapterNum: r, verseNum: a, verse: o, versificationStr: u } = e, f = o || a.toString();\n let d;\n return u && (d = new c(u)), s ? new i(s, r.toString(), f, d) : new i();\n }\n /**\n * Parses a verse string and gets the leading numeric portion as a number.\n * @param verseStr - verse string to parse\n * @returns true if the entire string could be parsed as a single, simple verse number (1-999);\n * false if the verse string represented a verse bridge, contained segment letters, or was invalid\n */\n static tryGetVerseNum(e) {\n let s;\n if (!e)\n return s = -1, { success: !0, vNum: s };\n s = 0;\n let r;\n for (let a = 0; a < e.length; a++) {\n if (r = e[a], r < \"0\" || r > \"9\")\n return a === 0 && (s = -1), { success: !1, vNum: s };\n if (s = s * 10 + +r - 0, s > i.bcvMaxValue)\n return s = -1, { success: !1, vNum: s };\n }\n return { success: !0, vNum: s };\n }\n /**\n * Checks to see if a VerseRef hasn't been set - all values are the default.\n */\n get isDefault() {\n return this.bookNum === 0 && this.chapterNum === 0 && this.verseNum === 0 && this.versification == null;\n }\n /**\n * Gets whether the verse contains multiple verses.\n */\n get hasMultiple() {\n return this._verse != null && (this._verse.includes(i.verseRangeSeparator) || this._verse.includes(i.verseSequenceIndicator));\n }\n /**\n * Gets or sets the book of the reference. Book is the 3-letter abbreviation in capital letters,\n * e.g. `'MAT'`.\n */\n get book() {\n return m.bookNumberToId(this.bookNum, \"\");\n }\n set book(e) {\n this.bookNum = m.bookIdToNumber(e);\n }\n /**\n * Gets or sets the chapter of the reference,. e.g. `'3'`.\n */\n get chapter() {\n return this.isDefault || this._chapterNum < 0 ? \"\" : this._chapterNum.toString();\n }\n set chapter(e) {\n const s = +e;\n this._chapterNum = Number.isInteger(s) ? s : -1;\n }\n /**\n * Gets or sets the verse of the reference, including range, segments, and sequences, e.g. `'4'`,\n * or `'4b-5a, 7'`.\n */\n get verse() {\n return this._verse != null ? this._verse : this.isDefault || this._verseNum < 0 ? \"\" : this._verseNum.toString();\n }\n set verse(e) {\n const { success: s, vNum: r } = i.tryGetVerseNum(e);\n this._verse = s ? void 0 : e.replace(this.rtlMark, \"\"), this._verseNum = r, !(this._verseNum >= 0) && ({ vNum: this._verseNum } = i.tryGetVerseNum(this._verse));\n }\n /**\n * Get or set Book based on book number, e.g. `42`.\n */\n get bookNum() {\n return this._bookNum;\n }\n set bookNum(e) {\n if (e <= 0 || e > m.lastBook)\n throw new v(\n \"BookNum must be greater than zero and less than or equal to last book\"\n );\n this._bookNum = e;\n }\n /**\n * Gets or sets the chapter number, e.g. `3`. `-1` if not valid.\n */\n get chapterNum() {\n return this._chapterNum;\n }\n set chapterNum(e) {\n this.chapterNum = e;\n }\n /**\n * Gets or sets verse start number, e.g. `4`. `-1` if not valid.\n */\n get verseNum() {\n return this._verseNum;\n }\n set verseNum(e) {\n this._verseNum = e;\n }\n /**\n * String representing the versification (should ONLY be used for serialization/deserialization).\n *\n * @remarks This is for backwards compatibility when ScrVers was an enumeration.\n */\n get versificationStr() {\n var e;\n return (e = this.versification) == null ? void 0 : e.name;\n }\n set versificationStr(e) {\n this.versification = this.versification != null ? new c(e) : void 0;\n }\n /**\n * Determines if the reference is valid.\n */\n get valid() {\n return this.validStatus === 0;\n }\n /**\n * Get the valid status for this reference.\n */\n get validStatus() {\n return this.validateVerse(i.verseRangeSeparators, i.verseSequenceIndicators);\n }\n /**\n * Gets the reference as a comparable integer where the book,\n * chapter, and verse each occupy three digits and the verse is 0.\n */\n get BBBCCC() {\n return i.getBBBCCCVVV(this._bookNum, this._chapterNum, 0);\n }\n /**\n * Gets the reference as a comparable integer where the book,\n * chapter, and verse each occupy three digits. If verse is not null\n * (i.e., this reference represents a complex reference with verse\n * segments or bridge) this cannot be used for an exact comparison.\n */\n get BBBCCCVVV() {\n return i.getBBBCCCVVV(this._bookNum, this._chapterNum, this._verseNum);\n }\n /**\n * Gets whether the verse is defined as an excluded verse in the versification.\n * Does not handle verse ranges.\n */\n // eslint-disable-next-line @typescript-eslint/class-literal-property-style\n get isExcluded() {\n return !1;\n }\n /**\n * Parses the reference in the specified string.\n * Optionally versification can follow reference as in GEN 3:11/4\n * Throw an exception if\n * - invalid book name\n * - chapter number is missing or not a number\n * - verse number is missing or does not start with a number\n * - versification is invalid\n * @param verseStr - string to parse e.g. 'MAT 3:11'\n */\n parse(e) {\n if (e = e.replace(this.rtlMark, \"\"), e.includes(\"/\")) {\n const o = e.split(\"/\");\n if (e = o[0], o.length > 1)\n try {\n const u = +o[1].trim();\n this.versification = new c(l[u]);\n } catch {\n throw new v(\"Invalid reference : \" + e);\n }\n }\n const s = e.trim().split(\" \");\n if (s.length !== 2)\n throw new v(\"Invalid reference : \" + e);\n const r = s[1].split(\":\"), a = +r[0];\n if (r.length !== 2 || m.bookIdToNumber(s[0]) === 0 || !Number.isInteger(a) || a < 0 || !i.isVerseParseable(r[1]))\n throw new v(\"Invalid reference : \" + e);\n this.updateInternal(s[0], r[0], r[1]);\n }\n /**\n * Simplifies this verse ref so that it has no bridging of verses or\n * verse segments like `'1a'`.\n */\n simplify() {\n this._verse = void 0;\n }\n /**\n * Makes a clone of the reference.\n *\n * @returns The cloned VerseRef.\n */\n clone() {\n return new i(this);\n }\n toString() {\n const e = this.book;\n return e === \"\" ? \"\" : `${e} ${this.chapter}:${this.verse}`;\n }\n toJSON() {\n let e = this.verse;\n (e === \"\" || e === this.verseNum.toString()) && (e = void 0);\n const s = {\n book: this.book,\n chapterNum: this.chapterNum,\n verseNum: this.verseNum,\n verse: e,\n versificationStr: this.versificationStr\n };\n return e || delete s.verse, s;\n }\n /**\n * Compares this `VerseRef` with supplied one.\n * @param verseRef - object to compare this one to.\n * @returns `true` if this `VerseRef` is equal to the supplied one, `false` otherwise.\n */\n equals(e) {\n return e instanceof i ? e._bookNum === this._bookNum && e._chapterNum === this._chapterNum && e._verseNum === this._verseNum && e.verse === this.verse && (e.versification == null && this.versification == null || e.versification != null && this.versification != null && e.versification.equals(this.versification)) : !1;\n }\n /**\n * Enumerate all individual verses contained in a VerseRef.\n * Verse ranges are indicated by \"-\" and consecutive verses by \",\"s.\n * Examples:\n * GEN 1:2 returns GEN 1:2\n * GEN 1:1a-3b,5 returns GEN 1:1a, GEN 1:2, GEN 1:3b, GEN 1:5\n * GEN 1:2a-2c returns //! ??????\n *\n * @param specifiedVersesOnly - if set to true return only verses that are\n * explicitly specified only, not verses within a range. Defaults to `false`.\n * @param verseRangeSeparators - Verse range separators.\n * Defaults to `VerseRef.verseRangeSeparators`.\n * @param verseSequenceSeparators - Verse sequence separators.\n * Defaults to `VerseRef.verseSequenceIndicators`.\n * @returns An array of all single verse references in this VerseRef.\n */\n allVerses(e = !1, s = i.verseRangeSeparators, r = i.verseSequenceIndicators) {\n if (this._verse == null || this.chapterNum <= 0)\n return [this.clone()];\n const a = [], o = E(this._verse, r);\n for (const u of o.map((f) => E(f, s))) {\n const f = this.clone();\n f.verse = u[0];\n const d = f.verseNum;\n if (a.push(f), u.length > 1) {\n const b = this.clone();\n if (b.verse = u[1], !e)\n for (let p = d + 1; p < b.verseNum; p++) {\n const J = new i(\n this._bookNum,\n this._chapterNum,\n p,\n this.versification\n );\n this.isExcluded || a.push(J);\n }\n a.push(b);\n }\n }\n return a;\n }\n /**\n * Validates a verse number using the supplied separators rather than the defaults.\n */\n validateVerse(e, s) {\n if (!this.verse)\n return this.internalValid;\n let r = 0;\n for (const a of this.allVerses(!0, e, s)) {\n const o = a.internalValid;\n if (o !== 0)\n return o;\n const u = a.BBBCCCVVV;\n if (r > u)\n return 3;\n if (r === u)\n return 4;\n r = u;\n }\n return 0;\n }\n /**\n * Gets whether a single verse reference is valid.\n */\n get internalValid() {\n return this.versification == null ? 1 : this._bookNum <= 0 || this._bookNum > m.lastBook ? 2 : (m.isCanonical(this._bookNum), 0);\n }\n setEmpty(e = i.defaultVersification) {\n this._bookNum = 0, this._chapterNum = -1, this._verse = void 0, this.versification = e;\n }\n updateInternal(e, s, r) {\n this.bookNum = m.bookIdToNumber(e), this.chapter = s, this.verse = r;\n }\n};\nn(i, \"defaultVersification\", c.English), n(i, \"verseRangeSeparator\", \"-\"), n(i, \"verseSequenceIndicator\", \",\"), n(i, \"verseRangeSeparators\", [i.verseRangeSeparator]), n(i, \"verseSequenceIndicators\", [i.verseSequenceIndicator]), n(i, \"chapterDigitShifter\", 1e3), n(i, \"bookDigitShifter\", i.chapterDigitShifter * i.chapterDigitShifter), n(i, \"bcvMaxValue\", i.chapterDigitShifter - 1), /**\n * The valid status of the VerseRef.\n */\nn(i, \"ValidStatusType\", D);\nlet M = i;\nclass v extends Error {\n}\nexport {\n _ as BookSet,\n m as Canon,\n c as ScrVers,\n l as ScrVersType,\n M as VerseRef,\n v as VerseRefException\n};\n//# sourceMappingURL=index.es.js.map\n","import React from 'react';\nimport * as DropdownMenuPrimitive from '@radix-ui/react-dropdown-menu';\nimport { Check, ChevronRight, Circle } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport const DropdownMenu = DropdownMenuPrimitive.Root;\n\nexport const DropdownMenuTrigger = DropdownMenuPrimitive.Trigger;\n\nexport const DropdownMenuGroup = DropdownMenuPrimitive.Group;\n\nexport const DropdownMenuPortal = DropdownMenuPrimitive.Portal;\n\nexport const DropdownMenuSub = DropdownMenuPrimitive.Sub;\n\nexport const DropdownMenuRadioGroup = DropdownMenuPrimitive.RadioGroup;\n\nexport type DropdownMenuSubTriggerProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.SubTrigger\n> & {\n className?: string;\n inset?: boolean;\n};\n\nexport type DropdownMenuSubContentProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.SubContent\n> & {\n className?: string;\n};\n\nexport type DropdownMenuContentProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Content\n> & {\n className?: string;\n sideOffset?: number;\n};\n\nexport type DropdownMenuItemProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Item\n> & {\n className?: string;\n inset?: boolean;\n};\n\nexport type DropdownMenuCheckboxItemProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.CheckboxItem\n> & {\n className?: string;\n checked?: boolean;\n};\n\nexport type DropdownMenuRadioItemProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.RadioItem\n> & {\n className?: string;\n};\n\nexport type DropdownMenuLabelProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Label\n> & {\n className?: string;\n inset?: boolean;\n};\n\nexport type DropdownMenuSeparatorProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Separator\n> & {\n className?: string;\n};\n\nexport type DropdownMenuShortcutProps = React.HTMLAttributes & {\n className?: string;\n};\n\nexport const DropdownMenuSubTrigger = React.forwardRef<\n React.ElementRef,\n DropdownMenuSubTriggerProps\n>(({ className, inset, children, ...props }, ref) => (\n \n {children}\n \n \n));\nDropdownMenuSubTrigger.displayName = DropdownMenuPrimitive.SubTrigger.displayName;\n\nexport const DropdownMenuSubContent = React.forwardRef<\n React.ElementRef,\n DropdownMenuSubContentProps\n>(({ className, ...props }, ref) => (\n \n));\nDropdownMenuSubContent.displayName = DropdownMenuPrimitive.SubContent.displayName;\n\nexport const DropdownMenuContent = React.forwardRef<\n React.ElementRef,\n DropdownMenuContentProps\n>(({ className, sideOffset = 4, ...props }, ref) => (\n \n \n \n));\nDropdownMenuContent.displayName = DropdownMenuPrimitive.Content.displayName;\n\n/**\n * TODO: fix: direction is not automatically handled by this component, so that shortcuts are\n * display always to the right\n */\nexport const DropdownMenuItem = React.forwardRef<\n React.ElementRef,\n DropdownMenuItemProps\n>(({ className, inset, ...props }, ref) => (\n \n));\nDropdownMenuItem.displayName = DropdownMenuPrimitive.Item.displayName;\n\nexport const DropdownMenuCheckboxItem = React.forwardRef<\n React.ElementRef,\n DropdownMenuCheckboxItemProps\n>(({ className, children, checked, ...props }, ref) => (\n \n \n \n \n \n \n {children}\n \n));\nDropdownMenuCheckboxItem.displayName = DropdownMenuPrimitive.CheckboxItem.displayName;\n\nexport const DropdownMenuRadioItem = React.forwardRef<\n React.ElementRef,\n DropdownMenuRadioItemProps\n>(({ className, children, ...props }, ref) => (\n \n \n \n \n \n \n {children}\n \n));\nDropdownMenuRadioItem.displayName = DropdownMenuPrimitive.RadioItem.displayName;\n\nexport const DropdownMenuLabel = React.forwardRef<\n React.ElementRef,\n DropdownMenuLabelProps\n>(({ className, inset, ...props }, ref) => (\n \n));\nDropdownMenuLabel.displayName = DropdownMenuPrimitive.Label.displayName;\n\nexport const DropdownMenuSeparator = React.forwardRef<\n React.ElementRef,\n DropdownMenuSeparatorProps\n>(({ className, ...props }, ref) => (\n \n));\nDropdownMenuSeparator.displayName = DropdownMenuPrimitive.Separator.displayName;\n\nexport function DropdownMenuShortcut({ className, ...props }: DropdownMenuShortcutProps) {\n return (\n \n );\n}\nDropdownMenuShortcut.displayName = 'DropdownMenuShortcut';\n","import { Canon } from '@sillsdev/scripture';\nimport { PropsWithChildren, KeyboardEvent, forwardRef } from 'react';\nimport { DropdownMenuItem as ShadDropdownMenuItem } from '@/components/shadcn-ui/dropdown-menu';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport type BookType = 'OT' | 'NT' | 'DC';\n\ntype BookMenuItemProps = PropsWithChildren<{\n /** String id of book */\n bookId: string;\n /** Callback to run when a book menu item is selected */\n handleSelectBook: () => void;\n /** Indicates if this menu item is currently selected */\n isSelected: boolean;\n /** Function that is called upon highlighting a book in the dropdown menu */\n handleHighlightBook: () => void;\n /**\n * Function that is called on pressing a key\n *\n * @param event Event that contains information about the key stroke\n */\n handleKeyDown: (event: KeyboardEvent) => void;\n /**\n * Type of book associated with this menu item, coordinates color labels ? Mock up has the labels\n * coordinated to genre\n */\n bookType: BookType;\n}>;\n\nconst BookMenuItem = forwardRef(\n (\n {\n bookId,\n handleSelectBook,\n isSelected,\n handleHighlightBook,\n handleKeyDown,\n bookType,\n children,\n }: BookMenuItemProps,\n ref,\n ) => {\n return (\n {\n // preventDefault() here prevents the entire dropdown menu from closing when selecting this item\n event.preventDefault();\n handleSelectBook();\n }}\n onKeyDown={(event: KeyboardEvent) => {\n handleKeyDown(event);\n }}\n onFocus={handleHighlightBook}\n onMouseMove={handleHighlightBook}\n >\n \n {Canon.bookIdToEnglishName(bookId)}\n \n {isSelected &&
    {children}
    }\n \n );\n },\n);\n\nexport default BookMenuItem;\n","import { cn } from '@/utils/shadcn-ui.util';\nimport { useCallback } from 'react';\n\nexport type ChapterSelectProps = {\n /**\n * Callback to run when a chapter div is selected\n *\n * @param chapterNumber Number of the chapter that has been selected\n */\n handleSelectChapter: (chapterNumber: number) => void;\n /** The highest chapter number in the book (of course equal to number of chapters in the book) */\n endChapter: number;\n /** The chapter number that is currently selected */\n activeChapter: number;\n /** The chapter number that is currently highlighted using keyboard or mouse navigation */\n highlightedChapter: number;\n /**\n * Callback to run when a chapter is highlighted by the user\n *\n * @param chapterNumber The chapter that is highlighted\n */\n handleHighlightedChapter: (chapterNumber: number) => void;\n};\n\nfunction ChapterSelect({\n handleSelectChapter,\n endChapter,\n activeChapter,\n highlightedChapter,\n handleHighlightedChapter,\n}: ChapterSelectProps) {\n const chapters = Array.from({ length: endChapter }, (_, i) => i + 1);\n\n const handleMouse = useCallback(\n (chapterNumber: number) => {\n handleHighlightedChapter(chapterNumber);\n },\n [handleHighlightedChapter],\n );\n\n return (\n
    \n {chapters.map((chapter) => (\n {\n event.preventDefault();\n event.stopPropagation();\n handleSelectChapter(chapter);\n }}\n role=\"button\"\n onKeyDown={(event) => {\n if (event.key === 'Enter') {\n handleSelectChapter(chapter);\n }\n }}\n tabIndex={0}\n onMouseMove={() => handleMouse(chapter)}\n >\n {chapter}\n
    \n ))}\n
    \n );\n}\n\nexport default ChapterSelect;\n","import { DropdownMenuLabel as ShadDropdownMenuLabel } from '@/components/shadcn-ui/dropdown-menu';\nimport { Bookmark, Clock, ArrowDownWideNarrow } from 'lucide-react';\n\nexport type GoToMenuItemProps = {\n handleSort: () => void;\n handleLocationHistory: () => void;\n handleBookmarks: () => void;\n};\n\nfunction GoToMenuItem({ handleSort, handleLocationHistory, handleBookmarks }: GoToMenuItemProps) {\n return (\n \n

    Go To

    \n
    \n \n \n \n
    \n
    \n );\n}\n\nexport default GoToMenuItem;\n","import BookChapterInput from '@/components/advanced/book-chapter-control/book-chapter-input.component';\nimport BookMenuItem, {\n BookType,\n} from '@/components/advanced/book-chapter-control/book-menu-item.component';\nimport ChapterSelect from '@/components/advanced/book-chapter-control/chapter-select.component';\nimport GoToMenuItem from '@/components/advanced/book-chapter-control/go-to-menu-item.component';\nimport {\n DropdownMenu as ShadDropdownMenu,\n DropdownMenuContent as ShadDropdownMenuContent,\n DropdownMenuLabel as ShadDropdownMenuLabel,\n DropdownMenuSeparator as ShadDropdownMenuSeparator,\n DropdownMenuTrigger as ShadDropdownMenuTrigger,\n} from '@/components/shadcn-ui/dropdown-menu';\nimport { Canon } from '@sillsdev/scripture';\nimport { ScriptureReference, getChaptersForBook } from 'platform-bible-utils';\nimport {\n KeyboardEvent as ReactKeyboardEvent,\n useCallback,\n useEffect,\n useLayoutEffect,\n useRef,\n useState,\n} from 'react';\n\ntype BookTypeLabels = {\n [bookType in BookType]: string;\n};\ntype BookChapterControlProps = {\n scrRef: ScriptureReference;\n handleSubmit: (scrRef: ScriptureReference) => void;\n};\n\nconst ALL_BOOK_IDS = Canon.allBookIds;\nconst BOOK_TYPE_LABELS: BookTypeLabels = {\n OT: 'Old Testament',\n NT: 'New Testament',\n DC: 'Deuterocanon',\n};\nconst BOOK_TYPE_ARRAY: BookType[] = ['OT', 'NT', 'DC'];\n// This is the height of three menu items to offset scrolling to the selected menu item\n// If you use menuItemRef.clientHeight- includes height of chapter div which is too big\nconst SCROLL_OFFSET = 32 + 32 + 32;\nconst SEARCH_QUERY_FORMATS = [\n /^(\\w+)$/i, // Matches a single word (book name or id)\n /^(\\w+)(?:\\s(\\d+))$/i, // Matches a word followed by a chapter number\n /^(\\w+)(?:\\s(\\d+):(\\d+))$/i, // Matches a word followed by a chapter and verse number\n];\nconst fetchGroupedBooks = (bookType: BookType) => {\n const groupedBooks = {\n OT: ALL_BOOK_IDS.filter((bookId) => Canon.isBookOT(bookId)),\n NT: ALL_BOOK_IDS.filter((bookId) => Canon.isBookNT(bookId)),\n DC: ALL_BOOK_IDS.filter((bookId) => Canon.isBookDC(bookId)),\n };\n return groupedBooks[bookType];\n};\nconst fetchEndChapter = (bookId: string) => {\n // getChaptersForBook returns -1 if not found in scrBookData\n // scrBookData only includes OT and NT, so all DC will return -1\n return getChaptersForBook(Canon.bookIdToNumber(bookId));\n};\n\n/**\n * Gets all of the English names from book ids\n *\n * @returns String[]\n */\nfunction getAllEnglishNames(): string[] {\n const allEnglishNames = ALL_BOOK_IDS.map((bookId) => {\n return Canon.bookIdToEnglishName(bookId);\n });\n return allEnglishNames;\n}\n\n/**\n * Determines if bookName is in allEnglishNames\n *\n * @param bookName Book English name\n * @returns True if bookName is included, false otherwise\n */\nfunction isValidBookEnglishName(bookName: string): boolean {\n return getAllEnglishNames().includes(bookName);\n}\n\n/**\n * Gets a bookId from given English name\n *\n * @param bookName Book English name\n * @returns BookId of provided bookName, undefined otherwise\n */\nfunction getBookIdFromEnglishName(bookName: string): string | undefined {\n // Convert bookName to lowercase and then capitalize the first letter\n const formattedBookName = bookName.toLowerCase().replace(/^\\w/, (c) => c.toUpperCase());\n\n if (isValidBookEnglishName(formattedBookName)) {\n const matchingBookId = ALL_BOOK_IDS.find((bookId) => {\n return Canon.bookIdToEnglishName(bookId) === formattedBookName;\n });\n return matchingBookId;\n }\n\n return undefined;\n}\n\nfunction BookChapterControl({ scrRef, handleSubmit }: BookChapterControlProps) {\n const [searchQuery, setSearchQuery] = useState('');\n const [selectedBookId, setSelectedBookId] = useState(\n Canon.bookNumberToId(scrRef.bookNum),\n );\n const [highlightedChapter, setHighlightedChapter] = useState(scrRef.chapterNum ?? 0);\n const [highlightedBookId, setHighlightedBookId] = useState(\n Canon.bookNumberToId(scrRef.bookNum),\n );\n const [isContentOpen, setIsContentOpen] = useState(false);\n const [isContentOpenDelayed, setIsContentOpenDelayed] = useState(isContentOpen);\n\n // This ref will always be defined\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const inputRef = useRef(undefined!);\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const contentRef = useRef(undefined!);\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const menuItemRef = useRef(undefined!);\n\n const fetchFilteredBooks = useCallback(\n (bookType: BookType) => {\n return fetchGroupedBooks(bookType).filter((bookId: string) => {\n const englishNameLowerCase = Canon.bookIdToEnglishName(bookId).toLowerCase();\n const normalizedQuery = searchQuery.replace(/[^a-zA-Z]/g, '').toLowerCase();\n return (\n englishNameLowerCase.includes(normalizedQuery) || // Match book name\n bookId.toLowerCase().includes(normalizedQuery) // Match book ID\n );\n });\n },\n [searchQuery],\n );\n\n const handleSearchInput = (searchString: string) => {\n setSearchQuery(searchString);\n };\n\n /**\n * Whether to prevent radix's logic from closing the dropdown. This is important because radix\n * tries to close the dropdown when the input first focuses, and we don't want it to do that. But\n * we don't want to prevent the dropdown from closing when we click away from the input, so we\n * don't want to just keep it open if the input is focused\n */\n const shouldPreventAutoClosing = useRef(false);\n\n const controlMenuState = useCallback((open: boolean) => {\n if (shouldPreventAutoClosing.current) {\n shouldPreventAutoClosing.current = false;\n return;\n }\n setIsContentOpen(open);\n }, []);\n\n const updateReference = useCallback(\n (bookId: string, shouldClose: boolean, chapter?: number, verse?: number) => {\n setHighlightedChapter(\n Canon.bookNumberToId(scrRef.bookNum) !== bookId ? 1 : scrRef.chapterNum,\n );\n\n if (shouldClose || fetchEndChapter(bookId) === -1) {\n handleSubmit({\n bookNum: Canon.bookIdToNumber(bookId),\n chapterNum: chapter || 1,\n verseNum: verse || 1,\n });\n\n setIsContentOpen(false);\n setSearchQuery('');\n return;\n }\n\n setSelectedBookId(selectedBookId !== bookId ? bookId : '');\n setIsContentOpen(!shouldClose);\n },\n [handleSubmit, scrRef.bookNum, scrRef.chapterNum, selectedBookId],\n );\n\n const handleSelectChapter = (chapterNumber: number) => {\n if (chapterNumber <= 0 || chapterNumber > fetchEndChapter(selectedBookId)) {\n return;\n }\n updateReference(selectedBookId, true, chapterNumber);\n };\n\n const handleInputSubmit = useCallback(() => {\n SEARCH_QUERY_FORMATS.forEach((format) => {\n const matches = searchQuery.match(format);\n if (matches) {\n // Book should be a bookId or an english name\n const [book, chapter = undefined, verse = undefined] = matches.slice(1);\n const englishName = getBookIdFromEnglishName(book);\n\n if (Canon.isBookIdValid(book) || englishName) {\n updateReference(\n englishName ?? book,\n true,\n chapter ? parseInt(chapter, 10) : 1,\n verse ? parseInt(verse, 10) : 1,\n );\n }\n }\n });\n }, [updateReference, searchQuery]);\n\n const handleKeyDownInput = useCallback(\n (event: ReactKeyboardEvent) => {\n if (!isContentOpen) {\n setIsContentOpen(true);\n } else if (event.key === 'ArrowDown' || event.key === 'ArrowUp') {\n if (\n typeof menuItemRef !== 'undefined' &&\n // Ref uses null\n // eslint-disable-next-line no-null/no-null\n menuItemRef.current !== null\n ) {\n menuItemRef.current.focus();\n } else if (\n typeof contentRef !== 'undefined' &&\n // Ref uses null\n // eslint-disable-next-line no-null/no-null\n contentRef.current !== null\n ) {\n contentRef.current.focus();\n }\n event.preventDefault();\n }\n },\n [isContentOpen],\n );\n\n const handleKeyDownContent = (event: ReactKeyboardEvent) => {\n // When the dropdown menu has focus, key strokes should give focus to the input component,\n // unless they're navigation keys (arrows and enter)\n const { key } = event;\n if (\n key === 'ArrowRight' ||\n key === 'ArrowLeft' ||\n key === 'ArrowDown' ||\n key === 'ArrowUp' ||\n key === 'Enter'\n ) {\n return;\n }\n\n inputRef.current.dispatchEvent(new KeyboardEvent('keydown', { key }));\n inputRef.current.focus();\n };\n\n const handleKeyDownMenuItem = (event: ReactKeyboardEvent) => {\n const { key } = event;\n if (highlightedBookId === selectedBookId) {\n if (key === 'Enter') {\n event.preventDefault();\n updateReference(selectedBookId, true, highlightedChapter);\n return;\n }\n\n let chapterOffSet = 0;\n if (key === 'ArrowRight') {\n if (highlightedChapter < fetchEndChapter(highlightedBookId)) {\n chapterOffSet = 1;\n } else {\n event.preventDefault();\n return;\n }\n } else if (key === 'ArrowLeft') {\n if (highlightedChapter > 1) {\n chapterOffSet = -1;\n } else {\n event.preventDefault();\n return;\n }\n } else if (key === 'ArrowDown') {\n chapterOffSet = 6;\n } else if (key === 'ArrowUp') {\n chapterOffSet = -6;\n }\n if (\n highlightedChapter + chapterOffSet <= 0 ||\n highlightedChapter + chapterOffSet > fetchEndChapter(highlightedBookId)\n ) {\n setHighlightedChapter(0);\n } else if (chapterOffSet !== 0) {\n setHighlightedChapter(highlightedChapter + chapterOffSet);\n event.preventDefault();\n }\n }\n };\n\n useEffect(() => {\n if (selectedBookId === highlightedBookId) {\n if (selectedBookId === Canon.bookNumberToId(scrRef.bookNum)) {\n setHighlightedChapter(scrRef.chapterNum);\n } else {\n setHighlightedChapter(1);\n }\n } else {\n setHighlightedChapter(0);\n }\n }, [highlightedBookId, scrRef.bookNum, scrRef.chapterNum, selectedBookId]);\n\n // The purpose of these useLayoutEffects and timeout is to delay the scroll just\n // enough so that the refs are defined and available when they are used after the timeout\n useLayoutEffect(() => {\n setIsContentOpenDelayed(isContentOpen);\n }, [isContentOpen]);\n\n useLayoutEffect(() => {\n const scrollTimeout = setTimeout(() => {\n if (isContentOpenDelayed && contentRef.current && menuItemRef.current) {\n const menuItemOffsetTop = menuItemRef.current.offsetTop;\n const scrollPosition = menuItemOffsetTop - SCROLL_OFFSET;\n contentRef.current.scrollTo({ top: scrollPosition, behavior: 'instant' });\n }\n }, 10);\n return () => {\n clearTimeout(scrollTimeout);\n };\n }, [isContentOpenDelayed]);\n\n return (\n
    \n \n \n {\n setSelectedBookId(Canon.bookNumberToId(scrRef.bookNum));\n setHighlightedBookId(Canon.bookNumberToId(scrRef.bookNum));\n setHighlightedChapter(scrRef.chapterNum > 0 ? scrRef.chapterNum : 0);\n setIsContentOpen(true);\n inputRef.current.focus();\n }}\n onFocus={() => {\n // Radix thinks we want to close because the input is being focused. Prevent that\n shouldPreventAutoClosing.current = true;\n }}\n handleSubmit={handleInputSubmit}\n placeholder={`${Canon.bookNumberToEnglishName(scrRef.bookNum)} ${scrRef.chapterNum}:${scrRef.verseNum}`}\n />\n \n \n console.log('sorting')}\n handleLocationHistory={() => console.log('location history')}\n handleBookmarks={() => console.log('bookmarks')}\n />\n {BOOK_TYPE_ARRAY.map(\n (bookType, bookTypeIndex) =>\n fetchFilteredBooks(bookType).length > 0 && (\n
    \n \n {BOOK_TYPE_LABELS[bookType]}\n \n\n {fetchFilteredBooks(bookType).map((bookId) => (\n
    \n updateReference(bookId, false)}\n isSelected={selectedBookId === bookId}\n handleHighlightBook={() => setHighlightedBookId(bookId)}\n handleKeyDown={handleKeyDownMenuItem}\n bookType={bookType}\n ref={(element: HTMLDivElement) => {\n if (selectedBookId === bookId) menuItemRef.current = element;\n }}\n >\n {\n setHighlightedChapter(chapterNumber);\n }}\n />\n \n
    \n ))}\n {BOOK_TYPE_ARRAY.length - 1 !== bookTypeIndex ? (\n \n ) : undefined}\n
    \n ),\n )}\n \n
    \n
    \n );\n}\n\nexport default BookChapterControl;\n","import React from 'react';\nimport { Slot } from '@radix-ui/react-slot';\nimport { cva, type VariantProps } from 'class-variance-authority';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport const buttonVariants = cva(\n 'pr-twp tw-inline-flex tw-items-center tw-justify-center tw-whitespace-nowrap tw-rounded-md tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-colors focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50',\n {\n variants: {\n variant: {\n default: 'tw-bg-primary tw-text-primary-foreground hover:tw-bg-primary/90',\n destructive: 'tw-bg-destructive tw-text-destructive-foreground hover:tw-bg-destructive/90',\n outline:\n 'tw-border tw-border-input tw-bg-background hover:tw-bg-accent hover:tw-text-accent-foreground',\n secondary: 'tw-bg-secondary tw-text-secondary-foreground hover:tw-bg-secondary/80',\n ghost: 'hover:tw-bg-accent hover:tw-text-accent-foreground',\n link: 'tw-text-primary tw-underline-offset-4 hover:tw-underline',\n },\n size: {\n default: 'tw-h-10 tw-px-4 tw-py-2',\n sm: 'tw-h-9 tw-rounded-md tw-px-3',\n lg: 'tw-h-11 tw-rounded-md tw-px-8',\n icon: 'tw-h-10 tw-w-10',\n },\n },\n defaultVariants: {\n variant: 'default',\n size: 'default',\n },\n },\n);\n\nexport interface ButtonProps\n extends React.ButtonHTMLAttributes,\n VariantProps {\n asChild?: boolean;\n}\n\nexport const Button = React.forwardRef(\n ({ className, variant, size, asChild = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'button';\n return (\n \n );\n },\n);\nButton.displayName = 'Button';\n","import React from 'react';\nimport * as LabelPrimitive from '@radix-ui/react-label';\nimport { cva, type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst labelVariants = cva(\n 'tw-text-sm tw-font-medium tw-leading-none peer-disabled:tw-cursor-not-allowed peer-disabled:tw-opacity-70',\n);\n\nexport const Label = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef & VariantProps\n>(({ className, ...props }, ref) => (\n \n));\nLabel.displayName = LabelPrimitive.Root.displayName;\n","import React from 'react';\nimport * as RadioGroupPrimitive from '@radix-ui/react-radio-group';\nimport { Circle } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst RadioGroup = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => {\n return (\n \n );\n});\nRadioGroup.displayName = RadioGroupPrimitive.Root.displayName;\n\nconst RadioGroupItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => {\n return (\n \n \n \n \n \n );\n});\nRadioGroupItem.displayName = RadioGroupPrimitive.Item.displayName;\n\nexport { RadioGroup, RadioGroupItem };\n","import React from 'react';\nimport * as PopoverPrimitive from '@radix-ui/react-popover';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Popover = PopoverPrimitive.Root;\n\nconst PopoverTrigger = PopoverPrimitive.Trigger;\n\nconst PopoverContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, align = 'center', sideOffset = 4, ...props }, ref) => (\n \n \n \n));\nPopoverContent.displayName = PopoverPrimitive.Content.displayName;\n\nexport { Popover, PopoverTrigger, PopoverContent };\n","import React from 'react';\nimport * as DialogPrimitive from '@radix-ui/react-dialog';\nimport { X } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Dialog = DialogPrimitive.Root;\n\nconst DialogTrigger = DialogPrimitive.Trigger;\n\nconst DialogPortal = DialogPrimitive.Portal;\n\nconst DialogClose = DialogPrimitive.Close;\n\nconst DialogOverlay = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nDialogOverlay.displayName = DialogPrimitive.Overlay.displayName;\n\nconst DialogContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, ...props }, ref) => (\n \n \n \n {children}\n \n \n Close\n \n \n \n));\nDialogContent.displayName = DialogPrimitive.Content.displayName;\n\nfunction DialogHeader({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nDialogHeader.displayName = 'DialogHeader';\n\nfunction DialogFooter({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nDialogFooter.displayName = 'DialogFooter';\n\nconst DialogTitle = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nDialogTitle.displayName = DialogPrimitive.Title.displayName;\n\nconst DialogDescription = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nDialogDescription.displayName = DialogPrimitive.Description.displayName;\n\nexport {\n Dialog,\n DialogPortal,\n DialogOverlay,\n DialogClose,\n DialogTrigger,\n DialogContent,\n DialogHeader,\n DialogFooter,\n DialogTitle,\n DialogDescription,\n};\n","import React from 'react';\nimport { type DialogProps } from '@radix-ui/react-dialog';\nimport { Command as CommandPrimitive } from 'cmdk';\nimport { Search } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Dialog, DialogContent } from '@/components/shadcn-ui/dialog';\n\nconst Command = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nCommand.displayName = CommandPrimitive.displayName;\n\ninterface CommandDialogProps extends DialogProps {}\n\nfunction CommandDialog({ children, ...props }: CommandDialogProps) {\n return (\n \n \n \n {children}\n \n \n \n );\n}\n\nconst CommandInput = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n
    \n \n \n
    \n));\n\nCommandInput.displayName = CommandPrimitive.Input.displayName;\n\nconst CommandList = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\n\nCommandList.displayName = CommandPrimitive.List.displayName;\n\nconst CommandEmpty = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>((props, ref) => (\n \n));\n\nCommandEmpty.displayName = CommandPrimitive.Empty.displayName;\n\nconst CommandGroup = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\n\nCommandGroup.displayName = CommandPrimitive.Group.displayName;\n\nconst CommandSeparator = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nCommandSeparator.displayName = CommandPrimitive.Separator.displayName;\n\nconst CommandItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\n\nCommandItem.displayName = CommandPrimitive.Item.displayName;\n\nfunction CommandShortcut({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nCommandShortcut.displayName = 'CommandShortcut';\n\nexport {\n Command,\n CommandDialog,\n CommandInput,\n CommandList,\n CommandEmpty,\n CommandGroup,\n CommandItem,\n CommandShortcut,\n CommandSeparator,\n};\n","import { useState } from 'react';\nimport { Check, ChevronsUpDown } from 'lucide-react';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport { Popover, PopoverContent, PopoverTrigger } from '@/components/shadcn-ui/popover';\nimport {\n Command,\n CommandEmpty,\n CommandInput,\n CommandItem,\n CommandList,\n} from '@/components/shadcn-ui/command';\nimport { PopoverProps } from '@radix-ui/react-popover';\n\nexport type ComboBoxLabelOption = { label: string };\nexport type ComboBoxOption = string | number | ComboBoxLabelOption;\n\nexport type ComboBoxProps = {\n /** Optional unique identifier */\n id?: string;\n /** Text label title for combobox */\n /** List of available options for the dropdown menu */\n options?: readonly T[];\n /** @deprecated 3 December 2024. Renamed to {@link buttonClassName} */\n className?: string;\n /** Additional css classes to help with unique styling of the combo box button */\n buttonClassName?: string;\n /** Additional css classes to help with unique styling of the combo box popover */\n popoverContentClassName?: string;\n /**\n * The selected value that the combo box currently holds. Must be shallow equal to one of the\n * options entries.\n */\n value?: T;\n /** Triggers when content of textfield is changed */\n onChange?: (newValue: T) => void;\n /** Used to determine the string value for a given option. */\n getOptionLabel?: (option: ComboBoxOption) => string;\n /** Text displayed on button if `value` is undefined */\n buttonPlaceholder?: string;\n /** Placeholder text for text field */\n textPlaceholder?: string;\n /** Text to display when no options match input */\n commandEmptyMessage?: string;\n /** Variant of button */\n buttonVariant?: ButtonProps['variant'];\n /** Text direction ltr or rtl */\n dir?: Direction;\n /** Optional boolean to set if trigger should be disabled */\n isDisabled?: boolean;\n} & PopoverProps;\n\ntype Direction = 'ltr' | 'rtl';\n\nfunction getOptionLabelDefault(option: ComboBoxOption): string {\n if (typeof option === 'string') {\n return option;\n }\n if (typeof option === 'number') {\n return option.toString();\n }\n return option.label;\n}\n\n/**\n * Autocomplete input and command palette with a list of suggestions.\n *\n * Thanks to Shadcn for heavy inspiration and documentation\n * https://ui.shadcn.com/docs/components/combobox\n */\nfunction ComboBox({\n id,\n options = [],\n buttonClassName,\n popoverContentClassName,\n value,\n onChange = () => {},\n getOptionLabel = getOptionLabelDefault,\n buttonPlaceholder = '',\n textPlaceholder = '',\n commandEmptyMessage = 'No option found',\n buttonVariant = 'outline',\n dir = 'ltr',\n isDisabled = false,\n ...props\n}: ComboBoxProps) {\n const [open, setOpen] = useState(false);\n\n return (\n \n \n \n \n {value ? getOptionLabel(value) : buttonPlaceholder}\n \n \n \n \n \n \n \n {commandEmptyMessage}\n \n {options.map((option) => (\n {\n onChange(option);\n setOpen(false);\n }}\n >\n \n {getOptionLabel(option)}\n \n ))}\n \n \n \n \n );\n}\n\nexport default ComboBox;\n","import { useMemo } from 'react';\nimport ComboBox from '@/components/basics/combo-box.component';\nimport { Label } from '@/components/shadcn-ui/label';\n\nexport type ChapterRangeSelectorProps = {\n startChapter: number;\n endChapter: number;\n handleSelectStartChapter: (chapter: number) => void;\n handleSelectEndChapter: (chapter: number) => void;\n isDisabled?: boolean;\n chapterCount: number;\n};\n\nexport default function ChapterRangeSelector({\n startChapter,\n endChapter,\n handleSelectStartChapter,\n handleSelectEndChapter,\n isDisabled = false,\n chapterCount,\n}: ChapterRangeSelectorProps) {\n const chapterOptions = useMemo(\n () => Array.from({ length: chapterCount }, (_, index) => index + 1),\n [chapterCount],\n );\n\n const onChangeStartChapter = (value: number) => {\n handleSelectStartChapter(value);\n if (value > endChapter) {\n handleSelectEndChapter(value);\n }\n };\n\n const onChangeEndChapter = (value: number) => {\n handleSelectEndChapter(value);\n if (value < startChapter) {\n handleSelectStartChapter(value);\n }\n };\n\n return (\n <>\n \n option.toString()}\n value={startChapter}\n />\n\n \n option.toString()}\n value={endChapter}\n />\n \n );\n}\n","import { Button } from '@/components/shadcn-ui/button';\nimport { Label } from '@/components/shadcn-ui/label';\nimport { RadioGroup, RadioGroupItem } from '@/components/shadcn-ui/radio-group';\nimport { Canon } from '@sillsdev/scripture';\nimport { LocalizedStringValue } from 'platform-bible-utils';\nimport { useState } from 'react';\nimport ChapterRangeSelector, {\n ChapterRangeSelectorProps,\n} from '../basics/chapter-range-selector.component';\n\nexport enum BookSelectionMode {\n CURRENT_BOOK = 'current book',\n CHOOSE_BOOKS = 'choose books',\n}\n\n/**\n * Object containing all keys used for localization in this component. If you're using this\n * component in an extension, you can pass it into the useLocalizedStrings hook to easily obtain the\n * localized strings and pass them into the localizedStrings prop of this component\n */\nexport const BOOK_SELECTOR_STRING_KEYS = Object.freeze([\n '%webView_bookSelector_currentBook%',\n '%webView_bookSelector_choose%',\n '%webView_bookSelector_chooseBooks%',\n] as const);\n\nexport type BookSelectorLocalizedStrings = {\n [localizedInventoryKey in (typeof BOOK_SELECTOR_STRING_KEYS)[number]]?: LocalizedStringValue;\n};\n\n/**\n * Gets the localized value for the provided key\n *\n * @param strings Object containing localized string\n * @param key Key for a localized string\n * @returns The localized value for the provided key, if available. Returns the key if no localized\n * value is available\n */\nconst localizeString = (\n strings: BookSelectorLocalizedStrings,\n key: keyof BookSelectorLocalizedStrings,\n) => {\n return strings[key] ?? key;\n};\n\ntype BookSelectorProps = ChapterRangeSelectorProps & {\n handleBookSelectionModeChange: (newMode: BookSelectionMode) => void;\n currentBookName: string;\n onSelectBooks: () => void;\n selectedBookIds: string[];\n localizedStrings: BookSelectorLocalizedStrings;\n};\n\nexport default function BookSelector({\n handleBookSelectionModeChange,\n currentBookName,\n onSelectBooks,\n selectedBookIds,\n chapterCount,\n endChapter,\n handleSelectEndChapter,\n startChapter,\n handleSelectStartChapter,\n localizedStrings,\n}: BookSelectorProps) {\n const currentBookText = localizeString(localizedStrings, '%webView_bookSelector_currentBook%');\n const chooseText = localizeString(localizedStrings, '%webView_bookSelector_choose%');\n const chooseBooksText = localizeString(localizedStrings, '%webView_bookSelector_chooseBooks%');\n\n const [bookSelectionMode, setBookSelectionMode] = useState(\n BookSelectionMode.CURRENT_BOOK,\n );\n\n const onSelectionModeChange = (newMode: BookSelectionMode) => {\n setBookSelectionMode(newMode);\n handleBookSelectionModeChange(newMode);\n };\n\n return (\n onSelectionModeChange(value as BookSelectionMode)}\n >\n
    \n
    \n
    \n \n \n
    \n \n
    \n \n
    \n
    \n
    \n
    \n \n \n
    \n \n onSelectBooks()}\n >\n {chooseText}\n \n
    \n
    \n \n );\n}\n","import { DropdownMenuTrigger } from '@radix-ui/react-dropdown-menu';\nimport { FilterIcon } from 'lucide-react';\nimport { Table } from '@tanstack/react-table';\n\nimport { Button } from '@/components/shadcn-ui/button';\nimport {\n DropdownMenu,\n DropdownMenuCheckboxItem,\n DropdownMenuContent,\n DropdownMenuLabel,\n DropdownMenuSeparator,\n} from '@/components/shadcn-ui/dropdown-menu';\n\ninterface DataTableViewOptionsProps {\n table: Table;\n}\n\nfunction DataTableViewOptions({ table }: DataTableViewOptionsProps) {\n return (\n \n \n \n \n \n Toggle columns\n \n {table\n .getAllColumns()\n .filter((column) => column.getCanHide())\n .map((column) => {\n return (\n column.toggleVisibility(!!value)}\n >\n {column.id}\n \n );\n })}\n \n \n );\n}\n\nexport default DataTableViewOptions;\n","import React from 'react';\nimport * as SelectPrimitive from '@radix-ui/react-select';\nimport { Check, ChevronDown, ChevronUp } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Select = SelectPrimitive.Root;\n\nconst SelectGroup = SelectPrimitive.Group;\n\nconst SelectValue = SelectPrimitive.Value;\n\nconst SelectTrigger = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, ...props }, ref) => (\n span]:tw-line-clamp-1',\n className,\n )}\n {...props}\n >\n {children}\n \n \n \n \n));\nSelectTrigger.displayName = SelectPrimitive.Trigger.displayName;\n\nconst SelectScrollUpButton = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n));\nSelectScrollUpButton.displayName = SelectPrimitive.ScrollUpButton.displayName;\n\nconst SelectScrollDownButton = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n));\nSelectScrollDownButton.displayName = SelectPrimitive.ScrollDownButton.displayName;\n\nconst SelectContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, position = 'popper', ...props }, ref) => (\n \n \n \n \n {children}\n \n \n \n \n));\nSelectContent.displayName = SelectPrimitive.Content.displayName;\n\nconst SelectLabel = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSelectLabel.displayName = SelectPrimitive.Label.displayName;\n\nconst SelectItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, ...props }, ref) => (\n \n \n \n \n \n \n\n {children}\n \n));\nSelectItem.displayName = SelectPrimitive.Item.displayName;\n\nconst SelectSeparator = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSelectSeparator.displayName = SelectPrimitive.Separator.displayName;\n\nexport {\n Select,\n SelectGroup,\n SelectValue,\n SelectTrigger,\n SelectContent,\n SelectLabel,\n SelectItem,\n SelectSeparator,\n SelectScrollUpButton,\n SelectScrollDownButton,\n};\n","import { ChevronLeftIcon, ChevronRightIcon, ArrowLeftIcon, ArrowRightIcon } from 'lucide-react';\nimport { Table } from '@tanstack/react-table';\n\nimport { Button } from '@/components/shadcn-ui/button';\nimport {\n Select,\n SelectContent,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\n\ninterface DataTablePaginationProps {\n table: Table;\n}\n\nfunction DataTablePagination({ table }: DataTablePaginationProps) {\n return (\n
    \n
    \n
    \n {table.getFilteredSelectedRowModel().rows.length} of{' '}\n {table.getFilteredRowModel().rows.length} row(s) selected\n
    \n
    \n

    Rows per page

    \n {\n table.setPageSize(Number(value));\n }}\n >\n \n \n \n \n {[10, 20, 30, 40, 50].map((pageSize) => (\n \n {pageSize}\n \n ))}\n \n \n
    \n
    \n Page {table.getState().pagination.pageIndex + 1} of {table.getPageCount()}\n
    \n
    \n table.setPageIndex(0)}\n disabled={!table.getCanPreviousPage()}\n >\n Go to first page\n \n \n table.previousPage()}\n disabled={!table.getCanPreviousPage()}\n >\n Go to previous page\n \n \n table.nextPage()}\n disabled={!table.getCanNextPage()}\n >\n Go to next page\n \n \n table.setPageIndex(table.getPageCount() - 1)}\n disabled={!table.getCanNextPage()}\n >\n Go to last page\n \n \n
    \n
    \n
    \n );\n}\n\nexport default DataTablePagination;\n","import React from 'react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Table = React.forwardRef<\n HTMLTableElement,\n React.HTMLAttributes & { stickyHeader?: boolean }\n>(({ className, stickyHeader, ...props }, ref) => (\n
    \n \n
    \n));\nTable.displayName = 'Table';\n\nconst TableHeader = React.forwardRef<\n HTMLTableSectionElement,\n React.HTMLAttributes & { stickyHeader?: boolean }\n>(({ className, stickyHeader, ...props }, ref) => (\n \n));\nTableHeader.displayName = 'TableHeader';\n\nconst TableBody = React.forwardRef<\n HTMLTableSectionElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableBody.displayName = 'TableBody';\n\nconst TableFooter = React.forwardRef<\n HTMLTableSectionElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n tr]:last:tw-border-b-0', className)}\n {...props}\n />\n));\nTableFooter.displayName = 'TableFooter';\n\nconst TableRow = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nTableRow.displayName = 'TableRow';\n\nconst TableHead = React.forwardRef<\n HTMLTableCellElement,\n React.ThHTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableHead.displayName = 'TableHead';\n\nconst TableCell = React.forwardRef<\n HTMLTableCellElement,\n React.TdHTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableCell.displayName = 'TableCell';\n\nconst TableCaption = React.forwardRef<\n HTMLTableCaptionElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableCaption.displayName = 'TableCaption';\n\nexport { Table, TableHeader, TableBody, TableFooter, TableHead, TableRow, TableCell, TableCaption };\n","import { useState } from 'react';\n\nimport {\n ColumnFiltersState,\n flexRender,\n getCoreRowModel,\n getFilteredRowModel,\n getPaginationRowModel,\n getSortedRowModel,\n SortingState,\n ColumnDef as TSColumnDef,\n Row as TSRow,\n RowSelectionState as TSRowSelectionState,\n SortDirection as TSSortDirection,\n Table as TSTable,\n useReactTable,\n VisibilityState,\n} from '@tanstack/react-table';\n\nimport DataTableViewOptions from '@/components/advanced/data-table/data-table-column-toggle.component';\nimport DataTablePagination from '@/components/advanced/data-table/data-table-pagination.component';\nimport { Button } from '@/components/shadcn-ui/button';\nimport {\n Table,\n TableBody,\n TableCell,\n TableHead,\n TableHeader,\n TableRow,\n} from '@/components/shadcn-ui/table';\n\nexport type ColumnDef = TSColumnDef;\nexport type RowContents = TSRow;\nexport type TableContents = TSTable;\nexport type SortDirection = TSSortDirection;\nexport type RowSelectionState = TSRowSelectionState;\n\ninterface DataTableProps {\n columns: ColumnDef[];\n data: TData[];\n enablePagination?: boolean;\n showPaginationControls?: boolean;\n showColumnVisibilityControls?: boolean;\n stickyHeader?: boolean;\n onRowClickHandler?: (row: RowContents, table: TableContents) => void;\n}\n\n/**\n * Feature-rich table component that infuses our basic shadcn-based Table component with features\n * from TanStack's React Table library\n */\nfunction DataTable({\n columns,\n data,\n enablePagination = false,\n showPaginationControls = false,\n showColumnVisibilityControls = false,\n stickyHeader = false,\n onRowClickHandler = () => {},\n}: DataTableProps) {\n const [sorting, setSorting] = useState([]);\n const [columnFilters, setColumnFilters] = useState([]);\n const [columnVisibility, setColumnVisibility] = useState({});\n const [rowSelection, setRowSelection] = useState({});\n\n const table = useReactTable({\n data,\n columns,\n getCoreRowModel: getCoreRowModel(),\n ...(enablePagination && { getPaginationRowModel: getPaginationRowModel() }),\n onSortingChange: setSorting,\n getSortedRowModel: getSortedRowModel(),\n onColumnFiltersChange: setColumnFilters,\n getFilteredRowModel: getFilteredRowModel(),\n onColumnVisibilityChange: setColumnVisibility,\n onRowSelectionChange: setRowSelection,\n state: {\n sorting,\n columnFilters,\n columnVisibility,\n rowSelection,\n },\n });\n\n return (\n
    \n {showColumnVisibilityControls && }\n \n \n {table.getHeaderGroups().map((headerGroup) => (\n \n {headerGroup.headers.map((header) => {\n return (\n \n {header.isPlaceholder\n ? undefined\n : flexRender(header.column.columnDef.header, header.getContext())}\n \n );\n })}\n \n ))}\n \n \n {table.getRowModel().rows?.length ? (\n table.getRowModel().rows.map((row) => (\n onRowClickHandler(row, table)}\n key={row.id}\n data-state={row.getIsSelected() && 'selected'}\n >\n {row.getVisibleCells().map((cell) => (\n \n {flexRender(cell.column.columnDef.cell, cell.getContext())}\n \n ))}\n \n ))\n ) : (\n \n \n No results.\n \n \n )}\n \n
    \n {enablePagination && (\n
    \n table.previousPage()}\n disabled={!table.getCanPreviousPage()}\n >\n Previous\n \n table.nextPage()}\n disabled={!table.getCanNextPage()}\n >\n Next\n \n
    \n )}\n {enablePagination && showPaginationControls && }\n
    \n );\n}\n\nexport default DataTable;\n","import {\n Table,\n TableBody,\n TableCell,\n TableHead,\n TableHeader,\n TableRow,\n} from '@/components/shadcn-ui/table';\nimport { Canon } from '@sillsdev/scripture';\nimport { deepEqual, LanguageStrings, ScriptureReference } from 'platform-bible-utils';\nimport { useMemo } from 'react';\nimport { InventoryItemOccurrence } from './inventory-utils';\n\n/** Props for the OccurrencesTable component */\ntype OccurrencesTableProps = {\n /** Data that contains scriptures references and snippets of scripture */\n occurrenceData: InventoryItemOccurrence[];\n /** Callback function that is executed when the scripture reference is changed */\n setScriptureReference: (scriptureReference: ScriptureReference) => void;\n /**\n * Object with all localized strings that the OccurrencesTable needs to work well across multiple\n * languages\n */\n localizedStrings: LanguageStrings;\n};\n\n/**\n * Table that shows occurrences of specified inventory item(s). The first column shows the related\n * scripture reference. The second column shows the snippet of scripture that contains the specified\n * inventory item\n */\nfunction OccurrencesTable({\n occurrenceData,\n setScriptureReference,\n localizedStrings,\n}: OccurrencesTableProps) {\n const referenceHeaderText =\n localizedStrings['%webView_inventory_occurrences_table_header_reference%'];\n const occurrenceHeaderText =\n localizedStrings['%webView_inventory_occurrences_table_header_occurrence%'];\n\n const occurrences: InventoryItemOccurrence[] = useMemo(() => {\n const uniqueOccurrences: InventoryItemOccurrence[] = [];\n\n occurrenceData.forEach((occurrence) => {\n if (!uniqueOccurrences.some((uniqueOccurrence) => deepEqual(uniqueOccurrence, occurrence))) {\n uniqueOccurrences.push(occurrence);\n }\n });\n\n return uniqueOccurrences;\n }, [occurrenceData]);\n\n return (\n \n \n \n {referenceHeaderText}\n {occurrenceHeaderText}\n \n \n \n {occurrences.length > 0 &&\n occurrences.map((occurrence) => (\n {\n setScriptureReference(occurrence.reference);\n }}\n >\n {`${Canon.bookNumberToEnglishName(occurrence.reference.bookNum)} ${occurrence.reference.chapterNum}:${occurrence.reference.verseNum}`}\n {occurrence.text}\n \n ))}\n \n
    \n );\n}\n\nexport default OccurrencesTable;\n","import React from 'react';\nimport * as CheckboxPrimitive from '@radix-ui/react-checkbox';\nimport { Check } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Checkbox = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n \n \n));\nCheckbox.displayName = CheckboxPrimitive.Root.displayName;\n\nexport default Checkbox;\n","import { Canon } from '@sillsdev/scripture';\nimport { ScriptureReference } from 'platform-bible-utils';\n\n/* #region Types */\n\n/**\n * Status of items that appear in inventories. 'approved' and 'unapproved' items are defined in the\n * project's `Settings.xml`. All other items are defined as 'unknown'\n */\nexport type Status = 'approved' | 'unapproved' | 'unknown';\n\n/** Occurrence of item in inventory. Primarily used by table that shows occurrences */\nexport type InventoryItemOccurrence = {\n /** Reference to scripture where the item appears */\n reference: ScriptureReference;\n /** Snippet of scripture that contains the occurrence */\n text: string;\n};\n\n/** Data structure that contains all information on an item that is shown in an inventory */\nexport type InventoryTableData = {\n /**\n * The item (e.g. a character in the characters inventory, a marker in the marker inventory) In\n * most cases the array will only have one element. In case of additional items (e.g. the\n * preceding marker in the markers check), the primary item should be stored in the first index.\n * To show additional items in the inventory, make sure to configure the `additionalItemsLabels`\n * prop for the Inventory component\n */\n items: string[];\n /** The number of times this item occurs in the selected scope */\n count: number;\n /** The status of this item (see documentation for `Status` type for more information) */\n status: Status;\n /** Occurrences of this item in the scripture text for the selected scope */\n occurrences: InventoryItemOccurrence[];\n};\n\n/* #endregion */\n\n/* #region Functions */\n\n/**\n * Splits USFM string into shorter line-like segments\n *\n * @param text A single (likely very large) USFM string\n * @returns An array containing the input text, split into shorter segments\n */\nexport const getLinesFromUSFM = (text: string) => {\n // Splits on (CR)LF, CR, \\v, \\c and \\id\n return text.split(/(?:\\r?\\n|\\r)|(?=(?:\\\\(?:v|c|id)))/g);\n};\n\n/**\n * Extracts chapter or verse number from USFM strings that start with a \\c or \\v marker\n *\n * @param text USFM string that is expected to start with \\c or \\v marker\n * @returns Chapter or verse number if one is found. Else returns 0.\n */\nexport const getNumberFromUSFM = (text: string): number | undefined => {\n // Captures all digits that follow \\v or \\c markers followed by whitespace located at the start of a string\n const regex = /^\\\\[vc]\\s+(\\d+)/;\n const match = text.match(regex);\n\n if (match) {\n return +match[1];\n }\n return undefined;\n};\n\n/**\n * Gets book ID from USFM string that starts with the \\id marker, and returns book number for it\n *\n * @param text USFM string that is expected to start with \\id marker\n * @returns Book number corresponding to the \\id marker in the input text. Returns 0 if no marker is\n * found or the marker is not valid\n */\nexport const getBookNumFromId = (text: string): number => {\n // Captures all digits that follow an \\id marker followed by whitespace located at the start of a string\n const match = text.match(/^\\\\id\\s+([A-Za-z]+)/);\n if (match) {\n return Canon.bookIdToNumber(match[1]);\n }\n return 0;\n};\n\n/**\n * Gets the status for an item, typically used in the Inventory component\n *\n * @param item The item for which the status is being requested\n * @param approvedItems Array of approved items, typically as defined in `Settings.xml`\n * @param unapprovedItems Array of unapproved items, typically as defined in `Settings.xml`\n * @returns The status for the specified item\n */\nexport const getStatusForItem = (\n item: string,\n approvedItems: string[],\n unapprovedItems: string[],\n): Status => {\n if (unapprovedItems.includes(item)) return 'unapproved';\n if (approvedItems.includes(item)) return 'approved';\n return 'unknown';\n};\n\n/* #endregion */\n","import React from 'react';\nimport * as TogglePrimitive from '@radix-ui/react-toggle';\nimport { cva, type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst toggleVariants = cva(\n 'pr-twp tw-inline-flex tw-items-center tw-justify-center tw-rounded-md tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-colors hover:tw-bg-muted hover:tw-text-muted-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50 data-[state=on]:tw-bg-accent data-[state=on]:tw-text-accent-foreground',\n {\n variants: {\n variant: {\n default: 'tw-bg-transparent',\n outline:\n 'tw-border tw-border-input tw-bg-transparent hover:tw-bg-accent hover:tw-text-accent-foreground',\n },\n size: {\n default: 'tw-h-10 tw-px-3',\n sm: 'tw-h-9 tw-px-2.5',\n lg: 'tw-h-11 tw-px-5',\n },\n },\n defaultVariants: {\n variant: 'default',\n size: 'default',\n },\n },\n);\n\nconst Toggle = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef & VariantProps\n>(({ className, variant, size, ...props }, ref) => (\n \n));\n\nToggle.displayName = TogglePrimitive.Root.displayName;\n\nexport { Toggle, toggleVariants };\n","import React from 'react';\nimport * as ToggleGroupPrimitive from '@radix-ui/react-toggle-group';\nimport { type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { toggleVariants } from '@/components/shadcn-ui/toggle';\n\nconst ToggleGroupContext = React.createContext>({\n size: 'default',\n variant: 'default',\n});\n\nconst ToggleGroup = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef &\n VariantProps\n>(({ className, variant, size, children, ...props }, ref) => (\n \n \n {children}\n \n \n));\n\nToggleGroup.displayName = ToggleGroupPrimitive.Root.displayName;\n\nconst ToggleGroupItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef &\n VariantProps\n>(({ className, children, variant, size, ...props }, ref) => {\n const context = React.useContext(ToggleGroupContext);\n\n return (\n \n {children}\n \n );\n});\n\nToggleGroupItem.displayName = ToggleGroupPrimitive.Item.displayName;\n\nexport { ToggleGroup, ToggleGroupItem };\n","import { ColumnDef, SortDirection } from '@/components/advanced/data-table/data-table.component';\nimport { Button } from '@/components/shadcn-ui/button';\nimport { ToggleGroup, ToggleGroupItem } from '@/components/shadcn-ui/toggle-group';\nimport {\n ArrowDownIcon,\n ArrowUpDownIcon,\n ArrowUpIcon,\n CircleCheckIcon,\n CircleHelpIcon,\n CircleXIcon,\n} from 'lucide-react';\nimport { ReactNode } from 'react';\nimport { InventoryTableData, Status } from './inventory-utils';\n\n/**\n * Gets an icon that indicates the current sorting direction based on the provided input\n *\n * @param sortDirection Sorting direction. Can be ascending ('asc'), descending ('desc') or false (\n * i.e. not sorted)\n * @returns The appropriate sorting icon for the provided sorting direction\n */\nconst getSortingIcon = (sortDirection: false | SortDirection): ReactNode => {\n if (sortDirection === 'asc') {\n return ;\n }\n if (sortDirection === 'desc') {\n return ;\n }\n return ;\n};\n\n/**\n * Function that creates the item column for inventories\n *\n * @param itemLabel Localized label for the item column (e.g. 'Character', 'Repeated Word', etc.)\n * @returns Column that shows the inventory items. Should be used with the DataTable component\n */\nexport const inventoryItemColumn = (itemLabel: string): ColumnDef => {\n return {\n accessorKey: 'item',\n accessorFn: (row: InventoryTableData) => row.items[0],\n header: ({ column }) => (\n \n ),\n };\n};\n\n/**\n * Function that creates the additional item columns for inventories\n *\n * @param additionalItemLabel Localized label for the additional item column (e.g. 'Preceding\n * Marker')\n * @param additionalItemIndex Index that locates the desired item in the items array of the\n * inventory\n * @returns Column that shows additional inventory items. Should be used with the DataTable\n * component\n */\nexport const inventoryAdditionalItemColumn = (\n additionalItemLabel: string,\n additionalItemIndex: number,\n): ColumnDef => {\n return {\n accessorKey: `item${additionalItemIndex}`,\n accessorFn: (row: InventoryTableData) => row.items[additionalItemIndex],\n header: ({ column }) => (\n \n ),\n };\n};\n\n/**\n * Function that creates the count column for inventories. Should be used with the DataTable\n * component.\n *\n * @param itemLabel Localized label for the count column\n * @returns Column that shows the number of occurrences of the related inventory items\n */\nexport const inventoryCountColumn = (countLabel: string): ColumnDef => {\n return {\n accessorKey: 'count',\n header: ({ column }) => (\n
    \n \n
    \n ),\n cell: ({ row }) =>
    {row.getValue('count')}
    ,\n };\n};\n\n/**\n * Function that updates project settings when status for item(s) changes\n *\n * @param changedItems Array of items for which the status is being updated\n * @param newStatus The status that the items are being given\n * @param approvedItems Array of currently approved items\n * @param onApprovedItemsChange Callback function that stores the updated list of approved items\n * @param unapprovedItems Array of currently unapproved items\n * @param onUnapprovedItemsChange Callback function that stores the updated list of unapproved items\n */\nconst statusChangeHandler = (\n changedItems: string[],\n newStatus: Status,\n approvedItems: string[],\n onApprovedItemsChange: (items: string[]) => void,\n unapprovedItems: string[],\n onUnapprovedItemsChange: (items: string[]) => void,\n) => {\n let newApprovedItems: string[] = [...approvedItems];\n changedItems.forEach((item) => {\n if (newStatus === 'approved') {\n if (!newApprovedItems.includes(item)) {\n newApprovedItems.push(item);\n }\n } else {\n newApprovedItems = newApprovedItems.filter((validItem) => validItem !== item);\n }\n });\n onApprovedItemsChange(newApprovedItems);\n\n let newUnapprovedItems: string[] = [...unapprovedItems];\n changedItems.forEach((item) => {\n if (newStatus === 'unapproved') {\n if (!newUnapprovedItems.includes(item)) {\n newUnapprovedItems.push(item);\n }\n } else {\n newUnapprovedItems = newUnapprovedItems.filter((unapprovedItem) => unapprovedItem !== item);\n }\n });\n onUnapprovedItemsChange(newUnapprovedItems);\n};\n\n/**\n * Function that creates the status column for inventories. Should be used with the DataTable\n * component.\n *\n * @param statusLabel Localized label for the status column\n * @param approvedItems Array of approved items, typically as defined in `Settings.xml`\n * @param onApprovedItemsChange Callback function that stores the updated list of approved items\n * @param unapprovedItems Array of unapproved items, typically as defined in `Settings.xml`\n * @param onUnapprovedItemsChange Callback function that stores the updated list of unapproved items\n * @returns Column that shows the status buttons for the related inventory item. The button for the\n * current status of the item is selected\n */\nexport const inventoryStatusColumn = (\n statusLabel: string,\n approvedItems: string[],\n onApprovedItemsChange: (items: string[]) => void,\n unapprovedItems: string[],\n onUnapprovedItemsChange: (items: string[]) => void,\n): ColumnDef => {\n return {\n accessorKey: 'status',\n header: ({ column }) => {\n return (\n
    \n \n
    \n );\n },\n cell: ({ row }) => {\n const status: Status = row.getValue('status');\n const item: string = row.getValue('item');\n return (\n \n \n statusChangeHandler(\n [item],\n 'approved',\n approvedItems,\n onApprovedItemsChange,\n unapprovedItems,\n onUnapprovedItemsChange,\n )\n }\n value=\"approved\"\n >\n \n \n \n statusChangeHandler(\n [item],\n 'unapproved',\n approvedItems,\n onApprovedItemsChange,\n unapprovedItems,\n onUnapprovedItemsChange,\n )\n }\n value=\"unapproved\"\n >\n \n \n \n statusChangeHandler(\n [item],\n 'unknown',\n approvedItems,\n onApprovedItemsChange,\n unapprovedItems,\n onUnapprovedItemsChange,\n )\n }\n value=\"unknown\"\n >\n \n \n \n );\n },\n };\n};\n","import DataTable, {\n ColumnDef,\n RowContents,\n RowSelectionState,\n TableContents,\n} from '@/components/advanced/data-table/data-table.component';\nimport OccurrencesTable from '@/components/advanced/inventory/occurrences-table.component';\nimport Checkbox from '@/components/shadcn-ui/checkbox';\nimport { Input } from '@/components/shadcn-ui/input';\nimport { Label } from '@/components/shadcn-ui/label';\nimport {\n Select,\n SelectContent,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\nimport {\n deepEqual,\n LocalizedStringValue,\n ScriptureReference,\n substring,\n} from 'platform-bible-utils';\nimport { useEffect, useMemo, useState } from 'react';\nimport {\n getBookNumFromId,\n getLinesFromUSFM,\n getNumberFromUSFM,\n getStatusForItem,\n InventoryItemOccurrence,\n InventoryTableData,\n Status,\n} from './inventory-utils';\nimport { inventoryAdditionalItemColumn } from './inventory-columns';\n\n/**\n * Object containing all keys used for localization in this component. If you're using this\n * component in an extension, you can pass it into the useLocalizedStrings hook to easily obtain the\n * localized strings and pass them into the localizedStrings prop of this component\n */\nexport const INVENTORY_STRING_KEYS = Object.freeze([\n '%webView_inventory_all%',\n '%webView_inventory_approved%',\n '%webView_inventory_unapproved%',\n '%webView_inventory_unknown%',\n '%webView_inventory_scope_currentBook%',\n '%webView_inventory_scope_chapter%',\n '%webView_inventory_scope_verse%',\n '%webView_inventory_filter_text%',\n '%webView_inventory_show_additional_items%',\n '%webView_inventory_occurrences_table_header_reference%',\n '%webView_inventory_occurrences_table_header_occurrence%',\n] as const);\n\nexport type InventoryLocalizedStrings = {\n [localizedInventoryKey in (typeof INVENTORY_STRING_KEYS)[number]]?: LocalizedStringValue;\n};\n\n/** Scope of scripture that the inventory can operate on */\nexport type Scope = 'book' | 'chapter' | 'verse';\n\n/** Status values that the status filter can select from */\ntype StatusFilter = Status | 'all';\n\n/** Text labels for the inventory columns and the control components of additional inventory items */\ntype AdditionalItemsLabels = {\n checkboxText?: string;\n tableHeaders?: string[];\n};\n\n/**\n * Filters data that is shown in the DataTable section of the Inventory\n *\n * @param itemData All inventory items and their related information\n * @param statusFilter Allows filtering by status (i.e. show all items, or only items that are\n * 'approved', 'unapproved' or 'unknown')\n * @param textFilter Allows filtering by text. All items that include the filter text will be\n * selected.\n * @returns Array of items and their related information that are matched by the specified filters\n */\nconst filterItemData = (\n itemData: InventoryTableData[],\n statusFilter: StatusFilter,\n textFilter: string,\n): InventoryTableData[] => {\n let filteredItemData: InventoryTableData[] = itemData;\n\n if (statusFilter !== 'all') {\n filteredItemData = filteredItemData.filter(\n (item) =>\n (statusFilter === 'approved' && item.status === 'approved') ||\n (statusFilter === 'unapproved' && item.status === 'unapproved') ||\n (statusFilter === 'unknown' && item.status === 'unknown'),\n );\n }\n\n if (textFilter !== '')\n filteredItemData = filteredItemData.filter((item) => item.items[0].includes(textFilter));\n\n return filteredItemData;\n};\n\n/**\n * Turns array of strings into array of inventory items, along with their count and status\n *\n * @param text The source scripture text that is searched for inventory items\n * @param scriptureRef The scripture reference that the application is currently set to\n * @param approvedItems Array of approved items, typically as defined in `Settings.xml`\n * @param unapprovedItems Array of unapproved items, typically as defined in `Settings.xml`\n * @param itemRegex Regular expression that describes what items this Inventory should extract from\n * the provided scripture text\n * @returns Array of inventory items, along with their count and status\n */\nconst createTableData = (\n text: string | undefined,\n scriptureRef: ScriptureReference,\n approvedItems: string[],\n unapprovedItems: string[],\n itemRegex: RegExp,\n): InventoryTableData[] => {\n if (!text) return [];\n\n const tableData: InventoryTableData[] = [];\n\n let currentBook: number | undefined = scriptureRef.bookNum;\n let currentChapter: number | undefined = scriptureRef.chapterNum;\n let currentVerse: number | undefined = scriptureRef.verseNum;\n\n const lines = getLinesFromUSFM(text);\n\n lines.forEach((line: string) => {\n if (line.startsWith('\\\\id')) {\n currentBook = getBookNumFromId(line);\n currentChapter = 0;\n currentVerse = 0;\n }\n if (line.startsWith('\\\\c')) {\n currentChapter = getNumberFromUSFM(line);\n currentVerse = 0;\n }\n if (line.startsWith('\\\\v')) {\n currentVerse = getNumberFromUSFM(line);\n if (currentChapter === 0) {\n currentChapter = scriptureRef.chapterNum;\n }\n }\n\n let match: RegExpExecArray | undefined = itemRegex.exec(line) ?? undefined;\n while (match) {\n const items: string[] = [];\n match.forEach((item) => items.push(item));\n const itemIndex = match.index;\n const existingItem = tableData.find((tableEntry) => deepEqual(tableEntry.items, items));\n const newReference: InventoryItemOccurrence = {\n reference: {\n bookNum: currentBook !== undefined ? currentBook : -1,\n chapterNum: currentChapter !== undefined ? currentChapter : -1,\n verseNum: currentVerse !== undefined ? currentVerse : -1,\n },\n text: substring(line, Math.max(0, itemIndex - 25), Math.min(itemIndex + 25, line.length)),\n };\n if (existingItem) {\n existingItem.count += 1;\n existingItem.occurrences.push(newReference);\n } else {\n const newItem: InventoryTableData = {\n items,\n count: 1,\n status: getStatusForItem(items[0], approvedItems, unapprovedItems),\n occurrences: [newReference],\n };\n tableData.push(newItem);\n }\n\n match = itemRegex.exec(line) ?? undefined;\n }\n });\n\n return tableData;\n};\n\n/**\n * Gets the localized value for the provided key\n *\n * @param strings Object containing localized string\n * @param key Key for a localized string\n * @returns The localized value for the provided key, if available. Returns the key if no localized\n * value is available\n */\nconst localizeString = (\n strings: InventoryLocalizedStrings,\n key: keyof InventoryLocalizedStrings,\n) => {\n return strings[key] ?? key;\n};\n\n/** Props for the Inventory component */\ntype InventoryProps = {\n /** The scripture reference that the application is currently set to */\n scriptureReference: ScriptureReference;\n /** Callback function that is executed when the scripture reference is changed */\n setScriptureReference: (scriptureReference: ScriptureReference) => void;\n /**\n * Object with all localized strings that the Inventory needs to work well across multiple\n * languages. When using this component with Platform.Bible, you can import\n * `INVENTORY_STRING_KEYS` from this library, pass it in to the Platform's localization hook, and\n * pass the localized keys that are returned by the hook into this prop.\n */\n localizedStrings: InventoryLocalizedStrings;\n /**\n * The logic that finds the desired items in the source text. This can either be a Regular\n * expression that captures one or multiple items (preferred), or a custom function that builds\n * and return an InventoryDataTable[] manually. Note: In case the logic captures more than one\n * item (i.e. InventoryTableData.items has a length greater than 1), you must provide text labels\n * for the related columns and control elements to show by setting the `additionalItemsLabels`\n * prop\n */\n extractItems:\n | RegExp\n | ((\n text: string | undefined,\n scriptureRef: ScriptureReference,\n approvedItems: string[],\n unapprovedItems: string[],\n ) => InventoryTableData[]);\n /**\n * Text labels for control elements and additional column headers in case your Inventory has more\n * than one item to show (e.g. The 'Preceding Marker' in the Markers Inventory)\n */\n additionalItemsLabels?: AdditionalItemsLabels;\n /** Array of approved items, typically as defined in `Settings.xml` */\n approvedItems: string[];\n /** Array of unapproved items, typically as defined in `Settings.xml` */\n unapprovedItems: string[];\n /** The source scripture text that is searched for in inventory items */\n text: string | undefined;\n /** Scope of scripture that the inventory will operate on */\n scope: Scope;\n /** Callback function that is executed when the scope is changed from the Inventory */\n onScopeChange: (scope: Scope) => void;\n /**\n * Column definitions for the Inventory data table. The most commonly used column definitions are\n * pre-configured for your convenience and can be imported (e.g. inventoryItemColumn,\n * inventoryAdditionalItemColumn inventoryCountColumn, and inventoryStatusColumn). If you need any\n * other columns you can add these yourself\n */\n columns: ColumnDef[];\n};\n\n/** Inventory component that is used to view and control the status of provided project settings */\nexport default function Inventory({\n scriptureReference,\n setScriptureReference,\n localizedStrings,\n extractItems,\n additionalItemsLabels,\n approvedItems,\n unapprovedItems,\n text,\n scope,\n onScopeChange,\n columns,\n}: InventoryProps) {\n const allItemsText = localizeString(localizedStrings, '%webView_inventory_all%');\n const approvedItemsText = localizeString(localizedStrings, '%webView_inventory_approved%');\n const unapprovedItemsText = localizeString(localizedStrings, '%webView_inventory_unapproved%');\n const unknownItemsText = localizeString(localizedStrings, '%webView_inventory_unknown%');\n const scopeBookText = localizeString(localizedStrings, '%webView_inventory_scope_currentBook%');\n const scopeChapterText = localizeString(localizedStrings, '%webView_inventory_scope_chapter%');\n const scopeVerseText = localizeString(localizedStrings, '%webView_inventory_scope_verse%');\n const filterText = localizeString(localizedStrings, '%webView_inventory_filter_text%');\n const showAdditionalItemsText = localizeString(\n localizedStrings,\n '%webView_inventory_show_additional_items%',\n );\n\n const [showAdditionalItems, setShowAdditionalItems] = useState(false);\n const [statusFilter, setStatusFilter] = useState('all');\n const [textFilter, setTextFilter] = useState('');\n const [selectedItem, setSelectedItem] = useState([]);\n\n const tableData: InventoryTableData[] = useMemo(() => {\n if (!text) return [];\n if (extractItems instanceof RegExp)\n return createTableData(\n text,\n scriptureReference,\n approvedItems,\n unapprovedItems,\n extractItems,\n );\n return extractItems(text, scriptureReference, approvedItems, unapprovedItems);\n }, [text, extractItems, scriptureReference, approvedItems, unapprovedItems]);\n\n const reducedTableData: InventoryTableData[] = useMemo(() => {\n if (showAdditionalItems) return tableData;\n\n const newTableData: InventoryTableData[] = [];\n\n tableData.forEach((tableEntry) => {\n const firstItem = tableEntry.items[0];\n\n const existingEntry = newTableData.find(\n (newTableEntry) => newTableEntry.items[0] === firstItem,\n );\n\n if (existingEntry) {\n existingEntry.count += tableEntry.count;\n existingEntry.occurrences = existingEntry.occurrences.concat(tableEntry.occurrences);\n } else {\n newTableData.push({\n items: [firstItem],\n count: tableEntry.count,\n occurrences: tableEntry.occurrences,\n status: tableEntry.status,\n });\n }\n });\n\n return newTableData;\n }, [showAdditionalItems, tableData]);\n\n const filteredTableData: InventoryTableData[] = useMemo(() => {\n return filterItemData(reducedTableData, statusFilter, textFilter);\n }, [reducedTableData, statusFilter, textFilter]);\n\n const allColumns: ColumnDef[] = useMemo(() => {\n if (!showAdditionalItems) return columns;\n\n const numberOfAdditionalItems = additionalItemsLabels?.tableHeaders?.length;\n if (!numberOfAdditionalItems) return columns;\n\n const additionalColumns: ColumnDef[] = [];\n\n for (let index = 0; index < numberOfAdditionalItems; index++) {\n additionalColumns.push(\n inventoryAdditionalItemColumn(\n additionalItemsLabels?.tableHeaders?.[index] || 'Additional Item',\n index + 1,\n ),\n );\n }\n\n return [...additionalColumns, ...columns];\n }, [additionalItemsLabels?.tableHeaders, columns, showAdditionalItems]);\n\n useEffect(() => {\n setSelectedItem([]);\n }, [filteredTableData]);\n\n const rowClickHandler = (\n row: RowContents,\n table: TableContents,\n ) => {\n table.setRowSelection(() => {\n const newSelection: RowSelectionState = {};\n newSelection[row.index] = true;\n return newSelection;\n });\n\n setSelectedItem(row.original.items);\n };\n\n const handleScopeChange = (value: string) => {\n if (value === 'book' || value === 'chapter' || value === 'verse') {\n onScopeChange(value);\n } else {\n throw new Error(`Invalid scope value: ${value}`);\n }\n };\n\n const handleStatusFilterChange = (value: string) => {\n if (value === 'all' || value === 'approved' || value === 'unapproved' || value === 'unknown') {\n setStatusFilter(value);\n } else {\n throw new Error(`Invalid status filter value: ${value}`);\n }\n };\n\n const occurrenceData: InventoryItemOccurrence[] = useMemo(() => {\n if (reducedTableData.length === 0 || selectedItem.length === 0) return [];\n const occurrence = reducedTableData.filter((tableEntry: InventoryTableData) => {\n return deepEqual(\n showAdditionalItems ? tableEntry.items : [tableEntry.items[0]],\n selectedItem,\n );\n });\n if (occurrence.length > 1) throw new Error('Selected item is not unique');\n return occurrence[0].occurrences;\n }, [selectedItem, showAdditionalItems, reducedTableData]);\n\n return (\n
    \n
    \n handleStatusFilterChange(value)}\n defaultValue={statusFilter}\n >\n \n \n \n \n {allItemsText}\n {approvedItemsText}\n {unapprovedItemsText}\n {unknownItemsText}\n \n \n \n {\n setTextFilter(event.target.value);\n }}\n />\n {additionalItemsLabels && (\n
    \n {\n setSelectedItem([]);\n setShowAdditionalItems(checked);\n }}\n />\n \n
    \n )}\n
    \n
    \n \n
    \n {occurrenceData.length > 0 && (\n
    \n \n
    \n )}\n
    \n );\n}\n","import { Input } from '@/components/shadcn-ui/input';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { useState } from 'react';\n\n/** Props for the SearchBar component. */\nexport type SearchBarProps = {\n /** Additional css classes to help with unique styling of the search bar */\n className?: string;\n /**\n * Callback fired to handle the search query when button pressed\n *\n * @param searchQuery\n */\n onSearch: (searchQuery: string) => void;\n\n /** Optional string that appears in the search bar without a search string */\n placeholder?: string;\n\n /** Optional boolean to set the input base to full width */\n isFullWidth?: boolean;\n};\n\nexport default function SearchBar({\n className,\n onSearch,\n placeholder,\n isFullWidth,\n}: SearchBarProps) {\n const [searchQuery, setSearchQuery] = useState('');\n\n const handleInputChange = (searchString: string) => {\n setSearchQuery(searchString);\n onSearch(searchString);\n };\n\n return (\n handleInputChange(e.target.value)}\n />\n );\n}\n","// adapted from: https://github.com/shadcn-ui/ui/discussions/752\n\n'use client';\n\nimport { TabsContentProps, TabsListProps, TabsTriggerProps } from '@/components/shadcn-ui/tabs';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport * as TabsPrimitive from '@radix-ui/react-tabs';\nimport React from 'react';\n\nexport type VerticalTabsProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport type LeftTabsTriggerProps = TabsTriggerProps & {\n value: string;\n ref?: React.Ref;\n};\n\nexport const VerticalTabs = React.forwardRef<\n React.ElementRef,\n VerticalTabsProps\n>(({ className, ...props }, ref) => (\n \n));\n\nVerticalTabs.displayName = TabsPrimitive.List.displayName;\n\nexport const VerticalTabsList = React.forwardRef<\n React.ElementRef,\n TabsListProps\n>(({ className, ...props }, ref) => (\n \n));\nVerticalTabsList.displayName = TabsPrimitive.List.displayName;\n\nexport const VerticalTabsTrigger = React.forwardRef<\n React.ElementRef,\n LeftTabsTriggerProps\n>(({ className, ...props }, ref) => (\n \n));\n\nexport const VerticalTabsContent = React.forwardRef<\n React.ElementRef,\n TabsContentProps\n>(({ className, ...props }, ref) => (\n \n));\nVerticalTabsContent.displayName = TabsPrimitive.Content.displayName;\n","import SearchBar from '@/components/basics/search-bar.component';\nimport {\n VerticalTabs,\n VerticalTabsContent,\n VerticalTabsList,\n VerticalTabsTrigger,\n} from '@/components/basics/tabs-vertical';\nimport { ReactNode } from 'react';\n\nexport type TabKeyValueContent = {\n key: string;\n value: string;\n content: ReactNode;\n};\n\nexport type TabNavigationContentSearchProps = {\n /** List of values and keys for each tab this component should provide */\n tabList: TabKeyValueContent[];\n\n /** Handler to run when the value of the search bar changes */\n onSearch: (searchQuery: string) => void;\n\n /** Optional placeholder for the search bar */\n searchPlaceholder?: string;\n\n /** Optional title to include in the header */\n headerTitle?: string;\n\n /** Optional flag to make the search bar appear full width */\n isSearchBarFullWidth?: boolean;\n\n /** Text direction ltr or rtl */\n direction?: 'ltr' | 'rtl';\n};\n\nexport default function TabNavigationContentSearch({\n tabList,\n onSearch,\n searchPlaceholder,\n headerTitle,\n isSearchBarFullWidth = false,\n direction = 'ltr',\n}: TabNavigationContentSearchProps) {\n return (\n
    \n
    \n {headerTitle ?

    {headerTitle}

    : ''}\n \n
    \n \n \n {tabList.map((tab) => (\n \n {tab.value}\n \n ))}\n \n {tabList.map((tab) => (\n \n {tab.content}\n \n ))}\n \n
    \n );\n}\n","import React from 'react';\nimport * as SeparatorPrimitive from '@radix-ui/react-separator';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Separator = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, orientation = 'horizontal', decorative = true, ...props }, ref) => (\n \n));\nSeparator.displayName = SeparatorPrimitive.Root.displayName;\n\nexport { Separator };\n","import React from 'react';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nfunction Skeleton({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\n\nexport { Skeleton };\n","import React from 'react';\nimport * as TooltipPrimitive from '@radix-ui/react-tooltip';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst TooltipProvider = TooltipPrimitive.Provider;\n\nconst Tooltip = TooltipPrimitive.Root;\n\nconst TooltipTrigger = TooltipPrimitive.Trigger;\n\nconst TooltipContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, sideOffset = 4, ...props }, ref) => (\n \n));\nTooltipContent.displayName = TooltipPrimitive.Content.displayName;\n\nexport { Tooltip, TooltipTrigger, TooltipContent, TooltipProvider };\n","import React from 'react';\nimport { Slot } from '@radix-ui/react-slot';\nimport { VariantProps, cva } from 'class-variance-authority';\nimport { PanelLeft } from 'lucide-react';\n\nimport { Button } from '@/components/shadcn-ui/button';\nimport { Input } from '@/components/shadcn-ui/input';\nimport { Separator } from '@/components/shadcn-ui/separator';\nimport { Skeleton } from '@/components/shadcn-ui/skeleton';\nimport {\n Tooltip,\n TooltipContent,\n TooltipProvider,\n TooltipTrigger,\n} from '@/components/shadcn-ui/tooltip';\nimport { cn } from '@/utils/shadcn-ui.util';\n\n/**\n * Changes from the original code from Shadcn- Removed uses of useIsMobile, Sheet, and SheetContent.\n * Also removed the parts setting COOKIES.\n */\n\nconst SIDEBAR_WIDTH = '16rem';\nconst SIDEBAR_WIDTH_ICON = '3rem';\nconst SIDEBAR_KEYBOARD_SHORTCUT = 'b';\n\ntype SidebarContextProps = {\n state: 'expanded' | 'collapsed';\n open: boolean;\n setOpen: (open: boolean) => void;\n toggleSidebar: () => void;\n};\n\nconst SidebarContext = React.createContext(undefined);\n\nfunction useSidebar() {\n const context = React.useContext(SidebarContext);\n if (!context) {\n throw new Error('useSidebar must be used within a SidebarProvider.');\n }\n\n return context;\n}\n\nconst SidebarProvider = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & {\n defaultOpen?: boolean;\n open?: boolean;\n onOpenChange?: (open: boolean) => void;\n }\n>(\n (\n {\n defaultOpen = true,\n open: openProp,\n onOpenChange: setOpenProp,\n className,\n style,\n children,\n ...props\n },\n ref,\n ) => {\n // This is the internal state of the sidebar.\n // We use openProp and setOpenProp for control from outside the component.\n const [_open, _setOpen] = React.useState(defaultOpen);\n const isOpen = openProp ?? _open;\n const setOpen = React.useCallback(\n (value: boolean | ((value: boolean) => boolean)) => {\n const openState = typeof value === 'function' ? value(isOpen) : value;\n if (setOpenProp) {\n setOpenProp(openState);\n } else {\n _setOpen(openState);\n }\n },\n [setOpenProp, isOpen],\n );\n\n // Helper to toggle the sidebar.\n const toggleSidebar = React.useCallback(() => {\n return setOpen((open) => !open);\n }, [setOpen]);\n\n // Adds a keyboard shortcut to toggle the sidebar.\n React.useEffect(() => {\n const handleKeyDown = (event: KeyboardEvent) => {\n if (event.key === SIDEBAR_KEYBOARD_SHORTCUT && (event.metaKey || event.ctrlKey)) {\n event.preventDefault();\n toggleSidebar();\n }\n };\n\n window.addEventListener('keydown', handleKeyDown);\n return () => window.removeEventListener('keydown', handleKeyDown);\n }, [toggleSidebar]);\n\n // We add a state so that we can do data-state=\"expanded\" or \"collapsed\".\n // This makes it easier to style the sidebar with Tailwind classes.\n const state = isOpen ? 'expanded' : 'collapsed';\n\n const contextValue = React.useMemo(\n () => ({\n state,\n open: isOpen,\n setOpen,\n toggleSidebar,\n }),\n [state, isOpen, setOpen, toggleSidebar],\n );\n\n return (\n \n \n \n {children}\n
    \n \n \n );\n },\n);\nSidebarProvider.displayName = 'SidebarProvider';\n\nconst Sidebar = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & {\n side?: 'left' | 'right';\n variant?: 'sidebar' | 'floating' | 'inset';\n collapsible?: 'offcanvas' | 'icon' | 'none';\n }\n>(\n (\n {\n side = 'left',\n variant = 'sidebar',\n collapsible = 'offcanvas',\n className,\n children,\n ...props\n },\n ref,\n ) => {\n const { state } = useSidebar();\n\n if (collapsible === 'none') {\n return (\n \n {children}\n
    \n );\n }\n\n return (\n \n {/* This is what handles the sidebar gap on desktop */}\n \n \n \n {children}\n
    \n
    \n
    \n );\n },\n);\nSidebar.displayName = 'Sidebar';\n\nconst SidebarTrigger = React.forwardRef<\n React.ElementRef,\n React.ComponentProps\n>(({ className, onClick, ...props }, ref) => {\n const { toggleSidebar } = useSidebar();\n\n return (\n {\n onClick?.(event);\n toggleSidebar();\n }}\n {...props}\n >\n \n Toggle Sidebar\n \n );\n});\nSidebarTrigger.displayName = 'SidebarTrigger';\n\nconst SidebarRail = React.forwardRef>(\n ({ className, ...props }, ref) => {\n const { toggleSidebar } = useSidebar();\n\n return (\n \n );\n },\n);\nSidebarRail.displayName = 'SidebarRail';\n\nconst SidebarInset = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarInset.displayName = 'SidebarInset';\n\nconst SidebarInput = React.forwardRef<\n React.ElementRef,\n React.ComponentProps\n>(({ className, ...props }, ref) => {\n return (\n \n );\n});\nSidebarInput.displayName = 'SidebarInput';\n\nconst SidebarHeader = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarHeader.displayName = 'SidebarHeader';\n\nconst SidebarFooter = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarFooter.displayName = 'SidebarFooter';\n\nconst SidebarSeparator = React.forwardRef<\n React.ElementRef,\n React.ComponentProps\n>(({ className, ...props }, ref) => {\n return (\n \n );\n});\nSidebarSeparator.displayName = 'SidebarSeparator';\n\nconst SidebarContent = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarContent.displayName = 'SidebarContent';\n\nconst SidebarGroup = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarGroup.displayName = 'SidebarGroup';\n\nconst SidebarGroupLabel = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & { asChild?: boolean }\n>(({ className, asChild = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'div';\n\n return (\n svg]:tw-size-4 [&>svg]:tw-shrink-0',\n 'group-data-[collapsible=icon]:tw--mt-8 group-data-[collapsible=icon]:tw-opacity-0',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarGroupLabel.displayName = 'SidebarGroupLabel';\n\nconst SidebarGroupAction = React.forwardRef<\n HTMLButtonElement,\n React.ComponentProps<'button'> & { asChild?: boolean }\n>(({ className, asChild = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'button';\n\n return (\n svg]:tw-size-4 [&>svg]:tw-shrink-0',\n // Increases the hit area of the button on mobile.\n 'after:tw-absolute after:tw--inset-2 after:md:tw-hidden',\n 'group-data-[collapsible=icon]:tw-hidden',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarGroupAction.displayName = 'SidebarGroupAction';\n\nconst SidebarGroupContent = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarGroupContent.displayName = 'SidebarGroupContent';\n\nconst SidebarMenu = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenu.displayName = 'SidebarMenu';\n\nconst SidebarMenuItem = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenuItem.displayName = 'SidebarMenuItem';\n\nconst sidebarMenuButtonVariants = cva(\n // Removed data-[active=true]:tw-bg-sidebar-accent\n 'tw-peer/menu-button tw-flex tw-w-full tw-items-center tw-gap-2 tw-overflow-hidden tw-rounded-md tw-p-2 tw-text-left tw-text-sm tw-outline-none tw-ring-sidebar-ring tw-transition-[width,height,padding] hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground focus-visible:tw-ring-2 active:tw-bg-sidebar-accent active:tw-text-sidebar-accent-foreground disabled:tw-pointer-events-none disabled:tw-opacity-50 tw-group-has-[[data-sidebar=menu-action]]/menu-item:pr-8 aria-disabled:tw-pointer-events-none aria-disabled:tw-opacity-50 data-[active=true]:tw-font-medium data-[active=true]:tw-text-sidebar-accent-foreground data-[state=open]:hover:tw-bg-sidebar-accent data-[state=open]:hover:tw-text-sidebar-accent-foreground group-data-[collapsible=icon]:tw-!size-8 group-data-[collapsible=icon]:tw-!p-2 [&>span:last-child]:tw-truncate [&>svg]:tw-size-4 [&>svg]:tw-shrink-0',\n {\n variants: {\n variant: {\n default: 'hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground',\n outline:\n 'tw-bg-background tw-shadow-[0_0_0_1px_hsl(var(--sidebar-border))] hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground hover:tw-shadow-[0_0_0_1px_hsl(var(--sidebar-accent))]',\n },\n size: {\n default: 'tw-h-8 tw-text-sm',\n sm: 'tw-h-7 tw-text-xs',\n lg: 'tw-h-12 tw-text-sm group-data-[collapsible=icon]:tw-!p-0',\n },\n },\n defaultVariants: {\n variant: 'default',\n size: 'default',\n },\n },\n);\n\nconst SidebarMenuButton = React.forwardRef<\n HTMLButtonElement,\n React.ComponentProps<'button'> & {\n asChild?: boolean;\n isActive?: boolean;\n tooltip?: string | React.ComponentProps;\n } & VariantProps\n>(\n (\n {\n asChild = false,\n isActive = false,\n variant = 'default',\n size = 'default',\n tooltip,\n className,\n ...props\n },\n ref,\n ) => {\n const Comp = asChild ? Slot : 'button';\n const { state } = useSidebar();\n\n const button = (\n \n );\n\n if (!tooltip) {\n return button;\n }\n\n if (typeof tooltip === 'string') {\n // eslint-disable-next-line no-param-reassign\n tooltip = {\n children: tooltip,\n };\n }\n\n return (\n \n {button}\n \n );\n },\n);\nSidebarMenuButton.displayName = 'SidebarMenuButton';\n\nconst SidebarMenuAction = React.forwardRef<\n HTMLButtonElement,\n React.ComponentProps<'button'> & {\n asChild?: boolean;\n showOnHover?: boolean;\n }\n>(({ className, asChild = false, showOnHover = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'button';\n\n return (\n svg]:tw-size-4 [&>svg]:tw-shrink-0',\n // Increases the hit area of the button on mobile.\n 'after:tw-absolute after:tw--inset-2 after:md:tw-hidden',\n 'tw-peer-data-[size=sm]/menu-button:top-1',\n 'tw-peer-data-[size=default]/menu-button:top-1.5',\n 'tw-peer-data-[size=lg]/menu-button:top-2.5',\n 'group-data-[collapsible=icon]:tw-hidden',\n showOnHover &&\n 'tw-group-focus-within/menu-item:opacity-100 tw-group-hover/menu-item:opacity-100 tw-peer-data-[active=true]/menu-button:text-sidebar-accent-foreground data-[state=open]:tw-opacity-100 md:tw-opacity-0',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarMenuAction.displayName = 'SidebarMenuAction';\n\nconst SidebarMenuBadge = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenuBadge.displayName = 'SidebarMenuBadge';\n\nconst SidebarMenuSkeleton = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & {\n showIcon?: boolean;\n }\n>(({ className, showIcon = false, ...props }, ref) => {\n // Random width between 50 to 90%.\n const width = React.useMemo(() => {\n return `${Math.floor(Math.random() * 40) + 50}%`;\n }, []);\n\n return (\n \n {showIcon && (\n \n )}\n \n
    \n );\n});\nSidebarMenuSkeleton.displayName = 'SidebarMenuSkeleton';\n\nconst SidebarMenuSub = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenuSub.displayName = 'SidebarMenuSub';\n\nconst SidebarMenuSubItem = React.forwardRef>(\n ({ ...props }, ref) =>
  • ,\n);\nSidebarMenuSubItem.displayName = 'SidebarMenuSubItem';\n\nconst SidebarMenuSubButton = React.forwardRef<\n HTMLAnchorElement,\n React.ComponentProps<'a'> & {\n asChild?: boolean;\n size?: 'sm' | 'md';\n isActive?: boolean;\n }\n>(({ asChild = false, size = 'md', isActive, className, ...props }, ref) => {\n const Comp = asChild ? Slot : 'a';\n\n return (\n span:last-child]:tw-truncate [&>svg]:tw-size-4 [&>svg]:tw-shrink-0 [&>svg]:tw-text-sidebar-accent-foreground',\n 'data-[active=true]:tw-bg-sidebar-accent data-[active=true]:tw-text-sidebar-accent-foreground',\n size === 'sm' && 'tw-text-xs',\n size === 'md' && 'tw-text-sm',\n 'group-data-[collapsible=icon]:tw-hidden',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarMenuSubButton.displayName = 'SidebarMenuSubButton';\n\nexport {\n Sidebar,\n SidebarContent,\n SidebarFooter,\n SidebarGroup,\n SidebarGroupAction,\n SidebarGroupContent,\n SidebarGroupLabel,\n SidebarHeader,\n SidebarInput,\n SidebarInset,\n SidebarMenu,\n SidebarMenuAction,\n SidebarMenuBadge,\n SidebarMenuButton,\n SidebarMenuItem,\n SidebarMenuSkeleton,\n SidebarMenuSub,\n SidebarMenuSubButton,\n SidebarMenuSubItem,\n SidebarProvider,\n SidebarRail,\n SidebarSeparator,\n SidebarTrigger,\n useSidebar,\n};\n","import ComboBox, { ComboBoxOption } from '@/components/basics/combo-box.component';\nimport {\n Sidebar,\n SidebarContent,\n SidebarGroup,\n SidebarGroupLabel,\n SidebarGroupContent,\n SidebarMenu,\n SidebarMenuItem,\n SidebarMenuButton,\n} from '@/components/shadcn-ui/sidebar';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { useCallback } from 'react';\n\nexport type SelectedSettingsSidebarItem = {\n label: string;\n projectId?: string;\n};\n\nexport type ProjectInfo = { projectId: string; projectName: string };\n\nexport type SettingsSidebarProps = {\n /** Optional id for testing */\n id?: string;\n\n /** Extension labels from contribution */\n extensionLabels: string[];\n\n /** Project names and ids */\n projectInfo: ProjectInfo[];\n\n /** Handler for selecting a sidebar item */\n handleSelectSidebarItem: (key: string, projectId?: string) => void;\n\n /** The current selected value in the sidebar */\n selectedSidebarItem: SelectedSettingsSidebarItem;\n\n /** Label for the group of extensions setting groups */\n extensionsSidebarGroupLabel: string;\n\n /** Label for the group of projects settings */\n projectsSidebarGroupLabel: string;\n\n /** Placeholder text for the button */\n buttonPlaceholderText: string;\n};\n\nexport default function SettingsSidebar({\n id,\n extensionLabels,\n projectInfo,\n handleSelectSidebarItem,\n selectedSidebarItem,\n extensionsSidebarGroupLabel,\n projectsSidebarGroupLabel,\n buttonPlaceholderText,\n}: SettingsSidebarProps) {\n const handleSelectItem = useCallback(\n (item: string, projectId?: string) => {\n handleSelectSidebarItem(item, projectId);\n },\n [handleSelectSidebarItem],\n );\n\n const getProjectNameFromProjectId = useCallback(\n (projectId: string) => {\n const project = projectInfo.find((info) => info.projectId === projectId);\n return project ? project.projectName : projectId;\n },\n [projectInfo],\n );\n\n const getIsActive: (label: string) => boolean = useCallback(\n (label: string) => !selectedSidebarItem.projectId && label === selectedSidebarItem.label,\n [selectedSidebarItem],\n );\n\n return (\n \n \n \n \n {extensionsSidebarGroupLabel}\n \n \n \n {extensionLabels.map((label) => (\n \n handleSelectItem(label)}\n isActive={getIsActive(label)}\n >\n {label}\n \n \n ))}\n \n \n \n \n \n {projectsSidebarGroupLabel}\n \n \n info.projectId)}\n getOptionLabel={(projectId: ComboBoxOption) => {\n // This function expects a ComboBoxOption, but we know it is a string\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n return getProjectNameFromProjectId(projectId as string);\n }}\n buttonPlaceholder={buttonPlaceholderText}\n onChange={(projectId: string) => {\n const selectedProjectName = getProjectNameFromProjectId(projectId);\n handleSelectItem(selectedProjectName, projectId);\n }}\n value={selectedSidebarItem?.projectId ?? undefined}\n />\n \n \n \n \n );\n}\n","import { SidebarInset, SidebarProvider } from '@/components/shadcn-ui/sidebar';\nimport { PropsWithChildren } from 'react';\nimport SearchBar from '@/components/basics/search-bar.component';\nimport SettingsSidebar, { SettingsSidebarProps } from './settings-sidebar.component';\n\nexport type SettingsSidebarContentSearchProps = SettingsSidebarProps &\n PropsWithChildren & {\n /** Optional id for testing */\n id?: string;\n\n /** Handler to run when the value of the search bar changes */\n onSearch: (searchQuery: string) => void;\n };\n\nexport default function SettingsSidebarContentSearch({\n id,\n extensionLabels,\n projectInfo,\n children,\n handleSelectSidebarItem,\n selectedSidebarItem,\n onSearch,\n extensionsSidebarGroupLabel,\n projectsSidebarGroupLabel,\n buttonPlaceholderText,\n}: SettingsSidebarContentSearchProps) {\n return (\n
    \n
    \n \n
    \n \n \n {children}\n \n
    \n );\n}\n","import { Button } from '@/components/shadcn-ui/button';\nimport {\n Select,\n SelectContent,\n SelectGroup,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\nimport {\n Table,\n TableBody,\n TableCell,\n TableHead,\n TableHeader,\n TableRow,\n} from '@/components/shadcn-ui/table';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Canon } from '@sillsdev/scripture';\nimport {\n Cell,\n ColumnDef,\n flexRender,\n getCoreRowModel,\n getExpandedRowModel,\n getGroupedRowModel,\n getSortedRowModel,\n GroupingState,\n Row,\n RowSelectionState,\n SortingState,\n useReactTable,\n} from '@tanstack/react-table';\nimport '@/components/advanced/scripture-results-viewer/scripture-results-viewer.component.css';\nimport {\n compareScrRefs,\n formatScrRef,\n ScriptureSelection,\n scrRefToBBBCCCVVV,\n} from 'platform-bible-utils';\nimport { MouseEvent, useEffect, useMemo, useState } from 'react';\nimport { ChevronDown, ChevronLeft, ChevronRight } from 'lucide-react';\n\n/**\n * Information (e.g., a checking error or some other type of \"transient\" annotation) about something\n * noteworthy at a specific place in an instance of the Scriptures.\n */\nexport type ScriptureItemDetail = ScriptureSelection & {\n /**\n * Text of the error, note, etc. In the future, we might want to support something more than just\n * text so that a JSX element could be provided with a link or some other controls related to the\n * issue being reported.\n */\n detail: string;\n};\n\n/**\n * A uniquely identifiable source of results that can be displayed in the ScriptureResultsViewer.\n * Generally, the source will be a particular Scripture check, but there may be other types of\n * sources.\n */\nexport type ResultsSource = {\n /**\n * Uniquely identifies the source.\n *\n * @type {string}\n */\n id: string;\n\n /**\n * Name (potentially localized) of the source, suitable for display in the UI.\n *\n * @type {string}\n */\n displayName: string;\n};\n\nexport type ScriptureSrcItemDetail = ScriptureItemDetail & {\n /** Source/type of detail. Can be used for grouping. */\n source: ResultsSource;\n};\n\n/**\n * Represents a set of results keyed by Scripture reference. Generally, the source will be a\n * particular Scripture check, but this type also allows for other types of uniquely identifiable\n * sources.\n */\nexport type ResultsSet = {\n /**\n * The backing source associated with this set of results.\n *\n * @type {ResultsSource}\n */\n source: ResultsSource;\n\n /**\n * Array of Scripture item details (messages keyed by Scripture reference).\n *\n * @type {ScriptureItemDetail[]}\n */\n data: ScriptureItemDetail[];\n};\n\nconst scrBookColId = 'scrBook';\nconst scrRefColId = 'scrRef';\nconst typeColId = 'source';\nconst detailsColId = 'details';\n\nconst defaultScrRefColumnName = 'Scripture Reference';\nconst defaultScrBookGroupName = 'Scripture Book';\nconst defaultTypeColumnName = 'Type';\nconst defaultDetailsColumnName = 'Details';\n\nexport type ScriptureResultsViewerColumnInfo = {\n /** Optional header to display for the Reference column. Default value: 'Scripture Reference'. */\n scriptureReferenceColumnName?: string;\n\n /** Optional text to display to refer to the Scripture book group. Default value: 'Scripture Book'. */\n scriptureBookGroupName?: string;\n\n /** Optional header to display for the Type column. Default value: 'Type'. */\n typeColumnName?: string;\n\n /** Optional header to display for the Details column. Default value: 'Details' */\n detailsColumnName?: string;\n};\n\nexport type ScriptureResultsViewerProps = ScriptureResultsViewerColumnInfo & {\n /** Groups of ScriptureItemDetail objects from particular sources (e.g., Scripture checks) */\n sources: ResultsSet[];\n\n /** Flag indicating whether to display column headers. Default is false. */\n showColumnHeaders?: boolean;\n\n /** Flag indicating whether to display source column. Default is false. */\n showSourceColumn?: boolean;\n\n /** Callback function to notify when a row is selected */\n onRowSelected?: (selectedRow: ScriptureSrcItemDetail | undefined) => void;\n\n /** Text direction ltr or rtl */\n direction?: 'ltr' | 'rtl';\n};\n\nfunction getColumns(\n colInfo?: ScriptureResultsViewerColumnInfo,\n showSourceColumn?: boolean,\n): ColumnDef[] {\n const showSrcCol = showSourceColumn ?? false;\n return [\n {\n accessorFn: (row) =>\n `${Canon.bookNumberToId(row.start.bookNum)} ${row.start.chapterNum}:${row.start.verseNum}`,\n id: scrBookColId,\n header: colInfo?.scriptureReferenceColumnName ?? defaultScrRefColumnName,\n cell: (info) => {\n const row = info.row.original;\n if (info.row.getIsGrouped()) {\n return Canon.bookNumberToEnglishName(row.start.bookNum);\n }\n return info.row.groupingColumnId === scrBookColId ? formatScrRef(row.start) : undefined;\n },\n getGroupingValue: (row) => row.start.bookNum,\n sortingFn: (a, b) => {\n return compareScrRefs(a.original.start, b.original.start);\n },\n enableGrouping: true,\n },\n {\n accessorFn: (row) => formatScrRef(row.start),\n id: scrRefColId,\n header: undefined,\n cell: (info) => {\n const row = info.row.original;\n return info.row.getIsGrouped() ? undefined : formatScrRef(row.start);\n },\n sortingFn: (a, b) => {\n return compareScrRefs(a.original.start, b.original.start);\n },\n enableGrouping: false,\n },\n {\n accessorFn: (row) => row.source.displayName,\n id: typeColId,\n header: showSrcCol ? (colInfo?.typeColumnName ?? defaultTypeColumnName) : undefined,\n cell: (info) => (showSrcCol || info.row.getIsGrouped() ? info.getValue() : undefined),\n getGroupingValue: (row) => row.source.id,\n sortingFn: (a, b) =>\n a.original.source.displayName.localeCompare(b.original.source.displayName),\n enableGrouping: true,\n },\n {\n accessorFn: (row) => row.detail,\n id: detailsColId,\n header: colInfo?.detailsColumnName ?? defaultDetailsColumnName,\n cell: (info) => info.getValue(),\n enableGrouping: false,\n },\n ];\n}\n\nconst toRefOrRange = (scriptureSelection: ScriptureSelection) => {\n if (!('offset' in scriptureSelection.start))\n throw new Error('No offset available in range start');\n if (scriptureSelection.end && !('offset' in scriptureSelection.end))\n throw new Error('No offset available in range end');\n const { offset: offsetStart } = scriptureSelection.start;\n let offsetEnd: number = 0;\n if (scriptureSelection.end) ({ offset: offsetEnd } = scriptureSelection.end);\n if (\n !scriptureSelection.end ||\n compareScrRefs(scriptureSelection.start, scriptureSelection.end) === 0\n )\n return `${scrRefToBBBCCCVVV(scriptureSelection.start)}+${offsetStart}`;\n return `${scrRefToBBBCCCVVV(scriptureSelection.start)}+${offsetStart}-${scrRefToBBBCCCVVV(scriptureSelection.end)}+${offsetEnd}`;\n};\n\nconst getRowKey = (row: ScriptureSrcItemDetail) =>\n `${toRefOrRange({ start: row.start, end: row.end })} ${row.source.displayName} ${row.detail}`;\n\n/**\n * Component to display a combined list of detailed items from one or more sources, where the items\n * are keyed primarily by Scripture reference. This is particularly useful for displaying a list of\n * results from Scripture checks, but more generally could be used to display any \"results\" from any\n * source(s). The component allows for grouping by Scripture book, source, or both. By default, it\n * displays somewhat \"tree-like\" which allows it to be more horizontally compact and intuitive. But\n * it also has the option of displaying as a traditional table with column headings (with or without\n * the source column showing).\n */\nexport default function ScriptureResultsViewer({\n sources,\n showColumnHeaders = false,\n showSourceColumn = false,\n scriptureReferenceColumnName,\n scriptureBookGroupName,\n typeColumnName,\n detailsColumnName,\n onRowSelected,\n direction = 'ltr',\n}: ScriptureResultsViewerProps) {\n const [grouping, setGrouping] = useState([]);\n const [sorting, setSorting] = useState([{ id: scrBookColId, desc: false }]);\n const [rowSelection, setRowSelection] = useState({});\n\n const scriptureResults = useMemo(\n () =>\n sources.flatMap((source) => {\n return source.data.map((item) => ({\n ...item,\n source: source.source,\n }));\n }),\n [sources],\n );\n\n const columns = useMemo(\n () =>\n getColumns(\n {\n scriptureReferenceColumnName,\n typeColumnName,\n detailsColumnName,\n },\n showSourceColumn,\n ),\n [scriptureReferenceColumnName, typeColumnName, detailsColumnName, showSourceColumn],\n );\n\n useEffect(() => {\n // Ensure sorting is applied correctly when grouped by type\n if (grouping.includes(typeColId)) {\n setSorting([\n { id: typeColId, desc: false },\n { id: scrBookColId, desc: false },\n ]);\n } else {\n setSorting([{ id: scrBookColId, desc: false }]);\n }\n }, [grouping]);\n\n const table = useReactTable({\n data: scriptureResults,\n columns,\n state: {\n grouping,\n sorting,\n rowSelection,\n },\n onGroupingChange: setGrouping,\n onSortingChange: setSorting,\n onRowSelectionChange: setRowSelection,\n getExpandedRowModel: getExpandedRowModel(),\n getGroupedRowModel: getGroupedRowModel(),\n getCoreRowModel: getCoreRowModel(),\n getSortedRowModel: getSortedRowModel(),\n getRowId: getRowKey,\n autoResetExpanded: false,\n enableMultiRowSelection: false,\n enableSubRowSelection: false,\n });\n\n useEffect(() => {\n if (onRowSelected) {\n const selectedRows = table.getSelectedRowModel().rowsById;\n const keys = Object.keys(selectedRows);\n if (keys.length === 1) {\n const selectedRow = scriptureResults.find((row) => getRowKey(row) === keys[0]) || undefined;\n if (selectedRow) onRowSelected(selectedRow);\n }\n }\n }, [rowSelection, scriptureResults, onRowSelected, table]);\n\n // Define possible grouping options\n const scrBookGroupName = scriptureBookGroupName ?? defaultScrBookGroupName;\n const typeGroupName = typeColumnName ?? defaultTypeColumnName;\n\n const groupingOptions = [\n { label: 'No Grouping', value: [] },\n { label: `Group by ${scrBookGroupName}`, value: [scrBookColId] },\n { label: `Group by ${typeGroupName}`, value: [typeColId] },\n {\n label: `Group by ${scrBookGroupName} and ${typeGroupName}`,\n value: [scrBookColId, typeColId],\n },\n {\n label: `Group by ${typeGroupName} and ${scrBookGroupName}`,\n value: [typeColId, scrBookColId],\n },\n ];\n\n const handleSelectChange = (selectedGrouping: string) => {\n setGrouping(JSON.parse(selectedGrouping));\n };\n\n const handleRowClick = (row: Row, event: MouseEvent) => {\n if (!row.getIsGrouped() && !row.getIsSelected()) {\n row.getToggleSelectedHandler()(event);\n }\n };\n\n const getEvenOrOddBandingStyle = (row: Row, index: number) => {\n if (row.getIsGrouped()) return '';\n // UX has now said they don't think they want banding. I'm leaving in the code to\n // set even and odd styles, but there's nothing in the CSS to style them differently.\n // The \"even\" style used to also have tw-bg-neutral-300 (along with even) to create\n // a visual banding effect. That could be added back in if UX changes the decision.\n return cn('banded-row', index % 2 === 0 ? 'even' : 'odd');\n };\n\n const getIndent = (\n groupingState: GroupingState,\n row: Row,\n cell: Cell,\n ) => {\n if (groupingState?.length === 0 || row.depth < cell.column.getGroupedIndex()) return undefined;\n if (row.getIsGrouped()) {\n switch (row.depth) {\n case 1:\n return 'tw-ps-4';\n default:\n return undefined;\n }\n }\n switch (row.depth) {\n case 1:\n return 'tw-ps-8';\n case 2:\n return 'tw-ps-12';\n default:\n return undefined;\n }\n };\n\n return (\n
    \n {!showColumnHeaders && (\n {\n handleSelectChange(value);\n }}\n >\n \n \n \n \n \n {groupingOptions.map((option) => (\n \n {option.label}\n \n ))}\n \n \n \n )}\n \n {showColumnHeaders && (\n \n {table.getHeaderGroups().map((headerGroup) => (\n \n {headerGroup.headers\n .filter((h) => h.column.columnDef.header)\n .map((header) => (\n /* For sticky column headers to work, we probably need to change the default definition of the shadcn Table component. See https://github.com/shadcn-ui/ui/issues/1151 */\n \n {header.isPlaceholder ? undefined : (\n
    \n {header.column.getCanGroup() ? (\n \n {header.column.getIsGrouped() ? `🛑` : `👊 `}\n \n ) : undefined}{' '}\n {flexRender(header.column.columnDef.header, header.getContext())}\n
    \n )}\n
    \n ))}\n
    \n ))}\n
    \n )}\n \n {table.getRowModel().rows.map((row, rowIndex) => {\n return (\n handleRowClick(row, event)}\n >\n {row.getVisibleCells().map((cell) => {\n if (\n cell.getIsPlaceholder() ||\n (cell.column.columnDef.enableGrouping &&\n !cell.getIsGrouped() &&\n (cell.column.columnDef.id !== typeColId || !showSourceColumn))\n )\n return undefined;\n return (\n \n {(() => {\n if (cell.getIsGrouped()) {\n return (\n \n {row.getIsExpanded() && }\n {!row.getIsExpanded() &&\n (direction === 'ltr' ? : )}{' '}\n {flexRender(cell.column.columnDef.cell, cell.getContext())} (\n {row.subRows.length})\n \n );\n }\n\n // if (cell.getIsAggregated()) {\n // flexRender(\n // cell.column.columnDef.aggregatedCell ?? cell.column.columnDef.cell,\n // cell.getContext(),\n // );\n // }\n\n return flexRender(cell.column.columnDef.cell, cell.getContext());\n })()}\n \n );\n })}\n \n );\n })}\n \n
    \n
    \n );\n}\n","import {\n getLocalizeKeyForScrollGroupId,\n LanguageStrings,\n ScrollGroupId,\n} from 'platform-bible-utils';\nimport {\n Select,\n SelectContent,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\n\nconst DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS = {\n [getLocalizeKeyForScrollGroupId('undefined')]: 'Ø',\n [getLocalizeKeyForScrollGroupId(0)]: 'A',\n [getLocalizeKeyForScrollGroupId(1)]: 'B',\n [getLocalizeKeyForScrollGroupId(2)]: 'C',\n [getLocalizeKeyForScrollGroupId(3)]: 'D',\n [getLocalizeKeyForScrollGroupId(4)]: 'E',\n [getLocalizeKeyForScrollGroupId(5)]: 'F',\n [getLocalizeKeyForScrollGroupId(6)]: 'G',\n [getLocalizeKeyForScrollGroupId(7)]: 'H',\n [getLocalizeKeyForScrollGroupId(8)]: 'I',\n [getLocalizeKeyForScrollGroupId(9)]: 'J',\n [getLocalizeKeyForScrollGroupId(10)]: 'K',\n [getLocalizeKeyForScrollGroupId(11)]: 'L',\n [getLocalizeKeyForScrollGroupId(12)]: 'M',\n [getLocalizeKeyForScrollGroupId(13)]: 'N',\n [getLocalizeKeyForScrollGroupId(14)]: 'O',\n [getLocalizeKeyForScrollGroupId(15)]: 'P',\n [getLocalizeKeyForScrollGroupId(16)]: 'Q',\n [getLocalizeKeyForScrollGroupId(17)]: 'R',\n [getLocalizeKeyForScrollGroupId(18)]: 'S',\n [getLocalizeKeyForScrollGroupId(19)]: 'T',\n [getLocalizeKeyForScrollGroupId(20)]: 'U',\n [getLocalizeKeyForScrollGroupId(21)]: 'V',\n [getLocalizeKeyForScrollGroupId(22)]: 'W',\n [getLocalizeKeyForScrollGroupId(23)]: 'X',\n [getLocalizeKeyForScrollGroupId(24)]: 'Y',\n [getLocalizeKeyForScrollGroupId(25)]: 'Z',\n};\n\nexport type ScrollGroupSelectorProps = {\n /**\n * List of scroll group ids to show to the user. Either a {@link ScrollGroupId} or `undefined` for\n * no scroll group\n */\n availableScrollGroupIds: (ScrollGroupId | undefined)[];\n /** Currently selected scroll group id. `undefined` for no scroll group */\n scrollGroupId: ScrollGroupId | undefined;\n /** Callback function run when the user tries to change the scroll group id */\n onChangeScrollGroupId: (newScrollGroupId: ScrollGroupId | undefined) => void;\n /**\n * Localized strings to use for displaying scroll group ids. Must be an object whose keys are\n * `getLocalizeKeyForScrollGroupId(scrollGroupId)` for all scroll group ids (and `undefined` if\n * included) in {@link ScrollGroupSelectorProps.availableScrollGroupIds} and whose values are the\n * localized strings to use for those scroll group ids.\n *\n * Defaults to English localizations of English alphabet for scroll groups 0-25 (e.g. 0 is A) and\n * Ø for `undefined`. Will fill in any that are not provided with these English localizations.\n * Also, if any values match the keys, the English localization will be used. This is useful in\n * case you want to pass in a temporary version of the localized strings while your localized\n * strings load.\n *\n * @example\n *\n * ```typescript\n * const myScrollGroupIdLocalizedStrings = {\n * [getLocalizeKeyForScrollGroupId('undefined')]: 'Ø',\n * [getLocalizeKeyForScrollGroupId(0)]: 'A',\n * [getLocalizeKeyForScrollGroupId(1)]: 'B',\n * [getLocalizeKeyForScrollGroupId(2)]: 'C',\n * [getLocalizeKeyForScrollGroupId(3)]: 'D',\n * [getLocalizeKeyForScrollGroupId(4)]: 'E',\n * };\n * ```\n *\n * @example\n *\n * ```tsx\n * const availableScrollGroupIds = [undefined, 0, 1, 2, 3, 4];\n *\n * const localizeKeys = getLocalizeKeysForScrollGroupIds();\n *\n * const [localizedStrings] = useLocalizedStrings(localizeKeys);\n *\n * ...\n *\n * \n * ```\n */\n localizedStrings?: LanguageStrings;\n};\n\n/** Selector component for choosing a scroll group */\nexport default function ScrollGroupSelector({\n availableScrollGroupIds,\n scrollGroupId,\n onChangeScrollGroupId,\n localizedStrings = {},\n}: ScrollGroupSelectorProps) {\n const localizedStringsDefaulted = {\n ...DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS,\n ...Object.fromEntries(\n Object.entries(localizedStrings).map(\n ([localizedStringKey, localizedStringValue]: [string, string]) => [\n localizedStringKey,\n localizedStringKey === localizedStringValue &&\n localizedStringKey in DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS\n ? DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS[localizedStringKey]\n : localizedStringValue,\n ],\n ),\n ),\n };\n return (\n \n onChangeScrollGroupId(\n newScrollGroupString === 'undefined' ? undefined : parseInt(newScrollGroupString, 10),\n )\n }\n >\n \n \n \n \n {availableScrollGroupIds.map((scrollGroupOptionId) => (\n \n {localizedStringsDefaulted[getLocalizeKeyForScrollGroupId(scrollGroupOptionId)]}\n \n ))}\n \n \n );\n}\n","import { PropsWithChildren } from 'react';\nimport { Separator } from '@/components/shadcn-ui/separator';\n\n/** Props for the SettingsList component, currently just children */\ntype SettingsListProps = PropsWithChildren;\n\n/**\n * SettingsList component is a wrapper for list items. Rendered with a formatted div\n *\n * @param children To populate the list with\n * @returns Formatted div encompassing the children\n */\nexport function SettingsList({ children }: SettingsListProps) {\n return
    {children}
    ;\n}\n\n/** Props for SettingsListItem component */\ntype SettingsListItemProps = PropsWithChildren & {\n /** Primary text of the list item */\n primary: string;\n\n /** Optional text of the list item */\n secondary?: string | undefined;\n\n /** Optional boolean to display a message if the children aren't loaded yet. Defaults to false */\n isLoading?: boolean;\n\n /** Optional message to display if isLoading */\n loadingMessage?: string;\n};\n\n/**\n * SettingsListItem component is a common list item. Rendered with a formatted div\n *\n * @param primary Primary text of the list item\n * @param secondary Optional secondary text of the list item\n * @param isLoading Optional, to display a message if the action component isn't generated yet,\n * defaults to false\n * @param children The action component(s) to provide for this item\n * @param loadingMessage Optional, message to display if isLoading\n * @returns Formatted div encompassing the list item content\n */\nexport function SettingsListItem({\n primary,\n secondary,\n children,\n isLoading = false,\n loadingMessage,\n}: SettingsListItemProps) {\n return (\n
    \n
    \n

    {primary}

    \n

    \n {secondary}\n

    \n
    \n\n {isLoading ? (\n

    {loadingMessage}

    \n ) : (\n
    {children}
    \n )}\n
    \n );\n}\n\n/** Props for SettingsListHeader component */\ntype SettingsListHeaderProps = {\n /** The primary text of the list header */\n primary: string;\n\n /** Optional secondary text of the list header */\n secondary?: string | undefined;\n\n /** Optional boolean to include a separator underneath the secondary text. Defaults to false */\n includeSeparator?: boolean;\n};\n\n/**\n * SettingsListHeader component displays text above the list\n *\n * @param primary The primary text of the list header\n * @param secondary Optional secondary text of the list header\n * @param includeSeparator Optional boolean to include a separator underneath the secondary text.\n * Defaults to false\n * @returns Formatted div with list header content\n */\nexport function SettingsListHeader({\n primary,\n secondary,\n includeSeparator = false,\n}: SettingsListHeaderProps) {\n return (\n
    \n
    \n

    {primary}

    \n

    {secondary}

    \n
    \n {includeSeparator ? : ''}\n
    \n );\n}\n","import Checkbox from '@/components/shadcn-ui/checkbox';\nimport { Label } from '@/components/shadcn-ui/label';\n\nexport type ChecklistProps = {\n /** Optional string representing the id attribute of the Checklist */\n id?: string;\n /** Optional string representing CSS class name(s) for styling */\n className?: string;\n /** Array of strings representing the checkable items */\n listItems: string[];\n /** Array of strings representing the checked items */\n selectedListItems: string[];\n /**\n * Function that is called when a checkbox item is selected or deselected\n *\n * @param item The string description for this item\n * @param selected True if selected, false if not selected\n */\n handleSelectListItem: (item: string, selected: boolean) => void;\n\n /**\n * Optional function creates a label for a provided checkable item\n *\n * @param item The item for which a label is to be created\n * @returns A string representing the label text for the checkbox associated with that item\n */\n createLabel?: (item: string) => string;\n};\n\n/** Renders a list of checkboxes. Each checkbox corresponds to an item from the `listItems` array. */\nexport default function Checklist({\n id,\n className,\n listItems,\n selectedListItems,\n handleSelectListItem,\n createLabel,\n}: ChecklistProps) {\n return (\n
    \n {listItems.map((item) => (\n
    \n handleSelectListItem(item, value)}\n />\n \n
    \n ))}\n
    \n );\n}\n","function _interopRequireDefault(obj) {\n return obj && obj.__esModule ? obj : {\n \"default\": obj\n };\n}\nmodule.exports = _interopRequireDefault, module.exports.__esModule = true, module.exports[\"default\"] = module.exports;","export default function chainPropTypes(propType1, propType2) {\n if (process.env.NODE_ENV === 'production') {\n return () => null;\n }\n return function validate(...args) {\n return propType1(...args) || propType2(...args);\n };\n}","export default function _extends() {\n _extends = Object.assign ? Object.assign.bind() : function (target) {\n for (var i = 1; i < arguments.length; i++) {\n var source = arguments[i];\n for (var key in source) {\n if (Object.prototype.hasOwnProperty.call(source, key)) {\n target[key] = source[key];\n }\n }\n }\n return target;\n };\n return _extends.apply(this, arguments);\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\n// https://github.com/sindresorhus/is-plain-obj/blob/main/index.js\nexport function isPlainObject(item) {\n if (typeof item !== 'object' || item === null) {\n return false;\n }\n const prototype = Object.getPrototypeOf(item);\n return (prototype === null || prototype === Object.prototype || Object.getPrototypeOf(prototype) === null) && !(Symbol.toStringTag in item) && !(Symbol.iterator in item);\n}\nfunction deepClone(source) {\n if (!isPlainObject(source)) {\n return source;\n }\n const output = {};\n Object.keys(source).forEach(key => {\n output[key] = deepClone(source[key]);\n });\n return output;\n}\nexport default function deepmerge(target, source, options = {\n clone: true\n}) {\n const output = options.clone ? _extends({}, target) : target;\n if (isPlainObject(target) && isPlainObject(source)) {\n Object.keys(source).forEach(key => {\n // Avoid prototype pollution\n if (key === '__proto__') {\n return;\n }\n if (isPlainObject(source[key]) && key in target && isPlainObject(target[key])) {\n // Since `output` is a clone of `target` and we have narrowed `target` in this block we can cast to the same type.\n output[key] = deepmerge(target[key], source[key], options);\n } else if (options.clone) {\n output[key] = isPlainObject(source[key]) ? deepClone(source[key]) : source[key];\n } else {\n output[key] = source[key];\n }\n });\n }\n return output;\n}","/** @license React v16.13.1\n * react-is.production.min.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';var b=\"function\"===typeof Symbol&&Symbol.for,c=b?Symbol.for(\"react.element\"):60103,d=b?Symbol.for(\"react.portal\"):60106,e=b?Symbol.for(\"react.fragment\"):60107,f=b?Symbol.for(\"react.strict_mode\"):60108,g=b?Symbol.for(\"react.profiler\"):60114,h=b?Symbol.for(\"react.provider\"):60109,k=b?Symbol.for(\"react.context\"):60110,l=b?Symbol.for(\"react.async_mode\"):60111,m=b?Symbol.for(\"react.concurrent_mode\"):60111,n=b?Symbol.for(\"react.forward_ref\"):60112,p=b?Symbol.for(\"react.suspense\"):60113,q=b?\nSymbol.for(\"react.suspense_list\"):60120,r=b?Symbol.for(\"react.memo\"):60115,t=b?Symbol.for(\"react.lazy\"):60116,v=b?Symbol.for(\"react.block\"):60121,w=b?Symbol.for(\"react.fundamental\"):60117,x=b?Symbol.for(\"react.responder\"):60118,y=b?Symbol.for(\"react.scope\"):60119;\nfunction z(a){if(\"object\"===typeof a&&null!==a){var u=a.$$typeof;switch(u){case c:switch(a=a.type,a){case l:case m:case e:case g:case f:case p:return a;default:switch(a=a&&a.$$typeof,a){case k:case n:case t:case r:case h:return a;default:return u}}case d:return u}}}function A(a){return z(a)===m}exports.AsyncMode=l;exports.ConcurrentMode=m;exports.ContextConsumer=k;exports.ContextProvider=h;exports.Element=c;exports.ForwardRef=n;exports.Fragment=e;exports.Lazy=t;exports.Memo=r;exports.Portal=d;\nexports.Profiler=g;exports.StrictMode=f;exports.Suspense=p;exports.isAsyncMode=function(a){return A(a)||z(a)===l};exports.isConcurrentMode=A;exports.isContextConsumer=function(a){return z(a)===k};exports.isContextProvider=function(a){return z(a)===h};exports.isElement=function(a){return\"object\"===typeof a&&null!==a&&a.$$typeof===c};exports.isForwardRef=function(a){return z(a)===n};exports.isFragment=function(a){return z(a)===e};exports.isLazy=function(a){return z(a)===t};\nexports.isMemo=function(a){return z(a)===r};exports.isPortal=function(a){return z(a)===d};exports.isProfiler=function(a){return z(a)===g};exports.isStrictMode=function(a){return z(a)===f};exports.isSuspense=function(a){return z(a)===p};\nexports.isValidElementType=function(a){return\"string\"===typeof a||\"function\"===typeof a||a===e||a===m||a===g||a===f||a===p||a===q||\"object\"===typeof a&&null!==a&&(a.$$typeof===t||a.$$typeof===r||a.$$typeof===h||a.$$typeof===k||a.$$typeof===n||a.$$typeof===w||a.$$typeof===x||a.$$typeof===y||a.$$typeof===v)};exports.typeOf=z;\n","/** @license React v16.13.1\n * react-is.development.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\n\n\nif (process.env.NODE_ENV !== \"production\") {\n (function() {\n'use strict';\n\n// The Symbol used to tag the ReactElement-like types. If there is no native Symbol\n// nor polyfill, then a plain number is used for performance.\nvar hasSymbol = typeof Symbol === 'function' && Symbol.for;\nvar REACT_ELEMENT_TYPE = hasSymbol ? Symbol.for('react.element') : 0xeac7;\nvar REACT_PORTAL_TYPE = hasSymbol ? Symbol.for('react.portal') : 0xeaca;\nvar REACT_FRAGMENT_TYPE = hasSymbol ? Symbol.for('react.fragment') : 0xeacb;\nvar REACT_STRICT_MODE_TYPE = hasSymbol ? Symbol.for('react.strict_mode') : 0xeacc;\nvar REACT_PROFILER_TYPE = hasSymbol ? Symbol.for('react.profiler') : 0xead2;\nvar REACT_PROVIDER_TYPE = hasSymbol ? Symbol.for('react.provider') : 0xeacd;\nvar REACT_CONTEXT_TYPE = hasSymbol ? Symbol.for('react.context') : 0xeace; // TODO: We don't use AsyncMode or ConcurrentMode anymore. They were temporary\n// (unstable) APIs that have been removed. Can we remove the symbols?\n\nvar REACT_ASYNC_MODE_TYPE = hasSymbol ? Symbol.for('react.async_mode') : 0xeacf;\nvar REACT_CONCURRENT_MODE_TYPE = hasSymbol ? Symbol.for('react.concurrent_mode') : 0xeacf;\nvar REACT_FORWARD_REF_TYPE = hasSymbol ? Symbol.for('react.forward_ref') : 0xead0;\nvar REACT_SUSPENSE_TYPE = hasSymbol ? Symbol.for('react.suspense') : 0xead1;\nvar REACT_SUSPENSE_LIST_TYPE = hasSymbol ? Symbol.for('react.suspense_list') : 0xead8;\nvar REACT_MEMO_TYPE = hasSymbol ? Symbol.for('react.memo') : 0xead3;\nvar REACT_LAZY_TYPE = hasSymbol ? Symbol.for('react.lazy') : 0xead4;\nvar REACT_BLOCK_TYPE = hasSymbol ? Symbol.for('react.block') : 0xead9;\nvar REACT_FUNDAMENTAL_TYPE = hasSymbol ? Symbol.for('react.fundamental') : 0xead5;\nvar REACT_RESPONDER_TYPE = hasSymbol ? Symbol.for('react.responder') : 0xead6;\nvar REACT_SCOPE_TYPE = hasSymbol ? Symbol.for('react.scope') : 0xead7;\n\nfunction isValidElementType(type) {\n return typeof type === 'string' || typeof type === 'function' || // Note: its typeof might be other than 'symbol' or 'number' if it's a polyfill.\n type === REACT_FRAGMENT_TYPE || type === REACT_CONCURRENT_MODE_TYPE || type === REACT_PROFILER_TYPE || type === REACT_STRICT_MODE_TYPE || type === REACT_SUSPENSE_TYPE || type === REACT_SUSPENSE_LIST_TYPE || typeof type === 'object' && type !== null && (type.$$typeof === REACT_LAZY_TYPE || type.$$typeof === REACT_MEMO_TYPE || type.$$typeof === REACT_PROVIDER_TYPE || type.$$typeof === REACT_CONTEXT_TYPE || type.$$typeof === REACT_FORWARD_REF_TYPE || type.$$typeof === REACT_FUNDAMENTAL_TYPE || type.$$typeof === REACT_RESPONDER_TYPE || type.$$typeof === REACT_SCOPE_TYPE || type.$$typeof === REACT_BLOCK_TYPE);\n}\n\nfunction typeOf(object) {\n if (typeof object === 'object' && object !== null) {\n var $$typeof = object.$$typeof;\n\n switch ($$typeof) {\n case REACT_ELEMENT_TYPE:\n var type = object.type;\n\n switch (type) {\n case REACT_ASYNC_MODE_TYPE:\n case REACT_CONCURRENT_MODE_TYPE:\n case REACT_FRAGMENT_TYPE:\n case REACT_PROFILER_TYPE:\n case REACT_STRICT_MODE_TYPE:\n case REACT_SUSPENSE_TYPE:\n return type;\n\n default:\n var $$typeofType = type && type.$$typeof;\n\n switch ($$typeofType) {\n case REACT_CONTEXT_TYPE:\n case REACT_FORWARD_REF_TYPE:\n case REACT_LAZY_TYPE:\n case REACT_MEMO_TYPE:\n case REACT_PROVIDER_TYPE:\n return $$typeofType;\n\n default:\n return $$typeof;\n }\n\n }\n\n case REACT_PORTAL_TYPE:\n return $$typeof;\n }\n }\n\n return undefined;\n} // AsyncMode is deprecated along with isAsyncMode\n\nvar AsyncMode = REACT_ASYNC_MODE_TYPE;\nvar ConcurrentMode = REACT_CONCURRENT_MODE_TYPE;\nvar ContextConsumer = REACT_CONTEXT_TYPE;\nvar ContextProvider = REACT_PROVIDER_TYPE;\nvar Element = REACT_ELEMENT_TYPE;\nvar ForwardRef = REACT_FORWARD_REF_TYPE;\nvar Fragment = REACT_FRAGMENT_TYPE;\nvar Lazy = REACT_LAZY_TYPE;\nvar Memo = REACT_MEMO_TYPE;\nvar Portal = REACT_PORTAL_TYPE;\nvar Profiler = REACT_PROFILER_TYPE;\nvar StrictMode = REACT_STRICT_MODE_TYPE;\nvar Suspense = REACT_SUSPENSE_TYPE;\nvar hasWarnedAboutDeprecatedIsAsyncMode = false; // AsyncMode should be deprecated\n\nfunction isAsyncMode(object) {\n {\n if (!hasWarnedAboutDeprecatedIsAsyncMode) {\n hasWarnedAboutDeprecatedIsAsyncMode = true; // Using console['warn'] to evade Babel and ESLint\n\n console['warn']('The ReactIs.isAsyncMode() alias has been deprecated, ' + 'and will be removed in React 17+. Update your code to use ' + 'ReactIs.isConcurrentMode() instead. It has the exact same API.');\n }\n }\n\n return isConcurrentMode(object) || typeOf(object) === REACT_ASYNC_MODE_TYPE;\n}\nfunction isConcurrentMode(object) {\n return typeOf(object) === REACT_CONCURRENT_MODE_TYPE;\n}\nfunction isContextConsumer(object) {\n return typeOf(object) === REACT_CONTEXT_TYPE;\n}\nfunction isContextProvider(object) {\n return typeOf(object) === REACT_PROVIDER_TYPE;\n}\nfunction isElement(object) {\n return typeof object === 'object' && object !== null && object.$$typeof === REACT_ELEMENT_TYPE;\n}\nfunction isForwardRef(object) {\n return typeOf(object) === REACT_FORWARD_REF_TYPE;\n}\nfunction isFragment(object) {\n return typeOf(object) === REACT_FRAGMENT_TYPE;\n}\nfunction isLazy(object) {\n return typeOf(object) === REACT_LAZY_TYPE;\n}\nfunction isMemo(object) {\n return typeOf(object) === REACT_MEMO_TYPE;\n}\nfunction isPortal(object) {\n return typeOf(object) === REACT_PORTAL_TYPE;\n}\nfunction isProfiler(object) {\n return typeOf(object) === REACT_PROFILER_TYPE;\n}\nfunction isStrictMode(object) {\n return typeOf(object) === REACT_STRICT_MODE_TYPE;\n}\nfunction isSuspense(object) {\n return typeOf(object) === REACT_SUSPENSE_TYPE;\n}\n\nexports.AsyncMode = AsyncMode;\nexports.ConcurrentMode = ConcurrentMode;\nexports.ContextConsumer = ContextConsumer;\nexports.ContextProvider = ContextProvider;\nexports.Element = Element;\nexports.ForwardRef = ForwardRef;\nexports.Fragment = Fragment;\nexports.Lazy = Lazy;\nexports.Memo = Memo;\nexports.Portal = Portal;\nexports.Profiler = Profiler;\nexports.StrictMode = StrictMode;\nexports.Suspense = Suspense;\nexports.isAsyncMode = isAsyncMode;\nexports.isConcurrentMode = isConcurrentMode;\nexports.isContextConsumer = isContextConsumer;\nexports.isContextProvider = isContextProvider;\nexports.isElement = isElement;\nexports.isForwardRef = isForwardRef;\nexports.isFragment = isFragment;\nexports.isLazy = isLazy;\nexports.isMemo = isMemo;\nexports.isPortal = isPortal;\nexports.isProfiler = isProfiler;\nexports.isStrictMode = isStrictMode;\nexports.isSuspense = isSuspense;\nexports.isValidElementType = isValidElementType;\nexports.typeOf = typeOf;\n })();\n}\n","'use strict';\n\nif (process.env.NODE_ENV === 'production') {\n module.exports = require('./cjs/react-is.production.min.js');\n} else {\n module.exports = require('./cjs/react-is.development.js');\n}\n","/*\nobject-assign\n(c) Sindre Sorhus\n@license MIT\n*/\n\n'use strict';\n/* eslint-disable no-unused-vars */\nvar getOwnPropertySymbols = Object.getOwnPropertySymbols;\nvar hasOwnProperty = Object.prototype.hasOwnProperty;\nvar propIsEnumerable = Object.prototype.propertyIsEnumerable;\n\nfunction toObject(val) {\n\tif (val === null || val === undefined) {\n\t\tthrow new TypeError('Object.assign cannot be called with null or undefined');\n\t}\n\n\treturn Object(val);\n}\n\nfunction shouldUseNative() {\n\ttry {\n\t\tif (!Object.assign) {\n\t\t\treturn false;\n\t\t}\n\n\t\t// Detect buggy property enumeration order in older V8 versions.\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=4118\n\t\tvar test1 = new String('abc'); // eslint-disable-line no-new-wrappers\n\t\ttest1[5] = 'de';\n\t\tif (Object.getOwnPropertyNames(test1)[0] === '5') {\n\t\t\treturn false;\n\t\t}\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=3056\n\t\tvar test2 = {};\n\t\tfor (var i = 0; i < 10; i++) {\n\t\t\ttest2['_' + String.fromCharCode(i)] = i;\n\t\t}\n\t\tvar order2 = Object.getOwnPropertyNames(test2).map(function (n) {\n\t\t\treturn test2[n];\n\t\t});\n\t\tif (order2.join('') !== '0123456789') {\n\t\t\treturn false;\n\t\t}\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=3056\n\t\tvar test3 = {};\n\t\t'abcdefghijklmnopqrst'.split('').forEach(function (letter) {\n\t\t\ttest3[letter] = letter;\n\t\t});\n\t\tif (Object.keys(Object.assign({}, test3)).join('') !==\n\t\t\t\t'abcdefghijklmnopqrst') {\n\t\t\treturn false;\n\t\t}\n\n\t\treturn true;\n\t} catch (err) {\n\t\t// We don't expect any of the above to throw, but better to be safe.\n\t\treturn false;\n\t}\n}\n\nmodule.exports = shouldUseNative() ? Object.assign : function (target, source) {\n\tvar from;\n\tvar to = toObject(target);\n\tvar symbols;\n\n\tfor (var s = 1; s < arguments.length; s++) {\n\t\tfrom = Object(arguments[s]);\n\n\t\tfor (var key in from) {\n\t\t\tif (hasOwnProperty.call(from, key)) {\n\t\t\t\tto[key] = from[key];\n\t\t\t}\n\t\t}\n\n\t\tif (getOwnPropertySymbols) {\n\t\t\tsymbols = getOwnPropertySymbols(from);\n\t\t\tfor (var i = 0; i < symbols.length; i++) {\n\t\t\t\tif (propIsEnumerable.call(from, symbols[i])) {\n\t\t\t\t\tto[symbols[i]] = from[symbols[i]];\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\n\treturn to;\n};\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar ReactPropTypesSecret = 'SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED';\n\nmodule.exports = ReactPropTypesSecret;\n","module.exports = Function.call.bind(Object.prototype.hasOwnProperty);\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar printWarning = function() {};\n\nif (process.env.NODE_ENV !== 'production') {\n var ReactPropTypesSecret = require('./lib/ReactPropTypesSecret');\n var loggedTypeFailures = {};\n var has = require('./lib/has');\n\n printWarning = function(text) {\n var message = 'Warning: ' + text;\n if (typeof console !== 'undefined') {\n console.error(message);\n }\n try {\n // --- Welcome to debugging React ---\n // This error was thrown as a convenience so that you can use this stack\n // to find the callsite that caused this warning to fire.\n throw new Error(message);\n } catch (x) { /**/ }\n };\n}\n\n/**\n * Assert that the values match with the type specs.\n * Error messages are memorized and will only be shown once.\n *\n * @param {object} typeSpecs Map of name to a ReactPropType\n * @param {object} values Runtime values that need to be type-checked\n * @param {string} location e.g. \"prop\", \"context\", \"child context\"\n * @param {string} componentName Name of the component for error messages.\n * @param {?Function} getStack Returns the component stack.\n * @private\n */\nfunction checkPropTypes(typeSpecs, values, location, componentName, getStack) {\n if (process.env.NODE_ENV !== 'production') {\n for (var typeSpecName in typeSpecs) {\n if (has(typeSpecs, typeSpecName)) {\n var error;\n // Prop type validation may throw. In case they do, we don't want to\n // fail the render phase where it didn't fail before. So we log it.\n // After these have been cleaned up, we'll let them throw.\n try {\n // This is intentionally an invariant that gets caught. It's the same\n // behavior as without this statement except with a better message.\n if (typeof typeSpecs[typeSpecName] !== 'function') {\n var err = Error(\n (componentName || 'React class') + ': ' + location + ' type `' + typeSpecName + '` is invalid; ' +\n 'it must be a function, usually from the `prop-types` package, but received `' + typeof typeSpecs[typeSpecName] + '`.' +\n 'This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.'\n );\n err.name = 'Invariant Violation';\n throw err;\n }\n error = typeSpecs[typeSpecName](values, typeSpecName, componentName, location, null, ReactPropTypesSecret);\n } catch (ex) {\n error = ex;\n }\n if (error && !(error instanceof Error)) {\n printWarning(\n (componentName || 'React class') + ': type specification of ' +\n location + ' `' + typeSpecName + '` is invalid; the type checker ' +\n 'function must return `null` or an `Error` but returned a ' + typeof error + '. ' +\n 'You may have forgotten to pass an argument to the type checker ' +\n 'creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and ' +\n 'shape all require an argument).'\n );\n }\n if (error instanceof Error && !(error.message in loggedTypeFailures)) {\n // Only monitor this failure once because there tends to be a lot of the\n // same error.\n loggedTypeFailures[error.message] = true;\n\n var stack = getStack ? getStack() : '';\n\n printWarning(\n 'Failed ' + location + ' type: ' + error.message + (stack != null ? stack : '')\n );\n }\n }\n }\n }\n}\n\n/**\n * Resets warning cache when testing.\n *\n * @private\n */\ncheckPropTypes.resetWarningCache = function() {\n if (process.env.NODE_ENV !== 'production') {\n loggedTypeFailures = {};\n }\n}\n\nmodule.exports = checkPropTypes;\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar ReactIs = require('react-is');\nvar assign = require('object-assign');\n\nvar ReactPropTypesSecret = require('./lib/ReactPropTypesSecret');\nvar has = require('./lib/has');\nvar checkPropTypes = require('./checkPropTypes');\n\nvar printWarning = function() {};\n\nif (process.env.NODE_ENV !== 'production') {\n printWarning = function(text) {\n var message = 'Warning: ' + text;\n if (typeof console !== 'undefined') {\n console.error(message);\n }\n try {\n // --- Welcome to debugging React ---\n // This error was thrown as a convenience so that you can use this stack\n // to find the callsite that caused this warning to fire.\n throw new Error(message);\n } catch (x) {}\n };\n}\n\nfunction emptyFunctionThatReturnsNull() {\n return null;\n}\n\nmodule.exports = function(isValidElement, throwOnDirectAccess) {\n /* global Symbol */\n var ITERATOR_SYMBOL = typeof Symbol === 'function' && Symbol.iterator;\n var FAUX_ITERATOR_SYMBOL = '@@iterator'; // Before Symbol spec.\n\n /**\n * Returns the iterator method function contained on the iterable object.\n *\n * Be sure to invoke the function with the iterable as context:\n *\n * var iteratorFn = getIteratorFn(myIterable);\n * if (iteratorFn) {\n * var iterator = iteratorFn.call(myIterable);\n * ...\n * }\n *\n * @param {?object} maybeIterable\n * @return {?function}\n */\n function getIteratorFn(maybeIterable) {\n var iteratorFn = maybeIterable && (ITERATOR_SYMBOL && maybeIterable[ITERATOR_SYMBOL] || maybeIterable[FAUX_ITERATOR_SYMBOL]);\n if (typeof iteratorFn === 'function') {\n return iteratorFn;\n }\n }\n\n /**\n * Collection of methods that allow declaration and validation of props that are\n * supplied to React components. Example usage:\n *\n * var Props = require('ReactPropTypes');\n * var MyArticle = React.createClass({\n * propTypes: {\n * // An optional string prop named \"description\".\n * description: Props.string,\n *\n * // A required enum prop named \"category\".\n * category: Props.oneOf(['News','Photos']).isRequired,\n *\n * // A prop named \"dialog\" that requires an instance of Dialog.\n * dialog: Props.instanceOf(Dialog).isRequired\n * },\n * render: function() { ... }\n * });\n *\n * A more formal specification of how these methods are used:\n *\n * type := array|bool|func|object|number|string|oneOf([...])|instanceOf(...)\n * decl := ReactPropTypes.{type}(.isRequired)?\n *\n * Each and every declaration produces a function with the same signature. This\n * allows the creation of custom validation functions. For example:\n *\n * var MyLink = React.createClass({\n * propTypes: {\n * // An optional string or URI prop named \"href\".\n * href: function(props, propName, componentName) {\n * var propValue = props[propName];\n * if (propValue != null && typeof propValue !== 'string' &&\n * !(propValue instanceof URI)) {\n * return new Error(\n * 'Expected a string or an URI for ' + propName + ' in ' +\n * componentName\n * );\n * }\n * }\n * },\n * render: function() {...}\n * });\n *\n * @internal\n */\n\n var ANONYMOUS = '<>';\n\n // Important!\n // Keep this list in sync with production version in `./factoryWithThrowingShims.js`.\n var ReactPropTypes = {\n array: createPrimitiveTypeChecker('array'),\n bigint: createPrimitiveTypeChecker('bigint'),\n bool: createPrimitiveTypeChecker('boolean'),\n func: createPrimitiveTypeChecker('function'),\n number: createPrimitiveTypeChecker('number'),\n object: createPrimitiveTypeChecker('object'),\n string: createPrimitiveTypeChecker('string'),\n symbol: createPrimitiveTypeChecker('symbol'),\n\n any: createAnyTypeChecker(),\n arrayOf: createArrayOfTypeChecker,\n element: createElementTypeChecker(),\n elementType: createElementTypeTypeChecker(),\n instanceOf: createInstanceTypeChecker,\n node: createNodeChecker(),\n objectOf: createObjectOfTypeChecker,\n oneOf: createEnumTypeChecker,\n oneOfType: createUnionTypeChecker,\n shape: createShapeTypeChecker,\n exact: createStrictShapeTypeChecker,\n };\n\n /**\n * inlined Object.is polyfill to avoid requiring consumers ship their own\n * https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object/is\n */\n /*eslint-disable no-self-compare*/\n function is(x, y) {\n // SameValue algorithm\n if (x === y) {\n // Steps 1-5, 7-10\n // Steps 6.b-6.e: +0 != -0\n return x !== 0 || 1 / x === 1 / y;\n } else {\n // Step 6.a: NaN == NaN\n return x !== x && y !== y;\n }\n }\n /*eslint-enable no-self-compare*/\n\n /**\n * We use an Error-like object for backward compatibility as people may call\n * PropTypes directly and inspect their output. However, we don't use real\n * Errors anymore. We don't inspect their stack anyway, and creating them\n * is prohibitively expensive if they are created too often, such as what\n * happens in oneOfType() for any type before the one that matched.\n */\n function PropTypeError(message, data) {\n this.message = message;\n this.data = data && typeof data === 'object' ? data: {};\n this.stack = '';\n }\n // Make `instanceof Error` still work for returned errors.\n PropTypeError.prototype = Error.prototype;\n\n function createChainableTypeChecker(validate) {\n if (process.env.NODE_ENV !== 'production') {\n var manualPropTypeCallCache = {};\n var manualPropTypeWarningCount = 0;\n }\n function checkType(isRequired, props, propName, componentName, location, propFullName, secret) {\n componentName = componentName || ANONYMOUS;\n propFullName = propFullName || propName;\n\n if (secret !== ReactPropTypesSecret) {\n if (throwOnDirectAccess) {\n // New behavior only for users of `prop-types` package\n var err = new Error(\n 'Calling PropTypes validators directly is not supported by the `prop-types` package. ' +\n 'Use `PropTypes.checkPropTypes()` to call them. ' +\n 'Read more at http://fb.me/use-check-prop-types'\n );\n err.name = 'Invariant Violation';\n throw err;\n } else if (process.env.NODE_ENV !== 'production' && typeof console !== 'undefined') {\n // Old behavior for people using React.PropTypes\n var cacheKey = componentName + ':' + propName;\n if (\n !manualPropTypeCallCache[cacheKey] &&\n // Avoid spamming the console because they are often not actionable except for lib authors\n manualPropTypeWarningCount < 3\n ) {\n printWarning(\n 'You are manually calling a React.PropTypes validation ' +\n 'function for the `' + propFullName + '` prop on `' + componentName + '`. This is deprecated ' +\n 'and will throw in the standalone `prop-types` package. ' +\n 'You may be seeing this warning due to a third-party PropTypes ' +\n 'library. See https://fb.me/react-warning-dont-call-proptypes ' + 'for details.'\n );\n manualPropTypeCallCache[cacheKey] = true;\n manualPropTypeWarningCount++;\n }\n }\n }\n if (props[propName] == null) {\n if (isRequired) {\n if (props[propName] === null) {\n return new PropTypeError('The ' + location + ' `' + propFullName + '` is marked as required ' + ('in `' + componentName + '`, but its value is `null`.'));\n }\n return new PropTypeError('The ' + location + ' `' + propFullName + '` is marked as required in ' + ('`' + componentName + '`, but its value is `undefined`.'));\n }\n return null;\n } else {\n return validate(props, propName, componentName, location, propFullName);\n }\n }\n\n var chainedCheckType = checkType.bind(null, false);\n chainedCheckType.isRequired = checkType.bind(null, true);\n\n return chainedCheckType;\n }\n\n function createPrimitiveTypeChecker(expectedType) {\n function validate(props, propName, componentName, location, propFullName, secret) {\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== expectedType) {\n // `propValue` being instance of, say, date/regexp, pass the 'object'\n // check, but we can offer a more precise error message here rather than\n // 'of type `object`'.\n var preciseType = getPreciseType(propValue);\n\n return new PropTypeError(\n 'Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + preciseType + '` supplied to `' + componentName + '`, expected ') + ('`' + expectedType + '`.'),\n {expectedType: expectedType}\n );\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createAnyTypeChecker() {\n return createChainableTypeChecker(emptyFunctionThatReturnsNull);\n }\n\n function createArrayOfTypeChecker(typeChecker) {\n function validate(props, propName, componentName, location, propFullName) {\n if (typeof typeChecker !== 'function') {\n return new PropTypeError('Property `' + propFullName + '` of component `' + componentName + '` has invalid PropType notation inside arrayOf.');\n }\n var propValue = props[propName];\n if (!Array.isArray(propValue)) {\n var propType = getPropType(propValue);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected an array.'));\n }\n for (var i = 0; i < propValue.length; i++) {\n var error = typeChecker(propValue, i, componentName, location, propFullName + '[' + i + ']', ReactPropTypesSecret);\n if (error instanceof Error) {\n return error;\n }\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createElementTypeChecker() {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n if (!isValidElement(propValue)) {\n var propType = getPropType(propValue);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected a single ReactElement.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createElementTypeTypeChecker() {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n if (!ReactIs.isValidElementType(propValue)) {\n var propType = getPropType(propValue);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected a single ReactElement type.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createInstanceTypeChecker(expectedClass) {\n function validate(props, propName, componentName, location, propFullName) {\n if (!(props[propName] instanceof expectedClass)) {\n var expectedClassName = expectedClass.name || ANONYMOUS;\n var actualClassName = getClassName(props[propName]);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + actualClassName + '` supplied to `' + componentName + '`, expected ') + ('instance of `' + expectedClassName + '`.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createEnumTypeChecker(expectedValues) {\n if (!Array.isArray(expectedValues)) {\n if (process.env.NODE_ENV !== 'production') {\n if (arguments.length > 1) {\n printWarning(\n 'Invalid arguments supplied to oneOf, expected an array, got ' + arguments.length + ' arguments. ' +\n 'A common mistake is to write oneOf(x, y, z) instead of oneOf([x, y, z]).'\n );\n } else {\n printWarning('Invalid argument supplied to oneOf, expected an array.');\n }\n }\n return emptyFunctionThatReturnsNull;\n }\n\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n for (var i = 0; i < expectedValues.length; i++) {\n if (is(propValue, expectedValues[i])) {\n return null;\n }\n }\n\n var valuesString = JSON.stringify(expectedValues, function replacer(key, value) {\n var type = getPreciseType(value);\n if (type === 'symbol') {\n return String(value);\n }\n return value;\n });\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of value `' + String(propValue) + '` ' + ('supplied to `' + componentName + '`, expected one of ' + valuesString + '.'));\n }\n return createChainableTypeChecker(validate);\n }\n\n function createObjectOfTypeChecker(typeChecker) {\n function validate(props, propName, componentName, location, propFullName) {\n if (typeof typeChecker !== 'function') {\n return new PropTypeError('Property `' + propFullName + '` of component `' + componentName + '` has invalid PropType notation inside objectOf.');\n }\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== 'object') {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected an object.'));\n }\n for (var key in propValue) {\n if (has(propValue, key)) {\n var error = typeChecker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret);\n if (error instanceof Error) {\n return error;\n }\n }\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createUnionTypeChecker(arrayOfTypeCheckers) {\n if (!Array.isArray(arrayOfTypeCheckers)) {\n process.env.NODE_ENV !== 'production' ? printWarning('Invalid argument supplied to oneOfType, expected an instance of array.') : void 0;\n return emptyFunctionThatReturnsNull;\n }\n\n for (var i = 0; i < arrayOfTypeCheckers.length; i++) {\n var checker = arrayOfTypeCheckers[i];\n if (typeof checker !== 'function') {\n printWarning(\n 'Invalid argument supplied to oneOfType. Expected an array of check functions, but ' +\n 'received ' + getPostfixForTypeWarning(checker) + ' at index ' + i + '.'\n );\n return emptyFunctionThatReturnsNull;\n }\n }\n\n function validate(props, propName, componentName, location, propFullName) {\n var expectedTypes = [];\n for (var i = 0; i < arrayOfTypeCheckers.length; i++) {\n var checker = arrayOfTypeCheckers[i];\n var checkerResult = checker(props, propName, componentName, location, propFullName, ReactPropTypesSecret);\n if (checkerResult == null) {\n return null;\n }\n if (checkerResult.data && has(checkerResult.data, 'expectedType')) {\n expectedTypes.push(checkerResult.data.expectedType);\n }\n }\n var expectedTypesMessage = (expectedTypes.length > 0) ? ', expected one of type [' + expectedTypes.join(', ') + ']': '';\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` supplied to ' + ('`' + componentName + '`' + expectedTypesMessage + '.'));\n }\n return createChainableTypeChecker(validate);\n }\n\n function createNodeChecker() {\n function validate(props, propName, componentName, location, propFullName) {\n if (!isNode(props[propName])) {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` supplied to ' + ('`' + componentName + '`, expected a ReactNode.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function invalidValidatorError(componentName, location, propFullName, key, type) {\n return new PropTypeError(\n (componentName || 'React class') + ': ' + location + ' type `' + propFullName + '.' + key + '` is invalid; ' +\n 'it must be a function, usually from the `prop-types` package, but received `' + type + '`.'\n );\n }\n\n function createShapeTypeChecker(shapeTypes) {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== 'object') {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type `' + propType + '` ' + ('supplied to `' + componentName + '`, expected `object`.'));\n }\n for (var key in shapeTypes) {\n var checker = shapeTypes[key];\n if (typeof checker !== 'function') {\n return invalidValidatorError(componentName, location, propFullName, key, getPreciseType(checker));\n }\n var error = checker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret);\n if (error) {\n return error;\n }\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createStrictShapeTypeChecker(shapeTypes) {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== 'object') {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type `' + propType + '` ' + ('supplied to `' + componentName + '`, expected `object`.'));\n }\n // We need to check all keys in case some are required but missing from props.\n var allKeys = assign({}, props[propName], shapeTypes);\n for (var key in allKeys) {\n var checker = shapeTypes[key];\n if (has(shapeTypes, key) && typeof checker !== 'function') {\n return invalidValidatorError(componentName, location, propFullName, key, getPreciseType(checker));\n }\n if (!checker) {\n return new PropTypeError(\n 'Invalid ' + location + ' `' + propFullName + '` key `' + key + '` supplied to `' + componentName + '`.' +\n '\\nBad object: ' + JSON.stringify(props[propName], null, ' ') +\n '\\nValid keys: ' + JSON.stringify(Object.keys(shapeTypes), null, ' ')\n );\n }\n var error = checker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret);\n if (error) {\n return error;\n }\n }\n return null;\n }\n\n return createChainableTypeChecker(validate);\n }\n\n function isNode(propValue) {\n switch (typeof propValue) {\n case 'number':\n case 'string':\n case 'undefined':\n return true;\n case 'boolean':\n return !propValue;\n case 'object':\n if (Array.isArray(propValue)) {\n return propValue.every(isNode);\n }\n if (propValue === null || isValidElement(propValue)) {\n return true;\n }\n\n var iteratorFn = getIteratorFn(propValue);\n if (iteratorFn) {\n var iterator = iteratorFn.call(propValue);\n var step;\n if (iteratorFn !== propValue.entries) {\n while (!(step = iterator.next()).done) {\n if (!isNode(step.value)) {\n return false;\n }\n }\n } else {\n // Iterator will provide entry [k,v] tuples rather than values.\n while (!(step = iterator.next()).done) {\n var entry = step.value;\n if (entry) {\n if (!isNode(entry[1])) {\n return false;\n }\n }\n }\n }\n } else {\n return false;\n }\n\n return true;\n default:\n return false;\n }\n }\n\n function isSymbol(propType, propValue) {\n // Native Symbol.\n if (propType === 'symbol') {\n return true;\n }\n\n // falsy value can't be a Symbol\n if (!propValue) {\n return false;\n }\n\n // 19.4.3.5 Symbol.prototype[@@toStringTag] === 'Symbol'\n if (propValue['@@toStringTag'] === 'Symbol') {\n return true;\n }\n\n // Fallback for non-spec compliant Symbols which are polyfilled.\n if (typeof Symbol === 'function' && propValue instanceof Symbol) {\n return true;\n }\n\n return false;\n }\n\n // Equivalent of `typeof` but with special handling for array and regexp.\n function getPropType(propValue) {\n var propType = typeof propValue;\n if (Array.isArray(propValue)) {\n return 'array';\n }\n if (propValue instanceof RegExp) {\n // Old webkits (at least until Android 4.0) return 'function' rather than\n // 'object' for typeof a RegExp. We'll normalize this here so that /bla/\n // passes PropTypes.object.\n return 'object';\n }\n if (isSymbol(propType, propValue)) {\n return 'symbol';\n }\n return propType;\n }\n\n // This handles more types than `getPropType`. Only used for error messages.\n // See `createPrimitiveTypeChecker`.\n function getPreciseType(propValue) {\n if (typeof propValue === 'undefined' || propValue === null) {\n return '' + propValue;\n }\n var propType = getPropType(propValue);\n if (propType === 'object') {\n if (propValue instanceof Date) {\n return 'date';\n } else if (propValue instanceof RegExp) {\n return 'regexp';\n }\n }\n return propType;\n }\n\n // Returns a string that is postfixed to a warning about an invalid type.\n // For example, \"undefined\" or \"of type array\"\n function getPostfixForTypeWarning(value) {\n var type = getPreciseType(value);\n switch (type) {\n case 'array':\n case 'object':\n return 'an ' + type;\n case 'boolean':\n case 'date':\n case 'regexp':\n return 'a ' + type;\n default:\n return type;\n }\n }\n\n // Returns class name of the object, if any.\n function getClassName(propValue) {\n if (!propValue.constructor || !propValue.constructor.name) {\n return ANONYMOUS;\n }\n return propValue.constructor.name;\n }\n\n ReactPropTypes.checkPropTypes = checkPropTypes;\n ReactPropTypes.resetWarningCache = checkPropTypes.resetWarningCache;\n ReactPropTypes.PropTypes = ReactPropTypes;\n\n return ReactPropTypes;\n};\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar ReactPropTypesSecret = require('./lib/ReactPropTypesSecret');\n\nfunction emptyFunction() {}\nfunction emptyFunctionWithReset() {}\nemptyFunctionWithReset.resetWarningCache = emptyFunction;\n\nmodule.exports = function() {\n function shim(props, propName, componentName, location, propFullName, secret) {\n if (secret === ReactPropTypesSecret) {\n // It is still safe when called from React.\n return;\n }\n var err = new Error(\n 'Calling PropTypes validators directly is not supported by the `prop-types` package. ' +\n 'Use PropTypes.checkPropTypes() to call them. ' +\n 'Read more at http://fb.me/use-check-prop-types'\n );\n err.name = 'Invariant Violation';\n throw err;\n };\n shim.isRequired = shim;\n function getShim() {\n return shim;\n };\n // Important!\n // Keep this list in sync with production version in `./factoryWithTypeCheckers.js`.\n var ReactPropTypes = {\n array: shim,\n bigint: shim,\n bool: shim,\n func: shim,\n number: shim,\n object: shim,\n string: shim,\n symbol: shim,\n\n any: shim,\n arrayOf: getShim,\n element: shim,\n elementType: shim,\n instanceOf: getShim,\n node: shim,\n objectOf: getShim,\n oneOf: getShim,\n oneOfType: getShim,\n shape: getShim,\n exact: getShim,\n\n checkPropTypes: emptyFunctionWithReset,\n resetWarningCache: emptyFunction\n };\n\n ReactPropTypes.PropTypes = ReactPropTypes;\n\n return ReactPropTypes;\n};\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\nif (process.env.NODE_ENV !== 'production') {\n var ReactIs = require('react-is');\n\n // By explicitly using `prop-types` you are opting into new development behavior.\n // http://fb.me/prop-types-in-prod\n var throwOnDirectAccess = true;\n module.exports = require('./factoryWithTypeCheckers')(ReactIs.isElement, throwOnDirectAccess);\n} else {\n // By explicitly using `prop-types` you are opting into new production behavior.\n // http://fb.me/prop-types-in-prod\n module.exports = require('./factoryWithThrowingShims')();\n}\n","import PropTypes from 'prop-types';\nimport chainPropTypes from '../chainPropTypes';\nfunction isClassComponent(elementType) {\n // elementType.prototype?.isReactComponent\n const {\n prototype = {}\n } = elementType;\n return Boolean(prototype.isReactComponent);\n}\nfunction acceptingRef(props, propName, componentName, location, propFullName) {\n const element = props[propName];\n const safePropName = propFullName || propName;\n if (element == null ||\n // When server-side rendering React doesn't warn either.\n // This is not an accurate check for SSR.\n // This is only in place for Emotion compat.\n // TODO: Revisit once https://github.com/facebook/react/issues/20047 is resolved.\n typeof window === 'undefined') {\n return null;\n }\n let warningHint;\n const elementType = element.type;\n /**\n * Blacklisting instead of whitelisting\n *\n * Blacklisting will miss some components, such as React.Fragment. Those will at least\n * trigger a warning in React.\n * We can't whitelist because there is no safe way to detect React.forwardRef\n * or class components. \"Safe\" means there's no public API.\n *\n */\n if (typeof elementType === 'function' && !isClassComponent(elementType)) {\n warningHint = 'Did you accidentally use a plain function component for an element instead?';\n }\n if (warningHint !== undefined) {\n return new Error(`Invalid ${location} \\`${safePropName}\\` supplied to \\`${componentName}\\`. ` + `Expected an element that can hold a ref. ${warningHint} ` + 'For more information see https://mui.com/r/caveat-with-refs-guide');\n }\n return null;\n}\nconst elementAcceptingRef = chainPropTypes(PropTypes.element, acceptingRef);\nelementAcceptingRef.isRequired = chainPropTypes(PropTypes.element.isRequired, acceptingRef);\nexport default elementAcceptingRef;","import _extends from \"@babel/runtime/helpers/esm/extends\";\n// This module is based on https://github.com/airbnb/prop-types-exact repository.\n// However, in order to reduce the number of dependencies and to remove some extra safe checks\n// the module was forked.\n\nconst specialProperty = 'exact-prop: \\u200b';\nexport default function exactProp(propTypes) {\n if (process.env.NODE_ENV === 'production') {\n return propTypes;\n }\n return _extends({}, propTypes, {\n [specialProperty]: props => {\n const unsupportedProps = Object.keys(props).filter(prop => !propTypes.hasOwnProperty(prop));\n if (unsupportedProps.length > 0) {\n return new Error(`The following props are not supported: ${unsupportedProps.map(prop => `\\`${prop}\\``).join(', ')}. Please remove them.`);\n }\n return null;\n }\n });\n}","/**\n * WARNING: Don't import this directly.\n * Use `MuiError` from `@mui/internal-babel-macros/MuiError.macro` instead.\n * @param {number} code\n */\nexport default function formatMuiErrorMessage(code) {\n // Apply babel-plugin-transform-template-literals in loose mode\n // loose mode is safe if we're concatenating primitives\n // see https://babeljs.io/docs/en/babel-plugin-transform-template-literals#loose\n /* eslint-disable prefer-template */\n let url = 'https://mui.com/production-error/?code=' + code;\n for (let i = 1; i < arguments.length; i += 1) {\n // rest params over-transpile for this case\n // eslint-disable-next-line prefer-rest-params\n url += '&args[]=' + encodeURIComponent(arguments[i]);\n }\n return 'Minified MUI error #' + code + '; visit ' + url + ' for the full message.';\n /* eslint-enable prefer-template */\n}","/**\n * @license React\n * react-is.production.min.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n'use strict';var b=Symbol.for(\"react.element\"),c=Symbol.for(\"react.portal\"),d=Symbol.for(\"react.fragment\"),e=Symbol.for(\"react.strict_mode\"),f=Symbol.for(\"react.profiler\"),g=Symbol.for(\"react.provider\"),h=Symbol.for(\"react.context\"),k=Symbol.for(\"react.server_context\"),l=Symbol.for(\"react.forward_ref\"),m=Symbol.for(\"react.suspense\"),n=Symbol.for(\"react.suspense_list\"),p=Symbol.for(\"react.memo\"),q=Symbol.for(\"react.lazy\"),t=Symbol.for(\"react.offscreen\"),u;u=Symbol.for(\"react.module.reference\");\nfunction v(a){if(\"object\"===typeof a&&null!==a){var r=a.$$typeof;switch(r){case b:switch(a=a.type,a){case d:case f:case e:case m:case n:return a;default:switch(a=a&&a.$$typeof,a){case k:case h:case l:case q:case p:case g:return a;default:return r}}case c:return r}}}exports.ContextConsumer=h;exports.ContextProvider=g;exports.Element=b;exports.ForwardRef=l;exports.Fragment=d;exports.Lazy=q;exports.Memo=p;exports.Portal=c;exports.Profiler=f;exports.StrictMode=e;exports.Suspense=m;\nexports.SuspenseList=n;exports.isAsyncMode=function(){return!1};exports.isConcurrentMode=function(){return!1};exports.isContextConsumer=function(a){return v(a)===h};exports.isContextProvider=function(a){return v(a)===g};exports.isElement=function(a){return\"object\"===typeof a&&null!==a&&a.$$typeof===b};exports.isForwardRef=function(a){return v(a)===l};exports.isFragment=function(a){return v(a)===d};exports.isLazy=function(a){return v(a)===q};exports.isMemo=function(a){return v(a)===p};\nexports.isPortal=function(a){return v(a)===c};exports.isProfiler=function(a){return v(a)===f};exports.isStrictMode=function(a){return v(a)===e};exports.isSuspense=function(a){return v(a)===m};exports.isSuspenseList=function(a){return v(a)===n};\nexports.isValidElementType=function(a){return\"string\"===typeof a||\"function\"===typeof a||a===d||a===f||a===e||a===m||a===n||a===t||\"object\"===typeof a&&null!==a&&(a.$$typeof===q||a.$$typeof===p||a.$$typeof===g||a.$$typeof===h||a.$$typeof===l||a.$$typeof===u||void 0!==a.getModuleId)?!0:!1};exports.typeOf=v;\n","/**\n * @license React\n * react-is.development.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nif (process.env.NODE_ENV !== \"production\") {\n (function() {\n'use strict';\n\n// ATTENTION\n// When adding new symbols to this file,\n// Please consider also adding to 'react-devtools-shared/src/backend/ReactSymbols'\n// The Symbol used to tag the ReactElement-like types.\nvar REACT_ELEMENT_TYPE = Symbol.for('react.element');\nvar REACT_PORTAL_TYPE = Symbol.for('react.portal');\nvar REACT_FRAGMENT_TYPE = Symbol.for('react.fragment');\nvar REACT_STRICT_MODE_TYPE = Symbol.for('react.strict_mode');\nvar REACT_PROFILER_TYPE = Symbol.for('react.profiler');\nvar REACT_PROVIDER_TYPE = Symbol.for('react.provider');\nvar REACT_CONTEXT_TYPE = Symbol.for('react.context');\nvar REACT_SERVER_CONTEXT_TYPE = Symbol.for('react.server_context');\nvar REACT_FORWARD_REF_TYPE = Symbol.for('react.forward_ref');\nvar REACT_SUSPENSE_TYPE = Symbol.for('react.suspense');\nvar REACT_SUSPENSE_LIST_TYPE = Symbol.for('react.suspense_list');\nvar REACT_MEMO_TYPE = Symbol.for('react.memo');\nvar REACT_LAZY_TYPE = Symbol.for('react.lazy');\nvar REACT_OFFSCREEN_TYPE = Symbol.for('react.offscreen');\n\n// -----------------------------------------------------------------------------\n\nvar enableScopeAPI = false; // Experimental Create Event Handle API.\nvar enableCacheElement = false;\nvar enableTransitionTracing = false; // No known bugs, but needs performance testing\n\nvar enableLegacyHidden = false; // Enables unstable_avoidThisFallback feature in Fiber\n// stuff. Intended to enable React core members to more easily debug scheduling\n// issues in DEV builds.\n\nvar enableDebugTracing = false; // Track which Fiber(s) schedule render work.\n\nvar REACT_MODULE_REFERENCE;\n\n{\n REACT_MODULE_REFERENCE = Symbol.for('react.module.reference');\n}\n\nfunction isValidElementType(type) {\n if (typeof type === 'string' || typeof type === 'function') {\n return true;\n } // Note: typeof might be other than 'symbol' or 'number' (e.g. if it's a polyfill).\n\n\n if (type === REACT_FRAGMENT_TYPE || type === REACT_PROFILER_TYPE || enableDebugTracing || type === REACT_STRICT_MODE_TYPE || type === REACT_SUSPENSE_TYPE || type === REACT_SUSPENSE_LIST_TYPE || enableLegacyHidden || type === REACT_OFFSCREEN_TYPE || enableScopeAPI || enableCacheElement || enableTransitionTracing ) {\n return true;\n }\n\n if (typeof type === 'object' && type !== null) {\n if (type.$$typeof === REACT_LAZY_TYPE || type.$$typeof === REACT_MEMO_TYPE || type.$$typeof === REACT_PROVIDER_TYPE || type.$$typeof === REACT_CONTEXT_TYPE || type.$$typeof === REACT_FORWARD_REF_TYPE || // This needs to include all possible module reference object\n // types supported by any Flight configuration anywhere since\n // we don't know which Flight build this will end up being used\n // with.\n type.$$typeof === REACT_MODULE_REFERENCE || type.getModuleId !== undefined) {\n return true;\n }\n }\n\n return false;\n}\n\nfunction typeOf(object) {\n if (typeof object === 'object' && object !== null) {\n var $$typeof = object.$$typeof;\n\n switch ($$typeof) {\n case REACT_ELEMENT_TYPE:\n var type = object.type;\n\n switch (type) {\n case REACT_FRAGMENT_TYPE:\n case REACT_PROFILER_TYPE:\n case REACT_STRICT_MODE_TYPE:\n case REACT_SUSPENSE_TYPE:\n case REACT_SUSPENSE_LIST_TYPE:\n return type;\n\n default:\n var $$typeofType = type && type.$$typeof;\n\n switch ($$typeofType) {\n case REACT_SERVER_CONTEXT_TYPE:\n case REACT_CONTEXT_TYPE:\n case REACT_FORWARD_REF_TYPE:\n case REACT_LAZY_TYPE:\n case REACT_MEMO_TYPE:\n case REACT_PROVIDER_TYPE:\n return $$typeofType;\n\n default:\n return $$typeof;\n }\n\n }\n\n case REACT_PORTAL_TYPE:\n return $$typeof;\n }\n }\n\n return undefined;\n}\nvar ContextConsumer = REACT_CONTEXT_TYPE;\nvar ContextProvider = REACT_PROVIDER_TYPE;\nvar Element = REACT_ELEMENT_TYPE;\nvar ForwardRef = REACT_FORWARD_REF_TYPE;\nvar Fragment = REACT_FRAGMENT_TYPE;\nvar Lazy = REACT_LAZY_TYPE;\nvar Memo = REACT_MEMO_TYPE;\nvar Portal = REACT_PORTAL_TYPE;\nvar Profiler = REACT_PROFILER_TYPE;\nvar StrictMode = REACT_STRICT_MODE_TYPE;\nvar Suspense = REACT_SUSPENSE_TYPE;\nvar SuspenseList = REACT_SUSPENSE_LIST_TYPE;\nvar hasWarnedAboutDeprecatedIsAsyncMode = false;\nvar hasWarnedAboutDeprecatedIsConcurrentMode = false; // AsyncMode should be deprecated\n\nfunction isAsyncMode(object) {\n {\n if (!hasWarnedAboutDeprecatedIsAsyncMode) {\n hasWarnedAboutDeprecatedIsAsyncMode = true; // Using console['warn'] to evade Babel and ESLint\n\n console['warn']('The ReactIs.isAsyncMode() alias has been deprecated, ' + 'and will be removed in React 18+.');\n }\n }\n\n return false;\n}\nfunction isConcurrentMode(object) {\n {\n if (!hasWarnedAboutDeprecatedIsConcurrentMode) {\n hasWarnedAboutDeprecatedIsConcurrentMode = true; // Using console['warn'] to evade Babel and ESLint\n\n console['warn']('The ReactIs.isConcurrentMode() alias has been deprecated, ' + 'and will be removed in React 18+.');\n }\n }\n\n return false;\n}\nfunction isContextConsumer(object) {\n return typeOf(object) === REACT_CONTEXT_TYPE;\n}\nfunction isContextProvider(object) {\n return typeOf(object) === REACT_PROVIDER_TYPE;\n}\nfunction isElement(object) {\n return typeof object === 'object' && object !== null && object.$$typeof === REACT_ELEMENT_TYPE;\n}\nfunction isForwardRef(object) {\n return typeOf(object) === REACT_FORWARD_REF_TYPE;\n}\nfunction isFragment(object) {\n return typeOf(object) === REACT_FRAGMENT_TYPE;\n}\nfunction isLazy(object) {\n return typeOf(object) === REACT_LAZY_TYPE;\n}\nfunction isMemo(object) {\n return typeOf(object) === REACT_MEMO_TYPE;\n}\nfunction isPortal(object) {\n return typeOf(object) === REACT_PORTAL_TYPE;\n}\nfunction isProfiler(object) {\n return typeOf(object) === REACT_PROFILER_TYPE;\n}\nfunction isStrictMode(object) {\n return typeOf(object) === REACT_STRICT_MODE_TYPE;\n}\nfunction isSuspense(object) {\n return typeOf(object) === REACT_SUSPENSE_TYPE;\n}\nfunction isSuspenseList(object) {\n return typeOf(object) === REACT_SUSPENSE_LIST_TYPE;\n}\n\nexports.ContextConsumer = ContextConsumer;\nexports.ContextProvider = ContextProvider;\nexports.Element = Element;\nexports.ForwardRef = ForwardRef;\nexports.Fragment = Fragment;\nexports.Lazy = Lazy;\nexports.Memo = Memo;\nexports.Portal = Portal;\nexports.Profiler = Profiler;\nexports.StrictMode = StrictMode;\nexports.Suspense = Suspense;\nexports.SuspenseList = SuspenseList;\nexports.isAsyncMode = isAsyncMode;\nexports.isConcurrentMode = isConcurrentMode;\nexports.isContextConsumer = isContextConsumer;\nexports.isContextProvider = isContextProvider;\nexports.isElement = isElement;\nexports.isForwardRef = isForwardRef;\nexports.isFragment = isFragment;\nexports.isLazy = isLazy;\nexports.isMemo = isMemo;\nexports.isPortal = isPortal;\nexports.isProfiler = isProfiler;\nexports.isStrictMode = isStrictMode;\nexports.isSuspense = isSuspense;\nexports.isSuspenseList = isSuspenseList;\nexports.isValidElementType = isValidElementType;\nexports.typeOf = typeOf;\n })();\n}\n","'use strict';\n\nif (process.env.NODE_ENV === 'production') {\n module.exports = require('./cjs/react-is.production.min.js');\n} else {\n module.exports = require('./cjs/react-is.development.js');\n}\n","import { ForwardRef, Memo } from 'react-is';\n\n// Simplified polyfill for IE11 support\n// https://github.com/JamesMGreene/Function.name/blob/58b314d4a983110c3682f1228f845d39ccca1817/Function.name.js#L3\nconst fnNameMatchRegex = /^\\s*function(?:\\s|\\s*\\/\\*.*\\*\\/\\s*)+([^(\\s/]*)\\s*/;\nexport function getFunctionName(fn) {\n const match = `${fn}`.match(fnNameMatchRegex);\n const name = match && match[1];\n return name || '';\n}\nfunction getFunctionComponentName(Component, fallback = '') {\n return Component.displayName || Component.name || getFunctionName(Component) || fallback;\n}\nfunction getWrappedName(outerType, innerType, wrapperName) {\n const functionName = getFunctionComponentName(innerType);\n return outerType.displayName || (functionName !== '' ? `${wrapperName}(${functionName})` : wrapperName);\n}\n\n/**\n * cherry-pick from\n * https://github.com/facebook/react/blob/769b1f270e1251d9dbdce0fcbd9e92e502d059b8/packages/shared/getComponentName.js\n * originally forked from recompose/getDisplayName with added IE11 support\n */\nexport default function getDisplayName(Component) {\n if (Component == null) {\n return undefined;\n }\n if (typeof Component === 'string') {\n return Component;\n }\n if (typeof Component === 'function') {\n return getFunctionComponentName(Component, 'Component');\n }\n\n // TypeScript can't have components as objects but they exist in the form of `memo` or `Suspense`\n if (typeof Component === 'object') {\n switch (Component.$$typeof) {\n case ForwardRef:\n return getWrappedName(Component, Component.render, 'ForwardRef');\n case Memo:\n return getWrappedName(Component, Component.type, 'memo');\n default:\n return undefined;\n }\n }\n return undefined;\n}","export default function HTMLElementType(props, propName, componentName, location, propFullName) {\n if (process.env.NODE_ENV === 'production') {\n return null;\n }\n const propValue = props[propName];\n const safePropName = propFullName || propName;\n if (propValue == null) {\n return null;\n }\n if (propValue && propValue.nodeType !== 1) {\n return new Error(`Invalid ${location} \\`${safePropName}\\` supplied to \\`${componentName}\\`. ` + `Expected an HTMLElement.`);\n }\n return null;\n}","import PropTypes from 'prop-types';\nconst refType = PropTypes.oneOfType([PropTypes.func, PropTypes.object]);\nexport default refType;","import _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\n// It should to be noted that this function isn't equivalent to `text-transform: capitalize`.\n//\n// A strict capitalization should uppercase the first letter of each word in the sentence.\n// We only handle the first word.\nexport default function capitalize(string) {\n if (typeof string !== 'string') {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: \\`capitalize(string)\\` expects a string argument.` : _formatMuiErrorMessage(7));\n }\n return string.charAt(0).toUpperCase() + string.slice(1);\n}","/**\n * Safe chained function.\n *\n * Will only create a new function if needed,\n * otherwise will pass back existing functions or null.\n */\nexport default function createChainedFunction(...funcs) {\n return funcs.reduce((acc, func) => {\n if (func == null) {\n return acc;\n }\n return function chainedFunction(...args) {\n acc.apply(this, args);\n func.apply(this, args);\n };\n }, () => {});\n}","// Corresponds to 10 frames at 60 Hz.\n// A few bytes payload overhead when lodash/debounce is ~3 kB and debounce ~300 B.\nexport default function debounce(func, wait = 166) {\n let timeout;\n function debounced(...args) {\n const later = () => {\n // @ts-ignore\n func.apply(this, args);\n };\n clearTimeout(timeout);\n timeout = setTimeout(later, wait);\n }\n debounced.clear = () => {\n clearTimeout(timeout);\n };\n return debounced;\n}","export default function deprecatedPropType(validator, reason) {\n if (process.env.NODE_ENV === 'production') {\n return () => null;\n }\n return (props, propName, componentName, location, propFullName) => {\n const componentNameSafe = componentName || '<>';\n const propFullNameSafe = propFullName || propName;\n if (typeof props[propName] !== 'undefined') {\n return new Error(`The ${location} \\`${propFullNameSafe}\\` of ` + `\\`${componentNameSafe}\\` is deprecated. ${reason}`);\n }\n return null;\n };\n}","import * as React from 'react';\nexport default function isMuiElement(element, muiNames) {\n var _muiName, _element$type;\n return /*#__PURE__*/React.isValidElement(element) && muiNames.indexOf( // For server components `muiName` is avaialble in element.type._payload.value.muiName\n // relevant info - https://github.com/facebook/react/blob/2807d781a08db8e9873687fccc25c0f12b4fb3d4/packages/react/src/ReactLazy.js#L45\n // eslint-disable-next-line no-underscore-dangle\n (_muiName = element.type.muiName) != null ? _muiName : (_element$type = element.type) == null || (_element$type = _element$type._payload) == null || (_element$type = _element$type.value) == null ? void 0 : _element$type.muiName) !== -1;\n}","export default function ownerDocument(node) {\n return node && node.ownerDocument || document;\n}","import ownerDocument from '../ownerDocument';\nexport default function ownerWindow(node) {\n const doc = ownerDocument(node);\n return doc.defaultView || window;\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nexport default function requirePropFactory(componentNameInError, Component) {\n if (process.env.NODE_ENV === 'production') {\n return () => null;\n }\n\n // eslint-disable-next-line react/forbid-foreign-prop-types\n const prevPropTypes = Component ? _extends({}, Component.propTypes) : null;\n const requireProp = requiredProp => (props, propName, componentName, location, propFullName, ...args) => {\n const propFullNameSafe = propFullName || propName;\n const defaultTypeChecker = prevPropTypes == null ? void 0 : prevPropTypes[propFullNameSafe];\n if (defaultTypeChecker) {\n const typeCheckerResult = defaultTypeChecker(props, propName, componentName, location, propFullName, ...args);\n if (typeCheckerResult) {\n return typeCheckerResult;\n }\n }\n if (typeof props[propName] !== 'undefined' && !props[requiredProp]) {\n return new Error(`The prop \\`${propFullNameSafe}\\` of ` + `\\`${componentNameInError}\\` can only be used together with the \\`${requiredProp}\\` prop.`);\n }\n return null;\n };\n return requireProp;\n}","/**\n * TODO v5: consider making it private\n *\n * passes {value} to {ref}\n *\n * WARNING: Be sure to only call this inside a callback that is passed as a ref.\n * Otherwise, make sure to cleanup the previous {ref} if it changes. See\n * https://github.com/mui/material-ui/issues/13539\n *\n * Useful if you want to expose the ref of an inner component to the public API\n * while still using it inside the component.\n * @param ref A ref callback or ref object. If anything falsy, this is a no-op.\n */\nexport default function setRef(ref, value) {\n if (typeof ref === 'function') {\n ref(value);\n } else if (ref) {\n ref.current = value;\n }\n}","'use client';\n\nimport * as React from 'react';\n\n/**\n * A version of `React.useLayoutEffect` that does not show a warning when server-side rendering.\n * This is useful for effects that are only needed for client-side rendering but not for SSR.\n *\n * Before you use this hook, make sure to read https://gist.github.com/gaearon/e7d97cdf38a2907924ea12e4ebdf3c85\n * and confirm it doesn't apply to your use-case.\n */\nconst useEnhancedEffect = typeof window !== 'undefined' ? React.useLayoutEffect : React.useEffect;\nexport default useEnhancedEffect;","'use client';\n\nimport * as React from 'react';\nlet globalId = 0;\nfunction useGlobalId(idOverride) {\n const [defaultId, setDefaultId] = React.useState(idOverride);\n const id = idOverride || defaultId;\n React.useEffect(() => {\n if (defaultId == null) {\n // Fallback to this default id when possible.\n // Use the incrementing value for client-side rendering only.\n // We can't use it server-side.\n // If you want to use random values please consider the Birthday Problem: https://en.wikipedia.org/wiki/Birthday_problem\n globalId += 1;\n setDefaultId(`mui-${globalId}`);\n }\n }, [defaultId]);\n return id;\n}\n\n// downstream bundlers may remove unnecessary concatenation, but won't remove toString call -- Workaround for https://github.com/webpack/webpack/issues/14814\nconst maybeReactUseId = React['useId'.toString()];\n/**\n *\n * @example
    \n * @param idOverride\n * @returns {string}\n */\nexport default function useId(idOverride) {\n if (maybeReactUseId !== undefined) {\n const reactId = maybeReactUseId();\n return idOverride != null ? idOverride : reactId;\n }\n // eslint-disable-next-line react-hooks/rules-of-hooks -- `React.useId` is invariant at runtime.\n return useGlobalId(idOverride);\n}","export default function unsupportedProp(props, propName, componentName, location, propFullName) {\n if (process.env.NODE_ENV === 'production') {\n return null;\n }\n const propFullNameSafe = propFullName || propName;\n if (typeof props[propName] !== 'undefined') {\n return new Error(`The prop \\`${propFullNameSafe}\\` is not supported. Please remove it.`);\n }\n return null;\n}","'use client';\n\n/* eslint-disable react-hooks/rules-of-hooks, react-hooks/exhaustive-deps */\nimport * as React from 'react';\nexport default function useControlled({\n controlled,\n default: defaultProp,\n name,\n state = 'value'\n}) {\n // isControlled is ignored in the hook dependency lists as it should never change.\n const {\n current: isControlled\n } = React.useRef(controlled !== undefined);\n const [valueState, setValue] = React.useState(defaultProp);\n const value = isControlled ? controlled : valueState;\n if (process.env.NODE_ENV !== 'production') {\n React.useEffect(() => {\n if (isControlled !== (controlled !== undefined)) {\n console.error([`MUI: A component is changing the ${isControlled ? '' : 'un'}controlled ${state} state of ${name} to be ${isControlled ? 'un' : ''}controlled.`, 'Elements should not switch from uncontrolled to controlled (or vice versa).', `Decide between using a controlled or uncontrolled ${name} ` + 'element for the lifetime of the component.', \"The nature of the state is determined during the first render. It's considered controlled if the value is not `undefined`.\", 'More info: https://fb.me/react-controlled-components'].join('\\n'));\n }\n }, [state, name, controlled]);\n const {\n current: defaultValue\n } = React.useRef(defaultProp);\n React.useEffect(() => {\n if (!isControlled && defaultValue !== defaultProp) {\n console.error([`MUI: A component is changing the default ${state} state of an uncontrolled ${name} after being initialized. ` + `To suppress this warning opt to use a controlled ${name}.`].join('\\n'));\n }\n }, [JSON.stringify(defaultProp)]);\n }\n const setValueIfUncontrolled = React.useCallback(newValue => {\n if (!isControlled) {\n setValue(newValue);\n }\n }, []);\n return [value, setValueIfUncontrolled];\n}","'use client';\n\nimport * as React from 'react';\nimport useEnhancedEffect from '../useEnhancedEffect';\n\n/**\n * Inspired by https://github.com/facebook/react/issues/14099#issuecomment-440013892\n * See RFC in https://github.com/reactjs/rfcs/pull/220\n */\n\nfunction useEventCallback(fn) {\n const ref = React.useRef(fn);\n useEnhancedEffect(() => {\n ref.current = fn;\n });\n return React.useRef((...args) =>\n // @ts-expect-error hide `this`\n (0, ref.current)(...args)).current;\n}\nexport default useEventCallback;","'use client';\n\nimport * as React from 'react';\nimport setRef from '../setRef';\nexport default function useForkRef(...refs) {\n /**\n * This will create a new function if the refs passed to this hook change and are all defined.\n * This means react will call the old forkRef with `null` and the new forkRef\n * with the ref. Cleanup naturally emerges from this behavior.\n */\n return React.useMemo(() => {\n if (refs.every(ref => ref == null)) {\n return null;\n }\n return instance => {\n refs.forEach(ref => {\n setRef(ref, instance);\n });\n };\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, refs);\n}","'use client';\n\nimport * as React from 'react';\nconst UNINITIALIZED = {};\n\n/**\n * A React.useRef() that is initialized lazily with a function. Note that it accepts an optional\n * initialization argument, so the initialization function doesn't need to be an inline closure.\n *\n * @usage\n * const ref = useLazyRef(sortColumns, columns)\n */\nexport default function useLazyRef(init, initArg) {\n const ref = React.useRef(UNINITIALIZED);\n if (ref.current === UNINITIALIZED) {\n ref.current = init(initArg);\n }\n return ref;\n}","'use client';\n\nimport * as React from 'react';\nconst EMPTY = [];\n\n/**\n * A React.useEffect equivalent that runs once, when the component is mounted.\n */\nexport default function useOnMount(fn) {\n /* eslint-disable react-hooks/exhaustive-deps */\n React.useEffect(fn, EMPTY);\n /* eslint-enable react-hooks/exhaustive-deps */\n}","'use client';\n\nimport useLazyRef from '../useLazyRef/useLazyRef';\nimport useOnMount from '../useOnMount/useOnMount';\nexport class Timeout {\n constructor() {\n this.currentId = null;\n this.clear = () => {\n if (this.currentId !== null) {\n clearTimeout(this.currentId);\n this.currentId = null;\n }\n };\n this.disposeEffect = () => {\n return this.clear;\n };\n }\n static create() {\n return new Timeout();\n }\n /**\n * Executes `fn` after `delay`, clearing any previously scheduled call.\n */\n start(delay, fn) {\n this.clear();\n this.currentId = setTimeout(() => {\n this.currentId = null;\n fn();\n }, delay);\n }\n}\nexport default function useTimeout() {\n const timeout = useLazyRef(Timeout.create).current;\n useOnMount(timeout.disposeEffect);\n return timeout;\n}","'use client';\n\n// based on https://github.com/WICG/focus-visible/blob/v4.1.5/src/focus-visible.js\nimport * as React from 'react';\nimport { Timeout } from '../useTimeout/useTimeout';\nlet hadKeyboardEvent = true;\nlet hadFocusVisibleRecently = false;\nconst hadFocusVisibleRecentlyTimeout = new Timeout();\nconst inputTypesWhitelist = {\n text: true,\n search: true,\n url: true,\n tel: true,\n email: true,\n password: true,\n number: true,\n date: true,\n month: true,\n week: true,\n time: true,\n datetime: true,\n 'datetime-local': true\n};\n\n/**\n * Computes whether the given element should automatically trigger the\n * `focus-visible` class being added, i.e. whether it should always match\n * `:focus-visible` when focused.\n * @param {Element} node\n * @returns {boolean}\n */\nfunction focusTriggersKeyboardModality(node) {\n const {\n type,\n tagName\n } = node;\n if (tagName === 'INPUT' && inputTypesWhitelist[type] && !node.readOnly) {\n return true;\n }\n if (tagName === 'TEXTAREA' && !node.readOnly) {\n return true;\n }\n if (node.isContentEditable) {\n return true;\n }\n return false;\n}\n\n/**\n * Keep track of our keyboard modality state with `hadKeyboardEvent`.\n * If the most recent user interaction was via the keyboard;\n * and the key press did not include a meta, alt/option, or control key;\n * then the modality is keyboard. Otherwise, the modality is not keyboard.\n * @param {KeyboardEvent} event\n */\nfunction handleKeyDown(event) {\n if (event.metaKey || event.altKey || event.ctrlKey) {\n return;\n }\n hadKeyboardEvent = true;\n}\n\n/**\n * If at any point a user clicks with a pointing device, ensure that we change\n * the modality away from keyboard.\n * This avoids the situation where a user presses a key on an already focused\n * element, and then clicks on a different element, focusing it with a\n * pointing device, while we still think we're in keyboard modality.\n */\nfunction handlePointerDown() {\n hadKeyboardEvent = false;\n}\nfunction handleVisibilityChange() {\n if (this.visibilityState === 'hidden') {\n // If the tab becomes active again, the browser will handle calling focus\n // on the element (Safari actually calls it twice).\n // If this tab change caused a blur on an element with focus-visible,\n // re-apply the class when the user switches back to the tab.\n if (hadFocusVisibleRecently) {\n hadKeyboardEvent = true;\n }\n }\n}\nfunction prepare(doc) {\n doc.addEventListener('keydown', handleKeyDown, true);\n doc.addEventListener('mousedown', handlePointerDown, true);\n doc.addEventListener('pointerdown', handlePointerDown, true);\n doc.addEventListener('touchstart', handlePointerDown, true);\n doc.addEventListener('visibilitychange', handleVisibilityChange, true);\n}\nexport function teardown(doc) {\n doc.removeEventListener('keydown', handleKeyDown, true);\n doc.removeEventListener('mousedown', handlePointerDown, true);\n doc.removeEventListener('pointerdown', handlePointerDown, true);\n doc.removeEventListener('touchstart', handlePointerDown, true);\n doc.removeEventListener('visibilitychange', handleVisibilityChange, true);\n}\nfunction isFocusVisible(event) {\n const {\n target\n } = event;\n try {\n return target.matches(':focus-visible');\n } catch (error) {\n // Browsers not implementing :focus-visible will throw a SyntaxError.\n // We use our own heuristic for those browsers.\n // Rethrow might be better if it's not the expected error but do we really\n // want to crash if focus-visible malfunctioned?\n }\n\n // No need for validFocusTarget check. The user does that by attaching it to\n // focusable events only.\n return hadKeyboardEvent || focusTriggersKeyboardModality(target);\n}\nexport default function useIsFocusVisible() {\n const ref = React.useCallback(node => {\n if (node != null) {\n prepare(node.ownerDocument);\n }\n }, []);\n const isFocusVisibleRef = React.useRef(false);\n\n /**\n * Should be called if a blur event is fired\n */\n function handleBlurVisible() {\n // checking against potential state variable does not suffice if we focus and blur synchronously.\n // React wouldn't have time to trigger a re-render so `focusVisible` would be stale.\n // Ideally we would adjust `isFocusVisible(event)` to look at `relatedTarget` for blur events.\n // This doesn't work in IE11 due to https://github.com/facebook/react/issues/3751\n // TODO: check again if React releases their internal changes to focus event handling (https://github.com/facebook/react/pull/19186).\n if (isFocusVisibleRef.current) {\n // To detect a tab/window switch, we look for a blur event followed\n // rapidly by a visibility change.\n // If we don't see a visibility change within 100ms, it's probably a\n // regular focus change.\n hadFocusVisibleRecently = true;\n hadFocusVisibleRecentlyTimeout.start(100, () => {\n hadFocusVisibleRecently = false;\n });\n isFocusVisibleRef.current = false;\n return true;\n }\n return false;\n }\n\n /**\n * Should be called if a blur event is fired\n */\n function handleFocusVisible(event) {\n if (isFocusVisible(event)) {\n isFocusVisibleRef.current = true;\n return true;\n }\n return false;\n }\n return {\n isFocusVisibleRef,\n onFocus: handleFocusVisible,\n onBlur: handleBlurVisible,\n ref\n };\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\n/**\n * Add keys, values of `defaultProps` that does not exist in `props`\n * @param {object} defaultProps\n * @param {object} props\n * @returns {object} resolved props\n */\nexport default function resolveProps(defaultProps, props) {\n const output = _extends({}, props);\n Object.keys(defaultProps).forEach(propName => {\n if (propName.toString().match(/^(components|slots)$/)) {\n output[propName] = _extends({}, defaultProps[propName], output[propName]);\n } else if (propName.toString().match(/^(componentsProps|slotProps)$/)) {\n const defaultSlotProps = defaultProps[propName] || {};\n const slotProps = props[propName];\n output[propName] = {};\n if (!slotProps || !Object.keys(slotProps)) {\n // Reduce the iteration if the slot props is empty\n output[propName] = defaultSlotProps;\n } else if (!defaultSlotProps || !Object.keys(defaultSlotProps)) {\n // Reduce the iteration if the default slot props is empty\n output[propName] = slotProps;\n } else {\n output[propName] = _extends({}, slotProps);\n Object.keys(defaultSlotProps).forEach(slotPropName => {\n output[propName][slotPropName] = resolveProps(defaultSlotProps[slotPropName], slotProps[slotPropName]);\n });\n }\n } else if (output[propName] === undefined) {\n output[propName] = defaultProps[propName];\n }\n });\n return output;\n}","export default function composeClasses(slots, getUtilityClass, classes = undefined) {\n const output = {};\n Object.keys(slots).forEach(\n // `Object.keys(slots)` can't be wider than `T` because we infer `T` from `slots`.\n // @ts-expect-error https://github.com/microsoft/TypeScript/pull/12253#issuecomment-263132208\n slot => {\n output[slot] = slots[slot].reduce((acc, key) => {\n if (key) {\n const utilityClass = getUtilityClass(key);\n if (utilityClass !== '') {\n acc.push(utilityClass);\n }\n if (classes && classes[key]) {\n acc.push(classes[key]);\n }\n }\n return acc;\n }, []).join(' ');\n });\n return output;\n}","const defaultGenerator = componentName => componentName;\nconst createClassNameGenerator = () => {\n let generate = defaultGenerator;\n return {\n configure(generator) {\n generate = generator;\n },\n generate(componentName) {\n return generate(componentName);\n },\n reset() {\n generate = defaultGenerator;\n }\n };\n};\nconst ClassNameGenerator = createClassNameGenerator();\nexport default ClassNameGenerator;","import ClassNameGenerator from '../ClassNameGenerator';\nexport const globalStateClasses = {\n active: 'active',\n checked: 'checked',\n completed: 'completed',\n disabled: 'disabled',\n error: 'error',\n expanded: 'expanded',\n focused: 'focused',\n focusVisible: 'focusVisible',\n open: 'open',\n readOnly: 'readOnly',\n required: 'required',\n selected: 'selected'\n};\nexport default function generateUtilityClass(componentName, slot, globalStatePrefix = 'Mui') {\n const globalStateClass = globalStateClasses[slot];\n return globalStateClass ? `${globalStatePrefix}-${globalStateClass}` : `${ClassNameGenerator.generate(componentName)}-${slot}`;\n}\nexport function isGlobalState(slot) {\n return globalStateClasses[slot] !== undefined;\n}","import generateUtilityClass from '../generateUtilityClass';\nexport default function generateUtilityClasses(componentName, slots, globalStatePrefix = 'Mui') {\n const result = {};\n slots.forEach(slot => {\n result[slot] = generateUtilityClass(componentName, slot, globalStatePrefix);\n });\n return result;\n}","function clamp(val, min = Number.MIN_SAFE_INTEGER, max = Number.MAX_SAFE_INTEGER) {\n return Math.max(min, Math.min(val, max));\n}\nexport default clamp;","export default function _objectWithoutPropertiesLoose(source, excluded) {\n if (source == null) return {};\n var target = {};\n var sourceKeys = Object.keys(source);\n var key, i;\n for (i = 0; i < sourceKeys.length; i++) {\n key = sourceKeys[i];\n if (excluded.indexOf(key) >= 0) continue;\n target[key] = source[key];\n }\n return target;\n}","import _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nconst _excluded = [\"values\", \"unit\", \"step\"];\n// Sorted ASC by size. That's important.\n// It can't be configured as it's used statically for propTypes.\nexport const breakpointKeys = ['xs', 'sm', 'md', 'lg', 'xl'];\nconst sortBreakpointsValues = values => {\n const breakpointsAsArray = Object.keys(values).map(key => ({\n key,\n val: values[key]\n })) || [];\n // Sort in ascending order\n breakpointsAsArray.sort((breakpoint1, breakpoint2) => breakpoint1.val - breakpoint2.val);\n return breakpointsAsArray.reduce((acc, obj) => {\n return _extends({}, acc, {\n [obj.key]: obj.val\n });\n }, {});\n};\n\n// Keep in mind that @media is inclusive by the CSS specification.\nexport default function createBreakpoints(breakpoints) {\n const {\n // The breakpoint **start** at this value.\n // For instance with the first breakpoint xs: [xs, sm).\n values = {\n xs: 0,\n // phone\n sm: 600,\n // tablet\n md: 900,\n // small laptop\n lg: 1200,\n // desktop\n xl: 1536 // large screen\n },\n unit = 'px',\n step = 5\n } = breakpoints,\n other = _objectWithoutPropertiesLoose(breakpoints, _excluded);\n const sortedValues = sortBreakpointsValues(values);\n const keys = Object.keys(sortedValues);\n function up(key) {\n const value = typeof values[key] === 'number' ? values[key] : key;\n return `@media (min-width:${value}${unit})`;\n }\n function down(key) {\n const value = typeof values[key] === 'number' ? values[key] : key;\n return `@media (max-width:${value - step / 100}${unit})`;\n }\n function between(start, end) {\n const endIndex = keys.indexOf(end);\n return `@media (min-width:${typeof values[start] === 'number' ? values[start] : start}${unit}) and ` + `(max-width:${(endIndex !== -1 && typeof values[keys[endIndex]] === 'number' ? values[keys[endIndex]] : end) - step / 100}${unit})`;\n }\n function only(key) {\n if (keys.indexOf(key) + 1 < keys.length) {\n return between(key, keys[keys.indexOf(key) + 1]);\n }\n return up(key);\n }\n function not(key) {\n // handle first and last key separately, for better readability\n const keyIndex = keys.indexOf(key);\n if (keyIndex === 0) {\n return up(keys[1]);\n }\n if (keyIndex === keys.length - 1) {\n return down(keys[keyIndex]);\n }\n return between(key, keys[keys.indexOf(key) + 1]).replace('@media', '@media not all and');\n }\n return _extends({\n keys,\n values: sortedValues,\n up,\n down,\n between,\n only,\n not,\n unit\n }, other);\n}","const shape = {\n borderRadius: 4\n};\nexport default shape;","import PropTypes from 'prop-types';\nconst responsivePropType = process.env.NODE_ENV !== 'production' ? PropTypes.oneOfType([PropTypes.number, PropTypes.string, PropTypes.object, PropTypes.array]) : {};\nexport default responsivePropType;","import deepmerge from '@mui/utils/deepmerge';\nfunction merge(acc, item) {\n if (!item) {\n return acc;\n }\n return deepmerge(acc, item, {\n clone: false // No need to clone deep, it's way faster.\n });\n}\nexport default merge;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport PropTypes from 'prop-types';\nimport deepmerge from '@mui/utils/deepmerge';\nimport merge from './merge';\n\n// The breakpoint **start** at this value.\n// For instance with the first breakpoint xs: [xs, sm[.\nexport const values = {\n xs: 0,\n // phone\n sm: 600,\n // tablet\n md: 900,\n // small laptop\n lg: 1200,\n // desktop\n xl: 1536 // large screen\n};\nconst defaultBreakpoints = {\n // Sorted ASC by size. That's important.\n // It can't be configured as it's used statically for propTypes.\n keys: ['xs', 'sm', 'md', 'lg', 'xl'],\n up: key => `@media (min-width:${values[key]}px)`\n};\nexport function handleBreakpoints(props, propValue, styleFromPropValue) {\n const theme = props.theme || {};\n if (Array.isArray(propValue)) {\n const themeBreakpoints = theme.breakpoints || defaultBreakpoints;\n return propValue.reduce((acc, item, index) => {\n acc[themeBreakpoints.up(themeBreakpoints.keys[index])] = styleFromPropValue(propValue[index]);\n return acc;\n }, {});\n }\n if (typeof propValue === 'object') {\n const themeBreakpoints = theme.breakpoints || defaultBreakpoints;\n return Object.keys(propValue).reduce((acc, breakpoint) => {\n // key is breakpoint\n if (Object.keys(themeBreakpoints.values || values).indexOf(breakpoint) !== -1) {\n const mediaKey = themeBreakpoints.up(breakpoint);\n acc[mediaKey] = styleFromPropValue(propValue[breakpoint], breakpoint);\n } else {\n const cssKey = breakpoint;\n acc[cssKey] = propValue[cssKey];\n }\n return acc;\n }, {});\n }\n const output = styleFromPropValue(propValue);\n return output;\n}\nfunction breakpoints(styleFunction) {\n // false positive\n // eslint-disable-next-line react/function-component-definition\n const newStyleFunction = props => {\n const theme = props.theme || {};\n const base = styleFunction(props);\n const themeBreakpoints = theme.breakpoints || defaultBreakpoints;\n const extended = themeBreakpoints.keys.reduce((acc, key) => {\n if (props[key]) {\n acc = acc || {};\n acc[themeBreakpoints.up(key)] = styleFunction(_extends({\n theme\n }, props[key]));\n }\n return acc;\n }, null);\n return merge(base, extended);\n };\n newStyleFunction.propTypes = process.env.NODE_ENV !== 'production' ? _extends({}, styleFunction.propTypes, {\n xs: PropTypes.object,\n sm: PropTypes.object,\n md: PropTypes.object,\n lg: PropTypes.object,\n xl: PropTypes.object\n }) : {};\n newStyleFunction.filterProps = ['xs', 'sm', 'md', 'lg', 'xl', ...styleFunction.filterProps];\n return newStyleFunction;\n}\nexport function createEmptyBreakpointObject(breakpointsInput = {}) {\n var _breakpointsInput$key;\n const breakpointsInOrder = (_breakpointsInput$key = breakpointsInput.keys) == null ? void 0 : _breakpointsInput$key.reduce((acc, key) => {\n const breakpointStyleKey = breakpointsInput.up(key);\n acc[breakpointStyleKey] = {};\n return acc;\n }, {});\n return breakpointsInOrder || {};\n}\nexport function removeUnusedBreakpoints(breakpointKeys, style) {\n return breakpointKeys.reduce((acc, key) => {\n const breakpointOutput = acc[key];\n const isBreakpointUnused = !breakpointOutput || Object.keys(breakpointOutput).length === 0;\n if (isBreakpointUnused) {\n delete acc[key];\n }\n return acc;\n }, style);\n}\nexport function mergeBreakpointsInOrder(breakpointsInput, ...styles) {\n const emptyBreakpoints = createEmptyBreakpointObject(breakpointsInput);\n const mergedOutput = [emptyBreakpoints, ...styles].reduce((prev, next) => deepmerge(prev, next), {});\n return removeUnusedBreakpoints(Object.keys(emptyBreakpoints), mergedOutput);\n}\n\n// compute base for responsive values; e.g.,\n// [1,2,3] => {xs: true, sm: true, md: true}\n// {xs: 1, sm: 2, md: 3} => {xs: true, sm: true, md: true}\nexport function computeBreakpointsBase(breakpointValues, themeBreakpoints) {\n // fixed value\n if (typeof breakpointValues !== 'object') {\n return {};\n }\n const base = {};\n const breakpointsKeys = Object.keys(themeBreakpoints);\n if (Array.isArray(breakpointValues)) {\n breakpointsKeys.forEach((breakpoint, i) => {\n if (i < breakpointValues.length) {\n base[breakpoint] = true;\n }\n });\n } else {\n breakpointsKeys.forEach(breakpoint => {\n if (breakpointValues[breakpoint] != null) {\n base[breakpoint] = true;\n }\n });\n }\n return base;\n}\nexport function resolveBreakpointValues({\n values: breakpointValues,\n breakpoints: themeBreakpoints,\n base: customBase\n}) {\n const base = customBase || computeBreakpointsBase(breakpointValues, themeBreakpoints);\n const keys = Object.keys(base);\n if (keys.length === 0) {\n return breakpointValues;\n }\n let previous;\n return keys.reduce((acc, breakpoint, i) => {\n if (Array.isArray(breakpointValues)) {\n acc[breakpoint] = breakpointValues[i] != null ? breakpointValues[i] : breakpointValues[previous];\n previous = i;\n } else if (typeof breakpointValues === 'object') {\n acc[breakpoint] = breakpointValues[breakpoint] != null ? breakpointValues[breakpoint] : breakpointValues[previous];\n previous = breakpoint;\n } else {\n acc[breakpoint] = breakpointValues;\n }\n return acc;\n }, {});\n}\nexport default breakpoints;","import capitalize from '@mui/utils/capitalize';\nimport responsivePropType from './responsivePropType';\nimport { handleBreakpoints } from './breakpoints';\nexport function getPath(obj, path, checkVars = true) {\n if (!path || typeof path !== 'string') {\n return null;\n }\n\n // Check if CSS variables are used\n if (obj && obj.vars && checkVars) {\n const val = `vars.${path}`.split('.').reduce((acc, item) => acc && acc[item] ? acc[item] : null, obj);\n if (val != null) {\n return val;\n }\n }\n return path.split('.').reduce((acc, item) => {\n if (acc && acc[item] != null) {\n return acc[item];\n }\n return null;\n }, obj);\n}\nexport function getStyleValue(themeMapping, transform, propValueFinal, userValue = propValueFinal) {\n let value;\n if (typeof themeMapping === 'function') {\n value = themeMapping(propValueFinal);\n } else if (Array.isArray(themeMapping)) {\n value = themeMapping[propValueFinal] || userValue;\n } else {\n value = getPath(themeMapping, propValueFinal) || userValue;\n }\n if (transform) {\n value = transform(value, userValue, themeMapping);\n }\n return value;\n}\nfunction style(options) {\n const {\n prop,\n cssProperty = options.prop,\n themeKey,\n transform\n } = options;\n\n // false positive\n // eslint-disable-next-line react/function-component-definition\n const fn = props => {\n if (props[prop] == null) {\n return null;\n }\n const propValue = props[prop];\n const theme = props.theme;\n const themeMapping = getPath(theme, themeKey) || {};\n const styleFromPropValue = propValueFinal => {\n let value = getStyleValue(themeMapping, transform, propValueFinal);\n if (propValueFinal === value && typeof propValueFinal === 'string') {\n // Haven't found value\n value = getStyleValue(themeMapping, transform, `${prop}${propValueFinal === 'default' ? '' : capitalize(propValueFinal)}`, propValueFinal);\n }\n if (cssProperty === false) {\n return value;\n }\n return {\n [cssProperty]: value\n };\n };\n return handleBreakpoints(props, propValue, styleFromPropValue);\n };\n fn.propTypes = process.env.NODE_ENV !== 'production' ? {\n [prop]: responsivePropType\n } : {};\n fn.filterProps = [prop];\n return fn;\n}\nexport default style;","export default function memoize(fn) {\n const cache = {};\n return arg => {\n if (cache[arg] === undefined) {\n cache[arg] = fn(arg);\n }\n return cache[arg];\n };\n}","import responsivePropType from './responsivePropType';\nimport { handleBreakpoints } from './breakpoints';\nimport { getPath } from './style';\nimport merge from './merge';\nimport memoize from './memoize';\nconst properties = {\n m: 'margin',\n p: 'padding'\n};\nconst directions = {\n t: 'Top',\n r: 'Right',\n b: 'Bottom',\n l: 'Left',\n x: ['Left', 'Right'],\n y: ['Top', 'Bottom']\n};\nconst aliases = {\n marginX: 'mx',\n marginY: 'my',\n paddingX: 'px',\n paddingY: 'py'\n};\n\n// memoize() impact:\n// From 300,000 ops/sec\n// To 350,000 ops/sec\nconst getCssProperties = memoize(prop => {\n // It's not a shorthand notation.\n if (prop.length > 2) {\n if (aliases[prop]) {\n prop = aliases[prop];\n } else {\n return [prop];\n }\n }\n const [a, b] = prop.split('');\n const property = properties[a];\n const direction = directions[b] || '';\n return Array.isArray(direction) ? direction.map(dir => property + dir) : [property + direction];\n});\nexport const marginKeys = ['m', 'mt', 'mr', 'mb', 'ml', 'mx', 'my', 'margin', 'marginTop', 'marginRight', 'marginBottom', 'marginLeft', 'marginX', 'marginY', 'marginInline', 'marginInlineStart', 'marginInlineEnd', 'marginBlock', 'marginBlockStart', 'marginBlockEnd'];\nexport const paddingKeys = ['p', 'pt', 'pr', 'pb', 'pl', 'px', 'py', 'padding', 'paddingTop', 'paddingRight', 'paddingBottom', 'paddingLeft', 'paddingX', 'paddingY', 'paddingInline', 'paddingInlineStart', 'paddingInlineEnd', 'paddingBlock', 'paddingBlockStart', 'paddingBlockEnd'];\nconst spacingKeys = [...marginKeys, ...paddingKeys];\nexport function createUnaryUnit(theme, themeKey, defaultValue, propName) {\n var _getPath;\n const themeSpacing = (_getPath = getPath(theme, themeKey, false)) != null ? _getPath : defaultValue;\n if (typeof themeSpacing === 'number') {\n return abs => {\n if (typeof abs === 'string') {\n return abs;\n }\n if (process.env.NODE_ENV !== 'production') {\n if (typeof abs !== 'number') {\n console.error(`MUI: Expected ${propName} argument to be a number or a string, got ${abs}.`);\n }\n }\n return themeSpacing * abs;\n };\n }\n if (Array.isArray(themeSpacing)) {\n return abs => {\n if (typeof abs === 'string') {\n return abs;\n }\n if (process.env.NODE_ENV !== 'production') {\n if (!Number.isInteger(abs)) {\n console.error([`MUI: The \\`theme.${themeKey}\\` array type cannot be combined with non integer values.` + `You should either use an integer value that can be used as index, or define the \\`theme.${themeKey}\\` as a number.`].join('\\n'));\n } else if (abs > themeSpacing.length - 1) {\n console.error([`MUI: The value provided (${abs}) overflows.`, `The supported values are: ${JSON.stringify(themeSpacing)}.`, `${abs} > ${themeSpacing.length - 1}, you need to add the missing values.`].join('\\n'));\n }\n }\n return themeSpacing[abs];\n };\n }\n if (typeof themeSpacing === 'function') {\n return themeSpacing;\n }\n if (process.env.NODE_ENV !== 'production') {\n console.error([`MUI: The \\`theme.${themeKey}\\` value (${themeSpacing}) is invalid.`, 'It should be a number, an array or a function.'].join('\\n'));\n }\n return () => undefined;\n}\nexport function createUnarySpacing(theme) {\n return createUnaryUnit(theme, 'spacing', 8, 'spacing');\n}\nexport function getValue(transformer, propValue) {\n if (typeof propValue === 'string' || propValue == null) {\n return propValue;\n }\n const abs = Math.abs(propValue);\n const transformed = transformer(abs);\n if (propValue >= 0) {\n return transformed;\n }\n if (typeof transformed === 'number') {\n return -transformed;\n }\n return `-${transformed}`;\n}\nexport function getStyleFromPropValue(cssProperties, transformer) {\n return propValue => cssProperties.reduce((acc, cssProperty) => {\n acc[cssProperty] = getValue(transformer, propValue);\n return acc;\n }, {});\n}\nfunction resolveCssProperty(props, keys, prop, transformer) {\n // Using a hash computation over an array iteration could be faster, but with only 28 items,\n // it's doesn't worth the bundle size.\n if (keys.indexOf(prop) === -1) {\n return null;\n }\n const cssProperties = getCssProperties(prop);\n const styleFromPropValue = getStyleFromPropValue(cssProperties, transformer);\n const propValue = props[prop];\n return handleBreakpoints(props, propValue, styleFromPropValue);\n}\nfunction style(props, keys) {\n const transformer = createUnarySpacing(props.theme);\n return Object.keys(props).map(prop => resolveCssProperty(props, keys, prop, transformer)).reduce(merge, {});\n}\nexport function margin(props) {\n return style(props, marginKeys);\n}\nmargin.propTypes = process.env.NODE_ENV !== 'production' ? marginKeys.reduce((obj, key) => {\n obj[key] = responsivePropType;\n return obj;\n}, {}) : {};\nmargin.filterProps = marginKeys;\nexport function padding(props) {\n return style(props, paddingKeys);\n}\npadding.propTypes = process.env.NODE_ENV !== 'production' ? paddingKeys.reduce((obj, key) => {\n obj[key] = responsivePropType;\n return obj;\n}, {}) : {};\npadding.filterProps = paddingKeys;\nfunction spacing(props) {\n return style(props, spacingKeys);\n}\nspacing.propTypes = process.env.NODE_ENV !== 'production' ? spacingKeys.reduce((obj, key) => {\n obj[key] = responsivePropType;\n return obj;\n}, {}) : {};\nspacing.filterProps = spacingKeys;\nexport default spacing;","import { createUnarySpacing } from '../spacing';\n\n// The different signatures imply different meaning for their arguments that can't be expressed structurally.\n// We express the difference with variable names.\n\nexport default function createSpacing(spacingInput = 8) {\n // Already transformed.\n if (spacingInput.mui) {\n return spacingInput;\n }\n\n // Material Design layouts are visually balanced. Most measurements align to an 8dp grid, which aligns both spacing and the overall layout.\n // Smaller components, such as icons, can align to a 4dp grid.\n // https://m2.material.io/design/layout/understanding-layout.html\n const transform = createUnarySpacing({\n spacing: spacingInput\n });\n const spacing = (...argsInput) => {\n if (process.env.NODE_ENV !== 'production') {\n if (!(argsInput.length <= 4)) {\n console.error(`MUI: Too many arguments provided, expected between 0 and 4, got ${argsInput.length}`);\n }\n }\n const args = argsInput.length === 0 ? [1] : argsInput;\n return args.map(argument => {\n const output = transform(argument);\n return typeof output === 'number' ? `${output}px` : output;\n }).join(' ');\n };\n spacing.mui = true;\n return spacing;\n}","import merge from './merge';\nfunction compose(...styles) {\n const handlers = styles.reduce((acc, style) => {\n style.filterProps.forEach(prop => {\n acc[prop] = style;\n });\n return acc;\n }, {});\n\n // false positive\n // eslint-disable-next-line react/function-component-definition\n const fn = props => {\n return Object.keys(props).reduce((acc, prop) => {\n if (handlers[prop]) {\n return merge(acc, handlers[prop](props));\n }\n return acc;\n }, {});\n };\n fn.propTypes = process.env.NODE_ENV !== 'production' ? styles.reduce((acc, style) => Object.assign(acc, style.propTypes), {}) : {};\n fn.filterProps = styles.reduce((acc, style) => acc.concat(style.filterProps), []);\n return fn;\n}\nexport default compose;","import responsivePropType from './responsivePropType';\nimport style from './style';\nimport compose from './compose';\nimport { createUnaryUnit, getValue } from './spacing';\nimport { handleBreakpoints } from './breakpoints';\nexport function borderTransform(value) {\n if (typeof value !== 'number') {\n return value;\n }\n return `${value}px solid`;\n}\nfunction createBorderStyle(prop, transform) {\n return style({\n prop,\n themeKey: 'borders',\n transform\n });\n}\nexport const border = createBorderStyle('border', borderTransform);\nexport const borderTop = createBorderStyle('borderTop', borderTransform);\nexport const borderRight = createBorderStyle('borderRight', borderTransform);\nexport const borderBottom = createBorderStyle('borderBottom', borderTransform);\nexport const borderLeft = createBorderStyle('borderLeft', borderTransform);\nexport const borderColor = createBorderStyle('borderColor');\nexport const borderTopColor = createBorderStyle('borderTopColor');\nexport const borderRightColor = createBorderStyle('borderRightColor');\nexport const borderBottomColor = createBorderStyle('borderBottomColor');\nexport const borderLeftColor = createBorderStyle('borderLeftColor');\nexport const outline = createBorderStyle('outline', borderTransform);\nexport const outlineColor = createBorderStyle('outlineColor');\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const borderRadius = props => {\n if (props.borderRadius !== undefined && props.borderRadius !== null) {\n const transformer = createUnaryUnit(props.theme, 'shape.borderRadius', 4, 'borderRadius');\n const styleFromPropValue = propValue => ({\n borderRadius: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.borderRadius, styleFromPropValue);\n }\n return null;\n};\nborderRadius.propTypes = process.env.NODE_ENV !== 'production' ? {\n borderRadius: responsivePropType\n} : {};\nborderRadius.filterProps = ['borderRadius'];\nconst borders = compose(border, borderTop, borderRight, borderBottom, borderLeft, borderColor, borderTopColor, borderRightColor, borderBottomColor, borderLeftColor, borderRadius, outline, outlineColor);\nexport default borders;","import style from './style';\nimport compose from './compose';\nimport { createUnaryUnit, getValue } from './spacing';\nimport { handleBreakpoints } from './breakpoints';\nimport responsivePropType from './responsivePropType';\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const gap = props => {\n if (props.gap !== undefined && props.gap !== null) {\n const transformer = createUnaryUnit(props.theme, 'spacing', 8, 'gap');\n const styleFromPropValue = propValue => ({\n gap: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.gap, styleFromPropValue);\n }\n return null;\n};\ngap.propTypes = process.env.NODE_ENV !== 'production' ? {\n gap: responsivePropType\n} : {};\ngap.filterProps = ['gap'];\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const columnGap = props => {\n if (props.columnGap !== undefined && props.columnGap !== null) {\n const transformer = createUnaryUnit(props.theme, 'spacing', 8, 'columnGap');\n const styleFromPropValue = propValue => ({\n columnGap: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.columnGap, styleFromPropValue);\n }\n return null;\n};\ncolumnGap.propTypes = process.env.NODE_ENV !== 'production' ? {\n columnGap: responsivePropType\n} : {};\ncolumnGap.filterProps = ['columnGap'];\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const rowGap = props => {\n if (props.rowGap !== undefined && props.rowGap !== null) {\n const transformer = createUnaryUnit(props.theme, 'spacing', 8, 'rowGap');\n const styleFromPropValue = propValue => ({\n rowGap: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.rowGap, styleFromPropValue);\n }\n return null;\n};\nrowGap.propTypes = process.env.NODE_ENV !== 'production' ? {\n rowGap: responsivePropType\n} : {};\nrowGap.filterProps = ['rowGap'];\nexport const gridColumn = style({\n prop: 'gridColumn'\n});\nexport const gridRow = style({\n prop: 'gridRow'\n});\nexport const gridAutoFlow = style({\n prop: 'gridAutoFlow'\n});\nexport const gridAutoColumns = style({\n prop: 'gridAutoColumns'\n});\nexport const gridAutoRows = style({\n prop: 'gridAutoRows'\n});\nexport const gridTemplateColumns = style({\n prop: 'gridTemplateColumns'\n});\nexport const gridTemplateRows = style({\n prop: 'gridTemplateRows'\n});\nexport const gridTemplateAreas = style({\n prop: 'gridTemplateAreas'\n});\nexport const gridArea = style({\n prop: 'gridArea'\n});\nconst grid = compose(gap, columnGap, rowGap, gridColumn, gridRow, gridAutoFlow, gridAutoColumns, gridAutoRows, gridTemplateColumns, gridTemplateRows, gridTemplateAreas, gridArea);\nexport default grid;","import style from './style';\nimport compose from './compose';\nexport function paletteTransform(value, userValue) {\n if (userValue === 'grey') {\n return userValue;\n }\n return value;\n}\nexport const color = style({\n prop: 'color',\n themeKey: 'palette',\n transform: paletteTransform\n});\nexport const bgcolor = style({\n prop: 'bgcolor',\n cssProperty: 'backgroundColor',\n themeKey: 'palette',\n transform: paletteTransform\n});\nexport const backgroundColor = style({\n prop: 'backgroundColor',\n themeKey: 'palette',\n transform: paletteTransform\n});\nconst palette = compose(color, bgcolor, backgroundColor);\nexport default palette;","import style from './style';\nimport compose from './compose';\nimport { handleBreakpoints, values as breakpointsValues } from './breakpoints';\nexport function sizingTransform(value) {\n return value <= 1 && value !== 0 ? `${value * 100}%` : value;\n}\nexport const width = style({\n prop: 'width',\n transform: sizingTransform\n});\nexport const maxWidth = props => {\n if (props.maxWidth !== undefined && props.maxWidth !== null) {\n const styleFromPropValue = propValue => {\n var _props$theme, _props$theme2;\n const breakpoint = ((_props$theme = props.theme) == null || (_props$theme = _props$theme.breakpoints) == null || (_props$theme = _props$theme.values) == null ? void 0 : _props$theme[propValue]) || breakpointsValues[propValue];\n if (!breakpoint) {\n return {\n maxWidth: sizingTransform(propValue)\n };\n }\n if (((_props$theme2 = props.theme) == null || (_props$theme2 = _props$theme2.breakpoints) == null ? void 0 : _props$theme2.unit) !== 'px') {\n return {\n maxWidth: `${breakpoint}${props.theme.breakpoints.unit}`\n };\n }\n return {\n maxWidth: breakpoint\n };\n };\n return handleBreakpoints(props, props.maxWidth, styleFromPropValue);\n }\n return null;\n};\nmaxWidth.filterProps = ['maxWidth'];\nexport const minWidth = style({\n prop: 'minWidth',\n transform: sizingTransform\n});\nexport const height = style({\n prop: 'height',\n transform: sizingTransform\n});\nexport const maxHeight = style({\n prop: 'maxHeight',\n transform: sizingTransform\n});\nexport const minHeight = style({\n prop: 'minHeight',\n transform: sizingTransform\n});\nexport const sizeWidth = style({\n prop: 'size',\n cssProperty: 'width',\n transform: sizingTransform\n});\nexport const sizeHeight = style({\n prop: 'size',\n cssProperty: 'height',\n transform: sizingTransform\n});\nexport const boxSizing = style({\n prop: 'boxSizing'\n});\nconst sizing = compose(width, maxWidth, minWidth, height, maxHeight, minHeight, boxSizing);\nexport default sizing;","import { padding, margin } from '../spacing';\nimport { borderRadius, borderTransform } from '../borders';\nimport { gap, rowGap, columnGap } from '../cssGrid';\nimport { paletteTransform } from '../palette';\nimport { maxWidth, sizingTransform } from '../sizing';\nconst defaultSxConfig = {\n // borders\n border: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderTop: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderRight: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderBottom: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderLeft: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderColor: {\n themeKey: 'palette'\n },\n borderTopColor: {\n themeKey: 'palette'\n },\n borderRightColor: {\n themeKey: 'palette'\n },\n borderBottomColor: {\n themeKey: 'palette'\n },\n borderLeftColor: {\n themeKey: 'palette'\n },\n outline: {\n themeKey: 'borders',\n transform: borderTransform\n },\n outlineColor: {\n themeKey: 'palette'\n },\n borderRadius: {\n themeKey: 'shape.borderRadius',\n style: borderRadius\n },\n // palette\n color: {\n themeKey: 'palette',\n transform: paletteTransform\n },\n bgcolor: {\n themeKey: 'palette',\n cssProperty: 'backgroundColor',\n transform: paletteTransform\n },\n backgroundColor: {\n themeKey: 'palette',\n transform: paletteTransform\n },\n // spacing\n p: {\n style: padding\n },\n pt: {\n style: padding\n },\n pr: {\n style: padding\n },\n pb: {\n style: padding\n },\n pl: {\n style: padding\n },\n px: {\n style: padding\n },\n py: {\n style: padding\n },\n padding: {\n style: padding\n },\n paddingTop: {\n style: padding\n },\n paddingRight: {\n style: padding\n },\n paddingBottom: {\n style: padding\n },\n paddingLeft: {\n style: padding\n },\n paddingX: {\n style: padding\n },\n paddingY: {\n style: padding\n },\n paddingInline: {\n style: padding\n },\n paddingInlineStart: {\n style: padding\n },\n paddingInlineEnd: {\n style: padding\n },\n paddingBlock: {\n style: padding\n },\n paddingBlockStart: {\n style: padding\n },\n paddingBlockEnd: {\n style: padding\n },\n m: {\n style: margin\n },\n mt: {\n style: margin\n },\n mr: {\n style: margin\n },\n mb: {\n style: margin\n },\n ml: {\n style: margin\n },\n mx: {\n style: margin\n },\n my: {\n style: margin\n },\n margin: {\n style: margin\n },\n marginTop: {\n style: margin\n },\n marginRight: {\n style: margin\n },\n marginBottom: {\n style: margin\n },\n marginLeft: {\n style: margin\n },\n marginX: {\n style: margin\n },\n marginY: {\n style: margin\n },\n marginInline: {\n style: margin\n },\n marginInlineStart: {\n style: margin\n },\n marginInlineEnd: {\n style: margin\n },\n marginBlock: {\n style: margin\n },\n marginBlockStart: {\n style: margin\n },\n marginBlockEnd: {\n style: margin\n },\n // display\n displayPrint: {\n cssProperty: false,\n transform: value => ({\n '@media print': {\n display: value\n }\n })\n },\n display: {},\n overflow: {},\n textOverflow: {},\n visibility: {},\n whiteSpace: {},\n // flexbox\n flexBasis: {},\n flexDirection: {},\n flexWrap: {},\n justifyContent: {},\n alignItems: {},\n alignContent: {},\n order: {},\n flex: {},\n flexGrow: {},\n flexShrink: {},\n alignSelf: {},\n justifyItems: {},\n justifySelf: {},\n // grid\n gap: {\n style: gap\n },\n rowGap: {\n style: rowGap\n },\n columnGap: {\n style: columnGap\n },\n gridColumn: {},\n gridRow: {},\n gridAutoFlow: {},\n gridAutoColumns: {},\n gridAutoRows: {},\n gridTemplateColumns: {},\n gridTemplateRows: {},\n gridTemplateAreas: {},\n gridArea: {},\n // positions\n position: {},\n zIndex: {\n themeKey: 'zIndex'\n },\n top: {},\n right: {},\n bottom: {},\n left: {},\n // shadows\n boxShadow: {\n themeKey: 'shadows'\n },\n // sizing\n width: {\n transform: sizingTransform\n },\n maxWidth: {\n style: maxWidth\n },\n minWidth: {\n transform: sizingTransform\n },\n height: {\n transform: sizingTransform\n },\n maxHeight: {\n transform: sizingTransform\n },\n minHeight: {\n transform: sizingTransform\n },\n boxSizing: {},\n // typography\n fontFamily: {\n themeKey: 'typography'\n },\n fontSize: {\n themeKey: 'typography'\n },\n fontStyle: {\n themeKey: 'typography'\n },\n fontWeight: {\n themeKey: 'typography'\n },\n letterSpacing: {},\n textTransform: {},\n lineHeight: {},\n textAlign: {},\n typography: {\n cssProperty: false,\n themeKey: 'typography'\n }\n};\nexport default defaultSxConfig;","import capitalize from '@mui/utils/capitalize';\nimport merge from '../merge';\nimport { getPath, getStyleValue as getValue } from '../style';\nimport { handleBreakpoints, createEmptyBreakpointObject, removeUnusedBreakpoints } from '../breakpoints';\nimport defaultSxConfig from './defaultSxConfig';\nfunction objectsHaveSameKeys(...objects) {\n const allKeys = objects.reduce((keys, object) => keys.concat(Object.keys(object)), []);\n const union = new Set(allKeys);\n return objects.every(object => union.size === Object.keys(object).length);\n}\nfunction callIfFn(maybeFn, arg) {\n return typeof maybeFn === 'function' ? maybeFn(arg) : maybeFn;\n}\n\n// eslint-disable-next-line @typescript-eslint/naming-convention\nexport function unstable_createStyleFunctionSx() {\n function getThemeValue(prop, val, theme, config) {\n const props = {\n [prop]: val,\n theme\n };\n const options = config[prop];\n if (!options) {\n return {\n [prop]: val\n };\n }\n const {\n cssProperty = prop,\n themeKey,\n transform,\n style\n } = options;\n if (val == null) {\n return null;\n }\n\n // TODO v6: remove, see https://github.com/mui/material-ui/pull/38123\n if (themeKey === 'typography' && val === 'inherit') {\n return {\n [prop]: val\n };\n }\n const themeMapping = getPath(theme, themeKey) || {};\n if (style) {\n return style(props);\n }\n const styleFromPropValue = propValueFinal => {\n let value = getValue(themeMapping, transform, propValueFinal);\n if (propValueFinal === value && typeof propValueFinal === 'string') {\n // Haven't found value\n value = getValue(themeMapping, transform, `${prop}${propValueFinal === 'default' ? '' : capitalize(propValueFinal)}`, propValueFinal);\n }\n if (cssProperty === false) {\n return value;\n }\n return {\n [cssProperty]: value\n };\n };\n return handleBreakpoints(props, val, styleFromPropValue);\n }\n function styleFunctionSx(props) {\n var _theme$unstable_sxCon;\n const {\n sx,\n theme = {}\n } = props || {};\n if (!sx) {\n return null; // Emotion & styled-components will neglect null\n }\n const config = (_theme$unstable_sxCon = theme.unstable_sxConfig) != null ? _theme$unstable_sxCon : defaultSxConfig;\n\n /*\n * Receive `sxInput` as object or callback\n * and then recursively check keys & values to create media query object styles.\n * (the result will be used in `styled`)\n */\n function traverse(sxInput) {\n let sxObject = sxInput;\n if (typeof sxInput === 'function') {\n sxObject = sxInput(theme);\n } else if (typeof sxInput !== 'object') {\n // value\n return sxInput;\n }\n if (!sxObject) {\n return null;\n }\n const emptyBreakpoints = createEmptyBreakpointObject(theme.breakpoints);\n const breakpointsKeys = Object.keys(emptyBreakpoints);\n let css = emptyBreakpoints;\n Object.keys(sxObject).forEach(styleKey => {\n const value = callIfFn(sxObject[styleKey], theme);\n if (value !== null && value !== undefined) {\n if (typeof value === 'object') {\n if (config[styleKey]) {\n css = merge(css, getThemeValue(styleKey, value, theme, config));\n } else {\n const breakpointsValues = handleBreakpoints({\n theme\n }, value, x => ({\n [styleKey]: x\n }));\n if (objectsHaveSameKeys(breakpointsValues, value)) {\n css[styleKey] = styleFunctionSx({\n sx: value,\n theme\n });\n } else {\n css = merge(css, breakpointsValues);\n }\n }\n } else {\n css = merge(css, getThemeValue(styleKey, value, theme, config));\n }\n }\n });\n return removeUnusedBreakpoints(breakpointsKeys, css);\n }\n return Array.isArray(sx) ? sx.map(traverse) : traverse(sx);\n }\n return styleFunctionSx;\n}\nconst styleFunctionSx = unstable_createStyleFunctionSx();\nstyleFunctionSx.filterProps = ['sx'];\nexport default styleFunctionSx;","/**\n * A universal utility to style components with multiple color modes. Always use it from the theme object.\n * It works with:\n * - [Basic theme](https://mui.com/material-ui/customization/dark-mode/)\n * - [CSS theme variables](https://mui.com/material-ui/experimental-api/css-theme-variables/overview/)\n * - Zero-runtime engine\n *\n * Tips: Use an array over object spread and place `theme.applyStyles()` last.\n *\n * ✅ [{ background: '#e5e5e5' }, theme.applyStyles('dark', { background: '#1c1c1c' })]\n *\n * 🚫 { background: '#e5e5e5', ...theme.applyStyles('dark', { background: '#1c1c1c' })}\n *\n * @example\n * 1. using with `styled`:\n * ```jsx\n * const Component = styled('div')(({ theme }) => [\n * { background: '#e5e5e5' },\n * theme.applyStyles('dark', {\n * background: '#1c1c1c',\n * color: '#fff',\n * }),\n * ]);\n * ```\n *\n * @example\n * 2. using with `sx` prop:\n * ```jsx\n * [\n * { background: '#e5e5e5' },\n * theme.applyStyles('dark', {\n * background: '#1c1c1c',\n * color: '#fff',\n * }),\n * ]}\n * />\n * ```\n *\n * @example\n * 3. theming a component:\n * ```jsx\n * extendTheme({\n * components: {\n * MuiButton: {\n * styleOverrides: {\n * root: ({ theme }) => [\n * { background: '#e5e5e5' },\n * theme.applyStyles('dark', {\n * background: '#1c1c1c',\n * color: '#fff',\n * }),\n * ],\n * },\n * }\n * }\n * })\n *```\n */\nexport default function applyStyles(key, styles) {\n // @ts-expect-error this is 'any' type\n const theme = this;\n if (theme.vars && typeof theme.getColorSchemeSelector === 'function') {\n // If CssVarsProvider is used as a provider,\n // returns '* :where([data-mui-color-scheme=\"light|dark\"]) &'\n const selector = theme.getColorSchemeSelector(key).replace(/(\\[[^\\]]+\\])/, '*:where($1)');\n return {\n [selector]: styles\n };\n }\n if (theme.palette.mode === key) {\n return styles;\n }\n return {};\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"breakpoints\", \"palette\", \"spacing\", \"shape\"];\nimport deepmerge from '@mui/utils/deepmerge';\nimport createBreakpoints from './createBreakpoints';\nimport shape from './shape';\nimport createSpacing from './createSpacing';\nimport styleFunctionSx from '../styleFunctionSx/styleFunctionSx';\nimport defaultSxConfig from '../styleFunctionSx/defaultSxConfig';\nimport applyStyles from './applyStyles';\nfunction createTheme(options = {}, ...args) {\n const {\n breakpoints: breakpointsInput = {},\n palette: paletteInput = {},\n spacing: spacingInput,\n shape: shapeInput = {}\n } = options,\n other = _objectWithoutPropertiesLoose(options, _excluded);\n const breakpoints = createBreakpoints(breakpointsInput);\n const spacing = createSpacing(spacingInput);\n let muiTheme = deepmerge({\n breakpoints,\n direction: 'ltr',\n components: {},\n // Inject component definitions.\n palette: _extends({\n mode: 'light'\n }, paletteInput),\n spacing,\n shape: _extends({}, shape, shapeInput)\n }, other);\n muiTheme.applyStyles = applyStyles;\n muiTheme = args.reduce((acc, argument) => deepmerge(acc, argument), muiTheme);\n muiTheme.unstable_sxConfig = _extends({}, defaultSxConfig, other == null ? void 0 : other.unstable_sxConfig);\n muiTheme.unstable_sx = function sx(props) {\n return styleFunctionSx({\n sx: props,\n theme: this\n });\n };\n return muiTheme;\n}\nexport default createTheme;","'use client';\n\nimport * as React from 'react';\nimport { ThemeContext } from '@mui/styled-engine';\nfunction isObjectEmpty(obj) {\n return Object.keys(obj).length === 0;\n}\nfunction useTheme(defaultTheme = null) {\n const contextTheme = React.useContext(ThemeContext);\n return !contextTheme || isObjectEmpty(contextTheme) ? defaultTheme : contextTheme;\n}\nexport default useTheme;","'use client';\n\nimport createTheme from './createTheme';\nimport useThemeWithoutDefault from './useThemeWithoutDefault';\nexport const systemDefaultTheme = createTheme();\nfunction useTheme(defaultTheme = systemDefaultTheme) {\n return useThemeWithoutDefault(defaultTheme);\n}\nexport default useTheme;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"ownerState\"],\n _excluded2 = [\"variants\"],\n _excluded3 = [\"name\", \"slot\", \"skipVariantsResolver\", \"skipSx\", \"overridesResolver\"];\n/* eslint-disable no-underscore-dangle */\nimport styledEngineStyled, { internal_processStyles as processStyles } from '@mui/styled-engine';\nimport { isPlainObject } from '@mui/utils/deepmerge';\nimport capitalize from '@mui/utils/capitalize';\nimport getDisplayName from '@mui/utils/getDisplayName';\nimport createTheme from './createTheme';\nimport styleFunctionSx from './styleFunctionSx';\nfunction isEmpty(obj) {\n return Object.keys(obj).length === 0;\n}\n\n// https://github.com/emotion-js/emotion/blob/26ded6109fcd8ca9875cc2ce4564fee678a3f3c5/packages/styled/src/utils.js#L40\nfunction isStringTag(tag) {\n return typeof tag === 'string' &&\n // 96 is one less than the char code\n // for \"a\" so this is checking that\n // it's a lowercase character\n tag.charCodeAt(0) > 96;\n}\n\n// Update /system/styled/#api in case if this changes\nexport function shouldForwardProp(prop) {\n return prop !== 'ownerState' && prop !== 'theme' && prop !== 'sx' && prop !== 'as';\n}\nexport const systemDefaultTheme = createTheme();\nconst lowercaseFirstLetter = string => {\n if (!string) {\n return string;\n }\n return string.charAt(0).toLowerCase() + string.slice(1);\n};\nfunction resolveTheme({\n defaultTheme,\n theme,\n themeId\n}) {\n return isEmpty(theme) ? defaultTheme : theme[themeId] || theme;\n}\nfunction defaultOverridesResolver(slot) {\n if (!slot) {\n return null;\n }\n return (props, styles) => styles[slot];\n}\nfunction processStyleArg(callableStyle, _ref) {\n let {\n ownerState\n } = _ref,\n props = _objectWithoutPropertiesLoose(_ref, _excluded);\n const resolvedStylesArg = typeof callableStyle === 'function' ? callableStyle(_extends({\n ownerState\n }, props)) : callableStyle;\n if (Array.isArray(resolvedStylesArg)) {\n return resolvedStylesArg.flatMap(resolvedStyle => processStyleArg(resolvedStyle, _extends({\n ownerState\n }, props)));\n }\n if (!!resolvedStylesArg && typeof resolvedStylesArg === 'object' && Array.isArray(resolvedStylesArg.variants)) {\n const {\n variants = []\n } = resolvedStylesArg,\n otherStyles = _objectWithoutPropertiesLoose(resolvedStylesArg, _excluded2);\n let result = otherStyles;\n variants.forEach(variant => {\n let isMatch = true;\n if (typeof variant.props === 'function') {\n isMatch = variant.props(_extends({\n ownerState\n }, props, ownerState));\n } else {\n Object.keys(variant.props).forEach(key => {\n if ((ownerState == null ? void 0 : ownerState[key]) !== variant.props[key] && props[key] !== variant.props[key]) {\n isMatch = false;\n }\n });\n }\n if (isMatch) {\n if (!Array.isArray(result)) {\n result = [result];\n }\n result.push(typeof variant.style === 'function' ? variant.style(_extends({\n ownerState\n }, props, ownerState)) : variant.style);\n }\n });\n return result;\n }\n return resolvedStylesArg;\n}\nexport default function createStyled(input = {}) {\n const {\n themeId,\n defaultTheme = systemDefaultTheme,\n rootShouldForwardProp = shouldForwardProp,\n slotShouldForwardProp = shouldForwardProp\n } = input;\n const systemSx = props => {\n return styleFunctionSx(_extends({}, props, {\n theme: resolveTheme(_extends({}, props, {\n defaultTheme,\n themeId\n }))\n }));\n };\n systemSx.__mui_systemSx = true;\n return (tag, inputOptions = {}) => {\n // Filter out the `sx` style function from the previous styled component to prevent unnecessary styles generated by the composite components.\n processStyles(tag, styles => styles.filter(style => !(style != null && style.__mui_systemSx)));\n const {\n name: componentName,\n slot: componentSlot,\n skipVariantsResolver: inputSkipVariantsResolver,\n skipSx: inputSkipSx,\n // TODO v6: remove `lowercaseFirstLetter()` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n overridesResolver = defaultOverridesResolver(lowercaseFirstLetter(componentSlot))\n } = inputOptions,\n options = _objectWithoutPropertiesLoose(inputOptions, _excluded3);\n\n // if skipVariantsResolver option is defined, take the value, otherwise, true for root and false for other slots.\n const skipVariantsResolver = inputSkipVariantsResolver !== undefined ? inputSkipVariantsResolver :\n // TODO v6: remove `Root` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n componentSlot && componentSlot !== 'Root' && componentSlot !== 'root' || false;\n const skipSx = inputSkipSx || false;\n let label;\n if (process.env.NODE_ENV !== 'production') {\n if (componentName) {\n // TODO v6: remove `lowercaseFirstLetter()` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n label = `${componentName}-${lowercaseFirstLetter(componentSlot || 'Root')}`;\n }\n }\n let shouldForwardPropOption = shouldForwardProp;\n\n // TODO v6: remove `Root` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n if (componentSlot === 'Root' || componentSlot === 'root') {\n shouldForwardPropOption = rootShouldForwardProp;\n } else if (componentSlot) {\n // any other slot specified\n shouldForwardPropOption = slotShouldForwardProp;\n } else if (isStringTag(tag)) {\n // for string (html) tag, preserve the behavior in emotion & styled-components.\n shouldForwardPropOption = undefined;\n }\n const defaultStyledResolver = styledEngineStyled(tag, _extends({\n shouldForwardProp: shouldForwardPropOption,\n label\n }, options));\n const transformStyleArg = stylesArg => {\n // On the server Emotion doesn't use React.forwardRef for creating components, so the created\n // component stays as a function. This condition makes sure that we do not interpolate functions\n // which are basically components used as a selectors.\n if (typeof stylesArg === 'function' && stylesArg.__emotion_real !== stylesArg || isPlainObject(stylesArg)) {\n return props => processStyleArg(stylesArg, _extends({}, props, {\n theme: resolveTheme({\n theme: props.theme,\n defaultTheme,\n themeId\n })\n }));\n }\n return stylesArg;\n };\n const muiStyledResolver = (styleArg, ...expressions) => {\n let transformedStyleArg = transformStyleArg(styleArg);\n const expressionsWithDefaultTheme = expressions ? expressions.map(transformStyleArg) : [];\n if (componentName && overridesResolver) {\n expressionsWithDefaultTheme.push(props => {\n const theme = resolveTheme(_extends({}, props, {\n defaultTheme,\n themeId\n }));\n if (!theme.components || !theme.components[componentName] || !theme.components[componentName].styleOverrides) {\n return null;\n }\n const styleOverrides = theme.components[componentName].styleOverrides;\n const resolvedStyleOverrides = {};\n // TODO: v7 remove iteration and use `resolveStyleArg(styleOverrides[slot])` directly\n Object.entries(styleOverrides).forEach(([slotKey, slotStyle]) => {\n resolvedStyleOverrides[slotKey] = processStyleArg(slotStyle, _extends({}, props, {\n theme\n }));\n });\n return overridesResolver(props, resolvedStyleOverrides);\n });\n }\n if (componentName && !skipVariantsResolver) {\n expressionsWithDefaultTheme.push(props => {\n var _theme$components;\n const theme = resolveTheme(_extends({}, props, {\n defaultTheme,\n themeId\n }));\n const themeVariants = theme == null || (_theme$components = theme.components) == null || (_theme$components = _theme$components[componentName]) == null ? void 0 : _theme$components.variants;\n return processStyleArg({\n variants: themeVariants\n }, _extends({}, props, {\n theme\n }));\n });\n }\n if (!skipSx) {\n expressionsWithDefaultTheme.push(systemSx);\n }\n const numOfCustomFnsApplied = expressionsWithDefaultTheme.length - expressions.length;\n if (Array.isArray(styleArg) && numOfCustomFnsApplied > 0) {\n const placeholders = new Array(numOfCustomFnsApplied).fill('');\n // If the type is array, than we need to add placeholders in the template for the overrides, variants and the sx styles.\n transformedStyleArg = [...styleArg, ...placeholders];\n transformedStyleArg.raw = [...styleArg.raw, ...placeholders];\n }\n const Component = defaultStyledResolver(transformedStyleArg, ...expressionsWithDefaultTheme);\n if (process.env.NODE_ENV !== 'production') {\n let displayName;\n if (componentName) {\n displayName = `${componentName}${capitalize(componentSlot || '')}`;\n }\n if (displayName === undefined) {\n displayName = `Styled(${getDisplayName(tag)})`;\n }\n Component.displayName = displayName;\n }\n if (tag.muiName) {\n Component.muiName = tag.muiName;\n }\n return Component;\n };\n if (defaultStyledResolver.withConfig) {\n muiStyledResolver.withConfig = defaultStyledResolver.withConfig;\n }\n return muiStyledResolver;\n };\n}","import resolveProps from '@mui/utils/resolveProps';\nexport default function getThemeProps(params) {\n const {\n theme,\n name,\n props\n } = params;\n if (!theme || !theme.components || !theme.components[name] || !theme.components[name].defaultProps) {\n return props;\n }\n return resolveProps(theme.components[name].defaultProps, props);\n}","'use client';\n\nimport getThemeProps from './getThemeProps';\nimport useTheme from '../useTheme';\nexport default function useThemeProps({\n props,\n name,\n defaultTheme,\n themeId\n}) {\n let theme = useTheme(defaultTheme);\n if (themeId) {\n theme = theme[themeId] || theme;\n }\n const mergedProps = getThemeProps({\n theme,\n name,\n props\n });\n return mergedProps;\n}","import _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\n/* eslint-disable @typescript-eslint/naming-convention */\nimport clamp from '@mui/utils/clamp';\n/**\n * Returns a number whose value is limited to the given range.\n * @param {number} value The value to be clamped\n * @param {number} min The lower boundary of the output range\n * @param {number} max The upper boundary of the output range\n * @returns {number} A number in the range [min, max]\n */\nfunction clampWrapper(value, min = 0, max = 1) {\n if (process.env.NODE_ENV !== 'production') {\n if (value < min || value > max) {\n console.error(`MUI: The value provided ${value} is out of range [${min}, ${max}].`);\n }\n }\n return clamp(value, min, max);\n}\n\n/**\n * Converts a color from CSS hex format to CSS rgb format.\n * @param {string} color - Hex color, i.e. #nnn or #nnnnnn\n * @returns {string} A CSS rgb color string\n */\nexport function hexToRgb(color) {\n color = color.slice(1);\n const re = new RegExp(`.{1,${color.length >= 6 ? 2 : 1}}`, 'g');\n let colors = color.match(re);\n if (colors && colors[0].length === 1) {\n colors = colors.map(n => n + n);\n }\n return colors ? `rgb${colors.length === 4 ? 'a' : ''}(${colors.map((n, index) => {\n return index < 3 ? parseInt(n, 16) : Math.round(parseInt(n, 16) / 255 * 1000) / 1000;\n }).join(', ')})` : '';\n}\nfunction intToHex(int) {\n const hex = int.toString(16);\n return hex.length === 1 ? `0${hex}` : hex;\n}\n\n/**\n * Returns an object with the type and values of a color.\n *\n * Note: Does not support rgb % values.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @returns {object} - A MUI color object: {type: string, values: number[]}\n */\nexport function decomposeColor(color) {\n // Idempotent\n if (color.type) {\n return color;\n }\n if (color.charAt(0) === '#') {\n return decomposeColor(hexToRgb(color));\n }\n const marker = color.indexOf('(');\n const type = color.substring(0, marker);\n if (['rgb', 'rgba', 'hsl', 'hsla', 'color'].indexOf(type) === -1) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: Unsupported \\`${color}\\` color.\nThe following formats are supported: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color().` : _formatMuiErrorMessage(9, color));\n }\n let values = color.substring(marker + 1, color.length - 1);\n let colorSpace;\n if (type === 'color') {\n values = values.split(' ');\n colorSpace = values.shift();\n if (values.length === 4 && values[3].charAt(0) === '/') {\n values[3] = values[3].slice(1);\n }\n if (['srgb', 'display-p3', 'a98-rgb', 'prophoto-rgb', 'rec-2020'].indexOf(colorSpace) === -1) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: unsupported \\`${colorSpace}\\` color space.\nThe following color spaces are supported: srgb, display-p3, a98-rgb, prophoto-rgb, rec-2020.` : _formatMuiErrorMessage(10, colorSpace));\n }\n } else {\n values = values.split(',');\n }\n values = values.map(value => parseFloat(value));\n return {\n type,\n values,\n colorSpace\n };\n}\n\n/**\n * Returns a channel created from the input color.\n *\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @returns {string} - The channel for the color, that can be used in rgba or hsla colors\n */\nexport const colorChannel = color => {\n const decomposedColor = decomposeColor(color);\n return decomposedColor.values.slice(0, 3).map((val, idx) => decomposedColor.type.indexOf('hsl') !== -1 && idx !== 0 ? `${val}%` : val).join(' ');\n};\nexport const private_safeColorChannel = (color, warning) => {\n try {\n return colorChannel(color);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n};\n\n/**\n * Converts a color object with type and values to a string.\n * @param {object} color - Decomposed color\n * @param {string} color.type - One of: 'rgb', 'rgba', 'hsl', 'hsla', 'color'\n * @param {array} color.values - [n,n,n] or [n,n,n,n]\n * @returns {string} A CSS color string\n */\nexport function recomposeColor(color) {\n const {\n type,\n colorSpace\n } = color;\n let {\n values\n } = color;\n if (type.indexOf('rgb') !== -1) {\n // Only convert the first 3 values to int (i.e. not alpha)\n values = values.map((n, i) => i < 3 ? parseInt(n, 10) : n);\n } else if (type.indexOf('hsl') !== -1) {\n values[1] = `${values[1]}%`;\n values[2] = `${values[2]}%`;\n }\n if (type.indexOf('color') !== -1) {\n values = `${colorSpace} ${values.join(' ')}`;\n } else {\n values = `${values.join(', ')}`;\n }\n return `${type}(${values})`;\n}\n\n/**\n * Converts a color from CSS rgb format to CSS hex format.\n * @param {string} color - RGB color, i.e. rgb(n, n, n)\n * @returns {string} A CSS rgb color string, i.e. #nnnnnn\n */\nexport function rgbToHex(color) {\n // Idempotent\n if (color.indexOf('#') === 0) {\n return color;\n }\n const {\n values\n } = decomposeColor(color);\n return `#${values.map((n, i) => intToHex(i === 3 ? Math.round(255 * n) : n)).join('')}`;\n}\n\n/**\n * Converts a color from hsl format to rgb format.\n * @param {string} color - HSL color values\n * @returns {string} rgb color values\n */\nexport function hslToRgb(color) {\n color = decomposeColor(color);\n const {\n values\n } = color;\n const h = values[0];\n const s = values[1] / 100;\n const l = values[2] / 100;\n const a = s * Math.min(l, 1 - l);\n const f = (n, k = (n + h / 30) % 12) => l - a * Math.max(Math.min(k - 3, 9 - k, 1), -1);\n let type = 'rgb';\n const rgb = [Math.round(f(0) * 255), Math.round(f(8) * 255), Math.round(f(4) * 255)];\n if (color.type === 'hsla') {\n type += 'a';\n rgb.push(values[3]);\n }\n return recomposeColor({\n type,\n values: rgb\n });\n}\n/**\n * The relative brightness of any point in a color space,\n * normalized to 0 for darkest black and 1 for lightest white.\n *\n * Formula: https://www.w3.org/TR/WCAG20-TECHS/G17.html#G17-tests\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @returns {number} The relative brightness of the color in the range 0 - 1\n */\nexport function getLuminance(color) {\n color = decomposeColor(color);\n let rgb = color.type === 'hsl' || color.type === 'hsla' ? decomposeColor(hslToRgb(color)).values : color.values;\n rgb = rgb.map(val => {\n if (color.type !== 'color') {\n val /= 255; // normalized\n }\n return val <= 0.03928 ? val / 12.92 : ((val + 0.055) / 1.055) ** 2.4;\n });\n\n // Truncate at 3 digits\n return Number((0.2126 * rgb[0] + 0.7152 * rgb[1] + 0.0722 * rgb[2]).toFixed(3));\n}\n\n/**\n * Calculates the contrast ratio between two colors.\n *\n * Formula: https://www.w3.org/TR/WCAG20-TECHS/G17.html#G17-tests\n * @param {string} foreground - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla()\n * @param {string} background - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla()\n * @returns {number} A contrast ratio value in the range 0 - 21.\n */\nexport function getContrastRatio(foreground, background) {\n const lumA = getLuminance(foreground);\n const lumB = getLuminance(background);\n return (Math.max(lumA, lumB) + 0.05) / (Math.min(lumA, lumB) + 0.05);\n}\n\n/**\n * Sets the absolute transparency of a color.\n * Any existing alpha values are overwritten.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} value - value to set the alpha channel to in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function alpha(color, value) {\n color = decomposeColor(color);\n value = clampWrapper(value);\n if (color.type === 'rgb' || color.type === 'hsl') {\n color.type += 'a';\n }\n if (color.type === 'color') {\n color.values[3] = `/${value}`;\n } else {\n color.values[3] = value;\n }\n return recomposeColor(color);\n}\nexport function private_safeAlpha(color, value, warning) {\n try {\n return alpha(color, value);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Darkens a color.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} coefficient - multiplier in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function darken(color, coefficient) {\n color = decomposeColor(color);\n coefficient = clampWrapper(coefficient);\n if (color.type.indexOf('hsl') !== -1) {\n color.values[2] *= 1 - coefficient;\n } else if (color.type.indexOf('rgb') !== -1 || color.type.indexOf('color') !== -1) {\n for (let i = 0; i < 3; i += 1) {\n color.values[i] *= 1 - coefficient;\n }\n }\n return recomposeColor(color);\n}\nexport function private_safeDarken(color, coefficient, warning) {\n try {\n return darken(color, coefficient);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Lightens a color.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} coefficient - multiplier in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function lighten(color, coefficient) {\n color = decomposeColor(color);\n coefficient = clampWrapper(coefficient);\n if (color.type.indexOf('hsl') !== -1) {\n color.values[2] += (100 - color.values[2]) * coefficient;\n } else if (color.type.indexOf('rgb') !== -1) {\n for (let i = 0; i < 3; i += 1) {\n color.values[i] += (255 - color.values[i]) * coefficient;\n }\n } else if (color.type.indexOf('color') !== -1) {\n for (let i = 0; i < 3; i += 1) {\n color.values[i] += (1 - color.values[i]) * coefficient;\n }\n }\n return recomposeColor(color);\n}\nexport function private_safeLighten(color, coefficient, warning) {\n try {\n return lighten(color, coefficient);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Darken or lighten a color, depending on its luminance.\n * Light colors are darkened, dark colors are lightened.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} coefficient=0.15 - multiplier in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function emphasize(color, coefficient = 0.15) {\n return getLuminance(color) > 0.5 ? darken(color, coefficient) : lighten(color, coefficient);\n}\nexport function private_safeEmphasize(color, coefficient, warning) {\n try {\n return emphasize(color, coefficient);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Blend a transparent overlay color with a background color, resulting in a single\n * RGB color.\n * @param {string} background - CSS color\n * @param {string} overlay - CSS color\n * @param {number} opacity - Opacity multiplier in the range 0 - 1\n * @param {number} [gamma=1.0] - Gamma correction factor. For gamma-correct blending, 2.2 is usual.\n */\nexport function blend(background, overlay, opacity, gamma = 1.0) {\n const blendChannel = (b, o) => Math.round((b ** (1 / gamma) * (1 - opacity) + o ** (1 / gamma) * opacity) ** gamma);\n const backgroundColor = decomposeColor(background);\n const overlayColor = decomposeColor(overlay);\n const rgb = [blendChannel(backgroundColor.values[0], overlayColor.values[0]), blendChannel(backgroundColor.values[1], overlayColor.values[1]), blendChannel(backgroundColor.values[2], overlayColor.values[2])];\n return recomposeColor({\n type: 'rgb',\n values: rgb\n });\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nexport default function createMixins(breakpoints, mixins) {\n return _extends({\n toolbar: {\n minHeight: 56,\n [breakpoints.up('xs')]: {\n '@media (orientation: landscape)': {\n minHeight: 48\n }\n },\n [breakpoints.up('sm')]: {\n minHeight: 64\n }\n }\n }, mixins);\n}","const common = {\n black: '#000',\n white: '#fff'\n};\nexport default common;","const grey = {\n 50: '#fafafa',\n 100: '#f5f5f5',\n 200: '#eeeeee',\n 300: '#e0e0e0',\n 400: '#bdbdbd',\n 500: '#9e9e9e',\n 600: '#757575',\n 700: '#616161',\n 800: '#424242',\n 900: '#212121',\n A100: '#f5f5f5',\n A200: '#eeeeee',\n A400: '#bdbdbd',\n A700: '#616161'\n};\nexport default grey;","const purple = {\n 50: '#f3e5f5',\n 100: '#e1bee7',\n 200: '#ce93d8',\n 300: '#ba68c8',\n 400: '#ab47bc',\n 500: '#9c27b0',\n 600: '#8e24aa',\n 700: '#7b1fa2',\n 800: '#6a1b9a',\n 900: '#4a148c',\n A100: '#ea80fc',\n A200: '#e040fb',\n A400: '#d500f9',\n A700: '#aa00ff'\n};\nexport default purple;","const red = {\n 50: '#ffebee',\n 100: '#ffcdd2',\n 200: '#ef9a9a',\n 300: '#e57373',\n 400: '#ef5350',\n 500: '#f44336',\n 600: '#e53935',\n 700: '#d32f2f',\n 800: '#c62828',\n 900: '#b71c1c',\n A100: '#ff8a80',\n A200: '#ff5252',\n A400: '#ff1744',\n A700: '#d50000'\n};\nexport default red;","const orange = {\n 50: '#fff3e0',\n 100: '#ffe0b2',\n 200: '#ffcc80',\n 300: '#ffb74d',\n 400: '#ffa726',\n 500: '#ff9800',\n 600: '#fb8c00',\n 700: '#f57c00',\n 800: '#ef6c00',\n 900: '#e65100',\n A100: '#ffd180',\n A200: '#ffab40',\n A400: '#ff9100',\n A700: '#ff6d00'\n};\nexport default orange;","const blue = {\n 50: '#e3f2fd',\n 100: '#bbdefb',\n 200: '#90caf9',\n 300: '#64b5f6',\n 400: '#42a5f5',\n 500: '#2196f3',\n 600: '#1e88e5',\n 700: '#1976d2',\n 800: '#1565c0',\n 900: '#0d47a1',\n A100: '#82b1ff',\n A200: '#448aff',\n A400: '#2979ff',\n A700: '#2962ff'\n};\nexport default blue;","const lightBlue = {\n 50: '#e1f5fe',\n 100: '#b3e5fc',\n 200: '#81d4fa',\n 300: '#4fc3f7',\n 400: '#29b6f6',\n 500: '#03a9f4',\n 600: '#039be5',\n 700: '#0288d1',\n 800: '#0277bd',\n 900: '#01579b',\n A100: '#80d8ff',\n A200: '#40c4ff',\n A400: '#00b0ff',\n A700: '#0091ea'\n};\nexport default lightBlue;","const green = {\n 50: '#e8f5e9',\n 100: '#c8e6c9',\n 200: '#a5d6a7',\n 300: '#81c784',\n 400: '#66bb6a',\n 500: '#4caf50',\n 600: '#43a047',\n 700: '#388e3c',\n 800: '#2e7d32',\n 900: '#1b5e20',\n A100: '#b9f6ca',\n A200: '#69f0ae',\n A400: '#00e676',\n A700: '#00c853'\n};\nexport default green;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\nconst _excluded = [\"mode\", \"contrastThreshold\", \"tonalOffset\"];\nimport { deepmerge } from '@mui/utils';\nimport { darken, getContrastRatio, lighten } from '@mui/system';\nimport common from '../colors/common';\nimport grey from '../colors/grey';\nimport purple from '../colors/purple';\nimport red from '../colors/red';\nimport orange from '../colors/orange';\nimport blue from '../colors/blue';\nimport lightBlue from '../colors/lightBlue';\nimport green from '../colors/green';\nexport const light = {\n // The colors used to style the text.\n text: {\n // The most important text.\n primary: 'rgba(0, 0, 0, 0.87)',\n // Secondary text.\n secondary: 'rgba(0, 0, 0, 0.6)',\n // Disabled text have even lower visual prominence.\n disabled: 'rgba(0, 0, 0, 0.38)'\n },\n // The color used to divide different elements.\n divider: 'rgba(0, 0, 0, 0.12)',\n // The background colors used to style the surfaces.\n // Consistency between these values is important.\n background: {\n paper: common.white,\n default: common.white\n },\n // The colors used to style the action elements.\n action: {\n // The color of an active action like an icon button.\n active: 'rgba(0, 0, 0, 0.54)',\n // The color of an hovered action.\n hover: 'rgba(0, 0, 0, 0.04)',\n hoverOpacity: 0.04,\n // The color of a selected action.\n selected: 'rgba(0, 0, 0, 0.08)',\n selectedOpacity: 0.08,\n // The color of a disabled action.\n disabled: 'rgba(0, 0, 0, 0.26)',\n // The background color of a disabled action.\n disabledBackground: 'rgba(0, 0, 0, 0.12)',\n disabledOpacity: 0.38,\n focus: 'rgba(0, 0, 0, 0.12)',\n focusOpacity: 0.12,\n activatedOpacity: 0.12\n }\n};\nexport const dark = {\n text: {\n primary: common.white,\n secondary: 'rgba(255, 255, 255, 0.7)',\n disabled: 'rgba(255, 255, 255, 0.5)',\n icon: 'rgba(255, 255, 255, 0.5)'\n },\n divider: 'rgba(255, 255, 255, 0.12)',\n background: {\n paper: '#121212',\n default: '#121212'\n },\n action: {\n active: common.white,\n hover: 'rgba(255, 255, 255, 0.08)',\n hoverOpacity: 0.08,\n selected: 'rgba(255, 255, 255, 0.16)',\n selectedOpacity: 0.16,\n disabled: 'rgba(255, 255, 255, 0.3)',\n disabledBackground: 'rgba(255, 255, 255, 0.12)',\n disabledOpacity: 0.38,\n focus: 'rgba(255, 255, 255, 0.12)',\n focusOpacity: 0.12,\n activatedOpacity: 0.24\n }\n};\nfunction addLightOrDark(intent, direction, shade, tonalOffset) {\n const tonalOffsetLight = tonalOffset.light || tonalOffset;\n const tonalOffsetDark = tonalOffset.dark || tonalOffset * 1.5;\n if (!intent[direction]) {\n if (intent.hasOwnProperty(shade)) {\n intent[direction] = intent[shade];\n } else if (direction === 'light') {\n intent.light = lighten(intent.main, tonalOffsetLight);\n } else if (direction === 'dark') {\n intent.dark = darken(intent.main, tonalOffsetDark);\n }\n }\n}\nfunction getDefaultPrimary(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: blue[200],\n light: blue[50],\n dark: blue[400]\n };\n }\n return {\n main: blue[700],\n light: blue[400],\n dark: blue[800]\n };\n}\nfunction getDefaultSecondary(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: purple[200],\n light: purple[50],\n dark: purple[400]\n };\n }\n return {\n main: purple[500],\n light: purple[300],\n dark: purple[700]\n };\n}\nfunction getDefaultError(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: red[500],\n light: red[300],\n dark: red[700]\n };\n }\n return {\n main: red[700],\n light: red[400],\n dark: red[800]\n };\n}\nfunction getDefaultInfo(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: lightBlue[400],\n light: lightBlue[300],\n dark: lightBlue[700]\n };\n }\n return {\n main: lightBlue[700],\n light: lightBlue[500],\n dark: lightBlue[900]\n };\n}\nfunction getDefaultSuccess(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: green[400],\n light: green[300],\n dark: green[700]\n };\n }\n return {\n main: green[800],\n light: green[500],\n dark: green[900]\n };\n}\nfunction getDefaultWarning(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: orange[400],\n light: orange[300],\n dark: orange[700]\n };\n }\n return {\n main: '#ed6c02',\n // closest to orange[800] that pass 3:1.\n light: orange[500],\n dark: orange[900]\n };\n}\nexport default function createPalette(palette) {\n const {\n mode = 'light',\n contrastThreshold = 3,\n tonalOffset = 0.2\n } = palette,\n other = _objectWithoutPropertiesLoose(palette, _excluded);\n const primary = palette.primary || getDefaultPrimary(mode);\n const secondary = palette.secondary || getDefaultSecondary(mode);\n const error = palette.error || getDefaultError(mode);\n const info = palette.info || getDefaultInfo(mode);\n const success = palette.success || getDefaultSuccess(mode);\n const warning = palette.warning || getDefaultWarning(mode);\n\n // Use the same logic as\n // Bootstrap: https://github.com/twbs/bootstrap/blob/1d6e3710dd447de1a200f29e8fa521f8a0908f70/scss/_functions.scss#L59\n // and material-components-web https://github.com/material-components/material-components-web/blob/ac46b8863c4dab9fc22c4c662dc6bd1b65dd652f/packages/mdc-theme/_functions.scss#L54\n function getContrastText(background) {\n const contrastText = getContrastRatio(background, dark.text.primary) >= contrastThreshold ? dark.text.primary : light.text.primary;\n if (process.env.NODE_ENV !== 'production') {\n const contrast = getContrastRatio(background, contrastText);\n if (contrast < 3) {\n console.error([`MUI: The contrast ratio of ${contrast}:1 for ${contrastText} on ${background}`, 'falls below the WCAG recommended absolute minimum contrast ratio of 3:1.', 'https://www.w3.org/TR/2008/REC-WCAG20-20081211/#visual-audio-contrast-contrast'].join('\\n'));\n }\n }\n return contrastText;\n }\n const augmentColor = ({\n color,\n name,\n mainShade = 500,\n lightShade = 300,\n darkShade = 700\n }) => {\n color = _extends({}, color);\n if (!color.main && color[mainShade]) {\n color.main = color[mainShade];\n }\n if (!color.hasOwnProperty('main')) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: The color${name ? ` (${name})` : ''} provided to augmentColor(color) is invalid.\nThe color object needs to have a \\`main\\` property or a \\`${mainShade}\\` property.` : _formatMuiErrorMessage(11, name ? ` (${name})` : '', mainShade));\n }\n if (typeof color.main !== 'string') {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: The color${name ? ` (${name})` : ''} provided to augmentColor(color) is invalid.\n\\`color.main\\` should be a string, but \\`${JSON.stringify(color.main)}\\` was provided instead.\n\nDid you intend to use one of the following approaches?\n\nimport { green } from \"@mui/material/colors\";\n\nconst theme1 = createTheme({ palette: {\n primary: green,\n} });\n\nconst theme2 = createTheme({ palette: {\n primary: { main: green[500] },\n} });` : _formatMuiErrorMessage(12, name ? ` (${name})` : '', JSON.stringify(color.main)));\n }\n addLightOrDark(color, 'light', lightShade, tonalOffset);\n addLightOrDark(color, 'dark', darkShade, tonalOffset);\n if (!color.contrastText) {\n color.contrastText = getContrastText(color.main);\n }\n return color;\n };\n const modes = {\n dark,\n light\n };\n if (process.env.NODE_ENV !== 'production') {\n if (!modes[mode]) {\n console.error(`MUI: The palette mode \\`${mode}\\` is not supported.`);\n }\n }\n const paletteOutput = deepmerge(_extends({\n // A collection of common colors.\n common: _extends({}, common),\n // prevent mutable object.\n // The palette mode, can be light or dark.\n mode,\n // The colors used to represent primary interface elements for a user.\n primary: augmentColor({\n color: primary,\n name: 'primary'\n }),\n // The colors used to represent secondary interface elements for a user.\n secondary: augmentColor({\n color: secondary,\n name: 'secondary',\n mainShade: 'A400',\n lightShade: 'A200',\n darkShade: 'A700'\n }),\n // The colors used to represent interface elements that the user should be made aware of.\n error: augmentColor({\n color: error,\n name: 'error'\n }),\n // The colors used to represent potentially dangerous actions or important messages.\n warning: augmentColor({\n color: warning,\n name: 'warning'\n }),\n // The colors used to present information to the user that is neutral and not necessarily important.\n info: augmentColor({\n color: info,\n name: 'info'\n }),\n // The colors used to indicate the successful completion of an action that user triggered.\n success: augmentColor({\n color: success,\n name: 'success'\n }),\n // The grey colors.\n grey,\n // Used by `getContrastText()` to maximize the contrast between\n // the background and the text.\n contrastThreshold,\n // Takes a background color and returns the text color that maximizes the contrast.\n getContrastText,\n // Generate a rich color object.\n augmentColor,\n // Used by the functions below to shift a color's luminance by approximately\n // two indexes within its tonal palette.\n // E.g., shift from Red 500 to Red 300 or Red 700.\n tonalOffset\n }, modes[mode]), other);\n return paletteOutput;\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"fontFamily\", \"fontSize\", \"fontWeightLight\", \"fontWeightRegular\", \"fontWeightMedium\", \"fontWeightBold\", \"htmlFontSize\", \"allVariants\", \"pxToRem\"];\nimport { deepmerge } from '@mui/utils';\nfunction round(value) {\n return Math.round(value * 1e5) / 1e5;\n}\nconst caseAllCaps = {\n textTransform: 'uppercase'\n};\nconst defaultFontFamily = '\"Roboto\", \"Helvetica\", \"Arial\", sans-serif';\n\n/**\n * @see @link{https://m2.material.io/design/typography/the-type-system.html}\n * @see @link{https://m2.material.io/design/typography/understanding-typography.html}\n */\nexport default function createTypography(palette, typography) {\n const _ref = typeof typography === 'function' ? typography(palette) : typography,\n {\n fontFamily = defaultFontFamily,\n // The default font size of the Material Specification.\n fontSize = 14,\n // px\n fontWeightLight = 300,\n fontWeightRegular = 400,\n fontWeightMedium = 500,\n fontWeightBold = 700,\n // Tell MUI what's the font-size on the html element.\n // 16px is the default font-size used by browsers.\n htmlFontSize = 16,\n // Apply the CSS properties to all the variants.\n allVariants,\n pxToRem: pxToRem2\n } = _ref,\n other = _objectWithoutPropertiesLoose(_ref, _excluded);\n if (process.env.NODE_ENV !== 'production') {\n if (typeof fontSize !== 'number') {\n console.error('MUI: `fontSize` is required to be a number.');\n }\n if (typeof htmlFontSize !== 'number') {\n console.error('MUI: `htmlFontSize` is required to be a number.');\n }\n }\n const coef = fontSize / 14;\n const pxToRem = pxToRem2 || (size => `${size / htmlFontSize * coef}rem`);\n const buildVariant = (fontWeight, size, lineHeight, letterSpacing, casing) => _extends({\n fontFamily,\n fontWeight,\n fontSize: pxToRem(size),\n // Unitless following https://meyerweb.com/eric/thoughts/2006/02/08/unitless-line-heights/\n lineHeight\n }, fontFamily === defaultFontFamily ? {\n letterSpacing: `${round(letterSpacing / size)}em`\n } : {}, casing, allVariants);\n const variants = {\n h1: buildVariant(fontWeightLight, 96, 1.167, -1.5),\n h2: buildVariant(fontWeightLight, 60, 1.2, -0.5),\n h3: buildVariant(fontWeightRegular, 48, 1.167, 0),\n h4: buildVariant(fontWeightRegular, 34, 1.235, 0.25),\n h5: buildVariant(fontWeightRegular, 24, 1.334, 0),\n h6: buildVariant(fontWeightMedium, 20, 1.6, 0.15),\n subtitle1: buildVariant(fontWeightRegular, 16, 1.75, 0.15),\n subtitle2: buildVariant(fontWeightMedium, 14, 1.57, 0.1),\n body1: buildVariant(fontWeightRegular, 16, 1.5, 0.15),\n body2: buildVariant(fontWeightRegular, 14, 1.43, 0.15),\n button: buildVariant(fontWeightMedium, 14, 1.75, 0.4, caseAllCaps),\n caption: buildVariant(fontWeightRegular, 12, 1.66, 0.4),\n overline: buildVariant(fontWeightRegular, 12, 2.66, 1, caseAllCaps),\n // TODO v6: Remove handling of 'inherit' variant from the theme as it is already handled in Material UI's Typography component. Also, remember to remove the associated types.\n inherit: {\n fontFamily: 'inherit',\n fontWeight: 'inherit',\n fontSize: 'inherit',\n lineHeight: 'inherit',\n letterSpacing: 'inherit'\n }\n };\n return deepmerge(_extends({\n htmlFontSize,\n pxToRem,\n fontFamily,\n fontSize,\n fontWeightLight,\n fontWeightRegular,\n fontWeightMedium,\n fontWeightBold\n }, variants), other, {\n clone: false // No need to clone deep\n });\n}","const shadowKeyUmbraOpacity = 0.2;\nconst shadowKeyPenumbraOpacity = 0.14;\nconst shadowAmbientShadowOpacity = 0.12;\nfunction createShadow(...px) {\n return [`${px[0]}px ${px[1]}px ${px[2]}px ${px[3]}px rgba(0,0,0,${shadowKeyUmbraOpacity})`, `${px[4]}px ${px[5]}px ${px[6]}px ${px[7]}px rgba(0,0,0,${shadowKeyPenumbraOpacity})`, `${px[8]}px ${px[9]}px ${px[10]}px ${px[11]}px rgba(0,0,0,${shadowAmbientShadowOpacity})`].join(',');\n}\n\n// Values from https://github.com/material-components/material-components-web/blob/be8747f94574669cb5e7add1a7c54fa41a89cec7/packages/mdc-elevation/_variables.scss\nconst shadows = ['none', createShadow(0, 2, 1, -1, 0, 1, 1, 0, 0, 1, 3, 0), createShadow(0, 3, 1, -2, 0, 2, 2, 0, 0, 1, 5, 0), createShadow(0, 3, 3, -2, 0, 3, 4, 0, 0, 1, 8, 0), createShadow(0, 2, 4, -1, 0, 4, 5, 0, 0, 1, 10, 0), createShadow(0, 3, 5, -1, 0, 5, 8, 0, 0, 1, 14, 0), createShadow(0, 3, 5, -1, 0, 6, 10, 0, 0, 1, 18, 0), createShadow(0, 4, 5, -2, 0, 7, 10, 1, 0, 2, 16, 1), createShadow(0, 5, 5, -3, 0, 8, 10, 1, 0, 3, 14, 2), createShadow(0, 5, 6, -3, 0, 9, 12, 1, 0, 3, 16, 2), createShadow(0, 6, 6, -3, 0, 10, 14, 1, 0, 4, 18, 3), createShadow(0, 6, 7, -4, 0, 11, 15, 1, 0, 4, 20, 3), createShadow(0, 7, 8, -4, 0, 12, 17, 2, 0, 5, 22, 4), createShadow(0, 7, 8, -4, 0, 13, 19, 2, 0, 5, 24, 4), createShadow(0, 7, 9, -4, 0, 14, 21, 2, 0, 5, 26, 4), createShadow(0, 8, 9, -5, 0, 15, 22, 2, 0, 6, 28, 5), createShadow(0, 8, 10, -5, 0, 16, 24, 2, 0, 6, 30, 5), createShadow(0, 8, 11, -5, 0, 17, 26, 2, 0, 6, 32, 5), createShadow(0, 9, 11, -5, 0, 18, 28, 2, 0, 7, 34, 6), createShadow(0, 9, 12, -6, 0, 19, 29, 2, 0, 7, 36, 6), createShadow(0, 10, 13, -6, 0, 20, 31, 3, 0, 8, 38, 7), createShadow(0, 10, 13, -6, 0, 21, 33, 3, 0, 8, 40, 7), createShadow(0, 10, 14, -6, 0, 22, 35, 3, 0, 8, 42, 7), createShadow(0, 11, 14, -7, 0, 23, 36, 3, 0, 9, 44, 8), createShadow(0, 11, 15, -7, 0, 24, 38, 3, 0, 9, 46, 8)];\nexport default shadows;","import _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nconst _excluded = [\"duration\", \"easing\", \"delay\"];\n// Follow https://material.google.com/motion/duration-easing.html#duration-easing-natural-easing-curves\n// to learn the context in which each easing should be used.\nexport const easing = {\n // This is the most common easing curve.\n easeInOut: 'cubic-bezier(0.4, 0, 0.2, 1)',\n // Objects enter the screen at full velocity from off-screen and\n // slowly decelerate to a resting point.\n easeOut: 'cubic-bezier(0.0, 0, 0.2, 1)',\n // Objects leave the screen at full velocity. They do not decelerate when off-screen.\n easeIn: 'cubic-bezier(0.4, 0, 1, 1)',\n // The sharp curve is used by objects that may return to the screen at any time.\n sharp: 'cubic-bezier(0.4, 0, 0.6, 1)'\n};\n\n// Follow https://m2.material.io/guidelines/motion/duration-easing.html#duration-easing-common-durations\n// to learn when use what timing\nexport const duration = {\n shortest: 150,\n shorter: 200,\n short: 250,\n // most basic recommended timing\n standard: 300,\n // this is to be used in complex animations\n complex: 375,\n // recommended when something is entering screen\n enteringScreen: 225,\n // recommended when something is leaving screen\n leavingScreen: 195\n};\nfunction formatMs(milliseconds) {\n return `${Math.round(milliseconds)}ms`;\n}\nfunction getAutoHeightDuration(height) {\n if (!height) {\n return 0;\n }\n const constant = height / 36;\n\n // https://www.wolframalpha.com/input/?i=(4+%2B+15+*+(x+%2F+36+)+**+0.25+%2B+(x+%2F+36)+%2F+5)+*+10\n return Math.round((4 + 15 * constant ** 0.25 + constant / 5) * 10);\n}\nexport default function createTransitions(inputTransitions) {\n const mergedEasing = _extends({}, easing, inputTransitions.easing);\n const mergedDuration = _extends({}, duration, inputTransitions.duration);\n const create = (props = ['all'], options = {}) => {\n const {\n duration: durationOption = mergedDuration.standard,\n easing: easingOption = mergedEasing.easeInOut,\n delay = 0\n } = options,\n other = _objectWithoutPropertiesLoose(options, _excluded);\n if (process.env.NODE_ENV !== 'production') {\n const isString = value => typeof value === 'string';\n // IE11 support, replace with Number.isNaN\n // eslint-disable-next-line no-restricted-globals\n const isNumber = value => !isNaN(parseFloat(value));\n if (!isString(props) && !Array.isArray(props)) {\n console.error('MUI: Argument \"props\" must be a string or Array.');\n }\n if (!isNumber(durationOption) && !isString(durationOption)) {\n console.error(`MUI: Argument \"duration\" must be a number or a string but found ${durationOption}.`);\n }\n if (!isString(easingOption)) {\n console.error('MUI: Argument \"easing\" must be a string.');\n }\n if (!isNumber(delay) && !isString(delay)) {\n console.error('MUI: Argument \"delay\" must be a number or a string.');\n }\n if (typeof options !== 'object') {\n console.error(['MUI: Secong argument of transition.create must be an object.', \"Arguments should be either `create('prop1', options)` or `create(['prop1', 'prop2'], options)`\"].join('\\n'));\n }\n if (Object.keys(other).length !== 0) {\n console.error(`MUI: Unrecognized argument(s) [${Object.keys(other).join(',')}].`);\n }\n }\n return (Array.isArray(props) ? props : [props]).map(animatedProp => `${animatedProp} ${typeof durationOption === 'string' ? durationOption : formatMs(durationOption)} ${easingOption} ${typeof delay === 'string' ? delay : formatMs(delay)}`).join(',');\n };\n return _extends({\n getAutoHeightDuration,\n create\n }, inputTransitions, {\n easing: mergedEasing,\n duration: mergedDuration\n });\n}","// We need to centralize the zIndex definitions as they work\n// like global values in the browser.\nconst zIndex = {\n mobileStepper: 1000,\n fab: 1050,\n speedDial: 1050,\n appBar: 1100,\n drawer: 1200,\n modal: 1300,\n snackbar: 1400,\n tooltip: 1500\n};\nexport default zIndex;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\nconst _excluded = [\"breakpoints\", \"mixins\", \"spacing\", \"palette\", \"transitions\", \"typography\", \"shape\"];\nimport { deepmerge } from '@mui/utils';\nimport { createTheme as systemCreateTheme, unstable_defaultSxConfig as defaultSxConfig, unstable_styleFunctionSx as styleFunctionSx } from '@mui/system';\nimport generateUtilityClass from '@mui/utils/generateUtilityClass';\nimport createMixins from './createMixins';\nimport createPalette from './createPalette';\nimport createTypography from './createTypography';\nimport shadows from './shadows';\nimport createTransitions from './createTransitions';\nimport zIndex from './zIndex';\nfunction createTheme(options = {}, ...args) {\n const {\n mixins: mixinsInput = {},\n palette: paletteInput = {},\n transitions: transitionsInput = {},\n typography: typographyInput = {}\n } = options,\n other = _objectWithoutPropertiesLoose(options, _excluded);\n if (options.vars) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: \\`vars\\` is a private field used for CSS variables support.\nPlease use another name.` : _formatMuiErrorMessage(18));\n }\n const palette = createPalette(paletteInput);\n const systemTheme = systemCreateTheme(options);\n let muiTheme = deepmerge(systemTheme, {\n mixins: createMixins(systemTheme.breakpoints, mixinsInput),\n palette,\n // Don't use [...shadows] until you've verified its transpiled code is not invoking the iterator protocol.\n shadows: shadows.slice(),\n typography: createTypography(palette, typographyInput),\n transitions: createTransitions(transitionsInput),\n zIndex: _extends({}, zIndex)\n });\n muiTheme = deepmerge(muiTheme, other);\n muiTheme = args.reduce((acc, argument) => deepmerge(acc, argument), muiTheme);\n if (process.env.NODE_ENV !== 'production') {\n // TODO v6: Refactor to use globalStateClassesMapping from @mui/utils once `readOnly` state class is used in Rating component.\n const stateClasses = ['active', 'checked', 'completed', 'disabled', 'error', 'expanded', 'focused', 'focusVisible', 'required', 'selected'];\n const traverse = (node, component) => {\n let key;\n\n // eslint-disable-next-line guard-for-in, no-restricted-syntax\n for (key in node) {\n const child = node[key];\n if (stateClasses.indexOf(key) !== -1 && Object.keys(child).length > 0) {\n if (process.env.NODE_ENV !== 'production') {\n const stateClass = generateUtilityClass('', key);\n console.error([`MUI: The \\`${component}\\` component increases ` + `the CSS specificity of the \\`${key}\\` internal state.`, 'You can not override it like this: ', JSON.stringify(node, null, 2), '', `Instead, you need to use the '&.${stateClass}' syntax:`, JSON.stringify({\n root: {\n [`&.${stateClass}`]: child\n }\n }, null, 2), '', 'https://mui.com/r/state-classes-guide'].join('\\n'));\n }\n // Remove the style to prevent global conflicts.\n node[key] = {};\n }\n }\n };\n Object.keys(muiTheme.components).forEach(component => {\n const styleOverrides = muiTheme.components[component].styleOverrides;\n if (styleOverrides && component.indexOf('Mui') === 0) {\n traverse(styleOverrides, component);\n }\n });\n }\n muiTheme.unstable_sxConfig = _extends({}, defaultSxConfig, other == null ? void 0 : other.unstable_sxConfig);\n muiTheme.unstable_sx = function sx(props) {\n return styleFunctionSx({\n sx: props,\n theme: this\n });\n };\n return muiTheme;\n}\nlet warnedOnce = false;\nexport function createMuiTheme(...args) {\n if (process.env.NODE_ENV !== 'production') {\n if (!warnedOnce) {\n warnedOnce = true;\n console.error(['MUI: the createMuiTheme function was renamed to createTheme.', '', \"You should use `import { createTheme } from '@mui/material/styles'`\"].join('\\n'));\n }\n }\n return createTheme(...args);\n}\nexport default createTheme;","'use client';\n\nimport createTheme from './createTheme';\nconst defaultTheme = createTheme();\nexport default defaultTheme;","export default '$$material';","'use client';\n\nimport { useThemeProps as systemUseThemeProps } from '@mui/system';\nimport defaultTheme from './defaultTheme';\nimport THEME_ID from './identifier';\nexport default function useThemeProps({\n props,\n name\n}) {\n return systemUseThemeProps({\n props,\n name,\n defaultTheme,\n themeId: THEME_ID\n });\n}","'use client';\n\nimport { createStyled, shouldForwardProp } from '@mui/system';\nimport defaultTheme from './defaultTheme';\nimport THEME_ID from './identifier';\nexport const rootShouldForwardProp = prop => shouldForwardProp(prop) && prop !== 'classes';\nexport const slotShouldForwardProp = shouldForwardProp;\nconst styled = createStyled({\n themeId: THEME_ID,\n defaultTheme,\n rootShouldForwardProp\n});\nexport default styled;","import generateUtilityClasses from '@mui/utils/generateUtilityClasses';\nimport generateUtilityClass from '@mui/utils/generateUtilityClass';\nexport function getSvgIconUtilityClass(slot) {\n return generateUtilityClass('MuiSvgIcon', slot);\n}\nconst svgIconClasses = generateUtilityClasses('MuiSvgIcon', ['root', 'colorPrimary', 'colorSecondary', 'colorAction', 'colorError', 'colorDisabled', 'fontSizeInherit', 'fontSizeSmall', 'fontSizeMedium', 'fontSizeLarge']);\nexport default svgIconClasses;","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"children\", \"className\", \"color\", \"component\", \"fontSize\", \"htmlColor\", \"inheritViewBox\", \"titleAccess\", \"viewBox\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport clsx from 'clsx';\nimport { unstable_composeClasses as composeClasses } from '@mui/base/composeClasses';\nimport capitalize from '../utils/capitalize';\nimport useThemeProps from '../styles/useThemeProps';\nimport styled from '../styles/styled';\nimport { getSvgIconUtilityClass } from './svgIconClasses';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nimport { jsxs as _jsxs } from \"react/jsx-runtime\";\nconst useUtilityClasses = ownerState => {\n const {\n color,\n fontSize,\n classes\n } = ownerState;\n const slots = {\n root: ['root', color !== 'inherit' && `color${capitalize(color)}`, `fontSize${capitalize(fontSize)}`]\n };\n return composeClasses(slots, getSvgIconUtilityClass, classes);\n};\nconst SvgIconRoot = styled('svg', {\n name: 'MuiSvgIcon',\n slot: 'Root',\n overridesResolver: (props, styles) => {\n const {\n ownerState\n } = props;\n return [styles.root, ownerState.color !== 'inherit' && styles[`color${capitalize(ownerState.color)}`], styles[`fontSize${capitalize(ownerState.fontSize)}`]];\n }\n})(({\n theme,\n ownerState\n}) => {\n var _theme$transitions, _theme$transitions$cr, _theme$transitions2, _theme$typography, _theme$typography$pxT, _theme$typography2, _theme$typography2$px, _theme$typography3, _theme$typography3$px, _palette$ownerState$c, _palette, _palette2, _palette3;\n return {\n userSelect: 'none',\n width: '1em',\n height: '1em',\n display: 'inline-block',\n // the will define the property that has `currentColor`\n // e.g. heroicons uses fill=\"none\" and stroke=\"currentColor\"\n fill: ownerState.hasSvgAsChild ? undefined : 'currentColor',\n flexShrink: 0,\n transition: (_theme$transitions = theme.transitions) == null || (_theme$transitions$cr = _theme$transitions.create) == null ? void 0 : _theme$transitions$cr.call(_theme$transitions, 'fill', {\n duration: (_theme$transitions2 = theme.transitions) == null || (_theme$transitions2 = _theme$transitions2.duration) == null ? void 0 : _theme$transitions2.shorter\n }),\n fontSize: {\n inherit: 'inherit',\n small: ((_theme$typography = theme.typography) == null || (_theme$typography$pxT = _theme$typography.pxToRem) == null ? void 0 : _theme$typography$pxT.call(_theme$typography, 20)) || '1.25rem',\n medium: ((_theme$typography2 = theme.typography) == null || (_theme$typography2$px = _theme$typography2.pxToRem) == null ? void 0 : _theme$typography2$px.call(_theme$typography2, 24)) || '1.5rem',\n large: ((_theme$typography3 = theme.typography) == null || (_theme$typography3$px = _theme$typography3.pxToRem) == null ? void 0 : _theme$typography3$px.call(_theme$typography3, 35)) || '2.1875rem'\n }[ownerState.fontSize],\n // TODO v5 deprecate, v6 remove for sx\n color: (_palette$ownerState$c = (_palette = (theme.vars || theme).palette) == null || (_palette = _palette[ownerState.color]) == null ? void 0 : _palette.main) != null ? _palette$ownerState$c : {\n action: (_palette2 = (theme.vars || theme).palette) == null || (_palette2 = _palette2.action) == null ? void 0 : _palette2.active,\n disabled: (_palette3 = (theme.vars || theme).palette) == null || (_palette3 = _palette3.action) == null ? void 0 : _palette3.disabled,\n inherit: undefined\n }[ownerState.color]\n };\n});\nconst SvgIcon = /*#__PURE__*/React.forwardRef(function SvgIcon(inProps, ref) {\n const props = useThemeProps({\n props: inProps,\n name: 'MuiSvgIcon'\n });\n const {\n children,\n className,\n color = 'inherit',\n component = 'svg',\n fontSize = 'medium',\n htmlColor,\n inheritViewBox = false,\n titleAccess,\n viewBox = '0 0 24 24'\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const hasSvgAsChild = /*#__PURE__*/React.isValidElement(children) && children.type === 'svg';\n const ownerState = _extends({}, props, {\n color,\n component,\n fontSize,\n instanceFontSize: inProps.fontSize,\n inheritViewBox,\n viewBox,\n hasSvgAsChild\n });\n const more = {};\n if (!inheritViewBox) {\n more.viewBox = viewBox;\n }\n const classes = useUtilityClasses(ownerState);\n return /*#__PURE__*/_jsxs(SvgIconRoot, _extends({\n as: component,\n className: clsx(classes.root, className),\n focusable: \"false\",\n color: htmlColor,\n \"aria-hidden\": titleAccess ? undefined : true,\n role: titleAccess ? 'img' : undefined,\n ref: ref\n }, more, other, hasSvgAsChild && children.props, {\n ownerState: ownerState,\n children: [hasSvgAsChild ? children.props.children : children, titleAccess ? /*#__PURE__*/_jsx(\"title\", {\n children: titleAccess\n }) : null]\n }));\n});\nprocess.env.NODE_ENV !== \"production\" ? SvgIcon.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the d.ts file and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * Node passed into the SVG element.\n */\n children: PropTypes.node,\n /**\n * Override or extend the styles applied to the component.\n */\n classes: PropTypes.object,\n /**\n * @ignore\n */\n className: PropTypes.string,\n /**\n * The color of the component.\n * It supports both default and custom theme colors, which can be added as shown in the\n * [palette customization guide](https://mui.com/material-ui/customization/palette/#custom-colors).\n * You can use the `htmlColor` prop to apply a color attribute to the SVG element.\n * @default 'inherit'\n */\n color: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.oneOf(['inherit', 'action', 'disabled', 'primary', 'secondary', 'error', 'info', 'success', 'warning']), PropTypes.string]),\n /**\n * The component used for the root node.\n * Either a string to use a HTML element or a component.\n */\n component: PropTypes.elementType,\n /**\n * The fontSize applied to the icon. Defaults to 24px, but can be configure to inherit font size.\n * @default 'medium'\n */\n fontSize: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.oneOf(['inherit', 'large', 'medium', 'small']), PropTypes.string]),\n /**\n * Applies a color attribute to the SVG element.\n */\n htmlColor: PropTypes.string,\n /**\n * If `true`, the root node will inherit the custom `component`'s viewBox and the `viewBox`\n * prop will be ignored.\n * Useful when you want to reference a custom `component` and have `SvgIcon` pass that\n * `component`'s viewBox to the root node.\n * @default false\n */\n inheritViewBox: PropTypes.bool,\n /**\n * The shape-rendering attribute. The behavior of the different options is described on the\n * [MDN Web Docs](https://developer.mozilla.org/en-US/docs/Web/SVG/Attribute/shape-rendering).\n * If you are having issues with blurry icons you should investigate this prop.\n */\n shapeRendering: PropTypes.string,\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Provides a human-readable title for the element that contains it.\n * https://www.w3.org/TR/SVG-access/#Equivalent\n */\n titleAccess: PropTypes.string,\n /**\n * Allows you to redefine what the coordinates without units mean inside an SVG element.\n * For example, if the SVG element is 500 (width) by 200 (height),\n * and you pass viewBox=\"0 0 50 20\",\n * this means that the coordinates inside the SVG will go from the top left corner (0,0)\n * to bottom right (50,20) and each unit will be worth 10px.\n * @default '0 0 24 24'\n */\n viewBox: PropTypes.string\n} : void 0;\nSvgIcon.muiName = 'SvgIcon';\nexport default SvgIcon;","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport * as React from 'react';\nimport SvgIcon from '../SvgIcon';\n\n/**\n * Private module reserved for @mui packages.\n */\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nexport default function createSvgIcon(path, displayName) {\n function Component(props, ref) {\n return /*#__PURE__*/_jsx(SvgIcon, _extends({\n \"data-testid\": `${displayName}Icon`,\n ref: ref\n }, props, {\n children: path\n }));\n }\n if (process.env.NODE_ENV !== 'production') {\n // Need to set `displayName` on the inner component for React.memo.\n // React prior to 16.14 ignores `displayName` on the wrapper.\n Component.displayName = `${displayName}Icon`;\n }\n Component.muiName = SvgIcon.muiName;\n return /*#__PURE__*/React.memo( /*#__PURE__*/React.forwardRef(Component));\n}","'use client';\n\nimport { unstable_ClassNameGenerator as ClassNameGenerator } from '@mui/base/ClassNameGenerator';\nexport { default as capitalize } from './capitalize';\nexport { default as createChainedFunction } from './createChainedFunction';\nexport { default as createSvgIcon } from './createSvgIcon';\nexport { default as debounce } from './debounce';\nexport { default as deprecatedPropType } from './deprecatedPropType';\nexport { default as isMuiElement } from './isMuiElement';\nexport { default as ownerDocument } from './ownerDocument';\nexport { default as ownerWindow } from './ownerWindow';\nexport { default as requirePropFactory } from './requirePropFactory';\nexport { default as setRef } from './setRef';\nexport { default as unstable_useEnhancedEffect } from './useEnhancedEffect';\nexport { default as unstable_useId } from './useId';\nexport { default as unsupportedProp } from './unsupportedProp';\nexport { default as useControlled } from './useControlled';\nexport { default as useEventCallback } from './useEventCallback';\nexport { default as useForkRef } from './useForkRef';\nexport { default as useIsFocusVisible } from './useIsFocusVisible';\n// TODO: remove this export once ClassNameGenerator is stable\n// eslint-disable-next-line @typescript-eslint/naming-convention\nexport const unstable_ClassNameGenerator = {\n configure: generator => {\n if (process.env.NODE_ENV !== 'production') {\n console.warn(['MUI: `ClassNameGenerator` import from `@mui/material/utils` is outdated and might cause unexpected issues.', '', \"You should use `import { unstable_ClassNameGenerator } from '@mui/material/className'` instead\", '', 'The detail of the issue: https://github.com/mui/material-ui/issues/30011#issuecomment-1024993401', '', 'The updated documentation: https://mui.com/guides/classname-generator/'].join('\\n'));\n }\n ClassNameGenerator.configure(generator);\n }\n};","\"use strict\";\n'use client';\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nObject.defineProperty(exports, \"default\", {\n enumerable: true,\n get: function () {\n return _utils.createSvgIcon;\n }\n});\nvar _utils = require(\"@mui/material/utils\");","\"use strict\";\n\"use client\";\n\nvar _interopRequireDefault = require(\"@babel/runtime/helpers/interopRequireDefault\");\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = void 0;\nvar _createSvgIcon = _interopRequireDefault(require(\"./utils/createSvgIcon\"));\nvar _jsxRuntime = require(\"react/jsx-runtime\");\nvar _default = exports.default = (0, _createSvgIcon.default)( /*#__PURE__*/(0, _jsxRuntime.jsx)(\"path\", {\n d: \"m10 17 5-5-5-5z\"\n}), 'ArrowRight');","/**\n * Determines if a given element is a DOM element name (i.e. not a React component).\n */\nexport function isHostComponent(element) {\n return typeof element === 'string';\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport { isHostComponent } from './isHostComponent';\n\n/**\n * Type of the ownerState based on the type of an element it applies to.\n * This resolves to the provided OwnerState for React components and `undefined` for host components.\n * Falls back to `OwnerState | undefined` when the exact type can't be determined in development time.\n */\n\n/**\n * Appends the ownerState object to the props, merging with the existing one if necessary.\n *\n * @param elementType Type of the element that owns the `existingProps`. If the element is a DOM node or undefined, `ownerState` is not applied.\n * @param otherProps Props of the element.\n * @param ownerState\n */\nexport function appendOwnerState(elementType, otherProps, ownerState) {\n if (elementType === undefined || isHostComponent(elementType)) {\n return otherProps;\n }\n return _extends({}, otherProps, {\n ownerState: _extends({}, otherProps.ownerState, ownerState)\n });\n}","'use client';\n\nimport * as React from 'react';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nconst defaultContextValue = {\n disableDefaultClasses: false\n};\nconst ClassNameConfiguratorContext = /*#__PURE__*/React.createContext(defaultContextValue);\n/**\n * @ignore - internal hook.\n *\n * Wraps the `generateUtilityClass` function and controls how the classes are generated.\n * Currently it only affects whether the classes are applied or not.\n *\n * @returns Function to be called with the `generateUtilityClass` function specific to a component to generate the classes.\n */\nexport function useClassNamesOverride(generateUtilityClass) {\n const {\n disableDefaultClasses\n } = React.useContext(ClassNameConfiguratorContext);\n return slot => {\n if (disableDefaultClasses) {\n return '';\n }\n return generateUtilityClass(slot);\n };\n}\n\n/**\n * Allows to configure the components within to not apply any built-in classes.\n */\nexport function ClassNameConfigurator(props) {\n const {\n disableDefaultClasses,\n children\n } = props;\n const contextValue = React.useMemo(() => ({\n disableDefaultClasses: disableDefaultClasses != null ? disableDefaultClasses : false\n }), [disableDefaultClasses]);\n return /*#__PURE__*/_jsx(ClassNameConfiguratorContext.Provider, {\n value: contextValue,\n children: children\n });\n}","/**\n * Extracts event handlers from a given object.\n * A prop is considered an event handler if it is a function and its name starts with `on`.\n *\n * @param object An object to extract event handlers from.\n * @param excludeKeys An array of keys to exclude from the returned object.\n */\nexport function extractEventHandlers(object, excludeKeys = []) {\n if (object === undefined) {\n return {};\n }\n const result = {};\n Object.keys(object).filter(prop => prop.match(/^on[A-Z]/) && typeof object[prop] === 'function' && !excludeKeys.includes(prop)).forEach(prop => {\n result[prop] = object[prop];\n });\n return result;\n}","/**\n * If `componentProps` is a function, calls it with the provided `ownerState`.\n * Otherwise, just returns `componentProps`.\n */\nexport function resolveComponentProps(componentProps, ownerState, slotState) {\n if (typeof componentProps === 'function') {\n return componentProps(ownerState, slotState);\n }\n return componentProps;\n}","/**\n * Removes event handlers from the given object.\n * A field is considered an event handler if it is a function with a name beginning with `on`.\n *\n * @param object Object to remove event handlers from.\n * @returns Object with event handlers removed.\n */\nexport function omitEventHandlers(object) {\n if (object === undefined) {\n return {};\n }\n const result = {};\n Object.keys(object).filter(prop => !(prop.match(/^on[A-Z]/) && typeof object[prop] === 'function')).forEach(prop => {\n result[prop] = object[prop];\n });\n return result;\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport clsx from 'clsx';\nimport { extractEventHandlers } from './extractEventHandlers';\nimport { omitEventHandlers } from './omitEventHandlers';\n/**\n * Merges the slot component internal props (usually coming from a hook)\n * with the externally provided ones.\n *\n * The merge order is (the latter overrides the former):\n * 1. The internal props (specified as a getter function to work with get*Props hook result)\n * 2. Additional props (specified internally on a Base UI component)\n * 3. External props specified on the owner component. These should only be used on a root slot.\n * 4. External props specified in the `slotProps.*` prop.\n * 5. The `className` prop - combined from all the above.\n * @param parameters\n * @returns\n */\nexport function mergeSlotProps(parameters) {\n const {\n getSlotProps,\n additionalProps,\n externalSlotProps,\n externalForwardedProps,\n className\n } = parameters;\n if (!getSlotProps) {\n // The simpler case - getSlotProps is not defined, so no internal event handlers are defined,\n // so we can simply merge all the props without having to worry about extracting event handlers.\n const joinedClasses = clsx(additionalProps == null ? void 0 : additionalProps.className, className, externalForwardedProps == null ? void 0 : externalForwardedProps.className, externalSlotProps == null ? void 0 : externalSlotProps.className);\n const mergedStyle = _extends({}, additionalProps == null ? void 0 : additionalProps.style, externalForwardedProps == null ? void 0 : externalForwardedProps.style, externalSlotProps == null ? void 0 : externalSlotProps.style);\n const props = _extends({}, additionalProps, externalForwardedProps, externalSlotProps);\n if (joinedClasses.length > 0) {\n props.className = joinedClasses;\n }\n if (Object.keys(mergedStyle).length > 0) {\n props.style = mergedStyle;\n }\n return {\n props,\n internalRef: undefined\n };\n }\n\n // In this case, getSlotProps is responsible for calling the external event handlers.\n // We don't need to include them in the merged props because of this.\n\n const eventHandlers = extractEventHandlers(_extends({}, externalForwardedProps, externalSlotProps));\n const componentsPropsWithoutEventHandlers = omitEventHandlers(externalSlotProps);\n const otherPropsWithoutEventHandlers = omitEventHandlers(externalForwardedProps);\n const internalSlotProps = getSlotProps(eventHandlers);\n\n // The order of classes is important here.\n // Emotion (that we use in libraries consuming Base UI) depends on this order\n // to properly override style. It requires the most important classes to be last\n // (see https://github.com/mui/material-ui/pull/33205) for the related discussion.\n const joinedClasses = clsx(internalSlotProps == null ? void 0 : internalSlotProps.className, additionalProps == null ? void 0 : additionalProps.className, className, externalForwardedProps == null ? void 0 : externalForwardedProps.className, externalSlotProps == null ? void 0 : externalSlotProps.className);\n const mergedStyle = _extends({}, internalSlotProps == null ? void 0 : internalSlotProps.style, additionalProps == null ? void 0 : additionalProps.style, externalForwardedProps == null ? void 0 : externalForwardedProps.style, externalSlotProps == null ? void 0 : externalSlotProps.style);\n const props = _extends({}, internalSlotProps, additionalProps, otherPropsWithoutEventHandlers, componentsPropsWithoutEventHandlers);\n if (joinedClasses.length > 0) {\n props.className = joinedClasses;\n }\n if (Object.keys(mergedStyle).length > 0) {\n props.style = mergedStyle;\n }\n return {\n props,\n internalRef: internalSlotProps.ref\n };\n}","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"elementType\", \"externalSlotProps\", \"ownerState\", \"skipResolvingSlotProps\"];\nimport { unstable_useForkRef as useForkRef } from '@mui/utils';\nimport { appendOwnerState } from './appendOwnerState';\nimport { mergeSlotProps } from './mergeSlotProps';\nimport { resolveComponentProps } from './resolveComponentProps';\n/**\n * @ignore - do not document.\n * Builds the props to be passed into the slot of an unstyled component.\n * It merges the internal props of the component with the ones supplied by the user, allowing to customize the behavior.\n * If the slot component is not a host component, it also merges in the `ownerState`.\n *\n * @param parameters.getSlotProps - A function that returns the props to be passed to the slot component.\n */\nexport function useSlotProps(parameters) {\n var _parameters$additiona;\n const {\n elementType,\n externalSlotProps,\n ownerState,\n skipResolvingSlotProps = false\n } = parameters,\n rest = _objectWithoutPropertiesLoose(parameters, _excluded);\n const resolvedComponentsProps = skipResolvingSlotProps ? {} : resolveComponentProps(externalSlotProps, ownerState);\n const {\n props: mergedProps,\n internalRef\n } = mergeSlotProps(_extends({}, rest, {\n externalSlotProps: resolvedComponentsProps\n }));\n const ref = useForkRef(internalRef, resolvedComponentsProps == null ? void 0 : resolvedComponentsProps.ref, (_parameters$additiona = parameters.additionalProps) == null ? void 0 : _parameters$additiona.ref);\n const props = appendOwnerState(elementType, _extends({}, mergedProps, {\n ref\n }), ownerState);\n return props;\n}","import { globalStateClasses } from '@mui/utils/generateUtilityClass';\nconst GLOBAL_CLASS_PREFIX = 'base';\nfunction buildStateClass(state) {\n return `${GLOBAL_CLASS_PREFIX}--${state}`;\n}\nfunction buildSlotClass(componentName, slot) {\n return `${GLOBAL_CLASS_PREFIX}-${componentName}-${slot}`;\n}\nexport function generateUtilityClass(componentName, slot) {\n const globalStateClass = globalStateClasses[slot];\n return globalStateClass ? buildStateClass(globalStateClass) : buildSlotClass(componentName, slot);\n}\nexport function isGlobalState(slot) {\n return globalStateClasses[slot] !== undefined;\n}","import { generateUtilityClass } from '../generateUtilityClass';\nexport function generateUtilityClasses(componentName, slots) {\n const result = {};\n slots.forEach(slot => {\n result[slot] = generateUtilityClass(componentName, slot);\n });\n return result;\n}","'use client';\n\nimport * as React from 'react';\nimport * as ReactDOM from 'react-dom';\nimport PropTypes from 'prop-types';\nimport { exactProp, HTMLElementType, unstable_useEnhancedEffect as useEnhancedEffect, unstable_useForkRef as useForkRef, unstable_setRef as setRef } from '@mui/utils';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nfunction getContainer(container) {\n return typeof container === 'function' ? container() : container;\n}\n\n/**\n * Portals provide a first-class way to render children into a DOM node\n * that exists outside the DOM hierarchy of the parent component.\n *\n * Demos:\n *\n * - [Portal](https://mui.com/base-ui/react-portal/)\n *\n * API:\n *\n * - [Portal API](https://mui.com/base-ui/react-portal/components-api/#portal)\n */\nconst Portal = /*#__PURE__*/React.forwardRef(function Portal(props, forwardedRef) {\n const {\n children,\n container,\n disablePortal = false\n } = props;\n const [mountNode, setMountNode] = React.useState(null);\n // @ts-expect-error TODO upstream fix\n const handleRef = useForkRef( /*#__PURE__*/React.isValidElement(children) ? children.ref : null, forwardedRef);\n useEnhancedEffect(() => {\n if (!disablePortal) {\n setMountNode(getContainer(container) || document.body);\n }\n }, [container, disablePortal]);\n useEnhancedEffect(() => {\n if (mountNode && !disablePortal) {\n setRef(forwardedRef, mountNode);\n return () => {\n setRef(forwardedRef, null);\n };\n }\n return undefined;\n }, [forwardedRef, mountNode, disablePortal]);\n if (disablePortal) {\n if ( /*#__PURE__*/React.isValidElement(children)) {\n const newProps = {\n ref: handleRef\n };\n return /*#__PURE__*/React.cloneElement(children, newProps);\n }\n return /*#__PURE__*/_jsx(React.Fragment, {\n children: children\n });\n }\n return /*#__PURE__*/_jsx(React.Fragment, {\n children: mountNode ? /*#__PURE__*/ReactDOM.createPortal(children, mountNode) : mountNode\n });\n});\nprocess.env.NODE_ENV !== \"production\" ? Portal.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * The children to render into the `container`.\n */\n children: PropTypes.node,\n /**\n * An HTML element or function that returns one.\n * The `container` will have the portal children appended to it.\n *\n * You can also provide a callback, which is called in a React layout effect.\n * This lets you set the container from a ref, and also makes server-side rendering possible.\n *\n * By default, it uses the body of the top-level document object,\n * so it's simply `document.body` most of the time.\n */\n container: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.func]),\n /**\n * The `children` will be under the DOM hierarchy of the parent component.\n * @default false\n */\n disablePortal: PropTypes.bool\n} : void 0;\nif (process.env.NODE_ENV !== 'production') {\n // eslint-disable-next-line\n Portal['propTypes' + ''] = exactProp(Portal.propTypes);\n}\nexport { Portal };","export var top = 'top';\nexport var bottom = 'bottom';\nexport var right = 'right';\nexport var left = 'left';\nexport var auto = 'auto';\nexport var basePlacements = [top, bottom, right, left];\nexport var start = 'start';\nexport var end = 'end';\nexport var clippingParents = 'clippingParents';\nexport var viewport = 'viewport';\nexport var popper = 'popper';\nexport var reference = 'reference';\nexport var variationPlacements = /*#__PURE__*/basePlacements.reduce(function (acc, placement) {\n return acc.concat([placement + \"-\" + start, placement + \"-\" + end]);\n}, []);\nexport var placements = /*#__PURE__*/[].concat(basePlacements, [auto]).reduce(function (acc, placement) {\n return acc.concat([placement, placement + \"-\" + start, placement + \"-\" + end]);\n}, []); // modifiers that need to read the DOM\n\nexport var beforeRead = 'beforeRead';\nexport var read = 'read';\nexport var afterRead = 'afterRead'; // pure-logic modifiers\n\nexport var beforeMain = 'beforeMain';\nexport var main = 'main';\nexport var afterMain = 'afterMain'; // modifier with the purpose to write to the DOM (or write into a framework state)\n\nexport var beforeWrite = 'beforeWrite';\nexport var write = 'write';\nexport var afterWrite = 'afterWrite';\nexport var modifierPhases = [beforeRead, read, afterRead, beforeMain, main, afterMain, beforeWrite, write, afterWrite];","export default function getNodeName(element) {\n return element ? (element.nodeName || '').toLowerCase() : null;\n}","export default function getWindow(node) {\n if (node == null) {\n return window;\n }\n\n if (node.toString() !== '[object Window]') {\n var ownerDocument = node.ownerDocument;\n return ownerDocument ? ownerDocument.defaultView || window : window;\n }\n\n return node;\n}","import getWindow from \"./getWindow.js\";\n\nfunction isElement(node) {\n var OwnElement = getWindow(node).Element;\n return node instanceof OwnElement || node instanceof Element;\n}\n\nfunction isHTMLElement(node) {\n var OwnElement = getWindow(node).HTMLElement;\n return node instanceof OwnElement || node instanceof HTMLElement;\n}\n\nfunction isShadowRoot(node) {\n // IE 11 has no ShadowRoot\n if (typeof ShadowRoot === 'undefined') {\n return false;\n }\n\n var OwnElement = getWindow(node).ShadowRoot;\n return node instanceof OwnElement || node instanceof ShadowRoot;\n}\n\nexport { isElement, isHTMLElement, isShadowRoot };","import getNodeName from \"../dom-utils/getNodeName.js\";\nimport { isHTMLElement } from \"../dom-utils/instanceOf.js\"; // This modifier takes the styles prepared by the `computeStyles` modifier\n// and applies them to the HTMLElements such as popper and arrow\n\nfunction applyStyles(_ref) {\n var state = _ref.state;\n Object.keys(state.elements).forEach(function (name) {\n var style = state.styles[name] || {};\n var attributes = state.attributes[name] || {};\n var element = state.elements[name]; // arrow is optional + virtual elements\n\n if (!isHTMLElement(element) || !getNodeName(element)) {\n return;\n } // Flow doesn't support to extend this property, but it's the most\n // effective way to apply styles to an HTMLElement\n // $FlowFixMe[cannot-write]\n\n\n Object.assign(element.style, style);\n Object.keys(attributes).forEach(function (name) {\n var value = attributes[name];\n\n if (value === false) {\n element.removeAttribute(name);\n } else {\n element.setAttribute(name, value === true ? '' : value);\n }\n });\n });\n}\n\nfunction effect(_ref2) {\n var state = _ref2.state;\n var initialStyles = {\n popper: {\n position: state.options.strategy,\n left: '0',\n top: '0',\n margin: '0'\n },\n arrow: {\n position: 'absolute'\n },\n reference: {}\n };\n Object.assign(state.elements.popper.style, initialStyles.popper);\n state.styles = initialStyles;\n\n if (state.elements.arrow) {\n Object.assign(state.elements.arrow.style, initialStyles.arrow);\n }\n\n return function () {\n Object.keys(state.elements).forEach(function (name) {\n var element = state.elements[name];\n var attributes = state.attributes[name] || {};\n var styleProperties = Object.keys(state.styles.hasOwnProperty(name) ? state.styles[name] : initialStyles[name]); // Set all values to an empty string to unset them\n\n var style = styleProperties.reduce(function (style, property) {\n style[property] = '';\n return style;\n }, {}); // arrow is optional + virtual elements\n\n if (!isHTMLElement(element) || !getNodeName(element)) {\n return;\n }\n\n Object.assign(element.style, style);\n Object.keys(attributes).forEach(function (attribute) {\n element.removeAttribute(attribute);\n });\n });\n };\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'applyStyles',\n enabled: true,\n phase: 'write',\n fn: applyStyles,\n effect: effect,\n requires: ['computeStyles']\n};","import { auto } from \"../enums.js\";\nexport default function getBasePlacement(placement) {\n return placement.split('-')[0];\n}","export var max = Math.max;\nexport var min = Math.min;\nexport var round = Math.round;","export default function getUAString() {\n var uaData = navigator.userAgentData;\n\n if (uaData != null && uaData.brands && Array.isArray(uaData.brands)) {\n return uaData.brands.map(function (item) {\n return item.brand + \"/\" + item.version;\n }).join(' ');\n }\n\n return navigator.userAgent;\n}","import getUAString from \"../utils/userAgent.js\";\nexport default function isLayoutViewport() {\n return !/^((?!chrome|android).)*safari/i.test(getUAString());\n}","import { isElement, isHTMLElement } from \"./instanceOf.js\";\nimport { round } from \"../utils/math.js\";\nimport getWindow from \"./getWindow.js\";\nimport isLayoutViewport from \"./isLayoutViewport.js\";\nexport default function getBoundingClientRect(element, includeScale, isFixedStrategy) {\n if (includeScale === void 0) {\n includeScale = false;\n }\n\n if (isFixedStrategy === void 0) {\n isFixedStrategy = false;\n }\n\n var clientRect = element.getBoundingClientRect();\n var scaleX = 1;\n var scaleY = 1;\n\n if (includeScale && isHTMLElement(element)) {\n scaleX = element.offsetWidth > 0 ? round(clientRect.width) / element.offsetWidth || 1 : 1;\n scaleY = element.offsetHeight > 0 ? round(clientRect.height) / element.offsetHeight || 1 : 1;\n }\n\n var _ref = isElement(element) ? getWindow(element) : window,\n visualViewport = _ref.visualViewport;\n\n var addVisualOffsets = !isLayoutViewport() && isFixedStrategy;\n var x = (clientRect.left + (addVisualOffsets && visualViewport ? visualViewport.offsetLeft : 0)) / scaleX;\n var y = (clientRect.top + (addVisualOffsets && visualViewport ? visualViewport.offsetTop : 0)) / scaleY;\n var width = clientRect.width / scaleX;\n var height = clientRect.height / scaleY;\n return {\n width: width,\n height: height,\n top: y,\n right: x + width,\n bottom: y + height,\n left: x,\n x: x,\n y: y\n };\n}","import getBoundingClientRect from \"./getBoundingClientRect.js\"; // Returns the layout rect of an element relative to its offsetParent. Layout\n// means it doesn't take into account transforms.\n\nexport default function getLayoutRect(element) {\n var clientRect = getBoundingClientRect(element); // Use the clientRect sizes if it's not been transformed.\n // Fixes https://github.com/popperjs/popper-core/issues/1223\n\n var width = element.offsetWidth;\n var height = element.offsetHeight;\n\n if (Math.abs(clientRect.width - width) <= 1) {\n width = clientRect.width;\n }\n\n if (Math.abs(clientRect.height - height) <= 1) {\n height = clientRect.height;\n }\n\n return {\n x: element.offsetLeft,\n y: element.offsetTop,\n width: width,\n height: height\n };\n}","import { isShadowRoot } from \"./instanceOf.js\";\nexport default function contains(parent, child) {\n var rootNode = child.getRootNode && child.getRootNode(); // First, attempt with faster native method\n\n if (parent.contains(child)) {\n return true;\n } // then fallback to custom implementation with Shadow DOM support\n else if (rootNode && isShadowRoot(rootNode)) {\n var next = child;\n\n do {\n if (next && parent.isSameNode(next)) {\n return true;\n } // $FlowFixMe[prop-missing]: need a better way to handle this...\n\n\n next = next.parentNode || next.host;\n } while (next);\n } // Give up, the result is false\n\n\n return false;\n}","import getWindow from \"./getWindow.js\";\nexport default function getComputedStyle(element) {\n return getWindow(element).getComputedStyle(element);\n}","import getNodeName from \"./getNodeName.js\";\nexport default function isTableElement(element) {\n return ['table', 'td', 'th'].indexOf(getNodeName(element)) >= 0;\n}","import { isElement } from \"./instanceOf.js\";\nexport default function getDocumentElement(element) {\n // $FlowFixMe[incompatible-return]: assume body is always available\n return ((isElement(element) ? element.ownerDocument : // $FlowFixMe[prop-missing]\n element.document) || window.document).documentElement;\n}","import getNodeName from \"./getNodeName.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport { isShadowRoot } from \"./instanceOf.js\";\nexport default function getParentNode(element) {\n if (getNodeName(element) === 'html') {\n return element;\n }\n\n return (// this is a quicker (but less type safe) way to save quite some bytes from the bundle\n // $FlowFixMe[incompatible-return]\n // $FlowFixMe[prop-missing]\n element.assignedSlot || // step into the shadow DOM of the parent of a slotted node\n element.parentNode || ( // DOM Element detected\n isShadowRoot(element) ? element.host : null) || // ShadowRoot detected\n // $FlowFixMe[incompatible-call]: HTMLElement is a Node\n getDocumentElement(element) // fallback\n\n );\n}","import getWindow from \"./getWindow.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport getComputedStyle from \"./getComputedStyle.js\";\nimport { isHTMLElement, isShadowRoot } from \"./instanceOf.js\";\nimport isTableElement from \"./isTableElement.js\";\nimport getParentNode from \"./getParentNode.js\";\nimport getUAString from \"../utils/userAgent.js\";\n\nfunction getTrueOffsetParent(element) {\n if (!isHTMLElement(element) || // https://github.com/popperjs/popper-core/issues/837\n getComputedStyle(element).position === 'fixed') {\n return null;\n }\n\n return element.offsetParent;\n} // `.offsetParent` reports `null` for fixed elements, while absolute elements\n// return the containing block\n\n\nfunction getContainingBlock(element) {\n var isFirefox = /firefox/i.test(getUAString());\n var isIE = /Trident/i.test(getUAString());\n\n if (isIE && isHTMLElement(element)) {\n // In IE 9, 10 and 11 fixed elements containing block is always established by the viewport\n var elementCss = getComputedStyle(element);\n\n if (elementCss.position === 'fixed') {\n return null;\n }\n }\n\n var currentNode = getParentNode(element);\n\n if (isShadowRoot(currentNode)) {\n currentNode = currentNode.host;\n }\n\n while (isHTMLElement(currentNode) && ['html', 'body'].indexOf(getNodeName(currentNode)) < 0) {\n var css = getComputedStyle(currentNode); // This is non-exhaustive but covers the most common CSS properties that\n // create a containing block.\n // https://developer.mozilla.org/en-US/docs/Web/CSS/Containing_block#identifying_the_containing_block\n\n if (css.transform !== 'none' || css.perspective !== 'none' || css.contain === 'paint' || ['transform', 'perspective'].indexOf(css.willChange) !== -1 || isFirefox && css.willChange === 'filter' || isFirefox && css.filter && css.filter !== 'none') {\n return currentNode;\n } else {\n currentNode = currentNode.parentNode;\n }\n }\n\n return null;\n} // Gets the closest ancestor positioned element. Handles some edge cases,\n// such as table ancestors and cross browser bugs.\n\n\nexport default function getOffsetParent(element) {\n var window = getWindow(element);\n var offsetParent = getTrueOffsetParent(element);\n\n while (offsetParent && isTableElement(offsetParent) && getComputedStyle(offsetParent).position === 'static') {\n offsetParent = getTrueOffsetParent(offsetParent);\n }\n\n if (offsetParent && (getNodeName(offsetParent) === 'html' || getNodeName(offsetParent) === 'body' && getComputedStyle(offsetParent).position === 'static')) {\n return window;\n }\n\n return offsetParent || getContainingBlock(element) || window;\n}","export default function getMainAxisFromPlacement(placement) {\n return ['top', 'bottom'].indexOf(placement) >= 0 ? 'x' : 'y';\n}","import { max as mathMax, min as mathMin } from \"./math.js\";\nexport function within(min, value, max) {\n return mathMax(min, mathMin(value, max));\n}\nexport function withinMaxClamp(min, value, max) {\n var v = within(min, value, max);\n return v > max ? max : v;\n}","export default function getFreshSideObject() {\n return {\n top: 0,\n right: 0,\n bottom: 0,\n left: 0\n };\n}","import getFreshSideObject from \"./getFreshSideObject.js\";\nexport default function mergePaddingObject(paddingObject) {\n return Object.assign({}, getFreshSideObject(), paddingObject);\n}","export default function expandToHashMap(value, keys) {\n return keys.reduce(function (hashMap, key) {\n hashMap[key] = value;\n return hashMap;\n }, {});\n}","import getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getLayoutRect from \"../dom-utils/getLayoutRect.js\";\nimport contains from \"../dom-utils/contains.js\";\nimport getOffsetParent from \"../dom-utils/getOffsetParent.js\";\nimport getMainAxisFromPlacement from \"../utils/getMainAxisFromPlacement.js\";\nimport { within } from \"../utils/within.js\";\nimport mergePaddingObject from \"../utils/mergePaddingObject.js\";\nimport expandToHashMap from \"../utils/expandToHashMap.js\";\nimport { left, right, basePlacements, top, bottom } from \"../enums.js\"; // eslint-disable-next-line import/no-unused-modules\n\nvar toPaddingObject = function toPaddingObject(padding, state) {\n padding = typeof padding === 'function' ? padding(Object.assign({}, state.rects, {\n placement: state.placement\n })) : padding;\n return mergePaddingObject(typeof padding !== 'number' ? padding : expandToHashMap(padding, basePlacements));\n};\n\nfunction arrow(_ref) {\n var _state$modifiersData$;\n\n var state = _ref.state,\n name = _ref.name,\n options = _ref.options;\n var arrowElement = state.elements.arrow;\n var popperOffsets = state.modifiersData.popperOffsets;\n var basePlacement = getBasePlacement(state.placement);\n var axis = getMainAxisFromPlacement(basePlacement);\n var isVertical = [left, right].indexOf(basePlacement) >= 0;\n var len = isVertical ? 'height' : 'width';\n\n if (!arrowElement || !popperOffsets) {\n return;\n }\n\n var paddingObject = toPaddingObject(options.padding, state);\n var arrowRect = getLayoutRect(arrowElement);\n var minProp = axis === 'y' ? top : left;\n var maxProp = axis === 'y' ? bottom : right;\n var endDiff = state.rects.reference[len] + state.rects.reference[axis] - popperOffsets[axis] - state.rects.popper[len];\n var startDiff = popperOffsets[axis] - state.rects.reference[axis];\n var arrowOffsetParent = getOffsetParent(arrowElement);\n var clientSize = arrowOffsetParent ? axis === 'y' ? arrowOffsetParent.clientHeight || 0 : arrowOffsetParent.clientWidth || 0 : 0;\n var centerToReference = endDiff / 2 - startDiff / 2; // Make sure the arrow doesn't overflow the popper if the center point is\n // outside of the popper bounds\n\n var min = paddingObject[minProp];\n var max = clientSize - arrowRect[len] - paddingObject[maxProp];\n var center = clientSize / 2 - arrowRect[len] / 2 + centerToReference;\n var offset = within(min, center, max); // Prevents breaking syntax highlighting...\n\n var axisProp = axis;\n state.modifiersData[name] = (_state$modifiersData$ = {}, _state$modifiersData$[axisProp] = offset, _state$modifiersData$.centerOffset = offset - center, _state$modifiersData$);\n}\n\nfunction effect(_ref2) {\n var state = _ref2.state,\n options = _ref2.options;\n var _options$element = options.element,\n arrowElement = _options$element === void 0 ? '[data-popper-arrow]' : _options$element;\n\n if (arrowElement == null) {\n return;\n } // CSS selector\n\n\n if (typeof arrowElement === 'string') {\n arrowElement = state.elements.popper.querySelector(arrowElement);\n\n if (!arrowElement) {\n return;\n }\n }\n\n if (!contains(state.elements.popper, arrowElement)) {\n return;\n }\n\n state.elements.arrow = arrowElement;\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'arrow',\n enabled: true,\n phase: 'main',\n fn: arrow,\n effect: effect,\n requires: ['popperOffsets'],\n requiresIfExists: ['preventOverflow']\n};","export default function getVariation(placement) {\n return placement.split('-')[1];\n}","import { top, left, right, bottom, end } from \"../enums.js\";\nimport getOffsetParent from \"../dom-utils/getOffsetParent.js\";\nimport getWindow from \"../dom-utils/getWindow.js\";\nimport getDocumentElement from \"../dom-utils/getDocumentElement.js\";\nimport getComputedStyle from \"../dom-utils/getComputedStyle.js\";\nimport getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getVariation from \"../utils/getVariation.js\";\nimport { round } from \"../utils/math.js\"; // eslint-disable-next-line import/no-unused-modules\n\nvar unsetSides = {\n top: 'auto',\n right: 'auto',\n bottom: 'auto',\n left: 'auto'\n}; // Round the offsets to the nearest suitable subpixel based on the DPR.\n// Zooming can change the DPR, but it seems to report a value that will\n// cleanly divide the values into the appropriate subpixels.\n\nfunction roundOffsetsByDPR(_ref, win) {\n var x = _ref.x,\n y = _ref.y;\n var dpr = win.devicePixelRatio || 1;\n return {\n x: round(x * dpr) / dpr || 0,\n y: round(y * dpr) / dpr || 0\n };\n}\n\nexport function mapToStyles(_ref2) {\n var _Object$assign2;\n\n var popper = _ref2.popper,\n popperRect = _ref2.popperRect,\n placement = _ref2.placement,\n variation = _ref2.variation,\n offsets = _ref2.offsets,\n position = _ref2.position,\n gpuAcceleration = _ref2.gpuAcceleration,\n adaptive = _ref2.adaptive,\n roundOffsets = _ref2.roundOffsets,\n isFixed = _ref2.isFixed;\n var _offsets$x = offsets.x,\n x = _offsets$x === void 0 ? 0 : _offsets$x,\n _offsets$y = offsets.y,\n y = _offsets$y === void 0 ? 0 : _offsets$y;\n\n var _ref3 = typeof roundOffsets === 'function' ? roundOffsets({\n x: x,\n y: y\n }) : {\n x: x,\n y: y\n };\n\n x = _ref3.x;\n y = _ref3.y;\n var hasX = offsets.hasOwnProperty('x');\n var hasY = offsets.hasOwnProperty('y');\n var sideX = left;\n var sideY = top;\n var win = window;\n\n if (adaptive) {\n var offsetParent = getOffsetParent(popper);\n var heightProp = 'clientHeight';\n var widthProp = 'clientWidth';\n\n if (offsetParent === getWindow(popper)) {\n offsetParent = getDocumentElement(popper);\n\n if (getComputedStyle(offsetParent).position !== 'static' && position === 'absolute') {\n heightProp = 'scrollHeight';\n widthProp = 'scrollWidth';\n }\n } // $FlowFixMe[incompatible-cast]: force type refinement, we compare offsetParent with window above, but Flow doesn't detect it\n\n\n offsetParent = offsetParent;\n\n if (placement === top || (placement === left || placement === right) && variation === end) {\n sideY = bottom;\n var offsetY = isFixed && offsetParent === win && win.visualViewport ? win.visualViewport.height : // $FlowFixMe[prop-missing]\n offsetParent[heightProp];\n y -= offsetY - popperRect.height;\n y *= gpuAcceleration ? 1 : -1;\n }\n\n if (placement === left || (placement === top || placement === bottom) && variation === end) {\n sideX = right;\n var offsetX = isFixed && offsetParent === win && win.visualViewport ? win.visualViewport.width : // $FlowFixMe[prop-missing]\n offsetParent[widthProp];\n x -= offsetX - popperRect.width;\n x *= gpuAcceleration ? 1 : -1;\n }\n }\n\n var commonStyles = Object.assign({\n position: position\n }, adaptive && unsetSides);\n\n var _ref4 = roundOffsets === true ? roundOffsetsByDPR({\n x: x,\n y: y\n }, getWindow(popper)) : {\n x: x,\n y: y\n };\n\n x = _ref4.x;\n y = _ref4.y;\n\n if (gpuAcceleration) {\n var _Object$assign;\n\n return Object.assign({}, commonStyles, (_Object$assign = {}, _Object$assign[sideY] = hasY ? '0' : '', _Object$assign[sideX] = hasX ? '0' : '', _Object$assign.transform = (win.devicePixelRatio || 1) <= 1 ? \"translate(\" + x + \"px, \" + y + \"px)\" : \"translate3d(\" + x + \"px, \" + y + \"px, 0)\", _Object$assign));\n }\n\n return Object.assign({}, commonStyles, (_Object$assign2 = {}, _Object$assign2[sideY] = hasY ? y + \"px\" : '', _Object$assign2[sideX] = hasX ? x + \"px\" : '', _Object$assign2.transform = '', _Object$assign2));\n}\n\nfunction computeStyles(_ref5) {\n var state = _ref5.state,\n options = _ref5.options;\n var _options$gpuAccelerat = options.gpuAcceleration,\n gpuAcceleration = _options$gpuAccelerat === void 0 ? true : _options$gpuAccelerat,\n _options$adaptive = options.adaptive,\n adaptive = _options$adaptive === void 0 ? true : _options$adaptive,\n _options$roundOffsets = options.roundOffsets,\n roundOffsets = _options$roundOffsets === void 0 ? true : _options$roundOffsets;\n var commonStyles = {\n placement: getBasePlacement(state.placement),\n variation: getVariation(state.placement),\n popper: state.elements.popper,\n popperRect: state.rects.popper,\n gpuAcceleration: gpuAcceleration,\n isFixed: state.options.strategy === 'fixed'\n };\n\n if (state.modifiersData.popperOffsets != null) {\n state.styles.popper = Object.assign({}, state.styles.popper, mapToStyles(Object.assign({}, commonStyles, {\n offsets: state.modifiersData.popperOffsets,\n position: state.options.strategy,\n adaptive: adaptive,\n roundOffsets: roundOffsets\n })));\n }\n\n if (state.modifiersData.arrow != null) {\n state.styles.arrow = Object.assign({}, state.styles.arrow, mapToStyles(Object.assign({}, commonStyles, {\n offsets: state.modifiersData.arrow,\n position: 'absolute',\n adaptive: false,\n roundOffsets: roundOffsets\n })));\n }\n\n state.attributes.popper = Object.assign({}, state.attributes.popper, {\n 'data-popper-placement': state.placement\n });\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'computeStyles',\n enabled: true,\n phase: 'beforeWrite',\n fn: computeStyles,\n data: {}\n};","import getWindow from \"../dom-utils/getWindow.js\"; // eslint-disable-next-line import/no-unused-modules\n\nvar passive = {\n passive: true\n};\n\nfunction effect(_ref) {\n var state = _ref.state,\n instance = _ref.instance,\n options = _ref.options;\n var _options$scroll = options.scroll,\n scroll = _options$scroll === void 0 ? true : _options$scroll,\n _options$resize = options.resize,\n resize = _options$resize === void 0 ? true : _options$resize;\n var window = getWindow(state.elements.popper);\n var scrollParents = [].concat(state.scrollParents.reference, state.scrollParents.popper);\n\n if (scroll) {\n scrollParents.forEach(function (scrollParent) {\n scrollParent.addEventListener('scroll', instance.update, passive);\n });\n }\n\n if (resize) {\n window.addEventListener('resize', instance.update, passive);\n }\n\n return function () {\n if (scroll) {\n scrollParents.forEach(function (scrollParent) {\n scrollParent.removeEventListener('scroll', instance.update, passive);\n });\n }\n\n if (resize) {\n window.removeEventListener('resize', instance.update, passive);\n }\n };\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'eventListeners',\n enabled: true,\n phase: 'write',\n fn: function fn() {},\n effect: effect,\n data: {}\n};","var hash = {\n left: 'right',\n right: 'left',\n bottom: 'top',\n top: 'bottom'\n};\nexport default function getOppositePlacement(placement) {\n return placement.replace(/left|right|bottom|top/g, function (matched) {\n return hash[matched];\n });\n}","var hash = {\n start: 'end',\n end: 'start'\n};\nexport default function getOppositeVariationPlacement(placement) {\n return placement.replace(/start|end/g, function (matched) {\n return hash[matched];\n });\n}","import getWindow from \"./getWindow.js\";\nexport default function getWindowScroll(node) {\n var win = getWindow(node);\n var scrollLeft = win.pageXOffset;\n var scrollTop = win.pageYOffset;\n return {\n scrollLeft: scrollLeft,\n scrollTop: scrollTop\n };\n}","import getBoundingClientRect from \"./getBoundingClientRect.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport getWindowScroll from \"./getWindowScroll.js\";\nexport default function getWindowScrollBarX(element) {\n // If has a CSS width greater than the viewport, then this will be\n // incorrect for RTL.\n // Popper 1 is broken in this case and never had a bug report so let's assume\n // it's not an issue. I don't think anyone ever specifies width on \n // anyway.\n // Browsers where the left scrollbar doesn't cause an issue report `0` for\n // this (e.g. Edge 2019, IE11, Safari)\n return getBoundingClientRect(getDocumentElement(element)).left + getWindowScroll(element).scrollLeft;\n}","import getWindow from \"./getWindow.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport getWindowScrollBarX from \"./getWindowScrollBarX.js\";\nimport isLayoutViewport from \"./isLayoutViewport.js\";\nexport default function getViewportRect(element, strategy) {\n var win = getWindow(element);\n var html = getDocumentElement(element);\n var visualViewport = win.visualViewport;\n var width = html.clientWidth;\n var height = html.clientHeight;\n var x = 0;\n var y = 0;\n\n if (visualViewport) {\n width = visualViewport.width;\n height = visualViewport.height;\n var layoutViewport = isLayoutViewport();\n\n if (layoutViewport || !layoutViewport && strategy === 'fixed') {\n x = visualViewport.offsetLeft;\n y = visualViewport.offsetTop;\n }\n }\n\n return {\n width: width,\n height: height,\n x: x + getWindowScrollBarX(element),\n y: y\n };\n}","import getDocumentElement from \"./getDocumentElement.js\";\nimport getComputedStyle from \"./getComputedStyle.js\";\nimport getWindowScrollBarX from \"./getWindowScrollBarX.js\";\nimport getWindowScroll from \"./getWindowScroll.js\";\nimport { max } from \"../utils/math.js\"; // Gets the entire size of the scrollable document area, even extending outside\n// of the `` and `` rect bounds if horizontally scrollable\n\nexport default function getDocumentRect(element) {\n var _element$ownerDocumen;\n\n var html = getDocumentElement(element);\n var winScroll = getWindowScroll(element);\n var body = (_element$ownerDocumen = element.ownerDocument) == null ? void 0 : _element$ownerDocumen.body;\n var width = max(html.scrollWidth, html.clientWidth, body ? body.scrollWidth : 0, body ? body.clientWidth : 0);\n var height = max(html.scrollHeight, html.clientHeight, body ? body.scrollHeight : 0, body ? body.clientHeight : 0);\n var x = -winScroll.scrollLeft + getWindowScrollBarX(element);\n var y = -winScroll.scrollTop;\n\n if (getComputedStyle(body || html).direction === 'rtl') {\n x += max(html.clientWidth, body ? body.clientWidth : 0) - width;\n }\n\n return {\n width: width,\n height: height,\n x: x,\n y: y\n };\n}","import getComputedStyle from \"./getComputedStyle.js\";\nexport default function isScrollParent(element) {\n // Firefox wants us to check `-x` and `-y` variations as well\n var _getComputedStyle = getComputedStyle(element),\n overflow = _getComputedStyle.overflow,\n overflowX = _getComputedStyle.overflowX,\n overflowY = _getComputedStyle.overflowY;\n\n return /auto|scroll|overlay|hidden/.test(overflow + overflowY + overflowX);\n}","import getParentNode from \"./getParentNode.js\";\nimport isScrollParent from \"./isScrollParent.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport { isHTMLElement } from \"./instanceOf.js\";\nexport default function getScrollParent(node) {\n if (['html', 'body', '#document'].indexOf(getNodeName(node)) >= 0) {\n // $FlowFixMe[incompatible-return]: assume body is always available\n return node.ownerDocument.body;\n }\n\n if (isHTMLElement(node) && isScrollParent(node)) {\n return node;\n }\n\n return getScrollParent(getParentNode(node));\n}","import getScrollParent from \"./getScrollParent.js\";\nimport getParentNode from \"./getParentNode.js\";\nimport getWindow from \"./getWindow.js\";\nimport isScrollParent from \"./isScrollParent.js\";\n/*\ngiven a DOM element, return the list of all scroll parents, up the list of ancesors\nuntil we get to the top window object. This list is what we attach scroll listeners\nto, because if any of these parent elements scroll, we'll need to re-calculate the\nreference element's position.\n*/\n\nexport default function listScrollParents(element, list) {\n var _element$ownerDocumen;\n\n if (list === void 0) {\n list = [];\n }\n\n var scrollParent = getScrollParent(element);\n var isBody = scrollParent === ((_element$ownerDocumen = element.ownerDocument) == null ? void 0 : _element$ownerDocumen.body);\n var win = getWindow(scrollParent);\n var target = isBody ? [win].concat(win.visualViewport || [], isScrollParent(scrollParent) ? scrollParent : []) : scrollParent;\n var updatedList = list.concat(target);\n return isBody ? updatedList : // $FlowFixMe[incompatible-call]: isBody tells us target will be an HTMLElement here\n updatedList.concat(listScrollParents(getParentNode(target)));\n}","export default function rectToClientRect(rect) {\n return Object.assign({}, rect, {\n left: rect.x,\n top: rect.y,\n right: rect.x + rect.width,\n bottom: rect.y + rect.height\n });\n}","import { viewport } from \"../enums.js\";\nimport getViewportRect from \"./getViewportRect.js\";\nimport getDocumentRect from \"./getDocumentRect.js\";\nimport listScrollParents from \"./listScrollParents.js\";\nimport getOffsetParent from \"./getOffsetParent.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport getComputedStyle from \"./getComputedStyle.js\";\nimport { isElement, isHTMLElement } from \"./instanceOf.js\";\nimport getBoundingClientRect from \"./getBoundingClientRect.js\";\nimport getParentNode from \"./getParentNode.js\";\nimport contains from \"./contains.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport rectToClientRect from \"../utils/rectToClientRect.js\";\nimport { max, min } from \"../utils/math.js\";\n\nfunction getInnerBoundingClientRect(element, strategy) {\n var rect = getBoundingClientRect(element, false, strategy === 'fixed');\n rect.top = rect.top + element.clientTop;\n rect.left = rect.left + element.clientLeft;\n rect.bottom = rect.top + element.clientHeight;\n rect.right = rect.left + element.clientWidth;\n rect.width = element.clientWidth;\n rect.height = element.clientHeight;\n rect.x = rect.left;\n rect.y = rect.top;\n return rect;\n}\n\nfunction getClientRectFromMixedType(element, clippingParent, strategy) {\n return clippingParent === viewport ? rectToClientRect(getViewportRect(element, strategy)) : isElement(clippingParent) ? getInnerBoundingClientRect(clippingParent, strategy) : rectToClientRect(getDocumentRect(getDocumentElement(element)));\n} // A \"clipping parent\" is an overflowable container with the characteristic of\n// clipping (or hiding) overflowing elements with a position different from\n// `initial`\n\n\nfunction getClippingParents(element) {\n var clippingParents = listScrollParents(getParentNode(element));\n var canEscapeClipping = ['absolute', 'fixed'].indexOf(getComputedStyle(element).position) >= 0;\n var clipperElement = canEscapeClipping && isHTMLElement(element) ? getOffsetParent(element) : element;\n\n if (!isElement(clipperElement)) {\n return [];\n } // $FlowFixMe[incompatible-return]: https://github.com/facebook/flow/issues/1414\n\n\n return clippingParents.filter(function (clippingParent) {\n return isElement(clippingParent) && contains(clippingParent, clipperElement) && getNodeName(clippingParent) !== 'body';\n });\n} // Gets the maximum area that the element is visible in due to any number of\n// clipping parents\n\n\nexport default function getClippingRect(element, boundary, rootBoundary, strategy) {\n var mainClippingParents = boundary === 'clippingParents' ? getClippingParents(element) : [].concat(boundary);\n var clippingParents = [].concat(mainClippingParents, [rootBoundary]);\n var firstClippingParent = clippingParents[0];\n var clippingRect = clippingParents.reduce(function (accRect, clippingParent) {\n var rect = getClientRectFromMixedType(element, clippingParent, strategy);\n accRect.top = max(rect.top, accRect.top);\n accRect.right = min(rect.right, accRect.right);\n accRect.bottom = min(rect.bottom, accRect.bottom);\n accRect.left = max(rect.left, accRect.left);\n return accRect;\n }, getClientRectFromMixedType(element, firstClippingParent, strategy));\n clippingRect.width = clippingRect.right - clippingRect.left;\n clippingRect.height = clippingRect.bottom - clippingRect.top;\n clippingRect.x = clippingRect.left;\n clippingRect.y = clippingRect.top;\n return clippingRect;\n}","import getBasePlacement from \"./getBasePlacement.js\";\nimport getVariation from \"./getVariation.js\";\nimport getMainAxisFromPlacement from \"./getMainAxisFromPlacement.js\";\nimport { top, right, bottom, left, start, end } from \"../enums.js\";\nexport default function computeOffsets(_ref) {\n var reference = _ref.reference,\n element = _ref.element,\n placement = _ref.placement;\n var basePlacement = placement ? getBasePlacement(placement) : null;\n var variation = placement ? getVariation(placement) : null;\n var commonX = reference.x + reference.width / 2 - element.width / 2;\n var commonY = reference.y + reference.height / 2 - element.height / 2;\n var offsets;\n\n switch (basePlacement) {\n case top:\n offsets = {\n x: commonX,\n y: reference.y - element.height\n };\n break;\n\n case bottom:\n offsets = {\n x: commonX,\n y: reference.y + reference.height\n };\n break;\n\n case right:\n offsets = {\n x: reference.x + reference.width,\n y: commonY\n };\n break;\n\n case left:\n offsets = {\n x: reference.x - element.width,\n y: commonY\n };\n break;\n\n default:\n offsets = {\n x: reference.x,\n y: reference.y\n };\n }\n\n var mainAxis = basePlacement ? getMainAxisFromPlacement(basePlacement) : null;\n\n if (mainAxis != null) {\n var len = mainAxis === 'y' ? 'height' : 'width';\n\n switch (variation) {\n case start:\n offsets[mainAxis] = offsets[mainAxis] - (reference[len] / 2 - element[len] / 2);\n break;\n\n case end:\n offsets[mainAxis] = offsets[mainAxis] + (reference[len] / 2 - element[len] / 2);\n break;\n\n default:\n }\n }\n\n return offsets;\n}","import getClippingRect from \"../dom-utils/getClippingRect.js\";\nimport getDocumentElement from \"../dom-utils/getDocumentElement.js\";\nimport getBoundingClientRect from \"../dom-utils/getBoundingClientRect.js\";\nimport computeOffsets from \"./computeOffsets.js\";\nimport rectToClientRect from \"./rectToClientRect.js\";\nimport { clippingParents, reference, popper, bottom, top, right, basePlacements, viewport } from \"../enums.js\";\nimport { isElement } from \"../dom-utils/instanceOf.js\";\nimport mergePaddingObject from \"./mergePaddingObject.js\";\nimport expandToHashMap from \"./expandToHashMap.js\"; // eslint-disable-next-line import/no-unused-modules\n\nexport default function detectOverflow(state, options) {\n if (options === void 0) {\n options = {};\n }\n\n var _options = options,\n _options$placement = _options.placement,\n placement = _options$placement === void 0 ? state.placement : _options$placement,\n _options$strategy = _options.strategy,\n strategy = _options$strategy === void 0 ? state.strategy : _options$strategy,\n _options$boundary = _options.boundary,\n boundary = _options$boundary === void 0 ? clippingParents : _options$boundary,\n _options$rootBoundary = _options.rootBoundary,\n rootBoundary = _options$rootBoundary === void 0 ? viewport : _options$rootBoundary,\n _options$elementConte = _options.elementContext,\n elementContext = _options$elementConte === void 0 ? popper : _options$elementConte,\n _options$altBoundary = _options.altBoundary,\n altBoundary = _options$altBoundary === void 0 ? false : _options$altBoundary,\n _options$padding = _options.padding,\n padding = _options$padding === void 0 ? 0 : _options$padding;\n var paddingObject = mergePaddingObject(typeof padding !== 'number' ? padding : expandToHashMap(padding, basePlacements));\n var altContext = elementContext === popper ? reference : popper;\n var popperRect = state.rects.popper;\n var element = state.elements[altBoundary ? altContext : elementContext];\n var clippingClientRect = getClippingRect(isElement(element) ? element : element.contextElement || getDocumentElement(state.elements.popper), boundary, rootBoundary, strategy);\n var referenceClientRect = getBoundingClientRect(state.elements.reference);\n var popperOffsets = computeOffsets({\n reference: referenceClientRect,\n element: popperRect,\n strategy: 'absolute',\n placement: placement\n });\n var popperClientRect = rectToClientRect(Object.assign({}, popperRect, popperOffsets));\n var elementClientRect = elementContext === popper ? popperClientRect : referenceClientRect; // positive = overflowing the clipping rect\n // 0 or negative = within the clipping rect\n\n var overflowOffsets = {\n top: clippingClientRect.top - elementClientRect.top + paddingObject.top,\n bottom: elementClientRect.bottom - clippingClientRect.bottom + paddingObject.bottom,\n left: clippingClientRect.left - elementClientRect.left + paddingObject.left,\n right: elementClientRect.right - clippingClientRect.right + paddingObject.right\n };\n var offsetData = state.modifiersData.offset; // Offsets can be applied only to the popper element\n\n if (elementContext === popper && offsetData) {\n var offset = offsetData[placement];\n Object.keys(overflowOffsets).forEach(function (key) {\n var multiply = [right, bottom].indexOf(key) >= 0 ? 1 : -1;\n var axis = [top, bottom].indexOf(key) >= 0 ? 'y' : 'x';\n overflowOffsets[key] += offset[axis] * multiply;\n });\n }\n\n return overflowOffsets;\n}","import getVariation from \"./getVariation.js\";\nimport { variationPlacements, basePlacements, placements as allPlacements } from \"../enums.js\";\nimport detectOverflow from \"./detectOverflow.js\";\nimport getBasePlacement from \"./getBasePlacement.js\";\nexport default function computeAutoPlacement(state, options) {\n if (options === void 0) {\n options = {};\n }\n\n var _options = options,\n placement = _options.placement,\n boundary = _options.boundary,\n rootBoundary = _options.rootBoundary,\n padding = _options.padding,\n flipVariations = _options.flipVariations,\n _options$allowedAutoP = _options.allowedAutoPlacements,\n allowedAutoPlacements = _options$allowedAutoP === void 0 ? allPlacements : _options$allowedAutoP;\n var variation = getVariation(placement);\n var placements = variation ? flipVariations ? variationPlacements : variationPlacements.filter(function (placement) {\n return getVariation(placement) === variation;\n }) : basePlacements;\n var allowedPlacements = placements.filter(function (placement) {\n return allowedAutoPlacements.indexOf(placement) >= 0;\n });\n\n if (allowedPlacements.length === 0) {\n allowedPlacements = placements;\n } // $FlowFixMe[incompatible-type]: Flow seems to have problems with two array unions...\n\n\n var overflows = allowedPlacements.reduce(function (acc, placement) {\n acc[placement] = detectOverflow(state, {\n placement: placement,\n boundary: boundary,\n rootBoundary: rootBoundary,\n padding: padding\n })[getBasePlacement(placement)];\n return acc;\n }, {});\n return Object.keys(overflows).sort(function (a, b) {\n return overflows[a] - overflows[b];\n });\n}","import getOppositePlacement from \"../utils/getOppositePlacement.js\";\nimport getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getOppositeVariationPlacement from \"../utils/getOppositeVariationPlacement.js\";\nimport detectOverflow from \"../utils/detectOverflow.js\";\nimport computeAutoPlacement from \"../utils/computeAutoPlacement.js\";\nimport { bottom, top, start, right, left, auto } from \"../enums.js\";\nimport getVariation from \"../utils/getVariation.js\"; // eslint-disable-next-line import/no-unused-modules\n\nfunction getExpandedFallbackPlacements(placement) {\n if (getBasePlacement(placement) === auto) {\n return [];\n }\n\n var oppositePlacement = getOppositePlacement(placement);\n return [getOppositeVariationPlacement(placement), oppositePlacement, getOppositeVariationPlacement(oppositePlacement)];\n}\n\nfunction flip(_ref) {\n var state = _ref.state,\n options = _ref.options,\n name = _ref.name;\n\n if (state.modifiersData[name]._skip) {\n return;\n }\n\n var _options$mainAxis = options.mainAxis,\n checkMainAxis = _options$mainAxis === void 0 ? true : _options$mainAxis,\n _options$altAxis = options.altAxis,\n checkAltAxis = _options$altAxis === void 0 ? true : _options$altAxis,\n specifiedFallbackPlacements = options.fallbackPlacements,\n padding = options.padding,\n boundary = options.boundary,\n rootBoundary = options.rootBoundary,\n altBoundary = options.altBoundary,\n _options$flipVariatio = options.flipVariations,\n flipVariations = _options$flipVariatio === void 0 ? true : _options$flipVariatio,\n allowedAutoPlacements = options.allowedAutoPlacements;\n var preferredPlacement = state.options.placement;\n var basePlacement = getBasePlacement(preferredPlacement);\n var isBasePlacement = basePlacement === preferredPlacement;\n var fallbackPlacements = specifiedFallbackPlacements || (isBasePlacement || !flipVariations ? [getOppositePlacement(preferredPlacement)] : getExpandedFallbackPlacements(preferredPlacement));\n var placements = [preferredPlacement].concat(fallbackPlacements).reduce(function (acc, placement) {\n return acc.concat(getBasePlacement(placement) === auto ? computeAutoPlacement(state, {\n placement: placement,\n boundary: boundary,\n rootBoundary: rootBoundary,\n padding: padding,\n flipVariations: flipVariations,\n allowedAutoPlacements: allowedAutoPlacements\n }) : placement);\n }, []);\n var referenceRect = state.rects.reference;\n var popperRect = state.rects.popper;\n var checksMap = new Map();\n var makeFallbackChecks = true;\n var firstFittingPlacement = placements[0];\n\n for (var i = 0; i < placements.length; i++) {\n var placement = placements[i];\n\n var _basePlacement = getBasePlacement(placement);\n\n var isStartVariation = getVariation(placement) === start;\n var isVertical = [top, bottom].indexOf(_basePlacement) >= 0;\n var len = isVertical ? 'width' : 'height';\n var overflow = detectOverflow(state, {\n placement: placement,\n boundary: boundary,\n rootBoundary: rootBoundary,\n altBoundary: altBoundary,\n padding: padding\n });\n var mainVariationSide = isVertical ? isStartVariation ? right : left : isStartVariation ? bottom : top;\n\n if (referenceRect[len] > popperRect[len]) {\n mainVariationSide = getOppositePlacement(mainVariationSide);\n }\n\n var altVariationSide = getOppositePlacement(mainVariationSide);\n var checks = [];\n\n if (checkMainAxis) {\n checks.push(overflow[_basePlacement] <= 0);\n }\n\n if (checkAltAxis) {\n checks.push(overflow[mainVariationSide] <= 0, overflow[altVariationSide] <= 0);\n }\n\n if (checks.every(function (check) {\n return check;\n })) {\n firstFittingPlacement = placement;\n makeFallbackChecks = false;\n break;\n }\n\n checksMap.set(placement, checks);\n }\n\n if (makeFallbackChecks) {\n // `2` may be desired in some cases – research later\n var numberOfChecks = flipVariations ? 3 : 1;\n\n var _loop = function _loop(_i) {\n var fittingPlacement = placements.find(function (placement) {\n var checks = checksMap.get(placement);\n\n if (checks) {\n return checks.slice(0, _i).every(function (check) {\n return check;\n });\n }\n });\n\n if (fittingPlacement) {\n firstFittingPlacement = fittingPlacement;\n return \"break\";\n }\n };\n\n for (var _i = numberOfChecks; _i > 0; _i--) {\n var _ret = _loop(_i);\n\n if (_ret === \"break\") break;\n }\n }\n\n if (state.placement !== firstFittingPlacement) {\n state.modifiersData[name]._skip = true;\n state.placement = firstFittingPlacement;\n state.reset = true;\n }\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'flip',\n enabled: true,\n phase: 'main',\n fn: flip,\n requiresIfExists: ['offset'],\n data: {\n _skip: false\n }\n};","import { top, bottom, left, right } from \"../enums.js\";\nimport detectOverflow from \"../utils/detectOverflow.js\";\n\nfunction getSideOffsets(overflow, rect, preventedOffsets) {\n if (preventedOffsets === void 0) {\n preventedOffsets = {\n x: 0,\n y: 0\n };\n }\n\n return {\n top: overflow.top - rect.height - preventedOffsets.y,\n right: overflow.right - rect.width + preventedOffsets.x,\n bottom: overflow.bottom - rect.height + preventedOffsets.y,\n left: overflow.left - rect.width - preventedOffsets.x\n };\n}\n\nfunction isAnySideFullyClipped(overflow) {\n return [top, right, bottom, left].some(function (side) {\n return overflow[side] >= 0;\n });\n}\n\nfunction hide(_ref) {\n var state = _ref.state,\n name = _ref.name;\n var referenceRect = state.rects.reference;\n var popperRect = state.rects.popper;\n var preventedOffsets = state.modifiersData.preventOverflow;\n var referenceOverflow = detectOverflow(state, {\n elementContext: 'reference'\n });\n var popperAltOverflow = detectOverflow(state, {\n altBoundary: true\n });\n var referenceClippingOffsets = getSideOffsets(referenceOverflow, referenceRect);\n var popperEscapeOffsets = getSideOffsets(popperAltOverflow, popperRect, preventedOffsets);\n var isReferenceHidden = isAnySideFullyClipped(referenceClippingOffsets);\n var hasPopperEscaped = isAnySideFullyClipped(popperEscapeOffsets);\n state.modifiersData[name] = {\n referenceClippingOffsets: referenceClippingOffsets,\n popperEscapeOffsets: popperEscapeOffsets,\n isReferenceHidden: isReferenceHidden,\n hasPopperEscaped: hasPopperEscaped\n };\n state.attributes.popper = Object.assign({}, state.attributes.popper, {\n 'data-popper-reference-hidden': isReferenceHidden,\n 'data-popper-escaped': hasPopperEscaped\n });\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'hide',\n enabled: true,\n phase: 'main',\n requiresIfExists: ['preventOverflow'],\n fn: hide\n};","import getBasePlacement from \"../utils/getBasePlacement.js\";\nimport { top, left, right, placements } from \"../enums.js\"; // eslint-disable-next-line import/no-unused-modules\n\nexport function distanceAndSkiddingToXY(placement, rects, offset) {\n var basePlacement = getBasePlacement(placement);\n var invertDistance = [left, top].indexOf(basePlacement) >= 0 ? -1 : 1;\n\n var _ref = typeof offset === 'function' ? offset(Object.assign({}, rects, {\n placement: placement\n })) : offset,\n skidding = _ref[0],\n distance = _ref[1];\n\n skidding = skidding || 0;\n distance = (distance || 0) * invertDistance;\n return [left, right].indexOf(basePlacement) >= 0 ? {\n x: distance,\n y: skidding\n } : {\n x: skidding,\n y: distance\n };\n}\n\nfunction offset(_ref2) {\n var state = _ref2.state,\n options = _ref2.options,\n name = _ref2.name;\n var _options$offset = options.offset,\n offset = _options$offset === void 0 ? [0, 0] : _options$offset;\n var data = placements.reduce(function (acc, placement) {\n acc[placement] = distanceAndSkiddingToXY(placement, state.rects, offset);\n return acc;\n }, {});\n var _data$state$placement = data[state.placement],\n x = _data$state$placement.x,\n y = _data$state$placement.y;\n\n if (state.modifiersData.popperOffsets != null) {\n state.modifiersData.popperOffsets.x += x;\n state.modifiersData.popperOffsets.y += y;\n }\n\n state.modifiersData[name] = data;\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'offset',\n enabled: true,\n phase: 'main',\n requires: ['popperOffsets'],\n fn: offset\n};","import computeOffsets from \"../utils/computeOffsets.js\";\n\nfunction popperOffsets(_ref) {\n var state = _ref.state,\n name = _ref.name;\n // Offsets are the actual position the popper needs to have to be\n // properly positioned near its reference element\n // This is the most basic placement, and will be adjusted by\n // the modifiers in the next step\n state.modifiersData[name] = computeOffsets({\n reference: state.rects.reference,\n element: state.rects.popper,\n strategy: 'absolute',\n placement: state.placement\n });\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'popperOffsets',\n enabled: true,\n phase: 'read',\n fn: popperOffsets,\n data: {}\n};","export default function getAltAxis(axis) {\n return axis === 'x' ? 'y' : 'x';\n}","import { top, left, right, bottom, start } from \"../enums.js\";\nimport getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getMainAxisFromPlacement from \"../utils/getMainAxisFromPlacement.js\";\nimport getAltAxis from \"../utils/getAltAxis.js\";\nimport { within, withinMaxClamp } from \"../utils/within.js\";\nimport getLayoutRect from \"../dom-utils/getLayoutRect.js\";\nimport getOffsetParent from \"../dom-utils/getOffsetParent.js\";\nimport detectOverflow from \"../utils/detectOverflow.js\";\nimport getVariation from \"../utils/getVariation.js\";\nimport getFreshSideObject from \"../utils/getFreshSideObject.js\";\nimport { min as mathMin, max as mathMax } from \"../utils/math.js\";\n\nfunction preventOverflow(_ref) {\n var state = _ref.state,\n options = _ref.options,\n name = _ref.name;\n var _options$mainAxis = options.mainAxis,\n checkMainAxis = _options$mainAxis === void 0 ? true : _options$mainAxis,\n _options$altAxis = options.altAxis,\n checkAltAxis = _options$altAxis === void 0 ? false : _options$altAxis,\n boundary = options.boundary,\n rootBoundary = options.rootBoundary,\n altBoundary = options.altBoundary,\n padding = options.padding,\n _options$tether = options.tether,\n tether = _options$tether === void 0 ? true : _options$tether,\n _options$tetherOffset = options.tetherOffset,\n tetherOffset = _options$tetherOffset === void 0 ? 0 : _options$tetherOffset;\n var overflow = detectOverflow(state, {\n boundary: boundary,\n rootBoundary: rootBoundary,\n padding: padding,\n altBoundary: altBoundary\n });\n var basePlacement = getBasePlacement(state.placement);\n var variation = getVariation(state.placement);\n var isBasePlacement = !variation;\n var mainAxis = getMainAxisFromPlacement(basePlacement);\n var altAxis = getAltAxis(mainAxis);\n var popperOffsets = state.modifiersData.popperOffsets;\n var referenceRect = state.rects.reference;\n var popperRect = state.rects.popper;\n var tetherOffsetValue = typeof tetherOffset === 'function' ? tetherOffset(Object.assign({}, state.rects, {\n placement: state.placement\n })) : tetherOffset;\n var normalizedTetherOffsetValue = typeof tetherOffsetValue === 'number' ? {\n mainAxis: tetherOffsetValue,\n altAxis: tetherOffsetValue\n } : Object.assign({\n mainAxis: 0,\n altAxis: 0\n }, tetherOffsetValue);\n var offsetModifierState = state.modifiersData.offset ? state.modifiersData.offset[state.placement] : null;\n var data = {\n x: 0,\n y: 0\n };\n\n if (!popperOffsets) {\n return;\n }\n\n if (checkMainAxis) {\n var _offsetModifierState$;\n\n var mainSide = mainAxis === 'y' ? top : left;\n var altSide = mainAxis === 'y' ? bottom : right;\n var len = mainAxis === 'y' ? 'height' : 'width';\n var offset = popperOffsets[mainAxis];\n var min = offset + overflow[mainSide];\n var max = offset - overflow[altSide];\n var additive = tether ? -popperRect[len] / 2 : 0;\n var minLen = variation === start ? referenceRect[len] : popperRect[len];\n var maxLen = variation === start ? -popperRect[len] : -referenceRect[len]; // We need to include the arrow in the calculation so the arrow doesn't go\n // outside the reference bounds\n\n var arrowElement = state.elements.arrow;\n var arrowRect = tether && arrowElement ? getLayoutRect(arrowElement) : {\n width: 0,\n height: 0\n };\n var arrowPaddingObject = state.modifiersData['arrow#persistent'] ? state.modifiersData['arrow#persistent'].padding : getFreshSideObject();\n var arrowPaddingMin = arrowPaddingObject[mainSide];\n var arrowPaddingMax = arrowPaddingObject[altSide]; // If the reference length is smaller than the arrow length, we don't want\n // to include its full size in the calculation. If the reference is small\n // and near the edge of a boundary, the popper can overflow even if the\n // reference is not overflowing as well (e.g. virtual elements with no\n // width or height)\n\n var arrowLen = within(0, referenceRect[len], arrowRect[len]);\n var minOffset = isBasePlacement ? referenceRect[len] / 2 - additive - arrowLen - arrowPaddingMin - normalizedTetherOffsetValue.mainAxis : minLen - arrowLen - arrowPaddingMin - normalizedTetherOffsetValue.mainAxis;\n var maxOffset = isBasePlacement ? -referenceRect[len] / 2 + additive + arrowLen + arrowPaddingMax + normalizedTetherOffsetValue.mainAxis : maxLen + arrowLen + arrowPaddingMax + normalizedTetherOffsetValue.mainAxis;\n var arrowOffsetParent = state.elements.arrow && getOffsetParent(state.elements.arrow);\n var clientOffset = arrowOffsetParent ? mainAxis === 'y' ? arrowOffsetParent.clientTop || 0 : arrowOffsetParent.clientLeft || 0 : 0;\n var offsetModifierValue = (_offsetModifierState$ = offsetModifierState == null ? void 0 : offsetModifierState[mainAxis]) != null ? _offsetModifierState$ : 0;\n var tetherMin = offset + minOffset - offsetModifierValue - clientOffset;\n var tetherMax = offset + maxOffset - offsetModifierValue;\n var preventedOffset = within(tether ? mathMin(min, tetherMin) : min, offset, tether ? mathMax(max, tetherMax) : max);\n popperOffsets[mainAxis] = preventedOffset;\n data[mainAxis] = preventedOffset - offset;\n }\n\n if (checkAltAxis) {\n var _offsetModifierState$2;\n\n var _mainSide = mainAxis === 'x' ? top : left;\n\n var _altSide = mainAxis === 'x' ? bottom : right;\n\n var _offset = popperOffsets[altAxis];\n\n var _len = altAxis === 'y' ? 'height' : 'width';\n\n var _min = _offset + overflow[_mainSide];\n\n var _max = _offset - overflow[_altSide];\n\n var isOriginSide = [top, left].indexOf(basePlacement) !== -1;\n\n var _offsetModifierValue = (_offsetModifierState$2 = offsetModifierState == null ? void 0 : offsetModifierState[altAxis]) != null ? _offsetModifierState$2 : 0;\n\n var _tetherMin = isOriginSide ? _min : _offset - referenceRect[_len] - popperRect[_len] - _offsetModifierValue + normalizedTetherOffsetValue.altAxis;\n\n var _tetherMax = isOriginSide ? _offset + referenceRect[_len] + popperRect[_len] - _offsetModifierValue - normalizedTetherOffsetValue.altAxis : _max;\n\n var _preventedOffset = tether && isOriginSide ? withinMaxClamp(_tetherMin, _offset, _tetherMax) : within(tether ? _tetherMin : _min, _offset, tether ? _tetherMax : _max);\n\n popperOffsets[altAxis] = _preventedOffset;\n data[altAxis] = _preventedOffset - _offset;\n }\n\n state.modifiersData[name] = data;\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'preventOverflow',\n enabled: true,\n phase: 'main',\n fn: preventOverflow,\n requiresIfExists: ['offset']\n};","export default function getHTMLElementScroll(element) {\n return {\n scrollLeft: element.scrollLeft,\n scrollTop: element.scrollTop\n };\n}","import getWindowScroll from \"./getWindowScroll.js\";\nimport getWindow from \"./getWindow.js\";\nimport { isHTMLElement } from \"./instanceOf.js\";\nimport getHTMLElementScroll from \"./getHTMLElementScroll.js\";\nexport default function getNodeScroll(node) {\n if (node === getWindow(node) || !isHTMLElement(node)) {\n return getWindowScroll(node);\n } else {\n return getHTMLElementScroll(node);\n }\n}","import getBoundingClientRect from \"./getBoundingClientRect.js\";\nimport getNodeScroll from \"./getNodeScroll.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport { isHTMLElement } from \"./instanceOf.js\";\nimport getWindowScrollBarX from \"./getWindowScrollBarX.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport isScrollParent from \"./isScrollParent.js\";\nimport { round } from \"../utils/math.js\";\n\nfunction isElementScaled(element) {\n var rect = element.getBoundingClientRect();\n var scaleX = round(rect.width) / element.offsetWidth || 1;\n var scaleY = round(rect.height) / element.offsetHeight || 1;\n return scaleX !== 1 || scaleY !== 1;\n} // Returns the composite rect of an element relative to its offsetParent.\n// Composite means it takes into account transforms as well as layout.\n\n\nexport default function getCompositeRect(elementOrVirtualElement, offsetParent, isFixed) {\n if (isFixed === void 0) {\n isFixed = false;\n }\n\n var isOffsetParentAnElement = isHTMLElement(offsetParent);\n var offsetParentIsScaled = isHTMLElement(offsetParent) && isElementScaled(offsetParent);\n var documentElement = getDocumentElement(offsetParent);\n var rect = getBoundingClientRect(elementOrVirtualElement, offsetParentIsScaled, isFixed);\n var scroll = {\n scrollLeft: 0,\n scrollTop: 0\n };\n var offsets = {\n x: 0,\n y: 0\n };\n\n if (isOffsetParentAnElement || !isOffsetParentAnElement && !isFixed) {\n if (getNodeName(offsetParent) !== 'body' || // https://github.com/popperjs/popper-core/issues/1078\n isScrollParent(documentElement)) {\n scroll = getNodeScroll(offsetParent);\n }\n\n if (isHTMLElement(offsetParent)) {\n offsets = getBoundingClientRect(offsetParent, true);\n offsets.x += offsetParent.clientLeft;\n offsets.y += offsetParent.clientTop;\n } else if (documentElement) {\n offsets.x = getWindowScrollBarX(documentElement);\n }\n }\n\n return {\n x: rect.left + scroll.scrollLeft - offsets.x,\n y: rect.top + scroll.scrollTop - offsets.y,\n width: rect.width,\n height: rect.height\n };\n}","import { modifierPhases } from \"../enums.js\"; // source: https://stackoverflow.com/questions/49875255\n\nfunction order(modifiers) {\n var map = new Map();\n var visited = new Set();\n var result = [];\n modifiers.forEach(function (modifier) {\n map.set(modifier.name, modifier);\n }); // On visiting object, check for its dependencies and visit them recursively\n\n function sort(modifier) {\n visited.add(modifier.name);\n var requires = [].concat(modifier.requires || [], modifier.requiresIfExists || []);\n requires.forEach(function (dep) {\n if (!visited.has(dep)) {\n var depModifier = map.get(dep);\n\n if (depModifier) {\n sort(depModifier);\n }\n }\n });\n result.push(modifier);\n }\n\n modifiers.forEach(function (modifier) {\n if (!visited.has(modifier.name)) {\n // check for visited object\n sort(modifier);\n }\n });\n return result;\n}\n\nexport default function orderModifiers(modifiers) {\n // order based on dependencies\n var orderedModifiers = order(modifiers); // order based on phase\n\n return modifierPhases.reduce(function (acc, phase) {\n return acc.concat(orderedModifiers.filter(function (modifier) {\n return modifier.phase === phase;\n }));\n }, []);\n}","export default function debounce(fn) {\n var pending;\n return function () {\n if (!pending) {\n pending = new Promise(function (resolve) {\n Promise.resolve().then(function () {\n pending = undefined;\n resolve(fn());\n });\n });\n }\n\n return pending;\n };\n}","export default function mergeByName(modifiers) {\n var merged = modifiers.reduce(function (merged, current) {\n var existing = merged[current.name];\n merged[current.name] = existing ? Object.assign({}, existing, current, {\n options: Object.assign({}, existing.options, current.options),\n data: Object.assign({}, existing.data, current.data)\n }) : current;\n return merged;\n }, {}); // IE11 does not support Object.values\n\n return Object.keys(merged).map(function (key) {\n return merged[key];\n });\n}","import getCompositeRect from \"./dom-utils/getCompositeRect.js\";\nimport getLayoutRect from \"./dom-utils/getLayoutRect.js\";\nimport listScrollParents from \"./dom-utils/listScrollParents.js\";\nimport getOffsetParent from \"./dom-utils/getOffsetParent.js\";\nimport orderModifiers from \"./utils/orderModifiers.js\";\nimport debounce from \"./utils/debounce.js\";\nimport mergeByName from \"./utils/mergeByName.js\";\nimport detectOverflow from \"./utils/detectOverflow.js\";\nimport { isElement } from \"./dom-utils/instanceOf.js\";\nvar DEFAULT_OPTIONS = {\n placement: 'bottom',\n modifiers: [],\n strategy: 'absolute'\n};\n\nfunction areValidElements() {\n for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {\n args[_key] = arguments[_key];\n }\n\n return !args.some(function (element) {\n return !(element && typeof element.getBoundingClientRect === 'function');\n });\n}\n\nexport function popperGenerator(generatorOptions) {\n if (generatorOptions === void 0) {\n generatorOptions = {};\n }\n\n var _generatorOptions = generatorOptions,\n _generatorOptions$def = _generatorOptions.defaultModifiers,\n defaultModifiers = _generatorOptions$def === void 0 ? [] : _generatorOptions$def,\n _generatorOptions$def2 = _generatorOptions.defaultOptions,\n defaultOptions = _generatorOptions$def2 === void 0 ? DEFAULT_OPTIONS : _generatorOptions$def2;\n return function createPopper(reference, popper, options) {\n if (options === void 0) {\n options = defaultOptions;\n }\n\n var state = {\n placement: 'bottom',\n orderedModifiers: [],\n options: Object.assign({}, DEFAULT_OPTIONS, defaultOptions),\n modifiersData: {},\n elements: {\n reference: reference,\n popper: popper\n },\n attributes: {},\n styles: {}\n };\n var effectCleanupFns = [];\n var isDestroyed = false;\n var instance = {\n state: state,\n setOptions: function setOptions(setOptionsAction) {\n var options = typeof setOptionsAction === 'function' ? setOptionsAction(state.options) : setOptionsAction;\n cleanupModifierEffects();\n state.options = Object.assign({}, defaultOptions, state.options, options);\n state.scrollParents = {\n reference: isElement(reference) ? listScrollParents(reference) : reference.contextElement ? listScrollParents(reference.contextElement) : [],\n popper: listScrollParents(popper)\n }; // Orders the modifiers based on their dependencies and `phase`\n // properties\n\n var orderedModifiers = orderModifiers(mergeByName([].concat(defaultModifiers, state.options.modifiers))); // Strip out disabled modifiers\n\n state.orderedModifiers = orderedModifiers.filter(function (m) {\n return m.enabled;\n });\n runModifierEffects();\n return instance.update();\n },\n // Sync update – it will always be executed, even if not necessary. This\n // is useful for low frequency updates where sync behavior simplifies the\n // logic.\n // For high frequency updates (e.g. `resize` and `scroll` events), always\n // prefer the async Popper#update method\n forceUpdate: function forceUpdate() {\n if (isDestroyed) {\n return;\n }\n\n var _state$elements = state.elements,\n reference = _state$elements.reference,\n popper = _state$elements.popper; // Don't proceed if `reference` or `popper` are not valid elements\n // anymore\n\n if (!areValidElements(reference, popper)) {\n return;\n } // Store the reference and popper rects to be read by modifiers\n\n\n state.rects = {\n reference: getCompositeRect(reference, getOffsetParent(popper), state.options.strategy === 'fixed'),\n popper: getLayoutRect(popper)\n }; // Modifiers have the ability to reset the current update cycle. The\n // most common use case for this is the `flip` modifier changing the\n // placement, which then needs to re-run all the modifiers, because the\n // logic was previously ran for the previous placement and is therefore\n // stale/incorrect\n\n state.reset = false;\n state.placement = state.options.placement; // On each update cycle, the `modifiersData` property for each modifier\n // is filled with the initial data specified by the modifier. This means\n // it doesn't persist and is fresh on each update.\n // To ensure persistent data, use `${name}#persistent`\n\n state.orderedModifiers.forEach(function (modifier) {\n return state.modifiersData[modifier.name] = Object.assign({}, modifier.data);\n });\n\n for (var index = 0; index < state.orderedModifiers.length; index++) {\n if (state.reset === true) {\n state.reset = false;\n index = -1;\n continue;\n }\n\n var _state$orderedModifie = state.orderedModifiers[index],\n fn = _state$orderedModifie.fn,\n _state$orderedModifie2 = _state$orderedModifie.options,\n _options = _state$orderedModifie2 === void 0 ? {} : _state$orderedModifie2,\n name = _state$orderedModifie.name;\n\n if (typeof fn === 'function') {\n state = fn({\n state: state,\n options: _options,\n name: name,\n instance: instance\n }) || state;\n }\n }\n },\n // Async and optimistically optimized update – it will not be executed if\n // not necessary (debounced to run at most once-per-tick)\n update: debounce(function () {\n return new Promise(function (resolve) {\n instance.forceUpdate();\n resolve(state);\n });\n }),\n destroy: function destroy() {\n cleanupModifierEffects();\n isDestroyed = true;\n }\n };\n\n if (!areValidElements(reference, popper)) {\n return instance;\n }\n\n instance.setOptions(options).then(function (state) {\n if (!isDestroyed && options.onFirstUpdate) {\n options.onFirstUpdate(state);\n }\n }); // Modifiers have the ability to execute arbitrary code before the first\n // update cycle runs. They will be executed in the same order as the update\n // cycle. This is useful when a modifier adds some persistent data that\n // other modifiers need to use, but the modifier is run after the dependent\n // one.\n\n function runModifierEffects() {\n state.orderedModifiers.forEach(function (_ref) {\n var name = _ref.name,\n _ref$options = _ref.options,\n options = _ref$options === void 0 ? {} : _ref$options,\n effect = _ref.effect;\n\n if (typeof effect === 'function') {\n var cleanupFn = effect({\n state: state,\n name: name,\n instance: instance,\n options: options\n });\n\n var noopFn = function noopFn() {};\n\n effectCleanupFns.push(cleanupFn || noopFn);\n }\n });\n }\n\n function cleanupModifierEffects() {\n effectCleanupFns.forEach(function (fn) {\n return fn();\n });\n effectCleanupFns = [];\n }\n\n return instance;\n };\n}\nexport var createPopper = /*#__PURE__*/popperGenerator(); // eslint-disable-next-line import/no-unused-modules\n\nexport { detectOverflow };","import { popperGenerator, detectOverflow } from \"./createPopper.js\";\nimport eventListeners from \"./modifiers/eventListeners.js\";\nimport popperOffsets from \"./modifiers/popperOffsets.js\";\nimport computeStyles from \"./modifiers/computeStyles.js\";\nimport applyStyles from \"./modifiers/applyStyles.js\";\nimport offset from \"./modifiers/offset.js\";\nimport flip from \"./modifiers/flip.js\";\nimport preventOverflow from \"./modifiers/preventOverflow.js\";\nimport arrow from \"./modifiers/arrow.js\";\nimport hide from \"./modifiers/hide.js\";\nvar defaultModifiers = [eventListeners, popperOffsets, computeStyles, applyStyles, offset, flip, preventOverflow, arrow, hide];\nvar createPopper = /*#__PURE__*/popperGenerator({\n defaultModifiers: defaultModifiers\n}); // eslint-disable-next-line import/no-unused-modules\n\nexport { createPopper, popperGenerator, defaultModifiers, detectOverflow }; // eslint-disable-next-line import/no-unused-modules\n\nexport { createPopper as createPopperLite } from \"./popper-lite.js\"; // eslint-disable-next-line import/no-unused-modules\n\nexport * from \"./modifiers/index.js\";","import { generateUtilityClass } from '../generateUtilityClass';\nimport { generateUtilityClasses } from '../generateUtilityClasses';\nconst COMPONENT_NAME = 'Popper';\nexport function getPopperUtilityClass(slot) {\n return generateUtilityClass(COMPONENT_NAME, slot);\n}\nexport const popperClasses = generateUtilityClasses(COMPONENT_NAME, ['root']);","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"anchorEl\", \"children\", \"direction\", \"disablePortal\", \"modifiers\", \"open\", \"placement\", \"popperOptions\", \"popperRef\", \"slotProps\", \"slots\", \"TransitionProps\", \"ownerState\"],\n _excluded2 = [\"anchorEl\", \"children\", \"container\", \"direction\", \"disablePortal\", \"keepMounted\", \"modifiers\", \"open\", \"placement\", \"popperOptions\", \"popperRef\", \"style\", \"transition\", \"slotProps\", \"slots\"];\nimport * as React from 'react';\nimport { chainPropTypes, HTMLElementType, refType, unstable_ownerDocument as ownerDocument, unstable_useEnhancedEffect as useEnhancedEffect, unstable_useForkRef as useForkRef } from '@mui/utils';\nimport { createPopper } from '@popperjs/core';\nimport PropTypes from 'prop-types';\nimport { unstable_composeClasses as composeClasses } from '../composeClasses';\nimport { Portal } from '../Portal';\nimport { getPopperUtilityClass } from './popperClasses';\nimport { useSlotProps } from '../utils';\nimport { useClassNamesOverride } from '../utils/ClassNameConfigurator';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nfunction flipPlacement(placement, direction) {\n if (direction === 'ltr') {\n return placement;\n }\n switch (placement) {\n case 'bottom-end':\n return 'bottom-start';\n case 'bottom-start':\n return 'bottom-end';\n case 'top-end':\n return 'top-start';\n case 'top-start':\n return 'top-end';\n default:\n return placement;\n }\n}\nfunction resolveAnchorEl(anchorEl) {\n return typeof anchorEl === 'function' ? anchorEl() : anchorEl;\n}\nfunction isHTMLElement(element) {\n return element.nodeType !== undefined;\n}\nfunction isVirtualElement(element) {\n return !isHTMLElement(element);\n}\nconst useUtilityClasses = () => {\n const slots = {\n root: ['root']\n };\n return composeClasses(slots, useClassNamesOverride(getPopperUtilityClass));\n};\nconst defaultPopperOptions = {};\nconst PopperTooltip = /*#__PURE__*/React.forwardRef(function PopperTooltip(props, forwardedRef) {\n var _slots$root;\n const {\n anchorEl,\n children,\n direction,\n disablePortal,\n modifiers,\n open,\n placement: initialPlacement,\n popperOptions,\n popperRef: popperRefProp,\n slotProps = {},\n slots = {},\n TransitionProps\n // @ts-ignore internal logic\n // prevent from spreading to DOM, it can come from the parent component e.g. Select.\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const tooltipRef = React.useRef(null);\n const ownRef = useForkRef(tooltipRef, forwardedRef);\n const popperRef = React.useRef(null);\n const handlePopperRef = useForkRef(popperRef, popperRefProp);\n const handlePopperRefRef = React.useRef(handlePopperRef);\n useEnhancedEffect(() => {\n handlePopperRefRef.current = handlePopperRef;\n }, [handlePopperRef]);\n React.useImperativeHandle(popperRefProp, () => popperRef.current, []);\n const rtlPlacement = flipPlacement(initialPlacement, direction);\n /**\n * placement initialized from prop but can change during lifetime if modifiers.flip.\n * modifiers.flip is essentially a flip for controlled/uncontrolled behavior\n */\n const [placement, setPlacement] = React.useState(rtlPlacement);\n const [resolvedAnchorElement, setResolvedAnchorElement] = React.useState(resolveAnchorEl(anchorEl));\n React.useEffect(() => {\n if (popperRef.current) {\n popperRef.current.forceUpdate();\n }\n });\n React.useEffect(() => {\n if (anchorEl) {\n setResolvedAnchorElement(resolveAnchorEl(anchorEl));\n }\n }, [anchorEl]);\n useEnhancedEffect(() => {\n if (!resolvedAnchorElement || !open) {\n return undefined;\n }\n const handlePopperUpdate = data => {\n setPlacement(data.placement);\n };\n if (process.env.NODE_ENV !== 'production') {\n if (resolvedAnchorElement && isHTMLElement(resolvedAnchorElement) && resolvedAnchorElement.nodeType === 1) {\n const box = resolvedAnchorElement.getBoundingClientRect();\n if (process.env.NODE_ENV !== 'test' && box.top === 0 && box.left === 0 && box.right === 0 && box.bottom === 0) {\n console.warn(['MUI: The `anchorEl` prop provided to the component is invalid.', 'The anchor element should be part of the document layout.', \"Make sure the element is present in the document or that it's not display none.\"].join('\\n'));\n }\n }\n }\n let popperModifiers = [{\n name: 'preventOverflow',\n options: {\n altBoundary: disablePortal\n }\n }, {\n name: 'flip',\n options: {\n altBoundary: disablePortal\n }\n }, {\n name: 'onUpdate',\n enabled: true,\n phase: 'afterWrite',\n fn: ({\n state\n }) => {\n handlePopperUpdate(state);\n }\n }];\n if (modifiers != null) {\n popperModifiers = popperModifiers.concat(modifiers);\n }\n if (popperOptions && popperOptions.modifiers != null) {\n popperModifiers = popperModifiers.concat(popperOptions.modifiers);\n }\n const popper = createPopper(resolvedAnchorElement, tooltipRef.current, _extends({\n placement: rtlPlacement\n }, popperOptions, {\n modifiers: popperModifiers\n }));\n handlePopperRefRef.current(popper);\n return () => {\n popper.destroy();\n handlePopperRefRef.current(null);\n };\n }, [resolvedAnchorElement, disablePortal, modifiers, open, popperOptions, rtlPlacement]);\n const childProps = {\n placement: placement\n };\n if (TransitionProps !== null) {\n childProps.TransitionProps = TransitionProps;\n }\n const classes = useUtilityClasses();\n const Root = (_slots$root = slots.root) != null ? _slots$root : 'div';\n const rootProps = useSlotProps({\n elementType: Root,\n externalSlotProps: slotProps.root,\n externalForwardedProps: other,\n additionalProps: {\n role: 'tooltip',\n ref: ownRef\n },\n ownerState: props,\n className: classes.root\n });\n return /*#__PURE__*/_jsx(Root, _extends({}, rootProps, {\n children: typeof children === 'function' ? children(childProps) : children\n }));\n});\n\n/**\n * Poppers rely on the 3rd party library [Popper.js](https://popper.js.org/docs/v2/) for positioning.\n *\n * Demos:\n *\n * - [Popper](https://mui.com/base-ui/react-popper/)\n *\n * API:\n *\n * - [Popper API](https://mui.com/base-ui/react-popper/components-api/#popper)\n */\nconst Popper = /*#__PURE__*/React.forwardRef(function Popper(props, forwardedRef) {\n const {\n anchorEl,\n children,\n container: containerProp,\n direction = 'ltr',\n disablePortal = false,\n keepMounted = false,\n modifiers,\n open,\n placement = 'bottom',\n popperOptions = defaultPopperOptions,\n popperRef,\n style,\n transition = false,\n slotProps = {},\n slots = {}\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded2);\n const [exited, setExited] = React.useState(true);\n const handleEnter = () => {\n setExited(false);\n };\n const handleExited = () => {\n setExited(true);\n };\n if (!keepMounted && !open && (!transition || exited)) {\n return null;\n }\n\n // If the container prop is provided, use that\n // If the anchorEl prop is provided, use its parent body element as the container\n // If neither are provided let the Modal take care of choosing the container\n let container;\n if (containerProp) {\n container = containerProp;\n } else if (anchorEl) {\n const resolvedAnchorEl = resolveAnchorEl(anchorEl);\n container = resolvedAnchorEl && isHTMLElement(resolvedAnchorEl) ? ownerDocument(resolvedAnchorEl).body : ownerDocument(null).body;\n }\n const display = !open && keepMounted && (!transition || exited) ? 'none' : undefined;\n const transitionProps = transition ? {\n in: open,\n onEnter: handleEnter,\n onExited: handleExited\n } : undefined;\n return /*#__PURE__*/_jsx(Portal, {\n disablePortal: disablePortal,\n container: container,\n children: /*#__PURE__*/_jsx(PopperTooltip, _extends({\n anchorEl: anchorEl,\n direction: direction,\n disablePortal: disablePortal,\n modifiers: modifiers,\n ref: forwardedRef,\n open: transition ? !exited : open,\n placement: placement,\n popperOptions: popperOptions,\n popperRef: popperRef,\n slotProps: slotProps,\n slots: slots\n }, other, {\n style: _extends({\n // Prevents scroll issue, waiting for Popper.js to add this style once initiated.\n position: 'fixed',\n // Fix Popper.js display issue\n top: 0,\n left: 0,\n display\n }, style),\n TransitionProps: transitionProps,\n children: children\n }))\n });\n});\nprocess.env.NODE_ENV !== \"production\" ? Popper.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * An HTML element, [virtualElement](https://popper.js.org/docs/v2/virtual-elements/),\n * or a function that returns either.\n * It's used to set the position of the popper.\n * The return value will passed as the reference object of the Popper instance.\n */\n anchorEl: chainPropTypes(PropTypes.oneOfType([HTMLElementType, PropTypes.object, PropTypes.func]), props => {\n if (props.open) {\n const resolvedAnchorEl = resolveAnchorEl(props.anchorEl);\n if (resolvedAnchorEl && isHTMLElement(resolvedAnchorEl) && resolvedAnchorEl.nodeType === 1) {\n const box = resolvedAnchorEl.getBoundingClientRect();\n if (process.env.NODE_ENV !== 'test' && box.top === 0 && box.left === 0 && box.right === 0 && box.bottom === 0) {\n return new Error(['MUI: The `anchorEl` prop provided to the component is invalid.', 'The anchor element should be part of the document layout.', \"Make sure the element is present in the document or that it's not display none.\"].join('\\n'));\n }\n } else if (!resolvedAnchorEl || typeof resolvedAnchorEl.getBoundingClientRect !== 'function' || isVirtualElement(resolvedAnchorEl) && resolvedAnchorEl.contextElement != null && resolvedAnchorEl.contextElement.nodeType !== 1) {\n return new Error(['MUI: The `anchorEl` prop provided to the component is invalid.', 'It should be an HTML element instance or a virtualElement ', '(https://popper.js.org/docs/v2/virtual-elements/).'].join('\\n'));\n }\n }\n return null;\n }),\n /**\n * Popper render function or node.\n */\n children: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.node, PropTypes.func]),\n /**\n * An HTML element or function that returns one.\n * The `container` will have the portal children appended to it.\n *\n * You can also provide a callback, which is called in a React layout effect.\n * This lets you set the container from a ref, and also makes server-side rendering possible.\n *\n * By default, it uses the body of the top-level document object,\n * so it's simply `document.body` most of the time.\n */\n container: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.func]),\n /**\n * Direction of the text.\n * @default 'ltr'\n */\n direction: PropTypes.oneOf(['ltr', 'rtl']),\n /**\n * The `children` will be under the DOM hierarchy of the parent component.\n * @default false\n */\n disablePortal: PropTypes.bool,\n /**\n * Always keep the children in the DOM.\n * This prop can be useful in SEO situation or\n * when you want to maximize the responsiveness of the Popper.\n * @default false\n */\n keepMounted: PropTypes.bool,\n /**\n * Popper.js is based on a \"plugin-like\" architecture,\n * most of its features are fully encapsulated \"modifiers\".\n *\n * A modifier is a function that is called each time Popper.js needs to\n * compute the position of the popper.\n * For this reason, modifiers should be very performant to avoid bottlenecks.\n * To learn how to create a modifier, [read the modifiers documentation](https://popper.js.org/docs/v2/modifiers/).\n */\n modifiers: PropTypes.arrayOf(PropTypes.shape({\n data: PropTypes.object,\n effect: PropTypes.func,\n enabled: PropTypes.bool,\n fn: PropTypes.func,\n name: PropTypes.any,\n options: PropTypes.object,\n phase: PropTypes.oneOf(['afterMain', 'afterRead', 'afterWrite', 'beforeMain', 'beforeRead', 'beforeWrite', 'main', 'read', 'write']),\n requires: PropTypes.arrayOf(PropTypes.string),\n requiresIfExists: PropTypes.arrayOf(PropTypes.string)\n })),\n /**\n * If `true`, the component is shown.\n */\n open: PropTypes.bool.isRequired,\n /**\n * Popper placement.\n * @default 'bottom'\n */\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n /**\n * Options provided to the [`Popper.js`](https://popper.js.org/docs/v2/constructors/#options) instance.\n * @default {}\n */\n popperOptions: PropTypes.shape({\n modifiers: PropTypes.array,\n onFirstUpdate: PropTypes.func,\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n strategy: PropTypes.oneOf(['absolute', 'fixed'])\n }),\n /**\n * A ref that points to the used popper instance.\n */\n popperRef: refType,\n /**\n * The props used for each slot inside the Popper.\n * @default {}\n */\n slotProps: PropTypes.shape({\n root: PropTypes.oneOfType([PropTypes.func, PropTypes.object])\n }),\n /**\n * The components used for each slot inside the Popper.\n * Either a string to use a HTML element or a component.\n * @default {}\n */\n slots: PropTypes.shape({\n root: PropTypes.elementType\n }),\n /**\n * Help supporting a react-transition-group/Transition component.\n * @default false\n */\n transition: PropTypes.bool\n} : void 0;\nexport { Popper };","'use client';\n\nimport * as React from 'react';\nimport { useTheme as useThemeSystem } from '@mui/system';\nimport defaultTheme from './defaultTheme';\nimport THEME_ID from './identifier';\nexport default function useTheme() {\n const theme = useThemeSystem(defaultTheme);\n if (process.env.NODE_ENV !== 'production') {\n // eslint-disable-next-line react-hooks/rules-of-hooks\n React.useDebugValue(theme);\n }\n return theme[THEME_ID] || theme;\n}","export default function _setPrototypeOf(o, p) {\n _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function _setPrototypeOf(o, p) {\n o.__proto__ = p;\n return o;\n };\n return _setPrototypeOf(o, p);\n}","import setPrototypeOf from \"./setPrototypeOf.js\";\nexport default function _inheritsLoose(subClass, superClass) {\n subClass.prototype = Object.create(superClass.prototype);\n subClass.prototype.constructor = subClass;\n setPrototypeOf(subClass, superClass);\n}","export default {\n disabled: false\n};","import PropTypes from 'prop-types';\nexport var timeoutsShape = process.env.NODE_ENV !== 'production' ? PropTypes.oneOfType([PropTypes.number, PropTypes.shape({\n enter: PropTypes.number,\n exit: PropTypes.number,\n appear: PropTypes.number\n}).isRequired]) : null;\nexport var classNamesShape = process.env.NODE_ENV !== 'production' ? PropTypes.oneOfType([PropTypes.string, PropTypes.shape({\n enter: PropTypes.string,\n exit: PropTypes.string,\n active: PropTypes.string\n}), PropTypes.shape({\n enter: PropTypes.string,\n enterDone: PropTypes.string,\n enterActive: PropTypes.string,\n exit: PropTypes.string,\n exitDone: PropTypes.string,\n exitActive: PropTypes.string\n})]) : null;","import React from 'react';\nexport default React.createContext(null);","export var forceReflow = function forceReflow(node) {\n return node.scrollTop;\n};","import _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _inheritsLoose from \"@babel/runtime/helpers/esm/inheritsLoose\";\nimport PropTypes from 'prop-types';\nimport React from 'react';\nimport ReactDOM from 'react-dom';\nimport config from './config';\nimport { timeoutsShape } from './utils/PropTypes';\nimport TransitionGroupContext from './TransitionGroupContext';\nimport { forceReflow } from './utils/reflow';\nexport var UNMOUNTED = 'unmounted';\nexport var EXITED = 'exited';\nexport var ENTERING = 'entering';\nexport var ENTERED = 'entered';\nexport var EXITING = 'exiting';\n/**\n * The Transition component lets you describe a transition from one component\n * state to another _over time_ with a simple declarative API. Most commonly\n * it's used to animate the mounting and unmounting of a component, but can also\n * be used to describe in-place transition states as well.\n *\n * ---\n *\n * **Note**: `Transition` is a platform-agnostic base component. If you're using\n * transitions in CSS, you'll probably want to use\n * [`CSSTransition`](https://reactcommunity.org/react-transition-group/css-transition)\n * instead. It inherits all the features of `Transition`, but contains\n * additional features necessary to play nice with CSS transitions (hence the\n * name of the component).\n *\n * ---\n *\n * By default the `Transition` component does not alter the behavior of the\n * component it renders, it only tracks \"enter\" and \"exit\" states for the\n * components. It's up to you to give meaning and effect to those states. For\n * example we can add styles to a component when it enters or exits:\n *\n * ```jsx\n * import { Transition } from 'react-transition-group';\n *\n * const duration = 300;\n *\n * const defaultStyle = {\n * transition: `opacity ${duration}ms ease-in-out`,\n * opacity: 0,\n * }\n *\n * const transitionStyles = {\n * entering: { opacity: 1 },\n * entered: { opacity: 1 },\n * exiting: { opacity: 0 },\n * exited: { opacity: 0 },\n * };\n *\n * const Fade = ({ in: inProp }) => (\n * \n * {state => (\n *
    \n * I'm a fade Transition!\n *
    \n * )}\n *
    \n * );\n * ```\n *\n * There are 4 main states a Transition can be in:\n * - `'entering'`\n * - `'entered'`\n * - `'exiting'`\n * - `'exited'`\n *\n * Transition state is toggled via the `in` prop. When `true` the component\n * begins the \"Enter\" stage. During this stage, the component will shift from\n * its current transition state, to `'entering'` for the duration of the\n * transition and then to the `'entered'` stage once it's complete. Let's take\n * the following example (we'll use the\n * [useState](https://reactjs.org/docs/hooks-reference.html#usestate) hook):\n *\n * ```jsx\n * function App() {\n * const [inProp, setInProp] = useState(false);\n * return (\n *
    \n * \n * {state => (\n * // ...\n * )}\n * \n * \n *
    \n * );\n * }\n * ```\n *\n * When the button is clicked the component will shift to the `'entering'` state\n * and stay there for 500ms (the value of `timeout`) before it finally switches\n * to `'entered'`.\n *\n * When `in` is `false` the same thing happens except the state moves from\n * `'exiting'` to `'exited'`.\n */\n\nvar Transition = /*#__PURE__*/function (_React$Component) {\n _inheritsLoose(Transition, _React$Component);\n\n function Transition(props, context) {\n var _this;\n\n _this = _React$Component.call(this, props, context) || this;\n var parentGroup = context; // In the context of a TransitionGroup all enters are really appears\n\n var appear = parentGroup && !parentGroup.isMounting ? props.enter : props.appear;\n var initialStatus;\n _this.appearStatus = null;\n\n if (props.in) {\n if (appear) {\n initialStatus = EXITED;\n _this.appearStatus = ENTERING;\n } else {\n initialStatus = ENTERED;\n }\n } else {\n if (props.unmountOnExit || props.mountOnEnter) {\n initialStatus = UNMOUNTED;\n } else {\n initialStatus = EXITED;\n }\n }\n\n _this.state = {\n status: initialStatus\n };\n _this.nextCallback = null;\n return _this;\n }\n\n Transition.getDerivedStateFromProps = function getDerivedStateFromProps(_ref, prevState) {\n var nextIn = _ref.in;\n\n if (nextIn && prevState.status === UNMOUNTED) {\n return {\n status: EXITED\n };\n }\n\n return null;\n } // getSnapshotBeforeUpdate(prevProps) {\n // let nextStatus = null\n // if (prevProps !== this.props) {\n // const { status } = this.state\n // if (this.props.in) {\n // if (status !== ENTERING && status !== ENTERED) {\n // nextStatus = ENTERING\n // }\n // } else {\n // if (status === ENTERING || status === ENTERED) {\n // nextStatus = EXITING\n // }\n // }\n // }\n // return { nextStatus }\n // }\n ;\n\n var _proto = Transition.prototype;\n\n _proto.componentDidMount = function componentDidMount() {\n this.updateStatus(true, this.appearStatus);\n };\n\n _proto.componentDidUpdate = function componentDidUpdate(prevProps) {\n var nextStatus = null;\n\n if (prevProps !== this.props) {\n var status = this.state.status;\n\n if (this.props.in) {\n if (status !== ENTERING && status !== ENTERED) {\n nextStatus = ENTERING;\n }\n } else {\n if (status === ENTERING || status === ENTERED) {\n nextStatus = EXITING;\n }\n }\n }\n\n this.updateStatus(false, nextStatus);\n };\n\n _proto.componentWillUnmount = function componentWillUnmount() {\n this.cancelNextCallback();\n };\n\n _proto.getTimeouts = function getTimeouts() {\n var timeout = this.props.timeout;\n var exit, enter, appear;\n exit = enter = appear = timeout;\n\n if (timeout != null && typeof timeout !== 'number') {\n exit = timeout.exit;\n enter = timeout.enter; // TODO: remove fallback for next major\n\n appear = timeout.appear !== undefined ? timeout.appear : enter;\n }\n\n return {\n exit: exit,\n enter: enter,\n appear: appear\n };\n };\n\n _proto.updateStatus = function updateStatus(mounting, nextStatus) {\n if (mounting === void 0) {\n mounting = false;\n }\n\n if (nextStatus !== null) {\n // nextStatus will always be ENTERING or EXITING.\n this.cancelNextCallback();\n\n if (nextStatus === ENTERING) {\n if (this.props.unmountOnExit || this.props.mountOnEnter) {\n var node = this.props.nodeRef ? this.props.nodeRef.current : ReactDOM.findDOMNode(this); // https://github.com/reactjs/react-transition-group/pull/749\n // With unmountOnExit or mountOnEnter, the enter animation should happen at the transition between `exited` and `entering`.\n // To make the animation happen, we have to separate each rendering and avoid being processed as batched.\n\n if (node) forceReflow(node);\n }\n\n this.performEnter(mounting);\n } else {\n this.performExit();\n }\n } else if (this.props.unmountOnExit && this.state.status === EXITED) {\n this.setState({\n status: UNMOUNTED\n });\n }\n };\n\n _proto.performEnter = function performEnter(mounting) {\n var _this2 = this;\n\n var enter = this.props.enter;\n var appearing = this.context ? this.context.isMounting : mounting;\n\n var _ref2 = this.props.nodeRef ? [appearing] : [ReactDOM.findDOMNode(this), appearing],\n maybeNode = _ref2[0],\n maybeAppearing = _ref2[1];\n\n var timeouts = this.getTimeouts();\n var enterTimeout = appearing ? timeouts.appear : timeouts.enter; // no enter animation skip right to ENTERED\n // if we are mounting and running this it means appear _must_ be set\n\n if (!mounting && !enter || config.disabled) {\n this.safeSetState({\n status: ENTERED\n }, function () {\n _this2.props.onEntered(maybeNode);\n });\n return;\n }\n\n this.props.onEnter(maybeNode, maybeAppearing);\n this.safeSetState({\n status: ENTERING\n }, function () {\n _this2.props.onEntering(maybeNode, maybeAppearing);\n\n _this2.onTransitionEnd(enterTimeout, function () {\n _this2.safeSetState({\n status: ENTERED\n }, function () {\n _this2.props.onEntered(maybeNode, maybeAppearing);\n });\n });\n });\n };\n\n _proto.performExit = function performExit() {\n var _this3 = this;\n\n var exit = this.props.exit;\n var timeouts = this.getTimeouts();\n var maybeNode = this.props.nodeRef ? undefined : ReactDOM.findDOMNode(this); // no exit animation skip right to EXITED\n\n if (!exit || config.disabled) {\n this.safeSetState({\n status: EXITED\n }, function () {\n _this3.props.onExited(maybeNode);\n });\n return;\n }\n\n this.props.onExit(maybeNode);\n this.safeSetState({\n status: EXITING\n }, function () {\n _this3.props.onExiting(maybeNode);\n\n _this3.onTransitionEnd(timeouts.exit, function () {\n _this3.safeSetState({\n status: EXITED\n }, function () {\n _this3.props.onExited(maybeNode);\n });\n });\n });\n };\n\n _proto.cancelNextCallback = function cancelNextCallback() {\n if (this.nextCallback !== null) {\n this.nextCallback.cancel();\n this.nextCallback = null;\n }\n };\n\n _proto.safeSetState = function safeSetState(nextState, callback) {\n // This shouldn't be necessary, but there are weird race conditions with\n // setState callbacks and unmounting in testing, so always make sure that\n // we can cancel any pending setState callbacks after we unmount.\n callback = this.setNextCallback(callback);\n this.setState(nextState, callback);\n };\n\n _proto.setNextCallback = function setNextCallback(callback) {\n var _this4 = this;\n\n var active = true;\n\n this.nextCallback = function (event) {\n if (active) {\n active = false;\n _this4.nextCallback = null;\n callback(event);\n }\n };\n\n this.nextCallback.cancel = function () {\n active = false;\n };\n\n return this.nextCallback;\n };\n\n _proto.onTransitionEnd = function onTransitionEnd(timeout, handler) {\n this.setNextCallback(handler);\n var node = this.props.nodeRef ? this.props.nodeRef.current : ReactDOM.findDOMNode(this);\n var doesNotHaveTimeoutOrListener = timeout == null && !this.props.addEndListener;\n\n if (!node || doesNotHaveTimeoutOrListener) {\n setTimeout(this.nextCallback, 0);\n return;\n }\n\n if (this.props.addEndListener) {\n var _ref3 = this.props.nodeRef ? [this.nextCallback] : [node, this.nextCallback],\n maybeNode = _ref3[0],\n maybeNextCallback = _ref3[1];\n\n this.props.addEndListener(maybeNode, maybeNextCallback);\n }\n\n if (timeout != null) {\n setTimeout(this.nextCallback, timeout);\n }\n };\n\n _proto.render = function render() {\n var status = this.state.status;\n\n if (status === UNMOUNTED) {\n return null;\n }\n\n var _this$props = this.props,\n children = _this$props.children,\n _in = _this$props.in,\n _mountOnEnter = _this$props.mountOnEnter,\n _unmountOnExit = _this$props.unmountOnExit,\n _appear = _this$props.appear,\n _enter = _this$props.enter,\n _exit = _this$props.exit,\n _timeout = _this$props.timeout,\n _addEndListener = _this$props.addEndListener,\n _onEnter = _this$props.onEnter,\n _onEntering = _this$props.onEntering,\n _onEntered = _this$props.onEntered,\n _onExit = _this$props.onExit,\n _onExiting = _this$props.onExiting,\n _onExited = _this$props.onExited,\n _nodeRef = _this$props.nodeRef,\n childProps = _objectWithoutPropertiesLoose(_this$props, [\"children\", \"in\", \"mountOnEnter\", \"unmountOnExit\", \"appear\", \"enter\", \"exit\", \"timeout\", \"addEndListener\", \"onEnter\", \"onEntering\", \"onEntered\", \"onExit\", \"onExiting\", \"onExited\", \"nodeRef\"]);\n\n return (\n /*#__PURE__*/\n // allows for nested Transitions\n React.createElement(TransitionGroupContext.Provider, {\n value: null\n }, typeof children === 'function' ? children(status, childProps) : React.cloneElement(React.Children.only(children), childProps))\n );\n };\n\n return Transition;\n}(React.Component);\n\nTransition.contextType = TransitionGroupContext;\nTransition.propTypes = process.env.NODE_ENV !== \"production\" ? {\n /**\n * A React reference to DOM element that need to transition:\n * https://stackoverflow.com/a/51127130/4671932\n *\n * - When `nodeRef` prop is used, `node` is not passed to callback functions\n * (e.g. `onEnter`) because user already has direct access to the node.\n * - When changing `key` prop of `Transition` in a `TransitionGroup` a new\n * `nodeRef` need to be provided to `Transition` with changed `key` prop\n * (see\n * [test/CSSTransition-test.js](https://github.com/reactjs/react-transition-group/blob/13435f897b3ab71f6e19d724f145596f5910581c/test/CSSTransition-test.js#L362-L437)).\n */\n nodeRef: PropTypes.shape({\n current: typeof Element === 'undefined' ? PropTypes.any : function (propValue, key, componentName, location, propFullName, secret) {\n var value = propValue[key];\n return PropTypes.instanceOf(value && 'ownerDocument' in value ? value.ownerDocument.defaultView.Element : Element)(propValue, key, componentName, location, propFullName, secret);\n }\n }),\n\n /**\n * A `function` child can be used instead of a React element. This function is\n * called with the current transition status (`'entering'`, `'entered'`,\n * `'exiting'`, `'exited'`), which can be used to apply context\n * specific props to a component.\n *\n * ```jsx\n * \n * {state => (\n * \n * )}\n * \n * ```\n */\n children: PropTypes.oneOfType([PropTypes.func.isRequired, PropTypes.element.isRequired]).isRequired,\n\n /**\n * Show the component; triggers the enter or exit states\n */\n in: PropTypes.bool,\n\n /**\n * By default the child component is mounted immediately along with\n * the parent `Transition` component. If you want to \"lazy mount\" the component on the\n * first `in={true}` you can set `mountOnEnter`. After the first enter transition the component will stay\n * mounted, even on \"exited\", unless you also specify `unmountOnExit`.\n */\n mountOnEnter: PropTypes.bool,\n\n /**\n * By default the child component stays mounted after it reaches the `'exited'` state.\n * Set `unmountOnExit` if you'd prefer to unmount the component after it finishes exiting.\n */\n unmountOnExit: PropTypes.bool,\n\n /**\n * By default the child component does not perform the enter transition when\n * it first mounts, regardless of the value of `in`. If you want this\n * behavior, set both `appear` and `in` to `true`.\n *\n * > **Note**: there are no special appear states like `appearing`/`appeared`, this prop\n * > only adds an additional enter transition. However, in the\n * > `` component that first enter transition does result in\n * > additional `.appear-*` classes, that way you can choose to style it\n * > differently.\n */\n appear: PropTypes.bool,\n\n /**\n * Enable or disable enter transitions.\n */\n enter: PropTypes.bool,\n\n /**\n * Enable or disable exit transitions.\n */\n exit: PropTypes.bool,\n\n /**\n * The duration of the transition, in milliseconds.\n * Required unless `addEndListener` is provided.\n *\n * You may specify a single timeout for all transitions:\n *\n * ```jsx\n * timeout={500}\n * ```\n *\n * or individually:\n *\n * ```jsx\n * timeout={{\n * appear: 500,\n * enter: 300,\n * exit: 500,\n * }}\n * ```\n *\n * - `appear` defaults to the value of `enter`\n * - `enter` defaults to `0`\n * - `exit` defaults to `0`\n *\n * @type {number | { enter?: number, exit?: number, appear?: number }}\n */\n timeout: function timeout(props) {\n var pt = timeoutsShape;\n if (!props.addEndListener) pt = pt.isRequired;\n\n for (var _len = arguments.length, args = new Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) {\n args[_key - 1] = arguments[_key];\n }\n\n return pt.apply(void 0, [props].concat(args));\n },\n\n /**\n * Add a custom transition end trigger. Called with the transitioning\n * DOM node and a `done` callback. Allows for more fine grained transition end\n * logic. Timeouts are still used as a fallback if provided.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * ```jsx\n * addEndListener={(node, done) => {\n * // use the css transitionend event to mark the finish of a transition\n * node.addEventListener('transitionend', done, false);\n * }}\n * ```\n */\n addEndListener: PropTypes.func,\n\n /**\n * Callback fired before the \"entering\" status is applied. An extra parameter\n * `isAppearing` is supplied to indicate if the enter stage is occurring on the initial mount\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement, isAppearing: bool) -> void\n */\n onEnter: PropTypes.func,\n\n /**\n * Callback fired after the \"entering\" status is applied. An extra parameter\n * `isAppearing` is supplied to indicate if the enter stage is occurring on the initial mount\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement, isAppearing: bool)\n */\n onEntering: PropTypes.func,\n\n /**\n * Callback fired after the \"entered\" status is applied. An extra parameter\n * `isAppearing` is supplied to indicate if the enter stage is occurring on the initial mount\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement, isAppearing: bool) -> void\n */\n onEntered: PropTypes.func,\n\n /**\n * Callback fired before the \"exiting\" status is applied.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement) -> void\n */\n onExit: PropTypes.func,\n\n /**\n * Callback fired after the \"exiting\" status is applied.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement) -> void\n */\n onExiting: PropTypes.func,\n\n /**\n * Callback fired after the \"exited\" status is applied.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed\n *\n * @type Function(node: HtmlElement) -> void\n */\n onExited: PropTypes.func\n} : {}; // Name the function so it is clearer in the documentation\n\nfunction noop() {}\n\nTransition.defaultProps = {\n in: false,\n mountOnEnter: false,\n unmountOnExit: false,\n appear: false,\n enter: true,\n exit: true,\n onEnter: noop,\n onEntering: noop,\n onEntered: noop,\n onExit: noop,\n onExiting: noop,\n onExited: noop\n};\nTransition.UNMOUNTED = UNMOUNTED;\nTransition.EXITED = EXITED;\nTransition.ENTERING = ENTERING;\nTransition.ENTERED = ENTERED;\nTransition.EXITING = EXITING;\nexport default Transition;","export const reflow = node => node.scrollTop;\nexport function getTransitionProps(props, options) {\n var _style$transitionDura, _style$transitionTimi;\n const {\n timeout,\n easing,\n style = {}\n } = props;\n return {\n duration: (_style$transitionDura = style.transitionDuration) != null ? _style$transitionDura : typeof timeout === 'number' ? timeout : timeout[options.mode] || 0,\n easing: (_style$transitionTimi = style.transitionTimingFunction) != null ? _style$transitionTimi : typeof easing === 'object' ? easing[options.mode] : easing,\n delay: style.transitionDelay\n };\n}","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"addEndListener\", \"appear\", \"children\", \"easing\", \"in\", \"onEnter\", \"onEntered\", \"onEntering\", \"onExit\", \"onExited\", \"onExiting\", \"style\", \"timeout\", \"TransitionComponent\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport { elementAcceptingRef, unstable_useTimeout as useTimeout } from '@mui/utils';\nimport { Transition } from 'react-transition-group';\nimport useTheme from '../styles/useTheme';\nimport { getTransitionProps, reflow } from '../transitions/utils';\nimport useForkRef from '../utils/useForkRef';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nfunction getScale(value) {\n return `scale(${value}, ${value ** 2})`;\n}\nconst styles = {\n entering: {\n opacity: 1,\n transform: getScale(1)\n },\n entered: {\n opacity: 1,\n transform: 'none'\n }\n};\n\n/*\n TODO v6: remove\n Conditionally apply a workaround for the CSS transition bug in Safari 15.4 / WebKit browsers.\n */\nconst isWebKit154 = typeof navigator !== 'undefined' && /^((?!chrome|android).)*(safari|mobile)/i.test(navigator.userAgent) && /(os |version\\/)15(.|_)4/i.test(navigator.userAgent);\n\n/**\n * The Grow transition is used by the [Tooltip](/material-ui/react-tooltip/) and\n * [Popover](/material-ui/react-popover/) components.\n * It uses [react-transition-group](https://github.com/reactjs/react-transition-group) internally.\n */\nconst Grow = /*#__PURE__*/React.forwardRef(function Grow(props, ref) {\n const {\n addEndListener,\n appear = true,\n children,\n easing,\n in: inProp,\n onEnter,\n onEntered,\n onEntering,\n onExit,\n onExited,\n onExiting,\n style,\n timeout = 'auto',\n // eslint-disable-next-line react/prop-types\n TransitionComponent = Transition\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const timer = useTimeout();\n const autoTimeout = React.useRef();\n const theme = useTheme();\n const nodeRef = React.useRef(null);\n const handleRef = useForkRef(nodeRef, children.ref, ref);\n const normalizedTransitionCallback = callback => maybeIsAppearing => {\n if (callback) {\n const node = nodeRef.current;\n\n // onEnterXxx and onExitXxx callbacks have a different arguments.length value.\n if (maybeIsAppearing === undefined) {\n callback(node);\n } else {\n callback(node, maybeIsAppearing);\n }\n }\n };\n const handleEntering = normalizedTransitionCallback(onEntering);\n const handleEnter = normalizedTransitionCallback((node, isAppearing) => {\n reflow(node); // So the animation always start from the start.\n\n const {\n duration: transitionDuration,\n delay,\n easing: transitionTimingFunction\n } = getTransitionProps({\n style,\n timeout,\n easing\n }, {\n mode: 'enter'\n });\n let duration;\n if (timeout === 'auto') {\n duration = theme.transitions.getAutoHeightDuration(node.clientHeight);\n autoTimeout.current = duration;\n } else {\n duration = transitionDuration;\n }\n node.style.transition = [theme.transitions.create('opacity', {\n duration,\n delay\n }), theme.transitions.create('transform', {\n duration: isWebKit154 ? duration : duration * 0.666,\n delay,\n easing: transitionTimingFunction\n })].join(',');\n if (onEnter) {\n onEnter(node, isAppearing);\n }\n });\n const handleEntered = normalizedTransitionCallback(onEntered);\n const handleExiting = normalizedTransitionCallback(onExiting);\n const handleExit = normalizedTransitionCallback(node => {\n const {\n duration: transitionDuration,\n delay,\n easing: transitionTimingFunction\n } = getTransitionProps({\n style,\n timeout,\n easing\n }, {\n mode: 'exit'\n });\n let duration;\n if (timeout === 'auto') {\n duration = theme.transitions.getAutoHeightDuration(node.clientHeight);\n autoTimeout.current = duration;\n } else {\n duration = transitionDuration;\n }\n node.style.transition = [theme.transitions.create('opacity', {\n duration,\n delay\n }), theme.transitions.create('transform', {\n duration: isWebKit154 ? duration : duration * 0.666,\n delay: isWebKit154 ? delay : delay || duration * 0.333,\n easing: transitionTimingFunction\n })].join(',');\n node.style.opacity = 0;\n node.style.transform = getScale(0.75);\n if (onExit) {\n onExit(node);\n }\n });\n const handleExited = normalizedTransitionCallback(onExited);\n const handleAddEndListener = next => {\n if (timeout === 'auto') {\n timer.start(autoTimeout.current || 0, next);\n }\n if (addEndListener) {\n // Old call signature before `react-transition-group` implemented `nodeRef`\n addEndListener(nodeRef.current, next);\n }\n };\n return /*#__PURE__*/_jsx(TransitionComponent, _extends({\n appear: appear,\n in: inProp,\n nodeRef: nodeRef,\n onEnter: handleEnter,\n onEntered: handleEntered,\n onEntering: handleEntering,\n onExit: handleExit,\n onExited: handleExited,\n onExiting: handleExiting,\n addEndListener: handleAddEndListener,\n timeout: timeout === 'auto' ? null : timeout\n }, other, {\n children: (state, childProps) => {\n return /*#__PURE__*/React.cloneElement(children, _extends({\n style: _extends({\n opacity: 0,\n transform: getScale(0.75),\n visibility: state === 'exited' && !inProp ? 'hidden' : undefined\n }, styles[state], style, children.props.style),\n ref: handleRef\n }, childProps));\n }\n }));\n});\nprocess.env.NODE_ENV !== \"production\" ? Grow.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the d.ts file and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * Add a custom transition end trigger. Called with the transitioning DOM\n * node and a done callback. Allows for more fine grained transition end\n * logic. Note: Timeouts are still used as a fallback if provided.\n */\n addEndListener: PropTypes.func,\n /**\n * Perform the enter transition when it first mounts if `in` is also `true`.\n * Set this to `false` to disable this behavior.\n * @default true\n */\n appear: PropTypes.bool,\n /**\n * A single child content element.\n */\n children: elementAcceptingRef.isRequired,\n /**\n * The transition timing function.\n * You may specify a single easing or a object containing enter and exit values.\n */\n easing: PropTypes.oneOfType([PropTypes.shape({\n enter: PropTypes.string,\n exit: PropTypes.string\n }), PropTypes.string]),\n /**\n * If `true`, the component will transition in.\n */\n in: PropTypes.bool,\n /**\n * @ignore\n */\n onEnter: PropTypes.func,\n /**\n * @ignore\n */\n onEntered: PropTypes.func,\n /**\n * @ignore\n */\n onEntering: PropTypes.func,\n /**\n * @ignore\n */\n onExit: PropTypes.func,\n /**\n * @ignore\n */\n onExited: PropTypes.func,\n /**\n * @ignore\n */\n onExiting: PropTypes.func,\n /**\n * @ignore\n */\n style: PropTypes.object,\n /**\n * The duration for the transition, in milliseconds.\n * You may specify a single timeout for all transitions, or individually with an object.\n *\n * Set to 'auto' to automatically calculate transition time based on height.\n * @default 'auto'\n */\n timeout: PropTypes.oneOfType([PropTypes.oneOf(['auto']), PropTypes.number, PropTypes.shape({\n appear: PropTypes.number,\n enter: PropTypes.number,\n exit: PropTypes.number\n })])\n} : void 0;\nGrow.muiSupportAuto = true;\nexport default Grow;","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"anchorEl\", \"component\", \"components\", \"componentsProps\", \"container\", \"disablePortal\", \"keepMounted\", \"modifiers\", \"open\", \"placement\", \"popperOptions\", \"popperRef\", \"transition\", \"slots\", \"slotProps\"];\nimport { Popper as BasePopper } from '@mui/base/Popper';\nimport { useThemeWithoutDefault as useTheme } from '@mui/system';\nimport { HTMLElementType, refType } from '@mui/utils';\nimport PropTypes from 'prop-types';\nimport * as React from 'react';\nimport { styled, useThemeProps } from '../styles';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nconst PopperRoot = styled(BasePopper, {\n name: 'MuiPopper',\n slot: 'Root',\n overridesResolver: (props, styles) => styles.root\n})({});\n\n/**\n *\n * Demos:\n *\n * - [Autocomplete](https://mui.com/material-ui/react-autocomplete/)\n * - [Menu](https://mui.com/material-ui/react-menu/)\n * - [Popper](https://mui.com/material-ui/react-popper/)\n *\n * API:\n *\n * - [Popper API](https://mui.com/material-ui/api/popper/)\n */\nconst Popper = /*#__PURE__*/React.forwardRef(function Popper(inProps, ref) {\n var _slots$root;\n const theme = useTheme();\n const props = useThemeProps({\n props: inProps,\n name: 'MuiPopper'\n });\n const {\n anchorEl,\n component,\n components,\n componentsProps,\n container,\n disablePortal,\n keepMounted,\n modifiers,\n open,\n placement,\n popperOptions,\n popperRef,\n transition,\n slots,\n slotProps\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const RootComponent = (_slots$root = slots == null ? void 0 : slots.root) != null ? _slots$root : components == null ? void 0 : components.Root;\n const otherProps = _extends({\n anchorEl,\n container,\n disablePortal,\n keepMounted,\n modifiers,\n open,\n placement,\n popperOptions,\n popperRef,\n transition\n }, other);\n return /*#__PURE__*/_jsx(PopperRoot, _extends({\n as: component,\n direction: theme == null ? void 0 : theme.direction,\n slots: {\n root: RootComponent\n },\n slotProps: slotProps != null ? slotProps : componentsProps\n }, otherProps, {\n ref: ref\n }));\n});\nprocess.env.NODE_ENV !== \"production\" ? Popper.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * An HTML element, [virtualElement](https://popper.js.org/docs/v2/virtual-elements/),\n * or a function that returns either.\n * It's used to set the position of the popper.\n * The return value will passed as the reference object of the Popper instance.\n */\n anchorEl: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.object, PropTypes.func]),\n /**\n * Popper render function or node.\n */\n children: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.node, PropTypes.func]),\n /**\n * The component used for the root node.\n * Either a string to use a HTML element or a component.\n */\n component: PropTypes.elementType,\n /**\n * The components used for each slot inside the Popper.\n * Either a string to use a HTML element or a component.\n * @default {}\n */\n components: PropTypes.shape({\n Root: PropTypes.elementType\n }),\n /**\n * The props used for each slot inside the Popper.\n * @default {}\n */\n componentsProps: PropTypes.shape({\n root: PropTypes.oneOfType([PropTypes.func, PropTypes.object])\n }),\n /**\n * An HTML element or function that returns one.\n * The `container` will have the portal children appended to it.\n *\n * You can also provide a callback, which is called in a React layout effect.\n * This lets you set the container from a ref, and also makes server-side rendering possible.\n *\n * By default, it uses the body of the top-level document object,\n * so it's simply `document.body` most of the time.\n */\n container: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.func]),\n /**\n * The `children` will be under the DOM hierarchy of the parent component.\n * @default false\n */\n disablePortal: PropTypes.bool,\n /**\n * Always keep the children in the DOM.\n * This prop can be useful in SEO situation or\n * when you want to maximize the responsiveness of the Popper.\n * @default false\n */\n keepMounted: PropTypes.bool,\n /**\n * Popper.js is based on a \"plugin-like\" architecture,\n * most of its features are fully encapsulated \"modifiers\".\n *\n * A modifier is a function that is called each time Popper.js needs to\n * compute the position of the popper.\n * For this reason, modifiers should be very performant to avoid bottlenecks.\n * To learn how to create a modifier, [read the modifiers documentation](https://popper.js.org/docs/v2/modifiers/).\n */\n modifiers: PropTypes.arrayOf(PropTypes.shape({\n data: PropTypes.object,\n effect: PropTypes.func,\n enabled: PropTypes.bool,\n fn: PropTypes.func,\n name: PropTypes.any,\n options: PropTypes.object,\n phase: PropTypes.oneOf(['afterMain', 'afterRead', 'afterWrite', 'beforeMain', 'beforeRead', 'beforeWrite', 'main', 'read', 'write']),\n requires: PropTypes.arrayOf(PropTypes.string),\n requiresIfExists: PropTypes.arrayOf(PropTypes.string)\n })),\n /**\n * If `true`, the component is shown.\n */\n open: PropTypes.bool.isRequired,\n /**\n * Popper placement.\n * @default 'bottom'\n */\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n /**\n * Options provided to the [`Popper.js`](https://popper.js.org/docs/v2/constructors/#options) instance.\n * @default {}\n */\n popperOptions: PropTypes.shape({\n modifiers: PropTypes.array,\n onFirstUpdate: PropTypes.func,\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n strategy: PropTypes.oneOf(['absolute', 'fixed'])\n }),\n /**\n * A ref that points to the used popper instance.\n */\n popperRef: refType,\n /**\n * The props used for each slot inside the Popper.\n * @default {}\n */\n slotProps: PropTypes.shape({\n root: PropTypes.oneOfType([PropTypes.func, PropTypes.object])\n }),\n /**\n * The components used for each slot inside the Popper.\n * Either a string to use a HTML element or a component.\n * @default {}\n */\n slots: PropTypes.shape({\n root: PropTypes.elementType\n }),\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Help supporting a react-transition-group/Transition component.\n * @default false\n */\n transition: PropTypes.bool\n} : void 0;\nexport default Popper;","import generateUtilityClasses from '@mui/utils/generateUtilityClasses';\nimport generateUtilityClass from '@mui/utils/generateUtilityClass';\nexport function getTooltipUtilityClass(slot) {\n return generateUtilityClass('MuiTooltip', slot);\n}\nconst tooltipClasses = generateUtilityClasses('MuiTooltip', ['popper', 'popperInteractive', 'popperArrow', 'popperClose', 'tooltip', 'tooltipArrow', 'touch', 'tooltipPlacementLeft', 'tooltipPlacementRight', 'tooltipPlacementTop', 'tooltipPlacementBottom', 'arrow']);\nexport default tooltipClasses;","'use client';\n\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nconst _excluded = [\"arrow\", \"children\", \"classes\", \"components\", \"componentsProps\", \"describeChild\", \"disableFocusListener\", \"disableHoverListener\", \"disableInteractive\", \"disableTouchListener\", \"enterDelay\", \"enterNextDelay\", \"enterTouchDelay\", \"followCursor\", \"id\", \"leaveDelay\", \"leaveTouchDelay\", \"onClose\", \"onOpen\", \"open\", \"placement\", \"PopperComponent\", \"PopperProps\", \"slotProps\", \"slots\", \"title\", \"TransitionComponent\", \"TransitionProps\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport clsx from 'clsx';\nimport { elementAcceptingRef, unstable_useTimeout as useTimeout, unstable_Timeout as Timeout } from '@mui/utils';\nimport { unstable_composeClasses as composeClasses, appendOwnerState } from '@mui/base';\nimport { alpha } from '@mui/system';\nimport styled from '../styles/styled';\nimport useTheme from '../styles/useTheme';\nimport useThemeProps from '../styles/useThemeProps';\nimport capitalize from '../utils/capitalize';\nimport Grow from '../Grow';\nimport Popper from '../Popper';\nimport useEventCallback from '../utils/useEventCallback';\nimport useForkRef from '../utils/useForkRef';\nimport useId from '../utils/useId';\nimport useIsFocusVisible from '../utils/useIsFocusVisible';\nimport useControlled from '../utils/useControlled';\nimport tooltipClasses, { getTooltipUtilityClass } from './tooltipClasses';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nimport { jsxs as _jsxs } from \"react/jsx-runtime\";\nfunction round(value) {\n return Math.round(value * 1e5) / 1e5;\n}\nconst useUtilityClasses = ownerState => {\n const {\n classes,\n disableInteractive,\n arrow,\n touch,\n placement\n } = ownerState;\n const slots = {\n popper: ['popper', !disableInteractive && 'popperInteractive', arrow && 'popperArrow'],\n tooltip: ['tooltip', arrow && 'tooltipArrow', touch && 'touch', `tooltipPlacement${capitalize(placement.split('-')[0])}`],\n arrow: ['arrow']\n };\n return composeClasses(slots, getTooltipUtilityClass, classes);\n};\nconst TooltipPopper = styled(Popper, {\n name: 'MuiTooltip',\n slot: 'Popper',\n overridesResolver: (props, styles) => {\n const {\n ownerState\n } = props;\n return [styles.popper, !ownerState.disableInteractive && styles.popperInteractive, ownerState.arrow && styles.popperArrow, !ownerState.open && styles.popperClose];\n }\n})(({\n theme,\n ownerState,\n open\n}) => _extends({\n zIndex: (theme.vars || theme).zIndex.tooltip,\n pointerEvents: 'none'\n}, !ownerState.disableInteractive && {\n pointerEvents: 'auto'\n}, !open && {\n pointerEvents: 'none'\n}, ownerState.arrow && {\n [`&[data-popper-placement*=\"bottom\"] .${tooltipClasses.arrow}`]: {\n top: 0,\n marginTop: '-0.71em',\n '&::before': {\n transformOrigin: '0 100%'\n }\n },\n [`&[data-popper-placement*=\"top\"] .${tooltipClasses.arrow}`]: {\n bottom: 0,\n marginBottom: '-0.71em',\n '&::before': {\n transformOrigin: '100% 0'\n }\n },\n [`&[data-popper-placement*=\"right\"] .${tooltipClasses.arrow}`]: _extends({}, !ownerState.isRtl ? {\n left: 0,\n marginLeft: '-0.71em'\n } : {\n right: 0,\n marginRight: '-0.71em'\n }, {\n height: '1em',\n width: '0.71em',\n '&::before': {\n transformOrigin: '100% 100%'\n }\n }),\n [`&[data-popper-placement*=\"left\"] .${tooltipClasses.arrow}`]: _extends({}, !ownerState.isRtl ? {\n right: 0,\n marginRight: '-0.71em'\n } : {\n left: 0,\n marginLeft: '-0.71em'\n }, {\n height: '1em',\n width: '0.71em',\n '&::before': {\n transformOrigin: '0 0'\n }\n })\n}));\nconst TooltipTooltip = styled('div', {\n name: 'MuiTooltip',\n slot: 'Tooltip',\n overridesResolver: (props, styles) => {\n const {\n ownerState\n } = props;\n return [styles.tooltip, ownerState.touch && styles.touch, ownerState.arrow && styles.tooltipArrow, styles[`tooltipPlacement${capitalize(ownerState.placement.split('-')[0])}`]];\n }\n})(({\n theme,\n ownerState\n}) => _extends({\n backgroundColor: theme.vars ? theme.vars.palette.Tooltip.bg : alpha(theme.palette.grey[700], 0.92),\n borderRadius: (theme.vars || theme).shape.borderRadius,\n color: (theme.vars || theme).palette.common.white,\n fontFamily: theme.typography.fontFamily,\n padding: '4px 8px',\n fontSize: theme.typography.pxToRem(11),\n maxWidth: 300,\n margin: 2,\n wordWrap: 'break-word',\n fontWeight: theme.typography.fontWeightMedium\n}, ownerState.arrow && {\n position: 'relative',\n margin: 0\n}, ownerState.touch && {\n padding: '8px 16px',\n fontSize: theme.typography.pxToRem(14),\n lineHeight: `${round(16 / 14)}em`,\n fontWeight: theme.typography.fontWeightRegular\n}, {\n [`.${tooltipClasses.popper}[data-popper-placement*=\"left\"] &`]: _extends({\n transformOrigin: 'right center'\n }, !ownerState.isRtl ? _extends({\n marginRight: '14px'\n }, ownerState.touch && {\n marginRight: '24px'\n }) : _extends({\n marginLeft: '14px'\n }, ownerState.touch && {\n marginLeft: '24px'\n })),\n [`.${tooltipClasses.popper}[data-popper-placement*=\"right\"] &`]: _extends({\n transformOrigin: 'left center'\n }, !ownerState.isRtl ? _extends({\n marginLeft: '14px'\n }, ownerState.touch && {\n marginLeft: '24px'\n }) : _extends({\n marginRight: '14px'\n }, ownerState.touch && {\n marginRight: '24px'\n })),\n [`.${tooltipClasses.popper}[data-popper-placement*=\"top\"] &`]: _extends({\n transformOrigin: 'center bottom',\n marginBottom: '14px'\n }, ownerState.touch && {\n marginBottom: '24px'\n }),\n [`.${tooltipClasses.popper}[data-popper-placement*=\"bottom\"] &`]: _extends({\n transformOrigin: 'center top',\n marginTop: '14px'\n }, ownerState.touch && {\n marginTop: '24px'\n })\n}));\nconst TooltipArrow = styled('span', {\n name: 'MuiTooltip',\n slot: 'Arrow',\n overridesResolver: (props, styles) => styles.arrow\n})(({\n theme\n}) => ({\n overflow: 'hidden',\n position: 'absolute',\n width: '1em',\n height: '0.71em' /* = width / sqrt(2) = (length of the hypotenuse) */,\n boxSizing: 'border-box',\n color: theme.vars ? theme.vars.palette.Tooltip.bg : alpha(theme.palette.grey[700], 0.9),\n '&::before': {\n content: '\"\"',\n margin: 'auto',\n display: 'block',\n width: '100%',\n height: '100%',\n backgroundColor: 'currentColor',\n transform: 'rotate(45deg)'\n }\n}));\nlet hystersisOpen = false;\nconst hystersisTimer = new Timeout();\nlet cursorPosition = {\n x: 0,\n y: 0\n};\nexport function testReset() {\n hystersisOpen = false;\n hystersisTimer.clear();\n}\nfunction composeEventHandler(handler, eventHandler) {\n return event => {\n if (eventHandler) {\n eventHandler(event);\n }\n handler(event);\n };\n}\n\n// TODO v6: Remove PopperComponent, PopperProps, TransitionComponent and TransitionProps.\nconst Tooltip = /*#__PURE__*/React.forwardRef(function Tooltip(inProps, ref) {\n var _ref, _slots$popper, _ref2, _ref3, _slots$transition, _ref4, _slots$tooltip, _ref5, _slots$arrow, _slotProps$popper, _ref6, _slotProps$popper2, _slotProps$transition, _slotProps$tooltip, _ref7, _slotProps$tooltip2, _slotProps$arrow, _ref8, _slotProps$arrow2;\n const props = useThemeProps({\n props: inProps,\n name: 'MuiTooltip'\n });\n const {\n arrow = false,\n children: childrenProp,\n components = {},\n componentsProps = {},\n describeChild = false,\n disableFocusListener = false,\n disableHoverListener = false,\n disableInteractive: disableInteractiveProp = false,\n disableTouchListener = false,\n enterDelay = 100,\n enterNextDelay = 0,\n enterTouchDelay = 700,\n followCursor = false,\n id: idProp,\n leaveDelay = 0,\n leaveTouchDelay = 1500,\n onClose,\n onOpen,\n open: openProp,\n placement = 'bottom',\n PopperComponent: PopperComponentProp,\n PopperProps = {},\n slotProps = {},\n slots = {},\n title,\n TransitionComponent: TransitionComponentProp = Grow,\n TransitionProps\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n\n // to prevent runtime errors, developers will need to provide a child as a React element anyway.\n const children = /*#__PURE__*/React.isValidElement(childrenProp) ? childrenProp : /*#__PURE__*/_jsx(\"span\", {\n children: childrenProp\n });\n const theme = useTheme();\n const isRtl = theme.direction === 'rtl';\n const [childNode, setChildNode] = React.useState();\n const [arrowRef, setArrowRef] = React.useState(null);\n const ignoreNonTouchEvents = React.useRef(false);\n const disableInteractive = disableInteractiveProp || followCursor;\n const closeTimer = useTimeout();\n const enterTimer = useTimeout();\n const leaveTimer = useTimeout();\n const touchTimer = useTimeout();\n const [openState, setOpenState] = useControlled({\n controlled: openProp,\n default: false,\n name: 'Tooltip',\n state: 'open'\n });\n let open = openState;\n if (process.env.NODE_ENV !== 'production') {\n // eslint-disable-next-line react-hooks/rules-of-hooks\n const {\n current: isControlled\n } = React.useRef(openProp !== undefined);\n\n // eslint-disable-next-line react-hooks/rules-of-hooks\n React.useEffect(() => {\n if (childNode && childNode.disabled && !isControlled && title !== '' && childNode.tagName.toLowerCase() === 'button') {\n console.error(['MUI: You are providing a disabled `button` child to the Tooltip component.', 'A disabled element does not fire events.', \"Tooltip needs to listen to the child element's events to display the title.\", '', 'Add a simple wrapper element, such as a `span`.'].join('\\n'));\n }\n }, [title, childNode, isControlled]);\n }\n const id = useId(idProp);\n const prevUserSelect = React.useRef();\n const stopTouchInteraction = useEventCallback(() => {\n if (prevUserSelect.current !== undefined) {\n document.body.style.WebkitUserSelect = prevUserSelect.current;\n prevUserSelect.current = undefined;\n }\n touchTimer.clear();\n });\n React.useEffect(() => stopTouchInteraction, [stopTouchInteraction]);\n const handleOpen = event => {\n hystersisTimer.clear();\n hystersisOpen = true;\n\n // The mouseover event will trigger for every nested element in the tooltip.\n // We can skip rerendering when the tooltip is already open.\n // We are using the mouseover event instead of the mouseenter event to fix a hide/show issue.\n setOpenState(true);\n if (onOpen && !open) {\n onOpen(event);\n }\n };\n const handleClose = useEventCallback(\n /**\n * @param {React.SyntheticEvent | Event} event\n */\n event => {\n hystersisTimer.start(800 + leaveDelay, () => {\n hystersisOpen = false;\n });\n setOpenState(false);\n if (onClose && open) {\n onClose(event);\n }\n closeTimer.start(theme.transitions.duration.shortest, () => {\n ignoreNonTouchEvents.current = false;\n });\n });\n const handleEnter = event => {\n if (ignoreNonTouchEvents.current && event.type !== 'touchstart') {\n return;\n }\n\n // Remove the title ahead of time.\n // We don't want to wait for the next render commit.\n // We would risk displaying two tooltips at the same time (native + this one).\n if (childNode) {\n childNode.removeAttribute('title');\n }\n enterTimer.clear();\n leaveTimer.clear();\n if (enterDelay || hystersisOpen && enterNextDelay) {\n enterTimer.start(hystersisOpen ? enterNextDelay : enterDelay, () => {\n handleOpen(event);\n });\n } else {\n handleOpen(event);\n }\n };\n const handleLeave = event => {\n enterTimer.clear();\n leaveTimer.start(leaveDelay, () => {\n handleClose(event);\n });\n };\n const {\n isFocusVisibleRef,\n onBlur: handleBlurVisible,\n onFocus: handleFocusVisible,\n ref: focusVisibleRef\n } = useIsFocusVisible();\n // We don't necessarily care about the focusVisible state (which is safe to access via ref anyway).\n // We just need to re-render the Tooltip if the focus-visible state changes.\n const [, setChildIsFocusVisible] = React.useState(false);\n const handleBlur = event => {\n handleBlurVisible(event);\n if (isFocusVisibleRef.current === false) {\n setChildIsFocusVisible(false);\n handleLeave(event);\n }\n };\n const handleFocus = event => {\n // Workaround for https://github.com/facebook/react/issues/7769\n // The autoFocus of React might trigger the event before the componentDidMount.\n // We need to account for this eventuality.\n if (!childNode) {\n setChildNode(event.currentTarget);\n }\n handleFocusVisible(event);\n if (isFocusVisibleRef.current === true) {\n setChildIsFocusVisible(true);\n handleEnter(event);\n }\n };\n const detectTouchStart = event => {\n ignoreNonTouchEvents.current = true;\n const childrenProps = children.props;\n if (childrenProps.onTouchStart) {\n childrenProps.onTouchStart(event);\n }\n };\n const handleMouseOver = handleEnter;\n const handleMouseLeave = handleLeave;\n const handleTouchStart = event => {\n detectTouchStart(event);\n leaveTimer.clear();\n closeTimer.clear();\n stopTouchInteraction();\n prevUserSelect.current = document.body.style.WebkitUserSelect;\n // Prevent iOS text selection on long-tap.\n document.body.style.WebkitUserSelect = 'none';\n touchTimer.start(enterTouchDelay, () => {\n document.body.style.WebkitUserSelect = prevUserSelect.current;\n handleEnter(event);\n });\n };\n const handleTouchEnd = event => {\n if (children.props.onTouchEnd) {\n children.props.onTouchEnd(event);\n }\n stopTouchInteraction();\n leaveTimer.start(leaveTouchDelay, () => {\n handleClose(event);\n });\n };\n React.useEffect(() => {\n if (!open) {\n return undefined;\n }\n\n /**\n * @param {KeyboardEvent} nativeEvent\n */\n function handleKeyDown(nativeEvent) {\n // IE11, Edge (prior to using Bink?) use 'Esc'\n if (nativeEvent.key === 'Escape' || nativeEvent.key === 'Esc') {\n handleClose(nativeEvent);\n }\n }\n document.addEventListener('keydown', handleKeyDown);\n return () => {\n document.removeEventListener('keydown', handleKeyDown);\n };\n }, [handleClose, open]);\n const handleRef = useForkRef(children.ref, focusVisibleRef, setChildNode, ref);\n\n // There is no point in displaying an empty tooltip.\n // So we exclude all falsy values, except 0, which is valid.\n if (!title && title !== 0) {\n open = false;\n }\n const popperRef = React.useRef();\n const handleMouseMove = event => {\n const childrenProps = children.props;\n if (childrenProps.onMouseMove) {\n childrenProps.onMouseMove(event);\n }\n cursorPosition = {\n x: event.clientX,\n y: event.clientY\n };\n if (popperRef.current) {\n popperRef.current.update();\n }\n };\n const nameOrDescProps = {};\n const titleIsString = typeof title === 'string';\n if (describeChild) {\n nameOrDescProps.title = !open && titleIsString && !disableHoverListener ? title : null;\n nameOrDescProps['aria-describedby'] = open ? id : null;\n } else {\n nameOrDescProps['aria-label'] = titleIsString ? title : null;\n nameOrDescProps['aria-labelledby'] = open && !titleIsString ? id : null;\n }\n const childrenProps = _extends({}, nameOrDescProps, other, children.props, {\n className: clsx(other.className, children.props.className),\n onTouchStart: detectTouchStart,\n ref: handleRef\n }, followCursor ? {\n onMouseMove: handleMouseMove\n } : {});\n if (process.env.NODE_ENV !== 'production') {\n childrenProps['data-mui-internal-clone-element'] = true;\n\n // eslint-disable-next-line react-hooks/rules-of-hooks\n React.useEffect(() => {\n if (childNode && !childNode.getAttribute('data-mui-internal-clone-element')) {\n console.error(['MUI: The `children` component of the Tooltip is not forwarding its props correctly.', 'Please make sure that props are spread on the same element that the ref is applied to.'].join('\\n'));\n }\n }, [childNode]);\n }\n const interactiveWrapperListeners = {};\n if (!disableTouchListener) {\n childrenProps.onTouchStart = handleTouchStart;\n childrenProps.onTouchEnd = handleTouchEnd;\n }\n if (!disableHoverListener) {\n childrenProps.onMouseOver = composeEventHandler(handleMouseOver, childrenProps.onMouseOver);\n childrenProps.onMouseLeave = composeEventHandler(handleMouseLeave, childrenProps.onMouseLeave);\n if (!disableInteractive) {\n interactiveWrapperListeners.onMouseOver = handleMouseOver;\n interactiveWrapperListeners.onMouseLeave = handleMouseLeave;\n }\n }\n if (!disableFocusListener) {\n childrenProps.onFocus = composeEventHandler(handleFocus, childrenProps.onFocus);\n childrenProps.onBlur = composeEventHandler(handleBlur, childrenProps.onBlur);\n if (!disableInteractive) {\n interactiveWrapperListeners.onFocus = handleFocus;\n interactiveWrapperListeners.onBlur = handleBlur;\n }\n }\n if (process.env.NODE_ENV !== 'production') {\n if (children.props.title) {\n console.error(['MUI: You have provided a `title` prop to the child of .', `Remove this title prop \\`${children.props.title}\\` or the Tooltip component.`].join('\\n'));\n }\n }\n const popperOptions = React.useMemo(() => {\n var _PopperProps$popperOp;\n let tooltipModifiers = [{\n name: 'arrow',\n enabled: Boolean(arrowRef),\n options: {\n element: arrowRef,\n padding: 4\n }\n }];\n if ((_PopperProps$popperOp = PopperProps.popperOptions) != null && _PopperProps$popperOp.modifiers) {\n tooltipModifiers = tooltipModifiers.concat(PopperProps.popperOptions.modifiers);\n }\n return _extends({}, PopperProps.popperOptions, {\n modifiers: tooltipModifiers\n });\n }, [arrowRef, PopperProps]);\n const ownerState = _extends({}, props, {\n isRtl,\n arrow,\n disableInteractive,\n placement,\n PopperComponentProp,\n touch: ignoreNonTouchEvents.current\n });\n const classes = useUtilityClasses(ownerState);\n const PopperComponent = (_ref = (_slots$popper = slots.popper) != null ? _slots$popper : components.Popper) != null ? _ref : TooltipPopper;\n const TransitionComponent = (_ref2 = (_ref3 = (_slots$transition = slots.transition) != null ? _slots$transition : components.Transition) != null ? _ref3 : TransitionComponentProp) != null ? _ref2 : Grow;\n const TooltipComponent = (_ref4 = (_slots$tooltip = slots.tooltip) != null ? _slots$tooltip : components.Tooltip) != null ? _ref4 : TooltipTooltip;\n const ArrowComponent = (_ref5 = (_slots$arrow = slots.arrow) != null ? _slots$arrow : components.Arrow) != null ? _ref5 : TooltipArrow;\n const popperProps = appendOwnerState(PopperComponent, _extends({}, PopperProps, (_slotProps$popper = slotProps.popper) != null ? _slotProps$popper : componentsProps.popper, {\n className: clsx(classes.popper, PopperProps == null ? void 0 : PopperProps.className, (_ref6 = (_slotProps$popper2 = slotProps.popper) != null ? _slotProps$popper2 : componentsProps.popper) == null ? void 0 : _ref6.className)\n }), ownerState);\n const transitionProps = appendOwnerState(TransitionComponent, _extends({}, TransitionProps, (_slotProps$transition = slotProps.transition) != null ? _slotProps$transition : componentsProps.transition), ownerState);\n const tooltipProps = appendOwnerState(TooltipComponent, _extends({}, (_slotProps$tooltip = slotProps.tooltip) != null ? _slotProps$tooltip : componentsProps.tooltip, {\n className: clsx(classes.tooltip, (_ref7 = (_slotProps$tooltip2 = slotProps.tooltip) != null ? _slotProps$tooltip2 : componentsProps.tooltip) == null ? void 0 : _ref7.className)\n }), ownerState);\n const tooltipArrowProps = appendOwnerState(ArrowComponent, _extends({}, (_slotProps$arrow = slotProps.arrow) != null ? _slotProps$arrow : componentsProps.arrow, {\n className: clsx(classes.arrow, (_ref8 = (_slotProps$arrow2 = slotProps.arrow) != null ? _slotProps$arrow2 : componentsProps.arrow) == null ? void 0 : _ref8.className)\n }), ownerState);\n return /*#__PURE__*/_jsxs(React.Fragment, {\n children: [/*#__PURE__*/React.cloneElement(children, childrenProps), /*#__PURE__*/_jsx(PopperComponent, _extends({\n as: PopperComponentProp != null ? PopperComponentProp : Popper,\n placement: placement,\n anchorEl: followCursor ? {\n getBoundingClientRect: () => ({\n top: cursorPosition.y,\n left: cursorPosition.x,\n right: cursorPosition.x,\n bottom: cursorPosition.y,\n width: 0,\n height: 0\n })\n } : childNode,\n popperRef: popperRef,\n open: childNode ? open : false,\n id: id,\n transition: true\n }, interactiveWrapperListeners, popperProps, {\n popperOptions: popperOptions,\n children: ({\n TransitionProps: TransitionPropsInner\n }) => /*#__PURE__*/_jsx(TransitionComponent, _extends({\n timeout: theme.transitions.duration.shorter\n }, TransitionPropsInner, transitionProps, {\n children: /*#__PURE__*/_jsxs(TooltipComponent, _extends({}, tooltipProps, {\n children: [title, arrow ? /*#__PURE__*/_jsx(ArrowComponent, _extends({}, tooltipArrowProps, {\n ref: setArrowRef\n })) : null]\n }))\n }))\n }))]\n });\n});\nprocess.env.NODE_ENV !== \"production\" ? Tooltip.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the d.ts file and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * If `true`, adds an arrow to the tooltip.\n * @default false\n */\n arrow: PropTypes.bool,\n /**\n * Tooltip reference element.\n */\n children: elementAcceptingRef.isRequired,\n /**\n * Override or extend the styles applied to the component.\n */\n classes: PropTypes.object,\n /**\n * @ignore\n */\n className: PropTypes.string,\n /**\n * The components used for each slot inside.\n *\n * This prop is an alias for the `slots` prop.\n * It's recommended to use the `slots` prop instead.\n *\n * @default {}\n */\n components: PropTypes.shape({\n Arrow: PropTypes.elementType,\n Popper: PropTypes.elementType,\n Tooltip: PropTypes.elementType,\n Transition: PropTypes.elementType\n }),\n /**\n * The extra props for the slot components.\n * You can override the existing props or add new ones.\n *\n * This prop is an alias for the `slotProps` prop.\n * It's recommended to use the `slotProps` prop instead, as `componentsProps` will be deprecated in the future.\n *\n * @default {}\n */\n componentsProps: PropTypes.shape({\n arrow: PropTypes.object,\n popper: PropTypes.object,\n tooltip: PropTypes.object,\n transition: PropTypes.object\n }),\n /**\n * Set to `true` if the `title` acts as an accessible description.\n * By default the `title` acts as an accessible label for the child.\n * @default false\n */\n describeChild: PropTypes.bool,\n /**\n * Do not respond to focus-visible events.\n * @default false\n */\n disableFocusListener: PropTypes.bool,\n /**\n * Do not respond to hover events.\n * @default false\n */\n disableHoverListener: PropTypes.bool,\n /**\n * Makes a tooltip not interactive, i.e. it will close when the user\n * hovers over the tooltip before the `leaveDelay` is expired.\n * @default false\n */\n disableInteractive: PropTypes.bool,\n /**\n * Do not respond to long press touch events.\n * @default false\n */\n disableTouchListener: PropTypes.bool,\n /**\n * The number of milliseconds to wait before showing the tooltip.\n * This prop won't impact the enter touch delay (`enterTouchDelay`).\n * @default 100\n */\n enterDelay: PropTypes.number,\n /**\n * The number of milliseconds to wait before showing the tooltip when one was already recently opened.\n * @default 0\n */\n enterNextDelay: PropTypes.number,\n /**\n * The number of milliseconds a user must touch the element before showing the tooltip.\n * @default 700\n */\n enterTouchDelay: PropTypes.number,\n /**\n * If `true`, the tooltip follow the cursor over the wrapped element.\n * @default false\n */\n followCursor: PropTypes.bool,\n /**\n * This prop is used to help implement the accessibility logic.\n * If you don't provide this prop. It falls back to a randomly generated id.\n */\n id: PropTypes.string,\n /**\n * The number of milliseconds to wait before hiding the tooltip.\n * This prop won't impact the leave touch delay (`leaveTouchDelay`).\n * @default 0\n */\n leaveDelay: PropTypes.number,\n /**\n * The number of milliseconds after the user stops touching an element before hiding the tooltip.\n * @default 1500\n */\n leaveTouchDelay: PropTypes.number,\n /**\n * Callback fired when the component requests to be closed.\n *\n * @param {React.SyntheticEvent} event The event source of the callback.\n */\n onClose: PropTypes.func,\n /**\n * Callback fired when the component requests to be open.\n *\n * @param {React.SyntheticEvent} event The event source of the callback.\n */\n onOpen: PropTypes.func,\n /**\n * If `true`, the component is shown.\n */\n open: PropTypes.bool,\n /**\n * Tooltip placement.\n * @default 'bottom'\n */\n placement: PropTypes.oneOf(['bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n /**\n * The component used for the popper.\n * @default Popper\n */\n PopperComponent: PropTypes.elementType,\n /**\n * Props applied to the [`Popper`](/material-ui/api/popper/) element.\n * @default {}\n */\n PopperProps: PropTypes.object,\n /**\n * The extra props for the slot components.\n * You can override the existing props or add new ones.\n *\n * This prop is an alias for the `componentsProps` prop, which will be deprecated in the future.\n *\n * @default {}\n */\n slotProps: PropTypes.shape({\n arrow: PropTypes.object,\n popper: PropTypes.object,\n tooltip: PropTypes.object,\n transition: PropTypes.object\n }),\n /**\n * The components used for each slot inside.\n *\n * This prop is an alias for the `components` prop, which will be deprecated in the future.\n *\n * @default {}\n */\n slots: PropTypes.shape({\n arrow: PropTypes.elementType,\n popper: PropTypes.elementType,\n tooltip: PropTypes.elementType,\n transition: PropTypes.elementType\n }),\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Tooltip title. Zero-length titles string, undefined, null and false are never displayed.\n */\n title: PropTypes.node,\n /**\n * The component used for the transition.\n * [Follow this guide](/material-ui/transitions/#transitioncomponent-prop) to learn more about the requirements for this component.\n * @default Grow\n */\n TransitionComponent: PropTypes.elementType,\n /**\n * Props applied to the transition element.\n * By default, the element is based on this [`Transition`](http://reactcommunity.org/react-transition-group/transition/) component.\n */\n TransitionProps: PropTypes.object\n} : void 0;\nexport default Tooltip;","import '@/components/mui/menu-item.component.css';\nimport ArrowRightIcon from '@mui/icons-material/ArrowRight';\nimport {\n ListItemIcon as MuiListItemIcon,\n ListItemText as MuiListItemText,\n MenuItem as MuiMenuItem,\n} from '@mui/material';\nimport Tooltip from '@mui/material/Tooltip';\nimport { Localized, ReferencedItem, SingleColumnMenu } from 'platform-bible-utils';\nimport { MouseEvent, PropsWithChildren } from 'react';\n\ntype MenuItemInfoBase = {\n /** Text (displayable in the UI) as the name of the menu item */\n label: string;\n /** Text to display when the mouse hovers over the menu item */\n tooltip?: string;\n};\n\nexport type Command = MenuItemInfoBase & {\n /** Command to execute (string.string) */\n command: string;\n};\n\ntype SubMenu = MenuItemInfoBase & {\n /** Command to execute (string.string) */\n items: MenuItemInfo[];\n};\n\nexport interface CommandHandler {\n (command: Command): void;\n}\n\nexport type MenuPropsBase = {\n /*\n * The JSON defining the menu whose items are to be rendered. This will typically be one of the\n * menus in the \"defs\" in a Platform.Bible menu (see PlatformMenus). The schema for this is\n * menuDocumentSchema (at the end of menus.model.ts). Note that while this is a\n * \"SingleColumnMenu\", somewhat bizarrely, a MultiColumnMenu is a SingleColumnMenu, so it really\n * could be a MultiColumnMenu, in which case, column had better be defined so it can be used\n * to filter out the actual groups and items to display on the column.\n */\n menuDefinition: Localized;\n\n commandHandler: CommandHandler;\n\n /**\n * Additional action to perform when any menu item is clicked. Allows the caller to handle event\n * (e.g., to close the menu).\n */\n onClick?: (event: MouseEvent) => void;\n};\n\nexport type MenuItemListProps = MenuPropsBase & {\n /** Optional unique (column) identifier */\n columnId?: ReferencedItem;\n};\n\nexport type MenuItemProps = Omit &\n PropsWithChildren<{\n /** Optional unique identifier */\n id?: string;\n\n onClick: (event: MouseEvent) => void;\n }>;\n\ntype MenuItemInfo = (Command | SubMenu) & {\n /**\n * If specified, menu item will be inset if it does not have a leading icon.\n *\n * @default true\n */\n allowForLeadingIcons?: boolean;\n /**\n * If specified, the path to the icon image to display on the leading side of the menu text.\n *\n * @default undefined (no leading icon will be shown)\n */\n iconPathBefore?: string;\n /**\n * If specified, the path to the icon image to display on the trailing side of the menu text.\n *\n * @default undefined (no trailing icon will be shown)\n */\n iconPathAfter?: string;\n /**\n * If true, list item is focused during the first mount\n *\n * @default false\n */\n hasAutoFocus?: boolean;\n\n /** Additional css classes to help with unique styling of the menu item */\n className?: string;\n\n /**\n * If true, the menu item will appear disabled and it will not respond to clicks or mouse hovers.\n *\n * @default false\n */\n isDisabled?: boolean;\n\n /**\n * If true, compact vertical padding designed for keyboard and mouse input is used.\n *\n * @default true\n */\n isDense?: boolean;\n\n /**\n * If true, a right-arrow icon will be displayed (iconPathAfter, if specified, will be ignored).\n *\n * @default false\n */\n isSubMenuParent?: boolean;\n\n /**\n * If true, the left and right padding is removed\n *\n * @default false\n */\n hasDisabledGutters?: boolean;\n\n /**\n * If true, a 1px light border is added to bottom of menu item\n *\n * @default false\n */\n hasDivider?: boolean;\n\n /** Help identify which element has keyboard focus */\n focusVisibleClassName?: string;\n\n /** If it's a submenu, it should have the items property */\n items?: MenuItemInfo[];\n};\n\nfunction getIcon(icon: string | undefined, menuLabel: string, leading: boolean) {\n return icon ? (\n \n {`${leading\n \n ) : undefined;\n}\n\nexport default function MenuItem(props: MenuItemProps) {\n const {\n onClick,\n label,\n tooltip,\n allowForLeadingIcons = true,\n iconPathBefore = undefined,\n iconPathAfter = undefined,\n hasAutoFocus = false,\n className,\n isDisabled = false,\n isDense = true,\n isSubMenuParent = false,\n hasDisabledGutters = false,\n hasDivider = false,\n focusVisibleClassName,\n id,\n children,\n } = props;\n\n const menuItem = (\n \n {label ? (\n <>\n {getIcon(iconPathBefore, label, true)}\n \n {isSubMenuParent ? (\n \n \n \n ) : (\n getIcon(iconPathAfter, label, false)\n )}\n \n ) : (\n children\n )}\n \n );\n\n return tooltip ? (\n \n
    {menuItem}
    \n
    \n ) : (\n menuItem\n );\n}\n","import MenuItem, {\n MenuItemListProps,\n MenuItemProps,\n MenuPropsBase,\n} from '@/components/mui/menu-item.component';\nimport { Menu } from '@mui/material';\nimport {\n Localized,\n MenuGroupDetailsInSubMenu,\n MenuItemContainingCommand,\n MenuItemContainingSubmenu,\n OrderedExtensibleContainer,\n ReferencedItem,\n SingleColumnMenu,\n} from 'platform-bible-utils';\nimport { MouseEvent, useMemo, useState } from 'react';\n\n/**\n * All the exported types in this file should be regarded as \"internal\" (i.e., they should not be\n * exposed via index.ts).\n */\n\nexport type GroupedMenuPropsBase = MenuPropsBase & {\n /** Optional unique (column) identifier */\n columnId?: ReferencedItem;\n};\n\nexport type GroupedMenuItemListProps = MenuItemListProps & {\n /**\n * If the menuDefinition includes \"top-level\" groups (i.e., those that belong to a column as\n * opposed to those that belong to a submenu) that should not be included in the list, then this\n * array specifies which groups to include. Likewise, for a submenu, this list indicates which\n * groups are pertinent for that submenu. So then for a context menu this property need not be\n * specified since it is a top-level menu based on a \"true\" SingleColumnMenu (i.e., one that is\n * not a MultiColumnMenu).\n */\n includedGroups?: {\n id: string;\n group: Localized;\n }[];\n};\n\ninterface ItemInfo {\n item: Localized;\n isLastItemInGroup: boolean;\n}\n\ntype SubMenuProps = MenuPropsBase & {\n parentMenuItem: Localized;\n parentItemProps: Omit, 'iconPathAfter'>;\n};\n\nfunction getAllGroups(menuDefinition: Localized) {\n const groupEntries = Object.entries(menuDefinition.groups);\n // Convert array of entries to array of objects with id and group properties\n return groupEntries.map(([key, value]) => ({ id: key, group: value }));\n}\n\nfunction SubMenu(props: SubMenuProps) {\n const [anchorEl, setAnchorEl] = useState(undefined);\n\n const { parentMenuItem, parentItemProps, menuDefinition } = props;\n\n const handleParentMenuItemClick = (event: MouseEvent) => {\n setAnchorEl(event.currentTarget);\n };\n\n const handleClose = () => {\n setAnchorEl(undefined);\n };\n\n const renderSubMenuItems = () => {\n let includedGroups = getAllGroups(menuDefinition).filter((g) => 'menuItem' in g.group);\n\n // Ensure valid parent menu was provided. (If not, submenu will contain all groups!)\n if (!parentMenuItem?.id) throw new Error('A valid parent menu item is required for submenus.');\n\n // When laying out a submenu, only include groups associated with the provided parent menu.\n // Note: without the (annoying) redundant check that the included groups\n // have the menuItem field, TS doesn't think it exists.\n includedGroups = includedGroups.filter(\n (group) => 'menuItem' in group.group && group.group.menuItem === parentMenuItem.id,\n );\n\n return ;\n };\n\n return (\n <>\n \n \n {renderSubMenuItems()}\n \n \n );\n}\n\nconst getOrderedGroupItems = (\n groupId: string,\n allItems: Localized[],\n) => {\n // Filter items that belong to the specified group\n const itemsForGroup = allItems.filter((item) => item.group === groupId);\n // Sort items based on order\n const sortedItems = itemsForGroup.sort((a, b) => (a.order || 0) - (b.order || 0));\n return sortedItems;\n};\n\n/**\n * This component is internal; it does not need to be exposed to the outside world since it is not\n * useful on its own. It is used to generate and lay out the MenuItems that appear either on a\n * top-level menu (in a GridMenu or ContextMenu) or in a submenu.\n */\nexport default function GroupedMenuItemList(menuProps: GroupedMenuItemListProps) {\n const { menuDefinition, onClick, commandHandler, includedGroups } = menuProps;\n\n const { items, allowForLeadingIcons } = useMemo(() => {\n const groupsToInclude =\n includedGroups && includedGroups.length > 0\n ? includedGroups\n : // We're apparently laying out a single-column menu (presumably a context menu). In this\n // case, all groups should be included except ones that belong to a submenu.\n getAllGroups(menuDefinition).filter((g) => !('menuItem' in g.group));\n\n const sortedGroups = Object.values(groupsToInclude).sort(\n (a, b) => (a.group.order || 0) - (b.group.order || 0),\n );\n\n const itemArray: ItemInfo[] = [];\n\n sortedGroups.forEach((group) => {\n getOrderedGroupItems(group.id, menuDefinition.items).forEach((item) =>\n itemArray.push({ item, isLastItemInGroup: false }),\n );\n if (itemArray.length > 0) itemArray[itemArray.length - 1].isLastItemInGroup = true;\n });\n\n // No divider after last item in final group.\n if (itemArray.length > 0) itemArray[itemArray.length - 1].isLastItemInGroup = false;\n\n const allowSpaceForLeadingIcons = itemArray.some(\n (i) => 'iconPathBefore' in i.item && i.item.iconPathBefore,\n );\n\n return { items: itemArray, allowForLeadingIcons: allowSpaceForLeadingIcons };\n }, [includedGroups, menuDefinition]);\n\n // Create props for MenuItem component including setting hasDivider for the last item in a group\n const createMenuItemProps = ({ item, isLastItemInGroup }: ItemInfo) => {\n const menuItemProps = {\n className: 'papi-menu-item',\n label: item.label,\n tooltip: item.tooltip,\n iconPathBefore: 'iconPathBefore' in item ? item.iconPathBefore : undefined,\n iconPathAfter: 'iconPathAfter' in item ? item.iconPathAfter : undefined,\n hasDivider: isLastItemInGroup, // Set hasDivider to true for the last item in a group\n allowForLeadingIcons,\n };\n\n return menuItemProps;\n };\n\n const [firstItem] = items;\n\n if (!firstItem) return
    ;\n\n const divKey = firstItem.item.group;\n\n return (\n
    \n {items.map((itemInfo, index) => {\n const { item } = itemInfo;\n const menuItemProps = createMenuItemProps(itemInfo);\n if ('command' in item) {\n const key = item.group + index;\n return (\n ) => {\n onClick?.(event);\n commandHandler(item);\n }}\n {...menuItemProps}\n />\n );\n }\n return (\n \n );\n })}\n
    \n );\n}\n","import GroupedMenuItemList from '@/components/mui/grouped-menu-item-list.component';\nimport { MenuItemListProps } from '@/components/mui/menu-item.component';\nimport { MultiColumnMenu } from 'platform-bible-utils';\n\n/**\n * This component is internal; it does not need to be exposed to the outside world since it is not\n * useful on its own. Use either GridMenu or ContextMenu.\n */\nexport default function TopLevelMenu(props: MenuItemListProps) {\n const { menuDefinition, columnId } = props;\n\n const groupEntries = Object.entries(menuDefinition.groups);\n // Convert array of entries to array of objects with id and group properties\n const groups = groupEntries.map(([key, value]) => ({ id: key, group: value }));\n let includedGroups = groups.filter((g) => 'column' in g.group);\n\n // Check if column is provided and menuDefinition is a MultiColumnMenu\n if (\n columnId &&\n 'columns' in menuDefinition &&\n // Without this type assertion, TS doesn't know what columns is.\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n (menuDefinition as MultiColumnMenu).columns[columnId]\n ) {\n // When laying out a single column in a MultiColumnMenu, only include groups associated with\n // the provided column. Note: without the (annoying) redundant check that the included groups\n // have the colum field, TS doesn't think it exists.\n includedGroups = includedGroups.filter(\n (g) => 'column' in g.group && g.group.column === columnId,\n );\n }\n\n return ;\n}\n","import '@/components/mui/grid-menu.component.css';\nimport { GroupedMenuPropsBase } from '@/components/mui/grouped-menu-item-list.component';\nimport { CommandHandler } from '@/components/mui/menu-item.component';\nimport TopLevelMenu from '@/components/mui/top-level-menu.component';\nimport { Grid, List } from '@mui/material';\nimport {\n Localized,\n MenuColumnWithHeader,\n MultiColumnMenu,\n ReferencedItem,\n} from 'platform-bible-utils';\nimport { useMemo } from 'react';\n\ntype ColumnInfo = {\n /*\n * The ID (`${string}.${string}`) of a specific menu column.\n */\n id: ReferencedItem;\n\n /*\n * Metadata (label, order, etc.) for a specific menu column.\n */\n metadata: Localized;\n};\n\ntype MenuColumnProps = ColumnInfo &\n GroupedMenuPropsBase & {\n /** Additional css classes to help with unique styling of the menu column */\n className?: string;\n };\n\nexport type GridMenuInfo = {\n /** The menu object containing information about the columns, groups, and items to display. */\n multiColumnMenu: Localized;\n};\n\nexport type GridMenuProps = GridMenuInfo & {\n /** Optional unique identifier */\n id?: string;\n\n commandHandler: CommandHandler;\n\n /** Additional css classes to help with unique styling of the grid menu */\n className?: string;\n};\n\nfunction MenuColumn({\n commandHandler,\n menuDefinition,\n id,\n metadata,\n onClick,\n className,\n}: MenuColumnProps) {\n return (\n \n

    \n {metadata.label}\n

    \n {/* It would seem as though this List component were unnecessary, since it only contains one\n thing, but the \"dense\" property does affect the layout of the items (in a way I don't fully\n understand). There might be a better way. */}\n \n \n \n \n );\n}\n\nexport default function GridMenu({\n commandHandler,\n className,\n multiColumnMenu,\n id,\n}: GridMenuProps) {\n const { columns } = multiColumnMenu;\n\n const sortedColumns = useMemo(() => {\n const columnNumbers = new Map();\n Object.getOwnPropertyNames(columns).forEach((columnName: string) => {\n // We know for sure there is a (boolean) property 'isExtensible' that we are not interested in.\n if (columnName === 'isExtensible') return;\n // TS doesn't allow `columnName` above to be a ReferencedItem even though the type says it is\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const columnId = columnName as ReferencedItem;\n const column = columns[columnId];\n // As of right now (and hopefully forever after), all remaining properties of the\n // ColumnsWithHeaders object are columns whose property names are the IDs of the columns.\n // This is an additional (redundant) sanity check. Specifically we're interested in\n // MenuColumnWithHeader objects, which TypeScript now \"knows\" we have, but at runtime all we\n // can check for is that it's an object with a valid numeric order field. That's likely good\n // enough.\n if (\n typeof column === 'object' &&\n typeof column.order === 'number' &&\n !Number.isNaN(column.order)\n )\n columnNumbers.set(column.order, { id: columnId, metadata: column });\n else\n console.warn(\n `Property ${columnName} (${typeof column}) on menu ${id} is not a valid column and is being ignored. This might indicate data corruption`,\n );\n });\n\n // Extract values and sort them based on the 'order' property\n return Array.from(columnNumbers.values()).sort((a, b) => {\n return (a.metadata.order || 0) - (b.metadata.order || 0);\n });\n }, [columns, id]);\n\n // We might need something like this if we need to be able to prevent empty columns\n // sortedColumns.filter((c) => multiColumnMenu.groups.some((g) => 'column' in g && (g as .column)...\n\n return (\n \n {sortedColumns.map((col, index) => (\n \n ))}\n \n );\n}\n","import { useEffect, useRef, useState } from 'react';\n\nexport type UsePromiseOptions = {\n /**\n * Whether to leave the value as the most recent resolved promise value or set it back to\n * defaultValue while running the promise again. Defaults to true\n */\n preserveValue?: boolean;\n};\n\n/** Set up defaults for options for usePromise hook */\nfunction getUsePromiseOptionsDefaults(options: UsePromiseOptions): UsePromiseOptions {\n return {\n preserveValue: true,\n ...options,\n };\n}\n\n/**\n * Awaits a promise and returns a loading value while the promise is unresolved\n *\n * @param promiseFactoryCallback A function that returns the promise to await. If this callback is\n * undefined, the current value will be returned (defaultValue unless it was previously changed\n * and `options.preserveValue` is true), and there will be no loading.\n *\n * WARNING: MUST BE STABLE - const or wrapped in useCallback. The reference must not be updated\n * every render\n * @param defaultValue The initial value to return while first awaiting the promise. If\n * `options.preserveValue` is false, this value is also shown while awaiting the promise on\n * subsequent calls.\n *\n * Note: this parameter is internally assigned to a `ref`, so changing it will not cause any hooks\n * to re-run with its new value. This means that, if the `promiseFactoryCallback` changes and\n * `options.preserveValue` is `false`, the returned value will be set to the current\n * `defaultValue`. However, the returned value will not be updated if`defaultValue` changes.\n * @param options Various options for adjusting how this hook runs the `promiseFactoryCallback`\n *\n * Note: this parameter is internally assigned to a `ref`, so changing it will not cause any hooks\n * to re-run with its new value. However, the latest `options.preserveValue` will always be used\n * appropriately to determine whether to preserve the returned value when changing the\n * `promiseFactoryCallback`\n * @returns `[value, isLoading]`\n *\n * - `value`: the current value for the promise, either the defaultValue or the resolved promise value\n * - `isLoading`: whether the promise is waiting to be resolved\n */\nconst usePromise = (\n promiseFactoryCallback: (() => Promise) | undefined,\n defaultValue: T,\n options: UsePromiseOptions = {},\n): [value: T, isLoading: boolean] => {\n // Use defaultValue as a ref so it doesn't update dependency arrays\n const defaultValueRef = useRef(defaultValue);\n defaultValueRef.current = defaultValue;\n // Use options as a ref so it doesn't update dependency arrays\n const optionsDefaultedRef = useRef(options);\n optionsDefaultedRef.current = getUsePromiseOptionsDefaults(optionsDefaultedRef.current);\n\n const [value, setValue] = useState(() => defaultValueRef.current);\n const [isLoading, setIsLoading] = useState(true);\n useEffect(() => {\n let promiseIsCurrent = true;\n // If a promiseFactoryCallback was provided, we are loading. Otherwise, there is no loading to do\n setIsLoading(!!promiseFactoryCallback);\n (async () => {\n // If there is a callback to run, run it\n if (promiseFactoryCallback) {\n const result = await promiseFactoryCallback();\n // If the promise was not already replaced, update the value\n if (promiseIsCurrent) {\n setValue(() => result);\n setIsLoading(false);\n }\n }\n })();\n\n return () => {\n // Mark this promise as old and not to be used\n promiseIsCurrent = false;\n if (!optionsDefaultedRef.current.preserveValue) setValue(() => defaultValueRef.current);\n };\n }, [promiseFactoryCallback]);\n\n return [value, isLoading];\n};\nexport default usePromise;\n","\"use client\";\n\nimport createSvgIcon from './utils/createSvgIcon';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nexport default createSvgIcon( /*#__PURE__*/_jsx(\"path\", {\n d: \"M3 18h18v-2H3zm0-5h18v-2H3zm0-7v2h18V6z\"\n}), 'Menu');","import GridMenu from '@/components/mui/grid-menu.component';\nimport { Command, CommandHandler } from '@/components/mui/menu-item.component';\nimport usePromise from '@/hooks/use-promise.hook';\nimport { Menu as MenuIcon } from '@mui/icons-material';\nimport { Drawer, IconButton } from '@mui/material';\nimport { Localized, MultiColumnMenu } from 'platform-bible-utils';\nimport {\n MouseEvent,\n MutableRefObject,\n PropsWithChildren,\n useCallback,\n useEffect,\n useState,\n} from 'react';\n\nexport interface MultiColumnMenuProvider {\n (isSupportAndDevelopment: boolean): Promise>;\n}\n\nexport type HamburgerMenuButtonProps = PropsWithChildren & {\n /** The handler to use for menu commands (and eventually toolbar commands). */\n commandHandler: CommandHandler;\n\n /**\n * Optional reference to the \"div\" container that determines the where the menu should appear. If\n * not defined, then (1,1) used.\n */\n containerRef?: MutableRefObject;\n\n /**\n * The delegate to use to get the menu data. If not specified or if it returns undefined, the data\n * in normalMenu or fullMenu property will be used.\n */\n menuProvider?: MultiColumnMenuProvider;\n\n /**\n * The menu data to show when the menu is opened if the menuProvider property is not defined.\n * (This allows for a default or test-only static menu to be used.)\n */\n normalMenu?: Localized;\n\n /**\n * The menu data to show for \"full\" menu (when opened with the SHIFT key pressed) if the\n * menuProvider property is not defined. (This allows for a default or test-only static menu to be\n * used.)\n */\n fullMenu?: Localized;\n\n /** Additional css class(es) to help with unique styling of the sub-components */\n className?: string;\n\n /** Value to use as prefix for ARIA labels on interactive sub-components */\n ariaLabelPrefix?: string;\n};\n\nexport default function HamburgerMenuButton({\n menuProvider,\n normalMenu,\n fullMenu,\n commandHandler,\n containerRef,\n className,\n ariaLabelPrefix,\n children,\n}: HamburgerMenuButtonProps) {\n const [isMenuOpen, setMenuOpen] = useState(false);\n const [showFullMenu, setShowFullMenu] = useState(false);\n\n const handleMenuItemClick = useCallback(() => {\n if (isMenuOpen) setMenuOpen(false);\n setShowFullMenu(false);\n }, [isMenuOpen]);\n\n const handleMenuButtonClick = useCallback((e: MouseEvent) => {\n e.stopPropagation();\n setMenuOpen((prevIsOpen) => {\n const isOpening = !prevIsOpen;\n if (isOpening && e.shiftKey) setShowFullMenu(true);\n else if (!isOpening) setShowFullMenu(false);\n return isOpening;\n });\n }, []);\n\n const menuCommandHandler = useCallback(\n (command: Command) => {\n handleMenuItemClick();\n return commandHandler(command);\n },\n [commandHandler, handleMenuItemClick],\n );\n\n const [offset, setOffset] = useState({ top: 1, left: 1 });\n\n useEffect(() => {\n if (isMenuOpen) {\n const node = containerRef?.current;\n if (node) {\n const rect = node.getBoundingClientRect();\n const scrollTop = window.scrollY;\n const scrollLeft = window.scrollX;\n const top = rect.top + scrollTop + node.clientHeight;\n const left = rect.left + scrollLeft;\n setOffset({ top, left });\n }\n }\n }, [isMenuOpen, containerRef]);\n\n const [normalMenuData] = usePromise(\n useCallback(async () => {\n return menuProvider?.(false) ?? normalMenu;\n // isMenuOpen needs to be included for the menu contents to reevaluate when reopened\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [menuProvider, normalMenu, isMenuOpen]),\n normalMenu,\n );\n\n const [fullMenuData] = usePromise(\n useCallback(async () => {\n return menuProvider?.(true) ?? fullMenu ?? normalMenuData;\n // isMenuOpen needs to be included for the menu contents to reevaluate when reopened\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [menuProvider, fullMenu, normalMenuData, isMenuOpen]),\n fullMenu ?? normalMenuData,\n );\n\n const menu = showFullMenu && fullMenuData ? fullMenuData : normalMenuData;\n\n return (\n <>\n \n {children ?? }\n \n \n {menu ? (\n \n ) : undefined}\n \n \n );\n}\n","import '@/components/mui/icon-button.component.css';\nimport { IconButton as MuiIconButton } from '@mui/material';\nimport { MouseEventHandler, PropsWithChildren } from 'react';\n\nexport type IconButtonProps = PropsWithChildren<{\n /** Optional unique identifier */\n id?: string;\n /**\n * Required. Used as both the tooltip (aka, title) and the aria-label (used for accessibility,\n * testing, etc.), unless a distinct tooltip is supplied.\n */\n label: string;\n /**\n * Enabled status of button\n *\n * @default false\n */\n isDisabled?: boolean;\n /** Optional tooltip to display if different from the aria-label. */\n tooltip?: string;\n /** If true, no tooltip will be displayed. */\n isTooltipSuppressed?: boolean;\n /**\n * If given, uses a negative margin to counteract the padding on one side (this is often helpful\n * for aligning the left or right side of the icon with content above or below, without ruining\n * the border size and shape).\n *\n * @default false\n */\n adjustMarginToAlignToEdge?: 'end' | 'start' | false;\n /**\n * The size of the component. small is equivalent to the dense button styling.\n *\n * @default false\n */\n size: 'small' | 'medium' | 'large';\n /** Additional css classes to help with unique styling of the button */\n className?: string;\n /** Optional click handler */\n onClick?: MouseEventHandler;\n}>;\n\n/**\n * Iconic button a user can click to do something\n *\n * Thanks to MUI for heavy inspiration and documentation\n * https://mui.com/material-ui/getting-started/overview/\n */\nfunction IconButton({\n id,\n label,\n isDisabled = false,\n tooltip,\n isTooltipSuppressed = false,\n adjustMarginToAlignToEdge = false,\n size = 'medium',\n className,\n onClick,\n children,\n}: IconButtonProps) {\n return (\n \n {children /* the icon to display */}\n \n );\n}\n\nexport default IconButton;\n","import { cn } from '@/utils/shadcn-ui.util';\nimport { LoaderCircle, LucideProps } from 'lucide-react';\nimport { forwardRef } from 'react';\n\nexport type SpinnerProps = LucideProps;\n\nconst Spinner = forwardRef(({ className, ...props }, ref) => {\n return (\n \n );\n});\n\nSpinner.displayName = 'Spinner';\n\nexport default Spinner;\n","import { Input as ShadInput } from '@/components/shadcn-ui/input';\nimport { Label as ShadLabel } from '@/components/shadcn-ui/label';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { ChangeEventHandler, FocusEventHandler } from 'react';\n\nexport type TextFieldProps = {\n /** Optional unique identifier */\n id?: string;\n /**\n * If `true`, the component is disabled.\n *\n * @default false\n */\n isDisabled?: boolean;\n /**\n * If `true`, the label is displayed in an error state.\n *\n * @default false\n */\n hasError?: boolean;\n /**\n * If `true`, the input will take up the full width of its container.\n *\n * @default false\n */\n isFullWidth?: boolean;\n /** Text that gives the user instructions on what contents the TextField expects */\n helperText?: string;\n /** The title of the TextField */\n label?: string;\n /** The short hint displayed in the `input` before the user enters a value. */\n placeholder?: string;\n /**\n * If `true`, the label is displayed as required and the `input` element is required.\n *\n * @default false\n */\n isRequired?: boolean;\n /** Additional css classes to help with unique styling of the text field */\n className?: string;\n /** Starting value for the text field if it is not controlled */\n defaultValue?: string | number;\n /** Value of the text field if controlled */\n value?: string | number;\n /** Triggers when content of textfield is changed */\n onChange?: ChangeEventHandler;\n /** Triggers when textfield gets focus */\n onFocus?: FocusEventHandler;\n /** Triggers when textfield loses focus */\n onBlur?: FocusEventHandler;\n};\n\n/**\n * Text input field\n *\n * Thanks to Shadcn for heavy inspiration and documentation\n * https://ui.shadcn.com/docs/components/input#with-label\n */\nfunction TextField({\n id,\n isDisabled = false,\n hasError = false,\n isFullWidth = false,\n helperText,\n label,\n placeholder,\n isRequired = false,\n className,\n defaultValue,\n value,\n onChange,\n onFocus,\n onBlur,\n}: TextFieldProps) {\n return (\n
    \n {`${label}${isRequired ? '*' : ''}`}\n \n

    {helperText}

    \n
    \n );\n}\n\nexport default TextField;\n","import HamburgerMenuButton, {\n MultiColumnMenuProvider,\n} from '@/components/mui/hamburger-menu-button.component';\nimport { CommandHandler } from '@/components/mui/menu-item.component';\nimport '@/components/mui/toolbar.component.css';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { AppBar, Toolbar as MuiToolbar } from '@mui/material';\nimport { PropsWithChildren, useRef } from 'react';\n\nexport type ToolbarProps = PropsWithChildren<{\n /** The handler to use for menu commands (and eventually toolbar commands). */\n commandHandler: CommandHandler;\n\n /**\n * The optional delegate to use to get the menu data. If not specified, the \"hamburger\" menu will\n * not display.\n */\n menuProvider?: MultiColumnMenuProvider;\n\n /** Optional unique identifier */\n id?: string;\n\n /** Additional css classes to help with unique styling of the toolbar */\n className?: string;\n}>;\n\nexport default function Toolbar({\n menuProvider,\n commandHandler,\n className,\n id,\n children,\n}: ToolbarProps) {\n // This ref will always be defined\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const containerRef = useRef(undefined!);\n\n return (\n
    \n \n \n {menuProvider ? (\n \n ) : undefined}\n {children ?
    {children}
    : undefined}\n \n
    \n
    \n );\n}\n","import React from 'react';\nimport { cva, type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst alertVariants = cva(\n 'tw-relative tw-w-full tw-rounded-lg tw-border tw-p-4 [&>svg~*]:tw-pl-7 [&>svg+div]:tw-translate-y-[-3px] [&>svg]:tw-absolute [&>svg]:tw-left-4 [&>svg]:tw-top-4 [&>svg]:tw-text-foreground',\n {\n variants: {\n variant: {\n default: 'tw-bg-background tw-text-foreground',\n destructive:\n 'tw-border-destructive/50 tw-text-destructive dark:tw-border-destructive [&>svg]:tw-text-destructive',\n },\n },\n defaultVariants: {\n variant: 'default',\n },\n },\n);\n\nconst Alert = React.forwardRef<\n HTMLDivElement,\n React.HTMLAttributes & VariantProps\n>(({ className, variant, ...props }, ref) => (\n
    \n));\nAlert.displayName = 'Alert';\n\nconst AlertTitle = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n {/* added because of https://github.com/jsx-eslint/eslint-plugin-jsx-a11y/blob/main/docs/rules/heading-has-content.md */}\n {props.children}{' '}\n \n ),\n);\nAlertTitle.displayName = 'AlertTitle';\n\nconst AlertDescription = React.forwardRef<\n HTMLParagraphElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n
    \n));\nAlertDescription.displayName = 'AlertDescription';\n\nexport { Alert, AlertTitle, AlertDescription };\n","import React from 'react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Card = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nCard.displayName = 'Card';\n\nconst CardHeader = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nCardHeader.displayName = 'CardHeader';\n\nconst CardTitle = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n {/* added because of https://github.com/jsx-eslint/eslint-plugin-jsx-a11y/blob/main/docs/rules/heading-has-content.md */}\n {props.children}\n \n ),\n);\nCardTitle.displayName = 'CardTitle';\n\nconst CardDescription = React.forwardRef<\n HTMLParagraphElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n

    \n));\nCardDescription.displayName = 'CardDescription';\n\nconst CardContent = React.forwardRef>(\n ({ className, ...props }, ref) => (\n

    \n ),\n);\nCardContent.displayName = 'CardContent';\n\nconst CardFooter = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nCardFooter.displayName = 'CardFooter';\n\nexport { Card, CardHeader, CardFooter, CardTitle, CardDescription, CardContent };\n","import { ComponentProps } from 'react';\nimport { toast as sonner, Toaster } from 'sonner';\n\ntype SonnerProps = ComponentProps;\n\nfunction Sonner({ ...props }: SonnerProps) {\n return (\n \n );\n}\n\n// The re-export of the sonner function was added manually\nexport { Sonner, sonner };\n","import React from 'react';\nimport * as SliderPrimitive from '@radix-ui/react-slider';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Slider = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n \n \n \n));\nSlider.displayName = SliderPrimitive.Root.displayName;\n\nexport { Slider };\n","import React from 'react';\nimport * as SwitchPrimitives from '@radix-ui/react-switch';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Switch = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n));\nSwitch.displayName = SwitchPrimitives.Root.displayName;\n\nexport { Switch };\n","import React from 'react';\nimport * as TabsPrimitive from '@radix-ui/react-tabs';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport const Tabs = TabsPrimitive.Root;\n\nexport type TabsListProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport type TabsTriggerProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport type TabsContentProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport const TabsList = React.forwardRef<\n React.ElementRef,\n TabsListProps\n>(({ className, ...props }, ref) => (\n \n));\nTabsList.displayName = TabsPrimitive.List.displayName;\n\nexport const TabsTrigger = React.forwardRef<\n React.ElementRef,\n TabsTriggerProps\n>(({ className, ...props }, ref) => (\n \n));\nTabsTrigger.displayName = TabsPrimitive.Trigger.displayName;\n\nexport const TabsContent = React.forwardRef<\n React.ElementRef,\n TabsContentProps\n>(({ className, ...props }, ref) => (\n \n));\nTabsContent.displayName = TabsPrimitive.Content.displayName;\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Download } from 'lucide-react';\n\ntype InstallButtonProps = {\n /** The installing boolean value determines the state of the button. */\n isInstalling: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n /** Optional text for the button. */\n buttonText?: string;\n} & ButtonProps;\n\n/**\n * The InstallButton component is a button designed for initiating installs. It includes visuals for\n * active installing and idle states.\n *\n * @param isInstalling The installing boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @param buttonText Optional text for the button.\n * @returns A install button.\n */\nexport default function InstallButton({\n isInstalling,\n handleClick,\n buttonText,\n className,\n ...props\n}: InstallButtonProps) {\n return (\n \n {isInstalling ? (\n \n ) : (\n <>\n \n {buttonText}\n \n )}\n \n );\n}\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\n\ntype EnableButtonProps = {\n /** The enabling boolean value determines the state of the button. */\n isEnabling: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n} & ButtonProps;\n\n/**\n * The EnableButton component is a button designed for initiating enabling of downloads. It includes\n * visuals for active enabling and idle states.\n *\n * @param isEnabling The enabling boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @returns A button that can be used to enable.\n */\nexport default function EnableButton({\n isEnabling,\n handleClick,\n className,\n ...props\n}: EnableButtonProps) {\n return (\n \n {isEnabling ? (\n <>\n \n Enabling...\n \n ) : (\n 'Enable'\n )}\n \n );\n}\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\n\ntype DisableButtonProps = {\n /** The disabling boolean value determines the state of the button. */\n isDisabling: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n} & ButtonProps;\n\n/**\n * The DisableButton component is a button designed for initiating disabling of downloads. It\n * includes visuals for active disabling and idle states.\n *\n * @param isDisabling The disabling boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @returns A button that can be used to disable.\n */\nexport default function DisableButton({\n isDisabling,\n handleClick,\n className,\n ...props\n}: DisableButtonProps) {\n return (\n \n {isDisabling ? (\n <>\n \n Disabling...\n \n ) : (\n 'Disable'\n )}\n \n );\n}\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\n\ntype UpdateButtonProps = {\n /** The updating boolean value determines the state of the button. */\n isUpdating: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n} & ButtonProps;\n\n/**\n * The UpdateButton component is a button designed for initiating updates for downloaded extensions.\n * It includes visuals for active updating and idle states.\n *\n * @param isUpdating The updating boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @returns A button that can be used to update.\n */\nexport default function UpdateButton({\n isUpdating,\n handleClick,\n className,\n ...props\n}: UpdateButtonProps) {\n return (\n \n {isUpdating ? (\n <>\n \n Updating...\n \n ) : (\n 'Update'\n )}\n \n );\n}\n","import { cn } from '@/utils/shadcn-ui.util';\nimport Markdown, { MarkdownToJSX } from 'markdown-to-jsx';\nimport { useMemo } from 'react';\n\ninterface MarkdownRendererProps {\n /** Optional unique identifier */\n id?: string;\n /** The markdown string to render */\n markdown: string;\n className?: string;\n /**\n * The [`target` attribute for `a` html\n * tags](https://developer.mozilla.org/en-US/docs/Web/HTML/Element/a#target). Defaults to not\n * adding a `target` to `a` tags\n */\n anchorTarget?: string;\n}\n\n/**\n * This component renders markdown content given a markdown string. It uses typography styles from\n * the platform.\n *\n * @param markdown The markdown string to render.\n * @param id Optional unique identifier\n * @returns A div containing the rendered markdown content.\n */\nexport default function MarkdownRenderer({\n id,\n markdown,\n className,\n anchorTarget,\n}: MarkdownRendererProps) {\n const options: MarkdownToJSX.Options = useMemo(\n () => ({\n overrides: {\n a: {\n props: {\n target: anchorTarget,\n },\n },\n },\n }),\n [anchorTarget],\n );\n return (\n
    \n {markdown}\n
    \n );\n}\n","import { Filter, ChevronDown } from 'lucide-react';\nimport { forwardRef } from 'react';\nimport { Button } from '@/components/shadcn-ui/button';\n\n/**\n * The FilterButton component is a button designed for initiating filtering of data. It is designed\n * to be used with the dropdown menu. It uses forwardRef to pass the button to the dropdown trigger\n * asChild.\n *\n * @returns A button that can be used to filter.\n */\nconst FilterButton = forwardRef((props, ref) => {\n return (\n \n \n Filter\n \n \n );\n});\n\nexport default FilterButton;\n","import {\n DropdownMenu,\n DropdownMenuTrigger,\n DropdownMenuContent,\n DropdownMenuLabel,\n DropdownMenuGroup,\n DropdownMenuCheckboxItem,\n DropdownMenuRadioItem,\n DropdownMenuSeparator,\n} from '@/components/shadcn-ui/dropdown-menu';\nimport FilterButton from './buttons/filter-button.component';\n\nexport enum DropdownMenuItemType {\n Check,\n Radio,\n}\n\nexport type DropdownItem = {\n /** The label is the text that will be displayed on the dropdown item. */\n label: string;\n /** The itemType determines the DropdownMenuItemType type as either Check or Radio. */\n itemType: DropdownMenuItemType;\n /** The onClick function is called when the item is clicked. */\n onClick: () => void;\n};\n\nexport type DropdownGroup = {\n /**\n * The label is the text that will be displayed on the dropdown group. It is used to categorize\n * the items in the group.\n */\n label: string;\n /** The items array contains the items that will be displayed in the dropdown group */\n items: DropdownItem[];\n};\n\nexport type FilterDropdownProps = {\n /** Object unique identifier */\n id?: string;\n /** The groups array contains the groups that will be displayed in the dropdown */\n groups: DropdownGroup[];\n}; // TODO: extend the props later\n\n/**\n * The FilterDropdown component is a dropdown designed for filtering content. It includes groups of\n * items that can be checkboxes or radio items.\n *\n * @param id Optional unique identifier\n * @param groups The groups array contains the groups that will be displayed in the dropdown\n * @returns A filter dropdown.\n */\nexport default function FilterDropdown({ id, groups }: FilterDropdownProps) {\n return (\n
    \n {/* TODO: remove this once the DropDown Menu shadcn has an id prop */}\n \n \n \n \n \n {groups.map((group) => (\n
    \n {group.label}\n \n {group.items.map((item) => (\n
    \n {item.itemType === DropdownMenuItemType.Check ? (\n \n {item.label}\n \n ) : (\n \n {item.label}\n \n )}\n
    \n ))}\n
    \n \n
    \n ))}\n
    \n
    \n
    \n );\n}\n","interface NoExtensionsFoundProps {\n /** Optional unique identifier */\n id?: string;\n /** The message to display */\n message: string;\n}\n/**\n * This component displays a message to the user when no extensions are found in the marketplace.\n *\n * @param id Optional unique identifier\n * @param message The message to display.\n * @returns {JSX.Element} - Returns the message component that displays the message to the user.\n */\nexport default function NoExtensionsFound({ id, message }: NoExtensionsFoundProps) {\n return (\n
    \n
    \n

    {message}

    \n
    \n
    \n );\n}\n","import { CircleHelp, Link as LucideLink, User } from 'lucide-react';\nimport { NumberFormat } from 'platform-bible-utils';\n\n/** Interface that stores the parameters passed to the More Info component */\ninterface MoreInfoProps {\n /** Optional unique identifier */\n id?: string;\n /** The category of the extension */\n category: string;\n /** The number of downloads for the extension */\n downloads: Record;\n /** The languages supported by the extension */\n languages: string[];\n /** The URL to the more info page of the extension */\n moreInfoUrl: string;\n}\n/**\n * This component displays the more info section of the extension which includes the category,\n * number of downloads, languages, and links to the website and support\n *\n * @param id Optional unique identifier\n * @param category The category of the extension\n * @param downloads The number of downloads for the extension\n * @param languages The languages supported by the extension\n * @param moreInfoUrl The URL to the more info page of the extension\n * @returns {JSX.Element} - Returns the more info component that displays the category, number of\n * downloads, languages, and links to the website and support\n */\nexport default function MoreInfo({\n id,\n category,\n downloads,\n languages,\n moreInfoUrl,\n}: MoreInfoProps) {\n /**\n * This constant formats the number of downloads into a more readable format.\n *\n * @example 1000 -> 1K\n *\n * @example 1000000 -> 1M\n *\n * @returns The formatted number of downloads\n */\n const numberFormatted = new NumberFormat('en', {\n notation: 'compact',\n compactDisplay: 'short',\n }).format(Object.values(downloads).reduce((a: number, b: number) => a + b, 0));\n\n /** This function scrolls the window to the bottom of the page. */\n const handleScrollToBottom = () => {\n window.scrollTo(0, document.body.scrollHeight);\n };\n\n return (\n \n
    \n
    \n {category}\n
    \n CATEGORY\n
    \n
    \n
    \n
    \n \n {numberFormatted}\n
    \n USERS\n
    \n
    \n
    \n
    \n {languages.slice(0, 3).map((locale) => (\n \n {locale.toUpperCase()}\n \n ))}\n
    \n {languages.length > 3 && (\n handleScrollToBottom()}\n className=\"tw-text-xs tw-text-gray-500 tw-underline\"\n >\n +{languages.length - 3} more languages\n \n )}\n
    \n
    \n
    \n \n Website\n \n \n \n Support\n \n \n
    \n
    \n );\n}\n","import { useState } from 'react';\n\nexport type VersionInformation = {\n /** Date the version was published */\n date: string;\n /** Description of the changes in the version */\n description: string;\n};\n\n/** Type to store the version history information */\nexport type VersionHistoryType = Record;\n\n/** Interface that stores the parameters passed to the Version History component */\ninterface VersionHistoryProps {\n /** Optional unique identifier */\n id?: string;\n /** Object containing the versions mapped with their information */\n versionHistory: VersionHistoryType;\n}\n\n/**\n * Component to render the version history information shown in the footer component. Lists the 5\n * most recent versions, with the options to show all versions by pressing a button.\n *\n * @param versionHistory Object containing the versions mapped with their information\n * @param id Optional unique identifier\n * @returns Rendered version history for the Footer component\n */\nexport default function VersionHistory({ id, versionHistory }: VersionHistoryProps) {\n const [showAllVersions, setShowAllVersions] = useState(false);\n const currentDate = new Date();\n\n /**\n * Function to format the time string for the version history in the form of 'X year(s) ago'.\n *\n * @param dateString ISO Date string to determine the time string from\n * @returns Formatted time string\n */\n function formatTimeString(dateString: string) {\n const date = new Date(dateString);\n const dateDiff = new Date(currentDate.getTime() - date.getTime());\n const yearDiff = dateDiff.getUTCFullYear() - 1970;\n const monthDiff = dateDiff.getUTCMonth();\n const dayDiff = dateDiff.getUTCDate() - 1;\n\n // Determines how long ago the version was published\n let timeString = '';\n if (yearDiff > 0) {\n timeString = `${yearDiff.toString()} year${yearDiff === 1 ? '' : 's'} ago`;\n } else if (monthDiff > 0) {\n timeString = `${monthDiff.toString()} month${monthDiff === 1 ? '' : 's'} ago`;\n } else if (dayDiff === 0) {\n timeString = 'today';\n } else {\n timeString = `${dayDiff.toString()} day${dayDiff === 1 ? '' : 's'} ago`;\n }\n\n return timeString;\n }\n\n // Sorts the version history by version number\n const sortedEntries = Object.entries(versionHistory).sort((a, b) => b[0].localeCompare(a[0]));\n\n return (\n
    \n

    What`s New

    \n
      \n {(showAllVersions ? sortedEntries : sortedEntries.slice(0, 5)).map((entry) => (\n
      \n
      \n
    • \n {entry[1].description}\n
    • \n
      \n
      \n
      Version {entry[0]}
      \n
      {formatTimeString(entry[1].date)}
      \n
      \n
      \n ))}\n
    \n {sortedEntries.length > 5 && (\n setShowAllVersions(!showAllVersions)}\n className=\"tw-text-xs tw-text-gray-500 tw-underline\"\n >\n {showAllVersions ? 'Show Less Version History' : 'Show All Version History'}\n \n )}\n
    \n );\n}\n","import { useMemo } from 'react';\nimport { formatBytes } from 'platform-bible-utils';\nimport VersionHistory, { VersionHistoryType } from './version-history.component';\n\n/** Interface to store the parameters passed to the Footer component */\ninterface FooterProps {\n /** Optional unique identifier */\n id?: string;\n /** Name of the publisher */\n publisherDisplayName: string;\n /** Size of the extension file in bytes */\n fileSize: number;\n /** List of language codes supported by the extension */\n locales: string[];\n /** Object containing the version history mapped with their information */\n versionHistory: VersionHistoryType;\n}\n\n/**\n * Component to render the footer for the extension details which contains information on the\n * publisher, version history, languages, and file size.\n *\n * @param id Optional unique identifier\n * @param publisherDisplayName Name of the publisher\n * @param fileSize Size of the extension file in bytes\n * @param locales List of language codes supported by the extension\n * @param versionHistory Object containing the version history mapped with their information\n * @returns The rendered Footer component\n */\nexport default function Footer({\n id,\n publisherDisplayName,\n fileSize,\n locales,\n versionHistory,\n}: FooterProps) {\n /** Formats the file size into a human-readable format */\n const formattedFileSize = useMemo(() => formatBytes(fileSize), [fileSize]);\n\n /**\n * This function gets the display names of the languages based on the language codes.\n *\n * @param codes The list of language codes\n * @returns The list of language names\n */\n const getLanguageNames = (codes: string[]) => {\n const displayNames = new Intl.DisplayNames(navigator.language, { type: 'language' });\n return codes.map((code) => displayNames.of(code));\n };\n\n const languageNames = getLanguageNames(locales);\n\n return (\n
    \n
    \n \n
    \n
    \n

    Information

    \n
    \n

    \n Publisher\n {publisherDisplayName}\n Size\n {formattedFileSize}\n

    \n
    \n

    \n Languages\n {languageNames.join(', ')}\n

    \n
    \n
    \n
    \n
    \n
    \n );\n}\n","import { PlatformEvent, PlatformEventHandler } from 'platform-bible-utils';\nimport { useEffect } from 'react';\n\n/**\n * Adds an event handler to an event so the event handler runs when the event is emitted. Use\n * `papi.network.getNetworkEvent` to use a networked event with this hook.\n *\n * @param event The event to subscribe to.\n *\n * - If event is a `PlatformEvent`, that event will be used\n * - If event is undefined, the callback will not be subscribed. Useful if the event is not yet\n * available for example\n *\n * @param eventHandler The callback to run when the event is emitted\n *\n * WARNING: MUST BE STABLE - const or wrapped in useCallback. The reference must not be updated\n * every render\n */\nconst useEvent = (\n event: PlatformEvent | undefined,\n eventHandler: PlatformEventHandler,\n) => {\n useEffect(() => {\n // Do nothing if the event is not provided (in case the event is not yet available, for example)\n if (!event) return () => {};\n\n const unsubscriber = event(eventHandler);\n return () => {\n unsubscriber();\n };\n }, [event, eventHandler]);\n};\nexport default useEvent;\n","import { useCallback, useEffect } from 'react';\nimport { PlatformEvent, PlatformEventAsync, PlatformEventHandler } from 'platform-bible-utils';\nimport usePromise from './use-promise.hook';\n\nconst noopUnsubscriber = () => false;\n\n/**\n * Adds an event handler to an asynchronously subscribing/unsubscribing event so the event handler\n * runs when the event is emitted. Use `papi.network.getNetworkEvent` to use a networked event with\n * this hook.\n *\n * @param event The asynchronously (un)subscribing event to subscribe to.\n *\n * - If event is a `PlatformEvent` or `PlatformEventAsync`, that event will be used\n * - If event is undefined, the callback will not be subscribed. Useful if the event is not yet\n * available for example\n *\n * @param eventHandler The callback to run when the event is emitted\n *\n * WARNING: MUST BE STABLE - const or wrapped in useCallback. The reference must not be updated\n * every render\n */\nconst useEventAsync = (\n event: PlatformEvent | PlatformEventAsync | undefined,\n eventHandler: PlatformEventHandler,\n) => {\n // Subscribe to the event asynchronously\n const [unsubscribe] = usePromise(\n useCallback(async () => {\n // Do nothing if the event is not provided (in case the event is not yet available, for example)\n if (!event) return noopUnsubscriber;\n\n // Wrap subscribe and unsubscribe in promises to allow normal events to be used as well\n const unsub = await Promise.resolve(event(eventHandler));\n return async () => unsub();\n }, [eventHandler, event]),\n noopUnsubscriber,\n // We want the unsubscriber to return to default value immediately upon changing subscription\n // So the useEffect below will unsubscribe asap\n { preserveValue: false },\n );\n\n // Unsubscribe from the event asynchronously (but we aren't awaiting the unsub)\n useEffect(() => {\n return () => {\n if (unsubscribe !== noopUnsubscriber) {\n unsubscribe();\n }\n };\n }, [unsubscribe]);\n};\n\nexport default useEventAsync;\n"],"names":["twMergeCustom","extendTailwindMerge","cn","inputs","clsx","Input","React","className","type","props","ref","jsx","BookChapterInput","forwardRef","handleSearch","handleKeyDown","handleOnClick","handleSubmit","jsxs","ShadInput","event","e","History","P","R","t","s","n","N","B","O","S","K","g","k","x","T","X","V","w","L","G","A","H","C","I","y","q","U","m","l","h","c","E","D","i","a","o","u","v","f","d","b","p","J","DropdownMenu","DropdownMenuPrimitive","DropdownMenuTrigger","DropdownMenuGroup","DropdownMenuPortal","DropdownMenuSub","DropdownMenuRadioGroup","DropdownMenuSubTrigger","inset","children","ChevronRight","DropdownMenuSubContent","DropdownMenuContent","sideOffset","DropdownMenuItem","DropdownMenuCheckboxItem","checked","Check","DropdownMenuRadioItem","Circle","DropdownMenuLabel","DropdownMenuSeparator","DropdownMenuShortcut","BookMenuItem","bookId","handleSelectBook","isSelected","handleHighlightBook","bookType","ShadDropdownMenuItem","Canon","ChapterSelect","handleSelectChapter","endChapter","activeChapter","highlightedChapter","handleHighlightedChapter","chapters","_","handleMouse","useCallback","chapterNumber","chapter","GoToMenuItem","handleSort","handleLocationHistory","handleBookmarks","ShadDropdownMenuLabel","ArrowDownWideNarrow","Clock","Bookmark","ALL_BOOK_IDS","BOOK_TYPE_LABELS","BOOK_TYPE_ARRAY","SCROLL_OFFSET","SEARCH_QUERY_FORMATS","fetchGroupedBooks","fetchEndChapter","getChaptersForBook","getAllEnglishNames","isValidBookEnglishName","bookName","getBookIdFromEnglishName","formattedBookName","BookChapterControl","scrRef","searchQuery","setSearchQuery","useState","selectedBookId","setSelectedBookId","setHighlightedChapter","highlightedBookId","setHighlightedBookId","isContentOpen","setIsContentOpen","isContentOpenDelayed","setIsContentOpenDelayed","inputRef","useRef","contentRef","menuItemRef","fetchFilteredBooks","englishNameLowerCase","normalizedQuery","handleSearchInput","searchString","shouldPreventAutoClosing","controlMenuState","open","updateReference","shouldClose","verse","handleInputSubmit","format","matches","book","englishName","handleKeyDownInput","handleKeyDownContent","key","handleKeyDownMenuItem","chapterOffSet","useEffect","useLayoutEffect","scrollTimeout","scrollPosition","ShadDropdownMenu","ShadDropdownMenuTrigger","ShadDropdownMenuContent","bookTypeIndex","element","ShadDropdownMenuSeparator","buttonVariants","cva","Button","variant","size","asChild","Comp","Slot","labelVariants","Label","LabelPrimitive","RadioGroup","RadioGroupPrimitive","RadioGroupItem","Popover","PopoverPrimitive","PopoverTrigger","PopoverContent","align","DialogPortal","DialogPrimitive","DialogOverlay","DialogContent","DialogTitle","DialogDescription","Command","CommandPrimitive","CommandInput","Search","CommandList","CommandEmpty","CommandGroup","CommandSeparator","CommandItem","getOptionLabelDefault","option","ComboBox","id","options","buttonClassName","popoverContentClassName","value","onChange","getOptionLabel","buttonPlaceholder","textPlaceholder","commandEmptyMessage","buttonVariant","dir","isDisabled","setOpen","ChevronsUpDown","ChapterRangeSelector","startChapter","handleSelectStartChapter","handleSelectEndChapter","chapterCount","chapterOptions","useMemo","index","onChangeStartChapter","onChangeEndChapter","Fragment","BookSelectionMode","BOOK_SELECTOR_STRING_KEYS","localizeString","strings","BookSelector","handleBookSelectionModeChange","currentBookName","onSelectBooks","selectedBookIds","localizedStrings","currentBookText","chooseText","chooseBooksText","bookSelectionMode","setBookSelectionMode","onSelectionModeChange","newMode","DataTableViewOptions","table","FilterIcon","column","Select","SelectPrimitive","SelectGroup","SelectValue","SelectTrigger","ChevronDown","SelectScrollUpButton","ChevronUp","SelectScrollDownButton","SelectContent","position","SelectLabel","SelectItem","SelectSeparator","DataTablePagination","pageSize","ArrowLeftIcon","ChevronLeftIcon","ChevronRightIcon","ArrowRightIcon","Table","stickyHeader","TableHeader","TableBody","TableFooter","TableRow","TableHead","TableCell","TableCaption","DataTable","columns","data","enablePagination","showPaginationControls","showColumnVisibilityControls","onRowClickHandler","sorting","setSorting","columnFilters","setColumnFilters","columnVisibility","setColumnVisibility","rowSelection","setRowSelection","useReactTable","getCoreRowModel","getPaginationRowModel","getSortedRowModel","getFilteredRowModel","headerGroup","header","flexRender","_a","row","cell","OccurrencesTable","occurrenceData","setScriptureReference","referenceHeaderText","occurrenceHeaderText","occurrences","uniqueOccurrences","occurrence","uniqueOccurrence","deepEqual","Checkbox","CheckboxPrimitive","getLinesFromUSFM","text","getNumberFromUSFM","regex","match","getBookNumFromId","getStatusForItem","item","approvedItems","unapprovedItems","toggleVariants","Toggle","TogglePrimitive","ToggleGroupContext","ToggleGroup","ToggleGroupPrimitive","ToggleGroupItem","context","getSortingIcon","sortDirection","ArrowUpIcon","ArrowDownIcon","ArrowUpDownIcon","inventoryItemColumn","itemLabel","inventoryAdditionalItemColumn","additionalItemLabel","additionalItemIndex","inventoryCountColumn","countLabel","statusChangeHandler","changedItems","newStatus","onApprovedItemsChange","onUnapprovedItemsChange","newApprovedItems","validItem","newUnapprovedItems","unapprovedItem","inventoryStatusColumn","statusLabel","status","CircleCheckIcon","CircleXIcon","CircleHelpIcon","INVENTORY_STRING_KEYS","filterItemData","itemData","statusFilter","textFilter","filteredItemData","createTableData","scriptureRef","itemRegex","tableData","currentBook","currentChapter","currentVerse","line","items","itemIndex","existingItem","tableEntry","newReference","substring","newItem","Inventory","scriptureReference","extractItems","additionalItemsLabels","scope","onScopeChange","allItemsText","approvedItemsText","unapprovedItemsText","unknownItemsText","scopeBookText","scopeChapterText","scopeVerseText","filterText","showAdditionalItemsText","showAdditionalItems","setShowAdditionalItems","setStatusFilter","setTextFilter","selectedItem","setSelectedItem","reducedTableData","newTableData","firstItem","existingEntry","newTableEntry","filteredTableData","allColumns","numberOfAdditionalItems","additionalColumns","_b","rowClickHandler","newSelection","handleScopeChange","handleStatusFilterChange","SearchBar","onSearch","placeholder","isFullWidth","handleInputChange","VerticalTabs","TabsPrimitive","VerticalTabsList","VerticalTabsTrigger","VerticalTabsContent","TabNavigationContentSearch","tabList","searchPlaceholder","headerTitle","isSearchBarFullWidth","direction","tab","Separator","orientation","decorative","SeparatorPrimitive","Skeleton","TooltipProvider","TooltipPrimitive","Tooltip","TooltipTrigger","TooltipContent","SIDEBAR_WIDTH","SIDEBAR_WIDTH_ICON","SIDEBAR_KEYBOARD_SHORTCUT","SidebarContext","useSidebar","SidebarProvider","defaultOpen","openProp","setOpenProp","style","_open","_setOpen","isOpen","openState","toggleSidebar","state","contextValue","Sidebar","side","collapsible","SidebarTrigger","onClick","PanelLeft","SidebarRail","SidebarInset","SidebarInput","SidebarHeader","SidebarFooter","SidebarSeparator","SidebarContent","SidebarGroup","SidebarGroupLabel","SidebarGroupAction","SidebarGroupContent","SidebarMenu","SidebarMenuItem","sidebarMenuButtonVariants","SidebarMenuButton","isActive","tooltip","button","SidebarMenuAction","showOnHover","SidebarMenuBadge","SidebarMenuSkeleton","showIcon","width","SidebarMenuSub","SidebarMenuSubItem","SidebarMenuSubButton","SettingsSidebar","extensionLabels","projectInfo","handleSelectSidebarItem","selectedSidebarItem","extensionsSidebarGroupLabel","projectsSidebarGroupLabel","buttonPlaceholderText","handleSelectItem","projectId","getProjectNameFromProjectId","project","info","getIsActive","label","selectedProjectName","SettingsSidebarContentSearch","scrBookColId","scrRefColId","typeColId","detailsColId","defaultScrRefColumnName","defaultScrBookGroupName","defaultTypeColumnName","defaultDetailsColumnName","getColumns","colInfo","showSourceColumn","showSrcCol","formatScrRef","compareScrRefs","toRefOrRange","scriptureSelection","offsetStart","offsetEnd","scrRefToBBBCCCVVV","getRowKey","ScriptureResultsViewer","sources","showColumnHeaders","scriptureReferenceColumnName","scriptureBookGroupName","typeColumnName","detailsColumnName","onRowSelected","grouping","setGrouping","scriptureResults","source","getExpandedRowModel","getGroupedRowModel","selectedRows","keys","selectedRow","scrBookGroupName","typeGroupName","groupingOptions","handleSelectChange","selectedGrouping","handleRowClick","getEvenOrOddBandingStyle","getIndent","groupingState","rowIndex","ChevronLeft","DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS","getLocalizeKeyForScrollGroupId","ScrollGroupSelector","availableScrollGroupIds","scrollGroupId","onChangeScrollGroupId","localizedStringsDefaulted","localizedStringKey","localizedStringValue","newScrollGroupString","scrollGroupOptionId","SettingsList","SettingsListItem","primary","secondary","isLoading","loadingMessage","SettingsListHeader","includeSeparator","Checklist","listItems","selectedListItems","handleSelectListItem","createLabel","_interopRequireDefault","obj","module","chainPropTypes","propType1","propType2","args","_extends","target","isPlainObject","prototype","deepClone","output","deepmerge","r","z","reactIs_production_min","hasSymbol","REACT_ELEMENT_TYPE","REACT_PORTAL_TYPE","REACT_FRAGMENT_TYPE","REACT_STRICT_MODE_TYPE","REACT_PROFILER_TYPE","REACT_PROVIDER_TYPE","REACT_CONTEXT_TYPE","REACT_ASYNC_MODE_TYPE","REACT_CONCURRENT_MODE_TYPE","REACT_FORWARD_REF_TYPE","REACT_SUSPENSE_TYPE","REACT_SUSPENSE_LIST_TYPE","REACT_MEMO_TYPE","REACT_LAZY_TYPE","REACT_BLOCK_TYPE","REACT_FUNDAMENTAL_TYPE","REACT_RESPONDER_TYPE","REACT_SCOPE_TYPE","isValidElementType","typeOf","object","$$typeof","$$typeofType","AsyncMode","ConcurrentMode","ContextConsumer","ContextProvider","Element","ForwardRef","Lazy","Memo","Portal","Profiler","StrictMode","Suspense","hasWarnedAboutDeprecatedIsAsyncMode","isAsyncMode","isConcurrentMode","isContextConsumer","isContextProvider","isElement","isForwardRef","isFragment","isLazy","isMemo","isPortal","isProfiler","isStrictMode","isSuspense","reactIs_development","reactIsModule","require$$0","require$$1","getOwnPropertySymbols","hasOwnProperty","propIsEnumerable","toObject","val","shouldUseNative","test1","test2","order2","test3","letter","objectAssign","from","to","symbols","ReactPropTypesSecret","ReactPropTypesSecret_1","has","printWarning","loggedTypeFailures","message","checkPropTypes","typeSpecs","values","location","componentName","getStack","typeSpecName","error","err","ex","stack","checkPropTypes_1","ReactIs","assign","require$$2","require$$3","require$$4","emptyFunctionThatReturnsNull","factoryWithTypeCheckers","isValidElement","throwOnDirectAccess","ITERATOR_SYMBOL","FAUX_ITERATOR_SYMBOL","getIteratorFn","maybeIterable","iteratorFn","ANONYMOUS","ReactPropTypes","createPrimitiveTypeChecker","createAnyTypeChecker","createArrayOfTypeChecker","createElementTypeChecker","createElementTypeTypeChecker","createInstanceTypeChecker","createNodeChecker","createObjectOfTypeChecker","createEnumTypeChecker","createUnionTypeChecker","createShapeTypeChecker","createStrictShapeTypeChecker","is","PropTypeError","createChainableTypeChecker","validate","manualPropTypeCallCache","manualPropTypeWarningCount","checkType","isRequired","propName","propFullName","secret","cacheKey","chainedCheckType","expectedType","propValue","propType","getPropType","preciseType","getPreciseType","typeChecker","expectedClass","expectedClassName","actualClassName","getClassName","expectedValues","valuesString","arrayOfTypeCheckers","checker","getPostfixForTypeWarning","expectedTypes","checkerResult","expectedTypesMessage","isNode","invalidValidatorError","shapeTypes","allKeys","iterator","step","entry","isSymbol","emptyFunction","emptyFunctionWithReset","factoryWithThrowingShims","shim","getShim","propTypesModule","isClassComponent","elementType","acceptingRef","safePropName","warningHint","elementAcceptingRef","PropTypes","elementAcceptingRef$1","specialProperty","exactProp","propTypes","unsupportedProps","prop","formatMuiErrorMessage","code","url","REACT_SERVER_CONTEXT_TYPE","REACT_OFFSCREEN_TYPE","enableScopeAPI","enableCacheElement","enableTransitionTracing","enableLegacyHidden","enableDebugTracing","REACT_MODULE_REFERENCE","SuspenseList","hasWarnedAboutDeprecatedIsConcurrentMode","isSuspenseList","fnNameMatchRegex","getFunctionName","fn","getFunctionComponentName","Component","fallback","getWrappedName","outerType","innerType","wrapperName","functionName","getDisplayName","HTMLElementType","refType","refType$1","capitalize","string","_formatMuiErrorMessage","createChainedFunction","funcs","acc","func","debounce","wait","timeout","debounced","later","deprecatedPropType","validator","reason","componentNameSafe","propFullNameSafe","isMuiElement","muiNames","_muiName","_element$type","ownerDocument","node","ownerWindow","requirePropFactory","componentNameInError","prevPropTypes","requiredProp","defaultTypeChecker","typeCheckerResult","setRef","useEnhancedEffect","useEnhancedEffect$1","globalId","useGlobalId","idOverride","defaultId","setDefaultId","maybeReactUseId","useId","reactId","unsupportedProp","useControlled","controlled","defaultProp","name","isControlled","valueState","setValue","defaultValue","setValueIfUncontrolled","newValue","useEventCallback","useForkRef","refs","instance","UNINITIALIZED","useLazyRef","init","initArg","EMPTY","useOnMount","Timeout","delay","useTimeout","hadKeyboardEvent","hadFocusVisibleRecently","hadFocusVisibleRecentlyTimeout","inputTypesWhitelist","focusTriggersKeyboardModality","tagName","handlePointerDown","handleVisibilityChange","prepare","doc","isFocusVisible","useIsFocusVisible","isFocusVisibleRef","handleBlurVisible","handleFocusVisible","resolveProps","defaultProps","defaultSlotProps","slotProps","slotPropName","composeClasses","slots","getUtilityClass","classes","slot","utilityClass","defaultGenerator","createClassNameGenerator","generate","generator","ClassNameGenerator","ClassNameGenerator$1","globalStateClasses","generateUtilityClass","globalStatePrefix","globalStateClass","generateUtilityClasses","result","clamp","min","max","_objectWithoutPropertiesLoose","excluded","sourceKeys","_excluded","sortBreakpointsValues","breakpointsAsArray","breakpoint1","breakpoint2","createBreakpoints","breakpoints","unit","other","sortedValues","up","down","between","start","end","endIndex","only","not","keyIndex","shape","shape$1","responsivePropType","responsivePropType$1","merge","defaultBreakpoints","handleBreakpoints","styleFromPropValue","theme","themeBreakpoints","breakpoint","mediaKey","cssKey","createEmptyBreakpointObject","breakpointsInput","_breakpointsInput$key","breakpointStyleKey","removeUnusedBreakpoints","breakpointKeys","breakpointOutput","getPath","path","checkVars","getStyleValue","themeMapping","transform","propValueFinal","userValue","cssProperty","themeKey","memoize","cache","arg","properties","directions","aliases","getCssProperties","property","marginKeys","paddingKeys","spacingKeys","createUnaryUnit","_getPath","themeSpacing","abs","createUnarySpacing","getValue","transformer","transformed","getStyleFromPropValue","cssProperties","resolveCssProperty","margin","padding","createSpacing","spacingInput","spacing","argsInput","argument","compose","styles","handlers","borderTransform","createBorderStyle","border","borderTop","borderRight","borderBottom","borderLeft","borderColor","borderTopColor","borderRightColor","borderBottomColor","borderLeftColor","outline","outlineColor","borderRadius","gap","columnGap","rowGap","gridColumn","gridRow","gridAutoFlow","gridAutoColumns","gridAutoRows","gridTemplateColumns","gridTemplateRows","gridTemplateAreas","gridArea","paletteTransform","color","bgcolor","backgroundColor","sizingTransform","maxWidth","_props$theme","_props$theme2","breakpointsValues","minWidth","height","maxHeight","minHeight","boxSizing","defaultSxConfig","defaultSxConfig$1","objectsHaveSameKeys","objects","union","callIfFn","maybeFn","unstable_createStyleFunctionSx","getThemeValue","config","styleFunctionSx","_theme$unstable_sxCon","sx","traverse","sxInput","sxObject","emptyBreakpoints","breakpointsKeys","css","styleKey","styleFunctionSx$1","applyStyles","createTheme","paletteInput","shapeInput","muiTheme","isObjectEmpty","useTheme","defaultTheme","contextTheme","ThemeContext","systemDefaultTheme","useThemeWithoutDefault","_excluded2","_excluded3","isEmpty","isStringTag","tag","shouldForwardProp","lowercaseFirstLetter","resolveTheme","themeId","defaultOverridesResolver","processStyleArg","callableStyle","_ref","ownerState","resolvedStylesArg","resolvedStyle","variants","isMatch","createStyled","input","rootShouldForwardProp","slotShouldForwardProp","systemSx","inputOptions","processStyles","componentSlot","inputSkipVariantsResolver","inputSkipSx","overridesResolver","skipVariantsResolver","skipSx","shouldForwardPropOption","defaultStyledResolver","styledEngineStyled","transformStyleArg","stylesArg","muiStyledResolver","styleArg","expressions","transformedStyleArg","expressionsWithDefaultTheme","styleOverrides","resolvedStyleOverrides","slotKey","slotStyle","_theme$components","themeVariants","numOfCustomFnsApplied","placeholders","displayName","getThemeProps","params","useThemeProps","clampWrapper","hexToRgb","re","colors","decomposeColor","marker","colorSpace","recomposeColor","hslToRgb","rgb","getLuminance","getContrastRatio","foreground","background","lumA","lumB","alpha","darken","coefficient","lighten","createMixins","mixins","common","common$1","grey","grey$1","purple","purple$1","red","red$1","orange","orange$1","blue","blue$1","lightBlue","lightBlue$1","green","green$1","light","dark","addLightOrDark","intent","shade","tonalOffset","tonalOffsetLight","tonalOffsetDark","getDefaultPrimary","mode","getDefaultSecondary","getDefaultError","getDefaultInfo","getDefaultSuccess","getDefaultWarning","createPalette","palette","contrastThreshold","success","warning","getContrastText","contrastText","contrast","augmentColor","mainShade","lightShade","darkShade","modes","round","caseAllCaps","defaultFontFamily","createTypography","typography","fontFamily","fontSize","fontWeightLight","fontWeightRegular","fontWeightMedium","fontWeightBold","htmlFontSize","allVariants","pxToRem2","coef","pxToRem","buildVariant","fontWeight","lineHeight","letterSpacing","casing","shadowKeyUmbraOpacity","shadowKeyPenumbraOpacity","shadowAmbientShadowOpacity","createShadow","px","shadows","shadows$1","easing","duration","formatMs","milliseconds","getAutoHeightDuration","constant","createTransitions","inputTransitions","mergedEasing","mergedDuration","durationOption","easingOption","isString","isNumber","animatedProp","zIndex","zIndex$1","mixinsInput","transitionsInput","typographyInput","systemTheme","systemCreateTheme","stateClasses","component","child","stateClass","defaultTheme$1","THEME_ID","systemUseThemeProps","styled","styled$1","getSvgIconUtilityClass","useUtilityClasses","SvgIconRoot","_theme$transitions","_theme$transitions$cr","_theme$transitions2","_theme$typography","_theme$typography$pxT","_theme$typography2","_theme$typography2$px","_theme$typography3","_theme$typography3$px","_palette$ownerState$c","_palette","_palette2","_palette3","SvgIcon","inProps","htmlColor","inheritViewBox","titleAccess","viewBox","hasSvgAsChild","more","_jsxs","_jsx","SvgIcon$1","createSvgIcon","unstable_ClassNameGenerator","exports","_utils","ArrowRight","default_1","_createSvgIcon","_jsxRuntime","isHostComponent","appendOwnerState","otherProps","defaultContextValue","ClassNameConfiguratorContext","useClassNamesOverride","disableDefaultClasses","extractEventHandlers","excludeKeys","resolveComponentProps","componentProps","slotState","omitEventHandlers","mergeSlotProps","parameters","getSlotProps","additionalProps","externalSlotProps","externalForwardedProps","joinedClasses","mergedStyle","eventHandlers","componentsPropsWithoutEventHandlers","otherPropsWithoutEventHandlers","internalSlotProps","useSlotProps","_parameters$additiona","skipResolvingSlotProps","rest","resolvedComponentsProps","mergedProps","internalRef","GLOBAL_CLASS_PREFIX","buildStateClass","buildSlotClass","getContainer","container","forwardedRef","disablePortal","mountNode","setMountNode","handleRef","newProps","ReactDOM","top","bottom","right","left","auto","basePlacements","clippingParents","viewport","popper","reference","variationPlacements","placement","placements","beforeRead","read","afterRead","beforeMain","main","afterMain","beforeWrite","write","afterWrite","modifierPhases","getNodeName","getWindow","OwnElement","isHTMLElement","isShadowRoot","attributes","effect","_ref2","initialStyles","styleProperties","attribute","applyStyles$1","getBasePlacement","getUAString","uaData","isLayoutViewport","getBoundingClientRect","includeScale","isFixedStrategy","clientRect","scaleX","scaleY","visualViewport","addVisualOffsets","getLayoutRect","contains","parent","rootNode","next","getComputedStyle","isTableElement","getDocumentElement","getParentNode","getTrueOffsetParent","getContainingBlock","isFirefox","isIE","elementCss","currentNode","getOffsetParent","window","offsetParent","getMainAxisFromPlacement","within","mathMax","mathMin","withinMaxClamp","getFreshSideObject","mergePaddingObject","paddingObject","expandToHashMap","hashMap","toPaddingObject","arrow","_state$modifiersData$","arrowElement","popperOffsets","basePlacement","axis","isVertical","len","arrowRect","minProp","maxProp","endDiff","startDiff","arrowOffsetParent","clientSize","centerToReference","center","offset","axisProp","_options$element","arrow$1","getVariation","unsetSides","roundOffsetsByDPR","win","dpr","mapToStyles","_Object$assign2","popperRect","variation","offsets","gpuAcceleration","adaptive","roundOffsets","isFixed","_offsets$x","_offsets$y","_ref3","hasX","hasY","sideX","sideY","heightProp","widthProp","offsetY","offsetX","commonStyles","_ref4","_Object$assign","computeStyles","_ref5","_options$gpuAccelerat","_options$adaptive","_options$roundOffsets","computeStyles$1","passive","_options$scroll","scroll","_options$resize","resize","scrollParents","scrollParent","eventListeners","hash","getOppositePlacement","matched","getOppositeVariationPlacement","getWindowScroll","scrollLeft","scrollTop","getWindowScrollBarX","getViewportRect","strategy","html","layoutViewport","getDocumentRect","_element$ownerDocumen","winScroll","body","isScrollParent","_getComputedStyle","overflow","overflowX","overflowY","getScrollParent","listScrollParents","list","isBody","updatedList","rectToClientRect","rect","getInnerBoundingClientRect","getClientRectFromMixedType","clippingParent","getClippingParents","canEscapeClipping","clipperElement","getClippingRect","boundary","rootBoundary","mainClippingParents","firstClippingParent","clippingRect","accRect","computeOffsets","commonX","commonY","mainAxis","detectOverflow","_options","_options$placement","_options$strategy","_options$boundary","_options$rootBoundary","_options$elementConte","elementContext","_options$altBoundary","altBoundary","_options$padding","altContext","clippingClientRect","referenceClientRect","popperClientRect","elementClientRect","overflowOffsets","offsetData","multiply","computeAutoPlacement","flipVariations","_options$allowedAutoP","allowedAutoPlacements","allPlacements","allowedPlacements","overflows","getExpandedFallbackPlacements","oppositePlacement","flip","_options$mainAxis","checkMainAxis","_options$altAxis","checkAltAxis","specifiedFallbackPlacements","_options$flipVariatio","preferredPlacement","isBasePlacement","fallbackPlacements","referenceRect","checksMap","makeFallbackChecks","firstFittingPlacement","_basePlacement","isStartVariation","mainVariationSide","altVariationSide","checks","check","numberOfChecks","_loop","_i","fittingPlacement","_ret","flip$1","getSideOffsets","preventedOffsets","isAnySideFullyClipped","hide","referenceOverflow","popperAltOverflow","referenceClippingOffsets","popperEscapeOffsets","isReferenceHidden","hasPopperEscaped","hide$1","distanceAndSkiddingToXY","rects","invertDistance","skidding","distance","_options$offset","_data$state$placement","offset$1","popperOffsets$1","getAltAxis","preventOverflow","_options$tether","tether","_options$tetherOffset","tetherOffset","altAxis","tetherOffsetValue","normalizedTetherOffsetValue","offsetModifierState","_offsetModifierState$","mainSide","altSide","additive","minLen","maxLen","arrowPaddingObject","arrowPaddingMin","arrowPaddingMax","arrowLen","minOffset","maxOffset","clientOffset","offsetModifierValue","tetherMin","tetherMax","preventedOffset","_offsetModifierState$2","_mainSide","_altSide","_offset","_len","_min","_max","isOriginSide","_offsetModifierValue","_tetherMin","_tetherMax","_preventedOffset","preventOverflow$1","getHTMLElementScroll","getNodeScroll","isElementScaled","getCompositeRect","elementOrVirtualElement","isOffsetParentAnElement","offsetParentIsScaled","documentElement","order","modifiers","map","visited","modifier","sort","requires","dep","depModifier","orderModifiers","orderedModifiers","phase","pending","resolve","mergeByName","merged","current","existing","DEFAULT_OPTIONS","areValidElements","_key","popperGenerator","generatorOptions","_generatorOptions","_generatorOptions$def","defaultModifiers","_generatorOptions$def2","defaultOptions","effectCleanupFns","isDestroyed","setOptionsAction","cleanupModifierEffects","runModifierEffects","_state$elements","_state$orderedModifie","_state$orderedModifie2","_ref$options","cleanupFn","noopFn","createPopper","COMPONENT_NAME","getPopperUtilityClass","flipPlacement","resolveAnchorEl","anchorEl","isVirtualElement","defaultPopperOptions","PopperTooltip","_slots$root","initialPlacement","popperOptions","popperRefProp","TransitionProps","tooltipRef","ownRef","popperRef","handlePopperRef","handlePopperRefRef","rtlPlacement","setPlacement","resolvedAnchorElement","setResolvedAnchorElement","handlePopperUpdate","box","popperModifiers","childProps","Root","rootProps","Popper","containerProp","keepMounted","transition","exited","setExited","handleEnter","handleExited","resolvedAnchorEl","display","transitionProps","useThemeSystem","_setPrototypeOf","_inheritsLoose","subClass","superClass","setPrototypeOf","timeoutsShape","TransitionGroupContext","forceReflow","UNMOUNTED","EXITED","ENTERING","ENTERED","EXITING","Transition","_React$Component","_this","parentGroup","appear","initialStatus","prevState","nextIn","_proto","prevProps","nextStatus","exit","enter","mounting","_this2","appearing","maybeNode","maybeAppearing","timeouts","enterTimeout","_this3","nextState","callback","_this4","active","handler","doesNotHaveTimeoutOrListener","maybeNextCallback","_this$props","pt","noop","Transition$1","reflow","getTransitionProps","_style$transitionDura","_style$transitionTimi","getScale","isWebKit154","Grow","addEndListener","inProp","onEnter","onEntered","onEntering","onExit","onExited","onExiting","TransitionComponent","timer","autoTimeout","nodeRef","normalizedTransitionCallback","maybeIsAppearing","handleEntering","isAppearing","transitionDuration","transitionTimingFunction","handleEntered","handleExiting","handleExit","handleAddEndListener","Grow$1","PopperRoot","BasePopper","components","componentsProps","RootComponent","Popper$1","getTooltipUtilityClass","tooltipClasses","tooltipClasses$1","disableInteractive","touch","TooltipPopper","TooltipTooltip","TooltipArrow","hystersisOpen","hystersisTimer","cursorPosition","composeEventHandler","eventHandler","_slots$popper","_slots$transition","_slots$tooltip","_slots$arrow","_slotProps$popper","_ref6","_slotProps$popper2","_slotProps$transition","_slotProps$tooltip","_ref7","_slotProps$tooltip2","_slotProps$arrow","_ref8","_slotProps$arrow2","childrenProp","describeChild","disableFocusListener","disableHoverListener","disableInteractiveProp","disableTouchListener","enterDelay","enterNextDelay","enterTouchDelay","followCursor","idProp","leaveDelay","leaveTouchDelay","onClose","onOpen","PopperComponentProp","PopperProps","title","TransitionComponentProp","isRtl","childNode","setChildNode","arrowRef","setArrowRef","ignoreNonTouchEvents","closeTimer","enterTimer","leaveTimer","touchTimer","setOpenState","prevUserSelect","stopTouchInteraction","handleOpen","handleClose","handleLeave","focusVisibleRef","setChildIsFocusVisible","handleBlur","handleFocus","detectTouchStart","childrenProps","handleMouseOver","handleMouseLeave","handleTouchStart","handleTouchEnd","nativeEvent","handleMouseMove","nameOrDescProps","titleIsString","interactiveWrapperListeners","_PopperProps$popperOp","tooltipModifiers","PopperComponent","TooltipComponent","ArrowComponent","popperProps","tooltipProps","tooltipArrowProps","TransitionPropsInner","Tooltip$1","getIcon","icon","menuLabel","leading","MuiListItemIcon","MenuItem","allowForLeadingIcons","iconPathBefore","iconPathAfter","hasAutoFocus","isDense","isSubMenuParent","hasDisabledGutters","hasDivider","focusVisibleClassName","menuItem","MuiMenuItem","MuiListItemText","getAllGroups","menuDefinition","SubMenu","setAnchorEl","parentMenuItem","parentItemProps","handleParentMenuItemClick","renderSubMenuItems","includedGroups","group","GroupedMenuItemList","Menu","getOrderedGroupItems","groupId","allItems","menuProps","commandHandler","groupsToInclude","sortedGroups","itemArray","allowSpaceForLeadingIcons","createMenuItemProps","isLastItemInGroup","divKey","itemInfo","menuItemProps","TopLevelMenu","columnId","MenuColumn","metadata","Grid","List","GridMenu","multiColumnMenu","sortedColumns","columnNumbers","columnName","col","getUsePromiseOptionsDefaults","usePromise","promiseFactoryCallback","defaultValueRef","optionsDefaultedRef","setIsLoading","promiseIsCurrent","MenuIcon","HamburgerMenuButton","menuProvider","normalMenu","fullMenu","containerRef","ariaLabelPrefix","isMenuOpen","setMenuOpen","showFullMenu","setShowFullMenu","handleMenuItemClick","handleMenuButtonClick","prevIsOpen","isOpening","menuCommandHandler","command","setOffset","normalMenuData","fullMenuData","menu","IconButton","Drawer","isTooltipSuppressed","adjustMarginToAlignToEdge","MuiIconButton","Spinner","LoaderCircle","TextField","hasError","helperText","onFocus","onBlur","ShadLabel","Toolbar","AppBar","MuiToolbar","alertVariants","Alert","AlertTitle","AlertDescription","Card","CardHeader","CardTitle","CardDescription","CardContent","CardFooter","Sonner","Toaster","Slider","SliderPrimitive","Switch","SwitchPrimitives","Tabs","TabsList","TabsTrigger","TabsContent","InstallButton","isInstalling","handleClick","buttonText","Download","EnableButton","isEnabling","DisableButton","isDisabling","UpdateButton","isUpdating","MarkdownRenderer","markdown","anchorTarget","Markdown","FilterButton","Filter","DropdownMenuItemType","DropdownMenuItemType2","FilterDropdown","groups","NoExtensionsFound","MoreInfo","category","downloads","languages","moreInfoUrl","numberFormatted","NumberFormat","handleScrollToBottom","User","locale","LucideLink","CircleHelp","VersionHistory","versionHistory","showAllVersions","setShowAllVersions","currentDate","formatTimeString","dateString","date","dateDiff","yearDiff","monthDiff","dayDiff","timeString","sortedEntries","Footer","publisherDisplayName","fileSize","locales","formattedFileSize","formatBytes","languageNames","codes","displayNames","useEvent","unsubscriber","noopUnsubscriber","useEventAsync","unsubscribe","unsub"],"mappings":"48CAGA,MAAMA,GAAgBC,GAAAA,oBAAoB,CAAE,OAAQ,KAAO,CAAA,EAyDpD,SAASC,KAAMC,EAAsB,CACnC,OAAAH,GAAcI,GAAAA,KAAKD,CAAM,CAAC,CACnC,CCzDO,MAAME,GAAQC,EAAM,WACzB,CAAC,CAAE,UAAAC,EAAW,KAAAC,EAAM,GAAGC,CAAA,EAASC,IAE5BC,EAAA,IAAC,QAAA,CACC,KAAAH,EACA,UAAWN,EACT,sbACAK,CACF,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AEA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MAEA,MAEA,MAEA,MAEA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,MAEA,MAEA,MAEA,MAEA,MACA,MACA,MACA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,KACF,EAAGC,GAAI,CACL,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,KACF,EAAGC,GAAI,CACL,UACA,SACA,YACA,UACA,cACA,SACA,SACA,OACA,WACA,WACA,UACA,UACA,eACA,eACA,OACA,WACA,kBACA,MACA,SACA,WACA,eACA,gBACA,SACA,WACA,eACA,UACA,kBACA,QACA,OACA,OACA,UACA,QACA,QACA,QACA,WACA,YACA,SACA,YACA,UACA,UACA,OACA,OACA,OACA,OACA,SACA,gBACA,gBACA,YACA,YACA,cACA,aACA,kBACA,kBACA,YACA,YACA,QACA,WACA,UACA,QACA,UACA,UACA,SACA,SACA,SACA,OACA,aACA,QACA,SACA,eACA,oBACA,0BACA,SACA,qBACA,sBACA,UACA,qBACA,cACA,cACA,cACA,cACA,mBACA,mBACA,qBACA,YACA,OACA,oBAGA,uBACA,uBACA,sBACA,yBACA,wBACA,qBACA,UACA,UACA,UACA,UACA,UACA,UACA,UACA,eACA,cACA,eACA,oBACA,qBACA,0BACA,0BACA,eACA,eACA,YACA,gBACA,cACA,eACA,iBACA,wBACA,mBACA,WACA,QACA,aACA,aACA,aACA,2BACA,4BACA,YACF,EAAGC,GAAIC,KACP,SAASC,GAAER,EAAGJ,EAAI,GAAI,CACpB,OAAOA,IAAMI,EAAIA,EAAE,YAAa,GAAGA,KAAKM,GAAIA,GAAEN,CAAC,EAAI,CACrD,CACA,SAASS,GAAET,EAAG,CACZ,OAAOQ,GAAER,CAAC,EAAI,CAChB,CACA,SAASU,GAAE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AU,UACV,UAAWA,EACZ,EAED,EAAG,CACD,MAAOpC,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,QAAS,CACP,MAAOA,EACR,EACD,WAAY,CACV,MAAOA,EACR,EACD,aAAc,CACZ,MAAOA,EACR,EACD,cAAe,CACb,MAAOA,EACR,EACD,YAAa,CACX,MAAOA,EACR,EACD,SAAU,CACR,MAAOA,EACR,EACD,SAAU,CACR,MAAOA,EACR,EACD,cAAe,CACb,MAAOA,EACR,EACD,mBAAoB,CAClB,MAAOA,EACR,EACD,iBAAkB,CAChB,MAAOA,EACR,EACD,aAAc,CACZ,MAAOA,EACR,EACD,kBAAmB,CACjB,MAAOA,EACR,EACD,gBAAiB,CACf,MAAOA,EACR,EACD,EAAG,CACD,MAAOD,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,OAAQ,CACN,MAAOA,EACR,EACD,UAAW,CACT,MAAOA,EACR,EACD,YAAa,CACX,MAAOA,EACR,EACD,aAAc,CACZ,MAAOA,EACR,EACD,WAAY,CACV,MAAOA,EACR,EACD,QAAS,CACP,MAAOA,EACR,EACD,QAAS,CACP,MAAOA,EACR,EACD,aAAc,CACZ,MAAOA,EACR,EACD,kBAAmB,CACjB,MAAOA,EACR,EACD,gBAAiB,CACf,MAAOA,EACR,EACD,YAAa,CACX,MAAOA,EACR,EACD,iBAAkB,CAChB,MAAOA,EACR,EACD,eAAgB,CACd,MAAOA,EACR,EAED,aAAc,CACZ,YAAa,GACb,UAAWzwB,IAAU,CACnB,eAAgB,CACd,QAASA,CACV,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,GAAO,CACX,GAAI,UACJ,IAAK,UACL,IAAK,UACL,IAAK,UACL,IAAK,UACL,IAAK,UACL,IAAK,UACL,IAAK,UACL,IAAK,UACL,IAAK,UACL,KAAM,UACN,KAAM,UACN,KAAM,UACN,KAAM,SACR,EACAC,GAAeD,GChBTE,GAAS,CACb,GAAI,UACJ,IAAK,UACL,IAAK,UACL,IAAK,UACL,IAAK,UACL,IAAK,UACL,IAAK,UACL,IAAK,UACL,IAAK,UACL,IAAK,UACL,KAAM,UACN,KAAM,UACN,KAAM,UACN,KAAM,SACR,EACAC,GAAeD,GChBTE,GAAM,CACV,GAAI,UACJ,IAAK,UACL,IAAK,UACL,IAAK,UACL,IAAK,UACL,IAAK,UACL,IAAK,UACL,IAAK,UACL,IAAK,UACL,IAAK,UACL,KAAM,UACN,KAAM,UACN,KAAM,UACN,KAAM,SACR,EACAC,GAAeD,GChBTE,GAAS,CACb,GAAI,UACJ,IAAK,UACL,IAAK,UACL,IAAK,UACL,IAAK,UACL,IAAK,UACL,IAAK,UACL,IAAK,UACL,IAAK,UACL,IAAK,UACL,KAAM,UACN,KAAM,UACN,KAAM,UACN,KAAM,SACR,EACAC,GAAeD,GChBTE,GAAO,CACX,GAAI,UACJ,IAAK,UACL,IAAK,UACL,IAAK,UACL,IAAK,UACL,IAAK,UACL,IAAK,UACL,IAAK,UACL,IAAK,UACL,IAAK,UACL,KAAM,UACN,KAAM,UACN,KAAM,UACN,KAAM,SACR,EACAC,GAAeD,GChBTE,GAAY,CAChB,GAAI,UACJ,IAAK,UACL,IAAK,UACL,IAAK,UACL,IAAK,UACL,IAAK,UACL,IAAK,UACL,IAAK,UACL,IAAK,UACL,IAAK,UACL,KAAM,UACN,KAAM,UACN,KAAM,UACN,KAAM,SACR,EACAC,GAAeD,GChBTE,GAAQ,CACZ,GAAI,UACJ,IAAK,UACL,IAAK,UACL,IAAK,UACL,IAAK,UACL,IAAK,UACL,IAAK,UACL,IAAK,UACL,IAAK,UACL,IAAK,UACL,KA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;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","x_google_ignoreList":[3,43,44,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,83,84,85,86,87,88,89,90,91,92,93,94,95,96,97,98,99,100,101,102,103,104,105,106,107,108,109,110,111,112,113,114,115,116,117,118,119,120,121,122,123,124,125,126,127,128,129,130,131,132,133,134,135,136,137,138,139,140,141,142,143,144,145,146,147,148,149,150,151,152,153,154,155,156,157,158,159,160,161,162,163,164,165,166,167,168,169,170,171,172,173,174,175,176,177,178,179,180,181,182,183,184,185,186,187,188,189,190,191,192,193,194,195,196,197,198,199,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,226]} \ No newline at end of file diff --git a/lib/platform-bible-react/dist/index.d.ts b/lib/platform-bible-react/dist/index.d.ts index 9475fd80ae..19ca97bb39 100644 --- a/lib/platform-bible-react/dist/index.d.ts +++ b/lib/platform-bible-react/dist/index.d.ts @@ -436,7 +436,7 @@ export type SelectedSettingsSidebarItem = { label: string; projectId?: string; }; -type ProjectInfo = { +export type ProjectInfo = { projectId: string; projectName: string; }; @@ -446,7 +446,7 @@ export type SettingsSidebarProps = { /** Extension labels from contribution */ extensionLabels: string[]; /** Project names and ids */ - projectOptions: ProjectInfo[]; + projectInfo: ProjectInfo[]; /** Handler for selecting a sidebar item */ handleSelectSidebarItem: (key: string, projectId?: string) => void; /** The current selected value in the sidebar */ @@ -458,14 +458,14 @@ export type SettingsSidebarProps = { /** Placeholder text for the button */ buttonPlaceholderText: string; }; -export function SettingsSidebar({ id, extensionLabels, projectOptions, handleSelectSidebarItem, selectedSidebarItem, extensionsSidebarGroupLabel, projectsSidebarGroupLabel, buttonPlaceholderText, }: SettingsSidebarProps): import("react/jsx-runtime").JSX.Element; +export function SettingsSidebar({ id, extensionLabels, projectInfo, handleSelectSidebarItem, selectedSidebarItem, extensionsSidebarGroupLabel, projectsSidebarGroupLabel, buttonPlaceholderText, }: SettingsSidebarProps): import("react/jsx-runtime").JSX.Element; export type SettingsSidebarContentSearchProps = SettingsSidebarProps & React$1.PropsWithChildren & { /** Optional id for testing */ id?: string; /** Handler to run when the value of the search bar changes */ onSearch: (searchQuery: string) => void; }; -export function SettingsSidebarContentSearch({ id, extensionLabels, projectOptions, children, handleSelectSidebarItem, selectedSidebarItem, onSearch, extensionsSidebarGroupLabel, projectsSidebarGroupLabel, buttonPlaceholderText, }: SettingsSidebarContentSearchProps): import("react/jsx-runtime").JSX.Element; +export function SettingsSidebarContentSearch({ id, extensionLabels, projectInfo, children, handleSelectSidebarItem, selectedSidebarItem, onSearch, extensionsSidebarGroupLabel, projectsSidebarGroupLabel, buttonPlaceholderText, }: SettingsSidebarContentSearchProps): import("react/jsx-runtime").JSX.Element; /** * Information (e.g., a checking error or some other type of "transient" annotation) about something * noteworthy at a specific place in an instance of the Scriptures. @@ -925,6 +925,7 @@ export type IconButtonProps = React$1.PropsWithChildren<{ export declare function IconButton({ id, label, isDisabled, tooltip, isTooltipSuppressed, adjustMarginToAlignToEdge, size, className, onClick, children, }: IconButtonProps): import("react/jsx-runtime").JSX.Element; /** Props for the SearchBar component. */ export type SearchBarProps = { + /** Additional css classes to help with unique styling of the search bar */ className?: string; /** * Callback fired to handle the search query when button pressed @@ -1508,7 +1509,6 @@ export declare const usePromise: (promiseFactoryCallback: (() => Promise) export declare function cn(...inputs: ClassValue[]): string; export { - ProjectInfo as ProjectOptions, TabNavigationContentSearch as NavigationContentSearch, sonner, }; diff --git a/lib/platform-bible-react/dist/index.js b/lib/platform-bible-react/dist/index.js index c8d16060bb..0818f97413 100644 --- a/lib/platform-bible-react/dist/index.js +++ b/lib/platform-bible-react/dist/index.js @@ -3039,7 +3039,7 @@ wd.displayName = "SidebarMenuSubButton"; function fd({ id: t, extensionLabels: e, - projectOptions: n, + projectInfo: n, handleSelectSidebarItem: r, selectedSidebarItem: o, extensionsSidebarGroupLabel: a, @@ -3108,7 +3108,7 @@ function fd({ function fh({ id: t, extensionLabels: e, - projectOptions: n, + projectInfo: n, children: r, handleSelectSidebarItem: o, selectedSidebarItem: a, @@ -3131,7 +3131,7 @@ function fh({ fd, { extensionLabels: e, - projectOptions: n, + projectInfo: n, handleSelectSidebarItem: o, selectedSidebarItem: a, extensionsSidebarGroupLabel: l, diff --git a/lib/platform-bible-react/dist/index.js.map b/lib/platform-bible-react/dist/index.js.map index f5c04dc357..086d4e58af 100644 --- a/lib/platform-bible-react/dist/index.js.map +++ b/lib/platform-bible-react/dist/index.js.map @@ -1 +1 @@ -{"version":3,"file":"index.js","sources":["../src/utils/shadcn-ui.util.ts","../src/components/shadcn-ui/input.tsx","../src/components/advanced/book-chapter-control/book-chapter-input.component.tsx","../../../node_modules/@sillsdev/scripture/dist/index.es.js","../src/components/shadcn-ui/dropdown-menu.tsx","../src/components/advanced/book-chapter-control/book-menu-item.component.tsx","../src/components/advanced/book-chapter-control/chapter-select.component.tsx","../src/components/advanced/book-chapter-control/go-to-menu-item.component.tsx","../src/components/advanced/book-chapter-control/book-chapter-control.component.tsx","../src/components/shadcn-ui/button.tsx","../src/components/shadcn-ui/label.tsx","../src/components/shadcn-ui/radio-group.tsx","../src/components/shadcn-ui/popover.tsx","../src/components/shadcn-ui/dialog.tsx","../src/components/shadcn-ui/command.tsx","../src/components/basics/combo-box.component.tsx","../src/components/basics/chapter-range-selector.component.tsx","../src/components/advanced/book-selector.component.tsx","../src/components/advanced/data-table/data-table-column-toggle.component.tsx","../src/components/shadcn-ui/select.tsx","../src/components/advanced/data-table/data-table-pagination.component.tsx","../src/components/shadcn-ui/table.tsx","../src/components/advanced/data-table/data-table.component.tsx","../src/components/advanced/inventory/occurrences-table.component.tsx","../src/components/shadcn-ui/checkbox.tsx","../src/components/advanced/inventory/inventory-utils.ts","../src/components/shadcn-ui/toggle.tsx","../src/components/shadcn-ui/toggle-group.tsx","../src/components/advanced/inventory/inventory-columns.tsx","../src/components/advanced/inventory/inventory.component.tsx","../src/components/basics/search-bar.component.tsx","../src/components/basics/tabs-vertical.tsx","../src/components/advanced/tab-navigation-content-search.component.tsx","../src/components/shadcn-ui/separator.tsx","../src/components/shadcn-ui/skeleton.tsx","../src/components/shadcn-ui/tooltip.tsx","../src/components/shadcn-ui/sidebar.tsx","../src/components/advanced/settings-components/settings-sidebar.component.tsx","../src/components/advanced/settings-components/settings-sidebar-content-search.component.tsx","../src/components/advanced/scripture-results-viewer/scripture-results-viewer.component.tsx","../src/components/advanced/scroll-group-selector.component.tsx","../src/components/advanced/settings-components/settings-list.component.tsx","../src/components/basics/checklist.component.tsx","../../../node_modules/@babel/runtime/helpers/interopRequireDefault.js","../../../node_modules/@mui/utils/chainPropTypes/chainPropTypes.js","../../../node_modules/@babel/runtime/helpers/esm/extends.js","../../../node_modules/@mui/utils/deepmerge/deepmerge.js","../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.production.min.js","../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.development.js","../../../node_modules/prop-types/node_modules/react-is/index.js","../../../node_modules/object-assign/index.js","../../../node_modules/prop-types/lib/ReactPropTypesSecret.js","../../../node_modules/prop-types/lib/has.js","../../../node_modules/prop-types/checkPropTypes.js","../../../node_modules/prop-types/factoryWithTypeCheckers.js","../../../node_modules/prop-types/factoryWithThrowingShims.js","../../../node_modules/prop-types/index.js","../../../node_modules/@mui/utils/elementAcceptingRef/elementAcceptingRef.js","../../../node_modules/@mui/utils/exactProp/exactProp.js","../../../node_modules/@mui/utils/formatMuiErrorMessage/formatMuiErrorMessage.js","../../../node_modules/react-is/cjs/react-is.production.min.js","../../../node_modules/react-is/cjs/react-is.development.js","../../../node_modules/react-is/index.js","../../../node_modules/@mui/utils/getDisplayName/getDisplayName.js","../../../node_modules/@mui/utils/HTMLElementType/HTMLElementType.js","../../../node_modules/@mui/utils/refType/refType.js","../../../node_modules/@mui/utils/capitalize/capitalize.js","../../../node_modules/@mui/utils/createChainedFunction/createChainedFunction.js","../../../node_modules/@mui/utils/debounce/debounce.js","../../../node_modules/@mui/utils/deprecatedPropType/deprecatedPropType.js","../../../node_modules/@mui/utils/isMuiElement/isMuiElement.js","../../../node_modules/@mui/utils/ownerDocument/ownerDocument.js","../../../node_modules/@mui/utils/ownerWindow/ownerWindow.js","../../../node_modules/@mui/utils/requirePropFactory/requirePropFactory.js","../../../node_modules/@mui/utils/setRef/setRef.js","../../../node_modules/@mui/utils/useEnhancedEffect/useEnhancedEffect.js","../../../node_modules/@mui/utils/useId/useId.js","../../../node_modules/@mui/utils/unsupportedProp/unsupportedProp.js","../../../node_modules/@mui/utils/useControlled/useControlled.js","../../../node_modules/@mui/utils/useEventCallback/useEventCallback.js","../../../node_modules/@mui/utils/useForkRef/useForkRef.js","../../../node_modules/@mui/utils/useLazyRef/useLazyRef.js","../../../node_modules/@mui/utils/useOnMount/useOnMount.js","../../../node_modules/@mui/utils/useTimeout/useTimeout.js","../../../node_modules/@mui/utils/useIsFocusVisible/useIsFocusVisible.js","../../../node_modules/@mui/utils/resolveProps/resolveProps.js","../../../node_modules/@mui/utils/composeClasses/composeClasses.js","../../../node_modules/@mui/utils/ClassNameGenerator/ClassNameGenerator.js","../../../node_modules/@mui/utils/generateUtilityClass/generateUtilityClass.js","../../../node_modules/@mui/utils/generateUtilityClasses/generateUtilityClasses.js","../../../node_modules/@mui/utils/clamp/clamp.js","../../../node_modules/@babel/runtime/helpers/esm/objectWithoutPropertiesLoose.js","../../../node_modules/@mui/system/esm/createTheme/createBreakpoints.js","../../../node_modules/@mui/system/esm/createTheme/shape.js","../../../node_modules/@mui/system/esm/responsivePropType.js","../../../node_modules/@mui/system/esm/merge.js","../../../node_modules/@mui/system/esm/breakpoints.js","../../../node_modules/@mui/system/esm/style.js","../../../node_modules/@mui/system/esm/memoize.js","../../../node_modules/@mui/system/esm/spacing.js","../../../node_modules/@mui/system/esm/createTheme/createSpacing.js","../../../node_modules/@mui/system/esm/compose.js","../../../node_modules/@mui/system/esm/borders.js","../../../node_modules/@mui/system/esm/cssGrid.js","../../../node_modules/@mui/system/esm/palette.js","../../../node_modules/@mui/system/esm/sizing.js","../../../node_modules/@mui/system/esm/styleFunctionSx/defaultSxConfig.js","../../../node_modules/@mui/system/esm/styleFunctionSx/styleFunctionSx.js","../../../node_modules/@mui/system/esm/createTheme/applyStyles.js","../../../node_modules/@mui/system/esm/createTheme/createTheme.js","../../../node_modules/@mui/system/esm/useThemeWithoutDefault.js","../../../node_modules/@mui/system/esm/useTheme.js","../../../node_modules/@mui/system/esm/createStyled.js","../../../node_modules/@mui/system/esm/useThemeProps/getThemeProps.js","../../../node_modules/@mui/system/esm/useThemeProps/useThemeProps.js","../../../node_modules/@mui/system/esm/colorManipulator.js","../../../node_modules/@mui/material/styles/createMixins.js","../../../node_modules/@mui/material/colors/common.js","../../../node_modules/@mui/material/colors/grey.js","../../../node_modules/@mui/material/colors/purple.js","../../../node_modules/@mui/material/colors/red.js","../../../node_modules/@mui/material/colors/orange.js","../../../node_modules/@mui/material/colors/blue.js","../../../node_modules/@mui/material/colors/lightBlue.js","../../../node_modules/@mui/material/colors/green.js","../../../node_modules/@mui/material/styles/createPalette.js","../../../node_modules/@mui/material/styles/createTypography.js","../../../node_modules/@mui/material/styles/shadows.js","../../../node_modules/@mui/material/styles/createTransitions.js","../../../node_modules/@mui/material/styles/zIndex.js","../../../node_modules/@mui/material/styles/createTheme.js","../../../node_modules/@mui/material/styles/defaultTheme.js","../../../node_modules/@mui/material/styles/identifier.js","../../../node_modules/@mui/material/styles/useThemeProps.js","../../../node_modules/@mui/material/styles/styled.js","../../../node_modules/@mui/material/SvgIcon/svgIconClasses.js","../../../node_modules/@mui/material/SvgIcon/SvgIcon.js","../../../node_modules/@mui/material/utils/createSvgIcon.js","../../../node_modules/@mui/material/utils/index.js","../../../node_modules/@mui/icons-material/utils/createSvgIcon.js","../../../node_modules/@mui/icons-material/ArrowRight.js","../../../node_modules/@mui/base/utils/isHostComponent.js","../../../node_modules/@mui/base/utils/appendOwnerState.js","../../../node_modules/@mui/base/utils/ClassNameConfigurator.js","../../../node_modules/@mui/base/utils/extractEventHandlers.js","../../../node_modules/@mui/base/utils/resolveComponentProps.js","../../../node_modules/@mui/base/utils/omitEventHandlers.js","../../../node_modules/@mui/base/utils/mergeSlotProps.js","../../../node_modules/@mui/base/utils/useSlotProps.js","../../../node_modules/@mui/base/generateUtilityClass/index.js","../../../node_modules/@mui/base/generateUtilityClasses/index.js","../../../node_modules/@mui/base/Portal/Portal.js","../../../node_modules/@popperjs/core/lib/enums.js","../../../node_modules/@popperjs/core/lib/dom-utils/getNodeName.js","../../../node_modules/@popperjs/core/lib/dom-utils/getWindow.js","../../../node_modules/@popperjs/core/lib/dom-utils/instanceOf.js","../../../node_modules/@popperjs/core/lib/modifiers/applyStyles.js","../../../node_modules/@popperjs/core/lib/utils/getBasePlacement.js","../../../node_modules/@popperjs/core/lib/utils/math.js","../../../node_modules/@popperjs/core/lib/utils/userAgent.js","../../../node_modules/@popperjs/core/lib/dom-utils/isLayoutViewport.js","../../../node_modules/@popperjs/core/lib/dom-utils/getBoundingClientRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/getLayoutRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/contains.js","../../../node_modules/@popperjs/core/lib/dom-utils/getComputedStyle.js","../../../node_modules/@popperjs/core/lib/dom-utils/isTableElement.js","../../../node_modules/@popperjs/core/lib/dom-utils/getDocumentElement.js","../../../node_modules/@popperjs/core/lib/dom-utils/getParentNode.js","../../../node_modules/@popperjs/core/lib/dom-utils/getOffsetParent.js","../../../node_modules/@popperjs/core/lib/utils/getMainAxisFromPlacement.js","../../../node_modules/@popperjs/core/lib/utils/within.js","../../../node_modules/@popperjs/core/lib/utils/getFreshSideObject.js","../../../node_modules/@popperjs/core/lib/utils/mergePaddingObject.js","../../../node_modules/@popperjs/core/lib/utils/expandToHashMap.js","../../../node_modules/@popperjs/core/lib/modifiers/arrow.js","../../../node_modules/@popperjs/core/lib/utils/getVariation.js","../../../node_modules/@popperjs/core/lib/modifiers/computeStyles.js","../../../node_modules/@popperjs/core/lib/modifiers/eventListeners.js","../../../node_modules/@popperjs/core/lib/utils/getOppositePlacement.js","../../../node_modules/@popperjs/core/lib/utils/getOppositeVariationPlacement.js","../../../node_modules/@popperjs/core/lib/dom-utils/getWindowScroll.js","../../../node_modules/@popperjs/core/lib/dom-utils/getWindowScrollBarX.js","../../../node_modules/@popperjs/core/lib/dom-utils/getViewportRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/getDocumentRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/isScrollParent.js","../../../node_modules/@popperjs/core/lib/dom-utils/getScrollParent.js","../../../node_modules/@popperjs/core/lib/dom-utils/listScrollParents.js","../../../node_modules/@popperjs/core/lib/utils/rectToClientRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/getClippingRect.js","../../../node_modules/@popperjs/core/lib/utils/computeOffsets.js","../../../node_modules/@popperjs/core/lib/utils/detectOverflow.js","../../../node_modules/@popperjs/core/lib/utils/computeAutoPlacement.js","../../../node_modules/@popperjs/core/lib/modifiers/flip.js","../../../node_modules/@popperjs/core/lib/modifiers/hide.js","../../../node_modules/@popperjs/core/lib/modifiers/offset.js","../../../node_modules/@popperjs/core/lib/modifiers/popperOffsets.js","../../../node_modules/@popperjs/core/lib/utils/getAltAxis.js","../../../node_modules/@popperjs/core/lib/modifiers/preventOverflow.js","../../../node_modules/@popperjs/core/lib/dom-utils/getHTMLElementScroll.js","../../../node_modules/@popperjs/core/lib/dom-utils/getNodeScroll.js","../../../node_modules/@popperjs/core/lib/dom-utils/getCompositeRect.js","../../../node_modules/@popperjs/core/lib/utils/orderModifiers.js","../../../node_modules/@popperjs/core/lib/utils/debounce.js","../../../node_modules/@popperjs/core/lib/utils/mergeByName.js","../../../node_modules/@popperjs/core/lib/createPopper.js","../../../node_modules/@popperjs/core/lib/popper.js","../../../node_modules/@mui/base/Popper/popperClasses.js","../../../node_modules/@mui/base/Popper/Popper.js","../../../node_modules/@mui/material/styles/useTheme.js","../../../node_modules/@babel/runtime/helpers/esm/setPrototypeOf.js","../../../node_modules/@babel/runtime/helpers/esm/inheritsLoose.js","../../../node_modules/react-transition-group/esm/config.js","../../../node_modules/react-transition-group/esm/utils/PropTypes.js","../../../node_modules/react-transition-group/esm/TransitionGroupContext.js","../../../node_modules/react-transition-group/esm/utils/reflow.js","../../../node_modules/react-transition-group/esm/Transition.js","../../../node_modules/@mui/material/transitions/utils.js","../../../node_modules/@mui/material/Grow/Grow.js","../../../node_modules/@mui/material/Popper/Popper.js","../../../node_modules/@mui/material/Tooltip/tooltipClasses.js","../../../node_modules/@mui/material/Tooltip/Tooltip.js","../src/components/mui/menu-item.component.tsx","../src/components/mui/grouped-menu-item-list.component.tsx","../src/components/mui/top-level-menu.component.tsx","../src/components/mui/grid-menu.component.tsx","../src/hooks/use-promise.hook.ts","../../../node_modules/@mui/icons-material/esm/Menu.js","../src/components/mui/hamburger-menu-button.component.tsx","../src/components/mui/icon-button.component.tsx","../src/components/basics/spinner.component.tsx","../src/components/basics/text-field.component.tsx","../src/components/mui/toolbar.component.tsx","../src/components/shadcn-ui/alert.tsx","../src/components/shadcn-ui/card.tsx","../src/components/shadcn-ui/sonner.tsx","../src/components/shadcn-ui/slider.tsx","../src/components/shadcn-ui/switch.tsx","../src/components/shadcn-ui/tabs.tsx","../src/components/advanced/extension-marketplace/buttons/install-button.component.tsx","../src/components/advanced/extension-marketplace/buttons/enable-button.component.tsx","../src/components/advanced/extension-marketplace/buttons/disable-button.component.tsx","../src/components/advanced/extension-marketplace/buttons/update-button.component.tsx","../src/components/advanced/extension-marketplace/markdown-renderer.component.tsx","../src/components/advanced/extension-marketplace/buttons/filter-button.component.tsx","../src/components/advanced/extension-marketplace/filter-dropdown.component.tsx","../src/components/advanced/extension-marketplace/no-extensions-found.component.tsx","../src/components/advanced/extension-marketplace/more-info.component.tsx","../src/components/advanced/extension-marketplace/version-history.component.tsx","../src/components/advanced/extension-marketplace/footer.component.tsx","../src/hooks/use-event.hook.ts","../src/hooks/use-event-async.hook.ts"],"sourcesContent":["import { type ClassValue, clsx } from 'clsx';\nimport { extendTailwindMerge } from 'tailwind-merge';\n\nconst twMergeCustom = extendTailwindMerge({ prefix: 'tw-' });\n\n/**\n * Tailwind and CSS class application helper function. Uses\n * [`clsx`](https://www.npmjs.com/package/clsx) to make it easy to apply classes conditionally using\n * object syntax, and uses [`tailwind-merge`](https://www.npmjs.com/package/tailwind-merge) to make\n * it easy to merge/overwrite Tailwind classes in a programmer-logic-friendly way.\n *\n * Note: `tailwind-merge` is configured to use the prefix `tw-`, so you must use the same prefix\n * with any Tailwind classes you use with this function to successfully overwrite other Tailwind\n * classes. `platform-bible-react` is configured to use `tw-` as its Tailwind prefix, so any\n * Tailwind classes you pass into `platform-bible-react` components will be compared using the `tw-`\n * prefix.\n *\n * This function was popularized by\n * [shadcn/ui](https://ui.shadcn.com/docs/installation/manual#add-a-cn-helper). See [ByteGrad's\n * explanation video](https://www.youtube.com/watch?v=re2JFITR7TI) for more information.\n *\n * @example\n *\n * ```typescript\n * const borderShouldBeBlue = true;\n * const textShouldBeRed = true;\n * const heightShouldBe20 = false;\n * const classString = cn(\n * 'tw-bg-primary tw-h-10 tw-text-primary-foreground',\n * 'tw-bg-secondary',\n * {\n * 'tw-border-blue-500': borderShouldBeBlue,\n * 'tw-text-red-500': textShouldBeRed,\n * 'tw-h-20': heightShouldBe20,\n * },\n * 'some-class',\n * );\n * ```\n *\n * The resulting `classString` is `'tw-h-10 tw-bg-secondary tw-border-blue-500 tw-text-red-500\n * some-class'`\n *\n * - Notice that `'tw-bg-secondary'`, specified later, overwrote `'tw-bg-primary'`, specified earlier,\n * because they are Tailwind classes that affect the same css property\n * - Notice that `'tw-text-red-500'`, specified later, overwrote `'tw-text-primary-foreground'`,\n * specified earlier, because they are Tailwind classes that affect the same css property\n * - Notice that `'tw-h-20'`, specified later, did not overwrite `'tw-h-10'`, specified earlier,\n * because `'tw-h-20'` is part of a conditional class object and its value evaluated to `false`;\n * therefore it was not applied\n * - Notice that `'some-class'` was applied. This function is not limited only to Tailwind classes.\n *\n *\n * @param inputs Class strings or `clsx` conditional class objects to merge. Tailwind classes\n * specified later in the arguments overwrite similar Tailwind classes specified earlier in the\n * arguments\n * @returns Class string containing all applicable classes from the arguments based on the rules\n * described above\n */\n// shadcn/ui uses this export in its boilerplate code\n// eslint-disable-next-line import/prefer-default-export\nexport function cn(...inputs: ClassValue[]) {\n return twMergeCustom(clsx(inputs));\n}\n","import React from 'react';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport interface InputProps extends React.InputHTMLAttributes {}\n\nexport const Input = React.forwardRef(\n ({ className, type, ...props }, ref) => {\n return (\n \n );\n },\n);\nInput.displayName = 'Input';\n","import { FocusEventHandler, forwardRef, KeyboardEvent, MouseEventHandler } from 'react';\nimport { History } from 'lucide-react';\nimport { Input as ShadInput } from '@/components/shadcn-ui/input';\n\nexport type BookChapterInputProps = {\n handleSearch: (searchString: string) => void;\n handleKeyDown: (event: KeyboardEvent) => void;\n handleOnClick: MouseEventHandler;\n handleSubmit: () => void;\n onFocus?: FocusEventHandler;\n value: string;\n placeholder: string;\n};\n\n// Shadcn Input sets type to \"button\"- HAVE to prop spread before setting type\nconst BookChapterInput = forwardRef(\n (\n { handleSearch, handleKeyDown, handleOnClick, handleSubmit, ...props }: BookChapterInputProps,\n ref,\n ) => {\n return (\n
    \n handleSearch(event.target.value)}\n onKeyDown={(e) => {\n if (e.key === 'Enter') {\n handleSubmit();\n }\n handleKeyDown(e);\n }}\n onClick={handleOnClick}\n ref={ref}\n />\n {\n // eslint-disable-next-line no-console\n console.log('back in history');\n }}\n />\n
    \n );\n },\n);\n\nexport default BookChapterInput;\n","var P = Object.defineProperty;\nvar R = (t, e, s) => e in t ? P(t, e, { enumerable: !0, configurable: !0, writable: !0, value: s }) : t[e] = s;\nvar n = (t, e, s) => R(t, typeof e != \"symbol\" ? e + \"\" : e, s);\nclass _ {\n constructor() {\n n(this, \"books\");\n n(this, \"firstSelectedBookNum\");\n n(this, \"lastSelectedBookNum\");\n n(this, \"count\");\n n(this, \"selectedBookNumbers\");\n n(this, \"selectedBookIds\");\n }\n}\nconst N = [\n \"GEN\",\n \"EXO\",\n \"LEV\",\n \"NUM\",\n \"DEU\",\n \"JOS\",\n \"JDG\",\n \"RUT\",\n \"1SA\",\n \"2SA\",\n // 10\n \"1KI\",\n \"2KI\",\n \"1CH\",\n \"2CH\",\n \"EZR\",\n \"NEH\",\n \"EST\",\n \"JOB\",\n \"PSA\",\n \"PRO\",\n // 20\n \"ECC\",\n \"SNG\",\n \"ISA\",\n \"JER\",\n \"LAM\",\n \"EZK\",\n \"DAN\",\n \"HOS\",\n \"JOL\",\n \"AMO\",\n // 30\n \"OBA\",\n \"JON\",\n \"MIC\",\n \"NAM\",\n \"HAB\",\n \"ZEP\",\n \"HAG\",\n \"ZEC\",\n \"MAL\",\n \"MAT\",\n // 40\n \"MRK\",\n \"LUK\",\n \"JHN\",\n \"ACT\",\n \"ROM\",\n \"1CO\",\n \"2CO\",\n \"GAL\",\n \"EPH\",\n \"PHP\",\n // 50\n \"COL\",\n \"1TH\",\n \"2TH\",\n \"1TI\",\n \"2TI\",\n \"TIT\",\n \"PHM\",\n \"HEB\",\n \"JAS\",\n \"1PE\",\n // 60\n \"2PE\",\n \"1JN\",\n \"2JN\",\n \"3JN\",\n \"JUD\",\n \"REV\",\n \"TOB\",\n \"JDT\",\n \"ESG\",\n \"WIS\",\n // 70\n \"SIR\",\n \"BAR\",\n \"LJE\",\n \"S3Y\",\n \"SUS\",\n \"BEL\",\n \"1MA\",\n \"2MA\",\n \"3MA\",\n \"4MA\",\n // 80\n \"1ES\",\n \"2ES\",\n \"MAN\",\n \"PS2\",\n \"ODA\",\n \"PSS\",\n \"JSA\",\n // actual variant text for JOS, now in LXA text\n \"JDB\",\n // actual variant text for JDG, now in LXA text\n \"TBS\",\n // actual variant text for TOB, now in LXA text\n \"SST\",\n // actual variant text for SUS, now in LXA text // 90\n \"DNT\",\n // actual variant text for DAN, now in LXA text\n \"BLT\",\n // actual variant text for BEL, now in LXA text\n \"XXA\",\n \"XXB\",\n \"XXC\",\n \"XXD\",\n \"XXE\",\n \"XXF\",\n \"XXG\",\n \"FRT\",\n // 100\n \"BAK\",\n \"OTH\",\n \"3ES\",\n // Used previously but really should be 2ES\n \"EZA\",\n // Used to be called 4ES, but not actually in any known project\n \"5EZ\",\n // Used to be called 5ES, but not actually in any known project\n \"6EZ\",\n // Used to be called 6ES, but not actually in any known project\n \"INT\",\n \"CNC\",\n \"GLO\",\n \"TDX\",\n // 110\n \"NDX\",\n \"DAG\",\n \"PS3\",\n \"2BA\",\n \"LBA\",\n \"JUB\",\n \"ENO\",\n \"1MQ\",\n \"2MQ\",\n \"3MQ\",\n // 120\n \"REP\",\n \"4BA\",\n \"LAO\"\n], B = [\n \"XXA\",\n \"XXB\",\n \"XXC\",\n \"XXD\",\n \"XXE\",\n \"XXF\",\n \"XXG\",\n \"FRT\",\n \"BAK\",\n \"OTH\",\n \"INT\",\n \"CNC\",\n \"GLO\",\n \"TDX\",\n \"NDX\"\n], O = [\n \"Genesis\",\n \"Exodus\",\n \"Leviticus\",\n \"Numbers\",\n \"Deuteronomy\",\n \"Joshua\",\n \"Judges\",\n \"Ruth\",\n \"1 Samuel\",\n \"2 Samuel\",\n \"1 Kings\",\n \"2 Kings\",\n \"1 Chronicles\",\n \"2 Chronicles\",\n \"Ezra\",\n \"Nehemiah\",\n \"Esther (Hebrew)\",\n \"Job\",\n \"Psalms\",\n \"Proverbs\",\n \"Ecclesiastes\",\n \"Song of Songs\",\n \"Isaiah\",\n \"Jeremiah\",\n \"Lamentations\",\n \"Ezekiel\",\n \"Daniel (Hebrew)\",\n \"Hosea\",\n \"Joel\",\n \"Amos\",\n \"Obadiah\",\n \"Jonah\",\n \"Micah\",\n \"Nahum\",\n \"Habakkuk\",\n \"Zephaniah\",\n \"Haggai\",\n \"Zechariah\",\n \"Malachi\",\n \"Matthew\",\n \"Mark\",\n \"Luke\",\n \"John\",\n \"Acts\",\n \"Romans\",\n \"1 Corinthians\",\n \"2 Corinthians\",\n \"Galatians\",\n \"Ephesians\",\n \"Philippians\",\n \"Colossians\",\n \"1 Thessalonians\",\n \"2 Thessalonians\",\n \"1 Timothy\",\n \"2 Timothy\",\n \"Titus\",\n \"Philemon\",\n \"Hebrews\",\n \"James\",\n \"1 Peter\",\n \"2 Peter\",\n \"1 John\",\n \"2 John\",\n \"3 John\",\n \"Jude\",\n \"Revelation\",\n \"Tobit\",\n \"Judith\",\n \"Esther Greek\",\n \"Wisdom of Solomon\",\n \"Sirach (Ecclesiasticus)\",\n \"Baruch\",\n \"Letter of Jeremiah\",\n \"Song of 3 Young Men\",\n \"Susanna\",\n \"Bel and the Dragon\",\n \"1 Maccabees\",\n \"2 Maccabees\",\n \"3 Maccabees\",\n \"4 Maccabees\",\n \"1 Esdras (Greek)\",\n \"2 Esdras (Latin)\",\n \"Prayer of Manasseh\",\n \"Psalm 151\",\n \"Odes\",\n \"Psalms of Solomon\",\n // WARNING, if you change the spelling of the *obsolete* tag be sure to update\n // IsObsolete routine\n \"Joshua A. *obsolete*\",\n \"Judges B. *obsolete*\",\n \"Tobit S. *obsolete*\",\n \"Susanna Th. *obsolete*\",\n \"Daniel Th. *obsolete*\",\n \"Bel Th. *obsolete*\",\n \"Extra A\",\n \"Extra B\",\n \"Extra C\",\n \"Extra D\",\n \"Extra E\",\n \"Extra F\",\n \"Extra G\",\n \"Front Matter\",\n \"Back Matter\",\n \"Other Matter\",\n \"3 Ezra *obsolete*\",\n \"Apocalypse of Ezra\",\n \"5 Ezra (Latin Prologue)\",\n \"6 Ezra (Latin Epilogue)\",\n \"Introduction\",\n \"Concordance \",\n \"Glossary \",\n \"Topical Index\",\n \"Names Index\",\n \"Daniel Greek\",\n \"Psalms 152-155\",\n \"2 Baruch (Apocalypse)\",\n \"Letter of Baruch\",\n \"Jubilees\",\n \"Enoch\",\n \"1 Meqabyan\",\n \"2 Meqabyan\",\n \"3 Meqabyan\",\n \"Reproof (Proverbs 25-31)\",\n \"4 Baruch (Rest of Baruch)\",\n \"Laodiceans\"\n], S = K();\nfunction g(t, e = !0) {\n return e && (t = t.toUpperCase()), t in S ? S[t] : 0;\n}\nfunction k(t) {\n return g(t) > 0;\n}\nfunction x(t) {\n const e = typeof t == \"string\" ? g(t) : t;\n return e >= 40 && e <= 66;\n}\nfunction T(t) {\n return (typeof t == \"string\" ? g(t) : t) <= 39;\n}\nfunction X(t) {\n return t <= 66;\n}\nfunction V(t) {\n const e = typeof t == \"string\" ? g(t) : t;\n return w(e) && !X(e);\n}\nfunction* L() {\n for (let t = 1; t <= N.length; t++) yield t;\n}\nconst G = 1, A = N.length;\nfunction H() {\n return [\"XXA\", \"XXB\", \"XXC\", \"XXD\", \"XXE\", \"XXF\", \"XXG\"];\n}\nfunction C(t, e = \"***\") {\n const s = t - 1;\n return s < 0 || s >= N.length ? e : N[s];\n}\nfunction I(t) {\n return t <= 0 || t > A ? \"******\" : O[t - 1];\n}\nfunction y(t) {\n return I(g(t));\n}\nfunction w(t) {\n const e = typeof t == \"number\" ? C(t) : t;\n return k(e) && !B.includes(e);\n}\nfunction q(t) {\n const e = typeof t == \"number\" ? C(t) : t;\n return k(e) && B.includes(e);\n}\nfunction U(t) {\n return O[t - 1].includes(\"*obsolete*\");\n}\nfunction K() {\n const t = {};\n for (let e = 0; e < N.length; e++)\n t[N[e]] = e + 1;\n return t;\n}\nconst m = {\n allBookIds: N,\n nonCanonicalIds: B,\n bookIdToNumber: g,\n isBookIdValid: k,\n isBookNT: x,\n isBookOT: T,\n isBookOTNT: X,\n isBookDC: V,\n allBookNumbers: L,\n firstBook: G,\n lastBook: A,\n extraBooks: H,\n bookNumberToId: C,\n bookNumberToEnglishName: I,\n bookIdToEnglishName: y,\n isCanonical: w,\n isExtraMaterial: q,\n isObsolete: U\n};\nvar l = /* @__PURE__ */ ((t) => (t[t.Unknown = 0] = \"Unknown\", t[t.Original = 1] = \"Original\", t[t.Septuagint = 2] = \"Septuagint\", t[t.Vulgate = 3] = \"Vulgate\", t[t.English = 4] = \"English\", t[t.RussianProtestant = 5] = \"RussianProtestant\", t[t.RussianOrthodox = 6] = \"RussianOrthodox\", t))(l || {});\nconst h = class h {\n // private versInfo: Versification;\n constructor(e) {\n n(this, \"name\");\n n(this, \"fullPath\");\n n(this, \"isPresent\");\n n(this, \"hasVerseSegments\");\n n(this, \"isCustomized\");\n n(this, \"baseVersification\");\n n(this, \"scriptureBooks\");\n n(this, \"_type\");\n if (e == null)\n throw new Error(\"Argument undefined\");\n typeof e == \"string\" ? (this.name = e, this._type = l[e]) : (this._type = e, this.name = l[e]);\n }\n get type() {\n return this._type;\n }\n equals(e) {\n return !e.type || !this.type ? !1 : e.type === this.type;\n }\n};\nn(h, \"Original\", new h(l.Original)), n(h, \"Septuagint\", new h(l.Septuagint)), n(h, \"Vulgate\", new h(l.Vulgate)), n(h, \"English\", new h(l.English)), n(h, \"RussianProtestant\", new h(l.RussianProtestant)), n(h, \"RussianOrthodox\", new h(l.RussianOrthodox));\nlet c = h;\nfunction E(t, e) {\n const s = e[0];\n for (let r = 1; r < e.length; r++)\n t = t.split(e[r]).join(s);\n return t.split(s);\n}\nvar D = /* @__PURE__ */ ((t) => (t[t.Valid = 0] = \"Valid\", t[t.UnknownVersification = 1] = \"UnknownVersification\", t[t.OutOfRange = 2] = \"OutOfRange\", t[t.VerseOutOfOrder = 3] = \"VerseOutOfOrder\", t[t.VerseRepeated = 4] = \"VerseRepeated\", t))(D || {});\nconst i = class i {\n constructor(e, s, r, a) {\n /** Not yet implemented. */\n n(this, \"firstChapter\");\n /** Not yet implemented. */\n n(this, \"lastChapter\");\n /** Not yet implemented. */\n n(this, \"lastVerse\");\n /** Not yet implemented. */\n n(this, \"hasSegmentsDefined\");\n /** Not yet implemented. */\n n(this, \"text\");\n /** Not yet implemented. */\n n(this, \"BBBCCCVVVS\");\n /** Not yet implemented. */\n n(this, \"longHashCode\");\n /** The versification of the reference. */\n n(this, \"versification\");\n n(this, \"rtlMark\", \"‏\");\n n(this, \"_bookNum\", 0);\n n(this, \"_chapterNum\", 0);\n n(this, \"_verseNum\", 0);\n n(this, \"_verse\");\n if (r == null && a == null)\n if (e != null && typeof e == \"string\") {\n const o = e, u = s != null && s instanceof c ? s : void 0;\n this.setEmpty(u), this.parse(o);\n } else if (e != null && typeof e == \"number\") {\n const o = s != null && s instanceof c ? s : void 0;\n this.setEmpty(o), this._verseNum = e % i.chapterDigitShifter, this._chapterNum = Math.floor(\n e % i.bookDigitShifter / i.chapterDigitShifter\n ), this._bookNum = Math.floor(e / i.bookDigitShifter);\n } else if (s == null)\n if (e != null && e instanceof i) {\n const o = e;\n this._bookNum = o.bookNum, this._chapterNum = o.chapterNum, this._verseNum = o.verseNum, this._verse = o.verse, this.versification = o.versification;\n } else {\n if (e == null) return;\n const o = e instanceof c ? e : i.defaultVersification;\n this.setEmpty(o);\n }\n else\n throw new Error(\"VerseRef constructor not supported.\");\n else if (e != null && s != null && r != null)\n if (typeof e == \"string\" && typeof s == \"string\" && typeof r == \"string\")\n this.setEmpty(a), this.updateInternal(e, s, r);\n else if (typeof e == \"number\" && typeof s == \"number\" && typeof r == \"number\")\n this._bookNum = e, this._chapterNum = s, this._verseNum = r, this.versification = a ?? i.defaultVersification;\n else\n throw new Error(\"VerseRef constructor not supported.\");\n else\n throw new Error(\"VerseRef constructor not supported.\");\n }\n /**\n * Determines if the verse string is in a valid format (does not consider versification).\n */\n static isVerseParseable(e) {\n return e.length > 0 && \"0123456789\".includes(e[0]) && !e.endsWith(this.verseRangeSeparator) && !e.endsWith(this.verseSequenceIndicator);\n }\n /**\n * Tries to parse the specified string into a verse reference.\n * @param str - The string to attempt to parse.\n * @returns success: `true` if the specified string was successfully parsed, `false` otherwise.\n * @returns verseRef: The result of the parse if successful, or empty VerseRef if it failed\n */\n static tryParse(e) {\n let s;\n try {\n return s = new i(e), { success: !0, verseRef: s };\n } catch (r) {\n if (r instanceof v)\n return s = new i(), { success: !1, verseRef: s };\n throw r;\n }\n }\n /**\n * Gets the reference as a comparable integer where the book, chapter, and verse each occupy 3\n * digits.\n * @param bookNum - Book number (this is 1-based, not an index).\n * @param chapterNum - Chapter number.\n * @param verseNum - Verse number.\n * @returns The reference as a comparable integer where the book, chapter, and verse each occupy 3\n * digits.\n */\n static getBBBCCCVVV(e, s, r) {\n return e % i.bcvMaxValue * i.bookDigitShifter + (s >= 0 ? s % i.bcvMaxValue * i.chapterDigitShifter : 0) + (r >= 0 ? r % i.bcvMaxValue : 0);\n }\n /**\n * Deserializes a serialized VerseRef.\n * @param serializedVerseRef - Serialized VerseRef to create from.\n * @returns the deserialized VerseRef.\n */\n static fromJSON(e) {\n const { book: s, chapterNum: r, verseNum: a, verse: o, versificationStr: u } = e, f = o || a.toString();\n let d;\n return u && (d = new c(u)), s ? new i(s, r.toString(), f, d) : new i();\n }\n /**\n * Parses a verse string and gets the leading numeric portion as a number.\n * @param verseStr - verse string to parse\n * @returns true if the entire string could be parsed as a single, simple verse number (1-999);\n * false if the verse string represented a verse bridge, contained segment letters, or was invalid\n */\n static tryGetVerseNum(e) {\n let s;\n if (!e)\n return s = -1, { success: !0, vNum: s };\n s = 0;\n let r;\n for (let a = 0; a < e.length; a++) {\n if (r = e[a], r < \"0\" || r > \"9\")\n return a === 0 && (s = -1), { success: !1, vNum: s };\n if (s = s * 10 + +r - 0, s > i.bcvMaxValue)\n return s = -1, { success: !1, vNum: s };\n }\n return { success: !0, vNum: s };\n }\n /**\n * Checks to see if a VerseRef hasn't been set - all values are the default.\n */\n get isDefault() {\n return this.bookNum === 0 && this.chapterNum === 0 && this.verseNum === 0 && this.versification == null;\n }\n /**\n * Gets whether the verse contains multiple verses.\n */\n get hasMultiple() {\n return this._verse != null && (this._verse.includes(i.verseRangeSeparator) || this._verse.includes(i.verseSequenceIndicator));\n }\n /**\n * Gets or sets the book of the reference. Book is the 3-letter abbreviation in capital letters,\n * e.g. `'MAT'`.\n */\n get book() {\n return m.bookNumberToId(this.bookNum, \"\");\n }\n set book(e) {\n this.bookNum = m.bookIdToNumber(e);\n }\n /**\n * Gets or sets the chapter of the reference,. e.g. `'3'`.\n */\n get chapter() {\n return this.isDefault || this._chapterNum < 0 ? \"\" : this._chapterNum.toString();\n }\n set chapter(e) {\n const s = +e;\n this._chapterNum = Number.isInteger(s) ? s : -1;\n }\n /**\n * Gets or sets the verse of the reference, including range, segments, and sequences, e.g. `'4'`,\n * or `'4b-5a, 7'`.\n */\n get verse() {\n return this._verse != null ? this._verse : this.isDefault || this._verseNum < 0 ? \"\" : this._verseNum.toString();\n }\n set verse(e) {\n const { success: s, vNum: r } = i.tryGetVerseNum(e);\n this._verse = s ? void 0 : e.replace(this.rtlMark, \"\"), this._verseNum = r, !(this._verseNum >= 0) && ({ vNum: this._verseNum } = i.tryGetVerseNum(this._verse));\n }\n /**\n * Get or set Book based on book number, e.g. `42`.\n */\n get bookNum() {\n return this._bookNum;\n }\n set bookNum(e) {\n if (e <= 0 || e > m.lastBook)\n throw new v(\n \"BookNum must be greater than zero and less than or equal to last book\"\n );\n this._bookNum = e;\n }\n /**\n * Gets or sets the chapter number, e.g. `3`. `-1` if not valid.\n */\n get chapterNum() {\n return this._chapterNum;\n }\n set chapterNum(e) {\n this.chapterNum = e;\n }\n /**\n * Gets or sets verse start number, e.g. `4`. `-1` if not valid.\n */\n get verseNum() {\n return this._verseNum;\n }\n set verseNum(e) {\n this._verseNum = e;\n }\n /**\n * String representing the versification (should ONLY be used for serialization/deserialization).\n *\n * @remarks This is for backwards compatibility when ScrVers was an enumeration.\n */\n get versificationStr() {\n var e;\n return (e = this.versification) == null ? void 0 : e.name;\n }\n set versificationStr(e) {\n this.versification = this.versification != null ? new c(e) : void 0;\n }\n /**\n * Determines if the reference is valid.\n */\n get valid() {\n return this.validStatus === 0;\n }\n /**\n * Get the valid status for this reference.\n */\n get validStatus() {\n return this.validateVerse(i.verseRangeSeparators, i.verseSequenceIndicators);\n }\n /**\n * Gets the reference as a comparable integer where the book,\n * chapter, and verse each occupy three digits and the verse is 0.\n */\n get BBBCCC() {\n return i.getBBBCCCVVV(this._bookNum, this._chapterNum, 0);\n }\n /**\n * Gets the reference as a comparable integer where the book,\n * chapter, and verse each occupy three digits. If verse is not null\n * (i.e., this reference represents a complex reference with verse\n * segments or bridge) this cannot be used for an exact comparison.\n */\n get BBBCCCVVV() {\n return i.getBBBCCCVVV(this._bookNum, this._chapterNum, this._verseNum);\n }\n /**\n * Gets whether the verse is defined as an excluded verse in the versification.\n * Does not handle verse ranges.\n */\n // eslint-disable-next-line @typescript-eslint/class-literal-property-style\n get isExcluded() {\n return !1;\n }\n /**\n * Parses the reference in the specified string.\n * Optionally versification can follow reference as in GEN 3:11/4\n * Throw an exception if\n * - invalid book name\n * - chapter number is missing or not a number\n * - verse number is missing or does not start with a number\n * - versification is invalid\n * @param verseStr - string to parse e.g. 'MAT 3:11'\n */\n parse(e) {\n if (e = e.replace(this.rtlMark, \"\"), e.includes(\"/\")) {\n const o = e.split(\"/\");\n if (e = o[0], o.length > 1)\n try {\n const u = +o[1].trim();\n this.versification = new c(l[u]);\n } catch {\n throw new v(\"Invalid reference : \" + e);\n }\n }\n const s = e.trim().split(\" \");\n if (s.length !== 2)\n throw new v(\"Invalid reference : \" + e);\n const r = s[1].split(\":\"), a = +r[0];\n if (r.length !== 2 || m.bookIdToNumber(s[0]) === 0 || !Number.isInteger(a) || a < 0 || !i.isVerseParseable(r[1]))\n throw new v(\"Invalid reference : \" + e);\n this.updateInternal(s[0], r[0], r[1]);\n }\n /**\n * Simplifies this verse ref so that it has no bridging of verses or\n * verse segments like `'1a'`.\n */\n simplify() {\n this._verse = void 0;\n }\n /**\n * Makes a clone of the reference.\n *\n * @returns The cloned VerseRef.\n */\n clone() {\n return new i(this);\n }\n toString() {\n const e = this.book;\n return e === \"\" ? \"\" : `${e} ${this.chapter}:${this.verse}`;\n }\n toJSON() {\n let e = this.verse;\n (e === \"\" || e === this.verseNum.toString()) && (e = void 0);\n const s = {\n book: this.book,\n chapterNum: this.chapterNum,\n verseNum: this.verseNum,\n verse: e,\n versificationStr: this.versificationStr\n };\n return e || delete s.verse, s;\n }\n /**\n * Compares this `VerseRef` with supplied one.\n * @param verseRef - object to compare this one to.\n * @returns `true` if this `VerseRef` is equal to the supplied one, `false` otherwise.\n */\n equals(e) {\n return e instanceof i ? e._bookNum === this._bookNum && e._chapterNum === this._chapterNum && e._verseNum === this._verseNum && e.verse === this.verse && (e.versification == null && this.versification == null || e.versification != null && this.versification != null && e.versification.equals(this.versification)) : !1;\n }\n /**\n * Enumerate all individual verses contained in a VerseRef.\n * Verse ranges are indicated by \"-\" and consecutive verses by \",\"s.\n * Examples:\n * GEN 1:2 returns GEN 1:2\n * GEN 1:1a-3b,5 returns GEN 1:1a, GEN 1:2, GEN 1:3b, GEN 1:5\n * GEN 1:2a-2c returns //! ??????\n *\n * @param specifiedVersesOnly - if set to true return only verses that are\n * explicitly specified only, not verses within a range. Defaults to `false`.\n * @param verseRangeSeparators - Verse range separators.\n * Defaults to `VerseRef.verseRangeSeparators`.\n * @param verseSequenceSeparators - Verse sequence separators.\n * Defaults to `VerseRef.verseSequenceIndicators`.\n * @returns An array of all single verse references in this VerseRef.\n */\n allVerses(e = !1, s = i.verseRangeSeparators, r = i.verseSequenceIndicators) {\n if (this._verse == null || this.chapterNum <= 0)\n return [this.clone()];\n const a = [], o = E(this._verse, r);\n for (const u of o.map((f) => E(f, s))) {\n const f = this.clone();\n f.verse = u[0];\n const d = f.verseNum;\n if (a.push(f), u.length > 1) {\n const b = this.clone();\n if (b.verse = u[1], !e)\n for (let p = d + 1; p < b.verseNum; p++) {\n const J = new i(\n this._bookNum,\n this._chapterNum,\n p,\n this.versification\n );\n this.isExcluded || a.push(J);\n }\n a.push(b);\n }\n }\n return a;\n }\n /**\n * Validates a verse number using the supplied separators rather than the defaults.\n */\n validateVerse(e, s) {\n if (!this.verse)\n return this.internalValid;\n let r = 0;\n for (const a of this.allVerses(!0, e, s)) {\n const o = a.internalValid;\n if (o !== 0)\n return o;\n const u = a.BBBCCCVVV;\n if (r > u)\n return 3;\n if (r === u)\n return 4;\n r = u;\n }\n return 0;\n }\n /**\n * Gets whether a single verse reference is valid.\n */\n get internalValid() {\n return this.versification == null ? 1 : this._bookNum <= 0 || this._bookNum > m.lastBook ? 2 : (m.isCanonical(this._bookNum), 0);\n }\n setEmpty(e = i.defaultVersification) {\n this._bookNum = 0, this._chapterNum = -1, this._verse = void 0, this.versification = e;\n }\n updateInternal(e, s, r) {\n this.bookNum = m.bookIdToNumber(e), this.chapter = s, this.verse = r;\n }\n};\nn(i, \"defaultVersification\", c.English), n(i, \"verseRangeSeparator\", \"-\"), n(i, \"verseSequenceIndicator\", \",\"), n(i, \"verseRangeSeparators\", [i.verseRangeSeparator]), n(i, \"verseSequenceIndicators\", [i.verseSequenceIndicator]), n(i, \"chapterDigitShifter\", 1e3), n(i, \"bookDigitShifter\", i.chapterDigitShifter * i.chapterDigitShifter), n(i, \"bcvMaxValue\", i.chapterDigitShifter - 1), /**\n * The valid status of the VerseRef.\n */\nn(i, \"ValidStatusType\", D);\nlet M = i;\nclass v extends Error {\n}\nexport {\n _ as BookSet,\n m as Canon,\n c as ScrVers,\n l as ScrVersType,\n M as VerseRef,\n v as VerseRefException\n};\n//# sourceMappingURL=index.es.js.map\n","import React from 'react';\nimport * as DropdownMenuPrimitive from '@radix-ui/react-dropdown-menu';\nimport { Check, ChevronRight, Circle } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport const DropdownMenu = DropdownMenuPrimitive.Root;\n\nexport const DropdownMenuTrigger = DropdownMenuPrimitive.Trigger;\n\nexport const DropdownMenuGroup = DropdownMenuPrimitive.Group;\n\nexport const DropdownMenuPortal = DropdownMenuPrimitive.Portal;\n\nexport const DropdownMenuSub = DropdownMenuPrimitive.Sub;\n\nexport const DropdownMenuRadioGroup = DropdownMenuPrimitive.RadioGroup;\n\nexport type DropdownMenuSubTriggerProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.SubTrigger\n> & {\n className?: string;\n inset?: boolean;\n};\n\nexport type DropdownMenuSubContentProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.SubContent\n> & {\n className?: string;\n};\n\nexport type DropdownMenuContentProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Content\n> & {\n className?: string;\n sideOffset?: number;\n};\n\nexport type DropdownMenuItemProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Item\n> & {\n className?: string;\n inset?: boolean;\n};\n\nexport type DropdownMenuCheckboxItemProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.CheckboxItem\n> & {\n className?: string;\n checked?: boolean;\n};\n\nexport type DropdownMenuRadioItemProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.RadioItem\n> & {\n className?: string;\n};\n\nexport type DropdownMenuLabelProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Label\n> & {\n className?: string;\n inset?: boolean;\n};\n\nexport type DropdownMenuSeparatorProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Separator\n> & {\n className?: string;\n};\n\nexport type DropdownMenuShortcutProps = React.HTMLAttributes & {\n className?: string;\n};\n\nexport const DropdownMenuSubTrigger = React.forwardRef<\n React.ElementRef,\n DropdownMenuSubTriggerProps\n>(({ className, inset, children, ...props }, ref) => (\n \n {children}\n \n \n));\nDropdownMenuSubTrigger.displayName = DropdownMenuPrimitive.SubTrigger.displayName;\n\nexport const DropdownMenuSubContent = React.forwardRef<\n React.ElementRef,\n DropdownMenuSubContentProps\n>(({ className, ...props }, ref) => (\n \n));\nDropdownMenuSubContent.displayName = DropdownMenuPrimitive.SubContent.displayName;\n\nexport const DropdownMenuContent = React.forwardRef<\n React.ElementRef,\n DropdownMenuContentProps\n>(({ className, sideOffset = 4, ...props }, ref) => (\n \n \n \n));\nDropdownMenuContent.displayName = DropdownMenuPrimitive.Content.displayName;\n\n/**\n * TODO: fix: direction is not automatically handled by this component, so that shortcuts are\n * display always to the right\n */\nexport const DropdownMenuItem = React.forwardRef<\n React.ElementRef,\n DropdownMenuItemProps\n>(({ className, inset, ...props }, ref) => (\n \n));\nDropdownMenuItem.displayName = DropdownMenuPrimitive.Item.displayName;\n\nexport const DropdownMenuCheckboxItem = React.forwardRef<\n React.ElementRef,\n DropdownMenuCheckboxItemProps\n>(({ className, children, checked, ...props }, ref) => (\n \n \n \n \n \n \n {children}\n \n));\nDropdownMenuCheckboxItem.displayName = DropdownMenuPrimitive.CheckboxItem.displayName;\n\nexport const DropdownMenuRadioItem = React.forwardRef<\n React.ElementRef,\n DropdownMenuRadioItemProps\n>(({ className, children, ...props }, ref) => (\n \n \n \n \n \n \n {children}\n \n));\nDropdownMenuRadioItem.displayName = DropdownMenuPrimitive.RadioItem.displayName;\n\nexport const DropdownMenuLabel = React.forwardRef<\n React.ElementRef,\n DropdownMenuLabelProps\n>(({ className, inset, ...props }, ref) => (\n \n));\nDropdownMenuLabel.displayName = DropdownMenuPrimitive.Label.displayName;\n\nexport const DropdownMenuSeparator = React.forwardRef<\n React.ElementRef,\n DropdownMenuSeparatorProps\n>(({ className, ...props }, ref) => (\n \n));\nDropdownMenuSeparator.displayName = DropdownMenuPrimitive.Separator.displayName;\n\nexport function DropdownMenuShortcut({ className, ...props }: DropdownMenuShortcutProps) {\n return (\n \n );\n}\nDropdownMenuShortcut.displayName = 'DropdownMenuShortcut';\n","import { Canon } from '@sillsdev/scripture';\nimport { PropsWithChildren, KeyboardEvent, forwardRef } from 'react';\nimport { DropdownMenuItem as ShadDropdownMenuItem } from '@/components/shadcn-ui/dropdown-menu';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport type BookType = 'OT' | 'NT' | 'DC';\n\ntype BookMenuItemProps = PropsWithChildren<{\n /** String id of book */\n bookId: string;\n /** Callback to run when a book menu item is selected */\n handleSelectBook: () => void;\n /** Indicates if this menu item is currently selected */\n isSelected: boolean;\n /** Function that is called upon highlighting a book in the dropdown menu */\n handleHighlightBook: () => void;\n /**\n * Function that is called on pressing a key\n *\n * @param event Event that contains information about the key stroke\n */\n handleKeyDown: (event: KeyboardEvent) => void;\n /**\n * Type of book associated with this menu item, coordinates color labels ? Mock up has the labels\n * coordinated to genre\n */\n bookType: BookType;\n}>;\n\nconst BookMenuItem = forwardRef(\n (\n {\n bookId,\n handleSelectBook,\n isSelected,\n handleHighlightBook,\n handleKeyDown,\n bookType,\n children,\n }: BookMenuItemProps,\n ref,\n ) => {\n return (\n {\n // preventDefault() here prevents the entire dropdown menu from closing when selecting this item\n event.preventDefault();\n handleSelectBook();\n }}\n onKeyDown={(event: KeyboardEvent) => {\n handleKeyDown(event);\n }}\n onFocus={handleHighlightBook}\n onMouseMove={handleHighlightBook}\n >\n \n {Canon.bookIdToEnglishName(bookId)}\n \n {isSelected &&
    {children}
    }\n \n );\n },\n);\n\nexport default BookMenuItem;\n","import { cn } from '@/utils/shadcn-ui.util';\nimport { useCallback } from 'react';\n\nexport type ChapterSelectProps = {\n /**\n * Callback to run when a chapter div is selected\n *\n * @param chapterNumber Number of the chapter that has been selected\n */\n handleSelectChapter: (chapterNumber: number) => void;\n /** The highest chapter number in the book (of course equal to number of chapters in the book) */\n endChapter: number;\n /** The chapter number that is currently selected */\n activeChapter: number;\n /** The chapter number that is currently highlighted using keyboard or mouse navigation */\n highlightedChapter: number;\n /**\n * Callback to run when a chapter is highlighted by the user\n *\n * @param chapterNumber The chapter that is highlighted\n */\n handleHighlightedChapter: (chapterNumber: number) => void;\n};\n\nfunction ChapterSelect({\n handleSelectChapter,\n endChapter,\n activeChapter,\n highlightedChapter,\n handleHighlightedChapter,\n}: ChapterSelectProps) {\n const chapters = Array.from({ length: endChapter }, (_, i) => i + 1);\n\n const handleMouse = useCallback(\n (chapterNumber: number) => {\n handleHighlightedChapter(chapterNumber);\n },\n [handleHighlightedChapter],\n );\n\n return (\n
    \n {chapters.map((chapter) => (\n {\n event.preventDefault();\n event.stopPropagation();\n handleSelectChapter(chapter);\n }}\n role=\"button\"\n onKeyDown={(event) => {\n if (event.key === 'Enter') {\n handleSelectChapter(chapter);\n }\n }}\n tabIndex={0}\n onMouseMove={() => handleMouse(chapter)}\n >\n {chapter}\n
    \n ))}\n
    \n );\n}\n\nexport default ChapterSelect;\n","import { DropdownMenuLabel as ShadDropdownMenuLabel } from '@/components/shadcn-ui/dropdown-menu';\nimport { Bookmark, Clock, ArrowDownWideNarrow } from 'lucide-react';\n\nexport type GoToMenuItemProps = {\n handleSort: () => void;\n handleLocationHistory: () => void;\n handleBookmarks: () => void;\n};\n\nfunction GoToMenuItem({ handleSort, handleLocationHistory, handleBookmarks }: GoToMenuItemProps) {\n return (\n \n

    Go To

    \n
    \n \n \n \n
    \n
    \n );\n}\n\nexport default GoToMenuItem;\n","import BookChapterInput from '@/components/advanced/book-chapter-control/book-chapter-input.component';\nimport BookMenuItem, {\n BookType,\n} from '@/components/advanced/book-chapter-control/book-menu-item.component';\nimport ChapterSelect from '@/components/advanced/book-chapter-control/chapter-select.component';\nimport GoToMenuItem from '@/components/advanced/book-chapter-control/go-to-menu-item.component';\nimport {\n DropdownMenu as ShadDropdownMenu,\n DropdownMenuContent as ShadDropdownMenuContent,\n DropdownMenuLabel as ShadDropdownMenuLabel,\n DropdownMenuSeparator as ShadDropdownMenuSeparator,\n DropdownMenuTrigger as ShadDropdownMenuTrigger,\n} from '@/components/shadcn-ui/dropdown-menu';\nimport { Canon } from '@sillsdev/scripture';\nimport { ScriptureReference, getChaptersForBook } from 'platform-bible-utils';\nimport {\n KeyboardEvent as ReactKeyboardEvent,\n useCallback,\n useEffect,\n useLayoutEffect,\n useRef,\n useState,\n} from 'react';\n\ntype BookTypeLabels = {\n [bookType in BookType]: string;\n};\ntype BookChapterControlProps = {\n scrRef: ScriptureReference;\n handleSubmit: (scrRef: ScriptureReference) => void;\n};\n\nconst ALL_BOOK_IDS = Canon.allBookIds;\nconst BOOK_TYPE_LABELS: BookTypeLabels = {\n OT: 'Old Testament',\n NT: 'New Testament',\n DC: 'Deuterocanon',\n};\nconst BOOK_TYPE_ARRAY: BookType[] = ['OT', 'NT', 'DC'];\n// This is the height of three menu items to offset scrolling to the selected menu item\n// If you use menuItemRef.clientHeight- includes height of chapter div which is too big\nconst SCROLL_OFFSET = 32 + 32 + 32;\nconst SEARCH_QUERY_FORMATS = [\n /^(\\w+)$/i, // Matches a single word (book name or id)\n /^(\\w+)(?:\\s(\\d+))$/i, // Matches a word followed by a chapter number\n /^(\\w+)(?:\\s(\\d+):(\\d+))$/i, // Matches a word followed by a chapter and verse number\n];\nconst fetchGroupedBooks = (bookType: BookType) => {\n const groupedBooks = {\n OT: ALL_BOOK_IDS.filter((bookId) => Canon.isBookOT(bookId)),\n NT: ALL_BOOK_IDS.filter((bookId) => Canon.isBookNT(bookId)),\n DC: ALL_BOOK_IDS.filter((bookId) => Canon.isBookDC(bookId)),\n };\n return groupedBooks[bookType];\n};\nconst fetchEndChapter = (bookId: string) => {\n // getChaptersForBook returns -1 if not found in scrBookData\n // scrBookData only includes OT and NT, so all DC will return -1\n return getChaptersForBook(Canon.bookIdToNumber(bookId));\n};\n\n/**\n * Gets all of the English names from book ids\n *\n * @returns String[]\n */\nfunction getAllEnglishNames(): string[] {\n const allEnglishNames = ALL_BOOK_IDS.map((bookId) => {\n return Canon.bookIdToEnglishName(bookId);\n });\n return allEnglishNames;\n}\n\n/**\n * Determines if bookName is in allEnglishNames\n *\n * @param bookName Book English name\n * @returns True if bookName is included, false otherwise\n */\nfunction isValidBookEnglishName(bookName: string): boolean {\n return getAllEnglishNames().includes(bookName);\n}\n\n/**\n * Gets a bookId from given English name\n *\n * @param bookName Book English name\n * @returns BookId of provided bookName, undefined otherwise\n */\nfunction getBookIdFromEnglishName(bookName: string): string | undefined {\n // Convert bookName to lowercase and then capitalize the first letter\n const formattedBookName = bookName.toLowerCase().replace(/^\\w/, (c) => c.toUpperCase());\n\n if (isValidBookEnglishName(formattedBookName)) {\n const matchingBookId = ALL_BOOK_IDS.find((bookId) => {\n return Canon.bookIdToEnglishName(bookId) === formattedBookName;\n });\n return matchingBookId;\n }\n\n return undefined;\n}\n\nfunction BookChapterControl({ scrRef, handleSubmit }: BookChapterControlProps) {\n const [searchQuery, setSearchQuery] = useState('');\n const [selectedBookId, setSelectedBookId] = useState(\n Canon.bookNumberToId(scrRef.bookNum),\n );\n const [highlightedChapter, setHighlightedChapter] = useState(scrRef.chapterNum ?? 0);\n const [highlightedBookId, setHighlightedBookId] = useState(\n Canon.bookNumberToId(scrRef.bookNum),\n );\n const [isContentOpen, setIsContentOpen] = useState(false);\n const [isContentOpenDelayed, setIsContentOpenDelayed] = useState(isContentOpen);\n\n // This ref will always be defined\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const inputRef = useRef(undefined!);\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const contentRef = useRef(undefined!);\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const menuItemRef = useRef(undefined!);\n\n const fetchFilteredBooks = useCallback(\n (bookType: BookType) => {\n return fetchGroupedBooks(bookType).filter((bookId: string) => {\n const englishNameLowerCase = Canon.bookIdToEnglishName(bookId).toLowerCase();\n const normalizedQuery = searchQuery.replace(/[^a-zA-Z]/g, '').toLowerCase();\n return (\n englishNameLowerCase.includes(normalizedQuery) || // Match book name\n bookId.toLowerCase().includes(normalizedQuery) // Match book ID\n );\n });\n },\n [searchQuery],\n );\n\n const handleSearchInput = (searchString: string) => {\n setSearchQuery(searchString);\n };\n\n /**\n * Whether to prevent radix's logic from closing the dropdown. This is important because radix\n * tries to close the dropdown when the input first focuses, and we don't want it to do that. But\n * we don't want to prevent the dropdown from closing when we click away from the input, so we\n * don't want to just keep it open if the input is focused\n */\n const shouldPreventAutoClosing = useRef(false);\n\n const controlMenuState = useCallback((open: boolean) => {\n if (shouldPreventAutoClosing.current) {\n shouldPreventAutoClosing.current = false;\n return;\n }\n setIsContentOpen(open);\n }, []);\n\n const updateReference = useCallback(\n (bookId: string, shouldClose: boolean, chapter?: number, verse?: number) => {\n setHighlightedChapter(\n Canon.bookNumberToId(scrRef.bookNum) !== bookId ? 1 : scrRef.chapterNum,\n );\n\n if (shouldClose || fetchEndChapter(bookId) === -1) {\n handleSubmit({\n bookNum: Canon.bookIdToNumber(bookId),\n chapterNum: chapter || 1,\n verseNum: verse || 1,\n });\n\n setIsContentOpen(false);\n setSearchQuery('');\n return;\n }\n\n setSelectedBookId(selectedBookId !== bookId ? bookId : '');\n setIsContentOpen(!shouldClose);\n },\n [handleSubmit, scrRef.bookNum, scrRef.chapterNum, selectedBookId],\n );\n\n const handleSelectChapter = (chapterNumber: number) => {\n if (chapterNumber <= 0 || chapterNumber > fetchEndChapter(selectedBookId)) {\n return;\n }\n updateReference(selectedBookId, true, chapterNumber);\n };\n\n const handleInputSubmit = useCallback(() => {\n SEARCH_QUERY_FORMATS.forEach((format) => {\n const matches = searchQuery.match(format);\n if (matches) {\n // Book should be a bookId or an english name\n const [book, chapter = undefined, verse = undefined] = matches.slice(1);\n const englishName = getBookIdFromEnglishName(book);\n\n if (Canon.isBookIdValid(book) || englishName) {\n updateReference(\n englishName ?? book,\n true,\n chapter ? parseInt(chapter, 10) : 1,\n verse ? parseInt(verse, 10) : 1,\n );\n }\n }\n });\n }, [updateReference, searchQuery]);\n\n const handleKeyDownInput = useCallback(\n (event: ReactKeyboardEvent) => {\n if (!isContentOpen) {\n setIsContentOpen(true);\n } else if (event.key === 'ArrowDown' || event.key === 'ArrowUp') {\n if (\n typeof menuItemRef !== 'undefined' &&\n // Ref uses null\n // eslint-disable-next-line no-null/no-null\n menuItemRef.current !== null\n ) {\n menuItemRef.current.focus();\n } else if (\n typeof contentRef !== 'undefined' &&\n // Ref uses null\n // eslint-disable-next-line no-null/no-null\n contentRef.current !== null\n ) {\n contentRef.current.focus();\n }\n event.preventDefault();\n }\n },\n [isContentOpen],\n );\n\n const handleKeyDownContent = (event: ReactKeyboardEvent) => {\n // When the dropdown menu has focus, key strokes should give focus to the input component,\n // unless they're navigation keys (arrows and enter)\n const { key } = event;\n if (\n key === 'ArrowRight' ||\n key === 'ArrowLeft' ||\n key === 'ArrowDown' ||\n key === 'ArrowUp' ||\n key === 'Enter'\n ) {\n return;\n }\n\n inputRef.current.dispatchEvent(new KeyboardEvent('keydown', { key }));\n inputRef.current.focus();\n };\n\n const handleKeyDownMenuItem = (event: ReactKeyboardEvent) => {\n const { key } = event;\n if (highlightedBookId === selectedBookId) {\n if (key === 'Enter') {\n event.preventDefault();\n updateReference(selectedBookId, true, highlightedChapter);\n return;\n }\n\n let chapterOffSet = 0;\n if (key === 'ArrowRight') {\n if (highlightedChapter < fetchEndChapter(highlightedBookId)) {\n chapterOffSet = 1;\n } else {\n event.preventDefault();\n return;\n }\n } else if (key === 'ArrowLeft') {\n if (highlightedChapter > 1) {\n chapterOffSet = -1;\n } else {\n event.preventDefault();\n return;\n }\n } else if (key === 'ArrowDown') {\n chapterOffSet = 6;\n } else if (key === 'ArrowUp') {\n chapterOffSet = -6;\n }\n if (\n highlightedChapter + chapterOffSet <= 0 ||\n highlightedChapter + chapterOffSet > fetchEndChapter(highlightedBookId)\n ) {\n setHighlightedChapter(0);\n } else if (chapterOffSet !== 0) {\n setHighlightedChapter(highlightedChapter + chapterOffSet);\n event.preventDefault();\n }\n }\n };\n\n useEffect(() => {\n if (selectedBookId === highlightedBookId) {\n if (selectedBookId === Canon.bookNumberToId(scrRef.bookNum)) {\n setHighlightedChapter(scrRef.chapterNum);\n } else {\n setHighlightedChapter(1);\n }\n } else {\n setHighlightedChapter(0);\n }\n }, [highlightedBookId, scrRef.bookNum, scrRef.chapterNum, selectedBookId]);\n\n // The purpose of these useLayoutEffects and timeout is to delay the scroll just\n // enough so that the refs are defined and available when they are used after the timeout\n useLayoutEffect(() => {\n setIsContentOpenDelayed(isContentOpen);\n }, [isContentOpen]);\n\n useLayoutEffect(() => {\n const scrollTimeout = setTimeout(() => {\n if (isContentOpenDelayed && contentRef.current && menuItemRef.current) {\n const menuItemOffsetTop = menuItemRef.current.offsetTop;\n const scrollPosition = menuItemOffsetTop - SCROLL_OFFSET;\n contentRef.current.scrollTo({ top: scrollPosition, behavior: 'instant' });\n }\n }, 10);\n return () => {\n clearTimeout(scrollTimeout);\n };\n }, [isContentOpenDelayed]);\n\n return (\n
    \n \n \n {\n setSelectedBookId(Canon.bookNumberToId(scrRef.bookNum));\n setHighlightedBookId(Canon.bookNumberToId(scrRef.bookNum));\n setHighlightedChapter(scrRef.chapterNum > 0 ? scrRef.chapterNum : 0);\n setIsContentOpen(true);\n inputRef.current.focus();\n }}\n onFocus={() => {\n // Radix thinks we want to close because the input is being focused. Prevent that\n shouldPreventAutoClosing.current = true;\n }}\n handleSubmit={handleInputSubmit}\n placeholder={`${Canon.bookNumberToEnglishName(scrRef.bookNum)} ${scrRef.chapterNum}:${scrRef.verseNum}`}\n />\n \n \n console.log('sorting')}\n handleLocationHistory={() => console.log('location history')}\n handleBookmarks={() => console.log('bookmarks')}\n />\n {BOOK_TYPE_ARRAY.map(\n (bookType, bookTypeIndex) =>\n fetchFilteredBooks(bookType).length > 0 && (\n
    \n \n {BOOK_TYPE_LABELS[bookType]}\n \n\n {fetchFilteredBooks(bookType).map((bookId) => (\n
    \n updateReference(bookId, false)}\n isSelected={selectedBookId === bookId}\n handleHighlightBook={() => setHighlightedBookId(bookId)}\n handleKeyDown={handleKeyDownMenuItem}\n bookType={bookType}\n ref={(element: HTMLDivElement) => {\n if (selectedBookId === bookId) menuItemRef.current = element;\n }}\n >\n {\n setHighlightedChapter(chapterNumber);\n }}\n />\n \n
    \n ))}\n {BOOK_TYPE_ARRAY.length - 1 !== bookTypeIndex ? (\n \n ) : undefined}\n
    \n ),\n )}\n \n
    \n
    \n );\n}\n\nexport default BookChapterControl;\n","import React from 'react';\nimport { Slot } from '@radix-ui/react-slot';\nimport { cva, type VariantProps } from 'class-variance-authority';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport const buttonVariants = cva(\n 'pr-twp tw-inline-flex tw-items-center tw-justify-center tw-whitespace-nowrap tw-rounded-md tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-colors focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50',\n {\n variants: {\n variant: {\n default: 'tw-bg-primary tw-text-primary-foreground hover:tw-bg-primary/90',\n destructive: 'tw-bg-destructive tw-text-destructive-foreground hover:tw-bg-destructive/90',\n outline:\n 'tw-border tw-border-input tw-bg-background hover:tw-bg-accent hover:tw-text-accent-foreground',\n secondary: 'tw-bg-secondary tw-text-secondary-foreground hover:tw-bg-secondary/80',\n ghost: 'hover:tw-bg-accent hover:tw-text-accent-foreground',\n link: 'tw-text-primary tw-underline-offset-4 hover:tw-underline',\n },\n size: {\n default: 'tw-h-10 tw-px-4 tw-py-2',\n sm: 'tw-h-9 tw-rounded-md tw-px-3',\n lg: 'tw-h-11 tw-rounded-md tw-px-8',\n icon: 'tw-h-10 tw-w-10',\n },\n },\n defaultVariants: {\n variant: 'default',\n size: 'default',\n },\n },\n);\n\nexport interface ButtonProps\n extends React.ButtonHTMLAttributes,\n VariantProps {\n asChild?: boolean;\n}\n\nexport const Button = React.forwardRef(\n ({ className, variant, size, asChild = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'button';\n return (\n \n );\n },\n);\nButton.displayName = 'Button';\n","import React from 'react';\nimport * as LabelPrimitive from '@radix-ui/react-label';\nimport { cva, type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst labelVariants = cva(\n 'tw-text-sm tw-font-medium tw-leading-none peer-disabled:tw-cursor-not-allowed peer-disabled:tw-opacity-70',\n);\n\nexport const Label = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef & VariantProps\n>(({ className, ...props }, ref) => (\n \n));\nLabel.displayName = LabelPrimitive.Root.displayName;\n","import React from 'react';\nimport * as RadioGroupPrimitive from '@radix-ui/react-radio-group';\nimport { Circle } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst RadioGroup = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => {\n return (\n \n );\n});\nRadioGroup.displayName = RadioGroupPrimitive.Root.displayName;\n\nconst RadioGroupItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => {\n return (\n \n \n \n \n \n );\n});\nRadioGroupItem.displayName = RadioGroupPrimitive.Item.displayName;\n\nexport { RadioGroup, RadioGroupItem };\n","import React from 'react';\nimport * as PopoverPrimitive from '@radix-ui/react-popover';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Popover = PopoverPrimitive.Root;\n\nconst PopoverTrigger = PopoverPrimitive.Trigger;\n\nconst PopoverContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, align = 'center', sideOffset = 4, ...props }, ref) => (\n \n \n \n));\nPopoverContent.displayName = PopoverPrimitive.Content.displayName;\n\nexport { Popover, PopoverTrigger, PopoverContent };\n","import React from 'react';\nimport * as DialogPrimitive from '@radix-ui/react-dialog';\nimport { X } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Dialog = DialogPrimitive.Root;\n\nconst DialogTrigger = DialogPrimitive.Trigger;\n\nconst DialogPortal = DialogPrimitive.Portal;\n\nconst DialogClose = DialogPrimitive.Close;\n\nconst DialogOverlay = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nDialogOverlay.displayName = DialogPrimitive.Overlay.displayName;\n\nconst DialogContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, ...props }, ref) => (\n \n \n \n {children}\n \n \n Close\n \n \n \n));\nDialogContent.displayName = DialogPrimitive.Content.displayName;\n\nfunction DialogHeader({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nDialogHeader.displayName = 'DialogHeader';\n\nfunction DialogFooter({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nDialogFooter.displayName = 'DialogFooter';\n\nconst DialogTitle = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nDialogTitle.displayName = DialogPrimitive.Title.displayName;\n\nconst DialogDescription = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nDialogDescription.displayName = DialogPrimitive.Description.displayName;\n\nexport {\n Dialog,\n DialogPortal,\n DialogOverlay,\n DialogClose,\n DialogTrigger,\n DialogContent,\n DialogHeader,\n DialogFooter,\n DialogTitle,\n DialogDescription,\n};\n","import React from 'react';\nimport { type DialogProps } from '@radix-ui/react-dialog';\nimport { Command as CommandPrimitive } from 'cmdk';\nimport { Search } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Dialog, DialogContent } from '@/components/shadcn-ui/dialog';\n\nconst Command = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nCommand.displayName = CommandPrimitive.displayName;\n\ninterface CommandDialogProps extends DialogProps {}\n\nfunction CommandDialog({ children, ...props }: CommandDialogProps) {\n return (\n \n \n \n {children}\n \n \n \n );\n}\n\nconst CommandInput = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n
    \n \n \n
    \n));\n\nCommandInput.displayName = CommandPrimitive.Input.displayName;\n\nconst CommandList = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\n\nCommandList.displayName = CommandPrimitive.List.displayName;\n\nconst CommandEmpty = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>((props, ref) => (\n \n));\n\nCommandEmpty.displayName = CommandPrimitive.Empty.displayName;\n\nconst CommandGroup = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\n\nCommandGroup.displayName = CommandPrimitive.Group.displayName;\n\nconst CommandSeparator = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nCommandSeparator.displayName = CommandPrimitive.Separator.displayName;\n\nconst CommandItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\n\nCommandItem.displayName = CommandPrimitive.Item.displayName;\n\nfunction CommandShortcut({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nCommandShortcut.displayName = 'CommandShortcut';\n\nexport {\n Command,\n CommandDialog,\n CommandInput,\n CommandList,\n CommandEmpty,\n CommandGroup,\n CommandItem,\n CommandShortcut,\n CommandSeparator,\n};\n","import { useState } from 'react';\nimport { Check, ChevronsUpDown } from 'lucide-react';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport { Popover, PopoverContent, PopoverTrigger } from '@/components/shadcn-ui/popover';\nimport {\n Command,\n CommandEmpty,\n CommandInput,\n CommandItem,\n CommandList,\n} from '@/components/shadcn-ui/command';\nimport { PopoverProps } from '@radix-ui/react-popover';\n\nexport type ComboBoxLabelOption = { label: string };\nexport type ComboBoxOption = string | number | ComboBoxLabelOption;\n\nexport type ComboBoxProps = {\n /** Optional unique identifier */\n id?: string;\n /** Text label title for combobox */\n /** List of available options for the dropdown menu */\n options?: readonly T[];\n /** @deprecated 3 December 2024. Renamed to {@link buttonClassName} */\n className?: string;\n /** Additional css classes to help with unique styling of the combo box button */\n buttonClassName?: string;\n /** Additional css classes to help with unique styling of the combo box popover */\n popoverContentClassName?: string;\n /**\n * The selected value that the combo box currently holds. Must be shallow equal to one of the\n * options entries.\n */\n value?: T;\n /** Triggers when content of textfield is changed */\n onChange?: (newValue: T) => void;\n /** Used to determine the string value for a given option. */\n getOptionLabel?: (option: ComboBoxOption) => string;\n /** Text displayed on button if `value` is undefined */\n buttonPlaceholder?: string;\n /** Placeholder text for text field */\n textPlaceholder?: string;\n /** Text to display when no options match input */\n commandEmptyMessage?: string;\n /** Variant of button */\n buttonVariant?: ButtonProps['variant'];\n /** Text direction ltr or rtl */\n dir?: Direction;\n /** Optional boolean to set if trigger should be disabled */\n isDisabled?: boolean;\n} & PopoverProps;\n\ntype Direction = 'ltr' | 'rtl';\n\nfunction getOptionLabelDefault(option: ComboBoxOption): string {\n if (typeof option === 'string') {\n return option;\n }\n if (typeof option === 'number') {\n return option.toString();\n }\n return option.label;\n}\n\n/**\n * Autocomplete input and command palette with a list of suggestions.\n *\n * Thanks to Shadcn for heavy inspiration and documentation\n * https://ui.shadcn.com/docs/components/combobox\n */\nfunction ComboBox({\n id,\n options = [],\n buttonClassName,\n popoverContentClassName,\n value,\n onChange = () => {},\n getOptionLabel = getOptionLabelDefault,\n buttonPlaceholder = '',\n textPlaceholder = '',\n commandEmptyMessage = 'No option found',\n buttonVariant = 'outline',\n dir = 'ltr',\n isDisabled = false,\n ...props\n}: ComboBoxProps) {\n const [open, setOpen] = useState(false);\n\n return (\n \n \n \n \n {value ? getOptionLabel(value) : buttonPlaceholder}\n \n \n \n \n \n \n \n {commandEmptyMessage}\n \n {options.map((option) => (\n {\n onChange(option);\n setOpen(false);\n }}\n >\n \n {getOptionLabel(option)}\n \n ))}\n \n \n \n \n );\n}\n\nexport default ComboBox;\n","import { useMemo } from 'react';\nimport ComboBox from '@/components/basics/combo-box.component';\nimport { Label } from '@/components/shadcn-ui/label';\n\nexport type ChapterRangeSelectorProps = {\n startChapter: number;\n endChapter: number;\n handleSelectStartChapter: (chapter: number) => void;\n handleSelectEndChapter: (chapter: number) => void;\n isDisabled?: boolean;\n chapterCount: number;\n};\n\nexport default function ChapterRangeSelector({\n startChapter,\n endChapter,\n handleSelectStartChapter,\n handleSelectEndChapter,\n isDisabled = false,\n chapterCount,\n}: ChapterRangeSelectorProps) {\n const chapterOptions = useMemo(\n () => Array.from({ length: chapterCount }, (_, index) => index + 1),\n [chapterCount],\n );\n\n const onChangeStartChapter = (value: number) => {\n handleSelectStartChapter(value);\n if (value > endChapter) {\n handleSelectEndChapter(value);\n }\n };\n\n const onChangeEndChapter = (value: number) => {\n handleSelectEndChapter(value);\n if (value < startChapter) {\n handleSelectStartChapter(value);\n }\n };\n\n return (\n <>\n \n option.toString()}\n value={startChapter}\n />\n\n \n option.toString()}\n value={endChapter}\n />\n \n );\n}\n","import { Button } from '@/components/shadcn-ui/button';\nimport { Label } from '@/components/shadcn-ui/label';\nimport { RadioGroup, RadioGroupItem } from '@/components/shadcn-ui/radio-group';\nimport { Canon } from '@sillsdev/scripture';\nimport { LocalizedStringValue } from 'platform-bible-utils';\nimport { useState } from 'react';\nimport ChapterRangeSelector, {\n ChapterRangeSelectorProps,\n} from '../basics/chapter-range-selector.component';\n\nexport enum BookSelectionMode {\n CURRENT_BOOK = 'current book',\n CHOOSE_BOOKS = 'choose books',\n}\n\n/**\n * Object containing all keys used for localization in this component. If you're using this\n * component in an extension, you can pass it into the useLocalizedStrings hook to easily obtain the\n * localized strings and pass them into the localizedStrings prop of this component\n */\nexport const BOOK_SELECTOR_STRING_KEYS = Object.freeze([\n '%webView_bookSelector_currentBook%',\n '%webView_bookSelector_choose%',\n '%webView_bookSelector_chooseBooks%',\n] as const);\n\nexport type BookSelectorLocalizedStrings = {\n [localizedInventoryKey in (typeof BOOK_SELECTOR_STRING_KEYS)[number]]?: LocalizedStringValue;\n};\n\n/**\n * Gets the localized value for the provided key\n *\n * @param strings Object containing localized string\n * @param key Key for a localized string\n * @returns The localized value for the provided key, if available. Returns the key if no localized\n * value is available\n */\nconst localizeString = (\n strings: BookSelectorLocalizedStrings,\n key: keyof BookSelectorLocalizedStrings,\n) => {\n return strings[key] ?? key;\n};\n\ntype BookSelectorProps = ChapterRangeSelectorProps & {\n handleBookSelectionModeChange: (newMode: BookSelectionMode) => void;\n currentBookName: string;\n onSelectBooks: () => void;\n selectedBookIds: string[];\n localizedStrings: BookSelectorLocalizedStrings;\n};\n\nexport default function BookSelector({\n handleBookSelectionModeChange,\n currentBookName,\n onSelectBooks,\n selectedBookIds,\n chapterCount,\n endChapter,\n handleSelectEndChapter,\n startChapter,\n handleSelectStartChapter,\n localizedStrings,\n}: BookSelectorProps) {\n const currentBookText = localizeString(localizedStrings, '%webView_bookSelector_currentBook%');\n const chooseText = localizeString(localizedStrings, '%webView_bookSelector_choose%');\n const chooseBooksText = localizeString(localizedStrings, '%webView_bookSelector_chooseBooks%');\n\n const [bookSelectionMode, setBookSelectionMode] = useState(\n BookSelectionMode.CURRENT_BOOK,\n );\n\n const onSelectionModeChange = (newMode: BookSelectionMode) => {\n setBookSelectionMode(newMode);\n handleBookSelectionModeChange(newMode);\n };\n\n return (\n onSelectionModeChange(value as BookSelectionMode)}\n >\n
    \n
    \n
    \n \n \n
    \n \n
    \n \n
    \n
    \n
    \n
    \n \n \n
    \n \n onSelectBooks()}\n >\n {chooseText}\n \n
    \n
    \n \n );\n}\n","import { DropdownMenuTrigger } from '@radix-ui/react-dropdown-menu';\nimport { FilterIcon } from 'lucide-react';\nimport { Table } from '@tanstack/react-table';\n\nimport { Button } from '@/components/shadcn-ui/button';\nimport {\n DropdownMenu,\n DropdownMenuCheckboxItem,\n DropdownMenuContent,\n DropdownMenuLabel,\n DropdownMenuSeparator,\n} from '@/components/shadcn-ui/dropdown-menu';\n\ninterface DataTableViewOptionsProps {\n table: Table;\n}\n\nfunction DataTableViewOptions({ table }: DataTableViewOptionsProps) {\n return (\n \n \n \n \n \n Toggle columns\n \n {table\n .getAllColumns()\n .filter((column) => column.getCanHide())\n .map((column) => {\n return (\n column.toggleVisibility(!!value)}\n >\n {column.id}\n \n );\n })}\n \n \n );\n}\n\nexport default DataTableViewOptions;\n","import React from 'react';\nimport * as SelectPrimitive from '@radix-ui/react-select';\nimport { Check, ChevronDown, ChevronUp } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Select = SelectPrimitive.Root;\n\nconst SelectGroup = SelectPrimitive.Group;\n\nconst SelectValue = SelectPrimitive.Value;\n\nconst SelectTrigger = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, ...props }, ref) => (\n span]:tw-line-clamp-1',\n className,\n )}\n {...props}\n >\n {children}\n \n \n \n \n));\nSelectTrigger.displayName = SelectPrimitive.Trigger.displayName;\n\nconst SelectScrollUpButton = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n));\nSelectScrollUpButton.displayName = SelectPrimitive.ScrollUpButton.displayName;\n\nconst SelectScrollDownButton = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n));\nSelectScrollDownButton.displayName = SelectPrimitive.ScrollDownButton.displayName;\n\nconst SelectContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, position = 'popper', ...props }, ref) => (\n \n \n \n \n {children}\n \n \n \n \n));\nSelectContent.displayName = SelectPrimitive.Content.displayName;\n\nconst SelectLabel = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSelectLabel.displayName = SelectPrimitive.Label.displayName;\n\nconst SelectItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, ...props }, ref) => (\n \n \n \n \n \n \n\n {children}\n \n));\nSelectItem.displayName = SelectPrimitive.Item.displayName;\n\nconst SelectSeparator = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSelectSeparator.displayName = SelectPrimitive.Separator.displayName;\n\nexport {\n Select,\n SelectGroup,\n SelectValue,\n SelectTrigger,\n SelectContent,\n SelectLabel,\n SelectItem,\n SelectSeparator,\n SelectScrollUpButton,\n SelectScrollDownButton,\n};\n","import { ChevronLeftIcon, ChevronRightIcon, ArrowLeftIcon, ArrowRightIcon } from 'lucide-react';\nimport { Table } from '@tanstack/react-table';\n\nimport { Button } from '@/components/shadcn-ui/button';\nimport {\n Select,\n SelectContent,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\n\ninterface DataTablePaginationProps {\n table: Table;\n}\n\nfunction DataTablePagination({ table }: DataTablePaginationProps) {\n return (\n
    \n
    \n
    \n {table.getFilteredSelectedRowModel().rows.length} of{' '}\n {table.getFilteredRowModel().rows.length} row(s) selected\n
    \n
    \n

    Rows per page

    \n {\n table.setPageSize(Number(value));\n }}\n >\n \n \n \n \n {[10, 20, 30, 40, 50].map((pageSize) => (\n \n {pageSize}\n \n ))}\n \n \n
    \n
    \n Page {table.getState().pagination.pageIndex + 1} of {table.getPageCount()}\n
    \n
    \n table.setPageIndex(0)}\n disabled={!table.getCanPreviousPage()}\n >\n Go to first page\n \n \n table.previousPage()}\n disabled={!table.getCanPreviousPage()}\n >\n Go to previous page\n \n \n table.nextPage()}\n disabled={!table.getCanNextPage()}\n >\n Go to next page\n \n \n table.setPageIndex(table.getPageCount() - 1)}\n disabled={!table.getCanNextPage()}\n >\n Go to last page\n \n \n
    \n
    \n
    \n );\n}\n\nexport default DataTablePagination;\n","import React from 'react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Table = React.forwardRef<\n HTMLTableElement,\n React.HTMLAttributes & { stickyHeader?: boolean }\n>(({ className, stickyHeader, ...props }, ref) => (\n
    \n \n
    \n));\nTable.displayName = 'Table';\n\nconst TableHeader = React.forwardRef<\n HTMLTableSectionElement,\n React.HTMLAttributes & { stickyHeader?: boolean }\n>(({ className, stickyHeader, ...props }, ref) => (\n \n));\nTableHeader.displayName = 'TableHeader';\n\nconst TableBody = React.forwardRef<\n HTMLTableSectionElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableBody.displayName = 'TableBody';\n\nconst TableFooter = React.forwardRef<\n HTMLTableSectionElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n tr]:last:tw-border-b-0', className)}\n {...props}\n />\n));\nTableFooter.displayName = 'TableFooter';\n\nconst TableRow = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nTableRow.displayName = 'TableRow';\n\nconst TableHead = React.forwardRef<\n HTMLTableCellElement,\n React.ThHTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableHead.displayName = 'TableHead';\n\nconst TableCell = React.forwardRef<\n HTMLTableCellElement,\n React.TdHTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableCell.displayName = 'TableCell';\n\nconst TableCaption = React.forwardRef<\n HTMLTableCaptionElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableCaption.displayName = 'TableCaption';\n\nexport { Table, TableHeader, TableBody, TableFooter, TableHead, TableRow, TableCell, TableCaption };\n","import { useState } from 'react';\n\nimport {\n ColumnFiltersState,\n flexRender,\n getCoreRowModel,\n getFilteredRowModel,\n getPaginationRowModel,\n getSortedRowModel,\n SortingState,\n ColumnDef as TSColumnDef,\n Row as TSRow,\n RowSelectionState as TSRowSelectionState,\n SortDirection as TSSortDirection,\n Table as TSTable,\n useReactTable,\n VisibilityState,\n} from '@tanstack/react-table';\n\nimport DataTableViewOptions from '@/components/advanced/data-table/data-table-column-toggle.component';\nimport DataTablePagination from '@/components/advanced/data-table/data-table-pagination.component';\nimport { Button } from '@/components/shadcn-ui/button';\nimport {\n Table,\n TableBody,\n TableCell,\n TableHead,\n TableHeader,\n TableRow,\n} from '@/components/shadcn-ui/table';\n\nexport type ColumnDef = TSColumnDef;\nexport type RowContents = TSRow;\nexport type TableContents = TSTable;\nexport type SortDirection = TSSortDirection;\nexport type RowSelectionState = TSRowSelectionState;\n\ninterface DataTableProps {\n columns: ColumnDef[];\n data: TData[];\n enablePagination?: boolean;\n showPaginationControls?: boolean;\n showColumnVisibilityControls?: boolean;\n stickyHeader?: boolean;\n onRowClickHandler?: (row: RowContents, table: TableContents) => void;\n}\n\n/**\n * Feature-rich table component that infuses our basic shadcn-based Table component with features\n * from TanStack's React Table library\n */\nfunction DataTable({\n columns,\n data,\n enablePagination = false,\n showPaginationControls = false,\n showColumnVisibilityControls = false,\n stickyHeader = false,\n onRowClickHandler = () => {},\n}: DataTableProps) {\n const [sorting, setSorting] = useState([]);\n const [columnFilters, setColumnFilters] = useState([]);\n const [columnVisibility, setColumnVisibility] = useState({});\n const [rowSelection, setRowSelection] = useState({});\n\n const table = useReactTable({\n data,\n columns,\n getCoreRowModel: getCoreRowModel(),\n ...(enablePagination && { getPaginationRowModel: getPaginationRowModel() }),\n onSortingChange: setSorting,\n getSortedRowModel: getSortedRowModel(),\n onColumnFiltersChange: setColumnFilters,\n getFilteredRowModel: getFilteredRowModel(),\n onColumnVisibilityChange: setColumnVisibility,\n onRowSelectionChange: setRowSelection,\n state: {\n sorting,\n columnFilters,\n columnVisibility,\n rowSelection,\n },\n });\n\n return (\n
    \n {showColumnVisibilityControls && }\n \n \n {table.getHeaderGroups().map((headerGroup) => (\n \n {headerGroup.headers.map((header) => {\n return (\n \n {header.isPlaceholder\n ? undefined\n : flexRender(header.column.columnDef.header, header.getContext())}\n \n );\n })}\n \n ))}\n \n \n {table.getRowModel().rows?.length ? (\n table.getRowModel().rows.map((row) => (\n onRowClickHandler(row, table)}\n key={row.id}\n data-state={row.getIsSelected() && 'selected'}\n >\n {row.getVisibleCells().map((cell) => (\n \n {flexRender(cell.column.columnDef.cell, cell.getContext())}\n \n ))}\n \n ))\n ) : (\n \n \n No results.\n \n \n )}\n \n
    \n {enablePagination && (\n
    \n table.previousPage()}\n disabled={!table.getCanPreviousPage()}\n >\n Previous\n \n table.nextPage()}\n disabled={!table.getCanNextPage()}\n >\n Next\n \n
    \n )}\n {enablePagination && showPaginationControls && }\n
    \n );\n}\n\nexport default DataTable;\n","import {\n Table,\n TableBody,\n TableCell,\n TableHead,\n TableHeader,\n TableRow,\n} from '@/components/shadcn-ui/table';\nimport { Canon } from '@sillsdev/scripture';\nimport { deepEqual, LanguageStrings, ScriptureReference } from 'platform-bible-utils';\nimport { useMemo } from 'react';\nimport { InventoryItemOccurrence } from './inventory-utils';\n\n/** Props for the OccurrencesTable component */\ntype OccurrencesTableProps = {\n /** Data that contains scriptures references and snippets of scripture */\n occurrenceData: InventoryItemOccurrence[];\n /** Callback function that is executed when the scripture reference is changed */\n setScriptureReference: (scriptureReference: ScriptureReference) => void;\n /**\n * Object with all localized strings that the OccurrencesTable needs to work well across multiple\n * languages\n */\n localizedStrings: LanguageStrings;\n};\n\n/**\n * Table that shows occurrences of specified inventory item(s). The first column shows the related\n * scripture reference. The second column shows the snippet of scripture that contains the specified\n * inventory item\n */\nfunction OccurrencesTable({\n occurrenceData,\n setScriptureReference,\n localizedStrings,\n}: OccurrencesTableProps) {\n const referenceHeaderText =\n localizedStrings['%webView_inventory_occurrences_table_header_reference%'];\n const occurrenceHeaderText =\n localizedStrings['%webView_inventory_occurrences_table_header_occurrence%'];\n\n const occurrences: InventoryItemOccurrence[] = useMemo(() => {\n const uniqueOccurrences: InventoryItemOccurrence[] = [];\n\n occurrenceData.forEach((occurrence) => {\n if (!uniqueOccurrences.some((uniqueOccurrence) => deepEqual(uniqueOccurrence, occurrence))) {\n uniqueOccurrences.push(occurrence);\n }\n });\n\n return uniqueOccurrences;\n }, [occurrenceData]);\n\n return (\n \n \n \n {referenceHeaderText}\n {occurrenceHeaderText}\n \n \n \n {occurrences.length > 0 &&\n occurrences.map((occurrence) => (\n {\n setScriptureReference(occurrence.reference);\n }}\n >\n {`${Canon.bookNumberToEnglishName(occurrence.reference.bookNum)} ${occurrence.reference.chapterNum}:${occurrence.reference.verseNum}`}\n {occurrence.text}\n \n ))}\n \n
    \n );\n}\n\nexport default OccurrencesTable;\n","import React from 'react';\nimport * as CheckboxPrimitive from '@radix-ui/react-checkbox';\nimport { Check } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Checkbox = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n \n \n));\nCheckbox.displayName = CheckboxPrimitive.Root.displayName;\n\nexport default Checkbox;\n","import { Canon } from '@sillsdev/scripture';\nimport { ScriptureReference } from 'platform-bible-utils';\n\n/* #region Types */\n\n/**\n * Status of items that appear in inventories. 'approved' and 'unapproved' items are defined in the\n * project's `Settings.xml`. All other items are defined as 'unknown'\n */\nexport type Status = 'approved' | 'unapproved' | 'unknown';\n\n/** Occurrence of item in inventory. Primarily used by table that shows occurrences */\nexport type InventoryItemOccurrence = {\n /** Reference to scripture where the item appears */\n reference: ScriptureReference;\n /** Snippet of scripture that contains the occurrence */\n text: string;\n};\n\n/** Data structure that contains all information on an item that is shown in an inventory */\nexport type InventoryTableData = {\n /**\n * The item (e.g. a character in the characters inventory, a marker in the marker inventory) In\n * most cases the array will only have one element. In case of additional items (e.g. the\n * preceding marker in the markers check), the primary item should be stored in the first index.\n * To show additional items in the inventory, make sure to configure the `additionalItemsLabels`\n * prop for the Inventory component\n */\n items: string[];\n /** The number of times this item occurs in the selected scope */\n count: number;\n /** The status of this item (see documentation for `Status` type for more information) */\n status: Status;\n /** Occurrences of this item in the scripture text for the selected scope */\n occurrences: InventoryItemOccurrence[];\n};\n\n/* #endregion */\n\n/* #region Functions */\n\n/**\n * Splits USFM string into shorter line-like segments\n *\n * @param text A single (likely very large) USFM string\n * @returns An array containing the input text, split into shorter segments\n */\nexport const getLinesFromUSFM = (text: string) => {\n // Splits on (CR)LF, CR, \\v, \\c and \\id\n return text.split(/(?:\\r?\\n|\\r)|(?=(?:\\\\(?:v|c|id)))/g);\n};\n\n/**\n * Extracts chapter or verse number from USFM strings that start with a \\c or \\v marker\n *\n * @param text USFM string that is expected to start with \\c or \\v marker\n * @returns Chapter or verse number if one is found. Else returns 0.\n */\nexport const getNumberFromUSFM = (text: string): number | undefined => {\n // Captures all digits that follow \\v or \\c markers followed by whitespace located at the start of a string\n const regex = /^\\\\[vc]\\s+(\\d+)/;\n const match = text.match(regex);\n\n if (match) {\n return +match[1];\n }\n return undefined;\n};\n\n/**\n * Gets book ID from USFM string that starts with the \\id marker, and returns book number for it\n *\n * @param text USFM string that is expected to start with \\id marker\n * @returns Book number corresponding to the \\id marker in the input text. Returns 0 if no marker is\n * found or the marker is not valid\n */\nexport const getBookNumFromId = (text: string): number => {\n // Captures all digits that follow an \\id marker followed by whitespace located at the start of a string\n const match = text.match(/^\\\\id\\s+([A-Za-z]+)/);\n if (match) {\n return Canon.bookIdToNumber(match[1]);\n }\n return 0;\n};\n\n/**\n * Gets the status for an item, typically used in the Inventory component\n *\n * @param item The item for which the status is being requested\n * @param approvedItems Array of approved items, typically as defined in `Settings.xml`\n * @param unapprovedItems Array of unapproved items, typically as defined in `Settings.xml`\n * @returns The status for the specified item\n */\nexport const getStatusForItem = (\n item: string,\n approvedItems: string[],\n unapprovedItems: string[],\n): Status => {\n if (unapprovedItems.includes(item)) return 'unapproved';\n if (approvedItems.includes(item)) return 'approved';\n return 'unknown';\n};\n\n/* #endregion */\n","import React from 'react';\nimport * as TogglePrimitive from '@radix-ui/react-toggle';\nimport { cva, type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst toggleVariants = cva(\n 'pr-twp tw-inline-flex tw-items-center tw-justify-center tw-rounded-md tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-colors hover:tw-bg-muted hover:tw-text-muted-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50 data-[state=on]:tw-bg-accent data-[state=on]:tw-text-accent-foreground',\n {\n variants: {\n variant: {\n default: 'tw-bg-transparent',\n outline:\n 'tw-border tw-border-input tw-bg-transparent hover:tw-bg-accent hover:tw-text-accent-foreground',\n },\n size: {\n default: 'tw-h-10 tw-px-3',\n sm: 'tw-h-9 tw-px-2.5',\n lg: 'tw-h-11 tw-px-5',\n },\n },\n defaultVariants: {\n variant: 'default',\n size: 'default',\n },\n },\n);\n\nconst Toggle = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef & VariantProps\n>(({ className, variant, size, ...props }, ref) => (\n \n));\n\nToggle.displayName = TogglePrimitive.Root.displayName;\n\nexport { Toggle, toggleVariants };\n","import React from 'react';\nimport * as ToggleGroupPrimitive from '@radix-ui/react-toggle-group';\nimport { type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { toggleVariants } from '@/components/shadcn-ui/toggle';\n\nconst ToggleGroupContext = React.createContext>({\n size: 'default',\n variant: 'default',\n});\n\nconst ToggleGroup = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef &\n VariantProps\n>(({ className, variant, size, children, ...props }, ref) => (\n \n \n {children}\n \n \n));\n\nToggleGroup.displayName = ToggleGroupPrimitive.Root.displayName;\n\nconst ToggleGroupItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef &\n VariantProps\n>(({ className, children, variant, size, ...props }, ref) => {\n const context = React.useContext(ToggleGroupContext);\n\n return (\n \n {children}\n \n );\n});\n\nToggleGroupItem.displayName = ToggleGroupPrimitive.Item.displayName;\n\nexport { ToggleGroup, ToggleGroupItem };\n","import { ColumnDef, SortDirection } from '@/components/advanced/data-table/data-table.component';\nimport { Button } from '@/components/shadcn-ui/button';\nimport { ToggleGroup, ToggleGroupItem } from '@/components/shadcn-ui/toggle-group';\nimport {\n ArrowDownIcon,\n ArrowUpDownIcon,\n ArrowUpIcon,\n CircleCheckIcon,\n CircleHelpIcon,\n CircleXIcon,\n} from 'lucide-react';\nimport { ReactNode } from 'react';\nimport { InventoryTableData, Status } from './inventory-utils';\n\n/**\n * Gets an icon that indicates the current sorting direction based on the provided input\n *\n * @param sortDirection Sorting direction. Can be ascending ('asc'), descending ('desc') or false (\n * i.e. not sorted)\n * @returns The appropriate sorting icon for the provided sorting direction\n */\nconst getSortingIcon = (sortDirection: false | SortDirection): ReactNode => {\n if (sortDirection === 'asc') {\n return ;\n }\n if (sortDirection === 'desc') {\n return ;\n }\n return ;\n};\n\n/**\n * Function that creates the item column for inventories\n *\n * @param itemLabel Localized label for the item column (e.g. 'Character', 'Repeated Word', etc.)\n * @returns Column that shows the inventory items. Should be used with the DataTable component\n */\nexport const inventoryItemColumn = (itemLabel: string): ColumnDef => {\n return {\n accessorKey: 'item',\n accessorFn: (row: InventoryTableData) => row.items[0],\n header: ({ column }) => (\n \n ),\n };\n};\n\n/**\n * Function that creates the additional item columns for inventories\n *\n * @param additionalItemLabel Localized label for the additional item column (e.g. 'Preceding\n * Marker')\n * @param additionalItemIndex Index that locates the desired item in the items array of the\n * inventory\n * @returns Column that shows additional inventory items. Should be used with the DataTable\n * component\n */\nexport const inventoryAdditionalItemColumn = (\n additionalItemLabel: string,\n additionalItemIndex: number,\n): ColumnDef => {\n return {\n accessorKey: `item${additionalItemIndex}`,\n accessorFn: (row: InventoryTableData) => row.items[additionalItemIndex],\n header: ({ column }) => (\n \n ),\n };\n};\n\n/**\n * Function that creates the count column for inventories. Should be used with the DataTable\n * component.\n *\n * @param itemLabel Localized label for the count column\n * @returns Column that shows the number of occurrences of the related inventory items\n */\nexport const inventoryCountColumn = (countLabel: string): ColumnDef => {\n return {\n accessorKey: 'count',\n header: ({ column }) => (\n
    \n \n
    \n ),\n cell: ({ row }) =>
    {row.getValue('count')}
    ,\n };\n};\n\n/**\n * Function that updates project settings when status for item(s) changes\n *\n * @param changedItems Array of items for which the status is being updated\n * @param newStatus The status that the items are being given\n * @param approvedItems Array of currently approved items\n * @param onApprovedItemsChange Callback function that stores the updated list of approved items\n * @param unapprovedItems Array of currently unapproved items\n * @param onUnapprovedItemsChange Callback function that stores the updated list of unapproved items\n */\nconst statusChangeHandler = (\n changedItems: string[],\n newStatus: Status,\n approvedItems: string[],\n onApprovedItemsChange: (items: string[]) => void,\n unapprovedItems: string[],\n onUnapprovedItemsChange: (items: string[]) => void,\n) => {\n let newApprovedItems: string[] = [...approvedItems];\n changedItems.forEach((item) => {\n if (newStatus === 'approved') {\n if (!newApprovedItems.includes(item)) {\n newApprovedItems.push(item);\n }\n } else {\n newApprovedItems = newApprovedItems.filter((validItem) => validItem !== item);\n }\n });\n onApprovedItemsChange(newApprovedItems);\n\n let newUnapprovedItems: string[] = [...unapprovedItems];\n changedItems.forEach((item) => {\n if (newStatus === 'unapproved') {\n if (!newUnapprovedItems.includes(item)) {\n newUnapprovedItems.push(item);\n }\n } else {\n newUnapprovedItems = newUnapprovedItems.filter((unapprovedItem) => unapprovedItem !== item);\n }\n });\n onUnapprovedItemsChange(newUnapprovedItems);\n};\n\n/**\n * Function that creates the status column for inventories. Should be used with the DataTable\n * component.\n *\n * @param statusLabel Localized label for the status column\n * @param approvedItems Array of approved items, typically as defined in `Settings.xml`\n * @param onApprovedItemsChange Callback function that stores the updated list of approved items\n * @param unapprovedItems Array of unapproved items, typically as defined in `Settings.xml`\n * @param onUnapprovedItemsChange Callback function that stores the updated list of unapproved items\n * @returns Column that shows the status buttons for the related inventory item. The button for the\n * current status of the item is selected\n */\nexport const inventoryStatusColumn = (\n statusLabel: string,\n approvedItems: string[],\n onApprovedItemsChange: (items: string[]) => void,\n unapprovedItems: string[],\n onUnapprovedItemsChange: (items: string[]) => void,\n): ColumnDef => {\n return {\n accessorKey: 'status',\n header: ({ column }) => {\n return (\n
    \n \n
    \n );\n },\n cell: ({ row }) => {\n const status: Status = row.getValue('status');\n const item: string = row.getValue('item');\n return (\n \n \n statusChangeHandler(\n [item],\n 'approved',\n approvedItems,\n onApprovedItemsChange,\n unapprovedItems,\n onUnapprovedItemsChange,\n )\n }\n value=\"approved\"\n >\n \n \n \n statusChangeHandler(\n [item],\n 'unapproved',\n approvedItems,\n onApprovedItemsChange,\n unapprovedItems,\n onUnapprovedItemsChange,\n )\n }\n value=\"unapproved\"\n >\n \n \n \n statusChangeHandler(\n [item],\n 'unknown',\n approvedItems,\n onApprovedItemsChange,\n unapprovedItems,\n onUnapprovedItemsChange,\n )\n }\n value=\"unknown\"\n >\n \n \n \n );\n },\n };\n};\n","import DataTable, {\n ColumnDef,\n RowContents,\n RowSelectionState,\n TableContents,\n} from '@/components/advanced/data-table/data-table.component';\nimport OccurrencesTable from '@/components/advanced/inventory/occurrences-table.component';\nimport Checkbox from '@/components/shadcn-ui/checkbox';\nimport { Input } from '@/components/shadcn-ui/input';\nimport { Label } from '@/components/shadcn-ui/label';\nimport {\n Select,\n SelectContent,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\nimport {\n deepEqual,\n LocalizedStringValue,\n ScriptureReference,\n substring,\n} from 'platform-bible-utils';\nimport { useEffect, useMemo, useState } from 'react';\nimport {\n getBookNumFromId,\n getLinesFromUSFM,\n getNumberFromUSFM,\n getStatusForItem,\n InventoryItemOccurrence,\n InventoryTableData,\n Status,\n} from './inventory-utils';\nimport { inventoryAdditionalItemColumn } from './inventory-columns';\n\n/**\n * Object containing all keys used for localization in this component. If you're using this\n * component in an extension, you can pass it into the useLocalizedStrings hook to easily obtain the\n * localized strings and pass them into the localizedStrings prop of this component\n */\nexport const INVENTORY_STRING_KEYS = Object.freeze([\n '%webView_inventory_all%',\n '%webView_inventory_approved%',\n '%webView_inventory_unapproved%',\n '%webView_inventory_unknown%',\n '%webView_inventory_scope_currentBook%',\n '%webView_inventory_scope_chapter%',\n '%webView_inventory_scope_verse%',\n '%webView_inventory_filter_text%',\n '%webView_inventory_show_additional_items%',\n '%webView_inventory_occurrences_table_header_reference%',\n '%webView_inventory_occurrences_table_header_occurrence%',\n] as const);\n\nexport type InventoryLocalizedStrings = {\n [localizedInventoryKey in (typeof INVENTORY_STRING_KEYS)[number]]?: LocalizedStringValue;\n};\n\n/** Scope of scripture that the inventory can operate on */\nexport type Scope = 'book' | 'chapter' | 'verse';\n\n/** Status values that the status filter can select from */\ntype StatusFilter = Status | 'all';\n\n/** Text labels for the inventory columns and the control components of additional inventory items */\ntype AdditionalItemsLabels = {\n checkboxText?: string;\n tableHeaders?: string[];\n};\n\n/**\n * Filters data that is shown in the DataTable section of the Inventory\n *\n * @param itemData All inventory items and their related information\n * @param statusFilter Allows filtering by status (i.e. show all items, or only items that are\n * 'approved', 'unapproved' or 'unknown')\n * @param textFilter Allows filtering by text. All items that include the filter text will be\n * selected.\n * @returns Array of items and their related information that are matched by the specified filters\n */\nconst filterItemData = (\n itemData: InventoryTableData[],\n statusFilter: StatusFilter,\n textFilter: string,\n): InventoryTableData[] => {\n let filteredItemData: InventoryTableData[] = itemData;\n\n if (statusFilter !== 'all') {\n filteredItemData = filteredItemData.filter(\n (item) =>\n (statusFilter === 'approved' && item.status === 'approved') ||\n (statusFilter === 'unapproved' && item.status === 'unapproved') ||\n (statusFilter === 'unknown' && item.status === 'unknown'),\n );\n }\n\n if (textFilter !== '')\n filteredItemData = filteredItemData.filter((item) => item.items[0].includes(textFilter));\n\n return filteredItemData;\n};\n\n/**\n * Turns array of strings into array of inventory items, along with their count and status\n *\n * @param text The source scripture text that is searched for inventory items\n * @param scriptureRef The scripture reference that the application is currently set to\n * @param approvedItems Array of approved items, typically as defined in `Settings.xml`\n * @param unapprovedItems Array of unapproved items, typically as defined in `Settings.xml`\n * @param itemRegex Regular expression that describes what items this Inventory should extract from\n * the provided scripture text\n * @returns Array of inventory items, along with their count and status\n */\nconst createTableData = (\n text: string | undefined,\n scriptureRef: ScriptureReference,\n approvedItems: string[],\n unapprovedItems: string[],\n itemRegex: RegExp,\n): InventoryTableData[] => {\n if (!text) return [];\n\n const tableData: InventoryTableData[] = [];\n\n let currentBook: number | undefined = scriptureRef.bookNum;\n let currentChapter: number | undefined = scriptureRef.chapterNum;\n let currentVerse: number | undefined = scriptureRef.verseNum;\n\n const lines = getLinesFromUSFM(text);\n\n lines.forEach((line: string) => {\n if (line.startsWith('\\\\id')) {\n currentBook = getBookNumFromId(line);\n currentChapter = 0;\n currentVerse = 0;\n }\n if (line.startsWith('\\\\c')) {\n currentChapter = getNumberFromUSFM(line);\n currentVerse = 0;\n }\n if (line.startsWith('\\\\v')) {\n currentVerse = getNumberFromUSFM(line);\n if (currentChapter === 0) {\n currentChapter = scriptureRef.chapterNum;\n }\n }\n\n let match: RegExpExecArray | undefined = itemRegex.exec(line) ?? undefined;\n while (match) {\n const items: string[] = [];\n match.forEach((item) => items.push(item));\n const itemIndex = match.index;\n const existingItem = tableData.find((tableEntry) => deepEqual(tableEntry.items, items));\n const newReference: InventoryItemOccurrence = {\n reference: {\n bookNum: currentBook !== undefined ? currentBook : -1,\n chapterNum: currentChapter !== undefined ? currentChapter : -1,\n verseNum: currentVerse !== undefined ? currentVerse : -1,\n },\n text: substring(line, Math.max(0, itemIndex - 25), Math.min(itemIndex + 25, line.length)),\n };\n if (existingItem) {\n existingItem.count += 1;\n existingItem.occurrences.push(newReference);\n } else {\n const newItem: InventoryTableData = {\n items,\n count: 1,\n status: getStatusForItem(items[0], approvedItems, unapprovedItems),\n occurrences: [newReference],\n };\n tableData.push(newItem);\n }\n\n match = itemRegex.exec(line) ?? undefined;\n }\n });\n\n return tableData;\n};\n\n/**\n * Gets the localized value for the provided key\n *\n * @param strings Object containing localized string\n * @param key Key for a localized string\n * @returns The localized value for the provided key, if available. Returns the key if no localized\n * value is available\n */\nconst localizeString = (\n strings: InventoryLocalizedStrings,\n key: keyof InventoryLocalizedStrings,\n) => {\n return strings[key] ?? key;\n};\n\n/** Props for the Inventory component */\ntype InventoryProps = {\n /** The scripture reference that the application is currently set to */\n scriptureReference: ScriptureReference;\n /** Callback function that is executed when the scripture reference is changed */\n setScriptureReference: (scriptureReference: ScriptureReference) => void;\n /**\n * Object with all localized strings that the Inventory needs to work well across multiple\n * languages. When using this component with Platform.Bible, you can import\n * `INVENTORY_STRING_KEYS` from this library, pass it in to the Platform's localization hook, and\n * pass the localized keys that are returned by the hook into this prop.\n */\n localizedStrings: InventoryLocalizedStrings;\n /**\n * The logic that finds the desired items in the source text. This can either be a Regular\n * expression that captures one or multiple items (preferred), or a custom function that builds\n * and return an InventoryDataTable[] manually. Note: In case the logic captures more than one\n * item (i.e. InventoryTableData.items has a length greater than 1), you must provide text labels\n * for the related columns and control elements to show by setting the `additionalItemsLabels`\n * prop\n */\n extractItems:\n | RegExp\n | ((\n text: string | undefined,\n scriptureRef: ScriptureReference,\n approvedItems: string[],\n unapprovedItems: string[],\n ) => InventoryTableData[]);\n /**\n * Text labels for control elements and additional column headers in case your Inventory has more\n * than one item to show (e.g. The 'Preceding Marker' in the Markers Inventory)\n */\n additionalItemsLabels?: AdditionalItemsLabels;\n /** Array of approved items, typically as defined in `Settings.xml` */\n approvedItems: string[];\n /** Array of unapproved items, typically as defined in `Settings.xml` */\n unapprovedItems: string[];\n /** The source scripture text that is searched for in inventory items */\n text: string | undefined;\n /** Scope of scripture that the inventory will operate on */\n scope: Scope;\n /** Callback function that is executed when the scope is changed from the Inventory */\n onScopeChange: (scope: Scope) => void;\n /**\n * Column definitions for the Inventory data table. The most commonly used column definitions are\n * pre-configured for your convenience and can be imported (e.g. inventoryItemColumn,\n * inventoryAdditionalItemColumn inventoryCountColumn, and inventoryStatusColumn). If you need any\n * other columns you can add these yourself\n */\n columns: ColumnDef[];\n};\n\n/** Inventory component that is used to view and control the status of provided project settings */\nexport default function Inventory({\n scriptureReference,\n setScriptureReference,\n localizedStrings,\n extractItems,\n additionalItemsLabels,\n approvedItems,\n unapprovedItems,\n text,\n scope,\n onScopeChange,\n columns,\n}: InventoryProps) {\n const allItemsText = localizeString(localizedStrings, '%webView_inventory_all%');\n const approvedItemsText = localizeString(localizedStrings, '%webView_inventory_approved%');\n const unapprovedItemsText = localizeString(localizedStrings, '%webView_inventory_unapproved%');\n const unknownItemsText = localizeString(localizedStrings, '%webView_inventory_unknown%');\n const scopeBookText = localizeString(localizedStrings, '%webView_inventory_scope_currentBook%');\n const scopeChapterText = localizeString(localizedStrings, '%webView_inventory_scope_chapter%');\n const scopeVerseText = localizeString(localizedStrings, '%webView_inventory_scope_verse%');\n const filterText = localizeString(localizedStrings, '%webView_inventory_filter_text%');\n const showAdditionalItemsText = localizeString(\n localizedStrings,\n '%webView_inventory_show_additional_items%',\n );\n\n const [showAdditionalItems, setShowAdditionalItems] = useState(false);\n const [statusFilter, setStatusFilter] = useState('all');\n const [textFilter, setTextFilter] = useState('');\n const [selectedItem, setSelectedItem] = useState([]);\n\n const tableData: InventoryTableData[] = useMemo(() => {\n if (!text) return [];\n if (extractItems instanceof RegExp)\n return createTableData(\n text,\n scriptureReference,\n approvedItems,\n unapprovedItems,\n extractItems,\n );\n return extractItems(text, scriptureReference, approvedItems, unapprovedItems);\n }, [text, extractItems, scriptureReference, approvedItems, unapprovedItems]);\n\n const reducedTableData: InventoryTableData[] = useMemo(() => {\n if (showAdditionalItems) return tableData;\n\n const newTableData: InventoryTableData[] = [];\n\n tableData.forEach((tableEntry) => {\n const firstItem = tableEntry.items[0];\n\n const existingEntry = newTableData.find(\n (newTableEntry) => newTableEntry.items[0] === firstItem,\n );\n\n if (existingEntry) {\n existingEntry.count += tableEntry.count;\n existingEntry.occurrences = existingEntry.occurrences.concat(tableEntry.occurrences);\n } else {\n newTableData.push({\n items: [firstItem],\n count: tableEntry.count,\n occurrences: tableEntry.occurrences,\n status: tableEntry.status,\n });\n }\n });\n\n return newTableData;\n }, [showAdditionalItems, tableData]);\n\n const filteredTableData: InventoryTableData[] = useMemo(() => {\n return filterItemData(reducedTableData, statusFilter, textFilter);\n }, [reducedTableData, statusFilter, textFilter]);\n\n const allColumns: ColumnDef[] = useMemo(() => {\n if (!showAdditionalItems) return columns;\n\n const numberOfAdditionalItems = additionalItemsLabels?.tableHeaders?.length;\n if (!numberOfAdditionalItems) return columns;\n\n const additionalColumns: ColumnDef[] = [];\n\n for (let index = 0; index < numberOfAdditionalItems; index++) {\n additionalColumns.push(\n inventoryAdditionalItemColumn(\n additionalItemsLabels?.tableHeaders?.[index] || 'Additional Item',\n index + 1,\n ),\n );\n }\n\n return [...additionalColumns, ...columns];\n }, [additionalItemsLabels?.tableHeaders, columns, showAdditionalItems]);\n\n useEffect(() => {\n setSelectedItem([]);\n }, [filteredTableData]);\n\n const rowClickHandler = (\n row: RowContents,\n table: TableContents,\n ) => {\n table.setRowSelection(() => {\n const newSelection: RowSelectionState = {};\n newSelection[row.index] = true;\n return newSelection;\n });\n\n setSelectedItem(row.original.items);\n };\n\n const handleScopeChange = (value: string) => {\n if (value === 'book' || value === 'chapter' || value === 'verse') {\n onScopeChange(value);\n } else {\n throw new Error(`Invalid scope value: ${value}`);\n }\n };\n\n const handleStatusFilterChange = (value: string) => {\n if (value === 'all' || value === 'approved' || value === 'unapproved' || value === 'unknown') {\n setStatusFilter(value);\n } else {\n throw new Error(`Invalid status filter value: ${value}`);\n }\n };\n\n const occurrenceData: InventoryItemOccurrence[] = useMemo(() => {\n if (reducedTableData.length === 0 || selectedItem.length === 0) return [];\n const occurrence = reducedTableData.filter((tableEntry: InventoryTableData) => {\n return deepEqual(\n showAdditionalItems ? tableEntry.items : [tableEntry.items[0]],\n selectedItem,\n );\n });\n if (occurrence.length > 1) throw new Error('Selected item is not unique');\n return occurrence[0].occurrences;\n }, [selectedItem, showAdditionalItems, reducedTableData]);\n\n return (\n
    \n
    \n handleStatusFilterChange(value)}\n defaultValue={statusFilter}\n >\n \n \n \n \n {allItemsText}\n {approvedItemsText}\n {unapprovedItemsText}\n {unknownItemsText}\n \n \n \n {\n setTextFilter(event.target.value);\n }}\n />\n {additionalItemsLabels && (\n
    \n {\n setSelectedItem([]);\n setShowAdditionalItems(checked);\n }}\n />\n \n
    \n )}\n
    \n
    \n \n
    \n {occurrenceData.length > 0 && (\n
    \n \n
    \n )}\n
    \n );\n}\n","import { Input } from '@/components/shadcn-ui/input';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { useState } from 'react';\n\n/** Props for the SearchBar component. */\nexport type SearchBarProps = {\n className?: string;\n /**\n * Callback fired to handle the search query when button pressed\n *\n * @param searchQuery\n */\n onSearch: (searchQuery: string) => void;\n\n /** Optional string that appears in the search bar without a search string */\n placeholder?: string;\n\n /** Optional boolean to set the input base to full width */\n isFullWidth?: boolean;\n};\n\nexport default function SearchBar({\n className,\n onSearch,\n placeholder,\n isFullWidth,\n}: SearchBarProps) {\n const [searchQuery, setSearchQuery] = useState('');\n\n const handleInputChange = (searchString: string) => {\n setSearchQuery(searchString);\n onSearch(searchString);\n };\n\n return (\n handleInputChange(e.target.value)}\n />\n );\n}\n","// adapted from: https://github.com/shadcn-ui/ui/discussions/752\n\n'use client';\n\nimport { TabsContentProps, TabsListProps, TabsTriggerProps } from '@/components/shadcn-ui/tabs';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport * as TabsPrimitive from '@radix-ui/react-tabs';\nimport React from 'react';\n\nexport type VerticalTabsProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport type LeftTabsTriggerProps = TabsTriggerProps & {\n value: string;\n ref?: React.Ref;\n};\n\nexport const VerticalTabs = React.forwardRef<\n React.ElementRef,\n VerticalTabsProps\n>(({ className, ...props }, ref) => (\n \n));\n\nVerticalTabs.displayName = TabsPrimitive.List.displayName;\n\nexport const VerticalTabsList = React.forwardRef<\n React.ElementRef,\n TabsListProps\n>(({ className, ...props }, ref) => (\n \n));\nVerticalTabsList.displayName = TabsPrimitive.List.displayName;\n\nexport const VerticalTabsTrigger = React.forwardRef<\n React.ElementRef,\n LeftTabsTriggerProps\n>(({ className, ...props }, ref) => (\n \n));\n\nexport const VerticalTabsContent = React.forwardRef<\n React.ElementRef,\n TabsContentProps\n>(({ className, ...props }, ref) => (\n \n));\nVerticalTabsContent.displayName = TabsPrimitive.Content.displayName;\n","import SearchBar from '@/components/basics/search-bar.component';\nimport {\n VerticalTabs,\n VerticalTabsContent,\n VerticalTabsList,\n VerticalTabsTrigger,\n} from '@/components/basics/tabs-vertical';\nimport { ReactNode } from 'react';\n\nexport type TabKeyValueContent = {\n key: string;\n value: string;\n content: ReactNode;\n};\n\nexport type TabNavigationContentSearchProps = {\n /** List of values and keys for each tab this component should provide */\n tabList: TabKeyValueContent[];\n\n /** Handler to run when the value of the search bar changes */\n onSearch: (searchQuery: string) => void;\n\n /** Optional placeholder for the search bar */\n searchPlaceholder?: string;\n\n /** Optional title to include in the header */\n headerTitle?: string;\n\n /** Optional flag to make the search bar appear full width */\n isSearchBarFullWidth?: boolean;\n\n /** Text direction ltr or rtl */\n direction?: 'ltr' | 'rtl';\n};\n\nexport default function TabNavigationContentSearch({\n tabList,\n onSearch,\n searchPlaceholder,\n headerTitle,\n isSearchBarFullWidth = false,\n direction = 'ltr',\n}: TabNavigationContentSearchProps) {\n return (\n
    \n
    \n {headerTitle ?

    {headerTitle}

    : ''}\n \n
    \n \n \n {tabList.map((tab) => (\n \n {tab.value}\n \n ))}\n \n {tabList.map((tab) => (\n \n {tab.content}\n \n ))}\n \n
    \n );\n}\n","import React from 'react';\nimport * as SeparatorPrimitive from '@radix-ui/react-separator';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Separator = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, orientation = 'horizontal', decorative = true, ...props }, ref) => (\n \n));\nSeparator.displayName = SeparatorPrimitive.Root.displayName;\n\nexport { Separator };\n","import React from 'react';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nfunction Skeleton({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\n\nexport { Skeleton };\n","import React from 'react';\nimport * as TooltipPrimitive from '@radix-ui/react-tooltip';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst TooltipProvider = TooltipPrimitive.Provider;\n\nconst Tooltip = TooltipPrimitive.Root;\n\nconst TooltipTrigger = TooltipPrimitive.Trigger;\n\nconst TooltipContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, sideOffset = 4, ...props }, ref) => (\n \n));\nTooltipContent.displayName = TooltipPrimitive.Content.displayName;\n\nexport { Tooltip, TooltipTrigger, TooltipContent, TooltipProvider };\n","import React from 'react';\nimport { Slot } from '@radix-ui/react-slot';\nimport { VariantProps, cva } from 'class-variance-authority';\nimport { PanelLeft } from 'lucide-react';\n\nimport { Button } from '@/components/shadcn-ui/button';\nimport { Input } from '@/components/shadcn-ui/input';\nimport { Separator } from '@/components/shadcn-ui/separator';\nimport { Skeleton } from '@/components/shadcn-ui/skeleton';\nimport {\n Tooltip,\n TooltipContent,\n TooltipProvider,\n TooltipTrigger,\n} from '@/components/shadcn-ui/tooltip';\nimport { cn } from '@/utils/shadcn-ui.util';\n\n/**\n * Changes from the original code from Shadcn- Removed uses of useIsMobile, Sheet, and SheetContent.\n * Also removed the parts setting COOKIES.\n */\n\nconst SIDEBAR_WIDTH = '16rem';\nconst SIDEBAR_WIDTH_ICON = '3rem';\nconst SIDEBAR_KEYBOARD_SHORTCUT = 'b';\n\ntype SidebarContextProps = {\n state: 'expanded' | 'collapsed';\n open: boolean;\n setOpen: (open: boolean) => void;\n toggleSidebar: () => void;\n};\n\nconst SidebarContext = React.createContext(undefined);\n\nfunction useSidebar() {\n const context = React.useContext(SidebarContext);\n if (!context) {\n throw new Error('useSidebar must be used within a SidebarProvider.');\n }\n\n return context;\n}\n\nconst SidebarProvider = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & {\n defaultOpen?: boolean;\n open?: boolean;\n onOpenChange?: (open: boolean) => void;\n }\n>(\n (\n {\n defaultOpen = true,\n open: openProp,\n onOpenChange: setOpenProp,\n className,\n style,\n children,\n ...props\n },\n ref,\n ) => {\n // This is the internal state of the sidebar.\n // We use openProp and setOpenProp for control from outside the component.\n const [_open, _setOpen] = React.useState(defaultOpen);\n const isOpen = openProp ?? _open;\n const setOpen = React.useCallback(\n (value: boolean | ((value: boolean) => boolean)) => {\n const openState = typeof value === 'function' ? value(isOpen) : value;\n if (setOpenProp) {\n setOpenProp(openState);\n } else {\n _setOpen(openState);\n }\n },\n [setOpenProp, isOpen],\n );\n\n // Helper to toggle the sidebar.\n const toggleSidebar = React.useCallback(() => {\n return setOpen((open) => !open);\n }, [setOpen]);\n\n // Adds a keyboard shortcut to toggle the sidebar.\n React.useEffect(() => {\n const handleKeyDown = (event: KeyboardEvent) => {\n if (event.key === SIDEBAR_KEYBOARD_SHORTCUT && (event.metaKey || event.ctrlKey)) {\n event.preventDefault();\n toggleSidebar();\n }\n };\n\n window.addEventListener('keydown', handleKeyDown);\n return () => window.removeEventListener('keydown', handleKeyDown);\n }, [toggleSidebar]);\n\n // We add a state so that we can do data-state=\"expanded\" or \"collapsed\".\n // This makes it easier to style the sidebar with Tailwind classes.\n const state = isOpen ? 'expanded' : 'collapsed';\n\n const contextValue = React.useMemo(\n () => ({\n state,\n open: isOpen,\n setOpen,\n toggleSidebar,\n }),\n [state, isOpen, setOpen, toggleSidebar],\n );\n\n return (\n \n \n \n {children}\n
    \n \n \n );\n },\n);\nSidebarProvider.displayName = 'SidebarProvider';\n\nconst Sidebar = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & {\n side?: 'left' | 'right';\n variant?: 'sidebar' | 'floating' | 'inset';\n collapsible?: 'offcanvas' | 'icon' | 'none';\n }\n>(\n (\n {\n side = 'left',\n variant = 'sidebar',\n collapsible = 'offcanvas',\n className,\n children,\n ...props\n },\n ref,\n ) => {\n const { state } = useSidebar();\n\n if (collapsible === 'none') {\n return (\n \n {children}\n
    \n );\n }\n\n return (\n \n {/* This is what handles the sidebar gap on desktop */}\n \n \n \n {children}\n
    \n
    \n
    \n );\n },\n);\nSidebar.displayName = 'Sidebar';\n\nconst SidebarTrigger = React.forwardRef<\n React.ElementRef,\n React.ComponentProps\n>(({ className, onClick, ...props }, ref) => {\n const { toggleSidebar } = useSidebar();\n\n return (\n {\n onClick?.(event);\n toggleSidebar();\n }}\n {...props}\n >\n \n Toggle Sidebar\n \n );\n});\nSidebarTrigger.displayName = 'SidebarTrigger';\n\nconst SidebarRail = React.forwardRef>(\n ({ className, ...props }, ref) => {\n const { toggleSidebar } = useSidebar();\n\n return (\n \n );\n },\n);\nSidebarRail.displayName = 'SidebarRail';\n\nconst SidebarInset = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarInset.displayName = 'SidebarInset';\n\nconst SidebarInput = React.forwardRef<\n React.ElementRef,\n React.ComponentProps\n>(({ className, ...props }, ref) => {\n return (\n \n );\n});\nSidebarInput.displayName = 'SidebarInput';\n\nconst SidebarHeader = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarHeader.displayName = 'SidebarHeader';\n\nconst SidebarFooter = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarFooter.displayName = 'SidebarFooter';\n\nconst SidebarSeparator = React.forwardRef<\n React.ElementRef,\n React.ComponentProps\n>(({ className, ...props }, ref) => {\n return (\n \n );\n});\nSidebarSeparator.displayName = 'SidebarSeparator';\n\nconst SidebarContent = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarContent.displayName = 'SidebarContent';\n\nconst SidebarGroup = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarGroup.displayName = 'SidebarGroup';\n\nconst SidebarGroupLabel = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & { asChild?: boolean }\n>(({ className, asChild = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'div';\n\n return (\n svg]:tw-size-4 [&>svg]:tw-shrink-0',\n 'group-data-[collapsible=icon]:tw--mt-8 group-data-[collapsible=icon]:tw-opacity-0',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarGroupLabel.displayName = 'SidebarGroupLabel';\n\nconst SidebarGroupAction = React.forwardRef<\n HTMLButtonElement,\n React.ComponentProps<'button'> & { asChild?: boolean }\n>(({ className, asChild = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'button';\n\n return (\n svg]:tw-size-4 [&>svg]:tw-shrink-0',\n // Increases the hit area of the button on mobile.\n 'after:tw-absolute after:tw--inset-2 after:md:tw-hidden',\n 'group-data-[collapsible=icon]:tw-hidden',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarGroupAction.displayName = 'SidebarGroupAction';\n\nconst SidebarGroupContent = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarGroupContent.displayName = 'SidebarGroupContent';\n\nconst SidebarMenu = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenu.displayName = 'SidebarMenu';\n\nconst SidebarMenuItem = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenuItem.displayName = 'SidebarMenuItem';\n\nconst sidebarMenuButtonVariants = cva(\n // Removed data-[active=true]:tw-bg-sidebar-accent\n 'tw-peer/menu-button tw-flex tw-w-full tw-items-center tw-gap-2 tw-overflow-hidden tw-rounded-md tw-p-2 tw-text-left tw-text-sm tw-outline-none tw-ring-sidebar-ring tw-transition-[width,height,padding] hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground focus-visible:tw-ring-2 active:tw-bg-sidebar-accent active:tw-text-sidebar-accent-foreground disabled:tw-pointer-events-none disabled:tw-opacity-50 tw-group-has-[[data-sidebar=menu-action]]/menu-item:pr-8 aria-disabled:tw-pointer-events-none aria-disabled:tw-opacity-50 data-[active=true]:tw-font-medium data-[active=true]:tw-text-sidebar-accent-foreground data-[state=open]:hover:tw-bg-sidebar-accent data-[state=open]:hover:tw-text-sidebar-accent-foreground group-data-[collapsible=icon]:tw-!size-8 group-data-[collapsible=icon]:tw-!p-2 [&>span:last-child]:tw-truncate [&>svg]:tw-size-4 [&>svg]:tw-shrink-0',\n {\n variants: {\n variant: {\n default: 'hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground',\n outline:\n 'tw-bg-background tw-shadow-[0_0_0_1px_hsl(var(--sidebar-border))] hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground hover:tw-shadow-[0_0_0_1px_hsl(var(--sidebar-accent))]',\n },\n size: {\n default: 'tw-h-8 tw-text-sm',\n sm: 'tw-h-7 tw-text-xs',\n lg: 'tw-h-12 tw-text-sm group-data-[collapsible=icon]:tw-!p-0',\n },\n },\n defaultVariants: {\n variant: 'default',\n size: 'default',\n },\n },\n);\n\nconst SidebarMenuButton = React.forwardRef<\n HTMLButtonElement,\n React.ComponentProps<'button'> & {\n asChild?: boolean;\n isActive?: boolean;\n tooltip?: string | React.ComponentProps;\n } & VariantProps\n>(\n (\n {\n asChild = false,\n isActive = false,\n variant = 'default',\n size = 'default',\n tooltip,\n className,\n ...props\n },\n ref,\n ) => {\n const Comp = asChild ? Slot : 'button';\n const { state } = useSidebar();\n\n const button = (\n \n );\n\n if (!tooltip) {\n return button;\n }\n\n if (typeof tooltip === 'string') {\n // eslint-disable-next-line no-param-reassign\n tooltip = {\n children: tooltip,\n };\n }\n\n return (\n \n {button}\n \n );\n },\n);\nSidebarMenuButton.displayName = 'SidebarMenuButton';\n\nconst SidebarMenuAction = React.forwardRef<\n HTMLButtonElement,\n React.ComponentProps<'button'> & {\n asChild?: boolean;\n showOnHover?: boolean;\n }\n>(({ className, asChild = false, showOnHover = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'button';\n\n return (\n svg]:tw-size-4 [&>svg]:tw-shrink-0',\n // Increases the hit area of the button on mobile.\n 'after:tw-absolute after:tw--inset-2 after:md:tw-hidden',\n 'tw-peer-data-[size=sm]/menu-button:top-1',\n 'tw-peer-data-[size=default]/menu-button:top-1.5',\n 'tw-peer-data-[size=lg]/menu-button:top-2.5',\n 'group-data-[collapsible=icon]:tw-hidden',\n showOnHover &&\n 'tw-group-focus-within/menu-item:opacity-100 tw-group-hover/menu-item:opacity-100 tw-peer-data-[active=true]/menu-button:text-sidebar-accent-foreground data-[state=open]:tw-opacity-100 md:tw-opacity-0',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarMenuAction.displayName = 'SidebarMenuAction';\n\nconst SidebarMenuBadge = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenuBadge.displayName = 'SidebarMenuBadge';\n\nconst SidebarMenuSkeleton = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & {\n showIcon?: boolean;\n }\n>(({ className, showIcon = false, ...props }, ref) => {\n // Random width between 50 to 90%.\n const width = React.useMemo(() => {\n return `${Math.floor(Math.random() * 40) + 50}%`;\n }, []);\n\n return (\n \n {showIcon && (\n \n )}\n \n
    \n );\n});\nSidebarMenuSkeleton.displayName = 'SidebarMenuSkeleton';\n\nconst SidebarMenuSub = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenuSub.displayName = 'SidebarMenuSub';\n\nconst SidebarMenuSubItem = React.forwardRef>(\n ({ ...props }, ref) =>
  • ,\n);\nSidebarMenuSubItem.displayName = 'SidebarMenuSubItem';\n\nconst SidebarMenuSubButton = React.forwardRef<\n HTMLAnchorElement,\n React.ComponentProps<'a'> & {\n asChild?: boolean;\n size?: 'sm' | 'md';\n isActive?: boolean;\n }\n>(({ asChild = false, size = 'md', isActive, className, ...props }, ref) => {\n const Comp = asChild ? Slot : 'a';\n\n return (\n span:last-child]:tw-truncate [&>svg]:tw-size-4 [&>svg]:tw-shrink-0 [&>svg]:tw-text-sidebar-accent-foreground',\n 'data-[active=true]:tw-bg-sidebar-accent data-[active=true]:tw-text-sidebar-accent-foreground',\n size === 'sm' && 'tw-text-xs',\n size === 'md' && 'tw-text-sm',\n 'group-data-[collapsible=icon]:tw-hidden',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarMenuSubButton.displayName = 'SidebarMenuSubButton';\n\nexport {\n Sidebar,\n SidebarContent,\n SidebarFooter,\n SidebarGroup,\n SidebarGroupAction,\n SidebarGroupContent,\n SidebarGroupLabel,\n SidebarHeader,\n SidebarInput,\n SidebarInset,\n SidebarMenu,\n SidebarMenuAction,\n SidebarMenuBadge,\n SidebarMenuButton,\n SidebarMenuItem,\n SidebarMenuSkeleton,\n SidebarMenuSub,\n SidebarMenuSubButton,\n SidebarMenuSubItem,\n SidebarProvider,\n SidebarRail,\n SidebarSeparator,\n SidebarTrigger,\n useSidebar,\n};\n","import ComboBox, { ComboBoxOption } from '@/components/basics/combo-box.component';\nimport {\n Sidebar,\n SidebarContent,\n SidebarGroup,\n SidebarGroupLabel,\n SidebarGroupContent,\n SidebarMenu,\n SidebarMenuItem,\n SidebarMenuButton,\n} from '@/components/shadcn-ui/sidebar';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { useCallback } from 'react';\n\nexport type SelectedSettingsSidebarItem = {\n label: string;\n projectId?: string;\n};\n\nexport type ProjectInfo = { projectId: string; projectName: string };\n\nexport type SettingsSidebarProps = {\n /** Optional id for testing */\n id?: string;\n\n /** Extension labels from contribution */\n extensionLabels: string[];\n\n /** Project names and ids */\n projectOptions: ProjectInfo[];\n\n /** Handler for selecting a sidebar item */\n handleSelectSidebarItem: (key: string, projectId?: string) => void;\n\n /** The current selected value in the sidebar */\n selectedSidebarItem: SelectedSettingsSidebarItem;\n\n /** Label for the group of extensions setting groups */\n extensionsSidebarGroupLabel: string;\n\n /** Label for the group of projects settings */\n projectsSidebarGroupLabel: string;\n\n /** Placeholder text for the button */\n buttonPlaceholderText: string;\n};\n\nexport default function SettingsSidebar({\n id,\n extensionLabels,\n projectOptions,\n handleSelectSidebarItem,\n selectedSidebarItem,\n extensionsSidebarGroupLabel,\n projectsSidebarGroupLabel,\n buttonPlaceholderText,\n}: SettingsSidebarProps) {\n const handleSelectItem = useCallback(\n (item: string, projectId?: string) => {\n handleSelectSidebarItem(item, projectId);\n },\n [handleSelectSidebarItem],\n );\n\n const getProjectNameFromProjectId = useCallback(\n (projectId: string) => {\n const project = projectOptions.find((option) => option.projectId === projectId);\n return project ? project.projectName : projectId;\n },\n [projectOptions],\n );\n\n const getIsActive: (label: string) => boolean = useCallback(\n (label: string) => !selectedSidebarItem.projectId && label === selectedSidebarItem.label,\n [selectedSidebarItem],\n );\n\n return (\n \n \n \n \n {extensionsSidebarGroupLabel}\n \n \n \n {extensionLabels.map((label) => (\n \n handleSelectItem(label)}\n isActive={getIsActive(label)}\n >\n {label}\n \n \n ))}\n \n \n \n \n \n {projectsSidebarGroupLabel}\n \n \n option.projectId)}\n getOptionLabel={(projectId: ComboBoxOption) => {\n // This function expects a ComboBoxOption, but we know it is a string\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n return getProjectNameFromProjectId(projectId as string);\n }}\n buttonPlaceholder={buttonPlaceholderText}\n onChange={(projectId: string) => {\n const selectedProjectName = getProjectNameFromProjectId(projectId);\n handleSelectItem(selectedProjectName, projectId);\n }}\n value={selectedSidebarItem?.projectId ?? undefined}\n />\n \n \n \n \n );\n}\n","import { SidebarInset, SidebarProvider } from '@/components/shadcn-ui/sidebar';\nimport { PropsWithChildren } from 'react';\nimport SearchBar from '@/components/basics/search-bar.component';\nimport SettingsSidebar, { SettingsSidebarProps } from './settings-sidebar.component';\n\nexport type SettingsSidebarContentSearchProps = SettingsSidebarProps &\n PropsWithChildren & {\n /** Optional id for testing */\n id?: string;\n\n /** Handler to run when the value of the search bar changes */\n onSearch: (searchQuery: string) => void;\n };\n\nexport default function SettingsSidebarContentSearch({\n id,\n extensionLabels,\n projectOptions,\n children,\n handleSelectSidebarItem,\n selectedSidebarItem,\n onSearch,\n extensionsSidebarGroupLabel,\n projectsSidebarGroupLabel,\n buttonPlaceholderText,\n}: SettingsSidebarContentSearchProps) {\n return (\n
    \n
    \n \n
    \n \n \n {children}\n \n
    \n );\n}\n","import { Button } from '@/components/shadcn-ui/button';\nimport {\n Select,\n SelectContent,\n SelectGroup,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\nimport {\n Table,\n TableBody,\n TableCell,\n TableHead,\n TableHeader,\n TableRow,\n} from '@/components/shadcn-ui/table';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Canon } from '@sillsdev/scripture';\nimport {\n Cell,\n ColumnDef,\n flexRender,\n getCoreRowModel,\n getExpandedRowModel,\n getGroupedRowModel,\n getSortedRowModel,\n GroupingState,\n Row,\n RowSelectionState,\n SortingState,\n useReactTable,\n} from '@tanstack/react-table';\nimport '@/components/advanced/scripture-results-viewer/scripture-results-viewer.component.css';\nimport {\n compareScrRefs,\n formatScrRef,\n ScriptureSelection,\n scrRefToBBBCCCVVV,\n} from 'platform-bible-utils';\nimport { MouseEvent, useEffect, useMemo, useState } from 'react';\nimport { ChevronDown, ChevronLeft, ChevronRight } from 'lucide-react';\n\n/**\n * Information (e.g., a checking error or some other type of \"transient\" annotation) about something\n * noteworthy at a specific place in an instance of the Scriptures.\n */\nexport type ScriptureItemDetail = ScriptureSelection & {\n /**\n * Text of the error, note, etc. In the future, we might want to support something more than just\n * text so that a JSX element could be provided with a link or some other controls related to the\n * issue being reported.\n */\n detail: string;\n};\n\n/**\n * A uniquely identifiable source of results that can be displayed in the ScriptureResultsViewer.\n * Generally, the source will be a particular Scripture check, but there may be other types of\n * sources.\n */\nexport type ResultsSource = {\n /**\n * Uniquely identifies the source.\n *\n * @type {string}\n */\n id: string;\n\n /**\n * Name (potentially localized) of the source, suitable for display in the UI.\n *\n * @type {string}\n */\n displayName: string;\n};\n\nexport type ScriptureSrcItemDetail = ScriptureItemDetail & {\n /** Source/type of detail. Can be used for grouping. */\n source: ResultsSource;\n};\n\n/**\n * Represents a set of results keyed by Scripture reference. Generally, the source will be a\n * particular Scripture check, but this type also allows for other types of uniquely identifiable\n * sources.\n */\nexport type ResultsSet = {\n /**\n * The backing source associated with this set of results.\n *\n * @type {ResultsSource}\n */\n source: ResultsSource;\n\n /**\n * Array of Scripture item details (messages keyed by Scripture reference).\n *\n * @type {ScriptureItemDetail[]}\n */\n data: ScriptureItemDetail[];\n};\n\nconst scrBookColId = 'scrBook';\nconst scrRefColId = 'scrRef';\nconst typeColId = 'source';\nconst detailsColId = 'details';\n\nconst defaultScrRefColumnName = 'Scripture Reference';\nconst defaultScrBookGroupName = 'Scripture Book';\nconst defaultTypeColumnName = 'Type';\nconst defaultDetailsColumnName = 'Details';\n\nexport type ScriptureResultsViewerColumnInfo = {\n /** Optional header to display for the Reference column. Default value: 'Scripture Reference'. */\n scriptureReferenceColumnName?: string;\n\n /** Optional text to display to refer to the Scripture book group. Default value: 'Scripture Book'. */\n scriptureBookGroupName?: string;\n\n /** Optional header to display for the Type column. Default value: 'Type'. */\n typeColumnName?: string;\n\n /** Optional header to display for the Details column. Default value: 'Details' */\n detailsColumnName?: string;\n};\n\nexport type ScriptureResultsViewerProps = ScriptureResultsViewerColumnInfo & {\n /** Groups of ScriptureItemDetail objects from particular sources (e.g., Scripture checks) */\n sources: ResultsSet[];\n\n /** Flag indicating whether to display column headers. Default is false. */\n showColumnHeaders?: boolean;\n\n /** Flag indicating whether to display source column. Default is false. */\n showSourceColumn?: boolean;\n\n /** Callback function to notify when a row is selected */\n onRowSelected?: (selectedRow: ScriptureSrcItemDetail | undefined) => void;\n\n /** Text direction ltr or rtl */\n direction?: 'ltr' | 'rtl';\n};\n\nfunction getColumns(\n colInfo?: ScriptureResultsViewerColumnInfo,\n showSourceColumn?: boolean,\n): ColumnDef[] {\n const showSrcCol = showSourceColumn ?? false;\n return [\n {\n accessorFn: (row) =>\n `${Canon.bookNumberToId(row.start.bookNum)} ${row.start.chapterNum}:${row.start.verseNum}`,\n id: scrBookColId,\n header: colInfo?.scriptureReferenceColumnName ?? defaultScrRefColumnName,\n cell: (info) => {\n const row = info.row.original;\n if (info.row.getIsGrouped()) {\n return Canon.bookNumberToEnglishName(row.start.bookNum);\n }\n return info.row.groupingColumnId === scrBookColId ? formatScrRef(row.start) : undefined;\n },\n getGroupingValue: (row) => row.start.bookNum,\n sortingFn: (a, b) => {\n return compareScrRefs(a.original.start, b.original.start);\n },\n enableGrouping: true,\n },\n {\n accessorFn: (row) => formatScrRef(row.start),\n id: scrRefColId,\n header: undefined,\n cell: (info) => {\n const row = info.row.original;\n return info.row.getIsGrouped() ? undefined : formatScrRef(row.start);\n },\n sortingFn: (a, b) => {\n return compareScrRefs(a.original.start, b.original.start);\n },\n enableGrouping: false,\n },\n {\n accessorFn: (row) => row.source.displayName,\n id: typeColId,\n header: showSrcCol ? (colInfo?.typeColumnName ?? defaultTypeColumnName) : undefined,\n cell: (info) => (showSrcCol || info.row.getIsGrouped() ? info.getValue() : undefined),\n getGroupingValue: (row) => row.source.id,\n sortingFn: (a, b) =>\n a.original.source.displayName.localeCompare(b.original.source.displayName),\n enableGrouping: true,\n },\n {\n accessorFn: (row) => row.detail,\n id: detailsColId,\n header: colInfo?.detailsColumnName ?? defaultDetailsColumnName,\n cell: (info) => info.getValue(),\n enableGrouping: false,\n },\n ];\n}\n\nconst toRefOrRange = (scriptureSelection: ScriptureSelection) => {\n if (!('offset' in scriptureSelection.start))\n throw new Error('No offset available in range start');\n if (scriptureSelection.end && !('offset' in scriptureSelection.end))\n throw new Error('No offset available in range end');\n const { offset: offsetStart } = scriptureSelection.start;\n let offsetEnd: number = 0;\n if (scriptureSelection.end) ({ offset: offsetEnd } = scriptureSelection.end);\n if (\n !scriptureSelection.end ||\n compareScrRefs(scriptureSelection.start, scriptureSelection.end) === 0\n )\n return `${scrRefToBBBCCCVVV(scriptureSelection.start)}+${offsetStart}`;\n return `${scrRefToBBBCCCVVV(scriptureSelection.start)}+${offsetStart}-${scrRefToBBBCCCVVV(scriptureSelection.end)}+${offsetEnd}`;\n};\n\nconst getRowKey = (row: ScriptureSrcItemDetail) =>\n `${toRefOrRange({ start: row.start, end: row.end })} ${row.source.displayName} ${row.detail}`;\n\n/**\n * Component to display a combined list of detailed items from one or more sources, where the items\n * are keyed primarily by Scripture reference. This is particularly useful for displaying a list of\n * results from Scripture checks, but more generally could be used to display any \"results\" from any\n * source(s). The component allows for grouping by Scripture book, source, or both. By default, it\n * displays somewhat \"tree-like\" which allows it to be more horizontally compact and intuitive. But\n * it also has the option of displaying as a traditional table with column headings (with or without\n * the source column showing).\n */\nexport default function ScriptureResultsViewer({\n sources,\n showColumnHeaders = false,\n showSourceColumn = false,\n scriptureReferenceColumnName,\n scriptureBookGroupName,\n typeColumnName,\n detailsColumnName,\n onRowSelected,\n direction = 'ltr',\n}: ScriptureResultsViewerProps) {\n const [grouping, setGrouping] = useState([]);\n const [sorting, setSorting] = useState([{ id: scrBookColId, desc: false }]);\n const [rowSelection, setRowSelection] = useState({});\n\n const scriptureResults = useMemo(\n () =>\n sources.flatMap((source) => {\n return source.data.map((item) => ({\n ...item,\n source: source.source,\n }));\n }),\n [sources],\n );\n\n const columns = useMemo(\n () =>\n getColumns(\n {\n scriptureReferenceColumnName,\n typeColumnName,\n detailsColumnName,\n },\n showSourceColumn,\n ),\n [scriptureReferenceColumnName, typeColumnName, detailsColumnName, showSourceColumn],\n );\n\n useEffect(() => {\n // Ensure sorting is applied correctly when grouped by type\n if (grouping.includes(typeColId)) {\n setSorting([\n { id: typeColId, desc: false },\n { id: scrBookColId, desc: false },\n ]);\n } else {\n setSorting([{ id: scrBookColId, desc: false }]);\n }\n }, [grouping]);\n\n const table = useReactTable({\n data: scriptureResults,\n columns,\n state: {\n grouping,\n sorting,\n rowSelection,\n },\n onGroupingChange: setGrouping,\n onSortingChange: setSorting,\n onRowSelectionChange: setRowSelection,\n getExpandedRowModel: getExpandedRowModel(),\n getGroupedRowModel: getGroupedRowModel(),\n getCoreRowModel: getCoreRowModel(),\n getSortedRowModel: getSortedRowModel(),\n getRowId: getRowKey,\n autoResetExpanded: false,\n enableMultiRowSelection: false,\n enableSubRowSelection: false,\n });\n\n useEffect(() => {\n if (onRowSelected) {\n const selectedRows = table.getSelectedRowModel().rowsById;\n const keys = Object.keys(selectedRows);\n if (keys.length === 1) {\n const selectedRow = scriptureResults.find((row) => getRowKey(row) === keys[0]) || undefined;\n if (selectedRow) onRowSelected(selectedRow);\n }\n }\n }, [rowSelection, scriptureResults, onRowSelected, table]);\n\n // Define possible grouping options\n const scrBookGroupName = scriptureBookGroupName ?? defaultScrBookGroupName;\n const typeGroupName = typeColumnName ?? defaultTypeColumnName;\n\n const groupingOptions = [\n { label: 'No Grouping', value: [] },\n { label: `Group by ${scrBookGroupName}`, value: [scrBookColId] },\n { label: `Group by ${typeGroupName}`, value: [typeColId] },\n {\n label: `Group by ${scrBookGroupName} and ${typeGroupName}`,\n value: [scrBookColId, typeColId],\n },\n {\n label: `Group by ${typeGroupName} and ${scrBookGroupName}`,\n value: [typeColId, scrBookColId],\n },\n ];\n\n const handleSelectChange = (selectedGrouping: string) => {\n setGrouping(JSON.parse(selectedGrouping));\n };\n\n const handleRowClick = (row: Row, event: MouseEvent) => {\n if (!row.getIsGrouped() && !row.getIsSelected()) {\n row.getToggleSelectedHandler()(event);\n }\n };\n\n const getEvenOrOddBandingStyle = (row: Row, index: number) => {\n if (row.getIsGrouped()) return '';\n // UX has now said they don't think they want banding. I'm leaving in the code to\n // set even and odd styles, but there's nothing in the CSS to style them differently.\n // The \"even\" style used to also have tw-bg-neutral-300 (along with even) to create\n // a visual banding effect. That could be added back in if UX changes the decision.\n return cn('banded-row', index % 2 === 0 ? 'even' : 'odd');\n };\n\n const getIndent = (\n groupingState: GroupingState,\n row: Row,\n cell: Cell,\n ) => {\n if (groupingState?.length === 0 || row.depth < cell.column.getGroupedIndex()) return undefined;\n if (row.getIsGrouped()) {\n switch (row.depth) {\n case 1:\n return 'tw-ps-4';\n default:\n return undefined;\n }\n }\n switch (row.depth) {\n case 1:\n return 'tw-ps-8';\n case 2:\n return 'tw-ps-12';\n default:\n return undefined;\n }\n };\n\n return (\n
    \n {!showColumnHeaders && (\n {\n handleSelectChange(value);\n }}\n >\n \n \n \n \n \n {groupingOptions.map((option) => (\n \n {option.label}\n \n ))}\n \n \n \n )}\n \n {showColumnHeaders && (\n \n {table.getHeaderGroups().map((headerGroup) => (\n \n {headerGroup.headers\n .filter((h) => h.column.columnDef.header)\n .map((header) => (\n /* For sticky column headers to work, we probably need to change the default definition of the shadcn Table component. See https://github.com/shadcn-ui/ui/issues/1151 */\n \n {header.isPlaceholder ? undefined : (\n
    \n {header.column.getCanGroup() ? (\n \n {header.column.getIsGrouped() ? `🛑` : `👊 `}\n \n ) : undefined}{' '}\n {flexRender(header.column.columnDef.header, header.getContext())}\n
    \n )}\n
    \n ))}\n
    \n ))}\n
    \n )}\n \n {table.getRowModel().rows.map((row, rowIndex) => {\n return (\n handleRowClick(row, event)}\n >\n {row.getVisibleCells().map((cell) => {\n if (\n cell.getIsPlaceholder() ||\n (cell.column.columnDef.enableGrouping &&\n !cell.getIsGrouped() &&\n (cell.column.columnDef.id !== typeColId || !showSourceColumn))\n )\n return undefined;\n return (\n \n {(() => {\n if (cell.getIsGrouped()) {\n return (\n \n {row.getIsExpanded() && }\n {!row.getIsExpanded() &&\n (direction === 'ltr' ? : )}{' '}\n {flexRender(cell.column.columnDef.cell, cell.getContext())} (\n {row.subRows.length})\n \n );\n }\n\n // if (cell.getIsAggregated()) {\n // flexRender(\n // cell.column.columnDef.aggregatedCell ?? cell.column.columnDef.cell,\n // cell.getContext(),\n // );\n // }\n\n return flexRender(cell.column.columnDef.cell, cell.getContext());\n })()}\n \n );\n })}\n \n );\n })}\n \n
    \n
    \n );\n}\n","import {\n getLocalizeKeyForScrollGroupId,\n LanguageStrings,\n ScrollGroupId,\n} from 'platform-bible-utils';\nimport {\n Select,\n SelectContent,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\n\nconst DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS = {\n [getLocalizeKeyForScrollGroupId('undefined')]: 'Ø',\n [getLocalizeKeyForScrollGroupId(0)]: 'A',\n [getLocalizeKeyForScrollGroupId(1)]: 'B',\n [getLocalizeKeyForScrollGroupId(2)]: 'C',\n [getLocalizeKeyForScrollGroupId(3)]: 'D',\n [getLocalizeKeyForScrollGroupId(4)]: 'E',\n [getLocalizeKeyForScrollGroupId(5)]: 'F',\n [getLocalizeKeyForScrollGroupId(6)]: 'G',\n [getLocalizeKeyForScrollGroupId(7)]: 'H',\n [getLocalizeKeyForScrollGroupId(8)]: 'I',\n [getLocalizeKeyForScrollGroupId(9)]: 'J',\n [getLocalizeKeyForScrollGroupId(10)]: 'K',\n [getLocalizeKeyForScrollGroupId(11)]: 'L',\n [getLocalizeKeyForScrollGroupId(12)]: 'M',\n [getLocalizeKeyForScrollGroupId(13)]: 'N',\n [getLocalizeKeyForScrollGroupId(14)]: 'O',\n [getLocalizeKeyForScrollGroupId(15)]: 'P',\n [getLocalizeKeyForScrollGroupId(16)]: 'Q',\n [getLocalizeKeyForScrollGroupId(17)]: 'R',\n [getLocalizeKeyForScrollGroupId(18)]: 'S',\n [getLocalizeKeyForScrollGroupId(19)]: 'T',\n [getLocalizeKeyForScrollGroupId(20)]: 'U',\n [getLocalizeKeyForScrollGroupId(21)]: 'V',\n [getLocalizeKeyForScrollGroupId(22)]: 'W',\n [getLocalizeKeyForScrollGroupId(23)]: 'X',\n [getLocalizeKeyForScrollGroupId(24)]: 'Y',\n [getLocalizeKeyForScrollGroupId(25)]: 'Z',\n};\n\nexport type ScrollGroupSelectorProps = {\n /**\n * List of scroll group ids to show to the user. Either a {@link ScrollGroupId} or `undefined` for\n * no scroll group\n */\n availableScrollGroupIds: (ScrollGroupId | undefined)[];\n /** Currently selected scroll group id. `undefined` for no scroll group */\n scrollGroupId: ScrollGroupId | undefined;\n /** Callback function run when the user tries to change the scroll group id */\n onChangeScrollGroupId: (newScrollGroupId: ScrollGroupId | undefined) => void;\n /**\n * Localized strings to use for displaying scroll group ids. Must be an object whose keys are\n * `getLocalizeKeyForScrollGroupId(scrollGroupId)` for all scroll group ids (and `undefined` if\n * included) in {@link ScrollGroupSelectorProps.availableScrollGroupIds} and whose values are the\n * localized strings to use for those scroll group ids.\n *\n * Defaults to English localizations of English alphabet for scroll groups 0-25 (e.g. 0 is A) and\n * Ø for `undefined`. Will fill in any that are not provided with these English localizations.\n * Also, if any values match the keys, the English localization will be used. This is useful in\n * case you want to pass in a temporary version of the localized strings while your localized\n * strings load.\n *\n * @example\n *\n * ```typescript\n * const myScrollGroupIdLocalizedStrings = {\n * [getLocalizeKeyForScrollGroupId('undefined')]: 'Ø',\n * [getLocalizeKeyForScrollGroupId(0)]: 'A',\n * [getLocalizeKeyForScrollGroupId(1)]: 'B',\n * [getLocalizeKeyForScrollGroupId(2)]: 'C',\n * [getLocalizeKeyForScrollGroupId(3)]: 'D',\n * [getLocalizeKeyForScrollGroupId(4)]: 'E',\n * };\n * ```\n *\n * @example\n *\n * ```tsx\n * const availableScrollGroupIds = [undefined, 0, 1, 2, 3, 4];\n *\n * const localizeKeys = getLocalizeKeysForScrollGroupIds();\n *\n * const [localizedStrings] = useLocalizedStrings(localizeKeys);\n *\n * ...\n *\n * \n * ```\n */\n localizedStrings?: LanguageStrings;\n};\n\n/** Selector component for choosing a scroll group */\nexport default function ScrollGroupSelector({\n availableScrollGroupIds,\n scrollGroupId,\n onChangeScrollGroupId,\n localizedStrings = {},\n}: ScrollGroupSelectorProps) {\n const localizedStringsDefaulted = {\n ...DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS,\n ...Object.fromEntries(\n Object.entries(localizedStrings).map(\n ([localizedStringKey, localizedStringValue]: [string, string]) => [\n localizedStringKey,\n localizedStringKey === localizedStringValue &&\n localizedStringKey in DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS\n ? DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS[localizedStringKey]\n : localizedStringValue,\n ],\n ),\n ),\n };\n return (\n \n onChangeScrollGroupId(\n newScrollGroupString === 'undefined' ? undefined : parseInt(newScrollGroupString, 10),\n )\n }\n >\n \n \n \n \n {availableScrollGroupIds.map((scrollGroupOptionId) => (\n \n {localizedStringsDefaulted[getLocalizeKeyForScrollGroupId(scrollGroupOptionId)]}\n \n ))}\n \n \n );\n}\n","import { PropsWithChildren } from 'react';\nimport { Separator } from '@/components/shadcn-ui/separator';\n\n/** Props for the SettingsList component, currently just children */\ntype SettingsListProps = PropsWithChildren;\n\n/**\n * SettingsList component is a wrapper for list items. Rendered with a formatted div\n *\n * @param children To populate the list with\n * @returns Formatted div encompassing the children\n */\nexport function SettingsList({ children }: SettingsListProps) {\n return
    {children}
    ;\n}\n\n/** Props for SettingsListItem component */\ntype SettingsListItemProps = PropsWithChildren & {\n /** Primary text of the list item */\n primary: string;\n\n /** Optional text of the list item */\n secondary?: string | undefined;\n\n /** Optional boolean to display a message if the children aren't loaded yet. Defaults to false */\n isLoading?: boolean;\n\n /** Optional message to display if isLoading */\n loadingMessage?: string;\n};\n\n/**\n * SettingsListItem component is a common list item. Rendered with a formatted div\n *\n * @param primary Primary text of the list item\n * @param secondary Optional secondary text of the list item\n * @param isLoading Optional, to display a message if the action component isn't generated yet,\n * defaults to false\n * @param children The action component(s) to provide for this item\n * @param loadingMessage Optional, message to display if isLoading\n * @returns Formatted div encompassing the list item content\n */\nexport function SettingsListItem({\n primary,\n secondary,\n children,\n isLoading = false,\n loadingMessage,\n}: SettingsListItemProps) {\n return (\n
    \n
    \n

    {primary}

    \n

    \n {secondary}\n

    \n
    \n\n {isLoading ? (\n

    {loadingMessage}

    \n ) : (\n
    {children}
    \n )}\n
    \n );\n}\n\n/** Props for SettingsListHeader component */\ntype SettingsListHeaderProps = {\n /** The primary text of the list header */\n primary: string;\n\n /** Optional secondary text of the list header */\n secondary?: string | undefined;\n\n /** Optional boolean to include a separator underneath the secondary text. Defaults to false */\n includeSeparator?: boolean;\n};\n\n/**\n * SettingsListHeader component displays text above the list\n *\n * @param primary The primary text of the list header\n * @param secondary Optional secondary text of the list header\n * @param includeSeparator Optional boolean to include a separator underneath the secondary text.\n * Defaults to false\n * @returns Formatted div with list header content\n */\nexport function SettingsListHeader({\n primary,\n secondary,\n includeSeparator = false,\n}: SettingsListHeaderProps) {\n return (\n
    \n
    \n

    {primary}

    \n

    {secondary}

    \n
    \n {includeSeparator ? : ''}\n
    \n );\n}\n","import Checkbox from '@/components/shadcn-ui/checkbox';\nimport { Label } from '@/components/shadcn-ui/label';\n\nexport type ChecklistProps = {\n /** Optional string representing the id attribute of the Checklist */\n id?: string;\n /** Optional string representing CSS class name(s) for styling */\n className?: string;\n /** Array of strings representing the checkable items */\n listItems: string[];\n /** Array of strings representing the checked items */\n selectedListItems: string[];\n /**\n * Function that is called when a checkbox item is selected or deselected\n *\n * @param item The string description for this item\n * @param selected True if selected, false if not selected\n */\n handleSelectListItem: (item: string, selected: boolean) => void;\n\n /**\n * Optional function creates a label for a provided checkable item\n *\n * @param item The item for which a label is to be created\n * @returns A string representing the label text for the checkbox associated with that item\n */\n createLabel?: (item: string) => string;\n};\n\n/** Renders a list of checkboxes. Each checkbox corresponds to an item from the `listItems` array. */\nexport default function Checklist({\n id,\n className,\n listItems,\n selectedListItems,\n handleSelectListItem,\n createLabel,\n}: ChecklistProps) {\n return (\n
    \n {listItems.map((item) => (\n
    \n handleSelectListItem(item, value)}\n />\n \n
    \n ))}\n
    \n );\n}\n","function _interopRequireDefault(obj) {\n return obj && obj.__esModule ? obj : {\n \"default\": obj\n };\n}\nmodule.exports = _interopRequireDefault, module.exports.__esModule = true, module.exports[\"default\"] = module.exports;","export default function chainPropTypes(propType1, propType2) {\n if (process.env.NODE_ENV === 'production') {\n return () => null;\n }\n return function validate(...args) {\n return propType1(...args) || propType2(...args);\n };\n}","export default function _extends() {\n _extends = Object.assign ? Object.assign.bind() : function (target) {\n for (var i = 1; i < arguments.length; i++) {\n var source = arguments[i];\n for (var key in source) {\n if (Object.prototype.hasOwnProperty.call(source, key)) {\n target[key] = source[key];\n }\n }\n }\n return target;\n };\n return _extends.apply(this, arguments);\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\n// https://github.com/sindresorhus/is-plain-obj/blob/main/index.js\nexport function isPlainObject(item) {\n if (typeof item !== 'object' || item === null) {\n return false;\n }\n const prototype = Object.getPrototypeOf(item);\n return (prototype === null || prototype === Object.prototype || Object.getPrototypeOf(prototype) === null) && !(Symbol.toStringTag in item) && !(Symbol.iterator in item);\n}\nfunction deepClone(source) {\n if (!isPlainObject(source)) {\n return source;\n }\n const output = {};\n Object.keys(source).forEach(key => {\n output[key] = deepClone(source[key]);\n });\n return output;\n}\nexport default function deepmerge(target, source, options = {\n clone: true\n}) {\n const output = options.clone ? _extends({}, target) : target;\n if (isPlainObject(target) && isPlainObject(source)) {\n Object.keys(source).forEach(key => {\n // Avoid prototype pollution\n if (key === '__proto__') {\n return;\n }\n if (isPlainObject(source[key]) && key in target && isPlainObject(target[key])) {\n // Since `output` is a clone of `target` and we have narrowed `target` in this block we can cast to the same type.\n output[key] = deepmerge(target[key], source[key], options);\n } else if (options.clone) {\n output[key] = isPlainObject(source[key]) ? deepClone(source[key]) : source[key];\n } else {\n output[key] = source[key];\n }\n });\n }\n return output;\n}","/** @license React v16.13.1\n * react-is.production.min.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';var b=\"function\"===typeof Symbol&&Symbol.for,c=b?Symbol.for(\"react.element\"):60103,d=b?Symbol.for(\"react.portal\"):60106,e=b?Symbol.for(\"react.fragment\"):60107,f=b?Symbol.for(\"react.strict_mode\"):60108,g=b?Symbol.for(\"react.profiler\"):60114,h=b?Symbol.for(\"react.provider\"):60109,k=b?Symbol.for(\"react.context\"):60110,l=b?Symbol.for(\"react.async_mode\"):60111,m=b?Symbol.for(\"react.concurrent_mode\"):60111,n=b?Symbol.for(\"react.forward_ref\"):60112,p=b?Symbol.for(\"react.suspense\"):60113,q=b?\nSymbol.for(\"react.suspense_list\"):60120,r=b?Symbol.for(\"react.memo\"):60115,t=b?Symbol.for(\"react.lazy\"):60116,v=b?Symbol.for(\"react.block\"):60121,w=b?Symbol.for(\"react.fundamental\"):60117,x=b?Symbol.for(\"react.responder\"):60118,y=b?Symbol.for(\"react.scope\"):60119;\nfunction z(a){if(\"object\"===typeof a&&null!==a){var u=a.$$typeof;switch(u){case c:switch(a=a.type,a){case l:case m:case e:case g:case f:case p:return a;default:switch(a=a&&a.$$typeof,a){case k:case n:case t:case r:case h:return a;default:return u}}case d:return u}}}function A(a){return z(a)===m}exports.AsyncMode=l;exports.ConcurrentMode=m;exports.ContextConsumer=k;exports.ContextProvider=h;exports.Element=c;exports.ForwardRef=n;exports.Fragment=e;exports.Lazy=t;exports.Memo=r;exports.Portal=d;\nexports.Profiler=g;exports.StrictMode=f;exports.Suspense=p;exports.isAsyncMode=function(a){return A(a)||z(a)===l};exports.isConcurrentMode=A;exports.isContextConsumer=function(a){return z(a)===k};exports.isContextProvider=function(a){return z(a)===h};exports.isElement=function(a){return\"object\"===typeof a&&null!==a&&a.$$typeof===c};exports.isForwardRef=function(a){return z(a)===n};exports.isFragment=function(a){return z(a)===e};exports.isLazy=function(a){return z(a)===t};\nexports.isMemo=function(a){return z(a)===r};exports.isPortal=function(a){return z(a)===d};exports.isProfiler=function(a){return z(a)===g};exports.isStrictMode=function(a){return z(a)===f};exports.isSuspense=function(a){return z(a)===p};\nexports.isValidElementType=function(a){return\"string\"===typeof a||\"function\"===typeof a||a===e||a===m||a===g||a===f||a===p||a===q||\"object\"===typeof a&&null!==a&&(a.$$typeof===t||a.$$typeof===r||a.$$typeof===h||a.$$typeof===k||a.$$typeof===n||a.$$typeof===w||a.$$typeof===x||a.$$typeof===y||a.$$typeof===v)};exports.typeOf=z;\n","/** @license React v16.13.1\n * react-is.development.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\n\n\nif (process.env.NODE_ENV !== \"production\") {\n (function() {\n'use strict';\n\n// The Symbol used to tag the ReactElement-like types. If there is no native Symbol\n// nor polyfill, then a plain number is used for performance.\nvar hasSymbol = typeof Symbol === 'function' && Symbol.for;\nvar REACT_ELEMENT_TYPE = hasSymbol ? Symbol.for('react.element') : 0xeac7;\nvar REACT_PORTAL_TYPE = hasSymbol ? Symbol.for('react.portal') : 0xeaca;\nvar REACT_FRAGMENT_TYPE = hasSymbol ? Symbol.for('react.fragment') : 0xeacb;\nvar REACT_STRICT_MODE_TYPE = hasSymbol ? Symbol.for('react.strict_mode') : 0xeacc;\nvar REACT_PROFILER_TYPE = hasSymbol ? Symbol.for('react.profiler') : 0xead2;\nvar REACT_PROVIDER_TYPE = hasSymbol ? Symbol.for('react.provider') : 0xeacd;\nvar REACT_CONTEXT_TYPE = hasSymbol ? Symbol.for('react.context') : 0xeace; // TODO: We don't use AsyncMode or ConcurrentMode anymore. They were temporary\n// (unstable) APIs that have been removed. Can we remove the symbols?\n\nvar REACT_ASYNC_MODE_TYPE = hasSymbol ? Symbol.for('react.async_mode') : 0xeacf;\nvar REACT_CONCURRENT_MODE_TYPE = hasSymbol ? Symbol.for('react.concurrent_mode') : 0xeacf;\nvar REACT_FORWARD_REF_TYPE = hasSymbol ? Symbol.for('react.forward_ref') : 0xead0;\nvar REACT_SUSPENSE_TYPE = hasSymbol ? Symbol.for('react.suspense') : 0xead1;\nvar REACT_SUSPENSE_LIST_TYPE = hasSymbol ? Symbol.for('react.suspense_list') : 0xead8;\nvar REACT_MEMO_TYPE = hasSymbol ? Symbol.for('react.memo') : 0xead3;\nvar REACT_LAZY_TYPE = hasSymbol ? Symbol.for('react.lazy') : 0xead4;\nvar REACT_BLOCK_TYPE = hasSymbol ? Symbol.for('react.block') : 0xead9;\nvar REACT_FUNDAMENTAL_TYPE = hasSymbol ? Symbol.for('react.fundamental') : 0xead5;\nvar REACT_RESPONDER_TYPE = hasSymbol ? Symbol.for('react.responder') : 0xead6;\nvar REACT_SCOPE_TYPE = hasSymbol ? Symbol.for('react.scope') : 0xead7;\n\nfunction isValidElementType(type) {\n return typeof type === 'string' || typeof type === 'function' || // Note: its typeof might be other than 'symbol' or 'number' if it's a polyfill.\n type === REACT_FRAGMENT_TYPE || type === REACT_CONCURRENT_MODE_TYPE || type === REACT_PROFILER_TYPE || type === REACT_STRICT_MODE_TYPE || type === REACT_SUSPENSE_TYPE || type === REACT_SUSPENSE_LIST_TYPE || typeof type === 'object' && type !== null && (type.$$typeof === REACT_LAZY_TYPE || type.$$typeof === REACT_MEMO_TYPE || type.$$typeof === REACT_PROVIDER_TYPE || type.$$typeof === REACT_CONTEXT_TYPE || type.$$typeof === REACT_FORWARD_REF_TYPE || type.$$typeof === REACT_FUNDAMENTAL_TYPE || type.$$typeof === REACT_RESPONDER_TYPE || type.$$typeof === REACT_SCOPE_TYPE || type.$$typeof === REACT_BLOCK_TYPE);\n}\n\nfunction typeOf(object) {\n if (typeof object === 'object' && object !== null) {\n var $$typeof = object.$$typeof;\n\n switch ($$typeof) {\n case REACT_ELEMENT_TYPE:\n var type = object.type;\n\n switch (type) {\n case REACT_ASYNC_MODE_TYPE:\n case REACT_CONCURRENT_MODE_TYPE:\n case REACT_FRAGMENT_TYPE:\n case REACT_PROFILER_TYPE:\n case REACT_STRICT_MODE_TYPE:\n case REACT_SUSPENSE_TYPE:\n return type;\n\n default:\n var $$typeofType = type && type.$$typeof;\n\n switch ($$typeofType) {\n case REACT_CONTEXT_TYPE:\n case REACT_FORWARD_REF_TYPE:\n case REACT_LAZY_TYPE:\n case REACT_MEMO_TYPE:\n case REACT_PROVIDER_TYPE:\n return $$typeofType;\n\n default:\n return $$typeof;\n }\n\n }\n\n case REACT_PORTAL_TYPE:\n return $$typeof;\n }\n }\n\n return undefined;\n} // AsyncMode is deprecated along with isAsyncMode\n\nvar AsyncMode = REACT_ASYNC_MODE_TYPE;\nvar ConcurrentMode = REACT_CONCURRENT_MODE_TYPE;\nvar ContextConsumer = REACT_CONTEXT_TYPE;\nvar ContextProvider = REACT_PROVIDER_TYPE;\nvar Element = REACT_ELEMENT_TYPE;\nvar ForwardRef = REACT_FORWARD_REF_TYPE;\nvar Fragment = REACT_FRAGMENT_TYPE;\nvar Lazy = REACT_LAZY_TYPE;\nvar Memo = REACT_MEMO_TYPE;\nvar Portal = REACT_PORTAL_TYPE;\nvar Profiler = REACT_PROFILER_TYPE;\nvar StrictMode = REACT_STRICT_MODE_TYPE;\nvar Suspense = REACT_SUSPENSE_TYPE;\nvar hasWarnedAboutDeprecatedIsAsyncMode = false; // AsyncMode should be deprecated\n\nfunction isAsyncMode(object) {\n {\n if (!hasWarnedAboutDeprecatedIsAsyncMode) {\n hasWarnedAboutDeprecatedIsAsyncMode = true; // Using console['warn'] to evade Babel and ESLint\n\n console['warn']('The ReactIs.isAsyncMode() alias has been deprecated, ' + 'and will be removed in React 17+. Update your code to use ' + 'ReactIs.isConcurrentMode() instead. It has the exact same API.');\n }\n }\n\n return isConcurrentMode(object) || typeOf(object) === REACT_ASYNC_MODE_TYPE;\n}\nfunction isConcurrentMode(object) {\n return typeOf(object) === REACT_CONCURRENT_MODE_TYPE;\n}\nfunction isContextConsumer(object) {\n return typeOf(object) === REACT_CONTEXT_TYPE;\n}\nfunction isContextProvider(object) {\n return typeOf(object) === REACT_PROVIDER_TYPE;\n}\nfunction isElement(object) {\n return typeof object === 'object' && object !== null && object.$$typeof === REACT_ELEMENT_TYPE;\n}\nfunction isForwardRef(object) {\n return typeOf(object) === REACT_FORWARD_REF_TYPE;\n}\nfunction isFragment(object) {\n return typeOf(object) === REACT_FRAGMENT_TYPE;\n}\nfunction isLazy(object) {\n return typeOf(object) === REACT_LAZY_TYPE;\n}\nfunction isMemo(object) {\n return typeOf(object) === REACT_MEMO_TYPE;\n}\nfunction isPortal(object) {\n return typeOf(object) === REACT_PORTAL_TYPE;\n}\nfunction isProfiler(object) {\n return typeOf(object) === REACT_PROFILER_TYPE;\n}\nfunction isStrictMode(object) {\n return typeOf(object) === REACT_STRICT_MODE_TYPE;\n}\nfunction isSuspense(object) {\n return typeOf(object) === REACT_SUSPENSE_TYPE;\n}\n\nexports.AsyncMode = AsyncMode;\nexports.ConcurrentMode = ConcurrentMode;\nexports.ContextConsumer = ContextConsumer;\nexports.ContextProvider = ContextProvider;\nexports.Element = Element;\nexports.ForwardRef = ForwardRef;\nexports.Fragment = Fragment;\nexports.Lazy = Lazy;\nexports.Memo = Memo;\nexports.Portal = Portal;\nexports.Profiler = Profiler;\nexports.StrictMode = StrictMode;\nexports.Suspense = Suspense;\nexports.isAsyncMode = isAsyncMode;\nexports.isConcurrentMode = isConcurrentMode;\nexports.isContextConsumer = isContextConsumer;\nexports.isContextProvider = isContextProvider;\nexports.isElement = isElement;\nexports.isForwardRef = isForwardRef;\nexports.isFragment = isFragment;\nexports.isLazy = isLazy;\nexports.isMemo = isMemo;\nexports.isPortal = isPortal;\nexports.isProfiler = isProfiler;\nexports.isStrictMode = isStrictMode;\nexports.isSuspense = isSuspense;\nexports.isValidElementType = isValidElementType;\nexports.typeOf = typeOf;\n })();\n}\n","'use strict';\n\nif (process.env.NODE_ENV === 'production') {\n module.exports = require('./cjs/react-is.production.min.js');\n} else {\n module.exports = require('./cjs/react-is.development.js');\n}\n","/*\nobject-assign\n(c) Sindre Sorhus\n@license MIT\n*/\n\n'use strict';\n/* eslint-disable no-unused-vars */\nvar getOwnPropertySymbols = Object.getOwnPropertySymbols;\nvar hasOwnProperty = Object.prototype.hasOwnProperty;\nvar propIsEnumerable = Object.prototype.propertyIsEnumerable;\n\nfunction toObject(val) {\n\tif (val === null || val === undefined) {\n\t\tthrow new TypeError('Object.assign cannot be called with null or undefined');\n\t}\n\n\treturn Object(val);\n}\n\nfunction shouldUseNative() {\n\ttry {\n\t\tif (!Object.assign) {\n\t\t\treturn false;\n\t\t}\n\n\t\t// Detect buggy property enumeration order in older V8 versions.\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=4118\n\t\tvar test1 = new String('abc'); // eslint-disable-line no-new-wrappers\n\t\ttest1[5] = 'de';\n\t\tif (Object.getOwnPropertyNames(test1)[0] === '5') {\n\t\t\treturn false;\n\t\t}\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=3056\n\t\tvar test2 = {};\n\t\tfor (var i = 0; i < 10; i++) {\n\t\t\ttest2['_' + String.fromCharCode(i)] = i;\n\t\t}\n\t\tvar order2 = Object.getOwnPropertyNames(test2).map(function (n) {\n\t\t\treturn test2[n];\n\t\t});\n\t\tif (order2.join('') !== '0123456789') {\n\t\t\treturn false;\n\t\t}\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=3056\n\t\tvar test3 = {};\n\t\t'abcdefghijklmnopqrst'.split('').forEach(function (letter) {\n\t\t\ttest3[letter] = letter;\n\t\t});\n\t\tif (Object.keys(Object.assign({}, test3)).join('') !==\n\t\t\t\t'abcdefghijklmnopqrst') {\n\t\t\treturn false;\n\t\t}\n\n\t\treturn true;\n\t} catch (err) {\n\t\t// We don't expect any of the above to throw, but better to be safe.\n\t\treturn false;\n\t}\n}\n\nmodule.exports = shouldUseNative() ? Object.assign : function (target, source) {\n\tvar from;\n\tvar to = toObject(target);\n\tvar symbols;\n\n\tfor (var s = 1; s < arguments.length; s++) {\n\t\tfrom = Object(arguments[s]);\n\n\t\tfor (var key in from) {\n\t\t\tif (hasOwnProperty.call(from, key)) {\n\t\t\t\tto[key] = from[key];\n\t\t\t}\n\t\t}\n\n\t\tif (getOwnPropertySymbols) {\n\t\t\tsymbols = getOwnPropertySymbols(from);\n\t\t\tfor (var i = 0; i < symbols.length; i++) {\n\t\t\t\tif (propIsEnumerable.call(from, symbols[i])) {\n\t\t\t\t\tto[symbols[i]] = from[symbols[i]];\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\n\treturn to;\n};\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar ReactPropTypesSecret = 'SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED';\n\nmodule.exports = ReactPropTypesSecret;\n","module.exports = Function.call.bind(Object.prototype.hasOwnProperty);\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar printWarning = function() {};\n\nif (process.env.NODE_ENV !== 'production') {\n var ReactPropTypesSecret = require('./lib/ReactPropTypesSecret');\n var loggedTypeFailures = {};\n var has = require('./lib/has');\n\n printWarning = function(text) {\n var message = 'Warning: ' + text;\n if (typeof console !== 'undefined') {\n console.error(message);\n }\n try {\n // --- Welcome to debugging React ---\n // This error was thrown as a convenience so that you can use this stack\n // to find the callsite that caused this warning to fire.\n throw new Error(message);\n } catch (x) { /**/ }\n };\n}\n\n/**\n * Assert that the values match with the type specs.\n * Error messages are memorized and will only be shown once.\n *\n * @param {object} typeSpecs Map of name to a ReactPropType\n * @param {object} values Runtime values that need to be type-checked\n * @param {string} location e.g. \"prop\", \"context\", \"child context\"\n * @param {string} componentName Name of the component for error messages.\n * @param {?Function} getStack Returns the component stack.\n * @private\n */\nfunction checkPropTypes(typeSpecs, values, location, componentName, getStack) {\n if (process.env.NODE_ENV !== 'production') {\n for (var typeSpecName in typeSpecs) {\n if (has(typeSpecs, typeSpecName)) {\n var error;\n // Prop type validation may throw. In case they do, we don't want to\n // fail the render phase where it didn't fail before. So we log it.\n // After these have been cleaned up, we'll let them throw.\n try {\n // This is intentionally an invariant that gets caught. It's the same\n // behavior as without this statement except with a better message.\n if (typeof typeSpecs[typeSpecName] !== 'function') {\n var err = Error(\n (componentName || 'React class') + ': ' + location + ' type `' + typeSpecName + '` is invalid; ' +\n 'it must be a function, usually from the `prop-types` package, but received `' + typeof typeSpecs[typeSpecName] + '`.' +\n 'This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.'\n );\n err.name = 'Invariant Violation';\n throw err;\n }\n error = typeSpecs[typeSpecName](values, typeSpecName, componentName, location, null, ReactPropTypesSecret);\n } catch (ex) {\n error = ex;\n }\n if (error && !(error instanceof Error)) {\n printWarning(\n (componentName || 'React class') + ': type specification of ' +\n location + ' `' + typeSpecName + '` is invalid; the type checker ' +\n 'function must return `null` or an `Error` but returned a ' + typeof error + '. ' +\n 'You may have forgotten to pass an argument to the type checker ' +\n 'creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and ' +\n 'shape all require an argument).'\n );\n }\n if (error instanceof Error && !(error.message in loggedTypeFailures)) {\n // Only monitor this failure once because there tends to be a lot of the\n // same error.\n loggedTypeFailures[error.message] = true;\n\n var stack = getStack ? getStack() : '';\n\n printWarning(\n 'Failed ' + location + ' type: ' + error.message + (stack != null ? stack : '')\n );\n }\n }\n }\n }\n}\n\n/**\n * Resets warning cache when testing.\n *\n * @private\n */\ncheckPropTypes.resetWarningCache = function() {\n if (process.env.NODE_ENV !== 'production') {\n loggedTypeFailures = {};\n }\n}\n\nmodule.exports = checkPropTypes;\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar ReactIs = require('react-is');\nvar assign = require('object-assign');\n\nvar ReactPropTypesSecret = require('./lib/ReactPropTypesSecret');\nvar has = require('./lib/has');\nvar checkPropTypes = require('./checkPropTypes');\n\nvar printWarning = function() {};\n\nif (process.env.NODE_ENV !== 'production') {\n printWarning = function(text) {\n var message = 'Warning: ' + text;\n if (typeof console !== 'undefined') {\n console.error(message);\n }\n try {\n // --- Welcome to debugging React ---\n // This error was thrown as a convenience so that you can use this stack\n // to find the callsite that caused this warning to fire.\n throw new Error(message);\n } catch (x) {}\n };\n}\n\nfunction emptyFunctionThatReturnsNull() {\n return null;\n}\n\nmodule.exports = function(isValidElement, throwOnDirectAccess) {\n /* global Symbol */\n var ITERATOR_SYMBOL = typeof Symbol === 'function' && Symbol.iterator;\n var FAUX_ITERATOR_SYMBOL = '@@iterator'; // Before Symbol spec.\n\n /**\n * Returns the iterator method function contained on the iterable object.\n *\n * Be sure to invoke the function with the iterable as context:\n *\n * var iteratorFn = getIteratorFn(myIterable);\n * if (iteratorFn) {\n * var iterator = iteratorFn.call(myIterable);\n * ...\n * }\n *\n * @param {?object} maybeIterable\n * @return {?function}\n */\n function getIteratorFn(maybeIterable) {\n var iteratorFn = maybeIterable && (ITERATOR_SYMBOL && maybeIterable[ITERATOR_SYMBOL] || maybeIterable[FAUX_ITERATOR_SYMBOL]);\n if (typeof iteratorFn === 'function') {\n return iteratorFn;\n }\n }\n\n /**\n * Collection of methods that allow declaration and validation of props that are\n * supplied to React components. Example usage:\n *\n * var Props = require('ReactPropTypes');\n * var MyArticle = React.createClass({\n * propTypes: {\n * // An optional string prop named \"description\".\n * description: Props.string,\n *\n * // A required enum prop named \"category\".\n * category: Props.oneOf(['News','Photos']).isRequired,\n *\n * // A prop named \"dialog\" that requires an instance of Dialog.\n * dialog: Props.instanceOf(Dialog).isRequired\n * },\n * render: function() { ... }\n * });\n *\n * A more formal specification of how these methods are used:\n *\n * type := array|bool|func|object|number|string|oneOf([...])|instanceOf(...)\n * decl := ReactPropTypes.{type}(.isRequired)?\n *\n * Each and every declaration produces a function with the same signature. This\n * allows the creation of custom validation functions. For example:\n *\n * var MyLink = React.createClass({\n * propTypes: {\n * // An optional string or URI prop named \"href\".\n * href: function(props, propName, componentName) {\n * var propValue = props[propName];\n * if (propValue != null && typeof propValue !== 'string' &&\n * !(propValue instanceof URI)) {\n * return new Error(\n * 'Expected a string or an URI for ' + propName + ' in ' +\n * componentName\n * );\n * }\n * }\n * },\n * render: function() {...}\n * });\n *\n * @internal\n */\n\n var ANONYMOUS = '<>';\n\n // Important!\n // Keep this list in sync with production version in `./factoryWithThrowingShims.js`.\n var ReactPropTypes = {\n array: createPrimitiveTypeChecker('array'),\n bigint: createPrimitiveTypeChecker('bigint'),\n bool: createPrimitiveTypeChecker('boolean'),\n func: createPrimitiveTypeChecker('function'),\n number: createPrimitiveTypeChecker('number'),\n object: createPrimitiveTypeChecker('object'),\n string: createPrimitiveTypeChecker('string'),\n symbol: createPrimitiveTypeChecker('symbol'),\n\n any: createAnyTypeChecker(),\n arrayOf: createArrayOfTypeChecker,\n element: createElementTypeChecker(),\n elementType: createElementTypeTypeChecker(),\n instanceOf: createInstanceTypeChecker,\n node: createNodeChecker(),\n objectOf: createObjectOfTypeChecker,\n oneOf: createEnumTypeChecker,\n oneOfType: createUnionTypeChecker,\n shape: createShapeTypeChecker,\n exact: createStrictShapeTypeChecker,\n };\n\n /**\n * inlined Object.is polyfill to avoid requiring consumers ship their own\n * https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object/is\n */\n /*eslint-disable no-self-compare*/\n function is(x, y) {\n // SameValue algorithm\n if (x === y) {\n // Steps 1-5, 7-10\n // Steps 6.b-6.e: +0 != -0\n return x !== 0 || 1 / x === 1 / y;\n } else {\n // Step 6.a: NaN == NaN\n return x !== x && y !== y;\n }\n }\n /*eslint-enable no-self-compare*/\n\n /**\n * We use an Error-like object for backward compatibility as people may call\n * PropTypes directly and inspect their output. However, we don't use real\n * Errors anymore. We don't inspect their stack anyway, and creating them\n * is prohibitively expensive if they are created too often, such as what\n * happens in oneOfType() for any type before the one that matched.\n */\n function PropTypeError(message, data) {\n this.message = message;\n this.data = data && typeof data === 'object' ? data: {};\n this.stack = '';\n }\n // Make `instanceof Error` still work for returned errors.\n PropTypeError.prototype = Error.prototype;\n\n function createChainableTypeChecker(validate) {\n if (process.env.NODE_ENV !== 'production') {\n var manualPropTypeCallCache = {};\n var manualPropTypeWarningCount = 0;\n }\n function checkType(isRequired, props, propName, componentName, location, propFullName, secret) {\n componentName = componentName || ANONYMOUS;\n propFullName = propFullName || propName;\n\n if (secret !== ReactPropTypesSecret) {\n if (throwOnDirectAccess) {\n // New behavior only for users of `prop-types` package\n var err = new Error(\n 'Calling PropTypes validators directly is not supported by the `prop-types` package. ' +\n 'Use `PropTypes.checkPropTypes()` to call them. ' +\n 'Read more at http://fb.me/use-check-prop-types'\n );\n err.name = 'Invariant Violation';\n throw err;\n } else if (process.env.NODE_ENV !== 'production' && typeof console !== 'undefined') {\n // Old behavior for people using React.PropTypes\n var cacheKey = componentName + ':' + propName;\n if (\n !manualPropTypeCallCache[cacheKey] &&\n // Avoid spamming the console because they are often not actionable except for lib authors\n manualPropTypeWarningCount < 3\n ) {\n printWarning(\n 'You are manually calling a React.PropTypes validation ' +\n 'function for the `' + propFullName + '` prop on `' + componentName + '`. This is deprecated ' +\n 'and will throw in the standalone `prop-types` package. ' +\n 'You may be seeing this warning due to a third-party PropTypes ' +\n 'library. See https://fb.me/react-warning-dont-call-proptypes ' + 'for details.'\n );\n manualPropTypeCallCache[cacheKey] = true;\n manualPropTypeWarningCount++;\n }\n }\n }\n if (props[propName] == null) {\n if (isRequired) {\n if (props[propName] === null) {\n return new PropTypeError('The ' + location + ' `' + propFullName + '` is marked as required ' + ('in `' + componentName + '`, but its value is `null`.'));\n }\n return new PropTypeError('The ' + location + ' `' + propFullName + '` is marked as required in ' + ('`' + componentName + '`, but its value is `undefined`.'));\n }\n return null;\n } else {\n return validate(props, propName, componentName, location, propFullName);\n }\n }\n\n var chainedCheckType = checkType.bind(null, false);\n chainedCheckType.isRequired = checkType.bind(null, true);\n\n return chainedCheckType;\n }\n\n function createPrimitiveTypeChecker(expectedType) {\n function validate(props, propName, componentName, location, propFullName, secret) {\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== expectedType) {\n // `propValue` being instance of, say, date/regexp, pass the 'object'\n // check, but we can offer a more precise error message here rather than\n // 'of type `object`'.\n var preciseType = getPreciseType(propValue);\n\n return new PropTypeError(\n 'Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + preciseType + '` supplied to `' + componentName + '`, expected ') + ('`' + expectedType + '`.'),\n {expectedType: expectedType}\n );\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createAnyTypeChecker() {\n return createChainableTypeChecker(emptyFunctionThatReturnsNull);\n }\n\n function createArrayOfTypeChecker(typeChecker) {\n function validate(props, propName, componentName, location, propFullName) {\n if (typeof typeChecker !== 'function') {\n return new PropTypeError('Property `' + propFullName + '` of component `' + componentName + '` has invalid PropType notation inside arrayOf.');\n }\n var propValue = props[propName];\n if (!Array.isArray(propValue)) {\n var propType = getPropType(propValue);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected an array.'));\n }\n for (var i = 0; i < propValue.length; i++) {\n var error = typeChecker(propValue, i, componentName, location, propFullName + '[' + i + ']', ReactPropTypesSecret);\n if (error instanceof Error) {\n return error;\n }\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createElementTypeChecker() {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n if (!isValidElement(propValue)) {\n var propType = getPropType(propValue);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected a single ReactElement.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createElementTypeTypeChecker() {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n if (!ReactIs.isValidElementType(propValue)) {\n var propType = getPropType(propValue);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected a single ReactElement type.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createInstanceTypeChecker(expectedClass) {\n function validate(props, propName, componentName, location, propFullName) {\n if (!(props[propName] instanceof expectedClass)) {\n var expectedClassName = expectedClass.name || ANONYMOUS;\n var actualClassName = getClassName(props[propName]);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + actualClassName + '` supplied to `' + componentName + '`, expected ') + ('instance of `' + expectedClassName + '`.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createEnumTypeChecker(expectedValues) {\n if (!Array.isArray(expectedValues)) {\n if (process.env.NODE_ENV !== 'production') {\n if (arguments.length > 1) {\n printWarning(\n 'Invalid arguments supplied to oneOf, expected an array, got ' + arguments.length + ' arguments. ' +\n 'A common mistake is to write oneOf(x, y, z) instead of oneOf([x, y, z]).'\n );\n } else {\n printWarning('Invalid argument supplied to oneOf, expected an array.');\n }\n }\n return emptyFunctionThatReturnsNull;\n }\n\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n for (var i = 0; i < expectedValues.length; i++) {\n if (is(propValue, expectedValues[i])) {\n return null;\n }\n }\n\n var valuesString = JSON.stringify(expectedValues, function replacer(key, value) {\n var type = getPreciseType(value);\n if (type === 'symbol') {\n return String(value);\n }\n return value;\n });\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of value `' + String(propValue) + '` ' + ('supplied to `' + componentName + '`, expected one of ' + valuesString + '.'));\n }\n return createChainableTypeChecker(validate);\n }\n\n function createObjectOfTypeChecker(typeChecker) {\n function validate(props, propName, componentName, location, propFullName) {\n if (typeof typeChecker !== 'function') {\n return new PropTypeError('Property `' + propFullName + '` of component `' + componentName + '` has invalid PropType notation inside objectOf.');\n }\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== 'object') {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected an object.'));\n }\n for (var key in propValue) {\n if (has(propValue, key)) {\n var error = typeChecker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret);\n if (error instanceof Error) {\n return error;\n }\n }\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createUnionTypeChecker(arrayOfTypeCheckers) {\n if (!Array.isArray(arrayOfTypeCheckers)) {\n process.env.NODE_ENV !== 'production' ? printWarning('Invalid argument supplied to oneOfType, expected an instance of array.') : void 0;\n return emptyFunctionThatReturnsNull;\n }\n\n for (var i = 0; i < arrayOfTypeCheckers.length; i++) {\n var checker = arrayOfTypeCheckers[i];\n if (typeof checker !== 'function') {\n printWarning(\n 'Invalid argument supplied to oneOfType. Expected an array of check functions, but ' +\n 'received ' + getPostfixForTypeWarning(checker) + ' at index ' + i + '.'\n );\n return emptyFunctionThatReturnsNull;\n }\n }\n\n function validate(props, propName, componentName, location, propFullName) {\n var expectedTypes = [];\n for (var i = 0; i < arrayOfTypeCheckers.length; i++) {\n var checker = arrayOfTypeCheckers[i];\n var checkerResult = checker(props, propName, componentName, location, propFullName, ReactPropTypesSecret);\n if (checkerResult == null) {\n return null;\n }\n if (checkerResult.data && has(checkerResult.data, 'expectedType')) {\n expectedTypes.push(checkerResult.data.expectedType);\n }\n }\n var expectedTypesMessage = (expectedTypes.length > 0) ? ', expected one of type [' + expectedTypes.join(', ') + ']': '';\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` supplied to ' + ('`' + componentName + '`' + expectedTypesMessage + '.'));\n }\n return createChainableTypeChecker(validate);\n }\n\n function createNodeChecker() {\n function validate(props, propName, componentName, location, propFullName) {\n if (!isNode(props[propName])) {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` supplied to ' + ('`' + componentName + '`, expected a ReactNode.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function invalidValidatorError(componentName, location, propFullName, key, type) {\n return new PropTypeError(\n (componentName || 'React class') + ': ' + location + ' type `' + propFullName + '.' + key + '` is invalid; ' +\n 'it must be a function, usually from the `prop-types` package, but received `' + type + '`.'\n );\n }\n\n function createShapeTypeChecker(shapeTypes) {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== 'object') {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type `' + propType + '` ' + ('supplied to `' + componentName + '`, expected `object`.'));\n }\n for (var key in shapeTypes) {\n var checker = shapeTypes[key];\n if (typeof checker !== 'function') {\n return invalidValidatorError(componentName, location, propFullName, key, getPreciseType(checker));\n }\n var error = checker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret);\n if (error) {\n return error;\n }\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createStrictShapeTypeChecker(shapeTypes) {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== 'object') {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type `' + propType + '` ' + ('supplied to `' + componentName + '`, expected `object`.'));\n }\n // We need to check all keys in case some are required but missing from props.\n var allKeys = assign({}, props[propName], shapeTypes);\n for (var key in allKeys) {\n var checker = shapeTypes[key];\n if (has(shapeTypes, key) && typeof checker !== 'function') {\n return invalidValidatorError(componentName, location, propFullName, key, getPreciseType(checker));\n }\n if (!checker) {\n return new PropTypeError(\n 'Invalid ' + location + ' `' + propFullName + '` key `' + key + '` supplied to `' + componentName + '`.' +\n '\\nBad object: ' + JSON.stringify(props[propName], null, ' ') +\n '\\nValid keys: ' + JSON.stringify(Object.keys(shapeTypes), null, ' ')\n );\n }\n var error = checker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret);\n if (error) {\n return error;\n }\n }\n return null;\n }\n\n return createChainableTypeChecker(validate);\n }\n\n function isNode(propValue) {\n switch (typeof propValue) {\n case 'number':\n case 'string':\n case 'undefined':\n return true;\n case 'boolean':\n return !propValue;\n case 'object':\n if (Array.isArray(propValue)) {\n return propValue.every(isNode);\n }\n if (propValue === null || isValidElement(propValue)) {\n return true;\n }\n\n var iteratorFn = getIteratorFn(propValue);\n if (iteratorFn) {\n var iterator = iteratorFn.call(propValue);\n var step;\n if (iteratorFn !== propValue.entries) {\n while (!(step = iterator.next()).done) {\n if (!isNode(step.value)) {\n return false;\n }\n }\n } else {\n // Iterator will provide entry [k,v] tuples rather than values.\n while (!(step = iterator.next()).done) {\n var entry = step.value;\n if (entry) {\n if (!isNode(entry[1])) {\n return false;\n }\n }\n }\n }\n } else {\n return false;\n }\n\n return true;\n default:\n return false;\n }\n }\n\n function isSymbol(propType, propValue) {\n // Native Symbol.\n if (propType === 'symbol') {\n return true;\n }\n\n // falsy value can't be a Symbol\n if (!propValue) {\n return false;\n }\n\n // 19.4.3.5 Symbol.prototype[@@toStringTag] === 'Symbol'\n if (propValue['@@toStringTag'] === 'Symbol') {\n return true;\n }\n\n // Fallback for non-spec compliant Symbols which are polyfilled.\n if (typeof Symbol === 'function' && propValue instanceof Symbol) {\n return true;\n }\n\n return false;\n }\n\n // Equivalent of `typeof` but with special handling for array and regexp.\n function getPropType(propValue) {\n var propType = typeof propValue;\n if (Array.isArray(propValue)) {\n return 'array';\n }\n if (propValue instanceof RegExp) {\n // Old webkits (at least until Android 4.0) return 'function' rather than\n // 'object' for typeof a RegExp. We'll normalize this here so that /bla/\n // passes PropTypes.object.\n return 'object';\n }\n if (isSymbol(propType, propValue)) {\n return 'symbol';\n }\n return propType;\n }\n\n // This handles more types than `getPropType`. Only used for error messages.\n // See `createPrimitiveTypeChecker`.\n function getPreciseType(propValue) {\n if (typeof propValue === 'undefined' || propValue === null) {\n return '' + propValue;\n }\n var propType = getPropType(propValue);\n if (propType === 'object') {\n if (propValue instanceof Date) {\n return 'date';\n } else if (propValue instanceof RegExp) {\n return 'regexp';\n }\n }\n return propType;\n }\n\n // Returns a string that is postfixed to a warning about an invalid type.\n // For example, \"undefined\" or \"of type array\"\n function getPostfixForTypeWarning(value) {\n var type = getPreciseType(value);\n switch (type) {\n case 'array':\n case 'object':\n return 'an ' + type;\n case 'boolean':\n case 'date':\n case 'regexp':\n return 'a ' + type;\n default:\n return type;\n }\n }\n\n // Returns class name of the object, if any.\n function getClassName(propValue) {\n if (!propValue.constructor || !propValue.constructor.name) {\n return ANONYMOUS;\n }\n return propValue.constructor.name;\n }\n\n ReactPropTypes.checkPropTypes = checkPropTypes;\n ReactPropTypes.resetWarningCache = checkPropTypes.resetWarningCache;\n ReactPropTypes.PropTypes = ReactPropTypes;\n\n return ReactPropTypes;\n};\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar ReactPropTypesSecret = require('./lib/ReactPropTypesSecret');\n\nfunction emptyFunction() {}\nfunction emptyFunctionWithReset() {}\nemptyFunctionWithReset.resetWarningCache = emptyFunction;\n\nmodule.exports = function() {\n function shim(props, propName, componentName, location, propFullName, secret) {\n if (secret === ReactPropTypesSecret) {\n // It is still safe when called from React.\n return;\n }\n var err = new Error(\n 'Calling PropTypes validators directly is not supported by the `prop-types` package. ' +\n 'Use PropTypes.checkPropTypes() to call them. ' +\n 'Read more at http://fb.me/use-check-prop-types'\n );\n err.name = 'Invariant Violation';\n throw err;\n };\n shim.isRequired = shim;\n function getShim() {\n return shim;\n };\n // Important!\n // Keep this list in sync with production version in `./factoryWithTypeCheckers.js`.\n var ReactPropTypes = {\n array: shim,\n bigint: shim,\n bool: shim,\n func: shim,\n number: shim,\n object: shim,\n string: shim,\n symbol: shim,\n\n any: shim,\n arrayOf: getShim,\n element: shim,\n elementType: shim,\n instanceOf: getShim,\n node: shim,\n objectOf: getShim,\n oneOf: getShim,\n oneOfType: getShim,\n shape: getShim,\n exact: getShim,\n\n checkPropTypes: emptyFunctionWithReset,\n resetWarningCache: emptyFunction\n };\n\n ReactPropTypes.PropTypes = ReactPropTypes;\n\n return ReactPropTypes;\n};\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\nif (process.env.NODE_ENV !== 'production') {\n var ReactIs = require('react-is');\n\n // By explicitly using `prop-types` you are opting into new development behavior.\n // http://fb.me/prop-types-in-prod\n var throwOnDirectAccess = true;\n module.exports = require('./factoryWithTypeCheckers')(ReactIs.isElement, throwOnDirectAccess);\n} else {\n // By explicitly using `prop-types` you are opting into new production behavior.\n // http://fb.me/prop-types-in-prod\n module.exports = require('./factoryWithThrowingShims')();\n}\n","import PropTypes from 'prop-types';\nimport chainPropTypes from '../chainPropTypes';\nfunction isClassComponent(elementType) {\n // elementType.prototype?.isReactComponent\n const {\n prototype = {}\n } = elementType;\n return Boolean(prototype.isReactComponent);\n}\nfunction acceptingRef(props, propName, componentName, location, propFullName) {\n const element = props[propName];\n const safePropName = propFullName || propName;\n if (element == null ||\n // When server-side rendering React doesn't warn either.\n // This is not an accurate check for SSR.\n // This is only in place for Emotion compat.\n // TODO: Revisit once https://github.com/facebook/react/issues/20047 is resolved.\n typeof window === 'undefined') {\n return null;\n }\n let warningHint;\n const elementType = element.type;\n /**\n * Blacklisting instead of whitelisting\n *\n * Blacklisting will miss some components, such as React.Fragment. Those will at least\n * trigger a warning in React.\n * We can't whitelist because there is no safe way to detect React.forwardRef\n * or class components. \"Safe\" means there's no public API.\n *\n */\n if (typeof elementType === 'function' && !isClassComponent(elementType)) {\n warningHint = 'Did you accidentally use a plain function component for an element instead?';\n }\n if (warningHint !== undefined) {\n return new Error(`Invalid ${location} \\`${safePropName}\\` supplied to \\`${componentName}\\`. ` + `Expected an element that can hold a ref. ${warningHint} ` + 'For more information see https://mui.com/r/caveat-with-refs-guide');\n }\n return null;\n}\nconst elementAcceptingRef = chainPropTypes(PropTypes.element, acceptingRef);\nelementAcceptingRef.isRequired = chainPropTypes(PropTypes.element.isRequired, acceptingRef);\nexport default elementAcceptingRef;","import _extends from \"@babel/runtime/helpers/esm/extends\";\n// This module is based on https://github.com/airbnb/prop-types-exact repository.\n// However, in order to reduce the number of dependencies and to remove some extra safe checks\n// the module was forked.\n\nconst specialProperty = 'exact-prop: \\u200b';\nexport default function exactProp(propTypes) {\n if (process.env.NODE_ENV === 'production') {\n return propTypes;\n }\n return _extends({}, propTypes, {\n [specialProperty]: props => {\n const unsupportedProps = Object.keys(props).filter(prop => !propTypes.hasOwnProperty(prop));\n if (unsupportedProps.length > 0) {\n return new Error(`The following props are not supported: ${unsupportedProps.map(prop => `\\`${prop}\\``).join(', ')}. Please remove them.`);\n }\n return null;\n }\n });\n}","/**\n * WARNING: Don't import this directly.\n * Use `MuiError` from `@mui/internal-babel-macros/MuiError.macro` instead.\n * @param {number} code\n */\nexport default function formatMuiErrorMessage(code) {\n // Apply babel-plugin-transform-template-literals in loose mode\n // loose mode is safe if we're concatenating primitives\n // see https://babeljs.io/docs/en/babel-plugin-transform-template-literals#loose\n /* eslint-disable prefer-template */\n let url = 'https://mui.com/production-error/?code=' + code;\n for (let i = 1; i < arguments.length; i += 1) {\n // rest params over-transpile for this case\n // eslint-disable-next-line prefer-rest-params\n url += '&args[]=' + encodeURIComponent(arguments[i]);\n }\n return 'Minified MUI error #' + code + '; visit ' + url + ' for the full message.';\n /* eslint-enable prefer-template */\n}","/**\n * @license React\n * react-is.production.min.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n'use strict';var b=Symbol.for(\"react.element\"),c=Symbol.for(\"react.portal\"),d=Symbol.for(\"react.fragment\"),e=Symbol.for(\"react.strict_mode\"),f=Symbol.for(\"react.profiler\"),g=Symbol.for(\"react.provider\"),h=Symbol.for(\"react.context\"),k=Symbol.for(\"react.server_context\"),l=Symbol.for(\"react.forward_ref\"),m=Symbol.for(\"react.suspense\"),n=Symbol.for(\"react.suspense_list\"),p=Symbol.for(\"react.memo\"),q=Symbol.for(\"react.lazy\"),t=Symbol.for(\"react.offscreen\"),u;u=Symbol.for(\"react.module.reference\");\nfunction v(a){if(\"object\"===typeof a&&null!==a){var r=a.$$typeof;switch(r){case b:switch(a=a.type,a){case d:case f:case e:case m:case n:return a;default:switch(a=a&&a.$$typeof,a){case k:case h:case l:case q:case p:case g:return a;default:return r}}case c:return r}}}exports.ContextConsumer=h;exports.ContextProvider=g;exports.Element=b;exports.ForwardRef=l;exports.Fragment=d;exports.Lazy=q;exports.Memo=p;exports.Portal=c;exports.Profiler=f;exports.StrictMode=e;exports.Suspense=m;\nexports.SuspenseList=n;exports.isAsyncMode=function(){return!1};exports.isConcurrentMode=function(){return!1};exports.isContextConsumer=function(a){return v(a)===h};exports.isContextProvider=function(a){return v(a)===g};exports.isElement=function(a){return\"object\"===typeof a&&null!==a&&a.$$typeof===b};exports.isForwardRef=function(a){return v(a)===l};exports.isFragment=function(a){return v(a)===d};exports.isLazy=function(a){return v(a)===q};exports.isMemo=function(a){return v(a)===p};\nexports.isPortal=function(a){return v(a)===c};exports.isProfiler=function(a){return v(a)===f};exports.isStrictMode=function(a){return v(a)===e};exports.isSuspense=function(a){return v(a)===m};exports.isSuspenseList=function(a){return v(a)===n};\nexports.isValidElementType=function(a){return\"string\"===typeof a||\"function\"===typeof a||a===d||a===f||a===e||a===m||a===n||a===t||\"object\"===typeof a&&null!==a&&(a.$$typeof===q||a.$$typeof===p||a.$$typeof===g||a.$$typeof===h||a.$$typeof===l||a.$$typeof===u||void 0!==a.getModuleId)?!0:!1};exports.typeOf=v;\n","/**\n * @license React\n * react-is.development.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nif (process.env.NODE_ENV !== \"production\") {\n (function() {\n'use strict';\n\n// ATTENTION\n// When adding new symbols to this file,\n// Please consider also adding to 'react-devtools-shared/src/backend/ReactSymbols'\n// The Symbol used to tag the ReactElement-like types.\nvar REACT_ELEMENT_TYPE = Symbol.for('react.element');\nvar REACT_PORTAL_TYPE = Symbol.for('react.portal');\nvar REACT_FRAGMENT_TYPE = Symbol.for('react.fragment');\nvar REACT_STRICT_MODE_TYPE = Symbol.for('react.strict_mode');\nvar REACT_PROFILER_TYPE = Symbol.for('react.profiler');\nvar REACT_PROVIDER_TYPE = Symbol.for('react.provider');\nvar REACT_CONTEXT_TYPE = Symbol.for('react.context');\nvar REACT_SERVER_CONTEXT_TYPE = Symbol.for('react.server_context');\nvar REACT_FORWARD_REF_TYPE = Symbol.for('react.forward_ref');\nvar REACT_SUSPENSE_TYPE = Symbol.for('react.suspense');\nvar REACT_SUSPENSE_LIST_TYPE = Symbol.for('react.suspense_list');\nvar REACT_MEMO_TYPE = Symbol.for('react.memo');\nvar REACT_LAZY_TYPE = Symbol.for('react.lazy');\nvar REACT_OFFSCREEN_TYPE = Symbol.for('react.offscreen');\n\n// -----------------------------------------------------------------------------\n\nvar enableScopeAPI = false; // Experimental Create Event Handle API.\nvar enableCacheElement = false;\nvar enableTransitionTracing = false; // No known bugs, but needs performance testing\n\nvar enableLegacyHidden = false; // Enables unstable_avoidThisFallback feature in Fiber\n// stuff. Intended to enable React core members to more easily debug scheduling\n// issues in DEV builds.\n\nvar enableDebugTracing = false; // Track which Fiber(s) schedule render work.\n\nvar REACT_MODULE_REFERENCE;\n\n{\n REACT_MODULE_REFERENCE = Symbol.for('react.module.reference');\n}\n\nfunction isValidElementType(type) {\n if (typeof type === 'string' || typeof type === 'function') {\n return true;\n } // Note: typeof might be other than 'symbol' or 'number' (e.g. if it's a polyfill).\n\n\n if (type === REACT_FRAGMENT_TYPE || type === REACT_PROFILER_TYPE || enableDebugTracing || type === REACT_STRICT_MODE_TYPE || type === REACT_SUSPENSE_TYPE || type === REACT_SUSPENSE_LIST_TYPE || enableLegacyHidden || type === REACT_OFFSCREEN_TYPE || enableScopeAPI || enableCacheElement || enableTransitionTracing ) {\n return true;\n }\n\n if (typeof type === 'object' && type !== null) {\n if (type.$$typeof === REACT_LAZY_TYPE || type.$$typeof === REACT_MEMO_TYPE || type.$$typeof === REACT_PROVIDER_TYPE || type.$$typeof === REACT_CONTEXT_TYPE || type.$$typeof === REACT_FORWARD_REF_TYPE || // This needs to include all possible module reference object\n // types supported by any Flight configuration anywhere since\n // we don't know which Flight build this will end up being used\n // with.\n type.$$typeof === REACT_MODULE_REFERENCE || type.getModuleId !== undefined) {\n return true;\n }\n }\n\n return false;\n}\n\nfunction typeOf(object) {\n if (typeof object === 'object' && object !== null) {\n var $$typeof = object.$$typeof;\n\n switch ($$typeof) {\n case REACT_ELEMENT_TYPE:\n var type = object.type;\n\n switch (type) {\n case REACT_FRAGMENT_TYPE:\n case REACT_PROFILER_TYPE:\n case REACT_STRICT_MODE_TYPE:\n case REACT_SUSPENSE_TYPE:\n case REACT_SUSPENSE_LIST_TYPE:\n return type;\n\n default:\n var $$typeofType = type && type.$$typeof;\n\n switch ($$typeofType) {\n case REACT_SERVER_CONTEXT_TYPE:\n case REACT_CONTEXT_TYPE:\n case REACT_FORWARD_REF_TYPE:\n case REACT_LAZY_TYPE:\n case REACT_MEMO_TYPE:\n case REACT_PROVIDER_TYPE:\n return $$typeofType;\n\n default:\n return $$typeof;\n }\n\n }\n\n case REACT_PORTAL_TYPE:\n return $$typeof;\n }\n }\n\n return undefined;\n}\nvar ContextConsumer = REACT_CONTEXT_TYPE;\nvar ContextProvider = REACT_PROVIDER_TYPE;\nvar Element = REACT_ELEMENT_TYPE;\nvar ForwardRef = REACT_FORWARD_REF_TYPE;\nvar Fragment = REACT_FRAGMENT_TYPE;\nvar Lazy = REACT_LAZY_TYPE;\nvar Memo = REACT_MEMO_TYPE;\nvar Portal = REACT_PORTAL_TYPE;\nvar Profiler = REACT_PROFILER_TYPE;\nvar StrictMode = REACT_STRICT_MODE_TYPE;\nvar Suspense = REACT_SUSPENSE_TYPE;\nvar SuspenseList = REACT_SUSPENSE_LIST_TYPE;\nvar hasWarnedAboutDeprecatedIsAsyncMode = false;\nvar hasWarnedAboutDeprecatedIsConcurrentMode = false; // AsyncMode should be deprecated\n\nfunction isAsyncMode(object) {\n {\n if (!hasWarnedAboutDeprecatedIsAsyncMode) {\n hasWarnedAboutDeprecatedIsAsyncMode = true; // Using console['warn'] to evade Babel and ESLint\n\n console['warn']('The ReactIs.isAsyncMode() alias has been deprecated, ' + 'and will be removed in React 18+.');\n }\n }\n\n return false;\n}\nfunction isConcurrentMode(object) {\n {\n if (!hasWarnedAboutDeprecatedIsConcurrentMode) {\n hasWarnedAboutDeprecatedIsConcurrentMode = true; // Using console['warn'] to evade Babel and ESLint\n\n console['warn']('The ReactIs.isConcurrentMode() alias has been deprecated, ' + 'and will be removed in React 18+.');\n }\n }\n\n return false;\n}\nfunction isContextConsumer(object) {\n return typeOf(object) === REACT_CONTEXT_TYPE;\n}\nfunction isContextProvider(object) {\n return typeOf(object) === REACT_PROVIDER_TYPE;\n}\nfunction isElement(object) {\n return typeof object === 'object' && object !== null && object.$$typeof === REACT_ELEMENT_TYPE;\n}\nfunction isForwardRef(object) {\n return typeOf(object) === REACT_FORWARD_REF_TYPE;\n}\nfunction isFragment(object) {\n return typeOf(object) === REACT_FRAGMENT_TYPE;\n}\nfunction isLazy(object) {\n return typeOf(object) === REACT_LAZY_TYPE;\n}\nfunction isMemo(object) {\n return typeOf(object) === REACT_MEMO_TYPE;\n}\nfunction isPortal(object) {\n return typeOf(object) === REACT_PORTAL_TYPE;\n}\nfunction isProfiler(object) {\n return typeOf(object) === REACT_PROFILER_TYPE;\n}\nfunction isStrictMode(object) {\n return typeOf(object) === REACT_STRICT_MODE_TYPE;\n}\nfunction isSuspense(object) {\n return typeOf(object) === REACT_SUSPENSE_TYPE;\n}\nfunction isSuspenseList(object) {\n return typeOf(object) === REACT_SUSPENSE_LIST_TYPE;\n}\n\nexports.ContextConsumer = ContextConsumer;\nexports.ContextProvider = ContextProvider;\nexports.Element = Element;\nexports.ForwardRef = ForwardRef;\nexports.Fragment = Fragment;\nexports.Lazy = Lazy;\nexports.Memo = Memo;\nexports.Portal = Portal;\nexports.Profiler = Profiler;\nexports.StrictMode = StrictMode;\nexports.Suspense = Suspense;\nexports.SuspenseList = SuspenseList;\nexports.isAsyncMode = isAsyncMode;\nexports.isConcurrentMode = isConcurrentMode;\nexports.isContextConsumer = isContextConsumer;\nexports.isContextProvider = isContextProvider;\nexports.isElement = isElement;\nexports.isForwardRef = isForwardRef;\nexports.isFragment = isFragment;\nexports.isLazy = isLazy;\nexports.isMemo = isMemo;\nexports.isPortal = isPortal;\nexports.isProfiler = isProfiler;\nexports.isStrictMode = isStrictMode;\nexports.isSuspense = isSuspense;\nexports.isSuspenseList = isSuspenseList;\nexports.isValidElementType = isValidElementType;\nexports.typeOf = typeOf;\n })();\n}\n","'use strict';\n\nif (process.env.NODE_ENV === 'production') {\n module.exports = require('./cjs/react-is.production.min.js');\n} else {\n module.exports = require('./cjs/react-is.development.js');\n}\n","import { ForwardRef, Memo } from 'react-is';\n\n// Simplified polyfill for IE11 support\n// https://github.com/JamesMGreene/Function.name/blob/58b314d4a983110c3682f1228f845d39ccca1817/Function.name.js#L3\nconst fnNameMatchRegex = /^\\s*function(?:\\s|\\s*\\/\\*.*\\*\\/\\s*)+([^(\\s/]*)\\s*/;\nexport function getFunctionName(fn) {\n const match = `${fn}`.match(fnNameMatchRegex);\n const name = match && match[1];\n return name || '';\n}\nfunction getFunctionComponentName(Component, fallback = '') {\n return Component.displayName || Component.name || getFunctionName(Component) || fallback;\n}\nfunction getWrappedName(outerType, innerType, wrapperName) {\n const functionName = getFunctionComponentName(innerType);\n return outerType.displayName || (functionName !== '' ? `${wrapperName}(${functionName})` : wrapperName);\n}\n\n/**\n * cherry-pick from\n * https://github.com/facebook/react/blob/769b1f270e1251d9dbdce0fcbd9e92e502d059b8/packages/shared/getComponentName.js\n * originally forked from recompose/getDisplayName with added IE11 support\n */\nexport default function getDisplayName(Component) {\n if (Component == null) {\n return undefined;\n }\n if (typeof Component === 'string') {\n return Component;\n }\n if (typeof Component === 'function') {\n return getFunctionComponentName(Component, 'Component');\n }\n\n // TypeScript can't have components as objects but they exist in the form of `memo` or `Suspense`\n if (typeof Component === 'object') {\n switch (Component.$$typeof) {\n case ForwardRef:\n return getWrappedName(Component, Component.render, 'ForwardRef');\n case Memo:\n return getWrappedName(Component, Component.type, 'memo');\n default:\n return undefined;\n }\n }\n return undefined;\n}","export default function HTMLElementType(props, propName, componentName, location, propFullName) {\n if (process.env.NODE_ENV === 'production') {\n return null;\n }\n const propValue = props[propName];\n const safePropName = propFullName || propName;\n if (propValue == null) {\n return null;\n }\n if (propValue && propValue.nodeType !== 1) {\n return new Error(`Invalid ${location} \\`${safePropName}\\` supplied to \\`${componentName}\\`. ` + `Expected an HTMLElement.`);\n }\n return null;\n}","import PropTypes from 'prop-types';\nconst refType = PropTypes.oneOfType([PropTypes.func, PropTypes.object]);\nexport default refType;","import _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\n// It should to be noted that this function isn't equivalent to `text-transform: capitalize`.\n//\n// A strict capitalization should uppercase the first letter of each word in the sentence.\n// We only handle the first word.\nexport default function capitalize(string) {\n if (typeof string !== 'string') {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: \\`capitalize(string)\\` expects a string argument.` : _formatMuiErrorMessage(7));\n }\n return string.charAt(0).toUpperCase() + string.slice(1);\n}","/**\n * Safe chained function.\n *\n * Will only create a new function if needed,\n * otherwise will pass back existing functions or null.\n */\nexport default function createChainedFunction(...funcs) {\n return funcs.reduce((acc, func) => {\n if (func == null) {\n return acc;\n }\n return function chainedFunction(...args) {\n acc.apply(this, args);\n func.apply(this, args);\n };\n }, () => {});\n}","// Corresponds to 10 frames at 60 Hz.\n// A few bytes payload overhead when lodash/debounce is ~3 kB and debounce ~300 B.\nexport default function debounce(func, wait = 166) {\n let timeout;\n function debounced(...args) {\n const later = () => {\n // @ts-ignore\n func.apply(this, args);\n };\n clearTimeout(timeout);\n timeout = setTimeout(later, wait);\n }\n debounced.clear = () => {\n clearTimeout(timeout);\n };\n return debounced;\n}","export default function deprecatedPropType(validator, reason) {\n if (process.env.NODE_ENV === 'production') {\n return () => null;\n }\n return (props, propName, componentName, location, propFullName) => {\n const componentNameSafe = componentName || '<>';\n const propFullNameSafe = propFullName || propName;\n if (typeof props[propName] !== 'undefined') {\n return new Error(`The ${location} \\`${propFullNameSafe}\\` of ` + `\\`${componentNameSafe}\\` is deprecated. ${reason}`);\n }\n return null;\n };\n}","import * as React from 'react';\nexport default function isMuiElement(element, muiNames) {\n var _muiName, _element$type;\n return /*#__PURE__*/React.isValidElement(element) && muiNames.indexOf( // For server components `muiName` is avaialble in element.type._payload.value.muiName\n // relevant info - https://github.com/facebook/react/blob/2807d781a08db8e9873687fccc25c0f12b4fb3d4/packages/react/src/ReactLazy.js#L45\n // eslint-disable-next-line no-underscore-dangle\n (_muiName = element.type.muiName) != null ? _muiName : (_element$type = element.type) == null || (_element$type = _element$type._payload) == null || (_element$type = _element$type.value) == null ? void 0 : _element$type.muiName) !== -1;\n}","export default function ownerDocument(node) {\n return node && node.ownerDocument || document;\n}","import ownerDocument from '../ownerDocument';\nexport default function ownerWindow(node) {\n const doc = ownerDocument(node);\n return doc.defaultView || window;\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nexport default function requirePropFactory(componentNameInError, Component) {\n if (process.env.NODE_ENV === 'production') {\n return () => null;\n }\n\n // eslint-disable-next-line react/forbid-foreign-prop-types\n const prevPropTypes = Component ? _extends({}, Component.propTypes) : null;\n const requireProp = requiredProp => (props, propName, componentName, location, propFullName, ...args) => {\n const propFullNameSafe = propFullName || propName;\n const defaultTypeChecker = prevPropTypes == null ? void 0 : prevPropTypes[propFullNameSafe];\n if (defaultTypeChecker) {\n const typeCheckerResult = defaultTypeChecker(props, propName, componentName, location, propFullName, ...args);\n if (typeCheckerResult) {\n return typeCheckerResult;\n }\n }\n if (typeof props[propName] !== 'undefined' && !props[requiredProp]) {\n return new Error(`The prop \\`${propFullNameSafe}\\` of ` + `\\`${componentNameInError}\\` can only be used together with the \\`${requiredProp}\\` prop.`);\n }\n return null;\n };\n return requireProp;\n}","/**\n * TODO v5: consider making it private\n *\n * passes {value} to {ref}\n *\n * WARNING: Be sure to only call this inside a callback that is passed as a ref.\n * Otherwise, make sure to cleanup the previous {ref} if it changes. See\n * https://github.com/mui/material-ui/issues/13539\n *\n * Useful if you want to expose the ref of an inner component to the public API\n * while still using it inside the component.\n * @param ref A ref callback or ref object. If anything falsy, this is a no-op.\n */\nexport default function setRef(ref, value) {\n if (typeof ref === 'function') {\n ref(value);\n } else if (ref) {\n ref.current = value;\n }\n}","'use client';\n\nimport * as React from 'react';\n\n/**\n * A version of `React.useLayoutEffect` that does not show a warning when server-side rendering.\n * This is useful for effects that are only needed for client-side rendering but not for SSR.\n *\n * Before you use this hook, make sure to read https://gist.github.com/gaearon/e7d97cdf38a2907924ea12e4ebdf3c85\n * and confirm it doesn't apply to your use-case.\n */\nconst useEnhancedEffect = typeof window !== 'undefined' ? React.useLayoutEffect : React.useEffect;\nexport default useEnhancedEffect;","'use client';\n\nimport * as React from 'react';\nlet globalId = 0;\nfunction useGlobalId(idOverride) {\n const [defaultId, setDefaultId] = React.useState(idOverride);\n const id = idOverride || defaultId;\n React.useEffect(() => {\n if (defaultId == null) {\n // Fallback to this default id when possible.\n // Use the incrementing value for client-side rendering only.\n // We can't use it server-side.\n // If you want to use random values please consider the Birthday Problem: https://en.wikipedia.org/wiki/Birthday_problem\n globalId += 1;\n setDefaultId(`mui-${globalId}`);\n }\n }, [defaultId]);\n return id;\n}\n\n// downstream bundlers may remove unnecessary concatenation, but won't remove toString call -- Workaround for https://github.com/webpack/webpack/issues/14814\nconst maybeReactUseId = React['useId'.toString()];\n/**\n *\n * @example
    \n * @param idOverride\n * @returns {string}\n */\nexport default function useId(idOverride) {\n if (maybeReactUseId !== undefined) {\n const reactId = maybeReactUseId();\n return idOverride != null ? idOverride : reactId;\n }\n // eslint-disable-next-line react-hooks/rules-of-hooks -- `React.useId` is invariant at runtime.\n return useGlobalId(idOverride);\n}","export default function unsupportedProp(props, propName, componentName, location, propFullName) {\n if (process.env.NODE_ENV === 'production') {\n return null;\n }\n const propFullNameSafe = propFullName || propName;\n if (typeof props[propName] !== 'undefined') {\n return new Error(`The prop \\`${propFullNameSafe}\\` is not supported. Please remove it.`);\n }\n return null;\n}","'use client';\n\n/* eslint-disable react-hooks/rules-of-hooks, react-hooks/exhaustive-deps */\nimport * as React from 'react';\nexport default function useControlled({\n controlled,\n default: defaultProp,\n name,\n state = 'value'\n}) {\n // isControlled is ignored in the hook dependency lists as it should never change.\n const {\n current: isControlled\n } = React.useRef(controlled !== undefined);\n const [valueState, setValue] = React.useState(defaultProp);\n const value = isControlled ? controlled : valueState;\n if (process.env.NODE_ENV !== 'production') {\n React.useEffect(() => {\n if (isControlled !== (controlled !== undefined)) {\n console.error([`MUI: A component is changing the ${isControlled ? '' : 'un'}controlled ${state} state of ${name} to be ${isControlled ? 'un' : ''}controlled.`, 'Elements should not switch from uncontrolled to controlled (or vice versa).', `Decide between using a controlled or uncontrolled ${name} ` + 'element for the lifetime of the component.', \"The nature of the state is determined during the first render. It's considered controlled if the value is not `undefined`.\", 'More info: https://fb.me/react-controlled-components'].join('\\n'));\n }\n }, [state, name, controlled]);\n const {\n current: defaultValue\n } = React.useRef(defaultProp);\n React.useEffect(() => {\n if (!isControlled && defaultValue !== defaultProp) {\n console.error([`MUI: A component is changing the default ${state} state of an uncontrolled ${name} after being initialized. ` + `To suppress this warning opt to use a controlled ${name}.`].join('\\n'));\n }\n }, [JSON.stringify(defaultProp)]);\n }\n const setValueIfUncontrolled = React.useCallback(newValue => {\n if (!isControlled) {\n setValue(newValue);\n }\n }, []);\n return [value, setValueIfUncontrolled];\n}","'use client';\n\nimport * as React from 'react';\nimport useEnhancedEffect from '../useEnhancedEffect';\n\n/**\n * Inspired by https://github.com/facebook/react/issues/14099#issuecomment-440013892\n * See RFC in https://github.com/reactjs/rfcs/pull/220\n */\n\nfunction useEventCallback(fn) {\n const ref = React.useRef(fn);\n useEnhancedEffect(() => {\n ref.current = fn;\n });\n return React.useRef((...args) =>\n // @ts-expect-error hide `this`\n (0, ref.current)(...args)).current;\n}\nexport default useEventCallback;","'use client';\n\nimport * as React from 'react';\nimport setRef from '../setRef';\nexport default function useForkRef(...refs) {\n /**\n * This will create a new function if the refs passed to this hook change and are all defined.\n * This means react will call the old forkRef with `null` and the new forkRef\n * with the ref. Cleanup naturally emerges from this behavior.\n */\n return React.useMemo(() => {\n if (refs.every(ref => ref == null)) {\n return null;\n }\n return instance => {\n refs.forEach(ref => {\n setRef(ref, instance);\n });\n };\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, refs);\n}","'use client';\n\nimport * as React from 'react';\nconst UNINITIALIZED = {};\n\n/**\n * A React.useRef() that is initialized lazily with a function. Note that it accepts an optional\n * initialization argument, so the initialization function doesn't need to be an inline closure.\n *\n * @usage\n * const ref = useLazyRef(sortColumns, columns)\n */\nexport default function useLazyRef(init, initArg) {\n const ref = React.useRef(UNINITIALIZED);\n if (ref.current === UNINITIALIZED) {\n ref.current = init(initArg);\n }\n return ref;\n}","'use client';\n\nimport * as React from 'react';\nconst EMPTY = [];\n\n/**\n * A React.useEffect equivalent that runs once, when the component is mounted.\n */\nexport default function useOnMount(fn) {\n /* eslint-disable react-hooks/exhaustive-deps */\n React.useEffect(fn, EMPTY);\n /* eslint-enable react-hooks/exhaustive-deps */\n}","'use client';\n\nimport useLazyRef from '../useLazyRef/useLazyRef';\nimport useOnMount from '../useOnMount/useOnMount';\nexport class Timeout {\n constructor() {\n this.currentId = null;\n this.clear = () => {\n if (this.currentId !== null) {\n clearTimeout(this.currentId);\n this.currentId = null;\n }\n };\n this.disposeEffect = () => {\n return this.clear;\n };\n }\n static create() {\n return new Timeout();\n }\n /**\n * Executes `fn` after `delay`, clearing any previously scheduled call.\n */\n start(delay, fn) {\n this.clear();\n this.currentId = setTimeout(() => {\n this.currentId = null;\n fn();\n }, delay);\n }\n}\nexport default function useTimeout() {\n const timeout = useLazyRef(Timeout.create).current;\n useOnMount(timeout.disposeEffect);\n return timeout;\n}","'use client';\n\n// based on https://github.com/WICG/focus-visible/blob/v4.1.5/src/focus-visible.js\nimport * as React from 'react';\nimport { Timeout } from '../useTimeout/useTimeout';\nlet hadKeyboardEvent = true;\nlet hadFocusVisibleRecently = false;\nconst hadFocusVisibleRecentlyTimeout = new Timeout();\nconst inputTypesWhitelist = {\n text: true,\n search: true,\n url: true,\n tel: true,\n email: true,\n password: true,\n number: true,\n date: true,\n month: true,\n week: true,\n time: true,\n datetime: true,\n 'datetime-local': true\n};\n\n/**\n * Computes whether the given element should automatically trigger the\n * `focus-visible` class being added, i.e. whether it should always match\n * `:focus-visible` when focused.\n * @param {Element} node\n * @returns {boolean}\n */\nfunction focusTriggersKeyboardModality(node) {\n const {\n type,\n tagName\n } = node;\n if (tagName === 'INPUT' && inputTypesWhitelist[type] && !node.readOnly) {\n return true;\n }\n if (tagName === 'TEXTAREA' && !node.readOnly) {\n return true;\n }\n if (node.isContentEditable) {\n return true;\n }\n return false;\n}\n\n/**\n * Keep track of our keyboard modality state with `hadKeyboardEvent`.\n * If the most recent user interaction was via the keyboard;\n * and the key press did not include a meta, alt/option, or control key;\n * then the modality is keyboard. Otherwise, the modality is not keyboard.\n * @param {KeyboardEvent} event\n */\nfunction handleKeyDown(event) {\n if (event.metaKey || event.altKey || event.ctrlKey) {\n return;\n }\n hadKeyboardEvent = true;\n}\n\n/**\n * If at any point a user clicks with a pointing device, ensure that we change\n * the modality away from keyboard.\n * This avoids the situation where a user presses a key on an already focused\n * element, and then clicks on a different element, focusing it with a\n * pointing device, while we still think we're in keyboard modality.\n */\nfunction handlePointerDown() {\n hadKeyboardEvent = false;\n}\nfunction handleVisibilityChange() {\n if (this.visibilityState === 'hidden') {\n // If the tab becomes active again, the browser will handle calling focus\n // on the element (Safari actually calls it twice).\n // If this tab change caused a blur on an element with focus-visible,\n // re-apply the class when the user switches back to the tab.\n if (hadFocusVisibleRecently) {\n hadKeyboardEvent = true;\n }\n }\n}\nfunction prepare(doc) {\n doc.addEventListener('keydown', handleKeyDown, true);\n doc.addEventListener('mousedown', handlePointerDown, true);\n doc.addEventListener('pointerdown', handlePointerDown, true);\n doc.addEventListener('touchstart', handlePointerDown, true);\n doc.addEventListener('visibilitychange', handleVisibilityChange, true);\n}\nexport function teardown(doc) {\n doc.removeEventListener('keydown', handleKeyDown, true);\n doc.removeEventListener('mousedown', handlePointerDown, true);\n doc.removeEventListener('pointerdown', handlePointerDown, true);\n doc.removeEventListener('touchstart', handlePointerDown, true);\n doc.removeEventListener('visibilitychange', handleVisibilityChange, true);\n}\nfunction isFocusVisible(event) {\n const {\n target\n } = event;\n try {\n return target.matches(':focus-visible');\n } catch (error) {\n // Browsers not implementing :focus-visible will throw a SyntaxError.\n // We use our own heuristic for those browsers.\n // Rethrow might be better if it's not the expected error but do we really\n // want to crash if focus-visible malfunctioned?\n }\n\n // No need for validFocusTarget check. The user does that by attaching it to\n // focusable events only.\n return hadKeyboardEvent || focusTriggersKeyboardModality(target);\n}\nexport default function useIsFocusVisible() {\n const ref = React.useCallback(node => {\n if (node != null) {\n prepare(node.ownerDocument);\n }\n }, []);\n const isFocusVisibleRef = React.useRef(false);\n\n /**\n * Should be called if a blur event is fired\n */\n function handleBlurVisible() {\n // checking against potential state variable does not suffice if we focus and blur synchronously.\n // React wouldn't have time to trigger a re-render so `focusVisible` would be stale.\n // Ideally we would adjust `isFocusVisible(event)` to look at `relatedTarget` for blur events.\n // This doesn't work in IE11 due to https://github.com/facebook/react/issues/3751\n // TODO: check again if React releases their internal changes to focus event handling (https://github.com/facebook/react/pull/19186).\n if (isFocusVisibleRef.current) {\n // To detect a tab/window switch, we look for a blur event followed\n // rapidly by a visibility change.\n // If we don't see a visibility change within 100ms, it's probably a\n // regular focus change.\n hadFocusVisibleRecently = true;\n hadFocusVisibleRecentlyTimeout.start(100, () => {\n hadFocusVisibleRecently = false;\n });\n isFocusVisibleRef.current = false;\n return true;\n }\n return false;\n }\n\n /**\n * Should be called if a blur event is fired\n */\n function handleFocusVisible(event) {\n if (isFocusVisible(event)) {\n isFocusVisibleRef.current = true;\n return true;\n }\n return false;\n }\n return {\n isFocusVisibleRef,\n onFocus: handleFocusVisible,\n onBlur: handleBlurVisible,\n ref\n };\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\n/**\n * Add keys, values of `defaultProps` that does not exist in `props`\n * @param {object} defaultProps\n * @param {object} props\n * @returns {object} resolved props\n */\nexport default function resolveProps(defaultProps, props) {\n const output = _extends({}, props);\n Object.keys(defaultProps).forEach(propName => {\n if (propName.toString().match(/^(components|slots)$/)) {\n output[propName] = _extends({}, defaultProps[propName], output[propName]);\n } else if (propName.toString().match(/^(componentsProps|slotProps)$/)) {\n const defaultSlotProps = defaultProps[propName] || {};\n const slotProps = props[propName];\n output[propName] = {};\n if (!slotProps || !Object.keys(slotProps)) {\n // Reduce the iteration if the slot props is empty\n output[propName] = defaultSlotProps;\n } else if (!defaultSlotProps || !Object.keys(defaultSlotProps)) {\n // Reduce the iteration if the default slot props is empty\n output[propName] = slotProps;\n } else {\n output[propName] = _extends({}, slotProps);\n Object.keys(defaultSlotProps).forEach(slotPropName => {\n output[propName][slotPropName] = resolveProps(defaultSlotProps[slotPropName], slotProps[slotPropName]);\n });\n }\n } else if (output[propName] === undefined) {\n output[propName] = defaultProps[propName];\n }\n });\n return output;\n}","export default function composeClasses(slots, getUtilityClass, classes = undefined) {\n const output = {};\n Object.keys(slots).forEach(\n // `Object.keys(slots)` can't be wider than `T` because we infer `T` from `slots`.\n // @ts-expect-error https://github.com/microsoft/TypeScript/pull/12253#issuecomment-263132208\n slot => {\n output[slot] = slots[slot].reduce((acc, key) => {\n if (key) {\n const utilityClass = getUtilityClass(key);\n if (utilityClass !== '') {\n acc.push(utilityClass);\n }\n if (classes && classes[key]) {\n acc.push(classes[key]);\n }\n }\n return acc;\n }, []).join(' ');\n });\n return output;\n}","const defaultGenerator = componentName => componentName;\nconst createClassNameGenerator = () => {\n let generate = defaultGenerator;\n return {\n configure(generator) {\n generate = generator;\n },\n generate(componentName) {\n return generate(componentName);\n },\n reset() {\n generate = defaultGenerator;\n }\n };\n};\nconst ClassNameGenerator = createClassNameGenerator();\nexport default ClassNameGenerator;","import ClassNameGenerator from '../ClassNameGenerator';\nexport const globalStateClasses = {\n active: 'active',\n checked: 'checked',\n completed: 'completed',\n disabled: 'disabled',\n error: 'error',\n expanded: 'expanded',\n focused: 'focused',\n focusVisible: 'focusVisible',\n open: 'open',\n readOnly: 'readOnly',\n required: 'required',\n selected: 'selected'\n};\nexport default function generateUtilityClass(componentName, slot, globalStatePrefix = 'Mui') {\n const globalStateClass = globalStateClasses[slot];\n return globalStateClass ? `${globalStatePrefix}-${globalStateClass}` : `${ClassNameGenerator.generate(componentName)}-${slot}`;\n}\nexport function isGlobalState(slot) {\n return globalStateClasses[slot] !== undefined;\n}","import generateUtilityClass from '../generateUtilityClass';\nexport default function generateUtilityClasses(componentName, slots, globalStatePrefix = 'Mui') {\n const result = {};\n slots.forEach(slot => {\n result[slot] = generateUtilityClass(componentName, slot, globalStatePrefix);\n });\n return result;\n}","function clamp(val, min = Number.MIN_SAFE_INTEGER, max = Number.MAX_SAFE_INTEGER) {\n return Math.max(min, Math.min(val, max));\n}\nexport default clamp;","export default function _objectWithoutPropertiesLoose(source, excluded) {\n if (source == null) return {};\n var target = {};\n var sourceKeys = Object.keys(source);\n var key, i;\n for (i = 0; i < sourceKeys.length; i++) {\n key = sourceKeys[i];\n if (excluded.indexOf(key) >= 0) continue;\n target[key] = source[key];\n }\n return target;\n}","import _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nconst _excluded = [\"values\", \"unit\", \"step\"];\n// Sorted ASC by size. That's important.\n// It can't be configured as it's used statically for propTypes.\nexport const breakpointKeys = ['xs', 'sm', 'md', 'lg', 'xl'];\nconst sortBreakpointsValues = values => {\n const breakpointsAsArray = Object.keys(values).map(key => ({\n key,\n val: values[key]\n })) || [];\n // Sort in ascending order\n breakpointsAsArray.sort((breakpoint1, breakpoint2) => breakpoint1.val - breakpoint2.val);\n return breakpointsAsArray.reduce((acc, obj) => {\n return _extends({}, acc, {\n [obj.key]: obj.val\n });\n }, {});\n};\n\n// Keep in mind that @media is inclusive by the CSS specification.\nexport default function createBreakpoints(breakpoints) {\n const {\n // The breakpoint **start** at this value.\n // For instance with the first breakpoint xs: [xs, sm).\n values = {\n xs: 0,\n // phone\n sm: 600,\n // tablet\n md: 900,\n // small laptop\n lg: 1200,\n // desktop\n xl: 1536 // large screen\n },\n unit = 'px',\n step = 5\n } = breakpoints,\n other = _objectWithoutPropertiesLoose(breakpoints, _excluded);\n const sortedValues = sortBreakpointsValues(values);\n const keys = Object.keys(sortedValues);\n function up(key) {\n const value = typeof values[key] === 'number' ? values[key] : key;\n return `@media (min-width:${value}${unit})`;\n }\n function down(key) {\n const value = typeof values[key] === 'number' ? values[key] : key;\n return `@media (max-width:${value - step / 100}${unit})`;\n }\n function between(start, end) {\n const endIndex = keys.indexOf(end);\n return `@media (min-width:${typeof values[start] === 'number' ? values[start] : start}${unit}) and ` + `(max-width:${(endIndex !== -1 && typeof values[keys[endIndex]] === 'number' ? values[keys[endIndex]] : end) - step / 100}${unit})`;\n }\n function only(key) {\n if (keys.indexOf(key) + 1 < keys.length) {\n return between(key, keys[keys.indexOf(key) + 1]);\n }\n return up(key);\n }\n function not(key) {\n // handle first and last key separately, for better readability\n const keyIndex = keys.indexOf(key);\n if (keyIndex === 0) {\n return up(keys[1]);\n }\n if (keyIndex === keys.length - 1) {\n return down(keys[keyIndex]);\n }\n return between(key, keys[keys.indexOf(key) + 1]).replace('@media', '@media not all and');\n }\n return _extends({\n keys,\n values: sortedValues,\n up,\n down,\n between,\n only,\n not,\n unit\n }, other);\n}","const shape = {\n borderRadius: 4\n};\nexport default shape;","import PropTypes from 'prop-types';\nconst responsivePropType = process.env.NODE_ENV !== 'production' ? PropTypes.oneOfType([PropTypes.number, PropTypes.string, PropTypes.object, PropTypes.array]) : {};\nexport default responsivePropType;","import deepmerge from '@mui/utils/deepmerge';\nfunction merge(acc, item) {\n if (!item) {\n return acc;\n }\n return deepmerge(acc, item, {\n clone: false // No need to clone deep, it's way faster.\n });\n}\nexport default merge;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport PropTypes from 'prop-types';\nimport deepmerge from '@mui/utils/deepmerge';\nimport merge from './merge';\n\n// The breakpoint **start** at this value.\n// For instance with the first breakpoint xs: [xs, sm[.\nexport const values = {\n xs: 0,\n // phone\n sm: 600,\n // tablet\n md: 900,\n // small laptop\n lg: 1200,\n // desktop\n xl: 1536 // large screen\n};\nconst defaultBreakpoints = {\n // Sorted ASC by size. That's important.\n // It can't be configured as it's used statically for propTypes.\n keys: ['xs', 'sm', 'md', 'lg', 'xl'],\n up: key => `@media (min-width:${values[key]}px)`\n};\nexport function handleBreakpoints(props, propValue, styleFromPropValue) {\n const theme = props.theme || {};\n if (Array.isArray(propValue)) {\n const themeBreakpoints = theme.breakpoints || defaultBreakpoints;\n return propValue.reduce((acc, item, index) => {\n acc[themeBreakpoints.up(themeBreakpoints.keys[index])] = styleFromPropValue(propValue[index]);\n return acc;\n }, {});\n }\n if (typeof propValue === 'object') {\n const themeBreakpoints = theme.breakpoints || defaultBreakpoints;\n return Object.keys(propValue).reduce((acc, breakpoint) => {\n // key is breakpoint\n if (Object.keys(themeBreakpoints.values || values).indexOf(breakpoint) !== -1) {\n const mediaKey = themeBreakpoints.up(breakpoint);\n acc[mediaKey] = styleFromPropValue(propValue[breakpoint], breakpoint);\n } else {\n const cssKey = breakpoint;\n acc[cssKey] = propValue[cssKey];\n }\n return acc;\n }, {});\n }\n const output = styleFromPropValue(propValue);\n return output;\n}\nfunction breakpoints(styleFunction) {\n // false positive\n // eslint-disable-next-line react/function-component-definition\n const newStyleFunction = props => {\n const theme = props.theme || {};\n const base = styleFunction(props);\n const themeBreakpoints = theme.breakpoints || defaultBreakpoints;\n const extended = themeBreakpoints.keys.reduce((acc, key) => {\n if (props[key]) {\n acc = acc || {};\n acc[themeBreakpoints.up(key)] = styleFunction(_extends({\n theme\n }, props[key]));\n }\n return acc;\n }, null);\n return merge(base, extended);\n };\n newStyleFunction.propTypes = process.env.NODE_ENV !== 'production' ? _extends({}, styleFunction.propTypes, {\n xs: PropTypes.object,\n sm: PropTypes.object,\n md: PropTypes.object,\n lg: PropTypes.object,\n xl: PropTypes.object\n }) : {};\n newStyleFunction.filterProps = ['xs', 'sm', 'md', 'lg', 'xl', ...styleFunction.filterProps];\n return newStyleFunction;\n}\nexport function createEmptyBreakpointObject(breakpointsInput = {}) {\n var _breakpointsInput$key;\n const breakpointsInOrder = (_breakpointsInput$key = breakpointsInput.keys) == null ? void 0 : _breakpointsInput$key.reduce((acc, key) => {\n const breakpointStyleKey = breakpointsInput.up(key);\n acc[breakpointStyleKey] = {};\n return acc;\n }, {});\n return breakpointsInOrder || {};\n}\nexport function removeUnusedBreakpoints(breakpointKeys, style) {\n return breakpointKeys.reduce((acc, key) => {\n const breakpointOutput = acc[key];\n const isBreakpointUnused = !breakpointOutput || Object.keys(breakpointOutput).length === 0;\n if (isBreakpointUnused) {\n delete acc[key];\n }\n return acc;\n }, style);\n}\nexport function mergeBreakpointsInOrder(breakpointsInput, ...styles) {\n const emptyBreakpoints = createEmptyBreakpointObject(breakpointsInput);\n const mergedOutput = [emptyBreakpoints, ...styles].reduce((prev, next) => deepmerge(prev, next), {});\n return removeUnusedBreakpoints(Object.keys(emptyBreakpoints), mergedOutput);\n}\n\n// compute base for responsive values; e.g.,\n// [1,2,3] => {xs: true, sm: true, md: true}\n// {xs: 1, sm: 2, md: 3} => {xs: true, sm: true, md: true}\nexport function computeBreakpointsBase(breakpointValues, themeBreakpoints) {\n // fixed value\n if (typeof breakpointValues !== 'object') {\n return {};\n }\n const base = {};\n const breakpointsKeys = Object.keys(themeBreakpoints);\n if (Array.isArray(breakpointValues)) {\n breakpointsKeys.forEach((breakpoint, i) => {\n if (i < breakpointValues.length) {\n base[breakpoint] = true;\n }\n });\n } else {\n breakpointsKeys.forEach(breakpoint => {\n if (breakpointValues[breakpoint] != null) {\n base[breakpoint] = true;\n }\n });\n }\n return base;\n}\nexport function resolveBreakpointValues({\n values: breakpointValues,\n breakpoints: themeBreakpoints,\n base: customBase\n}) {\n const base = customBase || computeBreakpointsBase(breakpointValues, themeBreakpoints);\n const keys = Object.keys(base);\n if (keys.length === 0) {\n return breakpointValues;\n }\n let previous;\n return keys.reduce((acc, breakpoint, i) => {\n if (Array.isArray(breakpointValues)) {\n acc[breakpoint] = breakpointValues[i] != null ? breakpointValues[i] : breakpointValues[previous];\n previous = i;\n } else if (typeof breakpointValues === 'object') {\n acc[breakpoint] = breakpointValues[breakpoint] != null ? breakpointValues[breakpoint] : breakpointValues[previous];\n previous = breakpoint;\n } else {\n acc[breakpoint] = breakpointValues;\n }\n return acc;\n }, {});\n}\nexport default breakpoints;","import capitalize from '@mui/utils/capitalize';\nimport responsivePropType from './responsivePropType';\nimport { handleBreakpoints } from './breakpoints';\nexport function getPath(obj, path, checkVars = true) {\n if (!path || typeof path !== 'string') {\n return null;\n }\n\n // Check if CSS variables are used\n if (obj && obj.vars && checkVars) {\n const val = `vars.${path}`.split('.').reduce((acc, item) => acc && acc[item] ? acc[item] : null, obj);\n if (val != null) {\n return val;\n }\n }\n return path.split('.').reduce((acc, item) => {\n if (acc && acc[item] != null) {\n return acc[item];\n }\n return null;\n }, obj);\n}\nexport function getStyleValue(themeMapping, transform, propValueFinal, userValue = propValueFinal) {\n let value;\n if (typeof themeMapping === 'function') {\n value = themeMapping(propValueFinal);\n } else if (Array.isArray(themeMapping)) {\n value = themeMapping[propValueFinal] || userValue;\n } else {\n value = getPath(themeMapping, propValueFinal) || userValue;\n }\n if (transform) {\n value = transform(value, userValue, themeMapping);\n }\n return value;\n}\nfunction style(options) {\n const {\n prop,\n cssProperty = options.prop,\n themeKey,\n transform\n } = options;\n\n // false positive\n // eslint-disable-next-line react/function-component-definition\n const fn = props => {\n if (props[prop] == null) {\n return null;\n }\n const propValue = props[prop];\n const theme = props.theme;\n const themeMapping = getPath(theme, themeKey) || {};\n const styleFromPropValue = propValueFinal => {\n let value = getStyleValue(themeMapping, transform, propValueFinal);\n if (propValueFinal === value && typeof propValueFinal === 'string') {\n // Haven't found value\n value = getStyleValue(themeMapping, transform, `${prop}${propValueFinal === 'default' ? '' : capitalize(propValueFinal)}`, propValueFinal);\n }\n if (cssProperty === false) {\n return value;\n }\n return {\n [cssProperty]: value\n };\n };\n return handleBreakpoints(props, propValue, styleFromPropValue);\n };\n fn.propTypes = process.env.NODE_ENV !== 'production' ? {\n [prop]: responsivePropType\n } : {};\n fn.filterProps = [prop];\n return fn;\n}\nexport default style;","export default function memoize(fn) {\n const cache = {};\n return arg => {\n if (cache[arg] === undefined) {\n cache[arg] = fn(arg);\n }\n return cache[arg];\n };\n}","import responsivePropType from './responsivePropType';\nimport { handleBreakpoints } from './breakpoints';\nimport { getPath } from './style';\nimport merge from './merge';\nimport memoize from './memoize';\nconst properties = {\n m: 'margin',\n p: 'padding'\n};\nconst directions = {\n t: 'Top',\n r: 'Right',\n b: 'Bottom',\n l: 'Left',\n x: ['Left', 'Right'],\n y: ['Top', 'Bottom']\n};\nconst aliases = {\n marginX: 'mx',\n marginY: 'my',\n paddingX: 'px',\n paddingY: 'py'\n};\n\n// memoize() impact:\n// From 300,000 ops/sec\n// To 350,000 ops/sec\nconst getCssProperties = memoize(prop => {\n // It's not a shorthand notation.\n if (prop.length > 2) {\n if (aliases[prop]) {\n prop = aliases[prop];\n } else {\n return [prop];\n }\n }\n const [a, b] = prop.split('');\n const property = properties[a];\n const direction = directions[b] || '';\n return Array.isArray(direction) ? direction.map(dir => property + dir) : [property + direction];\n});\nexport const marginKeys = ['m', 'mt', 'mr', 'mb', 'ml', 'mx', 'my', 'margin', 'marginTop', 'marginRight', 'marginBottom', 'marginLeft', 'marginX', 'marginY', 'marginInline', 'marginInlineStart', 'marginInlineEnd', 'marginBlock', 'marginBlockStart', 'marginBlockEnd'];\nexport const paddingKeys = ['p', 'pt', 'pr', 'pb', 'pl', 'px', 'py', 'padding', 'paddingTop', 'paddingRight', 'paddingBottom', 'paddingLeft', 'paddingX', 'paddingY', 'paddingInline', 'paddingInlineStart', 'paddingInlineEnd', 'paddingBlock', 'paddingBlockStart', 'paddingBlockEnd'];\nconst spacingKeys = [...marginKeys, ...paddingKeys];\nexport function createUnaryUnit(theme, themeKey, defaultValue, propName) {\n var _getPath;\n const themeSpacing = (_getPath = getPath(theme, themeKey, false)) != null ? _getPath : defaultValue;\n if (typeof themeSpacing === 'number') {\n return abs => {\n if (typeof abs === 'string') {\n return abs;\n }\n if (process.env.NODE_ENV !== 'production') {\n if (typeof abs !== 'number') {\n console.error(`MUI: Expected ${propName} argument to be a number or a string, got ${abs}.`);\n }\n }\n return themeSpacing * abs;\n };\n }\n if (Array.isArray(themeSpacing)) {\n return abs => {\n if (typeof abs === 'string') {\n return abs;\n }\n if (process.env.NODE_ENV !== 'production') {\n if (!Number.isInteger(abs)) {\n console.error([`MUI: The \\`theme.${themeKey}\\` array type cannot be combined with non integer values.` + `You should either use an integer value that can be used as index, or define the \\`theme.${themeKey}\\` as a number.`].join('\\n'));\n } else if (abs > themeSpacing.length - 1) {\n console.error([`MUI: The value provided (${abs}) overflows.`, `The supported values are: ${JSON.stringify(themeSpacing)}.`, `${abs} > ${themeSpacing.length - 1}, you need to add the missing values.`].join('\\n'));\n }\n }\n return themeSpacing[abs];\n };\n }\n if (typeof themeSpacing === 'function') {\n return themeSpacing;\n }\n if (process.env.NODE_ENV !== 'production') {\n console.error([`MUI: The \\`theme.${themeKey}\\` value (${themeSpacing}) is invalid.`, 'It should be a number, an array or a function.'].join('\\n'));\n }\n return () => undefined;\n}\nexport function createUnarySpacing(theme) {\n return createUnaryUnit(theme, 'spacing', 8, 'spacing');\n}\nexport function getValue(transformer, propValue) {\n if (typeof propValue === 'string' || propValue == null) {\n return propValue;\n }\n const abs = Math.abs(propValue);\n const transformed = transformer(abs);\n if (propValue >= 0) {\n return transformed;\n }\n if (typeof transformed === 'number') {\n return -transformed;\n }\n return `-${transformed}`;\n}\nexport function getStyleFromPropValue(cssProperties, transformer) {\n return propValue => cssProperties.reduce((acc, cssProperty) => {\n acc[cssProperty] = getValue(transformer, propValue);\n return acc;\n }, {});\n}\nfunction resolveCssProperty(props, keys, prop, transformer) {\n // Using a hash computation over an array iteration could be faster, but with only 28 items,\n // it's doesn't worth the bundle size.\n if (keys.indexOf(prop) === -1) {\n return null;\n }\n const cssProperties = getCssProperties(prop);\n const styleFromPropValue = getStyleFromPropValue(cssProperties, transformer);\n const propValue = props[prop];\n return handleBreakpoints(props, propValue, styleFromPropValue);\n}\nfunction style(props, keys) {\n const transformer = createUnarySpacing(props.theme);\n return Object.keys(props).map(prop => resolveCssProperty(props, keys, prop, transformer)).reduce(merge, {});\n}\nexport function margin(props) {\n return style(props, marginKeys);\n}\nmargin.propTypes = process.env.NODE_ENV !== 'production' ? marginKeys.reduce((obj, key) => {\n obj[key] = responsivePropType;\n return obj;\n}, {}) : {};\nmargin.filterProps = marginKeys;\nexport function padding(props) {\n return style(props, paddingKeys);\n}\npadding.propTypes = process.env.NODE_ENV !== 'production' ? paddingKeys.reduce((obj, key) => {\n obj[key] = responsivePropType;\n return obj;\n}, {}) : {};\npadding.filterProps = paddingKeys;\nfunction spacing(props) {\n return style(props, spacingKeys);\n}\nspacing.propTypes = process.env.NODE_ENV !== 'production' ? spacingKeys.reduce((obj, key) => {\n obj[key] = responsivePropType;\n return obj;\n}, {}) : {};\nspacing.filterProps = spacingKeys;\nexport default spacing;","import { createUnarySpacing } from '../spacing';\n\n// The different signatures imply different meaning for their arguments that can't be expressed structurally.\n// We express the difference with variable names.\n\nexport default function createSpacing(spacingInput = 8) {\n // Already transformed.\n if (spacingInput.mui) {\n return spacingInput;\n }\n\n // Material Design layouts are visually balanced. Most measurements align to an 8dp grid, which aligns both spacing and the overall layout.\n // Smaller components, such as icons, can align to a 4dp grid.\n // https://m2.material.io/design/layout/understanding-layout.html\n const transform = createUnarySpacing({\n spacing: spacingInput\n });\n const spacing = (...argsInput) => {\n if (process.env.NODE_ENV !== 'production') {\n if (!(argsInput.length <= 4)) {\n console.error(`MUI: Too many arguments provided, expected between 0 and 4, got ${argsInput.length}`);\n }\n }\n const args = argsInput.length === 0 ? [1] : argsInput;\n return args.map(argument => {\n const output = transform(argument);\n return typeof output === 'number' ? `${output}px` : output;\n }).join(' ');\n };\n spacing.mui = true;\n return spacing;\n}","import merge from './merge';\nfunction compose(...styles) {\n const handlers = styles.reduce((acc, style) => {\n style.filterProps.forEach(prop => {\n acc[prop] = style;\n });\n return acc;\n }, {});\n\n // false positive\n // eslint-disable-next-line react/function-component-definition\n const fn = props => {\n return Object.keys(props).reduce((acc, prop) => {\n if (handlers[prop]) {\n return merge(acc, handlers[prop](props));\n }\n return acc;\n }, {});\n };\n fn.propTypes = process.env.NODE_ENV !== 'production' ? styles.reduce((acc, style) => Object.assign(acc, style.propTypes), {}) : {};\n fn.filterProps = styles.reduce((acc, style) => acc.concat(style.filterProps), []);\n return fn;\n}\nexport default compose;","import responsivePropType from './responsivePropType';\nimport style from './style';\nimport compose from './compose';\nimport { createUnaryUnit, getValue } from './spacing';\nimport { handleBreakpoints } from './breakpoints';\nexport function borderTransform(value) {\n if (typeof value !== 'number') {\n return value;\n }\n return `${value}px solid`;\n}\nfunction createBorderStyle(prop, transform) {\n return style({\n prop,\n themeKey: 'borders',\n transform\n });\n}\nexport const border = createBorderStyle('border', borderTransform);\nexport const borderTop = createBorderStyle('borderTop', borderTransform);\nexport const borderRight = createBorderStyle('borderRight', borderTransform);\nexport const borderBottom = createBorderStyle('borderBottom', borderTransform);\nexport const borderLeft = createBorderStyle('borderLeft', borderTransform);\nexport const borderColor = createBorderStyle('borderColor');\nexport const borderTopColor = createBorderStyle('borderTopColor');\nexport const borderRightColor = createBorderStyle('borderRightColor');\nexport const borderBottomColor = createBorderStyle('borderBottomColor');\nexport const borderLeftColor = createBorderStyle('borderLeftColor');\nexport const outline = createBorderStyle('outline', borderTransform);\nexport const outlineColor = createBorderStyle('outlineColor');\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const borderRadius = props => {\n if (props.borderRadius !== undefined && props.borderRadius !== null) {\n const transformer = createUnaryUnit(props.theme, 'shape.borderRadius', 4, 'borderRadius');\n const styleFromPropValue = propValue => ({\n borderRadius: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.borderRadius, styleFromPropValue);\n }\n return null;\n};\nborderRadius.propTypes = process.env.NODE_ENV !== 'production' ? {\n borderRadius: responsivePropType\n} : {};\nborderRadius.filterProps = ['borderRadius'];\nconst borders = compose(border, borderTop, borderRight, borderBottom, borderLeft, borderColor, borderTopColor, borderRightColor, borderBottomColor, borderLeftColor, borderRadius, outline, outlineColor);\nexport default borders;","import style from './style';\nimport compose from './compose';\nimport { createUnaryUnit, getValue } from './spacing';\nimport { handleBreakpoints } from './breakpoints';\nimport responsivePropType from './responsivePropType';\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const gap = props => {\n if (props.gap !== undefined && props.gap !== null) {\n const transformer = createUnaryUnit(props.theme, 'spacing', 8, 'gap');\n const styleFromPropValue = propValue => ({\n gap: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.gap, styleFromPropValue);\n }\n return null;\n};\ngap.propTypes = process.env.NODE_ENV !== 'production' ? {\n gap: responsivePropType\n} : {};\ngap.filterProps = ['gap'];\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const columnGap = props => {\n if (props.columnGap !== undefined && props.columnGap !== null) {\n const transformer = createUnaryUnit(props.theme, 'spacing', 8, 'columnGap');\n const styleFromPropValue = propValue => ({\n columnGap: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.columnGap, styleFromPropValue);\n }\n return null;\n};\ncolumnGap.propTypes = process.env.NODE_ENV !== 'production' ? {\n columnGap: responsivePropType\n} : {};\ncolumnGap.filterProps = ['columnGap'];\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const rowGap = props => {\n if (props.rowGap !== undefined && props.rowGap !== null) {\n const transformer = createUnaryUnit(props.theme, 'spacing', 8, 'rowGap');\n const styleFromPropValue = propValue => ({\n rowGap: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.rowGap, styleFromPropValue);\n }\n return null;\n};\nrowGap.propTypes = process.env.NODE_ENV !== 'production' ? {\n rowGap: responsivePropType\n} : {};\nrowGap.filterProps = ['rowGap'];\nexport const gridColumn = style({\n prop: 'gridColumn'\n});\nexport const gridRow = style({\n prop: 'gridRow'\n});\nexport const gridAutoFlow = style({\n prop: 'gridAutoFlow'\n});\nexport const gridAutoColumns = style({\n prop: 'gridAutoColumns'\n});\nexport const gridAutoRows = style({\n prop: 'gridAutoRows'\n});\nexport const gridTemplateColumns = style({\n prop: 'gridTemplateColumns'\n});\nexport const gridTemplateRows = style({\n prop: 'gridTemplateRows'\n});\nexport const gridTemplateAreas = style({\n prop: 'gridTemplateAreas'\n});\nexport const gridArea = style({\n prop: 'gridArea'\n});\nconst grid = compose(gap, columnGap, rowGap, gridColumn, gridRow, gridAutoFlow, gridAutoColumns, gridAutoRows, gridTemplateColumns, gridTemplateRows, gridTemplateAreas, gridArea);\nexport default grid;","import style from './style';\nimport compose from './compose';\nexport function paletteTransform(value, userValue) {\n if (userValue === 'grey') {\n return userValue;\n }\n return value;\n}\nexport const color = style({\n prop: 'color',\n themeKey: 'palette',\n transform: paletteTransform\n});\nexport const bgcolor = style({\n prop: 'bgcolor',\n cssProperty: 'backgroundColor',\n themeKey: 'palette',\n transform: paletteTransform\n});\nexport const backgroundColor = style({\n prop: 'backgroundColor',\n themeKey: 'palette',\n transform: paletteTransform\n});\nconst palette = compose(color, bgcolor, backgroundColor);\nexport default palette;","import style from './style';\nimport compose from './compose';\nimport { handleBreakpoints, values as breakpointsValues } from './breakpoints';\nexport function sizingTransform(value) {\n return value <= 1 && value !== 0 ? `${value * 100}%` : value;\n}\nexport const width = style({\n prop: 'width',\n transform: sizingTransform\n});\nexport const maxWidth = props => {\n if (props.maxWidth !== undefined && props.maxWidth !== null) {\n const styleFromPropValue = propValue => {\n var _props$theme, _props$theme2;\n const breakpoint = ((_props$theme = props.theme) == null || (_props$theme = _props$theme.breakpoints) == null || (_props$theme = _props$theme.values) == null ? void 0 : _props$theme[propValue]) || breakpointsValues[propValue];\n if (!breakpoint) {\n return {\n maxWidth: sizingTransform(propValue)\n };\n }\n if (((_props$theme2 = props.theme) == null || (_props$theme2 = _props$theme2.breakpoints) == null ? void 0 : _props$theme2.unit) !== 'px') {\n return {\n maxWidth: `${breakpoint}${props.theme.breakpoints.unit}`\n };\n }\n return {\n maxWidth: breakpoint\n };\n };\n return handleBreakpoints(props, props.maxWidth, styleFromPropValue);\n }\n return null;\n};\nmaxWidth.filterProps = ['maxWidth'];\nexport const minWidth = style({\n prop: 'minWidth',\n transform: sizingTransform\n});\nexport const height = style({\n prop: 'height',\n transform: sizingTransform\n});\nexport const maxHeight = style({\n prop: 'maxHeight',\n transform: sizingTransform\n});\nexport const minHeight = style({\n prop: 'minHeight',\n transform: sizingTransform\n});\nexport const sizeWidth = style({\n prop: 'size',\n cssProperty: 'width',\n transform: sizingTransform\n});\nexport const sizeHeight = style({\n prop: 'size',\n cssProperty: 'height',\n transform: sizingTransform\n});\nexport const boxSizing = style({\n prop: 'boxSizing'\n});\nconst sizing = compose(width, maxWidth, minWidth, height, maxHeight, minHeight, boxSizing);\nexport default sizing;","import { padding, margin } from '../spacing';\nimport { borderRadius, borderTransform } from '../borders';\nimport { gap, rowGap, columnGap } from '../cssGrid';\nimport { paletteTransform } from '../palette';\nimport { maxWidth, sizingTransform } from '../sizing';\nconst defaultSxConfig = {\n // borders\n border: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderTop: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderRight: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderBottom: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderLeft: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderColor: {\n themeKey: 'palette'\n },\n borderTopColor: {\n themeKey: 'palette'\n },\n borderRightColor: {\n themeKey: 'palette'\n },\n borderBottomColor: {\n themeKey: 'palette'\n },\n borderLeftColor: {\n themeKey: 'palette'\n },\n outline: {\n themeKey: 'borders',\n transform: borderTransform\n },\n outlineColor: {\n themeKey: 'palette'\n },\n borderRadius: {\n themeKey: 'shape.borderRadius',\n style: borderRadius\n },\n // palette\n color: {\n themeKey: 'palette',\n transform: paletteTransform\n },\n bgcolor: {\n themeKey: 'palette',\n cssProperty: 'backgroundColor',\n transform: paletteTransform\n },\n backgroundColor: {\n themeKey: 'palette',\n transform: paletteTransform\n },\n // spacing\n p: {\n style: padding\n },\n pt: {\n style: padding\n },\n pr: {\n style: padding\n },\n pb: {\n style: padding\n },\n pl: {\n style: padding\n },\n px: {\n style: padding\n },\n py: {\n style: padding\n },\n padding: {\n style: padding\n },\n paddingTop: {\n style: padding\n },\n paddingRight: {\n style: padding\n },\n paddingBottom: {\n style: padding\n },\n paddingLeft: {\n style: padding\n },\n paddingX: {\n style: padding\n },\n paddingY: {\n style: padding\n },\n paddingInline: {\n style: padding\n },\n paddingInlineStart: {\n style: padding\n },\n paddingInlineEnd: {\n style: padding\n },\n paddingBlock: {\n style: padding\n },\n paddingBlockStart: {\n style: padding\n },\n paddingBlockEnd: {\n style: padding\n },\n m: {\n style: margin\n },\n mt: {\n style: margin\n },\n mr: {\n style: margin\n },\n mb: {\n style: margin\n },\n ml: {\n style: margin\n },\n mx: {\n style: margin\n },\n my: {\n style: margin\n },\n margin: {\n style: margin\n },\n marginTop: {\n style: margin\n },\n marginRight: {\n style: margin\n },\n marginBottom: {\n style: margin\n },\n marginLeft: {\n style: margin\n },\n marginX: {\n style: margin\n },\n marginY: {\n style: margin\n },\n marginInline: {\n style: margin\n },\n marginInlineStart: {\n style: margin\n },\n marginInlineEnd: {\n style: margin\n },\n marginBlock: {\n style: margin\n },\n marginBlockStart: {\n style: margin\n },\n marginBlockEnd: {\n style: margin\n },\n // display\n displayPrint: {\n cssProperty: false,\n transform: value => ({\n '@media print': {\n display: value\n }\n })\n },\n display: {},\n overflow: {},\n textOverflow: {},\n visibility: {},\n whiteSpace: {},\n // flexbox\n flexBasis: {},\n flexDirection: {},\n flexWrap: {},\n justifyContent: {},\n alignItems: {},\n alignContent: {},\n order: {},\n flex: {},\n flexGrow: {},\n flexShrink: {},\n alignSelf: {},\n justifyItems: {},\n justifySelf: {},\n // grid\n gap: {\n style: gap\n },\n rowGap: {\n style: rowGap\n },\n columnGap: {\n style: columnGap\n },\n gridColumn: {},\n gridRow: {},\n gridAutoFlow: {},\n gridAutoColumns: {},\n gridAutoRows: {},\n gridTemplateColumns: {},\n gridTemplateRows: {},\n gridTemplateAreas: {},\n gridArea: {},\n // positions\n position: {},\n zIndex: {\n themeKey: 'zIndex'\n },\n top: {},\n right: {},\n bottom: {},\n left: {},\n // shadows\n boxShadow: {\n themeKey: 'shadows'\n },\n // sizing\n width: {\n transform: sizingTransform\n },\n maxWidth: {\n style: maxWidth\n },\n minWidth: {\n transform: sizingTransform\n },\n height: {\n transform: sizingTransform\n },\n maxHeight: {\n transform: sizingTransform\n },\n minHeight: {\n transform: sizingTransform\n },\n boxSizing: {},\n // typography\n fontFamily: {\n themeKey: 'typography'\n },\n fontSize: {\n themeKey: 'typography'\n },\n fontStyle: {\n themeKey: 'typography'\n },\n fontWeight: {\n themeKey: 'typography'\n },\n letterSpacing: {},\n textTransform: {},\n lineHeight: {},\n textAlign: {},\n typography: {\n cssProperty: false,\n themeKey: 'typography'\n }\n};\nexport default defaultSxConfig;","import capitalize from '@mui/utils/capitalize';\nimport merge from '../merge';\nimport { getPath, getStyleValue as getValue } from '../style';\nimport { handleBreakpoints, createEmptyBreakpointObject, removeUnusedBreakpoints } from '../breakpoints';\nimport defaultSxConfig from './defaultSxConfig';\nfunction objectsHaveSameKeys(...objects) {\n const allKeys = objects.reduce((keys, object) => keys.concat(Object.keys(object)), []);\n const union = new Set(allKeys);\n return objects.every(object => union.size === Object.keys(object).length);\n}\nfunction callIfFn(maybeFn, arg) {\n return typeof maybeFn === 'function' ? maybeFn(arg) : maybeFn;\n}\n\n// eslint-disable-next-line @typescript-eslint/naming-convention\nexport function unstable_createStyleFunctionSx() {\n function getThemeValue(prop, val, theme, config) {\n const props = {\n [prop]: val,\n theme\n };\n const options = config[prop];\n if (!options) {\n return {\n [prop]: val\n };\n }\n const {\n cssProperty = prop,\n themeKey,\n transform,\n style\n } = options;\n if (val == null) {\n return null;\n }\n\n // TODO v6: remove, see https://github.com/mui/material-ui/pull/38123\n if (themeKey === 'typography' && val === 'inherit') {\n return {\n [prop]: val\n };\n }\n const themeMapping = getPath(theme, themeKey) || {};\n if (style) {\n return style(props);\n }\n const styleFromPropValue = propValueFinal => {\n let value = getValue(themeMapping, transform, propValueFinal);\n if (propValueFinal === value && typeof propValueFinal === 'string') {\n // Haven't found value\n value = getValue(themeMapping, transform, `${prop}${propValueFinal === 'default' ? '' : capitalize(propValueFinal)}`, propValueFinal);\n }\n if (cssProperty === false) {\n return value;\n }\n return {\n [cssProperty]: value\n };\n };\n return handleBreakpoints(props, val, styleFromPropValue);\n }\n function styleFunctionSx(props) {\n var _theme$unstable_sxCon;\n const {\n sx,\n theme = {}\n } = props || {};\n if (!sx) {\n return null; // Emotion & styled-components will neglect null\n }\n const config = (_theme$unstable_sxCon = theme.unstable_sxConfig) != null ? _theme$unstable_sxCon : defaultSxConfig;\n\n /*\n * Receive `sxInput` as object or callback\n * and then recursively check keys & values to create media query object styles.\n * (the result will be used in `styled`)\n */\n function traverse(sxInput) {\n let sxObject = sxInput;\n if (typeof sxInput === 'function') {\n sxObject = sxInput(theme);\n } else if (typeof sxInput !== 'object') {\n // value\n return sxInput;\n }\n if (!sxObject) {\n return null;\n }\n const emptyBreakpoints = createEmptyBreakpointObject(theme.breakpoints);\n const breakpointsKeys = Object.keys(emptyBreakpoints);\n let css = emptyBreakpoints;\n Object.keys(sxObject).forEach(styleKey => {\n const value = callIfFn(sxObject[styleKey], theme);\n if (value !== null && value !== undefined) {\n if (typeof value === 'object') {\n if (config[styleKey]) {\n css = merge(css, getThemeValue(styleKey, value, theme, config));\n } else {\n const breakpointsValues = handleBreakpoints({\n theme\n }, value, x => ({\n [styleKey]: x\n }));\n if (objectsHaveSameKeys(breakpointsValues, value)) {\n css[styleKey] = styleFunctionSx({\n sx: value,\n theme\n });\n } else {\n css = merge(css, breakpointsValues);\n }\n }\n } else {\n css = merge(css, getThemeValue(styleKey, value, theme, config));\n }\n }\n });\n return removeUnusedBreakpoints(breakpointsKeys, css);\n }\n return Array.isArray(sx) ? sx.map(traverse) : traverse(sx);\n }\n return styleFunctionSx;\n}\nconst styleFunctionSx = unstable_createStyleFunctionSx();\nstyleFunctionSx.filterProps = ['sx'];\nexport default styleFunctionSx;","/**\n * A universal utility to style components with multiple color modes. Always use it from the theme object.\n * It works with:\n * - [Basic theme](https://mui.com/material-ui/customization/dark-mode/)\n * - [CSS theme variables](https://mui.com/material-ui/experimental-api/css-theme-variables/overview/)\n * - Zero-runtime engine\n *\n * Tips: Use an array over object spread and place `theme.applyStyles()` last.\n *\n * ✅ [{ background: '#e5e5e5' }, theme.applyStyles('dark', { background: '#1c1c1c' })]\n *\n * 🚫 { background: '#e5e5e5', ...theme.applyStyles('dark', { background: '#1c1c1c' })}\n *\n * @example\n * 1. using with `styled`:\n * ```jsx\n * const Component = styled('div')(({ theme }) => [\n * { background: '#e5e5e5' },\n * theme.applyStyles('dark', {\n * background: '#1c1c1c',\n * color: '#fff',\n * }),\n * ]);\n * ```\n *\n * @example\n * 2. using with `sx` prop:\n * ```jsx\n * [\n * { background: '#e5e5e5' },\n * theme.applyStyles('dark', {\n * background: '#1c1c1c',\n * color: '#fff',\n * }),\n * ]}\n * />\n * ```\n *\n * @example\n * 3. theming a component:\n * ```jsx\n * extendTheme({\n * components: {\n * MuiButton: {\n * styleOverrides: {\n * root: ({ theme }) => [\n * { background: '#e5e5e5' },\n * theme.applyStyles('dark', {\n * background: '#1c1c1c',\n * color: '#fff',\n * }),\n * ],\n * },\n * }\n * }\n * })\n *```\n */\nexport default function applyStyles(key, styles) {\n // @ts-expect-error this is 'any' type\n const theme = this;\n if (theme.vars && typeof theme.getColorSchemeSelector === 'function') {\n // If CssVarsProvider is used as a provider,\n // returns '* :where([data-mui-color-scheme=\"light|dark\"]) &'\n const selector = theme.getColorSchemeSelector(key).replace(/(\\[[^\\]]+\\])/, '*:where($1)');\n return {\n [selector]: styles\n };\n }\n if (theme.palette.mode === key) {\n return styles;\n }\n return {};\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"breakpoints\", \"palette\", \"spacing\", \"shape\"];\nimport deepmerge from '@mui/utils/deepmerge';\nimport createBreakpoints from './createBreakpoints';\nimport shape from './shape';\nimport createSpacing from './createSpacing';\nimport styleFunctionSx from '../styleFunctionSx/styleFunctionSx';\nimport defaultSxConfig from '../styleFunctionSx/defaultSxConfig';\nimport applyStyles from './applyStyles';\nfunction createTheme(options = {}, ...args) {\n const {\n breakpoints: breakpointsInput = {},\n palette: paletteInput = {},\n spacing: spacingInput,\n shape: shapeInput = {}\n } = options,\n other = _objectWithoutPropertiesLoose(options, _excluded);\n const breakpoints = createBreakpoints(breakpointsInput);\n const spacing = createSpacing(spacingInput);\n let muiTheme = deepmerge({\n breakpoints,\n direction: 'ltr',\n components: {},\n // Inject component definitions.\n palette: _extends({\n mode: 'light'\n }, paletteInput),\n spacing,\n shape: _extends({}, shape, shapeInput)\n }, other);\n muiTheme.applyStyles = applyStyles;\n muiTheme = args.reduce((acc, argument) => deepmerge(acc, argument), muiTheme);\n muiTheme.unstable_sxConfig = _extends({}, defaultSxConfig, other == null ? void 0 : other.unstable_sxConfig);\n muiTheme.unstable_sx = function sx(props) {\n return styleFunctionSx({\n sx: props,\n theme: this\n });\n };\n return muiTheme;\n}\nexport default createTheme;","'use client';\n\nimport * as React from 'react';\nimport { ThemeContext } from '@mui/styled-engine';\nfunction isObjectEmpty(obj) {\n return Object.keys(obj).length === 0;\n}\nfunction useTheme(defaultTheme = null) {\n const contextTheme = React.useContext(ThemeContext);\n return !contextTheme || isObjectEmpty(contextTheme) ? defaultTheme : contextTheme;\n}\nexport default useTheme;","'use client';\n\nimport createTheme from './createTheme';\nimport useThemeWithoutDefault from './useThemeWithoutDefault';\nexport const systemDefaultTheme = createTheme();\nfunction useTheme(defaultTheme = systemDefaultTheme) {\n return useThemeWithoutDefault(defaultTheme);\n}\nexport default useTheme;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"ownerState\"],\n _excluded2 = [\"variants\"],\n _excluded3 = [\"name\", \"slot\", \"skipVariantsResolver\", \"skipSx\", \"overridesResolver\"];\n/* eslint-disable no-underscore-dangle */\nimport styledEngineStyled, { internal_processStyles as processStyles } from '@mui/styled-engine';\nimport { isPlainObject } from '@mui/utils/deepmerge';\nimport capitalize from '@mui/utils/capitalize';\nimport getDisplayName from '@mui/utils/getDisplayName';\nimport createTheme from './createTheme';\nimport styleFunctionSx from './styleFunctionSx';\nfunction isEmpty(obj) {\n return Object.keys(obj).length === 0;\n}\n\n// https://github.com/emotion-js/emotion/blob/26ded6109fcd8ca9875cc2ce4564fee678a3f3c5/packages/styled/src/utils.js#L40\nfunction isStringTag(tag) {\n return typeof tag === 'string' &&\n // 96 is one less than the char code\n // for \"a\" so this is checking that\n // it's a lowercase character\n tag.charCodeAt(0) > 96;\n}\n\n// Update /system/styled/#api in case if this changes\nexport function shouldForwardProp(prop) {\n return prop !== 'ownerState' && prop !== 'theme' && prop !== 'sx' && prop !== 'as';\n}\nexport const systemDefaultTheme = createTheme();\nconst lowercaseFirstLetter = string => {\n if (!string) {\n return string;\n }\n return string.charAt(0).toLowerCase() + string.slice(1);\n};\nfunction resolveTheme({\n defaultTheme,\n theme,\n themeId\n}) {\n return isEmpty(theme) ? defaultTheme : theme[themeId] || theme;\n}\nfunction defaultOverridesResolver(slot) {\n if (!slot) {\n return null;\n }\n return (props, styles) => styles[slot];\n}\nfunction processStyleArg(callableStyle, _ref) {\n let {\n ownerState\n } = _ref,\n props = _objectWithoutPropertiesLoose(_ref, _excluded);\n const resolvedStylesArg = typeof callableStyle === 'function' ? callableStyle(_extends({\n ownerState\n }, props)) : callableStyle;\n if (Array.isArray(resolvedStylesArg)) {\n return resolvedStylesArg.flatMap(resolvedStyle => processStyleArg(resolvedStyle, _extends({\n ownerState\n }, props)));\n }\n if (!!resolvedStylesArg && typeof resolvedStylesArg === 'object' && Array.isArray(resolvedStylesArg.variants)) {\n const {\n variants = []\n } = resolvedStylesArg,\n otherStyles = _objectWithoutPropertiesLoose(resolvedStylesArg, _excluded2);\n let result = otherStyles;\n variants.forEach(variant => {\n let isMatch = true;\n if (typeof variant.props === 'function') {\n isMatch = variant.props(_extends({\n ownerState\n }, props, ownerState));\n } else {\n Object.keys(variant.props).forEach(key => {\n if ((ownerState == null ? void 0 : ownerState[key]) !== variant.props[key] && props[key] !== variant.props[key]) {\n isMatch = false;\n }\n });\n }\n if (isMatch) {\n if (!Array.isArray(result)) {\n result = [result];\n }\n result.push(typeof variant.style === 'function' ? variant.style(_extends({\n ownerState\n }, props, ownerState)) : variant.style);\n }\n });\n return result;\n }\n return resolvedStylesArg;\n}\nexport default function createStyled(input = {}) {\n const {\n themeId,\n defaultTheme = systemDefaultTheme,\n rootShouldForwardProp = shouldForwardProp,\n slotShouldForwardProp = shouldForwardProp\n } = input;\n const systemSx = props => {\n return styleFunctionSx(_extends({}, props, {\n theme: resolveTheme(_extends({}, props, {\n defaultTheme,\n themeId\n }))\n }));\n };\n systemSx.__mui_systemSx = true;\n return (tag, inputOptions = {}) => {\n // Filter out the `sx` style function from the previous styled component to prevent unnecessary styles generated by the composite components.\n processStyles(tag, styles => styles.filter(style => !(style != null && style.__mui_systemSx)));\n const {\n name: componentName,\n slot: componentSlot,\n skipVariantsResolver: inputSkipVariantsResolver,\n skipSx: inputSkipSx,\n // TODO v6: remove `lowercaseFirstLetter()` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n overridesResolver = defaultOverridesResolver(lowercaseFirstLetter(componentSlot))\n } = inputOptions,\n options = _objectWithoutPropertiesLoose(inputOptions, _excluded3);\n\n // if skipVariantsResolver option is defined, take the value, otherwise, true for root and false for other slots.\n const skipVariantsResolver = inputSkipVariantsResolver !== undefined ? inputSkipVariantsResolver :\n // TODO v6: remove `Root` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n componentSlot && componentSlot !== 'Root' && componentSlot !== 'root' || false;\n const skipSx = inputSkipSx || false;\n let label;\n if (process.env.NODE_ENV !== 'production') {\n if (componentName) {\n // TODO v6: remove `lowercaseFirstLetter()` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n label = `${componentName}-${lowercaseFirstLetter(componentSlot || 'Root')}`;\n }\n }\n let shouldForwardPropOption = shouldForwardProp;\n\n // TODO v6: remove `Root` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n if (componentSlot === 'Root' || componentSlot === 'root') {\n shouldForwardPropOption = rootShouldForwardProp;\n } else if (componentSlot) {\n // any other slot specified\n shouldForwardPropOption = slotShouldForwardProp;\n } else if (isStringTag(tag)) {\n // for string (html) tag, preserve the behavior in emotion & styled-components.\n shouldForwardPropOption = undefined;\n }\n const defaultStyledResolver = styledEngineStyled(tag, _extends({\n shouldForwardProp: shouldForwardPropOption,\n label\n }, options));\n const transformStyleArg = stylesArg => {\n // On the server Emotion doesn't use React.forwardRef for creating components, so the created\n // component stays as a function. This condition makes sure that we do not interpolate functions\n // which are basically components used as a selectors.\n if (typeof stylesArg === 'function' && stylesArg.__emotion_real !== stylesArg || isPlainObject(stylesArg)) {\n return props => processStyleArg(stylesArg, _extends({}, props, {\n theme: resolveTheme({\n theme: props.theme,\n defaultTheme,\n themeId\n })\n }));\n }\n return stylesArg;\n };\n const muiStyledResolver = (styleArg, ...expressions) => {\n let transformedStyleArg = transformStyleArg(styleArg);\n const expressionsWithDefaultTheme = expressions ? expressions.map(transformStyleArg) : [];\n if (componentName && overridesResolver) {\n expressionsWithDefaultTheme.push(props => {\n const theme = resolveTheme(_extends({}, props, {\n defaultTheme,\n themeId\n }));\n if (!theme.components || !theme.components[componentName] || !theme.components[componentName].styleOverrides) {\n return null;\n }\n const styleOverrides = theme.components[componentName].styleOverrides;\n const resolvedStyleOverrides = {};\n // TODO: v7 remove iteration and use `resolveStyleArg(styleOverrides[slot])` directly\n Object.entries(styleOverrides).forEach(([slotKey, slotStyle]) => {\n resolvedStyleOverrides[slotKey] = processStyleArg(slotStyle, _extends({}, props, {\n theme\n }));\n });\n return overridesResolver(props, resolvedStyleOverrides);\n });\n }\n if (componentName && !skipVariantsResolver) {\n expressionsWithDefaultTheme.push(props => {\n var _theme$components;\n const theme = resolveTheme(_extends({}, props, {\n defaultTheme,\n themeId\n }));\n const themeVariants = theme == null || (_theme$components = theme.components) == null || (_theme$components = _theme$components[componentName]) == null ? void 0 : _theme$components.variants;\n return processStyleArg({\n variants: themeVariants\n }, _extends({}, props, {\n theme\n }));\n });\n }\n if (!skipSx) {\n expressionsWithDefaultTheme.push(systemSx);\n }\n const numOfCustomFnsApplied = expressionsWithDefaultTheme.length - expressions.length;\n if (Array.isArray(styleArg) && numOfCustomFnsApplied > 0) {\n const placeholders = new Array(numOfCustomFnsApplied).fill('');\n // If the type is array, than we need to add placeholders in the template for the overrides, variants and the sx styles.\n transformedStyleArg = [...styleArg, ...placeholders];\n transformedStyleArg.raw = [...styleArg.raw, ...placeholders];\n }\n const Component = defaultStyledResolver(transformedStyleArg, ...expressionsWithDefaultTheme);\n if (process.env.NODE_ENV !== 'production') {\n let displayName;\n if (componentName) {\n displayName = `${componentName}${capitalize(componentSlot || '')}`;\n }\n if (displayName === undefined) {\n displayName = `Styled(${getDisplayName(tag)})`;\n }\n Component.displayName = displayName;\n }\n if (tag.muiName) {\n Component.muiName = tag.muiName;\n }\n return Component;\n };\n if (defaultStyledResolver.withConfig) {\n muiStyledResolver.withConfig = defaultStyledResolver.withConfig;\n }\n return muiStyledResolver;\n };\n}","import resolveProps from '@mui/utils/resolveProps';\nexport default function getThemeProps(params) {\n const {\n theme,\n name,\n props\n } = params;\n if (!theme || !theme.components || !theme.components[name] || !theme.components[name].defaultProps) {\n return props;\n }\n return resolveProps(theme.components[name].defaultProps, props);\n}","'use client';\n\nimport getThemeProps from './getThemeProps';\nimport useTheme from '../useTheme';\nexport default function useThemeProps({\n props,\n name,\n defaultTheme,\n themeId\n}) {\n let theme = useTheme(defaultTheme);\n if (themeId) {\n theme = theme[themeId] || theme;\n }\n const mergedProps = getThemeProps({\n theme,\n name,\n props\n });\n return mergedProps;\n}","import _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\n/* eslint-disable @typescript-eslint/naming-convention */\nimport clamp from '@mui/utils/clamp';\n/**\n * Returns a number whose value is limited to the given range.\n * @param {number} value The value to be clamped\n * @param {number} min The lower boundary of the output range\n * @param {number} max The upper boundary of the output range\n * @returns {number} A number in the range [min, max]\n */\nfunction clampWrapper(value, min = 0, max = 1) {\n if (process.env.NODE_ENV !== 'production') {\n if (value < min || value > max) {\n console.error(`MUI: The value provided ${value} is out of range [${min}, ${max}].`);\n }\n }\n return clamp(value, min, max);\n}\n\n/**\n * Converts a color from CSS hex format to CSS rgb format.\n * @param {string} color - Hex color, i.e. #nnn or #nnnnnn\n * @returns {string} A CSS rgb color string\n */\nexport function hexToRgb(color) {\n color = color.slice(1);\n const re = new RegExp(`.{1,${color.length >= 6 ? 2 : 1}}`, 'g');\n let colors = color.match(re);\n if (colors && colors[0].length === 1) {\n colors = colors.map(n => n + n);\n }\n return colors ? `rgb${colors.length === 4 ? 'a' : ''}(${colors.map((n, index) => {\n return index < 3 ? parseInt(n, 16) : Math.round(parseInt(n, 16) / 255 * 1000) / 1000;\n }).join(', ')})` : '';\n}\nfunction intToHex(int) {\n const hex = int.toString(16);\n return hex.length === 1 ? `0${hex}` : hex;\n}\n\n/**\n * Returns an object with the type and values of a color.\n *\n * Note: Does not support rgb % values.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @returns {object} - A MUI color object: {type: string, values: number[]}\n */\nexport function decomposeColor(color) {\n // Idempotent\n if (color.type) {\n return color;\n }\n if (color.charAt(0) === '#') {\n return decomposeColor(hexToRgb(color));\n }\n const marker = color.indexOf('(');\n const type = color.substring(0, marker);\n if (['rgb', 'rgba', 'hsl', 'hsla', 'color'].indexOf(type) === -1) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: Unsupported \\`${color}\\` color.\nThe following formats are supported: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color().` : _formatMuiErrorMessage(9, color));\n }\n let values = color.substring(marker + 1, color.length - 1);\n let colorSpace;\n if (type === 'color') {\n values = values.split(' ');\n colorSpace = values.shift();\n if (values.length === 4 && values[3].charAt(0) === '/') {\n values[3] = values[3].slice(1);\n }\n if (['srgb', 'display-p3', 'a98-rgb', 'prophoto-rgb', 'rec-2020'].indexOf(colorSpace) === -1) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: unsupported \\`${colorSpace}\\` color space.\nThe following color spaces are supported: srgb, display-p3, a98-rgb, prophoto-rgb, rec-2020.` : _formatMuiErrorMessage(10, colorSpace));\n }\n } else {\n values = values.split(',');\n }\n values = values.map(value => parseFloat(value));\n return {\n type,\n values,\n colorSpace\n };\n}\n\n/**\n * Returns a channel created from the input color.\n *\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @returns {string} - The channel for the color, that can be used in rgba or hsla colors\n */\nexport const colorChannel = color => {\n const decomposedColor = decomposeColor(color);\n return decomposedColor.values.slice(0, 3).map((val, idx) => decomposedColor.type.indexOf('hsl') !== -1 && idx !== 0 ? `${val}%` : val).join(' ');\n};\nexport const private_safeColorChannel = (color, warning) => {\n try {\n return colorChannel(color);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n};\n\n/**\n * Converts a color object with type and values to a string.\n * @param {object} color - Decomposed color\n * @param {string} color.type - One of: 'rgb', 'rgba', 'hsl', 'hsla', 'color'\n * @param {array} color.values - [n,n,n] or [n,n,n,n]\n * @returns {string} A CSS color string\n */\nexport function recomposeColor(color) {\n const {\n type,\n colorSpace\n } = color;\n let {\n values\n } = color;\n if (type.indexOf('rgb') !== -1) {\n // Only convert the first 3 values to int (i.e. not alpha)\n values = values.map((n, i) => i < 3 ? parseInt(n, 10) : n);\n } else if (type.indexOf('hsl') !== -1) {\n values[1] = `${values[1]}%`;\n values[2] = `${values[2]}%`;\n }\n if (type.indexOf('color') !== -1) {\n values = `${colorSpace} ${values.join(' ')}`;\n } else {\n values = `${values.join(', ')}`;\n }\n return `${type}(${values})`;\n}\n\n/**\n * Converts a color from CSS rgb format to CSS hex format.\n * @param {string} color - RGB color, i.e. rgb(n, n, n)\n * @returns {string} A CSS rgb color string, i.e. #nnnnnn\n */\nexport function rgbToHex(color) {\n // Idempotent\n if (color.indexOf('#') === 0) {\n return color;\n }\n const {\n values\n } = decomposeColor(color);\n return `#${values.map((n, i) => intToHex(i === 3 ? Math.round(255 * n) : n)).join('')}`;\n}\n\n/**\n * Converts a color from hsl format to rgb format.\n * @param {string} color - HSL color values\n * @returns {string} rgb color values\n */\nexport function hslToRgb(color) {\n color = decomposeColor(color);\n const {\n values\n } = color;\n const h = values[0];\n const s = values[1] / 100;\n const l = values[2] / 100;\n const a = s * Math.min(l, 1 - l);\n const f = (n, k = (n + h / 30) % 12) => l - a * Math.max(Math.min(k - 3, 9 - k, 1), -1);\n let type = 'rgb';\n const rgb = [Math.round(f(0) * 255), Math.round(f(8) * 255), Math.round(f(4) * 255)];\n if (color.type === 'hsla') {\n type += 'a';\n rgb.push(values[3]);\n }\n return recomposeColor({\n type,\n values: rgb\n });\n}\n/**\n * The relative brightness of any point in a color space,\n * normalized to 0 for darkest black and 1 for lightest white.\n *\n * Formula: https://www.w3.org/TR/WCAG20-TECHS/G17.html#G17-tests\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @returns {number} The relative brightness of the color in the range 0 - 1\n */\nexport function getLuminance(color) {\n color = decomposeColor(color);\n let rgb = color.type === 'hsl' || color.type === 'hsla' ? decomposeColor(hslToRgb(color)).values : color.values;\n rgb = rgb.map(val => {\n if (color.type !== 'color') {\n val /= 255; // normalized\n }\n return val <= 0.03928 ? val / 12.92 : ((val + 0.055) / 1.055) ** 2.4;\n });\n\n // Truncate at 3 digits\n return Number((0.2126 * rgb[0] + 0.7152 * rgb[1] + 0.0722 * rgb[2]).toFixed(3));\n}\n\n/**\n * Calculates the contrast ratio between two colors.\n *\n * Formula: https://www.w3.org/TR/WCAG20-TECHS/G17.html#G17-tests\n * @param {string} foreground - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla()\n * @param {string} background - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla()\n * @returns {number} A contrast ratio value in the range 0 - 21.\n */\nexport function getContrastRatio(foreground, background) {\n const lumA = getLuminance(foreground);\n const lumB = getLuminance(background);\n return (Math.max(lumA, lumB) + 0.05) / (Math.min(lumA, lumB) + 0.05);\n}\n\n/**\n * Sets the absolute transparency of a color.\n * Any existing alpha values are overwritten.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} value - value to set the alpha channel to in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function alpha(color, value) {\n color = decomposeColor(color);\n value = clampWrapper(value);\n if (color.type === 'rgb' || color.type === 'hsl') {\n color.type += 'a';\n }\n if (color.type === 'color') {\n color.values[3] = `/${value}`;\n } else {\n color.values[3] = value;\n }\n return recomposeColor(color);\n}\nexport function private_safeAlpha(color, value, warning) {\n try {\n return alpha(color, value);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Darkens a color.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} coefficient - multiplier in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function darken(color, coefficient) {\n color = decomposeColor(color);\n coefficient = clampWrapper(coefficient);\n if (color.type.indexOf('hsl') !== -1) {\n color.values[2] *= 1 - coefficient;\n } else if (color.type.indexOf('rgb') !== -1 || color.type.indexOf('color') !== -1) {\n for (let i = 0; i < 3; i += 1) {\n color.values[i] *= 1 - coefficient;\n }\n }\n return recomposeColor(color);\n}\nexport function private_safeDarken(color, coefficient, warning) {\n try {\n return darken(color, coefficient);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Lightens a color.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} coefficient - multiplier in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function lighten(color, coefficient) {\n color = decomposeColor(color);\n coefficient = clampWrapper(coefficient);\n if (color.type.indexOf('hsl') !== -1) {\n color.values[2] += (100 - color.values[2]) * coefficient;\n } else if (color.type.indexOf('rgb') !== -1) {\n for (let i = 0; i < 3; i += 1) {\n color.values[i] += (255 - color.values[i]) * coefficient;\n }\n } else if (color.type.indexOf('color') !== -1) {\n for (let i = 0; i < 3; i += 1) {\n color.values[i] += (1 - color.values[i]) * coefficient;\n }\n }\n return recomposeColor(color);\n}\nexport function private_safeLighten(color, coefficient, warning) {\n try {\n return lighten(color, coefficient);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Darken or lighten a color, depending on its luminance.\n * Light colors are darkened, dark colors are lightened.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} coefficient=0.15 - multiplier in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function emphasize(color, coefficient = 0.15) {\n return getLuminance(color) > 0.5 ? darken(color, coefficient) : lighten(color, coefficient);\n}\nexport function private_safeEmphasize(color, coefficient, warning) {\n try {\n return emphasize(color, coefficient);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Blend a transparent overlay color with a background color, resulting in a single\n * RGB color.\n * @param {string} background - CSS color\n * @param {string} overlay - CSS color\n * @param {number} opacity - Opacity multiplier in the range 0 - 1\n * @param {number} [gamma=1.0] - Gamma correction factor. For gamma-correct blending, 2.2 is usual.\n */\nexport function blend(background, overlay, opacity, gamma = 1.0) {\n const blendChannel = (b, o) => Math.round((b ** (1 / gamma) * (1 - opacity) + o ** (1 / gamma) * opacity) ** gamma);\n const backgroundColor = decomposeColor(background);\n const overlayColor = decomposeColor(overlay);\n const rgb = [blendChannel(backgroundColor.values[0], overlayColor.values[0]), blendChannel(backgroundColor.values[1], overlayColor.values[1]), blendChannel(backgroundColor.values[2], overlayColor.values[2])];\n return recomposeColor({\n type: 'rgb',\n values: rgb\n });\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nexport default function createMixins(breakpoints, mixins) {\n return _extends({\n toolbar: {\n minHeight: 56,\n [breakpoints.up('xs')]: {\n '@media (orientation: landscape)': {\n minHeight: 48\n }\n },\n [breakpoints.up('sm')]: {\n minHeight: 64\n }\n }\n }, mixins);\n}","const common = {\n black: '#000',\n white: '#fff'\n};\nexport default common;","const grey = {\n 50: '#fafafa',\n 100: '#f5f5f5',\n 200: '#eeeeee',\n 300: '#e0e0e0',\n 400: '#bdbdbd',\n 500: '#9e9e9e',\n 600: '#757575',\n 700: '#616161',\n 800: '#424242',\n 900: '#212121',\n A100: '#f5f5f5',\n A200: '#eeeeee',\n A400: '#bdbdbd',\n A700: '#616161'\n};\nexport default grey;","const purple = {\n 50: '#f3e5f5',\n 100: '#e1bee7',\n 200: '#ce93d8',\n 300: '#ba68c8',\n 400: '#ab47bc',\n 500: '#9c27b0',\n 600: '#8e24aa',\n 700: '#7b1fa2',\n 800: '#6a1b9a',\n 900: '#4a148c',\n A100: '#ea80fc',\n A200: '#e040fb',\n A400: '#d500f9',\n A700: '#aa00ff'\n};\nexport default purple;","const red = {\n 50: '#ffebee',\n 100: '#ffcdd2',\n 200: '#ef9a9a',\n 300: '#e57373',\n 400: '#ef5350',\n 500: '#f44336',\n 600: '#e53935',\n 700: '#d32f2f',\n 800: '#c62828',\n 900: '#b71c1c',\n A100: '#ff8a80',\n A200: '#ff5252',\n A400: '#ff1744',\n A700: '#d50000'\n};\nexport default red;","const orange = {\n 50: '#fff3e0',\n 100: '#ffe0b2',\n 200: '#ffcc80',\n 300: '#ffb74d',\n 400: '#ffa726',\n 500: '#ff9800',\n 600: '#fb8c00',\n 700: '#f57c00',\n 800: '#ef6c00',\n 900: '#e65100',\n A100: '#ffd180',\n A200: '#ffab40',\n A400: '#ff9100',\n A700: '#ff6d00'\n};\nexport default orange;","const blue = {\n 50: '#e3f2fd',\n 100: '#bbdefb',\n 200: '#90caf9',\n 300: '#64b5f6',\n 400: '#42a5f5',\n 500: '#2196f3',\n 600: '#1e88e5',\n 700: '#1976d2',\n 800: '#1565c0',\n 900: '#0d47a1',\n A100: '#82b1ff',\n A200: '#448aff',\n A400: '#2979ff',\n A700: '#2962ff'\n};\nexport default blue;","const lightBlue = {\n 50: '#e1f5fe',\n 100: '#b3e5fc',\n 200: '#81d4fa',\n 300: '#4fc3f7',\n 400: '#29b6f6',\n 500: '#03a9f4',\n 600: '#039be5',\n 700: '#0288d1',\n 800: '#0277bd',\n 900: '#01579b',\n A100: '#80d8ff',\n A200: '#40c4ff',\n A400: '#00b0ff',\n A700: '#0091ea'\n};\nexport default lightBlue;","const green = {\n 50: '#e8f5e9',\n 100: '#c8e6c9',\n 200: '#a5d6a7',\n 300: '#81c784',\n 400: '#66bb6a',\n 500: '#4caf50',\n 600: '#43a047',\n 700: '#388e3c',\n 800: '#2e7d32',\n 900: '#1b5e20',\n A100: '#b9f6ca',\n A200: '#69f0ae',\n A400: '#00e676',\n A700: '#00c853'\n};\nexport default green;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\nconst _excluded = [\"mode\", \"contrastThreshold\", \"tonalOffset\"];\nimport { deepmerge } from '@mui/utils';\nimport { darken, getContrastRatio, lighten } from '@mui/system';\nimport common from '../colors/common';\nimport grey from '../colors/grey';\nimport purple from '../colors/purple';\nimport red from '../colors/red';\nimport orange from '../colors/orange';\nimport blue from '../colors/blue';\nimport lightBlue from '../colors/lightBlue';\nimport green from '../colors/green';\nexport const light = {\n // The colors used to style the text.\n text: {\n // The most important text.\n primary: 'rgba(0, 0, 0, 0.87)',\n // Secondary text.\n secondary: 'rgba(0, 0, 0, 0.6)',\n // Disabled text have even lower visual prominence.\n disabled: 'rgba(0, 0, 0, 0.38)'\n },\n // The color used to divide different elements.\n divider: 'rgba(0, 0, 0, 0.12)',\n // The background colors used to style the surfaces.\n // Consistency between these values is important.\n background: {\n paper: common.white,\n default: common.white\n },\n // The colors used to style the action elements.\n action: {\n // The color of an active action like an icon button.\n active: 'rgba(0, 0, 0, 0.54)',\n // The color of an hovered action.\n hover: 'rgba(0, 0, 0, 0.04)',\n hoverOpacity: 0.04,\n // The color of a selected action.\n selected: 'rgba(0, 0, 0, 0.08)',\n selectedOpacity: 0.08,\n // The color of a disabled action.\n disabled: 'rgba(0, 0, 0, 0.26)',\n // The background color of a disabled action.\n disabledBackground: 'rgba(0, 0, 0, 0.12)',\n disabledOpacity: 0.38,\n focus: 'rgba(0, 0, 0, 0.12)',\n focusOpacity: 0.12,\n activatedOpacity: 0.12\n }\n};\nexport const dark = {\n text: {\n primary: common.white,\n secondary: 'rgba(255, 255, 255, 0.7)',\n disabled: 'rgba(255, 255, 255, 0.5)',\n icon: 'rgba(255, 255, 255, 0.5)'\n },\n divider: 'rgba(255, 255, 255, 0.12)',\n background: {\n paper: '#121212',\n default: '#121212'\n },\n action: {\n active: common.white,\n hover: 'rgba(255, 255, 255, 0.08)',\n hoverOpacity: 0.08,\n selected: 'rgba(255, 255, 255, 0.16)',\n selectedOpacity: 0.16,\n disabled: 'rgba(255, 255, 255, 0.3)',\n disabledBackground: 'rgba(255, 255, 255, 0.12)',\n disabledOpacity: 0.38,\n focus: 'rgba(255, 255, 255, 0.12)',\n focusOpacity: 0.12,\n activatedOpacity: 0.24\n }\n};\nfunction addLightOrDark(intent, direction, shade, tonalOffset) {\n const tonalOffsetLight = tonalOffset.light || tonalOffset;\n const tonalOffsetDark = tonalOffset.dark || tonalOffset * 1.5;\n if (!intent[direction]) {\n if (intent.hasOwnProperty(shade)) {\n intent[direction] = intent[shade];\n } else if (direction === 'light') {\n intent.light = lighten(intent.main, tonalOffsetLight);\n } else if (direction === 'dark') {\n intent.dark = darken(intent.main, tonalOffsetDark);\n }\n }\n}\nfunction getDefaultPrimary(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: blue[200],\n light: blue[50],\n dark: blue[400]\n };\n }\n return {\n main: blue[700],\n light: blue[400],\n dark: blue[800]\n };\n}\nfunction getDefaultSecondary(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: purple[200],\n light: purple[50],\n dark: purple[400]\n };\n }\n return {\n main: purple[500],\n light: purple[300],\n dark: purple[700]\n };\n}\nfunction getDefaultError(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: red[500],\n light: red[300],\n dark: red[700]\n };\n }\n return {\n main: red[700],\n light: red[400],\n dark: red[800]\n };\n}\nfunction getDefaultInfo(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: lightBlue[400],\n light: lightBlue[300],\n dark: lightBlue[700]\n };\n }\n return {\n main: lightBlue[700],\n light: lightBlue[500],\n dark: lightBlue[900]\n };\n}\nfunction getDefaultSuccess(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: green[400],\n light: green[300],\n dark: green[700]\n };\n }\n return {\n main: green[800],\n light: green[500],\n dark: green[900]\n };\n}\nfunction getDefaultWarning(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: orange[400],\n light: orange[300],\n dark: orange[700]\n };\n }\n return {\n main: '#ed6c02',\n // closest to orange[800] that pass 3:1.\n light: orange[500],\n dark: orange[900]\n };\n}\nexport default function createPalette(palette) {\n const {\n mode = 'light',\n contrastThreshold = 3,\n tonalOffset = 0.2\n } = palette,\n other = _objectWithoutPropertiesLoose(palette, _excluded);\n const primary = palette.primary || getDefaultPrimary(mode);\n const secondary = palette.secondary || getDefaultSecondary(mode);\n const error = palette.error || getDefaultError(mode);\n const info = palette.info || getDefaultInfo(mode);\n const success = palette.success || getDefaultSuccess(mode);\n const warning = palette.warning || getDefaultWarning(mode);\n\n // Use the same logic as\n // Bootstrap: https://github.com/twbs/bootstrap/blob/1d6e3710dd447de1a200f29e8fa521f8a0908f70/scss/_functions.scss#L59\n // and material-components-web https://github.com/material-components/material-components-web/blob/ac46b8863c4dab9fc22c4c662dc6bd1b65dd652f/packages/mdc-theme/_functions.scss#L54\n function getContrastText(background) {\n const contrastText = getContrastRatio(background, dark.text.primary) >= contrastThreshold ? dark.text.primary : light.text.primary;\n if (process.env.NODE_ENV !== 'production') {\n const contrast = getContrastRatio(background, contrastText);\n if (contrast < 3) {\n console.error([`MUI: The contrast ratio of ${contrast}:1 for ${contrastText} on ${background}`, 'falls below the WCAG recommended absolute minimum contrast ratio of 3:1.', 'https://www.w3.org/TR/2008/REC-WCAG20-20081211/#visual-audio-contrast-contrast'].join('\\n'));\n }\n }\n return contrastText;\n }\n const augmentColor = ({\n color,\n name,\n mainShade = 500,\n lightShade = 300,\n darkShade = 700\n }) => {\n color = _extends({}, color);\n if (!color.main && color[mainShade]) {\n color.main = color[mainShade];\n }\n if (!color.hasOwnProperty('main')) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: The color${name ? ` (${name})` : ''} provided to augmentColor(color) is invalid.\nThe color object needs to have a \\`main\\` property or a \\`${mainShade}\\` property.` : _formatMuiErrorMessage(11, name ? ` (${name})` : '', mainShade));\n }\n if (typeof color.main !== 'string') {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: The color${name ? ` (${name})` : ''} provided to augmentColor(color) is invalid.\n\\`color.main\\` should be a string, but \\`${JSON.stringify(color.main)}\\` was provided instead.\n\nDid you intend to use one of the following approaches?\n\nimport { green } from \"@mui/material/colors\";\n\nconst theme1 = createTheme({ palette: {\n primary: green,\n} });\n\nconst theme2 = createTheme({ palette: {\n primary: { main: green[500] },\n} });` : _formatMuiErrorMessage(12, name ? ` (${name})` : '', JSON.stringify(color.main)));\n }\n addLightOrDark(color, 'light', lightShade, tonalOffset);\n addLightOrDark(color, 'dark', darkShade, tonalOffset);\n if (!color.contrastText) {\n color.contrastText = getContrastText(color.main);\n }\n return color;\n };\n const modes = {\n dark,\n light\n };\n if (process.env.NODE_ENV !== 'production') {\n if (!modes[mode]) {\n console.error(`MUI: The palette mode \\`${mode}\\` is not supported.`);\n }\n }\n const paletteOutput = deepmerge(_extends({\n // A collection of common colors.\n common: _extends({}, common),\n // prevent mutable object.\n // The palette mode, can be light or dark.\n mode,\n // The colors used to represent primary interface elements for a user.\n primary: augmentColor({\n color: primary,\n name: 'primary'\n }),\n // The colors used to represent secondary interface elements for a user.\n secondary: augmentColor({\n color: secondary,\n name: 'secondary',\n mainShade: 'A400',\n lightShade: 'A200',\n darkShade: 'A700'\n }),\n // The colors used to represent interface elements that the user should be made aware of.\n error: augmentColor({\n color: error,\n name: 'error'\n }),\n // The colors used to represent potentially dangerous actions or important messages.\n warning: augmentColor({\n color: warning,\n name: 'warning'\n }),\n // The colors used to present information to the user that is neutral and not necessarily important.\n info: augmentColor({\n color: info,\n name: 'info'\n }),\n // The colors used to indicate the successful completion of an action that user triggered.\n success: augmentColor({\n color: success,\n name: 'success'\n }),\n // The grey colors.\n grey,\n // Used by `getContrastText()` to maximize the contrast between\n // the background and the text.\n contrastThreshold,\n // Takes a background color and returns the text color that maximizes the contrast.\n getContrastText,\n // Generate a rich color object.\n augmentColor,\n // Used by the functions below to shift a color's luminance by approximately\n // two indexes within its tonal palette.\n // E.g., shift from Red 500 to Red 300 or Red 700.\n tonalOffset\n }, modes[mode]), other);\n return paletteOutput;\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"fontFamily\", \"fontSize\", \"fontWeightLight\", \"fontWeightRegular\", \"fontWeightMedium\", \"fontWeightBold\", \"htmlFontSize\", \"allVariants\", \"pxToRem\"];\nimport { deepmerge } from '@mui/utils';\nfunction round(value) {\n return Math.round(value * 1e5) / 1e5;\n}\nconst caseAllCaps = {\n textTransform: 'uppercase'\n};\nconst defaultFontFamily = '\"Roboto\", \"Helvetica\", \"Arial\", sans-serif';\n\n/**\n * @see @link{https://m2.material.io/design/typography/the-type-system.html}\n * @see @link{https://m2.material.io/design/typography/understanding-typography.html}\n */\nexport default function createTypography(palette, typography) {\n const _ref = typeof typography === 'function' ? typography(palette) : typography,\n {\n fontFamily = defaultFontFamily,\n // The default font size of the Material Specification.\n fontSize = 14,\n // px\n fontWeightLight = 300,\n fontWeightRegular = 400,\n fontWeightMedium = 500,\n fontWeightBold = 700,\n // Tell MUI what's the font-size on the html element.\n // 16px is the default font-size used by browsers.\n htmlFontSize = 16,\n // Apply the CSS properties to all the variants.\n allVariants,\n pxToRem: pxToRem2\n } = _ref,\n other = _objectWithoutPropertiesLoose(_ref, _excluded);\n if (process.env.NODE_ENV !== 'production') {\n if (typeof fontSize !== 'number') {\n console.error('MUI: `fontSize` is required to be a number.');\n }\n if (typeof htmlFontSize !== 'number') {\n console.error('MUI: `htmlFontSize` is required to be a number.');\n }\n }\n const coef = fontSize / 14;\n const pxToRem = pxToRem2 || (size => `${size / htmlFontSize * coef}rem`);\n const buildVariant = (fontWeight, size, lineHeight, letterSpacing, casing) => _extends({\n fontFamily,\n fontWeight,\n fontSize: pxToRem(size),\n // Unitless following https://meyerweb.com/eric/thoughts/2006/02/08/unitless-line-heights/\n lineHeight\n }, fontFamily === defaultFontFamily ? {\n letterSpacing: `${round(letterSpacing / size)}em`\n } : {}, casing, allVariants);\n const variants = {\n h1: buildVariant(fontWeightLight, 96, 1.167, -1.5),\n h2: buildVariant(fontWeightLight, 60, 1.2, -0.5),\n h3: buildVariant(fontWeightRegular, 48, 1.167, 0),\n h4: buildVariant(fontWeightRegular, 34, 1.235, 0.25),\n h5: buildVariant(fontWeightRegular, 24, 1.334, 0),\n h6: buildVariant(fontWeightMedium, 20, 1.6, 0.15),\n subtitle1: buildVariant(fontWeightRegular, 16, 1.75, 0.15),\n subtitle2: buildVariant(fontWeightMedium, 14, 1.57, 0.1),\n body1: buildVariant(fontWeightRegular, 16, 1.5, 0.15),\n body2: buildVariant(fontWeightRegular, 14, 1.43, 0.15),\n button: buildVariant(fontWeightMedium, 14, 1.75, 0.4, caseAllCaps),\n caption: buildVariant(fontWeightRegular, 12, 1.66, 0.4),\n overline: buildVariant(fontWeightRegular, 12, 2.66, 1, caseAllCaps),\n // TODO v6: Remove handling of 'inherit' variant from the theme as it is already handled in Material UI's Typography component. Also, remember to remove the associated types.\n inherit: {\n fontFamily: 'inherit',\n fontWeight: 'inherit',\n fontSize: 'inherit',\n lineHeight: 'inherit',\n letterSpacing: 'inherit'\n }\n };\n return deepmerge(_extends({\n htmlFontSize,\n pxToRem,\n fontFamily,\n fontSize,\n fontWeightLight,\n fontWeightRegular,\n fontWeightMedium,\n fontWeightBold\n }, variants), other, {\n clone: false // No need to clone deep\n });\n}","const shadowKeyUmbraOpacity = 0.2;\nconst shadowKeyPenumbraOpacity = 0.14;\nconst shadowAmbientShadowOpacity = 0.12;\nfunction createShadow(...px) {\n return [`${px[0]}px ${px[1]}px ${px[2]}px ${px[3]}px rgba(0,0,0,${shadowKeyUmbraOpacity})`, `${px[4]}px ${px[5]}px ${px[6]}px ${px[7]}px rgba(0,0,0,${shadowKeyPenumbraOpacity})`, `${px[8]}px ${px[9]}px ${px[10]}px ${px[11]}px rgba(0,0,0,${shadowAmbientShadowOpacity})`].join(',');\n}\n\n// Values from https://github.com/material-components/material-components-web/blob/be8747f94574669cb5e7add1a7c54fa41a89cec7/packages/mdc-elevation/_variables.scss\nconst shadows = ['none', createShadow(0, 2, 1, -1, 0, 1, 1, 0, 0, 1, 3, 0), createShadow(0, 3, 1, -2, 0, 2, 2, 0, 0, 1, 5, 0), createShadow(0, 3, 3, -2, 0, 3, 4, 0, 0, 1, 8, 0), createShadow(0, 2, 4, -1, 0, 4, 5, 0, 0, 1, 10, 0), createShadow(0, 3, 5, -1, 0, 5, 8, 0, 0, 1, 14, 0), createShadow(0, 3, 5, -1, 0, 6, 10, 0, 0, 1, 18, 0), createShadow(0, 4, 5, -2, 0, 7, 10, 1, 0, 2, 16, 1), createShadow(0, 5, 5, -3, 0, 8, 10, 1, 0, 3, 14, 2), createShadow(0, 5, 6, -3, 0, 9, 12, 1, 0, 3, 16, 2), createShadow(0, 6, 6, -3, 0, 10, 14, 1, 0, 4, 18, 3), createShadow(0, 6, 7, -4, 0, 11, 15, 1, 0, 4, 20, 3), createShadow(0, 7, 8, -4, 0, 12, 17, 2, 0, 5, 22, 4), createShadow(0, 7, 8, -4, 0, 13, 19, 2, 0, 5, 24, 4), createShadow(0, 7, 9, -4, 0, 14, 21, 2, 0, 5, 26, 4), createShadow(0, 8, 9, -5, 0, 15, 22, 2, 0, 6, 28, 5), createShadow(0, 8, 10, -5, 0, 16, 24, 2, 0, 6, 30, 5), createShadow(0, 8, 11, -5, 0, 17, 26, 2, 0, 6, 32, 5), createShadow(0, 9, 11, -5, 0, 18, 28, 2, 0, 7, 34, 6), createShadow(0, 9, 12, -6, 0, 19, 29, 2, 0, 7, 36, 6), createShadow(0, 10, 13, -6, 0, 20, 31, 3, 0, 8, 38, 7), createShadow(0, 10, 13, -6, 0, 21, 33, 3, 0, 8, 40, 7), createShadow(0, 10, 14, -6, 0, 22, 35, 3, 0, 8, 42, 7), createShadow(0, 11, 14, -7, 0, 23, 36, 3, 0, 9, 44, 8), createShadow(0, 11, 15, -7, 0, 24, 38, 3, 0, 9, 46, 8)];\nexport default shadows;","import _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nconst _excluded = [\"duration\", \"easing\", \"delay\"];\n// Follow https://material.google.com/motion/duration-easing.html#duration-easing-natural-easing-curves\n// to learn the context in which each easing should be used.\nexport const easing = {\n // This is the most common easing curve.\n easeInOut: 'cubic-bezier(0.4, 0, 0.2, 1)',\n // Objects enter the screen at full velocity from off-screen and\n // slowly decelerate to a resting point.\n easeOut: 'cubic-bezier(0.0, 0, 0.2, 1)',\n // Objects leave the screen at full velocity. They do not decelerate when off-screen.\n easeIn: 'cubic-bezier(0.4, 0, 1, 1)',\n // The sharp curve is used by objects that may return to the screen at any time.\n sharp: 'cubic-bezier(0.4, 0, 0.6, 1)'\n};\n\n// Follow https://m2.material.io/guidelines/motion/duration-easing.html#duration-easing-common-durations\n// to learn when use what timing\nexport const duration = {\n shortest: 150,\n shorter: 200,\n short: 250,\n // most basic recommended timing\n standard: 300,\n // this is to be used in complex animations\n complex: 375,\n // recommended when something is entering screen\n enteringScreen: 225,\n // recommended when something is leaving screen\n leavingScreen: 195\n};\nfunction formatMs(milliseconds) {\n return `${Math.round(milliseconds)}ms`;\n}\nfunction getAutoHeightDuration(height) {\n if (!height) {\n return 0;\n }\n const constant = height / 36;\n\n // https://www.wolframalpha.com/input/?i=(4+%2B+15+*+(x+%2F+36+)+**+0.25+%2B+(x+%2F+36)+%2F+5)+*+10\n return Math.round((4 + 15 * constant ** 0.25 + constant / 5) * 10);\n}\nexport default function createTransitions(inputTransitions) {\n const mergedEasing = _extends({}, easing, inputTransitions.easing);\n const mergedDuration = _extends({}, duration, inputTransitions.duration);\n const create = (props = ['all'], options = {}) => {\n const {\n duration: durationOption = mergedDuration.standard,\n easing: easingOption = mergedEasing.easeInOut,\n delay = 0\n } = options,\n other = _objectWithoutPropertiesLoose(options, _excluded);\n if (process.env.NODE_ENV !== 'production') {\n const isString = value => typeof value === 'string';\n // IE11 support, replace with Number.isNaN\n // eslint-disable-next-line no-restricted-globals\n const isNumber = value => !isNaN(parseFloat(value));\n if (!isString(props) && !Array.isArray(props)) {\n console.error('MUI: Argument \"props\" must be a string or Array.');\n }\n if (!isNumber(durationOption) && !isString(durationOption)) {\n console.error(`MUI: Argument \"duration\" must be a number or a string but found ${durationOption}.`);\n }\n if (!isString(easingOption)) {\n console.error('MUI: Argument \"easing\" must be a string.');\n }\n if (!isNumber(delay) && !isString(delay)) {\n console.error('MUI: Argument \"delay\" must be a number or a string.');\n }\n if (typeof options !== 'object') {\n console.error(['MUI: Secong argument of transition.create must be an object.', \"Arguments should be either `create('prop1', options)` or `create(['prop1', 'prop2'], options)`\"].join('\\n'));\n }\n if (Object.keys(other).length !== 0) {\n console.error(`MUI: Unrecognized argument(s) [${Object.keys(other).join(',')}].`);\n }\n }\n return (Array.isArray(props) ? props : [props]).map(animatedProp => `${animatedProp} ${typeof durationOption === 'string' ? durationOption : formatMs(durationOption)} ${easingOption} ${typeof delay === 'string' ? delay : formatMs(delay)}`).join(',');\n };\n return _extends({\n getAutoHeightDuration,\n create\n }, inputTransitions, {\n easing: mergedEasing,\n duration: mergedDuration\n });\n}","// We need to centralize the zIndex definitions as they work\n// like global values in the browser.\nconst zIndex = {\n mobileStepper: 1000,\n fab: 1050,\n speedDial: 1050,\n appBar: 1100,\n drawer: 1200,\n modal: 1300,\n snackbar: 1400,\n tooltip: 1500\n};\nexport default zIndex;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\nconst _excluded = [\"breakpoints\", \"mixins\", \"spacing\", \"palette\", \"transitions\", \"typography\", \"shape\"];\nimport { deepmerge } from '@mui/utils';\nimport { createTheme as systemCreateTheme, unstable_defaultSxConfig as defaultSxConfig, unstable_styleFunctionSx as styleFunctionSx } from '@mui/system';\nimport generateUtilityClass from '@mui/utils/generateUtilityClass';\nimport createMixins from './createMixins';\nimport createPalette from './createPalette';\nimport createTypography from './createTypography';\nimport shadows from './shadows';\nimport createTransitions from './createTransitions';\nimport zIndex from './zIndex';\nfunction createTheme(options = {}, ...args) {\n const {\n mixins: mixinsInput = {},\n palette: paletteInput = {},\n transitions: transitionsInput = {},\n typography: typographyInput = {}\n } = options,\n other = _objectWithoutPropertiesLoose(options, _excluded);\n if (options.vars) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: \\`vars\\` is a private field used for CSS variables support.\nPlease use another name.` : _formatMuiErrorMessage(18));\n }\n const palette = createPalette(paletteInput);\n const systemTheme = systemCreateTheme(options);\n let muiTheme = deepmerge(systemTheme, {\n mixins: createMixins(systemTheme.breakpoints, mixinsInput),\n palette,\n // Don't use [...shadows] until you've verified its transpiled code is not invoking the iterator protocol.\n shadows: shadows.slice(),\n typography: createTypography(palette, typographyInput),\n transitions: createTransitions(transitionsInput),\n zIndex: _extends({}, zIndex)\n });\n muiTheme = deepmerge(muiTheme, other);\n muiTheme = args.reduce((acc, argument) => deepmerge(acc, argument), muiTheme);\n if (process.env.NODE_ENV !== 'production') {\n // TODO v6: Refactor to use globalStateClassesMapping from @mui/utils once `readOnly` state class is used in Rating component.\n const stateClasses = ['active', 'checked', 'completed', 'disabled', 'error', 'expanded', 'focused', 'focusVisible', 'required', 'selected'];\n const traverse = (node, component) => {\n let key;\n\n // eslint-disable-next-line guard-for-in, no-restricted-syntax\n for (key in node) {\n const child = node[key];\n if (stateClasses.indexOf(key) !== -1 && Object.keys(child).length > 0) {\n if (process.env.NODE_ENV !== 'production') {\n const stateClass = generateUtilityClass('', key);\n console.error([`MUI: The \\`${component}\\` component increases ` + `the CSS specificity of the \\`${key}\\` internal state.`, 'You can not override it like this: ', JSON.stringify(node, null, 2), '', `Instead, you need to use the '&.${stateClass}' syntax:`, JSON.stringify({\n root: {\n [`&.${stateClass}`]: child\n }\n }, null, 2), '', 'https://mui.com/r/state-classes-guide'].join('\\n'));\n }\n // Remove the style to prevent global conflicts.\n node[key] = {};\n }\n }\n };\n Object.keys(muiTheme.components).forEach(component => {\n const styleOverrides = muiTheme.components[component].styleOverrides;\n if (styleOverrides && component.indexOf('Mui') === 0) {\n traverse(styleOverrides, component);\n }\n });\n }\n muiTheme.unstable_sxConfig = _extends({}, defaultSxConfig, other == null ? void 0 : other.unstable_sxConfig);\n muiTheme.unstable_sx = function sx(props) {\n return styleFunctionSx({\n sx: props,\n theme: this\n });\n };\n return muiTheme;\n}\nlet warnedOnce = false;\nexport function createMuiTheme(...args) {\n if (process.env.NODE_ENV !== 'production') {\n if (!warnedOnce) {\n warnedOnce = true;\n console.error(['MUI: the createMuiTheme function was renamed to createTheme.', '', \"You should use `import { createTheme } from '@mui/material/styles'`\"].join('\\n'));\n }\n }\n return createTheme(...args);\n}\nexport default createTheme;","'use client';\n\nimport createTheme from './createTheme';\nconst defaultTheme = createTheme();\nexport default defaultTheme;","export default '$$material';","'use client';\n\nimport { useThemeProps as systemUseThemeProps } from '@mui/system';\nimport defaultTheme from './defaultTheme';\nimport THEME_ID from './identifier';\nexport default function useThemeProps({\n props,\n name\n}) {\n return systemUseThemeProps({\n props,\n name,\n defaultTheme,\n themeId: THEME_ID\n });\n}","'use client';\n\nimport { createStyled, shouldForwardProp } from '@mui/system';\nimport defaultTheme from './defaultTheme';\nimport THEME_ID from './identifier';\nexport const rootShouldForwardProp = prop => shouldForwardProp(prop) && prop !== 'classes';\nexport const slotShouldForwardProp = shouldForwardProp;\nconst styled = createStyled({\n themeId: THEME_ID,\n defaultTheme,\n rootShouldForwardProp\n});\nexport default styled;","import generateUtilityClasses from '@mui/utils/generateUtilityClasses';\nimport generateUtilityClass from '@mui/utils/generateUtilityClass';\nexport function getSvgIconUtilityClass(slot) {\n return generateUtilityClass('MuiSvgIcon', slot);\n}\nconst svgIconClasses = generateUtilityClasses('MuiSvgIcon', ['root', 'colorPrimary', 'colorSecondary', 'colorAction', 'colorError', 'colorDisabled', 'fontSizeInherit', 'fontSizeSmall', 'fontSizeMedium', 'fontSizeLarge']);\nexport default svgIconClasses;","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"children\", \"className\", \"color\", \"component\", \"fontSize\", \"htmlColor\", \"inheritViewBox\", \"titleAccess\", \"viewBox\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport clsx from 'clsx';\nimport { unstable_composeClasses as composeClasses } from '@mui/base/composeClasses';\nimport capitalize from '../utils/capitalize';\nimport useThemeProps from '../styles/useThemeProps';\nimport styled from '../styles/styled';\nimport { getSvgIconUtilityClass } from './svgIconClasses';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nimport { jsxs as _jsxs } from \"react/jsx-runtime\";\nconst useUtilityClasses = ownerState => {\n const {\n color,\n fontSize,\n classes\n } = ownerState;\n const slots = {\n root: ['root', color !== 'inherit' && `color${capitalize(color)}`, `fontSize${capitalize(fontSize)}`]\n };\n return composeClasses(slots, getSvgIconUtilityClass, classes);\n};\nconst SvgIconRoot = styled('svg', {\n name: 'MuiSvgIcon',\n slot: 'Root',\n overridesResolver: (props, styles) => {\n const {\n ownerState\n } = props;\n return [styles.root, ownerState.color !== 'inherit' && styles[`color${capitalize(ownerState.color)}`], styles[`fontSize${capitalize(ownerState.fontSize)}`]];\n }\n})(({\n theme,\n ownerState\n}) => {\n var _theme$transitions, _theme$transitions$cr, _theme$transitions2, _theme$typography, _theme$typography$pxT, _theme$typography2, _theme$typography2$px, _theme$typography3, _theme$typography3$px, _palette$ownerState$c, _palette, _palette2, _palette3;\n return {\n userSelect: 'none',\n width: '1em',\n height: '1em',\n display: 'inline-block',\n // the will define the property that has `currentColor`\n // e.g. heroicons uses fill=\"none\" and stroke=\"currentColor\"\n fill: ownerState.hasSvgAsChild ? undefined : 'currentColor',\n flexShrink: 0,\n transition: (_theme$transitions = theme.transitions) == null || (_theme$transitions$cr = _theme$transitions.create) == null ? void 0 : _theme$transitions$cr.call(_theme$transitions, 'fill', {\n duration: (_theme$transitions2 = theme.transitions) == null || (_theme$transitions2 = _theme$transitions2.duration) == null ? void 0 : _theme$transitions2.shorter\n }),\n fontSize: {\n inherit: 'inherit',\n small: ((_theme$typography = theme.typography) == null || (_theme$typography$pxT = _theme$typography.pxToRem) == null ? void 0 : _theme$typography$pxT.call(_theme$typography, 20)) || '1.25rem',\n medium: ((_theme$typography2 = theme.typography) == null || (_theme$typography2$px = _theme$typography2.pxToRem) == null ? void 0 : _theme$typography2$px.call(_theme$typography2, 24)) || '1.5rem',\n large: ((_theme$typography3 = theme.typography) == null || (_theme$typography3$px = _theme$typography3.pxToRem) == null ? void 0 : _theme$typography3$px.call(_theme$typography3, 35)) || '2.1875rem'\n }[ownerState.fontSize],\n // TODO v5 deprecate, v6 remove for sx\n color: (_palette$ownerState$c = (_palette = (theme.vars || theme).palette) == null || (_palette = _palette[ownerState.color]) == null ? void 0 : _palette.main) != null ? _palette$ownerState$c : {\n action: (_palette2 = (theme.vars || theme).palette) == null || (_palette2 = _palette2.action) == null ? void 0 : _palette2.active,\n disabled: (_palette3 = (theme.vars || theme).palette) == null || (_palette3 = _palette3.action) == null ? void 0 : _palette3.disabled,\n inherit: undefined\n }[ownerState.color]\n };\n});\nconst SvgIcon = /*#__PURE__*/React.forwardRef(function SvgIcon(inProps, ref) {\n const props = useThemeProps({\n props: inProps,\n name: 'MuiSvgIcon'\n });\n const {\n children,\n className,\n color = 'inherit',\n component = 'svg',\n fontSize = 'medium',\n htmlColor,\n inheritViewBox = false,\n titleAccess,\n viewBox = '0 0 24 24'\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const hasSvgAsChild = /*#__PURE__*/React.isValidElement(children) && children.type === 'svg';\n const ownerState = _extends({}, props, {\n color,\n component,\n fontSize,\n instanceFontSize: inProps.fontSize,\n inheritViewBox,\n viewBox,\n hasSvgAsChild\n });\n const more = {};\n if (!inheritViewBox) {\n more.viewBox = viewBox;\n }\n const classes = useUtilityClasses(ownerState);\n return /*#__PURE__*/_jsxs(SvgIconRoot, _extends({\n as: component,\n className: clsx(classes.root, className),\n focusable: \"false\",\n color: htmlColor,\n \"aria-hidden\": titleAccess ? undefined : true,\n role: titleAccess ? 'img' : undefined,\n ref: ref\n }, more, other, hasSvgAsChild && children.props, {\n ownerState: ownerState,\n children: [hasSvgAsChild ? children.props.children : children, titleAccess ? /*#__PURE__*/_jsx(\"title\", {\n children: titleAccess\n }) : null]\n }));\n});\nprocess.env.NODE_ENV !== \"production\" ? SvgIcon.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the d.ts file and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * Node passed into the SVG element.\n */\n children: PropTypes.node,\n /**\n * Override or extend the styles applied to the component.\n */\n classes: PropTypes.object,\n /**\n * @ignore\n */\n className: PropTypes.string,\n /**\n * The color of the component.\n * It supports both default and custom theme colors, which can be added as shown in the\n * [palette customization guide](https://mui.com/material-ui/customization/palette/#custom-colors).\n * You can use the `htmlColor` prop to apply a color attribute to the SVG element.\n * @default 'inherit'\n */\n color: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.oneOf(['inherit', 'action', 'disabled', 'primary', 'secondary', 'error', 'info', 'success', 'warning']), PropTypes.string]),\n /**\n * The component used for the root node.\n * Either a string to use a HTML element or a component.\n */\n component: PropTypes.elementType,\n /**\n * The fontSize applied to the icon. Defaults to 24px, but can be configure to inherit font size.\n * @default 'medium'\n */\n fontSize: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.oneOf(['inherit', 'large', 'medium', 'small']), PropTypes.string]),\n /**\n * Applies a color attribute to the SVG element.\n */\n htmlColor: PropTypes.string,\n /**\n * If `true`, the root node will inherit the custom `component`'s viewBox and the `viewBox`\n * prop will be ignored.\n * Useful when you want to reference a custom `component` and have `SvgIcon` pass that\n * `component`'s viewBox to the root node.\n * @default false\n */\n inheritViewBox: PropTypes.bool,\n /**\n * The shape-rendering attribute. The behavior of the different options is described on the\n * [MDN Web Docs](https://developer.mozilla.org/en-US/docs/Web/SVG/Attribute/shape-rendering).\n * If you are having issues with blurry icons you should investigate this prop.\n */\n shapeRendering: PropTypes.string,\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Provides a human-readable title for the element that contains it.\n * https://www.w3.org/TR/SVG-access/#Equivalent\n */\n titleAccess: PropTypes.string,\n /**\n * Allows you to redefine what the coordinates without units mean inside an SVG element.\n * For example, if the SVG element is 500 (width) by 200 (height),\n * and you pass viewBox=\"0 0 50 20\",\n * this means that the coordinates inside the SVG will go from the top left corner (0,0)\n * to bottom right (50,20) and each unit will be worth 10px.\n * @default '0 0 24 24'\n */\n viewBox: PropTypes.string\n} : void 0;\nSvgIcon.muiName = 'SvgIcon';\nexport default SvgIcon;","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport * as React from 'react';\nimport SvgIcon from '../SvgIcon';\n\n/**\n * Private module reserved for @mui packages.\n */\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nexport default function createSvgIcon(path, displayName) {\n function Component(props, ref) {\n return /*#__PURE__*/_jsx(SvgIcon, _extends({\n \"data-testid\": `${displayName}Icon`,\n ref: ref\n }, props, {\n children: path\n }));\n }\n if (process.env.NODE_ENV !== 'production') {\n // Need to set `displayName` on the inner component for React.memo.\n // React prior to 16.14 ignores `displayName` on the wrapper.\n Component.displayName = `${displayName}Icon`;\n }\n Component.muiName = SvgIcon.muiName;\n return /*#__PURE__*/React.memo( /*#__PURE__*/React.forwardRef(Component));\n}","'use client';\n\nimport { unstable_ClassNameGenerator as ClassNameGenerator } from '@mui/base/ClassNameGenerator';\nexport { default as capitalize } from './capitalize';\nexport { default as createChainedFunction } from './createChainedFunction';\nexport { default as createSvgIcon } from './createSvgIcon';\nexport { default as debounce } from './debounce';\nexport { default as deprecatedPropType } from './deprecatedPropType';\nexport { default as isMuiElement } from './isMuiElement';\nexport { default as ownerDocument } from './ownerDocument';\nexport { default as ownerWindow } from './ownerWindow';\nexport { default as requirePropFactory } from './requirePropFactory';\nexport { default as setRef } from './setRef';\nexport { default as unstable_useEnhancedEffect } from './useEnhancedEffect';\nexport { default as unstable_useId } from './useId';\nexport { default as unsupportedProp } from './unsupportedProp';\nexport { default as useControlled } from './useControlled';\nexport { default as useEventCallback } from './useEventCallback';\nexport { default as useForkRef } from './useForkRef';\nexport { default as useIsFocusVisible } from './useIsFocusVisible';\n// TODO: remove this export once ClassNameGenerator is stable\n// eslint-disable-next-line @typescript-eslint/naming-convention\nexport const unstable_ClassNameGenerator = {\n configure: generator => {\n if (process.env.NODE_ENV !== 'production') {\n console.warn(['MUI: `ClassNameGenerator` import from `@mui/material/utils` is outdated and might cause unexpected issues.', '', \"You should use `import { unstable_ClassNameGenerator } from '@mui/material/className'` instead\", '', 'The detail of the issue: https://github.com/mui/material-ui/issues/30011#issuecomment-1024993401', '', 'The updated documentation: https://mui.com/guides/classname-generator/'].join('\\n'));\n }\n ClassNameGenerator.configure(generator);\n }\n};","\"use strict\";\n'use client';\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nObject.defineProperty(exports, \"default\", {\n enumerable: true,\n get: function () {\n return _utils.createSvgIcon;\n }\n});\nvar _utils = require(\"@mui/material/utils\");","\"use strict\";\n\"use client\";\n\nvar _interopRequireDefault = require(\"@babel/runtime/helpers/interopRequireDefault\");\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = void 0;\nvar _createSvgIcon = _interopRequireDefault(require(\"./utils/createSvgIcon\"));\nvar _jsxRuntime = require(\"react/jsx-runtime\");\nvar _default = exports.default = (0, _createSvgIcon.default)( /*#__PURE__*/(0, _jsxRuntime.jsx)(\"path\", {\n d: \"m10 17 5-5-5-5z\"\n}), 'ArrowRight');","/**\n * Determines if a given element is a DOM element name (i.e. not a React component).\n */\nexport function isHostComponent(element) {\n return typeof element === 'string';\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport { isHostComponent } from './isHostComponent';\n\n/**\n * Type of the ownerState based on the type of an element it applies to.\n * This resolves to the provided OwnerState for React components and `undefined` for host components.\n * Falls back to `OwnerState | undefined` when the exact type can't be determined in development time.\n */\n\n/**\n * Appends the ownerState object to the props, merging with the existing one if necessary.\n *\n * @param elementType Type of the element that owns the `existingProps`. If the element is a DOM node or undefined, `ownerState` is not applied.\n * @param otherProps Props of the element.\n * @param ownerState\n */\nexport function appendOwnerState(elementType, otherProps, ownerState) {\n if (elementType === undefined || isHostComponent(elementType)) {\n return otherProps;\n }\n return _extends({}, otherProps, {\n ownerState: _extends({}, otherProps.ownerState, ownerState)\n });\n}","'use client';\n\nimport * as React from 'react';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nconst defaultContextValue = {\n disableDefaultClasses: false\n};\nconst ClassNameConfiguratorContext = /*#__PURE__*/React.createContext(defaultContextValue);\n/**\n * @ignore - internal hook.\n *\n * Wraps the `generateUtilityClass` function and controls how the classes are generated.\n * Currently it only affects whether the classes are applied or not.\n *\n * @returns Function to be called with the `generateUtilityClass` function specific to a component to generate the classes.\n */\nexport function useClassNamesOverride(generateUtilityClass) {\n const {\n disableDefaultClasses\n } = React.useContext(ClassNameConfiguratorContext);\n return slot => {\n if (disableDefaultClasses) {\n return '';\n }\n return generateUtilityClass(slot);\n };\n}\n\n/**\n * Allows to configure the components within to not apply any built-in classes.\n */\nexport function ClassNameConfigurator(props) {\n const {\n disableDefaultClasses,\n children\n } = props;\n const contextValue = React.useMemo(() => ({\n disableDefaultClasses: disableDefaultClasses != null ? disableDefaultClasses : false\n }), [disableDefaultClasses]);\n return /*#__PURE__*/_jsx(ClassNameConfiguratorContext.Provider, {\n value: contextValue,\n children: children\n });\n}","/**\n * Extracts event handlers from a given object.\n * A prop is considered an event handler if it is a function and its name starts with `on`.\n *\n * @param object An object to extract event handlers from.\n * @param excludeKeys An array of keys to exclude from the returned object.\n */\nexport function extractEventHandlers(object, excludeKeys = []) {\n if (object === undefined) {\n return {};\n }\n const result = {};\n Object.keys(object).filter(prop => prop.match(/^on[A-Z]/) && typeof object[prop] === 'function' && !excludeKeys.includes(prop)).forEach(prop => {\n result[prop] = object[prop];\n });\n return result;\n}","/**\n * If `componentProps` is a function, calls it with the provided `ownerState`.\n * Otherwise, just returns `componentProps`.\n */\nexport function resolveComponentProps(componentProps, ownerState, slotState) {\n if (typeof componentProps === 'function') {\n return componentProps(ownerState, slotState);\n }\n return componentProps;\n}","/**\n * Removes event handlers from the given object.\n * A field is considered an event handler if it is a function with a name beginning with `on`.\n *\n * @param object Object to remove event handlers from.\n * @returns Object with event handlers removed.\n */\nexport function omitEventHandlers(object) {\n if (object === undefined) {\n return {};\n }\n const result = {};\n Object.keys(object).filter(prop => !(prop.match(/^on[A-Z]/) && typeof object[prop] === 'function')).forEach(prop => {\n result[prop] = object[prop];\n });\n return result;\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport clsx from 'clsx';\nimport { extractEventHandlers } from './extractEventHandlers';\nimport { omitEventHandlers } from './omitEventHandlers';\n/**\n * Merges the slot component internal props (usually coming from a hook)\n * with the externally provided ones.\n *\n * The merge order is (the latter overrides the former):\n * 1. The internal props (specified as a getter function to work with get*Props hook result)\n * 2. Additional props (specified internally on a Base UI component)\n * 3. External props specified on the owner component. These should only be used on a root slot.\n * 4. External props specified in the `slotProps.*` prop.\n * 5. The `className` prop - combined from all the above.\n * @param parameters\n * @returns\n */\nexport function mergeSlotProps(parameters) {\n const {\n getSlotProps,\n additionalProps,\n externalSlotProps,\n externalForwardedProps,\n className\n } = parameters;\n if (!getSlotProps) {\n // The simpler case - getSlotProps is not defined, so no internal event handlers are defined,\n // so we can simply merge all the props without having to worry about extracting event handlers.\n const joinedClasses = clsx(additionalProps == null ? void 0 : additionalProps.className, className, externalForwardedProps == null ? void 0 : externalForwardedProps.className, externalSlotProps == null ? void 0 : externalSlotProps.className);\n const mergedStyle = _extends({}, additionalProps == null ? void 0 : additionalProps.style, externalForwardedProps == null ? void 0 : externalForwardedProps.style, externalSlotProps == null ? void 0 : externalSlotProps.style);\n const props = _extends({}, additionalProps, externalForwardedProps, externalSlotProps);\n if (joinedClasses.length > 0) {\n props.className = joinedClasses;\n }\n if (Object.keys(mergedStyle).length > 0) {\n props.style = mergedStyle;\n }\n return {\n props,\n internalRef: undefined\n };\n }\n\n // In this case, getSlotProps is responsible for calling the external event handlers.\n // We don't need to include them in the merged props because of this.\n\n const eventHandlers = extractEventHandlers(_extends({}, externalForwardedProps, externalSlotProps));\n const componentsPropsWithoutEventHandlers = omitEventHandlers(externalSlotProps);\n const otherPropsWithoutEventHandlers = omitEventHandlers(externalForwardedProps);\n const internalSlotProps = getSlotProps(eventHandlers);\n\n // The order of classes is important here.\n // Emotion (that we use in libraries consuming Base UI) depends on this order\n // to properly override style. It requires the most important classes to be last\n // (see https://github.com/mui/material-ui/pull/33205) for the related discussion.\n const joinedClasses = clsx(internalSlotProps == null ? void 0 : internalSlotProps.className, additionalProps == null ? void 0 : additionalProps.className, className, externalForwardedProps == null ? void 0 : externalForwardedProps.className, externalSlotProps == null ? void 0 : externalSlotProps.className);\n const mergedStyle = _extends({}, internalSlotProps == null ? void 0 : internalSlotProps.style, additionalProps == null ? void 0 : additionalProps.style, externalForwardedProps == null ? void 0 : externalForwardedProps.style, externalSlotProps == null ? void 0 : externalSlotProps.style);\n const props = _extends({}, internalSlotProps, additionalProps, otherPropsWithoutEventHandlers, componentsPropsWithoutEventHandlers);\n if (joinedClasses.length > 0) {\n props.className = joinedClasses;\n }\n if (Object.keys(mergedStyle).length > 0) {\n props.style = mergedStyle;\n }\n return {\n props,\n internalRef: internalSlotProps.ref\n };\n}","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"elementType\", \"externalSlotProps\", \"ownerState\", \"skipResolvingSlotProps\"];\nimport { unstable_useForkRef as useForkRef } from '@mui/utils';\nimport { appendOwnerState } from './appendOwnerState';\nimport { mergeSlotProps } from './mergeSlotProps';\nimport { resolveComponentProps } from './resolveComponentProps';\n/**\n * @ignore - do not document.\n * Builds the props to be passed into the slot of an unstyled component.\n * It merges the internal props of the component with the ones supplied by the user, allowing to customize the behavior.\n * If the slot component is not a host component, it also merges in the `ownerState`.\n *\n * @param parameters.getSlotProps - A function that returns the props to be passed to the slot component.\n */\nexport function useSlotProps(parameters) {\n var _parameters$additiona;\n const {\n elementType,\n externalSlotProps,\n ownerState,\n skipResolvingSlotProps = false\n } = parameters,\n rest = _objectWithoutPropertiesLoose(parameters, _excluded);\n const resolvedComponentsProps = skipResolvingSlotProps ? {} : resolveComponentProps(externalSlotProps, ownerState);\n const {\n props: mergedProps,\n internalRef\n } = mergeSlotProps(_extends({}, rest, {\n externalSlotProps: resolvedComponentsProps\n }));\n const ref = useForkRef(internalRef, resolvedComponentsProps == null ? void 0 : resolvedComponentsProps.ref, (_parameters$additiona = parameters.additionalProps) == null ? void 0 : _parameters$additiona.ref);\n const props = appendOwnerState(elementType, _extends({}, mergedProps, {\n ref\n }), ownerState);\n return props;\n}","import { globalStateClasses } from '@mui/utils/generateUtilityClass';\nconst GLOBAL_CLASS_PREFIX = 'base';\nfunction buildStateClass(state) {\n return `${GLOBAL_CLASS_PREFIX}--${state}`;\n}\nfunction buildSlotClass(componentName, slot) {\n return `${GLOBAL_CLASS_PREFIX}-${componentName}-${slot}`;\n}\nexport function generateUtilityClass(componentName, slot) {\n const globalStateClass = globalStateClasses[slot];\n return globalStateClass ? buildStateClass(globalStateClass) : buildSlotClass(componentName, slot);\n}\nexport function isGlobalState(slot) {\n return globalStateClasses[slot] !== undefined;\n}","import { generateUtilityClass } from '../generateUtilityClass';\nexport function generateUtilityClasses(componentName, slots) {\n const result = {};\n slots.forEach(slot => {\n result[slot] = generateUtilityClass(componentName, slot);\n });\n return result;\n}","'use client';\n\nimport * as React from 'react';\nimport * as ReactDOM from 'react-dom';\nimport PropTypes from 'prop-types';\nimport { exactProp, HTMLElementType, unstable_useEnhancedEffect as useEnhancedEffect, unstable_useForkRef as useForkRef, unstable_setRef as setRef } from '@mui/utils';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nfunction getContainer(container) {\n return typeof container === 'function' ? container() : container;\n}\n\n/**\n * Portals provide a first-class way to render children into a DOM node\n * that exists outside the DOM hierarchy of the parent component.\n *\n * Demos:\n *\n * - [Portal](https://mui.com/base-ui/react-portal/)\n *\n * API:\n *\n * - [Portal API](https://mui.com/base-ui/react-portal/components-api/#portal)\n */\nconst Portal = /*#__PURE__*/React.forwardRef(function Portal(props, forwardedRef) {\n const {\n children,\n container,\n disablePortal = false\n } = props;\n const [mountNode, setMountNode] = React.useState(null);\n // @ts-expect-error TODO upstream fix\n const handleRef = useForkRef( /*#__PURE__*/React.isValidElement(children) ? children.ref : null, forwardedRef);\n useEnhancedEffect(() => {\n if (!disablePortal) {\n setMountNode(getContainer(container) || document.body);\n }\n }, [container, disablePortal]);\n useEnhancedEffect(() => {\n if (mountNode && !disablePortal) {\n setRef(forwardedRef, mountNode);\n return () => {\n setRef(forwardedRef, null);\n };\n }\n return undefined;\n }, [forwardedRef, mountNode, disablePortal]);\n if (disablePortal) {\n if ( /*#__PURE__*/React.isValidElement(children)) {\n const newProps = {\n ref: handleRef\n };\n return /*#__PURE__*/React.cloneElement(children, newProps);\n }\n return /*#__PURE__*/_jsx(React.Fragment, {\n children: children\n });\n }\n return /*#__PURE__*/_jsx(React.Fragment, {\n children: mountNode ? /*#__PURE__*/ReactDOM.createPortal(children, mountNode) : mountNode\n });\n});\nprocess.env.NODE_ENV !== \"production\" ? Portal.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * The children to render into the `container`.\n */\n children: PropTypes.node,\n /**\n * An HTML element or function that returns one.\n * The `container` will have the portal children appended to it.\n *\n * You can also provide a callback, which is called in a React layout effect.\n * This lets you set the container from a ref, and also makes server-side rendering possible.\n *\n * By default, it uses the body of the top-level document object,\n * so it's simply `document.body` most of the time.\n */\n container: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.func]),\n /**\n * The `children` will be under the DOM hierarchy of the parent component.\n * @default false\n */\n disablePortal: PropTypes.bool\n} : void 0;\nif (process.env.NODE_ENV !== 'production') {\n // eslint-disable-next-line\n Portal['propTypes' + ''] = exactProp(Portal.propTypes);\n}\nexport { Portal };","export var top = 'top';\nexport var bottom = 'bottom';\nexport var right = 'right';\nexport var left = 'left';\nexport var auto = 'auto';\nexport var basePlacements = [top, bottom, right, left];\nexport var start = 'start';\nexport var end = 'end';\nexport var clippingParents = 'clippingParents';\nexport var viewport = 'viewport';\nexport var popper = 'popper';\nexport var reference = 'reference';\nexport var variationPlacements = /*#__PURE__*/basePlacements.reduce(function (acc, placement) {\n return acc.concat([placement + \"-\" + start, placement + \"-\" + end]);\n}, []);\nexport var placements = /*#__PURE__*/[].concat(basePlacements, [auto]).reduce(function (acc, placement) {\n return acc.concat([placement, placement + \"-\" + start, placement + \"-\" + end]);\n}, []); // modifiers that need to read the DOM\n\nexport var beforeRead = 'beforeRead';\nexport var read = 'read';\nexport var afterRead = 'afterRead'; // pure-logic modifiers\n\nexport var beforeMain = 'beforeMain';\nexport var main = 'main';\nexport var afterMain = 'afterMain'; // modifier with the purpose to write to the DOM (or write into a framework state)\n\nexport var beforeWrite = 'beforeWrite';\nexport var write = 'write';\nexport var afterWrite = 'afterWrite';\nexport var modifierPhases = [beforeRead, read, afterRead, beforeMain, main, afterMain, beforeWrite, write, afterWrite];","export default function getNodeName(element) {\n return element ? (element.nodeName || '').toLowerCase() : null;\n}","export default function getWindow(node) {\n if (node == null) {\n return window;\n }\n\n if (node.toString() !== '[object Window]') {\n var ownerDocument = node.ownerDocument;\n return ownerDocument ? ownerDocument.defaultView || window : window;\n }\n\n return node;\n}","import getWindow from \"./getWindow.js\";\n\nfunction isElement(node) {\n var OwnElement = getWindow(node).Element;\n return node instanceof OwnElement || node instanceof Element;\n}\n\nfunction isHTMLElement(node) {\n var OwnElement = getWindow(node).HTMLElement;\n return node instanceof OwnElement || node instanceof HTMLElement;\n}\n\nfunction isShadowRoot(node) {\n // IE 11 has no ShadowRoot\n if (typeof ShadowRoot === 'undefined') {\n return false;\n }\n\n var OwnElement = getWindow(node).ShadowRoot;\n return node instanceof OwnElement || node instanceof ShadowRoot;\n}\n\nexport { isElement, isHTMLElement, isShadowRoot };","import getNodeName from \"../dom-utils/getNodeName.js\";\nimport { isHTMLElement } from \"../dom-utils/instanceOf.js\"; // This modifier takes the styles prepared by the `computeStyles` modifier\n// and applies them to the HTMLElements such as popper and arrow\n\nfunction applyStyles(_ref) {\n var state = _ref.state;\n Object.keys(state.elements).forEach(function (name) {\n var style = state.styles[name] || {};\n var attributes = state.attributes[name] || {};\n var element = state.elements[name]; // arrow is optional + virtual elements\n\n if (!isHTMLElement(element) || !getNodeName(element)) {\n return;\n } // Flow doesn't support to extend this property, but it's the most\n // effective way to apply styles to an HTMLElement\n // $FlowFixMe[cannot-write]\n\n\n Object.assign(element.style, style);\n Object.keys(attributes).forEach(function (name) {\n var value = attributes[name];\n\n if (value === false) {\n element.removeAttribute(name);\n } else {\n element.setAttribute(name, value === true ? '' : value);\n }\n });\n });\n}\n\nfunction effect(_ref2) {\n var state = _ref2.state;\n var initialStyles = {\n popper: {\n position: state.options.strategy,\n left: '0',\n top: '0',\n margin: '0'\n },\n arrow: {\n position: 'absolute'\n },\n reference: {}\n };\n Object.assign(state.elements.popper.style, initialStyles.popper);\n state.styles = initialStyles;\n\n if (state.elements.arrow) {\n Object.assign(state.elements.arrow.style, initialStyles.arrow);\n }\n\n return function () {\n Object.keys(state.elements).forEach(function (name) {\n var element = state.elements[name];\n var attributes = state.attributes[name] || {};\n var styleProperties = Object.keys(state.styles.hasOwnProperty(name) ? state.styles[name] : initialStyles[name]); // Set all values to an empty string to unset them\n\n var style = styleProperties.reduce(function (style, property) {\n style[property] = '';\n return style;\n }, {}); // arrow is optional + virtual elements\n\n if (!isHTMLElement(element) || !getNodeName(element)) {\n return;\n }\n\n Object.assign(element.style, style);\n Object.keys(attributes).forEach(function (attribute) {\n element.removeAttribute(attribute);\n });\n });\n };\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'applyStyles',\n enabled: true,\n phase: 'write',\n fn: applyStyles,\n effect: effect,\n requires: ['computeStyles']\n};","import { auto } from \"../enums.js\";\nexport default function getBasePlacement(placement) {\n return placement.split('-')[0];\n}","export var max = Math.max;\nexport var min = Math.min;\nexport var round = Math.round;","export default function getUAString() {\n var uaData = navigator.userAgentData;\n\n if (uaData != null && uaData.brands && Array.isArray(uaData.brands)) {\n return uaData.brands.map(function (item) {\n return item.brand + \"/\" + item.version;\n }).join(' ');\n }\n\n return navigator.userAgent;\n}","import getUAString from \"../utils/userAgent.js\";\nexport default function isLayoutViewport() {\n return !/^((?!chrome|android).)*safari/i.test(getUAString());\n}","import { isElement, isHTMLElement } from \"./instanceOf.js\";\nimport { round } from \"../utils/math.js\";\nimport getWindow from \"./getWindow.js\";\nimport isLayoutViewport from \"./isLayoutViewport.js\";\nexport default function getBoundingClientRect(element, includeScale, isFixedStrategy) {\n if (includeScale === void 0) {\n includeScale = false;\n }\n\n if (isFixedStrategy === void 0) {\n isFixedStrategy = false;\n }\n\n var clientRect = element.getBoundingClientRect();\n var scaleX = 1;\n var scaleY = 1;\n\n if (includeScale && isHTMLElement(element)) {\n scaleX = element.offsetWidth > 0 ? round(clientRect.width) / element.offsetWidth || 1 : 1;\n scaleY = element.offsetHeight > 0 ? round(clientRect.height) / element.offsetHeight || 1 : 1;\n }\n\n var _ref = isElement(element) ? getWindow(element) : window,\n visualViewport = _ref.visualViewport;\n\n var addVisualOffsets = !isLayoutViewport() && isFixedStrategy;\n var x = (clientRect.left + (addVisualOffsets && visualViewport ? visualViewport.offsetLeft : 0)) / scaleX;\n var y = (clientRect.top + (addVisualOffsets && visualViewport ? visualViewport.offsetTop : 0)) / scaleY;\n var width = clientRect.width / scaleX;\n var height = clientRect.height / scaleY;\n return {\n width: width,\n height: height,\n top: y,\n right: x + width,\n bottom: y + height,\n left: x,\n x: x,\n y: y\n };\n}","import getBoundingClientRect from \"./getBoundingClientRect.js\"; // Returns the layout rect of an element relative to its offsetParent. Layout\n// means it doesn't take into account transforms.\n\nexport default function getLayoutRect(element) {\n var clientRect = getBoundingClientRect(element); // Use the clientRect sizes if it's not been transformed.\n // Fixes https://github.com/popperjs/popper-core/issues/1223\n\n var width = element.offsetWidth;\n var height = element.offsetHeight;\n\n if (Math.abs(clientRect.width - width) <= 1) {\n width = clientRect.width;\n }\n\n if (Math.abs(clientRect.height - height) <= 1) {\n height = clientRect.height;\n }\n\n return {\n x: element.offsetLeft,\n y: element.offsetTop,\n width: width,\n height: height\n };\n}","import { isShadowRoot } from \"./instanceOf.js\";\nexport default function contains(parent, child) {\n var rootNode = child.getRootNode && child.getRootNode(); // First, attempt with faster native method\n\n if (parent.contains(child)) {\n return true;\n } // then fallback to custom implementation with Shadow DOM support\n else if (rootNode && isShadowRoot(rootNode)) {\n var next = child;\n\n do {\n if (next && parent.isSameNode(next)) {\n return true;\n } // $FlowFixMe[prop-missing]: need a better way to handle this...\n\n\n next = next.parentNode || next.host;\n } while (next);\n } // Give up, the result is false\n\n\n return false;\n}","import getWindow from \"./getWindow.js\";\nexport default function getComputedStyle(element) {\n return getWindow(element).getComputedStyle(element);\n}","import getNodeName from \"./getNodeName.js\";\nexport default function isTableElement(element) {\n return ['table', 'td', 'th'].indexOf(getNodeName(element)) >= 0;\n}","import { isElement } from \"./instanceOf.js\";\nexport default function getDocumentElement(element) {\n // $FlowFixMe[incompatible-return]: assume body is always available\n return ((isElement(element) ? element.ownerDocument : // $FlowFixMe[prop-missing]\n element.document) || window.document).documentElement;\n}","import getNodeName from \"./getNodeName.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport { isShadowRoot } from \"./instanceOf.js\";\nexport default function getParentNode(element) {\n if (getNodeName(element) === 'html') {\n return element;\n }\n\n return (// this is a quicker (but less type safe) way to save quite some bytes from the bundle\n // $FlowFixMe[incompatible-return]\n // $FlowFixMe[prop-missing]\n element.assignedSlot || // step into the shadow DOM of the parent of a slotted node\n element.parentNode || ( // DOM Element detected\n isShadowRoot(element) ? element.host : null) || // ShadowRoot detected\n // $FlowFixMe[incompatible-call]: HTMLElement is a Node\n getDocumentElement(element) // fallback\n\n );\n}","import getWindow from \"./getWindow.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport getComputedStyle from \"./getComputedStyle.js\";\nimport { isHTMLElement, isShadowRoot } from \"./instanceOf.js\";\nimport isTableElement from \"./isTableElement.js\";\nimport getParentNode from \"./getParentNode.js\";\nimport getUAString from \"../utils/userAgent.js\";\n\nfunction getTrueOffsetParent(element) {\n if (!isHTMLElement(element) || // https://github.com/popperjs/popper-core/issues/837\n getComputedStyle(element).position === 'fixed') {\n return null;\n }\n\n return element.offsetParent;\n} // `.offsetParent` reports `null` for fixed elements, while absolute elements\n// return the containing block\n\n\nfunction getContainingBlock(element) {\n var isFirefox = /firefox/i.test(getUAString());\n var isIE = /Trident/i.test(getUAString());\n\n if (isIE && isHTMLElement(element)) {\n // In IE 9, 10 and 11 fixed elements containing block is always established by the viewport\n var elementCss = getComputedStyle(element);\n\n if (elementCss.position === 'fixed') {\n return null;\n }\n }\n\n var currentNode = getParentNode(element);\n\n if (isShadowRoot(currentNode)) {\n currentNode = currentNode.host;\n }\n\n while (isHTMLElement(currentNode) && ['html', 'body'].indexOf(getNodeName(currentNode)) < 0) {\n var css = getComputedStyle(currentNode); // This is non-exhaustive but covers the most common CSS properties that\n // create a containing block.\n // https://developer.mozilla.org/en-US/docs/Web/CSS/Containing_block#identifying_the_containing_block\n\n if (css.transform !== 'none' || css.perspective !== 'none' || css.contain === 'paint' || ['transform', 'perspective'].indexOf(css.willChange) !== -1 || isFirefox && css.willChange === 'filter' || isFirefox && css.filter && css.filter !== 'none') {\n return currentNode;\n } else {\n currentNode = currentNode.parentNode;\n }\n }\n\n return null;\n} // Gets the closest ancestor positioned element. Handles some edge cases,\n// such as table ancestors and cross browser bugs.\n\n\nexport default function getOffsetParent(element) {\n var window = getWindow(element);\n var offsetParent = getTrueOffsetParent(element);\n\n while (offsetParent && isTableElement(offsetParent) && getComputedStyle(offsetParent).position === 'static') {\n offsetParent = getTrueOffsetParent(offsetParent);\n }\n\n if (offsetParent && (getNodeName(offsetParent) === 'html' || getNodeName(offsetParent) === 'body' && getComputedStyle(offsetParent).position === 'static')) {\n return window;\n }\n\n return offsetParent || getContainingBlock(element) || window;\n}","export default function getMainAxisFromPlacement(placement) {\n return ['top', 'bottom'].indexOf(placement) >= 0 ? 'x' : 'y';\n}","import { max as mathMax, min as mathMin } from \"./math.js\";\nexport function within(min, value, max) {\n return mathMax(min, mathMin(value, max));\n}\nexport function withinMaxClamp(min, value, max) {\n var v = within(min, value, max);\n return v > max ? max : v;\n}","export default function getFreshSideObject() {\n return {\n top: 0,\n right: 0,\n bottom: 0,\n left: 0\n };\n}","import getFreshSideObject from \"./getFreshSideObject.js\";\nexport default function mergePaddingObject(paddingObject) {\n return Object.assign({}, getFreshSideObject(), paddingObject);\n}","export default function expandToHashMap(value, keys) {\n return keys.reduce(function (hashMap, key) {\n hashMap[key] = value;\n return hashMap;\n }, {});\n}","import getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getLayoutRect from \"../dom-utils/getLayoutRect.js\";\nimport contains from \"../dom-utils/contains.js\";\nimport getOffsetParent from \"../dom-utils/getOffsetParent.js\";\nimport getMainAxisFromPlacement from \"../utils/getMainAxisFromPlacement.js\";\nimport { within } from \"../utils/within.js\";\nimport mergePaddingObject from \"../utils/mergePaddingObject.js\";\nimport expandToHashMap from \"../utils/expandToHashMap.js\";\nimport { left, right, basePlacements, top, bottom } from \"../enums.js\"; // eslint-disable-next-line import/no-unused-modules\n\nvar toPaddingObject = function toPaddingObject(padding, state) {\n padding = typeof padding === 'function' ? padding(Object.assign({}, state.rects, {\n placement: state.placement\n })) : padding;\n return mergePaddingObject(typeof padding !== 'number' ? padding : expandToHashMap(padding, basePlacements));\n};\n\nfunction arrow(_ref) {\n var _state$modifiersData$;\n\n var state = _ref.state,\n name = _ref.name,\n options = _ref.options;\n var arrowElement = state.elements.arrow;\n var popperOffsets = state.modifiersData.popperOffsets;\n var basePlacement = getBasePlacement(state.placement);\n var axis = getMainAxisFromPlacement(basePlacement);\n var isVertical = [left, right].indexOf(basePlacement) >= 0;\n var len = isVertical ? 'height' : 'width';\n\n if (!arrowElement || !popperOffsets) {\n return;\n }\n\n var paddingObject = toPaddingObject(options.padding, state);\n var arrowRect = getLayoutRect(arrowElement);\n var minProp = axis === 'y' ? top : left;\n var maxProp = axis === 'y' ? bottom : right;\n var endDiff = state.rects.reference[len] + state.rects.reference[axis] - popperOffsets[axis] - state.rects.popper[len];\n var startDiff = popperOffsets[axis] - state.rects.reference[axis];\n var arrowOffsetParent = getOffsetParent(arrowElement);\n var clientSize = arrowOffsetParent ? axis === 'y' ? arrowOffsetParent.clientHeight || 0 : arrowOffsetParent.clientWidth || 0 : 0;\n var centerToReference = endDiff / 2 - startDiff / 2; // Make sure the arrow doesn't overflow the popper if the center point is\n // outside of the popper bounds\n\n var min = paddingObject[minProp];\n var max = clientSize - arrowRect[len] - paddingObject[maxProp];\n var center = clientSize / 2 - arrowRect[len] / 2 + centerToReference;\n var offset = within(min, center, max); // Prevents breaking syntax highlighting...\n\n var axisProp = axis;\n state.modifiersData[name] = (_state$modifiersData$ = {}, _state$modifiersData$[axisProp] = offset, _state$modifiersData$.centerOffset = offset - center, _state$modifiersData$);\n}\n\nfunction effect(_ref2) {\n var state = _ref2.state,\n options = _ref2.options;\n var _options$element = options.element,\n arrowElement = _options$element === void 0 ? '[data-popper-arrow]' : _options$element;\n\n if (arrowElement == null) {\n return;\n } // CSS selector\n\n\n if (typeof arrowElement === 'string') {\n arrowElement = state.elements.popper.querySelector(arrowElement);\n\n if (!arrowElement) {\n return;\n }\n }\n\n if (!contains(state.elements.popper, arrowElement)) {\n return;\n }\n\n state.elements.arrow = arrowElement;\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'arrow',\n enabled: true,\n phase: 'main',\n fn: arrow,\n effect: effect,\n requires: ['popperOffsets'],\n requiresIfExists: ['preventOverflow']\n};","export default function getVariation(placement) {\n return placement.split('-')[1];\n}","import { top, left, right, bottom, end } from \"../enums.js\";\nimport getOffsetParent from \"../dom-utils/getOffsetParent.js\";\nimport getWindow from \"../dom-utils/getWindow.js\";\nimport getDocumentElement from \"../dom-utils/getDocumentElement.js\";\nimport getComputedStyle from \"../dom-utils/getComputedStyle.js\";\nimport getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getVariation from \"../utils/getVariation.js\";\nimport { round } from \"../utils/math.js\"; // eslint-disable-next-line import/no-unused-modules\n\nvar unsetSides = {\n top: 'auto',\n right: 'auto',\n bottom: 'auto',\n left: 'auto'\n}; // Round the offsets to the nearest suitable subpixel based on the DPR.\n// Zooming can change the DPR, but it seems to report a value that will\n// cleanly divide the values into the appropriate subpixels.\n\nfunction roundOffsetsByDPR(_ref, win) {\n var x = _ref.x,\n y = _ref.y;\n var dpr = win.devicePixelRatio || 1;\n return {\n x: round(x * dpr) / dpr || 0,\n y: round(y * dpr) / dpr || 0\n };\n}\n\nexport function mapToStyles(_ref2) {\n var _Object$assign2;\n\n var popper = _ref2.popper,\n popperRect = _ref2.popperRect,\n placement = _ref2.placement,\n variation = _ref2.variation,\n offsets = _ref2.offsets,\n position = _ref2.position,\n gpuAcceleration = _ref2.gpuAcceleration,\n adaptive = _ref2.adaptive,\n roundOffsets = _ref2.roundOffsets,\n isFixed = _ref2.isFixed;\n var _offsets$x = offsets.x,\n x = _offsets$x === void 0 ? 0 : _offsets$x,\n _offsets$y = offsets.y,\n y = _offsets$y === void 0 ? 0 : _offsets$y;\n\n var _ref3 = typeof roundOffsets === 'function' ? roundOffsets({\n x: x,\n y: y\n }) : {\n x: x,\n y: y\n };\n\n x = _ref3.x;\n y = _ref3.y;\n var hasX = offsets.hasOwnProperty('x');\n var hasY = offsets.hasOwnProperty('y');\n var sideX = left;\n var sideY = top;\n var win = window;\n\n if (adaptive) {\n var offsetParent = getOffsetParent(popper);\n var heightProp = 'clientHeight';\n var widthProp = 'clientWidth';\n\n if (offsetParent === getWindow(popper)) {\n offsetParent = getDocumentElement(popper);\n\n if (getComputedStyle(offsetParent).position !== 'static' && position === 'absolute') {\n heightProp = 'scrollHeight';\n widthProp = 'scrollWidth';\n }\n } // $FlowFixMe[incompatible-cast]: force type refinement, we compare offsetParent with window above, but Flow doesn't detect it\n\n\n offsetParent = offsetParent;\n\n if (placement === top || (placement === left || placement === right) && variation === end) {\n sideY = bottom;\n var offsetY = isFixed && offsetParent === win && win.visualViewport ? win.visualViewport.height : // $FlowFixMe[prop-missing]\n offsetParent[heightProp];\n y -= offsetY - popperRect.height;\n y *= gpuAcceleration ? 1 : -1;\n }\n\n if (placement === left || (placement === top || placement === bottom) && variation === end) {\n sideX = right;\n var offsetX = isFixed && offsetParent === win && win.visualViewport ? win.visualViewport.width : // $FlowFixMe[prop-missing]\n offsetParent[widthProp];\n x -= offsetX - popperRect.width;\n x *= gpuAcceleration ? 1 : -1;\n }\n }\n\n var commonStyles = Object.assign({\n position: position\n }, adaptive && unsetSides);\n\n var _ref4 = roundOffsets === true ? roundOffsetsByDPR({\n x: x,\n y: y\n }, getWindow(popper)) : {\n x: x,\n y: y\n };\n\n x = _ref4.x;\n y = _ref4.y;\n\n if (gpuAcceleration) {\n var _Object$assign;\n\n return Object.assign({}, commonStyles, (_Object$assign = {}, _Object$assign[sideY] = hasY ? '0' : '', _Object$assign[sideX] = hasX ? '0' : '', _Object$assign.transform = (win.devicePixelRatio || 1) <= 1 ? \"translate(\" + x + \"px, \" + y + \"px)\" : \"translate3d(\" + x + \"px, \" + y + \"px, 0)\", _Object$assign));\n }\n\n return Object.assign({}, commonStyles, (_Object$assign2 = {}, _Object$assign2[sideY] = hasY ? y + \"px\" : '', _Object$assign2[sideX] = hasX ? x + \"px\" : '', _Object$assign2.transform = '', _Object$assign2));\n}\n\nfunction computeStyles(_ref5) {\n var state = _ref5.state,\n options = _ref5.options;\n var _options$gpuAccelerat = options.gpuAcceleration,\n gpuAcceleration = _options$gpuAccelerat === void 0 ? true : _options$gpuAccelerat,\n _options$adaptive = options.adaptive,\n adaptive = _options$adaptive === void 0 ? true : _options$adaptive,\n _options$roundOffsets = options.roundOffsets,\n roundOffsets = _options$roundOffsets === void 0 ? true : _options$roundOffsets;\n var commonStyles = {\n placement: getBasePlacement(state.placement),\n variation: getVariation(state.placement),\n popper: state.elements.popper,\n popperRect: state.rects.popper,\n gpuAcceleration: gpuAcceleration,\n isFixed: state.options.strategy === 'fixed'\n };\n\n if (state.modifiersData.popperOffsets != null) {\n state.styles.popper = Object.assign({}, state.styles.popper, mapToStyles(Object.assign({}, commonStyles, {\n offsets: state.modifiersData.popperOffsets,\n position: state.options.strategy,\n adaptive: adaptive,\n roundOffsets: roundOffsets\n })));\n }\n\n if (state.modifiersData.arrow != null) {\n state.styles.arrow = Object.assign({}, state.styles.arrow, mapToStyles(Object.assign({}, commonStyles, {\n offsets: state.modifiersData.arrow,\n position: 'absolute',\n adaptive: false,\n roundOffsets: roundOffsets\n })));\n }\n\n state.attributes.popper = Object.assign({}, state.attributes.popper, {\n 'data-popper-placement': state.placement\n });\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'computeStyles',\n enabled: true,\n phase: 'beforeWrite',\n fn: computeStyles,\n data: {}\n};","import getWindow from \"../dom-utils/getWindow.js\"; // eslint-disable-next-line import/no-unused-modules\n\nvar passive = {\n passive: true\n};\n\nfunction effect(_ref) {\n var state = _ref.state,\n instance = _ref.instance,\n options = _ref.options;\n var _options$scroll = options.scroll,\n scroll = _options$scroll === void 0 ? true : _options$scroll,\n _options$resize = options.resize,\n resize = _options$resize === void 0 ? true : _options$resize;\n var window = getWindow(state.elements.popper);\n var scrollParents = [].concat(state.scrollParents.reference, state.scrollParents.popper);\n\n if (scroll) {\n scrollParents.forEach(function (scrollParent) {\n scrollParent.addEventListener('scroll', instance.update, passive);\n });\n }\n\n if (resize) {\n window.addEventListener('resize', instance.update, passive);\n }\n\n return function () {\n if (scroll) {\n scrollParents.forEach(function (scrollParent) {\n scrollParent.removeEventListener('scroll', instance.update, passive);\n });\n }\n\n if (resize) {\n window.removeEventListener('resize', instance.update, passive);\n }\n };\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'eventListeners',\n enabled: true,\n phase: 'write',\n fn: function fn() {},\n effect: effect,\n data: {}\n};","var hash = {\n left: 'right',\n right: 'left',\n bottom: 'top',\n top: 'bottom'\n};\nexport default function getOppositePlacement(placement) {\n return placement.replace(/left|right|bottom|top/g, function (matched) {\n return hash[matched];\n });\n}","var hash = {\n start: 'end',\n end: 'start'\n};\nexport default function getOppositeVariationPlacement(placement) {\n return placement.replace(/start|end/g, function (matched) {\n return hash[matched];\n });\n}","import getWindow from \"./getWindow.js\";\nexport default function getWindowScroll(node) {\n var win = getWindow(node);\n var scrollLeft = win.pageXOffset;\n var scrollTop = win.pageYOffset;\n return {\n scrollLeft: scrollLeft,\n scrollTop: scrollTop\n };\n}","import getBoundingClientRect from \"./getBoundingClientRect.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport getWindowScroll from \"./getWindowScroll.js\";\nexport default function getWindowScrollBarX(element) {\n // If has a CSS width greater than the viewport, then this will be\n // incorrect for RTL.\n // Popper 1 is broken in this case and never had a bug report so let's assume\n // it's not an issue. I don't think anyone ever specifies width on \n // anyway.\n // Browsers where the left scrollbar doesn't cause an issue report `0` for\n // this (e.g. Edge 2019, IE11, Safari)\n return getBoundingClientRect(getDocumentElement(element)).left + getWindowScroll(element).scrollLeft;\n}","import getWindow from \"./getWindow.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport getWindowScrollBarX from \"./getWindowScrollBarX.js\";\nimport isLayoutViewport from \"./isLayoutViewport.js\";\nexport default function getViewportRect(element, strategy) {\n var win = getWindow(element);\n var html = getDocumentElement(element);\n var visualViewport = win.visualViewport;\n var width = html.clientWidth;\n var height = html.clientHeight;\n var x = 0;\n var y = 0;\n\n if (visualViewport) {\n width = visualViewport.width;\n height = visualViewport.height;\n var layoutViewport = isLayoutViewport();\n\n if (layoutViewport || !layoutViewport && strategy === 'fixed') {\n x = visualViewport.offsetLeft;\n y = visualViewport.offsetTop;\n }\n }\n\n return {\n width: width,\n height: height,\n x: x + getWindowScrollBarX(element),\n y: y\n };\n}","import getDocumentElement from \"./getDocumentElement.js\";\nimport getComputedStyle from \"./getComputedStyle.js\";\nimport getWindowScrollBarX from \"./getWindowScrollBarX.js\";\nimport getWindowScroll from \"./getWindowScroll.js\";\nimport { max } from \"../utils/math.js\"; // Gets the entire size of the scrollable document area, even extending outside\n// of the `` and `` rect bounds if horizontally scrollable\n\nexport default function getDocumentRect(element) {\n var _element$ownerDocumen;\n\n var html = getDocumentElement(element);\n var winScroll = getWindowScroll(element);\n var body = (_element$ownerDocumen = element.ownerDocument) == null ? void 0 : _element$ownerDocumen.body;\n var width = max(html.scrollWidth, html.clientWidth, body ? body.scrollWidth : 0, body ? body.clientWidth : 0);\n var height = max(html.scrollHeight, html.clientHeight, body ? body.scrollHeight : 0, body ? body.clientHeight : 0);\n var x = -winScroll.scrollLeft + getWindowScrollBarX(element);\n var y = -winScroll.scrollTop;\n\n if (getComputedStyle(body || html).direction === 'rtl') {\n x += max(html.clientWidth, body ? body.clientWidth : 0) - width;\n }\n\n return {\n width: width,\n height: height,\n x: x,\n y: y\n };\n}","import getComputedStyle from \"./getComputedStyle.js\";\nexport default function isScrollParent(element) {\n // Firefox wants us to check `-x` and `-y` variations as well\n var _getComputedStyle = getComputedStyle(element),\n overflow = _getComputedStyle.overflow,\n overflowX = _getComputedStyle.overflowX,\n overflowY = _getComputedStyle.overflowY;\n\n return /auto|scroll|overlay|hidden/.test(overflow + overflowY + overflowX);\n}","import getParentNode from \"./getParentNode.js\";\nimport isScrollParent from \"./isScrollParent.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport { isHTMLElement } from \"./instanceOf.js\";\nexport default function getScrollParent(node) {\n if (['html', 'body', '#document'].indexOf(getNodeName(node)) >= 0) {\n // $FlowFixMe[incompatible-return]: assume body is always available\n return node.ownerDocument.body;\n }\n\n if (isHTMLElement(node) && isScrollParent(node)) {\n return node;\n }\n\n return getScrollParent(getParentNode(node));\n}","import getScrollParent from \"./getScrollParent.js\";\nimport getParentNode from \"./getParentNode.js\";\nimport getWindow from \"./getWindow.js\";\nimport isScrollParent from \"./isScrollParent.js\";\n/*\ngiven a DOM element, return the list of all scroll parents, up the list of ancesors\nuntil we get to the top window object. This list is what we attach scroll listeners\nto, because if any of these parent elements scroll, we'll need to re-calculate the\nreference element's position.\n*/\n\nexport default function listScrollParents(element, list) {\n var _element$ownerDocumen;\n\n if (list === void 0) {\n list = [];\n }\n\n var scrollParent = getScrollParent(element);\n var isBody = scrollParent === ((_element$ownerDocumen = element.ownerDocument) == null ? void 0 : _element$ownerDocumen.body);\n var win = getWindow(scrollParent);\n var target = isBody ? [win].concat(win.visualViewport || [], isScrollParent(scrollParent) ? scrollParent : []) : scrollParent;\n var updatedList = list.concat(target);\n return isBody ? updatedList : // $FlowFixMe[incompatible-call]: isBody tells us target will be an HTMLElement here\n updatedList.concat(listScrollParents(getParentNode(target)));\n}","export default function rectToClientRect(rect) {\n return Object.assign({}, rect, {\n left: rect.x,\n top: rect.y,\n right: rect.x + rect.width,\n bottom: rect.y + rect.height\n });\n}","import { viewport } from \"../enums.js\";\nimport getViewportRect from \"./getViewportRect.js\";\nimport getDocumentRect from \"./getDocumentRect.js\";\nimport listScrollParents from \"./listScrollParents.js\";\nimport getOffsetParent from \"./getOffsetParent.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport getComputedStyle from \"./getComputedStyle.js\";\nimport { isElement, isHTMLElement } from \"./instanceOf.js\";\nimport getBoundingClientRect from \"./getBoundingClientRect.js\";\nimport getParentNode from \"./getParentNode.js\";\nimport contains from \"./contains.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport rectToClientRect from \"../utils/rectToClientRect.js\";\nimport { max, min } from \"../utils/math.js\";\n\nfunction getInnerBoundingClientRect(element, strategy) {\n var rect = getBoundingClientRect(element, false, strategy === 'fixed');\n rect.top = rect.top + element.clientTop;\n rect.left = rect.left + element.clientLeft;\n rect.bottom = rect.top + element.clientHeight;\n rect.right = rect.left + element.clientWidth;\n rect.width = element.clientWidth;\n rect.height = element.clientHeight;\n rect.x = rect.left;\n rect.y = rect.top;\n return rect;\n}\n\nfunction getClientRectFromMixedType(element, clippingParent, strategy) {\n return clippingParent === viewport ? rectToClientRect(getViewportRect(element, strategy)) : isElement(clippingParent) ? getInnerBoundingClientRect(clippingParent, strategy) : rectToClientRect(getDocumentRect(getDocumentElement(element)));\n} // A \"clipping parent\" is an overflowable container with the characteristic of\n// clipping (or hiding) overflowing elements with a position different from\n// `initial`\n\n\nfunction getClippingParents(element) {\n var clippingParents = listScrollParents(getParentNode(element));\n var canEscapeClipping = ['absolute', 'fixed'].indexOf(getComputedStyle(element).position) >= 0;\n var clipperElement = canEscapeClipping && isHTMLElement(element) ? getOffsetParent(element) : element;\n\n if (!isElement(clipperElement)) {\n return [];\n } // $FlowFixMe[incompatible-return]: https://github.com/facebook/flow/issues/1414\n\n\n return clippingParents.filter(function (clippingParent) {\n return isElement(clippingParent) && contains(clippingParent, clipperElement) && getNodeName(clippingParent) !== 'body';\n });\n} // Gets the maximum area that the element is visible in due to any number of\n// clipping parents\n\n\nexport default function getClippingRect(element, boundary, rootBoundary, strategy) {\n var mainClippingParents = boundary === 'clippingParents' ? getClippingParents(element) : [].concat(boundary);\n var clippingParents = [].concat(mainClippingParents, [rootBoundary]);\n var firstClippingParent = clippingParents[0];\n var clippingRect = clippingParents.reduce(function (accRect, clippingParent) {\n var rect = getClientRectFromMixedType(element, clippingParent, strategy);\n accRect.top = max(rect.top, accRect.top);\n accRect.right = min(rect.right, accRect.right);\n accRect.bottom = min(rect.bottom, accRect.bottom);\n accRect.left = max(rect.left, accRect.left);\n return accRect;\n }, getClientRectFromMixedType(element, firstClippingParent, strategy));\n clippingRect.width = clippingRect.right - clippingRect.left;\n clippingRect.height = clippingRect.bottom - clippingRect.top;\n clippingRect.x = clippingRect.left;\n clippingRect.y = clippingRect.top;\n return clippingRect;\n}","import getBasePlacement from \"./getBasePlacement.js\";\nimport getVariation from \"./getVariation.js\";\nimport getMainAxisFromPlacement from \"./getMainAxisFromPlacement.js\";\nimport { top, right, bottom, left, start, end } from \"../enums.js\";\nexport default function computeOffsets(_ref) {\n var reference = _ref.reference,\n element = _ref.element,\n placement = _ref.placement;\n var basePlacement = placement ? getBasePlacement(placement) : null;\n var variation = placement ? getVariation(placement) : null;\n var commonX = reference.x + reference.width / 2 - element.width / 2;\n var commonY = reference.y + reference.height / 2 - element.height / 2;\n var offsets;\n\n switch (basePlacement) {\n case top:\n offsets = {\n x: commonX,\n y: reference.y - element.height\n };\n break;\n\n case bottom:\n offsets = {\n x: commonX,\n y: reference.y + reference.height\n };\n break;\n\n case right:\n offsets = {\n x: reference.x + reference.width,\n y: commonY\n };\n break;\n\n case left:\n offsets = {\n x: reference.x - element.width,\n y: commonY\n };\n break;\n\n default:\n offsets = {\n x: reference.x,\n y: reference.y\n };\n }\n\n var mainAxis = basePlacement ? getMainAxisFromPlacement(basePlacement) : null;\n\n if (mainAxis != null) {\n var len = mainAxis === 'y' ? 'height' : 'width';\n\n switch (variation) {\n case start:\n offsets[mainAxis] = offsets[mainAxis] - (reference[len] / 2 - element[len] / 2);\n break;\n\n case end:\n offsets[mainAxis] = offsets[mainAxis] + (reference[len] / 2 - element[len] / 2);\n break;\n\n default:\n }\n }\n\n return offsets;\n}","import getClippingRect from \"../dom-utils/getClippingRect.js\";\nimport getDocumentElement from \"../dom-utils/getDocumentElement.js\";\nimport getBoundingClientRect from \"../dom-utils/getBoundingClientRect.js\";\nimport computeOffsets from \"./computeOffsets.js\";\nimport rectToClientRect from \"./rectToClientRect.js\";\nimport { clippingParents, reference, popper, bottom, top, right, basePlacements, viewport } from \"../enums.js\";\nimport { isElement } from \"../dom-utils/instanceOf.js\";\nimport mergePaddingObject from \"./mergePaddingObject.js\";\nimport expandToHashMap from \"./expandToHashMap.js\"; // eslint-disable-next-line import/no-unused-modules\n\nexport default function detectOverflow(state, options) {\n if (options === void 0) {\n options = {};\n }\n\n var _options = options,\n _options$placement = _options.placement,\n placement = _options$placement === void 0 ? state.placement : _options$placement,\n _options$strategy = _options.strategy,\n strategy = _options$strategy === void 0 ? state.strategy : _options$strategy,\n _options$boundary = _options.boundary,\n boundary = _options$boundary === void 0 ? clippingParents : _options$boundary,\n _options$rootBoundary = _options.rootBoundary,\n rootBoundary = _options$rootBoundary === void 0 ? viewport : _options$rootBoundary,\n _options$elementConte = _options.elementContext,\n elementContext = _options$elementConte === void 0 ? popper : _options$elementConte,\n _options$altBoundary = _options.altBoundary,\n altBoundary = _options$altBoundary === void 0 ? false : _options$altBoundary,\n _options$padding = _options.padding,\n padding = _options$padding === void 0 ? 0 : _options$padding;\n var paddingObject = mergePaddingObject(typeof padding !== 'number' ? padding : expandToHashMap(padding, basePlacements));\n var altContext = elementContext === popper ? reference : popper;\n var popperRect = state.rects.popper;\n var element = state.elements[altBoundary ? altContext : elementContext];\n var clippingClientRect = getClippingRect(isElement(element) ? element : element.contextElement || getDocumentElement(state.elements.popper), boundary, rootBoundary, strategy);\n var referenceClientRect = getBoundingClientRect(state.elements.reference);\n var popperOffsets = computeOffsets({\n reference: referenceClientRect,\n element: popperRect,\n strategy: 'absolute',\n placement: placement\n });\n var popperClientRect = rectToClientRect(Object.assign({}, popperRect, popperOffsets));\n var elementClientRect = elementContext === popper ? popperClientRect : referenceClientRect; // positive = overflowing the clipping rect\n // 0 or negative = within the clipping rect\n\n var overflowOffsets = {\n top: clippingClientRect.top - elementClientRect.top + paddingObject.top,\n bottom: elementClientRect.bottom - clippingClientRect.bottom + paddingObject.bottom,\n left: clippingClientRect.left - elementClientRect.left + paddingObject.left,\n right: elementClientRect.right - clippingClientRect.right + paddingObject.right\n };\n var offsetData = state.modifiersData.offset; // Offsets can be applied only to the popper element\n\n if (elementContext === popper && offsetData) {\n var offset = offsetData[placement];\n Object.keys(overflowOffsets).forEach(function (key) {\n var multiply = [right, bottom].indexOf(key) >= 0 ? 1 : -1;\n var axis = [top, bottom].indexOf(key) >= 0 ? 'y' : 'x';\n overflowOffsets[key] += offset[axis] * multiply;\n });\n }\n\n return overflowOffsets;\n}","import getVariation from \"./getVariation.js\";\nimport { variationPlacements, basePlacements, placements as allPlacements } from \"../enums.js\";\nimport detectOverflow from \"./detectOverflow.js\";\nimport getBasePlacement from \"./getBasePlacement.js\";\nexport default function computeAutoPlacement(state, options) {\n if (options === void 0) {\n options = {};\n }\n\n var _options = options,\n placement = _options.placement,\n boundary = _options.boundary,\n rootBoundary = _options.rootBoundary,\n padding = _options.padding,\n flipVariations = _options.flipVariations,\n _options$allowedAutoP = _options.allowedAutoPlacements,\n allowedAutoPlacements = _options$allowedAutoP === void 0 ? allPlacements : _options$allowedAutoP;\n var variation = getVariation(placement);\n var placements = variation ? flipVariations ? variationPlacements : variationPlacements.filter(function (placement) {\n return getVariation(placement) === variation;\n }) : basePlacements;\n var allowedPlacements = placements.filter(function (placement) {\n return allowedAutoPlacements.indexOf(placement) >= 0;\n });\n\n if (allowedPlacements.length === 0) {\n allowedPlacements = placements;\n } // $FlowFixMe[incompatible-type]: Flow seems to have problems with two array unions...\n\n\n var overflows = allowedPlacements.reduce(function (acc, placement) {\n acc[placement] = detectOverflow(state, {\n placement: placement,\n boundary: boundary,\n rootBoundary: rootBoundary,\n padding: padding\n })[getBasePlacement(placement)];\n return acc;\n }, {});\n return Object.keys(overflows).sort(function (a, b) {\n return overflows[a] - overflows[b];\n });\n}","import getOppositePlacement from \"../utils/getOppositePlacement.js\";\nimport getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getOppositeVariationPlacement from \"../utils/getOppositeVariationPlacement.js\";\nimport detectOverflow from \"../utils/detectOverflow.js\";\nimport computeAutoPlacement from \"../utils/computeAutoPlacement.js\";\nimport { bottom, top, start, right, left, auto } from \"../enums.js\";\nimport getVariation from \"../utils/getVariation.js\"; // eslint-disable-next-line import/no-unused-modules\n\nfunction getExpandedFallbackPlacements(placement) {\n if (getBasePlacement(placement) === auto) {\n return [];\n }\n\n var oppositePlacement = getOppositePlacement(placement);\n return [getOppositeVariationPlacement(placement), oppositePlacement, getOppositeVariationPlacement(oppositePlacement)];\n}\n\nfunction flip(_ref) {\n var state = _ref.state,\n options = _ref.options,\n name = _ref.name;\n\n if (state.modifiersData[name]._skip) {\n return;\n }\n\n var _options$mainAxis = options.mainAxis,\n checkMainAxis = _options$mainAxis === void 0 ? true : _options$mainAxis,\n _options$altAxis = options.altAxis,\n checkAltAxis = _options$altAxis === void 0 ? true : _options$altAxis,\n specifiedFallbackPlacements = options.fallbackPlacements,\n padding = options.padding,\n boundary = options.boundary,\n rootBoundary = options.rootBoundary,\n altBoundary = options.altBoundary,\n _options$flipVariatio = options.flipVariations,\n flipVariations = _options$flipVariatio === void 0 ? true : _options$flipVariatio,\n allowedAutoPlacements = options.allowedAutoPlacements;\n var preferredPlacement = state.options.placement;\n var basePlacement = getBasePlacement(preferredPlacement);\n var isBasePlacement = basePlacement === preferredPlacement;\n var fallbackPlacements = specifiedFallbackPlacements || (isBasePlacement || !flipVariations ? [getOppositePlacement(preferredPlacement)] : getExpandedFallbackPlacements(preferredPlacement));\n var placements = [preferredPlacement].concat(fallbackPlacements).reduce(function (acc, placement) {\n return acc.concat(getBasePlacement(placement) === auto ? computeAutoPlacement(state, {\n placement: placement,\n boundary: boundary,\n rootBoundary: rootBoundary,\n padding: padding,\n flipVariations: flipVariations,\n allowedAutoPlacements: allowedAutoPlacements\n }) : placement);\n }, []);\n var referenceRect = state.rects.reference;\n var popperRect = state.rects.popper;\n var checksMap = new Map();\n var makeFallbackChecks = true;\n var firstFittingPlacement = placements[0];\n\n for (var i = 0; i < placements.length; i++) {\n var placement = placements[i];\n\n var _basePlacement = getBasePlacement(placement);\n\n var isStartVariation = getVariation(placement) === start;\n var isVertical = [top, bottom].indexOf(_basePlacement) >= 0;\n var len = isVertical ? 'width' : 'height';\n var overflow = detectOverflow(state, {\n placement: placement,\n boundary: boundary,\n rootBoundary: rootBoundary,\n altBoundary: altBoundary,\n padding: padding\n });\n var mainVariationSide = isVertical ? isStartVariation ? right : left : isStartVariation ? bottom : top;\n\n if (referenceRect[len] > popperRect[len]) {\n mainVariationSide = getOppositePlacement(mainVariationSide);\n }\n\n var altVariationSide = getOppositePlacement(mainVariationSide);\n var checks = [];\n\n if (checkMainAxis) {\n checks.push(overflow[_basePlacement] <= 0);\n }\n\n if (checkAltAxis) {\n checks.push(overflow[mainVariationSide] <= 0, overflow[altVariationSide] <= 0);\n }\n\n if (checks.every(function (check) {\n return check;\n })) {\n firstFittingPlacement = placement;\n makeFallbackChecks = false;\n break;\n }\n\n checksMap.set(placement, checks);\n }\n\n if (makeFallbackChecks) {\n // `2` may be desired in some cases – research later\n var numberOfChecks = flipVariations ? 3 : 1;\n\n var _loop = function _loop(_i) {\n var fittingPlacement = placements.find(function (placement) {\n var checks = checksMap.get(placement);\n\n if (checks) {\n return checks.slice(0, _i).every(function (check) {\n return check;\n });\n }\n });\n\n if (fittingPlacement) {\n firstFittingPlacement = fittingPlacement;\n return \"break\";\n }\n };\n\n for (var _i = numberOfChecks; _i > 0; _i--) {\n var _ret = _loop(_i);\n\n if (_ret === \"break\") break;\n }\n }\n\n if (state.placement !== firstFittingPlacement) {\n state.modifiersData[name]._skip = true;\n state.placement = firstFittingPlacement;\n state.reset = true;\n }\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'flip',\n enabled: true,\n phase: 'main',\n fn: flip,\n requiresIfExists: ['offset'],\n data: {\n _skip: false\n }\n};","import { top, bottom, left, right } from \"../enums.js\";\nimport detectOverflow from \"../utils/detectOverflow.js\";\n\nfunction getSideOffsets(overflow, rect, preventedOffsets) {\n if (preventedOffsets === void 0) {\n preventedOffsets = {\n x: 0,\n y: 0\n };\n }\n\n return {\n top: overflow.top - rect.height - preventedOffsets.y,\n right: overflow.right - rect.width + preventedOffsets.x,\n bottom: overflow.bottom - rect.height + preventedOffsets.y,\n left: overflow.left - rect.width - preventedOffsets.x\n };\n}\n\nfunction isAnySideFullyClipped(overflow) {\n return [top, right, bottom, left].some(function (side) {\n return overflow[side] >= 0;\n });\n}\n\nfunction hide(_ref) {\n var state = _ref.state,\n name = _ref.name;\n var referenceRect = state.rects.reference;\n var popperRect = state.rects.popper;\n var preventedOffsets = state.modifiersData.preventOverflow;\n var referenceOverflow = detectOverflow(state, {\n elementContext: 'reference'\n });\n var popperAltOverflow = detectOverflow(state, {\n altBoundary: true\n });\n var referenceClippingOffsets = getSideOffsets(referenceOverflow, referenceRect);\n var popperEscapeOffsets = getSideOffsets(popperAltOverflow, popperRect, preventedOffsets);\n var isReferenceHidden = isAnySideFullyClipped(referenceClippingOffsets);\n var hasPopperEscaped = isAnySideFullyClipped(popperEscapeOffsets);\n state.modifiersData[name] = {\n referenceClippingOffsets: referenceClippingOffsets,\n popperEscapeOffsets: popperEscapeOffsets,\n isReferenceHidden: isReferenceHidden,\n hasPopperEscaped: hasPopperEscaped\n };\n state.attributes.popper = Object.assign({}, state.attributes.popper, {\n 'data-popper-reference-hidden': isReferenceHidden,\n 'data-popper-escaped': hasPopperEscaped\n });\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'hide',\n enabled: true,\n phase: 'main',\n requiresIfExists: ['preventOverflow'],\n fn: hide\n};","import getBasePlacement from \"../utils/getBasePlacement.js\";\nimport { top, left, right, placements } from \"../enums.js\"; // eslint-disable-next-line import/no-unused-modules\n\nexport function distanceAndSkiddingToXY(placement, rects, offset) {\n var basePlacement = getBasePlacement(placement);\n var invertDistance = [left, top].indexOf(basePlacement) >= 0 ? -1 : 1;\n\n var _ref = typeof offset === 'function' ? offset(Object.assign({}, rects, {\n placement: placement\n })) : offset,\n skidding = _ref[0],\n distance = _ref[1];\n\n skidding = skidding || 0;\n distance = (distance || 0) * invertDistance;\n return [left, right].indexOf(basePlacement) >= 0 ? {\n x: distance,\n y: skidding\n } : {\n x: skidding,\n y: distance\n };\n}\n\nfunction offset(_ref2) {\n var state = _ref2.state,\n options = _ref2.options,\n name = _ref2.name;\n var _options$offset = options.offset,\n offset = _options$offset === void 0 ? [0, 0] : _options$offset;\n var data = placements.reduce(function (acc, placement) {\n acc[placement] = distanceAndSkiddingToXY(placement, state.rects, offset);\n return acc;\n }, {});\n var _data$state$placement = data[state.placement],\n x = _data$state$placement.x,\n y = _data$state$placement.y;\n\n if (state.modifiersData.popperOffsets != null) {\n state.modifiersData.popperOffsets.x += x;\n state.modifiersData.popperOffsets.y += y;\n }\n\n state.modifiersData[name] = data;\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'offset',\n enabled: true,\n phase: 'main',\n requires: ['popperOffsets'],\n fn: offset\n};","import computeOffsets from \"../utils/computeOffsets.js\";\n\nfunction popperOffsets(_ref) {\n var state = _ref.state,\n name = _ref.name;\n // Offsets are the actual position the popper needs to have to be\n // properly positioned near its reference element\n // This is the most basic placement, and will be adjusted by\n // the modifiers in the next step\n state.modifiersData[name] = computeOffsets({\n reference: state.rects.reference,\n element: state.rects.popper,\n strategy: 'absolute',\n placement: state.placement\n });\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'popperOffsets',\n enabled: true,\n phase: 'read',\n fn: popperOffsets,\n data: {}\n};","export default function getAltAxis(axis) {\n return axis === 'x' ? 'y' : 'x';\n}","import { top, left, right, bottom, start } from \"../enums.js\";\nimport getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getMainAxisFromPlacement from \"../utils/getMainAxisFromPlacement.js\";\nimport getAltAxis from \"../utils/getAltAxis.js\";\nimport { within, withinMaxClamp } from \"../utils/within.js\";\nimport getLayoutRect from \"../dom-utils/getLayoutRect.js\";\nimport getOffsetParent from \"../dom-utils/getOffsetParent.js\";\nimport detectOverflow from \"../utils/detectOverflow.js\";\nimport getVariation from \"../utils/getVariation.js\";\nimport getFreshSideObject from \"../utils/getFreshSideObject.js\";\nimport { min as mathMin, max as mathMax } from \"../utils/math.js\";\n\nfunction preventOverflow(_ref) {\n var state = _ref.state,\n options = _ref.options,\n name = _ref.name;\n var _options$mainAxis = options.mainAxis,\n checkMainAxis = _options$mainAxis === void 0 ? true : _options$mainAxis,\n _options$altAxis = options.altAxis,\n checkAltAxis = _options$altAxis === void 0 ? false : _options$altAxis,\n boundary = options.boundary,\n rootBoundary = options.rootBoundary,\n altBoundary = options.altBoundary,\n padding = options.padding,\n _options$tether = options.tether,\n tether = _options$tether === void 0 ? true : _options$tether,\n _options$tetherOffset = options.tetherOffset,\n tetherOffset = _options$tetherOffset === void 0 ? 0 : _options$tetherOffset;\n var overflow = detectOverflow(state, {\n boundary: boundary,\n rootBoundary: rootBoundary,\n padding: padding,\n altBoundary: altBoundary\n });\n var basePlacement = getBasePlacement(state.placement);\n var variation = getVariation(state.placement);\n var isBasePlacement = !variation;\n var mainAxis = getMainAxisFromPlacement(basePlacement);\n var altAxis = getAltAxis(mainAxis);\n var popperOffsets = state.modifiersData.popperOffsets;\n var referenceRect = state.rects.reference;\n var popperRect = state.rects.popper;\n var tetherOffsetValue = typeof tetherOffset === 'function' ? tetherOffset(Object.assign({}, state.rects, {\n placement: state.placement\n })) : tetherOffset;\n var normalizedTetherOffsetValue = typeof tetherOffsetValue === 'number' ? {\n mainAxis: tetherOffsetValue,\n altAxis: tetherOffsetValue\n } : Object.assign({\n mainAxis: 0,\n altAxis: 0\n }, tetherOffsetValue);\n var offsetModifierState = state.modifiersData.offset ? state.modifiersData.offset[state.placement] : null;\n var data = {\n x: 0,\n y: 0\n };\n\n if (!popperOffsets) {\n return;\n }\n\n if (checkMainAxis) {\n var _offsetModifierState$;\n\n var mainSide = mainAxis === 'y' ? top : left;\n var altSide = mainAxis === 'y' ? bottom : right;\n var len = mainAxis === 'y' ? 'height' : 'width';\n var offset = popperOffsets[mainAxis];\n var min = offset + overflow[mainSide];\n var max = offset - overflow[altSide];\n var additive = tether ? -popperRect[len] / 2 : 0;\n var minLen = variation === start ? referenceRect[len] : popperRect[len];\n var maxLen = variation === start ? -popperRect[len] : -referenceRect[len]; // We need to include the arrow in the calculation so the arrow doesn't go\n // outside the reference bounds\n\n var arrowElement = state.elements.arrow;\n var arrowRect = tether && arrowElement ? getLayoutRect(arrowElement) : {\n width: 0,\n height: 0\n };\n var arrowPaddingObject = state.modifiersData['arrow#persistent'] ? state.modifiersData['arrow#persistent'].padding : getFreshSideObject();\n var arrowPaddingMin = arrowPaddingObject[mainSide];\n var arrowPaddingMax = arrowPaddingObject[altSide]; // If the reference length is smaller than the arrow length, we don't want\n // to include its full size in the calculation. If the reference is small\n // and near the edge of a boundary, the popper can overflow even if the\n // reference is not overflowing as well (e.g. virtual elements with no\n // width or height)\n\n var arrowLen = within(0, referenceRect[len], arrowRect[len]);\n var minOffset = isBasePlacement ? referenceRect[len] / 2 - additive - arrowLen - arrowPaddingMin - normalizedTetherOffsetValue.mainAxis : minLen - arrowLen - arrowPaddingMin - normalizedTetherOffsetValue.mainAxis;\n var maxOffset = isBasePlacement ? -referenceRect[len] / 2 + additive + arrowLen + arrowPaddingMax + normalizedTetherOffsetValue.mainAxis : maxLen + arrowLen + arrowPaddingMax + normalizedTetherOffsetValue.mainAxis;\n var arrowOffsetParent = state.elements.arrow && getOffsetParent(state.elements.arrow);\n var clientOffset = arrowOffsetParent ? mainAxis === 'y' ? arrowOffsetParent.clientTop || 0 : arrowOffsetParent.clientLeft || 0 : 0;\n var offsetModifierValue = (_offsetModifierState$ = offsetModifierState == null ? void 0 : offsetModifierState[mainAxis]) != null ? _offsetModifierState$ : 0;\n var tetherMin = offset + minOffset - offsetModifierValue - clientOffset;\n var tetherMax = offset + maxOffset - offsetModifierValue;\n var preventedOffset = within(tether ? mathMin(min, tetherMin) : min, offset, tether ? mathMax(max, tetherMax) : max);\n popperOffsets[mainAxis] = preventedOffset;\n data[mainAxis] = preventedOffset - offset;\n }\n\n if (checkAltAxis) {\n var _offsetModifierState$2;\n\n var _mainSide = mainAxis === 'x' ? top : left;\n\n var _altSide = mainAxis === 'x' ? bottom : right;\n\n var _offset = popperOffsets[altAxis];\n\n var _len = altAxis === 'y' ? 'height' : 'width';\n\n var _min = _offset + overflow[_mainSide];\n\n var _max = _offset - overflow[_altSide];\n\n var isOriginSide = [top, left].indexOf(basePlacement) !== -1;\n\n var _offsetModifierValue = (_offsetModifierState$2 = offsetModifierState == null ? void 0 : offsetModifierState[altAxis]) != null ? _offsetModifierState$2 : 0;\n\n var _tetherMin = isOriginSide ? _min : _offset - referenceRect[_len] - popperRect[_len] - _offsetModifierValue + normalizedTetherOffsetValue.altAxis;\n\n var _tetherMax = isOriginSide ? _offset + referenceRect[_len] + popperRect[_len] - _offsetModifierValue - normalizedTetherOffsetValue.altAxis : _max;\n\n var _preventedOffset = tether && isOriginSide ? withinMaxClamp(_tetherMin, _offset, _tetherMax) : within(tether ? _tetherMin : _min, _offset, tether ? _tetherMax : _max);\n\n popperOffsets[altAxis] = _preventedOffset;\n data[altAxis] = _preventedOffset - _offset;\n }\n\n state.modifiersData[name] = data;\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'preventOverflow',\n enabled: true,\n phase: 'main',\n fn: preventOverflow,\n requiresIfExists: ['offset']\n};","export default function getHTMLElementScroll(element) {\n return {\n scrollLeft: element.scrollLeft,\n scrollTop: element.scrollTop\n };\n}","import getWindowScroll from \"./getWindowScroll.js\";\nimport getWindow from \"./getWindow.js\";\nimport { isHTMLElement } from \"./instanceOf.js\";\nimport getHTMLElementScroll from \"./getHTMLElementScroll.js\";\nexport default function getNodeScroll(node) {\n if (node === getWindow(node) || !isHTMLElement(node)) {\n return getWindowScroll(node);\n } else {\n return getHTMLElementScroll(node);\n }\n}","import getBoundingClientRect from \"./getBoundingClientRect.js\";\nimport getNodeScroll from \"./getNodeScroll.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport { isHTMLElement } from \"./instanceOf.js\";\nimport getWindowScrollBarX from \"./getWindowScrollBarX.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport isScrollParent from \"./isScrollParent.js\";\nimport { round } from \"../utils/math.js\";\n\nfunction isElementScaled(element) {\n var rect = element.getBoundingClientRect();\n var scaleX = round(rect.width) / element.offsetWidth || 1;\n var scaleY = round(rect.height) / element.offsetHeight || 1;\n return scaleX !== 1 || scaleY !== 1;\n} // Returns the composite rect of an element relative to its offsetParent.\n// Composite means it takes into account transforms as well as layout.\n\n\nexport default function getCompositeRect(elementOrVirtualElement, offsetParent, isFixed) {\n if (isFixed === void 0) {\n isFixed = false;\n }\n\n var isOffsetParentAnElement = isHTMLElement(offsetParent);\n var offsetParentIsScaled = isHTMLElement(offsetParent) && isElementScaled(offsetParent);\n var documentElement = getDocumentElement(offsetParent);\n var rect = getBoundingClientRect(elementOrVirtualElement, offsetParentIsScaled, isFixed);\n var scroll = {\n scrollLeft: 0,\n scrollTop: 0\n };\n var offsets = {\n x: 0,\n y: 0\n };\n\n if (isOffsetParentAnElement || !isOffsetParentAnElement && !isFixed) {\n if (getNodeName(offsetParent) !== 'body' || // https://github.com/popperjs/popper-core/issues/1078\n isScrollParent(documentElement)) {\n scroll = getNodeScroll(offsetParent);\n }\n\n if (isHTMLElement(offsetParent)) {\n offsets = getBoundingClientRect(offsetParent, true);\n offsets.x += offsetParent.clientLeft;\n offsets.y += offsetParent.clientTop;\n } else if (documentElement) {\n offsets.x = getWindowScrollBarX(documentElement);\n }\n }\n\n return {\n x: rect.left + scroll.scrollLeft - offsets.x,\n y: rect.top + scroll.scrollTop - offsets.y,\n width: rect.width,\n height: rect.height\n };\n}","import { modifierPhases } from \"../enums.js\"; // source: https://stackoverflow.com/questions/49875255\n\nfunction order(modifiers) {\n var map = new Map();\n var visited = new Set();\n var result = [];\n modifiers.forEach(function (modifier) {\n map.set(modifier.name, modifier);\n }); // On visiting object, check for its dependencies and visit them recursively\n\n function sort(modifier) {\n visited.add(modifier.name);\n var requires = [].concat(modifier.requires || [], modifier.requiresIfExists || []);\n requires.forEach(function (dep) {\n if (!visited.has(dep)) {\n var depModifier = map.get(dep);\n\n if (depModifier) {\n sort(depModifier);\n }\n }\n });\n result.push(modifier);\n }\n\n modifiers.forEach(function (modifier) {\n if (!visited.has(modifier.name)) {\n // check for visited object\n sort(modifier);\n }\n });\n return result;\n}\n\nexport default function orderModifiers(modifiers) {\n // order based on dependencies\n var orderedModifiers = order(modifiers); // order based on phase\n\n return modifierPhases.reduce(function (acc, phase) {\n return acc.concat(orderedModifiers.filter(function (modifier) {\n return modifier.phase === phase;\n }));\n }, []);\n}","export default function debounce(fn) {\n var pending;\n return function () {\n if (!pending) {\n pending = new Promise(function (resolve) {\n Promise.resolve().then(function () {\n pending = undefined;\n resolve(fn());\n });\n });\n }\n\n return pending;\n };\n}","export default function mergeByName(modifiers) {\n var merged = modifiers.reduce(function (merged, current) {\n var existing = merged[current.name];\n merged[current.name] = existing ? Object.assign({}, existing, current, {\n options: Object.assign({}, existing.options, current.options),\n data: Object.assign({}, existing.data, current.data)\n }) : current;\n return merged;\n }, {}); // IE11 does not support Object.values\n\n return Object.keys(merged).map(function (key) {\n return merged[key];\n });\n}","import getCompositeRect from \"./dom-utils/getCompositeRect.js\";\nimport getLayoutRect from \"./dom-utils/getLayoutRect.js\";\nimport listScrollParents from \"./dom-utils/listScrollParents.js\";\nimport getOffsetParent from \"./dom-utils/getOffsetParent.js\";\nimport orderModifiers from \"./utils/orderModifiers.js\";\nimport debounce from \"./utils/debounce.js\";\nimport mergeByName from \"./utils/mergeByName.js\";\nimport detectOverflow from \"./utils/detectOverflow.js\";\nimport { isElement } from \"./dom-utils/instanceOf.js\";\nvar DEFAULT_OPTIONS = {\n placement: 'bottom',\n modifiers: [],\n strategy: 'absolute'\n};\n\nfunction areValidElements() {\n for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {\n args[_key] = arguments[_key];\n }\n\n return !args.some(function (element) {\n return !(element && typeof element.getBoundingClientRect === 'function');\n });\n}\n\nexport function popperGenerator(generatorOptions) {\n if (generatorOptions === void 0) {\n generatorOptions = {};\n }\n\n var _generatorOptions = generatorOptions,\n _generatorOptions$def = _generatorOptions.defaultModifiers,\n defaultModifiers = _generatorOptions$def === void 0 ? [] : _generatorOptions$def,\n _generatorOptions$def2 = _generatorOptions.defaultOptions,\n defaultOptions = _generatorOptions$def2 === void 0 ? DEFAULT_OPTIONS : _generatorOptions$def2;\n return function createPopper(reference, popper, options) {\n if (options === void 0) {\n options = defaultOptions;\n }\n\n var state = {\n placement: 'bottom',\n orderedModifiers: [],\n options: Object.assign({}, DEFAULT_OPTIONS, defaultOptions),\n modifiersData: {},\n elements: {\n reference: reference,\n popper: popper\n },\n attributes: {},\n styles: {}\n };\n var effectCleanupFns = [];\n var isDestroyed = false;\n var instance = {\n state: state,\n setOptions: function setOptions(setOptionsAction) {\n var options = typeof setOptionsAction === 'function' ? setOptionsAction(state.options) : setOptionsAction;\n cleanupModifierEffects();\n state.options = Object.assign({}, defaultOptions, state.options, options);\n state.scrollParents = {\n reference: isElement(reference) ? listScrollParents(reference) : reference.contextElement ? listScrollParents(reference.contextElement) : [],\n popper: listScrollParents(popper)\n }; // Orders the modifiers based on their dependencies and `phase`\n // properties\n\n var orderedModifiers = orderModifiers(mergeByName([].concat(defaultModifiers, state.options.modifiers))); // Strip out disabled modifiers\n\n state.orderedModifiers = orderedModifiers.filter(function (m) {\n return m.enabled;\n });\n runModifierEffects();\n return instance.update();\n },\n // Sync update – it will always be executed, even if not necessary. This\n // is useful for low frequency updates where sync behavior simplifies the\n // logic.\n // For high frequency updates (e.g. `resize` and `scroll` events), always\n // prefer the async Popper#update method\n forceUpdate: function forceUpdate() {\n if (isDestroyed) {\n return;\n }\n\n var _state$elements = state.elements,\n reference = _state$elements.reference,\n popper = _state$elements.popper; // Don't proceed if `reference` or `popper` are not valid elements\n // anymore\n\n if (!areValidElements(reference, popper)) {\n return;\n } // Store the reference and popper rects to be read by modifiers\n\n\n state.rects = {\n reference: getCompositeRect(reference, getOffsetParent(popper), state.options.strategy === 'fixed'),\n popper: getLayoutRect(popper)\n }; // Modifiers have the ability to reset the current update cycle. The\n // most common use case for this is the `flip` modifier changing the\n // placement, which then needs to re-run all the modifiers, because the\n // logic was previously ran for the previous placement and is therefore\n // stale/incorrect\n\n state.reset = false;\n state.placement = state.options.placement; // On each update cycle, the `modifiersData` property for each modifier\n // is filled with the initial data specified by the modifier. This means\n // it doesn't persist and is fresh on each update.\n // To ensure persistent data, use `${name}#persistent`\n\n state.orderedModifiers.forEach(function (modifier) {\n return state.modifiersData[modifier.name] = Object.assign({}, modifier.data);\n });\n\n for (var index = 0; index < state.orderedModifiers.length; index++) {\n if (state.reset === true) {\n state.reset = false;\n index = -1;\n continue;\n }\n\n var _state$orderedModifie = state.orderedModifiers[index],\n fn = _state$orderedModifie.fn,\n _state$orderedModifie2 = _state$orderedModifie.options,\n _options = _state$orderedModifie2 === void 0 ? {} : _state$orderedModifie2,\n name = _state$orderedModifie.name;\n\n if (typeof fn === 'function') {\n state = fn({\n state: state,\n options: _options,\n name: name,\n instance: instance\n }) || state;\n }\n }\n },\n // Async and optimistically optimized update – it will not be executed if\n // not necessary (debounced to run at most once-per-tick)\n update: debounce(function () {\n return new Promise(function (resolve) {\n instance.forceUpdate();\n resolve(state);\n });\n }),\n destroy: function destroy() {\n cleanupModifierEffects();\n isDestroyed = true;\n }\n };\n\n if (!areValidElements(reference, popper)) {\n return instance;\n }\n\n instance.setOptions(options).then(function (state) {\n if (!isDestroyed && options.onFirstUpdate) {\n options.onFirstUpdate(state);\n }\n }); // Modifiers have the ability to execute arbitrary code before the first\n // update cycle runs. They will be executed in the same order as the update\n // cycle. This is useful when a modifier adds some persistent data that\n // other modifiers need to use, but the modifier is run after the dependent\n // one.\n\n function runModifierEffects() {\n state.orderedModifiers.forEach(function (_ref) {\n var name = _ref.name,\n _ref$options = _ref.options,\n options = _ref$options === void 0 ? {} : _ref$options,\n effect = _ref.effect;\n\n if (typeof effect === 'function') {\n var cleanupFn = effect({\n state: state,\n name: name,\n instance: instance,\n options: options\n });\n\n var noopFn = function noopFn() {};\n\n effectCleanupFns.push(cleanupFn || noopFn);\n }\n });\n }\n\n function cleanupModifierEffects() {\n effectCleanupFns.forEach(function (fn) {\n return fn();\n });\n effectCleanupFns = [];\n }\n\n return instance;\n };\n}\nexport var createPopper = /*#__PURE__*/popperGenerator(); // eslint-disable-next-line import/no-unused-modules\n\nexport { detectOverflow };","import { popperGenerator, detectOverflow } from \"./createPopper.js\";\nimport eventListeners from \"./modifiers/eventListeners.js\";\nimport popperOffsets from \"./modifiers/popperOffsets.js\";\nimport computeStyles from \"./modifiers/computeStyles.js\";\nimport applyStyles from \"./modifiers/applyStyles.js\";\nimport offset from \"./modifiers/offset.js\";\nimport flip from \"./modifiers/flip.js\";\nimport preventOverflow from \"./modifiers/preventOverflow.js\";\nimport arrow from \"./modifiers/arrow.js\";\nimport hide from \"./modifiers/hide.js\";\nvar defaultModifiers = [eventListeners, popperOffsets, computeStyles, applyStyles, offset, flip, preventOverflow, arrow, hide];\nvar createPopper = /*#__PURE__*/popperGenerator({\n defaultModifiers: defaultModifiers\n}); // eslint-disable-next-line import/no-unused-modules\n\nexport { createPopper, popperGenerator, defaultModifiers, detectOverflow }; // eslint-disable-next-line import/no-unused-modules\n\nexport { createPopper as createPopperLite } from \"./popper-lite.js\"; // eslint-disable-next-line import/no-unused-modules\n\nexport * from \"./modifiers/index.js\";","import { generateUtilityClass } from '../generateUtilityClass';\nimport { generateUtilityClasses } from '../generateUtilityClasses';\nconst COMPONENT_NAME = 'Popper';\nexport function getPopperUtilityClass(slot) {\n return generateUtilityClass(COMPONENT_NAME, slot);\n}\nexport const popperClasses = generateUtilityClasses(COMPONENT_NAME, ['root']);","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"anchorEl\", \"children\", \"direction\", \"disablePortal\", \"modifiers\", \"open\", \"placement\", \"popperOptions\", \"popperRef\", \"slotProps\", \"slots\", \"TransitionProps\", \"ownerState\"],\n _excluded2 = [\"anchorEl\", \"children\", \"container\", \"direction\", \"disablePortal\", \"keepMounted\", \"modifiers\", \"open\", \"placement\", \"popperOptions\", \"popperRef\", \"style\", \"transition\", \"slotProps\", \"slots\"];\nimport * as React from 'react';\nimport { chainPropTypes, HTMLElementType, refType, unstable_ownerDocument as ownerDocument, unstable_useEnhancedEffect as useEnhancedEffect, unstable_useForkRef as useForkRef } from '@mui/utils';\nimport { createPopper } from '@popperjs/core';\nimport PropTypes from 'prop-types';\nimport { unstable_composeClasses as composeClasses } from '../composeClasses';\nimport { Portal } from '../Portal';\nimport { getPopperUtilityClass } from './popperClasses';\nimport { useSlotProps } from '../utils';\nimport { useClassNamesOverride } from '../utils/ClassNameConfigurator';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nfunction flipPlacement(placement, direction) {\n if (direction === 'ltr') {\n return placement;\n }\n switch (placement) {\n case 'bottom-end':\n return 'bottom-start';\n case 'bottom-start':\n return 'bottom-end';\n case 'top-end':\n return 'top-start';\n case 'top-start':\n return 'top-end';\n default:\n return placement;\n }\n}\nfunction resolveAnchorEl(anchorEl) {\n return typeof anchorEl === 'function' ? anchorEl() : anchorEl;\n}\nfunction isHTMLElement(element) {\n return element.nodeType !== undefined;\n}\nfunction isVirtualElement(element) {\n return !isHTMLElement(element);\n}\nconst useUtilityClasses = () => {\n const slots = {\n root: ['root']\n };\n return composeClasses(slots, useClassNamesOverride(getPopperUtilityClass));\n};\nconst defaultPopperOptions = {};\nconst PopperTooltip = /*#__PURE__*/React.forwardRef(function PopperTooltip(props, forwardedRef) {\n var _slots$root;\n const {\n anchorEl,\n children,\n direction,\n disablePortal,\n modifiers,\n open,\n placement: initialPlacement,\n popperOptions,\n popperRef: popperRefProp,\n slotProps = {},\n slots = {},\n TransitionProps\n // @ts-ignore internal logic\n // prevent from spreading to DOM, it can come from the parent component e.g. Select.\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const tooltipRef = React.useRef(null);\n const ownRef = useForkRef(tooltipRef, forwardedRef);\n const popperRef = React.useRef(null);\n const handlePopperRef = useForkRef(popperRef, popperRefProp);\n const handlePopperRefRef = React.useRef(handlePopperRef);\n useEnhancedEffect(() => {\n handlePopperRefRef.current = handlePopperRef;\n }, [handlePopperRef]);\n React.useImperativeHandle(popperRefProp, () => popperRef.current, []);\n const rtlPlacement = flipPlacement(initialPlacement, direction);\n /**\n * placement initialized from prop but can change during lifetime if modifiers.flip.\n * modifiers.flip is essentially a flip for controlled/uncontrolled behavior\n */\n const [placement, setPlacement] = React.useState(rtlPlacement);\n const [resolvedAnchorElement, setResolvedAnchorElement] = React.useState(resolveAnchorEl(anchorEl));\n React.useEffect(() => {\n if (popperRef.current) {\n popperRef.current.forceUpdate();\n }\n });\n React.useEffect(() => {\n if (anchorEl) {\n setResolvedAnchorElement(resolveAnchorEl(anchorEl));\n }\n }, [anchorEl]);\n useEnhancedEffect(() => {\n if (!resolvedAnchorElement || !open) {\n return undefined;\n }\n const handlePopperUpdate = data => {\n setPlacement(data.placement);\n };\n if (process.env.NODE_ENV !== 'production') {\n if (resolvedAnchorElement && isHTMLElement(resolvedAnchorElement) && resolvedAnchorElement.nodeType === 1) {\n const box = resolvedAnchorElement.getBoundingClientRect();\n if (process.env.NODE_ENV !== 'test' && box.top === 0 && box.left === 0 && box.right === 0 && box.bottom === 0) {\n console.warn(['MUI: The `anchorEl` prop provided to the component is invalid.', 'The anchor element should be part of the document layout.', \"Make sure the element is present in the document or that it's not display none.\"].join('\\n'));\n }\n }\n }\n let popperModifiers = [{\n name: 'preventOverflow',\n options: {\n altBoundary: disablePortal\n }\n }, {\n name: 'flip',\n options: {\n altBoundary: disablePortal\n }\n }, {\n name: 'onUpdate',\n enabled: true,\n phase: 'afterWrite',\n fn: ({\n state\n }) => {\n handlePopperUpdate(state);\n }\n }];\n if (modifiers != null) {\n popperModifiers = popperModifiers.concat(modifiers);\n }\n if (popperOptions && popperOptions.modifiers != null) {\n popperModifiers = popperModifiers.concat(popperOptions.modifiers);\n }\n const popper = createPopper(resolvedAnchorElement, tooltipRef.current, _extends({\n placement: rtlPlacement\n }, popperOptions, {\n modifiers: popperModifiers\n }));\n handlePopperRefRef.current(popper);\n return () => {\n popper.destroy();\n handlePopperRefRef.current(null);\n };\n }, [resolvedAnchorElement, disablePortal, modifiers, open, popperOptions, rtlPlacement]);\n const childProps = {\n placement: placement\n };\n if (TransitionProps !== null) {\n childProps.TransitionProps = TransitionProps;\n }\n const classes = useUtilityClasses();\n const Root = (_slots$root = slots.root) != null ? _slots$root : 'div';\n const rootProps = useSlotProps({\n elementType: Root,\n externalSlotProps: slotProps.root,\n externalForwardedProps: other,\n additionalProps: {\n role: 'tooltip',\n ref: ownRef\n },\n ownerState: props,\n className: classes.root\n });\n return /*#__PURE__*/_jsx(Root, _extends({}, rootProps, {\n children: typeof children === 'function' ? children(childProps) : children\n }));\n});\n\n/**\n * Poppers rely on the 3rd party library [Popper.js](https://popper.js.org/docs/v2/) for positioning.\n *\n * Demos:\n *\n * - [Popper](https://mui.com/base-ui/react-popper/)\n *\n * API:\n *\n * - [Popper API](https://mui.com/base-ui/react-popper/components-api/#popper)\n */\nconst Popper = /*#__PURE__*/React.forwardRef(function Popper(props, forwardedRef) {\n const {\n anchorEl,\n children,\n container: containerProp,\n direction = 'ltr',\n disablePortal = false,\n keepMounted = false,\n modifiers,\n open,\n placement = 'bottom',\n popperOptions = defaultPopperOptions,\n popperRef,\n style,\n transition = false,\n slotProps = {},\n slots = {}\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded2);\n const [exited, setExited] = React.useState(true);\n const handleEnter = () => {\n setExited(false);\n };\n const handleExited = () => {\n setExited(true);\n };\n if (!keepMounted && !open && (!transition || exited)) {\n return null;\n }\n\n // If the container prop is provided, use that\n // If the anchorEl prop is provided, use its parent body element as the container\n // If neither are provided let the Modal take care of choosing the container\n let container;\n if (containerProp) {\n container = containerProp;\n } else if (anchorEl) {\n const resolvedAnchorEl = resolveAnchorEl(anchorEl);\n container = resolvedAnchorEl && isHTMLElement(resolvedAnchorEl) ? ownerDocument(resolvedAnchorEl).body : ownerDocument(null).body;\n }\n const display = !open && keepMounted && (!transition || exited) ? 'none' : undefined;\n const transitionProps = transition ? {\n in: open,\n onEnter: handleEnter,\n onExited: handleExited\n } : undefined;\n return /*#__PURE__*/_jsx(Portal, {\n disablePortal: disablePortal,\n container: container,\n children: /*#__PURE__*/_jsx(PopperTooltip, _extends({\n anchorEl: anchorEl,\n direction: direction,\n disablePortal: disablePortal,\n modifiers: modifiers,\n ref: forwardedRef,\n open: transition ? !exited : open,\n placement: placement,\n popperOptions: popperOptions,\n popperRef: popperRef,\n slotProps: slotProps,\n slots: slots\n }, other, {\n style: _extends({\n // Prevents scroll issue, waiting for Popper.js to add this style once initiated.\n position: 'fixed',\n // Fix Popper.js display issue\n top: 0,\n left: 0,\n display\n }, style),\n TransitionProps: transitionProps,\n children: children\n }))\n });\n});\nprocess.env.NODE_ENV !== \"production\" ? Popper.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * An HTML element, [virtualElement](https://popper.js.org/docs/v2/virtual-elements/),\n * or a function that returns either.\n * It's used to set the position of the popper.\n * The return value will passed as the reference object of the Popper instance.\n */\n anchorEl: chainPropTypes(PropTypes.oneOfType([HTMLElementType, PropTypes.object, PropTypes.func]), props => {\n if (props.open) {\n const resolvedAnchorEl = resolveAnchorEl(props.anchorEl);\n if (resolvedAnchorEl && isHTMLElement(resolvedAnchorEl) && resolvedAnchorEl.nodeType === 1) {\n const box = resolvedAnchorEl.getBoundingClientRect();\n if (process.env.NODE_ENV !== 'test' && box.top === 0 && box.left === 0 && box.right === 0 && box.bottom === 0) {\n return new Error(['MUI: The `anchorEl` prop provided to the component is invalid.', 'The anchor element should be part of the document layout.', \"Make sure the element is present in the document or that it's not display none.\"].join('\\n'));\n }\n } else if (!resolvedAnchorEl || typeof resolvedAnchorEl.getBoundingClientRect !== 'function' || isVirtualElement(resolvedAnchorEl) && resolvedAnchorEl.contextElement != null && resolvedAnchorEl.contextElement.nodeType !== 1) {\n return new Error(['MUI: The `anchorEl` prop provided to the component is invalid.', 'It should be an HTML element instance or a virtualElement ', '(https://popper.js.org/docs/v2/virtual-elements/).'].join('\\n'));\n }\n }\n return null;\n }),\n /**\n * Popper render function or node.\n */\n children: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.node, PropTypes.func]),\n /**\n * An HTML element or function that returns one.\n * The `container` will have the portal children appended to it.\n *\n * You can also provide a callback, which is called in a React layout effect.\n * This lets you set the container from a ref, and also makes server-side rendering possible.\n *\n * By default, it uses the body of the top-level document object,\n * so it's simply `document.body` most of the time.\n */\n container: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.func]),\n /**\n * Direction of the text.\n * @default 'ltr'\n */\n direction: PropTypes.oneOf(['ltr', 'rtl']),\n /**\n * The `children` will be under the DOM hierarchy of the parent component.\n * @default false\n */\n disablePortal: PropTypes.bool,\n /**\n * Always keep the children in the DOM.\n * This prop can be useful in SEO situation or\n * when you want to maximize the responsiveness of the Popper.\n * @default false\n */\n keepMounted: PropTypes.bool,\n /**\n * Popper.js is based on a \"plugin-like\" architecture,\n * most of its features are fully encapsulated \"modifiers\".\n *\n * A modifier is a function that is called each time Popper.js needs to\n * compute the position of the popper.\n * For this reason, modifiers should be very performant to avoid bottlenecks.\n * To learn how to create a modifier, [read the modifiers documentation](https://popper.js.org/docs/v2/modifiers/).\n */\n modifiers: PropTypes.arrayOf(PropTypes.shape({\n data: PropTypes.object,\n effect: PropTypes.func,\n enabled: PropTypes.bool,\n fn: PropTypes.func,\n name: PropTypes.any,\n options: PropTypes.object,\n phase: PropTypes.oneOf(['afterMain', 'afterRead', 'afterWrite', 'beforeMain', 'beforeRead', 'beforeWrite', 'main', 'read', 'write']),\n requires: PropTypes.arrayOf(PropTypes.string),\n requiresIfExists: PropTypes.arrayOf(PropTypes.string)\n })),\n /**\n * If `true`, the component is shown.\n */\n open: PropTypes.bool.isRequired,\n /**\n * Popper placement.\n * @default 'bottom'\n */\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n /**\n * Options provided to the [`Popper.js`](https://popper.js.org/docs/v2/constructors/#options) instance.\n * @default {}\n */\n popperOptions: PropTypes.shape({\n modifiers: PropTypes.array,\n onFirstUpdate: PropTypes.func,\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n strategy: PropTypes.oneOf(['absolute', 'fixed'])\n }),\n /**\n * A ref that points to the used popper instance.\n */\n popperRef: refType,\n /**\n * The props used for each slot inside the Popper.\n * @default {}\n */\n slotProps: PropTypes.shape({\n root: PropTypes.oneOfType([PropTypes.func, PropTypes.object])\n }),\n /**\n * The components used for each slot inside the Popper.\n * Either a string to use a HTML element or a component.\n * @default {}\n */\n slots: PropTypes.shape({\n root: PropTypes.elementType\n }),\n /**\n * Help supporting a react-transition-group/Transition component.\n * @default false\n */\n transition: PropTypes.bool\n} : void 0;\nexport { Popper };","'use client';\n\nimport * as React from 'react';\nimport { useTheme as useThemeSystem } from '@mui/system';\nimport defaultTheme from './defaultTheme';\nimport THEME_ID from './identifier';\nexport default function useTheme() {\n const theme = useThemeSystem(defaultTheme);\n if (process.env.NODE_ENV !== 'production') {\n // eslint-disable-next-line react-hooks/rules-of-hooks\n React.useDebugValue(theme);\n }\n return theme[THEME_ID] || theme;\n}","export default function _setPrototypeOf(o, p) {\n _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function _setPrototypeOf(o, p) {\n o.__proto__ = p;\n return o;\n };\n return _setPrototypeOf(o, p);\n}","import setPrototypeOf from \"./setPrototypeOf.js\";\nexport default function _inheritsLoose(subClass, superClass) {\n subClass.prototype = Object.create(superClass.prototype);\n subClass.prototype.constructor = subClass;\n setPrototypeOf(subClass, superClass);\n}","export default {\n disabled: false\n};","import PropTypes from 'prop-types';\nexport var timeoutsShape = process.env.NODE_ENV !== 'production' ? PropTypes.oneOfType([PropTypes.number, PropTypes.shape({\n enter: PropTypes.number,\n exit: PropTypes.number,\n appear: PropTypes.number\n}).isRequired]) : null;\nexport var classNamesShape = process.env.NODE_ENV !== 'production' ? PropTypes.oneOfType([PropTypes.string, PropTypes.shape({\n enter: PropTypes.string,\n exit: PropTypes.string,\n active: PropTypes.string\n}), PropTypes.shape({\n enter: PropTypes.string,\n enterDone: PropTypes.string,\n enterActive: PropTypes.string,\n exit: PropTypes.string,\n exitDone: PropTypes.string,\n exitActive: PropTypes.string\n})]) : null;","import React from 'react';\nexport default React.createContext(null);","export var forceReflow = function forceReflow(node) {\n return node.scrollTop;\n};","import _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _inheritsLoose from \"@babel/runtime/helpers/esm/inheritsLoose\";\nimport PropTypes from 'prop-types';\nimport React from 'react';\nimport ReactDOM from 'react-dom';\nimport config from './config';\nimport { timeoutsShape } from './utils/PropTypes';\nimport TransitionGroupContext from './TransitionGroupContext';\nimport { forceReflow } from './utils/reflow';\nexport var UNMOUNTED = 'unmounted';\nexport var EXITED = 'exited';\nexport var ENTERING = 'entering';\nexport var ENTERED = 'entered';\nexport var EXITING = 'exiting';\n/**\n * The Transition component lets you describe a transition from one component\n * state to another _over time_ with a simple declarative API. Most commonly\n * it's used to animate the mounting and unmounting of a component, but can also\n * be used to describe in-place transition states as well.\n *\n * ---\n *\n * **Note**: `Transition` is a platform-agnostic base component. If you're using\n * transitions in CSS, you'll probably want to use\n * [`CSSTransition`](https://reactcommunity.org/react-transition-group/css-transition)\n * instead. It inherits all the features of `Transition`, but contains\n * additional features necessary to play nice with CSS transitions (hence the\n * name of the component).\n *\n * ---\n *\n * By default the `Transition` component does not alter the behavior of the\n * component it renders, it only tracks \"enter\" and \"exit\" states for the\n * components. It's up to you to give meaning and effect to those states. For\n * example we can add styles to a component when it enters or exits:\n *\n * ```jsx\n * import { Transition } from 'react-transition-group';\n *\n * const duration = 300;\n *\n * const defaultStyle = {\n * transition: `opacity ${duration}ms ease-in-out`,\n * opacity: 0,\n * }\n *\n * const transitionStyles = {\n * entering: { opacity: 1 },\n * entered: { opacity: 1 },\n * exiting: { opacity: 0 },\n * exited: { opacity: 0 },\n * };\n *\n * const Fade = ({ in: inProp }) => (\n * \n * {state => (\n *
    \n * I'm a fade Transition!\n *
    \n * )}\n *
    \n * );\n * ```\n *\n * There are 4 main states a Transition can be in:\n * - `'entering'`\n * - `'entered'`\n * - `'exiting'`\n * - `'exited'`\n *\n * Transition state is toggled via the `in` prop. When `true` the component\n * begins the \"Enter\" stage. During this stage, the component will shift from\n * its current transition state, to `'entering'` for the duration of the\n * transition and then to the `'entered'` stage once it's complete. Let's take\n * the following example (we'll use the\n * [useState](https://reactjs.org/docs/hooks-reference.html#usestate) hook):\n *\n * ```jsx\n * function App() {\n * const [inProp, setInProp] = useState(false);\n * return (\n *
    \n * \n * {state => (\n * // ...\n * )}\n * \n * \n *
    \n * );\n * }\n * ```\n *\n * When the button is clicked the component will shift to the `'entering'` state\n * and stay there for 500ms (the value of `timeout`) before it finally switches\n * to `'entered'`.\n *\n * When `in` is `false` the same thing happens except the state moves from\n * `'exiting'` to `'exited'`.\n */\n\nvar Transition = /*#__PURE__*/function (_React$Component) {\n _inheritsLoose(Transition, _React$Component);\n\n function Transition(props, context) {\n var _this;\n\n _this = _React$Component.call(this, props, context) || this;\n var parentGroup = context; // In the context of a TransitionGroup all enters are really appears\n\n var appear = parentGroup && !parentGroup.isMounting ? props.enter : props.appear;\n var initialStatus;\n _this.appearStatus = null;\n\n if (props.in) {\n if (appear) {\n initialStatus = EXITED;\n _this.appearStatus = ENTERING;\n } else {\n initialStatus = ENTERED;\n }\n } else {\n if (props.unmountOnExit || props.mountOnEnter) {\n initialStatus = UNMOUNTED;\n } else {\n initialStatus = EXITED;\n }\n }\n\n _this.state = {\n status: initialStatus\n };\n _this.nextCallback = null;\n return _this;\n }\n\n Transition.getDerivedStateFromProps = function getDerivedStateFromProps(_ref, prevState) {\n var nextIn = _ref.in;\n\n if (nextIn && prevState.status === UNMOUNTED) {\n return {\n status: EXITED\n };\n }\n\n return null;\n } // getSnapshotBeforeUpdate(prevProps) {\n // let nextStatus = null\n // if (prevProps !== this.props) {\n // const { status } = this.state\n // if (this.props.in) {\n // if (status !== ENTERING && status !== ENTERED) {\n // nextStatus = ENTERING\n // }\n // } else {\n // if (status === ENTERING || status === ENTERED) {\n // nextStatus = EXITING\n // }\n // }\n // }\n // return { nextStatus }\n // }\n ;\n\n var _proto = Transition.prototype;\n\n _proto.componentDidMount = function componentDidMount() {\n this.updateStatus(true, this.appearStatus);\n };\n\n _proto.componentDidUpdate = function componentDidUpdate(prevProps) {\n var nextStatus = null;\n\n if (prevProps !== this.props) {\n var status = this.state.status;\n\n if (this.props.in) {\n if (status !== ENTERING && status !== ENTERED) {\n nextStatus = ENTERING;\n }\n } else {\n if (status === ENTERING || status === ENTERED) {\n nextStatus = EXITING;\n }\n }\n }\n\n this.updateStatus(false, nextStatus);\n };\n\n _proto.componentWillUnmount = function componentWillUnmount() {\n this.cancelNextCallback();\n };\n\n _proto.getTimeouts = function getTimeouts() {\n var timeout = this.props.timeout;\n var exit, enter, appear;\n exit = enter = appear = timeout;\n\n if (timeout != null && typeof timeout !== 'number') {\n exit = timeout.exit;\n enter = timeout.enter; // TODO: remove fallback for next major\n\n appear = timeout.appear !== undefined ? timeout.appear : enter;\n }\n\n return {\n exit: exit,\n enter: enter,\n appear: appear\n };\n };\n\n _proto.updateStatus = function updateStatus(mounting, nextStatus) {\n if (mounting === void 0) {\n mounting = false;\n }\n\n if (nextStatus !== null) {\n // nextStatus will always be ENTERING or EXITING.\n this.cancelNextCallback();\n\n if (nextStatus === ENTERING) {\n if (this.props.unmountOnExit || this.props.mountOnEnter) {\n var node = this.props.nodeRef ? this.props.nodeRef.current : ReactDOM.findDOMNode(this); // https://github.com/reactjs/react-transition-group/pull/749\n // With unmountOnExit or mountOnEnter, the enter animation should happen at the transition between `exited` and `entering`.\n // To make the animation happen, we have to separate each rendering and avoid being processed as batched.\n\n if (node) forceReflow(node);\n }\n\n this.performEnter(mounting);\n } else {\n this.performExit();\n }\n } else if (this.props.unmountOnExit && this.state.status === EXITED) {\n this.setState({\n status: UNMOUNTED\n });\n }\n };\n\n _proto.performEnter = function performEnter(mounting) {\n var _this2 = this;\n\n var enter = this.props.enter;\n var appearing = this.context ? this.context.isMounting : mounting;\n\n var _ref2 = this.props.nodeRef ? [appearing] : [ReactDOM.findDOMNode(this), appearing],\n maybeNode = _ref2[0],\n maybeAppearing = _ref2[1];\n\n var timeouts = this.getTimeouts();\n var enterTimeout = appearing ? timeouts.appear : timeouts.enter; // no enter animation skip right to ENTERED\n // if we are mounting and running this it means appear _must_ be set\n\n if (!mounting && !enter || config.disabled) {\n this.safeSetState({\n status: ENTERED\n }, function () {\n _this2.props.onEntered(maybeNode);\n });\n return;\n }\n\n this.props.onEnter(maybeNode, maybeAppearing);\n this.safeSetState({\n status: ENTERING\n }, function () {\n _this2.props.onEntering(maybeNode, maybeAppearing);\n\n _this2.onTransitionEnd(enterTimeout, function () {\n _this2.safeSetState({\n status: ENTERED\n }, function () {\n _this2.props.onEntered(maybeNode, maybeAppearing);\n });\n });\n });\n };\n\n _proto.performExit = function performExit() {\n var _this3 = this;\n\n var exit = this.props.exit;\n var timeouts = this.getTimeouts();\n var maybeNode = this.props.nodeRef ? undefined : ReactDOM.findDOMNode(this); // no exit animation skip right to EXITED\n\n if (!exit || config.disabled) {\n this.safeSetState({\n status: EXITED\n }, function () {\n _this3.props.onExited(maybeNode);\n });\n return;\n }\n\n this.props.onExit(maybeNode);\n this.safeSetState({\n status: EXITING\n }, function () {\n _this3.props.onExiting(maybeNode);\n\n _this3.onTransitionEnd(timeouts.exit, function () {\n _this3.safeSetState({\n status: EXITED\n }, function () {\n _this3.props.onExited(maybeNode);\n });\n });\n });\n };\n\n _proto.cancelNextCallback = function cancelNextCallback() {\n if (this.nextCallback !== null) {\n this.nextCallback.cancel();\n this.nextCallback = null;\n }\n };\n\n _proto.safeSetState = function safeSetState(nextState, callback) {\n // This shouldn't be necessary, but there are weird race conditions with\n // setState callbacks and unmounting in testing, so always make sure that\n // we can cancel any pending setState callbacks after we unmount.\n callback = this.setNextCallback(callback);\n this.setState(nextState, callback);\n };\n\n _proto.setNextCallback = function setNextCallback(callback) {\n var _this4 = this;\n\n var active = true;\n\n this.nextCallback = function (event) {\n if (active) {\n active = false;\n _this4.nextCallback = null;\n callback(event);\n }\n };\n\n this.nextCallback.cancel = function () {\n active = false;\n };\n\n return this.nextCallback;\n };\n\n _proto.onTransitionEnd = function onTransitionEnd(timeout, handler) {\n this.setNextCallback(handler);\n var node = this.props.nodeRef ? this.props.nodeRef.current : ReactDOM.findDOMNode(this);\n var doesNotHaveTimeoutOrListener = timeout == null && !this.props.addEndListener;\n\n if (!node || doesNotHaveTimeoutOrListener) {\n setTimeout(this.nextCallback, 0);\n return;\n }\n\n if (this.props.addEndListener) {\n var _ref3 = this.props.nodeRef ? [this.nextCallback] : [node, this.nextCallback],\n maybeNode = _ref3[0],\n maybeNextCallback = _ref3[1];\n\n this.props.addEndListener(maybeNode, maybeNextCallback);\n }\n\n if (timeout != null) {\n setTimeout(this.nextCallback, timeout);\n }\n };\n\n _proto.render = function render() {\n var status = this.state.status;\n\n if (status === UNMOUNTED) {\n return null;\n }\n\n var _this$props = this.props,\n children = _this$props.children,\n _in = _this$props.in,\n _mountOnEnter = _this$props.mountOnEnter,\n _unmountOnExit = _this$props.unmountOnExit,\n _appear = _this$props.appear,\n _enter = _this$props.enter,\n _exit = _this$props.exit,\n _timeout = _this$props.timeout,\n _addEndListener = _this$props.addEndListener,\n _onEnter = _this$props.onEnter,\n _onEntering = _this$props.onEntering,\n _onEntered = _this$props.onEntered,\n _onExit = _this$props.onExit,\n _onExiting = _this$props.onExiting,\n _onExited = _this$props.onExited,\n _nodeRef = _this$props.nodeRef,\n childProps = _objectWithoutPropertiesLoose(_this$props, [\"children\", \"in\", \"mountOnEnter\", \"unmountOnExit\", \"appear\", \"enter\", \"exit\", \"timeout\", \"addEndListener\", \"onEnter\", \"onEntering\", \"onEntered\", \"onExit\", \"onExiting\", \"onExited\", \"nodeRef\"]);\n\n return (\n /*#__PURE__*/\n // allows for nested Transitions\n React.createElement(TransitionGroupContext.Provider, {\n value: null\n }, typeof children === 'function' ? children(status, childProps) : React.cloneElement(React.Children.only(children), childProps))\n );\n };\n\n return Transition;\n}(React.Component);\n\nTransition.contextType = TransitionGroupContext;\nTransition.propTypes = process.env.NODE_ENV !== \"production\" ? {\n /**\n * A React reference to DOM element that need to transition:\n * https://stackoverflow.com/a/51127130/4671932\n *\n * - When `nodeRef` prop is used, `node` is not passed to callback functions\n * (e.g. `onEnter`) because user already has direct access to the node.\n * - When changing `key` prop of `Transition` in a `TransitionGroup` a new\n * `nodeRef` need to be provided to `Transition` with changed `key` prop\n * (see\n * [test/CSSTransition-test.js](https://github.com/reactjs/react-transition-group/blob/13435f897b3ab71f6e19d724f145596f5910581c/test/CSSTransition-test.js#L362-L437)).\n */\n nodeRef: PropTypes.shape({\n current: typeof Element === 'undefined' ? PropTypes.any : function (propValue, key, componentName, location, propFullName, secret) {\n var value = propValue[key];\n return PropTypes.instanceOf(value && 'ownerDocument' in value ? value.ownerDocument.defaultView.Element : Element)(propValue, key, componentName, location, propFullName, secret);\n }\n }),\n\n /**\n * A `function` child can be used instead of a React element. This function is\n * called with the current transition status (`'entering'`, `'entered'`,\n * `'exiting'`, `'exited'`), which can be used to apply context\n * specific props to a component.\n *\n * ```jsx\n * \n * {state => (\n * \n * )}\n * \n * ```\n */\n children: PropTypes.oneOfType([PropTypes.func.isRequired, PropTypes.element.isRequired]).isRequired,\n\n /**\n * Show the component; triggers the enter or exit states\n */\n in: PropTypes.bool,\n\n /**\n * By default the child component is mounted immediately along with\n * the parent `Transition` component. If you want to \"lazy mount\" the component on the\n * first `in={true}` you can set `mountOnEnter`. After the first enter transition the component will stay\n * mounted, even on \"exited\", unless you also specify `unmountOnExit`.\n */\n mountOnEnter: PropTypes.bool,\n\n /**\n * By default the child component stays mounted after it reaches the `'exited'` state.\n * Set `unmountOnExit` if you'd prefer to unmount the component after it finishes exiting.\n */\n unmountOnExit: PropTypes.bool,\n\n /**\n * By default the child component does not perform the enter transition when\n * it first mounts, regardless of the value of `in`. If you want this\n * behavior, set both `appear` and `in` to `true`.\n *\n * > **Note**: there are no special appear states like `appearing`/`appeared`, this prop\n * > only adds an additional enter transition. However, in the\n * > `` component that first enter transition does result in\n * > additional `.appear-*` classes, that way you can choose to style it\n * > differently.\n */\n appear: PropTypes.bool,\n\n /**\n * Enable or disable enter transitions.\n */\n enter: PropTypes.bool,\n\n /**\n * Enable or disable exit transitions.\n */\n exit: PropTypes.bool,\n\n /**\n * The duration of the transition, in milliseconds.\n * Required unless `addEndListener` is provided.\n *\n * You may specify a single timeout for all transitions:\n *\n * ```jsx\n * timeout={500}\n * ```\n *\n * or individually:\n *\n * ```jsx\n * timeout={{\n * appear: 500,\n * enter: 300,\n * exit: 500,\n * }}\n * ```\n *\n * - `appear` defaults to the value of `enter`\n * - `enter` defaults to `0`\n * - `exit` defaults to `0`\n *\n * @type {number | { enter?: number, exit?: number, appear?: number }}\n */\n timeout: function timeout(props) {\n var pt = timeoutsShape;\n if (!props.addEndListener) pt = pt.isRequired;\n\n for (var _len = arguments.length, args = new Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) {\n args[_key - 1] = arguments[_key];\n }\n\n return pt.apply(void 0, [props].concat(args));\n },\n\n /**\n * Add a custom transition end trigger. Called with the transitioning\n * DOM node and a `done` callback. Allows for more fine grained transition end\n * logic. Timeouts are still used as a fallback if provided.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * ```jsx\n * addEndListener={(node, done) => {\n * // use the css transitionend event to mark the finish of a transition\n * node.addEventListener('transitionend', done, false);\n * }}\n * ```\n */\n addEndListener: PropTypes.func,\n\n /**\n * Callback fired before the \"entering\" status is applied. An extra parameter\n * `isAppearing` is supplied to indicate if the enter stage is occurring on the initial mount\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement, isAppearing: bool) -> void\n */\n onEnter: PropTypes.func,\n\n /**\n * Callback fired after the \"entering\" status is applied. An extra parameter\n * `isAppearing` is supplied to indicate if the enter stage is occurring on the initial mount\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement, isAppearing: bool)\n */\n onEntering: PropTypes.func,\n\n /**\n * Callback fired after the \"entered\" status is applied. An extra parameter\n * `isAppearing` is supplied to indicate if the enter stage is occurring on the initial mount\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement, isAppearing: bool) -> void\n */\n onEntered: PropTypes.func,\n\n /**\n * Callback fired before the \"exiting\" status is applied.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement) -> void\n */\n onExit: PropTypes.func,\n\n /**\n * Callback fired after the \"exiting\" status is applied.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement) -> void\n */\n onExiting: PropTypes.func,\n\n /**\n * Callback fired after the \"exited\" status is applied.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed\n *\n * @type Function(node: HtmlElement) -> void\n */\n onExited: PropTypes.func\n} : {}; // Name the function so it is clearer in the documentation\n\nfunction noop() {}\n\nTransition.defaultProps = {\n in: false,\n mountOnEnter: false,\n unmountOnExit: false,\n appear: false,\n enter: true,\n exit: true,\n onEnter: noop,\n onEntering: noop,\n onEntered: noop,\n onExit: noop,\n onExiting: noop,\n onExited: noop\n};\nTransition.UNMOUNTED = UNMOUNTED;\nTransition.EXITED = EXITED;\nTransition.ENTERING = ENTERING;\nTransition.ENTERED = ENTERED;\nTransition.EXITING = EXITING;\nexport default Transition;","export const reflow = node => node.scrollTop;\nexport function getTransitionProps(props, options) {\n var _style$transitionDura, _style$transitionTimi;\n const {\n timeout,\n easing,\n style = {}\n } = props;\n return {\n duration: (_style$transitionDura = style.transitionDuration) != null ? _style$transitionDura : typeof timeout === 'number' ? timeout : timeout[options.mode] || 0,\n easing: (_style$transitionTimi = style.transitionTimingFunction) != null ? _style$transitionTimi : typeof easing === 'object' ? easing[options.mode] : easing,\n delay: style.transitionDelay\n };\n}","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"addEndListener\", \"appear\", \"children\", \"easing\", \"in\", \"onEnter\", \"onEntered\", \"onEntering\", \"onExit\", \"onExited\", \"onExiting\", \"style\", \"timeout\", \"TransitionComponent\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport { elementAcceptingRef, unstable_useTimeout as useTimeout } from '@mui/utils';\nimport { Transition } from 'react-transition-group';\nimport useTheme from '../styles/useTheme';\nimport { getTransitionProps, reflow } from '../transitions/utils';\nimport useForkRef from '../utils/useForkRef';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nfunction getScale(value) {\n return `scale(${value}, ${value ** 2})`;\n}\nconst styles = {\n entering: {\n opacity: 1,\n transform: getScale(1)\n },\n entered: {\n opacity: 1,\n transform: 'none'\n }\n};\n\n/*\n TODO v6: remove\n Conditionally apply a workaround for the CSS transition bug in Safari 15.4 / WebKit browsers.\n */\nconst isWebKit154 = typeof navigator !== 'undefined' && /^((?!chrome|android).)*(safari|mobile)/i.test(navigator.userAgent) && /(os |version\\/)15(.|_)4/i.test(navigator.userAgent);\n\n/**\n * The Grow transition is used by the [Tooltip](/material-ui/react-tooltip/) and\n * [Popover](/material-ui/react-popover/) components.\n * It uses [react-transition-group](https://github.com/reactjs/react-transition-group) internally.\n */\nconst Grow = /*#__PURE__*/React.forwardRef(function Grow(props, ref) {\n const {\n addEndListener,\n appear = true,\n children,\n easing,\n in: inProp,\n onEnter,\n onEntered,\n onEntering,\n onExit,\n onExited,\n onExiting,\n style,\n timeout = 'auto',\n // eslint-disable-next-line react/prop-types\n TransitionComponent = Transition\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const timer = useTimeout();\n const autoTimeout = React.useRef();\n const theme = useTheme();\n const nodeRef = React.useRef(null);\n const handleRef = useForkRef(nodeRef, children.ref, ref);\n const normalizedTransitionCallback = callback => maybeIsAppearing => {\n if (callback) {\n const node = nodeRef.current;\n\n // onEnterXxx and onExitXxx callbacks have a different arguments.length value.\n if (maybeIsAppearing === undefined) {\n callback(node);\n } else {\n callback(node, maybeIsAppearing);\n }\n }\n };\n const handleEntering = normalizedTransitionCallback(onEntering);\n const handleEnter = normalizedTransitionCallback((node, isAppearing) => {\n reflow(node); // So the animation always start from the start.\n\n const {\n duration: transitionDuration,\n delay,\n easing: transitionTimingFunction\n } = getTransitionProps({\n style,\n timeout,\n easing\n }, {\n mode: 'enter'\n });\n let duration;\n if (timeout === 'auto') {\n duration = theme.transitions.getAutoHeightDuration(node.clientHeight);\n autoTimeout.current = duration;\n } else {\n duration = transitionDuration;\n }\n node.style.transition = [theme.transitions.create('opacity', {\n duration,\n delay\n }), theme.transitions.create('transform', {\n duration: isWebKit154 ? duration : duration * 0.666,\n delay,\n easing: transitionTimingFunction\n })].join(',');\n if (onEnter) {\n onEnter(node, isAppearing);\n }\n });\n const handleEntered = normalizedTransitionCallback(onEntered);\n const handleExiting = normalizedTransitionCallback(onExiting);\n const handleExit = normalizedTransitionCallback(node => {\n const {\n duration: transitionDuration,\n delay,\n easing: transitionTimingFunction\n } = getTransitionProps({\n style,\n timeout,\n easing\n }, {\n mode: 'exit'\n });\n let duration;\n if (timeout === 'auto') {\n duration = theme.transitions.getAutoHeightDuration(node.clientHeight);\n autoTimeout.current = duration;\n } else {\n duration = transitionDuration;\n }\n node.style.transition = [theme.transitions.create('opacity', {\n duration,\n delay\n }), theme.transitions.create('transform', {\n duration: isWebKit154 ? duration : duration * 0.666,\n delay: isWebKit154 ? delay : delay || duration * 0.333,\n easing: transitionTimingFunction\n })].join(',');\n node.style.opacity = 0;\n node.style.transform = getScale(0.75);\n if (onExit) {\n onExit(node);\n }\n });\n const handleExited = normalizedTransitionCallback(onExited);\n const handleAddEndListener = next => {\n if (timeout === 'auto') {\n timer.start(autoTimeout.current || 0, next);\n }\n if (addEndListener) {\n // Old call signature before `react-transition-group` implemented `nodeRef`\n addEndListener(nodeRef.current, next);\n }\n };\n return /*#__PURE__*/_jsx(TransitionComponent, _extends({\n appear: appear,\n in: inProp,\n nodeRef: nodeRef,\n onEnter: handleEnter,\n onEntered: handleEntered,\n onEntering: handleEntering,\n onExit: handleExit,\n onExited: handleExited,\n onExiting: handleExiting,\n addEndListener: handleAddEndListener,\n timeout: timeout === 'auto' ? null : timeout\n }, other, {\n children: (state, childProps) => {\n return /*#__PURE__*/React.cloneElement(children, _extends({\n style: _extends({\n opacity: 0,\n transform: getScale(0.75),\n visibility: state === 'exited' && !inProp ? 'hidden' : undefined\n }, styles[state], style, children.props.style),\n ref: handleRef\n }, childProps));\n }\n }));\n});\nprocess.env.NODE_ENV !== \"production\" ? Grow.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the d.ts file and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * Add a custom transition end trigger. Called with the transitioning DOM\n * node and a done callback. Allows for more fine grained transition end\n * logic. Note: Timeouts are still used as a fallback if provided.\n */\n addEndListener: PropTypes.func,\n /**\n * Perform the enter transition when it first mounts if `in` is also `true`.\n * Set this to `false` to disable this behavior.\n * @default true\n */\n appear: PropTypes.bool,\n /**\n * A single child content element.\n */\n children: elementAcceptingRef.isRequired,\n /**\n * The transition timing function.\n * You may specify a single easing or a object containing enter and exit values.\n */\n easing: PropTypes.oneOfType([PropTypes.shape({\n enter: PropTypes.string,\n exit: PropTypes.string\n }), PropTypes.string]),\n /**\n * If `true`, the component will transition in.\n */\n in: PropTypes.bool,\n /**\n * @ignore\n */\n onEnter: PropTypes.func,\n /**\n * @ignore\n */\n onEntered: PropTypes.func,\n /**\n * @ignore\n */\n onEntering: PropTypes.func,\n /**\n * @ignore\n */\n onExit: PropTypes.func,\n /**\n * @ignore\n */\n onExited: PropTypes.func,\n /**\n * @ignore\n */\n onExiting: PropTypes.func,\n /**\n * @ignore\n */\n style: PropTypes.object,\n /**\n * The duration for the transition, in milliseconds.\n * You may specify a single timeout for all transitions, or individually with an object.\n *\n * Set to 'auto' to automatically calculate transition time based on height.\n * @default 'auto'\n */\n timeout: PropTypes.oneOfType([PropTypes.oneOf(['auto']), PropTypes.number, PropTypes.shape({\n appear: PropTypes.number,\n enter: PropTypes.number,\n exit: PropTypes.number\n })])\n} : void 0;\nGrow.muiSupportAuto = true;\nexport default Grow;","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"anchorEl\", \"component\", \"components\", \"componentsProps\", \"container\", \"disablePortal\", \"keepMounted\", \"modifiers\", \"open\", \"placement\", \"popperOptions\", \"popperRef\", \"transition\", \"slots\", \"slotProps\"];\nimport { Popper as BasePopper } from '@mui/base/Popper';\nimport { useThemeWithoutDefault as useTheme } from '@mui/system';\nimport { HTMLElementType, refType } from '@mui/utils';\nimport PropTypes from 'prop-types';\nimport * as React from 'react';\nimport { styled, useThemeProps } from '../styles';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nconst PopperRoot = styled(BasePopper, {\n name: 'MuiPopper',\n slot: 'Root',\n overridesResolver: (props, styles) => styles.root\n})({});\n\n/**\n *\n * Demos:\n *\n * - [Autocomplete](https://mui.com/material-ui/react-autocomplete/)\n * - [Menu](https://mui.com/material-ui/react-menu/)\n * - [Popper](https://mui.com/material-ui/react-popper/)\n *\n * API:\n *\n * - [Popper API](https://mui.com/material-ui/api/popper/)\n */\nconst Popper = /*#__PURE__*/React.forwardRef(function Popper(inProps, ref) {\n var _slots$root;\n const theme = useTheme();\n const props = useThemeProps({\n props: inProps,\n name: 'MuiPopper'\n });\n const {\n anchorEl,\n component,\n components,\n componentsProps,\n container,\n disablePortal,\n keepMounted,\n modifiers,\n open,\n placement,\n popperOptions,\n popperRef,\n transition,\n slots,\n slotProps\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const RootComponent = (_slots$root = slots == null ? void 0 : slots.root) != null ? _slots$root : components == null ? void 0 : components.Root;\n const otherProps = _extends({\n anchorEl,\n container,\n disablePortal,\n keepMounted,\n modifiers,\n open,\n placement,\n popperOptions,\n popperRef,\n transition\n }, other);\n return /*#__PURE__*/_jsx(PopperRoot, _extends({\n as: component,\n direction: theme == null ? void 0 : theme.direction,\n slots: {\n root: RootComponent\n },\n slotProps: slotProps != null ? slotProps : componentsProps\n }, otherProps, {\n ref: ref\n }));\n});\nprocess.env.NODE_ENV !== \"production\" ? Popper.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * An HTML element, [virtualElement](https://popper.js.org/docs/v2/virtual-elements/),\n * or a function that returns either.\n * It's used to set the position of the popper.\n * The return value will passed as the reference object of the Popper instance.\n */\n anchorEl: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.object, PropTypes.func]),\n /**\n * Popper render function or node.\n */\n children: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.node, PropTypes.func]),\n /**\n * The component used for the root node.\n * Either a string to use a HTML element or a component.\n */\n component: PropTypes.elementType,\n /**\n * The components used for each slot inside the Popper.\n * Either a string to use a HTML element or a component.\n * @default {}\n */\n components: PropTypes.shape({\n Root: PropTypes.elementType\n }),\n /**\n * The props used for each slot inside the Popper.\n * @default {}\n */\n componentsProps: PropTypes.shape({\n root: PropTypes.oneOfType([PropTypes.func, PropTypes.object])\n }),\n /**\n * An HTML element or function that returns one.\n * The `container` will have the portal children appended to it.\n *\n * You can also provide a callback, which is called in a React layout effect.\n * This lets you set the container from a ref, and also makes server-side rendering possible.\n *\n * By default, it uses the body of the top-level document object,\n * so it's simply `document.body` most of the time.\n */\n container: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.func]),\n /**\n * The `children` will be under the DOM hierarchy of the parent component.\n * @default false\n */\n disablePortal: PropTypes.bool,\n /**\n * Always keep the children in the DOM.\n * This prop can be useful in SEO situation or\n * when you want to maximize the responsiveness of the Popper.\n * @default false\n */\n keepMounted: PropTypes.bool,\n /**\n * Popper.js is based on a \"plugin-like\" architecture,\n * most of its features are fully encapsulated \"modifiers\".\n *\n * A modifier is a function that is called each time Popper.js needs to\n * compute the position of the popper.\n * For this reason, modifiers should be very performant to avoid bottlenecks.\n * To learn how to create a modifier, [read the modifiers documentation](https://popper.js.org/docs/v2/modifiers/).\n */\n modifiers: PropTypes.arrayOf(PropTypes.shape({\n data: PropTypes.object,\n effect: PropTypes.func,\n enabled: PropTypes.bool,\n fn: PropTypes.func,\n name: PropTypes.any,\n options: PropTypes.object,\n phase: PropTypes.oneOf(['afterMain', 'afterRead', 'afterWrite', 'beforeMain', 'beforeRead', 'beforeWrite', 'main', 'read', 'write']),\n requires: PropTypes.arrayOf(PropTypes.string),\n requiresIfExists: PropTypes.arrayOf(PropTypes.string)\n })),\n /**\n * If `true`, the component is shown.\n */\n open: PropTypes.bool.isRequired,\n /**\n * Popper placement.\n * @default 'bottom'\n */\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n /**\n * Options provided to the [`Popper.js`](https://popper.js.org/docs/v2/constructors/#options) instance.\n * @default {}\n */\n popperOptions: PropTypes.shape({\n modifiers: PropTypes.array,\n onFirstUpdate: PropTypes.func,\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n strategy: PropTypes.oneOf(['absolute', 'fixed'])\n }),\n /**\n * A ref that points to the used popper instance.\n */\n popperRef: refType,\n /**\n * The props used for each slot inside the Popper.\n * @default {}\n */\n slotProps: PropTypes.shape({\n root: PropTypes.oneOfType([PropTypes.func, PropTypes.object])\n }),\n /**\n * The components used for each slot inside the Popper.\n * Either a string to use a HTML element or a component.\n * @default {}\n */\n slots: PropTypes.shape({\n root: PropTypes.elementType\n }),\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Help supporting a react-transition-group/Transition component.\n * @default false\n */\n transition: PropTypes.bool\n} : void 0;\nexport default Popper;","import generateUtilityClasses from '@mui/utils/generateUtilityClasses';\nimport generateUtilityClass from '@mui/utils/generateUtilityClass';\nexport function getTooltipUtilityClass(slot) {\n return generateUtilityClass('MuiTooltip', slot);\n}\nconst tooltipClasses = generateUtilityClasses('MuiTooltip', ['popper', 'popperInteractive', 'popperArrow', 'popperClose', 'tooltip', 'tooltipArrow', 'touch', 'tooltipPlacementLeft', 'tooltipPlacementRight', 'tooltipPlacementTop', 'tooltipPlacementBottom', 'arrow']);\nexport default tooltipClasses;","'use client';\n\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nconst _excluded = [\"arrow\", \"children\", \"classes\", \"components\", \"componentsProps\", \"describeChild\", \"disableFocusListener\", \"disableHoverListener\", \"disableInteractive\", \"disableTouchListener\", \"enterDelay\", \"enterNextDelay\", \"enterTouchDelay\", \"followCursor\", \"id\", \"leaveDelay\", \"leaveTouchDelay\", \"onClose\", \"onOpen\", \"open\", \"placement\", \"PopperComponent\", \"PopperProps\", \"slotProps\", \"slots\", \"title\", \"TransitionComponent\", \"TransitionProps\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport clsx from 'clsx';\nimport { elementAcceptingRef, unstable_useTimeout as useTimeout, unstable_Timeout as Timeout } from '@mui/utils';\nimport { unstable_composeClasses as composeClasses, appendOwnerState } from '@mui/base';\nimport { alpha } from '@mui/system';\nimport styled from '../styles/styled';\nimport useTheme from '../styles/useTheme';\nimport useThemeProps from '../styles/useThemeProps';\nimport capitalize from '../utils/capitalize';\nimport Grow from '../Grow';\nimport Popper from '../Popper';\nimport useEventCallback from '../utils/useEventCallback';\nimport useForkRef from '../utils/useForkRef';\nimport useId from '../utils/useId';\nimport useIsFocusVisible from '../utils/useIsFocusVisible';\nimport useControlled from '../utils/useControlled';\nimport tooltipClasses, { getTooltipUtilityClass } from './tooltipClasses';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nimport { jsxs as _jsxs } from \"react/jsx-runtime\";\nfunction round(value) {\n return Math.round(value * 1e5) / 1e5;\n}\nconst useUtilityClasses = ownerState => {\n const {\n classes,\n disableInteractive,\n arrow,\n touch,\n placement\n } = ownerState;\n const slots = {\n popper: ['popper', !disableInteractive && 'popperInteractive', arrow && 'popperArrow'],\n tooltip: ['tooltip', arrow && 'tooltipArrow', touch && 'touch', `tooltipPlacement${capitalize(placement.split('-')[0])}`],\n arrow: ['arrow']\n };\n return composeClasses(slots, getTooltipUtilityClass, classes);\n};\nconst TooltipPopper = styled(Popper, {\n name: 'MuiTooltip',\n slot: 'Popper',\n overridesResolver: (props, styles) => {\n const {\n ownerState\n } = props;\n return [styles.popper, !ownerState.disableInteractive && styles.popperInteractive, ownerState.arrow && styles.popperArrow, !ownerState.open && styles.popperClose];\n }\n})(({\n theme,\n ownerState,\n open\n}) => _extends({\n zIndex: (theme.vars || theme).zIndex.tooltip,\n pointerEvents: 'none'\n}, !ownerState.disableInteractive && {\n pointerEvents: 'auto'\n}, !open && {\n pointerEvents: 'none'\n}, ownerState.arrow && {\n [`&[data-popper-placement*=\"bottom\"] .${tooltipClasses.arrow}`]: {\n top: 0,\n marginTop: '-0.71em',\n '&::before': {\n transformOrigin: '0 100%'\n }\n },\n [`&[data-popper-placement*=\"top\"] .${tooltipClasses.arrow}`]: {\n bottom: 0,\n marginBottom: '-0.71em',\n '&::before': {\n transformOrigin: '100% 0'\n }\n },\n [`&[data-popper-placement*=\"right\"] .${tooltipClasses.arrow}`]: _extends({}, !ownerState.isRtl ? {\n left: 0,\n marginLeft: '-0.71em'\n } : {\n right: 0,\n marginRight: '-0.71em'\n }, {\n height: '1em',\n width: '0.71em',\n '&::before': {\n transformOrigin: '100% 100%'\n }\n }),\n [`&[data-popper-placement*=\"left\"] .${tooltipClasses.arrow}`]: _extends({}, !ownerState.isRtl ? {\n right: 0,\n marginRight: '-0.71em'\n } : {\n left: 0,\n marginLeft: '-0.71em'\n }, {\n height: '1em',\n width: '0.71em',\n '&::before': {\n transformOrigin: '0 0'\n }\n })\n}));\nconst TooltipTooltip = styled('div', {\n name: 'MuiTooltip',\n slot: 'Tooltip',\n overridesResolver: (props, styles) => {\n const {\n ownerState\n } = props;\n return [styles.tooltip, ownerState.touch && styles.touch, ownerState.arrow && styles.tooltipArrow, styles[`tooltipPlacement${capitalize(ownerState.placement.split('-')[0])}`]];\n }\n})(({\n theme,\n ownerState\n}) => _extends({\n backgroundColor: theme.vars ? theme.vars.palette.Tooltip.bg : alpha(theme.palette.grey[700], 0.92),\n borderRadius: (theme.vars || theme).shape.borderRadius,\n color: (theme.vars || theme).palette.common.white,\n fontFamily: theme.typography.fontFamily,\n padding: '4px 8px',\n fontSize: theme.typography.pxToRem(11),\n maxWidth: 300,\n margin: 2,\n wordWrap: 'break-word',\n fontWeight: theme.typography.fontWeightMedium\n}, ownerState.arrow && {\n position: 'relative',\n margin: 0\n}, ownerState.touch && {\n padding: '8px 16px',\n fontSize: theme.typography.pxToRem(14),\n lineHeight: `${round(16 / 14)}em`,\n fontWeight: theme.typography.fontWeightRegular\n}, {\n [`.${tooltipClasses.popper}[data-popper-placement*=\"left\"] &`]: _extends({\n transformOrigin: 'right center'\n }, !ownerState.isRtl ? _extends({\n marginRight: '14px'\n }, ownerState.touch && {\n marginRight: '24px'\n }) : _extends({\n marginLeft: '14px'\n }, ownerState.touch && {\n marginLeft: '24px'\n })),\n [`.${tooltipClasses.popper}[data-popper-placement*=\"right\"] &`]: _extends({\n transformOrigin: 'left center'\n }, !ownerState.isRtl ? _extends({\n marginLeft: '14px'\n }, ownerState.touch && {\n marginLeft: '24px'\n }) : _extends({\n marginRight: '14px'\n }, ownerState.touch && {\n marginRight: '24px'\n })),\n [`.${tooltipClasses.popper}[data-popper-placement*=\"top\"] &`]: _extends({\n transformOrigin: 'center bottom',\n marginBottom: '14px'\n }, ownerState.touch && {\n marginBottom: '24px'\n }),\n [`.${tooltipClasses.popper}[data-popper-placement*=\"bottom\"] &`]: _extends({\n transformOrigin: 'center top',\n marginTop: '14px'\n }, ownerState.touch && {\n marginTop: '24px'\n })\n}));\nconst TooltipArrow = styled('span', {\n name: 'MuiTooltip',\n slot: 'Arrow',\n overridesResolver: (props, styles) => styles.arrow\n})(({\n theme\n}) => ({\n overflow: 'hidden',\n position: 'absolute',\n width: '1em',\n height: '0.71em' /* = width / sqrt(2) = (length of the hypotenuse) */,\n boxSizing: 'border-box',\n color: theme.vars ? theme.vars.palette.Tooltip.bg : alpha(theme.palette.grey[700], 0.9),\n '&::before': {\n content: '\"\"',\n margin: 'auto',\n display: 'block',\n width: '100%',\n height: '100%',\n backgroundColor: 'currentColor',\n transform: 'rotate(45deg)'\n }\n}));\nlet hystersisOpen = false;\nconst hystersisTimer = new Timeout();\nlet cursorPosition = {\n x: 0,\n y: 0\n};\nexport function testReset() {\n hystersisOpen = false;\n hystersisTimer.clear();\n}\nfunction composeEventHandler(handler, eventHandler) {\n return event => {\n if (eventHandler) {\n eventHandler(event);\n }\n handler(event);\n };\n}\n\n// TODO v6: Remove PopperComponent, PopperProps, TransitionComponent and TransitionProps.\nconst Tooltip = /*#__PURE__*/React.forwardRef(function Tooltip(inProps, ref) {\n var _ref, _slots$popper, _ref2, _ref3, _slots$transition, _ref4, _slots$tooltip, _ref5, _slots$arrow, _slotProps$popper, _ref6, _slotProps$popper2, _slotProps$transition, _slotProps$tooltip, _ref7, _slotProps$tooltip2, _slotProps$arrow, _ref8, _slotProps$arrow2;\n const props = useThemeProps({\n props: inProps,\n name: 'MuiTooltip'\n });\n const {\n arrow = false,\n children: childrenProp,\n components = {},\n componentsProps = {},\n describeChild = false,\n disableFocusListener = false,\n disableHoverListener = false,\n disableInteractive: disableInteractiveProp = false,\n disableTouchListener = false,\n enterDelay = 100,\n enterNextDelay = 0,\n enterTouchDelay = 700,\n followCursor = false,\n id: idProp,\n leaveDelay = 0,\n leaveTouchDelay = 1500,\n onClose,\n onOpen,\n open: openProp,\n placement = 'bottom',\n PopperComponent: PopperComponentProp,\n PopperProps = {},\n slotProps = {},\n slots = {},\n title,\n TransitionComponent: TransitionComponentProp = Grow,\n TransitionProps\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n\n // to prevent runtime errors, developers will need to provide a child as a React element anyway.\n const children = /*#__PURE__*/React.isValidElement(childrenProp) ? childrenProp : /*#__PURE__*/_jsx(\"span\", {\n children: childrenProp\n });\n const theme = useTheme();\n const isRtl = theme.direction === 'rtl';\n const [childNode, setChildNode] = React.useState();\n const [arrowRef, setArrowRef] = React.useState(null);\n const ignoreNonTouchEvents = React.useRef(false);\n const disableInteractive = disableInteractiveProp || followCursor;\n const closeTimer = useTimeout();\n const enterTimer = useTimeout();\n const leaveTimer = useTimeout();\n const touchTimer = useTimeout();\n const [openState, setOpenState] = useControlled({\n controlled: openProp,\n default: false,\n name: 'Tooltip',\n state: 'open'\n });\n let open = openState;\n if (process.env.NODE_ENV !== 'production') {\n // eslint-disable-next-line react-hooks/rules-of-hooks\n const {\n current: isControlled\n } = React.useRef(openProp !== undefined);\n\n // eslint-disable-next-line react-hooks/rules-of-hooks\n React.useEffect(() => {\n if (childNode && childNode.disabled && !isControlled && title !== '' && childNode.tagName.toLowerCase() === 'button') {\n console.error(['MUI: You are providing a disabled `button` child to the Tooltip component.', 'A disabled element does not fire events.', \"Tooltip needs to listen to the child element's events to display the title.\", '', 'Add a simple wrapper element, such as a `span`.'].join('\\n'));\n }\n }, [title, childNode, isControlled]);\n }\n const id = useId(idProp);\n const prevUserSelect = React.useRef();\n const stopTouchInteraction = useEventCallback(() => {\n if (prevUserSelect.current !== undefined) {\n document.body.style.WebkitUserSelect = prevUserSelect.current;\n prevUserSelect.current = undefined;\n }\n touchTimer.clear();\n });\n React.useEffect(() => stopTouchInteraction, [stopTouchInteraction]);\n const handleOpen = event => {\n hystersisTimer.clear();\n hystersisOpen = true;\n\n // The mouseover event will trigger for every nested element in the tooltip.\n // We can skip rerendering when the tooltip is already open.\n // We are using the mouseover event instead of the mouseenter event to fix a hide/show issue.\n setOpenState(true);\n if (onOpen && !open) {\n onOpen(event);\n }\n };\n const handleClose = useEventCallback(\n /**\n * @param {React.SyntheticEvent | Event} event\n */\n event => {\n hystersisTimer.start(800 + leaveDelay, () => {\n hystersisOpen = false;\n });\n setOpenState(false);\n if (onClose && open) {\n onClose(event);\n }\n closeTimer.start(theme.transitions.duration.shortest, () => {\n ignoreNonTouchEvents.current = false;\n });\n });\n const handleEnter = event => {\n if (ignoreNonTouchEvents.current && event.type !== 'touchstart') {\n return;\n }\n\n // Remove the title ahead of time.\n // We don't want to wait for the next render commit.\n // We would risk displaying two tooltips at the same time (native + this one).\n if (childNode) {\n childNode.removeAttribute('title');\n }\n enterTimer.clear();\n leaveTimer.clear();\n if (enterDelay || hystersisOpen && enterNextDelay) {\n enterTimer.start(hystersisOpen ? enterNextDelay : enterDelay, () => {\n handleOpen(event);\n });\n } else {\n handleOpen(event);\n }\n };\n const handleLeave = event => {\n enterTimer.clear();\n leaveTimer.start(leaveDelay, () => {\n handleClose(event);\n });\n };\n const {\n isFocusVisibleRef,\n onBlur: handleBlurVisible,\n onFocus: handleFocusVisible,\n ref: focusVisibleRef\n } = useIsFocusVisible();\n // We don't necessarily care about the focusVisible state (which is safe to access via ref anyway).\n // We just need to re-render the Tooltip if the focus-visible state changes.\n const [, setChildIsFocusVisible] = React.useState(false);\n const handleBlur = event => {\n handleBlurVisible(event);\n if (isFocusVisibleRef.current === false) {\n setChildIsFocusVisible(false);\n handleLeave(event);\n }\n };\n const handleFocus = event => {\n // Workaround for https://github.com/facebook/react/issues/7769\n // The autoFocus of React might trigger the event before the componentDidMount.\n // We need to account for this eventuality.\n if (!childNode) {\n setChildNode(event.currentTarget);\n }\n handleFocusVisible(event);\n if (isFocusVisibleRef.current === true) {\n setChildIsFocusVisible(true);\n handleEnter(event);\n }\n };\n const detectTouchStart = event => {\n ignoreNonTouchEvents.current = true;\n const childrenProps = children.props;\n if (childrenProps.onTouchStart) {\n childrenProps.onTouchStart(event);\n }\n };\n const handleMouseOver = handleEnter;\n const handleMouseLeave = handleLeave;\n const handleTouchStart = event => {\n detectTouchStart(event);\n leaveTimer.clear();\n closeTimer.clear();\n stopTouchInteraction();\n prevUserSelect.current = document.body.style.WebkitUserSelect;\n // Prevent iOS text selection on long-tap.\n document.body.style.WebkitUserSelect = 'none';\n touchTimer.start(enterTouchDelay, () => {\n document.body.style.WebkitUserSelect = prevUserSelect.current;\n handleEnter(event);\n });\n };\n const handleTouchEnd = event => {\n if (children.props.onTouchEnd) {\n children.props.onTouchEnd(event);\n }\n stopTouchInteraction();\n leaveTimer.start(leaveTouchDelay, () => {\n handleClose(event);\n });\n };\n React.useEffect(() => {\n if (!open) {\n return undefined;\n }\n\n /**\n * @param {KeyboardEvent} nativeEvent\n */\n function handleKeyDown(nativeEvent) {\n // IE11, Edge (prior to using Bink?) use 'Esc'\n if (nativeEvent.key === 'Escape' || nativeEvent.key === 'Esc') {\n handleClose(nativeEvent);\n }\n }\n document.addEventListener('keydown', handleKeyDown);\n return () => {\n document.removeEventListener('keydown', handleKeyDown);\n };\n }, [handleClose, open]);\n const handleRef = useForkRef(children.ref, focusVisibleRef, setChildNode, ref);\n\n // There is no point in displaying an empty tooltip.\n // So we exclude all falsy values, except 0, which is valid.\n if (!title && title !== 0) {\n open = false;\n }\n const popperRef = React.useRef();\n const handleMouseMove = event => {\n const childrenProps = children.props;\n if (childrenProps.onMouseMove) {\n childrenProps.onMouseMove(event);\n }\n cursorPosition = {\n x: event.clientX,\n y: event.clientY\n };\n if (popperRef.current) {\n popperRef.current.update();\n }\n };\n const nameOrDescProps = {};\n const titleIsString = typeof title === 'string';\n if (describeChild) {\n nameOrDescProps.title = !open && titleIsString && !disableHoverListener ? title : null;\n nameOrDescProps['aria-describedby'] = open ? id : null;\n } else {\n nameOrDescProps['aria-label'] = titleIsString ? title : null;\n nameOrDescProps['aria-labelledby'] = open && !titleIsString ? id : null;\n }\n const childrenProps = _extends({}, nameOrDescProps, other, children.props, {\n className: clsx(other.className, children.props.className),\n onTouchStart: detectTouchStart,\n ref: handleRef\n }, followCursor ? {\n onMouseMove: handleMouseMove\n } : {});\n if (process.env.NODE_ENV !== 'production') {\n childrenProps['data-mui-internal-clone-element'] = true;\n\n // eslint-disable-next-line react-hooks/rules-of-hooks\n React.useEffect(() => {\n if (childNode && !childNode.getAttribute('data-mui-internal-clone-element')) {\n console.error(['MUI: The `children` component of the Tooltip is not forwarding its props correctly.', 'Please make sure that props are spread on the same element that the ref is applied to.'].join('\\n'));\n }\n }, [childNode]);\n }\n const interactiveWrapperListeners = {};\n if (!disableTouchListener) {\n childrenProps.onTouchStart = handleTouchStart;\n childrenProps.onTouchEnd = handleTouchEnd;\n }\n if (!disableHoverListener) {\n childrenProps.onMouseOver = composeEventHandler(handleMouseOver, childrenProps.onMouseOver);\n childrenProps.onMouseLeave = composeEventHandler(handleMouseLeave, childrenProps.onMouseLeave);\n if (!disableInteractive) {\n interactiveWrapperListeners.onMouseOver = handleMouseOver;\n interactiveWrapperListeners.onMouseLeave = handleMouseLeave;\n }\n }\n if (!disableFocusListener) {\n childrenProps.onFocus = composeEventHandler(handleFocus, childrenProps.onFocus);\n childrenProps.onBlur = composeEventHandler(handleBlur, childrenProps.onBlur);\n if (!disableInteractive) {\n interactiveWrapperListeners.onFocus = handleFocus;\n interactiveWrapperListeners.onBlur = handleBlur;\n }\n }\n if (process.env.NODE_ENV !== 'production') {\n if (children.props.title) {\n console.error(['MUI: You have provided a `title` prop to the child of .', `Remove this title prop \\`${children.props.title}\\` or the Tooltip component.`].join('\\n'));\n }\n }\n const popperOptions = React.useMemo(() => {\n var _PopperProps$popperOp;\n let tooltipModifiers = [{\n name: 'arrow',\n enabled: Boolean(arrowRef),\n options: {\n element: arrowRef,\n padding: 4\n }\n }];\n if ((_PopperProps$popperOp = PopperProps.popperOptions) != null && _PopperProps$popperOp.modifiers) {\n tooltipModifiers = tooltipModifiers.concat(PopperProps.popperOptions.modifiers);\n }\n return _extends({}, PopperProps.popperOptions, {\n modifiers: tooltipModifiers\n });\n }, [arrowRef, PopperProps]);\n const ownerState = _extends({}, props, {\n isRtl,\n arrow,\n disableInteractive,\n placement,\n PopperComponentProp,\n touch: ignoreNonTouchEvents.current\n });\n const classes = useUtilityClasses(ownerState);\n const PopperComponent = (_ref = (_slots$popper = slots.popper) != null ? _slots$popper : components.Popper) != null ? _ref : TooltipPopper;\n const TransitionComponent = (_ref2 = (_ref3 = (_slots$transition = slots.transition) != null ? _slots$transition : components.Transition) != null ? _ref3 : TransitionComponentProp) != null ? _ref2 : Grow;\n const TooltipComponent = (_ref4 = (_slots$tooltip = slots.tooltip) != null ? _slots$tooltip : components.Tooltip) != null ? _ref4 : TooltipTooltip;\n const ArrowComponent = (_ref5 = (_slots$arrow = slots.arrow) != null ? _slots$arrow : components.Arrow) != null ? _ref5 : TooltipArrow;\n const popperProps = appendOwnerState(PopperComponent, _extends({}, PopperProps, (_slotProps$popper = slotProps.popper) != null ? _slotProps$popper : componentsProps.popper, {\n className: clsx(classes.popper, PopperProps == null ? void 0 : PopperProps.className, (_ref6 = (_slotProps$popper2 = slotProps.popper) != null ? _slotProps$popper2 : componentsProps.popper) == null ? void 0 : _ref6.className)\n }), ownerState);\n const transitionProps = appendOwnerState(TransitionComponent, _extends({}, TransitionProps, (_slotProps$transition = slotProps.transition) != null ? _slotProps$transition : componentsProps.transition), ownerState);\n const tooltipProps = appendOwnerState(TooltipComponent, _extends({}, (_slotProps$tooltip = slotProps.tooltip) != null ? _slotProps$tooltip : componentsProps.tooltip, {\n className: clsx(classes.tooltip, (_ref7 = (_slotProps$tooltip2 = slotProps.tooltip) != null ? _slotProps$tooltip2 : componentsProps.tooltip) == null ? void 0 : _ref7.className)\n }), ownerState);\n const tooltipArrowProps = appendOwnerState(ArrowComponent, _extends({}, (_slotProps$arrow = slotProps.arrow) != null ? _slotProps$arrow : componentsProps.arrow, {\n className: clsx(classes.arrow, (_ref8 = (_slotProps$arrow2 = slotProps.arrow) != null ? _slotProps$arrow2 : componentsProps.arrow) == null ? void 0 : _ref8.className)\n }), ownerState);\n return /*#__PURE__*/_jsxs(React.Fragment, {\n children: [/*#__PURE__*/React.cloneElement(children, childrenProps), /*#__PURE__*/_jsx(PopperComponent, _extends({\n as: PopperComponentProp != null ? PopperComponentProp : Popper,\n placement: placement,\n anchorEl: followCursor ? {\n getBoundingClientRect: () => ({\n top: cursorPosition.y,\n left: cursorPosition.x,\n right: cursorPosition.x,\n bottom: cursorPosition.y,\n width: 0,\n height: 0\n })\n } : childNode,\n popperRef: popperRef,\n open: childNode ? open : false,\n id: id,\n transition: true\n }, interactiveWrapperListeners, popperProps, {\n popperOptions: popperOptions,\n children: ({\n TransitionProps: TransitionPropsInner\n }) => /*#__PURE__*/_jsx(TransitionComponent, _extends({\n timeout: theme.transitions.duration.shorter\n }, TransitionPropsInner, transitionProps, {\n children: /*#__PURE__*/_jsxs(TooltipComponent, _extends({}, tooltipProps, {\n children: [title, arrow ? /*#__PURE__*/_jsx(ArrowComponent, _extends({}, tooltipArrowProps, {\n ref: setArrowRef\n })) : null]\n }))\n }))\n }))]\n });\n});\nprocess.env.NODE_ENV !== \"production\" ? Tooltip.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the d.ts file and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * If `true`, adds an arrow to the tooltip.\n * @default false\n */\n arrow: PropTypes.bool,\n /**\n * Tooltip reference element.\n */\n children: elementAcceptingRef.isRequired,\n /**\n * Override or extend the styles applied to the component.\n */\n classes: PropTypes.object,\n /**\n * @ignore\n */\n className: PropTypes.string,\n /**\n * The components used for each slot inside.\n *\n * This prop is an alias for the `slots` prop.\n * It's recommended to use the `slots` prop instead.\n *\n * @default {}\n */\n components: PropTypes.shape({\n Arrow: PropTypes.elementType,\n Popper: PropTypes.elementType,\n Tooltip: PropTypes.elementType,\n Transition: PropTypes.elementType\n }),\n /**\n * The extra props for the slot components.\n * You can override the existing props or add new ones.\n *\n * This prop is an alias for the `slotProps` prop.\n * It's recommended to use the `slotProps` prop instead, as `componentsProps` will be deprecated in the future.\n *\n * @default {}\n */\n componentsProps: PropTypes.shape({\n arrow: PropTypes.object,\n popper: PropTypes.object,\n tooltip: PropTypes.object,\n transition: PropTypes.object\n }),\n /**\n * Set to `true` if the `title` acts as an accessible description.\n * By default the `title` acts as an accessible label for the child.\n * @default false\n */\n describeChild: PropTypes.bool,\n /**\n * Do not respond to focus-visible events.\n * @default false\n */\n disableFocusListener: PropTypes.bool,\n /**\n * Do not respond to hover events.\n * @default false\n */\n disableHoverListener: PropTypes.bool,\n /**\n * Makes a tooltip not interactive, i.e. it will close when the user\n * hovers over the tooltip before the `leaveDelay` is expired.\n * @default false\n */\n disableInteractive: PropTypes.bool,\n /**\n * Do not respond to long press touch events.\n * @default false\n */\n disableTouchListener: PropTypes.bool,\n /**\n * The number of milliseconds to wait before showing the tooltip.\n * This prop won't impact the enter touch delay (`enterTouchDelay`).\n * @default 100\n */\n enterDelay: PropTypes.number,\n /**\n * The number of milliseconds to wait before showing the tooltip when one was already recently opened.\n * @default 0\n */\n enterNextDelay: PropTypes.number,\n /**\n * The number of milliseconds a user must touch the element before showing the tooltip.\n * @default 700\n */\n enterTouchDelay: PropTypes.number,\n /**\n * If `true`, the tooltip follow the cursor over the wrapped element.\n * @default false\n */\n followCursor: PropTypes.bool,\n /**\n * This prop is used to help implement the accessibility logic.\n * If you don't provide this prop. It falls back to a randomly generated id.\n */\n id: PropTypes.string,\n /**\n * The number of milliseconds to wait before hiding the tooltip.\n * This prop won't impact the leave touch delay (`leaveTouchDelay`).\n * @default 0\n */\n leaveDelay: PropTypes.number,\n /**\n * The number of milliseconds after the user stops touching an element before hiding the tooltip.\n * @default 1500\n */\n leaveTouchDelay: PropTypes.number,\n /**\n * Callback fired when the component requests to be closed.\n *\n * @param {React.SyntheticEvent} event The event source of the callback.\n */\n onClose: PropTypes.func,\n /**\n * Callback fired when the component requests to be open.\n *\n * @param {React.SyntheticEvent} event The event source of the callback.\n */\n onOpen: PropTypes.func,\n /**\n * If `true`, the component is shown.\n */\n open: PropTypes.bool,\n /**\n * Tooltip placement.\n * @default 'bottom'\n */\n placement: PropTypes.oneOf(['bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n /**\n * The component used for the popper.\n * @default Popper\n */\n PopperComponent: PropTypes.elementType,\n /**\n * Props applied to the [`Popper`](/material-ui/api/popper/) element.\n * @default {}\n */\n PopperProps: PropTypes.object,\n /**\n * The extra props for the slot components.\n * You can override the existing props or add new ones.\n *\n * This prop is an alias for the `componentsProps` prop, which will be deprecated in the future.\n *\n * @default {}\n */\n slotProps: PropTypes.shape({\n arrow: PropTypes.object,\n popper: PropTypes.object,\n tooltip: PropTypes.object,\n transition: PropTypes.object\n }),\n /**\n * The components used for each slot inside.\n *\n * This prop is an alias for the `components` prop, which will be deprecated in the future.\n *\n * @default {}\n */\n slots: PropTypes.shape({\n arrow: PropTypes.elementType,\n popper: PropTypes.elementType,\n tooltip: PropTypes.elementType,\n transition: PropTypes.elementType\n }),\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Tooltip title. Zero-length titles string, undefined, null and false are never displayed.\n */\n title: PropTypes.node,\n /**\n * The component used for the transition.\n * [Follow this guide](/material-ui/transitions/#transitioncomponent-prop) to learn more about the requirements for this component.\n * @default Grow\n */\n TransitionComponent: PropTypes.elementType,\n /**\n * Props applied to the transition element.\n * By default, the element is based on this [`Transition`](http://reactcommunity.org/react-transition-group/transition/) component.\n */\n TransitionProps: PropTypes.object\n} : void 0;\nexport default Tooltip;","import '@/components/mui/menu-item.component.css';\nimport ArrowRightIcon from '@mui/icons-material/ArrowRight';\nimport {\n ListItemIcon as MuiListItemIcon,\n ListItemText as MuiListItemText,\n MenuItem as MuiMenuItem,\n} from '@mui/material';\nimport Tooltip from '@mui/material/Tooltip';\nimport { Localized, ReferencedItem, SingleColumnMenu } from 'platform-bible-utils';\nimport { MouseEvent, PropsWithChildren } from 'react';\n\ntype MenuItemInfoBase = {\n /** Text (displayable in the UI) as the name of the menu item */\n label: string;\n /** Text to display when the mouse hovers over the menu item */\n tooltip?: string;\n};\n\nexport type Command = MenuItemInfoBase & {\n /** Command to execute (string.string) */\n command: string;\n};\n\ntype SubMenu = MenuItemInfoBase & {\n /** Command to execute (string.string) */\n items: MenuItemInfo[];\n};\n\nexport interface CommandHandler {\n (command: Command): void;\n}\n\nexport type MenuPropsBase = {\n /*\n * The JSON defining the menu whose items are to be rendered. This will typically be one of the\n * menus in the \"defs\" in a Platform.Bible menu (see PlatformMenus). The schema for this is\n * menuDocumentSchema (at the end of menus.model.ts). Note that while this is a\n * \"SingleColumnMenu\", somewhat bizarrely, a MultiColumnMenu is a SingleColumnMenu, so it really\n * could be a MultiColumnMenu, in which case, column had better be defined so it can be used\n * to filter out the actual groups and items to display on the column.\n */\n menuDefinition: Localized;\n\n commandHandler: CommandHandler;\n\n /**\n * Additional action to perform when any menu item is clicked. Allows the caller to handle event\n * (e.g., to close the menu).\n */\n onClick?: (event: MouseEvent) => void;\n};\n\nexport type MenuItemListProps = MenuPropsBase & {\n /** Optional unique (column) identifier */\n columnId?: ReferencedItem;\n};\n\nexport type MenuItemProps = Omit &\n PropsWithChildren<{\n /** Optional unique identifier */\n id?: string;\n\n onClick: (event: MouseEvent) => void;\n }>;\n\ntype MenuItemInfo = (Command | SubMenu) & {\n /**\n * If specified, menu item will be inset if it does not have a leading icon.\n *\n * @default true\n */\n allowForLeadingIcons?: boolean;\n /**\n * If specified, the path to the icon image to display on the leading side of the menu text.\n *\n * @default undefined (no leading icon will be shown)\n */\n iconPathBefore?: string;\n /**\n * If specified, the path to the icon image to display on the trailing side of the menu text.\n *\n * @default undefined (no trailing icon will be shown)\n */\n iconPathAfter?: string;\n /**\n * If true, list item is focused during the first mount\n *\n * @default false\n */\n hasAutoFocus?: boolean;\n\n /** Additional css classes to help with unique styling of the menu item */\n className?: string;\n\n /**\n * If true, the menu item will appear disabled and it will not respond to clicks or mouse hovers.\n *\n * @default false\n */\n isDisabled?: boolean;\n\n /**\n * If true, compact vertical padding designed for keyboard and mouse input is used.\n *\n * @default true\n */\n isDense?: boolean;\n\n /**\n * If true, a right-arrow icon will be displayed (iconPathAfter, if specified, will be ignored).\n *\n * @default false\n */\n isSubMenuParent?: boolean;\n\n /**\n * If true, the left and right padding is removed\n *\n * @default false\n */\n hasDisabledGutters?: boolean;\n\n /**\n * If true, a 1px light border is added to bottom of menu item\n *\n * @default false\n */\n hasDivider?: boolean;\n\n /** Help identify which element has keyboard focus */\n focusVisibleClassName?: string;\n\n /** If it's a submenu, it should have the items property */\n items?: MenuItemInfo[];\n};\n\nfunction getIcon(icon: string | undefined, menuLabel: string, leading: boolean) {\n return icon ? (\n \n {`${leading\n \n ) : undefined;\n}\n\nexport default function MenuItem(props: MenuItemProps) {\n const {\n onClick,\n label,\n tooltip,\n allowForLeadingIcons = true,\n iconPathBefore = undefined,\n iconPathAfter = undefined,\n hasAutoFocus = false,\n className,\n isDisabled = false,\n isDense = true,\n isSubMenuParent = false,\n hasDisabledGutters = false,\n hasDivider = false,\n focusVisibleClassName,\n id,\n children,\n } = props;\n\n const menuItem = (\n \n {label ? (\n <>\n {getIcon(iconPathBefore, label, true)}\n \n {isSubMenuParent ? (\n \n \n \n ) : (\n getIcon(iconPathAfter, label, false)\n )}\n \n ) : (\n children\n )}\n \n );\n\n return tooltip ? (\n \n
    {menuItem}
    \n
    \n ) : (\n menuItem\n );\n}\n","import MenuItem, {\n MenuItemListProps,\n MenuItemProps,\n MenuPropsBase,\n} from '@/components/mui/menu-item.component';\nimport { Menu } from '@mui/material';\nimport {\n Localized,\n MenuGroupDetailsInSubMenu,\n MenuItemContainingCommand,\n MenuItemContainingSubmenu,\n OrderedExtensibleContainer,\n ReferencedItem,\n SingleColumnMenu,\n} from 'platform-bible-utils';\nimport { MouseEvent, useMemo, useState } from 'react';\n\n/**\n * All the exported types in this file should be regarded as \"internal\" (i.e., they should not be\n * exposed via index.ts).\n */\n\nexport type GroupedMenuPropsBase = MenuPropsBase & {\n /** Optional unique (column) identifier */\n columnId?: ReferencedItem;\n};\n\nexport type GroupedMenuItemListProps = MenuItemListProps & {\n /**\n * If the menuDefinition includes \"top-level\" groups (i.e., those that belong to a column as\n * opposed to those that belong to a submenu) that should not be included in the list, then this\n * array specifies which groups to include. Likewise, for a submenu, this list indicates which\n * groups are pertinent for that submenu. So then for a context menu this property need not be\n * specified since it is a top-level menu based on a \"true\" SingleColumnMenu (i.e., one that is\n * not a MultiColumnMenu).\n */\n includedGroups?: {\n id: string;\n group: Localized;\n }[];\n};\n\ninterface ItemInfo {\n item: Localized;\n isLastItemInGroup: boolean;\n}\n\ntype SubMenuProps = MenuPropsBase & {\n parentMenuItem: Localized;\n parentItemProps: Omit, 'iconPathAfter'>;\n};\n\nfunction getAllGroups(menuDefinition: Localized) {\n const groupEntries = Object.entries(menuDefinition.groups);\n // Convert array of entries to array of objects with id and group properties\n return groupEntries.map(([key, value]) => ({ id: key, group: value }));\n}\n\nfunction SubMenu(props: SubMenuProps) {\n const [anchorEl, setAnchorEl] = useState(undefined);\n\n const { parentMenuItem, parentItemProps, menuDefinition } = props;\n\n const handleParentMenuItemClick = (event: MouseEvent) => {\n setAnchorEl(event.currentTarget);\n };\n\n const handleClose = () => {\n setAnchorEl(undefined);\n };\n\n const renderSubMenuItems = () => {\n let includedGroups = getAllGroups(menuDefinition).filter((g) => 'menuItem' in g.group);\n\n // Ensure valid parent menu was provided. (If not, submenu will contain all groups!)\n if (!parentMenuItem?.id) throw new Error('A valid parent menu item is required for submenus.');\n\n // When laying out a submenu, only include groups associated with the provided parent menu.\n // Note: without the (annoying) redundant check that the included groups\n // have the menuItem field, TS doesn't think it exists.\n includedGroups = includedGroups.filter(\n (group) => 'menuItem' in group.group && group.group.menuItem === parentMenuItem.id,\n );\n\n return ;\n };\n\n return (\n <>\n \n \n {renderSubMenuItems()}\n \n \n );\n}\n\nconst getOrderedGroupItems = (\n groupId: string,\n allItems: Localized[],\n) => {\n // Filter items that belong to the specified group\n const itemsForGroup = allItems.filter((item) => item.group === groupId);\n // Sort items based on order\n const sortedItems = itemsForGroup.sort((a, b) => (a.order || 0) - (b.order || 0));\n return sortedItems;\n};\n\n/**\n * This component is internal; it does not need to be exposed to the outside world since it is not\n * useful on its own. It is used to generate and lay out the MenuItems that appear either on a\n * top-level menu (in a GridMenu or ContextMenu) or in a submenu.\n */\nexport default function GroupedMenuItemList(menuProps: GroupedMenuItemListProps) {\n const { menuDefinition, onClick, commandHandler, includedGroups } = menuProps;\n\n const { items, allowForLeadingIcons } = useMemo(() => {\n const groupsToInclude =\n includedGroups && includedGroups.length > 0\n ? includedGroups\n : // We're apparently laying out a single-column menu (presumably a context menu). In this\n // case, all groups should be included except ones that belong to a submenu.\n getAllGroups(menuDefinition).filter((g) => !('menuItem' in g.group));\n\n const sortedGroups = Object.values(groupsToInclude).sort(\n (a, b) => (a.group.order || 0) - (b.group.order || 0),\n );\n\n const itemArray: ItemInfo[] = [];\n\n sortedGroups.forEach((group) => {\n getOrderedGroupItems(group.id, menuDefinition.items).forEach((item) =>\n itemArray.push({ item, isLastItemInGroup: false }),\n );\n if (itemArray.length > 0) itemArray[itemArray.length - 1].isLastItemInGroup = true;\n });\n\n // No divider after last item in final group.\n if (itemArray.length > 0) itemArray[itemArray.length - 1].isLastItemInGroup = false;\n\n const allowSpaceForLeadingIcons = itemArray.some(\n (i) => 'iconPathBefore' in i.item && i.item.iconPathBefore,\n );\n\n return { items: itemArray, allowForLeadingIcons: allowSpaceForLeadingIcons };\n }, [includedGroups, menuDefinition]);\n\n // Create props for MenuItem component including setting hasDivider for the last item in a group\n const createMenuItemProps = ({ item, isLastItemInGroup }: ItemInfo) => {\n const menuItemProps = {\n className: 'papi-menu-item',\n label: item.label,\n tooltip: item.tooltip,\n iconPathBefore: 'iconPathBefore' in item ? item.iconPathBefore : undefined,\n iconPathAfter: 'iconPathAfter' in item ? item.iconPathAfter : undefined,\n hasDivider: isLastItemInGroup, // Set hasDivider to true for the last item in a group\n allowForLeadingIcons,\n };\n\n return menuItemProps;\n };\n\n const [firstItem] = items;\n\n if (!firstItem) return
    ;\n\n const divKey = firstItem.item.group;\n\n return (\n
    \n {items.map((itemInfo, index) => {\n const { item } = itemInfo;\n const menuItemProps = createMenuItemProps(itemInfo);\n if ('command' in item) {\n const key = item.group + index;\n return (\n ) => {\n onClick?.(event);\n commandHandler(item);\n }}\n {...menuItemProps}\n />\n );\n }\n return (\n \n );\n })}\n
    \n );\n}\n","import GroupedMenuItemList from '@/components/mui/grouped-menu-item-list.component';\nimport { MenuItemListProps } from '@/components/mui/menu-item.component';\nimport { MultiColumnMenu } from 'platform-bible-utils';\n\n/**\n * This component is internal; it does not need to be exposed to the outside world since it is not\n * useful on its own. Use either GridMenu or ContextMenu.\n */\nexport default function TopLevelMenu(props: MenuItemListProps) {\n const { menuDefinition, columnId } = props;\n\n const groupEntries = Object.entries(menuDefinition.groups);\n // Convert array of entries to array of objects with id and group properties\n const groups = groupEntries.map(([key, value]) => ({ id: key, group: value }));\n let includedGroups = groups.filter((g) => 'column' in g.group);\n\n // Check if column is provided and menuDefinition is a MultiColumnMenu\n if (\n columnId &&\n 'columns' in menuDefinition &&\n // Without this type assertion, TS doesn't know what columns is.\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n (menuDefinition as MultiColumnMenu).columns[columnId]\n ) {\n // When laying out a single column in a MultiColumnMenu, only include groups associated with\n // the provided column. Note: without the (annoying) redundant check that the included groups\n // have the colum field, TS doesn't think it exists.\n includedGroups = includedGroups.filter(\n (g) => 'column' in g.group && g.group.column === columnId,\n );\n }\n\n return ;\n}\n","import '@/components/mui/grid-menu.component.css';\nimport { GroupedMenuPropsBase } from '@/components/mui/grouped-menu-item-list.component';\nimport { CommandHandler } from '@/components/mui/menu-item.component';\nimport TopLevelMenu from '@/components/mui/top-level-menu.component';\nimport { Grid, List } from '@mui/material';\nimport {\n Localized,\n MenuColumnWithHeader,\n MultiColumnMenu,\n ReferencedItem,\n} from 'platform-bible-utils';\nimport { useMemo } from 'react';\n\ntype ColumnInfo = {\n /*\n * The ID (`${string}.${string}`) of a specific menu column.\n */\n id: ReferencedItem;\n\n /*\n * Metadata (label, order, etc.) for a specific menu column.\n */\n metadata: Localized;\n};\n\ntype MenuColumnProps = ColumnInfo &\n GroupedMenuPropsBase & {\n /** Additional css classes to help with unique styling of the menu column */\n className?: string;\n };\n\nexport type GridMenuInfo = {\n /** The menu object containing information about the columns, groups, and items to display. */\n multiColumnMenu: Localized;\n};\n\nexport type GridMenuProps = GridMenuInfo & {\n /** Optional unique identifier */\n id?: string;\n\n commandHandler: CommandHandler;\n\n /** Additional css classes to help with unique styling of the grid menu */\n className?: string;\n};\n\nfunction MenuColumn({\n commandHandler,\n menuDefinition,\n id,\n metadata,\n onClick,\n className,\n}: MenuColumnProps) {\n return (\n \n

    \n {metadata.label}\n

    \n {/* It would seem as though this List component were unnecessary, since it only contains one\n thing, but the \"dense\" property does affect the layout of the items (in a way I don't fully\n understand). There might be a better way. */}\n \n \n \n \n );\n}\n\nexport default function GridMenu({\n commandHandler,\n className,\n multiColumnMenu,\n id,\n}: GridMenuProps) {\n const { columns } = multiColumnMenu;\n\n const sortedColumns = useMemo(() => {\n const columnNumbers = new Map();\n Object.getOwnPropertyNames(columns).forEach((columnName: string) => {\n // We know for sure there is a (boolean) property 'isExtensible' that we are not interested in.\n if (columnName === 'isExtensible') return;\n // TS doesn't allow `columnName` above to be a ReferencedItem even though the type says it is\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const columnId = columnName as ReferencedItem;\n const column = columns[columnId];\n // As of right now (and hopefully forever after), all remaining properties of the\n // ColumnsWithHeaders object are columns whose property names are the IDs of the columns.\n // This is an additional (redundant) sanity check. Specifically we're interested in\n // MenuColumnWithHeader objects, which TypeScript now \"knows\" we have, but at runtime all we\n // can check for is that it's an object with a valid numeric order field. That's likely good\n // enough.\n if (\n typeof column === 'object' &&\n typeof column.order === 'number' &&\n !Number.isNaN(column.order)\n )\n columnNumbers.set(column.order, { id: columnId, metadata: column });\n else\n console.warn(\n `Property ${columnName} (${typeof column}) on menu ${id} is not a valid column and is being ignored. This might indicate data corruption`,\n );\n });\n\n // Extract values and sort them based on the 'order' property\n return Array.from(columnNumbers.values()).sort((a, b) => {\n return (a.metadata.order || 0) - (b.metadata.order || 0);\n });\n }, [columns, id]);\n\n // We might need something like this if we need to be able to prevent empty columns\n // sortedColumns.filter((c) => multiColumnMenu.groups.some((g) => 'column' in g && (g as .column)...\n\n return (\n \n {sortedColumns.map((col, index) => (\n \n ))}\n \n );\n}\n","import { useEffect, useRef, useState } from 'react';\n\nexport type UsePromiseOptions = {\n /**\n * Whether to leave the value as the most recent resolved promise value or set it back to\n * defaultValue while running the promise again. Defaults to true\n */\n preserveValue?: boolean;\n};\n\n/** Set up defaults for options for usePromise hook */\nfunction getUsePromiseOptionsDefaults(options: UsePromiseOptions): UsePromiseOptions {\n return {\n preserveValue: true,\n ...options,\n };\n}\n\n/**\n * Awaits a promise and returns a loading value while the promise is unresolved\n *\n * @param promiseFactoryCallback A function that returns the promise to await. If this callback is\n * undefined, the current value will be returned (defaultValue unless it was previously changed\n * and `options.preserveValue` is true), and there will be no loading.\n *\n * WARNING: MUST BE STABLE - const or wrapped in useCallback. The reference must not be updated\n * every render\n * @param defaultValue The initial value to return while first awaiting the promise. If\n * `options.preserveValue` is false, this value is also shown while awaiting the promise on\n * subsequent calls.\n *\n * Note: this parameter is internally assigned to a `ref`, so changing it will not cause any hooks\n * to re-run with its new value. This means that, if the `promiseFactoryCallback` changes and\n * `options.preserveValue` is `false`, the returned value will be set to the current\n * `defaultValue`. However, the returned value will not be updated if`defaultValue` changes.\n * @param options Various options for adjusting how this hook runs the `promiseFactoryCallback`\n *\n * Note: this parameter is internally assigned to a `ref`, so changing it will not cause any hooks\n * to re-run with its new value. However, the latest `options.preserveValue` will always be used\n * appropriately to determine whether to preserve the returned value when changing the\n * `promiseFactoryCallback`\n * @returns `[value, isLoading]`\n *\n * - `value`: the current value for the promise, either the defaultValue or the resolved promise value\n * - `isLoading`: whether the promise is waiting to be resolved\n */\nconst usePromise = (\n promiseFactoryCallback: (() => Promise) | undefined,\n defaultValue: T,\n options: UsePromiseOptions = {},\n): [value: T, isLoading: boolean] => {\n // Use defaultValue as a ref so it doesn't update dependency arrays\n const defaultValueRef = useRef(defaultValue);\n defaultValueRef.current = defaultValue;\n // Use options as a ref so it doesn't update dependency arrays\n const optionsDefaultedRef = useRef(options);\n optionsDefaultedRef.current = getUsePromiseOptionsDefaults(optionsDefaultedRef.current);\n\n const [value, setValue] = useState(() => defaultValueRef.current);\n const [isLoading, setIsLoading] = useState(true);\n useEffect(() => {\n let promiseIsCurrent = true;\n // If a promiseFactoryCallback was provided, we are loading. Otherwise, there is no loading to do\n setIsLoading(!!promiseFactoryCallback);\n (async () => {\n // If there is a callback to run, run it\n if (promiseFactoryCallback) {\n const result = await promiseFactoryCallback();\n // If the promise was not already replaced, update the value\n if (promiseIsCurrent) {\n setValue(() => result);\n setIsLoading(false);\n }\n }\n })();\n\n return () => {\n // Mark this promise as old and not to be used\n promiseIsCurrent = false;\n if (!optionsDefaultedRef.current.preserveValue) setValue(() => defaultValueRef.current);\n };\n }, [promiseFactoryCallback]);\n\n return [value, isLoading];\n};\nexport default usePromise;\n","\"use client\";\n\nimport createSvgIcon from './utils/createSvgIcon';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nexport default createSvgIcon( /*#__PURE__*/_jsx(\"path\", {\n d: \"M3 18h18v-2H3zm0-5h18v-2H3zm0-7v2h18V6z\"\n}), 'Menu');","import GridMenu from '@/components/mui/grid-menu.component';\nimport { Command, CommandHandler } from '@/components/mui/menu-item.component';\nimport usePromise from '@/hooks/use-promise.hook';\nimport { Menu as MenuIcon } from '@mui/icons-material';\nimport { Drawer, IconButton } from '@mui/material';\nimport { Localized, MultiColumnMenu } from 'platform-bible-utils';\nimport {\n MouseEvent,\n MutableRefObject,\n PropsWithChildren,\n useCallback,\n useEffect,\n useState,\n} from 'react';\n\nexport interface MultiColumnMenuProvider {\n (isSupportAndDevelopment: boolean): Promise>;\n}\n\nexport type HamburgerMenuButtonProps = PropsWithChildren & {\n /** The handler to use for menu commands (and eventually toolbar commands). */\n commandHandler: CommandHandler;\n\n /**\n * Optional reference to the \"div\" container that determines the where the menu should appear. If\n * not defined, then (1,1) used.\n */\n containerRef?: MutableRefObject;\n\n /**\n * The delegate to use to get the menu data. If not specified or if it returns undefined, the data\n * in normalMenu or fullMenu property will be used.\n */\n menuProvider?: MultiColumnMenuProvider;\n\n /**\n * The menu data to show when the menu is opened if the menuProvider property is not defined.\n * (This allows for a default or test-only static menu to be used.)\n */\n normalMenu?: Localized;\n\n /**\n * The menu data to show for \"full\" menu (when opened with the SHIFT key pressed) if the\n * menuProvider property is not defined. (This allows for a default or test-only static menu to be\n * used.)\n */\n fullMenu?: Localized;\n\n /** Additional css class(es) to help with unique styling of the sub-components */\n className?: string;\n\n /** Value to use as prefix for ARIA labels on interactive sub-components */\n ariaLabelPrefix?: string;\n};\n\nexport default function HamburgerMenuButton({\n menuProvider,\n normalMenu,\n fullMenu,\n commandHandler,\n containerRef,\n className,\n ariaLabelPrefix,\n children,\n}: HamburgerMenuButtonProps) {\n const [isMenuOpen, setMenuOpen] = useState(false);\n const [showFullMenu, setShowFullMenu] = useState(false);\n\n const handleMenuItemClick = useCallback(() => {\n if (isMenuOpen) setMenuOpen(false);\n setShowFullMenu(false);\n }, [isMenuOpen]);\n\n const handleMenuButtonClick = useCallback((e: MouseEvent) => {\n e.stopPropagation();\n setMenuOpen((prevIsOpen) => {\n const isOpening = !prevIsOpen;\n if (isOpening && e.shiftKey) setShowFullMenu(true);\n else if (!isOpening) setShowFullMenu(false);\n return isOpening;\n });\n }, []);\n\n const menuCommandHandler = useCallback(\n (command: Command) => {\n handleMenuItemClick();\n return commandHandler(command);\n },\n [commandHandler, handleMenuItemClick],\n );\n\n const [offset, setOffset] = useState({ top: 1, left: 1 });\n\n useEffect(() => {\n if (isMenuOpen) {\n const node = containerRef?.current;\n if (node) {\n const rect = node.getBoundingClientRect();\n const scrollTop = window.scrollY;\n const scrollLeft = window.scrollX;\n const top = rect.top + scrollTop + node.clientHeight;\n const left = rect.left + scrollLeft;\n setOffset({ top, left });\n }\n }\n }, [isMenuOpen, containerRef]);\n\n const [normalMenuData] = usePromise(\n useCallback(async () => {\n return menuProvider?.(false) ?? normalMenu;\n // isMenuOpen needs to be included for the menu contents to reevaluate when reopened\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [menuProvider, normalMenu, isMenuOpen]),\n normalMenu,\n );\n\n const [fullMenuData] = usePromise(\n useCallback(async () => {\n return menuProvider?.(true) ?? fullMenu ?? normalMenuData;\n // isMenuOpen needs to be included for the menu contents to reevaluate when reopened\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [menuProvider, fullMenu, normalMenuData, isMenuOpen]),\n fullMenu ?? normalMenuData,\n );\n\n const menu = showFullMenu && fullMenuData ? fullMenuData : normalMenuData;\n\n return (\n <>\n \n {children ?? }\n \n \n {menu ? (\n \n ) : undefined}\n \n \n );\n}\n","import '@/components/mui/icon-button.component.css';\nimport { IconButton as MuiIconButton } from '@mui/material';\nimport { MouseEventHandler, PropsWithChildren } from 'react';\n\nexport type IconButtonProps = PropsWithChildren<{\n /** Optional unique identifier */\n id?: string;\n /**\n * Required. Used as both the tooltip (aka, title) and the aria-label (used for accessibility,\n * testing, etc.), unless a distinct tooltip is supplied.\n */\n label: string;\n /**\n * Enabled status of button\n *\n * @default false\n */\n isDisabled?: boolean;\n /** Optional tooltip to display if different from the aria-label. */\n tooltip?: string;\n /** If true, no tooltip will be displayed. */\n isTooltipSuppressed?: boolean;\n /**\n * If given, uses a negative margin to counteract the padding on one side (this is often helpful\n * for aligning the left or right side of the icon with content above or below, without ruining\n * the border size and shape).\n *\n * @default false\n */\n adjustMarginToAlignToEdge?: 'end' | 'start' | false;\n /**\n * The size of the component. small is equivalent to the dense button styling.\n *\n * @default false\n */\n size: 'small' | 'medium' | 'large';\n /** Additional css classes to help with unique styling of the button */\n className?: string;\n /** Optional click handler */\n onClick?: MouseEventHandler;\n}>;\n\n/**\n * Iconic button a user can click to do something\n *\n * Thanks to MUI for heavy inspiration and documentation\n * https://mui.com/material-ui/getting-started/overview/\n */\nfunction IconButton({\n id,\n label,\n isDisabled = false,\n tooltip,\n isTooltipSuppressed = false,\n adjustMarginToAlignToEdge = false,\n size = 'medium',\n className,\n onClick,\n children,\n}: IconButtonProps) {\n return (\n \n {children /* the icon to display */}\n \n );\n}\n\nexport default IconButton;\n","import { cn } from '@/utils/shadcn-ui.util';\nimport { LoaderCircle, LucideProps } from 'lucide-react';\nimport { forwardRef } from 'react';\n\nexport type SpinnerProps = LucideProps;\n\nconst Spinner = forwardRef(({ className, ...props }, ref) => {\n return (\n \n );\n});\n\nSpinner.displayName = 'Spinner';\n\nexport default Spinner;\n","import { Input as ShadInput } from '@/components/shadcn-ui/input';\nimport { Label as ShadLabel } from '@/components/shadcn-ui/label';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { ChangeEventHandler, FocusEventHandler } from 'react';\n\nexport type TextFieldProps = {\n /** Optional unique identifier */\n id?: string;\n /**\n * If `true`, the component is disabled.\n *\n * @default false\n */\n isDisabled?: boolean;\n /**\n * If `true`, the label is displayed in an error state.\n *\n * @default false\n */\n hasError?: boolean;\n /**\n * If `true`, the input will take up the full width of its container.\n *\n * @default false\n */\n isFullWidth?: boolean;\n /** Text that gives the user instructions on what contents the TextField expects */\n helperText?: string;\n /** The title of the TextField */\n label?: string;\n /** The short hint displayed in the `input` before the user enters a value. */\n placeholder?: string;\n /**\n * If `true`, the label is displayed as required and the `input` element is required.\n *\n * @default false\n */\n isRequired?: boolean;\n /** Additional css classes to help with unique styling of the text field */\n className?: string;\n /** Starting value for the text field if it is not controlled */\n defaultValue?: string | number;\n /** Value of the text field if controlled */\n value?: string | number;\n /** Triggers when content of textfield is changed */\n onChange?: ChangeEventHandler;\n /** Triggers when textfield gets focus */\n onFocus?: FocusEventHandler;\n /** Triggers when textfield loses focus */\n onBlur?: FocusEventHandler;\n};\n\n/**\n * Text input field\n *\n * Thanks to Shadcn for heavy inspiration and documentation\n * https://ui.shadcn.com/docs/components/input#with-label\n */\nfunction TextField({\n id,\n isDisabled = false,\n hasError = false,\n isFullWidth = false,\n helperText,\n label,\n placeholder,\n isRequired = false,\n className,\n defaultValue,\n value,\n onChange,\n onFocus,\n onBlur,\n}: TextFieldProps) {\n return (\n
    \n {`${label}${isRequired ? '*' : ''}`}\n \n

    {helperText}

    \n
    \n );\n}\n\nexport default TextField;\n","import HamburgerMenuButton, {\n MultiColumnMenuProvider,\n} from '@/components/mui/hamburger-menu-button.component';\nimport { CommandHandler } from '@/components/mui/menu-item.component';\nimport '@/components/mui/toolbar.component.css';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { AppBar, Toolbar as MuiToolbar } from '@mui/material';\nimport { PropsWithChildren, useRef } from 'react';\n\nexport type ToolbarProps = PropsWithChildren<{\n /** The handler to use for menu commands (and eventually toolbar commands). */\n commandHandler: CommandHandler;\n\n /**\n * The optional delegate to use to get the menu data. If not specified, the \"hamburger\" menu will\n * not display.\n */\n menuProvider?: MultiColumnMenuProvider;\n\n /** Optional unique identifier */\n id?: string;\n\n /** Additional css classes to help with unique styling of the toolbar */\n className?: string;\n}>;\n\nexport default function Toolbar({\n menuProvider,\n commandHandler,\n className,\n id,\n children,\n}: ToolbarProps) {\n // This ref will always be defined\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const containerRef = useRef(undefined!);\n\n return (\n
    \n \n \n {menuProvider ? (\n \n ) : undefined}\n {children ?
    {children}
    : undefined}\n \n
    \n
    \n );\n}\n","import React from 'react';\nimport { cva, type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst alertVariants = cva(\n 'tw-relative tw-w-full tw-rounded-lg tw-border tw-p-4 [&>svg~*]:tw-pl-7 [&>svg+div]:tw-translate-y-[-3px] [&>svg]:tw-absolute [&>svg]:tw-left-4 [&>svg]:tw-top-4 [&>svg]:tw-text-foreground',\n {\n variants: {\n variant: {\n default: 'tw-bg-background tw-text-foreground',\n destructive:\n 'tw-border-destructive/50 tw-text-destructive dark:tw-border-destructive [&>svg]:tw-text-destructive',\n },\n },\n defaultVariants: {\n variant: 'default',\n },\n },\n);\n\nconst Alert = React.forwardRef<\n HTMLDivElement,\n React.HTMLAttributes & VariantProps\n>(({ className, variant, ...props }, ref) => (\n
    \n));\nAlert.displayName = 'Alert';\n\nconst AlertTitle = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n {/* added because of https://github.com/jsx-eslint/eslint-plugin-jsx-a11y/blob/main/docs/rules/heading-has-content.md */}\n {props.children}{' '}\n \n ),\n);\nAlertTitle.displayName = 'AlertTitle';\n\nconst AlertDescription = React.forwardRef<\n HTMLParagraphElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n
    \n));\nAlertDescription.displayName = 'AlertDescription';\n\nexport { Alert, AlertTitle, AlertDescription };\n","import React from 'react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Card = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nCard.displayName = 'Card';\n\nconst CardHeader = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nCardHeader.displayName = 'CardHeader';\n\nconst CardTitle = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n {/* added because of https://github.com/jsx-eslint/eslint-plugin-jsx-a11y/blob/main/docs/rules/heading-has-content.md */}\n {props.children}\n \n ),\n);\nCardTitle.displayName = 'CardTitle';\n\nconst CardDescription = React.forwardRef<\n HTMLParagraphElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n

    \n));\nCardDescription.displayName = 'CardDescription';\n\nconst CardContent = React.forwardRef>(\n ({ className, ...props }, ref) => (\n

    \n ),\n);\nCardContent.displayName = 'CardContent';\n\nconst CardFooter = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nCardFooter.displayName = 'CardFooter';\n\nexport { Card, CardHeader, CardFooter, CardTitle, CardDescription, CardContent };\n","import { ComponentProps } from 'react';\nimport { toast as sonner, Toaster } from 'sonner';\n\ntype SonnerProps = ComponentProps;\n\nfunction Sonner({ ...props }: SonnerProps) {\n return (\n \n );\n}\n\n// The re-export of the sonner function was added manually\nexport { Sonner, sonner };\n","import React from 'react';\nimport * as SliderPrimitive from '@radix-ui/react-slider';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Slider = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n \n \n \n));\nSlider.displayName = SliderPrimitive.Root.displayName;\n\nexport { Slider };\n","import React from 'react';\nimport * as SwitchPrimitives from '@radix-ui/react-switch';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Switch = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n));\nSwitch.displayName = SwitchPrimitives.Root.displayName;\n\nexport { Switch };\n","import React from 'react';\nimport * as TabsPrimitive from '@radix-ui/react-tabs';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport const Tabs = TabsPrimitive.Root;\n\nexport type TabsListProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport type TabsTriggerProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport type TabsContentProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport const TabsList = React.forwardRef<\n React.ElementRef,\n TabsListProps\n>(({ className, ...props }, ref) => (\n \n));\nTabsList.displayName = TabsPrimitive.List.displayName;\n\nexport const TabsTrigger = React.forwardRef<\n React.ElementRef,\n TabsTriggerProps\n>(({ className, ...props }, ref) => (\n \n));\nTabsTrigger.displayName = TabsPrimitive.Trigger.displayName;\n\nexport const TabsContent = React.forwardRef<\n React.ElementRef,\n TabsContentProps\n>(({ className, ...props }, ref) => (\n \n));\nTabsContent.displayName = TabsPrimitive.Content.displayName;\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Download } from 'lucide-react';\n\ntype InstallButtonProps = {\n /** The installing boolean value determines the state of the button. */\n isInstalling: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n /** Optional text for the button. */\n buttonText?: string;\n} & ButtonProps;\n\n/**\n * The InstallButton component is a button designed for initiating installs. It includes visuals for\n * active installing and idle states.\n *\n * @param isInstalling The installing boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @param buttonText Optional text for the button.\n * @returns A install button.\n */\nexport default function InstallButton({\n isInstalling,\n handleClick,\n buttonText,\n className,\n ...props\n}: InstallButtonProps) {\n return (\n \n {isInstalling ? (\n \n ) : (\n <>\n \n {buttonText}\n \n )}\n \n );\n}\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\n\ntype EnableButtonProps = {\n /** The enabling boolean value determines the state of the button. */\n isEnabling: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n} & ButtonProps;\n\n/**\n * The EnableButton component is a button designed for initiating enabling of downloads. It includes\n * visuals for active enabling and idle states.\n *\n * @param isEnabling The enabling boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @returns A button that can be used to enable.\n */\nexport default function EnableButton({\n isEnabling,\n handleClick,\n className,\n ...props\n}: EnableButtonProps) {\n return (\n \n {isEnabling ? (\n <>\n \n Enabling...\n \n ) : (\n 'Enable'\n )}\n \n );\n}\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\n\ntype DisableButtonProps = {\n /** The disabling boolean value determines the state of the button. */\n isDisabling: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n} & ButtonProps;\n\n/**\n * The DisableButton component is a button designed for initiating disabling of downloads. It\n * includes visuals for active disabling and idle states.\n *\n * @param isDisabling The disabling boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @returns A button that can be used to disable.\n */\nexport default function DisableButton({\n isDisabling,\n handleClick,\n className,\n ...props\n}: DisableButtonProps) {\n return (\n \n {isDisabling ? (\n <>\n \n Disabling...\n \n ) : (\n 'Disable'\n )}\n \n );\n}\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\n\ntype UpdateButtonProps = {\n /** The updating boolean value determines the state of the button. */\n isUpdating: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n} & ButtonProps;\n\n/**\n * The UpdateButton component is a button designed for initiating updates for downloaded extensions.\n * It includes visuals for active updating and idle states.\n *\n * @param isUpdating The updating boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @returns A button that can be used to update.\n */\nexport default function UpdateButton({\n isUpdating,\n handleClick,\n className,\n ...props\n}: UpdateButtonProps) {\n return (\n \n {isUpdating ? (\n <>\n \n Updating...\n \n ) : (\n 'Update'\n )}\n \n );\n}\n","import { cn } from '@/utils/shadcn-ui.util';\nimport Markdown, { MarkdownToJSX } from 'markdown-to-jsx';\nimport { useMemo } from 'react';\n\ninterface MarkdownRendererProps {\n /** Optional unique identifier */\n id?: string;\n /** The markdown string to render */\n markdown: string;\n className?: string;\n /**\n * The [`target` attribute for `a` html\n * tags](https://developer.mozilla.org/en-US/docs/Web/HTML/Element/a#target). Defaults to not\n * adding a `target` to `a` tags\n */\n anchorTarget?: string;\n}\n\n/**\n * This component renders markdown content given a markdown string. It uses typography styles from\n * the platform.\n *\n * @param markdown The markdown string to render.\n * @param id Optional unique identifier\n * @returns A div containing the rendered markdown content.\n */\nexport default function MarkdownRenderer({\n id,\n markdown,\n className,\n anchorTarget,\n}: MarkdownRendererProps) {\n const options: MarkdownToJSX.Options = useMemo(\n () => ({\n overrides: {\n a: {\n props: {\n target: anchorTarget,\n },\n },\n },\n }),\n [anchorTarget],\n );\n return (\n
    \n {markdown}\n
    \n );\n}\n","import { Filter, ChevronDown } from 'lucide-react';\nimport { forwardRef } from 'react';\nimport { Button } from '@/components/shadcn-ui/button';\n\n/**\n * The FilterButton component is a button designed for initiating filtering of data. It is designed\n * to be used with the dropdown menu. It uses forwardRef to pass the button to the dropdown trigger\n * asChild.\n *\n * @returns A button that can be used to filter.\n */\nconst FilterButton = forwardRef((props, ref) => {\n return (\n \n \n Filter\n \n \n );\n});\n\nexport default FilterButton;\n","import {\n DropdownMenu,\n DropdownMenuTrigger,\n DropdownMenuContent,\n DropdownMenuLabel,\n DropdownMenuGroup,\n DropdownMenuCheckboxItem,\n DropdownMenuRadioItem,\n DropdownMenuSeparator,\n} from '@/components/shadcn-ui/dropdown-menu';\nimport FilterButton from './buttons/filter-button.component';\n\nexport enum DropdownMenuItemType {\n Check,\n Radio,\n}\n\nexport type DropdownItem = {\n /** The label is the text that will be displayed on the dropdown item. */\n label: string;\n /** The itemType determines the DropdownMenuItemType type as either Check or Radio. */\n itemType: DropdownMenuItemType;\n /** The onClick function is called when the item is clicked. */\n onClick: () => void;\n};\n\nexport type DropdownGroup = {\n /**\n * The label is the text that will be displayed on the dropdown group. It is used to categorize\n * the items in the group.\n */\n label: string;\n /** The items array contains the items that will be displayed in the dropdown group */\n items: DropdownItem[];\n};\n\nexport type FilterDropdownProps = {\n /** Object unique identifier */\n id?: string;\n /** The groups array contains the groups that will be displayed in the dropdown */\n groups: DropdownGroup[];\n}; // TODO: extend the props later\n\n/**\n * The FilterDropdown component is a dropdown designed for filtering content. It includes groups of\n * items that can be checkboxes or radio items.\n *\n * @param id Optional unique identifier\n * @param groups The groups array contains the groups that will be displayed in the dropdown\n * @returns A filter dropdown.\n */\nexport default function FilterDropdown({ id, groups }: FilterDropdownProps) {\n return (\n
    \n {/* TODO: remove this once the DropDown Menu shadcn has an id prop */}\n \n \n \n \n \n {groups.map((group) => (\n
    \n {group.label}\n \n {group.items.map((item) => (\n
    \n {item.itemType === DropdownMenuItemType.Check ? (\n \n {item.label}\n \n ) : (\n \n {item.label}\n \n )}\n
    \n ))}\n
    \n \n
    \n ))}\n
    \n
    \n
    \n );\n}\n","interface NoExtensionsFoundProps {\n /** Optional unique identifier */\n id?: string;\n /** The message to display */\n message: string;\n}\n/**\n * This component displays a message to the user when no extensions are found in the marketplace.\n *\n * @param id Optional unique identifier\n * @param message The message to display.\n * @returns {JSX.Element} - Returns the message component that displays the message to the user.\n */\nexport default function NoExtensionsFound({ id, message }: NoExtensionsFoundProps) {\n return (\n
    \n
    \n

    {message}

    \n
    \n
    \n );\n}\n","import { CircleHelp, Link as LucideLink, User } from 'lucide-react';\nimport { NumberFormat } from 'platform-bible-utils';\n\n/** Interface that stores the parameters passed to the More Info component */\ninterface MoreInfoProps {\n /** Optional unique identifier */\n id?: string;\n /** The category of the extension */\n category: string;\n /** The number of downloads for the extension */\n downloads: Record;\n /** The languages supported by the extension */\n languages: string[];\n /** The URL to the more info page of the extension */\n moreInfoUrl: string;\n}\n/**\n * This component displays the more info section of the extension which includes the category,\n * number of downloads, languages, and links to the website and support\n *\n * @param id Optional unique identifier\n * @param category The category of the extension\n * @param downloads The number of downloads for the extension\n * @param languages The languages supported by the extension\n * @param moreInfoUrl The URL to the more info page of the extension\n * @returns {JSX.Element} - Returns the more info component that displays the category, number of\n * downloads, languages, and links to the website and support\n */\nexport default function MoreInfo({\n id,\n category,\n downloads,\n languages,\n moreInfoUrl,\n}: MoreInfoProps) {\n /**\n * This constant formats the number of downloads into a more readable format.\n *\n * @example 1000 -> 1K\n *\n * @example 1000000 -> 1M\n *\n * @returns The formatted number of downloads\n */\n const numberFormatted = new NumberFormat('en', {\n notation: 'compact',\n compactDisplay: 'short',\n }).format(Object.values(downloads).reduce((a: number, b: number) => a + b, 0));\n\n /** This function scrolls the window to the bottom of the page. */\n const handleScrollToBottom = () => {\n window.scrollTo(0, document.body.scrollHeight);\n };\n\n return (\n \n
    \n
    \n {category}\n
    \n CATEGORY\n
    \n
    \n
    \n
    \n \n {numberFormatted}\n
    \n USERS\n
    \n
    \n
    \n
    \n {languages.slice(0, 3).map((locale) => (\n \n {locale.toUpperCase()}\n \n ))}\n
    \n {languages.length > 3 && (\n handleScrollToBottom()}\n className=\"tw-text-xs tw-text-gray-500 tw-underline\"\n >\n +{languages.length - 3} more languages\n \n )}\n
    \n
    \n
    \n \n Website\n \n \n \n Support\n \n \n
    \n
    \n );\n}\n","import { useState } from 'react';\n\nexport type VersionInformation = {\n /** Date the version was published */\n date: string;\n /** Description of the changes in the version */\n description: string;\n};\n\n/** Type to store the version history information */\nexport type VersionHistoryType = Record;\n\n/** Interface that stores the parameters passed to the Version History component */\ninterface VersionHistoryProps {\n /** Optional unique identifier */\n id?: string;\n /** Object containing the versions mapped with their information */\n versionHistory: VersionHistoryType;\n}\n\n/**\n * Component to render the version history information shown in the footer component. Lists the 5\n * most recent versions, with the options to show all versions by pressing a button.\n *\n * @param versionHistory Object containing the versions mapped with their information\n * @param id Optional unique identifier\n * @returns Rendered version history for the Footer component\n */\nexport default function VersionHistory({ id, versionHistory }: VersionHistoryProps) {\n const [showAllVersions, setShowAllVersions] = useState(false);\n const currentDate = new Date();\n\n /**\n * Function to format the time string for the version history in the form of 'X year(s) ago'.\n *\n * @param dateString ISO Date string to determine the time string from\n * @returns Formatted time string\n */\n function formatTimeString(dateString: string) {\n const date = new Date(dateString);\n const dateDiff = new Date(currentDate.getTime() - date.getTime());\n const yearDiff = dateDiff.getUTCFullYear() - 1970;\n const monthDiff = dateDiff.getUTCMonth();\n const dayDiff = dateDiff.getUTCDate() - 1;\n\n // Determines how long ago the version was published\n let timeString = '';\n if (yearDiff > 0) {\n timeString = `${yearDiff.toString()} year${yearDiff === 1 ? '' : 's'} ago`;\n } else if (monthDiff > 0) {\n timeString = `${monthDiff.toString()} month${monthDiff === 1 ? '' : 's'} ago`;\n } else if (dayDiff === 0) {\n timeString = 'today';\n } else {\n timeString = `${dayDiff.toString()} day${dayDiff === 1 ? '' : 's'} ago`;\n }\n\n return timeString;\n }\n\n // Sorts the version history by version number\n const sortedEntries = Object.entries(versionHistory).sort((a, b) => b[0].localeCompare(a[0]));\n\n return (\n
    \n

    What`s New

    \n
      \n {(showAllVersions ? sortedEntries : sortedEntries.slice(0, 5)).map((entry) => (\n
      \n
      \n
    • \n {entry[1].description}\n
    • \n
      \n
      \n
      Version {entry[0]}
      \n
      {formatTimeString(entry[1].date)}
      \n
      \n
      \n ))}\n
    \n {sortedEntries.length > 5 && (\n setShowAllVersions(!showAllVersions)}\n className=\"tw-text-xs tw-text-gray-500 tw-underline\"\n >\n {showAllVersions ? 'Show Less Version History' : 'Show All Version History'}\n \n )}\n
    \n );\n}\n","import { useMemo } from 'react';\nimport { formatBytes } from 'platform-bible-utils';\nimport VersionHistory, { VersionHistoryType } from './version-history.component';\n\n/** Interface to store the parameters passed to the Footer component */\ninterface FooterProps {\n /** Optional unique identifier */\n id?: string;\n /** Name of the publisher */\n publisherDisplayName: string;\n /** Size of the extension file in bytes */\n fileSize: number;\n /** List of language codes supported by the extension */\n locales: string[];\n /** Object containing the version history mapped with their information */\n versionHistory: VersionHistoryType;\n}\n\n/**\n * Component to render the footer for the extension details which contains information on the\n * publisher, version history, languages, and file size.\n *\n * @param id Optional unique identifier\n * @param publisherDisplayName Name of the publisher\n * @param fileSize Size of the extension file in bytes\n * @param locales List of language codes supported by the extension\n * @param versionHistory Object containing the version history mapped with their information\n * @returns The rendered Footer component\n */\nexport default function Footer({\n id,\n publisherDisplayName,\n fileSize,\n locales,\n versionHistory,\n}: FooterProps) {\n /** Formats the file size into a human-readable format */\n const formattedFileSize = useMemo(() => formatBytes(fileSize), [fileSize]);\n\n /**\n * This function gets the display names of the languages based on the language codes.\n *\n * @param codes The list of language codes\n * @returns The list of language names\n */\n const getLanguageNames = (codes: string[]) => {\n const displayNames = new Intl.DisplayNames(navigator.language, { type: 'language' });\n return codes.map((code) => displayNames.of(code));\n };\n\n const languageNames = getLanguageNames(locales);\n\n return (\n
    \n
    \n \n
    \n
    \n

    Information

    \n
    \n

    \n Publisher\n {publisherDisplayName}\n Size\n {formattedFileSize}\n

    \n
    \n

    \n Languages\n {languageNames.join(', ')}\n

    \n
    \n
    \n
    \n
    \n
    \n );\n}\n","import { PlatformEvent, PlatformEventHandler } from 'platform-bible-utils';\nimport { useEffect } from 'react';\n\n/**\n * Adds an event handler to an event so the event handler runs when the event is emitted. Use\n * `papi.network.getNetworkEvent` to use a networked event with this hook.\n *\n * @param event The event to subscribe to.\n *\n * - If event is a `PlatformEvent`, that event will be used\n * - If event is undefined, the callback will not be subscribed. Useful if the event is not yet\n * available for example\n *\n * @param eventHandler The callback to run when the event is emitted\n *\n * WARNING: MUST BE STABLE - const or wrapped in useCallback. The reference must not be updated\n * every render\n */\nconst useEvent = (\n event: PlatformEvent | undefined,\n eventHandler: PlatformEventHandler,\n) => {\n useEffect(() => {\n // Do nothing if the event is not provided (in case the event is not yet available, for example)\n if (!event) return () => {};\n\n const unsubscriber = event(eventHandler);\n return () => {\n unsubscriber();\n };\n }, [event, eventHandler]);\n};\nexport default useEvent;\n","import { useCallback, useEffect } from 'react';\nimport { PlatformEvent, PlatformEventAsync, PlatformEventHandler } from 'platform-bible-utils';\nimport usePromise from './use-promise.hook';\n\nconst noopUnsubscriber = () => false;\n\n/**\n * Adds an event handler to an asynchronously subscribing/unsubscribing event so the event handler\n * runs when the event is emitted. Use `papi.network.getNetworkEvent` to use a networked event with\n * this hook.\n *\n * @param event The asynchronously (un)subscribing event to subscribe to.\n *\n * - If event is a `PlatformEvent` or `PlatformEventAsync`, that event will be used\n * - If event is undefined, the callback will not be subscribed. Useful if the event is not yet\n * available for example\n *\n * @param eventHandler The callback to run when the event is emitted\n *\n * WARNING: MUST BE STABLE - const or wrapped in useCallback. The reference must not be updated\n * every render\n */\nconst useEventAsync = (\n event: PlatformEvent | PlatformEventAsync | undefined,\n eventHandler: PlatformEventHandler,\n) => {\n // Subscribe to the event asynchronously\n const [unsubscribe] = usePromise(\n useCallback(async () => {\n // Do nothing if the event is not provided (in case the event is not yet available, for example)\n if (!event) return noopUnsubscriber;\n\n // Wrap subscribe and unsubscribe in promises to allow normal events to be used as well\n const unsub = await Promise.resolve(event(eventHandler));\n return async () => unsub();\n }, [eventHandler, event]),\n noopUnsubscriber,\n // We want the unsubscriber to return to default value immediately upon changing subscription\n // So the useEffect below will unsubscribe asap\n { preserveValue: false },\n );\n\n // Unsubscribe from the event asynchronously (but we aren't awaiting the unsub)\n useEffect(() => {\n return () => {\n if (unsubscribe !== noopUnsubscriber) {\n unsubscribe();\n }\n };\n }, [unsubscribe]);\n};\n\nexport default useEventAsync;\n"],"names":["twMergeCustom","extendTailwindMerge","cn","inputs","clsx","Input","React","className","type","props","ref","jsx","BookChapterInput","forwardRef","handleSearch","handleKeyDown","handleOnClick","handleSubmit","jsxs","ShadInput","event","e","History","P","R","s","n","N","B","O","S","K","g","k","x","T","X","V","w","L","G","A","H","C","I","y","q","U","m","l","h","c","E","D","i","a","o","u","v","f","d","b","J","DropdownMenu","DropdownMenuPrimitive","DropdownMenuTrigger","DropdownMenuGroup","DropdownMenuPortal","DropdownMenuSub","DropdownMenuRadioGroup","DropdownMenuSubTrigger","inset","children","ChevronRight","DropdownMenuSubContent","DropdownMenuContent","sideOffset","DropdownMenuItem","DropdownMenuCheckboxItem","checked","Check","DropdownMenuRadioItem","Circle","DropdownMenuLabel","DropdownMenuSeparator","DropdownMenuShortcut","BookMenuItem","bookId","handleSelectBook","isSelected","handleHighlightBook","bookType","ShadDropdownMenuItem","Canon","ChapterSelect","handleSelectChapter","endChapter","activeChapter","highlightedChapter","handleHighlightedChapter","chapters","_","handleMouse","useCallback","chapterNumber","chapter","GoToMenuItem","handleSort","handleLocationHistory","handleBookmarks","ShadDropdownMenuLabel","ArrowDownWideNarrow","Clock","Bookmark","ALL_BOOK_IDS","BOOK_TYPE_LABELS","BOOK_TYPE_ARRAY","SCROLL_OFFSET","SEARCH_QUERY_FORMATS","fetchGroupedBooks","fetchEndChapter","getChaptersForBook","getAllEnglishNames","isValidBookEnglishName","bookName","getBookIdFromEnglishName","formattedBookName","BookChapterControl","scrRef","searchQuery","setSearchQuery","useState","selectedBookId","setSelectedBookId","setHighlightedChapter","highlightedBookId","setHighlightedBookId","isContentOpen","setIsContentOpen","isContentOpenDelayed","setIsContentOpenDelayed","inputRef","useRef","contentRef","menuItemRef","fetchFilteredBooks","englishNameLowerCase","normalizedQuery","handleSearchInput","searchString","shouldPreventAutoClosing","controlMenuState","open","updateReference","shouldClose","verse","handleInputSubmit","format","matches","book","englishName","handleKeyDownInput","handleKeyDownContent","key","handleKeyDownMenuItem","chapterOffSet","useEffect","useLayoutEffect","scrollTimeout","scrollPosition","ShadDropdownMenu","ShadDropdownMenuTrigger","ShadDropdownMenuContent","bookTypeIndex","element","ShadDropdownMenuSeparator","buttonVariants","cva","Button","variant","size","asChild","Slot","labelVariants","Label","LabelPrimitive","RadioGroup","RadioGroupPrimitive","RadioGroupItem","Popover","PopoverPrimitive","PopoverTrigger","PopoverContent","align","DialogPortal","DialogPrimitive","DialogOverlay","DialogContent","DialogTitle","DialogDescription","Command","CommandPrimitive","CommandInput","Search","CommandList","CommandEmpty","CommandGroup","CommandSeparator","CommandItem","getOptionLabelDefault","option","ComboBox","id","options","buttonClassName","popoverContentClassName","value","onChange","getOptionLabel","buttonPlaceholder","textPlaceholder","commandEmptyMessage","buttonVariant","dir","isDisabled","setOpen","ChevronsUpDown","ChapterRangeSelector","startChapter","handleSelectStartChapter","handleSelectEndChapter","chapterCount","chapterOptions","useMemo","index","Fragment","BookSelectionMode","BOOK_SELECTOR_STRING_KEYS","localizeString","strings","BookSelector","handleBookSelectionModeChange","currentBookName","onSelectBooks","selectedBookIds","localizedStrings","currentBookText","chooseText","chooseBooksText","bookSelectionMode","setBookSelectionMode","onSelectionModeChange","newMode","DataTableViewOptions","table","FilterIcon","column","Select","SelectPrimitive","SelectGroup","SelectValue","SelectTrigger","ChevronDown","SelectScrollUpButton","ChevronUp","SelectScrollDownButton","SelectContent","position","SelectLabel","SelectItem","SelectSeparator","DataTablePagination","pageSize","ArrowLeftIcon","ChevronLeftIcon","ChevronRightIcon","ArrowRightIcon","Table","stickyHeader","TableHeader","TableBody","TableFooter","TableRow","TableHead","TableCell","TableCaption","DataTable","columns","data","enablePagination","showPaginationControls","showColumnVisibilityControls","onRowClickHandler","sorting","setSorting","columnFilters","setColumnFilters","columnVisibility","setColumnVisibility","rowSelection","setRowSelection","useReactTable","getCoreRowModel","getPaginationRowModel","getSortedRowModel","getFilteredRowModel","headerGroup","header","flexRender","_a","row","cell","OccurrencesTable","occurrenceData","setScriptureReference","referenceHeaderText","occurrenceHeaderText","occurrences","uniqueOccurrences","occurrence","uniqueOccurrence","deepEqual","Checkbox","CheckboxPrimitive","getLinesFromUSFM","text","getNumberFromUSFM","regex","match","getBookNumFromId","getStatusForItem","item","approvedItems","unapprovedItems","toggleVariants","Toggle","TogglePrimitive","ToggleGroupContext","ToggleGroup","ToggleGroupPrimitive","ToggleGroupItem","context","getSortingIcon","sortDirection","ArrowUpIcon","ArrowDownIcon","ArrowUpDownIcon","inventoryItemColumn","itemLabel","inventoryAdditionalItemColumn","additionalItemLabel","additionalItemIndex","inventoryCountColumn","countLabel","statusChangeHandler","changedItems","newStatus","onApprovedItemsChange","onUnapprovedItemsChange","newApprovedItems","validItem","newUnapprovedItems","unapprovedItem","inventoryStatusColumn","statusLabel","status","CircleCheckIcon","CircleXIcon","CircleHelpIcon","INVENTORY_STRING_KEYS","filterItemData","itemData","statusFilter","textFilter","filteredItemData","createTableData","scriptureRef","itemRegex","tableData","currentBook","currentChapter","currentVerse","line","items","itemIndex","existingItem","tableEntry","newReference","substring","newItem","Inventory","scriptureReference","extractItems","additionalItemsLabels","scope","onScopeChange","allItemsText","approvedItemsText","unapprovedItemsText","unknownItemsText","scopeBookText","scopeChapterText","scopeVerseText","filterText","showAdditionalItemsText","showAdditionalItems","setShowAdditionalItems","setStatusFilter","setTextFilter","selectedItem","setSelectedItem","reducedTableData","newTableData","firstItem","existingEntry","newTableEntry","filteredTableData","allColumns","numberOfAdditionalItems","additionalColumns","_b","rowClickHandler","newSelection","handleScopeChange","handleStatusFilterChange","SearchBar","onSearch","placeholder","isFullWidth","handleInputChange","VerticalTabs","TabsPrimitive","VerticalTabsList","VerticalTabsTrigger","VerticalTabsContent","TabNavigationContentSearch","tabList","searchPlaceholder","headerTitle","isSearchBarFullWidth","direction","tab","Separator","orientation","decorative","SeparatorPrimitive","Skeleton","TooltipProvider","TooltipPrimitive","Tooltip","TooltipTrigger","TooltipContent","SIDEBAR_WIDTH","SIDEBAR_WIDTH_ICON","SIDEBAR_KEYBOARD_SHORTCUT","SidebarContext","useSidebar","SidebarProvider","defaultOpen","openProp","setOpenProp","style","_open","_setOpen","isOpen","openState","toggleSidebar","state","contextValue","Sidebar","side","collapsible","SidebarTrigger","onClick","PanelLeft","SidebarRail","SidebarInset","SidebarInput","SidebarHeader","SidebarFooter","SidebarSeparator","SidebarContent","SidebarGroup","SidebarGroupLabel","SidebarGroupAction","SidebarGroupContent","SidebarMenu","SidebarMenuItem","sidebarMenuButtonVariants","SidebarMenuButton","isActive","tooltip","Comp","button","SidebarMenuAction","showOnHover","SidebarMenuBadge","SidebarMenuSkeleton","showIcon","width","SidebarMenuSub","SidebarMenuSubItem","SidebarMenuSubButton","SettingsSidebar","extensionLabels","projectOptions","handleSelectSidebarItem","selectedSidebarItem","extensionsSidebarGroupLabel","projectsSidebarGroupLabel","buttonPlaceholderText","handleSelectItem","projectId","getProjectNameFromProjectId","project","getIsActive","label","selectedProjectName","SettingsSidebarContentSearch","scrBookColId","scrRefColId","typeColId","detailsColId","defaultScrRefColumnName","defaultScrBookGroupName","defaultTypeColumnName","defaultDetailsColumnName","getColumns","colInfo","showSourceColumn","showSrcCol","info","formatScrRef","compareScrRefs","toRefOrRange","scriptureSelection","offsetStart","offsetEnd","scrRefToBBBCCCVVV","getRowKey","ScriptureResultsViewer","sources","showColumnHeaders","scriptureReferenceColumnName","scriptureBookGroupName","typeColumnName","detailsColumnName","onRowSelected","grouping","setGrouping","scriptureResults","source","getExpandedRowModel","getGroupedRowModel","selectedRows","keys","selectedRow","scrBookGroupName","typeGroupName","groupingOptions","handleSelectChange","selectedGrouping","handleRowClick","getEvenOrOddBandingStyle","getIndent","groupingState","rowIndex","ChevronLeft","DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS","getLocalizeKeyForScrollGroupId","ScrollGroupSelector","availableScrollGroupIds","scrollGroupId","onChangeScrollGroupId","localizedStringsDefaulted","localizedStringKey","localizedStringValue","newScrollGroupString","scrollGroupOptionId","SettingsList","SettingsListItem","primary","secondary","isLoading","loadingMessage","SettingsListHeader","includeSeparator","Checklist","listItems","selectedListItems","handleSelectListItem","createLabel","_interopRequireDefault","obj","module","chainPropTypes","propType1","propType2","args","_extends","target","isPlainObject","prototype","deepClone","output","deepmerge","p","r","t","z","reactIs_production_min","hasSymbol","REACT_ELEMENT_TYPE","REACT_PORTAL_TYPE","REACT_FRAGMENT_TYPE","REACT_STRICT_MODE_TYPE","REACT_PROFILER_TYPE","REACT_PROVIDER_TYPE","REACT_CONTEXT_TYPE","REACT_ASYNC_MODE_TYPE","REACT_CONCURRENT_MODE_TYPE","REACT_FORWARD_REF_TYPE","REACT_SUSPENSE_TYPE","REACT_SUSPENSE_LIST_TYPE","REACT_MEMO_TYPE","REACT_LAZY_TYPE","REACT_BLOCK_TYPE","REACT_FUNDAMENTAL_TYPE","REACT_RESPONDER_TYPE","REACT_SCOPE_TYPE","isValidElementType","typeOf","object","$$typeof","$$typeofType","AsyncMode","ConcurrentMode","ContextConsumer","ContextProvider","Element","ForwardRef","Lazy","Memo","Portal","Profiler","StrictMode","Suspense","hasWarnedAboutDeprecatedIsAsyncMode","isAsyncMode","isConcurrentMode","isContextConsumer","isContextProvider","isElement","isForwardRef","isFragment","isLazy","isMemo","isPortal","isProfiler","isStrictMode","isSuspense","reactIs_development","reactIsModule","require$$0","require$$1","getOwnPropertySymbols","hasOwnProperty","propIsEnumerable","toObject","val","shouldUseNative","test1","test2","order2","test3","letter","objectAssign","from","to","symbols","ReactPropTypesSecret","ReactPropTypesSecret_1","has","printWarning","loggedTypeFailures","message","checkPropTypes","typeSpecs","values","location","componentName","getStack","typeSpecName","error","err","ex","stack","checkPropTypes_1","ReactIs","assign","require$$2","require$$3","require$$4","emptyFunctionThatReturnsNull","factoryWithTypeCheckers","isValidElement","throwOnDirectAccess","ITERATOR_SYMBOL","FAUX_ITERATOR_SYMBOL","getIteratorFn","maybeIterable","iteratorFn","ANONYMOUS","ReactPropTypes","createPrimitiveTypeChecker","createAnyTypeChecker","createArrayOfTypeChecker","createElementTypeChecker","createElementTypeTypeChecker","createInstanceTypeChecker","createNodeChecker","createObjectOfTypeChecker","createEnumTypeChecker","createUnionTypeChecker","createShapeTypeChecker","createStrictShapeTypeChecker","is","PropTypeError","createChainableTypeChecker","validate","manualPropTypeCallCache","manualPropTypeWarningCount","checkType","isRequired","propName","propFullName","secret","cacheKey","chainedCheckType","expectedType","propValue","propType","getPropType","preciseType","getPreciseType","typeChecker","expectedClass","expectedClassName","actualClassName","getClassName","expectedValues","valuesString","arrayOfTypeCheckers","checker","getPostfixForTypeWarning","expectedTypes","checkerResult","expectedTypesMessage","isNode","invalidValidatorError","shapeTypes","allKeys","iterator","step","entry","isSymbol","emptyFunction","emptyFunctionWithReset","factoryWithThrowingShims","shim","getShim","propTypesModule","isClassComponent","elementType","acceptingRef","safePropName","warningHint","elementAcceptingRef","PropTypes","elementAcceptingRef$1","specialProperty","exactProp","propTypes","unsupportedProps","prop","formatMuiErrorMessage","code","url","REACT_SERVER_CONTEXT_TYPE","REACT_OFFSCREEN_TYPE","enableScopeAPI","enableCacheElement","enableTransitionTracing","enableLegacyHidden","enableDebugTracing","REACT_MODULE_REFERENCE","SuspenseList","hasWarnedAboutDeprecatedIsConcurrentMode","isSuspenseList","fnNameMatchRegex","getFunctionName","fn","getFunctionComponentName","Component","fallback","getWrappedName","outerType","innerType","wrapperName","functionName","getDisplayName","HTMLElementType","refType","refType$1","capitalize","string","_formatMuiErrorMessage","createChainedFunction","funcs","acc","func","debounce","wait","timeout","debounced","later","deprecatedPropType","validator","reason","componentNameSafe","propFullNameSafe","isMuiElement","muiNames","_muiName","_element$type","ownerDocument","node","ownerWindow","requirePropFactory","componentNameInError","prevPropTypes","requiredProp","defaultTypeChecker","typeCheckerResult","setRef","useEnhancedEffect","useEnhancedEffect$1","globalId","useGlobalId","idOverride","defaultId","setDefaultId","maybeReactUseId","useId","reactId","unsupportedProp","useControlled","controlled","defaultProp","name","isControlled","valueState","setValue","defaultValue","setValueIfUncontrolled","newValue","useEventCallback","useForkRef","refs","instance","UNINITIALIZED","useLazyRef","init","initArg","EMPTY","useOnMount","Timeout","delay","useTimeout","hadKeyboardEvent","hadFocusVisibleRecently","hadFocusVisibleRecentlyTimeout","inputTypesWhitelist","focusTriggersKeyboardModality","tagName","handlePointerDown","handleVisibilityChange","prepare","doc","isFocusVisible","useIsFocusVisible","isFocusVisibleRef","handleBlurVisible","handleFocusVisible","resolveProps","defaultProps","defaultSlotProps","slotProps","slotPropName","composeClasses","slots","getUtilityClass","classes","slot","utilityClass","defaultGenerator","createClassNameGenerator","generate","generator","ClassNameGenerator","ClassNameGenerator$1","globalStateClasses","generateUtilityClass","globalStatePrefix","globalStateClass","generateUtilityClasses","result","clamp","min","max","_objectWithoutPropertiesLoose","excluded","sourceKeys","_excluded","sortBreakpointsValues","breakpointsAsArray","breakpoint1","breakpoint2","createBreakpoints","breakpoints","unit","other","sortedValues","up","down","between","start","end","endIndex","only","not","keyIndex","shape","shape$1","responsivePropType","responsivePropType$1","merge","defaultBreakpoints","handleBreakpoints","styleFromPropValue","theme","themeBreakpoints","breakpoint","mediaKey","cssKey","createEmptyBreakpointObject","breakpointsInput","_breakpointsInput$key","breakpointStyleKey","removeUnusedBreakpoints","breakpointKeys","breakpointOutput","getPath","path","checkVars","getStyleValue","themeMapping","transform","propValueFinal","userValue","cssProperty","themeKey","memoize","cache","arg","properties","directions","aliases","getCssProperties","property","marginKeys","paddingKeys","spacingKeys","createUnaryUnit","_getPath","themeSpacing","abs","createUnarySpacing","getValue","transformer","transformed","getStyleFromPropValue","cssProperties","resolveCssProperty","margin","padding","createSpacing","spacingInput","spacing","argsInput","argument","compose","styles","handlers","borderTransform","createBorderStyle","border","borderTop","borderRight","borderBottom","borderLeft","borderColor","borderTopColor","borderRightColor","borderBottomColor","borderLeftColor","outline","outlineColor","borderRadius","gap","columnGap","rowGap","gridColumn","gridRow","gridAutoFlow","gridAutoColumns","gridAutoRows","gridTemplateColumns","gridTemplateRows","gridTemplateAreas","gridArea","paletteTransform","color","bgcolor","backgroundColor","sizingTransform","maxWidth","_props$theme","_props$theme2","breakpointsValues","minWidth","height","maxHeight","minHeight","boxSizing","defaultSxConfig","defaultSxConfig$1","objectsHaveSameKeys","objects","union","callIfFn","maybeFn","unstable_createStyleFunctionSx","getThemeValue","config","styleFunctionSx","_theme$unstable_sxCon","sx","traverse","sxInput","sxObject","emptyBreakpoints","breakpointsKeys","css","styleKey","styleFunctionSx$1","applyStyles","createTheme","paletteInput","shapeInput","muiTheme","isObjectEmpty","useTheme","defaultTheme","contextTheme","ThemeContext","systemDefaultTheme","useThemeWithoutDefault","_excluded2","_excluded3","isEmpty","isStringTag","tag","shouldForwardProp","lowercaseFirstLetter","resolveTheme","themeId","defaultOverridesResolver","processStyleArg","callableStyle","_ref","ownerState","resolvedStylesArg","resolvedStyle","variants","isMatch","createStyled","input","rootShouldForwardProp","slotShouldForwardProp","systemSx","inputOptions","processStyles","componentSlot","inputSkipVariantsResolver","inputSkipSx","overridesResolver","skipVariantsResolver","skipSx","shouldForwardPropOption","defaultStyledResolver","styledEngineStyled","transformStyleArg","stylesArg","muiStyledResolver","styleArg","expressions","transformedStyleArg","expressionsWithDefaultTheme","styleOverrides","resolvedStyleOverrides","slotKey","slotStyle","_theme$components","themeVariants","numOfCustomFnsApplied","placeholders","displayName","getThemeProps","params","useThemeProps","clampWrapper","hexToRgb","re","colors","decomposeColor","marker","colorSpace","recomposeColor","hslToRgb","rgb","getLuminance","getContrastRatio","foreground","background","lumA","lumB","alpha","darken","coefficient","lighten","createMixins","mixins","common","common$1","grey","grey$1","purple","purple$1","red","red$1","orange","orange$1","blue","blue$1","lightBlue","lightBlue$1","green","green$1","light","dark","addLightOrDark","intent","shade","tonalOffset","tonalOffsetLight","tonalOffsetDark","getDefaultPrimary","mode","getDefaultSecondary","getDefaultError","getDefaultInfo","getDefaultSuccess","getDefaultWarning","createPalette","palette","contrastThreshold","success","warning","getContrastText","contrastText","contrast","augmentColor","mainShade","lightShade","darkShade","modes","round","caseAllCaps","defaultFontFamily","createTypography","typography","fontFamily","fontSize","fontWeightLight","fontWeightRegular","fontWeightMedium","fontWeightBold","htmlFontSize","allVariants","pxToRem2","coef","pxToRem","buildVariant","fontWeight","lineHeight","letterSpacing","casing","shadowKeyUmbraOpacity","shadowKeyPenumbraOpacity","shadowAmbientShadowOpacity","createShadow","px","shadows","shadows$1","easing","duration","formatMs","milliseconds","getAutoHeightDuration","constant","createTransitions","inputTransitions","mergedEasing","mergedDuration","durationOption","easingOption","isString","isNumber","animatedProp","zIndex","zIndex$1","mixinsInput","transitionsInput","typographyInput","systemTheme","systemCreateTheme","stateClasses","component","child","stateClass","defaultTheme$1","THEME_ID","systemUseThemeProps","styled","styled$1","getSvgIconUtilityClass","useUtilityClasses","SvgIconRoot","_theme$transitions","_theme$transitions$cr","_theme$transitions2","_theme$typography","_theme$typography$pxT","_theme$typography2","_theme$typography2$px","_theme$typography3","_theme$typography3$px","_palette$ownerState$c","_palette","_palette2","_palette3","SvgIcon","inProps","htmlColor","inheritViewBox","titleAccess","viewBox","hasSvgAsChild","more","_jsxs","_jsx","SvgIcon$1","createSvgIcon","unstable_ClassNameGenerator","exports","_utils","ArrowRight","default_1","_createSvgIcon","_jsxRuntime","isHostComponent","appendOwnerState","otherProps","defaultContextValue","ClassNameConfiguratorContext","useClassNamesOverride","disableDefaultClasses","extractEventHandlers","excludeKeys","resolveComponentProps","componentProps","slotState","omitEventHandlers","mergeSlotProps","parameters","getSlotProps","additionalProps","externalSlotProps","externalForwardedProps","joinedClasses","mergedStyle","eventHandlers","componentsPropsWithoutEventHandlers","otherPropsWithoutEventHandlers","internalSlotProps","useSlotProps","_parameters$additiona","skipResolvingSlotProps","rest","resolvedComponentsProps","mergedProps","internalRef","GLOBAL_CLASS_PREFIX","buildStateClass","buildSlotClass","getContainer","container","forwardedRef","disablePortal","mountNode","setMountNode","handleRef","newProps","ReactDOM","top","bottom","right","left","auto","basePlacements","clippingParents","viewport","popper","reference","variationPlacements","placement","placements","beforeRead","read","afterRead","beforeMain","main","afterMain","beforeWrite","write","afterWrite","modifierPhases","getNodeName","getWindow","OwnElement","isHTMLElement","isShadowRoot","attributes","effect","_ref2","initialStyles","styleProperties","attribute","applyStyles$1","getBasePlacement","getUAString","uaData","isLayoutViewport","getBoundingClientRect","includeScale","isFixedStrategy","clientRect","scaleX","scaleY","visualViewport","addVisualOffsets","getLayoutRect","contains","parent","rootNode","next","getComputedStyle","isTableElement","getDocumentElement","getParentNode","getTrueOffsetParent","getContainingBlock","isFirefox","isIE","elementCss","currentNode","getOffsetParent","window","offsetParent","getMainAxisFromPlacement","within","mathMax","mathMin","withinMaxClamp","getFreshSideObject","mergePaddingObject","paddingObject","expandToHashMap","hashMap","toPaddingObject","arrow","_state$modifiersData$","arrowElement","popperOffsets","basePlacement","axis","isVertical","len","arrowRect","minProp","maxProp","endDiff","startDiff","arrowOffsetParent","clientSize","centerToReference","center","offset","axisProp","_options$element","arrow$1","getVariation","unsetSides","roundOffsetsByDPR","win","dpr","mapToStyles","_Object$assign2","popperRect","variation","offsets","gpuAcceleration","adaptive","roundOffsets","isFixed","_offsets$x","_offsets$y","_ref3","hasX","hasY","sideX","sideY","heightProp","widthProp","offsetY","offsetX","commonStyles","_ref4","_Object$assign","computeStyles","_ref5","_options$gpuAccelerat","_options$adaptive","_options$roundOffsets","computeStyles$1","passive","_options$scroll","scroll","_options$resize","resize","scrollParents","scrollParent","eventListeners","hash","getOppositePlacement","matched","getOppositeVariationPlacement","getWindowScroll","scrollLeft","scrollTop","getWindowScrollBarX","getViewportRect","strategy","html","layoutViewport","getDocumentRect","_element$ownerDocumen","winScroll","body","isScrollParent","_getComputedStyle","overflow","overflowX","overflowY","getScrollParent","listScrollParents","list","isBody","updatedList","rectToClientRect","rect","getInnerBoundingClientRect","getClientRectFromMixedType","clippingParent","getClippingParents","canEscapeClipping","clipperElement","getClippingRect","boundary","rootBoundary","mainClippingParents","firstClippingParent","clippingRect","accRect","computeOffsets","commonX","commonY","mainAxis","detectOverflow","_options","_options$placement","_options$strategy","_options$boundary","_options$rootBoundary","_options$elementConte","elementContext","_options$altBoundary","altBoundary","_options$padding","altContext","clippingClientRect","referenceClientRect","popperClientRect","elementClientRect","overflowOffsets","offsetData","multiply","computeAutoPlacement","flipVariations","_options$allowedAutoP","allowedAutoPlacements","allPlacements","allowedPlacements","overflows","getExpandedFallbackPlacements","oppositePlacement","flip","_options$mainAxis","checkMainAxis","_options$altAxis","checkAltAxis","specifiedFallbackPlacements","_options$flipVariatio","preferredPlacement","isBasePlacement","fallbackPlacements","referenceRect","checksMap","makeFallbackChecks","firstFittingPlacement","_basePlacement","isStartVariation","mainVariationSide","altVariationSide","checks","check","numberOfChecks","_loop","_i","fittingPlacement","_ret","flip$1","getSideOffsets","preventedOffsets","isAnySideFullyClipped","hide","referenceOverflow","popperAltOverflow","referenceClippingOffsets","popperEscapeOffsets","isReferenceHidden","hasPopperEscaped","hide$1","distanceAndSkiddingToXY","rects","invertDistance","skidding","distance","_options$offset","_data$state$placement","offset$1","popperOffsets$1","getAltAxis","preventOverflow","_options$tether","tether","_options$tetherOffset","tetherOffset","altAxis","tetherOffsetValue","normalizedTetherOffsetValue","offsetModifierState","_offsetModifierState$","mainSide","altSide","additive","minLen","maxLen","arrowPaddingObject","arrowPaddingMin","arrowPaddingMax","arrowLen","minOffset","maxOffset","clientOffset","offsetModifierValue","tetherMin","tetherMax","preventedOffset","_offsetModifierState$2","_mainSide","_altSide","_offset","_len","_min","_max","isOriginSide","_offsetModifierValue","_tetherMin","_tetherMax","_preventedOffset","preventOverflow$1","getHTMLElementScroll","getNodeScroll","isElementScaled","getCompositeRect","elementOrVirtualElement","isOffsetParentAnElement","offsetParentIsScaled","documentElement","order","modifiers","map","visited","modifier","sort","requires","dep","depModifier","orderModifiers","orderedModifiers","phase","pending","resolve","mergeByName","merged","current","existing","DEFAULT_OPTIONS","areValidElements","_key","popperGenerator","generatorOptions","_generatorOptions","_generatorOptions$def","defaultModifiers","_generatorOptions$def2","defaultOptions","effectCleanupFns","isDestroyed","setOptionsAction","cleanupModifierEffects","runModifierEffects","_state$elements","_state$orderedModifie","_state$orderedModifie2","_ref$options","cleanupFn","noopFn","createPopper","COMPONENT_NAME","getPopperUtilityClass","flipPlacement","resolveAnchorEl","anchorEl","isVirtualElement","defaultPopperOptions","PopperTooltip","_slots$root","initialPlacement","popperOptions","popperRefProp","TransitionProps","tooltipRef","ownRef","popperRef","handlePopperRef","handlePopperRefRef","rtlPlacement","setPlacement","resolvedAnchorElement","setResolvedAnchorElement","handlePopperUpdate","box","popperModifiers","childProps","Root","rootProps","Popper","containerProp","keepMounted","transition","exited","setExited","handleEnter","handleExited","resolvedAnchorEl","display","transitionProps","useThemeSystem","_setPrototypeOf","_inheritsLoose","subClass","superClass","setPrototypeOf","timeoutsShape","TransitionGroupContext","forceReflow","UNMOUNTED","EXITED","ENTERING","ENTERED","EXITING","Transition","_React$Component","_this","parentGroup","appear","initialStatus","prevState","nextIn","_proto","prevProps","nextStatus","exit","enter","mounting","_this2","appearing","maybeNode","maybeAppearing","timeouts","enterTimeout","_this3","nextState","callback","_this4","active","handler","doesNotHaveTimeoutOrListener","maybeNextCallback","_this$props","pt","noop","Transition$1","reflow","getTransitionProps","_style$transitionDura","_style$transitionTimi","getScale","isWebKit154","Grow","addEndListener","inProp","onEnter","onEntered","onEntering","onExit","onExited","onExiting","TransitionComponent","timer","autoTimeout","nodeRef","normalizedTransitionCallback","maybeIsAppearing","handleEntering","isAppearing","transitionDuration","transitionTimingFunction","handleEntered","handleExiting","handleExit","Grow$1","PopperRoot","BasePopper","components","componentsProps","RootComponent","Popper$1","getTooltipUtilityClass","tooltipClasses","tooltipClasses$1","disableInteractive","touch","TooltipPopper","TooltipTooltip","TooltipArrow","hystersisOpen","hystersisTimer","cursorPosition","composeEventHandler","eventHandler","_slots$popper","_slots$transition","_slots$tooltip","_slots$arrow","_slotProps$popper","_ref6","_slotProps$popper2","_slotProps$transition","_slotProps$tooltip","_ref7","_slotProps$tooltip2","_slotProps$arrow","_ref8","_slotProps$arrow2","childrenProp","describeChild","disableFocusListener","disableHoverListener","disableInteractiveProp","disableTouchListener","enterDelay","enterNextDelay","enterTouchDelay","followCursor","idProp","leaveDelay","leaveTouchDelay","onClose","onOpen","PopperComponentProp","PopperProps","title","TransitionComponentProp","isRtl","childNode","setChildNode","arrowRef","setArrowRef","ignoreNonTouchEvents","closeTimer","enterTimer","leaveTimer","touchTimer","setOpenState","prevUserSelect","stopTouchInteraction","handleOpen","handleClose","handleLeave","focusVisibleRef","setChildIsFocusVisible","handleBlur","handleFocus","detectTouchStart","childrenProps","handleMouseOver","handleMouseLeave","handleTouchStart","handleTouchEnd","nativeEvent","handleMouseMove","nameOrDescProps","titleIsString","interactiveWrapperListeners","_PopperProps$popperOp","tooltipModifiers","PopperComponent","TooltipComponent","ArrowComponent","popperProps","tooltipProps","tooltipArrowProps","TransitionPropsInner","Tooltip$1","getIcon","icon","menuLabel","leading","MuiListItemIcon","MenuItem","allowForLeadingIcons","iconPathBefore","iconPathAfter","hasAutoFocus","isDense","isSubMenuParent","hasDisabledGutters","hasDivider","focusVisibleClassName","menuItem","MuiMenuItem","MuiListItemText","getAllGroups","menuDefinition","SubMenu","setAnchorEl","parentMenuItem","parentItemProps","handleParentMenuItemClick","renderSubMenuItems","includedGroups","group","GroupedMenuItemList","Menu","getOrderedGroupItems","groupId","allItems","menuProps","commandHandler","groupsToInclude","sortedGroups","itemArray","allowSpaceForLeadingIcons","createMenuItemProps","isLastItemInGroup","divKey","itemInfo","menuItemProps","TopLevelMenu","columnId","MenuColumn","metadata","Grid","List","GridMenu","multiColumnMenu","sortedColumns","columnNumbers","columnName","col","getUsePromiseOptionsDefaults","usePromise","promiseFactoryCallback","defaultValueRef","optionsDefaultedRef","setIsLoading","promiseIsCurrent","MenuIcon","HamburgerMenuButton","menuProvider","normalMenu","fullMenu","containerRef","ariaLabelPrefix","isMenuOpen","setMenuOpen","showFullMenu","setShowFullMenu","handleMenuItemClick","handleMenuButtonClick","prevIsOpen","isOpening","menuCommandHandler","command","setOffset","normalMenuData","fullMenuData","menu","IconButton","Drawer","isTooltipSuppressed","adjustMarginToAlignToEdge","MuiIconButton","Spinner","LoaderCircle","TextField","hasError","helperText","onFocus","onBlur","ShadLabel","Toolbar","AppBar","MuiToolbar","alertVariants","Alert","AlertTitle","AlertDescription","Card","CardHeader","CardTitle","CardDescription","CardContent","CardFooter","Sonner","Toaster","Slider","SliderPrimitive","Switch","SwitchPrimitives","Tabs","TabsList","TabsTrigger","TabsContent","InstallButton","isInstalling","handleClick","buttonText","Download","EnableButton","isEnabling","DisableButton","isDisabling","UpdateButton","isUpdating","MarkdownRenderer","markdown","anchorTarget","Markdown","FilterButton","Filter","DropdownMenuItemType","DropdownMenuItemType2","FilterDropdown","groups","NoExtensionsFound","MoreInfo","category","downloads","languages","moreInfoUrl","numberFormatted","NumberFormat","handleScrollToBottom","User","locale","LucideLink","CircleHelp","VersionHistory","versionHistory","showAllVersions","setShowAllVersions","currentDate","formatTimeString","dateString","date","dateDiff","yearDiff","monthDiff","dayDiff","timeString","sortedEntries","Footer","publisherDisplayName","fileSize","locales","formattedFileSize","formatBytes","languageNames","codes","displayNames","useEvent","unsubscriber","noopUnsubscriber","useEventAsync","unsubscribe","unsub"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAGA,MAAMA,KAAgBC,GAAoB,EAAE,QAAQ,MAAO,CAAA;AAyDpD,SAASC,KAAMC,GAAsB;AACnC,SAAAH,GAAcI,GAAKD,CAAM,CAAC;AACnC;ACzDO,MAAME,KAAQC,EAAM;AAAA,EACzB,CAAC,EAAE,WAAAC,GAAW,MAAAC,GAAM,GAAGC,EAAA,GAASC,MAE5B,gBAAAC;AAAA,IAAC;AAAA,IAAA;AAAA,MACC,MAAAH;AAAA,MACA,WAAWN;AAAA,QACT;AAAA,QACAK;AAAA,MACF;AAAA,MACA,KAAAG;AAAA,MAEC,GAAGD;AAAA,IAAA;AAAA,EAAA;AAIZ;AACAJ,GAAM,cAAc;ACNpB,MAAMO,KAAmBC;AAAA,EACvB,CACE,EAA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;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AACF,GAAGC,KAAI;AAAA,EACL;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA;AAAA;AAAA,EAGA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EAC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;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","x_google_ignoreList":[3,43,44,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,83,84,85,86,87,88,89,90,91,92,93,94,95,96,97,98,99,100,101,102,103,104,105,106,107,108,109,110,111,112,113,114,115,116,117,118,119,120,121,122,123,124,125,126,127,128,129,130,131,132,133,134,135,136,137,138,139,140,141,142,143,144,145,146,147,148,149,150,151,152,153,154,155,156,157,158,159,160,161,162,163,164,165,166,167,168,169,170,171,172,173,174,175,176,177,178,179,180,181,182,183,184,185,186,187,188,189,190,191,192,193,194,195,196,197,198,199,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,226]} \ No newline at end of file +{"version":3,"file":"index.js","sources":["../src/utils/shadcn-ui.util.ts","../src/components/shadcn-ui/input.tsx","../src/components/advanced/book-chapter-control/book-chapter-input.component.tsx","../../../node_modules/@sillsdev/scripture/dist/index.es.js","../src/components/shadcn-ui/dropdown-menu.tsx","../src/components/advanced/book-chapter-control/book-menu-item.component.tsx","../src/components/advanced/book-chapter-control/chapter-select.component.tsx","../src/components/advanced/book-chapter-control/go-to-menu-item.component.tsx","../src/components/advanced/book-chapter-control/book-chapter-control.component.tsx","../src/components/shadcn-ui/button.tsx","../src/components/shadcn-ui/label.tsx","../src/components/shadcn-ui/radio-group.tsx","../src/components/shadcn-ui/popover.tsx","../src/components/shadcn-ui/dialog.tsx","../src/components/shadcn-ui/command.tsx","../src/components/basics/combo-box.component.tsx","../src/components/basics/chapter-range-selector.component.tsx","../src/components/advanced/book-selector.component.tsx","../src/components/advanced/data-table/data-table-column-toggle.component.tsx","../src/components/shadcn-ui/select.tsx","../src/components/advanced/data-table/data-table-pagination.component.tsx","../src/components/shadcn-ui/table.tsx","../src/components/advanced/data-table/data-table.component.tsx","../src/components/advanced/inventory/occurrences-table.component.tsx","../src/components/shadcn-ui/checkbox.tsx","../src/components/advanced/inventory/inventory-utils.ts","../src/components/shadcn-ui/toggle.tsx","../src/components/shadcn-ui/toggle-group.tsx","../src/components/advanced/inventory/inventory-columns.tsx","../src/components/advanced/inventory/inventory.component.tsx","../src/components/basics/search-bar.component.tsx","../src/components/basics/tabs-vertical.tsx","../src/components/advanced/tab-navigation-content-search.component.tsx","../src/components/shadcn-ui/separator.tsx","../src/components/shadcn-ui/skeleton.tsx","../src/components/shadcn-ui/tooltip.tsx","../src/components/shadcn-ui/sidebar.tsx","../src/components/advanced/settings-components/settings-sidebar.component.tsx","../src/components/advanced/settings-components/settings-sidebar-content-search.component.tsx","../src/components/advanced/scripture-results-viewer/scripture-results-viewer.component.tsx","../src/components/advanced/scroll-group-selector.component.tsx","../src/components/advanced/settings-components/settings-list.component.tsx","../src/components/basics/checklist.component.tsx","../../../node_modules/@babel/runtime/helpers/interopRequireDefault.js","../../../node_modules/@mui/utils/chainPropTypes/chainPropTypes.js","../../../node_modules/@babel/runtime/helpers/esm/extends.js","../../../node_modules/@mui/utils/deepmerge/deepmerge.js","../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.production.min.js","../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.development.js","../../../node_modules/prop-types/node_modules/react-is/index.js","../../../node_modules/object-assign/index.js","../../../node_modules/prop-types/lib/ReactPropTypesSecret.js","../../../node_modules/prop-types/lib/has.js","../../../node_modules/prop-types/checkPropTypes.js","../../../node_modules/prop-types/factoryWithTypeCheckers.js","../../../node_modules/prop-types/factoryWithThrowingShims.js","../../../node_modules/prop-types/index.js","../../../node_modules/@mui/utils/elementAcceptingRef/elementAcceptingRef.js","../../../node_modules/@mui/utils/exactProp/exactProp.js","../../../node_modules/@mui/utils/formatMuiErrorMessage/formatMuiErrorMessage.js","../../../node_modules/react-is/cjs/react-is.production.min.js","../../../node_modules/react-is/cjs/react-is.development.js","../../../node_modules/react-is/index.js","../../../node_modules/@mui/utils/getDisplayName/getDisplayName.js","../../../node_modules/@mui/utils/HTMLElementType/HTMLElementType.js","../../../node_modules/@mui/utils/refType/refType.js","../../../node_modules/@mui/utils/capitalize/capitalize.js","../../../node_modules/@mui/utils/createChainedFunction/createChainedFunction.js","../../../node_modules/@mui/utils/debounce/debounce.js","../../../node_modules/@mui/utils/deprecatedPropType/deprecatedPropType.js","../../../node_modules/@mui/utils/isMuiElement/isMuiElement.js","../../../node_modules/@mui/utils/ownerDocument/ownerDocument.js","../../../node_modules/@mui/utils/ownerWindow/ownerWindow.js","../../../node_modules/@mui/utils/requirePropFactory/requirePropFactory.js","../../../node_modules/@mui/utils/setRef/setRef.js","../../../node_modules/@mui/utils/useEnhancedEffect/useEnhancedEffect.js","../../../node_modules/@mui/utils/useId/useId.js","../../../node_modules/@mui/utils/unsupportedProp/unsupportedProp.js","../../../node_modules/@mui/utils/useControlled/useControlled.js","../../../node_modules/@mui/utils/useEventCallback/useEventCallback.js","../../../node_modules/@mui/utils/useForkRef/useForkRef.js","../../../node_modules/@mui/utils/useLazyRef/useLazyRef.js","../../../node_modules/@mui/utils/useOnMount/useOnMount.js","../../../node_modules/@mui/utils/useTimeout/useTimeout.js","../../../node_modules/@mui/utils/useIsFocusVisible/useIsFocusVisible.js","../../../node_modules/@mui/utils/resolveProps/resolveProps.js","../../../node_modules/@mui/utils/composeClasses/composeClasses.js","../../../node_modules/@mui/utils/ClassNameGenerator/ClassNameGenerator.js","../../../node_modules/@mui/utils/generateUtilityClass/generateUtilityClass.js","../../../node_modules/@mui/utils/generateUtilityClasses/generateUtilityClasses.js","../../../node_modules/@mui/utils/clamp/clamp.js","../../../node_modules/@babel/runtime/helpers/esm/objectWithoutPropertiesLoose.js","../../../node_modules/@mui/system/esm/createTheme/createBreakpoints.js","../../../node_modules/@mui/system/esm/createTheme/shape.js","../../../node_modules/@mui/system/esm/responsivePropType.js","../../../node_modules/@mui/system/esm/merge.js","../../../node_modules/@mui/system/esm/breakpoints.js","../../../node_modules/@mui/system/esm/style.js","../../../node_modules/@mui/system/esm/memoize.js","../../../node_modules/@mui/system/esm/spacing.js","../../../node_modules/@mui/system/esm/createTheme/createSpacing.js","../../../node_modules/@mui/system/esm/compose.js","../../../node_modules/@mui/system/esm/borders.js","../../../node_modules/@mui/system/esm/cssGrid.js","../../../node_modules/@mui/system/esm/palette.js","../../../node_modules/@mui/system/esm/sizing.js","../../../node_modules/@mui/system/esm/styleFunctionSx/defaultSxConfig.js","../../../node_modules/@mui/system/esm/styleFunctionSx/styleFunctionSx.js","../../../node_modules/@mui/system/esm/createTheme/applyStyles.js","../../../node_modules/@mui/system/esm/createTheme/createTheme.js","../../../node_modules/@mui/system/esm/useThemeWithoutDefault.js","../../../node_modules/@mui/system/esm/useTheme.js","../../../node_modules/@mui/system/esm/createStyled.js","../../../node_modules/@mui/system/esm/useThemeProps/getThemeProps.js","../../../node_modules/@mui/system/esm/useThemeProps/useThemeProps.js","../../../node_modules/@mui/system/esm/colorManipulator.js","../../../node_modules/@mui/material/styles/createMixins.js","../../../node_modules/@mui/material/colors/common.js","../../../node_modules/@mui/material/colors/grey.js","../../../node_modules/@mui/material/colors/purple.js","../../../node_modules/@mui/material/colors/red.js","../../../node_modules/@mui/material/colors/orange.js","../../../node_modules/@mui/material/colors/blue.js","../../../node_modules/@mui/material/colors/lightBlue.js","../../../node_modules/@mui/material/colors/green.js","../../../node_modules/@mui/material/styles/createPalette.js","../../../node_modules/@mui/material/styles/createTypography.js","../../../node_modules/@mui/material/styles/shadows.js","../../../node_modules/@mui/material/styles/createTransitions.js","../../../node_modules/@mui/material/styles/zIndex.js","../../../node_modules/@mui/material/styles/createTheme.js","../../../node_modules/@mui/material/styles/defaultTheme.js","../../../node_modules/@mui/material/styles/identifier.js","../../../node_modules/@mui/material/styles/useThemeProps.js","../../../node_modules/@mui/material/styles/styled.js","../../../node_modules/@mui/material/SvgIcon/svgIconClasses.js","../../../node_modules/@mui/material/SvgIcon/SvgIcon.js","../../../node_modules/@mui/material/utils/createSvgIcon.js","../../../node_modules/@mui/material/utils/index.js","../../../node_modules/@mui/icons-material/utils/createSvgIcon.js","../../../node_modules/@mui/icons-material/ArrowRight.js","../../../node_modules/@mui/base/utils/isHostComponent.js","../../../node_modules/@mui/base/utils/appendOwnerState.js","../../../node_modules/@mui/base/utils/ClassNameConfigurator.js","../../../node_modules/@mui/base/utils/extractEventHandlers.js","../../../node_modules/@mui/base/utils/resolveComponentProps.js","../../../node_modules/@mui/base/utils/omitEventHandlers.js","../../../node_modules/@mui/base/utils/mergeSlotProps.js","../../../node_modules/@mui/base/utils/useSlotProps.js","../../../node_modules/@mui/base/generateUtilityClass/index.js","../../../node_modules/@mui/base/generateUtilityClasses/index.js","../../../node_modules/@mui/base/Portal/Portal.js","../../../node_modules/@popperjs/core/lib/enums.js","../../../node_modules/@popperjs/core/lib/dom-utils/getNodeName.js","../../../node_modules/@popperjs/core/lib/dom-utils/getWindow.js","../../../node_modules/@popperjs/core/lib/dom-utils/instanceOf.js","../../../node_modules/@popperjs/core/lib/modifiers/applyStyles.js","../../../node_modules/@popperjs/core/lib/utils/getBasePlacement.js","../../../node_modules/@popperjs/core/lib/utils/math.js","../../../node_modules/@popperjs/core/lib/utils/userAgent.js","../../../node_modules/@popperjs/core/lib/dom-utils/isLayoutViewport.js","../../../node_modules/@popperjs/core/lib/dom-utils/getBoundingClientRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/getLayoutRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/contains.js","../../../node_modules/@popperjs/core/lib/dom-utils/getComputedStyle.js","../../../node_modules/@popperjs/core/lib/dom-utils/isTableElement.js","../../../node_modules/@popperjs/core/lib/dom-utils/getDocumentElement.js","../../../node_modules/@popperjs/core/lib/dom-utils/getParentNode.js","../../../node_modules/@popperjs/core/lib/dom-utils/getOffsetParent.js","../../../node_modules/@popperjs/core/lib/utils/getMainAxisFromPlacement.js","../../../node_modules/@popperjs/core/lib/utils/within.js","../../../node_modules/@popperjs/core/lib/utils/getFreshSideObject.js","../../../node_modules/@popperjs/core/lib/utils/mergePaddingObject.js","../../../node_modules/@popperjs/core/lib/utils/expandToHashMap.js","../../../node_modules/@popperjs/core/lib/modifiers/arrow.js","../../../node_modules/@popperjs/core/lib/utils/getVariation.js","../../../node_modules/@popperjs/core/lib/modifiers/computeStyles.js","../../../node_modules/@popperjs/core/lib/modifiers/eventListeners.js","../../../node_modules/@popperjs/core/lib/utils/getOppositePlacement.js","../../../node_modules/@popperjs/core/lib/utils/getOppositeVariationPlacement.js","../../../node_modules/@popperjs/core/lib/dom-utils/getWindowScroll.js","../../../node_modules/@popperjs/core/lib/dom-utils/getWindowScrollBarX.js","../../../node_modules/@popperjs/core/lib/dom-utils/getViewportRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/getDocumentRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/isScrollParent.js","../../../node_modules/@popperjs/core/lib/dom-utils/getScrollParent.js","../../../node_modules/@popperjs/core/lib/dom-utils/listScrollParents.js","../../../node_modules/@popperjs/core/lib/utils/rectToClientRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/getClippingRect.js","../../../node_modules/@popperjs/core/lib/utils/computeOffsets.js","../../../node_modules/@popperjs/core/lib/utils/detectOverflow.js","../../../node_modules/@popperjs/core/lib/utils/computeAutoPlacement.js","../../../node_modules/@popperjs/core/lib/modifiers/flip.js","../../../node_modules/@popperjs/core/lib/modifiers/hide.js","../../../node_modules/@popperjs/core/lib/modifiers/offset.js","../../../node_modules/@popperjs/core/lib/modifiers/popperOffsets.js","../../../node_modules/@popperjs/core/lib/utils/getAltAxis.js","../../../node_modules/@popperjs/core/lib/modifiers/preventOverflow.js","../../../node_modules/@popperjs/core/lib/dom-utils/getHTMLElementScroll.js","../../../node_modules/@popperjs/core/lib/dom-utils/getNodeScroll.js","../../../node_modules/@popperjs/core/lib/dom-utils/getCompositeRect.js","../../../node_modules/@popperjs/core/lib/utils/orderModifiers.js","../../../node_modules/@popperjs/core/lib/utils/debounce.js","../../../node_modules/@popperjs/core/lib/utils/mergeByName.js","../../../node_modules/@popperjs/core/lib/createPopper.js","../../../node_modules/@popperjs/core/lib/popper.js","../../../node_modules/@mui/base/Popper/popperClasses.js","../../../node_modules/@mui/base/Popper/Popper.js","../../../node_modules/@mui/material/styles/useTheme.js","../../../node_modules/@babel/runtime/helpers/esm/setPrototypeOf.js","../../../node_modules/@babel/runtime/helpers/esm/inheritsLoose.js","../../../node_modules/react-transition-group/esm/config.js","../../../node_modules/react-transition-group/esm/utils/PropTypes.js","../../../node_modules/react-transition-group/esm/TransitionGroupContext.js","../../../node_modules/react-transition-group/esm/utils/reflow.js","../../../node_modules/react-transition-group/esm/Transition.js","../../../node_modules/@mui/material/transitions/utils.js","../../../node_modules/@mui/material/Grow/Grow.js","../../../node_modules/@mui/material/Popper/Popper.js","../../../node_modules/@mui/material/Tooltip/tooltipClasses.js","../../../node_modules/@mui/material/Tooltip/Tooltip.js","../src/components/mui/menu-item.component.tsx","../src/components/mui/grouped-menu-item-list.component.tsx","../src/components/mui/top-level-menu.component.tsx","../src/components/mui/grid-menu.component.tsx","../src/hooks/use-promise.hook.ts","../../../node_modules/@mui/icons-material/esm/Menu.js","../src/components/mui/hamburger-menu-button.component.tsx","../src/components/mui/icon-button.component.tsx","../src/components/basics/spinner.component.tsx","../src/components/basics/text-field.component.tsx","../src/components/mui/toolbar.component.tsx","../src/components/shadcn-ui/alert.tsx","../src/components/shadcn-ui/card.tsx","../src/components/shadcn-ui/sonner.tsx","../src/components/shadcn-ui/slider.tsx","../src/components/shadcn-ui/switch.tsx","../src/components/shadcn-ui/tabs.tsx","../src/components/advanced/extension-marketplace/buttons/install-button.component.tsx","../src/components/advanced/extension-marketplace/buttons/enable-button.component.tsx","../src/components/advanced/extension-marketplace/buttons/disable-button.component.tsx","../src/components/advanced/extension-marketplace/buttons/update-button.component.tsx","../src/components/advanced/extension-marketplace/markdown-renderer.component.tsx","../src/components/advanced/extension-marketplace/buttons/filter-button.component.tsx","../src/components/advanced/extension-marketplace/filter-dropdown.component.tsx","../src/components/advanced/extension-marketplace/no-extensions-found.component.tsx","../src/components/advanced/extension-marketplace/more-info.component.tsx","../src/components/advanced/extension-marketplace/version-history.component.tsx","../src/components/advanced/extension-marketplace/footer.component.tsx","../src/hooks/use-event.hook.ts","../src/hooks/use-event-async.hook.ts"],"sourcesContent":["import { type ClassValue, clsx } from 'clsx';\nimport { extendTailwindMerge } from 'tailwind-merge';\n\nconst twMergeCustom = extendTailwindMerge({ prefix: 'tw-' });\n\n/**\n * Tailwind and CSS class application helper function. Uses\n * [`clsx`](https://www.npmjs.com/package/clsx) to make it easy to apply classes conditionally using\n * object syntax, and uses [`tailwind-merge`](https://www.npmjs.com/package/tailwind-merge) to make\n * it easy to merge/overwrite Tailwind classes in a programmer-logic-friendly way.\n *\n * Note: `tailwind-merge` is configured to use the prefix `tw-`, so you must use the same prefix\n * with any Tailwind classes you use with this function to successfully overwrite other Tailwind\n * classes. `platform-bible-react` is configured to use `tw-` as its Tailwind prefix, so any\n * Tailwind classes you pass into `platform-bible-react` components will be compared using the `tw-`\n * prefix.\n *\n * This function was popularized by\n * [shadcn/ui](https://ui.shadcn.com/docs/installation/manual#add-a-cn-helper). See [ByteGrad's\n * explanation video](https://www.youtube.com/watch?v=re2JFITR7TI) for more information.\n *\n * @example\n *\n * ```typescript\n * const borderShouldBeBlue = true;\n * const textShouldBeRed = true;\n * const heightShouldBe20 = false;\n * const classString = cn(\n * 'tw-bg-primary tw-h-10 tw-text-primary-foreground',\n * 'tw-bg-secondary',\n * {\n * 'tw-border-blue-500': borderShouldBeBlue,\n * 'tw-text-red-500': textShouldBeRed,\n * 'tw-h-20': heightShouldBe20,\n * },\n * 'some-class',\n * );\n * ```\n *\n * The resulting `classString` is `'tw-h-10 tw-bg-secondary tw-border-blue-500 tw-text-red-500\n * some-class'`\n *\n * - Notice that `'tw-bg-secondary'`, specified later, overwrote `'tw-bg-primary'`, specified earlier,\n * because they are Tailwind classes that affect the same css property\n * - Notice that `'tw-text-red-500'`, specified later, overwrote `'tw-text-primary-foreground'`,\n * specified earlier, because they are Tailwind classes that affect the same css property\n * - Notice that `'tw-h-20'`, specified later, did not overwrite `'tw-h-10'`, specified earlier,\n * because `'tw-h-20'` is part of a conditional class object and its value evaluated to `false`;\n * therefore it was not applied\n * - Notice that `'some-class'` was applied. This function is not limited only to Tailwind classes.\n *\n *\n * @param inputs Class strings or `clsx` conditional class objects to merge. Tailwind classes\n * specified later in the arguments overwrite similar Tailwind classes specified earlier in the\n * arguments\n * @returns Class string containing all applicable classes from the arguments based on the rules\n * described above\n */\n// shadcn/ui uses this export in its boilerplate code\n// eslint-disable-next-line import/prefer-default-export\nexport function cn(...inputs: ClassValue[]) {\n return twMergeCustom(clsx(inputs));\n}\n","import React from 'react';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport interface InputProps extends React.InputHTMLAttributes {}\n\nexport const Input = React.forwardRef(\n ({ className, type, ...props }, ref) => {\n return (\n \n );\n },\n);\nInput.displayName = 'Input';\n","import { FocusEventHandler, forwardRef, KeyboardEvent, MouseEventHandler } from 'react';\nimport { History } from 'lucide-react';\nimport { Input as ShadInput } from '@/components/shadcn-ui/input';\n\nexport type BookChapterInputProps = {\n handleSearch: (searchString: string) => void;\n handleKeyDown: (event: KeyboardEvent) => void;\n handleOnClick: MouseEventHandler;\n handleSubmit: () => void;\n onFocus?: FocusEventHandler;\n value: string;\n placeholder: string;\n};\n\n// Shadcn Input sets type to \"button\"- HAVE to prop spread before setting type\nconst BookChapterInput = forwardRef(\n (\n { handleSearch, handleKeyDown, handleOnClick, handleSubmit, ...props }: BookChapterInputProps,\n ref,\n ) => {\n return (\n
    \n handleSearch(event.target.value)}\n onKeyDown={(e) => {\n if (e.key === 'Enter') {\n handleSubmit();\n }\n handleKeyDown(e);\n }}\n onClick={handleOnClick}\n ref={ref}\n />\n {\n // eslint-disable-next-line no-console\n console.log('back in history');\n }}\n />\n
    \n );\n },\n);\n\nexport default BookChapterInput;\n","var P = Object.defineProperty;\nvar R = (t, e, s) => e in t ? P(t, e, { enumerable: !0, configurable: !0, writable: !0, value: s }) : t[e] = s;\nvar n = (t, e, s) => R(t, typeof e != \"symbol\" ? e + \"\" : e, s);\nclass _ {\n constructor() {\n n(this, \"books\");\n n(this, \"firstSelectedBookNum\");\n n(this, \"lastSelectedBookNum\");\n n(this, \"count\");\n n(this, \"selectedBookNumbers\");\n n(this, \"selectedBookIds\");\n }\n}\nconst N = [\n \"GEN\",\n \"EXO\",\n \"LEV\",\n \"NUM\",\n \"DEU\",\n \"JOS\",\n \"JDG\",\n \"RUT\",\n \"1SA\",\n \"2SA\",\n // 10\n \"1KI\",\n \"2KI\",\n \"1CH\",\n \"2CH\",\n \"EZR\",\n \"NEH\",\n \"EST\",\n \"JOB\",\n \"PSA\",\n \"PRO\",\n // 20\n \"ECC\",\n \"SNG\",\n \"ISA\",\n \"JER\",\n \"LAM\",\n \"EZK\",\n \"DAN\",\n \"HOS\",\n \"JOL\",\n \"AMO\",\n // 30\n \"OBA\",\n \"JON\",\n \"MIC\",\n \"NAM\",\n \"HAB\",\n \"ZEP\",\n \"HAG\",\n \"ZEC\",\n \"MAL\",\n \"MAT\",\n // 40\n \"MRK\",\n \"LUK\",\n \"JHN\",\n \"ACT\",\n \"ROM\",\n \"1CO\",\n \"2CO\",\n \"GAL\",\n \"EPH\",\n \"PHP\",\n // 50\n \"COL\",\n \"1TH\",\n \"2TH\",\n \"1TI\",\n \"2TI\",\n \"TIT\",\n \"PHM\",\n \"HEB\",\n \"JAS\",\n \"1PE\",\n // 60\n \"2PE\",\n \"1JN\",\n \"2JN\",\n \"3JN\",\n \"JUD\",\n \"REV\",\n \"TOB\",\n \"JDT\",\n \"ESG\",\n \"WIS\",\n // 70\n \"SIR\",\n \"BAR\",\n \"LJE\",\n \"S3Y\",\n \"SUS\",\n \"BEL\",\n \"1MA\",\n \"2MA\",\n \"3MA\",\n \"4MA\",\n // 80\n \"1ES\",\n \"2ES\",\n \"MAN\",\n \"PS2\",\n \"ODA\",\n \"PSS\",\n \"JSA\",\n // actual variant text for JOS, now in LXA text\n \"JDB\",\n // actual variant text for JDG, now in LXA text\n \"TBS\",\n // actual variant text for TOB, now in LXA text\n \"SST\",\n // actual variant text for SUS, now in LXA text // 90\n \"DNT\",\n // actual variant text for DAN, now in LXA text\n \"BLT\",\n // actual variant text for BEL, now in LXA text\n \"XXA\",\n \"XXB\",\n \"XXC\",\n \"XXD\",\n \"XXE\",\n \"XXF\",\n \"XXG\",\n \"FRT\",\n // 100\n \"BAK\",\n \"OTH\",\n \"3ES\",\n // Used previously but really should be 2ES\n \"EZA\",\n // Used to be called 4ES, but not actually in any known project\n \"5EZ\",\n // Used to be called 5ES, but not actually in any known project\n \"6EZ\",\n // Used to be called 6ES, but not actually in any known project\n \"INT\",\n \"CNC\",\n \"GLO\",\n \"TDX\",\n // 110\n \"NDX\",\n \"DAG\",\n \"PS3\",\n \"2BA\",\n \"LBA\",\n \"JUB\",\n \"ENO\",\n \"1MQ\",\n \"2MQ\",\n \"3MQ\",\n // 120\n \"REP\",\n \"4BA\",\n \"LAO\"\n], B = [\n \"XXA\",\n \"XXB\",\n \"XXC\",\n \"XXD\",\n \"XXE\",\n \"XXF\",\n \"XXG\",\n \"FRT\",\n \"BAK\",\n \"OTH\",\n \"INT\",\n \"CNC\",\n \"GLO\",\n \"TDX\",\n \"NDX\"\n], O = [\n \"Genesis\",\n \"Exodus\",\n \"Leviticus\",\n \"Numbers\",\n \"Deuteronomy\",\n \"Joshua\",\n \"Judges\",\n \"Ruth\",\n \"1 Samuel\",\n \"2 Samuel\",\n \"1 Kings\",\n \"2 Kings\",\n \"1 Chronicles\",\n \"2 Chronicles\",\n \"Ezra\",\n \"Nehemiah\",\n \"Esther (Hebrew)\",\n \"Job\",\n \"Psalms\",\n \"Proverbs\",\n \"Ecclesiastes\",\n \"Song of Songs\",\n \"Isaiah\",\n \"Jeremiah\",\n \"Lamentations\",\n \"Ezekiel\",\n \"Daniel (Hebrew)\",\n \"Hosea\",\n \"Joel\",\n \"Amos\",\n \"Obadiah\",\n \"Jonah\",\n \"Micah\",\n \"Nahum\",\n \"Habakkuk\",\n \"Zephaniah\",\n \"Haggai\",\n \"Zechariah\",\n \"Malachi\",\n \"Matthew\",\n \"Mark\",\n \"Luke\",\n \"John\",\n \"Acts\",\n \"Romans\",\n \"1 Corinthians\",\n \"2 Corinthians\",\n \"Galatians\",\n \"Ephesians\",\n \"Philippians\",\n \"Colossians\",\n \"1 Thessalonians\",\n \"2 Thessalonians\",\n \"1 Timothy\",\n \"2 Timothy\",\n \"Titus\",\n \"Philemon\",\n \"Hebrews\",\n \"James\",\n \"1 Peter\",\n \"2 Peter\",\n \"1 John\",\n \"2 John\",\n \"3 John\",\n \"Jude\",\n \"Revelation\",\n \"Tobit\",\n \"Judith\",\n \"Esther Greek\",\n \"Wisdom of Solomon\",\n \"Sirach (Ecclesiasticus)\",\n \"Baruch\",\n \"Letter of Jeremiah\",\n \"Song of 3 Young Men\",\n \"Susanna\",\n \"Bel and the Dragon\",\n \"1 Maccabees\",\n \"2 Maccabees\",\n \"3 Maccabees\",\n \"4 Maccabees\",\n \"1 Esdras (Greek)\",\n \"2 Esdras (Latin)\",\n \"Prayer of Manasseh\",\n \"Psalm 151\",\n \"Odes\",\n \"Psalms of Solomon\",\n // WARNING, if you change the spelling of the *obsolete* tag be sure to update\n // IsObsolete routine\n \"Joshua A. *obsolete*\",\n \"Judges B. *obsolete*\",\n \"Tobit S. *obsolete*\",\n \"Susanna Th. *obsolete*\",\n \"Daniel Th. *obsolete*\",\n \"Bel Th. *obsolete*\",\n \"Extra A\",\n \"Extra B\",\n \"Extra C\",\n \"Extra D\",\n \"Extra E\",\n \"Extra F\",\n \"Extra G\",\n \"Front Matter\",\n \"Back Matter\",\n \"Other Matter\",\n \"3 Ezra *obsolete*\",\n \"Apocalypse of Ezra\",\n \"5 Ezra (Latin Prologue)\",\n \"6 Ezra (Latin Epilogue)\",\n \"Introduction\",\n \"Concordance \",\n \"Glossary \",\n \"Topical Index\",\n \"Names Index\",\n \"Daniel Greek\",\n \"Psalms 152-155\",\n \"2 Baruch (Apocalypse)\",\n \"Letter of Baruch\",\n \"Jubilees\",\n \"Enoch\",\n \"1 Meqabyan\",\n \"2 Meqabyan\",\n \"3 Meqabyan\",\n \"Reproof (Proverbs 25-31)\",\n \"4 Baruch (Rest of Baruch)\",\n \"Laodiceans\"\n], S = K();\nfunction g(t, e = !0) {\n return e && (t = t.toUpperCase()), t in S ? S[t] : 0;\n}\nfunction k(t) {\n return g(t) > 0;\n}\nfunction x(t) {\n const e = typeof t == \"string\" ? g(t) : t;\n return e >= 40 && e <= 66;\n}\nfunction T(t) {\n return (typeof t == \"string\" ? g(t) : t) <= 39;\n}\nfunction X(t) {\n return t <= 66;\n}\nfunction V(t) {\n const e = typeof t == \"string\" ? g(t) : t;\n return w(e) && !X(e);\n}\nfunction* L() {\n for (let t = 1; t <= N.length; t++) yield t;\n}\nconst G = 1, A = N.length;\nfunction H() {\n return [\"XXA\", \"XXB\", \"XXC\", \"XXD\", \"XXE\", \"XXF\", \"XXG\"];\n}\nfunction C(t, e = \"***\") {\n const s = t - 1;\n return s < 0 || s >= N.length ? e : N[s];\n}\nfunction I(t) {\n return t <= 0 || t > A ? \"******\" : O[t - 1];\n}\nfunction y(t) {\n return I(g(t));\n}\nfunction w(t) {\n const e = typeof t == \"number\" ? C(t) : t;\n return k(e) && !B.includes(e);\n}\nfunction q(t) {\n const e = typeof t == \"number\" ? C(t) : t;\n return k(e) && B.includes(e);\n}\nfunction U(t) {\n return O[t - 1].includes(\"*obsolete*\");\n}\nfunction K() {\n const t = {};\n for (let e = 0; e < N.length; e++)\n t[N[e]] = e + 1;\n return t;\n}\nconst m = {\n allBookIds: N,\n nonCanonicalIds: B,\n bookIdToNumber: g,\n isBookIdValid: k,\n isBookNT: x,\n isBookOT: T,\n isBookOTNT: X,\n isBookDC: V,\n allBookNumbers: L,\n firstBook: G,\n lastBook: A,\n extraBooks: H,\n bookNumberToId: C,\n bookNumberToEnglishName: I,\n bookIdToEnglishName: y,\n isCanonical: w,\n isExtraMaterial: q,\n isObsolete: U\n};\nvar l = /* @__PURE__ */ ((t) => (t[t.Unknown = 0] = \"Unknown\", t[t.Original = 1] = \"Original\", t[t.Septuagint = 2] = \"Septuagint\", t[t.Vulgate = 3] = \"Vulgate\", t[t.English = 4] = \"English\", t[t.RussianProtestant = 5] = \"RussianProtestant\", t[t.RussianOrthodox = 6] = \"RussianOrthodox\", t))(l || {});\nconst h = class h {\n // private versInfo: Versification;\n constructor(e) {\n n(this, \"name\");\n n(this, \"fullPath\");\n n(this, \"isPresent\");\n n(this, \"hasVerseSegments\");\n n(this, \"isCustomized\");\n n(this, \"baseVersification\");\n n(this, \"scriptureBooks\");\n n(this, \"_type\");\n if (e == null)\n throw new Error(\"Argument undefined\");\n typeof e == \"string\" ? (this.name = e, this._type = l[e]) : (this._type = e, this.name = l[e]);\n }\n get type() {\n return this._type;\n }\n equals(e) {\n return !e.type || !this.type ? !1 : e.type === this.type;\n }\n};\nn(h, \"Original\", new h(l.Original)), n(h, \"Septuagint\", new h(l.Septuagint)), n(h, \"Vulgate\", new h(l.Vulgate)), n(h, \"English\", new h(l.English)), n(h, \"RussianProtestant\", new h(l.RussianProtestant)), n(h, \"RussianOrthodox\", new h(l.RussianOrthodox));\nlet c = h;\nfunction E(t, e) {\n const s = e[0];\n for (let r = 1; r < e.length; r++)\n t = t.split(e[r]).join(s);\n return t.split(s);\n}\nvar D = /* @__PURE__ */ ((t) => (t[t.Valid = 0] = \"Valid\", t[t.UnknownVersification = 1] = \"UnknownVersification\", t[t.OutOfRange = 2] = \"OutOfRange\", t[t.VerseOutOfOrder = 3] = \"VerseOutOfOrder\", t[t.VerseRepeated = 4] = \"VerseRepeated\", t))(D || {});\nconst i = class i {\n constructor(e, s, r, a) {\n /** Not yet implemented. */\n n(this, \"firstChapter\");\n /** Not yet implemented. */\n n(this, \"lastChapter\");\n /** Not yet implemented. */\n n(this, \"lastVerse\");\n /** Not yet implemented. */\n n(this, \"hasSegmentsDefined\");\n /** Not yet implemented. */\n n(this, \"text\");\n /** Not yet implemented. */\n n(this, \"BBBCCCVVVS\");\n /** Not yet implemented. */\n n(this, \"longHashCode\");\n /** The versification of the reference. */\n n(this, \"versification\");\n n(this, \"rtlMark\", \"‏\");\n n(this, \"_bookNum\", 0);\n n(this, \"_chapterNum\", 0);\n n(this, \"_verseNum\", 0);\n n(this, \"_verse\");\n if (r == null && a == null)\n if (e != null && typeof e == \"string\") {\n const o = e, u = s != null && s instanceof c ? s : void 0;\n this.setEmpty(u), this.parse(o);\n } else if (e != null && typeof e == \"number\") {\n const o = s != null && s instanceof c ? s : void 0;\n this.setEmpty(o), this._verseNum = e % i.chapterDigitShifter, this._chapterNum = Math.floor(\n e % i.bookDigitShifter / i.chapterDigitShifter\n ), this._bookNum = Math.floor(e / i.bookDigitShifter);\n } else if (s == null)\n if (e != null && e instanceof i) {\n const o = e;\n this._bookNum = o.bookNum, this._chapterNum = o.chapterNum, this._verseNum = o.verseNum, this._verse = o.verse, this.versification = o.versification;\n } else {\n if (e == null) return;\n const o = e instanceof c ? e : i.defaultVersification;\n this.setEmpty(o);\n }\n else\n throw new Error(\"VerseRef constructor not supported.\");\n else if (e != null && s != null && r != null)\n if (typeof e == \"string\" && typeof s == \"string\" && typeof r == \"string\")\n this.setEmpty(a), this.updateInternal(e, s, r);\n else if (typeof e == \"number\" && typeof s == \"number\" && typeof r == \"number\")\n this._bookNum = e, this._chapterNum = s, this._verseNum = r, this.versification = a ?? i.defaultVersification;\n else\n throw new Error(\"VerseRef constructor not supported.\");\n else\n throw new Error(\"VerseRef constructor not supported.\");\n }\n /**\n * Determines if the verse string is in a valid format (does not consider versification).\n */\n static isVerseParseable(e) {\n return e.length > 0 && \"0123456789\".includes(e[0]) && !e.endsWith(this.verseRangeSeparator) && !e.endsWith(this.verseSequenceIndicator);\n }\n /**\n * Tries to parse the specified string into a verse reference.\n * @param str - The string to attempt to parse.\n * @returns success: `true` if the specified string was successfully parsed, `false` otherwise.\n * @returns verseRef: The result of the parse if successful, or empty VerseRef if it failed\n */\n static tryParse(e) {\n let s;\n try {\n return s = new i(e), { success: !0, verseRef: s };\n } catch (r) {\n if (r instanceof v)\n return s = new i(), { success: !1, verseRef: s };\n throw r;\n }\n }\n /**\n * Gets the reference as a comparable integer where the book, chapter, and verse each occupy 3\n * digits.\n * @param bookNum - Book number (this is 1-based, not an index).\n * @param chapterNum - Chapter number.\n * @param verseNum - Verse number.\n * @returns The reference as a comparable integer where the book, chapter, and verse each occupy 3\n * digits.\n */\n static getBBBCCCVVV(e, s, r) {\n return e % i.bcvMaxValue * i.bookDigitShifter + (s >= 0 ? s % i.bcvMaxValue * i.chapterDigitShifter : 0) + (r >= 0 ? r % i.bcvMaxValue : 0);\n }\n /**\n * Deserializes a serialized VerseRef.\n * @param serializedVerseRef - Serialized VerseRef to create from.\n * @returns the deserialized VerseRef.\n */\n static fromJSON(e) {\n const { book: s, chapterNum: r, verseNum: a, verse: o, versificationStr: u } = e, f = o || a.toString();\n let d;\n return u && (d = new c(u)), s ? new i(s, r.toString(), f, d) : new i();\n }\n /**\n * Parses a verse string and gets the leading numeric portion as a number.\n * @param verseStr - verse string to parse\n * @returns true if the entire string could be parsed as a single, simple verse number (1-999);\n * false if the verse string represented a verse bridge, contained segment letters, or was invalid\n */\n static tryGetVerseNum(e) {\n let s;\n if (!e)\n return s = -1, { success: !0, vNum: s };\n s = 0;\n let r;\n for (let a = 0; a < e.length; a++) {\n if (r = e[a], r < \"0\" || r > \"9\")\n return a === 0 && (s = -1), { success: !1, vNum: s };\n if (s = s * 10 + +r - 0, s > i.bcvMaxValue)\n return s = -1, { success: !1, vNum: s };\n }\n return { success: !0, vNum: s };\n }\n /**\n * Checks to see if a VerseRef hasn't been set - all values are the default.\n */\n get isDefault() {\n return this.bookNum === 0 && this.chapterNum === 0 && this.verseNum === 0 && this.versification == null;\n }\n /**\n * Gets whether the verse contains multiple verses.\n */\n get hasMultiple() {\n return this._verse != null && (this._verse.includes(i.verseRangeSeparator) || this._verse.includes(i.verseSequenceIndicator));\n }\n /**\n * Gets or sets the book of the reference. Book is the 3-letter abbreviation in capital letters,\n * e.g. `'MAT'`.\n */\n get book() {\n return m.bookNumberToId(this.bookNum, \"\");\n }\n set book(e) {\n this.bookNum = m.bookIdToNumber(e);\n }\n /**\n * Gets or sets the chapter of the reference,. e.g. `'3'`.\n */\n get chapter() {\n return this.isDefault || this._chapterNum < 0 ? \"\" : this._chapterNum.toString();\n }\n set chapter(e) {\n const s = +e;\n this._chapterNum = Number.isInteger(s) ? s : -1;\n }\n /**\n * Gets or sets the verse of the reference, including range, segments, and sequences, e.g. `'4'`,\n * or `'4b-5a, 7'`.\n */\n get verse() {\n return this._verse != null ? this._verse : this.isDefault || this._verseNum < 0 ? \"\" : this._verseNum.toString();\n }\n set verse(e) {\n const { success: s, vNum: r } = i.tryGetVerseNum(e);\n this._verse = s ? void 0 : e.replace(this.rtlMark, \"\"), this._verseNum = r, !(this._verseNum >= 0) && ({ vNum: this._verseNum } = i.tryGetVerseNum(this._verse));\n }\n /**\n * Get or set Book based on book number, e.g. `42`.\n */\n get bookNum() {\n return this._bookNum;\n }\n set bookNum(e) {\n if (e <= 0 || e > m.lastBook)\n throw new v(\n \"BookNum must be greater than zero and less than or equal to last book\"\n );\n this._bookNum = e;\n }\n /**\n * Gets or sets the chapter number, e.g. `3`. `-1` if not valid.\n */\n get chapterNum() {\n return this._chapterNum;\n }\n set chapterNum(e) {\n this.chapterNum = e;\n }\n /**\n * Gets or sets verse start number, e.g. `4`. `-1` if not valid.\n */\n get verseNum() {\n return this._verseNum;\n }\n set verseNum(e) {\n this._verseNum = e;\n }\n /**\n * String representing the versification (should ONLY be used for serialization/deserialization).\n *\n * @remarks This is for backwards compatibility when ScrVers was an enumeration.\n */\n get versificationStr() {\n var e;\n return (e = this.versification) == null ? void 0 : e.name;\n }\n set versificationStr(e) {\n this.versification = this.versification != null ? new c(e) : void 0;\n }\n /**\n * Determines if the reference is valid.\n */\n get valid() {\n return this.validStatus === 0;\n }\n /**\n * Get the valid status for this reference.\n */\n get validStatus() {\n return this.validateVerse(i.verseRangeSeparators, i.verseSequenceIndicators);\n }\n /**\n * Gets the reference as a comparable integer where the book,\n * chapter, and verse each occupy three digits and the verse is 0.\n */\n get BBBCCC() {\n return i.getBBBCCCVVV(this._bookNum, this._chapterNum, 0);\n }\n /**\n * Gets the reference as a comparable integer where the book,\n * chapter, and verse each occupy three digits. If verse is not null\n * (i.e., this reference represents a complex reference with verse\n * segments or bridge) this cannot be used for an exact comparison.\n */\n get BBBCCCVVV() {\n return i.getBBBCCCVVV(this._bookNum, this._chapterNum, this._verseNum);\n }\n /**\n * Gets whether the verse is defined as an excluded verse in the versification.\n * Does not handle verse ranges.\n */\n // eslint-disable-next-line @typescript-eslint/class-literal-property-style\n get isExcluded() {\n return !1;\n }\n /**\n * Parses the reference in the specified string.\n * Optionally versification can follow reference as in GEN 3:11/4\n * Throw an exception if\n * - invalid book name\n * - chapter number is missing or not a number\n * - verse number is missing or does not start with a number\n * - versification is invalid\n * @param verseStr - string to parse e.g. 'MAT 3:11'\n */\n parse(e) {\n if (e = e.replace(this.rtlMark, \"\"), e.includes(\"/\")) {\n const o = e.split(\"/\");\n if (e = o[0], o.length > 1)\n try {\n const u = +o[1].trim();\n this.versification = new c(l[u]);\n } catch {\n throw new v(\"Invalid reference : \" + e);\n }\n }\n const s = e.trim().split(\" \");\n if (s.length !== 2)\n throw new v(\"Invalid reference : \" + e);\n const r = s[1].split(\":\"), a = +r[0];\n if (r.length !== 2 || m.bookIdToNumber(s[0]) === 0 || !Number.isInteger(a) || a < 0 || !i.isVerseParseable(r[1]))\n throw new v(\"Invalid reference : \" + e);\n this.updateInternal(s[0], r[0], r[1]);\n }\n /**\n * Simplifies this verse ref so that it has no bridging of verses or\n * verse segments like `'1a'`.\n */\n simplify() {\n this._verse = void 0;\n }\n /**\n * Makes a clone of the reference.\n *\n * @returns The cloned VerseRef.\n */\n clone() {\n return new i(this);\n }\n toString() {\n const e = this.book;\n return e === \"\" ? \"\" : `${e} ${this.chapter}:${this.verse}`;\n }\n toJSON() {\n let e = this.verse;\n (e === \"\" || e === this.verseNum.toString()) && (e = void 0);\n const s = {\n book: this.book,\n chapterNum: this.chapterNum,\n verseNum: this.verseNum,\n verse: e,\n versificationStr: this.versificationStr\n };\n return e || delete s.verse, s;\n }\n /**\n * Compares this `VerseRef` with supplied one.\n * @param verseRef - object to compare this one to.\n * @returns `true` if this `VerseRef` is equal to the supplied one, `false` otherwise.\n */\n equals(e) {\n return e instanceof i ? e._bookNum === this._bookNum && e._chapterNum === this._chapterNum && e._verseNum === this._verseNum && e.verse === this.verse && (e.versification == null && this.versification == null || e.versification != null && this.versification != null && e.versification.equals(this.versification)) : !1;\n }\n /**\n * Enumerate all individual verses contained in a VerseRef.\n * Verse ranges are indicated by \"-\" and consecutive verses by \",\"s.\n * Examples:\n * GEN 1:2 returns GEN 1:2\n * GEN 1:1a-3b,5 returns GEN 1:1a, GEN 1:2, GEN 1:3b, GEN 1:5\n * GEN 1:2a-2c returns //! ??????\n *\n * @param specifiedVersesOnly - if set to true return only verses that are\n * explicitly specified only, not verses within a range. Defaults to `false`.\n * @param verseRangeSeparators - Verse range separators.\n * Defaults to `VerseRef.verseRangeSeparators`.\n * @param verseSequenceSeparators - Verse sequence separators.\n * Defaults to `VerseRef.verseSequenceIndicators`.\n * @returns An array of all single verse references in this VerseRef.\n */\n allVerses(e = !1, s = i.verseRangeSeparators, r = i.verseSequenceIndicators) {\n if (this._verse == null || this.chapterNum <= 0)\n return [this.clone()];\n const a = [], o = E(this._verse, r);\n for (const u of o.map((f) => E(f, s))) {\n const f = this.clone();\n f.verse = u[0];\n const d = f.verseNum;\n if (a.push(f), u.length > 1) {\n const b = this.clone();\n if (b.verse = u[1], !e)\n for (let p = d + 1; p < b.verseNum; p++) {\n const J = new i(\n this._bookNum,\n this._chapterNum,\n p,\n this.versification\n );\n this.isExcluded || a.push(J);\n }\n a.push(b);\n }\n }\n return a;\n }\n /**\n * Validates a verse number using the supplied separators rather than the defaults.\n */\n validateVerse(e, s) {\n if (!this.verse)\n return this.internalValid;\n let r = 0;\n for (const a of this.allVerses(!0, e, s)) {\n const o = a.internalValid;\n if (o !== 0)\n return o;\n const u = a.BBBCCCVVV;\n if (r > u)\n return 3;\n if (r === u)\n return 4;\n r = u;\n }\n return 0;\n }\n /**\n * Gets whether a single verse reference is valid.\n */\n get internalValid() {\n return this.versification == null ? 1 : this._bookNum <= 0 || this._bookNum > m.lastBook ? 2 : (m.isCanonical(this._bookNum), 0);\n }\n setEmpty(e = i.defaultVersification) {\n this._bookNum = 0, this._chapterNum = -1, this._verse = void 0, this.versification = e;\n }\n updateInternal(e, s, r) {\n this.bookNum = m.bookIdToNumber(e), this.chapter = s, this.verse = r;\n }\n};\nn(i, \"defaultVersification\", c.English), n(i, \"verseRangeSeparator\", \"-\"), n(i, \"verseSequenceIndicator\", \",\"), n(i, \"verseRangeSeparators\", [i.verseRangeSeparator]), n(i, \"verseSequenceIndicators\", [i.verseSequenceIndicator]), n(i, \"chapterDigitShifter\", 1e3), n(i, \"bookDigitShifter\", i.chapterDigitShifter * i.chapterDigitShifter), n(i, \"bcvMaxValue\", i.chapterDigitShifter - 1), /**\n * The valid status of the VerseRef.\n */\nn(i, \"ValidStatusType\", D);\nlet M = i;\nclass v extends Error {\n}\nexport {\n _ as BookSet,\n m as Canon,\n c as ScrVers,\n l as ScrVersType,\n M as VerseRef,\n v as VerseRefException\n};\n//# sourceMappingURL=index.es.js.map\n","import React from 'react';\nimport * as DropdownMenuPrimitive from '@radix-ui/react-dropdown-menu';\nimport { Check, ChevronRight, Circle } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport const DropdownMenu = DropdownMenuPrimitive.Root;\n\nexport const DropdownMenuTrigger = DropdownMenuPrimitive.Trigger;\n\nexport const DropdownMenuGroup = DropdownMenuPrimitive.Group;\n\nexport const DropdownMenuPortal = DropdownMenuPrimitive.Portal;\n\nexport const DropdownMenuSub = DropdownMenuPrimitive.Sub;\n\nexport const DropdownMenuRadioGroup = DropdownMenuPrimitive.RadioGroup;\n\nexport type DropdownMenuSubTriggerProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.SubTrigger\n> & {\n className?: string;\n inset?: boolean;\n};\n\nexport type DropdownMenuSubContentProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.SubContent\n> & {\n className?: string;\n};\n\nexport type DropdownMenuContentProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Content\n> & {\n className?: string;\n sideOffset?: number;\n};\n\nexport type DropdownMenuItemProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Item\n> & {\n className?: string;\n inset?: boolean;\n};\n\nexport type DropdownMenuCheckboxItemProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.CheckboxItem\n> & {\n className?: string;\n checked?: boolean;\n};\n\nexport type DropdownMenuRadioItemProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.RadioItem\n> & {\n className?: string;\n};\n\nexport type DropdownMenuLabelProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Label\n> & {\n className?: string;\n inset?: boolean;\n};\n\nexport type DropdownMenuSeparatorProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Separator\n> & {\n className?: string;\n};\n\nexport type DropdownMenuShortcutProps = React.HTMLAttributes & {\n className?: string;\n};\n\nexport const DropdownMenuSubTrigger = React.forwardRef<\n React.ElementRef,\n DropdownMenuSubTriggerProps\n>(({ className, inset, children, ...props }, ref) => (\n \n {children}\n \n \n));\nDropdownMenuSubTrigger.displayName = DropdownMenuPrimitive.SubTrigger.displayName;\n\nexport const DropdownMenuSubContent = React.forwardRef<\n React.ElementRef,\n DropdownMenuSubContentProps\n>(({ className, ...props }, ref) => (\n \n));\nDropdownMenuSubContent.displayName = DropdownMenuPrimitive.SubContent.displayName;\n\nexport const DropdownMenuContent = React.forwardRef<\n React.ElementRef,\n DropdownMenuContentProps\n>(({ className, sideOffset = 4, ...props }, ref) => (\n \n \n \n));\nDropdownMenuContent.displayName = DropdownMenuPrimitive.Content.displayName;\n\n/**\n * TODO: fix: direction is not automatically handled by this component, so that shortcuts are\n * display always to the right\n */\nexport const DropdownMenuItem = React.forwardRef<\n React.ElementRef,\n DropdownMenuItemProps\n>(({ className, inset, ...props }, ref) => (\n \n));\nDropdownMenuItem.displayName = DropdownMenuPrimitive.Item.displayName;\n\nexport const DropdownMenuCheckboxItem = React.forwardRef<\n React.ElementRef,\n DropdownMenuCheckboxItemProps\n>(({ className, children, checked, ...props }, ref) => (\n \n \n \n \n \n \n {children}\n \n));\nDropdownMenuCheckboxItem.displayName = DropdownMenuPrimitive.CheckboxItem.displayName;\n\nexport const DropdownMenuRadioItem = React.forwardRef<\n React.ElementRef,\n DropdownMenuRadioItemProps\n>(({ className, children, ...props }, ref) => (\n \n \n \n \n \n \n {children}\n \n));\nDropdownMenuRadioItem.displayName = DropdownMenuPrimitive.RadioItem.displayName;\n\nexport const DropdownMenuLabel = React.forwardRef<\n React.ElementRef,\n DropdownMenuLabelProps\n>(({ className, inset, ...props }, ref) => (\n \n));\nDropdownMenuLabel.displayName = DropdownMenuPrimitive.Label.displayName;\n\nexport const DropdownMenuSeparator = React.forwardRef<\n React.ElementRef,\n DropdownMenuSeparatorProps\n>(({ className, ...props }, ref) => (\n \n));\nDropdownMenuSeparator.displayName = DropdownMenuPrimitive.Separator.displayName;\n\nexport function DropdownMenuShortcut({ className, ...props }: DropdownMenuShortcutProps) {\n return (\n \n );\n}\nDropdownMenuShortcut.displayName = 'DropdownMenuShortcut';\n","import { Canon } from '@sillsdev/scripture';\nimport { PropsWithChildren, KeyboardEvent, forwardRef } from 'react';\nimport { DropdownMenuItem as ShadDropdownMenuItem } from '@/components/shadcn-ui/dropdown-menu';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport type BookType = 'OT' | 'NT' | 'DC';\n\ntype BookMenuItemProps = PropsWithChildren<{\n /** String id of book */\n bookId: string;\n /** Callback to run when a book menu item is selected */\n handleSelectBook: () => void;\n /** Indicates if this menu item is currently selected */\n isSelected: boolean;\n /** Function that is called upon highlighting a book in the dropdown menu */\n handleHighlightBook: () => void;\n /**\n * Function that is called on pressing a key\n *\n * @param event Event that contains information about the key stroke\n */\n handleKeyDown: (event: KeyboardEvent) => void;\n /**\n * Type of book associated with this menu item, coordinates color labels ? Mock up has the labels\n * coordinated to genre\n */\n bookType: BookType;\n}>;\n\nconst BookMenuItem = forwardRef(\n (\n {\n bookId,\n handleSelectBook,\n isSelected,\n handleHighlightBook,\n handleKeyDown,\n bookType,\n children,\n }: BookMenuItemProps,\n ref,\n ) => {\n return (\n {\n // preventDefault() here prevents the entire dropdown menu from closing when selecting this item\n event.preventDefault();\n handleSelectBook();\n }}\n onKeyDown={(event: KeyboardEvent) => {\n handleKeyDown(event);\n }}\n onFocus={handleHighlightBook}\n onMouseMove={handleHighlightBook}\n >\n \n {Canon.bookIdToEnglishName(bookId)}\n \n {isSelected &&
    {children}
    }\n \n );\n },\n);\n\nexport default BookMenuItem;\n","import { cn } from '@/utils/shadcn-ui.util';\nimport { useCallback } from 'react';\n\nexport type ChapterSelectProps = {\n /**\n * Callback to run when a chapter div is selected\n *\n * @param chapterNumber Number of the chapter that has been selected\n */\n handleSelectChapter: (chapterNumber: number) => void;\n /** The highest chapter number in the book (of course equal to number of chapters in the book) */\n endChapter: number;\n /** The chapter number that is currently selected */\n activeChapter: number;\n /** The chapter number that is currently highlighted using keyboard or mouse navigation */\n highlightedChapter: number;\n /**\n * Callback to run when a chapter is highlighted by the user\n *\n * @param chapterNumber The chapter that is highlighted\n */\n handleHighlightedChapter: (chapterNumber: number) => void;\n};\n\nfunction ChapterSelect({\n handleSelectChapter,\n endChapter,\n activeChapter,\n highlightedChapter,\n handleHighlightedChapter,\n}: ChapterSelectProps) {\n const chapters = Array.from({ length: endChapter }, (_, i) => i + 1);\n\n const handleMouse = useCallback(\n (chapterNumber: number) => {\n handleHighlightedChapter(chapterNumber);\n },\n [handleHighlightedChapter],\n );\n\n return (\n
    \n {chapters.map((chapter) => (\n {\n event.preventDefault();\n event.stopPropagation();\n handleSelectChapter(chapter);\n }}\n role=\"button\"\n onKeyDown={(event) => {\n if (event.key === 'Enter') {\n handleSelectChapter(chapter);\n }\n }}\n tabIndex={0}\n onMouseMove={() => handleMouse(chapter)}\n >\n {chapter}\n
    \n ))}\n
    \n );\n}\n\nexport default ChapterSelect;\n","import { DropdownMenuLabel as ShadDropdownMenuLabel } from '@/components/shadcn-ui/dropdown-menu';\nimport { Bookmark, Clock, ArrowDownWideNarrow } from 'lucide-react';\n\nexport type GoToMenuItemProps = {\n handleSort: () => void;\n handleLocationHistory: () => void;\n handleBookmarks: () => void;\n};\n\nfunction GoToMenuItem({ handleSort, handleLocationHistory, handleBookmarks }: GoToMenuItemProps) {\n return (\n \n

    Go To

    \n
    \n \n \n \n
    \n
    \n );\n}\n\nexport default GoToMenuItem;\n","import BookChapterInput from '@/components/advanced/book-chapter-control/book-chapter-input.component';\nimport BookMenuItem, {\n BookType,\n} from '@/components/advanced/book-chapter-control/book-menu-item.component';\nimport ChapterSelect from '@/components/advanced/book-chapter-control/chapter-select.component';\nimport GoToMenuItem from '@/components/advanced/book-chapter-control/go-to-menu-item.component';\nimport {\n DropdownMenu as ShadDropdownMenu,\n DropdownMenuContent as ShadDropdownMenuContent,\n DropdownMenuLabel as ShadDropdownMenuLabel,\n DropdownMenuSeparator as ShadDropdownMenuSeparator,\n DropdownMenuTrigger as ShadDropdownMenuTrigger,\n} from '@/components/shadcn-ui/dropdown-menu';\nimport { Canon } from '@sillsdev/scripture';\nimport { ScriptureReference, getChaptersForBook } from 'platform-bible-utils';\nimport {\n KeyboardEvent as ReactKeyboardEvent,\n useCallback,\n useEffect,\n useLayoutEffect,\n useRef,\n useState,\n} from 'react';\n\ntype BookTypeLabels = {\n [bookType in BookType]: string;\n};\ntype BookChapterControlProps = {\n scrRef: ScriptureReference;\n handleSubmit: (scrRef: ScriptureReference) => void;\n};\n\nconst ALL_BOOK_IDS = Canon.allBookIds;\nconst BOOK_TYPE_LABELS: BookTypeLabels = {\n OT: 'Old Testament',\n NT: 'New Testament',\n DC: 'Deuterocanon',\n};\nconst BOOK_TYPE_ARRAY: BookType[] = ['OT', 'NT', 'DC'];\n// This is the height of three menu items to offset scrolling to the selected menu item\n// If you use menuItemRef.clientHeight- includes height of chapter div which is too big\nconst SCROLL_OFFSET = 32 + 32 + 32;\nconst SEARCH_QUERY_FORMATS = [\n /^(\\w+)$/i, // Matches a single word (book name or id)\n /^(\\w+)(?:\\s(\\d+))$/i, // Matches a word followed by a chapter number\n /^(\\w+)(?:\\s(\\d+):(\\d+))$/i, // Matches a word followed by a chapter and verse number\n];\nconst fetchGroupedBooks = (bookType: BookType) => {\n const groupedBooks = {\n OT: ALL_BOOK_IDS.filter((bookId) => Canon.isBookOT(bookId)),\n NT: ALL_BOOK_IDS.filter((bookId) => Canon.isBookNT(bookId)),\n DC: ALL_BOOK_IDS.filter((bookId) => Canon.isBookDC(bookId)),\n };\n return groupedBooks[bookType];\n};\nconst fetchEndChapter = (bookId: string) => {\n // getChaptersForBook returns -1 if not found in scrBookData\n // scrBookData only includes OT and NT, so all DC will return -1\n return getChaptersForBook(Canon.bookIdToNumber(bookId));\n};\n\n/**\n * Gets all of the English names from book ids\n *\n * @returns String[]\n */\nfunction getAllEnglishNames(): string[] {\n const allEnglishNames = ALL_BOOK_IDS.map((bookId) => {\n return Canon.bookIdToEnglishName(bookId);\n });\n return allEnglishNames;\n}\n\n/**\n * Determines if bookName is in allEnglishNames\n *\n * @param bookName Book English name\n * @returns True if bookName is included, false otherwise\n */\nfunction isValidBookEnglishName(bookName: string): boolean {\n return getAllEnglishNames().includes(bookName);\n}\n\n/**\n * Gets a bookId from given English name\n *\n * @param bookName Book English name\n * @returns BookId of provided bookName, undefined otherwise\n */\nfunction getBookIdFromEnglishName(bookName: string): string | undefined {\n // Convert bookName to lowercase and then capitalize the first letter\n const formattedBookName = bookName.toLowerCase().replace(/^\\w/, (c) => c.toUpperCase());\n\n if (isValidBookEnglishName(formattedBookName)) {\n const matchingBookId = ALL_BOOK_IDS.find((bookId) => {\n return Canon.bookIdToEnglishName(bookId) === formattedBookName;\n });\n return matchingBookId;\n }\n\n return undefined;\n}\n\nfunction BookChapterControl({ scrRef, handleSubmit }: BookChapterControlProps) {\n const [searchQuery, setSearchQuery] = useState('');\n const [selectedBookId, setSelectedBookId] = useState(\n Canon.bookNumberToId(scrRef.bookNum),\n );\n const [highlightedChapter, setHighlightedChapter] = useState(scrRef.chapterNum ?? 0);\n const [highlightedBookId, setHighlightedBookId] = useState(\n Canon.bookNumberToId(scrRef.bookNum),\n );\n const [isContentOpen, setIsContentOpen] = useState(false);\n const [isContentOpenDelayed, setIsContentOpenDelayed] = useState(isContentOpen);\n\n // This ref will always be defined\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const inputRef = useRef(undefined!);\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const contentRef = useRef(undefined!);\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const menuItemRef = useRef(undefined!);\n\n const fetchFilteredBooks = useCallback(\n (bookType: BookType) => {\n return fetchGroupedBooks(bookType).filter((bookId: string) => {\n const englishNameLowerCase = Canon.bookIdToEnglishName(bookId).toLowerCase();\n const normalizedQuery = searchQuery.replace(/[^a-zA-Z]/g, '').toLowerCase();\n return (\n englishNameLowerCase.includes(normalizedQuery) || // Match book name\n bookId.toLowerCase().includes(normalizedQuery) // Match book ID\n );\n });\n },\n [searchQuery],\n );\n\n const handleSearchInput = (searchString: string) => {\n setSearchQuery(searchString);\n };\n\n /**\n * Whether to prevent radix's logic from closing the dropdown. This is important because radix\n * tries to close the dropdown when the input first focuses, and we don't want it to do that. But\n * we don't want to prevent the dropdown from closing when we click away from the input, so we\n * don't want to just keep it open if the input is focused\n */\n const shouldPreventAutoClosing = useRef(false);\n\n const controlMenuState = useCallback((open: boolean) => {\n if (shouldPreventAutoClosing.current) {\n shouldPreventAutoClosing.current = false;\n return;\n }\n setIsContentOpen(open);\n }, []);\n\n const updateReference = useCallback(\n (bookId: string, shouldClose: boolean, chapter?: number, verse?: number) => {\n setHighlightedChapter(\n Canon.bookNumberToId(scrRef.bookNum) !== bookId ? 1 : scrRef.chapterNum,\n );\n\n if (shouldClose || fetchEndChapter(bookId) === -1) {\n handleSubmit({\n bookNum: Canon.bookIdToNumber(bookId),\n chapterNum: chapter || 1,\n verseNum: verse || 1,\n });\n\n setIsContentOpen(false);\n setSearchQuery('');\n return;\n }\n\n setSelectedBookId(selectedBookId !== bookId ? bookId : '');\n setIsContentOpen(!shouldClose);\n },\n [handleSubmit, scrRef.bookNum, scrRef.chapterNum, selectedBookId],\n );\n\n const handleSelectChapter = (chapterNumber: number) => {\n if (chapterNumber <= 0 || chapterNumber > fetchEndChapter(selectedBookId)) {\n return;\n }\n updateReference(selectedBookId, true, chapterNumber);\n };\n\n const handleInputSubmit = useCallback(() => {\n SEARCH_QUERY_FORMATS.forEach((format) => {\n const matches = searchQuery.match(format);\n if (matches) {\n // Book should be a bookId or an english name\n const [book, chapter = undefined, verse = undefined] = matches.slice(1);\n const englishName = getBookIdFromEnglishName(book);\n\n if (Canon.isBookIdValid(book) || englishName) {\n updateReference(\n englishName ?? book,\n true,\n chapter ? parseInt(chapter, 10) : 1,\n verse ? parseInt(verse, 10) : 1,\n );\n }\n }\n });\n }, [updateReference, searchQuery]);\n\n const handleKeyDownInput = useCallback(\n (event: ReactKeyboardEvent) => {\n if (!isContentOpen) {\n setIsContentOpen(true);\n } else if (event.key === 'ArrowDown' || event.key === 'ArrowUp') {\n if (\n typeof menuItemRef !== 'undefined' &&\n // Ref uses null\n // eslint-disable-next-line no-null/no-null\n menuItemRef.current !== null\n ) {\n menuItemRef.current.focus();\n } else if (\n typeof contentRef !== 'undefined' &&\n // Ref uses null\n // eslint-disable-next-line no-null/no-null\n contentRef.current !== null\n ) {\n contentRef.current.focus();\n }\n event.preventDefault();\n }\n },\n [isContentOpen],\n );\n\n const handleKeyDownContent = (event: ReactKeyboardEvent) => {\n // When the dropdown menu has focus, key strokes should give focus to the input component,\n // unless they're navigation keys (arrows and enter)\n const { key } = event;\n if (\n key === 'ArrowRight' ||\n key === 'ArrowLeft' ||\n key === 'ArrowDown' ||\n key === 'ArrowUp' ||\n key === 'Enter'\n ) {\n return;\n }\n\n inputRef.current.dispatchEvent(new KeyboardEvent('keydown', { key }));\n inputRef.current.focus();\n };\n\n const handleKeyDownMenuItem = (event: ReactKeyboardEvent) => {\n const { key } = event;\n if (highlightedBookId === selectedBookId) {\n if (key === 'Enter') {\n event.preventDefault();\n updateReference(selectedBookId, true, highlightedChapter);\n return;\n }\n\n let chapterOffSet = 0;\n if (key === 'ArrowRight') {\n if (highlightedChapter < fetchEndChapter(highlightedBookId)) {\n chapterOffSet = 1;\n } else {\n event.preventDefault();\n return;\n }\n } else if (key === 'ArrowLeft') {\n if (highlightedChapter > 1) {\n chapterOffSet = -1;\n } else {\n event.preventDefault();\n return;\n }\n } else if (key === 'ArrowDown') {\n chapterOffSet = 6;\n } else if (key === 'ArrowUp') {\n chapterOffSet = -6;\n }\n if (\n highlightedChapter + chapterOffSet <= 0 ||\n highlightedChapter + chapterOffSet > fetchEndChapter(highlightedBookId)\n ) {\n setHighlightedChapter(0);\n } else if (chapterOffSet !== 0) {\n setHighlightedChapter(highlightedChapter + chapterOffSet);\n event.preventDefault();\n }\n }\n };\n\n useEffect(() => {\n if (selectedBookId === highlightedBookId) {\n if (selectedBookId === Canon.bookNumberToId(scrRef.bookNum)) {\n setHighlightedChapter(scrRef.chapterNum);\n } else {\n setHighlightedChapter(1);\n }\n } else {\n setHighlightedChapter(0);\n }\n }, [highlightedBookId, scrRef.bookNum, scrRef.chapterNum, selectedBookId]);\n\n // The purpose of these useLayoutEffects and timeout is to delay the scroll just\n // enough so that the refs are defined and available when they are used after the timeout\n useLayoutEffect(() => {\n setIsContentOpenDelayed(isContentOpen);\n }, [isContentOpen]);\n\n useLayoutEffect(() => {\n const scrollTimeout = setTimeout(() => {\n if (isContentOpenDelayed && contentRef.current && menuItemRef.current) {\n const menuItemOffsetTop = menuItemRef.current.offsetTop;\n const scrollPosition = menuItemOffsetTop - SCROLL_OFFSET;\n contentRef.current.scrollTo({ top: scrollPosition, behavior: 'instant' });\n }\n }, 10);\n return () => {\n clearTimeout(scrollTimeout);\n };\n }, [isContentOpenDelayed]);\n\n return (\n
    \n \n \n {\n setSelectedBookId(Canon.bookNumberToId(scrRef.bookNum));\n setHighlightedBookId(Canon.bookNumberToId(scrRef.bookNum));\n setHighlightedChapter(scrRef.chapterNum > 0 ? scrRef.chapterNum : 0);\n setIsContentOpen(true);\n inputRef.current.focus();\n }}\n onFocus={() => {\n // Radix thinks we want to close because the input is being focused. Prevent that\n shouldPreventAutoClosing.current = true;\n }}\n handleSubmit={handleInputSubmit}\n placeholder={`${Canon.bookNumberToEnglishName(scrRef.bookNum)} ${scrRef.chapterNum}:${scrRef.verseNum}`}\n />\n \n \n console.log('sorting')}\n handleLocationHistory={() => console.log('location history')}\n handleBookmarks={() => console.log('bookmarks')}\n />\n {BOOK_TYPE_ARRAY.map(\n (bookType, bookTypeIndex) =>\n fetchFilteredBooks(bookType).length > 0 && (\n
    \n \n {BOOK_TYPE_LABELS[bookType]}\n \n\n {fetchFilteredBooks(bookType).map((bookId) => (\n
    \n updateReference(bookId, false)}\n isSelected={selectedBookId === bookId}\n handleHighlightBook={() => setHighlightedBookId(bookId)}\n handleKeyDown={handleKeyDownMenuItem}\n bookType={bookType}\n ref={(element: HTMLDivElement) => {\n if (selectedBookId === bookId) menuItemRef.current = element;\n }}\n >\n {\n setHighlightedChapter(chapterNumber);\n }}\n />\n \n
    \n ))}\n {BOOK_TYPE_ARRAY.length - 1 !== bookTypeIndex ? (\n \n ) : undefined}\n
    \n ),\n )}\n \n
    \n
    \n );\n}\n\nexport default BookChapterControl;\n","import React from 'react';\nimport { Slot } from '@radix-ui/react-slot';\nimport { cva, type VariantProps } from 'class-variance-authority';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport const buttonVariants = cva(\n 'pr-twp tw-inline-flex tw-items-center tw-justify-center tw-whitespace-nowrap tw-rounded-md tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-colors focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50',\n {\n variants: {\n variant: {\n default: 'tw-bg-primary tw-text-primary-foreground hover:tw-bg-primary/90',\n destructive: 'tw-bg-destructive tw-text-destructive-foreground hover:tw-bg-destructive/90',\n outline:\n 'tw-border tw-border-input tw-bg-background hover:tw-bg-accent hover:tw-text-accent-foreground',\n secondary: 'tw-bg-secondary tw-text-secondary-foreground hover:tw-bg-secondary/80',\n ghost: 'hover:tw-bg-accent hover:tw-text-accent-foreground',\n link: 'tw-text-primary tw-underline-offset-4 hover:tw-underline',\n },\n size: {\n default: 'tw-h-10 tw-px-4 tw-py-2',\n sm: 'tw-h-9 tw-rounded-md tw-px-3',\n lg: 'tw-h-11 tw-rounded-md tw-px-8',\n icon: 'tw-h-10 tw-w-10',\n },\n },\n defaultVariants: {\n variant: 'default',\n size: 'default',\n },\n },\n);\n\nexport interface ButtonProps\n extends React.ButtonHTMLAttributes,\n VariantProps {\n asChild?: boolean;\n}\n\nexport const Button = React.forwardRef(\n ({ className, variant, size, asChild = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'button';\n return (\n \n );\n },\n);\nButton.displayName = 'Button';\n","import React from 'react';\nimport * as LabelPrimitive from '@radix-ui/react-label';\nimport { cva, type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst labelVariants = cva(\n 'tw-text-sm tw-font-medium tw-leading-none peer-disabled:tw-cursor-not-allowed peer-disabled:tw-opacity-70',\n);\n\nexport const Label = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef & VariantProps\n>(({ className, ...props }, ref) => (\n \n));\nLabel.displayName = LabelPrimitive.Root.displayName;\n","import React from 'react';\nimport * as RadioGroupPrimitive from '@radix-ui/react-radio-group';\nimport { Circle } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst RadioGroup = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => {\n return (\n \n );\n});\nRadioGroup.displayName = RadioGroupPrimitive.Root.displayName;\n\nconst RadioGroupItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => {\n return (\n \n \n \n \n \n );\n});\nRadioGroupItem.displayName = RadioGroupPrimitive.Item.displayName;\n\nexport { RadioGroup, RadioGroupItem };\n","import React from 'react';\nimport * as PopoverPrimitive from '@radix-ui/react-popover';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Popover = PopoverPrimitive.Root;\n\nconst PopoverTrigger = PopoverPrimitive.Trigger;\n\nconst PopoverContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, align = 'center', sideOffset = 4, ...props }, ref) => (\n \n \n \n));\nPopoverContent.displayName = PopoverPrimitive.Content.displayName;\n\nexport { Popover, PopoverTrigger, PopoverContent };\n","import React from 'react';\nimport * as DialogPrimitive from '@radix-ui/react-dialog';\nimport { X } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Dialog = DialogPrimitive.Root;\n\nconst DialogTrigger = DialogPrimitive.Trigger;\n\nconst DialogPortal = DialogPrimitive.Portal;\n\nconst DialogClose = DialogPrimitive.Close;\n\nconst DialogOverlay = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nDialogOverlay.displayName = DialogPrimitive.Overlay.displayName;\n\nconst DialogContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, ...props }, ref) => (\n \n \n \n {children}\n \n \n Close\n \n \n \n));\nDialogContent.displayName = DialogPrimitive.Content.displayName;\n\nfunction DialogHeader({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nDialogHeader.displayName = 'DialogHeader';\n\nfunction DialogFooter({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nDialogFooter.displayName = 'DialogFooter';\n\nconst DialogTitle = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nDialogTitle.displayName = DialogPrimitive.Title.displayName;\n\nconst DialogDescription = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nDialogDescription.displayName = DialogPrimitive.Description.displayName;\n\nexport {\n Dialog,\n DialogPortal,\n DialogOverlay,\n DialogClose,\n DialogTrigger,\n DialogContent,\n DialogHeader,\n DialogFooter,\n DialogTitle,\n DialogDescription,\n};\n","import React from 'react';\nimport { type DialogProps } from '@radix-ui/react-dialog';\nimport { Command as CommandPrimitive } from 'cmdk';\nimport { Search } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Dialog, DialogContent } from '@/components/shadcn-ui/dialog';\n\nconst Command = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nCommand.displayName = CommandPrimitive.displayName;\n\ninterface CommandDialogProps extends DialogProps {}\n\nfunction CommandDialog({ children, ...props }: CommandDialogProps) {\n return (\n \n \n \n {children}\n \n \n \n );\n}\n\nconst CommandInput = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n
    \n \n \n
    \n));\n\nCommandInput.displayName = CommandPrimitive.Input.displayName;\n\nconst CommandList = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\n\nCommandList.displayName = CommandPrimitive.List.displayName;\n\nconst CommandEmpty = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>((props, ref) => (\n \n));\n\nCommandEmpty.displayName = CommandPrimitive.Empty.displayName;\n\nconst CommandGroup = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\n\nCommandGroup.displayName = CommandPrimitive.Group.displayName;\n\nconst CommandSeparator = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nCommandSeparator.displayName = CommandPrimitive.Separator.displayName;\n\nconst CommandItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\n\nCommandItem.displayName = CommandPrimitive.Item.displayName;\n\nfunction CommandShortcut({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nCommandShortcut.displayName = 'CommandShortcut';\n\nexport {\n Command,\n CommandDialog,\n CommandInput,\n CommandList,\n CommandEmpty,\n CommandGroup,\n CommandItem,\n CommandShortcut,\n CommandSeparator,\n};\n","import { useState } from 'react';\nimport { Check, ChevronsUpDown } from 'lucide-react';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport { Popover, PopoverContent, PopoverTrigger } from '@/components/shadcn-ui/popover';\nimport {\n Command,\n CommandEmpty,\n CommandInput,\n CommandItem,\n CommandList,\n} from '@/components/shadcn-ui/command';\nimport { PopoverProps } from '@radix-ui/react-popover';\n\nexport type ComboBoxLabelOption = { label: string };\nexport type ComboBoxOption = string | number | ComboBoxLabelOption;\n\nexport type ComboBoxProps = {\n /** Optional unique identifier */\n id?: string;\n /** Text label title for combobox */\n /** List of available options for the dropdown menu */\n options?: readonly T[];\n /** @deprecated 3 December 2024. Renamed to {@link buttonClassName} */\n className?: string;\n /** Additional css classes to help with unique styling of the combo box button */\n buttonClassName?: string;\n /** Additional css classes to help with unique styling of the combo box popover */\n popoverContentClassName?: string;\n /**\n * The selected value that the combo box currently holds. Must be shallow equal to one of the\n * options entries.\n */\n value?: T;\n /** Triggers when content of textfield is changed */\n onChange?: (newValue: T) => void;\n /** Used to determine the string value for a given option. */\n getOptionLabel?: (option: ComboBoxOption) => string;\n /** Text displayed on button if `value` is undefined */\n buttonPlaceholder?: string;\n /** Placeholder text for text field */\n textPlaceholder?: string;\n /** Text to display when no options match input */\n commandEmptyMessage?: string;\n /** Variant of button */\n buttonVariant?: ButtonProps['variant'];\n /** Text direction ltr or rtl */\n dir?: Direction;\n /** Optional boolean to set if trigger should be disabled */\n isDisabled?: boolean;\n} & PopoverProps;\n\ntype Direction = 'ltr' | 'rtl';\n\nfunction getOptionLabelDefault(option: ComboBoxOption): string {\n if (typeof option === 'string') {\n return option;\n }\n if (typeof option === 'number') {\n return option.toString();\n }\n return option.label;\n}\n\n/**\n * Autocomplete input and command palette with a list of suggestions.\n *\n * Thanks to Shadcn for heavy inspiration and documentation\n * https://ui.shadcn.com/docs/components/combobox\n */\nfunction ComboBox({\n id,\n options = [],\n buttonClassName,\n popoverContentClassName,\n value,\n onChange = () => {},\n getOptionLabel = getOptionLabelDefault,\n buttonPlaceholder = '',\n textPlaceholder = '',\n commandEmptyMessage = 'No option found',\n buttonVariant = 'outline',\n dir = 'ltr',\n isDisabled = false,\n ...props\n}: ComboBoxProps) {\n const [open, setOpen] = useState(false);\n\n return (\n \n \n \n \n {value ? getOptionLabel(value) : buttonPlaceholder}\n \n \n \n \n \n \n \n {commandEmptyMessage}\n \n {options.map((option) => (\n {\n onChange(option);\n setOpen(false);\n }}\n >\n \n {getOptionLabel(option)}\n \n ))}\n \n \n \n \n );\n}\n\nexport default ComboBox;\n","import { useMemo } from 'react';\nimport ComboBox from '@/components/basics/combo-box.component';\nimport { Label } from '@/components/shadcn-ui/label';\n\nexport type ChapterRangeSelectorProps = {\n startChapter: number;\n endChapter: number;\n handleSelectStartChapter: (chapter: number) => void;\n handleSelectEndChapter: (chapter: number) => void;\n isDisabled?: boolean;\n chapterCount: number;\n};\n\nexport default function ChapterRangeSelector({\n startChapter,\n endChapter,\n handleSelectStartChapter,\n handleSelectEndChapter,\n isDisabled = false,\n chapterCount,\n}: ChapterRangeSelectorProps) {\n const chapterOptions = useMemo(\n () => Array.from({ length: chapterCount }, (_, index) => index + 1),\n [chapterCount],\n );\n\n const onChangeStartChapter = (value: number) => {\n handleSelectStartChapter(value);\n if (value > endChapter) {\n handleSelectEndChapter(value);\n }\n };\n\n const onChangeEndChapter = (value: number) => {\n handleSelectEndChapter(value);\n if (value < startChapter) {\n handleSelectStartChapter(value);\n }\n };\n\n return (\n <>\n \n option.toString()}\n value={startChapter}\n />\n\n \n option.toString()}\n value={endChapter}\n />\n \n );\n}\n","import { Button } from '@/components/shadcn-ui/button';\nimport { Label } from '@/components/shadcn-ui/label';\nimport { RadioGroup, RadioGroupItem } from '@/components/shadcn-ui/radio-group';\nimport { Canon } from '@sillsdev/scripture';\nimport { LocalizedStringValue } from 'platform-bible-utils';\nimport { useState } from 'react';\nimport ChapterRangeSelector, {\n ChapterRangeSelectorProps,\n} from '../basics/chapter-range-selector.component';\n\nexport enum BookSelectionMode {\n CURRENT_BOOK = 'current book',\n CHOOSE_BOOKS = 'choose books',\n}\n\n/**\n * Object containing all keys used for localization in this component. If you're using this\n * component in an extension, you can pass it into the useLocalizedStrings hook to easily obtain the\n * localized strings and pass them into the localizedStrings prop of this component\n */\nexport const BOOK_SELECTOR_STRING_KEYS = Object.freeze([\n '%webView_bookSelector_currentBook%',\n '%webView_bookSelector_choose%',\n '%webView_bookSelector_chooseBooks%',\n] as const);\n\nexport type BookSelectorLocalizedStrings = {\n [localizedInventoryKey in (typeof BOOK_SELECTOR_STRING_KEYS)[number]]?: LocalizedStringValue;\n};\n\n/**\n * Gets the localized value for the provided key\n *\n * @param strings Object containing localized string\n * @param key Key for a localized string\n * @returns The localized value for the provided key, if available. Returns the key if no localized\n * value is available\n */\nconst localizeString = (\n strings: BookSelectorLocalizedStrings,\n key: keyof BookSelectorLocalizedStrings,\n) => {\n return strings[key] ?? key;\n};\n\ntype BookSelectorProps = ChapterRangeSelectorProps & {\n handleBookSelectionModeChange: (newMode: BookSelectionMode) => void;\n currentBookName: string;\n onSelectBooks: () => void;\n selectedBookIds: string[];\n localizedStrings: BookSelectorLocalizedStrings;\n};\n\nexport default function BookSelector({\n handleBookSelectionModeChange,\n currentBookName,\n onSelectBooks,\n selectedBookIds,\n chapterCount,\n endChapter,\n handleSelectEndChapter,\n startChapter,\n handleSelectStartChapter,\n localizedStrings,\n}: BookSelectorProps) {\n const currentBookText = localizeString(localizedStrings, '%webView_bookSelector_currentBook%');\n const chooseText = localizeString(localizedStrings, '%webView_bookSelector_choose%');\n const chooseBooksText = localizeString(localizedStrings, '%webView_bookSelector_chooseBooks%');\n\n const [bookSelectionMode, setBookSelectionMode] = useState(\n BookSelectionMode.CURRENT_BOOK,\n );\n\n const onSelectionModeChange = (newMode: BookSelectionMode) => {\n setBookSelectionMode(newMode);\n handleBookSelectionModeChange(newMode);\n };\n\n return (\n onSelectionModeChange(value as BookSelectionMode)}\n >\n
    \n
    \n
    \n \n \n
    \n \n
    \n \n
    \n
    \n
    \n
    \n \n \n
    \n \n onSelectBooks()}\n >\n {chooseText}\n \n
    \n
    \n \n );\n}\n","import { DropdownMenuTrigger } from '@radix-ui/react-dropdown-menu';\nimport { FilterIcon } from 'lucide-react';\nimport { Table } from '@tanstack/react-table';\n\nimport { Button } from '@/components/shadcn-ui/button';\nimport {\n DropdownMenu,\n DropdownMenuCheckboxItem,\n DropdownMenuContent,\n DropdownMenuLabel,\n DropdownMenuSeparator,\n} from '@/components/shadcn-ui/dropdown-menu';\n\ninterface DataTableViewOptionsProps {\n table: Table;\n}\n\nfunction DataTableViewOptions({ table }: DataTableViewOptionsProps) {\n return (\n \n \n \n \n \n Toggle columns\n \n {table\n .getAllColumns()\n .filter((column) => column.getCanHide())\n .map((column) => {\n return (\n column.toggleVisibility(!!value)}\n >\n {column.id}\n \n );\n })}\n \n \n );\n}\n\nexport default DataTableViewOptions;\n","import React from 'react';\nimport * as SelectPrimitive from '@radix-ui/react-select';\nimport { Check, ChevronDown, ChevronUp } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Select = SelectPrimitive.Root;\n\nconst SelectGroup = SelectPrimitive.Group;\n\nconst SelectValue = SelectPrimitive.Value;\n\nconst SelectTrigger = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, ...props }, ref) => (\n span]:tw-line-clamp-1',\n className,\n )}\n {...props}\n >\n {children}\n \n \n \n \n));\nSelectTrigger.displayName = SelectPrimitive.Trigger.displayName;\n\nconst SelectScrollUpButton = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n));\nSelectScrollUpButton.displayName = SelectPrimitive.ScrollUpButton.displayName;\n\nconst SelectScrollDownButton = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n));\nSelectScrollDownButton.displayName = SelectPrimitive.ScrollDownButton.displayName;\n\nconst SelectContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, position = 'popper', ...props }, ref) => (\n \n \n \n \n {children}\n \n \n \n \n));\nSelectContent.displayName = SelectPrimitive.Content.displayName;\n\nconst SelectLabel = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSelectLabel.displayName = SelectPrimitive.Label.displayName;\n\nconst SelectItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, ...props }, ref) => (\n \n \n \n \n \n \n\n {children}\n \n));\nSelectItem.displayName = SelectPrimitive.Item.displayName;\n\nconst SelectSeparator = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSelectSeparator.displayName = SelectPrimitive.Separator.displayName;\n\nexport {\n Select,\n SelectGroup,\n SelectValue,\n SelectTrigger,\n SelectContent,\n SelectLabel,\n SelectItem,\n SelectSeparator,\n SelectScrollUpButton,\n SelectScrollDownButton,\n};\n","import { ChevronLeftIcon, ChevronRightIcon, ArrowLeftIcon, ArrowRightIcon } from 'lucide-react';\nimport { Table } from '@tanstack/react-table';\n\nimport { Button } from '@/components/shadcn-ui/button';\nimport {\n Select,\n SelectContent,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\n\ninterface DataTablePaginationProps {\n table: Table;\n}\n\nfunction DataTablePagination({ table }: DataTablePaginationProps) {\n return (\n
    \n
    \n
    \n {table.getFilteredSelectedRowModel().rows.length} of{' '}\n {table.getFilteredRowModel().rows.length} row(s) selected\n
    \n
    \n

    Rows per page

    \n {\n table.setPageSize(Number(value));\n }}\n >\n \n \n \n \n {[10, 20, 30, 40, 50].map((pageSize) => (\n \n {pageSize}\n \n ))}\n \n \n
    \n
    \n Page {table.getState().pagination.pageIndex + 1} of {table.getPageCount()}\n
    \n
    \n table.setPageIndex(0)}\n disabled={!table.getCanPreviousPage()}\n >\n Go to first page\n \n \n table.previousPage()}\n disabled={!table.getCanPreviousPage()}\n >\n Go to previous page\n \n \n table.nextPage()}\n disabled={!table.getCanNextPage()}\n >\n Go to next page\n \n \n table.setPageIndex(table.getPageCount() - 1)}\n disabled={!table.getCanNextPage()}\n >\n Go to last page\n \n \n
    \n
    \n
    \n );\n}\n\nexport default DataTablePagination;\n","import React from 'react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Table = React.forwardRef<\n HTMLTableElement,\n React.HTMLAttributes & { stickyHeader?: boolean }\n>(({ className, stickyHeader, ...props }, ref) => (\n
    \n \n
    \n));\nTable.displayName = 'Table';\n\nconst TableHeader = React.forwardRef<\n HTMLTableSectionElement,\n React.HTMLAttributes & { stickyHeader?: boolean }\n>(({ className, stickyHeader, ...props }, ref) => (\n \n));\nTableHeader.displayName = 'TableHeader';\n\nconst TableBody = React.forwardRef<\n HTMLTableSectionElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableBody.displayName = 'TableBody';\n\nconst TableFooter = React.forwardRef<\n HTMLTableSectionElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n tr]:last:tw-border-b-0', className)}\n {...props}\n />\n));\nTableFooter.displayName = 'TableFooter';\n\nconst TableRow = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nTableRow.displayName = 'TableRow';\n\nconst TableHead = React.forwardRef<\n HTMLTableCellElement,\n React.ThHTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableHead.displayName = 'TableHead';\n\nconst TableCell = React.forwardRef<\n HTMLTableCellElement,\n React.TdHTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableCell.displayName = 'TableCell';\n\nconst TableCaption = React.forwardRef<\n HTMLTableCaptionElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableCaption.displayName = 'TableCaption';\n\nexport { Table, TableHeader, TableBody, TableFooter, TableHead, TableRow, TableCell, TableCaption };\n","import { useState } from 'react';\n\nimport {\n ColumnFiltersState,\n flexRender,\n getCoreRowModel,\n getFilteredRowModel,\n getPaginationRowModel,\n getSortedRowModel,\n SortingState,\n ColumnDef as TSColumnDef,\n Row as TSRow,\n RowSelectionState as TSRowSelectionState,\n SortDirection as TSSortDirection,\n Table as TSTable,\n useReactTable,\n VisibilityState,\n} from '@tanstack/react-table';\n\nimport DataTableViewOptions from '@/components/advanced/data-table/data-table-column-toggle.component';\nimport DataTablePagination from '@/components/advanced/data-table/data-table-pagination.component';\nimport { Button } from '@/components/shadcn-ui/button';\nimport {\n Table,\n TableBody,\n TableCell,\n TableHead,\n TableHeader,\n TableRow,\n} from '@/components/shadcn-ui/table';\n\nexport type ColumnDef = TSColumnDef;\nexport type RowContents = TSRow;\nexport type TableContents = TSTable;\nexport type SortDirection = TSSortDirection;\nexport type RowSelectionState = TSRowSelectionState;\n\ninterface DataTableProps {\n columns: ColumnDef[];\n data: TData[];\n enablePagination?: boolean;\n showPaginationControls?: boolean;\n showColumnVisibilityControls?: boolean;\n stickyHeader?: boolean;\n onRowClickHandler?: (row: RowContents, table: TableContents) => void;\n}\n\n/**\n * Feature-rich table component that infuses our basic shadcn-based Table component with features\n * from TanStack's React Table library\n */\nfunction DataTable({\n columns,\n data,\n enablePagination = false,\n showPaginationControls = false,\n showColumnVisibilityControls = false,\n stickyHeader = false,\n onRowClickHandler = () => {},\n}: DataTableProps) {\n const [sorting, setSorting] = useState([]);\n const [columnFilters, setColumnFilters] = useState([]);\n const [columnVisibility, setColumnVisibility] = useState({});\n const [rowSelection, setRowSelection] = useState({});\n\n const table = useReactTable({\n data,\n columns,\n getCoreRowModel: getCoreRowModel(),\n ...(enablePagination && { getPaginationRowModel: getPaginationRowModel() }),\n onSortingChange: setSorting,\n getSortedRowModel: getSortedRowModel(),\n onColumnFiltersChange: setColumnFilters,\n getFilteredRowModel: getFilteredRowModel(),\n onColumnVisibilityChange: setColumnVisibility,\n onRowSelectionChange: setRowSelection,\n state: {\n sorting,\n columnFilters,\n columnVisibility,\n rowSelection,\n },\n });\n\n return (\n
    \n {showColumnVisibilityControls && }\n \n \n {table.getHeaderGroups().map((headerGroup) => (\n \n {headerGroup.headers.map((header) => {\n return (\n \n {header.isPlaceholder\n ? undefined\n : flexRender(header.column.columnDef.header, header.getContext())}\n \n );\n })}\n \n ))}\n \n \n {table.getRowModel().rows?.length ? (\n table.getRowModel().rows.map((row) => (\n onRowClickHandler(row, table)}\n key={row.id}\n data-state={row.getIsSelected() && 'selected'}\n >\n {row.getVisibleCells().map((cell) => (\n \n {flexRender(cell.column.columnDef.cell, cell.getContext())}\n \n ))}\n \n ))\n ) : (\n \n \n No results.\n \n \n )}\n \n
    \n {enablePagination && (\n
    \n table.previousPage()}\n disabled={!table.getCanPreviousPage()}\n >\n Previous\n \n table.nextPage()}\n disabled={!table.getCanNextPage()}\n >\n Next\n \n
    \n )}\n {enablePagination && showPaginationControls && }\n
    \n );\n}\n\nexport default DataTable;\n","import {\n Table,\n TableBody,\n TableCell,\n TableHead,\n TableHeader,\n TableRow,\n} from '@/components/shadcn-ui/table';\nimport { Canon } from '@sillsdev/scripture';\nimport { deepEqual, LanguageStrings, ScriptureReference } from 'platform-bible-utils';\nimport { useMemo } from 'react';\nimport { InventoryItemOccurrence } from './inventory-utils';\n\n/** Props for the OccurrencesTable component */\ntype OccurrencesTableProps = {\n /** Data that contains scriptures references and snippets of scripture */\n occurrenceData: InventoryItemOccurrence[];\n /** Callback function that is executed when the scripture reference is changed */\n setScriptureReference: (scriptureReference: ScriptureReference) => void;\n /**\n * Object with all localized strings that the OccurrencesTable needs to work well across multiple\n * languages\n */\n localizedStrings: LanguageStrings;\n};\n\n/**\n * Table that shows occurrences of specified inventory item(s). The first column shows the related\n * scripture reference. The second column shows the snippet of scripture that contains the specified\n * inventory item\n */\nfunction OccurrencesTable({\n occurrenceData,\n setScriptureReference,\n localizedStrings,\n}: OccurrencesTableProps) {\n const referenceHeaderText =\n localizedStrings['%webView_inventory_occurrences_table_header_reference%'];\n const occurrenceHeaderText =\n localizedStrings['%webView_inventory_occurrences_table_header_occurrence%'];\n\n const occurrences: InventoryItemOccurrence[] = useMemo(() => {\n const uniqueOccurrences: InventoryItemOccurrence[] = [];\n\n occurrenceData.forEach((occurrence) => {\n if (!uniqueOccurrences.some((uniqueOccurrence) => deepEqual(uniqueOccurrence, occurrence))) {\n uniqueOccurrences.push(occurrence);\n }\n });\n\n return uniqueOccurrences;\n }, [occurrenceData]);\n\n return (\n \n \n \n {referenceHeaderText}\n {occurrenceHeaderText}\n \n \n \n {occurrences.length > 0 &&\n occurrences.map((occurrence) => (\n {\n setScriptureReference(occurrence.reference);\n }}\n >\n {`${Canon.bookNumberToEnglishName(occurrence.reference.bookNum)} ${occurrence.reference.chapterNum}:${occurrence.reference.verseNum}`}\n {occurrence.text}\n \n ))}\n \n
    \n );\n}\n\nexport default OccurrencesTable;\n","import React from 'react';\nimport * as CheckboxPrimitive from '@radix-ui/react-checkbox';\nimport { Check } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Checkbox = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n \n \n));\nCheckbox.displayName = CheckboxPrimitive.Root.displayName;\n\nexport default Checkbox;\n","import { Canon } from '@sillsdev/scripture';\nimport { ScriptureReference } from 'platform-bible-utils';\n\n/* #region Types */\n\n/**\n * Status of items that appear in inventories. 'approved' and 'unapproved' items are defined in the\n * project's `Settings.xml`. All other items are defined as 'unknown'\n */\nexport type Status = 'approved' | 'unapproved' | 'unknown';\n\n/** Occurrence of item in inventory. Primarily used by table that shows occurrences */\nexport type InventoryItemOccurrence = {\n /** Reference to scripture where the item appears */\n reference: ScriptureReference;\n /** Snippet of scripture that contains the occurrence */\n text: string;\n};\n\n/** Data structure that contains all information on an item that is shown in an inventory */\nexport type InventoryTableData = {\n /**\n * The item (e.g. a character in the characters inventory, a marker in the marker inventory) In\n * most cases the array will only have one element. In case of additional items (e.g. the\n * preceding marker in the markers check), the primary item should be stored in the first index.\n * To show additional items in the inventory, make sure to configure the `additionalItemsLabels`\n * prop for the Inventory component\n */\n items: string[];\n /** The number of times this item occurs in the selected scope */\n count: number;\n /** The status of this item (see documentation for `Status` type for more information) */\n status: Status;\n /** Occurrences of this item in the scripture text for the selected scope */\n occurrences: InventoryItemOccurrence[];\n};\n\n/* #endregion */\n\n/* #region Functions */\n\n/**\n * Splits USFM string into shorter line-like segments\n *\n * @param text A single (likely very large) USFM string\n * @returns An array containing the input text, split into shorter segments\n */\nexport const getLinesFromUSFM = (text: string) => {\n // Splits on (CR)LF, CR, \\v, \\c and \\id\n return text.split(/(?:\\r?\\n|\\r)|(?=(?:\\\\(?:v|c|id)))/g);\n};\n\n/**\n * Extracts chapter or verse number from USFM strings that start with a \\c or \\v marker\n *\n * @param text USFM string that is expected to start with \\c or \\v marker\n * @returns Chapter or verse number if one is found. Else returns 0.\n */\nexport const getNumberFromUSFM = (text: string): number | undefined => {\n // Captures all digits that follow \\v or \\c markers followed by whitespace located at the start of a string\n const regex = /^\\\\[vc]\\s+(\\d+)/;\n const match = text.match(regex);\n\n if (match) {\n return +match[1];\n }\n return undefined;\n};\n\n/**\n * Gets book ID from USFM string that starts with the \\id marker, and returns book number for it\n *\n * @param text USFM string that is expected to start with \\id marker\n * @returns Book number corresponding to the \\id marker in the input text. Returns 0 if no marker is\n * found or the marker is not valid\n */\nexport const getBookNumFromId = (text: string): number => {\n // Captures all digits that follow an \\id marker followed by whitespace located at the start of a string\n const match = text.match(/^\\\\id\\s+([A-Za-z]+)/);\n if (match) {\n return Canon.bookIdToNumber(match[1]);\n }\n return 0;\n};\n\n/**\n * Gets the status for an item, typically used in the Inventory component\n *\n * @param item The item for which the status is being requested\n * @param approvedItems Array of approved items, typically as defined in `Settings.xml`\n * @param unapprovedItems Array of unapproved items, typically as defined in `Settings.xml`\n * @returns The status for the specified item\n */\nexport const getStatusForItem = (\n item: string,\n approvedItems: string[],\n unapprovedItems: string[],\n): Status => {\n if (unapprovedItems.includes(item)) return 'unapproved';\n if (approvedItems.includes(item)) return 'approved';\n return 'unknown';\n};\n\n/* #endregion */\n","import React from 'react';\nimport * as TogglePrimitive from '@radix-ui/react-toggle';\nimport { cva, type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst toggleVariants = cva(\n 'pr-twp tw-inline-flex tw-items-center tw-justify-center tw-rounded-md tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-colors hover:tw-bg-muted hover:tw-text-muted-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50 data-[state=on]:tw-bg-accent data-[state=on]:tw-text-accent-foreground',\n {\n variants: {\n variant: {\n default: 'tw-bg-transparent',\n outline:\n 'tw-border tw-border-input tw-bg-transparent hover:tw-bg-accent hover:tw-text-accent-foreground',\n },\n size: {\n default: 'tw-h-10 tw-px-3',\n sm: 'tw-h-9 tw-px-2.5',\n lg: 'tw-h-11 tw-px-5',\n },\n },\n defaultVariants: {\n variant: 'default',\n size: 'default',\n },\n },\n);\n\nconst Toggle = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef & VariantProps\n>(({ className, variant, size, ...props }, ref) => (\n \n));\n\nToggle.displayName = TogglePrimitive.Root.displayName;\n\nexport { Toggle, toggleVariants };\n","import React from 'react';\nimport * as ToggleGroupPrimitive from '@radix-ui/react-toggle-group';\nimport { type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { toggleVariants } from '@/components/shadcn-ui/toggle';\n\nconst ToggleGroupContext = React.createContext>({\n size: 'default',\n variant: 'default',\n});\n\nconst ToggleGroup = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef &\n VariantProps\n>(({ className, variant, size, children, ...props }, ref) => (\n \n \n {children}\n \n \n));\n\nToggleGroup.displayName = ToggleGroupPrimitive.Root.displayName;\n\nconst ToggleGroupItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef &\n VariantProps\n>(({ className, children, variant, size, ...props }, ref) => {\n const context = React.useContext(ToggleGroupContext);\n\n return (\n \n {children}\n \n );\n});\n\nToggleGroupItem.displayName = ToggleGroupPrimitive.Item.displayName;\n\nexport { ToggleGroup, ToggleGroupItem };\n","import { ColumnDef, SortDirection } from '@/components/advanced/data-table/data-table.component';\nimport { Button } from '@/components/shadcn-ui/button';\nimport { ToggleGroup, ToggleGroupItem } from '@/components/shadcn-ui/toggle-group';\nimport {\n ArrowDownIcon,\n ArrowUpDownIcon,\n ArrowUpIcon,\n CircleCheckIcon,\n CircleHelpIcon,\n CircleXIcon,\n} from 'lucide-react';\nimport { ReactNode } from 'react';\nimport { InventoryTableData, Status } from './inventory-utils';\n\n/**\n * Gets an icon that indicates the current sorting direction based on the provided input\n *\n * @param sortDirection Sorting direction. Can be ascending ('asc'), descending ('desc') or false (\n * i.e. not sorted)\n * @returns The appropriate sorting icon for the provided sorting direction\n */\nconst getSortingIcon = (sortDirection: false | SortDirection): ReactNode => {\n if (sortDirection === 'asc') {\n return ;\n }\n if (sortDirection === 'desc') {\n return ;\n }\n return ;\n};\n\n/**\n * Function that creates the item column for inventories\n *\n * @param itemLabel Localized label for the item column (e.g. 'Character', 'Repeated Word', etc.)\n * @returns Column that shows the inventory items. Should be used with the DataTable component\n */\nexport const inventoryItemColumn = (itemLabel: string): ColumnDef => {\n return {\n accessorKey: 'item',\n accessorFn: (row: InventoryTableData) => row.items[0],\n header: ({ column }) => (\n \n ),\n };\n};\n\n/**\n * Function that creates the additional item columns for inventories\n *\n * @param additionalItemLabel Localized label for the additional item column (e.g. 'Preceding\n * Marker')\n * @param additionalItemIndex Index that locates the desired item in the items array of the\n * inventory\n * @returns Column that shows additional inventory items. Should be used with the DataTable\n * component\n */\nexport const inventoryAdditionalItemColumn = (\n additionalItemLabel: string,\n additionalItemIndex: number,\n): ColumnDef => {\n return {\n accessorKey: `item${additionalItemIndex}`,\n accessorFn: (row: InventoryTableData) => row.items[additionalItemIndex],\n header: ({ column }) => (\n \n ),\n };\n};\n\n/**\n * Function that creates the count column for inventories. Should be used with the DataTable\n * component.\n *\n * @param itemLabel Localized label for the count column\n * @returns Column that shows the number of occurrences of the related inventory items\n */\nexport const inventoryCountColumn = (countLabel: string): ColumnDef => {\n return {\n accessorKey: 'count',\n header: ({ column }) => (\n
    \n \n
    \n ),\n cell: ({ row }) =>
    {row.getValue('count')}
    ,\n };\n};\n\n/**\n * Function that updates project settings when status for item(s) changes\n *\n * @param changedItems Array of items for which the status is being updated\n * @param newStatus The status that the items are being given\n * @param approvedItems Array of currently approved items\n * @param onApprovedItemsChange Callback function that stores the updated list of approved items\n * @param unapprovedItems Array of currently unapproved items\n * @param onUnapprovedItemsChange Callback function that stores the updated list of unapproved items\n */\nconst statusChangeHandler = (\n changedItems: string[],\n newStatus: Status,\n approvedItems: string[],\n onApprovedItemsChange: (items: string[]) => void,\n unapprovedItems: string[],\n onUnapprovedItemsChange: (items: string[]) => void,\n) => {\n let newApprovedItems: string[] = [...approvedItems];\n changedItems.forEach((item) => {\n if (newStatus === 'approved') {\n if (!newApprovedItems.includes(item)) {\n newApprovedItems.push(item);\n }\n } else {\n newApprovedItems = newApprovedItems.filter((validItem) => validItem !== item);\n }\n });\n onApprovedItemsChange(newApprovedItems);\n\n let newUnapprovedItems: string[] = [...unapprovedItems];\n changedItems.forEach((item) => {\n if (newStatus === 'unapproved') {\n if (!newUnapprovedItems.includes(item)) {\n newUnapprovedItems.push(item);\n }\n } else {\n newUnapprovedItems = newUnapprovedItems.filter((unapprovedItem) => unapprovedItem !== item);\n }\n });\n onUnapprovedItemsChange(newUnapprovedItems);\n};\n\n/**\n * Function that creates the status column for inventories. Should be used with the DataTable\n * component.\n *\n * @param statusLabel Localized label for the status column\n * @param approvedItems Array of approved items, typically as defined in `Settings.xml`\n * @param onApprovedItemsChange Callback function that stores the updated list of approved items\n * @param unapprovedItems Array of unapproved items, typically as defined in `Settings.xml`\n * @param onUnapprovedItemsChange Callback function that stores the updated list of unapproved items\n * @returns Column that shows the status buttons for the related inventory item. The button for the\n * current status of the item is selected\n */\nexport const inventoryStatusColumn = (\n statusLabel: string,\n approvedItems: string[],\n onApprovedItemsChange: (items: string[]) => void,\n unapprovedItems: string[],\n onUnapprovedItemsChange: (items: string[]) => void,\n): ColumnDef => {\n return {\n accessorKey: 'status',\n header: ({ column }) => {\n return (\n
    \n \n
    \n );\n },\n cell: ({ row }) => {\n const status: Status = row.getValue('status');\n const item: string = row.getValue('item');\n return (\n \n \n statusChangeHandler(\n [item],\n 'approved',\n approvedItems,\n onApprovedItemsChange,\n unapprovedItems,\n onUnapprovedItemsChange,\n )\n }\n value=\"approved\"\n >\n \n \n \n statusChangeHandler(\n [item],\n 'unapproved',\n approvedItems,\n onApprovedItemsChange,\n unapprovedItems,\n onUnapprovedItemsChange,\n )\n }\n value=\"unapproved\"\n >\n \n \n \n statusChangeHandler(\n [item],\n 'unknown',\n approvedItems,\n onApprovedItemsChange,\n unapprovedItems,\n onUnapprovedItemsChange,\n )\n }\n value=\"unknown\"\n >\n \n \n \n );\n },\n };\n};\n","import DataTable, {\n ColumnDef,\n RowContents,\n RowSelectionState,\n TableContents,\n} from '@/components/advanced/data-table/data-table.component';\nimport OccurrencesTable from '@/components/advanced/inventory/occurrences-table.component';\nimport Checkbox from '@/components/shadcn-ui/checkbox';\nimport { Input } from '@/components/shadcn-ui/input';\nimport { Label } from '@/components/shadcn-ui/label';\nimport {\n Select,\n SelectContent,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\nimport {\n deepEqual,\n LocalizedStringValue,\n ScriptureReference,\n substring,\n} from 'platform-bible-utils';\nimport { useEffect, useMemo, useState } from 'react';\nimport {\n getBookNumFromId,\n getLinesFromUSFM,\n getNumberFromUSFM,\n getStatusForItem,\n InventoryItemOccurrence,\n InventoryTableData,\n Status,\n} from './inventory-utils';\nimport { inventoryAdditionalItemColumn } from './inventory-columns';\n\n/**\n * Object containing all keys used for localization in this component. If you're using this\n * component in an extension, you can pass it into the useLocalizedStrings hook to easily obtain the\n * localized strings and pass them into the localizedStrings prop of this component\n */\nexport const INVENTORY_STRING_KEYS = Object.freeze([\n '%webView_inventory_all%',\n '%webView_inventory_approved%',\n '%webView_inventory_unapproved%',\n '%webView_inventory_unknown%',\n '%webView_inventory_scope_currentBook%',\n '%webView_inventory_scope_chapter%',\n '%webView_inventory_scope_verse%',\n '%webView_inventory_filter_text%',\n '%webView_inventory_show_additional_items%',\n '%webView_inventory_occurrences_table_header_reference%',\n '%webView_inventory_occurrences_table_header_occurrence%',\n] as const);\n\nexport type InventoryLocalizedStrings = {\n [localizedInventoryKey in (typeof INVENTORY_STRING_KEYS)[number]]?: LocalizedStringValue;\n};\n\n/** Scope of scripture that the inventory can operate on */\nexport type Scope = 'book' | 'chapter' | 'verse';\n\n/** Status values that the status filter can select from */\ntype StatusFilter = Status | 'all';\n\n/** Text labels for the inventory columns and the control components of additional inventory items */\ntype AdditionalItemsLabels = {\n checkboxText?: string;\n tableHeaders?: string[];\n};\n\n/**\n * Filters data that is shown in the DataTable section of the Inventory\n *\n * @param itemData All inventory items and their related information\n * @param statusFilter Allows filtering by status (i.e. show all items, or only items that are\n * 'approved', 'unapproved' or 'unknown')\n * @param textFilter Allows filtering by text. All items that include the filter text will be\n * selected.\n * @returns Array of items and their related information that are matched by the specified filters\n */\nconst filterItemData = (\n itemData: InventoryTableData[],\n statusFilter: StatusFilter,\n textFilter: string,\n): InventoryTableData[] => {\n let filteredItemData: InventoryTableData[] = itemData;\n\n if (statusFilter !== 'all') {\n filteredItemData = filteredItemData.filter(\n (item) =>\n (statusFilter === 'approved' && item.status === 'approved') ||\n (statusFilter === 'unapproved' && item.status === 'unapproved') ||\n (statusFilter === 'unknown' && item.status === 'unknown'),\n );\n }\n\n if (textFilter !== '')\n filteredItemData = filteredItemData.filter((item) => item.items[0].includes(textFilter));\n\n return filteredItemData;\n};\n\n/**\n * Turns array of strings into array of inventory items, along with their count and status\n *\n * @param text The source scripture text that is searched for inventory items\n * @param scriptureRef The scripture reference that the application is currently set to\n * @param approvedItems Array of approved items, typically as defined in `Settings.xml`\n * @param unapprovedItems Array of unapproved items, typically as defined in `Settings.xml`\n * @param itemRegex Regular expression that describes what items this Inventory should extract from\n * the provided scripture text\n * @returns Array of inventory items, along with their count and status\n */\nconst createTableData = (\n text: string | undefined,\n scriptureRef: ScriptureReference,\n approvedItems: string[],\n unapprovedItems: string[],\n itemRegex: RegExp,\n): InventoryTableData[] => {\n if (!text) return [];\n\n const tableData: InventoryTableData[] = [];\n\n let currentBook: number | undefined = scriptureRef.bookNum;\n let currentChapter: number | undefined = scriptureRef.chapterNum;\n let currentVerse: number | undefined = scriptureRef.verseNum;\n\n const lines = getLinesFromUSFM(text);\n\n lines.forEach((line: string) => {\n if (line.startsWith('\\\\id')) {\n currentBook = getBookNumFromId(line);\n currentChapter = 0;\n currentVerse = 0;\n }\n if (line.startsWith('\\\\c')) {\n currentChapter = getNumberFromUSFM(line);\n currentVerse = 0;\n }\n if (line.startsWith('\\\\v')) {\n currentVerse = getNumberFromUSFM(line);\n if (currentChapter === 0) {\n currentChapter = scriptureRef.chapterNum;\n }\n }\n\n let match: RegExpExecArray | undefined = itemRegex.exec(line) ?? undefined;\n while (match) {\n const items: string[] = [];\n match.forEach((item) => items.push(item));\n const itemIndex = match.index;\n const existingItem = tableData.find((tableEntry) => deepEqual(tableEntry.items, items));\n const newReference: InventoryItemOccurrence = {\n reference: {\n bookNum: currentBook !== undefined ? currentBook : -1,\n chapterNum: currentChapter !== undefined ? currentChapter : -1,\n verseNum: currentVerse !== undefined ? currentVerse : -1,\n },\n text: substring(line, Math.max(0, itemIndex - 25), Math.min(itemIndex + 25, line.length)),\n };\n if (existingItem) {\n existingItem.count += 1;\n existingItem.occurrences.push(newReference);\n } else {\n const newItem: InventoryTableData = {\n items,\n count: 1,\n status: getStatusForItem(items[0], approvedItems, unapprovedItems),\n occurrences: [newReference],\n };\n tableData.push(newItem);\n }\n\n match = itemRegex.exec(line) ?? undefined;\n }\n });\n\n return tableData;\n};\n\n/**\n * Gets the localized value for the provided key\n *\n * @param strings Object containing localized string\n * @param key Key for a localized string\n * @returns The localized value for the provided key, if available. Returns the key if no localized\n * value is available\n */\nconst localizeString = (\n strings: InventoryLocalizedStrings,\n key: keyof InventoryLocalizedStrings,\n) => {\n return strings[key] ?? key;\n};\n\n/** Props for the Inventory component */\ntype InventoryProps = {\n /** The scripture reference that the application is currently set to */\n scriptureReference: ScriptureReference;\n /** Callback function that is executed when the scripture reference is changed */\n setScriptureReference: (scriptureReference: ScriptureReference) => void;\n /**\n * Object with all localized strings that the Inventory needs to work well across multiple\n * languages. When using this component with Platform.Bible, you can import\n * `INVENTORY_STRING_KEYS` from this library, pass it in to the Platform's localization hook, and\n * pass the localized keys that are returned by the hook into this prop.\n */\n localizedStrings: InventoryLocalizedStrings;\n /**\n * The logic that finds the desired items in the source text. This can either be a Regular\n * expression that captures one or multiple items (preferred), or a custom function that builds\n * and return an InventoryDataTable[] manually. Note: In case the logic captures more than one\n * item (i.e. InventoryTableData.items has a length greater than 1), you must provide text labels\n * for the related columns and control elements to show by setting the `additionalItemsLabels`\n * prop\n */\n extractItems:\n | RegExp\n | ((\n text: string | undefined,\n scriptureRef: ScriptureReference,\n approvedItems: string[],\n unapprovedItems: string[],\n ) => InventoryTableData[]);\n /**\n * Text labels for control elements and additional column headers in case your Inventory has more\n * than one item to show (e.g. The 'Preceding Marker' in the Markers Inventory)\n */\n additionalItemsLabels?: AdditionalItemsLabels;\n /** Array of approved items, typically as defined in `Settings.xml` */\n approvedItems: string[];\n /** Array of unapproved items, typically as defined in `Settings.xml` */\n unapprovedItems: string[];\n /** The source scripture text that is searched for in inventory items */\n text: string | undefined;\n /** Scope of scripture that the inventory will operate on */\n scope: Scope;\n /** Callback function that is executed when the scope is changed from the Inventory */\n onScopeChange: (scope: Scope) => void;\n /**\n * Column definitions for the Inventory data table. The most commonly used column definitions are\n * pre-configured for your convenience and can be imported (e.g. inventoryItemColumn,\n * inventoryAdditionalItemColumn inventoryCountColumn, and inventoryStatusColumn). If you need any\n * other columns you can add these yourself\n */\n columns: ColumnDef[];\n};\n\n/** Inventory component that is used to view and control the status of provided project settings */\nexport default function Inventory({\n scriptureReference,\n setScriptureReference,\n localizedStrings,\n extractItems,\n additionalItemsLabels,\n approvedItems,\n unapprovedItems,\n text,\n scope,\n onScopeChange,\n columns,\n}: InventoryProps) {\n const allItemsText = localizeString(localizedStrings, '%webView_inventory_all%');\n const approvedItemsText = localizeString(localizedStrings, '%webView_inventory_approved%');\n const unapprovedItemsText = localizeString(localizedStrings, '%webView_inventory_unapproved%');\n const unknownItemsText = localizeString(localizedStrings, '%webView_inventory_unknown%');\n const scopeBookText = localizeString(localizedStrings, '%webView_inventory_scope_currentBook%');\n const scopeChapterText = localizeString(localizedStrings, '%webView_inventory_scope_chapter%');\n const scopeVerseText = localizeString(localizedStrings, '%webView_inventory_scope_verse%');\n const filterText = localizeString(localizedStrings, '%webView_inventory_filter_text%');\n const showAdditionalItemsText = localizeString(\n localizedStrings,\n '%webView_inventory_show_additional_items%',\n );\n\n const [showAdditionalItems, setShowAdditionalItems] = useState(false);\n const [statusFilter, setStatusFilter] = useState('all');\n const [textFilter, setTextFilter] = useState('');\n const [selectedItem, setSelectedItem] = useState([]);\n\n const tableData: InventoryTableData[] = useMemo(() => {\n if (!text) return [];\n if (extractItems instanceof RegExp)\n return createTableData(\n text,\n scriptureReference,\n approvedItems,\n unapprovedItems,\n extractItems,\n );\n return extractItems(text, scriptureReference, approvedItems, unapprovedItems);\n }, [text, extractItems, scriptureReference, approvedItems, unapprovedItems]);\n\n const reducedTableData: InventoryTableData[] = useMemo(() => {\n if (showAdditionalItems) return tableData;\n\n const newTableData: InventoryTableData[] = [];\n\n tableData.forEach((tableEntry) => {\n const firstItem = tableEntry.items[0];\n\n const existingEntry = newTableData.find(\n (newTableEntry) => newTableEntry.items[0] === firstItem,\n );\n\n if (existingEntry) {\n existingEntry.count += tableEntry.count;\n existingEntry.occurrences = existingEntry.occurrences.concat(tableEntry.occurrences);\n } else {\n newTableData.push({\n items: [firstItem],\n count: tableEntry.count,\n occurrences: tableEntry.occurrences,\n status: tableEntry.status,\n });\n }\n });\n\n return newTableData;\n }, [showAdditionalItems, tableData]);\n\n const filteredTableData: InventoryTableData[] = useMemo(() => {\n return filterItemData(reducedTableData, statusFilter, textFilter);\n }, [reducedTableData, statusFilter, textFilter]);\n\n const allColumns: ColumnDef[] = useMemo(() => {\n if (!showAdditionalItems) return columns;\n\n const numberOfAdditionalItems = additionalItemsLabels?.tableHeaders?.length;\n if (!numberOfAdditionalItems) return columns;\n\n const additionalColumns: ColumnDef[] = [];\n\n for (let index = 0; index < numberOfAdditionalItems; index++) {\n additionalColumns.push(\n inventoryAdditionalItemColumn(\n additionalItemsLabels?.tableHeaders?.[index] || 'Additional Item',\n index + 1,\n ),\n );\n }\n\n return [...additionalColumns, ...columns];\n }, [additionalItemsLabels?.tableHeaders, columns, showAdditionalItems]);\n\n useEffect(() => {\n setSelectedItem([]);\n }, [filteredTableData]);\n\n const rowClickHandler = (\n row: RowContents,\n table: TableContents,\n ) => {\n table.setRowSelection(() => {\n const newSelection: RowSelectionState = {};\n newSelection[row.index] = true;\n return newSelection;\n });\n\n setSelectedItem(row.original.items);\n };\n\n const handleScopeChange = (value: string) => {\n if (value === 'book' || value === 'chapter' || value === 'verse') {\n onScopeChange(value);\n } else {\n throw new Error(`Invalid scope value: ${value}`);\n }\n };\n\n const handleStatusFilterChange = (value: string) => {\n if (value === 'all' || value === 'approved' || value === 'unapproved' || value === 'unknown') {\n setStatusFilter(value);\n } else {\n throw new Error(`Invalid status filter value: ${value}`);\n }\n };\n\n const occurrenceData: InventoryItemOccurrence[] = useMemo(() => {\n if (reducedTableData.length === 0 || selectedItem.length === 0) return [];\n const occurrence = reducedTableData.filter((tableEntry: InventoryTableData) => {\n return deepEqual(\n showAdditionalItems ? tableEntry.items : [tableEntry.items[0]],\n selectedItem,\n );\n });\n if (occurrence.length > 1) throw new Error('Selected item is not unique');\n return occurrence[0].occurrences;\n }, [selectedItem, showAdditionalItems, reducedTableData]);\n\n return (\n
    \n
    \n handleStatusFilterChange(value)}\n defaultValue={statusFilter}\n >\n \n \n \n \n {allItemsText}\n {approvedItemsText}\n {unapprovedItemsText}\n {unknownItemsText}\n \n \n \n {\n setTextFilter(event.target.value);\n }}\n />\n {additionalItemsLabels && (\n
    \n {\n setSelectedItem([]);\n setShowAdditionalItems(checked);\n }}\n />\n \n
    \n )}\n
    \n
    \n \n
    \n {occurrenceData.length > 0 && (\n
    \n \n
    \n )}\n
    \n );\n}\n","import { Input } from '@/components/shadcn-ui/input';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { useState } from 'react';\n\n/** Props for the SearchBar component. */\nexport type SearchBarProps = {\n /** Additional css classes to help with unique styling of the search bar */\n className?: string;\n /**\n * Callback fired to handle the search query when button pressed\n *\n * @param searchQuery\n */\n onSearch: (searchQuery: string) => void;\n\n /** Optional string that appears in the search bar without a search string */\n placeholder?: string;\n\n /** Optional boolean to set the input base to full width */\n isFullWidth?: boolean;\n};\n\nexport default function SearchBar({\n className,\n onSearch,\n placeholder,\n isFullWidth,\n}: SearchBarProps) {\n const [searchQuery, setSearchQuery] = useState('');\n\n const handleInputChange = (searchString: string) => {\n setSearchQuery(searchString);\n onSearch(searchString);\n };\n\n return (\n handleInputChange(e.target.value)}\n />\n );\n}\n","// adapted from: https://github.com/shadcn-ui/ui/discussions/752\n\n'use client';\n\nimport { TabsContentProps, TabsListProps, TabsTriggerProps } from '@/components/shadcn-ui/tabs';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport * as TabsPrimitive from '@radix-ui/react-tabs';\nimport React from 'react';\n\nexport type VerticalTabsProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport type LeftTabsTriggerProps = TabsTriggerProps & {\n value: string;\n ref?: React.Ref;\n};\n\nexport const VerticalTabs = React.forwardRef<\n React.ElementRef,\n VerticalTabsProps\n>(({ className, ...props }, ref) => (\n \n));\n\nVerticalTabs.displayName = TabsPrimitive.List.displayName;\n\nexport const VerticalTabsList = React.forwardRef<\n React.ElementRef,\n TabsListProps\n>(({ className, ...props }, ref) => (\n \n));\nVerticalTabsList.displayName = TabsPrimitive.List.displayName;\n\nexport const VerticalTabsTrigger = React.forwardRef<\n React.ElementRef,\n LeftTabsTriggerProps\n>(({ className, ...props }, ref) => (\n \n));\n\nexport const VerticalTabsContent = React.forwardRef<\n React.ElementRef,\n TabsContentProps\n>(({ className, ...props }, ref) => (\n \n));\nVerticalTabsContent.displayName = TabsPrimitive.Content.displayName;\n","import SearchBar from '@/components/basics/search-bar.component';\nimport {\n VerticalTabs,\n VerticalTabsContent,\n VerticalTabsList,\n VerticalTabsTrigger,\n} from '@/components/basics/tabs-vertical';\nimport { ReactNode } from 'react';\n\nexport type TabKeyValueContent = {\n key: string;\n value: string;\n content: ReactNode;\n};\n\nexport type TabNavigationContentSearchProps = {\n /** List of values and keys for each tab this component should provide */\n tabList: TabKeyValueContent[];\n\n /** Handler to run when the value of the search bar changes */\n onSearch: (searchQuery: string) => void;\n\n /** Optional placeholder for the search bar */\n searchPlaceholder?: string;\n\n /** Optional title to include in the header */\n headerTitle?: string;\n\n /** Optional flag to make the search bar appear full width */\n isSearchBarFullWidth?: boolean;\n\n /** Text direction ltr or rtl */\n direction?: 'ltr' | 'rtl';\n};\n\nexport default function TabNavigationContentSearch({\n tabList,\n onSearch,\n searchPlaceholder,\n headerTitle,\n isSearchBarFullWidth = false,\n direction = 'ltr',\n}: TabNavigationContentSearchProps) {\n return (\n
    \n
    \n {headerTitle ?

    {headerTitle}

    : ''}\n \n
    \n \n \n {tabList.map((tab) => (\n \n {tab.value}\n \n ))}\n \n {tabList.map((tab) => (\n \n {tab.content}\n \n ))}\n \n
    \n );\n}\n","import React from 'react';\nimport * as SeparatorPrimitive from '@radix-ui/react-separator';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Separator = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, orientation = 'horizontal', decorative = true, ...props }, ref) => (\n \n));\nSeparator.displayName = SeparatorPrimitive.Root.displayName;\n\nexport { Separator };\n","import React from 'react';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nfunction Skeleton({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\n\nexport { Skeleton };\n","import React from 'react';\nimport * as TooltipPrimitive from '@radix-ui/react-tooltip';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst TooltipProvider = TooltipPrimitive.Provider;\n\nconst Tooltip = TooltipPrimitive.Root;\n\nconst TooltipTrigger = TooltipPrimitive.Trigger;\n\nconst TooltipContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, sideOffset = 4, ...props }, ref) => (\n \n));\nTooltipContent.displayName = TooltipPrimitive.Content.displayName;\n\nexport { Tooltip, TooltipTrigger, TooltipContent, TooltipProvider };\n","import React from 'react';\nimport { Slot } from '@radix-ui/react-slot';\nimport { VariantProps, cva } from 'class-variance-authority';\nimport { PanelLeft } from 'lucide-react';\n\nimport { Button } from '@/components/shadcn-ui/button';\nimport { Input } from '@/components/shadcn-ui/input';\nimport { Separator } from '@/components/shadcn-ui/separator';\nimport { Skeleton } from '@/components/shadcn-ui/skeleton';\nimport {\n Tooltip,\n TooltipContent,\n TooltipProvider,\n TooltipTrigger,\n} from '@/components/shadcn-ui/tooltip';\nimport { cn } from '@/utils/shadcn-ui.util';\n\n/**\n * Changes from the original code from Shadcn- Removed uses of useIsMobile, Sheet, and SheetContent.\n * Also removed the parts setting COOKIES.\n */\n\nconst SIDEBAR_WIDTH = '16rem';\nconst SIDEBAR_WIDTH_ICON = '3rem';\nconst SIDEBAR_KEYBOARD_SHORTCUT = 'b';\n\ntype SidebarContextProps = {\n state: 'expanded' | 'collapsed';\n open: boolean;\n setOpen: (open: boolean) => void;\n toggleSidebar: () => void;\n};\n\nconst SidebarContext = React.createContext(undefined);\n\nfunction useSidebar() {\n const context = React.useContext(SidebarContext);\n if (!context) {\n throw new Error('useSidebar must be used within a SidebarProvider.');\n }\n\n return context;\n}\n\nconst SidebarProvider = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & {\n defaultOpen?: boolean;\n open?: boolean;\n onOpenChange?: (open: boolean) => void;\n }\n>(\n (\n {\n defaultOpen = true,\n open: openProp,\n onOpenChange: setOpenProp,\n className,\n style,\n children,\n ...props\n },\n ref,\n ) => {\n // This is the internal state of the sidebar.\n // We use openProp and setOpenProp for control from outside the component.\n const [_open, _setOpen] = React.useState(defaultOpen);\n const isOpen = openProp ?? _open;\n const setOpen = React.useCallback(\n (value: boolean | ((value: boolean) => boolean)) => {\n const openState = typeof value === 'function' ? value(isOpen) : value;\n if (setOpenProp) {\n setOpenProp(openState);\n } else {\n _setOpen(openState);\n }\n },\n [setOpenProp, isOpen],\n );\n\n // Helper to toggle the sidebar.\n const toggleSidebar = React.useCallback(() => {\n return setOpen((open) => !open);\n }, [setOpen]);\n\n // Adds a keyboard shortcut to toggle the sidebar.\n React.useEffect(() => {\n const handleKeyDown = (event: KeyboardEvent) => {\n if (event.key === SIDEBAR_KEYBOARD_SHORTCUT && (event.metaKey || event.ctrlKey)) {\n event.preventDefault();\n toggleSidebar();\n }\n };\n\n window.addEventListener('keydown', handleKeyDown);\n return () => window.removeEventListener('keydown', handleKeyDown);\n }, [toggleSidebar]);\n\n // We add a state so that we can do data-state=\"expanded\" or \"collapsed\".\n // This makes it easier to style the sidebar with Tailwind classes.\n const state = isOpen ? 'expanded' : 'collapsed';\n\n const contextValue = React.useMemo(\n () => ({\n state,\n open: isOpen,\n setOpen,\n toggleSidebar,\n }),\n [state, isOpen, setOpen, toggleSidebar],\n );\n\n return (\n \n \n \n {children}\n
    \n \n \n );\n },\n);\nSidebarProvider.displayName = 'SidebarProvider';\n\nconst Sidebar = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & {\n side?: 'left' | 'right';\n variant?: 'sidebar' | 'floating' | 'inset';\n collapsible?: 'offcanvas' | 'icon' | 'none';\n }\n>(\n (\n {\n side = 'left',\n variant = 'sidebar',\n collapsible = 'offcanvas',\n className,\n children,\n ...props\n },\n ref,\n ) => {\n const { state } = useSidebar();\n\n if (collapsible === 'none') {\n return (\n \n {children}\n
    \n );\n }\n\n return (\n \n {/* This is what handles the sidebar gap on desktop */}\n \n \n \n {children}\n
    \n
    \n
    \n );\n },\n);\nSidebar.displayName = 'Sidebar';\n\nconst SidebarTrigger = React.forwardRef<\n React.ElementRef,\n React.ComponentProps\n>(({ className, onClick, ...props }, ref) => {\n const { toggleSidebar } = useSidebar();\n\n return (\n {\n onClick?.(event);\n toggleSidebar();\n }}\n {...props}\n >\n \n Toggle Sidebar\n \n );\n});\nSidebarTrigger.displayName = 'SidebarTrigger';\n\nconst SidebarRail = React.forwardRef>(\n ({ className, ...props }, ref) => {\n const { toggleSidebar } = useSidebar();\n\n return (\n \n );\n },\n);\nSidebarRail.displayName = 'SidebarRail';\n\nconst SidebarInset = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarInset.displayName = 'SidebarInset';\n\nconst SidebarInput = React.forwardRef<\n React.ElementRef,\n React.ComponentProps\n>(({ className, ...props }, ref) => {\n return (\n \n );\n});\nSidebarInput.displayName = 'SidebarInput';\n\nconst SidebarHeader = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarHeader.displayName = 'SidebarHeader';\n\nconst SidebarFooter = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarFooter.displayName = 'SidebarFooter';\n\nconst SidebarSeparator = React.forwardRef<\n React.ElementRef,\n React.ComponentProps\n>(({ className, ...props }, ref) => {\n return (\n \n );\n});\nSidebarSeparator.displayName = 'SidebarSeparator';\n\nconst SidebarContent = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarContent.displayName = 'SidebarContent';\n\nconst SidebarGroup = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarGroup.displayName = 'SidebarGroup';\n\nconst SidebarGroupLabel = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & { asChild?: boolean }\n>(({ className, asChild = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'div';\n\n return (\n svg]:tw-size-4 [&>svg]:tw-shrink-0',\n 'group-data-[collapsible=icon]:tw--mt-8 group-data-[collapsible=icon]:tw-opacity-0',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarGroupLabel.displayName = 'SidebarGroupLabel';\n\nconst SidebarGroupAction = React.forwardRef<\n HTMLButtonElement,\n React.ComponentProps<'button'> & { asChild?: boolean }\n>(({ className, asChild = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'button';\n\n return (\n svg]:tw-size-4 [&>svg]:tw-shrink-0',\n // Increases the hit area of the button on mobile.\n 'after:tw-absolute after:tw--inset-2 after:md:tw-hidden',\n 'group-data-[collapsible=icon]:tw-hidden',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarGroupAction.displayName = 'SidebarGroupAction';\n\nconst SidebarGroupContent = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarGroupContent.displayName = 'SidebarGroupContent';\n\nconst SidebarMenu = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenu.displayName = 'SidebarMenu';\n\nconst SidebarMenuItem = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenuItem.displayName = 'SidebarMenuItem';\n\nconst sidebarMenuButtonVariants = cva(\n // Removed data-[active=true]:tw-bg-sidebar-accent\n 'tw-peer/menu-button tw-flex tw-w-full tw-items-center tw-gap-2 tw-overflow-hidden tw-rounded-md tw-p-2 tw-text-left tw-text-sm tw-outline-none tw-ring-sidebar-ring tw-transition-[width,height,padding] hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground focus-visible:tw-ring-2 active:tw-bg-sidebar-accent active:tw-text-sidebar-accent-foreground disabled:tw-pointer-events-none disabled:tw-opacity-50 tw-group-has-[[data-sidebar=menu-action]]/menu-item:pr-8 aria-disabled:tw-pointer-events-none aria-disabled:tw-opacity-50 data-[active=true]:tw-font-medium data-[active=true]:tw-text-sidebar-accent-foreground data-[state=open]:hover:tw-bg-sidebar-accent data-[state=open]:hover:tw-text-sidebar-accent-foreground group-data-[collapsible=icon]:tw-!size-8 group-data-[collapsible=icon]:tw-!p-2 [&>span:last-child]:tw-truncate [&>svg]:tw-size-4 [&>svg]:tw-shrink-0',\n {\n variants: {\n variant: {\n default: 'hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground',\n outline:\n 'tw-bg-background tw-shadow-[0_0_0_1px_hsl(var(--sidebar-border))] hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground hover:tw-shadow-[0_0_0_1px_hsl(var(--sidebar-accent))]',\n },\n size: {\n default: 'tw-h-8 tw-text-sm',\n sm: 'tw-h-7 tw-text-xs',\n lg: 'tw-h-12 tw-text-sm group-data-[collapsible=icon]:tw-!p-0',\n },\n },\n defaultVariants: {\n variant: 'default',\n size: 'default',\n },\n },\n);\n\nconst SidebarMenuButton = React.forwardRef<\n HTMLButtonElement,\n React.ComponentProps<'button'> & {\n asChild?: boolean;\n isActive?: boolean;\n tooltip?: string | React.ComponentProps;\n } & VariantProps\n>(\n (\n {\n asChild = false,\n isActive = false,\n variant = 'default',\n size = 'default',\n tooltip,\n className,\n ...props\n },\n ref,\n ) => {\n const Comp = asChild ? Slot : 'button';\n const { state } = useSidebar();\n\n const button = (\n \n );\n\n if (!tooltip) {\n return button;\n }\n\n if (typeof tooltip === 'string') {\n // eslint-disable-next-line no-param-reassign\n tooltip = {\n children: tooltip,\n };\n }\n\n return (\n \n {button}\n \n );\n },\n);\nSidebarMenuButton.displayName = 'SidebarMenuButton';\n\nconst SidebarMenuAction = React.forwardRef<\n HTMLButtonElement,\n React.ComponentProps<'button'> & {\n asChild?: boolean;\n showOnHover?: boolean;\n }\n>(({ className, asChild = false, showOnHover = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'button';\n\n return (\n svg]:tw-size-4 [&>svg]:tw-shrink-0',\n // Increases the hit area of the button on mobile.\n 'after:tw-absolute after:tw--inset-2 after:md:tw-hidden',\n 'tw-peer-data-[size=sm]/menu-button:top-1',\n 'tw-peer-data-[size=default]/menu-button:top-1.5',\n 'tw-peer-data-[size=lg]/menu-button:top-2.5',\n 'group-data-[collapsible=icon]:tw-hidden',\n showOnHover &&\n 'tw-group-focus-within/menu-item:opacity-100 tw-group-hover/menu-item:opacity-100 tw-peer-data-[active=true]/menu-button:text-sidebar-accent-foreground data-[state=open]:tw-opacity-100 md:tw-opacity-0',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarMenuAction.displayName = 'SidebarMenuAction';\n\nconst SidebarMenuBadge = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenuBadge.displayName = 'SidebarMenuBadge';\n\nconst SidebarMenuSkeleton = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & {\n showIcon?: boolean;\n }\n>(({ className, showIcon = false, ...props }, ref) => {\n // Random width between 50 to 90%.\n const width = React.useMemo(() => {\n return `${Math.floor(Math.random() * 40) + 50}%`;\n }, []);\n\n return (\n \n {showIcon && (\n \n )}\n \n
    \n );\n});\nSidebarMenuSkeleton.displayName = 'SidebarMenuSkeleton';\n\nconst SidebarMenuSub = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenuSub.displayName = 'SidebarMenuSub';\n\nconst SidebarMenuSubItem = React.forwardRef>(\n ({ ...props }, ref) =>
  • ,\n);\nSidebarMenuSubItem.displayName = 'SidebarMenuSubItem';\n\nconst SidebarMenuSubButton = React.forwardRef<\n HTMLAnchorElement,\n React.ComponentProps<'a'> & {\n asChild?: boolean;\n size?: 'sm' | 'md';\n isActive?: boolean;\n }\n>(({ asChild = false, size = 'md', isActive, className, ...props }, ref) => {\n const Comp = asChild ? Slot : 'a';\n\n return (\n span:last-child]:tw-truncate [&>svg]:tw-size-4 [&>svg]:tw-shrink-0 [&>svg]:tw-text-sidebar-accent-foreground',\n 'data-[active=true]:tw-bg-sidebar-accent data-[active=true]:tw-text-sidebar-accent-foreground',\n size === 'sm' && 'tw-text-xs',\n size === 'md' && 'tw-text-sm',\n 'group-data-[collapsible=icon]:tw-hidden',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarMenuSubButton.displayName = 'SidebarMenuSubButton';\n\nexport {\n Sidebar,\n SidebarContent,\n SidebarFooter,\n SidebarGroup,\n SidebarGroupAction,\n SidebarGroupContent,\n SidebarGroupLabel,\n SidebarHeader,\n SidebarInput,\n SidebarInset,\n SidebarMenu,\n SidebarMenuAction,\n SidebarMenuBadge,\n SidebarMenuButton,\n SidebarMenuItem,\n SidebarMenuSkeleton,\n SidebarMenuSub,\n SidebarMenuSubButton,\n SidebarMenuSubItem,\n SidebarProvider,\n SidebarRail,\n SidebarSeparator,\n SidebarTrigger,\n useSidebar,\n};\n","import ComboBox, { ComboBoxOption } from '@/components/basics/combo-box.component';\nimport {\n Sidebar,\n SidebarContent,\n SidebarGroup,\n SidebarGroupLabel,\n SidebarGroupContent,\n SidebarMenu,\n SidebarMenuItem,\n SidebarMenuButton,\n} from '@/components/shadcn-ui/sidebar';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { useCallback } from 'react';\n\nexport type SelectedSettingsSidebarItem = {\n label: string;\n projectId?: string;\n};\n\nexport type ProjectInfo = { projectId: string; projectName: string };\n\nexport type SettingsSidebarProps = {\n /** Optional id for testing */\n id?: string;\n\n /** Extension labels from contribution */\n extensionLabels: string[];\n\n /** Project names and ids */\n projectInfo: ProjectInfo[];\n\n /** Handler for selecting a sidebar item */\n handleSelectSidebarItem: (key: string, projectId?: string) => void;\n\n /** The current selected value in the sidebar */\n selectedSidebarItem: SelectedSettingsSidebarItem;\n\n /** Label for the group of extensions setting groups */\n extensionsSidebarGroupLabel: string;\n\n /** Label for the group of projects settings */\n projectsSidebarGroupLabel: string;\n\n /** Placeholder text for the button */\n buttonPlaceholderText: string;\n};\n\nexport default function SettingsSidebar({\n id,\n extensionLabels,\n projectInfo,\n handleSelectSidebarItem,\n selectedSidebarItem,\n extensionsSidebarGroupLabel,\n projectsSidebarGroupLabel,\n buttonPlaceholderText,\n}: SettingsSidebarProps) {\n const handleSelectItem = useCallback(\n (item: string, projectId?: string) => {\n handleSelectSidebarItem(item, projectId);\n },\n [handleSelectSidebarItem],\n );\n\n const getProjectNameFromProjectId = useCallback(\n (projectId: string) => {\n const project = projectInfo.find((info) => info.projectId === projectId);\n return project ? project.projectName : projectId;\n },\n [projectInfo],\n );\n\n const getIsActive: (label: string) => boolean = useCallback(\n (label: string) => !selectedSidebarItem.projectId && label === selectedSidebarItem.label,\n [selectedSidebarItem],\n );\n\n return (\n \n \n \n \n {extensionsSidebarGroupLabel}\n \n \n \n {extensionLabels.map((label) => (\n \n handleSelectItem(label)}\n isActive={getIsActive(label)}\n >\n {label}\n \n \n ))}\n \n \n \n \n \n {projectsSidebarGroupLabel}\n \n \n info.projectId)}\n getOptionLabel={(projectId: ComboBoxOption) => {\n // This function expects a ComboBoxOption, but we know it is a string\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n return getProjectNameFromProjectId(projectId as string);\n }}\n buttonPlaceholder={buttonPlaceholderText}\n onChange={(projectId: string) => {\n const selectedProjectName = getProjectNameFromProjectId(projectId);\n handleSelectItem(selectedProjectName, projectId);\n }}\n value={selectedSidebarItem?.projectId ?? undefined}\n />\n \n \n \n \n );\n}\n","import { SidebarInset, SidebarProvider } from '@/components/shadcn-ui/sidebar';\nimport { PropsWithChildren } from 'react';\nimport SearchBar from '@/components/basics/search-bar.component';\nimport SettingsSidebar, { SettingsSidebarProps } from './settings-sidebar.component';\n\nexport type SettingsSidebarContentSearchProps = SettingsSidebarProps &\n PropsWithChildren & {\n /** Optional id for testing */\n id?: string;\n\n /** Handler to run when the value of the search bar changes */\n onSearch: (searchQuery: string) => void;\n };\n\nexport default function SettingsSidebarContentSearch({\n id,\n extensionLabels,\n projectInfo,\n children,\n handleSelectSidebarItem,\n selectedSidebarItem,\n onSearch,\n extensionsSidebarGroupLabel,\n projectsSidebarGroupLabel,\n buttonPlaceholderText,\n}: SettingsSidebarContentSearchProps) {\n return (\n
    \n
    \n \n
    \n \n \n {children}\n \n
    \n );\n}\n","import { Button } from '@/components/shadcn-ui/button';\nimport {\n Select,\n SelectContent,\n SelectGroup,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\nimport {\n Table,\n TableBody,\n TableCell,\n TableHead,\n TableHeader,\n TableRow,\n} from '@/components/shadcn-ui/table';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Canon } from '@sillsdev/scripture';\nimport {\n Cell,\n ColumnDef,\n flexRender,\n getCoreRowModel,\n getExpandedRowModel,\n getGroupedRowModel,\n getSortedRowModel,\n GroupingState,\n Row,\n RowSelectionState,\n SortingState,\n useReactTable,\n} from '@tanstack/react-table';\nimport '@/components/advanced/scripture-results-viewer/scripture-results-viewer.component.css';\nimport {\n compareScrRefs,\n formatScrRef,\n ScriptureSelection,\n scrRefToBBBCCCVVV,\n} from 'platform-bible-utils';\nimport { MouseEvent, useEffect, useMemo, useState } from 'react';\nimport { ChevronDown, ChevronLeft, ChevronRight } from 'lucide-react';\n\n/**\n * Information (e.g., a checking error or some other type of \"transient\" annotation) about something\n * noteworthy at a specific place in an instance of the Scriptures.\n */\nexport type ScriptureItemDetail = ScriptureSelection & {\n /**\n * Text of the error, note, etc. In the future, we might want to support something more than just\n * text so that a JSX element could be provided with a link or some other controls related to the\n * issue being reported.\n */\n detail: string;\n};\n\n/**\n * A uniquely identifiable source of results that can be displayed in the ScriptureResultsViewer.\n * Generally, the source will be a particular Scripture check, but there may be other types of\n * sources.\n */\nexport type ResultsSource = {\n /**\n * Uniquely identifies the source.\n *\n * @type {string}\n */\n id: string;\n\n /**\n * Name (potentially localized) of the source, suitable for display in the UI.\n *\n * @type {string}\n */\n displayName: string;\n};\n\nexport type ScriptureSrcItemDetail = ScriptureItemDetail & {\n /** Source/type of detail. Can be used for grouping. */\n source: ResultsSource;\n};\n\n/**\n * Represents a set of results keyed by Scripture reference. Generally, the source will be a\n * particular Scripture check, but this type also allows for other types of uniquely identifiable\n * sources.\n */\nexport type ResultsSet = {\n /**\n * The backing source associated with this set of results.\n *\n * @type {ResultsSource}\n */\n source: ResultsSource;\n\n /**\n * Array of Scripture item details (messages keyed by Scripture reference).\n *\n * @type {ScriptureItemDetail[]}\n */\n data: ScriptureItemDetail[];\n};\n\nconst scrBookColId = 'scrBook';\nconst scrRefColId = 'scrRef';\nconst typeColId = 'source';\nconst detailsColId = 'details';\n\nconst defaultScrRefColumnName = 'Scripture Reference';\nconst defaultScrBookGroupName = 'Scripture Book';\nconst defaultTypeColumnName = 'Type';\nconst defaultDetailsColumnName = 'Details';\n\nexport type ScriptureResultsViewerColumnInfo = {\n /** Optional header to display for the Reference column. Default value: 'Scripture Reference'. */\n scriptureReferenceColumnName?: string;\n\n /** Optional text to display to refer to the Scripture book group. Default value: 'Scripture Book'. */\n scriptureBookGroupName?: string;\n\n /** Optional header to display for the Type column. Default value: 'Type'. */\n typeColumnName?: string;\n\n /** Optional header to display for the Details column. Default value: 'Details' */\n detailsColumnName?: string;\n};\n\nexport type ScriptureResultsViewerProps = ScriptureResultsViewerColumnInfo & {\n /** Groups of ScriptureItemDetail objects from particular sources (e.g., Scripture checks) */\n sources: ResultsSet[];\n\n /** Flag indicating whether to display column headers. Default is false. */\n showColumnHeaders?: boolean;\n\n /** Flag indicating whether to display source column. Default is false. */\n showSourceColumn?: boolean;\n\n /** Callback function to notify when a row is selected */\n onRowSelected?: (selectedRow: ScriptureSrcItemDetail | undefined) => void;\n\n /** Text direction ltr or rtl */\n direction?: 'ltr' | 'rtl';\n};\n\nfunction getColumns(\n colInfo?: ScriptureResultsViewerColumnInfo,\n showSourceColumn?: boolean,\n): ColumnDef[] {\n const showSrcCol = showSourceColumn ?? false;\n return [\n {\n accessorFn: (row) =>\n `${Canon.bookNumberToId(row.start.bookNum)} ${row.start.chapterNum}:${row.start.verseNum}`,\n id: scrBookColId,\n header: colInfo?.scriptureReferenceColumnName ?? defaultScrRefColumnName,\n cell: (info) => {\n const row = info.row.original;\n if (info.row.getIsGrouped()) {\n return Canon.bookNumberToEnglishName(row.start.bookNum);\n }\n return info.row.groupingColumnId === scrBookColId ? formatScrRef(row.start) : undefined;\n },\n getGroupingValue: (row) => row.start.bookNum,\n sortingFn: (a, b) => {\n return compareScrRefs(a.original.start, b.original.start);\n },\n enableGrouping: true,\n },\n {\n accessorFn: (row) => formatScrRef(row.start),\n id: scrRefColId,\n header: undefined,\n cell: (info) => {\n const row = info.row.original;\n return info.row.getIsGrouped() ? undefined : formatScrRef(row.start);\n },\n sortingFn: (a, b) => {\n return compareScrRefs(a.original.start, b.original.start);\n },\n enableGrouping: false,\n },\n {\n accessorFn: (row) => row.source.displayName,\n id: typeColId,\n header: showSrcCol ? (colInfo?.typeColumnName ?? defaultTypeColumnName) : undefined,\n cell: (info) => (showSrcCol || info.row.getIsGrouped() ? info.getValue() : undefined),\n getGroupingValue: (row) => row.source.id,\n sortingFn: (a, b) =>\n a.original.source.displayName.localeCompare(b.original.source.displayName),\n enableGrouping: true,\n },\n {\n accessorFn: (row) => row.detail,\n id: detailsColId,\n header: colInfo?.detailsColumnName ?? defaultDetailsColumnName,\n cell: (info) => info.getValue(),\n enableGrouping: false,\n },\n ];\n}\n\nconst toRefOrRange = (scriptureSelection: ScriptureSelection) => {\n if (!('offset' in scriptureSelection.start))\n throw new Error('No offset available in range start');\n if (scriptureSelection.end && !('offset' in scriptureSelection.end))\n throw new Error('No offset available in range end');\n const { offset: offsetStart } = scriptureSelection.start;\n let offsetEnd: number = 0;\n if (scriptureSelection.end) ({ offset: offsetEnd } = scriptureSelection.end);\n if (\n !scriptureSelection.end ||\n compareScrRefs(scriptureSelection.start, scriptureSelection.end) === 0\n )\n return `${scrRefToBBBCCCVVV(scriptureSelection.start)}+${offsetStart}`;\n return `${scrRefToBBBCCCVVV(scriptureSelection.start)}+${offsetStart}-${scrRefToBBBCCCVVV(scriptureSelection.end)}+${offsetEnd}`;\n};\n\nconst getRowKey = (row: ScriptureSrcItemDetail) =>\n `${toRefOrRange({ start: row.start, end: row.end })} ${row.source.displayName} ${row.detail}`;\n\n/**\n * Component to display a combined list of detailed items from one or more sources, where the items\n * are keyed primarily by Scripture reference. This is particularly useful for displaying a list of\n * results from Scripture checks, but more generally could be used to display any \"results\" from any\n * source(s). The component allows for grouping by Scripture book, source, or both. By default, it\n * displays somewhat \"tree-like\" which allows it to be more horizontally compact and intuitive. But\n * it also has the option of displaying as a traditional table with column headings (with or without\n * the source column showing).\n */\nexport default function ScriptureResultsViewer({\n sources,\n showColumnHeaders = false,\n showSourceColumn = false,\n scriptureReferenceColumnName,\n scriptureBookGroupName,\n typeColumnName,\n detailsColumnName,\n onRowSelected,\n direction = 'ltr',\n}: ScriptureResultsViewerProps) {\n const [grouping, setGrouping] = useState([]);\n const [sorting, setSorting] = useState([{ id: scrBookColId, desc: false }]);\n const [rowSelection, setRowSelection] = useState({});\n\n const scriptureResults = useMemo(\n () =>\n sources.flatMap((source) => {\n return source.data.map((item) => ({\n ...item,\n source: source.source,\n }));\n }),\n [sources],\n );\n\n const columns = useMemo(\n () =>\n getColumns(\n {\n scriptureReferenceColumnName,\n typeColumnName,\n detailsColumnName,\n },\n showSourceColumn,\n ),\n [scriptureReferenceColumnName, typeColumnName, detailsColumnName, showSourceColumn],\n );\n\n useEffect(() => {\n // Ensure sorting is applied correctly when grouped by type\n if (grouping.includes(typeColId)) {\n setSorting([\n { id: typeColId, desc: false },\n { id: scrBookColId, desc: false },\n ]);\n } else {\n setSorting([{ id: scrBookColId, desc: false }]);\n }\n }, [grouping]);\n\n const table = useReactTable({\n data: scriptureResults,\n columns,\n state: {\n grouping,\n sorting,\n rowSelection,\n },\n onGroupingChange: setGrouping,\n onSortingChange: setSorting,\n onRowSelectionChange: setRowSelection,\n getExpandedRowModel: getExpandedRowModel(),\n getGroupedRowModel: getGroupedRowModel(),\n getCoreRowModel: getCoreRowModel(),\n getSortedRowModel: getSortedRowModel(),\n getRowId: getRowKey,\n autoResetExpanded: false,\n enableMultiRowSelection: false,\n enableSubRowSelection: false,\n });\n\n useEffect(() => {\n if (onRowSelected) {\n const selectedRows = table.getSelectedRowModel().rowsById;\n const keys = Object.keys(selectedRows);\n if (keys.length === 1) {\n const selectedRow = scriptureResults.find((row) => getRowKey(row) === keys[0]) || undefined;\n if (selectedRow) onRowSelected(selectedRow);\n }\n }\n }, [rowSelection, scriptureResults, onRowSelected, table]);\n\n // Define possible grouping options\n const scrBookGroupName = scriptureBookGroupName ?? defaultScrBookGroupName;\n const typeGroupName = typeColumnName ?? defaultTypeColumnName;\n\n const groupingOptions = [\n { label: 'No Grouping', value: [] },\n { label: `Group by ${scrBookGroupName}`, value: [scrBookColId] },\n { label: `Group by ${typeGroupName}`, value: [typeColId] },\n {\n label: `Group by ${scrBookGroupName} and ${typeGroupName}`,\n value: [scrBookColId, typeColId],\n },\n {\n label: `Group by ${typeGroupName} and ${scrBookGroupName}`,\n value: [typeColId, scrBookColId],\n },\n ];\n\n const handleSelectChange = (selectedGrouping: string) => {\n setGrouping(JSON.parse(selectedGrouping));\n };\n\n const handleRowClick = (row: Row, event: MouseEvent) => {\n if (!row.getIsGrouped() && !row.getIsSelected()) {\n row.getToggleSelectedHandler()(event);\n }\n };\n\n const getEvenOrOddBandingStyle = (row: Row, index: number) => {\n if (row.getIsGrouped()) return '';\n // UX has now said they don't think they want banding. I'm leaving in the code to\n // set even and odd styles, but there's nothing in the CSS to style them differently.\n // The \"even\" style used to also have tw-bg-neutral-300 (along with even) to create\n // a visual banding effect. That could be added back in if UX changes the decision.\n return cn('banded-row', index % 2 === 0 ? 'even' : 'odd');\n };\n\n const getIndent = (\n groupingState: GroupingState,\n row: Row,\n cell: Cell,\n ) => {\n if (groupingState?.length === 0 || row.depth < cell.column.getGroupedIndex()) return undefined;\n if (row.getIsGrouped()) {\n switch (row.depth) {\n case 1:\n return 'tw-ps-4';\n default:\n return undefined;\n }\n }\n switch (row.depth) {\n case 1:\n return 'tw-ps-8';\n case 2:\n return 'tw-ps-12';\n default:\n return undefined;\n }\n };\n\n return (\n
    \n {!showColumnHeaders && (\n {\n handleSelectChange(value);\n }}\n >\n \n \n \n \n \n {groupingOptions.map((option) => (\n \n {option.label}\n \n ))}\n \n \n \n )}\n \n {showColumnHeaders && (\n \n {table.getHeaderGroups().map((headerGroup) => (\n \n {headerGroup.headers\n .filter((h) => h.column.columnDef.header)\n .map((header) => (\n /* For sticky column headers to work, we probably need to change the default definition of the shadcn Table component. See https://github.com/shadcn-ui/ui/issues/1151 */\n \n {header.isPlaceholder ? undefined : (\n
    \n {header.column.getCanGroup() ? (\n \n {header.column.getIsGrouped() ? `🛑` : `👊 `}\n \n ) : undefined}{' '}\n {flexRender(header.column.columnDef.header, header.getContext())}\n
    \n )}\n
    \n ))}\n
    \n ))}\n
    \n )}\n \n {table.getRowModel().rows.map((row, rowIndex) => {\n return (\n handleRowClick(row, event)}\n >\n {row.getVisibleCells().map((cell) => {\n if (\n cell.getIsPlaceholder() ||\n (cell.column.columnDef.enableGrouping &&\n !cell.getIsGrouped() &&\n (cell.column.columnDef.id !== typeColId || !showSourceColumn))\n )\n return undefined;\n return (\n \n {(() => {\n if (cell.getIsGrouped()) {\n return (\n \n {row.getIsExpanded() && }\n {!row.getIsExpanded() &&\n (direction === 'ltr' ? : )}{' '}\n {flexRender(cell.column.columnDef.cell, cell.getContext())} (\n {row.subRows.length})\n \n );\n }\n\n // if (cell.getIsAggregated()) {\n // flexRender(\n // cell.column.columnDef.aggregatedCell ?? cell.column.columnDef.cell,\n // cell.getContext(),\n // );\n // }\n\n return flexRender(cell.column.columnDef.cell, cell.getContext());\n })()}\n \n );\n })}\n \n );\n })}\n \n
    \n
    \n );\n}\n","import {\n getLocalizeKeyForScrollGroupId,\n LanguageStrings,\n ScrollGroupId,\n} from 'platform-bible-utils';\nimport {\n Select,\n SelectContent,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\n\nconst DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS = {\n [getLocalizeKeyForScrollGroupId('undefined')]: 'Ø',\n [getLocalizeKeyForScrollGroupId(0)]: 'A',\n [getLocalizeKeyForScrollGroupId(1)]: 'B',\n [getLocalizeKeyForScrollGroupId(2)]: 'C',\n [getLocalizeKeyForScrollGroupId(3)]: 'D',\n [getLocalizeKeyForScrollGroupId(4)]: 'E',\n [getLocalizeKeyForScrollGroupId(5)]: 'F',\n [getLocalizeKeyForScrollGroupId(6)]: 'G',\n [getLocalizeKeyForScrollGroupId(7)]: 'H',\n [getLocalizeKeyForScrollGroupId(8)]: 'I',\n [getLocalizeKeyForScrollGroupId(9)]: 'J',\n [getLocalizeKeyForScrollGroupId(10)]: 'K',\n [getLocalizeKeyForScrollGroupId(11)]: 'L',\n [getLocalizeKeyForScrollGroupId(12)]: 'M',\n [getLocalizeKeyForScrollGroupId(13)]: 'N',\n [getLocalizeKeyForScrollGroupId(14)]: 'O',\n [getLocalizeKeyForScrollGroupId(15)]: 'P',\n [getLocalizeKeyForScrollGroupId(16)]: 'Q',\n [getLocalizeKeyForScrollGroupId(17)]: 'R',\n [getLocalizeKeyForScrollGroupId(18)]: 'S',\n [getLocalizeKeyForScrollGroupId(19)]: 'T',\n [getLocalizeKeyForScrollGroupId(20)]: 'U',\n [getLocalizeKeyForScrollGroupId(21)]: 'V',\n [getLocalizeKeyForScrollGroupId(22)]: 'W',\n [getLocalizeKeyForScrollGroupId(23)]: 'X',\n [getLocalizeKeyForScrollGroupId(24)]: 'Y',\n [getLocalizeKeyForScrollGroupId(25)]: 'Z',\n};\n\nexport type ScrollGroupSelectorProps = {\n /**\n * List of scroll group ids to show to the user. Either a {@link ScrollGroupId} or `undefined` for\n * no scroll group\n */\n availableScrollGroupIds: (ScrollGroupId | undefined)[];\n /** Currently selected scroll group id. `undefined` for no scroll group */\n scrollGroupId: ScrollGroupId | undefined;\n /** Callback function run when the user tries to change the scroll group id */\n onChangeScrollGroupId: (newScrollGroupId: ScrollGroupId | undefined) => void;\n /**\n * Localized strings to use for displaying scroll group ids. Must be an object whose keys are\n * `getLocalizeKeyForScrollGroupId(scrollGroupId)` for all scroll group ids (and `undefined` if\n * included) in {@link ScrollGroupSelectorProps.availableScrollGroupIds} and whose values are the\n * localized strings to use for those scroll group ids.\n *\n * Defaults to English localizations of English alphabet for scroll groups 0-25 (e.g. 0 is A) and\n * Ø for `undefined`. Will fill in any that are not provided with these English localizations.\n * Also, if any values match the keys, the English localization will be used. This is useful in\n * case you want to pass in a temporary version of the localized strings while your localized\n * strings load.\n *\n * @example\n *\n * ```typescript\n * const myScrollGroupIdLocalizedStrings = {\n * [getLocalizeKeyForScrollGroupId('undefined')]: 'Ø',\n * [getLocalizeKeyForScrollGroupId(0)]: 'A',\n * [getLocalizeKeyForScrollGroupId(1)]: 'B',\n * [getLocalizeKeyForScrollGroupId(2)]: 'C',\n * [getLocalizeKeyForScrollGroupId(3)]: 'D',\n * [getLocalizeKeyForScrollGroupId(4)]: 'E',\n * };\n * ```\n *\n * @example\n *\n * ```tsx\n * const availableScrollGroupIds = [undefined, 0, 1, 2, 3, 4];\n *\n * const localizeKeys = getLocalizeKeysForScrollGroupIds();\n *\n * const [localizedStrings] = useLocalizedStrings(localizeKeys);\n *\n * ...\n *\n * \n * ```\n */\n localizedStrings?: LanguageStrings;\n};\n\n/** Selector component for choosing a scroll group */\nexport default function ScrollGroupSelector({\n availableScrollGroupIds,\n scrollGroupId,\n onChangeScrollGroupId,\n localizedStrings = {},\n}: ScrollGroupSelectorProps) {\n const localizedStringsDefaulted = {\n ...DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS,\n ...Object.fromEntries(\n Object.entries(localizedStrings).map(\n ([localizedStringKey, localizedStringValue]: [string, string]) => [\n localizedStringKey,\n localizedStringKey === localizedStringValue &&\n localizedStringKey in DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS\n ? DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS[localizedStringKey]\n : localizedStringValue,\n ],\n ),\n ),\n };\n return (\n \n onChangeScrollGroupId(\n newScrollGroupString === 'undefined' ? undefined : parseInt(newScrollGroupString, 10),\n )\n }\n >\n \n \n \n \n {availableScrollGroupIds.map((scrollGroupOptionId) => (\n \n {localizedStringsDefaulted[getLocalizeKeyForScrollGroupId(scrollGroupOptionId)]}\n \n ))}\n \n \n );\n}\n","import { PropsWithChildren } from 'react';\nimport { Separator } from '@/components/shadcn-ui/separator';\n\n/** Props for the SettingsList component, currently just children */\ntype SettingsListProps = PropsWithChildren;\n\n/**\n * SettingsList component is a wrapper for list items. Rendered with a formatted div\n *\n * @param children To populate the list with\n * @returns Formatted div encompassing the children\n */\nexport function SettingsList({ children }: SettingsListProps) {\n return
    {children}
    ;\n}\n\n/** Props for SettingsListItem component */\ntype SettingsListItemProps = PropsWithChildren & {\n /** Primary text of the list item */\n primary: string;\n\n /** Optional text of the list item */\n secondary?: string | undefined;\n\n /** Optional boolean to display a message if the children aren't loaded yet. Defaults to false */\n isLoading?: boolean;\n\n /** Optional message to display if isLoading */\n loadingMessage?: string;\n};\n\n/**\n * SettingsListItem component is a common list item. Rendered with a formatted div\n *\n * @param primary Primary text of the list item\n * @param secondary Optional secondary text of the list item\n * @param isLoading Optional, to display a message if the action component isn't generated yet,\n * defaults to false\n * @param children The action component(s) to provide for this item\n * @param loadingMessage Optional, message to display if isLoading\n * @returns Formatted div encompassing the list item content\n */\nexport function SettingsListItem({\n primary,\n secondary,\n children,\n isLoading = false,\n loadingMessage,\n}: SettingsListItemProps) {\n return (\n
    \n
    \n

    {primary}

    \n

    \n {secondary}\n

    \n
    \n\n {isLoading ? (\n

    {loadingMessage}

    \n ) : (\n
    {children}
    \n )}\n
    \n );\n}\n\n/** Props for SettingsListHeader component */\ntype SettingsListHeaderProps = {\n /** The primary text of the list header */\n primary: string;\n\n /** Optional secondary text of the list header */\n secondary?: string | undefined;\n\n /** Optional boolean to include a separator underneath the secondary text. Defaults to false */\n includeSeparator?: boolean;\n};\n\n/**\n * SettingsListHeader component displays text above the list\n *\n * @param primary The primary text of the list header\n * @param secondary Optional secondary text of the list header\n * @param includeSeparator Optional boolean to include a separator underneath the secondary text.\n * Defaults to false\n * @returns Formatted div with list header content\n */\nexport function SettingsListHeader({\n primary,\n secondary,\n includeSeparator = false,\n}: SettingsListHeaderProps) {\n return (\n
    \n
    \n

    {primary}

    \n

    {secondary}

    \n
    \n {includeSeparator ? : ''}\n
    \n );\n}\n","import Checkbox from '@/components/shadcn-ui/checkbox';\nimport { Label } from '@/components/shadcn-ui/label';\n\nexport type ChecklistProps = {\n /** Optional string representing the id attribute of the Checklist */\n id?: string;\n /** Optional string representing CSS class name(s) for styling */\n className?: string;\n /** Array of strings representing the checkable items */\n listItems: string[];\n /** Array of strings representing the checked items */\n selectedListItems: string[];\n /**\n * Function that is called when a checkbox item is selected or deselected\n *\n * @param item The string description for this item\n * @param selected True if selected, false if not selected\n */\n handleSelectListItem: (item: string, selected: boolean) => void;\n\n /**\n * Optional function creates a label for a provided checkable item\n *\n * @param item The item for which a label is to be created\n * @returns A string representing the label text for the checkbox associated with that item\n */\n createLabel?: (item: string) => string;\n};\n\n/** Renders a list of checkboxes. Each checkbox corresponds to an item from the `listItems` array. */\nexport default function Checklist({\n id,\n className,\n listItems,\n selectedListItems,\n handleSelectListItem,\n createLabel,\n}: ChecklistProps) {\n return (\n
    \n {listItems.map((item) => (\n
    \n handleSelectListItem(item, value)}\n />\n \n
    \n ))}\n
    \n );\n}\n","function _interopRequireDefault(obj) {\n return obj && obj.__esModule ? obj : {\n \"default\": obj\n };\n}\nmodule.exports = _interopRequireDefault, module.exports.__esModule = true, module.exports[\"default\"] = module.exports;","export default function chainPropTypes(propType1, propType2) {\n if (process.env.NODE_ENV === 'production') {\n return () => null;\n }\n return function validate(...args) {\n return propType1(...args) || propType2(...args);\n };\n}","export default function _extends() {\n _extends = Object.assign ? Object.assign.bind() : function (target) {\n for (var i = 1; i < arguments.length; i++) {\n var source = arguments[i];\n for (var key in source) {\n if (Object.prototype.hasOwnProperty.call(source, key)) {\n target[key] = source[key];\n }\n }\n }\n return target;\n };\n return _extends.apply(this, arguments);\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\n// https://github.com/sindresorhus/is-plain-obj/blob/main/index.js\nexport function isPlainObject(item) {\n if (typeof item !== 'object' || item === null) {\n return false;\n }\n const prototype = Object.getPrototypeOf(item);\n return (prototype === null || prototype === Object.prototype || Object.getPrototypeOf(prototype) === null) && !(Symbol.toStringTag in item) && !(Symbol.iterator in item);\n}\nfunction deepClone(source) {\n if (!isPlainObject(source)) {\n return source;\n }\n const output = {};\n Object.keys(source).forEach(key => {\n output[key] = deepClone(source[key]);\n });\n return output;\n}\nexport default function deepmerge(target, source, options = {\n clone: true\n}) {\n const output = options.clone ? _extends({}, target) : target;\n if (isPlainObject(target) && isPlainObject(source)) {\n Object.keys(source).forEach(key => {\n // Avoid prototype pollution\n if (key === '__proto__') {\n return;\n }\n if (isPlainObject(source[key]) && key in target && isPlainObject(target[key])) {\n // Since `output` is a clone of `target` and we have narrowed `target` in this block we can cast to the same type.\n output[key] = deepmerge(target[key], source[key], options);\n } else if (options.clone) {\n output[key] = isPlainObject(source[key]) ? deepClone(source[key]) : source[key];\n } else {\n output[key] = source[key];\n }\n });\n }\n return output;\n}","/** @license React v16.13.1\n * react-is.production.min.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';var b=\"function\"===typeof Symbol&&Symbol.for,c=b?Symbol.for(\"react.element\"):60103,d=b?Symbol.for(\"react.portal\"):60106,e=b?Symbol.for(\"react.fragment\"):60107,f=b?Symbol.for(\"react.strict_mode\"):60108,g=b?Symbol.for(\"react.profiler\"):60114,h=b?Symbol.for(\"react.provider\"):60109,k=b?Symbol.for(\"react.context\"):60110,l=b?Symbol.for(\"react.async_mode\"):60111,m=b?Symbol.for(\"react.concurrent_mode\"):60111,n=b?Symbol.for(\"react.forward_ref\"):60112,p=b?Symbol.for(\"react.suspense\"):60113,q=b?\nSymbol.for(\"react.suspense_list\"):60120,r=b?Symbol.for(\"react.memo\"):60115,t=b?Symbol.for(\"react.lazy\"):60116,v=b?Symbol.for(\"react.block\"):60121,w=b?Symbol.for(\"react.fundamental\"):60117,x=b?Symbol.for(\"react.responder\"):60118,y=b?Symbol.for(\"react.scope\"):60119;\nfunction z(a){if(\"object\"===typeof a&&null!==a){var u=a.$$typeof;switch(u){case c:switch(a=a.type,a){case l:case m:case e:case g:case f:case p:return a;default:switch(a=a&&a.$$typeof,a){case k:case n:case t:case r:case h:return a;default:return u}}case d:return u}}}function A(a){return z(a)===m}exports.AsyncMode=l;exports.ConcurrentMode=m;exports.ContextConsumer=k;exports.ContextProvider=h;exports.Element=c;exports.ForwardRef=n;exports.Fragment=e;exports.Lazy=t;exports.Memo=r;exports.Portal=d;\nexports.Profiler=g;exports.StrictMode=f;exports.Suspense=p;exports.isAsyncMode=function(a){return A(a)||z(a)===l};exports.isConcurrentMode=A;exports.isContextConsumer=function(a){return z(a)===k};exports.isContextProvider=function(a){return z(a)===h};exports.isElement=function(a){return\"object\"===typeof a&&null!==a&&a.$$typeof===c};exports.isForwardRef=function(a){return z(a)===n};exports.isFragment=function(a){return z(a)===e};exports.isLazy=function(a){return z(a)===t};\nexports.isMemo=function(a){return z(a)===r};exports.isPortal=function(a){return z(a)===d};exports.isProfiler=function(a){return z(a)===g};exports.isStrictMode=function(a){return z(a)===f};exports.isSuspense=function(a){return z(a)===p};\nexports.isValidElementType=function(a){return\"string\"===typeof a||\"function\"===typeof a||a===e||a===m||a===g||a===f||a===p||a===q||\"object\"===typeof a&&null!==a&&(a.$$typeof===t||a.$$typeof===r||a.$$typeof===h||a.$$typeof===k||a.$$typeof===n||a.$$typeof===w||a.$$typeof===x||a.$$typeof===y||a.$$typeof===v)};exports.typeOf=z;\n","/** @license React v16.13.1\n * react-is.development.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\n\n\nif (process.env.NODE_ENV !== \"production\") {\n (function() {\n'use strict';\n\n// The Symbol used to tag the ReactElement-like types. If there is no native Symbol\n// nor polyfill, then a plain number is used for performance.\nvar hasSymbol = typeof Symbol === 'function' && Symbol.for;\nvar REACT_ELEMENT_TYPE = hasSymbol ? Symbol.for('react.element') : 0xeac7;\nvar REACT_PORTAL_TYPE = hasSymbol ? Symbol.for('react.portal') : 0xeaca;\nvar REACT_FRAGMENT_TYPE = hasSymbol ? Symbol.for('react.fragment') : 0xeacb;\nvar REACT_STRICT_MODE_TYPE = hasSymbol ? Symbol.for('react.strict_mode') : 0xeacc;\nvar REACT_PROFILER_TYPE = hasSymbol ? Symbol.for('react.profiler') : 0xead2;\nvar REACT_PROVIDER_TYPE = hasSymbol ? Symbol.for('react.provider') : 0xeacd;\nvar REACT_CONTEXT_TYPE = hasSymbol ? Symbol.for('react.context') : 0xeace; // TODO: We don't use AsyncMode or ConcurrentMode anymore. They were temporary\n// (unstable) APIs that have been removed. Can we remove the symbols?\n\nvar REACT_ASYNC_MODE_TYPE = hasSymbol ? Symbol.for('react.async_mode') : 0xeacf;\nvar REACT_CONCURRENT_MODE_TYPE = hasSymbol ? Symbol.for('react.concurrent_mode') : 0xeacf;\nvar REACT_FORWARD_REF_TYPE = hasSymbol ? Symbol.for('react.forward_ref') : 0xead0;\nvar REACT_SUSPENSE_TYPE = hasSymbol ? Symbol.for('react.suspense') : 0xead1;\nvar REACT_SUSPENSE_LIST_TYPE = hasSymbol ? Symbol.for('react.suspense_list') : 0xead8;\nvar REACT_MEMO_TYPE = hasSymbol ? Symbol.for('react.memo') : 0xead3;\nvar REACT_LAZY_TYPE = hasSymbol ? Symbol.for('react.lazy') : 0xead4;\nvar REACT_BLOCK_TYPE = hasSymbol ? Symbol.for('react.block') : 0xead9;\nvar REACT_FUNDAMENTAL_TYPE = hasSymbol ? Symbol.for('react.fundamental') : 0xead5;\nvar REACT_RESPONDER_TYPE = hasSymbol ? Symbol.for('react.responder') : 0xead6;\nvar REACT_SCOPE_TYPE = hasSymbol ? Symbol.for('react.scope') : 0xead7;\n\nfunction isValidElementType(type) {\n return typeof type === 'string' || typeof type === 'function' || // Note: its typeof might be other than 'symbol' or 'number' if it's a polyfill.\n type === REACT_FRAGMENT_TYPE || type === REACT_CONCURRENT_MODE_TYPE || type === REACT_PROFILER_TYPE || type === REACT_STRICT_MODE_TYPE || type === REACT_SUSPENSE_TYPE || type === REACT_SUSPENSE_LIST_TYPE || typeof type === 'object' && type !== null && (type.$$typeof === REACT_LAZY_TYPE || type.$$typeof === REACT_MEMO_TYPE || type.$$typeof === REACT_PROVIDER_TYPE || type.$$typeof === REACT_CONTEXT_TYPE || type.$$typeof === REACT_FORWARD_REF_TYPE || type.$$typeof === REACT_FUNDAMENTAL_TYPE || type.$$typeof === REACT_RESPONDER_TYPE || type.$$typeof === REACT_SCOPE_TYPE || type.$$typeof === REACT_BLOCK_TYPE);\n}\n\nfunction typeOf(object) {\n if (typeof object === 'object' && object !== null) {\n var $$typeof = object.$$typeof;\n\n switch ($$typeof) {\n case REACT_ELEMENT_TYPE:\n var type = object.type;\n\n switch (type) {\n case REACT_ASYNC_MODE_TYPE:\n case REACT_CONCURRENT_MODE_TYPE:\n case REACT_FRAGMENT_TYPE:\n case REACT_PROFILER_TYPE:\n case REACT_STRICT_MODE_TYPE:\n case REACT_SUSPENSE_TYPE:\n return type;\n\n default:\n var $$typeofType = type && type.$$typeof;\n\n switch ($$typeofType) {\n case REACT_CONTEXT_TYPE:\n case REACT_FORWARD_REF_TYPE:\n case REACT_LAZY_TYPE:\n case REACT_MEMO_TYPE:\n case REACT_PROVIDER_TYPE:\n return $$typeofType;\n\n default:\n return $$typeof;\n }\n\n }\n\n case REACT_PORTAL_TYPE:\n return $$typeof;\n }\n }\n\n return undefined;\n} // AsyncMode is deprecated along with isAsyncMode\n\nvar AsyncMode = REACT_ASYNC_MODE_TYPE;\nvar ConcurrentMode = REACT_CONCURRENT_MODE_TYPE;\nvar ContextConsumer = REACT_CONTEXT_TYPE;\nvar ContextProvider = REACT_PROVIDER_TYPE;\nvar Element = REACT_ELEMENT_TYPE;\nvar ForwardRef = REACT_FORWARD_REF_TYPE;\nvar Fragment = REACT_FRAGMENT_TYPE;\nvar Lazy = REACT_LAZY_TYPE;\nvar Memo = REACT_MEMO_TYPE;\nvar Portal = REACT_PORTAL_TYPE;\nvar Profiler = REACT_PROFILER_TYPE;\nvar StrictMode = REACT_STRICT_MODE_TYPE;\nvar Suspense = REACT_SUSPENSE_TYPE;\nvar hasWarnedAboutDeprecatedIsAsyncMode = false; // AsyncMode should be deprecated\n\nfunction isAsyncMode(object) {\n {\n if (!hasWarnedAboutDeprecatedIsAsyncMode) {\n hasWarnedAboutDeprecatedIsAsyncMode = true; // Using console['warn'] to evade Babel and ESLint\n\n console['warn']('The ReactIs.isAsyncMode() alias has been deprecated, ' + 'and will be removed in React 17+. Update your code to use ' + 'ReactIs.isConcurrentMode() instead. It has the exact same API.');\n }\n }\n\n return isConcurrentMode(object) || typeOf(object) === REACT_ASYNC_MODE_TYPE;\n}\nfunction isConcurrentMode(object) {\n return typeOf(object) === REACT_CONCURRENT_MODE_TYPE;\n}\nfunction isContextConsumer(object) {\n return typeOf(object) === REACT_CONTEXT_TYPE;\n}\nfunction isContextProvider(object) {\n return typeOf(object) === REACT_PROVIDER_TYPE;\n}\nfunction isElement(object) {\n return typeof object === 'object' && object !== null && object.$$typeof === REACT_ELEMENT_TYPE;\n}\nfunction isForwardRef(object) {\n return typeOf(object) === REACT_FORWARD_REF_TYPE;\n}\nfunction isFragment(object) {\n return typeOf(object) === REACT_FRAGMENT_TYPE;\n}\nfunction isLazy(object) {\n return typeOf(object) === REACT_LAZY_TYPE;\n}\nfunction isMemo(object) {\n return typeOf(object) === REACT_MEMO_TYPE;\n}\nfunction isPortal(object) {\n return typeOf(object) === REACT_PORTAL_TYPE;\n}\nfunction isProfiler(object) {\n return typeOf(object) === REACT_PROFILER_TYPE;\n}\nfunction isStrictMode(object) {\n return typeOf(object) === REACT_STRICT_MODE_TYPE;\n}\nfunction isSuspense(object) {\n return typeOf(object) === REACT_SUSPENSE_TYPE;\n}\n\nexports.AsyncMode = AsyncMode;\nexports.ConcurrentMode = ConcurrentMode;\nexports.ContextConsumer = ContextConsumer;\nexports.ContextProvider = ContextProvider;\nexports.Element = Element;\nexports.ForwardRef = ForwardRef;\nexports.Fragment = Fragment;\nexports.Lazy = Lazy;\nexports.Memo = Memo;\nexports.Portal = Portal;\nexports.Profiler = Profiler;\nexports.StrictMode = StrictMode;\nexports.Suspense = Suspense;\nexports.isAsyncMode = isAsyncMode;\nexports.isConcurrentMode = isConcurrentMode;\nexports.isContextConsumer = isContextConsumer;\nexports.isContextProvider = isContextProvider;\nexports.isElement = isElement;\nexports.isForwardRef = isForwardRef;\nexports.isFragment = isFragment;\nexports.isLazy = isLazy;\nexports.isMemo = isMemo;\nexports.isPortal = isPortal;\nexports.isProfiler = isProfiler;\nexports.isStrictMode = isStrictMode;\nexports.isSuspense = isSuspense;\nexports.isValidElementType = isValidElementType;\nexports.typeOf = typeOf;\n })();\n}\n","'use strict';\n\nif (process.env.NODE_ENV === 'production') {\n module.exports = require('./cjs/react-is.production.min.js');\n} else {\n module.exports = require('./cjs/react-is.development.js');\n}\n","/*\nobject-assign\n(c) Sindre Sorhus\n@license MIT\n*/\n\n'use strict';\n/* eslint-disable no-unused-vars */\nvar getOwnPropertySymbols = Object.getOwnPropertySymbols;\nvar hasOwnProperty = Object.prototype.hasOwnProperty;\nvar propIsEnumerable = Object.prototype.propertyIsEnumerable;\n\nfunction toObject(val) {\n\tif (val === null || val === undefined) {\n\t\tthrow new TypeError('Object.assign cannot be called with null or undefined');\n\t}\n\n\treturn Object(val);\n}\n\nfunction shouldUseNative() {\n\ttry {\n\t\tif (!Object.assign) {\n\t\t\treturn false;\n\t\t}\n\n\t\t// Detect buggy property enumeration order in older V8 versions.\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=4118\n\t\tvar test1 = new String('abc'); // eslint-disable-line no-new-wrappers\n\t\ttest1[5] = 'de';\n\t\tif (Object.getOwnPropertyNames(test1)[0] === '5') {\n\t\t\treturn false;\n\t\t}\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=3056\n\t\tvar test2 = {};\n\t\tfor (var i = 0; i < 10; i++) {\n\t\t\ttest2['_' + String.fromCharCode(i)] = i;\n\t\t}\n\t\tvar order2 = Object.getOwnPropertyNames(test2).map(function (n) {\n\t\t\treturn test2[n];\n\t\t});\n\t\tif (order2.join('') !== '0123456789') {\n\t\t\treturn false;\n\t\t}\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=3056\n\t\tvar test3 = {};\n\t\t'abcdefghijklmnopqrst'.split('').forEach(function (letter) {\n\t\t\ttest3[letter] = letter;\n\t\t});\n\t\tif (Object.keys(Object.assign({}, test3)).join('') !==\n\t\t\t\t'abcdefghijklmnopqrst') {\n\t\t\treturn false;\n\t\t}\n\n\t\treturn true;\n\t} catch (err) {\n\t\t// We don't expect any of the above to throw, but better to be safe.\n\t\treturn false;\n\t}\n}\n\nmodule.exports = shouldUseNative() ? Object.assign : function (target, source) {\n\tvar from;\n\tvar to = toObject(target);\n\tvar symbols;\n\n\tfor (var s = 1; s < arguments.length; s++) {\n\t\tfrom = Object(arguments[s]);\n\n\t\tfor (var key in from) {\n\t\t\tif (hasOwnProperty.call(from, key)) {\n\t\t\t\tto[key] = from[key];\n\t\t\t}\n\t\t}\n\n\t\tif (getOwnPropertySymbols) {\n\t\t\tsymbols = getOwnPropertySymbols(from);\n\t\t\tfor (var i = 0; i < symbols.length; i++) {\n\t\t\t\tif (propIsEnumerable.call(from, symbols[i])) {\n\t\t\t\t\tto[symbols[i]] = from[symbols[i]];\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\n\treturn to;\n};\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar ReactPropTypesSecret = 'SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED';\n\nmodule.exports = ReactPropTypesSecret;\n","module.exports = Function.call.bind(Object.prototype.hasOwnProperty);\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar printWarning = function() {};\n\nif (process.env.NODE_ENV !== 'production') {\n var ReactPropTypesSecret = require('./lib/ReactPropTypesSecret');\n var loggedTypeFailures = {};\n var has = require('./lib/has');\n\n printWarning = function(text) {\n var message = 'Warning: ' + text;\n if (typeof console !== 'undefined') {\n console.error(message);\n }\n try {\n // --- Welcome to debugging React ---\n // This error was thrown as a convenience so that you can use this stack\n // to find the callsite that caused this warning to fire.\n throw new Error(message);\n } catch (x) { /**/ }\n };\n}\n\n/**\n * Assert that the values match with the type specs.\n * Error messages are memorized and will only be shown once.\n *\n * @param {object} typeSpecs Map of name to a ReactPropType\n * @param {object} values Runtime values that need to be type-checked\n * @param {string} location e.g. \"prop\", \"context\", \"child context\"\n * @param {string} componentName Name of the component for error messages.\n * @param {?Function} getStack Returns the component stack.\n * @private\n */\nfunction checkPropTypes(typeSpecs, values, location, componentName, getStack) {\n if (process.env.NODE_ENV !== 'production') {\n for (var typeSpecName in typeSpecs) {\n if (has(typeSpecs, typeSpecName)) {\n var error;\n // Prop type validation may throw. In case they do, we don't want to\n // fail the render phase where it didn't fail before. So we log it.\n // After these have been cleaned up, we'll let them throw.\n try {\n // This is intentionally an invariant that gets caught. It's the same\n // behavior as without this statement except with a better message.\n if (typeof typeSpecs[typeSpecName] !== 'function') {\n var err = Error(\n (componentName || 'React class') + ': ' + location + ' type `' + typeSpecName + '` is invalid; ' +\n 'it must be a function, usually from the `prop-types` package, but received `' + typeof typeSpecs[typeSpecName] + '`.' +\n 'This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.'\n );\n err.name = 'Invariant Violation';\n throw err;\n }\n error = typeSpecs[typeSpecName](values, typeSpecName, componentName, location, null, ReactPropTypesSecret);\n } catch (ex) {\n error = ex;\n }\n if (error && !(error instanceof Error)) {\n printWarning(\n (componentName || 'React class') + ': type specification of ' +\n location + ' `' + typeSpecName + '` is invalid; the type checker ' +\n 'function must return `null` or an `Error` but returned a ' + typeof error + '. ' +\n 'You may have forgotten to pass an argument to the type checker ' +\n 'creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and ' +\n 'shape all require an argument).'\n );\n }\n if (error instanceof Error && !(error.message in loggedTypeFailures)) {\n // Only monitor this failure once because there tends to be a lot of the\n // same error.\n loggedTypeFailures[error.message] = true;\n\n var stack = getStack ? getStack() : '';\n\n printWarning(\n 'Failed ' + location + ' type: ' + error.message + (stack != null ? stack : '')\n );\n }\n }\n }\n }\n}\n\n/**\n * Resets warning cache when testing.\n *\n * @private\n */\ncheckPropTypes.resetWarningCache = function() {\n if (process.env.NODE_ENV !== 'production') {\n loggedTypeFailures = {};\n }\n}\n\nmodule.exports = checkPropTypes;\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar ReactIs = require('react-is');\nvar assign = require('object-assign');\n\nvar ReactPropTypesSecret = require('./lib/ReactPropTypesSecret');\nvar has = require('./lib/has');\nvar checkPropTypes = require('./checkPropTypes');\n\nvar printWarning = function() {};\n\nif (process.env.NODE_ENV !== 'production') {\n printWarning = function(text) {\n var message = 'Warning: ' + text;\n if (typeof console !== 'undefined') {\n console.error(message);\n }\n try {\n // --- Welcome to debugging React ---\n // This error was thrown as a convenience so that you can use this stack\n // to find the callsite that caused this warning to fire.\n throw new Error(message);\n } catch (x) {}\n };\n}\n\nfunction emptyFunctionThatReturnsNull() {\n return null;\n}\n\nmodule.exports = function(isValidElement, throwOnDirectAccess) {\n /* global Symbol */\n var ITERATOR_SYMBOL = typeof Symbol === 'function' && Symbol.iterator;\n var FAUX_ITERATOR_SYMBOL = '@@iterator'; // Before Symbol spec.\n\n /**\n * Returns the iterator method function contained on the iterable object.\n *\n * Be sure to invoke the function with the iterable as context:\n *\n * var iteratorFn = getIteratorFn(myIterable);\n * if (iteratorFn) {\n * var iterator = iteratorFn.call(myIterable);\n * ...\n * }\n *\n * @param {?object} maybeIterable\n * @return {?function}\n */\n function getIteratorFn(maybeIterable) {\n var iteratorFn = maybeIterable && (ITERATOR_SYMBOL && maybeIterable[ITERATOR_SYMBOL] || maybeIterable[FAUX_ITERATOR_SYMBOL]);\n if (typeof iteratorFn === 'function') {\n return iteratorFn;\n }\n }\n\n /**\n * Collection of methods that allow declaration and validation of props that are\n * supplied to React components. Example usage:\n *\n * var Props = require('ReactPropTypes');\n * var MyArticle = React.createClass({\n * propTypes: {\n * // An optional string prop named \"description\".\n * description: Props.string,\n *\n * // A required enum prop named \"category\".\n * category: Props.oneOf(['News','Photos']).isRequired,\n *\n * // A prop named \"dialog\" that requires an instance of Dialog.\n * dialog: Props.instanceOf(Dialog).isRequired\n * },\n * render: function() { ... }\n * });\n *\n * A more formal specification of how these methods are used:\n *\n * type := array|bool|func|object|number|string|oneOf([...])|instanceOf(...)\n * decl := ReactPropTypes.{type}(.isRequired)?\n *\n * Each and every declaration produces a function with the same signature. This\n * allows the creation of custom validation functions. For example:\n *\n * var MyLink = React.createClass({\n * propTypes: {\n * // An optional string or URI prop named \"href\".\n * href: function(props, propName, componentName) {\n * var propValue = props[propName];\n * if (propValue != null && typeof propValue !== 'string' &&\n * !(propValue instanceof URI)) {\n * return new Error(\n * 'Expected a string or an URI for ' + propName + ' in ' +\n * componentName\n * );\n * }\n * }\n * },\n * render: function() {...}\n * });\n *\n * @internal\n */\n\n var ANONYMOUS = '<>';\n\n // Important!\n // Keep this list in sync with production version in `./factoryWithThrowingShims.js`.\n var ReactPropTypes = {\n array: createPrimitiveTypeChecker('array'),\n bigint: createPrimitiveTypeChecker('bigint'),\n bool: createPrimitiveTypeChecker('boolean'),\n func: createPrimitiveTypeChecker('function'),\n number: createPrimitiveTypeChecker('number'),\n object: createPrimitiveTypeChecker('object'),\n string: createPrimitiveTypeChecker('string'),\n symbol: createPrimitiveTypeChecker('symbol'),\n\n any: createAnyTypeChecker(),\n arrayOf: createArrayOfTypeChecker,\n element: createElementTypeChecker(),\n elementType: createElementTypeTypeChecker(),\n instanceOf: createInstanceTypeChecker,\n node: createNodeChecker(),\n objectOf: createObjectOfTypeChecker,\n oneOf: createEnumTypeChecker,\n oneOfType: createUnionTypeChecker,\n shape: createShapeTypeChecker,\n exact: createStrictShapeTypeChecker,\n };\n\n /**\n * inlined Object.is polyfill to avoid requiring consumers ship their own\n * https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object/is\n */\n /*eslint-disable no-self-compare*/\n function is(x, y) {\n // SameValue algorithm\n if (x === y) {\n // Steps 1-5, 7-10\n // Steps 6.b-6.e: +0 != -0\n return x !== 0 || 1 / x === 1 / y;\n } else {\n // Step 6.a: NaN == NaN\n return x !== x && y !== y;\n }\n }\n /*eslint-enable no-self-compare*/\n\n /**\n * We use an Error-like object for backward compatibility as people may call\n * PropTypes directly and inspect their output. However, we don't use real\n * Errors anymore. We don't inspect their stack anyway, and creating them\n * is prohibitively expensive if they are created too often, such as what\n * happens in oneOfType() for any type before the one that matched.\n */\n function PropTypeError(message, data) {\n this.message = message;\n this.data = data && typeof data === 'object' ? data: {};\n this.stack = '';\n }\n // Make `instanceof Error` still work for returned errors.\n PropTypeError.prototype = Error.prototype;\n\n function createChainableTypeChecker(validate) {\n if (process.env.NODE_ENV !== 'production') {\n var manualPropTypeCallCache = {};\n var manualPropTypeWarningCount = 0;\n }\n function checkType(isRequired, props, propName, componentName, location, propFullName, secret) {\n componentName = componentName || ANONYMOUS;\n propFullName = propFullName || propName;\n\n if (secret !== ReactPropTypesSecret) {\n if (throwOnDirectAccess) {\n // New behavior only for users of `prop-types` package\n var err = new Error(\n 'Calling PropTypes validators directly is not supported by the `prop-types` package. ' +\n 'Use `PropTypes.checkPropTypes()` to call them. ' +\n 'Read more at http://fb.me/use-check-prop-types'\n );\n err.name = 'Invariant Violation';\n throw err;\n } else if (process.env.NODE_ENV !== 'production' && typeof console !== 'undefined') {\n // Old behavior for people using React.PropTypes\n var cacheKey = componentName + ':' + propName;\n if (\n !manualPropTypeCallCache[cacheKey] &&\n // Avoid spamming the console because they are often not actionable except for lib authors\n manualPropTypeWarningCount < 3\n ) {\n printWarning(\n 'You are manually calling a React.PropTypes validation ' +\n 'function for the `' + propFullName + '` prop on `' + componentName + '`. This is deprecated ' +\n 'and will throw in the standalone `prop-types` package. ' +\n 'You may be seeing this warning due to a third-party PropTypes ' +\n 'library. See https://fb.me/react-warning-dont-call-proptypes ' + 'for details.'\n );\n manualPropTypeCallCache[cacheKey] = true;\n manualPropTypeWarningCount++;\n }\n }\n }\n if (props[propName] == null) {\n if (isRequired) {\n if (props[propName] === null) {\n return new PropTypeError('The ' + location + ' `' + propFullName + '` is marked as required ' + ('in `' + componentName + '`, but its value is `null`.'));\n }\n return new PropTypeError('The ' + location + ' `' + propFullName + '` is marked as required in ' + ('`' + componentName + '`, but its value is `undefined`.'));\n }\n return null;\n } else {\n return validate(props, propName, componentName, location, propFullName);\n }\n }\n\n var chainedCheckType = checkType.bind(null, false);\n chainedCheckType.isRequired = checkType.bind(null, true);\n\n return chainedCheckType;\n }\n\n function createPrimitiveTypeChecker(expectedType) {\n function validate(props, propName, componentName, location, propFullName, secret) {\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== expectedType) {\n // `propValue` being instance of, say, date/regexp, pass the 'object'\n // check, but we can offer a more precise error message here rather than\n // 'of type `object`'.\n var preciseType = getPreciseType(propValue);\n\n return new PropTypeError(\n 'Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + preciseType + '` supplied to `' + componentName + '`, expected ') + ('`' + expectedType + '`.'),\n {expectedType: expectedType}\n );\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createAnyTypeChecker() {\n return createChainableTypeChecker(emptyFunctionThatReturnsNull);\n }\n\n function createArrayOfTypeChecker(typeChecker) {\n function validate(props, propName, componentName, location, propFullName) {\n if (typeof typeChecker !== 'function') {\n return new PropTypeError('Property `' + propFullName + '` of component `' + componentName + '` has invalid PropType notation inside arrayOf.');\n }\n var propValue = props[propName];\n if (!Array.isArray(propValue)) {\n var propType = getPropType(propValue);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected an array.'));\n }\n for (var i = 0; i < propValue.length; i++) {\n var error = typeChecker(propValue, i, componentName, location, propFullName + '[' + i + ']', ReactPropTypesSecret);\n if (error instanceof Error) {\n return error;\n }\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createElementTypeChecker() {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n if (!isValidElement(propValue)) {\n var propType = getPropType(propValue);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected a single ReactElement.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createElementTypeTypeChecker() {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n if (!ReactIs.isValidElementType(propValue)) {\n var propType = getPropType(propValue);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected a single ReactElement type.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createInstanceTypeChecker(expectedClass) {\n function validate(props, propName, componentName, location, propFullName) {\n if (!(props[propName] instanceof expectedClass)) {\n var expectedClassName = expectedClass.name || ANONYMOUS;\n var actualClassName = getClassName(props[propName]);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + actualClassName + '` supplied to `' + componentName + '`, expected ') + ('instance of `' + expectedClassName + '`.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createEnumTypeChecker(expectedValues) {\n if (!Array.isArray(expectedValues)) {\n if (process.env.NODE_ENV !== 'production') {\n if (arguments.length > 1) {\n printWarning(\n 'Invalid arguments supplied to oneOf, expected an array, got ' + arguments.length + ' arguments. ' +\n 'A common mistake is to write oneOf(x, y, z) instead of oneOf([x, y, z]).'\n );\n } else {\n printWarning('Invalid argument supplied to oneOf, expected an array.');\n }\n }\n return emptyFunctionThatReturnsNull;\n }\n\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n for (var i = 0; i < expectedValues.length; i++) {\n if (is(propValue, expectedValues[i])) {\n return null;\n }\n }\n\n var valuesString = JSON.stringify(expectedValues, function replacer(key, value) {\n var type = getPreciseType(value);\n if (type === 'symbol') {\n return String(value);\n }\n return value;\n });\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of value `' + String(propValue) + '` ' + ('supplied to `' + componentName + '`, expected one of ' + valuesString + '.'));\n }\n return createChainableTypeChecker(validate);\n }\n\n function createObjectOfTypeChecker(typeChecker) {\n function validate(props, propName, componentName, location, propFullName) {\n if (typeof typeChecker !== 'function') {\n return new PropTypeError('Property `' + propFullName + '` of component `' + componentName + '` has invalid PropType notation inside objectOf.');\n }\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== 'object') {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected an object.'));\n }\n for (var key in propValue) {\n if (has(propValue, key)) {\n var error = typeChecker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret);\n if (error instanceof Error) {\n return error;\n }\n }\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createUnionTypeChecker(arrayOfTypeCheckers) {\n if (!Array.isArray(arrayOfTypeCheckers)) {\n process.env.NODE_ENV !== 'production' ? printWarning('Invalid argument supplied to oneOfType, expected an instance of array.') : void 0;\n return emptyFunctionThatReturnsNull;\n }\n\n for (var i = 0; i < arrayOfTypeCheckers.length; i++) {\n var checker = arrayOfTypeCheckers[i];\n if (typeof checker !== 'function') {\n printWarning(\n 'Invalid argument supplied to oneOfType. Expected an array of check functions, but ' +\n 'received ' + getPostfixForTypeWarning(checker) + ' at index ' + i + '.'\n );\n return emptyFunctionThatReturnsNull;\n }\n }\n\n function validate(props, propName, componentName, location, propFullName) {\n var expectedTypes = [];\n for (var i = 0; i < arrayOfTypeCheckers.length; i++) {\n var checker = arrayOfTypeCheckers[i];\n var checkerResult = checker(props, propName, componentName, location, propFullName, ReactPropTypesSecret);\n if (checkerResult == null) {\n return null;\n }\n if (checkerResult.data && has(checkerResult.data, 'expectedType')) {\n expectedTypes.push(checkerResult.data.expectedType);\n }\n }\n var expectedTypesMessage = (expectedTypes.length > 0) ? ', expected one of type [' + expectedTypes.join(', ') + ']': '';\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` supplied to ' + ('`' + componentName + '`' + expectedTypesMessage + '.'));\n }\n return createChainableTypeChecker(validate);\n }\n\n function createNodeChecker() {\n function validate(props, propName, componentName, location, propFullName) {\n if (!isNode(props[propName])) {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` supplied to ' + ('`' + componentName + '`, expected a ReactNode.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function invalidValidatorError(componentName, location, propFullName, key, type) {\n return new PropTypeError(\n (componentName || 'React class') + ': ' + location + ' type `' + propFullName + '.' + key + '` is invalid; ' +\n 'it must be a function, usually from the `prop-types` package, but received `' + type + '`.'\n );\n }\n\n function createShapeTypeChecker(shapeTypes) {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== 'object') {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type `' + propType + '` ' + ('supplied to `' + componentName + '`, expected `object`.'));\n }\n for (var key in shapeTypes) {\n var checker = shapeTypes[key];\n if (typeof checker !== 'function') {\n return invalidValidatorError(componentName, location, propFullName, key, getPreciseType(checker));\n }\n var error = checker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret);\n if (error) {\n return error;\n }\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createStrictShapeTypeChecker(shapeTypes) {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== 'object') {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type `' + propType + '` ' + ('supplied to `' + componentName + '`, expected `object`.'));\n }\n // We need to check all keys in case some are required but missing from props.\n var allKeys = assign({}, props[propName], shapeTypes);\n for (var key in allKeys) {\n var checker = shapeTypes[key];\n if (has(shapeTypes, key) && typeof checker !== 'function') {\n return invalidValidatorError(componentName, location, propFullName, key, getPreciseType(checker));\n }\n if (!checker) {\n return new PropTypeError(\n 'Invalid ' + location + ' `' + propFullName + '` key `' + key + '` supplied to `' + componentName + '`.' +\n '\\nBad object: ' + JSON.stringify(props[propName], null, ' ') +\n '\\nValid keys: ' + JSON.stringify(Object.keys(shapeTypes), null, ' ')\n );\n }\n var error = checker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret);\n if (error) {\n return error;\n }\n }\n return null;\n }\n\n return createChainableTypeChecker(validate);\n }\n\n function isNode(propValue) {\n switch (typeof propValue) {\n case 'number':\n case 'string':\n case 'undefined':\n return true;\n case 'boolean':\n return !propValue;\n case 'object':\n if (Array.isArray(propValue)) {\n return propValue.every(isNode);\n }\n if (propValue === null || isValidElement(propValue)) {\n return true;\n }\n\n var iteratorFn = getIteratorFn(propValue);\n if (iteratorFn) {\n var iterator = iteratorFn.call(propValue);\n var step;\n if (iteratorFn !== propValue.entries) {\n while (!(step = iterator.next()).done) {\n if (!isNode(step.value)) {\n return false;\n }\n }\n } else {\n // Iterator will provide entry [k,v] tuples rather than values.\n while (!(step = iterator.next()).done) {\n var entry = step.value;\n if (entry) {\n if (!isNode(entry[1])) {\n return false;\n }\n }\n }\n }\n } else {\n return false;\n }\n\n return true;\n default:\n return false;\n }\n }\n\n function isSymbol(propType, propValue) {\n // Native Symbol.\n if (propType === 'symbol') {\n return true;\n }\n\n // falsy value can't be a Symbol\n if (!propValue) {\n return false;\n }\n\n // 19.4.3.5 Symbol.prototype[@@toStringTag] === 'Symbol'\n if (propValue['@@toStringTag'] === 'Symbol') {\n return true;\n }\n\n // Fallback for non-spec compliant Symbols which are polyfilled.\n if (typeof Symbol === 'function' && propValue instanceof Symbol) {\n return true;\n }\n\n return false;\n }\n\n // Equivalent of `typeof` but with special handling for array and regexp.\n function getPropType(propValue) {\n var propType = typeof propValue;\n if (Array.isArray(propValue)) {\n return 'array';\n }\n if (propValue instanceof RegExp) {\n // Old webkits (at least until Android 4.0) return 'function' rather than\n // 'object' for typeof a RegExp. We'll normalize this here so that /bla/\n // passes PropTypes.object.\n return 'object';\n }\n if (isSymbol(propType, propValue)) {\n return 'symbol';\n }\n return propType;\n }\n\n // This handles more types than `getPropType`. Only used for error messages.\n // See `createPrimitiveTypeChecker`.\n function getPreciseType(propValue) {\n if (typeof propValue === 'undefined' || propValue === null) {\n return '' + propValue;\n }\n var propType = getPropType(propValue);\n if (propType === 'object') {\n if (propValue instanceof Date) {\n return 'date';\n } else if (propValue instanceof RegExp) {\n return 'regexp';\n }\n }\n return propType;\n }\n\n // Returns a string that is postfixed to a warning about an invalid type.\n // For example, \"undefined\" or \"of type array\"\n function getPostfixForTypeWarning(value) {\n var type = getPreciseType(value);\n switch (type) {\n case 'array':\n case 'object':\n return 'an ' + type;\n case 'boolean':\n case 'date':\n case 'regexp':\n return 'a ' + type;\n default:\n return type;\n }\n }\n\n // Returns class name of the object, if any.\n function getClassName(propValue) {\n if (!propValue.constructor || !propValue.constructor.name) {\n return ANONYMOUS;\n }\n return propValue.constructor.name;\n }\n\n ReactPropTypes.checkPropTypes = checkPropTypes;\n ReactPropTypes.resetWarningCache = checkPropTypes.resetWarningCache;\n ReactPropTypes.PropTypes = ReactPropTypes;\n\n return ReactPropTypes;\n};\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar ReactPropTypesSecret = require('./lib/ReactPropTypesSecret');\n\nfunction emptyFunction() {}\nfunction emptyFunctionWithReset() {}\nemptyFunctionWithReset.resetWarningCache = emptyFunction;\n\nmodule.exports = function() {\n function shim(props, propName, componentName, location, propFullName, secret) {\n if (secret === ReactPropTypesSecret) {\n // It is still safe when called from React.\n return;\n }\n var err = new Error(\n 'Calling PropTypes validators directly is not supported by the `prop-types` package. ' +\n 'Use PropTypes.checkPropTypes() to call them. ' +\n 'Read more at http://fb.me/use-check-prop-types'\n );\n err.name = 'Invariant Violation';\n throw err;\n };\n shim.isRequired = shim;\n function getShim() {\n return shim;\n };\n // Important!\n // Keep this list in sync with production version in `./factoryWithTypeCheckers.js`.\n var ReactPropTypes = {\n array: shim,\n bigint: shim,\n bool: shim,\n func: shim,\n number: shim,\n object: shim,\n string: shim,\n symbol: shim,\n\n any: shim,\n arrayOf: getShim,\n element: shim,\n elementType: shim,\n instanceOf: getShim,\n node: shim,\n objectOf: getShim,\n oneOf: getShim,\n oneOfType: getShim,\n shape: getShim,\n exact: getShim,\n\n checkPropTypes: emptyFunctionWithReset,\n resetWarningCache: emptyFunction\n };\n\n ReactPropTypes.PropTypes = ReactPropTypes;\n\n return ReactPropTypes;\n};\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\nif (process.env.NODE_ENV !== 'production') {\n var ReactIs = require('react-is');\n\n // By explicitly using `prop-types` you are opting into new development behavior.\n // http://fb.me/prop-types-in-prod\n var throwOnDirectAccess = true;\n module.exports = require('./factoryWithTypeCheckers')(ReactIs.isElement, throwOnDirectAccess);\n} else {\n // By explicitly using `prop-types` you are opting into new production behavior.\n // http://fb.me/prop-types-in-prod\n module.exports = require('./factoryWithThrowingShims')();\n}\n","import PropTypes from 'prop-types';\nimport chainPropTypes from '../chainPropTypes';\nfunction isClassComponent(elementType) {\n // elementType.prototype?.isReactComponent\n const {\n prototype = {}\n } = elementType;\n return Boolean(prototype.isReactComponent);\n}\nfunction acceptingRef(props, propName, componentName, location, propFullName) {\n const element = props[propName];\n const safePropName = propFullName || propName;\n if (element == null ||\n // When server-side rendering React doesn't warn either.\n // This is not an accurate check for SSR.\n // This is only in place for Emotion compat.\n // TODO: Revisit once https://github.com/facebook/react/issues/20047 is resolved.\n typeof window === 'undefined') {\n return null;\n }\n let warningHint;\n const elementType = element.type;\n /**\n * Blacklisting instead of whitelisting\n *\n * Blacklisting will miss some components, such as React.Fragment. Those will at least\n * trigger a warning in React.\n * We can't whitelist because there is no safe way to detect React.forwardRef\n * or class components. \"Safe\" means there's no public API.\n *\n */\n if (typeof elementType === 'function' && !isClassComponent(elementType)) {\n warningHint = 'Did you accidentally use a plain function component for an element instead?';\n }\n if (warningHint !== undefined) {\n return new Error(`Invalid ${location} \\`${safePropName}\\` supplied to \\`${componentName}\\`. ` + `Expected an element that can hold a ref. ${warningHint} ` + 'For more information see https://mui.com/r/caveat-with-refs-guide');\n }\n return null;\n}\nconst elementAcceptingRef = chainPropTypes(PropTypes.element, acceptingRef);\nelementAcceptingRef.isRequired = chainPropTypes(PropTypes.element.isRequired, acceptingRef);\nexport default elementAcceptingRef;","import _extends from \"@babel/runtime/helpers/esm/extends\";\n// This module is based on https://github.com/airbnb/prop-types-exact repository.\n// However, in order to reduce the number of dependencies and to remove some extra safe checks\n// the module was forked.\n\nconst specialProperty = 'exact-prop: \\u200b';\nexport default function exactProp(propTypes) {\n if (process.env.NODE_ENV === 'production') {\n return propTypes;\n }\n return _extends({}, propTypes, {\n [specialProperty]: props => {\n const unsupportedProps = Object.keys(props).filter(prop => !propTypes.hasOwnProperty(prop));\n if (unsupportedProps.length > 0) {\n return new Error(`The following props are not supported: ${unsupportedProps.map(prop => `\\`${prop}\\``).join(', ')}. Please remove them.`);\n }\n return null;\n }\n });\n}","/**\n * WARNING: Don't import this directly.\n * Use `MuiError` from `@mui/internal-babel-macros/MuiError.macro` instead.\n * @param {number} code\n */\nexport default function formatMuiErrorMessage(code) {\n // Apply babel-plugin-transform-template-literals in loose mode\n // loose mode is safe if we're concatenating primitives\n // see https://babeljs.io/docs/en/babel-plugin-transform-template-literals#loose\n /* eslint-disable prefer-template */\n let url = 'https://mui.com/production-error/?code=' + code;\n for (let i = 1; i < arguments.length; i += 1) {\n // rest params over-transpile for this case\n // eslint-disable-next-line prefer-rest-params\n url += '&args[]=' + encodeURIComponent(arguments[i]);\n }\n return 'Minified MUI error #' + code + '; visit ' + url + ' for the full message.';\n /* eslint-enable prefer-template */\n}","/**\n * @license React\n * react-is.production.min.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n'use strict';var b=Symbol.for(\"react.element\"),c=Symbol.for(\"react.portal\"),d=Symbol.for(\"react.fragment\"),e=Symbol.for(\"react.strict_mode\"),f=Symbol.for(\"react.profiler\"),g=Symbol.for(\"react.provider\"),h=Symbol.for(\"react.context\"),k=Symbol.for(\"react.server_context\"),l=Symbol.for(\"react.forward_ref\"),m=Symbol.for(\"react.suspense\"),n=Symbol.for(\"react.suspense_list\"),p=Symbol.for(\"react.memo\"),q=Symbol.for(\"react.lazy\"),t=Symbol.for(\"react.offscreen\"),u;u=Symbol.for(\"react.module.reference\");\nfunction v(a){if(\"object\"===typeof a&&null!==a){var r=a.$$typeof;switch(r){case b:switch(a=a.type,a){case d:case f:case e:case m:case n:return a;default:switch(a=a&&a.$$typeof,a){case k:case h:case l:case q:case p:case g:return a;default:return r}}case c:return r}}}exports.ContextConsumer=h;exports.ContextProvider=g;exports.Element=b;exports.ForwardRef=l;exports.Fragment=d;exports.Lazy=q;exports.Memo=p;exports.Portal=c;exports.Profiler=f;exports.StrictMode=e;exports.Suspense=m;\nexports.SuspenseList=n;exports.isAsyncMode=function(){return!1};exports.isConcurrentMode=function(){return!1};exports.isContextConsumer=function(a){return v(a)===h};exports.isContextProvider=function(a){return v(a)===g};exports.isElement=function(a){return\"object\"===typeof a&&null!==a&&a.$$typeof===b};exports.isForwardRef=function(a){return v(a)===l};exports.isFragment=function(a){return v(a)===d};exports.isLazy=function(a){return v(a)===q};exports.isMemo=function(a){return v(a)===p};\nexports.isPortal=function(a){return v(a)===c};exports.isProfiler=function(a){return v(a)===f};exports.isStrictMode=function(a){return v(a)===e};exports.isSuspense=function(a){return v(a)===m};exports.isSuspenseList=function(a){return v(a)===n};\nexports.isValidElementType=function(a){return\"string\"===typeof a||\"function\"===typeof a||a===d||a===f||a===e||a===m||a===n||a===t||\"object\"===typeof a&&null!==a&&(a.$$typeof===q||a.$$typeof===p||a.$$typeof===g||a.$$typeof===h||a.$$typeof===l||a.$$typeof===u||void 0!==a.getModuleId)?!0:!1};exports.typeOf=v;\n","/**\n * @license React\n * react-is.development.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nif (process.env.NODE_ENV !== \"production\") {\n (function() {\n'use strict';\n\n// ATTENTION\n// When adding new symbols to this file,\n// Please consider also adding to 'react-devtools-shared/src/backend/ReactSymbols'\n// The Symbol used to tag the ReactElement-like types.\nvar REACT_ELEMENT_TYPE = Symbol.for('react.element');\nvar REACT_PORTAL_TYPE = Symbol.for('react.portal');\nvar REACT_FRAGMENT_TYPE = Symbol.for('react.fragment');\nvar REACT_STRICT_MODE_TYPE = Symbol.for('react.strict_mode');\nvar REACT_PROFILER_TYPE = Symbol.for('react.profiler');\nvar REACT_PROVIDER_TYPE = Symbol.for('react.provider');\nvar REACT_CONTEXT_TYPE = Symbol.for('react.context');\nvar REACT_SERVER_CONTEXT_TYPE = Symbol.for('react.server_context');\nvar REACT_FORWARD_REF_TYPE = Symbol.for('react.forward_ref');\nvar REACT_SUSPENSE_TYPE = Symbol.for('react.suspense');\nvar REACT_SUSPENSE_LIST_TYPE = Symbol.for('react.suspense_list');\nvar REACT_MEMO_TYPE = Symbol.for('react.memo');\nvar REACT_LAZY_TYPE = Symbol.for('react.lazy');\nvar REACT_OFFSCREEN_TYPE = Symbol.for('react.offscreen');\n\n// -----------------------------------------------------------------------------\n\nvar enableScopeAPI = false; // Experimental Create Event Handle API.\nvar enableCacheElement = false;\nvar enableTransitionTracing = false; // No known bugs, but needs performance testing\n\nvar enableLegacyHidden = false; // Enables unstable_avoidThisFallback feature in Fiber\n// stuff. Intended to enable React core members to more easily debug scheduling\n// issues in DEV builds.\n\nvar enableDebugTracing = false; // Track which Fiber(s) schedule render work.\n\nvar REACT_MODULE_REFERENCE;\n\n{\n REACT_MODULE_REFERENCE = Symbol.for('react.module.reference');\n}\n\nfunction isValidElementType(type) {\n if (typeof type === 'string' || typeof type === 'function') {\n return true;\n } // Note: typeof might be other than 'symbol' or 'number' (e.g. if it's a polyfill).\n\n\n if (type === REACT_FRAGMENT_TYPE || type === REACT_PROFILER_TYPE || enableDebugTracing || type === REACT_STRICT_MODE_TYPE || type === REACT_SUSPENSE_TYPE || type === REACT_SUSPENSE_LIST_TYPE || enableLegacyHidden || type === REACT_OFFSCREEN_TYPE || enableScopeAPI || enableCacheElement || enableTransitionTracing ) {\n return true;\n }\n\n if (typeof type === 'object' && type !== null) {\n if (type.$$typeof === REACT_LAZY_TYPE || type.$$typeof === REACT_MEMO_TYPE || type.$$typeof === REACT_PROVIDER_TYPE || type.$$typeof === REACT_CONTEXT_TYPE || type.$$typeof === REACT_FORWARD_REF_TYPE || // This needs to include all possible module reference object\n // types supported by any Flight configuration anywhere since\n // we don't know which Flight build this will end up being used\n // with.\n type.$$typeof === REACT_MODULE_REFERENCE || type.getModuleId !== undefined) {\n return true;\n }\n }\n\n return false;\n}\n\nfunction typeOf(object) {\n if (typeof object === 'object' && object !== null) {\n var $$typeof = object.$$typeof;\n\n switch ($$typeof) {\n case REACT_ELEMENT_TYPE:\n var type = object.type;\n\n switch (type) {\n case REACT_FRAGMENT_TYPE:\n case REACT_PROFILER_TYPE:\n case REACT_STRICT_MODE_TYPE:\n case REACT_SUSPENSE_TYPE:\n case REACT_SUSPENSE_LIST_TYPE:\n return type;\n\n default:\n var $$typeofType = type && type.$$typeof;\n\n switch ($$typeofType) {\n case REACT_SERVER_CONTEXT_TYPE:\n case REACT_CONTEXT_TYPE:\n case REACT_FORWARD_REF_TYPE:\n case REACT_LAZY_TYPE:\n case REACT_MEMO_TYPE:\n case REACT_PROVIDER_TYPE:\n return $$typeofType;\n\n default:\n return $$typeof;\n }\n\n }\n\n case REACT_PORTAL_TYPE:\n return $$typeof;\n }\n }\n\n return undefined;\n}\nvar ContextConsumer = REACT_CONTEXT_TYPE;\nvar ContextProvider = REACT_PROVIDER_TYPE;\nvar Element = REACT_ELEMENT_TYPE;\nvar ForwardRef = REACT_FORWARD_REF_TYPE;\nvar Fragment = REACT_FRAGMENT_TYPE;\nvar Lazy = REACT_LAZY_TYPE;\nvar Memo = REACT_MEMO_TYPE;\nvar Portal = REACT_PORTAL_TYPE;\nvar Profiler = REACT_PROFILER_TYPE;\nvar StrictMode = REACT_STRICT_MODE_TYPE;\nvar Suspense = REACT_SUSPENSE_TYPE;\nvar SuspenseList = REACT_SUSPENSE_LIST_TYPE;\nvar hasWarnedAboutDeprecatedIsAsyncMode = false;\nvar hasWarnedAboutDeprecatedIsConcurrentMode = false; // AsyncMode should be deprecated\n\nfunction isAsyncMode(object) {\n {\n if (!hasWarnedAboutDeprecatedIsAsyncMode) {\n hasWarnedAboutDeprecatedIsAsyncMode = true; // Using console['warn'] to evade Babel and ESLint\n\n console['warn']('The ReactIs.isAsyncMode() alias has been deprecated, ' + 'and will be removed in React 18+.');\n }\n }\n\n return false;\n}\nfunction isConcurrentMode(object) {\n {\n if (!hasWarnedAboutDeprecatedIsConcurrentMode) {\n hasWarnedAboutDeprecatedIsConcurrentMode = true; // Using console['warn'] to evade Babel and ESLint\n\n console['warn']('The ReactIs.isConcurrentMode() alias has been deprecated, ' + 'and will be removed in React 18+.');\n }\n }\n\n return false;\n}\nfunction isContextConsumer(object) {\n return typeOf(object) === REACT_CONTEXT_TYPE;\n}\nfunction isContextProvider(object) {\n return typeOf(object) === REACT_PROVIDER_TYPE;\n}\nfunction isElement(object) {\n return typeof object === 'object' && object !== null && object.$$typeof === REACT_ELEMENT_TYPE;\n}\nfunction isForwardRef(object) {\n return typeOf(object) === REACT_FORWARD_REF_TYPE;\n}\nfunction isFragment(object) {\n return typeOf(object) === REACT_FRAGMENT_TYPE;\n}\nfunction isLazy(object) {\n return typeOf(object) === REACT_LAZY_TYPE;\n}\nfunction isMemo(object) {\n return typeOf(object) === REACT_MEMO_TYPE;\n}\nfunction isPortal(object) {\n return typeOf(object) === REACT_PORTAL_TYPE;\n}\nfunction isProfiler(object) {\n return typeOf(object) === REACT_PROFILER_TYPE;\n}\nfunction isStrictMode(object) {\n return typeOf(object) === REACT_STRICT_MODE_TYPE;\n}\nfunction isSuspense(object) {\n return typeOf(object) === REACT_SUSPENSE_TYPE;\n}\nfunction isSuspenseList(object) {\n return typeOf(object) === REACT_SUSPENSE_LIST_TYPE;\n}\n\nexports.ContextConsumer = ContextConsumer;\nexports.ContextProvider = ContextProvider;\nexports.Element = Element;\nexports.ForwardRef = ForwardRef;\nexports.Fragment = Fragment;\nexports.Lazy = Lazy;\nexports.Memo = Memo;\nexports.Portal = Portal;\nexports.Profiler = Profiler;\nexports.StrictMode = StrictMode;\nexports.Suspense = Suspense;\nexports.SuspenseList = SuspenseList;\nexports.isAsyncMode = isAsyncMode;\nexports.isConcurrentMode = isConcurrentMode;\nexports.isContextConsumer = isContextConsumer;\nexports.isContextProvider = isContextProvider;\nexports.isElement = isElement;\nexports.isForwardRef = isForwardRef;\nexports.isFragment = isFragment;\nexports.isLazy = isLazy;\nexports.isMemo = isMemo;\nexports.isPortal = isPortal;\nexports.isProfiler = isProfiler;\nexports.isStrictMode = isStrictMode;\nexports.isSuspense = isSuspense;\nexports.isSuspenseList = isSuspenseList;\nexports.isValidElementType = isValidElementType;\nexports.typeOf = typeOf;\n })();\n}\n","'use strict';\n\nif (process.env.NODE_ENV === 'production') {\n module.exports = require('./cjs/react-is.production.min.js');\n} else {\n module.exports = require('./cjs/react-is.development.js');\n}\n","import { ForwardRef, Memo } from 'react-is';\n\n// Simplified polyfill for IE11 support\n// https://github.com/JamesMGreene/Function.name/blob/58b314d4a983110c3682f1228f845d39ccca1817/Function.name.js#L3\nconst fnNameMatchRegex = /^\\s*function(?:\\s|\\s*\\/\\*.*\\*\\/\\s*)+([^(\\s/]*)\\s*/;\nexport function getFunctionName(fn) {\n const match = `${fn}`.match(fnNameMatchRegex);\n const name = match && match[1];\n return name || '';\n}\nfunction getFunctionComponentName(Component, fallback = '') {\n return Component.displayName || Component.name || getFunctionName(Component) || fallback;\n}\nfunction getWrappedName(outerType, innerType, wrapperName) {\n const functionName = getFunctionComponentName(innerType);\n return outerType.displayName || (functionName !== '' ? `${wrapperName}(${functionName})` : wrapperName);\n}\n\n/**\n * cherry-pick from\n * https://github.com/facebook/react/blob/769b1f270e1251d9dbdce0fcbd9e92e502d059b8/packages/shared/getComponentName.js\n * originally forked from recompose/getDisplayName with added IE11 support\n */\nexport default function getDisplayName(Component) {\n if (Component == null) {\n return undefined;\n }\n if (typeof Component === 'string') {\n return Component;\n }\n if (typeof Component === 'function') {\n return getFunctionComponentName(Component, 'Component');\n }\n\n // TypeScript can't have components as objects but they exist in the form of `memo` or `Suspense`\n if (typeof Component === 'object') {\n switch (Component.$$typeof) {\n case ForwardRef:\n return getWrappedName(Component, Component.render, 'ForwardRef');\n case Memo:\n return getWrappedName(Component, Component.type, 'memo');\n default:\n return undefined;\n }\n }\n return undefined;\n}","export default function HTMLElementType(props, propName, componentName, location, propFullName) {\n if (process.env.NODE_ENV === 'production') {\n return null;\n }\n const propValue = props[propName];\n const safePropName = propFullName || propName;\n if (propValue == null) {\n return null;\n }\n if (propValue && propValue.nodeType !== 1) {\n return new Error(`Invalid ${location} \\`${safePropName}\\` supplied to \\`${componentName}\\`. ` + `Expected an HTMLElement.`);\n }\n return null;\n}","import PropTypes from 'prop-types';\nconst refType = PropTypes.oneOfType([PropTypes.func, PropTypes.object]);\nexport default refType;","import _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\n// It should to be noted that this function isn't equivalent to `text-transform: capitalize`.\n//\n// A strict capitalization should uppercase the first letter of each word in the sentence.\n// We only handle the first word.\nexport default function capitalize(string) {\n if (typeof string !== 'string') {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: \\`capitalize(string)\\` expects a string argument.` : _formatMuiErrorMessage(7));\n }\n return string.charAt(0).toUpperCase() + string.slice(1);\n}","/**\n * Safe chained function.\n *\n * Will only create a new function if needed,\n * otherwise will pass back existing functions or null.\n */\nexport default function createChainedFunction(...funcs) {\n return funcs.reduce((acc, func) => {\n if (func == null) {\n return acc;\n }\n return function chainedFunction(...args) {\n acc.apply(this, args);\n func.apply(this, args);\n };\n }, () => {});\n}","// Corresponds to 10 frames at 60 Hz.\n// A few bytes payload overhead when lodash/debounce is ~3 kB and debounce ~300 B.\nexport default function debounce(func, wait = 166) {\n let timeout;\n function debounced(...args) {\n const later = () => {\n // @ts-ignore\n func.apply(this, args);\n };\n clearTimeout(timeout);\n timeout = setTimeout(later, wait);\n }\n debounced.clear = () => {\n clearTimeout(timeout);\n };\n return debounced;\n}","export default function deprecatedPropType(validator, reason) {\n if (process.env.NODE_ENV === 'production') {\n return () => null;\n }\n return (props, propName, componentName, location, propFullName) => {\n const componentNameSafe = componentName || '<>';\n const propFullNameSafe = propFullName || propName;\n if (typeof props[propName] !== 'undefined') {\n return new Error(`The ${location} \\`${propFullNameSafe}\\` of ` + `\\`${componentNameSafe}\\` is deprecated. ${reason}`);\n }\n return null;\n };\n}","import * as React from 'react';\nexport default function isMuiElement(element, muiNames) {\n var _muiName, _element$type;\n return /*#__PURE__*/React.isValidElement(element) && muiNames.indexOf( // For server components `muiName` is avaialble in element.type._payload.value.muiName\n // relevant info - https://github.com/facebook/react/blob/2807d781a08db8e9873687fccc25c0f12b4fb3d4/packages/react/src/ReactLazy.js#L45\n // eslint-disable-next-line no-underscore-dangle\n (_muiName = element.type.muiName) != null ? _muiName : (_element$type = element.type) == null || (_element$type = _element$type._payload) == null || (_element$type = _element$type.value) == null ? void 0 : _element$type.muiName) !== -1;\n}","export default function ownerDocument(node) {\n return node && node.ownerDocument || document;\n}","import ownerDocument from '../ownerDocument';\nexport default function ownerWindow(node) {\n const doc = ownerDocument(node);\n return doc.defaultView || window;\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nexport default function requirePropFactory(componentNameInError, Component) {\n if (process.env.NODE_ENV === 'production') {\n return () => null;\n }\n\n // eslint-disable-next-line react/forbid-foreign-prop-types\n const prevPropTypes = Component ? _extends({}, Component.propTypes) : null;\n const requireProp = requiredProp => (props, propName, componentName, location, propFullName, ...args) => {\n const propFullNameSafe = propFullName || propName;\n const defaultTypeChecker = prevPropTypes == null ? void 0 : prevPropTypes[propFullNameSafe];\n if (defaultTypeChecker) {\n const typeCheckerResult = defaultTypeChecker(props, propName, componentName, location, propFullName, ...args);\n if (typeCheckerResult) {\n return typeCheckerResult;\n }\n }\n if (typeof props[propName] !== 'undefined' && !props[requiredProp]) {\n return new Error(`The prop \\`${propFullNameSafe}\\` of ` + `\\`${componentNameInError}\\` can only be used together with the \\`${requiredProp}\\` prop.`);\n }\n return null;\n };\n return requireProp;\n}","/**\n * TODO v5: consider making it private\n *\n * passes {value} to {ref}\n *\n * WARNING: Be sure to only call this inside a callback that is passed as a ref.\n * Otherwise, make sure to cleanup the previous {ref} if it changes. See\n * https://github.com/mui/material-ui/issues/13539\n *\n * Useful if you want to expose the ref of an inner component to the public API\n * while still using it inside the component.\n * @param ref A ref callback or ref object. If anything falsy, this is a no-op.\n */\nexport default function setRef(ref, value) {\n if (typeof ref === 'function') {\n ref(value);\n } else if (ref) {\n ref.current = value;\n }\n}","'use client';\n\nimport * as React from 'react';\n\n/**\n * A version of `React.useLayoutEffect` that does not show a warning when server-side rendering.\n * This is useful for effects that are only needed for client-side rendering but not for SSR.\n *\n * Before you use this hook, make sure to read https://gist.github.com/gaearon/e7d97cdf38a2907924ea12e4ebdf3c85\n * and confirm it doesn't apply to your use-case.\n */\nconst useEnhancedEffect = typeof window !== 'undefined' ? React.useLayoutEffect : React.useEffect;\nexport default useEnhancedEffect;","'use client';\n\nimport * as React from 'react';\nlet globalId = 0;\nfunction useGlobalId(idOverride) {\n const [defaultId, setDefaultId] = React.useState(idOverride);\n const id = idOverride || defaultId;\n React.useEffect(() => {\n if (defaultId == null) {\n // Fallback to this default id when possible.\n // Use the incrementing value for client-side rendering only.\n // We can't use it server-side.\n // If you want to use random values please consider the Birthday Problem: https://en.wikipedia.org/wiki/Birthday_problem\n globalId += 1;\n setDefaultId(`mui-${globalId}`);\n }\n }, [defaultId]);\n return id;\n}\n\n// downstream bundlers may remove unnecessary concatenation, but won't remove toString call -- Workaround for https://github.com/webpack/webpack/issues/14814\nconst maybeReactUseId = React['useId'.toString()];\n/**\n *\n * @example
    \n * @param idOverride\n * @returns {string}\n */\nexport default function useId(idOverride) {\n if (maybeReactUseId !== undefined) {\n const reactId = maybeReactUseId();\n return idOverride != null ? idOverride : reactId;\n }\n // eslint-disable-next-line react-hooks/rules-of-hooks -- `React.useId` is invariant at runtime.\n return useGlobalId(idOverride);\n}","export default function unsupportedProp(props, propName, componentName, location, propFullName) {\n if (process.env.NODE_ENV === 'production') {\n return null;\n }\n const propFullNameSafe = propFullName || propName;\n if (typeof props[propName] !== 'undefined') {\n return new Error(`The prop \\`${propFullNameSafe}\\` is not supported. Please remove it.`);\n }\n return null;\n}","'use client';\n\n/* eslint-disable react-hooks/rules-of-hooks, react-hooks/exhaustive-deps */\nimport * as React from 'react';\nexport default function useControlled({\n controlled,\n default: defaultProp,\n name,\n state = 'value'\n}) {\n // isControlled is ignored in the hook dependency lists as it should never change.\n const {\n current: isControlled\n } = React.useRef(controlled !== undefined);\n const [valueState, setValue] = React.useState(defaultProp);\n const value = isControlled ? controlled : valueState;\n if (process.env.NODE_ENV !== 'production') {\n React.useEffect(() => {\n if (isControlled !== (controlled !== undefined)) {\n console.error([`MUI: A component is changing the ${isControlled ? '' : 'un'}controlled ${state} state of ${name} to be ${isControlled ? 'un' : ''}controlled.`, 'Elements should not switch from uncontrolled to controlled (or vice versa).', `Decide between using a controlled or uncontrolled ${name} ` + 'element for the lifetime of the component.', \"The nature of the state is determined during the first render. It's considered controlled if the value is not `undefined`.\", 'More info: https://fb.me/react-controlled-components'].join('\\n'));\n }\n }, [state, name, controlled]);\n const {\n current: defaultValue\n } = React.useRef(defaultProp);\n React.useEffect(() => {\n if (!isControlled && defaultValue !== defaultProp) {\n console.error([`MUI: A component is changing the default ${state} state of an uncontrolled ${name} after being initialized. ` + `To suppress this warning opt to use a controlled ${name}.`].join('\\n'));\n }\n }, [JSON.stringify(defaultProp)]);\n }\n const setValueIfUncontrolled = React.useCallback(newValue => {\n if (!isControlled) {\n setValue(newValue);\n }\n }, []);\n return [value, setValueIfUncontrolled];\n}","'use client';\n\nimport * as React from 'react';\nimport useEnhancedEffect from '../useEnhancedEffect';\n\n/**\n * Inspired by https://github.com/facebook/react/issues/14099#issuecomment-440013892\n * See RFC in https://github.com/reactjs/rfcs/pull/220\n */\n\nfunction useEventCallback(fn) {\n const ref = React.useRef(fn);\n useEnhancedEffect(() => {\n ref.current = fn;\n });\n return React.useRef((...args) =>\n // @ts-expect-error hide `this`\n (0, ref.current)(...args)).current;\n}\nexport default useEventCallback;","'use client';\n\nimport * as React from 'react';\nimport setRef from '../setRef';\nexport default function useForkRef(...refs) {\n /**\n * This will create a new function if the refs passed to this hook change and are all defined.\n * This means react will call the old forkRef with `null` and the new forkRef\n * with the ref. Cleanup naturally emerges from this behavior.\n */\n return React.useMemo(() => {\n if (refs.every(ref => ref == null)) {\n return null;\n }\n return instance => {\n refs.forEach(ref => {\n setRef(ref, instance);\n });\n };\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, refs);\n}","'use client';\n\nimport * as React from 'react';\nconst UNINITIALIZED = {};\n\n/**\n * A React.useRef() that is initialized lazily with a function. Note that it accepts an optional\n * initialization argument, so the initialization function doesn't need to be an inline closure.\n *\n * @usage\n * const ref = useLazyRef(sortColumns, columns)\n */\nexport default function useLazyRef(init, initArg) {\n const ref = React.useRef(UNINITIALIZED);\n if (ref.current === UNINITIALIZED) {\n ref.current = init(initArg);\n }\n return ref;\n}","'use client';\n\nimport * as React from 'react';\nconst EMPTY = [];\n\n/**\n * A React.useEffect equivalent that runs once, when the component is mounted.\n */\nexport default function useOnMount(fn) {\n /* eslint-disable react-hooks/exhaustive-deps */\n React.useEffect(fn, EMPTY);\n /* eslint-enable react-hooks/exhaustive-deps */\n}","'use client';\n\nimport useLazyRef from '../useLazyRef/useLazyRef';\nimport useOnMount from '../useOnMount/useOnMount';\nexport class Timeout {\n constructor() {\n this.currentId = null;\n this.clear = () => {\n if (this.currentId !== null) {\n clearTimeout(this.currentId);\n this.currentId = null;\n }\n };\n this.disposeEffect = () => {\n return this.clear;\n };\n }\n static create() {\n return new Timeout();\n }\n /**\n * Executes `fn` after `delay`, clearing any previously scheduled call.\n */\n start(delay, fn) {\n this.clear();\n this.currentId = setTimeout(() => {\n this.currentId = null;\n fn();\n }, delay);\n }\n}\nexport default function useTimeout() {\n const timeout = useLazyRef(Timeout.create).current;\n useOnMount(timeout.disposeEffect);\n return timeout;\n}","'use client';\n\n// based on https://github.com/WICG/focus-visible/blob/v4.1.5/src/focus-visible.js\nimport * as React from 'react';\nimport { Timeout } from '../useTimeout/useTimeout';\nlet hadKeyboardEvent = true;\nlet hadFocusVisibleRecently = false;\nconst hadFocusVisibleRecentlyTimeout = new Timeout();\nconst inputTypesWhitelist = {\n text: true,\n search: true,\n url: true,\n tel: true,\n email: true,\n password: true,\n number: true,\n date: true,\n month: true,\n week: true,\n time: true,\n datetime: true,\n 'datetime-local': true\n};\n\n/**\n * Computes whether the given element should automatically trigger the\n * `focus-visible` class being added, i.e. whether it should always match\n * `:focus-visible` when focused.\n * @param {Element} node\n * @returns {boolean}\n */\nfunction focusTriggersKeyboardModality(node) {\n const {\n type,\n tagName\n } = node;\n if (tagName === 'INPUT' && inputTypesWhitelist[type] && !node.readOnly) {\n return true;\n }\n if (tagName === 'TEXTAREA' && !node.readOnly) {\n return true;\n }\n if (node.isContentEditable) {\n return true;\n }\n return false;\n}\n\n/**\n * Keep track of our keyboard modality state with `hadKeyboardEvent`.\n * If the most recent user interaction was via the keyboard;\n * and the key press did not include a meta, alt/option, or control key;\n * then the modality is keyboard. Otherwise, the modality is not keyboard.\n * @param {KeyboardEvent} event\n */\nfunction handleKeyDown(event) {\n if (event.metaKey || event.altKey || event.ctrlKey) {\n return;\n }\n hadKeyboardEvent = true;\n}\n\n/**\n * If at any point a user clicks with a pointing device, ensure that we change\n * the modality away from keyboard.\n * This avoids the situation where a user presses a key on an already focused\n * element, and then clicks on a different element, focusing it with a\n * pointing device, while we still think we're in keyboard modality.\n */\nfunction handlePointerDown() {\n hadKeyboardEvent = false;\n}\nfunction handleVisibilityChange() {\n if (this.visibilityState === 'hidden') {\n // If the tab becomes active again, the browser will handle calling focus\n // on the element (Safari actually calls it twice).\n // If this tab change caused a blur on an element with focus-visible,\n // re-apply the class when the user switches back to the tab.\n if (hadFocusVisibleRecently) {\n hadKeyboardEvent = true;\n }\n }\n}\nfunction prepare(doc) {\n doc.addEventListener('keydown', handleKeyDown, true);\n doc.addEventListener('mousedown', handlePointerDown, true);\n doc.addEventListener('pointerdown', handlePointerDown, true);\n doc.addEventListener('touchstart', handlePointerDown, true);\n doc.addEventListener('visibilitychange', handleVisibilityChange, true);\n}\nexport function teardown(doc) {\n doc.removeEventListener('keydown', handleKeyDown, true);\n doc.removeEventListener('mousedown', handlePointerDown, true);\n doc.removeEventListener('pointerdown', handlePointerDown, true);\n doc.removeEventListener('touchstart', handlePointerDown, true);\n doc.removeEventListener('visibilitychange', handleVisibilityChange, true);\n}\nfunction isFocusVisible(event) {\n const {\n target\n } = event;\n try {\n return target.matches(':focus-visible');\n } catch (error) {\n // Browsers not implementing :focus-visible will throw a SyntaxError.\n // We use our own heuristic for those browsers.\n // Rethrow might be better if it's not the expected error but do we really\n // want to crash if focus-visible malfunctioned?\n }\n\n // No need for validFocusTarget check. The user does that by attaching it to\n // focusable events only.\n return hadKeyboardEvent || focusTriggersKeyboardModality(target);\n}\nexport default function useIsFocusVisible() {\n const ref = React.useCallback(node => {\n if (node != null) {\n prepare(node.ownerDocument);\n }\n }, []);\n const isFocusVisibleRef = React.useRef(false);\n\n /**\n * Should be called if a blur event is fired\n */\n function handleBlurVisible() {\n // checking against potential state variable does not suffice if we focus and blur synchronously.\n // React wouldn't have time to trigger a re-render so `focusVisible` would be stale.\n // Ideally we would adjust `isFocusVisible(event)` to look at `relatedTarget` for blur events.\n // This doesn't work in IE11 due to https://github.com/facebook/react/issues/3751\n // TODO: check again if React releases their internal changes to focus event handling (https://github.com/facebook/react/pull/19186).\n if (isFocusVisibleRef.current) {\n // To detect a tab/window switch, we look for a blur event followed\n // rapidly by a visibility change.\n // If we don't see a visibility change within 100ms, it's probably a\n // regular focus change.\n hadFocusVisibleRecently = true;\n hadFocusVisibleRecentlyTimeout.start(100, () => {\n hadFocusVisibleRecently = false;\n });\n isFocusVisibleRef.current = false;\n return true;\n }\n return false;\n }\n\n /**\n * Should be called if a blur event is fired\n */\n function handleFocusVisible(event) {\n if (isFocusVisible(event)) {\n isFocusVisibleRef.current = true;\n return true;\n }\n return false;\n }\n return {\n isFocusVisibleRef,\n onFocus: handleFocusVisible,\n onBlur: handleBlurVisible,\n ref\n };\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\n/**\n * Add keys, values of `defaultProps` that does not exist in `props`\n * @param {object} defaultProps\n * @param {object} props\n * @returns {object} resolved props\n */\nexport default function resolveProps(defaultProps, props) {\n const output = _extends({}, props);\n Object.keys(defaultProps).forEach(propName => {\n if (propName.toString().match(/^(components|slots)$/)) {\n output[propName] = _extends({}, defaultProps[propName], output[propName]);\n } else if (propName.toString().match(/^(componentsProps|slotProps)$/)) {\n const defaultSlotProps = defaultProps[propName] || {};\n const slotProps = props[propName];\n output[propName] = {};\n if (!slotProps || !Object.keys(slotProps)) {\n // Reduce the iteration if the slot props is empty\n output[propName] = defaultSlotProps;\n } else if (!defaultSlotProps || !Object.keys(defaultSlotProps)) {\n // Reduce the iteration if the default slot props is empty\n output[propName] = slotProps;\n } else {\n output[propName] = _extends({}, slotProps);\n Object.keys(defaultSlotProps).forEach(slotPropName => {\n output[propName][slotPropName] = resolveProps(defaultSlotProps[slotPropName], slotProps[slotPropName]);\n });\n }\n } else if (output[propName] === undefined) {\n output[propName] = defaultProps[propName];\n }\n });\n return output;\n}","export default function composeClasses(slots, getUtilityClass, classes = undefined) {\n const output = {};\n Object.keys(slots).forEach(\n // `Object.keys(slots)` can't be wider than `T` because we infer `T` from `slots`.\n // @ts-expect-error https://github.com/microsoft/TypeScript/pull/12253#issuecomment-263132208\n slot => {\n output[slot] = slots[slot].reduce((acc, key) => {\n if (key) {\n const utilityClass = getUtilityClass(key);\n if (utilityClass !== '') {\n acc.push(utilityClass);\n }\n if (classes && classes[key]) {\n acc.push(classes[key]);\n }\n }\n return acc;\n }, []).join(' ');\n });\n return output;\n}","const defaultGenerator = componentName => componentName;\nconst createClassNameGenerator = () => {\n let generate = defaultGenerator;\n return {\n configure(generator) {\n generate = generator;\n },\n generate(componentName) {\n return generate(componentName);\n },\n reset() {\n generate = defaultGenerator;\n }\n };\n};\nconst ClassNameGenerator = createClassNameGenerator();\nexport default ClassNameGenerator;","import ClassNameGenerator from '../ClassNameGenerator';\nexport const globalStateClasses = {\n active: 'active',\n checked: 'checked',\n completed: 'completed',\n disabled: 'disabled',\n error: 'error',\n expanded: 'expanded',\n focused: 'focused',\n focusVisible: 'focusVisible',\n open: 'open',\n readOnly: 'readOnly',\n required: 'required',\n selected: 'selected'\n};\nexport default function generateUtilityClass(componentName, slot, globalStatePrefix = 'Mui') {\n const globalStateClass = globalStateClasses[slot];\n return globalStateClass ? `${globalStatePrefix}-${globalStateClass}` : `${ClassNameGenerator.generate(componentName)}-${slot}`;\n}\nexport function isGlobalState(slot) {\n return globalStateClasses[slot] !== undefined;\n}","import generateUtilityClass from '../generateUtilityClass';\nexport default function generateUtilityClasses(componentName, slots, globalStatePrefix = 'Mui') {\n const result = {};\n slots.forEach(slot => {\n result[slot] = generateUtilityClass(componentName, slot, globalStatePrefix);\n });\n return result;\n}","function clamp(val, min = Number.MIN_SAFE_INTEGER, max = Number.MAX_SAFE_INTEGER) {\n return Math.max(min, Math.min(val, max));\n}\nexport default clamp;","export default function _objectWithoutPropertiesLoose(source, excluded) {\n if (source == null) return {};\n var target = {};\n var sourceKeys = Object.keys(source);\n var key, i;\n for (i = 0; i < sourceKeys.length; i++) {\n key = sourceKeys[i];\n if (excluded.indexOf(key) >= 0) continue;\n target[key] = source[key];\n }\n return target;\n}","import _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nconst _excluded = [\"values\", \"unit\", \"step\"];\n// Sorted ASC by size. That's important.\n// It can't be configured as it's used statically for propTypes.\nexport const breakpointKeys = ['xs', 'sm', 'md', 'lg', 'xl'];\nconst sortBreakpointsValues = values => {\n const breakpointsAsArray = Object.keys(values).map(key => ({\n key,\n val: values[key]\n })) || [];\n // Sort in ascending order\n breakpointsAsArray.sort((breakpoint1, breakpoint2) => breakpoint1.val - breakpoint2.val);\n return breakpointsAsArray.reduce((acc, obj) => {\n return _extends({}, acc, {\n [obj.key]: obj.val\n });\n }, {});\n};\n\n// Keep in mind that @media is inclusive by the CSS specification.\nexport default function createBreakpoints(breakpoints) {\n const {\n // The breakpoint **start** at this value.\n // For instance with the first breakpoint xs: [xs, sm).\n values = {\n xs: 0,\n // phone\n sm: 600,\n // tablet\n md: 900,\n // small laptop\n lg: 1200,\n // desktop\n xl: 1536 // large screen\n },\n unit = 'px',\n step = 5\n } = breakpoints,\n other = _objectWithoutPropertiesLoose(breakpoints, _excluded);\n const sortedValues = sortBreakpointsValues(values);\n const keys = Object.keys(sortedValues);\n function up(key) {\n const value = typeof values[key] === 'number' ? values[key] : key;\n return `@media (min-width:${value}${unit})`;\n }\n function down(key) {\n const value = typeof values[key] === 'number' ? values[key] : key;\n return `@media (max-width:${value - step / 100}${unit})`;\n }\n function between(start, end) {\n const endIndex = keys.indexOf(end);\n return `@media (min-width:${typeof values[start] === 'number' ? values[start] : start}${unit}) and ` + `(max-width:${(endIndex !== -1 && typeof values[keys[endIndex]] === 'number' ? values[keys[endIndex]] : end) - step / 100}${unit})`;\n }\n function only(key) {\n if (keys.indexOf(key) + 1 < keys.length) {\n return between(key, keys[keys.indexOf(key) + 1]);\n }\n return up(key);\n }\n function not(key) {\n // handle first and last key separately, for better readability\n const keyIndex = keys.indexOf(key);\n if (keyIndex === 0) {\n return up(keys[1]);\n }\n if (keyIndex === keys.length - 1) {\n return down(keys[keyIndex]);\n }\n return between(key, keys[keys.indexOf(key) + 1]).replace('@media', '@media not all and');\n }\n return _extends({\n keys,\n values: sortedValues,\n up,\n down,\n between,\n only,\n not,\n unit\n }, other);\n}","const shape = {\n borderRadius: 4\n};\nexport default shape;","import PropTypes from 'prop-types';\nconst responsivePropType = process.env.NODE_ENV !== 'production' ? PropTypes.oneOfType([PropTypes.number, PropTypes.string, PropTypes.object, PropTypes.array]) : {};\nexport default responsivePropType;","import deepmerge from '@mui/utils/deepmerge';\nfunction merge(acc, item) {\n if (!item) {\n return acc;\n }\n return deepmerge(acc, item, {\n clone: false // No need to clone deep, it's way faster.\n });\n}\nexport default merge;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport PropTypes from 'prop-types';\nimport deepmerge from '@mui/utils/deepmerge';\nimport merge from './merge';\n\n// The breakpoint **start** at this value.\n// For instance with the first breakpoint xs: [xs, sm[.\nexport const values = {\n xs: 0,\n // phone\n sm: 600,\n // tablet\n md: 900,\n // small laptop\n lg: 1200,\n // desktop\n xl: 1536 // large screen\n};\nconst defaultBreakpoints = {\n // Sorted ASC by size. That's important.\n // It can't be configured as it's used statically for propTypes.\n keys: ['xs', 'sm', 'md', 'lg', 'xl'],\n up: key => `@media (min-width:${values[key]}px)`\n};\nexport function handleBreakpoints(props, propValue, styleFromPropValue) {\n const theme = props.theme || {};\n if (Array.isArray(propValue)) {\n const themeBreakpoints = theme.breakpoints || defaultBreakpoints;\n return propValue.reduce((acc, item, index) => {\n acc[themeBreakpoints.up(themeBreakpoints.keys[index])] = styleFromPropValue(propValue[index]);\n return acc;\n }, {});\n }\n if (typeof propValue === 'object') {\n const themeBreakpoints = theme.breakpoints || defaultBreakpoints;\n return Object.keys(propValue).reduce((acc, breakpoint) => {\n // key is breakpoint\n if (Object.keys(themeBreakpoints.values || values).indexOf(breakpoint) !== -1) {\n const mediaKey = themeBreakpoints.up(breakpoint);\n acc[mediaKey] = styleFromPropValue(propValue[breakpoint], breakpoint);\n } else {\n const cssKey = breakpoint;\n acc[cssKey] = propValue[cssKey];\n }\n return acc;\n }, {});\n }\n const output = styleFromPropValue(propValue);\n return output;\n}\nfunction breakpoints(styleFunction) {\n // false positive\n // eslint-disable-next-line react/function-component-definition\n const newStyleFunction = props => {\n const theme = props.theme || {};\n const base = styleFunction(props);\n const themeBreakpoints = theme.breakpoints || defaultBreakpoints;\n const extended = themeBreakpoints.keys.reduce((acc, key) => {\n if (props[key]) {\n acc = acc || {};\n acc[themeBreakpoints.up(key)] = styleFunction(_extends({\n theme\n }, props[key]));\n }\n return acc;\n }, null);\n return merge(base, extended);\n };\n newStyleFunction.propTypes = process.env.NODE_ENV !== 'production' ? _extends({}, styleFunction.propTypes, {\n xs: PropTypes.object,\n sm: PropTypes.object,\n md: PropTypes.object,\n lg: PropTypes.object,\n xl: PropTypes.object\n }) : {};\n newStyleFunction.filterProps = ['xs', 'sm', 'md', 'lg', 'xl', ...styleFunction.filterProps];\n return newStyleFunction;\n}\nexport function createEmptyBreakpointObject(breakpointsInput = {}) {\n var _breakpointsInput$key;\n const breakpointsInOrder = (_breakpointsInput$key = breakpointsInput.keys) == null ? void 0 : _breakpointsInput$key.reduce((acc, key) => {\n const breakpointStyleKey = breakpointsInput.up(key);\n acc[breakpointStyleKey] = {};\n return acc;\n }, {});\n return breakpointsInOrder || {};\n}\nexport function removeUnusedBreakpoints(breakpointKeys, style) {\n return breakpointKeys.reduce((acc, key) => {\n const breakpointOutput = acc[key];\n const isBreakpointUnused = !breakpointOutput || Object.keys(breakpointOutput).length === 0;\n if (isBreakpointUnused) {\n delete acc[key];\n }\n return acc;\n }, style);\n}\nexport function mergeBreakpointsInOrder(breakpointsInput, ...styles) {\n const emptyBreakpoints = createEmptyBreakpointObject(breakpointsInput);\n const mergedOutput = [emptyBreakpoints, ...styles].reduce((prev, next) => deepmerge(prev, next), {});\n return removeUnusedBreakpoints(Object.keys(emptyBreakpoints), mergedOutput);\n}\n\n// compute base for responsive values; e.g.,\n// [1,2,3] => {xs: true, sm: true, md: true}\n// {xs: 1, sm: 2, md: 3} => {xs: true, sm: true, md: true}\nexport function computeBreakpointsBase(breakpointValues, themeBreakpoints) {\n // fixed value\n if (typeof breakpointValues !== 'object') {\n return {};\n }\n const base = {};\n const breakpointsKeys = Object.keys(themeBreakpoints);\n if (Array.isArray(breakpointValues)) {\n breakpointsKeys.forEach((breakpoint, i) => {\n if (i < breakpointValues.length) {\n base[breakpoint] = true;\n }\n });\n } else {\n breakpointsKeys.forEach(breakpoint => {\n if (breakpointValues[breakpoint] != null) {\n base[breakpoint] = true;\n }\n });\n }\n return base;\n}\nexport function resolveBreakpointValues({\n values: breakpointValues,\n breakpoints: themeBreakpoints,\n base: customBase\n}) {\n const base = customBase || computeBreakpointsBase(breakpointValues, themeBreakpoints);\n const keys = Object.keys(base);\n if (keys.length === 0) {\n return breakpointValues;\n }\n let previous;\n return keys.reduce((acc, breakpoint, i) => {\n if (Array.isArray(breakpointValues)) {\n acc[breakpoint] = breakpointValues[i] != null ? breakpointValues[i] : breakpointValues[previous];\n previous = i;\n } else if (typeof breakpointValues === 'object') {\n acc[breakpoint] = breakpointValues[breakpoint] != null ? breakpointValues[breakpoint] : breakpointValues[previous];\n previous = breakpoint;\n } else {\n acc[breakpoint] = breakpointValues;\n }\n return acc;\n }, {});\n}\nexport default breakpoints;","import capitalize from '@mui/utils/capitalize';\nimport responsivePropType from './responsivePropType';\nimport { handleBreakpoints } from './breakpoints';\nexport function getPath(obj, path, checkVars = true) {\n if (!path || typeof path !== 'string') {\n return null;\n }\n\n // Check if CSS variables are used\n if (obj && obj.vars && checkVars) {\n const val = `vars.${path}`.split('.').reduce((acc, item) => acc && acc[item] ? acc[item] : null, obj);\n if (val != null) {\n return val;\n }\n }\n return path.split('.').reduce((acc, item) => {\n if (acc && acc[item] != null) {\n return acc[item];\n }\n return null;\n }, obj);\n}\nexport function getStyleValue(themeMapping, transform, propValueFinal, userValue = propValueFinal) {\n let value;\n if (typeof themeMapping === 'function') {\n value = themeMapping(propValueFinal);\n } else if (Array.isArray(themeMapping)) {\n value = themeMapping[propValueFinal] || userValue;\n } else {\n value = getPath(themeMapping, propValueFinal) || userValue;\n }\n if (transform) {\n value = transform(value, userValue, themeMapping);\n }\n return value;\n}\nfunction style(options) {\n const {\n prop,\n cssProperty = options.prop,\n themeKey,\n transform\n } = options;\n\n // false positive\n // eslint-disable-next-line react/function-component-definition\n const fn = props => {\n if (props[prop] == null) {\n return null;\n }\n const propValue = props[prop];\n const theme = props.theme;\n const themeMapping = getPath(theme, themeKey) || {};\n const styleFromPropValue = propValueFinal => {\n let value = getStyleValue(themeMapping, transform, propValueFinal);\n if (propValueFinal === value && typeof propValueFinal === 'string') {\n // Haven't found value\n value = getStyleValue(themeMapping, transform, `${prop}${propValueFinal === 'default' ? '' : capitalize(propValueFinal)}`, propValueFinal);\n }\n if (cssProperty === false) {\n return value;\n }\n return {\n [cssProperty]: value\n };\n };\n return handleBreakpoints(props, propValue, styleFromPropValue);\n };\n fn.propTypes = process.env.NODE_ENV !== 'production' ? {\n [prop]: responsivePropType\n } : {};\n fn.filterProps = [prop];\n return fn;\n}\nexport default style;","export default function memoize(fn) {\n const cache = {};\n return arg => {\n if (cache[arg] === undefined) {\n cache[arg] = fn(arg);\n }\n return cache[arg];\n };\n}","import responsivePropType from './responsivePropType';\nimport { handleBreakpoints } from './breakpoints';\nimport { getPath } from './style';\nimport merge from './merge';\nimport memoize from './memoize';\nconst properties = {\n m: 'margin',\n p: 'padding'\n};\nconst directions = {\n t: 'Top',\n r: 'Right',\n b: 'Bottom',\n l: 'Left',\n x: ['Left', 'Right'],\n y: ['Top', 'Bottom']\n};\nconst aliases = {\n marginX: 'mx',\n marginY: 'my',\n paddingX: 'px',\n paddingY: 'py'\n};\n\n// memoize() impact:\n// From 300,000 ops/sec\n// To 350,000 ops/sec\nconst getCssProperties = memoize(prop => {\n // It's not a shorthand notation.\n if (prop.length > 2) {\n if (aliases[prop]) {\n prop = aliases[prop];\n } else {\n return [prop];\n }\n }\n const [a, b] = prop.split('');\n const property = properties[a];\n const direction = directions[b] || '';\n return Array.isArray(direction) ? direction.map(dir => property + dir) : [property + direction];\n});\nexport const marginKeys = ['m', 'mt', 'mr', 'mb', 'ml', 'mx', 'my', 'margin', 'marginTop', 'marginRight', 'marginBottom', 'marginLeft', 'marginX', 'marginY', 'marginInline', 'marginInlineStart', 'marginInlineEnd', 'marginBlock', 'marginBlockStart', 'marginBlockEnd'];\nexport const paddingKeys = ['p', 'pt', 'pr', 'pb', 'pl', 'px', 'py', 'padding', 'paddingTop', 'paddingRight', 'paddingBottom', 'paddingLeft', 'paddingX', 'paddingY', 'paddingInline', 'paddingInlineStart', 'paddingInlineEnd', 'paddingBlock', 'paddingBlockStart', 'paddingBlockEnd'];\nconst spacingKeys = [...marginKeys, ...paddingKeys];\nexport function createUnaryUnit(theme, themeKey, defaultValue, propName) {\n var _getPath;\n const themeSpacing = (_getPath = getPath(theme, themeKey, false)) != null ? _getPath : defaultValue;\n if (typeof themeSpacing === 'number') {\n return abs => {\n if (typeof abs === 'string') {\n return abs;\n }\n if (process.env.NODE_ENV !== 'production') {\n if (typeof abs !== 'number') {\n console.error(`MUI: Expected ${propName} argument to be a number or a string, got ${abs}.`);\n }\n }\n return themeSpacing * abs;\n };\n }\n if (Array.isArray(themeSpacing)) {\n return abs => {\n if (typeof abs === 'string') {\n return abs;\n }\n if (process.env.NODE_ENV !== 'production') {\n if (!Number.isInteger(abs)) {\n console.error([`MUI: The \\`theme.${themeKey}\\` array type cannot be combined with non integer values.` + `You should either use an integer value that can be used as index, or define the \\`theme.${themeKey}\\` as a number.`].join('\\n'));\n } else if (abs > themeSpacing.length - 1) {\n console.error([`MUI: The value provided (${abs}) overflows.`, `The supported values are: ${JSON.stringify(themeSpacing)}.`, `${abs} > ${themeSpacing.length - 1}, you need to add the missing values.`].join('\\n'));\n }\n }\n return themeSpacing[abs];\n };\n }\n if (typeof themeSpacing === 'function') {\n return themeSpacing;\n }\n if (process.env.NODE_ENV !== 'production') {\n console.error([`MUI: The \\`theme.${themeKey}\\` value (${themeSpacing}) is invalid.`, 'It should be a number, an array or a function.'].join('\\n'));\n }\n return () => undefined;\n}\nexport function createUnarySpacing(theme) {\n return createUnaryUnit(theme, 'spacing', 8, 'spacing');\n}\nexport function getValue(transformer, propValue) {\n if (typeof propValue === 'string' || propValue == null) {\n return propValue;\n }\n const abs = Math.abs(propValue);\n const transformed = transformer(abs);\n if (propValue >= 0) {\n return transformed;\n }\n if (typeof transformed === 'number') {\n return -transformed;\n }\n return `-${transformed}`;\n}\nexport function getStyleFromPropValue(cssProperties, transformer) {\n return propValue => cssProperties.reduce((acc, cssProperty) => {\n acc[cssProperty] = getValue(transformer, propValue);\n return acc;\n }, {});\n}\nfunction resolveCssProperty(props, keys, prop, transformer) {\n // Using a hash computation over an array iteration could be faster, but with only 28 items,\n // it's doesn't worth the bundle size.\n if (keys.indexOf(prop) === -1) {\n return null;\n }\n const cssProperties = getCssProperties(prop);\n const styleFromPropValue = getStyleFromPropValue(cssProperties, transformer);\n const propValue = props[prop];\n return handleBreakpoints(props, propValue, styleFromPropValue);\n}\nfunction style(props, keys) {\n const transformer = createUnarySpacing(props.theme);\n return Object.keys(props).map(prop => resolveCssProperty(props, keys, prop, transformer)).reduce(merge, {});\n}\nexport function margin(props) {\n return style(props, marginKeys);\n}\nmargin.propTypes = process.env.NODE_ENV !== 'production' ? marginKeys.reduce((obj, key) => {\n obj[key] = responsivePropType;\n return obj;\n}, {}) : {};\nmargin.filterProps = marginKeys;\nexport function padding(props) {\n return style(props, paddingKeys);\n}\npadding.propTypes = process.env.NODE_ENV !== 'production' ? paddingKeys.reduce((obj, key) => {\n obj[key] = responsivePropType;\n return obj;\n}, {}) : {};\npadding.filterProps = paddingKeys;\nfunction spacing(props) {\n return style(props, spacingKeys);\n}\nspacing.propTypes = process.env.NODE_ENV !== 'production' ? spacingKeys.reduce((obj, key) => {\n obj[key] = responsivePropType;\n return obj;\n}, {}) : {};\nspacing.filterProps = spacingKeys;\nexport default spacing;","import { createUnarySpacing } from '../spacing';\n\n// The different signatures imply different meaning for their arguments that can't be expressed structurally.\n// We express the difference with variable names.\n\nexport default function createSpacing(spacingInput = 8) {\n // Already transformed.\n if (spacingInput.mui) {\n return spacingInput;\n }\n\n // Material Design layouts are visually balanced. Most measurements align to an 8dp grid, which aligns both spacing and the overall layout.\n // Smaller components, such as icons, can align to a 4dp grid.\n // https://m2.material.io/design/layout/understanding-layout.html\n const transform = createUnarySpacing({\n spacing: spacingInput\n });\n const spacing = (...argsInput) => {\n if (process.env.NODE_ENV !== 'production') {\n if (!(argsInput.length <= 4)) {\n console.error(`MUI: Too many arguments provided, expected between 0 and 4, got ${argsInput.length}`);\n }\n }\n const args = argsInput.length === 0 ? [1] : argsInput;\n return args.map(argument => {\n const output = transform(argument);\n return typeof output === 'number' ? `${output}px` : output;\n }).join(' ');\n };\n spacing.mui = true;\n return spacing;\n}","import merge from './merge';\nfunction compose(...styles) {\n const handlers = styles.reduce((acc, style) => {\n style.filterProps.forEach(prop => {\n acc[prop] = style;\n });\n return acc;\n }, {});\n\n // false positive\n // eslint-disable-next-line react/function-component-definition\n const fn = props => {\n return Object.keys(props).reduce((acc, prop) => {\n if (handlers[prop]) {\n return merge(acc, handlers[prop](props));\n }\n return acc;\n }, {});\n };\n fn.propTypes = process.env.NODE_ENV !== 'production' ? styles.reduce((acc, style) => Object.assign(acc, style.propTypes), {}) : {};\n fn.filterProps = styles.reduce((acc, style) => acc.concat(style.filterProps), []);\n return fn;\n}\nexport default compose;","import responsivePropType from './responsivePropType';\nimport style from './style';\nimport compose from './compose';\nimport { createUnaryUnit, getValue } from './spacing';\nimport { handleBreakpoints } from './breakpoints';\nexport function borderTransform(value) {\n if (typeof value !== 'number') {\n return value;\n }\n return `${value}px solid`;\n}\nfunction createBorderStyle(prop, transform) {\n return style({\n prop,\n themeKey: 'borders',\n transform\n });\n}\nexport const border = createBorderStyle('border', borderTransform);\nexport const borderTop = createBorderStyle('borderTop', borderTransform);\nexport const borderRight = createBorderStyle('borderRight', borderTransform);\nexport const borderBottom = createBorderStyle('borderBottom', borderTransform);\nexport const borderLeft = createBorderStyle('borderLeft', borderTransform);\nexport const borderColor = createBorderStyle('borderColor');\nexport const borderTopColor = createBorderStyle('borderTopColor');\nexport const borderRightColor = createBorderStyle('borderRightColor');\nexport const borderBottomColor = createBorderStyle('borderBottomColor');\nexport const borderLeftColor = createBorderStyle('borderLeftColor');\nexport const outline = createBorderStyle('outline', borderTransform);\nexport const outlineColor = createBorderStyle('outlineColor');\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const borderRadius = props => {\n if (props.borderRadius !== undefined && props.borderRadius !== null) {\n const transformer = createUnaryUnit(props.theme, 'shape.borderRadius', 4, 'borderRadius');\n const styleFromPropValue = propValue => ({\n borderRadius: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.borderRadius, styleFromPropValue);\n }\n return null;\n};\nborderRadius.propTypes = process.env.NODE_ENV !== 'production' ? {\n borderRadius: responsivePropType\n} : {};\nborderRadius.filterProps = ['borderRadius'];\nconst borders = compose(border, borderTop, borderRight, borderBottom, borderLeft, borderColor, borderTopColor, borderRightColor, borderBottomColor, borderLeftColor, borderRadius, outline, outlineColor);\nexport default borders;","import style from './style';\nimport compose from './compose';\nimport { createUnaryUnit, getValue } from './spacing';\nimport { handleBreakpoints } from './breakpoints';\nimport responsivePropType from './responsivePropType';\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const gap = props => {\n if (props.gap !== undefined && props.gap !== null) {\n const transformer = createUnaryUnit(props.theme, 'spacing', 8, 'gap');\n const styleFromPropValue = propValue => ({\n gap: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.gap, styleFromPropValue);\n }\n return null;\n};\ngap.propTypes = process.env.NODE_ENV !== 'production' ? {\n gap: responsivePropType\n} : {};\ngap.filterProps = ['gap'];\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const columnGap = props => {\n if (props.columnGap !== undefined && props.columnGap !== null) {\n const transformer = createUnaryUnit(props.theme, 'spacing', 8, 'columnGap');\n const styleFromPropValue = propValue => ({\n columnGap: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.columnGap, styleFromPropValue);\n }\n return null;\n};\ncolumnGap.propTypes = process.env.NODE_ENV !== 'production' ? {\n columnGap: responsivePropType\n} : {};\ncolumnGap.filterProps = ['columnGap'];\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const rowGap = props => {\n if (props.rowGap !== undefined && props.rowGap !== null) {\n const transformer = createUnaryUnit(props.theme, 'spacing', 8, 'rowGap');\n const styleFromPropValue = propValue => ({\n rowGap: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.rowGap, styleFromPropValue);\n }\n return null;\n};\nrowGap.propTypes = process.env.NODE_ENV !== 'production' ? {\n rowGap: responsivePropType\n} : {};\nrowGap.filterProps = ['rowGap'];\nexport const gridColumn = style({\n prop: 'gridColumn'\n});\nexport const gridRow = style({\n prop: 'gridRow'\n});\nexport const gridAutoFlow = style({\n prop: 'gridAutoFlow'\n});\nexport const gridAutoColumns = style({\n prop: 'gridAutoColumns'\n});\nexport const gridAutoRows = style({\n prop: 'gridAutoRows'\n});\nexport const gridTemplateColumns = style({\n prop: 'gridTemplateColumns'\n});\nexport const gridTemplateRows = style({\n prop: 'gridTemplateRows'\n});\nexport const gridTemplateAreas = style({\n prop: 'gridTemplateAreas'\n});\nexport const gridArea = style({\n prop: 'gridArea'\n});\nconst grid = compose(gap, columnGap, rowGap, gridColumn, gridRow, gridAutoFlow, gridAutoColumns, gridAutoRows, gridTemplateColumns, gridTemplateRows, gridTemplateAreas, gridArea);\nexport default grid;","import style from './style';\nimport compose from './compose';\nexport function paletteTransform(value, userValue) {\n if (userValue === 'grey') {\n return userValue;\n }\n return value;\n}\nexport const color = style({\n prop: 'color',\n themeKey: 'palette',\n transform: paletteTransform\n});\nexport const bgcolor = style({\n prop: 'bgcolor',\n cssProperty: 'backgroundColor',\n themeKey: 'palette',\n transform: paletteTransform\n});\nexport const backgroundColor = style({\n prop: 'backgroundColor',\n themeKey: 'palette',\n transform: paletteTransform\n});\nconst palette = compose(color, bgcolor, backgroundColor);\nexport default palette;","import style from './style';\nimport compose from './compose';\nimport { handleBreakpoints, values as breakpointsValues } from './breakpoints';\nexport function sizingTransform(value) {\n return value <= 1 && value !== 0 ? `${value * 100}%` : value;\n}\nexport const width = style({\n prop: 'width',\n transform: sizingTransform\n});\nexport const maxWidth = props => {\n if (props.maxWidth !== undefined && props.maxWidth !== null) {\n const styleFromPropValue = propValue => {\n var _props$theme, _props$theme2;\n const breakpoint = ((_props$theme = props.theme) == null || (_props$theme = _props$theme.breakpoints) == null || (_props$theme = _props$theme.values) == null ? void 0 : _props$theme[propValue]) || breakpointsValues[propValue];\n if (!breakpoint) {\n return {\n maxWidth: sizingTransform(propValue)\n };\n }\n if (((_props$theme2 = props.theme) == null || (_props$theme2 = _props$theme2.breakpoints) == null ? void 0 : _props$theme2.unit) !== 'px') {\n return {\n maxWidth: `${breakpoint}${props.theme.breakpoints.unit}`\n };\n }\n return {\n maxWidth: breakpoint\n };\n };\n return handleBreakpoints(props, props.maxWidth, styleFromPropValue);\n }\n return null;\n};\nmaxWidth.filterProps = ['maxWidth'];\nexport const minWidth = style({\n prop: 'minWidth',\n transform: sizingTransform\n});\nexport const height = style({\n prop: 'height',\n transform: sizingTransform\n});\nexport const maxHeight = style({\n prop: 'maxHeight',\n transform: sizingTransform\n});\nexport const minHeight = style({\n prop: 'minHeight',\n transform: sizingTransform\n});\nexport const sizeWidth = style({\n prop: 'size',\n cssProperty: 'width',\n transform: sizingTransform\n});\nexport const sizeHeight = style({\n prop: 'size',\n cssProperty: 'height',\n transform: sizingTransform\n});\nexport const boxSizing = style({\n prop: 'boxSizing'\n});\nconst sizing = compose(width, maxWidth, minWidth, height, maxHeight, minHeight, boxSizing);\nexport default sizing;","import { padding, margin } from '../spacing';\nimport { borderRadius, borderTransform } from '../borders';\nimport { gap, rowGap, columnGap } from '../cssGrid';\nimport { paletteTransform } from '../palette';\nimport { maxWidth, sizingTransform } from '../sizing';\nconst defaultSxConfig = {\n // borders\n border: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderTop: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderRight: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderBottom: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderLeft: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderColor: {\n themeKey: 'palette'\n },\n borderTopColor: {\n themeKey: 'palette'\n },\n borderRightColor: {\n themeKey: 'palette'\n },\n borderBottomColor: {\n themeKey: 'palette'\n },\n borderLeftColor: {\n themeKey: 'palette'\n },\n outline: {\n themeKey: 'borders',\n transform: borderTransform\n },\n outlineColor: {\n themeKey: 'palette'\n },\n borderRadius: {\n themeKey: 'shape.borderRadius',\n style: borderRadius\n },\n // palette\n color: {\n themeKey: 'palette',\n transform: paletteTransform\n },\n bgcolor: {\n themeKey: 'palette',\n cssProperty: 'backgroundColor',\n transform: paletteTransform\n },\n backgroundColor: {\n themeKey: 'palette',\n transform: paletteTransform\n },\n // spacing\n p: {\n style: padding\n },\n pt: {\n style: padding\n },\n pr: {\n style: padding\n },\n pb: {\n style: padding\n },\n pl: {\n style: padding\n },\n px: {\n style: padding\n },\n py: {\n style: padding\n },\n padding: {\n style: padding\n },\n paddingTop: {\n style: padding\n },\n paddingRight: {\n style: padding\n },\n paddingBottom: {\n style: padding\n },\n paddingLeft: {\n style: padding\n },\n paddingX: {\n style: padding\n },\n paddingY: {\n style: padding\n },\n paddingInline: {\n style: padding\n },\n paddingInlineStart: {\n style: padding\n },\n paddingInlineEnd: {\n style: padding\n },\n paddingBlock: {\n style: padding\n },\n paddingBlockStart: {\n style: padding\n },\n paddingBlockEnd: {\n style: padding\n },\n m: {\n style: margin\n },\n mt: {\n style: margin\n },\n mr: {\n style: margin\n },\n mb: {\n style: margin\n },\n ml: {\n style: margin\n },\n mx: {\n style: margin\n },\n my: {\n style: margin\n },\n margin: {\n style: margin\n },\n marginTop: {\n style: margin\n },\n marginRight: {\n style: margin\n },\n marginBottom: {\n style: margin\n },\n marginLeft: {\n style: margin\n },\n marginX: {\n style: margin\n },\n marginY: {\n style: margin\n },\n marginInline: {\n style: margin\n },\n marginInlineStart: {\n style: margin\n },\n marginInlineEnd: {\n style: margin\n },\n marginBlock: {\n style: margin\n },\n marginBlockStart: {\n style: margin\n },\n marginBlockEnd: {\n style: margin\n },\n // display\n displayPrint: {\n cssProperty: false,\n transform: value => ({\n '@media print': {\n display: value\n }\n })\n },\n display: {},\n overflow: {},\n textOverflow: {},\n visibility: {},\n whiteSpace: {},\n // flexbox\n flexBasis: {},\n flexDirection: {},\n flexWrap: {},\n justifyContent: {},\n alignItems: {},\n alignContent: {},\n order: {},\n flex: {},\n flexGrow: {},\n flexShrink: {},\n alignSelf: {},\n justifyItems: {},\n justifySelf: {},\n // grid\n gap: {\n style: gap\n },\n rowGap: {\n style: rowGap\n },\n columnGap: {\n style: columnGap\n },\n gridColumn: {},\n gridRow: {},\n gridAutoFlow: {},\n gridAutoColumns: {},\n gridAutoRows: {},\n gridTemplateColumns: {},\n gridTemplateRows: {},\n gridTemplateAreas: {},\n gridArea: {},\n // positions\n position: {},\n zIndex: {\n themeKey: 'zIndex'\n },\n top: {},\n right: {},\n bottom: {},\n left: {},\n // shadows\n boxShadow: {\n themeKey: 'shadows'\n },\n // sizing\n width: {\n transform: sizingTransform\n },\n maxWidth: {\n style: maxWidth\n },\n minWidth: {\n transform: sizingTransform\n },\n height: {\n transform: sizingTransform\n },\n maxHeight: {\n transform: sizingTransform\n },\n minHeight: {\n transform: sizingTransform\n },\n boxSizing: {},\n // typography\n fontFamily: {\n themeKey: 'typography'\n },\n fontSize: {\n themeKey: 'typography'\n },\n fontStyle: {\n themeKey: 'typography'\n },\n fontWeight: {\n themeKey: 'typography'\n },\n letterSpacing: {},\n textTransform: {},\n lineHeight: {},\n textAlign: {},\n typography: {\n cssProperty: false,\n themeKey: 'typography'\n }\n};\nexport default defaultSxConfig;","import capitalize from '@mui/utils/capitalize';\nimport merge from '../merge';\nimport { getPath, getStyleValue as getValue } from '../style';\nimport { handleBreakpoints, createEmptyBreakpointObject, removeUnusedBreakpoints } from '../breakpoints';\nimport defaultSxConfig from './defaultSxConfig';\nfunction objectsHaveSameKeys(...objects) {\n const allKeys = objects.reduce((keys, object) => keys.concat(Object.keys(object)), []);\n const union = new Set(allKeys);\n return objects.every(object => union.size === Object.keys(object).length);\n}\nfunction callIfFn(maybeFn, arg) {\n return typeof maybeFn === 'function' ? maybeFn(arg) : maybeFn;\n}\n\n// eslint-disable-next-line @typescript-eslint/naming-convention\nexport function unstable_createStyleFunctionSx() {\n function getThemeValue(prop, val, theme, config) {\n const props = {\n [prop]: val,\n theme\n };\n const options = config[prop];\n if (!options) {\n return {\n [prop]: val\n };\n }\n const {\n cssProperty = prop,\n themeKey,\n transform,\n style\n } = options;\n if (val == null) {\n return null;\n }\n\n // TODO v6: remove, see https://github.com/mui/material-ui/pull/38123\n if (themeKey === 'typography' && val === 'inherit') {\n return {\n [prop]: val\n };\n }\n const themeMapping = getPath(theme, themeKey) || {};\n if (style) {\n return style(props);\n }\n const styleFromPropValue = propValueFinal => {\n let value = getValue(themeMapping, transform, propValueFinal);\n if (propValueFinal === value && typeof propValueFinal === 'string') {\n // Haven't found value\n value = getValue(themeMapping, transform, `${prop}${propValueFinal === 'default' ? '' : capitalize(propValueFinal)}`, propValueFinal);\n }\n if (cssProperty === false) {\n return value;\n }\n return {\n [cssProperty]: value\n };\n };\n return handleBreakpoints(props, val, styleFromPropValue);\n }\n function styleFunctionSx(props) {\n var _theme$unstable_sxCon;\n const {\n sx,\n theme = {}\n } = props || {};\n if (!sx) {\n return null; // Emotion & styled-components will neglect null\n }\n const config = (_theme$unstable_sxCon = theme.unstable_sxConfig) != null ? _theme$unstable_sxCon : defaultSxConfig;\n\n /*\n * Receive `sxInput` as object or callback\n * and then recursively check keys & values to create media query object styles.\n * (the result will be used in `styled`)\n */\n function traverse(sxInput) {\n let sxObject = sxInput;\n if (typeof sxInput === 'function') {\n sxObject = sxInput(theme);\n } else if (typeof sxInput !== 'object') {\n // value\n return sxInput;\n }\n if (!sxObject) {\n return null;\n }\n const emptyBreakpoints = createEmptyBreakpointObject(theme.breakpoints);\n const breakpointsKeys = Object.keys(emptyBreakpoints);\n let css = emptyBreakpoints;\n Object.keys(sxObject).forEach(styleKey => {\n const value = callIfFn(sxObject[styleKey], theme);\n if (value !== null && value !== undefined) {\n if (typeof value === 'object') {\n if (config[styleKey]) {\n css = merge(css, getThemeValue(styleKey, value, theme, config));\n } else {\n const breakpointsValues = handleBreakpoints({\n theme\n }, value, x => ({\n [styleKey]: x\n }));\n if (objectsHaveSameKeys(breakpointsValues, value)) {\n css[styleKey] = styleFunctionSx({\n sx: value,\n theme\n });\n } else {\n css = merge(css, breakpointsValues);\n }\n }\n } else {\n css = merge(css, getThemeValue(styleKey, value, theme, config));\n }\n }\n });\n return removeUnusedBreakpoints(breakpointsKeys, css);\n }\n return Array.isArray(sx) ? sx.map(traverse) : traverse(sx);\n }\n return styleFunctionSx;\n}\nconst styleFunctionSx = unstable_createStyleFunctionSx();\nstyleFunctionSx.filterProps = ['sx'];\nexport default styleFunctionSx;","/**\n * A universal utility to style components with multiple color modes. Always use it from the theme object.\n * It works with:\n * - [Basic theme](https://mui.com/material-ui/customization/dark-mode/)\n * - [CSS theme variables](https://mui.com/material-ui/experimental-api/css-theme-variables/overview/)\n * - Zero-runtime engine\n *\n * Tips: Use an array over object spread and place `theme.applyStyles()` last.\n *\n * ✅ [{ background: '#e5e5e5' }, theme.applyStyles('dark', { background: '#1c1c1c' })]\n *\n * 🚫 { background: '#e5e5e5', ...theme.applyStyles('dark', { background: '#1c1c1c' })}\n *\n * @example\n * 1. using with `styled`:\n * ```jsx\n * const Component = styled('div')(({ theme }) => [\n * { background: '#e5e5e5' },\n * theme.applyStyles('dark', {\n * background: '#1c1c1c',\n * color: '#fff',\n * }),\n * ]);\n * ```\n *\n * @example\n * 2. using with `sx` prop:\n * ```jsx\n * [\n * { background: '#e5e5e5' },\n * theme.applyStyles('dark', {\n * background: '#1c1c1c',\n * color: '#fff',\n * }),\n * ]}\n * />\n * ```\n *\n * @example\n * 3. theming a component:\n * ```jsx\n * extendTheme({\n * components: {\n * MuiButton: {\n * styleOverrides: {\n * root: ({ theme }) => [\n * { background: '#e5e5e5' },\n * theme.applyStyles('dark', {\n * background: '#1c1c1c',\n * color: '#fff',\n * }),\n * ],\n * },\n * }\n * }\n * })\n *```\n */\nexport default function applyStyles(key, styles) {\n // @ts-expect-error this is 'any' type\n const theme = this;\n if (theme.vars && typeof theme.getColorSchemeSelector === 'function') {\n // If CssVarsProvider is used as a provider,\n // returns '* :where([data-mui-color-scheme=\"light|dark\"]) &'\n const selector = theme.getColorSchemeSelector(key).replace(/(\\[[^\\]]+\\])/, '*:where($1)');\n return {\n [selector]: styles\n };\n }\n if (theme.palette.mode === key) {\n return styles;\n }\n return {};\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"breakpoints\", \"palette\", \"spacing\", \"shape\"];\nimport deepmerge from '@mui/utils/deepmerge';\nimport createBreakpoints from './createBreakpoints';\nimport shape from './shape';\nimport createSpacing from './createSpacing';\nimport styleFunctionSx from '../styleFunctionSx/styleFunctionSx';\nimport defaultSxConfig from '../styleFunctionSx/defaultSxConfig';\nimport applyStyles from './applyStyles';\nfunction createTheme(options = {}, ...args) {\n const {\n breakpoints: breakpointsInput = {},\n palette: paletteInput = {},\n spacing: spacingInput,\n shape: shapeInput = {}\n } = options,\n other = _objectWithoutPropertiesLoose(options, _excluded);\n const breakpoints = createBreakpoints(breakpointsInput);\n const spacing = createSpacing(spacingInput);\n let muiTheme = deepmerge({\n breakpoints,\n direction: 'ltr',\n components: {},\n // Inject component definitions.\n palette: _extends({\n mode: 'light'\n }, paletteInput),\n spacing,\n shape: _extends({}, shape, shapeInput)\n }, other);\n muiTheme.applyStyles = applyStyles;\n muiTheme = args.reduce((acc, argument) => deepmerge(acc, argument), muiTheme);\n muiTheme.unstable_sxConfig = _extends({}, defaultSxConfig, other == null ? void 0 : other.unstable_sxConfig);\n muiTheme.unstable_sx = function sx(props) {\n return styleFunctionSx({\n sx: props,\n theme: this\n });\n };\n return muiTheme;\n}\nexport default createTheme;","'use client';\n\nimport * as React from 'react';\nimport { ThemeContext } from '@mui/styled-engine';\nfunction isObjectEmpty(obj) {\n return Object.keys(obj).length === 0;\n}\nfunction useTheme(defaultTheme = null) {\n const contextTheme = React.useContext(ThemeContext);\n return !contextTheme || isObjectEmpty(contextTheme) ? defaultTheme : contextTheme;\n}\nexport default useTheme;","'use client';\n\nimport createTheme from './createTheme';\nimport useThemeWithoutDefault from './useThemeWithoutDefault';\nexport const systemDefaultTheme = createTheme();\nfunction useTheme(defaultTheme = systemDefaultTheme) {\n return useThemeWithoutDefault(defaultTheme);\n}\nexport default useTheme;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"ownerState\"],\n _excluded2 = [\"variants\"],\n _excluded3 = [\"name\", \"slot\", \"skipVariantsResolver\", \"skipSx\", \"overridesResolver\"];\n/* eslint-disable no-underscore-dangle */\nimport styledEngineStyled, { internal_processStyles as processStyles } from '@mui/styled-engine';\nimport { isPlainObject } from '@mui/utils/deepmerge';\nimport capitalize from '@mui/utils/capitalize';\nimport getDisplayName from '@mui/utils/getDisplayName';\nimport createTheme from './createTheme';\nimport styleFunctionSx from './styleFunctionSx';\nfunction isEmpty(obj) {\n return Object.keys(obj).length === 0;\n}\n\n// https://github.com/emotion-js/emotion/blob/26ded6109fcd8ca9875cc2ce4564fee678a3f3c5/packages/styled/src/utils.js#L40\nfunction isStringTag(tag) {\n return typeof tag === 'string' &&\n // 96 is one less than the char code\n // for \"a\" so this is checking that\n // it's a lowercase character\n tag.charCodeAt(0) > 96;\n}\n\n// Update /system/styled/#api in case if this changes\nexport function shouldForwardProp(prop) {\n return prop !== 'ownerState' && prop !== 'theme' && prop !== 'sx' && prop !== 'as';\n}\nexport const systemDefaultTheme = createTheme();\nconst lowercaseFirstLetter = string => {\n if (!string) {\n return string;\n }\n return string.charAt(0).toLowerCase() + string.slice(1);\n};\nfunction resolveTheme({\n defaultTheme,\n theme,\n themeId\n}) {\n return isEmpty(theme) ? defaultTheme : theme[themeId] || theme;\n}\nfunction defaultOverridesResolver(slot) {\n if (!slot) {\n return null;\n }\n return (props, styles) => styles[slot];\n}\nfunction processStyleArg(callableStyle, _ref) {\n let {\n ownerState\n } = _ref,\n props = _objectWithoutPropertiesLoose(_ref, _excluded);\n const resolvedStylesArg = typeof callableStyle === 'function' ? callableStyle(_extends({\n ownerState\n }, props)) : callableStyle;\n if (Array.isArray(resolvedStylesArg)) {\n return resolvedStylesArg.flatMap(resolvedStyle => processStyleArg(resolvedStyle, _extends({\n ownerState\n }, props)));\n }\n if (!!resolvedStylesArg && typeof resolvedStylesArg === 'object' && Array.isArray(resolvedStylesArg.variants)) {\n const {\n variants = []\n } = resolvedStylesArg,\n otherStyles = _objectWithoutPropertiesLoose(resolvedStylesArg, _excluded2);\n let result = otherStyles;\n variants.forEach(variant => {\n let isMatch = true;\n if (typeof variant.props === 'function') {\n isMatch = variant.props(_extends({\n ownerState\n }, props, ownerState));\n } else {\n Object.keys(variant.props).forEach(key => {\n if ((ownerState == null ? void 0 : ownerState[key]) !== variant.props[key] && props[key] !== variant.props[key]) {\n isMatch = false;\n }\n });\n }\n if (isMatch) {\n if (!Array.isArray(result)) {\n result = [result];\n }\n result.push(typeof variant.style === 'function' ? variant.style(_extends({\n ownerState\n }, props, ownerState)) : variant.style);\n }\n });\n return result;\n }\n return resolvedStylesArg;\n}\nexport default function createStyled(input = {}) {\n const {\n themeId,\n defaultTheme = systemDefaultTheme,\n rootShouldForwardProp = shouldForwardProp,\n slotShouldForwardProp = shouldForwardProp\n } = input;\n const systemSx = props => {\n return styleFunctionSx(_extends({}, props, {\n theme: resolveTheme(_extends({}, props, {\n defaultTheme,\n themeId\n }))\n }));\n };\n systemSx.__mui_systemSx = true;\n return (tag, inputOptions = {}) => {\n // Filter out the `sx` style function from the previous styled component to prevent unnecessary styles generated by the composite components.\n processStyles(tag, styles => styles.filter(style => !(style != null && style.__mui_systemSx)));\n const {\n name: componentName,\n slot: componentSlot,\n skipVariantsResolver: inputSkipVariantsResolver,\n skipSx: inputSkipSx,\n // TODO v6: remove `lowercaseFirstLetter()` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n overridesResolver = defaultOverridesResolver(lowercaseFirstLetter(componentSlot))\n } = inputOptions,\n options = _objectWithoutPropertiesLoose(inputOptions, _excluded3);\n\n // if skipVariantsResolver option is defined, take the value, otherwise, true for root and false for other slots.\n const skipVariantsResolver = inputSkipVariantsResolver !== undefined ? inputSkipVariantsResolver :\n // TODO v6: remove `Root` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n componentSlot && componentSlot !== 'Root' && componentSlot !== 'root' || false;\n const skipSx = inputSkipSx || false;\n let label;\n if (process.env.NODE_ENV !== 'production') {\n if (componentName) {\n // TODO v6: remove `lowercaseFirstLetter()` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n label = `${componentName}-${lowercaseFirstLetter(componentSlot || 'Root')}`;\n }\n }\n let shouldForwardPropOption = shouldForwardProp;\n\n // TODO v6: remove `Root` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n if (componentSlot === 'Root' || componentSlot === 'root') {\n shouldForwardPropOption = rootShouldForwardProp;\n } else if (componentSlot) {\n // any other slot specified\n shouldForwardPropOption = slotShouldForwardProp;\n } else if (isStringTag(tag)) {\n // for string (html) tag, preserve the behavior in emotion & styled-components.\n shouldForwardPropOption = undefined;\n }\n const defaultStyledResolver = styledEngineStyled(tag, _extends({\n shouldForwardProp: shouldForwardPropOption,\n label\n }, options));\n const transformStyleArg = stylesArg => {\n // On the server Emotion doesn't use React.forwardRef for creating components, so the created\n // component stays as a function. This condition makes sure that we do not interpolate functions\n // which are basically components used as a selectors.\n if (typeof stylesArg === 'function' && stylesArg.__emotion_real !== stylesArg || isPlainObject(stylesArg)) {\n return props => processStyleArg(stylesArg, _extends({}, props, {\n theme: resolveTheme({\n theme: props.theme,\n defaultTheme,\n themeId\n })\n }));\n }\n return stylesArg;\n };\n const muiStyledResolver = (styleArg, ...expressions) => {\n let transformedStyleArg = transformStyleArg(styleArg);\n const expressionsWithDefaultTheme = expressions ? expressions.map(transformStyleArg) : [];\n if (componentName && overridesResolver) {\n expressionsWithDefaultTheme.push(props => {\n const theme = resolveTheme(_extends({}, props, {\n defaultTheme,\n themeId\n }));\n if (!theme.components || !theme.components[componentName] || !theme.components[componentName].styleOverrides) {\n return null;\n }\n const styleOverrides = theme.components[componentName].styleOverrides;\n const resolvedStyleOverrides = {};\n // TODO: v7 remove iteration and use `resolveStyleArg(styleOverrides[slot])` directly\n Object.entries(styleOverrides).forEach(([slotKey, slotStyle]) => {\n resolvedStyleOverrides[slotKey] = processStyleArg(slotStyle, _extends({}, props, {\n theme\n }));\n });\n return overridesResolver(props, resolvedStyleOverrides);\n });\n }\n if (componentName && !skipVariantsResolver) {\n expressionsWithDefaultTheme.push(props => {\n var _theme$components;\n const theme = resolveTheme(_extends({}, props, {\n defaultTheme,\n themeId\n }));\n const themeVariants = theme == null || (_theme$components = theme.components) == null || (_theme$components = _theme$components[componentName]) == null ? void 0 : _theme$components.variants;\n return processStyleArg({\n variants: themeVariants\n }, _extends({}, props, {\n theme\n }));\n });\n }\n if (!skipSx) {\n expressionsWithDefaultTheme.push(systemSx);\n }\n const numOfCustomFnsApplied = expressionsWithDefaultTheme.length - expressions.length;\n if (Array.isArray(styleArg) && numOfCustomFnsApplied > 0) {\n const placeholders = new Array(numOfCustomFnsApplied).fill('');\n // If the type is array, than we need to add placeholders in the template for the overrides, variants and the sx styles.\n transformedStyleArg = [...styleArg, ...placeholders];\n transformedStyleArg.raw = [...styleArg.raw, ...placeholders];\n }\n const Component = defaultStyledResolver(transformedStyleArg, ...expressionsWithDefaultTheme);\n if (process.env.NODE_ENV !== 'production') {\n let displayName;\n if (componentName) {\n displayName = `${componentName}${capitalize(componentSlot || '')}`;\n }\n if (displayName === undefined) {\n displayName = `Styled(${getDisplayName(tag)})`;\n }\n Component.displayName = displayName;\n }\n if (tag.muiName) {\n Component.muiName = tag.muiName;\n }\n return Component;\n };\n if (defaultStyledResolver.withConfig) {\n muiStyledResolver.withConfig = defaultStyledResolver.withConfig;\n }\n return muiStyledResolver;\n };\n}","import resolveProps from '@mui/utils/resolveProps';\nexport default function getThemeProps(params) {\n const {\n theme,\n name,\n props\n } = params;\n if (!theme || !theme.components || !theme.components[name] || !theme.components[name].defaultProps) {\n return props;\n }\n return resolveProps(theme.components[name].defaultProps, props);\n}","'use client';\n\nimport getThemeProps from './getThemeProps';\nimport useTheme from '../useTheme';\nexport default function useThemeProps({\n props,\n name,\n defaultTheme,\n themeId\n}) {\n let theme = useTheme(defaultTheme);\n if (themeId) {\n theme = theme[themeId] || theme;\n }\n const mergedProps = getThemeProps({\n theme,\n name,\n props\n });\n return mergedProps;\n}","import _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\n/* eslint-disable @typescript-eslint/naming-convention */\nimport clamp from '@mui/utils/clamp';\n/**\n * Returns a number whose value is limited to the given range.\n * @param {number} value The value to be clamped\n * @param {number} min The lower boundary of the output range\n * @param {number} max The upper boundary of the output range\n * @returns {number} A number in the range [min, max]\n */\nfunction clampWrapper(value, min = 0, max = 1) {\n if (process.env.NODE_ENV !== 'production') {\n if (value < min || value > max) {\n console.error(`MUI: The value provided ${value} is out of range [${min}, ${max}].`);\n }\n }\n return clamp(value, min, max);\n}\n\n/**\n * Converts a color from CSS hex format to CSS rgb format.\n * @param {string} color - Hex color, i.e. #nnn or #nnnnnn\n * @returns {string} A CSS rgb color string\n */\nexport function hexToRgb(color) {\n color = color.slice(1);\n const re = new RegExp(`.{1,${color.length >= 6 ? 2 : 1}}`, 'g');\n let colors = color.match(re);\n if (colors && colors[0].length === 1) {\n colors = colors.map(n => n + n);\n }\n return colors ? `rgb${colors.length === 4 ? 'a' : ''}(${colors.map((n, index) => {\n return index < 3 ? parseInt(n, 16) : Math.round(parseInt(n, 16) / 255 * 1000) / 1000;\n }).join(', ')})` : '';\n}\nfunction intToHex(int) {\n const hex = int.toString(16);\n return hex.length === 1 ? `0${hex}` : hex;\n}\n\n/**\n * Returns an object with the type and values of a color.\n *\n * Note: Does not support rgb % values.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @returns {object} - A MUI color object: {type: string, values: number[]}\n */\nexport function decomposeColor(color) {\n // Idempotent\n if (color.type) {\n return color;\n }\n if (color.charAt(0) === '#') {\n return decomposeColor(hexToRgb(color));\n }\n const marker = color.indexOf('(');\n const type = color.substring(0, marker);\n if (['rgb', 'rgba', 'hsl', 'hsla', 'color'].indexOf(type) === -1) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: Unsupported \\`${color}\\` color.\nThe following formats are supported: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color().` : _formatMuiErrorMessage(9, color));\n }\n let values = color.substring(marker + 1, color.length - 1);\n let colorSpace;\n if (type === 'color') {\n values = values.split(' ');\n colorSpace = values.shift();\n if (values.length === 4 && values[3].charAt(0) === '/') {\n values[3] = values[3].slice(1);\n }\n if (['srgb', 'display-p3', 'a98-rgb', 'prophoto-rgb', 'rec-2020'].indexOf(colorSpace) === -1) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: unsupported \\`${colorSpace}\\` color space.\nThe following color spaces are supported: srgb, display-p3, a98-rgb, prophoto-rgb, rec-2020.` : _formatMuiErrorMessage(10, colorSpace));\n }\n } else {\n values = values.split(',');\n }\n values = values.map(value => parseFloat(value));\n return {\n type,\n values,\n colorSpace\n };\n}\n\n/**\n * Returns a channel created from the input color.\n *\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @returns {string} - The channel for the color, that can be used in rgba or hsla colors\n */\nexport const colorChannel = color => {\n const decomposedColor = decomposeColor(color);\n return decomposedColor.values.slice(0, 3).map((val, idx) => decomposedColor.type.indexOf('hsl') !== -1 && idx !== 0 ? `${val}%` : val).join(' ');\n};\nexport const private_safeColorChannel = (color, warning) => {\n try {\n return colorChannel(color);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n};\n\n/**\n * Converts a color object with type and values to a string.\n * @param {object} color - Decomposed color\n * @param {string} color.type - One of: 'rgb', 'rgba', 'hsl', 'hsla', 'color'\n * @param {array} color.values - [n,n,n] or [n,n,n,n]\n * @returns {string} A CSS color string\n */\nexport function recomposeColor(color) {\n const {\n type,\n colorSpace\n } = color;\n let {\n values\n } = color;\n if (type.indexOf('rgb') !== -1) {\n // Only convert the first 3 values to int (i.e. not alpha)\n values = values.map((n, i) => i < 3 ? parseInt(n, 10) : n);\n } else if (type.indexOf('hsl') !== -1) {\n values[1] = `${values[1]}%`;\n values[2] = `${values[2]}%`;\n }\n if (type.indexOf('color') !== -1) {\n values = `${colorSpace} ${values.join(' ')}`;\n } else {\n values = `${values.join(', ')}`;\n }\n return `${type}(${values})`;\n}\n\n/**\n * Converts a color from CSS rgb format to CSS hex format.\n * @param {string} color - RGB color, i.e. rgb(n, n, n)\n * @returns {string} A CSS rgb color string, i.e. #nnnnnn\n */\nexport function rgbToHex(color) {\n // Idempotent\n if (color.indexOf('#') === 0) {\n return color;\n }\n const {\n values\n } = decomposeColor(color);\n return `#${values.map((n, i) => intToHex(i === 3 ? Math.round(255 * n) : n)).join('')}`;\n}\n\n/**\n * Converts a color from hsl format to rgb format.\n * @param {string} color - HSL color values\n * @returns {string} rgb color values\n */\nexport function hslToRgb(color) {\n color = decomposeColor(color);\n const {\n values\n } = color;\n const h = values[0];\n const s = values[1] / 100;\n const l = values[2] / 100;\n const a = s * Math.min(l, 1 - l);\n const f = (n, k = (n + h / 30) % 12) => l - a * Math.max(Math.min(k - 3, 9 - k, 1), -1);\n let type = 'rgb';\n const rgb = [Math.round(f(0) * 255), Math.round(f(8) * 255), Math.round(f(4) * 255)];\n if (color.type === 'hsla') {\n type += 'a';\n rgb.push(values[3]);\n }\n return recomposeColor({\n type,\n values: rgb\n });\n}\n/**\n * The relative brightness of any point in a color space,\n * normalized to 0 for darkest black and 1 for lightest white.\n *\n * Formula: https://www.w3.org/TR/WCAG20-TECHS/G17.html#G17-tests\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @returns {number} The relative brightness of the color in the range 0 - 1\n */\nexport function getLuminance(color) {\n color = decomposeColor(color);\n let rgb = color.type === 'hsl' || color.type === 'hsla' ? decomposeColor(hslToRgb(color)).values : color.values;\n rgb = rgb.map(val => {\n if (color.type !== 'color') {\n val /= 255; // normalized\n }\n return val <= 0.03928 ? val / 12.92 : ((val + 0.055) / 1.055) ** 2.4;\n });\n\n // Truncate at 3 digits\n return Number((0.2126 * rgb[0] + 0.7152 * rgb[1] + 0.0722 * rgb[2]).toFixed(3));\n}\n\n/**\n * Calculates the contrast ratio between two colors.\n *\n * Formula: https://www.w3.org/TR/WCAG20-TECHS/G17.html#G17-tests\n * @param {string} foreground - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla()\n * @param {string} background - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla()\n * @returns {number} A contrast ratio value in the range 0 - 21.\n */\nexport function getContrastRatio(foreground, background) {\n const lumA = getLuminance(foreground);\n const lumB = getLuminance(background);\n return (Math.max(lumA, lumB) + 0.05) / (Math.min(lumA, lumB) + 0.05);\n}\n\n/**\n * Sets the absolute transparency of a color.\n * Any existing alpha values are overwritten.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} value - value to set the alpha channel to in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function alpha(color, value) {\n color = decomposeColor(color);\n value = clampWrapper(value);\n if (color.type === 'rgb' || color.type === 'hsl') {\n color.type += 'a';\n }\n if (color.type === 'color') {\n color.values[3] = `/${value}`;\n } else {\n color.values[3] = value;\n }\n return recomposeColor(color);\n}\nexport function private_safeAlpha(color, value, warning) {\n try {\n return alpha(color, value);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Darkens a color.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} coefficient - multiplier in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function darken(color, coefficient) {\n color = decomposeColor(color);\n coefficient = clampWrapper(coefficient);\n if (color.type.indexOf('hsl') !== -1) {\n color.values[2] *= 1 - coefficient;\n } else if (color.type.indexOf('rgb') !== -1 || color.type.indexOf('color') !== -1) {\n for (let i = 0; i < 3; i += 1) {\n color.values[i] *= 1 - coefficient;\n }\n }\n return recomposeColor(color);\n}\nexport function private_safeDarken(color, coefficient, warning) {\n try {\n return darken(color, coefficient);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Lightens a color.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} coefficient - multiplier in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function lighten(color, coefficient) {\n color = decomposeColor(color);\n coefficient = clampWrapper(coefficient);\n if (color.type.indexOf('hsl') !== -1) {\n color.values[2] += (100 - color.values[2]) * coefficient;\n } else if (color.type.indexOf('rgb') !== -1) {\n for (let i = 0; i < 3; i += 1) {\n color.values[i] += (255 - color.values[i]) * coefficient;\n }\n } else if (color.type.indexOf('color') !== -1) {\n for (let i = 0; i < 3; i += 1) {\n color.values[i] += (1 - color.values[i]) * coefficient;\n }\n }\n return recomposeColor(color);\n}\nexport function private_safeLighten(color, coefficient, warning) {\n try {\n return lighten(color, coefficient);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Darken or lighten a color, depending on its luminance.\n * Light colors are darkened, dark colors are lightened.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} coefficient=0.15 - multiplier in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function emphasize(color, coefficient = 0.15) {\n return getLuminance(color) > 0.5 ? darken(color, coefficient) : lighten(color, coefficient);\n}\nexport function private_safeEmphasize(color, coefficient, warning) {\n try {\n return emphasize(color, coefficient);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Blend a transparent overlay color with a background color, resulting in a single\n * RGB color.\n * @param {string} background - CSS color\n * @param {string} overlay - CSS color\n * @param {number} opacity - Opacity multiplier in the range 0 - 1\n * @param {number} [gamma=1.0] - Gamma correction factor. For gamma-correct blending, 2.2 is usual.\n */\nexport function blend(background, overlay, opacity, gamma = 1.0) {\n const blendChannel = (b, o) => Math.round((b ** (1 / gamma) * (1 - opacity) + o ** (1 / gamma) * opacity) ** gamma);\n const backgroundColor = decomposeColor(background);\n const overlayColor = decomposeColor(overlay);\n const rgb = [blendChannel(backgroundColor.values[0], overlayColor.values[0]), blendChannel(backgroundColor.values[1], overlayColor.values[1]), blendChannel(backgroundColor.values[2], overlayColor.values[2])];\n return recomposeColor({\n type: 'rgb',\n values: rgb\n });\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nexport default function createMixins(breakpoints, mixins) {\n return _extends({\n toolbar: {\n minHeight: 56,\n [breakpoints.up('xs')]: {\n '@media (orientation: landscape)': {\n minHeight: 48\n }\n },\n [breakpoints.up('sm')]: {\n minHeight: 64\n }\n }\n }, mixins);\n}","const common = {\n black: '#000',\n white: '#fff'\n};\nexport default common;","const grey = {\n 50: '#fafafa',\n 100: '#f5f5f5',\n 200: '#eeeeee',\n 300: '#e0e0e0',\n 400: '#bdbdbd',\n 500: '#9e9e9e',\n 600: '#757575',\n 700: '#616161',\n 800: '#424242',\n 900: '#212121',\n A100: '#f5f5f5',\n A200: '#eeeeee',\n A400: '#bdbdbd',\n A700: '#616161'\n};\nexport default grey;","const purple = {\n 50: '#f3e5f5',\n 100: '#e1bee7',\n 200: '#ce93d8',\n 300: '#ba68c8',\n 400: '#ab47bc',\n 500: '#9c27b0',\n 600: '#8e24aa',\n 700: '#7b1fa2',\n 800: '#6a1b9a',\n 900: '#4a148c',\n A100: '#ea80fc',\n A200: '#e040fb',\n A400: '#d500f9',\n A700: '#aa00ff'\n};\nexport default purple;","const red = {\n 50: '#ffebee',\n 100: '#ffcdd2',\n 200: '#ef9a9a',\n 300: '#e57373',\n 400: '#ef5350',\n 500: '#f44336',\n 600: '#e53935',\n 700: '#d32f2f',\n 800: '#c62828',\n 900: '#b71c1c',\n A100: '#ff8a80',\n A200: '#ff5252',\n A400: '#ff1744',\n A700: '#d50000'\n};\nexport default red;","const orange = {\n 50: '#fff3e0',\n 100: '#ffe0b2',\n 200: '#ffcc80',\n 300: '#ffb74d',\n 400: '#ffa726',\n 500: '#ff9800',\n 600: '#fb8c00',\n 700: '#f57c00',\n 800: '#ef6c00',\n 900: '#e65100',\n A100: '#ffd180',\n A200: '#ffab40',\n A400: '#ff9100',\n A700: '#ff6d00'\n};\nexport default orange;","const blue = {\n 50: '#e3f2fd',\n 100: '#bbdefb',\n 200: '#90caf9',\n 300: '#64b5f6',\n 400: '#42a5f5',\n 500: '#2196f3',\n 600: '#1e88e5',\n 700: '#1976d2',\n 800: '#1565c0',\n 900: '#0d47a1',\n A100: '#82b1ff',\n A200: '#448aff',\n A400: '#2979ff',\n A700: '#2962ff'\n};\nexport default blue;","const lightBlue = {\n 50: '#e1f5fe',\n 100: '#b3e5fc',\n 200: '#81d4fa',\n 300: '#4fc3f7',\n 400: '#29b6f6',\n 500: '#03a9f4',\n 600: '#039be5',\n 700: '#0288d1',\n 800: '#0277bd',\n 900: '#01579b',\n A100: '#80d8ff',\n A200: '#40c4ff',\n A400: '#00b0ff',\n A700: '#0091ea'\n};\nexport default lightBlue;","const green = {\n 50: '#e8f5e9',\n 100: '#c8e6c9',\n 200: '#a5d6a7',\n 300: '#81c784',\n 400: '#66bb6a',\n 500: '#4caf50',\n 600: '#43a047',\n 700: '#388e3c',\n 800: '#2e7d32',\n 900: '#1b5e20',\n A100: '#b9f6ca',\n A200: '#69f0ae',\n A400: '#00e676',\n A700: '#00c853'\n};\nexport default green;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\nconst _excluded = [\"mode\", \"contrastThreshold\", \"tonalOffset\"];\nimport { deepmerge } from '@mui/utils';\nimport { darken, getContrastRatio, lighten } from '@mui/system';\nimport common from '../colors/common';\nimport grey from '../colors/grey';\nimport purple from '../colors/purple';\nimport red from '../colors/red';\nimport orange from '../colors/orange';\nimport blue from '../colors/blue';\nimport lightBlue from '../colors/lightBlue';\nimport green from '../colors/green';\nexport const light = {\n // The colors used to style the text.\n text: {\n // The most important text.\n primary: 'rgba(0, 0, 0, 0.87)',\n // Secondary text.\n secondary: 'rgba(0, 0, 0, 0.6)',\n // Disabled text have even lower visual prominence.\n disabled: 'rgba(0, 0, 0, 0.38)'\n },\n // The color used to divide different elements.\n divider: 'rgba(0, 0, 0, 0.12)',\n // The background colors used to style the surfaces.\n // Consistency between these values is important.\n background: {\n paper: common.white,\n default: common.white\n },\n // The colors used to style the action elements.\n action: {\n // The color of an active action like an icon button.\n active: 'rgba(0, 0, 0, 0.54)',\n // The color of an hovered action.\n hover: 'rgba(0, 0, 0, 0.04)',\n hoverOpacity: 0.04,\n // The color of a selected action.\n selected: 'rgba(0, 0, 0, 0.08)',\n selectedOpacity: 0.08,\n // The color of a disabled action.\n disabled: 'rgba(0, 0, 0, 0.26)',\n // The background color of a disabled action.\n disabledBackground: 'rgba(0, 0, 0, 0.12)',\n disabledOpacity: 0.38,\n focus: 'rgba(0, 0, 0, 0.12)',\n focusOpacity: 0.12,\n activatedOpacity: 0.12\n }\n};\nexport const dark = {\n text: {\n primary: common.white,\n secondary: 'rgba(255, 255, 255, 0.7)',\n disabled: 'rgba(255, 255, 255, 0.5)',\n icon: 'rgba(255, 255, 255, 0.5)'\n },\n divider: 'rgba(255, 255, 255, 0.12)',\n background: {\n paper: '#121212',\n default: '#121212'\n },\n action: {\n active: common.white,\n hover: 'rgba(255, 255, 255, 0.08)',\n hoverOpacity: 0.08,\n selected: 'rgba(255, 255, 255, 0.16)',\n selectedOpacity: 0.16,\n disabled: 'rgba(255, 255, 255, 0.3)',\n disabledBackground: 'rgba(255, 255, 255, 0.12)',\n disabledOpacity: 0.38,\n focus: 'rgba(255, 255, 255, 0.12)',\n focusOpacity: 0.12,\n activatedOpacity: 0.24\n }\n};\nfunction addLightOrDark(intent, direction, shade, tonalOffset) {\n const tonalOffsetLight = tonalOffset.light || tonalOffset;\n const tonalOffsetDark = tonalOffset.dark || tonalOffset * 1.5;\n if (!intent[direction]) {\n if (intent.hasOwnProperty(shade)) {\n intent[direction] = intent[shade];\n } else if (direction === 'light') {\n intent.light = lighten(intent.main, tonalOffsetLight);\n } else if (direction === 'dark') {\n intent.dark = darken(intent.main, tonalOffsetDark);\n }\n }\n}\nfunction getDefaultPrimary(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: blue[200],\n light: blue[50],\n dark: blue[400]\n };\n }\n return {\n main: blue[700],\n light: blue[400],\n dark: blue[800]\n };\n}\nfunction getDefaultSecondary(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: purple[200],\n light: purple[50],\n dark: purple[400]\n };\n }\n return {\n main: purple[500],\n light: purple[300],\n dark: purple[700]\n };\n}\nfunction getDefaultError(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: red[500],\n light: red[300],\n dark: red[700]\n };\n }\n return {\n main: red[700],\n light: red[400],\n dark: red[800]\n };\n}\nfunction getDefaultInfo(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: lightBlue[400],\n light: lightBlue[300],\n dark: lightBlue[700]\n };\n }\n return {\n main: lightBlue[700],\n light: lightBlue[500],\n dark: lightBlue[900]\n };\n}\nfunction getDefaultSuccess(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: green[400],\n light: green[300],\n dark: green[700]\n };\n }\n return {\n main: green[800],\n light: green[500],\n dark: green[900]\n };\n}\nfunction getDefaultWarning(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: orange[400],\n light: orange[300],\n dark: orange[700]\n };\n }\n return {\n main: '#ed6c02',\n // closest to orange[800] that pass 3:1.\n light: orange[500],\n dark: orange[900]\n };\n}\nexport default function createPalette(palette) {\n const {\n mode = 'light',\n contrastThreshold = 3,\n tonalOffset = 0.2\n } = palette,\n other = _objectWithoutPropertiesLoose(palette, _excluded);\n const primary = palette.primary || getDefaultPrimary(mode);\n const secondary = palette.secondary || getDefaultSecondary(mode);\n const error = palette.error || getDefaultError(mode);\n const info = palette.info || getDefaultInfo(mode);\n const success = palette.success || getDefaultSuccess(mode);\n const warning = palette.warning || getDefaultWarning(mode);\n\n // Use the same logic as\n // Bootstrap: https://github.com/twbs/bootstrap/blob/1d6e3710dd447de1a200f29e8fa521f8a0908f70/scss/_functions.scss#L59\n // and material-components-web https://github.com/material-components/material-components-web/blob/ac46b8863c4dab9fc22c4c662dc6bd1b65dd652f/packages/mdc-theme/_functions.scss#L54\n function getContrastText(background) {\n const contrastText = getContrastRatio(background, dark.text.primary) >= contrastThreshold ? dark.text.primary : light.text.primary;\n if (process.env.NODE_ENV !== 'production') {\n const contrast = getContrastRatio(background, contrastText);\n if (contrast < 3) {\n console.error([`MUI: The contrast ratio of ${contrast}:1 for ${contrastText} on ${background}`, 'falls below the WCAG recommended absolute minimum contrast ratio of 3:1.', 'https://www.w3.org/TR/2008/REC-WCAG20-20081211/#visual-audio-contrast-contrast'].join('\\n'));\n }\n }\n return contrastText;\n }\n const augmentColor = ({\n color,\n name,\n mainShade = 500,\n lightShade = 300,\n darkShade = 700\n }) => {\n color = _extends({}, color);\n if (!color.main && color[mainShade]) {\n color.main = color[mainShade];\n }\n if (!color.hasOwnProperty('main')) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: The color${name ? ` (${name})` : ''} provided to augmentColor(color) is invalid.\nThe color object needs to have a \\`main\\` property or a \\`${mainShade}\\` property.` : _formatMuiErrorMessage(11, name ? ` (${name})` : '', mainShade));\n }\n if (typeof color.main !== 'string') {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: The color${name ? ` (${name})` : ''} provided to augmentColor(color) is invalid.\n\\`color.main\\` should be a string, but \\`${JSON.stringify(color.main)}\\` was provided instead.\n\nDid you intend to use one of the following approaches?\n\nimport { green } from \"@mui/material/colors\";\n\nconst theme1 = createTheme({ palette: {\n primary: green,\n} });\n\nconst theme2 = createTheme({ palette: {\n primary: { main: green[500] },\n} });` : _formatMuiErrorMessage(12, name ? ` (${name})` : '', JSON.stringify(color.main)));\n }\n addLightOrDark(color, 'light', lightShade, tonalOffset);\n addLightOrDark(color, 'dark', darkShade, tonalOffset);\n if (!color.contrastText) {\n color.contrastText = getContrastText(color.main);\n }\n return color;\n };\n const modes = {\n dark,\n light\n };\n if (process.env.NODE_ENV !== 'production') {\n if (!modes[mode]) {\n console.error(`MUI: The palette mode \\`${mode}\\` is not supported.`);\n }\n }\n const paletteOutput = deepmerge(_extends({\n // A collection of common colors.\n common: _extends({}, common),\n // prevent mutable object.\n // The palette mode, can be light or dark.\n mode,\n // The colors used to represent primary interface elements for a user.\n primary: augmentColor({\n color: primary,\n name: 'primary'\n }),\n // The colors used to represent secondary interface elements for a user.\n secondary: augmentColor({\n color: secondary,\n name: 'secondary',\n mainShade: 'A400',\n lightShade: 'A200',\n darkShade: 'A700'\n }),\n // The colors used to represent interface elements that the user should be made aware of.\n error: augmentColor({\n color: error,\n name: 'error'\n }),\n // The colors used to represent potentially dangerous actions or important messages.\n warning: augmentColor({\n color: warning,\n name: 'warning'\n }),\n // The colors used to present information to the user that is neutral and not necessarily important.\n info: augmentColor({\n color: info,\n name: 'info'\n }),\n // The colors used to indicate the successful completion of an action that user triggered.\n success: augmentColor({\n color: success,\n name: 'success'\n }),\n // The grey colors.\n grey,\n // Used by `getContrastText()` to maximize the contrast between\n // the background and the text.\n contrastThreshold,\n // Takes a background color and returns the text color that maximizes the contrast.\n getContrastText,\n // Generate a rich color object.\n augmentColor,\n // Used by the functions below to shift a color's luminance by approximately\n // two indexes within its tonal palette.\n // E.g., shift from Red 500 to Red 300 or Red 700.\n tonalOffset\n }, modes[mode]), other);\n return paletteOutput;\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"fontFamily\", \"fontSize\", \"fontWeightLight\", \"fontWeightRegular\", \"fontWeightMedium\", \"fontWeightBold\", \"htmlFontSize\", \"allVariants\", \"pxToRem\"];\nimport { deepmerge } from '@mui/utils';\nfunction round(value) {\n return Math.round(value * 1e5) / 1e5;\n}\nconst caseAllCaps = {\n textTransform: 'uppercase'\n};\nconst defaultFontFamily = '\"Roboto\", \"Helvetica\", \"Arial\", sans-serif';\n\n/**\n * @see @link{https://m2.material.io/design/typography/the-type-system.html}\n * @see @link{https://m2.material.io/design/typography/understanding-typography.html}\n */\nexport default function createTypography(palette, typography) {\n const _ref = typeof typography === 'function' ? typography(palette) : typography,\n {\n fontFamily = defaultFontFamily,\n // The default font size of the Material Specification.\n fontSize = 14,\n // px\n fontWeightLight = 300,\n fontWeightRegular = 400,\n fontWeightMedium = 500,\n fontWeightBold = 700,\n // Tell MUI what's the font-size on the html element.\n // 16px is the default font-size used by browsers.\n htmlFontSize = 16,\n // Apply the CSS properties to all the variants.\n allVariants,\n pxToRem: pxToRem2\n } = _ref,\n other = _objectWithoutPropertiesLoose(_ref, _excluded);\n if (process.env.NODE_ENV !== 'production') {\n if (typeof fontSize !== 'number') {\n console.error('MUI: `fontSize` is required to be a number.');\n }\n if (typeof htmlFontSize !== 'number') {\n console.error('MUI: `htmlFontSize` is required to be a number.');\n }\n }\n const coef = fontSize / 14;\n const pxToRem = pxToRem2 || (size => `${size / htmlFontSize * coef}rem`);\n const buildVariant = (fontWeight, size, lineHeight, letterSpacing, casing) => _extends({\n fontFamily,\n fontWeight,\n fontSize: pxToRem(size),\n // Unitless following https://meyerweb.com/eric/thoughts/2006/02/08/unitless-line-heights/\n lineHeight\n }, fontFamily === defaultFontFamily ? {\n letterSpacing: `${round(letterSpacing / size)}em`\n } : {}, casing, allVariants);\n const variants = {\n h1: buildVariant(fontWeightLight, 96, 1.167, -1.5),\n h2: buildVariant(fontWeightLight, 60, 1.2, -0.5),\n h3: buildVariant(fontWeightRegular, 48, 1.167, 0),\n h4: buildVariant(fontWeightRegular, 34, 1.235, 0.25),\n h5: buildVariant(fontWeightRegular, 24, 1.334, 0),\n h6: buildVariant(fontWeightMedium, 20, 1.6, 0.15),\n subtitle1: buildVariant(fontWeightRegular, 16, 1.75, 0.15),\n subtitle2: buildVariant(fontWeightMedium, 14, 1.57, 0.1),\n body1: buildVariant(fontWeightRegular, 16, 1.5, 0.15),\n body2: buildVariant(fontWeightRegular, 14, 1.43, 0.15),\n button: buildVariant(fontWeightMedium, 14, 1.75, 0.4, caseAllCaps),\n caption: buildVariant(fontWeightRegular, 12, 1.66, 0.4),\n overline: buildVariant(fontWeightRegular, 12, 2.66, 1, caseAllCaps),\n // TODO v6: Remove handling of 'inherit' variant from the theme as it is already handled in Material UI's Typography component. Also, remember to remove the associated types.\n inherit: {\n fontFamily: 'inherit',\n fontWeight: 'inherit',\n fontSize: 'inherit',\n lineHeight: 'inherit',\n letterSpacing: 'inherit'\n }\n };\n return deepmerge(_extends({\n htmlFontSize,\n pxToRem,\n fontFamily,\n fontSize,\n fontWeightLight,\n fontWeightRegular,\n fontWeightMedium,\n fontWeightBold\n }, variants), other, {\n clone: false // No need to clone deep\n });\n}","const shadowKeyUmbraOpacity = 0.2;\nconst shadowKeyPenumbraOpacity = 0.14;\nconst shadowAmbientShadowOpacity = 0.12;\nfunction createShadow(...px) {\n return [`${px[0]}px ${px[1]}px ${px[2]}px ${px[3]}px rgba(0,0,0,${shadowKeyUmbraOpacity})`, `${px[4]}px ${px[5]}px ${px[6]}px ${px[7]}px rgba(0,0,0,${shadowKeyPenumbraOpacity})`, `${px[8]}px ${px[9]}px ${px[10]}px ${px[11]}px rgba(0,0,0,${shadowAmbientShadowOpacity})`].join(',');\n}\n\n// Values from https://github.com/material-components/material-components-web/blob/be8747f94574669cb5e7add1a7c54fa41a89cec7/packages/mdc-elevation/_variables.scss\nconst shadows = ['none', createShadow(0, 2, 1, -1, 0, 1, 1, 0, 0, 1, 3, 0), createShadow(0, 3, 1, -2, 0, 2, 2, 0, 0, 1, 5, 0), createShadow(0, 3, 3, -2, 0, 3, 4, 0, 0, 1, 8, 0), createShadow(0, 2, 4, -1, 0, 4, 5, 0, 0, 1, 10, 0), createShadow(0, 3, 5, -1, 0, 5, 8, 0, 0, 1, 14, 0), createShadow(0, 3, 5, -1, 0, 6, 10, 0, 0, 1, 18, 0), createShadow(0, 4, 5, -2, 0, 7, 10, 1, 0, 2, 16, 1), createShadow(0, 5, 5, -3, 0, 8, 10, 1, 0, 3, 14, 2), createShadow(0, 5, 6, -3, 0, 9, 12, 1, 0, 3, 16, 2), createShadow(0, 6, 6, -3, 0, 10, 14, 1, 0, 4, 18, 3), createShadow(0, 6, 7, -4, 0, 11, 15, 1, 0, 4, 20, 3), createShadow(0, 7, 8, -4, 0, 12, 17, 2, 0, 5, 22, 4), createShadow(0, 7, 8, -4, 0, 13, 19, 2, 0, 5, 24, 4), createShadow(0, 7, 9, -4, 0, 14, 21, 2, 0, 5, 26, 4), createShadow(0, 8, 9, -5, 0, 15, 22, 2, 0, 6, 28, 5), createShadow(0, 8, 10, -5, 0, 16, 24, 2, 0, 6, 30, 5), createShadow(0, 8, 11, -5, 0, 17, 26, 2, 0, 6, 32, 5), createShadow(0, 9, 11, -5, 0, 18, 28, 2, 0, 7, 34, 6), createShadow(0, 9, 12, -6, 0, 19, 29, 2, 0, 7, 36, 6), createShadow(0, 10, 13, -6, 0, 20, 31, 3, 0, 8, 38, 7), createShadow(0, 10, 13, -6, 0, 21, 33, 3, 0, 8, 40, 7), createShadow(0, 10, 14, -6, 0, 22, 35, 3, 0, 8, 42, 7), createShadow(0, 11, 14, -7, 0, 23, 36, 3, 0, 9, 44, 8), createShadow(0, 11, 15, -7, 0, 24, 38, 3, 0, 9, 46, 8)];\nexport default shadows;","import _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nconst _excluded = [\"duration\", \"easing\", \"delay\"];\n// Follow https://material.google.com/motion/duration-easing.html#duration-easing-natural-easing-curves\n// to learn the context in which each easing should be used.\nexport const easing = {\n // This is the most common easing curve.\n easeInOut: 'cubic-bezier(0.4, 0, 0.2, 1)',\n // Objects enter the screen at full velocity from off-screen and\n // slowly decelerate to a resting point.\n easeOut: 'cubic-bezier(0.0, 0, 0.2, 1)',\n // Objects leave the screen at full velocity. They do not decelerate when off-screen.\n easeIn: 'cubic-bezier(0.4, 0, 1, 1)',\n // The sharp curve is used by objects that may return to the screen at any time.\n sharp: 'cubic-bezier(0.4, 0, 0.6, 1)'\n};\n\n// Follow https://m2.material.io/guidelines/motion/duration-easing.html#duration-easing-common-durations\n// to learn when use what timing\nexport const duration = {\n shortest: 150,\n shorter: 200,\n short: 250,\n // most basic recommended timing\n standard: 300,\n // this is to be used in complex animations\n complex: 375,\n // recommended when something is entering screen\n enteringScreen: 225,\n // recommended when something is leaving screen\n leavingScreen: 195\n};\nfunction formatMs(milliseconds) {\n return `${Math.round(milliseconds)}ms`;\n}\nfunction getAutoHeightDuration(height) {\n if (!height) {\n return 0;\n }\n const constant = height / 36;\n\n // https://www.wolframalpha.com/input/?i=(4+%2B+15+*+(x+%2F+36+)+**+0.25+%2B+(x+%2F+36)+%2F+5)+*+10\n return Math.round((4 + 15 * constant ** 0.25 + constant / 5) * 10);\n}\nexport default function createTransitions(inputTransitions) {\n const mergedEasing = _extends({}, easing, inputTransitions.easing);\n const mergedDuration = _extends({}, duration, inputTransitions.duration);\n const create = (props = ['all'], options = {}) => {\n const {\n duration: durationOption = mergedDuration.standard,\n easing: easingOption = mergedEasing.easeInOut,\n delay = 0\n } = options,\n other = _objectWithoutPropertiesLoose(options, _excluded);\n if (process.env.NODE_ENV !== 'production') {\n const isString = value => typeof value === 'string';\n // IE11 support, replace with Number.isNaN\n // eslint-disable-next-line no-restricted-globals\n const isNumber = value => !isNaN(parseFloat(value));\n if (!isString(props) && !Array.isArray(props)) {\n console.error('MUI: Argument \"props\" must be a string or Array.');\n }\n if (!isNumber(durationOption) && !isString(durationOption)) {\n console.error(`MUI: Argument \"duration\" must be a number or a string but found ${durationOption}.`);\n }\n if (!isString(easingOption)) {\n console.error('MUI: Argument \"easing\" must be a string.');\n }\n if (!isNumber(delay) && !isString(delay)) {\n console.error('MUI: Argument \"delay\" must be a number or a string.');\n }\n if (typeof options !== 'object') {\n console.error(['MUI: Secong argument of transition.create must be an object.', \"Arguments should be either `create('prop1', options)` or `create(['prop1', 'prop2'], options)`\"].join('\\n'));\n }\n if (Object.keys(other).length !== 0) {\n console.error(`MUI: Unrecognized argument(s) [${Object.keys(other).join(',')}].`);\n }\n }\n return (Array.isArray(props) ? props : [props]).map(animatedProp => `${animatedProp} ${typeof durationOption === 'string' ? durationOption : formatMs(durationOption)} ${easingOption} ${typeof delay === 'string' ? delay : formatMs(delay)}`).join(',');\n };\n return _extends({\n getAutoHeightDuration,\n create\n }, inputTransitions, {\n easing: mergedEasing,\n duration: mergedDuration\n });\n}","// We need to centralize the zIndex definitions as they work\n// like global values in the browser.\nconst zIndex = {\n mobileStepper: 1000,\n fab: 1050,\n speedDial: 1050,\n appBar: 1100,\n drawer: 1200,\n modal: 1300,\n snackbar: 1400,\n tooltip: 1500\n};\nexport default zIndex;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\nconst _excluded = [\"breakpoints\", \"mixins\", \"spacing\", \"palette\", \"transitions\", \"typography\", \"shape\"];\nimport { deepmerge } from '@mui/utils';\nimport { createTheme as systemCreateTheme, unstable_defaultSxConfig as defaultSxConfig, unstable_styleFunctionSx as styleFunctionSx } from '@mui/system';\nimport generateUtilityClass from '@mui/utils/generateUtilityClass';\nimport createMixins from './createMixins';\nimport createPalette from './createPalette';\nimport createTypography from './createTypography';\nimport shadows from './shadows';\nimport createTransitions from './createTransitions';\nimport zIndex from './zIndex';\nfunction createTheme(options = {}, ...args) {\n const {\n mixins: mixinsInput = {},\n palette: paletteInput = {},\n transitions: transitionsInput = {},\n typography: typographyInput = {}\n } = options,\n other = _objectWithoutPropertiesLoose(options, _excluded);\n if (options.vars) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: \\`vars\\` is a private field used for CSS variables support.\nPlease use another name.` : _formatMuiErrorMessage(18));\n }\n const palette = createPalette(paletteInput);\n const systemTheme = systemCreateTheme(options);\n let muiTheme = deepmerge(systemTheme, {\n mixins: createMixins(systemTheme.breakpoints, mixinsInput),\n palette,\n // Don't use [...shadows] until you've verified its transpiled code is not invoking the iterator protocol.\n shadows: shadows.slice(),\n typography: createTypography(palette, typographyInput),\n transitions: createTransitions(transitionsInput),\n zIndex: _extends({}, zIndex)\n });\n muiTheme = deepmerge(muiTheme, other);\n muiTheme = args.reduce((acc, argument) => deepmerge(acc, argument), muiTheme);\n if (process.env.NODE_ENV !== 'production') {\n // TODO v6: Refactor to use globalStateClassesMapping from @mui/utils once `readOnly` state class is used in Rating component.\n const stateClasses = ['active', 'checked', 'completed', 'disabled', 'error', 'expanded', 'focused', 'focusVisible', 'required', 'selected'];\n const traverse = (node, component) => {\n let key;\n\n // eslint-disable-next-line guard-for-in, no-restricted-syntax\n for (key in node) {\n const child = node[key];\n if (stateClasses.indexOf(key) !== -1 && Object.keys(child).length > 0) {\n if (process.env.NODE_ENV !== 'production') {\n const stateClass = generateUtilityClass('', key);\n console.error([`MUI: The \\`${component}\\` component increases ` + `the CSS specificity of the \\`${key}\\` internal state.`, 'You can not override it like this: ', JSON.stringify(node, null, 2), '', `Instead, you need to use the '&.${stateClass}' syntax:`, JSON.stringify({\n root: {\n [`&.${stateClass}`]: child\n }\n }, null, 2), '', 'https://mui.com/r/state-classes-guide'].join('\\n'));\n }\n // Remove the style to prevent global conflicts.\n node[key] = {};\n }\n }\n };\n Object.keys(muiTheme.components).forEach(component => {\n const styleOverrides = muiTheme.components[component].styleOverrides;\n if (styleOverrides && component.indexOf('Mui') === 0) {\n traverse(styleOverrides, component);\n }\n });\n }\n muiTheme.unstable_sxConfig = _extends({}, defaultSxConfig, other == null ? void 0 : other.unstable_sxConfig);\n muiTheme.unstable_sx = function sx(props) {\n return styleFunctionSx({\n sx: props,\n theme: this\n });\n };\n return muiTheme;\n}\nlet warnedOnce = false;\nexport function createMuiTheme(...args) {\n if (process.env.NODE_ENV !== 'production') {\n if (!warnedOnce) {\n warnedOnce = true;\n console.error(['MUI: the createMuiTheme function was renamed to createTheme.', '', \"You should use `import { createTheme } from '@mui/material/styles'`\"].join('\\n'));\n }\n }\n return createTheme(...args);\n}\nexport default createTheme;","'use client';\n\nimport createTheme from './createTheme';\nconst defaultTheme = createTheme();\nexport default defaultTheme;","export default '$$material';","'use client';\n\nimport { useThemeProps as systemUseThemeProps } from '@mui/system';\nimport defaultTheme from './defaultTheme';\nimport THEME_ID from './identifier';\nexport default function useThemeProps({\n props,\n name\n}) {\n return systemUseThemeProps({\n props,\n name,\n defaultTheme,\n themeId: THEME_ID\n });\n}","'use client';\n\nimport { createStyled, shouldForwardProp } from '@mui/system';\nimport defaultTheme from './defaultTheme';\nimport THEME_ID from './identifier';\nexport const rootShouldForwardProp = prop => shouldForwardProp(prop) && prop !== 'classes';\nexport const slotShouldForwardProp = shouldForwardProp;\nconst styled = createStyled({\n themeId: THEME_ID,\n defaultTheme,\n rootShouldForwardProp\n});\nexport default styled;","import generateUtilityClasses from '@mui/utils/generateUtilityClasses';\nimport generateUtilityClass from '@mui/utils/generateUtilityClass';\nexport function getSvgIconUtilityClass(slot) {\n return generateUtilityClass('MuiSvgIcon', slot);\n}\nconst svgIconClasses = generateUtilityClasses('MuiSvgIcon', ['root', 'colorPrimary', 'colorSecondary', 'colorAction', 'colorError', 'colorDisabled', 'fontSizeInherit', 'fontSizeSmall', 'fontSizeMedium', 'fontSizeLarge']);\nexport default svgIconClasses;","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"children\", \"className\", \"color\", \"component\", \"fontSize\", \"htmlColor\", \"inheritViewBox\", \"titleAccess\", \"viewBox\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport clsx from 'clsx';\nimport { unstable_composeClasses as composeClasses } from '@mui/base/composeClasses';\nimport capitalize from '../utils/capitalize';\nimport useThemeProps from '../styles/useThemeProps';\nimport styled from '../styles/styled';\nimport { getSvgIconUtilityClass } from './svgIconClasses';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nimport { jsxs as _jsxs } from \"react/jsx-runtime\";\nconst useUtilityClasses = ownerState => {\n const {\n color,\n fontSize,\n classes\n } = ownerState;\n const slots = {\n root: ['root', color !== 'inherit' && `color${capitalize(color)}`, `fontSize${capitalize(fontSize)}`]\n };\n return composeClasses(slots, getSvgIconUtilityClass, classes);\n};\nconst SvgIconRoot = styled('svg', {\n name: 'MuiSvgIcon',\n slot: 'Root',\n overridesResolver: (props, styles) => {\n const {\n ownerState\n } = props;\n return [styles.root, ownerState.color !== 'inherit' && styles[`color${capitalize(ownerState.color)}`], styles[`fontSize${capitalize(ownerState.fontSize)}`]];\n }\n})(({\n theme,\n ownerState\n}) => {\n var _theme$transitions, _theme$transitions$cr, _theme$transitions2, _theme$typography, _theme$typography$pxT, _theme$typography2, _theme$typography2$px, _theme$typography3, _theme$typography3$px, _palette$ownerState$c, _palette, _palette2, _palette3;\n return {\n userSelect: 'none',\n width: '1em',\n height: '1em',\n display: 'inline-block',\n // the will define the property that has `currentColor`\n // e.g. heroicons uses fill=\"none\" and stroke=\"currentColor\"\n fill: ownerState.hasSvgAsChild ? undefined : 'currentColor',\n flexShrink: 0,\n transition: (_theme$transitions = theme.transitions) == null || (_theme$transitions$cr = _theme$transitions.create) == null ? void 0 : _theme$transitions$cr.call(_theme$transitions, 'fill', {\n duration: (_theme$transitions2 = theme.transitions) == null || (_theme$transitions2 = _theme$transitions2.duration) == null ? void 0 : _theme$transitions2.shorter\n }),\n fontSize: {\n inherit: 'inherit',\n small: ((_theme$typography = theme.typography) == null || (_theme$typography$pxT = _theme$typography.pxToRem) == null ? void 0 : _theme$typography$pxT.call(_theme$typography, 20)) || '1.25rem',\n medium: ((_theme$typography2 = theme.typography) == null || (_theme$typography2$px = _theme$typography2.pxToRem) == null ? void 0 : _theme$typography2$px.call(_theme$typography2, 24)) || '1.5rem',\n large: ((_theme$typography3 = theme.typography) == null || (_theme$typography3$px = _theme$typography3.pxToRem) == null ? void 0 : _theme$typography3$px.call(_theme$typography3, 35)) || '2.1875rem'\n }[ownerState.fontSize],\n // TODO v5 deprecate, v6 remove for sx\n color: (_palette$ownerState$c = (_palette = (theme.vars || theme).palette) == null || (_palette = _palette[ownerState.color]) == null ? void 0 : _palette.main) != null ? _palette$ownerState$c : {\n action: (_palette2 = (theme.vars || theme).palette) == null || (_palette2 = _palette2.action) == null ? void 0 : _palette2.active,\n disabled: (_palette3 = (theme.vars || theme).palette) == null || (_palette3 = _palette3.action) == null ? void 0 : _palette3.disabled,\n inherit: undefined\n }[ownerState.color]\n };\n});\nconst SvgIcon = /*#__PURE__*/React.forwardRef(function SvgIcon(inProps, ref) {\n const props = useThemeProps({\n props: inProps,\n name: 'MuiSvgIcon'\n });\n const {\n children,\n className,\n color = 'inherit',\n component = 'svg',\n fontSize = 'medium',\n htmlColor,\n inheritViewBox = false,\n titleAccess,\n viewBox = '0 0 24 24'\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const hasSvgAsChild = /*#__PURE__*/React.isValidElement(children) && children.type === 'svg';\n const ownerState = _extends({}, props, {\n color,\n component,\n fontSize,\n instanceFontSize: inProps.fontSize,\n inheritViewBox,\n viewBox,\n hasSvgAsChild\n });\n const more = {};\n if (!inheritViewBox) {\n more.viewBox = viewBox;\n }\n const classes = useUtilityClasses(ownerState);\n return /*#__PURE__*/_jsxs(SvgIconRoot, _extends({\n as: component,\n className: clsx(classes.root, className),\n focusable: \"false\",\n color: htmlColor,\n \"aria-hidden\": titleAccess ? undefined : true,\n role: titleAccess ? 'img' : undefined,\n ref: ref\n }, more, other, hasSvgAsChild && children.props, {\n ownerState: ownerState,\n children: [hasSvgAsChild ? children.props.children : children, titleAccess ? /*#__PURE__*/_jsx(\"title\", {\n children: titleAccess\n }) : null]\n }));\n});\nprocess.env.NODE_ENV !== \"production\" ? SvgIcon.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the d.ts file and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * Node passed into the SVG element.\n */\n children: PropTypes.node,\n /**\n * Override or extend the styles applied to the component.\n */\n classes: PropTypes.object,\n /**\n * @ignore\n */\n className: PropTypes.string,\n /**\n * The color of the component.\n * It supports both default and custom theme colors, which can be added as shown in the\n * [palette customization guide](https://mui.com/material-ui/customization/palette/#custom-colors).\n * You can use the `htmlColor` prop to apply a color attribute to the SVG element.\n * @default 'inherit'\n */\n color: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.oneOf(['inherit', 'action', 'disabled', 'primary', 'secondary', 'error', 'info', 'success', 'warning']), PropTypes.string]),\n /**\n * The component used for the root node.\n * Either a string to use a HTML element or a component.\n */\n component: PropTypes.elementType,\n /**\n * The fontSize applied to the icon. Defaults to 24px, but can be configure to inherit font size.\n * @default 'medium'\n */\n fontSize: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.oneOf(['inherit', 'large', 'medium', 'small']), PropTypes.string]),\n /**\n * Applies a color attribute to the SVG element.\n */\n htmlColor: PropTypes.string,\n /**\n * If `true`, the root node will inherit the custom `component`'s viewBox and the `viewBox`\n * prop will be ignored.\n * Useful when you want to reference a custom `component` and have `SvgIcon` pass that\n * `component`'s viewBox to the root node.\n * @default false\n */\n inheritViewBox: PropTypes.bool,\n /**\n * The shape-rendering attribute. The behavior of the different options is described on the\n * [MDN Web Docs](https://developer.mozilla.org/en-US/docs/Web/SVG/Attribute/shape-rendering).\n * If you are having issues with blurry icons you should investigate this prop.\n */\n shapeRendering: PropTypes.string,\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Provides a human-readable title for the element that contains it.\n * https://www.w3.org/TR/SVG-access/#Equivalent\n */\n titleAccess: PropTypes.string,\n /**\n * Allows you to redefine what the coordinates without units mean inside an SVG element.\n * For example, if the SVG element is 500 (width) by 200 (height),\n * and you pass viewBox=\"0 0 50 20\",\n * this means that the coordinates inside the SVG will go from the top left corner (0,0)\n * to bottom right (50,20) and each unit will be worth 10px.\n * @default '0 0 24 24'\n */\n viewBox: PropTypes.string\n} : void 0;\nSvgIcon.muiName = 'SvgIcon';\nexport default SvgIcon;","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport * as React from 'react';\nimport SvgIcon from '../SvgIcon';\n\n/**\n * Private module reserved for @mui packages.\n */\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nexport default function createSvgIcon(path, displayName) {\n function Component(props, ref) {\n return /*#__PURE__*/_jsx(SvgIcon, _extends({\n \"data-testid\": `${displayName}Icon`,\n ref: ref\n }, props, {\n children: path\n }));\n }\n if (process.env.NODE_ENV !== 'production') {\n // Need to set `displayName` on the inner component for React.memo.\n // React prior to 16.14 ignores `displayName` on the wrapper.\n Component.displayName = `${displayName}Icon`;\n }\n Component.muiName = SvgIcon.muiName;\n return /*#__PURE__*/React.memo( /*#__PURE__*/React.forwardRef(Component));\n}","'use client';\n\nimport { unstable_ClassNameGenerator as ClassNameGenerator } from '@mui/base/ClassNameGenerator';\nexport { default as capitalize } from './capitalize';\nexport { default as createChainedFunction } from './createChainedFunction';\nexport { default as createSvgIcon } from './createSvgIcon';\nexport { default as debounce } from './debounce';\nexport { default as deprecatedPropType } from './deprecatedPropType';\nexport { default as isMuiElement } from './isMuiElement';\nexport { default as ownerDocument } from './ownerDocument';\nexport { default as ownerWindow } from './ownerWindow';\nexport { default as requirePropFactory } from './requirePropFactory';\nexport { default as setRef } from './setRef';\nexport { default as unstable_useEnhancedEffect } from './useEnhancedEffect';\nexport { default as unstable_useId } from './useId';\nexport { default as unsupportedProp } from './unsupportedProp';\nexport { default as useControlled } from './useControlled';\nexport { default as useEventCallback } from './useEventCallback';\nexport { default as useForkRef } from './useForkRef';\nexport { default as useIsFocusVisible } from './useIsFocusVisible';\n// TODO: remove this export once ClassNameGenerator is stable\n// eslint-disable-next-line @typescript-eslint/naming-convention\nexport const unstable_ClassNameGenerator = {\n configure: generator => {\n if (process.env.NODE_ENV !== 'production') {\n console.warn(['MUI: `ClassNameGenerator` import from `@mui/material/utils` is outdated and might cause unexpected issues.', '', \"You should use `import { unstable_ClassNameGenerator } from '@mui/material/className'` instead\", '', 'The detail of the issue: https://github.com/mui/material-ui/issues/30011#issuecomment-1024993401', '', 'The updated documentation: https://mui.com/guides/classname-generator/'].join('\\n'));\n }\n ClassNameGenerator.configure(generator);\n }\n};","\"use strict\";\n'use client';\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nObject.defineProperty(exports, \"default\", {\n enumerable: true,\n get: function () {\n return _utils.createSvgIcon;\n }\n});\nvar _utils = require(\"@mui/material/utils\");","\"use strict\";\n\"use client\";\n\nvar _interopRequireDefault = require(\"@babel/runtime/helpers/interopRequireDefault\");\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = void 0;\nvar _createSvgIcon = _interopRequireDefault(require(\"./utils/createSvgIcon\"));\nvar _jsxRuntime = require(\"react/jsx-runtime\");\nvar _default = exports.default = (0, _createSvgIcon.default)( /*#__PURE__*/(0, _jsxRuntime.jsx)(\"path\", {\n d: \"m10 17 5-5-5-5z\"\n}), 'ArrowRight');","/**\n * Determines if a given element is a DOM element name (i.e. not a React component).\n */\nexport function isHostComponent(element) {\n return typeof element === 'string';\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport { isHostComponent } from './isHostComponent';\n\n/**\n * Type of the ownerState based on the type of an element it applies to.\n * This resolves to the provided OwnerState for React components and `undefined` for host components.\n * Falls back to `OwnerState | undefined` when the exact type can't be determined in development time.\n */\n\n/**\n * Appends the ownerState object to the props, merging with the existing one if necessary.\n *\n * @param elementType Type of the element that owns the `existingProps`. If the element is a DOM node or undefined, `ownerState` is not applied.\n * @param otherProps Props of the element.\n * @param ownerState\n */\nexport function appendOwnerState(elementType, otherProps, ownerState) {\n if (elementType === undefined || isHostComponent(elementType)) {\n return otherProps;\n }\n return _extends({}, otherProps, {\n ownerState: _extends({}, otherProps.ownerState, ownerState)\n });\n}","'use client';\n\nimport * as React from 'react';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nconst defaultContextValue = {\n disableDefaultClasses: false\n};\nconst ClassNameConfiguratorContext = /*#__PURE__*/React.createContext(defaultContextValue);\n/**\n * @ignore - internal hook.\n *\n * Wraps the `generateUtilityClass` function and controls how the classes are generated.\n * Currently it only affects whether the classes are applied or not.\n *\n * @returns Function to be called with the `generateUtilityClass` function specific to a component to generate the classes.\n */\nexport function useClassNamesOverride(generateUtilityClass) {\n const {\n disableDefaultClasses\n } = React.useContext(ClassNameConfiguratorContext);\n return slot => {\n if (disableDefaultClasses) {\n return '';\n }\n return generateUtilityClass(slot);\n };\n}\n\n/**\n * Allows to configure the components within to not apply any built-in classes.\n */\nexport function ClassNameConfigurator(props) {\n const {\n disableDefaultClasses,\n children\n } = props;\n const contextValue = React.useMemo(() => ({\n disableDefaultClasses: disableDefaultClasses != null ? disableDefaultClasses : false\n }), [disableDefaultClasses]);\n return /*#__PURE__*/_jsx(ClassNameConfiguratorContext.Provider, {\n value: contextValue,\n children: children\n });\n}","/**\n * Extracts event handlers from a given object.\n * A prop is considered an event handler if it is a function and its name starts with `on`.\n *\n * @param object An object to extract event handlers from.\n * @param excludeKeys An array of keys to exclude from the returned object.\n */\nexport function extractEventHandlers(object, excludeKeys = []) {\n if (object === undefined) {\n return {};\n }\n const result = {};\n Object.keys(object).filter(prop => prop.match(/^on[A-Z]/) && typeof object[prop] === 'function' && !excludeKeys.includes(prop)).forEach(prop => {\n result[prop] = object[prop];\n });\n return result;\n}","/**\n * If `componentProps` is a function, calls it with the provided `ownerState`.\n * Otherwise, just returns `componentProps`.\n */\nexport function resolveComponentProps(componentProps, ownerState, slotState) {\n if (typeof componentProps === 'function') {\n return componentProps(ownerState, slotState);\n }\n return componentProps;\n}","/**\n * Removes event handlers from the given object.\n * A field is considered an event handler if it is a function with a name beginning with `on`.\n *\n * @param object Object to remove event handlers from.\n * @returns Object with event handlers removed.\n */\nexport function omitEventHandlers(object) {\n if (object === undefined) {\n return {};\n }\n const result = {};\n Object.keys(object).filter(prop => !(prop.match(/^on[A-Z]/) && typeof object[prop] === 'function')).forEach(prop => {\n result[prop] = object[prop];\n });\n return result;\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport clsx from 'clsx';\nimport { extractEventHandlers } from './extractEventHandlers';\nimport { omitEventHandlers } from './omitEventHandlers';\n/**\n * Merges the slot component internal props (usually coming from a hook)\n * with the externally provided ones.\n *\n * The merge order is (the latter overrides the former):\n * 1. The internal props (specified as a getter function to work with get*Props hook result)\n * 2. Additional props (specified internally on a Base UI component)\n * 3. External props specified on the owner component. These should only be used on a root slot.\n * 4. External props specified in the `slotProps.*` prop.\n * 5. The `className` prop - combined from all the above.\n * @param parameters\n * @returns\n */\nexport function mergeSlotProps(parameters) {\n const {\n getSlotProps,\n additionalProps,\n externalSlotProps,\n externalForwardedProps,\n className\n } = parameters;\n if (!getSlotProps) {\n // The simpler case - getSlotProps is not defined, so no internal event handlers are defined,\n // so we can simply merge all the props without having to worry about extracting event handlers.\n const joinedClasses = clsx(additionalProps == null ? void 0 : additionalProps.className, className, externalForwardedProps == null ? void 0 : externalForwardedProps.className, externalSlotProps == null ? void 0 : externalSlotProps.className);\n const mergedStyle = _extends({}, additionalProps == null ? void 0 : additionalProps.style, externalForwardedProps == null ? void 0 : externalForwardedProps.style, externalSlotProps == null ? void 0 : externalSlotProps.style);\n const props = _extends({}, additionalProps, externalForwardedProps, externalSlotProps);\n if (joinedClasses.length > 0) {\n props.className = joinedClasses;\n }\n if (Object.keys(mergedStyle).length > 0) {\n props.style = mergedStyle;\n }\n return {\n props,\n internalRef: undefined\n };\n }\n\n // In this case, getSlotProps is responsible for calling the external event handlers.\n // We don't need to include them in the merged props because of this.\n\n const eventHandlers = extractEventHandlers(_extends({}, externalForwardedProps, externalSlotProps));\n const componentsPropsWithoutEventHandlers = omitEventHandlers(externalSlotProps);\n const otherPropsWithoutEventHandlers = omitEventHandlers(externalForwardedProps);\n const internalSlotProps = getSlotProps(eventHandlers);\n\n // The order of classes is important here.\n // Emotion (that we use in libraries consuming Base UI) depends on this order\n // to properly override style. It requires the most important classes to be last\n // (see https://github.com/mui/material-ui/pull/33205) for the related discussion.\n const joinedClasses = clsx(internalSlotProps == null ? void 0 : internalSlotProps.className, additionalProps == null ? void 0 : additionalProps.className, className, externalForwardedProps == null ? void 0 : externalForwardedProps.className, externalSlotProps == null ? void 0 : externalSlotProps.className);\n const mergedStyle = _extends({}, internalSlotProps == null ? void 0 : internalSlotProps.style, additionalProps == null ? void 0 : additionalProps.style, externalForwardedProps == null ? void 0 : externalForwardedProps.style, externalSlotProps == null ? void 0 : externalSlotProps.style);\n const props = _extends({}, internalSlotProps, additionalProps, otherPropsWithoutEventHandlers, componentsPropsWithoutEventHandlers);\n if (joinedClasses.length > 0) {\n props.className = joinedClasses;\n }\n if (Object.keys(mergedStyle).length > 0) {\n props.style = mergedStyle;\n }\n return {\n props,\n internalRef: internalSlotProps.ref\n };\n}","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"elementType\", \"externalSlotProps\", \"ownerState\", \"skipResolvingSlotProps\"];\nimport { unstable_useForkRef as useForkRef } from '@mui/utils';\nimport { appendOwnerState } from './appendOwnerState';\nimport { mergeSlotProps } from './mergeSlotProps';\nimport { resolveComponentProps } from './resolveComponentProps';\n/**\n * @ignore - do not document.\n * Builds the props to be passed into the slot of an unstyled component.\n * It merges the internal props of the component with the ones supplied by the user, allowing to customize the behavior.\n * If the slot component is not a host component, it also merges in the `ownerState`.\n *\n * @param parameters.getSlotProps - A function that returns the props to be passed to the slot component.\n */\nexport function useSlotProps(parameters) {\n var _parameters$additiona;\n const {\n elementType,\n externalSlotProps,\n ownerState,\n skipResolvingSlotProps = false\n } = parameters,\n rest = _objectWithoutPropertiesLoose(parameters, _excluded);\n const resolvedComponentsProps = skipResolvingSlotProps ? {} : resolveComponentProps(externalSlotProps, ownerState);\n const {\n props: mergedProps,\n internalRef\n } = mergeSlotProps(_extends({}, rest, {\n externalSlotProps: resolvedComponentsProps\n }));\n const ref = useForkRef(internalRef, resolvedComponentsProps == null ? void 0 : resolvedComponentsProps.ref, (_parameters$additiona = parameters.additionalProps) == null ? void 0 : _parameters$additiona.ref);\n const props = appendOwnerState(elementType, _extends({}, mergedProps, {\n ref\n }), ownerState);\n return props;\n}","import { globalStateClasses } from '@mui/utils/generateUtilityClass';\nconst GLOBAL_CLASS_PREFIX = 'base';\nfunction buildStateClass(state) {\n return `${GLOBAL_CLASS_PREFIX}--${state}`;\n}\nfunction buildSlotClass(componentName, slot) {\n return `${GLOBAL_CLASS_PREFIX}-${componentName}-${slot}`;\n}\nexport function generateUtilityClass(componentName, slot) {\n const globalStateClass = globalStateClasses[slot];\n return globalStateClass ? buildStateClass(globalStateClass) : buildSlotClass(componentName, slot);\n}\nexport function isGlobalState(slot) {\n return globalStateClasses[slot] !== undefined;\n}","import { generateUtilityClass } from '../generateUtilityClass';\nexport function generateUtilityClasses(componentName, slots) {\n const result = {};\n slots.forEach(slot => {\n result[slot] = generateUtilityClass(componentName, slot);\n });\n return result;\n}","'use client';\n\nimport * as React from 'react';\nimport * as ReactDOM from 'react-dom';\nimport PropTypes from 'prop-types';\nimport { exactProp, HTMLElementType, unstable_useEnhancedEffect as useEnhancedEffect, unstable_useForkRef as useForkRef, unstable_setRef as setRef } from '@mui/utils';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nfunction getContainer(container) {\n return typeof container === 'function' ? container() : container;\n}\n\n/**\n * Portals provide a first-class way to render children into a DOM node\n * that exists outside the DOM hierarchy of the parent component.\n *\n * Demos:\n *\n * - [Portal](https://mui.com/base-ui/react-portal/)\n *\n * API:\n *\n * - [Portal API](https://mui.com/base-ui/react-portal/components-api/#portal)\n */\nconst Portal = /*#__PURE__*/React.forwardRef(function Portal(props, forwardedRef) {\n const {\n children,\n container,\n disablePortal = false\n } = props;\n const [mountNode, setMountNode] = React.useState(null);\n // @ts-expect-error TODO upstream fix\n const handleRef = useForkRef( /*#__PURE__*/React.isValidElement(children) ? children.ref : null, forwardedRef);\n useEnhancedEffect(() => {\n if (!disablePortal) {\n setMountNode(getContainer(container) || document.body);\n }\n }, [container, disablePortal]);\n useEnhancedEffect(() => {\n if (mountNode && !disablePortal) {\n setRef(forwardedRef, mountNode);\n return () => {\n setRef(forwardedRef, null);\n };\n }\n return undefined;\n }, [forwardedRef, mountNode, disablePortal]);\n if (disablePortal) {\n if ( /*#__PURE__*/React.isValidElement(children)) {\n const newProps = {\n ref: handleRef\n };\n return /*#__PURE__*/React.cloneElement(children, newProps);\n }\n return /*#__PURE__*/_jsx(React.Fragment, {\n children: children\n });\n }\n return /*#__PURE__*/_jsx(React.Fragment, {\n children: mountNode ? /*#__PURE__*/ReactDOM.createPortal(children, mountNode) : mountNode\n });\n});\nprocess.env.NODE_ENV !== \"production\" ? Portal.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * The children to render into the `container`.\n */\n children: PropTypes.node,\n /**\n * An HTML element or function that returns one.\n * The `container` will have the portal children appended to it.\n *\n * You can also provide a callback, which is called in a React layout effect.\n * This lets you set the container from a ref, and also makes server-side rendering possible.\n *\n * By default, it uses the body of the top-level document object,\n * so it's simply `document.body` most of the time.\n */\n container: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.func]),\n /**\n * The `children` will be under the DOM hierarchy of the parent component.\n * @default false\n */\n disablePortal: PropTypes.bool\n} : void 0;\nif (process.env.NODE_ENV !== 'production') {\n // eslint-disable-next-line\n Portal['propTypes' + ''] = exactProp(Portal.propTypes);\n}\nexport { Portal };","export var top = 'top';\nexport var bottom = 'bottom';\nexport var right = 'right';\nexport var left = 'left';\nexport var auto = 'auto';\nexport var basePlacements = [top, bottom, right, left];\nexport var start = 'start';\nexport var end = 'end';\nexport var clippingParents = 'clippingParents';\nexport var viewport = 'viewport';\nexport var popper = 'popper';\nexport var reference = 'reference';\nexport var variationPlacements = /*#__PURE__*/basePlacements.reduce(function (acc, placement) {\n return acc.concat([placement + \"-\" + start, placement + \"-\" + end]);\n}, []);\nexport var placements = /*#__PURE__*/[].concat(basePlacements, [auto]).reduce(function (acc, placement) {\n return acc.concat([placement, placement + \"-\" + start, placement + \"-\" + end]);\n}, []); // modifiers that need to read the DOM\n\nexport var beforeRead = 'beforeRead';\nexport var read = 'read';\nexport var afterRead = 'afterRead'; // pure-logic modifiers\n\nexport var beforeMain = 'beforeMain';\nexport var main = 'main';\nexport var afterMain = 'afterMain'; // modifier with the purpose to write to the DOM (or write into a framework state)\n\nexport var beforeWrite = 'beforeWrite';\nexport var write = 'write';\nexport var afterWrite = 'afterWrite';\nexport var modifierPhases = [beforeRead, read, afterRead, beforeMain, main, afterMain, beforeWrite, write, afterWrite];","export default function getNodeName(element) {\n return element ? (element.nodeName || '').toLowerCase() : null;\n}","export default function getWindow(node) {\n if (node == null) {\n return window;\n }\n\n if (node.toString() !== '[object Window]') {\n var ownerDocument = node.ownerDocument;\n return ownerDocument ? ownerDocument.defaultView || window : window;\n }\n\n return node;\n}","import getWindow from \"./getWindow.js\";\n\nfunction isElement(node) {\n var OwnElement = getWindow(node).Element;\n return node instanceof OwnElement || node instanceof Element;\n}\n\nfunction isHTMLElement(node) {\n var OwnElement = getWindow(node).HTMLElement;\n return node instanceof OwnElement || node instanceof HTMLElement;\n}\n\nfunction isShadowRoot(node) {\n // IE 11 has no ShadowRoot\n if (typeof ShadowRoot === 'undefined') {\n return false;\n }\n\n var OwnElement = getWindow(node).ShadowRoot;\n return node instanceof OwnElement || node instanceof ShadowRoot;\n}\n\nexport { isElement, isHTMLElement, isShadowRoot };","import getNodeName from \"../dom-utils/getNodeName.js\";\nimport { isHTMLElement } from \"../dom-utils/instanceOf.js\"; // This modifier takes the styles prepared by the `computeStyles` modifier\n// and applies them to the HTMLElements such as popper and arrow\n\nfunction applyStyles(_ref) {\n var state = _ref.state;\n Object.keys(state.elements).forEach(function (name) {\n var style = state.styles[name] || {};\n var attributes = state.attributes[name] || {};\n var element = state.elements[name]; // arrow is optional + virtual elements\n\n if (!isHTMLElement(element) || !getNodeName(element)) {\n return;\n } // Flow doesn't support to extend this property, but it's the most\n // effective way to apply styles to an HTMLElement\n // $FlowFixMe[cannot-write]\n\n\n Object.assign(element.style, style);\n Object.keys(attributes).forEach(function (name) {\n var value = attributes[name];\n\n if (value === false) {\n element.removeAttribute(name);\n } else {\n element.setAttribute(name, value === true ? '' : value);\n }\n });\n });\n}\n\nfunction effect(_ref2) {\n var state = _ref2.state;\n var initialStyles = {\n popper: {\n position: state.options.strategy,\n left: '0',\n top: '0',\n margin: '0'\n },\n arrow: {\n position: 'absolute'\n },\n reference: {}\n };\n Object.assign(state.elements.popper.style, initialStyles.popper);\n state.styles = initialStyles;\n\n if (state.elements.arrow) {\n Object.assign(state.elements.arrow.style, initialStyles.arrow);\n }\n\n return function () {\n Object.keys(state.elements).forEach(function (name) {\n var element = state.elements[name];\n var attributes = state.attributes[name] || {};\n var styleProperties = Object.keys(state.styles.hasOwnProperty(name) ? state.styles[name] : initialStyles[name]); // Set all values to an empty string to unset them\n\n var style = styleProperties.reduce(function (style, property) {\n style[property] = '';\n return style;\n }, {}); // arrow is optional + virtual elements\n\n if (!isHTMLElement(element) || !getNodeName(element)) {\n return;\n }\n\n Object.assign(element.style, style);\n Object.keys(attributes).forEach(function (attribute) {\n element.removeAttribute(attribute);\n });\n });\n };\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'applyStyles',\n enabled: true,\n phase: 'write',\n fn: applyStyles,\n effect: effect,\n requires: ['computeStyles']\n};","import { auto } from \"../enums.js\";\nexport default function getBasePlacement(placement) {\n return placement.split('-')[0];\n}","export var max = Math.max;\nexport var min = Math.min;\nexport var round = Math.round;","export default function getUAString() {\n var uaData = navigator.userAgentData;\n\n if (uaData != null && uaData.brands && Array.isArray(uaData.brands)) {\n return uaData.brands.map(function (item) {\n return item.brand + \"/\" + item.version;\n }).join(' ');\n }\n\n return navigator.userAgent;\n}","import getUAString from \"../utils/userAgent.js\";\nexport default function isLayoutViewport() {\n return !/^((?!chrome|android).)*safari/i.test(getUAString());\n}","import { isElement, isHTMLElement } from \"./instanceOf.js\";\nimport { round } from \"../utils/math.js\";\nimport getWindow from \"./getWindow.js\";\nimport isLayoutViewport from \"./isLayoutViewport.js\";\nexport default function getBoundingClientRect(element, includeScale, isFixedStrategy) {\n if (includeScale === void 0) {\n includeScale = false;\n }\n\n if (isFixedStrategy === void 0) {\n isFixedStrategy = false;\n }\n\n var clientRect = element.getBoundingClientRect();\n var scaleX = 1;\n var scaleY = 1;\n\n if (includeScale && isHTMLElement(element)) {\n scaleX = element.offsetWidth > 0 ? round(clientRect.width) / element.offsetWidth || 1 : 1;\n scaleY = element.offsetHeight > 0 ? round(clientRect.height) / element.offsetHeight || 1 : 1;\n }\n\n var _ref = isElement(element) ? getWindow(element) : window,\n visualViewport = _ref.visualViewport;\n\n var addVisualOffsets = !isLayoutViewport() && isFixedStrategy;\n var x = (clientRect.left + (addVisualOffsets && visualViewport ? visualViewport.offsetLeft : 0)) / scaleX;\n var y = (clientRect.top + (addVisualOffsets && visualViewport ? visualViewport.offsetTop : 0)) / scaleY;\n var width = clientRect.width / scaleX;\n var height = clientRect.height / scaleY;\n return {\n width: width,\n height: height,\n top: y,\n right: x + width,\n bottom: y + height,\n left: x,\n x: x,\n y: y\n };\n}","import getBoundingClientRect from \"./getBoundingClientRect.js\"; // Returns the layout rect of an element relative to its offsetParent. Layout\n// means it doesn't take into account transforms.\n\nexport default function getLayoutRect(element) {\n var clientRect = getBoundingClientRect(element); // Use the clientRect sizes if it's not been transformed.\n // Fixes https://github.com/popperjs/popper-core/issues/1223\n\n var width = element.offsetWidth;\n var height = element.offsetHeight;\n\n if (Math.abs(clientRect.width - width) <= 1) {\n width = clientRect.width;\n }\n\n if (Math.abs(clientRect.height - height) <= 1) {\n height = clientRect.height;\n }\n\n return {\n x: element.offsetLeft,\n y: element.offsetTop,\n width: width,\n height: height\n };\n}","import { isShadowRoot } from \"./instanceOf.js\";\nexport default function contains(parent, child) {\n var rootNode = child.getRootNode && child.getRootNode(); // First, attempt with faster native method\n\n if (parent.contains(child)) {\n return true;\n } // then fallback to custom implementation with Shadow DOM support\n else if (rootNode && isShadowRoot(rootNode)) {\n var next = child;\n\n do {\n if (next && parent.isSameNode(next)) {\n return true;\n } // $FlowFixMe[prop-missing]: need a better way to handle this...\n\n\n next = next.parentNode || next.host;\n } while (next);\n } // Give up, the result is false\n\n\n return false;\n}","import getWindow from \"./getWindow.js\";\nexport default function getComputedStyle(element) {\n return getWindow(element).getComputedStyle(element);\n}","import getNodeName from \"./getNodeName.js\";\nexport default function isTableElement(element) {\n return ['table', 'td', 'th'].indexOf(getNodeName(element)) >= 0;\n}","import { isElement } from \"./instanceOf.js\";\nexport default function getDocumentElement(element) {\n // $FlowFixMe[incompatible-return]: assume body is always available\n return ((isElement(element) ? element.ownerDocument : // $FlowFixMe[prop-missing]\n element.document) || window.document).documentElement;\n}","import getNodeName from \"./getNodeName.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport { isShadowRoot } from \"./instanceOf.js\";\nexport default function getParentNode(element) {\n if (getNodeName(element) === 'html') {\n return element;\n }\n\n return (// this is a quicker (but less type safe) way to save quite some bytes from the bundle\n // $FlowFixMe[incompatible-return]\n // $FlowFixMe[prop-missing]\n element.assignedSlot || // step into the shadow DOM of the parent of a slotted node\n element.parentNode || ( // DOM Element detected\n isShadowRoot(element) ? element.host : null) || // ShadowRoot detected\n // $FlowFixMe[incompatible-call]: HTMLElement is a Node\n getDocumentElement(element) // fallback\n\n );\n}","import getWindow from \"./getWindow.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport getComputedStyle from \"./getComputedStyle.js\";\nimport { isHTMLElement, isShadowRoot } from \"./instanceOf.js\";\nimport isTableElement from \"./isTableElement.js\";\nimport getParentNode from \"./getParentNode.js\";\nimport getUAString from \"../utils/userAgent.js\";\n\nfunction getTrueOffsetParent(element) {\n if (!isHTMLElement(element) || // https://github.com/popperjs/popper-core/issues/837\n getComputedStyle(element).position === 'fixed') {\n return null;\n }\n\n return element.offsetParent;\n} // `.offsetParent` reports `null` for fixed elements, while absolute elements\n// return the containing block\n\n\nfunction getContainingBlock(element) {\n var isFirefox = /firefox/i.test(getUAString());\n var isIE = /Trident/i.test(getUAString());\n\n if (isIE && isHTMLElement(element)) {\n // In IE 9, 10 and 11 fixed elements containing block is always established by the viewport\n var elementCss = getComputedStyle(element);\n\n if (elementCss.position === 'fixed') {\n return null;\n }\n }\n\n var currentNode = getParentNode(element);\n\n if (isShadowRoot(currentNode)) {\n currentNode = currentNode.host;\n }\n\n while (isHTMLElement(currentNode) && ['html', 'body'].indexOf(getNodeName(currentNode)) < 0) {\n var css = getComputedStyle(currentNode); // This is non-exhaustive but covers the most common CSS properties that\n // create a containing block.\n // https://developer.mozilla.org/en-US/docs/Web/CSS/Containing_block#identifying_the_containing_block\n\n if (css.transform !== 'none' || css.perspective !== 'none' || css.contain === 'paint' || ['transform', 'perspective'].indexOf(css.willChange) !== -1 || isFirefox && css.willChange === 'filter' || isFirefox && css.filter && css.filter !== 'none') {\n return currentNode;\n } else {\n currentNode = currentNode.parentNode;\n }\n }\n\n return null;\n} // Gets the closest ancestor positioned element. Handles some edge cases,\n// such as table ancestors and cross browser bugs.\n\n\nexport default function getOffsetParent(element) {\n var window = getWindow(element);\n var offsetParent = getTrueOffsetParent(element);\n\n while (offsetParent && isTableElement(offsetParent) && getComputedStyle(offsetParent).position === 'static') {\n offsetParent = getTrueOffsetParent(offsetParent);\n }\n\n if (offsetParent && (getNodeName(offsetParent) === 'html' || getNodeName(offsetParent) === 'body' && getComputedStyle(offsetParent).position === 'static')) {\n return window;\n }\n\n return offsetParent || getContainingBlock(element) || window;\n}","export default function getMainAxisFromPlacement(placement) {\n return ['top', 'bottom'].indexOf(placement) >= 0 ? 'x' : 'y';\n}","import { max as mathMax, min as mathMin } from \"./math.js\";\nexport function within(min, value, max) {\n return mathMax(min, mathMin(value, max));\n}\nexport function withinMaxClamp(min, value, max) {\n var v = within(min, value, max);\n return v > max ? max : v;\n}","export default function getFreshSideObject() {\n return {\n top: 0,\n right: 0,\n bottom: 0,\n left: 0\n };\n}","import getFreshSideObject from \"./getFreshSideObject.js\";\nexport default function mergePaddingObject(paddingObject) {\n return Object.assign({}, getFreshSideObject(), paddingObject);\n}","export default function expandToHashMap(value, keys) {\n return keys.reduce(function (hashMap, key) {\n hashMap[key] = value;\n return hashMap;\n }, {});\n}","import getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getLayoutRect from \"../dom-utils/getLayoutRect.js\";\nimport contains from \"../dom-utils/contains.js\";\nimport getOffsetParent from \"../dom-utils/getOffsetParent.js\";\nimport getMainAxisFromPlacement from \"../utils/getMainAxisFromPlacement.js\";\nimport { within } from \"../utils/within.js\";\nimport mergePaddingObject from \"../utils/mergePaddingObject.js\";\nimport expandToHashMap from \"../utils/expandToHashMap.js\";\nimport { left, right, basePlacements, top, bottom } from \"../enums.js\"; // eslint-disable-next-line import/no-unused-modules\n\nvar toPaddingObject = function toPaddingObject(padding, state) {\n padding = typeof padding === 'function' ? padding(Object.assign({}, state.rects, {\n placement: state.placement\n })) : padding;\n return mergePaddingObject(typeof padding !== 'number' ? padding : expandToHashMap(padding, basePlacements));\n};\n\nfunction arrow(_ref) {\n var _state$modifiersData$;\n\n var state = _ref.state,\n name = _ref.name,\n options = _ref.options;\n var arrowElement = state.elements.arrow;\n var popperOffsets = state.modifiersData.popperOffsets;\n var basePlacement = getBasePlacement(state.placement);\n var axis = getMainAxisFromPlacement(basePlacement);\n var isVertical = [left, right].indexOf(basePlacement) >= 0;\n var len = isVertical ? 'height' : 'width';\n\n if (!arrowElement || !popperOffsets) {\n return;\n }\n\n var paddingObject = toPaddingObject(options.padding, state);\n var arrowRect = getLayoutRect(arrowElement);\n var minProp = axis === 'y' ? top : left;\n var maxProp = axis === 'y' ? bottom : right;\n var endDiff = state.rects.reference[len] + state.rects.reference[axis] - popperOffsets[axis] - state.rects.popper[len];\n var startDiff = popperOffsets[axis] - state.rects.reference[axis];\n var arrowOffsetParent = getOffsetParent(arrowElement);\n var clientSize = arrowOffsetParent ? axis === 'y' ? arrowOffsetParent.clientHeight || 0 : arrowOffsetParent.clientWidth || 0 : 0;\n var centerToReference = endDiff / 2 - startDiff / 2; // Make sure the arrow doesn't overflow the popper if the center point is\n // outside of the popper bounds\n\n var min = paddingObject[minProp];\n var max = clientSize - arrowRect[len] - paddingObject[maxProp];\n var center = clientSize / 2 - arrowRect[len] / 2 + centerToReference;\n var offset = within(min, center, max); // Prevents breaking syntax highlighting...\n\n var axisProp = axis;\n state.modifiersData[name] = (_state$modifiersData$ = {}, _state$modifiersData$[axisProp] = offset, _state$modifiersData$.centerOffset = offset - center, _state$modifiersData$);\n}\n\nfunction effect(_ref2) {\n var state = _ref2.state,\n options = _ref2.options;\n var _options$element = options.element,\n arrowElement = _options$element === void 0 ? '[data-popper-arrow]' : _options$element;\n\n if (arrowElement == null) {\n return;\n } // CSS selector\n\n\n if (typeof arrowElement === 'string') {\n arrowElement = state.elements.popper.querySelector(arrowElement);\n\n if (!arrowElement) {\n return;\n }\n }\n\n if (!contains(state.elements.popper, arrowElement)) {\n return;\n }\n\n state.elements.arrow = arrowElement;\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'arrow',\n enabled: true,\n phase: 'main',\n fn: arrow,\n effect: effect,\n requires: ['popperOffsets'],\n requiresIfExists: ['preventOverflow']\n};","export default function getVariation(placement) {\n return placement.split('-')[1];\n}","import { top, left, right, bottom, end } from \"../enums.js\";\nimport getOffsetParent from \"../dom-utils/getOffsetParent.js\";\nimport getWindow from \"../dom-utils/getWindow.js\";\nimport getDocumentElement from \"../dom-utils/getDocumentElement.js\";\nimport getComputedStyle from \"../dom-utils/getComputedStyle.js\";\nimport getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getVariation from \"../utils/getVariation.js\";\nimport { round } from \"../utils/math.js\"; // eslint-disable-next-line import/no-unused-modules\n\nvar unsetSides = {\n top: 'auto',\n right: 'auto',\n bottom: 'auto',\n left: 'auto'\n}; // Round the offsets to the nearest suitable subpixel based on the DPR.\n// Zooming can change the DPR, but it seems to report a value that will\n// cleanly divide the values into the appropriate subpixels.\n\nfunction roundOffsetsByDPR(_ref, win) {\n var x = _ref.x,\n y = _ref.y;\n var dpr = win.devicePixelRatio || 1;\n return {\n x: round(x * dpr) / dpr || 0,\n y: round(y * dpr) / dpr || 0\n };\n}\n\nexport function mapToStyles(_ref2) {\n var _Object$assign2;\n\n var popper = _ref2.popper,\n popperRect = _ref2.popperRect,\n placement = _ref2.placement,\n variation = _ref2.variation,\n offsets = _ref2.offsets,\n position = _ref2.position,\n gpuAcceleration = _ref2.gpuAcceleration,\n adaptive = _ref2.adaptive,\n roundOffsets = _ref2.roundOffsets,\n isFixed = _ref2.isFixed;\n var _offsets$x = offsets.x,\n x = _offsets$x === void 0 ? 0 : _offsets$x,\n _offsets$y = offsets.y,\n y = _offsets$y === void 0 ? 0 : _offsets$y;\n\n var _ref3 = typeof roundOffsets === 'function' ? roundOffsets({\n x: x,\n y: y\n }) : {\n x: x,\n y: y\n };\n\n x = _ref3.x;\n y = _ref3.y;\n var hasX = offsets.hasOwnProperty('x');\n var hasY = offsets.hasOwnProperty('y');\n var sideX = left;\n var sideY = top;\n var win = window;\n\n if (adaptive) {\n var offsetParent = getOffsetParent(popper);\n var heightProp = 'clientHeight';\n var widthProp = 'clientWidth';\n\n if (offsetParent === getWindow(popper)) {\n offsetParent = getDocumentElement(popper);\n\n if (getComputedStyle(offsetParent).position !== 'static' && position === 'absolute') {\n heightProp = 'scrollHeight';\n widthProp = 'scrollWidth';\n }\n } // $FlowFixMe[incompatible-cast]: force type refinement, we compare offsetParent with window above, but Flow doesn't detect it\n\n\n offsetParent = offsetParent;\n\n if (placement === top || (placement === left || placement === right) && variation === end) {\n sideY = bottom;\n var offsetY = isFixed && offsetParent === win && win.visualViewport ? win.visualViewport.height : // $FlowFixMe[prop-missing]\n offsetParent[heightProp];\n y -= offsetY - popperRect.height;\n y *= gpuAcceleration ? 1 : -1;\n }\n\n if (placement === left || (placement === top || placement === bottom) && variation === end) {\n sideX = right;\n var offsetX = isFixed && offsetParent === win && win.visualViewport ? win.visualViewport.width : // $FlowFixMe[prop-missing]\n offsetParent[widthProp];\n x -= offsetX - popperRect.width;\n x *= gpuAcceleration ? 1 : -1;\n }\n }\n\n var commonStyles = Object.assign({\n position: position\n }, adaptive && unsetSides);\n\n var _ref4 = roundOffsets === true ? roundOffsetsByDPR({\n x: x,\n y: y\n }, getWindow(popper)) : {\n x: x,\n y: y\n };\n\n x = _ref4.x;\n y = _ref4.y;\n\n if (gpuAcceleration) {\n var _Object$assign;\n\n return Object.assign({}, commonStyles, (_Object$assign = {}, _Object$assign[sideY] = hasY ? '0' : '', _Object$assign[sideX] = hasX ? '0' : '', _Object$assign.transform = (win.devicePixelRatio || 1) <= 1 ? \"translate(\" + x + \"px, \" + y + \"px)\" : \"translate3d(\" + x + \"px, \" + y + \"px, 0)\", _Object$assign));\n }\n\n return Object.assign({}, commonStyles, (_Object$assign2 = {}, _Object$assign2[sideY] = hasY ? y + \"px\" : '', _Object$assign2[sideX] = hasX ? x + \"px\" : '', _Object$assign2.transform = '', _Object$assign2));\n}\n\nfunction computeStyles(_ref5) {\n var state = _ref5.state,\n options = _ref5.options;\n var _options$gpuAccelerat = options.gpuAcceleration,\n gpuAcceleration = _options$gpuAccelerat === void 0 ? true : _options$gpuAccelerat,\n _options$adaptive = options.adaptive,\n adaptive = _options$adaptive === void 0 ? true : _options$adaptive,\n _options$roundOffsets = options.roundOffsets,\n roundOffsets = _options$roundOffsets === void 0 ? true : _options$roundOffsets;\n var commonStyles = {\n placement: getBasePlacement(state.placement),\n variation: getVariation(state.placement),\n popper: state.elements.popper,\n popperRect: state.rects.popper,\n gpuAcceleration: gpuAcceleration,\n isFixed: state.options.strategy === 'fixed'\n };\n\n if (state.modifiersData.popperOffsets != null) {\n state.styles.popper = Object.assign({}, state.styles.popper, mapToStyles(Object.assign({}, commonStyles, {\n offsets: state.modifiersData.popperOffsets,\n position: state.options.strategy,\n adaptive: adaptive,\n roundOffsets: roundOffsets\n })));\n }\n\n if (state.modifiersData.arrow != null) {\n state.styles.arrow = Object.assign({}, state.styles.arrow, mapToStyles(Object.assign({}, commonStyles, {\n offsets: state.modifiersData.arrow,\n position: 'absolute',\n adaptive: false,\n roundOffsets: roundOffsets\n })));\n }\n\n state.attributes.popper = Object.assign({}, state.attributes.popper, {\n 'data-popper-placement': state.placement\n });\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'computeStyles',\n enabled: true,\n phase: 'beforeWrite',\n fn: computeStyles,\n data: {}\n};","import getWindow from \"../dom-utils/getWindow.js\"; // eslint-disable-next-line import/no-unused-modules\n\nvar passive = {\n passive: true\n};\n\nfunction effect(_ref) {\n var state = _ref.state,\n instance = _ref.instance,\n options = _ref.options;\n var _options$scroll = options.scroll,\n scroll = _options$scroll === void 0 ? true : _options$scroll,\n _options$resize = options.resize,\n resize = _options$resize === void 0 ? true : _options$resize;\n var window = getWindow(state.elements.popper);\n var scrollParents = [].concat(state.scrollParents.reference, state.scrollParents.popper);\n\n if (scroll) {\n scrollParents.forEach(function (scrollParent) {\n scrollParent.addEventListener('scroll', instance.update, passive);\n });\n }\n\n if (resize) {\n window.addEventListener('resize', instance.update, passive);\n }\n\n return function () {\n if (scroll) {\n scrollParents.forEach(function (scrollParent) {\n scrollParent.removeEventListener('scroll', instance.update, passive);\n });\n }\n\n if (resize) {\n window.removeEventListener('resize', instance.update, passive);\n }\n };\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'eventListeners',\n enabled: true,\n phase: 'write',\n fn: function fn() {},\n effect: effect,\n data: {}\n};","var hash = {\n left: 'right',\n right: 'left',\n bottom: 'top',\n top: 'bottom'\n};\nexport default function getOppositePlacement(placement) {\n return placement.replace(/left|right|bottom|top/g, function (matched) {\n return hash[matched];\n });\n}","var hash = {\n start: 'end',\n end: 'start'\n};\nexport default function getOppositeVariationPlacement(placement) {\n return placement.replace(/start|end/g, function (matched) {\n return hash[matched];\n });\n}","import getWindow from \"./getWindow.js\";\nexport default function getWindowScroll(node) {\n var win = getWindow(node);\n var scrollLeft = win.pageXOffset;\n var scrollTop = win.pageYOffset;\n return {\n scrollLeft: scrollLeft,\n scrollTop: scrollTop\n };\n}","import getBoundingClientRect from \"./getBoundingClientRect.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport getWindowScroll from \"./getWindowScroll.js\";\nexport default function getWindowScrollBarX(element) {\n // If has a CSS width greater than the viewport, then this will be\n // incorrect for RTL.\n // Popper 1 is broken in this case and never had a bug report so let's assume\n // it's not an issue. I don't think anyone ever specifies width on \n // anyway.\n // Browsers where the left scrollbar doesn't cause an issue report `0` for\n // this (e.g. Edge 2019, IE11, Safari)\n return getBoundingClientRect(getDocumentElement(element)).left + getWindowScroll(element).scrollLeft;\n}","import getWindow from \"./getWindow.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport getWindowScrollBarX from \"./getWindowScrollBarX.js\";\nimport isLayoutViewport from \"./isLayoutViewport.js\";\nexport default function getViewportRect(element, strategy) {\n var win = getWindow(element);\n var html = getDocumentElement(element);\n var visualViewport = win.visualViewport;\n var width = html.clientWidth;\n var height = html.clientHeight;\n var x = 0;\n var y = 0;\n\n if (visualViewport) {\n width = visualViewport.width;\n height = visualViewport.height;\n var layoutViewport = isLayoutViewport();\n\n if (layoutViewport || !layoutViewport && strategy === 'fixed') {\n x = visualViewport.offsetLeft;\n y = visualViewport.offsetTop;\n }\n }\n\n return {\n width: width,\n height: height,\n x: x + getWindowScrollBarX(element),\n y: y\n };\n}","import getDocumentElement from \"./getDocumentElement.js\";\nimport getComputedStyle from \"./getComputedStyle.js\";\nimport getWindowScrollBarX from \"./getWindowScrollBarX.js\";\nimport getWindowScroll from \"./getWindowScroll.js\";\nimport { max } from \"../utils/math.js\"; // Gets the entire size of the scrollable document area, even extending outside\n// of the `` and `` rect bounds if horizontally scrollable\n\nexport default function getDocumentRect(element) {\n var _element$ownerDocumen;\n\n var html = getDocumentElement(element);\n var winScroll = getWindowScroll(element);\n var body = (_element$ownerDocumen = element.ownerDocument) == null ? void 0 : _element$ownerDocumen.body;\n var width = max(html.scrollWidth, html.clientWidth, body ? body.scrollWidth : 0, body ? body.clientWidth : 0);\n var height = max(html.scrollHeight, html.clientHeight, body ? body.scrollHeight : 0, body ? body.clientHeight : 0);\n var x = -winScroll.scrollLeft + getWindowScrollBarX(element);\n var y = -winScroll.scrollTop;\n\n if (getComputedStyle(body || html).direction === 'rtl') {\n x += max(html.clientWidth, body ? body.clientWidth : 0) - width;\n }\n\n return {\n width: width,\n height: height,\n x: x,\n y: y\n };\n}","import getComputedStyle from \"./getComputedStyle.js\";\nexport default function isScrollParent(element) {\n // Firefox wants us to check `-x` and `-y` variations as well\n var _getComputedStyle = getComputedStyle(element),\n overflow = _getComputedStyle.overflow,\n overflowX = _getComputedStyle.overflowX,\n overflowY = _getComputedStyle.overflowY;\n\n return /auto|scroll|overlay|hidden/.test(overflow + overflowY + overflowX);\n}","import getParentNode from \"./getParentNode.js\";\nimport isScrollParent from \"./isScrollParent.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport { isHTMLElement } from \"./instanceOf.js\";\nexport default function getScrollParent(node) {\n if (['html', 'body', '#document'].indexOf(getNodeName(node)) >= 0) {\n // $FlowFixMe[incompatible-return]: assume body is always available\n return node.ownerDocument.body;\n }\n\n if (isHTMLElement(node) && isScrollParent(node)) {\n return node;\n }\n\n return getScrollParent(getParentNode(node));\n}","import getScrollParent from \"./getScrollParent.js\";\nimport getParentNode from \"./getParentNode.js\";\nimport getWindow from \"./getWindow.js\";\nimport isScrollParent from \"./isScrollParent.js\";\n/*\ngiven a DOM element, return the list of all scroll parents, up the list of ancesors\nuntil we get to the top window object. This list is what we attach scroll listeners\nto, because if any of these parent elements scroll, we'll need to re-calculate the\nreference element's position.\n*/\n\nexport default function listScrollParents(element, list) {\n var _element$ownerDocumen;\n\n if (list === void 0) {\n list = [];\n }\n\n var scrollParent = getScrollParent(element);\n var isBody = scrollParent === ((_element$ownerDocumen = element.ownerDocument) == null ? void 0 : _element$ownerDocumen.body);\n var win = getWindow(scrollParent);\n var target = isBody ? [win].concat(win.visualViewport || [], isScrollParent(scrollParent) ? scrollParent : []) : scrollParent;\n var updatedList = list.concat(target);\n return isBody ? updatedList : // $FlowFixMe[incompatible-call]: isBody tells us target will be an HTMLElement here\n updatedList.concat(listScrollParents(getParentNode(target)));\n}","export default function rectToClientRect(rect) {\n return Object.assign({}, rect, {\n left: rect.x,\n top: rect.y,\n right: rect.x + rect.width,\n bottom: rect.y + rect.height\n });\n}","import { viewport } from \"../enums.js\";\nimport getViewportRect from \"./getViewportRect.js\";\nimport getDocumentRect from \"./getDocumentRect.js\";\nimport listScrollParents from \"./listScrollParents.js\";\nimport getOffsetParent from \"./getOffsetParent.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport getComputedStyle from \"./getComputedStyle.js\";\nimport { isElement, isHTMLElement } from \"./instanceOf.js\";\nimport getBoundingClientRect from \"./getBoundingClientRect.js\";\nimport getParentNode from \"./getParentNode.js\";\nimport contains from \"./contains.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport rectToClientRect from \"../utils/rectToClientRect.js\";\nimport { max, min } from \"../utils/math.js\";\n\nfunction getInnerBoundingClientRect(element, strategy) {\n var rect = getBoundingClientRect(element, false, strategy === 'fixed');\n rect.top = rect.top + element.clientTop;\n rect.left = rect.left + element.clientLeft;\n rect.bottom = rect.top + element.clientHeight;\n rect.right = rect.left + element.clientWidth;\n rect.width = element.clientWidth;\n rect.height = element.clientHeight;\n rect.x = rect.left;\n rect.y = rect.top;\n return rect;\n}\n\nfunction getClientRectFromMixedType(element, clippingParent, strategy) {\n return clippingParent === viewport ? rectToClientRect(getViewportRect(element, strategy)) : isElement(clippingParent) ? getInnerBoundingClientRect(clippingParent, strategy) : rectToClientRect(getDocumentRect(getDocumentElement(element)));\n} // A \"clipping parent\" is an overflowable container with the characteristic of\n// clipping (or hiding) overflowing elements with a position different from\n// `initial`\n\n\nfunction getClippingParents(element) {\n var clippingParents = listScrollParents(getParentNode(element));\n var canEscapeClipping = ['absolute', 'fixed'].indexOf(getComputedStyle(element).position) >= 0;\n var clipperElement = canEscapeClipping && isHTMLElement(element) ? getOffsetParent(element) : element;\n\n if (!isElement(clipperElement)) {\n return [];\n } // $FlowFixMe[incompatible-return]: https://github.com/facebook/flow/issues/1414\n\n\n return clippingParents.filter(function (clippingParent) {\n return isElement(clippingParent) && contains(clippingParent, clipperElement) && getNodeName(clippingParent) !== 'body';\n });\n} // Gets the maximum area that the element is visible in due to any number of\n// clipping parents\n\n\nexport default function getClippingRect(element, boundary, rootBoundary, strategy) {\n var mainClippingParents = boundary === 'clippingParents' ? getClippingParents(element) : [].concat(boundary);\n var clippingParents = [].concat(mainClippingParents, [rootBoundary]);\n var firstClippingParent = clippingParents[0];\n var clippingRect = clippingParents.reduce(function (accRect, clippingParent) {\n var rect = getClientRectFromMixedType(element, clippingParent, strategy);\n accRect.top = max(rect.top, accRect.top);\n accRect.right = min(rect.right, accRect.right);\n accRect.bottom = min(rect.bottom, accRect.bottom);\n accRect.left = max(rect.left, accRect.left);\n return accRect;\n }, getClientRectFromMixedType(element, firstClippingParent, strategy));\n clippingRect.width = clippingRect.right - clippingRect.left;\n clippingRect.height = clippingRect.bottom - clippingRect.top;\n clippingRect.x = clippingRect.left;\n clippingRect.y = clippingRect.top;\n return clippingRect;\n}","import getBasePlacement from \"./getBasePlacement.js\";\nimport getVariation from \"./getVariation.js\";\nimport getMainAxisFromPlacement from \"./getMainAxisFromPlacement.js\";\nimport { top, right, bottom, left, start, end } from \"../enums.js\";\nexport default function computeOffsets(_ref) {\n var reference = _ref.reference,\n element = _ref.element,\n placement = _ref.placement;\n var basePlacement = placement ? getBasePlacement(placement) : null;\n var variation = placement ? getVariation(placement) : null;\n var commonX = reference.x + reference.width / 2 - element.width / 2;\n var commonY = reference.y + reference.height / 2 - element.height / 2;\n var offsets;\n\n switch (basePlacement) {\n case top:\n offsets = {\n x: commonX,\n y: reference.y - element.height\n };\n break;\n\n case bottom:\n offsets = {\n x: commonX,\n y: reference.y + reference.height\n };\n break;\n\n case right:\n offsets = {\n x: reference.x + reference.width,\n y: commonY\n };\n break;\n\n case left:\n offsets = {\n x: reference.x - element.width,\n y: commonY\n };\n break;\n\n default:\n offsets = {\n x: reference.x,\n y: reference.y\n };\n }\n\n var mainAxis = basePlacement ? getMainAxisFromPlacement(basePlacement) : null;\n\n if (mainAxis != null) {\n var len = mainAxis === 'y' ? 'height' : 'width';\n\n switch (variation) {\n case start:\n offsets[mainAxis] = offsets[mainAxis] - (reference[len] / 2 - element[len] / 2);\n break;\n\n case end:\n offsets[mainAxis] = offsets[mainAxis] + (reference[len] / 2 - element[len] / 2);\n break;\n\n default:\n }\n }\n\n return offsets;\n}","import getClippingRect from \"../dom-utils/getClippingRect.js\";\nimport getDocumentElement from \"../dom-utils/getDocumentElement.js\";\nimport getBoundingClientRect from \"../dom-utils/getBoundingClientRect.js\";\nimport computeOffsets from \"./computeOffsets.js\";\nimport rectToClientRect from \"./rectToClientRect.js\";\nimport { clippingParents, reference, popper, bottom, top, right, basePlacements, viewport } from \"../enums.js\";\nimport { isElement } from \"../dom-utils/instanceOf.js\";\nimport mergePaddingObject from \"./mergePaddingObject.js\";\nimport expandToHashMap from \"./expandToHashMap.js\"; // eslint-disable-next-line import/no-unused-modules\n\nexport default function detectOverflow(state, options) {\n if (options === void 0) {\n options = {};\n }\n\n var _options = options,\n _options$placement = _options.placement,\n placement = _options$placement === void 0 ? state.placement : _options$placement,\n _options$strategy = _options.strategy,\n strategy = _options$strategy === void 0 ? state.strategy : _options$strategy,\n _options$boundary = _options.boundary,\n boundary = _options$boundary === void 0 ? clippingParents : _options$boundary,\n _options$rootBoundary = _options.rootBoundary,\n rootBoundary = _options$rootBoundary === void 0 ? viewport : _options$rootBoundary,\n _options$elementConte = _options.elementContext,\n elementContext = _options$elementConte === void 0 ? popper : _options$elementConte,\n _options$altBoundary = _options.altBoundary,\n altBoundary = _options$altBoundary === void 0 ? false : _options$altBoundary,\n _options$padding = _options.padding,\n padding = _options$padding === void 0 ? 0 : _options$padding;\n var paddingObject = mergePaddingObject(typeof padding !== 'number' ? padding : expandToHashMap(padding, basePlacements));\n var altContext = elementContext === popper ? reference : popper;\n var popperRect = state.rects.popper;\n var element = state.elements[altBoundary ? altContext : elementContext];\n var clippingClientRect = getClippingRect(isElement(element) ? element : element.contextElement || getDocumentElement(state.elements.popper), boundary, rootBoundary, strategy);\n var referenceClientRect = getBoundingClientRect(state.elements.reference);\n var popperOffsets = computeOffsets({\n reference: referenceClientRect,\n element: popperRect,\n strategy: 'absolute',\n placement: placement\n });\n var popperClientRect = rectToClientRect(Object.assign({}, popperRect, popperOffsets));\n var elementClientRect = elementContext === popper ? popperClientRect : referenceClientRect; // positive = overflowing the clipping rect\n // 0 or negative = within the clipping rect\n\n var overflowOffsets = {\n top: clippingClientRect.top - elementClientRect.top + paddingObject.top,\n bottom: elementClientRect.bottom - clippingClientRect.bottom + paddingObject.bottom,\n left: clippingClientRect.left - elementClientRect.left + paddingObject.left,\n right: elementClientRect.right - clippingClientRect.right + paddingObject.right\n };\n var offsetData = state.modifiersData.offset; // Offsets can be applied only to the popper element\n\n if (elementContext === popper && offsetData) {\n var offset = offsetData[placement];\n Object.keys(overflowOffsets).forEach(function (key) {\n var multiply = [right, bottom].indexOf(key) >= 0 ? 1 : -1;\n var axis = [top, bottom].indexOf(key) >= 0 ? 'y' : 'x';\n overflowOffsets[key] += offset[axis] * multiply;\n });\n }\n\n return overflowOffsets;\n}","import getVariation from \"./getVariation.js\";\nimport { variationPlacements, basePlacements, placements as allPlacements } from \"../enums.js\";\nimport detectOverflow from \"./detectOverflow.js\";\nimport getBasePlacement from \"./getBasePlacement.js\";\nexport default function computeAutoPlacement(state, options) {\n if (options === void 0) {\n options = {};\n }\n\n var _options = options,\n placement = _options.placement,\n boundary = _options.boundary,\n rootBoundary = _options.rootBoundary,\n padding = _options.padding,\n flipVariations = _options.flipVariations,\n _options$allowedAutoP = _options.allowedAutoPlacements,\n allowedAutoPlacements = _options$allowedAutoP === void 0 ? allPlacements : _options$allowedAutoP;\n var variation = getVariation(placement);\n var placements = variation ? flipVariations ? variationPlacements : variationPlacements.filter(function (placement) {\n return getVariation(placement) === variation;\n }) : basePlacements;\n var allowedPlacements = placements.filter(function (placement) {\n return allowedAutoPlacements.indexOf(placement) >= 0;\n });\n\n if (allowedPlacements.length === 0) {\n allowedPlacements = placements;\n } // $FlowFixMe[incompatible-type]: Flow seems to have problems with two array unions...\n\n\n var overflows = allowedPlacements.reduce(function (acc, placement) {\n acc[placement] = detectOverflow(state, {\n placement: placement,\n boundary: boundary,\n rootBoundary: rootBoundary,\n padding: padding\n })[getBasePlacement(placement)];\n return acc;\n }, {});\n return Object.keys(overflows).sort(function (a, b) {\n return overflows[a] - overflows[b];\n });\n}","import getOppositePlacement from \"../utils/getOppositePlacement.js\";\nimport getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getOppositeVariationPlacement from \"../utils/getOppositeVariationPlacement.js\";\nimport detectOverflow from \"../utils/detectOverflow.js\";\nimport computeAutoPlacement from \"../utils/computeAutoPlacement.js\";\nimport { bottom, top, start, right, left, auto } from \"../enums.js\";\nimport getVariation from \"../utils/getVariation.js\"; // eslint-disable-next-line import/no-unused-modules\n\nfunction getExpandedFallbackPlacements(placement) {\n if (getBasePlacement(placement) === auto) {\n return [];\n }\n\n var oppositePlacement = getOppositePlacement(placement);\n return [getOppositeVariationPlacement(placement), oppositePlacement, getOppositeVariationPlacement(oppositePlacement)];\n}\n\nfunction flip(_ref) {\n var state = _ref.state,\n options = _ref.options,\n name = _ref.name;\n\n if (state.modifiersData[name]._skip) {\n return;\n }\n\n var _options$mainAxis = options.mainAxis,\n checkMainAxis = _options$mainAxis === void 0 ? true : _options$mainAxis,\n _options$altAxis = options.altAxis,\n checkAltAxis = _options$altAxis === void 0 ? true : _options$altAxis,\n specifiedFallbackPlacements = options.fallbackPlacements,\n padding = options.padding,\n boundary = options.boundary,\n rootBoundary = options.rootBoundary,\n altBoundary = options.altBoundary,\n _options$flipVariatio = options.flipVariations,\n flipVariations = _options$flipVariatio === void 0 ? true : _options$flipVariatio,\n allowedAutoPlacements = options.allowedAutoPlacements;\n var preferredPlacement = state.options.placement;\n var basePlacement = getBasePlacement(preferredPlacement);\n var isBasePlacement = basePlacement === preferredPlacement;\n var fallbackPlacements = specifiedFallbackPlacements || (isBasePlacement || !flipVariations ? [getOppositePlacement(preferredPlacement)] : getExpandedFallbackPlacements(preferredPlacement));\n var placements = [preferredPlacement].concat(fallbackPlacements).reduce(function (acc, placement) {\n return acc.concat(getBasePlacement(placement) === auto ? computeAutoPlacement(state, {\n placement: placement,\n boundary: boundary,\n rootBoundary: rootBoundary,\n padding: padding,\n flipVariations: flipVariations,\n allowedAutoPlacements: allowedAutoPlacements\n }) : placement);\n }, []);\n var referenceRect = state.rects.reference;\n var popperRect = state.rects.popper;\n var checksMap = new Map();\n var makeFallbackChecks = true;\n var firstFittingPlacement = placements[0];\n\n for (var i = 0; i < placements.length; i++) {\n var placement = placements[i];\n\n var _basePlacement = getBasePlacement(placement);\n\n var isStartVariation = getVariation(placement) === start;\n var isVertical = [top, bottom].indexOf(_basePlacement) >= 0;\n var len = isVertical ? 'width' : 'height';\n var overflow = detectOverflow(state, {\n placement: placement,\n boundary: boundary,\n rootBoundary: rootBoundary,\n altBoundary: altBoundary,\n padding: padding\n });\n var mainVariationSide = isVertical ? isStartVariation ? right : left : isStartVariation ? bottom : top;\n\n if (referenceRect[len] > popperRect[len]) {\n mainVariationSide = getOppositePlacement(mainVariationSide);\n }\n\n var altVariationSide = getOppositePlacement(mainVariationSide);\n var checks = [];\n\n if (checkMainAxis) {\n checks.push(overflow[_basePlacement] <= 0);\n }\n\n if (checkAltAxis) {\n checks.push(overflow[mainVariationSide] <= 0, overflow[altVariationSide] <= 0);\n }\n\n if (checks.every(function (check) {\n return check;\n })) {\n firstFittingPlacement = placement;\n makeFallbackChecks = false;\n break;\n }\n\n checksMap.set(placement, checks);\n }\n\n if (makeFallbackChecks) {\n // `2` may be desired in some cases – research later\n var numberOfChecks = flipVariations ? 3 : 1;\n\n var _loop = function _loop(_i) {\n var fittingPlacement = placements.find(function (placement) {\n var checks = checksMap.get(placement);\n\n if (checks) {\n return checks.slice(0, _i).every(function (check) {\n return check;\n });\n }\n });\n\n if (fittingPlacement) {\n firstFittingPlacement = fittingPlacement;\n return \"break\";\n }\n };\n\n for (var _i = numberOfChecks; _i > 0; _i--) {\n var _ret = _loop(_i);\n\n if (_ret === \"break\") break;\n }\n }\n\n if (state.placement !== firstFittingPlacement) {\n state.modifiersData[name]._skip = true;\n state.placement = firstFittingPlacement;\n state.reset = true;\n }\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'flip',\n enabled: true,\n phase: 'main',\n fn: flip,\n requiresIfExists: ['offset'],\n data: {\n _skip: false\n }\n};","import { top, bottom, left, right } from \"../enums.js\";\nimport detectOverflow from \"../utils/detectOverflow.js\";\n\nfunction getSideOffsets(overflow, rect, preventedOffsets) {\n if (preventedOffsets === void 0) {\n preventedOffsets = {\n x: 0,\n y: 0\n };\n }\n\n return {\n top: overflow.top - rect.height - preventedOffsets.y,\n right: overflow.right - rect.width + preventedOffsets.x,\n bottom: overflow.bottom - rect.height + preventedOffsets.y,\n left: overflow.left - rect.width - preventedOffsets.x\n };\n}\n\nfunction isAnySideFullyClipped(overflow) {\n return [top, right, bottom, left].some(function (side) {\n return overflow[side] >= 0;\n });\n}\n\nfunction hide(_ref) {\n var state = _ref.state,\n name = _ref.name;\n var referenceRect = state.rects.reference;\n var popperRect = state.rects.popper;\n var preventedOffsets = state.modifiersData.preventOverflow;\n var referenceOverflow = detectOverflow(state, {\n elementContext: 'reference'\n });\n var popperAltOverflow = detectOverflow(state, {\n altBoundary: true\n });\n var referenceClippingOffsets = getSideOffsets(referenceOverflow, referenceRect);\n var popperEscapeOffsets = getSideOffsets(popperAltOverflow, popperRect, preventedOffsets);\n var isReferenceHidden = isAnySideFullyClipped(referenceClippingOffsets);\n var hasPopperEscaped = isAnySideFullyClipped(popperEscapeOffsets);\n state.modifiersData[name] = {\n referenceClippingOffsets: referenceClippingOffsets,\n popperEscapeOffsets: popperEscapeOffsets,\n isReferenceHidden: isReferenceHidden,\n hasPopperEscaped: hasPopperEscaped\n };\n state.attributes.popper = Object.assign({}, state.attributes.popper, {\n 'data-popper-reference-hidden': isReferenceHidden,\n 'data-popper-escaped': hasPopperEscaped\n });\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'hide',\n enabled: true,\n phase: 'main',\n requiresIfExists: ['preventOverflow'],\n fn: hide\n};","import getBasePlacement from \"../utils/getBasePlacement.js\";\nimport { top, left, right, placements } from \"../enums.js\"; // eslint-disable-next-line import/no-unused-modules\n\nexport function distanceAndSkiddingToXY(placement, rects, offset) {\n var basePlacement = getBasePlacement(placement);\n var invertDistance = [left, top].indexOf(basePlacement) >= 0 ? -1 : 1;\n\n var _ref = typeof offset === 'function' ? offset(Object.assign({}, rects, {\n placement: placement\n })) : offset,\n skidding = _ref[0],\n distance = _ref[1];\n\n skidding = skidding || 0;\n distance = (distance || 0) * invertDistance;\n return [left, right].indexOf(basePlacement) >= 0 ? {\n x: distance,\n y: skidding\n } : {\n x: skidding,\n y: distance\n };\n}\n\nfunction offset(_ref2) {\n var state = _ref2.state,\n options = _ref2.options,\n name = _ref2.name;\n var _options$offset = options.offset,\n offset = _options$offset === void 0 ? [0, 0] : _options$offset;\n var data = placements.reduce(function (acc, placement) {\n acc[placement] = distanceAndSkiddingToXY(placement, state.rects, offset);\n return acc;\n }, {});\n var _data$state$placement = data[state.placement],\n x = _data$state$placement.x,\n y = _data$state$placement.y;\n\n if (state.modifiersData.popperOffsets != null) {\n state.modifiersData.popperOffsets.x += x;\n state.modifiersData.popperOffsets.y += y;\n }\n\n state.modifiersData[name] = data;\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'offset',\n enabled: true,\n phase: 'main',\n requires: ['popperOffsets'],\n fn: offset\n};","import computeOffsets from \"../utils/computeOffsets.js\";\n\nfunction popperOffsets(_ref) {\n var state = _ref.state,\n name = _ref.name;\n // Offsets are the actual position the popper needs to have to be\n // properly positioned near its reference element\n // This is the most basic placement, and will be adjusted by\n // the modifiers in the next step\n state.modifiersData[name] = computeOffsets({\n reference: state.rects.reference,\n element: state.rects.popper,\n strategy: 'absolute',\n placement: state.placement\n });\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'popperOffsets',\n enabled: true,\n phase: 'read',\n fn: popperOffsets,\n data: {}\n};","export default function getAltAxis(axis) {\n return axis === 'x' ? 'y' : 'x';\n}","import { top, left, right, bottom, start } from \"../enums.js\";\nimport getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getMainAxisFromPlacement from \"../utils/getMainAxisFromPlacement.js\";\nimport getAltAxis from \"../utils/getAltAxis.js\";\nimport { within, withinMaxClamp } from \"../utils/within.js\";\nimport getLayoutRect from \"../dom-utils/getLayoutRect.js\";\nimport getOffsetParent from \"../dom-utils/getOffsetParent.js\";\nimport detectOverflow from \"../utils/detectOverflow.js\";\nimport getVariation from \"../utils/getVariation.js\";\nimport getFreshSideObject from \"../utils/getFreshSideObject.js\";\nimport { min as mathMin, max as mathMax } from \"../utils/math.js\";\n\nfunction preventOverflow(_ref) {\n var state = _ref.state,\n options = _ref.options,\n name = _ref.name;\n var _options$mainAxis = options.mainAxis,\n checkMainAxis = _options$mainAxis === void 0 ? true : _options$mainAxis,\n _options$altAxis = options.altAxis,\n checkAltAxis = _options$altAxis === void 0 ? false : _options$altAxis,\n boundary = options.boundary,\n rootBoundary = options.rootBoundary,\n altBoundary = options.altBoundary,\n padding = options.padding,\n _options$tether = options.tether,\n tether = _options$tether === void 0 ? true : _options$tether,\n _options$tetherOffset = options.tetherOffset,\n tetherOffset = _options$tetherOffset === void 0 ? 0 : _options$tetherOffset;\n var overflow = detectOverflow(state, {\n boundary: boundary,\n rootBoundary: rootBoundary,\n padding: padding,\n altBoundary: altBoundary\n });\n var basePlacement = getBasePlacement(state.placement);\n var variation = getVariation(state.placement);\n var isBasePlacement = !variation;\n var mainAxis = getMainAxisFromPlacement(basePlacement);\n var altAxis = getAltAxis(mainAxis);\n var popperOffsets = state.modifiersData.popperOffsets;\n var referenceRect = state.rects.reference;\n var popperRect = state.rects.popper;\n var tetherOffsetValue = typeof tetherOffset === 'function' ? tetherOffset(Object.assign({}, state.rects, {\n placement: state.placement\n })) : tetherOffset;\n var normalizedTetherOffsetValue = typeof tetherOffsetValue === 'number' ? {\n mainAxis: tetherOffsetValue,\n altAxis: tetherOffsetValue\n } : Object.assign({\n mainAxis: 0,\n altAxis: 0\n }, tetherOffsetValue);\n var offsetModifierState = state.modifiersData.offset ? state.modifiersData.offset[state.placement] : null;\n var data = {\n x: 0,\n y: 0\n };\n\n if (!popperOffsets) {\n return;\n }\n\n if (checkMainAxis) {\n var _offsetModifierState$;\n\n var mainSide = mainAxis === 'y' ? top : left;\n var altSide = mainAxis === 'y' ? bottom : right;\n var len = mainAxis === 'y' ? 'height' : 'width';\n var offset = popperOffsets[mainAxis];\n var min = offset + overflow[mainSide];\n var max = offset - overflow[altSide];\n var additive = tether ? -popperRect[len] / 2 : 0;\n var minLen = variation === start ? referenceRect[len] : popperRect[len];\n var maxLen = variation === start ? -popperRect[len] : -referenceRect[len]; // We need to include the arrow in the calculation so the arrow doesn't go\n // outside the reference bounds\n\n var arrowElement = state.elements.arrow;\n var arrowRect = tether && arrowElement ? getLayoutRect(arrowElement) : {\n width: 0,\n height: 0\n };\n var arrowPaddingObject = state.modifiersData['arrow#persistent'] ? state.modifiersData['arrow#persistent'].padding : getFreshSideObject();\n var arrowPaddingMin = arrowPaddingObject[mainSide];\n var arrowPaddingMax = arrowPaddingObject[altSide]; // If the reference length is smaller than the arrow length, we don't want\n // to include its full size in the calculation. If the reference is small\n // and near the edge of a boundary, the popper can overflow even if the\n // reference is not overflowing as well (e.g. virtual elements with no\n // width or height)\n\n var arrowLen = within(0, referenceRect[len], arrowRect[len]);\n var minOffset = isBasePlacement ? referenceRect[len] / 2 - additive - arrowLen - arrowPaddingMin - normalizedTetherOffsetValue.mainAxis : minLen - arrowLen - arrowPaddingMin - normalizedTetherOffsetValue.mainAxis;\n var maxOffset = isBasePlacement ? -referenceRect[len] / 2 + additive + arrowLen + arrowPaddingMax + normalizedTetherOffsetValue.mainAxis : maxLen + arrowLen + arrowPaddingMax + normalizedTetherOffsetValue.mainAxis;\n var arrowOffsetParent = state.elements.arrow && getOffsetParent(state.elements.arrow);\n var clientOffset = arrowOffsetParent ? mainAxis === 'y' ? arrowOffsetParent.clientTop || 0 : arrowOffsetParent.clientLeft || 0 : 0;\n var offsetModifierValue = (_offsetModifierState$ = offsetModifierState == null ? void 0 : offsetModifierState[mainAxis]) != null ? _offsetModifierState$ : 0;\n var tetherMin = offset + minOffset - offsetModifierValue - clientOffset;\n var tetherMax = offset + maxOffset - offsetModifierValue;\n var preventedOffset = within(tether ? mathMin(min, tetherMin) : min, offset, tether ? mathMax(max, tetherMax) : max);\n popperOffsets[mainAxis] = preventedOffset;\n data[mainAxis] = preventedOffset - offset;\n }\n\n if (checkAltAxis) {\n var _offsetModifierState$2;\n\n var _mainSide = mainAxis === 'x' ? top : left;\n\n var _altSide = mainAxis === 'x' ? bottom : right;\n\n var _offset = popperOffsets[altAxis];\n\n var _len = altAxis === 'y' ? 'height' : 'width';\n\n var _min = _offset + overflow[_mainSide];\n\n var _max = _offset - overflow[_altSide];\n\n var isOriginSide = [top, left].indexOf(basePlacement) !== -1;\n\n var _offsetModifierValue = (_offsetModifierState$2 = offsetModifierState == null ? void 0 : offsetModifierState[altAxis]) != null ? _offsetModifierState$2 : 0;\n\n var _tetherMin = isOriginSide ? _min : _offset - referenceRect[_len] - popperRect[_len] - _offsetModifierValue + normalizedTetherOffsetValue.altAxis;\n\n var _tetherMax = isOriginSide ? _offset + referenceRect[_len] + popperRect[_len] - _offsetModifierValue - normalizedTetherOffsetValue.altAxis : _max;\n\n var _preventedOffset = tether && isOriginSide ? withinMaxClamp(_tetherMin, _offset, _tetherMax) : within(tether ? _tetherMin : _min, _offset, tether ? _tetherMax : _max);\n\n popperOffsets[altAxis] = _preventedOffset;\n data[altAxis] = _preventedOffset - _offset;\n }\n\n state.modifiersData[name] = data;\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'preventOverflow',\n enabled: true,\n phase: 'main',\n fn: preventOverflow,\n requiresIfExists: ['offset']\n};","export default function getHTMLElementScroll(element) {\n return {\n scrollLeft: element.scrollLeft,\n scrollTop: element.scrollTop\n };\n}","import getWindowScroll from \"./getWindowScroll.js\";\nimport getWindow from \"./getWindow.js\";\nimport { isHTMLElement } from \"./instanceOf.js\";\nimport getHTMLElementScroll from \"./getHTMLElementScroll.js\";\nexport default function getNodeScroll(node) {\n if (node === getWindow(node) || !isHTMLElement(node)) {\n return getWindowScroll(node);\n } else {\n return getHTMLElementScroll(node);\n }\n}","import getBoundingClientRect from \"./getBoundingClientRect.js\";\nimport getNodeScroll from \"./getNodeScroll.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport { isHTMLElement } from \"./instanceOf.js\";\nimport getWindowScrollBarX from \"./getWindowScrollBarX.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport isScrollParent from \"./isScrollParent.js\";\nimport { round } from \"../utils/math.js\";\n\nfunction isElementScaled(element) {\n var rect = element.getBoundingClientRect();\n var scaleX = round(rect.width) / element.offsetWidth || 1;\n var scaleY = round(rect.height) / element.offsetHeight || 1;\n return scaleX !== 1 || scaleY !== 1;\n} // Returns the composite rect of an element relative to its offsetParent.\n// Composite means it takes into account transforms as well as layout.\n\n\nexport default function getCompositeRect(elementOrVirtualElement, offsetParent, isFixed) {\n if (isFixed === void 0) {\n isFixed = false;\n }\n\n var isOffsetParentAnElement = isHTMLElement(offsetParent);\n var offsetParentIsScaled = isHTMLElement(offsetParent) && isElementScaled(offsetParent);\n var documentElement = getDocumentElement(offsetParent);\n var rect = getBoundingClientRect(elementOrVirtualElement, offsetParentIsScaled, isFixed);\n var scroll = {\n scrollLeft: 0,\n scrollTop: 0\n };\n var offsets = {\n x: 0,\n y: 0\n };\n\n if (isOffsetParentAnElement || !isOffsetParentAnElement && !isFixed) {\n if (getNodeName(offsetParent) !== 'body' || // https://github.com/popperjs/popper-core/issues/1078\n isScrollParent(documentElement)) {\n scroll = getNodeScroll(offsetParent);\n }\n\n if (isHTMLElement(offsetParent)) {\n offsets = getBoundingClientRect(offsetParent, true);\n offsets.x += offsetParent.clientLeft;\n offsets.y += offsetParent.clientTop;\n } else if (documentElement) {\n offsets.x = getWindowScrollBarX(documentElement);\n }\n }\n\n return {\n x: rect.left + scroll.scrollLeft - offsets.x,\n y: rect.top + scroll.scrollTop - offsets.y,\n width: rect.width,\n height: rect.height\n };\n}","import { modifierPhases } from \"../enums.js\"; // source: https://stackoverflow.com/questions/49875255\n\nfunction order(modifiers) {\n var map = new Map();\n var visited = new Set();\n var result = [];\n modifiers.forEach(function (modifier) {\n map.set(modifier.name, modifier);\n }); // On visiting object, check for its dependencies and visit them recursively\n\n function sort(modifier) {\n visited.add(modifier.name);\n var requires = [].concat(modifier.requires || [], modifier.requiresIfExists || []);\n requires.forEach(function (dep) {\n if (!visited.has(dep)) {\n var depModifier = map.get(dep);\n\n if (depModifier) {\n sort(depModifier);\n }\n }\n });\n result.push(modifier);\n }\n\n modifiers.forEach(function (modifier) {\n if (!visited.has(modifier.name)) {\n // check for visited object\n sort(modifier);\n }\n });\n return result;\n}\n\nexport default function orderModifiers(modifiers) {\n // order based on dependencies\n var orderedModifiers = order(modifiers); // order based on phase\n\n return modifierPhases.reduce(function (acc, phase) {\n return acc.concat(orderedModifiers.filter(function (modifier) {\n return modifier.phase === phase;\n }));\n }, []);\n}","export default function debounce(fn) {\n var pending;\n return function () {\n if (!pending) {\n pending = new Promise(function (resolve) {\n Promise.resolve().then(function () {\n pending = undefined;\n resolve(fn());\n });\n });\n }\n\n return pending;\n };\n}","export default function mergeByName(modifiers) {\n var merged = modifiers.reduce(function (merged, current) {\n var existing = merged[current.name];\n merged[current.name] = existing ? Object.assign({}, existing, current, {\n options: Object.assign({}, existing.options, current.options),\n data: Object.assign({}, existing.data, current.data)\n }) : current;\n return merged;\n }, {}); // IE11 does not support Object.values\n\n return Object.keys(merged).map(function (key) {\n return merged[key];\n });\n}","import getCompositeRect from \"./dom-utils/getCompositeRect.js\";\nimport getLayoutRect from \"./dom-utils/getLayoutRect.js\";\nimport listScrollParents from \"./dom-utils/listScrollParents.js\";\nimport getOffsetParent from \"./dom-utils/getOffsetParent.js\";\nimport orderModifiers from \"./utils/orderModifiers.js\";\nimport debounce from \"./utils/debounce.js\";\nimport mergeByName from \"./utils/mergeByName.js\";\nimport detectOverflow from \"./utils/detectOverflow.js\";\nimport { isElement } from \"./dom-utils/instanceOf.js\";\nvar DEFAULT_OPTIONS = {\n placement: 'bottom',\n modifiers: [],\n strategy: 'absolute'\n};\n\nfunction areValidElements() {\n for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {\n args[_key] = arguments[_key];\n }\n\n return !args.some(function (element) {\n return !(element && typeof element.getBoundingClientRect === 'function');\n });\n}\n\nexport function popperGenerator(generatorOptions) {\n if (generatorOptions === void 0) {\n generatorOptions = {};\n }\n\n var _generatorOptions = generatorOptions,\n _generatorOptions$def = _generatorOptions.defaultModifiers,\n defaultModifiers = _generatorOptions$def === void 0 ? [] : _generatorOptions$def,\n _generatorOptions$def2 = _generatorOptions.defaultOptions,\n defaultOptions = _generatorOptions$def2 === void 0 ? DEFAULT_OPTIONS : _generatorOptions$def2;\n return function createPopper(reference, popper, options) {\n if (options === void 0) {\n options = defaultOptions;\n }\n\n var state = {\n placement: 'bottom',\n orderedModifiers: [],\n options: Object.assign({}, DEFAULT_OPTIONS, defaultOptions),\n modifiersData: {},\n elements: {\n reference: reference,\n popper: popper\n },\n attributes: {},\n styles: {}\n };\n var effectCleanupFns = [];\n var isDestroyed = false;\n var instance = {\n state: state,\n setOptions: function setOptions(setOptionsAction) {\n var options = typeof setOptionsAction === 'function' ? setOptionsAction(state.options) : setOptionsAction;\n cleanupModifierEffects();\n state.options = Object.assign({}, defaultOptions, state.options, options);\n state.scrollParents = {\n reference: isElement(reference) ? listScrollParents(reference) : reference.contextElement ? listScrollParents(reference.contextElement) : [],\n popper: listScrollParents(popper)\n }; // Orders the modifiers based on their dependencies and `phase`\n // properties\n\n var orderedModifiers = orderModifiers(mergeByName([].concat(defaultModifiers, state.options.modifiers))); // Strip out disabled modifiers\n\n state.orderedModifiers = orderedModifiers.filter(function (m) {\n return m.enabled;\n });\n runModifierEffects();\n return instance.update();\n },\n // Sync update – it will always be executed, even if not necessary. This\n // is useful for low frequency updates where sync behavior simplifies the\n // logic.\n // For high frequency updates (e.g. `resize` and `scroll` events), always\n // prefer the async Popper#update method\n forceUpdate: function forceUpdate() {\n if (isDestroyed) {\n return;\n }\n\n var _state$elements = state.elements,\n reference = _state$elements.reference,\n popper = _state$elements.popper; // Don't proceed if `reference` or `popper` are not valid elements\n // anymore\n\n if (!areValidElements(reference, popper)) {\n return;\n } // Store the reference and popper rects to be read by modifiers\n\n\n state.rects = {\n reference: getCompositeRect(reference, getOffsetParent(popper), state.options.strategy === 'fixed'),\n popper: getLayoutRect(popper)\n }; // Modifiers have the ability to reset the current update cycle. The\n // most common use case for this is the `flip` modifier changing the\n // placement, which then needs to re-run all the modifiers, because the\n // logic was previously ran for the previous placement and is therefore\n // stale/incorrect\n\n state.reset = false;\n state.placement = state.options.placement; // On each update cycle, the `modifiersData` property for each modifier\n // is filled with the initial data specified by the modifier. This means\n // it doesn't persist and is fresh on each update.\n // To ensure persistent data, use `${name}#persistent`\n\n state.orderedModifiers.forEach(function (modifier) {\n return state.modifiersData[modifier.name] = Object.assign({}, modifier.data);\n });\n\n for (var index = 0; index < state.orderedModifiers.length; index++) {\n if (state.reset === true) {\n state.reset = false;\n index = -1;\n continue;\n }\n\n var _state$orderedModifie = state.orderedModifiers[index],\n fn = _state$orderedModifie.fn,\n _state$orderedModifie2 = _state$orderedModifie.options,\n _options = _state$orderedModifie2 === void 0 ? {} : _state$orderedModifie2,\n name = _state$orderedModifie.name;\n\n if (typeof fn === 'function') {\n state = fn({\n state: state,\n options: _options,\n name: name,\n instance: instance\n }) || state;\n }\n }\n },\n // Async and optimistically optimized update – it will not be executed if\n // not necessary (debounced to run at most once-per-tick)\n update: debounce(function () {\n return new Promise(function (resolve) {\n instance.forceUpdate();\n resolve(state);\n });\n }),\n destroy: function destroy() {\n cleanupModifierEffects();\n isDestroyed = true;\n }\n };\n\n if (!areValidElements(reference, popper)) {\n return instance;\n }\n\n instance.setOptions(options).then(function (state) {\n if (!isDestroyed && options.onFirstUpdate) {\n options.onFirstUpdate(state);\n }\n }); // Modifiers have the ability to execute arbitrary code before the first\n // update cycle runs. They will be executed in the same order as the update\n // cycle. This is useful when a modifier adds some persistent data that\n // other modifiers need to use, but the modifier is run after the dependent\n // one.\n\n function runModifierEffects() {\n state.orderedModifiers.forEach(function (_ref) {\n var name = _ref.name,\n _ref$options = _ref.options,\n options = _ref$options === void 0 ? {} : _ref$options,\n effect = _ref.effect;\n\n if (typeof effect === 'function') {\n var cleanupFn = effect({\n state: state,\n name: name,\n instance: instance,\n options: options\n });\n\n var noopFn = function noopFn() {};\n\n effectCleanupFns.push(cleanupFn || noopFn);\n }\n });\n }\n\n function cleanupModifierEffects() {\n effectCleanupFns.forEach(function (fn) {\n return fn();\n });\n effectCleanupFns = [];\n }\n\n return instance;\n };\n}\nexport var createPopper = /*#__PURE__*/popperGenerator(); // eslint-disable-next-line import/no-unused-modules\n\nexport { detectOverflow };","import { popperGenerator, detectOverflow } from \"./createPopper.js\";\nimport eventListeners from \"./modifiers/eventListeners.js\";\nimport popperOffsets from \"./modifiers/popperOffsets.js\";\nimport computeStyles from \"./modifiers/computeStyles.js\";\nimport applyStyles from \"./modifiers/applyStyles.js\";\nimport offset from \"./modifiers/offset.js\";\nimport flip from \"./modifiers/flip.js\";\nimport preventOverflow from \"./modifiers/preventOverflow.js\";\nimport arrow from \"./modifiers/arrow.js\";\nimport hide from \"./modifiers/hide.js\";\nvar defaultModifiers = [eventListeners, popperOffsets, computeStyles, applyStyles, offset, flip, preventOverflow, arrow, hide];\nvar createPopper = /*#__PURE__*/popperGenerator({\n defaultModifiers: defaultModifiers\n}); // eslint-disable-next-line import/no-unused-modules\n\nexport { createPopper, popperGenerator, defaultModifiers, detectOverflow }; // eslint-disable-next-line import/no-unused-modules\n\nexport { createPopper as createPopperLite } from \"./popper-lite.js\"; // eslint-disable-next-line import/no-unused-modules\n\nexport * from \"./modifiers/index.js\";","import { generateUtilityClass } from '../generateUtilityClass';\nimport { generateUtilityClasses } from '../generateUtilityClasses';\nconst COMPONENT_NAME = 'Popper';\nexport function getPopperUtilityClass(slot) {\n return generateUtilityClass(COMPONENT_NAME, slot);\n}\nexport const popperClasses = generateUtilityClasses(COMPONENT_NAME, ['root']);","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"anchorEl\", \"children\", \"direction\", \"disablePortal\", \"modifiers\", \"open\", \"placement\", \"popperOptions\", \"popperRef\", \"slotProps\", \"slots\", \"TransitionProps\", \"ownerState\"],\n _excluded2 = [\"anchorEl\", \"children\", \"container\", \"direction\", \"disablePortal\", \"keepMounted\", \"modifiers\", \"open\", \"placement\", \"popperOptions\", \"popperRef\", \"style\", \"transition\", \"slotProps\", \"slots\"];\nimport * as React from 'react';\nimport { chainPropTypes, HTMLElementType, refType, unstable_ownerDocument as ownerDocument, unstable_useEnhancedEffect as useEnhancedEffect, unstable_useForkRef as useForkRef } from '@mui/utils';\nimport { createPopper } from '@popperjs/core';\nimport PropTypes from 'prop-types';\nimport { unstable_composeClasses as composeClasses } from '../composeClasses';\nimport { Portal } from '../Portal';\nimport { getPopperUtilityClass } from './popperClasses';\nimport { useSlotProps } from '../utils';\nimport { useClassNamesOverride } from '../utils/ClassNameConfigurator';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nfunction flipPlacement(placement, direction) {\n if (direction === 'ltr') {\n return placement;\n }\n switch (placement) {\n case 'bottom-end':\n return 'bottom-start';\n case 'bottom-start':\n return 'bottom-end';\n case 'top-end':\n return 'top-start';\n case 'top-start':\n return 'top-end';\n default:\n return placement;\n }\n}\nfunction resolveAnchorEl(anchorEl) {\n return typeof anchorEl === 'function' ? anchorEl() : anchorEl;\n}\nfunction isHTMLElement(element) {\n return element.nodeType !== undefined;\n}\nfunction isVirtualElement(element) {\n return !isHTMLElement(element);\n}\nconst useUtilityClasses = () => {\n const slots = {\n root: ['root']\n };\n return composeClasses(slots, useClassNamesOverride(getPopperUtilityClass));\n};\nconst defaultPopperOptions = {};\nconst PopperTooltip = /*#__PURE__*/React.forwardRef(function PopperTooltip(props, forwardedRef) {\n var _slots$root;\n const {\n anchorEl,\n children,\n direction,\n disablePortal,\n modifiers,\n open,\n placement: initialPlacement,\n popperOptions,\n popperRef: popperRefProp,\n slotProps = {},\n slots = {},\n TransitionProps\n // @ts-ignore internal logic\n // prevent from spreading to DOM, it can come from the parent component e.g. Select.\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const tooltipRef = React.useRef(null);\n const ownRef = useForkRef(tooltipRef, forwardedRef);\n const popperRef = React.useRef(null);\n const handlePopperRef = useForkRef(popperRef, popperRefProp);\n const handlePopperRefRef = React.useRef(handlePopperRef);\n useEnhancedEffect(() => {\n handlePopperRefRef.current = handlePopperRef;\n }, [handlePopperRef]);\n React.useImperativeHandle(popperRefProp, () => popperRef.current, []);\n const rtlPlacement = flipPlacement(initialPlacement, direction);\n /**\n * placement initialized from prop but can change during lifetime if modifiers.flip.\n * modifiers.flip is essentially a flip for controlled/uncontrolled behavior\n */\n const [placement, setPlacement] = React.useState(rtlPlacement);\n const [resolvedAnchorElement, setResolvedAnchorElement] = React.useState(resolveAnchorEl(anchorEl));\n React.useEffect(() => {\n if (popperRef.current) {\n popperRef.current.forceUpdate();\n }\n });\n React.useEffect(() => {\n if (anchorEl) {\n setResolvedAnchorElement(resolveAnchorEl(anchorEl));\n }\n }, [anchorEl]);\n useEnhancedEffect(() => {\n if (!resolvedAnchorElement || !open) {\n return undefined;\n }\n const handlePopperUpdate = data => {\n setPlacement(data.placement);\n };\n if (process.env.NODE_ENV !== 'production') {\n if (resolvedAnchorElement && isHTMLElement(resolvedAnchorElement) && resolvedAnchorElement.nodeType === 1) {\n const box = resolvedAnchorElement.getBoundingClientRect();\n if (process.env.NODE_ENV !== 'test' && box.top === 0 && box.left === 0 && box.right === 0 && box.bottom === 0) {\n console.warn(['MUI: The `anchorEl` prop provided to the component is invalid.', 'The anchor element should be part of the document layout.', \"Make sure the element is present in the document or that it's not display none.\"].join('\\n'));\n }\n }\n }\n let popperModifiers = [{\n name: 'preventOverflow',\n options: {\n altBoundary: disablePortal\n }\n }, {\n name: 'flip',\n options: {\n altBoundary: disablePortal\n }\n }, {\n name: 'onUpdate',\n enabled: true,\n phase: 'afterWrite',\n fn: ({\n state\n }) => {\n handlePopperUpdate(state);\n }\n }];\n if (modifiers != null) {\n popperModifiers = popperModifiers.concat(modifiers);\n }\n if (popperOptions && popperOptions.modifiers != null) {\n popperModifiers = popperModifiers.concat(popperOptions.modifiers);\n }\n const popper = createPopper(resolvedAnchorElement, tooltipRef.current, _extends({\n placement: rtlPlacement\n }, popperOptions, {\n modifiers: popperModifiers\n }));\n handlePopperRefRef.current(popper);\n return () => {\n popper.destroy();\n handlePopperRefRef.current(null);\n };\n }, [resolvedAnchorElement, disablePortal, modifiers, open, popperOptions, rtlPlacement]);\n const childProps = {\n placement: placement\n };\n if (TransitionProps !== null) {\n childProps.TransitionProps = TransitionProps;\n }\n const classes = useUtilityClasses();\n const Root = (_slots$root = slots.root) != null ? _slots$root : 'div';\n const rootProps = useSlotProps({\n elementType: Root,\n externalSlotProps: slotProps.root,\n externalForwardedProps: other,\n additionalProps: {\n role: 'tooltip',\n ref: ownRef\n },\n ownerState: props,\n className: classes.root\n });\n return /*#__PURE__*/_jsx(Root, _extends({}, rootProps, {\n children: typeof children === 'function' ? children(childProps) : children\n }));\n});\n\n/**\n * Poppers rely on the 3rd party library [Popper.js](https://popper.js.org/docs/v2/) for positioning.\n *\n * Demos:\n *\n * - [Popper](https://mui.com/base-ui/react-popper/)\n *\n * API:\n *\n * - [Popper API](https://mui.com/base-ui/react-popper/components-api/#popper)\n */\nconst Popper = /*#__PURE__*/React.forwardRef(function Popper(props, forwardedRef) {\n const {\n anchorEl,\n children,\n container: containerProp,\n direction = 'ltr',\n disablePortal = false,\n keepMounted = false,\n modifiers,\n open,\n placement = 'bottom',\n popperOptions = defaultPopperOptions,\n popperRef,\n style,\n transition = false,\n slotProps = {},\n slots = {}\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded2);\n const [exited, setExited] = React.useState(true);\n const handleEnter = () => {\n setExited(false);\n };\n const handleExited = () => {\n setExited(true);\n };\n if (!keepMounted && !open && (!transition || exited)) {\n return null;\n }\n\n // If the container prop is provided, use that\n // If the anchorEl prop is provided, use its parent body element as the container\n // If neither are provided let the Modal take care of choosing the container\n let container;\n if (containerProp) {\n container = containerProp;\n } else if (anchorEl) {\n const resolvedAnchorEl = resolveAnchorEl(anchorEl);\n container = resolvedAnchorEl && isHTMLElement(resolvedAnchorEl) ? ownerDocument(resolvedAnchorEl).body : ownerDocument(null).body;\n }\n const display = !open && keepMounted && (!transition || exited) ? 'none' : undefined;\n const transitionProps = transition ? {\n in: open,\n onEnter: handleEnter,\n onExited: handleExited\n } : undefined;\n return /*#__PURE__*/_jsx(Portal, {\n disablePortal: disablePortal,\n container: container,\n children: /*#__PURE__*/_jsx(PopperTooltip, _extends({\n anchorEl: anchorEl,\n direction: direction,\n disablePortal: disablePortal,\n modifiers: modifiers,\n ref: forwardedRef,\n open: transition ? !exited : open,\n placement: placement,\n popperOptions: popperOptions,\n popperRef: popperRef,\n slotProps: slotProps,\n slots: slots\n }, other, {\n style: _extends({\n // Prevents scroll issue, waiting for Popper.js to add this style once initiated.\n position: 'fixed',\n // Fix Popper.js display issue\n top: 0,\n left: 0,\n display\n }, style),\n TransitionProps: transitionProps,\n children: children\n }))\n });\n});\nprocess.env.NODE_ENV !== \"production\" ? Popper.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * An HTML element, [virtualElement](https://popper.js.org/docs/v2/virtual-elements/),\n * or a function that returns either.\n * It's used to set the position of the popper.\n * The return value will passed as the reference object of the Popper instance.\n */\n anchorEl: chainPropTypes(PropTypes.oneOfType([HTMLElementType, PropTypes.object, PropTypes.func]), props => {\n if (props.open) {\n const resolvedAnchorEl = resolveAnchorEl(props.anchorEl);\n if (resolvedAnchorEl && isHTMLElement(resolvedAnchorEl) && resolvedAnchorEl.nodeType === 1) {\n const box = resolvedAnchorEl.getBoundingClientRect();\n if (process.env.NODE_ENV !== 'test' && box.top === 0 && box.left === 0 && box.right === 0 && box.bottom === 0) {\n return new Error(['MUI: The `anchorEl` prop provided to the component is invalid.', 'The anchor element should be part of the document layout.', \"Make sure the element is present in the document or that it's not display none.\"].join('\\n'));\n }\n } else if (!resolvedAnchorEl || typeof resolvedAnchorEl.getBoundingClientRect !== 'function' || isVirtualElement(resolvedAnchorEl) && resolvedAnchorEl.contextElement != null && resolvedAnchorEl.contextElement.nodeType !== 1) {\n return new Error(['MUI: The `anchorEl` prop provided to the component is invalid.', 'It should be an HTML element instance or a virtualElement ', '(https://popper.js.org/docs/v2/virtual-elements/).'].join('\\n'));\n }\n }\n return null;\n }),\n /**\n * Popper render function or node.\n */\n children: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.node, PropTypes.func]),\n /**\n * An HTML element or function that returns one.\n * The `container` will have the portal children appended to it.\n *\n * You can also provide a callback, which is called in a React layout effect.\n * This lets you set the container from a ref, and also makes server-side rendering possible.\n *\n * By default, it uses the body of the top-level document object,\n * so it's simply `document.body` most of the time.\n */\n container: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.func]),\n /**\n * Direction of the text.\n * @default 'ltr'\n */\n direction: PropTypes.oneOf(['ltr', 'rtl']),\n /**\n * The `children` will be under the DOM hierarchy of the parent component.\n * @default false\n */\n disablePortal: PropTypes.bool,\n /**\n * Always keep the children in the DOM.\n * This prop can be useful in SEO situation or\n * when you want to maximize the responsiveness of the Popper.\n * @default false\n */\n keepMounted: PropTypes.bool,\n /**\n * Popper.js is based on a \"plugin-like\" architecture,\n * most of its features are fully encapsulated \"modifiers\".\n *\n * A modifier is a function that is called each time Popper.js needs to\n * compute the position of the popper.\n * For this reason, modifiers should be very performant to avoid bottlenecks.\n * To learn how to create a modifier, [read the modifiers documentation](https://popper.js.org/docs/v2/modifiers/).\n */\n modifiers: PropTypes.arrayOf(PropTypes.shape({\n data: PropTypes.object,\n effect: PropTypes.func,\n enabled: PropTypes.bool,\n fn: PropTypes.func,\n name: PropTypes.any,\n options: PropTypes.object,\n phase: PropTypes.oneOf(['afterMain', 'afterRead', 'afterWrite', 'beforeMain', 'beforeRead', 'beforeWrite', 'main', 'read', 'write']),\n requires: PropTypes.arrayOf(PropTypes.string),\n requiresIfExists: PropTypes.arrayOf(PropTypes.string)\n })),\n /**\n * If `true`, the component is shown.\n */\n open: PropTypes.bool.isRequired,\n /**\n * Popper placement.\n * @default 'bottom'\n */\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n /**\n * Options provided to the [`Popper.js`](https://popper.js.org/docs/v2/constructors/#options) instance.\n * @default {}\n */\n popperOptions: PropTypes.shape({\n modifiers: PropTypes.array,\n onFirstUpdate: PropTypes.func,\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n strategy: PropTypes.oneOf(['absolute', 'fixed'])\n }),\n /**\n * A ref that points to the used popper instance.\n */\n popperRef: refType,\n /**\n * The props used for each slot inside the Popper.\n * @default {}\n */\n slotProps: PropTypes.shape({\n root: PropTypes.oneOfType([PropTypes.func, PropTypes.object])\n }),\n /**\n * The components used for each slot inside the Popper.\n * Either a string to use a HTML element or a component.\n * @default {}\n */\n slots: PropTypes.shape({\n root: PropTypes.elementType\n }),\n /**\n * Help supporting a react-transition-group/Transition component.\n * @default false\n */\n transition: PropTypes.bool\n} : void 0;\nexport { Popper };","'use client';\n\nimport * as React from 'react';\nimport { useTheme as useThemeSystem } from '@mui/system';\nimport defaultTheme from './defaultTheme';\nimport THEME_ID from './identifier';\nexport default function useTheme() {\n const theme = useThemeSystem(defaultTheme);\n if (process.env.NODE_ENV !== 'production') {\n // eslint-disable-next-line react-hooks/rules-of-hooks\n React.useDebugValue(theme);\n }\n return theme[THEME_ID] || theme;\n}","export default function _setPrototypeOf(o, p) {\n _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function _setPrototypeOf(o, p) {\n o.__proto__ = p;\n return o;\n };\n return _setPrototypeOf(o, p);\n}","import setPrototypeOf from \"./setPrototypeOf.js\";\nexport default function _inheritsLoose(subClass, superClass) {\n subClass.prototype = Object.create(superClass.prototype);\n subClass.prototype.constructor = subClass;\n setPrototypeOf(subClass, superClass);\n}","export default {\n disabled: false\n};","import PropTypes from 'prop-types';\nexport var timeoutsShape = process.env.NODE_ENV !== 'production' ? PropTypes.oneOfType([PropTypes.number, PropTypes.shape({\n enter: PropTypes.number,\n exit: PropTypes.number,\n appear: PropTypes.number\n}).isRequired]) : null;\nexport var classNamesShape = process.env.NODE_ENV !== 'production' ? PropTypes.oneOfType([PropTypes.string, PropTypes.shape({\n enter: PropTypes.string,\n exit: PropTypes.string,\n active: PropTypes.string\n}), PropTypes.shape({\n enter: PropTypes.string,\n enterDone: PropTypes.string,\n enterActive: PropTypes.string,\n exit: PropTypes.string,\n exitDone: PropTypes.string,\n exitActive: PropTypes.string\n})]) : null;","import React from 'react';\nexport default React.createContext(null);","export var forceReflow = function forceReflow(node) {\n return node.scrollTop;\n};","import _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _inheritsLoose from \"@babel/runtime/helpers/esm/inheritsLoose\";\nimport PropTypes from 'prop-types';\nimport React from 'react';\nimport ReactDOM from 'react-dom';\nimport config from './config';\nimport { timeoutsShape } from './utils/PropTypes';\nimport TransitionGroupContext from './TransitionGroupContext';\nimport { forceReflow } from './utils/reflow';\nexport var UNMOUNTED = 'unmounted';\nexport var EXITED = 'exited';\nexport var ENTERING = 'entering';\nexport var ENTERED = 'entered';\nexport var EXITING = 'exiting';\n/**\n * The Transition component lets you describe a transition from one component\n * state to another _over time_ with a simple declarative API. Most commonly\n * it's used to animate the mounting and unmounting of a component, but can also\n * be used to describe in-place transition states as well.\n *\n * ---\n *\n * **Note**: `Transition` is a platform-agnostic base component. If you're using\n * transitions in CSS, you'll probably want to use\n * [`CSSTransition`](https://reactcommunity.org/react-transition-group/css-transition)\n * instead. It inherits all the features of `Transition`, but contains\n * additional features necessary to play nice with CSS transitions (hence the\n * name of the component).\n *\n * ---\n *\n * By default the `Transition` component does not alter the behavior of the\n * component it renders, it only tracks \"enter\" and \"exit\" states for the\n * components. It's up to you to give meaning and effect to those states. For\n * example we can add styles to a component when it enters or exits:\n *\n * ```jsx\n * import { Transition } from 'react-transition-group';\n *\n * const duration = 300;\n *\n * const defaultStyle = {\n * transition: `opacity ${duration}ms ease-in-out`,\n * opacity: 0,\n * }\n *\n * const transitionStyles = {\n * entering: { opacity: 1 },\n * entered: { opacity: 1 },\n * exiting: { opacity: 0 },\n * exited: { opacity: 0 },\n * };\n *\n * const Fade = ({ in: inProp }) => (\n * \n * {state => (\n *
    \n * I'm a fade Transition!\n *
    \n * )}\n *
    \n * );\n * ```\n *\n * There are 4 main states a Transition can be in:\n * - `'entering'`\n * - `'entered'`\n * - `'exiting'`\n * - `'exited'`\n *\n * Transition state is toggled via the `in` prop. When `true` the component\n * begins the \"Enter\" stage. During this stage, the component will shift from\n * its current transition state, to `'entering'` for the duration of the\n * transition and then to the `'entered'` stage once it's complete. Let's take\n * the following example (we'll use the\n * [useState](https://reactjs.org/docs/hooks-reference.html#usestate) hook):\n *\n * ```jsx\n * function App() {\n * const [inProp, setInProp] = useState(false);\n * return (\n *
    \n * \n * {state => (\n * // ...\n * )}\n * \n * \n *
    \n * );\n * }\n * ```\n *\n * When the button is clicked the component will shift to the `'entering'` state\n * and stay there for 500ms (the value of `timeout`) before it finally switches\n * to `'entered'`.\n *\n * When `in` is `false` the same thing happens except the state moves from\n * `'exiting'` to `'exited'`.\n */\n\nvar Transition = /*#__PURE__*/function (_React$Component) {\n _inheritsLoose(Transition, _React$Component);\n\n function Transition(props, context) {\n var _this;\n\n _this = _React$Component.call(this, props, context) || this;\n var parentGroup = context; // In the context of a TransitionGroup all enters are really appears\n\n var appear = parentGroup && !parentGroup.isMounting ? props.enter : props.appear;\n var initialStatus;\n _this.appearStatus = null;\n\n if (props.in) {\n if (appear) {\n initialStatus = EXITED;\n _this.appearStatus = ENTERING;\n } else {\n initialStatus = ENTERED;\n }\n } else {\n if (props.unmountOnExit || props.mountOnEnter) {\n initialStatus = UNMOUNTED;\n } else {\n initialStatus = EXITED;\n }\n }\n\n _this.state = {\n status: initialStatus\n };\n _this.nextCallback = null;\n return _this;\n }\n\n Transition.getDerivedStateFromProps = function getDerivedStateFromProps(_ref, prevState) {\n var nextIn = _ref.in;\n\n if (nextIn && prevState.status === UNMOUNTED) {\n return {\n status: EXITED\n };\n }\n\n return null;\n } // getSnapshotBeforeUpdate(prevProps) {\n // let nextStatus = null\n // if (prevProps !== this.props) {\n // const { status } = this.state\n // if (this.props.in) {\n // if (status !== ENTERING && status !== ENTERED) {\n // nextStatus = ENTERING\n // }\n // } else {\n // if (status === ENTERING || status === ENTERED) {\n // nextStatus = EXITING\n // }\n // }\n // }\n // return { nextStatus }\n // }\n ;\n\n var _proto = Transition.prototype;\n\n _proto.componentDidMount = function componentDidMount() {\n this.updateStatus(true, this.appearStatus);\n };\n\n _proto.componentDidUpdate = function componentDidUpdate(prevProps) {\n var nextStatus = null;\n\n if (prevProps !== this.props) {\n var status = this.state.status;\n\n if (this.props.in) {\n if (status !== ENTERING && status !== ENTERED) {\n nextStatus = ENTERING;\n }\n } else {\n if (status === ENTERING || status === ENTERED) {\n nextStatus = EXITING;\n }\n }\n }\n\n this.updateStatus(false, nextStatus);\n };\n\n _proto.componentWillUnmount = function componentWillUnmount() {\n this.cancelNextCallback();\n };\n\n _proto.getTimeouts = function getTimeouts() {\n var timeout = this.props.timeout;\n var exit, enter, appear;\n exit = enter = appear = timeout;\n\n if (timeout != null && typeof timeout !== 'number') {\n exit = timeout.exit;\n enter = timeout.enter; // TODO: remove fallback for next major\n\n appear = timeout.appear !== undefined ? timeout.appear : enter;\n }\n\n return {\n exit: exit,\n enter: enter,\n appear: appear\n };\n };\n\n _proto.updateStatus = function updateStatus(mounting, nextStatus) {\n if (mounting === void 0) {\n mounting = false;\n }\n\n if (nextStatus !== null) {\n // nextStatus will always be ENTERING or EXITING.\n this.cancelNextCallback();\n\n if (nextStatus === ENTERING) {\n if (this.props.unmountOnExit || this.props.mountOnEnter) {\n var node = this.props.nodeRef ? this.props.nodeRef.current : ReactDOM.findDOMNode(this); // https://github.com/reactjs/react-transition-group/pull/749\n // With unmountOnExit or mountOnEnter, the enter animation should happen at the transition between `exited` and `entering`.\n // To make the animation happen, we have to separate each rendering and avoid being processed as batched.\n\n if (node) forceReflow(node);\n }\n\n this.performEnter(mounting);\n } else {\n this.performExit();\n }\n } else if (this.props.unmountOnExit && this.state.status === EXITED) {\n this.setState({\n status: UNMOUNTED\n });\n }\n };\n\n _proto.performEnter = function performEnter(mounting) {\n var _this2 = this;\n\n var enter = this.props.enter;\n var appearing = this.context ? this.context.isMounting : mounting;\n\n var _ref2 = this.props.nodeRef ? [appearing] : [ReactDOM.findDOMNode(this), appearing],\n maybeNode = _ref2[0],\n maybeAppearing = _ref2[1];\n\n var timeouts = this.getTimeouts();\n var enterTimeout = appearing ? timeouts.appear : timeouts.enter; // no enter animation skip right to ENTERED\n // if we are mounting and running this it means appear _must_ be set\n\n if (!mounting && !enter || config.disabled) {\n this.safeSetState({\n status: ENTERED\n }, function () {\n _this2.props.onEntered(maybeNode);\n });\n return;\n }\n\n this.props.onEnter(maybeNode, maybeAppearing);\n this.safeSetState({\n status: ENTERING\n }, function () {\n _this2.props.onEntering(maybeNode, maybeAppearing);\n\n _this2.onTransitionEnd(enterTimeout, function () {\n _this2.safeSetState({\n status: ENTERED\n }, function () {\n _this2.props.onEntered(maybeNode, maybeAppearing);\n });\n });\n });\n };\n\n _proto.performExit = function performExit() {\n var _this3 = this;\n\n var exit = this.props.exit;\n var timeouts = this.getTimeouts();\n var maybeNode = this.props.nodeRef ? undefined : ReactDOM.findDOMNode(this); // no exit animation skip right to EXITED\n\n if (!exit || config.disabled) {\n this.safeSetState({\n status: EXITED\n }, function () {\n _this3.props.onExited(maybeNode);\n });\n return;\n }\n\n this.props.onExit(maybeNode);\n this.safeSetState({\n status: EXITING\n }, function () {\n _this3.props.onExiting(maybeNode);\n\n _this3.onTransitionEnd(timeouts.exit, function () {\n _this3.safeSetState({\n status: EXITED\n }, function () {\n _this3.props.onExited(maybeNode);\n });\n });\n });\n };\n\n _proto.cancelNextCallback = function cancelNextCallback() {\n if (this.nextCallback !== null) {\n this.nextCallback.cancel();\n this.nextCallback = null;\n }\n };\n\n _proto.safeSetState = function safeSetState(nextState, callback) {\n // This shouldn't be necessary, but there are weird race conditions with\n // setState callbacks and unmounting in testing, so always make sure that\n // we can cancel any pending setState callbacks after we unmount.\n callback = this.setNextCallback(callback);\n this.setState(nextState, callback);\n };\n\n _proto.setNextCallback = function setNextCallback(callback) {\n var _this4 = this;\n\n var active = true;\n\n this.nextCallback = function (event) {\n if (active) {\n active = false;\n _this4.nextCallback = null;\n callback(event);\n }\n };\n\n this.nextCallback.cancel = function () {\n active = false;\n };\n\n return this.nextCallback;\n };\n\n _proto.onTransitionEnd = function onTransitionEnd(timeout, handler) {\n this.setNextCallback(handler);\n var node = this.props.nodeRef ? this.props.nodeRef.current : ReactDOM.findDOMNode(this);\n var doesNotHaveTimeoutOrListener = timeout == null && !this.props.addEndListener;\n\n if (!node || doesNotHaveTimeoutOrListener) {\n setTimeout(this.nextCallback, 0);\n return;\n }\n\n if (this.props.addEndListener) {\n var _ref3 = this.props.nodeRef ? [this.nextCallback] : [node, this.nextCallback],\n maybeNode = _ref3[0],\n maybeNextCallback = _ref3[1];\n\n this.props.addEndListener(maybeNode, maybeNextCallback);\n }\n\n if (timeout != null) {\n setTimeout(this.nextCallback, timeout);\n }\n };\n\n _proto.render = function render() {\n var status = this.state.status;\n\n if (status === UNMOUNTED) {\n return null;\n }\n\n var _this$props = this.props,\n children = _this$props.children,\n _in = _this$props.in,\n _mountOnEnter = _this$props.mountOnEnter,\n _unmountOnExit = _this$props.unmountOnExit,\n _appear = _this$props.appear,\n _enter = _this$props.enter,\n _exit = _this$props.exit,\n _timeout = _this$props.timeout,\n _addEndListener = _this$props.addEndListener,\n _onEnter = _this$props.onEnter,\n _onEntering = _this$props.onEntering,\n _onEntered = _this$props.onEntered,\n _onExit = _this$props.onExit,\n _onExiting = _this$props.onExiting,\n _onExited = _this$props.onExited,\n _nodeRef = _this$props.nodeRef,\n childProps = _objectWithoutPropertiesLoose(_this$props, [\"children\", \"in\", \"mountOnEnter\", \"unmountOnExit\", \"appear\", \"enter\", \"exit\", \"timeout\", \"addEndListener\", \"onEnter\", \"onEntering\", \"onEntered\", \"onExit\", \"onExiting\", \"onExited\", \"nodeRef\"]);\n\n return (\n /*#__PURE__*/\n // allows for nested Transitions\n React.createElement(TransitionGroupContext.Provider, {\n value: null\n }, typeof children === 'function' ? children(status, childProps) : React.cloneElement(React.Children.only(children), childProps))\n );\n };\n\n return Transition;\n}(React.Component);\n\nTransition.contextType = TransitionGroupContext;\nTransition.propTypes = process.env.NODE_ENV !== \"production\" ? {\n /**\n * A React reference to DOM element that need to transition:\n * https://stackoverflow.com/a/51127130/4671932\n *\n * - When `nodeRef` prop is used, `node` is not passed to callback functions\n * (e.g. `onEnter`) because user already has direct access to the node.\n * - When changing `key` prop of `Transition` in a `TransitionGroup` a new\n * `nodeRef` need to be provided to `Transition` with changed `key` prop\n * (see\n * [test/CSSTransition-test.js](https://github.com/reactjs/react-transition-group/blob/13435f897b3ab71f6e19d724f145596f5910581c/test/CSSTransition-test.js#L362-L437)).\n */\n nodeRef: PropTypes.shape({\n current: typeof Element === 'undefined' ? PropTypes.any : function (propValue, key, componentName, location, propFullName, secret) {\n var value = propValue[key];\n return PropTypes.instanceOf(value && 'ownerDocument' in value ? value.ownerDocument.defaultView.Element : Element)(propValue, key, componentName, location, propFullName, secret);\n }\n }),\n\n /**\n * A `function` child can be used instead of a React element. This function is\n * called with the current transition status (`'entering'`, `'entered'`,\n * `'exiting'`, `'exited'`), which can be used to apply context\n * specific props to a component.\n *\n * ```jsx\n * \n * {state => (\n * \n * )}\n * \n * ```\n */\n children: PropTypes.oneOfType([PropTypes.func.isRequired, PropTypes.element.isRequired]).isRequired,\n\n /**\n * Show the component; triggers the enter or exit states\n */\n in: PropTypes.bool,\n\n /**\n * By default the child component is mounted immediately along with\n * the parent `Transition` component. If you want to \"lazy mount\" the component on the\n * first `in={true}` you can set `mountOnEnter`. After the first enter transition the component will stay\n * mounted, even on \"exited\", unless you also specify `unmountOnExit`.\n */\n mountOnEnter: PropTypes.bool,\n\n /**\n * By default the child component stays mounted after it reaches the `'exited'` state.\n * Set `unmountOnExit` if you'd prefer to unmount the component after it finishes exiting.\n */\n unmountOnExit: PropTypes.bool,\n\n /**\n * By default the child component does not perform the enter transition when\n * it first mounts, regardless of the value of `in`. If you want this\n * behavior, set both `appear` and `in` to `true`.\n *\n * > **Note**: there are no special appear states like `appearing`/`appeared`, this prop\n * > only adds an additional enter transition. However, in the\n * > `` component that first enter transition does result in\n * > additional `.appear-*` classes, that way you can choose to style it\n * > differently.\n */\n appear: PropTypes.bool,\n\n /**\n * Enable or disable enter transitions.\n */\n enter: PropTypes.bool,\n\n /**\n * Enable or disable exit transitions.\n */\n exit: PropTypes.bool,\n\n /**\n * The duration of the transition, in milliseconds.\n * Required unless `addEndListener` is provided.\n *\n * You may specify a single timeout for all transitions:\n *\n * ```jsx\n * timeout={500}\n * ```\n *\n * or individually:\n *\n * ```jsx\n * timeout={{\n * appear: 500,\n * enter: 300,\n * exit: 500,\n * }}\n * ```\n *\n * - `appear` defaults to the value of `enter`\n * - `enter` defaults to `0`\n * - `exit` defaults to `0`\n *\n * @type {number | { enter?: number, exit?: number, appear?: number }}\n */\n timeout: function timeout(props) {\n var pt = timeoutsShape;\n if (!props.addEndListener) pt = pt.isRequired;\n\n for (var _len = arguments.length, args = new Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) {\n args[_key - 1] = arguments[_key];\n }\n\n return pt.apply(void 0, [props].concat(args));\n },\n\n /**\n * Add a custom transition end trigger. Called with the transitioning\n * DOM node and a `done` callback. Allows for more fine grained transition end\n * logic. Timeouts are still used as a fallback if provided.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * ```jsx\n * addEndListener={(node, done) => {\n * // use the css transitionend event to mark the finish of a transition\n * node.addEventListener('transitionend', done, false);\n * }}\n * ```\n */\n addEndListener: PropTypes.func,\n\n /**\n * Callback fired before the \"entering\" status is applied. An extra parameter\n * `isAppearing` is supplied to indicate if the enter stage is occurring on the initial mount\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement, isAppearing: bool) -> void\n */\n onEnter: PropTypes.func,\n\n /**\n * Callback fired after the \"entering\" status is applied. An extra parameter\n * `isAppearing` is supplied to indicate if the enter stage is occurring on the initial mount\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement, isAppearing: bool)\n */\n onEntering: PropTypes.func,\n\n /**\n * Callback fired after the \"entered\" status is applied. An extra parameter\n * `isAppearing` is supplied to indicate if the enter stage is occurring on the initial mount\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement, isAppearing: bool) -> void\n */\n onEntered: PropTypes.func,\n\n /**\n * Callback fired before the \"exiting\" status is applied.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement) -> void\n */\n onExit: PropTypes.func,\n\n /**\n * Callback fired after the \"exiting\" status is applied.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement) -> void\n */\n onExiting: PropTypes.func,\n\n /**\n * Callback fired after the \"exited\" status is applied.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed\n *\n * @type Function(node: HtmlElement) -> void\n */\n onExited: PropTypes.func\n} : {}; // Name the function so it is clearer in the documentation\n\nfunction noop() {}\n\nTransition.defaultProps = {\n in: false,\n mountOnEnter: false,\n unmountOnExit: false,\n appear: false,\n enter: true,\n exit: true,\n onEnter: noop,\n onEntering: noop,\n onEntered: noop,\n onExit: noop,\n onExiting: noop,\n onExited: noop\n};\nTransition.UNMOUNTED = UNMOUNTED;\nTransition.EXITED = EXITED;\nTransition.ENTERING = ENTERING;\nTransition.ENTERED = ENTERED;\nTransition.EXITING = EXITING;\nexport default Transition;","export const reflow = node => node.scrollTop;\nexport function getTransitionProps(props, options) {\n var _style$transitionDura, _style$transitionTimi;\n const {\n timeout,\n easing,\n style = {}\n } = props;\n return {\n duration: (_style$transitionDura = style.transitionDuration) != null ? _style$transitionDura : typeof timeout === 'number' ? timeout : timeout[options.mode] || 0,\n easing: (_style$transitionTimi = style.transitionTimingFunction) != null ? _style$transitionTimi : typeof easing === 'object' ? easing[options.mode] : easing,\n delay: style.transitionDelay\n };\n}","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"addEndListener\", \"appear\", \"children\", \"easing\", \"in\", \"onEnter\", \"onEntered\", \"onEntering\", \"onExit\", \"onExited\", \"onExiting\", \"style\", \"timeout\", \"TransitionComponent\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport { elementAcceptingRef, unstable_useTimeout as useTimeout } from '@mui/utils';\nimport { Transition } from 'react-transition-group';\nimport useTheme from '../styles/useTheme';\nimport { getTransitionProps, reflow } from '../transitions/utils';\nimport useForkRef from '../utils/useForkRef';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nfunction getScale(value) {\n return `scale(${value}, ${value ** 2})`;\n}\nconst styles = {\n entering: {\n opacity: 1,\n transform: getScale(1)\n },\n entered: {\n opacity: 1,\n transform: 'none'\n }\n};\n\n/*\n TODO v6: remove\n Conditionally apply a workaround for the CSS transition bug in Safari 15.4 / WebKit browsers.\n */\nconst isWebKit154 = typeof navigator !== 'undefined' && /^((?!chrome|android).)*(safari|mobile)/i.test(navigator.userAgent) && /(os |version\\/)15(.|_)4/i.test(navigator.userAgent);\n\n/**\n * The Grow transition is used by the [Tooltip](/material-ui/react-tooltip/) and\n * [Popover](/material-ui/react-popover/) components.\n * It uses [react-transition-group](https://github.com/reactjs/react-transition-group) internally.\n */\nconst Grow = /*#__PURE__*/React.forwardRef(function Grow(props, ref) {\n const {\n addEndListener,\n appear = true,\n children,\n easing,\n in: inProp,\n onEnter,\n onEntered,\n onEntering,\n onExit,\n onExited,\n onExiting,\n style,\n timeout = 'auto',\n // eslint-disable-next-line react/prop-types\n TransitionComponent = Transition\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const timer = useTimeout();\n const autoTimeout = React.useRef();\n const theme = useTheme();\n const nodeRef = React.useRef(null);\n const handleRef = useForkRef(nodeRef, children.ref, ref);\n const normalizedTransitionCallback = callback => maybeIsAppearing => {\n if (callback) {\n const node = nodeRef.current;\n\n // onEnterXxx and onExitXxx callbacks have a different arguments.length value.\n if (maybeIsAppearing === undefined) {\n callback(node);\n } else {\n callback(node, maybeIsAppearing);\n }\n }\n };\n const handleEntering = normalizedTransitionCallback(onEntering);\n const handleEnter = normalizedTransitionCallback((node, isAppearing) => {\n reflow(node); // So the animation always start from the start.\n\n const {\n duration: transitionDuration,\n delay,\n easing: transitionTimingFunction\n } = getTransitionProps({\n style,\n timeout,\n easing\n }, {\n mode: 'enter'\n });\n let duration;\n if (timeout === 'auto') {\n duration = theme.transitions.getAutoHeightDuration(node.clientHeight);\n autoTimeout.current = duration;\n } else {\n duration = transitionDuration;\n }\n node.style.transition = [theme.transitions.create('opacity', {\n duration,\n delay\n }), theme.transitions.create('transform', {\n duration: isWebKit154 ? duration : duration * 0.666,\n delay,\n easing: transitionTimingFunction\n })].join(',');\n if (onEnter) {\n onEnter(node, isAppearing);\n }\n });\n const handleEntered = normalizedTransitionCallback(onEntered);\n const handleExiting = normalizedTransitionCallback(onExiting);\n const handleExit = normalizedTransitionCallback(node => {\n const {\n duration: transitionDuration,\n delay,\n easing: transitionTimingFunction\n } = getTransitionProps({\n style,\n timeout,\n easing\n }, {\n mode: 'exit'\n });\n let duration;\n if (timeout === 'auto') {\n duration = theme.transitions.getAutoHeightDuration(node.clientHeight);\n autoTimeout.current = duration;\n } else {\n duration = transitionDuration;\n }\n node.style.transition = [theme.transitions.create('opacity', {\n duration,\n delay\n }), theme.transitions.create('transform', {\n duration: isWebKit154 ? duration : duration * 0.666,\n delay: isWebKit154 ? delay : delay || duration * 0.333,\n easing: transitionTimingFunction\n })].join(',');\n node.style.opacity = 0;\n node.style.transform = getScale(0.75);\n if (onExit) {\n onExit(node);\n }\n });\n const handleExited = normalizedTransitionCallback(onExited);\n const handleAddEndListener = next => {\n if (timeout === 'auto') {\n timer.start(autoTimeout.current || 0, next);\n }\n if (addEndListener) {\n // Old call signature before `react-transition-group` implemented `nodeRef`\n addEndListener(nodeRef.current, next);\n }\n };\n return /*#__PURE__*/_jsx(TransitionComponent, _extends({\n appear: appear,\n in: inProp,\n nodeRef: nodeRef,\n onEnter: handleEnter,\n onEntered: handleEntered,\n onEntering: handleEntering,\n onExit: handleExit,\n onExited: handleExited,\n onExiting: handleExiting,\n addEndListener: handleAddEndListener,\n timeout: timeout === 'auto' ? null : timeout\n }, other, {\n children: (state, childProps) => {\n return /*#__PURE__*/React.cloneElement(children, _extends({\n style: _extends({\n opacity: 0,\n transform: getScale(0.75),\n visibility: state === 'exited' && !inProp ? 'hidden' : undefined\n }, styles[state], style, children.props.style),\n ref: handleRef\n }, childProps));\n }\n }));\n});\nprocess.env.NODE_ENV !== \"production\" ? Grow.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the d.ts file and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * Add a custom transition end trigger. Called with the transitioning DOM\n * node and a done callback. Allows for more fine grained transition end\n * logic. Note: Timeouts are still used as a fallback if provided.\n */\n addEndListener: PropTypes.func,\n /**\n * Perform the enter transition when it first mounts if `in` is also `true`.\n * Set this to `false` to disable this behavior.\n * @default true\n */\n appear: PropTypes.bool,\n /**\n * A single child content element.\n */\n children: elementAcceptingRef.isRequired,\n /**\n * The transition timing function.\n * You may specify a single easing or a object containing enter and exit values.\n */\n easing: PropTypes.oneOfType([PropTypes.shape({\n enter: PropTypes.string,\n exit: PropTypes.string\n }), PropTypes.string]),\n /**\n * If `true`, the component will transition in.\n */\n in: PropTypes.bool,\n /**\n * @ignore\n */\n onEnter: PropTypes.func,\n /**\n * @ignore\n */\n onEntered: PropTypes.func,\n /**\n * @ignore\n */\n onEntering: PropTypes.func,\n /**\n * @ignore\n */\n onExit: PropTypes.func,\n /**\n * @ignore\n */\n onExited: PropTypes.func,\n /**\n * @ignore\n */\n onExiting: PropTypes.func,\n /**\n * @ignore\n */\n style: PropTypes.object,\n /**\n * The duration for the transition, in milliseconds.\n * You may specify a single timeout for all transitions, or individually with an object.\n *\n * Set to 'auto' to automatically calculate transition time based on height.\n * @default 'auto'\n */\n timeout: PropTypes.oneOfType([PropTypes.oneOf(['auto']), PropTypes.number, PropTypes.shape({\n appear: PropTypes.number,\n enter: PropTypes.number,\n exit: PropTypes.number\n })])\n} : void 0;\nGrow.muiSupportAuto = true;\nexport default Grow;","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"anchorEl\", \"component\", \"components\", \"componentsProps\", \"container\", \"disablePortal\", \"keepMounted\", \"modifiers\", \"open\", \"placement\", \"popperOptions\", \"popperRef\", \"transition\", \"slots\", \"slotProps\"];\nimport { Popper as BasePopper } from '@mui/base/Popper';\nimport { useThemeWithoutDefault as useTheme } from '@mui/system';\nimport { HTMLElementType, refType } from '@mui/utils';\nimport PropTypes from 'prop-types';\nimport * as React from 'react';\nimport { styled, useThemeProps } from '../styles';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nconst PopperRoot = styled(BasePopper, {\n name: 'MuiPopper',\n slot: 'Root',\n overridesResolver: (props, styles) => styles.root\n})({});\n\n/**\n *\n * Demos:\n *\n * - [Autocomplete](https://mui.com/material-ui/react-autocomplete/)\n * - [Menu](https://mui.com/material-ui/react-menu/)\n * - [Popper](https://mui.com/material-ui/react-popper/)\n *\n * API:\n *\n * - [Popper API](https://mui.com/material-ui/api/popper/)\n */\nconst Popper = /*#__PURE__*/React.forwardRef(function Popper(inProps, ref) {\n var _slots$root;\n const theme = useTheme();\n const props = useThemeProps({\n props: inProps,\n name: 'MuiPopper'\n });\n const {\n anchorEl,\n component,\n components,\n componentsProps,\n container,\n disablePortal,\n keepMounted,\n modifiers,\n open,\n placement,\n popperOptions,\n popperRef,\n transition,\n slots,\n slotProps\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const RootComponent = (_slots$root = slots == null ? void 0 : slots.root) != null ? _slots$root : components == null ? void 0 : components.Root;\n const otherProps = _extends({\n anchorEl,\n container,\n disablePortal,\n keepMounted,\n modifiers,\n open,\n placement,\n popperOptions,\n popperRef,\n transition\n }, other);\n return /*#__PURE__*/_jsx(PopperRoot, _extends({\n as: component,\n direction: theme == null ? void 0 : theme.direction,\n slots: {\n root: RootComponent\n },\n slotProps: slotProps != null ? slotProps : componentsProps\n }, otherProps, {\n ref: ref\n }));\n});\nprocess.env.NODE_ENV !== \"production\" ? Popper.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * An HTML element, [virtualElement](https://popper.js.org/docs/v2/virtual-elements/),\n * or a function that returns either.\n * It's used to set the position of the popper.\n * The return value will passed as the reference object of the Popper instance.\n */\n anchorEl: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.object, PropTypes.func]),\n /**\n * Popper render function or node.\n */\n children: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.node, PropTypes.func]),\n /**\n * The component used for the root node.\n * Either a string to use a HTML element or a component.\n */\n component: PropTypes.elementType,\n /**\n * The components used for each slot inside the Popper.\n * Either a string to use a HTML element or a component.\n * @default {}\n */\n components: PropTypes.shape({\n Root: PropTypes.elementType\n }),\n /**\n * The props used for each slot inside the Popper.\n * @default {}\n */\n componentsProps: PropTypes.shape({\n root: PropTypes.oneOfType([PropTypes.func, PropTypes.object])\n }),\n /**\n * An HTML element or function that returns one.\n * The `container` will have the portal children appended to it.\n *\n * You can also provide a callback, which is called in a React layout effect.\n * This lets you set the container from a ref, and also makes server-side rendering possible.\n *\n * By default, it uses the body of the top-level document object,\n * so it's simply `document.body` most of the time.\n */\n container: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.func]),\n /**\n * The `children` will be under the DOM hierarchy of the parent component.\n * @default false\n */\n disablePortal: PropTypes.bool,\n /**\n * Always keep the children in the DOM.\n * This prop can be useful in SEO situation or\n * when you want to maximize the responsiveness of the Popper.\n * @default false\n */\n keepMounted: PropTypes.bool,\n /**\n * Popper.js is based on a \"plugin-like\" architecture,\n * most of its features are fully encapsulated \"modifiers\".\n *\n * A modifier is a function that is called each time Popper.js needs to\n * compute the position of the popper.\n * For this reason, modifiers should be very performant to avoid bottlenecks.\n * To learn how to create a modifier, [read the modifiers documentation](https://popper.js.org/docs/v2/modifiers/).\n */\n modifiers: PropTypes.arrayOf(PropTypes.shape({\n data: PropTypes.object,\n effect: PropTypes.func,\n enabled: PropTypes.bool,\n fn: PropTypes.func,\n name: PropTypes.any,\n options: PropTypes.object,\n phase: PropTypes.oneOf(['afterMain', 'afterRead', 'afterWrite', 'beforeMain', 'beforeRead', 'beforeWrite', 'main', 'read', 'write']),\n requires: PropTypes.arrayOf(PropTypes.string),\n requiresIfExists: PropTypes.arrayOf(PropTypes.string)\n })),\n /**\n * If `true`, the component is shown.\n */\n open: PropTypes.bool.isRequired,\n /**\n * Popper placement.\n * @default 'bottom'\n */\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n /**\n * Options provided to the [`Popper.js`](https://popper.js.org/docs/v2/constructors/#options) instance.\n * @default {}\n */\n popperOptions: PropTypes.shape({\n modifiers: PropTypes.array,\n onFirstUpdate: PropTypes.func,\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n strategy: PropTypes.oneOf(['absolute', 'fixed'])\n }),\n /**\n * A ref that points to the used popper instance.\n */\n popperRef: refType,\n /**\n * The props used for each slot inside the Popper.\n * @default {}\n */\n slotProps: PropTypes.shape({\n root: PropTypes.oneOfType([PropTypes.func, PropTypes.object])\n }),\n /**\n * The components used for each slot inside the Popper.\n * Either a string to use a HTML element or a component.\n * @default {}\n */\n slots: PropTypes.shape({\n root: PropTypes.elementType\n }),\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Help supporting a react-transition-group/Transition component.\n * @default false\n */\n transition: PropTypes.bool\n} : void 0;\nexport default Popper;","import generateUtilityClasses from '@mui/utils/generateUtilityClasses';\nimport generateUtilityClass from '@mui/utils/generateUtilityClass';\nexport function getTooltipUtilityClass(slot) {\n return generateUtilityClass('MuiTooltip', slot);\n}\nconst tooltipClasses = generateUtilityClasses('MuiTooltip', ['popper', 'popperInteractive', 'popperArrow', 'popperClose', 'tooltip', 'tooltipArrow', 'touch', 'tooltipPlacementLeft', 'tooltipPlacementRight', 'tooltipPlacementTop', 'tooltipPlacementBottom', 'arrow']);\nexport default tooltipClasses;","'use client';\n\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nconst _excluded = [\"arrow\", \"children\", \"classes\", \"components\", \"componentsProps\", \"describeChild\", \"disableFocusListener\", \"disableHoverListener\", \"disableInteractive\", \"disableTouchListener\", \"enterDelay\", \"enterNextDelay\", \"enterTouchDelay\", \"followCursor\", \"id\", \"leaveDelay\", \"leaveTouchDelay\", \"onClose\", \"onOpen\", \"open\", \"placement\", \"PopperComponent\", \"PopperProps\", \"slotProps\", \"slots\", \"title\", \"TransitionComponent\", \"TransitionProps\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport clsx from 'clsx';\nimport { elementAcceptingRef, unstable_useTimeout as useTimeout, unstable_Timeout as Timeout } from '@mui/utils';\nimport { unstable_composeClasses as composeClasses, appendOwnerState } from '@mui/base';\nimport { alpha } from '@mui/system';\nimport styled from '../styles/styled';\nimport useTheme from '../styles/useTheme';\nimport useThemeProps from '../styles/useThemeProps';\nimport capitalize from '../utils/capitalize';\nimport Grow from '../Grow';\nimport Popper from '../Popper';\nimport useEventCallback from '../utils/useEventCallback';\nimport useForkRef from '../utils/useForkRef';\nimport useId from '../utils/useId';\nimport useIsFocusVisible from '../utils/useIsFocusVisible';\nimport useControlled from '../utils/useControlled';\nimport tooltipClasses, { getTooltipUtilityClass } from './tooltipClasses';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nimport { jsxs as _jsxs } from \"react/jsx-runtime\";\nfunction round(value) {\n return Math.round(value * 1e5) / 1e5;\n}\nconst useUtilityClasses = ownerState => {\n const {\n classes,\n disableInteractive,\n arrow,\n touch,\n placement\n } = ownerState;\n const slots = {\n popper: ['popper', !disableInteractive && 'popperInteractive', arrow && 'popperArrow'],\n tooltip: ['tooltip', arrow && 'tooltipArrow', touch && 'touch', `tooltipPlacement${capitalize(placement.split('-')[0])}`],\n arrow: ['arrow']\n };\n return composeClasses(slots, getTooltipUtilityClass, classes);\n};\nconst TooltipPopper = styled(Popper, {\n name: 'MuiTooltip',\n slot: 'Popper',\n overridesResolver: (props, styles) => {\n const {\n ownerState\n } = props;\n return [styles.popper, !ownerState.disableInteractive && styles.popperInteractive, ownerState.arrow && styles.popperArrow, !ownerState.open && styles.popperClose];\n }\n})(({\n theme,\n ownerState,\n open\n}) => _extends({\n zIndex: (theme.vars || theme).zIndex.tooltip,\n pointerEvents: 'none'\n}, !ownerState.disableInteractive && {\n pointerEvents: 'auto'\n}, !open && {\n pointerEvents: 'none'\n}, ownerState.arrow && {\n [`&[data-popper-placement*=\"bottom\"] .${tooltipClasses.arrow}`]: {\n top: 0,\n marginTop: '-0.71em',\n '&::before': {\n transformOrigin: '0 100%'\n }\n },\n [`&[data-popper-placement*=\"top\"] .${tooltipClasses.arrow}`]: {\n bottom: 0,\n marginBottom: '-0.71em',\n '&::before': {\n transformOrigin: '100% 0'\n }\n },\n [`&[data-popper-placement*=\"right\"] .${tooltipClasses.arrow}`]: _extends({}, !ownerState.isRtl ? {\n left: 0,\n marginLeft: '-0.71em'\n } : {\n right: 0,\n marginRight: '-0.71em'\n }, {\n height: '1em',\n width: '0.71em',\n '&::before': {\n transformOrigin: '100% 100%'\n }\n }),\n [`&[data-popper-placement*=\"left\"] .${tooltipClasses.arrow}`]: _extends({}, !ownerState.isRtl ? {\n right: 0,\n marginRight: '-0.71em'\n } : {\n left: 0,\n marginLeft: '-0.71em'\n }, {\n height: '1em',\n width: '0.71em',\n '&::before': {\n transformOrigin: '0 0'\n }\n })\n}));\nconst TooltipTooltip = styled('div', {\n name: 'MuiTooltip',\n slot: 'Tooltip',\n overridesResolver: (props, styles) => {\n const {\n ownerState\n } = props;\n return [styles.tooltip, ownerState.touch && styles.touch, ownerState.arrow && styles.tooltipArrow, styles[`tooltipPlacement${capitalize(ownerState.placement.split('-')[0])}`]];\n }\n})(({\n theme,\n ownerState\n}) => _extends({\n backgroundColor: theme.vars ? theme.vars.palette.Tooltip.bg : alpha(theme.palette.grey[700], 0.92),\n borderRadius: (theme.vars || theme).shape.borderRadius,\n color: (theme.vars || theme).palette.common.white,\n fontFamily: theme.typography.fontFamily,\n padding: '4px 8px',\n fontSize: theme.typography.pxToRem(11),\n maxWidth: 300,\n margin: 2,\n wordWrap: 'break-word',\n fontWeight: theme.typography.fontWeightMedium\n}, ownerState.arrow && {\n position: 'relative',\n margin: 0\n}, ownerState.touch && {\n padding: '8px 16px',\n fontSize: theme.typography.pxToRem(14),\n lineHeight: `${round(16 / 14)}em`,\n fontWeight: theme.typography.fontWeightRegular\n}, {\n [`.${tooltipClasses.popper}[data-popper-placement*=\"left\"] &`]: _extends({\n transformOrigin: 'right center'\n }, !ownerState.isRtl ? _extends({\n marginRight: '14px'\n }, ownerState.touch && {\n marginRight: '24px'\n }) : _extends({\n marginLeft: '14px'\n }, ownerState.touch && {\n marginLeft: '24px'\n })),\n [`.${tooltipClasses.popper}[data-popper-placement*=\"right\"] &`]: _extends({\n transformOrigin: 'left center'\n }, !ownerState.isRtl ? _extends({\n marginLeft: '14px'\n }, ownerState.touch && {\n marginLeft: '24px'\n }) : _extends({\n marginRight: '14px'\n }, ownerState.touch && {\n marginRight: '24px'\n })),\n [`.${tooltipClasses.popper}[data-popper-placement*=\"top\"] &`]: _extends({\n transformOrigin: 'center bottom',\n marginBottom: '14px'\n }, ownerState.touch && {\n marginBottom: '24px'\n }),\n [`.${tooltipClasses.popper}[data-popper-placement*=\"bottom\"] &`]: _extends({\n transformOrigin: 'center top',\n marginTop: '14px'\n }, ownerState.touch && {\n marginTop: '24px'\n })\n}));\nconst TooltipArrow = styled('span', {\n name: 'MuiTooltip',\n slot: 'Arrow',\n overridesResolver: (props, styles) => styles.arrow\n})(({\n theme\n}) => ({\n overflow: 'hidden',\n position: 'absolute',\n width: '1em',\n height: '0.71em' /* = width / sqrt(2) = (length of the hypotenuse) */,\n boxSizing: 'border-box',\n color: theme.vars ? theme.vars.palette.Tooltip.bg : alpha(theme.palette.grey[700], 0.9),\n '&::before': {\n content: '\"\"',\n margin: 'auto',\n display: 'block',\n width: '100%',\n height: '100%',\n backgroundColor: 'currentColor',\n transform: 'rotate(45deg)'\n }\n}));\nlet hystersisOpen = false;\nconst hystersisTimer = new Timeout();\nlet cursorPosition = {\n x: 0,\n y: 0\n};\nexport function testReset() {\n hystersisOpen = false;\n hystersisTimer.clear();\n}\nfunction composeEventHandler(handler, eventHandler) {\n return event => {\n if (eventHandler) {\n eventHandler(event);\n }\n handler(event);\n };\n}\n\n// TODO v6: Remove PopperComponent, PopperProps, TransitionComponent and TransitionProps.\nconst Tooltip = /*#__PURE__*/React.forwardRef(function Tooltip(inProps, ref) {\n var _ref, _slots$popper, _ref2, _ref3, _slots$transition, _ref4, _slots$tooltip, _ref5, _slots$arrow, _slotProps$popper, _ref6, _slotProps$popper2, _slotProps$transition, _slotProps$tooltip, _ref7, _slotProps$tooltip2, _slotProps$arrow, _ref8, _slotProps$arrow2;\n const props = useThemeProps({\n props: inProps,\n name: 'MuiTooltip'\n });\n const {\n arrow = false,\n children: childrenProp,\n components = {},\n componentsProps = {},\n describeChild = false,\n disableFocusListener = false,\n disableHoverListener = false,\n disableInteractive: disableInteractiveProp = false,\n disableTouchListener = false,\n enterDelay = 100,\n enterNextDelay = 0,\n enterTouchDelay = 700,\n followCursor = false,\n id: idProp,\n leaveDelay = 0,\n leaveTouchDelay = 1500,\n onClose,\n onOpen,\n open: openProp,\n placement = 'bottom',\n PopperComponent: PopperComponentProp,\n PopperProps = {},\n slotProps = {},\n slots = {},\n title,\n TransitionComponent: TransitionComponentProp = Grow,\n TransitionProps\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n\n // to prevent runtime errors, developers will need to provide a child as a React element anyway.\n const children = /*#__PURE__*/React.isValidElement(childrenProp) ? childrenProp : /*#__PURE__*/_jsx(\"span\", {\n children: childrenProp\n });\n const theme = useTheme();\n const isRtl = theme.direction === 'rtl';\n const [childNode, setChildNode] = React.useState();\n const [arrowRef, setArrowRef] = React.useState(null);\n const ignoreNonTouchEvents = React.useRef(false);\n const disableInteractive = disableInteractiveProp || followCursor;\n const closeTimer = useTimeout();\n const enterTimer = useTimeout();\n const leaveTimer = useTimeout();\n const touchTimer = useTimeout();\n const [openState, setOpenState] = useControlled({\n controlled: openProp,\n default: false,\n name: 'Tooltip',\n state: 'open'\n });\n let open = openState;\n if (process.env.NODE_ENV !== 'production') {\n // eslint-disable-next-line react-hooks/rules-of-hooks\n const {\n current: isControlled\n } = React.useRef(openProp !== undefined);\n\n // eslint-disable-next-line react-hooks/rules-of-hooks\n React.useEffect(() => {\n if (childNode && childNode.disabled && !isControlled && title !== '' && childNode.tagName.toLowerCase() === 'button') {\n console.error(['MUI: You are providing a disabled `button` child to the Tooltip component.', 'A disabled element does not fire events.', \"Tooltip needs to listen to the child element's events to display the title.\", '', 'Add a simple wrapper element, such as a `span`.'].join('\\n'));\n }\n }, [title, childNode, isControlled]);\n }\n const id = useId(idProp);\n const prevUserSelect = React.useRef();\n const stopTouchInteraction = useEventCallback(() => {\n if (prevUserSelect.current !== undefined) {\n document.body.style.WebkitUserSelect = prevUserSelect.current;\n prevUserSelect.current = undefined;\n }\n touchTimer.clear();\n });\n React.useEffect(() => stopTouchInteraction, [stopTouchInteraction]);\n const handleOpen = event => {\n hystersisTimer.clear();\n hystersisOpen = true;\n\n // The mouseover event will trigger for every nested element in the tooltip.\n // We can skip rerendering when the tooltip is already open.\n // We are using the mouseover event instead of the mouseenter event to fix a hide/show issue.\n setOpenState(true);\n if (onOpen && !open) {\n onOpen(event);\n }\n };\n const handleClose = useEventCallback(\n /**\n * @param {React.SyntheticEvent | Event} event\n */\n event => {\n hystersisTimer.start(800 + leaveDelay, () => {\n hystersisOpen = false;\n });\n setOpenState(false);\n if (onClose && open) {\n onClose(event);\n }\n closeTimer.start(theme.transitions.duration.shortest, () => {\n ignoreNonTouchEvents.current = false;\n });\n });\n const handleEnter = event => {\n if (ignoreNonTouchEvents.current && event.type !== 'touchstart') {\n return;\n }\n\n // Remove the title ahead of time.\n // We don't want to wait for the next render commit.\n // We would risk displaying two tooltips at the same time (native + this one).\n if (childNode) {\n childNode.removeAttribute('title');\n }\n enterTimer.clear();\n leaveTimer.clear();\n if (enterDelay || hystersisOpen && enterNextDelay) {\n enterTimer.start(hystersisOpen ? enterNextDelay : enterDelay, () => {\n handleOpen(event);\n });\n } else {\n handleOpen(event);\n }\n };\n const handleLeave = event => {\n enterTimer.clear();\n leaveTimer.start(leaveDelay, () => {\n handleClose(event);\n });\n };\n const {\n isFocusVisibleRef,\n onBlur: handleBlurVisible,\n onFocus: handleFocusVisible,\n ref: focusVisibleRef\n } = useIsFocusVisible();\n // We don't necessarily care about the focusVisible state (which is safe to access via ref anyway).\n // We just need to re-render the Tooltip if the focus-visible state changes.\n const [, setChildIsFocusVisible] = React.useState(false);\n const handleBlur = event => {\n handleBlurVisible(event);\n if (isFocusVisibleRef.current === false) {\n setChildIsFocusVisible(false);\n handleLeave(event);\n }\n };\n const handleFocus = event => {\n // Workaround for https://github.com/facebook/react/issues/7769\n // The autoFocus of React might trigger the event before the componentDidMount.\n // We need to account for this eventuality.\n if (!childNode) {\n setChildNode(event.currentTarget);\n }\n handleFocusVisible(event);\n if (isFocusVisibleRef.current === true) {\n setChildIsFocusVisible(true);\n handleEnter(event);\n }\n };\n const detectTouchStart = event => {\n ignoreNonTouchEvents.current = true;\n const childrenProps = children.props;\n if (childrenProps.onTouchStart) {\n childrenProps.onTouchStart(event);\n }\n };\n const handleMouseOver = handleEnter;\n const handleMouseLeave = handleLeave;\n const handleTouchStart = event => {\n detectTouchStart(event);\n leaveTimer.clear();\n closeTimer.clear();\n stopTouchInteraction();\n prevUserSelect.current = document.body.style.WebkitUserSelect;\n // Prevent iOS text selection on long-tap.\n document.body.style.WebkitUserSelect = 'none';\n touchTimer.start(enterTouchDelay, () => {\n document.body.style.WebkitUserSelect = prevUserSelect.current;\n handleEnter(event);\n });\n };\n const handleTouchEnd = event => {\n if (children.props.onTouchEnd) {\n children.props.onTouchEnd(event);\n }\n stopTouchInteraction();\n leaveTimer.start(leaveTouchDelay, () => {\n handleClose(event);\n });\n };\n React.useEffect(() => {\n if (!open) {\n return undefined;\n }\n\n /**\n * @param {KeyboardEvent} nativeEvent\n */\n function handleKeyDown(nativeEvent) {\n // IE11, Edge (prior to using Bink?) use 'Esc'\n if (nativeEvent.key === 'Escape' || nativeEvent.key === 'Esc') {\n handleClose(nativeEvent);\n }\n }\n document.addEventListener('keydown', handleKeyDown);\n return () => {\n document.removeEventListener('keydown', handleKeyDown);\n };\n }, [handleClose, open]);\n const handleRef = useForkRef(children.ref, focusVisibleRef, setChildNode, ref);\n\n // There is no point in displaying an empty tooltip.\n // So we exclude all falsy values, except 0, which is valid.\n if (!title && title !== 0) {\n open = false;\n }\n const popperRef = React.useRef();\n const handleMouseMove = event => {\n const childrenProps = children.props;\n if (childrenProps.onMouseMove) {\n childrenProps.onMouseMove(event);\n }\n cursorPosition = {\n x: event.clientX,\n y: event.clientY\n };\n if (popperRef.current) {\n popperRef.current.update();\n }\n };\n const nameOrDescProps = {};\n const titleIsString = typeof title === 'string';\n if (describeChild) {\n nameOrDescProps.title = !open && titleIsString && !disableHoverListener ? title : null;\n nameOrDescProps['aria-describedby'] = open ? id : null;\n } else {\n nameOrDescProps['aria-label'] = titleIsString ? title : null;\n nameOrDescProps['aria-labelledby'] = open && !titleIsString ? id : null;\n }\n const childrenProps = _extends({}, nameOrDescProps, other, children.props, {\n className: clsx(other.className, children.props.className),\n onTouchStart: detectTouchStart,\n ref: handleRef\n }, followCursor ? {\n onMouseMove: handleMouseMove\n } : {});\n if (process.env.NODE_ENV !== 'production') {\n childrenProps['data-mui-internal-clone-element'] = true;\n\n // eslint-disable-next-line react-hooks/rules-of-hooks\n React.useEffect(() => {\n if (childNode && !childNode.getAttribute('data-mui-internal-clone-element')) {\n console.error(['MUI: The `children` component of the Tooltip is not forwarding its props correctly.', 'Please make sure that props are spread on the same element that the ref is applied to.'].join('\\n'));\n }\n }, [childNode]);\n }\n const interactiveWrapperListeners = {};\n if (!disableTouchListener) {\n childrenProps.onTouchStart = handleTouchStart;\n childrenProps.onTouchEnd = handleTouchEnd;\n }\n if (!disableHoverListener) {\n childrenProps.onMouseOver = composeEventHandler(handleMouseOver, childrenProps.onMouseOver);\n childrenProps.onMouseLeave = composeEventHandler(handleMouseLeave, childrenProps.onMouseLeave);\n if (!disableInteractive) {\n interactiveWrapperListeners.onMouseOver = handleMouseOver;\n interactiveWrapperListeners.onMouseLeave = handleMouseLeave;\n }\n }\n if (!disableFocusListener) {\n childrenProps.onFocus = composeEventHandler(handleFocus, childrenProps.onFocus);\n childrenProps.onBlur = composeEventHandler(handleBlur, childrenProps.onBlur);\n if (!disableInteractive) {\n interactiveWrapperListeners.onFocus = handleFocus;\n interactiveWrapperListeners.onBlur = handleBlur;\n }\n }\n if (process.env.NODE_ENV !== 'production') {\n if (children.props.title) {\n console.error(['MUI: You have provided a `title` prop to the child of .', `Remove this title prop \\`${children.props.title}\\` or the Tooltip component.`].join('\\n'));\n }\n }\n const popperOptions = React.useMemo(() => {\n var _PopperProps$popperOp;\n let tooltipModifiers = [{\n name: 'arrow',\n enabled: Boolean(arrowRef),\n options: {\n element: arrowRef,\n padding: 4\n }\n }];\n if ((_PopperProps$popperOp = PopperProps.popperOptions) != null && _PopperProps$popperOp.modifiers) {\n tooltipModifiers = tooltipModifiers.concat(PopperProps.popperOptions.modifiers);\n }\n return _extends({}, PopperProps.popperOptions, {\n modifiers: tooltipModifiers\n });\n }, [arrowRef, PopperProps]);\n const ownerState = _extends({}, props, {\n isRtl,\n arrow,\n disableInteractive,\n placement,\n PopperComponentProp,\n touch: ignoreNonTouchEvents.current\n });\n const classes = useUtilityClasses(ownerState);\n const PopperComponent = (_ref = (_slots$popper = slots.popper) != null ? _slots$popper : components.Popper) != null ? _ref : TooltipPopper;\n const TransitionComponent = (_ref2 = (_ref3 = (_slots$transition = slots.transition) != null ? _slots$transition : components.Transition) != null ? _ref3 : TransitionComponentProp) != null ? _ref2 : Grow;\n const TooltipComponent = (_ref4 = (_slots$tooltip = slots.tooltip) != null ? _slots$tooltip : components.Tooltip) != null ? _ref4 : TooltipTooltip;\n const ArrowComponent = (_ref5 = (_slots$arrow = slots.arrow) != null ? _slots$arrow : components.Arrow) != null ? _ref5 : TooltipArrow;\n const popperProps = appendOwnerState(PopperComponent, _extends({}, PopperProps, (_slotProps$popper = slotProps.popper) != null ? _slotProps$popper : componentsProps.popper, {\n className: clsx(classes.popper, PopperProps == null ? void 0 : PopperProps.className, (_ref6 = (_slotProps$popper2 = slotProps.popper) != null ? _slotProps$popper2 : componentsProps.popper) == null ? void 0 : _ref6.className)\n }), ownerState);\n const transitionProps = appendOwnerState(TransitionComponent, _extends({}, TransitionProps, (_slotProps$transition = slotProps.transition) != null ? _slotProps$transition : componentsProps.transition), ownerState);\n const tooltipProps = appendOwnerState(TooltipComponent, _extends({}, (_slotProps$tooltip = slotProps.tooltip) != null ? _slotProps$tooltip : componentsProps.tooltip, {\n className: clsx(classes.tooltip, (_ref7 = (_slotProps$tooltip2 = slotProps.tooltip) != null ? _slotProps$tooltip2 : componentsProps.tooltip) == null ? void 0 : _ref7.className)\n }), ownerState);\n const tooltipArrowProps = appendOwnerState(ArrowComponent, _extends({}, (_slotProps$arrow = slotProps.arrow) != null ? _slotProps$arrow : componentsProps.arrow, {\n className: clsx(classes.arrow, (_ref8 = (_slotProps$arrow2 = slotProps.arrow) != null ? _slotProps$arrow2 : componentsProps.arrow) == null ? void 0 : _ref8.className)\n }), ownerState);\n return /*#__PURE__*/_jsxs(React.Fragment, {\n children: [/*#__PURE__*/React.cloneElement(children, childrenProps), /*#__PURE__*/_jsx(PopperComponent, _extends({\n as: PopperComponentProp != null ? PopperComponentProp : Popper,\n placement: placement,\n anchorEl: followCursor ? {\n getBoundingClientRect: () => ({\n top: cursorPosition.y,\n left: cursorPosition.x,\n right: cursorPosition.x,\n bottom: cursorPosition.y,\n width: 0,\n height: 0\n })\n } : childNode,\n popperRef: popperRef,\n open: childNode ? open : false,\n id: id,\n transition: true\n }, interactiveWrapperListeners, popperProps, {\n popperOptions: popperOptions,\n children: ({\n TransitionProps: TransitionPropsInner\n }) => /*#__PURE__*/_jsx(TransitionComponent, _extends({\n timeout: theme.transitions.duration.shorter\n }, TransitionPropsInner, transitionProps, {\n children: /*#__PURE__*/_jsxs(TooltipComponent, _extends({}, tooltipProps, {\n children: [title, arrow ? /*#__PURE__*/_jsx(ArrowComponent, _extends({}, tooltipArrowProps, {\n ref: setArrowRef\n })) : null]\n }))\n }))\n }))]\n });\n});\nprocess.env.NODE_ENV !== \"production\" ? Tooltip.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the d.ts file and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * If `true`, adds an arrow to the tooltip.\n * @default false\n */\n arrow: PropTypes.bool,\n /**\n * Tooltip reference element.\n */\n children: elementAcceptingRef.isRequired,\n /**\n * Override or extend the styles applied to the component.\n */\n classes: PropTypes.object,\n /**\n * @ignore\n */\n className: PropTypes.string,\n /**\n * The components used for each slot inside.\n *\n * This prop is an alias for the `slots` prop.\n * It's recommended to use the `slots` prop instead.\n *\n * @default {}\n */\n components: PropTypes.shape({\n Arrow: PropTypes.elementType,\n Popper: PropTypes.elementType,\n Tooltip: PropTypes.elementType,\n Transition: PropTypes.elementType\n }),\n /**\n * The extra props for the slot components.\n * You can override the existing props or add new ones.\n *\n * This prop is an alias for the `slotProps` prop.\n * It's recommended to use the `slotProps` prop instead, as `componentsProps` will be deprecated in the future.\n *\n * @default {}\n */\n componentsProps: PropTypes.shape({\n arrow: PropTypes.object,\n popper: PropTypes.object,\n tooltip: PropTypes.object,\n transition: PropTypes.object\n }),\n /**\n * Set to `true` if the `title` acts as an accessible description.\n * By default the `title` acts as an accessible label for the child.\n * @default false\n */\n describeChild: PropTypes.bool,\n /**\n * Do not respond to focus-visible events.\n * @default false\n */\n disableFocusListener: PropTypes.bool,\n /**\n * Do not respond to hover events.\n * @default false\n */\n disableHoverListener: PropTypes.bool,\n /**\n * Makes a tooltip not interactive, i.e. it will close when the user\n * hovers over the tooltip before the `leaveDelay` is expired.\n * @default false\n */\n disableInteractive: PropTypes.bool,\n /**\n * Do not respond to long press touch events.\n * @default false\n */\n disableTouchListener: PropTypes.bool,\n /**\n * The number of milliseconds to wait before showing the tooltip.\n * This prop won't impact the enter touch delay (`enterTouchDelay`).\n * @default 100\n */\n enterDelay: PropTypes.number,\n /**\n * The number of milliseconds to wait before showing the tooltip when one was already recently opened.\n * @default 0\n */\n enterNextDelay: PropTypes.number,\n /**\n * The number of milliseconds a user must touch the element before showing the tooltip.\n * @default 700\n */\n enterTouchDelay: PropTypes.number,\n /**\n * If `true`, the tooltip follow the cursor over the wrapped element.\n * @default false\n */\n followCursor: PropTypes.bool,\n /**\n * This prop is used to help implement the accessibility logic.\n * If you don't provide this prop. It falls back to a randomly generated id.\n */\n id: PropTypes.string,\n /**\n * The number of milliseconds to wait before hiding the tooltip.\n * This prop won't impact the leave touch delay (`leaveTouchDelay`).\n * @default 0\n */\n leaveDelay: PropTypes.number,\n /**\n * The number of milliseconds after the user stops touching an element before hiding the tooltip.\n * @default 1500\n */\n leaveTouchDelay: PropTypes.number,\n /**\n * Callback fired when the component requests to be closed.\n *\n * @param {React.SyntheticEvent} event The event source of the callback.\n */\n onClose: PropTypes.func,\n /**\n * Callback fired when the component requests to be open.\n *\n * @param {React.SyntheticEvent} event The event source of the callback.\n */\n onOpen: PropTypes.func,\n /**\n * If `true`, the component is shown.\n */\n open: PropTypes.bool,\n /**\n * Tooltip placement.\n * @default 'bottom'\n */\n placement: PropTypes.oneOf(['bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n /**\n * The component used for the popper.\n * @default Popper\n */\n PopperComponent: PropTypes.elementType,\n /**\n * Props applied to the [`Popper`](/material-ui/api/popper/) element.\n * @default {}\n */\n PopperProps: PropTypes.object,\n /**\n * The extra props for the slot components.\n * You can override the existing props or add new ones.\n *\n * This prop is an alias for the `componentsProps` prop, which will be deprecated in the future.\n *\n * @default {}\n */\n slotProps: PropTypes.shape({\n arrow: PropTypes.object,\n popper: PropTypes.object,\n tooltip: PropTypes.object,\n transition: PropTypes.object\n }),\n /**\n * The components used for each slot inside.\n *\n * This prop is an alias for the `components` prop, which will be deprecated in the future.\n *\n * @default {}\n */\n slots: PropTypes.shape({\n arrow: PropTypes.elementType,\n popper: PropTypes.elementType,\n tooltip: PropTypes.elementType,\n transition: PropTypes.elementType\n }),\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Tooltip title. Zero-length titles string, undefined, null and false are never displayed.\n */\n title: PropTypes.node,\n /**\n * The component used for the transition.\n * [Follow this guide](/material-ui/transitions/#transitioncomponent-prop) to learn more about the requirements for this component.\n * @default Grow\n */\n TransitionComponent: PropTypes.elementType,\n /**\n * Props applied to the transition element.\n * By default, the element is based on this [`Transition`](http://reactcommunity.org/react-transition-group/transition/) component.\n */\n TransitionProps: PropTypes.object\n} : void 0;\nexport default Tooltip;","import '@/components/mui/menu-item.component.css';\nimport ArrowRightIcon from '@mui/icons-material/ArrowRight';\nimport {\n ListItemIcon as MuiListItemIcon,\n ListItemText as MuiListItemText,\n MenuItem as MuiMenuItem,\n} from '@mui/material';\nimport Tooltip from '@mui/material/Tooltip';\nimport { Localized, ReferencedItem, SingleColumnMenu } from 'platform-bible-utils';\nimport { MouseEvent, PropsWithChildren } from 'react';\n\ntype MenuItemInfoBase = {\n /** Text (displayable in the UI) as the name of the menu item */\n label: string;\n /** Text to display when the mouse hovers over the menu item */\n tooltip?: string;\n};\n\nexport type Command = MenuItemInfoBase & {\n /** Command to execute (string.string) */\n command: string;\n};\n\ntype SubMenu = MenuItemInfoBase & {\n /** Command to execute (string.string) */\n items: MenuItemInfo[];\n};\n\nexport interface CommandHandler {\n (command: Command): void;\n}\n\nexport type MenuPropsBase = {\n /*\n * The JSON defining the menu whose items are to be rendered. This will typically be one of the\n * menus in the \"defs\" in a Platform.Bible menu (see PlatformMenus). The schema for this is\n * menuDocumentSchema (at the end of menus.model.ts). Note that while this is a\n * \"SingleColumnMenu\", somewhat bizarrely, a MultiColumnMenu is a SingleColumnMenu, so it really\n * could be a MultiColumnMenu, in which case, column had better be defined so it can be used\n * to filter out the actual groups and items to display on the column.\n */\n menuDefinition: Localized;\n\n commandHandler: CommandHandler;\n\n /**\n * Additional action to perform when any menu item is clicked. Allows the caller to handle event\n * (e.g., to close the menu).\n */\n onClick?: (event: MouseEvent) => void;\n};\n\nexport type MenuItemListProps = MenuPropsBase & {\n /** Optional unique (column) identifier */\n columnId?: ReferencedItem;\n};\n\nexport type MenuItemProps = Omit &\n PropsWithChildren<{\n /** Optional unique identifier */\n id?: string;\n\n onClick: (event: MouseEvent) => void;\n }>;\n\ntype MenuItemInfo = (Command | SubMenu) & {\n /**\n * If specified, menu item will be inset if it does not have a leading icon.\n *\n * @default true\n */\n allowForLeadingIcons?: boolean;\n /**\n * If specified, the path to the icon image to display on the leading side of the menu text.\n *\n * @default undefined (no leading icon will be shown)\n */\n iconPathBefore?: string;\n /**\n * If specified, the path to the icon image to display on the trailing side of the menu text.\n *\n * @default undefined (no trailing icon will be shown)\n */\n iconPathAfter?: string;\n /**\n * If true, list item is focused during the first mount\n *\n * @default false\n */\n hasAutoFocus?: boolean;\n\n /** Additional css classes to help with unique styling of the menu item */\n className?: string;\n\n /**\n * If true, the menu item will appear disabled and it will not respond to clicks or mouse hovers.\n *\n * @default false\n */\n isDisabled?: boolean;\n\n /**\n * If true, compact vertical padding designed for keyboard and mouse input is used.\n *\n * @default true\n */\n isDense?: boolean;\n\n /**\n * If true, a right-arrow icon will be displayed (iconPathAfter, if specified, will be ignored).\n *\n * @default false\n */\n isSubMenuParent?: boolean;\n\n /**\n * If true, the left and right padding is removed\n *\n * @default false\n */\n hasDisabledGutters?: boolean;\n\n /**\n * If true, a 1px light border is added to bottom of menu item\n *\n * @default false\n */\n hasDivider?: boolean;\n\n /** Help identify which element has keyboard focus */\n focusVisibleClassName?: string;\n\n /** If it's a submenu, it should have the items property */\n items?: MenuItemInfo[];\n};\n\nfunction getIcon(icon: string | undefined, menuLabel: string, leading: boolean) {\n return icon ? (\n \n {`${leading\n \n ) : undefined;\n}\n\nexport default function MenuItem(props: MenuItemProps) {\n const {\n onClick,\n label,\n tooltip,\n allowForLeadingIcons = true,\n iconPathBefore = undefined,\n iconPathAfter = undefined,\n hasAutoFocus = false,\n className,\n isDisabled = false,\n isDense = true,\n isSubMenuParent = false,\n hasDisabledGutters = false,\n hasDivider = false,\n focusVisibleClassName,\n id,\n children,\n } = props;\n\n const menuItem = (\n \n {label ? (\n <>\n {getIcon(iconPathBefore, label, true)}\n \n {isSubMenuParent ? (\n \n \n \n ) : (\n getIcon(iconPathAfter, label, false)\n )}\n \n ) : (\n children\n )}\n \n );\n\n return tooltip ? (\n \n
    {menuItem}
    \n
    \n ) : (\n menuItem\n );\n}\n","import MenuItem, {\n MenuItemListProps,\n MenuItemProps,\n MenuPropsBase,\n} from '@/components/mui/menu-item.component';\nimport { Menu } from '@mui/material';\nimport {\n Localized,\n MenuGroupDetailsInSubMenu,\n MenuItemContainingCommand,\n MenuItemContainingSubmenu,\n OrderedExtensibleContainer,\n ReferencedItem,\n SingleColumnMenu,\n} from 'platform-bible-utils';\nimport { MouseEvent, useMemo, useState } from 'react';\n\n/**\n * All the exported types in this file should be regarded as \"internal\" (i.e., they should not be\n * exposed via index.ts).\n */\n\nexport type GroupedMenuPropsBase = MenuPropsBase & {\n /** Optional unique (column) identifier */\n columnId?: ReferencedItem;\n};\n\nexport type GroupedMenuItemListProps = MenuItemListProps & {\n /**\n * If the menuDefinition includes \"top-level\" groups (i.e., those that belong to a column as\n * opposed to those that belong to a submenu) that should not be included in the list, then this\n * array specifies which groups to include. Likewise, for a submenu, this list indicates which\n * groups are pertinent for that submenu. So then for a context menu this property need not be\n * specified since it is a top-level menu based on a \"true\" SingleColumnMenu (i.e., one that is\n * not a MultiColumnMenu).\n */\n includedGroups?: {\n id: string;\n group: Localized;\n }[];\n};\n\ninterface ItemInfo {\n item: Localized;\n isLastItemInGroup: boolean;\n}\n\ntype SubMenuProps = MenuPropsBase & {\n parentMenuItem: Localized;\n parentItemProps: Omit, 'iconPathAfter'>;\n};\n\nfunction getAllGroups(menuDefinition: Localized) {\n const groupEntries = Object.entries(menuDefinition.groups);\n // Convert array of entries to array of objects with id and group properties\n return groupEntries.map(([key, value]) => ({ id: key, group: value }));\n}\n\nfunction SubMenu(props: SubMenuProps) {\n const [anchorEl, setAnchorEl] = useState(undefined);\n\n const { parentMenuItem, parentItemProps, menuDefinition } = props;\n\n const handleParentMenuItemClick = (event: MouseEvent) => {\n setAnchorEl(event.currentTarget);\n };\n\n const handleClose = () => {\n setAnchorEl(undefined);\n };\n\n const renderSubMenuItems = () => {\n let includedGroups = getAllGroups(menuDefinition).filter((g) => 'menuItem' in g.group);\n\n // Ensure valid parent menu was provided. (If not, submenu will contain all groups!)\n if (!parentMenuItem?.id) throw new Error('A valid parent menu item is required for submenus.');\n\n // When laying out a submenu, only include groups associated with the provided parent menu.\n // Note: without the (annoying) redundant check that the included groups\n // have the menuItem field, TS doesn't think it exists.\n includedGroups = includedGroups.filter(\n (group) => 'menuItem' in group.group && group.group.menuItem === parentMenuItem.id,\n );\n\n return ;\n };\n\n return (\n <>\n \n \n {renderSubMenuItems()}\n \n \n );\n}\n\nconst getOrderedGroupItems = (\n groupId: string,\n allItems: Localized[],\n) => {\n // Filter items that belong to the specified group\n const itemsForGroup = allItems.filter((item) => item.group === groupId);\n // Sort items based on order\n const sortedItems = itemsForGroup.sort((a, b) => (a.order || 0) - (b.order || 0));\n return sortedItems;\n};\n\n/**\n * This component is internal; it does not need to be exposed to the outside world since it is not\n * useful on its own. It is used to generate and lay out the MenuItems that appear either on a\n * top-level menu (in a GridMenu or ContextMenu) or in a submenu.\n */\nexport default function GroupedMenuItemList(menuProps: GroupedMenuItemListProps) {\n const { menuDefinition, onClick, commandHandler, includedGroups } = menuProps;\n\n const { items, allowForLeadingIcons } = useMemo(() => {\n const groupsToInclude =\n includedGroups && includedGroups.length > 0\n ? includedGroups\n : // We're apparently laying out a single-column menu (presumably a context menu). In this\n // case, all groups should be included except ones that belong to a submenu.\n getAllGroups(menuDefinition).filter((g) => !('menuItem' in g.group));\n\n const sortedGroups = Object.values(groupsToInclude).sort(\n (a, b) => (a.group.order || 0) - (b.group.order || 0),\n );\n\n const itemArray: ItemInfo[] = [];\n\n sortedGroups.forEach((group) => {\n getOrderedGroupItems(group.id, menuDefinition.items).forEach((item) =>\n itemArray.push({ item, isLastItemInGroup: false }),\n );\n if (itemArray.length > 0) itemArray[itemArray.length - 1].isLastItemInGroup = true;\n });\n\n // No divider after last item in final group.\n if (itemArray.length > 0) itemArray[itemArray.length - 1].isLastItemInGroup = false;\n\n const allowSpaceForLeadingIcons = itemArray.some(\n (i) => 'iconPathBefore' in i.item && i.item.iconPathBefore,\n );\n\n return { items: itemArray, allowForLeadingIcons: allowSpaceForLeadingIcons };\n }, [includedGroups, menuDefinition]);\n\n // Create props for MenuItem component including setting hasDivider for the last item in a group\n const createMenuItemProps = ({ item, isLastItemInGroup }: ItemInfo) => {\n const menuItemProps = {\n className: 'papi-menu-item',\n label: item.label,\n tooltip: item.tooltip,\n iconPathBefore: 'iconPathBefore' in item ? item.iconPathBefore : undefined,\n iconPathAfter: 'iconPathAfter' in item ? item.iconPathAfter : undefined,\n hasDivider: isLastItemInGroup, // Set hasDivider to true for the last item in a group\n allowForLeadingIcons,\n };\n\n return menuItemProps;\n };\n\n const [firstItem] = items;\n\n if (!firstItem) return
    ;\n\n const divKey = firstItem.item.group;\n\n return (\n
    \n {items.map((itemInfo, index) => {\n const { item } = itemInfo;\n const menuItemProps = createMenuItemProps(itemInfo);\n if ('command' in item) {\n const key = item.group + index;\n return (\n ) => {\n onClick?.(event);\n commandHandler(item);\n }}\n {...menuItemProps}\n />\n );\n }\n return (\n \n );\n })}\n
    \n );\n}\n","import GroupedMenuItemList from '@/components/mui/grouped-menu-item-list.component';\nimport { MenuItemListProps } from '@/components/mui/menu-item.component';\nimport { MultiColumnMenu } from 'platform-bible-utils';\n\n/**\n * This component is internal; it does not need to be exposed to the outside world since it is not\n * useful on its own. Use either GridMenu or ContextMenu.\n */\nexport default function TopLevelMenu(props: MenuItemListProps) {\n const { menuDefinition, columnId } = props;\n\n const groupEntries = Object.entries(menuDefinition.groups);\n // Convert array of entries to array of objects with id and group properties\n const groups = groupEntries.map(([key, value]) => ({ id: key, group: value }));\n let includedGroups = groups.filter((g) => 'column' in g.group);\n\n // Check if column is provided and menuDefinition is a MultiColumnMenu\n if (\n columnId &&\n 'columns' in menuDefinition &&\n // Without this type assertion, TS doesn't know what columns is.\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n (menuDefinition as MultiColumnMenu).columns[columnId]\n ) {\n // When laying out a single column in a MultiColumnMenu, only include groups associated with\n // the provided column. Note: without the (annoying) redundant check that the included groups\n // have the colum field, TS doesn't think it exists.\n includedGroups = includedGroups.filter(\n (g) => 'column' in g.group && g.group.column === columnId,\n );\n }\n\n return ;\n}\n","import '@/components/mui/grid-menu.component.css';\nimport { GroupedMenuPropsBase } from '@/components/mui/grouped-menu-item-list.component';\nimport { CommandHandler } from '@/components/mui/menu-item.component';\nimport TopLevelMenu from '@/components/mui/top-level-menu.component';\nimport { Grid, List } from '@mui/material';\nimport {\n Localized,\n MenuColumnWithHeader,\n MultiColumnMenu,\n ReferencedItem,\n} from 'platform-bible-utils';\nimport { useMemo } from 'react';\n\ntype ColumnInfo = {\n /*\n * The ID (`${string}.${string}`) of a specific menu column.\n */\n id: ReferencedItem;\n\n /*\n * Metadata (label, order, etc.) for a specific menu column.\n */\n metadata: Localized;\n};\n\ntype MenuColumnProps = ColumnInfo &\n GroupedMenuPropsBase & {\n /** Additional css classes to help with unique styling of the menu column */\n className?: string;\n };\n\nexport type GridMenuInfo = {\n /** The menu object containing information about the columns, groups, and items to display. */\n multiColumnMenu: Localized;\n};\n\nexport type GridMenuProps = GridMenuInfo & {\n /** Optional unique identifier */\n id?: string;\n\n commandHandler: CommandHandler;\n\n /** Additional css classes to help with unique styling of the grid menu */\n className?: string;\n};\n\nfunction MenuColumn({\n commandHandler,\n menuDefinition,\n id,\n metadata,\n onClick,\n className,\n}: MenuColumnProps) {\n return (\n \n

    \n {metadata.label}\n

    \n {/* It would seem as though this List component were unnecessary, since it only contains one\n thing, but the \"dense\" property does affect the layout of the items (in a way I don't fully\n understand). There might be a better way. */}\n \n \n \n \n );\n}\n\nexport default function GridMenu({\n commandHandler,\n className,\n multiColumnMenu,\n id,\n}: GridMenuProps) {\n const { columns } = multiColumnMenu;\n\n const sortedColumns = useMemo(() => {\n const columnNumbers = new Map();\n Object.getOwnPropertyNames(columns).forEach((columnName: string) => {\n // We know for sure there is a (boolean) property 'isExtensible' that we are not interested in.\n if (columnName === 'isExtensible') return;\n // TS doesn't allow `columnName` above to be a ReferencedItem even though the type says it is\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const columnId = columnName as ReferencedItem;\n const column = columns[columnId];\n // As of right now (and hopefully forever after), all remaining properties of the\n // ColumnsWithHeaders object are columns whose property names are the IDs of the columns.\n // This is an additional (redundant) sanity check. Specifically we're interested in\n // MenuColumnWithHeader objects, which TypeScript now \"knows\" we have, but at runtime all we\n // can check for is that it's an object with a valid numeric order field. That's likely good\n // enough.\n if (\n typeof column === 'object' &&\n typeof column.order === 'number' &&\n !Number.isNaN(column.order)\n )\n columnNumbers.set(column.order, { id: columnId, metadata: column });\n else\n console.warn(\n `Property ${columnName} (${typeof column}) on menu ${id} is not a valid column and is being ignored. This might indicate data corruption`,\n );\n });\n\n // Extract values and sort them based on the 'order' property\n return Array.from(columnNumbers.values()).sort((a, b) => {\n return (a.metadata.order || 0) - (b.metadata.order || 0);\n });\n }, [columns, id]);\n\n // We might need something like this if we need to be able to prevent empty columns\n // sortedColumns.filter((c) => multiColumnMenu.groups.some((g) => 'column' in g && (g as .column)...\n\n return (\n \n {sortedColumns.map((col, index) => (\n \n ))}\n \n );\n}\n","import { useEffect, useRef, useState } from 'react';\n\nexport type UsePromiseOptions = {\n /**\n * Whether to leave the value as the most recent resolved promise value or set it back to\n * defaultValue while running the promise again. Defaults to true\n */\n preserveValue?: boolean;\n};\n\n/** Set up defaults for options for usePromise hook */\nfunction getUsePromiseOptionsDefaults(options: UsePromiseOptions): UsePromiseOptions {\n return {\n preserveValue: true,\n ...options,\n };\n}\n\n/**\n * Awaits a promise and returns a loading value while the promise is unresolved\n *\n * @param promiseFactoryCallback A function that returns the promise to await. If this callback is\n * undefined, the current value will be returned (defaultValue unless it was previously changed\n * and `options.preserveValue` is true), and there will be no loading.\n *\n * WARNING: MUST BE STABLE - const or wrapped in useCallback. The reference must not be updated\n * every render\n * @param defaultValue The initial value to return while first awaiting the promise. If\n * `options.preserveValue` is false, this value is also shown while awaiting the promise on\n * subsequent calls.\n *\n * Note: this parameter is internally assigned to a `ref`, so changing it will not cause any hooks\n * to re-run with its new value. This means that, if the `promiseFactoryCallback` changes and\n * `options.preserveValue` is `false`, the returned value will be set to the current\n * `defaultValue`. However, the returned value will not be updated if`defaultValue` changes.\n * @param options Various options for adjusting how this hook runs the `promiseFactoryCallback`\n *\n * Note: this parameter is internally assigned to a `ref`, so changing it will not cause any hooks\n * to re-run with its new value. However, the latest `options.preserveValue` will always be used\n * appropriately to determine whether to preserve the returned value when changing the\n * `promiseFactoryCallback`\n * @returns `[value, isLoading]`\n *\n * - `value`: the current value for the promise, either the defaultValue or the resolved promise value\n * - `isLoading`: whether the promise is waiting to be resolved\n */\nconst usePromise = (\n promiseFactoryCallback: (() => Promise) | undefined,\n defaultValue: T,\n options: UsePromiseOptions = {},\n): [value: T, isLoading: boolean] => {\n // Use defaultValue as a ref so it doesn't update dependency arrays\n const defaultValueRef = useRef(defaultValue);\n defaultValueRef.current = defaultValue;\n // Use options as a ref so it doesn't update dependency arrays\n const optionsDefaultedRef = useRef(options);\n optionsDefaultedRef.current = getUsePromiseOptionsDefaults(optionsDefaultedRef.current);\n\n const [value, setValue] = useState(() => defaultValueRef.current);\n const [isLoading, setIsLoading] = useState(true);\n useEffect(() => {\n let promiseIsCurrent = true;\n // If a promiseFactoryCallback was provided, we are loading. Otherwise, there is no loading to do\n setIsLoading(!!promiseFactoryCallback);\n (async () => {\n // If there is a callback to run, run it\n if (promiseFactoryCallback) {\n const result = await promiseFactoryCallback();\n // If the promise was not already replaced, update the value\n if (promiseIsCurrent) {\n setValue(() => result);\n setIsLoading(false);\n }\n }\n })();\n\n return () => {\n // Mark this promise as old and not to be used\n promiseIsCurrent = false;\n if (!optionsDefaultedRef.current.preserveValue) setValue(() => defaultValueRef.current);\n };\n }, [promiseFactoryCallback]);\n\n return [value, isLoading];\n};\nexport default usePromise;\n","\"use client\";\n\nimport createSvgIcon from './utils/createSvgIcon';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nexport default createSvgIcon( /*#__PURE__*/_jsx(\"path\", {\n d: \"M3 18h18v-2H3zm0-5h18v-2H3zm0-7v2h18V6z\"\n}), 'Menu');","import GridMenu from '@/components/mui/grid-menu.component';\nimport { Command, CommandHandler } from '@/components/mui/menu-item.component';\nimport usePromise from '@/hooks/use-promise.hook';\nimport { Menu as MenuIcon } from '@mui/icons-material';\nimport { Drawer, IconButton } from '@mui/material';\nimport { Localized, MultiColumnMenu } from 'platform-bible-utils';\nimport {\n MouseEvent,\n MutableRefObject,\n PropsWithChildren,\n useCallback,\n useEffect,\n useState,\n} from 'react';\n\nexport interface MultiColumnMenuProvider {\n (isSupportAndDevelopment: boolean): Promise>;\n}\n\nexport type HamburgerMenuButtonProps = PropsWithChildren & {\n /** The handler to use for menu commands (and eventually toolbar commands). */\n commandHandler: CommandHandler;\n\n /**\n * Optional reference to the \"div\" container that determines the where the menu should appear. If\n * not defined, then (1,1) used.\n */\n containerRef?: MutableRefObject;\n\n /**\n * The delegate to use to get the menu data. If not specified or if it returns undefined, the data\n * in normalMenu or fullMenu property will be used.\n */\n menuProvider?: MultiColumnMenuProvider;\n\n /**\n * The menu data to show when the menu is opened if the menuProvider property is not defined.\n * (This allows for a default or test-only static menu to be used.)\n */\n normalMenu?: Localized;\n\n /**\n * The menu data to show for \"full\" menu (when opened with the SHIFT key pressed) if the\n * menuProvider property is not defined. (This allows for a default or test-only static menu to be\n * used.)\n */\n fullMenu?: Localized;\n\n /** Additional css class(es) to help with unique styling of the sub-components */\n className?: string;\n\n /** Value to use as prefix for ARIA labels on interactive sub-components */\n ariaLabelPrefix?: string;\n};\n\nexport default function HamburgerMenuButton({\n menuProvider,\n normalMenu,\n fullMenu,\n commandHandler,\n containerRef,\n className,\n ariaLabelPrefix,\n children,\n}: HamburgerMenuButtonProps) {\n const [isMenuOpen, setMenuOpen] = useState(false);\n const [showFullMenu, setShowFullMenu] = useState(false);\n\n const handleMenuItemClick = useCallback(() => {\n if (isMenuOpen) setMenuOpen(false);\n setShowFullMenu(false);\n }, [isMenuOpen]);\n\n const handleMenuButtonClick = useCallback((e: MouseEvent) => {\n e.stopPropagation();\n setMenuOpen((prevIsOpen) => {\n const isOpening = !prevIsOpen;\n if (isOpening && e.shiftKey) setShowFullMenu(true);\n else if (!isOpening) setShowFullMenu(false);\n return isOpening;\n });\n }, []);\n\n const menuCommandHandler = useCallback(\n (command: Command) => {\n handleMenuItemClick();\n return commandHandler(command);\n },\n [commandHandler, handleMenuItemClick],\n );\n\n const [offset, setOffset] = useState({ top: 1, left: 1 });\n\n useEffect(() => {\n if (isMenuOpen) {\n const node = containerRef?.current;\n if (node) {\n const rect = node.getBoundingClientRect();\n const scrollTop = window.scrollY;\n const scrollLeft = window.scrollX;\n const top = rect.top + scrollTop + node.clientHeight;\n const left = rect.left + scrollLeft;\n setOffset({ top, left });\n }\n }\n }, [isMenuOpen, containerRef]);\n\n const [normalMenuData] = usePromise(\n useCallback(async () => {\n return menuProvider?.(false) ?? normalMenu;\n // isMenuOpen needs to be included for the menu contents to reevaluate when reopened\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [menuProvider, normalMenu, isMenuOpen]),\n normalMenu,\n );\n\n const [fullMenuData] = usePromise(\n useCallback(async () => {\n return menuProvider?.(true) ?? fullMenu ?? normalMenuData;\n // isMenuOpen needs to be included for the menu contents to reevaluate when reopened\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [menuProvider, fullMenu, normalMenuData, isMenuOpen]),\n fullMenu ?? normalMenuData,\n );\n\n const menu = showFullMenu && fullMenuData ? fullMenuData : normalMenuData;\n\n return (\n <>\n \n {children ?? }\n \n \n {menu ? (\n \n ) : undefined}\n \n \n );\n}\n","import '@/components/mui/icon-button.component.css';\nimport { IconButton as MuiIconButton } from '@mui/material';\nimport { MouseEventHandler, PropsWithChildren } from 'react';\n\nexport type IconButtonProps = PropsWithChildren<{\n /** Optional unique identifier */\n id?: string;\n /**\n * Required. Used as both the tooltip (aka, title) and the aria-label (used for accessibility,\n * testing, etc.), unless a distinct tooltip is supplied.\n */\n label: string;\n /**\n * Enabled status of button\n *\n * @default false\n */\n isDisabled?: boolean;\n /** Optional tooltip to display if different from the aria-label. */\n tooltip?: string;\n /** If true, no tooltip will be displayed. */\n isTooltipSuppressed?: boolean;\n /**\n * If given, uses a negative margin to counteract the padding on one side (this is often helpful\n * for aligning the left or right side of the icon with content above or below, without ruining\n * the border size and shape).\n *\n * @default false\n */\n adjustMarginToAlignToEdge?: 'end' | 'start' | false;\n /**\n * The size of the component. small is equivalent to the dense button styling.\n *\n * @default false\n */\n size: 'small' | 'medium' | 'large';\n /** Additional css classes to help with unique styling of the button */\n className?: string;\n /** Optional click handler */\n onClick?: MouseEventHandler;\n}>;\n\n/**\n * Iconic button a user can click to do something\n *\n * Thanks to MUI for heavy inspiration and documentation\n * https://mui.com/material-ui/getting-started/overview/\n */\nfunction IconButton({\n id,\n label,\n isDisabled = false,\n tooltip,\n isTooltipSuppressed = false,\n adjustMarginToAlignToEdge = false,\n size = 'medium',\n className,\n onClick,\n children,\n}: IconButtonProps) {\n return (\n \n {children /* the icon to display */}\n \n );\n}\n\nexport default IconButton;\n","import { cn } from '@/utils/shadcn-ui.util';\nimport { LoaderCircle, LucideProps } from 'lucide-react';\nimport { forwardRef } from 'react';\n\nexport type SpinnerProps = LucideProps;\n\nconst Spinner = forwardRef(({ className, ...props }, ref) => {\n return (\n \n );\n});\n\nSpinner.displayName = 'Spinner';\n\nexport default Spinner;\n","import { Input as ShadInput } from '@/components/shadcn-ui/input';\nimport { Label as ShadLabel } from '@/components/shadcn-ui/label';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { ChangeEventHandler, FocusEventHandler } from 'react';\n\nexport type TextFieldProps = {\n /** Optional unique identifier */\n id?: string;\n /**\n * If `true`, the component is disabled.\n *\n * @default false\n */\n isDisabled?: boolean;\n /**\n * If `true`, the label is displayed in an error state.\n *\n * @default false\n */\n hasError?: boolean;\n /**\n * If `true`, the input will take up the full width of its container.\n *\n * @default false\n */\n isFullWidth?: boolean;\n /** Text that gives the user instructions on what contents the TextField expects */\n helperText?: string;\n /** The title of the TextField */\n label?: string;\n /** The short hint displayed in the `input` before the user enters a value. */\n placeholder?: string;\n /**\n * If `true`, the label is displayed as required and the `input` element is required.\n *\n * @default false\n */\n isRequired?: boolean;\n /** Additional css classes to help with unique styling of the text field */\n className?: string;\n /** Starting value for the text field if it is not controlled */\n defaultValue?: string | number;\n /** Value of the text field if controlled */\n value?: string | number;\n /** Triggers when content of textfield is changed */\n onChange?: ChangeEventHandler;\n /** Triggers when textfield gets focus */\n onFocus?: FocusEventHandler;\n /** Triggers when textfield loses focus */\n onBlur?: FocusEventHandler;\n};\n\n/**\n * Text input field\n *\n * Thanks to Shadcn for heavy inspiration and documentation\n * https://ui.shadcn.com/docs/components/input#with-label\n */\nfunction TextField({\n id,\n isDisabled = false,\n hasError = false,\n isFullWidth = false,\n helperText,\n label,\n placeholder,\n isRequired = false,\n className,\n defaultValue,\n value,\n onChange,\n onFocus,\n onBlur,\n}: TextFieldProps) {\n return (\n
    \n {`${label}${isRequired ? '*' : ''}`}\n \n

    {helperText}

    \n
    \n );\n}\n\nexport default TextField;\n","import HamburgerMenuButton, {\n MultiColumnMenuProvider,\n} from '@/components/mui/hamburger-menu-button.component';\nimport { CommandHandler } from '@/components/mui/menu-item.component';\nimport '@/components/mui/toolbar.component.css';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { AppBar, Toolbar as MuiToolbar } from '@mui/material';\nimport { PropsWithChildren, useRef } from 'react';\n\nexport type ToolbarProps = PropsWithChildren<{\n /** The handler to use for menu commands (and eventually toolbar commands). */\n commandHandler: CommandHandler;\n\n /**\n * The optional delegate to use to get the menu data. If not specified, the \"hamburger\" menu will\n * not display.\n */\n menuProvider?: MultiColumnMenuProvider;\n\n /** Optional unique identifier */\n id?: string;\n\n /** Additional css classes to help with unique styling of the toolbar */\n className?: string;\n}>;\n\nexport default function Toolbar({\n menuProvider,\n commandHandler,\n className,\n id,\n children,\n}: ToolbarProps) {\n // This ref will always be defined\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const containerRef = useRef(undefined!);\n\n return (\n
    \n \n \n {menuProvider ? (\n \n ) : undefined}\n {children ?
    {children}
    : undefined}\n \n
    \n
    \n );\n}\n","import React from 'react';\nimport { cva, type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst alertVariants = cva(\n 'tw-relative tw-w-full tw-rounded-lg tw-border tw-p-4 [&>svg~*]:tw-pl-7 [&>svg+div]:tw-translate-y-[-3px] [&>svg]:tw-absolute [&>svg]:tw-left-4 [&>svg]:tw-top-4 [&>svg]:tw-text-foreground',\n {\n variants: {\n variant: {\n default: 'tw-bg-background tw-text-foreground',\n destructive:\n 'tw-border-destructive/50 tw-text-destructive dark:tw-border-destructive [&>svg]:tw-text-destructive',\n },\n },\n defaultVariants: {\n variant: 'default',\n },\n },\n);\n\nconst Alert = React.forwardRef<\n HTMLDivElement,\n React.HTMLAttributes & VariantProps\n>(({ className, variant, ...props }, ref) => (\n
    \n));\nAlert.displayName = 'Alert';\n\nconst AlertTitle = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n {/* added because of https://github.com/jsx-eslint/eslint-plugin-jsx-a11y/blob/main/docs/rules/heading-has-content.md */}\n {props.children}{' '}\n \n ),\n);\nAlertTitle.displayName = 'AlertTitle';\n\nconst AlertDescription = React.forwardRef<\n HTMLParagraphElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n
    \n));\nAlertDescription.displayName = 'AlertDescription';\n\nexport { Alert, AlertTitle, AlertDescription };\n","import React from 'react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Card = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nCard.displayName = 'Card';\n\nconst CardHeader = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nCardHeader.displayName = 'CardHeader';\n\nconst CardTitle = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n {/* added because of https://github.com/jsx-eslint/eslint-plugin-jsx-a11y/blob/main/docs/rules/heading-has-content.md */}\n {props.children}\n \n ),\n);\nCardTitle.displayName = 'CardTitle';\n\nconst CardDescription = React.forwardRef<\n HTMLParagraphElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n

    \n));\nCardDescription.displayName = 'CardDescription';\n\nconst CardContent = React.forwardRef>(\n ({ className, ...props }, ref) => (\n

    \n ),\n);\nCardContent.displayName = 'CardContent';\n\nconst CardFooter = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nCardFooter.displayName = 'CardFooter';\n\nexport { Card, CardHeader, CardFooter, CardTitle, CardDescription, CardContent };\n","import { ComponentProps } from 'react';\nimport { toast as sonner, Toaster } from 'sonner';\n\ntype SonnerProps = ComponentProps;\n\nfunction Sonner({ ...props }: SonnerProps) {\n return (\n \n );\n}\n\n// The re-export of the sonner function was added manually\nexport { Sonner, sonner };\n","import React from 'react';\nimport * as SliderPrimitive from '@radix-ui/react-slider';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Slider = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n \n \n \n));\nSlider.displayName = SliderPrimitive.Root.displayName;\n\nexport { Slider };\n","import React from 'react';\nimport * as SwitchPrimitives from '@radix-ui/react-switch';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Switch = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n));\nSwitch.displayName = SwitchPrimitives.Root.displayName;\n\nexport { Switch };\n","import React from 'react';\nimport * as TabsPrimitive from '@radix-ui/react-tabs';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport const Tabs = TabsPrimitive.Root;\n\nexport type TabsListProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport type TabsTriggerProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport type TabsContentProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport const TabsList = React.forwardRef<\n React.ElementRef,\n TabsListProps\n>(({ className, ...props }, ref) => (\n \n));\nTabsList.displayName = TabsPrimitive.List.displayName;\n\nexport const TabsTrigger = React.forwardRef<\n React.ElementRef,\n TabsTriggerProps\n>(({ className, ...props }, ref) => (\n \n));\nTabsTrigger.displayName = TabsPrimitive.Trigger.displayName;\n\nexport const TabsContent = React.forwardRef<\n React.ElementRef,\n TabsContentProps\n>(({ className, ...props }, ref) => (\n \n));\nTabsContent.displayName = TabsPrimitive.Content.displayName;\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Download } from 'lucide-react';\n\ntype InstallButtonProps = {\n /** The installing boolean value determines the state of the button. */\n isInstalling: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n /** Optional text for the button. */\n buttonText?: string;\n} & ButtonProps;\n\n/**\n * The InstallButton component is a button designed for initiating installs. It includes visuals for\n * active installing and idle states.\n *\n * @param isInstalling The installing boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @param buttonText Optional text for the button.\n * @returns A install button.\n */\nexport default function InstallButton({\n isInstalling,\n handleClick,\n buttonText,\n className,\n ...props\n}: InstallButtonProps) {\n return (\n \n {isInstalling ? (\n \n ) : (\n <>\n \n {buttonText}\n \n )}\n \n );\n}\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\n\ntype EnableButtonProps = {\n /** The enabling boolean value determines the state of the button. */\n isEnabling: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n} & ButtonProps;\n\n/**\n * The EnableButton component is a button designed for initiating enabling of downloads. It includes\n * visuals for active enabling and idle states.\n *\n * @param isEnabling The enabling boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @returns A button that can be used to enable.\n */\nexport default function EnableButton({\n isEnabling,\n handleClick,\n className,\n ...props\n}: EnableButtonProps) {\n return (\n \n {isEnabling ? (\n <>\n \n Enabling...\n \n ) : (\n 'Enable'\n )}\n \n );\n}\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\n\ntype DisableButtonProps = {\n /** The disabling boolean value determines the state of the button. */\n isDisabling: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n} & ButtonProps;\n\n/**\n * The DisableButton component is a button designed for initiating disabling of downloads. It\n * includes visuals for active disabling and idle states.\n *\n * @param isDisabling The disabling boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @returns A button that can be used to disable.\n */\nexport default function DisableButton({\n isDisabling,\n handleClick,\n className,\n ...props\n}: DisableButtonProps) {\n return (\n \n {isDisabling ? (\n <>\n \n Disabling...\n \n ) : (\n 'Disable'\n )}\n \n );\n}\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\n\ntype UpdateButtonProps = {\n /** The updating boolean value determines the state of the button. */\n isUpdating: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n} & ButtonProps;\n\n/**\n * The UpdateButton component is a button designed for initiating updates for downloaded extensions.\n * It includes visuals for active updating and idle states.\n *\n * @param isUpdating The updating boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @returns A button that can be used to update.\n */\nexport default function UpdateButton({\n isUpdating,\n handleClick,\n className,\n ...props\n}: UpdateButtonProps) {\n return (\n \n {isUpdating ? (\n <>\n \n Updating...\n \n ) : (\n 'Update'\n )}\n \n );\n}\n","import { cn } from '@/utils/shadcn-ui.util';\nimport Markdown, { MarkdownToJSX } from 'markdown-to-jsx';\nimport { useMemo } from 'react';\n\ninterface MarkdownRendererProps {\n /** Optional unique identifier */\n id?: string;\n /** The markdown string to render */\n markdown: string;\n className?: string;\n /**\n * The [`target` attribute for `a` html\n * tags](https://developer.mozilla.org/en-US/docs/Web/HTML/Element/a#target). Defaults to not\n * adding a `target` to `a` tags\n */\n anchorTarget?: string;\n}\n\n/**\n * This component renders markdown content given a markdown string. It uses typography styles from\n * the platform.\n *\n * @param markdown The markdown string to render.\n * @param id Optional unique identifier\n * @returns A div containing the rendered markdown content.\n */\nexport default function MarkdownRenderer({\n id,\n markdown,\n className,\n anchorTarget,\n}: MarkdownRendererProps) {\n const options: MarkdownToJSX.Options = useMemo(\n () => ({\n overrides: {\n a: {\n props: {\n target: anchorTarget,\n },\n },\n },\n }),\n [anchorTarget],\n );\n return (\n
    \n {markdown}\n
    \n );\n}\n","import { Filter, ChevronDown } from 'lucide-react';\nimport { forwardRef } from 'react';\nimport { Button } from '@/components/shadcn-ui/button';\n\n/**\n * The FilterButton component is a button designed for initiating filtering of data. It is designed\n * to be used with the dropdown menu. It uses forwardRef to pass the button to the dropdown trigger\n * asChild.\n *\n * @returns A button that can be used to filter.\n */\nconst FilterButton = forwardRef((props, ref) => {\n return (\n \n \n Filter\n \n \n );\n});\n\nexport default FilterButton;\n","import {\n DropdownMenu,\n DropdownMenuTrigger,\n DropdownMenuContent,\n DropdownMenuLabel,\n DropdownMenuGroup,\n DropdownMenuCheckboxItem,\n DropdownMenuRadioItem,\n DropdownMenuSeparator,\n} from '@/components/shadcn-ui/dropdown-menu';\nimport FilterButton from './buttons/filter-button.component';\n\nexport enum DropdownMenuItemType {\n Check,\n Radio,\n}\n\nexport type DropdownItem = {\n /** The label is the text that will be displayed on the dropdown item. */\n label: string;\n /** The itemType determines the DropdownMenuItemType type as either Check or Radio. */\n itemType: DropdownMenuItemType;\n /** The onClick function is called when the item is clicked. */\n onClick: () => void;\n};\n\nexport type DropdownGroup = {\n /**\n * The label is the text that will be displayed on the dropdown group. It is used to categorize\n * the items in the group.\n */\n label: string;\n /** The items array contains the items that will be displayed in the dropdown group */\n items: DropdownItem[];\n};\n\nexport type FilterDropdownProps = {\n /** Object unique identifier */\n id?: string;\n /** The groups array contains the groups that will be displayed in the dropdown */\n groups: DropdownGroup[];\n}; // TODO: extend the props later\n\n/**\n * The FilterDropdown component is a dropdown designed for filtering content. It includes groups of\n * items that can be checkboxes or radio items.\n *\n * @param id Optional unique identifier\n * @param groups The groups array contains the groups that will be displayed in the dropdown\n * @returns A filter dropdown.\n */\nexport default function FilterDropdown({ id, groups }: FilterDropdownProps) {\n return (\n
    \n {/* TODO: remove this once the DropDown Menu shadcn has an id prop */}\n \n \n \n \n \n {groups.map((group) => (\n
    \n {group.label}\n \n {group.items.map((item) => (\n
    \n {item.itemType === DropdownMenuItemType.Check ? (\n \n {item.label}\n \n ) : (\n \n {item.label}\n \n )}\n
    \n ))}\n
    \n \n
    \n ))}\n
    \n
    \n
    \n );\n}\n","interface NoExtensionsFoundProps {\n /** Optional unique identifier */\n id?: string;\n /** The message to display */\n message: string;\n}\n/**\n * This component displays a message to the user when no extensions are found in the marketplace.\n *\n * @param id Optional unique identifier\n * @param message The message to display.\n * @returns {JSX.Element} - Returns the message component that displays the message to the user.\n */\nexport default function NoExtensionsFound({ id, message }: NoExtensionsFoundProps) {\n return (\n
    \n
    \n

    {message}

    \n
    \n
    \n );\n}\n","import { CircleHelp, Link as LucideLink, User } from 'lucide-react';\nimport { NumberFormat } from 'platform-bible-utils';\n\n/** Interface that stores the parameters passed to the More Info component */\ninterface MoreInfoProps {\n /** Optional unique identifier */\n id?: string;\n /** The category of the extension */\n category: string;\n /** The number of downloads for the extension */\n downloads: Record;\n /** The languages supported by the extension */\n languages: string[];\n /** The URL to the more info page of the extension */\n moreInfoUrl: string;\n}\n/**\n * This component displays the more info section of the extension which includes the category,\n * number of downloads, languages, and links to the website and support\n *\n * @param id Optional unique identifier\n * @param category The category of the extension\n * @param downloads The number of downloads for the extension\n * @param languages The languages supported by the extension\n * @param moreInfoUrl The URL to the more info page of the extension\n * @returns {JSX.Element} - Returns the more info component that displays the category, number of\n * downloads, languages, and links to the website and support\n */\nexport default function MoreInfo({\n id,\n category,\n downloads,\n languages,\n moreInfoUrl,\n}: MoreInfoProps) {\n /**\n * This constant formats the number of downloads into a more readable format.\n *\n * @example 1000 -> 1K\n *\n * @example 1000000 -> 1M\n *\n * @returns The formatted number of downloads\n */\n const numberFormatted = new NumberFormat('en', {\n notation: 'compact',\n compactDisplay: 'short',\n }).format(Object.values(downloads).reduce((a: number, b: number) => a + b, 0));\n\n /** This function scrolls the window to the bottom of the page. */\n const handleScrollToBottom = () => {\n window.scrollTo(0, document.body.scrollHeight);\n };\n\n return (\n \n
    \n
    \n {category}\n
    \n CATEGORY\n
    \n
    \n
    \n
    \n \n {numberFormatted}\n
    \n USERS\n
    \n
    \n
    \n
    \n {languages.slice(0, 3).map((locale) => (\n \n {locale.toUpperCase()}\n \n ))}\n
    \n {languages.length > 3 && (\n handleScrollToBottom()}\n className=\"tw-text-xs tw-text-gray-500 tw-underline\"\n >\n +{languages.length - 3} more languages\n \n )}\n
    \n
    \n
    \n \n Website\n \n \n \n Support\n \n \n
    \n
    \n );\n}\n","import { useState } from 'react';\n\nexport type VersionInformation = {\n /** Date the version was published */\n date: string;\n /** Description of the changes in the version */\n description: string;\n};\n\n/** Type to store the version history information */\nexport type VersionHistoryType = Record;\n\n/** Interface that stores the parameters passed to the Version History component */\ninterface VersionHistoryProps {\n /** Optional unique identifier */\n id?: string;\n /** Object containing the versions mapped with their information */\n versionHistory: VersionHistoryType;\n}\n\n/**\n * Component to render the version history information shown in the footer component. Lists the 5\n * most recent versions, with the options to show all versions by pressing a button.\n *\n * @param versionHistory Object containing the versions mapped with their information\n * @param id Optional unique identifier\n * @returns Rendered version history for the Footer component\n */\nexport default function VersionHistory({ id, versionHistory }: VersionHistoryProps) {\n const [showAllVersions, setShowAllVersions] = useState(false);\n const currentDate = new Date();\n\n /**\n * Function to format the time string for the version history in the form of 'X year(s) ago'.\n *\n * @param dateString ISO Date string to determine the time string from\n * @returns Formatted time string\n */\n function formatTimeString(dateString: string) {\n const date = new Date(dateString);\n const dateDiff = new Date(currentDate.getTime() - date.getTime());\n const yearDiff = dateDiff.getUTCFullYear() - 1970;\n const monthDiff = dateDiff.getUTCMonth();\n const dayDiff = dateDiff.getUTCDate() - 1;\n\n // Determines how long ago the version was published\n let timeString = '';\n if (yearDiff > 0) {\n timeString = `${yearDiff.toString()} year${yearDiff === 1 ? '' : 's'} ago`;\n } else if (monthDiff > 0) {\n timeString = `${monthDiff.toString()} month${monthDiff === 1 ? '' : 's'} ago`;\n } else if (dayDiff === 0) {\n timeString = 'today';\n } else {\n timeString = `${dayDiff.toString()} day${dayDiff === 1 ? '' : 's'} ago`;\n }\n\n return timeString;\n }\n\n // Sorts the version history by version number\n const sortedEntries = Object.entries(versionHistory).sort((a, b) => b[0].localeCompare(a[0]));\n\n return (\n
    \n

    What`s New

    \n
      \n {(showAllVersions ? sortedEntries : sortedEntries.slice(0, 5)).map((entry) => (\n
      \n
      \n
    • \n {entry[1].description}\n
    • \n
      \n
      \n
      Version {entry[0]}
      \n
      {formatTimeString(entry[1].date)}
      \n
      \n
      \n ))}\n
    \n {sortedEntries.length > 5 && (\n setShowAllVersions(!showAllVersions)}\n className=\"tw-text-xs tw-text-gray-500 tw-underline\"\n >\n {showAllVersions ? 'Show Less Version History' : 'Show All Version History'}\n \n )}\n
    \n );\n}\n","import { useMemo } from 'react';\nimport { formatBytes } from 'platform-bible-utils';\nimport VersionHistory, { VersionHistoryType } from './version-history.component';\n\n/** Interface to store the parameters passed to the Footer component */\ninterface FooterProps {\n /** Optional unique identifier */\n id?: string;\n /** Name of the publisher */\n publisherDisplayName: string;\n /** Size of the extension file in bytes */\n fileSize: number;\n /** List of language codes supported by the extension */\n locales: string[];\n /** Object containing the version history mapped with their information */\n versionHistory: VersionHistoryType;\n}\n\n/**\n * Component to render the footer for the extension details which contains information on the\n * publisher, version history, languages, and file size.\n *\n * @param id Optional unique identifier\n * @param publisherDisplayName Name of the publisher\n * @param fileSize Size of the extension file in bytes\n * @param locales List of language codes supported by the extension\n * @param versionHistory Object containing the version history mapped with their information\n * @returns The rendered Footer component\n */\nexport default function Footer({\n id,\n publisherDisplayName,\n fileSize,\n locales,\n versionHistory,\n}: FooterProps) {\n /** Formats the file size into a human-readable format */\n const formattedFileSize = useMemo(() => formatBytes(fileSize), [fileSize]);\n\n /**\n * This function gets the display names of the languages based on the language codes.\n *\n * @param codes The list of language codes\n * @returns The list of language names\n */\n const getLanguageNames = (codes: string[]) => {\n const displayNames = new Intl.DisplayNames(navigator.language, { type: 'language' });\n return codes.map((code) => displayNames.of(code));\n };\n\n const languageNames = getLanguageNames(locales);\n\n return (\n
    \n
    \n \n
    \n
    \n

    Information

    \n
    \n

    \n Publisher\n {publisherDisplayName}\n Size\n {formattedFileSize}\n

    \n
    \n

    \n Languages\n {languageNames.join(', ')}\n

    \n
    \n
    \n
    \n
    \n
    \n );\n}\n","import { PlatformEvent, PlatformEventHandler } from 'platform-bible-utils';\nimport { useEffect } from 'react';\n\n/**\n * Adds an event handler to an event so the event handler runs when the event is emitted. Use\n * `papi.network.getNetworkEvent` to use a networked event with this hook.\n *\n * @param event The event to subscribe to.\n *\n * - If event is a `PlatformEvent`, that event will be used\n * - If event is undefined, the callback will not be subscribed. Useful if the event is not yet\n * available for example\n *\n * @param eventHandler The callback to run when the event is emitted\n *\n * WARNING: MUST BE STABLE - const or wrapped in useCallback. The reference must not be updated\n * every render\n */\nconst useEvent = (\n event: PlatformEvent | undefined,\n eventHandler: PlatformEventHandler,\n) => {\n useEffect(() => {\n // Do nothing if the event is not provided (in case the event is not yet available, for example)\n if (!event) return () => {};\n\n const unsubscriber = event(eventHandler);\n return () => {\n unsubscriber();\n };\n }, [event, eventHandler]);\n};\nexport default useEvent;\n","import { useCallback, useEffect } from 'react';\nimport { PlatformEvent, PlatformEventAsync, PlatformEventHandler } from 'platform-bible-utils';\nimport usePromise from './use-promise.hook';\n\nconst noopUnsubscriber = () => false;\n\n/**\n * Adds an event handler to an asynchronously subscribing/unsubscribing event so the event handler\n * runs when the event is emitted. Use `papi.network.getNetworkEvent` to use a networked event with\n * this hook.\n *\n * @param event The asynchronously (un)subscribing event to subscribe to.\n *\n * - If event is a `PlatformEvent` or `PlatformEventAsync`, that event will be used\n * - If event is undefined, the callback will not be subscribed. Useful if the event is not yet\n * available for example\n *\n * @param eventHandler The callback to run when the event is emitted\n *\n * WARNING: MUST BE STABLE - const or wrapped in useCallback. The reference must not be updated\n * every render\n */\nconst useEventAsync = (\n event: PlatformEvent | PlatformEventAsync | undefined,\n eventHandler: PlatformEventHandler,\n) => {\n // Subscribe to the event asynchronously\n const [unsubscribe] = usePromise(\n useCallback(async () => {\n // Do nothing if the event is not provided (in case the event is not yet available, for example)\n if (!event) return noopUnsubscriber;\n\n // Wrap subscribe and unsubscribe in promises to allow normal events to be used as well\n const unsub = await Promise.resolve(event(eventHandler));\n return async () => unsub();\n }, [eventHandler, event]),\n noopUnsubscriber,\n // We want the unsubscriber to return to default value immediately upon changing subscription\n // So the useEffect below will unsubscribe asap\n { preserveValue: false },\n );\n\n // Unsubscribe from the event asynchronously (but we aren't awaiting the unsub)\n useEffect(() => {\n return () => {\n if (unsubscribe !== noopUnsubscriber) {\n unsubscribe();\n }\n };\n }, [unsubscribe]);\n};\n\nexport default useEventAsync;\n"],"names":["twMergeCustom","extendTailwindMerge","cn","inputs","clsx","Input","React","className","type","props","ref","jsx","BookChapterInput","forwardRef","handleSearch","handleKeyDown","handleOnClick","handleSubmit","jsxs","ShadInput","event","e","History","P","R","s","n","N","B","O","S","K","g","k","x","T","X","V","w","L","G","A","H","C","I","y","q","U","m","l","h","c","E","D","i","a","o","u","v","f","d","b","J","DropdownMenu","DropdownMenuPrimitive","DropdownMenuTrigger","DropdownMenuGroup","DropdownMenuPortal","DropdownMenuSub","DropdownMenuRadioGroup","DropdownMenuSubTrigger","inset","children","ChevronRight","DropdownMenuSubContent","DropdownMenuContent","sideOffset","DropdownMenuItem","DropdownMenuCheckboxItem","checked","Check","DropdownMenuRadioItem","Circle","DropdownMenuLabel","DropdownMenuSeparator","DropdownMenuShortcut","BookMenuItem","bookId","handleSelectBook","isSelected","handleHighlightBook","bookType","ShadDropdownMenuItem","Canon","ChapterSelect","handleSelectChapter","endChapter","activeChapter","highlightedChapter","handleHighlightedChapter","chapters","_","handleMouse","useCallback","chapterNumber","chapter","GoToMenuItem","handleSort","handleLocationHistory","handleBookmarks","ShadDropdownMenuLabel","ArrowDownWideNarrow","Clock","Bookmark","ALL_BOOK_IDS","BOOK_TYPE_LABELS","BOOK_TYPE_ARRAY","SCROLL_OFFSET","SEARCH_QUERY_FORMATS","fetchGroupedBooks","fetchEndChapter","getChaptersForBook","getAllEnglishNames","isValidBookEnglishName","bookName","getBookIdFromEnglishName","formattedBookName","BookChapterControl","scrRef","searchQuery","setSearchQuery","useState","selectedBookId","setSelectedBookId","setHighlightedChapter","highlightedBookId","setHighlightedBookId","isContentOpen","setIsContentOpen","isContentOpenDelayed","setIsContentOpenDelayed","inputRef","useRef","contentRef","menuItemRef","fetchFilteredBooks","englishNameLowerCase","normalizedQuery","handleSearchInput","searchString","shouldPreventAutoClosing","controlMenuState","open","updateReference","shouldClose","verse","handleInputSubmit","format","matches","book","englishName","handleKeyDownInput","handleKeyDownContent","key","handleKeyDownMenuItem","chapterOffSet","useEffect","useLayoutEffect","scrollTimeout","scrollPosition","ShadDropdownMenu","ShadDropdownMenuTrigger","ShadDropdownMenuContent","bookTypeIndex","element","ShadDropdownMenuSeparator","buttonVariants","cva","Button","variant","size","asChild","Slot","labelVariants","Label","LabelPrimitive","RadioGroup","RadioGroupPrimitive","RadioGroupItem","Popover","PopoverPrimitive","PopoverTrigger","PopoverContent","align","DialogPortal","DialogPrimitive","DialogOverlay","DialogContent","DialogTitle","DialogDescription","Command","CommandPrimitive","CommandInput","Search","CommandList","CommandEmpty","CommandGroup","CommandSeparator","CommandItem","getOptionLabelDefault","option","ComboBox","id","options","buttonClassName","popoverContentClassName","value","onChange","getOptionLabel","buttonPlaceholder","textPlaceholder","commandEmptyMessage","buttonVariant","dir","isDisabled","setOpen","ChevronsUpDown","ChapterRangeSelector","startChapter","handleSelectStartChapter","handleSelectEndChapter","chapterCount","chapterOptions","useMemo","index","Fragment","BookSelectionMode","BOOK_SELECTOR_STRING_KEYS","localizeString","strings","BookSelector","handleBookSelectionModeChange","currentBookName","onSelectBooks","selectedBookIds","localizedStrings","currentBookText","chooseText","chooseBooksText","bookSelectionMode","setBookSelectionMode","onSelectionModeChange","newMode","DataTableViewOptions","table","FilterIcon","column","Select","SelectPrimitive","SelectGroup","SelectValue","SelectTrigger","ChevronDown","SelectScrollUpButton","ChevronUp","SelectScrollDownButton","SelectContent","position","SelectLabel","SelectItem","SelectSeparator","DataTablePagination","pageSize","ArrowLeftIcon","ChevronLeftIcon","ChevronRightIcon","ArrowRightIcon","Table","stickyHeader","TableHeader","TableBody","TableFooter","TableRow","TableHead","TableCell","TableCaption","DataTable","columns","data","enablePagination","showPaginationControls","showColumnVisibilityControls","onRowClickHandler","sorting","setSorting","columnFilters","setColumnFilters","columnVisibility","setColumnVisibility","rowSelection","setRowSelection","useReactTable","getCoreRowModel","getPaginationRowModel","getSortedRowModel","getFilteredRowModel","headerGroup","header","flexRender","_a","row","cell","OccurrencesTable","occurrenceData","setScriptureReference","referenceHeaderText","occurrenceHeaderText","occurrences","uniqueOccurrences","occurrence","uniqueOccurrence","deepEqual","Checkbox","CheckboxPrimitive","getLinesFromUSFM","text","getNumberFromUSFM","regex","match","getBookNumFromId","getStatusForItem","item","approvedItems","unapprovedItems","toggleVariants","Toggle","TogglePrimitive","ToggleGroupContext","ToggleGroup","ToggleGroupPrimitive","ToggleGroupItem","context","getSortingIcon","sortDirection","ArrowUpIcon","ArrowDownIcon","ArrowUpDownIcon","inventoryItemColumn","itemLabel","inventoryAdditionalItemColumn","additionalItemLabel","additionalItemIndex","inventoryCountColumn","countLabel","statusChangeHandler","changedItems","newStatus","onApprovedItemsChange","onUnapprovedItemsChange","newApprovedItems","validItem","newUnapprovedItems","unapprovedItem","inventoryStatusColumn","statusLabel","status","CircleCheckIcon","CircleXIcon","CircleHelpIcon","INVENTORY_STRING_KEYS","filterItemData","itemData","statusFilter","textFilter","filteredItemData","createTableData","scriptureRef","itemRegex","tableData","currentBook","currentChapter","currentVerse","line","items","itemIndex","existingItem","tableEntry","newReference","substring","newItem","Inventory","scriptureReference","extractItems","additionalItemsLabels","scope","onScopeChange","allItemsText","approvedItemsText","unapprovedItemsText","unknownItemsText","scopeBookText","scopeChapterText","scopeVerseText","filterText","showAdditionalItemsText","showAdditionalItems","setShowAdditionalItems","setStatusFilter","setTextFilter","selectedItem","setSelectedItem","reducedTableData","newTableData","firstItem","existingEntry","newTableEntry","filteredTableData","allColumns","numberOfAdditionalItems","additionalColumns","_b","rowClickHandler","newSelection","handleScopeChange","handleStatusFilterChange","SearchBar","onSearch","placeholder","isFullWidth","handleInputChange","VerticalTabs","TabsPrimitive","VerticalTabsList","VerticalTabsTrigger","VerticalTabsContent","TabNavigationContentSearch","tabList","searchPlaceholder","headerTitle","isSearchBarFullWidth","direction","tab","Separator","orientation","decorative","SeparatorPrimitive","Skeleton","TooltipProvider","TooltipPrimitive","Tooltip","TooltipTrigger","TooltipContent","SIDEBAR_WIDTH","SIDEBAR_WIDTH_ICON","SIDEBAR_KEYBOARD_SHORTCUT","SidebarContext","useSidebar","SidebarProvider","defaultOpen","openProp","setOpenProp","style","_open","_setOpen","isOpen","openState","toggleSidebar","state","contextValue","Sidebar","side","collapsible","SidebarTrigger","onClick","PanelLeft","SidebarRail","SidebarInset","SidebarInput","SidebarHeader","SidebarFooter","SidebarSeparator","SidebarContent","SidebarGroup","SidebarGroupLabel","SidebarGroupAction","SidebarGroupContent","SidebarMenu","SidebarMenuItem","sidebarMenuButtonVariants","SidebarMenuButton","isActive","tooltip","Comp","button","SidebarMenuAction","showOnHover","SidebarMenuBadge","SidebarMenuSkeleton","showIcon","width","SidebarMenuSub","SidebarMenuSubItem","SidebarMenuSubButton","SettingsSidebar","extensionLabels","projectInfo","handleSelectSidebarItem","selectedSidebarItem","extensionsSidebarGroupLabel","projectsSidebarGroupLabel","buttonPlaceholderText","handleSelectItem","projectId","getProjectNameFromProjectId","project","info","getIsActive","label","selectedProjectName","SettingsSidebarContentSearch","scrBookColId","scrRefColId","typeColId","detailsColId","defaultScrRefColumnName","defaultScrBookGroupName","defaultTypeColumnName","defaultDetailsColumnName","getColumns","colInfo","showSourceColumn","showSrcCol","formatScrRef","compareScrRefs","toRefOrRange","scriptureSelection","offsetStart","offsetEnd","scrRefToBBBCCCVVV","getRowKey","ScriptureResultsViewer","sources","showColumnHeaders","scriptureReferenceColumnName","scriptureBookGroupName","typeColumnName","detailsColumnName","onRowSelected","grouping","setGrouping","scriptureResults","source","getExpandedRowModel","getGroupedRowModel","selectedRows","keys","selectedRow","scrBookGroupName","typeGroupName","groupingOptions","handleSelectChange","selectedGrouping","handleRowClick","getEvenOrOddBandingStyle","getIndent","groupingState","rowIndex","ChevronLeft","DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS","getLocalizeKeyForScrollGroupId","ScrollGroupSelector","availableScrollGroupIds","scrollGroupId","onChangeScrollGroupId","localizedStringsDefaulted","localizedStringKey","localizedStringValue","newScrollGroupString","scrollGroupOptionId","SettingsList","SettingsListItem","primary","secondary","isLoading","loadingMessage","SettingsListHeader","includeSeparator","Checklist","listItems","selectedListItems","handleSelectListItem","createLabel","_interopRequireDefault","obj","module","chainPropTypes","propType1","propType2","args","_extends","target","isPlainObject","prototype","deepClone","output","deepmerge","p","r","t","z","reactIs_production_min","hasSymbol","REACT_ELEMENT_TYPE","REACT_PORTAL_TYPE","REACT_FRAGMENT_TYPE","REACT_STRICT_MODE_TYPE","REACT_PROFILER_TYPE","REACT_PROVIDER_TYPE","REACT_CONTEXT_TYPE","REACT_ASYNC_MODE_TYPE","REACT_CONCURRENT_MODE_TYPE","REACT_FORWARD_REF_TYPE","REACT_SUSPENSE_TYPE","REACT_SUSPENSE_LIST_TYPE","REACT_MEMO_TYPE","REACT_LAZY_TYPE","REACT_BLOCK_TYPE","REACT_FUNDAMENTAL_TYPE","REACT_RESPONDER_TYPE","REACT_SCOPE_TYPE","isValidElementType","typeOf","object","$$typeof","$$typeofType","AsyncMode","ConcurrentMode","ContextConsumer","ContextProvider","Element","ForwardRef","Lazy","Memo","Portal","Profiler","StrictMode","Suspense","hasWarnedAboutDeprecatedIsAsyncMode","isAsyncMode","isConcurrentMode","isContextConsumer","isContextProvider","isElement","isForwardRef","isFragment","isLazy","isMemo","isPortal","isProfiler","isStrictMode","isSuspense","reactIs_development","reactIsModule","require$$0","require$$1","getOwnPropertySymbols","hasOwnProperty","propIsEnumerable","toObject","val","shouldUseNative","test1","test2","order2","test3","letter","objectAssign","from","to","symbols","ReactPropTypesSecret","ReactPropTypesSecret_1","has","printWarning","loggedTypeFailures","message","checkPropTypes","typeSpecs","values","location","componentName","getStack","typeSpecName","error","err","ex","stack","checkPropTypes_1","ReactIs","assign","require$$2","require$$3","require$$4","emptyFunctionThatReturnsNull","factoryWithTypeCheckers","isValidElement","throwOnDirectAccess","ITERATOR_SYMBOL","FAUX_ITERATOR_SYMBOL","getIteratorFn","maybeIterable","iteratorFn","ANONYMOUS","ReactPropTypes","createPrimitiveTypeChecker","createAnyTypeChecker","createArrayOfTypeChecker","createElementTypeChecker","createElementTypeTypeChecker","createInstanceTypeChecker","createNodeChecker","createObjectOfTypeChecker","createEnumTypeChecker","createUnionTypeChecker","createShapeTypeChecker","createStrictShapeTypeChecker","is","PropTypeError","createChainableTypeChecker","validate","manualPropTypeCallCache","manualPropTypeWarningCount","checkType","isRequired","propName","propFullName","secret","cacheKey","chainedCheckType","expectedType","propValue","propType","getPropType","preciseType","getPreciseType","typeChecker","expectedClass","expectedClassName","actualClassName","getClassName","expectedValues","valuesString","arrayOfTypeCheckers","checker","getPostfixForTypeWarning","expectedTypes","checkerResult","expectedTypesMessage","isNode","invalidValidatorError","shapeTypes","allKeys","iterator","step","entry","isSymbol","emptyFunction","emptyFunctionWithReset","factoryWithThrowingShims","shim","getShim","propTypesModule","isClassComponent","elementType","acceptingRef","safePropName","warningHint","elementAcceptingRef","PropTypes","elementAcceptingRef$1","specialProperty","exactProp","propTypes","unsupportedProps","prop","formatMuiErrorMessage","code","url","REACT_SERVER_CONTEXT_TYPE","REACT_OFFSCREEN_TYPE","enableScopeAPI","enableCacheElement","enableTransitionTracing","enableLegacyHidden","enableDebugTracing","REACT_MODULE_REFERENCE","SuspenseList","hasWarnedAboutDeprecatedIsConcurrentMode","isSuspenseList","fnNameMatchRegex","getFunctionName","fn","getFunctionComponentName","Component","fallback","getWrappedName","outerType","innerType","wrapperName","functionName","getDisplayName","HTMLElementType","refType","refType$1","capitalize","string","_formatMuiErrorMessage","createChainedFunction","funcs","acc","func","debounce","wait","timeout","debounced","later","deprecatedPropType","validator","reason","componentNameSafe","propFullNameSafe","isMuiElement","muiNames","_muiName","_element$type","ownerDocument","node","ownerWindow","requirePropFactory","componentNameInError","prevPropTypes","requiredProp","defaultTypeChecker","typeCheckerResult","setRef","useEnhancedEffect","useEnhancedEffect$1","globalId","useGlobalId","idOverride","defaultId","setDefaultId","maybeReactUseId","useId","reactId","unsupportedProp","useControlled","controlled","defaultProp","name","isControlled","valueState","setValue","defaultValue","setValueIfUncontrolled","newValue","useEventCallback","useForkRef","refs","instance","UNINITIALIZED","useLazyRef","init","initArg","EMPTY","useOnMount","Timeout","delay","useTimeout","hadKeyboardEvent","hadFocusVisibleRecently","hadFocusVisibleRecentlyTimeout","inputTypesWhitelist","focusTriggersKeyboardModality","tagName","handlePointerDown","handleVisibilityChange","prepare","doc","isFocusVisible","useIsFocusVisible","isFocusVisibleRef","handleBlurVisible","handleFocusVisible","resolveProps","defaultProps","defaultSlotProps","slotProps","slotPropName","composeClasses","slots","getUtilityClass","classes","slot","utilityClass","defaultGenerator","createClassNameGenerator","generate","generator","ClassNameGenerator","ClassNameGenerator$1","globalStateClasses","generateUtilityClass","globalStatePrefix","globalStateClass","generateUtilityClasses","result","clamp","min","max","_objectWithoutPropertiesLoose","excluded","sourceKeys","_excluded","sortBreakpointsValues","breakpointsAsArray","breakpoint1","breakpoint2","createBreakpoints","breakpoints","unit","other","sortedValues","up","down","between","start","end","endIndex","only","not","keyIndex","shape","shape$1","responsivePropType","responsivePropType$1","merge","defaultBreakpoints","handleBreakpoints","styleFromPropValue","theme","themeBreakpoints","breakpoint","mediaKey","cssKey","createEmptyBreakpointObject","breakpointsInput","_breakpointsInput$key","breakpointStyleKey","removeUnusedBreakpoints","breakpointKeys","breakpointOutput","getPath","path","checkVars","getStyleValue","themeMapping","transform","propValueFinal","userValue","cssProperty","themeKey","memoize","cache","arg","properties","directions","aliases","getCssProperties","property","marginKeys","paddingKeys","spacingKeys","createUnaryUnit","_getPath","themeSpacing","abs","createUnarySpacing","getValue","transformer","transformed","getStyleFromPropValue","cssProperties","resolveCssProperty","margin","padding","createSpacing","spacingInput","spacing","argsInput","argument","compose","styles","handlers","borderTransform","createBorderStyle","border","borderTop","borderRight","borderBottom","borderLeft","borderColor","borderTopColor","borderRightColor","borderBottomColor","borderLeftColor","outline","outlineColor","borderRadius","gap","columnGap","rowGap","gridColumn","gridRow","gridAutoFlow","gridAutoColumns","gridAutoRows","gridTemplateColumns","gridTemplateRows","gridTemplateAreas","gridArea","paletteTransform","color","bgcolor","backgroundColor","sizingTransform","maxWidth","_props$theme","_props$theme2","breakpointsValues","minWidth","height","maxHeight","minHeight","boxSizing","defaultSxConfig","defaultSxConfig$1","objectsHaveSameKeys","objects","union","callIfFn","maybeFn","unstable_createStyleFunctionSx","getThemeValue","config","styleFunctionSx","_theme$unstable_sxCon","sx","traverse","sxInput","sxObject","emptyBreakpoints","breakpointsKeys","css","styleKey","styleFunctionSx$1","applyStyles","createTheme","paletteInput","shapeInput","muiTheme","isObjectEmpty","useTheme","defaultTheme","contextTheme","ThemeContext","systemDefaultTheme","useThemeWithoutDefault","_excluded2","_excluded3","isEmpty","isStringTag","tag","shouldForwardProp","lowercaseFirstLetter","resolveTheme","themeId","defaultOverridesResolver","processStyleArg","callableStyle","_ref","ownerState","resolvedStylesArg","resolvedStyle","variants","isMatch","createStyled","input","rootShouldForwardProp","slotShouldForwardProp","systemSx","inputOptions","processStyles","componentSlot","inputSkipVariantsResolver","inputSkipSx","overridesResolver","skipVariantsResolver","skipSx","shouldForwardPropOption","defaultStyledResolver","styledEngineStyled","transformStyleArg","stylesArg","muiStyledResolver","styleArg","expressions","transformedStyleArg","expressionsWithDefaultTheme","styleOverrides","resolvedStyleOverrides","slotKey","slotStyle","_theme$components","themeVariants","numOfCustomFnsApplied","placeholders","displayName","getThemeProps","params","useThemeProps","clampWrapper","hexToRgb","re","colors","decomposeColor","marker","colorSpace","recomposeColor","hslToRgb","rgb","getLuminance","getContrastRatio","foreground","background","lumA","lumB","alpha","darken","coefficient","lighten","createMixins","mixins","common","common$1","grey","grey$1","purple","purple$1","red","red$1","orange","orange$1","blue","blue$1","lightBlue","lightBlue$1","green","green$1","light","dark","addLightOrDark","intent","shade","tonalOffset","tonalOffsetLight","tonalOffsetDark","getDefaultPrimary","mode","getDefaultSecondary","getDefaultError","getDefaultInfo","getDefaultSuccess","getDefaultWarning","createPalette","palette","contrastThreshold","success","warning","getContrastText","contrastText","contrast","augmentColor","mainShade","lightShade","darkShade","modes","round","caseAllCaps","defaultFontFamily","createTypography","typography","fontFamily","fontSize","fontWeightLight","fontWeightRegular","fontWeightMedium","fontWeightBold","htmlFontSize","allVariants","pxToRem2","coef","pxToRem","buildVariant","fontWeight","lineHeight","letterSpacing","casing","shadowKeyUmbraOpacity","shadowKeyPenumbraOpacity","shadowAmbientShadowOpacity","createShadow","px","shadows","shadows$1","easing","duration","formatMs","milliseconds","getAutoHeightDuration","constant","createTransitions","inputTransitions","mergedEasing","mergedDuration","durationOption","easingOption","isString","isNumber","animatedProp","zIndex","zIndex$1","mixinsInput","transitionsInput","typographyInput","systemTheme","systemCreateTheme","stateClasses","component","child","stateClass","defaultTheme$1","THEME_ID","systemUseThemeProps","styled","styled$1","getSvgIconUtilityClass","useUtilityClasses","SvgIconRoot","_theme$transitions","_theme$transitions$cr","_theme$transitions2","_theme$typography","_theme$typography$pxT","_theme$typography2","_theme$typography2$px","_theme$typography3","_theme$typography3$px","_palette$ownerState$c","_palette","_palette2","_palette3","SvgIcon","inProps","htmlColor","inheritViewBox","titleAccess","viewBox","hasSvgAsChild","more","_jsxs","_jsx","SvgIcon$1","createSvgIcon","unstable_ClassNameGenerator","exports","_utils","ArrowRight","default_1","_createSvgIcon","_jsxRuntime","isHostComponent","appendOwnerState","otherProps","defaultContextValue","ClassNameConfiguratorContext","useClassNamesOverride","disableDefaultClasses","extractEventHandlers","excludeKeys","resolveComponentProps","componentProps","slotState","omitEventHandlers","mergeSlotProps","parameters","getSlotProps","additionalProps","externalSlotProps","externalForwardedProps","joinedClasses","mergedStyle","eventHandlers","componentsPropsWithoutEventHandlers","otherPropsWithoutEventHandlers","internalSlotProps","useSlotProps","_parameters$additiona","skipResolvingSlotProps","rest","resolvedComponentsProps","mergedProps","internalRef","GLOBAL_CLASS_PREFIX","buildStateClass","buildSlotClass","getContainer","container","forwardedRef","disablePortal","mountNode","setMountNode","handleRef","newProps","ReactDOM","top","bottom","right","left","auto","basePlacements","clippingParents","viewport","popper","reference","variationPlacements","placement","placements","beforeRead","read","afterRead","beforeMain","main","afterMain","beforeWrite","write","afterWrite","modifierPhases","getNodeName","getWindow","OwnElement","isHTMLElement","isShadowRoot","attributes","effect","_ref2","initialStyles","styleProperties","attribute","applyStyles$1","getBasePlacement","getUAString","uaData","isLayoutViewport","getBoundingClientRect","includeScale","isFixedStrategy","clientRect","scaleX","scaleY","visualViewport","addVisualOffsets","getLayoutRect","contains","parent","rootNode","next","getComputedStyle","isTableElement","getDocumentElement","getParentNode","getTrueOffsetParent","getContainingBlock","isFirefox","isIE","elementCss","currentNode","getOffsetParent","window","offsetParent","getMainAxisFromPlacement","within","mathMax","mathMin","withinMaxClamp","getFreshSideObject","mergePaddingObject","paddingObject","expandToHashMap","hashMap","toPaddingObject","arrow","_state$modifiersData$","arrowElement","popperOffsets","basePlacement","axis","isVertical","len","arrowRect","minProp","maxProp","endDiff","startDiff","arrowOffsetParent","clientSize","centerToReference","center","offset","axisProp","_options$element","arrow$1","getVariation","unsetSides","roundOffsetsByDPR","win","dpr","mapToStyles","_Object$assign2","popperRect","variation","offsets","gpuAcceleration","adaptive","roundOffsets","isFixed","_offsets$x","_offsets$y","_ref3","hasX","hasY","sideX","sideY","heightProp","widthProp","offsetY","offsetX","commonStyles","_ref4","_Object$assign","computeStyles","_ref5","_options$gpuAccelerat","_options$adaptive","_options$roundOffsets","computeStyles$1","passive","_options$scroll","scroll","_options$resize","resize","scrollParents","scrollParent","eventListeners","hash","getOppositePlacement","matched","getOppositeVariationPlacement","getWindowScroll","scrollLeft","scrollTop","getWindowScrollBarX","getViewportRect","strategy","html","layoutViewport","getDocumentRect","_element$ownerDocumen","winScroll","body","isScrollParent","_getComputedStyle","overflow","overflowX","overflowY","getScrollParent","listScrollParents","list","isBody","updatedList","rectToClientRect","rect","getInnerBoundingClientRect","getClientRectFromMixedType","clippingParent","getClippingParents","canEscapeClipping","clipperElement","getClippingRect","boundary","rootBoundary","mainClippingParents","firstClippingParent","clippingRect","accRect","computeOffsets","commonX","commonY","mainAxis","detectOverflow","_options","_options$placement","_options$strategy","_options$boundary","_options$rootBoundary","_options$elementConte","elementContext","_options$altBoundary","altBoundary","_options$padding","altContext","clippingClientRect","referenceClientRect","popperClientRect","elementClientRect","overflowOffsets","offsetData","multiply","computeAutoPlacement","flipVariations","_options$allowedAutoP","allowedAutoPlacements","allPlacements","allowedPlacements","overflows","getExpandedFallbackPlacements","oppositePlacement","flip","_options$mainAxis","checkMainAxis","_options$altAxis","checkAltAxis","specifiedFallbackPlacements","_options$flipVariatio","preferredPlacement","isBasePlacement","fallbackPlacements","referenceRect","checksMap","makeFallbackChecks","firstFittingPlacement","_basePlacement","isStartVariation","mainVariationSide","altVariationSide","checks","check","numberOfChecks","_loop","_i","fittingPlacement","_ret","flip$1","getSideOffsets","preventedOffsets","isAnySideFullyClipped","hide","referenceOverflow","popperAltOverflow","referenceClippingOffsets","popperEscapeOffsets","isReferenceHidden","hasPopperEscaped","hide$1","distanceAndSkiddingToXY","rects","invertDistance","skidding","distance","_options$offset","_data$state$placement","offset$1","popperOffsets$1","getAltAxis","preventOverflow","_options$tether","tether","_options$tetherOffset","tetherOffset","altAxis","tetherOffsetValue","normalizedTetherOffsetValue","offsetModifierState","_offsetModifierState$","mainSide","altSide","additive","minLen","maxLen","arrowPaddingObject","arrowPaddingMin","arrowPaddingMax","arrowLen","minOffset","maxOffset","clientOffset","offsetModifierValue","tetherMin","tetherMax","preventedOffset","_offsetModifierState$2","_mainSide","_altSide","_offset","_len","_min","_max","isOriginSide","_offsetModifierValue","_tetherMin","_tetherMax","_preventedOffset","preventOverflow$1","getHTMLElementScroll","getNodeScroll","isElementScaled","getCompositeRect","elementOrVirtualElement","isOffsetParentAnElement","offsetParentIsScaled","documentElement","order","modifiers","map","visited","modifier","sort","requires","dep","depModifier","orderModifiers","orderedModifiers","phase","pending","resolve","mergeByName","merged","current","existing","DEFAULT_OPTIONS","areValidElements","_key","popperGenerator","generatorOptions","_generatorOptions","_generatorOptions$def","defaultModifiers","_generatorOptions$def2","defaultOptions","effectCleanupFns","isDestroyed","setOptionsAction","cleanupModifierEffects","runModifierEffects","_state$elements","_state$orderedModifie","_state$orderedModifie2","_ref$options","cleanupFn","noopFn","createPopper","COMPONENT_NAME","getPopperUtilityClass","flipPlacement","resolveAnchorEl","anchorEl","isVirtualElement","defaultPopperOptions","PopperTooltip","_slots$root","initialPlacement","popperOptions","popperRefProp","TransitionProps","tooltipRef","ownRef","popperRef","handlePopperRef","handlePopperRefRef","rtlPlacement","setPlacement","resolvedAnchorElement","setResolvedAnchorElement","handlePopperUpdate","box","popperModifiers","childProps","Root","rootProps","Popper","containerProp","keepMounted","transition","exited","setExited","handleEnter","handleExited","resolvedAnchorEl","display","transitionProps","useThemeSystem","_setPrototypeOf","_inheritsLoose","subClass","superClass","setPrototypeOf","timeoutsShape","TransitionGroupContext","forceReflow","UNMOUNTED","EXITED","ENTERING","ENTERED","EXITING","Transition","_React$Component","_this","parentGroup","appear","initialStatus","prevState","nextIn","_proto","prevProps","nextStatus","exit","enter","mounting","_this2","appearing","maybeNode","maybeAppearing","timeouts","enterTimeout","_this3","nextState","callback","_this4","active","handler","doesNotHaveTimeoutOrListener","maybeNextCallback","_this$props","pt","noop","Transition$1","reflow","getTransitionProps","_style$transitionDura","_style$transitionTimi","getScale","isWebKit154","Grow","addEndListener","inProp","onEnter","onEntered","onEntering","onExit","onExited","onExiting","TransitionComponent","timer","autoTimeout","nodeRef","normalizedTransitionCallback","maybeIsAppearing","handleEntering","isAppearing","transitionDuration","transitionTimingFunction","handleEntered","handleExiting","handleExit","Grow$1","PopperRoot","BasePopper","components","componentsProps","RootComponent","Popper$1","getTooltipUtilityClass","tooltipClasses","tooltipClasses$1","disableInteractive","touch","TooltipPopper","TooltipTooltip","TooltipArrow","hystersisOpen","hystersisTimer","cursorPosition","composeEventHandler","eventHandler","_slots$popper","_slots$transition","_slots$tooltip","_slots$arrow","_slotProps$popper","_ref6","_slotProps$popper2","_slotProps$transition","_slotProps$tooltip","_ref7","_slotProps$tooltip2","_slotProps$arrow","_ref8","_slotProps$arrow2","childrenProp","describeChild","disableFocusListener","disableHoverListener","disableInteractiveProp","disableTouchListener","enterDelay","enterNextDelay","enterTouchDelay","followCursor","idProp","leaveDelay","leaveTouchDelay","onClose","onOpen","PopperComponentProp","PopperProps","title","TransitionComponentProp","isRtl","childNode","setChildNode","arrowRef","setArrowRef","ignoreNonTouchEvents","closeTimer","enterTimer","leaveTimer","touchTimer","setOpenState","prevUserSelect","stopTouchInteraction","handleOpen","handleClose","handleLeave","focusVisibleRef","setChildIsFocusVisible","handleBlur","handleFocus","detectTouchStart","childrenProps","handleMouseOver","handleMouseLeave","handleTouchStart","handleTouchEnd","nativeEvent","handleMouseMove","nameOrDescProps","titleIsString","interactiveWrapperListeners","_PopperProps$popperOp","tooltipModifiers","PopperComponent","TooltipComponent","ArrowComponent","popperProps","tooltipProps","tooltipArrowProps","TransitionPropsInner","Tooltip$1","getIcon","icon","menuLabel","leading","MuiListItemIcon","MenuItem","allowForLeadingIcons","iconPathBefore","iconPathAfter","hasAutoFocus","isDense","isSubMenuParent","hasDisabledGutters","hasDivider","focusVisibleClassName","menuItem","MuiMenuItem","MuiListItemText","getAllGroups","menuDefinition","SubMenu","setAnchorEl","parentMenuItem","parentItemProps","handleParentMenuItemClick","renderSubMenuItems","includedGroups","group","GroupedMenuItemList","Menu","getOrderedGroupItems","groupId","allItems","menuProps","commandHandler","groupsToInclude","sortedGroups","itemArray","allowSpaceForLeadingIcons","createMenuItemProps","isLastItemInGroup","divKey","itemInfo","menuItemProps","TopLevelMenu","columnId","MenuColumn","metadata","Grid","List","GridMenu","multiColumnMenu","sortedColumns","columnNumbers","columnName","col","getUsePromiseOptionsDefaults","usePromise","promiseFactoryCallback","defaultValueRef","optionsDefaultedRef","setIsLoading","promiseIsCurrent","MenuIcon","HamburgerMenuButton","menuProvider","normalMenu","fullMenu","containerRef","ariaLabelPrefix","isMenuOpen","setMenuOpen","showFullMenu","setShowFullMenu","handleMenuItemClick","handleMenuButtonClick","prevIsOpen","isOpening","menuCommandHandler","command","setOffset","normalMenuData","fullMenuData","menu","IconButton","Drawer","isTooltipSuppressed","adjustMarginToAlignToEdge","MuiIconButton","Spinner","LoaderCircle","TextField","hasError","helperText","onFocus","onBlur","ShadLabel","Toolbar","AppBar","MuiToolbar","alertVariants","Alert","AlertTitle","AlertDescription","Card","CardHeader","CardTitle","CardDescription","CardContent","CardFooter","Sonner","Toaster","Slider","SliderPrimitive","Switch","SwitchPrimitives","Tabs","TabsList","TabsTrigger","TabsContent","InstallButton","isInstalling","handleClick","buttonText","Download","EnableButton","isEnabling","DisableButton","isDisabling","UpdateButton","isUpdating","MarkdownRenderer","markdown","anchorTarget","Markdown","FilterButton","Filter","DropdownMenuItemType","DropdownMenuItemType2","FilterDropdown","groups","NoExtensionsFound","MoreInfo","category","downloads","languages","moreInfoUrl","numberFormatted","NumberFormat","handleScrollToBottom","User","locale","LucideLink","CircleHelp","VersionHistory","versionHistory","showAllVersions","setShowAllVersions","currentDate","formatTimeString","dateString","date","dateDiff","yearDiff","monthDiff","dayDiff","timeString","sortedEntries","Footer","publisherDisplayName","fileSize","locales","formattedFileSize","formatBytes","languageNames","codes","displayNames","useEvent","unsubscriber","noopUnsubscriber","useEventAsync","unsubscribe","unsub"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAGA,MAAMA,KAAgBC,G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;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","x_google_ignoreList":[3,43,44,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,83,84,85,86,87,88,89,90,91,92,93,94,95,96,97,98,99,100,101,102,103,104,105,106,107,108,109,110,111,112,113,114,115,116,117,118,119,120,121,122,123,124,125,126,127,128,129,130,131,132,133,134,135,136,137,138,139,140,141,142,143,144,145,146,147,148,149,150,151,152,153,154,155,156,157,158,159,160,161,162,163,164,165,166,167,168,169,170,171,172,173,174,175,176,177,178,179,180,181,182,183,184,185,186,187,188,189,190,191,192,193,194,195,196,197,198,199,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,226]} \ No newline at end of file diff --git a/lib/platform-bible-react/src/components/advanced/settings-components/settings-sidebar-content-search.component.tsx b/lib/platform-bible-react/src/components/advanced/settings-components/settings-sidebar-content-search.component.tsx index 210a18da17..f2e252b269 100644 --- a/lib/platform-bible-react/src/components/advanced/settings-components/settings-sidebar-content-search.component.tsx +++ b/lib/platform-bible-react/src/components/advanced/settings-components/settings-sidebar-content-search.component.tsx @@ -15,7 +15,7 @@ export type SettingsSidebarContentSearchProps = SettingsSidebarProps & export default function SettingsSidebarContentSearch({ id, extensionLabels, - projectOptions, + projectInfo, children, handleSelectSidebarItem, selectedSidebarItem, @@ -36,7 +36,7 @@ export default function SettingsSidebarContentSearch({ void; @@ -48,7 +48,7 @@ export type SettingsSidebarProps = { export default function SettingsSidebar({ id, extensionLabels, - projectOptions, + projectInfo, handleSelectSidebarItem, selectedSidebarItem, extensionsSidebarGroupLabel, @@ -64,10 +64,10 @@ export default function SettingsSidebar({ const getProjectNameFromProjectId = useCallback( (projectId: string) => { - const project = projectOptions.find((option) => option.projectId === projectId); + const project = projectInfo.find((info) => info.projectId === projectId); return project ? project.projectName : projectId; }, - [projectOptions], + [projectInfo], ); const getIsActive: (label: string) => boolean = useCallback( @@ -113,7 +113,7 @@ export default function SettingsSidebar({ option.projectId)} + options={projectInfo.flatMap((info) => info.projectId)} getOptionLabel={(projectId: ComboBoxOption) => { // This function expects a ComboBoxOption, but we know it is a string // eslint-disable-next-line no-type-assertion/no-type-assertion diff --git a/lib/platform-bible-react/src/components/basics/search-bar.component.tsx b/lib/platform-bible-react/src/components/basics/search-bar.component.tsx index a4f9771bc3..b7bd0679e9 100644 --- a/lib/platform-bible-react/src/components/basics/search-bar.component.tsx +++ b/lib/platform-bible-react/src/components/basics/search-bar.component.tsx @@ -4,6 +4,7 @@ import { useState } from 'react'; /** Props for the SearchBar component. */ export type SearchBarProps = { + /** Additional css classes to help with unique styling of the search bar */ className?: string; /** * Callback fired to handle the search query when button pressed diff --git a/lib/platform-bible-react/src/index.ts b/lib/platform-bible-react/src/index.ts index e3fd8a4330..d5988fe960 100644 --- a/lib/platform-bible-react/src/index.ts +++ b/lib/platform-bible-react/src/index.ts @@ -43,7 +43,7 @@ export { export { default as SettingsSidebar, type SettingsSidebarProps, - type ProjectInfo as ProjectOptions, + type ProjectInfo, type SelectedSettingsSidebarItem, } from './components/advanced/settings-components/settings-sidebar.component'; export { default as SettingsSidebarContentSearch } from './components/advanced/settings-components/settings-sidebar-content-search.component'; From 4273a8242d6e377cc5071a1e7c43878cb06b5de6 Mon Sep 17 00:00:00 2001 From: Jolie Rabideau Date: Wed, 4 Dec 2024 12:27:35 -0500 Subject: [PATCH 15/18] Fix prop renaming, remove unused className --- .../components/settings-tabs/settings-tab.component.scss | 5 ----- .../components/settings-tabs/settings-tab.component.tsx | 4 ++-- 2 files changed, 2 insertions(+), 7 deletions(-) diff --git a/src/renderer/components/settings-tabs/settings-tab.component.scss b/src/renderer/components/settings-tabs/settings-tab.component.scss index 4ab526ac35..03ed249e20 100644 --- a/src/renderer/components/settings-tabs/settings-tab.component.scss +++ b/src/renderer/components/settings-tabs/settings-tab.component.scss @@ -12,11 +12,6 @@ overflow-y: auto; } -.sidebar { - position: relative; - overflow: hidden; -} - .sidebar-container { height: 100%; box-sizing: border-box; diff --git a/src/renderer/components/settings-tabs/settings-tab.component.tsx b/src/renderer/components/settings-tabs/settings-tab.component.tsx index dc120468c9..e9ae9ebff8 100644 --- a/src/renderer/components/settings-tabs/settings-tab.component.tsx +++ b/src/renderer/components/settings-tabs/settings-tab.component.tsx @@ -193,7 +193,7 @@ export default function SettingsTab({ projectIdToLimitSettings }: SettingsTabPro
    setSelectedSidebarItem({ label: key, projectId: projId }) } @@ -201,7 +201,7 @@ export default function SettingsTab({ projectIdToLimitSettings }: SettingsTabPro onSearch={handleSearchInput} extensionsSidebarGroupLabel={localizedStrings['%settings_sidebar_extensionsLabel%']} projectsSidebarGroupLabel={localizedStrings['%settings_sidebar_projectsLabel%']} - buttonPlaceholder={localizedStrings['%settings_sidebar_projectsComboBoxPlaceholder%']} + buttonPlaceholderText={localizedStrings['%settings_sidebar_projectsComboBoxPlaceholder%']} >
    {selectedSidebarItem.projectId From 92e9e2499380336a2f2ea7a2cbb5276c51708701 Mon Sep 17 00:00:00 2001 From: Jolie Rabideau Date: Wed, 4 Dec 2024 17:10:34 -0500 Subject: [PATCH 16/18] Comment out keydown handler in shadcn sidebar, rounded w and h to nearest hundred --- lib/platform-bible-react/dist/index.cjs | 92 +- lib/platform-bible-react/dist/index.cjs.map | 2 +- lib/platform-bible-react/dist/index.js | 1757 ++++++++--------- lib/platform-bible-react/dist/index.js.map | 2 +- .../src/components/shadcn-ui/sidebar.tsx | 26 +- .../services/web-view.service-host.ts | 2 +- 6 files changed, 938 insertions(+), 943 deletions(-) diff --git a/lib/platform-bible-react/dist/index.cjs b/lib/platform-bible-react/dist/index.cjs index c7ec89bed1..ae84fcc8d8 100644 --- a/lib/platform-bible-react/dist/index.cjs +++ b/lib/platform-bible-react/dist/index.cjs @@ -1,23 +1,23 @@ -"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const a=require("react/jsx-runtime"),g=require("react"),ee=require("lucide-react"),ot=require("clsx"),pl=require("tailwind-merge"),Ja=require("@radix-ui/react-dropdown-menu"),W=require("platform-bible-utils"),Ht=require("@radix-ui/react-slot"),kn=require("class-variance-authority"),wl=require("@radix-ui/react-label"),fl=require("@radix-ui/react-radio-group"),ml=require("@radix-ui/react-popover"),Ce=require("cmdk"),hl=require("@radix-ui/react-dialog"),ke=require("@tanstack/react-table"),gl=require("@radix-ui/react-select"),bl=require("@radix-ui/react-checkbox"),vl=require("@radix-ui/react-toggle-group"),xl=require("@radix-ui/react-toggle"),yl=require("@radix-ui/react-tabs"),Nl=require("@radix-ui/react-separator"),kl=require("@radix-ui/react-tooltip"),Fr=require("@mui/styled-engine"),Ie=require("@mui/material"),sn=require("react-dom"),Za=require("sonner"),Sl=require("@radix-ui/react-slider"),El=require("@radix-ui/react-switch"),jl=require("markdown-to-jsx");function Ne(e){const t=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(e){for(const n in e)if(n!=="default"){const r=Object.getOwnPropertyDescriptor(e,n);Object.defineProperty(t,n,r.get?r:{enumerable:!0,get:()=>e[n]})}}return t.default=e,Object.freeze(t)}const $=Ne(g),pe=Ne(Ja),Qa=Ne(wl),gn=Ne(fl),bn=Ne(ml),Ye=Ne(hl),ge=Ne(gl),Gr=Ne(bl),rr=Ne(vl),es=Ne(xl),Re=Ne(yl),ts=Ne(Nl),Sn=Ne(kl),Tl=Ne(sn),ln=Ne(Sl),Ur=Ne(El);const Cl=pl.extendTailwindMerge({prefix:"tw-"});function N(...e){return Cl(ot.clsx(e))}const St=g.forwardRef(({className:e,type:t,...n},r)=>a.jsx("input",{type:t,className:N("pr-twp tw-flex tw-h-10 tw-rounded-md tw-border tw-border-input tw-bg-background tw-px-3 tw-py-2 tw-text-sm tw-ring-offset-background file:tw-border-0 file:tw-bg-transparent file:tw-text-sm file:tw-font-medium file:tw-text-foreground placeholder:tw-text-muted-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-cursor-not-allowed disabled:tw-opacity-50",e),ref:r,...n}));St.displayName="Input";const Rl=g.forwardRef(({handleSearch:e,handleKeyDown:t,handleOnClick:n,handleSubmit:r,...o},s)=>a.jsxs("div",{className:"tw-relative",children:[a.jsx(St,{...o,type:"text",className:"tw-box-border tw-gap-2.5 tw-rounded-lg tw-border tw-border-solid tw-bg-background tw-py-2 tw-pl-4 tw-pr-3 tw-font-medium tw-shadow-none tw-outline-none",onChange:i=>e(i.target.value),onKeyDown:i=>{i.key==="Enter"&&r(),t(i)},onClick:n,ref:s}),a.jsx(ee.History,{className:"tw-absolute tw-right-3 tw-top-1/2 tw-h-4 tw-w-4 tw--translate-y-1/2 tw-transform tw-cursor-pointer tw-text-muted-foreground",onClick:()=>{console.log("back in history")}})]}));var Ol=Object.defineProperty,_l=(e,t,n)=>t in e?Ol(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,ne=(e,t,n)=>_l(e,typeof t!="symbol"?t+"":t,n);const gt=["GEN","EXO","LEV","NUM","DEU","JOS","JDG","RUT","1SA","2SA","1KI","2KI","1CH","2CH","EZR","NEH","EST","JOB","PSA","PRO","ECC","SNG","ISA","JER","LAM","EZK","DAN","HOS","JOL","AMO","OBA","JON","MIC","NAM","HAB","ZEP","HAG","ZEC","MAL","MAT","MRK","LUK","JHN","ACT","ROM","1CO","2CO","GAL","EPH","PHP","COL","1TH","2TH","1TI","2TI","TIT","PHM","HEB","JAS","1PE","2PE","1JN","2JN","3JN","JUD","REV","TOB","JDT","ESG","WIS","SIR","BAR","LJE","S3Y","SUS","BEL","1MA","2MA","3MA","4MA","1ES","2ES","MAN","PS2","ODA","PSS","JSA","JDB","TBS","SST","DNT","BLT","XXA","XXB","XXC","XXD","XXE","XXF","XXG","FRT","BAK","OTH","3ES","EZA","5EZ","6EZ","INT","CNC","GLO","TDX","NDX","DAG","PS3","2BA","LBA","JUB","ENO","1MQ","2MQ","3MQ","REP","4BA","LAO"],oo=["XXA","XXB","XXC","XXD","XXE","XXF","XXG","FRT","BAK","OTH","INT","CNC","GLO","TDX","NDX"],ns=["Genesis","Exodus","Leviticus","Numbers","Deuteronomy","Joshua","Judges","Ruth","1 Samuel","2 Samuel","1 Kings","2 Kings","1 Chronicles","2 Chronicles","Ezra","Nehemiah","Esther (Hebrew)","Job","Psalms","Proverbs","Ecclesiastes","Song of Songs","Isaiah","Jeremiah","Lamentations","Ezekiel","Daniel (Hebrew)","Hosea","Joel","Amos","Obadiah","Jonah","Micah","Nahum","Habakkuk","Zephaniah","Haggai","Zechariah","Malachi","Matthew","Mark","Luke","John","Acts","Romans","1 Corinthians","2 Corinthians","Galatians","Ephesians","Philippians","Colossians","1 Thessalonians","2 Thessalonians","1 Timothy","2 Timothy","Titus","Philemon","Hebrews","James","1 Peter","2 Peter","1 John","2 John","3 John","Jude","Revelation","Tobit","Judith","Esther Greek","Wisdom of Solomon","Sirach (Ecclesiasticus)","Baruch","Letter of Jeremiah","Song of 3 Young Men","Susanna","Bel and the Dragon","1 Maccabees","2 Maccabees","3 Maccabees","4 Maccabees","1 Esdras (Greek)","2 Esdras (Latin)","Prayer of Manasseh","Psalm 151","Odes","Psalms of Solomon","Joshua A. *obsolete*","Judges B. *obsolete*","Tobit S. *obsolete*","Susanna Th. *obsolete*","Daniel Th. *obsolete*","Bel Th. *obsolete*","Extra A","Extra B","Extra C","Extra D","Extra E","Extra F","Extra G","Front Matter","Back Matter","Other Matter","3 Ezra *obsolete*","Apocalypse of Ezra","5 Ezra (Latin Prologue)","6 Ezra (Latin Epilogue)","Introduction","Concordance ","Glossary ","Topical Index","Names Index","Daniel Greek","Psalms 152-155","2 Baruch (Apocalypse)","Letter of Baruch","Jubilees","Enoch","1 Meqabyan","2 Meqabyan","3 Meqabyan","Reproof (Proverbs 25-31)","4 Baruch (Rest of Baruch)","Laodiceans"],na=Ll();function Yt(e,t=!0){return t&&(e=e.toUpperCase()),e in na?na[e]:0}function ao(e){return Yt(e)>0}function Pl(e){const t=typeof e=="string"?Yt(e):e;return t>=40&&t<=66}function Il(e){return(typeof e=="string"?Yt(e):e)<=39}function rs(e){return e<=66}function Ml(e){const t=typeof e=="string"?Yt(e):e;return ss(t)&&!rs(t)}function*$l(){for(let e=1;e<=gt.length;e++)yield e}const Dl=1,os=gt.length;function Al(){return["XXA","XXB","XXC","XXD","XXE","XXF","XXG"]}function so(e,t="***"){const n=e-1;return n<0||n>=gt.length?t:gt[n]}function as(e){return e<=0||e>os?"******":ns[e-1]}function Bl(e){return as(Yt(e))}function ss(e){const t=typeof e=="number"?so(e):e;return ao(t)&&!oo.includes(t)}function Vl(e){const t=typeof e=="number"?so(e):e;return ao(t)&&oo.includes(t)}function zl(e){return ns[e-1].includes("*obsolete*")}function Ll(){const e={};for(let t=0;t(e[e.Unknown=0]="Unknown",e[e.Original=1]="Original",e[e.Septuagint=2]="Septuagint",e[e.Vulgate=3]="Vulgate",e[e.English=4]="English",e[e.RussianProtestant=5]="RussianProtestant",e[e.RussianOrthodox=6]="RussianOrthodox",e))(qe||{});const _e=class{constructor(t){if(ne(this,"name"),ne(this,"fullPath"),ne(this,"isPresent"),ne(this,"hasVerseSegments"),ne(this,"isCustomized"),ne(this,"baseVersification"),ne(this,"scriptureBooks"),ne(this,"_type"),t==null)throw new Error("Argument undefined");typeof t=="string"?(this.name=t,this._type=qe[t]):(this._type=t,this.name=qe[t])}get type(){return this._type}equals(t){return!t.type||!this.type?!1:t.type===this.type}};ne(_e,"Original",new _e(qe.Original)),ne(_e,"Septuagint",new _e(qe.Septuagint)),ne(_e,"Vulgate",new _e(qe.Vulgate)),ne(_e,"English",new _e(qe.English)),ne(_e,"RussianProtestant",new _e(qe.RussianProtestant)),ne(_e,"RussianOrthodox",new _e(qe.RussianOrthodox));let ut=_e;function ra(e,t){const n=t[0];for(let r=1;r(e[e.Valid=0]="Valid",e[e.UnknownVersification=1]="UnknownVersification",e[e.OutOfRange=2]="OutOfRange",e[e.VerseOutOfOrder=3]="VerseOutOfOrder",e[e.VerseRepeated=4]="VerseRepeated",e))(is||{});const Ee=class re{constructor(t,n,r,o){if(ne(this,"firstChapter"),ne(this,"lastChapter"),ne(this,"lastVerse"),ne(this,"hasSegmentsDefined"),ne(this,"text"),ne(this,"BBBCCCVVVS"),ne(this,"longHashCode"),ne(this,"versification"),ne(this,"rtlMark","‏"),ne(this,"_bookNum",0),ne(this,"_chapterNum",0),ne(this,"_verseNum",0),ne(this,"_verse"),r==null&&o==null)if(t!=null&&typeof t=="string"){const s=t,i=n!=null&&n instanceof ut?n:void 0;this.setEmpty(i),this.parse(s)}else if(t!=null&&typeof t=="number"){const s=n!=null&&n instanceof ut?n:void 0;this.setEmpty(s),this._verseNum=t%re.chapterDigitShifter,this._chapterNum=Math.floor(t%re.bookDigitShifter/re.chapterDigitShifter),this._bookNum=Math.floor(t/re.bookDigitShifter)}else if(n==null)if(t!=null&&t instanceof re){const s=t;this._bookNum=s.bookNum,this._chapterNum=s.chapterNum,this._verseNum=s.verseNum,this._verse=s.verse,this.versification=s.versification}else{if(t==null)return;const s=t instanceof ut?t:re.defaultVersification;this.setEmpty(s)}else throw new Error("VerseRef constructor not supported.");else if(t!=null&&n!=null&&r!=null)if(typeof t=="string"&&typeof n=="string"&&typeof r=="string")this.setEmpty(o),this.updateInternal(t,n,r);else if(typeof t=="number"&&typeof n=="number"&&typeof r=="number")this._bookNum=t,this._chapterNum=n,this._verseNum=r,this.versification=o??re.defaultVersification;else throw new Error("VerseRef constructor not supported.");else throw new Error("VerseRef constructor not supported.")}static isVerseParseable(t){return t.length>0&&"0123456789".includes(t[0])&&!t.endsWith(this.verseRangeSeparator)&&!t.endsWith(this.verseSequenceIndicator)}static tryParse(t){let n;try{return n=new re(t),{success:!0,verseRef:n}}catch(r){if(r instanceof tn)return n=new re,{success:!1,verseRef:n};throw r}}static getBBBCCCVVV(t,n,r){return t%re.bcvMaxValue*re.bookDigitShifter+(n>=0?n%re.bcvMaxValue*re.chapterDigitShifter:0)+(r>=0?r%re.bcvMaxValue:0)}static fromJSON(t){const{book:n,chapterNum:r,verseNum:o,verse:s,versificationStr:i}=t,l=s||o.toString();let c;return i&&(c=new ut(i)),n?new re(n,r.toString(),l,c):new re}static tryGetVerseNum(t){let n;if(!t)return n=-1,{success:!0,vNum:n};n=0;let r;for(let o=0;o"9")return o===0&&(n=-1),{success:!1,vNum:n};if(n=n*10+ +r-0,n>re.bcvMaxValue)return n=-1,{success:!1,vNum:n}}return{success:!0,vNum:n}}get isDefault(){return this.bookNum===0&&this.chapterNum===0&&this.verseNum===0&&this.versification==null}get hasMultiple(){return this._verse!=null&&(this._verse.includes(re.verseRangeSeparator)||this._verse.includes(re.verseSequenceIndicator))}get book(){return ae.bookNumberToId(this.bookNum,"")}set book(t){this.bookNum=ae.bookIdToNumber(t)}get chapter(){return this.isDefault||this._chapterNum<0?"":this._chapterNum.toString()}set chapter(t){const n=+t;this._chapterNum=Number.isInteger(n)?n:-1}get verse(){return this._verse!=null?this._verse:this.isDefault||this._verseNum<0?"":this._verseNum.toString()}set verse(t){const{success:n,vNum:r}=re.tryGetVerseNum(t);this._verse=n?void 0:t.replace(this.rtlMark,""),this._verseNum=r,!(this._verseNum>=0)&&({vNum:this._verseNum}=re.tryGetVerseNum(this._verse))}get bookNum(){return this._bookNum}set bookNum(t){if(t<=0||t>ae.lastBook)throw new tn("BookNum must be greater than zero and less than or equal to last book");this._bookNum=t}get chapterNum(){return this._chapterNum}set chapterNum(t){this.chapterNum=t}get verseNum(){return this._verseNum}set verseNum(t){this._verseNum=t}get versificationStr(){var t;return(t=this.versification)==null?void 0:t.name}set versificationStr(t){this.versification=this.versification!=null?new ut(t):void 0}get valid(){return this.validStatus===0}get validStatus(){return this.validateVerse(re.verseRangeSeparators,re.verseSequenceIndicators)}get BBBCCC(){return re.getBBBCCCVVV(this._bookNum,this._chapterNum,0)}get BBBCCCVVV(){return re.getBBBCCCVVV(this._bookNum,this._chapterNum,this._verseNum)}get isExcluded(){return!1}parse(t){if(t=t.replace(this.rtlMark,""),t.includes("/")){const s=t.split("/");if(t=s[0],s.length>1)try{const i=+s[1].trim();this.versification=new ut(qe[i])}catch{throw new tn("Invalid reference : "+t)}}const n=t.trim().split(" ");if(n.length!==2)throw new tn("Invalid reference : "+t);const r=n[1].split(":"),o=+r[0];if(r.length!==2||ae.bookIdToNumber(n[0])===0||!Number.isInteger(o)||o<0||!re.isVerseParseable(r[1]))throw new tn("Invalid reference : "+t);this.updateInternal(n[0],r[0],r[1])}simplify(){this._verse=void 0}clone(){return new re(this)}toString(){const t=this.book;return t===""?"":`${t} ${this.chapter}:${this.verse}`}toJSON(){let t=this.verse;(t===""||t===this.verseNum.toString())&&(t=void 0);const n={book:this.book,chapterNum:this.chapterNum,verseNum:this.verseNum,verse:t,versificationStr:this.versificationStr};return t||delete n.verse,n}equals(t){return t instanceof re?t._bookNum===this._bookNum&&t._chapterNum===this._chapterNum&&t._verseNum===this._verseNum&&t.verse===this.verse&&(t.versification==null&&this.versification==null||t.versification!=null&&this.versification!=null&&t.versification.equals(this.versification)):!1}allVerses(t=!1,n=re.verseRangeSeparators,r=re.verseSequenceIndicators){if(this._verse==null||this.chapterNum<=0)return[this.clone()];const o=[],s=ra(this._verse,r);for(const i of s.map(l=>ra(l,n))){const l=this.clone();l.verse=i[0];const c=l.verseNum;if(o.push(l),i.length>1){const d=this.clone();if(d.verse=i[1],!t)for(let u=c+1;ui)return 3;if(r===i)return 4;r=i}return 0}get internalValid(){return this.versification==null?1:this._bookNum<=0||this._bookNum>ae.lastBook?2:(ae.isCanonical(this._bookNum),0)}setEmpty(t=re.defaultVersification){this._bookNum=0,this._chapterNum=-1,this._verse=void 0,this.versification=t}updateInternal(t,n,r){this.bookNum=ae.bookIdToNumber(t),this.chapter=n,this.verse=r}};ne(Ee,"defaultVersification",ut.English),ne(Ee,"verseRangeSeparator","-"),ne(Ee,"verseSequenceIndicator",","),ne(Ee,"verseRangeSeparators",[Ee.verseRangeSeparator]),ne(Ee,"verseSequenceIndicators",[Ee.verseSequenceIndicator]),ne(Ee,"chapterDigitShifter",1e3),ne(Ee,"bookDigitShifter",Ee.chapterDigitShifter*Ee.chapterDigitShifter),ne(Ee,"bcvMaxValue",Ee.chapterDigitShifter-1),ne(Ee,"ValidStatusType",is);class tn extends Error{}const or=pe.Root,io=pe.Trigger,ls=pe.Group,Fl=pe.Portal,Gl=pe.Sub,Ul=pe.RadioGroup,cs=g.forwardRef(({className:e,inset:t,children:n,...r},o)=>a.jsxs(pe.SubTrigger,{ref:o,className:N("tw-flex tw-cursor-default tw-select-none tw-items-center tw-rounded-sm tw-px-2 tw-py-1.5 tw-text-sm tw-outline-none focus:tw-bg-accent data-[state=open]:tw-bg-accent",t&&"tw-pl-8",e),...r,children:[n,a.jsx(ee.ChevronRight,{className:"tw-ml-auto tw-h-4 tw-w-4"})]}));cs.displayName=pe.SubTrigger.displayName;const ds=g.forwardRef(({className:e,...t},n)=>a.jsx(pe.SubContent,{ref:n,className:N("tw-z-50 tw-min-w-[8rem] tw-overflow-hidden tw-rounded-md tw-border tw-bg-popover tw-p-1 tw-text-popover-foreground tw-shadow-lg data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0 data-[state=closed]:tw-zoom-out-95 data-[state=open]:tw-zoom-in-95 data-[side=bottom]:tw-slide-in-from-top-2 data-[side=left]:tw-slide-in-from-right-2 data-[side=right]:tw-slide-in-from-left-2 data-[side=top]:tw-slide-in-from-bottom-2",e),...t}));ds.displayName=pe.SubContent.displayName;const En=g.forwardRef(({className:e,sideOffset:t=4,...n},r)=>a.jsx(pe.Portal,{children:a.jsx(pe.Content,{ref:r,sideOffset:t,className:N("pr-twp tw-z-50 tw-min-w-[8rem] tw-overflow-hidden tw-rounded-md tw-border tw-bg-popover tw-p-1 tw-text-popover-foreground tw-shadow-md data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0 data-[state=closed]:tw-zoom-out-95 data-[state=open]:tw-zoom-in-95 data-[side=bottom]:tw-slide-in-from-top-2 data-[side=left]:tw-slide-in-from-right-2 data-[side=right]:tw-slide-in-from-left-2 data-[side=top]:tw-slide-in-from-bottom-2",e),...n})}));En.displayName=pe.Content.displayName;const lo=g.forwardRef(({className:e,inset:t,...n},r)=>a.jsx(pe.Item,{ref:r,className:N("tw-cursor-default tw-select-none tw-items-center tw-rounded-sm tw-px-2 tw-py-1.5 tw-text-sm tw-outline-none tw-transition-colors focus:tw-bg-accent data-[disabled]:tw-pointer-events-none data-[disabled]:tw-opacity-50",t&&"tw-pl-8",e),...n}));lo.displayName=pe.Item.displayName;const ar=g.forwardRef(({className:e,children:t,checked:n,...r},o)=>a.jsxs(pe.CheckboxItem,{ref:o,className:N("tw-relative tw-flex tw-cursor-default tw-select-none tw-items-center tw-rounded-sm tw-py-1.5 tw-pl-8 tw-pr-2 tw-text-sm tw-outline-none tw-transition-colors focus:tw-bg-accent focus:tw-text-accent-foreground data-[disabled]:tw-pointer-events-none data-[disabled]:tw-opacity-50",e),checked:n,...r,children:[a.jsx("span",{className:"tw-absolute tw-left-2 tw-flex tw-h-3.5 tw-w-3.5 tw-items-center tw-justify-center",children:a.jsx(pe.ItemIndicator,{children:a.jsx(ee.Check,{className:"tw-h-4 tw-w-4"})})}),t]}));ar.displayName=pe.CheckboxItem.displayName;const co=g.forwardRef(({className:e,children:t,...n},r)=>a.jsxs(pe.RadioItem,{ref:r,className:N("tw-relative tw-flex tw-cursor-default tw-select-none tw-items-center tw-rounded-sm tw-py-1.5 tw-pl-8 tw-pr-2 tw-text-sm tw-outline-none tw-transition-colors focus:tw-bg-accent focus:tw-text-accent-foreground data-[disabled]:tw-pointer-events-none data-[disabled]:tw-opacity-50",e),...n,children:[a.jsx("span",{className:"tw-absolute tw-left-2 tw-flex tw-h-3.5 tw-w-3.5 tw-items-center tw-justify-center",children:a.jsx(pe.ItemIndicator,{children:a.jsx(ee.Circle,{className:"tw-h-2 tw-w-2 tw-fill-current"})})}),t]}));co.displayName=pe.RadioItem.displayName;const Xt=g.forwardRef(({className:e,inset:t,...n},r)=>a.jsx(pe.Label,{ref:r,className:N("tw-px-2 tw-py-1.5 tw-text-sm tw-font-semibold",t&&"tw-pl-8",e),...n}));Xt.displayName=pe.Label.displayName;const jn=g.forwardRef(({className:e,...t},n)=>a.jsx(pe.Separator,{ref:n,className:N("tw--mx-1 tw-my-1 tw-h-px tw-bg-muted",e),...t}));jn.displayName=pe.Separator.displayName;function us({className:e,...t}){return a.jsx("span",{className:N("tw-ml-auto tw-text-xs tw-tracking-widest tw-opacity-60",e),...t})}us.displayName="DropdownMenuShortcut";const ql=g.forwardRef(({bookId:e,handleSelectBook:t,isSelected:n,handleHighlightBook:r,handleKeyDown:o,bookType:s,children:i},l)=>a.jsxs(lo,{ref:l,textValue:e,className:N("tw-mx-1 tw-px-1 tw-font-normal tw-text-foreground/80",{"tw-bg-amber-50 tw-text-yellow-900 data-[highlighted]:tw-bg-amber-100":n}),onSelect:c=>{c.preventDefault(),t()},onKeyDown:c=>{o(c)},onFocus:r,onMouseMove:r,children:[a.jsx("span",{className:N("tw-border-b-0 tw-border-l-2 tw-border-r-0 tw-border-t-0 tw-border-solid tw-px-2",{"tw-font-bold":n,"tw-border-l-red-200":s.toLowerCase()==="ot","tw-border-l-purple-200":s.toLowerCase()==="nt","tw-border-l-indigo-200":s.toLowerCase()==="dc"}),children:ae.bookIdToEnglishName(e)}),n&&a.jsx("div",{children:i})]},e));function Hl({handleSelectChapter:e,endChapter:t,activeChapter:n,highlightedChapter:r,handleHighlightedChapter:o}){const s=Array.from({length:t},(l,c)=>c+1),i=g.useCallback(l=>{o(l)},[o]);return a.jsx("div",{className:N("tw-flex tw-flex-wrap tw-items-start tw-justify-start tw-self-stretch"),children:s.map(l=>a.jsx("div",{className:N("tw-box-content tw-flex tw-h-4 tw-w-4 tw-cursor-pointer tw-items-center tw-justify-end tw-rounded-md tw-p-2 tw-text-amber-800",{"tw-font-semibold tw-text-amber-900":l===n,"tw-bg-amber-200":l===r}),onClick:c=>{c.preventDefault(),c.stopPropagation(),e(l)},role:"button",onKeyDown:c=>{c.key==="Enter"&&e(l)},tabIndex:0,onMouseMove:()=>i(l),children:l},l))})}function Yl({handleSort:e,handleLocationHistory:t,handleBookmarks:n}){return a.jsxs(Xt,{className:"tw-flex tw-justify-between",children:[a.jsx("p",{className:"tw-inline-block tw-align-middle",children:"Go To"}),a.jsxs("div",{className:"tw-flex tw-items-center",children:[a.jsx(ee.ArrowDownWideNarrow,{onClick:e,className:"tw-m-2 tw-h-4 tw-w-4 tw-cursor-pointer tw-gap-2"}),a.jsx(ee.Clock,{onClick:t,className:"tw-m-2 tw-h-4 tw-w-4 tw-cursor-pointer tw-gap-2"}),a.jsx(ee.Bookmark,{onClick:n,className:"tw-m-2 tw-h-4 tw-w-4 tw-cursor-pointer tw-gap-2"})]})]})}const pn=ae.allBookIds,Xl={OT:"Old Testament",NT:"New Testament",DC:"Deuterocanon"},oa=["OT","NT","DC"],Wl=32+32+32,Kl=[/^(\w+)$/i,/^(\w+)(?:\s(\d+))$/i,/^(\w+)(?:\s(\d+):(\d+))$/i],Jl=e=>({OT:pn.filter(n=>ae.isBookOT(n)),NT:pn.filter(n=>ae.isBookNT(n)),DC:pn.filter(n=>ae.isBookDC(n))})[e],nn=e=>W.getChaptersForBook(ae.bookIdToNumber(e));function Zl(){return pn.map(t=>ae.bookIdToEnglishName(t))}function Ql(e){return Zl().includes(e)}function ec(e){const t=e.toLowerCase().replace(/^\w/,n=>n.toUpperCase());if(Ql(t))return pn.find(r=>ae.bookIdToEnglishName(r)===t)}function tc({scrRef:e,handleSubmit:t}){const[n,r]=g.useState(""),[o,s]=g.useState(ae.bookNumberToId(e.bookNum)),[i,l]=g.useState(e.chapterNum??0),[c,d]=g.useState(ae.bookNumberToId(e.bookNum)),[u,f]=g.useState(!1),[w,b]=g.useState(u),x=g.useRef(void 0),m=g.useRef(void 0),h=g.useRef(void 0),E=g.useCallback(k=>Jl(k).filter(D=>{const M=ae.bookIdToEnglishName(D).toLowerCase(),J=n.replace(/[^a-zA-Z]/g,"").toLowerCase();return M.includes(J)||D.toLowerCase().includes(J)}),[n]),I=k=>{r(k)},C=g.useRef(!1),S=g.useCallback(k=>{if(C.current){C.current=!1;return}f(k)},[]),v=g.useCallback((k,D,M,J)=>{if(l(ae.bookNumberToId(e.bookNum)!==k?1:e.chapterNum),D||nn(k)===-1){t({bookNum:ae.bookIdToNumber(k),chapterNum:M||1,verseNum:J||1}),f(!1),r("");return}s(o!==k?k:""),f(!D)},[t,e.bookNum,e.chapterNum,o]),_=k=>{k<=0||k>nn(o)||v(o,!0,k)},V=g.useCallback(()=>{Kl.forEach(k=>{const D=n.match(k);if(D){const[M,J=void 0,X=void 0]=D.slice(1),F=ec(M);(ae.isBookIdValid(M)||F)&&v(F??M,!0,J?parseInt(J,10):1,X?parseInt(X,10):1)}})},[v,n]),U=g.useCallback(k=>{u?(k.key==="ArrowDown"||k.key==="ArrowUp")&&(typeof h<"u"&&h.current!==null?h.current.focus():typeof m<"u"&&m.current!==null&&m.current.focus(),k.preventDefault()):f(!0)},[u]),j=k=>{const{key:D}=k;D==="ArrowRight"||D==="ArrowLeft"||D==="ArrowDown"||D==="ArrowUp"||D==="Enter"||(x.current.dispatchEvent(new KeyboardEvent("keydown",{key:D})),x.current.focus())},O=k=>{const{key:D}=k;if(c===o){if(D==="Enter"){k.preventDefault(),v(o,!0,i);return}let M=0;if(D==="ArrowRight")if(i1)M=-1;else{k.preventDefault();return}else D==="ArrowDown"?M=6:D==="ArrowUp"&&(M=-6);i+M<=0||i+M>nn(c)?l(0):M!==0&&(l(i+M),k.preventDefault())}};return g.useEffect(()=>{o===c?o===ae.bookNumberToId(e.bookNum)?l(e.chapterNum):l(1):l(0)},[c,e.bookNum,e.chapterNum,o]),g.useLayoutEffect(()=>{b(u)},[u]),g.useLayoutEffect(()=>{const k=setTimeout(()=>{if(w&&m.current&&h.current){const M=h.current.offsetTop-Wl;m.current.scrollTo({top:M,behavior:"instant"})}},10);return()=>{clearTimeout(k)}},[w]),a.jsx("div",{className:"pr-twp tw-flex",children:a.jsxs(or,{modal:!1,open:u,onOpenChange:S,children:[a.jsx(io,{asChild:!0,children:a.jsx(Rl,{ref:x,value:n,handleSearch:I,handleKeyDown:U,handleOnClick:()=>{s(ae.bookNumberToId(e.bookNum)),d(ae.bookNumberToId(e.bookNum)),l(e.chapterNum>0?e.chapterNum:0),f(!0),x.current.focus()},onFocus:()=>{C.current=!0},handleSubmit:V,placeholder:`${ae.bookNumberToEnglishName(e.bookNum)} ${e.chapterNum}:${e.verseNum}`})}),a.jsxs(En,{className:"tw-m-1 tw-overflow-y-auto tw-p-0 tw-font-normal tw-text-foreground/80",style:{width:"233px",maxHeight:"500px",zIndex:"250"},onKeyDown:j,align:"start",ref:m,children:[a.jsx(Yl,{handleSort:()=>console.log("sorting"),handleLocationHistory:()=>console.log("location history"),handleBookmarks:()=>console.log("bookmarks")}),oa.map((k,D)=>E(k).length>0&&a.jsxs("div",{children:[a.jsx(Xt,{className:"tw-font-semibold tw-text-foreground/80",children:Xl[k]}),E(k).map(M=>a.jsx("div",{children:a.jsx(ql,{bookId:M,handleSelectBook:()=>v(M,!1),isSelected:o===M,handleHighlightBook:()=>d(M),handleKeyDown:O,bookType:k,ref:J=>{o===M&&(h.current=J)},children:a.jsx(Hl,{handleSelectChapter:_,endChapter:nn(M),activeChapter:e.bookNum===ae.bookIdToNumber(M)?e.chapterNum:0,highlightedChapter:i,handleHighlightedChapter:J=>{l(J)}})})},M)),oa.length-1!==D?a.jsx(jn,{}):void 0]},k))]})]})})}const ps=kn.cva("pr-twp tw-inline-flex tw-items-center tw-justify-center tw-whitespace-nowrap tw-rounded-md tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-colors focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50",{variants:{variant:{default:"tw-bg-primary tw-text-primary-foreground hover:tw-bg-primary/90",destructive:"tw-bg-destructive tw-text-destructive-foreground hover:tw-bg-destructive/90",outline:"tw-border tw-border-input tw-bg-background hover:tw-bg-accent hover:tw-text-accent-foreground",secondary:"tw-bg-secondary tw-text-secondary-foreground hover:tw-bg-secondary/80",ghost:"hover:tw-bg-accent hover:tw-text-accent-foreground",link:"tw-text-primary tw-underline-offset-4 hover:tw-underline"},size:{default:"tw-h-10 tw-px-4 tw-py-2",sm:"tw-h-9 tw-rounded-md tw-px-3",lg:"tw-h-11 tw-rounded-md tw-px-8",icon:"tw-h-10 tw-w-10"}},defaultVariants:{variant:"default",size:"default"}}),fe=g.forwardRef(({className:e,variant:t,size:n,asChild:r=!1,...o},s)=>{const i=r?Ht.Slot:"button";return a.jsx(i,{className:N(ps({variant:t,size:n,className:e})),ref:s,...o})});fe.displayName="Button";const nc=kn.cva("tw-text-sm tw-font-medium tw-leading-none peer-disabled:tw-cursor-not-allowed peer-disabled:tw-opacity-70"),Ue=g.forwardRef(({className:e,...t},n)=>a.jsx(Qa.Root,{ref:n,className:N("pr-twp",nc(),e),...t}));Ue.displayName=Qa.Root.displayName;const uo=g.forwardRef(({className:e,...t},n)=>a.jsx(gn.Root,{className:N("pr-twp tw-grid tw-gap-2",e),...t,ref:n}));uo.displayName=gn.Root.displayName;const Xn=g.forwardRef(({className:e,...t},n)=>a.jsx(gn.Item,{ref:n,className:N("pr-twp tw-aspect-square tw-h-4 tw-w-4 tw-rounded-full tw-border tw-border-primary tw-text-primary tw-ring-offset-background focus:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-cursor-not-allowed disabled:tw-opacity-50",e),...t,children:a.jsx(gn.Indicator,{className:"tw-flex tw-items-center tw-justify-center",children:a.jsx(ee.Circle,{className:"tw-h-2.5 tw-w-2.5 tw-fill-current tw-text-current"})})}));Xn.displayName=gn.Item.displayName;const rc=bn.Root,oc=bn.Trigger,ws=g.forwardRef(({className:e,align:t="center",sideOffset:n=4,...r},o)=>a.jsx(bn.Portal,{children:a.jsx(bn.Content,{ref:o,align:t,sideOffset:n,className:N("pr-twp tw-z-50 tw-w-72 tw-rounded-md tw-border tw-bg-popover tw-p-4 tw-text-popover-foreground tw-shadow-md tw-outline-none data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0 data-[state=closed]:tw-zoom-out-95 data-[state=open]:tw-zoom-in-95 data-[side=bottom]:tw-slide-in-from-top-2 data-[side=left]:tw-slide-in-from-right-2 data-[side=right]:tw-slide-in-from-left-2 data-[side=top]:tw-slide-in-from-bottom-2",e),...r})}));ws.displayName=bn.Content.displayName;const ac=Ye.Portal,fs=g.forwardRef(({className:e,...t},n)=>a.jsx(Ye.Overlay,{ref:n,className:N("tw-fixed tw-inset-0 tw-z-50 tw-bg-black/80 data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0",e),...t}));fs.displayName=Ye.Overlay.displayName;const sc=g.forwardRef(({className:e,children:t,...n},r)=>a.jsxs(ac,{children:[a.jsx(fs,{}),a.jsxs(Ye.Content,{ref:r,className:N("tw-fixed tw-left-[50%] tw-top-[50%] tw-z-50 tw-grid tw-w-full tw-max-w-lg tw-translate-x-[-50%] tw-translate-y-[-50%] tw-gap-4 tw-border tw-bg-background tw-p-6 tw-shadow-lg tw-duration-200 data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0 data-[state=closed]:tw-zoom-out-95 data-[state=open]:tw-zoom-in-95 data-[state=closed]:tw-slide-out-to-left-1/2 data-[state=closed]:tw-slide-out-to-top-[48%] data-[state=open]:tw-slide-in-from-left-1/2 data-[state=open]:tw-slide-in-from-top-[48%] sm:tw-rounded-lg",e),...n,children:[t,a.jsxs(Ye.Close,{className:"tw-absolute tw-right-4 tw-top-4 tw-rounded-sm tw-opacity-70 tw-ring-offset-background tw-transition-opacity hover:tw-opacity-100 focus:tw-outline-none focus:tw-ring-2 focus:tw-ring-ring focus:tw-ring-offset-2 disabled:tw-pointer-events-none data-[state=open]:tw-bg-accent data-[state=open]:tw-text-muted-foreground",children:[a.jsx(ee.X,{className:"tw-h-4 tw-w-4"}),a.jsx("span",{className:"tw-sr-only",children:"Close"})]})]})]}));sc.displayName=Ye.Content.displayName;const ic=g.forwardRef(({className:e,...t},n)=>a.jsx(Ye.Title,{ref:n,className:N("tw-text-lg tw-font-semibold tw-leading-none tw-tracking-tight",e),...t}));ic.displayName=Ye.Title.displayName;const lc=g.forwardRef(({className:e,...t},n)=>a.jsx(Ye.Description,{ref:n,className:N("tw-text-sm tw-text-muted-foreground",e),...t}));lc.displayName=Ye.Description.displayName;const ms=g.forwardRef(({className:e,...t},n)=>a.jsx(Ce.Command,{ref:n,className:N("tw-flex tw-h-full tw-w-full tw-flex-col tw-overflow-hidden tw-rounded-md tw-bg-popover tw-text-popover-foreground",e),...t}));ms.displayName=Ce.Command.displayName;const hs=g.forwardRef(({className:e,...t},n)=>a.jsxs("div",{className:"tw-flex tw-items-center tw-border-b tw-px-3",children:[a.jsx(ee.Search,{className:"tw-me-2 tw-h-4 tw-w-4 tw-shrink-0 tw-opacity-50"}),a.jsx(Ce.Command.Input,{ref:n,className:N("tw-flex tw-h-11 tw-w-full tw-rounded-md tw-bg-transparent tw-py-3 tw-text-sm tw-outline-none placeholder:tw-text-muted-foreground disabled:tw-cursor-not-allowed disabled:tw-opacity-50",e),...t})]}));hs.displayName=Ce.Command.Input.displayName;const gs=g.forwardRef(({className:e,...t},n)=>a.jsx(Ce.Command.List,{ref:n,className:N("tw-max-h-[300px] tw-overflow-y-auto tw-overflow-x-hidden",e),...t}));gs.displayName=Ce.Command.List.displayName;const bs=g.forwardRef((e,t)=>a.jsx(Ce.Command.Empty,{ref:t,className:"tw-py-6 tw-text-center tw-text-sm",...e}));bs.displayName=Ce.Command.Empty.displayName;const cc=g.forwardRef(({className:e,...t},n)=>a.jsx(Ce.Command.Group,{ref:n,className:N("tw-overflow-hidden tw-p-1 tw-text-foreground [&_[cmdk-group-heading]]:tw-px-2 [&_[cmdk-group-heading]]:tw-py-1.5 [&_[cmdk-group-heading]]:tw-text-xs [&_[cmdk-group-heading]]:tw-font-medium [&_[cmdk-group-heading]]:tw-text-muted-foreground",e),...t}));cc.displayName=Ce.Command.Group.displayName;const dc=g.forwardRef(({className:e,...t},n)=>a.jsx(Ce.Command.Separator,{ref:n,className:N("tw--mx-1 tw-h-px tw-bg-border",e),...t}));dc.displayName=Ce.Command.Separator.displayName;const vs=g.forwardRef(({className:e,...t},n)=>a.jsx(Ce.Command.Item,{ref:n,className:N("tw-relative tw-flex tw-cursor-default tw-select-none tw-items-center tw-rounded-sm tw-px-2 tw-py-1.5 tw-text-sm tw-outline-none data-[disabled=true]:tw-pointer-events-none data-[selected=true]:tw-bg-accent data-[selected=true]:tw-text-accent-foreground data-[disabled=true]:tw-opacity-50",e),...t}));vs.displayName=Ce.Command.Item.displayName;function uc(e){return typeof e=="string"?e:typeof e=="number"?e.toString():e.label}function Wn({id:e,options:t=[],buttonClassName:n,popoverContentClassName:r,value:o,onChange:s=()=>{},getOptionLabel:i=uc,buttonPlaceholder:l="",textPlaceholder:c="",commandEmptyMessage:d="No option found",buttonVariant:u="outline",dir:f="ltr",isDisabled:w=!1,...b}){const[x,m]=g.useState(!1);return a.jsxs(rc,{open:x,onOpenChange:m,...b,children:[a.jsx(oc,{asChild:!0,children:a.jsxs(fe,{variant:u,role:"combobox","aria-expanded":x,id:e,className:N("tw-w-[200px] tw-justify-between",n),disabled:w,children:[a.jsx("span",{className:"tw-overflow-hidden tw-text-ellipsis tw-whitespace-nowrap",children:o?i(o):l}),a.jsx(ee.ChevronsUpDown,{className:"tw-ms-2 tw-h-4 tw-w-4 tw-shrink-0 tw-opacity-50"})]})}),a.jsx(ws,{className:N("tw-w-[200px] tw-p-0",r),dir:f,children:a.jsxs(ms,{children:[a.jsx(hs,{dir:f,placeholder:c,className:"tw-text-inherit"}),a.jsx(bs,{children:d}),a.jsx(gs,{children:t.map(h=>a.jsxs(vs,{value:i(h),onSelect:()=>{s(h),m(!1)},children:[a.jsx(ee.Check,{className:N("tw-me-2 tw-h-4 tw-w-4",{"tw-opacity-0":!o||i(o)!==i(h)})}),i(h)]},i(h)))})]})})]})}function xs({startChapter:e,endChapter:t,handleSelectStartChapter:n,handleSelectEndChapter:r,isDisabled:o=!1,chapterCount:s}){const i=g.useMemo(()=>Array.from({length:s},(d,u)=>u+1),[s]),l=d=>{n(d),d>t&&r(d)},c=d=>{r(d),dd.toString(),value:e},"start chapter"),a.jsx(Ue,{htmlFor:"end-chapters-combobox",children:"to"}),a.jsx(Wn,{isDisabled:o,onChange:c,buttonClassName:"tw-ml-2 tw-w-20",options:i,getOptionLabel:d=>d.toString(),value:t},"end chapter")]})}var ys=(e=>(e.CURRENT_BOOK="current book",e.CHOOSE_BOOKS="choose books",e))(ys||{});const pc=Object.freeze(["%webView_bookSelector_currentBook%","%webView_bookSelector_choose%","%webView_bookSelector_chooseBooks%"]),Cr=(e,t)=>e[t]??t;function wc({handleBookSelectionModeChange:e,currentBookName:t,onSelectBooks:n,selectedBookIds:r,chapterCount:o,endChapter:s,handleSelectEndChapter:i,startChapter:l,handleSelectStartChapter:c,localizedStrings:d}){const u=Cr(d,"%webView_bookSelector_currentBook%"),f=Cr(d,"%webView_bookSelector_choose%"),w=Cr(d,"%webView_bookSelector_chooseBooks%"),[b,x]=g.useState("current book"),m=h=>{x(h),e(h)};return a.jsx(uo,{className:"pr-twp tw-flex",value:b,onValueChange:h=>m(h),children:a.jsxs("div",{className:"tw-flex tw-w-full tw-flex-col tw-gap-4",children:[a.jsxs("div",{className:"tw-grid tw-grid-cols-[25%,25%,50%]",children:[a.jsxs("div",{className:"tw-flex tw-items-center",children:[a.jsx(Xn,{value:"current book"}),a.jsx(Ue,{className:"tw-ml-1",children:u})]}),a.jsx(Ue,{className:"tw-flex tw-items-center",children:t}),a.jsx("div",{className:"tw-flex tw-items-center tw-justify-end",children:a.jsx(xs,{isDisabled:b==="choose books",handleSelectStartChapter:c,handleSelectEndChapter:i,chapterCount:o,startChapter:l,endChapter:s})})]}),a.jsxs("div",{className:"tw-grid tw-grid-cols-[25%,50%,25%]",children:[a.jsxs("div",{className:"tw-flex tw-items-center",children:[a.jsx(Xn,{value:"choose books"}),a.jsx(Ue,{className:"tw-ml-1",children:w})]}),a.jsx(Ue,{className:"tw-flex tw-items-center",children:r.map(h=>ae.bookIdToEnglishName(h)).join(", ")}),a.jsx(fe,{disabled:b==="current book",onClick:()=>n(),children:f})]})]})})}function fc({table:e}){return a.jsxs(or,{children:[a.jsx(Ja.DropdownMenuTrigger,{asChild:!0,children:a.jsxs(fe,{variant:"outline",size:"sm",className:"tw-ml-auto tw-hidden tw-h-8 lg:tw-flex",children:[a.jsx(ee.FilterIcon,{className:"tw-mr-2 tw-h-4 tw-w-4"}),"View"]})}),a.jsxs(En,{align:"end",className:"tw-w-[150px]",children:[a.jsx(Xt,{children:"Toggle columns"}),a.jsx(jn,{}),e.getAllColumns().filter(t=>t.getCanHide()).map(t=>a.jsx(ar,{className:"tw-capitalize",checked:t.getIsVisible(),onCheckedChange:n=>t.toggleVisibility(!!n),children:t.id},t.id))]})]})}const At=ge.Root,Ns=ge.Group,Bt=ge.Value,bt=g.forwardRef(({className:e,children:t,...n},r)=>a.jsxs(ge.Trigger,{ref:r,className:N("tw-flex tw-h-10 tw-w-full tw-items-center tw-justify-between tw-rounded-md tw-border tw-border-input tw-bg-background tw-px-3 tw-py-2 tw-text-sm tw-ring-offset-background placeholder:tw-text-muted-foreground focus:tw-outline-none focus:tw-ring-2 focus:tw-ring-ring focus:tw-ring-offset-2 disabled:tw-cursor-not-allowed disabled:tw-opacity-50 [&>span]:tw-line-clamp-1",e),...n,children:[t,a.jsx(ge.Icon,{asChild:!0,children:a.jsx(ee.ChevronDown,{className:"tw-h-4 tw-w-4 tw-opacity-50"})})]}));bt.displayName=ge.Trigger.displayName;const po=g.forwardRef(({className:e,...t},n)=>a.jsx(ge.ScrollUpButton,{ref:n,className:N("tw-flex tw-cursor-default tw-items-center tw-justify-center tw-py-1",e),...t,children:a.jsx(ee.ChevronUp,{className:"tw-h-4 tw-w-4"})}));po.displayName=ge.ScrollUpButton.displayName;const wo=g.forwardRef(({className:e,...t},n)=>a.jsx(ge.ScrollDownButton,{ref:n,className:N("tw-flex tw-cursor-default tw-items-center tw-justify-center tw-py-1",e),...t,children:a.jsx(ee.ChevronDown,{className:"tw-h-4 tw-w-4"})}));wo.displayName=ge.ScrollDownButton.displayName;const vt=g.forwardRef(({className:e,children:t,position:n="popper",...r},o)=>a.jsx(ge.Portal,{children:a.jsxs(ge.Content,{ref:o,className:N("pr-twp tw-relative tw-z-50 tw-max-h-96 tw-min-w-[8rem] tw-overflow-hidden tw-rounded-md tw-border tw-bg-popover tw-text-popover-foreground tw-shadow-md data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0 data-[state=closed]:tw-zoom-out-95 data-[state=open]:tw-zoom-in-95 data-[side=bottom]:tw-slide-in-from-top-2 data-[side=left]:tw-slide-in-from-right-2 data-[side=right]:tw-slide-in-from-left-2 data-[side=top]:tw-slide-in-from-bottom-2",n==="popper"&&"data-[side=bottom]:tw-translate-y-1 data-[side=left]:tw--translate-x-1 data-[side=right]:tw-translate-x-1 data-[side=top]:tw--translate-y-1",e),position:n,...r,children:[a.jsx(po,{}),a.jsx(ge.Viewport,{className:N("tw-p-1",n==="popper"&&"tw-h-[var(--radix-select-trigger-height)] tw-w-full tw-min-w-[var(--radix-select-trigger-width)]"),children:t}),a.jsx(wo,{})]})}));vt.displayName=ge.Content.displayName;const ks=g.forwardRef(({className:e,...t},n)=>a.jsx(ge.Label,{ref:n,className:N("tw-py-1.5 tw-pl-8 tw-pr-2 tw-text-sm tw-font-semibold",e),...t}));ks.displayName=ge.Label.displayName;const De=g.forwardRef(({className:e,children:t,...n},r)=>a.jsxs(ge.Item,{ref:r,className:N("tw-relative tw-flex tw-w-full tw-cursor-default tw-select-none tw-items-center tw-rounded-sm tw-py-1.5 tw-pl-8 tw-pr-2 tw-text-sm tw-outline-none focus:tw-bg-accent focus:tw-text-accent-foreground data-[disabled]:tw-pointer-events-none data-[disabled]:tw-opacity-50",e),...n,children:[a.jsx("span",{className:"tw-absolute tw-left-2 tw-flex tw-h-3.5 tw-w-3.5 tw-items-center tw-justify-center",children:a.jsx(ge.ItemIndicator,{children:a.jsx(ee.Check,{className:"tw-h-4 tw-w-4"})})}),a.jsx(ge.ItemText,{children:t})]}));De.displayName=ge.Item.displayName;const Ss=g.forwardRef(({className:e,...t},n)=>a.jsx(ge.Separator,{ref:n,className:N("tw--mx-1 tw-my-1 tw-h-px tw-bg-muted",e),...t}));Ss.displayName=ge.Separator.displayName;function mc({table:e}){return a.jsx("div",{className:"tw-flex tw-items-center tw-justify-between tw-px-2 tw-pb-3 tw-pt-3",children:a.jsxs("div",{className:"tw-flex tw-items-center tw-space-x-6 lg:tw-space-x-8",children:[a.jsxs("div",{className:"tw-flex-1 tw-text-sm tw-text-muted-foreground",children:[e.getFilteredSelectedRowModel().rows.length," of"," ",e.getFilteredRowModel().rows.length," row(s) selected"]}),a.jsxs("div",{className:"tw-flex tw-items-center tw-space-x-2",children:[a.jsx("p",{className:"tw-text-nowrap tw-text-sm tw-font-medium",children:"Rows per page"}),a.jsxs(At,{value:`${e.getState().pagination.pageSize}`,onValueChange:t=>{e.setPageSize(Number(t))},children:[a.jsx(bt,{className:"tw-h-8 tw-w-[70px]",children:a.jsx(Bt,{placeholder:e.getState().pagination.pageSize})}),a.jsx(vt,{side:"top",children:[10,20,30,40,50].map(t=>a.jsx(De,{value:`${t}`,children:t},t))})]})]}),a.jsxs("div",{className:"tw-flex tw-w-[100px] tw-items-center tw-justify-center tw-text-sm tw-font-medium",children:["Page ",e.getState().pagination.pageIndex+1," of ",e.getPageCount()]}),a.jsxs("div",{className:"tw-flex tw-items-center tw-space-x-2",children:[a.jsxs(fe,{variant:"outline",size:"icon",className:"tw-hidden tw-h-8 tw-w-8 tw-p-0 lg:tw-flex",onClick:()=>e.setPageIndex(0),disabled:!e.getCanPreviousPage(),children:[a.jsx("span",{className:"tw-sr-only",children:"Go to first page"}),a.jsx(ee.ArrowLeftIcon,{className:"tw-h-4 tw-w-4"})]}),a.jsxs(fe,{variant:"outline",size:"icon",className:"tw-h-8 tw-w-8 tw-p-0",onClick:()=>e.previousPage(),disabled:!e.getCanPreviousPage(),children:[a.jsx("span",{className:"tw-sr-only",children:"Go to previous page"}),a.jsx(ee.ChevronLeftIcon,{className:"tw-h-4 tw-w-4"})]}),a.jsxs(fe,{variant:"outline",size:"icon",className:"tw-h-8 tw-w-8 tw-p-0",onClick:()=>e.nextPage(),disabled:!e.getCanNextPage(),children:[a.jsx("span",{className:"tw-sr-only",children:"Go to next page"}),a.jsx(ee.ChevronRightIcon,{className:"tw-h-4 tw-w-4"})]}),a.jsxs(fe,{variant:"outline",size:"icon",className:"tw-hidden tw-h-8 tw-w-8 tw-p-0 lg:tw-flex",onClick:()=>e.setPageIndex(e.getPageCount()-1),disabled:!e.getCanNextPage(),children:[a.jsx("span",{className:"tw-sr-only",children:"Go to last page"}),a.jsx(ee.ArrowRightIcon,{className:"tw-h-4 tw-w-4"})]})]})]})})}const Tn=g.forwardRef(({className:e,stickyHeader:t,...n},r)=>a.jsx("div",{className:N("pr-twp tw-relative tw-w-full",{"tw-overflow-auto":!t}),children:a.jsx("table",{ref:r,className:N("tw-w-full tw-caption-bottom tw-text-sm",e),...n})}));Tn.displayName="Table";const Cn=g.forwardRef(({className:e,stickyHeader:t,...n},r)=>a.jsx("thead",{ref:r,className:N({"tw-sticky tw-top-[-1px] tw-bg-background tw-drop-shadow-sm":t},"[&_tr]:tw-border-b",e),...n}));Cn.displayName="TableHeader";const Rn=g.forwardRef(({className:e,...t},n)=>a.jsx("tbody",{ref:n,className:N("[&_tr:last-child]:tw-border-0",e),...t}));Rn.displayName="TableBody";const Es=g.forwardRef(({className:e,...t},n)=>a.jsx("tfoot",{ref:n,className:N("tw-border-t tw-bg-muted/50 tw-font-medium [&>tr]:last:tw-border-b-0",e),...t}));Es.displayName="TableFooter";const Ze=g.forwardRef(({className:e,...t},n)=>a.jsx("tr",{ref:n,className:N("tw-border-b tw-transition-colors hover:tw-bg-muted/50 data-[state=selected]:tw-bg-muted",e),...t}));Ze.displayName="TableRow";const Vt=g.forwardRef(({className:e,...t},n)=>a.jsx("th",{ref:n,className:N("tw-h-12 tw-px-4 tw-text-start tw-align-middle tw-font-medium tw-text-muted-foreground [&:has([role=checkbox])]:tw-pe-0",e),...t}));Vt.displayName="TableHead";const xt=g.forwardRef(({className:e,...t},n)=>a.jsx("td",{ref:n,className:N("tw-p-4 tw-align-middle [&:has([role=checkbox])]:tw-pe-0",e),...t}));xt.displayName="TableCell";const js=g.forwardRef(({className:e,...t},n)=>a.jsx("caption",{ref:n,className:N("tw-mt-4 tw-text-sm tw-text-muted-foreground",e),...t}));js.displayName="TableCaption";function Ts({columns:e,data:t,enablePagination:n=!1,showPaginationControls:r=!1,showColumnVisibilityControls:o=!1,stickyHeader:s=!1,onRowClickHandler:i=()=>{}}){var h;const[l,c]=g.useState([]),[d,u]=g.useState([]),[f,w]=g.useState({}),[b,x]=g.useState({}),m=ke.useReactTable({data:t,columns:e,getCoreRowModel:ke.getCoreRowModel(),...n&&{getPaginationRowModel:ke.getPaginationRowModel()},onSortingChange:c,getSortedRowModel:ke.getSortedRowModel(),onColumnFiltersChange:u,getFilteredRowModel:ke.getFilteredRowModel(),onColumnVisibilityChange:w,onRowSelectionChange:x,state:{sorting:l,columnFilters:d,columnVisibility:f,rowSelection:b}});return a.jsxs("div",{className:"pr-twp",children:[o&&a.jsx(fc,{table:m}),a.jsxs(Tn,{stickyHeader:s,children:[a.jsx(Cn,{stickyHeader:s,children:m.getHeaderGroups().map(E=>a.jsx(Ze,{children:E.headers.map(I=>a.jsx(Vt,{children:I.isPlaceholder?void 0:ke.flexRender(I.column.columnDef.header,I.getContext())},I.id))},E.id))}),a.jsx(Rn,{children:(h=m.getRowModel().rows)!=null&&h.length?m.getRowModel().rows.map(E=>a.jsx(Ze,{onClick:()=>i(E,m),"data-state":E.getIsSelected()&&"selected",children:E.getVisibleCells().map(I=>a.jsx(xt,{children:ke.flexRender(I.column.columnDef.cell,I.getContext())},I.id))},E.id)):a.jsx(Ze,{children:a.jsx(xt,{colSpan:e.length,className:"tw-h-24 tw-text-center",children:"No results."})})})]}),n&&a.jsxs("div",{className:"tw-flex tw-items-center tw-justify-end tw-space-x-2 tw-py-4",children:[a.jsx(fe,{variant:"outline",size:"sm",onClick:()=>m.previousPage(),disabled:!m.getCanPreviousPage(),children:"Previous"}),a.jsx(fe,{variant:"outline",size:"sm",onClick:()=>m.nextPage(),disabled:!m.getCanNextPage(),children:"Next"})]}),n&&r&&a.jsx(mc,{table:m})]})}function hc({occurrenceData:e,setScriptureReference:t,localizedStrings:n}){const r=n["%webView_inventory_occurrences_table_header_reference%"],o=n["%webView_inventory_occurrences_table_header_occurrence%"],s=g.useMemo(()=>{const i=[];return e.forEach(l=>{i.some(c=>W.deepEqual(c,l))||i.push(l)}),i},[e]);return a.jsxs(Tn,{stickyHeader:!0,children:[a.jsx(Cn,{stickyHeader:!0,children:a.jsxs(Ze,{children:[a.jsx(Vt,{children:r}),a.jsx(Vt,{children:o})]})}),a.jsx(Rn,{children:s.length>0&&s.map(i=>a.jsxs(Ze,{onClick:()=>{t(i.reference)},children:[a.jsx(xt,{children:`${ae.bookNumberToEnglishName(i.reference.bookNum)} ${i.reference.chapterNum}:${i.reference.verseNum}`}),a.jsx(xt,{children:i.text})]},`${i.reference.bookNum} ${i.reference.chapterNum}:${i.reference.verseNum}-${i.text}`))})]})}const sr=g.forwardRef(({className:e,...t},n)=>a.jsx(Gr.Root,{ref:n,className:N("tw-peer pr-twp tw-h-4 tw-w-4 tw-shrink-0 tw-rounded-sm tw-border tw-border-primary tw-ring-offset-background focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-cursor-not-allowed disabled:tw-opacity-50 data-[state=checked]:tw-bg-primary data-[state=checked]:tw-text-primary-foreground",e),...t,children:a.jsx(Gr.Indicator,{className:N("tw-flex tw-items-center tw-justify-center tw-text-current"),children:a.jsx(ee.Check,{className:"tw-h-4 tw-w-4"})})}));sr.displayName=Gr.Root.displayName;const Cs=e=>e.split(/(?:\r?\n|\r)|(?=(?:\\(?:v|c|id)))/g),qr=e=>{const t=/^\\[vc]\s+(\d+)/,n=e.match(t);if(n)return+n[1]},Rs=e=>{const t=e.match(/^\\id\s+([A-Za-z]+)/);return t?ae.bookIdToNumber(t[1]):0},Os=(e,t,n)=>n.includes(e)?"unapproved":t.includes(e)?"approved":"unknown",_s=kn.cva("pr-twp tw-inline-flex tw-items-center tw-justify-center tw-rounded-md tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-colors hover:tw-bg-muted hover:tw-text-muted-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50 data-[state=on]:tw-bg-accent data-[state=on]:tw-text-accent-foreground",{variants:{variant:{default:"tw-bg-transparent",outline:"tw-border tw-border-input tw-bg-transparent hover:tw-bg-accent hover:tw-text-accent-foreground"},size:{default:"tw-h-10 tw-px-3",sm:"tw-h-9 tw-px-2.5",lg:"tw-h-11 tw-px-5"}},defaultVariants:{variant:"default",size:"default"}}),gc=g.forwardRef(({className:e,variant:t,size:n,...r},o)=>a.jsx(es.Root,{ref:o,className:N(_s({variant:t,size:n,className:e})),...r}));gc.displayName=es.Root.displayName;const Ps=g.createContext({size:"default",variant:"default"}),fo=g.forwardRef(({className:e,variant:t,size:n,children:r,...o},s)=>a.jsx(rr.Root,{ref:s,className:N("pr-twp tw-flex tw-items-center tw-justify-center tw-gap-1",e),...o,children:a.jsx(Ps.Provider,{value:{variant:t,size:n},children:r})}));fo.displayName=rr.Root.displayName;const wn=g.forwardRef(({className:e,children:t,variant:n,size:r,...o},s)=>{const i=g.useContext(Ps);return a.jsx(rr.Item,{ref:s,className:N(_s({variant:i.variant||n,size:i.size||r}),e),...o,children:t})});wn.displayName=rr.Item.displayName;const ir=e=>e==="asc"?a.jsx(ee.ArrowUpIcon,{className:"tw-ms-2 tw-h-4 tw-w-4"}):e==="desc"?a.jsx(ee.ArrowDownIcon,{className:"tw-ms-2 tw-h-4 tw-w-4"}):a.jsx(ee.ArrowUpDownIcon,{className:"tw-ms-2 tw-h-4 tw-w-4"}),bc=e=>({accessorKey:"item",accessorFn:t=>t.items[0],header:({column:t})=>a.jsxs(fe,{variant:"ghost",onClick:()=>t.toggleSorting(void 0),children:[e,ir(t.getIsSorted())]})}),vc=(e,t)=>({accessorKey:`item${t}`,accessorFn:n=>n.items[t],header:({column:n})=>a.jsxs(fe,{variant:"ghost",onClick:()=>n.toggleSorting(void 0),children:[e,ir(n.getIsSorted())]})}),xc=e=>({accessorKey:"count",header:({column:t})=>a.jsx("div",{className:"tw-flex tw-justify-end tw-tabular-nums",children:a.jsxs(fe,{variant:"ghost",onClick:()=>t.toggleSorting(void 0),children:[e,ir(t.getIsSorted())]})}),cell:({row:t})=>a.jsx("div",{className:"tw-flex tw-justify-end",children:t.getValue("count")})}),Rr=(e,t,n,r,o,s)=>{let i=[...n];e.forEach(c=>{t==="approved"?i.includes(c)||i.push(c):i=i.filter(d=>d!==c)}),r(i);let l=[...o];e.forEach(c=>{t==="unapproved"?l.includes(c)||l.push(c):l=l.filter(d=>d!==c)}),s(l)},yc=(e,t,n,r,o)=>({accessorKey:"status",header:({column:s})=>a.jsx("div",{className:"tw-flex tw-justify-center",children:a.jsxs(fe,{variant:"ghost",onClick:()=>s.toggleSorting(void 0),children:[e,ir(s.getIsSorted())]})}),cell:({row:s})=>{const i=s.getValue("status"),l=s.getValue("item");return a.jsxs(fo,{value:i,variant:"outline",type:"single",children:[a.jsx(wn,{onClick:()=>Rr([l],"approved",t,n,r,o),value:"approved",children:a.jsx(ee.CircleCheckIcon,{})}),a.jsx(wn,{onClick:()=>Rr([l],"unapproved",t,n,r,o),value:"unapproved",children:a.jsx(ee.CircleXIcon,{})}),a.jsx(wn,{onClick:()=>Rr([l],"unknown",t,n,r,o),value:"unknown",children:a.jsx(ee.CircleHelpIcon,{})})]})}}),Nc=Object.freeze(["%webView_inventory_all%","%webView_inventory_approved%","%webView_inventory_unapproved%","%webView_inventory_unknown%","%webView_inventory_scope_currentBook%","%webView_inventory_scope_chapter%","%webView_inventory_scope_verse%","%webView_inventory_filter_text%","%webView_inventory_show_additional_items%","%webView_inventory_occurrences_table_header_reference%","%webView_inventory_occurrences_table_header_occurrence%"]),kc=(e,t,n)=>{let r=e;return t!=="all"&&(r=r.filter(o=>t==="approved"&&o.status==="approved"||t==="unapproved"&&o.status==="unapproved"||t==="unknown"&&o.status==="unknown")),n!==""&&(r=r.filter(o=>o.items[0].includes(n))),r},Sc=(e,t,n,r,o)=>{if(!e)return[];const s=[];let i=t.bookNum,l=t.chapterNum,c=t.verseNum;return Cs(e).forEach(u=>{u.startsWith("\\id")&&(i=Rs(u),l=0,c=0),u.startsWith("\\c")&&(l=qr(u),c=0),u.startsWith("\\v")&&(c=qr(u),l===0&&(l=t.chapterNum));let f=o.exec(u)??void 0;for(;f;){const w=[];f.forEach(h=>w.push(h));const b=f.index,x=s.find(h=>W.deepEqual(h.items,w)),m={reference:{bookNum:i!==void 0?i:-1,chapterNum:l!==void 0?l:-1,verseNum:c!==void 0?c:-1},text:W.substring(u,Math.max(0,b-25),Math.min(b+25,u.length))};if(x)x.count+=1,x.occurrences.push(m);else{const h={items:w,count:1,status:Os(w[0],n,r),occurrences:[m]};s.push(h)}f=o.exec(u)??void 0}}),s},Je=(e,t)=>e[t]??t;function Ec({scriptureReference:e,setScriptureReference:t,localizedStrings:n,extractItems:r,additionalItemsLabels:o,approvedItems:s,unapprovedItems:i,text:l,scope:c,onScopeChange:d,columns:u}){const f=Je(n,"%webView_inventory_all%"),w=Je(n,"%webView_inventory_approved%"),b=Je(n,"%webView_inventory_unapproved%"),x=Je(n,"%webView_inventory_unknown%"),m=Je(n,"%webView_inventory_scope_currentBook%"),h=Je(n,"%webView_inventory_scope_chapter%"),E=Je(n,"%webView_inventory_scope_verse%"),I=Je(n,"%webView_inventory_filter_text%"),C=Je(n,"%webView_inventory_show_additional_items%"),[S,v]=g.useState(!1),[_,V]=g.useState("all"),[U,j]=g.useState(""),[O,k]=g.useState([]),D=g.useMemo(()=>l?r instanceof RegExp?Sc(l,e,s,i,r):r(l,e,s,i):[],[l,r,e,s,i]),M=g.useMemo(()=>{if(S)return D;const y=[];return D.forEach(T=>{const z=T.items[0],L=y.find(B=>B.items[0]===z);L?(L.count+=T.count,L.occurrences=L.occurrences.concat(T.occurrences)):y.push({items:[z],count:T.count,occurrences:T.occurrences,status:T.status})}),y},[S,D]),J=g.useMemo(()=>kc(M,_,U),[M,_,U]),X=g.useMemo(()=>{var z,L;if(!S)return u;const y=(z=o==null?void 0:o.tableHeaders)==null?void 0:z.length;if(!y)return u;const T=[];for(let B=0;B{k([])},[J]);const F=(y,T)=>{T.setRowSelection(()=>{const z={};return z[y.index]=!0,z}),k(y.original.items)},te=y=>{if(y==="book"||y==="chapter"||y==="verse")d(y);else throw new Error(`Invalid scope value: ${y}`)},se=y=>{if(y==="all"||y==="approved"||y==="unapproved"||y==="unknown")V(y);else throw new Error(`Invalid status filter value: ${y}`)},oe=g.useMemo(()=>{if(M.length===0||O.length===0)return[];const y=M.filter(T=>W.deepEqual(S?T.items:[T.items[0]],O));if(y.length>1)throw new Error("Selected item is not unique");return y[0].occurrences},[O,S,M]);return a.jsxs("div",{className:"pr-twp tw-flex tw-h-full tw-flex-col",children:[a.jsxs("div",{className:"tw-flex tw-items-stretch",children:[a.jsxs(At,{onValueChange:y=>se(y),defaultValue:_,children:[a.jsx(bt,{className:"tw-m-1",children:a.jsx(Bt,{placeholder:"Select filter"})}),a.jsxs(vt,{children:[a.jsx(De,{value:"all",children:f}),a.jsx(De,{value:"approved",children:w}),a.jsx(De,{value:"unapproved",children:b}),a.jsx(De,{value:"unknown",children:x})]})]}),a.jsxs(At,{onValueChange:y=>te(y),defaultValue:c,children:[a.jsx(bt,{className:"tw-m-1",children:a.jsx(Bt,{placeholder:"Select scope"})}),a.jsxs(vt,{children:[a.jsx(De,{value:"book",children:m}),a.jsx(De,{value:"chapter",children:h}),a.jsx(De,{value:"verse",children:E})]})]}),a.jsx(St,{className:"tw-m-1 tw-rounded-md tw-border",placeholder:I,value:U,onChange:y=>{j(y.target.value)}}),o&&a.jsxs("div",{className:"tw-m-1 tw-flex tw-items-center tw-rounded-md tw-border",children:[a.jsx(sr,{className:"tw-m-1",checked:S,onCheckedChange:y=>{k([]),v(y)}}),a.jsx(Ue,{className:"tw-m-1 tw-flex-shrink-0 tw-whitespace-nowrap",children:(o==null?void 0:o.checkboxText)??C})]})]}),a.jsx("div",{className:"tw-m-1 tw-flex-1 tw-overflow-auto tw-rounded-md tw-border",children:a.jsx(Ts,{columns:X,data:J,onRowClickHandler:F,stickyHeader:!0})}),oe.length>0&&a.jsx("div",{className:"tw-m-1 tw-flex-1 tw-overflow-auto tw-rounded-md tw-border",children:a.jsx(hc,{occurrenceData:oe,setScriptureReference:t,localizedStrings:n})})]})}function mo({className:e,onSearch:t,placeholder:n,isFullWidth:r}){const[o,s]=g.useState(""),i=l=>{s(l),t(l)};return a.jsx(St,{className:N("tw-flex tw-h-10 tw-rounded-md tw-border tw-border-input tw-bg-background tw-px-3 tw-py-2 tw-text-sm tw-ring-offset-background file:tw-border-0 file:tw-bg-transparent file:tw-text-sm file:tw-font-medium placeholder:tw-text-muted-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-[color:hsl(240,5%,64.9%)] focus-visible:tw-ring-offset-2 disabled:tw-cursor-not-allowed disabled:tw-opacity-50",{"tw-w-full":r},e),placeholder:n,value:o,onChange:l=>i(l.target.value)})}const ho=g.forwardRef(({className:e,...t},n)=>a.jsx(Re.Root,{orientation:"vertical",ref:n,className:N("tw-flex tw-gap-1 tw-rounded-md tw-text-muted-foreground",e),...t}));ho.displayName=Re.List.displayName;const go=g.forwardRef(({className:e,...t},n)=>a.jsx(Re.List,{ref:n,className:N("tw-flex-fit tw-mlk-items-center tw-w-[124px] tw-justify-center tw-rounded-md tw-bg-muted tw-p-1 tw-text-muted-foreground",e),...t}));go.displayName=Re.List.displayName;const Is=g.forwardRef(({className:e,...t},n)=>a.jsx(Re.Trigger,{ref:n,...t,className:N("overflow-clip tw-inline-flex tw-w-[116px] tw-cursor-pointer tw-items-center tw-justify-center tw-break-words tw-rounded-sm tw-border-0 tw-bg-muted tw-px-3 tw-py-1.5 tw-text-sm tw-font-medium tw-text-inherit tw-ring-offset-background tw-transition-all hover:tw-text-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50 data-[state=active]:tw-bg-background data-[state=active]:tw-text-foreground data-[state=active]:tw-shadow-sm",e)})),bo=g.forwardRef(({className:e,...t},n)=>a.jsx(Re.Content,{ref:n,className:N("tw-ms-5 tw-flex-grow tw-text-foreground tw-ring-offset-background focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2",e),...t}));bo.displayName=Re.Content.displayName;function jc({tabList:e,onSearch:t,searchPlaceholder:n,headerTitle:r,isSearchBarFullWidth:o=!1,direction:s="ltr"}){return a.jsxs("div",{className:"pr-twp",children:[a.jsxs("div",{className:"tw-sticky tw-top-0 tw-space-y-2 tw-pb-2",children:[r?a.jsx("h1",{children:r}):"",a.jsx(mo,{isFullWidth:o,onSearch:t,placeholder:n})]}),a.jsxs(ho,{dir:s,children:[a.jsx(go,{children:e.map(i=>a.jsx(Is,{value:i.value,children:i.value},i.key))}),e.map(i=>a.jsx(bo,{value:i.value,children:i.content},i.key))]})]})}const lr=g.forwardRef(({className:e,orientation:t="horizontal",decorative:n=!0,...r},o)=>a.jsx(ts.Root,{ref:o,decorative:n,orientation:t,className:N("pr-twp tw-shrink-0 tw-bg-border",t==="horizontal"?"tw-h-[1px] tw-w-full":"tw-h-full tw-w-[1px]",e),...r}));lr.displayName=ts.Root.displayName;function aa({className:e,...t}){return a.jsx("div",{className:N("pr-twp tw-animate-pulse tw-rounded-md tw-bg-muted",e),...t})}const Tc=Sn.Provider,Cc=Sn.Root,Rc=Sn.Trigger,Ms=g.forwardRef(({className:e,sideOffset:t=4,...n},r)=>a.jsx(Sn.Content,{ref:r,sideOffset:t,className:N("pr-twp tw-z-50 tw-overflow-hidden tw-rounded-md tw-border tw-bg-popover tw-px-3 tw-py-1.5 tw-text-sm tw-text-popover-foreground tw-shadow-md tw-animate-in tw-fade-in-0 tw-zoom-in-95 data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=closed]:tw-zoom-out-95 data-[side=bottom]:tw-slide-in-from-top-2 data-[side=left]:tw-slide-in-from-right-2 data-[side=right]:tw-slide-in-from-left-2 data-[side=top]:tw-slide-in-from-bottom-2",e),...n}));Ms.displayName=Sn.Content.displayName;const Oc="16rem",_c="3rem",Pc="b",$s=g.createContext(void 0);function cr(){const e=g.useContext($s);if(!e)throw new Error("useSidebar must be used within a SidebarProvider.");return e}const Ds=g.forwardRef(({defaultOpen:e=!0,open:t,onOpenChange:n,className:r,style:o,children:s,...i},l)=>{const[c,d]=g.useState(e),u=t??c,f=g.useCallback(m=>{const h=typeof m=="function"?m(u):m;n?n(h):d(h)},[n,u]),w=g.useCallback(()=>f(m=>!m),[f]);g.useEffect(()=>{const m=h=>{h.key===Pc&&(h.metaKey||h.ctrlKey)&&(h.preventDefault(),w())};return window.addEventListener("keydown",m),()=>window.removeEventListener("keydown",m)},[w]);const b=u?"expanded":"collapsed",x=g.useMemo(()=>({state:b,open:u,setOpen:f,toggleSidebar:w}),[b,u,f,w]);return a.jsx($s.Provider,{value:x,children:a.jsx(Tc,{delayDuration:0,children:a.jsx("div",{style:{"--sidebar-width":Oc,"--sidebar-width-icon":_c,...o},className:N("tw-group/sidebar-wrapper pr-twp tw-flex tw-w-full has-[[data-variant=inset]]:tw-bg-sidebar",r),ref:l,...i,children:s})})})});Ds.displayName="SidebarProvider";const As=g.forwardRef(({side:e="left",variant:t="sidebar",collapsible:n="offcanvas",className:r,children:o,...s},i)=>{const{state:l}=cr();return n==="none"?a.jsx("div",{className:N("tw-flex tw-h-full tw-w-[--sidebar-width] tw-flex-col tw-bg-sidebar tw-text-sidebar-foreground",r),ref:i,...s,children:o}):a.jsxs("div",{ref:i,className:"tw-group tw-peer tw-hidden tw-text-sidebar-foreground md:tw-block","data-state":l,"data-collapsible":l==="collapsed"?n:"","data-variant":t,"data-side":e,children:[a.jsx("div",{className:N("tw-relative tw-h-svh tw-w-[--sidebar-width] tw-bg-transparent tw-transition-[width] tw-duration-200 tw-ease-linear","group-data-[collapsible=offcanvas]:tw-w-0","group-data-[side=right]:tw-rotate-180",t==="floating"||t==="inset"?"group-data-[collapsible=icon]:tw-w-[calc(var(--sidebar-width-icon)_+_theme(spacing.4))]":"group-data-[collapsible=icon]:tw-w-[--sidebar-width-icon]")}),a.jsx("div",{className:N("tw-absolute tw-inset-y-0 tw-z-10 tw-hidden tw-h-svh tw-w-[--sidebar-width] tw-transition-[left,right,width] tw-duration-200 tw-ease-linear md:tw-flex",e==="left"?"tw-left-0 group-data-[collapsible=offcanvas]:tw-left-[calc(var(--sidebar-width)*-1)]":"tw-right-0 group-data-[collapsible=offcanvas]:tw-right-[calc(var(--sidebar-width)*-1)]",t==="floating"||t==="inset"?"tw-p-2 group-data-[collapsible=icon]:tw-w-[calc(var(--sidebar-width-icon)_+_theme(spacing.4)_+2px)]":"group-data-[collapsible=icon]:tw-w-[--sidebar-width-icon] group-data-[side=left]:tw-border-r group-data-[side=right]:tw-border-l",r),...s,children:a.jsx("div",{"data-sidebar":"sidebar",className:"tw-flex tw-h-full tw-w-full tw-flex-col tw-bg-sidebar group-data-[variant=floating]:tw-rounded-lg group-data-[variant=floating]:tw-border group-data-[variant=floating]:tw-border-sidebar-border group-data-[variant=floating]:tw-shadow",children:o})})]})});As.displayName="Sidebar";const Ic=g.forwardRef(({className:e,onClick:t,...n},r)=>{const{toggleSidebar:o}=cr();return a.jsxs(fe,{ref:r,"data-sidebar":"trigger",variant:"ghost",size:"icon",className:N("tw-h-7 tw-w-7",e),onClick:s=>{t==null||t(s),o()},...n,children:[a.jsx(ee.PanelLeft,{}),a.jsx("span",{className:"tw-sr-only",children:"Toggle Sidebar"})]})});Ic.displayName="SidebarTrigger";const Mc=g.forwardRef(({className:e,...t},n)=>{const{toggleSidebar:r}=cr();return a.jsx("button",{type:"button",ref:n,"data-sidebar":"rail","aria-label":"Toggle Sidebar",tabIndex:-1,onClick:r,title:"Toggle Sidebar",className:N("tw-absolute tw-inset-y-0 tw-z-20 tw-hidden tw-w-4 tw--translate-x-1/2 tw-transition-all tw-ease-linear after:tw-absolute after:tw-inset-y-0 after:tw-left-1/2 after:tw-w-[2px] hover:after:tw-bg-sidebar-border group-data-[side=left]:tw--right-4 group-data-[side=right]:tw-left-0 sm:tw-flex","[[data-side=left]_&]:tw-cursor-w-resize [[data-side=right]_&]:tw-cursor-e-resize","[[data-side=left][data-state=collapsed]_&]:tw-cursor-e-resize [[data-side=right][data-state=collapsed]_&]:tw-cursor-w-resize","group-data-[collapsible=offcanvas]:tw-translate-x-0 group-data-[collapsible=offcanvas]:after:tw-left-full group-data-[collapsible=offcanvas]:hover:tw-bg-sidebar","[[data-side=left][data-collapsible=offcanvas]_&]:tw--right-2","[[data-side=right][data-collapsible=offcanvas]_&]:tw--left-2",e),...t})});Mc.displayName="SidebarRail";const Bs=g.forwardRef(({className:e,...t},n)=>a.jsx("main",{ref:n,className:N("tw-relative tw-flex tw-flex-1 tw-flex-col tw-bg-background","peer-data-[variant=inset]:tw-min-h-[calc(100svh-theme(spacing.4))] md:peer-data-[variant=inset]:tw-m-2 md:peer-data-[state=collapsed]:peer-data-[variant=inset]:tw-ml-2 md:peer-data-[variant=inset]:tw-ml-0 md:peer-data-[variant=inset]:tw-rounded-xl md:peer-data-[variant=inset]:tw-shadow",e),...t}));Bs.displayName="SidebarInset";const $c=g.forwardRef(({className:e,...t},n)=>a.jsx(St,{ref:n,"data-sidebar":"input",className:N("tw-h-8 tw-w-full tw-bg-background tw-shadow-none focus-visible:tw-ring-2 focus-visible:tw-ring-sidebar-ring",e),...t}));$c.displayName="SidebarInput";const Dc=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,"data-sidebar":"header",className:N("tw-flex tw-flex-col tw-gap-2 tw-p-2",e),...t}));Dc.displayName="SidebarHeader";const Ac=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,"data-sidebar":"footer",className:N("tw-flex tw-flex-col tw-gap-2 tw-p-2",e),...t}));Ac.displayName="SidebarFooter";const Bc=g.forwardRef(({className:e,...t},n)=>a.jsx(lr,{ref:n,"data-sidebar":"separator",className:N("tw-mx-2 tw-w-auto tw-bg-sidebar-border",e),...t}));Bc.displayName="SidebarSeparator";const Vs=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,"data-sidebar":"content",className:N("tw-flex tw-min-h-0 tw-flex-1 tw-flex-col tw-gap-2 tw-overflow-auto group-data-[collapsible=icon]:tw-overflow-hidden",e),...t}));Vs.displayName="SidebarContent";const Hr=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,"data-sidebar":"group",className:N("tw-relative tw-flex tw-w-full tw-min-w-0 tw-flex-col tw-p-2",e),...t}));Hr.displayName="SidebarGroup";const Yr=g.forwardRef(({className:e,asChild:t=!1,...n},r)=>{const o=t?Ht.Slot:"div";return a.jsx(o,{ref:r,"data-sidebar":"group-label",className:N("tw-flex tw-h-8 tw-shrink-0 tw-items-center tw-rounded-md tw-px-2 tw-text-xs tw-font-medium tw-text-sidebar-foreground/70 tw-outline-none tw-ring-sidebar-ring tw-transition-[margin,opa] tw-duration-200 tw-ease-linear focus-visible:tw-ring-2 [&>svg]:tw-size-4 [&>svg]:tw-shrink-0","group-data-[collapsible=icon]:tw--mt-8 group-data-[collapsible=icon]:tw-opacity-0",e),...n})});Yr.displayName="SidebarGroupLabel";const Vc=g.forwardRef(({className:e,asChild:t=!1,...n},r)=>{const o=t?Ht.Slot:"button";return a.jsx(o,{ref:r,"data-sidebar":"group-action",className:N("tw-absolute tw-right-3 tw-top-3.5 tw-flex tw-aspect-square tw-w-5 tw-items-center tw-justify-center tw-rounded-md tw-p-0 tw-text-sidebar-foreground tw-outline-none tw-ring-sidebar-ring tw-transition-transform hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground focus-visible:tw-ring-2 [&>svg]:tw-size-4 [&>svg]:tw-shrink-0","after:tw-absolute after:tw--inset-2 after:md:tw-hidden","group-data-[collapsible=icon]:tw-hidden",e),...n})});Vc.displayName="SidebarGroupAction";const Xr=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,"data-sidebar":"group-content",className:N("tw-w-full tw-text-sm",e),...t}));Xr.displayName="SidebarGroupContent";const zs=g.forwardRef(({className:e,...t},n)=>a.jsx("ul",{ref:n,"data-sidebar":"menu",className:N("tw-flex tw-w-full tw-min-w-0 tw-flex-col tw-gap-1",e),...t}));zs.displayName="SidebarMenu";const Ls=g.forwardRef(({className:e,...t},n)=>a.jsx("li",{ref:n,"data-sidebar":"menu-item",className:N("tw-group/menu-item tw-relative",e),...t}));Ls.displayName="SidebarMenuItem";const zc=kn.cva("tw-peer/menu-button tw-flex tw-w-full tw-items-center tw-gap-2 tw-overflow-hidden tw-rounded-md tw-p-2 tw-text-left tw-text-sm tw-outline-none tw-ring-sidebar-ring tw-transition-[width,height,padding] hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground focus-visible:tw-ring-2 active:tw-bg-sidebar-accent active:tw-text-sidebar-accent-foreground disabled:tw-pointer-events-none disabled:tw-opacity-50 tw-group-has-[[data-sidebar=menu-action]]/menu-item:pr-8 aria-disabled:tw-pointer-events-none aria-disabled:tw-opacity-50 data-[active=true]:tw-font-medium data-[active=true]:tw-text-sidebar-accent-foreground data-[state=open]:hover:tw-bg-sidebar-accent data-[state=open]:hover:tw-text-sidebar-accent-foreground group-data-[collapsible=icon]:tw-!size-8 group-data-[collapsible=icon]:tw-!p-2 [&>span:last-child]:tw-truncate [&>svg]:tw-size-4 [&>svg]:tw-shrink-0",{variants:{variant:{default:"hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground",outline:"tw-bg-background tw-shadow-[0_0_0_1px_hsl(var(--sidebar-border))] hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground hover:tw-shadow-[0_0_0_1px_hsl(var(--sidebar-accent))]"},size:{default:"tw-h-8 tw-text-sm",sm:"tw-h-7 tw-text-xs",lg:"tw-h-12 tw-text-sm group-data-[collapsible=icon]:tw-!p-0"}},defaultVariants:{variant:"default",size:"default"}}),Fs=g.forwardRef(({asChild:e=!1,isActive:t=!1,variant:n="default",size:r="default",tooltip:o,className:s,...i},l)=>{const c=e?Ht.Slot:"button",{state:d}=cr(),u=a.jsx(c,{ref:l,"data-sidebar":"menu-button","data-size":r,"data-active":t,className:N(zc({variant:n,size:r}),s),...i});return o?(typeof o=="string"&&(o={children:o}),a.jsxs(Cc,{children:[a.jsx(Rc,{asChild:!0,children:u}),a.jsx(Ms,{side:"right",align:"center",hidden:d!=="collapsed",...o})]})):u});Fs.displayName="SidebarMenuButton";const Lc=g.forwardRef(({className:e,asChild:t=!1,showOnHover:n=!1,...r},o)=>{const s=t?Ht.Slot:"button";return a.jsx(s,{ref:o,"data-sidebar":"menu-action",className:N("tw-peer-hover/menu-button:text-sidebar-accent-foreground tw-absolute tw-right-1 tw-top-1.5 tw-flex tw-aspect-square tw-w-5 tw-items-center tw-justify-center tw-rounded-md tw-p-0 tw-text-sidebar-foreground tw-outline-none tw-ring-sidebar-ring tw-transition-transform hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground focus-visible:tw-ring-2 [&>svg]:tw-size-4 [&>svg]:tw-shrink-0","after:tw-absolute after:tw--inset-2 after:md:tw-hidden","tw-peer-data-[size=sm]/menu-button:top-1","tw-peer-data-[size=default]/menu-button:top-1.5","tw-peer-data-[size=lg]/menu-button:top-2.5","group-data-[collapsible=icon]:tw-hidden",n&&"tw-group-focus-within/menu-item:opacity-100 tw-group-hover/menu-item:opacity-100 tw-peer-data-[active=true]/menu-button:text-sidebar-accent-foreground data-[state=open]:tw-opacity-100 md:tw-opacity-0",e),...r})});Lc.displayName="SidebarMenuAction";const Fc=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,"data-sidebar":"menu-badge",className:N("tw-pointer-events-none tw-absolute tw-right-1 tw-flex tw-h-5 tw-min-w-5 tw-select-none tw-items-center tw-justify-center tw-rounded-md tw-px-1 tw-text-xs tw-font-medium tw-tabular-nums tw-text-sidebar-foreground","tw-peer-hover/menu-button:text-sidebar-accent-foreground tw-peer-data-[active=true]/menu-button:text-sidebar-accent-foreground","tw-peer-data-[size=sm]/menu-button:top-1","tw-peer-data-[size=default]/menu-button:top-1.5","tw-peer-data-[size=lg]/menu-button:top-2.5","group-data-[collapsible=icon]:tw-hidden",e),...t}));Fc.displayName="SidebarMenuBadge";const Gc=g.forwardRef(({className:e,showIcon:t=!1,...n},r)=>{const o=g.useMemo(()=>`${Math.floor(Math.random()*40)+50}%`,[]);return a.jsxs("div",{ref:r,"data-sidebar":"menu-skeleton",className:N("tw-flex tw-h-8 tw-items-center tw-gap-2 tw-rounded-md tw-px-2",e),...n,children:[t&&a.jsx(aa,{className:"tw-size-4 tw-rounded-md","data-sidebar":"menu-skeleton-icon"}),a.jsx(aa,{className:"tw-h-4 tw-max-w-[--skeleton-width] tw-flex-1","data-sidebar":"menu-skeleton-text",style:{"--skeleton-width":o}})]})});Gc.displayName="SidebarMenuSkeleton";const Uc=g.forwardRef(({className:e,...t},n)=>a.jsx("ul",{ref:n,"data-sidebar":"menu-sub",className:N("tw-mx-3.5 tw-flex tw-min-w-0 tw-translate-x-px tw-flex-col tw-gap-1 tw-border-l tw-border-sidebar-border tw-px-2.5 tw-py-0.5","group-data-[collapsible=icon]:tw-hidden",e),...t}));Uc.displayName="SidebarMenuSub";const qc=g.forwardRef(({...e},t)=>a.jsx("li",{ref:t,...e}));qc.displayName="SidebarMenuSubItem";const Hc=g.forwardRef(({asChild:e=!1,size:t="md",isActive:n,className:r,...o},s)=>{const i=e?Ht.Slot:"a";return a.jsx(i,{ref:s,"data-sidebar":"menu-sub-button","data-size":t,"data-active":n,className:N("tw-flex tw-h-7 tw-min-w-0 tw--translate-x-px tw-items-center tw-gap-2 tw-overflow-hidden tw-rounded-md tw-px-2 tw-text-sidebar-foreground tw-outline-none tw-ring-sidebar-ring hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground focus-visible:tw-ring-2 active:tw-bg-sidebar-accent active:tw-text-sidebar-accent-foreground disabled:tw-pointer-events-none disabled:tw-opacity-50 aria-disabled:tw-pointer-events-none aria-disabled:tw-opacity-50 [&>span:last-child]:tw-truncate [&>svg]:tw-size-4 [&>svg]:tw-shrink-0 [&>svg]:tw-text-sidebar-accent-foreground","data-[active=true]:tw-bg-sidebar-accent data-[active=true]:tw-text-sidebar-accent-foreground",t==="sm"&&"tw-text-xs",t==="md"&&"tw-text-sm","group-data-[collapsible=icon]:tw-hidden",r),...o})});Hc.displayName="SidebarMenuSubButton";function Gs({id:e,extensionLabels:t,projectInfo:n,handleSelectSidebarItem:r,selectedSidebarItem:o,extensionsSidebarGroupLabel:s,projectsSidebarGroupLabel:i,buttonPlaceholderText:l}){const c=g.useCallback((f,w)=>{r(f,w)},[r]),d=g.useCallback(f=>{const w=n.find(b=>b.projectId===f);return w?w.projectName:f},[n]),u=g.useCallback(f=>!o.projectId&&f===o.label,[o]);return a.jsx(As,{id:e,collapsible:"none",variant:"inset",className:"tw-w-96 tw-gap-2 tw-overflow-y-auto tw-rounded tw-bg-slate-100",children:a.jsxs(Vs,{children:[a.jsxs(Hr,{children:[a.jsx(Yr,{className:"tw-text-sm tw-text-gray-400",children:s}),a.jsx(Xr,{children:a.jsx(zs,{children:t.map(f=>a.jsx(Ls,{children:a.jsx(Fs,{className:N("tw-rounded tw-py-2 tw-text-sm tw-text-gray-500 hover:tw-bg-white hover:tw-text-gray-900 hover:tw-shadow-sm active:tw-bg-white",{"tw-bg-white tw-text-gray-900 tw-shadow-sm":u(f)}),onClick:()=>c(f),isActive:u(f),children:a.jsx("span",{className:"tw-pl-3",children:f})})},f))})})]}),a.jsxs(Hr,{children:[a.jsx(Yr,{className:"tw-text-sm tw-text-gray-400",children:i}),a.jsx(Xr,{className:"tw-pl-3",children:a.jsx(Wn,{popoverContentClassName:"tw-z-[1000]",options:n.flatMap(f=>f.projectId),getOptionLabel:f=>d(f),buttonPlaceholder:l,onChange:f=>{const w=d(f);c(w,f)},value:(o==null?void 0:o.projectId)??void 0})})]})]})})}function Yc({id:e,extensionLabels:t,projectInfo:n,children:r,handleSelectSidebarItem:o,selectedSidebarItem:s,onSearch:i,extensionsSidebarGroupLabel:l,projectsSidebarGroupLabel:c,buttonPlaceholderText:d}){return a.jsxs("div",{className:"tw-box-border tw-flex tw-h-full tw-flex-col tw-p-3",children:[a.jsx("div",{className:"tw-box-border tw-flex tw-items-center tw-justify-center tw-py-4",children:a.jsx(mo,{className:"tw-w-9/12",onSearch:i,placeholder:"Search app settings, extension settings, and project settings"})}),a.jsxs(Ds,{id:e,className:"tw-h-full tw-flex-1 tw-gap-4 tw-overflow-auto",children:[a.jsx(Gs,{extensionLabels:t,projectInfo:n,handleSelectSidebarItem:o,selectedSidebarItem:s,extensionsSidebarGroupLabel:l,projectsSidebarGroupLabel:c,buttonPlaceholderText:d}),a.jsx(Bs,{className:"tw-overflow-y-auto",children:r})]})]})}const rt="scrBook",Xc="scrRef",pt="source",Wc="details",Kc="Scripture Reference",Jc="Scripture Book",Us="Type",Zc="Details";function Qc(e,t){const n=t??!1;return[{accessorFn:r=>`${ae.bookNumberToId(r.start.bookNum)} ${r.start.chapterNum}:${r.start.verseNum}`,id:rt,header:(e==null?void 0:e.scriptureReferenceColumnName)??Kc,cell:r=>{const o=r.row.original;return r.row.getIsGrouped()?ae.bookNumberToEnglishName(o.start.bookNum):r.row.groupingColumnId===rt?W.formatScrRef(o.start):void 0},getGroupingValue:r=>r.start.bookNum,sortingFn:(r,o)=>W.compareScrRefs(r.original.start,o.original.start),enableGrouping:!0},{accessorFn:r=>W.formatScrRef(r.start),id:Xc,header:void 0,cell:r=>{const o=r.row.original;return r.row.getIsGrouped()?void 0:W.formatScrRef(o.start)},sortingFn:(r,o)=>W.compareScrRefs(r.original.start,o.original.start),enableGrouping:!1},{accessorFn:r=>r.source.displayName,id:pt,header:n?(e==null?void 0:e.typeColumnName)??Us:void 0,cell:r=>n||r.row.getIsGrouped()?r.getValue():void 0,getGroupingValue:r=>r.source.id,sortingFn:(r,o)=>r.original.source.displayName.localeCompare(o.original.source.displayName),enableGrouping:!0},{accessorFn:r=>r.detail,id:Wc,header:(e==null?void 0:e.detailsColumnName)??Zc,cell:r=>r.getValue(),enableGrouping:!1}]}const ed=e=>{if(!("offset"in e.start))throw new Error("No offset available in range start");if(e.end&&!("offset"in e.end))throw new Error("No offset available in range end");const{offset:t}=e.start;let n=0;return e.end&&({offset:n}=e.end),!e.end||W.compareScrRefs(e.start,e.end)===0?`${W.scrRefToBBBCCCVVV(e.start)}+${t}`:`${W.scrRefToBBBCCCVVV(e.start)}+${t}-${W.scrRefToBBBCCCVVV(e.end)}+${n}`},sa=e=>`${ed({start:e.start,end:e.end})} ${e.source.displayName} ${e.detail}`;function td({sources:e,showColumnHeaders:t=!1,showSourceColumn:n=!1,scriptureReferenceColumnName:r,scriptureBookGroupName:o,typeColumnName:s,detailsColumnName:i,onRowSelected:l,direction:c="ltr"}){const[d,u]=g.useState([]),[f,w]=g.useState([{id:rt,desc:!1}]),[b,x]=g.useState({}),m=g.useMemo(()=>e.flatMap(j=>j.data.map(O=>({...O,source:j.source}))),[e]),h=g.useMemo(()=>Qc({scriptureReferenceColumnName:r,typeColumnName:s,detailsColumnName:i},n),[r,s,i,n]);g.useEffect(()=>{d.includes(pt)?w([{id:pt,desc:!1},{id:rt,desc:!1}]):w([{id:rt,desc:!1}])},[d]);const E=ke.useReactTable({data:m,columns:h,state:{grouping:d,sorting:f,rowSelection:b},onGroupingChange:u,onSortingChange:w,onRowSelectionChange:x,getExpandedRowModel:ke.getExpandedRowModel(),getGroupedRowModel:ke.getGroupedRowModel(),getCoreRowModel:ke.getCoreRowModel(),getSortedRowModel:ke.getSortedRowModel(),getRowId:sa,autoResetExpanded:!1,enableMultiRowSelection:!1,enableSubRowSelection:!1});g.useEffect(()=>{if(l){const j=E.getSelectedRowModel().rowsById,O=Object.keys(j);if(O.length===1){const k=m.find(D=>sa(D)===O[0])||void 0;k&&l(k)}}},[b,m,l,E]);const I=o??Jc,C=s??Us,S=[{label:"No Grouping",value:[]},{label:`Group by ${I}`,value:[rt]},{label:`Group by ${C}`,value:[pt]},{label:`Group by ${I} and ${C}`,value:[rt,pt]},{label:`Group by ${C} and ${I}`,value:[pt,rt]}],v=j=>{u(JSON.parse(j))},_=(j,O)=>{!j.getIsGrouped()&&!j.getIsSelected()&&j.getToggleSelectedHandler()(O)},V=(j,O)=>j.getIsGrouped()?"":N("banded-row",O%2===0?"even":"odd"),U=(j,O,k)=>{if(!((j==null?void 0:j.length)===0||O.depth{v(j)},children:[a.jsx(bt,{className:"tw-mb-1 tw-mt-2",children:a.jsx(Bt,{})}),a.jsx(vt,{position:"item-aligned",children:a.jsx(Ns,{children:S.map(j=>a.jsx(De,{value:JSON.stringify(j.value),children:j.label},j.label))})})]}),a.jsxs(Tn,{className:"tw-relative tw-flex tw-flex-col tw-overflow-y-auto tw-p-0",children:[t&&a.jsx(Cn,{children:E.getHeaderGroups().map(j=>a.jsx(Ze,{children:j.headers.filter(O=>O.column.columnDef.header).map(O=>a.jsx(Vt,{colSpan:O.colSpan,className:"top-0 tw-sticky",children:O.isPlaceholder?void 0:a.jsxs("div",{children:[O.column.getCanGroup()?a.jsx(fe,{variant:"ghost",title:`Toggle grouping by ${O.column.columnDef.header}`,onClick:O.column.getToggleGroupingHandler(),type:"button",children:O.column.getIsGrouped()?"🛑":"👊 "}):void 0," ",ke.flexRender(O.column.columnDef.header,O.getContext())]})},O.id))},j.id))}),a.jsx(Rn,{children:E.getRowModel().rows.map((j,O)=>a.jsx(Ze,{"data-state":j.getIsSelected()?"selected":"",className:N(V(j,O)),onClick:k=>_(j,k),children:j.getVisibleCells().map(k=>{if(!(k.getIsPlaceholder()||k.column.columnDef.enableGrouping&&!k.getIsGrouped()&&(k.column.columnDef.id!==pt||!n)))return a.jsx(xt,{className:N(k.column.columnDef.id,"tw-p-[1px]",U(d,j,k)),children:(()=>k.getIsGrouped()?a.jsxs(fe,{variant:"link",onClick:j.getToggleExpandedHandler(),type:"button",children:[j.getIsExpanded()&&a.jsx(ee.ChevronDown,{}),!j.getIsExpanded()&&(c==="ltr"?a.jsx(ee.ChevronRight,{}):a.jsx(ee.ChevronLeft,{}))," ",ke.flexRender(k.column.columnDef.cell,k.getContext())," (",j.subRows.length,")"]}):ke.flexRender(k.column.columnDef.cell,k.getContext()))()},k.id)})},j.id))})]})]})}const Or={[W.getLocalizeKeyForScrollGroupId("undefined")]:"Ø",[W.getLocalizeKeyForScrollGroupId(0)]:"A",[W.getLocalizeKeyForScrollGroupId(1)]:"B",[W.getLocalizeKeyForScrollGroupId(2)]:"C",[W.getLocalizeKeyForScrollGroupId(3)]:"D",[W.getLocalizeKeyForScrollGroupId(4)]:"E",[W.getLocalizeKeyForScrollGroupId(5)]:"F",[W.getLocalizeKeyForScrollGroupId(6)]:"G",[W.getLocalizeKeyForScrollGroupId(7)]:"H",[W.getLocalizeKeyForScrollGroupId(8)]:"I",[W.getLocalizeKeyForScrollGroupId(9)]:"J",[W.getLocalizeKeyForScrollGroupId(10)]:"K",[W.getLocalizeKeyForScrollGroupId(11)]:"L",[W.getLocalizeKeyForScrollGroupId(12)]:"M",[W.getLocalizeKeyForScrollGroupId(13)]:"N",[W.getLocalizeKeyForScrollGroupId(14)]:"O",[W.getLocalizeKeyForScrollGroupId(15)]:"P",[W.getLocalizeKeyForScrollGroupId(16)]:"Q",[W.getLocalizeKeyForScrollGroupId(17)]:"R",[W.getLocalizeKeyForScrollGroupId(18)]:"S",[W.getLocalizeKeyForScrollGroupId(19)]:"T",[W.getLocalizeKeyForScrollGroupId(20)]:"U",[W.getLocalizeKeyForScrollGroupId(21)]:"V",[W.getLocalizeKeyForScrollGroupId(22)]:"W",[W.getLocalizeKeyForScrollGroupId(23)]:"X",[W.getLocalizeKeyForScrollGroupId(24)]:"Y",[W.getLocalizeKeyForScrollGroupId(25)]:"Z"};function nd({availableScrollGroupIds:e,scrollGroupId:t,onChangeScrollGroupId:n,localizedStrings:r={}}){const o={...Or,...Object.fromEntries(Object.entries(r).map(([s,i])=>[s,s===i&&s in Or?Or[s]:i]))};return a.jsxs(At,{value:`${t}`,onValueChange:s=>n(s==="undefined"?void 0:parseInt(s,10)),children:[a.jsx(bt,{className:"pr-twp tw-w-auto",children:a.jsx(Bt,{placeholder:o[W.getLocalizeKeyForScrollGroupId(t)]??t})}),a.jsx(vt,{style:{zIndex:250},children:e.map(s=>a.jsx(De,{value:`${s}`,children:o[W.getLocalizeKeyForScrollGroupId(s)]},`${s}`))})]})}function rd({children:e}){return a.jsx("div",{className:"pr-twp tw-grid",children:e})}function od({primary:e,secondary:t,children:n,isLoading:r=!1,loadingMessage:o}){return a.jsxs("div",{className:"tw-flex tw-items-center tw-justify-between tw-space-x-4 tw-py-2",children:[a.jsxs("div",{children:[a.jsx("p",{className:"tw-text-sm tw-font-medium tw-leading-none",children:e}),a.jsx("p",{className:"tw-whitespace-normal tw-break-words tw-text-sm tw-text-muted-foreground",children:t})]}),r?a.jsx("p",{className:"tw-text-sm tw-text-muted-foreground",children:o}):a.jsx("div",{children:n})]})}function ad({primary:e,secondary:t,includeSeparator:n=!1}){return a.jsxs("div",{className:"tw-space-y-4 tw-py-2",children:[a.jsxs("div",{children:[a.jsx("h3",{className:"tw-text-lg tw-font-medium",children:e}),a.jsx("p",{className:"tw-text-sm tw-text-muted-foreground",children:t})]}),n?a.jsx(lr,{}):""]})}function sd({id:e,className:t,listItems:n,selectedListItems:r,handleSelectListItem:o,createLabel:s}){return a.jsx("div",{id:e,className:t,children:n.map(i=>a.jsxs("div",{className:"tw-m-2 tw-flex tw-items-center",children:[a.jsx(sr,{className:"tw-mr-2 tw-align-middle",checked:r.includes(i),onCheckedChange:l=>o(i,l)}),a.jsx(Ue,{children:s?s(i):i})]},i))})}function id(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}function ld(e){if(e.__esModule)return e;var t=e.default;if(typeof t=="function"){var n=function r(){return this instanceof r?Reflect.construct(t,arguments,this.constructor):t.apply(this,arguments)};n.prototype=t.prototype}else n={};return Object.defineProperty(n,"__esModule",{value:!0}),Object.keys(e).forEach(function(r){var o=Object.getOwnPropertyDescriptor(e,r);Object.defineProperty(n,r,o.get?o:{enumerable:!0,get:function(){return e[r]}})}),n}var vo={},qs={exports:{}};(function(e){function t(n){return n&&n.__esModule?n:{default:n}}e.exports=t,e.exports.__esModule=!0,e.exports.default=e.exports})(qs);var cd=qs.exports,_r={};function xo(e,t){return process.env.NODE_ENV==="production"?()=>null:function(...r){return e(...r)||t(...r)}}function R(){return R=Object.assign?Object.assign.bind():function(e){for(var t=1;t{t[n]=Hs(e[n])}),t}function Qe(e,t,n={clone:!0}){const r=n.clone?R({},e):e;return mt(e)&&mt(t)&&Object.keys(t).forEach(o=>{o!=="__proto__"&&(mt(t[o])&&o in e&&mt(e[o])?r[o]=Qe(e[o],t[o],n):n.clone?r[o]=mt(t[o])?Hs(t[o]):t[o]:r[o]=t[o])}),r}var Wr={exports:{}},zn={exports:{}},ie={};/** @license React v16.13.1 +"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const a=require("react/jsx-runtime"),g=require("react"),ee=require("lucide-react"),ot=require("clsx"),pl=require("tailwind-merge"),Ja=require("@radix-ui/react-dropdown-menu"),W=require("platform-bible-utils"),Ht=require("@radix-ui/react-slot"),kn=require("class-variance-authority"),wl=require("@radix-ui/react-label"),fl=require("@radix-ui/react-radio-group"),ml=require("@radix-ui/react-popover"),Ce=require("cmdk"),hl=require("@radix-ui/react-dialog"),ke=require("@tanstack/react-table"),gl=require("@radix-ui/react-select"),bl=require("@radix-ui/react-checkbox"),vl=require("@radix-ui/react-toggle-group"),xl=require("@radix-ui/react-toggle"),yl=require("@radix-ui/react-tabs"),Nl=require("@radix-ui/react-separator"),kl=require("@radix-ui/react-tooltip"),Fr=require("@mui/styled-engine"),Ie=require("@mui/material"),sn=require("react-dom"),Za=require("sonner"),Sl=require("@radix-ui/react-slider"),El=require("@radix-ui/react-switch"),jl=require("markdown-to-jsx");function Ne(e){const t=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(e){for(const n in e)if(n!=="default"){const r=Object.getOwnPropertyDescriptor(e,n);Object.defineProperty(t,n,r.get?r:{enumerable:!0,get:()=>e[n]})}}return t.default=e,Object.freeze(t)}const $=Ne(g),pe=Ne(Ja),Qa=Ne(wl),gn=Ne(fl),bn=Ne(ml),Xe=Ne(hl),ge=Ne(gl),Gr=Ne(bl),rr=Ne(vl),es=Ne(xl),Re=Ne(yl),ts=Ne(Nl),Sn=Ne(kl),Tl=Ne(sn),ln=Ne(Sl),Ur=Ne(El);const Cl=pl.extendTailwindMerge({prefix:"tw-"});function N(...e){return Cl(ot.clsx(e))}const St=g.forwardRef(({className:e,type:t,...n},r)=>a.jsx("input",{type:t,className:N("pr-twp tw-flex tw-h-10 tw-rounded-md tw-border tw-border-input tw-bg-background tw-px-3 tw-py-2 tw-text-sm tw-ring-offset-background file:tw-border-0 file:tw-bg-transparent file:tw-text-sm file:tw-font-medium file:tw-text-foreground placeholder:tw-text-muted-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-cursor-not-allowed disabled:tw-opacity-50",e),ref:r,...n}));St.displayName="Input";const Rl=g.forwardRef(({handleSearch:e,handleKeyDown:t,handleOnClick:n,handleSubmit:r,...o},s)=>a.jsxs("div",{className:"tw-relative",children:[a.jsx(St,{...o,type:"text",className:"tw-box-border tw-gap-2.5 tw-rounded-lg tw-border tw-border-solid tw-bg-background tw-py-2 tw-pl-4 tw-pr-3 tw-font-medium tw-shadow-none tw-outline-none",onChange:i=>e(i.target.value),onKeyDown:i=>{i.key==="Enter"&&r(),t(i)},onClick:n,ref:s}),a.jsx(ee.History,{className:"tw-absolute tw-right-3 tw-top-1/2 tw-h-4 tw-w-4 tw--translate-y-1/2 tw-transform tw-cursor-pointer tw-text-muted-foreground",onClick:()=>{console.log("back in history")}})]}));var Ol=Object.defineProperty,_l=(e,t,n)=>t in e?Ol(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,ne=(e,t,n)=>_l(e,typeof t!="symbol"?t+"":t,n);const gt=["GEN","EXO","LEV","NUM","DEU","JOS","JDG","RUT","1SA","2SA","1KI","2KI","1CH","2CH","EZR","NEH","EST","JOB","PSA","PRO","ECC","SNG","ISA","JER","LAM","EZK","DAN","HOS","JOL","AMO","OBA","JON","MIC","NAM","HAB","ZEP","HAG","ZEC","MAL","MAT","MRK","LUK","JHN","ACT","ROM","1CO","2CO","GAL","EPH","PHP","COL","1TH","2TH","1TI","2TI","TIT","PHM","HEB","JAS","1PE","2PE","1JN","2JN","3JN","JUD","REV","TOB","JDT","ESG","WIS","SIR","BAR","LJE","S3Y","SUS","BEL","1MA","2MA","3MA","4MA","1ES","2ES","MAN","PS2","ODA","PSS","JSA","JDB","TBS","SST","DNT","BLT","XXA","XXB","XXC","XXD","XXE","XXF","XXG","FRT","BAK","OTH","3ES","EZA","5EZ","6EZ","INT","CNC","GLO","TDX","NDX","DAG","PS3","2BA","LBA","JUB","ENO","1MQ","2MQ","3MQ","REP","4BA","LAO"],oo=["XXA","XXB","XXC","XXD","XXE","XXF","XXG","FRT","BAK","OTH","INT","CNC","GLO","TDX","NDX"],ns=["Genesis","Exodus","Leviticus","Numbers","Deuteronomy","Joshua","Judges","Ruth","1 Samuel","2 Samuel","1 Kings","2 Kings","1 Chronicles","2 Chronicles","Ezra","Nehemiah","Esther (Hebrew)","Job","Psalms","Proverbs","Ecclesiastes","Song of Songs","Isaiah","Jeremiah","Lamentations","Ezekiel","Daniel (Hebrew)","Hosea","Joel","Amos","Obadiah","Jonah","Micah","Nahum","Habakkuk","Zephaniah","Haggai","Zechariah","Malachi","Matthew","Mark","Luke","John","Acts","Romans","1 Corinthians","2 Corinthians","Galatians","Ephesians","Philippians","Colossians","1 Thessalonians","2 Thessalonians","1 Timothy","2 Timothy","Titus","Philemon","Hebrews","James","1 Peter","2 Peter","1 John","2 John","3 John","Jude","Revelation","Tobit","Judith","Esther Greek","Wisdom of Solomon","Sirach (Ecclesiasticus)","Baruch","Letter of Jeremiah","Song of 3 Young Men","Susanna","Bel and the Dragon","1 Maccabees","2 Maccabees","3 Maccabees","4 Maccabees","1 Esdras (Greek)","2 Esdras (Latin)","Prayer of Manasseh","Psalm 151","Odes","Psalms of Solomon","Joshua A. *obsolete*","Judges B. *obsolete*","Tobit S. *obsolete*","Susanna Th. *obsolete*","Daniel Th. *obsolete*","Bel Th. *obsolete*","Extra A","Extra B","Extra C","Extra D","Extra E","Extra F","Extra G","Front Matter","Back Matter","Other Matter","3 Ezra *obsolete*","Apocalypse of Ezra","5 Ezra (Latin Prologue)","6 Ezra (Latin Epilogue)","Introduction","Concordance ","Glossary ","Topical Index","Names Index","Daniel Greek","Psalms 152-155","2 Baruch (Apocalypse)","Letter of Baruch","Jubilees","Enoch","1 Meqabyan","2 Meqabyan","3 Meqabyan","Reproof (Proverbs 25-31)","4 Baruch (Rest of Baruch)","Laodiceans"],na=Ll();function Xt(e,t=!0){return t&&(e=e.toUpperCase()),e in na?na[e]:0}function ao(e){return Xt(e)>0}function Pl(e){const t=typeof e=="string"?Xt(e):e;return t>=40&&t<=66}function Il(e){return(typeof e=="string"?Xt(e):e)<=39}function rs(e){return e<=66}function Ml(e){const t=typeof e=="string"?Xt(e):e;return ss(t)&&!rs(t)}function*$l(){for(let e=1;e<=gt.length;e++)yield e}const Al=1,os=gt.length;function Dl(){return["XXA","XXB","XXC","XXD","XXE","XXF","XXG"]}function so(e,t="***"){const n=e-1;return n<0||n>=gt.length?t:gt[n]}function as(e){return e<=0||e>os?"******":ns[e-1]}function Bl(e){return as(Xt(e))}function ss(e){const t=typeof e=="number"?so(e):e;return ao(t)&&!oo.includes(t)}function Vl(e){const t=typeof e=="number"?so(e):e;return ao(t)&&oo.includes(t)}function zl(e){return ns[e-1].includes("*obsolete*")}function Ll(){const e={};for(let t=0;t(e[e.Unknown=0]="Unknown",e[e.Original=1]="Original",e[e.Septuagint=2]="Septuagint",e[e.Vulgate=3]="Vulgate",e[e.English=4]="English",e[e.RussianProtestant=5]="RussianProtestant",e[e.RussianOrthodox=6]="RussianOrthodox",e))(qe||{});const _e=class{constructor(t){if(ne(this,"name"),ne(this,"fullPath"),ne(this,"isPresent"),ne(this,"hasVerseSegments"),ne(this,"isCustomized"),ne(this,"baseVersification"),ne(this,"scriptureBooks"),ne(this,"_type"),t==null)throw new Error("Argument undefined");typeof t=="string"?(this.name=t,this._type=qe[t]):(this._type=t,this.name=qe[t])}get type(){return this._type}equals(t){return!t.type||!this.type?!1:t.type===this.type}};ne(_e,"Original",new _e(qe.Original)),ne(_e,"Septuagint",new _e(qe.Septuagint)),ne(_e,"Vulgate",new _e(qe.Vulgate)),ne(_e,"English",new _e(qe.English)),ne(_e,"RussianProtestant",new _e(qe.RussianProtestant)),ne(_e,"RussianOrthodox",new _e(qe.RussianOrthodox));let ut=_e;function ra(e,t){const n=t[0];for(let r=1;r(e[e.Valid=0]="Valid",e[e.UnknownVersification=1]="UnknownVersification",e[e.OutOfRange=2]="OutOfRange",e[e.VerseOutOfOrder=3]="VerseOutOfOrder",e[e.VerseRepeated=4]="VerseRepeated",e))(is||{});const Ee=class re{constructor(t,n,r,o){if(ne(this,"firstChapter"),ne(this,"lastChapter"),ne(this,"lastVerse"),ne(this,"hasSegmentsDefined"),ne(this,"text"),ne(this,"BBBCCCVVVS"),ne(this,"longHashCode"),ne(this,"versification"),ne(this,"rtlMark","‏"),ne(this,"_bookNum",0),ne(this,"_chapterNum",0),ne(this,"_verseNum",0),ne(this,"_verse"),r==null&&o==null)if(t!=null&&typeof t=="string"){const s=t,i=n!=null&&n instanceof ut?n:void 0;this.setEmpty(i),this.parse(s)}else if(t!=null&&typeof t=="number"){const s=n!=null&&n instanceof ut?n:void 0;this.setEmpty(s),this._verseNum=t%re.chapterDigitShifter,this._chapterNum=Math.floor(t%re.bookDigitShifter/re.chapterDigitShifter),this._bookNum=Math.floor(t/re.bookDigitShifter)}else if(n==null)if(t!=null&&t instanceof re){const s=t;this._bookNum=s.bookNum,this._chapterNum=s.chapterNum,this._verseNum=s.verseNum,this._verse=s.verse,this.versification=s.versification}else{if(t==null)return;const s=t instanceof ut?t:re.defaultVersification;this.setEmpty(s)}else throw new Error("VerseRef constructor not supported.");else if(t!=null&&n!=null&&r!=null)if(typeof t=="string"&&typeof n=="string"&&typeof r=="string")this.setEmpty(o),this.updateInternal(t,n,r);else if(typeof t=="number"&&typeof n=="number"&&typeof r=="number")this._bookNum=t,this._chapterNum=n,this._verseNum=r,this.versification=o??re.defaultVersification;else throw new Error("VerseRef constructor not supported.");else throw new Error("VerseRef constructor not supported.")}static isVerseParseable(t){return t.length>0&&"0123456789".includes(t[0])&&!t.endsWith(this.verseRangeSeparator)&&!t.endsWith(this.verseSequenceIndicator)}static tryParse(t){let n;try{return n=new re(t),{success:!0,verseRef:n}}catch(r){if(r instanceof tn)return n=new re,{success:!1,verseRef:n};throw r}}static getBBBCCCVVV(t,n,r){return t%re.bcvMaxValue*re.bookDigitShifter+(n>=0?n%re.bcvMaxValue*re.chapterDigitShifter:0)+(r>=0?r%re.bcvMaxValue:0)}static fromJSON(t){const{book:n,chapterNum:r,verseNum:o,verse:s,versificationStr:i}=t,l=s||o.toString();let c;return i&&(c=new ut(i)),n?new re(n,r.toString(),l,c):new re}static tryGetVerseNum(t){let n;if(!t)return n=-1,{success:!0,vNum:n};n=0;let r;for(let o=0;o"9")return o===0&&(n=-1),{success:!1,vNum:n};if(n=n*10+ +r-0,n>re.bcvMaxValue)return n=-1,{success:!1,vNum:n}}return{success:!0,vNum:n}}get isDefault(){return this.bookNum===0&&this.chapterNum===0&&this.verseNum===0&&this.versification==null}get hasMultiple(){return this._verse!=null&&(this._verse.includes(re.verseRangeSeparator)||this._verse.includes(re.verseSequenceIndicator))}get book(){return ae.bookNumberToId(this.bookNum,"")}set book(t){this.bookNum=ae.bookIdToNumber(t)}get chapter(){return this.isDefault||this._chapterNum<0?"":this._chapterNum.toString()}set chapter(t){const n=+t;this._chapterNum=Number.isInteger(n)?n:-1}get verse(){return this._verse!=null?this._verse:this.isDefault||this._verseNum<0?"":this._verseNum.toString()}set verse(t){const{success:n,vNum:r}=re.tryGetVerseNum(t);this._verse=n?void 0:t.replace(this.rtlMark,""),this._verseNum=r,!(this._verseNum>=0)&&({vNum:this._verseNum}=re.tryGetVerseNum(this._verse))}get bookNum(){return this._bookNum}set bookNum(t){if(t<=0||t>ae.lastBook)throw new tn("BookNum must be greater than zero and less than or equal to last book");this._bookNum=t}get chapterNum(){return this._chapterNum}set chapterNum(t){this.chapterNum=t}get verseNum(){return this._verseNum}set verseNum(t){this._verseNum=t}get versificationStr(){var t;return(t=this.versification)==null?void 0:t.name}set versificationStr(t){this.versification=this.versification!=null?new ut(t):void 0}get valid(){return this.validStatus===0}get validStatus(){return this.validateVerse(re.verseRangeSeparators,re.verseSequenceIndicators)}get BBBCCC(){return re.getBBBCCCVVV(this._bookNum,this._chapterNum,0)}get BBBCCCVVV(){return re.getBBBCCCVVV(this._bookNum,this._chapterNum,this._verseNum)}get isExcluded(){return!1}parse(t){if(t=t.replace(this.rtlMark,""),t.includes("/")){const s=t.split("/");if(t=s[0],s.length>1)try{const i=+s[1].trim();this.versification=new ut(qe[i])}catch{throw new tn("Invalid reference : "+t)}}const n=t.trim().split(" ");if(n.length!==2)throw new tn("Invalid reference : "+t);const r=n[1].split(":"),o=+r[0];if(r.length!==2||ae.bookIdToNumber(n[0])===0||!Number.isInteger(o)||o<0||!re.isVerseParseable(r[1]))throw new tn("Invalid reference : "+t);this.updateInternal(n[0],r[0],r[1])}simplify(){this._verse=void 0}clone(){return new re(this)}toString(){const t=this.book;return t===""?"":`${t} ${this.chapter}:${this.verse}`}toJSON(){let t=this.verse;(t===""||t===this.verseNum.toString())&&(t=void 0);const n={book:this.book,chapterNum:this.chapterNum,verseNum:this.verseNum,verse:t,versificationStr:this.versificationStr};return t||delete n.verse,n}equals(t){return t instanceof re?t._bookNum===this._bookNum&&t._chapterNum===this._chapterNum&&t._verseNum===this._verseNum&&t.verse===this.verse&&(t.versification==null&&this.versification==null||t.versification!=null&&this.versification!=null&&t.versification.equals(this.versification)):!1}allVerses(t=!1,n=re.verseRangeSeparators,r=re.verseSequenceIndicators){if(this._verse==null||this.chapterNum<=0)return[this.clone()];const o=[],s=ra(this._verse,r);for(const i of s.map(l=>ra(l,n))){const l=this.clone();l.verse=i[0];const c=l.verseNum;if(o.push(l),i.length>1){const d=this.clone();if(d.verse=i[1],!t)for(let u=c+1;ui)return 3;if(r===i)return 4;r=i}return 0}get internalValid(){return this.versification==null?1:this._bookNum<=0||this._bookNum>ae.lastBook?2:(ae.isCanonical(this._bookNum),0)}setEmpty(t=re.defaultVersification){this._bookNum=0,this._chapterNum=-1,this._verse=void 0,this.versification=t}updateInternal(t,n,r){this.bookNum=ae.bookIdToNumber(t),this.chapter=n,this.verse=r}};ne(Ee,"defaultVersification",ut.English),ne(Ee,"verseRangeSeparator","-"),ne(Ee,"verseSequenceIndicator",","),ne(Ee,"verseRangeSeparators",[Ee.verseRangeSeparator]),ne(Ee,"verseSequenceIndicators",[Ee.verseSequenceIndicator]),ne(Ee,"chapterDigitShifter",1e3),ne(Ee,"bookDigitShifter",Ee.chapterDigitShifter*Ee.chapterDigitShifter),ne(Ee,"bcvMaxValue",Ee.chapterDigitShifter-1),ne(Ee,"ValidStatusType",is);class tn extends Error{}const or=pe.Root,io=pe.Trigger,ls=pe.Group,Fl=pe.Portal,Gl=pe.Sub,Ul=pe.RadioGroup,cs=g.forwardRef(({className:e,inset:t,children:n,...r},o)=>a.jsxs(pe.SubTrigger,{ref:o,className:N("tw-flex tw-cursor-default tw-select-none tw-items-center tw-rounded-sm tw-px-2 tw-py-1.5 tw-text-sm tw-outline-none focus:tw-bg-accent data-[state=open]:tw-bg-accent",t&&"tw-pl-8",e),...r,children:[n,a.jsx(ee.ChevronRight,{className:"tw-ml-auto tw-h-4 tw-w-4"})]}));cs.displayName=pe.SubTrigger.displayName;const ds=g.forwardRef(({className:e,...t},n)=>a.jsx(pe.SubContent,{ref:n,className:N("tw-z-50 tw-min-w-[8rem] tw-overflow-hidden tw-rounded-md tw-border tw-bg-popover tw-p-1 tw-text-popover-foreground tw-shadow-lg data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0 data-[state=closed]:tw-zoom-out-95 data-[state=open]:tw-zoom-in-95 data-[side=bottom]:tw-slide-in-from-top-2 data-[side=left]:tw-slide-in-from-right-2 data-[side=right]:tw-slide-in-from-left-2 data-[side=top]:tw-slide-in-from-bottom-2",e),...t}));ds.displayName=pe.SubContent.displayName;const En=g.forwardRef(({className:e,sideOffset:t=4,...n},r)=>a.jsx(pe.Portal,{children:a.jsx(pe.Content,{ref:r,sideOffset:t,className:N("pr-twp tw-z-50 tw-min-w-[8rem] tw-overflow-hidden tw-rounded-md tw-border tw-bg-popover tw-p-1 tw-text-popover-foreground tw-shadow-md data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0 data-[state=closed]:tw-zoom-out-95 data-[state=open]:tw-zoom-in-95 data-[side=bottom]:tw-slide-in-from-top-2 data-[side=left]:tw-slide-in-from-right-2 data-[side=right]:tw-slide-in-from-left-2 data-[side=top]:tw-slide-in-from-bottom-2",e),...n})}));En.displayName=pe.Content.displayName;const lo=g.forwardRef(({className:e,inset:t,...n},r)=>a.jsx(pe.Item,{ref:r,className:N("tw-cursor-default tw-select-none tw-items-center tw-rounded-sm tw-px-2 tw-py-1.5 tw-text-sm tw-outline-none tw-transition-colors focus:tw-bg-accent data-[disabled]:tw-pointer-events-none data-[disabled]:tw-opacity-50",t&&"tw-pl-8",e),...n}));lo.displayName=pe.Item.displayName;const ar=g.forwardRef(({className:e,children:t,checked:n,...r},o)=>a.jsxs(pe.CheckboxItem,{ref:o,className:N("tw-relative tw-flex tw-cursor-default tw-select-none tw-items-center tw-rounded-sm tw-py-1.5 tw-pl-8 tw-pr-2 tw-text-sm tw-outline-none tw-transition-colors focus:tw-bg-accent focus:tw-text-accent-foreground data-[disabled]:tw-pointer-events-none data-[disabled]:tw-opacity-50",e),checked:n,...r,children:[a.jsx("span",{className:"tw-absolute tw-left-2 tw-flex tw-h-3.5 tw-w-3.5 tw-items-center tw-justify-center",children:a.jsx(pe.ItemIndicator,{children:a.jsx(ee.Check,{className:"tw-h-4 tw-w-4"})})}),t]}));ar.displayName=pe.CheckboxItem.displayName;const co=g.forwardRef(({className:e,children:t,...n},r)=>a.jsxs(pe.RadioItem,{ref:r,className:N("tw-relative tw-flex tw-cursor-default tw-select-none tw-items-center tw-rounded-sm tw-py-1.5 tw-pl-8 tw-pr-2 tw-text-sm tw-outline-none tw-transition-colors focus:tw-bg-accent focus:tw-text-accent-foreground data-[disabled]:tw-pointer-events-none data-[disabled]:tw-opacity-50",e),...n,children:[a.jsx("span",{className:"tw-absolute tw-left-2 tw-flex tw-h-3.5 tw-w-3.5 tw-items-center tw-justify-center",children:a.jsx(pe.ItemIndicator,{children:a.jsx(ee.Circle,{className:"tw-h-2 tw-w-2 tw-fill-current"})})}),t]}));co.displayName=pe.RadioItem.displayName;const Yt=g.forwardRef(({className:e,inset:t,...n},r)=>a.jsx(pe.Label,{ref:r,className:N("tw-px-2 tw-py-1.5 tw-text-sm tw-font-semibold",t&&"tw-pl-8",e),...n}));Yt.displayName=pe.Label.displayName;const jn=g.forwardRef(({className:e,...t},n)=>a.jsx(pe.Separator,{ref:n,className:N("tw--mx-1 tw-my-1 tw-h-px tw-bg-muted",e),...t}));jn.displayName=pe.Separator.displayName;function us({className:e,...t}){return a.jsx("span",{className:N("tw-ml-auto tw-text-xs tw-tracking-widest tw-opacity-60",e),...t})}us.displayName="DropdownMenuShortcut";const ql=g.forwardRef(({bookId:e,handleSelectBook:t,isSelected:n,handleHighlightBook:r,handleKeyDown:o,bookType:s,children:i},l)=>a.jsxs(lo,{ref:l,textValue:e,className:N("tw-mx-1 tw-px-1 tw-font-normal tw-text-foreground/80",{"tw-bg-amber-50 tw-text-yellow-900 data-[highlighted]:tw-bg-amber-100":n}),onSelect:c=>{c.preventDefault(),t()},onKeyDown:c=>{o(c)},onFocus:r,onMouseMove:r,children:[a.jsx("span",{className:N("tw-border-b-0 tw-border-l-2 tw-border-r-0 tw-border-t-0 tw-border-solid tw-px-2",{"tw-font-bold":n,"tw-border-l-red-200":s.toLowerCase()==="ot","tw-border-l-purple-200":s.toLowerCase()==="nt","tw-border-l-indigo-200":s.toLowerCase()==="dc"}),children:ae.bookIdToEnglishName(e)}),n&&a.jsx("div",{children:i})]},e));function Hl({handleSelectChapter:e,endChapter:t,activeChapter:n,highlightedChapter:r,handleHighlightedChapter:o}){const s=Array.from({length:t},(l,c)=>c+1),i=g.useCallback(l=>{o(l)},[o]);return a.jsx("div",{className:N("tw-flex tw-flex-wrap tw-items-start tw-justify-start tw-self-stretch"),children:s.map(l=>a.jsx("div",{className:N("tw-box-content tw-flex tw-h-4 tw-w-4 tw-cursor-pointer tw-items-center tw-justify-end tw-rounded-md tw-p-2 tw-text-amber-800",{"tw-font-semibold tw-text-amber-900":l===n,"tw-bg-amber-200":l===r}),onClick:c=>{c.preventDefault(),c.stopPropagation(),e(l)},role:"button",onKeyDown:c=>{c.key==="Enter"&&e(l)},tabIndex:0,onMouseMove:()=>i(l),children:l},l))})}function Xl({handleSort:e,handleLocationHistory:t,handleBookmarks:n}){return a.jsxs(Yt,{className:"tw-flex tw-justify-between",children:[a.jsx("p",{className:"tw-inline-block tw-align-middle",children:"Go To"}),a.jsxs("div",{className:"tw-flex tw-items-center",children:[a.jsx(ee.ArrowDownWideNarrow,{onClick:e,className:"tw-m-2 tw-h-4 tw-w-4 tw-cursor-pointer tw-gap-2"}),a.jsx(ee.Clock,{onClick:t,className:"tw-m-2 tw-h-4 tw-w-4 tw-cursor-pointer tw-gap-2"}),a.jsx(ee.Bookmark,{onClick:n,className:"tw-m-2 tw-h-4 tw-w-4 tw-cursor-pointer tw-gap-2"})]})]})}const pn=ae.allBookIds,Yl={OT:"Old Testament",NT:"New Testament",DC:"Deuterocanon"},oa=["OT","NT","DC"],Wl=32+32+32,Kl=[/^(\w+)$/i,/^(\w+)(?:\s(\d+))$/i,/^(\w+)(?:\s(\d+):(\d+))$/i],Jl=e=>({OT:pn.filter(n=>ae.isBookOT(n)),NT:pn.filter(n=>ae.isBookNT(n)),DC:pn.filter(n=>ae.isBookDC(n))})[e],nn=e=>W.getChaptersForBook(ae.bookIdToNumber(e));function Zl(){return pn.map(t=>ae.bookIdToEnglishName(t))}function Ql(e){return Zl().includes(e)}function ec(e){const t=e.toLowerCase().replace(/^\w/,n=>n.toUpperCase());if(Ql(t))return pn.find(r=>ae.bookIdToEnglishName(r)===t)}function tc({scrRef:e,handleSubmit:t}){const[n,r]=g.useState(""),[o,s]=g.useState(ae.bookNumberToId(e.bookNum)),[i,l]=g.useState(e.chapterNum??0),[c,d]=g.useState(ae.bookNumberToId(e.bookNum)),[u,f]=g.useState(!1),[w,b]=g.useState(u),x=g.useRef(void 0),m=g.useRef(void 0),h=g.useRef(void 0),E=g.useCallback(k=>Jl(k).filter(A=>{const M=ae.bookIdToEnglishName(A).toLowerCase(),J=n.replace(/[^a-zA-Z]/g,"").toLowerCase();return M.includes(J)||A.toLowerCase().includes(J)}),[n]),I=k=>{r(k)},C=g.useRef(!1),S=g.useCallback(k=>{if(C.current){C.current=!1;return}f(k)},[]),v=g.useCallback((k,A,M,J)=>{if(l(ae.bookNumberToId(e.bookNum)!==k?1:e.chapterNum),A||nn(k)===-1){t({bookNum:ae.bookIdToNumber(k),chapterNum:M||1,verseNum:J||1}),f(!1),r("");return}s(o!==k?k:""),f(!A)},[t,e.bookNum,e.chapterNum,o]),_=k=>{k<=0||k>nn(o)||v(o,!0,k)},V=g.useCallback(()=>{Kl.forEach(k=>{const A=n.match(k);if(A){const[M,J=void 0,Y=void 0]=A.slice(1),F=ec(M);(ae.isBookIdValid(M)||F)&&v(F??M,!0,J?parseInt(J,10):1,Y?parseInt(Y,10):1)}})},[v,n]),U=g.useCallback(k=>{u?(k.key==="ArrowDown"||k.key==="ArrowUp")&&(typeof h<"u"&&h.current!==null?h.current.focus():typeof m<"u"&&m.current!==null&&m.current.focus(),k.preventDefault()):f(!0)},[u]),j=k=>{const{key:A}=k;A==="ArrowRight"||A==="ArrowLeft"||A==="ArrowDown"||A==="ArrowUp"||A==="Enter"||(x.current.dispatchEvent(new KeyboardEvent("keydown",{key:A})),x.current.focus())},O=k=>{const{key:A}=k;if(c===o){if(A==="Enter"){k.preventDefault(),v(o,!0,i);return}let M=0;if(A==="ArrowRight")if(i1)M=-1;else{k.preventDefault();return}else A==="ArrowDown"?M=6:A==="ArrowUp"&&(M=-6);i+M<=0||i+M>nn(c)?l(0):M!==0&&(l(i+M),k.preventDefault())}};return g.useEffect(()=>{o===c?o===ae.bookNumberToId(e.bookNum)?l(e.chapterNum):l(1):l(0)},[c,e.bookNum,e.chapterNum,o]),g.useLayoutEffect(()=>{b(u)},[u]),g.useLayoutEffect(()=>{const k=setTimeout(()=>{if(w&&m.current&&h.current){const M=h.current.offsetTop-Wl;m.current.scrollTo({top:M,behavior:"instant"})}},10);return()=>{clearTimeout(k)}},[w]),a.jsx("div",{className:"pr-twp tw-flex",children:a.jsxs(or,{modal:!1,open:u,onOpenChange:S,children:[a.jsx(io,{asChild:!0,children:a.jsx(Rl,{ref:x,value:n,handleSearch:I,handleKeyDown:U,handleOnClick:()=>{s(ae.bookNumberToId(e.bookNum)),d(ae.bookNumberToId(e.bookNum)),l(e.chapterNum>0?e.chapterNum:0),f(!0),x.current.focus()},onFocus:()=>{C.current=!0},handleSubmit:V,placeholder:`${ae.bookNumberToEnglishName(e.bookNum)} ${e.chapterNum}:${e.verseNum}`})}),a.jsxs(En,{className:"tw-m-1 tw-overflow-y-auto tw-p-0 tw-font-normal tw-text-foreground/80",style:{width:"233px",maxHeight:"500px",zIndex:"250"},onKeyDown:j,align:"start",ref:m,children:[a.jsx(Xl,{handleSort:()=>console.log("sorting"),handleLocationHistory:()=>console.log("location history"),handleBookmarks:()=>console.log("bookmarks")}),oa.map((k,A)=>E(k).length>0&&a.jsxs("div",{children:[a.jsx(Yt,{className:"tw-font-semibold tw-text-foreground/80",children:Yl[k]}),E(k).map(M=>a.jsx("div",{children:a.jsx(ql,{bookId:M,handleSelectBook:()=>v(M,!1),isSelected:o===M,handleHighlightBook:()=>d(M),handleKeyDown:O,bookType:k,ref:J=>{o===M&&(h.current=J)},children:a.jsx(Hl,{handleSelectChapter:_,endChapter:nn(M),activeChapter:e.bookNum===ae.bookIdToNumber(M)?e.chapterNum:0,highlightedChapter:i,handleHighlightedChapter:J=>{l(J)}})})},M)),oa.length-1!==A?a.jsx(jn,{}):void 0]},k))]})]})})}const ps=kn.cva("pr-twp tw-inline-flex tw-items-center tw-justify-center tw-whitespace-nowrap tw-rounded-md tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-colors focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50",{variants:{variant:{default:"tw-bg-primary tw-text-primary-foreground hover:tw-bg-primary/90",destructive:"tw-bg-destructive tw-text-destructive-foreground hover:tw-bg-destructive/90",outline:"tw-border tw-border-input tw-bg-background hover:tw-bg-accent hover:tw-text-accent-foreground",secondary:"tw-bg-secondary tw-text-secondary-foreground hover:tw-bg-secondary/80",ghost:"hover:tw-bg-accent hover:tw-text-accent-foreground",link:"tw-text-primary tw-underline-offset-4 hover:tw-underline"},size:{default:"tw-h-10 tw-px-4 tw-py-2",sm:"tw-h-9 tw-rounded-md tw-px-3",lg:"tw-h-11 tw-rounded-md tw-px-8",icon:"tw-h-10 tw-w-10"}},defaultVariants:{variant:"default",size:"default"}}),fe=g.forwardRef(({className:e,variant:t,size:n,asChild:r=!1,...o},s)=>{const i=r?Ht.Slot:"button";return a.jsx(i,{className:N(ps({variant:t,size:n,className:e})),ref:s,...o})});fe.displayName="Button";const nc=kn.cva("tw-text-sm tw-font-medium tw-leading-none peer-disabled:tw-cursor-not-allowed peer-disabled:tw-opacity-70"),Ue=g.forwardRef(({className:e,...t},n)=>a.jsx(Qa.Root,{ref:n,className:N("pr-twp",nc(),e),...t}));Ue.displayName=Qa.Root.displayName;const uo=g.forwardRef(({className:e,...t},n)=>a.jsx(gn.Root,{className:N("pr-twp tw-grid tw-gap-2",e),...t,ref:n}));uo.displayName=gn.Root.displayName;const Yn=g.forwardRef(({className:e,...t},n)=>a.jsx(gn.Item,{ref:n,className:N("pr-twp tw-aspect-square tw-h-4 tw-w-4 tw-rounded-full tw-border tw-border-primary tw-text-primary tw-ring-offset-background focus:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-cursor-not-allowed disabled:tw-opacity-50",e),...t,children:a.jsx(gn.Indicator,{className:"tw-flex tw-items-center tw-justify-center",children:a.jsx(ee.Circle,{className:"tw-h-2.5 tw-w-2.5 tw-fill-current tw-text-current"})})}));Yn.displayName=gn.Item.displayName;const rc=bn.Root,oc=bn.Trigger,ws=g.forwardRef(({className:e,align:t="center",sideOffset:n=4,...r},o)=>a.jsx(bn.Portal,{children:a.jsx(bn.Content,{ref:o,align:t,sideOffset:n,className:N("pr-twp tw-z-50 tw-w-72 tw-rounded-md tw-border tw-bg-popover tw-p-4 tw-text-popover-foreground tw-shadow-md tw-outline-none data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0 data-[state=closed]:tw-zoom-out-95 data-[state=open]:tw-zoom-in-95 data-[side=bottom]:tw-slide-in-from-top-2 data-[side=left]:tw-slide-in-from-right-2 data-[side=right]:tw-slide-in-from-left-2 data-[side=top]:tw-slide-in-from-bottom-2",e),...r})}));ws.displayName=bn.Content.displayName;const ac=Xe.Portal,fs=g.forwardRef(({className:e,...t},n)=>a.jsx(Xe.Overlay,{ref:n,className:N("tw-fixed tw-inset-0 tw-z-50 tw-bg-black/80 data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0",e),...t}));fs.displayName=Xe.Overlay.displayName;const sc=g.forwardRef(({className:e,children:t,...n},r)=>a.jsxs(ac,{children:[a.jsx(fs,{}),a.jsxs(Xe.Content,{ref:r,className:N("tw-fixed tw-left-[50%] tw-top-[50%] tw-z-50 tw-grid tw-w-full tw-max-w-lg tw-translate-x-[-50%] tw-translate-y-[-50%] tw-gap-4 tw-border tw-bg-background tw-p-6 tw-shadow-lg tw-duration-200 data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0 data-[state=closed]:tw-zoom-out-95 data-[state=open]:tw-zoom-in-95 data-[state=closed]:tw-slide-out-to-left-1/2 data-[state=closed]:tw-slide-out-to-top-[48%] data-[state=open]:tw-slide-in-from-left-1/2 data-[state=open]:tw-slide-in-from-top-[48%] sm:tw-rounded-lg",e),...n,children:[t,a.jsxs(Xe.Close,{className:"tw-absolute tw-right-4 tw-top-4 tw-rounded-sm tw-opacity-70 tw-ring-offset-background tw-transition-opacity hover:tw-opacity-100 focus:tw-outline-none focus:tw-ring-2 focus:tw-ring-ring focus:tw-ring-offset-2 disabled:tw-pointer-events-none data-[state=open]:tw-bg-accent data-[state=open]:tw-text-muted-foreground",children:[a.jsx(ee.X,{className:"tw-h-4 tw-w-4"}),a.jsx("span",{className:"tw-sr-only",children:"Close"})]})]})]}));sc.displayName=Xe.Content.displayName;const ic=g.forwardRef(({className:e,...t},n)=>a.jsx(Xe.Title,{ref:n,className:N("tw-text-lg tw-font-semibold tw-leading-none tw-tracking-tight",e),...t}));ic.displayName=Xe.Title.displayName;const lc=g.forwardRef(({className:e,...t},n)=>a.jsx(Xe.Description,{ref:n,className:N("tw-text-sm tw-text-muted-foreground",e),...t}));lc.displayName=Xe.Description.displayName;const ms=g.forwardRef(({className:e,...t},n)=>a.jsx(Ce.Command,{ref:n,className:N("tw-flex tw-h-full tw-w-full tw-flex-col tw-overflow-hidden tw-rounded-md tw-bg-popover tw-text-popover-foreground",e),...t}));ms.displayName=Ce.Command.displayName;const hs=g.forwardRef(({className:e,...t},n)=>a.jsxs("div",{className:"tw-flex tw-items-center tw-border-b tw-px-3",children:[a.jsx(ee.Search,{className:"tw-me-2 tw-h-4 tw-w-4 tw-shrink-0 tw-opacity-50"}),a.jsx(Ce.Command.Input,{ref:n,className:N("tw-flex tw-h-11 tw-w-full tw-rounded-md tw-bg-transparent tw-py-3 tw-text-sm tw-outline-none placeholder:tw-text-muted-foreground disabled:tw-cursor-not-allowed disabled:tw-opacity-50",e),...t})]}));hs.displayName=Ce.Command.Input.displayName;const gs=g.forwardRef(({className:e,...t},n)=>a.jsx(Ce.Command.List,{ref:n,className:N("tw-max-h-[300px] tw-overflow-y-auto tw-overflow-x-hidden",e),...t}));gs.displayName=Ce.Command.List.displayName;const bs=g.forwardRef((e,t)=>a.jsx(Ce.Command.Empty,{ref:t,className:"tw-py-6 tw-text-center tw-text-sm",...e}));bs.displayName=Ce.Command.Empty.displayName;const cc=g.forwardRef(({className:e,...t},n)=>a.jsx(Ce.Command.Group,{ref:n,className:N("tw-overflow-hidden tw-p-1 tw-text-foreground [&_[cmdk-group-heading]]:tw-px-2 [&_[cmdk-group-heading]]:tw-py-1.5 [&_[cmdk-group-heading]]:tw-text-xs [&_[cmdk-group-heading]]:tw-font-medium [&_[cmdk-group-heading]]:tw-text-muted-foreground",e),...t}));cc.displayName=Ce.Command.Group.displayName;const dc=g.forwardRef(({className:e,...t},n)=>a.jsx(Ce.Command.Separator,{ref:n,className:N("tw--mx-1 tw-h-px tw-bg-border",e),...t}));dc.displayName=Ce.Command.Separator.displayName;const vs=g.forwardRef(({className:e,...t},n)=>a.jsx(Ce.Command.Item,{ref:n,className:N("tw-relative tw-flex tw-cursor-default tw-select-none tw-items-center tw-rounded-sm tw-px-2 tw-py-1.5 tw-text-sm tw-outline-none data-[disabled=true]:tw-pointer-events-none data-[selected=true]:tw-bg-accent data-[selected=true]:tw-text-accent-foreground data-[disabled=true]:tw-opacity-50",e),...t}));vs.displayName=Ce.Command.Item.displayName;function uc(e){return typeof e=="string"?e:typeof e=="number"?e.toString():e.label}function Wn({id:e,options:t=[],buttonClassName:n,popoverContentClassName:r,value:o,onChange:s=()=>{},getOptionLabel:i=uc,buttonPlaceholder:l="",textPlaceholder:c="",commandEmptyMessage:d="No option found",buttonVariant:u="outline",dir:f="ltr",isDisabled:w=!1,...b}){const[x,m]=g.useState(!1);return a.jsxs(rc,{open:x,onOpenChange:m,...b,children:[a.jsx(oc,{asChild:!0,children:a.jsxs(fe,{variant:u,role:"combobox","aria-expanded":x,id:e,className:N("tw-w-[200px] tw-justify-between",n),disabled:w,children:[a.jsx("span",{className:"tw-overflow-hidden tw-text-ellipsis tw-whitespace-nowrap",children:o?i(o):l}),a.jsx(ee.ChevronsUpDown,{className:"tw-ms-2 tw-h-4 tw-w-4 tw-shrink-0 tw-opacity-50"})]})}),a.jsx(ws,{className:N("tw-w-[200px] tw-p-0",r),dir:f,children:a.jsxs(ms,{children:[a.jsx(hs,{dir:f,placeholder:c,className:"tw-text-inherit"}),a.jsx(bs,{children:d}),a.jsx(gs,{children:t.map(h=>a.jsxs(vs,{value:i(h),onSelect:()=>{s(h),m(!1)},children:[a.jsx(ee.Check,{className:N("tw-me-2 tw-h-4 tw-w-4",{"tw-opacity-0":!o||i(o)!==i(h)})}),i(h)]},i(h)))})]})})]})}function xs({startChapter:e,endChapter:t,handleSelectStartChapter:n,handleSelectEndChapter:r,isDisabled:o=!1,chapterCount:s}){const i=g.useMemo(()=>Array.from({length:s},(d,u)=>u+1),[s]),l=d=>{n(d),d>t&&r(d)},c=d=>{r(d),dd.toString(),value:e},"start chapter"),a.jsx(Ue,{htmlFor:"end-chapters-combobox",children:"to"}),a.jsx(Wn,{isDisabled:o,onChange:c,buttonClassName:"tw-ml-2 tw-w-20",options:i,getOptionLabel:d=>d.toString(),value:t},"end chapter")]})}var ys=(e=>(e.CURRENT_BOOK="current book",e.CHOOSE_BOOKS="choose books",e))(ys||{});const pc=Object.freeze(["%webView_bookSelector_currentBook%","%webView_bookSelector_choose%","%webView_bookSelector_chooseBooks%"]),Cr=(e,t)=>e[t]??t;function wc({handleBookSelectionModeChange:e,currentBookName:t,onSelectBooks:n,selectedBookIds:r,chapterCount:o,endChapter:s,handleSelectEndChapter:i,startChapter:l,handleSelectStartChapter:c,localizedStrings:d}){const u=Cr(d,"%webView_bookSelector_currentBook%"),f=Cr(d,"%webView_bookSelector_choose%"),w=Cr(d,"%webView_bookSelector_chooseBooks%"),[b,x]=g.useState("current book"),m=h=>{x(h),e(h)};return a.jsx(uo,{className:"pr-twp tw-flex",value:b,onValueChange:h=>m(h),children:a.jsxs("div",{className:"tw-flex tw-w-full tw-flex-col tw-gap-4",children:[a.jsxs("div",{className:"tw-grid tw-grid-cols-[25%,25%,50%]",children:[a.jsxs("div",{className:"tw-flex tw-items-center",children:[a.jsx(Yn,{value:"current book"}),a.jsx(Ue,{className:"tw-ml-1",children:u})]}),a.jsx(Ue,{className:"tw-flex tw-items-center",children:t}),a.jsx("div",{className:"tw-flex tw-items-center tw-justify-end",children:a.jsx(xs,{isDisabled:b==="choose books",handleSelectStartChapter:c,handleSelectEndChapter:i,chapterCount:o,startChapter:l,endChapter:s})})]}),a.jsxs("div",{className:"tw-grid tw-grid-cols-[25%,50%,25%]",children:[a.jsxs("div",{className:"tw-flex tw-items-center",children:[a.jsx(Yn,{value:"choose books"}),a.jsx(Ue,{className:"tw-ml-1",children:w})]}),a.jsx(Ue,{className:"tw-flex tw-items-center",children:r.map(h=>ae.bookIdToEnglishName(h)).join(", ")}),a.jsx(fe,{disabled:b==="current book",onClick:()=>n(),children:f})]})]})})}function fc({table:e}){return a.jsxs(or,{children:[a.jsx(Ja.DropdownMenuTrigger,{asChild:!0,children:a.jsxs(fe,{variant:"outline",size:"sm",className:"tw-ml-auto tw-hidden tw-h-8 lg:tw-flex",children:[a.jsx(ee.FilterIcon,{className:"tw-mr-2 tw-h-4 tw-w-4"}),"View"]})}),a.jsxs(En,{align:"end",className:"tw-w-[150px]",children:[a.jsx(Yt,{children:"Toggle columns"}),a.jsx(jn,{}),e.getAllColumns().filter(t=>t.getCanHide()).map(t=>a.jsx(ar,{className:"tw-capitalize",checked:t.getIsVisible(),onCheckedChange:n=>t.toggleVisibility(!!n),children:t.id},t.id))]})]})}const Dt=ge.Root,Ns=ge.Group,Bt=ge.Value,bt=g.forwardRef(({className:e,children:t,...n},r)=>a.jsxs(ge.Trigger,{ref:r,className:N("tw-flex tw-h-10 tw-w-full tw-items-center tw-justify-between tw-rounded-md tw-border tw-border-input tw-bg-background tw-px-3 tw-py-2 tw-text-sm tw-ring-offset-background placeholder:tw-text-muted-foreground focus:tw-outline-none focus:tw-ring-2 focus:tw-ring-ring focus:tw-ring-offset-2 disabled:tw-cursor-not-allowed disabled:tw-opacity-50 [&>span]:tw-line-clamp-1",e),...n,children:[t,a.jsx(ge.Icon,{asChild:!0,children:a.jsx(ee.ChevronDown,{className:"tw-h-4 tw-w-4 tw-opacity-50"})})]}));bt.displayName=ge.Trigger.displayName;const po=g.forwardRef(({className:e,...t},n)=>a.jsx(ge.ScrollUpButton,{ref:n,className:N("tw-flex tw-cursor-default tw-items-center tw-justify-center tw-py-1",e),...t,children:a.jsx(ee.ChevronUp,{className:"tw-h-4 tw-w-4"})}));po.displayName=ge.ScrollUpButton.displayName;const wo=g.forwardRef(({className:e,...t},n)=>a.jsx(ge.ScrollDownButton,{ref:n,className:N("tw-flex tw-cursor-default tw-items-center tw-justify-center tw-py-1",e),...t,children:a.jsx(ee.ChevronDown,{className:"tw-h-4 tw-w-4"})}));wo.displayName=ge.ScrollDownButton.displayName;const vt=g.forwardRef(({className:e,children:t,position:n="popper",...r},o)=>a.jsx(ge.Portal,{children:a.jsxs(ge.Content,{ref:o,className:N("pr-twp tw-relative tw-z-50 tw-max-h-96 tw-min-w-[8rem] tw-overflow-hidden tw-rounded-md tw-border tw-bg-popover tw-text-popover-foreground tw-shadow-md data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0 data-[state=closed]:tw-zoom-out-95 data-[state=open]:tw-zoom-in-95 data-[side=bottom]:tw-slide-in-from-top-2 data-[side=left]:tw-slide-in-from-right-2 data-[side=right]:tw-slide-in-from-left-2 data-[side=top]:tw-slide-in-from-bottom-2",n==="popper"&&"data-[side=bottom]:tw-translate-y-1 data-[side=left]:tw--translate-x-1 data-[side=right]:tw-translate-x-1 data-[side=top]:tw--translate-y-1",e),position:n,...r,children:[a.jsx(po,{}),a.jsx(ge.Viewport,{className:N("tw-p-1",n==="popper"&&"tw-h-[var(--radix-select-trigger-height)] tw-w-full tw-min-w-[var(--radix-select-trigger-width)]"),children:t}),a.jsx(wo,{})]})}));vt.displayName=ge.Content.displayName;const ks=g.forwardRef(({className:e,...t},n)=>a.jsx(ge.Label,{ref:n,className:N("tw-py-1.5 tw-pl-8 tw-pr-2 tw-text-sm tw-font-semibold",e),...t}));ks.displayName=ge.Label.displayName;const Ae=g.forwardRef(({className:e,children:t,...n},r)=>a.jsxs(ge.Item,{ref:r,className:N("tw-relative tw-flex tw-w-full tw-cursor-default tw-select-none tw-items-center tw-rounded-sm tw-py-1.5 tw-pl-8 tw-pr-2 tw-text-sm tw-outline-none focus:tw-bg-accent focus:tw-text-accent-foreground data-[disabled]:tw-pointer-events-none data-[disabled]:tw-opacity-50",e),...n,children:[a.jsx("span",{className:"tw-absolute tw-left-2 tw-flex tw-h-3.5 tw-w-3.5 tw-items-center tw-justify-center",children:a.jsx(ge.ItemIndicator,{children:a.jsx(ee.Check,{className:"tw-h-4 tw-w-4"})})}),a.jsx(ge.ItemText,{children:t})]}));Ae.displayName=ge.Item.displayName;const Ss=g.forwardRef(({className:e,...t},n)=>a.jsx(ge.Separator,{ref:n,className:N("tw--mx-1 tw-my-1 tw-h-px tw-bg-muted",e),...t}));Ss.displayName=ge.Separator.displayName;function mc({table:e}){return a.jsx("div",{className:"tw-flex tw-items-center tw-justify-between tw-px-2 tw-pb-3 tw-pt-3",children:a.jsxs("div",{className:"tw-flex tw-items-center tw-space-x-6 lg:tw-space-x-8",children:[a.jsxs("div",{className:"tw-flex-1 tw-text-sm tw-text-muted-foreground",children:[e.getFilteredSelectedRowModel().rows.length," of"," ",e.getFilteredRowModel().rows.length," row(s) selected"]}),a.jsxs("div",{className:"tw-flex tw-items-center tw-space-x-2",children:[a.jsx("p",{className:"tw-text-nowrap tw-text-sm tw-font-medium",children:"Rows per page"}),a.jsxs(Dt,{value:`${e.getState().pagination.pageSize}`,onValueChange:t=>{e.setPageSize(Number(t))},children:[a.jsx(bt,{className:"tw-h-8 tw-w-[70px]",children:a.jsx(Bt,{placeholder:e.getState().pagination.pageSize})}),a.jsx(vt,{side:"top",children:[10,20,30,40,50].map(t=>a.jsx(Ae,{value:`${t}`,children:t},t))})]})]}),a.jsxs("div",{className:"tw-flex tw-w-[100px] tw-items-center tw-justify-center tw-text-sm tw-font-medium",children:["Page ",e.getState().pagination.pageIndex+1," of ",e.getPageCount()]}),a.jsxs("div",{className:"tw-flex tw-items-center tw-space-x-2",children:[a.jsxs(fe,{variant:"outline",size:"icon",className:"tw-hidden tw-h-8 tw-w-8 tw-p-0 lg:tw-flex",onClick:()=>e.setPageIndex(0),disabled:!e.getCanPreviousPage(),children:[a.jsx("span",{className:"tw-sr-only",children:"Go to first page"}),a.jsx(ee.ArrowLeftIcon,{className:"tw-h-4 tw-w-4"})]}),a.jsxs(fe,{variant:"outline",size:"icon",className:"tw-h-8 tw-w-8 tw-p-0",onClick:()=>e.previousPage(),disabled:!e.getCanPreviousPage(),children:[a.jsx("span",{className:"tw-sr-only",children:"Go to previous page"}),a.jsx(ee.ChevronLeftIcon,{className:"tw-h-4 tw-w-4"})]}),a.jsxs(fe,{variant:"outline",size:"icon",className:"tw-h-8 tw-w-8 tw-p-0",onClick:()=>e.nextPage(),disabled:!e.getCanNextPage(),children:[a.jsx("span",{className:"tw-sr-only",children:"Go to next page"}),a.jsx(ee.ChevronRightIcon,{className:"tw-h-4 tw-w-4"})]}),a.jsxs(fe,{variant:"outline",size:"icon",className:"tw-hidden tw-h-8 tw-w-8 tw-p-0 lg:tw-flex",onClick:()=>e.setPageIndex(e.getPageCount()-1),disabled:!e.getCanNextPage(),children:[a.jsx("span",{className:"tw-sr-only",children:"Go to last page"}),a.jsx(ee.ArrowRightIcon,{className:"tw-h-4 tw-w-4"})]})]})]})})}const Tn=g.forwardRef(({className:e,stickyHeader:t,...n},r)=>a.jsx("div",{className:N("pr-twp tw-relative tw-w-full",{"tw-overflow-auto":!t}),children:a.jsx("table",{ref:r,className:N("tw-w-full tw-caption-bottom tw-text-sm",e),...n})}));Tn.displayName="Table";const Cn=g.forwardRef(({className:e,stickyHeader:t,...n},r)=>a.jsx("thead",{ref:r,className:N({"tw-sticky tw-top-[-1px] tw-bg-background tw-drop-shadow-sm":t},"[&_tr]:tw-border-b",e),...n}));Cn.displayName="TableHeader";const Rn=g.forwardRef(({className:e,...t},n)=>a.jsx("tbody",{ref:n,className:N("[&_tr:last-child]:tw-border-0",e),...t}));Rn.displayName="TableBody";const Es=g.forwardRef(({className:e,...t},n)=>a.jsx("tfoot",{ref:n,className:N("tw-border-t tw-bg-muted/50 tw-font-medium [&>tr]:last:tw-border-b-0",e),...t}));Es.displayName="TableFooter";const Ze=g.forwardRef(({className:e,...t},n)=>a.jsx("tr",{ref:n,className:N("tw-border-b tw-transition-colors hover:tw-bg-muted/50 data-[state=selected]:tw-bg-muted",e),...t}));Ze.displayName="TableRow";const Vt=g.forwardRef(({className:e,...t},n)=>a.jsx("th",{ref:n,className:N("tw-h-12 tw-px-4 tw-text-start tw-align-middle tw-font-medium tw-text-muted-foreground [&:has([role=checkbox])]:tw-pe-0",e),...t}));Vt.displayName="TableHead";const xt=g.forwardRef(({className:e,...t},n)=>a.jsx("td",{ref:n,className:N("tw-p-4 tw-align-middle [&:has([role=checkbox])]:tw-pe-0",e),...t}));xt.displayName="TableCell";const js=g.forwardRef(({className:e,...t},n)=>a.jsx("caption",{ref:n,className:N("tw-mt-4 tw-text-sm tw-text-muted-foreground",e),...t}));js.displayName="TableCaption";function Ts({columns:e,data:t,enablePagination:n=!1,showPaginationControls:r=!1,showColumnVisibilityControls:o=!1,stickyHeader:s=!1,onRowClickHandler:i=()=>{}}){var h;const[l,c]=g.useState([]),[d,u]=g.useState([]),[f,w]=g.useState({}),[b,x]=g.useState({}),m=ke.useReactTable({data:t,columns:e,getCoreRowModel:ke.getCoreRowModel(),...n&&{getPaginationRowModel:ke.getPaginationRowModel()},onSortingChange:c,getSortedRowModel:ke.getSortedRowModel(),onColumnFiltersChange:u,getFilteredRowModel:ke.getFilteredRowModel(),onColumnVisibilityChange:w,onRowSelectionChange:x,state:{sorting:l,columnFilters:d,columnVisibility:f,rowSelection:b}});return a.jsxs("div",{className:"pr-twp",children:[o&&a.jsx(fc,{table:m}),a.jsxs(Tn,{stickyHeader:s,children:[a.jsx(Cn,{stickyHeader:s,children:m.getHeaderGroups().map(E=>a.jsx(Ze,{children:E.headers.map(I=>a.jsx(Vt,{children:I.isPlaceholder?void 0:ke.flexRender(I.column.columnDef.header,I.getContext())},I.id))},E.id))}),a.jsx(Rn,{children:(h=m.getRowModel().rows)!=null&&h.length?m.getRowModel().rows.map(E=>a.jsx(Ze,{onClick:()=>i(E,m),"data-state":E.getIsSelected()&&"selected",children:E.getVisibleCells().map(I=>a.jsx(xt,{children:ke.flexRender(I.column.columnDef.cell,I.getContext())},I.id))},E.id)):a.jsx(Ze,{children:a.jsx(xt,{colSpan:e.length,className:"tw-h-24 tw-text-center",children:"No results."})})})]}),n&&a.jsxs("div",{className:"tw-flex tw-items-center tw-justify-end tw-space-x-2 tw-py-4",children:[a.jsx(fe,{variant:"outline",size:"sm",onClick:()=>m.previousPage(),disabled:!m.getCanPreviousPage(),children:"Previous"}),a.jsx(fe,{variant:"outline",size:"sm",onClick:()=>m.nextPage(),disabled:!m.getCanNextPage(),children:"Next"})]}),n&&r&&a.jsx(mc,{table:m})]})}function hc({occurrenceData:e,setScriptureReference:t,localizedStrings:n}){const r=n["%webView_inventory_occurrences_table_header_reference%"],o=n["%webView_inventory_occurrences_table_header_occurrence%"],s=g.useMemo(()=>{const i=[];return e.forEach(l=>{i.some(c=>W.deepEqual(c,l))||i.push(l)}),i},[e]);return a.jsxs(Tn,{stickyHeader:!0,children:[a.jsx(Cn,{stickyHeader:!0,children:a.jsxs(Ze,{children:[a.jsx(Vt,{children:r}),a.jsx(Vt,{children:o})]})}),a.jsx(Rn,{children:s.length>0&&s.map(i=>a.jsxs(Ze,{onClick:()=>{t(i.reference)},children:[a.jsx(xt,{children:`${ae.bookNumberToEnglishName(i.reference.bookNum)} ${i.reference.chapterNum}:${i.reference.verseNum}`}),a.jsx(xt,{children:i.text})]},`${i.reference.bookNum} ${i.reference.chapterNum}:${i.reference.verseNum}-${i.text}`))})]})}const sr=g.forwardRef(({className:e,...t},n)=>a.jsx(Gr.Root,{ref:n,className:N("tw-peer pr-twp tw-h-4 tw-w-4 tw-shrink-0 tw-rounded-sm tw-border tw-border-primary tw-ring-offset-background focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-cursor-not-allowed disabled:tw-opacity-50 data-[state=checked]:tw-bg-primary data-[state=checked]:tw-text-primary-foreground",e),...t,children:a.jsx(Gr.Indicator,{className:N("tw-flex tw-items-center tw-justify-center tw-text-current"),children:a.jsx(ee.Check,{className:"tw-h-4 tw-w-4"})})}));sr.displayName=Gr.Root.displayName;const Cs=e=>e.split(/(?:\r?\n|\r)|(?=(?:\\(?:v|c|id)))/g),qr=e=>{const t=/^\\[vc]\s+(\d+)/,n=e.match(t);if(n)return+n[1]},Rs=e=>{const t=e.match(/^\\id\s+([A-Za-z]+)/);return t?ae.bookIdToNumber(t[1]):0},Os=(e,t,n)=>n.includes(e)?"unapproved":t.includes(e)?"approved":"unknown",_s=kn.cva("pr-twp tw-inline-flex tw-items-center tw-justify-center tw-rounded-md tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-colors hover:tw-bg-muted hover:tw-text-muted-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50 data-[state=on]:tw-bg-accent data-[state=on]:tw-text-accent-foreground",{variants:{variant:{default:"tw-bg-transparent",outline:"tw-border tw-border-input tw-bg-transparent hover:tw-bg-accent hover:tw-text-accent-foreground"},size:{default:"tw-h-10 tw-px-3",sm:"tw-h-9 tw-px-2.5",lg:"tw-h-11 tw-px-5"}},defaultVariants:{variant:"default",size:"default"}}),gc=g.forwardRef(({className:e,variant:t,size:n,...r},o)=>a.jsx(es.Root,{ref:o,className:N(_s({variant:t,size:n,className:e})),...r}));gc.displayName=es.Root.displayName;const Ps=g.createContext({size:"default",variant:"default"}),fo=g.forwardRef(({className:e,variant:t,size:n,children:r,...o},s)=>a.jsx(rr.Root,{ref:s,className:N("pr-twp tw-flex tw-items-center tw-justify-center tw-gap-1",e),...o,children:a.jsx(Ps.Provider,{value:{variant:t,size:n},children:r})}));fo.displayName=rr.Root.displayName;const wn=g.forwardRef(({className:e,children:t,variant:n,size:r,...o},s)=>{const i=g.useContext(Ps);return a.jsx(rr.Item,{ref:s,className:N(_s({variant:i.variant||n,size:i.size||r}),e),...o,children:t})});wn.displayName=rr.Item.displayName;const ir=e=>e==="asc"?a.jsx(ee.ArrowUpIcon,{className:"tw-ms-2 tw-h-4 tw-w-4"}):e==="desc"?a.jsx(ee.ArrowDownIcon,{className:"tw-ms-2 tw-h-4 tw-w-4"}):a.jsx(ee.ArrowUpDownIcon,{className:"tw-ms-2 tw-h-4 tw-w-4"}),bc=e=>({accessorKey:"item",accessorFn:t=>t.items[0],header:({column:t})=>a.jsxs(fe,{variant:"ghost",onClick:()=>t.toggleSorting(void 0),children:[e,ir(t.getIsSorted())]})}),vc=(e,t)=>({accessorKey:`item${t}`,accessorFn:n=>n.items[t],header:({column:n})=>a.jsxs(fe,{variant:"ghost",onClick:()=>n.toggleSorting(void 0),children:[e,ir(n.getIsSorted())]})}),xc=e=>({accessorKey:"count",header:({column:t})=>a.jsx("div",{className:"tw-flex tw-justify-end tw-tabular-nums",children:a.jsxs(fe,{variant:"ghost",onClick:()=>t.toggleSorting(void 0),children:[e,ir(t.getIsSorted())]})}),cell:({row:t})=>a.jsx("div",{className:"tw-flex tw-justify-end",children:t.getValue("count")})}),Rr=(e,t,n,r,o,s)=>{let i=[...n];e.forEach(c=>{t==="approved"?i.includes(c)||i.push(c):i=i.filter(d=>d!==c)}),r(i);let l=[...o];e.forEach(c=>{t==="unapproved"?l.includes(c)||l.push(c):l=l.filter(d=>d!==c)}),s(l)},yc=(e,t,n,r,o)=>({accessorKey:"status",header:({column:s})=>a.jsx("div",{className:"tw-flex tw-justify-center",children:a.jsxs(fe,{variant:"ghost",onClick:()=>s.toggleSorting(void 0),children:[e,ir(s.getIsSorted())]})}),cell:({row:s})=>{const i=s.getValue("status"),l=s.getValue("item");return a.jsxs(fo,{value:i,variant:"outline",type:"single",children:[a.jsx(wn,{onClick:()=>Rr([l],"approved",t,n,r,o),value:"approved",children:a.jsx(ee.CircleCheckIcon,{})}),a.jsx(wn,{onClick:()=>Rr([l],"unapproved",t,n,r,o),value:"unapproved",children:a.jsx(ee.CircleXIcon,{})}),a.jsx(wn,{onClick:()=>Rr([l],"unknown",t,n,r,o),value:"unknown",children:a.jsx(ee.CircleHelpIcon,{})})]})}}),Nc=Object.freeze(["%webView_inventory_all%","%webView_inventory_approved%","%webView_inventory_unapproved%","%webView_inventory_unknown%","%webView_inventory_scope_currentBook%","%webView_inventory_scope_chapter%","%webView_inventory_scope_verse%","%webView_inventory_filter_text%","%webView_inventory_show_additional_items%","%webView_inventory_occurrences_table_header_reference%","%webView_inventory_occurrences_table_header_occurrence%"]),kc=(e,t,n)=>{let r=e;return t!=="all"&&(r=r.filter(o=>t==="approved"&&o.status==="approved"||t==="unapproved"&&o.status==="unapproved"||t==="unknown"&&o.status==="unknown")),n!==""&&(r=r.filter(o=>o.items[0].includes(n))),r},Sc=(e,t,n,r,o)=>{if(!e)return[];const s=[];let i=t.bookNum,l=t.chapterNum,c=t.verseNum;return Cs(e).forEach(u=>{u.startsWith("\\id")&&(i=Rs(u),l=0,c=0),u.startsWith("\\c")&&(l=qr(u),c=0),u.startsWith("\\v")&&(c=qr(u),l===0&&(l=t.chapterNum));let f=o.exec(u)??void 0;for(;f;){const w=[];f.forEach(h=>w.push(h));const b=f.index,x=s.find(h=>W.deepEqual(h.items,w)),m={reference:{bookNum:i!==void 0?i:-1,chapterNum:l!==void 0?l:-1,verseNum:c!==void 0?c:-1},text:W.substring(u,Math.max(0,b-25),Math.min(b+25,u.length))};if(x)x.count+=1,x.occurrences.push(m);else{const h={items:w,count:1,status:Os(w[0],n,r),occurrences:[m]};s.push(h)}f=o.exec(u)??void 0}}),s},Je=(e,t)=>e[t]??t;function Ec({scriptureReference:e,setScriptureReference:t,localizedStrings:n,extractItems:r,additionalItemsLabels:o,approvedItems:s,unapprovedItems:i,text:l,scope:c,onScopeChange:d,columns:u}){const f=Je(n,"%webView_inventory_all%"),w=Je(n,"%webView_inventory_approved%"),b=Je(n,"%webView_inventory_unapproved%"),x=Je(n,"%webView_inventory_unknown%"),m=Je(n,"%webView_inventory_scope_currentBook%"),h=Je(n,"%webView_inventory_scope_chapter%"),E=Je(n,"%webView_inventory_scope_verse%"),I=Je(n,"%webView_inventory_filter_text%"),C=Je(n,"%webView_inventory_show_additional_items%"),[S,v]=g.useState(!1),[_,V]=g.useState("all"),[U,j]=g.useState(""),[O,k]=g.useState([]),A=g.useMemo(()=>l?r instanceof RegExp?Sc(l,e,s,i,r):r(l,e,s,i):[],[l,r,e,s,i]),M=g.useMemo(()=>{if(S)return A;const y=[];return A.forEach(T=>{const z=T.items[0],L=y.find(B=>B.items[0]===z);L?(L.count+=T.count,L.occurrences=L.occurrences.concat(T.occurrences)):y.push({items:[z],count:T.count,occurrences:T.occurrences,status:T.status})}),y},[S,A]),J=g.useMemo(()=>kc(M,_,U),[M,_,U]),Y=g.useMemo(()=>{var z,L;if(!S)return u;const y=(z=o==null?void 0:o.tableHeaders)==null?void 0:z.length;if(!y)return u;const T=[];for(let B=0;B{k([])},[J]);const F=(y,T)=>{T.setRowSelection(()=>{const z={};return z[y.index]=!0,z}),k(y.original.items)},te=y=>{if(y==="book"||y==="chapter"||y==="verse")d(y);else throw new Error(`Invalid scope value: ${y}`)},se=y=>{if(y==="all"||y==="approved"||y==="unapproved"||y==="unknown")V(y);else throw new Error(`Invalid status filter value: ${y}`)},oe=g.useMemo(()=>{if(M.length===0||O.length===0)return[];const y=M.filter(T=>W.deepEqual(S?T.items:[T.items[0]],O));if(y.length>1)throw new Error("Selected item is not unique");return y[0].occurrences},[O,S,M]);return a.jsxs("div",{className:"pr-twp tw-flex tw-h-full tw-flex-col",children:[a.jsxs("div",{className:"tw-flex tw-items-stretch",children:[a.jsxs(Dt,{onValueChange:y=>se(y),defaultValue:_,children:[a.jsx(bt,{className:"tw-m-1",children:a.jsx(Bt,{placeholder:"Select filter"})}),a.jsxs(vt,{children:[a.jsx(Ae,{value:"all",children:f}),a.jsx(Ae,{value:"approved",children:w}),a.jsx(Ae,{value:"unapproved",children:b}),a.jsx(Ae,{value:"unknown",children:x})]})]}),a.jsxs(Dt,{onValueChange:y=>te(y),defaultValue:c,children:[a.jsx(bt,{className:"tw-m-1",children:a.jsx(Bt,{placeholder:"Select scope"})}),a.jsxs(vt,{children:[a.jsx(Ae,{value:"book",children:m}),a.jsx(Ae,{value:"chapter",children:h}),a.jsx(Ae,{value:"verse",children:E})]})]}),a.jsx(St,{className:"tw-m-1 tw-rounded-md tw-border",placeholder:I,value:U,onChange:y=>{j(y.target.value)}}),o&&a.jsxs("div",{className:"tw-m-1 tw-flex tw-items-center tw-rounded-md tw-border",children:[a.jsx(sr,{className:"tw-m-1",checked:S,onCheckedChange:y=>{k([]),v(y)}}),a.jsx(Ue,{className:"tw-m-1 tw-flex-shrink-0 tw-whitespace-nowrap",children:(o==null?void 0:o.checkboxText)??C})]})]}),a.jsx("div",{className:"tw-m-1 tw-flex-1 tw-overflow-auto tw-rounded-md tw-border",children:a.jsx(Ts,{columns:Y,data:J,onRowClickHandler:F,stickyHeader:!0})}),oe.length>0&&a.jsx("div",{className:"tw-m-1 tw-flex-1 tw-overflow-auto tw-rounded-md tw-border",children:a.jsx(hc,{occurrenceData:oe,setScriptureReference:t,localizedStrings:n})})]})}function mo({className:e,onSearch:t,placeholder:n,isFullWidth:r}){const[o,s]=g.useState(""),i=l=>{s(l),t(l)};return a.jsx(St,{className:N("tw-flex tw-h-10 tw-rounded-md tw-border tw-border-input tw-bg-background tw-px-3 tw-py-2 tw-text-sm tw-ring-offset-background file:tw-border-0 file:tw-bg-transparent file:tw-text-sm file:tw-font-medium placeholder:tw-text-muted-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-[color:hsl(240,5%,64.9%)] focus-visible:tw-ring-offset-2 disabled:tw-cursor-not-allowed disabled:tw-opacity-50",{"tw-w-full":r},e),placeholder:n,value:o,onChange:l=>i(l.target.value)})}const ho=g.forwardRef(({className:e,...t},n)=>a.jsx(Re.Root,{orientation:"vertical",ref:n,className:N("tw-flex tw-gap-1 tw-rounded-md tw-text-muted-foreground",e),...t}));ho.displayName=Re.List.displayName;const go=g.forwardRef(({className:e,...t},n)=>a.jsx(Re.List,{ref:n,className:N("tw-flex-fit tw-mlk-items-center tw-w-[124px] tw-justify-center tw-rounded-md tw-bg-muted tw-p-1 tw-text-muted-foreground",e),...t}));go.displayName=Re.List.displayName;const Is=g.forwardRef(({className:e,...t},n)=>a.jsx(Re.Trigger,{ref:n,...t,className:N("overflow-clip tw-inline-flex tw-w-[116px] tw-cursor-pointer tw-items-center tw-justify-center tw-break-words tw-rounded-sm tw-border-0 tw-bg-muted tw-px-3 tw-py-1.5 tw-text-sm tw-font-medium tw-text-inherit tw-ring-offset-background tw-transition-all hover:tw-text-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50 data-[state=active]:tw-bg-background data-[state=active]:tw-text-foreground data-[state=active]:tw-shadow-sm",e)})),bo=g.forwardRef(({className:e,...t},n)=>a.jsx(Re.Content,{ref:n,className:N("tw-ms-5 tw-flex-grow tw-text-foreground tw-ring-offset-background focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2",e),...t}));bo.displayName=Re.Content.displayName;function jc({tabList:e,onSearch:t,searchPlaceholder:n,headerTitle:r,isSearchBarFullWidth:o=!1,direction:s="ltr"}){return a.jsxs("div",{className:"pr-twp",children:[a.jsxs("div",{className:"tw-sticky tw-top-0 tw-space-y-2 tw-pb-2",children:[r?a.jsx("h1",{children:r}):"",a.jsx(mo,{isFullWidth:o,onSearch:t,placeholder:n})]}),a.jsxs(ho,{dir:s,children:[a.jsx(go,{children:e.map(i=>a.jsx(Is,{value:i.value,children:i.value},i.key))}),e.map(i=>a.jsx(bo,{value:i.value,children:i.content},i.key))]})]})}const lr=g.forwardRef(({className:e,orientation:t="horizontal",decorative:n=!0,...r},o)=>a.jsx(ts.Root,{ref:o,decorative:n,orientation:t,className:N("pr-twp tw-shrink-0 tw-bg-border",t==="horizontal"?"tw-h-[1px] tw-w-full":"tw-h-full tw-w-[1px]",e),...r}));lr.displayName=ts.Root.displayName;function aa({className:e,...t}){return a.jsx("div",{className:N("pr-twp tw-animate-pulse tw-rounded-md tw-bg-muted",e),...t})}const Tc=Sn.Provider,Cc=Sn.Root,Rc=Sn.Trigger,Ms=g.forwardRef(({className:e,sideOffset:t=4,...n},r)=>a.jsx(Sn.Content,{ref:r,sideOffset:t,className:N("pr-twp tw-z-50 tw-overflow-hidden tw-rounded-md tw-border tw-bg-popover tw-px-3 tw-py-1.5 tw-text-sm tw-text-popover-foreground tw-shadow-md tw-animate-in tw-fade-in-0 tw-zoom-in-95 data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=closed]:tw-zoom-out-95 data-[side=bottom]:tw-slide-in-from-top-2 data-[side=left]:tw-slide-in-from-right-2 data-[side=right]:tw-slide-in-from-left-2 data-[side=top]:tw-slide-in-from-bottom-2",e),...n}));Ms.displayName=Sn.Content.displayName;const Oc="16rem",_c="3rem",$s=g.createContext(void 0);function cr(){const e=g.useContext($s);if(!e)throw new Error("useSidebar must be used within a SidebarProvider.");return e}const As=g.forwardRef(({defaultOpen:e=!0,open:t,onOpenChange:n,className:r,style:o,children:s,...i},l)=>{const[c,d]=g.useState(e),u=t??c,f=g.useCallback(m=>{const h=typeof m=="function"?m(u):m;n?n(h):d(h)},[n,u]),w=g.useCallback(()=>f(m=>!m),[f]),b=u?"expanded":"collapsed",x=g.useMemo(()=>({state:b,open:u,setOpen:f,toggleSidebar:w}),[b,u,f,w]);return a.jsx($s.Provider,{value:x,children:a.jsx(Tc,{delayDuration:0,children:a.jsx("div",{style:{"--sidebar-width":Oc,"--sidebar-width-icon":_c,...o},className:N("tw-group/sidebar-wrapper has-[[data-variant=inset]]:tw-bg-sidebar pr-twp tw-flex tw-w-full",r),ref:l,...i,children:s})})})});As.displayName="SidebarProvider";const Ds=g.forwardRef(({side:e="left",variant:t="sidebar",collapsible:n="offcanvas",className:r,children:o,...s},i)=>{const{state:l}=cr();return n==="none"?a.jsx("div",{className:N("tw-bg-sidebar tw-text-sidebar-foreground tw-flex tw-h-full tw-w-[--sidebar-width] tw-flex-col",r),ref:i,...s,children:o}):a.jsxs("div",{ref:i,className:"tw-text-sidebar-foreground tw-group tw-peer tw-hidden md:tw-block","data-state":l,"data-collapsible":l==="collapsed"?n:"","data-variant":t,"data-side":e,children:[a.jsx("div",{className:N("tw-relative tw-h-svh tw-w-[--sidebar-width] tw-bg-transparent tw-transition-[width] tw-duration-200 tw-ease-linear","group-data-[collapsible=offcanvas]:tw-w-0","group-data-[side=right]:tw-rotate-180",t==="floating"||t==="inset"?"group-data-[collapsible=icon]:tw-w-[calc(var(--sidebar-width-icon)_+_theme(spacing.4))]":"group-data-[collapsible=icon]:tw-w-[--sidebar-width-icon]")}),a.jsx("div",{className:N("tw-absolute tw-inset-y-0 tw-z-10 tw-hidden tw-h-svh tw-w-[--sidebar-width] tw-transition-[left,right,width] tw-duration-200 tw-ease-linear md:tw-flex",e==="left"?"tw-left-0 group-data-[collapsible=offcanvas]:tw-left-[calc(var(--sidebar-width)*-1)]":"tw-right-0 group-data-[collapsible=offcanvas]:tw-right-[calc(var(--sidebar-width)*-1)]",t==="floating"||t==="inset"?"tw-p-2 group-data-[collapsible=icon]:tw-w-[calc(var(--sidebar-width-icon)_+_theme(spacing.4)_+2px)]":"group-data-[collapsible=icon]:tw-w-[--sidebar-width-icon] group-data-[side=left]:tw-border-r group-data-[side=right]:tw-border-l",r),...s,children:a.jsx("div",{"data-sidebar":"sidebar",className:"tw-bg-sidebar group-data-[variant=floating]:tw-border-sidebar-border tw-flex tw-h-full tw-w-full tw-flex-col group-data-[variant=floating]:tw-rounded-lg group-data-[variant=floating]:tw-border group-data-[variant=floating]:tw-shadow",children:o})})]})});Ds.displayName="Sidebar";const Pc=g.forwardRef(({className:e,onClick:t,...n},r)=>{const{toggleSidebar:o}=cr();return a.jsxs(fe,{ref:r,"data-sidebar":"trigger",variant:"ghost",size:"icon",className:N("tw-h-7 tw-w-7",e),onClick:s=>{t==null||t(s),o()},...n,children:[a.jsx(ee.PanelLeft,{}),a.jsx("span",{className:"tw-sr-only",children:"Toggle Sidebar"})]})});Pc.displayName="SidebarTrigger";const Ic=g.forwardRef(({className:e,...t},n)=>{const{toggleSidebar:r}=cr();return a.jsx("button",{type:"button",ref:n,"data-sidebar":"rail","aria-label":"Toggle Sidebar",tabIndex:-1,onClick:r,title:"Toggle Sidebar",className:N("hover:after:tw-bg-sidebar-border tw-absolute tw-inset-y-0 tw-z-20 tw-hidden tw-w-4 tw--translate-x-1/2 tw-transition-all tw-ease-linear after:tw-absolute after:tw-inset-y-0 after:tw-left-1/2 after:tw-w-[2px] group-data-[side=left]:tw--right-4 group-data-[side=right]:tw-left-0 sm:tw-flex","[[data-side=left]_&]:tw-cursor-w-resize [[data-side=right]_&]:tw-cursor-e-resize","[[data-side=left][data-state=collapsed]_&]:tw-cursor-e-resize [[data-side=right][data-state=collapsed]_&]:tw-cursor-w-resize","group-data-[collapsible=offcanvas]:hover:tw-bg-sidebar group-data-[collapsible=offcanvas]:tw-translate-x-0 group-data-[collapsible=offcanvas]:after:tw-left-full","[[data-side=left][data-collapsible=offcanvas]_&]:tw--right-2","[[data-side=right][data-collapsible=offcanvas]_&]:tw--left-2",e),...t})});Ic.displayName="SidebarRail";const Bs=g.forwardRef(({className:e,...t},n)=>a.jsx("main",{ref:n,className:N("tw-relative tw-flex tw-flex-1 tw-flex-col tw-bg-background","peer-data-[variant=inset]:tw-min-h-[calc(100svh-theme(spacing.4))] md:peer-data-[variant=inset]:tw-m-2 md:peer-data-[state=collapsed]:peer-data-[variant=inset]:tw-ml-2 md:peer-data-[variant=inset]:tw-ml-0 md:peer-data-[variant=inset]:tw-rounded-xl md:peer-data-[variant=inset]:tw-shadow",e),...t}));Bs.displayName="SidebarInset";const Mc=g.forwardRef(({className:e,...t},n)=>a.jsx(St,{ref:n,"data-sidebar":"input",className:N("focus-visible:tw-ring-sidebar-ring tw-h-8 tw-w-full tw-bg-background tw-shadow-none focus-visible:tw-ring-2",e),...t}));Mc.displayName="SidebarInput";const $c=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,"data-sidebar":"header",className:N("tw-flex tw-flex-col tw-gap-2 tw-p-2",e),...t}));$c.displayName="SidebarHeader";const Ac=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,"data-sidebar":"footer",className:N("tw-flex tw-flex-col tw-gap-2 tw-p-2",e),...t}));Ac.displayName="SidebarFooter";const Dc=g.forwardRef(({className:e,...t},n)=>a.jsx(lr,{ref:n,"data-sidebar":"separator",className:N("tw-bg-sidebar-border tw-mx-2 tw-w-auto",e),...t}));Dc.displayName="SidebarSeparator";const Vs=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,"data-sidebar":"content",className:N("tw-flex tw-min-h-0 tw-flex-1 tw-flex-col tw-gap-2 tw-overflow-auto group-data-[collapsible=icon]:tw-overflow-hidden",e),...t}));Vs.displayName="SidebarContent";const Hr=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,"data-sidebar":"group",className:N("tw-relative tw-flex tw-w-full tw-min-w-0 tw-flex-col tw-p-2",e),...t}));Hr.displayName="SidebarGroup";const Xr=g.forwardRef(({className:e,asChild:t=!1,...n},r)=>{const o=t?Ht.Slot:"div";return a.jsx(o,{ref:r,"data-sidebar":"group-label",className:N("tw-text-sidebar-foreground/70 tw-ring-sidebar-ring tw-flex tw-h-8 tw-shrink-0 tw-items-center tw-rounded-md tw-px-2 tw-text-xs tw-font-medium tw-outline-none tw-transition-[margin,opa] tw-duration-200 tw-ease-linear focus-visible:tw-ring-2 [&>svg]:tw-size-4 [&>svg]:tw-shrink-0","group-data-[collapsible=icon]:tw--mt-8 group-data-[collapsible=icon]:tw-opacity-0",e),...n})});Xr.displayName="SidebarGroupLabel";const Bc=g.forwardRef(({className:e,asChild:t=!1,...n},r)=>{const o=t?Ht.Slot:"button";return a.jsx(o,{ref:r,"data-sidebar":"group-action",className:N("tw-text-sidebar-foreground tw-ring-sidebar-ring hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground tw-absolute tw-right-3 tw-top-3.5 tw-flex tw-aspect-square tw-w-5 tw-items-center tw-justify-center tw-rounded-md tw-p-0 tw-outline-none tw-transition-transform focus-visible:tw-ring-2 [&>svg]:tw-size-4 [&>svg]:tw-shrink-0","after:tw-absolute after:tw--inset-2 after:md:tw-hidden","group-data-[collapsible=icon]:tw-hidden",e),...n})});Bc.displayName="SidebarGroupAction";const Yr=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,"data-sidebar":"group-content",className:N("tw-w-full tw-text-sm",e),...t}));Yr.displayName="SidebarGroupContent";const zs=g.forwardRef(({className:e,...t},n)=>a.jsx("ul",{ref:n,"data-sidebar":"menu",className:N("tw-flex tw-w-full tw-min-w-0 tw-flex-col tw-gap-1",e),...t}));zs.displayName="SidebarMenu";const Ls=g.forwardRef(({className:e,...t},n)=>a.jsx("li",{ref:n,"data-sidebar":"menu-item",className:N("tw-group/menu-item tw-relative",e),...t}));Ls.displayName="SidebarMenuItem";const Vc=kn.cva("tw-peer/menu-button tw-flex tw-w-full tw-items-center tw-gap-2 tw-overflow-hidden tw-rounded-md tw-p-2 tw-text-left tw-text-sm tw-outline-none tw-ring-sidebar-ring tw-transition-[width,height,padding] hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground focus-visible:tw-ring-2 active:tw-bg-sidebar-accent active:tw-text-sidebar-accent-foreground disabled:tw-pointer-events-none disabled:tw-opacity-50 tw-group-has-[[data-sidebar=menu-action]]/menu-item:pr-8 aria-disabled:tw-pointer-events-none aria-disabled:tw-opacity-50 data-[active=true]:tw-font-medium data-[active=true]:tw-text-sidebar-accent-foreground data-[state=open]:hover:tw-bg-sidebar-accent data-[state=open]:hover:tw-text-sidebar-accent-foreground group-data-[collapsible=icon]:tw-!size-8 group-data-[collapsible=icon]:tw-!p-2 [&>span:last-child]:tw-truncate [&>svg]:tw-size-4 [&>svg]:tw-shrink-0",{variants:{variant:{default:"hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground",outline:"tw-bg-background tw-shadow-[0_0_0_1px_hsl(var(--sidebar-border))] hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground hover:tw-shadow-[0_0_0_1px_hsl(var(--sidebar-accent))]"},size:{default:"tw-h-8 tw-text-sm",sm:"tw-h-7 tw-text-xs",lg:"tw-h-12 tw-text-sm group-data-[collapsible=icon]:tw-!p-0"}},defaultVariants:{variant:"default",size:"default"}}),Fs=g.forwardRef(({asChild:e=!1,isActive:t=!1,variant:n="default",size:r="default",tooltip:o,className:s,...i},l)=>{const c=e?Ht.Slot:"button",{state:d}=cr(),u=a.jsx(c,{ref:l,"data-sidebar":"menu-button","data-size":r,"data-active":t,className:N(Vc({variant:n,size:r}),s),...i});return o?(typeof o=="string"&&(o={children:o}),a.jsxs(Cc,{children:[a.jsx(Rc,{asChild:!0,children:u}),a.jsx(Ms,{side:"right",align:"center",hidden:d!=="collapsed",...o})]})):u});Fs.displayName="SidebarMenuButton";const zc=g.forwardRef(({className:e,asChild:t=!1,showOnHover:n=!1,...r},o)=>{const s=t?Ht.Slot:"button";return a.jsx(s,{ref:o,"data-sidebar":"menu-action",className:N("tw-peer-hover/menu-button:text-sidebar-accent-foreground tw-text-sidebar-foreground tw-ring-sidebar-ring hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground tw-absolute tw-right-1 tw-top-1.5 tw-flex tw-aspect-square tw-w-5 tw-items-center tw-justify-center tw-rounded-md tw-p-0 tw-outline-none tw-transition-transform focus-visible:tw-ring-2 [&>svg]:tw-size-4 [&>svg]:tw-shrink-0","after:tw-absolute after:tw--inset-2 after:md:tw-hidden","tw-peer-data-[size=sm]/menu-button:top-1","tw-peer-data-[size=default]/menu-button:top-1.5","tw-peer-data-[size=lg]/menu-button:top-2.5","group-data-[collapsible=icon]:tw-hidden",n&&"tw-group-focus-within/menu-item:opacity-100 tw-group-hover/menu-item:opacity-100 tw-peer-data-[active=true]/menu-button:text-sidebar-accent-foreground data-[state=open]:tw-opacity-100 md:tw-opacity-0",e),...r})});zc.displayName="SidebarMenuAction";const Lc=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,"data-sidebar":"menu-badge",className:N("tw-text-sidebar-foreground tw-pointer-events-none tw-absolute tw-right-1 tw-flex tw-h-5 tw-min-w-5 tw-select-none tw-items-center tw-justify-center tw-rounded-md tw-px-1 tw-text-xs tw-font-medium tw-tabular-nums","tw-peer-hover/menu-button:text-sidebar-accent-foreground tw-peer-data-[active=true]/menu-button:text-sidebar-accent-foreground","tw-peer-data-[size=sm]/menu-button:top-1","tw-peer-data-[size=default]/menu-button:top-1.5","tw-peer-data-[size=lg]/menu-button:top-2.5","group-data-[collapsible=icon]:tw-hidden",e),...t}));Lc.displayName="SidebarMenuBadge";const Fc=g.forwardRef(({className:e,showIcon:t=!1,...n},r)=>{const o=g.useMemo(()=>`${Math.floor(Math.random()*40)+50}%`,[]);return a.jsxs("div",{ref:r,"data-sidebar":"menu-skeleton",className:N("tw-flex tw-h-8 tw-items-center tw-gap-2 tw-rounded-md tw-px-2",e),...n,children:[t&&a.jsx(aa,{className:"tw-size-4 tw-rounded-md","data-sidebar":"menu-skeleton-icon"}),a.jsx(aa,{className:"tw-h-4 tw-max-w-[--skeleton-width] tw-flex-1","data-sidebar":"menu-skeleton-text",style:{"--skeleton-width":o}})]})});Fc.displayName="SidebarMenuSkeleton";const Gc=g.forwardRef(({className:e,...t},n)=>a.jsx("ul",{ref:n,"data-sidebar":"menu-sub",className:N("tw-border-sidebar-border tw-mx-3.5 tw-flex tw-min-w-0 tw-translate-x-px tw-flex-col tw-gap-1 tw-border-l tw-px-2.5 tw-py-0.5","group-data-[collapsible=icon]:tw-hidden",e),...t}));Gc.displayName="SidebarMenuSub";const Uc=g.forwardRef(({...e},t)=>a.jsx("li",{ref:t,...e}));Uc.displayName="SidebarMenuSubItem";const qc=g.forwardRef(({asChild:e=!1,size:t="md",isActive:n,className:r,...o},s)=>{const i=e?Ht.Slot:"a";return a.jsx(i,{ref:s,"data-sidebar":"menu-sub-button","data-size":t,"data-active":n,className:N("tw-text-sidebar-foreground tw-ring-sidebar-ring hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground active:tw-bg-sidebar-accent active:tw-text-sidebar-accent-foreground [&>svg]:tw-text-sidebar-accent-foreground tw-flex tw-h-7 tw-min-w-0 tw--translate-x-px tw-items-center tw-gap-2 tw-overflow-hidden tw-rounded-md tw-px-2 tw-outline-none focus-visible:tw-ring-2 disabled:tw-pointer-events-none disabled:tw-opacity-50 aria-disabled:tw-pointer-events-none aria-disabled:tw-opacity-50 [&>span:last-child]:tw-truncate [&>svg]:tw-size-4 [&>svg]:tw-shrink-0","data-[active=true]:tw-bg-sidebar-accent data-[active=true]:tw-text-sidebar-accent-foreground",t==="sm"&&"tw-text-xs",t==="md"&&"tw-text-sm","group-data-[collapsible=icon]:tw-hidden",r),...o})});qc.displayName="SidebarMenuSubButton";function Gs({id:e,extensionLabels:t,projectInfo:n,handleSelectSidebarItem:r,selectedSidebarItem:o,extensionsSidebarGroupLabel:s,projectsSidebarGroupLabel:i,buttonPlaceholderText:l}){const c=g.useCallback((f,w)=>{r(f,w)},[r]),d=g.useCallback(f=>{const w=n.find(b=>b.projectId===f);return w?w.projectName:f},[n]),u=g.useCallback(f=>!o.projectId&&f===o.label,[o]);return a.jsx(Ds,{id:e,collapsible:"none",variant:"inset",className:"tw-w-96 tw-gap-2 tw-overflow-y-auto tw-rounded tw-bg-slate-100",children:a.jsxs(Vs,{children:[a.jsxs(Hr,{children:[a.jsx(Xr,{className:"tw-text-sm tw-text-gray-400",children:s}),a.jsx(Yr,{children:a.jsx(zs,{children:t.map(f=>a.jsx(Ls,{children:a.jsx(Fs,{className:N("tw-rounded tw-py-2 tw-text-sm tw-text-gray-500 hover:tw-bg-white hover:tw-text-gray-900 hover:tw-shadow-sm active:tw-bg-white",{"tw-bg-white tw-text-gray-900 tw-shadow-sm":u(f)}),onClick:()=>c(f),isActive:u(f),children:a.jsx("span",{className:"tw-pl-3",children:f})})},f))})})]}),a.jsxs(Hr,{children:[a.jsx(Xr,{className:"tw-text-sm tw-text-gray-400",children:i}),a.jsx(Yr,{className:"tw-pl-3",children:a.jsx(Wn,{popoverContentClassName:"tw-z-[1000]",options:n.flatMap(f=>f.projectId),getOptionLabel:f=>d(f),buttonPlaceholder:l,onChange:f=>{const w=d(f);c(w,f)},value:(o==null?void 0:o.projectId)??void 0})})]})]})})}function Hc({id:e,extensionLabels:t,projectInfo:n,children:r,handleSelectSidebarItem:o,selectedSidebarItem:s,onSearch:i,extensionsSidebarGroupLabel:l,projectsSidebarGroupLabel:c,buttonPlaceholderText:d}){return a.jsxs("div",{className:"tw-box-border tw-flex tw-h-full tw-flex-col tw-p-3",children:[a.jsx("div",{className:"tw-box-border tw-flex tw-items-center tw-justify-center tw-py-4",children:a.jsx(mo,{className:"tw-w-9/12",onSearch:i,placeholder:"Search app settings, extension settings, and project settings"})}),a.jsxs(As,{id:e,className:"tw-h-full tw-flex-1 tw-gap-4 tw-overflow-auto",children:[a.jsx(Gs,{extensionLabels:t,projectInfo:n,handleSelectSidebarItem:o,selectedSidebarItem:s,extensionsSidebarGroupLabel:l,projectsSidebarGroupLabel:c,buttonPlaceholderText:d}),a.jsx(Bs,{className:"tw-overflow-y-auto",children:r})]})]})}const rt="scrBook",Xc="scrRef",pt="source",Yc="details",Wc="Scripture Reference",Kc="Scripture Book",Us="Type",Jc="Details";function Zc(e,t){const n=t??!1;return[{accessorFn:r=>`${ae.bookNumberToId(r.start.bookNum)} ${r.start.chapterNum}:${r.start.verseNum}`,id:rt,header:(e==null?void 0:e.scriptureReferenceColumnName)??Wc,cell:r=>{const o=r.row.original;return r.row.getIsGrouped()?ae.bookNumberToEnglishName(o.start.bookNum):r.row.groupingColumnId===rt?W.formatScrRef(o.start):void 0},getGroupingValue:r=>r.start.bookNum,sortingFn:(r,o)=>W.compareScrRefs(r.original.start,o.original.start),enableGrouping:!0},{accessorFn:r=>W.formatScrRef(r.start),id:Xc,header:void 0,cell:r=>{const o=r.row.original;return r.row.getIsGrouped()?void 0:W.formatScrRef(o.start)},sortingFn:(r,o)=>W.compareScrRefs(r.original.start,o.original.start),enableGrouping:!1},{accessorFn:r=>r.source.displayName,id:pt,header:n?(e==null?void 0:e.typeColumnName)??Us:void 0,cell:r=>n||r.row.getIsGrouped()?r.getValue():void 0,getGroupingValue:r=>r.source.id,sortingFn:(r,o)=>r.original.source.displayName.localeCompare(o.original.source.displayName),enableGrouping:!0},{accessorFn:r=>r.detail,id:Yc,header:(e==null?void 0:e.detailsColumnName)??Jc,cell:r=>r.getValue(),enableGrouping:!1}]}const Qc=e=>{if(!("offset"in e.start))throw new Error("No offset available in range start");if(e.end&&!("offset"in e.end))throw new Error("No offset available in range end");const{offset:t}=e.start;let n=0;return e.end&&({offset:n}=e.end),!e.end||W.compareScrRefs(e.start,e.end)===0?`${W.scrRefToBBBCCCVVV(e.start)}+${t}`:`${W.scrRefToBBBCCCVVV(e.start)}+${t}-${W.scrRefToBBBCCCVVV(e.end)}+${n}`},sa=e=>`${Qc({start:e.start,end:e.end})} ${e.source.displayName} ${e.detail}`;function ed({sources:e,showColumnHeaders:t=!1,showSourceColumn:n=!1,scriptureReferenceColumnName:r,scriptureBookGroupName:o,typeColumnName:s,detailsColumnName:i,onRowSelected:l,direction:c="ltr"}){const[d,u]=g.useState([]),[f,w]=g.useState([{id:rt,desc:!1}]),[b,x]=g.useState({}),m=g.useMemo(()=>e.flatMap(j=>j.data.map(O=>({...O,source:j.source}))),[e]),h=g.useMemo(()=>Zc({scriptureReferenceColumnName:r,typeColumnName:s,detailsColumnName:i},n),[r,s,i,n]);g.useEffect(()=>{d.includes(pt)?w([{id:pt,desc:!1},{id:rt,desc:!1}]):w([{id:rt,desc:!1}])},[d]);const E=ke.useReactTable({data:m,columns:h,state:{grouping:d,sorting:f,rowSelection:b},onGroupingChange:u,onSortingChange:w,onRowSelectionChange:x,getExpandedRowModel:ke.getExpandedRowModel(),getGroupedRowModel:ke.getGroupedRowModel(),getCoreRowModel:ke.getCoreRowModel(),getSortedRowModel:ke.getSortedRowModel(),getRowId:sa,autoResetExpanded:!1,enableMultiRowSelection:!1,enableSubRowSelection:!1});g.useEffect(()=>{if(l){const j=E.getSelectedRowModel().rowsById,O=Object.keys(j);if(O.length===1){const k=m.find(A=>sa(A)===O[0])||void 0;k&&l(k)}}},[b,m,l,E]);const I=o??Kc,C=s??Us,S=[{label:"No Grouping",value:[]},{label:`Group by ${I}`,value:[rt]},{label:`Group by ${C}`,value:[pt]},{label:`Group by ${I} and ${C}`,value:[rt,pt]},{label:`Group by ${C} and ${I}`,value:[pt,rt]}],v=j=>{u(JSON.parse(j))},_=(j,O)=>{!j.getIsGrouped()&&!j.getIsSelected()&&j.getToggleSelectedHandler()(O)},V=(j,O)=>j.getIsGrouped()?"":N("banded-row",O%2===0?"even":"odd"),U=(j,O,k)=>{if(!((j==null?void 0:j.length)===0||O.depth{v(j)},children:[a.jsx(bt,{className:"tw-mb-1 tw-mt-2",children:a.jsx(Bt,{})}),a.jsx(vt,{position:"item-aligned",children:a.jsx(Ns,{children:S.map(j=>a.jsx(Ae,{value:JSON.stringify(j.value),children:j.label},j.label))})})]}),a.jsxs(Tn,{className:"tw-relative tw-flex tw-flex-col tw-overflow-y-auto tw-p-0",children:[t&&a.jsx(Cn,{children:E.getHeaderGroups().map(j=>a.jsx(Ze,{children:j.headers.filter(O=>O.column.columnDef.header).map(O=>a.jsx(Vt,{colSpan:O.colSpan,className:"top-0 tw-sticky",children:O.isPlaceholder?void 0:a.jsxs("div",{children:[O.column.getCanGroup()?a.jsx(fe,{variant:"ghost",title:`Toggle grouping by ${O.column.columnDef.header}`,onClick:O.column.getToggleGroupingHandler(),type:"button",children:O.column.getIsGrouped()?"🛑":"👊 "}):void 0," ",ke.flexRender(O.column.columnDef.header,O.getContext())]})},O.id))},j.id))}),a.jsx(Rn,{children:E.getRowModel().rows.map((j,O)=>a.jsx(Ze,{"data-state":j.getIsSelected()?"selected":"",className:N(V(j,O)),onClick:k=>_(j,k),children:j.getVisibleCells().map(k=>{if(!(k.getIsPlaceholder()||k.column.columnDef.enableGrouping&&!k.getIsGrouped()&&(k.column.columnDef.id!==pt||!n)))return a.jsx(xt,{className:N(k.column.columnDef.id,"tw-p-[1px]",U(d,j,k)),children:(()=>k.getIsGrouped()?a.jsxs(fe,{variant:"link",onClick:j.getToggleExpandedHandler(),type:"button",children:[j.getIsExpanded()&&a.jsx(ee.ChevronDown,{}),!j.getIsExpanded()&&(c==="ltr"?a.jsx(ee.ChevronRight,{}):a.jsx(ee.ChevronLeft,{}))," ",ke.flexRender(k.column.columnDef.cell,k.getContext())," (",j.subRows.length,")"]}):ke.flexRender(k.column.columnDef.cell,k.getContext()))()},k.id)})},j.id))})]})]})}const Or={[W.getLocalizeKeyForScrollGroupId("undefined")]:"Ø",[W.getLocalizeKeyForScrollGroupId(0)]:"A",[W.getLocalizeKeyForScrollGroupId(1)]:"B",[W.getLocalizeKeyForScrollGroupId(2)]:"C",[W.getLocalizeKeyForScrollGroupId(3)]:"D",[W.getLocalizeKeyForScrollGroupId(4)]:"E",[W.getLocalizeKeyForScrollGroupId(5)]:"F",[W.getLocalizeKeyForScrollGroupId(6)]:"G",[W.getLocalizeKeyForScrollGroupId(7)]:"H",[W.getLocalizeKeyForScrollGroupId(8)]:"I",[W.getLocalizeKeyForScrollGroupId(9)]:"J",[W.getLocalizeKeyForScrollGroupId(10)]:"K",[W.getLocalizeKeyForScrollGroupId(11)]:"L",[W.getLocalizeKeyForScrollGroupId(12)]:"M",[W.getLocalizeKeyForScrollGroupId(13)]:"N",[W.getLocalizeKeyForScrollGroupId(14)]:"O",[W.getLocalizeKeyForScrollGroupId(15)]:"P",[W.getLocalizeKeyForScrollGroupId(16)]:"Q",[W.getLocalizeKeyForScrollGroupId(17)]:"R",[W.getLocalizeKeyForScrollGroupId(18)]:"S",[W.getLocalizeKeyForScrollGroupId(19)]:"T",[W.getLocalizeKeyForScrollGroupId(20)]:"U",[W.getLocalizeKeyForScrollGroupId(21)]:"V",[W.getLocalizeKeyForScrollGroupId(22)]:"W",[W.getLocalizeKeyForScrollGroupId(23)]:"X",[W.getLocalizeKeyForScrollGroupId(24)]:"Y",[W.getLocalizeKeyForScrollGroupId(25)]:"Z"};function td({availableScrollGroupIds:e,scrollGroupId:t,onChangeScrollGroupId:n,localizedStrings:r={}}){const o={...Or,...Object.fromEntries(Object.entries(r).map(([s,i])=>[s,s===i&&s in Or?Or[s]:i]))};return a.jsxs(Dt,{value:`${t}`,onValueChange:s=>n(s==="undefined"?void 0:parseInt(s,10)),children:[a.jsx(bt,{className:"pr-twp tw-w-auto",children:a.jsx(Bt,{placeholder:o[W.getLocalizeKeyForScrollGroupId(t)]??t})}),a.jsx(vt,{style:{zIndex:250},children:e.map(s=>a.jsx(Ae,{value:`${s}`,children:o[W.getLocalizeKeyForScrollGroupId(s)]},`${s}`))})]})}function nd({children:e}){return a.jsx("div",{className:"pr-twp tw-grid",children:e})}function rd({primary:e,secondary:t,children:n,isLoading:r=!1,loadingMessage:o}){return a.jsxs("div",{className:"tw-flex tw-items-center tw-justify-between tw-space-x-4 tw-py-2",children:[a.jsxs("div",{children:[a.jsx("p",{className:"tw-text-sm tw-font-medium tw-leading-none",children:e}),a.jsx("p",{className:"tw-whitespace-normal tw-break-words tw-text-sm tw-text-muted-foreground",children:t})]}),r?a.jsx("p",{className:"tw-text-sm tw-text-muted-foreground",children:o}):a.jsx("div",{children:n})]})}function od({primary:e,secondary:t,includeSeparator:n=!1}){return a.jsxs("div",{className:"tw-space-y-4 tw-py-2",children:[a.jsxs("div",{children:[a.jsx("h3",{className:"tw-text-lg tw-font-medium",children:e}),a.jsx("p",{className:"tw-text-sm tw-text-muted-foreground",children:t})]}),n?a.jsx(lr,{}):""]})}function ad({id:e,className:t,listItems:n,selectedListItems:r,handleSelectListItem:o,createLabel:s}){return a.jsx("div",{id:e,className:t,children:n.map(i=>a.jsxs("div",{className:"tw-m-2 tw-flex tw-items-center",children:[a.jsx(sr,{className:"tw-mr-2 tw-align-middle",checked:r.includes(i),onCheckedChange:l=>o(i,l)}),a.jsx(Ue,{children:s?s(i):i})]},i))})}function sd(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}function id(e){if(e.__esModule)return e;var t=e.default;if(typeof t=="function"){var n=function r(){return this instanceof r?Reflect.construct(t,arguments,this.constructor):t.apply(this,arguments)};n.prototype=t.prototype}else n={};return Object.defineProperty(n,"__esModule",{value:!0}),Object.keys(e).forEach(function(r){var o=Object.getOwnPropertyDescriptor(e,r);Object.defineProperty(n,r,o.get?o:{enumerable:!0,get:function(){return e[r]}})}),n}var vo={},qs={exports:{}};(function(e){function t(n){return n&&n.__esModule?n:{default:n}}e.exports=t,e.exports.__esModule=!0,e.exports.default=e.exports})(qs);var ld=qs.exports,_r={};function xo(e,t){return process.env.NODE_ENV==="production"?()=>null:function(...r){return e(...r)||t(...r)}}function R(){return R=Object.assign?Object.assign.bind():function(e){for(var t=1;t{t[n]=Hs(e[n])}),t}function Qe(e,t,n={clone:!0}){const r=n.clone?R({},e):e;return mt(e)&&mt(t)&&Object.keys(t).forEach(o=>{o!=="__proto__"&&(mt(t[o])&&o in e&&mt(e[o])?r[o]=Qe(e[o],t[o],n):n.clone?r[o]=mt(t[o])?Hs(t[o]):t[o]:r[o]=t[o])}),r}var Wr={exports:{}},zn={exports:{}},ie={};/** @license React v16.13.1 * react-is.production.min.js * * Copyright (c) Facebook, Inc. and its affiliates. * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. - */var ia;function dd(){if(ia)return ie;ia=1;var e=typeof Symbol=="function"&&Symbol.for,t=e?Symbol.for("react.element"):60103,n=e?Symbol.for("react.portal"):60106,r=e?Symbol.for("react.fragment"):60107,o=e?Symbol.for("react.strict_mode"):60108,s=e?Symbol.for("react.profiler"):60114,i=e?Symbol.for("react.provider"):60109,l=e?Symbol.for("react.context"):60110,c=e?Symbol.for("react.async_mode"):60111,d=e?Symbol.for("react.concurrent_mode"):60111,u=e?Symbol.for("react.forward_ref"):60112,f=e?Symbol.for("react.suspense"):60113,w=e?Symbol.for("react.suspense_list"):60120,b=e?Symbol.for("react.memo"):60115,x=e?Symbol.for("react.lazy"):60116,m=e?Symbol.for("react.block"):60121,h=e?Symbol.for("react.fundamental"):60117,E=e?Symbol.for("react.responder"):60118,I=e?Symbol.for("react.scope"):60119;function C(v){if(typeof v=="object"&&v!==null){var _=v.$$typeof;switch(_){case t:switch(v=v.type,v){case c:case d:case r:case s:case o:case f:return v;default:switch(v=v&&v.$$typeof,v){case l:case u:case x:case b:case i:return v;default:return _}}case n:return _}}}function S(v){return C(v)===d}return ie.AsyncMode=c,ie.ConcurrentMode=d,ie.ContextConsumer=l,ie.ContextProvider=i,ie.Element=t,ie.ForwardRef=u,ie.Fragment=r,ie.Lazy=x,ie.Memo=b,ie.Portal=n,ie.Profiler=s,ie.StrictMode=o,ie.Suspense=f,ie.isAsyncMode=function(v){return S(v)||C(v)===c},ie.isConcurrentMode=S,ie.isContextConsumer=function(v){return C(v)===l},ie.isContextProvider=function(v){return C(v)===i},ie.isElement=function(v){return typeof v=="object"&&v!==null&&v.$$typeof===t},ie.isForwardRef=function(v){return C(v)===u},ie.isFragment=function(v){return C(v)===r},ie.isLazy=function(v){return C(v)===x},ie.isMemo=function(v){return C(v)===b},ie.isPortal=function(v){return C(v)===n},ie.isProfiler=function(v){return C(v)===s},ie.isStrictMode=function(v){return C(v)===o},ie.isSuspense=function(v){return C(v)===f},ie.isValidElementType=function(v){return typeof v=="string"||typeof v=="function"||v===r||v===d||v===s||v===o||v===f||v===w||typeof v=="object"&&v!==null&&(v.$$typeof===x||v.$$typeof===b||v.$$typeof===i||v.$$typeof===l||v.$$typeof===u||v.$$typeof===h||v.$$typeof===E||v.$$typeof===I||v.$$typeof===m)},ie.typeOf=C,ie}var le={};/** @license React v16.13.1 + */var ia;function cd(){if(ia)return ie;ia=1;var e=typeof Symbol=="function"&&Symbol.for,t=e?Symbol.for("react.element"):60103,n=e?Symbol.for("react.portal"):60106,r=e?Symbol.for("react.fragment"):60107,o=e?Symbol.for("react.strict_mode"):60108,s=e?Symbol.for("react.profiler"):60114,i=e?Symbol.for("react.provider"):60109,l=e?Symbol.for("react.context"):60110,c=e?Symbol.for("react.async_mode"):60111,d=e?Symbol.for("react.concurrent_mode"):60111,u=e?Symbol.for("react.forward_ref"):60112,f=e?Symbol.for("react.suspense"):60113,w=e?Symbol.for("react.suspense_list"):60120,b=e?Symbol.for("react.memo"):60115,x=e?Symbol.for("react.lazy"):60116,m=e?Symbol.for("react.block"):60121,h=e?Symbol.for("react.fundamental"):60117,E=e?Symbol.for("react.responder"):60118,I=e?Symbol.for("react.scope"):60119;function C(v){if(typeof v=="object"&&v!==null){var _=v.$$typeof;switch(_){case t:switch(v=v.type,v){case c:case d:case r:case s:case o:case f:return v;default:switch(v=v&&v.$$typeof,v){case l:case u:case x:case b:case i:return v;default:return _}}case n:return _}}}function S(v){return C(v)===d}return ie.AsyncMode=c,ie.ConcurrentMode=d,ie.ContextConsumer=l,ie.ContextProvider=i,ie.Element=t,ie.ForwardRef=u,ie.Fragment=r,ie.Lazy=x,ie.Memo=b,ie.Portal=n,ie.Profiler=s,ie.StrictMode=o,ie.Suspense=f,ie.isAsyncMode=function(v){return S(v)||C(v)===c},ie.isConcurrentMode=S,ie.isContextConsumer=function(v){return C(v)===l},ie.isContextProvider=function(v){return C(v)===i},ie.isElement=function(v){return typeof v=="object"&&v!==null&&v.$$typeof===t},ie.isForwardRef=function(v){return C(v)===u},ie.isFragment=function(v){return C(v)===r},ie.isLazy=function(v){return C(v)===x},ie.isMemo=function(v){return C(v)===b},ie.isPortal=function(v){return C(v)===n},ie.isProfiler=function(v){return C(v)===s},ie.isStrictMode=function(v){return C(v)===o},ie.isSuspense=function(v){return C(v)===f},ie.isValidElementType=function(v){return typeof v=="string"||typeof v=="function"||v===r||v===d||v===s||v===o||v===f||v===w||typeof v=="object"&&v!==null&&(v.$$typeof===x||v.$$typeof===b||v.$$typeof===i||v.$$typeof===l||v.$$typeof===u||v.$$typeof===h||v.$$typeof===E||v.$$typeof===I||v.$$typeof===m)},ie.typeOf=C,ie}var le={};/** @license React v16.13.1 * react-is.development.js * * Copyright (c) Facebook, Inc. and its affiliates. * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. - */var la;function ud(){return la||(la=1,process.env.NODE_ENV!=="production"&&function(){var e=typeof Symbol=="function"&&Symbol.for,t=e?Symbol.for("react.element"):60103,n=e?Symbol.for("react.portal"):60106,r=e?Symbol.for("react.fragment"):60107,o=e?Symbol.for("react.strict_mode"):60108,s=e?Symbol.for("react.profiler"):60114,i=e?Symbol.for("react.provider"):60109,l=e?Symbol.for("react.context"):60110,c=e?Symbol.for("react.async_mode"):60111,d=e?Symbol.for("react.concurrent_mode"):60111,u=e?Symbol.for("react.forward_ref"):60112,f=e?Symbol.for("react.suspense"):60113,w=e?Symbol.for("react.suspense_list"):60120,b=e?Symbol.for("react.memo"):60115,x=e?Symbol.for("react.lazy"):60116,m=e?Symbol.for("react.block"):60121,h=e?Symbol.for("react.fundamental"):60117,E=e?Symbol.for("react.responder"):60118,I=e?Symbol.for("react.scope"):60119;function C(P){return typeof P=="string"||typeof P=="function"||P===r||P===d||P===s||P===o||P===f||P===w||typeof P=="object"&&P!==null&&(P.$$typeof===x||P.$$typeof===b||P.$$typeof===i||P.$$typeof===l||P.$$typeof===u||P.$$typeof===h||P.$$typeof===E||P.$$typeof===I||P.$$typeof===m)}function S(P){if(typeof P=="object"&&P!==null){var xe=P.$$typeof;switch(xe){case t:var A=P.type;switch(A){case c:case d:case r:case s:case o:case f:return A;default:var ve=A&&A.$$typeof;switch(ve){case l:case u:case x:case b:case i:return ve;default:return xe}}case n:return xe}}}var v=c,_=d,V=l,U=i,j=t,O=u,k=r,D=x,M=b,J=n,X=s,F=o,te=f,se=!1;function oe(P){return se||(se=!0,console.warn("The ReactIs.isAsyncMode() alias has been deprecated, and will be removed in React 17+. Update your code to use ReactIs.isConcurrentMode() instead. It has the exact same API.")),y(P)||S(P)===c}function y(P){return S(P)===d}function T(P){return S(P)===l}function z(P){return S(P)===i}function L(P){return typeof P=="object"&&P!==null&&P.$$typeof===t}function B(P){return S(P)===u}function Y(P){return S(P)===r}function q(P){return S(P)===x}function H(P){return S(P)===b}function G(P){return S(P)===n}function K(P){return S(P)===s}function Z(P){return S(P)===o}function ue(P){return S(P)===f}le.AsyncMode=v,le.ConcurrentMode=_,le.ContextConsumer=V,le.ContextProvider=U,le.Element=j,le.ForwardRef=O,le.Fragment=k,le.Lazy=D,le.Memo=M,le.Portal=J,le.Profiler=X,le.StrictMode=F,le.Suspense=te,le.isAsyncMode=oe,le.isConcurrentMode=y,le.isContextConsumer=T,le.isContextProvider=z,le.isElement=L,le.isForwardRef=B,le.isFragment=Y,le.isLazy=q,le.isMemo=H,le.isPortal=G,le.isProfiler=K,le.isStrictMode=Z,le.isSuspense=ue,le.isValidElementType=C,le.typeOf=S}()),le}var ca;function Ys(){return ca||(ca=1,process.env.NODE_ENV==="production"?zn.exports=dd():zn.exports=ud()),zn.exports}/* + */var la;function dd(){return la||(la=1,process.env.NODE_ENV!=="production"&&function(){var e=typeof Symbol=="function"&&Symbol.for,t=e?Symbol.for("react.element"):60103,n=e?Symbol.for("react.portal"):60106,r=e?Symbol.for("react.fragment"):60107,o=e?Symbol.for("react.strict_mode"):60108,s=e?Symbol.for("react.profiler"):60114,i=e?Symbol.for("react.provider"):60109,l=e?Symbol.for("react.context"):60110,c=e?Symbol.for("react.async_mode"):60111,d=e?Symbol.for("react.concurrent_mode"):60111,u=e?Symbol.for("react.forward_ref"):60112,f=e?Symbol.for("react.suspense"):60113,w=e?Symbol.for("react.suspense_list"):60120,b=e?Symbol.for("react.memo"):60115,x=e?Symbol.for("react.lazy"):60116,m=e?Symbol.for("react.block"):60121,h=e?Symbol.for("react.fundamental"):60117,E=e?Symbol.for("react.responder"):60118,I=e?Symbol.for("react.scope"):60119;function C(P){return typeof P=="string"||typeof P=="function"||P===r||P===d||P===s||P===o||P===f||P===w||typeof P=="object"&&P!==null&&(P.$$typeof===x||P.$$typeof===b||P.$$typeof===i||P.$$typeof===l||P.$$typeof===u||P.$$typeof===h||P.$$typeof===E||P.$$typeof===I||P.$$typeof===m)}function S(P){if(typeof P=="object"&&P!==null){var xe=P.$$typeof;switch(xe){case t:var D=P.type;switch(D){case c:case d:case r:case s:case o:case f:return D;default:var ve=D&&D.$$typeof;switch(ve){case l:case u:case x:case b:case i:return ve;default:return xe}}case n:return xe}}}var v=c,_=d,V=l,U=i,j=t,O=u,k=r,A=x,M=b,J=n,Y=s,F=o,te=f,se=!1;function oe(P){return se||(se=!0,console.warn("The ReactIs.isAsyncMode() alias has been deprecated, and will be removed in React 17+. Update your code to use ReactIs.isConcurrentMode() instead. It has the exact same API.")),y(P)||S(P)===c}function y(P){return S(P)===d}function T(P){return S(P)===l}function z(P){return S(P)===i}function L(P){return typeof P=="object"&&P!==null&&P.$$typeof===t}function B(P){return S(P)===u}function X(P){return S(P)===r}function q(P){return S(P)===x}function H(P){return S(P)===b}function G(P){return S(P)===n}function K(P){return S(P)===s}function Z(P){return S(P)===o}function ue(P){return S(P)===f}le.AsyncMode=v,le.ConcurrentMode=_,le.ContextConsumer=V,le.ContextProvider=U,le.Element=j,le.ForwardRef=O,le.Fragment=k,le.Lazy=A,le.Memo=M,le.Portal=J,le.Profiler=Y,le.StrictMode=F,le.Suspense=te,le.isAsyncMode=oe,le.isConcurrentMode=y,le.isContextConsumer=T,le.isContextProvider=z,le.isElement=L,le.isForwardRef=B,le.isFragment=X,le.isLazy=q,le.isMemo=H,le.isPortal=G,le.isProfiler=K,le.isStrictMode=Z,le.isSuspense=ue,le.isValidElementType=C,le.typeOf=S}()),le}var ca;function Xs(){return ca||(ca=1,process.env.NODE_ENV==="production"?zn.exports=cd():zn.exports=dd()),zn.exports}/* object-assign (c) Sindre Sorhus @license MIT -*/var Pr,da;function pd(){if(da)return Pr;da=1;var e=Object.getOwnPropertySymbols,t=Object.prototype.hasOwnProperty,n=Object.prototype.propertyIsEnumerable;function r(s){if(s==null)throw new TypeError("Object.assign cannot be called with null or undefined");return Object(s)}function o(){try{if(!Object.assign)return!1;var s=new String("abc");if(s[5]="de",Object.getOwnPropertyNames(s)[0]==="5")return!1;for(var i={},l=0;l<10;l++)i["_"+String.fromCharCode(l)]=l;var c=Object.getOwnPropertyNames(i).map(function(u){return i[u]});if(c.join("")!=="0123456789")return!1;var d={};return"abcdefghijklmnopqrst".split("").forEach(function(u){d[u]=u}),Object.keys(Object.assign({},d)).join("")==="abcdefghijklmnopqrst"}catch{return!1}}return Pr=o()?Object.assign:function(s,i){for(var l,c=r(s),d,u=1;u1?s("Invalid arguments supplied to oneOf, expected an array, got "+arguments.length+" arguments. A common mistake is to write oneOf(x, y, z) instead of oneOf([x, y, z])."):s("Invalid argument supplied to oneOf, expected an array.")),i;function T(z,L,B,Y,q){for(var H=z[L],G=0;G0?", expected one of type ["+K.join(", ")+"]":"";return new m("Invalid "+H+" `"+G+"` supplied to "+("`"+q+"`"+xe+"."))}return h(L)}function O(){function y(T,z,L,B,Y){return J(T[z])?null:new m("Invalid "+B+" `"+Y+"` supplied to "+("`"+L+"`, expected a ReactNode."))}return h(y)}function k(y,T,z,L,B){return new m((y||"React class")+": "+T+" type `"+z+"."+L+"` is invalid; it must be a function, usually from the `prop-types` package, but received `"+B+"`.")}function D(y){function T(z,L,B,Y,q){var H=z[L],G=F(H);if(G!=="object")return new m("Invalid "+Y+" `"+q+"` of type `"+G+"` "+("supplied to `"+B+"`, expected `object`."));for(var K in y){var Z=y[K];if(typeof Z!="function")return k(B,Y,q,K,te(Z));var ue=Z(H,K,B,Y,q+"."+K,n);if(ue)return ue}return null}return h(T)}function M(y){function T(z,L,B,Y,q){var H=z[L],G=F(H);if(G!=="object")return new m("Invalid "+Y+" `"+q+"` of type `"+G+"` "+("supplied to `"+B+"`, expected `object`."));var K=t({},z[L],y);for(var Z in K){var ue=y[Z];if(r(y,Z)&&typeof ue!="function")return k(B,Y,q,Z,te(ue));if(!ue)return new m("Invalid "+Y+" `"+q+"` key `"+Z+"` supplied to `"+B+"`.\nBad object: "+JSON.stringify(z[L],null," ")+` -Valid keys: `+JSON.stringify(Object.keys(y),null," "));var P=ue(H,Z,B,Y,q+"."+Z,n);if(P)return P}return null}return h(T)}function J(y){switch(typeof y){case"number":case"string":case"undefined":return!0;case"boolean":return!y;case"object":if(Array.isArray(y))return y.every(J);if(y===null||l(y))return!0;var T=f(y);if(T){var z=T.call(y),L;if(T!==y.entries){for(;!(L=z.next()).done;)if(!J(L.value))return!1}else for(;!(L=z.next()).done;){var B=L.value;if(B&&!J(B[1]))return!1}}else return!1;return!0;default:return!1}}function X(y,T){return y==="symbol"?!0:T?T["@@toStringTag"]==="Symbol"||typeof Symbol=="function"&&T instanceof Symbol:!1}function F(y){var T=typeof y;return Array.isArray(y)?"array":y instanceof RegExp?"object":X(T,y)?"symbol":T}function te(y){if(typeof y>"u"||y===null)return""+y;var T=F(y);if(T==="object"){if(y instanceof Date)return"date";if(y instanceof RegExp)return"regexp"}return T}function se(y){var T=te(y);switch(T){case"array":case"object":return"an "+T;case"boolean":case"date":case"regexp":return"a "+T;default:return T}}function oe(y){return!y.constructor||!y.constructor.name?w:y.constructor.name}return b.checkPropTypes=o,b.resetWarningCache=o.resetWarningCache,b.PropTypes=b,b},Dr}var Ar,ma;function md(){if(ma)return Ar;ma=1;var e=yo();function t(){}function n(){}return n.resetWarningCache=t,Ar=function(){function r(i,l,c,d,u,f){if(f!==e){var w=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types");throw w.name="Invariant Violation",w}}r.isRequired=r;function o(){return r}var s={array:r,bigint:r,bool:r,func:r,number:r,object:r,string:r,symbol:r,any:r,arrayOf:o,element:r,elementType:r,instanceOf:o,node:r,objectOf:o,oneOf:o,oneOfType:o,shape:o,exact:o,checkPropTypes:n,resetWarningCache:t};return s.PropTypes=s,s},Ar}if(process.env.NODE_ENV!=="production"){var hd=Ys(),gd=!0;Wr.exports=fd()(hd.isElement,gd)}else Wr.exports=md()();var bd=Wr.exports;const p=id(bd);function vd(e){const{prototype:t={}}=e;return!!t.isReactComponent}function Ws(e,t,n,r,o){const s=e[t],i=o||t;if(s==null||typeof window>"u")return null;let l;const c=s.type;return typeof c=="function"&&!vd(c)&&(l="Did you accidentally use a plain function component for an element instead?"),l!==void 0?new Error(`Invalid ${r} \`${i}\` supplied to \`${n}\`. Expected an element that can hold a ref. ${l} For more information see https://mui.com/r/caveat-with-refs-guide`):null}const Ks=xo(p.element,Ws);Ks.isRequired=xo(p.element.isRequired,Ws);const Js=Ks,xd="exact-prop: ​";function yd(e){return process.env.NODE_ENV==="production"?e:R({},e,{[xd]:t=>{const n=Object.keys(t).filter(r=>!e.hasOwnProperty(r));return n.length>0?new Error(`The following props are not supported: ${n.map(r=>`\`${r}\``).join(", ")}. Please remove them.`):null}})}function zt(e){let t="https://mui.com/production-error/?code="+e;for(let n=1;n1?s("Invalid arguments supplied to oneOf, expected an array, got "+arguments.length+" arguments. A common mistake is to write oneOf(x, y, z) instead of oneOf([x, y, z])."):s("Invalid argument supplied to oneOf, expected an array.")),i;function T(z,L,B,X,q){for(var H=z[L],G=0;G0?", expected one of type ["+K.join(", ")+"]":"";return new m("Invalid "+H+" `"+G+"` supplied to "+("`"+q+"`"+xe+"."))}return h(L)}function O(){function y(T,z,L,B,X){return J(T[z])?null:new m("Invalid "+B+" `"+X+"` supplied to "+("`"+L+"`, expected a ReactNode."))}return h(y)}function k(y,T,z,L,B){return new m((y||"React class")+": "+T+" type `"+z+"."+L+"` is invalid; it must be a function, usually from the `prop-types` package, but received `"+B+"`.")}function A(y){function T(z,L,B,X,q){var H=z[L],G=F(H);if(G!=="object")return new m("Invalid "+X+" `"+q+"` of type `"+G+"` "+("supplied to `"+B+"`, expected `object`."));for(var K in y){var Z=y[K];if(typeof Z!="function")return k(B,X,q,K,te(Z));var ue=Z(H,K,B,X,q+"."+K,n);if(ue)return ue}return null}return h(T)}function M(y){function T(z,L,B,X,q){var H=z[L],G=F(H);if(G!=="object")return new m("Invalid "+X+" `"+q+"` of type `"+G+"` "+("supplied to `"+B+"`, expected `object`."));var K=t({},z[L],y);for(var Z in K){var ue=y[Z];if(r(y,Z)&&typeof ue!="function")return k(B,X,q,Z,te(ue));if(!ue)return new m("Invalid "+X+" `"+q+"` key `"+Z+"` supplied to `"+B+"`.\nBad object: "+JSON.stringify(z[L],null," ")+` +Valid keys: `+JSON.stringify(Object.keys(y),null," "));var P=ue(H,Z,B,X,q+"."+Z,n);if(P)return P}return null}return h(T)}function J(y){switch(typeof y){case"number":case"string":case"undefined":return!0;case"boolean":return!y;case"object":if(Array.isArray(y))return y.every(J);if(y===null||l(y))return!0;var T=f(y);if(T){var z=T.call(y),L;if(T!==y.entries){for(;!(L=z.next()).done;)if(!J(L.value))return!1}else for(;!(L=z.next()).done;){var B=L.value;if(B&&!J(B[1]))return!1}}else return!1;return!0;default:return!1}}function Y(y,T){return y==="symbol"?!0:T?T["@@toStringTag"]==="Symbol"||typeof Symbol=="function"&&T instanceof Symbol:!1}function F(y){var T=typeof y;return Array.isArray(y)?"array":y instanceof RegExp?"object":Y(T,y)?"symbol":T}function te(y){if(typeof y>"u"||y===null)return""+y;var T=F(y);if(T==="object"){if(y instanceof Date)return"date";if(y instanceof RegExp)return"regexp"}return T}function se(y){var T=te(y);switch(T){case"array":case"object":return"an "+T;case"boolean":case"date":case"regexp":return"a "+T;default:return T}}function oe(y){return!y.constructor||!y.constructor.name?w:y.constructor.name}return b.checkPropTypes=o,b.resetWarningCache=o.resetWarningCache,b.PropTypes=b,b},Ar}var Dr,ma;function fd(){if(ma)return Dr;ma=1;var e=yo();function t(){}function n(){}return n.resetWarningCache=t,Dr=function(){function r(i,l,c,d,u,f){if(f!==e){var w=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types");throw w.name="Invariant Violation",w}}r.isRequired=r;function o(){return r}var s={array:r,bigint:r,bool:r,func:r,number:r,object:r,string:r,symbol:r,any:r,arrayOf:o,element:r,elementType:r,instanceOf:o,node:r,objectOf:o,oneOf:o,oneOfType:o,shape:o,exact:o,checkPropTypes:n,resetWarningCache:t};return s.PropTypes=s,s},Dr}if(process.env.NODE_ENV!=="production"){var md=Xs(),hd=!0;Wr.exports=wd()(md.isElement,hd)}else Wr.exports=fd()();var gd=Wr.exports;const p=sd(gd);function bd(e){const{prototype:t={}}=e;return!!t.isReactComponent}function Ws(e,t,n,r,o){const s=e[t],i=o||t;if(s==null||typeof window>"u")return null;let l;const c=s.type;return typeof c=="function"&&!bd(c)&&(l="Did you accidentally use a plain function component for an element instead?"),l!==void 0?new Error(`Invalid ${r} \`${i}\` supplied to \`${n}\`. Expected an element that can hold a ref. ${l} For more information see https://mui.com/r/caveat-with-refs-guide`):null}const Ks=xo(p.element,Ws);Ks.isRequired=xo(p.element.isRequired,Ws);const Js=Ks,vd="exact-prop: ​";function xd(e){return process.env.NODE_ENV==="production"?e:R({},e,{[vd]:t=>{const n=Object.keys(t).filter(r=>!e.hasOwnProperty(r));return n.length>0?new Error(`The following props are not supported: ${n.map(r=>`\`${r}\``).join(", ")}. Please remove them.`):null}})}function zt(e){let t="https://mui.com/production-error/?code="+e;for(let n=1;nn==null?t:function(...o){t.apply(this,o),n.apply(this,o)},()=>{})}function Rd(e,t=166){let n;function r(...o){const s=()=>{e.apply(this,o)};clearTimeout(n),n=setTimeout(s,t)}return r.clear=()=>{clearTimeout(n)},r}function Od(e,t){return process.env.NODE_ENV==="production"?()=>null:(n,r,o,s,i)=>{const l=o||"<>",c=i||r;return typeof n[r]<"u"?new Error(`The ${s} \`${c}\` of \`${l}\` is deprecated. ${t}`):null}}function _d(e,t){var n,r;return $.isValidElement(e)&&t.indexOf((n=e.type.muiName)!=null?n:(r=e.type)==null||(r=r._payload)==null||(r=r.value)==null?void 0:r.muiName)!==-1}function Kn(e){return e&&e.ownerDocument||document}function Pd(e){return Kn(e).defaultView||window}function Id(e,t){if(process.env.NODE_ENV==="production")return()=>null;const n=t?R({},t.propTypes):null;return o=>(s,i,l,c,d,...u)=>{const f=d||i,w=n==null?void 0:n[f];if(w){const b=w(s,i,l,c,d,...u);if(b)return b}return typeof s[i]<"u"&&!s[o]?new Error(`The prop \`${f}\` of \`${e}\` can only be used together with the \`${o}\` prop.`):null}}function Jn(e,t){typeof e=="function"?e(t):e&&(e.current=t)}const Md=typeof window<"u"?$.useLayoutEffect:$.useEffect,Lt=Md;let xa=0;function $d(e){const[t,n]=$.useState(e),r=e||t;return $.useEffect(()=>{t==null&&(xa+=1,n(`mui-${xa}`))},[t]),r}const ya=$["useId".toString()];function ei(e){if(ya!==void 0){const t=ya();return e??t}return $d(e)}function Dd(e,t,n,r,o){if(process.env.NODE_ENV==="production")return null;const s=o||t;return typeof e[t]<"u"?new Error(`The prop \`${s}\` is not supported. Please remove it.`):null}function ti({controlled:e,default:t,name:n,state:r="value"}){const{current:o}=$.useRef(e!==void 0),[s,i]=$.useState(t),l=o?e:s;if(process.env.NODE_ENV!=="production"){$.useEffect(()=>{o!==(e!==void 0)&&console.error([`MUI: A component is changing the ${o?"":"un"}controlled ${r} state of ${n} to be ${o?"un":""}controlled.`,"Elements should not switch from uncontrolled to controlled (or vice versa).",`Decide between using a controlled or uncontrolled ${n} element for the lifetime of the component.`,"The nature of the state is determined during the first render. It's considered controlled if the value is not `undefined`.","More info: https://fb.me/react-controlled-components"].join(` + */var ga;function Nd(){return ga||(ga=1,process.env.NODE_ENV!=="production"&&function(){var e=Symbol.for("react.element"),t=Symbol.for("react.portal"),n=Symbol.for("react.fragment"),r=Symbol.for("react.strict_mode"),o=Symbol.for("react.profiler"),s=Symbol.for("react.provider"),i=Symbol.for("react.context"),l=Symbol.for("react.server_context"),c=Symbol.for("react.forward_ref"),d=Symbol.for("react.suspense"),u=Symbol.for("react.suspense_list"),f=Symbol.for("react.memo"),w=Symbol.for("react.lazy"),b=Symbol.for("react.offscreen"),x=!1,m=!1,h=!1,E=!1,I=!1,C;C=Symbol.for("react.module.reference");function S(D){return!!(typeof D=="string"||typeof D=="function"||D===n||D===o||I||D===r||D===d||D===u||E||D===b||x||m||h||typeof D=="object"&&D!==null&&(D.$$typeof===w||D.$$typeof===f||D.$$typeof===s||D.$$typeof===i||D.$$typeof===c||D.$$typeof===C||D.getModuleId!==void 0))}function v(D){if(typeof D=="object"&&D!==null){var ve=D.$$typeof;switch(ve){case e:var Fe=D.type;switch(Fe){case n:case o:case r:case d:case u:return Fe;default:var lt=Fe&&Fe.$$typeof;switch(lt){case l:case i:case c:case w:case f:case s:return lt;default:return ve}}case t:return ve}}}var _=i,V=s,U=e,j=c,O=n,k=w,A=f,M=t,J=o,Y=r,F=d,te=u,se=!1,oe=!1;function y(D){return se||(se=!0,console.warn("The ReactIs.isAsyncMode() alias has been deprecated, and will be removed in React 18+.")),!1}function T(D){return oe||(oe=!0,console.warn("The ReactIs.isConcurrentMode() alias has been deprecated, and will be removed in React 18+.")),!1}function z(D){return v(D)===i}function L(D){return v(D)===s}function B(D){return typeof D=="object"&&D!==null&&D.$$typeof===e}function X(D){return v(D)===c}function q(D){return v(D)===n}function H(D){return v(D)===w}function G(D){return v(D)===f}function K(D){return v(D)===t}function Z(D){return v(D)===o}function ue(D){return v(D)===r}function P(D){return v(D)===d}function xe(D){return v(D)===u}de.ContextConsumer=_,de.ContextProvider=V,de.Element=U,de.ForwardRef=j,de.Fragment=O,de.Lazy=k,de.Memo=A,de.Portal=M,de.Profiler=J,de.StrictMode=Y,de.Suspense=F,de.SuspenseList=te,de.isAsyncMode=y,de.isConcurrentMode=T,de.isContextConsumer=z,de.isContextProvider=L,de.isElement=B,de.isForwardRef=X,de.isFragment=q,de.isLazy=H,de.isMemo=G,de.isPortal=K,de.isProfiler=Z,de.isStrictMode=ue,de.isSuspense=P,de.isSuspenseList=xe,de.isValidElementType=S,de.typeOf=v}()),de}process.env.NODE_ENV==="production"?Kr.exports=yd():Kr.exports=Nd();var ba=Kr.exports;const kd=/^\s*function(?:\s|\s*\/\*.*\*\/\s*)+([^(\s/]*)\s*/;function Sd(e){const t=`${e}`.match(kd);return t&&t[1]||""}function Zs(e,t=""){return e.displayName||e.name||Sd(e)||t}function va(e,t,n){const r=Zs(t);return e.displayName||(r!==""?`${n}(${r})`:n)}function Ed(e){if(e!=null){if(typeof e=="string")return e;if(typeof e=="function")return Zs(e,"Component");if(typeof e=="object")switch(e.$$typeof){case ba.ForwardRef:return va(e,e.render,"ForwardRef");case ba.Memo:return va(e,e.type,"memo");default:return}}}function vn(e,t,n,r,o){if(process.env.NODE_ENV==="production")return null;const s=e[t],i=o||t;return s==null?null:s&&s.nodeType!==1?new Error(`Invalid ${r} \`${i}\` supplied to \`${n}\`. Expected an HTMLElement.`):null}const jd=p.oneOfType([p.func,p.object]),Qs=jd;function Ye(e){if(typeof e!="string")throw new Error(process.env.NODE_ENV!=="production"?"MUI: `capitalize(string)` expects a string argument.":zt(7));return e.charAt(0).toUpperCase()+e.slice(1)}function Td(...e){return e.reduce((t,n)=>n==null?t:function(...o){t.apply(this,o),n.apply(this,o)},()=>{})}function Cd(e,t=166){let n;function r(...o){const s=()=>{e.apply(this,o)};clearTimeout(n),n=setTimeout(s,t)}return r.clear=()=>{clearTimeout(n)},r}function Rd(e,t){return process.env.NODE_ENV==="production"?()=>null:(n,r,o,s,i)=>{const l=o||"<>",c=i||r;return typeof n[r]<"u"?new Error(`The ${s} \`${c}\` of \`${l}\` is deprecated. ${t}`):null}}function Od(e,t){var n,r;return $.isValidElement(e)&&t.indexOf((n=e.type.muiName)!=null?n:(r=e.type)==null||(r=r._payload)==null||(r=r.value)==null?void 0:r.muiName)!==-1}function Kn(e){return e&&e.ownerDocument||document}function _d(e){return Kn(e).defaultView||window}function Pd(e,t){if(process.env.NODE_ENV==="production")return()=>null;const n=t?R({},t.propTypes):null;return o=>(s,i,l,c,d,...u)=>{const f=d||i,w=n==null?void 0:n[f];if(w){const b=w(s,i,l,c,d,...u);if(b)return b}return typeof s[i]<"u"&&!s[o]?new Error(`The prop \`${f}\` of \`${e}\` can only be used together with the \`${o}\` prop.`):null}}function Jn(e,t){typeof e=="function"?e(t):e&&(e.current=t)}const Id=typeof window<"u"?$.useLayoutEffect:$.useEffect,Lt=Id;let xa=0;function Md(e){const[t,n]=$.useState(e),r=e||t;return $.useEffect(()=>{t==null&&(xa+=1,n(`mui-${xa}`))},[t]),r}const ya=$["useId".toString()];function ei(e){if(ya!==void 0){const t=ya();return e??t}return Md(e)}function $d(e,t,n,r,o){if(process.env.NODE_ENV==="production")return null;const s=o||t;return typeof e[t]<"u"?new Error(`The prop \`${s}\` is not supported. Please remove it.`):null}function ti({controlled:e,default:t,name:n,state:r="value"}){const{current:o}=$.useRef(e!==void 0),[s,i]=$.useState(t),l=o?e:s;if(process.env.NODE_ENV!=="production"){$.useEffect(()=>{o!==(e!==void 0)&&console.error([`MUI: A component is changing the ${o?"":"un"}controlled ${r} state of ${n} to be ${o?"un":""}controlled.`,"Elements should not switch from uncontrolled to controlled (or vice versa).",`Decide between using a controlled or uncontrolled ${n} element for the lifetime of the component.`,"The nature of the state is determined during the first render. It's considered controlled if the value is not `undefined`.","More info: https://fb.me/react-controlled-components"].join(` `))},[r,n,e]);const{current:d}=$.useRef(t);$.useEffect(()=>{!o&&d!==t&&console.error([`MUI: A component is changing the default ${r} state of an uncontrolled ${n} after being initialized. To suppress this warning opt to use a controlled ${n}.`].join(` -`))},[JSON.stringify(t)])}const c=$.useCallback(d=>{o||i(d)},[]);return[l,c]}function Jr(e){const t=$.useRef(e);return Lt(()=>{t.current=e}),$.useRef((...n)=>(0,t.current)(...n)).current}function yt(...e){return $.useMemo(()=>e.every(t=>t==null)?null:t=>{e.forEach(n=>{Jn(n,t)})},e)}const Na={};function Ad(e,t){const n=$.useRef(Na);return n.current===Na&&(n.current=e(t)),n}const Bd=[];function Vd(e){$.useEffect(e,Bd)}class On{constructor(){this.currentId=null,this.clear=()=>{this.currentId!==null&&(clearTimeout(this.currentId),this.currentId=null)},this.disposeEffect=()=>this.clear}static create(){return new On}start(t,n){this.clear(),this.currentId=setTimeout(()=>{this.currentId=null,n()},t)}}function cn(){const e=Ad(On.create).current;return Vd(e.disposeEffect),e}let dr=!0,Zr=!1;const zd=new On,Ld={text:!0,search:!0,url:!0,tel:!0,email:!0,password:!0,number:!0,date:!0,month:!0,week:!0,time:!0,datetime:!0,"datetime-local":!0};function Fd(e){const{type:t,tagName:n}=e;return!!(n==="INPUT"&&Ld[t]&&!e.readOnly||n==="TEXTAREA"&&!e.readOnly||e.isContentEditable)}function Gd(e){e.metaKey||e.altKey||e.ctrlKey||(dr=!0)}function Br(){dr=!1}function Ud(){this.visibilityState==="hidden"&&Zr&&(dr=!0)}function qd(e){e.addEventListener("keydown",Gd,!0),e.addEventListener("mousedown",Br,!0),e.addEventListener("pointerdown",Br,!0),e.addEventListener("touchstart",Br,!0),e.addEventListener("visibilitychange",Ud,!0)}function Hd(e){const{target:t}=e;try{return t.matches(":focus-visible")}catch{}return dr||Fd(t)}function ni(){const e=$.useCallback(o=>{o!=null&&qd(o.ownerDocument)},[]),t=$.useRef(!1);function n(){return t.current?(Zr=!0,zd.start(100,()=>{Zr=!1}),t.current=!1,!0):!1}function r(o){return Hd(o)?(t.current=!0,!0):!1}return{isFocusVisibleRef:t,onFocus:r,onBlur:n,ref:e}}function ri(e,t){const n=R({},t);return Object.keys(e).forEach(r=>{if(r.toString().match(/^(components|slots)$/))n[r]=R({},e[r],n[r]);else if(r.toString().match(/^(componentsProps|slotProps)$/)){const o=e[r]||{},s=t[r];n[r]={},!s||!Object.keys(s)?n[r]=o:!o||!Object.keys(o)?n[r]=s:(n[r]=R({},s),Object.keys(o).forEach(i=>{n[r][i]=ri(o[i],s[i])}))}else n[r]===void 0&&(n[r]=e[r])}),n}function No(e,t,n=void 0){const r={};return Object.keys(e).forEach(o=>{r[o]=e[o].reduce((s,i)=>{if(i){const l=t(i);l!==""&&s.push(l),n&&n[i]&&s.push(n[i])}return s},[]).join(" ")}),r}const ka=e=>e,Yd=()=>{let e=ka;return{configure(t){e=t},generate(t){return e(t)},reset(){e=ka}}},Xd=Yd(),oi=Xd,ai={active:"active",checked:"checked",completed:"completed",disabled:"disabled",error:"error",expanded:"expanded",focused:"focused",focusVisible:"focusVisible",open:"open",readOnly:"readOnly",required:"required",selected:"selected"};function ur(e,t,n="Mui"){const r=ai[t];return r?`${n}-${r}`:`${oi.generate(e)}-${t}`}function si(e,t,n="Mui"){const r={};return t.forEach(o=>{r[o]=ur(e,o,n)}),r}function Wd(e,t=Number.MIN_SAFE_INTEGER,n=Number.MAX_SAFE_INTEGER){return Math.max(t,Math.min(e,n))}function ye(e,t){if(e==null)return{};var n={},r=Object.keys(e),o,s;for(s=0;s=0)&&(n[o]=e[o]);return n}const Kd=["values","unit","step"],Jd=e=>{const t=Object.keys(e).map(n=>({key:n,val:e[n]}))||[];return t.sort((n,r)=>n.val-r.val),t.reduce((n,r)=>R({},n,{[r.key]:r.val}),{})};function Zd(e){const{values:t={xs:0,sm:600,md:900,lg:1200,xl:1536},unit:n="px",step:r=5}=e,o=ye(e,Kd),s=Jd(t),i=Object.keys(s);function l(w){return`@media (min-width:${typeof t[w]=="number"?t[w]:w}${n})`}function c(w){return`@media (max-width:${(typeof t[w]=="number"?t[w]:w)-r/100}${n})`}function d(w,b){const x=i.indexOf(b);return`@media (min-width:${typeof t[w]=="number"?t[w]:w}${n}) and (max-width:${(x!==-1&&typeof t[i[x]]=="number"?t[i[x]]:b)-r/100}${n})`}function u(w){return i.indexOf(w)+1`@media (min-width:${ko[e]}px)`};function et(e,t,n){const r=e.theme||{};if(Array.isArray(t)){const s=r.breakpoints||Sa;return t.reduce((i,l,c)=>(i[s.up(s.keys[c])]=n(t[c]),i),{})}if(typeof t=="object"){const s=r.breakpoints||Sa;return Object.keys(t).reduce((i,l)=>{if(Object.keys(s.values||ko).indexOf(l)!==-1){const c=s.up(l);i[c]=n(t[l],l)}else{const c=l;i[c]=t[c]}return i},{})}return n(t)}function nu(e={}){var t;return((t=e.keys)==null?void 0:t.reduce((r,o)=>{const s=e.up(o);return r[s]={},r},{}))||{}}function ru(e,t){return e.reduce((n,r)=>{const o=n[r];return(!o||Object.keys(o).length===0)&&delete n[r],n},t)}function pr(e,t,n=!0){if(!t||typeof t!="string")return null;if(e&&e.vars&&n){const r=`vars.${t}`.split(".").reduce((o,s)=>o&&o[s]?o[s]:null,e);if(r!=null)return r}return t.split(".").reduce((r,o)=>r&&r[o]!=null?r[o]:null,e)}function Zn(e,t,n,r=n){let o;return typeof e=="function"?o=e(n):Array.isArray(e)?o=e[n]||r:o=pr(e,n)||r,t&&(o=t(o,r,e)),o}function be(e){const{prop:t,cssProperty:n=e.prop,themeKey:r,transform:o}=e,s=i=>{if(i[t]==null)return null;const l=i[t],c=i.theme,d=pr(c,r)||{};return et(i,l,f=>{let w=Zn(d,o,f);return f===w&&typeof f=="string"&&(w=Zn(d,o,`${t}${f==="default"?"":Xe(f)}`,f)),n===!1?w:{[n]:w}})};return s.propTypes=process.env.NODE_ENV!=="production"?{[t]:st}:{},s.filterProps=[t],s}function ou(e){const t={};return n=>(t[n]===void 0&&(t[n]=e(n)),t[n])}const au={m:"margin",p:"padding"},su={t:"Top",r:"Right",b:"Bottom",l:"Left",x:["Left","Right"],y:["Top","Bottom"]},Ea={marginX:"mx",marginY:"my",paddingX:"px",paddingY:"py"},iu=ou(e=>{if(e.length>2)if(Ea[e])e=Ea[e];else return[e];const[t,n]=e.split(""),r=au[t],o=su[n]||"";return Array.isArray(o)?o.map(s=>r+s):[r+o]}),wr=["m","mt","mr","mb","ml","mx","my","margin","marginTop","marginRight","marginBottom","marginLeft","marginX","marginY","marginInline","marginInlineStart","marginInlineEnd","marginBlock","marginBlockStart","marginBlockEnd"],fr=["p","pt","pr","pb","pl","px","py","padding","paddingTop","paddingRight","paddingBottom","paddingLeft","paddingX","paddingY","paddingInline","paddingInlineStart","paddingInlineEnd","paddingBlock","paddingBlockStart","paddingBlockEnd"],lu=[...wr,...fr];function _n(e,t,n,r){var o;const s=(o=pr(e,t,!1))!=null?o:n;return typeof s=="number"?i=>typeof i=="string"?i:(process.env.NODE_ENV!=="production"&&typeof i!="number"&&console.error(`MUI: Expected ${r} argument to be a number or a string, got ${i}.`),s*i):Array.isArray(s)?i=>typeof i=="string"?i:(process.env.NODE_ENV!=="production"&&(Number.isInteger(i)?i>s.length-1&&console.error([`MUI: The value provided (${i}) overflows.`,`The supported values are: ${JSON.stringify(s)}.`,`${i} > ${s.length-1}, you need to add the missing values.`].join(` +`))},[JSON.stringify(t)])}const c=$.useCallback(d=>{o||i(d)},[]);return[l,c]}function Jr(e){const t=$.useRef(e);return Lt(()=>{t.current=e}),$.useRef((...n)=>(0,t.current)(...n)).current}function yt(...e){return $.useMemo(()=>e.every(t=>t==null)?null:t=>{e.forEach(n=>{Jn(n,t)})},e)}const Na={};function Ad(e,t){const n=$.useRef(Na);return n.current===Na&&(n.current=e(t)),n}const Dd=[];function Bd(e){$.useEffect(e,Dd)}class On{constructor(){this.currentId=null,this.clear=()=>{this.currentId!==null&&(clearTimeout(this.currentId),this.currentId=null)},this.disposeEffect=()=>this.clear}static create(){return new On}start(t,n){this.clear(),this.currentId=setTimeout(()=>{this.currentId=null,n()},t)}}function cn(){const e=Ad(On.create).current;return Bd(e.disposeEffect),e}let dr=!0,Zr=!1;const Vd=new On,zd={text:!0,search:!0,url:!0,tel:!0,email:!0,password:!0,number:!0,date:!0,month:!0,week:!0,time:!0,datetime:!0,"datetime-local":!0};function Ld(e){const{type:t,tagName:n}=e;return!!(n==="INPUT"&&zd[t]&&!e.readOnly||n==="TEXTAREA"&&!e.readOnly||e.isContentEditable)}function Fd(e){e.metaKey||e.altKey||e.ctrlKey||(dr=!0)}function Br(){dr=!1}function Gd(){this.visibilityState==="hidden"&&Zr&&(dr=!0)}function Ud(e){e.addEventListener("keydown",Fd,!0),e.addEventListener("mousedown",Br,!0),e.addEventListener("pointerdown",Br,!0),e.addEventListener("touchstart",Br,!0),e.addEventListener("visibilitychange",Gd,!0)}function qd(e){const{target:t}=e;try{return t.matches(":focus-visible")}catch{}return dr||Ld(t)}function ni(){const e=$.useCallback(o=>{o!=null&&Ud(o.ownerDocument)},[]),t=$.useRef(!1);function n(){return t.current?(Zr=!0,Vd.start(100,()=>{Zr=!1}),t.current=!1,!0):!1}function r(o){return qd(o)?(t.current=!0,!0):!1}return{isFocusVisibleRef:t,onFocus:r,onBlur:n,ref:e}}function ri(e,t){const n=R({},t);return Object.keys(e).forEach(r=>{if(r.toString().match(/^(components|slots)$/))n[r]=R({},e[r],n[r]);else if(r.toString().match(/^(componentsProps|slotProps)$/)){const o=e[r]||{},s=t[r];n[r]={},!s||!Object.keys(s)?n[r]=o:!o||!Object.keys(o)?n[r]=s:(n[r]=R({},s),Object.keys(o).forEach(i=>{n[r][i]=ri(o[i],s[i])}))}else n[r]===void 0&&(n[r]=e[r])}),n}function No(e,t,n=void 0){const r={};return Object.keys(e).forEach(o=>{r[o]=e[o].reduce((s,i)=>{if(i){const l=t(i);l!==""&&s.push(l),n&&n[i]&&s.push(n[i])}return s},[]).join(" ")}),r}const ka=e=>e,Hd=()=>{let e=ka;return{configure(t){e=t},generate(t){return e(t)},reset(){e=ka}}},Xd=Hd(),oi=Xd,ai={active:"active",checked:"checked",completed:"completed",disabled:"disabled",error:"error",expanded:"expanded",focused:"focused",focusVisible:"focusVisible",open:"open",readOnly:"readOnly",required:"required",selected:"selected"};function ur(e,t,n="Mui"){const r=ai[t];return r?`${n}-${r}`:`${oi.generate(e)}-${t}`}function si(e,t,n="Mui"){const r={};return t.forEach(o=>{r[o]=ur(e,o,n)}),r}function Yd(e,t=Number.MIN_SAFE_INTEGER,n=Number.MAX_SAFE_INTEGER){return Math.max(t,Math.min(e,n))}function ye(e,t){if(e==null)return{};var n={},r=Object.keys(e),o,s;for(s=0;s=0)&&(n[o]=e[o]);return n}const Wd=["values","unit","step"],Kd=e=>{const t=Object.keys(e).map(n=>({key:n,val:e[n]}))||[];return t.sort((n,r)=>n.val-r.val),t.reduce((n,r)=>R({},n,{[r.key]:r.val}),{})};function Jd(e){const{values:t={xs:0,sm:600,md:900,lg:1200,xl:1536},unit:n="px",step:r=5}=e,o=ye(e,Wd),s=Kd(t),i=Object.keys(s);function l(w){return`@media (min-width:${typeof t[w]=="number"?t[w]:w}${n})`}function c(w){return`@media (max-width:${(typeof t[w]=="number"?t[w]:w)-r/100}${n})`}function d(w,b){const x=i.indexOf(b);return`@media (min-width:${typeof t[w]=="number"?t[w]:w}${n}) and (max-width:${(x!==-1&&typeof t[i[x]]=="number"?t[i[x]]:b)-r/100}${n})`}function u(w){return i.indexOf(w)+1`@media (min-width:${ko[e]}px)`};function et(e,t,n){const r=e.theme||{};if(Array.isArray(t)){const s=r.breakpoints||Sa;return t.reduce((i,l,c)=>(i[s.up(s.keys[c])]=n(t[c]),i),{})}if(typeof t=="object"){const s=r.breakpoints||Sa;return Object.keys(t).reduce((i,l)=>{if(Object.keys(s.values||ko).indexOf(l)!==-1){const c=s.up(l);i[c]=n(t[l],l)}else{const c=l;i[c]=t[c]}return i},{})}return n(t)}function tu(e={}){var t;return((t=e.keys)==null?void 0:t.reduce((r,o)=>{const s=e.up(o);return r[s]={},r},{}))||{}}function nu(e,t){return e.reduce((n,r)=>{const o=n[r];return(!o||Object.keys(o).length===0)&&delete n[r],n},t)}function pr(e,t,n=!0){if(!t||typeof t!="string")return null;if(e&&e.vars&&n){const r=`vars.${t}`.split(".").reduce((o,s)=>o&&o[s]?o[s]:null,e);if(r!=null)return r}return t.split(".").reduce((r,o)=>r&&r[o]!=null?r[o]:null,e)}function Zn(e,t,n,r=n){let o;return typeof e=="function"?o=e(n):Array.isArray(e)?o=e[n]||r:o=pr(e,n)||r,t&&(o=t(o,r,e)),o}function be(e){const{prop:t,cssProperty:n=e.prop,themeKey:r,transform:o}=e,s=i=>{if(i[t]==null)return null;const l=i[t],c=i.theme,d=pr(c,r)||{};return et(i,l,f=>{let w=Zn(d,o,f);return f===w&&typeof f=="string"&&(w=Zn(d,o,`${t}${f==="default"?"":Ye(f)}`,f)),n===!1?w:{[n]:w}})};return s.propTypes=process.env.NODE_ENV!=="production"?{[t]:st}:{},s.filterProps=[t],s}function ru(e){const t={};return n=>(t[n]===void 0&&(t[n]=e(n)),t[n])}const ou={m:"margin",p:"padding"},au={t:"Top",r:"Right",b:"Bottom",l:"Left",x:["Left","Right"],y:["Top","Bottom"]},Ea={marginX:"mx",marginY:"my",paddingX:"px",paddingY:"py"},su=ru(e=>{if(e.length>2)if(Ea[e])e=Ea[e];else return[e];const[t,n]=e.split(""),r=ou[t],o=au[n]||"";return Array.isArray(o)?o.map(s=>r+s):[r+o]}),wr=["m","mt","mr","mb","ml","mx","my","margin","marginTop","marginRight","marginBottom","marginLeft","marginX","marginY","marginInline","marginInlineStart","marginInlineEnd","marginBlock","marginBlockStart","marginBlockEnd"],fr=["p","pt","pr","pb","pl","px","py","padding","paddingTop","paddingRight","paddingBottom","paddingLeft","paddingX","paddingY","paddingInline","paddingInlineStart","paddingInlineEnd","paddingBlock","paddingBlockStart","paddingBlockEnd"],iu=[...wr,...fr];function _n(e,t,n,r){var o;const s=(o=pr(e,t,!1))!=null?o:n;return typeof s=="number"?i=>typeof i=="string"?i:(process.env.NODE_ENV!=="production"&&typeof i!="number"&&console.error(`MUI: Expected ${r} argument to be a number or a string, got ${i}.`),s*i):Array.isArray(s)?i=>typeof i=="string"?i:(process.env.NODE_ENV!=="production"&&(Number.isInteger(i)?i>s.length-1&&console.error([`MUI: The value provided (${i}) overflows.`,`The supported values are: ${JSON.stringify(s)}.`,`${i} > ${s.length-1}, you need to add the missing values.`].join(` `)):console.error([`MUI: The \`theme.${t}\` array type cannot be combined with non integer values.You should either use an integer value that can be used as index, or define the \`theme.${t}\` as a number.`].join(` `))),s[i]):typeof s=="function"?s:(process.env.NODE_ENV!=="production"&&console.error([`MUI: The \`theme.${t}\` value (${s}) is invalid.`,"It should be a number, an array or a function."].join(` -`)),()=>{})}function ii(e){return _n(e,"spacing",8,"spacing")}function Pn(e,t){if(typeof t=="string"||t==null)return t;const n=Math.abs(t),r=e(n);return t>=0?r:typeof r=="number"?-r:`-${r}`}function cu(e,t){return n=>e.reduce((r,o)=>(r[o]=Pn(t,n),r),{})}function du(e,t,n,r){if(t.indexOf(n)===-1)return null;const o=iu(n),s=cu(o,r),i=e[n];return et(e,i,s)}function li(e,t){const n=ii(e.theme);return Object.keys(e).map(r=>du(e,t,r,n)).reduce(fn,{})}function me(e){return li(e,wr)}me.propTypes=process.env.NODE_ENV!=="production"?wr.reduce((e,t)=>(e[t]=st,e),{}):{};me.filterProps=wr;function he(e){return li(e,fr)}he.propTypes=process.env.NODE_ENV!=="production"?fr.reduce((e,t)=>(e[t]=st,e),{}):{};he.filterProps=fr;process.env.NODE_ENV!=="production"&&lu.reduce((e,t)=>(e[t]=st,e),{});function uu(e=8){if(e.mui)return e;const t=ii({spacing:e}),n=(...r)=>(process.env.NODE_ENV!=="production"&&(r.length<=4||console.error(`MUI: Too many arguments provided, expected between 0 and 4, got ${r.length}`)),(r.length===0?[1]:r).map(s=>{const i=t(s);return typeof i=="number"?`${i}px`:i}).join(" "));return n.mui=!0,n}function mr(...e){const t=e.reduce((r,o)=>(o.filterProps.forEach(s=>{r[s]=o}),r),{}),n=r=>Object.keys(r).reduce((o,s)=>t[s]?fn(o,t[s](r)):o,{});return n.propTypes=process.env.NODE_ENV!=="production"?e.reduce((r,o)=>Object.assign(r,o.propTypes),{}):{},n.filterProps=e.reduce((r,o)=>r.concat(o.filterProps),[]),n}function Ae(e){return typeof e!="number"?e:`${e}px solid`}function Le(e,t){return be({prop:e,themeKey:"borders",transform:t})}const pu=Le("border",Ae),wu=Le("borderTop",Ae),fu=Le("borderRight",Ae),mu=Le("borderBottom",Ae),hu=Le("borderLeft",Ae),gu=Le("borderColor"),bu=Le("borderTopColor"),vu=Le("borderRightColor"),xu=Le("borderBottomColor"),yu=Le("borderLeftColor"),Nu=Le("outline",Ae),ku=Le("outlineColor"),hr=e=>{if(e.borderRadius!==void 0&&e.borderRadius!==null){const t=_n(e.theme,"shape.borderRadius",4,"borderRadius"),n=r=>({borderRadius:Pn(t,r)});return et(e,e.borderRadius,n)}return null};hr.propTypes=process.env.NODE_ENV!=="production"?{borderRadius:st}:{};hr.filterProps=["borderRadius"];mr(pu,wu,fu,mu,hu,gu,bu,vu,xu,yu,hr,Nu,ku);const gr=e=>{if(e.gap!==void 0&&e.gap!==null){const t=_n(e.theme,"spacing",8,"gap"),n=r=>({gap:Pn(t,r)});return et(e,e.gap,n)}return null};gr.propTypes=process.env.NODE_ENV!=="production"?{gap:st}:{};gr.filterProps=["gap"];const br=e=>{if(e.columnGap!==void 0&&e.columnGap!==null){const t=_n(e.theme,"spacing",8,"columnGap"),n=r=>({columnGap:Pn(t,r)});return et(e,e.columnGap,n)}return null};br.propTypes=process.env.NODE_ENV!=="production"?{columnGap:st}:{};br.filterProps=["columnGap"];const vr=e=>{if(e.rowGap!==void 0&&e.rowGap!==null){const t=_n(e.theme,"spacing",8,"rowGap"),n=r=>({rowGap:Pn(t,r)});return et(e,e.rowGap,n)}return null};vr.propTypes=process.env.NODE_ENV!=="production"?{rowGap:st}:{};vr.filterProps=["rowGap"];const Su=be({prop:"gridColumn"}),Eu=be({prop:"gridRow"}),ju=be({prop:"gridAutoFlow"}),Tu=be({prop:"gridAutoColumns"}),Cu=be({prop:"gridAutoRows"}),Ru=be({prop:"gridTemplateColumns"}),Ou=be({prop:"gridTemplateRows"}),_u=be({prop:"gridTemplateAreas"}),Pu=be({prop:"gridArea"});mr(gr,br,vr,Su,Eu,ju,Tu,Cu,Ru,Ou,_u,Pu);function Dt(e,t){return t==="grey"?t:e}const Iu=be({prop:"color",themeKey:"palette",transform:Dt}),Mu=be({prop:"bgcolor",cssProperty:"backgroundColor",themeKey:"palette",transform:Dt}),$u=be({prop:"backgroundColor",themeKey:"palette",transform:Dt});mr(Iu,Mu,$u);function Pe(e){return e<=1&&e!==0?`${e*100}%`:e}const Du=be({prop:"width",transform:Pe}),So=e=>{if(e.maxWidth!==void 0&&e.maxWidth!==null){const t=n=>{var r,o;const s=((r=e.theme)==null||(r=r.breakpoints)==null||(r=r.values)==null?void 0:r[n])||ko[n];return s?((o=e.theme)==null||(o=o.breakpoints)==null?void 0:o.unit)!=="px"?{maxWidth:`${s}${e.theme.breakpoints.unit}`}:{maxWidth:s}:{maxWidth:Pe(n)}};return et(e,e.maxWidth,t)}return null};So.filterProps=["maxWidth"];const Au=be({prop:"minWidth",transform:Pe}),Bu=be({prop:"height",transform:Pe}),Vu=be({prop:"maxHeight",transform:Pe}),zu=be({prop:"minHeight",transform:Pe});be({prop:"size",cssProperty:"width",transform:Pe});be({prop:"size",cssProperty:"height",transform:Pe});const Lu=be({prop:"boxSizing"});mr(Du,So,Au,Bu,Vu,zu,Lu);const Fu={border:{themeKey:"borders",transform:Ae},borderTop:{themeKey:"borders",transform:Ae},borderRight:{themeKey:"borders",transform:Ae},borderBottom:{themeKey:"borders",transform:Ae},borderLeft:{themeKey:"borders",transform:Ae},borderColor:{themeKey:"palette"},borderTopColor:{themeKey:"palette"},borderRightColor:{themeKey:"palette"},borderBottomColor:{themeKey:"palette"},borderLeftColor:{themeKey:"palette"},outline:{themeKey:"borders",transform:Ae},outlineColor:{themeKey:"palette"},borderRadius:{themeKey:"shape.borderRadius",style:hr},color:{themeKey:"palette",transform:Dt},bgcolor:{themeKey:"palette",cssProperty:"backgroundColor",transform:Dt},backgroundColor:{themeKey:"palette",transform:Dt},p:{style:he},pt:{style:he},pr:{style:he},pb:{style:he},pl:{style:he},px:{style:he},py:{style:he},padding:{style:he},paddingTop:{style:he},paddingRight:{style:he},paddingBottom:{style:he},paddingLeft:{style:he},paddingX:{style:he},paddingY:{style:he},paddingInline:{style:he},paddingInlineStart:{style:he},paddingInlineEnd:{style:he},paddingBlock:{style:he},paddingBlockStart:{style:he},paddingBlockEnd:{style:he},m:{style:me},mt:{style:me},mr:{style:me},mb:{style:me},ml:{style:me},mx:{style:me},my:{style:me},margin:{style:me},marginTop:{style:me},marginRight:{style:me},marginBottom:{style:me},marginLeft:{style:me},marginX:{style:me},marginY:{style:me},marginInline:{style:me},marginInlineStart:{style:me},marginInlineEnd:{style:me},marginBlock:{style:me},marginBlockStart:{style:me},marginBlockEnd:{style:me},displayPrint:{cssProperty:!1,transform:e=>({"@media print":{display:e}})},display:{},overflow:{},textOverflow:{},visibility:{},whiteSpace:{},flexBasis:{},flexDirection:{},flexWrap:{},justifyContent:{},alignItems:{},alignContent:{},order:{},flex:{},flexGrow:{},flexShrink:{},alignSelf:{},justifyItems:{},justifySelf:{},gap:{style:gr},rowGap:{style:vr},columnGap:{style:br},gridColumn:{},gridRow:{},gridAutoFlow:{},gridAutoColumns:{},gridAutoRows:{},gridTemplateColumns:{},gridTemplateRows:{},gridTemplateAreas:{},gridArea:{},position:{},zIndex:{themeKey:"zIndex"},top:{},right:{},bottom:{},left:{},boxShadow:{themeKey:"shadows"},width:{transform:Pe},maxWidth:{style:So},minWidth:{transform:Pe},height:{transform:Pe},maxHeight:{transform:Pe},minHeight:{transform:Pe},boxSizing:{},fontFamily:{themeKey:"typography"},fontSize:{themeKey:"typography"},fontStyle:{themeKey:"typography"},fontWeight:{themeKey:"typography"},letterSpacing:{},textTransform:{},lineHeight:{},textAlign:{},typography:{cssProperty:!1,themeKey:"typography"}},Eo=Fu;function Gu(...e){const t=e.reduce((r,o)=>r.concat(Object.keys(o)),[]),n=new Set(t);return e.every(r=>n.size===Object.keys(r).length)}function Uu(e,t){return typeof e=="function"?e(t):e}function qu(){function e(n,r,o,s){const i={[n]:r,theme:o},l=s[n];if(!l)return{[n]:r};const{cssProperty:c=n,themeKey:d,transform:u,style:f}=l;if(r==null)return null;if(d==="typography"&&r==="inherit")return{[n]:r};const w=pr(o,d)||{};return f?f(i):et(i,r,x=>{let m=Zn(w,u,x);return x===m&&typeof x=="string"&&(m=Zn(w,u,`${n}${x==="default"?"":Xe(x)}`,x)),c===!1?m:{[c]:m}})}function t(n){var r;const{sx:o,theme:s={}}=n||{};if(!o)return null;const i=(r=s.unstable_sxConfig)!=null?r:Eo;function l(c){let d=c;if(typeof c=="function")d=c(s);else if(typeof c!="object")return c;if(!d)return null;const u=nu(s.breakpoints),f=Object.keys(u);let w=u;return Object.keys(d).forEach(b=>{const x=Uu(d[b],s);if(x!=null)if(typeof x=="object")if(i[b])w=fn(w,e(b,x,s,i));else{const m=et({theme:s},x,h=>({[b]:h}));Gu(m,x)?w[b]=t({sx:x,theme:s}):w=fn(w,m)}else w=fn(w,e(b,x,s,i))}),ru(f,w)}return Array.isArray(o)?o.map(l):l(o)}return t}const ci=qu();ci.filterProps=["sx"];const jo=ci;function Hu(e,t){const n=this;return n.vars&&typeof n.getColorSchemeSelector=="function"?{[n.getColorSchemeSelector(e).replace(/(\[[^\]]+\])/,"*:where($1)")]:t}:n.palette.mode===e?t:{}}const Yu=["breakpoints","palette","spacing","shape"];function To(e={},...t){const{breakpoints:n={},palette:r={},spacing:o,shape:s={}}=e,i=ye(e,Yu),l=Zd(n),c=uu(o);let d=Qe({breakpoints:l,direction:"ltr",components:{},palette:R({mode:"light"},r),spacing:c,shape:R({},eu,s)},i);return d.applyStyles=Hu,d=t.reduce((u,f)=>Qe(u,f),d),d.unstable_sxConfig=R({},Eo,i==null?void 0:i.unstable_sxConfig),d.unstable_sx=function(f){return jo({sx:f,theme:this})},d}function Xu(e){return Object.keys(e).length===0}function di(e=null){const t=$.useContext(Fr.ThemeContext);return!t||Xu(t)?e:t}const Wu=To();function ui(e=Wu){return di(e)}const Ku=["ownerState"],Ju=["variants"],Zu=["name","slot","skipVariantsResolver","skipSx","overridesResolver"];function Qu(e){return Object.keys(e).length===0}function ep(e){return typeof e=="string"&&e.charCodeAt(0)>96}function qn(e){return e!=="ownerState"&&e!=="theme"&&e!=="sx"&&e!=="as"}const tp=To(),ja=e=>e&&e.charAt(0).toLowerCase()+e.slice(1);function Ln({defaultTheme:e,theme:t,themeId:n}){return Qu(t)?e:t[n]||t}function np(e){return e?(t,n)=>n[e]:null}function Hn(e,t){let{ownerState:n}=t,r=ye(t,Ku);const o=typeof e=="function"?e(R({ownerState:n},r)):e;if(Array.isArray(o))return o.flatMap(s=>Hn(s,R({ownerState:n},r)));if(o&&typeof o=="object"&&Array.isArray(o.variants)){const{variants:s=[]}=o;let l=ye(o,Ju);return s.forEach(c=>{let d=!0;typeof c.props=="function"?d=c.props(R({ownerState:n},r,n)):Object.keys(c.props).forEach(u=>{(n==null?void 0:n[u])!==c.props[u]&&r[u]!==c.props[u]&&(d=!1)}),d&&(Array.isArray(l)||(l=[l]),l.push(typeof c.style=="function"?c.style(R({ownerState:n},r,n)):c.style))}),l}return o}function rp(e={}){const{themeId:t,defaultTheme:n=tp,rootShouldForwardProp:r=qn,slotShouldForwardProp:o=qn}=e,s=i=>jo(R({},i,{theme:Ln(R({},i,{defaultTheme:n,themeId:t}))}));return s.__mui_systemSx=!0,(i,l={})=>{Fr.internal_processStyles(i,v=>v.filter(_=>!(_!=null&&_.__mui_systemSx)));const{name:c,slot:d,skipVariantsResolver:u,skipSx:f,overridesResolver:w=np(ja(d))}=l,b=ye(l,Zu),x=u!==void 0?u:d&&d!=="Root"&&d!=="root"||!1,m=f||!1;let h;process.env.NODE_ENV!=="production"&&c&&(h=`${c}-${ja(d||"Root")}`);let E=qn;d==="Root"||d==="root"?E=r:d?E=o:ep(i)&&(E=void 0);const I=Fr(i,R({shouldForwardProp:E,label:h},b)),C=v=>typeof v=="function"&&v.__emotion_real!==v||mt(v)?_=>Hn(v,R({},_,{theme:Ln({theme:_.theme,defaultTheme:n,themeId:t})})):v,S=(v,..._)=>{let V=C(v);const U=_?_.map(C):[];c&&w&&U.push(k=>{const D=Ln(R({},k,{defaultTheme:n,themeId:t}));if(!D.components||!D.components[c]||!D.components[c].styleOverrides)return null;const M=D.components[c].styleOverrides,J={};return Object.entries(M).forEach(([X,F])=>{J[X]=Hn(F,R({},k,{theme:D}))}),w(k,J)}),c&&!x&&U.push(k=>{var D;const M=Ln(R({},k,{defaultTheme:n,themeId:t})),J=M==null||(D=M.components)==null||(D=D[c])==null?void 0:D.variants;return Hn({variants:J},R({},k,{theme:M}))}),m||U.push(s);const j=U.length-_.length;if(Array.isArray(v)&&j>0){const k=new Array(j).fill("");V=[...v,...k],V.raw=[...v.raw,...k]}const O=I(V,...U);if(process.env.NODE_ENV!=="production"){let k;c&&(k=`${c}${Xe(d||"")}`),k===void 0&&(k=`Styled(${jd(i)})`),O.displayName=k}return i.muiName&&(O.muiName=i.muiName),O};return I.withConfig&&(S.withConfig=I.withConfig),S}}function op(e){const{theme:t,name:n,props:r}=e;return!t||!t.components||!t.components[n]||!t.components[n].defaultProps?r:ri(t.components[n].defaultProps,r)}function ap({props:e,name:t,defaultTheme:n,themeId:r}){let o=ui(n);return r&&(o=o[r]||o),op({theme:o,name:t,props:e})}function Co(e,t=0,n=1){return process.env.NODE_ENV!=="production"&&(en)&&console.error(`MUI: The value provided ${e} is out of range [${t}, ${n}].`),Wd(e,t,n)}function sp(e){e=e.slice(1);const t=new RegExp(`.{1,${e.length>=6?2:1}}`,"g");let n=e.match(t);return n&&n[0].length===1&&(n=n.map(r=>r+r)),n?`rgb${n.length===4?"a":""}(${n.map((r,o)=>o<3?parseInt(r,16):Math.round(parseInt(r,16)/255*1e3)/1e3).join(", ")})`:""}function Nt(e){if(e.type)return e;if(e.charAt(0)==="#")return Nt(sp(e));const t=e.indexOf("("),n=e.substring(0,t);if(["rgb","rgba","hsl","hsla","color"].indexOf(n)===-1)throw new Error(process.env.NODE_ENV!=="production"?`MUI: Unsupported \`${e}\` color. +`)),()=>{})}function ii(e){return _n(e,"spacing",8,"spacing")}function Pn(e,t){if(typeof t=="string"||t==null)return t;const n=Math.abs(t),r=e(n);return t>=0?r:typeof r=="number"?-r:`-${r}`}function lu(e,t){return n=>e.reduce((r,o)=>(r[o]=Pn(t,n),r),{})}function cu(e,t,n,r){if(t.indexOf(n)===-1)return null;const o=su(n),s=lu(o,r),i=e[n];return et(e,i,s)}function li(e,t){const n=ii(e.theme);return Object.keys(e).map(r=>cu(e,t,r,n)).reduce(fn,{})}function me(e){return li(e,wr)}me.propTypes=process.env.NODE_ENV!=="production"?wr.reduce((e,t)=>(e[t]=st,e),{}):{};me.filterProps=wr;function he(e){return li(e,fr)}he.propTypes=process.env.NODE_ENV!=="production"?fr.reduce((e,t)=>(e[t]=st,e),{}):{};he.filterProps=fr;process.env.NODE_ENV!=="production"&&iu.reduce((e,t)=>(e[t]=st,e),{});function du(e=8){if(e.mui)return e;const t=ii({spacing:e}),n=(...r)=>(process.env.NODE_ENV!=="production"&&(r.length<=4||console.error(`MUI: Too many arguments provided, expected between 0 and 4, got ${r.length}`)),(r.length===0?[1]:r).map(s=>{const i=t(s);return typeof i=="number"?`${i}px`:i}).join(" "));return n.mui=!0,n}function mr(...e){const t=e.reduce((r,o)=>(o.filterProps.forEach(s=>{r[s]=o}),r),{}),n=r=>Object.keys(r).reduce((o,s)=>t[s]?fn(o,t[s](r)):o,{});return n.propTypes=process.env.NODE_ENV!=="production"?e.reduce((r,o)=>Object.assign(r,o.propTypes),{}):{},n.filterProps=e.reduce((r,o)=>r.concat(o.filterProps),[]),n}function De(e){return typeof e!="number"?e:`${e}px solid`}function Le(e,t){return be({prop:e,themeKey:"borders",transform:t})}const uu=Le("border",De),pu=Le("borderTop",De),wu=Le("borderRight",De),fu=Le("borderBottom",De),mu=Le("borderLeft",De),hu=Le("borderColor"),gu=Le("borderTopColor"),bu=Le("borderRightColor"),vu=Le("borderBottomColor"),xu=Le("borderLeftColor"),yu=Le("outline",De),Nu=Le("outlineColor"),hr=e=>{if(e.borderRadius!==void 0&&e.borderRadius!==null){const t=_n(e.theme,"shape.borderRadius",4,"borderRadius"),n=r=>({borderRadius:Pn(t,r)});return et(e,e.borderRadius,n)}return null};hr.propTypes=process.env.NODE_ENV!=="production"?{borderRadius:st}:{};hr.filterProps=["borderRadius"];mr(uu,pu,wu,fu,mu,hu,gu,bu,vu,xu,hr,yu,Nu);const gr=e=>{if(e.gap!==void 0&&e.gap!==null){const t=_n(e.theme,"spacing",8,"gap"),n=r=>({gap:Pn(t,r)});return et(e,e.gap,n)}return null};gr.propTypes=process.env.NODE_ENV!=="production"?{gap:st}:{};gr.filterProps=["gap"];const br=e=>{if(e.columnGap!==void 0&&e.columnGap!==null){const t=_n(e.theme,"spacing",8,"columnGap"),n=r=>({columnGap:Pn(t,r)});return et(e,e.columnGap,n)}return null};br.propTypes=process.env.NODE_ENV!=="production"?{columnGap:st}:{};br.filterProps=["columnGap"];const vr=e=>{if(e.rowGap!==void 0&&e.rowGap!==null){const t=_n(e.theme,"spacing",8,"rowGap"),n=r=>({rowGap:Pn(t,r)});return et(e,e.rowGap,n)}return null};vr.propTypes=process.env.NODE_ENV!=="production"?{rowGap:st}:{};vr.filterProps=["rowGap"];const ku=be({prop:"gridColumn"}),Su=be({prop:"gridRow"}),Eu=be({prop:"gridAutoFlow"}),ju=be({prop:"gridAutoColumns"}),Tu=be({prop:"gridAutoRows"}),Cu=be({prop:"gridTemplateColumns"}),Ru=be({prop:"gridTemplateRows"}),Ou=be({prop:"gridTemplateAreas"}),_u=be({prop:"gridArea"});mr(gr,br,vr,ku,Su,Eu,ju,Tu,Cu,Ru,Ou,_u);function At(e,t){return t==="grey"?t:e}const Pu=be({prop:"color",themeKey:"palette",transform:At}),Iu=be({prop:"bgcolor",cssProperty:"backgroundColor",themeKey:"palette",transform:At}),Mu=be({prop:"backgroundColor",themeKey:"palette",transform:At});mr(Pu,Iu,Mu);function Pe(e){return e<=1&&e!==0?`${e*100}%`:e}const $u=be({prop:"width",transform:Pe}),So=e=>{if(e.maxWidth!==void 0&&e.maxWidth!==null){const t=n=>{var r,o;const s=((r=e.theme)==null||(r=r.breakpoints)==null||(r=r.values)==null?void 0:r[n])||ko[n];return s?((o=e.theme)==null||(o=o.breakpoints)==null?void 0:o.unit)!=="px"?{maxWidth:`${s}${e.theme.breakpoints.unit}`}:{maxWidth:s}:{maxWidth:Pe(n)}};return et(e,e.maxWidth,t)}return null};So.filterProps=["maxWidth"];const Au=be({prop:"minWidth",transform:Pe}),Du=be({prop:"height",transform:Pe}),Bu=be({prop:"maxHeight",transform:Pe}),Vu=be({prop:"minHeight",transform:Pe});be({prop:"size",cssProperty:"width",transform:Pe});be({prop:"size",cssProperty:"height",transform:Pe});const zu=be({prop:"boxSizing"});mr($u,So,Au,Du,Bu,Vu,zu);const Lu={border:{themeKey:"borders",transform:De},borderTop:{themeKey:"borders",transform:De},borderRight:{themeKey:"borders",transform:De},borderBottom:{themeKey:"borders",transform:De},borderLeft:{themeKey:"borders",transform:De},borderColor:{themeKey:"palette"},borderTopColor:{themeKey:"palette"},borderRightColor:{themeKey:"palette"},borderBottomColor:{themeKey:"palette"},borderLeftColor:{themeKey:"palette"},outline:{themeKey:"borders",transform:De},outlineColor:{themeKey:"palette"},borderRadius:{themeKey:"shape.borderRadius",style:hr},color:{themeKey:"palette",transform:At},bgcolor:{themeKey:"palette",cssProperty:"backgroundColor",transform:At},backgroundColor:{themeKey:"palette",transform:At},p:{style:he},pt:{style:he},pr:{style:he},pb:{style:he},pl:{style:he},px:{style:he},py:{style:he},padding:{style:he},paddingTop:{style:he},paddingRight:{style:he},paddingBottom:{style:he},paddingLeft:{style:he},paddingX:{style:he},paddingY:{style:he},paddingInline:{style:he},paddingInlineStart:{style:he},paddingInlineEnd:{style:he},paddingBlock:{style:he},paddingBlockStart:{style:he},paddingBlockEnd:{style:he},m:{style:me},mt:{style:me},mr:{style:me},mb:{style:me},ml:{style:me},mx:{style:me},my:{style:me},margin:{style:me},marginTop:{style:me},marginRight:{style:me},marginBottom:{style:me},marginLeft:{style:me},marginX:{style:me},marginY:{style:me},marginInline:{style:me},marginInlineStart:{style:me},marginInlineEnd:{style:me},marginBlock:{style:me},marginBlockStart:{style:me},marginBlockEnd:{style:me},displayPrint:{cssProperty:!1,transform:e=>({"@media print":{display:e}})},display:{},overflow:{},textOverflow:{},visibility:{},whiteSpace:{},flexBasis:{},flexDirection:{},flexWrap:{},justifyContent:{},alignItems:{},alignContent:{},order:{},flex:{},flexGrow:{},flexShrink:{},alignSelf:{},justifyItems:{},justifySelf:{},gap:{style:gr},rowGap:{style:vr},columnGap:{style:br},gridColumn:{},gridRow:{},gridAutoFlow:{},gridAutoColumns:{},gridAutoRows:{},gridTemplateColumns:{},gridTemplateRows:{},gridTemplateAreas:{},gridArea:{},position:{},zIndex:{themeKey:"zIndex"},top:{},right:{},bottom:{},left:{},boxShadow:{themeKey:"shadows"},width:{transform:Pe},maxWidth:{style:So},minWidth:{transform:Pe},height:{transform:Pe},maxHeight:{transform:Pe},minHeight:{transform:Pe},boxSizing:{},fontFamily:{themeKey:"typography"},fontSize:{themeKey:"typography"},fontStyle:{themeKey:"typography"},fontWeight:{themeKey:"typography"},letterSpacing:{},textTransform:{},lineHeight:{},textAlign:{},typography:{cssProperty:!1,themeKey:"typography"}},Eo=Lu;function Fu(...e){const t=e.reduce((r,o)=>r.concat(Object.keys(o)),[]),n=new Set(t);return e.every(r=>n.size===Object.keys(r).length)}function Gu(e,t){return typeof e=="function"?e(t):e}function Uu(){function e(n,r,o,s){const i={[n]:r,theme:o},l=s[n];if(!l)return{[n]:r};const{cssProperty:c=n,themeKey:d,transform:u,style:f}=l;if(r==null)return null;if(d==="typography"&&r==="inherit")return{[n]:r};const w=pr(o,d)||{};return f?f(i):et(i,r,x=>{let m=Zn(w,u,x);return x===m&&typeof x=="string"&&(m=Zn(w,u,`${n}${x==="default"?"":Ye(x)}`,x)),c===!1?m:{[c]:m}})}function t(n){var r;const{sx:o,theme:s={}}=n||{};if(!o)return null;const i=(r=s.unstable_sxConfig)!=null?r:Eo;function l(c){let d=c;if(typeof c=="function")d=c(s);else if(typeof c!="object")return c;if(!d)return null;const u=tu(s.breakpoints),f=Object.keys(u);let w=u;return Object.keys(d).forEach(b=>{const x=Gu(d[b],s);if(x!=null)if(typeof x=="object")if(i[b])w=fn(w,e(b,x,s,i));else{const m=et({theme:s},x,h=>({[b]:h}));Fu(m,x)?w[b]=t({sx:x,theme:s}):w=fn(w,m)}else w=fn(w,e(b,x,s,i))}),nu(f,w)}return Array.isArray(o)?o.map(l):l(o)}return t}const ci=Uu();ci.filterProps=["sx"];const jo=ci;function qu(e,t){const n=this;return n.vars&&typeof n.getColorSchemeSelector=="function"?{[n.getColorSchemeSelector(e).replace(/(\[[^\]]+\])/,"*:where($1)")]:t}:n.palette.mode===e?t:{}}const Hu=["breakpoints","palette","spacing","shape"];function To(e={},...t){const{breakpoints:n={},palette:r={},spacing:o,shape:s={}}=e,i=ye(e,Hu),l=Jd(n),c=du(o);let d=Qe({breakpoints:l,direction:"ltr",components:{},palette:R({mode:"light"},r),spacing:c,shape:R({},Qd,s)},i);return d.applyStyles=qu,d=t.reduce((u,f)=>Qe(u,f),d),d.unstable_sxConfig=R({},Eo,i==null?void 0:i.unstable_sxConfig),d.unstable_sx=function(f){return jo({sx:f,theme:this})},d}function Xu(e){return Object.keys(e).length===0}function di(e=null){const t=$.useContext(Fr.ThemeContext);return!t||Xu(t)?e:t}const Yu=To();function ui(e=Yu){return di(e)}const Wu=["ownerState"],Ku=["variants"],Ju=["name","slot","skipVariantsResolver","skipSx","overridesResolver"];function Zu(e){return Object.keys(e).length===0}function Qu(e){return typeof e=="string"&&e.charCodeAt(0)>96}function qn(e){return e!=="ownerState"&&e!=="theme"&&e!=="sx"&&e!=="as"}const ep=To(),ja=e=>e&&e.charAt(0).toLowerCase()+e.slice(1);function Ln({defaultTheme:e,theme:t,themeId:n}){return Zu(t)?e:t[n]||t}function tp(e){return e?(t,n)=>n[e]:null}function Hn(e,t){let{ownerState:n}=t,r=ye(t,Wu);const o=typeof e=="function"?e(R({ownerState:n},r)):e;if(Array.isArray(o))return o.flatMap(s=>Hn(s,R({ownerState:n},r)));if(o&&typeof o=="object"&&Array.isArray(o.variants)){const{variants:s=[]}=o;let l=ye(o,Ku);return s.forEach(c=>{let d=!0;typeof c.props=="function"?d=c.props(R({ownerState:n},r,n)):Object.keys(c.props).forEach(u=>{(n==null?void 0:n[u])!==c.props[u]&&r[u]!==c.props[u]&&(d=!1)}),d&&(Array.isArray(l)||(l=[l]),l.push(typeof c.style=="function"?c.style(R({ownerState:n},r,n)):c.style))}),l}return o}function np(e={}){const{themeId:t,defaultTheme:n=ep,rootShouldForwardProp:r=qn,slotShouldForwardProp:o=qn}=e,s=i=>jo(R({},i,{theme:Ln(R({},i,{defaultTheme:n,themeId:t}))}));return s.__mui_systemSx=!0,(i,l={})=>{Fr.internal_processStyles(i,v=>v.filter(_=>!(_!=null&&_.__mui_systemSx)));const{name:c,slot:d,skipVariantsResolver:u,skipSx:f,overridesResolver:w=tp(ja(d))}=l,b=ye(l,Ju),x=u!==void 0?u:d&&d!=="Root"&&d!=="root"||!1,m=f||!1;let h;process.env.NODE_ENV!=="production"&&c&&(h=`${c}-${ja(d||"Root")}`);let E=qn;d==="Root"||d==="root"?E=r:d?E=o:Qu(i)&&(E=void 0);const I=Fr(i,R({shouldForwardProp:E,label:h},b)),C=v=>typeof v=="function"&&v.__emotion_real!==v||mt(v)?_=>Hn(v,R({},_,{theme:Ln({theme:_.theme,defaultTheme:n,themeId:t})})):v,S=(v,..._)=>{let V=C(v);const U=_?_.map(C):[];c&&w&&U.push(k=>{const A=Ln(R({},k,{defaultTheme:n,themeId:t}));if(!A.components||!A.components[c]||!A.components[c].styleOverrides)return null;const M=A.components[c].styleOverrides,J={};return Object.entries(M).forEach(([Y,F])=>{J[Y]=Hn(F,R({},k,{theme:A}))}),w(k,J)}),c&&!x&&U.push(k=>{var A;const M=Ln(R({},k,{defaultTheme:n,themeId:t})),J=M==null||(A=M.components)==null||(A=A[c])==null?void 0:A.variants;return Hn({variants:J},R({},k,{theme:M}))}),m||U.push(s);const j=U.length-_.length;if(Array.isArray(v)&&j>0){const k=new Array(j).fill("");V=[...v,...k],V.raw=[...v.raw,...k]}const O=I(V,...U);if(process.env.NODE_ENV!=="production"){let k;c&&(k=`${c}${Ye(d||"")}`),k===void 0&&(k=`Styled(${Ed(i)})`),O.displayName=k}return i.muiName&&(O.muiName=i.muiName),O};return I.withConfig&&(S.withConfig=I.withConfig),S}}function rp(e){const{theme:t,name:n,props:r}=e;return!t||!t.components||!t.components[n]||!t.components[n].defaultProps?r:ri(t.components[n].defaultProps,r)}function op({props:e,name:t,defaultTheme:n,themeId:r}){let o=ui(n);return r&&(o=o[r]||o),rp({theme:o,name:t,props:e})}function Co(e,t=0,n=1){return process.env.NODE_ENV!=="production"&&(en)&&console.error(`MUI: The value provided ${e} is out of range [${t}, ${n}].`),Yd(e,t,n)}function ap(e){e=e.slice(1);const t=new RegExp(`.{1,${e.length>=6?2:1}}`,"g");let n=e.match(t);return n&&n[0].length===1&&(n=n.map(r=>r+r)),n?`rgb${n.length===4?"a":""}(${n.map((r,o)=>o<3?parseInt(r,16):Math.round(parseInt(r,16)/255*1e3)/1e3).join(", ")})`:""}function Nt(e){if(e.type)return e;if(e.charAt(0)==="#")return Nt(ap(e));const t=e.indexOf("("),n=e.substring(0,t);if(["rgb","rgba","hsl","hsla","color"].indexOf(n)===-1)throw new Error(process.env.NODE_ENV!=="production"?`MUI: Unsupported \`${e}\` color. The following formats are supported: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color().`:zt(9,e));let r=e.substring(t+1,e.length-1),o;if(n==="color"){if(r=r.split(" "),o=r.shift(),r.length===4&&r[3].charAt(0)==="/"&&(r[3]=r[3].slice(1)),["srgb","display-p3","a98-rgb","prophoto-rgb","rec-2020"].indexOf(o)===-1)throw new Error(process.env.NODE_ENV!=="production"?`MUI: unsupported \`${o}\` color space. -The following color spaces are supported: srgb, display-p3, a98-rgb, prophoto-rgb, rec-2020.`:zt(10,o))}else r=r.split(",");return r=r.map(s=>parseFloat(s)),{type:n,values:r,colorSpace:o}}function xr(e){const{type:t,colorSpace:n}=e;let{values:r}=e;return t.indexOf("rgb")!==-1?r=r.map((o,s)=>s<3?parseInt(o,10):o):t.indexOf("hsl")!==-1&&(r[1]=`${r[1]}%`,r[2]=`${r[2]}%`),t.indexOf("color")!==-1?r=`${n} ${r.join(" ")}`:r=`${r.join(", ")}`,`${t}(${r})`}function ip(e){e=Nt(e);const{values:t}=e,n=t[0],r=t[1]/100,o=t[2]/100,s=r*Math.min(o,1-o),i=(d,u=(d+n/30)%12)=>o-s*Math.max(Math.min(u-3,9-u,1),-1);let l="rgb";const c=[Math.round(i(0)*255),Math.round(i(8)*255),Math.round(i(4)*255)];return e.type==="hsla"&&(l+="a",c.push(t[3])),xr({type:l,values:c})}function Ta(e){e=Nt(e);let t=e.type==="hsl"||e.type==="hsla"?Nt(ip(e)).values:e.values;return t=t.map(n=>(e.type!=="color"&&(n/=255),n<=.03928?n/12.92:((n+.055)/1.055)**2.4)),Number((.2126*t[0]+.7152*t[1]+.0722*t[2]).toFixed(3))}function Ca(e,t){const n=Ta(e),r=Ta(t);return(Math.max(n,r)+.05)/(Math.min(n,r)+.05)}function pi(e,t){return e=Nt(e),t=Co(t),(e.type==="rgb"||e.type==="hsl")&&(e.type+="a"),e.type==="color"?e.values[3]=`/${t}`:e.values[3]=t,xr(e)}function lp(e,t){if(e=Nt(e),t=Co(t),e.type.indexOf("hsl")!==-1)e.values[2]*=1-t;else if(e.type.indexOf("rgb")!==-1||e.type.indexOf("color")!==-1)for(let n=0;n<3;n+=1)e.values[n]*=1-t;return xr(e)}function cp(e,t){if(e=Nt(e),t=Co(t),e.type.indexOf("hsl")!==-1)e.values[2]+=(100-e.values[2])*t;else if(e.type.indexOf("rgb")!==-1)for(let n=0;n<3;n+=1)e.values[n]+=(255-e.values[n])*t;else if(e.type.indexOf("color")!==-1)for(let n=0;n<3;n+=1)e.values[n]+=(1-e.values[n])*t;return xr(e)}function dp(e,t){return R({toolbar:{minHeight:56,[e.up("xs")]:{"@media (orientation: landscape)":{minHeight:48}},[e.up("sm")]:{minHeight:64}}},t)}const up={black:"#000",white:"#fff"},xn=up,pp={50:"#fafafa",100:"#f5f5f5",200:"#eeeeee",300:"#e0e0e0",400:"#bdbdbd",500:"#9e9e9e",600:"#757575",700:"#616161",800:"#424242",900:"#212121",A100:"#f5f5f5",A200:"#eeeeee",A400:"#bdbdbd",A700:"#616161"},wp=pp,fp={50:"#f3e5f5",100:"#e1bee7",200:"#ce93d8",300:"#ba68c8",400:"#ab47bc",500:"#9c27b0",600:"#8e24aa",700:"#7b1fa2",800:"#6a1b9a",900:"#4a148c",A100:"#ea80fc",A200:"#e040fb",A400:"#d500f9",A700:"#aa00ff"},Rt=fp,mp={50:"#ffebee",100:"#ffcdd2",200:"#ef9a9a",300:"#e57373",400:"#ef5350",500:"#f44336",600:"#e53935",700:"#d32f2f",800:"#c62828",900:"#b71c1c",A100:"#ff8a80",A200:"#ff5252",A400:"#ff1744",A700:"#d50000"},Ot=mp,hp={50:"#fff3e0",100:"#ffe0b2",200:"#ffcc80",300:"#ffb74d",400:"#ffa726",500:"#ff9800",600:"#fb8c00",700:"#f57c00",800:"#ef6c00",900:"#e65100",A100:"#ffd180",A200:"#ffab40",A400:"#ff9100",A700:"#ff6d00"},rn=hp,gp={50:"#e3f2fd",100:"#bbdefb",200:"#90caf9",300:"#64b5f6",400:"#42a5f5",500:"#2196f3",600:"#1e88e5",700:"#1976d2",800:"#1565c0",900:"#0d47a1",A100:"#82b1ff",A200:"#448aff",A400:"#2979ff",A700:"#2962ff"},_t=gp,bp={50:"#e1f5fe",100:"#b3e5fc",200:"#81d4fa",300:"#4fc3f7",400:"#29b6f6",500:"#03a9f4",600:"#039be5",700:"#0288d1",800:"#0277bd",900:"#01579b",A100:"#80d8ff",A200:"#40c4ff",A400:"#00b0ff",A700:"#0091ea"},Pt=bp,vp={50:"#e8f5e9",100:"#c8e6c9",200:"#a5d6a7",300:"#81c784",400:"#66bb6a",500:"#4caf50",600:"#43a047",700:"#388e3c",800:"#2e7d32",900:"#1b5e20",A100:"#b9f6ca",A200:"#69f0ae",A400:"#00e676",A700:"#00c853"},It=vp,xp=["mode","contrastThreshold","tonalOffset"],Ra={text:{primary:"rgba(0, 0, 0, 0.87)",secondary:"rgba(0, 0, 0, 0.6)",disabled:"rgba(0, 0, 0, 0.38)"},divider:"rgba(0, 0, 0, 0.12)",background:{paper:xn.white,default:xn.white},action:{active:"rgba(0, 0, 0, 0.54)",hover:"rgba(0, 0, 0, 0.04)",hoverOpacity:.04,selected:"rgba(0, 0, 0, 0.08)",selectedOpacity:.08,disabled:"rgba(0, 0, 0, 0.26)",disabledBackground:"rgba(0, 0, 0, 0.12)",disabledOpacity:.38,focus:"rgba(0, 0, 0, 0.12)",focusOpacity:.12,activatedOpacity:.12}},Vr={text:{primary:xn.white,secondary:"rgba(255, 255, 255, 0.7)",disabled:"rgba(255, 255, 255, 0.5)",icon:"rgba(255, 255, 255, 0.5)"},divider:"rgba(255, 255, 255, 0.12)",background:{paper:"#121212",default:"#121212"},action:{active:xn.white,hover:"rgba(255, 255, 255, 0.08)",hoverOpacity:.08,selected:"rgba(255, 255, 255, 0.16)",selectedOpacity:.16,disabled:"rgba(255, 255, 255, 0.3)",disabledBackground:"rgba(255, 255, 255, 0.12)",disabledOpacity:.38,focus:"rgba(255, 255, 255, 0.12)",focusOpacity:.12,activatedOpacity:.24}};function Oa(e,t,n,r){const o=r.light||r,s=r.dark||r*1.5;e[t]||(e.hasOwnProperty(n)?e[t]=e[n]:t==="light"?e.light=cp(e.main,o):t==="dark"&&(e.dark=lp(e.main,s)))}function yp(e="light"){return e==="dark"?{main:_t[200],light:_t[50],dark:_t[400]}:{main:_t[700],light:_t[400],dark:_t[800]}}function Np(e="light"){return e==="dark"?{main:Rt[200],light:Rt[50],dark:Rt[400]}:{main:Rt[500],light:Rt[300],dark:Rt[700]}}function kp(e="light"){return e==="dark"?{main:Ot[500],light:Ot[300],dark:Ot[700]}:{main:Ot[700],light:Ot[400],dark:Ot[800]}}function Sp(e="light"){return e==="dark"?{main:Pt[400],light:Pt[300],dark:Pt[700]}:{main:Pt[700],light:Pt[500],dark:Pt[900]}}function Ep(e="light"){return e==="dark"?{main:It[400],light:It[300],dark:It[700]}:{main:It[800],light:It[500],dark:It[900]}}function jp(e="light"){return e==="dark"?{main:rn[400],light:rn[300],dark:rn[700]}:{main:"#ed6c02",light:rn[500],dark:rn[900]}}function Tp(e){const{mode:t="light",contrastThreshold:n=3,tonalOffset:r=.2}=e,o=ye(e,xp),s=e.primary||yp(t),i=e.secondary||Np(t),l=e.error||kp(t),c=e.info||Sp(t),d=e.success||Ep(t),u=e.warning||jp(t);function f(m){const h=Ca(m,Vr.text.primary)>=n?Vr.text.primary:Ra.text.primary;if(process.env.NODE_ENV!=="production"){const E=Ca(m,h);E<3&&console.error([`MUI: The contrast ratio of ${E}:1 for ${h} on ${m}`,"falls below the WCAG recommended absolute minimum contrast ratio of 3:1.","https://www.w3.org/TR/2008/REC-WCAG20-20081211/#visual-audio-contrast-contrast"].join(` +The following color spaces are supported: srgb, display-p3, a98-rgb, prophoto-rgb, rec-2020.`:zt(10,o))}else r=r.split(",");return r=r.map(s=>parseFloat(s)),{type:n,values:r,colorSpace:o}}function xr(e){const{type:t,colorSpace:n}=e;let{values:r}=e;return t.indexOf("rgb")!==-1?r=r.map((o,s)=>s<3?parseInt(o,10):o):t.indexOf("hsl")!==-1&&(r[1]=`${r[1]}%`,r[2]=`${r[2]}%`),t.indexOf("color")!==-1?r=`${n} ${r.join(" ")}`:r=`${r.join(", ")}`,`${t}(${r})`}function sp(e){e=Nt(e);const{values:t}=e,n=t[0],r=t[1]/100,o=t[2]/100,s=r*Math.min(o,1-o),i=(d,u=(d+n/30)%12)=>o-s*Math.max(Math.min(u-3,9-u,1),-1);let l="rgb";const c=[Math.round(i(0)*255),Math.round(i(8)*255),Math.round(i(4)*255)];return e.type==="hsla"&&(l+="a",c.push(t[3])),xr({type:l,values:c})}function Ta(e){e=Nt(e);let t=e.type==="hsl"||e.type==="hsla"?Nt(sp(e)).values:e.values;return t=t.map(n=>(e.type!=="color"&&(n/=255),n<=.03928?n/12.92:((n+.055)/1.055)**2.4)),Number((.2126*t[0]+.7152*t[1]+.0722*t[2]).toFixed(3))}function Ca(e,t){const n=Ta(e),r=Ta(t);return(Math.max(n,r)+.05)/(Math.min(n,r)+.05)}function pi(e,t){return e=Nt(e),t=Co(t),(e.type==="rgb"||e.type==="hsl")&&(e.type+="a"),e.type==="color"?e.values[3]=`/${t}`:e.values[3]=t,xr(e)}function ip(e,t){if(e=Nt(e),t=Co(t),e.type.indexOf("hsl")!==-1)e.values[2]*=1-t;else if(e.type.indexOf("rgb")!==-1||e.type.indexOf("color")!==-1)for(let n=0;n<3;n+=1)e.values[n]*=1-t;return xr(e)}function lp(e,t){if(e=Nt(e),t=Co(t),e.type.indexOf("hsl")!==-1)e.values[2]+=(100-e.values[2])*t;else if(e.type.indexOf("rgb")!==-1)for(let n=0;n<3;n+=1)e.values[n]+=(255-e.values[n])*t;else if(e.type.indexOf("color")!==-1)for(let n=0;n<3;n+=1)e.values[n]+=(1-e.values[n])*t;return xr(e)}function cp(e,t){return R({toolbar:{minHeight:56,[e.up("xs")]:{"@media (orientation: landscape)":{minHeight:48}},[e.up("sm")]:{minHeight:64}}},t)}const dp={black:"#000",white:"#fff"},xn=dp,up={50:"#fafafa",100:"#f5f5f5",200:"#eeeeee",300:"#e0e0e0",400:"#bdbdbd",500:"#9e9e9e",600:"#757575",700:"#616161",800:"#424242",900:"#212121",A100:"#f5f5f5",A200:"#eeeeee",A400:"#bdbdbd",A700:"#616161"},pp=up,wp={50:"#f3e5f5",100:"#e1bee7",200:"#ce93d8",300:"#ba68c8",400:"#ab47bc",500:"#9c27b0",600:"#8e24aa",700:"#7b1fa2",800:"#6a1b9a",900:"#4a148c",A100:"#ea80fc",A200:"#e040fb",A400:"#d500f9",A700:"#aa00ff"},Rt=wp,fp={50:"#ffebee",100:"#ffcdd2",200:"#ef9a9a",300:"#e57373",400:"#ef5350",500:"#f44336",600:"#e53935",700:"#d32f2f",800:"#c62828",900:"#b71c1c",A100:"#ff8a80",A200:"#ff5252",A400:"#ff1744",A700:"#d50000"},Ot=fp,mp={50:"#fff3e0",100:"#ffe0b2",200:"#ffcc80",300:"#ffb74d",400:"#ffa726",500:"#ff9800",600:"#fb8c00",700:"#f57c00",800:"#ef6c00",900:"#e65100",A100:"#ffd180",A200:"#ffab40",A400:"#ff9100",A700:"#ff6d00"},rn=mp,hp={50:"#e3f2fd",100:"#bbdefb",200:"#90caf9",300:"#64b5f6",400:"#42a5f5",500:"#2196f3",600:"#1e88e5",700:"#1976d2",800:"#1565c0",900:"#0d47a1",A100:"#82b1ff",A200:"#448aff",A400:"#2979ff",A700:"#2962ff"},_t=hp,gp={50:"#e1f5fe",100:"#b3e5fc",200:"#81d4fa",300:"#4fc3f7",400:"#29b6f6",500:"#03a9f4",600:"#039be5",700:"#0288d1",800:"#0277bd",900:"#01579b",A100:"#80d8ff",A200:"#40c4ff",A400:"#00b0ff",A700:"#0091ea"},Pt=gp,bp={50:"#e8f5e9",100:"#c8e6c9",200:"#a5d6a7",300:"#81c784",400:"#66bb6a",500:"#4caf50",600:"#43a047",700:"#388e3c",800:"#2e7d32",900:"#1b5e20",A100:"#b9f6ca",A200:"#69f0ae",A400:"#00e676",A700:"#00c853"},It=bp,vp=["mode","contrastThreshold","tonalOffset"],Ra={text:{primary:"rgba(0, 0, 0, 0.87)",secondary:"rgba(0, 0, 0, 0.6)",disabled:"rgba(0, 0, 0, 0.38)"},divider:"rgba(0, 0, 0, 0.12)",background:{paper:xn.white,default:xn.white},action:{active:"rgba(0, 0, 0, 0.54)",hover:"rgba(0, 0, 0, 0.04)",hoverOpacity:.04,selected:"rgba(0, 0, 0, 0.08)",selectedOpacity:.08,disabled:"rgba(0, 0, 0, 0.26)",disabledBackground:"rgba(0, 0, 0, 0.12)",disabledOpacity:.38,focus:"rgba(0, 0, 0, 0.12)",focusOpacity:.12,activatedOpacity:.12}},Vr={text:{primary:xn.white,secondary:"rgba(255, 255, 255, 0.7)",disabled:"rgba(255, 255, 255, 0.5)",icon:"rgba(255, 255, 255, 0.5)"},divider:"rgba(255, 255, 255, 0.12)",background:{paper:"#121212",default:"#121212"},action:{active:xn.white,hover:"rgba(255, 255, 255, 0.08)",hoverOpacity:.08,selected:"rgba(255, 255, 255, 0.16)",selectedOpacity:.16,disabled:"rgba(255, 255, 255, 0.3)",disabledBackground:"rgba(255, 255, 255, 0.12)",disabledOpacity:.38,focus:"rgba(255, 255, 255, 0.12)",focusOpacity:.12,activatedOpacity:.24}};function Oa(e,t,n,r){const o=r.light||r,s=r.dark||r*1.5;e[t]||(e.hasOwnProperty(n)?e[t]=e[n]:t==="light"?e.light=lp(e.main,o):t==="dark"&&(e.dark=ip(e.main,s)))}function xp(e="light"){return e==="dark"?{main:_t[200],light:_t[50],dark:_t[400]}:{main:_t[700],light:_t[400],dark:_t[800]}}function yp(e="light"){return e==="dark"?{main:Rt[200],light:Rt[50],dark:Rt[400]}:{main:Rt[500],light:Rt[300],dark:Rt[700]}}function Np(e="light"){return e==="dark"?{main:Ot[500],light:Ot[300],dark:Ot[700]}:{main:Ot[700],light:Ot[400],dark:Ot[800]}}function kp(e="light"){return e==="dark"?{main:Pt[400],light:Pt[300],dark:Pt[700]}:{main:Pt[700],light:Pt[500],dark:Pt[900]}}function Sp(e="light"){return e==="dark"?{main:It[400],light:It[300],dark:It[700]}:{main:It[800],light:It[500],dark:It[900]}}function Ep(e="light"){return e==="dark"?{main:rn[400],light:rn[300],dark:rn[700]}:{main:"#ed6c02",light:rn[500],dark:rn[900]}}function jp(e){const{mode:t="light",contrastThreshold:n=3,tonalOffset:r=.2}=e,o=ye(e,vp),s=e.primary||xp(t),i=e.secondary||yp(t),l=e.error||Np(t),c=e.info||kp(t),d=e.success||Sp(t),u=e.warning||Ep(t);function f(m){const h=Ca(m,Vr.text.primary)>=n?Vr.text.primary:Ra.text.primary;if(process.env.NODE_ENV!=="production"){const E=Ca(m,h);E<3&&console.error([`MUI: The contrast ratio of ${E}:1 for ${h} on ${m}`,"falls below the WCAG recommended absolute minimum contrast ratio of 3:1.","https://www.w3.org/TR/2008/REC-WCAG20-20081211/#visual-audio-contrast-contrast"].join(` `))}return h}const w=({color:m,name:h,mainShade:E=500,lightShade:I=300,darkShade:C=700})=>{if(m=R({},m),!m.main&&m[E]&&(m.main=m[E]),!m.hasOwnProperty("main"))throw new Error(process.env.NODE_ENV!=="production"?`MUI: The color${h?` (${h})`:""} provided to augmentColor(color) is invalid. The color object needs to have a \`main\` property or a \`${E}\` property.`:zt(11,h?` (${h})`:"",E));if(typeof m.main!="string")throw new Error(process.env.NODE_ENV!=="production"?`MUI: The color${h?` (${h})`:""} provided to augmentColor(color) is invalid. \`color.main\` should be a string, but \`${JSON.stringify(m.main)}\` was provided instead. @@ -55,16 +55,16 @@ const theme1 = createTheme({ palette: { const theme2 = createTheme({ palette: { primary: { main: green[500] }, -} });`:zt(12,h?` (${h})`:"",JSON.stringify(m.main)));return Oa(m,"light",I,r),Oa(m,"dark",C,r),m.contrastText||(m.contrastText=f(m.main)),m},b={dark:Vr,light:Ra};return process.env.NODE_ENV!=="production"&&(b[t]||console.error(`MUI: The palette mode \`${t}\` is not supported.`)),Qe(R({common:R({},xn),mode:t,primary:w({color:s,name:"primary"}),secondary:w({color:i,name:"secondary",mainShade:"A400",lightShade:"A200",darkShade:"A700"}),error:w({color:l,name:"error"}),warning:w({color:u,name:"warning"}),info:w({color:c,name:"info"}),success:w({color:d,name:"success"}),grey:wp,contrastThreshold:n,getContrastText:f,augmentColor:w,tonalOffset:r},b[t]),o)}const Cp=["fontFamily","fontSize","fontWeightLight","fontWeightRegular","fontWeightMedium","fontWeightBold","htmlFontSize","allVariants","pxToRem"];function Rp(e){return Math.round(e*1e5)/1e5}const _a={textTransform:"uppercase"},Pa='"Roboto", "Helvetica", "Arial", sans-serif';function Op(e,t){const n=typeof t=="function"?t(e):t,{fontFamily:r=Pa,fontSize:o=14,fontWeightLight:s=300,fontWeightRegular:i=400,fontWeightMedium:l=500,fontWeightBold:c=700,htmlFontSize:d=16,allVariants:u,pxToRem:f}=n,w=ye(n,Cp);process.env.NODE_ENV!=="production"&&(typeof o!="number"&&console.error("MUI: `fontSize` is required to be a number."),typeof d!="number"&&console.error("MUI: `htmlFontSize` is required to be a number."));const b=o/14,x=f||(E=>`${E/d*b}rem`),m=(E,I,C,S,v)=>R({fontFamily:r,fontWeight:E,fontSize:x(I),lineHeight:C},r===Pa?{letterSpacing:`${Rp(S/I)}em`}:{},v,u),h={h1:m(s,96,1.167,-1.5),h2:m(s,60,1.2,-.5),h3:m(i,48,1.167,0),h4:m(i,34,1.235,.25),h5:m(i,24,1.334,0),h6:m(l,20,1.6,.15),subtitle1:m(i,16,1.75,.15),subtitle2:m(l,14,1.57,.1),body1:m(i,16,1.5,.15),body2:m(i,14,1.43,.15),button:m(l,14,1.75,.4,_a),caption:m(i,12,1.66,.4),overline:m(i,12,2.66,1,_a),inherit:{fontFamily:"inherit",fontWeight:"inherit",fontSize:"inherit",lineHeight:"inherit",letterSpacing:"inherit"}};return Qe(R({htmlFontSize:d,pxToRem:x,fontFamily:r,fontSize:o,fontWeightLight:s,fontWeightRegular:i,fontWeightMedium:l,fontWeightBold:c},h),w,{clone:!1})}const _p=.2,Pp=.14,Ip=.12;function we(...e){return[`${e[0]}px ${e[1]}px ${e[2]}px ${e[3]}px rgba(0,0,0,${_p})`,`${e[4]}px ${e[5]}px ${e[6]}px ${e[7]}px rgba(0,0,0,${Pp})`,`${e[8]}px ${e[9]}px ${e[10]}px ${e[11]}px rgba(0,0,0,${Ip})`].join(",")}const Mp=["none",we(0,2,1,-1,0,1,1,0,0,1,3,0),we(0,3,1,-2,0,2,2,0,0,1,5,0),we(0,3,3,-2,0,3,4,0,0,1,8,0),we(0,2,4,-1,0,4,5,0,0,1,10,0),we(0,3,5,-1,0,5,8,0,0,1,14,0),we(0,3,5,-1,0,6,10,0,0,1,18,0),we(0,4,5,-2,0,7,10,1,0,2,16,1),we(0,5,5,-3,0,8,10,1,0,3,14,2),we(0,5,6,-3,0,9,12,1,0,3,16,2),we(0,6,6,-3,0,10,14,1,0,4,18,3),we(0,6,7,-4,0,11,15,1,0,4,20,3),we(0,7,8,-4,0,12,17,2,0,5,22,4),we(0,7,8,-4,0,13,19,2,0,5,24,4),we(0,7,9,-4,0,14,21,2,0,5,26,4),we(0,8,9,-5,0,15,22,2,0,6,28,5),we(0,8,10,-5,0,16,24,2,0,6,30,5),we(0,8,11,-5,0,17,26,2,0,6,32,5),we(0,9,11,-5,0,18,28,2,0,7,34,6),we(0,9,12,-6,0,19,29,2,0,7,36,6),we(0,10,13,-6,0,20,31,3,0,8,38,7),we(0,10,13,-6,0,21,33,3,0,8,40,7),we(0,10,14,-6,0,22,35,3,0,8,42,7),we(0,11,14,-7,0,23,36,3,0,9,44,8),we(0,11,15,-7,0,24,38,3,0,9,46,8)],$p=Mp,Dp=["duration","easing","delay"],Ap={easeInOut:"cubic-bezier(0.4, 0, 0.2, 1)",easeOut:"cubic-bezier(0.0, 0, 0.2, 1)",easeIn:"cubic-bezier(0.4, 0, 1, 1)",sharp:"cubic-bezier(0.4, 0, 0.6, 1)"},Bp={shortest:150,shorter:200,short:250,standard:300,complex:375,enteringScreen:225,leavingScreen:195};function Ia(e){return`${Math.round(e)}ms`}function Vp(e){if(!e)return 0;const t=e/36;return Math.round((4+15*t**.25+t/5)*10)}function zp(e){const t=R({},Ap,e.easing),n=R({},Bp,e.duration);return R({getAutoHeightDuration:Vp,create:(o=["all"],s={})=>{const{duration:i=n.standard,easing:l=t.easeInOut,delay:c=0}=s,d=ye(s,Dp);if(process.env.NODE_ENV!=="production"){const u=w=>typeof w=="string",f=w=>!isNaN(parseFloat(w));!u(o)&&!Array.isArray(o)&&console.error('MUI: Argument "props" must be a string or Array.'),!f(i)&&!u(i)&&console.error(`MUI: Argument "duration" must be a number or a string but found ${i}.`),u(l)||console.error('MUI: Argument "easing" must be a string.'),!f(c)&&!u(c)&&console.error('MUI: Argument "delay" must be a number or a string.'),typeof s!="object"&&console.error(["MUI: Secong argument of transition.create must be an object.","Arguments should be either `create('prop1', options)` or `create(['prop1', 'prop2'], options)`"].join(` -`)),Object.keys(d).length!==0&&console.error(`MUI: Unrecognized argument(s) [${Object.keys(d).join(",")}].`)}return(Array.isArray(o)?o:[o]).map(u=>`${u} ${typeof i=="string"?i:Ia(i)} ${l} ${typeof c=="string"?c:Ia(c)}`).join(",")}},e,{easing:t,duration:n})}const Lp={mobileStepper:1e3,fab:1050,speedDial:1050,appBar:1100,drawer:1200,modal:1300,snackbar:1400,tooltip:1500},Fp=Lp,Gp=["breakpoints","mixins","spacing","palette","transitions","typography","shape"];function Up(e={},...t){const{mixins:n={},palette:r={},transitions:o={},typography:s={}}=e,i=ye(e,Gp);if(e.vars)throw new Error(process.env.NODE_ENV!=="production"?"MUI: `vars` is a private field used for CSS variables support.\nPlease use another name.":zt(18));const l=Tp(r),c=To(e);let d=Qe(c,{mixins:dp(c.breakpoints,n),palette:l,shadows:$p.slice(),typography:Op(l,s),transitions:zp(o),zIndex:R({},Fp)});if(d=Qe(d,i),d=t.reduce((u,f)=>Qe(u,f),d),process.env.NODE_ENV!=="production"){const u=["active","checked","completed","disabled","error","expanded","focused","focusVisible","required","selected"],f=(w,b)=>{let x;for(x in w){const m=w[x];if(u.indexOf(x)!==-1&&Object.keys(m).length>0){if(process.env.NODE_ENV!=="production"){const h=ur("",x);console.error([`MUI: The \`${b}\` component increases the CSS specificity of the \`${x}\` internal state.`,"You can not override it like this: ",JSON.stringify(w,null,2),"",`Instead, you need to use the '&.${h}' syntax:`,JSON.stringify({root:{[`&.${h}`]:m}},null,2),"","https://mui.com/r/state-classes-guide"].join(` -`))}w[x]={}}}};Object.keys(d.components).forEach(w=>{const b=d.components[w].styleOverrides;b&&w.indexOf("Mui")===0&&f(b,w)})}return d.unstable_sxConfig=R({},Eo,i==null?void 0:i.unstable_sxConfig),d.unstable_sx=function(f){return jo({sx:f,theme:this})},d}const qp=Up(),Ro=qp,Oo="$$material";function _o({props:e,name:t}){return ap({props:e,name:t,defaultTheme:Ro,themeId:Oo})}const Hp=e=>qn(e)&&e!=="classes",Yp=rp({themeId:Oo,defaultTheme:Ro,rootShouldForwardProp:Hp}),In=Yp;function Xp(e){return ur("MuiSvgIcon",e)}si("MuiSvgIcon",["root","colorPrimary","colorSecondary","colorAction","colorError","colorDisabled","fontSizeInherit","fontSizeSmall","fontSizeMedium","fontSizeLarge"]);const Wp=["children","className","color","component","fontSize","htmlColor","inheritViewBox","titleAccess","viewBox"],Kp=e=>{const{color:t,fontSize:n,classes:r}=e,o={root:["root",t!=="inherit"&&`color${Xe(t)}`,`fontSize${Xe(n)}`]};return No(o,Xp,r)},Jp=In("svg",{name:"MuiSvgIcon",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.root,n.color!=="inherit"&&t[`color${Xe(n.color)}`],t[`fontSize${Xe(n.fontSize)}`]]}})(({theme:e,ownerState:t})=>{var n,r,o,s,i,l,c,d,u,f,w,b,x;return{userSelect:"none",width:"1em",height:"1em",display:"inline-block",fill:t.hasSvgAsChild?void 0:"currentColor",flexShrink:0,transition:(n=e.transitions)==null||(r=n.create)==null?void 0:r.call(n,"fill",{duration:(o=e.transitions)==null||(o=o.duration)==null?void 0:o.shorter}),fontSize:{inherit:"inherit",small:((s=e.typography)==null||(i=s.pxToRem)==null?void 0:i.call(s,20))||"1.25rem",medium:((l=e.typography)==null||(c=l.pxToRem)==null?void 0:c.call(l,24))||"1.5rem",large:((d=e.typography)==null||(u=d.pxToRem)==null?void 0:u.call(d,35))||"2.1875rem"}[t.fontSize],color:(f=(w=(e.vars||e).palette)==null||(w=w[t.color])==null?void 0:w.main)!=null?f:{action:(b=(e.vars||e).palette)==null||(b=b.action)==null?void 0:b.active,disabled:(x=(e.vars||e).palette)==null||(x=x.action)==null?void 0:x.disabled,inherit:void 0}[t.color]}}),Po=$.forwardRef(function(t,n){const r=_o({props:t,name:"MuiSvgIcon"}),{children:o,className:s,color:i="inherit",component:l="svg",fontSize:c="medium",htmlColor:d,inheritViewBox:u=!1,titleAccess:f,viewBox:w="0 0 24 24"}=r,b=ye(r,Wp),x=$.isValidElement(o)&&o.type==="svg",m=R({},r,{color:i,component:l,fontSize:c,instanceFontSize:t.fontSize,inheritViewBox:u,viewBox:w,hasSvgAsChild:x}),h={};u||(h.viewBox=w);const E=Kp(m);return a.jsxs(Jp,R({as:l,className:ot(E.root,s),focusable:"false",color:d,"aria-hidden":f?void 0:!0,role:f?"img":void 0,ref:n},h,b,x&&o.props,{ownerState:m,children:[x?o.props.children:o,f?a.jsx("title",{children:f}):null]}))});process.env.NODE_ENV!=="production"&&(Po.propTypes={children:p.node,classes:p.object,className:p.string,color:p.oneOfType([p.oneOf(["inherit","action","disabled","primary","secondary","error","info","success","warning"]),p.string]),component:p.elementType,fontSize:p.oneOfType([p.oneOf(["inherit","large","medium","small"]),p.string]),htmlColor:p.string,inheritViewBox:p.bool,shapeRendering:p.string,sx:p.oneOfType([p.arrayOf(p.oneOfType([p.func,p.object,p.bool])),p.func,p.object]),titleAccess:p.string,viewBox:p.string});Po.muiName="SvgIcon";const Ma=Po;function wi(e,t){function n(r,o){return a.jsx(Ma,R({"data-testid":`${t}Icon`,ref:o},r,{children:e}))}return process.env.NODE_ENV!=="production"&&(n.displayName=`${t}Icon`),n.muiName=Ma.muiName,$.memo($.forwardRef(n))}const Zp={configure:e=>{process.env.NODE_ENV!=="production"&&console.warn(["MUI: `ClassNameGenerator` import from `@mui/material/utils` is outdated and might cause unexpected issues.","","You should use `import { unstable_ClassNameGenerator } from '@mui/material/className'` instead","","The detail of the issue: https://github.com/mui/material-ui/issues/30011#issuecomment-1024993401","","The updated documentation: https://mui.com/guides/classname-generator/"].join(` -`)),oi.configure(e)}},Qp=Object.freeze(Object.defineProperty({__proto__:null,capitalize:Xe,createChainedFunction:Cd,createSvgIcon:wi,debounce:Rd,deprecatedPropType:Od,isMuiElement:_d,ownerDocument:Kn,ownerWindow:Pd,requirePropFactory:Id,setRef:Jn,unstable_ClassNameGenerator:Zp,unstable_useEnhancedEffect:Lt,unstable_useId:ei,unsupportedProp:Dd,useControlled:ti,useEventCallback:Jr,useForkRef:yt,useIsFocusVisible:ni},Symbol.toStringTag,{value:"Module"})),ew=ld(Qp);var $a;function tw(){return $a||($a=1,function(e){"use client";Object.defineProperty(e,"__esModule",{value:!0}),Object.defineProperty(e,"default",{enumerable:!0,get:function(){return t.createSvgIcon}});var t=ew}(_r)),_r}var nw=cd;Object.defineProperty(vo,"__esModule",{value:!0});var fi=vo.default=void 0,rw=nw(tw()),ow=a;fi=vo.default=(0,rw.default)((0,ow.jsx)("path",{d:"m10 17 5-5-5-5z"}),"ArrowRight");function aw(e){return typeof e=="string"}function dn(e,t,n){return e===void 0||aw(e)?t:R({},t,{ownerState:R({},t.ownerState,n)})}const sw={disableDefaultClasses:!1},iw=$.createContext(sw);function lw(e){const{disableDefaultClasses:t}=$.useContext(iw);return n=>t?"":e(n)}function cw(e,t=[]){if(e===void 0)return{};const n={};return Object.keys(e).filter(r=>r.match(/^on[A-Z]/)&&typeof e[r]=="function"&&!t.includes(r)).forEach(r=>{n[r]=e[r]}),n}function dw(e,t,n){return typeof e=="function"?e(t,n):e}function Da(e){if(e===void 0)return{};const t={};return Object.keys(e).filter(n=>!(n.match(/^on[A-Z]/)&&typeof e[n]=="function")).forEach(n=>{t[n]=e[n]}),t}function uw(e){const{getSlotProps:t,additionalProps:n,externalSlotProps:r,externalForwardedProps:o,className:s}=e;if(!t){const b=ot(n==null?void 0:n.className,s,o==null?void 0:o.className,r==null?void 0:r.className),x=R({},n==null?void 0:n.style,o==null?void 0:o.style,r==null?void 0:r.style),m=R({},n,o,r);return b.length>0&&(m.className=b),Object.keys(x).length>0&&(m.style=x),{props:m,internalRef:void 0}}const i=cw(R({},o,r)),l=Da(r),c=Da(o),d=t(i),u=ot(d==null?void 0:d.className,n==null?void 0:n.className,s,o==null?void 0:o.className,r==null?void 0:r.className),f=R({},d==null?void 0:d.style,n==null?void 0:n.style,o==null?void 0:o.style,r==null?void 0:r.style),w=R({},d,n,c,l);return u.length>0&&(w.className=u),Object.keys(f).length>0&&(w.style=f),{props:w,internalRef:d.ref}}const pw=["elementType","externalSlotProps","ownerState","skipResolvingSlotProps"];function ww(e){var t;const{elementType:n,externalSlotProps:r,ownerState:o,skipResolvingSlotProps:s=!1}=e,i=ye(e,pw),l=s?{}:dw(r,o),{props:c,internalRef:d}=uw(R({},i,{externalSlotProps:l})),u=yt(d,l==null?void 0:l.ref,(t=e.additionalProps)==null?void 0:t.ref);return dn(n,R({},c,{ref:u}),o)}const mi="base";function fw(e){return`${mi}--${e}`}function mw(e,t){return`${mi}-${e}-${t}`}function hi(e,t){const n=ai[t];return n?fw(n):mw(e,t)}function hw(e,t){const n={};return t.forEach(r=>{n[r]=hi(e,r)}),n}function gw(e){return typeof e=="function"?e():e}const Qn=$.forwardRef(function(t,n){const{children:r,container:o,disablePortal:s=!1}=t,[i,l]=$.useState(null),c=yt($.isValidElement(r)?r.ref:null,n);if(Lt(()=>{s||l(gw(o)||document.body)},[o,s]),Lt(()=>{if(i&&!s)return Jn(n,i),()=>{Jn(n,null)}},[n,i,s]),s){if($.isValidElement(r)){const d={ref:c};return $.cloneElement(r,d)}return a.jsx($.Fragment,{children:r})}return a.jsx($.Fragment,{children:i&&Tl.createPortal(r,i)})});process.env.NODE_ENV!=="production"&&(Qn.propTypes={children:p.node,container:p.oneOfType([vn,p.func]),disablePortal:p.bool});process.env.NODE_ENV!=="production"&&(Qn["propTypes"]=yd(Qn.propTypes));var je="top",Ve="bottom",ze="right",Te="left",Io="auto",Mn=[je,Ve,ze,Te],Ft="start",yn="end",bw="clippingParents",gi="viewport",on="popper",vw="reference",Aa=Mn.reduce(function(e,t){return e.concat([t+"-"+Ft,t+"-"+yn])},[]),bi=[].concat(Mn,[Io]).reduce(function(e,t){return e.concat([t,t+"-"+Ft,t+"-"+yn])},[]),xw="beforeRead",yw="read",Nw="afterRead",kw="beforeMain",Sw="main",Ew="afterMain",jw="beforeWrite",Tw="write",Cw="afterWrite",Rw=[xw,yw,Nw,kw,Sw,Ew,jw,Tw,Cw];function We(e){return e?(e.nodeName||"").toLowerCase():null}function Me(e){if(e==null)return window;if(e.toString()!=="[object Window]"){var t=e.ownerDocument;return t&&t.defaultView||window}return e}function kt(e){var t=Me(e).Element;return e instanceof t||e instanceof Element}function Be(e){var t=Me(e).HTMLElement;return e instanceof t||e instanceof HTMLElement}function Mo(e){if(typeof ShadowRoot>"u")return!1;var t=Me(e).ShadowRoot;return e instanceof t||e instanceof ShadowRoot}function Ow(e){var t=e.state;Object.keys(t.elements).forEach(function(n){var r=t.styles[n]||{},o=t.attributes[n]||{},s=t.elements[n];!Be(s)||!We(s)||(Object.assign(s.style,r),Object.keys(o).forEach(function(i){var l=o[i];l===!1?s.removeAttribute(i):s.setAttribute(i,l===!0?"":l)}))})}function _w(e){var t=e.state,n={popper:{position:t.options.strategy,left:"0",top:"0",margin:"0"},arrow:{position:"absolute"},reference:{}};return Object.assign(t.elements.popper.style,n.popper),t.styles=n,t.elements.arrow&&Object.assign(t.elements.arrow.style,n.arrow),function(){Object.keys(t.elements).forEach(function(r){var o=t.elements[r],s=t.attributes[r]||{},i=Object.keys(t.styles.hasOwnProperty(r)?t.styles[r]:n[r]),l=i.reduce(function(c,d){return c[d]="",c},{});!Be(o)||!We(o)||(Object.assign(o.style,l),Object.keys(s).forEach(function(c){o.removeAttribute(c)}))})}}const Pw={name:"applyStyles",enabled:!0,phase:"write",fn:Ow,effect:_w,requires:["computeStyles"]};function He(e){return e.split("-")[0]}var ht=Math.max,er=Math.min,Gt=Math.round;function Qr(){var e=navigator.userAgentData;return e!=null&&e.brands&&Array.isArray(e.brands)?e.brands.map(function(t){return t.brand+"/"+t.version}).join(" "):navigator.userAgent}function vi(){return!/^((?!chrome|android).)*safari/i.test(Qr())}function Ut(e,t,n){t===void 0&&(t=!1),n===void 0&&(n=!1);var r=e.getBoundingClientRect(),o=1,s=1;t&&Be(e)&&(o=e.offsetWidth>0&&Gt(r.width)/e.offsetWidth||1,s=e.offsetHeight>0&&Gt(r.height)/e.offsetHeight||1);var i=kt(e)?Me(e):window,l=i.visualViewport,c=!vi()&&n,d=(r.left+(c&&l?l.offsetLeft:0))/o,u=(r.top+(c&&l?l.offsetTop:0))/s,f=r.width/o,w=r.height/s;return{width:f,height:w,top:u,right:d+f,bottom:u+w,left:d,x:d,y:u}}function $o(e){var t=Ut(e),n=e.offsetWidth,r=e.offsetHeight;return Math.abs(t.width-n)<=1&&(n=t.width),Math.abs(t.height-r)<=1&&(r=t.height),{x:e.offsetLeft,y:e.offsetTop,width:n,height:r}}function xi(e,t){var n=t.getRootNode&&t.getRootNode();if(e.contains(t))return!0;if(n&&Mo(n)){var r=t;do{if(r&&e.isSameNode(r))return!0;r=r.parentNode||r.host}while(r)}return!1}function tt(e){return Me(e).getComputedStyle(e)}function Iw(e){return["table","td","th"].indexOf(We(e))>=0}function it(e){return((kt(e)?e.ownerDocument:e.document)||window.document).documentElement}function yr(e){return We(e)==="html"?e:e.assignedSlot||e.parentNode||(Mo(e)?e.host:null)||it(e)}function Ba(e){return!Be(e)||tt(e).position==="fixed"?null:e.offsetParent}function Mw(e){var t=/firefox/i.test(Qr()),n=/Trident/i.test(Qr());if(n&&Be(e)){var r=tt(e);if(r.position==="fixed")return null}var o=yr(e);for(Mo(o)&&(o=o.host);Be(o)&&["html","body"].indexOf(We(o))<0;){var s=tt(o);if(s.transform!=="none"||s.perspective!=="none"||s.contain==="paint"||["transform","perspective"].indexOf(s.willChange)!==-1||t&&s.willChange==="filter"||t&&s.filter&&s.filter!=="none")return o;o=o.parentNode}return null}function $n(e){for(var t=Me(e),n=Ba(e);n&&Iw(n)&&tt(n).position==="static";)n=Ba(n);return n&&(We(n)==="html"||We(n)==="body"&&tt(n).position==="static")?t:n||Mw(e)||t}function Do(e){return["top","bottom"].indexOf(e)>=0?"x":"y"}function mn(e,t,n){return ht(e,er(t,n))}function $w(e,t,n){var r=mn(e,t,n);return r>n?n:r}function yi(){return{top:0,right:0,bottom:0,left:0}}function Ni(e){return Object.assign({},yi(),e)}function ki(e,t){return t.reduce(function(n,r){return n[r]=e,n},{})}var Dw=function(t,n){return t=typeof t=="function"?t(Object.assign({},n.rects,{placement:n.placement})):t,Ni(typeof t!="number"?t:ki(t,Mn))};function Aw(e){var t,n=e.state,r=e.name,o=e.options,s=n.elements.arrow,i=n.modifiersData.popperOffsets,l=He(n.placement),c=Do(l),d=[Te,ze].indexOf(l)>=0,u=d?"height":"width";if(!(!s||!i)){var f=Dw(o.padding,n),w=$o(s),b=c==="y"?je:Te,x=c==="y"?Ve:ze,m=n.rects.reference[u]+n.rects.reference[c]-i[c]-n.rects.popper[u],h=i[c]-n.rects.reference[c],E=$n(s),I=E?c==="y"?E.clientHeight||0:E.clientWidth||0:0,C=m/2-h/2,S=f[b],v=I-w[u]-f[x],_=I/2-w[u]/2+C,V=mn(S,_,v),U=c;n.modifiersData[r]=(t={},t[U]=V,t.centerOffset=V-_,t)}}function Bw(e){var t=e.state,n=e.options,r=n.element,o=r===void 0?"[data-popper-arrow]":r;o!=null&&(typeof o=="string"&&(o=t.elements.popper.querySelector(o),!o)||xi(t.elements.popper,o)&&(t.elements.arrow=o))}const Vw={name:"arrow",enabled:!0,phase:"main",fn:Aw,effect:Bw,requires:["popperOffsets"],requiresIfExists:["preventOverflow"]};function qt(e){return e.split("-")[1]}var zw={top:"auto",right:"auto",bottom:"auto",left:"auto"};function Lw(e,t){var n=e.x,r=e.y,o=t.devicePixelRatio||1;return{x:Gt(n*o)/o||0,y:Gt(r*o)/o||0}}function Va(e){var t,n=e.popper,r=e.popperRect,o=e.placement,s=e.variation,i=e.offsets,l=e.position,c=e.gpuAcceleration,d=e.adaptive,u=e.roundOffsets,f=e.isFixed,w=i.x,b=w===void 0?0:w,x=i.y,m=x===void 0?0:x,h=typeof u=="function"?u({x:b,y:m}):{x:b,y:m};b=h.x,m=h.y;var E=i.hasOwnProperty("x"),I=i.hasOwnProperty("y"),C=Te,S=je,v=window;if(d){var _=$n(n),V="clientHeight",U="clientWidth";if(_===Me(n)&&(_=it(n),tt(_).position!=="static"&&l==="absolute"&&(V="scrollHeight",U="scrollWidth")),_=_,o===je||(o===Te||o===ze)&&s===yn){S=Ve;var j=f&&_===v&&v.visualViewport?v.visualViewport.height:_[V];m-=j-r.height,m*=c?1:-1}if(o===Te||(o===je||o===Ve)&&s===yn){C=ze;var O=f&&_===v&&v.visualViewport?v.visualViewport.width:_[U];b-=O-r.width,b*=c?1:-1}}var k=Object.assign({position:l},d&&zw),D=u===!0?Lw({x:b,y:m},Me(n)):{x:b,y:m};if(b=D.x,m=D.y,c){var M;return Object.assign({},k,(M={},M[S]=I?"0":"",M[C]=E?"0":"",M.transform=(v.devicePixelRatio||1)<=1?"translate("+b+"px, "+m+"px)":"translate3d("+b+"px, "+m+"px, 0)",M))}return Object.assign({},k,(t={},t[S]=I?m+"px":"",t[C]=E?b+"px":"",t.transform="",t))}function Fw(e){var t=e.state,n=e.options,r=n.gpuAcceleration,o=r===void 0?!0:r,s=n.adaptive,i=s===void 0?!0:s,l=n.roundOffsets,c=l===void 0?!0:l,d={placement:He(t.placement),variation:qt(t.placement),popper:t.elements.popper,popperRect:t.rects.popper,gpuAcceleration:o,isFixed:t.options.strategy==="fixed"};t.modifiersData.popperOffsets!=null&&(t.styles.popper=Object.assign({},t.styles.popper,Va(Object.assign({},d,{offsets:t.modifiersData.popperOffsets,position:t.options.strategy,adaptive:i,roundOffsets:c})))),t.modifiersData.arrow!=null&&(t.styles.arrow=Object.assign({},t.styles.arrow,Va(Object.assign({},d,{offsets:t.modifiersData.arrow,position:"absolute",adaptive:!1,roundOffsets:c})))),t.attributes.popper=Object.assign({},t.attributes.popper,{"data-popper-placement":t.placement})}const Gw={name:"computeStyles",enabled:!0,phase:"beforeWrite",fn:Fw,data:{}};var Fn={passive:!0};function Uw(e){var t=e.state,n=e.instance,r=e.options,o=r.scroll,s=o===void 0?!0:o,i=r.resize,l=i===void 0?!0:i,c=Me(t.elements.popper),d=[].concat(t.scrollParents.reference,t.scrollParents.popper);return s&&d.forEach(function(u){u.addEventListener("scroll",n.update,Fn)}),l&&c.addEventListener("resize",n.update,Fn),function(){s&&d.forEach(function(u){u.removeEventListener("scroll",n.update,Fn)}),l&&c.removeEventListener("resize",n.update,Fn)}}const qw={name:"eventListeners",enabled:!0,phase:"write",fn:function(){},effect:Uw,data:{}};var Hw={left:"right",right:"left",bottom:"top",top:"bottom"};function Yn(e){return e.replace(/left|right|bottom|top/g,function(t){return Hw[t]})}var Yw={start:"end",end:"start"};function za(e){return e.replace(/start|end/g,function(t){return Yw[t]})}function Ao(e){var t=Me(e),n=t.pageXOffset,r=t.pageYOffset;return{scrollLeft:n,scrollTop:r}}function Bo(e){return Ut(it(e)).left+Ao(e).scrollLeft}function Xw(e,t){var n=Me(e),r=it(e),o=n.visualViewport,s=r.clientWidth,i=r.clientHeight,l=0,c=0;if(o){s=o.width,i=o.height;var d=vi();(d||!d&&t==="fixed")&&(l=o.offsetLeft,c=o.offsetTop)}return{width:s,height:i,x:l+Bo(e),y:c}}function Ww(e){var t,n=it(e),r=Ao(e),o=(t=e.ownerDocument)==null?void 0:t.body,s=ht(n.scrollWidth,n.clientWidth,o?o.scrollWidth:0,o?o.clientWidth:0),i=ht(n.scrollHeight,n.clientHeight,o?o.scrollHeight:0,o?o.clientHeight:0),l=-r.scrollLeft+Bo(e),c=-r.scrollTop;return tt(o||n).direction==="rtl"&&(l+=ht(n.clientWidth,o?o.clientWidth:0)-s),{width:s,height:i,x:l,y:c}}function Vo(e){var t=tt(e),n=t.overflow,r=t.overflowX,o=t.overflowY;return/auto|scroll|overlay|hidden/.test(n+o+r)}function Si(e){return["html","body","#document"].indexOf(We(e))>=0?e.ownerDocument.body:Be(e)&&Vo(e)?e:Si(yr(e))}function hn(e,t){var n;t===void 0&&(t=[]);var r=Si(e),o=r===((n=e.ownerDocument)==null?void 0:n.body),s=Me(r),i=o?[s].concat(s.visualViewport||[],Vo(r)?r:[]):r,l=t.concat(i);return o?l:l.concat(hn(yr(i)))}function eo(e){return Object.assign({},e,{left:e.x,top:e.y,right:e.x+e.width,bottom:e.y+e.height})}function Kw(e,t){var n=Ut(e,!1,t==="fixed");return n.top=n.top+e.clientTop,n.left=n.left+e.clientLeft,n.bottom=n.top+e.clientHeight,n.right=n.left+e.clientWidth,n.width=e.clientWidth,n.height=e.clientHeight,n.x=n.left,n.y=n.top,n}function La(e,t,n){return t===gi?eo(Xw(e,n)):kt(t)?Kw(t,n):eo(Ww(it(e)))}function Jw(e){var t=hn(yr(e)),n=["absolute","fixed"].indexOf(tt(e).position)>=0,r=n&&Be(e)?$n(e):e;return kt(r)?t.filter(function(o){return kt(o)&&xi(o,r)&&We(o)!=="body"}):[]}function Zw(e,t,n,r){var o=t==="clippingParents"?Jw(e):[].concat(t),s=[].concat(o,[n]),i=s[0],l=s.reduce(function(c,d){var u=La(e,d,r);return c.top=ht(u.top,c.top),c.right=er(u.right,c.right),c.bottom=er(u.bottom,c.bottom),c.left=ht(u.left,c.left),c},La(e,i,r));return l.width=l.right-l.left,l.height=l.bottom-l.top,l.x=l.left,l.y=l.top,l}function Ei(e){var t=e.reference,n=e.element,r=e.placement,o=r?He(r):null,s=r?qt(r):null,i=t.x+t.width/2-n.width/2,l=t.y+t.height/2-n.height/2,c;switch(o){case je:c={x:i,y:t.y-n.height};break;case Ve:c={x:i,y:t.y+t.height};break;case ze:c={x:t.x+t.width,y:l};break;case Te:c={x:t.x-n.width,y:l};break;default:c={x:t.x,y:t.y}}var d=o?Do(o):null;if(d!=null){var u=d==="y"?"height":"width";switch(s){case Ft:c[d]=c[d]-(t[u]/2-n[u]/2);break;case yn:c[d]=c[d]+(t[u]/2-n[u]/2);break}}return c}function Nn(e,t){t===void 0&&(t={});var n=t,r=n.placement,o=r===void 0?e.placement:r,s=n.strategy,i=s===void 0?e.strategy:s,l=n.boundary,c=l===void 0?bw:l,d=n.rootBoundary,u=d===void 0?gi:d,f=n.elementContext,w=f===void 0?on:f,b=n.altBoundary,x=b===void 0?!1:b,m=n.padding,h=m===void 0?0:m,E=Ni(typeof h!="number"?h:ki(h,Mn)),I=w===on?vw:on,C=e.rects.popper,S=e.elements[x?I:w],v=Zw(kt(S)?S:S.contextElement||it(e.elements.popper),c,u,i),_=Ut(e.elements.reference),V=Ei({reference:_,element:C,strategy:"absolute",placement:o}),U=eo(Object.assign({},C,V)),j=w===on?U:_,O={top:v.top-j.top+E.top,bottom:j.bottom-v.bottom+E.bottom,left:v.left-j.left+E.left,right:j.right-v.right+E.right},k=e.modifiersData.offset;if(w===on&&k){var D=k[o];Object.keys(O).forEach(function(M){var J=[ze,Ve].indexOf(M)>=0?1:-1,X=[je,Ve].indexOf(M)>=0?"y":"x";O[M]+=D[X]*J})}return O}function Qw(e,t){t===void 0&&(t={});var n=t,r=n.placement,o=n.boundary,s=n.rootBoundary,i=n.padding,l=n.flipVariations,c=n.allowedAutoPlacements,d=c===void 0?bi:c,u=qt(r),f=u?l?Aa:Aa.filter(function(x){return qt(x)===u}):Mn,w=f.filter(function(x){return d.indexOf(x)>=0});w.length===0&&(w=f);var b=w.reduce(function(x,m){return x[m]=Nn(e,{placement:m,boundary:o,rootBoundary:s,padding:i})[He(m)],x},{});return Object.keys(b).sort(function(x,m){return b[x]-b[m]})}function ef(e){if(He(e)===Io)return[];var t=Yn(e);return[za(e),t,za(t)]}function tf(e){var t=e.state,n=e.options,r=e.name;if(!t.modifiersData[r]._skip){for(var o=n.mainAxis,s=o===void 0?!0:o,i=n.altAxis,l=i===void 0?!0:i,c=n.fallbackPlacements,d=n.padding,u=n.boundary,f=n.rootBoundary,w=n.altBoundary,b=n.flipVariations,x=b===void 0?!0:b,m=n.allowedAutoPlacements,h=t.options.placement,E=He(h),I=E===h,C=c||(I||!x?[Yn(h)]:ef(h)),S=[h].concat(C).reduce(function(B,Y){return B.concat(He(Y)===Io?Qw(t,{placement:Y,boundary:u,rootBoundary:f,padding:d,flipVariations:x,allowedAutoPlacements:m}):Y)},[]),v=t.rects.reference,_=t.rects.popper,V=new Map,U=!0,j=S[0],O=0;O=0,X=J?"width":"height",F=Nn(t,{placement:k,boundary:u,rootBoundary:f,altBoundary:w,padding:d}),te=J?M?ze:Te:M?Ve:je;v[X]>_[X]&&(te=Yn(te));var se=Yn(te),oe=[];if(s&&oe.push(F[D]<=0),l&&oe.push(F[te]<=0,F[se]<=0),oe.every(function(B){return B})){j=k,U=!1;break}V.set(k,oe)}if(U)for(var y=x?3:1,T=function(Y){var q=S.find(function(H){var G=V.get(H);if(G)return G.slice(0,Y).every(function(K){return K})});if(q)return j=q,"break"},z=y;z>0;z--){var L=T(z);if(L==="break")break}t.placement!==j&&(t.modifiersData[r]._skip=!0,t.placement=j,t.reset=!0)}}const nf={name:"flip",enabled:!0,phase:"main",fn:tf,requiresIfExists:["offset"],data:{_skip:!1}};function Fa(e,t,n){return n===void 0&&(n={x:0,y:0}),{top:e.top-t.height-n.y,right:e.right-t.width+n.x,bottom:e.bottom-t.height+n.y,left:e.left-t.width-n.x}}function Ga(e){return[je,ze,Ve,Te].some(function(t){return e[t]>=0})}function rf(e){var t=e.state,n=e.name,r=t.rects.reference,o=t.rects.popper,s=t.modifiersData.preventOverflow,i=Nn(t,{elementContext:"reference"}),l=Nn(t,{altBoundary:!0}),c=Fa(i,r),d=Fa(l,o,s),u=Ga(c),f=Ga(d);t.modifiersData[n]={referenceClippingOffsets:c,popperEscapeOffsets:d,isReferenceHidden:u,hasPopperEscaped:f},t.attributes.popper=Object.assign({},t.attributes.popper,{"data-popper-reference-hidden":u,"data-popper-escaped":f})}const of={name:"hide",enabled:!0,phase:"main",requiresIfExists:["preventOverflow"],fn:rf};function af(e,t,n){var r=He(e),o=[Te,je].indexOf(r)>=0?-1:1,s=typeof n=="function"?n(Object.assign({},t,{placement:e})):n,i=s[0],l=s[1];return i=i||0,l=(l||0)*o,[Te,ze].indexOf(r)>=0?{x:l,y:i}:{x:i,y:l}}function sf(e){var t=e.state,n=e.options,r=e.name,o=n.offset,s=o===void 0?[0,0]:o,i=bi.reduce(function(u,f){return u[f]=af(f,t.rects,s),u},{}),l=i[t.placement],c=l.x,d=l.y;t.modifiersData.popperOffsets!=null&&(t.modifiersData.popperOffsets.x+=c,t.modifiersData.popperOffsets.y+=d),t.modifiersData[r]=i}const lf={name:"offset",enabled:!0,phase:"main",requires:["popperOffsets"],fn:sf};function cf(e){var t=e.state,n=e.name;t.modifiersData[n]=Ei({reference:t.rects.reference,element:t.rects.popper,strategy:"absolute",placement:t.placement})}const df={name:"popperOffsets",enabled:!0,phase:"read",fn:cf,data:{}};function uf(e){return e==="x"?"y":"x"}function pf(e){var t=e.state,n=e.options,r=e.name,o=n.mainAxis,s=o===void 0?!0:o,i=n.altAxis,l=i===void 0?!1:i,c=n.boundary,d=n.rootBoundary,u=n.altBoundary,f=n.padding,w=n.tether,b=w===void 0?!0:w,x=n.tetherOffset,m=x===void 0?0:x,h=Nn(t,{boundary:c,rootBoundary:d,padding:f,altBoundary:u}),E=He(t.placement),I=qt(t.placement),C=!I,S=Do(E),v=uf(S),_=t.modifiersData.popperOffsets,V=t.rects.reference,U=t.rects.popper,j=typeof m=="function"?m(Object.assign({},t.rects,{placement:t.placement})):m,O=typeof j=="number"?{mainAxis:j,altAxis:j}:Object.assign({mainAxis:0,altAxis:0},j),k=t.modifiersData.offset?t.modifiersData.offset[t.placement]:null,D={x:0,y:0};if(_){if(s){var M,J=S==="y"?je:Te,X=S==="y"?Ve:ze,F=S==="y"?"height":"width",te=_[S],se=te+h[J],oe=te-h[X],y=b?-U[F]/2:0,T=I===Ft?V[F]:U[F],z=I===Ft?-U[F]:-V[F],L=t.elements.arrow,B=b&&L?$o(L):{width:0,height:0},Y=t.modifiersData["arrow#persistent"]?t.modifiersData["arrow#persistent"].padding:yi(),q=Y[J],H=Y[X],G=mn(0,V[F],B[F]),K=C?V[F]/2-y-G-q-O.mainAxis:T-G-q-O.mainAxis,Z=C?-V[F]/2+y+G+H+O.mainAxis:z+G+H+O.mainAxis,ue=t.elements.arrow&&$n(t.elements.arrow),P=ue?S==="y"?ue.clientTop||0:ue.clientLeft||0:0,xe=(M=k==null?void 0:k[S])!=null?M:0,A=te+K-xe-P,ve=te+Z-xe,Fe=mn(b?er(se,A):se,te,b?ht(oe,ve):oe);_[S]=Fe,D[S]=Fe-te}if(l){var lt,Se=S==="x"?je:Te,Dn=S==="x"?Ve:ze,Ge=_[v],Et=v==="y"?"height":"width",ct=Ge+h[Se],jt=Ge-h[Dn],Tt=[je,Te].indexOf(E)!==-1,Ct=(lt=k==null?void 0:k[v])!=null?lt:0,dt=Tt?ct:Ge-V[Et]-U[Et]-Ct+O.altAxis,Kt=Tt?Ge+V[Et]+U[Et]-Ct-O.altAxis:jt,An=b&&Tt?$w(dt,Ge,Kt):mn(b?dt:ct,Ge,b?Kt:jt);_[v]=An,D[v]=An-Ge}t.modifiersData[r]=D}}const wf={name:"preventOverflow",enabled:!0,phase:"main",fn:pf,requiresIfExists:["offset"]};function ff(e){return{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}}function mf(e){return e===Me(e)||!Be(e)?Ao(e):ff(e)}function hf(e){var t=e.getBoundingClientRect(),n=Gt(t.width)/e.offsetWidth||1,r=Gt(t.height)/e.offsetHeight||1;return n!==1||r!==1}function gf(e,t,n){n===void 0&&(n=!1);var r=Be(t),o=Be(t)&&hf(t),s=it(t),i=Ut(e,o,n),l={scrollLeft:0,scrollTop:0},c={x:0,y:0};return(r||!r&&!n)&&((We(t)!=="body"||Vo(s))&&(l=mf(t)),Be(t)?(c=Ut(t,!0),c.x+=t.clientLeft,c.y+=t.clientTop):s&&(c.x=Bo(s))),{x:i.left+l.scrollLeft-c.x,y:i.top+l.scrollTop-c.y,width:i.width,height:i.height}}function bf(e){var t=new Map,n=new Set,r=[];e.forEach(function(s){t.set(s.name,s)});function o(s){n.add(s.name);var i=[].concat(s.requires||[],s.requiresIfExists||[]);i.forEach(function(l){if(!n.has(l)){var c=t.get(l);c&&o(c)}}),r.push(s)}return e.forEach(function(s){n.has(s.name)||o(s)}),r}function vf(e){var t=bf(e);return Rw.reduce(function(n,r){return n.concat(t.filter(function(o){return o.phase===r}))},[])}function xf(e){var t;return function(){return t||(t=new Promise(function(n){Promise.resolve().then(function(){t=void 0,n(e())})})),t}}function yf(e){var t=e.reduce(function(n,r){var o=n[r.name];return n[r.name]=o?Object.assign({},o,r,{options:Object.assign({},o.options,r.options),data:Object.assign({},o.data,r.data)}):r,n},{});return Object.keys(t).map(function(n){return t[n]})}var Ua={placement:"bottom",modifiers:[],strategy:"absolute"};function qa(){for(var e=arguments.length,t=new Array(e),n=0;nNo({root:["root"]},lw(Ef)),_f={},Pf=$.forwardRef(function(t,n){var r;const{anchorEl:o,children:s,direction:i,disablePortal:l,modifiers:c,open:d,placement:u,popperOptions:f,popperRef:w,slotProps:b={},slots:x={},TransitionProps:m}=t,h=ye(t,jf),E=$.useRef(null),I=yt(E,n),C=$.useRef(null),S=yt(C,w),v=$.useRef(S);Lt(()=>{v.current=S},[S]),$.useImperativeHandle(w,()=>C.current,[]);const _=Cf(u,i),[V,U]=$.useState(_),[j,O]=$.useState(tr(o));$.useEffect(()=>{C.current&&C.current.forceUpdate()}),$.useEffect(()=>{o&&O(tr(o))},[o]),Lt(()=>{if(!j||!d)return;const X=se=>{U(se.placement)};if(process.env.NODE_ENV!=="production"&&j&&Nr(j)&&j.nodeType===1){const se=j.getBoundingClientRect();process.env.NODE_ENV!=="test"&&se.top===0&&se.left===0&&se.right===0&&se.bottom===0&&console.warn(["MUI: The `anchorEl` prop provided to the component is invalid.","The anchor element should be part of the document layout.","Make sure the element is present in the document or that it's not display none."].join(` -`))}let F=[{name:"preventOverflow",options:{altBoundary:l}},{name:"flip",options:{altBoundary:l}},{name:"onUpdate",enabled:!0,phase:"afterWrite",fn:({state:se})=>{X(se)}}];c!=null&&(F=F.concat(c)),f&&f.modifiers!=null&&(F=F.concat(f.modifiers));const te=Sf(j,E.current,R({placement:_},f,{modifiers:F}));return v.current(te),()=>{te.destroy(),v.current(null)}},[j,l,c,d,f,_]);const k={placement:V};m!==null&&(k.TransitionProps=m);const D=Of(),M=(r=x.root)!=null?r:"div",J=ww({elementType:M,externalSlotProps:b.root,externalForwardedProps:h,additionalProps:{role:"tooltip",ref:I},ownerState:t,className:D.root});return a.jsx(M,R({},J,{children:typeof s=="function"?s(k):s}))}),Ti=$.forwardRef(function(t,n){const{anchorEl:r,children:o,container:s,direction:i="ltr",disablePortal:l=!1,keepMounted:c=!1,modifiers:d,open:u,placement:f="bottom",popperOptions:w=_f,popperRef:b,style:x,transition:m=!1,slotProps:h={},slots:E={}}=t,I=ye(t,Tf),[C,S]=$.useState(!0),v=()=>{S(!1)},_=()=>{S(!0)};if(!c&&!u&&(!m||C))return null;let V;if(s)V=s;else if(r){const O=tr(r);V=O&&Nr(O)?Kn(O).body:Kn(null).body}const U=!u&&c&&(!m||C)?"none":void 0,j=m?{in:u,onEnter:v,onExited:_}:void 0;return a.jsx(Qn,{disablePortal:l,container:V,children:a.jsx(Pf,R({anchorEl:r,direction:i,disablePortal:l,modifiers:d,ref:n,open:m?!C:u,placement:f,popperOptions:w,popperRef:b,slotProps:h,slots:E},I,{style:R({position:"fixed",top:0,left:0,display:U},x),TransitionProps:j,children:o}))})});process.env.NODE_ENV!=="production"&&(Ti.propTypes={anchorEl:xo(p.oneOfType([vn,p.object,p.func]),e=>{if(e.open){const t=tr(e.anchorEl);if(t&&Nr(t)&&t.nodeType===1){const n=t.getBoundingClientRect();if(process.env.NODE_ENV!=="test"&&n.top===0&&n.left===0&&n.right===0&&n.bottom===0)return new Error(["MUI: The `anchorEl` prop provided to the component is invalid.","The anchor element should be part of the document layout.","Make sure the element is present in the document or that it's not display none."].join(` -`))}else if(!t||typeof t.getBoundingClientRect!="function"||Rf(t)&&t.contextElement!=null&&t.contextElement.nodeType!==1)return new Error(["MUI: The `anchorEl` prop provided to the component is invalid.","It should be an HTML element instance or a virtualElement ","(https://popper.js.org/docs/v2/virtual-elements/)."].join(` -`))}return null}),children:p.oneOfType([p.node,p.func]),container:p.oneOfType([vn,p.func]),direction:p.oneOf(["ltr","rtl"]),disablePortal:p.bool,keepMounted:p.bool,modifiers:p.arrayOf(p.shape({data:p.object,effect:p.func,enabled:p.bool,fn:p.func,name:p.any,options:p.object,phase:p.oneOf(["afterMain","afterRead","afterWrite","beforeMain","beforeRead","beforeWrite","main","read","write"]),requires:p.arrayOf(p.string),requiresIfExists:p.arrayOf(p.string)})),open:p.bool.isRequired,placement:p.oneOf(["auto-end","auto-start","auto","bottom-end","bottom-start","bottom","left-end","left-start","left","right-end","right-start","right","top-end","top-start","top"]),popperOptions:p.shape({modifiers:p.array,onFirstUpdate:p.func,placement:p.oneOf(["auto-end","auto-start","auto","bottom-end","bottom-start","bottom","left-end","left-start","left","right-end","right-start","right","top-end","top-start","top"]),strategy:p.oneOf(["absolute","fixed"])}),popperRef:Qs,slotProps:p.shape({root:p.oneOfType([p.func,p.object])}),slots:p.shape({root:p.elementType}),transition:p.bool});function Ci(){const e=ui(Ro);return process.env.NODE_ENV!=="production"&&$.useDebugValue(e),e[Oo]||e}function to(e,t){return to=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,o){return r.__proto__=o,r},to(e,t)}function If(e,t){e.prototype=Object.create(t.prototype),e.prototype.constructor=e,to(e,t)}const Ha={disabled:!1};var Mf=process.env.NODE_ENV!=="production"?p.oneOfType([p.number,p.shape({enter:p.number,exit:p.number,appear:p.number}).isRequired]):null;process.env.NODE_ENV!=="production"&&p.oneOfType([p.string,p.shape({enter:p.string,exit:p.string,active:p.string}),p.shape({enter:p.string,enterDone:p.string,enterActive:p.string,exit:p.string,exitDone:p.string,exitActive:p.string})]);const Ri=g.createContext(null);var $f=function(t){return t.scrollTop},un="unmounted",wt="exited",ft="entering",$t="entered",no="exiting",nt=function(e){If(t,e);function t(r,o){var s;s=e.call(this,r,o)||this;var i=o,l=i&&!i.isMounting?r.enter:r.appear,c;return s.appearStatus=null,r.in?l?(c=wt,s.appearStatus=ft):c=$t:r.unmountOnExit||r.mountOnEnter?c=un:c=wt,s.state={status:c},s.nextCallback=null,s}t.getDerivedStateFromProps=function(o,s){var i=o.in;return i&&s.status===un?{status:wt}:null};var n=t.prototype;return n.componentDidMount=function(){this.updateStatus(!0,this.appearStatus)},n.componentDidUpdate=function(o){var s=null;if(o!==this.props){var i=this.state.status;this.props.in?i!==ft&&i!==$t&&(s=ft):(i===ft||i===$t)&&(s=no)}this.updateStatus(!1,s)},n.componentWillUnmount=function(){this.cancelNextCallback()},n.getTimeouts=function(){var o=this.props.timeout,s,i,l;return s=i=l=o,o!=null&&typeof o!="number"&&(s=o.exit,i=o.enter,l=o.appear!==void 0?o.appear:i),{exit:s,enter:i,appear:l}},n.updateStatus=function(o,s){if(o===void 0&&(o=!1),s!==null)if(this.cancelNextCallback(),s===ft){if(this.props.unmountOnExit||this.props.mountOnEnter){var i=this.props.nodeRef?this.props.nodeRef.current:sn.findDOMNode(this);i&&$f(i)}this.performEnter(o)}else this.performExit();else this.props.unmountOnExit&&this.state.status===wt&&this.setState({status:un})},n.performEnter=function(o){var s=this,i=this.props.enter,l=this.context?this.context.isMounting:o,c=this.props.nodeRef?[l]:[sn.findDOMNode(this),l],d=c[0],u=c[1],f=this.getTimeouts(),w=l?f.appear:f.enter;if(!o&&!i||Ha.disabled){this.safeSetState({status:$t},function(){s.props.onEntered(d)});return}this.props.onEnter(d,u),this.safeSetState({status:ft},function(){s.props.onEntering(d,u),s.onTransitionEnd(w,function(){s.safeSetState({status:$t},function(){s.props.onEntered(d,u)})})})},n.performExit=function(){var o=this,s=this.props.exit,i=this.getTimeouts(),l=this.props.nodeRef?void 0:sn.findDOMNode(this);if(!s||Ha.disabled){this.safeSetState({status:wt},function(){o.props.onExited(l)});return}this.props.onExit(l),this.safeSetState({status:no},function(){o.props.onExiting(l),o.onTransitionEnd(i.exit,function(){o.safeSetState({status:wt},function(){o.props.onExited(l)})})})},n.cancelNextCallback=function(){this.nextCallback!==null&&(this.nextCallback.cancel(),this.nextCallback=null)},n.safeSetState=function(o,s){s=this.setNextCallback(s),this.setState(o,s)},n.setNextCallback=function(o){var s=this,i=!0;return this.nextCallback=function(l){i&&(i=!1,s.nextCallback=null,o(l))},this.nextCallback.cancel=function(){i=!1},this.nextCallback},n.onTransitionEnd=function(o,s){this.setNextCallback(s);var i=this.props.nodeRef?this.props.nodeRef.current:sn.findDOMNode(this),l=o==null&&!this.props.addEndListener;if(!i||l){setTimeout(this.nextCallback,0);return}if(this.props.addEndListener){var c=this.props.nodeRef?[this.nextCallback]:[i,this.nextCallback],d=c[0],u=c[1];this.props.addEndListener(d,u)}o!=null&&setTimeout(this.nextCallback,o)},n.render=function(){var o=this.state.status;if(o===un)return null;var s=this.props,i=s.children;s.in,s.mountOnEnter,s.unmountOnExit,s.appear,s.enter,s.exit,s.timeout,s.addEndListener,s.onEnter,s.onEntering,s.onEntered,s.onExit,s.onExiting,s.onExited,s.nodeRef;var l=ye(s,["children","in","mountOnEnter","unmountOnExit","appear","enter","exit","timeout","addEndListener","onEnter","onEntering","onEntered","onExit","onExiting","onExited","nodeRef"]);return g.createElement(Ri.Provider,{value:null},typeof i=="function"?i(o,l):g.cloneElement(g.Children.only(i),l))},t}(g.Component);nt.contextType=Ri;nt.propTypes=process.env.NODE_ENV!=="production"?{nodeRef:p.shape({current:typeof Element>"u"?p.any:function(e,t,n,r,o,s){var i=e[t];return p.instanceOf(i&&"ownerDocument"in i?i.ownerDocument.defaultView.Element:Element)(e,t,n,r,o,s)}}),children:p.oneOfType([p.func.isRequired,p.element.isRequired]).isRequired,in:p.bool,mountOnEnter:p.bool,unmountOnExit:p.bool,appear:p.bool,enter:p.bool,exit:p.bool,timeout:function(t){var n=Mf;t.addEndListener||(n=n.isRequired);for(var r=arguments.length,o=new Array(r>1?r-1:0),s=1;se.scrollTop;function Ya(e,t){var n,r;const{timeout:o,easing:s,style:i={}}=e;return{duration:(n=i.transitionDuration)!=null?n:typeof o=="number"?o:o[t.mode]||0,easing:(r=i.transitionTimingFunction)!=null?r:typeof s=="object"?s[t.mode]:s,delay:i.transitionDelay}}const Bf=["addEndListener","appear","children","easing","in","onEnter","onEntered","onEntering","onExit","onExited","onExiting","style","timeout","TransitionComponent"];function ro(e){return`scale(${e}, ${e**2})`}const Vf={entering:{opacity:1,transform:ro(1)},entered:{opacity:1,transform:"none"}},zr=typeof navigator<"u"&&/^((?!chrome|android).)*(safari|mobile)/i.test(navigator.userAgent)&&/(os |version\/)15(.|_)4/i.test(navigator.userAgent),zo=$.forwardRef(function(t,n){const{addEndListener:r,appear:o=!0,children:s,easing:i,in:l,onEnter:c,onEntered:d,onEntering:u,onExit:f,onExited:w,onExiting:b,style:x,timeout:m="auto",TransitionComponent:h=Df}=t,E=ye(t,Bf),I=cn(),C=$.useRef(),S=Ci(),v=$.useRef(null),_=yt(v,s.ref,n),V=X=>F=>{if(X){const te=v.current;F===void 0?X(te):X(te,F)}},U=V(u),j=V((X,F)=>{Af(X);const{duration:te,delay:se,easing:oe}=Ya({style:x,timeout:m,easing:i},{mode:"enter"});let y;m==="auto"?(y=S.transitions.getAutoHeightDuration(X.clientHeight),C.current=y):y=te,X.style.transition=[S.transitions.create("opacity",{duration:y,delay:se}),S.transitions.create("transform",{duration:zr?y:y*.666,delay:se,easing:oe})].join(","),c&&c(X,F)}),O=V(d),k=V(b),D=V(X=>{const{duration:F,delay:te,easing:se}=Ya({style:x,timeout:m,easing:i},{mode:"exit"});let oe;m==="auto"?(oe=S.transitions.getAutoHeightDuration(X.clientHeight),C.current=oe):oe=F,X.style.transition=[S.transitions.create("opacity",{duration:oe,delay:te}),S.transitions.create("transform",{duration:zr?oe:oe*.666,delay:zr?te:te||oe*.333,easing:se})].join(","),X.style.opacity=0,X.style.transform=ro(.75),f&&f(X)}),M=V(w),J=X=>{m==="auto"&&I.start(C.current||0,X),r&&r(v.current,X)};return a.jsx(h,R({appear:o,in:l,nodeRef:v,onEnter:j,onEntered:O,onEntering:U,onExit:D,onExited:M,onExiting:k,addEndListener:J,timeout:m==="auto"?null:m},E,{children:(X,F)=>$.cloneElement(s,R({style:R({opacity:0,transform:ro(.75),visibility:X==="exited"&&!l?"hidden":void 0},Vf[X],x,s.props.style),ref:_},F))}))});process.env.NODE_ENV!=="production"&&(zo.propTypes={addEndListener:p.func,appear:p.bool,children:Js.isRequired,easing:p.oneOfType([p.shape({enter:p.string,exit:p.string}),p.string]),in:p.bool,onEnter:p.func,onEntered:p.func,onEntering:p.func,onExit:p.func,onExited:p.func,onExiting:p.func,style:p.object,timeout:p.oneOfType([p.oneOf(["auto"]),p.number,p.shape({appear:p.number,enter:p.number,exit:p.number})])});zo.muiSupportAuto=!0;const Xa=zo,zf=["anchorEl","component","components","componentsProps","container","disablePortal","keepMounted","modifiers","open","placement","popperOptions","popperRef","transition","slots","slotProps"],Lf=In(Ti,{name:"MuiPopper",slot:"Root",overridesResolver:(e,t)=>t.root})({}),Oi=$.forwardRef(function(t,n){var r;const o=di(),s=_o({props:t,name:"MuiPopper"}),{anchorEl:i,component:l,components:c,componentsProps:d,container:u,disablePortal:f,keepMounted:w,modifiers:b,open:x,placement:m,popperOptions:h,popperRef:E,transition:I,slots:C,slotProps:S}=s,v=ye(s,zf),_=(r=C==null?void 0:C.root)!=null?r:c==null?void 0:c.Root,V=R({anchorEl:i,container:u,disablePortal:f,keepMounted:w,modifiers:b,open:x,placement:m,popperOptions:h,popperRef:E,transition:I},v);return a.jsx(Lf,R({as:l,direction:o==null?void 0:o.direction,slots:{root:_},slotProps:S??d},V,{ref:n}))});process.env.NODE_ENV!=="production"&&(Oi.propTypes={anchorEl:p.oneOfType([vn,p.object,p.func]),children:p.oneOfType([p.node,p.func]),component:p.elementType,components:p.shape({Root:p.elementType}),componentsProps:p.shape({root:p.oneOfType([p.func,p.object])}),container:p.oneOfType([vn,p.func]),disablePortal:p.bool,keepMounted:p.bool,modifiers:p.arrayOf(p.shape({data:p.object,effect:p.func,enabled:p.bool,fn:p.func,name:p.any,options:p.object,phase:p.oneOf(["afterMain","afterRead","afterWrite","beforeMain","beforeRead","beforeWrite","main","read","write"]),requires:p.arrayOf(p.string),requiresIfExists:p.arrayOf(p.string)})),open:p.bool.isRequired,placement:p.oneOf(["auto-end","auto-start","auto","bottom-end","bottom-start","bottom","left-end","left-start","left","right-end","right-start","right","top-end","top-start","top"]),popperOptions:p.shape({modifiers:p.array,onFirstUpdate:p.func,placement:p.oneOf(["auto-end","auto-start","auto","bottom-end","bottom-start","bottom","left-end","left-start","left","right-end","right-start","right","top-end","top-start","top"]),strategy:p.oneOf(["absolute","fixed"])}),popperRef:Qs,slotProps:p.shape({root:p.oneOfType([p.func,p.object])}),slots:p.shape({root:p.elementType}),sx:p.oneOfType([p.arrayOf(p.oneOfType([p.func,p.object,p.bool])),p.func,p.object]),transition:p.bool});const _i=Oi;function Ff(e){return ur("MuiTooltip",e)}const Gf=si("MuiTooltip",["popper","popperInteractive","popperArrow","popperClose","tooltip","tooltipArrow","touch","tooltipPlacementLeft","tooltipPlacementRight","tooltipPlacementTop","tooltipPlacementBottom","arrow"]),at=Gf,Uf=["arrow","children","classes","components","componentsProps","describeChild","disableFocusListener","disableHoverListener","disableInteractive","disableTouchListener","enterDelay","enterNextDelay","enterTouchDelay","followCursor","id","leaveDelay","leaveTouchDelay","onClose","onOpen","open","placement","PopperComponent","PopperProps","slotProps","slots","title","TransitionComponent","TransitionProps"];function qf(e){return Math.round(e*1e5)/1e5}const Hf=e=>{const{classes:t,disableInteractive:n,arrow:r,touch:o,placement:s}=e,i={popper:["popper",!n&&"popperInteractive",r&&"popperArrow"],tooltip:["tooltip",r&&"tooltipArrow",o&&"touch",`tooltipPlacement${Xe(s.split("-")[0])}`],arrow:["arrow"]};return No(i,Ff,t)},Yf=In(_i,{name:"MuiTooltip",slot:"Popper",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.popper,!n.disableInteractive&&t.popperInteractive,n.arrow&&t.popperArrow,!n.open&&t.popperClose]}})(({theme:e,ownerState:t,open:n})=>R({zIndex:(e.vars||e).zIndex.tooltip,pointerEvents:"none"},!t.disableInteractive&&{pointerEvents:"auto"},!n&&{pointerEvents:"none"},t.arrow&&{[`&[data-popper-placement*="bottom"] .${at.arrow}`]:{top:0,marginTop:"-0.71em","&::before":{transformOrigin:"0 100%"}},[`&[data-popper-placement*="top"] .${at.arrow}`]:{bottom:0,marginBottom:"-0.71em","&::before":{transformOrigin:"100% 0"}},[`&[data-popper-placement*="right"] .${at.arrow}`]:R({},t.isRtl?{right:0,marginRight:"-0.71em"}:{left:0,marginLeft:"-0.71em"},{height:"1em",width:"0.71em","&::before":{transformOrigin:"100% 100%"}}),[`&[data-popper-placement*="left"] .${at.arrow}`]:R({},t.isRtl?{left:0,marginLeft:"-0.71em"}:{right:0,marginRight:"-0.71em"},{height:"1em",width:"0.71em","&::before":{transformOrigin:"0 0"}})})),Xf=In("div",{name:"MuiTooltip",slot:"Tooltip",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.tooltip,n.touch&&t.touch,n.arrow&&t.tooltipArrow,t[`tooltipPlacement${Xe(n.placement.split("-")[0])}`]]}})(({theme:e,ownerState:t})=>R({backgroundColor:e.vars?e.vars.palette.Tooltip.bg:pi(e.palette.grey[700],.92),borderRadius:(e.vars||e).shape.borderRadius,color:(e.vars||e).palette.common.white,fontFamily:e.typography.fontFamily,padding:"4px 8px",fontSize:e.typography.pxToRem(11),maxWidth:300,margin:2,wordWrap:"break-word",fontWeight:e.typography.fontWeightMedium},t.arrow&&{position:"relative",margin:0},t.touch&&{padding:"8px 16px",fontSize:e.typography.pxToRem(14),lineHeight:`${qf(16/14)}em`,fontWeight:e.typography.fontWeightRegular},{[`.${at.popper}[data-popper-placement*="left"] &`]:R({transformOrigin:"right center"},t.isRtl?R({marginLeft:"14px"},t.touch&&{marginLeft:"24px"}):R({marginRight:"14px"},t.touch&&{marginRight:"24px"})),[`.${at.popper}[data-popper-placement*="right"] &`]:R({transformOrigin:"left center"},t.isRtl?R({marginRight:"14px"},t.touch&&{marginRight:"24px"}):R({marginLeft:"14px"},t.touch&&{marginLeft:"24px"})),[`.${at.popper}[data-popper-placement*="top"] &`]:R({transformOrigin:"center bottom",marginBottom:"14px"},t.touch&&{marginBottom:"24px"}),[`.${at.popper}[data-popper-placement*="bottom"] &`]:R({transformOrigin:"center top",marginTop:"14px"},t.touch&&{marginTop:"24px"})})),Wf=In("span",{name:"MuiTooltip",slot:"Arrow",overridesResolver:(e,t)=>t.arrow})(({theme:e})=>({overflow:"hidden",position:"absolute",width:"1em",height:"0.71em",boxSizing:"border-box",color:e.vars?e.vars.palette.Tooltip.bg:pi(e.palette.grey[700],.9),"&::before":{content:'""',margin:"auto",display:"block",width:"100%",height:"100%",backgroundColor:"currentColor",transform:"rotate(45deg)"}}));let Gn=!1;const Wa=new On;let an={x:0,y:0};function Un(e,t){return n=>{t&&t(n),e(n)}}const Pi=$.forwardRef(function(t,n){var r,o,s,i,l,c,d,u,f,w,b,x,m,h,E,I,C,S,v;const _=_o({props:t,name:"MuiTooltip"}),{arrow:V=!1,children:U,components:j={},componentsProps:O={},describeChild:k=!1,disableFocusListener:D=!1,disableHoverListener:M=!1,disableInteractive:J=!1,disableTouchListener:X=!1,enterDelay:F=100,enterNextDelay:te=0,enterTouchDelay:se=700,followCursor:oe=!1,id:y,leaveDelay:T=0,leaveTouchDelay:z=1500,onClose:L,onOpen:B,open:Y,placement:q="bottom",PopperComponent:H,PopperProps:G={},slotProps:K={},slots:Z={},title:ue,TransitionComponent:P=Xa,TransitionProps:xe}=_,A=ye(_,Uf),ve=$.isValidElement(U)?U:a.jsx("span",{children:U}),Fe=Ci(),lt=Fe.direction==="rtl",[Se,Dn]=$.useState(),[Ge,Et]=$.useState(null),ct=$.useRef(!1),jt=J||oe,Tt=cn(),Ct=cn(),dt=cn(),Kt=cn(),[An,Fo]=ti({controlled:Y,default:!1,name:"Tooltip",state:"open"});let Ke=An;if(process.env.NODE_ENV!=="production"){const{current:Q}=$.useRef(Y!==void 0);$.useEffect(()=>{Se&&Se.disabled&&!Q&&ue!==""&&Se.tagName.toLowerCase()==="button"&&console.error(["MUI: You are providing a disabled `button` child to the Tooltip component.","A disabled element does not fire events.","Tooltip needs to listen to the child element's events to display the title.","","Add a simple wrapper element, such as a `span`."].join(` -`))},[ue,Se,Q])}const kr=ei(y),Jt=$.useRef(),Bn=Jr(()=>{Jt.current!==void 0&&(document.body.style.WebkitUserSelect=Jt.current,Jt.current=void 0),Kt.clear()});$.useEffect(()=>Bn,[Bn]);const Go=Q=>{Wa.clear(),Gn=!0,Fo(!0),B&&!Ke&&B(Q)},Vn=Jr(Q=>{Wa.start(800+T,()=>{Gn=!1}),Fo(!1),L&&Ke&&L(Q),Tt.start(Fe.transitions.duration.shortest,()=>{ct.current=!1})}),Sr=Q=>{ct.current&&Q.type!=="touchstart"||(Se&&Se.removeAttribute("title"),Ct.clear(),dt.clear(),F||Gn&&te?Ct.start(Gn?te:F,()=>{Go(Q)}):Go(Q))},Uo=Q=>{Ct.clear(),dt.start(T,()=>{Vn(Q)})},{isFocusVisibleRef:qo,onBlur:el,onFocus:tl,ref:nl}=ni(),[,Ho]=$.useState(!1),Yo=Q=>{el(Q),qo.current===!1&&(Ho(!1),Uo(Q))},Xo=Q=>{Se||Dn(Q.currentTarget),tl(Q),qo.current===!0&&(Ho(!0),Sr(Q))},Wo=Q=>{ct.current=!0;const Oe=ve.props;Oe.onTouchStart&&Oe.onTouchStart(Q)},Ko=Sr,Jo=Uo,rl=Q=>{Wo(Q),dt.clear(),Tt.clear(),Bn(),Jt.current=document.body.style.WebkitUserSelect,document.body.style.WebkitUserSelect="none",Kt.start(se,()=>{document.body.style.WebkitUserSelect=Jt.current,Sr(Q)})},ol=Q=>{ve.props.onTouchEnd&&ve.props.onTouchEnd(Q),Bn(),dt.start(z,()=>{Vn(Q)})};$.useEffect(()=>{if(!Ke)return;function Q(Oe){(Oe.key==="Escape"||Oe.key==="Esc")&&Vn(Oe)}return document.addEventListener("keydown",Q),()=>{document.removeEventListener("keydown",Q)}},[Vn,Ke]);const al=yt(ve.ref,nl,Dn,n);!ue&&ue!==0&&(Ke=!1);const Er=$.useRef(),sl=Q=>{const Oe=ve.props;Oe.onMouseMove&&Oe.onMouseMove(Q),an={x:Q.clientX,y:Q.clientY},Er.current&&Er.current.update()},Zt={},jr=typeof ue=="string";k?(Zt.title=!Ke&&jr&&!M?ue:null,Zt["aria-describedby"]=Ke?kr:null):(Zt["aria-label"]=jr?ue:null,Zt["aria-labelledby"]=Ke&&!jr?kr:null);const $e=R({},Zt,A,ve.props,{className:ot(A.className,ve.props.className),onTouchStart:Wo,ref:al},oe?{onMouseMove:sl}:{});process.env.NODE_ENV!=="production"&&($e["data-mui-internal-clone-element"]=!0,$.useEffect(()=>{Se&&!Se.getAttribute("data-mui-internal-clone-element")&&console.error(["MUI: The `children` component of the Tooltip is not forwarding its props correctly.","Please make sure that props are spread on the same element that the ref is applied to."].join(` -`))},[Se]));const Qt={};X||($e.onTouchStart=rl,$e.onTouchEnd=ol),M||($e.onMouseOver=Un(Ko,$e.onMouseOver),$e.onMouseLeave=Un(Jo,$e.onMouseLeave),jt||(Qt.onMouseOver=Ko,Qt.onMouseLeave=Jo)),D||($e.onFocus=Un(Xo,$e.onFocus),$e.onBlur=Un(Yo,$e.onBlur),jt||(Qt.onFocus=Xo,Qt.onBlur=Yo)),process.env.NODE_ENV!=="production"&&ve.props.title&&console.error(["MUI: You have provided a `title` prop to the child of .",`Remove this title prop \`${ve.props.title}\` or the Tooltip component.`].join(` -`));const il=$.useMemo(()=>{var Q;let Oe=[{name:"arrow",enabled:!!Ge,options:{element:Ge,padding:4}}];return(Q=G.popperOptions)!=null&&Q.modifiers&&(Oe=Oe.concat(G.popperOptions.modifiers)),R({},G.popperOptions,{modifiers:Oe})},[Ge,G]),en=R({},_,{isRtl:lt,arrow:V,disableInteractive:jt,placement:q,PopperComponentProp:H,touch:ct.current}),Tr=Hf(en),Zo=(r=(o=Z.popper)!=null?o:j.Popper)!=null?r:Yf,Qo=(s=(i=(l=Z.transition)!=null?l:j.Transition)!=null?i:P)!=null?s:Xa,ea=(c=(d=Z.tooltip)!=null?d:j.Tooltip)!=null?c:Xf,ta=(u=(f=Z.arrow)!=null?f:j.Arrow)!=null?u:Wf,ll=dn(Zo,R({},G,(w=K.popper)!=null?w:O.popper,{className:ot(Tr.popper,G==null?void 0:G.className,(b=(x=K.popper)!=null?x:O.popper)==null?void 0:b.className)}),en),cl=dn(Qo,R({},xe,(m=K.transition)!=null?m:O.transition),en),dl=dn(ea,R({},(h=K.tooltip)!=null?h:O.tooltip,{className:ot(Tr.tooltip,(E=(I=K.tooltip)!=null?I:O.tooltip)==null?void 0:E.className)}),en),ul=dn(ta,R({},(C=K.arrow)!=null?C:O.arrow,{className:ot(Tr.arrow,(S=(v=K.arrow)!=null?v:O.arrow)==null?void 0:S.className)}),en);return a.jsxs($.Fragment,{children:[$.cloneElement(ve,$e),a.jsx(Zo,R({as:H??_i,placement:q,anchorEl:oe?{getBoundingClientRect:()=>({top:an.y,left:an.x,right:an.x,bottom:an.y,width:0,height:0})}:Se,popperRef:Er,open:Se?Ke:!1,id:kr,transition:!0},Qt,ll,{popperOptions:il,children:({TransitionProps:Q})=>a.jsx(Qo,R({timeout:Fe.transitions.duration.shorter},Q,cl,{children:a.jsxs(ea,R({},dl,{children:[ue,V?a.jsx(ta,R({},ul,{ref:Et})):null]}))}))}))]})});process.env.NODE_ENV!=="production"&&(Pi.propTypes={arrow:p.bool,children:Js.isRequired,classes:p.object,className:p.string,components:p.shape({Arrow:p.elementType,Popper:p.elementType,Tooltip:p.elementType,Transition:p.elementType}),componentsProps:p.shape({arrow:p.object,popper:p.object,tooltip:p.object,transition:p.object}),describeChild:p.bool,disableFocusListener:p.bool,disableHoverListener:p.bool,disableInteractive:p.bool,disableTouchListener:p.bool,enterDelay:p.number,enterNextDelay:p.number,enterTouchDelay:p.number,followCursor:p.bool,id:p.string,leaveDelay:p.number,leaveTouchDelay:p.number,onClose:p.func,onOpen:p.func,open:p.bool,placement:p.oneOf(["bottom-end","bottom-start","bottom","left-end","left-start","left","right-end","right-start","right","top-end","top-start","top"]),PopperComponent:p.elementType,PopperProps:p.object,slotProps:p.shape({arrow:p.object,popper:p.object,tooltip:p.object,transition:p.object}),slots:p.shape({arrow:p.elementType,popper:p.elementType,tooltip:p.elementType,transition:p.elementType}),sx:p.oneOfType([p.arrayOf(p.oneOfType([p.func,p.object,p.bool])),p.func,p.object]),title:p.node,TransitionComponent:p.elementType,TransitionProps:p.object});const Kf=Pi;function Ka(e,t,n){return e?a.jsx(Ie.ListItemIcon,{className:`papi-menu-icon-${n?"leading":"trailing"}`,children:a.jsx("img",{src:e,alt:`${n?"Leading":"Trailing"} icon for ${t}`})}):void 0}function Lo(e){const{onClick:t,label:n,tooltip:r,allowForLeadingIcons:o=!0,iconPathBefore:s=void 0,iconPathAfter:i=void 0,hasAutoFocus:l=!1,className:c,isDisabled:d=!1,isDense:u=!0,isSubMenuParent:f=!1,hasDisabledGutters:w=!1,hasDivider:b=!1,focusVisibleClassName:x,id:m,children:h}=e,E=a.jsx(Ie.MenuItem,{sx:{lineHeight:.8},autoFocus:l,className:c,disabled:d,dense:u,disableGutters:w,divider:b,focusVisibleClassName:x,onClick:t,id:m,children:n?a.jsxs(a.Fragment,{children:[Ka(s,n,!0),a.jsx(Ie.ListItemText,{primary:n,inset:!s&&o}),f?a.jsx(Ie.ListItemIcon,{className:"papi-menu-icon-trailing",children:a.jsx(fi,{})}):Ka(i,n,!1)]}):h});return r?a.jsx(Kf,{title:r,placement:"right",children:a.jsx("div",{children:E})}):E}function Ii(e){return Object.entries(e.groups).map(([n,r])=>({id:n,group:r}))}function Jf(e){const[t,n]=g.useState(void 0),{parentMenuItem:r,parentItemProps:o,menuDefinition:s}=e,i=d=>{n(d.currentTarget)},l=()=>{n(void 0)},c=()=>{let d=Ii(s).filter(u=>"menuItem"in u.group);if(!(r!=null&&r.id))throw new Error("A valid parent menu item is required for submenus.");return d=d.filter(u=>"menuItem"in u.group&&u.group.menuItem===r.id),a.jsx(Mi,{...e,includedGroups:d})};return a.jsxs(a.Fragment,{children:[a.jsx(Lo,{onClick:i,...o,isSubMenuParent:!0}),a.jsx(Ie.Menu,{anchorEl:t,open:!!t,onClose:l,anchorOrigin:{vertical:"top",horizontal:"right"},transformOrigin:{vertical:"top",horizontal:"left"},children:c()},r.id)]})}const Zf=(e,t)=>t.filter(o=>o.group===e).sort((o,s)=>(o.order||0)-(s.order||0));function Mi(e){const{menuDefinition:t,onClick:n,commandHandler:r,includedGroups:o}=e,{items:s,allowForLeadingIcons:i}=g.useMemo(()=>{const u=o&&o.length>0?o:Ii(t).filter(x=>!("menuItem"in x.group)),f=Object.values(u).sort((x,m)=>(x.group.order||0)-(m.group.order||0)),w=[];f.forEach(x=>{Zf(x.id,t.items).forEach(m=>w.push({item:m,isLastItemInGroup:!1})),w.length>0&&(w[w.length-1].isLastItemInGroup=!0)}),w.length>0&&(w[w.length-1].isLastItemInGroup=!1);const b=w.some(x=>"iconPathBefore"in x.item&&x.item.iconPathBefore);return{items:w,allowForLeadingIcons:b}},[o,t]),l=({item:u,isLastItemInGroup:f})=>({className:"papi-menu-item",label:u.label,tooltip:u.tooltip,iconPathBefore:"iconPathBefore"in u?u.iconPathBefore:void 0,iconPathAfter:"iconPathAfter"in u?u.iconPathAfter:void 0,hasDivider:f,allowForLeadingIcons:i}),[c]=s;if(!c)return a.jsx("div",{});const d=c.item.group;return a.jsx("div",{role:"menu","aria-label":d,children:s.map((u,f)=>{const{item:w}=u,b=l(u);if("command"in w){const x=w.group+f;return a.jsx(Lo,{onClick:m=>{n==null||n(m),r(w)},...b},x)}return a.jsx(Jf,{parentMenuItem:w,parentItemProps:b,...e},d+w.id)})},d)}function Qf(e){const{menuDefinition:t,columnId:n}=e;let s=Object.entries(t.groups).map(([i,l])=>({id:i,group:l})).filter(i=>"column"in i.group);return n&&"columns"in t&&t.columns[n]&&(s=s.filter(i=>"column"in i.group&&i.group.column===n)),a.jsx(Mi,{...e,includedGroups:s})}function em({commandHandler:e,menuDefinition:t,id:n,metadata:r,onClick:o,className:s}){return a.jsxs(Ie.Grid,{id:n,item:!0,xs:"auto",role:"menu","aria-label":n,className:`papi-menu-column ${s??""}`,children:[a.jsx("h3",{"aria-label":r.label,className:`papi-menu-column-header ${s??""}`,children:r.label}),a.jsx(Ie.List,{id:n,dense:!0,className:s??"",children:a.jsx(Qf,{commandHandler:e,menuDefinition:t,columnId:n,onClick:o})})]})}function $i({commandHandler:e,className:t,multiColumnMenu:n,id:r}){const{columns:o}=n,s=g.useMemo(()=>{const i=new Map;return Object.getOwnPropertyNames(o).forEach(l=>{if(l==="isExtensible")return;const c=l,d=o[c];typeof d=="object"&&typeof d.order=="number"&&!Number.isNaN(d.order)?i.set(d.order,{id:c,metadata:d}):console.warn(`Property ${l} (${typeof d}) on menu ${r} is not a valid column and is being ignored. This might indicate data corruption`)}),Array.from(i.values()).sort((l,c)=>(l.metadata.order||0)-(c.metadata.order||0))},[o,r]);return a.jsx(Ie.Grid,{container:!0,spacing:0,className:`papi-multi-column-menu ${t??""}`,columns:s.length,role:"menu","aria-label":"GridMenu",id:r,children:s.map((i,l)=>a.jsx(em,{commandHandler:e,menuDefinition:n,...i,className:t},l))})}function tm(e){return{preserveValue:!0,...e}}const nr=(e,t,n={})=>{const r=g.useRef(t);r.current=t;const o=g.useRef(n);o.current=tm(o.current);const[s,i]=g.useState(()=>r.current),[l,c]=g.useState(!0);return g.useEffect(()=>{let d=!0;return c(!!e),(async()=>{if(e){const u=await e();d&&(i(()=>u),c(!1))}})(),()=>{d=!1,o.current.preserveValue||i(()=>r.current)}},[e]),[s,l]},nm=wi(a.jsx("path",{d:"M3 18h18v-2H3zm0-5h18v-2H3zm0-7v2h18V6z"}),"Menu");function Di({menuProvider:e,normalMenu:t,fullMenu:n,commandHandler:r,containerRef:o,className:s,ariaLabelPrefix:i,children:l}){const[c,d]=g.useState(!1),[u,f]=g.useState(!1),w=g.useCallback(()=>{c&&d(!1),f(!1)},[c]),b=g.useCallback(S=>{S.stopPropagation(),d(v=>{const _=!v;return _&&S.shiftKey?f(!0):_||f(!1),_})},[]),x=g.useCallback(S=>(w(),r(S)),[r,w]),[m,h]=g.useState({top:1,left:1});g.useEffect(()=>{if(c){const S=o==null?void 0:o.current;if(S){const v=S.getBoundingClientRect(),_=window.scrollY,V=window.scrollX,U=v.top+_+S.clientHeight,j=v.left+V;h({top:U,left:j})}}},[c,o]);const[E]=nr(g.useCallback(async()=>(e==null?void 0:e(!1))??t,[e,t,c]),t),[I]=nr(g.useCallback(async()=>(e==null?void 0:e(!0))??n??E,[e,n,E,c]),n??E),C=u&&I?I:E;return a.jsxs(a.Fragment,{children:[a.jsx(Ie.IconButton,{sx:{paddingTop:0,paddingBottom:0},edge:"start",className:`papi-menuButton ${s??""}`,color:"inherit","aria-label":`${i??""} menu button`,onClick:b,children:l??a.jsx(nm,{})}),a.jsx(Ie.Drawer,{className:`papi-menu-drawer ${s??""}`,anchor:"left",variant:"temporary",open:c,onClose:w,PaperProps:{className:"papi-menu-drawer-paper",style:{top:m.top,left:m.left}},children:C?a.jsx($i,{className:s,id:`${i??""} main menu`,commandHandler:x,multiColumnMenu:C}):void 0})]})}function rm({id:e,label:t,isDisabled:n=!1,tooltip:r,isTooltipSuppressed:o=!1,adjustMarginToAlignToEdge:s=!1,size:i="medium",className:l,onClick:c,children:d}){return a.jsx(Ie.IconButton,{id:e,disabled:n,edge:s,size:i,"aria-label":t,title:o?void 0:r??t,className:`papi-icon-button ${l??""}`,onClick:c,children:d})}const Wt=g.forwardRef(({className:e,...t},n)=>a.jsx(ee.LoaderCircle,{size:35,className:N("tw-animate-spin",e),...t,ref:n}));Wt.displayName="Spinner";function om({id:e,isDisabled:t=!1,hasError:n=!1,isFullWidth:r=!1,helperText:o,label:s,placeholder:i,isRequired:l=!1,className:c,defaultValue:d,value:u,onChange:f,onFocus:w,onBlur:b}){return a.jsxs("div",{className:N("tw-inline-grid tw-items-center tw-gap-1.5",{"tw-w-full":r}),children:[a.jsx(Ue,{htmlFor:e,className:N({"tw-text-red-600":n,"tw-hidden":!s}),children:`${s}${l?"*":""}`}),a.jsx(St,{id:e,disabled:t,placeholder:i,required:l,className:N(c,{"tw-border-red-600":n}),defaultValue:d,value:u,onChange:f,onFocus:w,onBlur:b}),a.jsx("p",{className:N({"tw-hidden":!o}),children:o})]})}function am({menuProvider:e,commandHandler:t,className:n,id:r,children:o}){const s=g.useRef(void 0);return a.jsx("div",{ref:s,style:{position:"relative"},children:a.jsx(Ie.AppBar,{position:"static",id:r,children:a.jsxs(Ie.Toolbar,{className:N("tw-bg-muted tw-text-muted-foreground",n),variant:"dense",children:[e?a.jsx(Di,{commandHandler:t,containerRef:s,menuProvider:e}):void 0,o?a.jsx("div",{className:"papi-toolbar-children",children:o}):void 0]})})})}const sm=kn.cva("tw-relative tw-w-full tw-rounded-lg tw-border tw-p-4 [&>svg~*]:tw-pl-7 [&>svg+div]:tw-translate-y-[-3px] [&>svg]:tw-absolute [&>svg]:tw-left-4 [&>svg]:tw-top-4 [&>svg]:tw-text-foreground",{variants:{variant:{default:"tw-bg-background tw-text-foreground",destructive:"tw-border-destructive/50 tw-text-destructive dark:tw-border-destructive [&>svg]:tw-text-destructive"}},defaultVariants:{variant:"default"}}),Ai=g.forwardRef(({className:e,variant:t,...n},r)=>a.jsx("div",{ref:r,role:"alert",className:N(sm({variant:t}),e),...n}));Ai.displayName="Alert";const Bi=g.forwardRef(({className:e,...t},n)=>a.jsxs("h5",{ref:n,className:N("tw-mb-1 tw-font-medium tw-leading-none tw-tracking-tight",e),...t,children:[t.children," "]}));Bi.displayName="AlertTitle";const Vi=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,className:N("tw-text-sm [&_p]:tw-leading-relaxed",e),...t}));Vi.displayName="AlertDescription";const zi=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,className:N("pr-twp tw-rounded-lg tw-border tw-bg-card tw-text-card-foreground tw-shadow-sm",e),...t}));zi.displayName="Card";const Li=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,className:N("pr-twp tw-flex tw-flex-col tw-space-y-1.5 tw-p-6",e),...t}));Li.displayName="CardHeader";const Fi=g.forwardRef(({className:e,...t},n)=>a.jsx("h3",{ref:n,className:N("pr-twp tw-text-2xl tw-font-semibold tw-leading-none tw-tracking-tight",e),...t,children:t.children}));Fi.displayName="CardTitle";const Gi=g.forwardRef(({className:e,...t},n)=>a.jsx("p",{ref:n,className:N("pr-twp tw-text-sm tw-text-muted-foreground",e),...t}));Gi.displayName="CardDescription";const Ui=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,className:N("pr-twp tw-p-6 tw-pt-0",e),...t}));Ui.displayName="CardContent";const qi=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,className:N("pr-twp tw-flex tw-items-center tw-p-6 tw-pt-0",e),...t}));qi.displayName="CardFooter";function im({...e}){return a.jsx(Za.Toaster,{className:"tw-toaster tw-group",toastOptions:{classNames:{toast:"group toast group-[.toaster]:bg-background group-[.toaster]:text-foreground group-[.toaster]:border-border group-[.toaster]:shadow-lg",description:"group-[.toast]:text-muted-foreground",actionButton:"group-[.toast]:bg-primary group-[.toast]:text-primary-foreground",cancelButton:"group-[.toast]:bg-muted group-[.toast]:text-muted-foreground"}},...e})}const Hi=g.forwardRef(({className:e,...t},n)=>a.jsxs(ln.Root,{ref:n,className:N("pr-twp tw-relative tw-flex tw-w-full tw-touch-none tw-select-none tw-items-center",e),...t,children:[a.jsx(ln.Track,{className:"tw-relative tw-h-2 tw-w-full tw-grow tw-overflow-hidden tw-rounded-full tw-bg-secondary",children:a.jsx(ln.Range,{className:"tw-absolute tw-h-full tw-bg-primary"})}),a.jsx(ln.Thumb,{className:"tw-block tw-h-5 tw-w-5 tw-rounded-full tw-border-2 tw-border-primary tw-bg-background tw-ring-offset-background tw-transition-colors focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50"})]}));Hi.displayName=ln.Root.displayName;const Yi=g.forwardRef(({className:e,...t},n)=>a.jsx(Ur.Root,{className:N("tw-peer pr-twp tw-inline-flex tw-h-6 tw-w-11 tw-shrink-0 tw-cursor-pointer tw-items-center tw-rounded-full tw-border-2 tw-border-transparent tw-transition-colors focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 focus-visible:tw-ring-offset-background disabled:tw-cursor-not-allowed disabled:tw-opacity-50 data-[state=checked]:tw-bg-primary data-[state=unchecked]:tw-bg-input",e),...t,ref:n,children:a.jsx(Ur.Thumb,{className:N("pr-twp tw-pointer-events-none tw-block tw-h-5 tw-w-5 tw-rounded-full tw-bg-background tw-shadow-lg tw-ring-0 tw-transition-transform data-[state=checked]:tw-translate-x-5 data-[state=unchecked]:tw-translate-x-0")})}));Yi.displayName=Ur.Root.displayName;const lm=Re.Root,Xi=g.forwardRef(({className:e,...t},n)=>a.jsx(Re.List,{ref:n,className:N("tw-inline-flex tw-h-10 tw-items-center tw-justify-center tw-rounded-md tw-bg-muted tw-p-1 tw-text-muted-foreground",e),...t}));Xi.displayName=Re.List.displayName;const Wi=g.forwardRef(({className:e,...t},n)=>a.jsx(Re.Trigger,{ref:n,className:N("tw-inline-flex tw-items-center tw-justify-center tw-whitespace-nowrap tw-rounded-sm tw-px-3 tw-py-1.5 tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-all hover:tw-text-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50 data-[state=active]:tw-bg-background data-[state=active]:tw-text-foreground data-[state=active]:tw-shadow-sm",e),...t}));Wi.displayName=Re.Trigger.displayName;const Ki=g.forwardRef(({className:e,...t},n)=>a.jsx(Re.Content,{ref:n,className:N("tw-mt-2 tw-ring-offset-background focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2",e),...t}));Ki.displayName=Re.Content.displayName;function cm({isInstalling:e,handleClick:t,buttonText:n,className:r,...o}){return a.jsx(fe,{className:N("tw-h-8 tw-rounded-md tw-text-white tw-transition tw-duration-300 tw-ease-in-out hover:tw-bg-blue-700",{"tw-cursor-not-allowed tw-bg-blue-700":e,"tw-bg-blue-600":!e,"tw-bg-white tw-text-blue-600 hover:tw-text-white":!n,"tw-w-20":n},r),onClick:t,...o,children:e?a.jsx(Wt,{size:15}):a.jsxs(a.Fragment,{children:[a.jsx(ee.Download,{size:25,className:N("tw-h-4 tw-w-4",{"tw-mr-1":n})}),n]})})}function dm({isEnabling:e,handleClick:t,className:n,...r}){return a.jsx(fe,{className:N("tw-h-8 tw-rounded-md tw-bg-blue-600 tw-px-4 tw-text-white tw-transition tw-duration-300 tw-ease-in-out hover:tw-bg-blue-700",{"tw-cursor-not-allowed tw-bg-blue-700":e},n),onClick:t,...r,children:e?a.jsxs(a.Fragment,{children:[a.jsx(Wt,{size:15,className:"tw-mr-1 tw-text-white"}),"Enabling..."]}):"Enable"})}function um({isDisabling:e,handleClick:t,className:n,...r}){return a.jsx(fe,{className:N("tw-h-8 tw-rounded-md tw-bg-gray-300 tw-text-black tw-transition tw-duration-300 tw-ease-in-out hover:tw-bg-gray-400",{"tw-cursor-not-allowed tw-bg-gray-400":e},n),onClick:t,...r,children:e?a.jsxs(a.Fragment,{children:[a.jsx(Wt,{size:15,className:"tw-mr-1 tw-text-black"}),"Disabling..."]}):"Disable"})}function pm({isUpdating:e,handleClick:t,className:n,...r}){return a.jsx(fe,{className:N("tw-h-8 tw-rounded-md tw-bg-blue-600 tw-px-4 tw-text-white tw-transition tw-duration-300 tw-ease-in-out hover:tw-bg-blue-700 hover:tw-text-white",{"tw-cursor-not-allowed tw-bg-blue-700":e},n),onClick:t,...r,children:e?a.jsxs(a.Fragment,{children:[a.jsx(Wt,{size:15,className:"tw-mr-1 tw-text-white"}),"Updating..."]}):"Update"})}function wm({id:e,markdown:t,className:n,anchorTarget:r}){const o=g.useMemo(()=>({overrides:{a:{props:{target:r}}}}),[r]);return a.jsx("div",{id:e,className:N("pr-twp tw-prose",n),children:a.jsx(jl,{options:o,children:t})})}const Ji=g.forwardRef((e,t)=>a.jsxs(fe,{ref:t,className:"tw-rounded-md tw-border tw-border-dashed tw-border-gray-400 tw-bg-white tw-px-4 tw-py-2 tw-text-black tw-transition tw-duration-300 tw-ease-in-out hover:tw-border-blue-600 hover:tw-bg-white hover:tw-text-blue-600",...e,children:[a.jsx(ee.Filter,{size:16,className:"tw-mr-2 tw-h-4 tw-w-4 tw-text-gray-700 hover:tw-text-blue-600"}),"Filter",a.jsx(ee.ChevronDown,{size:16,className:"tw-ml-2 tw-h-4 tw-w-4 tw-text-gray-700 hover:tw-text-blue-600"})]}));var Zi=(e=>(e[e.Check=0]="Check",e[e.Radio=1]="Radio",e))(Zi||{});function fm({id:e,groups:t}){return a.jsx("div",{id:e,children:a.jsxs(or,{children:[a.jsx(io,{asChild:!0,children:a.jsx(Ji,{})}),a.jsx(En,{children:t.map(n=>a.jsxs("div",{children:[a.jsx(Xt,{children:n.label}),a.jsx(ls,{children:n.items.map(r=>a.jsx("div",{children:r.itemType===0?a.jsx(ar,{onClick:r.onClick,children:r.label}):a.jsx(co,{onClick:r.onClick,value:r.label,children:r.label})},r.label))}),a.jsx(jn,{})]},n.label))})]})})}function mm({id:e,message:t}){return a.jsx("div",{id:e,className:"tw-mb-20 tw-mt-20 tw-flex tw-items-center tw-justify-center",children:a.jsx("div",{className:"tw-w-3/4 tw-rounded-lg tw-bg-gray-100 tw-p-8 tw-text-center",children:a.jsx("p",{className:"tw-text-lg tw-text-gray-800",children:t})})})}function hm({id:e,category:t,downloads:n,languages:r,moreInfoUrl:o}){const s=new W.NumberFormat("en",{notation:"compact",compactDisplay:"short"}).format(Object.values(n).reduce((l,c)=>l+c,0)),i=()=>{window.scrollTo(0,document.body.scrollHeight)};return a.jsxs("div",{id:e,className:"tw-flex tw-flex-wrap tw-items-start tw-space-x-4 tw-border-b tw-border-t tw-bg-white tw-pb-4 tw-pt-4",children:[a.jsxs("div",{className:"tw-flex tw-flex-col tw-items-center",children:[a.jsx("div",{className:"tw-flex tw-items-center tw-rounded-md tw-bg-gray-100 tw-px-2 tw-py-1",children:a.jsx("span",{className:"tw-text-xs tw-font-semibold tw-text-gray-700",children:t})}),a.jsx("span",{className:"tw-text-xs tw-text-gray-500",children:"CATEGORY"})]}),a.jsx("div",{className:"tw-mx-2 tw-h-10 tw-border-l tw-border-gray-300"}),a.jsxs("div",{className:"tw-flex tw-flex-col tw-items-center",children:[a.jsxs("div",{className:"tw-flex tw-items-center tw-rounded-md tw-bg-gray-100 tw-px-2 tw-py-1",children:[a.jsx(ee.User,{className:"tw-mr-1 tw-h-4 tw-w-4"}),a.jsx("span",{className:"tw-text-xs tw-font-semibold tw-text-gray-700",children:s})]}),a.jsx("span",{className:"tw-text-xs tw-text-gray-500",children:"USERS"})]}),a.jsx("div",{className:"tw-mx-2 tw-h-10 tw-border-l tw-border-gray-300"}),a.jsxs("div",{className:"tw-flex tw-flex-col tw-items-center",children:[a.jsx("div",{className:"tw-flex tw-items-center",children:r.slice(0,3).map(l=>a.jsx("span",{className:"tw-ml-1 tw-rounded-md tw-bg-gray-100 tw-px-2 tw-py-1 tw-text-xs tw-font-semibold tw-text-gray-700",children:l.toUpperCase()},l))}),r.length>3&&a.jsxs("button",{type:"button",onClick:()=>i(),className:"tw-text-xs tw-text-gray-500 tw-underline",children:["+",r.length-3," more languages"]})]}),a.jsx("div",{className:"tw-mx-2 tw-h-10 tw-border-l tw-border-gray-300"}),a.jsxs("div",{className:"tw-ml-auto tw-flex tw-flex-col tw-space-y-2",children:[a.jsxs("a",{href:o,target:"_blank",rel:"noreferrer",className:"tw-flex tw-items-center tw-text-xs tw-font-semibold tw-text-gray-500 tw-underline",children:["Website",a.jsx(ee.Link,{className:"tw-ml-1 tw-inline tw-h-4 tw-w-4"})]}),a.jsxs("a",{href:"https://example.com",target:"_blank",rel:"noreferrer",className:"tw-flex tw-items-center tw-text-xs tw-font-semibold tw-text-gray-500 tw-underline",children:["Support",a.jsx(ee.CircleHelp,{className:"tw-ml-1 tw-inline tw-h-4 tw-w-4"})]})]})]})}function Qi({id:e,versionHistory:t}){const[n,r]=g.useState(!1),o=new Date;function s(l){const c=new Date(l),d=new Date(o.getTime()-c.getTime()),u=d.getUTCFullYear()-1970,f=d.getUTCMonth(),w=d.getUTCDate()-1;let b="";return u>0?b=`${u.toString()} year${u===1?"":"s"} ago`:f>0?b=`${f.toString()} month${f===1?"":"s"} ago`:w===0?b="today":b=`${w.toString()} day${w===1?"":"s"} ago`,b}const i=Object.entries(t).sort((l,c)=>c[0].localeCompare(l[0]));return a.jsxs("div",{id:e,children:[a.jsx("h3",{className:"tw-text-md tw-font-semibold",children:"What`s New"}),a.jsx("ul",{className:"tw-list-disc tw-pl-5 tw-pr-4 tw-text-xs tw-text-gray-600",children:(n?i:i.slice(0,5)).map(l=>a.jsxs("div",{className:"tw-mt-3 tw-flex tw-justify-between",children:[a.jsx("div",{className:"tw-text-gray-600",children:a.jsx("li",{className:"tw-prose tw-text-xs",children:a.jsx("span",{children:l[1].description})})}),a.jsxs("div",{className:"tw-justify-end tw-text-right",children:[a.jsxs("div",{children:["Version ",l[0]]}),a.jsx("div",{children:s(l[1].date)})]})]},l[0]))}),i.length>5&&a.jsx("button",{type:"button",onClick:()=>r(!n),className:"tw-text-xs tw-text-gray-500 tw-underline",children:n?"Show Less Version History":"Show All Version History"})]})}function gm({id:e,publisherDisplayName:t,fileSize:n,locales:r,versionHistory:o}){const s=g.useMemo(()=>W.formatBytes(n),[n]),l=(c=>{const d=new Intl.DisplayNames(navigator.language,{type:"language"});return c.map(u=>d.of(u))})(r);return a.jsx("div",{id:e,className:"tw-border-t tw-pb-4 tw-pt-4",children:a.jsxs("div",{className:"tw-md:flex-row tw-md:space-x-8 tw-flex tw-flex-col tw-space-x-0",children:[a.jsx(Qi,{versionHistory:o}),a.jsx("div",{className:"tw-md:border-t-0 tw-md:border-l tw-md-h-auto tw-md-ml-8 tw-mt-4 tw-border-t tw-border-gray-300"}),a.jsxs("div",{className:"tw-md:mt-0 tw-mt-4 tw-flex-1 tw-space-y-3",children:[a.jsx("h2",{className:"tw-text-md tw-font-semibold",children:"Information"}),a.jsxs("div",{className:"tw-flex tw-items-start tw-justify-between tw-pr-4 tw-text-xs tw-text-gray-600",children:[a.jsxs("p",{className:"tw-flex tw-flex-col tw-justify-start",children:[a.jsx("span",{className:"tw-mb-2",children:"Publisher"}),a.jsx("span",{className:"tw-font-semibold",children:t}),a.jsx("span",{className:"tw-mb-2 tw-mt-4",children:"Size"}),a.jsx("span",{className:"tw-font-semibold",children:s})]}),a.jsx("div",{className:"tw-flex tw-w-3/4 tw-items-center tw-justify-between tw-text-xs tw-text-gray-600",children:a.jsxs("p",{className:"tw-flex tw-flex-col tw-justify-start",children:[a.jsx("span",{className:"tw-mb-2",children:"Languages"}),a.jsx("span",{className:"tw-font-semibold",children:l.join(", ")})]})})]})]})]})})}const bm=(e,t)=>{g.useEffect(()=>{if(!e)return()=>{};const n=e(t);return()=>{n()}},[e,t])},Lr=()=>!1,vm=(e,t)=>{const[n]=nr(g.useCallback(async()=>{if(!e)return Lr;const r=await Promise.resolve(e(t));return async()=>r()},[t,e]),Lr,{preserveValue:!1});g.useEffect(()=>()=>{n!==Lr&&n()},[n])};Object.defineProperty(exports,"sonner",{enumerable:!0,get:()=>Za.toast});exports.Alert=Ai;exports.AlertDescription=Vi;exports.AlertTitle=Bi;exports.BOOK_SELECTOR_STRING_KEYS=pc;exports.BookChapterControl=tc;exports.BookSelectionMode=ys;exports.BookSelector=wc;exports.Button=fe;exports.Card=zi;exports.CardContent=Ui;exports.CardDescription=Gi;exports.CardFooter=qi;exports.CardHeader=Li;exports.CardTitle=Fi;exports.ChapterRangeSelector=xs;exports.Checkbox=sr;exports.Checklist=sd;exports.ComboBox=Wn;exports.DataTable=Ts;exports.DisableButton=um;exports.DropdownMenu=or;exports.DropdownMenuCheckboxItem=ar;exports.DropdownMenuContent=En;exports.DropdownMenuGroup=ls;exports.DropdownMenuItem=lo;exports.DropdownMenuItemType=Zi;exports.DropdownMenuLabel=Xt;exports.DropdownMenuPortal=Fl;exports.DropdownMenuRadioGroup=Ul;exports.DropdownMenuRadioItem=co;exports.DropdownMenuSeparator=jn;exports.DropdownMenuShortcut=us;exports.DropdownMenuSub=Gl;exports.DropdownMenuSubContent=ds;exports.DropdownMenuSubTrigger=cs;exports.DropdownMenuTrigger=io;exports.EnableButton=dm;exports.FilterButton=Ji;exports.FilterDropdown=fm;exports.Footer=gm;exports.GridMenu=$i;exports.HamburgerMenuButton=Di;exports.INVENTORY_STRING_KEYS=Nc;exports.IconButton=rm;exports.Input=St;exports.InstallButton=cm;exports.Inventory=Ec;exports.Label=Ue;exports.MarkdownRenderer=wm;exports.MenuItem=Lo;exports.MoreInfo=hm;exports.NavigationContentSearch=jc;exports.NoExtensionsFound=mm;exports.RadioGroup=uo;exports.RadioGroupItem=Xn;exports.ScriptureResultsViewer=td;exports.ScrollGroupSelector=nd;exports.SearchBar=mo;exports.Select=At;exports.SelectContent=vt;exports.SelectGroup=Ns;exports.SelectItem=De;exports.SelectLabel=ks;exports.SelectScrollDownButton=wo;exports.SelectScrollUpButton=po;exports.SelectSeparator=Ss;exports.SelectTrigger=bt;exports.SelectValue=Bt;exports.Separator=lr;exports.SettingsList=rd;exports.SettingsListHeader=ad;exports.SettingsListItem=od;exports.SettingsSidebar=Gs;exports.SettingsSidebarContentSearch=Yc;exports.Slider=Hi;exports.Sonner=im;exports.Spinner=Wt;exports.Switch=Yi;exports.Table=Tn;exports.TableBody=Rn;exports.TableCaption=js;exports.TableCell=xt;exports.TableFooter=Es;exports.TableHead=Vt;exports.TableHeader=Cn;exports.TableRow=Ze;exports.Tabs=lm;exports.TabsContent=Ki;exports.TabsList=Xi;exports.TabsTrigger=Wi;exports.TextField=om;exports.ToggleGroup=fo;exports.ToggleGroupItem=wn;exports.Toolbar=am;exports.UpdateButton=pm;exports.VersionHistory=Qi;exports.VerticalTabs=ho;exports.VerticalTabsContent=bo;exports.VerticalTabsList=go;exports.VerticalTabsTrigger=Is;exports.buttonVariants=ps;exports.cn=N;exports.getBookNumFromId=Rs;exports.getLinesFromUSFM=Cs;exports.getNumberFromUSFM=qr;exports.getStatusForItem=Os;exports.inventoryCountColumn=xc;exports.inventoryItemColumn=bc;exports.inventoryStatusColumn=yc;exports.useEvent=bm;exports.useEventAsync=vm;exports.usePromise=nr;function xm(e,t="top"){if(!e||typeof document>"u")return;const n=document.head||document.querySelector("head"),r=n.querySelector(":first-child"),o=document.createElement("style");o.appendChild(document.createTextNode(e)),t==="top"&&r?n.insertBefore(o,r):n.appendChild(o)}xm(`*, ::before, ::after { +} });`:zt(12,h?` (${h})`:"",JSON.stringify(m.main)));return Oa(m,"light",I,r),Oa(m,"dark",C,r),m.contrastText||(m.contrastText=f(m.main)),m},b={dark:Vr,light:Ra};return process.env.NODE_ENV!=="production"&&(b[t]||console.error(`MUI: The palette mode \`${t}\` is not supported.`)),Qe(R({common:R({},xn),mode:t,primary:w({color:s,name:"primary"}),secondary:w({color:i,name:"secondary",mainShade:"A400",lightShade:"A200",darkShade:"A700"}),error:w({color:l,name:"error"}),warning:w({color:u,name:"warning"}),info:w({color:c,name:"info"}),success:w({color:d,name:"success"}),grey:pp,contrastThreshold:n,getContrastText:f,augmentColor:w,tonalOffset:r},b[t]),o)}const Tp=["fontFamily","fontSize","fontWeightLight","fontWeightRegular","fontWeightMedium","fontWeightBold","htmlFontSize","allVariants","pxToRem"];function Cp(e){return Math.round(e*1e5)/1e5}const _a={textTransform:"uppercase"},Pa='"Roboto", "Helvetica", "Arial", sans-serif';function Rp(e,t){const n=typeof t=="function"?t(e):t,{fontFamily:r=Pa,fontSize:o=14,fontWeightLight:s=300,fontWeightRegular:i=400,fontWeightMedium:l=500,fontWeightBold:c=700,htmlFontSize:d=16,allVariants:u,pxToRem:f}=n,w=ye(n,Tp);process.env.NODE_ENV!=="production"&&(typeof o!="number"&&console.error("MUI: `fontSize` is required to be a number."),typeof d!="number"&&console.error("MUI: `htmlFontSize` is required to be a number."));const b=o/14,x=f||(E=>`${E/d*b}rem`),m=(E,I,C,S,v)=>R({fontFamily:r,fontWeight:E,fontSize:x(I),lineHeight:C},r===Pa?{letterSpacing:`${Cp(S/I)}em`}:{},v,u),h={h1:m(s,96,1.167,-1.5),h2:m(s,60,1.2,-.5),h3:m(i,48,1.167,0),h4:m(i,34,1.235,.25),h5:m(i,24,1.334,0),h6:m(l,20,1.6,.15),subtitle1:m(i,16,1.75,.15),subtitle2:m(l,14,1.57,.1),body1:m(i,16,1.5,.15),body2:m(i,14,1.43,.15),button:m(l,14,1.75,.4,_a),caption:m(i,12,1.66,.4),overline:m(i,12,2.66,1,_a),inherit:{fontFamily:"inherit",fontWeight:"inherit",fontSize:"inherit",lineHeight:"inherit",letterSpacing:"inherit"}};return Qe(R({htmlFontSize:d,pxToRem:x,fontFamily:r,fontSize:o,fontWeightLight:s,fontWeightRegular:i,fontWeightMedium:l,fontWeightBold:c},h),w,{clone:!1})}const Op=.2,_p=.14,Pp=.12;function we(...e){return[`${e[0]}px ${e[1]}px ${e[2]}px ${e[3]}px rgba(0,0,0,${Op})`,`${e[4]}px ${e[5]}px ${e[6]}px ${e[7]}px rgba(0,0,0,${_p})`,`${e[8]}px ${e[9]}px ${e[10]}px ${e[11]}px rgba(0,0,0,${Pp})`].join(",")}const Ip=["none",we(0,2,1,-1,0,1,1,0,0,1,3,0),we(0,3,1,-2,0,2,2,0,0,1,5,0),we(0,3,3,-2,0,3,4,0,0,1,8,0),we(0,2,4,-1,0,4,5,0,0,1,10,0),we(0,3,5,-1,0,5,8,0,0,1,14,0),we(0,3,5,-1,0,6,10,0,0,1,18,0),we(0,4,5,-2,0,7,10,1,0,2,16,1),we(0,5,5,-3,0,8,10,1,0,3,14,2),we(0,5,6,-3,0,9,12,1,0,3,16,2),we(0,6,6,-3,0,10,14,1,0,4,18,3),we(0,6,7,-4,0,11,15,1,0,4,20,3),we(0,7,8,-4,0,12,17,2,0,5,22,4),we(0,7,8,-4,0,13,19,2,0,5,24,4),we(0,7,9,-4,0,14,21,2,0,5,26,4),we(0,8,9,-5,0,15,22,2,0,6,28,5),we(0,8,10,-5,0,16,24,2,0,6,30,5),we(0,8,11,-5,0,17,26,2,0,6,32,5),we(0,9,11,-5,0,18,28,2,0,7,34,6),we(0,9,12,-6,0,19,29,2,0,7,36,6),we(0,10,13,-6,0,20,31,3,0,8,38,7),we(0,10,13,-6,0,21,33,3,0,8,40,7),we(0,10,14,-6,0,22,35,3,0,8,42,7),we(0,11,14,-7,0,23,36,3,0,9,44,8),we(0,11,15,-7,0,24,38,3,0,9,46,8)],Mp=Ip,$p=["duration","easing","delay"],Ap={easeInOut:"cubic-bezier(0.4, 0, 0.2, 1)",easeOut:"cubic-bezier(0.0, 0, 0.2, 1)",easeIn:"cubic-bezier(0.4, 0, 1, 1)",sharp:"cubic-bezier(0.4, 0, 0.6, 1)"},Dp={shortest:150,shorter:200,short:250,standard:300,complex:375,enteringScreen:225,leavingScreen:195};function Ia(e){return`${Math.round(e)}ms`}function Bp(e){if(!e)return 0;const t=e/36;return Math.round((4+15*t**.25+t/5)*10)}function Vp(e){const t=R({},Ap,e.easing),n=R({},Dp,e.duration);return R({getAutoHeightDuration:Bp,create:(o=["all"],s={})=>{const{duration:i=n.standard,easing:l=t.easeInOut,delay:c=0}=s,d=ye(s,$p);if(process.env.NODE_ENV!=="production"){const u=w=>typeof w=="string",f=w=>!isNaN(parseFloat(w));!u(o)&&!Array.isArray(o)&&console.error('MUI: Argument "props" must be a string or Array.'),!f(i)&&!u(i)&&console.error(`MUI: Argument "duration" must be a number or a string but found ${i}.`),u(l)||console.error('MUI: Argument "easing" must be a string.'),!f(c)&&!u(c)&&console.error('MUI: Argument "delay" must be a number or a string.'),typeof s!="object"&&console.error(["MUI: Secong argument of transition.create must be an object.","Arguments should be either `create('prop1', options)` or `create(['prop1', 'prop2'], options)`"].join(` +`)),Object.keys(d).length!==0&&console.error(`MUI: Unrecognized argument(s) [${Object.keys(d).join(",")}].`)}return(Array.isArray(o)?o:[o]).map(u=>`${u} ${typeof i=="string"?i:Ia(i)} ${l} ${typeof c=="string"?c:Ia(c)}`).join(",")}},e,{easing:t,duration:n})}const zp={mobileStepper:1e3,fab:1050,speedDial:1050,appBar:1100,drawer:1200,modal:1300,snackbar:1400,tooltip:1500},Lp=zp,Fp=["breakpoints","mixins","spacing","palette","transitions","typography","shape"];function Gp(e={},...t){const{mixins:n={},palette:r={},transitions:o={},typography:s={}}=e,i=ye(e,Fp);if(e.vars)throw new Error(process.env.NODE_ENV!=="production"?"MUI: `vars` is a private field used for CSS variables support.\nPlease use another name.":zt(18));const l=jp(r),c=To(e);let d=Qe(c,{mixins:cp(c.breakpoints,n),palette:l,shadows:Mp.slice(),typography:Rp(l,s),transitions:Vp(o),zIndex:R({},Lp)});if(d=Qe(d,i),d=t.reduce((u,f)=>Qe(u,f),d),process.env.NODE_ENV!=="production"){const u=["active","checked","completed","disabled","error","expanded","focused","focusVisible","required","selected"],f=(w,b)=>{let x;for(x in w){const m=w[x];if(u.indexOf(x)!==-1&&Object.keys(m).length>0){if(process.env.NODE_ENV!=="production"){const h=ur("",x);console.error([`MUI: The \`${b}\` component increases the CSS specificity of the \`${x}\` internal state.`,"You can not override it like this: ",JSON.stringify(w,null,2),"",`Instead, you need to use the '&.${h}' syntax:`,JSON.stringify({root:{[`&.${h}`]:m}},null,2),"","https://mui.com/r/state-classes-guide"].join(` +`))}w[x]={}}}};Object.keys(d.components).forEach(w=>{const b=d.components[w].styleOverrides;b&&w.indexOf("Mui")===0&&f(b,w)})}return d.unstable_sxConfig=R({},Eo,i==null?void 0:i.unstable_sxConfig),d.unstable_sx=function(f){return jo({sx:f,theme:this})},d}const Up=Gp(),Ro=Up,Oo="$$material";function _o({props:e,name:t}){return op({props:e,name:t,defaultTheme:Ro,themeId:Oo})}const qp=e=>qn(e)&&e!=="classes",Hp=np({themeId:Oo,defaultTheme:Ro,rootShouldForwardProp:qp}),In=Hp;function Xp(e){return ur("MuiSvgIcon",e)}si("MuiSvgIcon",["root","colorPrimary","colorSecondary","colorAction","colorError","colorDisabled","fontSizeInherit","fontSizeSmall","fontSizeMedium","fontSizeLarge"]);const Yp=["children","className","color","component","fontSize","htmlColor","inheritViewBox","titleAccess","viewBox"],Wp=e=>{const{color:t,fontSize:n,classes:r}=e,o={root:["root",t!=="inherit"&&`color${Ye(t)}`,`fontSize${Ye(n)}`]};return No(o,Xp,r)},Kp=In("svg",{name:"MuiSvgIcon",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.root,n.color!=="inherit"&&t[`color${Ye(n.color)}`],t[`fontSize${Ye(n.fontSize)}`]]}})(({theme:e,ownerState:t})=>{var n,r,o,s,i,l,c,d,u,f,w,b,x;return{userSelect:"none",width:"1em",height:"1em",display:"inline-block",fill:t.hasSvgAsChild?void 0:"currentColor",flexShrink:0,transition:(n=e.transitions)==null||(r=n.create)==null?void 0:r.call(n,"fill",{duration:(o=e.transitions)==null||(o=o.duration)==null?void 0:o.shorter}),fontSize:{inherit:"inherit",small:((s=e.typography)==null||(i=s.pxToRem)==null?void 0:i.call(s,20))||"1.25rem",medium:((l=e.typography)==null||(c=l.pxToRem)==null?void 0:c.call(l,24))||"1.5rem",large:((d=e.typography)==null||(u=d.pxToRem)==null?void 0:u.call(d,35))||"2.1875rem"}[t.fontSize],color:(f=(w=(e.vars||e).palette)==null||(w=w[t.color])==null?void 0:w.main)!=null?f:{action:(b=(e.vars||e).palette)==null||(b=b.action)==null?void 0:b.active,disabled:(x=(e.vars||e).palette)==null||(x=x.action)==null?void 0:x.disabled,inherit:void 0}[t.color]}}),Po=$.forwardRef(function(t,n){const r=_o({props:t,name:"MuiSvgIcon"}),{children:o,className:s,color:i="inherit",component:l="svg",fontSize:c="medium",htmlColor:d,inheritViewBox:u=!1,titleAccess:f,viewBox:w="0 0 24 24"}=r,b=ye(r,Yp),x=$.isValidElement(o)&&o.type==="svg",m=R({},r,{color:i,component:l,fontSize:c,instanceFontSize:t.fontSize,inheritViewBox:u,viewBox:w,hasSvgAsChild:x}),h={};u||(h.viewBox=w);const E=Wp(m);return a.jsxs(Kp,R({as:l,className:ot(E.root,s),focusable:"false",color:d,"aria-hidden":f?void 0:!0,role:f?"img":void 0,ref:n},h,b,x&&o.props,{ownerState:m,children:[x?o.props.children:o,f?a.jsx("title",{children:f}):null]}))});process.env.NODE_ENV!=="production"&&(Po.propTypes={children:p.node,classes:p.object,className:p.string,color:p.oneOfType([p.oneOf(["inherit","action","disabled","primary","secondary","error","info","success","warning"]),p.string]),component:p.elementType,fontSize:p.oneOfType([p.oneOf(["inherit","large","medium","small"]),p.string]),htmlColor:p.string,inheritViewBox:p.bool,shapeRendering:p.string,sx:p.oneOfType([p.arrayOf(p.oneOfType([p.func,p.object,p.bool])),p.func,p.object]),titleAccess:p.string,viewBox:p.string});Po.muiName="SvgIcon";const Ma=Po;function wi(e,t){function n(r,o){return a.jsx(Ma,R({"data-testid":`${t}Icon`,ref:o},r,{children:e}))}return process.env.NODE_ENV!=="production"&&(n.displayName=`${t}Icon`),n.muiName=Ma.muiName,$.memo($.forwardRef(n))}const Jp={configure:e=>{process.env.NODE_ENV!=="production"&&console.warn(["MUI: `ClassNameGenerator` import from `@mui/material/utils` is outdated and might cause unexpected issues.","","You should use `import { unstable_ClassNameGenerator } from '@mui/material/className'` instead","","The detail of the issue: https://github.com/mui/material-ui/issues/30011#issuecomment-1024993401","","The updated documentation: https://mui.com/guides/classname-generator/"].join(` +`)),oi.configure(e)}},Zp=Object.freeze(Object.defineProperty({__proto__:null,capitalize:Ye,createChainedFunction:Td,createSvgIcon:wi,debounce:Cd,deprecatedPropType:Rd,isMuiElement:Od,ownerDocument:Kn,ownerWindow:_d,requirePropFactory:Pd,setRef:Jn,unstable_ClassNameGenerator:Jp,unstable_useEnhancedEffect:Lt,unstable_useId:ei,unsupportedProp:$d,useControlled:ti,useEventCallback:Jr,useForkRef:yt,useIsFocusVisible:ni},Symbol.toStringTag,{value:"Module"})),Qp=id(Zp);var $a;function ew(){return $a||($a=1,function(e){"use client";Object.defineProperty(e,"__esModule",{value:!0}),Object.defineProperty(e,"default",{enumerable:!0,get:function(){return t.createSvgIcon}});var t=Qp}(_r)),_r}var tw=ld;Object.defineProperty(vo,"__esModule",{value:!0});var fi=vo.default=void 0,nw=tw(ew()),rw=a;fi=vo.default=(0,nw.default)((0,rw.jsx)("path",{d:"m10 17 5-5-5-5z"}),"ArrowRight");function ow(e){return typeof e=="string"}function dn(e,t,n){return e===void 0||ow(e)?t:R({},t,{ownerState:R({},t.ownerState,n)})}const aw={disableDefaultClasses:!1},sw=$.createContext(aw);function iw(e){const{disableDefaultClasses:t}=$.useContext(sw);return n=>t?"":e(n)}function lw(e,t=[]){if(e===void 0)return{};const n={};return Object.keys(e).filter(r=>r.match(/^on[A-Z]/)&&typeof e[r]=="function"&&!t.includes(r)).forEach(r=>{n[r]=e[r]}),n}function cw(e,t,n){return typeof e=="function"?e(t,n):e}function Aa(e){if(e===void 0)return{};const t={};return Object.keys(e).filter(n=>!(n.match(/^on[A-Z]/)&&typeof e[n]=="function")).forEach(n=>{t[n]=e[n]}),t}function dw(e){const{getSlotProps:t,additionalProps:n,externalSlotProps:r,externalForwardedProps:o,className:s}=e;if(!t){const b=ot(n==null?void 0:n.className,s,o==null?void 0:o.className,r==null?void 0:r.className),x=R({},n==null?void 0:n.style,o==null?void 0:o.style,r==null?void 0:r.style),m=R({},n,o,r);return b.length>0&&(m.className=b),Object.keys(x).length>0&&(m.style=x),{props:m,internalRef:void 0}}const i=lw(R({},o,r)),l=Aa(r),c=Aa(o),d=t(i),u=ot(d==null?void 0:d.className,n==null?void 0:n.className,s,o==null?void 0:o.className,r==null?void 0:r.className),f=R({},d==null?void 0:d.style,n==null?void 0:n.style,o==null?void 0:o.style,r==null?void 0:r.style),w=R({},d,n,c,l);return u.length>0&&(w.className=u),Object.keys(f).length>0&&(w.style=f),{props:w,internalRef:d.ref}}const uw=["elementType","externalSlotProps","ownerState","skipResolvingSlotProps"];function pw(e){var t;const{elementType:n,externalSlotProps:r,ownerState:o,skipResolvingSlotProps:s=!1}=e,i=ye(e,uw),l=s?{}:cw(r,o),{props:c,internalRef:d}=dw(R({},i,{externalSlotProps:l})),u=yt(d,l==null?void 0:l.ref,(t=e.additionalProps)==null?void 0:t.ref);return dn(n,R({},c,{ref:u}),o)}const mi="base";function ww(e){return`${mi}--${e}`}function fw(e,t){return`${mi}-${e}-${t}`}function hi(e,t){const n=ai[t];return n?ww(n):fw(e,t)}function mw(e,t){const n={};return t.forEach(r=>{n[r]=hi(e,r)}),n}function hw(e){return typeof e=="function"?e():e}const Qn=$.forwardRef(function(t,n){const{children:r,container:o,disablePortal:s=!1}=t,[i,l]=$.useState(null),c=yt($.isValidElement(r)?r.ref:null,n);if(Lt(()=>{s||l(hw(o)||document.body)},[o,s]),Lt(()=>{if(i&&!s)return Jn(n,i),()=>{Jn(n,null)}},[n,i,s]),s){if($.isValidElement(r)){const d={ref:c};return $.cloneElement(r,d)}return a.jsx($.Fragment,{children:r})}return a.jsx($.Fragment,{children:i&&Tl.createPortal(r,i)})});process.env.NODE_ENV!=="production"&&(Qn.propTypes={children:p.node,container:p.oneOfType([vn,p.func]),disablePortal:p.bool});process.env.NODE_ENV!=="production"&&(Qn["propTypes"]=xd(Qn.propTypes));var je="top",Ve="bottom",ze="right",Te="left",Io="auto",Mn=[je,Ve,ze,Te],Ft="start",yn="end",gw="clippingParents",gi="viewport",on="popper",bw="reference",Da=Mn.reduce(function(e,t){return e.concat([t+"-"+Ft,t+"-"+yn])},[]),bi=[].concat(Mn,[Io]).reduce(function(e,t){return e.concat([t,t+"-"+Ft,t+"-"+yn])},[]),vw="beforeRead",xw="read",yw="afterRead",Nw="beforeMain",kw="main",Sw="afterMain",Ew="beforeWrite",jw="write",Tw="afterWrite",Cw=[vw,xw,yw,Nw,kw,Sw,Ew,jw,Tw];function We(e){return e?(e.nodeName||"").toLowerCase():null}function Me(e){if(e==null)return window;if(e.toString()!=="[object Window]"){var t=e.ownerDocument;return t&&t.defaultView||window}return e}function kt(e){var t=Me(e).Element;return e instanceof t||e instanceof Element}function Be(e){var t=Me(e).HTMLElement;return e instanceof t||e instanceof HTMLElement}function Mo(e){if(typeof ShadowRoot>"u")return!1;var t=Me(e).ShadowRoot;return e instanceof t||e instanceof ShadowRoot}function Rw(e){var t=e.state;Object.keys(t.elements).forEach(function(n){var r=t.styles[n]||{},o=t.attributes[n]||{},s=t.elements[n];!Be(s)||!We(s)||(Object.assign(s.style,r),Object.keys(o).forEach(function(i){var l=o[i];l===!1?s.removeAttribute(i):s.setAttribute(i,l===!0?"":l)}))})}function Ow(e){var t=e.state,n={popper:{position:t.options.strategy,left:"0",top:"0",margin:"0"},arrow:{position:"absolute"},reference:{}};return Object.assign(t.elements.popper.style,n.popper),t.styles=n,t.elements.arrow&&Object.assign(t.elements.arrow.style,n.arrow),function(){Object.keys(t.elements).forEach(function(r){var o=t.elements[r],s=t.attributes[r]||{},i=Object.keys(t.styles.hasOwnProperty(r)?t.styles[r]:n[r]),l=i.reduce(function(c,d){return c[d]="",c},{});!Be(o)||!We(o)||(Object.assign(o.style,l),Object.keys(s).forEach(function(c){o.removeAttribute(c)}))})}}const _w={name:"applyStyles",enabled:!0,phase:"write",fn:Rw,effect:Ow,requires:["computeStyles"]};function He(e){return e.split("-")[0]}var ht=Math.max,er=Math.min,Gt=Math.round;function Qr(){var e=navigator.userAgentData;return e!=null&&e.brands&&Array.isArray(e.brands)?e.brands.map(function(t){return t.brand+"/"+t.version}).join(" "):navigator.userAgent}function vi(){return!/^((?!chrome|android).)*safari/i.test(Qr())}function Ut(e,t,n){t===void 0&&(t=!1),n===void 0&&(n=!1);var r=e.getBoundingClientRect(),o=1,s=1;t&&Be(e)&&(o=e.offsetWidth>0&&Gt(r.width)/e.offsetWidth||1,s=e.offsetHeight>0&&Gt(r.height)/e.offsetHeight||1);var i=kt(e)?Me(e):window,l=i.visualViewport,c=!vi()&&n,d=(r.left+(c&&l?l.offsetLeft:0))/o,u=(r.top+(c&&l?l.offsetTop:0))/s,f=r.width/o,w=r.height/s;return{width:f,height:w,top:u,right:d+f,bottom:u+w,left:d,x:d,y:u}}function $o(e){var t=Ut(e),n=e.offsetWidth,r=e.offsetHeight;return Math.abs(t.width-n)<=1&&(n=t.width),Math.abs(t.height-r)<=1&&(r=t.height),{x:e.offsetLeft,y:e.offsetTop,width:n,height:r}}function xi(e,t){var n=t.getRootNode&&t.getRootNode();if(e.contains(t))return!0;if(n&&Mo(n)){var r=t;do{if(r&&e.isSameNode(r))return!0;r=r.parentNode||r.host}while(r)}return!1}function tt(e){return Me(e).getComputedStyle(e)}function Pw(e){return["table","td","th"].indexOf(We(e))>=0}function it(e){return((kt(e)?e.ownerDocument:e.document)||window.document).documentElement}function yr(e){return We(e)==="html"?e:e.assignedSlot||e.parentNode||(Mo(e)?e.host:null)||it(e)}function Ba(e){return!Be(e)||tt(e).position==="fixed"?null:e.offsetParent}function Iw(e){var t=/firefox/i.test(Qr()),n=/Trident/i.test(Qr());if(n&&Be(e)){var r=tt(e);if(r.position==="fixed")return null}var o=yr(e);for(Mo(o)&&(o=o.host);Be(o)&&["html","body"].indexOf(We(o))<0;){var s=tt(o);if(s.transform!=="none"||s.perspective!=="none"||s.contain==="paint"||["transform","perspective"].indexOf(s.willChange)!==-1||t&&s.willChange==="filter"||t&&s.filter&&s.filter!=="none")return o;o=o.parentNode}return null}function $n(e){for(var t=Me(e),n=Ba(e);n&&Pw(n)&&tt(n).position==="static";)n=Ba(n);return n&&(We(n)==="html"||We(n)==="body"&&tt(n).position==="static")?t:n||Iw(e)||t}function Ao(e){return["top","bottom"].indexOf(e)>=0?"x":"y"}function mn(e,t,n){return ht(e,er(t,n))}function Mw(e,t,n){var r=mn(e,t,n);return r>n?n:r}function yi(){return{top:0,right:0,bottom:0,left:0}}function Ni(e){return Object.assign({},yi(),e)}function ki(e,t){return t.reduce(function(n,r){return n[r]=e,n},{})}var $w=function(t,n){return t=typeof t=="function"?t(Object.assign({},n.rects,{placement:n.placement})):t,Ni(typeof t!="number"?t:ki(t,Mn))};function Aw(e){var t,n=e.state,r=e.name,o=e.options,s=n.elements.arrow,i=n.modifiersData.popperOffsets,l=He(n.placement),c=Ao(l),d=[Te,ze].indexOf(l)>=0,u=d?"height":"width";if(!(!s||!i)){var f=$w(o.padding,n),w=$o(s),b=c==="y"?je:Te,x=c==="y"?Ve:ze,m=n.rects.reference[u]+n.rects.reference[c]-i[c]-n.rects.popper[u],h=i[c]-n.rects.reference[c],E=$n(s),I=E?c==="y"?E.clientHeight||0:E.clientWidth||0:0,C=m/2-h/2,S=f[b],v=I-w[u]-f[x],_=I/2-w[u]/2+C,V=mn(S,_,v),U=c;n.modifiersData[r]=(t={},t[U]=V,t.centerOffset=V-_,t)}}function Dw(e){var t=e.state,n=e.options,r=n.element,o=r===void 0?"[data-popper-arrow]":r;o!=null&&(typeof o=="string"&&(o=t.elements.popper.querySelector(o),!o)||xi(t.elements.popper,o)&&(t.elements.arrow=o))}const Bw={name:"arrow",enabled:!0,phase:"main",fn:Aw,effect:Dw,requires:["popperOffsets"],requiresIfExists:["preventOverflow"]};function qt(e){return e.split("-")[1]}var Vw={top:"auto",right:"auto",bottom:"auto",left:"auto"};function zw(e,t){var n=e.x,r=e.y,o=t.devicePixelRatio||1;return{x:Gt(n*o)/o||0,y:Gt(r*o)/o||0}}function Va(e){var t,n=e.popper,r=e.popperRect,o=e.placement,s=e.variation,i=e.offsets,l=e.position,c=e.gpuAcceleration,d=e.adaptive,u=e.roundOffsets,f=e.isFixed,w=i.x,b=w===void 0?0:w,x=i.y,m=x===void 0?0:x,h=typeof u=="function"?u({x:b,y:m}):{x:b,y:m};b=h.x,m=h.y;var E=i.hasOwnProperty("x"),I=i.hasOwnProperty("y"),C=Te,S=je,v=window;if(d){var _=$n(n),V="clientHeight",U="clientWidth";if(_===Me(n)&&(_=it(n),tt(_).position!=="static"&&l==="absolute"&&(V="scrollHeight",U="scrollWidth")),_=_,o===je||(o===Te||o===ze)&&s===yn){S=Ve;var j=f&&_===v&&v.visualViewport?v.visualViewport.height:_[V];m-=j-r.height,m*=c?1:-1}if(o===Te||(o===je||o===Ve)&&s===yn){C=ze;var O=f&&_===v&&v.visualViewport?v.visualViewport.width:_[U];b-=O-r.width,b*=c?1:-1}}var k=Object.assign({position:l},d&&Vw),A=u===!0?zw({x:b,y:m},Me(n)):{x:b,y:m};if(b=A.x,m=A.y,c){var M;return Object.assign({},k,(M={},M[S]=I?"0":"",M[C]=E?"0":"",M.transform=(v.devicePixelRatio||1)<=1?"translate("+b+"px, "+m+"px)":"translate3d("+b+"px, "+m+"px, 0)",M))}return Object.assign({},k,(t={},t[S]=I?m+"px":"",t[C]=E?b+"px":"",t.transform="",t))}function Lw(e){var t=e.state,n=e.options,r=n.gpuAcceleration,o=r===void 0?!0:r,s=n.adaptive,i=s===void 0?!0:s,l=n.roundOffsets,c=l===void 0?!0:l,d={placement:He(t.placement),variation:qt(t.placement),popper:t.elements.popper,popperRect:t.rects.popper,gpuAcceleration:o,isFixed:t.options.strategy==="fixed"};t.modifiersData.popperOffsets!=null&&(t.styles.popper=Object.assign({},t.styles.popper,Va(Object.assign({},d,{offsets:t.modifiersData.popperOffsets,position:t.options.strategy,adaptive:i,roundOffsets:c})))),t.modifiersData.arrow!=null&&(t.styles.arrow=Object.assign({},t.styles.arrow,Va(Object.assign({},d,{offsets:t.modifiersData.arrow,position:"absolute",adaptive:!1,roundOffsets:c})))),t.attributes.popper=Object.assign({},t.attributes.popper,{"data-popper-placement":t.placement})}const Fw={name:"computeStyles",enabled:!0,phase:"beforeWrite",fn:Lw,data:{}};var Fn={passive:!0};function Gw(e){var t=e.state,n=e.instance,r=e.options,o=r.scroll,s=o===void 0?!0:o,i=r.resize,l=i===void 0?!0:i,c=Me(t.elements.popper),d=[].concat(t.scrollParents.reference,t.scrollParents.popper);return s&&d.forEach(function(u){u.addEventListener("scroll",n.update,Fn)}),l&&c.addEventListener("resize",n.update,Fn),function(){s&&d.forEach(function(u){u.removeEventListener("scroll",n.update,Fn)}),l&&c.removeEventListener("resize",n.update,Fn)}}const Uw={name:"eventListeners",enabled:!0,phase:"write",fn:function(){},effect:Gw,data:{}};var qw={left:"right",right:"left",bottom:"top",top:"bottom"};function Xn(e){return e.replace(/left|right|bottom|top/g,function(t){return qw[t]})}var Hw={start:"end",end:"start"};function za(e){return e.replace(/start|end/g,function(t){return Hw[t]})}function Do(e){var t=Me(e),n=t.pageXOffset,r=t.pageYOffset;return{scrollLeft:n,scrollTop:r}}function Bo(e){return Ut(it(e)).left+Do(e).scrollLeft}function Xw(e,t){var n=Me(e),r=it(e),o=n.visualViewport,s=r.clientWidth,i=r.clientHeight,l=0,c=0;if(o){s=o.width,i=o.height;var d=vi();(d||!d&&t==="fixed")&&(l=o.offsetLeft,c=o.offsetTop)}return{width:s,height:i,x:l+Bo(e),y:c}}function Yw(e){var t,n=it(e),r=Do(e),o=(t=e.ownerDocument)==null?void 0:t.body,s=ht(n.scrollWidth,n.clientWidth,o?o.scrollWidth:0,o?o.clientWidth:0),i=ht(n.scrollHeight,n.clientHeight,o?o.scrollHeight:0,o?o.clientHeight:0),l=-r.scrollLeft+Bo(e),c=-r.scrollTop;return tt(o||n).direction==="rtl"&&(l+=ht(n.clientWidth,o?o.clientWidth:0)-s),{width:s,height:i,x:l,y:c}}function Vo(e){var t=tt(e),n=t.overflow,r=t.overflowX,o=t.overflowY;return/auto|scroll|overlay|hidden/.test(n+o+r)}function Si(e){return["html","body","#document"].indexOf(We(e))>=0?e.ownerDocument.body:Be(e)&&Vo(e)?e:Si(yr(e))}function hn(e,t){var n;t===void 0&&(t=[]);var r=Si(e),o=r===((n=e.ownerDocument)==null?void 0:n.body),s=Me(r),i=o?[s].concat(s.visualViewport||[],Vo(r)?r:[]):r,l=t.concat(i);return o?l:l.concat(hn(yr(i)))}function eo(e){return Object.assign({},e,{left:e.x,top:e.y,right:e.x+e.width,bottom:e.y+e.height})}function Ww(e,t){var n=Ut(e,!1,t==="fixed");return n.top=n.top+e.clientTop,n.left=n.left+e.clientLeft,n.bottom=n.top+e.clientHeight,n.right=n.left+e.clientWidth,n.width=e.clientWidth,n.height=e.clientHeight,n.x=n.left,n.y=n.top,n}function La(e,t,n){return t===gi?eo(Xw(e,n)):kt(t)?Ww(t,n):eo(Yw(it(e)))}function Kw(e){var t=hn(yr(e)),n=["absolute","fixed"].indexOf(tt(e).position)>=0,r=n&&Be(e)?$n(e):e;return kt(r)?t.filter(function(o){return kt(o)&&xi(o,r)&&We(o)!=="body"}):[]}function Jw(e,t,n,r){var o=t==="clippingParents"?Kw(e):[].concat(t),s=[].concat(o,[n]),i=s[0],l=s.reduce(function(c,d){var u=La(e,d,r);return c.top=ht(u.top,c.top),c.right=er(u.right,c.right),c.bottom=er(u.bottom,c.bottom),c.left=ht(u.left,c.left),c},La(e,i,r));return l.width=l.right-l.left,l.height=l.bottom-l.top,l.x=l.left,l.y=l.top,l}function Ei(e){var t=e.reference,n=e.element,r=e.placement,o=r?He(r):null,s=r?qt(r):null,i=t.x+t.width/2-n.width/2,l=t.y+t.height/2-n.height/2,c;switch(o){case je:c={x:i,y:t.y-n.height};break;case Ve:c={x:i,y:t.y+t.height};break;case ze:c={x:t.x+t.width,y:l};break;case Te:c={x:t.x-n.width,y:l};break;default:c={x:t.x,y:t.y}}var d=o?Ao(o):null;if(d!=null){var u=d==="y"?"height":"width";switch(s){case Ft:c[d]=c[d]-(t[u]/2-n[u]/2);break;case yn:c[d]=c[d]+(t[u]/2-n[u]/2);break}}return c}function Nn(e,t){t===void 0&&(t={});var n=t,r=n.placement,o=r===void 0?e.placement:r,s=n.strategy,i=s===void 0?e.strategy:s,l=n.boundary,c=l===void 0?gw:l,d=n.rootBoundary,u=d===void 0?gi:d,f=n.elementContext,w=f===void 0?on:f,b=n.altBoundary,x=b===void 0?!1:b,m=n.padding,h=m===void 0?0:m,E=Ni(typeof h!="number"?h:ki(h,Mn)),I=w===on?bw:on,C=e.rects.popper,S=e.elements[x?I:w],v=Jw(kt(S)?S:S.contextElement||it(e.elements.popper),c,u,i),_=Ut(e.elements.reference),V=Ei({reference:_,element:C,strategy:"absolute",placement:o}),U=eo(Object.assign({},C,V)),j=w===on?U:_,O={top:v.top-j.top+E.top,bottom:j.bottom-v.bottom+E.bottom,left:v.left-j.left+E.left,right:j.right-v.right+E.right},k=e.modifiersData.offset;if(w===on&&k){var A=k[o];Object.keys(O).forEach(function(M){var J=[ze,Ve].indexOf(M)>=0?1:-1,Y=[je,Ve].indexOf(M)>=0?"y":"x";O[M]+=A[Y]*J})}return O}function Zw(e,t){t===void 0&&(t={});var n=t,r=n.placement,o=n.boundary,s=n.rootBoundary,i=n.padding,l=n.flipVariations,c=n.allowedAutoPlacements,d=c===void 0?bi:c,u=qt(r),f=u?l?Da:Da.filter(function(x){return qt(x)===u}):Mn,w=f.filter(function(x){return d.indexOf(x)>=0});w.length===0&&(w=f);var b=w.reduce(function(x,m){return x[m]=Nn(e,{placement:m,boundary:o,rootBoundary:s,padding:i})[He(m)],x},{});return Object.keys(b).sort(function(x,m){return b[x]-b[m]})}function Qw(e){if(He(e)===Io)return[];var t=Xn(e);return[za(e),t,za(t)]}function ef(e){var t=e.state,n=e.options,r=e.name;if(!t.modifiersData[r]._skip){for(var o=n.mainAxis,s=o===void 0?!0:o,i=n.altAxis,l=i===void 0?!0:i,c=n.fallbackPlacements,d=n.padding,u=n.boundary,f=n.rootBoundary,w=n.altBoundary,b=n.flipVariations,x=b===void 0?!0:b,m=n.allowedAutoPlacements,h=t.options.placement,E=He(h),I=E===h,C=c||(I||!x?[Xn(h)]:Qw(h)),S=[h].concat(C).reduce(function(B,X){return B.concat(He(X)===Io?Zw(t,{placement:X,boundary:u,rootBoundary:f,padding:d,flipVariations:x,allowedAutoPlacements:m}):X)},[]),v=t.rects.reference,_=t.rects.popper,V=new Map,U=!0,j=S[0],O=0;O=0,Y=J?"width":"height",F=Nn(t,{placement:k,boundary:u,rootBoundary:f,altBoundary:w,padding:d}),te=J?M?ze:Te:M?Ve:je;v[Y]>_[Y]&&(te=Xn(te));var se=Xn(te),oe=[];if(s&&oe.push(F[A]<=0),l&&oe.push(F[te]<=0,F[se]<=0),oe.every(function(B){return B})){j=k,U=!1;break}V.set(k,oe)}if(U)for(var y=x?3:1,T=function(X){var q=S.find(function(H){var G=V.get(H);if(G)return G.slice(0,X).every(function(K){return K})});if(q)return j=q,"break"},z=y;z>0;z--){var L=T(z);if(L==="break")break}t.placement!==j&&(t.modifiersData[r]._skip=!0,t.placement=j,t.reset=!0)}}const tf={name:"flip",enabled:!0,phase:"main",fn:ef,requiresIfExists:["offset"],data:{_skip:!1}};function Fa(e,t,n){return n===void 0&&(n={x:0,y:0}),{top:e.top-t.height-n.y,right:e.right-t.width+n.x,bottom:e.bottom-t.height+n.y,left:e.left-t.width-n.x}}function Ga(e){return[je,ze,Ve,Te].some(function(t){return e[t]>=0})}function nf(e){var t=e.state,n=e.name,r=t.rects.reference,o=t.rects.popper,s=t.modifiersData.preventOverflow,i=Nn(t,{elementContext:"reference"}),l=Nn(t,{altBoundary:!0}),c=Fa(i,r),d=Fa(l,o,s),u=Ga(c),f=Ga(d);t.modifiersData[n]={referenceClippingOffsets:c,popperEscapeOffsets:d,isReferenceHidden:u,hasPopperEscaped:f},t.attributes.popper=Object.assign({},t.attributes.popper,{"data-popper-reference-hidden":u,"data-popper-escaped":f})}const rf={name:"hide",enabled:!0,phase:"main",requiresIfExists:["preventOverflow"],fn:nf};function of(e,t,n){var r=He(e),o=[Te,je].indexOf(r)>=0?-1:1,s=typeof n=="function"?n(Object.assign({},t,{placement:e})):n,i=s[0],l=s[1];return i=i||0,l=(l||0)*o,[Te,ze].indexOf(r)>=0?{x:l,y:i}:{x:i,y:l}}function af(e){var t=e.state,n=e.options,r=e.name,o=n.offset,s=o===void 0?[0,0]:o,i=bi.reduce(function(u,f){return u[f]=of(f,t.rects,s),u},{}),l=i[t.placement],c=l.x,d=l.y;t.modifiersData.popperOffsets!=null&&(t.modifiersData.popperOffsets.x+=c,t.modifiersData.popperOffsets.y+=d),t.modifiersData[r]=i}const sf={name:"offset",enabled:!0,phase:"main",requires:["popperOffsets"],fn:af};function lf(e){var t=e.state,n=e.name;t.modifiersData[n]=Ei({reference:t.rects.reference,element:t.rects.popper,strategy:"absolute",placement:t.placement})}const cf={name:"popperOffsets",enabled:!0,phase:"read",fn:lf,data:{}};function df(e){return e==="x"?"y":"x"}function uf(e){var t=e.state,n=e.options,r=e.name,o=n.mainAxis,s=o===void 0?!0:o,i=n.altAxis,l=i===void 0?!1:i,c=n.boundary,d=n.rootBoundary,u=n.altBoundary,f=n.padding,w=n.tether,b=w===void 0?!0:w,x=n.tetherOffset,m=x===void 0?0:x,h=Nn(t,{boundary:c,rootBoundary:d,padding:f,altBoundary:u}),E=He(t.placement),I=qt(t.placement),C=!I,S=Ao(E),v=df(S),_=t.modifiersData.popperOffsets,V=t.rects.reference,U=t.rects.popper,j=typeof m=="function"?m(Object.assign({},t.rects,{placement:t.placement})):m,O=typeof j=="number"?{mainAxis:j,altAxis:j}:Object.assign({mainAxis:0,altAxis:0},j),k=t.modifiersData.offset?t.modifiersData.offset[t.placement]:null,A={x:0,y:0};if(_){if(s){var M,J=S==="y"?je:Te,Y=S==="y"?Ve:ze,F=S==="y"?"height":"width",te=_[S],se=te+h[J],oe=te-h[Y],y=b?-U[F]/2:0,T=I===Ft?V[F]:U[F],z=I===Ft?-U[F]:-V[F],L=t.elements.arrow,B=b&&L?$o(L):{width:0,height:0},X=t.modifiersData["arrow#persistent"]?t.modifiersData["arrow#persistent"].padding:yi(),q=X[J],H=X[Y],G=mn(0,V[F],B[F]),K=C?V[F]/2-y-G-q-O.mainAxis:T-G-q-O.mainAxis,Z=C?-V[F]/2+y+G+H+O.mainAxis:z+G+H+O.mainAxis,ue=t.elements.arrow&&$n(t.elements.arrow),P=ue?S==="y"?ue.clientTop||0:ue.clientLeft||0:0,xe=(M=k==null?void 0:k[S])!=null?M:0,D=te+K-xe-P,ve=te+Z-xe,Fe=mn(b?er(se,D):se,te,b?ht(oe,ve):oe);_[S]=Fe,A[S]=Fe-te}if(l){var lt,Se=S==="x"?je:Te,An=S==="x"?Ve:ze,Ge=_[v],Et=v==="y"?"height":"width",ct=Ge+h[Se],jt=Ge-h[An],Tt=[je,Te].indexOf(E)!==-1,Ct=(lt=k==null?void 0:k[v])!=null?lt:0,dt=Tt?ct:Ge-V[Et]-U[Et]-Ct+O.altAxis,Kt=Tt?Ge+V[Et]+U[Et]-Ct-O.altAxis:jt,Dn=b&&Tt?Mw(dt,Ge,Kt):mn(b?dt:ct,Ge,b?Kt:jt);_[v]=Dn,A[v]=Dn-Ge}t.modifiersData[r]=A}}const pf={name:"preventOverflow",enabled:!0,phase:"main",fn:uf,requiresIfExists:["offset"]};function wf(e){return{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}}function ff(e){return e===Me(e)||!Be(e)?Do(e):wf(e)}function mf(e){var t=e.getBoundingClientRect(),n=Gt(t.width)/e.offsetWidth||1,r=Gt(t.height)/e.offsetHeight||1;return n!==1||r!==1}function hf(e,t,n){n===void 0&&(n=!1);var r=Be(t),o=Be(t)&&mf(t),s=it(t),i=Ut(e,o,n),l={scrollLeft:0,scrollTop:0},c={x:0,y:0};return(r||!r&&!n)&&((We(t)!=="body"||Vo(s))&&(l=ff(t)),Be(t)?(c=Ut(t,!0),c.x+=t.clientLeft,c.y+=t.clientTop):s&&(c.x=Bo(s))),{x:i.left+l.scrollLeft-c.x,y:i.top+l.scrollTop-c.y,width:i.width,height:i.height}}function gf(e){var t=new Map,n=new Set,r=[];e.forEach(function(s){t.set(s.name,s)});function o(s){n.add(s.name);var i=[].concat(s.requires||[],s.requiresIfExists||[]);i.forEach(function(l){if(!n.has(l)){var c=t.get(l);c&&o(c)}}),r.push(s)}return e.forEach(function(s){n.has(s.name)||o(s)}),r}function bf(e){var t=gf(e);return Cw.reduce(function(n,r){return n.concat(t.filter(function(o){return o.phase===r}))},[])}function vf(e){var t;return function(){return t||(t=new Promise(function(n){Promise.resolve().then(function(){t=void 0,n(e())})})),t}}function xf(e){var t=e.reduce(function(n,r){var o=n[r.name];return n[r.name]=o?Object.assign({},o,r,{options:Object.assign({},o.options,r.options),data:Object.assign({},o.data,r.data)}):r,n},{});return Object.keys(t).map(function(n){return t[n]})}var Ua={placement:"bottom",modifiers:[],strategy:"absolute"};function qa(){for(var e=arguments.length,t=new Array(e),n=0;nNo({root:["root"]},iw(Sf)),Of={},_f=$.forwardRef(function(t,n){var r;const{anchorEl:o,children:s,direction:i,disablePortal:l,modifiers:c,open:d,placement:u,popperOptions:f,popperRef:w,slotProps:b={},slots:x={},TransitionProps:m}=t,h=ye(t,Ef),E=$.useRef(null),I=yt(E,n),C=$.useRef(null),S=yt(C,w),v=$.useRef(S);Lt(()=>{v.current=S},[S]),$.useImperativeHandle(w,()=>C.current,[]);const _=Tf(u,i),[V,U]=$.useState(_),[j,O]=$.useState(tr(o));$.useEffect(()=>{C.current&&C.current.forceUpdate()}),$.useEffect(()=>{o&&O(tr(o))},[o]),Lt(()=>{if(!j||!d)return;const Y=se=>{U(se.placement)};if(process.env.NODE_ENV!=="production"&&j&&Nr(j)&&j.nodeType===1){const se=j.getBoundingClientRect();process.env.NODE_ENV!=="test"&&se.top===0&&se.left===0&&se.right===0&&se.bottom===0&&console.warn(["MUI: The `anchorEl` prop provided to the component is invalid.","The anchor element should be part of the document layout.","Make sure the element is present in the document or that it's not display none."].join(` +`))}let F=[{name:"preventOverflow",options:{altBoundary:l}},{name:"flip",options:{altBoundary:l}},{name:"onUpdate",enabled:!0,phase:"afterWrite",fn:({state:se})=>{Y(se)}}];c!=null&&(F=F.concat(c)),f&&f.modifiers!=null&&(F=F.concat(f.modifiers));const te=kf(j,E.current,R({placement:_},f,{modifiers:F}));return v.current(te),()=>{te.destroy(),v.current(null)}},[j,l,c,d,f,_]);const k={placement:V};m!==null&&(k.TransitionProps=m);const A=Rf(),M=(r=x.root)!=null?r:"div",J=pw({elementType:M,externalSlotProps:b.root,externalForwardedProps:h,additionalProps:{role:"tooltip",ref:I},ownerState:t,className:A.root});return a.jsx(M,R({},J,{children:typeof s=="function"?s(k):s}))}),Ti=$.forwardRef(function(t,n){const{anchorEl:r,children:o,container:s,direction:i="ltr",disablePortal:l=!1,keepMounted:c=!1,modifiers:d,open:u,placement:f="bottom",popperOptions:w=Of,popperRef:b,style:x,transition:m=!1,slotProps:h={},slots:E={}}=t,I=ye(t,jf),[C,S]=$.useState(!0),v=()=>{S(!1)},_=()=>{S(!0)};if(!c&&!u&&(!m||C))return null;let V;if(s)V=s;else if(r){const O=tr(r);V=O&&Nr(O)?Kn(O).body:Kn(null).body}const U=!u&&c&&(!m||C)?"none":void 0,j=m?{in:u,onEnter:v,onExited:_}:void 0;return a.jsx(Qn,{disablePortal:l,container:V,children:a.jsx(_f,R({anchorEl:r,direction:i,disablePortal:l,modifiers:d,ref:n,open:m?!C:u,placement:f,popperOptions:w,popperRef:b,slotProps:h,slots:E},I,{style:R({position:"fixed",top:0,left:0,display:U},x),TransitionProps:j,children:o}))})});process.env.NODE_ENV!=="production"&&(Ti.propTypes={anchorEl:xo(p.oneOfType([vn,p.object,p.func]),e=>{if(e.open){const t=tr(e.anchorEl);if(t&&Nr(t)&&t.nodeType===1){const n=t.getBoundingClientRect();if(process.env.NODE_ENV!=="test"&&n.top===0&&n.left===0&&n.right===0&&n.bottom===0)return new Error(["MUI: The `anchorEl` prop provided to the component is invalid.","The anchor element should be part of the document layout.","Make sure the element is present in the document or that it's not display none."].join(` +`))}else if(!t||typeof t.getBoundingClientRect!="function"||Cf(t)&&t.contextElement!=null&&t.contextElement.nodeType!==1)return new Error(["MUI: The `anchorEl` prop provided to the component is invalid.","It should be an HTML element instance or a virtualElement ","(https://popper.js.org/docs/v2/virtual-elements/)."].join(` +`))}return null}),children:p.oneOfType([p.node,p.func]),container:p.oneOfType([vn,p.func]),direction:p.oneOf(["ltr","rtl"]),disablePortal:p.bool,keepMounted:p.bool,modifiers:p.arrayOf(p.shape({data:p.object,effect:p.func,enabled:p.bool,fn:p.func,name:p.any,options:p.object,phase:p.oneOf(["afterMain","afterRead","afterWrite","beforeMain","beforeRead","beforeWrite","main","read","write"]),requires:p.arrayOf(p.string),requiresIfExists:p.arrayOf(p.string)})),open:p.bool.isRequired,placement:p.oneOf(["auto-end","auto-start","auto","bottom-end","bottom-start","bottom","left-end","left-start","left","right-end","right-start","right","top-end","top-start","top"]),popperOptions:p.shape({modifiers:p.array,onFirstUpdate:p.func,placement:p.oneOf(["auto-end","auto-start","auto","bottom-end","bottom-start","bottom","left-end","left-start","left","right-end","right-start","right","top-end","top-start","top"]),strategy:p.oneOf(["absolute","fixed"])}),popperRef:Qs,slotProps:p.shape({root:p.oneOfType([p.func,p.object])}),slots:p.shape({root:p.elementType}),transition:p.bool});function Ci(){const e=ui(Ro);return process.env.NODE_ENV!=="production"&&$.useDebugValue(e),e[Oo]||e}function to(e,t){return to=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,o){return r.__proto__=o,r},to(e,t)}function Pf(e,t){e.prototype=Object.create(t.prototype),e.prototype.constructor=e,to(e,t)}const Ha={disabled:!1};var If=process.env.NODE_ENV!=="production"?p.oneOfType([p.number,p.shape({enter:p.number,exit:p.number,appear:p.number}).isRequired]):null;process.env.NODE_ENV!=="production"&&p.oneOfType([p.string,p.shape({enter:p.string,exit:p.string,active:p.string}),p.shape({enter:p.string,enterDone:p.string,enterActive:p.string,exit:p.string,exitDone:p.string,exitActive:p.string})]);const Ri=g.createContext(null);var Mf=function(t){return t.scrollTop},un="unmounted",wt="exited",ft="entering",$t="entered",no="exiting",nt=function(e){Pf(t,e);function t(r,o){var s;s=e.call(this,r,o)||this;var i=o,l=i&&!i.isMounting?r.enter:r.appear,c;return s.appearStatus=null,r.in?l?(c=wt,s.appearStatus=ft):c=$t:r.unmountOnExit||r.mountOnEnter?c=un:c=wt,s.state={status:c},s.nextCallback=null,s}t.getDerivedStateFromProps=function(o,s){var i=o.in;return i&&s.status===un?{status:wt}:null};var n=t.prototype;return n.componentDidMount=function(){this.updateStatus(!0,this.appearStatus)},n.componentDidUpdate=function(o){var s=null;if(o!==this.props){var i=this.state.status;this.props.in?i!==ft&&i!==$t&&(s=ft):(i===ft||i===$t)&&(s=no)}this.updateStatus(!1,s)},n.componentWillUnmount=function(){this.cancelNextCallback()},n.getTimeouts=function(){var o=this.props.timeout,s,i,l;return s=i=l=o,o!=null&&typeof o!="number"&&(s=o.exit,i=o.enter,l=o.appear!==void 0?o.appear:i),{exit:s,enter:i,appear:l}},n.updateStatus=function(o,s){if(o===void 0&&(o=!1),s!==null)if(this.cancelNextCallback(),s===ft){if(this.props.unmountOnExit||this.props.mountOnEnter){var i=this.props.nodeRef?this.props.nodeRef.current:sn.findDOMNode(this);i&&Mf(i)}this.performEnter(o)}else this.performExit();else this.props.unmountOnExit&&this.state.status===wt&&this.setState({status:un})},n.performEnter=function(o){var s=this,i=this.props.enter,l=this.context?this.context.isMounting:o,c=this.props.nodeRef?[l]:[sn.findDOMNode(this),l],d=c[0],u=c[1],f=this.getTimeouts(),w=l?f.appear:f.enter;if(!o&&!i||Ha.disabled){this.safeSetState({status:$t},function(){s.props.onEntered(d)});return}this.props.onEnter(d,u),this.safeSetState({status:ft},function(){s.props.onEntering(d,u),s.onTransitionEnd(w,function(){s.safeSetState({status:$t},function(){s.props.onEntered(d,u)})})})},n.performExit=function(){var o=this,s=this.props.exit,i=this.getTimeouts(),l=this.props.nodeRef?void 0:sn.findDOMNode(this);if(!s||Ha.disabled){this.safeSetState({status:wt},function(){o.props.onExited(l)});return}this.props.onExit(l),this.safeSetState({status:no},function(){o.props.onExiting(l),o.onTransitionEnd(i.exit,function(){o.safeSetState({status:wt},function(){o.props.onExited(l)})})})},n.cancelNextCallback=function(){this.nextCallback!==null&&(this.nextCallback.cancel(),this.nextCallback=null)},n.safeSetState=function(o,s){s=this.setNextCallback(s),this.setState(o,s)},n.setNextCallback=function(o){var s=this,i=!0;return this.nextCallback=function(l){i&&(i=!1,s.nextCallback=null,o(l))},this.nextCallback.cancel=function(){i=!1},this.nextCallback},n.onTransitionEnd=function(o,s){this.setNextCallback(s);var i=this.props.nodeRef?this.props.nodeRef.current:sn.findDOMNode(this),l=o==null&&!this.props.addEndListener;if(!i||l){setTimeout(this.nextCallback,0);return}if(this.props.addEndListener){var c=this.props.nodeRef?[this.nextCallback]:[i,this.nextCallback],d=c[0],u=c[1];this.props.addEndListener(d,u)}o!=null&&setTimeout(this.nextCallback,o)},n.render=function(){var o=this.state.status;if(o===un)return null;var s=this.props,i=s.children;s.in,s.mountOnEnter,s.unmountOnExit,s.appear,s.enter,s.exit,s.timeout,s.addEndListener,s.onEnter,s.onEntering,s.onEntered,s.onExit,s.onExiting,s.onExited,s.nodeRef;var l=ye(s,["children","in","mountOnEnter","unmountOnExit","appear","enter","exit","timeout","addEndListener","onEnter","onEntering","onEntered","onExit","onExiting","onExited","nodeRef"]);return g.createElement(Ri.Provider,{value:null},typeof i=="function"?i(o,l):g.cloneElement(g.Children.only(i),l))},t}(g.Component);nt.contextType=Ri;nt.propTypes=process.env.NODE_ENV!=="production"?{nodeRef:p.shape({current:typeof Element>"u"?p.any:function(e,t,n,r,o,s){var i=e[t];return p.instanceOf(i&&"ownerDocument"in i?i.ownerDocument.defaultView.Element:Element)(e,t,n,r,o,s)}}),children:p.oneOfType([p.func.isRequired,p.element.isRequired]).isRequired,in:p.bool,mountOnEnter:p.bool,unmountOnExit:p.bool,appear:p.bool,enter:p.bool,exit:p.bool,timeout:function(t){var n=If;t.addEndListener||(n=n.isRequired);for(var r=arguments.length,o=new Array(r>1?r-1:0),s=1;se.scrollTop;function Xa(e,t){var n,r;const{timeout:o,easing:s,style:i={}}=e;return{duration:(n=i.transitionDuration)!=null?n:typeof o=="number"?o:o[t.mode]||0,easing:(r=i.transitionTimingFunction)!=null?r:typeof s=="object"?s[t.mode]:s,delay:i.transitionDelay}}const Df=["addEndListener","appear","children","easing","in","onEnter","onEntered","onEntering","onExit","onExited","onExiting","style","timeout","TransitionComponent"];function ro(e){return`scale(${e}, ${e**2})`}const Bf={entering:{opacity:1,transform:ro(1)},entered:{opacity:1,transform:"none"}},zr=typeof navigator<"u"&&/^((?!chrome|android).)*(safari|mobile)/i.test(navigator.userAgent)&&/(os |version\/)15(.|_)4/i.test(navigator.userAgent),zo=$.forwardRef(function(t,n){const{addEndListener:r,appear:o=!0,children:s,easing:i,in:l,onEnter:c,onEntered:d,onEntering:u,onExit:f,onExited:w,onExiting:b,style:x,timeout:m="auto",TransitionComponent:h=$f}=t,E=ye(t,Df),I=cn(),C=$.useRef(),S=Ci(),v=$.useRef(null),_=yt(v,s.ref,n),V=Y=>F=>{if(Y){const te=v.current;F===void 0?Y(te):Y(te,F)}},U=V(u),j=V((Y,F)=>{Af(Y);const{duration:te,delay:se,easing:oe}=Xa({style:x,timeout:m,easing:i},{mode:"enter"});let y;m==="auto"?(y=S.transitions.getAutoHeightDuration(Y.clientHeight),C.current=y):y=te,Y.style.transition=[S.transitions.create("opacity",{duration:y,delay:se}),S.transitions.create("transform",{duration:zr?y:y*.666,delay:se,easing:oe})].join(","),c&&c(Y,F)}),O=V(d),k=V(b),A=V(Y=>{const{duration:F,delay:te,easing:se}=Xa({style:x,timeout:m,easing:i},{mode:"exit"});let oe;m==="auto"?(oe=S.transitions.getAutoHeightDuration(Y.clientHeight),C.current=oe):oe=F,Y.style.transition=[S.transitions.create("opacity",{duration:oe,delay:te}),S.transitions.create("transform",{duration:zr?oe:oe*.666,delay:zr?te:te||oe*.333,easing:se})].join(","),Y.style.opacity=0,Y.style.transform=ro(.75),f&&f(Y)}),M=V(w),J=Y=>{m==="auto"&&I.start(C.current||0,Y),r&&r(v.current,Y)};return a.jsx(h,R({appear:o,in:l,nodeRef:v,onEnter:j,onEntered:O,onEntering:U,onExit:A,onExited:M,onExiting:k,addEndListener:J,timeout:m==="auto"?null:m},E,{children:(Y,F)=>$.cloneElement(s,R({style:R({opacity:0,transform:ro(.75),visibility:Y==="exited"&&!l?"hidden":void 0},Bf[Y],x,s.props.style),ref:_},F))}))});process.env.NODE_ENV!=="production"&&(zo.propTypes={addEndListener:p.func,appear:p.bool,children:Js.isRequired,easing:p.oneOfType([p.shape({enter:p.string,exit:p.string}),p.string]),in:p.bool,onEnter:p.func,onEntered:p.func,onEntering:p.func,onExit:p.func,onExited:p.func,onExiting:p.func,style:p.object,timeout:p.oneOfType([p.oneOf(["auto"]),p.number,p.shape({appear:p.number,enter:p.number,exit:p.number})])});zo.muiSupportAuto=!0;const Ya=zo,Vf=["anchorEl","component","components","componentsProps","container","disablePortal","keepMounted","modifiers","open","placement","popperOptions","popperRef","transition","slots","slotProps"],zf=In(Ti,{name:"MuiPopper",slot:"Root",overridesResolver:(e,t)=>t.root})({}),Oi=$.forwardRef(function(t,n){var r;const o=di(),s=_o({props:t,name:"MuiPopper"}),{anchorEl:i,component:l,components:c,componentsProps:d,container:u,disablePortal:f,keepMounted:w,modifiers:b,open:x,placement:m,popperOptions:h,popperRef:E,transition:I,slots:C,slotProps:S}=s,v=ye(s,Vf),_=(r=C==null?void 0:C.root)!=null?r:c==null?void 0:c.Root,V=R({anchorEl:i,container:u,disablePortal:f,keepMounted:w,modifiers:b,open:x,placement:m,popperOptions:h,popperRef:E,transition:I},v);return a.jsx(zf,R({as:l,direction:o==null?void 0:o.direction,slots:{root:_},slotProps:S??d},V,{ref:n}))});process.env.NODE_ENV!=="production"&&(Oi.propTypes={anchorEl:p.oneOfType([vn,p.object,p.func]),children:p.oneOfType([p.node,p.func]),component:p.elementType,components:p.shape({Root:p.elementType}),componentsProps:p.shape({root:p.oneOfType([p.func,p.object])}),container:p.oneOfType([vn,p.func]),disablePortal:p.bool,keepMounted:p.bool,modifiers:p.arrayOf(p.shape({data:p.object,effect:p.func,enabled:p.bool,fn:p.func,name:p.any,options:p.object,phase:p.oneOf(["afterMain","afterRead","afterWrite","beforeMain","beforeRead","beforeWrite","main","read","write"]),requires:p.arrayOf(p.string),requiresIfExists:p.arrayOf(p.string)})),open:p.bool.isRequired,placement:p.oneOf(["auto-end","auto-start","auto","bottom-end","bottom-start","bottom","left-end","left-start","left","right-end","right-start","right","top-end","top-start","top"]),popperOptions:p.shape({modifiers:p.array,onFirstUpdate:p.func,placement:p.oneOf(["auto-end","auto-start","auto","bottom-end","bottom-start","bottom","left-end","left-start","left","right-end","right-start","right","top-end","top-start","top"]),strategy:p.oneOf(["absolute","fixed"])}),popperRef:Qs,slotProps:p.shape({root:p.oneOfType([p.func,p.object])}),slots:p.shape({root:p.elementType}),sx:p.oneOfType([p.arrayOf(p.oneOfType([p.func,p.object,p.bool])),p.func,p.object]),transition:p.bool});const _i=Oi;function Lf(e){return ur("MuiTooltip",e)}const Ff=si("MuiTooltip",["popper","popperInteractive","popperArrow","popperClose","tooltip","tooltipArrow","touch","tooltipPlacementLeft","tooltipPlacementRight","tooltipPlacementTop","tooltipPlacementBottom","arrow"]),at=Ff,Gf=["arrow","children","classes","components","componentsProps","describeChild","disableFocusListener","disableHoverListener","disableInteractive","disableTouchListener","enterDelay","enterNextDelay","enterTouchDelay","followCursor","id","leaveDelay","leaveTouchDelay","onClose","onOpen","open","placement","PopperComponent","PopperProps","slotProps","slots","title","TransitionComponent","TransitionProps"];function Uf(e){return Math.round(e*1e5)/1e5}const qf=e=>{const{classes:t,disableInteractive:n,arrow:r,touch:o,placement:s}=e,i={popper:["popper",!n&&"popperInteractive",r&&"popperArrow"],tooltip:["tooltip",r&&"tooltipArrow",o&&"touch",`tooltipPlacement${Ye(s.split("-")[0])}`],arrow:["arrow"]};return No(i,Lf,t)},Hf=In(_i,{name:"MuiTooltip",slot:"Popper",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.popper,!n.disableInteractive&&t.popperInteractive,n.arrow&&t.popperArrow,!n.open&&t.popperClose]}})(({theme:e,ownerState:t,open:n})=>R({zIndex:(e.vars||e).zIndex.tooltip,pointerEvents:"none"},!t.disableInteractive&&{pointerEvents:"auto"},!n&&{pointerEvents:"none"},t.arrow&&{[`&[data-popper-placement*="bottom"] .${at.arrow}`]:{top:0,marginTop:"-0.71em","&::before":{transformOrigin:"0 100%"}},[`&[data-popper-placement*="top"] .${at.arrow}`]:{bottom:0,marginBottom:"-0.71em","&::before":{transformOrigin:"100% 0"}},[`&[data-popper-placement*="right"] .${at.arrow}`]:R({},t.isRtl?{right:0,marginRight:"-0.71em"}:{left:0,marginLeft:"-0.71em"},{height:"1em",width:"0.71em","&::before":{transformOrigin:"100% 100%"}}),[`&[data-popper-placement*="left"] .${at.arrow}`]:R({},t.isRtl?{left:0,marginLeft:"-0.71em"}:{right:0,marginRight:"-0.71em"},{height:"1em",width:"0.71em","&::before":{transformOrigin:"0 0"}})})),Xf=In("div",{name:"MuiTooltip",slot:"Tooltip",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.tooltip,n.touch&&t.touch,n.arrow&&t.tooltipArrow,t[`tooltipPlacement${Ye(n.placement.split("-")[0])}`]]}})(({theme:e,ownerState:t})=>R({backgroundColor:e.vars?e.vars.palette.Tooltip.bg:pi(e.palette.grey[700],.92),borderRadius:(e.vars||e).shape.borderRadius,color:(e.vars||e).palette.common.white,fontFamily:e.typography.fontFamily,padding:"4px 8px",fontSize:e.typography.pxToRem(11),maxWidth:300,margin:2,wordWrap:"break-word",fontWeight:e.typography.fontWeightMedium},t.arrow&&{position:"relative",margin:0},t.touch&&{padding:"8px 16px",fontSize:e.typography.pxToRem(14),lineHeight:`${Uf(16/14)}em`,fontWeight:e.typography.fontWeightRegular},{[`.${at.popper}[data-popper-placement*="left"] &`]:R({transformOrigin:"right center"},t.isRtl?R({marginLeft:"14px"},t.touch&&{marginLeft:"24px"}):R({marginRight:"14px"},t.touch&&{marginRight:"24px"})),[`.${at.popper}[data-popper-placement*="right"] &`]:R({transformOrigin:"left center"},t.isRtl?R({marginRight:"14px"},t.touch&&{marginRight:"24px"}):R({marginLeft:"14px"},t.touch&&{marginLeft:"24px"})),[`.${at.popper}[data-popper-placement*="top"] &`]:R({transformOrigin:"center bottom",marginBottom:"14px"},t.touch&&{marginBottom:"24px"}),[`.${at.popper}[data-popper-placement*="bottom"] &`]:R({transformOrigin:"center top",marginTop:"14px"},t.touch&&{marginTop:"24px"})})),Yf=In("span",{name:"MuiTooltip",slot:"Arrow",overridesResolver:(e,t)=>t.arrow})(({theme:e})=>({overflow:"hidden",position:"absolute",width:"1em",height:"0.71em",boxSizing:"border-box",color:e.vars?e.vars.palette.Tooltip.bg:pi(e.palette.grey[700],.9),"&::before":{content:'""',margin:"auto",display:"block",width:"100%",height:"100%",backgroundColor:"currentColor",transform:"rotate(45deg)"}}));let Gn=!1;const Wa=new On;let an={x:0,y:0};function Un(e,t){return n=>{t&&t(n),e(n)}}const Pi=$.forwardRef(function(t,n){var r,o,s,i,l,c,d,u,f,w,b,x,m,h,E,I,C,S,v;const _=_o({props:t,name:"MuiTooltip"}),{arrow:V=!1,children:U,components:j={},componentsProps:O={},describeChild:k=!1,disableFocusListener:A=!1,disableHoverListener:M=!1,disableInteractive:J=!1,disableTouchListener:Y=!1,enterDelay:F=100,enterNextDelay:te=0,enterTouchDelay:se=700,followCursor:oe=!1,id:y,leaveDelay:T=0,leaveTouchDelay:z=1500,onClose:L,onOpen:B,open:X,placement:q="bottom",PopperComponent:H,PopperProps:G={},slotProps:K={},slots:Z={},title:ue,TransitionComponent:P=Ya,TransitionProps:xe}=_,D=ye(_,Gf),ve=$.isValidElement(U)?U:a.jsx("span",{children:U}),Fe=Ci(),lt=Fe.direction==="rtl",[Se,An]=$.useState(),[Ge,Et]=$.useState(null),ct=$.useRef(!1),jt=J||oe,Tt=cn(),Ct=cn(),dt=cn(),Kt=cn(),[Dn,Fo]=ti({controlled:X,default:!1,name:"Tooltip",state:"open"});let Ke=Dn;if(process.env.NODE_ENV!=="production"){const{current:Q}=$.useRef(X!==void 0);$.useEffect(()=>{Se&&Se.disabled&&!Q&&ue!==""&&Se.tagName.toLowerCase()==="button"&&console.error(["MUI: You are providing a disabled `button` child to the Tooltip component.","A disabled element does not fire events.","Tooltip needs to listen to the child element's events to display the title.","","Add a simple wrapper element, such as a `span`."].join(` +`))},[ue,Se,Q])}const kr=ei(y),Jt=$.useRef(),Bn=Jr(()=>{Jt.current!==void 0&&(document.body.style.WebkitUserSelect=Jt.current,Jt.current=void 0),Kt.clear()});$.useEffect(()=>Bn,[Bn]);const Go=Q=>{Wa.clear(),Gn=!0,Fo(!0),B&&!Ke&&B(Q)},Vn=Jr(Q=>{Wa.start(800+T,()=>{Gn=!1}),Fo(!1),L&&Ke&&L(Q),Tt.start(Fe.transitions.duration.shortest,()=>{ct.current=!1})}),Sr=Q=>{ct.current&&Q.type!=="touchstart"||(Se&&Se.removeAttribute("title"),Ct.clear(),dt.clear(),F||Gn&&te?Ct.start(Gn?te:F,()=>{Go(Q)}):Go(Q))},Uo=Q=>{Ct.clear(),dt.start(T,()=>{Vn(Q)})},{isFocusVisibleRef:qo,onBlur:el,onFocus:tl,ref:nl}=ni(),[,Ho]=$.useState(!1),Xo=Q=>{el(Q),qo.current===!1&&(Ho(!1),Uo(Q))},Yo=Q=>{Se||An(Q.currentTarget),tl(Q),qo.current===!0&&(Ho(!0),Sr(Q))},Wo=Q=>{ct.current=!0;const Oe=ve.props;Oe.onTouchStart&&Oe.onTouchStart(Q)},Ko=Sr,Jo=Uo,rl=Q=>{Wo(Q),dt.clear(),Tt.clear(),Bn(),Jt.current=document.body.style.WebkitUserSelect,document.body.style.WebkitUserSelect="none",Kt.start(se,()=>{document.body.style.WebkitUserSelect=Jt.current,Sr(Q)})},ol=Q=>{ve.props.onTouchEnd&&ve.props.onTouchEnd(Q),Bn(),dt.start(z,()=>{Vn(Q)})};$.useEffect(()=>{if(!Ke)return;function Q(Oe){(Oe.key==="Escape"||Oe.key==="Esc")&&Vn(Oe)}return document.addEventListener("keydown",Q),()=>{document.removeEventListener("keydown",Q)}},[Vn,Ke]);const al=yt(ve.ref,nl,An,n);!ue&&ue!==0&&(Ke=!1);const Er=$.useRef(),sl=Q=>{const Oe=ve.props;Oe.onMouseMove&&Oe.onMouseMove(Q),an={x:Q.clientX,y:Q.clientY},Er.current&&Er.current.update()},Zt={},jr=typeof ue=="string";k?(Zt.title=!Ke&&jr&&!M?ue:null,Zt["aria-describedby"]=Ke?kr:null):(Zt["aria-label"]=jr?ue:null,Zt["aria-labelledby"]=Ke&&!jr?kr:null);const $e=R({},Zt,D,ve.props,{className:ot(D.className,ve.props.className),onTouchStart:Wo,ref:al},oe?{onMouseMove:sl}:{});process.env.NODE_ENV!=="production"&&($e["data-mui-internal-clone-element"]=!0,$.useEffect(()=>{Se&&!Se.getAttribute("data-mui-internal-clone-element")&&console.error(["MUI: The `children` component of the Tooltip is not forwarding its props correctly.","Please make sure that props are spread on the same element that the ref is applied to."].join(` +`))},[Se]));const Qt={};Y||($e.onTouchStart=rl,$e.onTouchEnd=ol),M||($e.onMouseOver=Un(Ko,$e.onMouseOver),$e.onMouseLeave=Un(Jo,$e.onMouseLeave),jt||(Qt.onMouseOver=Ko,Qt.onMouseLeave=Jo)),A||($e.onFocus=Un(Yo,$e.onFocus),$e.onBlur=Un(Xo,$e.onBlur),jt||(Qt.onFocus=Yo,Qt.onBlur=Xo)),process.env.NODE_ENV!=="production"&&ve.props.title&&console.error(["MUI: You have provided a `title` prop to the child of .",`Remove this title prop \`${ve.props.title}\` or the Tooltip component.`].join(` +`));const il=$.useMemo(()=>{var Q;let Oe=[{name:"arrow",enabled:!!Ge,options:{element:Ge,padding:4}}];return(Q=G.popperOptions)!=null&&Q.modifiers&&(Oe=Oe.concat(G.popperOptions.modifiers)),R({},G.popperOptions,{modifiers:Oe})},[Ge,G]),en=R({},_,{isRtl:lt,arrow:V,disableInteractive:jt,placement:q,PopperComponentProp:H,touch:ct.current}),Tr=qf(en),Zo=(r=(o=Z.popper)!=null?o:j.Popper)!=null?r:Hf,Qo=(s=(i=(l=Z.transition)!=null?l:j.Transition)!=null?i:P)!=null?s:Ya,ea=(c=(d=Z.tooltip)!=null?d:j.Tooltip)!=null?c:Xf,ta=(u=(f=Z.arrow)!=null?f:j.Arrow)!=null?u:Yf,ll=dn(Zo,R({},G,(w=K.popper)!=null?w:O.popper,{className:ot(Tr.popper,G==null?void 0:G.className,(b=(x=K.popper)!=null?x:O.popper)==null?void 0:b.className)}),en),cl=dn(Qo,R({},xe,(m=K.transition)!=null?m:O.transition),en),dl=dn(ea,R({},(h=K.tooltip)!=null?h:O.tooltip,{className:ot(Tr.tooltip,(E=(I=K.tooltip)!=null?I:O.tooltip)==null?void 0:E.className)}),en),ul=dn(ta,R({},(C=K.arrow)!=null?C:O.arrow,{className:ot(Tr.arrow,(S=(v=K.arrow)!=null?v:O.arrow)==null?void 0:S.className)}),en);return a.jsxs($.Fragment,{children:[$.cloneElement(ve,$e),a.jsx(Zo,R({as:H??_i,placement:q,anchorEl:oe?{getBoundingClientRect:()=>({top:an.y,left:an.x,right:an.x,bottom:an.y,width:0,height:0})}:Se,popperRef:Er,open:Se?Ke:!1,id:kr,transition:!0},Qt,ll,{popperOptions:il,children:({TransitionProps:Q})=>a.jsx(Qo,R({timeout:Fe.transitions.duration.shorter},Q,cl,{children:a.jsxs(ea,R({},dl,{children:[ue,V?a.jsx(ta,R({},ul,{ref:Et})):null]}))}))}))]})});process.env.NODE_ENV!=="production"&&(Pi.propTypes={arrow:p.bool,children:Js.isRequired,classes:p.object,className:p.string,components:p.shape({Arrow:p.elementType,Popper:p.elementType,Tooltip:p.elementType,Transition:p.elementType}),componentsProps:p.shape({arrow:p.object,popper:p.object,tooltip:p.object,transition:p.object}),describeChild:p.bool,disableFocusListener:p.bool,disableHoverListener:p.bool,disableInteractive:p.bool,disableTouchListener:p.bool,enterDelay:p.number,enterNextDelay:p.number,enterTouchDelay:p.number,followCursor:p.bool,id:p.string,leaveDelay:p.number,leaveTouchDelay:p.number,onClose:p.func,onOpen:p.func,open:p.bool,placement:p.oneOf(["bottom-end","bottom-start","bottom","left-end","left-start","left","right-end","right-start","right","top-end","top-start","top"]),PopperComponent:p.elementType,PopperProps:p.object,slotProps:p.shape({arrow:p.object,popper:p.object,tooltip:p.object,transition:p.object}),slots:p.shape({arrow:p.elementType,popper:p.elementType,tooltip:p.elementType,transition:p.elementType}),sx:p.oneOfType([p.arrayOf(p.oneOfType([p.func,p.object,p.bool])),p.func,p.object]),title:p.node,TransitionComponent:p.elementType,TransitionProps:p.object});const Wf=Pi;function Ka(e,t,n){return e?a.jsx(Ie.ListItemIcon,{className:`papi-menu-icon-${n?"leading":"trailing"}`,children:a.jsx("img",{src:e,alt:`${n?"Leading":"Trailing"} icon for ${t}`})}):void 0}function Lo(e){const{onClick:t,label:n,tooltip:r,allowForLeadingIcons:o=!0,iconPathBefore:s=void 0,iconPathAfter:i=void 0,hasAutoFocus:l=!1,className:c,isDisabled:d=!1,isDense:u=!0,isSubMenuParent:f=!1,hasDisabledGutters:w=!1,hasDivider:b=!1,focusVisibleClassName:x,id:m,children:h}=e,E=a.jsx(Ie.MenuItem,{sx:{lineHeight:.8},autoFocus:l,className:c,disabled:d,dense:u,disableGutters:w,divider:b,focusVisibleClassName:x,onClick:t,id:m,children:n?a.jsxs(a.Fragment,{children:[Ka(s,n,!0),a.jsx(Ie.ListItemText,{primary:n,inset:!s&&o}),f?a.jsx(Ie.ListItemIcon,{className:"papi-menu-icon-trailing",children:a.jsx(fi,{})}):Ka(i,n,!1)]}):h});return r?a.jsx(Wf,{title:r,placement:"right",children:a.jsx("div",{children:E})}):E}function Ii(e){return Object.entries(e.groups).map(([n,r])=>({id:n,group:r}))}function Kf(e){const[t,n]=g.useState(void 0),{parentMenuItem:r,parentItemProps:o,menuDefinition:s}=e,i=d=>{n(d.currentTarget)},l=()=>{n(void 0)},c=()=>{let d=Ii(s).filter(u=>"menuItem"in u.group);if(!(r!=null&&r.id))throw new Error("A valid parent menu item is required for submenus.");return d=d.filter(u=>"menuItem"in u.group&&u.group.menuItem===r.id),a.jsx(Mi,{...e,includedGroups:d})};return a.jsxs(a.Fragment,{children:[a.jsx(Lo,{onClick:i,...o,isSubMenuParent:!0}),a.jsx(Ie.Menu,{anchorEl:t,open:!!t,onClose:l,anchorOrigin:{vertical:"top",horizontal:"right"},transformOrigin:{vertical:"top",horizontal:"left"},children:c()},r.id)]})}const Jf=(e,t)=>t.filter(o=>o.group===e).sort((o,s)=>(o.order||0)-(s.order||0));function Mi(e){const{menuDefinition:t,onClick:n,commandHandler:r,includedGroups:o}=e,{items:s,allowForLeadingIcons:i}=g.useMemo(()=>{const u=o&&o.length>0?o:Ii(t).filter(x=>!("menuItem"in x.group)),f=Object.values(u).sort((x,m)=>(x.group.order||0)-(m.group.order||0)),w=[];f.forEach(x=>{Jf(x.id,t.items).forEach(m=>w.push({item:m,isLastItemInGroup:!1})),w.length>0&&(w[w.length-1].isLastItemInGroup=!0)}),w.length>0&&(w[w.length-1].isLastItemInGroup=!1);const b=w.some(x=>"iconPathBefore"in x.item&&x.item.iconPathBefore);return{items:w,allowForLeadingIcons:b}},[o,t]),l=({item:u,isLastItemInGroup:f})=>({className:"papi-menu-item",label:u.label,tooltip:u.tooltip,iconPathBefore:"iconPathBefore"in u?u.iconPathBefore:void 0,iconPathAfter:"iconPathAfter"in u?u.iconPathAfter:void 0,hasDivider:f,allowForLeadingIcons:i}),[c]=s;if(!c)return a.jsx("div",{});const d=c.item.group;return a.jsx("div",{role:"menu","aria-label":d,children:s.map((u,f)=>{const{item:w}=u,b=l(u);if("command"in w){const x=w.group+f;return a.jsx(Lo,{onClick:m=>{n==null||n(m),r(w)},...b},x)}return a.jsx(Kf,{parentMenuItem:w,parentItemProps:b,...e},d+w.id)})},d)}function Zf(e){const{menuDefinition:t,columnId:n}=e;let s=Object.entries(t.groups).map(([i,l])=>({id:i,group:l})).filter(i=>"column"in i.group);return n&&"columns"in t&&t.columns[n]&&(s=s.filter(i=>"column"in i.group&&i.group.column===n)),a.jsx(Mi,{...e,includedGroups:s})}function Qf({commandHandler:e,menuDefinition:t,id:n,metadata:r,onClick:o,className:s}){return a.jsxs(Ie.Grid,{id:n,item:!0,xs:"auto",role:"menu","aria-label":n,className:`papi-menu-column ${s??""}`,children:[a.jsx("h3",{"aria-label":r.label,className:`papi-menu-column-header ${s??""}`,children:r.label}),a.jsx(Ie.List,{id:n,dense:!0,className:s??"",children:a.jsx(Zf,{commandHandler:e,menuDefinition:t,columnId:n,onClick:o})})]})}function $i({commandHandler:e,className:t,multiColumnMenu:n,id:r}){const{columns:o}=n,s=g.useMemo(()=>{const i=new Map;return Object.getOwnPropertyNames(o).forEach(l=>{if(l==="isExtensible")return;const c=l,d=o[c];typeof d=="object"&&typeof d.order=="number"&&!Number.isNaN(d.order)?i.set(d.order,{id:c,metadata:d}):console.warn(`Property ${l} (${typeof d}) on menu ${r} is not a valid column and is being ignored. This might indicate data corruption`)}),Array.from(i.values()).sort((l,c)=>(l.metadata.order||0)-(c.metadata.order||0))},[o,r]);return a.jsx(Ie.Grid,{container:!0,spacing:0,className:`papi-multi-column-menu ${t??""}`,columns:s.length,role:"menu","aria-label":"GridMenu",id:r,children:s.map((i,l)=>a.jsx(Qf,{commandHandler:e,menuDefinition:n,...i,className:t},l))})}function em(e){return{preserveValue:!0,...e}}const nr=(e,t,n={})=>{const r=g.useRef(t);r.current=t;const o=g.useRef(n);o.current=em(o.current);const[s,i]=g.useState(()=>r.current),[l,c]=g.useState(!0);return g.useEffect(()=>{let d=!0;return c(!!e),(async()=>{if(e){const u=await e();d&&(i(()=>u),c(!1))}})(),()=>{d=!1,o.current.preserveValue||i(()=>r.current)}},[e]),[s,l]},tm=wi(a.jsx("path",{d:"M3 18h18v-2H3zm0-5h18v-2H3zm0-7v2h18V6z"}),"Menu");function Ai({menuProvider:e,normalMenu:t,fullMenu:n,commandHandler:r,containerRef:o,className:s,ariaLabelPrefix:i,children:l}){const[c,d]=g.useState(!1),[u,f]=g.useState(!1),w=g.useCallback(()=>{c&&d(!1),f(!1)},[c]),b=g.useCallback(S=>{S.stopPropagation(),d(v=>{const _=!v;return _&&S.shiftKey?f(!0):_||f(!1),_})},[]),x=g.useCallback(S=>(w(),r(S)),[r,w]),[m,h]=g.useState({top:1,left:1});g.useEffect(()=>{if(c){const S=o==null?void 0:o.current;if(S){const v=S.getBoundingClientRect(),_=window.scrollY,V=window.scrollX,U=v.top+_+S.clientHeight,j=v.left+V;h({top:U,left:j})}}},[c,o]);const[E]=nr(g.useCallback(async()=>(e==null?void 0:e(!1))??t,[e,t,c]),t),[I]=nr(g.useCallback(async()=>(e==null?void 0:e(!0))??n??E,[e,n,E,c]),n??E),C=u&&I?I:E;return a.jsxs(a.Fragment,{children:[a.jsx(Ie.IconButton,{sx:{paddingTop:0,paddingBottom:0},edge:"start",className:`papi-menuButton ${s??""}`,color:"inherit","aria-label":`${i??""} menu button`,onClick:b,children:l??a.jsx(tm,{})}),a.jsx(Ie.Drawer,{className:`papi-menu-drawer ${s??""}`,anchor:"left",variant:"temporary",open:c,onClose:w,PaperProps:{className:"papi-menu-drawer-paper",style:{top:m.top,left:m.left}},children:C?a.jsx($i,{className:s,id:`${i??""} main menu`,commandHandler:x,multiColumnMenu:C}):void 0})]})}function nm({id:e,label:t,isDisabled:n=!1,tooltip:r,isTooltipSuppressed:o=!1,adjustMarginToAlignToEdge:s=!1,size:i="medium",className:l,onClick:c,children:d}){return a.jsx(Ie.IconButton,{id:e,disabled:n,edge:s,size:i,"aria-label":t,title:o?void 0:r??t,className:`papi-icon-button ${l??""}`,onClick:c,children:d})}const Wt=g.forwardRef(({className:e,...t},n)=>a.jsx(ee.LoaderCircle,{size:35,className:N("tw-animate-spin",e),...t,ref:n}));Wt.displayName="Spinner";function rm({id:e,isDisabled:t=!1,hasError:n=!1,isFullWidth:r=!1,helperText:o,label:s,placeholder:i,isRequired:l=!1,className:c,defaultValue:d,value:u,onChange:f,onFocus:w,onBlur:b}){return a.jsxs("div",{className:N("tw-inline-grid tw-items-center tw-gap-1.5",{"tw-w-full":r}),children:[a.jsx(Ue,{htmlFor:e,className:N({"tw-text-red-600":n,"tw-hidden":!s}),children:`${s}${l?"*":""}`}),a.jsx(St,{id:e,disabled:t,placeholder:i,required:l,className:N(c,{"tw-border-red-600":n}),defaultValue:d,value:u,onChange:f,onFocus:w,onBlur:b}),a.jsx("p",{className:N({"tw-hidden":!o}),children:o})]})}function om({menuProvider:e,commandHandler:t,className:n,id:r,children:o}){const s=g.useRef(void 0);return a.jsx("div",{ref:s,style:{position:"relative"},children:a.jsx(Ie.AppBar,{position:"static",id:r,children:a.jsxs(Ie.Toolbar,{className:N("tw-bg-muted tw-text-muted-foreground",n),variant:"dense",children:[e?a.jsx(Ai,{commandHandler:t,containerRef:s,menuProvider:e}):void 0,o?a.jsx("div",{className:"papi-toolbar-children",children:o}):void 0]})})})}const am=kn.cva("tw-relative tw-w-full tw-rounded-lg tw-border tw-p-4 [&>svg~*]:tw-pl-7 [&>svg+div]:tw-translate-y-[-3px] [&>svg]:tw-absolute [&>svg]:tw-left-4 [&>svg]:tw-top-4 [&>svg]:tw-text-foreground",{variants:{variant:{default:"tw-bg-background tw-text-foreground",destructive:"tw-border-destructive/50 tw-text-destructive dark:tw-border-destructive [&>svg]:tw-text-destructive"}},defaultVariants:{variant:"default"}}),Di=g.forwardRef(({className:e,variant:t,...n},r)=>a.jsx("div",{ref:r,role:"alert",className:N(am({variant:t}),e),...n}));Di.displayName="Alert";const Bi=g.forwardRef(({className:e,...t},n)=>a.jsxs("h5",{ref:n,className:N("tw-mb-1 tw-font-medium tw-leading-none tw-tracking-tight",e),...t,children:[t.children," "]}));Bi.displayName="AlertTitle";const Vi=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,className:N("tw-text-sm [&_p]:tw-leading-relaxed",e),...t}));Vi.displayName="AlertDescription";const zi=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,className:N("pr-twp tw-rounded-lg tw-border tw-bg-card tw-text-card-foreground tw-shadow-sm",e),...t}));zi.displayName="Card";const Li=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,className:N("pr-twp tw-flex tw-flex-col tw-space-y-1.5 tw-p-6",e),...t}));Li.displayName="CardHeader";const Fi=g.forwardRef(({className:e,...t},n)=>a.jsx("h3",{ref:n,className:N("pr-twp tw-text-2xl tw-font-semibold tw-leading-none tw-tracking-tight",e),...t,children:t.children}));Fi.displayName="CardTitle";const Gi=g.forwardRef(({className:e,...t},n)=>a.jsx("p",{ref:n,className:N("pr-twp tw-text-sm tw-text-muted-foreground",e),...t}));Gi.displayName="CardDescription";const Ui=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,className:N("pr-twp tw-p-6 tw-pt-0",e),...t}));Ui.displayName="CardContent";const qi=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,className:N("pr-twp tw-flex tw-items-center tw-p-6 tw-pt-0",e),...t}));qi.displayName="CardFooter";function sm({...e}){return a.jsx(Za.Toaster,{className:"tw-toaster tw-group",toastOptions:{classNames:{toast:"group toast group-[.toaster]:bg-background group-[.toaster]:text-foreground group-[.toaster]:border-border group-[.toaster]:shadow-lg",description:"group-[.toast]:text-muted-foreground",actionButton:"group-[.toast]:bg-primary group-[.toast]:text-primary-foreground",cancelButton:"group-[.toast]:bg-muted group-[.toast]:text-muted-foreground"}},...e})}const Hi=g.forwardRef(({className:e,...t},n)=>a.jsxs(ln.Root,{ref:n,className:N("pr-twp tw-relative tw-flex tw-w-full tw-touch-none tw-select-none tw-items-center",e),...t,children:[a.jsx(ln.Track,{className:"tw-relative tw-h-2 tw-w-full tw-grow tw-overflow-hidden tw-rounded-full tw-bg-secondary",children:a.jsx(ln.Range,{className:"tw-absolute tw-h-full tw-bg-primary"})}),a.jsx(ln.Thumb,{className:"tw-block tw-h-5 tw-w-5 tw-rounded-full tw-border-2 tw-border-primary tw-bg-background tw-ring-offset-background tw-transition-colors focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50"})]}));Hi.displayName=ln.Root.displayName;const Xi=g.forwardRef(({className:e,...t},n)=>a.jsx(Ur.Root,{className:N("tw-peer pr-twp tw-inline-flex tw-h-6 tw-w-11 tw-shrink-0 tw-cursor-pointer tw-items-center tw-rounded-full tw-border-2 tw-border-transparent tw-transition-colors focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 focus-visible:tw-ring-offset-background disabled:tw-cursor-not-allowed disabled:tw-opacity-50 data-[state=checked]:tw-bg-primary data-[state=unchecked]:tw-bg-input",e),...t,ref:n,children:a.jsx(Ur.Thumb,{className:N("pr-twp tw-pointer-events-none tw-block tw-h-5 tw-w-5 tw-rounded-full tw-bg-background tw-shadow-lg tw-ring-0 tw-transition-transform data-[state=checked]:tw-translate-x-5 data-[state=unchecked]:tw-translate-x-0")})}));Xi.displayName=Ur.Root.displayName;const im=Re.Root,Yi=g.forwardRef(({className:e,...t},n)=>a.jsx(Re.List,{ref:n,className:N("tw-inline-flex tw-h-10 tw-items-center tw-justify-center tw-rounded-md tw-bg-muted tw-p-1 tw-text-muted-foreground",e),...t}));Yi.displayName=Re.List.displayName;const Wi=g.forwardRef(({className:e,...t},n)=>a.jsx(Re.Trigger,{ref:n,className:N("tw-inline-flex tw-items-center tw-justify-center tw-whitespace-nowrap tw-rounded-sm tw-px-3 tw-py-1.5 tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-all hover:tw-text-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50 data-[state=active]:tw-bg-background data-[state=active]:tw-text-foreground data-[state=active]:tw-shadow-sm",e),...t}));Wi.displayName=Re.Trigger.displayName;const Ki=g.forwardRef(({className:e,...t},n)=>a.jsx(Re.Content,{ref:n,className:N("tw-mt-2 tw-ring-offset-background focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2",e),...t}));Ki.displayName=Re.Content.displayName;function lm({isInstalling:e,handleClick:t,buttonText:n,className:r,...o}){return a.jsx(fe,{className:N("tw-h-8 tw-rounded-md tw-text-white tw-transition tw-duration-300 tw-ease-in-out hover:tw-bg-blue-700",{"tw-cursor-not-allowed tw-bg-blue-700":e,"tw-bg-blue-600":!e,"tw-bg-white tw-text-blue-600 hover:tw-text-white":!n,"tw-w-20":n},r),onClick:t,...o,children:e?a.jsx(Wt,{size:15}):a.jsxs(a.Fragment,{children:[a.jsx(ee.Download,{size:25,className:N("tw-h-4 tw-w-4",{"tw-mr-1":n})}),n]})})}function cm({isEnabling:e,handleClick:t,className:n,...r}){return a.jsx(fe,{className:N("tw-h-8 tw-rounded-md tw-bg-blue-600 tw-px-4 tw-text-white tw-transition tw-duration-300 tw-ease-in-out hover:tw-bg-blue-700",{"tw-cursor-not-allowed tw-bg-blue-700":e},n),onClick:t,...r,children:e?a.jsxs(a.Fragment,{children:[a.jsx(Wt,{size:15,className:"tw-mr-1 tw-text-white"}),"Enabling..."]}):"Enable"})}function dm({isDisabling:e,handleClick:t,className:n,...r}){return a.jsx(fe,{className:N("tw-h-8 tw-rounded-md tw-bg-gray-300 tw-text-black tw-transition tw-duration-300 tw-ease-in-out hover:tw-bg-gray-400",{"tw-cursor-not-allowed tw-bg-gray-400":e},n),onClick:t,...r,children:e?a.jsxs(a.Fragment,{children:[a.jsx(Wt,{size:15,className:"tw-mr-1 tw-text-black"}),"Disabling..."]}):"Disable"})}function um({isUpdating:e,handleClick:t,className:n,...r}){return a.jsx(fe,{className:N("tw-h-8 tw-rounded-md tw-bg-blue-600 tw-px-4 tw-text-white tw-transition tw-duration-300 tw-ease-in-out hover:tw-bg-blue-700 hover:tw-text-white",{"tw-cursor-not-allowed tw-bg-blue-700":e},n),onClick:t,...r,children:e?a.jsxs(a.Fragment,{children:[a.jsx(Wt,{size:15,className:"tw-mr-1 tw-text-white"}),"Updating..."]}):"Update"})}function pm({id:e,markdown:t,className:n,anchorTarget:r}){const o=g.useMemo(()=>({overrides:{a:{props:{target:r}}}}),[r]);return a.jsx("div",{id:e,className:N("pr-twp tw-prose",n),children:a.jsx(jl,{options:o,children:t})})}const Ji=g.forwardRef((e,t)=>a.jsxs(fe,{ref:t,className:"tw-rounded-md tw-border tw-border-dashed tw-border-gray-400 tw-bg-white tw-px-4 tw-py-2 tw-text-black tw-transition tw-duration-300 tw-ease-in-out hover:tw-border-blue-600 hover:tw-bg-white hover:tw-text-blue-600",...e,children:[a.jsx(ee.Filter,{size:16,className:"tw-mr-2 tw-h-4 tw-w-4 tw-text-gray-700 hover:tw-text-blue-600"}),"Filter",a.jsx(ee.ChevronDown,{size:16,className:"tw-ml-2 tw-h-4 tw-w-4 tw-text-gray-700 hover:tw-text-blue-600"})]}));var Zi=(e=>(e[e.Check=0]="Check",e[e.Radio=1]="Radio",e))(Zi||{});function wm({id:e,groups:t}){return a.jsx("div",{id:e,children:a.jsxs(or,{children:[a.jsx(io,{asChild:!0,children:a.jsx(Ji,{})}),a.jsx(En,{children:t.map(n=>a.jsxs("div",{children:[a.jsx(Yt,{children:n.label}),a.jsx(ls,{children:n.items.map(r=>a.jsx("div",{children:r.itemType===0?a.jsx(ar,{onClick:r.onClick,children:r.label}):a.jsx(co,{onClick:r.onClick,value:r.label,children:r.label})},r.label))}),a.jsx(jn,{})]},n.label))})]})})}function fm({id:e,message:t}){return a.jsx("div",{id:e,className:"tw-mb-20 tw-mt-20 tw-flex tw-items-center tw-justify-center",children:a.jsx("div",{className:"tw-w-3/4 tw-rounded-lg tw-bg-gray-100 tw-p-8 tw-text-center",children:a.jsx("p",{className:"tw-text-lg tw-text-gray-800",children:t})})})}function mm({id:e,category:t,downloads:n,languages:r,moreInfoUrl:o}){const s=new W.NumberFormat("en",{notation:"compact",compactDisplay:"short"}).format(Object.values(n).reduce((l,c)=>l+c,0)),i=()=>{window.scrollTo(0,document.body.scrollHeight)};return a.jsxs("div",{id:e,className:"tw-flex tw-flex-wrap tw-items-start tw-space-x-4 tw-border-b tw-border-t tw-bg-white tw-pb-4 tw-pt-4",children:[a.jsxs("div",{className:"tw-flex tw-flex-col tw-items-center",children:[a.jsx("div",{className:"tw-flex tw-items-center tw-rounded-md tw-bg-gray-100 tw-px-2 tw-py-1",children:a.jsx("span",{className:"tw-text-xs tw-font-semibold tw-text-gray-700",children:t})}),a.jsx("span",{className:"tw-text-xs tw-text-gray-500",children:"CATEGORY"})]}),a.jsx("div",{className:"tw-mx-2 tw-h-10 tw-border-l tw-border-gray-300"}),a.jsxs("div",{className:"tw-flex tw-flex-col tw-items-center",children:[a.jsxs("div",{className:"tw-flex tw-items-center tw-rounded-md tw-bg-gray-100 tw-px-2 tw-py-1",children:[a.jsx(ee.User,{className:"tw-mr-1 tw-h-4 tw-w-4"}),a.jsx("span",{className:"tw-text-xs tw-font-semibold tw-text-gray-700",children:s})]}),a.jsx("span",{className:"tw-text-xs tw-text-gray-500",children:"USERS"})]}),a.jsx("div",{className:"tw-mx-2 tw-h-10 tw-border-l tw-border-gray-300"}),a.jsxs("div",{className:"tw-flex tw-flex-col tw-items-center",children:[a.jsx("div",{className:"tw-flex tw-items-center",children:r.slice(0,3).map(l=>a.jsx("span",{className:"tw-ml-1 tw-rounded-md tw-bg-gray-100 tw-px-2 tw-py-1 tw-text-xs tw-font-semibold tw-text-gray-700",children:l.toUpperCase()},l))}),r.length>3&&a.jsxs("button",{type:"button",onClick:()=>i(),className:"tw-text-xs tw-text-gray-500 tw-underline",children:["+",r.length-3," more languages"]})]}),a.jsx("div",{className:"tw-mx-2 tw-h-10 tw-border-l tw-border-gray-300"}),a.jsxs("div",{className:"tw-ml-auto tw-flex tw-flex-col tw-space-y-2",children:[a.jsxs("a",{href:o,target:"_blank",rel:"noreferrer",className:"tw-flex tw-items-center tw-text-xs tw-font-semibold tw-text-gray-500 tw-underline",children:["Website",a.jsx(ee.Link,{className:"tw-ml-1 tw-inline tw-h-4 tw-w-4"})]}),a.jsxs("a",{href:"https://example.com",target:"_blank",rel:"noreferrer",className:"tw-flex tw-items-center tw-text-xs tw-font-semibold tw-text-gray-500 tw-underline",children:["Support",a.jsx(ee.CircleHelp,{className:"tw-ml-1 tw-inline tw-h-4 tw-w-4"})]})]})]})}function Qi({id:e,versionHistory:t}){const[n,r]=g.useState(!1),o=new Date;function s(l){const c=new Date(l),d=new Date(o.getTime()-c.getTime()),u=d.getUTCFullYear()-1970,f=d.getUTCMonth(),w=d.getUTCDate()-1;let b="";return u>0?b=`${u.toString()} year${u===1?"":"s"} ago`:f>0?b=`${f.toString()} month${f===1?"":"s"} ago`:w===0?b="today":b=`${w.toString()} day${w===1?"":"s"} ago`,b}const i=Object.entries(t).sort((l,c)=>c[0].localeCompare(l[0]));return a.jsxs("div",{id:e,children:[a.jsx("h3",{className:"tw-text-md tw-font-semibold",children:"What`s New"}),a.jsx("ul",{className:"tw-list-disc tw-pl-5 tw-pr-4 tw-text-xs tw-text-gray-600",children:(n?i:i.slice(0,5)).map(l=>a.jsxs("div",{className:"tw-mt-3 tw-flex tw-justify-between",children:[a.jsx("div",{className:"tw-text-gray-600",children:a.jsx("li",{className:"tw-prose tw-text-xs",children:a.jsx("span",{children:l[1].description})})}),a.jsxs("div",{className:"tw-justify-end tw-text-right",children:[a.jsxs("div",{children:["Version ",l[0]]}),a.jsx("div",{children:s(l[1].date)})]})]},l[0]))}),i.length>5&&a.jsx("button",{type:"button",onClick:()=>r(!n),className:"tw-text-xs tw-text-gray-500 tw-underline",children:n?"Show Less Version History":"Show All Version History"})]})}function hm({id:e,publisherDisplayName:t,fileSize:n,locales:r,versionHistory:o}){const s=g.useMemo(()=>W.formatBytes(n),[n]),l=(c=>{const d=new Intl.DisplayNames(navigator.language,{type:"language"});return c.map(u=>d.of(u))})(r);return a.jsx("div",{id:e,className:"tw-border-t tw-pb-4 tw-pt-4",children:a.jsxs("div",{className:"tw-md:flex-row tw-md:space-x-8 tw-flex tw-flex-col tw-space-x-0",children:[a.jsx(Qi,{versionHistory:o}),a.jsx("div",{className:"tw-md:border-t-0 tw-md:border-l tw-md-h-auto tw-md-ml-8 tw-mt-4 tw-border-t tw-border-gray-300"}),a.jsxs("div",{className:"tw-md:mt-0 tw-mt-4 tw-flex-1 tw-space-y-3",children:[a.jsx("h2",{className:"tw-text-md tw-font-semibold",children:"Information"}),a.jsxs("div",{className:"tw-flex tw-items-start tw-justify-between tw-pr-4 tw-text-xs tw-text-gray-600",children:[a.jsxs("p",{className:"tw-flex tw-flex-col tw-justify-start",children:[a.jsx("span",{className:"tw-mb-2",children:"Publisher"}),a.jsx("span",{className:"tw-font-semibold",children:t}),a.jsx("span",{className:"tw-mb-2 tw-mt-4",children:"Size"}),a.jsx("span",{className:"tw-font-semibold",children:s})]}),a.jsx("div",{className:"tw-flex tw-w-3/4 tw-items-center tw-justify-between tw-text-xs tw-text-gray-600",children:a.jsxs("p",{className:"tw-flex tw-flex-col tw-justify-start",children:[a.jsx("span",{className:"tw-mb-2",children:"Languages"}),a.jsx("span",{className:"tw-font-semibold",children:l.join(", ")})]})})]})]})]})})}const gm=(e,t)=>{g.useEffect(()=>{if(!e)return()=>{};const n=e(t);return()=>{n()}},[e,t])},Lr=()=>!1,bm=(e,t)=>{const[n]=nr(g.useCallback(async()=>{if(!e)return Lr;const r=await Promise.resolve(e(t));return async()=>r()},[t,e]),Lr,{preserveValue:!1});g.useEffect(()=>()=>{n!==Lr&&n()},[n])};Object.defineProperty(exports,"sonner",{enumerable:!0,get:()=>Za.toast});exports.Alert=Di;exports.AlertDescription=Vi;exports.AlertTitle=Bi;exports.BOOK_SELECTOR_STRING_KEYS=pc;exports.BookChapterControl=tc;exports.BookSelectionMode=ys;exports.BookSelector=wc;exports.Button=fe;exports.Card=zi;exports.CardContent=Ui;exports.CardDescription=Gi;exports.CardFooter=qi;exports.CardHeader=Li;exports.CardTitle=Fi;exports.ChapterRangeSelector=xs;exports.Checkbox=sr;exports.Checklist=ad;exports.ComboBox=Wn;exports.DataTable=Ts;exports.DisableButton=dm;exports.DropdownMenu=or;exports.DropdownMenuCheckboxItem=ar;exports.DropdownMenuContent=En;exports.DropdownMenuGroup=ls;exports.DropdownMenuItem=lo;exports.DropdownMenuItemType=Zi;exports.DropdownMenuLabel=Yt;exports.DropdownMenuPortal=Fl;exports.DropdownMenuRadioGroup=Ul;exports.DropdownMenuRadioItem=co;exports.DropdownMenuSeparator=jn;exports.DropdownMenuShortcut=us;exports.DropdownMenuSub=Gl;exports.DropdownMenuSubContent=ds;exports.DropdownMenuSubTrigger=cs;exports.DropdownMenuTrigger=io;exports.EnableButton=cm;exports.FilterButton=Ji;exports.FilterDropdown=wm;exports.Footer=hm;exports.GridMenu=$i;exports.HamburgerMenuButton=Ai;exports.INVENTORY_STRING_KEYS=Nc;exports.IconButton=nm;exports.Input=St;exports.InstallButton=lm;exports.Inventory=Ec;exports.Label=Ue;exports.MarkdownRenderer=pm;exports.MenuItem=Lo;exports.MoreInfo=mm;exports.NavigationContentSearch=jc;exports.NoExtensionsFound=fm;exports.RadioGroup=uo;exports.RadioGroupItem=Yn;exports.ScriptureResultsViewer=ed;exports.ScrollGroupSelector=td;exports.SearchBar=mo;exports.Select=Dt;exports.SelectContent=vt;exports.SelectGroup=Ns;exports.SelectItem=Ae;exports.SelectLabel=ks;exports.SelectScrollDownButton=wo;exports.SelectScrollUpButton=po;exports.SelectSeparator=Ss;exports.SelectTrigger=bt;exports.SelectValue=Bt;exports.Separator=lr;exports.SettingsList=nd;exports.SettingsListHeader=od;exports.SettingsListItem=rd;exports.SettingsSidebar=Gs;exports.SettingsSidebarContentSearch=Hc;exports.Slider=Hi;exports.Sonner=sm;exports.Spinner=Wt;exports.Switch=Xi;exports.Table=Tn;exports.TableBody=Rn;exports.TableCaption=js;exports.TableCell=xt;exports.TableFooter=Es;exports.TableHead=Vt;exports.TableHeader=Cn;exports.TableRow=Ze;exports.Tabs=im;exports.TabsContent=Ki;exports.TabsList=Yi;exports.TabsTrigger=Wi;exports.TextField=rm;exports.ToggleGroup=fo;exports.ToggleGroupItem=wn;exports.Toolbar=om;exports.UpdateButton=um;exports.VersionHistory=Qi;exports.VerticalTabs=ho;exports.VerticalTabsContent=bo;exports.VerticalTabsList=go;exports.VerticalTabsTrigger=Is;exports.buttonVariants=ps;exports.cn=N;exports.getBookNumFromId=Rs;exports.getLinesFromUSFM=Cs;exports.getNumberFromUSFM=qr;exports.getStatusForItem=Os;exports.inventoryCountColumn=xc;exports.inventoryItemColumn=bc;exports.inventoryStatusColumn=yc;exports.useEvent=gm;exports.useEventAsync=bm;exports.usePromise=nr;function vm(e,t="top"){if(!e||typeof document>"u")return;const n=document.head||document.querySelector("head"),r=n.querySelector(":first-child"),o=document.createElement("style");o.appendChild(document.createTextNode(e)),t==="top"&&r?n.insertBefore(o,r):n.appendChild(o)}vm(`*, ::before, ::after { --tw-border-spacing-x: 0; --tw-border-spacing-y: 0; --tw-translate-x: 0; @@ -3523,32 +3523,6 @@ video:where(.pr-twp,.pr-twp *) { .banded-row[data-state='selected']:hover { cursor: default; } -.papi-icon-button { - border: 0; - border-radius: 3em; - cursor: pointer; - display: inline-block; -} - -.papi-icon-button.primary { - background-color: #1ea7fd; - color: white; -} - -.papi-icon-button.secondary { - background-color: transparent; - color: #333; -} - -.papi-icon-button.paratext { - background-color: darkgreen; - color: greenyellow; -} - -.papi-icon-button.paratext.bright { - background-color: greenyellow; - color: darkgreen; -} .papi-multi-column-menu { background-color: rgb(222, 222, 222); display: flex; @@ -3583,6 +3557,32 @@ video:where(.pr-twp,.pr-twp *) { color: rgb(76, 106, 76); background-color: rgb(214, 255, 152); } +.papi-icon-button { + border: 0; + border-radius: 3em; + cursor: pointer; + display: inline-block; +} + +.papi-icon-button.primary { + background-color: #1ea7fd; + color: white; +} + +.papi-icon-button.secondary { + background-color: transparent; + color: #333; +} + +.papi-icon-button.paratext { + background-color: darkgreen; + color: greenyellow; +} + +.papi-icon-button.paratext.bright { + background-color: greenyellow; + color: darkgreen; +} .papi-menu-item { background-color: transparent; } diff --git a/lib/platform-bible-react/dist/index.cjs.map b/lib/platform-bible-react/dist/index.cjs.map index 4e50b1b632..902d5fa2d6 100644 --- a/lib/platform-bible-react/dist/index.cjs.map +++ b/lib/platform-bible-react/dist/index.cjs.map @@ -1 +1 @@ -{"version":3,"file":"index.cjs","sources":["../src/utils/shadcn-ui.util.ts","../src/components/shadcn-ui/input.tsx","../src/components/advanced/book-chapter-control/book-chapter-input.component.tsx","../../../node_modules/@sillsdev/scripture/dist/index.es.js","../src/components/shadcn-ui/dropdown-menu.tsx","../src/components/advanced/book-chapter-control/book-menu-item.component.tsx","../src/components/advanced/book-chapter-control/chapter-select.component.tsx","../src/components/advanced/book-chapter-control/go-to-menu-item.component.tsx","../src/components/advanced/book-chapter-control/book-chapter-control.component.tsx","../src/components/shadcn-ui/button.tsx","../src/components/shadcn-ui/label.tsx","../src/components/shadcn-ui/radio-group.tsx","../src/components/shadcn-ui/popover.tsx","../src/components/shadcn-ui/dialog.tsx","../src/components/shadcn-ui/command.tsx","../src/components/basics/combo-box.component.tsx","../src/components/basics/chapter-range-selector.component.tsx","../src/components/advanced/book-selector.component.tsx","../src/components/advanced/data-table/data-table-column-toggle.component.tsx","../src/components/shadcn-ui/select.tsx","../src/components/advanced/data-table/data-table-pagination.component.tsx","../src/components/shadcn-ui/table.tsx","../src/components/advanced/data-table/data-table.component.tsx","../src/components/advanced/inventory/occurrences-table.component.tsx","../src/components/shadcn-ui/checkbox.tsx","../src/components/advanced/inventory/inventory-utils.ts","../src/components/shadcn-ui/toggle.tsx","../src/components/shadcn-ui/toggle-group.tsx","../src/components/advanced/inventory/inventory-columns.tsx","../src/components/advanced/inventory/inventory.component.tsx","../src/components/basics/search-bar.component.tsx","../src/components/basics/tabs-vertical.tsx","../src/components/advanced/tab-navigation-content-search.component.tsx","../src/components/shadcn-ui/separator.tsx","../src/components/shadcn-ui/skeleton.tsx","../src/components/shadcn-ui/tooltip.tsx","../src/components/shadcn-ui/sidebar.tsx","../src/components/advanced/settings-components/settings-sidebar.component.tsx","../src/components/advanced/settings-components/settings-sidebar-content-search.component.tsx","../src/components/advanced/scripture-results-viewer/scripture-results-viewer.component.tsx","../src/components/advanced/scroll-group-selector.component.tsx","../src/components/advanced/settings-components/settings-list.component.tsx","../src/components/basics/checklist.component.tsx","../../../node_modules/@babel/runtime/helpers/interopRequireDefault.js","../../../node_modules/@mui/utils/chainPropTypes/chainPropTypes.js","../../../node_modules/@babel/runtime/helpers/esm/extends.js","../../../node_modules/@mui/utils/deepmerge/deepmerge.js","../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.production.min.js","../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.development.js","../../../node_modules/prop-types/node_modules/react-is/index.js","../../../node_modules/object-assign/index.js","../../../node_modules/prop-types/lib/ReactPropTypesSecret.js","../../../node_modules/prop-types/lib/has.js","../../../node_modules/prop-types/checkPropTypes.js","../../../node_modules/prop-types/factoryWithTypeCheckers.js","../../../node_modules/prop-types/factoryWithThrowingShims.js","../../../node_modules/prop-types/index.js","../../../node_modules/@mui/utils/elementAcceptingRef/elementAcceptingRef.js","../../../node_modules/@mui/utils/exactProp/exactProp.js","../../../node_modules/@mui/utils/formatMuiErrorMessage/formatMuiErrorMessage.js","../../../node_modules/react-is/cjs/react-is.production.min.js","../../../node_modules/react-is/cjs/react-is.development.js","../../../node_modules/react-is/index.js","../../../node_modules/@mui/utils/getDisplayName/getDisplayName.js","../../../node_modules/@mui/utils/HTMLElementType/HTMLElementType.js","../../../node_modules/@mui/utils/refType/refType.js","../../../node_modules/@mui/utils/capitalize/capitalize.js","../../../node_modules/@mui/utils/createChainedFunction/createChainedFunction.js","../../../node_modules/@mui/utils/debounce/debounce.js","../../../node_modules/@mui/utils/deprecatedPropType/deprecatedPropType.js","../../../node_modules/@mui/utils/isMuiElement/isMuiElement.js","../../../node_modules/@mui/utils/ownerDocument/ownerDocument.js","../../../node_modules/@mui/utils/ownerWindow/ownerWindow.js","../../../node_modules/@mui/utils/requirePropFactory/requirePropFactory.js","../../../node_modules/@mui/utils/setRef/setRef.js","../../../node_modules/@mui/utils/useEnhancedEffect/useEnhancedEffect.js","../../../node_modules/@mui/utils/useId/useId.js","../../../node_modules/@mui/utils/unsupportedProp/unsupportedProp.js","../../../node_modules/@mui/utils/useControlled/useControlled.js","../../../node_modules/@mui/utils/useEventCallback/useEventCallback.js","../../../node_modules/@mui/utils/useForkRef/useForkRef.js","../../../node_modules/@mui/utils/useLazyRef/useLazyRef.js","../../../node_modules/@mui/utils/useOnMount/useOnMount.js","../../../node_modules/@mui/utils/useTimeout/useTimeout.js","../../../node_modules/@mui/utils/useIsFocusVisible/useIsFocusVisible.js","../../../node_modules/@mui/utils/resolveProps/resolveProps.js","../../../node_modules/@mui/utils/composeClasses/composeClasses.js","../../../node_modules/@mui/utils/ClassNameGenerator/ClassNameGenerator.js","../../../node_modules/@mui/utils/generateUtilityClass/generateUtilityClass.js","../../../node_modules/@mui/utils/generateUtilityClasses/generateUtilityClasses.js","../../../node_modules/@mui/utils/clamp/clamp.js","../../../node_modules/@babel/runtime/helpers/esm/objectWithoutPropertiesLoose.js","../../../node_modules/@mui/system/esm/createTheme/createBreakpoints.js","../../../node_modules/@mui/system/esm/createTheme/shape.js","../../../node_modules/@mui/system/esm/responsivePropType.js","../../../node_modules/@mui/system/esm/merge.js","../../../node_modules/@mui/system/esm/breakpoints.js","../../../node_modules/@mui/system/esm/style.js","../../../node_modules/@mui/system/esm/memoize.js","../../../node_modules/@mui/system/esm/spacing.js","../../../node_modules/@mui/system/esm/createTheme/createSpacing.js","../../../node_modules/@mui/system/esm/compose.js","../../../node_modules/@mui/system/esm/borders.js","../../../node_modules/@mui/system/esm/cssGrid.js","../../../node_modules/@mui/system/esm/palette.js","../../../node_modules/@mui/system/esm/sizing.js","../../../node_modules/@mui/system/esm/styleFunctionSx/defaultSxConfig.js","../../../node_modules/@mui/system/esm/styleFunctionSx/styleFunctionSx.js","../../../node_modules/@mui/system/esm/createTheme/applyStyles.js","../../../node_modules/@mui/system/esm/createTheme/createTheme.js","../../../node_modules/@mui/system/esm/useThemeWithoutDefault.js","../../../node_modules/@mui/system/esm/useTheme.js","../../../node_modules/@mui/system/esm/createStyled.js","../../../node_modules/@mui/system/esm/useThemeProps/getThemeProps.js","../../../node_modules/@mui/system/esm/useThemeProps/useThemeProps.js","../../../node_modules/@mui/system/esm/colorManipulator.js","../../../node_modules/@mui/material/styles/createMixins.js","../../../node_modules/@mui/material/colors/common.js","../../../node_modules/@mui/material/colors/grey.js","../../../node_modules/@mui/material/colors/purple.js","../../../node_modules/@mui/material/colors/red.js","../../../node_modules/@mui/material/colors/orange.js","../../../node_modules/@mui/material/colors/blue.js","../../../node_modules/@mui/material/colors/lightBlue.js","../../../node_modules/@mui/material/colors/green.js","../../../node_modules/@mui/material/styles/createPalette.js","../../../node_modules/@mui/material/styles/createTypography.js","../../../node_modules/@mui/material/styles/shadows.js","../../../node_modules/@mui/material/styles/createTransitions.js","../../../node_modules/@mui/material/styles/zIndex.js","../../../node_modules/@mui/material/styles/createTheme.js","../../../node_modules/@mui/material/styles/defaultTheme.js","../../../node_modules/@mui/material/styles/identifier.js","../../../node_modules/@mui/material/styles/useThemeProps.js","../../../node_modules/@mui/material/styles/styled.js","../../../node_modules/@mui/material/SvgIcon/svgIconClasses.js","../../../node_modules/@mui/material/SvgIcon/SvgIcon.js","../../../node_modules/@mui/material/utils/createSvgIcon.js","../../../node_modules/@mui/material/utils/index.js","../../../node_modules/@mui/icons-material/utils/createSvgIcon.js","../../../node_modules/@mui/icons-material/ArrowRight.js","../../../node_modules/@mui/base/utils/isHostComponent.js","../../../node_modules/@mui/base/utils/appendOwnerState.js","../../../node_modules/@mui/base/utils/ClassNameConfigurator.js","../../../node_modules/@mui/base/utils/extractEventHandlers.js","../../../node_modules/@mui/base/utils/resolveComponentProps.js","../../../node_modules/@mui/base/utils/omitEventHandlers.js","../../../node_modules/@mui/base/utils/mergeSlotProps.js","../../../node_modules/@mui/base/utils/useSlotProps.js","../../../node_modules/@mui/base/generateUtilityClass/index.js","../../../node_modules/@mui/base/generateUtilityClasses/index.js","../../../node_modules/@mui/base/Portal/Portal.js","../../../node_modules/@popperjs/core/lib/enums.js","../../../node_modules/@popperjs/core/lib/dom-utils/getNodeName.js","../../../node_modules/@popperjs/core/lib/dom-utils/getWindow.js","../../../node_modules/@popperjs/core/lib/dom-utils/instanceOf.js","../../../node_modules/@popperjs/core/lib/modifiers/applyStyles.js","../../../node_modules/@popperjs/core/lib/utils/getBasePlacement.js","../../../node_modules/@popperjs/core/lib/utils/math.js","../../../node_modules/@popperjs/core/lib/utils/userAgent.js","../../../node_modules/@popperjs/core/lib/dom-utils/isLayoutViewport.js","../../../node_modules/@popperjs/core/lib/dom-utils/getBoundingClientRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/getLayoutRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/contains.js","../../../node_modules/@popperjs/core/lib/dom-utils/getComputedStyle.js","../../../node_modules/@popperjs/core/lib/dom-utils/isTableElement.js","../../../node_modules/@popperjs/core/lib/dom-utils/getDocumentElement.js","../../../node_modules/@popperjs/core/lib/dom-utils/getParentNode.js","../../../node_modules/@popperjs/core/lib/dom-utils/getOffsetParent.js","../../../node_modules/@popperjs/core/lib/utils/getMainAxisFromPlacement.js","../../../node_modules/@popperjs/core/lib/utils/within.js","../../../node_modules/@popperjs/core/lib/utils/getFreshSideObject.js","../../../node_modules/@popperjs/core/lib/utils/mergePaddingObject.js","../../../node_modules/@popperjs/core/lib/utils/expandToHashMap.js","../../../node_modules/@popperjs/core/lib/modifiers/arrow.js","../../../node_modules/@popperjs/core/lib/utils/getVariation.js","../../../node_modules/@popperjs/core/lib/modifiers/computeStyles.js","../../../node_modules/@popperjs/core/lib/modifiers/eventListeners.js","../../../node_modules/@popperjs/core/lib/utils/getOppositePlacement.js","../../../node_modules/@popperjs/core/lib/utils/getOppositeVariationPlacement.js","../../../node_modules/@popperjs/core/lib/dom-utils/getWindowScroll.js","../../../node_modules/@popperjs/core/lib/dom-utils/getWindowScrollBarX.js","../../../node_modules/@popperjs/core/lib/dom-utils/getViewportRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/getDocumentRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/isScrollParent.js","../../../node_modules/@popperjs/core/lib/dom-utils/getScrollParent.js","../../../node_modules/@popperjs/core/lib/dom-utils/listScrollParents.js","../../../node_modules/@popperjs/core/lib/utils/rectToClientRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/getClippingRect.js","../../../node_modules/@popperjs/core/lib/utils/computeOffsets.js","../../../node_modules/@popperjs/core/lib/utils/detectOverflow.js","../../../node_modules/@popperjs/core/lib/utils/computeAutoPlacement.js","../../../node_modules/@popperjs/core/lib/modifiers/flip.js","../../../node_modules/@popperjs/core/lib/modifiers/hide.js","../../../node_modules/@popperjs/core/lib/modifiers/offset.js","../../../node_modules/@popperjs/core/lib/modifiers/popperOffsets.js","../../../node_modules/@popperjs/core/lib/utils/getAltAxis.js","../../../node_modules/@popperjs/core/lib/modifiers/preventOverflow.js","../../../node_modules/@popperjs/core/lib/dom-utils/getHTMLElementScroll.js","../../../node_modules/@popperjs/core/lib/dom-utils/getNodeScroll.js","../../../node_modules/@popperjs/core/lib/dom-utils/getCompositeRect.js","../../../node_modules/@popperjs/core/lib/utils/orderModifiers.js","../../../node_modules/@popperjs/core/lib/utils/debounce.js","../../../node_modules/@popperjs/core/lib/utils/mergeByName.js","../../../node_modules/@popperjs/core/lib/createPopper.js","../../../node_modules/@popperjs/core/lib/popper.js","../../../node_modules/@mui/base/Popper/popperClasses.js","../../../node_modules/@mui/base/Popper/Popper.js","../../../node_modules/@mui/material/styles/useTheme.js","../../../node_modules/@babel/runtime/helpers/esm/setPrototypeOf.js","../../../node_modules/@babel/runtime/helpers/esm/inheritsLoose.js","../../../node_modules/react-transition-group/esm/config.js","../../../node_modules/react-transition-group/esm/utils/PropTypes.js","../../../node_modules/react-transition-group/esm/TransitionGroupContext.js","../../../node_modules/react-transition-group/esm/utils/reflow.js","../../../node_modules/react-transition-group/esm/Transition.js","../../../node_modules/@mui/material/transitions/utils.js","../../../node_modules/@mui/material/Grow/Grow.js","../../../node_modules/@mui/material/Popper/Popper.js","../../../node_modules/@mui/material/Tooltip/tooltipClasses.js","../../../node_modules/@mui/material/Tooltip/Tooltip.js","../src/components/mui/menu-item.component.tsx","../src/components/mui/grouped-menu-item-list.component.tsx","../src/components/mui/top-level-menu.component.tsx","../src/components/mui/grid-menu.component.tsx","../src/hooks/use-promise.hook.ts","../../../node_modules/@mui/icons-material/esm/Menu.js","../src/components/mui/hamburger-menu-button.component.tsx","../src/components/mui/icon-button.component.tsx","../src/components/basics/spinner.component.tsx","../src/components/basics/text-field.component.tsx","../src/components/mui/toolbar.component.tsx","../src/components/shadcn-ui/alert.tsx","../src/components/shadcn-ui/card.tsx","../src/components/shadcn-ui/sonner.tsx","../src/components/shadcn-ui/slider.tsx","../src/components/shadcn-ui/switch.tsx","../src/components/shadcn-ui/tabs.tsx","../src/components/advanced/extension-marketplace/buttons/install-button.component.tsx","../src/components/advanced/extension-marketplace/buttons/enable-button.component.tsx","../src/components/advanced/extension-marketplace/buttons/disable-button.component.tsx","../src/components/advanced/extension-marketplace/buttons/update-button.component.tsx","../src/components/advanced/extension-marketplace/markdown-renderer.component.tsx","../src/components/advanced/extension-marketplace/buttons/filter-button.component.tsx","../src/components/advanced/extension-marketplace/filter-dropdown.component.tsx","../src/components/advanced/extension-marketplace/no-extensions-found.component.tsx","../src/components/advanced/extension-marketplace/more-info.component.tsx","../src/components/advanced/extension-marketplace/version-history.component.tsx","../src/components/advanced/extension-marketplace/footer.component.tsx","../src/hooks/use-event.hook.ts","../src/hooks/use-event-async.hook.ts"],"sourcesContent":["import { type ClassValue, clsx } from 'clsx';\nimport { extendTailwindMerge } from 'tailwind-merge';\n\nconst twMergeCustom = extendTailwindMerge({ prefix: 'tw-' });\n\n/**\n * Tailwind and CSS class application helper function. Uses\n * [`clsx`](https://www.npmjs.com/package/clsx) to make it easy to apply classes conditionally using\n * object syntax, and uses [`tailwind-merge`](https://www.npmjs.com/package/tailwind-merge) to make\n * it easy to merge/overwrite Tailwind classes in a programmer-logic-friendly way.\n *\n * Note: `tailwind-merge` is configured to use the prefix `tw-`, so you must use the same prefix\n * with any Tailwind classes you use with this function to successfully overwrite other Tailwind\n * classes. `platform-bible-react` is configured to use `tw-` as its Tailwind prefix, so any\n * Tailwind classes you pass into `platform-bible-react` components will be compared using the `tw-`\n * prefix.\n *\n * This function was popularized by\n * [shadcn/ui](https://ui.shadcn.com/docs/installation/manual#add-a-cn-helper). See [ByteGrad's\n * explanation video](https://www.youtube.com/watch?v=re2JFITR7TI) for more information.\n *\n * @example\n *\n * ```typescript\n * const borderShouldBeBlue = true;\n * const textShouldBeRed = true;\n * const heightShouldBe20 = false;\n * const classString = cn(\n * 'tw-bg-primary tw-h-10 tw-text-primary-foreground',\n * 'tw-bg-secondary',\n * {\n * 'tw-border-blue-500': borderShouldBeBlue,\n * 'tw-text-red-500': textShouldBeRed,\n * 'tw-h-20': heightShouldBe20,\n * },\n * 'some-class',\n * );\n * ```\n *\n * The resulting `classString` is `'tw-h-10 tw-bg-secondary tw-border-blue-500 tw-text-red-500\n * some-class'`\n *\n * - Notice that `'tw-bg-secondary'`, specified later, overwrote `'tw-bg-primary'`, specified earlier,\n * because they are Tailwind classes that affect the same css property\n * - Notice that `'tw-text-red-500'`, specified later, overwrote `'tw-text-primary-foreground'`,\n * specified earlier, because they are Tailwind classes that affect the same css property\n * - Notice that `'tw-h-20'`, specified later, did not overwrite `'tw-h-10'`, specified earlier,\n * because `'tw-h-20'` is part of a conditional class object and its value evaluated to `false`;\n * therefore it was not applied\n * - Notice that `'some-class'` was applied. This function is not limited only to Tailwind classes.\n *\n *\n * @param inputs Class strings or `clsx` conditional class objects to merge. Tailwind classes\n * specified later in the arguments overwrite similar Tailwind classes specified earlier in the\n * arguments\n * @returns Class string containing all applicable classes from the arguments based on the rules\n * described above\n */\n// shadcn/ui uses this export in its boilerplate code\n// eslint-disable-next-line import/prefer-default-export\nexport function cn(...inputs: ClassValue[]) {\n return twMergeCustom(clsx(inputs));\n}\n","import React from 'react';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport interface InputProps extends React.InputHTMLAttributes {}\n\nexport const Input = React.forwardRef(\n ({ className, type, ...props }, ref) => {\n return (\n \n );\n },\n);\nInput.displayName = 'Input';\n","import { FocusEventHandler, forwardRef, KeyboardEvent, MouseEventHandler } from 'react';\nimport { History } from 'lucide-react';\nimport { Input as ShadInput } from '@/components/shadcn-ui/input';\n\nexport type BookChapterInputProps = {\n handleSearch: (searchString: string) => void;\n handleKeyDown: (event: KeyboardEvent) => void;\n handleOnClick: MouseEventHandler;\n handleSubmit: () => void;\n onFocus?: FocusEventHandler;\n value: string;\n placeholder: string;\n};\n\n// Shadcn Input sets type to \"button\"- HAVE to prop spread before setting type\nconst BookChapterInput = forwardRef(\n (\n { handleSearch, handleKeyDown, handleOnClick, handleSubmit, ...props }: BookChapterInputProps,\n ref,\n ) => {\n return (\n
    \n handleSearch(event.target.value)}\n onKeyDown={(e) => {\n if (e.key === 'Enter') {\n handleSubmit();\n }\n handleKeyDown(e);\n }}\n onClick={handleOnClick}\n ref={ref}\n />\n {\n // eslint-disable-next-line no-console\n console.log('back in history');\n }}\n />\n
    \n );\n },\n);\n\nexport default BookChapterInput;\n","var P = Object.defineProperty;\nvar R = (t, e, s) => e in t ? P(t, e, { enumerable: !0, configurable: !0, writable: !0, value: s }) : t[e] = s;\nvar n = (t, e, s) => R(t, typeof e != \"symbol\" ? e + \"\" : e, s);\nclass _ {\n constructor() {\n n(this, \"books\");\n n(this, \"firstSelectedBookNum\");\n n(this, \"lastSelectedBookNum\");\n n(this, \"count\");\n n(this, \"selectedBookNumbers\");\n n(this, \"selectedBookIds\");\n }\n}\nconst N = [\n \"GEN\",\n \"EXO\",\n \"LEV\",\n \"NUM\",\n \"DEU\",\n \"JOS\",\n \"JDG\",\n \"RUT\",\n \"1SA\",\n \"2SA\",\n // 10\n \"1KI\",\n \"2KI\",\n \"1CH\",\n \"2CH\",\n \"EZR\",\n \"NEH\",\n \"EST\",\n \"JOB\",\n \"PSA\",\n \"PRO\",\n // 20\n \"ECC\",\n \"SNG\",\n \"ISA\",\n \"JER\",\n \"LAM\",\n \"EZK\",\n \"DAN\",\n \"HOS\",\n \"JOL\",\n \"AMO\",\n // 30\n \"OBA\",\n \"JON\",\n \"MIC\",\n \"NAM\",\n \"HAB\",\n \"ZEP\",\n \"HAG\",\n \"ZEC\",\n \"MAL\",\n \"MAT\",\n // 40\n \"MRK\",\n \"LUK\",\n \"JHN\",\n \"ACT\",\n \"ROM\",\n \"1CO\",\n \"2CO\",\n \"GAL\",\n \"EPH\",\n \"PHP\",\n // 50\n \"COL\",\n \"1TH\",\n \"2TH\",\n \"1TI\",\n \"2TI\",\n \"TIT\",\n \"PHM\",\n \"HEB\",\n \"JAS\",\n \"1PE\",\n // 60\n \"2PE\",\n \"1JN\",\n \"2JN\",\n \"3JN\",\n \"JUD\",\n \"REV\",\n \"TOB\",\n \"JDT\",\n \"ESG\",\n \"WIS\",\n // 70\n \"SIR\",\n \"BAR\",\n \"LJE\",\n \"S3Y\",\n \"SUS\",\n \"BEL\",\n \"1MA\",\n \"2MA\",\n \"3MA\",\n \"4MA\",\n // 80\n \"1ES\",\n \"2ES\",\n \"MAN\",\n \"PS2\",\n \"ODA\",\n \"PSS\",\n \"JSA\",\n // actual variant text for JOS, now in LXA text\n \"JDB\",\n // actual variant text for JDG, now in LXA text\n \"TBS\",\n // actual variant text for TOB, now in LXA text\n \"SST\",\n // actual variant text for SUS, now in LXA text // 90\n \"DNT\",\n // actual variant text for DAN, now in LXA text\n \"BLT\",\n // actual variant text for BEL, now in LXA text\n \"XXA\",\n \"XXB\",\n \"XXC\",\n \"XXD\",\n \"XXE\",\n \"XXF\",\n \"XXG\",\n \"FRT\",\n // 100\n \"BAK\",\n \"OTH\",\n \"3ES\",\n // Used previously but really should be 2ES\n \"EZA\",\n // Used to be called 4ES, but not actually in any known project\n \"5EZ\",\n // Used to be called 5ES, but not actually in any known project\n \"6EZ\",\n // Used to be called 6ES, but not actually in any known project\n \"INT\",\n \"CNC\",\n \"GLO\",\n \"TDX\",\n // 110\n \"NDX\",\n \"DAG\",\n \"PS3\",\n \"2BA\",\n \"LBA\",\n \"JUB\",\n \"ENO\",\n \"1MQ\",\n \"2MQ\",\n \"3MQ\",\n // 120\n \"REP\",\n \"4BA\",\n \"LAO\"\n], B = [\n \"XXA\",\n \"XXB\",\n \"XXC\",\n \"XXD\",\n \"XXE\",\n \"XXF\",\n \"XXG\",\n \"FRT\",\n \"BAK\",\n \"OTH\",\n \"INT\",\n \"CNC\",\n \"GLO\",\n \"TDX\",\n \"NDX\"\n], O = [\n \"Genesis\",\n \"Exodus\",\n \"Leviticus\",\n \"Numbers\",\n \"Deuteronomy\",\n \"Joshua\",\n \"Judges\",\n \"Ruth\",\n \"1 Samuel\",\n \"2 Samuel\",\n \"1 Kings\",\n \"2 Kings\",\n \"1 Chronicles\",\n \"2 Chronicles\",\n \"Ezra\",\n \"Nehemiah\",\n \"Esther (Hebrew)\",\n \"Job\",\n \"Psalms\",\n \"Proverbs\",\n \"Ecclesiastes\",\n \"Song of Songs\",\n \"Isaiah\",\n \"Jeremiah\",\n \"Lamentations\",\n \"Ezekiel\",\n \"Daniel (Hebrew)\",\n \"Hosea\",\n \"Joel\",\n \"Amos\",\n \"Obadiah\",\n \"Jonah\",\n \"Micah\",\n \"Nahum\",\n \"Habakkuk\",\n \"Zephaniah\",\n \"Haggai\",\n \"Zechariah\",\n \"Malachi\",\n \"Matthew\",\n \"Mark\",\n \"Luke\",\n \"John\",\n \"Acts\",\n \"Romans\",\n \"1 Corinthians\",\n \"2 Corinthians\",\n \"Galatians\",\n \"Ephesians\",\n \"Philippians\",\n \"Colossians\",\n \"1 Thessalonians\",\n \"2 Thessalonians\",\n \"1 Timothy\",\n \"2 Timothy\",\n \"Titus\",\n \"Philemon\",\n \"Hebrews\",\n \"James\",\n \"1 Peter\",\n \"2 Peter\",\n \"1 John\",\n \"2 John\",\n \"3 John\",\n \"Jude\",\n \"Revelation\",\n \"Tobit\",\n \"Judith\",\n \"Esther Greek\",\n \"Wisdom of Solomon\",\n \"Sirach (Ecclesiasticus)\",\n \"Baruch\",\n \"Letter of Jeremiah\",\n \"Song of 3 Young Men\",\n \"Susanna\",\n \"Bel and the Dragon\",\n \"1 Maccabees\",\n \"2 Maccabees\",\n \"3 Maccabees\",\n \"4 Maccabees\",\n \"1 Esdras (Greek)\",\n \"2 Esdras (Latin)\",\n \"Prayer of Manasseh\",\n \"Psalm 151\",\n \"Odes\",\n \"Psalms of Solomon\",\n // WARNING, if you change the spelling of the *obsolete* tag be sure to update\n // IsObsolete routine\n \"Joshua A. *obsolete*\",\n \"Judges B. *obsolete*\",\n \"Tobit S. *obsolete*\",\n \"Susanna Th. *obsolete*\",\n \"Daniel Th. *obsolete*\",\n \"Bel Th. *obsolete*\",\n \"Extra A\",\n \"Extra B\",\n \"Extra C\",\n \"Extra D\",\n \"Extra E\",\n \"Extra F\",\n \"Extra G\",\n \"Front Matter\",\n \"Back Matter\",\n \"Other Matter\",\n \"3 Ezra *obsolete*\",\n \"Apocalypse of Ezra\",\n \"5 Ezra (Latin Prologue)\",\n \"6 Ezra (Latin Epilogue)\",\n \"Introduction\",\n \"Concordance \",\n \"Glossary \",\n \"Topical Index\",\n \"Names Index\",\n \"Daniel Greek\",\n \"Psalms 152-155\",\n \"2 Baruch (Apocalypse)\",\n \"Letter of Baruch\",\n \"Jubilees\",\n \"Enoch\",\n \"1 Meqabyan\",\n \"2 Meqabyan\",\n \"3 Meqabyan\",\n \"Reproof (Proverbs 25-31)\",\n \"4 Baruch (Rest of Baruch)\",\n \"Laodiceans\"\n], S = K();\nfunction g(t, e = !0) {\n return e && (t = t.toUpperCase()), t in S ? S[t] : 0;\n}\nfunction k(t) {\n return g(t) > 0;\n}\nfunction x(t) {\n const e = typeof t == \"string\" ? g(t) : t;\n return e >= 40 && e <= 66;\n}\nfunction T(t) {\n return (typeof t == \"string\" ? g(t) : t) <= 39;\n}\nfunction X(t) {\n return t <= 66;\n}\nfunction V(t) {\n const e = typeof t == \"string\" ? g(t) : t;\n return w(e) && !X(e);\n}\nfunction* L() {\n for (let t = 1; t <= N.length; t++) yield t;\n}\nconst G = 1, A = N.length;\nfunction H() {\n return [\"XXA\", \"XXB\", \"XXC\", \"XXD\", \"XXE\", \"XXF\", \"XXG\"];\n}\nfunction C(t, e = \"***\") {\n const s = t - 1;\n return s < 0 || s >= N.length ? e : N[s];\n}\nfunction I(t) {\n return t <= 0 || t > A ? \"******\" : O[t - 1];\n}\nfunction y(t) {\n return I(g(t));\n}\nfunction w(t) {\n const e = typeof t == \"number\" ? C(t) : t;\n return k(e) && !B.includes(e);\n}\nfunction q(t) {\n const e = typeof t == \"number\" ? C(t) : t;\n return k(e) && B.includes(e);\n}\nfunction U(t) {\n return O[t - 1].includes(\"*obsolete*\");\n}\nfunction K() {\n const t = {};\n for (let e = 0; e < N.length; e++)\n t[N[e]] = e + 1;\n return t;\n}\nconst m = {\n allBookIds: N,\n nonCanonicalIds: B,\n bookIdToNumber: g,\n isBookIdValid: k,\n isBookNT: x,\n isBookOT: T,\n isBookOTNT: X,\n isBookDC: V,\n allBookNumbers: L,\n firstBook: G,\n lastBook: A,\n extraBooks: H,\n bookNumberToId: C,\n bookNumberToEnglishName: I,\n bookIdToEnglishName: y,\n isCanonical: w,\n isExtraMaterial: q,\n isObsolete: U\n};\nvar l = /* @__PURE__ */ ((t) => (t[t.Unknown = 0] = \"Unknown\", t[t.Original = 1] = \"Original\", t[t.Septuagint = 2] = \"Septuagint\", t[t.Vulgate = 3] = \"Vulgate\", t[t.English = 4] = \"English\", t[t.RussianProtestant = 5] = \"RussianProtestant\", t[t.RussianOrthodox = 6] = \"RussianOrthodox\", t))(l || {});\nconst h = class h {\n // private versInfo: Versification;\n constructor(e) {\n n(this, \"name\");\n n(this, \"fullPath\");\n n(this, \"isPresent\");\n n(this, \"hasVerseSegments\");\n n(this, \"isCustomized\");\n n(this, \"baseVersification\");\n n(this, \"scriptureBooks\");\n n(this, \"_type\");\n if (e == null)\n throw new Error(\"Argument undefined\");\n typeof e == \"string\" ? (this.name = e, this._type = l[e]) : (this._type = e, this.name = l[e]);\n }\n get type() {\n return this._type;\n }\n equals(e) {\n return !e.type || !this.type ? !1 : e.type === this.type;\n }\n};\nn(h, \"Original\", new h(l.Original)), n(h, \"Septuagint\", new h(l.Septuagint)), n(h, \"Vulgate\", new h(l.Vulgate)), n(h, \"English\", new h(l.English)), n(h, \"RussianProtestant\", new h(l.RussianProtestant)), n(h, \"RussianOrthodox\", new h(l.RussianOrthodox));\nlet c = h;\nfunction E(t, e) {\n const s = e[0];\n for (let r = 1; r < e.length; r++)\n t = t.split(e[r]).join(s);\n return t.split(s);\n}\nvar D = /* @__PURE__ */ ((t) => (t[t.Valid = 0] = \"Valid\", t[t.UnknownVersification = 1] = \"UnknownVersification\", t[t.OutOfRange = 2] = \"OutOfRange\", t[t.VerseOutOfOrder = 3] = \"VerseOutOfOrder\", t[t.VerseRepeated = 4] = \"VerseRepeated\", t))(D || {});\nconst i = class i {\n constructor(e, s, r, a) {\n /** Not yet implemented. */\n n(this, \"firstChapter\");\n /** Not yet implemented. */\n n(this, \"lastChapter\");\n /** Not yet implemented. */\n n(this, \"lastVerse\");\n /** Not yet implemented. */\n n(this, \"hasSegmentsDefined\");\n /** Not yet implemented. */\n n(this, \"text\");\n /** Not yet implemented. */\n n(this, \"BBBCCCVVVS\");\n /** Not yet implemented. */\n n(this, \"longHashCode\");\n /** The versification of the reference. */\n n(this, \"versification\");\n n(this, \"rtlMark\", \"‏\");\n n(this, \"_bookNum\", 0);\n n(this, \"_chapterNum\", 0);\n n(this, \"_verseNum\", 0);\n n(this, \"_verse\");\n if (r == null && a == null)\n if (e != null && typeof e == \"string\") {\n const o = e, u = s != null && s instanceof c ? s : void 0;\n this.setEmpty(u), this.parse(o);\n } else if (e != null && typeof e == \"number\") {\n const o = s != null && s instanceof c ? s : void 0;\n this.setEmpty(o), this._verseNum = e % i.chapterDigitShifter, this._chapterNum = Math.floor(\n e % i.bookDigitShifter / i.chapterDigitShifter\n ), this._bookNum = Math.floor(e / i.bookDigitShifter);\n } else if (s == null)\n if (e != null && e instanceof i) {\n const o = e;\n this._bookNum = o.bookNum, this._chapterNum = o.chapterNum, this._verseNum = o.verseNum, this._verse = o.verse, this.versification = o.versification;\n } else {\n if (e == null) return;\n const o = e instanceof c ? e : i.defaultVersification;\n this.setEmpty(o);\n }\n else\n throw new Error(\"VerseRef constructor not supported.\");\n else if (e != null && s != null && r != null)\n if (typeof e == \"string\" && typeof s == \"string\" && typeof r == \"string\")\n this.setEmpty(a), this.updateInternal(e, s, r);\n else if (typeof e == \"number\" && typeof s == \"number\" && typeof r == \"number\")\n this._bookNum = e, this._chapterNum = s, this._verseNum = r, this.versification = a ?? i.defaultVersification;\n else\n throw new Error(\"VerseRef constructor not supported.\");\n else\n throw new Error(\"VerseRef constructor not supported.\");\n }\n /**\n * Determines if the verse string is in a valid format (does not consider versification).\n */\n static isVerseParseable(e) {\n return e.length > 0 && \"0123456789\".includes(e[0]) && !e.endsWith(this.verseRangeSeparator) && !e.endsWith(this.verseSequenceIndicator);\n }\n /**\n * Tries to parse the specified string into a verse reference.\n * @param str - The string to attempt to parse.\n * @returns success: `true` if the specified string was successfully parsed, `false` otherwise.\n * @returns verseRef: The result of the parse if successful, or empty VerseRef if it failed\n */\n static tryParse(e) {\n let s;\n try {\n return s = new i(e), { success: !0, verseRef: s };\n } catch (r) {\n if (r instanceof v)\n return s = new i(), { success: !1, verseRef: s };\n throw r;\n }\n }\n /**\n * Gets the reference as a comparable integer where the book, chapter, and verse each occupy 3\n * digits.\n * @param bookNum - Book number (this is 1-based, not an index).\n * @param chapterNum - Chapter number.\n * @param verseNum - Verse number.\n * @returns The reference as a comparable integer where the book, chapter, and verse each occupy 3\n * digits.\n */\n static getBBBCCCVVV(e, s, r) {\n return e % i.bcvMaxValue * i.bookDigitShifter + (s >= 0 ? s % i.bcvMaxValue * i.chapterDigitShifter : 0) + (r >= 0 ? r % i.bcvMaxValue : 0);\n }\n /**\n * Deserializes a serialized VerseRef.\n * @param serializedVerseRef - Serialized VerseRef to create from.\n * @returns the deserialized VerseRef.\n */\n static fromJSON(e) {\n const { book: s, chapterNum: r, verseNum: a, verse: o, versificationStr: u } = e, f = o || a.toString();\n let d;\n return u && (d = new c(u)), s ? new i(s, r.toString(), f, d) : new i();\n }\n /**\n * Parses a verse string and gets the leading numeric portion as a number.\n * @param verseStr - verse string to parse\n * @returns true if the entire string could be parsed as a single, simple verse number (1-999);\n * false if the verse string represented a verse bridge, contained segment letters, or was invalid\n */\n static tryGetVerseNum(e) {\n let s;\n if (!e)\n return s = -1, { success: !0, vNum: s };\n s = 0;\n let r;\n for (let a = 0; a < e.length; a++) {\n if (r = e[a], r < \"0\" || r > \"9\")\n return a === 0 && (s = -1), { success: !1, vNum: s };\n if (s = s * 10 + +r - 0, s > i.bcvMaxValue)\n return s = -1, { success: !1, vNum: s };\n }\n return { success: !0, vNum: s };\n }\n /**\n * Checks to see if a VerseRef hasn't been set - all values are the default.\n */\n get isDefault() {\n return this.bookNum === 0 && this.chapterNum === 0 && this.verseNum === 0 && this.versification == null;\n }\n /**\n * Gets whether the verse contains multiple verses.\n */\n get hasMultiple() {\n return this._verse != null && (this._verse.includes(i.verseRangeSeparator) || this._verse.includes(i.verseSequenceIndicator));\n }\n /**\n * Gets or sets the book of the reference. Book is the 3-letter abbreviation in capital letters,\n * e.g. `'MAT'`.\n */\n get book() {\n return m.bookNumberToId(this.bookNum, \"\");\n }\n set book(e) {\n this.bookNum = m.bookIdToNumber(e);\n }\n /**\n * Gets or sets the chapter of the reference,. e.g. `'3'`.\n */\n get chapter() {\n return this.isDefault || this._chapterNum < 0 ? \"\" : this._chapterNum.toString();\n }\n set chapter(e) {\n const s = +e;\n this._chapterNum = Number.isInteger(s) ? s : -1;\n }\n /**\n * Gets or sets the verse of the reference, including range, segments, and sequences, e.g. `'4'`,\n * or `'4b-5a, 7'`.\n */\n get verse() {\n return this._verse != null ? this._verse : this.isDefault || this._verseNum < 0 ? \"\" : this._verseNum.toString();\n }\n set verse(e) {\n const { success: s, vNum: r } = i.tryGetVerseNum(e);\n this._verse = s ? void 0 : e.replace(this.rtlMark, \"\"), this._verseNum = r, !(this._verseNum >= 0) && ({ vNum: this._verseNum } = i.tryGetVerseNum(this._verse));\n }\n /**\n * Get or set Book based on book number, e.g. `42`.\n */\n get bookNum() {\n return this._bookNum;\n }\n set bookNum(e) {\n if (e <= 0 || e > m.lastBook)\n throw new v(\n \"BookNum must be greater than zero and less than or equal to last book\"\n );\n this._bookNum = e;\n }\n /**\n * Gets or sets the chapter number, e.g. `3`. `-1` if not valid.\n */\n get chapterNum() {\n return this._chapterNum;\n }\n set chapterNum(e) {\n this.chapterNum = e;\n }\n /**\n * Gets or sets verse start number, e.g. `4`. `-1` if not valid.\n */\n get verseNum() {\n return this._verseNum;\n }\n set verseNum(e) {\n this._verseNum = e;\n }\n /**\n * String representing the versification (should ONLY be used for serialization/deserialization).\n *\n * @remarks This is for backwards compatibility when ScrVers was an enumeration.\n */\n get versificationStr() {\n var e;\n return (e = this.versification) == null ? void 0 : e.name;\n }\n set versificationStr(e) {\n this.versification = this.versification != null ? new c(e) : void 0;\n }\n /**\n * Determines if the reference is valid.\n */\n get valid() {\n return this.validStatus === 0;\n }\n /**\n * Get the valid status for this reference.\n */\n get validStatus() {\n return this.validateVerse(i.verseRangeSeparators, i.verseSequenceIndicators);\n }\n /**\n * Gets the reference as a comparable integer where the book,\n * chapter, and verse each occupy three digits and the verse is 0.\n */\n get BBBCCC() {\n return i.getBBBCCCVVV(this._bookNum, this._chapterNum, 0);\n }\n /**\n * Gets the reference as a comparable integer where the book,\n * chapter, and verse each occupy three digits. If verse is not null\n * (i.e., this reference represents a complex reference with verse\n * segments or bridge) this cannot be used for an exact comparison.\n */\n get BBBCCCVVV() {\n return i.getBBBCCCVVV(this._bookNum, this._chapterNum, this._verseNum);\n }\n /**\n * Gets whether the verse is defined as an excluded verse in the versification.\n * Does not handle verse ranges.\n */\n // eslint-disable-next-line @typescript-eslint/class-literal-property-style\n get isExcluded() {\n return !1;\n }\n /**\n * Parses the reference in the specified string.\n * Optionally versification can follow reference as in GEN 3:11/4\n * Throw an exception if\n * - invalid book name\n * - chapter number is missing or not a number\n * - verse number is missing or does not start with a number\n * - versification is invalid\n * @param verseStr - string to parse e.g. 'MAT 3:11'\n */\n parse(e) {\n if (e = e.replace(this.rtlMark, \"\"), e.includes(\"/\")) {\n const o = e.split(\"/\");\n if (e = o[0], o.length > 1)\n try {\n const u = +o[1].trim();\n this.versification = new c(l[u]);\n } catch {\n throw new v(\"Invalid reference : \" + e);\n }\n }\n const s = e.trim().split(\" \");\n if (s.length !== 2)\n throw new v(\"Invalid reference : \" + e);\n const r = s[1].split(\":\"), a = +r[0];\n if (r.length !== 2 || m.bookIdToNumber(s[0]) === 0 || !Number.isInteger(a) || a < 0 || !i.isVerseParseable(r[1]))\n throw new v(\"Invalid reference : \" + e);\n this.updateInternal(s[0], r[0], r[1]);\n }\n /**\n * Simplifies this verse ref so that it has no bridging of verses or\n * verse segments like `'1a'`.\n */\n simplify() {\n this._verse = void 0;\n }\n /**\n * Makes a clone of the reference.\n *\n * @returns The cloned VerseRef.\n */\n clone() {\n return new i(this);\n }\n toString() {\n const e = this.book;\n return e === \"\" ? \"\" : `${e} ${this.chapter}:${this.verse}`;\n }\n toJSON() {\n let e = this.verse;\n (e === \"\" || e === this.verseNum.toString()) && (e = void 0);\n const s = {\n book: this.book,\n chapterNum: this.chapterNum,\n verseNum: this.verseNum,\n verse: e,\n versificationStr: this.versificationStr\n };\n return e || delete s.verse, s;\n }\n /**\n * Compares this `VerseRef` with supplied one.\n * @param verseRef - object to compare this one to.\n * @returns `true` if this `VerseRef` is equal to the supplied one, `false` otherwise.\n */\n equals(e) {\n return e instanceof i ? e._bookNum === this._bookNum && e._chapterNum === this._chapterNum && e._verseNum === this._verseNum && e.verse === this.verse && (e.versification == null && this.versification == null || e.versification != null && this.versification != null && e.versification.equals(this.versification)) : !1;\n }\n /**\n * Enumerate all individual verses contained in a VerseRef.\n * Verse ranges are indicated by \"-\" and consecutive verses by \",\"s.\n * Examples:\n * GEN 1:2 returns GEN 1:2\n * GEN 1:1a-3b,5 returns GEN 1:1a, GEN 1:2, GEN 1:3b, GEN 1:5\n * GEN 1:2a-2c returns //! ??????\n *\n * @param specifiedVersesOnly - if set to true return only verses that are\n * explicitly specified only, not verses within a range. Defaults to `false`.\n * @param verseRangeSeparators - Verse range separators.\n * Defaults to `VerseRef.verseRangeSeparators`.\n * @param verseSequenceSeparators - Verse sequence separators.\n * Defaults to `VerseRef.verseSequenceIndicators`.\n * @returns An array of all single verse references in this VerseRef.\n */\n allVerses(e = !1, s = i.verseRangeSeparators, r = i.verseSequenceIndicators) {\n if (this._verse == null || this.chapterNum <= 0)\n return [this.clone()];\n const a = [], o = E(this._verse, r);\n for (const u of o.map((f) => E(f, s))) {\n const f = this.clone();\n f.verse = u[0];\n const d = f.verseNum;\n if (a.push(f), u.length > 1) {\n const b = this.clone();\n if (b.verse = u[1], !e)\n for (let p = d + 1; p < b.verseNum; p++) {\n const J = new i(\n this._bookNum,\n this._chapterNum,\n p,\n this.versification\n );\n this.isExcluded || a.push(J);\n }\n a.push(b);\n }\n }\n return a;\n }\n /**\n * Validates a verse number using the supplied separators rather than the defaults.\n */\n validateVerse(e, s) {\n if (!this.verse)\n return this.internalValid;\n let r = 0;\n for (const a of this.allVerses(!0, e, s)) {\n const o = a.internalValid;\n if (o !== 0)\n return o;\n const u = a.BBBCCCVVV;\n if (r > u)\n return 3;\n if (r === u)\n return 4;\n r = u;\n }\n return 0;\n }\n /**\n * Gets whether a single verse reference is valid.\n */\n get internalValid() {\n return this.versification == null ? 1 : this._bookNum <= 0 || this._bookNum > m.lastBook ? 2 : (m.isCanonical(this._bookNum), 0);\n }\n setEmpty(e = i.defaultVersification) {\n this._bookNum = 0, this._chapterNum = -1, this._verse = void 0, this.versification = e;\n }\n updateInternal(e, s, r) {\n this.bookNum = m.bookIdToNumber(e), this.chapter = s, this.verse = r;\n }\n};\nn(i, \"defaultVersification\", c.English), n(i, \"verseRangeSeparator\", \"-\"), n(i, \"verseSequenceIndicator\", \",\"), n(i, \"verseRangeSeparators\", [i.verseRangeSeparator]), n(i, \"verseSequenceIndicators\", [i.verseSequenceIndicator]), n(i, \"chapterDigitShifter\", 1e3), n(i, \"bookDigitShifter\", i.chapterDigitShifter * i.chapterDigitShifter), n(i, \"bcvMaxValue\", i.chapterDigitShifter - 1), /**\n * The valid status of the VerseRef.\n */\nn(i, \"ValidStatusType\", D);\nlet M = i;\nclass v extends Error {\n}\nexport {\n _ as BookSet,\n m as Canon,\n c as ScrVers,\n l as ScrVersType,\n M as VerseRef,\n v as VerseRefException\n};\n//# sourceMappingURL=index.es.js.map\n","import React from 'react';\nimport * as DropdownMenuPrimitive from '@radix-ui/react-dropdown-menu';\nimport { Check, ChevronRight, Circle } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport const DropdownMenu = DropdownMenuPrimitive.Root;\n\nexport const DropdownMenuTrigger = DropdownMenuPrimitive.Trigger;\n\nexport const DropdownMenuGroup = DropdownMenuPrimitive.Group;\n\nexport const DropdownMenuPortal = DropdownMenuPrimitive.Portal;\n\nexport const DropdownMenuSub = DropdownMenuPrimitive.Sub;\n\nexport const DropdownMenuRadioGroup = DropdownMenuPrimitive.RadioGroup;\n\nexport type DropdownMenuSubTriggerProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.SubTrigger\n> & {\n className?: string;\n inset?: boolean;\n};\n\nexport type DropdownMenuSubContentProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.SubContent\n> & {\n className?: string;\n};\n\nexport type DropdownMenuContentProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Content\n> & {\n className?: string;\n sideOffset?: number;\n};\n\nexport type DropdownMenuItemProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Item\n> & {\n className?: string;\n inset?: boolean;\n};\n\nexport type DropdownMenuCheckboxItemProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.CheckboxItem\n> & {\n className?: string;\n checked?: boolean;\n};\n\nexport type DropdownMenuRadioItemProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.RadioItem\n> & {\n className?: string;\n};\n\nexport type DropdownMenuLabelProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Label\n> & {\n className?: string;\n inset?: boolean;\n};\n\nexport type DropdownMenuSeparatorProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Separator\n> & {\n className?: string;\n};\n\nexport type DropdownMenuShortcutProps = React.HTMLAttributes & {\n className?: string;\n};\n\nexport const DropdownMenuSubTrigger = React.forwardRef<\n React.ElementRef,\n DropdownMenuSubTriggerProps\n>(({ className, inset, children, ...props }, ref) => (\n \n {children}\n \n \n));\nDropdownMenuSubTrigger.displayName = DropdownMenuPrimitive.SubTrigger.displayName;\n\nexport const DropdownMenuSubContent = React.forwardRef<\n React.ElementRef,\n DropdownMenuSubContentProps\n>(({ className, ...props }, ref) => (\n \n));\nDropdownMenuSubContent.displayName = DropdownMenuPrimitive.SubContent.displayName;\n\nexport const DropdownMenuContent = React.forwardRef<\n React.ElementRef,\n DropdownMenuContentProps\n>(({ className, sideOffset = 4, ...props }, ref) => (\n \n \n \n));\nDropdownMenuContent.displayName = DropdownMenuPrimitive.Content.displayName;\n\n/**\n * TODO: fix: direction is not automatically handled by this component, so that shortcuts are\n * display always to the right\n */\nexport const DropdownMenuItem = React.forwardRef<\n React.ElementRef,\n DropdownMenuItemProps\n>(({ className, inset, ...props }, ref) => (\n \n));\nDropdownMenuItem.displayName = DropdownMenuPrimitive.Item.displayName;\n\nexport const DropdownMenuCheckboxItem = React.forwardRef<\n React.ElementRef,\n DropdownMenuCheckboxItemProps\n>(({ className, children, checked, ...props }, ref) => (\n \n \n \n \n \n \n {children}\n \n));\nDropdownMenuCheckboxItem.displayName = DropdownMenuPrimitive.CheckboxItem.displayName;\n\nexport const DropdownMenuRadioItem = React.forwardRef<\n React.ElementRef,\n DropdownMenuRadioItemProps\n>(({ className, children, ...props }, ref) => (\n \n \n \n \n \n \n {children}\n \n));\nDropdownMenuRadioItem.displayName = DropdownMenuPrimitive.RadioItem.displayName;\n\nexport const DropdownMenuLabel = React.forwardRef<\n React.ElementRef,\n DropdownMenuLabelProps\n>(({ className, inset, ...props }, ref) => (\n \n));\nDropdownMenuLabel.displayName = DropdownMenuPrimitive.Label.displayName;\n\nexport const DropdownMenuSeparator = React.forwardRef<\n React.ElementRef,\n DropdownMenuSeparatorProps\n>(({ className, ...props }, ref) => (\n \n));\nDropdownMenuSeparator.displayName = DropdownMenuPrimitive.Separator.displayName;\n\nexport function DropdownMenuShortcut({ className, ...props }: DropdownMenuShortcutProps) {\n return (\n \n );\n}\nDropdownMenuShortcut.displayName = 'DropdownMenuShortcut';\n","import { Canon } from '@sillsdev/scripture';\nimport { PropsWithChildren, KeyboardEvent, forwardRef } from 'react';\nimport { DropdownMenuItem as ShadDropdownMenuItem } from '@/components/shadcn-ui/dropdown-menu';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport type BookType = 'OT' | 'NT' | 'DC';\n\ntype BookMenuItemProps = PropsWithChildren<{\n /** String id of book */\n bookId: string;\n /** Callback to run when a book menu item is selected */\n handleSelectBook: () => void;\n /** Indicates if this menu item is currently selected */\n isSelected: boolean;\n /** Function that is called upon highlighting a book in the dropdown menu */\n handleHighlightBook: () => void;\n /**\n * Function that is called on pressing a key\n *\n * @param event Event that contains information about the key stroke\n */\n handleKeyDown: (event: KeyboardEvent) => void;\n /**\n * Type of book associated with this menu item, coordinates color labels ? Mock up has the labels\n * coordinated to genre\n */\n bookType: BookType;\n}>;\n\nconst BookMenuItem = forwardRef(\n (\n {\n bookId,\n handleSelectBook,\n isSelected,\n handleHighlightBook,\n handleKeyDown,\n bookType,\n children,\n }: BookMenuItemProps,\n ref,\n ) => {\n return (\n {\n // preventDefault() here prevents the entire dropdown menu from closing when selecting this item\n event.preventDefault();\n handleSelectBook();\n }}\n onKeyDown={(event: KeyboardEvent) => {\n handleKeyDown(event);\n }}\n onFocus={handleHighlightBook}\n onMouseMove={handleHighlightBook}\n >\n \n {Canon.bookIdToEnglishName(bookId)}\n \n {isSelected &&
    {children}
    }\n \n );\n },\n);\n\nexport default BookMenuItem;\n","import { cn } from '@/utils/shadcn-ui.util';\nimport { useCallback } from 'react';\n\nexport type ChapterSelectProps = {\n /**\n * Callback to run when a chapter div is selected\n *\n * @param chapterNumber Number of the chapter that has been selected\n */\n handleSelectChapter: (chapterNumber: number) => void;\n /** The highest chapter number in the book (of course equal to number of chapters in the book) */\n endChapter: number;\n /** The chapter number that is currently selected */\n activeChapter: number;\n /** The chapter number that is currently highlighted using keyboard or mouse navigation */\n highlightedChapter: number;\n /**\n * Callback to run when a chapter is highlighted by the user\n *\n * @param chapterNumber The chapter that is highlighted\n */\n handleHighlightedChapter: (chapterNumber: number) => void;\n};\n\nfunction ChapterSelect({\n handleSelectChapter,\n endChapter,\n activeChapter,\n highlightedChapter,\n handleHighlightedChapter,\n}: ChapterSelectProps) {\n const chapters = Array.from({ length: endChapter }, (_, i) => i + 1);\n\n const handleMouse = useCallback(\n (chapterNumber: number) => {\n handleHighlightedChapter(chapterNumber);\n },\n [handleHighlightedChapter],\n );\n\n return (\n
    \n {chapters.map((chapter) => (\n {\n event.preventDefault();\n event.stopPropagation();\n handleSelectChapter(chapter);\n }}\n role=\"button\"\n onKeyDown={(event) => {\n if (event.key === 'Enter') {\n handleSelectChapter(chapter);\n }\n }}\n tabIndex={0}\n onMouseMove={() => handleMouse(chapter)}\n >\n {chapter}\n
    \n ))}\n
    \n );\n}\n\nexport default ChapterSelect;\n","import { DropdownMenuLabel as ShadDropdownMenuLabel } from '@/components/shadcn-ui/dropdown-menu';\nimport { Bookmark, Clock, ArrowDownWideNarrow } from 'lucide-react';\n\nexport type GoToMenuItemProps = {\n handleSort: () => void;\n handleLocationHistory: () => void;\n handleBookmarks: () => void;\n};\n\nfunction GoToMenuItem({ handleSort, handleLocationHistory, handleBookmarks }: GoToMenuItemProps) {\n return (\n \n

    Go To

    \n
    \n \n \n \n
    \n
    \n );\n}\n\nexport default GoToMenuItem;\n","import BookChapterInput from '@/components/advanced/book-chapter-control/book-chapter-input.component';\nimport BookMenuItem, {\n BookType,\n} from '@/components/advanced/book-chapter-control/book-menu-item.component';\nimport ChapterSelect from '@/components/advanced/book-chapter-control/chapter-select.component';\nimport GoToMenuItem from '@/components/advanced/book-chapter-control/go-to-menu-item.component';\nimport {\n DropdownMenu as ShadDropdownMenu,\n DropdownMenuContent as ShadDropdownMenuContent,\n DropdownMenuLabel as ShadDropdownMenuLabel,\n DropdownMenuSeparator as ShadDropdownMenuSeparator,\n DropdownMenuTrigger as ShadDropdownMenuTrigger,\n} from '@/components/shadcn-ui/dropdown-menu';\nimport { Canon } from '@sillsdev/scripture';\nimport { ScriptureReference, getChaptersForBook } from 'platform-bible-utils';\nimport {\n KeyboardEvent as ReactKeyboardEvent,\n useCallback,\n useEffect,\n useLayoutEffect,\n useRef,\n useState,\n} from 'react';\n\ntype BookTypeLabels = {\n [bookType in BookType]: string;\n};\ntype BookChapterControlProps = {\n scrRef: ScriptureReference;\n handleSubmit: (scrRef: ScriptureReference) => void;\n};\n\nconst ALL_BOOK_IDS = Canon.allBookIds;\nconst BOOK_TYPE_LABELS: BookTypeLabels = {\n OT: 'Old Testament',\n NT: 'New Testament',\n DC: 'Deuterocanon',\n};\nconst BOOK_TYPE_ARRAY: BookType[] = ['OT', 'NT', 'DC'];\n// This is the height of three menu items to offset scrolling to the selected menu item\n// If you use menuItemRef.clientHeight- includes height of chapter div which is too big\nconst SCROLL_OFFSET = 32 + 32 + 32;\nconst SEARCH_QUERY_FORMATS = [\n /^(\\w+)$/i, // Matches a single word (book name or id)\n /^(\\w+)(?:\\s(\\d+))$/i, // Matches a word followed by a chapter number\n /^(\\w+)(?:\\s(\\d+):(\\d+))$/i, // Matches a word followed by a chapter and verse number\n];\nconst fetchGroupedBooks = (bookType: BookType) => {\n const groupedBooks = {\n OT: ALL_BOOK_IDS.filter((bookId) => Canon.isBookOT(bookId)),\n NT: ALL_BOOK_IDS.filter((bookId) => Canon.isBookNT(bookId)),\n DC: ALL_BOOK_IDS.filter((bookId) => Canon.isBookDC(bookId)),\n };\n return groupedBooks[bookType];\n};\nconst fetchEndChapter = (bookId: string) => {\n // getChaptersForBook returns -1 if not found in scrBookData\n // scrBookData only includes OT and NT, so all DC will return -1\n return getChaptersForBook(Canon.bookIdToNumber(bookId));\n};\n\n/**\n * Gets all of the English names from book ids\n *\n * @returns String[]\n */\nfunction getAllEnglishNames(): string[] {\n const allEnglishNames = ALL_BOOK_IDS.map((bookId) => {\n return Canon.bookIdToEnglishName(bookId);\n });\n return allEnglishNames;\n}\n\n/**\n * Determines if bookName is in allEnglishNames\n *\n * @param bookName Book English name\n * @returns True if bookName is included, false otherwise\n */\nfunction isValidBookEnglishName(bookName: string): boolean {\n return getAllEnglishNames().includes(bookName);\n}\n\n/**\n * Gets a bookId from given English name\n *\n * @param bookName Book English name\n * @returns BookId of provided bookName, undefined otherwise\n */\nfunction getBookIdFromEnglishName(bookName: string): string | undefined {\n // Convert bookName to lowercase and then capitalize the first letter\n const formattedBookName = bookName.toLowerCase().replace(/^\\w/, (c) => c.toUpperCase());\n\n if (isValidBookEnglishName(formattedBookName)) {\n const matchingBookId = ALL_BOOK_IDS.find((bookId) => {\n return Canon.bookIdToEnglishName(bookId) === formattedBookName;\n });\n return matchingBookId;\n }\n\n return undefined;\n}\n\nfunction BookChapterControl({ scrRef, handleSubmit }: BookChapterControlProps) {\n const [searchQuery, setSearchQuery] = useState('');\n const [selectedBookId, setSelectedBookId] = useState(\n Canon.bookNumberToId(scrRef.bookNum),\n );\n const [highlightedChapter, setHighlightedChapter] = useState(scrRef.chapterNum ?? 0);\n const [highlightedBookId, setHighlightedBookId] = useState(\n Canon.bookNumberToId(scrRef.bookNum),\n );\n const [isContentOpen, setIsContentOpen] = useState(false);\n const [isContentOpenDelayed, setIsContentOpenDelayed] = useState(isContentOpen);\n\n // This ref will always be defined\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const inputRef = useRef(undefined!);\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const contentRef = useRef(undefined!);\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const menuItemRef = useRef(undefined!);\n\n const fetchFilteredBooks = useCallback(\n (bookType: BookType) => {\n return fetchGroupedBooks(bookType).filter((bookId: string) => {\n const englishNameLowerCase = Canon.bookIdToEnglishName(bookId).toLowerCase();\n const normalizedQuery = searchQuery.replace(/[^a-zA-Z]/g, '').toLowerCase();\n return (\n englishNameLowerCase.includes(normalizedQuery) || // Match book name\n bookId.toLowerCase().includes(normalizedQuery) // Match book ID\n );\n });\n },\n [searchQuery],\n );\n\n const handleSearchInput = (searchString: string) => {\n setSearchQuery(searchString);\n };\n\n /**\n * Whether to prevent radix's logic from closing the dropdown. This is important because radix\n * tries to close the dropdown when the input first focuses, and we don't want it to do that. But\n * we don't want to prevent the dropdown from closing when we click away from the input, so we\n * don't want to just keep it open if the input is focused\n */\n const shouldPreventAutoClosing = useRef(false);\n\n const controlMenuState = useCallback((open: boolean) => {\n if (shouldPreventAutoClosing.current) {\n shouldPreventAutoClosing.current = false;\n return;\n }\n setIsContentOpen(open);\n }, []);\n\n const updateReference = useCallback(\n (bookId: string, shouldClose: boolean, chapter?: number, verse?: number) => {\n setHighlightedChapter(\n Canon.bookNumberToId(scrRef.bookNum) !== bookId ? 1 : scrRef.chapterNum,\n );\n\n if (shouldClose || fetchEndChapter(bookId) === -1) {\n handleSubmit({\n bookNum: Canon.bookIdToNumber(bookId),\n chapterNum: chapter || 1,\n verseNum: verse || 1,\n });\n\n setIsContentOpen(false);\n setSearchQuery('');\n return;\n }\n\n setSelectedBookId(selectedBookId !== bookId ? bookId : '');\n setIsContentOpen(!shouldClose);\n },\n [handleSubmit, scrRef.bookNum, scrRef.chapterNum, selectedBookId],\n );\n\n const handleSelectChapter = (chapterNumber: number) => {\n if (chapterNumber <= 0 || chapterNumber > fetchEndChapter(selectedBookId)) {\n return;\n }\n updateReference(selectedBookId, true, chapterNumber);\n };\n\n const handleInputSubmit = useCallback(() => {\n SEARCH_QUERY_FORMATS.forEach((format) => {\n const matches = searchQuery.match(format);\n if (matches) {\n // Book should be a bookId or an english name\n const [book, chapter = undefined, verse = undefined] = matches.slice(1);\n const englishName = getBookIdFromEnglishName(book);\n\n if (Canon.isBookIdValid(book) || englishName) {\n updateReference(\n englishName ?? book,\n true,\n chapter ? parseInt(chapter, 10) : 1,\n verse ? parseInt(verse, 10) : 1,\n );\n }\n }\n });\n }, [updateReference, searchQuery]);\n\n const handleKeyDownInput = useCallback(\n (event: ReactKeyboardEvent) => {\n if (!isContentOpen) {\n setIsContentOpen(true);\n } else if (event.key === 'ArrowDown' || event.key === 'ArrowUp') {\n if (\n typeof menuItemRef !== 'undefined' &&\n // Ref uses null\n // eslint-disable-next-line no-null/no-null\n menuItemRef.current !== null\n ) {\n menuItemRef.current.focus();\n } else if (\n typeof contentRef !== 'undefined' &&\n // Ref uses null\n // eslint-disable-next-line no-null/no-null\n contentRef.current !== null\n ) {\n contentRef.current.focus();\n }\n event.preventDefault();\n }\n },\n [isContentOpen],\n );\n\n const handleKeyDownContent = (event: ReactKeyboardEvent) => {\n // When the dropdown menu has focus, key strokes should give focus to the input component,\n // unless they're navigation keys (arrows and enter)\n const { key } = event;\n if (\n key === 'ArrowRight' ||\n key === 'ArrowLeft' ||\n key === 'ArrowDown' ||\n key === 'ArrowUp' ||\n key === 'Enter'\n ) {\n return;\n }\n\n inputRef.current.dispatchEvent(new KeyboardEvent('keydown', { key }));\n inputRef.current.focus();\n };\n\n const handleKeyDownMenuItem = (event: ReactKeyboardEvent) => {\n const { key } = event;\n if (highlightedBookId === selectedBookId) {\n if (key === 'Enter') {\n event.preventDefault();\n updateReference(selectedBookId, true, highlightedChapter);\n return;\n }\n\n let chapterOffSet = 0;\n if (key === 'ArrowRight') {\n if (highlightedChapter < fetchEndChapter(highlightedBookId)) {\n chapterOffSet = 1;\n } else {\n event.preventDefault();\n return;\n }\n } else if (key === 'ArrowLeft') {\n if (highlightedChapter > 1) {\n chapterOffSet = -1;\n } else {\n event.preventDefault();\n return;\n }\n } else if (key === 'ArrowDown') {\n chapterOffSet = 6;\n } else if (key === 'ArrowUp') {\n chapterOffSet = -6;\n }\n if (\n highlightedChapter + chapterOffSet <= 0 ||\n highlightedChapter + chapterOffSet > fetchEndChapter(highlightedBookId)\n ) {\n setHighlightedChapter(0);\n } else if (chapterOffSet !== 0) {\n setHighlightedChapter(highlightedChapter + chapterOffSet);\n event.preventDefault();\n }\n }\n };\n\n useEffect(() => {\n if (selectedBookId === highlightedBookId) {\n if (selectedBookId === Canon.bookNumberToId(scrRef.bookNum)) {\n setHighlightedChapter(scrRef.chapterNum);\n } else {\n setHighlightedChapter(1);\n }\n } else {\n setHighlightedChapter(0);\n }\n }, [highlightedBookId, scrRef.bookNum, scrRef.chapterNum, selectedBookId]);\n\n // The purpose of these useLayoutEffects and timeout is to delay the scroll just\n // enough so that the refs are defined and available when they are used after the timeout\n useLayoutEffect(() => {\n setIsContentOpenDelayed(isContentOpen);\n }, [isContentOpen]);\n\n useLayoutEffect(() => {\n const scrollTimeout = setTimeout(() => {\n if (isContentOpenDelayed && contentRef.current && menuItemRef.current) {\n const menuItemOffsetTop = menuItemRef.current.offsetTop;\n const scrollPosition = menuItemOffsetTop - SCROLL_OFFSET;\n contentRef.current.scrollTo({ top: scrollPosition, behavior: 'instant' });\n }\n }, 10);\n return () => {\n clearTimeout(scrollTimeout);\n };\n }, [isContentOpenDelayed]);\n\n return (\n
    \n \n \n {\n setSelectedBookId(Canon.bookNumberToId(scrRef.bookNum));\n setHighlightedBookId(Canon.bookNumberToId(scrRef.bookNum));\n setHighlightedChapter(scrRef.chapterNum > 0 ? scrRef.chapterNum : 0);\n setIsContentOpen(true);\n inputRef.current.focus();\n }}\n onFocus={() => {\n // Radix thinks we want to close because the input is being focused. Prevent that\n shouldPreventAutoClosing.current = true;\n }}\n handleSubmit={handleInputSubmit}\n placeholder={`${Canon.bookNumberToEnglishName(scrRef.bookNum)} ${scrRef.chapterNum}:${scrRef.verseNum}`}\n />\n \n \n console.log('sorting')}\n handleLocationHistory={() => console.log('location history')}\n handleBookmarks={() => console.log('bookmarks')}\n />\n {BOOK_TYPE_ARRAY.map(\n (bookType, bookTypeIndex) =>\n fetchFilteredBooks(bookType).length > 0 && (\n
    \n \n {BOOK_TYPE_LABELS[bookType]}\n \n\n {fetchFilteredBooks(bookType).map((bookId) => (\n
    \n updateReference(bookId, false)}\n isSelected={selectedBookId === bookId}\n handleHighlightBook={() => setHighlightedBookId(bookId)}\n handleKeyDown={handleKeyDownMenuItem}\n bookType={bookType}\n ref={(element: HTMLDivElement) => {\n if (selectedBookId === bookId) menuItemRef.current = element;\n }}\n >\n {\n setHighlightedChapter(chapterNumber);\n }}\n />\n \n
    \n ))}\n {BOOK_TYPE_ARRAY.length - 1 !== bookTypeIndex ? (\n \n ) : undefined}\n
    \n ),\n )}\n \n
    \n
    \n );\n}\n\nexport default BookChapterControl;\n","import React from 'react';\nimport { Slot } from '@radix-ui/react-slot';\nimport { cva, type VariantProps } from 'class-variance-authority';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport const buttonVariants = cva(\n 'pr-twp tw-inline-flex tw-items-center tw-justify-center tw-whitespace-nowrap tw-rounded-md tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-colors focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50',\n {\n variants: {\n variant: {\n default: 'tw-bg-primary tw-text-primary-foreground hover:tw-bg-primary/90',\n destructive: 'tw-bg-destructive tw-text-destructive-foreground hover:tw-bg-destructive/90',\n outline:\n 'tw-border tw-border-input tw-bg-background hover:tw-bg-accent hover:tw-text-accent-foreground',\n secondary: 'tw-bg-secondary tw-text-secondary-foreground hover:tw-bg-secondary/80',\n ghost: 'hover:tw-bg-accent hover:tw-text-accent-foreground',\n link: 'tw-text-primary tw-underline-offset-4 hover:tw-underline',\n },\n size: {\n default: 'tw-h-10 tw-px-4 tw-py-2',\n sm: 'tw-h-9 tw-rounded-md tw-px-3',\n lg: 'tw-h-11 tw-rounded-md tw-px-8',\n icon: 'tw-h-10 tw-w-10',\n },\n },\n defaultVariants: {\n variant: 'default',\n size: 'default',\n },\n },\n);\n\nexport interface ButtonProps\n extends React.ButtonHTMLAttributes,\n VariantProps {\n asChild?: boolean;\n}\n\nexport const Button = React.forwardRef(\n ({ className, variant, size, asChild = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'button';\n return (\n \n );\n },\n);\nButton.displayName = 'Button';\n","import React from 'react';\nimport * as LabelPrimitive from '@radix-ui/react-label';\nimport { cva, type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst labelVariants = cva(\n 'tw-text-sm tw-font-medium tw-leading-none peer-disabled:tw-cursor-not-allowed peer-disabled:tw-opacity-70',\n);\n\nexport const Label = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef & VariantProps\n>(({ className, ...props }, ref) => (\n \n));\nLabel.displayName = LabelPrimitive.Root.displayName;\n","import React from 'react';\nimport * as RadioGroupPrimitive from '@radix-ui/react-radio-group';\nimport { Circle } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst RadioGroup = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => {\n return (\n \n );\n});\nRadioGroup.displayName = RadioGroupPrimitive.Root.displayName;\n\nconst RadioGroupItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => {\n return (\n \n \n \n \n \n );\n});\nRadioGroupItem.displayName = RadioGroupPrimitive.Item.displayName;\n\nexport { RadioGroup, RadioGroupItem };\n","import React from 'react';\nimport * as PopoverPrimitive from '@radix-ui/react-popover';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Popover = PopoverPrimitive.Root;\n\nconst PopoverTrigger = PopoverPrimitive.Trigger;\n\nconst PopoverContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, align = 'center', sideOffset = 4, ...props }, ref) => (\n \n \n \n));\nPopoverContent.displayName = PopoverPrimitive.Content.displayName;\n\nexport { Popover, PopoverTrigger, PopoverContent };\n","import React from 'react';\nimport * as DialogPrimitive from '@radix-ui/react-dialog';\nimport { X } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Dialog = DialogPrimitive.Root;\n\nconst DialogTrigger = DialogPrimitive.Trigger;\n\nconst DialogPortal = DialogPrimitive.Portal;\n\nconst DialogClose = DialogPrimitive.Close;\n\nconst DialogOverlay = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nDialogOverlay.displayName = DialogPrimitive.Overlay.displayName;\n\nconst DialogContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, ...props }, ref) => (\n \n \n \n {children}\n \n \n Close\n \n \n \n));\nDialogContent.displayName = DialogPrimitive.Content.displayName;\n\nfunction DialogHeader({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nDialogHeader.displayName = 'DialogHeader';\n\nfunction DialogFooter({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nDialogFooter.displayName = 'DialogFooter';\n\nconst DialogTitle = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nDialogTitle.displayName = DialogPrimitive.Title.displayName;\n\nconst DialogDescription = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nDialogDescription.displayName = DialogPrimitive.Description.displayName;\n\nexport {\n Dialog,\n DialogPortal,\n DialogOverlay,\n DialogClose,\n DialogTrigger,\n DialogContent,\n DialogHeader,\n DialogFooter,\n DialogTitle,\n DialogDescription,\n};\n","import React from 'react';\nimport { type DialogProps } from '@radix-ui/react-dialog';\nimport { Command as CommandPrimitive } from 'cmdk';\nimport { Search } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Dialog, DialogContent } from '@/components/shadcn-ui/dialog';\n\nconst Command = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nCommand.displayName = CommandPrimitive.displayName;\n\ninterface CommandDialogProps extends DialogProps {}\n\nfunction CommandDialog({ children, ...props }: CommandDialogProps) {\n return (\n \n \n \n {children}\n \n \n \n );\n}\n\nconst CommandInput = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n
    \n \n \n
    \n));\n\nCommandInput.displayName = CommandPrimitive.Input.displayName;\n\nconst CommandList = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\n\nCommandList.displayName = CommandPrimitive.List.displayName;\n\nconst CommandEmpty = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>((props, ref) => (\n \n));\n\nCommandEmpty.displayName = CommandPrimitive.Empty.displayName;\n\nconst CommandGroup = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\n\nCommandGroup.displayName = CommandPrimitive.Group.displayName;\n\nconst CommandSeparator = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nCommandSeparator.displayName = CommandPrimitive.Separator.displayName;\n\nconst CommandItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\n\nCommandItem.displayName = CommandPrimitive.Item.displayName;\n\nfunction CommandShortcut({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nCommandShortcut.displayName = 'CommandShortcut';\n\nexport {\n Command,\n CommandDialog,\n CommandInput,\n CommandList,\n CommandEmpty,\n CommandGroup,\n CommandItem,\n CommandShortcut,\n CommandSeparator,\n};\n","import { useState } from 'react';\nimport { Check, ChevronsUpDown } from 'lucide-react';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport { Popover, PopoverContent, PopoverTrigger } from '@/components/shadcn-ui/popover';\nimport {\n Command,\n CommandEmpty,\n CommandInput,\n CommandItem,\n CommandList,\n} from '@/components/shadcn-ui/command';\nimport { PopoverProps } from '@radix-ui/react-popover';\n\nexport type ComboBoxLabelOption = { label: string };\nexport type ComboBoxOption = string | number | ComboBoxLabelOption;\n\nexport type ComboBoxProps = {\n /** Optional unique identifier */\n id?: string;\n /** Text label title for combobox */\n /** List of available options for the dropdown menu */\n options?: readonly T[];\n /** @deprecated 3 December 2024. Renamed to {@link buttonClassName} */\n className?: string;\n /** Additional css classes to help with unique styling of the combo box button */\n buttonClassName?: string;\n /** Additional css classes to help with unique styling of the combo box popover */\n popoverContentClassName?: string;\n /**\n * The selected value that the combo box currently holds. Must be shallow equal to one of the\n * options entries.\n */\n value?: T;\n /** Triggers when content of textfield is changed */\n onChange?: (newValue: T) => void;\n /** Used to determine the string value for a given option. */\n getOptionLabel?: (option: ComboBoxOption) => string;\n /** Text displayed on button if `value` is undefined */\n buttonPlaceholder?: string;\n /** Placeholder text for text field */\n textPlaceholder?: string;\n /** Text to display when no options match input */\n commandEmptyMessage?: string;\n /** Variant of button */\n buttonVariant?: ButtonProps['variant'];\n /** Text direction ltr or rtl */\n dir?: Direction;\n /** Optional boolean to set if trigger should be disabled */\n isDisabled?: boolean;\n} & PopoverProps;\n\ntype Direction = 'ltr' | 'rtl';\n\nfunction getOptionLabelDefault(option: ComboBoxOption): string {\n if (typeof option === 'string') {\n return option;\n }\n if (typeof option === 'number') {\n return option.toString();\n }\n return option.label;\n}\n\n/**\n * Autocomplete input and command palette with a list of suggestions.\n *\n * Thanks to Shadcn for heavy inspiration and documentation\n * https://ui.shadcn.com/docs/components/combobox\n */\nfunction ComboBox({\n id,\n options = [],\n buttonClassName,\n popoverContentClassName,\n value,\n onChange = () => {},\n getOptionLabel = getOptionLabelDefault,\n buttonPlaceholder = '',\n textPlaceholder = '',\n commandEmptyMessage = 'No option found',\n buttonVariant = 'outline',\n dir = 'ltr',\n isDisabled = false,\n ...props\n}: ComboBoxProps) {\n const [open, setOpen] = useState(false);\n\n return (\n \n \n \n \n {value ? getOptionLabel(value) : buttonPlaceholder}\n \n \n \n \n \n \n \n {commandEmptyMessage}\n \n {options.map((option) => (\n {\n onChange(option);\n setOpen(false);\n }}\n >\n \n {getOptionLabel(option)}\n \n ))}\n \n \n \n \n );\n}\n\nexport default ComboBox;\n","import { useMemo } from 'react';\nimport ComboBox from '@/components/basics/combo-box.component';\nimport { Label } from '@/components/shadcn-ui/label';\n\nexport type ChapterRangeSelectorProps = {\n startChapter: number;\n endChapter: number;\n handleSelectStartChapter: (chapter: number) => void;\n handleSelectEndChapter: (chapter: number) => void;\n isDisabled?: boolean;\n chapterCount: number;\n};\n\nexport default function ChapterRangeSelector({\n startChapter,\n endChapter,\n handleSelectStartChapter,\n handleSelectEndChapter,\n isDisabled = false,\n chapterCount,\n}: ChapterRangeSelectorProps) {\n const chapterOptions = useMemo(\n () => Array.from({ length: chapterCount }, (_, index) => index + 1),\n [chapterCount],\n );\n\n const onChangeStartChapter = (value: number) => {\n handleSelectStartChapter(value);\n if (value > endChapter) {\n handleSelectEndChapter(value);\n }\n };\n\n const onChangeEndChapter = (value: number) => {\n handleSelectEndChapter(value);\n if (value < startChapter) {\n handleSelectStartChapter(value);\n }\n };\n\n return (\n <>\n \n option.toString()}\n value={startChapter}\n />\n\n \n option.toString()}\n value={endChapter}\n />\n \n );\n}\n","import { Button } from '@/components/shadcn-ui/button';\nimport { Label } from '@/components/shadcn-ui/label';\nimport { RadioGroup, RadioGroupItem } from '@/components/shadcn-ui/radio-group';\nimport { Canon } from '@sillsdev/scripture';\nimport { LocalizedStringValue } from 'platform-bible-utils';\nimport { useState } from 'react';\nimport ChapterRangeSelector, {\n ChapterRangeSelectorProps,\n} from '../basics/chapter-range-selector.component';\n\nexport enum BookSelectionMode {\n CURRENT_BOOK = 'current book',\n CHOOSE_BOOKS = 'choose books',\n}\n\n/**\n * Object containing all keys used for localization in this component. If you're using this\n * component in an extension, you can pass it into the useLocalizedStrings hook to easily obtain the\n * localized strings and pass them into the localizedStrings prop of this component\n */\nexport const BOOK_SELECTOR_STRING_KEYS = Object.freeze([\n '%webView_bookSelector_currentBook%',\n '%webView_bookSelector_choose%',\n '%webView_bookSelector_chooseBooks%',\n] as const);\n\nexport type BookSelectorLocalizedStrings = {\n [localizedInventoryKey in (typeof BOOK_SELECTOR_STRING_KEYS)[number]]?: LocalizedStringValue;\n};\n\n/**\n * Gets the localized value for the provided key\n *\n * @param strings Object containing localized string\n * @param key Key for a localized string\n * @returns The localized value for the provided key, if available. Returns the key if no localized\n * value is available\n */\nconst localizeString = (\n strings: BookSelectorLocalizedStrings,\n key: keyof BookSelectorLocalizedStrings,\n) => {\n return strings[key] ?? key;\n};\n\ntype BookSelectorProps = ChapterRangeSelectorProps & {\n handleBookSelectionModeChange: (newMode: BookSelectionMode) => void;\n currentBookName: string;\n onSelectBooks: () => void;\n selectedBookIds: string[];\n localizedStrings: BookSelectorLocalizedStrings;\n};\n\nexport default function BookSelector({\n handleBookSelectionModeChange,\n currentBookName,\n onSelectBooks,\n selectedBookIds,\n chapterCount,\n endChapter,\n handleSelectEndChapter,\n startChapter,\n handleSelectStartChapter,\n localizedStrings,\n}: BookSelectorProps) {\n const currentBookText = localizeString(localizedStrings, '%webView_bookSelector_currentBook%');\n const chooseText = localizeString(localizedStrings, '%webView_bookSelector_choose%');\n const chooseBooksText = localizeString(localizedStrings, '%webView_bookSelector_chooseBooks%');\n\n const [bookSelectionMode, setBookSelectionMode] = useState(\n BookSelectionMode.CURRENT_BOOK,\n );\n\n const onSelectionModeChange = (newMode: BookSelectionMode) => {\n setBookSelectionMode(newMode);\n handleBookSelectionModeChange(newMode);\n };\n\n return (\n onSelectionModeChange(value as BookSelectionMode)}\n >\n
    \n
    \n
    \n \n \n
    \n \n
    \n \n
    \n
    \n
    \n
    \n \n \n
    \n \n onSelectBooks()}\n >\n {chooseText}\n \n
    \n
    \n \n );\n}\n","import { DropdownMenuTrigger } from '@radix-ui/react-dropdown-menu';\nimport { FilterIcon } from 'lucide-react';\nimport { Table } from '@tanstack/react-table';\n\nimport { Button } from '@/components/shadcn-ui/button';\nimport {\n DropdownMenu,\n DropdownMenuCheckboxItem,\n DropdownMenuContent,\n DropdownMenuLabel,\n DropdownMenuSeparator,\n} from '@/components/shadcn-ui/dropdown-menu';\n\ninterface DataTableViewOptionsProps {\n table: Table;\n}\n\nfunction DataTableViewOptions({ table }: DataTableViewOptionsProps) {\n return (\n \n \n \n \n \n Toggle columns\n \n {table\n .getAllColumns()\n .filter((column) => column.getCanHide())\n .map((column) => {\n return (\n column.toggleVisibility(!!value)}\n >\n {column.id}\n \n );\n })}\n \n \n );\n}\n\nexport default DataTableViewOptions;\n","import React from 'react';\nimport * as SelectPrimitive from '@radix-ui/react-select';\nimport { Check, ChevronDown, ChevronUp } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Select = SelectPrimitive.Root;\n\nconst SelectGroup = SelectPrimitive.Group;\n\nconst SelectValue = SelectPrimitive.Value;\n\nconst SelectTrigger = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, ...props }, ref) => (\n span]:tw-line-clamp-1',\n className,\n )}\n {...props}\n >\n {children}\n \n \n \n \n));\nSelectTrigger.displayName = SelectPrimitive.Trigger.displayName;\n\nconst SelectScrollUpButton = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n));\nSelectScrollUpButton.displayName = SelectPrimitive.ScrollUpButton.displayName;\n\nconst SelectScrollDownButton = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n));\nSelectScrollDownButton.displayName = SelectPrimitive.ScrollDownButton.displayName;\n\nconst SelectContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, position = 'popper', ...props }, ref) => (\n \n \n \n \n {children}\n \n \n \n \n));\nSelectContent.displayName = SelectPrimitive.Content.displayName;\n\nconst SelectLabel = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSelectLabel.displayName = SelectPrimitive.Label.displayName;\n\nconst SelectItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, ...props }, ref) => (\n \n \n \n \n \n \n\n {children}\n \n));\nSelectItem.displayName = SelectPrimitive.Item.displayName;\n\nconst SelectSeparator = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSelectSeparator.displayName = SelectPrimitive.Separator.displayName;\n\nexport {\n Select,\n SelectGroup,\n SelectValue,\n SelectTrigger,\n SelectContent,\n SelectLabel,\n SelectItem,\n SelectSeparator,\n SelectScrollUpButton,\n SelectScrollDownButton,\n};\n","import { ChevronLeftIcon, ChevronRightIcon, ArrowLeftIcon, ArrowRightIcon } from 'lucide-react';\nimport { Table } from '@tanstack/react-table';\n\nimport { Button } from '@/components/shadcn-ui/button';\nimport {\n Select,\n SelectContent,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\n\ninterface DataTablePaginationProps {\n table: Table;\n}\n\nfunction DataTablePagination({ table }: DataTablePaginationProps) {\n return (\n
    \n
    \n
    \n {table.getFilteredSelectedRowModel().rows.length} of{' '}\n {table.getFilteredRowModel().rows.length} row(s) selected\n
    \n
    \n

    Rows per page

    \n {\n table.setPageSize(Number(value));\n }}\n >\n \n \n \n \n {[10, 20, 30, 40, 50].map((pageSize) => (\n \n {pageSize}\n \n ))}\n \n \n
    \n
    \n Page {table.getState().pagination.pageIndex + 1} of {table.getPageCount()}\n
    \n
    \n table.setPageIndex(0)}\n disabled={!table.getCanPreviousPage()}\n >\n Go to first page\n \n \n table.previousPage()}\n disabled={!table.getCanPreviousPage()}\n >\n Go to previous page\n \n \n table.nextPage()}\n disabled={!table.getCanNextPage()}\n >\n Go to next page\n \n \n table.setPageIndex(table.getPageCount() - 1)}\n disabled={!table.getCanNextPage()}\n >\n Go to last page\n \n \n
    \n
    \n
    \n );\n}\n\nexport default DataTablePagination;\n","import React from 'react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Table = React.forwardRef<\n HTMLTableElement,\n React.HTMLAttributes & { stickyHeader?: boolean }\n>(({ className, stickyHeader, ...props }, ref) => (\n
    \n \n
    \n));\nTable.displayName = 'Table';\n\nconst TableHeader = React.forwardRef<\n HTMLTableSectionElement,\n React.HTMLAttributes & { stickyHeader?: boolean }\n>(({ className, stickyHeader, ...props }, ref) => (\n \n));\nTableHeader.displayName = 'TableHeader';\n\nconst TableBody = React.forwardRef<\n HTMLTableSectionElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableBody.displayName = 'TableBody';\n\nconst TableFooter = React.forwardRef<\n HTMLTableSectionElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n tr]:last:tw-border-b-0', className)}\n {...props}\n />\n));\nTableFooter.displayName = 'TableFooter';\n\nconst TableRow = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nTableRow.displayName = 'TableRow';\n\nconst TableHead = React.forwardRef<\n HTMLTableCellElement,\n React.ThHTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableHead.displayName = 'TableHead';\n\nconst TableCell = React.forwardRef<\n HTMLTableCellElement,\n React.TdHTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableCell.displayName = 'TableCell';\n\nconst TableCaption = React.forwardRef<\n HTMLTableCaptionElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableCaption.displayName = 'TableCaption';\n\nexport { Table, TableHeader, TableBody, TableFooter, TableHead, TableRow, TableCell, TableCaption };\n","import { useState } from 'react';\n\nimport {\n ColumnFiltersState,\n flexRender,\n getCoreRowModel,\n getFilteredRowModel,\n getPaginationRowModel,\n getSortedRowModel,\n SortingState,\n ColumnDef as TSColumnDef,\n Row as TSRow,\n RowSelectionState as TSRowSelectionState,\n SortDirection as TSSortDirection,\n Table as TSTable,\n useReactTable,\n VisibilityState,\n} from '@tanstack/react-table';\n\nimport DataTableViewOptions from '@/components/advanced/data-table/data-table-column-toggle.component';\nimport DataTablePagination from '@/components/advanced/data-table/data-table-pagination.component';\nimport { Button } from '@/components/shadcn-ui/button';\nimport {\n Table,\n TableBody,\n TableCell,\n TableHead,\n TableHeader,\n TableRow,\n} from '@/components/shadcn-ui/table';\n\nexport type ColumnDef = TSColumnDef;\nexport type RowContents = TSRow;\nexport type TableContents = TSTable;\nexport type SortDirection = TSSortDirection;\nexport type RowSelectionState = TSRowSelectionState;\n\ninterface DataTableProps {\n columns: ColumnDef[];\n data: TData[];\n enablePagination?: boolean;\n showPaginationControls?: boolean;\n showColumnVisibilityControls?: boolean;\n stickyHeader?: boolean;\n onRowClickHandler?: (row: RowContents, table: TableContents) => void;\n}\n\n/**\n * Feature-rich table component that infuses our basic shadcn-based Table component with features\n * from TanStack's React Table library\n */\nfunction DataTable({\n columns,\n data,\n enablePagination = false,\n showPaginationControls = false,\n showColumnVisibilityControls = false,\n stickyHeader = false,\n onRowClickHandler = () => {},\n}: DataTableProps) {\n const [sorting, setSorting] = useState([]);\n const [columnFilters, setColumnFilters] = useState([]);\n const [columnVisibility, setColumnVisibility] = useState({});\n const [rowSelection, setRowSelection] = useState({});\n\n const table = useReactTable({\n data,\n columns,\n getCoreRowModel: getCoreRowModel(),\n ...(enablePagination && { getPaginationRowModel: getPaginationRowModel() }),\n onSortingChange: setSorting,\n getSortedRowModel: getSortedRowModel(),\n onColumnFiltersChange: setColumnFilters,\n getFilteredRowModel: getFilteredRowModel(),\n onColumnVisibilityChange: setColumnVisibility,\n onRowSelectionChange: setRowSelection,\n state: {\n sorting,\n columnFilters,\n columnVisibility,\n rowSelection,\n },\n });\n\n return (\n
    \n {showColumnVisibilityControls && }\n \n \n {table.getHeaderGroups().map((headerGroup) => (\n \n {headerGroup.headers.map((header) => {\n return (\n \n {header.isPlaceholder\n ? undefined\n : flexRender(header.column.columnDef.header, header.getContext())}\n \n );\n })}\n \n ))}\n \n \n {table.getRowModel().rows?.length ? (\n table.getRowModel().rows.map((row) => (\n onRowClickHandler(row, table)}\n key={row.id}\n data-state={row.getIsSelected() && 'selected'}\n >\n {row.getVisibleCells().map((cell) => (\n \n {flexRender(cell.column.columnDef.cell, cell.getContext())}\n \n ))}\n \n ))\n ) : (\n \n \n No results.\n \n \n )}\n \n
    \n {enablePagination && (\n
    \n table.previousPage()}\n disabled={!table.getCanPreviousPage()}\n >\n Previous\n \n table.nextPage()}\n disabled={!table.getCanNextPage()}\n >\n Next\n \n
    \n )}\n {enablePagination && showPaginationControls && }\n
    \n );\n}\n\nexport default DataTable;\n","import {\n Table,\n TableBody,\n TableCell,\n TableHead,\n TableHeader,\n TableRow,\n} from '@/components/shadcn-ui/table';\nimport { Canon } from '@sillsdev/scripture';\nimport { deepEqual, LanguageStrings, ScriptureReference } from 'platform-bible-utils';\nimport { useMemo } from 'react';\nimport { InventoryItemOccurrence } from './inventory-utils';\n\n/** Props for the OccurrencesTable component */\ntype OccurrencesTableProps = {\n /** Data that contains scriptures references and snippets of scripture */\n occurrenceData: InventoryItemOccurrence[];\n /** Callback function that is executed when the scripture reference is changed */\n setScriptureReference: (scriptureReference: ScriptureReference) => void;\n /**\n * Object with all localized strings that the OccurrencesTable needs to work well across multiple\n * languages\n */\n localizedStrings: LanguageStrings;\n};\n\n/**\n * Table that shows occurrences of specified inventory item(s). The first column shows the related\n * scripture reference. The second column shows the snippet of scripture that contains the specified\n * inventory item\n */\nfunction OccurrencesTable({\n occurrenceData,\n setScriptureReference,\n localizedStrings,\n}: OccurrencesTableProps) {\n const referenceHeaderText =\n localizedStrings['%webView_inventory_occurrences_table_header_reference%'];\n const occurrenceHeaderText =\n localizedStrings['%webView_inventory_occurrences_table_header_occurrence%'];\n\n const occurrences: InventoryItemOccurrence[] = useMemo(() => {\n const uniqueOccurrences: InventoryItemOccurrence[] = [];\n\n occurrenceData.forEach((occurrence) => {\n if (!uniqueOccurrences.some((uniqueOccurrence) => deepEqual(uniqueOccurrence, occurrence))) {\n uniqueOccurrences.push(occurrence);\n }\n });\n\n return uniqueOccurrences;\n }, [occurrenceData]);\n\n return (\n \n \n \n {referenceHeaderText}\n {occurrenceHeaderText}\n \n \n \n {occurrences.length > 0 &&\n occurrences.map((occurrence) => (\n {\n setScriptureReference(occurrence.reference);\n }}\n >\n {`${Canon.bookNumberToEnglishName(occurrence.reference.bookNum)} ${occurrence.reference.chapterNum}:${occurrence.reference.verseNum}`}\n {occurrence.text}\n \n ))}\n \n
    \n );\n}\n\nexport default OccurrencesTable;\n","import React from 'react';\nimport * as CheckboxPrimitive from '@radix-ui/react-checkbox';\nimport { Check } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Checkbox = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n \n \n));\nCheckbox.displayName = CheckboxPrimitive.Root.displayName;\n\nexport default Checkbox;\n","import { Canon } from '@sillsdev/scripture';\nimport { ScriptureReference } from 'platform-bible-utils';\n\n/* #region Types */\n\n/**\n * Status of items that appear in inventories. 'approved' and 'unapproved' items are defined in the\n * project's `Settings.xml`. All other items are defined as 'unknown'\n */\nexport type Status = 'approved' | 'unapproved' | 'unknown';\n\n/** Occurrence of item in inventory. Primarily used by table that shows occurrences */\nexport type InventoryItemOccurrence = {\n /** Reference to scripture where the item appears */\n reference: ScriptureReference;\n /** Snippet of scripture that contains the occurrence */\n text: string;\n};\n\n/** Data structure that contains all information on an item that is shown in an inventory */\nexport type InventoryTableData = {\n /**\n * The item (e.g. a character in the characters inventory, a marker in the marker inventory) In\n * most cases the array will only have one element. In case of additional items (e.g. the\n * preceding marker in the markers check), the primary item should be stored in the first index.\n * To show additional items in the inventory, make sure to configure the `additionalItemsLabels`\n * prop for the Inventory component\n */\n items: string[];\n /** The number of times this item occurs in the selected scope */\n count: number;\n /** The status of this item (see documentation for `Status` type for more information) */\n status: Status;\n /** Occurrences of this item in the scripture text for the selected scope */\n occurrences: InventoryItemOccurrence[];\n};\n\n/* #endregion */\n\n/* #region Functions */\n\n/**\n * Splits USFM string into shorter line-like segments\n *\n * @param text A single (likely very large) USFM string\n * @returns An array containing the input text, split into shorter segments\n */\nexport const getLinesFromUSFM = (text: string) => {\n // Splits on (CR)LF, CR, \\v, \\c and \\id\n return text.split(/(?:\\r?\\n|\\r)|(?=(?:\\\\(?:v|c|id)))/g);\n};\n\n/**\n * Extracts chapter or verse number from USFM strings that start with a \\c or \\v marker\n *\n * @param text USFM string that is expected to start with \\c or \\v marker\n * @returns Chapter or verse number if one is found. Else returns 0.\n */\nexport const getNumberFromUSFM = (text: string): number | undefined => {\n // Captures all digits that follow \\v or \\c markers followed by whitespace located at the start of a string\n const regex = /^\\\\[vc]\\s+(\\d+)/;\n const match = text.match(regex);\n\n if (match) {\n return +match[1];\n }\n return undefined;\n};\n\n/**\n * Gets book ID from USFM string that starts with the \\id marker, and returns book number for it\n *\n * @param text USFM string that is expected to start with \\id marker\n * @returns Book number corresponding to the \\id marker in the input text. Returns 0 if no marker is\n * found or the marker is not valid\n */\nexport const getBookNumFromId = (text: string): number => {\n // Captures all digits that follow an \\id marker followed by whitespace located at the start of a string\n const match = text.match(/^\\\\id\\s+([A-Za-z]+)/);\n if (match) {\n return Canon.bookIdToNumber(match[1]);\n }\n return 0;\n};\n\n/**\n * Gets the status for an item, typically used in the Inventory component\n *\n * @param item The item for which the status is being requested\n * @param approvedItems Array of approved items, typically as defined in `Settings.xml`\n * @param unapprovedItems Array of unapproved items, typically as defined in `Settings.xml`\n * @returns The status for the specified item\n */\nexport const getStatusForItem = (\n item: string,\n approvedItems: string[],\n unapprovedItems: string[],\n): Status => {\n if (unapprovedItems.includes(item)) return 'unapproved';\n if (approvedItems.includes(item)) return 'approved';\n return 'unknown';\n};\n\n/* #endregion */\n","import React from 'react';\nimport * as TogglePrimitive from '@radix-ui/react-toggle';\nimport { cva, type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst toggleVariants = cva(\n 'pr-twp tw-inline-flex tw-items-center tw-justify-center tw-rounded-md tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-colors hover:tw-bg-muted hover:tw-text-muted-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50 data-[state=on]:tw-bg-accent data-[state=on]:tw-text-accent-foreground',\n {\n variants: {\n variant: {\n default: 'tw-bg-transparent',\n outline:\n 'tw-border tw-border-input tw-bg-transparent hover:tw-bg-accent hover:tw-text-accent-foreground',\n },\n size: {\n default: 'tw-h-10 tw-px-3',\n sm: 'tw-h-9 tw-px-2.5',\n lg: 'tw-h-11 tw-px-5',\n },\n },\n defaultVariants: {\n variant: 'default',\n size: 'default',\n },\n },\n);\n\nconst Toggle = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef & VariantProps\n>(({ className, variant, size, ...props }, ref) => (\n \n));\n\nToggle.displayName = TogglePrimitive.Root.displayName;\n\nexport { Toggle, toggleVariants };\n","import React from 'react';\nimport * as ToggleGroupPrimitive from '@radix-ui/react-toggle-group';\nimport { type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { toggleVariants } from '@/components/shadcn-ui/toggle';\n\nconst ToggleGroupContext = React.createContext>({\n size: 'default',\n variant: 'default',\n});\n\nconst ToggleGroup = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef &\n VariantProps\n>(({ className, variant, size, children, ...props }, ref) => (\n \n \n {children}\n \n \n));\n\nToggleGroup.displayName = ToggleGroupPrimitive.Root.displayName;\n\nconst ToggleGroupItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef &\n VariantProps\n>(({ className, children, variant, size, ...props }, ref) => {\n const context = React.useContext(ToggleGroupContext);\n\n return (\n \n {children}\n \n );\n});\n\nToggleGroupItem.displayName = ToggleGroupPrimitive.Item.displayName;\n\nexport { ToggleGroup, ToggleGroupItem };\n","import { ColumnDef, SortDirection } from '@/components/advanced/data-table/data-table.component';\nimport { Button } from '@/components/shadcn-ui/button';\nimport { ToggleGroup, ToggleGroupItem } from '@/components/shadcn-ui/toggle-group';\nimport {\n ArrowDownIcon,\n ArrowUpDownIcon,\n ArrowUpIcon,\n CircleCheckIcon,\n CircleHelpIcon,\n CircleXIcon,\n} from 'lucide-react';\nimport { ReactNode } from 'react';\nimport { InventoryTableData, Status } from './inventory-utils';\n\n/**\n * Gets an icon that indicates the current sorting direction based on the provided input\n *\n * @param sortDirection Sorting direction. Can be ascending ('asc'), descending ('desc') or false (\n * i.e. not sorted)\n * @returns The appropriate sorting icon for the provided sorting direction\n */\nconst getSortingIcon = (sortDirection: false | SortDirection): ReactNode => {\n if (sortDirection === 'asc') {\n return ;\n }\n if (sortDirection === 'desc') {\n return ;\n }\n return ;\n};\n\n/**\n * Function that creates the item column for inventories\n *\n * @param itemLabel Localized label for the item column (e.g. 'Character', 'Repeated Word', etc.)\n * @returns Column that shows the inventory items. Should be used with the DataTable component\n */\nexport const inventoryItemColumn = (itemLabel: string): ColumnDef => {\n return {\n accessorKey: 'item',\n accessorFn: (row: InventoryTableData) => row.items[0],\n header: ({ column }) => (\n \n ),\n };\n};\n\n/**\n * Function that creates the additional item columns for inventories\n *\n * @param additionalItemLabel Localized label for the additional item column (e.g. 'Preceding\n * Marker')\n * @param additionalItemIndex Index that locates the desired item in the items array of the\n * inventory\n * @returns Column that shows additional inventory items. Should be used with the DataTable\n * component\n */\nexport const inventoryAdditionalItemColumn = (\n additionalItemLabel: string,\n additionalItemIndex: number,\n): ColumnDef => {\n return {\n accessorKey: `item${additionalItemIndex}`,\n accessorFn: (row: InventoryTableData) => row.items[additionalItemIndex],\n header: ({ column }) => (\n \n ),\n };\n};\n\n/**\n * Function that creates the count column for inventories. Should be used with the DataTable\n * component.\n *\n * @param itemLabel Localized label for the count column\n * @returns Column that shows the number of occurrences of the related inventory items\n */\nexport const inventoryCountColumn = (countLabel: string): ColumnDef => {\n return {\n accessorKey: 'count',\n header: ({ column }) => (\n
    \n \n
    \n ),\n cell: ({ row }) =>
    {row.getValue('count')}
    ,\n };\n};\n\n/**\n * Function that updates project settings when status for item(s) changes\n *\n * @param changedItems Array of items for which the status is being updated\n * @param newStatus The status that the items are being given\n * @param approvedItems Array of currently approved items\n * @param onApprovedItemsChange Callback function that stores the updated list of approved items\n * @param unapprovedItems Array of currently unapproved items\n * @param onUnapprovedItemsChange Callback function that stores the updated list of unapproved items\n */\nconst statusChangeHandler = (\n changedItems: string[],\n newStatus: Status,\n approvedItems: string[],\n onApprovedItemsChange: (items: string[]) => void,\n unapprovedItems: string[],\n onUnapprovedItemsChange: (items: string[]) => void,\n) => {\n let newApprovedItems: string[] = [...approvedItems];\n changedItems.forEach((item) => {\n if (newStatus === 'approved') {\n if (!newApprovedItems.includes(item)) {\n newApprovedItems.push(item);\n }\n } else {\n newApprovedItems = newApprovedItems.filter((validItem) => validItem !== item);\n }\n });\n onApprovedItemsChange(newApprovedItems);\n\n let newUnapprovedItems: string[] = [...unapprovedItems];\n changedItems.forEach((item) => {\n if (newStatus === 'unapproved') {\n if (!newUnapprovedItems.includes(item)) {\n newUnapprovedItems.push(item);\n }\n } else {\n newUnapprovedItems = newUnapprovedItems.filter((unapprovedItem) => unapprovedItem !== item);\n }\n });\n onUnapprovedItemsChange(newUnapprovedItems);\n};\n\n/**\n * Function that creates the status column for inventories. Should be used with the DataTable\n * component.\n *\n * @param statusLabel Localized label for the status column\n * @param approvedItems Array of approved items, typically as defined in `Settings.xml`\n * @param onApprovedItemsChange Callback function that stores the updated list of approved items\n * @param unapprovedItems Array of unapproved items, typically as defined in `Settings.xml`\n * @param onUnapprovedItemsChange Callback function that stores the updated list of unapproved items\n * @returns Column that shows the status buttons for the related inventory item. The button for the\n * current status of the item is selected\n */\nexport const inventoryStatusColumn = (\n statusLabel: string,\n approvedItems: string[],\n onApprovedItemsChange: (items: string[]) => void,\n unapprovedItems: string[],\n onUnapprovedItemsChange: (items: string[]) => void,\n): ColumnDef => {\n return {\n accessorKey: 'status',\n header: ({ column }) => {\n return (\n
    \n \n
    \n );\n },\n cell: ({ row }) => {\n const status: Status = row.getValue('status');\n const item: string = row.getValue('item');\n return (\n \n \n statusChangeHandler(\n [item],\n 'approved',\n approvedItems,\n onApprovedItemsChange,\n unapprovedItems,\n onUnapprovedItemsChange,\n )\n }\n value=\"approved\"\n >\n \n \n \n statusChangeHandler(\n [item],\n 'unapproved',\n approvedItems,\n onApprovedItemsChange,\n unapprovedItems,\n onUnapprovedItemsChange,\n )\n }\n value=\"unapproved\"\n >\n \n \n \n statusChangeHandler(\n [item],\n 'unknown',\n approvedItems,\n onApprovedItemsChange,\n unapprovedItems,\n onUnapprovedItemsChange,\n )\n }\n value=\"unknown\"\n >\n \n \n \n );\n },\n };\n};\n","import DataTable, {\n ColumnDef,\n RowContents,\n RowSelectionState,\n TableContents,\n} from '@/components/advanced/data-table/data-table.component';\nimport OccurrencesTable from '@/components/advanced/inventory/occurrences-table.component';\nimport Checkbox from '@/components/shadcn-ui/checkbox';\nimport { Input } from '@/components/shadcn-ui/input';\nimport { Label } from '@/components/shadcn-ui/label';\nimport {\n Select,\n SelectContent,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\nimport {\n deepEqual,\n LocalizedStringValue,\n ScriptureReference,\n substring,\n} from 'platform-bible-utils';\nimport { useEffect, useMemo, useState } from 'react';\nimport {\n getBookNumFromId,\n getLinesFromUSFM,\n getNumberFromUSFM,\n getStatusForItem,\n InventoryItemOccurrence,\n InventoryTableData,\n Status,\n} from './inventory-utils';\nimport { inventoryAdditionalItemColumn } from './inventory-columns';\n\n/**\n * Object containing all keys used for localization in this component. If you're using this\n * component in an extension, you can pass it into the useLocalizedStrings hook to easily obtain the\n * localized strings and pass them into the localizedStrings prop of this component\n */\nexport const INVENTORY_STRING_KEYS = Object.freeze([\n '%webView_inventory_all%',\n '%webView_inventory_approved%',\n '%webView_inventory_unapproved%',\n '%webView_inventory_unknown%',\n '%webView_inventory_scope_currentBook%',\n '%webView_inventory_scope_chapter%',\n '%webView_inventory_scope_verse%',\n '%webView_inventory_filter_text%',\n '%webView_inventory_show_additional_items%',\n '%webView_inventory_occurrences_table_header_reference%',\n '%webView_inventory_occurrences_table_header_occurrence%',\n] as const);\n\nexport type InventoryLocalizedStrings = {\n [localizedInventoryKey in (typeof INVENTORY_STRING_KEYS)[number]]?: LocalizedStringValue;\n};\n\n/** Scope of scripture that the inventory can operate on */\nexport type Scope = 'book' | 'chapter' | 'verse';\n\n/** Status values that the status filter can select from */\ntype StatusFilter = Status | 'all';\n\n/** Text labels for the inventory columns and the control components of additional inventory items */\ntype AdditionalItemsLabels = {\n checkboxText?: string;\n tableHeaders?: string[];\n};\n\n/**\n * Filters data that is shown in the DataTable section of the Inventory\n *\n * @param itemData All inventory items and their related information\n * @param statusFilter Allows filtering by status (i.e. show all items, or only items that are\n * 'approved', 'unapproved' or 'unknown')\n * @param textFilter Allows filtering by text. All items that include the filter text will be\n * selected.\n * @returns Array of items and their related information that are matched by the specified filters\n */\nconst filterItemData = (\n itemData: InventoryTableData[],\n statusFilter: StatusFilter,\n textFilter: string,\n): InventoryTableData[] => {\n let filteredItemData: InventoryTableData[] = itemData;\n\n if (statusFilter !== 'all') {\n filteredItemData = filteredItemData.filter(\n (item) =>\n (statusFilter === 'approved' && item.status === 'approved') ||\n (statusFilter === 'unapproved' && item.status === 'unapproved') ||\n (statusFilter === 'unknown' && item.status === 'unknown'),\n );\n }\n\n if (textFilter !== '')\n filteredItemData = filteredItemData.filter((item) => item.items[0].includes(textFilter));\n\n return filteredItemData;\n};\n\n/**\n * Turns array of strings into array of inventory items, along with their count and status\n *\n * @param text The source scripture text that is searched for inventory items\n * @param scriptureRef The scripture reference that the application is currently set to\n * @param approvedItems Array of approved items, typically as defined in `Settings.xml`\n * @param unapprovedItems Array of unapproved items, typically as defined in `Settings.xml`\n * @param itemRegex Regular expression that describes what items this Inventory should extract from\n * the provided scripture text\n * @returns Array of inventory items, along with their count and status\n */\nconst createTableData = (\n text: string | undefined,\n scriptureRef: ScriptureReference,\n approvedItems: string[],\n unapprovedItems: string[],\n itemRegex: RegExp,\n): InventoryTableData[] => {\n if (!text) return [];\n\n const tableData: InventoryTableData[] = [];\n\n let currentBook: number | undefined = scriptureRef.bookNum;\n let currentChapter: number | undefined = scriptureRef.chapterNum;\n let currentVerse: number | undefined = scriptureRef.verseNum;\n\n const lines = getLinesFromUSFM(text);\n\n lines.forEach((line: string) => {\n if (line.startsWith('\\\\id')) {\n currentBook = getBookNumFromId(line);\n currentChapter = 0;\n currentVerse = 0;\n }\n if (line.startsWith('\\\\c')) {\n currentChapter = getNumberFromUSFM(line);\n currentVerse = 0;\n }\n if (line.startsWith('\\\\v')) {\n currentVerse = getNumberFromUSFM(line);\n if (currentChapter === 0) {\n currentChapter = scriptureRef.chapterNum;\n }\n }\n\n let match: RegExpExecArray | undefined = itemRegex.exec(line) ?? undefined;\n while (match) {\n const items: string[] = [];\n match.forEach((item) => items.push(item));\n const itemIndex = match.index;\n const existingItem = tableData.find((tableEntry) => deepEqual(tableEntry.items, items));\n const newReference: InventoryItemOccurrence = {\n reference: {\n bookNum: currentBook !== undefined ? currentBook : -1,\n chapterNum: currentChapter !== undefined ? currentChapter : -1,\n verseNum: currentVerse !== undefined ? currentVerse : -1,\n },\n text: substring(line, Math.max(0, itemIndex - 25), Math.min(itemIndex + 25, line.length)),\n };\n if (existingItem) {\n existingItem.count += 1;\n existingItem.occurrences.push(newReference);\n } else {\n const newItem: InventoryTableData = {\n items,\n count: 1,\n status: getStatusForItem(items[0], approvedItems, unapprovedItems),\n occurrences: [newReference],\n };\n tableData.push(newItem);\n }\n\n match = itemRegex.exec(line) ?? undefined;\n }\n });\n\n return tableData;\n};\n\n/**\n * Gets the localized value for the provided key\n *\n * @param strings Object containing localized string\n * @param key Key for a localized string\n * @returns The localized value for the provided key, if available. Returns the key if no localized\n * value is available\n */\nconst localizeString = (\n strings: InventoryLocalizedStrings,\n key: keyof InventoryLocalizedStrings,\n) => {\n return strings[key] ?? key;\n};\n\n/** Props for the Inventory component */\ntype InventoryProps = {\n /** The scripture reference that the application is currently set to */\n scriptureReference: ScriptureReference;\n /** Callback function that is executed when the scripture reference is changed */\n setScriptureReference: (scriptureReference: ScriptureReference) => void;\n /**\n * Object with all localized strings that the Inventory needs to work well across multiple\n * languages. When using this component with Platform.Bible, you can import\n * `INVENTORY_STRING_KEYS` from this library, pass it in to the Platform's localization hook, and\n * pass the localized keys that are returned by the hook into this prop.\n */\n localizedStrings: InventoryLocalizedStrings;\n /**\n * The logic that finds the desired items in the source text. This can either be a Regular\n * expression that captures one or multiple items (preferred), or a custom function that builds\n * and return an InventoryDataTable[] manually. Note: In case the logic captures more than one\n * item (i.e. InventoryTableData.items has a length greater than 1), you must provide text labels\n * for the related columns and control elements to show by setting the `additionalItemsLabels`\n * prop\n */\n extractItems:\n | RegExp\n | ((\n text: string | undefined,\n scriptureRef: ScriptureReference,\n approvedItems: string[],\n unapprovedItems: string[],\n ) => InventoryTableData[]);\n /**\n * Text labels for control elements and additional column headers in case your Inventory has more\n * than one item to show (e.g. The 'Preceding Marker' in the Markers Inventory)\n */\n additionalItemsLabels?: AdditionalItemsLabels;\n /** Array of approved items, typically as defined in `Settings.xml` */\n approvedItems: string[];\n /** Array of unapproved items, typically as defined in `Settings.xml` */\n unapprovedItems: string[];\n /** The source scripture text that is searched for in inventory items */\n text: string | undefined;\n /** Scope of scripture that the inventory will operate on */\n scope: Scope;\n /** Callback function that is executed when the scope is changed from the Inventory */\n onScopeChange: (scope: Scope) => void;\n /**\n * Column definitions for the Inventory data table. The most commonly used column definitions are\n * pre-configured for your convenience and can be imported (e.g. inventoryItemColumn,\n * inventoryAdditionalItemColumn inventoryCountColumn, and inventoryStatusColumn). If you need any\n * other columns you can add these yourself\n */\n columns: ColumnDef[];\n};\n\n/** Inventory component that is used to view and control the status of provided project settings */\nexport default function Inventory({\n scriptureReference,\n setScriptureReference,\n localizedStrings,\n extractItems,\n additionalItemsLabels,\n approvedItems,\n unapprovedItems,\n text,\n scope,\n onScopeChange,\n columns,\n}: InventoryProps) {\n const allItemsText = localizeString(localizedStrings, '%webView_inventory_all%');\n const approvedItemsText = localizeString(localizedStrings, '%webView_inventory_approved%');\n const unapprovedItemsText = localizeString(localizedStrings, '%webView_inventory_unapproved%');\n const unknownItemsText = localizeString(localizedStrings, '%webView_inventory_unknown%');\n const scopeBookText = localizeString(localizedStrings, '%webView_inventory_scope_currentBook%');\n const scopeChapterText = localizeString(localizedStrings, '%webView_inventory_scope_chapter%');\n const scopeVerseText = localizeString(localizedStrings, '%webView_inventory_scope_verse%');\n const filterText = localizeString(localizedStrings, '%webView_inventory_filter_text%');\n const showAdditionalItemsText = localizeString(\n localizedStrings,\n '%webView_inventory_show_additional_items%',\n );\n\n const [showAdditionalItems, setShowAdditionalItems] = useState(false);\n const [statusFilter, setStatusFilter] = useState('all');\n const [textFilter, setTextFilter] = useState('');\n const [selectedItem, setSelectedItem] = useState([]);\n\n const tableData: InventoryTableData[] = useMemo(() => {\n if (!text) return [];\n if (extractItems instanceof RegExp)\n return createTableData(\n text,\n scriptureReference,\n approvedItems,\n unapprovedItems,\n extractItems,\n );\n return extractItems(text, scriptureReference, approvedItems, unapprovedItems);\n }, [text, extractItems, scriptureReference, approvedItems, unapprovedItems]);\n\n const reducedTableData: InventoryTableData[] = useMemo(() => {\n if (showAdditionalItems) return tableData;\n\n const newTableData: InventoryTableData[] = [];\n\n tableData.forEach((tableEntry) => {\n const firstItem = tableEntry.items[0];\n\n const existingEntry = newTableData.find(\n (newTableEntry) => newTableEntry.items[0] === firstItem,\n );\n\n if (existingEntry) {\n existingEntry.count += tableEntry.count;\n existingEntry.occurrences = existingEntry.occurrences.concat(tableEntry.occurrences);\n } else {\n newTableData.push({\n items: [firstItem],\n count: tableEntry.count,\n occurrences: tableEntry.occurrences,\n status: tableEntry.status,\n });\n }\n });\n\n return newTableData;\n }, [showAdditionalItems, tableData]);\n\n const filteredTableData: InventoryTableData[] = useMemo(() => {\n return filterItemData(reducedTableData, statusFilter, textFilter);\n }, [reducedTableData, statusFilter, textFilter]);\n\n const allColumns: ColumnDef[] = useMemo(() => {\n if (!showAdditionalItems) return columns;\n\n const numberOfAdditionalItems = additionalItemsLabels?.tableHeaders?.length;\n if (!numberOfAdditionalItems) return columns;\n\n const additionalColumns: ColumnDef[] = [];\n\n for (let index = 0; index < numberOfAdditionalItems; index++) {\n additionalColumns.push(\n inventoryAdditionalItemColumn(\n additionalItemsLabels?.tableHeaders?.[index] || 'Additional Item',\n index + 1,\n ),\n );\n }\n\n return [...additionalColumns, ...columns];\n }, [additionalItemsLabels?.tableHeaders, columns, showAdditionalItems]);\n\n useEffect(() => {\n setSelectedItem([]);\n }, [filteredTableData]);\n\n const rowClickHandler = (\n row: RowContents,\n table: TableContents,\n ) => {\n table.setRowSelection(() => {\n const newSelection: RowSelectionState = {};\n newSelection[row.index] = true;\n return newSelection;\n });\n\n setSelectedItem(row.original.items);\n };\n\n const handleScopeChange = (value: string) => {\n if (value === 'book' || value === 'chapter' || value === 'verse') {\n onScopeChange(value);\n } else {\n throw new Error(`Invalid scope value: ${value}`);\n }\n };\n\n const handleStatusFilterChange = (value: string) => {\n if (value === 'all' || value === 'approved' || value === 'unapproved' || value === 'unknown') {\n setStatusFilter(value);\n } else {\n throw new Error(`Invalid status filter value: ${value}`);\n }\n };\n\n const occurrenceData: InventoryItemOccurrence[] = useMemo(() => {\n if (reducedTableData.length === 0 || selectedItem.length === 0) return [];\n const occurrence = reducedTableData.filter((tableEntry: InventoryTableData) => {\n return deepEqual(\n showAdditionalItems ? tableEntry.items : [tableEntry.items[0]],\n selectedItem,\n );\n });\n if (occurrence.length > 1) throw new Error('Selected item is not unique');\n return occurrence[0].occurrences;\n }, [selectedItem, showAdditionalItems, reducedTableData]);\n\n return (\n
    \n
    \n handleStatusFilterChange(value)}\n defaultValue={statusFilter}\n >\n \n \n \n \n {allItemsText}\n {approvedItemsText}\n {unapprovedItemsText}\n {unknownItemsText}\n \n \n \n {\n setTextFilter(event.target.value);\n }}\n />\n {additionalItemsLabels && (\n
    \n {\n setSelectedItem([]);\n setShowAdditionalItems(checked);\n }}\n />\n \n
    \n )}\n
    \n
    \n \n
    \n {occurrenceData.length > 0 && (\n
    \n \n
    \n )}\n
    \n );\n}\n","import { Input } from '@/components/shadcn-ui/input';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { useState } from 'react';\n\n/** Props for the SearchBar component. */\nexport type SearchBarProps = {\n /** Additional css classes to help with unique styling of the search bar */\n className?: string;\n /**\n * Callback fired to handle the search query when button pressed\n *\n * @param searchQuery\n */\n onSearch: (searchQuery: string) => void;\n\n /** Optional string that appears in the search bar without a search string */\n placeholder?: string;\n\n /** Optional boolean to set the input base to full width */\n isFullWidth?: boolean;\n};\n\nexport default function SearchBar({\n className,\n onSearch,\n placeholder,\n isFullWidth,\n}: SearchBarProps) {\n const [searchQuery, setSearchQuery] = useState('');\n\n const handleInputChange = (searchString: string) => {\n setSearchQuery(searchString);\n onSearch(searchString);\n };\n\n return (\n handleInputChange(e.target.value)}\n />\n );\n}\n","// adapted from: https://github.com/shadcn-ui/ui/discussions/752\n\n'use client';\n\nimport { TabsContentProps, TabsListProps, TabsTriggerProps } from '@/components/shadcn-ui/tabs';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport * as TabsPrimitive from '@radix-ui/react-tabs';\nimport React from 'react';\n\nexport type VerticalTabsProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport type LeftTabsTriggerProps = TabsTriggerProps & {\n value: string;\n ref?: React.Ref;\n};\n\nexport const VerticalTabs = React.forwardRef<\n React.ElementRef,\n VerticalTabsProps\n>(({ className, ...props }, ref) => (\n \n));\n\nVerticalTabs.displayName = TabsPrimitive.List.displayName;\n\nexport const VerticalTabsList = React.forwardRef<\n React.ElementRef,\n TabsListProps\n>(({ className, ...props }, ref) => (\n \n));\nVerticalTabsList.displayName = TabsPrimitive.List.displayName;\n\nexport const VerticalTabsTrigger = React.forwardRef<\n React.ElementRef,\n LeftTabsTriggerProps\n>(({ className, ...props }, ref) => (\n \n));\n\nexport const VerticalTabsContent = React.forwardRef<\n React.ElementRef,\n TabsContentProps\n>(({ className, ...props }, ref) => (\n \n));\nVerticalTabsContent.displayName = TabsPrimitive.Content.displayName;\n","import SearchBar from '@/components/basics/search-bar.component';\nimport {\n VerticalTabs,\n VerticalTabsContent,\n VerticalTabsList,\n VerticalTabsTrigger,\n} from '@/components/basics/tabs-vertical';\nimport { ReactNode } from 'react';\n\nexport type TabKeyValueContent = {\n key: string;\n value: string;\n content: ReactNode;\n};\n\nexport type TabNavigationContentSearchProps = {\n /** List of values and keys for each tab this component should provide */\n tabList: TabKeyValueContent[];\n\n /** Handler to run when the value of the search bar changes */\n onSearch: (searchQuery: string) => void;\n\n /** Optional placeholder for the search bar */\n searchPlaceholder?: string;\n\n /** Optional title to include in the header */\n headerTitle?: string;\n\n /** Optional flag to make the search bar appear full width */\n isSearchBarFullWidth?: boolean;\n\n /** Text direction ltr or rtl */\n direction?: 'ltr' | 'rtl';\n};\n\nexport default function TabNavigationContentSearch({\n tabList,\n onSearch,\n searchPlaceholder,\n headerTitle,\n isSearchBarFullWidth = false,\n direction = 'ltr',\n}: TabNavigationContentSearchProps) {\n return (\n
    \n
    \n {headerTitle ?

    {headerTitle}

    : ''}\n \n
    \n \n \n {tabList.map((tab) => (\n \n {tab.value}\n \n ))}\n \n {tabList.map((tab) => (\n \n {tab.content}\n \n ))}\n \n
    \n );\n}\n","import React from 'react';\nimport * as SeparatorPrimitive from '@radix-ui/react-separator';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Separator = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, orientation = 'horizontal', decorative = true, ...props }, ref) => (\n \n));\nSeparator.displayName = SeparatorPrimitive.Root.displayName;\n\nexport { Separator };\n","import React from 'react';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nfunction Skeleton({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\n\nexport { Skeleton };\n","import React from 'react';\nimport * as TooltipPrimitive from '@radix-ui/react-tooltip';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst TooltipProvider = TooltipPrimitive.Provider;\n\nconst Tooltip = TooltipPrimitive.Root;\n\nconst TooltipTrigger = TooltipPrimitive.Trigger;\n\nconst TooltipContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, sideOffset = 4, ...props }, ref) => (\n \n));\nTooltipContent.displayName = TooltipPrimitive.Content.displayName;\n\nexport { Tooltip, TooltipTrigger, TooltipContent, TooltipProvider };\n","import React from 'react';\nimport { Slot } from '@radix-ui/react-slot';\nimport { VariantProps, cva } from 'class-variance-authority';\nimport { PanelLeft } from 'lucide-react';\n\nimport { Button } from '@/components/shadcn-ui/button';\nimport { Input } from '@/components/shadcn-ui/input';\nimport { Separator } from '@/components/shadcn-ui/separator';\nimport { Skeleton } from '@/components/shadcn-ui/skeleton';\nimport {\n Tooltip,\n TooltipContent,\n TooltipProvider,\n TooltipTrigger,\n} from '@/components/shadcn-ui/tooltip';\nimport { cn } from '@/utils/shadcn-ui.util';\n\n/**\n * Changes from the original code from Shadcn- Removed uses of useIsMobile, Sheet, and SheetContent.\n * Also removed the parts setting COOKIES.\n */\n\nconst SIDEBAR_WIDTH = '16rem';\nconst SIDEBAR_WIDTH_ICON = '3rem';\nconst SIDEBAR_KEYBOARD_SHORTCUT = 'b';\n\ntype SidebarContextProps = {\n state: 'expanded' | 'collapsed';\n open: boolean;\n setOpen: (open: boolean) => void;\n toggleSidebar: () => void;\n};\n\nconst SidebarContext = React.createContext(undefined);\n\nfunction useSidebar() {\n const context = React.useContext(SidebarContext);\n if (!context) {\n throw new Error('useSidebar must be used within a SidebarProvider.');\n }\n\n return context;\n}\n\nconst SidebarProvider = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & {\n defaultOpen?: boolean;\n open?: boolean;\n onOpenChange?: (open: boolean) => void;\n }\n>(\n (\n {\n defaultOpen = true,\n open: openProp,\n onOpenChange: setOpenProp,\n className,\n style,\n children,\n ...props\n },\n ref,\n ) => {\n // This is the internal state of the sidebar.\n // We use openProp and setOpenProp for control from outside the component.\n const [_open, _setOpen] = React.useState(defaultOpen);\n const isOpen = openProp ?? _open;\n const setOpen = React.useCallback(\n (value: boolean | ((value: boolean) => boolean)) => {\n const openState = typeof value === 'function' ? value(isOpen) : value;\n if (setOpenProp) {\n setOpenProp(openState);\n } else {\n _setOpen(openState);\n }\n },\n [setOpenProp, isOpen],\n );\n\n // Helper to toggle the sidebar.\n const toggleSidebar = React.useCallback(() => {\n return setOpen((open) => !open);\n }, [setOpen]);\n\n // Adds a keyboard shortcut to toggle the sidebar.\n React.useEffect(() => {\n const handleKeyDown = (event: KeyboardEvent) => {\n if (event.key === SIDEBAR_KEYBOARD_SHORTCUT && (event.metaKey || event.ctrlKey)) {\n event.preventDefault();\n toggleSidebar();\n }\n };\n\n window.addEventListener('keydown', handleKeyDown);\n return () => window.removeEventListener('keydown', handleKeyDown);\n }, [toggleSidebar]);\n\n // We add a state so that we can do data-state=\"expanded\" or \"collapsed\".\n // This makes it easier to style the sidebar with Tailwind classes.\n const state = isOpen ? 'expanded' : 'collapsed';\n\n const contextValue = React.useMemo(\n () => ({\n state,\n open: isOpen,\n setOpen,\n toggleSidebar,\n }),\n [state, isOpen, setOpen, toggleSidebar],\n );\n\n return (\n \n \n \n {children}\n
    \n \n \n );\n },\n);\nSidebarProvider.displayName = 'SidebarProvider';\n\nconst Sidebar = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & {\n side?: 'left' | 'right';\n variant?: 'sidebar' | 'floating' | 'inset';\n collapsible?: 'offcanvas' | 'icon' | 'none';\n }\n>(\n (\n {\n side = 'left',\n variant = 'sidebar',\n collapsible = 'offcanvas',\n className,\n children,\n ...props\n },\n ref,\n ) => {\n const { state } = useSidebar();\n\n if (collapsible === 'none') {\n return (\n \n {children}\n
    \n );\n }\n\n return (\n \n {/* This is what handles the sidebar gap on desktop */}\n \n \n \n {children}\n
    \n
    \n
    \n );\n },\n);\nSidebar.displayName = 'Sidebar';\n\nconst SidebarTrigger = React.forwardRef<\n React.ElementRef,\n React.ComponentProps\n>(({ className, onClick, ...props }, ref) => {\n const { toggleSidebar } = useSidebar();\n\n return (\n {\n onClick?.(event);\n toggleSidebar();\n }}\n {...props}\n >\n \n Toggle Sidebar\n \n );\n});\nSidebarTrigger.displayName = 'SidebarTrigger';\n\nconst SidebarRail = React.forwardRef>(\n ({ className, ...props }, ref) => {\n const { toggleSidebar } = useSidebar();\n\n return (\n \n );\n },\n);\nSidebarRail.displayName = 'SidebarRail';\n\nconst SidebarInset = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarInset.displayName = 'SidebarInset';\n\nconst SidebarInput = React.forwardRef<\n React.ElementRef,\n React.ComponentProps\n>(({ className, ...props }, ref) => {\n return (\n \n );\n});\nSidebarInput.displayName = 'SidebarInput';\n\nconst SidebarHeader = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarHeader.displayName = 'SidebarHeader';\n\nconst SidebarFooter = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarFooter.displayName = 'SidebarFooter';\n\nconst SidebarSeparator = React.forwardRef<\n React.ElementRef,\n React.ComponentProps\n>(({ className, ...props }, ref) => {\n return (\n \n );\n});\nSidebarSeparator.displayName = 'SidebarSeparator';\n\nconst SidebarContent = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarContent.displayName = 'SidebarContent';\n\nconst SidebarGroup = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarGroup.displayName = 'SidebarGroup';\n\nconst SidebarGroupLabel = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & { asChild?: boolean }\n>(({ className, asChild = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'div';\n\n return (\n svg]:tw-size-4 [&>svg]:tw-shrink-0',\n 'group-data-[collapsible=icon]:tw--mt-8 group-data-[collapsible=icon]:tw-opacity-0',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarGroupLabel.displayName = 'SidebarGroupLabel';\n\nconst SidebarGroupAction = React.forwardRef<\n HTMLButtonElement,\n React.ComponentProps<'button'> & { asChild?: boolean }\n>(({ className, asChild = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'button';\n\n return (\n svg]:tw-size-4 [&>svg]:tw-shrink-0',\n // Increases the hit area of the button on mobile.\n 'after:tw-absolute after:tw--inset-2 after:md:tw-hidden',\n 'group-data-[collapsible=icon]:tw-hidden',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarGroupAction.displayName = 'SidebarGroupAction';\n\nconst SidebarGroupContent = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarGroupContent.displayName = 'SidebarGroupContent';\n\nconst SidebarMenu = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenu.displayName = 'SidebarMenu';\n\nconst SidebarMenuItem = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenuItem.displayName = 'SidebarMenuItem';\n\nconst sidebarMenuButtonVariants = cva(\n // Removed data-[active=true]:tw-bg-sidebar-accent\n 'tw-peer/menu-button tw-flex tw-w-full tw-items-center tw-gap-2 tw-overflow-hidden tw-rounded-md tw-p-2 tw-text-left tw-text-sm tw-outline-none tw-ring-sidebar-ring tw-transition-[width,height,padding] hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground focus-visible:tw-ring-2 active:tw-bg-sidebar-accent active:tw-text-sidebar-accent-foreground disabled:tw-pointer-events-none disabled:tw-opacity-50 tw-group-has-[[data-sidebar=menu-action]]/menu-item:pr-8 aria-disabled:tw-pointer-events-none aria-disabled:tw-opacity-50 data-[active=true]:tw-font-medium data-[active=true]:tw-text-sidebar-accent-foreground data-[state=open]:hover:tw-bg-sidebar-accent data-[state=open]:hover:tw-text-sidebar-accent-foreground group-data-[collapsible=icon]:tw-!size-8 group-data-[collapsible=icon]:tw-!p-2 [&>span:last-child]:tw-truncate [&>svg]:tw-size-4 [&>svg]:tw-shrink-0',\n {\n variants: {\n variant: {\n default: 'hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground',\n outline:\n 'tw-bg-background tw-shadow-[0_0_0_1px_hsl(var(--sidebar-border))] hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground hover:tw-shadow-[0_0_0_1px_hsl(var(--sidebar-accent))]',\n },\n size: {\n default: 'tw-h-8 tw-text-sm',\n sm: 'tw-h-7 tw-text-xs',\n lg: 'tw-h-12 tw-text-sm group-data-[collapsible=icon]:tw-!p-0',\n },\n },\n defaultVariants: {\n variant: 'default',\n size: 'default',\n },\n },\n);\n\nconst SidebarMenuButton = React.forwardRef<\n HTMLButtonElement,\n React.ComponentProps<'button'> & {\n asChild?: boolean;\n isActive?: boolean;\n tooltip?: string | React.ComponentProps;\n } & VariantProps\n>(\n (\n {\n asChild = false,\n isActive = false,\n variant = 'default',\n size = 'default',\n tooltip,\n className,\n ...props\n },\n ref,\n ) => {\n const Comp = asChild ? Slot : 'button';\n const { state } = useSidebar();\n\n const button = (\n \n );\n\n if (!tooltip) {\n return button;\n }\n\n if (typeof tooltip === 'string') {\n // eslint-disable-next-line no-param-reassign\n tooltip = {\n children: tooltip,\n };\n }\n\n return (\n \n {button}\n \n );\n },\n);\nSidebarMenuButton.displayName = 'SidebarMenuButton';\n\nconst SidebarMenuAction = React.forwardRef<\n HTMLButtonElement,\n React.ComponentProps<'button'> & {\n asChild?: boolean;\n showOnHover?: boolean;\n }\n>(({ className, asChild = false, showOnHover = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'button';\n\n return (\n svg]:tw-size-4 [&>svg]:tw-shrink-0',\n // Increases the hit area of the button on mobile.\n 'after:tw-absolute after:tw--inset-2 after:md:tw-hidden',\n 'tw-peer-data-[size=sm]/menu-button:top-1',\n 'tw-peer-data-[size=default]/menu-button:top-1.5',\n 'tw-peer-data-[size=lg]/menu-button:top-2.5',\n 'group-data-[collapsible=icon]:tw-hidden',\n showOnHover &&\n 'tw-group-focus-within/menu-item:opacity-100 tw-group-hover/menu-item:opacity-100 tw-peer-data-[active=true]/menu-button:text-sidebar-accent-foreground data-[state=open]:tw-opacity-100 md:tw-opacity-0',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarMenuAction.displayName = 'SidebarMenuAction';\n\nconst SidebarMenuBadge = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenuBadge.displayName = 'SidebarMenuBadge';\n\nconst SidebarMenuSkeleton = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & {\n showIcon?: boolean;\n }\n>(({ className, showIcon = false, ...props }, ref) => {\n // Random width between 50 to 90%.\n const width = React.useMemo(() => {\n return `${Math.floor(Math.random() * 40) + 50}%`;\n }, []);\n\n return (\n \n {showIcon && (\n \n )}\n \n
    \n );\n});\nSidebarMenuSkeleton.displayName = 'SidebarMenuSkeleton';\n\nconst SidebarMenuSub = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenuSub.displayName = 'SidebarMenuSub';\n\nconst SidebarMenuSubItem = React.forwardRef>(\n ({ ...props }, ref) =>
  • ,\n);\nSidebarMenuSubItem.displayName = 'SidebarMenuSubItem';\n\nconst SidebarMenuSubButton = React.forwardRef<\n HTMLAnchorElement,\n React.ComponentProps<'a'> & {\n asChild?: boolean;\n size?: 'sm' | 'md';\n isActive?: boolean;\n }\n>(({ asChild = false, size = 'md', isActive, className, ...props }, ref) => {\n const Comp = asChild ? Slot : 'a';\n\n return (\n span:last-child]:tw-truncate [&>svg]:tw-size-4 [&>svg]:tw-shrink-0 [&>svg]:tw-text-sidebar-accent-foreground',\n 'data-[active=true]:tw-bg-sidebar-accent data-[active=true]:tw-text-sidebar-accent-foreground',\n size === 'sm' && 'tw-text-xs',\n size === 'md' && 'tw-text-sm',\n 'group-data-[collapsible=icon]:tw-hidden',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarMenuSubButton.displayName = 'SidebarMenuSubButton';\n\nexport {\n Sidebar,\n SidebarContent,\n SidebarFooter,\n SidebarGroup,\n SidebarGroupAction,\n SidebarGroupContent,\n SidebarGroupLabel,\n SidebarHeader,\n SidebarInput,\n SidebarInset,\n SidebarMenu,\n SidebarMenuAction,\n SidebarMenuBadge,\n SidebarMenuButton,\n SidebarMenuItem,\n SidebarMenuSkeleton,\n SidebarMenuSub,\n SidebarMenuSubButton,\n SidebarMenuSubItem,\n SidebarProvider,\n SidebarRail,\n SidebarSeparator,\n SidebarTrigger,\n useSidebar,\n};\n","import ComboBox, { ComboBoxOption } from '@/components/basics/combo-box.component';\nimport {\n Sidebar,\n SidebarContent,\n SidebarGroup,\n SidebarGroupLabel,\n SidebarGroupContent,\n SidebarMenu,\n SidebarMenuItem,\n SidebarMenuButton,\n} from '@/components/shadcn-ui/sidebar';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { useCallback } from 'react';\n\nexport type SelectedSettingsSidebarItem = {\n label: string;\n projectId?: string;\n};\n\nexport type ProjectInfo = { projectId: string; projectName: string };\n\nexport type SettingsSidebarProps = {\n /** Optional id for testing */\n id?: string;\n\n /** Extension labels from contribution */\n extensionLabels: string[];\n\n /** Project names and ids */\n projectInfo: ProjectInfo[];\n\n /** Handler for selecting a sidebar item */\n handleSelectSidebarItem: (key: string, projectId?: string) => void;\n\n /** The current selected value in the sidebar */\n selectedSidebarItem: SelectedSettingsSidebarItem;\n\n /** Label for the group of extensions setting groups */\n extensionsSidebarGroupLabel: string;\n\n /** Label for the group of projects settings */\n projectsSidebarGroupLabel: string;\n\n /** Placeholder text for the button */\n buttonPlaceholderText: string;\n};\n\nexport default function SettingsSidebar({\n id,\n extensionLabels,\n projectInfo,\n handleSelectSidebarItem,\n selectedSidebarItem,\n extensionsSidebarGroupLabel,\n projectsSidebarGroupLabel,\n buttonPlaceholderText,\n}: SettingsSidebarProps) {\n const handleSelectItem = useCallback(\n (item: string, projectId?: string) => {\n handleSelectSidebarItem(item, projectId);\n },\n [handleSelectSidebarItem],\n );\n\n const getProjectNameFromProjectId = useCallback(\n (projectId: string) => {\n const project = projectInfo.find((info) => info.projectId === projectId);\n return project ? project.projectName : projectId;\n },\n [projectInfo],\n );\n\n const getIsActive: (label: string) => boolean = useCallback(\n (label: string) => !selectedSidebarItem.projectId && label === selectedSidebarItem.label,\n [selectedSidebarItem],\n );\n\n return (\n \n \n \n \n {extensionsSidebarGroupLabel}\n \n \n \n {extensionLabels.map((label) => (\n \n handleSelectItem(label)}\n isActive={getIsActive(label)}\n >\n {label}\n \n \n ))}\n \n \n \n \n \n {projectsSidebarGroupLabel}\n \n \n info.projectId)}\n getOptionLabel={(projectId: ComboBoxOption) => {\n // This function expects a ComboBoxOption, but we know it is a string\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n return getProjectNameFromProjectId(projectId as string);\n }}\n buttonPlaceholder={buttonPlaceholderText}\n onChange={(projectId: string) => {\n const selectedProjectName = getProjectNameFromProjectId(projectId);\n handleSelectItem(selectedProjectName, projectId);\n }}\n value={selectedSidebarItem?.projectId ?? undefined}\n />\n \n \n \n \n );\n}\n","import { SidebarInset, SidebarProvider } from '@/components/shadcn-ui/sidebar';\nimport { PropsWithChildren } from 'react';\nimport SearchBar from '@/components/basics/search-bar.component';\nimport SettingsSidebar, { SettingsSidebarProps } from './settings-sidebar.component';\n\nexport type SettingsSidebarContentSearchProps = SettingsSidebarProps &\n PropsWithChildren & {\n /** Optional id for testing */\n id?: string;\n\n /** Handler to run when the value of the search bar changes */\n onSearch: (searchQuery: string) => void;\n };\n\nexport default function SettingsSidebarContentSearch({\n id,\n extensionLabels,\n projectInfo,\n children,\n handleSelectSidebarItem,\n selectedSidebarItem,\n onSearch,\n extensionsSidebarGroupLabel,\n projectsSidebarGroupLabel,\n buttonPlaceholderText,\n}: SettingsSidebarContentSearchProps) {\n return (\n
    \n
    \n \n
    \n \n \n {children}\n \n
    \n );\n}\n","import { Button } from '@/components/shadcn-ui/button';\nimport {\n Select,\n SelectContent,\n SelectGroup,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\nimport {\n Table,\n TableBody,\n TableCell,\n TableHead,\n TableHeader,\n TableRow,\n} from '@/components/shadcn-ui/table';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Canon } from '@sillsdev/scripture';\nimport {\n Cell,\n ColumnDef,\n flexRender,\n getCoreRowModel,\n getExpandedRowModel,\n getGroupedRowModel,\n getSortedRowModel,\n GroupingState,\n Row,\n RowSelectionState,\n SortingState,\n useReactTable,\n} from '@tanstack/react-table';\nimport '@/components/advanced/scripture-results-viewer/scripture-results-viewer.component.css';\nimport {\n compareScrRefs,\n formatScrRef,\n ScriptureSelection,\n scrRefToBBBCCCVVV,\n} from 'platform-bible-utils';\nimport { MouseEvent, useEffect, useMemo, useState } from 'react';\nimport { ChevronDown, ChevronLeft, ChevronRight } from 'lucide-react';\n\n/**\n * Information (e.g., a checking error or some other type of \"transient\" annotation) about something\n * noteworthy at a specific place in an instance of the Scriptures.\n */\nexport type ScriptureItemDetail = ScriptureSelection & {\n /**\n * Text of the error, note, etc. In the future, we might want to support something more than just\n * text so that a JSX element could be provided with a link or some other controls related to the\n * issue being reported.\n */\n detail: string;\n};\n\n/**\n * A uniquely identifiable source of results that can be displayed in the ScriptureResultsViewer.\n * Generally, the source will be a particular Scripture check, but there may be other types of\n * sources.\n */\nexport type ResultsSource = {\n /**\n * Uniquely identifies the source.\n *\n * @type {string}\n */\n id: string;\n\n /**\n * Name (potentially localized) of the source, suitable for display in the UI.\n *\n * @type {string}\n */\n displayName: string;\n};\n\nexport type ScriptureSrcItemDetail = ScriptureItemDetail & {\n /** Source/type of detail. Can be used for grouping. */\n source: ResultsSource;\n};\n\n/**\n * Represents a set of results keyed by Scripture reference. Generally, the source will be a\n * particular Scripture check, but this type also allows for other types of uniquely identifiable\n * sources.\n */\nexport type ResultsSet = {\n /**\n * The backing source associated with this set of results.\n *\n * @type {ResultsSource}\n */\n source: ResultsSource;\n\n /**\n * Array of Scripture item details (messages keyed by Scripture reference).\n *\n * @type {ScriptureItemDetail[]}\n */\n data: ScriptureItemDetail[];\n};\n\nconst scrBookColId = 'scrBook';\nconst scrRefColId = 'scrRef';\nconst typeColId = 'source';\nconst detailsColId = 'details';\n\nconst defaultScrRefColumnName = 'Scripture Reference';\nconst defaultScrBookGroupName = 'Scripture Book';\nconst defaultTypeColumnName = 'Type';\nconst defaultDetailsColumnName = 'Details';\n\nexport type ScriptureResultsViewerColumnInfo = {\n /** Optional header to display for the Reference column. Default value: 'Scripture Reference'. */\n scriptureReferenceColumnName?: string;\n\n /** Optional text to display to refer to the Scripture book group. Default value: 'Scripture Book'. */\n scriptureBookGroupName?: string;\n\n /** Optional header to display for the Type column. Default value: 'Type'. */\n typeColumnName?: string;\n\n /** Optional header to display for the Details column. Default value: 'Details' */\n detailsColumnName?: string;\n};\n\nexport type ScriptureResultsViewerProps = ScriptureResultsViewerColumnInfo & {\n /** Groups of ScriptureItemDetail objects from particular sources (e.g., Scripture checks) */\n sources: ResultsSet[];\n\n /** Flag indicating whether to display column headers. Default is false. */\n showColumnHeaders?: boolean;\n\n /** Flag indicating whether to display source column. Default is false. */\n showSourceColumn?: boolean;\n\n /** Callback function to notify when a row is selected */\n onRowSelected?: (selectedRow: ScriptureSrcItemDetail | undefined) => void;\n\n /** Text direction ltr or rtl */\n direction?: 'ltr' | 'rtl';\n};\n\nfunction getColumns(\n colInfo?: ScriptureResultsViewerColumnInfo,\n showSourceColumn?: boolean,\n): ColumnDef[] {\n const showSrcCol = showSourceColumn ?? false;\n return [\n {\n accessorFn: (row) =>\n `${Canon.bookNumberToId(row.start.bookNum)} ${row.start.chapterNum}:${row.start.verseNum}`,\n id: scrBookColId,\n header: colInfo?.scriptureReferenceColumnName ?? defaultScrRefColumnName,\n cell: (info) => {\n const row = info.row.original;\n if (info.row.getIsGrouped()) {\n return Canon.bookNumberToEnglishName(row.start.bookNum);\n }\n return info.row.groupingColumnId === scrBookColId ? formatScrRef(row.start) : undefined;\n },\n getGroupingValue: (row) => row.start.bookNum,\n sortingFn: (a, b) => {\n return compareScrRefs(a.original.start, b.original.start);\n },\n enableGrouping: true,\n },\n {\n accessorFn: (row) => formatScrRef(row.start),\n id: scrRefColId,\n header: undefined,\n cell: (info) => {\n const row = info.row.original;\n return info.row.getIsGrouped() ? undefined : formatScrRef(row.start);\n },\n sortingFn: (a, b) => {\n return compareScrRefs(a.original.start, b.original.start);\n },\n enableGrouping: false,\n },\n {\n accessorFn: (row) => row.source.displayName,\n id: typeColId,\n header: showSrcCol ? (colInfo?.typeColumnName ?? defaultTypeColumnName) : undefined,\n cell: (info) => (showSrcCol || info.row.getIsGrouped() ? info.getValue() : undefined),\n getGroupingValue: (row) => row.source.id,\n sortingFn: (a, b) =>\n a.original.source.displayName.localeCompare(b.original.source.displayName),\n enableGrouping: true,\n },\n {\n accessorFn: (row) => row.detail,\n id: detailsColId,\n header: colInfo?.detailsColumnName ?? defaultDetailsColumnName,\n cell: (info) => info.getValue(),\n enableGrouping: false,\n },\n ];\n}\n\nconst toRefOrRange = (scriptureSelection: ScriptureSelection) => {\n if (!('offset' in scriptureSelection.start))\n throw new Error('No offset available in range start');\n if (scriptureSelection.end && !('offset' in scriptureSelection.end))\n throw new Error('No offset available in range end');\n const { offset: offsetStart } = scriptureSelection.start;\n let offsetEnd: number = 0;\n if (scriptureSelection.end) ({ offset: offsetEnd } = scriptureSelection.end);\n if (\n !scriptureSelection.end ||\n compareScrRefs(scriptureSelection.start, scriptureSelection.end) === 0\n )\n return `${scrRefToBBBCCCVVV(scriptureSelection.start)}+${offsetStart}`;\n return `${scrRefToBBBCCCVVV(scriptureSelection.start)}+${offsetStart}-${scrRefToBBBCCCVVV(scriptureSelection.end)}+${offsetEnd}`;\n};\n\nconst getRowKey = (row: ScriptureSrcItemDetail) =>\n `${toRefOrRange({ start: row.start, end: row.end })} ${row.source.displayName} ${row.detail}`;\n\n/**\n * Component to display a combined list of detailed items from one or more sources, where the items\n * are keyed primarily by Scripture reference. This is particularly useful for displaying a list of\n * results from Scripture checks, but more generally could be used to display any \"results\" from any\n * source(s). The component allows for grouping by Scripture book, source, or both. By default, it\n * displays somewhat \"tree-like\" which allows it to be more horizontally compact and intuitive. But\n * it also has the option of displaying as a traditional table with column headings (with or without\n * the source column showing).\n */\nexport default function ScriptureResultsViewer({\n sources,\n showColumnHeaders = false,\n showSourceColumn = false,\n scriptureReferenceColumnName,\n scriptureBookGroupName,\n typeColumnName,\n detailsColumnName,\n onRowSelected,\n direction = 'ltr',\n}: ScriptureResultsViewerProps) {\n const [grouping, setGrouping] = useState([]);\n const [sorting, setSorting] = useState([{ id: scrBookColId, desc: false }]);\n const [rowSelection, setRowSelection] = useState({});\n\n const scriptureResults = useMemo(\n () =>\n sources.flatMap((source) => {\n return source.data.map((item) => ({\n ...item,\n source: source.source,\n }));\n }),\n [sources],\n );\n\n const columns = useMemo(\n () =>\n getColumns(\n {\n scriptureReferenceColumnName,\n typeColumnName,\n detailsColumnName,\n },\n showSourceColumn,\n ),\n [scriptureReferenceColumnName, typeColumnName, detailsColumnName, showSourceColumn],\n );\n\n useEffect(() => {\n // Ensure sorting is applied correctly when grouped by type\n if (grouping.includes(typeColId)) {\n setSorting([\n { id: typeColId, desc: false },\n { id: scrBookColId, desc: false },\n ]);\n } else {\n setSorting([{ id: scrBookColId, desc: false }]);\n }\n }, [grouping]);\n\n const table = useReactTable({\n data: scriptureResults,\n columns,\n state: {\n grouping,\n sorting,\n rowSelection,\n },\n onGroupingChange: setGrouping,\n onSortingChange: setSorting,\n onRowSelectionChange: setRowSelection,\n getExpandedRowModel: getExpandedRowModel(),\n getGroupedRowModel: getGroupedRowModel(),\n getCoreRowModel: getCoreRowModel(),\n getSortedRowModel: getSortedRowModel(),\n getRowId: getRowKey,\n autoResetExpanded: false,\n enableMultiRowSelection: false,\n enableSubRowSelection: false,\n });\n\n useEffect(() => {\n if (onRowSelected) {\n const selectedRows = table.getSelectedRowModel().rowsById;\n const keys = Object.keys(selectedRows);\n if (keys.length === 1) {\n const selectedRow = scriptureResults.find((row) => getRowKey(row) === keys[0]) || undefined;\n if (selectedRow) onRowSelected(selectedRow);\n }\n }\n }, [rowSelection, scriptureResults, onRowSelected, table]);\n\n // Define possible grouping options\n const scrBookGroupName = scriptureBookGroupName ?? defaultScrBookGroupName;\n const typeGroupName = typeColumnName ?? defaultTypeColumnName;\n\n const groupingOptions = [\n { label: 'No Grouping', value: [] },\n { label: `Group by ${scrBookGroupName}`, value: [scrBookColId] },\n { label: `Group by ${typeGroupName}`, value: [typeColId] },\n {\n label: `Group by ${scrBookGroupName} and ${typeGroupName}`,\n value: [scrBookColId, typeColId],\n },\n {\n label: `Group by ${typeGroupName} and ${scrBookGroupName}`,\n value: [typeColId, scrBookColId],\n },\n ];\n\n const handleSelectChange = (selectedGrouping: string) => {\n setGrouping(JSON.parse(selectedGrouping));\n };\n\n const handleRowClick = (row: Row, event: MouseEvent) => {\n if (!row.getIsGrouped() && !row.getIsSelected()) {\n row.getToggleSelectedHandler()(event);\n }\n };\n\n const getEvenOrOddBandingStyle = (row: Row, index: number) => {\n if (row.getIsGrouped()) return '';\n // UX has now said they don't think they want banding. I'm leaving in the code to\n // set even and odd styles, but there's nothing in the CSS to style them differently.\n // The \"even\" style used to also have tw-bg-neutral-300 (along with even) to create\n // a visual banding effect. That could be added back in if UX changes the decision.\n return cn('banded-row', index % 2 === 0 ? 'even' : 'odd');\n };\n\n const getIndent = (\n groupingState: GroupingState,\n row: Row,\n cell: Cell,\n ) => {\n if (groupingState?.length === 0 || row.depth < cell.column.getGroupedIndex()) return undefined;\n if (row.getIsGrouped()) {\n switch (row.depth) {\n case 1:\n return 'tw-ps-4';\n default:\n return undefined;\n }\n }\n switch (row.depth) {\n case 1:\n return 'tw-ps-8';\n case 2:\n return 'tw-ps-12';\n default:\n return undefined;\n }\n };\n\n return (\n
    \n {!showColumnHeaders && (\n {\n handleSelectChange(value);\n }}\n >\n \n \n \n \n \n {groupingOptions.map((option) => (\n \n {option.label}\n \n ))}\n \n \n \n )}\n \n {showColumnHeaders && (\n \n {table.getHeaderGroups().map((headerGroup) => (\n \n {headerGroup.headers\n .filter((h) => h.column.columnDef.header)\n .map((header) => (\n /* For sticky column headers to work, we probably need to change the default definition of the shadcn Table component. See https://github.com/shadcn-ui/ui/issues/1151 */\n \n {header.isPlaceholder ? undefined : (\n
    \n {header.column.getCanGroup() ? (\n \n {header.column.getIsGrouped() ? `🛑` : `👊 `}\n \n ) : undefined}{' '}\n {flexRender(header.column.columnDef.header, header.getContext())}\n
    \n )}\n
    \n ))}\n
    \n ))}\n
    \n )}\n \n {table.getRowModel().rows.map((row, rowIndex) => {\n return (\n handleRowClick(row, event)}\n >\n {row.getVisibleCells().map((cell) => {\n if (\n cell.getIsPlaceholder() ||\n (cell.column.columnDef.enableGrouping &&\n !cell.getIsGrouped() &&\n (cell.column.columnDef.id !== typeColId || !showSourceColumn))\n )\n return undefined;\n return (\n \n {(() => {\n if (cell.getIsGrouped()) {\n return (\n \n {row.getIsExpanded() && }\n {!row.getIsExpanded() &&\n (direction === 'ltr' ? : )}{' '}\n {flexRender(cell.column.columnDef.cell, cell.getContext())} (\n {row.subRows.length})\n \n );\n }\n\n // if (cell.getIsAggregated()) {\n // flexRender(\n // cell.column.columnDef.aggregatedCell ?? cell.column.columnDef.cell,\n // cell.getContext(),\n // );\n // }\n\n return flexRender(cell.column.columnDef.cell, cell.getContext());\n })()}\n \n );\n })}\n \n );\n })}\n \n
    \n
    \n );\n}\n","import {\n getLocalizeKeyForScrollGroupId,\n LanguageStrings,\n ScrollGroupId,\n} from 'platform-bible-utils';\nimport {\n Select,\n SelectContent,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\n\nconst DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS = {\n [getLocalizeKeyForScrollGroupId('undefined')]: 'Ø',\n [getLocalizeKeyForScrollGroupId(0)]: 'A',\n [getLocalizeKeyForScrollGroupId(1)]: 'B',\n [getLocalizeKeyForScrollGroupId(2)]: 'C',\n [getLocalizeKeyForScrollGroupId(3)]: 'D',\n [getLocalizeKeyForScrollGroupId(4)]: 'E',\n [getLocalizeKeyForScrollGroupId(5)]: 'F',\n [getLocalizeKeyForScrollGroupId(6)]: 'G',\n [getLocalizeKeyForScrollGroupId(7)]: 'H',\n [getLocalizeKeyForScrollGroupId(8)]: 'I',\n [getLocalizeKeyForScrollGroupId(9)]: 'J',\n [getLocalizeKeyForScrollGroupId(10)]: 'K',\n [getLocalizeKeyForScrollGroupId(11)]: 'L',\n [getLocalizeKeyForScrollGroupId(12)]: 'M',\n [getLocalizeKeyForScrollGroupId(13)]: 'N',\n [getLocalizeKeyForScrollGroupId(14)]: 'O',\n [getLocalizeKeyForScrollGroupId(15)]: 'P',\n [getLocalizeKeyForScrollGroupId(16)]: 'Q',\n [getLocalizeKeyForScrollGroupId(17)]: 'R',\n [getLocalizeKeyForScrollGroupId(18)]: 'S',\n [getLocalizeKeyForScrollGroupId(19)]: 'T',\n [getLocalizeKeyForScrollGroupId(20)]: 'U',\n [getLocalizeKeyForScrollGroupId(21)]: 'V',\n [getLocalizeKeyForScrollGroupId(22)]: 'W',\n [getLocalizeKeyForScrollGroupId(23)]: 'X',\n [getLocalizeKeyForScrollGroupId(24)]: 'Y',\n [getLocalizeKeyForScrollGroupId(25)]: 'Z',\n};\n\nexport type ScrollGroupSelectorProps = {\n /**\n * List of scroll group ids to show to the user. Either a {@link ScrollGroupId} or `undefined` for\n * no scroll group\n */\n availableScrollGroupIds: (ScrollGroupId | undefined)[];\n /** Currently selected scroll group id. `undefined` for no scroll group */\n scrollGroupId: ScrollGroupId | undefined;\n /** Callback function run when the user tries to change the scroll group id */\n onChangeScrollGroupId: (newScrollGroupId: ScrollGroupId | undefined) => void;\n /**\n * Localized strings to use for displaying scroll group ids. Must be an object whose keys are\n * `getLocalizeKeyForScrollGroupId(scrollGroupId)` for all scroll group ids (and `undefined` if\n * included) in {@link ScrollGroupSelectorProps.availableScrollGroupIds} and whose values are the\n * localized strings to use for those scroll group ids.\n *\n * Defaults to English localizations of English alphabet for scroll groups 0-25 (e.g. 0 is A) and\n * Ø for `undefined`. Will fill in any that are not provided with these English localizations.\n * Also, if any values match the keys, the English localization will be used. This is useful in\n * case you want to pass in a temporary version of the localized strings while your localized\n * strings load.\n *\n * @example\n *\n * ```typescript\n * const myScrollGroupIdLocalizedStrings = {\n * [getLocalizeKeyForScrollGroupId('undefined')]: 'Ø',\n * [getLocalizeKeyForScrollGroupId(0)]: 'A',\n * [getLocalizeKeyForScrollGroupId(1)]: 'B',\n * [getLocalizeKeyForScrollGroupId(2)]: 'C',\n * [getLocalizeKeyForScrollGroupId(3)]: 'D',\n * [getLocalizeKeyForScrollGroupId(4)]: 'E',\n * };\n * ```\n *\n * @example\n *\n * ```tsx\n * const availableScrollGroupIds = [undefined, 0, 1, 2, 3, 4];\n *\n * const localizeKeys = getLocalizeKeysForScrollGroupIds();\n *\n * const [localizedStrings] = useLocalizedStrings(localizeKeys);\n *\n * ...\n *\n * \n * ```\n */\n localizedStrings?: LanguageStrings;\n};\n\n/** Selector component for choosing a scroll group */\nexport default function ScrollGroupSelector({\n availableScrollGroupIds,\n scrollGroupId,\n onChangeScrollGroupId,\n localizedStrings = {},\n}: ScrollGroupSelectorProps) {\n const localizedStringsDefaulted = {\n ...DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS,\n ...Object.fromEntries(\n Object.entries(localizedStrings).map(\n ([localizedStringKey, localizedStringValue]: [string, string]) => [\n localizedStringKey,\n localizedStringKey === localizedStringValue &&\n localizedStringKey in DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS\n ? DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS[localizedStringKey]\n : localizedStringValue,\n ],\n ),\n ),\n };\n return (\n \n onChangeScrollGroupId(\n newScrollGroupString === 'undefined' ? undefined : parseInt(newScrollGroupString, 10),\n )\n }\n >\n \n \n \n \n {availableScrollGroupIds.map((scrollGroupOptionId) => (\n \n {localizedStringsDefaulted[getLocalizeKeyForScrollGroupId(scrollGroupOptionId)]}\n \n ))}\n \n \n );\n}\n","import { PropsWithChildren } from 'react';\nimport { Separator } from '@/components/shadcn-ui/separator';\n\n/** Props for the SettingsList component, currently just children */\ntype SettingsListProps = PropsWithChildren;\n\n/**\n * SettingsList component is a wrapper for list items. Rendered with a formatted div\n *\n * @param children To populate the list with\n * @returns Formatted div encompassing the children\n */\nexport function SettingsList({ children }: SettingsListProps) {\n return
    {children}
    ;\n}\n\n/** Props for SettingsListItem component */\ntype SettingsListItemProps = PropsWithChildren & {\n /** Primary text of the list item */\n primary: string;\n\n /** Optional text of the list item */\n secondary?: string | undefined;\n\n /** Optional boolean to display a message if the children aren't loaded yet. Defaults to false */\n isLoading?: boolean;\n\n /** Optional message to display if isLoading */\n loadingMessage?: string;\n};\n\n/**\n * SettingsListItem component is a common list item. Rendered with a formatted div\n *\n * @param primary Primary text of the list item\n * @param secondary Optional secondary text of the list item\n * @param isLoading Optional, to display a message if the action component isn't generated yet,\n * defaults to false\n * @param children The action component(s) to provide for this item\n * @param loadingMessage Optional, message to display if isLoading\n * @returns Formatted div encompassing the list item content\n */\nexport function SettingsListItem({\n primary,\n secondary,\n children,\n isLoading = false,\n loadingMessage,\n}: SettingsListItemProps) {\n return (\n
    \n
    \n

    {primary}

    \n

    \n {secondary}\n

    \n
    \n\n {isLoading ? (\n

    {loadingMessage}

    \n ) : (\n
    {children}
    \n )}\n
    \n );\n}\n\n/** Props for SettingsListHeader component */\ntype SettingsListHeaderProps = {\n /** The primary text of the list header */\n primary: string;\n\n /** Optional secondary text of the list header */\n secondary?: string | undefined;\n\n /** Optional boolean to include a separator underneath the secondary text. Defaults to false */\n includeSeparator?: boolean;\n};\n\n/**\n * SettingsListHeader component displays text above the list\n *\n * @param primary The primary text of the list header\n * @param secondary Optional secondary text of the list header\n * @param includeSeparator Optional boolean to include a separator underneath the secondary text.\n * Defaults to false\n * @returns Formatted div with list header content\n */\nexport function SettingsListHeader({\n primary,\n secondary,\n includeSeparator = false,\n}: SettingsListHeaderProps) {\n return (\n
    \n
    \n

    {primary}

    \n

    {secondary}

    \n
    \n {includeSeparator ? : ''}\n
    \n );\n}\n","import Checkbox from '@/components/shadcn-ui/checkbox';\nimport { Label } from '@/components/shadcn-ui/label';\n\nexport type ChecklistProps = {\n /** Optional string representing the id attribute of the Checklist */\n id?: string;\n /** Optional string representing CSS class name(s) for styling */\n className?: string;\n /** Array of strings representing the checkable items */\n listItems: string[];\n /** Array of strings representing the checked items */\n selectedListItems: string[];\n /**\n * Function that is called when a checkbox item is selected or deselected\n *\n * @param item The string description for this item\n * @param selected True if selected, false if not selected\n */\n handleSelectListItem: (item: string, selected: boolean) => void;\n\n /**\n * Optional function creates a label for a provided checkable item\n *\n * @param item The item for which a label is to be created\n * @returns A string representing the label text for the checkbox associated with that item\n */\n createLabel?: (item: string) => string;\n};\n\n/** Renders a list of checkboxes. Each checkbox corresponds to an item from the `listItems` array. */\nexport default function Checklist({\n id,\n className,\n listItems,\n selectedListItems,\n handleSelectListItem,\n createLabel,\n}: ChecklistProps) {\n return (\n
    \n {listItems.map((item) => (\n
    \n handleSelectListItem(item, value)}\n />\n \n
    \n ))}\n
    \n );\n}\n","function _interopRequireDefault(obj) {\n return obj && obj.__esModule ? obj : {\n \"default\": obj\n };\n}\nmodule.exports = _interopRequireDefault, module.exports.__esModule = true, module.exports[\"default\"] = module.exports;","export default function chainPropTypes(propType1, propType2) {\n if (process.env.NODE_ENV === 'production') {\n return () => null;\n }\n return function validate(...args) {\n return propType1(...args) || propType2(...args);\n };\n}","export default function _extends() {\n _extends = Object.assign ? Object.assign.bind() : function (target) {\n for (var i = 1; i < arguments.length; i++) {\n var source = arguments[i];\n for (var key in source) {\n if (Object.prototype.hasOwnProperty.call(source, key)) {\n target[key] = source[key];\n }\n }\n }\n return target;\n };\n return _extends.apply(this, arguments);\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\n// https://github.com/sindresorhus/is-plain-obj/blob/main/index.js\nexport function isPlainObject(item) {\n if (typeof item !== 'object' || item === null) {\n return false;\n }\n const prototype = Object.getPrototypeOf(item);\n return (prototype === null || prototype === Object.prototype || Object.getPrototypeOf(prototype) === null) && !(Symbol.toStringTag in item) && !(Symbol.iterator in item);\n}\nfunction deepClone(source) {\n if (!isPlainObject(source)) {\n return source;\n }\n const output = {};\n Object.keys(source).forEach(key => {\n output[key] = deepClone(source[key]);\n });\n return output;\n}\nexport default function deepmerge(target, source, options = {\n clone: true\n}) {\n const output = options.clone ? _extends({}, target) : target;\n if (isPlainObject(target) && isPlainObject(source)) {\n Object.keys(source).forEach(key => {\n // Avoid prototype pollution\n if (key === '__proto__') {\n return;\n }\n if (isPlainObject(source[key]) && key in target && isPlainObject(target[key])) {\n // Since `output` is a clone of `target` and we have narrowed `target` in this block we can cast to the same type.\n output[key] = deepmerge(target[key], source[key], options);\n } else if (options.clone) {\n output[key] = isPlainObject(source[key]) ? deepClone(source[key]) : source[key];\n } else {\n output[key] = source[key];\n }\n });\n }\n return output;\n}","/** @license React v16.13.1\n * react-is.production.min.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';var b=\"function\"===typeof Symbol&&Symbol.for,c=b?Symbol.for(\"react.element\"):60103,d=b?Symbol.for(\"react.portal\"):60106,e=b?Symbol.for(\"react.fragment\"):60107,f=b?Symbol.for(\"react.strict_mode\"):60108,g=b?Symbol.for(\"react.profiler\"):60114,h=b?Symbol.for(\"react.provider\"):60109,k=b?Symbol.for(\"react.context\"):60110,l=b?Symbol.for(\"react.async_mode\"):60111,m=b?Symbol.for(\"react.concurrent_mode\"):60111,n=b?Symbol.for(\"react.forward_ref\"):60112,p=b?Symbol.for(\"react.suspense\"):60113,q=b?\nSymbol.for(\"react.suspense_list\"):60120,r=b?Symbol.for(\"react.memo\"):60115,t=b?Symbol.for(\"react.lazy\"):60116,v=b?Symbol.for(\"react.block\"):60121,w=b?Symbol.for(\"react.fundamental\"):60117,x=b?Symbol.for(\"react.responder\"):60118,y=b?Symbol.for(\"react.scope\"):60119;\nfunction z(a){if(\"object\"===typeof a&&null!==a){var u=a.$$typeof;switch(u){case c:switch(a=a.type,a){case l:case m:case e:case g:case f:case p:return a;default:switch(a=a&&a.$$typeof,a){case k:case n:case t:case r:case h:return a;default:return u}}case d:return u}}}function A(a){return z(a)===m}exports.AsyncMode=l;exports.ConcurrentMode=m;exports.ContextConsumer=k;exports.ContextProvider=h;exports.Element=c;exports.ForwardRef=n;exports.Fragment=e;exports.Lazy=t;exports.Memo=r;exports.Portal=d;\nexports.Profiler=g;exports.StrictMode=f;exports.Suspense=p;exports.isAsyncMode=function(a){return A(a)||z(a)===l};exports.isConcurrentMode=A;exports.isContextConsumer=function(a){return z(a)===k};exports.isContextProvider=function(a){return z(a)===h};exports.isElement=function(a){return\"object\"===typeof a&&null!==a&&a.$$typeof===c};exports.isForwardRef=function(a){return z(a)===n};exports.isFragment=function(a){return z(a)===e};exports.isLazy=function(a){return z(a)===t};\nexports.isMemo=function(a){return z(a)===r};exports.isPortal=function(a){return z(a)===d};exports.isProfiler=function(a){return z(a)===g};exports.isStrictMode=function(a){return z(a)===f};exports.isSuspense=function(a){return z(a)===p};\nexports.isValidElementType=function(a){return\"string\"===typeof a||\"function\"===typeof a||a===e||a===m||a===g||a===f||a===p||a===q||\"object\"===typeof a&&null!==a&&(a.$$typeof===t||a.$$typeof===r||a.$$typeof===h||a.$$typeof===k||a.$$typeof===n||a.$$typeof===w||a.$$typeof===x||a.$$typeof===y||a.$$typeof===v)};exports.typeOf=z;\n","/** @license React v16.13.1\n * react-is.development.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\n\n\nif (process.env.NODE_ENV !== \"production\") {\n (function() {\n'use strict';\n\n// The Symbol used to tag the ReactElement-like types. If there is no native Symbol\n// nor polyfill, then a plain number is used for performance.\nvar hasSymbol = typeof Symbol === 'function' && Symbol.for;\nvar REACT_ELEMENT_TYPE = hasSymbol ? Symbol.for('react.element') : 0xeac7;\nvar REACT_PORTAL_TYPE = hasSymbol ? Symbol.for('react.portal') : 0xeaca;\nvar REACT_FRAGMENT_TYPE = hasSymbol ? Symbol.for('react.fragment') : 0xeacb;\nvar REACT_STRICT_MODE_TYPE = hasSymbol ? Symbol.for('react.strict_mode') : 0xeacc;\nvar REACT_PROFILER_TYPE = hasSymbol ? Symbol.for('react.profiler') : 0xead2;\nvar REACT_PROVIDER_TYPE = hasSymbol ? Symbol.for('react.provider') : 0xeacd;\nvar REACT_CONTEXT_TYPE = hasSymbol ? Symbol.for('react.context') : 0xeace; // TODO: We don't use AsyncMode or ConcurrentMode anymore. They were temporary\n// (unstable) APIs that have been removed. Can we remove the symbols?\n\nvar REACT_ASYNC_MODE_TYPE = hasSymbol ? Symbol.for('react.async_mode') : 0xeacf;\nvar REACT_CONCURRENT_MODE_TYPE = hasSymbol ? Symbol.for('react.concurrent_mode') : 0xeacf;\nvar REACT_FORWARD_REF_TYPE = hasSymbol ? Symbol.for('react.forward_ref') : 0xead0;\nvar REACT_SUSPENSE_TYPE = hasSymbol ? Symbol.for('react.suspense') : 0xead1;\nvar REACT_SUSPENSE_LIST_TYPE = hasSymbol ? Symbol.for('react.suspense_list') : 0xead8;\nvar REACT_MEMO_TYPE = hasSymbol ? Symbol.for('react.memo') : 0xead3;\nvar REACT_LAZY_TYPE = hasSymbol ? Symbol.for('react.lazy') : 0xead4;\nvar REACT_BLOCK_TYPE = hasSymbol ? Symbol.for('react.block') : 0xead9;\nvar REACT_FUNDAMENTAL_TYPE = hasSymbol ? Symbol.for('react.fundamental') : 0xead5;\nvar REACT_RESPONDER_TYPE = hasSymbol ? Symbol.for('react.responder') : 0xead6;\nvar REACT_SCOPE_TYPE = hasSymbol ? Symbol.for('react.scope') : 0xead7;\n\nfunction isValidElementType(type) {\n return typeof type === 'string' || typeof type === 'function' || // Note: its typeof might be other than 'symbol' or 'number' if it's a polyfill.\n type === REACT_FRAGMENT_TYPE || type === REACT_CONCURRENT_MODE_TYPE || type === REACT_PROFILER_TYPE || type === REACT_STRICT_MODE_TYPE || type === REACT_SUSPENSE_TYPE || type === REACT_SUSPENSE_LIST_TYPE || typeof type === 'object' && type !== null && (type.$$typeof === REACT_LAZY_TYPE || type.$$typeof === REACT_MEMO_TYPE || type.$$typeof === REACT_PROVIDER_TYPE || type.$$typeof === REACT_CONTEXT_TYPE || type.$$typeof === REACT_FORWARD_REF_TYPE || type.$$typeof === REACT_FUNDAMENTAL_TYPE || type.$$typeof === REACT_RESPONDER_TYPE || type.$$typeof === REACT_SCOPE_TYPE || type.$$typeof === REACT_BLOCK_TYPE);\n}\n\nfunction typeOf(object) {\n if (typeof object === 'object' && object !== null) {\n var $$typeof = object.$$typeof;\n\n switch ($$typeof) {\n case REACT_ELEMENT_TYPE:\n var type = object.type;\n\n switch (type) {\n case REACT_ASYNC_MODE_TYPE:\n case REACT_CONCURRENT_MODE_TYPE:\n case REACT_FRAGMENT_TYPE:\n case REACT_PROFILER_TYPE:\n case REACT_STRICT_MODE_TYPE:\n case REACT_SUSPENSE_TYPE:\n return type;\n\n default:\n var $$typeofType = type && type.$$typeof;\n\n switch ($$typeofType) {\n case REACT_CONTEXT_TYPE:\n case REACT_FORWARD_REF_TYPE:\n case REACT_LAZY_TYPE:\n case REACT_MEMO_TYPE:\n case REACT_PROVIDER_TYPE:\n return $$typeofType;\n\n default:\n return $$typeof;\n }\n\n }\n\n case REACT_PORTAL_TYPE:\n return $$typeof;\n }\n }\n\n return undefined;\n} // AsyncMode is deprecated along with isAsyncMode\n\nvar AsyncMode = REACT_ASYNC_MODE_TYPE;\nvar ConcurrentMode = REACT_CONCURRENT_MODE_TYPE;\nvar ContextConsumer = REACT_CONTEXT_TYPE;\nvar ContextProvider = REACT_PROVIDER_TYPE;\nvar Element = REACT_ELEMENT_TYPE;\nvar ForwardRef = REACT_FORWARD_REF_TYPE;\nvar Fragment = REACT_FRAGMENT_TYPE;\nvar Lazy = REACT_LAZY_TYPE;\nvar Memo = REACT_MEMO_TYPE;\nvar Portal = REACT_PORTAL_TYPE;\nvar Profiler = REACT_PROFILER_TYPE;\nvar StrictMode = REACT_STRICT_MODE_TYPE;\nvar Suspense = REACT_SUSPENSE_TYPE;\nvar hasWarnedAboutDeprecatedIsAsyncMode = false; // AsyncMode should be deprecated\n\nfunction isAsyncMode(object) {\n {\n if (!hasWarnedAboutDeprecatedIsAsyncMode) {\n hasWarnedAboutDeprecatedIsAsyncMode = true; // Using console['warn'] to evade Babel and ESLint\n\n console['warn']('The ReactIs.isAsyncMode() alias has been deprecated, ' + 'and will be removed in React 17+. Update your code to use ' + 'ReactIs.isConcurrentMode() instead. It has the exact same API.');\n }\n }\n\n return isConcurrentMode(object) || typeOf(object) === REACT_ASYNC_MODE_TYPE;\n}\nfunction isConcurrentMode(object) {\n return typeOf(object) === REACT_CONCURRENT_MODE_TYPE;\n}\nfunction isContextConsumer(object) {\n return typeOf(object) === REACT_CONTEXT_TYPE;\n}\nfunction isContextProvider(object) {\n return typeOf(object) === REACT_PROVIDER_TYPE;\n}\nfunction isElement(object) {\n return typeof object === 'object' && object !== null && object.$$typeof === REACT_ELEMENT_TYPE;\n}\nfunction isForwardRef(object) {\n return typeOf(object) === REACT_FORWARD_REF_TYPE;\n}\nfunction isFragment(object) {\n return typeOf(object) === REACT_FRAGMENT_TYPE;\n}\nfunction isLazy(object) {\n return typeOf(object) === REACT_LAZY_TYPE;\n}\nfunction isMemo(object) {\n return typeOf(object) === REACT_MEMO_TYPE;\n}\nfunction isPortal(object) {\n return typeOf(object) === REACT_PORTAL_TYPE;\n}\nfunction isProfiler(object) {\n return typeOf(object) === REACT_PROFILER_TYPE;\n}\nfunction isStrictMode(object) {\n return typeOf(object) === REACT_STRICT_MODE_TYPE;\n}\nfunction isSuspense(object) {\n return typeOf(object) === REACT_SUSPENSE_TYPE;\n}\n\nexports.AsyncMode = AsyncMode;\nexports.ConcurrentMode = ConcurrentMode;\nexports.ContextConsumer = ContextConsumer;\nexports.ContextProvider = ContextProvider;\nexports.Element = Element;\nexports.ForwardRef = ForwardRef;\nexports.Fragment = Fragment;\nexports.Lazy = Lazy;\nexports.Memo = Memo;\nexports.Portal = Portal;\nexports.Profiler = Profiler;\nexports.StrictMode = StrictMode;\nexports.Suspense = Suspense;\nexports.isAsyncMode = isAsyncMode;\nexports.isConcurrentMode = isConcurrentMode;\nexports.isContextConsumer = isContextConsumer;\nexports.isContextProvider = isContextProvider;\nexports.isElement = isElement;\nexports.isForwardRef = isForwardRef;\nexports.isFragment = isFragment;\nexports.isLazy = isLazy;\nexports.isMemo = isMemo;\nexports.isPortal = isPortal;\nexports.isProfiler = isProfiler;\nexports.isStrictMode = isStrictMode;\nexports.isSuspense = isSuspense;\nexports.isValidElementType = isValidElementType;\nexports.typeOf = typeOf;\n })();\n}\n","'use strict';\n\nif (process.env.NODE_ENV === 'production') {\n module.exports = require('./cjs/react-is.production.min.js');\n} else {\n module.exports = require('./cjs/react-is.development.js');\n}\n","/*\nobject-assign\n(c) Sindre Sorhus\n@license MIT\n*/\n\n'use strict';\n/* eslint-disable no-unused-vars */\nvar getOwnPropertySymbols = Object.getOwnPropertySymbols;\nvar hasOwnProperty = Object.prototype.hasOwnProperty;\nvar propIsEnumerable = Object.prototype.propertyIsEnumerable;\n\nfunction toObject(val) {\n\tif (val === null || val === undefined) {\n\t\tthrow new TypeError('Object.assign cannot be called with null or undefined');\n\t}\n\n\treturn Object(val);\n}\n\nfunction shouldUseNative() {\n\ttry {\n\t\tif (!Object.assign) {\n\t\t\treturn false;\n\t\t}\n\n\t\t// Detect buggy property enumeration order in older V8 versions.\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=4118\n\t\tvar test1 = new String('abc'); // eslint-disable-line no-new-wrappers\n\t\ttest1[5] = 'de';\n\t\tif (Object.getOwnPropertyNames(test1)[0] === '5') {\n\t\t\treturn false;\n\t\t}\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=3056\n\t\tvar test2 = {};\n\t\tfor (var i = 0; i < 10; i++) {\n\t\t\ttest2['_' + String.fromCharCode(i)] = i;\n\t\t}\n\t\tvar order2 = Object.getOwnPropertyNames(test2).map(function (n) {\n\t\t\treturn test2[n];\n\t\t});\n\t\tif (order2.join('') !== '0123456789') {\n\t\t\treturn false;\n\t\t}\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=3056\n\t\tvar test3 = {};\n\t\t'abcdefghijklmnopqrst'.split('').forEach(function (letter) {\n\t\t\ttest3[letter] = letter;\n\t\t});\n\t\tif (Object.keys(Object.assign({}, test3)).join('') !==\n\t\t\t\t'abcdefghijklmnopqrst') {\n\t\t\treturn false;\n\t\t}\n\n\t\treturn true;\n\t} catch (err) {\n\t\t// We don't expect any of the above to throw, but better to be safe.\n\t\treturn false;\n\t}\n}\n\nmodule.exports = shouldUseNative() ? Object.assign : function (target, source) {\n\tvar from;\n\tvar to = toObject(target);\n\tvar symbols;\n\n\tfor (var s = 1; s < arguments.length; s++) {\n\t\tfrom = Object(arguments[s]);\n\n\t\tfor (var key in from) {\n\t\t\tif (hasOwnProperty.call(from, key)) {\n\t\t\t\tto[key] = from[key];\n\t\t\t}\n\t\t}\n\n\t\tif (getOwnPropertySymbols) {\n\t\t\tsymbols = getOwnPropertySymbols(from);\n\t\t\tfor (var i = 0; i < symbols.length; i++) {\n\t\t\t\tif (propIsEnumerable.call(from, symbols[i])) {\n\t\t\t\t\tto[symbols[i]] = from[symbols[i]];\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\n\treturn to;\n};\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar ReactPropTypesSecret = 'SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED';\n\nmodule.exports = ReactPropTypesSecret;\n","module.exports = Function.call.bind(Object.prototype.hasOwnProperty);\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar printWarning = function() {};\n\nif (process.env.NODE_ENV !== 'production') {\n var ReactPropTypesSecret = require('./lib/ReactPropTypesSecret');\n var loggedTypeFailures = {};\n var has = require('./lib/has');\n\n printWarning = function(text) {\n var message = 'Warning: ' + text;\n if (typeof console !== 'undefined') {\n console.error(message);\n }\n try {\n // --- Welcome to debugging React ---\n // This error was thrown as a convenience so that you can use this stack\n // to find the callsite that caused this warning to fire.\n throw new Error(message);\n } catch (x) { /**/ }\n };\n}\n\n/**\n * Assert that the values match with the type specs.\n * Error messages are memorized and will only be shown once.\n *\n * @param {object} typeSpecs Map of name to a ReactPropType\n * @param {object} values Runtime values that need to be type-checked\n * @param {string} location e.g. \"prop\", \"context\", \"child context\"\n * @param {string} componentName Name of the component for error messages.\n * @param {?Function} getStack Returns the component stack.\n * @private\n */\nfunction checkPropTypes(typeSpecs, values, location, componentName, getStack) {\n if (process.env.NODE_ENV !== 'production') {\n for (var typeSpecName in typeSpecs) {\n if (has(typeSpecs, typeSpecName)) {\n var error;\n // Prop type validation may throw. In case they do, we don't want to\n // fail the render phase where it didn't fail before. So we log it.\n // After these have been cleaned up, we'll let them throw.\n try {\n // This is intentionally an invariant that gets caught. It's the same\n // behavior as without this statement except with a better message.\n if (typeof typeSpecs[typeSpecName] !== 'function') {\n var err = Error(\n (componentName || 'React class') + ': ' + location + ' type `' + typeSpecName + '` is invalid; ' +\n 'it must be a function, usually from the `prop-types` package, but received `' + typeof typeSpecs[typeSpecName] + '`.' +\n 'This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.'\n );\n err.name = 'Invariant Violation';\n throw err;\n }\n error = typeSpecs[typeSpecName](values, typeSpecName, componentName, location, null, ReactPropTypesSecret);\n } catch (ex) {\n error = ex;\n }\n if (error && !(error instanceof Error)) {\n printWarning(\n (componentName || 'React class') + ': type specification of ' +\n location + ' `' + typeSpecName + '` is invalid; the type checker ' +\n 'function must return `null` or an `Error` but returned a ' + typeof error + '. ' +\n 'You may have forgotten to pass an argument to the type checker ' +\n 'creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and ' +\n 'shape all require an argument).'\n );\n }\n if (error instanceof Error && !(error.message in loggedTypeFailures)) {\n // Only monitor this failure once because there tends to be a lot of the\n // same error.\n loggedTypeFailures[error.message] = true;\n\n var stack = getStack ? getStack() : '';\n\n printWarning(\n 'Failed ' + location + ' type: ' + error.message + (stack != null ? stack : '')\n );\n }\n }\n }\n }\n}\n\n/**\n * Resets warning cache when testing.\n *\n * @private\n */\ncheckPropTypes.resetWarningCache = function() {\n if (process.env.NODE_ENV !== 'production') {\n loggedTypeFailures = {};\n }\n}\n\nmodule.exports = checkPropTypes;\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar ReactIs = require('react-is');\nvar assign = require('object-assign');\n\nvar ReactPropTypesSecret = require('./lib/ReactPropTypesSecret');\nvar has = require('./lib/has');\nvar checkPropTypes = require('./checkPropTypes');\n\nvar printWarning = function() {};\n\nif (process.env.NODE_ENV !== 'production') {\n printWarning = function(text) {\n var message = 'Warning: ' + text;\n if (typeof console !== 'undefined') {\n console.error(message);\n }\n try {\n // --- Welcome to debugging React ---\n // This error was thrown as a convenience so that you can use this stack\n // to find the callsite that caused this warning to fire.\n throw new Error(message);\n } catch (x) {}\n };\n}\n\nfunction emptyFunctionThatReturnsNull() {\n return null;\n}\n\nmodule.exports = function(isValidElement, throwOnDirectAccess) {\n /* global Symbol */\n var ITERATOR_SYMBOL = typeof Symbol === 'function' && Symbol.iterator;\n var FAUX_ITERATOR_SYMBOL = '@@iterator'; // Before Symbol spec.\n\n /**\n * Returns the iterator method function contained on the iterable object.\n *\n * Be sure to invoke the function with the iterable as context:\n *\n * var iteratorFn = getIteratorFn(myIterable);\n * if (iteratorFn) {\n * var iterator = iteratorFn.call(myIterable);\n * ...\n * }\n *\n * @param {?object} maybeIterable\n * @return {?function}\n */\n function getIteratorFn(maybeIterable) {\n var iteratorFn = maybeIterable && (ITERATOR_SYMBOL && maybeIterable[ITERATOR_SYMBOL] || maybeIterable[FAUX_ITERATOR_SYMBOL]);\n if (typeof iteratorFn === 'function') {\n return iteratorFn;\n }\n }\n\n /**\n * Collection of methods that allow declaration and validation of props that are\n * supplied to React components. Example usage:\n *\n * var Props = require('ReactPropTypes');\n * var MyArticle = React.createClass({\n * propTypes: {\n * // An optional string prop named \"description\".\n * description: Props.string,\n *\n * // A required enum prop named \"category\".\n * category: Props.oneOf(['News','Photos']).isRequired,\n *\n * // A prop named \"dialog\" that requires an instance of Dialog.\n * dialog: Props.instanceOf(Dialog).isRequired\n * },\n * render: function() { ... }\n * });\n *\n * A more formal specification of how these methods are used:\n *\n * type := array|bool|func|object|number|string|oneOf([...])|instanceOf(...)\n * decl := ReactPropTypes.{type}(.isRequired)?\n *\n * Each and every declaration produces a function with the same signature. This\n * allows the creation of custom validation functions. For example:\n *\n * var MyLink = React.createClass({\n * propTypes: {\n * // An optional string or URI prop named \"href\".\n * href: function(props, propName, componentName) {\n * var propValue = props[propName];\n * if (propValue != null && typeof propValue !== 'string' &&\n * !(propValue instanceof URI)) {\n * return new Error(\n * 'Expected a string or an URI for ' + propName + ' in ' +\n * componentName\n * );\n * }\n * }\n * },\n * render: function() {...}\n * });\n *\n * @internal\n */\n\n var ANONYMOUS = '<>';\n\n // Important!\n // Keep this list in sync with production version in `./factoryWithThrowingShims.js`.\n var ReactPropTypes = {\n array: createPrimitiveTypeChecker('array'),\n bigint: createPrimitiveTypeChecker('bigint'),\n bool: createPrimitiveTypeChecker('boolean'),\n func: createPrimitiveTypeChecker('function'),\n number: createPrimitiveTypeChecker('number'),\n object: createPrimitiveTypeChecker('object'),\n string: createPrimitiveTypeChecker('string'),\n symbol: createPrimitiveTypeChecker('symbol'),\n\n any: createAnyTypeChecker(),\n arrayOf: createArrayOfTypeChecker,\n element: createElementTypeChecker(),\n elementType: createElementTypeTypeChecker(),\n instanceOf: createInstanceTypeChecker,\n node: createNodeChecker(),\n objectOf: createObjectOfTypeChecker,\n oneOf: createEnumTypeChecker,\n oneOfType: createUnionTypeChecker,\n shape: createShapeTypeChecker,\n exact: createStrictShapeTypeChecker,\n };\n\n /**\n * inlined Object.is polyfill to avoid requiring consumers ship their own\n * https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object/is\n */\n /*eslint-disable no-self-compare*/\n function is(x, y) {\n // SameValue algorithm\n if (x === y) {\n // Steps 1-5, 7-10\n // Steps 6.b-6.e: +0 != -0\n return x !== 0 || 1 / x === 1 / y;\n } else {\n // Step 6.a: NaN == NaN\n return x !== x && y !== y;\n }\n }\n /*eslint-enable no-self-compare*/\n\n /**\n * We use an Error-like object for backward compatibility as people may call\n * PropTypes directly and inspect their output. However, we don't use real\n * Errors anymore. We don't inspect their stack anyway, and creating them\n * is prohibitively expensive if they are created too often, such as what\n * happens in oneOfType() for any type before the one that matched.\n */\n function PropTypeError(message, data) {\n this.message = message;\n this.data = data && typeof data === 'object' ? data: {};\n this.stack = '';\n }\n // Make `instanceof Error` still work for returned errors.\n PropTypeError.prototype = Error.prototype;\n\n function createChainableTypeChecker(validate) {\n if (process.env.NODE_ENV !== 'production') {\n var manualPropTypeCallCache = {};\n var manualPropTypeWarningCount = 0;\n }\n function checkType(isRequired, props, propName, componentName, location, propFullName, secret) {\n componentName = componentName || ANONYMOUS;\n propFullName = propFullName || propName;\n\n if (secret !== ReactPropTypesSecret) {\n if (throwOnDirectAccess) {\n // New behavior only for users of `prop-types` package\n var err = new Error(\n 'Calling PropTypes validators directly is not supported by the `prop-types` package. ' +\n 'Use `PropTypes.checkPropTypes()` to call them. ' +\n 'Read more at http://fb.me/use-check-prop-types'\n );\n err.name = 'Invariant Violation';\n throw err;\n } else if (process.env.NODE_ENV !== 'production' && typeof console !== 'undefined') {\n // Old behavior for people using React.PropTypes\n var cacheKey = componentName + ':' + propName;\n if (\n !manualPropTypeCallCache[cacheKey] &&\n // Avoid spamming the console because they are often not actionable except for lib authors\n manualPropTypeWarningCount < 3\n ) {\n printWarning(\n 'You are manually calling a React.PropTypes validation ' +\n 'function for the `' + propFullName + '` prop on `' + componentName + '`. This is deprecated ' +\n 'and will throw in the standalone `prop-types` package. ' +\n 'You may be seeing this warning due to a third-party PropTypes ' +\n 'library. See https://fb.me/react-warning-dont-call-proptypes ' + 'for details.'\n );\n manualPropTypeCallCache[cacheKey] = true;\n manualPropTypeWarningCount++;\n }\n }\n }\n if (props[propName] == null) {\n if (isRequired) {\n if (props[propName] === null) {\n return new PropTypeError('The ' + location + ' `' + propFullName + '` is marked as required ' + ('in `' + componentName + '`, but its value is `null`.'));\n }\n return new PropTypeError('The ' + location + ' `' + propFullName + '` is marked as required in ' + ('`' + componentName + '`, but its value is `undefined`.'));\n }\n return null;\n } else {\n return validate(props, propName, componentName, location, propFullName);\n }\n }\n\n var chainedCheckType = checkType.bind(null, false);\n chainedCheckType.isRequired = checkType.bind(null, true);\n\n return chainedCheckType;\n }\n\n function createPrimitiveTypeChecker(expectedType) {\n function validate(props, propName, componentName, location, propFullName, secret) {\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== expectedType) {\n // `propValue` being instance of, say, date/regexp, pass the 'object'\n // check, but we can offer a more precise error message here rather than\n // 'of type `object`'.\n var preciseType = getPreciseType(propValue);\n\n return new PropTypeError(\n 'Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + preciseType + '` supplied to `' + componentName + '`, expected ') + ('`' + expectedType + '`.'),\n {expectedType: expectedType}\n );\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createAnyTypeChecker() {\n return createChainableTypeChecker(emptyFunctionThatReturnsNull);\n }\n\n function createArrayOfTypeChecker(typeChecker) {\n function validate(props, propName, componentName, location, propFullName) {\n if (typeof typeChecker !== 'function') {\n return new PropTypeError('Property `' + propFullName + '` of component `' + componentName + '` has invalid PropType notation inside arrayOf.');\n }\n var propValue = props[propName];\n if (!Array.isArray(propValue)) {\n var propType = getPropType(propValue);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected an array.'));\n }\n for (var i = 0; i < propValue.length; i++) {\n var error = typeChecker(propValue, i, componentName, location, propFullName + '[' + i + ']', ReactPropTypesSecret);\n if (error instanceof Error) {\n return error;\n }\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createElementTypeChecker() {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n if (!isValidElement(propValue)) {\n var propType = getPropType(propValue);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected a single ReactElement.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createElementTypeTypeChecker() {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n if (!ReactIs.isValidElementType(propValue)) {\n var propType = getPropType(propValue);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected a single ReactElement type.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createInstanceTypeChecker(expectedClass) {\n function validate(props, propName, componentName, location, propFullName) {\n if (!(props[propName] instanceof expectedClass)) {\n var expectedClassName = expectedClass.name || ANONYMOUS;\n var actualClassName = getClassName(props[propName]);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + actualClassName + '` supplied to `' + componentName + '`, expected ') + ('instance of `' + expectedClassName + '`.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createEnumTypeChecker(expectedValues) {\n if (!Array.isArray(expectedValues)) {\n if (process.env.NODE_ENV !== 'production') {\n if (arguments.length > 1) {\n printWarning(\n 'Invalid arguments supplied to oneOf, expected an array, got ' + arguments.length + ' arguments. ' +\n 'A common mistake is to write oneOf(x, y, z) instead of oneOf([x, y, z]).'\n );\n } else {\n printWarning('Invalid argument supplied to oneOf, expected an array.');\n }\n }\n return emptyFunctionThatReturnsNull;\n }\n\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n for (var i = 0; i < expectedValues.length; i++) {\n if (is(propValue, expectedValues[i])) {\n return null;\n }\n }\n\n var valuesString = JSON.stringify(expectedValues, function replacer(key, value) {\n var type = getPreciseType(value);\n if (type === 'symbol') {\n return String(value);\n }\n return value;\n });\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of value `' + String(propValue) + '` ' + ('supplied to `' + componentName + '`, expected one of ' + valuesString + '.'));\n }\n return createChainableTypeChecker(validate);\n }\n\n function createObjectOfTypeChecker(typeChecker) {\n function validate(props, propName, componentName, location, propFullName) {\n if (typeof typeChecker !== 'function') {\n return new PropTypeError('Property `' + propFullName + '` of component `' + componentName + '` has invalid PropType notation inside objectOf.');\n }\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== 'object') {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected an object.'));\n }\n for (var key in propValue) {\n if (has(propValue, key)) {\n var error = typeChecker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret);\n if (error instanceof Error) {\n return error;\n }\n }\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createUnionTypeChecker(arrayOfTypeCheckers) {\n if (!Array.isArray(arrayOfTypeCheckers)) {\n process.env.NODE_ENV !== 'production' ? printWarning('Invalid argument supplied to oneOfType, expected an instance of array.') : void 0;\n return emptyFunctionThatReturnsNull;\n }\n\n for (var i = 0; i < arrayOfTypeCheckers.length; i++) {\n var checker = arrayOfTypeCheckers[i];\n if (typeof checker !== 'function') {\n printWarning(\n 'Invalid argument supplied to oneOfType. Expected an array of check functions, but ' +\n 'received ' + getPostfixForTypeWarning(checker) + ' at index ' + i + '.'\n );\n return emptyFunctionThatReturnsNull;\n }\n }\n\n function validate(props, propName, componentName, location, propFullName) {\n var expectedTypes = [];\n for (var i = 0; i < arrayOfTypeCheckers.length; i++) {\n var checker = arrayOfTypeCheckers[i];\n var checkerResult = checker(props, propName, componentName, location, propFullName, ReactPropTypesSecret);\n if (checkerResult == null) {\n return null;\n }\n if (checkerResult.data && has(checkerResult.data, 'expectedType')) {\n expectedTypes.push(checkerResult.data.expectedType);\n }\n }\n var expectedTypesMessage = (expectedTypes.length > 0) ? ', expected one of type [' + expectedTypes.join(', ') + ']': '';\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` supplied to ' + ('`' + componentName + '`' + expectedTypesMessage + '.'));\n }\n return createChainableTypeChecker(validate);\n }\n\n function createNodeChecker() {\n function validate(props, propName, componentName, location, propFullName) {\n if (!isNode(props[propName])) {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` supplied to ' + ('`' + componentName + '`, expected a ReactNode.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function invalidValidatorError(componentName, location, propFullName, key, type) {\n return new PropTypeError(\n (componentName || 'React class') + ': ' + location + ' type `' + propFullName + '.' + key + '` is invalid; ' +\n 'it must be a function, usually from the `prop-types` package, but received `' + type + '`.'\n );\n }\n\n function createShapeTypeChecker(shapeTypes) {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== 'object') {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type `' + propType + '` ' + ('supplied to `' + componentName + '`, expected `object`.'));\n }\n for (var key in shapeTypes) {\n var checker = shapeTypes[key];\n if (typeof checker !== 'function') {\n return invalidValidatorError(componentName, location, propFullName, key, getPreciseType(checker));\n }\n var error = checker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret);\n if (error) {\n return error;\n }\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createStrictShapeTypeChecker(shapeTypes) {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== 'object') {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type `' + propType + '` ' + ('supplied to `' + componentName + '`, expected `object`.'));\n }\n // We need to check all keys in case some are required but missing from props.\n var allKeys = assign({}, props[propName], shapeTypes);\n for (var key in allKeys) {\n var checker = shapeTypes[key];\n if (has(shapeTypes, key) && typeof checker !== 'function') {\n return invalidValidatorError(componentName, location, propFullName, key, getPreciseType(checker));\n }\n if (!checker) {\n return new PropTypeError(\n 'Invalid ' + location + ' `' + propFullName + '` key `' + key + '` supplied to `' + componentName + '`.' +\n '\\nBad object: ' + JSON.stringify(props[propName], null, ' ') +\n '\\nValid keys: ' + JSON.stringify(Object.keys(shapeTypes), null, ' ')\n );\n }\n var error = checker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret);\n if (error) {\n return error;\n }\n }\n return null;\n }\n\n return createChainableTypeChecker(validate);\n }\n\n function isNode(propValue) {\n switch (typeof propValue) {\n case 'number':\n case 'string':\n case 'undefined':\n return true;\n case 'boolean':\n return !propValue;\n case 'object':\n if (Array.isArray(propValue)) {\n return propValue.every(isNode);\n }\n if (propValue === null || isValidElement(propValue)) {\n return true;\n }\n\n var iteratorFn = getIteratorFn(propValue);\n if (iteratorFn) {\n var iterator = iteratorFn.call(propValue);\n var step;\n if (iteratorFn !== propValue.entries) {\n while (!(step = iterator.next()).done) {\n if (!isNode(step.value)) {\n return false;\n }\n }\n } else {\n // Iterator will provide entry [k,v] tuples rather than values.\n while (!(step = iterator.next()).done) {\n var entry = step.value;\n if (entry) {\n if (!isNode(entry[1])) {\n return false;\n }\n }\n }\n }\n } else {\n return false;\n }\n\n return true;\n default:\n return false;\n }\n }\n\n function isSymbol(propType, propValue) {\n // Native Symbol.\n if (propType === 'symbol') {\n return true;\n }\n\n // falsy value can't be a Symbol\n if (!propValue) {\n return false;\n }\n\n // 19.4.3.5 Symbol.prototype[@@toStringTag] === 'Symbol'\n if (propValue['@@toStringTag'] === 'Symbol') {\n return true;\n }\n\n // Fallback for non-spec compliant Symbols which are polyfilled.\n if (typeof Symbol === 'function' && propValue instanceof Symbol) {\n return true;\n }\n\n return false;\n }\n\n // Equivalent of `typeof` but with special handling for array and regexp.\n function getPropType(propValue) {\n var propType = typeof propValue;\n if (Array.isArray(propValue)) {\n return 'array';\n }\n if (propValue instanceof RegExp) {\n // Old webkits (at least until Android 4.0) return 'function' rather than\n // 'object' for typeof a RegExp. We'll normalize this here so that /bla/\n // passes PropTypes.object.\n return 'object';\n }\n if (isSymbol(propType, propValue)) {\n return 'symbol';\n }\n return propType;\n }\n\n // This handles more types than `getPropType`. Only used for error messages.\n // See `createPrimitiveTypeChecker`.\n function getPreciseType(propValue) {\n if (typeof propValue === 'undefined' || propValue === null) {\n return '' + propValue;\n }\n var propType = getPropType(propValue);\n if (propType === 'object') {\n if (propValue instanceof Date) {\n return 'date';\n } else if (propValue instanceof RegExp) {\n return 'regexp';\n }\n }\n return propType;\n }\n\n // Returns a string that is postfixed to a warning about an invalid type.\n // For example, \"undefined\" or \"of type array\"\n function getPostfixForTypeWarning(value) {\n var type = getPreciseType(value);\n switch (type) {\n case 'array':\n case 'object':\n return 'an ' + type;\n case 'boolean':\n case 'date':\n case 'regexp':\n return 'a ' + type;\n default:\n return type;\n }\n }\n\n // Returns class name of the object, if any.\n function getClassName(propValue) {\n if (!propValue.constructor || !propValue.constructor.name) {\n return ANONYMOUS;\n }\n return propValue.constructor.name;\n }\n\n ReactPropTypes.checkPropTypes = checkPropTypes;\n ReactPropTypes.resetWarningCache = checkPropTypes.resetWarningCache;\n ReactPropTypes.PropTypes = ReactPropTypes;\n\n return ReactPropTypes;\n};\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar ReactPropTypesSecret = require('./lib/ReactPropTypesSecret');\n\nfunction emptyFunction() {}\nfunction emptyFunctionWithReset() {}\nemptyFunctionWithReset.resetWarningCache = emptyFunction;\n\nmodule.exports = function() {\n function shim(props, propName, componentName, location, propFullName, secret) {\n if (secret === ReactPropTypesSecret) {\n // It is still safe when called from React.\n return;\n }\n var err = new Error(\n 'Calling PropTypes validators directly is not supported by the `prop-types` package. ' +\n 'Use PropTypes.checkPropTypes() to call them. ' +\n 'Read more at http://fb.me/use-check-prop-types'\n );\n err.name = 'Invariant Violation';\n throw err;\n };\n shim.isRequired = shim;\n function getShim() {\n return shim;\n };\n // Important!\n // Keep this list in sync with production version in `./factoryWithTypeCheckers.js`.\n var ReactPropTypes = {\n array: shim,\n bigint: shim,\n bool: shim,\n func: shim,\n number: shim,\n object: shim,\n string: shim,\n symbol: shim,\n\n any: shim,\n arrayOf: getShim,\n element: shim,\n elementType: shim,\n instanceOf: getShim,\n node: shim,\n objectOf: getShim,\n oneOf: getShim,\n oneOfType: getShim,\n shape: getShim,\n exact: getShim,\n\n checkPropTypes: emptyFunctionWithReset,\n resetWarningCache: emptyFunction\n };\n\n ReactPropTypes.PropTypes = ReactPropTypes;\n\n return ReactPropTypes;\n};\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\nif (process.env.NODE_ENV !== 'production') {\n var ReactIs = require('react-is');\n\n // By explicitly using `prop-types` you are opting into new development behavior.\n // http://fb.me/prop-types-in-prod\n var throwOnDirectAccess = true;\n module.exports = require('./factoryWithTypeCheckers')(ReactIs.isElement, throwOnDirectAccess);\n} else {\n // By explicitly using `prop-types` you are opting into new production behavior.\n // http://fb.me/prop-types-in-prod\n module.exports = require('./factoryWithThrowingShims')();\n}\n","import PropTypes from 'prop-types';\nimport chainPropTypes from '../chainPropTypes';\nfunction isClassComponent(elementType) {\n // elementType.prototype?.isReactComponent\n const {\n prototype = {}\n } = elementType;\n return Boolean(prototype.isReactComponent);\n}\nfunction acceptingRef(props, propName, componentName, location, propFullName) {\n const element = props[propName];\n const safePropName = propFullName || propName;\n if (element == null ||\n // When server-side rendering React doesn't warn either.\n // This is not an accurate check for SSR.\n // This is only in place for Emotion compat.\n // TODO: Revisit once https://github.com/facebook/react/issues/20047 is resolved.\n typeof window === 'undefined') {\n return null;\n }\n let warningHint;\n const elementType = element.type;\n /**\n * Blacklisting instead of whitelisting\n *\n * Blacklisting will miss some components, such as React.Fragment. Those will at least\n * trigger a warning in React.\n * We can't whitelist because there is no safe way to detect React.forwardRef\n * or class components. \"Safe\" means there's no public API.\n *\n */\n if (typeof elementType === 'function' && !isClassComponent(elementType)) {\n warningHint = 'Did you accidentally use a plain function component for an element instead?';\n }\n if (warningHint !== undefined) {\n return new Error(`Invalid ${location} \\`${safePropName}\\` supplied to \\`${componentName}\\`. ` + `Expected an element that can hold a ref. ${warningHint} ` + 'For more information see https://mui.com/r/caveat-with-refs-guide');\n }\n return null;\n}\nconst elementAcceptingRef = chainPropTypes(PropTypes.element, acceptingRef);\nelementAcceptingRef.isRequired = chainPropTypes(PropTypes.element.isRequired, acceptingRef);\nexport default elementAcceptingRef;","import _extends from \"@babel/runtime/helpers/esm/extends\";\n// This module is based on https://github.com/airbnb/prop-types-exact repository.\n// However, in order to reduce the number of dependencies and to remove some extra safe checks\n// the module was forked.\n\nconst specialProperty = 'exact-prop: \\u200b';\nexport default function exactProp(propTypes) {\n if (process.env.NODE_ENV === 'production') {\n return propTypes;\n }\n return _extends({}, propTypes, {\n [specialProperty]: props => {\n const unsupportedProps = Object.keys(props).filter(prop => !propTypes.hasOwnProperty(prop));\n if (unsupportedProps.length > 0) {\n return new Error(`The following props are not supported: ${unsupportedProps.map(prop => `\\`${prop}\\``).join(', ')}. Please remove them.`);\n }\n return null;\n }\n });\n}","/**\n * WARNING: Don't import this directly.\n * Use `MuiError` from `@mui/internal-babel-macros/MuiError.macro` instead.\n * @param {number} code\n */\nexport default function formatMuiErrorMessage(code) {\n // Apply babel-plugin-transform-template-literals in loose mode\n // loose mode is safe if we're concatenating primitives\n // see https://babeljs.io/docs/en/babel-plugin-transform-template-literals#loose\n /* eslint-disable prefer-template */\n let url = 'https://mui.com/production-error/?code=' + code;\n for (let i = 1; i < arguments.length; i += 1) {\n // rest params over-transpile for this case\n // eslint-disable-next-line prefer-rest-params\n url += '&args[]=' + encodeURIComponent(arguments[i]);\n }\n return 'Minified MUI error #' + code + '; visit ' + url + ' for the full message.';\n /* eslint-enable prefer-template */\n}","/**\n * @license React\n * react-is.production.min.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n'use strict';var b=Symbol.for(\"react.element\"),c=Symbol.for(\"react.portal\"),d=Symbol.for(\"react.fragment\"),e=Symbol.for(\"react.strict_mode\"),f=Symbol.for(\"react.profiler\"),g=Symbol.for(\"react.provider\"),h=Symbol.for(\"react.context\"),k=Symbol.for(\"react.server_context\"),l=Symbol.for(\"react.forward_ref\"),m=Symbol.for(\"react.suspense\"),n=Symbol.for(\"react.suspense_list\"),p=Symbol.for(\"react.memo\"),q=Symbol.for(\"react.lazy\"),t=Symbol.for(\"react.offscreen\"),u;u=Symbol.for(\"react.module.reference\");\nfunction v(a){if(\"object\"===typeof a&&null!==a){var r=a.$$typeof;switch(r){case b:switch(a=a.type,a){case d:case f:case e:case m:case n:return a;default:switch(a=a&&a.$$typeof,a){case k:case h:case l:case q:case p:case g:return a;default:return r}}case c:return r}}}exports.ContextConsumer=h;exports.ContextProvider=g;exports.Element=b;exports.ForwardRef=l;exports.Fragment=d;exports.Lazy=q;exports.Memo=p;exports.Portal=c;exports.Profiler=f;exports.StrictMode=e;exports.Suspense=m;\nexports.SuspenseList=n;exports.isAsyncMode=function(){return!1};exports.isConcurrentMode=function(){return!1};exports.isContextConsumer=function(a){return v(a)===h};exports.isContextProvider=function(a){return v(a)===g};exports.isElement=function(a){return\"object\"===typeof a&&null!==a&&a.$$typeof===b};exports.isForwardRef=function(a){return v(a)===l};exports.isFragment=function(a){return v(a)===d};exports.isLazy=function(a){return v(a)===q};exports.isMemo=function(a){return v(a)===p};\nexports.isPortal=function(a){return v(a)===c};exports.isProfiler=function(a){return v(a)===f};exports.isStrictMode=function(a){return v(a)===e};exports.isSuspense=function(a){return v(a)===m};exports.isSuspenseList=function(a){return v(a)===n};\nexports.isValidElementType=function(a){return\"string\"===typeof a||\"function\"===typeof a||a===d||a===f||a===e||a===m||a===n||a===t||\"object\"===typeof a&&null!==a&&(a.$$typeof===q||a.$$typeof===p||a.$$typeof===g||a.$$typeof===h||a.$$typeof===l||a.$$typeof===u||void 0!==a.getModuleId)?!0:!1};exports.typeOf=v;\n","/**\n * @license React\n * react-is.development.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nif (process.env.NODE_ENV !== \"production\") {\n (function() {\n'use strict';\n\n// ATTENTION\n// When adding new symbols to this file,\n// Please consider also adding to 'react-devtools-shared/src/backend/ReactSymbols'\n// The Symbol used to tag the ReactElement-like types.\nvar REACT_ELEMENT_TYPE = Symbol.for('react.element');\nvar REACT_PORTAL_TYPE = Symbol.for('react.portal');\nvar REACT_FRAGMENT_TYPE = Symbol.for('react.fragment');\nvar REACT_STRICT_MODE_TYPE = Symbol.for('react.strict_mode');\nvar REACT_PROFILER_TYPE = Symbol.for('react.profiler');\nvar REACT_PROVIDER_TYPE = Symbol.for('react.provider');\nvar REACT_CONTEXT_TYPE = Symbol.for('react.context');\nvar REACT_SERVER_CONTEXT_TYPE = Symbol.for('react.server_context');\nvar REACT_FORWARD_REF_TYPE = Symbol.for('react.forward_ref');\nvar REACT_SUSPENSE_TYPE = Symbol.for('react.suspense');\nvar REACT_SUSPENSE_LIST_TYPE = Symbol.for('react.suspense_list');\nvar REACT_MEMO_TYPE = Symbol.for('react.memo');\nvar REACT_LAZY_TYPE = Symbol.for('react.lazy');\nvar REACT_OFFSCREEN_TYPE = Symbol.for('react.offscreen');\n\n// -----------------------------------------------------------------------------\n\nvar enableScopeAPI = false; // Experimental Create Event Handle API.\nvar enableCacheElement = false;\nvar enableTransitionTracing = false; // No known bugs, but needs performance testing\n\nvar enableLegacyHidden = false; // Enables unstable_avoidThisFallback feature in Fiber\n// stuff. Intended to enable React core members to more easily debug scheduling\n// issues in DEV builds.\n\nvar enableDebugTracing = false; // Track which Fiber(s) schedule render work.\n\nvar REACT_MODULE_REFERENCE;\n\n{\n REACT_MODULE_REFERENCE = Symbol.for('react.module.reference');\n}\n\nfunction isValidElementType(type) {\n if (typeof type === 'string' || typeof type === 'function') {\n return true;\n } // Note: typeof might be other than 'symbol' or 'number' (e.g. if it's a polyfill).\n\n\n if (type === REACT_FRAGMENT_TYPE || type === REACT_PROFILER_TYPE || enableDebugTracing || type === REACT_STRICT_MODE_TYPE || type === REACT_SUSPENSE_TYPE || type === REACT_SUSPENSE_LIST_TYPE || enableLegacyHidden || type === REACT_OFFSCREEN_TYPE || enableScopeAPI || enableCacheElement || enableTransitionTracing ) {\n return true;\n }\n\n if (typeof type === 'object' && type !== null) {\n if (type.$$typeof === REACT_LAZY_TYPE || type.$$typeof === REACT_MEMO_TYPE || type.$$typeof === REACT_PROVIDER_TYPE || type.$$typeof === REACT_CONTEXT_TYPE || type.$$typeof === REACT_FORWARD_REF_TYPE || // This needs to include all possible module reference object\n // types supported by any Flight configuration anywhere since\n // we don't know which Flight build this will end up being used\n // with.\n type.$$typeof === REACT_MODULE_REFERENCE || type.getModuleId !== undefined) {\n return true;\n }\n }\n\n return false;\n}\n\nfunction typeOf(object) {\n if (typeof object === 'object' && object !== null) {\n var $$typeof = object.$$typeof;\n\n switch ($$typeof) {\n case REACT_ELEMENT_TYPE:\n var type = object.type;\n\n switch (type) {\n case REACT_FRAGMENT_TYPE:\n case REACT_PROFILER_TYPE:\n case REACT_STRICT_MODE_TYPE:\n case REACT_SUSPENSE_TYPE:\n case REACT_SUSPENSE_LIST_TYPE:\n return type;\n\n default:\n var $$typeofType = type && type.$$typeof;\n\n switch ($$typeofType) {\n case REACT_SERVER_CONTEXT_TYPE:\n case REACT_CONTEXT_TYPE:\n case REACT_FORWARD_REF_TYPE:\n case REACT_LAZY_TYPE:\n case REACT_MEMO_TYPE:\n case REACT_PROVIDER_TYPE:\n return $$typeofType;\n\n default:\n return $$typeof;\n }\n\n }\n\n case REACT_PORTAL_TYPE:\n return $$typeof;\n }\n }\n\n return undefined;\n}\nvar ContextConsumer = REACT_CONTEXT_TYPE;\nvar ContextProvider = REACT_PROVIDER_TYPE;\nvar Element = REACT_ELEMENT_TYPE;\nvar ForwardRef = REACT_FORWARD_REF_TYPE;\nvar Fragment = REACT_FRAGMENT_TYPE;\nvar Lazy = REACT_LAZY_TYPE;\nvar Memo = REACT_MEMO_TYPE;\nvar Portal = REACT_PORTAL_TYPE;\nvar Profiler = REACT_PROFILER_TYPE;\nvar StrictMode = REACT_STRICT_MODE_TYPE;\nvar Suspense = REACT_SUSPENSE_TYPE;\nvar SuspenseList = REACT_SUSPENSE_LIST_TYPE;\nvar hasWarnedAboutDeprecatedIsAsyncMode = false;\nvar hasWarnedAboutDeprecatedIsConcurrentMode = false; // AsyncMode should be deprecated\n\nfunction isAsyncMode(object) {\n {\n if (!hasWarnedAboutDeprecatedIsAsyncMode) {\n hasWarnedAboutDeprecatedIsAsyncMode = true; // Using console['warn'] to evade Babel and ESLint\n\n console['warn']('The ReactIs.isAsyncMode() alias has been deprecated, ' + 'and will be removed in React 18+.');\n }\n }\n\n return false;\n}\nfunction isConcurrentMode(object) {\n {\n if (!hasWarnedAboutDeprecatedIsConcurrentMode) {\n hasWarnedAboutDeprecatedIsConcurrentMode = true; // Using console['warn'] to evade Babel and ESLint\n\n console['warn']('The ReactIs.isConcurrentMode() alias has been deprecated, ' + 'and will be removed in React 18+.');\n }\n }\n\n return false;\n}\nfunction isContextConsumer(object) {\n return typeOf(object) === REACT_CONTEXT_TYPE;\n}\nfunction isContextProvider(object) {\n return typeOf(object) === REACT_PROVIDER_TYPE;\n}\nfunction isElement(object) {\n return typeof object === 'object' && object !== null && object.$$typeof === REACT_ELEMENT_TYPE;\n}\nfunction isForwardRef(object) {\n return typeOf(object) === REACT_FORWARD_REF_TYPE;\n}\nfunction isFragment(object) {\n return typeOf(object) === REACT_FRAGMENT_TYPE;\n}\nfunction isLazy(object) {\n return typeOf(object) === REACT_LAZY_TYPE;\n}\nfunction isMemo(object) {\n return typeOf(object) === REACT_MEMO_TYPE;\n}\nfunction isPortal(object) {\n return typeOf(object) === REACT_PORTAL_TYPE;\n}\nfunction isProfiler(object) {\n return typeOf(object) === REACT_PROFILER_TYPE;\n}\nfunction isStrictMode(object) {\n return typeOf(object) === REACT_STRICT_MODE_TYPE;\n}\nfunction isSuspense(object) {\n return typeOf(object) === REACT_SUSPENSE_TYPE;\n}\nfunction isSuspenseList(object) {\n return typeOf(object) === REACT_SUSPENSE_LIST_TYPE;\n}\n\nexports.ContextConsumer = ContextConsumer;\nexports.ContextProvider = ContextProvider;\nexports.Element = Element;\nexports.ForwardRef = ForwardRef;\nexports.Fragment = Fragment;\nexports.Lazy = Lazy;\nexports.Memo = Memo;\nexports.Portal = Portal;\nexports.Profiler = Profiler;\nexports.StrictMode = StrictMode;\nexports.Suspense = Suspense;\nexports.SuspenseList = SuspenseList;\nexports.isAsyncMode = isAsyncMode;\nexports.isConcurrentMode = isConcurrentMode;\nexports.isContextConsumer = isContextConsumer;\nexports.isContextProvider = isContextProvider;\nexports.isElement = isElement;\nexports.isForwardRef = isForwardRef;\nexports.isFragment = isFragment;\nexports.isLazy = isLazy;\nexports.isMemo = isMemo;\nexports.isPortal = isPortal;\nexports.isProfiler = isProfiler;\nexports.isStrictMode = isStrictMode;\nexports.isSuspense = isSuspense;\nexports.isSuspenseList = isSuspenseList;\nexports.isValidElementType = isValidElementType;\nexports.typeOf = typeOf;\n })();\n}\n","'use strict';\n\nif (process.env.NODE_ENV === 'production') {\n module.exports = require('./cjs/react-is.production.min.js');\n} else {\n module.exports = require('./cjs/react-is.development.js');\n}\n","import { ForwardRef, Memo } from 'react-is';\n\n// Simplified polyfill for IE11 support\n// https://github.com/JamesMGreene/Function.name/blob/58b314d4a983110c3682f1228f845d39ccca1817/Function.name.js#L3\nconst fnNameMatchRegex = /^\\s*function(?:\\s|\\s*\\/\\*.*\\*\\/\\s*)+([^(\\s/]*)\\s*/;\nexport function getFunctionName(fn) {\n const match = `${fn}`.match(fnNameMatchRegex);\n const name = match && match[1];\n return name || '';\n}\nfunction getFunctionComponentName(Component, fallback = '') {\n return Component.displayName || Component.name || getFunctionName(Component) || fallback;\n}\nfunction getWrappedName(outerType, innerType, wrapperName) {\n const functionName = getFunctionComponentName(innerType);\n return outerType.displayName || (functionName !== '' ? `${wrapperName}(${functionName})` : wrapperName);\n}\n\n/**\n * cherry-pick from\n * https://github.com/facebook/react/blob/769b1f270e1251d9dbdce0fcbd9e92e502d059b8/packages/shared/getComponentName.js\n * originally forked from recompose/getDisplayName with added IE11 support\n */\nexport default function getDisplayName(Component) {\n if (Component == null) {\n return undefined;\n }\n if (typeof Component === 'string') {\n return Component;\n }\n if (typeof Component === 'function') {\n return getFunctionComponentName(Component, 'Component');\n }\n\n // TypeScript can't have components as objects but they exist in the form of `memo` or `Suspense`\n if (typeof Component === 'object') {\n switch (Component.$$typeof) {\n case ForwardRef:\n return getWrappedName(Component, Component.render, 'ForwardRef');\n case Memo:\n return getWrappedName(Component, Component.type, 'memo');\n default:\n return undefined;\n }\n }\n return undefined;\n}","export default function HTMLElementType(props, propName, componentName, location, propFullName) {\n if (process.env.NODE_ENV === 'production') {\n return null;\n }\n const propValue = props[propName];\n const safePropName = propFullName || propName;\n if (propValue == null) {\n return null;\n }\n if (propValue && propValue.nodeType !== 1) {\n return new Error(`Invalid ${location} \\`${safePropName}\\` supplied to \\`${componentName}\\`. ` + `Expected an HTMLElement.`);\n }\n return null;\n}","import PropTypes from 'prop-types';\nconst refType = PropTypes.oneOfType([PropTypes.func, PropTypes.object]);\nexport default refType;","import _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\n// It should to be noted that this function isn't equivalent to `text-transform: capitalize`.\n//\n// A strict capitalization should uppercase the first letter of each word in the sentence.\n// We only handle the first word.\nexport default function capitalize(string) {\n if (typeof string !== 'string') {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: \\`capitalize(string)\\` expects a string argument.` : _formatMuiErrorMessage(7));\n }\n return string.charAt(0).toUpperCase() + string.slice(1);\n}","/**\n * Safe chained function.\n *\n * Will only create a new function if needed,\n * otherwise will pass back existing functions or null.\n */\nexport default function createChainedFunction(...funcs) {\n return funcs.reduce((acc, func) => {\n if (func == null) {\n return acc;\n }\n return function chainedFunction(...args) {\n acc.apply(this, args);\n func.apply(this, args);\n };\n }, () => {});\n}","// Corresponds to 10 frames at 60 Hz.\n// A few bytes payload overhead when lodash/debounce is ~3 kB and debounce ~300 B.\nexport default function debounce(func, wait = 166) {\n let timeout;\n function debounced(...args) {\n const later = () => {\n // @ts-ignore\n func.apply(this, args);\n };\n clearTimeout(timeout);\n timeout = setTimeout(later, wait);\n }\n debounced.clear = () => {\n clearTimeout(timeout);\n };\n return debounced;\n}","export default function deprecatedPropType(validator, reason) {\n if (process.env.NODE_ENV === 'production') {\n return () => null;\n }\n return (props, propName, componentName, location, propFullName) => {\n const componentNameSafe = componentName || '<>';\n const propFullNameSafe = propFullName || propName;\n if (typeof props[propName] !== 'undefined') {\n return new Error(`The ${location} \\`${propFullNameSafe}\\` of ` + `\\`${componentNameSafe}\\` is deprecated. ${reason}`);\n }\n return null;\n };\n}","import * as React from 'react';\nexport default function isMuiElement(element, muiNames) {\n var _muiName, _element$type;\n return /*#__PURE__*/React.isValidElement(element) && muiNames.indexOf( // For server components `muiName` is avaialble in element.type._payload.value.muiName\n // relevant info - https://github.com/facebook/react/blob/2807d781a08db8e9873687fccc25c0f12b4fb3d4/packages/react/src/ReactLazy.js#L45\n // eslint-disable-next-line no-underscore-dangle\n (_muiName = element.type.muiName) != null ? _muiName : (_element$type = element.type) == null || (_element$type = _element$type._payload) == null || (_element$type = _element$type.value) == null ? void 0 : _element$type.muiName) !== -1;\n}","export default function ownerDocument(node) {\n return node && node.ownerDocument || document;\n}","import ownerDocument from '../ownerDocument';\nexport default function ownerWindow(node) {\n const doc = ownerDocument(node);\n return doc.defaultView || window;\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nexport default function requirePropFactory(componentNameInError, Component) {\n if (process.env.NODE_ENV === 'production') {\n return () => null;\n }\n\n // eslint-disable-next-line react/forbid-foreign-prop-types\n const prevPropTypes = Component ? _extends({}, Component.propTypes) : null;\n const requireProp = requiredProp => (props, propName, componentName, location, propFullName, ...args) => {\n const propFullNameSafe = propFullName || propName;\n const defaultTypeChecker = prevPropTypes == null ? void 0 : prevPropTypes[propFullNameSafe];\n if (defaultTypeChecker) {\n const typeCheckerResult = defaultTypeChecker(props, propName, componentName, location, propFullName, ...args);\n if (typeCheckerResult) {\n return typeCheckerResult;\n }\n }\n if (typeof props[propName] !== 'undefined' && !props[requiredProp]) {\n return new Error(`The prop \\`${propFullNameSafe}\\` of ` + `\\`${componentNameInError}\\` can only be used together with the \\`${requiredProp}\\` prop.`);\n }\n return null;\n };\n return requireProp;\n}","/**\n * TODO v5: consider making it private\n *\n * passes {value} to {ref}\n *\n * WARNING: Be sure to only call this inside a callback that is passed as a ref.\n * Otherwise, make sure to cleanup the previous {ref} if it changes. See\n * https://github.com/mui/material-ui/issues/13539\n *\n * Useful if you want to expose the ref of an inner component to the public API\n * while still using it inside the component.\n * @param ref A ref callback or ref object. If anything falsy, this is a no-op.\n */\nexport default function setRef(ref, value) {\n if (typeof ref === 'function') {\n ref(value);\n } else if (ref) {\n ref.current = value;\n }\n}","'use client';\n\nimport * as React from 'react';\n\n/**\n * A version of `React.useLayoutEffect` that does not show a warning when server-side rendering.\n * This is useful for effects that are only needed for client-side rendering but not for SSR.\n *\n * Before you use this hook, make sure to read https://gist.github.com/gaearon/e7d97cdf38a2907924ea12e4ebdf3c85\n * and confirm it doesn't apply to your use-case.\n */\nconst useEnhancedEffect = typeof window !== 'undefined' ? React.useLayoutEffect : React.useEffect;\nexport default useEnhancedEffect;","'use client';\n\nimport * as React from 'react';\nlet globalId = 0;\nfunction useGlobalId(idOverride) {\n const [defaultId, setDefaultId] = React.useState(idOverride);\n const id = idOverride || defaultId;\n React.useEffect(() => {\n if (defaultId == null) {\n // Fallback to this default id when possible.\n // Use the incrementing value for client-side rendering only.\n // We can't use it server-side.\n // If you want to use random values please consider the Birthday Problem: https://en.wikipedia.org/wiki/Birthday_problem\n globalId += 1;\n setDefaultId(`mui-${globalId}`);\n }\n }, [defaultId]);\n return id;\n}\n\n// downstream bundlers may remove unnecessary concatenation, but won't remove toString call -- Workaround for https://github.com/webpack/webpack/issues/14814\nconst maybeReactUseId = React['useId'.toString()];\n/**\n *\n * @example
    \n * @param idOverride\n * @returns {string}\n */\nexport default function useId(idOverride) {\n if (maybeReactUseId !== undefined) {\n const reactId = maybeReactUseId();\n return idOverride != null ? idOverride : reactId;\n }\n // eslint-disable-next-line react-hooks/rules-of-hooks -- `React.useId` is invariant at runtime.\n return useGlobalId(idOverride);\n}","export default function unsupportedProp(props, propName, componentName, location, propFullName) {\n if (process.env.NODE_ENV === 'production') {\n return null;\n }\n const propFullNameSafe = propFullName || propName;\n if (typeof props[propName] !== 'undefined') {\n return new Error(`The prop \\`${propFullNameSafe}\\` is not supported. Please remove it.`);\n }\n return null;\n}","'use client';\n\n/* eslint-disable react-hooks/rules-of-hooks, react-hooks/exhaustive-deps */\nimport * as React from 'react';\nexport default function useControlled({\n controlled,\n default: defaultProp,\n name,\n state = 'value'\n}) {\n // isControlled is ignored in the hook dependency lists as it should never change.\n const {\n current: isControlled\n } = React.useRef(controlled !== undefined);\n const [valueState, setValue] = React.useState(defaultProp);\n const value = isControlled ? controlled : valueState;\n if (process.env.NODE_ENV !== 'production') {\n React.useEffect(() => {\n if (isControlled !== (controlled !== undefined)) {\n console.error([`MUI: A component is changing the ${isControlled ? '' : 'un'}controlled ${state} state of ${name} to be ${isControlled ? 'un' : ''}controlled.`, 'Elements should not switch from uncontrolled to controlled (or vice versa).', `Decide between using a controlled or uncontrolled ${name} ` + 'element for the lifetime of the component.', \"The nature of the state is determined during the first render. It's considered controlled if the value is not `undefined`.\", 'More info: https://fb.me/react-controlled-components'].join('\\n'));\n }\n }, [state, name, controlled]);\n const {\n current: defaultValue\n } = React.useRef(defaultProp);\n React.useEffect(() => {\n if (!isControlled && defaultValue !== defaultProp) {\n console.error([`MUI: A component is changing the default ${state} state of an uncontrolled ${name} after being initialized. ` + `To suppress this warning opt to use a controlled ${name}.`].join('\\n'));\n }\n }, [JSON.stringify(defaultProp)]);\n }\n const setValueIfUncontrolled = React.useCallback(newValue => {\n if (!isControlled) {\n setValue(newValue);\n }\n }, []);\n return [value, setValueIfUncontrolled];\n}","'use client';\n\nimport * as React from 'react';\nimport useEnhancedEffect from '../useEnhancedEffect';\n\n/**\n * Inspired by https://github.com/facebook/react/issues/14099#issuecomment-440013892\n * See RFC in https://github.com/reactjs/rfcs/pull/220\n */\n\nfunction useEventCallback(fn) {\n const ref = React.useRef(fn);\n useEnhancedEffect(() => {\n ref.current = fn;\n });\n return React.useRef((...args) =>\n // @ts-expect-error hide `this`\n (0, ref.current)(...args)).current;\n}\nexport default useEventCallback;","'use client';\n\nimport * as React from 'react';\nimport setRef from '../setRef';\nexport default function useForkRef(...refs) {\n /**\n * This will create a new function if the refs passed to this hook change and are all defined.\n * This means react will call the old forkRef with `null` and the new forkRef\n * with the ref. Cleanup naturally emerges from this behavior.\n */\n return React.useMemo(() => {\n if (refs.every(ref => ref == null)) {\n return null;\n }\n return instance => {\n refs.forEach(ref => {\n setRef(ref, instance);\n });\n };\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, refs);\n}","'use client';\n\nimport * as React from 'react';\nconst UNINITIALIZED = {};\n\n/**\n * A React.useRef() that is initialized lazily with a function. Note that it accepts an optional\n * initialization argument, so the initialization function doesn't need to be an inline closure.\n *\n * @usage\n * const ref = useLazyRef(sortColumns, columns)\n */\nexport default function useLazyRef(init, initArg) {\n const ref = React.useRef(UNINITIALIZED);\n if (ref.current === UNINITIALIZED) {\n ref.current = init(initArg);\n }\n return ref;\n}","'use client';\n\nimport * as React from 'react';\nconst EMPTY = [];\n\n/**\n * A React.useEffect equivalent that runs once, when the component is mounted.\n */\nexport default function useOnMount(fn) {\n /* eslint-disable react-hooks/exhaustive-deps */\n React.useEffect(fn, EMPTY);\n /* eslint-enable react-hooks/exhaustive-deps */\n}","'use client';\n\nimport useLazyRef from '../useLazyRef/useLazyRef';\nimport useOnMount from '../useOnMount/useOnMount';\nexport class Timeout {\n constructor() {\n this.currentId = null;\n this.clear = () => {\n if (this.currentId !== null) {\n clearTimeout(this.currentId);\n this.currentId = null;\n }\n };\n this.disposeEffect = () => {\n return this.clear;\n };\n }\n static create() {\n return new Timeout();\n }\n /**\n * Executes `fn` after `delay`, clearing any previously scheduled call.\n */\n start(delay, fn) {\n this.clear();\n this.currentId = setTimeout(() => {\n this.currentId = null;\n fn();\n }, delay);\n }\n}\nexport default function useTimeout() {\n const timeout = useLazyRef(Timeout.create).current;\n useOnMount(timeout.disposeEffect);\n return timeout;\n}","'use client';\n\n// based on https://github.com/WICG/focus-visible/blob/v4.1.5/src/focus-visible.js\nimport * as React from 'react';\nimport { Timeout } from '../useTimeout/useTimeout';\nlet hadKeyboardEvent = true;\nlet hadFocusVisibleRecently = false;\nconst hadFocusVisibleRecentlyTimeout = new Timeout();\nconst inputTypesWhitelist = {\n text: true,\n search: true,\n url: true,\n tel: true,\n email: true,\n password: true,\n number: true,\n date: true,\n month: true,\n week: true,\n time: true,\n datetime: true,\n 'datetime-local': true\n};\n\n/**\n * Computes whether the given element should automatically trigger the\n * `focus-visible` class being added, i.e. whether it should always match\n * `:focus-visible` when focused.\n * @param {Element} node\n * @returns {boolean}\n */\nfunction focusTriggersKeyboardModality(node) {\n const {\n type,\n tagName\n } = node;\n if (tagName === 'INPUT' && inputTypesWhitelist[type] && !node.readOnly) {\n return true;\n }\n if (tagName === 'TEXTAREA' && !node.readOnly) {\n return true;\n }\n if (node.isContentEditable) {\n return true;\n }\n return false;\n}\n\n/**\n * Keep track of our keyboard modality state with `hadKeyboardEvent`.\n * If the most recent user interaction was via the keyboard;\n * and the key press did not include a meta, alt/option, or control key;\n * then the modality is keyboard. Otherwise, the modality is not keyboard.\n * @param {KeyboardEvent} event\n */\nfunction handleKeyDown(event) {\n if (event.metaKey || event.altKey || event.ctrlKey) {\n return;\n }\n hadKeyboardEvent = true;\n}\n\n/**\n * If at any point a user clicks with a pointing device, ensure that we change\n * the modality away from keyboard.\n * This avoids the situation where a user presses a key on an already focused\n * element, and then clicks on a different element, focusing it with a\n * pointing device, while we still think we're in keyboard modality.\n */\nfunction handlePointerDown() {\n hadKeyboardEvent = false;\n}\nfunction handleVisibilityChange() {\n if (this.visibilityState === 'hidden') {\n // If the tab becomes active again, the browser will handle calling focus\n // on the element (Safari actually calls it twice).\n // If this tab change caused a blur on an element with focus-visible,\n // re-apply the class when the user switches back to the tab.\n if (hadFocusVisibleRecently) {\n hadKeyboardEvent = true;\n }\n }\n}\nfunction prepare(doc) {\n doc.addEventListener('keydown', handleKeyDown, true);\n doc.addEventListener('mousedown', handlePointerDown, true);\n doc.addEventListener('pointerdown', handlePointerDown, true);\n doc.addEventListener('touchstart', handlePointerDown, true);\n doc.addEventListener('visibilitychange', handleVisibilityChange, true);\n}\nexport function teardown(doc) {\n doc.removeEventListener('keydown', handleKeyDown, true);\n doc.removeEventListener('mousedown', handlePointerDown, true);\n doc.removeEventListener('pointerdown', handlePointerDown, true);\n doc.removeEventListener('touchstart', handlePointerDown, true);\n doc.removeEventListener('visibilitychange', handleVisibilityChange, true);\n}\nfunction isFocusVisible(event) {\n const {\n target\n } = event;\n try {\n return target.matches(':focus-visible');\n } catch (error) {\n // Browsers not implementing :focus-visible will throw a SyntaxError.\n // We use our own heuristic for those browsers.\n // Rethrow might be better if it's not the expected error but do we really\n // want to crash if focus-visible malfunctioned?\n }\n\n // No need for validFocusTarget check. The user does that by attaching it to\n // focusable events only.\n return hadKeyboardEvent || focusTriggersKeyboardModality(target);\n}\nexport default function useIsFocusVisible() {\n const ref = React.useCallback(node => {\n if (node != null) {\n prepare(node.ownerDocument);\n }\n }, []);\n const isFocusVisibleRef = React.useRef(false);\n\n /**\n * Should be called if a blur event is fired\n */\n function handleBlurVisible() {\n // checking against potential state variable does not suffice if we focus and blur synchronously.\n // React wouldn't have time to trigger a re-render so `focusVisible` would be stale.\n // Ideally we would adjust `isFocusVisible(event)` to look at `relatedTarget` for blur events.\n // This doesn't work in IE11 due to https://github.com/facebook/react/issues/3751\n // TODO: check again if React releases their internal changes to focus event handling (https://github.com/facebook/react/pull/19186).\n if (isFocusVisibleRef.current) {\n // To detect a tab/window switch, we look for a blur event followed\n // rapidly by a visibility change.\n // If we don't see a visibility change within 100ms, it's probably a\n // regular focus change.\n hadFocusVisibleRecently = true;\n hadFocusVisibleRecentlyTimeout.start(100, () => {\n hadFocusVisibleRecently = false;\n });\n isFocusVisibleRef.current = false;\n return true;\n }\n return false;\n }\n\n /**\n * Should be called if a blur event is fired\n */\n function handleFocusVisible(event) {\n if (isFocusVisible(event)) {\n isFocusVisibleRef.current = true;\n return true;\n }\n return false;\n }\n return {\n isFocusVisibleRef,\n onFocus: handleFocusVisible,\n onBlur: handleBlurVisible,\n ref\n };\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\n/**\n * Add keys, values of `defaultProps` that does not exist in `props`\n * @param {object} defaultProps\n * @param {object} props\n * @returns {object} resolved props\n */\nexport default function resolveProps(defaultProps, props) {\n const output = _extends({}, props);\n Object.keys(defaultProps).forEach(propName => {\n if (propName.toString().match(/^(components|slots)$/)) {\n output[propName] = _extends({}, defaultProps[propName], output[propName]);\n } else if (propName.toString().match(/^(componentsProps|slotProps)$/)) {\n const defaultSlotProps = defaultProps[propName] || {};\n const slotProps = props[propName];\n output[propName] = {};\n if (!slotProps || !Object.keys(slotProps)) {\n // Reduce the iteration if the slot props is empty\n output[propName] = defaultSlotProps;\n } else if (!defaultSlotProps || !Object.keys(defaultSlotProps)) {\n // Reduce the iteration if the default slot props is empty\n output[propName] = slotProps;\n } else {\n output[propName] = _extends({}, slotProps);\n Object.keys(defaultSlotProps).forEach(slotPropName => {\n output[propName][slotPropName] = resolveProps(defaultSlotProps[slotPropName], slotProps[slotPropName]);\n });\n }\n } else if (output[propName] === undefined) {\n output[propName] = defaultProps[propName];\n }\n });\n return output;\n}","export default function composeClasses(slots, getUtilityClass, classes = undefined) {\n const output = {};\n Object.keys(slots).forEach(\n // `Object.keys(slots)` can't be wider than `T` because we infer `T` from `slots`.\n // @ts-expect-error https://github.com/microsoft/TypeScript/pull/12253#issuecomment-263132208\n slot => {\n output[slot] = slots[slot].reduce((acc, key) => {\n if (key) {\n const utilityClass = getUtilityClass(key);\n if (utilityClass !== '') {\n acc.push(utilityClass);\n }\n if (classes && classes[key]) {\n acc.push(classes[key]);\n }\n }\n return acc;\n }, []).join(' ');\n });\n return output;\n}","const defaultGenerator = componentName => componentName;\nconst createClassNameGenerator = () => {\n let generate = defaultGenerator;\n return {\n configure(generator) {\n generate = generator;\n },\n generate(componentName) {\n return generate(componentName);\n },\n reset() {\n generate = defaultGenerator;\n }\n };\n};\nconst ClassNameGenerator = createClassNameGenerator();\nexport default ClassNameGenerator;","import ClassNameGenerator from '../ClassNameGenerator';\nexport const globalStateClasses = {\n active: 'active',\n checked: 'checked',\n completed: 'completed',\n disabled: 'disabled',\n error: 'error',\n expanded: 'expanded',\n focused: 'focused',\n focusVisible: 'focusVisible',\n open: 'open',\n readOnly: 'readOnly',\n required: 'required',\n selected: 'selected'\n};\nexport default function generateUtilityClass(componentName, slot, globalStatePrefix = 'Mui') {\n const globalStateClass = globalStateClasses[slot];\n return globalStateClass ? `${globalStatePrefix}-${globalStateClass}` : `${ClassNameGenerator.generate(componentName)}-${slot}`;\n}\nexport function isGlobalState(slot) {\n return globalStateClasses[slot] !== undefined;\n}","import generateUtilityClass from '../generateUtilityClass';\nexport default function generateUtilityClasses(componentName, slots, globalStatePrefix = 'Mui') {\n const result = {};\n slots.forEach(slot => {\n result[slot] = generateUtilityClass(componentName, slot, globalStatePrefix);\n });\n return result;\n}","function clamp(val, min = Number.MIN_SAFE_INTEGER, max = Number.MAX_SAFE_INTEGER) {\n return Math.max(min, Math.min(val, max));\n}\nexport default clamp;","export default function _objectWithoutPropertiesLoose(source, excluded) {\n if (source == null) return {};\n var target = {};\n var sourceKeys = Object.keys(source);\n var key, i;\n for (i = 0; i < sourceKeys.length; i++) {\n key = sourceKeys[i];\n if (excluded.indexOf(key) >= 0) continue;\n target[key] = source[key];\n }\n return target;\n}","import _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nconst _excluded = [\"values\", \"unit\", \"step\"];\n// Sorted ASC by size. That's important.\n// It can't be configured as it's used statically for propTypes.\nexport const breakpointKeys = ['xs', 'sm', 'md', 'lg', 'xl'];\nconst sortBreakpointsValues = values => {\n const breakpointsAsArray = Object.keys(values).map(key => ({\n key,\n val: values[key]\n })) || [];\n // Sort in ascending order\n breakpointsAsArray.sort((breakpoint1, breakpoint2) => breakpoint1.val - breakpoint2.val);\n return breakpointsAsArray.reduce((acc, obj) => {\n return _extends({}, acc, {\n [obj.key]: obj.val\n });\n }, {});\n};\n\n// Keep in mind that @media is inclusive by the CSS specification.\nexport default function createBreakpoints(breakpoints) {\n const {\n // The breakpoint **start** at this value.\n // For instance with the first breakpoint xs: [xs, sm).\n values = {\n xs: 0,\n // phone\n sm: 600,\n // tablet\n md: 900,\n // small laptop\n lg: 1200,\n // desktop\n xl: 1536 // large screen\n },\n unit = 'px',\n step = 5\n } = breakpoints,\n other = _objectWithoutPropertiesLoose(breakpoints, _excluded);\n const sortedValues = sortBreakpointsValues(values);\n const keys = Object.keys(sortedValues);\n function up(key) {\n const value = typeof values[key] === 'number' ? values[key] : key;\n return `@media (min-width:${value}${unit})`;\n }\n function down(key) {\n const value = typeof values[key] === 'number' ? values[key] : key;\n return `@media (max-width:${value - step / 100}${unit})`;\n }\n function between(start, end) {\n const endIndex = keys.indexOf(end);\n return `@media (min-width:${typeof values[start] === 'number' ? values[start] : start}${unit}) and ` + `(max-width:${(endIndex !== -1 && typeof values[keys[endIndex]] === 'number' ? values[keys[endIndex]] : end) - step / 100}${unit})`;\n }\n function only(key) {\n if (keys.indexOf(key) + 1 < keys.length) {\n return between(key, keys[keys.indexOf(key) + 1]);\n }\n return up(key);\n }\n function not(key) {\n // handle first and last key separately, for better readability\n const keyIndex = keys.indexOf(key);\n if (keyIndex === 0) {\n return up(keys[1]);\n }\n if (keyIndex === keys.length - 1) {\n return down(keys[keyIndex]);\n }\n return between(key, keys[keys.indexOf(key) + 1]).replace('@media', '@media not all and');\n }\n return _extends({\n keys,\n values: sortedValues,\n up,\n down,\n between,\n only,\n not,\n unit\n }, other);\n}","const shape = {\n borderRadius: 4\n};\nexport default shape;","import PropTypes from 'prop-types';\nconst responsivePropType = process.env.NODE_ENV !== 'production' ? PropTypes.oneOfType([PropTypes.number, PropTypes.string, PropTypes.object, PropTypes.array]) : {};\nexport default responsivePropType;","import deepmerge from '@mui/utils/deepmerge';\nfunction merge(acc, item) {\n if (!item) {\n return acc;\n }\n return deepmerge(acc, item, {\n clone: false // No need to clone deep, it's way faster.\n });\n}\nexport default merge;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport PropTypes from 'prop-types';\nimport deepmerge from '@mui/utils/deepmerge';\nimport merge from './merge';\n\n// The breakpoint **start** at this value.\n// For instance with the first breakpoint xs: [xs, sm[.\nexport const values = {\n xs: 0,\n // phone\n sm: 600,\n // tablet\n md: 900,\n // small laptop\n lg: 1200,\n // desktop\n xl: 1536 // large screen\n};\nconst defaultBreakpoints = {\n // Sorted ASC by size. That's important.\n // It can't be configured as it's used statically for propTypes.\n keys: ['xs', 'sm', 'md', 'lg', 'xl'],\n up: key => `@media (min-width:${values[key]}px)`\n};\nexport function handleBreakpoints(props, propValue, styleFromPropValue) {\n const theme = props.theme || {};\n if (Array.isArray(propValue)) {\n const themeBreakpoints = theme.breakpoints || defaultBreakpoints;\n return propValue.reduce((acc, item, index) => {\n acc[themeBreakpoints.up(themeBreakpoints.keys[index])] = styleFromPropValue(propValue[index]);\n return acc;\n }, {});\n }\n if (typeof propValue === 'object') {\n const themeBreakpoints = theme.breakpoints || defaultBreakpoints;\n return Object.keys(propValue).reduce((acc, breakpoint) => {\n // key is breakpoint\n if (Object.keys(themeBreakpoints.values || values).indexOf(breakpoint) !== -1) {\n const mediaKey = themeBreakpoints.up(breakpoint);\n acc[mediaKey] = styleFromPropValue(propValue[breakpoint], breakpoint);\n } else {\n const cssKey = breakpoint;\n acc[cssKey] = propValue[cssKey];\n }\n return acc;\n }, {});\n }\n const output = styleFromPropValue(propValue);\n return output;\n}\nfunction breakpoints(styleFunction) {\n // false positive\n // eslint-disable-next-line react/function-component-definition\n const newStyleFunction = props => {\n const theme = props.theme || {};\n const base = styleFunction(props);\n const themeBreakpoints = theme.breakpoints || defaultBreakpoints;\n const extended = themeBreakpoints.keys.reduce((acc, key) => {\n if (props[key]) {\n acc = acc || {};\n acc[themeBreakpoints.up(key)] = styleFunction(_extends({\n theme\n }, props[key]));\n }\n return acc;\n }, null);\n return merge(base, extended);\n };\n newStyleFunction.propTypes = process.env.NODE_ENV !== 'production' ? _extends({}, styleFunction.propTypes, {\n xs: PropTypes.object,\n sm: PropTypes.object,\n md: PropTypes.object,\n lg: PropTypes.object,\n xl: PropTypes.object\n }) : {};\n newStyleFunction.filterProps = ['xs', 'sm', 'md', 'lg', 'xl', ...styleFunction.filterProps];\n return newStyleFunction;\n}\nexport function createEmptyBreakpointObject(breakpointsInput = {}) {\n var _breakpointsInput$key;\n const breakpointsInOrder = (_breakpointsInput$key = breakpointsInput.keys) == null ? void 0 : _breakpointsInput$key.reduce((acc, key) => {\n const breakpointStyleKey = breakpointsInput.up(key);\n acc[breakpointStyleKey] = {};\n return acc;\n }, {});\n return breakpointsInOrder || {};\n}\nexport function removeUnusedBreakpoints(breakpointKeys, style) {\n return breakpointKeys.reduce((acc, key) => {\n const breakpointOutput = acc[key];\n const isBreakpointUnused = !breakpointOutput || Object.keys(breakpointOutput).length === 0;\n if (isBreakpointUnused) {\n delete acc[key];\n }\n return acc;\n }, style);\n}\nexport function mergeBreakpointsInOrder(breakpointsInput, ...styles) {\n const emptyBreakpoints = createEmptyBreakpointObject(breakpointsInput);\n const mergedOutput = [emptyBreakpoints, ...styles].reduce((prev, next) => deepmerge(prev, next), {});\n return removeUnusedBreakpoints(Object.keys(emptyBreakpoints), mergedOutput);\n}\n\n// compute base for responsive values; e.g.,\n// [1,2,3] => {xs: true, sm: true, md: true}\n// {xs: 1, sm: 2, md: 3} => {xs: true, sm: true, md: true}\nexport function computeBreakpointsBase(breakpointValues, themeBreakpoints) {\n // fixed value\n if (typeof breakpointValues !== 'object') {\n return {};\n }\n const base = {};\n const breakpointsKeys = Object.keys(themeBreakpoints);\n if (Array.isArray(breakpointValues)) {\n breakpointsKeys.forEach((breakpoint, i) => {\n if (i < breakpointValues.length) {\n base[breakpoint] = true;\n }\n });\n } else {\n breakpointsKeys.forEach(breakpoint => {\n if (breakpointValues[breakpoint] != null) {\n base[breakpoint] = true;\n }\n });\n }\n return base;\n}\nexport function resolveBreakpointValues({\n values: breakpointValues,\n breakpoints: themeBreakpoints,\n base: customBase\n}) {\n const base = customBase || computeBreakpointsBase(breakpointValues, themeBreakpoints);\n const keys = Object.keys(base);\n if (keys.length === 0) {\n return breakpointValues;\n }\n let previous;\n return keys.reduce((acc, breakpoint, i) => {\n if (Array.isArray(breakpointValues)) {\n acc[breakpoint] = breakpointValues[i] != null ? breakpointValues[i] : breakpointValues[previous];\n previous = i;\n } else if (typeof breakpointValues === 'object') {\n acc[breakpoint] = breakpointValues[breakpoint] != null ? breakpointValues[breakpoint] : breakpointValues[previous];\n previous = breakpoint;\n } else {\n acc[breakpoint] = breakpointValues;\n }\n return acc;\n }, {});\n}\nexport default breakpoints;","import capitalize from '@mui/utils/capitalize';\nimport responsivePropType from './responsivePropType';\nimport { handleBreakpoints } from './breakpoints';\nexport function getPath(obj, path, checkVars = true) {\n if (!path || typeof path !== 'string') {\n return null;\n }\n\n // Check if CSS variables are used\n if (obj && obj.vars && checkVars) {\n const val = `vars.${path}`.split('.').reduce((acc, item) => acc && acc[item] ? acc[item] : null, obj);\n if (val != null) {\n return val;\n }\n }\n return path.split('.').reduce((acc, item) => {\n if (acc && acc[item] != null) {\n return acc[item];\n }\n return null;\n }, obj);\n}\nexport function getStyleValue(themeMapping, transform, propValueFinal, userValue = propValueFinal) {\n let value;\n if (typeof themeMapping === 'function') {\n value = themeMapping(propValueFinal);\n } else if (Array.isArray(themeMapping)) {\n value = themeMapping[propValueFinal] || userValue;\n } else {\n value = getPath(themeMapping, propValueFinal) || userValue;\n }\n if (transform) {\n value = transform(value, userValue, themeMapping);\n }\n return value;\n}\nfunction style(options) {\n const {\n prop,\n cssProperty = options.prop,\n themeKey,\n transform\n } = options;\n\n // false positive\n // eslint-disable-next-line react/function-component-definition\n const fn = props => {\n if (props[prop] == null) {\n return null;\n }\n const propValue = props[prop];\n const theme = props.theme;\n const themeMapping = getPath(theme, themeKey) || {};\n const styleFromPropValue = propValueFinal => {\n let value = getStyleValue(themeMapping, transform, propValueFinal);\n if (propValueFinal === value && typeof propValueFinal === 'string') {\n // Haven't found value\n value = getStyleValue(themeMapping, transform, `${prop}${propValueFinal === 'default' ? '' : capitalize(propValueFinal)}`, propValueFinal);\n }\n if (cssProperty === false) {\n return value;\n }\n return {\n [cssProperty]: value\n };\n };\n return handleBreakpoints(props, propValue, styleFromPropValue);\n };\n fn.propTypes = process.env.NODE_ENV !== 'production' ? {\n [prop]: responsivePropType\n } : {};\n fn.filterProps = [prop];\n return fn;\n}\nexport default style;","export default function memoize(fn) {\n const cache = {};\n return arg => {\n if (cache[arg] === undefined) {\n cache[arg] = fn(arg);\n }\n return cache[arg];\n };\n}","import responsivePropType from './responsivePropType';\nimport { handleBreakpoints } from './breakpoints';\nimport { getPath } from './style';\nimport merge from './merge';\nimport memoize from './memoize';\nconst properties = {\n m: 'margin',\n p: 'padding'\n};\nconst directions = {\n t: 'Top',\n r: 'Right',\n b: 'Bottom',\n l: 'Left',\n x: ['Left', 'Right'],\n y: ['Top', 'Bottom']\n};\nconst aliases = {\n marginX: 'mx',\n marginY: 'my',\n paddingX: 'px',\n paddingY: 'py'\n};\n\n// memoize() impact:\n// From 300,000 ops/sec\n// To 350,000 ops/sec\nconst getCssProperties = memoize(prop => {\n // It's not a shorthand notation.\n if (prop.length > 2) {\n if (aliases[prop]) {\n prop = aliases[prop];\n } else {\n return [prop];\n }\n }\n const [a, b] = prop.split('');\n const property = properties[a];\n const direction = directions[b] || '';\n return Array.isArray(direction) ? direction.map(dir => property + dir) : [property + direction];\n});\nexport const marginKeys = ['m', 'mt', 'mr', 'mb', 'ml', 'mx', 'my', 'margin', 'marginTop', 'marginRight', 'marginBottom', 'marginLeft', 'marginX', 'marginY', 'marginInline', 'marginInlineStart', 'marginInlineEnd', 'marginBlock', 'marginBlockStart', 'marginBlockEnd'];\nexport const paddingKeys = ['p', 'pt', 'pr', 'pb', 'pl', 'px', 'py', 'padding', 'paddingTop', 'paddingRight', 'paddingBottom', 'paddingLeft', 'paddingX', 'paddingY', 'paddingInline', 'paddingInlineStart', 'paddingInlineEnd', 'paddingBlock', 'paddingBlockStart', 'paddingBlockEnd'];\nconst spacingKeys = [...marginKeys, ...paddingKeys];\nexport function createUnaryUnit(theme, themeKey, defaultValue, propName) {\n var _getPath;\n const themeSpacing = (_getPath = getPath(theme, themeKey, false)) != null ? _getPath : defaultValue;\n if (typeof themeSpacing === 'number') {\n return abs => {\n if (typeof abs === 'string') {\n return abs;\n }\n if (process.env.NODE_ENV !== 'production') {\n if (typeof abs !== 'number') {\n console.error(`MUI: Expected ${propName} argument to be a number or a string, got ${abs}.`);\n }\n }\n return themeSpacing * abs;\n };\n }\n if (Array.isArray(themeSpacing)) {\n return abs => {\n if (typeof abs === 'string') {\n return abs;\n }\n if (process.env.NODE_ENV !== 'production') {\n if (!Number.isInteger(abs)) {\n console.error([`MUI: The \\`theme.${themeKey}\\` array type cannot be combined with non integer values.` + `You should either use an integer value that can be used as index, or define the \\`theme.${themeKey}\\` as a number.`].join('\\n'));\n } else if (abs > themeSpacing.length - 1) {\n console.error([`MUI: The value provided (${abs}) overflows.`, `The supported values are: ${JSON.stringify(themeSpacing)}.`, `${abs} > ${themeSpacing.length - 1}, you need to add the missing values.`].join('\\n'));\n }\n }\n return themeSpacing[abs];\n };\n }\n if (typeof themeSpacing === 'function') {\n return themeSpacing;\n }\n if (process.env.NODE_ENV !== 'production') {\n console.error([`MUI: The \\`theme.${themeKey}\\` value (${themeSpacing}) is invalid.`, 'It should be a number, an array or a function.'].join('\\n'));\n }\n return () => undefined;\n}\nexport function createUnarySpacing(theme) {\n return createUnaryUnit(theme, 'spacing', 8, 'spacing');\n}\nexport function getValue(transformer, propValue) {\n if (typeof propValue === 'string' || propValue == null) {\n return propValue;\n }\n const abs = Math.abs(propValue);\n const transformed = transformer(abs);\n if (propValue >= 0) {\n return transformed;\n }\n if (typeof transformed === 'number') {\n return -transformed;\n }\n return `-${transformed}`;\n}\nexport function getStyleFromPropValue(cssProperties, transformer) {\n return propValue => cssProperties.reduce((acc, cssProperty) => {\n acc[cssProperty] = getValue(transformer, propValue);\n return acc;\n }, {});\n}\nfunction resolveCssProperty(props, keys, prop, transformer) {\n // Using a hash computation over an array iteration could be faster, but with only 28 items,\n // it's doesn't worth the bundle size.\n if (keys.indexOf(prop) === -1) {\n return null;\n }\n const cssProperties = getCssProperties(prop);\n const styleFromPropValue = getStyleFromPropValue(cssProperties, transformer);\n const propValue = props[prop];\n return handleBreakpoints(props, propValue, styleFromPropValue);\n}\nfunction style(props, keys) {\n const transformer = createUnarySpacing(props.theme);\n return Object.keys(props).map(prop => resolveCssProperty(props, keys, prop, transformer)).reduce(merge, {});\n}\nexport function margin(props) {\n return style(props, marginKeys);\n}\nmargin.propTypes = process.env.NODE_ENV !== 'production' ? marginKeys.reduce((obj, key) => {\n obj[key] = responsivePropType;\n return obj;\n}, {}) : {};\nmargin.filterProps = marginKeys;\nexport function padding(props) {\n return style(props, paddingKeys);\n}\npadding.propTypes = process.env.NODE_ENV !== 'production' ? paddingKeys.reduce((obj, key) => {\n obj[key] = responsivePropType;\n return obj;\n}, {}) : {};\npadding.filterProps = paddingKeys;\nfunction spacing(props) {\n return style(props, spacingKeys);\n}\nspacing.propTypes = process.env.NODE_ENV !== 'production' ? spacingKeys.reduce((obj, key) => {\n obj[key] = responsivePropType;\n return obj;\n}, {}) : {};\nspacing.filterProps = spacingKeys;\nexport default spacing;","import { createUnarySpacing } from '../spacing';\n\n// The different signatures imply different meaning for their arguments that can't be expressed structurally.\n// We express the difference with variable names.\n\nexport default function createSpacing(spacingInput = 8) {\n // Already transformed.\n if (spacingInput.mui) {\n return spacingInput;\n }\n\n // Material Design layouts are visually balanced. Most measurements align to an 8dp grid, which aligns both spacing and the overall layout.\n // Smaller components, such as icons, can align to a 4dp grid.\n // https://m2.material.io/design/layout/understanding-layout.html\n const transform = createUnarySpacing({\n spacing: spacingInput\n });\n const spacing = (...argsInput) => {\n if (process.env.NODE_ENV !== 'production') {\n if (!(argsInput.length <= 4)) {\n console.error(`MUI: Too many arguments provided, expected between 0 and 4, got ${argsInput.length}`);\n }\n }\n const args = argsInput.length === 0 ? [1] : argsInput;\n return args.map(argument => {\n const output = transform(argument);\n return typeof output === 'number' ? `${output}px` : output;\n }).join(' ');\n };\n spacing.mui = true;\n return spacing;\n}","import merge from './merge';\nfunction compose(...styles) {\n const handlers = styles.reduce((acc, style) => {\n style.filterProps.forEach(prop => {\n acc[prop] = style;\n });\n return acc;\n }, {});\n\n // false positive\n // eslint-disable-next-line react/function-component-definition\n const fn = props => {\n return Object.keys(props).reduce((acc, prop) => {\n if (handlers[prop]) {\n return merge(acc, handlers[prop](props));\n }\n return acc;\n }, {});\n };\n fn.propTypes = process.env.NODE_ENV !== 'production' ? styles.reduce((acc, style) => Object.assign(acc, style.propTypes), {}) : {};\n fn.filterProps = styles.reduce((acc, style) => acc.concat(style.filterProps), []);\n return fn;\n}\nexport default compose;","import responsivePropType from './responsivePropType';\nimport style from './style';\nimport compose from './compose';\nimport { createUnaryUnit, getValue } from './spacing';\nimport { handleBreakpoints } from './breakpoints';\nexport function borderTransform(value) {\n if (typeof value !== 'number') {\n return value;\n }\n return `${value}px solid`;\n}\nfunction createBorderStyle(prop, transform) {\n return style({\n prop,\n themeKey: 'borders',\n transform\n });\n}\nexport const border = createBorderStyle('border', borderTransform);\nexport const borderTop = createBorderStyle('borderTop', borderTransform);\nexport const borderRight = createBorderStyle('borderRight', borderTransform);\nexport const borderBottom = createBorderStyle('borderBottom', borderTransform);\nexport const borderLeft = createBorderStyle('borderLeft', borderTransform);\nexport const borderColor = createBorderStyle('borderColor');\nexport const borderTopColor = createBorderStyle('borderTopColor');\nexport const borderRightColor = createBorderStyle('borderRightColor');\nexport const borderBottomColor = createBorderStyle('borderBottomColor');\nexport const borderLeftColor = createBorderStyle('borderLeftColor');\nexport const outline = createBorderStyle('outline', borderTransform);\nexport const outlineColor = createBorderStyle('outlineColor');\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const borderRadius = props => {\n if (props.borderRadius !== undefined && props.borderRadius !== null) {\n const transformer = createUnaryUnit(props.theme, 'shape.borderRadius', 4, 'borderRadius');\n const styleFromPropValue = propValue => ({\n borderRadius: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.borderRadius, styleFromPropValue);\n }\n return null;\n};\nborderRadius.propTypes = process.env.NODE_ENV !== 'production' ? {\n borderRadius: responsivePropType\n} : {};\nborderRadius.filterProps = ['borderRadius'];\nconst borders = compose(border, borderTop, borderRight, borderBottom, borderLeft, borderColor, borderTopColor, borderRightColor, borderBottomColor, borderLeftColor, borderRadius, outline, outlineColor);\nexport default borders;","import style from './style';\nimport compose from './compose';\nimport { createUnaryUnit, getValue } from './spacing';\nimport { handleBreakpoints } from './breakpoints';\nimport responsivePropType from './responsivePropType';\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const gap = props => {\n if (props.gap !== undefined && props.gap !== null) {\n const transformer = createUnaryUnit(props.theme, 'spacing', 8, 'gap');\n const styleFromPropValue = propValue => ({\n gap: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.gap, styleFromPropValue);\n }\n return null;\n};\ngap.propTypes = process.env.NODE_ENV !== 'production' ? {\n gap: responsivePropType\n} : {};\ngap.filterProps = ['gap'];\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const columnGap = props => {\n if (props.columnGap !== undefined && props.columnGap !== null) {\n const transformer = createUnaryUnit(props.theme, 'spacing', 8, 'columnGap');\n const styleFromPropValue = propValue => ({\n columnGap: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.columnGap, styleFromPropValue);\n }\n return null;\n};\ncolumnGap.propTypes = process.env.NODE_ENV !== 'production' ? {\n columnGap: responsivePropType\n} : {};\ncolumnGap.filterProps = ['columnGap'];\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const rowGap = props => {\n if (props.rowGap !== undefined && props.rowGap !== null) {\n const transformer = createUnaryUnit(props.theme, 'spacing', 8, 'rowGap');\n const styleFromPropValue = propValue => ({\n rowGap: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.rowGap, styleFromPropValue);\n }\n return null;\n};\nrowGap.propTypes = process.env.NODE_ENV !== 'production' ? {\n rowGap: responsivePropType\n} : {};\nrowGap.filterProps = ['rowGap'];\nexport const gridColumn = style({\n prop: 'gridColumn'\n});\nexport const gridRow = style({\n prop: 'gridRow'\n});\nexport const gridAutoFlow = style({\n prop: 'gridAutoFlow'\n});\nexport const gridAutoColumns = style({\n prop: 'gridAutoColumns'\n});\nexport const gridAutoRows = style({\n prop: 'gridAutoRows'\n});\nexport const gridTemplateColumns = style({\n prop: 'gridTemplateColumns'\n});\nexport const gridTemplateRows = style({\n prop: 'gridTemplateRows'\n});\nexport const gridTemplateAreas = style({\n prop: 'gridTemplateAreas'\n});\nexport const gridArea = style({\n prop: 'gridArea'\n});\nconst grid = compose(gap, columnGap, rowGap, gridColumn, gridRow, gridAutoFlow, gridAutoColumns, gridAutoRows, gridTemplateColumns, gridTemplateRows, gridTemplateAreas, gridArea);\nexport default grid;","import style from './style';\nimport compose from './compose';\nexport function paletteTransform(value, userValue) {\n if (userValue === 'grey') {\n return userValue;\n }\n return value;\n}\nexport const color = style({\n prop: 'color',\n themeKey: 'palette',\n transform: paletteTransform\n});\nexport const bgcolor = style({\n prop: 'bgcolor',\n cssProperty: 'backgroundColor',\n themeKey: 'palette',\n transform: paletteTransform\n});\nexport const backgroundColor = style({\n prop: 'backgroundColor',\n themeKey: 'palette',\n transform: paletteTransform\n});\nconst palette = compose(color, bgcolor, backgroundColor);\nexport default palette;","import style from './style';\nimport compose from './compose';\nimport { handleBreakpoints, values as breakpointsValues } from './breakpoints';\nexport function sizingTransform(value) {\n return value <= 1 && value !== 0 ? `${value * 100}%` : value;\n}\nexport const width = style({\n prop: 'width',\n transform: sizingTransform\n});\nexport const maxWidth = props => {\n if (props.maxWidth !== undefined && props.maxWidth !== null) {\n const styleFromPropValue = propValue => {\n var _props$theme, _props$theme2;\n const breakpoint = ((_props$theme = props.theme) == null || (_props$theme = _props$theme.breakpoints) == null || (_props$theme = _props$theme.values) == null ? void 0 : _props$theme[propValue]) || breakpointsValues[propValue];\n if (!breakpoint) {\n return {\n maxWidth: sizingTransform(propValue)\n };\n }\n if (((_props$theme2 = props.theme) == null || (_props$theme2 = _props$theme2.breakpoints) == null ? void 0 : _props$theme2.unit) !== 'px') {\n return {\n maxWidth: `${breakpoint}${props.theme.breakpoints.unit}`\n };\n }\n return {\n maxWidth: breakpoint\n };\n };\n return handleBreakpoints(props, props.maxWidth, styleFromPropValue);\n }\n return null;\n};\nmaxWidth.filterProps = ['maxWidth'];\nexport const minWidth = style({\n prop: 'minWidth',\n transform: sizingTransform\n});\nexport const height = style({\n prop: 'height',\n transform: sizingTransform\n});\nexport const maxHeight = style({\n prop: 'maxHeight',\n transform: sizingTransform\n});\nexport const minHeight = style({\n prop: 'minHeight',\n transform: sizingTransform\n});\nexport const sizeWidth = style({\n prop: 'size',\n cssProperty: 'width',\n transform: sizingTransform\n});\nexport const sizeHeight = style({\n prop: 'size',\n cssProperty: 'height',\n transform: sizingTransform\n});\nexport const boxSizing = style({\n prop: 'boxSizing'\n});\nconst sizing = compose(width, maxWidth, minWidth, height, maxHeight, minHeight, boxSizing);\nexport default sizing;","import { padding, margin } from '../spacing';\nimport { borderRadius, borderTransform } from '../borders';\nimport { gap, rowGap, columnGap } from '../cssGrid';\nimport { paletteTransform } from '../palette';\nimport { maxWidth, sizingTransform } from '../sizing';\nconst defaultSxConfig = {\n // borders\n border: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderTop: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderRight: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderBottom: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderLeft: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderColor: {\n themeKey: 'palette'\n },\n borderTopColor: {\n themeKey: 'palette'\n },\n borderRightColor: {\n themeKey: 'palette'\n },\n borderBottomColor: {\n themeKey: 'palette'\n },\n borderLeftColor: {\n themeKey: 'palette'\n },\n outline: {\n themeKey: 'borders',\n transform: borderTransform\n },\n outlineColor: {\n themeKey: 'palette'\n },\n borderRadius: {\n themeKey: 'shape.borderRadius',\n style: borderRadius\n },\n // palette\n color: {\n themeKey: 'palette',\n transform: paletteTransform\n },\n bgcolor: {\n themeKey: 'palette',\n cssProperty: 'backgroundColor',\n transform: paletteTransform\n },\n backgroundColor: {\n themeKey: 'palette',\n transform: paletteTransform\n },\n // spacing\n p: {\n style: padding\n },\n pt: {\n style: padding\n },\n pr: {\n style: padding\n },\n pb: {\n style: padding\n },\n pl: {\n style: padding\n },\n px: {\n style: padding\n },\n py: {\n style: padding\n },\n padding: {\n style: padding\n },\n paddingTop: {\n style: padding\n },\n paddingRight: {\n style: padding\n },\n paddingBottom: {\n style: padding\n },\n paddingLeft: {\n style: padding\n },\n paddingX: {\n style: padding\n },\n paddingY: {\n style: padding\n },\n paddingInline: {\n style: padding\n },\n paddingInlineStart: {\n style: padding\n },\n paddingInlineEnd: {\n style: padding\n },\n paddingBlock: {\n style: padding\n },\n paddingBlockStart: {\n style: padding\n },\n paddingBlockEnd: {\n style: padding\n },\n m: {\n style: margin\n },\n mt: {\n style: margin\n },\n mr: {\n style: margin\n },\n mb: {\n style: margin\n },\n ml: {\n style: margin\n },\n mx: {\n style: margin\n },\n my: {\n style: margin\n },\n margin: {\n style: margin\n },\n marginTop: {\n style: margin\n },\n marginRight: {\n style: margin\n },\n marginBottom: {\n style: margin\n },\n marginLeft: {\n style: margin\n },\n marginX: {\n style: margin\n },\n marginY: {\n style: margin\n },\n marginInline: {\n style: margin\n },\n marginInlineStart: {\n style: margin\n },\n marginInlineEnd: {\n style: margin\n },\n marginBlock: {\n style: margin\n },\n marginBlockStart: {\n style: margin\n },\n marginBlockEnd: {\n style: margin\n },\n // display\n displayPrint: {\n cssProperty: false,\n transform: value => ({\n '@media print': {\n display: value\n }\n })\n },\n display: {},\n overflow: {},\n textOverflow: {},\n visibility: {},\n whiteSpace: {},\n // flexbox\n flexBasis: {},\n flexDirection: {},\n flexWrap: {},\n justifyContent: {},\n alignItems: {},\n alignContent: {},\n order: {},\n flex: {},\n flexGrow: {},\n flexShrink: {},\n alignSelf: {},\n justifyItems: {},\n justifySelf: {},\n // grid\n gap: {\n style: gap\n },\n rowGap: {\n style: rowGap\n },\n columnGap: {\n style: columnGap\n },\n gridColumn: {},\n gridRow: {},\n gridAutoFlow: {},\n gridAutoColumns: {},\n gridAutoRows: {},\n gridTemplateColumns: {},\n gridTemplateRows: {},\n gridTemplateAreas: {},\n gridArea: {},\n // positions\n position: {},\n zIndex: {\n themeKey: 'zIndex'\n },\n top: {},\n right: {},\n bottom: {},\n left: {},\n // shadows\n boxShadow: {\n themeKey: 'shadows'\n },\n // sizing\n width: {\n transform: sizingTransform\n },\n maxWidth: {\n style: maxWidth\n },\n minWidth: {\n transform: sizingTransform\n },\n height: {\n transform: sizingTransform\n },\n maxHeight: {\n transform: sizingTransform\n },\n minHeight: {\n transform: sizingTransform\n },\n boxSizing: {},\n // typography\n fontFamily: {\n themeKey: 'typography'\n },\n fontSize: {\n themeKey: 'typography'\n },\n fontStyle: {\n themeKey: 'typography'\n },\n fontWeight: {\n themeKey: 'typography'\n },\n letterSpacing: {},\n textTransform: {},\n lineHeight: {},\n textAlign: {},\n typography: {\n cssProperty: false,\n themeKey: 'typography'\n }\n};\nexport default defaultSxConfig;","import capitalize from '@mui/utils/capitalize';\nimport merge from '../merge';\nimport { getPath, getStyleValue as getValue } from '../style';\nimport { handleBreakpoints, createEmptyBreakpointObject, removeUnusedBreakpoints } from '../breakpoints';\nimport defaultSxConfig from './defaultSxConfig';\nfunction objectsHaveSameKeys(...objects) {\n const allKeys = objects.reduce((keys, object) => keys.concat(Object.keys(object)), []);\n const union = new Set(allKeys);\n return objects.every(object => union.size === Object.keys(object).length);\n}\nfunction callIfFn(maybeFn, arg) {\n return typeof maybeFn === 'function' ? maybeFn(arg) : maybeFn;\n}\n\n// eslint-disable-next-line @typescript-eslint/naming-convention\nexport function unstable_createStyleFunctionSx() {\n function getThemeValue(prop, val, theme, config) {\n const props = {\n [prop]: val,\n theme\n };\n const options = config[prop];\n if (!options) {\n return {\n [prop]: val\n };\n }\n const {\n cssProperty = prop,\n themeKey,\n transform,\n style\n } = options;\n if (val == null) {\n return null;\n }\n\n // TODO v6: remove, see https://github.com/mui/material-ui/pull/38123\n if (themeKey === 'typography' && val === 'inherit') {\n return {\n [prop]: val\n };\n }\n const themeMapping = getPath(theme, themeKey) || {};\n if (style) {\n return style(props);\n }\n const styleFromPropValue = propValueFinal => {\n let value = getValue(themeMapping, transform, propValueFinal);\n if (propValueFinal === value && typeof propValueFinal === 'string') {\n // Haven't found value\n value = getValue(themeMapping, transform, `${prop}${propValueFinal === 'default' ? '' : capitalize(propValueFinal)}`, propValueFinal);\n }\n if (cssProperty === false) {\n return value;\n }\n return {\n [cssProperty]: value\n };\n };\n return handleBreakpoints(props, val, styleFromPropValue);\n }\n function styleFunctionSx(props) {\n var _theme$unstable_sxCon;\n const {\n sx,\n theme = {}\n } = props || {};\n if (!sx) {\n return null; // Emotion & styled-components will neglect null\n }\n const config = (_theme$unstable_sxCon = theme.unstable_sxConfig) != null ? _theme$unstable_sxCon : defaultSxConfig;\n\n /*\n * Receive `sxInput` as object or callback\n * and then recursively check keys & values to create media query object styles.\n * (the result will be used in `styled`)\n */\n function traverse(sxInput) {\n let sxObject = sxInput;\n if (typeof sxInput === 'function') {\n sxObject = sxInput(theme);\n } else if (typeof sxInput !== 'object') {\n // value\n return sxInput;\n }\n if (!sxObject) {\n return null;\n }\n const emptyBreakpoints = createEmptyBreakpointObject(theme.breakpoints);\n const breakpointsKeys = Object.keys(emptyBreakpoints);\n let css = emptyBreakpoints;\n Object.keys(sxObject).forEach(styleKey => {\n const value = callIfFn(sxObject[styleKey], theme);\n if (value !== null && value !== undefined) {\n if (typeof value === 'object') {\n if (config[styleKey]) {\n css = merge(css, getThemeValue(styleKey, value, theme, config));\n } else {\n const breakpointsValues = handleBreakpoints({\n theme\n }, value, x => ({\n [styleKey]: x\n }));\n if (objectsHaveSameKeys(breakpointsValues, value)) {\n css[styleKey] = styleFunctionSx({\n sx: value,\n theme\n });\n } else {\n css = merge(css, breakpointsValues);\n }\n }\n } else {\n css = merge(css, getThemeValue(styleKey, value, theme, config));\n }\n }\n });\n return removeUnusedBreakpoints(breakpointsKeys, css);\n }\n return Array.isArray(sx) ? sx.map(traverse) : traverse(sx);\n }\n return styleFunctionSx;\n}\nconst styleFunctionSx = unstable_createStyleFunctionSx();\nstyleFunctionSx.filterProps = ['sx'];\nexport default styleFunctionSx;","/**\n * A universal utility to style components with multiple color modes. Always use it from the theme object.\n * It works with:\n * - [Basic theme](https://mui.com/material-ui/customization/dark-mode/)\n * - [CSS theme variables](https://mui.com/material-ui/experimental-api/css-theme-variables/overview/)\n * - Zero-runtime engine\n *\n * Tips: Use an array over object spread and place `theme.applyStyles()` last.\n *\n * ✅ [{ background: '#e5e5e5' }, theme.applyStyles('dark', { background: '#1c1c1c' })]\n *\n * 🚫 { background: '#e5e5e5', ...theme.applyStyles('dark', { background: '#1c1c1c' })}\n *\n * @example\n * 1. using with `styled`:\n * ```jsx\n * const Component = styled('div')(({ theme }) => [\n * { background: '#e5e5e5' },\n * theme.applyStyles('dark', {\n * background: '#1c1c1c',\n * color: '#fff',\n * }),\n * ]);\n * ```\n *\n * @example\n * 2. using with `sx` prop:\n * ```jsx\n * [\n * { background: '#e5e5e5' },\n * theme.applyStyles('dark', {\n * background: '#1c1c1c',\n * color: '#fff',\n * }),\n * ]}\n * />\n * ```\n *\n * @example\n * 3. theming a component:\n * ```jsx\n * extendTheme({\n * components: {\n * MuiButton: {\n * styleOverrides: {\n * root: ({ theme }) => [\n * { background: '#e5e5e5' },\n * theme.applyStyles('dark', {\n * background: '#1c1c1c',\n * color: '#fff',\n * }),\n * ],\n * },\n * }\n * }\n * })\n *```\n */\nexport default function applyStyles(key, styles) {\n // @ts-expect-error this is 'any' type\n const theme = this;\n if (theme.vars && typeof theme.getColorSchemeSelector === 'function') {\n // If CssVarsProvider is used as a provider,\n // returns '* :where([data-mui-color-scheme=\"light|dark\"]) &'\n const selector = theme.getColorSchemeSelector(key).replace(/(\\[[^\\]]+\\])/, '*:where($1)');\n return {\n [selector]: styles\n };\n }\n if (theme.palette.mode === key) {\n return styles;\n }\n return {};\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"breakpoints\", \"palette\", \"spacing\", \"shape\"];\nimport deepmerge from '@mui/utils/deepmerge';\nimport createBreakpoints from './createBreakpoints';\nimport shape from './shape';\nimport createSpacing from './createSpacing';\nimport styleFunctionSx from '../styleFunctionSx/styleFunctionSx';\nimport defaultSxConfig from '../styleFunctionSx/defaultSxConfig';\nimport applyStyles from './applyStyles';\nfunction createTheme(options = {}, ...args) {\n const {\n breakpoints: breakpointsInput = {},\n palette: paletteInput = {},\n spacing: spacingInput,\n shape: shapeInput = {}\n } = options,\n other = _objectWithoutPropertiesLoose(options, _excluded);\n const breakpoints = createBreakpoints(breakpointsInput);\n const spacing = createSpacing(spacingInput);\n let muiTheme = deepmerge({\n breakpoints,\n direction: 'ltr',\n components: {},\n // Inject component definitions.\n palette: _extends({\n mode: 'light'\n }, paletteInput),\n spacing,\n shape: _extends({}, shape, shapeInput)\n }, other);\n muiTheme.applyStyles = applyStyles;\n muiTheme = args.reduce((acc, argument) => deepmerge(acc, argument), muiTheme);\n muiTheme.unstable_sxConfig = _extends({}, defaultSxConfig, other == null ? void 0 : other.unstable_sxConfig);\n muiTheme.unstable_sx = function sx(props) {\n return styleFunctionSx({\n sx: props,\n theme: this\n });\n };\n return muiTheme;\n}\nexport default createTheme;","'use client';\n\nimport * as React from 'react';\nimport { ThemeContext } from '@mui/styled-engine';\nfunction isObjectEmpty(obj) {\n return Object.keys(obj).length === 0;\n}\nfunction useTheme(defaultTheme = null) {\n const contextTheme = React.useContext(ThemeContext);\n return !contextTheme || isObjectEmpty(contextTheme) ? defaultTheme : contextTheme;\n}\nexport default useTheme;","'use client';\n\nimport createTheme from './createTheme';\nimport useThemeWithoutDefault from './useThemeWithoutDefault';\nexport const systemDefaultTheme = createTheme();\nfunction useTheme(defaultTheme = systemDefaultTheme) {\n return useThemeWithoutDefault(defaultTheme);\n}\nexport default useTheme;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"ownerState\"],\n _excluded2 = [\"variants\"],\n _excluded3 = [\"name\", \"slot\", \"skipVariantsResolver\", \"skipSx\", \"overridesResolver\"];\n/* eslint-disable no-underscore-dangle */\nimport styledEngineStyled, { internal_processStyles as processStyles } from '@mui/styled-engine';\nimport { isPlainObject } from '@mui/utils/deepmerge';\nimport capitalize from '@mui/utils/capitalize';\nimport getDisplayName from '@mui/utils/getDisplayName';\nimport createTheme from './createTheme';\nimport styleFunctionSx from './styleFunctionSx';\nfunction isEmpty(obj) {\n return Object.keys(obj).length === 0;\n}\n\n// https://github.com/emotion-js/emotion/blob/26ded6109fcd8ca9875cc2ce4564fee678a3f3c5/packages/styled/src/utils.js#L40\nfunction isStringTag(tag) {\n return typeof tag === 'string' &&\n // 96 is one less than the char code\n // for \"a\" so this is checking that\n // it's a lowercase character\n tag.charCodeAt(0) > 96;\n}\n\n// Update /system/styled/#api in case if this changes\nexport function shouldForwardProp(prop) {\n return prop !== 'ownerState' && prop !== 'theme' && prop !== 'sx' && prop !== 'as';\n}\nexport const systemDefaultTheme = createTheme();\nconst lowercaseFirstLetter = string => {\n if (!string) {\n return string;\n }\n return string.charAt(0).toLowerCase() + string.slice(1);\n};\nfunction resolveTheme({\n defaultTheme,\n theme,\n themeId\n}) {\n return isEmpty(theme) ? defaultTheme : theme[themeId] || theme;\n}\nfunction defaultOverridesResolver(slot) {\n if (!slot) {\n return null;\n }\n return (props, styles) => styles[slot];\n}\nfunction processStyleArg(callableStyle, _ref) {\n let {\n ownerState\n } = _ref,\n props = _objectWithoutPropertiesLoose(_ref, _excluded);\n const resolvedStylesArg = typeof callableStyle === 'function' ? callableStyle(_extends({\n ownerState\n }, props)) : callableStyle;\n if (Array.isArray(resolvedStylesArg)) {\n return resolvedStylesArg.flatMap(resolvedStyle => processStyleArg(resolvedStyle, _extends({\n ownerState\n }, props)));\n }\n if (!!resolvedStylesArg && typeof resolvedStylesArg === 'object' && Array.isArray(resolvedStylesArg.variants)) {\n const {\n variants = []\n } = resolvedStylesArg,\n otherStyles = _objectWithoutPropertiesLoose(resolvedStylesArg, _excluded2);\n let result = otherStyles;\n variants.forEach(variant => {\n let isMatch = true;\n if (typeof variant.props === 'function') {\n isMatch = variant.props(_extends({\n ownerState\n }, props, ownerState));\n } else {\n Object.keys(variant.props).forEach(key => {\n if ((ownerState == null ? void 0 : ownerState[key]) !== variant.props[key] && props[key] !== variant.props[key]) {\n isMatch = false;\n }\n });\n }\n if (isMatch) {\n if (!Array.isArray(result)) {\n result = [result];\n }\n result.push(typeof variant.style === 'function' ? variant.style(_extends({\n ownerState\n }, props, ownerState)) : variant.style);\n }\n });\n return result;\n }\n return resolvedStylesArg;\n}\nexport default function createStyled(input = {}) {\n const {\n themeId,\n defaultTheme = systemDefaultTheme,\n rootShouldForwardProp = shouldForwardProp,\n slotShouldForwardProp = shouldForwardProp\n } = input;\n const systemSx = props => {\n return styleFunctionSx(_extends({}, props, {\n theme: resolveTheme(_extends({}, props, {\n defaultTheme,\n themeId\n }))\n }));\n };\n systemSx.__mui_systemSx = true;\n return (tag, inputOptions = {}) => {\n // Filter out the `sx` style function from the previous styled component to prevent unnecessary styles generated by the composite components.\n processStyles(tag, styles => styles.filter(style => !(style != null && style.__mui_systemSx)));\n const {\n name: componentName,\n slot: componentSlot,\n skipVariantsResolver: inputSkipVariantsResolver,\n skipSx: inputSkipSx,\n // TODO v6: remove `lowercaseFirstLetter()` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n overridesResolver = defaultOverridesResolver(lowercaseFirstLetter(componentSlot))\n } = inputOptions,\n options = _objectWithoutPropertiesLoose(inputOptions, _excluded3);\n\n // if skipVariantsResolver option is defined, take the value, otherwise, true for root and false for other slots.\n const skipVariantsResolver = inputSkipVariantsResolver !== undefined ? inputSkipVariantsResolver :\n // TODO v6: remove `Root` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n componentSlot && componentSlot !== 'Root' && componentSlot !== 'root' || false;\n const skipSx = inputSkipSx || false;\n let label;\n if (process.env.NODE_ENV !== 'production') {\n if (componentName) {\n // TODO v6: remove `lowercaseFirstLetter()` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n label = `${componentName}-${lowercaseFirstLetter(componentSlot || 'Root')}`;\n }\n }\n let shouldForwardPropOption = shouldForwardProp;\n\n // TODO v6: remove `Root` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n if (componentSlot === 'Root' || componentSlot === 'root') {\n shouldForwardPropOption = rootShouldForwardProp;\n } else if (componentSlot) {\n // any other slot specified\n shouldForwardPropOption = slotShouldForwardProp;\n } else if (isStringTag(tag)) {\n // for string (html) tag, preserve the behavior in emotion & styled-components.\n shouldForwardPropOption = undefined;\n }\n const defaultStyledResolver = styledEngineStyled(tag, _extends({\n shouldForwardProp: shouldForwardPropOption,\n label\n }, options));\n const transformStyleArg = stylesArg => {\n // On the server Emotion doesn't use React.forwardRef for creating components, so the created\n // component stays as a function. This condition makes sure that we do not interpolate functions\n // which are basically components used as a selectors.\n if (typeof stylesArg === 'function' && stylesArg.__emotion_real !== stylesArg || isPlainObject(stylesArg)) {\n return props => processStyleArg(stylesArg, _extends({}, props, {\n theme: resolveTheme({\n theme: props.theme,\n defaultTheme,\n themeId\n })\n }));\n }\n return stylesArg;\n };\n const muiStyledResolver = (styleArg, ...expressions) => {\n let transformedStyleArg = transformStyleArg(styleArg);\n const expressionsWithDefaultTheme = expressions ? expressions.map(transformStyleArg) : [];\n if (componentName && overridesResolver) {\n expressionsWithDefaultTheme.push(props => {\n const theme = resolveTheme(_extends({}, props, {\n defaultTheme,\n themeId\n }));\n if (!theme.components || !theme.components[componentName] || !theme.components[componentName].styleOverrides) {\n return null;\n }\n const styleOverrides = theme.components[componentName].styleOverrides;\n const resolvedStyleOverrides = {};\n // TODO: v7 remove iteration and use `resolveStyleArg(styleOverrides[slot])` directly\n Object.entries(styleOverrides).forEach(([slotKey, slotStyle]) => {\n resolvedStyleOverrides[slotKey] = processStyleArg(slotStyle, _extends({}, props, {\n theme\n }));\n });\n return overridesResolver(props, resolvedStyleOverrides);\n });\n }\n if (componentName && !skipVariantsResolver) {\n expressionsWithDefaultTheme.push(props => {\n var _theme$components;\n const theme = resolveTheme(_extends({}, props, {\n defaultTheme,\n themeId\n }));\n const themeVariants = theme == null || (_theme$components = theme.components) == null || (_theme$components = _theme$components[componentName]) == null ? void 0 : _theme$components.variants;\n return processStyleArg({\n variants: themeVariants\n }, _extends({}, props, {\n theme\n }));\n });\n }\n if (!skipSx) {\n expressionsWithDefaultTheme.push(systemSx);\n }\n const numOfCustomFnsApplied = expressionsWithDefaultTheme.length - expressions.length;\n if (Array.isArray(styleArg) && numOfCustomFnsApplied > 0) {\n const placeholders = new Array(numOfCustomFnsApplied).fill('');\n // If the type is array, than we need to add placeholders in the template for the overrides, variants and the sx styles.\n transformedStyleArg = [...styleArg, ...placeholders];\n transformedStyleArg.raw = [...styleArg.raw, ...placeholders];\n }\n const Component = defaultStyledResolver(transformedStyleArg, ...expressionsWithDefaultTheme);\n if (process.env.NODE_ENV !== 'production') {\n let displayName;\n if (componentName) {\n displayName = `${componentName}${capitalize(componentSlot || '')}`;\n }\n if (displayName === undefined) {\n displayName = `Styled(${getDisplayName(tag)})`;\n }\n Component.displayName = displayName;\n }\n if (tag.muiName) {\n Component.muiName = tag.muiName;\n }\n return Component;\n };\n if (defaultStyledResolver.withConfig) {\n muiStyledResolver.withConfig = defaultStyledResolver.withConfig;\n }\n return muiStyledResolver;\n };\n}","import resolveProps from '@mui/utils/resolveProps';\nexport default function getThemeProps(params) {\n const {\n theme,\n name,\n props\n } = params;\n if (!theme || !theme.components || !theme.components[name] || !theme.components[name].defaultProps) {\n return props;\n }\n return resolveProps(theme.components[name].defaultProps, props);\n}","'use client';\n\nimport getThemeProps from './getThemeProps';\nimport useTheme from '../useTheme';\nexport default function useThemeProps({\n props,\n name,\n defaultTheme,\n themeId\n}) {\n let theme = useTheme(defaultTheme);\n if (themeId) {\n theme = theme[themeId] || theme;\n }\n const mergedProps = getThemeProps({\n theme,\n name,\n props\n });\n return mergedProps;\n}","import _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\n/* eslint-disable @typescript-eslint/naming-convention */\nimport clamp from '@mui/utils/clamp';\n/**\n * Returns a number whose value is limited to the given range.\n * @param {number} value The value to be clamped\n * @param {number} min The lower boundary of the output range\n * @param {number} max The upper boundary of the output range\n * @returns {number} A number in the range [min, max]\n */\nfunction clampWrapper(value, min = 0, max = 1) {\n if (process.env.NODE_ENV !== 'production') {\n if (value < min || value > max) {\n console.error(`MUI: The value provided ${value} is out of range [${min}, ${max}].`);\n }\n }\n return clamp(value, min, max);\n}\n\n/**\n * Converts a color from CSS hex format to CSS rgb format.\n * @param {string} color - Hex color, i.e. #nnn or #nnnnnn\n * @returns {string} A CSS rgb color string\n */\nexport function hexToRgb(color) {\n color = color.slice(1);\n const re = new RegExp(`.{1,${color.length >= 6 ? 2 : 1}}`, 'g');\n let colors = color.match(re);\n if (colors && colors[0].length === 1) {\n colors = colors.map(n => n + n);\n }\n return colors ? `rgb${colors.length === 4 ? 'a' : ''}(${colors.map((n, index) => {\n return index < 3 ? parseInt(n, 16) : Math.round(parseInt(n, 16) / 255 * 1000) / 1000;\n }).join(', ')})` : '';\n}\nfunction intToHex(int) {\n const hex = int.toString(16);\n return hex.length === 1 ? `0${hex}` : hex;\n}\n\n/**\n * Returns an object with the type and values of a color.\n *\n * Note: Does not support rgb % values.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @returns {object} - A MUI color object: {type: string, values: number[]}\n */\nexport function decomposeColor(color) {\n // Idempotent\n if (color.type) {\n return color;\n }\n if (color.charAt(0) === '#') {\n return decomposeColor(hexToRgb(color));\n }\n const marker = color.indexOf('(');\n const type = color.substring(0, marker);\n if (['rgb', 'rgba', 'hsl', 'hsla', 'color'].indexOf(type) === -1) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: Unsupported \\`${color}\\` color.\nThe following formats are supported: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color().` : _formatMuiErrorMessage(9, color));\n }\n let values = color.substring(marker + 1, color.length - 1);\n let colorSpace;\n if (type === 'color') {\n values = values.split(' ');\n colorSpace = values.shift();\n if (values.length === 4 && values[3].charAt(0) === '/') {\n values[3] = values[3].slice(1);\n }\n if (['srgb', 'display-p3', 'a98-rgb', 'prophoto-rgb', 'rec-2020'].indexOf(colorSpace) === -1) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: unsupported \\`${colorSpace}\\` color space.\nThe following color spaces are supported: srgb, display-p3, a98-rgb, prophoto-rgb, rec-2020.` : _formatMuiErrorMessage(10, colorSpace));\n }\n } else {\n values = values.split(',');\n }\n values = values.map(value => parseFloat(value));\n return {\n type,\n values,\n colorSpace\n };\n}\n\n/**\n * Returns a channel created from the input color.\n *\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @returns {string} - The channel for the color, that can be used in rgba or hsla colors\n */\nexport const colorChannel = color => {\n const decomposedColor = decomposeColor(color);\n return decomposedColor.values.slice(0, 3).map((val, idx) => decomposedColor.type.indexOf('hsl') !== -1 && idx !== 0 ? `${val}%` : val).join(' ');\n};\nexport const private_safeColorChannel = (color, warning) => {\n try {\n return colorChannel(color);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n};\n\n/**\n * Converts a color object with type and values to a string.\n * @param {object} color - Decomposed color\n * @param {string} color.type - One of: 'rgb', 'rgba', 'hsl', 'hsla', 'color'\n * @param {array} color.values - [n,n,n] or [n,n,n,n]\n * @returns {string} A CSS color string\n */\nexport function recomposeColor(color) {\n const {\n type,\n colorSpace\n } = color;\n let {\n values\n } = color;\n if (type.indexOf('rgb') !== -1) {\n // Only convert the first 3 values to int (i.e. not alpha)\n values = values.map((n, i) => i < 3 ? parseInt(n, 10) : n);\n } else if (type.indexOf('hsl') !== -1) {\n values[1] = `${values[1]}%`;\n values[2] = `${values[2]}%`;\n }\n if (type.indexOf('color') !== -1) {\n values = `${colorSpace} ${values.join(' ')}`;\n } else {\n values = `${values.join(', ')}`;\n }\n return `${type}(${values})`;\n}\n\n/**\n * Converts a color from CSS rgb format to CSS hex format.\n * @param {string} color - RGB color, i.e. rgb(n, n, n)\n * @returns {string} A CSS rgb color string, i.e. #nnnnnn\n */\nexport function rgbToHex(color) {\n // Idempotent\n if (color.indexOf('#') === 0) {\n return color;\n }\n const {\n values\n } = decomposeColor(color);\n return `#${values.map((n, i) => intToHex(i === 3 ? Math.round(255 * n) : n)).join('')}`;\n}\n\n/**\n * Converts a color from hsl format to rgb format.\n * @param {string} color - HSL color values\n * @returns {string} rgb color values\n */\nexport function hslToRgb(color) {\n color = decomposeColor(color);\n const {\n values\n } = color;\n const h = values[0];\n const s = values[1] / 100;\n const l = values[2] / 100;\n const a = s * Math.min(l, 1 - l);\n const f = (n, k = (n + h / 30) % 12) => l - a * Math.max(Math.min(k - 3, 9 - k, 1), -1);\n let type = 'rgb';\n const rgb = [Math.round(f(0) * 255), Math.round(f(8) * 255), Math.round(f(4) * 255)];\n if (color.type === 'hsla') {\n type += 'a';\n rgb.push(values[3]);\n }\n return recomposeColor({\n type,\n values: rgb\n });\n}\n/**\n * The relative brightness of any point in a color space,\n * normalized to 0 for darkest black and 1 for lightest white.\n *\n * Formula: https://www.w3.org/TR/WCAG20-TECHS/G17.html#G17-tests\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @returns {number} The relative brightness of the color in the range 0 - 1\n */\nexport function getLuminance(color) {\n color = decomposeColor(color);\n let rgb = color.type === 'hsl' || color.type === 'hsla' ? decomposeColor(hslToRgb(color)).values : color.values;\n rgb = rgb.map(val => {\n if (color.type !== 'color') {\n val /= 255; // normalized\n }\n return val <= 0.03928 ? val / 12.92 : ((val + 0.055) / 1.055) ** 2.4;\n });\n\n // Truncate at 3 digits\n return Number((0.2126 * rgb[0] + 0.7152 * rgb[1] + 0.0722 * rgb[2]).toFixed(3));\n}\n\n/**\n * Calculates the contrast ratio between two colors.\n *\n * Formula: https://www.w3.org/TR/WCAG20-TECHS/G17.html#G17-tests\n * @param {string} foreground - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla()\n * @param {string} background - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla()\n * @returns {number} A contrast ratio value in the range 0 - 21.\n */\nexport function getContrastRatio(foreground, background) {\n const lumA = getLuminance(foreground);\n const lumB = getLuminance(background);\n return (Math.max(lumA, lumB) + 0.05) / (Math.min(lumA, lumB) + 0.05);\n}\n\n/**\n * Sets the absolute transparency of a color.\n * Any existing alpha values are overwritten.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} value - value to set the alpha channel to in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function alpha(color, value) {\n color = decomposeColor(color);\n value = clampWrapper(value);\n if (color.type === 'rgb' || color.type === 'hsl') {\n color.type += 'a';\n }\n if (color.type === 'color') {\n color.values[3] = `/${value}`;\n } else {\n color.values[3] = value;\n }\n return recomposeColor(color);\n}\nexport function private_safeAlpha(color, value, warning) {\n try {\n return alpha(color, value);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Darkens a color.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} coefficient - multiplier in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function darken(color, coefficient) {\n color = decomposeColor(color);\n coefficient = clampWrapper(coefficient);\n if (color.type.indexOf('hsl') !== -1) {\n color.values[2] *= 1 - coefficient;\n } else if (color.type.indexOf('rgb') !== -1 || color.type.indexOf('color') !== -1) {\n for (let i = 0; i < 3; i += 1) {\n color.values[i] *= 1 - coefficient;\n }\n }\n return recomposeColor(color);\n}\nexport function private_safeDarken(color, coefficient, warning) {\n try {\n return darken(color, coefficient);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Lightens a color.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} coefficient - multiplier in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function lighten(color, coefficient) {\n color = decomposeColor(color);\n coefficient = clampWrapper(coefficient);\n if (color.type.indexOf('hsl') !== -1) {\n color.values[2] += (100 - color.values[2]) * coefficient;\n } else if (color.type.indexOf('rgb') !== -1) {\n for (let i = 0; i < 3; i += 1) {\n color.values[i] += (255 - color.values[i]) * coefficient;\n }\n } else if (color.type.indexOf('color') !== -1) {\n for (let i = 0; i < 3; i += 1) {\n color.values[i] += (1 - color.values[i]) * coefficient;\n }\n }\n return recomposeColor(color);\n}\nexport function private_safeLighten(color, coefficient, warning) {\n try {\n return lighten(color, coefficient);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Darken or lighten a color, depending on its luminance.\n * Light colors are darkened, dark colors are lightened.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} coefficient=0.15 - multiplier in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function emphasize(color, coefficient = 0.15) {\n return getLuminance(color) > 0.5 ? darken(color, coefficient) : lighten(color, coefficient);\n}\nexport function private_safeEmphasize(color, coefficient, warning) {\n try {\n return emphasize(color, coefficient);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Blend a transparent overlay color with a background color, resulting in a single\n * RGB color.\n * @param {string} background - CSS color\n * @param {string} overlay - CSS color\n * @param {number} opacity - Opacity multiplier in the range 0 - 1\n * @param {number} [gamma=1.0] - Gamma correction factor. For gamma-correct blending, 2.2 is usual.\n */\nexport function blend(background, overlay, opacity, gamma = 1.0) {\n const blendChannel = (b, o) => Math.round((b ** (1 / gamma) * (1 - opacity) + o ** (1 / gamma) * opacity) ** gamma);\n const backgroundColor = decomposeColor(background);\n const overlayColor = decomposeColor(overlay);\n const rgb = [blendChannel(backgroundColor.values[0], overlayColor.values[0]), blendChannel(backgroundColor.values[1], overlayColor.values[1]), blendChannel(backgroundColor.values[2], overlayColor.values[2])];\n return recomposeColor({\n type: 'rgb',\n values: rgb\n });\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nexport default function createMixins(breakpoints, mixins) {\n return _extends({\n toolbar: {\n minHeight: 56,\n [breakpoints.up('xs')]: {\n '@media (orientation: landscape)': {\n minHeight: 48\n }\n },\n [breakpoints.up('sm')]: {\n minHeight: 64\n }\n }\n }, mixins);\n}","const common = {\n black: '#000',\n white: '#fff'\n};\nexport default common;","const grey = {\n 50: '#fafafa',\n 100: '#f5f5f5',\n 200: '#eeeeee',\n 300: '#e0e0e0',\n 400: '#bdbdbd',\n 500: '#9e9e9e',\n 600: '#757575',\n 700: '#616161',\n 800: '#424242',\n 900: '#212121',\n A100: '#f5f5f5',\n A200: '#eeeeee',\n A400: '#bdbdbd',\n A700: '#616161'\n};\nexport default grey;","const purple = {\n 50: '#f3e5f5',\n 100: '#e1bee7',\n 200: '#ce93d8',\n 300: '#ba68c8',\n 400: '#ab47bc',\n 500: '#9c27b0',\n 600: '#8e24aa',\n 700: '#7b1fa2',\n 800: '#6a1b9a',\n 900: '#4a148c',\n A100: '#ea80fc',\n A200: '#e040fb',\n A400: '#d500f9',\n A700: '#aa00ff'\n};\nexport default purple;","const red = {\n 50: '#ffebee',\n 100: '#ffcdd2',\n 200: '#ef9a9a',\n 300: '#e57373',\n 400: '#ef5350',\n 500: '#f44336',\n 600: '#e53935',\n 700: '#d32f2f',\n 800: '#c62828',\n 900: '#b71c1c',\n A100: '#ff8a80',\n A200: '#ff5252',\n A400: '#ff1744',\n A700: '#d50000'\n};\nexport default red;","const orange = {\n 50: '#fff3e0',\n 100: '#ffe0b2',\n 200: '#ffcc80',\n 300: '#ffb74d',\n 400: '#ffa726',\n 500: '#ff9800',\n 600: '#fb8c00',\n 700: '#f57c00',\n 800: '#ef6c00',\n 900: '#e65100',\n A100: '#ffd180',\n A200: '#ffab40',\n A400: '#ff9100',\n A700: '#ff6d00'\n};\nexport default orange;","const blue = {\n 50: '#e3f2fd',\n 100: '#bbdefb',\n 200: '#90caf9',\n 300: '#64b5f6',\n 400: '#42a5f5',\n 500: '#2196f3',\n 600: '#1e88e5',\n 700: '#1976d2',\n 800: '#1565c0',\n 900: '#0d47a1',\n A100: '#82b1ff',\n A200: '#448aff',\n A400: '#2979ff',\n A700: '#2962ff'\n};\nexport default blue;","const lightBlue = {\n 50: '#e1f5fe',\n 100: '#b3e5fc',\n 200: '#81d4fa',\n 300: '#4fc3f7',\n 400: '#29b6f6',\n 500: '#03a9f4',\n 600: '#039be5',\n 700: '#0288d1',\n 800: '#0277bd',\n 900: '#01579b',\n A100: '#80d8ff',\n A200: '#40c4ff',\n A400: '#00b0ff',\n A700: '#0091ea'\n};\nexport default lightBlue;","const green = {\n 50: '#e8f5e9',\n 100: '#c8e6c9',\n 200: '#a5d6a7',\n 300: '#81c784',\n 400: '#66bb6a',\n 500: '#4caf50',\n 600: '#43a047',\n 700: '#388e3c',\n 800: '#2e7d32',\n 900: '#1b5e20',\n A100: '#b9f6ca',\n A200: '#69f0ae',\n A400: '#00e676',\n A700: '#00c853'\n};\nexport default green;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\nconst _excluded = [\"mode\", \"contrastThreshold\", \"tonalOffset\"];\nimport { deepmerge } from '@mui/utils';\nimport { darken, getContrastRatio, lighten } from '@mui/system';\nimport common from '../colors/common';\nimport grey from '../colors/grey';\nimport purple from '../colors/purple';\nimport red from '../colors/red';\nimport orange from '../colors/orange';\nimport blue from '../colors/blue';\nimport lightBlue from '../colors/lightBlue';\nimport green from '../colors/green';\nexport const light = {\n // The colors used to style the text.\n text: {\n // The most important text.\n primary: 'rgba(0, 0, 0, 0.87)',\n // Secondary text.\n secondary: 'rgba(0, 0, 0, 0.6)',\n // Disabled text have even lower visual prominence.\n disabled: 'rgba(0, 0, 0, 0.38)'\n },\n // The color used to divide different elements.\n divider: 'rgba(0, 0, 0, 0.12)',\n // The background colors used to style the surfaces.\n // Consistency between these values is important.\n background: {\n paper: common.white,\n default: common.white\n },\n // The colors used to style the action elements.\n action: {\n // The color of an active action like an icon button.\n active: 'rgba(0, 0, 0, 0.54)',\n // The color of an hovered action.\n hover: 'rgba(0, 0, 0, 0.04)',\n hoverOpacity: 0.04,\n // The color of a selected action.\n selected: 'rgba(0, 0, 0, 0.08)',\n selectedOpacity: 0.08,\n // The color of a disabled action.\n disabled: 'rgba(0, 0, 0, 0.26)',\n // The background color of a disabled action.\n disabledBackground: 'rgba(0, 0, 0, 0.12)',\n disabledOpacity: 0.38,\n focus: 'rgba(0, 0, 0, 0.12)',\n focusOpacity: 0.12,\n activatedOpacity: 0.12\n }\n};\nexport const dark = {\n text: {\n primary: common.white,\n secondary: 'rgba(255, 255, 255, 0.7)',\n disabled: 'rgba(255, 255, 255, 0.5)',\n icon: 'rgba(255, 255, 255, 0.5)'\n },\n divider: 'rgba(255, 255, 255, 0.12)',\n background: {\n paper: '#121212',\n default: '#121212'\n },\n action: {\n active: common.white,\n hover: 'rgba(255, 255, 255, 0.08)',\n hoverOpacity: 0.08,\n selected: 'rgba(255, 255, 255, 0.16)',\n selectedOpacity: 0.16,\n disabled: 'rgba(255, 255, 255, 0.3)',\n disabledBackground: 'rgba(255, 255, 255, 0.12)',\n disabledOpacity: 0.38,\n focus: 'rgba(255, 255, 255, 0.12)',\n focusOpacity: 0.12,\n activatedOpacity: 0.24\n }\n};\nfunction addLightOrDark(intent, direction, shade, tonalOffset) {\n const tonalOffsetLight = tonalOffset.light || tonalOffset;\n const tonalOffsetDark = tonalOffset.dark || tonalOffset * 1.5;\n if (!intent[direction]) {\n if (intent.hasOwnProperty(shade)) {\n intent[direction] = intent[shade];\n } else if (direction === 'light') {\n intent.light = lighten(intent.main, tonalOffsetLight);\n } else if (direction === 'dark') {\n intent.dark = darken(intent.main, tonalOffsetDark);\n }\n }\n}\nfunction getDefaultPrimary(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: blue[200],\n light: blue[50],\n dark: blue[400]\n };\n }\n return {\n main: blue[700],\n light: blue[400],\n dark: blue[800]\n };\n}\nfunction getDefaultSecondary(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: purple[200],\n light: purple[50],\n dark: purple[400]\n };\n }\n return {\n main: purple[500],\n light: purple[300],\n dark: purple[700]\n };\n}\nfunction getDefaultError(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: red[500],\n light: red[300],\n dark: red[700]\n };\n }\n return {\n main: red[700],\n light: red[400],\n dark: red[800]\n };\n}\nfunction getDefaultInfo(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: lightBlue[400],\n light: lightBlue[300],\n dark: lightBlue[700]\n };\n }\n return {\n main: lightBlue[700],\n light: lightBlue[500],\n dark: lightBlue[900]\n };\n}\nfunction getDefaultSuccess(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: green[400],\n light: green[300],\n dark: green[700]\n };\n }\n return {\n main: green[800],\n light: green[500],\n dark: green[900]\n };\n}\nfunction getDefaultWarning(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: orange[400],\n light: orange[300],\n dark: orange[700]\n };\n }\n return {\n main: '#ed6c02',\n // closest to orange[800] that pass 3:1.\n light: orange[500],\n dark: orange[900]\n };\n}\nexport default function createPalette(palette) {\n const {\n mode = 'light',\n contrastThreshold = 3,\n tonalOffset = 0.2\n } = palette,\n other = _objectWithoutPropertiesLoose(palette, _excluded);\n const primary = palette.primary || getDefaultPrimary(mode);\n const secondary = palette.secondary || getDefaultSecondary(mode);\n const error = palette.error || getDefaultError(mode);\n const info = palette.info || getDefaultInfo(mode);\n const success = palette.success || getDefaultSuccess(mode);\n const warning = palette.warning || getDefaultWarning(mode);\n\n // Use the same logic as\n // Bootstrap: https://github.com/twbs/bootstrap/blob/1d6e3710dd447de1a200f29e8fa521f8a0908f70/scss/_functions.scss#L59\n // and material-components-web https://github.com/material-components/material-components-web/blob/ac46b8863c4dab9fc22c4c662dc6bd1b65dd652f/packages/mdc-theme/_functions.scss#L54\n function getContrastText(background) {\n const contrastText = getContrastRatio(background, dark.text.primary) >= contrastThreshold ? dark.text.primary : light.text.primary;\n if (process.env.NODE_ENV !== 'production') {\n const contrast = getContrastRatio(background, contrastText);\n if (contrast < 3) {\n console.error([`MUI: The contrast ratio of ${contrast}:1 for ${contrastText} on ${background}`, 'falls below the WCAG recommended absolute minimum contrast ratio of 3:1.', 'https://www.w3.org/TR/2008/REC-WCAG20-20081211/#visual-audio-contrast-contrast'].join('\\n'));\n }\n }\n return contrastText;\n }\n const augmentColor = ({\n color,\n name,\n mainShade = 500,\n lightShade = 300,\n darkShade = 700\n }) => {\n color = _extends({}, color);\n if (!color.main && color[mainShade]) {\n color.main = color[mainShade];\n }\n if (!color.hasOwnProperty('main')) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: The color${name ? ` (${name})` : ''} provided to augmentColor(color) is invalid.\nThe color object needs to have a \\`main\\` property or a \\`${mainShade}\\` property.` : _formatMuiErrorMessage(11, name ? ` (${name})` : '', mainShade));\n }\n if (typeof color.main !== 'string') {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: The color${name ? ` (${name})` : ''} provided to augmentColor(color) is invalid.\n\\`color.main\\` should be a string, but \\`${JSON.stringify(color.main)}\\` was provided instead.\n\nDid you intend to use one of the following approaches?\n\nimport { green } from \"@mui/material/colors\";\n\nconst theme1 = createTheme({ palette: {\n primary: green,\n} });\n\nconst theme2 = createTheme({ palette: {\n primary: { main: green[500] },\n} });` : _formatMuiErrorMessage(12, name ? ` (${name})` : '', JSON.stringify(color.main)));\n }\n addLightOrDark(color, 'light', lightShade, tonalOffset);\n addLightOrDark(color, 'dark', darkShade, tonalOffset);\n if (!color.contrastText) {\n color.contrastText = getContrastText(color.main);\n }\n return color;\n };\n const modes = {\n dark,\n light\n };\n if (process.env.NODE_ENV !== 'production') {\n if (!modes[mode]) {\n console.error(`MUI: The palette mode \\`${mode}\\` is not supported.`);\n }\n }\n const paletteOutput = deepmerge(_extends({\n // A collection of common colors.\n common: _extends({}, common),\n // prevent mutable object.\n // The palette mode, can be light or dark.\n mode,\n // The colors used to represent primary interface elements for a user.\n primary: augmentColor({\n color: primary,\n name: 'primary'\n }),\n // The colors used to represent secondary interface elements for a user.\n secondary: augmentColor({\n color: secondary,\n name: 'secondary',\n mainShade: 'A400',\n lightShade: 'A200',\n darkShade: 'A700'\n }),\n // The colors used to represent interface elements that the user should be made aware of.\n error: augmentColor({\n color: error,\n name: 'error'\n }),\n // The colors used to represent potentially dangerous actions or important messages.\n warning: augmentColor({\n color: warning,\n name: 'warning'\n }),\n // The colors used to present information to the user that is neutral and not necessarily important.\n info: augmentColor({\n color: info,\n name: 'info'\n }),\n // The colors used to indicate the successful completion of an action that user triggered.\n success: augmentColor({\n color: success,\n name: 'success'\n }),\n // The grey colors.\n grey,\n // Used by `getContrastText()` to maximize the contrast between\n // the background and the text.\n contrastThreshold,\n // Takes a background color and returns the text color that maximizes the contrast.\n getContrastText,\n // Generate a rich color object.\n augmentColor,\n // Used by the functions below to shift a color's luminance by approximately\n // two indexes within its tonal palette.\n // E.g., shift from Red 500 to Red 300 or Red 700.\n tonalOffset\n }, modes[mode]), other);\n return paletteOutput;\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"fontFamily\", \"fontSize\", \"fontWeightLight\", \"fontWeightRegular\", \"fontWeightMedium\", \"fontWeightBold\", \"htmlFontSize\", \"allVariants\", \"pxToRem\"];\nimport { deepmerge } from '@mui/utils';\nfunction round(value) {\n return Math.round(value * 1e5) / 1e5;\n}\nconst caseAllCaps = {\n textTransform: 'uppercase'\n};\nconst defaultFontFamily = '\"Roboto\", \"Helvetica\", \"Arial\", sans-serif';\n\n/**\n * @see @link{https://m2.material.io/design/typography/the-type-system.html}\n * @see @link{https://m2.material.io/design/typography/understanding-typography.html}\n */\nexport default function createTypography(palette, typography) {\n const _ref = typeof typography === 'function' ? typography(palette) : typography,\n {\n fontFamily = defaultFontFamily,\n // The default font size of the Material Specification.\n fontSize = 14,\n // px\n fontWeightLight = 300,\n fontWeightRegular = 400,\n fontWeightMedium = 500,\n fontWeightBold = 700,\n // Tell MUI what's the font-size on the html element.\n // 16px is the default font-size used by browsers.\n htmlFontSize = 16,\n // Apply the CSS properties to all the variants.\n allVariants,\n pxToRem: pxToRem2\n } = _ref,\n other = _objectWithoutPropertiesLoose(_ref, _excluded);\n if (process.env.NODE_ENV !== 'production') {\n if (typeof fontSize !== 'number') {\n console.error('MUI: `fontSize` is required to be a number.');\n }\n if (typeof htmlFontSize !== 'number') {\n console.error('MUI: `htmlFontSize` is required to be a number.');\n }\n }\n const coef = fontSize / 14;\n const pxToRem = pxToRem2 || (size => `${size / htmlFontSize * coef}rem`);\n const buildVariant = (fontWeight, size, lineHeight, letterSpacing, casing) => _extends({\n fontFamily,\n fontWeight,\n fontSize: pxToRem(size),\n // Unitless following https://meyerweb.com/eric/thoughts/2006/02/08/unitless-line-heights/\n lineHeight\n }, fontFamily === defaultFontFamily ? {\n letterSpacing: `${round(letterSpacing / size)}em`\n } : {}, casing, allVariants);\n const variants = {\n h1: buildVariant(fontWeightLight, 96, 1.167, -1.5),\n h2: buildVariant(fontWeightLight, 60, 1.2, -0.5),\n h3: buildVariant(fontWeightRegular, 48, 1.167, 0),\n h4: buildVariant(fontWeightRegular, 34, 1.235, 0.25),\n h5: buildVariant(fontWeightRegular, 24, 1.334, 0),\n h6: buildVariant(fontWeightMedium, 20, 1.6, 0.15),\n subtitle1: buildVariant(fontWeightRegular, 16, 1.75, 0.15),\n subtitle2: buildVariant(fontWeightMedium, 14, 1.57, 0.1),\n body1: buildVariant(fontWeightRegular, 16, 1.5, 0.15),\n body2: buildVariant(fontWeightRegular, 14, 1.43, 0.15),\n button: buildVariant(fontWeightMedium, 14, 1.75, 0.4, caseAllCaps),\n caption: buildVariant(fontWeightRegular, 12, 1.66, 0.4),\n overline: buildVariant(fontWeightRegular, 12, 2.66, 1, caseAllCaps),\n // TODO v6: Remove handling of 'inherit' variant from the theme as it is already handled in Material UI's Typography component. Also, remember to remove the associated types.\n inherit: {\n fontFamily: 'inherit',\n fontWeight: 'inherit',\n fontSize: 'inherit',\n lineHeight: 'inherit',\n letterSpacing: 'inherit'\n }\n };\n return deepmerge(_extends({\n htmlFontSize,\n pxToRem,\n fontFamily,\n fontSize,\n fontWeightLight,\n fontWeightRegular,\n fontWeightMedium,\n fontWeightBold\n }, variants), other, {\n clone: false // No need to clone deep\n });\n}","const shadowKeyUmbraOpacity = 0.2;\nconst shadowKeyPenumbraOpacity = 0.14;\nconst shadowAmbientShadowOpacity = 0.12;\nfunction createShadow(...px) {\n return [`${px[0]}px ${px[1]}px ${px[2]}px ${px[3]}px rgba(0,0,0,${shadowKeyUmbraOpacity})`, `${px[4]}px ${px[5]}px ${px[6]}px ${px[7]}px rgba(0,0,0,${shadowKeyPenumbraOpacity})`, `${px[8]}px ${px[9]}px ${px[10]}px ${px[11]}px rgba(0,0,0,${shadowAmbientShadowOpacity})`].join(',');\n}\n\n// Values from https://github.com/material-components/material-components-web/blob/be8747f94574669cb5e7add1a7c54fa41a89cec7/packages/mdc-elevation/_variables.scss\nconst shadows = ['none', createShadow(0, 2, 1, -1, 0, 1, 1, 0, 0, 1, 3, 0), createShadow(0, 3, 1, -2, 0, 2, 2, 0, 0, 1, 5, 0), createShadow(0, 3, 3, -2, 0, 3, 4, 0, 0, 1, 8, 0), createShadow(0, 2, 4, -1, 0, 4, 5, 0, 0, 1, 10, 0), createShadow(0, 3, 5, -1, 0, 5, 8, 0, 0, 1, 14, 0), createShadow(0, 3, 5, -1, 0, 6, 10, 0, 0, 1, 18, 0), createShadow(0, 4, 5, -2, 0, 7, 10, 1, 0, 2, 16, 1), createShadow(0, 5, 5, -3, 0, 8, 10, 1, 0, 3, 14, 2), createShadow(0, 5, 6, -3, 0, 9, 12, 1, 0, 3, 16, 2), createShadow(0, 6, 6, -3, 0, 10, 14, 1, 0, 4, 18, 3), createShadow(0, 6, 7, -4, 0, 11, 15, 1, 0, 4, 20, 3), createShadow(0, 7, 8, -4, 0, 12, 17, 2, 0, 5, 22, 4), createShadow(0, 7, 8, -4, 0, 13, 19, 2, 0, 5, 24, 4), createShadow(0, 7, 9, -4, 0, 14, 21, 2, 0, 5, 26, 4), createShadow(0, 8, 9, -5, 0, 15, 22, 2, 0, 6, 28, 5), createShadow(0, 8, 10, -5, 0, 16, 24, 2, 0, 6, 30, 5), createShadow(0, 8, 11, -5, 0, 17, 26, 2, 0, 6, 32, 5), createShadow(0, 9, 11, -5, 0, 18, 28, 2, 0, 7, 34, 6), createShadow(0, 9, 12, -6, 0, 19, 29, 2, 0, 7, 36, 6), createShadow(0, 10, 13, -6, 0, 20, 31, 3, 0, 8, 38, 7), createShadow(0, 10, 13, -6, 0, 21, 33, 3, 0, 8, 40, 7), createShadow(0, 10, 14, -6, 0, 22, 35, 3, 0, 8, 42, 7), createShadow(0, 11, 14, -7, 0, 23, 36, 3, 0, 9, 44, 8), createShadow(0, 11, 15, -7, 0, 24, 38, 3, 0, 9, 46, 8)];\nexport default shadows;","import _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nconst _excluded = [\"duration\", \"easing\", \"delay\"];\n// Follow https://material.google.com/motion/duration-easing.html#duration-easing-natural-easing-curves\n// to learn the context in which each easing should be used.\nexport const easing = {\n // This is the most common easing curve.\n easeInOut: 'cubic-bezier(0.4, 0, 0.2, 1)',\n // Objects enter the screen at full velocity from off-screen and\n // slowly decelerate to a resting point.\n easeOut: 'cubic-bezier(0.0, 0, 0.2, 1)',\n // Objects leave the screen at full velocity. They do not decelerate when off-screen.\n easeIn: 'cubic-bezier(0.4, 0, 1, 1)',\n // The sharp curve is used by objects that may return to the screen at any time.\n sharp: 'cubic-bezier(0.4, 0, 0.6, 1)'\n};\n\n// Follow https://m2.material.io/guidelines/motion/duration-easing.html#duration-easing-common-durations\n// to learn when use what timing\nexport const duration = {\n shortest: 150,\n shorter: 200,\n short: 250,\n // most basic recommended timing\n standard: 300,\n // this is to be used in complex animations\n complex: 375,\n // recommended when something is entering screen\n enteringScreen: 225,\n // recommended when something is leaving screen\n leavingScreen: 195\n};\nfunction formatMs(milliseconds) {\n return `${Math.round(milliseconds)}ms`;\n}\nfunction getAutoHeightDuration(height) {\n if (!height) {\n return 0;\n }\n const constant = height / 36;\n\n // https://www.wolframalpha.com/input/?i=(4+%2B+15+*+(x+%2F+36+)+**+0.25+%2B+(x+%2F+36)+%2F+5)+*+10\n return Math.round((4 + 15 * constant ** 0.25 + constant / 5) * 10);\n}\nexport default function createTransitions(inputTransitions) {\n const mergedEasing = _extends({}, easing, inputTransitions.easing);\n const mergedDuration = _extends({}, duration, inputTransitions.duration);\n const create = (props = ['all'], options = {}) => {\n const {\n duration: durationOption = mergedDuration.standard,\n easing: easingOption = mergedEasing.easeInOut,\n delay = 0\n } = options,\n other = _objectWithoutPropertiesLoose(options, _excluded);\n if (process.env.NODE_ENV !== 'production') {\n const isString = value => typeof value === 'string';\n // IE11 support, replace with Number.isNaN\n // eslint-disable-next-line no-restricted-globals\n const isNumber = value => !isNaN(parseFloat(value));\n if (!isString(props) && !Array.isArray(props)) {\n console.error('MUI: Argument \"props\" must be a string or Array.');\n }\n if (!isNumber(durationOption) && !isString(durationOption)) {\n console.error(`MUI: Argument \"duration\" must be a number or a string but found ${durationOption}.`);\n }\n if (!isString(easingOption)) {\n console.error('MUI: Argument \"easing\" must be a string.');\n }\n if (!isNumber(delay) && !isString(delay)) {\n console.error('MUI: Argument \"delay\" must be a number or a string.');\n }\n if (typeof options !== 'object') {\n console.error(['MUI: Secong argument of transition.create must be an object.', \"Arguments should be either `create('prop1', options)` or `create(['prop1', 'prop2'], options)`\"].join('\\n'));\n }\n if (Object.keys(other).length !== 0) {\n console.error(`MUI: Unrecognized argument(s) [${Object.keys(other).join(',')}].`);\n }\n }\n return (Array.isArray(props) ? props : [props]).map(animatedProp => `${animatedProp} ${typeof durationOption === 'string' ? durationOption : formatMs(durationOption)} ${easingOption} ${typeof delay === 'string' ? delay : formatMs(delay)}`).join(',');\n };\n return _extends({\n getAutoHeightDuration,\n create\n }, inputTransitions, {\n easing: mergedEasing,\n duration: mergedDuration\n });\n}","// We need to centralize the zIndex definitions as they work\n// like global values in the browser.\nconst zIndex = {\n mobileStepper: 1000,\n fab: 1050,\n speedDial: 1050,\n appBar: 1100,\n drawer: 1200,\n modal: 1300,\n snackbar: 1400,\n tooltip: 1500\n};\nexport default zIndex;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\nconst _excluded = [\"breakpoints\", \"mixins\", \"spacing\", \"palette\", \"transitions\", \"typography\", \"shape\"];\nimport { deepmerge } from '@mui/utils';\nimport { createTheme as systemCreateTheme, unstable_defaultSxConfig as defaultSxConfig, unstable_styleFunctionSx as styleFunctionSx } from '@mui/system';\nimport generateUtilityClass from '@mui/utils/generateUtilityClass';\nimport createMixins from './createMixins';\nimport createPalette from './createPalette';\nimport createTypography from './createTypography';\nimport shadows from './shadows';\nimport createTransitions from './createTransitions';\nimport zIndex from './zIndex';\nfunction createTheme(options = {}, ...args) {\n const {\n mixins: mixinsInput = {},\n palette: paletteInput = {},\n transitions: transitionsInput = {},\n typography: typographyInput = {}\n } = options,\n other = _objectWithoutPropertiesLoose(options, _excluded);\n if (options.vars) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: \\`vars\\` is a private field used for CSS variables support.\nPlease use another name.` : _formatMuiErrorMessage(18));\n }\n const palette = createPalette(paletteInput);\n const systemTheme = systemCreateTheme(options);\n let muiTheme = deepmerge(systemTheme, {\n mixins: createMixins(systemTheme.breakpoints, mixinsInput),\n palette,\n // Don't use [...shadows] until you've verified its transpiled code is not invoking the iterator protocol.\n shadows: shadows.slice(),\n typography: createTypography(palette, typographyInput),\n transitions: createTransitions(transitionsInput),\n zIndex: _extends({}, zIndex)\n });\n muiTheme = deepmerge(muiTheme, other);\n muiTheme = args.reduce((acc, argument) => deepmerge(acc, argument), muiTheme);\n if (process.env.NODE_ENV !== 'production') {\n // TODO v6: Refactor to use globalStateClassesMapping from @mui/utils once `readOnly` state class is used in Rating component.\n const stateClasses = ['active', 'checked', 'completed', 'disabled', 'error', 'expanded', 'focused', 'focusVisible', 'required', 'selected'];\n const traverse = (node, component) => {\n let key;\n\n // eslint-disable-next-line guard-for-in, no-restricted-syntax\n for (key in node) {\n const child = node[key];\n if (stateClasses.indexOf(key) !== -1 && Object.keys(child).length > 0) {\n if (process.env.NODE_ENV !== 'production') {\n const stateClass = generateUtilityClass('', key);\n console.error([`MUI: The \\`${component}\\` component increases ` + `the CSS specificity of the \\`${key}\\` internal state.`, 'You can not override it like this: ', JSON.stringify(node, null, 2), '', `Instead, you need to use the '&.${stateClass}' syntax:`, JSON.stringify({\n root: {\n [`&.${stateClass}`]: child\n }\n }, null, 2), '', 'https://mui.com/r/state-classes-guide'].join('\\n'));\n }\n // Remove the style to prevent global conflicts.\n node[key] = {};\n }\n }\n };\n Object.keys(muiTheme.components).forEach(component => {\n const styleOverrides = muiTheme.components[component].styleOverrides;\n if (styleOverrides && component.indexOf('Mui') === 0) {\n traverse(styleOverrides, component);\n }\n });\n }\n muiTheme.unstable_sxConfig = _extends({}, defaultSxConfig, other == null ? void 0 : other.unstable_sxConfig);\n muiTheme.unstable_sx = function sx(props) {\n return styleFunctionSx({\n sx: props,\n theme: this\n });\n };\n return muiTheme;\n}\nlet warnedOnce = false;\nexport function createMuiTheme(...args) {\n if (process.env.NODE_ENV !== 'production') {\n if (!warnedOnce) {\n warnedOnce = true;\n console.error(['MUI: the createMuiTheme function was renamed to createTheme.', '', \"You should use `import { createTheme } from '@mui/material/styles'`\"].join('\\n'));\n }\n }\n return createTheme(...args);\n}\nexport default createTheme;","'use client';\n\nimport createTheme from './createTheme';\nconst defaultTheme = createTheme();\nexport default defaultTheme;","export default '$$material';","'use client';\n\nimport { useThemeProps as systemUseThemeProps } from '@mui/system';\nimport defaultTheme from './defaultTheme';\nimport THEME_ID from './identifier';\nexport default function useThemeProps({\n props,\n name\n}) {\n return systemUseThemeProps({\n props,\n name,\n defaultTheme,\n themeId: THEME_ID\n });\n}","'use client';\n\nimport { createStyled, shouldForwardProp } from '@mui/system';\nimport defaultTheme from './defaultTheme';\nimport THEME_ID from './identifier';\nexport const rootShouldForwardProp = prop => shouldForwardProp(prop) && prop !== 'classes';\nexport const slotShouldForwardProp = shouldForwardProp;\nconst styled = createStyled({\n themeId: THEME_ID,\n defaultTheme,\n rootShouldForwardProp\n});\nexport default styled;","import generateUtilityClasses from '@mui/utils/generateUtilityClasses';\nimport generateUtilityClass from '@mui/utils/generateUtilityClass';\nexport function getSvgIconUtilityClass(slot) {\n return generateUtilityClass('MuiSvgIcon', slot);\n}\nconst svgIconClasses = generateUtilityClasses('MuiSvgIcon', ['root', 'colorPrimary', 'colorSecondary', 'colorAction', 'colorError', 'colorDisabled', 'fontSizeInherit', 'fontSizeSmall', 'fontSizeMedium', 'fontSizeLarge']);\nexport default svgIconClasses;","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"children\", \"className\", \"color\", \"component\", \"fontSize\", \"htmlColor\", \"inheritViewBox\", \"titleAccess\", \"viewBox\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport clsx from 'clsx';\nimport { unstable_composeClasses as composeClasses } from '@mui/base/composeClasses';\nimport capitalize from '../utils/capitalize';\nimport useThemeProps from '../styles/useThemeProps';\nimport styled from '../styles/styled';\nimport { getSvgIconUtilityClass } from './svgIconClasses';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nimport { jsxs as _jsxs } from \"react/jsx-runtime\";\nconst useUtilityClasses = ownerState => {\n const {\n color,\n fontSize,\n classes\n } = ownerState;\n const slots = {\n root: ['root', color !== 'inherit' && `color${capitalize(color)}`, `fontSize${capitalize(fontSize)}`]\n };\n return composeClasses(slots, getSvgIconUtilityClass, classes);\n};\nconst SvgIconRoot = styled('svg', {\n name: 'MuiSvgIcon',\n slot: 'Root',\n overridesResolver: (props, styles) => {\n const {\n ownerState\n } = props;\n return [styles.root, ownerState.color !== 'inherit' && styles[`color${capitalize(ownerState.color)}`], styles[`fontSize${capitalize(ownerState.fontSize)}`]];\n }\n})(({\n theme,\n ownerState\n}) => {\n var _theme$transitions, _theme$transitions$cr, _theme$transitions2, _theme$typography, _theme$typography$pxT, _theme$typography2, _theme$typography2$px, _theme$typography3, _theme$typography3$px, _palette$ownerState$c, _palette, _palette2, _palette3;\n return {\n userSelect: 'none',\n width: '1em',\n height: '1em',\n display: 'inline-block',\n // the will define the property that has `currentColor`\n // e.g. heroicons uses fill=\"none\" and stroke=\"currentColor\"\n fill: ownerState.hasSvgAsChild ? undefined : 'currentColor',\n flexShrink: 0,\n transition: (_theme$transitions = theme.transitions) == null || (_theme$transitions$cr = _theme$transitions.create) == null ? void 0 : _theme$transitions$cr.call(_theme$transitions, 'fill', {\n duration: (_theme$transitions2 = theme.transitions) == null || (_theme$transitions2 = _theme$transitions2.duration) == null ? void 0 : _theme$transitions2.shorter\n }),\n fontSize: {\n inherit: 'inherit',\n small: ((_theme$typography = theme.typography) == null || (_theme$typography$pxT = _theme$typography.pxToRem) == null ? void 0 : _theme$typography$pxT.call(_theme$typography, 20)) || '1.25rem',\n medium: ((_theme$typography2 = theme.typography) == null || (_theme$typography2$px = _theme$typography2.pxToRem) == null ? void 0 : _theme$typography2$px.call(_theme$typography2, 24)) || '1.5rem',\n large: ((_theme$typography3 = theme.typography) == null || (_theme$typography3$px = _theme$typography3.pxToRem) == null ? void 0 : _theme$typography3$px.call(_theme$typography3, 35)) || '2.1875rem'\n }[ownerState.fontSize],\n // TODO v5 deprecate, v6 remove for sx\n color: (_palette$ownerState$c = (_palette = (theme.vars || theme).palette) == null || (_palette = _palette[ownerState.color]) == null ? void 0 : _palette.main) != null ? _palette$ownerState$c : {\n action: (_palette2 = (theme.vars || theme).palette) == null || (_palette2 = _palette2.action) == null ? void 0 : _palette2.active,\n disabled: (_palette3 = (theme.vars || theme).palette) == null || (_palette3 = _palette3.action) == null ? void 0 : _palette3.disabled,\n inherit: undefined\n }[ownerState.color]\n };\n});\nconst SvgIcon = /*#__PURE__*/React.forwardRef(function SvgIcon(inProps, ref) {\n const props = useThemeProps({\n props: inProps,\n name: 'MuiSvgIcon'\n });\n const {\n children,\n className,\n color = 'inherit',\n component = 'svg',\n fontSize = 'medium',\n htmlColor,\n inheritViewBox = false,\n titleAccess,\n viewBox = '0 0 24 24'\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const hasSvgAsChild = /*#__PURE__*/React.isValidElement(children) && children.type === 'svg';\n const ownerState = _extends({}, props, {\n color,\n component,\n fontSize,\n instanceFontSize: inProps.fontSize,\n inheritViewBox,\n viewBox,\n hasSvgAsChild\n });\n const more = {};\n if (!inheritViewBox) {\n more.viewBox = viewBox;\n }\n const classes = useUtilityClasses(ownerState);\n return /*#__PURE__*/_jsxs(SvgIconRoot, _extends({\n as: component,\n className: clsx(classes.root, className),\n focusable: \"false\",\n color: htmlColor,\n \"aria-hidden\": titleAccess ? undefined : true,\n role: titleAccess ? 'img' : undefined,\n ref: ref\n }, more, other, hasSvgAsChild && children.props, {\n ownerState: ownerState,\n children: [hasSvgAsChild ? children.props.children : children, titleAccess ? /*#__PURE__*/_jsx(\"title\", {\n children: titleAccess\n }) : null]\n }));\n});\nprocess.env.NODE_ENV !== \"production\" ? SvgIcon.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the d.ts file and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * Node passed into the SVG element.\n */\n children: PropTypes.node,\n /**\n * Override or extend the styles applied to the component.\n */\n classes: PropTypes.object,\n /**\n * @ignore\n */\n className: PropTypes.string,\n /**\n * The color of the component.\n * It supports both default and custom theme colors, which can be added as shown in the\n * [palette customization guide](https://mui.com/material-ui/customization/palette/#custom-colors).\n * You can use the `htmlColor` prop to apply a color attribute to the SVG element.\n * @default 'inherit'\n */\n color: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.oneOf(['inherit', 'action', 'disabled', 'primary', 'secondary', 'error', 'info', 'success', 'warning']), PropTypes.string]),\n /**\n * The component used for the root node.\n * Either a string to use a HTML element or a component.\n */\n component: PropTypes.elementType,\n /**\n * The fontSize applied to the icon. Defaults to 24px, but can be configure to inherit font size.\n * @default 'medium'\n */\n fontSize: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.oneOf(['inherit', 'large', 'medium', 'small']), PropTypes.string]),\n /**\n * Applies a color attribute to the SVG element.\n */\n htmlColor: PropTypes.string,\n /**\n * If `true`, the root node will inherit the custom `component`'s viewBox and the `viewBox`\n * prop will be ignored.\n * Useful when you want to reference a custom `component` and have `SvgIcon` pass that\n * `component`'s viewBox to the root node.\n * @default false\n */\n inheritViewBox: PropTypes.bool,\n /**\n * The shape-rendering attribute. The behavior of the different options is described on the\n * [MDN Web Docs](https://developer.mozilla.org/en-US/docs/Web/SVG/Attribute/shape-rendering).\n * If you are having issues with blurry icons you should investigate this prop.\n */\n shapeRendering: PropTypes.string,\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Provides a human-readable title for the element that contains it.\n * https://www.w3.org/TR/SVG-access/#Equivalent\n */\n titleAccess: PropTypes.string,\n /**\n * Allows you to redefine what the coordinates without units mean inside an SVG element.\n * For example, if the SVG element is 500 (width) by 200 (height),\n * and you pass viewBox=\"0 0 50 20\",\n * this means that the coordinates inside the SVG will go from the top left corner (0,0)\n * to bottom right (50,20) and each unit will be worth 10px.\n * @default '0 0 24 24'\n */\n viewBox: PropTypes.string\n} : void 0;\nSvgIcon.muiName = 'SvgIcon';\nexport default SvgIcon;","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport * as React from 'react';\nimport SvgIcon from '../SvgIcon';\n\n/**\n * Private module reserved for @mui packages.\n */\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nexport default function createSvgIcon(path, displayName) {\n function Component(props, ref) {\n return /*#__PURE__*/_jsx(SvgIcon, _extends({\n \"data-testid\": `${displayName}Icon`,\n ref: ref\n }, props, {\n children: path\n }));\n }\n if (process.env.NODE_ENV !== 'production') {\n // Need to set `displayName` on the inner component for React.memo.\n // React prior to 16.14 ignores `displayName` on the wrapper.\n Component.displayName = `${displayName}Icon`;\n }\n Component.muiName = SvgIcon.muiName;\n return /*#__PURE__*/React.memo( /*#__PURE__*/React.forwardRef(Component));\n}","'use client';\n\nimport { unstable_ClassNameGenerator as ClassNameGenerator } from '@mui/base/ClassNameGenerator';\nexport { default as capitalize } from './capitalize';\nexport { default as createChainedFunction } from './createChainedFunction';\nexport { default as createSvgIcon } from './createSvgIcon';\nexport { default as debounce } from './debounce';\nexport { default as deprecatedPropType } from './deprecatedPropType';\nexport { default as isMuiElement } from './isMuiElement';\nexport { default as ownerDocument } from './ownerDocument';\nexport { default as ownerWindow } from './ownerWindow';\nexport { default as requirePropFactory } from './requirePropFactory';\nexport { default as setRef } from './setRef';\nexport { default as unstable_useEnhancedEffect } from './useEnhancedEffect';\nexport { default as unstable_useId } from './useId';\nexport { default as unsupportedProp } from './unsupportedProp';\nexport { default as useControlled } from './useControlled';\nexport { default as useEventCallback } from './useEventCallback';\nexport { default as useForkRef } from './useForkRef';\nexport { default as useIsFocusVisible } from './useIsFocusVisible';\n// TODO: remove this export once ClassNameGenerator is stable\n// eslint-disable-next-line @typescript-eslint/naming-convention\nexport const unstable_ClassNameGenerator = {\n configure: generator => {\n if (process.env.NODE_ENV !== 'production') {\n console.warn(['MUI: `ClassNameGenerator` import from `@mui/material/utils` is outdated and might cause unexpected issues.', '', \"You should use `import { unstable_ClassNameGenerator } from '@mui/material/className'` instead\", '', 'The detail of the issue: https://github.com/mui/material-ui/issues/30011#issuecomment-1024993401', '', 'The updated documentation: https://mui.com/guides/classname-generator/'].join('\\n'));\n }\n ClassNameGenerator.configure(generator);\n }\n};","\"use strict\";\n'use client';\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nObject.defineProperty(exports, \"default\", {\n enumerable: true,\n get: function () {\n return _utils.createSvgIcon;\n }\n});\nvar _utils = require(\"@mui/material/utils\");","\"use strict\";\n\"use client\";\n\nvar _interopRequireDefault = require(\"@babel/runtime/helpers/interopRequireDefault\");\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = void 0;\nvar _createSvgIcon = _interopRequireDefault(require(\"./utils/createSvgIcon\"));\nvar _jsxRuntime = require(\"react/jsx-runtime\");\nvar _default = exports.default = (0, _createSvgIcon.default)( /*#__PURE__*/(0, _jsxRuntime.jsx)(\"path\", {\n d: \"m10 17 5-5-5-5z\"\n}), 'ArrowRight');","/**\n * Determines if a given element is a DOM element name (i.e. not a React component).\n */\nexport function isHostComponent(element) {\n return typeof element === 'string';\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport { isHostComponent } from './isHostComponent';\n\n/**\n * Type of the ownerState based on the type of an element it applies to.\n * This resolves to the provided OwnerState for React components and `undefined` for host components.\n * Falls back to `OwnerState | undefined` when the exact type can't be determined in development time.\n */\n\n/**\n * Appends the ownerState object to the props, merging with the existing one if necessary.\n *\n * @param elementType Type of the element that owns the `existingProps`. If the element is a DOM node or undefined, `ownerState` is not applied.\n * @param otherProps Props of the element.\n * @param ownerState\n */\nexport function appendOwnerState(elementType, otherProps, ownerState) {\n if (elementType === undefined || isHostComponent(elementType)) {\n return otherProps;\n }\n return _extends({}, otherProps, {\n ownerState: _extends({}, otherProps.ownerState, ownerState)\n });\n}","'use client';\n\nimport * as React from 'react';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nconst defaultContextValue = {\n disableDefaultClasses: false\n};\nconst ClassNameConfiguratorContext = /*#__PURE__*/React.createContext(defaultContextValue);\n/**\n * @ignore - internal hook.\n *\n * Wraps the `generateUtilityClass` function and controls how the classes are generated.\n * Currently it only affects whether the classes are applied or not.\n *\n * @returns Function to be called with the `generateUtilityClass` function specific to a component to generate the classes.\n */\nexport function useClassNamesOverride(generateUtilityClass) {\n const {\n disableDefaultClasses\n } = React.useContext(ClassNameConfiguratorContext);\n return slot => {\n if (disableDefaultClasses) {\n return '';\n }\n return generateUtilityClass(slot);\n };\n}\n\n/**\n * Allows to configure the components within to not apply any built-in classes.\n */\nexport function ClassNameConfigurator(props) {\n const {\n disableDefaultClasses,\n children\n } = props;\n const contextValue = React.useMemo(() => ({\n disableDefaultClasses: disableDefaultClasses != null ? disableDefaultClasses : false\n }), [disableDefaultClasses]);\n return /*#__PURE__*/_jsx(ClassNameConfiguratorContext.Provider, {\n value: contextValue,\n children: children\n });\n}","/**\n * Extracts event handlers from a given object.\n * A prop is considered an event handler if it is a function and its name starts with `on`.\n *\n * @param object An object to extract event handlers from.\n * @param excludeKeys An array of keys to exclude from the returned object.\n */\nexport function extractEventHandlers(object, excludeKeys = []) {\n if (object === undefined) {\n return {};\n }\n const result = {};\n Object.keys(object).filter(prop => prop.match(/^on[A-Z]/) && typeof object[prop] === 'function' && !excludeKeys.includes(prop)).forEach(prop => {\n result[prop] = object[prop];\n });\n return result;\n}","/**\n * If `componentProps` is a function, calls it with the provided `ownerState`.\n * Otherwise, just returns `componentProps`.\n */\nexport function resolveComponentProps(componentProps, ownerState, slotState) {\n if (typeof componentProps === 'function') {\n return componentProps(ownerState, slotState);\n }\n return componentProps;\n}","/**\n * Removes event handlers from the given object.\n * A field is considered an event handler if it is a function with a name beginning with `on`.\n *\n * @param object Object to remove event handlers from.\n * @returns Object with event handlers removed.\n */\nexport function omitEventHandlers(object) {\n if (object === undefined) {\n return {};\n }\n const result = {};\n Object.keys(object).filter(prop => !(prop.match(/^on[A-Z]/) && typeof object[prop] === 'function')).forEach(prop => {\n result[prop] = object[prop];\n });\n return result;\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport clsx from 'clsx';\nimport { extractEventHandlers } from './extractEventHandlers';\nimport { omitEventHandlers } from './omitEventHandlers';\n/**\n * Merges the slot component internal props (usually coming from a hook)\n * with the externally provided ones.\n *\n * The merge order is (the latter overrides the former):\n * 1. The internal props (specified as a getter function to work with get*Props hook result)\n * 2. Additional props (specified internally on a Base UI component)\n * 3. External props specified on the owner component. These should only be used on a root slot.\n * 4. External props specified in the `slotProps.*` prop.\n * 5. The `className` prop - combined from all the above.\n * @param parameters\n * @returns\n */\nexport function mergeSlotProps(parameters) {\n const {\n getSlotProps,\n additionalProps,\n externalSlotProps,\n externalForwardedProps,\n className\n } = parameters;\n if (!getSlotProps) {\n // The simpler case - getSlotProps is not defined, so no internal event handlers are defined,\n // so we can simply merge all the props without having to worry about extracting event handlers.\n const joinedClasses = clsx(additionalProps == null ? void 0 : additionalProps.className, className, externalForwardedProps == null ? void 0 : externalForwardedProps.className, externalSlotProps == null ? void 0 : externalSlotProps.className);\n const mergedStyle = _extends({}, additionalProps == null ? void 0 : additionalProps.style, externalForwardedProps == null ? void 0 : externalForwardedProps.style, externalSlotProps == null ? void 0 : externalSlotProps.style);\n const props = _extends({}, additionalProps, externalForwardedProps, externalSlotProps);\n if (joinedClasses.length > 0) {\n props.className = joinedClasses;\n }\n if (Object.keys(mergedStyle).length > 0) {\n props.style = mergedStyle;\n }\n return {\n props,\n internalRef: undefined\n };\n }\n\n // In this case, getSlotProps is responsible for calling the external event handlers.\n // We don't need to include them in the merged props because of this.\n\n const eventHandlers = extractEventHandlers(_extends({}, externalForwardedProps, externalSlotProps));\n const componentsPropsWithoutEventHandlers = omitEventHandlers(externalSlotProps);\n const otherPropsWithoutEventHandlers = omitEventHandlers(externalForwardedProps);\n const internalSlotProps = getSlotProps(eventHandlers);\n\n // The order of classes is important here.\n // Emotion (that we use in libraries consuming Base UI) depends on this order\n // to properly override style. It requires the most important classes to be last\n // (see https://github.com/mui/material-ui/pull/33205) for the related discussion.\n const joinedClasses = clsx(internalSlotProps == null ? void 0 : internalSlotProps.className, additionalProps == null ? void 0 : additionalProps.className, className, externalForwardedProps == null ? void 0 : externalForwardedProps.className, externalSlotProps == null ? void 0 : externalSlotProps.className);\n const mergedStyle = _extends({}, internalSlotProps == null ? void 0 : internalSlotProps.style, additionalProps == null ? void 0 : additionalProps.style, externalForwardedProps == null ? void 0 : externalForwardedProps.style, externalSlotProps == null ? void 0 : externalSlotProps.style);\n const props = _extends({}, internalSlotProps, additionalProps, otherPropsWithoutEventHandlers, componentsPropsWithoutEventHandlers);\n if (joinedClasses.length > 0) {\n props.className = joinedClasses;\n }\n if (Object.keys(mergedStyle).length > 0) {\n props.style = mergedStyle;\n }\n return {\n props,\n internalRef: internalSlotProps.ref\n };\n}","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"elementType\", \"externalSlotProps\", \"ownerState\", \"skipResolvingSlotProps\"];\nimport { unstable_useForkRef as useForkRef } from '@mui/utils';\nimport { appendOwnerState } from './appendOwnerState';\nimport { mergeSlotProps } from './mergeSlotProps';\nimport { resolveComponentProps } from './resolveComponentProps';\n/**\n * @ignore - do not document.\n * Builds the props to be passed into the slot of an unstyled component.\n * It merges the internal props of the component with the ones supplied by the user, allowing to customize the behavior.\n * If the slot component is not a host component, it also merges in the `ownerState`.\n *\n * @param parameters.getSlotProps - A function that returns the props to be passed to the slot component.\n */\nexport function useSlotProps(parameters) {\n var _parameters$additiona;\n const {\n elementType,\n externalSlotProps,\n ownerState,\n skipResolvingSlotProps = false\n } = parameters,\n rest = _objectWithoutPropertiesLoose(parameters, _excluded);\n const resolvedComponentsProps = skipResolvingSlotProps ? {} : resolveComponentProps(externalSlotProps, ownerState);\n const {\n props: mergedProps,\n internalRef\n } = mergeSlotProps(_extends({}, rest, {\n externalSlotProps: resolvedComponentsProps\n }));\n const ref = useForkRef(internalRef, resolvedComponentsProps == null ? void 0 : resolvedComponentsProps.ref, (_parameters$additiona = parameters.additionalProps) == null ? void 0 : _parameters$additiona.ref);\n const props = appendOwnerState(elementType, _extends({}, mergedProps, {\n ref\n }), ownerState);\n return props;\n}","import { globalStateClasses } from '@mui/utils/generateUtilityClass';\nconst GLOBAL_CLASS_PREFIX = 'base';\nfunction buildStateClass(state) {\n return `${GLOBAL_CLASS_PREFIX}--${state}`;\n}\nfunction buildSlotClass(componentName, slot) {\n return `${GLOBAL_CLASS_PREFIX}-${componentName}-${slot}`;\n}\nexport function generateUtilityClass(componentName, slot) {\n const globalStateClass = globalStateClasses[slot];\n return globalStateClass ? buildStateClass(globalStateClass) : buildSlotClass(componentName, slot);\n}\nexport function isGlobalState(slot) {\n return globalStateClasses[slot] !== undefined;\n}","import { generateUtilityClass } from '../generateUtilityClass';\nexport function generateUtilityClasses(componentName, slots) {\n const result = {};\n slots.forEach(slot => {\n result[slot] = generateUtilityClass(componentName, slot);\n });\n return result;\n}","'use client';\n\nimport * as React from 'react';\nimport * as ReactDOM from 'react-dom';\nimport PropTypes from 'prop-types';\nimport { exactProp, HTMLElementType, unstable_useEnhancedEffect as useEnhancedEffect, unstable_useForkRef as useForkRef, unstable_setRef as setRef } from '@mui/utils';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nfunction getContainer(container) {\n return typeof container === 'function' ? container() : container;\n}\n\n/**\n * Portals provide a first-class way to render children into a DOM node\n * that exists outside the DOM hierarchy of the parent component.\n *\n * Demos:\n *\n * - [Portal](https://mui.com/base-ui/react-portal/)\n *\n * API:\n *\n * - [Portal API](https://mui.com/base-ui/react-portal/components-api/#portal)\n */\nconst Portal = /*#__PURE__*/React.forwardRef(function Portal(props, forwardedRef) {\n const {\n children,\n container,\n disablePortal = false\n } = props;\n const [mountNode, setMountNode] = React.useState(null);\n // @ts-expect-error TODO upstream fix\n const handleRef = useForkRef( /*#__PURE__*/React.isValidElement(children) ? children.ref : null, forwardedRef);\n useEnhancedEffect(() => {\n if (!disablePortal) {\n setMountNode(getContainer(container) || document.body);\n }\n }, [container, disablePortal]);\n useEnhancedEffect(() => {\n if (mountNode && !disablePortal) {\n setRef(forwardedRef, mountNode);\n return () => {\n setRef(forwardedRef, null);\n };\n }\n return undefined;\n }, [forwardedRef, mountNode, disablePortal]);\n if (disablePortal) {\n if ( /*#__PURE__*/React.isValidElement(children)) {\n const newProps = {\n ref: handleRef\n };\n return /*#__PURE__*/React.cloneElement(children, newProps);\n }\n return /*#__PURE__*/_jsx(React.Fragment, {\n children: children\n });\n }\n return /*#__PURE__*/_jsx(React.Fragment, {\n children: mountNode ? /*#__PURE__*/ReactDOM.createPortal(children, mountNode) : mountNode\n });\n});\nprocess.env.NODE_ENV !== \"production\" ? Portal.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * The children to render into the `container`.\n */\n children: PropTypes.node,\n /**\n * An HTML element or function that returns one.\n * The `container` will have the portal children appended to it.\n *\n * You can also provide a callback, which is called in a React layout effect.\n * This lets you set the container from a ref, and also makes server-side rendering possible.\n *\n * By default, it uses the body of the top-level document object,\n * so it's simply `document.body` most of the time.\n */\n container: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.func]),\n /**\n * The `children` will be under the DOM hierarchy of the parent component.\n * @default false\n */\n disablePortal: PropTypes.bool\n} : void 0;\nif (process.env.NODE_ENV !== 'production') {\n // eslint-disable-next-line\n Portal['propTypes' + ''] = exactProp(Portal.propTypes);\n}\nexport { Portal };","export var top = 'top';\nexport var bottom = 'bottom';\nexport var right = 'right';\nexport var left = 'left';\nexport var auto = 'auto';\nexport var basePlacements = [top, bottom, right, left];\nexport var start = 'start';\nexport var end = 'end';\nexport var clippingParents = 'clippingParents';\nexport var viewport = 'viewport';\nexport var popper = 'popper';\nexport var reference = 'reference';\nexport var variationPlacements = /*#__PURE__*/basePlacements.reduce(function (acc, placement) {\n return acc.concat([placement + \"-\" + start, placement + \"-\" + end]);\n}, []);\nexport var placements = /*#__PURE__*/[].concat(basePlacements, [auto]).reduce(function (acc, placement) {\n return acc.concat([placement, placement + \"-\" + start, placement + \"-\" + end]);\n}, []); // modifiers that need to read the DOM\n\nexport var beforeRead = 'beforeRead';\nexport var read = 'read';\nexport var afterRead = 'afterRead'; // pure-logic modifiers\n\nexport var beforeMain = 'beforeMain';\nexport var main = 'main';\nexport var afterMain = 'afterMain'; // modifier with the purpose to write to the DOM (or write into a framework state)\n\nexport var beforeWrite = 'beforeWrite';\nexport var write = 'write';\nexport var afterWrite = 'afterWrite';\nexport var modifierPhases = [beforeRead, read, afterRead, beforeMain, main, afterMain, beforeWrite, write, afterWrite];","export default function getNodeName(element) {\n return element ? (element.nodeName || '').toLowerCase() : null;\n}","export default function getWindow(node) {\n if (node == null) {\n return window;\n }\n\n if (node.toString() !== '[object Window]') {\n var ownerDocument = node.ownerDocument;\n return ownerDocument ? ownerDocument.defaultView || window : window;\n }\n\n return node;\n}","import getWindow from \"./getWindow.js\";\n\nfunction isElement(node) {\n var OwnElement = getWindow(node).Element;\n return node instanceof OwnElement || node instanceof Element;\n}\n\nfunction isHTMLElement(node) {\n var OwnElement = getWindow(node).HTMLElement;\n return node instanceof OwnElement || node instanceof HTMLElement;\n}\n\nfunction isShadowRoot(node) {\n // IE 11 has no ShadowRoot\n if (typeof ShadowRoot === 'undefined') {\n return false;\n }\n\n var OwnElement = getWindow(node).ShadowRoot;\n return node instanceof OwnElement || node instanceof ShadowRoot;\n}\n\nexport { isElement, isHTMLElement, isShadowRoot };","import getNodeName from \"../dom-utils/getNodeName.js\";\nimport { isHTMLElement } from \"../dom-utils/instanceOf.js\"; // This modifier takes the styles prepared by the `computeStyles` modifier\n// and applies them to the HTMLElements such as popper and arrow\n\nfunction applyStyles(_ref) {\n var state = _ref.state;\n Object.keys(state.elements).forEach(function (name) {\n var style = state.styles[name] || {};\n var attributes = state.attributes[name] || {};\n var element = state.elements[name]; // arrow is optional + virtual elements\n\n if (!isHTMLElement(element) || !getNodeName(element)) {\n return;\n } // Flow doesn't support to extend this property, but it's the most\n // effective way to apply styles to an HTMLElement\n // $FlowFixMe[cannot-write]\n\n\n Object.assign(element.style, style);\n Object.keys(attributes).forEach(function (name) {\n var value = attributes[name];\n\n if (value === false) {\n element.removeAttribute(name);\n } else {\n element.setAttribute(name, value === true ? '' : value);\n }\n });\n });\n}\n\nfunction effect(_ref2) {\n var state = _ref2.state;\n var initialStyles = {\n popper: {\n position: state.options.strategy,\n left: '0',\n top: '0',\n margin: '0'\n },\n arrow: {\n position: 'absolute'\n },\n reference: {}\n };\n Object.assign(state.elements.popper.style, initialStyles.popper);\n state.styles = initialStyles;\n\n if (state.elements.arrow) {\n Object.assign(state.elements.arrow.style, initialStyles.arrow);\n }\n\n return function () {\n Object.keys(state.elements).forEach(function (name) {\n var element = state.elements[name];\n var attributes = state.attributes[name] || {};\n var styleProperties = Object.keys(state.styles.hasOwnProperty(name) ? state.styles[name] : initialStyles[name]); // Set all values to an empty string to unset them\n\n var style = styleProperties.reduce(function (style, property) {\n style[property] = '';\n return style;\n }, {}); // arrow is optional + virtual elements\n\n if (!isHTMLElement(element) || !getNodeName(element)) {\n return;\n }\n\n Object.assign(element.style, style);\n Object.keys(attributes).forEach(function (attribute) {\n element.removeAttribute(attribute);\n });\n });\n };\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'applyStyles',\n enabled: true,\n phase: 'write',\n fn: applyStyles,\n effect: effect,\n requires: ['computeStyles']\n};","import { auto } from \"../enums.js\";\nexport default function getBasePlacement(placement) {\n return placement.split('-')[0];\n}","export var max = Math.max;\nexport var min = Math.min;\nexport var round = Math.round;","export default function getUAString() {\n var uaData = navigator.userAgentData;\n\n if (uaData != null && uaData.brands && Array.isArray(uaData.brands)) {\n return uaData.brands.map(function (item) {\n return item.brand + \"/\" + item.version;\n }).join(' ');\n }\n\n return navigator.userAgent;\n}","import getUAString from \"../utils/userAgent.js\";\nexport default function isLayoutViewport() {\n return !/^((?!chrome|android).)*safari/i.test(getUAString());\n}","import { isElement, isHTMLElement } from \"./instanceOf.js\";\nimport { round } from \"../utils/math.js\";\nimport getWindow from \"./getWindow.js\";\nimport isLayoutViewport from \"./isLayoutViewport.js\";\nexport default function getBoundingClientRect(element, includeScale, isFixedStrategy) {\n if (includeScale === void 0) {\n includeScale = false;\n }\n\n if (isFixedStrategy === void 0) {\n isFixedStrategy = false;\n }\n\n var clientRect = element.getBoundingClientRect();\n var scaleX = 1;\n var scaleY = 1;\n\n if (includeScale && isHTMLElement(element)) {\n scaleX = element.offsetWidth > 0 ? round(clientRect.width) / element.offsetWidth || 1 : 1;\n scaleY = element.offsetHeight > 0 ? round(clientRect.height) / element.offsetHeight || 1 : 1;\n }\n\n var _ref = isElement(element) ? getWindow(element) : window,\n visualViewport = _ref.visualViewport;\n\n var addVisualOffsets = !isLayoutViewport() && isFixedStrategy;\n var x = (clientRect.left + (addVisualOffsets && visualViewport ? visualViewport.offsetLeft : 0)) / scaleX;\n var y = (clientRect.top + (addVisualOffsets && visualViewport ? visualViewport.offsetTop : 0)) / scaleY;\n var width = clientRect.width / scaleX;\n var height = clientRect.height / scaleY;\n return {\n width: width,\n height: height,\n top: y,\n right: x + width,\n bottom: y + height,\n left: x,\n x: x,\n y: y\n };\n}","import getBoundingClientRect from \"./getBoundingClientRect.js\"; // Returns the layout rect of an element relative to its offsetParent. Layout\n// means it doesn't take into account transforms.\n\nexport default function getLayoutRect(element) {\n var clientRect = getBoundingClientRect(element); // Use the clientRect sizes if it's not been transformed.\n // Fixes https://github.com/popperjs/popper-core/issues/1223\n\n var width = element.offsetWidth;\n var height = element.offsetHeight;\n\n if (Math.abs(clientRect.width - width) <= 1) {\n width = clientRect.width;\n }\n\n if (Math.abs(clientRect.height - height) <= 1) {\n height = clientRect.height;\n }\n\n return {\n x: element.offsetLeft,\n y: element.offsetTop,\n width: width,\n height: height\n };\n}","import { isShadowRoot } from \"./instanceOf.js\";\nexport default function contains(parent, child) {\n var rootNode = child.getRootNode && child.getRootNode(); // First, attempt with faster native method\n\n if (parent.contains(child)) {\n return true;\n } // then fallback to custom implementation with Shadow DOM support\n else if (rootNode && isShadowRoot(rootNode)) {\n var next = child;\n\n do {\n if (next && parent.isSameNode(next)) {\n return true;\n } // $FlowFixMe[prop-missing]: need a better way to handle this...\n\n\n next = next.parentNode || next.host;\n } while (next);\n } // Give up, the result is false\n\n\n return false;\n}","import getWindow from \"./getWindow.js\";\nexport default function getComputedStyle(element) {\n return getWindow(element).getComputedStyle(element);\n}","import getNodeName from \"./getNodeName.js\";\nexport default function isTableElement(element) {\n return ['table', 'td', 'th'].indexOf(getNodeName(element)) >= 0;\n}","import { isElement } from \"./instanceOf.js\";\nexport default function getDocumentElement(element) {\n // $FlowFixMe[incompatible-return]: assume body is always available\n return ((isElement(element) ? element.ownerDocument : // $FlowFixMe[prop-missing]\n element.document) || window.document).documentElement;\n}","import getNodeName from \"./getNodeName.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport { isShadowRoot } from \"./instanceOf.js\";\nexport default function getParentNode(element) {\n if (getNodeName(element) === 'html') {\n return element;\n }\n\n return (// this is a quicker (but less type safe) way to save quite some bytes from the bundle\n // $FlowFixMe[incompatible-return]\n // $FlowFixMe[prop-missing]\n element.assignedSlot || // step into the shadow DOM of the parent of a slotted node\n element.parentNode || ( // DOM Element detected\n isShadowRoot(element) ? element.host : null) || // ShadowRoot detected\n // $FlowFixMe[incompatible-call]: HTMLElement is a Node\n getDocumentElement(element) // fallback\n\n );\n}","import getWindow from \"./getWindow.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport getComputedStyle from \"./getComputedStyle.js\";\nimport { isHTMLElement, isShadowRoot } from \"./instanceOf.js\";\nimport isTableElement from \"./isTableElement.js\";\nimport getParentNode from \"./getParentNode.js\";\nimport getUAString from \"../utils/userAgent.js\";\n\nfunction getTrueOffsetParent(element) {\n if (!isHTMLElement(element) || // https://github.com/popperjs/popper-core/issues/837\n getComputedStyle(element).position === 'fixed') {\n return null;\n }\n\n return element.offsetParent;\n} // `.offsetParent` reports `null` for fixed elements, while absolute elements\n// return the containing block\n\n\nfunction getContainingBlock(element) {\n var isFirefox = /firefox/i.test(getUAString());\n var isIE = /Trident/i.test(getUAString());\n\n if (isIE && isHTMLElement(element)) {\n // In IE 9, 10 and 11 fixed elements containing block is always established by the viewport\n var elementCss = getComputedStyle(element);\n\n if (elementCss.position === 'fixed') {\n return null;\n }\n }\n\n var currentNode = getParentNode(element);\n\n if (isShadowRoot(currentNode)) {\n currentNode = currentNode.host;\n }\n\n while (isHTMLElement(currentNode) && ['html', 'body'].indexOf(getNodeName(currentNode)) < 0) {\n var css = getComputedStyle(currentNode); // This is non-exhaustive but covers the most common CSS properties that\n // create a containing block.\n // https://developer.mozilla.org/en-US/docs/Web/CSS/Containing_block#identifying_the_containing_block\n\n if (css.transform !== 'none' || css.perspective !== 'none' || css.contain === 'paint' || ['transform', 'perspective'].indexOf(css.willChange) !== -1 || isFirefox && css.willChange === 'filter' || isFirefox && css.filter && css.filter !== 'none') {\n return currentNode;\n } else {\n currentNode = currentNode.parentNode;\n }\n }\n\n return null;\n} // Gets the closest ancestor positioned element. Handles some edge cases,\n// such as table ancestors and cross browser bugs.\n\n\nexport default function getOffsetParent(element) {\n var window = getWindow(element);\n var offsetParent = getTrueOffsetParent(element);\n\n while (offsetParent && isTableElement(offsetParent) && getComputedStyle(offsetParent).position === 'static') {\n offsetParent = getTrueOffsetParent(offsetParent);\n }\n\n if (offsetParent && (getNodeName(offsetParent) === 'html' || getNodeName(offsetParent) === 'body' && getComputedStyle(offsetParent).position === 'static')) {\n return window;\n }\n\n return offsetParent || getContainingBlock(element) || window;\n}","export default function getMainAxisFromPlacement(placement) {\n return ['top', 'bottom'].indexOf(placement) >= 0 ? 'x' : 'y';\n}","import { max as mathMax, min as mathMin } from \"./math.js\";\nexport function within(min, value, max) {\n return mathMax(min, mathMin(value, max));\n}\nexport function withinMaxClamp(min, value, max) {\n var v = within(min, value, max);\n return v > max ? max : v;\n}","export default function getFreshSideObject() {\n return {\n top: 0,\n right: 0,\n bottom: 0,\n left: 0\n };\n}","import getFreshSideObject from \"./getFreshSideObject.js\";\nexport default function mergePaddingObject(paddingObject) {\n return Object.assign({}, getFreshSideObject(), paddingObject);\n}","export default function expandToHashMap(value, keys) {\n return keys.reduce(function (hashMap, key) {\n hashMap[key] = value;\n return hashMap;\n }, {});\n}","import getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getLayoutRect from \"../dom-utils/getLayoutRect.js\";\nimport contains from \"../dom-utils/contains.js\";\nimport getOffsetParent from \"../dom-utils/getOffsetParent.js\";\nimport getMainAxisFromPlacement from \"../utils/getMainAxisFromPlacement.js\";\nimport { within } from \"../utils/within.js\";\nimport mergePaddingObject from \"../utils/mergePaddingObject.js\";\nimport expandToHashMap from \"../utils/expandToHashMap.js\";\nimport { left, right, basePlacements, top, bottom } from \"../enums.js\"; // eslint-disable-next-line import/no-unused-modules\n\nvar toPaddingObject = function toPaddingObject(padding, state) {\n padding = typeof padding === 'function' ? padding(Object.assign({}, state.rects, {\n placement: state.placement\n })) : padding;\n return mergePaddingObject(typeof padding !== 'number' ? padding : expandToHashMap(padding, basePlacements));\n};\n\nfunction arrow(_ref) {\n var _state$modifiersData$;\n\n var state = _ref.state,\n name = _ref.name,\n options = _ref.options;\n var arrowElement = state.elements.arrow;\n var popperOffsets = state.modifiersData.popperOffsets;\n var basePlacement = getBasePlacement(state.placement);\n var axis = getMainAxisFromPlacement(basePlacement);\n var isVertical = [left, right].indexOf(basePlacement) >= 0;\n var len = isVertical ? 'height' : 'width';\n\n if (!arrowElement || !popperOffsets) {\n return;\n }\n\n var paddingObject = toPaddingObject(options.padding, state);\n var arrowRect = getLayoutRect(arrowElement);\n var minProp = axis === 'y' ? top : left;\n var maxProp = axis === 'y' ? bottom : right;\n var endDiff = state.rects.reference[len] + state.rects.reference[axis] - popperOffsets[axis] - state.rects.popper[len];\n var startDiff = popperOffsets[axis] - state.rects.reference[axis];\n var arrowOffsetParent = getOffsetParent(arrowElement);\n var clientSize = arrowOffsetParent ? axis === 'y' ? arrowOffsetParent.clientHeight || 0 : arrowOffsetParent.clientWidth || 0 : 0;\n var centerToReference = endDiff / 2 - startDiff / 2; // Make sure the arrow doesn't overflow the popper if the center point is\n // outside of the popper bounds\n\n var min = paddingObject[minProp];\n var max = clientSize - arrowRect[len] - paddingObject[maxProp];\n var center = clientSize / 2 - arrowRect[len] / 2 + centerToReference;\n var offset = within(min, center, max); // Prevents breaking syntax highlighting...\n\n var axisProp = axis;\n state.modifiersData[name] = (_state$modifiersData$ = {}, _state$modifiersData$[axisProp] = offset, _state$modifiersData$.centerOffset = offset - center, _state$modifiersData$);\n}\n\nfunction effect(_ref2) {\n var state = _ref2.state,\n options = _ref2.options;\n var _options$element = options.element,\n arrowElement = _options$element === void 0 ? '[data-popper-arrow]' : _options$element;\n\n if (arrowElement == null) {\n return;\n } // CSS selector\n\n\n if (typeof arrowElement === 'string') {\n arrowElement = state.elements.popper.querySelector(arrowElement);\n\n if (!arrowElement) {\n return;\n }\n }\n\n if (!contains(state.elements.popper, arrowElement)) {\n return;\n }\n\n state.elements.arrow = arrowElement;\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'arrow',\n enabled: true,\n phase: 'main',\n fn: arrow,\n effect: effect,\n requires: ['popperOffsets'],\n requiresIfExists: ['preventOverflow']\n};","export default function getVariation(placement) {\n return placement.split('-')[1];\n}","import { top, left, right, bottom, end } from \"../enums.js\";\nimport getOffsetParent from \"../dom-utils/getOffsetParent.js\";\nimport getWindow from \"../dom-utils/getWindow.js\";\nimport getDocumentElement from \"../dom-utils/getDocumentElement.js\";\nimport getComputedStyle from \"../dom-utils/getComputedStyle.js\";\nimport getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getVariation from \"../utils/getVariation.js\";\nimport { round } from \"../utils/math.js\"; // eslint-disable-next-line import/no-unused-modules\n\nvar unsetSides = {\n top: 'auto',\n right: 'auto',\n bottom: 'auto',\n left: 'auto'\n}; // Round the offsets to the nearest suitable subpixel based on the DPR.\n// Zooming can change the DPR, but it seems to report a value that will\n// cleanly divide the values into the appropriate subpixels.\n\nfunction roundOffsetsByDPR(_ref, win) {\n var x = _ref.x,\n y = _ref.y;\n var dpr = win.devicePixelRatio || 1;\n return {\n x: round(x * dpr) / dpr || 0,\n y: round(y * dpr) / dpr || 0\n };\n}\n\nexport function mapToStyles(_ref2) {\n var _Object$assign2;\n\n var popper = _ref2.popper,\n popperRect = _ref2.popperRect,\n placement = _ref2.placement,\n variation = _ref2.variation,\n offsets = _ref2.offsets,\n position = _ref2.position,\n gpuAcceleration = _ref2.gpuAcceleration,\n adaptive = _ref2.adaptive,\n roundOffsets = _ref2.roundOffsets,\n isFixed = _ref2.isFixed;\n var _offsets$x = offsets.x,\n x = _offsets$x === void 0 ? 0 : _offsets$x,\n _offsets$y = offsets.y,\n y = _offsets$y === void 0 ? 0 : _offsets$y;\n\n var _ref3 = typeof roundOffsets === 'function' ? roundOffsets({\n x: x,\n y: y\n }) : {\n x: x,\n y: y\n };\n\n x = _ref3.x;\n y = _ref3.y;\n var hasX = offsets.hasOwnProperty('x');\n var hasY = offsets.hasOwnProperty('y');\n var sideX = left;\n var sideY = top;\n var win = window;\n\n if (adaptive) {\n var offsetParent = getOffsetParent(popper);\n var heightProp = 'clientHeight';\n var widthProp = 'clientWidth';\n\n if (offsetParent === getWindow(popper)) {\n offsetParent = getDocumentElement(popper);\n\n if (getComputedStyle(offsetParent).position !== 'static' && position === 'absolute') {\n heightProp = 'scrollHeight';\n widthProp = 'scrollWidth';\n }\n } // $FlowFixMe[incompatible-cast]: force type refinement, we compare offsetParent with window above, but Flow doesn't detect it\n\n\n offsetParent = offsetParent;\n\n if (placement === top || (placement === left || placement === right) && variation === end) {\n sideY = bottom;\n var offsetY = isFixed && offsetParent === win && win.visualViewport ? win.visualViewport.height : // $FlowFixMe[prop-missing]\n offsetParent[heightProp];\n y -= offsetY - popperRect.height;\n y *= gpuAcceleration ? 1 : -1;\n }\n\n if (placement === left || (placement === top || placement === bottom) && variation === end) {\n sideX = right;\n var offsetX = isFixed && offsetParent === win && win.visualViewport ? win.visualViewport.width : // $FlowFixMe[prop-missing]\n offsetParent[widthProp];\n x -= offsetX - popperRect.width;\n x *= gpuAcceleration ? 1 : -1;\n }\n }\n\n var commonStyles = Object.assign({\n position: position\n }, adaptive && unsetSides);\n\n var _ref4 = roundOffsets === true ? roundOffsetsByDPR({\n x: x,\n y: y\n }, getWindow(popper)) : {\n x: x,\n y: y\n };\n\n x = _ref4.x;\n y = _ref4.y;\n\n if (gpuAcceleration) {\n var _Object$assign;\n\n return Object.assign({}, commonStyles, (_Object$assign = {}, _Object$assign[sideY] = hasY ? '0' : '', _Object$assign[sideX] = hasX ? '0' : '', _Object$assign.transform = (win.devicePixelRatio || 1) <= 1 ? \"translate(\" + x + \"px, \" + y + \"px)\" : \"translate3d(\" + x + \"px, \" + y + \"px, 0)\", _Object$assign));\n }\n\n return Object.assign({}, commonStyles, (_Object$assign2 = {}, _Object$assign2[sideY] = hasY ? y + \"px\" : '', _Object$assign2[sideX] = hasX ? x + \"px\" : '', _Object$assign2.transform = '', _Object$assign2));\n}\n\nfunction computeStyles(_ref5) {\n var state = _ref5.state,\n options = _ref5.options;\n var _options$gpuAccelerat = options.gpuAcceleration,\n gpuAcceleration = _options$gpuAccelerat === void 0 ? true : _options$gpuAccelerat,\n _options$adaptive = options.adaptive,\n adaptive = _options$adaptive === void 0 ? true : _options$adaptive,\n _options$roundOffsets = options.roundOffsets,\n roundOffsets = _options$roundOffsets === void 0 ? true : _options$roundOffsets;\n var commonStyles = {\n placement: getBasePlacement(state.placement),\n variation: getVariation(state.placement),\n popper: state.elements.popper,\n popperRect: state.rects.popper,\n gpuAcceleration: gpuAcceleration,\n isFixed: state.options.strategy === 'fixed'\n };\n\n if (state.modifiersData.popperOffsets != null) {\n state.styles.popper = Object.assign({}, state.styles.popper, mapToStyles(Object.assign({}, commonStyles, {\n offsets: state.modifiersData.popperOffsets,\n position: state.options.strategy,\n adaptive: adaptive,\n roundOffsets: roundOffsets\n })));\n }\n\n if (state.modifiersData.arrow != null) {\n state.styles.arrow = Object.assign({}, state.styles.arrow, mapToStyles(Object.assign({}, commonStyles, {\n offsets: state.modifiersData.arrow,\n position: 'absolute',\n adaptive: false,\n roundOffsets: roundOffsets\n })));\n }\n\n state.attributes.popper = Object.assign({}, state.attributes.popper, {\n 'data-popper-placement': state.placement\n });\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'computeStyles',\n enabled: true,\n phase: 'beforeWrite',\n fn: computeStyles,\n data: {}\n};","import getWindow from \"../dom-utils/getWindow.js\"; // eslint-disable-next-line import/no-unused-modules\n\nvar passive = {\n passive: true\n};\n\nfunction effect(_ref) {\n var state = _ref.state,\n instance = _ref.instance,\n options = _ref.options;\n var _options$scroll = options.scroll,\n scroll = _options$scroll === void 0 ? true : _options$scroll,\n _options$resize = options.resize,\n resize = _options$resize === void 0 ? true : _options$resize;\n var window = getWindow(state.elements.popper);\n var scrollParents = [].concat(state.scrollParents.reference, state.scrollParents.popper);\n\n if (scroll) {\n scrollParents.forEach(function (scrollParent) {\n scrollParent.addEventListener('scroll', instance.update, passive);\n });\n }\n\n if (resize) {\n window.addEventListener('resize', instance.update, passive);\n }\n\n return function () {\n if (scroll) {\n scrollParents.forEach(function (scrollParent) {\n scrollParent.removeEventListener('scroll', instance.update, passive);\n });\n }\n\n if (resize) {\n window.removeEventListener('resize', instance.update, passive);\n }\n };\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'eventListeners',\n enabled: true,\n phase: 'write',\n fn: function fn() {},\n effect: effect,\n data: {}\n};","var hash = {\n left: 'right',\n right: 'left',\n bottom: 'top',\n top: 'bottom'\n};\nexport default function getOppositePlacement(placement) {\n return placement.replace(/left|right|bottom|top/g, function (matched) {\n return hash[matched];\n });\n}","var hash = {\n start: 'end',\n end: 'start'\n};\nexport default function getOppositeVariationPlacement(placement) {\n return placement.replace(/start|end/g, function (matched) {\n return hash[matched];\n });\n}","import getWindow from \"./getWindow.js\";\nexport default function getWindowScroll(node) {\n var win = getWindow(node);\n var scrollLeft = win.pageXOffset;\n var scrollTop = win.pageYOffset;\n return {\n scrollLeft: scrollLeft,\n scrollTop: scrollTop\n };\n}","import getBoundingClientRect from \"./getBoundingClientRect.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport getWindowScroll from \"./getWindowScroll.js\";\nexport default function getWindowScrollBarX(element) {\n // If has a CSS width greater than the viewport, then this will be\n // incorrect for RTL.\n // Popper 1 is broken in this case and never had a bug report so let's assume\n // it's not an issue. I don't think anyone ever specifies width on \n // anyway.\n // Browsers where the left scrollbar doesn't cause an issue report `0` for\n // this (e.g. Edge 2019, IE11, Safari)\n return getBoundingClientRect(getDocumentElement(element)).left + getWindowScroll(element).scrollLeft;\n}","import getWindow from \"./getWindow.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport getWindowScrollBarX from \"./getWindowScrollBarX.js\";\nimport isLayoutViewport from \"./isLayoutViewport.js\";\nexport default function getViewportRect(element, strategy) {\n var win = getWindow(element);\n var html = getDocumentElement(element);\n var visualViewport = win.visualViewport;\n var width = html.clientWidth;\n var height = html.clientHeight;\n var x = 0;\n var y = 0;\n\n if (visualViewport) {\n width = visualViewport.width;\n height = visualViewport.height;\n var layoutViewport = isLayoutViewport();\n\n if (layoutViewport || !layoutViewport && strategy === 'fixed') {\n x = visualViewport.offsetLeft;\n y = visualViewport.offsetTop;\n }\n }\n\n return {\n width: width,\n height: height,\n x: x + getWindowScrollBarX(element),\n y: y\n };\n}","import getDocumentElement from \"./getDocumentElement.js\";\nimport getComputedStyle from \"./getComputedStyle.js\";\nimport getWindowScrollBarX from \"./getWindowScrollBarX.js\";\nimport getWindowScroll from \"./getWindowScroll.js\";\nimport { max } from \"../utils/math.js\"; // Gets the entire size of the scrollable document area, even extending outside\n// of the `` and `` rect bounds if horizontally scrollable\n\nexport default function getDocumentRect(element) {\n var _element$ownerDocumen;\n\n var html = getDocumentElement(element);\n var winScroll = getWindowScroll(element);\n var body = (_element$ownerDocumen = element.ownerDocument) == null ? void 0 : _element$ownerDocumen.body;\n var width = max(html.scrollWidth, html.clientWidth, body ? body.scrollWidth : 0, body ? body.clientWidth : 0);\n var height = max(html.scrollHeight, html.clientHeight, body ? body.scrollHeight : 0, body ? body.clientHeight : 0);\n var x = -winScroll.scrollLeft + getWindowScrollBarX(element);\n var y = -winScroll.scrollTop;\n\n if (getComputedStyle(body || html).direction === 'rtl') {\n x += max(html.clientWidth, body ? body.clientWidth : 0) - width;\n }\n\n return {\n width: width,\n height: height,\n x: x,\n y: y\n };\n}","import getComputedStyle from \"./getComputedStyle.js\";\nexport default function isScrollParent(element) {\n // Firefox wants us to check `-x` and `-y` variations as well\n var _getComputedStyle = getComputedStyle(element),\n overflow = _getComputedStyle.overflow,\n overflowX = _getComputedStyle.overflowX,\n overflowY = _getComputedStyle.overflowY;\n\n return /auto|scroll|overlay|hidden/.test(overflow + overflowY + overflowX);\n}","import getParentNode from \"./getParentNode.js\";\nimport isScrollParent from \"./isScrollParent.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport { isHTMLElement } from \"./instanceOf.js\";\nexport default function getScrollParent(node) {\n if (['html', 'body', '#document'].indexOf(getNodeName(node)) >= 0) {\n // $FlowFixMe[incompatible-return]: assume body is always available\n return node.ownerDocument.body;\n }\n\n if (isHTMLElement(node) && isScrollParent(node)) {\n return node;\n }\n\n return getScrollParent(getParentNode(node));\n}","import getScrollParent from \"./getScrollParent.js\";\nimport getParentNode from \"./getParentNode.js\";\nimport getWindow from \"./getWindow.js\";\nimport isScrollParent from \"./isScrollParent.js\";\n/*\ngiven a DOM element, return the list of all scroll parents, up the list of ancesors\nuntil we get to the top window object. This list is what we attach scroll listeners\nto, because if any of these parent elements scroll, we'll need to re-calculate the\nreference element's position.\n*/\n\nexport default function listScrollParents(element, list) {\n var _element$ownerDocumen;\n\n if (list === void 0) {\n list = [];\n }\n\n var scrollParent = getScrollParent(element);\n var isBody = scrollParent === ((_element$ownerDocumen = element.ownerDocument) == null ? void 0 : _element$ownerDocumen.body);\n var win = getWindow(scrollParent);\n var target = isBody ? [win].concat(win.visualViewport || [], isScrollParent(scrollParent) ? scrollParent : []) : scrollParent;\n var updatedList = list.concat(target);\n return isBody ? updatedList : // $FlowFixMe[incompatible-call]: isBody tells us target will be an HTMLElement here\n updatedList.concat(listScrollParents(getParentNode(target)));\n}","export default function rectToClientRect(rect) {\n return Object.assign({}, rect, {\n left: rect.x,\n top: rect.y,\n right: rect.x + rect.width,\n bottom: rect.y + rect.height\n });\n}","import { viewport } from \"../enums.js\";\nimport getViewportRect from \"./getViewportRect.js\";\nimport getDocumentRect from \"./getDocumentRect.js\";\nimport listScrollParents from \"./listScrollParents.js\";\nimport getOffsetParent from \"./getOffsetParent.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport getComputedStyle from \"./getComputedStyle.js\";\nimport { isElement, isHTMLElement } from \"./instanceOf.js\";\nimport getBoundingClientRect from \"./getBoundingClientRect.js\";\nimport getParentNode from \"./getParentNode.js\";\nimport contains from \"./contains.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport rectToClientRect from \"../utils/rectToClientRect.js\";\nimport { max, min } from \"../utils/math.js\";\n\nfunction getInnerBoundingClientRect(element, strategy) {\n var rect = getBoundingClientRect(element, false, strategy === 'fixed');\n rect.top = rect.top + element.clientTop;\n rect.left = rect.left + element.clientLeft;\n rect.bottom = rect.top + element.clientHeight;\n rect.right = rect.left + element.clientWidth;\n rect.width = element.clientWidth;\n rect.height = element.clientHeight;\n rect.x = rect.left;\n rect.y = rect.top;\n return rect;\n}\n\nfunction getClientRectFromMixedType(element, clippingParent, strategy) {\n return clippingParent === viewport ? rectToClientRect(getViewportRect(element, strategy)) : isElement(clippingParent) ? getInnerBoundingClientRect(clippingParent, strategy) : rectToClientRect(getDocumentRect(getDocumentElement(element)));\n} // A \"clipping parent\" is an overflowable container with the characteristic of\n// clipping (or hiding) overflowing elements with a position different from\n// `initial`\n\n\nfunction getClippingParents(element) {\n var clippingParents = listScrollParents(getParentNode(element));\n var canEscapeClipping = ['absolute', 'fixed'].indexOf(getComputedStyle(element).position) >= 0;\n var clipperElement = canEscapeClipping && isHTMLElement(element) ? getOffsetParent(element) : element;\n\n if (!isElement(clipperElement)) {\n return [];\n } // $FlowFixMe[incompatible-return]: https://github.com/facebook/flow/issues/1414\n\n\n return clippingParents.filter(function (clippingParent) {\n return isElement(clippingParent) && contains(clippingParent, clipperElement) && getNodeName(clippingParent) !== 'body';\n });\n} // Gets the maximum area that the element is visible in due to any number of\n// clipping parents\n\n\nexport default function getClippingRect(element, boundary, rootBoundary, strategy) {\n var mainClippingParents = boundary === 'clippingParents' ? getClippingParents(element) : [].concat(boundary);\n var clippingParents = [].concat(mainClippingParents, [rootBoundary]);\n var firstClippingParent = clippingParents[0];\n var clippingRect = clippingParents.reduce(function (accRect, clippingParent) {\n var rect = getClientRectFromMixedType(element, clippingParent, strategy);\n accRect.top = max(rect.top, accRect.top);\n accRect.right = min(rect.right, accRect.right);\n accRect.bottom = min(rect.bottom, accRect.bottom);\n accRect.left = max(rect.left, accRect.left);\n return accRect;\n }, getClientRectFromMixedType(element, firstClippingParent, strategy));\n clippingRect.width = clippingRect.right - clippingRect.left;\n clippingRect.height = clippingRect.bottom - clippingRect.top;\n clippingRect.x = clippingRect.left;\n clippingRect.y = clippingRect.top;\n return clippingRect;\n}","import getBasePlacement from \"./getBasePlacement.js\";\nimport getVariation from \"./getVariation.js\";\nimport getMainAxisFromPlacement from \"./getMainAxisFromPlacement.js\";\nimport { top, right, bottom, left, start, end } from \"../enums.js\";\nexport default function computeOffsets(_ref) {\n var reference = _ref.reference,\n element = _ref.element,\n placement = _ref.placement;\n var basePlacement = placement ? getBasePlacement(placement) : null;\n var variation = placement ? getVariation(placement) : null;\n var commonX = reference.x + reference.width / 2 - element.width / 2;\n var commonY = reference.y + reference.height / 2 - element.height / 2;\n var offsets;\n\n switch (basePlacement) {\n case top:\n offsets = {\n x: commonX,\n y: reference.y - element.height\n };\n break;\n\n case bottom:\n offsets = {\n x: commonX,\n y: reference.y + reference.height\n };\n break;\n\n case right:\n offsets = {\n x: reference.x + reference.width,\n y: commonY\n };\n break;\n\n case left:\n offsets = {\n x: reference.x - element.width,\n y: commonY\n };\n break;\n\n default:\n offsets = {\n x: reference.x,\n y: reference.y\n };\n }\n\n var mainAxis = basePlacement ? getMainAxisFromPlacement(basePlacement) : null;\n\n if (mainAxis != null) {\n var len = mainAxis === 'y' ? 'height' : 'width';\n\n switch (variation) {\n case start:\n offsets[mainAxis] = offsets[mainAxis] - (reference[len] / 2 - element[len] / 2);\n break;\n\n case end:\n offsets[mainAxis] = offsets[mainAxis] + (reference[len] / 2 - element[len] / 2);\n break;\n\n default:\n }\n }\n\n return offsets;\n}","import getClippingRect from \"../dom-utils/getClippingRect.js\";\nimport getDocumentElement from \"../dom-utils/getDocumentElement.js\";\nimport getBoundingClientRect from \"../dom-utils/getBoundingClientRect.js\";\nimport computeOffsets from \"./computeOffsets.js\";\nimport rectToClientRect from \"./rectToClientRect.js\";\nimport { clippingParents, reference, popper, bottom, top, right, basePlacements, viewport } from \"../enums.js\";\nimport { isElement } from \"../dom-utils/instanceOf.js\";\nimport mergePaddingObject from \"./mergePaddingObject.js\";\nimport expandToHashMap from \"./expandToHashMap.js\"; // eslint-disable-next-line import/no-unused-modules\n\nexport default function detectOverflow(state, options) {\n if (options === void 0) {\n options = {};\n }\n\n var _options = options,\n _options$placement = _options.placement,\n placement = _options$placement === void 0 ? state.placement : _options$placement,\n _options$strategy = _options.strategy,\n strategy = _options$strategy === void 0 ? state.strategy : _options$strategy,\n _options$boundary = _options.boundary,\n boundary = _options$boundary === void 0 ? clippingParents : _options$boundary,\n _options$rootBoundary = _options.rootBoundary,\n rootBoundary = _options$rootBoundary === void 0 ? viewport : _options$rootBoundary,\n _options$elementConte = _options.elementContext,\n elementContext = _options$elementConte === void 0 ? popper : _options$elementConte,\n _options$altBoundary = _options.altBoundary,\n altBoundary = _options$altBoundary === void 0 ? false : _options$altBoundary,\n _options$padding = _options.padding,\n padding = _options$padding === void 0 ? 0 : _options$padding;\n var paddingObject = mergePaddingObject(typeof padding !== 'number' ? padding : expandToHashMap(padding, basePlacements));\n var altContext = elementContext === popper ? reference : popper;\n var popperRect = state.rects.popper;\n var element = state.elements[altBoundary ? altContext : elementContext];\n var clippingClientRect = getClippingRect(isElement(element) ? element : element.contextElement || getDocumentElement(state.elements.popper), boundary, rootBoundary, strategy);\n var referenceClientRect = getBoundingClientRect(state.elements.reference);\n var popperOffsets = computeOffsets({\n reference: referenceClientRect,\n element: popperRect,\n strategy: 'absolute',\n placement: placement\n });\n var popperClientRect = rectToClientRect(Object.assign({}, popperRect, popperOffsets));\n var elementClientRect = elementContext === popper ? popperClientRect : referenceClientRect; // positive = overflowing the clipping rect\n // 0 or negative = within the clipping rect\n\n var overflowOffsets = {\n top: clippingClientRect.top - elementClientRect.top + paddingObject.top,\n bottom: elementClientRect.bottom - clippingClientRect.bottom + paddingObject.bottom,\n left: clippingClientRect.left - elementClientRect.left + paddingObject.left,\n right: elementClientRect.right - clippingClientRect.right + paddingObject.right\n };\n var offsetData = state.modifiersData.offset; // Offsets can be applied only to the popper element\n\n if (elementContext === popper && offsetData) {\n var offset = offsetData[placement];\n Object.keys(overflowOffsets).forEach(function (key) {\n var multiply = [right, bottom].indexOf(key) >= 0 ? 1 : -1;\n var axis = [top, bottom].indexOf(key) >= 0 ? 'y' : 'x';\n overflowOffsets[key] += offset[axis] * multiply;\n });\n }\n\n return overflowOffsets;\n}","import getVariation from \"./getVariation.js\";\nimport { variationPlacements, basePlacements, placements as allPlacements } from \"../enums.js\";\nimport detectOverflow from \"./detectOverflow.js\";\nimport getBasePlacement from \"./getBasePlacement.js\";\nexport default function computeAutoPlacement(state, options) {\n if (options === void 0) {\n options = {};\n }\n\n var _options = options,\n placement = _options.placement,\n boundary = _options.boundary,\n rootBoundary = _options.rootBoundary,\n padding = _options.padding,\n flipVariations = _options.flipVariations,\n _options$allowedAutoP = _options.allowedAutoPlacements,\n allowedAutoPlacements = _options$allowedAutoP === void 0 ? allPlacements : _options$allowedAutoP;\n var variation = getVariation(placement);\n var placements = variation ? flipVariations ? variationPlacements : variationPlacements.filter(function (placement) {\n return getVariation(placement) === variation;\n }) : basePlacements;\n var allowedPlacements = placements.filter(function (placement) {\n return allowedAutoPlacements.indexOf(placement) >= 0;\n });\n\n if (allowedPlacements.length === 0) {\n allowedPlacements = placements;\n } // $FlowFixMe[incompatible-type]: Flow seems to have problems with two array unions...\n\n\n var overflows = allowedPlacements.reduce(function (acc, placement) {\n acc[placement] = detectOverflow(state, {\n placement: placement,\n boundary: boundary,\n rootBoundary: rootBoundary,\n padding: padding\n })[getBasePlacement(placement)];\n return acc;\n }, {});\n return Object.keys(overflows).sort(function (a, b) {\n return overflows[a] - overflows[b];\n });\n}","import getOppositePlacement from \"../utils/getOppositePlacement.js\";\nimport getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getOppositeVariationPlacement from \"../utils/getOppositeVariationPlacement.js\";\nimport detectOverflow from \"../utils/detectOverflow.js\";\nimport computeAutoPlacement from \"../utils/computeAutoPlacement.js\";\nimport { bottom, top, start, right, left, auto } from \"../enums.js\";\nimport getVariation from \"../utils/getVariation.js\"; // eslint-disable-next-line import/no-unused-modules\n\nfunction getExpandedFallbackPlacements(placement) {\n if (getBasePlacement(placement) === auto) {\n return [];\n }\n\n var oppositePlacement = getOppositePlacement(placement);\n return [getOppositeVariationPlacement(placement), oppositePlacement, getOppositeVariationPlacement(oppositePlacement)];\n}\n\nfunction flip(_ref) {\n var state = _ref.state,\n options = _ref.options,\n name = _ref.name;\n\n if (state.modifiersData[name]._skip) {\n return;\n }\n\n var _options$mainAxis = options.mainAxis,\n checkMainAxis = _options$mainAxis === void 0 ? true : _options$mainAxis,\n _options$altAxis = options.altAxis,\n checkAltAxis = _options$altAxis === void 0 ? true : _options$altAxis,\n specifiedFallbackPlacements = options.fallbackPlacements,\n padding = options.padding,\n boundary = options.boundary,\n rootBoundary = options.rootBoundary,\n altBoundary = options.altBoundary,\n _options$flipVariatio = options.flipVariations,\n flipVariations = _options$flipVariatio === void 0 ? true : _options$flipVariatio,\n allowedAutoPlacements = options.allowedAutoPlacements;\n var preferredPlacement = state.options.placement;\n var basePlacement = getBasePlacement(preferredPlacement);\n var isBasePlacement = basePlacement === preferredPlacement;\n var fallbackPlacements = specifiedFallbackPlacements || (isBasePlacement || !flipVariations ? [getOppositePlacement(preferredPlacement)] : getExpandedFallbackPlacements(preferredPlacement));\n var placements = [preferredPlacement].concat(fallbackPlacements).reduce(function (acc, placement) {\n return acc.concat(getBasePlacement(placement) === auto ? computeAutoPlacement(state, {\n placement: placement,\n boundary: boundary,\n rootBoundary: rootBoundary,\n padding: padding,\n flipVariations: flipVariations,\n allowedAutoPlacements: allowedAutoPlacements\n }) : placement);\n }, []);\n var referenceRect = state.rects.reference;\n var popperRect = state.rects.popper;\n var checksMap = new Map();\n var makeFallbackChecks = true;\n var firstFittingPlacement = placements[0];\n\n for (var i = 0; i < placements.length; i++) {\n var placement = placements[i];\n\n var _basePlacement = getBasePlacement(placement);\n\n var isStartVariation = getVariation(placement) === start;\n var isVertical = [top, bottom].indexOf(_basePlacement) >= 0;\n var len = isVertical ? 'width' : 'height';\n var overflow = detectOverflow(state, {\n placement: placement,\n boundary: boundary,\n rootBoundary: rootBoundary,\n altBoundary: altBoundary,\n padding: padding\n });\n var mainVariationSide = isVertical ? isStartVariation ? right : left : isStartVariation ? bottom : top;\n\n if (referenceRect[len] > popperRect[len]) {\n mainVariationSide = getOppositePlacement(mainVariationSide);\n }\n\n var altVariationSide = getOppositePlacement(mainVariationSide);\n var checks = [];\n\n if (checkMainAxis) {\n checks.push(overflow[_basePlacement] <= 0);\n }\n\n if (checkAltAxis) {\n checks.push(overflow[mainVariationSide] <= 0, overflow[altVariationSide] <= 0);\n }\n\n if (checks.every(function (check) {\n return check;\n })) {\n firstFittingPlacement = placement;\n makeFallbackChecks = false;\n break;\n }\n\n checksMap.set(placement, checks);\n }\n\n if (makeFallbackChecks) {\n // `2` may be desired in some cases – research later\n var numberOfChecks = flipVariations ? 3 : 1;\n\n var _loop = function _loop(_i) {\n var fittingPlacement = placements.find(function (placement) {\n var checks = checksMap.get(placement);\n\n if (checks) {\n return checks.slice(0, _i).every(function (check) {\n return check;\n });\n }\n });\n\n if (fittingPlacement) {\n firstFittingPlacement = fittingPlacement;\n return \"break\";\n }\n };\n\n for (var _i = numberOfChecks; _i > 0; _i--) {\n var _ret = _loop(_i);\n\n if (_ret === \"break\") break;\n }\n }\n\n if (state.placement !== firstFittingPlacement) {\n state.modifiersData[name]._skip = true;\n state.placement = firstFittingPlacement;\n state.reset = true;\n }\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'flip',\n enabled: true,\n phase: 'main',\n fn: flip,\n requiresIfExists: ['offset'],\n data: {\n _skip: false\n }\n};","import { top, bottom, left, right } from \"../enums.js\";\nimport detectOverflow from \"../utils/detectOverflow.js\";\n\nfunction getSideOffsets(overflow, rect, preventedOffsets) {\n if (preventedOffsets === void 0) {\n preventedOffsets = {\n x: 0,\n y: 0\n };\n }\n\n return {\n top: overflow.top - rect.height - preventedOffsets.y,\n right: overflow.right - rect.width + preventedOffsets.x,\n bottom: overflow.bottom - rect.height + preventedOffsets.y,\n left: overflow.left - rect.width - preventedOffsets.x\n };\n}\n\nfunction isAnySideFullyClipped(overflow) {\n return [top, right, bottom, left].some(function (side) {\n return overflow[side] >= 0;\n });\n}\n\nfunction hide(_ref) {\n var state = _ref.state,\n name = _ref.name;\n var referenceRect = state.rects.reference;\n var popperRect = state.rects.popper;\n var preventedOffsets = state.modifiersData.preventOverflow;\n var referenceOverflow = detectOverflow(state, {\n elementContext: 'reference'\n });\n var popperAltOverflow = detectOverflow(state, {\n altBoundary: true\n });\n var referenceClippingOffsets = getSideOffsets(referenceOverflow, referenceRect);\n var popperEscapeOffsets = getSideOffsets(popperAltOverflow, popperRect, preventedOffsets);\n var isReferenceHidden = isAnySideFullyClipped(referenceClippingOffsets);\n var hasPopperEscaped = isAnySideFullyClipped(popperEscapeOffsets);\n state.modifiersData[name] = {\n referenceClippingOffsets: referenceClippingOffsets,\n popperEscapeOffsets: popperEscapeOffsets,\n isReferenceHidden: isReferenceHidden,\n hasPopperEscaped: hasPopperEscaped\n };\n state.attributes.popper = Object.assign({}, state.attributes.popper, {\n 'data-popper-reference-hidden': isReferenceHidden,\n 'data-popper-escaped': hasPopperEscaped\n });\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'hide',\n enabled: true,\n phase: 'main',\n requiresIfExists: ['preventOverflow'],\n fn: hide\n};","import getBasePlacement from \"../utils/getBasePlacement.js\";\nimport { top, left, right, placements } from \"../enums.js\"; // eslint-disable-next-line import/no-unused-modules\n\nexport function distanceAndSkiddingToXY(placement, rects, offset) {\n var basePlacement = getBasePlacement(placement);\n var invertDistance = [left, top].indexOf(basePlacement) >= 0 ? -1 : 1;\n\n var _ref = typeof offset === 'function' ? offset(Object.assign({}, rects, {\n placement: placement\n })) : offset,\n skidding = _ref[0],\n distance = _ref[1];\n\n skidding = skidding || 0;\n distance = (distance || 0) * invertDistance;\n return [left, right].indexOf(basePlacement) >= 0 ? {\n x: distance,\n y: skidding\n } : {\n x: skidding,\n y: distance\n };\n}\n\nfunction offset(_ref2) {\n var state = _ref2.state,\n options = _ref2.options,\n name = _ref2.name;\n var _options$offset = options.offset,\n offset = _options$offset === void 0 ? [0, 0] : _options$offset;\n var data = placements.reduce(function (acc, placement) {\n acc[placement] = distanceAndSkiddingToXY(placement, state.rects, offset);\n return acc;\n }, {});\n var _data$state$placement = data[state.placement],\n x = _data$state$placement.x,\n y = _data$state$placement.y;\n\n if (state.modifiersData.popperOffsets != null) {\n state.modifiersData.popperOffsets.x += x;\n state.modifiersData.popperOffsets.y += y;\n }\n\n state.modifiersData[name] = data;\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'offset',\n enabled: true,\n phase: 'main',\n requires: ['popperOffsets'],\n fn: offset\n};","import computeOffsets from \"../utils/computeOffsets.js\";\n\nfunction popperOffsets(_ref) {\n var state = _ref.state,\n name = _ref.name;\n // Offsets are the actual position the popper needs to have to be\n // properly positioned near its reference element\n // This is the most basic placement, and will be adjusted by\n // the modifiers in the next step\n state.modifiersData[name] = computeOffsets({\n reference: state.rects.reference,\n element: state.rects.popper,\n strategy: 'absolute',\n placement: state.placement\n });\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'popperOffsets',\n enabled: true,\n phase: 'read',\n fn: popperOffsets,\n data: {}\n};","export default function getAltAxis(axis) {\n return axis === 'x' ? 'y' : 'x';\n}","import { top, left, right, bottom, start } from \"../enums.js\";\nimport getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getMainAxisFromPlacement from \"../utils/getMainAxisFromPlacement.js\";\nimport getAltAxis from \"../utils/getAltAxis.js\";\nimport { within, withinMaxClamp } from \"../utils/within.js\";\nimport getLayoutRect from \"../dom-utils/getLayoutRect.js\";\nimport getOffsetParent from \"../dom-utils/getOffsetParent.js\";\nimport detectOverflow from \"../utils/detectOverflow.js\";\nimport getVariation from \"../utils/getVariation.js\";\nimport getFreshSideObject from \"../utils/getFreshSideObject.js\";\nimport { min as mathMin, max as mathMax } from \"../utils/math.js\";\n\nfunction preventOverflow(_ref) {\n var state = _ref.state,\n options = _ref.options,\n name = _ref.name;\n var _options$mainAxis = options.mainAxis,\n checkMainAxis = _options$mainAxis === void 0 ? true : _options$mainAxis,\n _options$altAxis = options.altAxis,\n checkAltAxis = _options$altAxis === void 0 ? false : _options$altAxis,\n boundary = options.boundary,\n rootBoundary = options.rootBoundary,\n altBoundary = options.altBoundary,\n padding = options.padding,\n _options$tether = options.tether,\n tether = _options$tether === void 0 ? true : _options$tether,\n _options$tetherOffset = options.tetherOffset,\n tetherOffset = _options$tetherOffset === void 0 ? 0 : _options$tetherOffset;\n var overflow = detectOverflow(state, {\n boundary: boundary,\n rootBoundary: rootBoundary,\n padding: padding,\n altBoundary: altBoundary\n });\n var basePlacement = getBasePlacement(state.placement);\n var variation = getVariation(state.placement);\n var isBasePlacement = !variation;\n var mainAxis = getMainAxisFromPlacement(basePlacement);\n var altAxis = getAltAxis(mainAxis);\n var popperOffsets = state.modifiersData.popperOffsets;\n var referenceRect = state.rects.reference;\n var popperRect = state.rects.popper;\n var tetherOffsetValue = typeof tetherOffset === 'function' ? tetherOffset(Object.assign({}, state.rects, {\n placement: state.placement\n })) : tetherOffset;\n var normalizedTetherOffsetValue = typeof tetherOffsetValue === 'number' ? {\n mainAxis: tetherOffsetValue,\n altAxis: tetherOffsetValue\n } : Object.assign({\n mainAxis: 0,\n altAxis: 0\n }, tetherOffsetValue);\n var offsetModifierState = state.modifiersData.offset ? state.modifiersData.offset[state.placement] : null;\n var data = {\n x: 0,\n y: 0\n };\n\n if (!popperOffsets) {\n return;\n }\n\n if (checkMainAxis) {\n var _offsetModifierState$;\n\n var mainSide = mainAxis === 'y' ? top : left;\n var altSide = mainAxis === 'y' ? bottom : right;\n var len = mainAxis === 'y' ? 'height' : 'width';\n var offset = popperOffsets[mainAxis];\n var min = offset + overflow[mainSide];\n var max = offset - overflow[altSide];\n var additive = tether ? -popperRect[len] / 2 : 0;\n var minLen = variation === start ? referenceRect[len] : popperRect[len];\n var maxLen = variation === start ? -popperRect[len] : -referenceRect[len]; // We need to include the arrow in the calculation so the arrow doesn't go\n // outside the reference bounds\n\n var arrowElement = state.elements.arrow;\n var arrowRect = tether && arrowElement ? getLayoutRect(arrowElement) : {\n width: 0,\n height: 0\n };\n var arrowPaddingObject = state.modifiersData['arrow#persistent'] ? state.modifiersData['arrow#persistent'].padding : getFreshSideObject();\n var arrowPaddingMin = arrowPaddingObject[mainSide];\n var arrowPaddingMax = arrowPaddingObject[altSide]; // If the reference length is smaller than the arrow length, we don't want\n // to include its full size in the calculation. If the reference is small\n // and near the edge of a boundary, the popper can overflow even if the\n // reference is not overflowing as well (e.g. virtual elements with no\n // width or height)\n\n var arrowLen = within(0, referenceRect[len], arrowRect[len]);\n var minOffset = isBasePlacement ? referenceRect[len] / 2 - additive - arrowLen - arrowPaddingMin - normalizedTetherOffsetValue.mainAxis : minLen - arrowLen - arrowPaddingMin - normalizedTetherOffsetValue.mainAxis;\n var maxOffset = isBasePlacement ? -referenceRect[len] / 2 + additive + arrowLen + arrowPaddingMax + normalizedTetherOffsetValue.mainAxis : maxLen + arrowLen + arrowPaddingMax + normalizedTetherOffsetValue.mainAxis;\n var arrowOffsetParent = state.elements.arrow && getOffsetParent(state.elements.arrow);\n var clientOffset = arrowOffsetParent ? mainAxis === 'y' ? arrowOffsetParent.clientTop || 0 : arrowOffsetParent.clientLeft || 0 : 0;\n var offsetModifierValue = (_offsetModifierState$ = offsetModifierState == null ? void 0 : offsetModifierState[mainAxis]) != null ? _offsetModifierState$ : 0;\n var tetherMin = offset + minOffset - offsetModifierValue - clientOffset;\n var tetherMax = offset + maxOffset - offsetModifierValue;\n var preventedOffset = within(tether ? mathMin(min, tetherMin) : min, offset, tether ? mathMax(max, tetherMax) : max);\n popperOffsets[mainAxis] = preventedOffset;\n data[mainAxis] = preventedOffset - offset;\n }\n\n if (checkAltAxis) {\n var _offsetModifierState$2;\n\n var _mainSide = mainAxis === 'x' ? top : left;\n\n var _altSide = mainAxis === 'x' ? bottom : right;\n\n var _offset = popperOffsets[altAxis];\n\n var _len = altAxis === 'y' ? 'height' : 'width';\n\n var _min = _offset + overflow[_mainSide];\n\n var _max = _offset - overflow[_altSide];\n\n var isOriginSide = [top, left].indexOf(basePlacement) !== -1;\n\n var _offsetModifierValue = (_offsetModifierState$2 = offsetModifierState == null ? void 0 : offsetModifierState[altAxis]) != null ? _offsetModifierState$2 : 0;\n\n var _tetherMin = isOriginSide ? _min : _offset - referenceRect[_len] - popperRect[_len] - _offsetModifierValue + normalizedTetherOffsetValue.altAxis;\n\n var _tetherMax = isOriginSide ? _offset + referenceRect[_len] + popperRect[_len] - _offsetModifierValue - normalizedTetherOffsetValue.altAxis : _max;\n\n var _preventedOffset = tether && isOriginSide ? withinMaxClamp(_tetherMin, _offset, _tetherMax) : within(tether ? _tetherMin : _min, _offset, tether ? _tetherMax : _max);\n\n popperOffsets[altAxis] = _preventedOffset;\n data[altAxis] = _preventedOffset - _offset;\n }\n\n state.modifiersData[name] = data;\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'preventOverflow',\n enabled: true,\n phase: 'main',\n fn: preventOverflow,\n requiresIfExists: ['offset']\n};","export default function getHTMLElementScroll(element) {\n return {\n scrollLeft: element.scrollLeft,\n scrollTop: element.scrollTop\n };\n}","import getWindowScroll from \"./getWindowScroll.js\";\nimport getWindow from \"./getWindow.js\";\nimport { isHTMLElement } from \"./instanceOf.js\";\nimport getHTMLElementScroll from \"./getHTMLElementScroll.js\";\nexport default function getNodeScroll(node) {\n if (node === getWindow(node) || !isHTMLElement(node)) {\n return getWindowScroll(node);\n } else {\n return getHTMLElementScroll(node);\n }\n}","import getBoundingClientRect from \"./getBoundingClientRect.js\";\nimport getNodeScroll from \"./getNodeScroll.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport { isHTMLElement } from \"./instanceOf.js\";\nimport getWindowScrollBarX from \"./getWindowScrollBarX.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport isScrollParent from \"./isScrollParent.js\";\nimport { round } from \"../utils/math.js\";\n\nfunction isElementScaled(element) {\n var rect = element.getBoundingClientRect();\n var scaleX = round(rect.width) / element.offsetWidth || 1;\n var scaleY = round(rect.height) / element.offsetHeight || 1;\n return scaleX !== 1 || scaleY !== 1;\n} // Returns the composite rect of an element relative to its offsetParent.\n// Composite means it takes into account transforms as well as layout.\n\n\nexport default function getCompositeRect(elementOrVirtualElement, offsetParent, isFixed) {\n if (isFixed === void 0) {\n isFixed = false;\n }\n\n var isOffsetParentAnElement = isHTMLElement(offsetParent);\n var offsetParentIsScaled = isHTMLElement(offsetParent) && isElementScaled(offsetParent);\n var documentElement = getDocumentElement(offsetParent);\n var rect = getBoundingClientRect(elementOrVirtualElement, offsetParentIsScaled, isFixed);\n var scroll = {\n scrollLeft: 0,\n scrollTop: 0\n };\n var offsets = {\n x: 0,\n y: 0\n };\n\n if (isOffsetParentAnElement || !isOffsetParentAnElement && !isFixed) {\n if (getNodeName(offsetParent) !== 'body' || // https://github.com/popperjs/popper-core/issues/1078\n isScrollParent(documentElement)) {\n scroll = getNodeScroll(offsetParent);\n }\n\n if (isHTMLElement(offsetParent)) {\n offsets = getBoundingClientRect(offsetParent, true);\n offsets.x += offsetParent.clientLeft;\n offsets.y += offsetParent.clientTop;\n } else if (documentElement) {\n offsets.x = getWindowScrollBarX(documentElement);\n }\n }\n\n return {\n x: rect.left + scroll.scrollLeft - offsets.x,\n y: rect.top + scroll.scrollTop - offsets.y,\n width: rect.width,\n height: rect.height\n };\n}","import { modifierPhases } from \"../enums.js\"; // source: https://stackoverflow.com/questions/49875255\n\nfunction order(modifiers) {\n var map = new Map();\n var visited = new Set();\n var result = [];\n modifiers.forEach(function (modifier) {\n map.set(modifier.name, modifier);\n }); // On visiting object, check for its dependencies and visit them recursively\n\n function sort(modifier) {\n visited.add(modifier.name);\n var requires = [].concat(modifier.requires || [], modifier.requiresIfExists || []);\n requires.forEach(function (dep) {\n if (!visited.has(dep)) {\n var depModifier = map.get(dep);\n\n if (depModifier) {\n sort(depModifier);\n }\n }\n });\n result.push(modifier);\n }\n\n modifiers.forEach(function (modifier) {\n if (!visited.has(modifier.name)) {\n // check for visited object\n sort(modifier);\n }\n });\n return result;\n}\n\nexport default function orderModifiers(modifiers) {\n // order based on dependencies\n var orderedModifiers = order(modifiers); // order based on phase\n\n return modifierPhases.reduce(function (acc, phase) {\n return acc.concat(orderedModifiers.filter(function (modifier) {\n return modifier.phase === phase;\n }));\n }, []);\n}","export default function debounce(fn) {\n var pending;\n return function () {\n if (!pending) {\n pending = new Promise(function (resolve) {\n Promise.resolve().then(function () {\n pending = undefined;\n resolve(fn());\n });\n });\n }\n\n return pending;\n };\n}","export default function mergeByName(modifiers) {\n var merged = modifiers.reduce(function (merged, current) {\n var existing = merged[current.name];\n merged[current.name] = existing ? Object.assign({}, existing, current, {\n options: Object.assign({}, existing.options, current.options),\n data: Object.assign({}, existing.data, current.data)\n }) : current;\n return merged;\n }, {}); // IE11 does not support Object.values\n\n return Object.keys(merged).map(function (key) {\n return merged[key];\n });\n}","import getCompositeRect from \"./dom-utils/getCompositeRect.js\";\nimport getLayoutRect from \"./dom-utils/getLayoutRect.js\";\nimport listScrollParents from \"./dom-utils/listScrollParents.js\";\nimport getOffsetParent from \"./dom-utils/getOffsetParent.js\";\nimport orderModifiers from \"./utils/orderModifiers.js\";\nimport debounce from \"./utils/debounce.js\";\nimport mergeByName from \"./utils/mergeByName.js\";\nimport detectOverflow from \"./utils/detectOverflow.js\";\nimport { isElement } from \"./dom-utils/instanceOf.js\";\nvar DEFAULT_OPTIONS = {\n placement: 'bottom',\n modifiers: [],\n strategy: 'absolute'\n};\n\nfunction areValidElements() {\n for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {\n args[_key] = arguments[_key];\n }\n\n return !args.some(function (element) {\n return !(element && typeof element.getBoundingClientRect === 'function');\n });\n}\n\nexport function popperGenerator(generatorOptions) {\n if (generatorOptions === void 0) {\n generatorOptions = {};\n }\n\n var _generatorOptions = generatorOptions,\n _generatorOptions$def = _generatorOptions.defaultModifiers,\n defaultModifiers = _generatorOptions$def === void 0 ? [] : _generatorOptions$def,\n _generatorOptions$def2 = _generatorOptions.defaultOptions,\n defaultOptions = _generatorOptions$def2 === void 0 ? DEFAULT_OPTIONS : _generatorOptions$def2;\n return function createPopper(reference, popper, options) {\n if (options === void 0) {\n options = defaultOptions;\n }\n\n var state = {\n placement: 'bottom',\n orderedModifiers: [],\n options: Object.assign({}, DEFAULT_OPTIONS, defaultOptions),\n modifiersData: {},\n elements: {\n reference: reference,\n popper: popper\n },\n attributes: {},\n styles: {}\n };\n var effectCleanupFns = [];\n var isDestroyed = false;\n var instance = {\n state: state,\n setOptions: function setOptions(setOptionsAction) {\n var options = typeof setOptionsAction === 'function' ? setOptionsAction(state.options) : setOptionsAction;\n cleanupModifierEffects();\n state.options = Object.assign({}, defaultOptions, state.options, options);\n state.scrollParents = {\n reference: isElement(reference) ? listScrollParents(reference) : reference.contextElement ? listScrollParents(reference.contextElement) : [],\n popper: listScrollParents(popper)\n }; // Orders the modifiers based on their dependencies and `phase`\n // properties\n\n var orderedModifiers = orderModifiers(mergeByName([].concat(defaultModifiers, state.options.modifiers))); // Strip out disabled modifiers\n\n state.orderedModifiers = orderedModifiers.filter(function (m) {\n return m.enabled;\n });\n runModifierEffects();\n return instance.update();\n },\n // Sync update – it will always be executed, even if not necessary. This\n // is useful for low frequency updates where sync behavior simplifies the\n // logic.\n // For high frequency updates (e.g. `resize` and `scroll` events), always\n // prefer the async Popper#update method\n forceUpdate: function forceUpdate() {\n if (isDestroyed) {\n return;\n }\n\n var _state$elements = state.elements,\n reference = _state$elements.reference,\n popper = _state$elements.popper; // Don't proceed if `reference` or `popper` are not valid elements\n // anymore\n\n if (!areValidElements(reference, popper)) {\n return;\n } // Store the reference and popper rects to be read by modifiers\n\n\n state.rects = {\n reference: getCompositeRect(reference, getOffsetParent(popper), state.options.strategy === 'fixed'),\n popper: getLayoutRect(popper)\n }; // Modifiers have the ability to reset the current update cycle. The\n // most common use case for this is the `flip` modifier changing the\n // placement, which then needs to re-run all the modifiers, because the\n // logic was previously ran for the previous placement and is therefore\n // stale/incorrect\n\n state.reset = false;\n state.placement = state.options.placement; // On each update cycle, the `modifiersData` property for each modifier\n // is filled with the initial data specified by the modifier. This means\n // it doesn't persist and is fresh on each update.\n // To ensure persistent data, use `${name}#persistent`\n\n state.orderedModifiers.forEach(function (modifier) {\n return state.modifiersData[modifier.name] = Object.assign({}, modifier.data);\n });\n\n for (var index = 0; index < state.orderedModifiers.length; index++) {\n if (state.reset === true) {\n state.reset = false;\n index = -1;\n continue;\n }\n\n var _state$orderedModifie = state.orderedModifiers[index],\n fn = _state$orderedModifie.fn,\n _state$orderedModifie2 = _state$orderedModifie.options,\n _options = _state$orderedModifie2 === void 0 ? {} : _state$orderedModifie2,\n name = _state$orderedModifie.name;\n\n if (typeof fn === 'function') {\n state = fn({\n state: state,\n options: _options,\n name: name,\n instance: instance\n }) || state;\n }\n }\n },\n // Async and optimistically optimized update – it will not be executed if\n // not necessary (debounced to run at most once-per-tick)\n update: debounce(function () {\n return new Promise(function (resolve) {\n instance.forceUpdate();\n resolve(state);\n });\n }),\n destroy: function destroy() {\n cleanupModifierEffects();\n isDestroyed = true;\n }\n };\n\n if (!areValidElements(reference, popper)) {\n return instance;\n }\n\n instance.setOptions(options).then(function (state) {\n if (!isDestroyed && options.onFirstUpdate) {\n options.onFirstUpdate(state);\n }\n }); // Modifiers have the ability to execute arbitrary code before the first\n // update cycle runs. They will be executed in the same order as the update\n // cycle. This is useful when a modifier adds some persistent data that\n // other modifiers need to use, but the modifier is run after the dependent\n // one.\n\n function runModifierEffects() {\n state.orderedModifiers.forEach(function (_ref) {\n var name = _ref.name,\n _ref$options = _ref.options,\n options = _ref$options === void 0 ? {} : _ref$options,\n effect = _ref.effect;\n\n if (typeof effect === 'function') {\n var cleanupFn = effect({\n state: state,\n name: name,\n instance: instance,\n options: options\n });\n\n var noopFn = function noopFn() {};\n\n effectCleanupFns.push(cleanupFn || noopFn);\n }\n });\n }\n\n function cleanupModifierEffects() {\n effectCleanupFns.forEach(function (fn) {\n return fn();\n });\n effectCleanupFns = [];\n }\n\n return instance;\n };\n}\nexport var createPopper = /*#__PURE__*/popperGenerator(); // eslint-disable-next-line import/no-unused-modules\n\nexport { detectOverflow };","import { popperGenerator, detectOverflow } from \"./createPopper.js\";\nimport eventListeners from \"./modifiers/eventListeners.js\";\nimport popperOffsets from \"./modifiers/popperOffsets.js\";\nimport computeStyles from \"./modifiers/computeStyles.js\";\nimport applyStyles from \"./modifiers/applyStyles.js\";\nimport offset from \"./modifiers/offset.js\";\nimport flip from \"./modifiers/flip.js\";\nimport preventOverflow from \"./modifiers/preventOverflow.js\";\nimport arrow from \"./modifiers/arrow.js\";\nimport hide from \"./modifiers/hide.js\";\nvar defaultModifiers = [eventListeners, popperOffsets, computeStyles, applyStyles, offset, flip, preventOverflow, arrow, hide];\nvar createPopper = /*#__PURE__*/popperGenerator({\n defaultModifiers: defaultModifiers\n}); // eslint-disable-next-line import/no-unused-modules\n\nexport { createPopper, popperGenerator, defaultModifiers, detectOverflow }; // eslint-disable-next-line import/no-unused-modules\n\nexport { createPopper as createPopperLite } from \"./popper-lite.js\"; // eslint-disable-next-line import/no-unused-modules\n\nexport * from \"./modifiers/index.js\";","import { generateUtilityClass } from '../generateUtilityClass';\nimport { generateUtilityClasses } from '../generateUtilityClasses';\nconst COMPONENT_NAME = 'Popper';\nexport function getPopperUtilityClass(slot) {\n return generateUtilityClass(COMPONENT_NAME, slot);\n}\nexport const popperClasses = generateUtilityClasses(COMPONENT_NAME, ['root']);","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"anchorEl\", \"children\", \"direction\", \"disablePortal\", \"modifiers\", \"open\", \"placement\", \"popperOptions\", \"popperRef\", \"slotProps\", \"slots\", \"TransitionProps\", \"ownerState\"],\n _excluded2 = [\"anchorEl\", \"children\", \"container\", \"direction\", \"disablePortal\", \"keepMounted\", \"modifiers\", \"open\", \"placement\", \"popperOptions\", \"popperRef\", \"style\", \"transition\", \"slotProps\", \"slots\"];\nimport * as React from 'react';\nimport { chainPropTypes, HTMLElementType, refType, unstable_ownerDocument as ownerDocument, unstable_useEnhancedEffect as useEnhancedEffect, unstable_useForkRef as useForkRef } from '@mui/utils';\nimport { createPopper } from '@popperjs/core';\nimport PropTypes from 'prop-types';\nimport { unstable_composeClasses as composeClasses } from '../composeClasses';\nimport { Portal } from '../Portal';\nimport { getPopperUtilityClass } from './popperClasses';\nimport { useSlotProps } from '../utils';\nimport { useClassNamesOverride } from '../utils/ClassNameConfigurator';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nfunction flipPlacement(placement, direction) {\n if (direction === 'ltr') {\n return placement;\n }\n switch (placement) {\n case 'bottom-end':\n return 'bottom-start';\n case 'bottom-start':\n return 'bottom-end';\n case 'top-end':\n return 'top-start';\n case 'top-start':\n return 'top-end';\n default:\n return placement;\n }\n}\nfunction resolveAnchorEl(anchorEl) {\n return typeof anchorEl === 'function' ? anchorEl() : anchorEl;\n}\nfunction isHTMLElement(element) {\n return element.nodeType !== undefined;\n}\nfunction isVirtualElement(element) {\n return !isHTMLElement(element);\n}\nconst useUtilityClasses = () => {\n const slots = {\n root: ['root']\n };\n return composeClasses(slots, useClassNamesOverride(getPopperUtilityClass));\n};\nconst defaultPopperOptions = {};\nconst PopperTooltip = /*#__PURE__*/React.forwardRef(function PopperTooltip(props, forwardedRef) {\n var _slots$root;\n const {\n anchorEl,\n children,\n direction,\n disablePortal,\n modifiers,\n open,\n placement: initialPlacement,\n popperOptions,\n popperRef: popperRefProp,\n slotProps = {},\n slots = {},\n TransitionProps\n // @ts-ignore internal logic\n // prevent from spreading to DOM, it can come from the parent component e.g. Select.\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const tooltipRef = React.useRef(null);\n const ownRef = useForkRef(tooltipRef, forwardedRef);\n const popperRef = React.useRef(null);\n const handlePopperRef = useForkRef(popperRef, popperRefProp);\n const handlePopperRefRef = React.useRef(handlePopperRef);\n useEnhancedEffect(() => {\n handlePopperRefRef.current = handlePopperRef;\n }, [handlePopperRef]);\n React.useImperativeHandle(popperRefProp, () => popperRef.current, []);\n const rtlPlacement = flipPlacement(initialPlacement, direction);\n /**\n * placement initialized from prop but can change during lifetime if modifiers.flip.\n * modifiers.flip is essentially a flip for controlled/uncontrolled behavior\n */\n const [placement, setPlacement] = React.useState(rtlPlacement);\n const [resolvedAnchorElement, setResolvedAnchorElement] = React.useState(resolveAnchorEl(anchorEl));\n React.useEffect(() => {\n if (popperRef.current) {\n popperRef.current.forceUpdate();\n }\n });\n React.useEffect(() => {\n if (anchorEl) {\n setResolvedAnchorElement(resolveAnchorEl(anchorEl));\n }\n }, [anchorEl]);\n useEnhancedEffect(() => {\n if (!resolvedAnchorElement || !open) {\n return undefined;\n }\n const handlePopperUpdate = data => {\n setPlacement(data.placement);\n };\n if (process.env.NODE_ENV !== 'production') {\n if (resolvedAnchorElement && isHTMLElement(resolvedAnchorElement) && resolvedAnchorElement.nodeType === 1) {\n const box = resolvedAnchorElement.getBoundingClientRect();\n if (process.env.NODE_ENV !== 'test' && box.top === 0 && box.left === 0 && box.right === 0 && box.bottom === 0) {\n console.warn(['MUI: The `anchorEl` prop provided to the component is invalid.', 'The anchor element should be part of the document layout.', \"Make sure the element is present in the document or that it's not display none.\"].join('\\n'));\n }\n }\n }\n let popperModifiers = [{\n name: 'preventOverflow',\n options: {\n altBoundary: disablePortal\n }\n }, {\n name: 'flip',\n options: {\n altBoundary: disablePortal\n }\n }, {\n name: 'onUpdate',\n enabled: true,\n phase: 'afterWrite',\n fn: ({\n state\n }) => {\n handlePopperUpdate(state);\n }\n }];\n if (modifiers != null) {\n popperModifiers = popperModifiers.concat(modifiers);\n }\n if (popperOptions && popperOptions.modifiers != null) {\n popperModifiers = popperModifiers.concat(popperOptions.modifiers);\n }\n const popper = createPopper(resolvedAnchorElement, tooltipRef.current, _extends({\n placement: rtlPlacement\n }, popperOptions, {\n modifiers: popperModifiers\n }));\n handlePopperRefRef.current(popper);\n return () => {\n popper.destroy();\n handlePopperRefRef.current(null);\n };\n }, [resolvedAnchorElement, disablePortal, modifiers, open, popperOptions, rtlPlacement]);\n const childProps = {\n placement: placement\n };\n if (TransitionProps !== null) {\n childProps.TransitionProps = TransitionProps;\n }\n const classes = useUtilityClasses();\n const Root = (_slots$root = slots.root) != null ? _slots$root : 'div';\n const rootProps = useSlotProps({\n elementType: Root,\n externalSlotProps: slotProps.root,\n externalForwardedProps: other,\n additionalProps: {\n role: 'tooltip',\n ref: ownRef\n },\n ownerState: props,\n className: classes.root\n });\n return /*#__PURE__*/_jsx(Root, _extends({}, rootProps, {\n children: typeof children === 'function' ? children(childProps) : children\n }));\n});\n\n/**\n * Poppers rely on the 3rd party library [Popper.js](https://popper.js.org/docs/v2/) for positioning.\n *\n * Demos:\n *\n * - [Popper](https://mui.com/base-ui/react-popper/)\n *\n * API:\n *\n * - [Popper API](https://mui.com/base-ui/react-popper/components-api/#popper)\n */\nconst Popper = /*#__PURE__*/React.forwardRef(function Popper(props, forwardedRef) {\n const {\n anchorEl,\n children,\n container: containerProp,\n direction = 'ltr',\n disablePortal = false,\n keepMounted = false,\n modifiers,\n open,\n placement = 'bottom',\n popperOptions = defaultPopperOptions,\n popperRef,\n style,\n transition = false,\n slotProps = {},\n slots = {}\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded2);\n const [exited, setExited] = React.useState(true);\n const handleEnter = () => {\n setExited(false);\n };\n const handleExited = () => {\n setExited(true);\n };\n if (!keepMounted && !open && (!transition || exited)) {\n return null;\n }\n\n // If the container prop is provided, use that\n // If the anchorEl prop is provided, use its parent body element as the container\n // If neither are provided let the Modal take care of choosing the container\n let container;\n if (containerProp) {\n container = containerProp;\n } else if (anchorEl) {\n const resolvedAnchorEl = resolveAnchorEl(anchorEl);\n container = resolvedAnchorEl && isHTMLElement(resolvedAnchorEl) ? ownerDocument(resolvedAnchorEl).body : ownerDocument(null).body;\n }\n const display = !open && keepMounted && (!transition || exited) ? 'none' : undefined;\n const transitionProps = transition ? {\n in: open,\n onEnter: handleEnter,\n onExited: handleExited\n } : undefined;\n return /*#__PURE__*/_jsx(Portal, {\n disablePortal: disablePortal,\n container: container,\n children: /*#__PURE__*/_jsx(PopperTooltip, _extends({\n anchorEl: anchorEl,\n direction: direction,\n disablePortal: disablePortal,\n modifiers: modifiers,\n ref: forwardedRef,\n open: transition ? !exited : open,\n placement: placement,\n popperOptions: popperOptions,\n popperRef: popperRef,\n slotProps: slotProps,\n slots: slots\n }, other, {\n style: _extends({\n // Prevents scroll issue, waiting for Popper.js to add this style once initiated.\n position: 'fixed',\n // Fix Popper.js display issue\n top: 0,\n left: 0,\n display\n }, style),\n TransitionProps: transitionProps,\n children: children\n }))\n });\n});\nprocess.env.NODE_ENV !== \"production\" ? Popper.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * An HTML element, [virtualElement](https://popper.js.org/docs/v2/virtual-elements/),\n * or a function that returns either.\n * It's used to set the position of the popper.\n * The return value will passed as the reference object of the Popper instance.\n */\n anchorEl: chainPropTypes(PropTypes.oneOfType([HTMLElementType, PropTypes.object, PropTypes.func]), props => {\n if (props.open) {\n const resolvedAnchorEl = resolveAnchorEl(props.anchorEl);\n if (resolvedAnchorEl && isHTMLElement(resolvedAnchorEl) && resolvedAnchorEl.nodeType === 1) {\n const box = resolvedAnchorEl.getBoundingClientRect();\n if (process.env.NODE_ENV !== 'test' && box.top === 0 && box.left === 0 && box.right === 0 && box.bottom === 0) {\n return new Error(['MUI: The `anchorEl` prop provided to the component is invalid.', 'The anchor element should be part of the document layout.', \"Make sure the element is present in the document or that it's not display none.\"].join('\\n'));\n }\n } else if (!resolvedAnchorEl || typeof resolvedAnchorEl.getBoundingClientRect !== 'function' || isVirtualElement(resolvedAnchorEl) && resolvedAnchorEl.contextElement != null && resolvedAnchorEl.contextElement.nodeType !== 1) {\n return new Error(['MUI: The `anchorEl` prop provided to the component is invalid.', 'It should be an HTML element instance or a virtualElement ', '(https://popper.js.org/docs/v2/virtual-elements/).'].join('\\n'));\n }\n }\n return null;\n }),\n /**\n * Popper render function or node.\n */\n children: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.node, PropTypes.func]),\n /**\n * An HTML element or function that returns one.\n * The `container` will have the portal children appended to it.\n *\n * You can also provide a callback, which is called in a React layout effect.\n * This lets you set the container from a ref, and also makes server-side rendering possible.\n *\n * By default, it uses the body of the top-level document object,\n * so it's simply `document.body` most of the time.\n */\n container: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.func]),\n /**\n * Direction of the text.\n * @default 'ltr'\n */\n direction: PropTypes.oneOf(['ltr', 'rtl']),\n /**\n * The `children` will be under the DOM hierarchy of the parent component.\n * @default false\n */\n disablePortal: PropTypes.bool,\n /**\n * Always keep the children in the DOM.\n * This prop can be useful in SEO situation or\n * when you want to maximize the responsiveness of the Popper.\n * @default false\n */\n keepMounted: PropTypes.bool,\n /**\n * Popper.js is based on a \"plugin-like\" architecture,\n * most of its features are fully encapsulated \"modifiers\".\n *\n * A modifier is a function that is called each time Popper.js needs to\n * compute the position of the popper.\n * For this reason, modifiers should be very performant to avoid bottlenecks.\n * To learn how to create a modifier, [read the modifiers documentation](https://popper.js.org/docs/v2/modifiers/).\n */\n modifiers: PropTypes.arrayOf(PropTypes.shape({\n data: PropTypes.object,\n effect: PropTypes.func,\n enabled: PropTypes.bool,\n fn: PropTypes.func,\n name: PropTypes.any,\n options: PropTypes.object,\n phase: PropTypes.oneOf(['afterMain', 'afterRead', 'afterWrite', 'beforeMain', 'beforeRead', 'beforeWrite', 'main', 'read', 'write']),\n requires: PropTypes.arrayOf(PropTypes.string),\n requiresIfExists: PropTypes.arrayOf(PropTypes.string)\n })),\n /**\n * If `true`, the component is shown.\n */\n open: PropTypes.bool.isRequired,\n /**\n * Popper placement.\n * @default 'bottom'\n */\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n /**\n * Options provided to the [`Popper.js`](https://popper.js.org/docs/v2/constructors/#options) instance.\n * @default {}\n */\n popperOptions: PropTypes.shape({\n modifiers: PropTypes.array,\n onFirstUpdate: PropTypes.func,\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n strategy: PropTypes.oneOf(['absolute', 'fixed'])\n }),\n /**\n * A ref that points to the used popper instance.\n */\n popperRef: refType,\n /**\n * The props used for each slot inside the Popper.\n * @default {}\n */\n slotProps: PropTypes.shape({\n root: PropTypes.oneOfType([PropTypes.func, PropTypes.object])\n }),\n /**\n * The components used for each slot inside the Popper.\n * Either a string to use a HTML element or a component.\n * @default {}\n */\n slots: PropTypes.shape({\n root: PropTypes.elementType\n }),\n /**\n * Help supporting a react-transition-group/Transition component.\n * @default false\n */\n transition: PropTypes.bool\n} : void 0;\nexport { Popper };","'use client';\n\nimport * as React from 'react';\nimport { useTheme as useThemeSystem } from '@mui/system';\nimport defaultTheme from './defaultTheme';\nimport THEME_ID from './identifier';\nexport default function useTheme() {\n const theme = useThemeSystem(defaultTheme);\n if (process.env.NODE_ENV !== 'production') {\n // eslint-disable-next-line react-hooks/rules-of-hooks\n React.useDebugValue(theme);\n }\n return theme[THEME_ID] || theme;\n}","export default function _setPrototypeOf(o, p) {\n _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function _setPrototypeOf(o, p) {\n o.__proto__ = p;\n return o;\n };\n return _setPrototypeOf(o, p);\n}","import setPrototypeOf from \"./setPrototypeOf.js\";\nexport default function _inheritsLoose(subClass, superClass) {\n subClass.prototype = Object.create(superClass.prototype);\n subClass.prototype.constructor = subClass;\n setPrototypeOf(subClass, superClass);\n}","export default {\n disabled: false\n};","import PropTypes from 'prop-types';\nexport var timeoutsShape = process.env.NODE_ENV !== 'production' ? PropTypes.oneOfType([PropTypes.number, PropTypes.shape({\n enter: PropTypes.number,\n exit: PropTypes.number,\n appear: PropTypes.number\n}).isRequired]) : null;\nexport var classNamesShape = process.env.NODE_ENV !== 'production' ? PropTypes.oneOfType([PropTypes.string, PropTypes.shape({\n enter: PropTypes.string,\n exit: PropTypes.string,\n active: PropTypes.string\n}), PropTypes.shape({\n enter: PropTypes.string,\n enterDone: PropTypes.string,\n enterActive: PropTypes.string,\n exit: PropTypes.string,\n exitDone: PropTypes.string,\n exitActive: PropTypes.string\n})]) : null;","import React from 'react';\nexport default React.createContext(null);","export var forceReflow = function forceReflow(node) {\n return node.scrollTop;\n};","import _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _inheritsLoose from \"@babel/runtime/helpers/esm/inheritsLoose\";\nimport PropTypes from 'prop-types';\nimport React from 'react';\nimport ReactDOM from 'react-dom';\nimport config from './config';\nimport { timeoutsShape } from './utils/PropTypes';\nimport TransitionGroupContext from './TransitionGroupContext';\nimport { forceReflow } from './utils/reflow';\nexport var UNMOUNTED = 'unmounted';\nexport var EXITED = 'exited';\nexport var ENTERING = 'entering';\nexport var ENTERED = 'entered';\nexport var EXITING = 'exiting';\n/**\n * The Transition component lets you describe a transition from one component\n * state to another _over time_ with a simple declarative API. Most commonly\n * it's used to animate the mounting and unmounting of a component, but can also\n * be used to describe in-place transition states as well.\n *\n * ---\n *\n * **Note**: `Transition` is a platform-agnostic base component. If you're using\n * transitions in CSS, you'll probably want to use\n * [`CSSTransition`](https://reactcommunity.org/react-transition-group/css-transition)\n * instead. It inherits all the features of `Transition`, but contains\n * additional features necessary to play nice with CSS transitions (hence the\n * name of the component).\n *\n * ---\n *\n * By default the `Transition` component does not alter the behavior of the\n * component it renders, it only tracks \"enter\" and \"exit\" states for the\n * components. It's up to you to give meaning and effect to those states. For\n * example we can add styles to a component when it enters or exits:\n *\n * ```jsx\n * import { Transition } from 'react-transition-group';\n *\n * const duration = 300;\n *\n * const defaultStyle = {\n * transition: `opacity ${duration}ms ease-in-out`,\n * opacity: 0,\n * }\n *\n * const transitionStyles = {\n * entering: { opacity: 1 },\n * entered: { opacity: 1 },\n * exiting: { opacity: 0 },\n * exited: { opacity: 0 },\n * };\n *\n * const Fade = ({ in: inProp }) => (\n * \n * {state => (\n *
    \n * I'm a fade Transition!\n *
    \n * )}\n *
    \n * );\n * ```\n *\n * There are 4 main states a Transition can be in:\n * - `'entering'`\n * - `'entered'`\n * - `'exiting'`\n * - `'exited'`\n *\n * Transition state is toggled via the `in` prop. When `true` the component\n * begins the \"Enter\" stage. During this stage, the component will shift from\n * its current transition state, to `'entering'` for the duration of the\n * transition and then to the `'entered'` stage once it's complete. Let's take\n * the following example (we'll use the\n * [useState](https://reactjs.org/docs/hooks-reference.html#usestate) hook):\n *\n * ```jsx\n * function App() {\n * const [inProp, setInProp] = useState(false);\n * return (\n *
    \n * \n * {state => (\n * // ...\n * )}\n * \n * \n *
    \n * );\n * }\n * ```\n *\n * When the button is clicked the component will shift to the `'entering'` state\n * and stay there for 500ms (the value of `timeout`) before it finally switches\n * to `'entered'`.\n *\n * When `in` is `false` the same thing happens except the state moves from\n * `'exiting'` to `'exited'`.\n */\n\nvar Transition = /*#__PURE__*/function (_React$Component) {\n _inheritsLoose(Transition, _React$Component);\n\n function Transition(props, context) {\n var _this;\n\n _this = _React$Component.call(this, props, context) || this;\n var parentGroup = context; // In the context of a TransitionGroup all enters are really appears\n\n var appear = parentGroup && !parentGroup.isMounting ? props.enter : props.appear;\n var initialStatus;\n _this.appearStatus = null;\n\n if (props.in) {\n if (appear) {\n initialStatus = EXITED;\n _this.appearStatus = ENTERING;\n } else {\n initialStatus = ENTERED;\n }\n } else {\n if (props.unmountOnExit || props.mountOnEnter) {\n initialStatus = UNMOUNTED;\n } else {\n initialStatus = EXITED;\n }\n }\n\n _this.state = {\n status: initialStatus\n };\n _this.nextCallback = null;\n return _this;\n }\n\n Transition.getDerivedStateFromProps = function getDerivedStateFromProps(_ref, prevState) {\n var nextIn = _ref.in;\n\n if (nextIn && prevState.status === UNMOUNTED) {\n return {\n status: EXITED\n };\n }\n\n return null;\n } // getSnapshotBeforeUpdate(prevProps) {\n // let nextStatus = null\n // if (prevProps !== this.props) {\n // const { status } = this.state\n // if (this.props.in) {\n // if (status !== ENTERING && status !== ENTERED) {\n // nextStatus = ENTERING\n // }\n // } else {\n // if (status === ENTERING || status === ENTERED) {\n // nextStatus = EXITING\n // }\n // }\n // }\n // return { nextStatus }\n // }\n ;\n\n var _proto = Transition.prototype;\n\n _proto.componentDidMount = function componentDidMount() {\n this.updateStatus(true, this.appearStatus);\n };\n\n _proto.componentDidUpdate = function componentDidUpdate(prevProps) {\n var nextStatus = null;\n\n if (prevProps !== this.props) {\n var status = this.state.status;\n\n if (this.props.in) {\n if (status !== ENTERING && status !== ENTERED) {\n nextStatus = ENTERING;\n }\n } else {\n if (status === ENTERING || status === ENTERED) {\n nextStatus = EXITING;\n }\n }\n }\n\n this.updateStatus(false, nextStatus);\n };\n\n _proto.componentWillUnmount = function componentWillUnmount() {\n this.cancelNextCallback();\n };\n\n _proto.getTimeouts = function getTimeouts() {\n var timeout = this.props.timeout;\n var exit, enter, appear;\n exit = enter = appear = timeout;\n\n if (timeout != null && typeof timeout !== 'number') {\n exit = timeout.exit;\n enter = timeout.enter; // TODO: remove fallback for next major\n\n appear = timeout.appear !== undefined ? timeout.appear : enter;\n }\n\n return {\n exit: exit,\n enter: enter,\n appear: appear\n };\n };\n\n _proto.updateStatus = function updateStatus(mounting, nextStatus) {\n if (mounting === void 0) {\n mounting = false;\n }\n\n if (nextStatus !== null) {\n // nextStatus will always be ENTERING or EXITING.\n this.cancelNextCallback();\n\n if (nextStatus === ENTERING) {\n if (this.props.unmountOnExit || this.props.mountOnEnter) {\n var node = this.props.nodeRef ? this.props.nodeRef.current : ReactDOM.findDOMNode(this); // https://github.com/reactjs/react-transition-group/pull/749\n // With unmountOnExit or mountOnEnter, the enter animation should happen at the transition between `exited` and `entering`.\n // To make the animation happen, we have to separate each rendering and avoid being processed as batched.\n\n if (node) forceReflow(node);\n }\n\n this.performEnter(mounting);\n } else {\n this.performExit();\n }\n } else if (this.props.unmountOnExit && this.state.status === EXITED) {\n this.setState({\n status: UNMOUNTED\n });\n }\n };\n\n _proto.performEnter = function performEnter(mounting) {\n var _this2 = this;\n\n var enter = this.props.enter;\n var appearing = this.context ? this.context.isMounting : mounting;\n\n var _ref2 = this.props.nodeRef ? [appearing] : [ReactDOM.findDOMNode(this), appearing],\n maybeNode = _ref2[0],\n maybeAppearing = _ref2[1];\n\n var timeouts = this.getTimeouts();\n var enterTimeout = appearing ? timeouts.appear : timeouts.enter; // no enter animation skip right to ENTERED\n // if we are mounting and running this it means appear _must_ be set\n\n if (!mounting && !enter || config.disabled) {\n this.safeSetState({\n status: ENTERED\n }, function () {\n _this2.props.onEntered(maybeNode);\n });\n return;\n }\n\n this.props.onEnter(maybeNode, maybeAppearing);\n this.safeSetState({\n status: ENTERING\n }, function () {\n _this2.props.onEntering(maybeNode, maybeAppearing);\n\n _this2.onTransitionEnd(enterTimeout, function () {\n _this2.safeSetState({\n status: ENTERED\n }, function () {\n _this2.props.onEntered(maybeNode, maybeAppearing);\n });\n });\n });\n };\n\n _proto.performExit = function performExit() {\n var _this3 = this;\n\n var exit = this.props.exit;\n var timeouts = this.getTimeouts();\n var maybeNode = this.props.nodeRef ? undefined : ReactDOM.findDOMNode(this); // no exit animation skip right to EXITED\n\n if (!exit || config.disabled) {\n this.safeSetState({\n status: EXITED\n }, function () {\n _this3.props.onExited(maybeNode);\n });\n return;\n }\n\n this.props.onExit(maybeNode);\n this.safeSetState({\n status: EXITING\n }, function () {\n _this3.props.onExiting(maybeNode);\n\n _this3.onTransitionEnd(timeouts.exit, function () {\n _this3.safeSetState({\n status: EXITED\n }, function () {\n _this3.props.onExited(maybeNode);\n });\n });\n });\n };\n\n _proto.cancelNextCallback = function cancelNextCallback() {\n if (this.nextCallback !== null) {\n this.nextCallback.cancel();\n this.nextCallback = null;\n }\n };\n\n _proto.safeSetState = function safeSetState(nextState, callback) {\n // This shouldn't be necessary, but there are weird race conditions with\n // setState callbacks and unmounting in testing, so always make sure that\n // we can cancel any pending setState callbacks after we unmount.\n callback = this.setNextCallback(callback);\n this.setState(nextState, callback);\n };\n\n _proto.setNextCallback = function setNextCallback(callback) {\n var _this4 = this;\n\n var active = true;\n\n this.nextCallback = function (event) {\n if (active) {\n active = false;\n _this4.nextCallback = null;\n callback(event);\n }\n };\n\n this.nextCallback.cancel = function () {\n active = false;\n };\n\n return this.nextCallback;\n };\n\n _proto.onTransitionEnd = function onTransitionEnd(timeout, handler) {\n this.setNextCallback(handler);\n var node = this.props.nodeRef ? this.props.nodeRef.current : ReactDOM.findDOMNode(this);\n var doesNotHaveTimeoutOrListener = timeout == null && !this.props.addEndListener;\n\n if (!node || doesNotHaveTimeoutOrListener) {\n setTimeout(this.nextCallback, 0);\n return;\n }\n\n if (this.props.addEndListener) {\n var _ref3 = this.props.nodeRef ? [this.nextCallback] : [node, this.nextCallback],\n maybeNode = _ref3[0],\n maybeNextCallback = _ref3[1];\n\n this.props.addEndListener(maybeNode, maybeNextCallback);\n }\n\n if (timeout != null) {\n setTimeout(this.nextCallback, timeout);\n }\n };\n\n _proto.render = function render() {\n var status = this.state.status;\n\n if (status === UNMOUNTED) {\n return null;\n }\n\n var _this$props = this.props,\n children = _this$props.children,\n _in = _this$props.in,\n _mountOnEnter = _this$props.mountOnEnter,\n _unmountOnExit = _this$props.unmountOnExit,\n _appear = _this$props.appear,\n _enter = _this$props.enter,\n _exit = _this$props.exit,\n _timeout = _this$props.timeout,\n _addEndListener = _this$props.addEndListener,\n _onEnter = _this$props.onEnter,\n _onEntering = _this$props.onEntering,\n _onEntered = _this$props.onEntered,\n _onExit = _this$props.onExit,\n _onExiting = _this$props.onExiting,\n _onExited = _this$props.onExited,\n _nodeRef = _this$props.nodeRef,\n childProps = _objectWithoutPropertiesLoose(_this$props, [\"children\", \"in\", \"mountOnEnter\", \"unmountOnExit\", \"appear\", \"enter\", \"exit\", \"timeout\", \"addEndListener\", \"onEnter\", \"onEntering\", \"onEntered\", \"onExit\", \"onExiting\", \"onExited\", \"nodeRef\"]);\n\n return (\n /*#__PURE__*/\n // allows for nested Transitions\n React.createElement(TransitionGroupContext.Provider, {\n value: null\n }, typeof children === 'function' ? children(status, childProps) : React.cloneElement(React.Children.only(children), childProps))\n );\n };\n\n return Transition;\n}(React.Component);\n\nTransition.contextType = TransitionGroupContext;\nTransition.propTypes = process.env.NODE_ENV !== \"production\" ? {\n /**\n * A React reference to DOM element that need to transition:\n * https://stackoverflow.com/a/51127130/4671932\n *\n * - When `nodeRef` prop is used, `node` is not passed to callback functions\n * (e.g. `onEnter`) because user already has direct access to the node.\n * - When changing `key` prop of `Transition` in a `TransitionGroup` a new\n * `nodeRef` need to be provided to `Transition` with changed `key` prop\n * (see\n * [test/CSSTransition-test.js](https://github.com/reactjs/react-transition-group/blob/13435f897b3ab71f6e19d724f145596f5910581c/test/CSSTransition-test.js#L362-L437)).\n */\n nodeRef: PropTypes.shape({\n current: typeof Element === 'undefined' ? PropTypes.any : function (propValue, key, componentName, location, propFullName, secret) {\n var value = propValue[key];\n return PropTypes.instanceOf(value && 'ownerDocument' in value ? value.ownerDocument.defaultView.Element : Element)(propValue, key, componentName, location, propFullName, secret);\n }\n }),\n\n /**\n * A `function` child can be used instead of a React element. This function is\n * called with the current transition status (`'entering'`, `'entered'`,\n * `'exiting'`, `'exited'`), which can be used to apply context\n * specific props to a component.\n *\n * ```jsx\n * \n * {state => (\n * \n * )}\n * \n * ```\n */\n children: PropTypes.oneOfType([PropTypes.func.isRequired, PropTypes.element.isRequired]).isRequired,\n\n /**\n * Show the component; triggers the enter or exit states\n */\n in: PropTypes.bool,\n\n /**\n * By default the child component is mounted immediately along with\n * the parent `Transition` component. If you want to \"lazy mount\" the component on the\n * first `in={true}` you can set `mountOnEnter`. After the first enter transition the component will stay\n * mounted, even on \"exited\", unless you also specify `unmountOnExit`.\n */\n mountOnEnter: PropTypes.bool,\n\n /**\n * By default the child component stays mounted after it reaches the `'exited'` state.\n * Set `unmountOnExit` if you'd prefer to unmount the component after it finishes exiting.\n */\n unmountOnExit: PropTypes.bool,\n\n /**\n * By default the child component does not perform the enter transition when\n * it first mounts, regardless of the value of `in`. If you want this\n * behavior, set both `appear` and `in` to `true`.\n *\n * > **Note**: there are no special appear states like `appearing`/`appeared`, this prop\n * > only adds an additional enter transition. However, in the\n * > `` component that first enter transition does result in\n * > additional `.appear-*` classes, that way you can choose to style it\n * > differently.\n */\n appear: PropTypes.bool,\n\n /**\n * Enable or disable enter transitions.\n */\n enter: PropTypes.bool,\n\n /**\n * Enable or disable exit transitions.\n */\n exit: PropTypes.bool,\n\n /**\n * The duration of the transition, in milliseconds.\n * Required unless `addEndListener` is provided.\n *\n * You may specify a single timeout for all transitions:\n *\n * ```jsx\n * timeout={500}\n * ```\n *\n * or individually:\n *\n * ```jsx\n * timeout={{\n * appear: 500,\n * enter: 300,\n * exit: 500,\n * }}\n * ```\n *\n * - `appear` defaults to the value of `enter`\n * - `enter` defaults to `0`\n * - `exit` defaults to `0`\n *\n * @type {number | { enter?: number, exit?: number, appear?: number }}\n */\n timeout: function timeout(props) {\n var pt = timeoutsShape;\n if (!props.addEndListener) pt = pt.isRequired;\n\n for (var _len = arguments.length, args = new Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) {\n args[_key - 1] = arguments[_key];\n }\n\n return pt.apply(void 0, [props].concat(args));\n },\n\n /**\n * Add a custom transition end trigger. Called with the transitioning\n * DOM node and a `done` callback. Allows for more fine grained transition end\n * logic. Timeouts are still used as a fallback if provided.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * ```jsx\n * addEndListener={(node, done) => {\n * // use the css transitionend event to mark the finish of a transition\n * node.addEventListener('transitionend', done, false);\n * }}\n * ```\n */\n addEndListener: PropTypes.func,\n\n /**\n * Callback fired before the \"entering\" status is applied. An extra parameter\n * `isAppearing` is supplied to indicate if the enter stage is occurring on the initial mount\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement, isAppearing: bool) -> void\n */\n onEnter: PropTypes.func,\n\n /**\n * Callback fired after the \"entering\" status is applied. An extra parameter\n * `isAppearing` is supplied to indicate if the enter stage is occurring on the initial mount\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement, isAppearing: bool)\n */\n onEntering: PropTypes.func,\n\n /**\n * Callback fired after the \"entered\" status is applied. An extra parameter\n * `isAppearing` is supplied to indicate if the enter stage is occurring on the initial mount\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement, isAppearing: bool) -> void\n */\n onEntered: PropTypes.func,\n\n /**\n * Callback fired before the \"exiting\" status is applied.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement) -> void\n */\n onExit: PropTypes.func,\n\n /**\n * Callback fired after the \"exiting\" status is applied.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement) -> void\n */\n onExiting: PropTypes.func,\n\n /**\n * Callback fired after the \"exited\" status is applied.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed\n *\n * @type Function(node: HtmlElement) -> void\n */\n onExited: PropTypes.func\n} : {}; // Name the function so it is clearer in the documentation\n\nfunction noop() {}\n\nTransition.defaultProps = {\n in: false,\n mountOnEnter: false,\n unmountOnExit: false,\n appear: false,\n enter: true,\n exit: true,\n onEnter: noop,\n onEntering: noop,\n onEntered: noop,\n onExit: noop,\n onExiting: noop,\n onExited: noop\n};\nTransition.UNMOUNTED = UNMOUNTED;\nTransition.EXITED = EXITED;\nTransition.ENTERING = ENTERING;\nTransition.ENTERED = ENTERED;\nTransition.EXITING = EXITING;\nexport default Transition;","export const reflow = node => node.scrollTop;\nexport function getTransitionProps(props, options) {\n var _style$transitionDura, _style$transitionTimi;\n const {\n timeout,\n easing,\n style = {}\n } = props;\n return {\n duration: (_style$transitionDura = style.transitionDuration) != null ? _style$transitionDura : typeof timeout === 'number' ? timeout : timeout[options.mode] || 0,\n easing: (_style$transitionTimi = style.transitionTimingFunction) != null ? _style$transitionTimi : typeof easing === 'object' ? easing[options.mode] : easing,\n delay: style.transitionDelay\n };\n}","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"addEndListener\", \"appear\", \"children\", \"easing\", \"in\", \"onEnter\", \"onEntered\", \"onEntering\", \"onExit\", \"onExited\", \"onExiting\", \"style\", \"timeout\", \"TransitionComponent\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport { elementAcceptingRef, unstable_useTimeout as useTimeout } from '@mui/utils';\nimport { Transition } from 'react-transition-group';\nimport useTheme from '../styles/useTheme';\nimport { getTransitionProps, reflow } from '../transitions/utils';\nimport useForkRef from '../utils/useForkRef';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nfunction getScale(value) {\n return `scale(${value}, ${value ** 2})`;\n}\nconst styles = {\n entering: {\n opacity: 1,\n transform: getScale(1)\n },\n entered: {\n opacity: 1,\n transform: 'none'\n }\n};\n\n/*\n TODO v6: remove\n Conditionally apply a workaround for the CSS transition bug in Safari 15.4 / WebKit browsers.\n */\nconst isWebKit154 = typeof navigator !== 'undefined' && /^((?!chrome|android).)*(safari|mobile)/i.test(navigator.userAgent) && /(os |version\\/)15(.|_)4/i.test(navigator.userAgent);\n\n/**\n * The Grow transition is used by the [Tooltip](/material-ui/react-tooltip/) and\n * [Popover](/material-ui/react-popover/) components.\n * It uses [react-transition-group](https://github.com/reactjs/react-transition-group) internally.\n */\nconst Grow = /*#__PURE__*/React.forwardRef(function Grow(props, ref) {\n const {\n addEndListener,\n appear = true,\n children,\n easing,\n in: inProp,\n onEnter,\n onEntered,\n onEntering,\n onExit,\n onExited,\n onExiting,\n style,\n timeout = 'auto',\n // eslint-disable-next-line react/prop-types\n TransitionComponent = Transition\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const timer = useTimeout();\n const autoTimeout = React.useRef();\n const theme = useTheme();\n const nodeRef = React.useRef(null);\n const handleRef = useForkRef(nodeRef, children.ref, ref);\n const normalizedTransitionCallback = callback => maybeIsAppearing => {\n if (callback) {\n const node = nodeRef.current;\n\n // onEnterXxx and onExitXxx callbacks have a different arguments.length value.\n if (maybeIsAppearing === undefined) {\n callback(node);\n } else {\n callback(node, maybeIsAppearing);\n }\n }\n };\n const handleEntering = normalizedTransitionCallback(onEntering);\n const handleEnter = normalizedTransitionCallback((node, isAppearing) => {\n reflow(node); // So the animation always start from the start.\n\n const {\n duration: transitionDuration,\n delay,\n easing: transitionTimingFunction\n } = getTransitionProps({\n style,\n timeout,\n easing\n }, {\n mode: 'enter'\n });\n let duration;\n if (timeout === 'auto') {\n duration = theme.transitions.getAutoHeightDuration(node.clientHeight);\n autoTimeout.current = duration;\n } else {\n duration = transitionDuration;\n }\n node.style.transition = [theme.transitions.create('opacity', {\n duration,\n delay\n }), theme.transitions.create('transform', {\n duration: isWebKit154 ? duration : duration * 0.666,\n delay,\n easing: transitionTimingFunction\n })].join(',');\n if (onEnter) {\n onEnter(node, isAppearing);\n }\n });\n const handleEntered = normalizedTransitionCallback(onEntered);\n const handleExiting = normalizedTransitionCallback(onExiting);\n const handleExit = normalizedTransitionCallback(node => {\n const {\n duration: transitionDuration,\n delay,\n easing: transitionTimingFunction\n } = getTransitionProps({\n style,\n timeout,\n easing\n }, {\n mode: 'exit'\n });\n let duration;\n if (timeout === 'auto') {\n duration = theme.transitions.getAutoHeightDuration(node.clientHeight);\n autoTimeout.current = duration;\n } else {\n duration = transitionDuration;\n }\n node.style.transition = [theme.transitions.create('opacity', {\n duration,\n delay\n }), theme.transitions.create('transform', {\n duration: isWebKit154 ? duration : duration * 0.666,\n delay: isWebKit154 ? delay : delay || duration * 0.333,\n easing: transitionTimingFunction\n })].join(',');\n node.style.opacity = 0;\n node.style.transform = getScale(0.75);\n if (onExit) {\n onExit(node);\n }\n });\n const handleExited = normalizedTransitionCallback(onExited);\n const handleAddEndListener = next => {\n if (timeout === 'auto') {\n timer.start(autoTimeout.current || 0, next);\n }\n if (addEndListener) {\n // Old call signature before `react-transition-group` implemented `nodeRef`\n addEndListener(nodeRef.current, next);\n }\n };\n return /*#__PURE__*/_jsx(TransitionComponent, _extends({\n appear: appear,\n in: inProp,\n nodeRef: nodeRef,\n onEnter: handleEnter,\n onEntered: handleEntered,\n onEntering: handleEntering,\n onExit: handleExit,\n onExited: handleExited,\n onExiting: handleExiting,\n addEndListener: handleAddEndListener,\n timeout: timeout === 'auto' ? null : timeout\n }, other, {\n children: (state, childProps) => {\n return /*#__PURE__*/React.cloneElement(children, _extends({\n style: _extends({\n opacity: 0,\n transform: getScale(0.75),\n visibility: state === 'exited' && !inProp ? 'hidden' : undefined\n }, styles[state], style, children.props.style),\n ref: handleRef\n }, childProps));\n }\n }));\n});\nprocess.env.NODE_ENV !== \"production\" ? Grow.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the d.ts file and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * Add a custom transition end trigger. Called with the transitioning DOM\n * node and a done callback. Allows for more fine grained transition end\n * logic. Note: Timeouts are still used as a fallback if provided.\n */\n addEndListener: PropTypes.func,\n /**\n * Perform the enter transition when it first mounts if `in` is also `true`.\n * Set this to `false` to disable this behavior.\n * @default true\n */\n appear: PropTypes.bool,\n /**\n * A single child content element.\n */\n children: elementAcceptingRef.isRequired,\n /**\n * The transition timing function.\n * You may specify a single easing or a object containing enter and exit values.\n */\n easing: PropTypes.oneOfType([PropTypes.shape({\n enter: PropTypes.string,\n exit: PropTypes.string\n }), PropTypes.string]),\n /**\n * If `true`, the component will transition in.\n */\n in: PropTypes.bool,\n /**\n * @ignore\n */\n onEnter: PropTypes.func,\n /**\n * @ignore\n */\n onEntered: PropTypes.func,\n /**\n * @ignore\n */\n onEntering: PropTypes.func,\n /**\n * @ignore\n */\n onExit: PropTypes.func,\n /**\n * @ignore\n */\n onExited: PropTypes.func,\n /**\n * @ignore\n */\n onExiting: PropTypes.func,\n /**\n * @ignore\n */\n style: PropTypes.object,\n /**\n * The duration for the transition, in milliseconds.\n * You may specify a single timeout for all transitions, or individually with an object.\n *\n * Set to 'auto' to automatically calculate transition time based on height.\n * @default 'auto'\n */\n timeout: PropTypes.oneOfType([PropTypes.oneOf(['auto']), PropTypes.number, PropTypes.shape({\n appear: PropTypes.number,\n enter: PropTypes.number,\n exit: PropTypes.number\n })])\n} : void 0;\nGrow.muiSupportAuto = true;\nexport default Grow;","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"anchorEl\", \"component\", \"components\", \"componentsProps\", \"container\", \"disablePortal\", \"keepMounted\", \"modifiers\", \"open\", \"placement\", \"popperOptions\", \"popperRef\", \"transition\", \"slots\", \"slotProps\"];\nimport { Popper as BasePopper } from '@mui/base/Popper';\nimport { useThemeWithoutDefault as useTheme } from '@mui/system';\nimport { HTMLElementType, refType } from '@mui/utils';\nimport PropTypes from 'prop-types';\nimport * as React from 'react';\nimport { styled, useThemeProps } from '../styles';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nconst PopperRoot = styled(BasePopper, {\n name: 'MuiPopper',\n slot: 'Root',\n overridesResolver: (props, styles) => styles.root\n})({});\n\n/**\n *\n * Demos:\n *\n * - [Autocomplete](https://mui.com/material-ui/react-autocomplete/)\n * - [Menu](https://mui.com/material-ui/react-menu/)\n * - [Popper](https://mui.com/material-ui/react-popper/)\n *\n * API:\n *\n * - [Popper API](https://mui.com/material-ui/api/popper/)\n */\nconst Popper = /*#__PURE__*/React.forwardRef(function Popper(inProps, ref) {\n var _slots$root;\n const theme = useTheme();\n const props = useThemeProps({\n props: inProps,\n name: 'MuiPopper'\n });\n const {\n anchorEl,\n component,\n components,\n componentsProps,\n container,\n disablePortal,\n keepMounted,\n modifiers,\n open,\n placement,\n popperOptions,\n popperRef,\n transition,\n slots,\n slotProps\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const RootComponent = (_slots$root = slots == null ? void 0 : slots.root) != null ? _slots$root : components == null ? void 0 : components.Root;\n const otherProps = _extends({\n anchorEl,\n container,\n disablePortal,\n keepMounted,\n modifiers,\n open,\n placement,\n popperOptions,\n popperRef,\n transition\n }, other);\n return /*#__PURE__*/_jsx(PopperRoot, _extends({\n as: component,\n direction: theme == null ? void 0 : theme.direction,\n slots: {\n root: RootComponent\n },\n slotProps: slotProps != null ? slotProps : componentsProps\n }, otherProps, {\n ref: ref\n }));\n});\nprocess.env.NODE_ENV !== \"production\" ? Popper.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * An HTML element, [virtualElement](https://popper.js.org/docs/v2/virtual-elements/),\n * or a function that returns either.\n * It's used to set the position of the popper.\n * The return value will passed as the reference object of the Popper instance.\n */\n anchorEl: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.object, PropTypes.func]),\n /**\n * Popper render function or node.\n */\n children: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.node, PropTypes.func]),\n /**\n * The component used for the root node.\n * Either a string to use a HTML element or a component.\n */\n component: PropTypes.elementType,\n /**\n * The components used for each slot inside the Popper.\n * Either a string to use a HTML element or a component.\n * @default {}\n */\n components: PropTypes.shape({\n Root: PropTypes.elementType\n }),\n /**\n * The props used for each slot inside the Popper.\n * @default {}\n */\n componentsProps: PropTypes.shape({\n root: PropTypes.oneOfType([PropTypes.func, PropTypes.object])\n }),\n /**\n * An HTML element or function that returns one.\n * The `container` will have the portal children appended to it.\n *\n * You can also provide a callback, which is called in a React layout effect.\n * This lets you set the container from a ref, and also makes server-side rendering possible.\n *\n * By default, it uses the body of the top-level document object,\n * so it's simply `document.body` most of the time.\n */\n container: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.func]),\n /**\n * The `children` will be under the DOM hierarchy of the parent component.\n * @default false\n */\n disablePortal: PropTypes.bool,\n /**\n * Always keep the children in the DOM.\n * This prop can be useful in SEO situation or\n * when you want to maximize the responsiveness of the Popper.\n * @default false\n */\n keepMounted: PropTypes.bool,\n /**\n * Popper.js is based on a \"plugin-like\" architecture,\n * most of its features are fully encapsulated \"modifiers\".\n *\n * A modifier is a function that is called each time Popper.js needs to\n * compute the position of the popper.\n * For this reason, modifiers should be very performant to avoid bottlenecks.\n * To learn how to create a modifier, [read the modifiers documentation](https://popper.js.org/docs/v2/modifiers/).\n */\n modifiers: PropTypes.arrayOf(PropTypes.shape({\n data: PropTypes.object,\n effect: PropTypes.func,\n enabled: PropTypes.bool,\n fn: PropTypes.func,\n name: PropTypes.any,\n options: PropTypes.object,\n phase: PropTypes.oneOf(['afterMain', 'afterRead', 'afterWrite', 'beforeMain', 'beforeRead', 'beforeWrite', 'main', 'read', 'write']),\n requires: PropTypes.arrayOf(PropTypes.string),\n requiresIfExists: PropTypes.arrayOf(PropTypes.string)\n })),\n /**\n * If `true`, the component is shown.\n */\n open: PropTypes.bool.isRequired,\n /**\n * Popper placement.\n * @default 'bottom'\n */\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n /**\n * Options provided to the [`Popper.js`](https://popper.js.org/docs/v2/constructors/#options) instance.\n * @default {}\n */\n popperOptions: PropTypes.shape({\n modifiers: PropTypes.array,\n onFirstUpdate: PropTypes.func,\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n strategy: PropTypes.oneOf(['absolute', 'fixed'])\n }),\n /**\n * A ref that points to the used popper instance.\n */\n popperRef: refType,\n /**\n * The props used for each slot inside the Popper.\n * @default {}\n */\n slotProps: PropTypes.shape({\n root: PropTypes.oneOfType([PropTypes.func, PropTypes.object])\n }),\n /**\n * The components used for each slot inside the Popper.\n * Either a string to use a HTML element or a component.\n * @default {}\n */\n slots: PropTypes.shape({\n root: PropTypes.elementType\n }),\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Help supporting a react-transition-group/Transition component.\n * @default false\n */\n transition: PropTypes.bool\n} : void 0;\nexport default Popper;","import generateUtilityClasses from '@mui/utils/generateUtilityClasses';\nimport generateUtilityClass from '@mui/utils/generateUtilityClass';\nexport function getTooltipUtilityClass(slot) {\n return generateUtilityClass('MuiTooltip', slot);\n}\nconst tooltipClasses = generateUtilityClasses('MuiTooltip', ['popper', 'popperInteractive', 'popperArrow', 'popperClose', 'tooltip', 'tooltipArrow', 'touch', 'tooltipPlacementLeft', 'tooltipPlacementRight', 'tooltipPlacementTop', 'tooltipPlacementBottom', 'arrow']);\nexport default tooltipClasses;","'use client';\n\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nconst _excluded = [\"arrow\", \"children\", \"classes\", \"components\", \"componentsProps\", \"describeChild\", \"disableFocusListener\", \"disableHoverListener\", \"disableInteractive\", \"disableTouchListener\", \"enterDelay\", \"enterNextDelay\", \"enterTouchDelay\", \"followCursor\", \"id\", \"leaveDelay\", \"leaveTouchDelay\", \"onClose\", \"onOpen\", \"open\", \"placement\", \"PopperComponent\", \"PopperProps\", \"slotProps\", \"slots\", \"title\", \"TransitionComponent\", \"TransitionProps\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport clsx from 'clsx';\nimport { elementAcceptingRef, unstable_useTimeout as useTimeout, unstable_Timeout as Timeout } from '@mui/utils';\nimport { unstable_composeClasses as composeClasses, appendOwnerState } from '@mui/base';\nimport { alpha } from '@mui/system';\nimport styled from '../styles/styled';\nimport useTheme from '../styles/useTheme';\nimport useThemeProps from '../styles/useThemeProps';\nimport capitalize from '../utils/capitalize';\nimport Grow from '../Grow';\nimport Popper from '../Popper';\nimport useEventCallback from '../utils/useEventCallback';\nimport useForkRef from '../utils/useForkRef';\nimport useId from '../utils/useId';\nimport useIsFocusVisible from '../utils/useIsFocusVisible';\nimport useControlled from '../utils/useControlled';\nimport tooltipClasses, { getTooltipUtilityClass } from './tooltipClasses';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nimport { jsxs as _jsxs } from \"react/jsx-runtime\";\nfunction round(value) {\n return Math.round(value * 1e5) / 1e5;\n}\nconst useUtilityClasses = ownerState => {\n const {\n classes,\n disableInteractive,\n arrow,\n touch,\n placement\n } = ownerState;\n const slots = {\n popper: ['popper', !disableInteractive && 'popperInteractive', arrow && 'popperArrow'],\n tooltip: ['tooltip', arrow && 'tooltipArrow', touch && 'touch', `tooltipPlacement${capitalize(placement.split('-')[0])}`],\n arrow: ['arrow']\n };\n return composeClasses(slots, getTooltipUtilityClass, classes);\n};\nconst TooltipPopper = styled(Popper, {\n name: 'MuiTooltip',\n slot: 'Popper',\n overridesResolver: (props, styles) => {\n const {\n ownerState\n } = props;\n return [styles.popper, !ownerState.disableInteractive && styles.popperInteractive, ownerState.arrow && styles.popperArrow, !ownerState.open && styles.popperClose];\n }\n})(({\n theme,\n ownerState,\n open\n}) => _extends({\n zIndex: (theme.vars || theme).zIndex.tooltip,\n pointerEvents: 'none'\n}, !ownerState.disableInteractive && {\n pointerEvents: 'auto'\n}, !open && {\n pointerEvents: 'none'\n}, ownerState.arrow && {\n [`&[data-popper-placement*=\"bottom\"] .${tooltipClasses.arrow}`]: {\n top: 0,\n marginTop: '-0.71em',\n '&::before': {\n transformOrigin: '0 100%'\n }\n },\n [`&[data-popper-placement*=\"top\"] .${tooltipClasses.arrow}`]: {\n bottom: 0,\n marginBottom: '-0.71em',\n '&::before': {\n transformOrigin: '100% 0'\n }\n },\n [`&[data-popper-placement*=\"right\"] .${tooltipClasses.arrow}`]: _extends({}, !ownerState.isRtl ? {\n left: 0,\n marginLeft: '-0.71em'\n } : {\n right: 0,\n marginRight: '-0.71em'\n }, {\n height: '1em',\n width: '0.71em',\n '&::before': {\n transformOrigin: '100% 100%'\n }\n }),\n [`&[data-popper-placement*=\"left\"] .${tooltipClasses.arrow}`]: _extends({}, !ownerState.isRtl ? {\n right: 0,\n marginRight: '-0.71em'\n } : {\n left: 0,\n marginLeft: '-0.71em'\n }, {\n height: '1em',\n width: '0.71em',\n '&::before': {\n transformOrigin: '0 0'\n }\n })\n}));\nconst TooltipTooltip = styled('div', {\n name: 'MuiTooltip',\n slot: 'Tooltip',\n overridesResolver: (props, styles) => {\n const {\n ownerState\n } = props;\n return [styles.tooltip, ownerState.touch && styles.touch, ownerState.arrow && styles.tooltipArrow, styles[`tooltipPlacement${capitalize(ownerState.placement.split('-')[0])}`]];\n }\n})(({\n theme,\n ownerState\n}) => _extends({\n backgroundColor: theme.vars ? theme.vars.palette.Tooltip.bg : alpha(theme.palette.grey[700], 0.92),\n borderRadius: (theme.vars || theme).shape.borderRadius,\n color: (theme.vars || theme).palette.common.white,\n fontFamily: theme.typography.fontFamily,\n padding: '4px 8px',\n fontSize: theme.typography.pxToRem(11),\n maxWidth: 300,\n margin: 2,\n wordWrap: 'break-word',\n fontWeight: theme.typography.fontWeightMedium\n}, ownerState.arrow && {\n position: 'relative',\n margin: 0\n}, ownerState.touch && {\n padding: '8px 16px',\n fontSize: theme.typography.pxToRem(14),\n lineHeight: `${round(16 / 14)}em`,\n fontWeight: theme.typography.fontWeightRegular\n}, {\n [`.${tooltipClasses.popper}[data-popper-placement*=\"left\"] &`]: _extends({\n transformOrigin: 'right center'\n }, !ownerState.isRtl ? _extends({\n marginRight: '14px'\n }, ownerState.touch && {\n marginRight: '24px'\n }) : _extends({\n marginLeft: '14px'\n }, ownerState.touch && {\n marginLeft: '24px'\n })),\n [`.${tooltipClasses.popper}[data-popper-placement*=\"right\"] &`]: _extends({\n transformOrigin: 'left center'\n }, !ownerState.isRtl ? _extends({\n marginLeft: '14px'\n }, ownerState.touch && {\n marginLeft: '24px'\n }) : _extends({\n marginRight: '14px'\n }, ownerState.touch && {\n marginRight: '24px'\n })),\n [`.${tooltipClasses.popper}[data-popper-placement*=\"top\"] &`]: _extends({\n transformOrigin: 'center bottom',\n marginBottom: '14px'\n }, ownerState.touch && {\n marginBottom: '24px'\n }),\n [`.${tooltipClasses.popper}[data-popper-placement*=\"bottom\"] &`]: _extends({\n transformOrigin: 'center top',\n marginTop: '14px'\n }, ownerState.touch && {\n marginTop: '24px'\n })\n}));\nconst TooltipArrow = styled('span', {\n name: 'MuiTooltip',\n slot: 'Arrow',\n overridesResolver: (props, styles) => styles.arrow\n})(({\n theme\n}) => ({\n overflow: 'hidden',\n position: 'absolute',\n width: '1em',\n height: '0.71em' /* = width / sqrt(2) = (length of the hypotenuse) */,\n boxSizing: 'border-box',\n color: theme.vars ? theme.vars.palette.Tooltip.bg : alpha(theme.palette.grey[700], 0.9),\n '&::before': {\n content: '\"\"',\n margin: 'auto',\n display: 'block',\n width: '100%',\n height: '100%',\n backgroundColor: 'currentColor',\n transform: 'rotate(45deg)'\n }\n}));\nlet hystersisOpen = false;\nconst hystersisTimer = new Timeout();\nlet cursorPosition = {\n x: 0,\n y: 0\n};\nexport function testReset() {\n hystersisOpen = false;\n hystersisTimer.clear();\n}\nfunction composeEventHandler(handler, eventHandler) {\n return event => {\n if (eventHandler) {\n eventHandler(event);\n }\n handler(event);\n };\n}\n\n// TODO v6: Remove PopperComponent, PopperProps, TransitionComponent and TransitionProps.\nconst Tooltip = /*#__PURE__*/React.forwardRef(function Tooltip(inProps, ref) {\n var _ref, _slots$popper, _ref2, _ref3, _slots$transition, _ref4, _slots$tooltip, _ref5, _slots$arrow, _slotProps$popper, _ref6, _slotProps$popper2, _slotProps$transition, _slotProps$tooltip, _ref7, _slotProps$tooltip2, _slotProps$arrow, _ref8, _slotProps$arrow2;\n const props = useThemeProps({\n props: inProps,\n name: 'MuiTooltip'\n });\n const {\n arrow = false,\n children: childrenProp,\n components = {},\n componentsProps = {},\n describeChild = false,\n disableFocusListener = false,\n disableHoverListener = false,\n disableInteractive: disableInteractiveProp = false,\n disableTouchListener = false,\n enterDelay = 100,\n enterNextDelay = 0,\n enterTouchDelay = 700,\n followCursor = false,\n id: idProp,\n leaveDelay = 0,\n leaveTouchDelay = 1500,\n onClose,\n onOpen,\n open: openProp,\n placement = 'bottom',\n PopperComponent: PopperComponentProp,\n PopperProps = {},\n slotProps = {},\n slots = {},\n title,\n TransitionComponent: TransitionComponentProp = Grow,\n TransitionProps\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n\n // to prevent runtime errors, developers will need to provide a child as a React element anyway.\n const children = /*#__PURE__*/React.isValidElement(childrenProp) ? childrenProp : /*#__PURE__*/_jsx(\"span\", {\n children: childrenProp\n });\n const theme = useTheme();\n const isRtl = theme.direction === 'rtl';\n const [childNode, setChildNode] = React.useState();\n const [arrowRef, setArrowRef] = React.useState(null);\n const ignoreNonTouchEvents = React.useRef(false);\n const disableInteractive = disableInteractiveProp || followCursor;\n const closeTimer = useTimeout();\n const enterTimer = useTimeout();\n const leaveTimer = useTimeout();\n const touchTimer = useTimeout();\n const [openState, setOpenState] = useControlled({\n controlled: openProp,\n default: false,\n name: 'Tooltip',\n state: 'open'\n });\n let open = openState;\n if (process.env.NODE_ENV !== 'production') {\n // eslint-disable-next-line react-hooks/rules-of-hooks\n const {\n current: isControlled\n } = React.useRef(openProp !== undefined);\n\n // eslint-disable-next-line react-hooks/rules-of-hooks\n React.useEffect(() => {\n if (childNode && childNode.disabled && !isControlled && title !== '' && childNode.tagName.toLowerCase() === 'button') {\n console.error(['MUI: You are providing a disabled `button` child to the Tooltip component.', 'A disabled element does not fire events.', \"Tooltip needs to listen to the child element's events to display the title.\", '', 'Add a simple wrapper element, such as a `span`.'].join('\\n'));\n }\n }, [title, childNode, isControlled]);\n }\n const id = useId(idProp);\n const prevUserSelect = React.useRef();\n const stopTouchInteraction = useEventCallback(() => {\n if (prevUserSelect.current !== undefined) {\n document.body.style.WebkitUserSelect = prevUserSelect.current;\n prevUserSelect.current = undefined;\n }\n touchTimer.clear();\n });\n React.useEffect(() => stopTouchInteraction, [stopTouchInteraction]);\n const handleOpen = event => {\n hystersisTimer.clear();\n hystersisOpen = true;\n\n // The mouseover event will trigger for every nested element in the tooltip.\n // We can skip rerendering when the tooltip is already open.\n // We are using the mouseover event instead of the mouseenter event to fix a hide/show issue.\n setOpenState(true);\n if (onOpen && !open) {\n onOpen(event);\n }\n };\n const handleClose = useEventCallback(\n /**\n * @param {React.SyntheticEvent | Event} event\n */\n event => {\n hystersisTimer.start(800 + leaveDelay, () => {\n hystersisOpen = false;\n });\n setOpenState(false);\n if (onClose && open) {\n onClose(event);\n }\n closeTimer.start(theme.transitions.duration.shortest, () => {\n ignoreNonTouchEvents.current = false;\n });\n });\n const handleEnter = event => {\n if (ignoreNonTouchEvents.current && event.type !== 'touchstart') {\n return;\n }\n\n // Remove the title ahead of time.\n // We don't want to wait for the next render commit.\n // We would risk displaying two tooltips at the same time (native + this one).\n if (childNode) {\n childNode.removeAttribute('title');\n }\n enterTimer.clear();\n leaveTimer.clear();\n if (enterDelay || hystersisOpen && enterNextDelay) {\n enterTimer.start(hystersisOpen ? enterNextDelay : enterDelay, () => {\n handleOpen(event);\n });\n } else {\n handleOpen(event);\n }\n };\n const handleLeave = event => {\n enterTimer.clear();\n leaveTimer.start(leaveDelay, () => {\n handleClose(event);\n });\n };\n const {\n isFocusVisibleRef,\n onBlur: handleBlurVisible,\n onFocus: handleFocusVisible,\n ref: focusVisibleRef\n } = useIsFocusVisible();\n // We don't necessarily care about the focusVisible state (which is safe to access via ref anyway).\n // We just need to re-render the Tooltip if the focus-visible state changes.\n const [, setChildIsFocusVisible] = React.useState(false);\n const handleBlur = event => {\n handleBlurVisible(event);\n if (isFocusVisibleRef.current === false) {\n setChildIsFocusVisible(false);\n handleLeave(event);\n }\n };\n const handleFocus = event => {\n // Workaround for https://github.com/facebook/react/issues/7769\n // The autoFocus of React might trigger the event before the componentDidMount.\n // We need to account for this eventuality.\n if (!childNode) {\n setChildNode(event.currentTarget);\n }\n handleFocusVisible(event);\n if (isFocusVisibleRef.current === true) {\n setChildIsFocusVisible(true);\n handleEnter(event);\n }\n };\n const detectTouchStart = event => {\n ignoreNonTouchEvents.current = true;\n const childrenProps = children.props;\n if (childrenProps.onTouchStart) {\n childrenProps.onTouchStart(event);\n }\n };\n const handleMouseOver = handleEnter;\n const handleMouseLeave = handleLeave;\n const handleTouchStart = event => {\n detectTouchStart(event);\n leaveTimer.clear();\n closeTimer.clear();\n stopTouchInteraction();\n prevUserSelect.current = document.body.style.WebkitUserSelect;\n // Prevent iOS text selection on long-tap.\n document.body.style.WebkitUserSelect = 'none';\n touchTimer.start(enterTouchDelay, () => {\n document.body.style.WebkitUserSelect = prevUserSelect.current;\n handleEnter(event);\n });\n };\n const handleTouchEnd = event => {\n if (children.props.onTouchEnd) {\n children.props.onTouchEnd(event);\n }\n stopTouchInteraction();\n leaveTimer.start(leaveTouchDelay, () => {\n handleClose(event);\n });\n };\n React.useEffect(() => {\n if (!open) {\n return undefined;\n }\n\n /**\n * @param {KeyboardEvent} nativeEvent\n */\n function handleKeyDown(nativeEvent) {\n // IE11, Edge (prior to using Bink?) use 'Esc'\n if (nativeEvent.key === 'Escape' || nativeEvent.key === 'Esc') {\n handleClose(nativeEvent);\n }\n }\n document.addEventListener('keydown', handleKeyDown);\n return () => {\n document.removeEventListener('keydown', handleKeyDown);\n };\n }, [handleClose, open]);\n const handleRef = useForkRef(children.ref, focusVisibleRef, setChildNode, ref);\n\n // There is no point in displaying an empty tooltip.\n // So we exclude all falsy values, except 0, which is valid.\n if (!title && title !== 0) {\n open = false;\n }\n const popperRef = React.useRef();\n const handleMouseMove = event => {\n const childrenProps = children.props;\n if (childrenProps.onMouseMove) {\n childrenProps.onMouseMove(event);\n }\n cursorPosition = {\n x: event.clientX,\n y: event.clientY\n };\n if (popperRef.current) {\n popperRef.current.update();\n }\n };\n const nameOrDescProps = {};\n const titleIsString = typeof title === 'string';\n if (describeChild) {\n nameOrDescProps.title = !open && titleIsString && !disableHoverListener ? title : null;\n nameOrDescProps['aria-describedby'] = open ? id : null;\n } else {\n nameOrDescProps['aria-label'] = titleIsString ? title : null;\n nameOrDescProps['aria-labelledby'] = open && !titleIsString ? id : null;\n }\n const childrenProps = _extends({}, nameOrDescProps, other, children.props, {\n className: clsx(other.className, children.props.className),\n onTouchStart: detectTouchStart,\n ref: handleRef\n }, followCursor ? {\n onMouseMove: handleMouseMove\n } : {});\n if (process.env.NODE_ENV !== 'production') {\n childrenProps['data-mui-internal-clone-element'] = true;\n\n // eslint-disable-next-line react-hooks/rules-of-hooks\n React.useEffect(() => {\n if (childNode && !childNode.getAttribute('data-mui-internal-clone-element')) {\n console.error(['MUI: The `children` component of the Tooltip is not forwarding its props correctly.', 'Please make sure that props are spread on the same element that the ref is applied to.'].join('\\n'));\n }\n }, [childNode]);\n }\n const interactiveWrapperListeners = {};\n if (!disableTouchListener) {\n childrenProps.onTouchStart = handleTouchStart;\n childrenProps.onTouchEnd = handleTouchEnd;\n }\n if (!disableHoverListener) {\n childrenProps.onMouseOver = composeEventHandler(handleMouseOver, childrenProps.onMouseOver);\n childrenProps.onMouseLeave = composeEventHandler(handleMouseLeave, childrenProps.onMouseLeave);\n if (!disableInteractive) {\n interactiveWrapperListeners.onMouseOver = handleMouseOver;\n interactiveWrapperListeners.onMouseLeave = handleMouseLeave;\n }\n }\n if (!disableFocusListener) {\n childrenProps.onFocus = composeEventHandler(handleFocus, childrenProps.onFocus);\n childrenProps.onBlur = composeEventHandler(handleBlur, childrenProps.onBlur);\n if (!disableInteractive) {\n interactiveWrapperListeners.onFocus = handleFocus;\n interactiveWrapperListeners.onBlur = handleBlur;\n }\n }\n if (process.env.NODE_ENV !== 'production') {\n if (children.props.title) {\n console.error(['MUI: You have provided a `title` prop to the child of .', `Remove this title prop \\`${children.props.title}\\` or the Tooltip component.`].join('\\n'));\n }\n }\n const popperOptions = React.useMemo(() => {\n var _PopperProps$popperOp;\n let tooltipModifiers = [{\n name: 'arrow',\n enabled: Boolean(arrowRef),\n options: {\n element: arrowRef,\n padding: 4\n }\n }];\n if ((_PopperProps$popperOp = PopperProps.popperOptions) != null && _PopperProps$popperOp.modifiers) {\n tooltipModifiers = tooltipModifiers.concat(PopperProps.popperOptions.modifiers);\n }\n return _extends({}, PopperProps.popperOptions, {\n modifiers: tooltipModifiers\n });\n }, [arrowRef, PopperProps]);\n const ownerState = _extends({}, props, {\n isRtl,\n arrow,\n disableInteractive,\n placement,\n PopperComponentProp,\n touch: ignoreNonTouchEvents.current\n });\n const classes = useUtilityClasses(ownerState);\n const PopperComponent = (_ref = (_slots$popper = slots.popper) != null ? _slots$popper : components.Popper) != null ? _ref : TooltipPopper;\n const TransitionComponent = (_ref2 = (_ref3 = (_slots$transition = slots.transition) != null ? _slots$transition : components.Transition) != null ? _ref3 : TransitionComponentProp) != null ? _ref2 : Grow;\n const TooltipComponent = (_ref4 = (_slots$tooltip = slots.tooltip) != null ? _slots$tooltip : components.Tooltip) != null ? _ref4 : TooltipTooltip;\n const ArrowComponent = (_ref5 = (_slots$arrow = slots.arrow) != null ? _slots$arrow : components.Arrow) != null ? _ref5 : TooltipArrow;\n const popperProps = appendOwnerState(PopperComponent, _extends({}, PopperProps, (_slotProps$popper = slotProps.popper) != null ? _slotProps$popper : componentsProps.popper, {\n className: clsx(classes.popper, PopperProps == null ? void 0 : PopperProps.className, (_ref6 = (_slotProps$popper2 = slotProps.popper) != null ? _slotProps$popper2 : componentsProps.popper) == null ? void 0 : _ref6.className)\n }), ownerState);\n const transitionProps = appendOwnerState(TransitionComponent, _extends({}, TransitionProps, (_slotProps$transition = slotProps.transition) != null ? _slotProps$transition : componentsProps.transition), ownerState);\n const tooltipProps = appendOwnerState(TooltipComponent, _extends({}, (_slotProps$tooltip = slotProps.tooltip) != null ? _slotProps$tooltip : componentsProps.tooltip, {\n className: clsx(classes.tooltip, (_ref7 = (_slotProps$tooltip2 = slotProps.tooltip) != null ? _slotProps$tooltip2 : componentsProps.tooltip) == null ? void 0 : _ref7.className)\n }), ownerState);\n const tooltipArrowProps = appendOwnerState(ArrowComponent, _extends({}, (_slotProps$arrow = slotProps.arrow) != null ? _slotProps$arrow : componentsProps.arrow, {\n className: clsx(classes.arrow, (_ref8 = (_slotProps$arrow2 = slotProps.arrow) != null ? _slotProps$arrow2 : componentsProps.arrow) == null ? void 0 : _ref8.className)\n }), ownerState);\n return /*#__PURE__*/_jsxs(React.Fragment, {\n children: [/*#__PURE__*/React.cloneElement(children, childrenProps), /*#__PURE__*/_jsx(PopperComponent, _extends({\n as: PopperComponentProp != null ? PopperComponentProp : Popper,\n placement: placement,\n anchorEl: followCursor ? {\n getBoundingClientRect: () => ({\n top: cursorPosition.y,\n left: cursorPosition.x,\n right: cursorPosition.x,\n bottom: cursorPosition.y,\n width: 0,\n height: 0\n })\n } : childNode,\n popperRef: popperRef,\n open: childNode ? open : false,\n id: id,\n transition: true\n }, interactiveWrapperListeners, popperProps, {\n popperOptions: popperOptions,\n children: ({\n TransitionProps: TransitionPropsInner\n }) => /*#__PURE__*/_jsx(TransitionComponent, _extends({\n timeout: theme.transitions.duration.shorter\n }, TransitionPropsInner, transitionProps, {\n children: /*#__PURE__*/_jsxs(TooltipComponent, _extends({}, tooltipProps, {\n children: [title, arrow ? /*#__PURE__*/_jsx(ArrowComponent, _extends({}, tooltipArrowProps, {\n ref: setArrowRef\n })) : null]\n }))\n }))\n }))]\n });\n});\nprocess.env.NODE_ENV !== \"production\" ? Tooltip.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the d.ts file and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * If `true`, adds an arrow to the tooltip.\n * @default false\n */\n arrow: PropTypes.bool,\n /**\n * Tooltip reference element.\n */\n children: elementAcceptingRef.isRequired,\n /**\n * Override or extend the styles applied to the component.\n */\n classes: PropTypes.object,\n /**\n * @ignore\n */\n className: PropTypes.string,\n /**\n * The components used for each slot inside.\n *\n * This prop is an alias for the `slots` prop.\n * It's recommended to use the `slots` prop instead.\n *\n * @default {}\n */\n components: PropTypes.shape({\n Arrow: PropTypes.elementType,\n Popper: PropTypes.elementType,\n Tooltip: PropTypes.elementType,\n Transition: PropTypes.elementType\n }),\n /**\n * The extra props for the slot components.\n * You can override the existing props or add new ones.\n *\n * This prop is an alias for the `slotProps` prop.\n * It's recommended to use the `slotProps` prop instead, as `componentsProps` will be deprecated in the future.\n *\n * @default {}\n */\n componentsProps: PropTypes.shape({\n arrow: PropTypes.object,\n popper: PropTypes.object,\n tooltip: PropTypes.object,\n transition: PropTypes.object\n }),\n /**\n * Set to `true` if the `title` acts as an accessible description.\n * By default the `title` acts as an accessible label for the child.\n * @default false\n */\n describeChild: PropTypes.bool,\n /**\n * Do not respond to focus-visible events.\n * @default false\n */\n disableFocusListener: PropTypes.bool,\n /**\n * Do not respond to hover events.\n * @default false\n */\n disableHoverListener: PropTypes.bool,\n /**\n * Makes a tooltip not interactive, i.e. it will close when the user\n * hovers over the tooltip before the `leaveDelay` is expired.\n * @default false\n */\n disableInteractive: PropTypes.bool,\n /**\n * Do not respond to long press touch events.\n * @default false\n */\n disableTouchListener: PropTypes.bool,\n /**\n * The number of milliseconds to wait before showing the tooltip.\n * This prop won't impact the enter touch delay (`enterTouchDelay`).\n * @default 100\n */\n enterDelay: PropTypes.number,\n /**\n * The number of milliseconds to wait before showing the tooltip when one was already recently opened.\n * @default 0\n */\n enterNextDelay: PropTypes.number,\n /**\n * The number of milliseconds a user must touch the element before showing the tooltip.\n * @default 700\n */\n enterTouchDelay: PropTypes.number,\n /**\n * If `true`, the tooltip follow the cursor over the wrapped element.\n * @default false\n */\n followCursor: PropTypes.bool,\n /**\n * This prop is used to help implement the accessibility logic.\n * If you don't provide this prop. It falls back to a randomly generated id.\n */\n id: PropTypes.string,\n /**\n * The number of milliseconds to wait before hiding the tooltip.\n * This prop won't impact the leave touch delay (`leaveTouchDelay`).\n * @default 0\n */\n leaveDelay: PropTypes.number,\n /**\n * The number of milliseconds after the user stops touching an element before hiding the tooltip.\n * @default 1500\n */\n leaveTouchDelay: PropTypes.number,\n /**\n * Callback fired when the component requests to be closed.\n *\n * @param {React.SyntheticEvent} event The event source of the callback.\n */\n onClose: PropTypes.func,\n /**\n * Callback fired when the component requests to be open.\n *\n * @param {React.SyntheticEvent} event The event source of the callback.\n */\n onOpen: PropTypes.func,\n /**\n * If `true`, the component is shown.\n */\n open: PropTypes.bool,\n /**\n * Tooltip placement.\n * @default 'bottom'\n */\n placement: PropTypes.oneOf(['bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n /**\n * The component used for the popper.\n * @default Popper\n */\n PopperComponent: PropTypes.elementType,\n /**\n * Props applied to the [`Popper`](/material-ui/api/popper/) element.\n * @default {}\n */\n PopperProps: PropTypes.object,\n /**\n * The extra props for the slot components.\n * You can override the existing props or add new ones.\n *\n * This prop is an alias for the `componentsProps` prop, which will be deprecated in the future.\n *\n * @default {}\n */\n slotProps: PropTypes.shape({\n arrow: PropTypes.object,\n popper: PropTypes.object,\n tooltip: PropTypes.object,\n transition: PropTypes.object\n }),\n /**\n * The components used for each slot inside.\n *\n * This prop is an alias for the `components` prop, which will be deprecated in the future.\n *\n * @default {}\n */\n slots: PropTypes.shape({\n arrow: PropTypes.elementType,\n popper: PropTypes.elementType,\n tooltip: PropTypes.elementType,\n transition: PropTypes.elementType\n }),\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Tooltip title. Zero-length titles string, undefined, null and false are never displayed.\n */\n title: PropTypes.node,\n /**\n * The component used for the transition.\n * [Follow this guide](/material-ui/transitions/#transitioncomponent-prop) to learn more about the requirements for this component.\n * @default Grow\n */\n TransitionComponent: PropTypes.elementType,\n /**\n * Props applied to the transition element.\n * By default, the element is based on this [`Transition`](http://reactcommunity.org/react-transition-group/transition/) component.\n */\n TransitionProps: PropTypes.object\n} : void 0;\nexport default Tooltip;","import '@/components/mui/menu-item.component.css';\nimport ArrowRightIcon from '@mui/icons-material/ArrowRight';\nimport {\n ListItemIcon as MuiListItemIcon,\n ListItemText as MuiListItemText,\n MenuItem as MuiMenuItem,\n} from '@mui/material';\nimport Tooltip from '@mui/material/Tooltip';\nimport { Localized, ReferencedItem, SingleColumnMenu } from 'platform-bible-utils';\nimport { MouseEvent, PropsWithChildren } from 'react';\n\ntype MenuItemInfoBase = {\n /** Text (displayable in the UI) as the name of the menu item */\n label: string;\n /** Text to display when the mouse hovers over the menu item */\n tooltip?: string;\n};\n\nexport type Command = MenuItemInfoBase & {\n /** Command to execute (string.string) */\n command: string;\n};\n\ntype SubMenu = MenuItemInfoBase & {\n /** Command to execute (string.string) */\n items: MenuItemInfo[];\n};\n\nexport interface CommandHandler {\n (command: Command): void;\n}\n\nexport type MenuPropsBase = {\n /*\n * The JSON defining the menu whose items are to be rendered. This will typically be one of the\n * menus in the \"defs\" in a Platform.Bible menu (see PlatformMenus). The schema for this is\n * menuDocumentSchema (at the end of menus.model.ts). Note that while this is a\n * \"SingleColumnMenu\", somewhat bizarrely, a MultiColumnMenu is a SingleColumnMenu, so it really\n * could be a MultiColumnMenu, in which case, column had better be defined so it can be used\n * to filter out the actual groups and items to display on the column.\n */\n menuDefinition: Localized;\n\n commandHandler: CommandHandler;\n\n /**\n * Additional action to perform when any menu item is clicked. Allows the caller to handle event\n * (e.g., to close the menu).\n */\n onClick?: (event: MouseEvent) => void;\n};\n\nexport type MenuItemListProps = MenuPropsBase & {\n /** Optional unique (column) identifier */\n columnId?: ReferencedItem;\n};\n\nexport type MenuItemProps = Omit &\n PropsWithChildren<{\n /** Optional unique identifier */\n id?: string;\n\n onClick: (event: MouseEvent) => void;\n }>;\n\ntype MenuItemInfo = (Command | SubMenu) & {\n /**\n * If specified, menu item will be inset if it does not have a leading icon.\n *\n * @default true\n */\n allowForLeadingIcons?: boolean;\n /**\n * If specified, the path to the icon image to display on the leading side of the menu text.\n *\n * @default undefined (no leading icon will be shown)\n */\n iconPathBefore?: string;\n /**\n * If specified, the path to the icon image to display on the trailing side of the menu text.\n *\n * @default undefined (no trailing icon will be shown)\n */\n iconPathAfter?: string;\n /**\n * If true, list item is focused during the first mount\n *\n * @default false\n */\n hasAutoFocus?: boolean;\n\n /** Additional css classes to help with unique styling of the menu item */\n className?: string;\n\n /**\n * If true, the menu item will appear disabled and it will not respond to clicks or mouse hovers.\n *\n * @default false\n */\n isDisabled?: boolean;\n\n /**\n * If true, compact vertical padding designed for keyboard and mouse input is used.\n *\n * @default true\n */\n isDense?: boolean;\n\n /**\n * If true, a right-arrow icon will be displayed (iconPathAfter, if specified, will be ignored).\n *\n * @default false\n */\n isSubMenuParent?: boolean;\n\n /**\n * If true, the left and right padding is removed\n *\n * @default false\n */\n hasDisabledGutters?: boolean;\n\n /**\n * If true, a 1px light border is added to bottom of menu item\n *\n * @default false\n */\n hasDivider?: boolean;\n\n /** Help identify which element has keyboard focus */\n focusVisibleClassName?: string;\n\n /** If it's a submenu, it should have the items property */\n items?: MenuItemInfo[];\n};\n\nfunction getIcon(icon: string | undefined, menuLabel: string, leading: boolean) {\n return icon ? (\n \n {`${leading\n \n ) : undefined;\n}\n\nexport default function MenuItem(props: MenuItemProps) {\n const {\n onClick,\n label,\n tooltip,\n allowForLeadingIcons = true,\n iconPathBefore = undefined,\n iconPathAfter = undefined,\n hasAutoFocus = false,\n className,\n isDisabled = false,\n isDense = true,\n isSubMenuParent = false,\n hasDisabledGutters = false,\n hasDivider = false,\n focusVisibleClassName,\n id,\n children,\n } = props;\n\n const menuItem = (\n \n {label ? (\n <>\n {getIcon(iconPathBefore, label, true)}\n \n {isSubMenuParent ? (\n \n \n \n ) : (\n getIcon(iconPathAfter, label, false)\n )}\n \n ) : (\n children\n )}\n \n );\n\n return tooltip ? (\n \n
    {menuItem}
    \n
    \n ) : (\n menuItem\n );\n}\n","import MenuItem, {\n MenuItemListProps,\n MenuItemProps,\n MenuPropsBase,\n} from '@/components/mui/menu-item.component';\nimport { Menu } from '@mui/material';\nimport {\n Localized,\n MenuGroupDetailsInSubMenu,\n MenuItemContainingCommand,\n MenuItemContainingSubmenu,\n OrderedExtensibleContainer,\n ReferencedItem,\n SingleColumnMenu,\n} from 'platform-bible-utils';\nimport { MouseEvent, useMemo, useState } from 'react';\n\n/**\n * All the exported types in this file should be regarded as \"internal\" (i.e., they should not be\n * exposed via index.ts).\n */\n\nexport type GroupedMenuPropsBase = MenuPropsBase & {\n /** Optional unique (column) identifier */\n columnId?: ReferencedItem;\n};\n\nexport type GroupedMenuItemListProps = MenuItemListProps & {\n /**\n * If the menuDefinition includes \"top-level\" groups (i.e., those that belong to a column as\n * opposed to those that belong to a submenu) that should not be included in the list, then this\n * array specifies which groups to include. Likewise, for a submenu, this list indicates which\n * groups are pertinent for that submenu. So then for a context menu this property need not be\n * specified since it is a top-level menu based on a \"true\" SingleColumnMenu (i.e., one that is\n * not a MultiColumnMenu).\n */\n includedGroups?: {\n id: string;\n group: Localized;\n }[];\n};\n\ninterface ItemInfo {\n item: Localized;\n isLastItemInGroup: boolean;\n}\n\ntype SubMenuProps = MenuPropsBase & {\n parentMenuItem: Localized;\n parentItemProps: Omit, 'iconPathAfter'>;\n};\n\nfunction getAllGroups(menuDefinition: Localized) {\n const groupEntries = Object.entries(menuDefinition.groups);\n // Convert array of entries to array of objects with id and group properties\n return groupEntries.map(([key, value]) => ({ id: key, group: value }));\n}\n\nfunction SubMenu(props: SubMenuProps) {\n const [anchorEl, setAnchorEl] = useState(undefined);\n\n const { parentMenuItem, parentItemProps, menuDefinition } = props;\n\n const handleParentMenuItemClick = (event: MouseEvent) => {\n setAnchorEl(event.currentTarget);\n };\n\n const handleClose = () => {\n setAnchorEl(undefined);\n };\n\n const renderSubMenuItems = () => {\n let includedGroups = getAllGroups(menuDefinition).filter((g) => 'menuItem' in g.group);\n\n // Ensure valid parent menu was provided. (If not, submenu will contain all groups!)\n if (!parentMenuItem?.id) throw new Error('A valid parent menu item is required for submenus.');\n\n // When laying out a submenu, only include groups associated with the provided parent menu.\n // Note: without the (annoying) redundant check that the included groups\n // have the menuItem field, TS doesn't think it exists.\n includedGroups = includedGroups.filter(\n (group) => 'menuItem' in group.group && group.group.menuItem === parentMenuItem.id,\n );\n\n return ;\n };\n\n return (\n <>\n \n \n {renderSubMenuItems()}\n \n \n );\n}\n\nconst getOrderedGroupItems = (\n groupId: string,\n allItems: Localized[],\n) => {\n // Filter items that belong to the specified group\n const itemsForGroup = allItems.filter((item) => item.group === groupId);\n // Sort items based on order\n const sortedItems = itemsForGroup.sort((a, b) => (a.order || 0) - (b.order || 0));\n return sortedItems;\n};\n\n/**\n * This component is internal; it does not need to be exposed to the outside world since it is not\n * useful on its own. It is used to generate and lay out the MenuItems that appear either on a\n * top-level menu (in a GridMenu or ContextMenu) or in a submenu.\n */\nexport default function GroupedMenuItemList(menuProps: GroupedMenuItemListProps) {\n const { menuDefinition, onClick, commandHandler, includedGroups } = menuProps;\n\n const { items, allowForLeadingIcons } = useMemo(() => {\n const groupsToInclude =\n includedGroups && includedGroups.length > 0\n ? includedGroups\n : // We're apparently laying out a single-column menu (presumably a context menu). In this\n // case, all groups should be included except ones that belong to a submenu.\n getAllGroups(menuDefinition).filter((g) => !('menuItem' in g.group));\n\n const sortedGroups = Object.values(groupsToInclude).sort(\n (a, b) => (a.group.order || 0) - (b.group.order || 0),\n );\n\n const itemArray: ItemInfo[] = [];\n\n sortedGroups.forEach((group) => {\n getOrderedGroupItems(group.id, menuDefinition.items).forEach((item) =>\n itemArray.push({ item, isLastItemInGroup: false }),\n );\n if (itemArray.length > 0) itemArray[itemArray.length - 1].isLastItemInGroup = true;\n });\n\n // No divider after last item in final group.\n if (itemArray.length > 0) itemArray[itemArray.length - 1].isLastItemInGroup = false;\n\n const allowSpaceForLeadingIcons = itemArray.some(\n (i) => 'iconPathBefore' in i.item && i.item.iconPathBefore,\n );\n\n return { items: itemArray, allowForLeadingIcons: allowSpaceForLeadingIcons };\n }, [includedGroups, menuDefinition]);\n\n // Create props for MenuItem component including setting hasDivider for the last item in a group\n const createMenuItemProps = ({ item, isLastItemInGroup }: ItemInfo) => {\n const menuItemProps = {\n className: 'papi-menu-item',\n label: item.label,\n tooltip: item.tooltip,\n iconPathBefore: 'iconPathBefore' in item ? item.iconPathBefore : undefined,\n iconPathAfter: 'iconPathAfter' in item ? item.iconPathAfter : undefined,\n hasDivider: isLastItemInGroup, // Set hasDivider to true for the last item in a group\n allowForLeadingIcons,\n };\n\n return menuItemProps;\n };\n\n const [firstItem] = items;\n\n if (!firstItem) return
    ;\n\n const divKey = firstItem.item.group;\n\n return (\n
    \n {items.map((itemInfo, index) => {\n const { item } = itemInfo;\n const menuItemProps = createMenuItemProps(itemInfo);\n if ('command' in item) {\n const key = item.group + index;\n return (\n ) => {\n onClick?.(event);\n commandHandler(item);\n }}\n {...menuItemProps}\n />\n );\n }\n return (\n \n );\n })}\n
    \n );\n}\n","import GroupedMenuItemList from '@/components/mui/grouped-menu-item-list.component';\nimport { MenuItemListProps } from '@/components/mui/menu-item.component';\nimport { MultiColumnMenu } from 'platform-bible-utils';\n\n/**\n * This component is internal; it does not need to be exposed to the outside world since it is not\n * useful on its own. Use either GridMenu or ContextMenu.\n */\nexport default function TopLevelMenu(props: MenuItemListProps) {\n const { menuDefinition, columnId } = props;\n\n const groupEntries = Object.entries(menuDefinition.groups);\n // Convert array of entries to array of objects with id and group properties\n const groups = groupEntries.map(([key, value]) => ({ id: key, group: value }));\n let includedGroups = groups.filter((g) => 'column' in g.group);\n\n // Check if column is provided and menuDefinition is a MultiColumnMenu\n if (\n columnId &&\n 'columns' in menuDefinition &&\n // Without this type assertion, TS doesn't know what columns is.\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n (menuDefinition as MultiColumnMenu).columns[columnId]\n ) {\n // When laying out a single column in a MultiColumnMenu, only include groups associated with\n // the provided column. Note: without the (annoying) redundant check that the included groups\n // have the colum field, TS doesn't think it exists.\n includedGroups = includedGroups.filter(\n (g) => 'column' in g.group && g.group.column === columnId,\n );\n }\n\n return ;\n}\n","import '@/components/mui/grid-menu.component.css';\nimport { GroupedMenuPropsBase } from '@/components/mui/grouped-menu-item-list.component';\nimport { CommandHandler } from '@/components/mui/menu-item.component';\nimport TopLevelMenu from '@/components/mui/top-level-menu.component';\nimport { Grid, List } from '@mui/material';\nimport {\n Localized,\n MenuColumnWithHeader,\n MultiColumnMenu,\n ReferencedItem,\n} from 'platform-bible-utils';\nimport { useMemo } from 'react';\n\ntype ColumnInfo = {\n /*\n * The ID (`${string}.${string}`) of a specific menu column.\n */\n id: ReferencedItem;\n\n /*\n * Metadata (label, order, etc.) for a specific menu column.\n */\n metadata: Localized;\n};\n\ntype MenuColumnProps = ColumnInfo &\n GroupedMenuPropsBase & {\n /** Additional css classes to help with unique styling of the menu column */\n className?: string;\n };\n\nexport type GridMenuInfo = {\n /** The menu object containing information about the columns, groups, and items to display. */\n multiColumnMenu: Localized;\n};\n\nexport type GridMenuProps = GridMenuInfo & {\n /** Optional unique identifier */\n id?: string;\n\n commandHandler: CommandHandler;\n\n /** Additional css classes to help with unique styling of the grid menu */\n className?: string;\n};\n\nfunction MenuColumn({\n commandHandler,\n menuDefinition,\n id,\n metadata,\n onClick,\n className,\n}: MenuColumnProps) {\n return (\n \n

    \n {metadata.label}\n

    \n {/* It would seem as though this List component were unnecessary, since it only contains one\n thing, but the \"dense\" property does affect the layout of the items (in a way I don't fully\n understand). There might be a better way. */}\n \n \n \n \n );\n}\n\nexport default function GridMenu({\n commandHandler,\n className,\n multiColumnMenu,\n id,\n}: GridMenuProps) {\n const { columns } = multiColumnMenu;\n\n const sortedColumns = useMemo(() => {\n const columnNumbers = new Map();\n Object.getOwnPropertyNames(columns).forEach((columnName: string) => {\n // We know for sure there is a (boolean) property 'isExtensible' that we are not interested in.\n if (columnName === 'isExtensible') return;\n // TS doesn't allow `columnName` above to be a ReferencedItem even though the type says it is\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const columnId = columnName as ReferencedItem;\n const column = columns[columnId];\n // As of right now (and hopefully forever after), all remaining properties of the\n // ColumnsWithHeaders object are columns whose property names are the IDs of the columns.\n // This is an additional (redundant) sanity check. Specifically we're interested in\n // MenuColumnWithHeader objects, which TypeScript now \"knows\" we have, but at runtime all we\n // can check for is that it's an object with a valid numeric order field. That's likely good\n // enough.\n if (\n typeof column === 'object' &&\n typeof column.order === 'number' &&\n !Number.isNaN(column.order)\n )\n columnNumbers.set(column.order, { id: columnId, metadata: column });\n else\n console.warn(\n `Property ${columnName} (${typeof column}) on menu ${id} is not a valid column and is being ignored. This might indicate data corruption`,\n );\n });\n\n // Extract values and sort them based on the 'order' property\n return Array.from(columnNumbers.values()).sort((a, b) => {\n return (a.metadata.order || 0) - (b.metadata.order || 0);\n });\n }, [columns, id]);\n\n // We might need something like this if we need to be able to prevent empty columns\n // sortedColumns.filter((c) => multiColumnMenu.groups.some((g) => 'column' in g && (g as .column)...\n\n return (\n \n {sortedColumns.map((col, index) => (\n \n ))}\n \n );\n}\n","import { useEffect, useRef, useState } from 'react';\n\nexport type UsePromiseOptions = {\n /**\n * Whether to leave the value as the most recent resolved promise value or set it back to\n * defaultValue while running the promise again. Defaults to true\n */\n preserveValue?: boolean;\n};\n\n/** Set up defaults for options for usePromise hook */\nfunction getUsePromiseOptionsDefaults(options: UsePromiseOptions): UsePromiseOptions {\n return {\n preserveValue: true,\n ...options,\n };\n}\n\n/**\n * Awaits a promise and returns a loading value while the promise is unresolved\n *\n * @param promiseFactoryCallback A function that returns the promise to await. If this callback is\n * undefined, the current value will be returned (defaultValue unless it was previously changed\n * and `options.preserveValue` is true), and there will be no loading.\n *\n * WARNING: MUST BE STABLE - const or wrapped in useCallback. The reference must not be updated\n * every render\n * @param defaultValue The initial value to return while first awaiting the promise. If\n * `options.preserveValue` is false, this value is also shown while awaiting the promise on\n * subsequent calls.\n *\n * Note: this parameter is internally assigned to a `ref`, so changing it will not cause any hooks\n * to re-run with its new value. This means that, if the `promiseFactoryCallback` changes and\n * `options.preserveValue` is `false`, the returned value will be set to the current\n * `defaultValue`. However, the returned value will not be updated if`defaultValue` changes.\n * @param options Various options for adjusting how this hook runs the `promiseFactoryCallback`\n *\n * Note: this parameter is internally assigned to a `ref`, so changing it will not cause any hooks\n * to re-run with its new value. However, the latest `options.preserveValue` will always be used\n * appropriately to determine whether to preserve the returned value when changing the\n * `promiseFactoryCallback`\n * @returns `[value, isLoading]`\n *\n * - `value`: the current value for the promise, either the defaultValue or the resolved promise value\n * - `isLoading`: whether the promise is waiting to be resolved\n */\nconst usePromise = (\n promiseFactoryCallback: (() => Promise) | undefined,\n defaultValue: T,\n options: UsePromiseOptions = {},\n): [value: T, isLoading: boolean] => {\n // Use defaultValue as a ref so it doesn't update dependency arrays\n const defaultValueRef = useRef(defaultValue);\n defaultValueRef.current = defaultValue;\n // Use options as a ref so it doesn't update dependency arrays\n const optionsDefaultedRef = useRef(options);\n optionsDefaultedRef.current = getUsePromiseOptionsDefaults(optionsDefaultedRef.current);\n\n const [value, setValue] = useState(() => defaultValueRef.current);\n const [isLoading, setIsLoading] = useState(true);\n useEffect(() => {\n let promiseIsCurrent = true;\n // If a promiseFactoryCallback was provided, we are loading. Otherwise, there is no loading to do\n setIsLoading(!!promiseFactoryCallback);\n (async () => {\n // If there is a callback to run, run it\n if (promiseFactoryCallback) {\n const result = await promiseFactoryCallback();\n // If the promise was not already replaced, update the value\n if (promiseIsCurrent) {\n setValue(() => result);\n setIsLoading(false);\n }\n }\n })();\n\n return () => {\n // Mark this promise as old and not to be used\n promiseIsCurrent = false;\n if (!optionsDefaultedRef.current.preserveValue) setValue(() => defaultValueRef.current);\n };\n }, [promiseFactoryCallback]);\n\n return [value, isLoading];\n};\nexport default usePromise;\n","\"use client\";\n\nimport createSvgIcon from './utils/createSvgIcon';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nexport default createSvgIcon( /*#__PURE__*/_jsx(\"path\", {\n d: \"M3 18h18v-2H3zm0-5h18v-2H3zm0-7v2h18V6z\"\n}), 'Menu');","import GridMenu from '@/components/mui/grid-menu.component';\nimport { Command, CommandHandler } from '@/components/mui/menu-item.component';\nimport usePromise from '@/hooks/use-promise.hook';\nimport { Menu as MenuIcon } from '@mui/icons-material';\nimport { Drawer, IconButton } from '@mui/material';\nimport { Localized, MultiColumnMenu } from 'platform-bible-utils';\nimport {\n MouseEvent,\n MutableRefObject,\n PropsWithChildren,\n useCallback,\n useEffect,\n useState,\n} from 'react';\n\nexport interface MultiColumnMenuProvider {\n (isSupportAndDevelopment: boolean): Promise>;\n}\n\nexport type HamburgerMenuButtonProps = PropsWithChildren & {\n /** The handler to use for menu commands (and eventually toolbar commands). */\n commandHandler: CommandHandler;\n\n /**\n * Optional reference to the \"div\" container that determines the where the menu should appear. If\n * not defined, then (1,1) used.\n */\n containerRef?: MutableRefObject;\n\n /**\n * The delegate to use to get the menu data. If not specified or if it returns undefined, the data\n * in normalMenu or fullMenu property will be used.\n */\n menuProvider?: MultiColumnMenuProvider;\n\n /**\n * The menu data to show when the menu is opened if the menuProvider property is not defined.\n * (This allows for a default or test-only static menu to be used.)\n */\n normalMenu?: Localized;\n\n /**\n * The menu data to show for \"full\" menu (when opened with the SHIFT key pressed) if the\n * menuProvider property is not defined. (This allows for a default or test-only static menu to be\n * used.)\n */\n fullMenu?: Localized;\n\n /** Additional css class(es) to help with unique styling of the sub-components */\n className?: string;\n\n /** Value to use as prefix for ARIA labels on interactive sub-components */\n ariaLabelPrefix?: string;\n};\n\nexport default function HamburgerMenuButton({\n menuProvider,\n normalMenu,\n fullMenu,\n commandHandler,\n containerRef,\n className,\n ariaLabelPrefix,\n children,\n}: HamburgerMenuButtonProps) {\n const [isMenuOpen, setMenuOpen] = useState(false);\n const [showFullMenu, setShowFullMenu] = useState(false);\n\n const handleMenuItemClick = useCallback(() => {\n if (isMenuOpen) setMenuOpen(false);\n setShowFullMenu(false);\n }, [isMenuOpen]);\n\n const handleMenuButtonClick = useCallback((e: MouseEvent) => {\n e.stopPropagation();\n setMenuOpen((prevIsOpen) => {\n const isOpening = !prevIsOpen;\n if (isOpening && e.shiftKey) setShowFullMenu(true);\n else if (!isOpening) setShowFullMenu(false);\n return isOpening;\n });\n }, []);\n\n const menuCommandHandler = useCallback(\n (command: Command) => {\n handleMenuItemClick();\n return commandHandler(command);\n },\n [commandHandler, handleMenuItemClick],\n );\n\n const [offset, setOffset] = useState({ top: 1, left: 1 });\n\n useEffect(() => {\n if (isMenuOpen) {\n const node = containerRef?.current;\n if (node) {\n const rect = node.getBoundingClientRect();\n const scrollTop = window.scrollY;\n const scrollLeft = window.scrollX;\n const top = rect.top + scrollTop + node.clientHeight;\n const left = rect.left + scrollLeft;\n setOffset({ top, left });\n }\n }\n }, [isMenuOpen, containerRef]);\n\n const [normalMenuData] = usePromise(\n useCallback(async () => {\n return menuProvider?.(false) ?? normalMenu;\n // isMenuOpen needs to be included for the menu contents to reevaluate when reopened\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [menuProvider, normalMenu, isMenuOpen]),\n normalMenu,\n );\n\n const [fullMenuData] = usePromise(\n useCallback(async () => {\n return menuProvider?.(true) ?? fullMenu ?? normalMenuData;\n // isMenuOpen needs to be included for the menu contents to reevaluate when reopened\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [menuProvider, fullMenu, normalMenuData, isMenuOpen]),\n fullMenu ?? normalMenuData,\n );\n\n const menu = showFullMenu && fullMenuData ? fullMenuData : normalMenuData;\n\n return (\n <>\n \n {children ?? }\n \n \n {menu ? (\n \n ) : undefined}\n \n \n );\n}\n","import '@/components/mui/icon-button.component.css';\nimport { IconButton as MuiIconButton } from '@mui/material';\nimport { MouseEventHandler, PropsWithChildren } from 'react';\n\nexport type IconButtonProps = PropsWithChildren<{\n /** Optional unique identifier */\n id?: string;\n /**\n * Required. Used as both the tooltip (aka, title) and the aria-label (used for accessibility,\n * testing, etc.), unless a distinct tooltip is supplied.\n */\n label: string;\n /**\n * Enabled status of button\n *\n * @default false\n */\n isDisabled?: boolean;\n /** Optional tooltip to display if different from the aria-label. */\n tooltip?: string;\n /** If true, no tooltip will be displayed. */\n isTooltipSuppressed?: boolean;\n /**\n * If given, uses a negative margin to counteract the padding on one side (this is often helpful\n * for aligning the left or right side of the icon with content above or below, without ruining\n * the border size and shape).\n *\n * @default false\n */\n adjustMarginToAlignToEdge?: 'end' | 'start' | false;\n /**\n * The size of the component. small is equivalent to the dense button styling.\n *\n * @default false\n */\n size: 'small' | 'medium' | 'large';\n /** Additional css classes to help with unique styling of the button */\n className?: string;\n /** Optional click handler */\n onClick?: MouseEventHandler;\n}>;\n\n/**\n * Iconic button a user can click to do something\n *\n * Thanks to MUI for heavy inspiration and documentation\n * https://mui.com/material-ui/getting-started/overview/\n */\nfunction IconButton({\n id,\n label,\n isDisabled = false,\n tooltip,\n isTooltipSuppressed = false,\n adjustMarginToAlignToEdge = false,\n size = 'medium',\n className,\n onClick,\n children,\n}: IconButtonProps) {\n return (\n \n {children /* the icon to display */}\n \n );\n}\n\nexport default IconButton;\n","import { cn } from '@/utils/shadcn-ui.util';\nimport { LoaderCircle, LucideProps } from 'lucide-react';\nimport { forwardRef } from 'react';\n\nexport type SpinnerProps = LucideProps;\n\nconst Spinner = forwardRef(({ className, ...props }, ref) => {\n return (\n \n );\n});\n\nSpinner.displayName = 'Spinner';\n\nexport default Spinner;\n","import { Input as ShadInput } from '@/components/shadcn-ui/input';\nimport { Label as ShadLabel } from '@/components/shadcn-ui/label';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { ChangeEventHandler, FocusEventHandler } from 'react';\n\nexport type TextFieldProps = {\n /** Optional unique identifier */\n id?: string;\n /**\n * If `true`, the component is disabled.\n *\n * @default false\n */\n isDisabled?: boolean;\n /**\n * If `true`, the label is displayed in an error state.\n *\n * @default false\n */\n hasError?: boolean;\n /**\n * If `true`, the input will take up the full width of its container.\n *\n * @default false\n */\n isFullWidth?: boolean;\n /** Text that gives the user instructions on what contents the TextField expects */\n helperText?: string;\n /** The title of the TextField */\n label?: string;\n /** The short hint displayed in the `input` before the user enters a value. */\n placeholder?: string;\n /**\n * If `true`, the label is displayed as required and the `input` element is required.\n *\n * @default false\n */\n isRequired?: boolean;\n /** Additional css classes to help with unique styling of the text field */\n className?: string;\n /** Starting value for the text field if it is not controlled */\n defaultValue?: string | number;\n /** Value of the text field if controlled */\n value?: string | number;\n /** Triggers when content of textfield is changed */\n onChange?: ChangeEventHandler;\n /** Triggers when textfield gets focus */\n onFocus?: FocusEventHandler;\n /** Triggers when textfield loses focus */\n onBlur?: FocusEventHandler;\n};\n\n/**\n * Text input field\n *\n * Thanks to Shadcn for heavy inspiration and documentation\n * https://ui.shadcn.com/docs/components/input#with-label\n */\nfunction TextField({\n id,\n isDisabled = false,\n hasError = false,\n isFullWidth = false,\n helperText,\n label,\n placeholder,\n isRequired = false,\n className,\n defaultValue,\n value,\n onChange,\n onFocus,\n onBlur,\n}: TextFieldProps) {\n return (\n
    \n {`${label}${isRequired ? '*' : ''}`}\n \n

    {helperText}

    \n
    \n );\n}\n\nexport default TextField;\n","import HamburgerMenuButton, {\n MultiColumnMenuProvider,\n} from '@/components/mui/hamburger-menu-button.component';\nimport { CommandHandler } from '@/components/mui/menu-item.component';\nimport '@/components/mui/toolbar.component.css';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { AppBar, Toolbar as MuiToolbar } from '@mui/material';\nimport { PropsWithChildren, useRef } from 'react';\n\nexport type ToolbarProps = PropsWithChildren<{\n /** The handler to use for menu commands (and eventually toolbar commands). */\n commandHandler: CommandHandler;\n\n /**\n * The optional delegate to use to get the menu data. If not specified, the \"hamburger\" menu will\n * not display.\n */\n menuProvider?: MultiColumnMenuProvider;\n\n /** Optional unique identifier */\n id?: string;\n\n /** Additional css classes to help with unique styling of the toolbar */\n className?: string;\n}>;\n\nexport default function Toolbar({\n menuProvider,\n commandHandler,\n className,\n id,\n children,\n}: ToolbarProps) {\n // This ref will always be defined\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const containerRef = useRef(undefined!);\n\n return (\n
    \n \n \n {menuProvider ? (\n \n ) : undefined}\n {children ?
    {children}
    : undefined}\n \n
    \n
    \n );\n}\n","import React from 'react';\nimport { cva, type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst alertVariants = cva(\n 'tw-relative tw-w-full tw-rounded-lg tw-border tw-p-4 [&>svg~*]:tw-pl-7 [&>svg+div]:tw-translate-y-[-3px] [&>svg]:tw-absolute [&>svg]:tw-left-4 [&>svg]:tw-top-4 [&>svg]:tw-text-foreground',\n {\n variants: {\n variant: {\n default: 'tw-bg-background tw-text-foreground',\n destructive:\n 'tw-border-destructive/50 tw-text-destructive dark:tw-border-destructive [&>svg]:tw-text-destructive',\n },\n },\n defaultVariants: {\n variant: 'default',\n },\n },\n);\n\nconst Alert = React.forwardRef<\n HTMLDivElement,\n React.HTMLAttributes & VariantProps\n>(({ className, variant, ...props }, ref) => (\n
    \n));\nAlert.displayName = 'Alert';\n\nconst AlertTitle = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n {/* added because of https://github.com/jsx-eslint/eslint-plugin-jsx-a11y/blob/main/docs/rules/heading-has-content.md */}\n {props.children}{' '}\n \n ),\n);\nAlertTitle.displayName = 'AlertTitle';\n\nconst AlertDescription = React.forwardRef<\n HTMLParagraphElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n
    \n));\nAlertDescription.displayName = 'AlertDescription';\n\nexport { Alert, AlertTitle, AlertDescription };\n","import React from 'react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Card = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nCard.displayName = 'Card';\n\nconst CardHeader = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nCardHeader.displayName = 'CardHeader';\n\nconst CardTitle = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n {/* added because of https://github.com/jsx-eslint/eslint-plugin-jsx-a11y/blob/main/docs/rules/heading-has-content.md */}\n {props.children}\n \n ),\n);\nCardTitle.displayName = 'CardTitle';\n\nconst CardDescription = React.forwardRef<\n HTMLParagraphElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n

    \n));\nCardDescription.displayName = 'CardDescription';\n\nconst CardContent = React.forwardRef>(\n ({ className, ...props }, ref) => (\n

    \n ),\n);\nCardContent.displayName = 'CardContent';\n\nconst CardFooter = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nCardFooter.displayName = 'CardFooter';\n\nexport { Card, CardHeader, CardFooter, CardTitle, CardDescription, CardContent };\n","import { ComponentProps } from 'react';\nimport { toast as sonner, Toaster } from 'sonner';\n\ntype SonnerProps = ComponentProps;\n\nfunction Sonner({ ...props }: SonnerProps) {\n return (\n \n );\n}\n\n// The re-export of the sonner function was added manually\nexport { Sonner, sonner };\n","import React from 'react';\nimport * as SliderPrimitive from '@radix-ui/react-slider';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Slider = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n \n \n \n));\nSlider.displayName = SliderPrimitive.Root.displayName;\n\nexport { Slider };\n","import React from 'react';\nimport * as SwitchPrimitives from '@radix-ui/react-switch';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Switch = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n));\nSwitch.displayName = SwitchPrimitives.Root.displayName;\n\nexport { Switch };\n","import React from 'react';\nimport * as TabsPrimitive from '@radix-ui/react-tabs';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport const Tabs = TabsPrimitive.Root;\n\nexport type TabsListProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport type TabsTriggerProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport type TabsContentProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport const TabsList = React.forwardRef<\n React.ElementRef,\n TabsListProps\n>(({ className, ...props }, ref) => (\n \n));\nTabsList.displayName = TabsPrimitive.List.displayName;\n\nexport const TabsTrigger = React.forwardRef<\n React.ElementRef,\n TabsTriggerProps\n>(({ className, ...props }, ref) => (\n \n));\nTabsTrigger.displayName = TabsPrimitive.Trigger.displayName;\n\nexport const TabsContent = React.forwardRef<\n React.ElementRef,\n TabsContentProps\n>(({ className, ...props }, ref) => (\n \n));\nTabsContent.displayName = TabsPrimitive.Content.displayName;\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Download } from 'lucide-react';\n\ntype InstallButtonProps = {\n /** The installing boolean value determines the state of the button. */\n isInstalling: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n /** Optional text for the button. */\n buttonText?: string;\n} & ButtonProps;\n\n/**\n * The InstallButton component is a button designed for initiating installs. It includes visuals for\n * active installing and idle states.\n *\n * @param isInstalling The installing boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @param buttonText Optional text for the button.\n * @returns A install button.\n */\nexport default function InstallButton({\n isInstalling,\n handleClick,\n buttonText,\n className,\n ...props\n}: InstallButtonProps) {\n return (\n \n {isInstalling ? (\n \n ) : (\n <>\n \n {buttonText}\n \n )}\n \n );\n}\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\n\ntype EnableButtonProps = {\n /** The enabling boolean value determines the state of the button. */\n isEnabling: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n} & ButtonProps;\n\n/**\n * The EnableButton component is a button designed for initiating enabling of downloads. It includes\n * visuals for active enabling and idle states.\n *\n * @param isEnabling The enabling boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @returns A button that can be used to enable.\n */\nexport default function EnableButton({\n isEnabling,\n handleClick,\n className,\n ...props\n}: EnableButtonProps) {\n return (\n \n {isEnabling ? (\n <>\n \n Enabling...\n \n ) : (\n 'Enable'\n )}\n \n );\n}\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\n\ntype DisableButtonProps = {\n /** The disabling boolean value determines the state of the button. */\n isDisabling: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n} & ButtonProps;\n\n/**\n * The DisableButton component is a button designed for initiating disabling of downloads. It\n * includes visuals for active disabling and idle states.\n *\n * @param isDisabling The disabling boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @returns A button that can be used to disable.\n */\nexport default function DisableButton({\n isDisabling,\n handleClick,\n className,\n ...props\n}: DisableButtonProps) {\n return (\n \n {isDisabling ? (\n <>\n \n Disabling...\n \n ) : (\n 'Disable'\n )}\n \n );\n}\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\n\ntype UpdateButtonProps = {\n /** The updating boolean value determines the state of the button. */\n isUpdating: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n} & ButtonProps;\n\n/**\n * The UpdateButton component is a button designed for initiating updates for downloaded extensions.\n * It includes visuals for active updating and idle states.\n *\n * @param isUpdating The updating boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @returns A button that can be used to update.\n */\nexport default function UpdateButton({\n isUpdating,\n handleClick,\n className,\n ...props\n}: UpdateButtonProps) {\n return (\n \n {isUpdating ? (\n <>\n \n Updating...\n \n ) : (\n 'Update'\n )}\n \n );\n}\n","import { cn } from '@/utils/shadcn-ui.util';\nimport Markdown, { MarkdownToJSX } from 'markdown-to-jsx';\nimport { useMemo } from 'react';\n\ninterface MarkdownRendererProps {\n /** Optional unique identifier */\n id?: string;\n /** The markdown string to render */\n markdown: string;\n className?: string;\n /**\n * The [`target` attribute for `a` html\n * tags](https://developer.mozilla.org/en-US/docs/Web/HTML/Element/a#target). Defaults to not\n * adding a `target` to `a` tags\n */\n anchorTarget?: string;\n}\n\n/**\n * This component renders markdown content given a markdown string. It uses typography styles from\n * the platform.\n *\n * @param markdown The markdown string to render.\n * @param id Optional unique identifier\n * @returns A div containing the rendered markdown content.\n */\nexport default function MarkdownRenderer({\n id,\n markdown,\n className,\n anchorTarget,\n}: MarkdownRendererProps) {\n const options: MarkdownToJSX.Options = useMemo(\n () => ({\n overrides: {\n a: {\n props: {\n target: anchorTarget,\n },\n },\n },\n }),\n [anchorTarget],\n );\n return (\n
    \n {markdown}\n
    \n );\n}\n","import { Filter, ChevronDown } from 'lucide-react';\nimport { forwardRef } from 'react';\nimport { Button } from '@/components/shadcn-ui/button';\n\n/**\n * The FilterButton component is a button designed for initiating filtering of data. It is designed\n * to be used with the dropdown menu. It uses forwardRef to pass the button to the dropdown trigger\n * asChild.\n *\n * @returns A button that can be used to filter.\n */\nconst FilterButton = forwardRef((props, ref) => {\n return (\n \n \n Filter\n \n \n );\n});\n\nexport default FilterButton;\n","import {\n DropdownMenu,\n DropdownMenuTrigger,\n DropdownMenuContent,\n DropdownMenuLabel,\n DropdownMenuGroup,\n DropdownMenuCheckboxItem,\n DropdownMenuRadioItem,\n DropdownMenuSeparator,\n} from '@/components/shadcn-ui/dropdown-menu';\nimport FilterButton from './buttons/filter-button.component';\n\nexport enum DropdownMenuItemType {\n Check,\n Radio,\n}\n\nexport type DropdownItem = {\n /** The label is the text that will be displayed on the dropdown item. */\n label: string;\n /** The itemType determines the DropdownMenuItemType type as either Check or Radio. */\n itemType: DropdownMenuItemType;\n /** The onClick function is called when the item is clicked. */\n onClick: () => void;\n};\n\nexport type DropdownGroup = {\n /**\n * The label is the text that will be displayed on the dropdown group. It is used to categorize\n * the items in the group.\n */\n label: string;\n /** The items array contains the items that will be displayed in the dropdown group */\n items: DropdownItem[];\n};\n\nexport type FilterDropdownProps = {\n /** Object unique identifier */\n id?: string;\n /** The groups array contains the groups that will be displayed in the dropdown */\n groups: DropdownGroup[];\n}; // TODO: extend the props later\n\n/**\n * The FilterDropdown component is a dropdown designed for filtering content. It includes groups of\n * items that can be checkboxes or radio items.\n *\n * @param id Optional unique identifier\n * @param groups The groups array contains the groups that will be displayed in the dropdown\n * @returns A filter dropdown.\n */\nexport default function FilterDropdown({ id, groups }: FilterDropdownProps) {\n return (\n
    \n {/* TODO: remove this once the DropDown Menu shadcn has an id prop */}\n \n \n \n \n \n {groups.map((group) => (\n
    \n {group.label}\n \n {group.items.map((item) => (\n
    \n {item.itemType === DropdownMenuItemType.Check ? (\n \n {item.label}\n \n ) : (\n \n {item.label}\n \n )}\n
    \n ))}\n
    \n \n
    \n ))}\n
    \n
    \n
    \n );\n}\n","interface NoExtensionsFoundProps {\n /** Optional unique identifier */\n id?: string;\n /** The message to display */\n message: string;\n}\n/**\n * This component displays a message to the user when no extensions are found in the marketplace.\n *\n * @param id Optional unique identifier\n * @param message The message to display.\n * @returns {JSX.Element} - Returns the message component that displays the message to the user.\n */\nexport default function NoExtensionsFound({ id, message }: NoExtensionsFoundProps) {\n return (\n
    \n
    \n

    {message}

    \n
    \n
    \n );\n}\n","import { CircleHelp, Link as LucideLink, User } from 'lucide-react';\nimport { NumberFormat } from 'platform-bible-utils';\n\n/** Interface that stores the parameters passed to the More Info component */\ninterface MoreInfoProps {\n /** Optional unique identifier */\n id?: string;\n /** The category of the extension */\n category: string;\n /** The number of downloads for the extension */\n downloads: Record;\n /** The languages supported by the extension */\n languages: string[];\n /** The URL to the more info page of the extension */\n moreInfoUrl: string;\n}\n/**\n * This component displays the more info section of the extension which includes the category,\n * number of downloads, languages, and links to the website and support\n *\n * @param id Optional unique identifier\n * @param category The category of the extension\n * @param downloads The number of downloads for the extension\n * @param languages The languages supported by the extension\n * @param moreInfoUrl The URL to the more info page of the extension\n * @returns {JSX.Element} - Returns the more info component that displays the category, number of\n * downloads, languages, and links to the website and support\n */\nexport default function MoreInfo({\n id,\n category,\n downloads,\n languages,\n moreInfoUrl,\n}: MoreInfoProps) {\n /**\n * This constant formats the number of downloads into a more readable format.\n *\n * @example 1000 -> 1K\n *\n * @example 1000000 -> 1M\n *\n * @returns The formatted number of downloads\n */\n const numberFormatted = new NumberFormat('en', {\n notation: 'compact',\n compactDisplay: 'short',\n }).format(Object.values(downloads).reduce((a: number, b: number) => a + b, 0));\n\n /** This function scrolls the window to the bottom of the page. */\n const handleScrollToBottom = () => {\n window.scrollTo(0, document.body.scrollHeight);\n };\n\n return (\n \n
    \n
    \n {category}\n
    \n CATEGORY\n
    \n
    \n
    \n
    \n \n {numberFormatted}\n
    \n USERS\n
    \n
    \n
    \n
    \n {languages.slice(0, 3).map((locale) => (\n \n {locale.toUpperCase()}\n \n ))}\n
    \n {languages.length > 3 && (\n handleScrollToBottom()}\n className=\"tw-text-xs tw-text-gray-500 tw-underline\"\n >\n +{languages.length - 3} more languages\n \n )}\n
    \n
    \n
    \n \n Website\n \n \n \n Support\n \n \n
    \n
    \n );\n}\n","import { useState } from 'react';\n\nexport type VersionInformation = {\n /** Date the version was published */\n date: string;\n /** Description of the changes in the version */\n description: string;\n};\n\n/** Type to store the version history information */\nexport type VersionHistoryType = Record;\n\n/** Interface that stores the parameters passed to the Version History component */\ninterface VersionHistoryProps {\n /** Optional unique identifier */\n id?: string;\n /** Object containing the versions mapped with their information */\n versionHistory: VersionHistoryType;\n}\n\n/**\n * Component to render the version history information shown in the footer component. Lists the 5\n * most recent versions, with the options to show all versions by pressing a button.\n *\n * @param versionHistory Object containing the versions mapped with their information\n * @param id Optional unique identifier\n * @returns Rendered version history for the Footer component\n */\nexport default function VersionHistory({ id, versionHistory }: VersionHistoryProps) {\n const [showAllVersions, setShowAllVersions] = useState(false);\n const currentDate = new Date();\n\n /**\n * Function to format the time string for the version history in the form of 'X year(s) ago'.\n *\n * @param dateString ISO Date string to determine the time string from\n * @returns Formatted time string\n */\n function formatTimeString(dateString: string) {\n const date = new Date(dateString);\n const dateDiff = new Date(currentDate.getTime() - date.getTime());\n const yearDiff = dateDiff.getUTCFullYear() - 1970;\n const monthDiff = dateDiff.getUTCMonth();\n const dayDiff = dateDiff.getUTCDate() - 1;\n\n // Determines how long ago the version was published\n let timeString = '';\n if (yearDiff > 0) {\n timeString = `${yearDiff.toString()} year${yearDiff === 1 ? '' : 's'} ago`;\n } else if (monthDiff > 0) {\n timeString = `${monthDiff.toString()} month${monthDiff === 1 ? '' : 's'} ago`;\n } else if (dayDiff === 0) {\n timeString = 'today';\n } else {\n timeString = `${dayDiff.toString()} day${dayDiff === 1 ? '' : 's'} ago`;\n }\n\n return timeString;\n }\n\n // Sorts the version history by version number\n const sortedEntries = Object.entries(versionHistory).sort((a, b) => b[0].localeCompare(a[0]));\n\n return (\n
    \n

    What`s New

    \n
      \n {(showAllVersions ? sortedEntries : sortedEntries.slice(0, 5)).map((entry) => (\n
      \n
      \n
    • \n {entry[1].description}\n
    • \n
      \n
      \n
      Version {entry[0]}
      \n
      {formatTimeString(entry[1].date)}
      \n
      \n
      \n ))}\n
    \n {sortedEntries.length > 5 && (\n setShowAllVersions(!showAllVersions)}\n className=\"tw-text-xs tw-text-gray-500 tw-underline\"\n >\n {showAllVersions ? 'Show Less Version History' : 'Show All Version History'}\n \n )}\n
    \n );\n}\n","import { useMemo } from 'react';\nimport { formatBytes } from 'platform-bible-utils';\nimport VersionHistory, { VersionHistoryType } from './version-history.component';\n\n/** Interface to store the parameters passed to the Footer component */\ninterface FooterProps {\n /** Optional unique identifier */\n id?: string;\n /** Name of the publisher */\n publisherDisplayName: string;\n /** Size of the extension file in bytes */\n fileSize: number;\n /** List of language codes supported by the extension */\n locales: string[];\n /** Object containing the version history mapped with their information */\n versionHistory: VersionHistoryType;\n}\n\n/**\n * Component to render the footer for the extension details which contains information on the\n * publisher, version history, languages, and file size.\n *\n * @param id Optional unique identifier\n * @param publisherDisplayName Name of the publisher\n * @param fileSize Size of the extension file in bytes\n * @param locales List of language codes supported by the extension\n * @param versionHistory Object containing the version history mapped with their information\n * @returns The rendered Footer component\n */\nexport default function Footer({\n id,\n publisherDisplayName,\n fileSize,\n locales,\n versionHistory,\n}: FooterProps) {\n /** Formats the file size into a human-readable format */\n const formattedFileSize = useMemo(() => formatBytes(fileSize), [fileSize]);\n\n /**\n * This function gets the display names of the languages based on the language codes.\n *\n * @param codes The list of language codes\n * @returns The list of language names\n */\n const getLanguageNames = (codes: string[]) => {\n const displayNames = new Intl.DisplayNames(navigator.language, { type: 'language' });\n return codes.map((code) => displayNames.of(code));\n };\n\n const languageNames = getLanguageNames(locales);\n\n return (\n
    \n
    \n \n
    \n
    \n

    Information

    \n
    \n

    \n Publisher\n {publisherDisplayName}\n Size\n {formattedFileSize}\n

    \n
    \n

    \n Languages\n {languageNames.join(', ')}\n

    \n
    \n
    \n
    \n
    \n
    \n );\n}\n","import { PlatformEvent, PlatformEventHandler } from 'platform-bible-utils';\nimport { useEffect } from 'react';\n\n/**\n * Adds an event handler to an event so the event handler runs when the event is emitted. Use\n * `papi.network.getNetworkEvent` to use a networked event with this hook.\n *\n * @param event The event to subscribe to.\n *\n * - If event is a `PlatformEvent`, that event will be used\n * - If event is undefined, the callback will not be subscribed. Useful if the event is not yet\n * available for example\n *\n * @param eventHandler The callback to run when the event is emitted\n *\n * WARNING: MUST BE STABLE - const or wrapped in useCallback. The reference must not be updated\n * every render\n */\nconst useEvent = (\n event: PlatformEvent | undefined,\n eventHandler: PlatformEventHandler,\n) => {\n useEffect(() => {\n // Do nothing if the event is not provided (in case the event is not yet available, for example)\n if (!event) return () => {};\n\n const unsubscriber = event(eventHandler);\n return () => {\n unsubscriber();\n };\n }, [event, eventHandler]);\n};\nexport default useEvent;\n","import { useCallback, useEffect } from 'react';\nimport { PlatformEvent, PlatformEventAsync, PlatformEventHandler } from 'platform-bible-utils';\nimport usePromise from './use-promise.hook';\n\nconst noopUnsubscriber = () => false;\n\n/**\n * Adds an event handler to an asynchronously subscribing/unsubscribing event so the event handler\n * runs when the event is emitted. Use `papi.network.getNetworkEvent` to use a networked event with\n * this hook.\n *\n * @param event The asynchronously (un)subscribing event to subscribe to.\n *\n * - If event is a `PlatformEvent` or `PlatformEventAsync`, that event will be used\n * - If event is undefined, the callback will not be subscribed. Useful if the event is not yet\n * available for example\n *\n * @param eventHandler The callback to run when the event is emitted\n *\n * WARNING: MUST BE STABLE - const or wrapped in useCallback. The reference must not be updated\n * every render\n */\nconst useEventAsync = (\n event: PlatformEvent | PlatformEventAsync | undefined,\n eventHandler: PlatformEventHandler,\n) => {\n // Subscribe to the event asynchronously\n const [unsubscribe] = usePromise(\n useCallback(async () => {\n // Do nothing if the event is not provided (in case the event is not yet available, for example)\n if (!event) return noopUnsubscriber;\n\n // Wrap subscribe and unsubscribe in promises to allow normal events to be used as well\n const unsub = await Promise.resolve(event(eventHandler));\n return async () => unsub();\n }, [eventHandler, event]),\n noopUnsubscriber,\n // We want the unsubscriber to return to default value immediately upon changing subscription\n // So the useEffect below will unsubscribe asap\n { preserveValue: false },\n );\n\n // Unsubscribe from the event asynchronously (but we aren't awaiting the unsub)\n useEffect(() => {\n return () => {\n if (unsubscribe !== noopUnsubscriber) {\n unsubscribe();\n }\n };\n }, [unsubscribe]);\n};\n\nexport default useEventAsync;\n"],"names":["twMergeCustom","extendTailwindMerge","cn","inputs","clsx","Input","React","className","type","props","ref","jsx","BookChapterInput","forwardRef","handleSearch","handleKeyDown","handleOnClick","handleSubmit","jsxs","ShadInput","event","e","History","P","R","t","s","n","N","B","O","S","K","g","k","x","T","X","V","w","L","G","A","H","C","I","y","q","U","m","l","h","c","E","D","i","a","o","u","v","f","d","b","p","J","DropdownMenu","DropdownMenuPrimitive","DropdownMenuTrigger","DropdownMenuGroup","DropdownMenuPortal","DropdownMenuSub","DropdownMenuRadioGroup","DropdownMenuSubTrigger","inset","children","ChevronRight","DropdownMenuSubContent","DropdownMenuContent","sideOffset","DropdownMenuItem","DropdownMenuCheckboxItem","checked","Check","DropdownMenuRadioItem","Circle","DropdownMenuLabel","DropdownMenuSeparator","DropdownMenuShortcut","BookMenuItem","bookId","handleSelectBook","isSelected","handleHighlightBook","bookType","ShadDropdownMenuItem","Canon","ChapterSelect","handleSelectChapter","endChapter","activeChapter","highlightedChapter","handleHighlightedChapter","chapters","_","handleMouse","useCallback","chapterNumber","chapter","GoToMenuItem","handleSort","handleLocationHistory","handleBookmarks","ShadDropdownMenuLabel","ArrowDownWideNarrow","Clock","Bookmark","ALL_BOOK_IDS","BOOK_TYPE_LABELS","BOOK_TYPE_ARRAY","SCROLL_OFFSET","SEARCH_QUERY_FORMATS","fetchGroupedBooks","fetchEndChapter","getChaptersForBook","getAllEnglishNames","isValidBookEnglishName","bookName","getBookIdFromEnglishName","formattedBookName","BookChapterControl","scrRef","searchQuery","setSearchQuery","useState","selectedBookId","setSelectedBookId","setHighlightedChapter","highlightedBookId","setHighlightedBookId","isContentOpen","setIsContentOpen","isContentOpenDelayed","setIsContentOpenDelayed","inputRef","useRef","contentRef","menuItemRef","fetchFilteredBooks","englishNameLowerCase","normalizedQuery","handleSearchInput","searchString","shouldPreventAutoClosing","controlMenuState","open","updateReference","shouldClose","verse","handleInputSubmit","format","matches","book","englishName","handleKeyDownInput","handleKeyDownContent","key","handleKeyDownMenuItem","chapterOffSet","useEffect","useLayoutEffect","scrollTimeout","scrollPosition","ShadDropdownMenu","ShadDropdownMenuTrigger","ShadDropdownMenuContent","bookTypeIndex","element","ShadDropdownMenuSeparator","buttonVariants","cva","Button","variant","size","asChild","Comp","Slot","labelVariants","Label","LabelPrimitive","RadioGroup","RadioGroupPrimitive","RadioGroupItem","Popover","PopoverPrimitive","PopoverTrigger","PopoverContent","align","DialogPortal","DialogPrimitive","DialogOverlay","DialogContent","DialogTitle","DialogDescription","Command","CommandPrimitive","CommandInput","Search","CommandList","CommandEmpty","CommandGroup","CommandSeparator","CommandItem","getOptionLabelDefault","option","ComboBox","id","options","buttonClassName","popoverContentClassName","value","onChange","getOptionLabel","buttonPlaceholder","textPlaceholder","commandEmptyMessage","buttonVariant","dir","isDisabled","setOpen","ChevronsUpDown","ChapterRangeSelector","startChapter","handleSelectStartChapter","handleSelectEndChapter","chapterCount","chapterOptions","useMemo","index","onChangeStartChapter","onChangeEndChapter","Fragment","BookSelectionMode","BOOK_SELECTOR_STRING_KEYS","localizeString","strings","BookSelector","handleBookSelectionModeChange","currentBookName","onSelectBooks","selectedBookIds","localizedStrings","currentBookText","chooseText","chooseBooksText","bookSelectionMode","setBookSelectionMode","onSelectionModeChange","newMode","DataTableViewOptions","table","FilterIcon","column","Select","SelectPrimitive","SelectGroup","SelectValue","SelectTrigger","ChevronDown","SelectScrollUpButton","ChevronUp","SelectScrollDownButton","SelectContent","position","SelectLabel","SelectItem","SelectSeparator","DataTablePagination","pageSize","ArrowLeftIcon","ChevronLeftIcon","ChevronRightIcon","ArrowRightIcon","Table","stickyHeader","TableHeader","TableBody","TableFooter","TableRow","TableHead","TableCell","TableCaption","DataTable","columns","data","enablePagination","showPaginationControls","showColumnVisibilityControls","onRowClickHandler","sorting","setSorting","columnFilters","setColumnFilters","columnVisibility","setColumnVisibility","rowSelection","setRowSelection","useReactTable","getCoreRowModel","getPaginationRowModel","getSortedRowModel","getFilteredRowModel","headerGroup","header","flexRender","_a","row","cell","OccurrencesTable","occurrenceData","setScriptureReference","referenceHeaderText","occurrenceHeaderText","occurrences","uniqueOccurrences","occurrence","uniqueOccurrence","deepEqual","Checkbox","CheckboxPrimitive","getLinesFromUSFM","text","getNumberFromUSFM","regex","match","getBookNumFromId","getStatusForItem","item","approvedItems","unapprovedItems","toggleVariants","Toggle","TogglePrimitive","ToggleGroupContext","ToggleGroup","ToggleGroupPrimitive","ToggleGroupItem","context","getSortingIcon","sortDirection","ArrowUpIcon","ArrowDownIcon","ArrowUpDownIcon","inventoryItemColumn","itemLabel","inventoryAdditionalItemColumn","additionalItemLabel","additionalItemIndex","inventoryCountColumn","countLabel","statusChangeHandler","changedItems","newStatus","onApprovedItemsChange","onUnapprovedItemsChange","newApprovedItems","validItem","newUnapprovedItems","unapprovedItem","inventoryStatusColumn","statusLabel","status","CircleCheckIcon","CircleXIcon","CircleHelpIcon","INVENTORY_STRING_KEYS","filterItemData","itemData","statusFilter","textFilter","filteredItemData","createTableData","scriptureRef","itemRegex","tableData","currentBook","currentChapter","currentVerse","line","items","itemIndex","existingItem","tableEntry","newReference","substring","newItem","Inventory","scriptureReference","extractItems","additionalItemsLabels","scope","onScopeChange","allItemsText","approvedItemsText","unapprovedItemsText","unknownItemsText","scopeBookText","scopeChapterText","scopeVerseText","filterText","showAdditionalItemsText","showAdditionalItems","setShowAdditionalItems","setStatusFilter","setTextFilter","selectedItem","setSelectedItem","reducedTableData","newTableData","firstItem","existingEntry","newTableEntry","filteredTableData","allColumns","numberOfAdditionalItems","additionalColumns","_b","rowClickHandler","newSelection","handleScopeChange","handleStatusFilterChange","SearchBar","onSearch","placeholder","isFullWidth","handleInputChange","VerticalTabs","TabsPrimitive","VerticalTabsList","VerticalTabsTrigger","VerticalTabsContent","TabNavigationContentSearch","tabList","searchPlaceholder","headerTitle","isSearchBarFullWidth","direction","tab","Separator","orientation","decorative","SeparatorPrimitive","Skeleton","TooltipProvider","TooltipPrimitive","Tooltip","TooltipTrigger","TooltipContent","SIDEBAR_WIDTH","SIDEBAR_WIDTH_ICON","SIDEBAR_KEYBOARD_SHORTCUT","SidebarContext","useSidebar","SidebarProvider","defaultOpen","openProp","setOpenProp","style","_open","_setOpen","isOpen","openState","toggleSidebar","state","contextValue","Sidebar","side","collapsible","SidebarTrigger","onClick","PanelLeft","SidebarRail","SidebarInset","SidebarInput","SidebarHeader","SidebarFooter","SidebarSeparator","SidebarContent","SidebarGroup","SidebarGroupLabel","SidebarGroupAction","SidebarGroupContent","SidebarMenu","SidebarMenuItem","sidebarMenuButtonVariants","SidebarMenuButton","isActive","tooltip","button","SidebarMenuAction","showOnHover","SidebarMenuBadge","SidebarMenuSkeleton","showIcon","width","SidebarMenuSub","SidebarMenuSubItem","SidebarMenuSubButton","SettingsSidebar","extensionLabels","projectInfo","handleSelectSidebarItem","selectedSidebarItem","extensionsSidebarGroupLabel","projectsSidebarGroupLabel","buttonPlaceholderText","handleSelectItem","projectId","getProjectNameFromProjectId","project","info","getIsActive","label","selectedProjectName","SettingsSidebarContentSearch","scrBookColId","scrRefColId","typeColId","detailsColId","defaultScrRefColumnName","defaultScrBookGroupName","defaultTypeColumnName","defaultDetailsColumnName","getColumns","colInfo","showSourceColumn","showSrcCol","formatScrRef","compareScrRefs","toRefOrRange","scriptureSelection","offsetStart","offsetEnd","scrRefToBBBCCCVVV","getRowKey","ScriptureResultsViewer","sources","showColumnHeaders","scriptureReferenceColumnName","scriptureBookGroupName","typeColumnName","detailsColumnName","onRowSelected","grouping","setGrouping","scriptureResults","source","getExpandedRowModel","getGroupedRowModel","selectedRows","keys","selectedRow","scrBookGroupName","typeGroupName","groupingOptions","handleSelectChange","selectedGrouping","handleRowClick","getEvenOrOddBandingStyle","getIndent","groupingState","rowIndex","ChevronLeft","DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS","getLocalizeKeyForScrollGroupId","ScrollGroupSelector","availableScrollGroupIds","scrollGroupId","onChangeScrollGroupId","localizedStringsDefaulted","localizedStringKey","localizedStringValue","newScrollGroupString","scrollGroupOptionId","SettingsList","SettingsListItem","primary","secondary","isLoading","loadingMessage","SettingsListHeader","includeSeparator","Checklist","listItems","selectedListItems","handleSelectListItem","createLabel","_interopRequireDefault","obj","module","chainPropTypes","propType1","propType2","args","_extends","target","isPlainObject","prototype","deepClone","output","deepmerge","r","z","reactIs_production_min","hasSymbol","REACT_ELEMENT_TYPE","REACT_PORTAL_TYPE","REACT_FRAGMENT_TYPE","REACT_STRICT_MODE_TYPE","REACT_PROFILER_TYPE","REACT_PROVIDER_TYPE","REACT_CONTEXT_TYPE","REACT_ASYNC_MODE_TYPE","REACT_CONCURRENT_MODE_TYPE","REACT_FORWARD_REF_TYPE","REACT_SUSPENSE_TYPE","REACT_SUSPENSE_LIST_TYPE","REACT_MEMO_TYPE","REACT_LAZY_TYPE","REACT_BLOCK_TYPE","REACT_FUNDAMENTAL_TYPE","REACT_RESPONDER_TYPE","REACT_SCOPE_TYPE","isValidElementType","typeOf","object","$$typeof","$$typeofType","AsyncMode","ConcurrentMode","ContextConsumer","ContextProvider","Element","ForwardRef","Lazy","Memo","Portal","Profiler","StrictMode","Suspense","hasWarnedAboutDeprecatedIsAsyncMode","isAsyncMode","isConcurrentMode","isContextConsumer","isContextProvider","isElement","isForwardRef","isFragment","isLazy","isMemo","isPortal","isProfiler","isStrictMode","isSuspense","reactIs_development","reactIsModule","require$$0","require$$1","getOwnPropertySymbols","hasOwnProperty","propIsEnumerable","toObject","val","shouldUseNative","test1","test2","order2","test3","letter","objectAssign","from","to","symbols","ReactPropTypesSecret","ReactPropTypesSecret_1","has","printWarning","loggedTypeFailures","message","checkPropTypes","typeSpecs","values","location","componentName","getStack","typeSpecName","error","err","ex","stack","checkPropTypes_1","ReactIs","assign","require$$2","require$$3","require$$4","emptyFunctionThatReturnsNull","factoryWithTypeCheckers","isValidElement","throwOnDirectAccess","ITERATOR_SYMBOL","FAUX_ITERATOR_SYMBOL","getIteratorFn","maybeIterable","iteratorFn","ANONYMOUS","ReactPropTypes","createPrimitiveTypeChecker","createAnyTypeChecker","createArrayOfTypeChecker","createElementTypeChecker","createElementTypeTypeChecker","createInstanceTypeChecker","createNodeChecker","createObjectOfTypeChecker","createEnumTypeChecker","createUnionTypeChecker","createShapeTypeChecker","createStrictShapeTypeChecker","is","PropTypeError","createChainableTypeChecker","validate","manualPropTypeCallCache","manualPropTypeWarningCount","checkType","isRequired","propName","propFullName","secret","cacheKey","chainedCheckType","expectedType","propValue","propType","getPropType","preciseType","getPreciseType","typeChecker","expectedClass","expectedClassName","actualClassName","getClassName","expectedValues","valuesString","arrayOfTypeCheckers","checker","getPostfixForTypeWarning","expectedTypes","checkerResult","expectedTypesMessage","isNode","invalidValidatorError","shapeTypes","allKeys","iterator","step","entry","isSymbol","emptyFunction","emptyFunctionWithReset","factoryWithThrowingShims","shim","getShim","propTypesModule","isClassComponent","elementType","acceptingRef","safePropName","warningHint","elementAcceptingRef","PropTypes","elementAcceptingRef$1","specialProperty","exactProp","propTypes","unsupportedProps","prop","formatMuiErrorMessage","code","url","REACT_SERVER_CONTEXT_TYPE","REACT_OFFSCREEN_TYPE","enableScopeAPI","enableCacheElement","enableTransitionTracing","enableLegacyHidden","enableDebugTracing","REACT_MODULE_REFERENCE","SuspenseList","hasWarnedAboutDeprecatedIsConcurrentMode","isSuspenseList","fnNameMatchRegex","getFunctionName","fn","getFunctionComponentName","Component","fallback","getWrappedName","outerType","innerType","wrapperName","functionName","getDisplayName","HTMLElementType","refType","refType$1","capitalize","string","_formatMuiErrorMessage","createChainedFunction","funcs","acc","func","debounce","wait","timeout","debounced","later","deprecatedPropType","validator","reason","componentNameSafe","propFullNameSafe","isMuiElement","muiNames","_muiName","_element$type","ownerDocument","node","ownerWindow","requirePropFactory","componentNameInError","prevPropTypes","requiredProp","defaultTypeChecker","typeCheckerResult","setRef","useEnhancedEffect","useEnhancedEffect$1","globalId","useGlobalId","idOverride","defaultId","setDefaultId","maybeReactUseId","useId","reactId","unsupportedProp","useControlled","controlled","defaultProp","name","isControlled","valueState","setValue","defaultValue","setValueIfUncontrolled","newValue","useEventCallback","useForkRef","refs","instance","UNINITIALIZED","useLazyRef","init","initArg","EMPTY","useOnMount","Timeout","delay","useTimeout","hadKeyboardEvent","hadFocusVisibleRecently","hadFocusVisibleRecentlyTimeout","inputTypesWhitelist","focusTriggersKeyboardModality","tagName","handlePointerDown","handleVisibilityChange","prepare","doc","isFocusVisible","useIsFocusVisible","isFocusVisibleRef","handleBlurVisible","handleFocusVisible","resolveProps","defaultProps","defaultSlotProps","slotProps","slotPropName","composeClasses","slots","getUtilityClass","classes","slot","utilityClass","defaultGenerator","createClassNameGenerator","generate","generator","ClassNameGenerator","ClassNameGenerator$1","globalStateClasses","generateUtilityClass","globalStatePrefix","globalStateClass","generateUtilityClasses","result","clamp","min","max","_objectWithoutPropertiesLoose","excluded","sourceKeys","_excluded","sortBreakpointsValues","breakpointsAsArray","breakpoint1","breakpoint2","createBreakpoints","breakpoints","unit","other","sortedValues","up","down","between","start","end","endIndex","only","not","keyIndex","shape","shape$1","responsivePropType","responsivePropType$1","merge","defaultBreakpoints","handleBreakpoints","styleFromPropValue","theme","themeBreakpoints","breakpoint","mediaKey","cssKey","createEmptyBreakpointObject","breakpointsInput","_breakpointsInput$key","breakpointStyleKey","removeUnusedBreakpoints","breakpointKeys","breakpointOutput","getPath","path","checkVars","getStyleValue","themeMapping","transform","propValueFinal","userValue","cssProperty","themeKey","memoize","cache","arg","properties","directions","aliases","getCssProperties","property","marginKeys","paddingKeys","spacingKeys","createUnaryUnit","_getPath","themeSpacing","abs","createUnarySpacing","getValue","transformer","transformed","getStyleFromPropValue","cssProperties","resolveCssProperty","margin","padding","createSpacing","spacingInput","spacing","argsInput","argument","compose","styles","handlers","borderTransform","createBorderStyle","border","borderTop","borderRight","borderBottom","borderLeft","borderColor","borderTopColor","borderRightColor","borderBottomColor","borderLeftColor","outline","outlineColor","borderRadius","gap","columnGap","rowGap","gridColumn","gridRow","gridAutoFlow","gridAutoColumns","gridAutoRows","gridTemplateColumns","gridTemplateRows","gridTemplateAreas","gridArea","paletteTransform","color","bgcolor","backgroundColor","sizingTransform","maxWidth","_props$theme","_props$theme2","breakpointsValues","minWidth","height","maxHeight","minHeight","boxSizing","defaultSxConfig","defaultSxConfig$1","objectsHaveSameKeys","objects","union","callIfFn","maybeFn","unstable_createStyleFunctionSx","getThemeValue","config","styleFunctionSx","_theme$unstable_sxCon","sx","traverse","sxInput","sxObject","emptyBreakpoints","breakpointsKeys","css","styleKey","styleFunctionSx$1","applyStyles","createTheme","paletteInput","shapeInput","muiTheme","isObjectEmpty","useTheme","defaultTheme","contextTheme","ThemeContext","systemDefaultTheme","useThemeWithoutDefault","_excluded2","_excluded3","isEmpty","isStringTag","tag","shouldForwardProp","lowercaseFirstLetter","resolveTheme","themeId","defaultOverridesResolver","processStyleArg","callableStyle","_ref","ownerState","resolvedStylesArg","resolvedStyle","variants","isMatch","createStyled","input","rootShouldForwardProp","slotShouldForwardProp","systemSx","inputOptions","processStyles","componentSlot","inputSkipVariantsResolver","inputSkipSx","overridesResolver","skipVariantsResolver","skipSx","shouldForwardPropOption","defaultStyledResolver","styledEngineStyled","transformStyleArg","stylesArg","muiStyledResolver","styleArg","expressions","transformedStyleArg","expressionsWithDefaultTheme","styleOverrides","resolvedStyleOverrides","slotKey","slotStyle","_theme$components","themeVariants","numOfCustomFnsApplied","placeholders","displayName","getThemeProps","params","useThemeProps","clampWrapper","hexToRgb","re","colors","decomposeColor","marker","colorSpace","recomposeColor","hslToRgb","rgb","getLuminance","getContrastRatio","foreground","background","lumA","lumB","alpha","darken","coefficient","lighten","createMixins","mixins","common","common$1","grey","grey$1","purple","purple$1","red","red$1","orange","orange$1","blue","blue$1","lightBlue","lightBlue$1","green","green$1","light","dark","addLightOrDark","intent","shade","tonalOffset","tonalOffsetLight","tonalOffsetDark","getDefaultPrimary","mode","getDefaultSecondary","getDefaultError","getDefaultInfo","getDefaultSuccess","getDefaultWarning","createPalette","palette","contrastThreshold","success","warning","getContrastText","contrastText","contrast","augmentColor","mainShade","lightShade","darkShade","modes","round","caseAllCaps","defaultFontFamily","createTypography","typography","fontFamily","fontSize","fontWeightLight","fontWeightRegular","fontWeightMedium","fontWeightBold","htmlFontSize","allVariants","pxToRem2","coef","pxToRem","buildVariant","fontWeight","lineHeight","letterSpacing","casing","shadowKeyUmbraOpacity","shadowKeyPenumbraOpacity","shadowAmbientShadowOpacity","createShadow","px","shadows","shadows$1","easing","duration","formatMs","milliseconds","getAutoHeightDuration","constant","createTransitions","inputTransitions","mergedEasing","mergedDuration","durationOption","easingOption","isString","isNumber","animatedProp","zIndex","zIndex$1","mixinsInput","transitionsInput","typographyInput","systemTheme","systemCreateTheme","stateClasses","component","child","stateClass","defaultTheme$1","THEME_ID","systemUseThemeProps","styled","styled$1","getSvgIconUtilityClass","useUtilityClasses","SvgIconRoot","_theme$transitions","_theme$transitions$cr","_theme$transitions2","_theme$typography","_theme$typography$pxT","_theme$typography2","_theme$typography2$px","_theme$typography3","_theme$typography3$px","_palette$ownerState$c","_palette","_palette2","_palette3","SvgIcon","inProps","htmlColor","inheritViewBox","titleAccess","viewBox","hasSvgAsChild","more","_jsxs","_jsx","SvgIcon$1","createSvgIcon","unstable_ClassNameGenerator","exports","_utils","ArrowRight","default_1","_createSvgIcon","_jsxRuntime","isHostComponent","appendOwnerState","otherProps","defaultContextValue","ClassNameConfiguratorContext","useClassNamesOverride","disableDefaultClasses","extractEventHandlers","excludeKeys","resolveComponentProps","componentProps","slotState","omitEventHandlers","mergeSlotProps","parameters","getSlotProps","additionalProps","externalSlotProps","externalForwardedProps","joinedClasses","mergedStyle","eventHandlers","componentsPropsWithoutEventHandlers","otherPropsWithoutEventHandlers","internalSlotProps","useSlotProps","_parameters$additiona","skipResolvingSlotProps","rest","resolvedComponentsProps","mergedProps","internalRef","GLOBAL_CLASS_PREFIX","buildStateClass","buildSlotClass","getContainer","container","forwardedRef","disablePortal","mountNode","setMountNode","handleRef","newProps","ReactDOM","top","bottom","right","left","auto","basePlacements","clippingParents","viewport","popper","reference","variationPlacements","placement","placements","beforeRead","read","afterRead","beforeMain","main","afterMain","beforeWrite","write","afterWrite","modifierPhases","getNodeName","getWindow","OwnElement","isHTMLElement","isShadowRoot","attributes","effect","_ref2","initialStyles","styleProperties","attribute","applyStyles$1","getBasePlacement","getUAString","uaData","isLayoutViewport","getBoundingClientRect","includeScale","isFixedStrategy","clientRect","scaleX","scaleY","visualViewport","addVisualOffsets","getLayoutRect","contains","parent","rootNode","next","getComputedStyle","isTableElement","getDocumentElement","getParentNode","getTrueOffsetParent","getContainingBlock","isFirefox","isIE","elementCss","currentNode","getOffsetParent","window","offsetParent","getMainAxisFromPlacement","within","mathMax","mathMin","withinMaxClamp","getFreshSideObject","mergePaddingObject","paddingObject","expandToHashMap","hashMap","toPaddingObject","arrow","_state$modifiersData$","arrowElement","popperOffsets","basePlacement","axis","isVertical","len","arrowRect","minProp","maxProp","endDiff","startDiff","arrowOffsetParent","clientSize","centerToReference","center","offset","axisProp","_options$element","arrow$1","getVariation","unsetSides","roundOffsetsByDPR","win","dpr","mapToStyles","_Object$assign2","popperRect","variation","offsets","gpuAcceleration","adaptive","roundOffsets","isFixed","_offsets$x","_offsets$y","_ref3","hasX","hasY","sideX","sideY","heightProp","widthProp","offsetY","offsetX","commonStyles","_ref4","_Object$assign","computeStyles","_ref5","_options$gpuAccelerat","_options$adaptive","_options$roundOffsets","computeStyles$1","passive","_options$scroll","scroll","_options$resize","resize","scrollParents","scrollParent","eventListeners","hash","getOppositePlacement","matched","getOppositeVariationPlacement","getWindowScroll","scrollLeft","scrollTop","getWindowScrollBarX","getViewportRect","strategy","html","layoutViewport","getDocumentRect","_element$ownerDocumen","winScroll","body","isScrollParent","_getComputedStyle","overflow","overflowX","overflowY","getScrollParent","listScrollParents","list","isBody","updatedList","rectToClientRect","rect","getInnerBoundingClientRect","getClientRectFromMixedType","clippingParent","getClippingParents","canEscapeClipping","clipperElement","getClippingRect","boundary","rootBoundary","mainClippingParents","firstClippingParent","clippingRect","accRect","computeOffsets","commonX","commonY","mainAxis","detectOverflow","_options","_options$placement","_options$strategy","_options$boundary","_options$rootBoundary","_options$elementConte","elementContext","_options$altBoundary","altBoundary","_options$padding","altContext","clippingClientRect","referenceClientRect","popperClientRect","elementClientRect","overflowOffsets","offsetData","multiply","computeAutoPlacement","flipVariations","_options$allowedAutoP","allowedAutoPlacements","allPlacements","allowedPlacements","overflows","getExpandedFallbackPlacements","oppositePlacement","flip","_options$mainAxis","checkMainAxis","_options$altAxis","checkAltAxis","specifiedFallbackPlacements","_options$flipVariatio","preferredPlacement","isBasePlacement","fallbackPlacements","referenceRect","checksMap","makeFallbackChecks","firstFittingPlacement","_basePlacement","isStartVariation","mainVariationSide","altVariationSide","checks","check","numberOfChecks","_loop","_i","fittingPlacement","_ret","flip$1","getSideOffsets","preventedOffsets","isAnySideFullyClipped","hide","referenceOverflow","popperAltOverflow","referenceClippingOffsets","popperEscapeOffsets","isReferenceHidden","hasPopperEscaped","hide$1","distanceAndSkiddingToXY","rects","invertDistance","skidding","distance","_options$offset","_data$state$placement","offset$1","popperOffsets$1","getAltAxis","preventOverflow","_options$tether","tether","_options$tetherOffset","tetherOffset","altAxis","tetherOffsetValue","normalizedTetherOffsetValue","offsetModifierState","_offsetModifierState$","mainSide","altSide","additive","minLen","maxLen","arrowPaddingObject","arrowPaddingMin","arrowPaddingMax","arrowLen","minOffset","maxOffset","clientOffset","offsetModifierValue","tetherMin","tetherMax","preventedOffset","_offsetModifierState$2","_mainSide","_altSide","_offset","_len","_min","_max","isOriginSide","_offsetModifierValue","_tetherMin","_tetherMax","_preventedOffset","preventOverflow$1","getHTMLElementScroll","getNodeScroll","isElementScaled","getCompositeRect","elementOrVirtualElement","isOffsetParentAnElement","offsetParentIsScaled","documentElement","order","modifiers","map","visited","modifier","sort","requires","dep","depModifier","orderModifiers","orderedModifiers","phase","pending","resolve","mergeByName","merged","current","existing","DEFAULT_OPTIONS","areValidElements","_key","popperGenerator","generatorOptions","_generatorOptions","_generatorOptions$def","defaultModifiers","_generatorOptions$def2","defaultOptions","effectCleanupFns","isDestroyed","setOptionsAction","cleanupModifierEffects","runModifierEffects","_state$elements","_state$orderedModifie","_state$orderedModifie2","_ref$options","cleanupFn","noopFn","createPopper","COMPONENT_NAME","getPopperUtilityClass","flipPlacement","resolveAnchorEl","anchorEl","isVirtualElement","defaultPopperOptions","PopperTooltip","_slots$root","initialPlacement","popperOptions","popperRefProp","TransitionProps","tooltipRef","ownRef","popperRef","handlePopperRef","handlePopperRefRef","rtlPlacement","setPlacement","resolvedAnchorElement","setResolvedAnchorElement","handlePopperUpdate","box","popperModifiers","childProps","Root","rootProps","Popper","containerProp","keepMounted","transition","exited","setExited","handleEnter","handleExited","resolvedAnchorEl","display","transitionProps","useThemeSystem","_setPrototypeOf","_inheritsLoose","subClass","superClass","setPrototypeOf","timeoutsShape","TransitionGroupContext","forceReflow","UNMOUNTED","EXITED","ENTERING","ENTERED","EXITING","Transition","_React$Component","_this","parentGroup","appear","initialStatus","prevState","nextIn","_proto","prevProps","nextStatus","exit","enter","mounting","_this2","appearing","maybeNode","maybeAppearing","timeouts","enterTimeout","_this3","nextState","callback","_this4","active","handler","doesNotHaveTimeoutOrListener","maybeNextCallback","_this$props","pt","noop","Transition$1","reflow","getTransitionProps","_style$transitionDura","_style$transitionTimi","getScale","isWebKit154","Grow","addEndListener","inProp","onEnter","onEntered","onEntering","onExit","onExited","onExiting","TransitionComponent","timer","autoTimeout","nodeRef","normalizedTransitionCallback","maybeIsAppearing","handleEntering","isAppearing","transitionDuration","transitionTimingFunction","handleEntered","handleExiting","handleExit","handleAddEndListener","Grow$1","PopperRoot","BasePopper","components","componentsProps","RootComponent","Popper$1","getTooltipUtilityClass","tooltipClasses","tooltipClasses$1","disableInteractive","touch","TooltipPopper","TooltipTooltip","TooltipArrow","hystersisOpen","hystersisTimer","cursorPosition","composeEventHandler","eventHandler","_slots$popper","_slots$transition","_slots$tooltip","_slots$arrow","_slotProps$popper","_ref6","_slotProps$popper2","_slotProps$transition","_slotProps$tooltip","_ref7","_slotProps$tooltip2","_slotProps$arrow","_ref8","_slotProps$arrow2","childrenProp","describeChild","disableFocusListener","disableHoverListener","disableInteractiveProp","disableTouchListener","enterDelay","enterNextDelay","enterTouchDelay","followCursor","idProp","leaveDelay","leaveTouchDelay","onClose","onOpen","PopperComponentProp","PopperProps","title","TransitionComponentProp","isRtl","childNode","setChildNode","arrowRef","setArrowRef","ignoreNonTouchEvents","closeTimer","enterTimer","leaveTimer","touchTimer","setOpenState","prevUserSelect","stopTouchInteraction","handleOpen","handleClose","handleLeave","focusVisibleRef","setChildIsFocusVisible","handleBlur","handleFocus","detectTouchStart","childrenProps","handleMouseOver","handleMouseLeave","handleTouchStart","handleTouchEnd","nativeEvent","handleMouseMove","nameOrDescProps","titleIsString","interactiveWrapperListeners","_PopperProps$popperOp","tooltipModifiers","PopperComponent","TooltipComponent","ArrowComponent","popperProps","tooltipProps","tooltipArrowProps","TransitionPropsInner","Tooltip$1","getIcon","icon","menuLabel","leading","MuiListItemIcon","MenuItem","allowForLeadingIcons","iconPathBefore","iconPathAfter","hasAutoFocus","isDense","isSubMenuParent","hasDisabledGutters","hasDivider","focusVisibleClassName","menuItem","MuiMenuItem","MuiListItemText","getAllGroups","menuDefinition","SubMenu","setAnchorEl","parentMenuItem","parentItemProps","handleParentMenuItemClick","renderSubMenuItems","includedGroups","group","GroupedMenuItemList","Menu","getOrderedGroupItems","groupId","allItems","menuProps","commandHandler","groupsToInclude","sortedGroups","itemArray","allowSpaceForLeadingIcons","createMenuItemProps","isLastItemInGroup","divKey","itemInfo","menuItemProps","TopLevelMenu","columnId","MenuColumn","metadata","Grid","List","GridMenu","multiColumnMenu","sortedColumns","columnNumbers","columnName","col","getUsePromiseOptionsDefaults","usePromise","promiseFactoryCallback","defaultValueRef","optionsDefaultedRef","setIsLoading","promiseIsCurrent","MenuIcon","HamburgerMenuButton","menuProvider","normalMenu","fullMenu","containerRef","ariaLabelPrefix","isMenuOpen","setMenuOpen","showFullMenu","setShowFullMenu","handleMenuItemClick","handleMenuButtonClick","prevIsOpen","isOpening","menuCommandHandler","command","setOffset","normalMenuData","fullMenuData","menu","IconButton","Drawer","isTooltipSuppressed","adjustMarginToAlignToEdge","MuiIconButton","Spinner","LoaderCircle","TextField","hasError","helperText","onFocus","onBlur","ShadLabel","Toolbar","AppBar","MuiToolbar","alertVariants","Alert","AlertTitle","AlertDescription","Card","CardHeader","CardTitle","CardDescription","CardContent","CardFooter","Sonner","Toaster","Slider","SliderPrimitive","Switch","SwitchPrimitives","Tabs","TabsList","TabsTrigger","TabsContent","InstallButton","isInstalling","handleClick","buttonText","Download","EnableButton","isEnabling","DisableButton","isDisabling","UpdateButton","isUpdating","MarkdownRenderer","markdown","anchorTarget","Markdown","FilterButton","Filter","DropdownMenuItemType","DropdownMenuItemType2","FilterDropdown","groups","NoExtensionsFound","MoreInfo","category","downloads","languages","moreInfoUrl","numberFormatted","NumberFormat","handleScrollToBottom","User","locale","LucideLink","CircleHelp","VersionHistory","versionHistory","showAllVersions","setShowAllVersions","currentDate","formatTimeString","dateString","date","dateDiff","yearDiff","monthDiff","dayDiff","timeString","sortedEntries","Footer","publisherDisplayName","fileSize","locales","formattedFileSize","formatBytes","languageNames","codes","displayNames","useEvent","unsubscriber","noopUnsubscriber","useEventAsync","unsubscribe","unsub"],"mappings":"48CAGA,MAAMA,GAAgBC,GAAAA,oBAAoB,CAAE,OAAQ,KAAO,CAAA,EAyDpD,SAASC,KAAMC,EAAsB,CACnC,OAAAH,GAAcI,GAAAA,KAAKD,CAAM,CAAC,CACnC,CCzDO,MAAME,GAAQC,EAAM,WACzB,CAAC,CAAE,UAAAC,EAAW,KAAAC,EAAM,GAAGC,CAAA,EAASC,IAE5BC,EAAA,IAAC,QAAA,CACC,KAAAH,EACA,UAAWN,EACT,sbACAK,CACF,EACA,IAAAG,EAEC,GAAGD,CAAA,CAAA,CAIZ,EACAJ,GAAM,YAAc,QCNpB,MAAMO,GAAmBC,EAAA,WACvB,CACE,CAAE,aAAAC,EAAc,cAAAC,EAAe,cAAAC,EAAe,aAAAC,EAAc,GAAGR,CAAM,EACrEC,IAGEQ,EAAA,KAAC,MAAI,CAAA,UAAU,cACb,SAAA,CAAAP,EAAA,IAACQ,GAAA,CACE,GAAGV,EACJ,KAAK,OACL,UAAU,0JACV,SAAWW,GAAUN,EAAaM,EAAM,OAAO,KAAK,EACpD,UAAYC,GAAM,CACZA,EAAE,MAAQ,SACCJ,IAEfF,EAAcM,CAAC,CACjB,EACA,QAASL,EACT,IAAAN,CAAA,CACF,EACAC,EAAA,IAACW,GAAA,QAAA,CACC,UAAU,8HACV,QAAS,IAAM,CAEb,QAAQ,IAAI,iBAAiB,CAC/B,CAAA,CACF,CACF,CAAA,CAAA,CAGN,EC9CA,IAAIC,GAAI,OAAO,eACXC,GAAI,CAACC,EAAGJ,EAAGK,IAAML,KAAKI,EAAIF,GAAEE,EAAGJ,EAAG,CAAE,WAAY,GAAI,aAAc,GAAI,SAAU,GAAI,MAAOK,CAAC,CAAE,EAAID,EAAEJ,CAAC,EAAIK,EACzGC,GAAI,CAACF,EAAGJ,EAAGK,IAAMF,GAAEC,EAAG,OAAOJ,GAAK,SAAWA,EAAI,GAAKA,EAAGK,CAAC,EAW9D,MAAME,GAAI,CACR,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MAEA,MAEA,MAEA,MAEA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,MAEA,MAEA,MAEA,MAEA,MACA,MACA,MACA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,KACF,EAAGC,GAAI,CACL,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,KACF,EAAGC,GAAI,CACL,UACA,SACA,YACA,UACA,cACA,SACA,SACA,OACA,WACA,WACA,UACA,UACA,eACA,eACA,OACA,WACA,kBACA,MACA,SACA,WACA,eACA,gBACA,SACA,WACA,eACA,UACA,kBACA,QACA,OACA,OACA,UACA,QACA,QACA,QACA,WACA,YACA,SACA,YACA,UACA,UACA,OACA,OACA,OACA,OACA,SACA,gBACA,gBACA,YACA,YACA,cACA,aACA,kBACA,kBACA,YACA,YACA,QACA,WACA,UACA,QACA,UACA,UACA,SACA,SACA,SACA,OACA,aACA,QACA,SACA,eACA,oBACA,0BACA,SACA,qBACA,sBACA,UACA,qBACA,cACA,cACA,cACA,cACA,mBACA,mBACA,qBACA,YACA,OACA,oBAGA,uBACA,uBACA,sBACA,yBACA,wBACA,qBACA,UACA,UACA,UACA,UACA,UACA,UACA,UACA,eACA,cACA,eACA,oBACA,qBACA,0BACA,0BACA,eACA,eACA,YACA,gBACA,cACA,eACA,iBACA,wBACA,mBACA,WACA,QACA,aACA,aACA,aACA,2BACA,4BACA,YACF,EAAGC,GAAIC,KACP,SAASC,GAAER,EAAGJ,EAAI,GAAI,CACpB,OAAOA,IAAMI,EAAIA,EAAE,YAAa,GAAGA,KAAKM,GAAIA,GAAEN,CAAC,EAAI,CACrD,CACA,SAASS,GAAET,EAAG,CACZ,OAAOQ,GAAER,CAAC,EAAI,CAChB,CACA,SAASU,GAAEV,EAAG,CACZ,MAAMJ,EAAI,OAAOI,GAAK,SAAWQ,GAAER,CAAC,EAAIA,EACxC,OAAOJ,GAAK,IAAMA,GAAK,EACzB,CACA,SAASe,GAAEX,EAAG,CACZ,OAAQ,OAAOA,GAAK,SAAWQ,GAAER,CAAC,EAAIA,IA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ACD,GAAI,CACF,MAAOA,EACR,EACD,QAAS,CACP,MAAOA,EACR,EACD,WAAY,CACV,MAAOA,EACR,EACD,aAAc,CACZ,MAAOA,EACR,EACD,cAAe,CACb,MAAOA,EACR,EACD,YAAa,CACX,MAAOA,EACR,EACD,SAAU,CACR,MAAOA,EACR,EACD,SAAU,CACR,MAAOA,EACR,EACD,cAAe,CACb,MAAOA,EACR,EACD,mBAAoB,CAClB,MAAOA,EACR,EACD,iBAAkB,CAChB,MAAOA,EACR,EACD,aAAc,CACZ,MAAOA,EACR,EACD,kBAAmB,CACjB,MAAOA,EACR,EACD,gBAAiB,CACf,MAAOA,EACR,EACD,EAAG,CACD,MAAOD,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,OAAQ,CACN,MAAOA,EACR,EACD,UAAW,CACT,MAAOA,EACR,EACD,YAAa,CACX,MAAOA,EACR,EACD,aAAc,CACZ,MAAOA,EACR,EACD,WAAY,CACV,MAAOA,EACR,EACD,QAAS,CACP,MAAOA,EACR,EACD,QAAS,CACP,MAAOA,EACR,EACD,aAAc,CACZ,MAAOA,EACR,EACD,kBAAmB,CACjB,MAAOA,EACR,EACD,gBAAiB,CACf,MAAOA,EACR,EACD,YAAa,CACX,MAAOA,EACR,EACD,iBAAkB,CAChB,MAAOA,EACR,EACD,eAAgB,CACd,MAAOA,EACR,EAED,aAAc,CACZ,YAAa,GACb,UAAWzwB,IAAU,CACnB,eAAgB,CACd,QAASA,CACV,CACP,EACG,EACD,QAAS,CAAE,EACX,SAAU,CAAE,EACZ,aAAc,CAAE,EAChB,WAAY,CAAE,EACd,WAAY,CAAE,EAEd,UAAW,CAAE,EACb,cAAe,CAAE,EACjB,SAAU,CAAE,EACZ,eAAgB,CAAE,EAClB,WAAY,CAAE,EACd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;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","x_google_ignoreList":[3,43,44,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,83,84,85,86,87,88,89,90,91,92,93,94,95,96,97,98,99,100,101,102,103,104,105,106,107,108,109,110,111,112,113,114,115,116,117,118,119,120,121,122,123,124,125,126,127,128,129,130,131,132,133,134,135,136,137,138,139,140,141,142,143,144,145,146,147,148,149,150,151,152,153,154,155,156,157,158,159,160,161,162,163,164,165,166,167,168,169,170,171,172,173,174,175,176,177,178,179,180,181,182,183,184,185,186,187,188,189,190,191,192,193,194,195,196,197,198,199,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,226]} \ No newline at end of file +{"version":3,"file":"index.cjs","sources":["../src/utils/shadcn-ui.util.ts","../src/components/shadcn-ui/input.tsx","../src/components/advanced/book-chapter-control/book-chapter-input.component.tsx","../../../node_modules/@sillsdev/scripture/dist/index.es.js","../src/components/shadcn-ui/dropdown-menu.tsx","../src/components/advanced/book-chapter-control/book-menu-item.component.tsx","../src/components/advanced/book-chapter-control/chapter-select.component.tsx","../src/components/advanced/book-chapter-control/go-to-menu-item.component.tsx","../src/components/advanced/book-chapter-control/book-chapter-control.component.tsx","../src/components/shadcn-ui/button.tsx","../src/components/shadcn-ui/label.tsx","../src/components/shadcn-ui/radio-group.tsx","../src/components/shadcn-ui/popover.tsx","../src/components/shadcn-ui/dialog.tsx","../src/components/shadcn-ui/command.tsx","../src/components/basics/combo-box.component.tsx","../src/components/basics/chapter-range-selector.component.tsx","../src/components/advanced/book-selector.component.tsx","../src/components/advanced/data-table/data-table-column-toggle.component.tsx","../src/components/shadcn-ui/select.tsx","../src/components/advanced/data-table/data-table-pagination.component.tsx","../src/components/shadcn-ui/table.tsx","../src/components/advanced/data-table/data-table.component.tsx","../src/components/advanced/inventory/occurrences-table.component.tsx","../src/components/shadcn-ui/checkbox.tsx","../src/components/advanced/inventory/inventory-utils.ts","../src/components/shadcn-ui/toggle.tsx","../src/components/shadcn-ui/toggle-group.tsx","../src/components/advanced/inventory/inventory-columns.tsx","../src/components/advanced/inventory/inventory.component.tsx","../src/components/basics/search-bar.component.tsx","../src/components/basics/tabs-vertical.tsx","../src/components/advanced/tab-navigation-content-search.component.tsx","../src/components/shadcn-ui/separator.tsx","../src/components/shadcn-ui/skeleton.tsx","../src/components/shadcn-ui/tooltip.tsx","../src/components/shadcn-ui/sidebar.tsx","../src/components/advanced/settings-components/settings-sidebar.component.tsx","../src/components/advanced/settings-components/settings-sidebar-content-search.component.tsx","../src/components/advanced/scripture-results-viewer/scripture-results-viewer.component.tsx","../src/components/advanced/scroll-group-selector.component.tsx","../src/components/advanced/settings-components/settings-list.component.tsx","../src/components/basics/checklist.component.tsx","../../../node_modules/@babel/runtime/helpers/interopRequireDefault.js","../../../node_modules/@mui/utils/chainPropTypes/chainPropTypes.js","../../../node_modules/@babel/runtime/helpers/esm/extends.js","../../../node_modules/@mui/utils/deepmerge/deepmerge.js","../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.production.min.js","../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.development.js","../../../node_modules/prop-types/node_modules/react-is/index.js","../../../node_modules/object-assign/index.js","../../../node_modules/prop-types/lib/ReactPropTypesSecret.js","../../../node_modules/prop-types/lib/has.js","../../../node_modules/prop-types/checkPropTypes.js","../../../node_modules/prop-types/factoryWithTypeCheckers.js","../../../node_modules/prop-types/factoryWithThrowingShims.js","../../../node_modules/prop-types/index.js","../../../node_modules/@mui/utils/elementAcceptingRef/elementAcceptingRef.js","../../../node_modules/@mui/utils/exactProp/exactProp.js","../../../node_modules/@mui/utils/formatMuiErrorMessage/formatMuiErrorMessage.js","../../../node_modules/react-is/cjs/react-is.production.min.js","../../../node_modules/react-is/cjs/react-is.development.js","../../../node_modules/react-is/index.js","../../../node_modules/@mui/utils/getDisplayName/getDisplayName.js","../../../node_modules/@mui/utils/HTMLElementType/HTMLElementType.js","../../../node_modules/@mui/utils/refType/refType.js","../../../node_modules/@mui/utils/capitalize/capitalize.js","../../../node_modules/@mui/utils/createChainedFunction/createChainedFunction.js","../../../node_modules/@mui/utils/debounce/debounce.js","../../../node_modules/@mui/utils/deprecatedPropType/deprecatedPropType.js","../../../node_modules/@mui/utils/isMuiElement/isMuiElement.js","../../../node_modules/@mui/utils/ownerDocument/ownerDocument.js","../../../node_modules/@mui/utils/ownerWindow/ownerWindow.js","../../../node_modules/@mui/utils/requirePropFactory/requirePropFactory.js","../../../node_modules/@mui/utils/setRef/setRef.js","../../../node_modules/@mui/utils/useEnhancedEffect/useEnhancedEffect.js","../../../node_modules/@mui/utils/useId/useId.js","../../../node_modules/@mui/utils/unsupportedProp/unsupportedProp.js","../../../node_modules/@mui/utils/useControlled/useControlled.js","../../../node_modules/@mui/utils/useEventCallback/useEventCallback.js","../../../node_modules/@mui/utils/useForkRef/useForkRef.js","../../../node_modules/@mui/utils/useLazyRef/useLazyRef.js","../../../node_modules/@mui/utils/useOnMount/useOnMount.js","../../../node_modules/@mui/utils/useTimeout/useTimeout.js","../../../node_modules/@mui/utils/useIsFocusVisible/useIsFocusVisible.js","../../../node_modules/@mui/utils/resolveProps/resolveProps.js","../../../node_modules/@mui/utils/composeClasses/composeClasses.js","../../../node_modules/@mui/utils/ClassNameGenerator/ClassNameGenerator.js","../../../node_modules/@mui/utils/generateUtilityClass/generateUtilityClass.js","../../../node_modules/@mui/utils/generateUtilityClasses/generateUtilityClasses.js","../../../node_modules/@mui/utils/clamp/clamp.js","../../../node_modules/@babel/runtime/helpers/esm/objectWithoutPropertiesLoose.js","../../../node_modules/@mui/system/esm/createTheme/createBreakpoints.js","../../../node_modules/@mui/system/esm/createTheme/shape.js","../../../node_modules/@mui/system/esm/responsivePropType.js","../../../node_modules/@mui/system/esm/merge.js","../../../node_modules/@mui/system/esm/breakpoints.js","../../../node_modules/@mui/system/esm/style.js","../../../node_modules/@mui/system/esm/memoize.js","../../../node_modules/@mui/system/esm/spacing.js","../../../node_modules/@mui/system/esm/createTheme/createSpacing.js","../../../node_modules/@mui/system/esm/compose.js","../../../node_modules/@mui/system/esm/borders.js","../../../node_modules/@mui/system/esm/cssGrid.js","../../../node_modules/@mui/system/esm/palette.js","../../../node_modules/@mui/system/esm/sizing.js","../../../node_modules/@mui/system/esm/styleFunctionSx/defaultSxConfig.js","../../../node_modules/@mui/system/esm/styleFunctionSx/styleFunctionSx.js","../../../node_modules/@mui/system/esm/createTheme/applyStyles.js","../../../node_modules/@mui/system/esm/createTheme/createTheme.js","../../../node_modules/@mui/system/esm/useThemeWithoutDefault.js","../../../node_modules/@mui/system/esm/useTheme.js","../../../node_modules/@mui/system/esm/createStyled.js","../../../node_modules/@mui/system/esm/useThemeProps/getThemeProps.js","../../../node_modules/@mui/system/esm/useThemeProps/useThemeProps.js","../../../node_modules/@mui/system/esm/colorManipulator.js","../../../node_modules/@mui/material/styles/createMixins.js","../../../node_modules/@mui/material/colors/common.js","../../../node_modules/@mui/material/colors/grey.js","../../../node_modules/@mui/material/colors/purple.js","../../../node_modules/@mui/material/colors/red.js","../../../node_modules/@mui/material/colors/orange.js","../../../node_modules/@mui/material/colors/blue.js","../../../node_modules/@mui/material/colors/lightBlue.js","../../../node_modules/@mui/material/colors/green.js","../../../node_modules/@mui/material/styles/createPalette.js","../../../node_modules/@mui/material/styles/createTypography.js","../../../node_modules/@mui/material/styles/shadows.js","../../../node_modules/@mui/material/styles/createTransitions.js","../../../node_modules/@mui/material/styles/zIndex.js","../../../node_modules/@mui/material/styles/createTheme.js","../../../node_modules/@mui/material/styles/defaultTheme.js","../../../node_modules/@mui/material/styles/identifier.js","../../../node_modules/@mui/material/styles/useThemeProps.js","../../../node_modules/@mui/material/styles/styled.js","../../../node_modules/@mui/material/SvgIcon/svgIconClasses.js","../../../node_modules/@mui/material/SvgIcon/SvgIcon.js","../../../node_modules/@mui/material/utils/createSvgIcon.js","../../../node_modules/@mui/material/utils/index.js","../../../node_modules/@mui/icons-material/utils/createSvgIcon.js","../../../node_modules/@mui/icons-material/ArrowRight.js","../../../node_modules/@mui/base/utils/isHostComponent.js","../../../node_modules/@mui/base/utils/appendOwnerState.js","../../../node_modules/@mui/base/utils/ClassNameConfigurator.js","../../../node_modules/@mui/base/utils/extractEventHandlers.js","../../../node_modules/@mui/base/utils/resolveComponentProps.js","../../../node_modules/@mui/base/utils/omitEventHandlers.js","../../../node_modules/@mui/base/utils/mergeSlotProps.js","../../../node_modules/@mui/base/utils/useSlotProps.js","../../../node_modules/@mui/base/generateUtilityClass/index.js","../../../node_modules/@mui/base/generateUtilityClasses/index.js","../../../node_modules/@mui/base/Portal/Portal.js","../../../node_modules/@popperjs/core/lib/enums.js","../../../node_modules/@popperjs/core/lib/dom-utils/getNodeName.js","../../../node_modules/@popperjs/core/lib/dom-utils/getWindow.js","../../../node_modules/@popperjs/core/lib/dom-utils/instanceOf.js","../../../node_modules/@popperjs/core/lib/modifiers/applyStyles.js","../../../node_modules/@popperjs/core/lib/utils/getBasePlacement.js","../../../node_modules/@popperjs/core/lib/utils/math.js","../../../node_modules/@popperjs/core/lib/utils/userAgent.js","../../../node_modules/@popperjs/core/lib/dom-utils/isLayoutViewport.js","../../../node_modules/@popperjs/core/lib/dom-utils/getBoundingClientRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/getLayoutRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/contains.js","../../../node_modules/@popperjs/core/lib/dom-utils/getComputedStyle.js","../../../node_modules/@popperjs/core/lib/dom-utils/isTableElement.js","../../../node_modules/@popperjs/core/lib/dom-utils/getDocumentElement.js","../../../node_modules/@popperjs/core/lib/dom-utils/getParentNode.js","../../../node_modules/@popperjs/core/lib/dom-utils/getOffsetParent.js","../../../node_modules/@popperjs/core/lib/utils/getMainAxisFromPlacement.js","../../../node_modules/@popperjs/core/lib/utils/within.js","../../../node_modules/@popperjs/core/lib/utils/getFreshSideObject.js","../../../node_modules/@popperjs/core/lib/utils/mergePaddingObject.js","../../../node_modules/@popperjs/core/lib/utils/expandToHashMap.js","../../../node_modules/@popperjs/core/lib/modifiers/arrow.js","../../../node_modules/@popperjs/core/lib/utils/getVariation.js","../../../node_modules/@popperjs/core/lib/modifiers/computeStyles.js","../../../node_modules/@popperjs/core/lib/modifiers/eventListeners.js","../../../node_modules/@popperjs/core/lib/utils/getOppositePlacement.js","../../../node_modules/@popperjs/core/lib/utils/getOppositeVariationPlacement.js","../../../node_modules/@popperjs/core/lib/dom-utils/getWindowScroll.js","../../../node_modules/@popperjs/core/lib/dom-utils/getWindowScrollBarX.js","../../../node_modules/@popperjs/core/lib/dom-utils/getViewportRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/getDocumentRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/isScrollParent.js","../../../node_modules/@popperjs/core/lib/dom-utils/getScrollParent.js","../../../node_modules/@popperjs/core/lib/dom-utils/listScrollParents.js","../../../node_modules/@popperjs/core/lib/utils/rectToClientRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/getClippingRect.js","../../../node_modules/@popperjs/core/lib/utils/computeOffsets.js","../../../node_modules/@popperjs/core/lib/utils/detectOverflow.js","../../../node_modules/@popperjs/core/lib/utils/computeAutoPlacement.js","../../../node_modules/@popperjs/core/lib/modifiers/flip.js","../../../node_modules/@popperjs/core/lib/modifiers/hide.js","../../../node_modules/@popperjs/core/lib/modifiers/offset.js","../../../node_modules/@popperjs/core/lib/modifiers/popperOffsets.js","../../../node_modules/@popperjs/core/lib/utils/getAltAxis.js","../../../node_modules/@popperjs/core/lib/modifiers/preventOverflow.js","../../../node_modules/@popperjs/core/lib/dom-utils/getHTMLElementScroll.js","../../../node_modules/@popperjs/core/lib/dom-utils/getNodeScroll.js","../../../node_modules/@popperjs/core/lib/dom-utils/getCompositeRect.js","../../../node_modules/@popperjs/core/lib/utils/orderModifiers.js","../../../node_modules/@popperjs/core/lib/utils/debounce.js","../../../node_modules/@popperjs/core/lib/utils/mergeByName.js","../../../node_modules/@popperjs/core/lib/createPopper.js","../../../node_modules/@popperjs/core/lib/popper.js","../../../node_modules/@mui/base/Popper/popperClasses.js","../../../node_modules/@mui/base/Popper/Popper.js","../../../node_modules/@mui/material/styles/useTheme.js","../../../node_modules/@babel/runtime/helpers/esm/setPrototypeOf.js","../../../node_modules/@babel/runtime/helpers/esm/inheritsLoose.js","../../../node_modules/react-transition-group/esm/config.js","../../../node_modules/react-transition-group/esm/utils/PropTypes.js","../../../node_modules/react-transition-group/esm/TransitionGroupContext.js","../../../node_modules/react-transition-group/esm/utils/reflow.js","../../../node_modules/react-transition-group/esm/Transition.js","../../../node_modules/@mui/material/transitions/utils.js","../../../node_modules/@mui/material/Grow/Grow.js","../../../node_modules/@mui/material/Popper/Popper.js","../../../node_modules/@mui/material/Tooltip/tooltipClasses.js","../../../node_modules/@mui/material/Tooltip/Tooltip.js","../src/components/mui/menu-item.component.tsx","../src/components/mui/grouped-menu-item-list.component.tsx","../src/components/mui/top-level-menu.component.tsx","../src/components/mui/grid-menu.component.tsx","../src/hooks/use-promise.hook.ts","../../../node_modules/@mui/icons-material/esm/Menu.js","../src/components/mui/hamburger-menu-button.component.tsx","../src/components/mui/icon-button.component.tsx","../src/components/basics/spinner.component.tsx","../src/components/basics/text-field.component.tsx","../src/components/mui/toolbar.component.tsx","../src/components/shadcn-ui/alert.tsx","../src/components/shadcn-ui/card.tsx","../src/components/shadcn-ui/sonner.tsx","../src/components/shadcn-ui/slider.tsx","../src/components/shadcn-ui/switch.tsx","../src/components/shadcn-ui/tabs.tsx","../src/components/advanced/extension-marketplace/buttons/install-button.component.tsx","../src/components/advanced/extension-marketplace/buttons/enable-button.component.tsx","../src/components/advanced/extension-marketplace/buttons/disable-button.component.tsx","../src/components/advanced/extension-marketplace/buttons/update-button.component.tsx","../src/components/advanced/extension-marketplace/markdown-renderer.component.tsx","../src/components/advanced/extension-marketplace/buttons/filter-button.component.tsx","../src/components/advanced/extension-marketplace/filter-dropdown.component.tsx","../src/components/advanced/extension-marketplace/no-extensions-found.component.tsx","../src/components/advanced/extension-marketplace/more-info.component.tsx","../src/components/advanced/extension-marketplace/version-history.component.tsx","../src/components/advanced/extension-marketplace/footer.component.tsx","../src/hooks/use-event.hook.ts","../src/hooks/use-event-async.hook.ts"],"sourcesContent":["import { type ClassValue, clsx } from 'clsx';\nimport { extendTailwindMerge } from 'tailwind-merge';\n\nconst twMergeCustom = extendTailwindMerge({ prefix: 'tw-' });\n\n/**\n * Tailwind and CSS class application helper function. Uses\n * [`clsx`](https://www.npmjs.com/package/clsx) to make it easy to apply classes conditionally using\n * object syntax, and uses [`tailwind-merge`](https://www.npmjs.com/package/tailwind-merge) to make\n * it easy to merge/overwrite Tailwind classes in a programmer-logic-friendly way.\n *\n * Note: `tailwind-merge` is configured to use the prefix `tw-`, so you must use the same prefix\n * with any Tailwind classes you use with this function to successfully overwrite other Tailwind\n * classes. `platform-bible-react` is configured to use `tw-` as its Tailwind prefix, so any\n * Tailwind classes you pass into `platform-bible-react` components will be compared using the `tw-`\n * prefix.\n *\n * This function was popularized by\n * [shadcn/ui](https://ui.shadcn.com/docs/installation/manual#add-a-cn-helper). See [ByteGrad's\n * explanation video](https://www.youtube.com/watch?v=re2JFITR7TI) for more information.\n *\n * @example\n *\n * ```typescript\n * const borderShouldBeBlue = true;\n * const textShouldBeRed = true;\n * const heightShouldBe20 = false;\n * const classString = cn(\n * 'tw-bg-primary tw-h-10 tw-text-primary-foreground',\n * 'tw-bg-secondary',\n * {\n * 'tw-border-blue-500': borderShouldBeBlue,\n * 'tw-text-red-500': textShouldBeRed,\n * 'tw-h-20': heightShouldBe20,\n * },\n * 'some-class',\n * );\n * ```\n *\n * The resulting `classString` is `'tw-h-10 tw-bg-secondary tw-border-blue-500 tw-text-red-500\n * some-class'`\n *\n * - Notice that `'tw-bg-secondary'`, specified later, overwrote `'tw-bg-primary'`, specified earlier,\n * because they are Tailwind classes that affect the same css property\n * - Notice that `'tw-text-red-500'`, specified later, overwrote `'tw-text-primary-foreground'`,\n * specified earlier, because they are Tailwind classes that affect the same css property\n * - Notice that `'tw-h-20'`, specified later, did not overwrite `'tw-h-10'`, specified earlier,\n * because `'tw-h-20'` is part of a conditional class object and its value evaluated to `false`;\n * therefore it was not applied\n * - Notice that `'some-class'` was applied. This function is not limited only to Tailwind classes.\n *\n *\n * @param inputs Class strings or `clsx` conditional class objects to merge. Tailwind classes\n * specified later in the arguments overwrite similar Tailwind classes specified earlier in the\n * arguments\n * @returns Class string containing all applicable classes from the arguments based on the rules\n * described above\n */\n// shadcn/ui uses this export in its boilerplate code\n// eslint-disable-next-line import/prefer-default-export\nexport function cn(...inputs: ClassValue[]) {\n return twMergeCustom(clsx(inputs));\n}\n","import React from 'react';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport interface InputProps extends React.InputHTMLAttributes {}\n\nexport const Input = React.forwardRef(\n ({ className, type, ...props }, ref) => {\n return (\n \n );\n },\n);\nInput.displayName = 'Input';\n","import { FocusEventHandler, forwardRef, KeyboardEvent, MouseEventHandler } from 'react';\nimport { History } from 'lucide-react';\nimport { Input as ShadInput } from '@/components/shadcn-ui/input';\n\nexport type BookChapterInputProps = {\n handleSearch: (searchString: string) => void;\n handleKeyDown: (event: KeyboardEvent) => void;\n handleOnClick: MouseEventHandler;\n handleSubmit: () => void;\n onFocus?: FocusEventHandler;\n value: string;\n placeholder: string;\n};\n\n// Shadcn Input sets type to \"button\"- HAVE to prop spread before setting type\nconst BookChapterInput = forwardRef(\n (\n { handleSearch, handleKeyDown, handleOnClick, handleSubmit, ...props }: BookChapterInputProps,\n ref,\n ) => {\n return (\n
    \n handleSearch(event.target.value)}\n onKeyDown={(e) => {\n if (e.key === 'Enter') {\n handleSubmit();\n }\n handleKeyDown(e);\n }}\n onClick={handleOnClick}\n ref={ref}\n />\n {\n // eslint-disable-next-line no-console\n console.log('back in history');\n }}\n />\n
    \n );\n },\n);\n\nexport default BookChapterInput;\n","var P = Object.defineProperty;\nvar R = (t, e, s) => e in t ? P(t, e, { enumerable: !0, configurable: !0, writable: !0, value: s }) : t[e] = s;\nvar n = (t, e, s) => R(t, typeof e != \"symbol\" ? e + \"\" : e, s);\nclass _ {\n constructor() {\n n(this, \"books\");\n n(this, \"firstSelectedBookNum\");\n n(this, \"lastSelectedBookNum\");\n n(this, \"count\");\n n(this, \"selectedBookNumbers\");\n n(this, \"selectedBookIds\");\n }\n}\nconst N = [\n \"GEN\",\n \"EXO\",\n \"LEV\",\n \"NUM\",\n \"DEU\",\n \"JOS\",\n \"JDG\",\n \"RUT\",\n \"1SA\",\n \"2SA\",\n // 10\n \"1KI\",\n \"2KI\",\n \"1CH\",\n \"2CH\",\n \"EZR\",\n \"NEH\",\n \"EST\",\n \"JOB\",\n \"PSA\",\n \"PRO\",\n // 20\n \"ECC\",\n \"SNG\",\n \"ISA\",\n \"JER\",\n \"LAM\",\n \"EZK\",\n \"DAN\",\n \"HOS\",\n \"JOL\",\n \"AMO\",\n // 30\n \"OBA\",\n \"JON\",\n \"MIC\",\n \"NAM\",\n \"HAB\",\n \"ZEP\",\n \"HAG\",\n \"ZEC\",\n \"MAL\",\n \"MAT\",\n // 40\n \"MRK\",\n \"LUK\",\n \"JHN\",\n \"ACT\",\n \"ROM\",\n \"1CO\",\n \"2CO\",\n \"GAL\",\n \"EPH\",\n \"PHP\",\n // 50\n \"COL\",\n \"1TH\",\n \"2TH\",\n \"1TI\",\n \"2TI\",\n \"TIT\",\n \"PHM\",\n \"HEB\",\n \"JAS\",\n \"1PE\",\n // 60\n \"2PE\",\n \"1JN\",\n \"2JN\",\n \"3JN\",\n \"JUD\",\n \"REV\",\n \"TOB\",\n \"JDT\",\n \"ESG\",\n \"WIS\",\n // 70\n \"SIR\",\n \"BAR\",\n \"LJE\",\n \"S3Y\",\n \"SUS\",\n \"BEL\",\n \"1MA\",\n \"2MA\",\n \"3MA\",\n \"4MA\",\n // 80\n \"1ES\",\n \"2ES\",\n \"MAN\",\n \"PS2\",\n \"ODA\",\n \"PSS\",\n \"JSA\",\n // actual variant text for JOS, now in LXA text\n \"JDB\",\n // actual variant text for JDG, now in LXA text\n \"TBS\",\n // actual variant text for TOB, now in LXA text\n \"SST\",\n // actual variant text for SUS, now in LXA text // 90\n \"DNT\",\n // actual variant text for DAN, now in LXA text\n \"BLT\",\n // actual variant text for BEL, now in LXA text\n \"XXA\",\n \"XXB\",\n \"XXC\",\n \"XXD\",\n \"XXE\",\n \"XXF\",\n \"XXG\",\n \"FRT\",\n // 100\n \"BAK\",\n \"OTH\",\n \"3ES\",\n // Used previously but really should be 2ES\n \"EZA\",\n // Used to be called 4ES, but not actually in any known project\n \"5EZ\",\n // Used to be called 5ES, but not actually in any known project\n \"6EZ\",\n // Used to be called 6ES, but not actually in any known project\n \"INT\",\n \"CNC\",\n \"GLO\",\n \"TDX\",\n // 110\n \"NDX\",\n \"DAG\",\n \"PS3\",\n \"2BA\",\n \"LBA\",\n \"JUB\",\n \"ENO\",\n \"1MQ\",\n \"2MQ\",\n \"3MQ\",\n // 120\n \"REP\",\n \"4BA\",\n \"LAO\"\n], B = [\n \"XXA\",\n \"XXB\",\n \"XXC\",\n \"XXD\",\n \"XXE\",\n \"XXF\",\n \"XXG\",\n \"FRT\",\n \"BAK\",\n \"OTH\",\n \"INT\",\n \"CNC\",\n \"GLO\",\n \"TDX\",\n \"NDX\"\n], O = [\n \"Genesis\",\n \"Exodus\",\n \"Leviticus\",\n \"Numbers\",\n \"Deuteronomy\",\n \"Joshua\",\n \"Judges\",\n \"Ruth\",\n \"1 Samuel\",\n \"2 Samuel\",\n \"1 Kings\",\n \"2 Kings\",\n \"1 Chronicles\",\n \"2 Chronicles\",\n \"Ezra\",\n \"Nehemiah\",\n \"Esther (Hebrew)\",\n \"Job\",\n \"Psalms\",\n \"Proverbs\",\n \"Ecclesiastes\",\n \"Song of Songs\",\n \"Isaiah\",\n \"Jeremiah\",\n \"Lamentations\",\n \"Ezekiel\",\n \"Daniel (Hebrew)\",\n \"Hosea\",\n \"Joel\",\n \"Amos\",\n \"Obadiah\",\n \"Jonah\",\n \"Micah\",\n \"Nahum\",\n \"Habakkuk\",\n \"Zephaniah\",\n \"Haggai\",\n \"Zechariah\",\n \"Malachi\",\n \"Matthew\",\n \"Mark\",\n \"Luke\",\n \"John\",\n \"Acts\",\n \"Romans\",\n \"1 Corinthians\",\n \"2 Corinthians\",\n \"Galatians\",\n \"Ephesians\",\n \"Philippians\",\n \"Colossians\",\n \"1 Thessalonians\",\n \"2 Thessalonians\",\n \"1 Timothy\",\n \"2 Timothy\",\n \"Titus\",\n \"Philemon\",\n \"Hebrews\",\n \"James\",\n \"1 Peter\",\n \"2 Peter\",\n \"1 John\",\n \"2 John\",\n \"3 John\",\n \"Jude\",\n \"Revelation\",\n \"Tobit\",\n \"Judith\",\n \"Esther Greek\",\n \"Wisdom of Solomon\",\n \"Sirach (Ecclesiasticus)\",\n \"Baruch\",\n \"Letter of Jeremiah\",\n \"Song of 3 Young Men\",\n \"Susanna\",\n \"Bel and the Dragon\",\n \"1 Maccabees\",\n \"2 Maccabees\",\n \"3 Maccabees\",\n \"4 Maccabees\",\n \"1 Esdras (Greek)\",\n \"2 Esdras (Latin)\",\n \"Prayer of Manasseh\",\n \"Psalm 151\",\n \"Odes\",\n \"Psalms of Solomon\",\n // WARNING, if you change the spelling of the *obsolete* tag be sure to update\n // IsObsolete routine\n \"Joshua A. *obsolete*\",\n \"Judges B. *obsolete*\",\n \"Tobit S. *obsolete*\",\n \"Susanna Th. *obsolete*\",\n \"Daniel Th. *obsolete*\",\n \"Bel Th. *obsolete*\",\n \"Extra A\",\n \"Extra B\",\n \"Extra C\",\n \"Extra D\",\n \"Extra E\",\n \"Extra F\",\n \"Extra G\",\n \"Front Matter\",\n \"Back Matter\",\n \"Other Matter\",\n \"3 Ezra *obsolete*\",\n \"Apocalypse of Ezra\",\n \"5 Ezra (Latin Prologue)\",\n \"6 Ezra (Latin Epilogue)\",\n \"Introduction\",\n \"Concordance \",\n \"Glossary \",\n \"Topical Index\",\n \"Names Index\",\n \"Daniel Greek\",\n \"Psalms 152-155\",\n \"2 Baruch (Apocalypse)\",\n \"Letter of Baruch\",\n \"Jubilees\",\n \"Enoch\",\n \"1 Meqabyan\",\n \"2 Meqabyan\",\n \"3 Meqabyan\",\n \"Reproof (Proverbs 25-31)\",\n \"4 Baruch (Rest of Baruch)\",\n \"Laodiceans\"\n], S = K();\nfunction g(t, e = !0) {\n return e && (t = t.toUpperCase()), t in S ? S[t] : 0;\n}\nfunction k(t) {\n return g(t) > 0;\n}\nfunction x(t) {\n const e = typeof t == \"string\" ? g(t) : t;\n return e >= 40 && e <= 66;\n}\nfunction T(t) {\n return (typeof t == \"string\" ? g(t) : t) <= 39;\n}\nfunction X(t) {\n return t <= 66;\n}\nfunction V(t) {\n const e = typeof t == \"string\" ? g(t) : t;\n return w(e) && !X(e);\n}\nfunction* L() {\n for (let t = 1; t <= N.length; t++) yield t;\n}\nconst G = 1, A = N.length;\nfunction H() {\n return [\"XXA\", \"XXB\", \"XXC\", \"XXD\", \"XXE\", \"XXF\", \"XXG\"];\n}\nfunction C(t, e = \"***\") {\n const s = t - 1;\n return s < 0 || s >= N.length ? e : N[s];\n}\nfunction I(t) {\n return t <= 0 || t > A ? \"******\" : O[t - 1];\n}\nfunction y(t) {\n return I(g(t));\n}\nfunction w(t) {\n const e = typeof t == \"number\" ? C(t) : t;\n return k(e) && !B.includes(e);\n}\nfunction q(t) {\n const e = typeof t == \"number\" ? C(t) : t;\n return k(e) && B.includes(e);\n}\nfunction U(t) {\n return O[t - 1].includes(\"*obsolete*\");\n}\nfunction K() {\n const t = {};\n for (let e = 0; e < N.length; e++)\n t[N[e]] = e + 1;\n return t;\n}\nconst m = {\n allBookIds: N,\n nonCanonicalIds: B,\n bookIdToNumber: g,\n isBookIdValid: k,\n isBookNT: x,\n isBookOT: T,\n isBookOTNT: X,\n isBookDC: V,\n allBookNumbers: L,\n firstBook: G,\n lastBook: A,\n extraBooks: H,\n bookNumberToId: C,\n bookNumberToEnglishName: I,\n bookIdToEnglishName: y,\n isCanonical: w,\n isExtraMaterial: q,\n isObsolete: U\n};\nvar l = /* @__PURE__ */ ((t) => (t[t.Unknown = 0] = \"Unknown\", t[t.Original = 1] = \"Original\", t[t.Septuagint = 2] = \"Septuagint\", t[t.Vulgate = 3] = \"Vulgate\", t[t.English = 4] = \"English\", t[t.RussianProtestant = 5] = \"RussianProtestant\", t[t.RussianOrthodox = 6] = \"RussianOrthodox\", t))(l || {});\nconst h = class h {\n // private versInfo: Versification;\n constructor(e) {\n n(this, \"name\");\n n(this, \"fullPath\");\n n(this, \"isPresent\");\n n(this, \"hasVerseSegments\");\n n(this, \"isCustomized\");\n n(this, \"baseVersification\");\n n(this, \"scriptureBooks\");\n n(this, \"_type\");\n if (e == null)\n throw new Error(\"Argument undefined\");\n typeof e == \"string\" ? (this.name = e, this._type = l[e]) : (this._type = e, this.name = l[e]);\n }\n get type() {\n return this._type;\n }\n equals(e) {\n return !e.type || !this.type ? !1 : e.type === this.type;\n }\n};\nn(h, \"Original\", new h(l.Original)), n(h, \"Septuagint\", new h(l.Septuagint)), n(h, \"Vulgate\", new h(l.Vulgate)), n(h, \"English\", new h(l.English)), n(h, \"RussianProtestant\", new h(l.RussianProtestant)), n(h, \"RussianOrthodox\", new h(l.RussianOrthodox));\nlet c = h;\nfunction E(t, e) {\n const s = e[0];\n for (let r = 1; r < e.length; r++)\n t = t.split(e[r]).join(s);\n return t.split(s);\n}\nvar D = /* @__PURE__ */ ((t) => (t[t.Valid = 0] = \"Valid\", t[t.UnknownVersification = 1] = \"UnknownVersification\", t[t.OutOfRange = 2] = \"OutOfRange\", t[t.VerseOutOfOrder = 3] = \"VerseOutOfOrder\", t[t.VerseRepeated = 4] = \"VerseRepeated\", t))(D || {});\nconst i = class i {\n constructor(e, s, r, a) {\n /** Not yet implemented. */\n n(this, \"firstChapter\");\n /** Not yet implemented. */\n n(this, \"lastChapter\");\n /** Not yet implemented. */\n n(this, \"lastVerse\");\n /** Not yet implemented. */\n n(this, \"hasSegmentsDefined\");\n /** Not yet implemented. */\n n(this, \"text\");\n /** Not yet implemented. */\n n(this, \"BBBCCCVVVS\");\n /** Not yet implemented. */\n n(this, \"longHashCode\");\n /** The versification of the reference. */\n n(this, \"versification\");\n n(this, \"rtlMark\", \"‏\");\n n(this, \"_bookNum\", 0);\n n(this, \"_chapterNum\", 0);\n n(this, \"_verseNum\", 0);\n n(this, \"_verse\");\n if (r == null && a == null)\n if (e != null && typeof e == \"string\") {\n const o = e, u = s != null && s instanceof c ? s : void 0;\n this.setEmpty(u), this.parse(o);\n } else if (e != null && typeof e == \"number\") {\n const o = s != null && s instanceof c ? s : void 0;\n this.setEmpty(o), this._verseNum = e % i.chapterDigitShifter, this._chapterNum = Math.floor(\n e % i.bookDigitShifter / i.chapterDigitShifter\n ), this._bookNum = Math.floor(e / i.bookDigitShifter);\n } else if (s == null)\n if (e != null && e instanceof i) {\n const o = e;\n this._bookNum = o.bookNum, this._chapterNum = o.chapterNum, this._verseNum = o.verseNum, this._verse = o.verse, this.versification = o.versification;\n } else {\n if (e == null) return;\n const o = e instanceof c ? e : i.defaultVersification;\n this.setEmpty(o);\n }\n else\n throw new Error(\"VerseRef constructor not supported.\");\n else if (e != null && s != null && r != null)\n if (typeof e == \"string\" && typeof s == \"string\" && typeof r == \"string\")\n this.setEmpty(a), this.updateInternal(e, s, r);\n else if (typeof e == \"number\" && typeof s == \"number\" && typeof r == \"number\")\n this._bookNum = e, this._chapterNum = s, this._verseNum = r, this.versification = a ?? i.defaultVersification;\n else\n throw new Error(\"VerseRef constructor not supported.\");\n else\n throw new Error(\"VerseRef constructor not supported.\");\n }\n /**\n * Determines if the verse string is in a valid format (does not consider versification).\n */\n static isVerseParseable(e) {\n return e.length > 0 && \"0123456789\".includes(e[0]) && !e.endsWith(this.verseRangeSeparator) && !e.endsWith(this.verseSequenceIndicator);\n }\n /**\n * Tries to parse the specified string into a verse reference.\n * @param str - The string to attempt to parse.\n * @returns success: `true` if the specified string was successfully parsed, `false` otherwise.\n * @returns verseRef: The result of the parse if successful, or empty VerseRef if it failed\n */\n static tryParse(e) {\n let s;\n try {\n return s = new i(e), { success: !0, verseRef: s };\n } catch (r) {\n if (r instanceof v)\n return s = new i(), { success: !1, verseRef: s };\n throw r;\n }\n }\n /**\n * Gets the reference as a comparable integer where the book, chapter, and verse each occupy 3\n * digits.\n * @param bookNum - Book number (this is 1-based, not an index).\n * @param chapterNum - Chapter number.\n * @param verseNum - Verse number.\n * @returns The reference as a comparable integer where the book, chapter, and verse each occupy 3\n * digits.\n */\n static getBBBCCCVVV(e, s, r) {\n return e % i.bcvMaxValue * i.bookDigitShifter + (s >= 0 ? s % i.bcvMaxValue * i.chapterDigitShifter : 0) + (r >= 0 ? r % i.bcvMaxValue : 0);\n }\n /**\n * Deserializes a serialized VerseRef.\n * @param serializedVerseRef - Serialized VerseRef to create from.\n * @returns the deserialized VerseRef.\n */\n static fromJSON(e) {\n const { book: s, chapterNum: r, verseNum: a, verse: o, versificationStr: u } = e, f = o || a.toString();\n let d;\n return u && (d = new c(u)), s ? new i(s, r.toString(), f, d) : new i();\n }\n /**\n * Parses a verse string and gets the leading numeric portion as a number.\n * @param verseStr - verse string to parse\n * @returns true if the entire string could be parsed as a single, simple verse number (1-999);\n * false if the verse string represented a verse bridge, contained segment letters, or was invalid\n */\n static tryGetVerseNum(e) {\n let s;\n if (!e)\n return s = -1, { success: !0, vNum: s };\n s = 0;\n let r;\n for (let a = 0; a < e.length; a++) {\n if (r = e[a], r < \"0\" || r > \"9\")\n return a === 0 && (s = -1), { success: !1, vNum: s };\n if (s = s * 10 + +r - 0, s > i.bcvMaxValue)\n return s = -1, { success: !1, vNum: s };\n }\n return { success: !0, vNum: s };\n }\n /**\n * Checks to see if a VerseRef hasn't been set - all values are the default.\n */\n get isDefault() {\n return this.bookNum === 0 && this.chapterNum === 0 && this.verseNum === 0 && this.versification == null;\n }\n /**\n * Gets whether the verse contains multiple verses.\n */\n get hasMultiple() {\n return this._verse != null && (this._verse.includes(i.verseRangeSeparator) || this._verse.includes(i.verseSequenceIndicator));\n }\n /**\n * Gets or sets the book of the reference. Book is the 3-letter abbreviation in capital letters,\n * e.g. `'MAT'`.\n */\n get book() {\n return m.bookNumberToId(this.bookNum, \"\");\n }\n set book(e) {\n this.bookNum = m.bookIdToNumber(e);\n }\n /**\n * Gets or sets the chapter of the reference,. e.g. `'3'`.\n */\n get chapter() {\n return this.isDefault || this._chapterNum < 0 ? \"\" : this._chapterNum.toString();\n }\n set chapter(e) {\n const s = +e;\n this._chapterNum = Number.isInteger(s) ? s : -1;\n }\n /**\n * Gets or sets the verse of the reference, including range, segments, and sequences, e.g. `'4'`,\n * or `'4b-5a, 7'`.\n */\n get verse() {\n return this._verse != null ? this._verse : this.isDefault || this._verseNum < 0 ? \"\" : this._verseNum.toString();\n }\n set verse(e) {\n const { success: s, vNum: r } = i.tryGetVerseNum(e);\n this._verse = s ? void 0 : e.replace(this.rtlMark, \"\"), this._verseNum = r, !(this._verseNum >= 0) && ({ vNum: this._verseNum } = i.tryGetVerseNum(this._verse));\n }\n /**\n * Get or set Book based on book number, e.g. `42`.\n */\n get bookNum() {\n return this._bookNum;\n }\n set bookNum(e) {\n if (e <= 0 || e > m.lastBook)\n throw new v(\n \"BookNum must be greater than zero and less than or equal to last book\"\n );\n this._bookNum = e;\n }\n /**\n * Gets or sets the chapter number, e.g. `3`. `-1` if not valid.\n */\n get chapterNum() {\n return this._chapterNum;\n }\n set chapterNum(e) {\n this.chapterNum = e;\n }\n /**\n * Gets or sets verse start number, e.g. `4`. `-1` if not valid.\n */\n get verseNum() {\n return this._verseNum;\n }\n set verseNum(e) {\n this._verseNum = e;\n }\n /**\n * String representing the versification (should ONLY be used for serialization/deserialization).\n *\n * @remarks This is for backwards compatibility when ScrVers was an enumeration.\n */\n get versificationStr() {\n var e;\n return (e = this.versification) == null ? void 0 : e.name;\n }\n set versificationStr(e) {\n this.versification = this.versification != null ? new c(e) : void 0;\n }\n /**\n * Determines if the reference is valid.\n */\n get valid() {\n return this.validStatus === 0;\n }\n /**\n * Get the valid status for this reference.\n */\n get validStatus() {\n return this.validateVerse(i.verseRangeSeparators, i.verseSequenceIndicators);\n }\n /**\n * Gets the reference as a comparable integer where the book,\n * chapter, and verse each occupy three digits and the verse is 0.\n */\n get BBBCCC() {\n return i.getBBBCCCVVV(this._bookNum, this._chapterNum, 0);\n }\n /**\n * Gets the reference as a comparable integer where the book,\n * chapter, and verse each occupy three digits. If verse is not null\n * (i.e., this reference represents a complex reference with verse\n * segments or bridge) this cannot be used for an exact comparison.\n */\n get BBBCCCVVV() {\n return i.getBBBCCCVVV(this._bookNum, this._chapterNum, this._verseNum);\n }\n /**\n * Gets whether the verse is defined as an excluded verse in the versification.\n * Does not handle verse ranges.\n */\n // eslint-disable-next-line @typescript-eslint/class-literal-property-style\n get isExcluded() {\n return !1;\n }\n /**\n * Parses the reference in the specified string.\n * Optionally versification can follow reference as in GEN 3:11/4\n * Throw an exception if\n * - invalid book name\n * - chapter number is missing or not a number\n * - verse number is missing or does not start with a number\n * - versification is invalid\n * @param verseStr - string to parse e.g. 'MAT 3:11'\n */\n parse(e) {\n if (e = e.replace(this.rtlMark, \"\"), e.includes(\"/\")) {\n const o = e.split(\"/\");\n if (e = o[0], o.length > 1)\n try {\n const u = +o[1].trim();\n this.versification = new c(l[u]);\n } catch {\n throw new v(\"Invalid reference : \" + e);\n }\n }\n const s = e.trim().split(\" \");\n if (s.length !== 2)\n throw new v(\"Invalid reference : \" + e);\n const r = s[1].split(\":\"), a = +r[0];\n if (r.length !== 2 || m.bookIdToNumber(s[0]) === 0 || !Number.isInteger(a) || a < 0 || !i.isVerseParseable(r[1]))\n throw new v(\"Invalid reference : \" + e);\n this.updateInternal(s[0], r[0], r[1]);\n }\n /**\n * Simplifies this verse ref so that it has no bridging of verses or\n * verse segments like `'1a'`.\n */\n simplify() {\n this._verse = void 0;\n }\n /**\n * Makes a clone of the reference.\n *\n * @returns The cloned VerseRef.\n */\n clone() {\n return new i(this);\n }\n toString() {\n const e = this.book;\n return e === \"\" ? \"\" : `${e} ${this.chapter}:${this.verse}`;\n }\n toJSON() {\n let e = this.verse;\n (e === \"\" || e === this.verseNum.toString()) && (e = void 0);\n const s = {\n book: this.book,\n chapterNum: this.chapterNum,\n verseNum: this.verseNum,\n verse: e,\n versificationStr: this.versificationStr\n };\n return e || delete s.verse, s;\n }\n /**\n * Compares this `VerseRef` with supplied one.\n * @param verseRef - object to compare this one to.\n * @returns `true` if this `VerseRef` is equal to the supplied one, `false` otherwise.\n */\n equals(e) {\n return e instanceof i ? e._bookNum === this._bookNum && e._chapterNum === this._chapterNum && e._verseNum === this._verseNum && e.verse === this.verse && (e.versification == null && this.versification == null || e.versification != null && this.versification != null && e.versification.equals(this.versification)) : !1;\n }\n /**\n * Enumerate all individual verses contained in a VerseRef.\n * Verse ranges are indicated by \"-\" and consecutive verses by \",\"s.\n * Examples:\n * GEN 1:2 returns GEN 1:2\n * GEN 1:1a-3b,5 returns GEN 1:1a, GEN 1:2, GEN 1:3b, GEN 1:5\n * GEN 1:2a-2c returns //! ??????\n *\n * @param specifiedVersesOnly - if set to true return only verses that are\n * explicitly specified only, not verses within a range. Defaults to `false`.\n * @param verseRangeSeparators - Verse range separators.\n * Defaults to `VerseRef.verseRangeSeparators`.\n * @param verseSequenceSeparators - Verse sequence separators.\n * Defaults to `VerseRef.verseSequenceIndicators`.\n * @returns An array of all single verse references in this VerseRef.\n */\n allVerses(e = !1, s = i.verseRangeSeparators, r = i.verseSequenceIndicators) {\n if (this._verse == null || this.chapterNum <= 0)\n return [this.clone()];\n const a = [], o = E(this._verse, r);\n for (const u of o.map((f) => E(f, s))) {\n const f = this.clone();\n f.verse = u[0];\n const d = f.verseNum;\n if (a.push(f), u.length > 1) {\n const b = this.clone();\n if (b.verse = u[1], !e)\n for (let p = d + 1; p < b.verseNum; p++) {\n const J = new i(\n this._bookNum,\n this._chapterNum,\n p,\n this.versification\n );\n this.isExcluded || a.push(J);\n }\n a.push(b);\n }\n }\n return a;\n }\n /**\n * Validates a verse number using the supplied separators rather than the defaults.\n */\n validateVerse(e, s) {\n if (!this.verse)\n return this.internalValid;\n let r = 0;\n for (const a of this.allVerses(!0, e, s)) {\n const o = a.internalValid;\n if (o !== 0)\n return o;\n const u = a.BBBCCCVVV;\n if (r > u)\n return 3;\n if (r === u)\n return 4;\n r = u;\n }\n return 0;\n }\n /**\n * Gets whether a single verse reference is valid.\n */\n get internalValid() {\n return this.versification == null ? 1 : this._bookNum <= 0 || this._bookNum > m.lastBook ? 2 : (m.isCanonical(this._bookNum), 0);\n }\n setEmpty(e = i.defaultVersification) {\n this._bookNum = 0, this._chapterNum = -1, this._verse = void 0, this.versification = e;\n }\n updateInternal(e, s, r) {\n this.bookNum = m.bookIdToNumber(e), this.chapter = s, this.verse = r;\n }\n};\nn(i, \"defaultVersification\", c.English), n(i, \"verseRangeSeparator\", \"-\"), n(i, \"verseSequenceIndicator\", \",\"), n(i, \"verseRangeSeparators\", [i.verseRangeSeparator]), n(i, \"verseSequenceIndicators\", [i.verseSequenceIndicator]), n(i, \"chapterDigitShifter\", 1e3), n(i, \"bookDigitShifter\", i.chapterDigitShifter * i.chapterDigitShifter), n(i, \"bcvMaxValue\", i.chapterDigitShifter - 1), /**\n * The valid status of the VerseRef.\n */\nn(i, \"ValidStatusType\", D);\nlet M = i;\nclass v extends Error {\n}\nexport {\n _ as BookSet,\n m as Canon,\n c as ScrVers,\n l as ScrVersType,\n M as VerseRef,\n v as VerseRefException\n};\n//# sourceMappingURL=index.es.js.map\n","import React from 'react';\nimport * as DropdownMenuPrimitive from '@radix-ui/react-dropdown-menu';\nimport { Check, ChevronRight, Circle } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport const DropdownMenu = DropdownMenuPrimitive.Root;\n\nexport const DropdownMenuTrigger = DropdownMenuPrimitive.Trigger;\n\nexport const DropdownMenuGroup = DropdownMenuPrimitive.Group;\n\nexport const DropdownMenuPortal = DropdownMenuPrimitive.Portal;\n\nexport const DropdownMenuSub = DropdownMenuPrimitive.Sub;\n\nexport const DropdownMenuRadioGroup = DropdownMenuPrimitive.RadioGroup;\n\nexport type DropdownMenuSubTriggerProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.SubTrigger\n> & {\n className?: string;\n inset?: boolean;\n};\n\nexport type DropdownMenuSubContentProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.SubContent\n> & {\n className?: string;\n};\n\nexport type DropdownMenuContentProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Content\n> & {\n className?: string;\n sideOffset?: number;\n};\n\nexport type DropdownMenuItemProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Item\n> & {\n className?: string;\n inset?: boolean;\n};\n\nexport type DropdownMenuCheckboxItemProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.CheckboxItem\n> & {\n className?: string;\n checked?: boolean;\n};\n\nexport type DropdownMenuRadioItemProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.RadioItem\n> & {\n className?: string;\n};\n\nexport type DropdownMenuLabelProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Label\n> & {\n className?: string;\n inset?: boolean;\n};\n\nexport type DropdownMenuSeparatorProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Separator\n> & {\n className?: string;\n};\n\nexport type DropdownMenuShortcutProps = React.HTMLAttributes & {\n className?: string;\n};\n\nexport const DropdownMenuSubTrigger = React.forwardRef<\n React.ElementRef,\n DropdownMenuSubTriggerProps\n>(({ className, inset, children, ...props }, ref) => (\n \n {children}\n \n \n));\nDropdownMenuSubTrigger.displayName = DropdownMenuPrimitive.SubTrigger.displayName;\n\nexport const DropdownMenuSubContent = React.forwardRef<\n React.ElementRef,\n DropdownMenuSubContentProps\n>(({ className, ...props }, ref) => (\n \n));\nDropdownMenuSubContent.displayName = DropdownMenuPrimitive.SubContent.displayName;\n\nexport const DropdownMenuContent = React.forwardRef<\n React.ElementRef,\n DropdownMenuContentProps\n>(({ className, sideOffset = 4, ...props }, ref) => (\n \n \n \n));\nDropdownMenuContent.displayName = DropdownMenuPrimitive.Content.displayName;\n\n/**\n * TODO: fix: direction is not automatically handled by this component, so that shortcuts are\n * display always to the right\n */\nexport const DropdownMenuItem = React.forwardRef<\n React.ElementRef,\n DropdownMenuItemProps\n>(({ className, inset, ...props }, ref) => (\n \n));\nDropdownMenuItem.displayName = DropdownMenuPrimitive.Item.displayName;\n\nexport const DropdownMenuCheckboxItem = React.forwardRef<\n React.ElementRef,\n DropdownMenuCheckboxItemProps\n>(({ className, children, checked, ...props }, ref) => (\n \n \n \n \n \n \n {children}\n \n));\nDropdownMenuCheckboxItem.displayName = DropdownMenuPrimitive.CheckboxItem.displayName;\n\nexport const DropdownMenuRadioItem = React.forwardRef<\n React.ElementRef,\n DropdownMenuRadioItemProps\n>(({ className, children, ...props }, ref) => (\n \n \n \n \n \n \n {children}\n \n));\nDropdownMenuRadioItem.displayName = DropdownMenuPrimitive.RadioItem.displayName;\n\nexport const DropdownMenuLabel = React.forwardRef<\n React.ElementRef,\n DropdownMenuLabelProps\n>(({ className, inset, ...props }, ref) => (\n \n));\nDropdownMenuLabel.displayName = DropdownMenuPrimitive.Label.displayName;\n\nexport const DropdownMenuSeparator = React.forwardRef<\n React.ElementRef,\n DropdownMenuSeparatorProps\n>(({ className, ...props }, ref) => (\n \n));\nDropdownMenuSeparator.displayName = DropdownMenuPrimitive.Separator.displayName;\n\nexport function DropdownMenuShortcut({ className, ...props }: DropdownMenuShortcutProps) {\n return (\n \n );\n}\nDropdownMenuShortcut.displayName = 'DropdownMenuShortcut';\n","import { Canon } from '@sillsdev/scripture';\nimport { PropsWithChildren, KeyboardEvent, forwardRef } from 'react';\nimport { DropdownMenuItem as ShadDropdownMenuItem } from '@/components/shadcn-ui/dropdown-menu';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport type BookType = 'OT' | 'NT' | 'DC';\n\ntype BookMenuItemProps = PropsWithChildren<{\n /** String id of book */\n bookId: string;\n /** Callback to run when a book menu item is selected */\n handleSelectBook: () => void;\n /** Indicates if this menu item is currently selected */\n isSelected: boolean;\n /** Function that is called upon highlighting a book in the dropdown menu */\n handleHighlightBook: () => void;\n /**\n * Function that is called on pressing a key\n *\n * @param event Event that contains information about the key stroke\n */\n handleKeyDown: (event: KeyboardEvent) => void;\n /**\n * Type of book associated with this menu item, coordinates color labels ? Mock up has the labels\n * coordinated to genre\n */\n bookType: BookType;\n}>;\n\nconst BookMenuItem = forwardRef(\n (\n {\n bookId,\n handleSelectBook,\n isSelected,\n handleHighlightBook,\n handleKeyDown,\n bookType,\n children,\n }: BookMenuItemProps,\n ref,\n ) => {\n return (\n {\n // preventDefault() here prevents the entire dropdown menu from closing when selecting this item\n event.preventDefault();\n handleSelectBook();\n }}\n onKeyDown={(event: KeyboardEvent) => {\n handleKeyDown(event);\n }}\n onFocus={handleHighlightBook}\n onMouseMove={handleHighlightBook}\n >\n \n {Canon.bookIdToEnglishName(bookId)}\n \n {isSelected &&
    {children}
    }\n \n );\n },\n);\n\nexport default BookMenuItem;\n","import { cn } from '@/utils/shadcn-ui.util';\nimport { useCallback } from 'react';\n\nexport type ChapterSelectProps = {\n /**\n * Callback to run when a chapter div is selected\n *\n * @param chapterNumber Number of the chapter that has been selected\n */\n handleSelectChapter: (chapterNumber: number) => void;\n /** The highest chapter number in the book (of course equal to number of chapters in the book) */\n endChapter: number;\n /** The chapter number that is currently selected */\n activeChapter: number;\n /** The chapter number that is currently highlighted using keyboard or mouse navigation */\n highlightedChapter: number;\n /**\n * Callback to run when a chapter is highlighted by the user\n *\n * @param chapterNumber The chapter that is highlighted\n */\n handleHighlightedChapter: (chapterNumber: number) => void;\n};\n\nfunction ChapterSelect({\n handleSelectChapter,\n endChapter,\n activeChapter,\n highlightedChapter,\n handleHighlightedChapter,\n}: ChapterSelectProps) {\n const chapters = Array.from({ length: endChapter }, (_, i) => i + 1);\n\n const handleMouse = useCallback(\n (chapterNumber: number) => {\n handleHighlightedChapter(chapterNumber);\n },\n [handleHighlightedChapter],\n );\n\n return (\n
    \n {chapters.map((chapter) => (\n {\n event.preventDefault();\n event.stopPropagation();\n handleSelectChapter(chapter);\n }}\n role=\"button\"\n onKeyDown={(event) => {\n if (event.key === 'Enter') {\n handleSelectChapter(chapter);\n }\n }}\n tabIndex={0}\n onMouseMove={() => handleMouse(chapter)}\n >\n {chapter}\n
    \n ))}\n
    \n );\n}\n\nexport default ChapterSelect;\n","import { DropdownMenuLabel as ShadDropdownMenuLabel } from '@/components/shadcn-ui/dropdown-menu';\nimport { Bookmark, Clock, ArrowDownWideNarrow } from 'lucide-react';\n\nexport type GoToMenuItemProps = {\n handleSort: () => void;\n handleLocationHistory: () => void;\n handleBookmarks: () => void;\n};\n\nfunction GoToMenuItem({ handleSort, handleLocationHistory, handleBookmarks }: GoToMenuItemProps) {\n return (\n \n

    Go To

    \n
    \n \n \n \n
    \n
    \n );\n}\n\nexport default GoToMenuItem;\n","import BookChapterInput from '@/components/advanced/book-chapter-control/book-chapter-input.component';\nimport BookMenuItem, {\n BookType,\n} from '@/components/advanced/book-chapter-control/book-menu-item.component';\nimport ChapterSelect from '@/components/advanced/book-chapter-control/chapter-select.component';\nimport GoToMenuItem from '@/components/advanced/book-chapter-control/go-to-menu-item.component';\nimport {\n DropdownMenu as ShadDropdownMenu,\n DropdownMenuContent as ShadDropdownMenuContent,\n DropdownMenuLabel as ShadDropdownMenuLabel,\n DropdownMenuSeparator as ShadDropdownMenuSeparator,\n DropdownMenuTrigger as ShadDropdownMenuTrigger,\n} from '@/components/shadcn-ui/dropdown-menu';\nimport { Canon } from '@sillsdev/scripture';\nimport { ScriptureReference, getChaptersForBook } from 'platform-bible-utils';\nimport {\n KeyboardEvent as ReactKeyboardEvent,\n useCallback,\n useEffect,\n useLayoutEffect,\n useRef,\n useState,\n} from 'react';\n\ntype BookTypeLabels = {\n [bookType in BookType]: string;\n};\ntype BookChapterControlProps = {\n scrRef: ScriptureReference;\n handleSubmit: (scrRef: ScriptureReference) => void;\n};\n\nconst ALL_BOOK_IDS = Canon.allBookIds;\nconst BOOK_TYPE_LABELS: BookTypeLabels = {\n OT: 'Old Testament',\n NT: 'New Testament',\n DC: 'Deuterocanon',\n};\nconst BOOK_TYPE_ARRAY: BookType[] = ['OT', 'NT', 'DC'];\n// This is the height of three menu items to offset scrolling to the selected menu item\n// If you use menuItemRef.clientHeight- includes height of chapter div which is too big\nconst SCROLL_OFFSET = 32 + 32 + 32;\nconst SEARCH_QUERY_FORMATS = [\n /^(\\w+)$/i, // Matches a single word (book name or id)\n /^(\\w+)(?:\\s(\\d+))$/i, // Matches a word followed by a chapter number\n /^(\\w+)(?:\\s(\\d+):(\\d+))$/i, // Matches a word followed by a chapter and verse number\n];\nconst fetchGroupedBooks = (bookType: BookType) => {\n const groupedBooks = {\n OT: ALL_BOOK_IDS.filter((bookId) => Canon.isBookOT(bookId)),\n NT: ALL_BOOK_IDS.filter((bookId) => Canon.isBookNT(bookId)),\n DC: ALL_BOOK_IDS.filter((bookId) => Canon.isBookDC(bookId)),\n };\n return groupedBooks[bookType];\n};\nconst fetchEndChapter = (bookId: string) => {\n // getChaptersForBook returns -1 if not found in scrBookData\n // scrBookData only includes OT and NT, so all DC will return -1\n return getChaptersForBook(Canon.bookIdToNumber(bookId));\n};\n\n/**\n * Gets all of the English names from book ids\n *\n * @returns String[]\n */\nfunction getAllEnglishNames(): string[] {\n const allEnglishNames = ALL_BOOK_IDS.map((bookId) => {\n return Canon.bookIdToEnglishName(bookId);\n });\n return allEnglishNames;\n}\n\n/**\n * Determines if bookName is in allEnglishNames\n *\n * @param bookName Book English name\n * @returns True if bookName is included, false otherwise\n */\nfunction isValidBookEnglishName(bookName: string): boolean {\n return getAllEnglishNames().includes(bookName);\n}\n\n/**\n * Gets a bookId from given English name\n *\n * @param bookName Book English name\n * @returns BookId of provided bookName, undefined otherwise\n */\nfunction getBookIdFromEnglishName(bookName: string): string | undefined {\n // Convert bookName to lowercase and then capitalize the first letter\n const formattedBookName = bookName.toLowerCase().replace(/^\\w/, (c) => c.toUpperCase());\n\n if (isValidBookEnglishName(formattedBookName)) {\n const matchingBookId = ALL_BOOK_IDS.find((bookId) => {\n return Canon.bookIdToEnglishName(bookId) === formattedBookName;\n });\n return matchingBookId;\n }\n\n return undefined;\n}\n\nfunction BookChapterControl({ scrRef, handleSubmit }: BookChapterControlProps) {\n const [searchQuery, setSearchQuery] = useState('');\n const [selectedBookId, setSelectedBookId] = useState(\n Canon.bookNumberToId(scrRef.bookNum),\n );\n const [highlightedChapter, setHighlightedChapter] = useState(scrRef.chapterNum ?? 0);\n const [highlightedBookId, setHighlightedBookId] = useState(\n Canon.bookNumberToId(scrRef.bookNum),\n );\n const [isContentOpen, setIsContentOpen] = useState(false);\n const [isContentOpenDelayed, setIsContentOpenDelayed] = useState(isContentOpen);\n\n // This ref will always be defined\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const inputRef = useRef(undefined!);\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const contentRef = useRef(undefined!);\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const menuItemRef = useRef(undefined!);\n\n const fetchFilteredBooks = useCallback(\n (bookType: BookType) => {\n return fetchGroupedBooks(bookType).filter((bookId: string) => {\n const englishNameLowerCase = Canon.bookIdToEnglishName(bookId).toLowerCase();\n const normalizedQuery = searchQuery.replace(/[^a-zA-Z]/g, '').toLowerCase();\n return (\n englishNameLowerCase.includes(normalizedQuery) || // Match book name\n bookId.toLowerCase().includes(normalizedQuery) // Match book ID\n );\n });\n },\n [searchQuery],\n );\n\n const handleSearchInput = (searchString: string) => {\n setSearchQuery(searchString);\n };\n\n /**\n * Whether to prevent radix's logic from closing the dropdown. This is important because radix\n * tries to close the dropdown when the input first focuses, and we don't want it to do that. But\n * we don't want to prevent the dropdown from closing when we click away from the input, so we\n * don't want to just keep it open if the input is focused\n */\n const shouldPreventAutoClosing = useRef(false);\n\n const controlMenuState = useCallback((open: boolean) => {\n if (shouldPreventAutoClosing.current) {\n shouldPreventAutoClosing.current = false;\n return;\n }\n setIsContentOpen(open);\n }, []);\n\n const updateReference = useCallback(\n (bookId: string, shouldClose: boolean, chapter?: number, verse?: number) => {\n setHighlightedChapter(\n Canon.bookNumberToId(scrRef.bookNum) !== bookId ? 1 : scrRef.chapterNum,\n );\n\n if (shouldClose || fetchEndChapter(bookId) === -1) {\n handleSubmit({\n bookNum: Canon.bookIdToNumber(bookId),\n chapterNum: chapter || 1,\n verseNum: verse || 1,\n });\n\n setIsContentOpen(false);\n setSearchQuery('');\n return;\n }\n\n setSelectedBookId(selectedBookId !== bookId ? bookId : '');\n setIsContentOpen(!shouldClose);\n },\n [handleSubmit, scrRef.bookNum, scrRef.chapterNum, selectedBookId],\n );\n\n const handleSelectChapter = (chapterNumber: number) => {\n if (chapterNumber <= 0 || chapterNumber > fetchEndChapter(selectedBookId)) {\n return;\n }\n updateReference(selectedBookId, true, chapterNumber);\n };\n\n const handleInputSubmit = useCallback(() => {\n SEARCH_QUERY_FORMATS.forEach((format) => {\n const matches = searchQuery.match(format);\n if (matches) {\n // Book should be a bookId or an english name\n const [book, chapter = undefined, verse = undefined] = matches.slice(1);\n const englishName = getBookIdFromEnglishName(book);\n\n if (Canon.isBookIdValid(book) || englishName) {\n updateReference(\n englishName ?? book,\n true,\n chapter ? parseInt(chapter, 10) : 1,\n verse ? parseInt(verse, 10) : 1,\n );\n }\n }\n });\n }, [updateReference, searchQuery]);\n\n const handleKeyDownInput = useCallback(\n (event: ReactKeyboardEvent) => {\n if (!isContentOpen) {\n setIsContentOpen(true);\n } else if (event.key === 'ArrowDown' || event.key === 'ArrowUp') {\n if (\n typeof menuItemRef !== 'undefined' &&\n // Ref uses null\n // eslint-disable-next-line no-null/no-null\n menuItemRef.current !== null\n ) {\n menuItemRef.current.focus();\n } else if (\n typeof contentRef !== 'undefined' &&\n // Ref uses null\n // eslint-disable-next-line no-null/no-null\n contentRef.current !== null\n ) {\n contentRef.current.focus();\n }\n event.preventDefault();\n }\n },\n [isContentOpen],\n );\n\n const handleKeyDownContent = (event: ReactKeyboardEvent) => {\n // When the dropdown menu has focus, key strokes should give focus to the input component,\n // unless they're navigation keys (arrows and enter)\n const { key } = event;\n if (\n key === 'ArrowRight' ||\n key === 'ArrowLeft' ||\n key === 'ArrowDown' ||\n key === 'ArrowUp' ||\n key === 'Enter'\n ) {\n return;\n }\n\n inputRef.current.dispatchEvent(new KeyboardEvent('keydown', { key }));\n inputRef.current.focus();\n };\n\n const handleKeyDownMenuItem = (event: ReactKeyboardEvent) => {\n const { key } = event;\n if (highlightedBookId === selectedBookId) {\n if (key === 'Enter') {\n event.preventDefault();\n updateReference(selectedBookId, true, highlightedChapter);\n return;\n }\n\n let chapterOffSet = 0;\n if (key === 'ArrowRight') {\n if (highlightedChapter < fetchEndChapter(highlightedBookId)) {\n chapterOffSet = 1;\n } else {\n event.preventDefault();\n return;\n }\n } else if (key === 'ArrowLeft') {\n if (highlightedChapter > 1) {\n chapterOffSet = -1;\n } else {\n event.preventDefault();\n return;\n }\n } else if (key === 'ArrowDown') {\n chapterOffSet = 6;\n } else if (key === 'ArrowUp') {\n chapterOffSet = -6;\n }\n if (\n highlightedChapter + chapterOffSet <= 0 ||\n highlightedChapter + chapterOffSet > fetchEndChapter(highlightedBookId)\n ) {\n setHighlightedChapter(0);\n } else if (chapterOffSet !== 0) {\n setHighlightedChapter(highlightedChapter + chapterOffSet);\n event.preventDefault();\n }\n }\n };\n\n useEffect(() => {\n if (selectedBookId === highlightedBookId) {\n if (selectedBookId === Canon.bookNumberToId(scrRef.bookNum)) {\n setHighlightedChapter(scrRef.chapterNum);\n } else {\n setHighlightedChapter(1);\n }\n } else {\n setHighlightedChapter(0);\n }\n }, [highlightedBookId, scrRef.bookNum, scrRef.chapterNum, selectedBookId]);\n\n // The purpose of these useLayoutEffects and timeout is to delay the scroll just\n // enough so that the refs are defined and available when they are used after the timeout\n useLayoutEffect(() => {\n setIsContentOpenDelayed(isContentOpen);\n }, [isContentOpen]);\n\n useLayoutEffect(() => {\n const scrollTimeout = setTimeout(() => {\n if (isContentOpenDelayed && contentRef.current && menuItemRef.current) {\n const menuItemOffsetTop = menuItemRef.current.offsetTop;\n const scrollPosition = menuItemOffsetTop - SCROLL_OFFSET;\n contentRef.current.scrollTo({ top: scrollPosition, behavior: 'instant' });\n }\n }, 10);\n return () => {\n clearTimeout(scrollTimeout);\n };\n }, [isContentOpenDelayed]);\n\n return (\n
    \n \n \n {\n setSelectedBookId(Canon.bookNumberToId(scrRef.bookNum));\n setHighlightedBookId(Canon.bookNumberToId(scrRef.bookNum));\n setHighlightedChapter(scrRef.chapterNum > 0 ? scrRef.chapterNum : 0);\n setIsContentOpen(true);\n inputRef.current.focus();\n }}\n onFocus={() => {\n // Radix thinks we want to close because the input is being focused. Prevent that\n shouldPreventAutoClosing.current = true;\n }}\n handleSubmit={handleInputSubmit}\n placeholder={`${Canon.bookNumberToEnglishName(scrRef.bookNum)} ${scrRef.chapterNum}:${scrRef.verseNum}`}\n />\n \n \n console.log('sorting')}\n handleLocationHistory={() => console.log('location history')}\n handleBookmarks={() => console.log('bookmarks')}\n />\n {BOOK_TYPE_ARRAY.map(\n (bookType, bookTypeIndex) =>\n fetchFilteredBooks(bookType).length > 0 && (\n
    \n \n {BOOK_TYPE_LABELS[bookType]}\n \n\n {fetchFilteredBooks(bookType).map((bookId) => (\n
    \n updateReference(bookId, false)}\n isSelected={selectedBookId === bookId}\n handleHighlightBook={() => setHighlightedBookId(bookId)}\n handleKeyDown={handleKeyDownMenuItem}\n bookType={bookType}\n ref={(element: HTMLDivElement) => {\n if (selectedBookId === bookId) menuItemRef.current = element;\n }}\n >\n {\n setHighlightedChapter(chapterNumber);\n }}\n />\n \n
    \n ))}\n {BOOK_TYPE_ARRAY.length - 1 !== bookTypeIndex ? (\n \n ) : undefined}\n
    \n ),\n )}\n \n
    \n
    \n );\n}\n\nexport default BookChapterControl;\n","import React from 'react';\nimport { Slot } from '@radix-ui/react-slot';\nimport { cva, type VariantProps } from 'class-variance-authority';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport const buttonVariants = cva(\n 'pr-twp tw-inline-flex tw-items-center tw-justify-center tw-whitespace-nowrap tw-rounded-md tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-colors focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50',\n {\n variants: {\n variant: {\n default: 'tw-bg-primary tw-text-primary-foreground hover:tw-bg-primary/90',\n destructive: 'tw-bg-destructive tw-text-destructive-foreground hover:tw-bg-destructive/90',\n outline:\n 'tw-border tw-border-input tw-bg-background hover:tw-bg-accent hover:tw-text-accent-foreground',\n secondary: 'tw-bg-secondary tw-text-secondary-foreground hover:tw-bg-secondary/80',\n ghost: 'hover:tw-bg-accent hover:tw-text-accent-foreground',\n link: 'tw-text-primary tw-underline-offset-4 hover:tw-underline',\n },\n size: {\n default: 'tw-h-10 tw-px-4 tw-py-2',\n sm: 'tw-h-9 tw-rounded-md tw-px-3',\n lg: 'tw-h-11 tw-rounded-md tw-px-8',\n icon: 'tw-h-10 tw-w-10',\n },\n },\n defaultVariants: {\n variant: 'default',\n size: 'default',\n },\n },\n);\n\nexport interface ButtonProps\n extends React.ButtonHTMLAttributes,\n VariantProps {\n asChild?: boolean;\n}\n\nexport const Button = React.forwardRef(\n ({ className, variant, size, asChild = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'button';\n return (\n \n );\n },\n);\nButton.displayName = 'Button';\n","import React from 'react';\nimport * as LabelPrimitive from '@radix-ui/react-label';\nimport { cva, type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst labelVariants = cva(\n 'tw-text-sm tw-font-medium tw-leading-none peer-disabled:tw-cursor-not-allowed peer-disabled:tw-opacity-70',\n);\n\nexport const Label = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef & VariantProps\n>(({ className, ...props }, ref) => (\n \n));\nLabel.displayName = LabelPrimitive.Root.displayName;\n","import React from 'react';\nimport * as RadioGroupPrimitive from '@radix-ui/react-radio-group';\nimport { Circle } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst RadioGroup = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => {\n return (\n \n );\n});\nRadioGroup.displayName = RadioGroupPrimitive.Root.displayName;\n\nconst RadioGroupItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => {\n return (\n \n \n \n \n \n );\n});\nRadioGroupItem.displayName = RadioGroupPrimitive.Item.displayName;\n\nexport { RadioGroup, RadioGroupItem };\n","import React from 'react';\nimport * as PopoverPrimitive from '@radix-ui/react-popover';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Popover = PopoverPrimitive.Root;\n\nconst PopoverTrigger = PopoverPrimitive.Trigger;\n\nconst PopoverContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, align = 'center', sideOffset = 4, ...props }, ref) => (\n \n \n \n));\nPopoverContent.displayName = PopoverPrimitive.Content.displayName;\n\nexport { Popover, PopoverTrigger, PopoverContent };\n","import React from 'react';\nimport * as DialogPrimitive from '@radix-ui/react-dialog';\nimport { X } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Dialog = DialogPrimitive.Root;\n\nconst DialogTrigger = DialogPrimitive.Trigger;\n\nconst DialogPortal = DialogPrimitive.Portal;\n\nconst DialogClose = DialogPrimitive.Close;\n\nconst DialogOverlay = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nDialogOverlay.displayName = DialogPrimitive.Overlay.displayName;\n\nconst DialogContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, ...props }, ref) => (\n \n \n \n {children}\n \n \n Close\n \n \n \n));\nDialogContent.displayName = DialogPrimitive.Content.displayName;\n\nfunction DialogHeader({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nDialogHeader.displayName = 'DialogHeader';\n\nfunction DialogFooter({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nDialogFooter.displayName = 'DialogFooter';\n\nconst DialogTitle = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nDialogTitle.displayName = DialogPrimitive.Title.displayName;\n\nconst DialogDescription = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nDialogDescription.displayName = DialogPrimitive.Description.displayName;\n\nexport {\n Dialog,\n DialogPortal,\n DialogOverlay,\n DialogClose,\n DialogTrigger,\n DialogContent,\n DialogHeader,\n DialogFooter,\n DialogTitle,\n DialogDescription,\n};\n","import React from 'react';\nimport { type DialogProps } from '@radix-ui/react-dialog';\nimport { Command as CommandPrimitive } from 'cmdk';\nimport { Search } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Dialog, DialogContent } from '@/components/shadcn-ui/dialog';\n\nconst Command = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nCommand.displayName = CommandPrimitive.displayName;\n\ninterface CommandDialogProps extends DialogProps {}\n\nfunction CommandDialog({ children, ...props }: CommandDialogProps) {\n return (\n \n \n \n {children}\n \n \n \n );\n}\n\nconst CommandInput = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n
    \n \n \n
    \n));\n\nCommandInput.displayName = CommandPrimitive.Input.displayName;\n\nconst CommandList = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\n\nCommandList.displayName = CommandPrimitive.List.displayName;\n\nconst CommandEmpty = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>((props, ref) => (\n \n));\n\nCommandEmpty.displayName = CommandPrimitive.Empty.displayName;\n\nconst CommandGroup = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\n\nCommandGroup.displayName = CommandPrimitive.Group.displayName;\n\nconst CommandSeparator = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nCommandSeparator.displayName = CommandPrimitive.Separator.displayName;\n\nconst CommandItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\n\nCommandItem.displayName = CommandPrimitive.Item.displayName;\n\nfunction CommandShortcut({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nCommandShortcut.displayName = 'CommandShortcut';\n\nexport {\n Command,\n CommandDialog,\n CommandInput,\n CommandList,\n CommandEmpty,\n CommandGroup,\n CommandItem,\n CommandShortcut,\n CommandSeparator,\n};\n","import { useState } from 'react';\nimport { Check, ChevronsUpDown } from 'lucide-react';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport { Popover, PopoverContent, PopoverTrigger } from '@/components/shadcn-ui/popover';\nimport {\n Command,\n CommandEmpty,\n CommandInput,\n CommandItem,\n CommandList,\n} from '@/components/shadcn-ui/command';\nimport { PopoverProps } from '@radix-ui/react-popover';\n\nexport type ComboBoxLabelOption = { label: string };\nexport type ComboBoxOption = string | number | ComboBoxLabelOption;\n\nexport type ComboBoxProps = {\n /** Optional unique identifier */\n id?: string;\n /** Text label title for combobox */\n /** List of available options for the dropdown menu */\n options?: readonly T[];\n /** @deprecated 3 December 2024. Renamed to {@link buttonClassName} */\n className?: string;\n /** Additional css classes to help with unique styling of the combo box button */\n buttonClassName?: string;\n /** Additional css classes to help with unique styling of the combo box popover */\n popoverContentClassName?: string;\n /**\n * The selected value that the combo box currently holds. Must be shallow equal to one of the\n * options entries.\n */\n value?: T;\n /** Triggers when content of textfield is changed */\n onChange?: (newValue: T) => void;\n /** Used to determine the string value for a given option. */\n getOptionLabel?: (option: ComboBoxOption) => string;\n /** Text displayed on button if `value` is undefined */\n buttonPlaceholder?: string;\n /** Placeholder text for text field */\n textPlaceholder?: string;\n /** Text to display when no options match input */\n commandEmptyMessage?: string;\n /** Variant of button */\n buttonVariant?: ButtonProps['variant'];\n /** Text direction ltr or rtl */\n dir?: Direction;\n /** Optional boolean to set if trigger should be disabled */\n isDisabled?: boolean;\n} & PopoverProps;\n\ntype Direction = 'ltr' | 'rtl';\n\nfunction getOptionLabelDefault(option: ComboBoxOption): string {\n if (typeof option === 'string') {\n return option;\n }\n if (typeof option === 'number') {\n return option.toString();\n }\n return option.label;\n}\n\n/**\n * Autocomplete input and command palette with a list of suggestions.\n *\n * Thanks to Shadcn for heavy inspiration and documentation\n * https://ui.shadcn.com/docs/components/combobox\n */\nfunction ComboBox({\n id,\n options = [],\n buttonClassName,\n popoverContentClassName,\n value,\n onChange = () => {},\n getOptionLabel = getOptionLabelDefault,\n buttonPlaceholder = '',\n textPlaceholder = '',\n commandEmptyMessage = 'No option found',\n buttonVariant = 'outline',\n dir = 'ltr',\n isDisabled = false,\n ...props\n}: ComboBoxProps) {\n const [open, setOpen] = useState(false);\n\n return (\n \n \n \n \n {value ? getOptionLabel(value) : buttonPlaceholder}\n \n \n \n \n \n \n \n {commandEmptyMessage}\n \n {options.map((option) => (\n {\n onChange(option);\n setOpen(false);\n }}\n >\n \n {getOptionLabel(option)}\n \n ))}\n \n \n \n \n );\n}\n\nexport default ComboBox;\n","import { useMemo } from 'react';\nimport ComboBox from '@/components/basics/combo-box.component';\nimport { Label } from '@/components/shadcn-ui/label';\n\nexport type ChapterRangeSelectorProps = {\n startChapter: number;\n endChapter: number;\n handleSelectStartChapter: (chapter: number) => void;\n handleSelectEndChapter: (chapter: number) => void;\n isDisabled?: boolean;\n chapterCount: number;\n};\n\nexport default function ChapterRangeSelector({\n startChapter,\n endChapter,\n handleSelectStartChapter,\n handleSelectEndChapter,\n isDisabled = false,\n chapterCount,\n}: ChapterRangeSelectorProps) {\n const chapterOptions = useMemo(\n () => Array.from({ length: chapterCount }, (_, index) => index + 1),\n [chapterCount],\n );\n\n const onChangeStartChapter = (value: number) => {\n handleSelectStartChapter(value);\n if (value > endChapter) {\n handleSelectEndChapter(value);\n }\n };\n\n const onChangeEndChapter = (value: number) => {\n handleSelectEndChapter(value);\n if (value < startChapter) {\n handleSelectStartChapter(value);\n }\n };\n\n return (\n <>\n \n option.toString()}\n value={startChapter}\n />\n\n \n option.toString()}\n value={endChapter}\n />\n \n );\n}\n","import { Button } from '@/components/shadcn-ui/button';\nimport { Label } from '@/components/shadcn-ui/label';\nimport { RadioGroup, RadioGroupItem } from '@/components/shadcn-ui/radio-group';\nimport { Canon } from '@sillsdev/scripture';\nimport { LocalizedStringValue } from 'platform-bible-utils';\nimport { useState } from 'react';\nimport ChapterRangeSelector, {\n ChapterRangeSelectorProps,\n} from '../basics/chapter-range-selector.component';\n\nexport enum BookSelectionMode {\n CURRENT_BOOK = 'current book',\n CHOOSE_BOOKS = 'choose books',\n}\n\n/**\n * Object containing all keys used for localization in this component. If you're using this\n * component in an extension, you can pass it into the useLocalizedStrings hook to easily obtain the\n * localized strings and pass them into the localizedStrings prop of this component\n */\nexport const BOOK_SELECTOR_STRING_KEYS = Object.freeze([\n '%webView_bookSelector_currentBook%',\n '%webView_bookSelector_choose%',\n '%webView_bookSelector_chooseBooks%',\n] as const);\n\nexport type BookSelectorLocalizedStrings = {\n [localizedInventoryKey in (typeof BOOK_SELECTOR_STRING_KEYS)[number]]?: LocalizedStringValue;\n};\n\n/**\n * Gets the localized value for the provided key\n *\n * @param strings Object containing localized string\n * @param key Key for a localized string\n * @returns The localized value for the provided key, if available. Returns the key if no localized\n * value is available\n */\nconst localizeString = (\n strings: BookSelectorLocalizedStrings,\n key: keyof BookSelectorLocalizedStrings,\n) => {\n return strings[key] ?? key;\n};\n\ntype BookSelectorProps = ChapterRangeSelectorProps & {\n handleBookSelectionModeChange: (newMode: BookSelectionMode) => void;\n currentBookName: string;\n onSelectBooks: () => void;\n selectedBookIds: string[];\n localizedStrings: BookSelectorLocalizedStrings;\n};\n\nexport default function BookSelector({\n handleBookSelectionModeChange,\n currentBookName,\n onSelectBooks,\n selectedBookIds,\n chapterCount,\n endChapter,\n handleSelectEndChapter,\n startChapter,\n handleSelectStartChapter,\n localizedStrings,\n}: BookSelectorProps) {\n const currentBookText = localizeString(localizedStrings, '%webView_bookSelector_currentBook%');\n const chooseText = localizeString(localizedStrings, '%webView_bookSelector_choose%');\n const chooseBooksText = localizeString(localizedStrings, '%webView_bookSelector_chooseBooks%');\n\n const [bookSelectionMode, setBookSelectionMode] = useState(\n BookSelectionMode.CURRENT_BOOK,\n );\n\n const onSelectionModeChange = (newMode: BookSelectionMode) => {\n setBookSelectionMode(newMode);\n handleBookSelectionModeChange(newMode);\n };\n\n return (\n onSelectionModeChange(value as BookSelectionMode)}\n >\n
    \n
    \n
    \n \n \n
    \n \n
    \n \n
    \n
    \n
    \n
    \n \n \n
    \n \n onSelectBooks()}\n >\n {chooseText}\n \n
    \n
    \n \n );\n}\n","import { DropdownMenuTrigger } from '@radix-ui/react-dropdown-menu';\nimport { FilterIcon } from 'lucide-react';\nimport { Table } from '@tanstack/react-table';\n\nimport { Button } from '@/components/shadcn-ui/button';\nimport {\n DropdownMenu,\n DropdownMenuCheckboxItem,\n DropdownMenuContent,\n DropdownMenuLabel,\n DropdownMenuSeparator,\n} from '@/components/shadcn-ui/dropdown-menu';\n\ninterface DataTableViewOptionsProps {\n table: Table;\n}\n\nfunction DataTableViewOptions({ table }: DataTableViewOptionsProps) {\n return (\n \n \n \n \n \n Toggle columns\n \n {table\n .getAllColumns()\n .filter((column) => column.getCanHide())\n .map((column) => {\n return (\n column.toggleVisibility(!!value)}\n >\n {column.id}\n \n );\n })}\n \n \n );\n}\n\nexport default DataTableViewOptions;\n","import React from 'react';\nimport * as SelectPrimitive from '@radix-ui/react-select';\nimport { Check, ChevronDown, ChevronUp } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Select = SelectPrimitive.Root;\n\nconst SelectGroup = SelectPrimitive.Group;\n\nconst SelectValue = SelectPrimitive.Value;\n\nconst SelectTrigger = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, ...props }, ref) => (\n span]:tw-line-clamp-1',\n className,\n )}\n {...props}\n >\n {children}\n \n \n \n \n));\nSelectTrigger.displayName = SelectPrimitive.Trigger.displayName;\n\nconst SelectScrollUpButton = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n));\nSelectScrollUpButton.displayName = SelectPrimitive.ScrollUpButton.displayName;\n\nconst SelectScrollDownButton = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n));\nSelectScrollDownButton.displayName = SelectPrimitive.ScrollDownButton.displayName;\n\nconst SelectContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, position = 'popper', ...props }, ref) => (\n \n \n \n \n {children}\n \n \n \n \n));\nSelectContent.displayName = SelectPrimitive.Content.displayName;\n\nconst SelectLabel = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSelectLabel.displayName = SelectPrimitive.Label.displayName;\n\nconst SelectItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, ...props }, ref) => (\n \n \n \n \n \n \n\n {children}\n \n));\nSelectItem.displayName = SelectPrimitive.Item.displayName;\n\nconst SelectSeparator = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSelectSeparator.displayName = SelectPrimitive.Separator.displayName;\n\nexport {\n Select,\n SelectGroup,\n SelectValue,\n SelectTrigger,\n SelectContent,\n SelectLabel,\n SelectItem,\n SelectSeparator,\n SelectScrollUpButton,\n SelectScrollDownButton,\n};\n","import { ChevronLeftIcon, ChevronRightIcon, ArrowLeftIcon, ArrowRightIcon } from 'lucide-react';\nimport { Table } from '@tanstack/react-table';\n\nimport { Button } from '@/components/shadcn-ui/button';\nimport {\n Select,\n SelectContent,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\n\ninterface DataTablePaginationProps {\n table: Table;\n}\n\nfunction DataTablePagination({ table }: DataTablePaginationProps) {\n return (\n
    \n
    \n
    \n {table.getFilteredSelectedRowModel().rows.length} of{' '}\n {table.getFilteredRowModel().rows.length} row(s) selected\n
    \n
    \n

    Rows per page

    \n {\n table.setPageSize(Number(value));\n }}\n >\n \n \n \n \n {[10, 20, 30, 40, 50].map((pageSize) => (\n \n {pageSize}\n \n ))}\n \n \n
    \n
    \n Page {table.getState().pagination.pageIndex + 1} of {table.getPageCount()}\n
    \n
    \n table.setPageIndex(0)}\n disabled={!table.getCanPreviousPage()}\n >\n Go to first page\n \n \n table.previousPage()}\n disabled={!table.getCanPreviousPage()}\n >\n Go to previous page\n \n \n table.nextPage()}\n disabled={!table.getCanNextPage()}\n >\n Go to next page\n \n \n table.setPageIndex(table.getPageCount() - 1)}\n disabled={!table.getCanNextPage()}\n >\n Go to last page\n \n \n
    \n
    \n
    \n );\n}\n\nexport default DataTablePagination;\n","import React from 'react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Table = React.forwardRef<\n HTMLTableElement,\n React.HTMLAttributes & { stickyHeader?: boolean }\n>(({ className, stickyHeader, ...props }, ref) => (\n
    \n \n
    \n));\nTable.displayName = 'Table';\n\nconst TableHeader = React.forwardRef<\n HTMLTableSectionElement,\n React.HTMLAttributes & { stickyHeader?: boolean }\n>(({ className, stickyHeader, ...props }, ref) => (\n \n));\nTableHeader.displayName = 'TableHeader';\n\nconst TableBody = React.forwardRef<\n HTMLTableSectionElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableBody.displayName = 'TableBody';\n\nconst TableFooter = React.forwardRef<\n HTMLTableSectionElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n tr]:last:tw-border-b-0', className)}\n {...props}\n />\n));\nTableFooter.displayName = 'TableFooter';\n\nconst TableRow = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nTableRow.displayName = 'TableRow';\n\nconst TableHead = React.forwardRef<\n HTMLTableCellElement,\n React.ThHTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableHead.displayName = 'TableHead';\n\nconst TableCell = React.forwardRef<\n HTMLTableCellElement,\n React.TdHTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableCell.displayName = 'TableCell';\n\nconst TableCaption = React.forwardRef<\n HTMLTableCaptionElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableCaption.displayName = 'TableCaption';\n\nexport { Table, TableHeader, TableBody, TableFooter, TableHead, TableRow, TableCell, TableCaption };\n","import { useState } from 'react';\n\nimport {\n ColumnFiltersState,\n flexRender,\n getCoreRowModel,\n getFilteredRowModel,\n getPaginationRowModel,\n getSortedRowModel,\n SortingState,\n ColumnDef as TSColumnDef,\n Row as TSRow,\n RowSelectionState as TSRowSelectionState,\n SortDirection as TSSortDirection,\n Table as TSTable,\n useReactTable,\n VisibilityState,\n} from '@tanstack/react-table';\n\nimport DataTableViewOptions from '@/components/advanced/data-table/data-table-column-toggle.component';\nimport DataTablePagination from '@/components/advanced/data-table/data-table-pagination.component';\nimport { Button } from '@/components/shadcn-ui/button';\nimport {\n Table,\n TableBody,\n TableCell,\n TableHead,\n TableHeader,\n TableRow,\n} from '@/components/shadcn-ui/table';\n\nexport type ColumnDef = TSColumnDef;\nexport type RowContents = TSRow;\nexport type TableContents = TSTable;\nexport type SortDirection = TSSortDirection;\nexport type RowSelectionState = TSRowSelectionState;\n\ninterface DataTableProps {\n columns: ColumnDef[];\n data: TData[];\n enablePagination?: boolean;\n showPaginationControls?: boolean;\n showColumnVisibilityControls?: boolean;\n stickyHeader?: boolean;\n onRowClickHandler?: (row: RowContents, table: TableContents) => void;\n}\n\n/**\n * Feature-rich table component that infuses our basic shadcn-based Table component with features\n * from TanStack's React Table library\n */\nfunction DataTable({\n columns,\n data,\n enablePagination = false,\n showPaginationControls = false,\n showColumnVisibilityControls = false,\n stickyHeader = false,\n onRowClickHandler = () => {},\n}: DataTableProps) {\n const [sorting, setSorting] = useState([]);\n const [columnFilters, setColumnFilters] = useState([]);\n const [columnVisibility, setColumnVisibility] = useState({});\n const [rowSelection, setRowSelection] = useState({});\n\n const table = useReactTable({\n data,\n columns,\n getCoreRowModel: getCoreRowModel(),\n ...(enablePagination && { getPaginationRowModel: getPaginationRowModel() }),\n onSortingChange: setSorting,\n getSortedRowModel: getSortedRowModel(),\n onColumnFiltersChange: setColumnFilters,\n getFilteredRowModel: getFilteredRowModel(),\n onColumnVisibilityChange: setColumnVisibility,\n onRowSelectionChange: setRowSelection,\n state: {\n sorting,\n columnFilters,\n columnVisibility,\n rowSelection,\n },\n });\n\n return (\n
    \n {showColumnVisibilityControls && }\n \n \n {table.getHeaderGroups().map((headerGroup) => (\n \n {headerGroup.headers.map((header) => {\n return (\n \n {header.isPlaceholder\n ? undefined\n : flexRender(header.column.columnDef.header, header.getContext())}\n \n );\n })}\n \n ))}\n \n \n {table.getRowModel().rows?.length ? (\n table.getRowModel().rows.map((row) => (\n onRowClickHandler(row, table)}\n key={row.id}\n data-state={row.getIsSelected() && 'selected'}\n >\n {row.getVisibleCells().map((cell) => (\n \n {flexRender(cell.column.columnDef.cell, cell.getContext())}\n \n ))}\n \n ))\n ) : (\n \n \n No results.\n \n \n )}\n \n
    \n {enablePagination && (\n
    \n table.previousPage()}\n disabled={!table.getCanPreviousPage()}\n >\n Previous\n \n table.nextPage()}\n disabled={!table.getCanNextPage()}\n >\n Next\n \n
    \n )}\n {enablePagination && showPaginationControls && }\n
    \n );\n}\n\nexport default DataTable;\n","import {\n Table,\n TableBody,\n TableCell,\n TableHead,\n TableHeader,\n TableRow,\n} from '@/components/shadcn-ui/table';\nimport { Canon } from '@sillsdev/scripture';\nimport { deepEqual, LanguageStrings, ScriptureReference } from 'platform-bible-utils';\nimport { useMemo } from 'react';\nimport { InventoryItemOccurrence } from './inventory-utils';\n\n/** Props for the OccurrencesTable component */\ntype OccurrencesTableProps = {\n /** Data that contains scriptures references and snippets of scripture */\n occurrenceData: InventoryItemOccurrence[];\n /** Callback function that is executed when the scripture reference is changed */\n setScriptureReference: (scriptureReference: ScriptureReference) => void;\n /**\n * Object with all localized strings that the OccurrencesTable needs to work well across multiple\n * languages\n */\n localizedStrings: LanguageStrings;\n};\n\n/**\n * Table that shows occurrences of specified inventory item(s). The first column shows the related\n * scripture reference. The second column shows the snippet of scripture that contains the specified\n * inventory item\n */\nfunction OccurrencesTable({\n occurrenceData,\n setScriptureReference,\n localizedStrings,\n}: OccurrencesTableProps) {\n const referenceHeaderText =\n localizedStrings['%webView_inventory_occurrences_table_header_reference%'];\n const occurrenceHeaderText =\n localizedStrings['%webView_inventory_occurrences_table_header_occurrence%'];\n\n const occurrences: InventoryItemOccurrence[] = useMemo(() => {\n const uniqueOccurrences: InventoryItemOccurrence[] = [];\n\n occurrenceData.forEach((occurrence) => {\n if (!uniqueOccurrences.some((uniqueOccurrence) => deepEqual(uniqueOccurrence, occurrence))) {\n uniqueOccurrences.push(occurrence);\n }\n });\n\n return uniqueOccurrences;\n }, [occurrenceData]);\n\n return (\n \n \n \n {referenceHeaderText}\n {occurrenceHeaderText}\n \n \n \n {occurrences.length > 0 &&\n occurrences.map((occurrence) => (\n {\n setScriptureReference(occurrence.reference);\n }}\n >\n {`${Canon.bookNumberToEnglishName(occurrence.reference.bookNum)} ${occurrence.reference.chapterNum}:${occurrence.reference.verseNum}`}\n {occurrence.text}\n \n ))}\n \n
    \n );\n}\n\nexport default OccurrencesTable;\n","import React from 'react';\nimport * as CheckboxPrimitive from '@radix-ui/react-checkbox';\nimport { Check } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Checkbox = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n \n \n));\nCheckbox.displayName = CheckboxPrimitive.Root.displayName;\n\nexport default Checkbox;\n","import { Canon } from '@sillsdev/scripture';\nimport { ScriptureReference } from 'platform-bible-utils';\n\n/* #region Types */\n\n/**\n * Status of items that appear in inventories. 'approved' and 'unapproved' items are defined in the\n * project's `Settings.xml`. All other items are defined as 'unknown'\n */\nexport type Status = 'approved' | 'unapproved' | 'unknown';\n\n/** Occurrence of item in inventory. Primarily used by table that shows occurrences */\nexport type InventoryItemOccurrence = {\n /** Reference to scripture where the item appears */\n reference: ScriptureReference;\n /** Snippet of scripture that contains the occurrence */\n text: string;\n};\n\n/** Data structure that contains all information on an item that is shown in an inventory */\nexport type InventoryTableData = {\n /**\n * The item (e.g. a character in the characters inventory, a marker in the marker inventory) In\n * most cases the array will only have one element. In case of additional items (e.g. the\n * preceding marker in the markers check), the primary item should be stored in the first index.\n * To show additional items in the inventory, make sure to configure the `additionalItemsLabels`\n * prop for the Inventory component\n */\n items: string[];\n /** The number of times this item occurs in the selected scope */\n count: number;\n /** The status of this item (see documentation for `Status` type for more information) */\n status: Status;\n /** Occurrences of this item in the scripture text for the selected scope */\n occurrences: InventoryItemOccurrence[];\n};\n\n/* #endregion */\n\n/* #region Functions */\n\n/**\n * Splits USFM string into shorter line-like segments\n *\n * @param text A single (likely very large) USFM string\n * @returns An array containing the input text, split into shorter segments\n */\nexport const getLinesFromUSFM = (text: string) => {\n // Splits on (CR)LF, CR, \\v, \\c and \\id\n return text.split(/(?:\\r?\\n|\\r)|(?=(?:\\\\(?:v|c|id)))/g);\n};\n\n/**\n * Extracts chapter or verse number from USFM strings that start with a \\c or \\v marker\n *\n * @param text USFM string that is expected to start with \\c or \\v marker\n * @returns Chapter or verse number if one is found. Else returns 0.\n */\nexport const getNumberFromUSFM = (text: string): number | undefined => {\n // Captures all digits that follow \\v or \\c markers followed by whitespace located at the start of a string\n const regex = /^\\\\[vc]\\s+(\\d+)/;\n const match = text.match(regex);\n\n if (match) {\n return +match[1];\n }\n return undefined;\n};\n\n/**\n * Gets book ID from USFM string that starts with the \\id marker, and returns book number for it\n *\n * @param text USFM string that is expected to start with \\id marker\n * @returns Book number corresponding to the \\id marker in the input text. Returns 0 if no marker is\n * found or the marker is not valid\n */\nexport const getBookNumFromId = (text: string): number => {\n // Captures all digits that follow an \\id marker followed by whitespace located at the start of a string\n const match = text.match(/^\\\\id\\s+([A-Za-z]+)/);\n if (match) {\n return Canon.bookIdToNumber(match[1]);\n }\n return 0;\n};\n\n/**\n * Gets the status for an item, typically used in the Inventory component\n *\n * @param item The item for which the status is being requested\n * @param approvedItems Array of approved items, typically as defined in `Settings.xml`\n * @param unapprovedItems Array of unapproved items, typically as defined in `Settings.xml`\n * @returns The status for the specified item\n */\nexport const getStatusForItem = (\n item: string,\n approvedItems: string[],\n unapprovedItems: string[],\n): Status => {\n if (unapprovedItems.includes(item)) return 'unapproved';\n if (approvedItems.includes(item)) return 'approved';\n return 'unknown';\n};\n\n/* #endregion */\n","import React from 'react';\nimport * as TogglePrimitive from '@radix-ui/react-toggle';\nimport { cva, type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst toggleVariants = cva(\n 'pr-twp tw-inline-flex tw-items-center tw-justify-center tw-rounded-md tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-colors hover:tw-bg-muted hover:tw-text-muted-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50 data-[state=on]:tw-bg-accent data-[state=on]:tw-text-accent-foreground',\n {\n variants: {\n variant: {\n default: 'tw-bg-transparent',\n outline:\n 'tw-border tw-border-input tw-bg-transparent hover:tw-bg-accent hover:tw-text-accent-foreground',\n },\n size: {\n default: 'tw-h-10 tw-px-3',\n sm: 'tw-h-9 tw-px-2.5',\n lg: 'tw-h-11 tw-px-5',\n },\n },\n defaultVariants: {\n variant: 'default',\n size: 'default',\n },\n },\n);\n\nconst Toggle = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef & VariantProps\n>(({ className, variant, size, ...props }, ref) => (\n \n));\n\nToggle.displayName = TogglePrimitive.Root.displayName;\n\nexport { Toggle, toggleVariants };\n","import React from 'react';\nimport * as ToggleGroupPrimitive from '@radix-ui/react-toggle-group';\nimport { type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { toggleVariants } from '@/components/shadcn-ui/toggle';\n\nconst ToggleGroupContext = React.createContext>({\n size: 'default',\n variant: 'default',\n});\n\nconst ToggleGroup = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef &\n VariantProps\n>(({ className, variant, size, children, ...props }, ref) => (\n \n \n {children}\n \n \n));\n\nToggleGroup.displayName = ToggleGroupPrimitive.Root.displayName;\n\nconst ToggleGroupItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef &\n VariantProps\n>(({ className, children, variant, size, ...props }, ref) => {\n const context = React.useContext(ToggleGroupContext);\n\n return (\n \n {children}\n \n );\n});\n\nToggleGroupItem.displayName = ToggleGroupPrimitive.Item.displayName;\n\nexport { ToggleGroup, ToggleGroupItem };\n","import { ColumnDef, SortDirection } from '@/components/advanced/data-table/data-table.component';\nimport { Button } from '@/components/shadcn-ui/button';\nimport { ToggleGroup, ToggleGroupItem } from '@/components/shadcn-ui/toggle-group';\nimport {\n ArrowDownIcon,\n ArrowUpDownIcon,\n ArrowUpIcon,\n CircleCheckIcon,\n CircleHelpIcon,\n CircleXIcon,\n} from 'lucide-react';\nimport { ReactNode } from 'react';\nimport { InventoryTableData, Status } from './inventory-utils';\n\n/**\n * Gets an icon that indicates the current sorting direction based on the provided input\n *\n * @param sortDirection Sorting direction. Can be ascending ('asc'), descending ('desc') or false (\n * i.e. not sorted)\n * @returns The appropriate sorting icon for the provided sorting direction\n */\nconst getSortingIcon = (sortDirection: false | SortDirection): ReactNode => {\n if (sortDirection === 'asc') {\n return ;\n }\n if (sortDirection === 'desc') {\n return ;\n }\n return ;\n};\n\n/**\n * Function that creates the item column for inventories\n *\n * @param itemLabel Localized label for the item column (e.g. 'Character', 'Repeated Word', etc.)\n * @returns Column that shows the inventory items. Should be used with the DataTable component\n */\nexport const inventoryItemColumn = (itemLabel: string): ColumnDef => {\n return {\n accessorKey: 'item',\n accessorFn: (row: InventoryTableData) => row.items[0],\n header: ({ column }) => (\n \n ),\n };\n};\n\n/**\n * Function that creates the additional item columns for inventories\n *\n * @param additionalItemLabel Localized label for the additional item column (e.g. 'Preceding\n * Marker')\n * @param additionalItemIndex Index that locates the desired item in the items array of the\n * inventory\n * @returns Column that shows additional inventory items. Should be used with the DataTable\n * component\n */\nexport const inventoryAdditionalItemColumn = (\n additionalItemLabel: string,\n additionalItemIndex: number,\n): ColumnDef => {\n return {\n accessorKey: `item${additionalItemIndex}`,\n accessorFn: (row: InventoryTableData) => row.items[additionalItemIndex],\n header: ({ column }) => (\n \n ),\n };\n};\n\n/**\n * Function that creates the count column for inventories. Should be used with the DataTable\n * component.\n *\n * @param itemLabel Localized label for the count column\n * @returns Column that shows the number of occurrences of the related inventory items\n */\nexport const inventoryCountColumn = (countLabel: string): ColumnDef => {\n return {\n accessorKey: 'count',\n header: ({ column }) => (\n
    \n \n
    \n ),\n cell: ({ row }) =>
    {row.getValue('count')}
    ,\n };\n};\n\n/**\n * Function that updates project settings when status for item(s) changes\n *\n * @param changedItems Array of items for which the status is being updated\n * @param newStatus The status that the items are being given\n * @param approvedItems Array of currently approved items\n * @param onApprovedItemsChange Callback function that stores the updated list of approved items\n * @param unapprovedItems Array of currently unapproved items\n * @param onUnapprovedItemsChange Callback function that stores the updated list of unapproved items\n */\nconst statusChangeHandler = (\n changedItems: string[],\n newStatus: Status,\n approvedItems: string[],\n onApprovedItemsChange: (items: string[]) => void,\n unapprovedItems: string[],\n onUnapprovedItemsChange: (items: string[]) => void,\n) => {\n let newApprovedItems: string[] = [...approvedItems];\n changedItems.forEach((item) => {\n if (newStatus === 'approved') {\n if (!newApprovedItems.includes(item)) {\n newApprovedItems.push(item);\n }\n } else {\n newApprovedItems = newApprovedItems.filter((validItem) => validItem !== item);\n }\n });\n onApprovedItemsChange(newApprovedItems);\n\n let newUnapprovedItems: string[] = [...unapprovedItems];\n changedItems.forEach((item) => {\n if (newStatus === 'unapproved') {\n if (!newUnapprovedItems.includes(item)) {\n newUnapprovedItems.push(item);\n }\n } else {\n newUnapprovedItems = newUnapprovedItems.filter((unapprovedItem) => unapprovedItem !== item);\n }\n });\n onUnapprovedItemsChange(newUnapprovedItems);\n};\n\n/**\n * Function that creates the status column for inventories. Should be used with the DataTable\n * component.\n *\n * @param statusLabel Localized label for the status column\n * @param approvedItems Array of approved items, typically as defined in `Settings.xml`\n * @param onApprovedItemsChange Callback function that stores the updated list of approved items\n * @param unapprovedItems Array of unapproved items, typically as defined in `Settings.xml`\n * @param onUnapprovedItemsChange Callback function that stores the updated list of unapproved items\n * @returns Column that shows the status buttons for the related inventory item. The button for the\n * current status of the item is selected\n */\nexport const inventoryStatusColumn = (\n statusLabel: string,\n approvedItems: string[],\n onApprovedItemsChange: (items: string[]) => void,\n unapprovedItems: string[],\n onUnapprovedItemsChange: (items: string[]) => void,\n): ColumnDef => {\n return {\n accessorKey: 'status',\n header: ({ column }) => {\n return (\n
    \n \n
    \n );\n },\n cell: ({ row }) => {\n const status: Status = row.getValue('status');\n const item: string = row.getValue('item');\n return (\n \n \n statusChangeHandler(\n [item],\n 'approved',\n approvedItems,\n onApprovedItemsChange,\n unapprovedItems,\n onUnapprovedItemsChange,\n )\n }\n value=\"approved\"\n >\n \n \n \n statusChangeHandler(\n [item],\n 'unapproved',\n approvedItems,\n onApprovedItemsChange,\n unapprovedItems,\n onUnapprovedItemsChange,\n )\n }\n value=\"unapproved\"\n >\n \n \n \n statusChangeHandler(\n [item],\n 'unknown',\n approvedItems,\n onApprovedItemsChange,\n unapprovedItems,\n onUnapprovedItemsChange,\n )\n }\n value=\"unknown\"\n >\n \n \n \n );\n },\n };\n};\n","import DataTable, {\n ColumnDef,\n RowContents,\n RowSelectionState,\n TableContents,\n} from '@/components/advanced/data-table/data-table.component';\nimport OccurrencesTable from '@/components/advanced/inventory/occurrences-table.component';\nimport Checkbox from '@/components/shadcn-ui/checkbox';\nimport { Input } from '@/components/shadcn-ui/input';\nimport { Label } from '@/components/shadcn-ui/label';\nimport {\n Select,\n SelectContent,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\nimport {\n deepEqual,\n LocalizedStringValue,\n ScriptureReference,\n substring,\n} from 'platform-bible-utils';\nimport { useEffect, useMemo, useState } from 'react';\nimport {\n getBookNumFromId,\n getLinesFromUSFM,\n getNumberFromUSFM,\n getStatusForItem,\n InventoryItemOccurrence,\n InventoryTableData,\n Status,\n} from './inventory-utils';\nimport { inventoryAdditionalItemColumn } from './inventory-columns';\n\n/**\n * Object containing all keys used for localization in this component. If you're using this\n * component in an extension, you can pass it into the useLocalizedStrings hook to easily obtain the\n * localized strings and pass them into the localizedStrings prop of this component\n */\nexport const INVENTORY_STRING_KEYS = Object.freeze([\n '%webView_inventory_all%',\n '%webView_inventory_approved%',\n '%webView_inventory_unapproved%',\n '%webView_inventory_unknown%',\n '%webView_inventory_scope_currentBook%',\n '%webView_inventory_scope_chapter%',\n '%webView_inventory_scope_verse%',\n '%webView_inventory_filter_text%',\n '%webView_inventory_show_additional_items%',\n '%webView_inventory_occurrences_table_header_reference%',\n '%webView_inventory_occurrences_table_header_occurrence%',\n] as const);\n\nexport type InventoryLocalizedStrings = {\n [localizedInventoryKey in (typeof INVENTORY_STRING_KEYS)[number]]?: LocalizedStringValue;\n};\n\n/** Scope of scripture that the inventory can operate on */\nexport type Scope = 'book' | 'chapter' | 'verse';\n\n/** Status values that the status filter can select from */\ntype StatusFilter = Status | 'all';\n\n/** Text labels for the inventory columns and the control components of additional inventory items */\ntype AdditionalItemsLabels = {\n checkboxText?: string;\n tableHeaders?: string[];\n};\n\n/**\n * Filters data that is shown in the DataTable section of the Inventory\n *\n * @param itemData All inventory items and their related information\n * @param statusFilter Allows filtering by status (i.e. show all items, or only items that are\n * 'approved', 'unapproved' or 'unknown')\n * @param textFilter Allows filtering by text. All items that include the filter text will be\n * selected.\n * @returns Array of items and their related information that are matched by the specified filters\n */\nconst filterItemData = (\n itemData: InventoryTableData[],\n statusFilter: StatusFilter,\n textFilter: string,\n): InventoryTableData[] => {\n let filteredItemData: InventoryTableData[] = itemData;\n\n if (statusFilter !== 'all') {\n filteredItemData = filteredItemData.filter(\n (item) =>\n (statusFilter === 'approved' && item.status === 'approved') ||\n (statusFilter === 'unapproved' && item.status === 'unapproved') ||\n (statusFilter === 'unknown' && item.status === 'unknown'),\n );\n }\n\n if (textFilter !== '')\n filteredItemData = filteredItemData.filter((item) => item.items[0].includes(textFilter));\n\n return filteredItemData;\n};\n\n/**\n * Turns array of strings into array of inventory items, along with their count and status\n *\n * @param text The source scripture text that is searched for inventory items\n * @param scriptureRef The scripture reference that the application is currently set to\n * @param approvedItems Array of approved items, typically as defined in `Settings.xml`\n * @param unapprovedItems Array of unapproved items, typically as defined in `Settings.xml`\n * @param itemRegex Regular expression that describes what items this Inventory should extract from\n * the provided scripture text\n * @returns Array of inventory items, along with their count and status\n */\nconst createTableData = (\n text: string | undefined,\n scriptureRef: ScriptureReference,\n approvedItems: string[],\n unapprovedItems: string[],\n itemRegex: RegExp,\n): InventoryTableData[] => {\n if (!text) return [];\n\n const tableData: InventoryTableData[] = [];\n\n let currentBook: number | undefined = scriptureRef.bookNum;\n let currentChapter: number | undefined = scriptureRef.chapterNum;\n let currentVerse: number | undefined = scriptureRef.verseNum;\n\n const lines = getLinesFromUSFM(text);\n\n lines.forEach((line: string) => {\n if (line.startsWith('\\\\id')) {\n currentBook = getBookNumFromId(line);\n currentChapter = 0;\n currentVerse = 0;\n }\n if (line.startsWith('\\\\c')) {\n currentChapter = getNumberFromUSFM(line);\n currentVerse = 0;\n }\n if (line.startsWith('\\\\v')) {\n currentVerse = getNumberFromUSFM(line);\n if (currentChapter === 0) {\n currentChapter = scriptureRef.chapterNum;\n }\n }\n\n let match: RegExpExecArray | undefined = itemRegex.exec(line) ?? undefined;\n while (match) {\n const items: string[] = [];\n match.forEach((item) => items.push(item));\n const itemIndex = match.index;\n const existingItem = tableData.find((tableEntry) => deepEqual(tableEntry.items, items));\n const newReference: InventoryItemOccurrence = {\n reference: {\n bookNum: currentBook !== undefined ? currentBook : -1,\n chapterNum: currentChapter !== undefined ? currentChapter : -1,\n verseNum: currentVerse !== undefined ? currentVerse : -1,\n },\n text: substring(line, Math.max(0, itemIndex - 25), Math.min(itemIndex + 25, line.length)),\n };\n if (existingItem) {\n existingItem.count += 1;\n existingItem.occurrences.push(newReference);\n } else {\n const newItem: InventoryTableData = {\n items,\n count: 1,\n status: getStatusForItem(items[0], approvedItems, unapprovedItems),\n occurrences: [newReference],\n };\n tableData.push(newItem);\n }\n\n match = itemRegex.exec(line) ?? undefined;\n }\n });\n\n return tableData;\n};\n\n/**\n * Gets the localized value for the provided key\n *\n * @param strings Object containing localized string\n * @param key Key for a localized string\n * @returns The localized value for the provided key, if available. Returns the key if no localized\n * value is available\n */\nconst localizeString = (\n strings: InventoryLocalizedStrings,\n key: keyof InventoryLocalizedStrings,\n) => {\n return strings[key] ?? key;\n};\n\n/** Props for the Inventory component */\ntype InventoryProps = {\n /** The scripture reference that the application is currently set to */\n scriptureReference: ScriptureReference;\n /** Callback function that is executed when the scripture reference is changed */\n setScriptureReference: (scriptureReference: ScriptureReference) => void;\n /**\n * Object with all localized strings that the Inventory needs to work well across multiple\n * languages. When using this component with Platform.Bible, you can import\n * `INVENTORY_STRING_KEYS` from this library, pass it in to the Platform's localization hook, and\n * pass the localized keys that are returned by the hook into this prop.\n */\n localizedStrings: InventoryLocalizedStrings;\n /**\n * The logic that finds the desired items in the source text. This can either be a Regular\n * expression that captures one or multiple items (preferred), or a custom function that builds\n * and return an InventoryDataTable[] manually. Note: In case the logic captures more than one\n * item (i.e. InventoryTableData.items has a length greater than 1), you must provide text labels\n * for the related columns and control elements to show by setting the `additionalItemsLabels`\n * prop\n */\n extractItems:\n | RegExp\n | ((\n text: string | undefined,\n scriptureRef: ScriptureReference,\n approvedItems: string[],\n unapprovedItems: string[],\n ) => InventoryTableData[]);\n /**\n * Text labels for control elements and additional column headers in case your Inventory has more\n * than one item to show (e.g. The 'Preceding Marker' in the Markers Inventory)\n */\n additionalItemsLabels?: AdditionalItemsLabels;\n /** Array of approved items, typically as defined in `Settings.xml` */\n approvedItems: string[];\n /** Array of unapproved items, typically as defined in `Settings.xml` */\n unapprovedItems: string[];\n /** The source scripture text that is searched for in inventory items */\n text: string | undefined;\n /** Scope of scripture that the inventory will operate on */\n scope: Scope;\n /** Callback function that is executed when the scope is changed from the Inventory */\n onScopeChange: (scope: Scope) => void;\n /**\n * Column definitions for the Inventory data table. The most commonly used column definitions are\n * pre-configured for your convenience and can be imported (e.g. inventoryItemColumn,\n * inventoryAdditionalItemColumn inventoryCountColumn, and inventoryStatusColumn). If you need any\n * other columns you can add these yourself\n */\n columns: ColumnDef[];\n};\n\n/** Inventory component that is used to view and control the status of provided project settings */\nexport default function Inventory({\n scriptureReference,\n setScriptureReference,\n localizedStrings,\n extractItems,\n additionalItemsLabels,\n approvedItems,\n unapprovedItems,\n text,\n scope,\n onScopeChange,\n columns,\n}: InventoryProps) {\n const allItemsText = localizeString(localizedStrings, '%webView_inventory_all%');\n const approvedItemsText = localizeString(localizedStrings, '%webView_inventory_approved%');\n const unapprovedItemsText = localizeString(localizedStrings, '%webView_inventory_unapproved%');\n const unknownItemsText = localizeString(localizedStrings, '%webView_inventory_unknown%');\n const scopeBookText = localizeString(localizedStrings, '%webView_inventory_scope_currentBook%');\n const scopeChapterText = localizeString(localizedStrings, '%webView_inventory_scope_chapter%');\n const scopeVerseText = localizeString(localizedStrings, '%webView_inventory_scope_verse%');\n const filterText = localizeString(localizedStrings, '%webView_inventory_filter_text%');\n const showAdditionalItemsText = localizeString(\n localizedStrings,\n '%webView_inventory_show_additional_items%',\n );\n\n const [showAdditionalItems, setShowAdditionalItems] = useState(false);\n const [statusFilter, setStatusFilter] = useState('all');\n const [textFilter, setTextFilter] = useState('');\n const [selectedItem, setSelectedItem] = useState([]);\n\n const tableData: InventoryTableData[] = useMemo(() => {\n if (!text) return [];\n if (extractItems instanceof RegExp)\n return createTableData(\n text,\n scriptureReference,\n approvedItems,\n unapprovedItems,\n extractItems,\n );\n return extractItems(text, scriptureReference, approvedItems, unapprovedItems);\n }, [text, extractItems, scriptureReference, approvedItems, unapprovedItems]);\n\n const reducedTableData: InventoryTableData[] = useMemo(() => {\n if (showAdditionalItems) return tableData;\n\n const newTableData: InventoryTableData[] = [];\n\n tableData.forEach((tableEntry) => {\n const firstItem = tableEntry.items[0];\n\n const existingEntry = newTableData.find(\n (newTableEntry) => newTableEntry.items[0] === firstItem,\n );\n\n if (existingEntry) {\n existingEntry.count += tableEntry.count;\n existingEntry.occurrences = existingEntry.occurrences.concat(tableEntry.occurrences);\n } else {\n newTableData.push({\n items: [firstItem],\n count: tableEntry.count,\n occurrences: tableEntry.occurrences,\n status: tableEntry.status,\n });\n }\n });\n\n return newTableData;\n }, [showAdditionalItems, tableData]);\n\n const filteredTableData: InventoryTableData[] = useMemo(() => {\n return filterItemData(reducedTableData, statusFilter, textFilter);\n }, [reducedTableData, statusFilter, textFilter]);\n\n const allColumns: ColumnDef[] = useMemo(() => {\n if (!showAdditionalItems) return columns;\n\n const numberOfAdditionalItems = additionalItemsLabels?.tableHeaders?.length;\n if (!numberOfAdditionalItems) return columns;\n\n const additionalColumns: ColumnDef[] = [];\n\n for (let index = 0; index < numberOfAdditionalItems; index++) {\n additionalColumns.push(\n inventoryAdditionalItemColumn(\n additionalItemsLabels?.tableHeaders?.[index] || 'Additional Item',\n index + 1,\n ),\n );\n }\n\n return [...additionalColumns, ...columns];\n }, [additionalItemsLabels?.tableHeaders, columns, showAdditionalItems]);\n\n useEffect(() => {\n setSelectedItem([]);\n }, [filteredTableData]);\n\n const rowClickHandler = (\n row: RowContents,\n table: TableContents,\n ) => {\n table.setRowSelection(() => {\n const newSelection: RowSelectionState = {};\n newSelection[row.index] = true;\n return newSelection;\n });\n\n setSelectedItem(row.original.items);\n };\n\n const handleScopeChange = (value: string) => {\n if (value === 'book' || value === 'chapter' || value === 'verse') {\n onScopeChange(value);\n } else {\n throw new Error(`Invalid scope value: ${value}`);\n }\n };\n\n const handleStatusFilterChange = (value: string) => {\n if (value === 'all' || value === 'approved' || value === 'unapproved' || value === 'unknown') {\n setStatusFilter(value);\n } else {\n throw new Error(`Invalid status filter value: ${value}`);\n }\n };\n\n const occurrenceData: InventoryItemOccurrence[] = useMemo(() => {\n if (reducedTableData.length === 0 || selectedItem.length === 0) return [];\n const occurrence = reducedTableData.filter((tableEntry: InventoryTableData) => {\n return deepEqual(\n showAdditionalItems ? tableEntry.items : [tableEntry.items[0]],\n selectedItem,\n );\n });\n if (occurrence.length > 1) throw new Error('Selected item is not unique');\n return occurrence[0].occurrences;\n }, [selectedItem, showAdditionalItems, reducedTableData]);\n\n return (\n
    \n
    \n handleStatusFilterChange(value)}\n defaultValue={statusFilter}\n >\n \n \n \n \n {allItemsText}\n {approvedItemsText}\n {unapprovedItemsText}\n {unknownItemsText}\n \n \n \n {\n setTextFilter(event.target.value);\n }}\n />\n {additionalItemsLabels && (\n
    \n {\n setSelectedItem([]);\n setShowAdditionalItems(checked);\n }}\n />\n \n
    \n )}\n
    \n
    \n \n
    \n {occurrenceData.length > 0 && (\n
    \n \n
    \n )}\n
    \n );\n}\n","import { Input } from '@/components/shadcn-ui/input';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { useState } from 'react';\n\n/** Props for the SearchBar component. */\nexport type SearchBarProps = {\n /** Additional css classes to help with unique styling of the search bar */\n className?: string;\n /**\n * Callback fired to handle the search query when button pressed\n *\n * @param searchQuery\n */\n onSearch: (searchQuery: string) => void;\n\n /** Optional string that appears in the search bar without a search string */\n placeholder?: string;\n\n /** Optional boolean to set the input base to full width */\n isFullWidth?: boolean;\n};\n\nexport default function SearchBar({\n className,\n onSearch,\n placeholder,\n isFullWidth,\n}: SearchBarProps) {\n const [searchQuery, setSearchQuery] = useState('');\n\n const handleInputChange = (searchString: string) => {\n setSearchQuery(searchString);\n onSearch(searchString);\n };\n\n return (\n handleInputChange(e.target.value)}\n />\n );\n}\n","// adapted from: https://github.com/shadcn-ui/ui/discussions/752\n\n'use client';\n\nimport { TabsContentProps, TabsListProps, TabsTriggerProps } from '@/components/shadcn-ui/tabs';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport * as TabsPrimitive from '@radix-ui/react-tabs';\nimport React from 'react';\n\nexport type VerticalTabsProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport type LeftTabsTriggerProps = TabsTriggerProps & {\n value: string;\n ref?: React.Ref;\n};\n\nexport const VerticalTabs = React.forwardRef<\n React.ElementRef,\n VerticalTabsProps\n>(({ className, ...props }, ref) => (\n \n));\n\nVerticalTabs.displayName = TabsPrimitive.List.displayName;\n\nexport const VerticalTabsList = React.forwardRef<\n React.ElementRef,\n TabsListProps\n>(({ className, ...props }, ref) => (\n \n));\nVerticalTabsList.displayName = TabsPrimitive.List.displayName;\n\nexport const VerticalTabsTrigger = React.forwardRef<\n React.ElementRef,\n LeftTabsTriggerProps\n>(({ className, ...props }, ref) => (\n \n));\n\nexport const VerticalTabsContent = React.forwardRef<\n React.ElementRef,\n TabsContentProps\n>(({ className, ...props }, ref) => (\n \n));\nVerticalTabsContent.displayName = TabsPrimitive.Content.displayName;\n","import SearchBar from '@/components/basics/search-bar.component';\nimport {\n VerticalTabs,\n VerticalTabsContent,\n VerticalTabsList,\n VerticalTabsTrigger,\n} from '@/components/basics/tabs-vertical';\nimport { ReactNode } from 'react';\n\nexport type TabKeyValueContent = {\n key: string;\n value: string;\n content: ReactNode;\n};\n\nexport type TabNavigationContentSearchProps = {\n /** List of values and keys for each tab this component should provide */\n tabList: TabKeyValueContent[];\n\n /** Handler to run when the value of the search bar changes */\n onSearch: (searchQuery: string) => void;\n\n /** Optional placeholder for the search bar */\n searchPlaceholder?: string;\n\n /** Optional title to include in the header */\n headerTitle?: string;\n\n /** Optional flag to make the search bar appear full width */\n isSearchBarFullWidth?: boolean;\n\n /** Text direction ltr or rtl */\n direction?: 'ltr' | 'rtl';\n};\n\nexport default function TabNavigationContentSearch({\n tabList,\n onSearch,\n searchPlaceholder,\n headerTitle,\n isSearchBarFullWidth = false,\n direction = 'ltr',\n}: TabNavigationContentSearchProps) {\n return (\n
    \n
    \n {headerTitle ?

    {headerTitle}

    : ''}\n \n
    \n \n \n {tabList.map((tab) => (\n \n {tab.value}\n \n ))}\n \n {tabList.map((tab) => (\n \n {tab.content}\n \n ))}\n \n
    \n );\n}\n","import React from 'react';\nimport * as SeparatorPrimitive from '@radix-ui/react-separator';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Separator = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, orientation = 'horizontal', decorative = true, ...props }, ref) => (\n \n));\nSeparator.displayName = SeparatorPrimitive.Root.displayName;\n\nexport { Separator };\n","import React from 'react';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nfunction Skeleton({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\n\nexport { Skeleton };\n","import React from 'react';\nimport * as TooltipPrimitive from '@radix-ui/react-tooltip';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst TooltipProvider = TooltipPrimitive.Provider;\n\nconst Tooltip = TooltipPrimitive.Root;\n\nconst TooltipTrigger = TooltipPrimitive.Trigger;\n\nconst TooltipContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, sideOffset = 4, ...props }, ref) => (\n \n));\nTooltipContent.displayName = TooltipPrimitive.Content.displayName;\n\nexport { Tooltip, TooltipTrigger, TooltipContent, TooltipProvider };\n","import React from 'react';\nimport { Slot } from '@radix-ui/react-slot';\nimport { VariantProps, cva } from 'class-variance-authority';\nimport { PanelLeft } from 'lucide-react';\n\nimport { Button } from '@/components/shadcn-ui/button';\nimport { Input } from '@/components/shadcn-ui/input';\nimport { Separator } from '@/components/shadcn-ui/separator';\nimport { Skeleton } from '@/components/shadcn-ui/skeleton';\nimport {\n Tooltip,\n TooltipContent,\n TooltipProvider,\n TooltipTrigger,\n} from '@/components/shadcn-ui/tooltip';\nimport { cn } from '@/utils/shadcn-ui.util';\n\n/**\n * Changes from the original code from Shadcn- Removed uses of useIsMobile, Sheet, and SheetContent.\n * Also removed the parts setting COOKIES.\n */\n\nconst SIDEBAR_WIDTH = '16rem';\nconst SIDEBAR_WIDTH_ICON = '3rem';\n// Commented this out pending a discussion with UX about keyboard shortcuts\n// const SIDEBAR_KEYBOARD_SHORTCUT = 'b';\n\ntype SidebarContextProps = {\n state: 'expanded' | 'collapsed';\n open: boolean;\n setOpen: (open: boolean) => void;\n toggleSidebar: () => void;\n};\n\nconst SidebarContext = React.createContext(undefined);\n\nfunction useSidebar() {\n const context = React.useContext(SidebarContext);\n if (!context) {\n throw new Error('useSidebar must be used within a SidebarProvider.');\n }\n\n return context;\n}\n\nconst SidebarProvider = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & {\n defaultOpen?: boolean;\n open?: boolean;\n onOpenChange?: (open: boolean) => void;\n }\n>(\n (\n {\n defaultOpen = true,\n open: openProp,\n onOpenChange: setOpenProp,\n className,\n style,\n children,\n ...props\n },\n ref,\n ) => {\n // This is the internal state of the sidebar.\n // We use openProp and setOpenProp for control from outside the component.\n const [_open, _setOpen] = React.useState(defaultOpen);\n const isOpen = openProp ?? _open;\n const setOpen = React.useCallback(\n (value: boolean | ((value: boolean) => boolean)) => {\n const openState = typeof value === 'function' ? value(isOpen) : value;\n if (setOpenProp) {\n setOpenProp(openState);\n } else {\n _setOpen(openState);\n }\n },\n [setOpenProp, isOpen],\n );\n\n // Helper to toggle the sidebar.\n const toggleSidebar = React.useCallback(() => {\n return setOpen((open) => !open);\n }, [setOpen]);\n\n // Commented this out pending a discussion with UX about keyboard shortcuts\n // Adds a keyboard shortcut to toggle the sidebar.\n // React.useEffect(() => {\n // const handleKeyDown = (event: KeyboardEvent) => {\n // if (event.key === SIDEBAR_KEYBOARD_SHORTCUT && (event.metaKey || event.ctrlKey)) {\n // event.preventDefault();\n // toggleSidebar();\n // }\n // };\n\n // window.addEventListener('keydown', handleKeyDown);\n // return () => window.removeEventListener('keydown', handleKeyDown);\n // }, [toggleSidebar]);\n\n // We add a state so that we can do data-state=\"expanded\" or \"collapsed\".\n // This makes it easier to style the sidebar with Tailwind classes.\n const state = isOpen ? 'expanded' : 'collapsed';\n\n const contextValue = React.useMemo(\n () => ({\n state,\n open: isOpen,\n setOpen,\n toggleSidebar,\n }),\n [state, isOpen, setOpen, toggleSidebar],\n );\n\n return (\n \n \n \n {children}\n
    \n \n \n );\n },\n);\nSidebarProvider.displayName = 'SidebarProvider';\n\nconst Sidebar = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & {\n side?: 'left' | 'right';\n variant?: 'sidebar' | 'floating' | 'inset';\n collapsible?: 'offcanvas' | 'icon' | 'none';\n }\n>(\n (\n {\n side = 'left',\n variant = 'sidebar',\n collapsible = 'offcanvas',\n className,\n children,\n ...props\n },\n ref,\n ) => {\n const { state } = useSidebar();\n\n if (collapsible === 'none') {\n return (\n \n {children}\n
    \n );\n }\n\n return (\n \n {/* This is what handles the sidebar gap on desktop */}\n \n \n \n {children}\n
    \n
    \n
    \n );\n },\n);\nSidebar.displayName = 'Sidebar';\n\nconst SidebarTrigger = React.forwardRef<\n React.ElementRef,\n React.ComponentProps\n>(({ className, onClick, ...props }, ref) => {\n const { toggleSidebar } = useSidebar();\n\n return (\n {\n onClick?.(event);\n toggleSidebar();\n }}\n {...props}\n >\n \n Toggle Sidebar\n \n );\n});\nSidebarTrigger.displayName = 'SidebarTrigger';\n\nconst SidebarRail = React.forwardRef>(\n ({ className, ...props }, ref) => {\n const { toggleSidebar } = useSidebar();\n\n return (\n \n );\n },\n);\nSidebarRail.displayName = 'SidebarRail';\n\nconst SidebarInset = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarInset.displayName = 'SidebarInset';\n\nconst SidebarInput = React.forwardRef<\n React.ElementRef,\n React.ComponentProps\n>(({ className, ...props }, ref) => {\n return (\n \n );\n});\nSidebarInput.displayName = 'SidebarInput';\n\nconst SidebarHeader = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarHeader.displayName = 'SidebarHeader';\n\nconst SidebarFooter = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarFooter.displayName = 'SidebarFooter';\n\nconst SidebarSeparator = React.forwardRef<\n React.ElementRef,\n React.ComponentProps\n>(({ className, ...props }, ref) => {\n return (\n \n );\n});\nSidebarSeparator.displayName = 'SidebarSeparator';\n\nconst SidebarContent = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarContent.displayName = 'SidebarContent';\n\nconst SidebarGroup = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarGroup.displayName = 'SidebarGroup';\n\nconst SidebarGroupLabel = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & { asChild?: boolean }\n>(({ className, asChild = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'div';\n\n return (\n svg]:tw-size-4 [&>svg]:tw-shrink-0',\n 'group-data-[collapsible=icon]:tw--mt-8 group-data-[collapsible=icon]:tw-opacity-0',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarGroupLabel.displayName = 'SidebarGroupLabel';\n\nconst SidebarGroupAction = React.forwardRef<\n HTMLButtonElement,\n React.ComponentProps<'button'> & { asChild?: boolean }\n>(({ className, asChild = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'button';\n\n return (\n svg]:tw-size-4 [&>svg]:tw-shrink-0',\n // Increases the hit area of the button on mobile.\n 'after:tw-absolute after:tw--inset-2 after:md:tw-hidden',\n 'group-data-[collapsible=icon]:tw-hidden',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarGroupAction.displayName = 'SidebarGroupAction';\n\nconst SidebarGroupContent = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarGroupContent.displayName = 'SidebarGroupContent';\n\nconst SidebarMenu = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenu.displayName = 'SidebarMenu';\n\nconst SidebarMenuItem = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenuItem.displayName = 'SidebarMenuItem';\n\nconst sidebarMenuButtonVariants = cva(\n // Removed data-[active=true]:tw-bg-sidebar-accent\n 'tw-peer/menu-button tw-flex tw-w-full tw-items-center tw-gap-2 tw-overflow-hidden tw-rounded-md tw-p-2 tw-text-left tw-text-sm tw-outline-none tw-ring-sidebar-ring tw-transition-[width,height,padding] hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground focus-visible:tw-ring-2 active:tw-bg-sidebar-accent active:tw-text-sidebar-accent-foreground disabled:tw-pointer-events-none disabled:tw-opacity-50 tw-group-has-[[data-sidebar=menu-action]]/menu-item:pr-8 aria-disabled:tw-pointer-events-none aria-disabled:tw-opacity-50 data-[active=true]:tw-font-medium data-[active=true]:tw-text-sidebar-accent-foreground data-[state=open]:hover:tw-bg-sidebar-accent data-[state=open]:hover:tw-text-sidebar-accent-foreground group-data-[collapsible=icon]:tw-!size-8 group-data-[collapsible=icon]:tw-!p-2 [&>span:last-child]:tw-truncate [&>svg]:tw-size-4 [&>svg]:tw-shrink-0',\n {\n variants: {\n variant: {\n default: 'hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground',\n outline:\n 'tw-bg-background tw-shadow-[0_0_0_1px_hsl(var(--sidebar-border))] hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground hover:tw-shadow-[0_0_0_1px_hsl(var(--sidebar-accent))]',\n },\n size: {\n default: 'tw-h-8 tw-text-sm',\n sm: 'tw-h-7 tw-text-xs',\n lg: 'tw-h-12 tw-text-sm group-data-[collapsible=icon]:tw-!p-0',\n },\n },\n defaultVariants: {\n variant: 'default',\n size: 'default',\n },\n },\n);\n\nconst SidebarMenuButton = React.forwardRef<\n HTMLButtonElement,\n React.ComponentProps<'button'> & {\n asChild?: boolean;\n isActive?: boolean;\n tooltip?: string | React.ComponentProps;\n } & VariantProps\n>(\n (\n {\n asChild = false,\n isActive = false,\n variant = 'default',\n size = 'default',\n tooltip,\n className,\n ...props\n },\n ref,\n ) => {\n const Comp = asChild ? Slot : 'button';\n const { state } = useSidebar();\n\n const button = (\n \n );\n\n if (!tooltip) {\n return button;\n }\n\n if (typeof tooltip === 'string') {\n // eslint-disable-next-line no-param-reassign\n tooltip = {\n children: tooltip,\n };\n }\n\n return (\n \n {button}\n \n );\n },\n);\nSidebarMenuButton.displayName = 'SidebarMenuButton';\n\nconst SidebarMenuAction = React.forwardRef<\n HTMLButtonElement,\n React.ComponentProps<'button'> & {\n asChild?: boolean;\n showOnHover?: boolean;\n }\n>(({ className, asChild = false, showOnHover = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'button';\n\n return (\n svg]:tw-size-4 [&>svg]:tw-shrink-0',\n // Increases the hit area of the button on mobile.\n 'after:tw-absolute after:tw--inset-2 after:md:tw-hidden',\n 'tw-peer-data-[size=sm]/menu-button:top-1',\n 'tw-peer-data-[size=default]/menu-button:top-1.5',\n 'tw-peer-data-[size=lg]/menu-button:top-2.5',\n 'group-data-[collapsible=icon]:tw-hidden',\n showOnHover &&\n 'tw-group-focus-within/menu-item:opacity-100 tw-group-hover/menu-item:opacity-100 tw-peer-data-[active=true]/menu-button:text-sidebar-accent-foreground data-[state=open]:tw-opacity-100 md:tw-opacity-0',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarMenuAction.displayName = 'SidebarMenuAction';\n\nconst SidebarMenuBadge = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenuBadge.displayName = 'SidebarMenuBadge';\n\nconst SidebarMenuSkeleton = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & {\n showIcon?: boolean;\n }\n>(({ className, showIcon = false, ...props }, ref) => {\n // Random width between 50 to 90%.\n const width = React.useMemo(() => {\n return `${Math.floor(Math.random() * 40) + 50}%`;\n }, []);\n\n return (\n \n {showIcon && (\n \n )}\n \n
    \n );\n});\nSidebarMenuSkeleton.displayName = 'SidebarMenuSkeleton';\n\nconst SidebarMenuSub = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenuSub.displayName = 'SidebarMenuSub';\n\nconst SidebarMenuSubItem = React.forwardRef>(\n ({ ...props }, ref) =>
  • ,\n);\nSidebarMenuSubItem.displayName = 'SidebarMenuSubItem';\n\nconst SidebarMenuSubButton = React.forwardRef<\n HTMLAnchorElement,\n React.ComponentProps<'a'> & {\n asChild?: boolean;\n size?: 'sm' | 'md';\n isActive?: boolean;\n }\n>(({ asChild = false, size = 'md', isActive, className, ...props }, ref) => {\n const Comp = asChild ? Slot : 'a';\n\n return (\n svg]:tw-text-sidebar-accent-foreground tw-flex tw-h-7 tw-min-w-0 tw--translate-x-px tw-items-center tw-gap-2 tw-overflow-hidden tw-rounded-md tw-px-2 tw-outline-none focus-visible:tw-ring-2 disabled:tw-pointer-events-none disabled:tw-opacity-50 aria-disabled:tw-pointer-events-none aria-disabled:tw-opacity-50 [&>span:last-child]:tw-truncate [&>svg]:tw-size-4 [&>svg]:tw-shrink-0',\n 'data-[active=true]:tw-bg-sidebar-accent data-[active=true]:tw-text-sidebar-accent-foreground',\n size === 'sm' && 'tw-text-xs',\n size === 'md' && 'tw-text-sm',\n 'group-data-[collapsible=icon]:tw-hidden',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarMenuSubButton.displayName = 'SidebarMenuSubButton';\n\nexport {\n Sidebar,\n SidebarContent,\n SidebarFooter,\n SidebarGroup,\n SidebarGroupAction,\n SidebarGroupContent,\n SidebarGroupLabel,\n SidebarHeader,\n SidebarInput,\n SidebarInset,\n SidebarMenu,\n SidebarMenuAction,\n SidebarMenuBadge,\n SidebarMenuButton,\n SidebarMenuItem,\n SidebarMenuSkeleton,\n SidebarMenuSub,\n SidebarMenuSubButton,\n SidebarMenuSubItem,\n SidebarProvider,\n SidebarRail,\n SidebarSeparator,\n SidebarTrigger,\n useSidebar,\n};\n","import ComboBox, { ComboBoxOption } from '@/components/basics/combo-box.component';\nimport {\n Sidebar,\n SidebarContent,\n SidebarGroup,\n SidebarGroupLabel,\n SidebarGroupContent,\n SidebarMenu,\n SidebarMenuItem,\n SidebarMenuButton,\n} from '@/components/shadcn-ui/sidebar';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { useCallback } from 'react';\n\nexport type SelectedSettingsSidebarItem = {\n label: string;\n projectId?: string;\n};\n\nexport type ProjectInfo = { projectId: string; projectName: string };\n\nexport type SettingsSidebarProps = {\n /** Optional id for testing */\n id?: string;\n\n /** Extension labels from contribution */\n extensionLabels: string[];\n\n /** Project names and ids */\n projectInfo: ProjectInfo[];\n\n /** Handler for selecting a sidebar item */\n handleSelectSidebarItem: (key: string, projectId?: string) => void;\n\n /** The current selected value in the sidebar */\n selectedSidebarItem: SelectedSettingsSidebarItem;\n\n /** Label for the group of extensions setting groups */\n extensionsSidebarGroupLabel: string;\n\n /** Label for the group of projects settings */\n projectsSidebarGroupLabel: string;\n\n /** Placeholder text for the button */\n buttonPlaceholderText: string;\n};\n\nexport default function SettingsSidebar({\n id,\n extensionLabels,\n projectInfo,\n handleSelectSidebarItem,\n selectedSidebarItem,\n extensionsSidebarGroupLabel,\n projectsSidebarGroupLabel,\n buttonPlaceholderText,\n}: SettingsSidebarProps) {\n const handleSelectItem = useCallback(\n (item: string, projectId?: string) => {\n handleSelectSidebarItem(item, projectId);\n },\n [handleSelectSidebarItem],\n );\n\n const getProjectNameFromProjectId = useCallback(\n (projectId: string) => {\n const project = projectInfo.find((info) => info.projectId === projectId);\n return project ? project.projectName : projectId;\n },\n [projectInfo],\n );\n\n const getIsActive: (label: string) => boolean = useCallback(\n (label: string) => !selectedSidebarItem.projectId && label === selectedSidebarItem.label,\n [selectedSidebarItem],\n );\n\n return (\n \n \n \n \n {extensionsSidebarGroupLabel}\n \n \n \n {extensionLabels.map((label) => (\n \n handleSelectItem(label)}\n isActive={getIsActive(label)}\n >\n {label}\n \n \n ))}\n \n \n \n \n \n {projectsSidebarGroupLabel}\n \n \n info.projectId)}\n getOptionLabel={(projectId: ComboBoxOption) => {\n // This function expects a ComboBoxOption, but we know it is a string\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n return getProjectNameFromProjectId(projectId as string);\n }}\n buttonPlaceholder={buttonPlaceholderText}\n onChange={(projectId: string) => {\n const selectedProjectName = getProjectNameFromProjectId(projectId);\n handleSelectItem(selectedProjectName, projectId);\n }}\n value={selectedSidebarItem?.projectId ?? undefined}\n />\n \n \n \n \n );\n}\n","import { SidebarInset, SidebarProvider } from '@/components/shadcn-ui/sidebar';\nimport { PropsWithChildren } from 'react';\nimport SearchBar from '@/components/basics/search-bar.component';\nimport SettingsSidebar, { SettingsSidebarProps } from './settings-sidebar.component';\n\nexport type SettingsSidebarContentSearchProps = SettingsSidebarProps &\n PropsWithChildren & {\n /** Optional id for testing */\n id?: string;\n\n /** Handler to run when the value of the search bar changes */\n onSearch: (searchQuery: string) => void;\n };\n\nexport default function SettingsSidebarContentSearch({\n id,\n extensionLabels,\n projectInfo,\n children,\n handleSelectSidebarItem,\n selectedSidebarItem,\n onSearch,\n extensionsSidebarGroupLabel,\n projectsSidebarGroupLabel,\n buttonPlaceholderText,\n}: SettingsSidebarContentSearchProps) {\n return (\n
    \n
    \n \n
    \n \n \n {children}\n \n
    \n );\n}\n","import { Button } from '@/components/shadcn-ui/button';\nimport {\n Select,\n SelectContent,\n SelectGroup,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\nimport {\n Table,\n TableBody,\n TableCell,\n TableHead,\n TableHeader,\n TableRow,\n} from '@/components/shadcn-ui/table';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Canon } from '@sillsdev/scripture';\nimport {\n Cell,\n ColumnDef,\n flexRender,\n getCoreRowModel,\n getExpandedRowModel,\n getGroupedRowModel,\n getSortedRowModel,\n GroupingState,\n Row,\n RowSelectionState,\n SortingState,\n useReactTable,\n} from '@tanstack/react-table';\nimport '@/components/advanced/scripture-results-viewer/scripture-results-viewer.component.css';\nimport {\n compareScrRefs,\n formatScrRef,\n ScriptureSelection,\n scrRefToBBBCCCVVV,\n} from 'platform-bible-utils';\nimport { MouseEvent, useEffect, useMemo, useState } from 'react';\nimport { ChevronDown, ChevronLeft, ChevronRight } from 'lucide-react';\n\n/**\n * Information (e.g., a checking error or some other type of \"transient\" annotation) about something\n * noteworthy at a specific place in an instance of the Scriptures.\n */\nexport type ScriptureItemDetail = ScriptureSelection & {\n /**\n * Text of the error, note, etc. In the future, we might want to support something more than just\n * text so that a JSX element could be provided with a link or some other controls related to the\n * issue being reported.\n */\n detail: string;\n};\n\n/**\n * A uniquely identifiable source of results that can be displayed in the ScriptureResultsViewer.\n * Generally, the source will be a particular Scripture check, but there may be other types of\n * sources.\n */\nexport type ResultsSource = {\n /**\n * Uniquely identifies the source.\n *\n * @type {string}\n */\n id: string;\n\n /**\n * Name (potentially localized) of the source, suitable for display in the UI.\n *\n * @type {string}\n */\n displayName: string;\n};\n\nexport type ScriptureSrcItemDetail = ScriptureItemDetail & {\n /** Source/type of detail. Can be used for grouping. */\n source: ResultsSource;\n};\n\n/**\n * Represents a set of results keyed by Scripture reference. Generally, the source will be a\n * particular Scripture check, but this type also allows for other types of uniquely identifiable\n * sources.\n */\nexport type ResultsSet = {\n /**\n * The backing source associated with this set of results.\n *\n * @type {ResultsSource}\n */\n source: ResultsSource;\n\n /**\n * Array of Scripture item details (messages keyed by Scripture reference).\n *\n * @type {ScriptureItemDetail[]}\n */\n data: ScriptureItemDetail[];\n};\n\nconst scrBookColId = 'scrBook';\nconst scrRefColId = 'scrRef';\nconst typeColId = 'source';\nconst detailsColId = 'details';\n\nconst defaultScrRefColumnName = 'Scripture Reference';\nconst defaultScrBookGroupName = 'Scripture Book';\nconst defaultTypeColumnName = 'Type';\nconst defaultDetailsColumnName = 'Details';\n\nexport type ScriptureResultsViewerColumnInfo = {\n /** Optional header to display for the Reference column. Default value: 'Scripture Reference'. */\n scriptureReferenceColumnName?: string;\n\n /** Optional text to display to refer to the Scripture book group. Default value: 'Scripture Book'. */\n scriptureBookGroupName?: string;\n\n /** Optional header to display for the Type column. Default value: 'Type'. */\n typeColumnName?: string;\n\n /** Optional header to display for the Details column. Default value: 'Details' */\n detailsColumnName?: string;\n};\n\nexport type ScriptureResultsViewerProps = ScriptureResultsViewerColumnInfo & {\n /** Groups of ScriptureItemDetail objects from particular sources (e.g., Scripture checks) */\n sources: ResultsSet[];\n\n /** Flag indicating whether to display column headers. Default is false. */\n showColumnHeaders?: boolean;\n\n /** Flag indicating whether to display source column. Default is false. */\n showSourceColumn?: boolean;\n\n /** Callback function to notify when a row is selected */\n onRowSelected?: (selectedRow: ScriptureSrcItemDetail | undefined) => void;\n\n /** Text direction ltr or rtl */\n direction?: 'ltr' | 'rtl';\n};\n\nfunction getColumns(\n colInfo?: ScriptureResultsViewerColumnInfo,\n showSourceColumn?: boolean,\n): ColumnDef[] {\n const showSrcCol = showSourceColumn ?? false;\n return [\n {\n accessorFn: (row) =>\n `${Canon.bookNumberToId(row.start.bookNum)} ${row.start.chapterNum}:${row.start.verseNum}`,\n id: scrBookColId,\n header: colInfo?.scriptureReferenceColumnName ?? defaultScrRefColumnName,\n cell: (info) => {\n const row = info.row.original;\n if (info.row.getIsGrouped()) {\n return Canon.bookNumberToEnglishName(row.start.bookNum);\n }\n return info.row.groupingColumnId === scrBookColId ? formatScrRef(row.start) : undefined;\n },\n getGroupingValue: (row) => row.start.bookNum,\n sortingFn: (a, b) => {\n return compareScrRefs(a.original.start, b.original.start);\n },\n enableGrouping: true,\n },\n {\n accessorFn: (row) => formatScrRef(row.start),\n id: scrRefColId,\n header: undefined,\n cell: (info) => {\n const row = info.row.original;\n return info.row.getIsGrouped() ? undefined : formatScrRef(row.start);\n },\n sortingFn: (a, b) => {\n return compareScrRefs(a.original.start, b.original.start);\n },\n enableGrouping: false,\n },\n {\n accessorFn: (row) => row.source.displayName,\n id: typeColId,\n header: showSrcCol ? (colInfo?.typeColumnName ?? defaultTypeColumnName) : undefined,\n cell: (info) => (showSrcCol || info.row.getIsGrouped() ? info.getValue() : undefined),\n getGroupingValue: (row) => row.source.id,\n sortingFn: (a, b) =>\n a.original.source.displayName.localeCompare(b.original.source.displayName),\n enableGrouping: true,\n },\n {\n accessorFn: (row) => row.detail,\n id: detailsColId,\n header: colInfo?.detailsColumnName ?? defaultDetailsColumnName,\n cell: (info) => info.getValue(),\n enableGrouping: false,\n },\n ];\n}\n\nconst toRefOrRange = (scriptureSelection: ScriptureSelection) => {\n if (!('offset' in scriptureSelection.start))\n throw new Error('No offset available in range start');\n if (scriptureSelection.end && !('offset' in scriptureSelection.end))\n throw new Error('No offset available in range end');\n const { offset: offsetStart } = scriptureSelection.start;\n let offsetEnd: number = 0;\n if (scriptureSelection.end) ({ offset: offsetEnd } = scriptureSelection.end);\n if (\n !scriptureSelection.end ||\n compareScrRefs(scriptureSelection.start, scriptureSelection.end) === 0\n )\n return `${scrRefToBBBCCCVVV(scriptureSelection.start)}+${offsetStart}`;\n return `${scrRefToBBBCCCVVV(scriptureSelection.start)}+${offsetStart}-${scrRefToBBBCCCVVV(scriptureSelection.end)}+${offsetEnd}`;\n};\n\nconst getRowKey = (row: ScriptureSrcItemDetail) =>\n `${toRefOrRange({ start: row.start, end: row.end })} ${row.source.displayName} ${row.detail}`;\n\n/**\n * Component to display a combined list of detailed items from one or more sources, where the items\n * are keyed primarily by Scripture reference. This is particularly useful for displaying a list of\n * results from Scripture checks, but more generally could be used to display any \"results\" from any\n * source(s). The component allows for grouping by Scripture book, source, or both. By default, it\n * displays somewhat \"tree-like\" which allows it to be more horizontally compact and intuitive. But\n * it also has the option of displaying as a traditional table with column headings (with or without\n * the source column showing).\n */\nexport default function ScriptureResultsViewer({\n sources,\n showColumnHeaders = false,\n showSourceColumn = false,\n scriptureReferenceColumnName,\n scriptureBookGroupName,\n typeColumnName,\n detailsColumnName,\n onRowSelected,\n direction = 'ltr',\n}: ScriptureResultsViewerProps) {\n const [grouping, setGrouping] = useState([]);\n const [sorting, setSorting] = useState([{ id: scrBookColId, desc: false }]);\n const [rowSelection, setRowSelection] = useState({});\n\n const scriptureResults = useMemo(\n () =>\n sources.flatMap((source) => {\n return source.data.map((item) => ({\n ...item,\n source: source.source,\n }));\n }),\n [sources],\n );\n\n const columns = useMemo(\n () =>\n getColumns(\n {\n scriptureReferenceColumnName,\n typeColumnName,\n detailsColumnName,\n },\n showSourceColumn,\n ),\n [scriptureReferenceColumnName, typeColumnName, detailsColumnName, showSourceColumn],\n );\n\n useEffect(() => {\n // Ensure sorting is applied correctly when grouped by type\n if (grouping.includes(typeColId)) {\n setSorting([\n { id: typeColId, desc: false },\n { id: scrBookColId, desc: false },\n ]);\n } else {\n setSorting([{ id: scrBookColId, desc: false }]);\n }\n }, [grouping]);\n\n const table = useReactTable({\n data: scriptureResults,\n columns,\n state: {\n grouping,\n sorting,\n rowSelection,\n },\n onGroupingChange: setGrouping,\n onSortingChange: setSorting,\n onRowSelectionChange: setRowSelection,\n getExpandedRowModel: getExpandedRowModel(),\n getGroupedRowModel: getGroupedRowModel(),\n getCoreRowModel: getCoreRowModel(),\n getSortedRowModel: getSortedRowModel(),\n getRowId: getRowKey,\n autoResetExpanded: false,\n enableMultiRowSelection: false,\n enableSubRowSelection: false,\n });\n\n useEffect(() => {\n if (onRowSelected) {\n const selectedRows = table.getSelectedRowModel().rowsById;\n const keys = Object.keys(selectedRows);\n if (keys.length === 1) {\n const selectedRow = scriptureResults.find((row) => getRowKey(row) === keys[0]) || undefined;\n if (selectedRow) onRowSelected(selectedRow);\n }\n }\n }, [rowSelection, scriptureResults, onRowSelected, table]);\n\n // Define possible grouping options\n const scrBookGroupName = scriptureBookGroupName ?? defaultScrBookGroupName;\n const typeGroupName = typeColumnName ?? defaultTypeColumnName;\n\n const groupingOptions = [\n { label: 'No Grouping', value: [] },\n { label: `Group by ${scrBookGroupName}`, value: [scrBookColId] },\n { label: `Group by ${typeGroupName}`, value: [typeColId] },\n {\n label: `Group by ${scrBookGroupName} and ${typeGroupName}`,\n value: [scrBookColId, typeColId],\n },\n {\n label: `Group by ${typeGroupName} and ${scrBookGroupName}`,\n value: [typeColId, scrBookColId],\n },\n ];\n\n const handleSelectChange = (selectedGrouping: string) => {\n setGrouping(JSON.parse(selectedGrouping));\n };\n\n const handleRowClick = (row: Row, event: MouseEvent) => {\n if (!row.getIsGrouped() && !row.getIsSelected()) {\n row.getToggleSelectedHandler()(event);\n }\n };\n\n const getEvenOrOddBandingStyle = (row: Row, index: number) => {\n if (row.getIsGrouped()) return '';\n // UX has now said they don't think they want banding. I'm leaving in the code to\n // set even and odd styles, but there's nothing in the CSS to style them differently.\n // The \"even\" style used to also have tw-bg-neutral-300 (along with even) to create\n // a visual banding effect. That could be added back in if UX changes the decision.\n return cn('banded-row', index % 2 === 0 ? 'even' : 'odd');\n };\n\n const getIndent = (\n groupingState: GroupingState,\n row: Row,\n cell: Cell,\n ) => {\n if (groupingState?.length === 0 || row.depth < cell.column.getGroupedIndex()) return undefined;\n if (row.getIsGrouped()) {\n switch (row.depth) {\n case 1:\n return 'tw-ps-4';\n default:\n return undefined;\n }\n }\n switch (row.depth) {\n case 1:\n return 'tw-ps-8';\n case 2:\n return 'tw-ps-12';\n default:\n return undefined;\n }\n };\n\n return (\n
    \n {!showColumnHeaders && (\n {\n handleSelectChange(value);\n }}\n >\n \n \n \n \n \n {groupingOptions.map((option) => (\n \n {option.label}\n \n ))}\n \n \n \n )}\n \n {showColumnHeaders && (\n \n {table.getHeaderGroups().map((headerGroup) => (\n \n {headerGroup.headers\n .filter((h) => h.column.columnDef.header)\n .map((header) => (\n /* For sticky column headers to work, we probably need to change the default definition of the shadcn Table component. See https://github.com/shadcn-ui/ui/issues/1151 */\n \n {header.isPlaceholder ? undefined : (\n
    \n {header.column.getCanGroup() ? (\n \n {header.column.getIsGrouped() ? `🛑` : `👊 `}\n \n ) : undefined}{' '}\n {flexRender(header.column.columnDef.header, header.getContext())}\n
    \n )}\n
    \n ))}\n
    \n ))}\n
    \n )}\n \n {table.getRowModel().rows.map((row, rowIndex) => {\n return (\n handleRowClick(row, event)}\n >\n {row.getVisibleCells().map((cell) => {\n if (\n cell.getIsPlaceholder() ||\n (cell.column.columnDef.enableGrouping &&\n !cell.getIsGrouped() &&\n (cell.column.columnDef.id !== typeColId || !showSourceColumn))\n )\n return undefined;\n return (\n \n {(() => {\n if (cell.getIsGrouped()) {\n return (\n \n {row.getIsExpanded() && }\n {!row.getIsExpanded() &&\n (direction === 'ltr' ? : )}{' '}\n {flexRender(cell.column.columnDef.cell, cell.getContext())} (\n {row.subRows.length})\n \n );\n }\n\n // if (cell.getIsAggregated()) {\n // flexRender(\n // cell.column.columnDef.aggregatedCell ?? cell.column.columnDef.cell,\n // cell.getContext(),\n // );\n // }\n\n return flexRender(cell.column.columnDef.cell, cell.getContext());\n })()}\n \n );\n })}\n \n );\n })}\n \n
    \n
    \n );\n}\n","import {\n getLocalizeKeyForScrollGroupId,\n LanguageStrings,\n ScrollGroupId,\n} from 'platform-bible-utils';\nimport {\n Select,\n SelectContent,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\n\nconst DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS = {\n [getLocalizeKeyForScrollGroupId('undefined')]: 'Ø',\n [getLocalizeKeyForScrollGroupId(0)]: 'A',\n [getLocalizeKeyForScrollGroupId(1)]: 'B',\n [getLocalizeKeyForScrollGroupId(2)]: 'C',\n [getLocalizeKeyForScrollGroupId(3)]: 'D',\n [getLocalizeKeyForScrollGroupId(4)]: 'E',\n [getLocalizeKeyForScrollGroupId(5)]: 'F',\n [getLocalizeKeyForScrollGroupId(6)]: 'G',\n [getLocalizeKeyForScrollGroupId(7)]: 'H',\n [getLocalizeKeyForScrollGroupId(8)]: 'I',\n [getLocalizeKeyForScrollGroupId(9)]: 'J',\n [getLocalizeKeyForScrollGroupId(10)]: 'K',\n [getLocalizeKeyForScrollGroupId(11)]: 'L',\n [getLocalizeKeyForScrollGroupId(12)]: 'M',\n [getLocalizeKeyForScrollGroupId(13)]: 'N',\n [getLocalizeKeyForScrollGroupId(14)]: 'O',\n [getLocalizeKeyForScrollGroupId(15)]: 'P',\n [getLocalizeKeyForScrollGroupId(16)]: 'Q',\n [getLocalizeKeyForScrollGroupId(17)]: 'R',\n [getLocalizeKeyForScrollGroupId(18)]: 'S',\n [getLocalizeKeyForScrollGroupId(19)]: 'T',\n [getLocalizeKeyForScrollGroupId(20)]: 'U',\n [getLocalizeKeyForScrollGroupId(21)]: 'V',\n [getLocalizeKeyForScrollGroupId(22)]: 'W',\n [getLocalizeKeyForScrollGroupId(23)]: 'X',\n [getLocalizeKeyForScrollGroupId(24)]: 'Y',\n [getLocalizeKeyForScrollGroupId(25)]: 'Z',\n};\n\nexport type ScrollGroupSelectorProps = {\n /**\n * List of scroll group ids to show to the user. Either a {@link ScrollGroupId} or `undefined` for\n * no scroll group\n */\n availableScrollGroupIds: (ScrollGroupId | undefined)[];\n /** Currently selected scroll group id. `undefined` for no scroll group */\n scrollGroupId: ScrollGroupId | undefined;\n /** Callback function run when the user tries to change the scroll group id */\n onChangeScrollGroupId: (newScrollGroupId: ScrollGroupId | undefined) => void;\n /**\n * Localized strings to use for displaying scroll group ids. Must be an object whose keys are\n * `getLocalizeKeyForScrollGroupId(scrollGroupId)` for all scroll group ids (and `undefined` if\n * included) in {@link ScrollGroupSelectorProps.availableScrollGroupIds} and whose values are the\n * localized strings to use for those scroll group ids.\n *\n * Defaults to English localizations of English alphabet for scroll groups 0-25 (e.g. 0 is A) and\n * Ø for `undefined`. Will fill in any that are not provided with these English localizations.\n * Also, if any values match the keys, the English localization will be used. This is useful in\n * case you want to pass in a temporary version of the localized strings while your localized\n * strings load.\n *\n * @example\n *\n * ```typescript\n * const myScrollGroupIdLocalizedStrings = {\n * [getLocalizeKeyForScrollGroupId('undefined')]: 'Ø',\n * [getLocalizeKeyForScrollGroupId(0)]: 'A',\n * [getLocalizeKeyForScrollGroupId(1)]: 'B',\n * [getLocalizeKeyForScrollGroupId(2)]: 'C',\n * [getLocalizeKeyForScrollGroupId(3)]: 'D',\n * [getLocalizeKeyForScrollGroupId(4)]: 'E',\n * };\n * ```\n *\n * @example\n *\n * ```tsx\n * const availableScrollGroupIds = [undefined, 0, 1, 2, 3, 4];\n *\n * const localizeKeys = getLocalizeKeysForScrollGroupIds();\n *\n * const [localizedStrings] = useLocalizedStrings(localizeKeys);\n *\n * ...\n *\n * \n * ```\n */\n localizedStrings?: LanguageStrings;\n};\n\n/** Selector component for choosing a scroll group */\nexport default function ScrollGroupSelector({\n availableScrollGroupIds,\n scrollGroupId,\n onChangeScrollGroupId,\n localizedStrings = {},\n}: ScrollGroupSelectorProps) {\n const localizedStringsDefaulted = {\n ...DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS,\n ...Object.fromEntries(\n Object.entries(localizedStrings).map(\n ([localizedStringKey, localizedStringValue]: [string, string]) => [\n localizedStringKey,\n localizedStringKey === localizedStringValue &&\n localizedStringKey in DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS\n ? DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS[localizedStringKey]\n : localizedStringValue,\n ],\n ),\n ),\n };\n return (\n \n onChangeScrollGroupId(\n newScrollGroupString === 'undefined' ? undefined : parseInt(newScrollGroupString, 10),\n )\n }\n >\n \n \n \n \n {availableScrollGroupIds.map((scrollGroupOptionId) => (\n \n {localizedStringsDefaulted[getLocalizeKeyForScrollGroupId(scrollGroupOptionId)]}\n \n ))}\n \n \n );\n}\n","import { PropsWithChildren } from 'react';\nimport { Separator } from '@/components/shadcn-ui/separator';\n\n/** Props for the SettingsList component, currently just children */\ntype SettingsListProps = PropsWithChildren;\n\n/**\n * SettingsList component is a wrapper for list items. Rendered with a formatted div\n *\n * @param children To populate the list with\n * @returns Formatted div encompassing the children\n */\nexport function SettingsList({ children }: SettingsListProps) {\n return
    {children}
    ;\n}\n\n/** Props for SettingsListItem component */\ntype SettingsListItemProps = PropsWithChildren & {\n /** Primary text of the list item */\n primary: string;\n\n /** Optional text of the list item */\n secondary?: string | undefined;\n\n /** Optional boolean to display a message if the children aren't loaded yet. Defaults to false */\n isLoading?: boolean;\n\n /** Optional message to display if isLoading */\n loadingMessage?: string;\n};\n\n/**\n * SettingsListItem component is a common list item. Rendered with a formatted div\n *\n * @param primary Primary text of the list item\n * @param secondary Optional secondary text of the list item\n * @param isLoading Optional, to display a message if the action component isn't generated yet,\n * defaults to false\n * @param children The action component(s) to provide for this item\n * @param loadingMessage Optional, message to display if isLoading\n * @returns Formatted div encompassing the list item content\n */\nexport function SettingsListItem({\n primary,\n secondary,\n children,\n isLoading = false,\n loadingMessage,\n}: SettingsListItemProps) {\n return (\n
    \n
    \n

    {primary}

    \n

    \n {secondary}\n

    \n
    \n\n {isLoading ? (\n

    {loadingMessage}

    \n ) : (\n
    {children}
    \n )}\n
    \n );\n}\n\n/** Props for SettingsListHeader component */\ntype SettingsListHeaderProps = {\n /** The primary text of the list header */\n primary: string;\n\n /** Optional secondary text of the list header */\n secondary?: string | undefined;\n\n /** Optional boolean to include a separator underneath the secondary text. Defaults to false */\n includeSeparator?: boolean;\n};\n\n/**\n * SettingsListHeader component displays text above the list\n *\n * @param primary The primary text of the list header\n * @param secondary Optional secondary text of the list header\n * @param includeSeparator Optional boolean to include a separator underneath the secondary text.\n * Defaults to false\n * @returns Formatted div with list header content\n */\nexport function SettingsListHeader({\n primary,\n secondary,\n includeSeparator = false,\n}: SettingsListHeaderProps) {\n return (\n
    \n
    \n

    {primary}

    \n

    {secondary}

    \n
    \n {includeSeparator ? : ''}\n
    \n );\n}\n","import Checkbox from '@/components/shadcn-ui/checkbox';\nimport { Label } from '@/components/shadcn-ui/label';\n\nexport type ChecklistProps = {\n /** Optional string representing the id attribute of the Checklist */\n id?: string;\n /** Optional string representing CSS class name(s) for styling */\n className?: string;\n /** Array of strings representing the checkable items */\n listItems: string[];\n /** Array of strings representing the checked items */\n selectedListItems: string[];\n /**\n * Function that is called when a checkbox item is selected or deselected\n *\n * @param item The string description for this item\n * @param selected True if selected, false if not selected\n */\n handleSelectListItem: (item: string, selected: boolean) => void;\n\n /**\n * Optional function creates a label for a provided checkable item\n *\n * @param item The item for which a label is to be created\n * @returns A string representing the label text for the checkbox associated with that item\n */\n createLabel?: (item: string) => string;\n};\n\n/** Renders a list of checkboxes. Each checkbox corresponds to an item from the `listItems` array. */\nexport default function Checklist({\n id,\n className,\n listItems,\n selectedListItems,\n handleSelectListItem,\n createLabel,\n}: ChecklistProps) {\n return (\n
    \n {listItems.map((item) => (\n
    \n handleSelectListItem(item, value)}\n />\n \n
    \n ))}\n
    \n );\n}\n","function _interopRequireDefault(obj) {\n return obj && obj.__esModule ? obj : {\n \"default\": obj\n };\n}\nmodule.exports = _interopRequireDefault, module.exports.__esModule = true, module.exports[\"default\"] = module.exports;","export default function chainPropTypes(propType1, propType2) {\n if (process.env.NODE_ENV === 'production') {\n return () => null;\n }\n return function validate(...args) {\n return propType1(...args) || propType2(...args);\n };\n}","export default function _extends() {\n _extends = Object.assign ? Object.assign.bind() : function (target) {\n for (var i = 1; i < arguments.length; i++) {\n var source = arguments[i];\n for (var key in source) {\n if (Object.prototype.hasOwnProperty.call(source, key)) {\n target[key] = source[key];\n }\n }\n }\n return target;\n };\n return _extends.apply(this, arguments);\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\n// https://github.com/sindresorhus/is-plain-obj/blob/main/index.js\nexport function isPlainObject(item) {\n if (typeof item !== 'object' || item === null) {\n return false;\n }\n const prototype = Object.getPrototypeOf(item);\n return (prototype === null || prototype === Object.prototype || Object.getPrototypeOf(prototype) === null) && !(Symbol.toStringTag in item) && !(Symbol.iterator in item);\n}\nfunction deepClone(source) {\n if (!isPlainObject(source)) {\n return source;\n }\n const output = {};\n Object.keys(source).forEach(key => {\n output[key] = deepClone(source[key]);\n });\n return output;\n}\nexport default function deepmerge(target, source, options = {\n clone: true\n}) {\n const output = options.clone ? _extends({}, target) : target;\n if (isPlainObject(target) && isPlainObject(source)) {\n Object.keys(source).forEach(key => {\n // Avoid prototype pollution\n if (key === '__proto__') {\n return;\n }\n if (isPlainObject(source[key]) && key in target && isPlainObject(target[key])) {\n // Since `output` is a clone of `target` and we have narrowed `target` in this block we can cast to the same type.\n output[key] = deepmerge(target[key], source[key], options);\n } else if (options.clone) {\n output[key] = isPlainObject(source[key]) ? deepClone(source[key]) : source[key];\n } else {\n output[key] = source[key];\n }\n });\n }\n return output;\n}","/** @license React v16.13.1\n * react-is.production.min.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';var b=\"function\"===typeof Symbol&&Symbol.for,c=b?Symbol.for(\"react.element\"):60103,d=b?Symbol.for(\"react.portal\"):60106,e=b?Symbol.for(\"react.fragment\"):60107,f=b?Symbol.for(\"react.strict_mode\"):60108,g=b?Symbol.for(\"react.profiler\"):60114,h=b?Symbol.for(\"react.provider\"):60109,k=b?Symbol.for(\"react.context\"):60110,l=b?Symbol.for(\"react.async_mode\"):60111,m=b?Symbol.for(\"react.concurrent_mode\"):60111,n=b?Symbol.for(\"react.forward_ref\"):60112,p=b?Symbol.for(\"react.suspense\"):60113,q=b?\nSymbol.for(\"react.suspense_list\"):60120,r=b?Symbol.for(\"react.memo\"):60115,t=b?Symbol.for(\"react.lazy\"):60116,v=b?Symbol.for(\"react.block\"):60121,w=b?Symbol.for(\"react.fundamental\"):60117,x=b?Symbol.for(\"react.responder\"):60118,y=b?Symbol.for(\"react.scope\"):60119;\nfunction z(a){if(\"object\"===typeof a&&null!==a){var u=a.$$typeof;switch(u){case c:switch(a=a.type,a){case l:case m:case e:case g:case f:case p:return a;default:switch(a=a&&a.$$typeof,a){case k:case n:case t:case r:case h:return a;default:return u}}case d:return u}}}function A(a){return z(a)===m}exports.AsyncMode=l;exports.ConcurrentMode=m;exports.ContextConsumer=k;exports.ContextProvider=h;exports.Element=c;exports.ForwardRef=n;exports.Fragment=e;exports.Lazy=t;exports.Memo=r;exports.Portal=d;\nexports.Profiler=g;exports.StrictMode=f;exports.Suspense=p;exports.isAsyncMode=function(a){return A(a)||z(a)===l};exports.isConcurrentMode=A;exports.isContextConsumer=function(a){return z(a)===k};exports.isContextProvider=function(a){return z(a)===h};exports.isElement=function(a){return\"object\"===typeof a&&null!==a&&a.$$typeof===c};exports.isForwardRef=function(a){return z(a)===n};exports.isFragment=function(a){return z(a)===e};exports.isLazy=function(a){return z(a)===t};\nexports.isMemo=function(a){return z(a)===r};exports.isPortal=function(a){return z(a)===d};exports.isProfiler=function(a){return z(a)===g};exports.isStrictMode=function(a){return z(a)===f};exports.isSuspense=function(a){return z(a)===p};\nexports.isValidElementType=function(a){return\"string\"===typeof a||\"function\"===typeof a||a===e||a===m||a===g||a===f||a===p||a===q||\"object\"===typeof a&&null!==a&&(a.$$typeof===t||a.$$typeof===r||a.$$typeof===h||a.$$typeof===k||a.$$typeof===n||a.$$typeof===w||a.$$typeof===x||a.$$typeof===y||a.$$typeof===v)};exports.typeOf=z;\n","/** @license React v16.13.1\n * react-is.development.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\n\n\nif (process.env.NODE_ENV !== \"production\") {\n (function() {\n'use strict';\n\n// The Symbol used to tag the ReactElement-like types. If there is no native Symbol\n// nor polyfill, then a plain number is used for performance.\nvar hasSymbol = typeof Symbol === 'function' && Symbol.for;\nvar REACT_ELEMENT_TYPE = hasSymbol ? Symbol.for('react.element') : 0xeac7;\nvar REACT_PORTAL_TYPE = hasSymbol ? Symbol.for('react.portal') : 0xeaca;\nvar REACT_FRAGMENT_TYPE = hasSymbol ? Symbol.for('react.fragment') : 0xeacb;\nvar REACT_STRICT_MODE_TYPE = hasSymbol ? Symbol.for('react.strict_mode') : 0xeacc;\nvar REACT_PROFILER_TYPE = hasSymbol ? Symbol.for('react.profiler') : 0xead2;\nvar REACT_PROVIDER_TYPE = hasSymbol ? Symbol.for('react.provider') : 0xeacd;\nvar REACT_CONTEXT_TYPE = hasSymbol ? Symbol.for('react.context') : 0xeace; // TODO: We don't use AsyncMode or ConcurrentMode anymore. They were temporary\n// (unstable) APIs that have been removed. Can we remove the symbols?\n\nvar REACT_ASYNC_MODE_TYPE = hasSymbol ? Symbol.for('react.async_mode') : 0xeacf;\nvar REACT_CONCURRENT_MODE_TYPE = hasSymbol ? Symbol.for('react.concurrent_mode') : 0xeacf;\nvar REACT_FORWARD_REF_TYPE = hasSymbol ? Symbol.for('react.forward_ref') : 0xead0;\nvar REACT_SUSPENSE_TYPE = hasSymbol ? Symbol.for('react.suspense') : 0xead1;\nvar REACT_SUSPENSE_LIST_TYPE = hasSymbol ? Symbol.for('react.suspense_list') : 0xead8;\nvar REACT_MEMO_TYPE = hasSymbol ? Symbol.for('react.memo') : 0xead3;\nvar REACT_LAZY_TYPE = hasSymbol ? Symbol.for('react.lazy') : 0xead4;\nvar REACT_BLOCK_TYPE = hasSymbol ? Symbol.for('react.block') : 0xead9;\nvar REACT_FUNDAMENTAL_TYPE = hasSymbol ? Symbol.for('react.fundamental') : 0xead5;\nvar REACT_RESPONDER_TYPE = hasSymbol ? Symbol.for('react.responder') : 0xead6;\nvar REACT_SCOPE_TYPE = hasSymbol ? Symbol.for('react.scope') : 0xead7;\n\nfunction isValidElementType(type) {\n return typeof type === 'string' || typeof type === 'function' || // Note: its typeof might be other than 'symbol' or 'number' if it's a polyfill.\n type === REACT_FRAGMENT_TYPE || type === REACT_CONCURRENT_MODE_TYPE || type === REACT_PROFILER_TYPE || type === REACT_STRICT_MODE_TYPE || type === REACT_SUSPENSE_TYPE || type === REACT_SUSPENSE_LIST_TYPE || typeof type === 'object' && type !== null && (type.$$typeof === REACT_LAZY_TYPE || type.$$typeof === REACT_MEMO_TYPE || type.$$typeof === REACT_PROVIDER_TYPE || type.$$typeof === REACT_CONTEXT_TYPE || type.$$typeof === REACT_FORWARD_REF_TYPE || type.$$typeof === REACT_FUNDAMENTAL_TYPE || type.$$typeof === REACT_RESPONDER_TYPE || type.$$typeof === REACT_SCOPE_TYPE || type.$$typeof === REACT_BLOCK_TYPE);\n}\n\nfunction typeOf(object) {\n if (typeof object === 'object' && object !== null) {\n var $$typeof = object.$$typeof;\n\n switch ($$typeof) {\n case REACT_ELEMENT_TYPE:\n var type = object.type;\n\n switch (type) {\n case REACT_ASYNC_MODE_TYPE:\n case REACT_CONCURRENT_MODE_TYPE:\n case REACT_FRAGMENT_TYPE:\n case REACT_PROFILER_TYPE:\n case REACT_STRICT_MODE_TYPE:\n case REACT_SUSPENSE_TYPE:\n return type;\n\n default:\n var $$typeofType = type && type.$$typeof;\n\n switch ($$typeofType) {\n case REACT_CONTEXT_TYPE:\n case REACT_FORWARD_REF_TYPE:\n case REACT_LAZY_TYPE:\n case REACT_MEMO_TYPE:\n case REACT_PROVIDER_TYPE:\n return $$typeofType;\n\n default:\n return $$typeof;\n }\n\n }\n\n case REACT_PORTAL_TYPE:\n return $$typeof;\n }\n }\n\n return undefined;\n} // AsyncMode is deprecated along with isAsyncMode\n\nvar AsyncMode = REACT_ASYNC_MODE_TYPE;\nvar ConcurrentMode = REACT_CONCURRENT_MODE_TYPE;\nvar ContextConsumer = REACT_CONTEXT_TYPE;\nvar ContextProvider = REACT_PROVIDER_TYPE;\nvar Element = REACT_ELEMENT_TYPE;\nvar ForwardRef = REACT_FORWARD_REF_TYPE;\nvar Fragment = REACT_FRAGMENT_TYPE;\nvar Lazy = REACT_LAZY_TYPE;\nvar Memo = REACT_MEMO_TYPE;\nvar Portal = REACT_PORTAL_TYPE;\nvar Profiler = REACT_PROFILER_TYPE;\nvar StrictMode = REACT_STRICT_MODE_TYPE;\nvar Suspense = REACT_SUSPENSE_TYPE;\nvar hasWarnedAboutDeprecatedIsAsyncMode = false; // AsyncMode should be deprecated\n\nfunction isAsyncMode(object) {\n {\n if (!hasWarnedAboutDeprecatedIsAsyncMode) {\n hasWarnedAboutDeprecatedIsAsyncMode = true; // Using console['warn'] to evade Babel and ESLint\n\n console['warn']('The ReactIs.isAsyncMode() alias has been deprecated, ' + 'and will be removed in React 17+. Update your code to use ' + 'ReactIs.isConcurrentMode() instead. It has the exact same API.');\n }\n }\n\n return isConcurrentMode(object) || typeOf(object) === REACT_ASYNC_MODE_TYPE;\n}\nfunction isConcurrentMode(object) {\n return typeOf(object) === REACT_CONCURRENT_MODE_TYPE;\n}\nfunction isContextConsumer(object) {\n return typeOf(object) === REACT_CONTEXT_TYPE;\n}\nfunction isContextProvider(object) {\n return typeOf(object) === REACT_PROVIDER_TYPE;\n}\nfunction isElement(object) {\n return typeof object === 'object' && object !== null && object.$$typeof === REACT_ELEMENT_TYPE;\n}\nfunction isForwardRef(object) {\n return typeOf(object) === REACT_FORWARD_REF_TYPE;\n}\nfunction isFragment(object) {\n return typeOf(object) === REACT_FRAGMENT_TYPE;\n}\nfunction isLazy(object) {\n return typeOf(object) === REACT_LAZY_TYPE;\n}\nfunction isMemo(object) {\n return typeOf(object) === REACT_MEMO_TYPE;\n}\nfunction isPortal(object) {\n return typeOf(object) === REACT_PORTAL_TYPE;\n}\nfunction isProfiler(object) {\n return typeOf(object) === REACT_PROFILER_TYPE;\n}\nfunction isStrictMode(object) {\n return typeOf(object) === REACT_STRICT_MODE_TYPE;\n}\nfunction isSuspense(object) {\n return typeOf(object) === REACT_SUSPENSE_TYPE;\n}\n\nexports.AsyncMode = AsyncMode;\nexports.ConcurrentMode = ConcurrentMode;\nexports.ContextConsumer = ContextConsumer;\nexports.ContextProvider = ContextProvider;\nexports.Element = Element;\nexports.ForwardRef = ForwardRef;\nexports.Fragment = Fragment;\nexports.Lazy = Lazy;\nexports.Memo = Memo;\nexports.Portal = Portal;\nexports.Profiler = Profiler;\nexports.StrictMode = StrictMode;\nexports.Suspense = Suspense;\nexports.isAsyncMode = isAsyncMode;\nexports.isConcurrentMode = isConcurrentMode;\nexports.isContextConsumer = isContextConsumer;\nexports.isContextProvider = isContextProvider;\nexports.isElement = isElement;\nexports.isForwardRef = isForwardRef;\nexports.isFragment = isFragment;\nexports.isLazy = isLazy;\nexports.isMemo = isMemo;\nexports.isPortal = isPortal;\nexports.isProfiler = isProfiler;\nexports.isStrictMode = isStrictMode;\nexports.isSuspense = isSuspense;\nexports.isValidElementType = isValidElementType;\nexports.typeOf = typeOf;\n })();\n}\n","'use strict';\n\nif (process.env.NODE_ENV === 'production') {\n module.exports = require('./cjs/react-is.production.min.js');\n} else {\n module.exports = require('./cjs/react-is.development.js');\n}\n","/*\nobject-assign\n(c) Sindre Sorhus\n@license MIT\n*/\n\n'use strict';\n/* eslint-disable no-unused-vars */\nvar getOwnPropertySymbols = Object.getOwnPropertySymbols;\nvar hasOwnProperty = Object.prototype.hasOwnProperty;\nvar propIsEnumerable = Object.prototype.propertyIsEnumerable;\n\nfunction toObject(val) {\n\tif (val === null || val === undefined) {\n\t\tthrow new TypeError('Object.assign cannot be called with null or undefined');\n\t}\n\n\treturn Object(val);\n}\n\nfunction shouldUseNative() {\n\ttry {\n\t\tif (!Object.assign) {\n\t\t\treturn false;\n\t\t}\n\n\t\t// Detect buggy property enumeration order in older V8 versions.\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=4118\n\t\tvar test1 = new String('abc'); // eslint-disable-line no-new-wrappers\n\t\ttest1[5] = 'de';\n\t\tif (Object.getOwnPropertyNames(test1)[0] === '5') {\n\t\t\treturn false;\n\t\t}\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=3056\n\t\tvar test2 = {};\n\t\tfor (var i = 0; i < 10; i++) {\n\t\t\ttest2['_' + String.fromCharCode(i)] = i;\n\t\t}\n\t\tvar order2 = Object.getOwnPropertyNames(test2).map(function (n) {\n\t\t\treturn test2[n];\n\t\t});\n\t\tif (order2.join('') !== '0123456789') {\n\t\t\treturn false;\n\t\t}\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=3056\n\t\tvar test3 = {};\n\t\t'abcdefghijklmnopqrst'.split('').forEach(function (letter) {\n\t\t\ttest3[letter] = letter;\n\t\t});\n\t\tif (Object.keys(Object.assign({}, test3)).join('') !==\n\t\t\t\t'abcdefghijklmnopqrst') {\n\t\t\treturn false;\n\t\t}\n\n\t\treturn true;\n\t} catch (err) {\n\t\t// We don't expect any of the above to throw, but better to be safe.\n\t\treturn false;\n\t}\n}\n\nmodule.exports = shouldUseNative() ? Object.assign : function (target, source) {\n\tvar from;\n\tvar to = toObject(target);\n\tvar symbols;\n\n\tfor (var s = 1; s < arguments.length; s++) {\n\t\tfrom = Object(arguments[s]);\n\n\t\tfor (var key in from) {\n\t\t\tif (hasOwnProperty.call(from, key)) {\n\t\t\t\tto[key] = from[key];\n\t\t\t}\n\t\t}\n\n\t\tif (getOwnPropertySymbols) {\n\t\t\tsymbols = getOwnPropertySymbols(from);\n\t\t\tfor (var i = 0; i < symbols.length; i++) {\n\t\t\t\tif (propIsEnumerable.call(from, symbols[i])) {\n\t\t\t\t\tto[symbols[i]] = from[symbols[i]];\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\n\treturn to;\n};\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar ReactPropTypesSecret = 'SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED';\n\nmodule.exports = ReactPropTypesSecret;\n","module.exports = Function.call.bind(Object.prototype.hasOwnProperty);\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar printWarning = function() {};\n\nif (process.env.NODE_ENV !== 'production') {\n var ReactPropTypesSecret = require('./lib/ReactPropTypesSecret');\n var loggedTypeFailures = {};\n var has = require('./lib/has');\n\n printWarning = function(text) {\n var message = 'Warning: ' + text;\n if (typeof console !== 'undefined') {\n console.error(message);\n }\n try {\n // --- Welcome to debugging React ---\n // This error was thrown as a convenience so that you can use this stack\n // to find the callsite that caused this warning to fire.\n throw new Error(message);\n } catch (x) { /**/ }\n };\n}\n\n/**\n * Assert that the values match with the type specs.\n * Error messages are memorized and will only be shown once.\n *\n * @param {object} typeSpecs Map of name to a ReactPropType\n * @param {object} values Runtime values that need to be type-checked\n * @param {string} location e.g. \"prop\", \"context\", \"child context\"\n * @param {string} componentName Name of the component for error messages.\n * @param {?Function} getStack Returns the component stack.\n * @private\n */\nfunction checkPropTypes(typeSpecs, values, location, componentName, getStack) {\n if (process.env.NODE_ENV !== 'production') {\n for (var typeSpecName in typeSpecs) {\n if (has(typeSpecs, typeSpecName)) {\n var error;\n // Prop type validation may throw. In case they do, we don't want to\n // fail the render phase where it didn't fail before. So we log it.\n // After these have been cleaned up, we'll let them throw.\n try {\n // This is intentionally an invariant that gets caught. It's the same\n // behavior as without this statement except with a better message.\n if (typeof typeSpecs[typeSpecName] !== 'function') {\n var err = Error(\n (componentName || 'React class') + ': ' + location + ' type `' + typeSpecName + '` is invalid; ' +\n 'it must be a function, usually from the `prop-types` package, but received `' + typeof typeSpecs[typeSpecName] + '`.' +\n 'This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.'\n );\n err.name = 'Invariant Violation';\n throw err;\n }\n error = typeSpecs[typeSpecName](values, typeSpecName, componentName, location, null, ReactPropTypesSecret);\n } catch (ex) {\n error = ex;\n }\n if (error && !(error instanceof Error)) {\n printWarning(\n (componentName || 'React class') + ': type specification of ' +\n location + ' `' + typeSpecName + '` is invalid; the type checker ' +\n 'function must return `null` or an `Error` but returned a ' + typeof error + '. ' +\n 'You may have forgotten to pass an argument to the type checker ' +\n 'creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and ' +\n 'shape all require an argument).'\n );\n }\n if (error instanceof Error && !(error.message in loggedTypeFailures)) {\n // Only monitor this failure once because there tends to be a lot of the\n // same error.\n loggedTypeFailures[error.message] = true;\n\n var stack = getStack ? getStack() : '';\n\n printWarning(\n 'Failed ' + location + ' type: ' + error.message + (stack != null ? stack : '')\n );\n }\n }\n }\n }\n}\n\n/**\n * Resets warning cache when testing.\n *\n * @private\n */\ncheckPropTypes.resetWarningCache = function() {\n if (process.env.NODE_ENV !== 'production') {\n loggedTypeFailures = {};\n }\n}\n\nmodule.exports = checkPropTypes;\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar ReactIs = require('react-is');\nvar assign = require('object-assign');\n\nvar ReactPropTypesSecret = require('./lib/ReactPropTypesSecret');\nvar has = require('./lib/has');\nvar checkPropTypes = require('./checkPropTypes');\n\nvar printWarning = function() {};\n\nif (process.env.NODE_ENV !== 'production') {\n printWarning = function(text) {\n var message = 'Warning: ' + text;\n if (typeof console !== 'undefined') {\n console.error(message);\n }\n try {\n // --- Welcome to debugging React ---\n // This error was thrown as a convenience so that you can use this stack\n // to find the callsite that caused this warning to fire.\n throw new Error(message);\n } catch (x) {}\n };\n}\n\nfunction emptyFunctionThatReturnsNull() {\n return null;\n}\n\nmodule.exports = function(isValidElement, throwOnDirectAccess) {\n /* global Symbol */\n var ITERATOR_SYMBOL = typeof Symbol === 'function' && Symbol.iterator;\n var FAUX_ITERATOR_SYMBOL = '@@iterator'; // Before Symbol spec.\n\n /**\n * Returns the iterator method function contained on the iterable object.\n *\n * Be sure to invoke the function with the iterable as context:\n *\n * var iteratorFn = getIteratorFn(myIterable);\n * if (iteratorFn) {\n * var iterator = iteratorFn.call(myIterable);\n * ...\n * }\n *\n * @param {?object} maybeIterable\n * @return {?function}\n */\n function getIteratorFn(maybeIterable) {\n var iteratorFn = maybeIterable && (ITERATOR_SYMBOL && maybeIterable[ITERATOR_SYMBOL] || maybeIterable[FAUX_ITERATOR_SYMBOL]);\n if (typeof iteratorFn === 'function') {\n return iteratorFn;\n }\n }\n\n /**\n * Collection of methods that allow declaration and validation of props that are\n * supplied to React components. Example usage:\n *\n * var Props = require('ReactPropTypes');\n * var MyArticle = React.createClass({\n * propTypes: {\n * // An optional string prop named \"description\".\n * description: Props.string,\n *\n * // A required enum prop named \"category\".\n * category: Props.oneOf(['News','Photos']).isRequired,\n *\n * // A prop named \"dialog\" that requires an instance of Dialog.\n * dialog: Props.instanceOf(Dialog).isRequired\n * },\n * render: function() { ... }\n * });\n *\n * A more formal specification of how these methods are used:\n *\n * type := array|bool|func|object|number|string|oneOf([...])|instanceOf(...)\n * decl := ReactPropTypes.{type}(.isRequired)?\n *\n * Each and every declaration produces a function with the same signature. This\n * allows the creation of custom validation functions. For example:\n *\n * var MyLink = React.createClass({\n * propTypes: {\n * // An optional string or URI prop named \"href\".\n * href: function(props, propName, componentName) {\n * var propValue = props[propName];\n * if (propValue != null && typeof propValue !== 'string' &&\n * !(propValue instanceof URI)) {\n * return new Error(\n * 'Expected a string or an URI for ' + propName + ' in ' +\n * componentName\n * );\n * }\n * }\n * },\n * render: function() {...}\n * });\n *\n * @internal\n */\n\n var ANONYMOUS = '<>';\n\n // Important!\n // Keep this list in sync with production version in `./factoryWithThrowingShims.js`.\n var ReactPropTypes = {\n array: createPrimitiveTypeChecker('array'),\n bigint: createPrimitiveTypeChecker('bigint'),\n bool: createPrimitiveTypeChecker('boolean'),\n func: createPrimitiveTypeChecker('function'),\n number: createPrimitiveTypeChecker('number'),\n object: createPrimitiveTypeChecker('object'),\n string: createPrimitiveTypeChecker('string'),\n symbol: createPrimitiveTypeChecker('symbol'),\n\n any: createAnyTypeChecker(),\n arrayOf: createArrayOfTypeChecker,\n element: createElementTypeChecker(),\n elementType: createElementTypeTypeChecker(),\n instanceOf: createInstanceTypeChecker,\n node: createNodeChecker(),\n objectOf: createObjectOfTypeChecker,\n oneOf: createEnumTypeChecker,\n oneOfType: createUnionTypeChecker,\n shape: createShapeTypeChecker,\n exact: createStrictShapeTypeChecker,\n };\n\n /**\n * inlined Object.is polyfill to avoid requiring consumers ship their own\n * https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object/is\n */\n /*eslint-disable no-self-compare*/\n function is(x, y) {\n // SameValue algorithm\n if (x === y) {\n // Steps 1-5, 7-10\n // Steps 6.b-6.e: +0 != -0\n return x !== 0 || 1 / x === 1 / y;\n } else {\n // Step 6.a: NaN == NaN\n return x !== x && y !== y;\n }\n }\n /*eslint-enable no-self-compare*/\n\n /**\n * We use an Error-like object for backward compatibility as people may call\n * PropTypes directly and inspect their output. However, we don't use real\n * Errors anymore. We don't inspect their stack anyway, and creating them\n * is prohibitively expensive if they are created too often, such as what\n * happens in oneOfType() for any type before the one that matched.\n */\n function PropTypeError(message, data) {\n this.message = message;\n this.data = data && typeof data === 'object' ? data: {};\n this.stack = '';\n }\n // Make `instanceof Error` still work for returned errors.\n PropTypeError.prototype = Error.prototype;\n\n function createChainableTypeChecker(validate) {\n if (process.env.NODE_ENV !== 'production') {\n var manualPropTypeCallCache = {};\n var manualPropTypeWarningCount = 0;\n }\n function checkType(isRequired, props, propName, componentName, location, propFullName, secret) {\n componentName = componentName || ANONYMOUS;\n propFullName = propFullName || propName;\n\n if (secret !== ReactPropTypesSecret) {\n if (throwOnDirectAccess) {\n // New behavior only for users of `prop-types` package\n var err = new Error(\n 'Calling PropTypes validators directly is not supported by the `prop-types` package. ' +\n 'Use `PropTypes.checkPropTypes()` to call them. ' +\n 'Read more at http://fb.me/use-check-prop-types'\n );\n err.name = 'Invariant Violation';\n throw err;\n } else if (process.env.NODE_ENV !== 'production' && typeof console !== 'undefined') {\n // Old behavior for people using React.PropTypes\n var cacheKey = componentName + ':' + propName;\n if (\n !manualPropTypeCallCache[cacheKey] &&\n // Avoid spamming the console because they are often not actionable except for lib authors\n manualPropTypeWarningCount < 3\n ) {\n printWarning(\n 'You are manually calling a React.PropTypes validation ' +\n 'function for the `' + propFullName + '` prop on `' + componentName + '`. This is deprecated ' +\n 'and will throw in the standalone `prop-types` package. ' +\n 'You may be seeing this warning due to a third-party PropTypes ' +\n 'library. See https://fb.me/react-warning-dont-call-proptypes ' + 'for details.'\n );\n manualPropTypeCallCache[cacheKey] = true;\n manualPropTypeWarningCount++;\n }\n }\n }\n if (props[propName] == null) {\n if (isRequired) {\n if (props[propName] === null) {\n return new PropTypeError('The ' + location + ' `' + propFullName + '` is marked as required ' + ('in `' + componentName + '`, but its value is `null`.'));\n }\n return new PropTypeError('The ' + location + ' `' + propFullName + '` is marked as required in ' + ('`' + componentName + '`, but its value is `undefined`.'));\n }\n return null;\n } else {\n return validate(props, propName, componentName, location, propFullName);\n }\n }\n\n var chainedCheckType = checkType.bind(null, false);\n chainedCheckType.isRequired = checkType.bind(null, true);\n\n return chainedCheckType;\n }\n\n function createPrimitiveTypeChecker(expectedType) {\n function validate(props, propName, componentName, location, propFullName, secret) {\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== expectedType) {\n // `propValue` being instance of, say, date/regexp, pass the 'object'\n // check, but we can offer a more precise error message here rather than\n // 'of type `object`'.\n var preciseType = getPreciseType(propValue);\n\n return new PropTypeError(\n 'Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + preciseType + '` supplied to `' + componentName + '`, expected ') + ('`' + expectedType + '`.'),\n {expectedType: expectedType}\n );\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createAnyTypeChecker() {\n return createChainableTypeChecker(emptyFunctionThatReturnsNull);\n }\n\n function createArrayOfTypeChecker(typeChecker) {\n function validate(props, propName, componentName, location, propFullName) {\n if (typeof typeChecker !== 'function') {\n return new PropTypeError('Property `' + propFullName + '` of component `' + componentName + '` has invalid PropType notation inside arrayOf.');\n }\n var propValue = props[propName];\n if (!Array.isArray(propValue)) {\n var propType = getPropType(propValue);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected an array.'));\n }\n for (var i = 0; i < propValue.length; i++) {\n var error = typeChecker(propValue, i, componentName, location, propFullName + '[' + i + ']', ReactPropTypesSecret);\n if (error instanceof Error) {\n return error;\n }\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createElementTypeChecker() {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n if (!isValidElement(propValue)) {\n var propType = getPropType(propValue);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected a single ReactElement.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createElementTypeTypeChecker() {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n if (!ReactIs.isValidElementType(propValue)) {\n var propType = getPropType(propValue);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected a single ReactElement type.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createInstanceTypeChecker(expectedClass) {\n function validate(props, propName, componentName, location, propFullName) {\n if (!(props[propName] instanceof expectedClass)) {\n var expectedClassName = expectedClass.name || ANONYMOUS;\n var actualClassName = getClassName(props[propName]);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + actualClassName + '` supplied to `' + componentName + '`, expected ') + ('instance of `' + expectedClassName + '`.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createEnumTypeChecker(expectedValues) {\n if (!Array.isArray(expectedValues)) {\n if (process.env.NODE_ENV !== 'production') {\n if (arguments.length > 1) {\n printWarning(\n 'Invalid arguments supplied to oneOf, expected an array, got ' + arguments.length + ' arguments. ' +\n 'A common mistake is to write oneOf(x, y, z) instead of oneOf([x, y, z]).'\n );\n } else {\n printWarning('Invalid argument supplied to oneOf, expected an array.');\n }\n }\n return emptyFunctionThatReturnsNull;\n }\n\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n for (var i = 0; i < expectedValues.length; i++) {\n if (is(propValue, expectedValues[i])) {\n return null;\n }\n }\n\n var valuesString = JSON.stringify(expectedValues, function replacer(key, value) {\n var type = getPreciseType(value);\n if (type === 'symbol') {\n return String(value);\n }\n return value;\n });\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of value `' + String(propValue) + '` ' + ('supplied to `' + componentName + '`, expected one of ' + valuesString + '.'));\n }\n return createChainableTypeChecker(validate);\n }\n\n function createObjectOfTypeChecker(typeChecker) {\n function validate(props, propName, componentName, location, propFullName) {\n if (typeof typeChecker !== 'function') {\n return new PropTypeError('Property `' + propFullName + '` of component `' + componentName + '` has invalid PropType notation inside objectOf.');\n }\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== 'object') {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected an object.'));\n }\n for (var key in propValue) {\n if (has(propValue, key)) {\n var error = typeChecker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret);\n if (error instanceof Error) {\n return error;\n }\n }\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createUnionTypeChecker(arrayOfTypeCheckers) {\n if (!Array.isArray(arrayOfTypeCheckers)) {\n process.env.NODE_ENV !== 'production' ? printWarning('Invalid argument supplied to oneOfType, expected an instance of array.') : void 0;\n return emptyFunctionThatReturnsNull;\n }\n\n for (var i = 0; i < arrayOfTypeCheckers.length; i++) {\n var checker = arrayOfTypeCheckers[i];\n if (typeof checker !== 'function') {\n printWarning(\n 'Invalid argument supplied to oneOfType. Expected an array of check functions, but ' +\n 'received ' + getPostfixForTypeWarning(checker) + ' at index ' + i + '.'\n );\n return emptyFunctionThatReturnsNull;\n }\n }\n\n function validate(props, propName, componentName, location, propFullName) {\n var expectedTypes = [];\n for (var i = 0; i < arrayOfTypeCheckers.length; i++) {\n var checker = arrayOfTypeCheckers[i];\n var checkerResult = checker(props, propName, componentName, location, propFullName, ReactPropTypesSecret);\n if (checkerResult == null) {\n return null;\n }\n if (checkerResult.data && has(checkerResult.data, 'expectedType')) {\n expectedTypes.push(checkerResult.data.expectedType);\n }\n }\n var expectedTypesMessage = (expectedTypes.length > 0) ? ', expected one of type [' + expectedTypes.join(', ') + ']': '';\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` supplied to ' + ('`' + componentName + '`' + expectedTypesMessage + '.'));\n }\n return createChainableTypeChecker(validate);\n }\n\n function createNodeChecker() {\n function validate(props, propName, componentName, location, propFullName) {\n if (!isNode(props[propName])) {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` supplied to ' + ('`' + componentName + '`, expected a ReactNode.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function invalidValidatorError(componentName, location, propFullName, key, type) {\n return new PropTypeError(\n (componentName || 'React class') + ': ' + location + ' type `' + propFullName + '.' + key + '` is invalid; ' +\n 'it must be a function, usually from the `prop-types` package, but received `' + type + '`.'\n );\n }\n\n function createShapeTypeChecker(shapeTypes) {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== 'object') {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type `' + propType + '` ' + ('supplied to `' + componentName + '`, expected `object`.'));\n }\n for (var key in shapeTypes) {\n var checker = shapeTypes[key];\n if (typeof checker !== 'function') {\n return invalidValidatorError(componentName, location, propFullName, key, getPreciseType(checker));\n }\n var error = checker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret);\n if (error) {\n return error;\n }\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createStrictShapeTypeChecker(shapeTypes) {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== 'object') {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type `' + propType + '` ' + ('supplied to `' + componentName + '`, expected `object`.'));\n }\n // We need to check all keys in case some are required but missing from props.\n var allKeys = assign({}, props[propName], shapeTypes);\n for (var key in allKeys) {\n var checker = shapeTypes[key];\n if (has(shapeTypes, key) && typeof checker !== 'function') {\n return invalidValidatorError(componentName, location, propFullName, key, getPreciseType(checker));\n }\n if (!checker) {\n return new PropTypeError(\n 'Invalid ' + location + ' `' + propFullName + '` key `' + key + '` supplied to `' + componentName + '`.' +\n '\\nBad object: ' + JSON.stringify(props[propName], null, ' ') +\n '\\nValid keys: ' + JSON.stringify(Object.keys(shapeTypes), null, ' ')\n );\n }\n var error = checker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret);\n if (error) {\n return error;\n }\n }\n return null;\n }\n\n return createChainableTypeChecker(validate);\n }\n\n function isNode(propValue) {\n switch (typeof propValue) {\n case 'number':\n case 'string':\n case 'undefined':\n return true;\n case 'boolean':\n return !propValue;\n case 'object':\n if (Array.isArray(propValue)) {\n return propValue.every(isNode);\n }\n if (propValue === null || isValidElement(propValue)) {\n return true;\n }\n\n var iteratorFn = getIteratorFn(propValue);\n if (iteratorFn) {\n var iterator = iteratorFn.call(propValue);\n var step;\n if (iteratorFn !== propValue.entries) {\n while (!(step = iterator.next()).done) {\n if (!isNode(step.value)) {\n return false;\n }\n }\n } else {\n // Iterator will provide entry [k,v] tuples rather than values.\n while (!(step = iterator.next()).done) {\n var entry = step.value;\n if (entry) {\n if (!isNode(entry[1])) {\n return false;\n }\n }\n }\n }\n } else {\n return false;\n }\n\n return true;\n default:\n return false;\n }\n }\n\n function isSymbol(propType, propValue) {\n // Native Symbol.\n if (propType === 'symbol') {\n return true;\n }\n\n // falsy value can't be a Symbol\n if (!propValue) {\n return false;\n }\n\n // 19.4.3.5 Symbol.prototype[@@toStringTag] === 'Symbol'\n if (propValue['@@toStringTag'] === 'Symbol') {\n return true;\n }\n\n // Fallback for non-spec compliant Symbols which are polyfilled.\n if (typeof Symbol === 'function' && propValue instanceof Symbol) {\n return true;\n }\n\n return false;\n }\n\n // Equivalent of `typeof` but with special handling for array and regexp.\n function getPropType(propValue) {\n var propType = typeof propValue;\n if (Array.isArray(propValue)) {\n return 'array';\n }\n if (propValue instanceof RegExp) {\n // Old webkits (at least until Android 4.0) return 'function' rather than\n // 'object' for typeof a RegExp. We'll normalize this here so that /bla/\n // passes PropTypes.object.\n return 'object';\n }\n if (isSymbol(propType, propValue)) {\n return 'symbol';\n }\n return propType;\n }\n\n // This handles more types than `getPropType`. Only used for error messages.\n // See `createPrimitiveTypeChecker`.\n function getPreciseType(propValue) {\n if (typeof propValue === 'undefined' || propValue === null) {\n return '' + propValue;\n }\n var propType = getPropType(propValue);\n if (propType === 'object') {\n if (propValue instanceof Date) {\n return 'date';\n } else if (propValue instanceof RegExp) {\n return 'regexp';\n }\n }\n return propType;\n }\n\n // Returns a string that is postfixed to a warning about an invalid type.\n // For example, \"undefined\" or \"of type array\"\n function getPostfixForTypeWarning(value) {\n var type = getPreciseType(value);\n switch (type) {\n case 'array':\n case 'object':\n return 'an ' + type;\n case 'boolean':\n case 'date':\n case 'regexp':\n return 'a ' + type;\n default:\n return type;\n }\n }\n\n // Returns class name of the object, if any.\n function getClassName(propValue) {\n if (!propValue.constructor || !propValue.constructor.name) {\n return ANONYMOUS;\n }\n return propValue.constructor.name;\n }\n\n ReactPropTypes.checkPropTypes = checkPropTypes;\n ReactPropTypes.resetWarningCache = checkPropTypes.resetWarningCache;\n ReactPropTypes.PropTypes = ReactPropTypes;\n\n return ReactPropTypes;\n};\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar ReactPropTypesSecret = require('./lib/ReactPropTypesSecret');\n\nfunction emptyFunction() {}\nfunction emptyFunctionWithReset() {}\nemptyFunctionWithReset.resetWarningCache = emptyFunction;\n\nmodule.exports = function() {\n function shim(props, propName, componentName, location, propFullName, secret) {\n if (secret === ReactPropTypesSecret) {\n // It is still safe when called from React.\n return;\n }\n var err = new Error(\n 'Calling PropTypes validators directly is not supported by the `prop-types` package. ' +\n 'Use PropTypes.checkPropTypes() to call them. ' +\n 'Read more at http://fb.me/use-check-prop-types'\n );\n err.name = 'Invariant Violation';\n throw err;\n };\n shim.isRequired = shim;\n function getShim() {\n return shim;\n };\n // Important!\n // Keep this list in sync with production version in `./factoryWithTypeCheckers.js`.\n var ReactPropTypes = {\n array: shim,\n bigint: shim,\n bool: shim,\n func: shim,\n number: shim,\n object: shim,\n string: shim,\n symbol: shim,\n\n any: shim,\n arrayOf: getShim,\n element: shim,\n elementType: shim,\n instanceOf: getShim,\n node: shim,\n objectOf: getShim,\n oneOf: getShim,\n oneOfType: getShim,\n shape: getShim,\n exact: getShim,\n\n checkPropTypes: emptyFunctionWithReset,\n resetWarningCache: emptyFunction\n };\n\n ReactPropTypes.PropTypes = ReactPropTypes;\n\n return ReactPropTypes;\n};\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\nif (process.env.NODE_ENV !== 'production') {\n var ReactIs = require('react-is');\n\n // By explicitly using `prop-types` you are opting into new development behavior.\n // http://fb.me/prop-types-in-prod\n var throwOnDirectAccess = true;\n module.exports = require('./factoryWithTypeCheckers')(ReactIs.isElement, throwOnDirectAccess);\n} else {\n // By explicitly using `prop-types` you are opting into new production behavior.\n // http://fb.me/prop-types-in-prod\n module.exports = require('./factoryWithThrowingShims')();\n}\n","import PropTypes from 'prop-types';\nimport chainPropTypes from '../chainPropTypes';\nfunction isClassComponent(elementType) {\n // elementType.prototype?.isReactComponent\n const {\n prototype = {}\n } = elementType;\n return Boolean(prototype.isReactComponent);\n}\nfunction acceptingRef(props, propName, componentName, location, propFullName) {\n const element = props[propName];\n const safePropName = propFullName || propName;\n if (element == null ||\n // When server-side rendering React doesn't warn either.\n // This is not an accurate check for SSR.\n // This is only in place for Emotion compat.\n // TODO: Revisit once https://github.com/facebook/react/issues/20047 is resolved.\n typeof window === 'undefined') {\n return null;\n }\n let warningHint;\n const elementType = element.type;\n /**\n * Blacklisting instead of whitelisting\n *\n * Blacklisting will miss some components, such as React.Fragment. Those will at least\n * trigger a warning in React.\n * We can't whitelist because there is no safe way to detect React.forwardRef\n * or class components. \"Safe\" means there's no public API.\n *\n */\n if (typeof elementType === 'function' && !isClassComponent(elementType)) {\n warningHint = 'Did you accidentally use a plain function component for an element instead?';\n }\n if (warningHint !== undefined) {\n return new Error(`Invalid ${location} \\`${safePropName}\\` supplied to \\`${componentName}\\`. ` + `Expected an element that can hold a ref. ${warningHint} ` + 'For more information see https://mui.com/r/caveat-with-refs-guide');\n }\n return null;\n}\nconst elementAcceptingRef = chainPropTypes(PropTypes.element, acceptingRef);\nelementAcceptingRef.isRequired = chainPropTypes(PropTypes.element.isRequired, acceptingRef);\nexport default elementAcceptingRef;","import _extends from \"@babel/runtime/helpers/esm/extends\";\n// This module is based on https://github.com/airbnb/prop-types-exact repository.\n// However, in order to reduce the number of dependencies and to remove some extra safe checks\n// the module was forked.\n\nconst specialProperty = 'exact-prop: \\u200b';\nexport default function exactProp(propTypes) {\n if (process.env.NODE_ENV === 'production') {\n return propTypes;\n }\n return _extends({}, propTypes, {\n [specialProperty]: props => {\n const unsupportedProps = Object.keys(props).filter(prop => !propTypes.hasOwnProperty(prop));\n if (unsupportedProps.length > 0) {\n return new Error(`The following props are not supported: ${unsupportedProps.map(prop => `\\`${prop}\\``).join(', ')}. Please remove them.`);\n }\n return null;\n }\n });\n}","/**\n * WARNING: Don't import this directly.\n * Use `MuiError` from `@mui/internal-babel-macros/MuiError.macro` instead.\n * @param {number} code\n */\nexport default function formatMuiErrorMessage(code) {\n // Apply babel-plugin-transform-template-literals in loose mode\n // loose mode is safe if we're concatenating primitives\n // see https://babeljs.io/docs/en/babel-plugin-transform-template-literals#loose\n /* eslint-disable prefer-template */\n let url = 'https://mui.com/production-error/?code=' + code;\n for (let i = 1; i < arguments.length; i += 1) {\n // rest params over-transpile for this case\n // eslint-disable-next-line prefer-rest-params\n url += '&args[]=' + encodeURIComponent(arguments[i]);\n }\n return 'Minified MUI error #' + code + '; visit ' + url + ' for the full message.';\n /* eslint-enable prefer-template */\n}","/**\n * @license React\n * react-is.production.min.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n'use strict';var b=Symbol.for(\"react.element\"),c=Symbol.for(\"react.portal\"),d=Symbol.for(\"react.fragment\"),e=Symbol.for(\"react.strict_mode\"),f=Symbol.for(\"react.profiler\"),g=Symbol.for(\"react.provider\"),h=Symbol.for(\"react.context\"),k=Symbol.for(\"react.server_context\"),l=Symbol.for(\"react.forward_ref\"),m=Symbol.for(\"react.suspense\"),n=Symbol.for(\"react.suspense_list\"),p=Symbol.for(\"react.memo\"),q=Symbol.for(\"react.lazy\"),t=Symbol.for(\"react.offscreen\"),u;u=Symbol.for(\"react.module.reference\");\nfunction v(a){if(\"object\"===typeof a&&null!==a){var r=a.$$typeof;switch(r){case b:switch(a=a.type,a){case d:case f:case e:case m:case n:return a;default:switch(a=a&&a.$$typeof,a){case k:case h:case l:case q:case p:case g:return a;default:return r}}case c:return r}}}exports.ContextConsumer=h;exports.ContextProvider=g;exports.Element=b;exports.ForwardRef=l;exports.Fragment=d;exports.Lazy=q;exports.Memo=p;exports.Portal=c;exports.Profiler=f;exports.StrictMode=e;exports.Suspense=m;\nexports.SuspenseList=n;exports.isAsyncMode=function(){return!1};exports.isConcurrentMode=function(){return!1};exports.isContextConsumer=function(a){return v(a)===h};exports.isContextProvider=function(a){return v(a)===g};exports.isElement=function(a){return\"object\"===typeof a&&null!==a&&a.$$typeof===b};exports.isForwardRef=function(a){return v(a)===l};exports.isFragment=function(a){return v(a)===d};exports.isLazy=function(a){return v(a)===q};exports.isMemo=function(a){return v(a)===p};\nexports.isPortal=function(a){return v(a)===c};exports.isProfiler=function(a){return v(a)===f};exports.isStrictMode=function(a){return v(a)===e};exports.isSuspense=function(a){return v(a)===m};exports.isSuspenseList=function(a){return v(a)===n};\nexports.isValidElementType=function(a){return\"string\"===typeof a||\"function\"===typeof a||a===d||a===f||a===e||a===m||a===n||a===t||\"object\"===typeof a&&null!==a&&(a.$$typeof===q||a.$$typeof===p||a.$$typeof===g||a.$$typeof===h||a.$$typeof===l||a.$$typeof===u||void 0!==a.getModuleId)?!0:!1};exports.typeOf=v;\n","/**\n * @license React\n * react-is.development.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nif (process.env.NODE_ENV !== \"production\") {\n (function() {\n'use strict';\n\n// ATTENTION\n// When adding new symbols to this file,\n// Please consider also adding to 'react-devtools-shared/src/backend/ReactSymbols'\n// The Symbol used to tag the ReactElement-like types.\nvar REACT_ELEMENT_TYPE = Symbol.for('react.element');\nvar REACT_PORTAL_TYPE = Symbol.for('react.portal');\nvar REACT_FRAGMENT_TYPE = Symbol.for('react.fragment');\nvar REACT_STRICT_MODE_TYPE = Symbol.for('react.strict_mode');\nvar REACT_PROFILER_TYPE = Symbol.for('react.profiler');\nvar REACT_PROVIDER_TYPE = Symbol.for('react.provider');\nvar REACT_CONTEXT_TYPE = Symbol.for('react.context');\nvar REACT_SERVER_CONTEXT_TYPE = Symbol.for('react.server_context');\nvar REACT_FORWARD_REF_TYPE = Symbol.for('react.forward_ref');\nvar REACT_SUSPENSE_TYPE = Symbol.for('react.suspense');\nvar REACT_SUSPENSE_LIST_TYPE = Symbol.for('react.suspense_list');\nvar REACT_MEMO_TYPE = Symbol.for('react.memo');\nvar REACT_LAZY_TYPE = Symbol.for('react.lazy');\nvar REACT_OFFSCREEN_TYPE = Symbol.for('react.offscreen');\n\n// -----------------------------------------------------------------------------\n\nvar enableScopeAPI = false; // Experimental Create Event Handle API.\nvar enableCacheElement = false;\nvar enableTransitionTracing = false; // No known bugs, but needs performance testing\n\nvar enableLegacyHidden = false; // Enables unstable_avoidThisFallback feature in Fiber\n// stuff. Intended to enable React core members to more easily debug scheduling\n// issues in DEV builds.\n\nvar enableDebugTracing = false; // Track which Fiber(s) schedule render work.\n\nvar REACT_MODULE_REFERENCE;\n\n{\n REACT_MODULE_REFERENCE = Symbol.for('react.module.reference');\n}\n\nfunction isValidElementType(type) {\n if (typeof type === 'string' || typeof type === 'function') {\n return true;\n } // Note: typeof might be other than 'symbol' or 'number' (e.g. if it's a polyfill).\n\n\n if (type === REACT_FRAGMENT_TYPE || type === REACT_PROFILER_TYPE || enableDebugTracing || type === REACT_STRICT_MODE_TYPE || type === REACT_SUSPENSE_TYPE || type === REACT_SUSPENSE_LIST_TYPE || enableLegacyHidden || type === REACT_OFFSCREEN_TYPE || enableScopeAPI || enableCacheElement || enableTransitionTracing ) {\n return true;\n }\n\n if (typeof type === 'object' && type !== null) {\n if (type.$$typeof === REACT_LAZY_TYPE || type.$$typeof === REACT_MEMO_TYPE || type.$$typeof === REACT_PROVIDER_TYPE || type.$$typeof === REACT_CONTEXT_TYPE || type.$$typeof === REACT_FORWARD_REF_TYPE || // This needs to include all possible module reference object\n // types supported by any Flight configuration anywhere since\n // we don't know which Flight build this will end up being used\n // with.\n type.$$typeof === REACT_MODULE_REFERENCE || type.getModuleId !== undefined) {\n return true;\n }\n }\n\n return false;\n}\n\nfunction typeOf(object) {\n if (typeof object === 'object' && object !== null) {\n var $$typeof = object.$$typeof;\n\n switch ($$typeof) {\n case REACT_ELEMENT_TYPE:\n var type = object.type;\n\n switch (type) {\n case REACT_FRAGMENT_TYPE:\n case REACT_PROFILER_TYPE:\n case REACT_STRICT_MODE_TYPE:\n case REACT_SUSPENSE_TYPE:\n case REACT_SUSPENSE_LIST_TYPE:\n return type;\n\n default:\n var $$typeofType = type && type.$$typeof;\n\n switch ($$typeofType) {\n case REACT_SERVER_CONTEXT_TYPE:\n case REACT_CONTEXT_TYPE:\n case REACT_FORWARD_REF_TYPE:\n case REACT_LAZY_TYPE:\n case REACT_MEMO_TYPE:\n case REACT_PROVIDER_TYPE:\n return $$typeofType;\n\n default:\n return $$typeof;\n }\n\n }\n\n case REACT_PORTAL_TYPE:\n return $$typeof;\n }\n }\n\n return undefined;\n}\nvar ContextConsumer = REACT_CONTEXT_TYPE;\nvar ContextProvider = REACT_PROVIDER_TYPE;\nvar Element = REACT_ELEMENT_TYPE;\nvar ForwardRef = REACT_FORWARD_REF_TYPE;\nvar Fragment = REACT_FRAGMENT_TYPE;\nvar Lazy = REACT_LAZY_TYPE;\nvar Memo = REACT_MEMO_TYPE;\nvar Portal = REACT_PORTAL_TYPE;\nvar Profiler = REACT_PROFILER_TYPE;\nvar StrictMode = REACT_STRICT_MODE_TYPE;\nvar Suspense = REACT_SUSPENSE_TYPE;\nvar SuspenseList = REACT_SUSPENSE_LIST_TYPE;\nvar hasWarnedAboutDeprecatedIsAsyncMode = false;\nvar hasWarnedAboutDeprecatedIsConcurrentMode = false; // AsyncMode should be deprecated\n\nfunction isAsyncMode(object) {\n {\n if (!hasWarnedAboutDeprecatedIsAsyncMode) {\n hasWarnedAboutDeprecatedIsAsyncMode = true; // Using console['warn'] to evade Babel and ESLint\n\n console['warn']('The ReactIs.isAsyncMode() alias has been deprecated, ' + 'and will be removed in React 18+.');\n }\n }\n\n return false;\n}\nfunction isConcurrentMode(object) {\n {\n if (!hasWarnedAboutDeprecatedIsConcurrentMode) {\n hasWarnedAboutDeprecatedIsConcurrentMode = true; // Using console['warn'] to evade Babel and ESLint\n\n console['warn']('The ReactIs.isConcurrentMode() alias has been deprecated, ' + 'and will be removed in React 18+.');\n }\n }\n\n return false;\n}\nfunction isContextConsumer(object) {\n return typeOf(object) === REACT_CONTEXT_TYPE;\n}\nfunction isContextProvider(object) {\n return typeOf(object) === REACT_PROVIDER_TYPE;\n}\nfunction isElement(object) {\n return typeof object === 'object' && object !== null && object.$$typeof === REACT_ELEMENT_TYPE;\n}\nfunction isForwardRef(object) {\n return typeOf(object) === REACT_FORWARD_REF_TYPE;\n}\nfunction isFragment(object) {\n return typeOf(object) === REACT_FRAGMENT_TYPE;\n}\nfunction isLazy(object) {\n return typeOf(object) === REACT_LAZY_TYPE;\n}\nfunction isMemo(object) {\n return typeOf(object) === REACT_MEMO_TYPE;\n}\nfunction isPortal(object) {\n return typeOf(object) === REACT_PORTAL_TYPE;\n}\nfunction isProfiler(object) {\n return typeOf(object) === REACT_PROFILER_TYPE;\n}\nfunction isStrictMode(object) {\n return typeOf(object) === REACT_STRICT_MODE_TYPE;\n}\nfunction isSuspense(object) {\n return typeOf(object) === REACT_SUSPENSE_TYPE;\n}\nfunction isSuspenseList(object) {\n return typeOf(object) === REACT_SUSPENSE_LIST_TYPE;\n}\n\nexports.ContextConsumer = ContextConsumer;\nexports.ContextProvider = ContextProvider;\nexports.Element = Element;\nexports.ForwardRef = ForwardRef;\nexports.Fragment = Fragment;\nexports.Lazy = Lazy;\nexports.Memo = Memo;\nexports.Portal = Portal;\nexports.Profiler = Profiler;\nexports.StrictMode = StrictMode;\nexports.Suspense = Suspense;\nexports.SuspenseList = SuspenseList;\nexports.isAsyncMode = isAsyncMode;\nexports.isConcurrentMode = isConcurrentMode;\nexports.isContextConsumer = isContextConsumer;\nexports.isContextProvider = isContextProvider;\nexports.isElement = isElement;\nexports.isForwardRef = isForwardRef;\nexports.isFragment = isFragment;\nexports.isLazy = isLazy;\nexports.isMemo = isMemo;\nexports.isPortal = isPortal;\nexports.isProfiler = isProfiler;\nexports.isStrictMode = isStrictMode;\nexports.isSuspense = isSuspense;\nexports.isSuspenseList = isSuspenseList;\nexports.isValidElementType = isValidElementType;\nexports.typeOf = typeOf;\n })();\n}\n","'use strict';\n\nif (process.env.NODE_ENV === 'production') {\n module.exports = require('./cjs/react-is.production.min.js');\n} else {\n module.exports = require('./cjs/react-is.development.js');\n}\n","import { ForwardRef, Memo } from 'react-is';\n\n// Simplified polyfill for IE11 support\n// https://github.com/JamesMGreene/Function.name/blob/58b314d4a983110c3682f1228f845d39ccca1817/Function.name.js#L3\nconst fnNameMatchRegex = /^\\s*function(?:\\s|\\s*\\/\\*.*\\*\\/\\s*)+([^(\\s/]*)\\s*/;\nexport function getFunctionName(fn) {\n const match = `${fn}`.match(fnNameMatchRegex);\n const name = match && match[1];\n return name || '';\n}\nfunction getFunctionComponentName(Component, fallback = '') {\n return Component.displayName || Component.name || getFunctionName(Component) || fallback;\n}\nfunction getWrappedName(outerType, innerType, wrapperName) {\n const functionName = getFunctionComponentName(innerType);\n return outerType.displayName || (functionName !== '' ? `${wrapperName}(${functionName})` : wrapperName);\n}\n\n/**\n * cherry-pick from\n * https://github.com/facebook/react/blob/769b1f270e1251d9dbdce0fcbd9e92e502d059b8/packages/shared/getComponentName.js\n * originally forked from recompose/getDisplayName with added IE11 support\n */\nexport default function getDisplayName(Component) {\n if (Component == null) {\n return undefined;\n }\n if (typeof Component === 'string') {\n return Component;\n }\n if (typeof Component === 'function') {\n return getFunctionComponentName(Component, 'Component');\n }\n\n // TypeScript can't have components as objects but they exist in the form of `memo` or `Suspense`\n if (typeof Component === 'object') {\n switch (Component.$$typeof) {\n case ForwardRef:\n return getWrappedName(Component, Component.render, 'ForwardRef');\n case Memo:\n return getWrappedName(Component, Component.type, 'memo');\n default:\n return undefined;\n }\n }\n return undefined;\n}","export default function HTMLElementType(props, propName, componentName, location, propFullName) {\n if (process.env.NODE_ENV === 'production') {\n return null;\n }\n const propValue = props[propName];\n const safePropName = propFullName || propName;\n if (propValue == null) {\n return null;\n }\n if (propValue && propValue.nodeType !== 1) {\n return new Error(`Invalid ${location} \\`${safePropName}\\` supplied to \\`${componentName}\\`. ` + `Expected an HTMLElement.`);\n }\n return null;\n}","import PropTypes from 'prop-types';\nconst refType = PropTypes.oneOfType([PropTypes.func, PropTypes.object]);\nexport default refType;","import _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\n// It should to be noted that this function isn't equivalent to `text-transform: capitalize`.\n//\n// A strict capitalization should uppercase the first letter of each word in the sentence.\n// We only handle the first word.\nexport default function capitalize(string) {\n if (typeof string !== 'string') {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: \\`capitalize(string)\\` expects a string argument.` : _formatMuiErrorMessage(7));\n }\n return string.charAt(0).toUpperCase() + string.slice(1);\n}","/**\n * Safe chained function.\n *\n * Will only create a new function if needed,\n * otherwise will pass back existing functions or null.\n */\nexport default function createChainedFunction(...funcs) {\n return funcs.reduce((acc, func) => {\n if (func == null) {\n return acc;\n }\n return function chainedFunction(...args) {\n acc.apply(this, args);\n func.apply(this, args);\n };\n }, () => {});\n}","// Corresponds to 10 frames at 60 Hz.\n// A few bytes payload overhead when lodash/debounce is ~3 kB and debounce ~300 B.\nexport default function debounce(func, wait = 166) {\n let timeout;\n function debounced(...args) {\n const later = () => {\n // @ts-ignore\n func.apply(this, args);\n };\n clearTimeout(timeout);\n timeout = setTimeout(later, wait);\n }\n debounced.clear = () => {\n clearTimeout(timeout);\n };\n return debounced;\n}","export default function deprecatedPropType(validator, reason) {\n if (process.env.NODE_ENV === 'production') {\n return () => null;\n }\n return (props, propName, componentName, location, propFullName) => {\n const componentNameSafe = componentName || '<>';\n const propFullNameSafe = propFullName || propName;\n if (typeof props[propName] !== 'undefined') {\n return new Error(`The ${location} \\`${propFullNameSafe}\\` of ` + `\\`${componentNameSafe}\\` is deprecated. ${reason}`);\n }\n return null;\n };\n}","import * as React from 'react';\nexport default function isMuiElement(element, muiNames) {\n var _muiName, _element$type;\n return /*#__PURE__*/React.isValidElement(element) && muiNames.indexOf( // For server components `muiName` is avaialble in element.type._payload.value.muiName\n // relevant info - https://github.com/facebook/react/blob/2807d781a08db8e9873687fccc25c0f12b4fb3d4/packages/react/src/ReactLazy.js#L45\n // eslint-disable-next-line no-underscore-dangle\n (_muiName = element.type.muiName) != null ? _muiName : (_element$type = element.type) == null || (_element$type = _element$type._payload) == null || (_element$type = _element$type.value) == null ? void 0 : _element$type.muiName) !== -1;\n}","export default function ownerDocument(node) {\n return node && node.ownerDocument || document;\n}","import ownerDocument from '../ownerDocument';\nexport default function ownerWindow(node) {\n const doc = ownerDocument(node);\n return doc.defaultView || window;\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nexport default function requirePropFactory(componentNameInError, Component) {\n if (process.env.NODE_ENV === 'production') {\n return () => null;\n }\n\n // eslint-disable-next-line react/forbid-foreign-prop-types\n const prevPropTypes = Component ? _extends({}, Component.propTypes) : null;\n const requireProp = requiredProp => (props, propName, componentName, location, propFullName, ...args) => {\n const propFullNameSafe = propFullName || propName;\n const defaultTypeChecker = prevPropTypes == null ? void 0 : prevPropTypes[propFullNameSafe];\n if (defaultTypeChecker) {\n const typeCheckerResult = defaultTypeChecker(props, propName, componentName, location, propFullName, ...args);\n if (typeCheckerResult) {\n return typeCheckerResult;\n }\n }\n if (typeof props[propName] !== 'undefined' && !props[requiredProp]) {\n return new Error(`The prop \\`${propFullNameSafe}\\` of ` + `\\`${componentNameInError}\\` can only be used together with the \\`${requiredProp}\\` prop.`);\n }\n return null;\n };\n return requireProp;\n}","/**\n * TODO v5: consider making it private\n *\n * passes {value} to {ref}\n *\n * WARNING: Be sure to only call this inside a callback that is passed as a ref.\n * Otherwise, make sure to cleanup the previous {ref} if it changes. See\n * https://github.com/mui/material-ui/issues/13539\n *\n * Useful if you want to expose the ref of an inner component to the public API\n * while still using it inside the component.\n * @param ref A ref callback or ref object. If anything falsy, this is a no-op.\n */\nexport default function setRef(ref, value) {\n if (typeof ref === 'function') {\n ref(value);\n } else if (ref) {\n ref.current = value;\n }\n}","'use client';\n\nimport * as React from 'react';\n\n/**\n * A version of `React.useLayoutEffect` that does not show a warning when server-side rendering.\n * This is useful for effects that are only needed for client-side rendering but not for SSR.\n *\n * Before you use this hook, make sure to read https://gist.github.com/gaearon/e7d97cdf38a2907924ea12e4ebdf3c85\n * and confirm it doesn't apply to your use-case.\n */\nconst useEnhancedEffect = typeof window !== 'undefined' ? React.useLayoutEffect : React.useEffect;\nexport default useEnhancedEffect;","'use client';\n\nimport * as React from 'react';\nlet globalId = 0;\nfunction useGlobalId(idOverride) {\n const [defaultId, setDefaultId] = React.useState(idOverride);\n const id = idOverride || defaultId;\n React.useEffect(() => {\n if (defaultId == null) {\n // Fallback to this default id when possible.\n // Use the incrementing value for client-side rendering only.\n // We can't use it server-side.\n // If you want to use random values please consider the Birthday Problem: https://en.wikipedia.org/wiki/Birthday_problem\n globalId += 1;\n setDefaultId(`mui-${globalId}`);\n }\n }, [defaultId]);\n return id;\n}\n\n// downstream bundlers may remove unnecessary concatenation, but won't remove toString call -- Workaround for https://github.com/webpack/webpack/issues/14814\nconst maybeReactUseId = React['useId'.toString()];\n/**\n *\n * @example
    \n * @param idOverride\n * @returns {string}\n */\nexport default function useId(idOverride) {\n if (maybeReactUseId !== undefined) {\n const reactId = maybeReactUseId();\n return idOverride != null ? idOverride : reactId;\n }\n // eslint-disable-next-line react-hooks/rules-of-hooks -- `React.useId` is invariant at runtime.\n return useGlobalId(idOverride);\n}","export default function unsupportedProp(props, propName, componentName, location, propFullName) {\n if (process.env.NODE_ENV === 'production') {\n return null;\n }\n const propFullNameSafe = propFullName || propName;\n if (typeof props[propName] !== 'undefined') {\n return new Error(`The prop \\`${propFullNameSafe}\\` is not supported. Please remove it.`);\n }\n return null;\n}","'use client';\n\n/* eslint-disable react-hooks/rules-of-hooks, react-hooks/exhaustive-deps */\nimport * as React from 'react';\nexport default function useControlled({\n controlled,\n default: defaultProp,\n name,\n state = 'value'\n}) {\n // isControlled is ignored in the hook dependency lists as it should never change.\n const {\n current: isControlled\n } = React.useRef(controlled !== undefined);\n const [valueState, setValue] = React.useState(defaultProp);\n const value = isControlled ? controlled : valueState;\n if (process.env.NODE_ENV !== 'production') {\n React.useEffect(() => {\n if (isControlled !== (controlled !== undefined)) {\n console.error([`MUI: A component is changing the ${isControlled ? '' : 'un'}controlled ${state} state of ${name} to be ${isControlled ? 'un' : ''}controlled.`, 'Elements should not switch from uncontrolled to controlled (or vice versa).', `Decide between using a controlled or uncontrolled ${name} ` + 'element for the lifetime of the component.', \"The nature of the state is determined during the first render. It's considered controlled if the value is not `undefined`.\", 'More info: https://fb.me/react-controlled-components'].join('\\n'));\n }\n }, [state, name, controlled]);\n const {\n current: defaultValue\n } = React.useRef(defaultProp);\n React.useEffect(() => {\n if (!isControlled && defaultValue !== defaultProp) {\n console.error([`MUI: A component is changing the default ${state} state of an uncontrolled ${name} after being initialized. ` + `To suppress this warning opt to use a controlled ${name}.`].join('\\n'));\n }\n }, [JSON.stringify(defaultProp)]);\n }\n const setValueIfUncontrolled = React.useCallback(newValue => {\n if (!isControlled) {\n setValue(newValue);\n }\n }, []);\n return [value, setValueIfUncontrolled];\n}","'use client';\n\nimport * as React from 'react';\nimport useEnhancedEffect from '../useEnhancedEffect';\n\n/**\n * Inspired by https://github.com/facebook/react/issues/14099#issuecomment-440013892\n * See RFC in https://github.com/reactjs/rfcs/pull/220\n */\n\nfunction useEventCallback(fn) {\n const ref = React.useRef(fn);\n useEnhancedEffect(() => {\n ref.current = fn;\n });\n return React.useRef((...args) =>\n // @ts-expect-error hide `this`\n (0, ref.current)(...args)).current;\n}\nexport default useEventCallback;","'use client';\n\nimport * as React from 'react';\nimport setRef from '../setRef';\nexport default function useForkRef(...refs) {\n /**\n * This will create a new function if the refs passed to this hook change and are all defined.\n * This means react will call the old forkRef with `null` and the new forkRef\n * with the ref. Cleanup naturally emerges from this behavior.\n */\n return React.useMemo(() => {\n if (refs.every(ref => ref == null)) {\n return null;\n }\n return instance => {\n refs.forEach(ref => {\n setRef(ref, instance);\n });\n };\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, refs);\n}","'use client';\n\nimport * as React from 'react';\nconst UNINITIALIZED = {};\n\n/**\n * A React.useRef() that is initialized lazily with a function. Note that it accepts an optional\n * initialization argument, so the initialization function doesn't need to be an inline closure.\n *\n * @usage\n * const ref = useLazyRef(sortColumns, columns)\n */\nexport default function useLazyRef(init, initArg) {\n const ref = React.useRef(UNINITIALIZED);\n if (ref.current === UNINITIALIZED) {\n ref.current = init(initArg);\n }\n return ref;\n}","'use client';\n\nimport * as React from 'react';\nconst EMPTY = [];\n\n/**\n * A React.useEffect equivalent that runs once, when the component is mounted.\n */\nexport default function useOnMount(fn) {\n /* eslint-disable react-hooks/exhaustive-deps */\n React.useEffect(fn, EMPTY);\n /* eslint-enable react-hooks/exhaustive-deps */\n}","'use client';\n\nimport useLazyRef from '../useLazyRef/useLazyRef';\nimport useOnMount from '../useOnMount/useOnMount';\nexport class Timeout {\n constructor() {\n this.currentId = null;\n this.clear = () => {\n if (this.currentId !== null) {\n clearTimeout(this.currentId);\n this.currentId = null;\n }\n };\n this.disposeEffect = () => {\n return this.clear;\n };\n }\n static create() {\n return new Timeout();\n }\n /**\n * Executes `fn` after `delay`, clearing any previously scheduled call.\n */\n start(delay, fn) {\n this.clear();\n this.currentId = setTimeout(() => {\n this.currentId = null;\n fn();\n }, delay);\n }\n}\nexport default function useTimeout() {\n const timeout = useLazyRef(Timeout.create).current;\n useOnMount(timeout.disposeEffect);\n return timeout;\n}","'use client';\n\n// based on https://github.com/WICG/focus-visible/blob/v4.1.5/src/focus-visible.js\nimport * as React from 'react';\nimport { Timeout } from '../useTimeout/useTimeout';\nlet hadKeyboardEvent = true;\nlet hadFocusVisibleRecently = false;\nconst hadFocusVisibleRecentlyTimeout = new Timeout();\nconst inputTypesWhitelist = {\n text: true,\n search: true,\n url: true,\n tel: true,\n email: true,\n password: true,\n number: true,\n date: true,\n month: true,\n week: true,\n time: true,\n datetime: true,\n 'datetime-local': true\n};\n\n/**\n * Computes whether the given element should automatically trigger the\n * `focus-visible` class being added, i.e. whether it should always match\n * `:focus-visible` when focused.\n * @param {Element} node\n * @returns {boolean}\n */\nfunction focusTriggersKeyboardModality(node) {\n const {\n type,\n tagName\n } = node;\n if (tagName === 'INPUT' && inputTypesWhitelist[type] && !node.readOnly) {\n return true;\n }\n if (tagName === 'TEXTAREA' && !node.readOnly) {\n return true;\n }\n if (node.isContentEditable) {\n return true;\n }\n return false;\n}\n\n/**\n * Keep track of our keyboard modality state with `hadKeyboardEvent`.\n * If the most recent user interaction was via the keyboard;\n * and the key press did not include a meta, alt/option, or control key;\n * then the modality is keyboard. Otherwise, the modality is not keyboard.\n * @param {KeyboardEvent} event\n */\nfunction handleKeyDown(event) {\n if (event.metaKey || event.altKey || event.ctrlKey) {\n return;\n }\n hadKeyboardEvent = true;\n}\n\n/**\n * If at any point a user clicks with a pointing device, ensure that we change\n * the modality away from keyboard.\n * This avoids the situation where a user presses a key on an already focused\n * element, and then clicks on a different element, focusing it with a\n * pointing device, while we still think we're in keyboard modality.\n */\nfunction handlePointerDown() {\n hadKeyboardEvent = false;\n}\nfunction handleVisibilityChange() {\n if (this.visibilityState === 'hidden') {\n // If the tab becomes active again, the browser will handle calling focus\n // on the element (Safari actually calls it twice).\n // If this tab change caused a blur on an element with focus-visible,\n // re-apply the class when the user switches back to the tab.\n if (hadFocusVisibleRecently) {\n hadKeyboardEvent = true;\n }\n }\n}\nfunction prepare(doc) {\n doc.addEventListener('keydown', handleKeyDown, true);\n doc.addEventListener('mousedown', handlePointerDown, true);\n doc.addEventListener('pointerdown', handlePointerDown, true);\n doc.addEventListener('touchstart', handlePointerDown, true);\n doc.addEventListener('visibilitychange', handleVisibilityChange, true);\n}\nexport function teardown(doc) {\n doc.removeEventListener('keydown', handleKeyDown, true);\n doc.removeEventListener('mousedown', handlePointerDown, true);\n doc.removeEventListener('pointerdown', handlePointerDown, true);\n doc.removeEventListener('touchstart', handlePointerDown, true);\n doc.removeEventListener('visibilitychange', handleVisibilityChange, true);\n}\nfunction isFocusVisible(event) {\n const {\n target\n } = event;\n try {\n return target.matches(':focus-visible');\n } catch (error) {\n // Browsers not implementing :focus-visible will throw a SyntaxError.\n // We use our own heuristic for those browsers.\n // Rethrow might be better if it's not the expected error but do we really\n // want to crash if focus-visible malfunctioned?\n }\n\n // No need for validFocusTarget check. The user does that by attaching it to\n // focusable events only.\n return hadKeyboardEvent || focusTriggersKeyboardModality(target);\n}\nexport default function useIsFocusVisible() {\n const ref = React.useCallback(node => {\n if (node != null) {\n prepare(node.ownerDocument);\n }\n }, []);\n const isFocusVisibleRef = React.useRef(false);\n\n /**\n * Should be called if a blur event is fired\n */\n function handleBlurVisible() {\n // checking against potential state variable does not suffice if we focus and blur synchronously.\n // React wouldn't have time to trigger a re-render so `focusVisible` would be stale.\n // Ideally we would adjust `isFocusVisible(event)` to look at `relatedTarget` for blur events.\n // This doesn't work in IE11 due to https://github.com/facebook/react/issues/3751\n // TODO: check again if React releases their internal changes to focus event handling (https://github.com/facebook/react/pull/19186).\n if (isFocusVisibleRef.current) {\n // To detect a tab/window switch, we look for a blur event followed\n // rapidly by a visibility change.\n // If we don't see a visibility change within 100ms, it's probably a\n // regular focus change.\n hadFocusVisibleRecently = true;\n hadFocusVisibleRecentlyTimeout.start(100, () => {\n hadFocusVisibleRecently = false;\n });\n isFocusVisibleRef.current = false;\n return true;\n }\n return false;\n }\n\n /**\n * Should be called if a blur event is fired\n */\n function handleFocusVisible(event) {\n if (isFocusVisible(event)) {\n isFocusVisibleRef.current = true;\n return true;\n }\n return false;\n }\n return {\n isFocusVisibleRef,\n onFocus: handleFocusVisible,\n onBlur: handleBlurVisible,\n ref\n };\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\n/**\n * Add keys, values of `defaultProps` that does not exist in `props`\n * @param {object} defaultProps\n * @param {object} props\n * @returns {object} resolved props\n */\nexport default function resolveProps(defaultProps, props) {\n const output = _extends({}, props);\n Object.keys(defaultProps).forEach(propName => {\n if (propName.toString().match(/^(components|slots)$/)) {\n output[propName] = _extends({}, defaultProps[propName], output[propName]);\n } else if (propName.toString().match(/^(componentsProps|slotProps)$/)) {\n const defaultSlotProps = defaultProps[propName] || {};\n const slotProps = props[propName];\n output[propName] = {};\n if (!slotProps || !Object.keys(slotProps)) {\n // Reduce the iteration if the slot props is empty\n output[propName] = defaultSlotProps;\n } else if (!defaultSlotProps || !Object.keys(defaultSlotProps)) {\n // Reduce the iteration if the default slot props is empty\n output[propName] = slotProps;\n } else {\n output[propName] = _extends({}, slotProps);\n Object.keys(defaultSlotProps).forEach(slotPropName => {\n output[propName][slotPropName] = resolveProps(defaultSlotProps[slotPropName], slotProps[slotPropName]);\n });\n }\n } else if (output[propName] === undefined) {\n output[propName] = defaultProps[propName];\n }\n });\n return output;\n}","export default function composeClasses(slots, getUtilityClass, classes = undefined) {\n const output = {};\n Object.keys(slots).forEach(\n // `Object.keys(slots)` can't be wider than `T` because we infer `T` from `slots`.\n // @ts-expect-error https://github.com/microsoft/TypeScript/pull/12253#issuecomment-263132208\n slot => {\n output[slot] = slots[slot].reduce((acc, key) => {\n if (key) {\n const utilityClass = getUtilityClass(key);\n if (utilityClass !== '') {\n acc.push(utilityClass);\n }\n if (classes && classes[key]) {\n acc.push(classes[key]);\n }\n }\n return acc;\n }, []).join(' ');\n });\n return output;\n}","const defaultGenerator = componentName => componentName;\nconst createClassNameGenerator = () => {\n let generate = defaultGenerator;\n return {\n configure(generator) {\n generate = generator;\n },\n generate(componentName) {\n return generate(componentName);\n },\n reset() {\n generate = defaultGenerator;\n }\n };\n};\nconst ClassNameGenerator = createClassNameGenerator();\nexport default ClassNameGenerator;","import ClassNameGenerator from '../ClassNameGenerator';\nexport const globalStateClasses = {\n active: 'active',\n checked: 'checked',\n completed: 'completed',\n disabled: 'disabled',\n error: 'error',\n expanded: 'expanded',\n focused: 'focused',\n focusVisible: 'focusVisible',\n open: 'open',\n readOnly: 'readOnly',\n required: 'required',\n selected: 'selected'\n};\nexport default function generateUtilityClass(componentName, slot, globalStatePrefix = 'Mui') {\n const globalStateClass = globalStateClasses[slot];\n return globalStateClass ? `${globalStatePrefix}-${globalStateClass}` : `${ClassNameGenerator.generate(componentName)}-${slot}`;\n}\nexport function isGlobalState(slot) {\n return globalStateClasses[slot] !== undefined;\n}","import generateUtilityClass from '../generateUtilityClass';\nexport default function generateUtilityClasses(componentName, slots, globalStatePrefix = 'Mui') {\n const result = {};\n slots.forEach(slot => {\n result[slot] = generateUtilityClass(componentName, slot, globalStatePrefix);\n });\n return result;\n}","function clamp(val, min = Number.MIN_SAFE_INTEGER, max = Number.MAX_SAFE_INTEGER) {\n return Math.max(min, Math.min(val, max));\n}\nexport default clamp;","export default function _objectWithoutPropertiesLoose(source, excluded) {\n if (source == null) return {};\n var target = {};\n var sourceKeys = Object.keys(source);\n var key, i;\n for (i = 0; i < sourceKeys.length; i++) {\n key = sourceKeys[i];\n if (excluded.indexOf(key) >= 0) continue;\n target[key] = source[key];\n }\n return target;\n}","import _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nconst _excluded = [\"values\", \"unit\", \"step\"];\n// Sorted ASC by size. That's important.\n// It can't be configured as it's used statically for propTypes.\nexport const breakpointKeys = ['xs', 'sm', 'md', 'lg', 'xl'];\nconst sortBreakpointsValues = values => {\n const breakpointsAsArray = Object.keys(values).map(key => ({\n key,\n val: values[key]\n })) || [];\n // Sort in ascending order\n breakpointsAsArray.sort((breakpoint1, breakpoint2) => breakpoint1.val - breakpoint2.val);\n return breakpointsAsArray.reduce((acc, obj) => {\n return _extends({}, acc, {\n [obj.key]: obj.val\n });\n }, {});\n};\n\n// Keep in mind that @media is inclusive by the CSS specification.\nexport default function createBreakpoints(breakpoints) {\n const {\n // The breakpoint **start** at this value.\n // For instance with the first breakpoint xs: [xs, sm).\n values = {\n xs: 0,\n // phone\n sm: 600,\n // tablet\n md: 900,\n // small laptop\n lg: 1200,\n // desktop\n xl: 1536 // large screen\n },\n unit = 'px',\n step = 5\n } = breakpoints,\n other = _objectWithoutPropertiesLoose(breakpoints, _excluded);\n const sortedValues = sortBreakpointsValues(values);\n const keys = Object.keys(sortedValues);\n function up(key) {\n const value = typeof values[key] === 'number' ? values[key] : key;\n return `@media (min-width:${value}${unit})`;\n }\n function down(key) {\n const value = typeof values[key] === 'number' ? values[key] : key;\n return `@media (max-width:${value - step / 100}${unit})`;\n }\n function between(start, end) {\n const endIndex = keys.indexOf(end);\n return `@media (min-width:${typeof values[start] === 'number' ? values[start] : start}${unit}) and ` + `(max-width:${(endIndex !== -1 && typeof values[keys[endIndex]] === 'number' ? values[keys[endIndex]] : end) - step / 100}${unit})`;\n }\n function only(key) {\n if (keys.indexOf(key) + 1 < keys.length) {\n return between(key, keys[keys.indexOf(key) + 1]);\n }\n return up(key);\n }\n function not(key) {\n // handle first and last key separately, for better readability\n const keyIndex = keys.indexOf(key);\n if (keyIndex === 0) {\n return up(keys[1]);\n }\n if (keyIndex === keys.length - 1) {\n return down(keys[keyIndex]);\n }\n return between(key, keys[keys.indexOf(key) + 1]).replace('@media', '@media not all and');\n }\n return _extends({\n keys,\n values: sortedValues,\n up,\n down,\n between,\n only,\n not,\n unit\n }, other);\n}","const shape = {\n borderRadius: 4\n};\nexport default shape;","import PropTypes from 'prop-types';\nconst responsivePropType = process.env.NODE_ENV !== 'production' ? PropTypes.oneOfType([PropTypes.number, PropTypes.string, PropTypes.object, PropTypes.array]) : {};\nexport default responsivePropType;","import deepmerge from '@mui/utils/deepmerge';\nfunction merge(acc, item) {\n if (!item) {\n return acc;\n }\n return deepmerge(acc, item, {\n clone: false // No need to clone deep, it's way faster.\n });\n}\nexport default merge;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport PropTypes from 'prop-types';\nimport deepmerge from '@mui/utils/deepmerge';\nimport merge from './merge';\n\n// The breakpoint **start** at this value.\n// For instance with the first breakpoint xs: [xs, sm[.\nexport const values = {\n xs: 0,\n // phone\n sm: 600,\n // tablet\n md: 900,\n // small laptop\n lg: 1200,\n // desktop\n xl: 1536 // large screen\n};\nconst defaultBreakpoints = {\n // Sorted ASC by size. That's important.\n // It can't be configured as it's used statically for propTypes.\n keys: ['xs', 'sm', 'md', 'lg', 'xl'],\n up: key => `@media (min-width:${values[key]}px)`\n};\nexport function handleBreakpoints(props, propValue, styleFromPropValue) {\n const theme = props.theme || {};\n if (Array.isArray(propValue)) {\n const themeBreakpoints = theme.breakpoints || defaultBreakpoints;\n return propValue.reduce((acc, item, index) => {\n acc[themeBreakpoints.up(themeBreakpoints.keys[index])] = styleFromPropValue(propValue[index]);\n return acc;\n }, {});\n }\n if (typeof propValue === 'object') {\n const themeBreakpoints = theme.breakpoints || defaultBreakpoints;\n return Object.keys(propValue).reduce((acc, breakpoint) => {\n // key is breakpoint\n if (Object.keys(themeBreakpoints.values || values).indexOf(breakpoint) !== -1) {\n const mediaKey = themeBreakpoints.up(breakpoint);\n acc[mediaKey] = styleFromPropValue(propValue[breakpoint], breakpoint);\n } else {\n const cssKey = breakpoint;\n acc[cssKey] = propValue[cssKey];\n }\n return acc;\n }, {});\n }\n const output = styleFromPropValue(propValue);\n return output;\n}\nfunction breakpoints(styleFunction) {\n // false positive\n // eslint-disable-next-line react/function-component-definition\n const newStyleFunction = props => {\n const theme = props.theme || {};\n const base = styleFunction(props);\n const themeBreakpoints = theme.breakpoints || defaultBreakpoints;\n const extended = themeBreakpoints.keys.reduce((acc, key) => {\n if (props[key]) {\n acc = acc || {};\n acc[themeBreakpoints.up(key)] = styleFunction(_extends({\n theme\n }, props[key]));\n }\n return acc;\n }, null);\n return merge(base, extended);\n };\n newStyleFunction.propTypes = process.env.NODE_ENV !== 'production' ? _extends({}, styleFunction.propTypes, {\n xs: PropTypes.object,\n sm: PropTypes.object,\n md: PropTypes.object,\n lg: PropTypes.object,\n xl: PropTypes.object\n }) : {};\n newStyleFunction.filterProps = ['xs', 'sm', 'md', 'lg', 'xl', ...styleFunction.filterProps];\n return newStyleFunction;\n}\nexport function createEmptyBreakpointObject(breakpointsInput = {}) {\n var _breakpointsInput$key;\n const breakpointsInOrder = (_breakpointsInput$key = breakpointsInput.keys) == null ? void 0 : _breakpointsInput$key.reduce((acc, key) => {\n const breakpointStyleKey = breakpointsInput.up(key);\n acc[breakpointStyleKey] = {};\n return acc;\n }, {});\n return breakpointsInOrder || {};\n}\nexport function removeUnusedBreakpoints(breakpointKeys, style) {\n return breakpointKeys.reduce((acc, key) => {\n const breakpointOutput = acc[key];\n const isBreakpointUnused = !breakpointOutput || Object.keys(breakpointOutput).length === 0;\n if (isBreakpointUnused) {\n delete acc[key];\n }\n return acc;\n }, style);\n}\nexport function mergeBreakpointsInOrder(breakpointsInput, ...styles) {\n const emptyBreakpoints = createEmptyBreakpointObject(breakpointsInput);\n const mergedOutput = [emptyBreakpoints, ...styles].reduce((prev, next) => deepmerge(prev, next), {});\n return removeUnusedBreakpoints(Object.keys(emptyBreakpoints), mergedOutput);\n}\n\n// compute base for responsive values; e.g.,\n// [1,2,3] => {xs: true, sm: true, md: true}\n// {xs: 1, sm: 2, md: 3} => {xs: true, sm: true, md: true}\nexport function computeBreakpointsBase(breakpointValues, themeBreakpoints) {\n // fixed value\n if (typeof breakpointValues !== 'object') {\n return {};\n }\n const base = {};\n const breakpointsKeys = Object.keys(themeBreakpoints);\n if (Array.isArray(breakpointValues)) {\n breakpointsKeys.forEach((breakpoint, i) => {\n if (i < breakpointValues.length) {\n base[breakpoint] = true;\n }\n });\n } else {\n breakpointsKeys.forEach(breakpoint => {\n if (breakpointValues[breakpoint] != null) {\n base[breakpoint] = true;\n }\n });\n }\n return base;\n}\nexport function resolveBreakpointValues({\n values: breakpointValues,\n breakpoints: themeBreakpoints,\n base: customBase\n}) {\n const base = customBase || computeBreakpointsBase(breakpointValues, themeBreakpoints);\n const keys = Object.keys(base);\n if (keys.length === 0) {\n return breakpointValues;\n }\n let previous;\n return keys.reduce((acc, breakpoint, i) => {\n if (Array.isArray(breakpointValues)) {\n acc[breakpoint] = breakpointValues[i] != null ? breakpointValues[i] : breakpointValues[previous];\n previous = i;\n } else if (typeof breakpointValues === 'object') {\n acc[breakpoint] = breakpointValues[breakpoint] != null ? breakpointValues[breakpoint] : breakpointValues[previous];\n previous = breakpoint;\n } else {\n acc[breakpoint] = breakpointValues;\n }\n return acc;\n }, {});\n}\nexport default breakpoints;","import capitalize from '@mui/utils/capitalize';\nimport responsivePropType from './responsivePropType';\nimport { handleBreakpoints } from './breakpoints';\nexport function getPath(obj, path, checkVars = true) {\n if (!path || typeof path !== 'string') {\n return null;\n }\n\n // Check if CSS variables are used\n if (obj && obj.vars && checkVars) {\n const val = `vars.${path}`.split('.').reduce((acc, item) => acc && acc[item] ? acc[item] : null, obj);\n if (val != null) {\n return val;\n }\n }\n return path.split('.').reduce((acc, item) => {\n if (acc && acc[item] != null) {\n return acc[item];\n }\n return null;\n }, obj);\n}\nexport function getStyleValue(themeMapping, transform, propValueFinal, userValue = propValueFinal) {\n let value;\n if (typeof themeMapping === 'function') {\n value = themeMapping(propValueFinal);\n } else if (Array.isArray(themeMapping)) {\n value = themeMapping[propValueFinal] || userValue;\n } else {\n value = getPath(themeMapping, propValueFinal) || userValue;\n }\n if (transform) {\n value = transform(value, userValue, themeMapping);\n }\n return value;\n}\nfunction style(options) {\n const {\n prop,\n cssProperty = options.prop,\n themeKey,\n transform\n } = options;\n\n // false positive\n // eslint-disable-next-line react/function-component-definition\n const fn = props => {\n if (props[prop] == null) {\n return null;\n }\n const propValue = props[prop];\n const theme = props.theme;\n const themeMapping = getPath(theme, themeKey) || {};\n const styleFromPropValue = propValueFinal => {\n let value = getStyleValue(themeMapping, transform, propValueFinal);\n if (propValueFinal === value && typeof propValueFinal === 'string') {\n // Haven't found value\n value = getStyleValue(themeMapping, transform, `${prop}${propValueFinal === 'default' ? '' : capitalize(propValueFinal)}`, propValueFinal);\n }\n if (cssProperty === false) {\n return value;\n }\n return {\n [cssProperty]: value\n };\n };\n return handleBreakpoints(props, propValue, styleFromPropValue);\n };\n fn.propTypes = process.env.NODE_ENV !== 'production' ? {\n [prop]: responsivePropType\n } : {};\n fn.filterProps = [prop];\n return fn;\n}\nexport default style;","export default function memoize(fn) {\n const cache = {};\n return arg => {\n if (cache[arg] === undefined) {\n cache[arg] = fn(arg);\n }\n return cache[arg];\n };\n}","import responsivePropType from './responsivePropType';\nimport { handleBreakpoints } from './breakpoints';\nimport { getPath } from './style';\nimport merge from './merge';\nimport memoize from './memoize';\nconst properties = {\n m: 'margin',\n p: 'padding'\n};\nconst directions = {\n t: 'Top',\n r: 'Right',\n b: 'Bottom',\n l: 'Left',\n x: ['Left', 'Right'],\n y: ['Top', 'Bottom']\n};\nconst aliases = {\n marginX: 'mx',\n marginY: 'my',\n paddingX: 'px',\n paddingY: 'py'\n};\n\n// memoize() impact:\n// From 300,000 ops/sec\n// To 350,000 ops/sec\nconst getCssProperties = memoize(prop => {\n // It's not a shorthand notation.\n if (prop.length > 2) {\n if (aliases[prop]) {\n prop = aliases[prop];\n } else {\n return [prop];\n }\n }\n const [a, b] = prop.split('');\n const property = properties[a];\n const direction = directions[b] || '';\n return Array.isArray(direction) ? direction.map(dir => property + dir) : [property + direction];\n});\nexport const marginKeys = ['m', 'mt', 'mr', 'mb', 'ml', 'mx', 'my', 'margin', 'marginTop', 'marginRight', 'marginBottom', 'marginLeft', 'marginX', 'marginY', 'marginInline', 'marginInlineStart', 'marginInlineEnd', 'marginBlock', 'marginBlockStart', 'marginBlockEnd'];\nexport const paddingKeys = ['p', 'pt', 'pr', 'pb', 'pl', 'px', 'py', 'padding', 'paddingTop', 'paddingRight', 'paddingBottom', 'paddingLeft', 'paddingX', 'paddingY', 'paddingInline', 'paddingInlineStart', 'paddingInlineEnd', 'paddingBlock', 'paddingBlockStart', 'paddingBlockEnd'];\nconst spacingKeys = [...marginKeys, ...paddingKeys];\nexport function createUnaryUnit(theme, themeKey, defaultValue, propName) {\n var _getPath;\n const themeSpacing = (_getPath = getPath(theme, themeKey, false)) != null ? _getPath : defaultValue;\n if (typeof themeSpacing === 'number') {\n return abs => {\n if (typeof abs === 'string') {\n return abs;\n }\n if (process.env.NODE_ENV !== 'production') {\n if (typeof abs !== 'number') {\n console.error(`MUI: Expected ${propName} argument to be a number or a string, got ${abs}.`);\n }\n }\n return themeSpacing * abs;\n };\n }\n if (Array.isArray(themeSpacing)) {\n return abs => {\n if (typeof abs === 'string') {\n return abs;\n }\n if (process.env.NODE_ENV !== 'production') {\n if (!Number.isInteger(abs)) {\n console.error([`MUI: The \\`theme.${themeKey}\\` array type cannot be combined with non integer values.` + `You should either use an integer value that can be used as index, or define the \\`theme.${themeKey}\\` as a number.`].join('\\n'));\n } else if (abs > themeSpacing.length - 1) {\n console.error([`MUI: The value provided (${abs}) overflows.`, `The supported values are: ${JSON.stringify(themeSpacing)}.`, `${abs} > ${themeSpacing.length - 1}, you need to add the missing values.`].join('\\n'));\n }\n }\n return themeSpacing[abs];\n };\n }\n if (typeof themeSpacing === 'function') {\n return themeSpacing;\n }\n if (process.env.NODE_ENV !== 'production') {\n console.error([`MUI: The \\`theme.${themeKey}\\` value (${themeSpacing}) is invalid.`, 'It should be a number, an array or a function.'].join('\\n'));\n }\n return () => undefined;\n}\nexport function createUnarySpacing(theme) {\n return createUnaryUnit(theme, 'spacing', 8, 'spacing');\n}\nexport function getValue(transformer, propValue) {\n if (typeof propValue === 'string' || propValue == null) {\n return propValue;\n }\n const abs = Math.abs(propValue);\n const transformed = transformer(abs);\n if (propValue >= 0) {\n return transformed;\n }\n if (typeof transformed === 'number') {\n return -transformed;\n }\n return `-${transformed}`;\n}\nexport function getStyleFromPropValue(cssProperties, transformer) {\n return propValue => cssProperties.reduce((acc, cssProperty) => {\n acc[cssProperty] = getValue(transformer, propValue);\n return acc;\n }, {});\n}\nfunction resolveCssProperty(props, keys, prop, transformer) {\n // Using a hash computation over an array iteration could be faster, but with only 28 items,\n // it's doesn't worth the bundle size.\n if (keys.indexOf(prop) === -1) {\n return null;\n }\n const cssProperties = getCssProperties(prop);\n const styleFromPropValue = getStyleFromPropValue(cssProperties, transformer);\n const propValue = props[prop];\n return handleBreakpoints(props, propValue, styleFromPropValue);\n}\nfunction style(props, keys) {\n const transformer = createUnarySpacing(props.theme);\n return Object.keys(props).map(prop => resolveCssProperty(props, keys, prop, transformer)).reduce(merge, {});\n}\nexport function margin(props) {\n return style(props, marginKeys);\n}\nmargin.propTypes = process.env.NODE_ENV !== 'production' ? marginKeys.reduce((obj, key) => {\n obj[key] = responsivePropType;\n return obj;\n}, {}) : {};\nmargin.filterProps = marginKeys;\nexport function padding(props) {\n return style(props, paddingKeys);\n}\npadding.propTypes = process.env.NODE_ENV !== 'production' ? paddingKeys.reduce((obj, key) => {\n obj[key] = responsivePropType;\n return obj;\n}, {}) : {};\npadding.filterProps = paddingKeys;\nfunction spacing(props) {\n return style(props, spacingKeys);\n}\nspacing.propTypes = process.env.NODE_ENV !== 'production' ? spacingKeys.reduce((obj, key) => {\n obj[key] = responsivePropType;\n return obj;\n}, {}) : {};\nspacing.filterProps = spacingKeys;\nexport default spacing;","import { createUnarySpacing } from '../spacing';\n\n// The different signatures imply different meaning for their arguments that can't be expressed structurally.\n// We express the difference with variable names.\n\nexport default function createSpacing(spacingInput = 8) {\n // Already transformed.\n if (spacingInput.mui) {\n return spacingInput;\n }\n\n // Material Design layouts are visually balanced. Most measurements align to an 8dp grid, which aligns both spacing and the overall layout.\n // Smaller components, such as icons, can align to a 4dp grid.\n // https://m2.material.io/design/layout/understanding-layout.html\n const transform = createUnarySpacing({\n spacing: spacingInput\n });\n const spacing = (...argsInput) => {\n if (process.env.NODE_ENV !== 'production') {\n if (!(argsInput.length <= 4)) {\n console.error(`MUI: Too many arguments provided, expected between 0 and 4, got ${argsInput.length}`);\n }\n }\n const args = argsInput.length === 0 ? [1] : argsInput;\n return args.map(argument => {\n const output = transform(argument);\n return typeof output === 'number' ? `${output}px` : output;\n }).join(' ');\n };\n spacing.mui = true;\n return spacing;\n}","import merge from './merge';\nfunction compose(...styles) {\n const handlers = styles.reduce((acc, style) => {\n style.filterProps.forEach(prop => {\n acc[prop] = style;\n });\n return acc;\n }, {});\n\n // false positive\n // eslint-disable-next-line react/function-component-definition\n const fn = props => {\n return Object.keys(props).reduce((acc, prop) => {\n if (handlers[prop]) {\n return merge(acc, handlers[prop](props));\n }\n return acc;\n }, {});\n };\n fn.propTypes = process.env.NODE_ENV !== 'production' ? styles.reduce((acc, style) => Object.assign(acc, style.propTypes), {}) : {};\n fn.filterProps = styles.reduce((acc, style) => acc.concat(style.filterProps), []);\n return fn;\n}\nexport default compose;","import responsivePropType from './responsivePropType';\nimport style from './style';\nimport compose from './compose';\nimport { createUnaryUnit, getValue } from './spacing';\nimport { handleBreakpoints } from './breakpoints';\nexport function borderTransform(value) {\n if (typeof value !== 'number') {\n return value;\n }\n return `${value}px solid`;\n}\nfunction createBorderStyle(prop, transform) {\n return style({\n prop,\n themeKey: 'borders',\n transform\n });\n}\nexport const border = createBorderStyle('border', borderTransform);\nexport const borderTop = createBorderStyle('borderTop', borderTransform);\nexport const borderRight = createBorderStyle('borderRight', borderTransform);\nexport const borderBottom = createBorderStyle('borderBottom', borderTransform);\nexport const borderLeft = createBorderStyle('borderLeft', borderTransform);\nexport const borderColor = createBorderStyle('borderColor');\nexport const borderTopColor = createBorderStyle('borderTopColor');\nexport const borderRightColor = createBorderStyle('borderRightColor');\nexport const borderBottomColor = createBorderStyle('borderBottomColor');\nexport const borderLeftColor = createBorderStyle('borderLeftColor');\nexport const outline = createBorderStyle('outline', borderTransform);\nexport const outlineColor = createBorderStyle('outlineColor');\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const borderRadius = props => {\n if (props.borderRadius !== undefined && props.borderRadius !== null) {\n const transformer = createUnaryUnit(props.theme, 'shape.borderRadius', 4, 'borderRadius');\n const styleFromPropValue = propValue => ({\n borderRadius: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.borderRadius, styleFromPropValue);\n }\n return null;\n};\nborderRadius.propTypes = process.env.NODE_ENV !== 'production' ? {\n borderRadius: responsivePropType\n} : {};\nborderRadius.filterProps = ['borderRadius'];\nconst borders = compose(border, borderTop, borderRight, borderBottom, borderLeft, borderColor, borderTopColor, borderRightColor, borderBottomColor, borderLeftColor, borderRadius, outline, outlineColor);\nexport default borders;","import style from './style';\nimport compose from './compose';\nimport { createUnaryUnit, getValue } from './spacing';\nimport { handleBreakpoints } from './breakpoints';\nimport responsivePropType from './responsivePropType';\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const gap = props => {\n if (props.gap !== undefined && props.gap !== null) {\n const transformer = createUnaryUnit(props.theme, 'spacing', 8, 'gap');\n const styleFromPropValue = propValue => ({\n gap: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.gap, styleFromPropValue);\n }\n return null;\n};\ngap.propTypes = process.env.NODE_ENV !== 'production' ? {\n gap: responsivePropType\n} : {};\ngap.filterProps = ['gap'];\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const columnGap = props => {\n if (props.columnGap !== undefined && props.columnGap !== null) {\n const transformer = createUnaryUnit(props.theme, 'spacing', 8, 'columnGap');\n const styleFromPropValue = propValue => ({\n columnGap: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.columnGap, styleFromPropValue);\n }\n return null;\n};\ncolumnGap.propTypes = process.env.NODE_ENV !== 'production' ? {\n columnGap: responsivePropType\n} : {};\ncolumnGap.filterProps = ['columnGap'];\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const rowGap = props => {\n if (props.rowGap !== undefined && props.rowGap !== null) {\n const transformer = createUnaryUnit(props.theme, 'spacing', 8, 'rowGap');\n const styleFromPropValue = propValue => ({\n rowGap: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.rowGap, styleFromPropValue);\n }\n return null;\n};\nrowGap.propTypes = process.env.NODE_ENV !== 'production' ? {\n rowGap: responsivePropType\n} : {};\nrowGap.filterProps = ['rowGap'];\nexport const gridColumn = style({\n prop: 'gridColumn'\n});\nexport const gridRow = style({\n prop: 'gridRow'\n});\nexport const gridAutoFlow = style({\n prop: 'gridAutoFlow'\n});\nexport const gridAutoColumns = style({\n prop: 'gridAutoColumns'\n});\nexport const gridAutoRows = style({\n prop: 'gridAutoRows'\n});\nexport const gridTemplateColumns = style({\n prop: 'gridTemplateColumns'\n});\nexport const gridTemplateRows = style({\n prop: 'gridTemplateRows'\n});\nexport const gridTemplateAreas = style({\n prop: 'gridTemplateAreas'\n});\nexport const gridArea = style({\n prop: 'gridArea'\n});\nconst grid = compose(gap, columnGap, rowGap, gridColumn, gridRow, gridAutoFlow, gridAutoColumns, gridAutoRows, gridTemplateColumns, gridTemplateRows, gridTemplateAreas, gridArea);\nexport default grid;","import style from './style';\nimport compose from './compose';\nexport function paletteTransform(value, userValue) {\n if (userValue === 'grey') {\n return userValue;\n }\n return value;\n}\nexport const color = style({\n prop: 'color',\n themeKey: 'palette',\n transform: paletteTransform\n});\nexport const bgcolor = style({\n prop: 'bgcolor',\n cssProperty: 'backgroundColor',\n themeKey: 'palette',\n transform: paletteTransform\n});\nexport const backgroundColor = style({\n prop: 'backgroundColor',\n themeKey: 'palette',\n transform: paletteTransform\n});\nconst palette = compose(color, bgcolor, backgroundColor);\nexport default palette;","import style from './style';\nimport compose from './compose';\nimport { handleBreakpoints, values as breakpointsValues } from './breakpoints';\nexport function sizingTransform(value) {\n return value <= 1 && value !== 0 ? `${value * 100}%` : value;\n}\nexport const width = style({\n prop: 'width',\n transform: sizingTransform\n});\nexport const maxWidth = props => {\n if (props.maxWidth !== undefined && props.maxWidth !== null) {\n const styleFromPropValue = propValue => {\n var _props$theme, _props$theme2;\n const breakpoint = ((_props$theme = props.theme) == null || (_props$theme = _props$theme.breakpoints) == null || (_props$theme = _props$theme.values) == null ? void 0 : _props$theme[propValue]) || breakpointsValues[propValue];\n if (!breakpoint) {\n return {\n maxWidth: sizingTransform(propValue)\n };\n }\n if (((_props$theme2 = props.theme) == null || (_props$theme2 = _props$theme2.breakpoints) == null ? void 0 : _props$theme2.unit) !== 'px') {\n return {\n maxWidth: `${breakpoint}${props.theme.breakpoints.unit}`\n };\n }\n return {\n maxWidth: breakpoint\n };\n };\n return handleBreakpoints(props, props.maxWidth, styleFromPropValue);\n }\n return null;\n};\nmaxWidth.filterProps = ['maxWidth'];\nexport const minWidth = style({\n prop: 'minWidth',\n transform: sizingTransform\n});\nexport const height = style({\n prop: 'height',\n transform: sizingTransform\n});\nexport const maxHeight = style({\n prop: 'maxHeight',\n transform: sizingTransform\n});\nexport const minHeight = style({\n prop: 'minHeight',\n transform: sizingTransform\n});\nexport const sizeWidth = style({\n prop: 'size',\n cssProperty: 'width',\n transform: sizingTransform\n});\nexport const sizeHeight = style({\n prop: 'size',\n cssProperty: 'height',\n transform: sizingTransform\n});\nexport const boxSizing = style({\n prop: 'boxSizing'\n});\nconst sizing = compose(width, maxWidth, minWidth, height, maxHeight, minHeight, boxSizing);\nexport default sizing;","import { padding, margin } from '../spacing';\nimport { borderRadius, borderTransform } from '../borders';\nimport { gap, rowGap, columnGap } from '../cssGrid';\nimport { paletteTransform } from '../palette';\nimport { maxWidth, sizingTransform } from '../sizing';\nconst defaultSxConfig = {\n // borders\n border: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderTop: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderRight: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderBottom: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderLeft: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderColor: {\n themeKey: 'palette'\n },\n borderTopColor: {\n themeKey: 'palette'\n },\n borderRightColor: {\n themeKey: 'palette'\n },\n borderBottomColor: {\n themeKey: 'palette'\n },\n borderLeftColor: {\n themeKey: 'palette'\n },\n outline: {\n themeKey: 'borders',\n transform: borderTransform\n },\n outlineColor: {\n themeKey: 'palette'\n },\n borderRadius: {\n themeKey: 'shape.borderRadius',\n style: borderRadius\n },\n // palette\n color: {\n themeKey: 'palette',\n transform: paletteTransform\n },\n bgcolor: {\n themeKey: 'palette',\n cssProperty: 'backgroundColor',\n transform: paletteTransform\n },\n backgroundColor: {\n themeKey: 'palette',\n transform: paletteTransform\n },\n // spacing\n p: {\n style: padding\n },\n pt: {\n style: padding\n },\n pr: {\n style: padding\n },\n pb: {\n style: padding\n },\n pl: {\n style: padding\n },\n px: {\n style: padding\n },\n py: {\n style: padding\n },\n padding: {\n style: padding\n },\n paddingTop: {\n style: padding\n },\n paddingRight: {\n style: padding\n },\n paddingBottom: {\n style: padding\n },\n paddingLeft: {\n style: padding\n },\n paddingX: {\n style: padding\n },\n paddingY: {\n style: padding\n },\n paddingInline: {\n style: padding\n },\n paddingInlineStart: {\n style: padding\n },\n paddingInlineEnd: {\n style: padding\n },\n paddingBlock: {\n style: padding\n },\n paddingBlockStart: {\n style: padding\n },\n paddingBlockEnd: {\n style: padding\n },\n m: {\n style: margin\n },\n mt: {\n style: margin\n },\n mr: {\n style: margin\n },\n mb: {\n style: margin\n },\n ml: {\n style: margin\n },\n mx: {\n style: margin\n },\n my: {\n style: margin\n },\n margin: {\n style: margin\n },\n marginTop: {\n style: margin\n },\n marginRight: {\n style: margin\n },\n marginBottom: {\n style: margin\n },\n marginLeft: {\n style: margin\n },\n marginX: {\n style: margin\n },\n marginY: {\n style: margin\n },\n marginInline: {\n style: margin\n },\n marginInlineStart: {\n style: margin\n },\n marginInlineEnd: {\n style: margin\n },\n marginBlock: {\n style: margin\n },\n marginBlockStart: {\n style: margin\n },\n marginBlockEnd: {\n style: margin\n },\n // display\n displayPrint: {\n cssProperty: false,\n transform: value => ({\n '@media print': {\n display: value\n }\n })\n },\n display: {},\n overflow: {},\n textOverflow: {},\n visibility: {},\n whiteSpace: {},\n // flexbox\n flexBasis: {},\n flexDirection: {},\n flexWrap: {},\n justifyContent: {},\n alignItems: {},\n alignContent: {},\n order: {},\n flex: {},\n flexGrow: {},\n flexShrink: {},\n alignSelf: {},\n justifyItems: {},\n justifySelf: {},\n // grid\n gap: {\n style: gap\n },\n rowGap: {\n style: rowGap\n },\n columnGap: {\n style: columnGap\n },\n gridColumn: {},\n gridRow: {},\n gridAutoFlow: {},\n gridAutoColumns: {},\n gridAutoRows: {},\n gridTemplateColumns: {},\n gridTemplateRows: {},\n gridTemplateAreas: {},\n gridArea: {},\n // positions\n position: {},\n zIndex: {\n themeKey: 'zIndex'\n },\n top: {},\n right: {},\n bottom: {},\n left: {},\n // shadows\n boxShadow: {\n themeKey: 'shadows'\n },\n // sizing\n width: {\n transform: sizingTransform\n },\n maxWidth: {\n style: maxWidth\n },\n minWidth: {\n transform: sizingTransform\n },\n height: {\n transform: sizingTransform\n },\n maxHeight: {\n transform: sizingTransform\n },\n minHeight: {\n transform: sizingTransform\n },\n boxSizing: {},\n // typography\n fontFamily: {\n themeKey: 'typography'\n },\n fontSize: {\n themeKey: 'typography'\n },\n fontStyle: {\n themeKey: 'typography'\n },\n fontWeight: {\n themeKey: 'typography'\n },\n letterSpacing: {},\n textTransform: {},\n lineHeight: {},\n textAlign: {},\n typography: {\n cssProperty: false,\n themeKey: 'typography'\n }\n};\nexport default defaultSxConfig;","import capitalize from '@mui/utils/capitalize';\nimport merge from '../merge';\nimport { getPath, getStyleValue as getValue } from '../style';\nimport { handleBreakpoints, createEmptyBreakpointObject, removeUnusedBreakpoints } from '../breakpoints';\nimport defaultSxConfig from './defaultSxConfig';\nfunction objectsHaveSameKeys(...objects) {\n const allKeys = objects.reduce((keys, object) => keys.concat(Object.keys(object)), []);\n const union = new Set(allKeys);\n return objects.every(object => union.size === Object.keys(object).length);\n}\nfunction callIfFn(maybeFn, arg) {\n return typeof maybeFn === 'function' ? maybeFn(arg) : maybeFn;\n}\n\n// eslint-disable-next-line @typescript-eslint/naming-convention\nexport function unstable_createStyleFunctionSx() {\n function getThemeValue(prop, val, theme, config) {\n const props = {\n [prop]: val,\n theme\n };\n const options = config[prop];\n if (!options) {\n return {\n [prop]: val\n };\n }\n const {\n cssProperty = prop,\n themeKey,\n transform,\n style\n } = options;\n if (val == null) {\n return null;\n }\n\n // TODO v6: remove, see https://github.com/mui/material-ui/pull/38123\n if (themeKey === 'typography' && val === 'inherit') {\n return {\n [prop]: val\n };\n }\n const themeMapping = getPath(theme, themeKey) || {};\n if (style) {\n return style(props);\n }\n const styleFromPropValue = propValueFinal => {\n let value = getValue(themeMapping, transform, propValueFinal);\n if (propValueFinal === value && typeof propValueFinal === 'string') {\n // Haven't found value\n value = getValue(themeMapping, transform, `${prop}${propValueFinal === 'default' ? '' : capitalize(propValueFinal)}`, propValueFinal);\n }\n if (cssProperty === false) {\n return value;\n }\n return {\n [cssProperty]: value\n };\n };\n return handleBreakpoints(props, val, styleFromPropValue);\n }\n function styleFunctionSx(props) {\n var _theme$unstable_sxCon;\n const {\n sx,\n theme = {}\n } = props || {};\n if (!sx) {\n return null; // Emotion & styled-components will neglect null\n }\n const config = (_theme$unstable_sxCon = theme.unstable_sxConfig) != null ? _theme$unstable_sxCon : defaultSxConfig;\n\n /*\n * Receive `sxInput` as object or callback\n * and then recursively check keys & values to create media query object styles.\n * (the result will be used in `styled`)\n */\n function traverse(sxInput) {\n let sxObject = sxInput;\n if (typeof sxInput === 'function') {\n sxObject = sxInput(theme);\n } else if (typeof sxInput !== 'object') {\n // value\n return sxInput;\n }\n if (!sxObject) {\n return null;\n }\n const emptyBreakpoints = createEmptyBreakpointObject(theme.breakpoints);\n const breakpointsKeys = Object.keys(emptyBreakpoints);\n let css = emptyBreakpoints;\n Object.keys(sxObject).forEach(styleKey => {\n const value = callIfFn(sxObject[styleKey], theme);\n if (value !== null && value !== undefined) {\n if (typeof value === 'object') {\n if (config[styleKey]) {\n css = merge(css, getThemeValue(styleKey, value, theme, config));\n } else {\n const breakpointsValues = handleBreakpoints({\n theme\n }, value, x => ({\n [styleKey]: x\n }));\n if (objectsHaveSameKeys(breakpointsValues, value)) {\n css[styleKey] = styleFunctionSx({\n sx: value,\n theme\n });\n } else {\n css = merge(css, breakpointsValues);\n }\n }\n } else {\n css = merge(css, getThemeValue(styleKey, value, theme, config));\n }\n }\n });\n return removeUnusedBreakpoints(breakpointsKeys, css);\n }\n return Array.isArray(sx) ? sx.map(traverse) : traverse(sx);\n }\n return styleFunctionSx;\n}\nconst styleFunctionSx = unstable_createStyleFunctionSx();\nstyleFunctionSx.filterProps = ['sx'];\nexport default styleFunctionSx;","/**\n * A universal utility to style components with multiple color modes. Always use it from the theme object.\n * It works with:\n * - [Basic theme](https://mui.com/material-ui/customization/dark-mode/)\n * - [CSS theme variables](https://mui.com/material-ui/experimental-api/css-theme-variables/overview/)\n * - Zero-runtime engine\n *\n * Tips: Use an array over object spread and place `theme.applyStyles()` last.\n *\n * ✅ [{ background: '#e5e5e5' }, theme.applyStyles('dark', { background: '#1c1c1c' })]\n *\n * 🚫 { background: '#e5e5e5', ...theme.applyStyles('dark', { background: '#1c1c1c' })}\n *\n * @example\n * 1. using with `styled`:\n * ```jsx\n * const Component = styled('div')(({ theme }) => [\n * { background: '#e5e5e5' },\n * theme.applyStyles('dark', {\n * background: '#1c1c1c',\n * color: '#fff',\n * }),\n * ]);\n * ```\n *\n * @example\n * 2. using with `sx` prop:\n * ```jsx\n * [\n * { background: '#e5e5e5' },\n * theme.applyStyles('dark', {\n * background: '#1c1c1c',\n * color: '#fff',\n * }),\n * ]}\n * />\n * ```\n *\n * @example\n * 3. theming a component:\n * ```jsx\n * extendTheme({\n * components: {\n * MuiButton: {\n * styleOverrides: {\n * root: ({ theme }) => [\n * { background: '#e5e5e5' },\n * theme.applyStyles('dark', {\n * background: '#1c1c1c',\n * color: '#fff',\n * }),\n * ],\n * },\n * }\n * }\n * })\n *```\n */\nexport default function applyStyles(key, styles) {\n // @ts-expect-error this is 'any' type\n const theme = this;\n if (theme.vars && typeof theme.getColorSchemeSelector === 'function') {\n // If CssVarsProvider is used as a provider,\n // returns '* :where([data-mui-color-scheme=\"light|dark\"]) &'\n const selector = theme.getColorSchemeSelector(key).replace(/(\\[[^\\]]+\\])/, '*:where($1)');\n return {\n [selector]: styles\n };\n }\n if (theme.palette.mode === key) {\n return styles;\n }\n return {};\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"breakpoints\", \"palette\", \"spacing\", \"shape\"];\nimport deepmerge from '@mui/utils/deepmerge';\nimport createBreakpoints from './createBreakpoints';\nimport shape from './shape';\nimport createSpacing from './createSpacing';\nimport styleFunctionSx from '../styleFunctionSx/styleFunctionSx';\nimport defaultSxConfig from '../styleFunctionSx/defaultSxConfig';\nimport applyStyles from './applyStyles';\nfunction createTheme(options = {}, ...args) {\n const {\n breakpoints: breakpointsInput = {},\n palette: paletteInput = {},\n spacing: spacingInput,\n shape: shapeInput = {}\n } = options,\n other = _objectWithoutPropertiesLoose(options, _excluded);\n const breakpoints = createBreakpoints(breakpointsInput);\n const spacing = createSpacing(spacingInput);\n let muiTheme = deepmerge({\n breakpoints,\n direction: 'ltr',\n components: {},\n // Inject component definitions.\n palette: _extends({\n mode: 'light'\n }, paletteInput),\n spacing,\n shape: _extends({}, shape, shapeInput)\n }, other);\n muiTheme.applyStyles = applyStyles;\n muiTheme = args.reduce((acc, argument) => deepmerge(acc, argument), muiTheme);\n muiTheme.unstable_sxConfig = _extends({}, defaultSxConfig, other == null ? void 0 : other.unstable_sxConfig);\n muiTheme.unstable_sx = function sx(props) {\n return styleFunctionSx({\n sx: props,\n theme: this\n });\n };\n return muiTheme;\n}\nexport default createTheme;","'use client';\n\nimport * as React from 'react';\nimport { ThemeContext } from '@mui/styled-engine';\nfunction isObjectEmpty(obj) {\n return Object.keys(obj).length === 0;\n}\nfunction useTheme(defaultTheme = null) {\n const contextTheme = React.useContext(ThemeContext);\n return !contextTheme || isObjectEmpty(contextTheme) ? defaultTheme : contextTheme;\n}\nexport default useTheme;","'use client';\n\nimport createTheme from './createTheme';\nimport useThemeWithoutDefault from './useThemeWithoutDefault';\nexport const systemDefaultTheme = createTheme();\nfunction useTheme(defaultTheme = systemDefaultTheme) {\n return useThemeWithoutDefault(defaultTheme);\n}\nexport default useTheme;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"ownerState\"],\n _excluded2 = [\"variants\"],\n _excluded3 = [\"name\", \"slot\", \"skipVariantsResolver\", \"skipSx\", \"overridesResolver\"];\n/* eslint-disable no-underscore-dangle */\nimport styledEngineStyled, { internal_processStyles as processStyles } from '@mui/styled-engine';\nimport { isPlainObject } from '@mui/utils/deepmerge';\nimport capitalize from '@mui/utils/capitalize';\nimport getDisplayName from '@mui/utils/getDisplayName';\nimport createTheme from './createTheme';\nimport styleFunctionSx from './styleFunctionSx';\nfunction isEmpty(obj) {\n return Object.keys(obj).length === 0;\n}\n\n// https://github.com/emotion-js/emotion/blob/26ded6109fcd8ca9875cc2ce4564fee678a3f3c5/packages/styled/src/utils.js#L40\nfunction isStringTag(tag) {\n return typeof tag === 'string' &&\n // 96 is one less than the char code\n // for \"a\" so this is checking that\n // it's a lowercase character\n tag.charCodeAt(0) > 96;\n}\n\n// Update /system/styled/#api in case if this changes\nexport function shouldForwardProp(prop) {\n return prop !== 'ownerState' && prop !== 'theme' && prop !== 'sx' && prop !== 'as';\n}\nexport const systemDefaultTheme = createTheme();\nconst lowercaseFirstLetter = string => {\n if (!string) {\n return string;\n }\n return string.charAt(0).toLowerCase() + string.slice(1);\n};\nfunction resolveTheme({\n defaultTheme,\n theme,\n themeId\n}) {\n return isEmpty(theme) ? defaultTheme : theme[themeId] || theme;\n}\nfunction defaultOverridesResolver(slot) {\n if (!slot) {\n return null;\n }\n return (props, styles) => styles[slot];\n}\nfunction processStyleArg(callableStyle, _ref) {\n let {\n ownerState\n } = _ref,\n props = _objectWithoutPropertiesLoose(_ref, _excluded);\n const resolvedStylesArg = typeof callableStyle === 'function' ? callableStyle(_extends({\n ownerState\n }, props)) : callableStyle;\n if (Array.isArray(resolvedStylesArg)) {\n return resolvedStylesArg.flatMap(resolvedStyle => processStyleArg(resolvedStyle, _extends({\n ownerState\n }, props)));\n }\n if (!!resolvedStylesArg && typeof resolvedStylesArg === 'object' && Array.isArray(resolvedStylesArg.variants)) {\n const {\n variants = []\n } = resolvedStylesArg,\n otherStyles = _objectWithoutPropertiesLoose(resolvedStylesArg, _excluded2);\n let result = otherStyles;\n variants.forEach(variant => {\n let isMatch = true;\n if (typeof variant.props === 'function') {\n isMatch = variant.props(_extends({\n ownerState\n }, props, ownerState));\n } else {\n Object.keys(variant.props).forEach(key => {\n if ((ownerState == null ? void 0 : ownerState[key]) !== variant.props[key] && props[key] !== variant.props[key]) {\n isMatch = false;\n }\n });\n }\n if (isMatch) {\n if (!Array.isArray(result)) {\n result = [result];\n }\n result.push(typeof variant.style === 'function' ? variant.style(_extends({\n ownerState\n }, props, ownerState)) : variant.style);\n }\n });\n return result;\n }\n return resolvedStylesArg;\n}\nexport default function createStyled(input = {}) {\n const {\n themeId,\n defaultTheme = systemDefaultTheme,\n rootShouldForwardProp = shouldForwardProp,\n slotShouldForwardProp = shouldForwardProp\n } = input;\n const systemSx = props => {\n return styleFunctionSx(_extends({}, props, {\n theme: resolveTheme(_extends({}, props, {\n defaultTheme,\n themeId\n }))\n }));\n };\n systemSx.__mui_systemSx = true;\n return (tag, inputOptions = {}) => {\n // Filter out the `sx` style function from the previous styled component to prevent unnecessary styles generated by the composite components.\n processStyles(tag, styles => styles.filter(style => !(style != null && style.__mui_systemSx)));\n const {\n name: componentName,\n slot: componentSlot,\n skipVariantsResolver: inputSkipVariantsResolver,\n skipSx: inputSkipSx,\n // TODO v6: remove `lowercaseFirstLetter()` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n overridesResolver = defaultOverridesResolver(lowercaseFirstLetter(componentSlot))\n } = inputOptions,\n options = _objectWithoutPropertiesLoose(inputOptions, _excluded3);\n\n // if skipVariantsResolver option is defined, take the value, otherwise, true for root and false for other slots.\n const skipVariantsResolver = inputSkipVariantsResolver !== undefined ? inputSkipVariantsResolver :\n // TODO v6: remove `Root` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n componentSlot && componentSlot !== 'Root' && componentSlot !== 'root' || false;\n const skipSx = inputSkipSx || false;\n let label;\n if (process.env.NODE_ENV !== 'production') {\n if (componentName) {\n // TODO v6: remove `lowercaseFirstLetter()` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n label = `${componentName}-${lowercaseFirstLetter(componentSlot || 'Root')}`;\n }\n }\n let shouldForwardPropOption = shouldForwardProp;\n\n // TODO v6: remove `Root` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n if (componentSlot === 'Root' || componentSlot === 'root') {\n shouldForwardPropOption = rootShouldForwardProp;\n } else if (componentSlot) {\n // any other slot specified\n shouldForwardPropOption = slotShouldForwardProp;\n } else if (isStringTag(tag)) {\n // for string (html) tag, preserve the behavior in emotion & styled-components.\n shouldForwardPropOption = undefined;\n }\n const defaultStyledResolver = styledEngineStyled(tag, _extends({\n shouldForwardProp: shouldForwardPropOption,\n label\n }, options));\n const transformStyleArg = stylesArg => {\n // On the server Emotion doesn't use React.forwardRef for creating components, so the created\n // component stays as a function. This condition makes sure that we do not interpolate functions\n // which are basically components used as a selectors.\n if (typeof stylesArg === 'function' && stylesArg.__emotion_real !== stylesArg || isPlainObject(stylesArg)) {\n return props => processStyleArg(stylesArg, _extends({}, props, {\n theme: resolveTheme({\n theme: props.theme,\n defaultTheme,\n themeId\n })\n }));\n }\n return stylesArg;\n };\n const muiStyledResolver = (styleArg, ...expressions) => {\n let transformedStyleArg = transformStyleArg(styleArg);\n const expressionsWithDefaultTheme = expressions ? expressions.map(transformStyleArg) : [];\n if (componentName && overridesResolver) {\n expressionsWithDefaultTheme.push(props => {\n const theme = resolveTheme(_extends({}, props, {\n defaultTheme,\n themeId\n }));\n if (!theme.components || !theme.components[componentName] || !theme.components[componentName].styleOverrides) {\n return null;\n }\n const styleOverrides = theme.components[componentName].styleOverrides;\n const resolvedStyleOverrides = {};\n // TODO: v7 remove iteration and use `resolveStyleArg(styleOverrides[slot])` directly\n Object.entries(styleOverrides).forEach(([slotKey, slotStyle]) => {\n resolvedStyleOverrides[slotKey] = processStyleArg(slotStyle, _extends({}, props, {\n theme\n }));\n });\n return overridesResolver(props, resolvedStyleOverrides);\n });\n }\n if (componentName && !skipVariantsResolver) {\n expressionsWithDefaultTheme.push(props => {\n var _theme$components;\n const theme = resolveTheme(_extends({}, props, {\n defaultTheme,\n themeId\n }));\n const themeVariants = theme == null || (_theme$components = theme.components) == null || (_theme$components = _theme$components[componentName]) == null ? void 0 : _theme$components.variants;\n return processStyleArg({\n variants: themeVariants\n }, _extends({}, props, {\n theme\n }));\n });\n }\n if (!skipSx) {\n expressionsWithDefaultTheme.push(systemSx);\n }\n const numOfCustomFnsApplied = expressionsWithDefaultTheme.length - expressions.length;\n if (Array.isArray(styleArg) && numOfCustomFnsApplied > 0) {\n const placeholders = new Array(numOfCustomFnsApplied).fill('');\n // If the type is array, than we need to add placeholders in the template for the overrides, variants and the sx styles.\n transformedStyleArg = [...styleArg, ...placeholders];\n transformedStyleArg.raw = [...styleArg.raw, ...placeholders];\n }\n const Component = defaultStyledResolver(transformedStyleArg, ...expressionsWithDefaultTheme);\n if (process.env.NODE_ENV !== 'production') {\n let displayName;\n if (componentName) {\n displayName = `${componentName}${capitalize(componentSlot || '')}`;\n }\n if (displayName === undefined) {\n displayName = `Styled(${getDisplayName(tag)})`;\n }\n Component.displayName = displayName;\n }\n if (tag.muiName) {\n Component.muiName = tag.muiName;\n }\n return Component;\n };\n if (defaultStyledResolver.withConfig) {\n muiStyledResolver.withConfig = defaultStyledResolver.withConfig;\n }\n return muiStyledResolver;\n };\n}","import resolveProps from '@mui/utils/resolveProps';\nexport default function getThemeProps(params) {\n const {\n theme,\n name,\n props\n } = params;\n if (!theme || !theme.components || !theme.components[name] || !theme.components[name].defaultProps) {\n return props;\n }\n return resolveProps(theme.components[name].defaultProps, props);\n}","'use client';\n\nimport getThemeProps from './getThemeProps';\nimport useTheme from '../useTheme';\nexport default function useThemeProps({\n props,\n name,\n defaultTheme,\n themeId\n}) {\n let theme = useTheme(defaultTheme);\n if (themeId) {\n theme = theme[themeId] || theme;\n }\n const mergedProps = getThemeProps({\n theme,\n name,\n props\n });\n return mergedProps;\n}","import _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\n/* eslint-disable @typescript-eslint/naming-convention */\nimport clamp from '@mui/utils/clamp';\n/**\n * Returns a number whose value is limited to the given range.\n * @param {number} value The value to be clamped\n * @param {number} min The lower boundary of the output range\n * @param {number} max The upper boundary of the output range\n * @returns {number} A number in the range [min, max]\n */\nfunction clampWrapper(value, min = 0, max = 1) {\n if (process.env.NODE_ENV !== 'production') {\n if (value < min || value > max) {\n console.error(`MUI: The value provided ${value} is out of range [${min}, ${max}].`);\n }\n }\n return clamp(value, min, max);\n}\n\n/**\n * Converts a color from CSS hex format to CSS rgb format.\n * @param {string} color - Hex color, i.e. #nnn or #nnnnnn\n * @returns {string} A CSS rgb color string\n */\nexport function hexToRgb(color) {\n color = color.slice(1);\n const re = new RegExp(`.{1,${color.length >= 6 ? 2 : 1}}`, 'g');\n let colors = color.match(re);\n if (colors && colors[0].length === 1) {\n colors = colors.map(n => n + n);\n }\n return colors ? `rgb${colors.length === 4 ? 'a' : ''}(${colors.map((n, index) => {\n return index < 3 ? parseInt(n, 16) : Math.round(parseInt(n, 16) / 255 * 1000) / 1000;\n }).join(', ')})` : '';\n}\nfunction intToHex(int) {\n const hex = int.toString(16);\n return hex.length === 1 ? `0${hex}` : hex;\n}\n\n/**\n * Returns an object with the type and values of a color.\n *\n * Note: Does not support rgb % values.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @returns {object} - A MUI color object: {type: string, values: number[]}\n */\nexport function decomposeColor(color) {\n // Idempotent\n if (color.type) {\n return color;\n }\n if (color.charAt(0) === '#') {\n return decomposeColor(hexToRgb(color));\n }\n const marker = color.indexOf('(');\n const type = color.substring(0, marker);\n if (['rgb', 'rgba', 'hsl', 'hsla', 'color'].indexOf(type) === -1) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: Unsupported \\`${color}\\` color.\nThe following formats are supported: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color().` : _formatMuiErrorMessage(9, color));\n }\n let values = color.substring(marker + 1, color.length - 1);\n let colorSpace;\n if (type === 'color') {\n values = values.split(' ');\n colorSpace = values.shift();\n if (values.length === 4 && values[3].charAt(0) === '/') {\n values[3] = values[3].slice(1);\n }\n if (['srgb', 'display-p3', 'a98-rgb', 'prophoto-rgb', 'rec-2020'].indexOf(colorSpace) === -1) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: unsupported \\`${colorSpace}\\` color space.\nThe following color spaces are supported: srgb, display-p3, a98-rgb, prophoto-rgb, rec-2020.` : _formatMuiErrorMessage(10, colorSpace));\n }\n } else {\n values = values.split(',');\n }\n values = values.map(value => parseFloat(value));\n return {\n type,\n values,\n colorSpace\n };\n}\n\n/**\n * Returns a channel created from the input color.\n *\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @returns {string} - The channel for the color, that can be used in rgba or hsla colors\n */\nexport const colorChannel = color => {\n const decomposedColor = decomposeColor(color);\n return decomposedColor.values.slice(0, 3).map((val, idx) => decomposedColor.type.indexOf('hsl') !== -1 && idx !== 0 ? `${val}%` : val).join(' ');\n};\nexport const private_safeColorChannel = (color, warning) => {\n try {\n return colorChannel(color);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n};\n\n/**\n * Converts a color object with type and values to a string.\n * @param {object} color - Decomposed color\n * @param {string} color.type - One of: 'rgb', 'rgba', 'hsl', 'hsla', 'color'\n * @param {array} color.values - [n,n,n] or [n,n,n,n]\n * @returns {string} A CSS color string\n */\nexport function recomposeColor(color) {\n const {\n type,\n colorSpace\n } = color;\n let {\n values\n } = color;\n if (type.indexOf('rgb') !== -1) {\n // Only convert the first 3 values to int (i.e. not alpha)\n values = values.map((n, i) => i < 3 ? parseInt(n, 10) : n);\n } else if (type.indexOf('hsl') !== -1) {\n values[1] = `${values[1]}%`;\n values[2] = `${values[2]}%`;\n }\n if (type.indexOf('color') !== -1) {\n values = `${colorSpace} ${values.join(' ')}`;\n } else {\n values = `${values.join(', ')}`;\n }\n return `${type}(${values})`;\n}\n\n/**\n * Converts a color from CSS rgb format to CSS hex format.\n * @param {string} color - RGB color, i.e. rgb(n, n, n)\n * @returns {string} A CSS rgb color string, i.e. #nnnnnn\n */\nexport function rgbToHex(color) {\n // Idempotent\n if (color.indexOf('#') === 0) {\n return color;\n }\n const {\n values\n } = decomposeColor(color);\n return `#${values.map((n, i) => intToHex(i === 3 ? Math.round(255 * n) : n)).join('')}`;\n}\n\n/**\n * Converts a color from hsl format to rgb format.\n * @param {string} color - HSL color values\n * @returns {string} rgb color values\n */\nexport function hslToRgb(color) {\n color = decomposeColor(color);\n const {\n values\n } = color;\n const h = values[0];\n const s = values[1] / 100;\n const l = values[2] / 100;\n const a = s * Math.min(l, 1 - l);\n const f = (n, k = (n + h / 30) % 12) => l - a * Math.max(Math.min(k - 3, 9 - k, 1), -1);\n let type = 'rgb';\n const rgb = [Math.round(f(0) * 255), Math.round(f(8) * 255), Math.round(f(4) * 255)];\n if (color.type === 'hsla') {\n type += 'a';\n rgb.push(values[3]);\n }\n return recomposeColor({\n type,\n values: rgb\n });\n}\n/**\n * The relative brightness of any point in a color space,\n * normalized to 0 for darkest black and 1 for lightest white.\n *\n * Formula: https://www.w3.org/TR/WCAG20-TECHS/G17.html#G17-tests\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @returns {number} The relative brightness of the color in the range 0 - 1\n */\nexport function getLuminance(color) {\n color = decomposeColor(color);\n let rgb = color.type === 'hsl' || color.type === 'hsla' ? decomposeColor(hslToRgb(color)).values : color.values;\n rgb = rgb.map(val => {\n if (color.type !== 'color') {\n val /= 255; // normalized\n }\n return val <= 0.03928 ? val / 12.92 : ((val + 0.055) / 1.055) ** 2.4;\n });\n\n // Truncate at 3 digits\n return Number((0.2126 * rgb[0] + 0.7152 * rgb[1] + 0.0722 * rgb[2]).toFixed(3));\n}\n\n/**\n * Calculates the contrast ratio between two colors.\n *\n * Formula: https://www.w3.org/TR/WCAG20-TECHS/G17.html#G17-tests\n * @param {string} foreground - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla()\n * @param {string} background - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla()\n * @returns {number} A contrast ratio value in the range 0 - 21.\n */\nexport function getContrastRatio(foreground, background) {\n const lumA = getLuminance(foreground);\n const lumB = getLuminance(background);\n return (Math.max(lumA, lumB) + 0.05) / (Math.min(lumA, lumB) + 0.05);\n}\n\n/**\n * Sets the absolute transparency of a color.\n * Any existing alpha values are overwritten.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} value - value to set the alpha channel to in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function alpha(color, value) {\n color = decomposeColor(color);\n value = clampWrapper(value);\n if (color.type === 'rgb' || color.type === 'hsl') {\n color.type += 'a';\n }\n if (color.type === 'color') {\n color.values[3] = `/${value}`;\n } else {\n color.values[3] = value;\n }\n return recomposeColor(color);\n}\nexport function private_safeAlpha(color, value, warning) {\n try {\n return alpha(color, value);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Darkens a color.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} coefficient - multiplier in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function darken(color, coefficient) {\n color = decomposeColor(color);\n coefficient = clampWrapper(coefficient);\n if (color.type.indexOf('hsl') !== -1) {\n color.values[2] *= 1 - coefficient;\n } else if (color.type.indexOf('rgb') !== -1 || color.type.indexOf('color') !== -1) {\n for (let i = 0; i < 3; i += 1) {\n color.values[i] *= 1 - coefficient;\n }\n }\n return recomposeColor(color);\n}\nexport function private_safeDarken(color, coefficient, warning) {\n try {\n return darken(color, coefficient);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Lightens a color.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} coefficient - multiplier in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function lighten(color, coefficient) {\n color = decomposeColor(color);\n coefficient = clampWrapper(coefficient);\n if (color.type.indexOf('hsl') !== -1) {\n color.values[2] += (100 - color.values[2]) * coefficient;\n } else if (color.type.indexOf('rgb') !== -1) {\n for (let i = 0; i < 3; i += 1) {\n color.values[i] += (255 - color.values[i]) * coefficient;\n }\n } else if (color.type.indexOf('color') !== -1) {\n for (let i = 0; i < 3; i += 1) {\n color.values[i] += (1 - color.values[i]) * coefficient;\n }\n }\n return recomposeColor(color);\n}\nexport function private_safeLighten(color, coefficient, warning) {\n try {\n return lighten(color, coefficient);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Darken or lighten a color, depending on its luminance.\n * Light colors are darkened, dark colors are lightened.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} coefficient=0.15 - multiplier in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function emphasize(color, coefficient = 0.15) {\n return getLuminance(color) > 0.5 ? darken(color, coefficient) : lighten(color, coefficient);\n}\nexport function private_safeEmphasize(color, coefficient, warning) {\n try {\n return emphasize(color, coefficient);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Blend a transparent overlay color with a background color, resulting in a single\n * RGB color.\n * @param {string} background - CSS color\n * @param {string} overlay - CSS color\n * @param {number} opacity - Opacity multiplier in the range 0 - 1\n * @param {number} [gamma=1.0] - Gamma correction factor. For gamma-correct blending, 2.2 is usual.\n */\nexport function blend(background, overlay, opacity, gamma = 1.0) {\n const blendChannel = (b, o) => Math.round((b ** (1 / gamma) * (1 - opacity) + o ** (1 / gamma) * opacity) ** gamma);\n const backgroundColor = decomposeColor(background);\n const overlayColor = decomposeColor(overlay);\n const rgb = [blendChannel(backgroundColor.values[0], overlayColor.values[0]), blendChannel(backgroundColor.values[1], overlayColor.values[1]), blendChannel(backgroundColor.values[2], overlayColor.values[2])];\n return recomposeColor({\n type: 'rgb',\n values: rgb\n });\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nexport default function createMixins(breakpoints, mixins) {\n return _extends({\n toolbar: {\n minHeight: 56,\n [breakpoints.up('xs')]: {\n '@media (orientation: landscape)': {\n minHeight: 48\n }\n },\n [breakpoints.up('sm')]: {\n minHeight: 64\n }\n }\n }, mixins);\n}","const common = {\n black: '#000',\n white: '#fff'\n};\nexport default common;","const grey = {\n 50: '#fafafa',\n 100: '#f5f5f5',\n 200: '#eeeeee',\n 300: '#e0e0e0',\n 400: '#bdbdbd',\n 500: '#9e9e9e',\n 600: '#757575',\n 700: '#616161',\n 800: '#424242',\n 900: '#212121',\n A100: '#f5f5f5',\n A200: '#eeeeee',\n A400: '#bdbdbd',\n A700: '#616161'\n};\nexport default grey;","const purple = {\n 50: '#f3e5f5',\n 100: '#e1bee7',\n 200: '#ce93d8',\n 300: '#ba68c8',\n 400: '#ab47bc',\n 500: '#9c27b0',\n 600: '#8e24aa',\n 700: '#7b1fa2',\n 800: '#6a1b9a',\n 900: '#4a148c',\n A100: '#ea80fc',\n A200: '#e040fb',\n A400: '#d500f9',\n A700: '#aa00ff'\n};\nexport default purple;","const red = {\n 50: '#ffebee',\n 100: '#ffcdd2',\n 200: '#ef9a9a',\n 300: '#e57373',\n 400: '#ef5350',\n 500: '#f44336',\n 600: '#e53935',\n 700: '#d32f2f',\n 800: '#c62828',\n 900: '#b71c1c',\n A100: '#ff8a80',\n A200: '#ff5252',\n A400: '#ff1744',\n A700: '#d50000'\n};\nexport default red;","const orange = {\n 50: '#fff3e0',\n 100: '#ffe0b2',\n 200: '#ffcc80',\n 300: '#ffb74d',\n 400: '#ffa726',\n 500: '#ff9800',\n 600: '#fb8c00',\n 700: '#f57c00',\n 800: '#ef6c00',\n 900: '#e65100',\n A100: '#ffd180',\n A200: '#ffab40',\n A400: '#ff9100',\n A700: '#ff6d00'\n};\nexport default orange;","const blue = {\n 50: '#e3f2fd',\n 100: '#bbdefb',\n 200: '#90caf9',\n 300: '#64b5f6',\n 400: '#42a5f5',\n 500: '#2196f3',\n 600: '#1e88e5',\n 700: '#1976d2',\n 800: '#1565c0',\n 900: '#0d47a1',\n A100: '#82b1ff',\n A200: '#448aff',\n A400: '#2979ff',\n A700: '#2962ff'\n};\nexport default blue;","const lightBlue = {\n 50: '#e1f5fe',\n 100: '#b3e5fc',\n 200: '#81d4fa',\n 300: '#4fc3f7',\n 400: '#29b6f6',\n 500: '#03a9f4',\n 600: '#039be5',\n 700: '#0288d1',\n 800: '#0277bd',\n 900: '#01579b',\n A100: '#80d8ff',\n A200: '#40c4ff',\n A400: '#00b0ff',\n A700: '#0091ea'\n};\nexport default lightBlue;","const green = {\n 50: '#e8f5e9',\n 100: '#c8e6c9',\n 200: '#a5d6a7',\n 300: '#81c784',\n 400: '#66bb6a',\n 500: '#4caf50',\n 600: '#43a047',\n 700: '#388e3c',\n 800: '#2e7d32',\n 900: '#1b5e20',\n A100: '#b9f6ca',\n A200: '#69f0ae',\n A400: '#00e676',\n A700: '#00c853'\n};\nexport default green;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\nconst _excluded = [\"mode\", \"contrastThreshold\", \"tonalOffset\"];\nimport { deepmerge } from '@mui/utils';\nimport { darken, getContrastRatio, lighten } from '@mui/system';\nimport common from '../colors/common';\nimport grey from '../colors/grey';\nimport purple from '../colors/purple';\nimport red from '../colors/red';\nimport orange from '../colors/orange';\nimport blue from '../colors/blue';\nimport lightBlue from '../colors/lightBlue';\nimport green from '../colors/green';\nexport const light = {\n // The colors used to style the text.\n text: {\n // The most important text.\n primary: 'rgba(0, 0, 0, 0.87)',\n // Secondary text.\n secondary: 'rgba(0, 0, 0, 0.6)',\n // Disabled text have even lower visual prominence.\n disabled: 'rgba(0, 0, 0, 0.38)'\n },\n // The color used to divide different elements.\n divider: 'rgba(0, 0, 0, 0.12)',\n // The background colors used to style the surfaces.\n // Consistency between these values is important.\n background: {\n paper: common.white,\n default: common.white\n },\n // The colors used to style the action elements.\n action: {\n // The color of an active action like an icon button.\n active: 'rgba(0, 0, 0, 0.54)',\n // The color of an hovered action.\n hover: 'rgba(0, 0, 0, 0.04)',\n hoverOpacity: 0.04,\n // The color of a selected action.\n selected: 'rgba(0, 0, 0, 0.08)',\n selectedOpacity: 0.08,\n // The color of a disabled action.\n disabled: 'rgba(0, 0, 0, 0.26)',\n // The background color of a disabled action.\n disabledBackground: 'rgba(0, 0, 0, 0.12)',\n disabledOpacity: 0.38,\n focus: 'rgba(0, 0, 0, 0.12)',\n focusOpacity: 0.12,\n activatedOpacity: 0.12\n }\n};\nexport const dark = {\n text: {\n primary: common.white,\n secondary: 'rgba(255, 255, 255, 0.7)',\n disabled: 'rgba(255, 255, 255, 0.5)',\n icon: 'rgba(255, 255, 255, 0.5)'\n },\n divider: 'rgba(255, 255, 255, 0.12)',\n background: {\n paper: '#121212',\n default: '#121212'\n },\n action: {\n active: common.white,\n hover: 'rgba(255, 255, 255, 0.08)',\n hoverOpacity: 0.08,\n selected: 'rgba(255, 255, 255, 0.16)',\n selectedOpacity: 0.16,\n disabled: 'rgba(255, 255, 255, 0.3)',\n disabledBackground: 'rgba(255, 255, 255, 0.12)',\n disabledOpacity: 0.38,\n focus: 'rgba(255, 255, 255, 0.12)',\n focusOpacity: 0.12,\n activatedOpacity: 0.24\n }\n};\nfunction addLightOrDark(intent, direction, shade, tonalOffset) {\n const tonalOffsetLight = tonalOffset.light || tonalOffset;\n const tonalOffsetDark = tonalOffset.dark || tonalOffset * 1.5;\n if (!intent[direction]) {\n if (intent.hasOwnProperty(shade)) {\n intent[direction] = intent[shade];\n } else if (direction === 'light') {\n intent.light = lighten(intent.main, tonalOffsetLight);\n } else if (direction === 'dark') {\n intent.dark = darken(intent.main, tonalOffsetDark);\n }\n }\n}\nfunction getDefaultPrimary(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: blue[200],\n light: blue[50],\n dark: blue[400]\n };\n }\n return {\n main: blue[700],\n light: blue[400],\n dark: blue[800]\n };\n}\nfunction getDefaultSecondary(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: purple[200],\n light: purple[50],\n dark: purple[400]\n };\n }\n return {\n main: purple[500],\n light: purple[300],\n dark: purple[700]\n };\n}\nfunction getDefaultError(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: red[500],\n light: red[300],\n dark: red[700]\n };\n }\n return {\n main: red[700],\n light: red[400],\n dark: red[800]\n };\n}\nfunction getDefaultInfo(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: lightBlue[400],\n light: lightBlue[300],\n dark: lightBlue[700]\n };\n }\n return {\n main: lightBlue[700],\n light: lightBlue[500],\n dark: lightBlue[900]\n };\n}\nfunction getDefaultSuccess(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: green[400],\n light: green[300],\n dark: green[700]\n };\n }\n return {\n main: green[800],\n light: green[500],\n dark: green[900]\n };\n}\nfunction getDefaultWarning(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: orange[400],\n light: orange[300],\n dark: orange[700]\n };\n }\n return {\n main: '#ed6c02',\n // closest to orange[800] that pass 3:1.\n light: orange[500],\n dark: orange[900]\n };\n}\nexport default function createPalette(palette) {\n const {\n mode = 'light',\n contrastThreshold = 3,\n tonalOffset = 0.2\n } = palette,\n other = _objectWithoutPropertiesLoose(palette, _excluded);\n const primary = palette.primary || getDefaultPrimary(mode);\n const secondary = palette.secondary || getDefaultSecondary(mode);\n const error = palette.error || getDefaultError(mode);\n const info = palette.info || getDefaultInfo(mode);\n const success = palette.success || getDefaultSuccess(mode);\n const warning = palette.warning || getDefaultWarning(mode);\n\n // Use the same logic as\n // Bootstrap: https://github.com/twbs/bootstrap/blob/1d6e3710dd447de1a200f29e8fa521f8a0908f70/scss/_functions.scss#L59\n // and material-components-web https://github.com/material-components/material-components-web/blob/ac46b8863c4dab9fc22c4c662dc6bd1b65dd652f/packages/mdc-theme/_functions.scss#L54\n function getContrastText(background) {\n const contrastText = getContrastRatio(background, dark.text.primary) >= contrastThreshold ? dark.text.primary : light.text.primary;\n if (process.env.NODE_ENV !== 'production') {\n const contrast = getContrastRatio(background, contrastText);\n if (contrast < 3) {\n console.error([`MUI: The contrast ratio of ${contrast}:1 for ${contrastText} on ${background}`, 'falls below the WCAG recommended absolute minimum contrast ratio of 3:1.', 'https://www.w3.org/TR/2008/REC-WCAG20-20081211/#visual-audio-contrast-contrast'].join('\\n'));\n }\n }\n return contrastText;\n }\n const augmentColor = ({\n color,\n name,\n mainShade = 500,\n lightShade = 300,\n darkShade = 700\n }) => {\n color = _extends({}, color);\n if (!color.main && color[mainShade]) {\n color.main = color[mainShade];\n }\n if (!color.hasOwnProperty('main')) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: The color${name ? ` (${name})` : ''} provided to augmentColor(color) is invalid.\nThe color object needs to have a \\`main\\` property or a \\`${mainShade}\\` property.` : _formatMuiErrorMessage(11, name ? ` (${name})` : '', mainShade));\n }\n if (typeof color.main !== 'string') {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: The color${name ? ` (${name})` : ''} provided to augmentColor(color) is invalid.\n\\`color.main\\` should be a string, but \\`${JSON.stringify(color.main)}\\` was provided instead.\n\nDid you intend to use one of the following approaches?\n\nimport { green } from \"@mui/material/colors\";\n\nconst theme1 = createTheme({ palette: {\n primary: green,\n} });\n\nconst theme2 = createTheme({ palette: {\n primary: { main: green[500] },\n} });` : _formatMuiErrorMessage(12, name ? ` (${name})` : '', JSON.stringify(color.main)));\n }\n addLightOrDark(color, 'light', lightShade, tonalOffset);\n addLightOrDark(color, 'dark', darkShade, tonalOffset);\n if (!color.contrastText) {\n color.contrastText = getContrastText(color.main);\n }\n return color;\n };\n const modes = {\n dark,\n light\n };\n if (process.env.NODE_ENV !== 'production') {\n if (!modes[mode]) {\n console.error(`MUI: The palette mode \\`${mode}\\` is not supported.`);\n }\n }\n const paletteOutput = deepmerge(_extends({\n // A collection of common colors.\n common: _extends({}, common),\n // prevent mutable object.\n // The palette mode, can be light or dark.\n mode,\n // The colors used to represent primary interface elements for a user.\n primary: augmentColor({\n color: primary,\n name: 'primary'\n }),\n // The colors used to represent secondary interface elements for a user.\n secondary: augmentColor({\n color: secondary,\n name: 'secondary',\n mainShade: 'A400',\n lightShade: 'A200',\n darkShade: 'A700'\n }),\n // The colors used to represent interface elements that the user should be made aware of.\n error: augmentColor({\n color: error,\n name: 'error'\n }),\n // The colors used to represent potentially dangerous actions or important messages.\n warning: augmentColor({\n color: warning,\n name: 'warning'\n }),\n // The colors used to present information to the user that is neutral and not necessarily important.\n info: augmentColor({\n color: info,\n name: 'info'\n }),\n // The colors used to indicate the successful completion of an action that user triggered.\n success: augmentColor({\n color: success,\n name: 'success'\n }),\n // The grey colors.\n grey,\n // Used by `getContrastText()` to maximize the contrast between\n // the background and the text.\n contrastThreshold,\n // Takes a background color and returns the text color that maximizes the contrast.\n getContrastText,\n // Generate a rich color object.\n augmentColor,\n // Used by the functions below to shift a color's luminance by approximately\n // two indexes within its tonal palette.\n // E.g., shift from Red 500 to Red 300 or Red 700.\n tonalOffset\n }, modes[mode]), other);\n return paletteOutput;\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"fontFamily\", \"fontSize\", \"fontWeightLight\", \"fontWeightRegular\", \"fontWeightMedium\", \"fontWeightBold\", \"htmlFontSize\", \"allVariants\", \"pxToRem\"];\nimport { deepmerge } from '@mui/utils';\nfunction round(value) {\n return Math.round(value * 1e5) / 1e5;\n}\nconst caseAllCaps = {\n textTransform: 'uppercase'\n};\nconst defaultFontFamily = '\"Roboto\", \"Helvetica\", \"Arial\", sans-serif';\n\n/**\n * @see @link{https://m2.material.io/design/typography/the-type-system.html}\n * @see @link{https://m2.material.io/design/typography/understanding-typography.html}\n */\nexport default function createTypography(palette, typography) {\n const _ref = typeof typography === 'function' ? typography(palette) : typography,\n {\n fontFamily = defaultFontFamily,\n // The default font size of the Material Specification.\n fontSize = 14,\n // px\n fontWeightLight = 300,\n fontWeightRegular = 400,\n fontWeightMedium = 500,\n fontWeightBold = 700,\n // Tell MUI what's the font-size on the html element.\n // 16px is the default font-size used by browsers.\n htmlFontSize = 16,\n // Apply the CSS properties to all the variants.\n allVariants,\n pxToRem: pxToRem2\n } = _ref,\n other = _objectWithoutPropertiesLoose(_ref, _excluded);\n if (process.env.NODE_ENV !== 'production') {\n if (typeof fontSize !== 'number') {\n console.error('MUI: `fontSize` is required to be a number.');\n }\n if (typeof htmlFontSize !== 'number') {\n console.error('MUI: `htmlFontSize` is required to be a number.');\n }\n }\n const coef = fontSize / 14;\n const pxToRem = pxToRem2 || (size => `${size / htmlFontSize * coef}rem`);\n const buildVariant = (fontWeight, size, lineHeight, letterSpacing, casing) => _extends({\n fontFamily,\n fontWeight,\n fontSize: pxToRem(size),\n // Unitless following https://meyerweb.com/eric/thoughts/2006/02/08/unitless-line-heights/\n lineHeight\n }, fontFamily === defaultFontFamily ? {\n letterSpacing: `${round(letterSpacing / size)}em`\n } : {}, casing, allVariants);\n const variants = {\n h1: buildVariant(fontWeightLight, 96, 1.167, -1.5),\n h2: buildVariant(fontWeightLight, 60, 1.2, -0.5),\n h3: buildVariant(fontWeightRegular, 48, 1.167, 0),\n h4: buildVariant(fontWeightRegular, 34, 1.235, 0.25),\n h5: buildVariant(fontWeightRegular, 24, 1.334, 0),\n h6: buildVariant(fontWeightMedium, 20, 1.6, 0.15),\n subtitle1: buildVariant(fontWeightRegular, 16, 1.75, 0.15),\n subtitle2: buildVariant(fontWeightMedium, 14, 1.57, 0.1),\n body1: buildVariant(fontWeightRegular, 16, 1.5, 0.15),\n body2: buildVariant(fontWeightRegular, 14, 1.43, 0.15),\n button: buildVariant(fontWeightMedium, 14, 1.75, 0.4, caseAllCaps),\n caption: buildVariant(fontWeightRegular, 12, 1.66, 0.4),\n overline: buildVariant(fontWeightRegular, 12, 2.66, 1, caseAllCaps),\n // TODO v6: Remove handling of 'inherit' variant from the theme as it is already handled in Material UI's Typography component. Also, remember to remove the associated types.\n inherit: {\n fontFamily: 'inherit',\n fontWeight: 'inherit',\n fontSize: 'inherit',\n lineHeight: 'inherit',\n letterSpacing: 'inherit'\n }\n };\n return deepmerge(_extends({\n htmlFontSize,\n pxToRem,\n fontFamily,\n fontSize,\n fontWeightLight,\n fontWeightRegular,\n fontWeightMedium,\n fontWeightBold\n }, variants), other, {\n clone: false // No need to clone deep\n });\n}","const shadowKeyUmbraOpacity = 0.2;\nconst shadowKeyPenumbraOpacity = 0.14;\nconst shadowAmbientShadowOpacity = 0.12;\nfunction createShadow(...px) {\n return [`${px[0]}px ${px[1]}px ${px[2]}px ${px[3]}px rgba(0,0,0,${shadowKeyUmbraOpacity})`, `${px[4]}px ${px[5]}px ${px[6]}px ${px[7]}px rgba(0,0,0,${shadowKeyPenumbraOpacity})`, `${px[8]}px ${px[9]}px ${px[10]}px ${px[11]}px rgba(0,0,0,${shadowAmbientShadowOpacity})`].join(',');\n}\n\n// Values from https://github.com/material-components/material-components-web/blob/be8747f94574669cb5e7add1a7c54fa41a89cec7/packages/mdc-elevation/_variables.scss\nconst shadows = ['none', createShadow(0, 2, 1, -1, 0, 1, 1, 0, 0, 1, 3, 0), createShadow(0, 3, 1, -2, 0, 2, 2, 0, 0, 1, 5, 0), createShadow(0, 3, 3, -2, 0, 3, 4, 0, 0, 1, 8, 0), createShadow(0, 2, 4, -1, 0, 4, 5, 0, 0, 1, 10, 0), createShadow(0, 3, 5, -1, 0, 5, 8, 0, 0, 1, 14, 0), createShadow(0, 3, 5, -1, 0, 6, 10, 0, 0, 1, 18, 0), createShadow(0, 4, 5, -2, 0, 7, 10, 1, 0, 2, 16, 1), createShadow(0, 5, 5, -3, 0, 8, 10, 1, 0, 3, 14, 2), createShadow(0, 5, 6, -3, 0, 9, 12, 1, 0, 3, 16, 2), createShadow(0, 6, 6, -3, 0, 10, 14, 1, 0, 4, 18, 3), createShadow(0, 6, 7, -4, 0, 11, 15, 1, 0, 4, 20, 3), createShadow(0, 7, 8, -4, 0, 12, 17, 2, 0, 5, 22, 4), createShadow(0, 7, 8, -4, 0, 13, 19, 2, 0, 5, 24, 4), createShadow(0, 7, 9, -4, 0, 14, 21, 2, 0, 5, 26, 4), createShadow(0, 8, 9, -5, 0, 15, 22, 2, 0, 6, 28, 5), createShadow(0, 8, 10, -5, 0, 16, 24, 2, 0, 6, 30, 5), createShadow(0, 8, 11, -5, 0, 17, 26, 2, 0, 6, 32, 5), createShadow(0, 9, 11, -5, 0, 18, 28, 2, 0, 7, 34, 6), createShadow(0, 9, 12, -6, 0, 19, 29, 2, 0, 7, 36, 6), createShadow(0, 10, 13, -6, 0, 20, 31, 3, 0, 8, 38, 7), createShadow(0, 10, 13, -6, 0, 21, 33, 3, 0, 8, 40, 7), createShadow(0, 10, 14, -6, 0, 22, 35, 3, 0, 8, 42, 7), createShadow(0, 11, 14, -7, 0, 23, 36, 3, 0, 9, 44, 8), createShadow(0, 11, 15, -7, 0, 24, 38, 3, 0, 9, 46, 8)];\nexport default shadows;","import _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nconst _excluded = [\"duration\", \"easing\", \"delay\"];\n// Follow https://material.google.com/motion/duration-easing.html#duration-easing-natural-easing-curves\n// to learn the context in which each easing should be used.\nexport const easing = {\n // This is the most common easing curve.\n easeInOut: 'cubic-bezier(0.4, 0, 0.2, 1)',\n // Objects enter the screen at full velocity from off-screen and\n // slowly decelerate to a resting point.\n easeOut: 'cubic-bezier(0.0, 0, 0.2, 1)',\n // Objects leave the screen at full velocity. They do not decelerate when off-screen.\n easeIn: 'cubic-bezier(0.4, 0, 1, 1)',\n // The sharp curve is used by objects that may return to the screen at any time.\n sharp: 'cubic-bezier(0.4, 0, 0.6, 1)'\n};\n\n// Follow https://m2.material.io/guidelines/motion/duration-easing.html#duration-easing-common-durations\n// to learn when use what timing\nexport const duration = {\n shortest: 150,\n shorter: 200,\n short: 250,\n // most basic recommended timing\n standard: 300,\n // this is to be used in complex animations\n complex: 375,\n // recommended when something is entering screen\n enteringScreen: 225,\n // recommended when something is leaving screen\n leavingScreen: 195\n};\nfunction formatMs(milliseconds) {\n return `${Math.round(milliseconds)}ms`;\n}\nfunction getAutoHeightDuration(height) {\n if (!height) {\n return 0;\n }\n const constant = height / 36;\n\n // https://www.wolframalpha.com/input/?i=(4+%2B+15+*+(x+%2F+36+)+**+0.25+%2B+(x+%2F+36)+%2F+5)+*+10\n return Math.round((4 + 15 * constant ** 0.25 + constant / 5) * 10);\n}\nexport default function createTransitions(inputTransitions) {\n const mergedEasing = _extends({}, easing, inputTransitions.easing);\n const mergedDuration = _extends({}, duration, inputTransitions.duration);\n const create = (props = ['all'], options = {}) => {\n const {\n duration: durationOption = mergedDuration.standard,\n easing: easingOption = mergedEasing.easeInOut,\n delay = 0\n } = options,\n other = _objectWithoutPropertiesLoose(options, _excluded);\n if (process.env.NODE_ENV !== 'production') {\n const isString = value => typeof value === 'string';\n // IE11 support, replace with Number.isNaN\n // eslint-disable-next-line no-restricted-globals\n const isNumber = value => !isNaN(parseFloat(value));\n if (!isString(props) && !Array.isArray(props)) {\n console.error('MUI: Argument \"props\" must be a string or Array.');\n }\n if (!isNumber(durationOption) && !isString(durationOption)) {\n console.error(`MUI: Argument \"duration\" must be a number or a string but found ${durationOption}.`);\n }\n if (!isString(easingOption)) {\n console.error('MUI: Argument \"easing\" must be a string.');\n }\n if (!isNumber(delay) && !isString(delay)) {\n console.error('MUI: Argument \"delay\" must be a number or a string.');\n }\n if (typeof options !== 'object') {\n console.error(['MUI: Secong argument of transition.create must be an object.', \"Arguments should be either `create('prop1', options)` or `create(['prop1', 'prop2'], options)`\"].join('\\n'));\n }\n if (Object.keys(other).length !== 0) {\n console.error(`MUI: Unrecognized argument(s) [${Object.keys(other).join(',')}].`);\n }\n }\n return (Array.isArray(props) ? props : [props]).map(animatedProp => `${animatedProp} ${typeof durationOption === 'string' ? durationOption : formatMs(durationOption)} ${easingOption} ${typeof delay === 'string' ? delay : formatMs(delay)}`).join(',');\n };\n return _extends({\n getAutoHeightDuration,\n create\n }, inputTransitions, {\n easing: mergedEasing,\n duration: mergedDuration\n });\n}","// We need to centralize the zIndex definitions as they work\n// like global values in the browser.\nconst zIndex = {\n mobileStepper: 1000,\n fab: 1050,\n speedDial: 1050,\n appBar: 1100,\n drawer: 1200,\n modal: 1300,\n snackbar: 1400,\n tooltip: 1500\n};\nexport default zIndex;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\nconst _excluded = [\"breakpoints\", \"mixins\", \"spacing\", \"palette\", \"transitions\", \"typography\", \"shape\"];\nimport { deepmerge } from '@mui/utils';\nimport { createTheme as systemCreateTheme, unstable_defaultSxConfig as defaultSxConfig, unstable_styleFunctionSx as styleFunctionSx } from '@mui/system';\nimport generateUtilityClass from '@mui/utils/generateUtilityClass';\nimport createMixins from './createMixins';\nimport createPalette from './createPalette';\nimport createTypography from './createTypography';\nimport shadows from './shadows';\nimport createTransitions from './createTransitions';\nimport zIndex from './zIndex';\nfunction createTheme(options = {}, ...args) {\n const {\n mixins: mixinsInput = {},\n palette: paletteInput = {},\n transitions: transitionsInput = {},\n typography: typographyInput = {}\n } = options,\n other = _objectWithoutPropertiesLoose(options, _excluded);\n if (options.vars) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: \\`vars\\` is a private field used for CSS variables support.\nPlease use another name.` : _formatMuiErrorMessage(18));\n }\n const palette = createPalette(paletteInput);\n const systemTheme = systemCreateTheme(options);\n let muiTheme = deepmerge(systemTheme, {\n mixins: createMixins(systemTheme.breakpoints, mixinsInput),\n palette,\n // Don't use [...shadows] until you've verified its transpiled code is not invoking the iterator protocol.\n shadows: shadows.slice(),\n typography: createTypography(palette, typographyInput),\n transitions: createTransitions(transitionsInput),\n zIndex: _extends({}, zIndex)\n });\n muiTheme = deepmerge(muiTheme, other);\n muiTheme = args.reduce((acc, argument) => deepmerge(acc, argument), muiTheme);\n if (process.env.NODE_ENV !== 'production') {\n // TODO v6: Refactor to use globalStateClassesMapping from @mui/utils once `readOnly` state class is used in Rating component.\n const stateClasses = ['active', 'checked', 'completed', 'disabled', 'error', 'expanded', 'focused', 'focusVisible', 'required', 'selected'];\n const traverse = (node, component) => {\n let key;\n\n // eslint-disable-next-line guard-for-in, no-restricted-syntax\n for (key in node) {\n const child = node[key];\n if (stateClasses.indexOf(key) !== -1 && Object.keys(child).length > 0) {\n if (process.env.NODE_ENV !== 'production') {\n const stateClass = generateUtilityClass('', key);\n console.error([`MUI: The \\`${component}\\` component increases ` + `the CSS specificity of the \\`${key}\\` internal state.`, 'You can not override it like this: ', JSON.stringify(node, null, 2), '', `Instead, you need to use the '&.${stateClass}' syntax:`, JSON.stringify({\n root: {\n [`&.${stateClass}`]: child\n }\n }, null, 2), '', 'https://mui.com/r/state-classes-guide'].join('\\n'));\n }\n // Remove the style to prevent global conflicts.\n node[key] = {};\n }\n }\n };\n Object.keys(muiTheme.components).forEach(component => {\n const styleOverrides = muiTheme.components[component].styleOverrides;\n if (styleOverrides && component.indexOf('Mui') === 0) {\n traverse(styleOverrides, component);\n }\n });\n }\n muiTheme.unstable_sxConfig = _extends({}, defaultSxConfig, other == null ? void 0 : other.unstable_sxConfig);\n muiTheme.unstable_sx = function sx(props) {\n return styleFunctionSx({\n sx: props,\n theme: this\n });\n };\n return muiTheme;\n}\nlet warnedOnce = false;\nexport function createMuiTheme(...args) {\n if (process.env.NODE_ENV !== 'production') {\n if (!warnedOnce) {\n warnedOnce = true;\n console.error(['MUI: the createMuiTheme function was renamed to createTheme.', '', \"You should use `import { createTheme } from '@mui/material/styles'`\"].join('\\n'));\n }\n }\n return createTheme(...args);\n}\nexport default createTheme;","'use client';\n\nimport createTheme from './createTheme';\nconst defaultTheme = createTheme();\nexport default defaultTheme;","export default '$$material';","'use client';\n\nimport { useThemeProps as systemUseThemeProps } from '@mui/system';\nimport defaultTheme from './defaultTheme';\nimport THEME_ID from './identifier';\nexport default function useThemeProps({\n props,\n name\n}) {\n return systemUseThemeProps({\n props,\n name,\n defaultTheme,\n themeId: THEME_ID\n });\n}","'use client';\n\nimport { createStyled, shouldForwardProp } from '@mui/system';\nimport defaultTheme from './defaultTheme';\nimport THEME_ID from './identifier';\nexport const rootShouldForwardProp = prop => shouldForwardProp(prop) && prop !== 'classes';\nexport const slotShouldForwardProp = shouldForwardProp;\nconst styled = createStyled({\n themeId: THEME_ID,\n defaultTheme,\n rootShouldForwardProp\n});\nexport default styled;","import generateUtilityClasses from '@mui/utils/generateUtilityClasses';\nimport generateUtilityClass from '@mui/utils/generateUtilityClass';\nexport function getSvgIconUtilityClass(slot) {\n return generateUtilityClass('MuiSvgIcon', slot);\n}\nconst svgIconClasses = generateUtilityClasses('MuiSvgIcon', ['root', 'colorPrimary', 'colorSecondary', 'colorAction', 'colorError', 'colorDisabled', 'fontSizeInherit', 'fontSizeSmall', 'fontSizeMedium', 'fontSizeLarge']);\nexport default svgIconClasses;","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"children\", \"className\", \"color\", \"component\", \"fontSize\", \"htmlColor\", \"inheritViewBox\", \"titleAccess\", \"viewBox\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport clsx from 'clsx';\nimport { unstable_composeClasses as composeClasses } from '@mui/base/composeClasses';\nimport capitalize from '../utils/capitalize';\nimport useThemeProps from '../styles/useThemeProps';\nimport styled from '../styles/styled';\nimport { getSvgIconUtilityClass } from './svgIconClasses';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nimport { jsxs as _jsxs } from \"react/jsx-runtime\";\nconst useUtilityClasses = ownerState => {\n const {\n color,\n fontSize,\n classes\n } = ownerState;\n const slots = {\n root: ['root', color !== 'inherit' && `color${capitalize(color)}`, `fontSize${capitalize(fontSize)}`]\n };\n return composeClasses(slots, getSvgIconUtilityClass, classes);\n};\nconst SvgIconRoot = styled('svg', {\n name: 'MuiSvgIcon',\n slot: 'Root',\n overridesResolver: (props, styles) => {\n const {\n ownerState\n } = props;\n return [styles.root, ownerState.color !== 'inherit' && styles[`color${capitalize(ownerState.color)}`], styles[`fontSize${capitalize(ownerState.fontSize)}`]];\n }\n})(({\n theme,\n ownerState\n}) => {\n var _theme$transitions, _theme$transitions$cr, _theme$transitions2, _theme$typography, _theme$typography$pxT, _theme$typography2, _theme$typography2$px, _theme$typography3, _theme$typography3$px, _palette$ownerState$c, _palette, _palette2, _palette3;\n return {\n userSelect: 'none',\n width: '1em',\n height: '1em',\n display: 'inline-block',\n // the will define the property that has `currentColor`\n // e.g. heroicons uses fill=\"none\" and stroke=\"currentColor\"\n fill: ownerState.hasSvgAsChild ? undefined : 'currentColor',\n flexShrink: 0,\n transition: (_theme$transitions = theme.transitions) == null || (_theme$transitions$cr = _theme$transitions.create) == null ? void 0 : _theme$transitions$cr.call(_theme$transitions, 'fill', {\n duration: (_theme$transitions2 = theme.transitions) == null || (_theme$transitions2 = _theme$transitions2.duration) == null ? void 0 : _theme$transitions2.shorter\n }),\n fontSize: {\n inherit: 'inherit',\n small: ((_theme$typography = theme.typography) == null || (_theme$typography$pxT = _theme$typography.pxToRem) == null ? void 0 : _theme$typography$pxT.call(_theme$typography, 20)) || '1.25rem',\n medium: ((_theme$typography2 = theme.typography) == null || (_theme$typography2$px = _theme$typography2.pxToRem) == null ? void 0 : _theme$typography2$px.call(_theme$typography2, 24)) || '1.5rem',\n large: ((_theme$typography3 = theme.typography) == null || (_theme$typography3$px = _theme$typography3.pxToRem) == null ? void 0 : _theme$typography3$px.call(_theme$typography3, 35)) || '2.1875rem'\n }[ownerState.fontSize],\n // TODO v5 deprecate, v6 remove for sx\n color: (_palette$ownerState$c = (_palette = (theme.vars || theme).palette) == null || (_palette = _palette[ownerState.color]) == null ? void 0 : _palette.main) != null ? _palette$ownerState$c : {\n action: (_palette2 = (theme.vars || theme).palette) == null || (_palette2 = _palette2.action) == null ? void 0 : _palette2.active,\n disabled: (_palette3 = (theme.vars || theme).palette) == null || (_palette3 = _palette3.action) == null ? void 0 : _palette3.disabled,\n inherit: undefined\n }[ownerState.color]\n };\n});\nconst SvgIcon = /*#__PURE__*/React.forwardRef(function SvgIcon(inProps, ref) {\n const props = useThemeProps({\n props: inProps,\n name: 'MuiSvgIcon'\n });\n const {\n children,\n className,\n color = 'inherit',\n component = 'svg',\n fontSize = 'medium',\n htmlColor,\n inheritViewBox = false,\n titleAccess,\n viewBox = '0 0 24 24'\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const hasSvgAsChild = /*#__PURE__*/React.isValidElement(children) && children.type === 'svg';\n const ownerState = _extends({}, props, {\n color,\n component,\n fontSize,\n instanceFontSize: inProps.fontSize,\n inheritViewBox,\n viewBox,\n hasSvgAsChild\n });\n const more = {};\n if (!inheritViewBox) {\n more.viewBox = viewBox;\n }\n const classes = useUtilityClasses(ownerState);\n return /*#__PURE__*/_jsxs(SvgIconRoot, _extends({\n as: component,\n className: clsx(classes.root, className),\n focusable: \"false\",\n color: htmlColor,\n \"aria-hidden\": titleAccess ? undefined : true,\n role: titleAccess ? 'img' : undefined,\n ref: ref\n }, more, other, hasSvgAsChild && children.props, {\n ownerState: ownerState,\n children: [hasSvgAsChild ? children.props.children : children, titleAccess ? /*#__PURE__*/_jsx(\"title\", {\n children: titleAccess\n }) : null]\n }));\n});\nprocess.env.NODE_ENV !== \"production\" ? SvgIcon.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the d.ts file and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * Node passed into the SVG element.\n */\n children: PropTypes.node,\n /**\n * Override or extend the styles applied to the component.\n */\n classes: PropTypes.object,\n /**\n * @ignore\n */\n className: PropTypes.string,\n /**\n * The color of the component.\n * It supports both default and custom theme colors, which can be added as shown in the\n * [palette customization guide](https://mui.com/material-ui/customization/palette/#custom-colors).\n * You can use the `htmlColor` prop to apply a color attribute to the SVG element.\n * @default 'inherit'\n */\n color: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.oneOf(['inherit', 'action', 'disabled', 'primary', 'secondary', 'error', 'info', 'success', 'warning']), PropTypes.string]),\n /**\n * The component used for the root node.\n * Either a string to use a HTML element or a component.\n */\n component: PropTypes.elementType,\n /**\n * The fontSize applied to the icon. Defaults to 24px, but can be configure to inherit font size.\n * @default 'medium'\n */\n fontSize: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.oneOf(['inherit', 'large', 'medium', 'small']), PropTypes.string]),\n /**\n * Applies a color attribute to the SVG element.\n */\n htmlColor: PropTypes.string,\n /**\n * If `true`, the root node will inherit the custom `component`'s viewBox and the `viewBox`\n * prop will be ignored.\n * Useful when you want to reference a custom `component` and have `SvgIcon` pass that\n * `component`'s viewBox to the root node.\n * @default false\n */\n inheritViewBox: PropTypes.bool,\n /**\n * The shape-rendering attribute. The behavior of the different options is described on the\n * [MDN Web Docs](https://developer.mozilla.org/en-US/docs/Web/SVG/Attribute/shape-rendering).\n * If you are having issues with blurry icons you should investigate this prop.\n */\n shapeRendering: PropTypes.string,\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Provides a human-readable title for the element that contains it.\n * https://www.w3.org/TR/SVG-access/#Equivalent\n */\n titleAccess: PropTypes.string,\n /**\n * Allows you to redefine what the coordinates without units mean inside an SVG element.\n * For example, if the SVG element is 500 (width) by 200 (height),\n * and you pass viewBox=\"0 0 50 20\",\n * this means that the coordinates inside the SVG will go from the top left corner (0,0)\n * to bottom right (50,20) and each unit will be worth 10px.\n * @default '0 0 24 24'\n */\n viewBox: PropTypes.string\n} : void 0;\nSvgIcon.muiName = 'SvgIcon';\nexport default SvgIcon;","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport * as React from 'react';\nimport SvgIcon from '../SvgIcon';\n\n/**\n * Private module reserved for @mui packages.\n */\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nexport default function createSvgIcon(path, displayName) {\n function Component(props, ref) {\n return /*#__PURE__*/_jsx(SvgIcon, _extends({\n \"data-testid\": `${displayName}Icon`,\n ref: ref\n }, props, {\n children: path\n }));\n }\n if (process.env.NODE_ENV !== 'production') {\n // Need to set `displayName` on the inner component for React.memo.\n // React prior to 16.14 ignores `displayName` on the wrapper.\n Component.displayName = `${displayName}Icon`;\n }\n Component.muiName = SvgIcon.muiName;\n return /*#__PURE__*/React.memo( /*#__PURE__*/React.forwardRef(Component));\n}","'use client';\n\nimport { unstable_ClassNameGenerator as ClassNameGenerator } from '@mui/base/ClassNameGenerator';\nexport { default as capitalize } from './capitalize';\nexport { default as createChainedFunction } from './createChainedFunction';\nexport { default as createSvgIcon } from './createSvgIcon';\nexport { default as debounce } from './debounce';\nexport { default as deprecatedPropType } from './deprecatedPropType';\nexport { default as isMuiElement } from './isMuiElement';\nexport { default as ownerDocument } from './ownerDocument';\nexport { default as ownerWindow } from './ownerWindow';\nexport { default as requirePropFactory } from './requirePropFactory';\nexport { default as setRef } from './setRef';\nexport { default as unstable_useEnhancedEffect } from './useEnhancedEffect';\nexport { default as unstable_useId } from './useId';\nexport { default as unsupportedProp } from './unsupportedProp';\nexport { default as useControlled } from './useControlled';\nexport { default as useEventCallback } from './useEventCallback';\nexport { default as useForkRef } from './useForkRef';\nexport { default as useIsFocusVisible } from './useIsFocusVisible';\n// TODO: remove this export once ClassNameGenerator is stable\n// eslint-disable-next-line @typescript-eslint/naming-convention\nexport const unstable_ClassNameGenerator = {\n configure: generator => {\n if (process.env.NODE_ENV !== 'production') {\n console.warn(['MUI: `ClassNameGenerator` import from `@mui/material/utils` is outdated and might cause unexpected issues.', '', \"You should use `import { unstable_ClassNameGenerator } from '@mui/material/className'` instead\", '', 'The detail of the issue: https://github.com/mui/material-ui/issues/30011#issuecomment-1024993401', '', 'The updated documentation: https://mui.com/guides/classname-generator/'].join('\\n'));\n }\n ClassNameGenerator.configure(generator);\n }\n};","\"use strict\";\n'use client';\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nObject.defineProperty(exports, \"default\", {\n enumerable: true,\n get: function () {\n return _utils.createSvgIcon;\n }\n});\nvar _utils = require(\"@mui/material/utils\");","\"use strict\";\n\"use client\";\n\nvar _interopRequireDefault = require(\"@babel/runtime/helpers/interopRequireDefault\");\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = void 0;\nvar _createSvgIcon = _interopRequireDefault(require(\"./utils/createSvgIcon\"));\nvar _jsxRuntime = require(\"react/jsx-runtime\");\nvar _default = exports.default = (0, _createSvgIcon.default)( /*#__PURE__*/(0, _jsxRuntime.jsx)(\"path\", {\n d: \"m10 17 5-5-5-5z\"\n}), 'ArrowRight');","/**\n * Determines if a given element is a DOM element name (i.e. not a React component).\n */\nexport function isHostComponent(element) {\n return typeof element === 'string';\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport { isHostComponent } from './isHostComponent';\n\n/**\n * Type of the ownerState based on the type of an element it applies to.\n * This resolves to the provided OwnerState for React components and `undefined` for host components.\n * Falls back to `OwnerState | undefined` when the exact type can't be determined in development time.\n */\n\n/**\n * Appends the ownerState object to the props, merging with the existing one if necessary.\n *\n * @param elementType Type of the element that owns the `existingProps`. If the element is a DOM node or undefined, `ownerState` is not applied.\n * @param otherProps Props of the element.\n * @param ownerState\n */\nexport function appendOwnerState(elementType, otherProps, ownerState) {\n if (elementType === undefined || isHostComponent(elementType)) {\n return otherProps;\n }\n return _extends({}, otherProps, {\n ownerState: _extends({}, otherProps.ownerState, ownerState)\n });\n}","'use client';\n\nimport * as React from 'react';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nconst defaultContextValue = {\n disableDefaultClasses: false\n};\nconst ClassNameConfiguratorContext = /*#__PURE__*/React.createContext(defaultContextValue);\n/**\n * @ignore - internal hook.\n *\n * Wraps the `generateUtilityClass` function and controls how the classes are generated.\n * Currently it only affects whether the classes are applied or not.\n *\n * @returns Function to be called with the `generateUtilityClass` function specific to a component to generate the classes.\n */\nexport function useClassNamesOverride(generateUtilityClass) {\n const {\n disableDefaultClasses\n } = React.useContext(ClassNameConfiguratorContext);\n return slot => {\n if (disableDefaultClasses) {\n return '';\n }\n return generateUtilityClass(slot);\n };\n}\n\n/**\n * Allows to configure the components within to not apply any built-in classes.\n */\nexport function ClassNameConfigurator(props) {\n const {\n disableDefaultClasses,\n children\n } = props;\n const contextValue = React.useMemo(() => ({\n disableDefaultClasses: disableDefaultClasses != null ? disableDefaultClasses : false\n }), [disableDefaultClasses]);\n return /*#__PURE__*/_jsx(ClassNameConfiguratorContext.Provider, {\n value: contextValue,\n children: children\n });\n}","/**\n * Extracts event handlers from a given object.\n * A prop is considered an event handler if it is a function and its name starts with `on`.\n *\n * @param object An object to extract event handlers from.\n * @param excludeKeys An array of keys to exclude from the returned object.\n */\nexport function extractEventHandlers(object, excludeKeys = []) {\n if (object === undefined) {\n return {};\n }\n const result = {};\n Object.keys(object).filter(prop => prop.match(/^on[A-Z]/) && typeof object[prop] === 'function' && !excludeKeys.includes(prop)).forEach(prop => {\n result[prop] = object[prop];\n });\n return result;\n}","/**\n * If `componentProps` is a function, calls it with the provided `ownerState`.\n * Otherwise, just returns `componentProps`.\n */\nexport function resolveComponentProps(componentProps, ownerState, slotState) {\n if (typeof componentProps === 'function') {\n return componentProps(ownerState, slotState);\n }\n return componentProps;\n}","/**\n * Removes event handlers from the given object.\n * A field is considered an event handler if it is a function with a name beginning with `on`.\n *\n * @param object Object to remove event handlers from.\n * @returns Object with event handlers removed.\n */\nexport function omitEventHandlers(object) {\n if (object === undefined) {\n return {};\n }\n const result = {};\n Object.keys(object).filter(prop => !(prop.match(/^on[A-Z]/) && typeof object[prop] === 'function')).forEach(prop => {\n result[prop] = object[prop];\n });\n return result;\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport clsx from 'clsx';\nimport { extractEventHandlers } from './extractEventHandlers';\nimport { omitEventHandlers } from './omitEventHandlers';\n/**\n * Merges the slot component internal props (usually coming from a hook)\n * with the externally provided ones.\n *\n * The merge order is (the latter overrides the former):\n * 1. The internal props (specified as a getter function to work with get*Props hook result)\n * 2. Additional props (specified internally on a Base UI component)\n * 3. External props specified on the owner component. These should only be used on a root slot.\n * 4. External props specified in the `slotProps.*` prop.\n * 5. The `className` prop - combined from all the above.\n * @param parameters\n * @returns\n */\nexport function mergeSlotProps(parameters) {\n const {\n getSlotProps,\n additionalProps,\n externalSlotProps,\n externalForwardedProps,\n className\n } = parameters;\n if (!getSlotProps) {\n // The simpler case - getSlotProps is not defined, so no internal event handlers are defined,\n // so we can simply merge all the props without having to worry about extracting event handlers.\n const joinedClasses = clsx(additionalProps == null ? void 0 : additionalProps.className, className, externalForwardedProps == null ? void 0 : externalForwardedProps.className, externalSlotProps == null ? void 0 : externalSlotProps.className);\n const mergedStyle = _extends({}, additionalProps == null ? void 0 : additionalProps.style, externalForwardedProps == null ? void 0 : externalForwardedProps.style, externalSlotProps == null ? void 0 : externalSlotProps.style);\n const props = _extends({}, additionalProps, externalForwardedProps, externalSlotProps);\n if (joinedClasses.length > 0) {\n props.className = joinedClasses;\n }\n if (Object.keys(mergedStyle).length > 0) {\n props.style = mergedStyle;\n }\n return {\n props,\n internalRef: undefined\n };\n }\n\n // In this case, getSlotProps is responsible for calling the external event handlers.\n // We don't need to include them in the merged props because of this.\n\n const eventHandlers = extractEventHandlers(_extends({}, externalForwardedProps, externalSlotProps));\n const componentsPropsWithoutEventHandlers = omitEventHandlers(externalSlotProps);\n const otherPropsWithoutEventHandlers = omitEventHandlers(externalForwardedProps);\n const internalSlotProps = getSlotProps(eventHandlers);\n\n // The order of classes is important here.\n // Emotion (that we use in libraries consuming Base UI) depends on this order\n // to properly override style. It requires the most important classes to be last\n // (see https://github.com/mui/material-ui/pull/33205) for the related discussion.\n const joinedClasses = clsx(internalSlotProps == null ? void 0 : internalSlotProps.className, additionalProps == null ? void 0 : additionalProps.className, className, externalForwardedProps == null ? void 0 : externalForwardedProps.className, externalSlotProps == null ? void 0 : externalSlotProps.className);\n const mergedStyle = _extends({}, internalSlotProps == null ? void 0 : internalSlotProps.style, additionalProps == null ? void 0 : additionalProps.style, externalForwardedProps == null ? void 0 : externalForwardedProps.style, externalSlotProps == null ? void 0 : externalSlotProps.style);\n const props = _extends({}, internalSlotProps, additionalProps, otherPropsWithoutEventHandlers, componentsPropsWithoutEventHandlers);\n if (joinedClasses.length > 0) {\n props.className = joinedClasses;\n }\n if (Object.keys(mergedStyle).length > 0) {\n props.style = mergedStyle;\n }\n return {\n props,\n internalRef: internalSlotProps.ref\n };\n}","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"elementType\", \"externalSlotProps\", \"ownerState\", \"skipResolvingSlotProps\"];\nimport { unstable_useForkRef as useForkRef } from '@mui/utils';\nimport { appendOwnerState } from './appendOwnerState';\nimport { mergeSlotProps } from './mergeSlotProps';\nimport { resolveComponentProps } from './resolveComponentProps';\n/**\n * @ignore - do not document.\n * Builds the props to be passed into the slot of an unstyled component.\n * It merges the internal props of the component with the ones supplied by the user, allowing to customize the behavior.\n * If the slot component is not a host component, it also merges in the `ownerState`.\n *\n * @param parameters.getSlotProps - A function that returns the props to be passed to the slot component.\n */\nexport function useSlotProps(parameters) {\n var _parameters$additiona;\n const {\n elementType,\n externalSlotProps,\n ownerState,\n skipResolvingSlotProps = false\n } = parameters,\n rest = _objectWithoutPropertiesLoose(parameters, _excluded);\n const resolvedComponentsProps = skipResolvingSlotProps ? {} : resolveComponentProps(externalSlotProps, ownerState);\n const {\n props: mergedProps,\n internalRef\n } = mergeSlotProps(_extends({}, rest, {\n externalSlotProps: resolvedComponentsProps\n }));\n const ref = useForkRef(internalRef, resolvedComponentsProps == null ? void 0 : resolvedComponentsProps.ref, (_parameters$additiona = parameters.additionalProps) == null ? void 0 : _parameters$additiona.ref);\n const props = appendOwnerState(elementType, _extends({}, mergedProps, {\n ref\n }), ownerState);\n return props;\n}","import { globalStateClasses } from '@mui/utils/generateUtilityClass';\nconst GLOBAL_CLASS_PREFIX = 'base';\nfunction buildStateClass(state) {\n return `${GLOBAL_CLASS_PREFIX}--${state}`;\n}\nfunction buildSlotClass(componentName, slot) {\n return `${GLOBAL_CLASS_PREFIX}-${componentName}-${slot}`;\n}\nexport function generateUtilityClass(componentName, slot) {\n const globalStateClass = globalStateClasses[slot];\n return globalStateClass ? buildStateClass(globalStateClass) : buildSlotClass(componentName, slot);\n}\nexport function isGlobalState(slot) {\n return globalStateClasses[slot] !== undefined;\n}","import { generateUtilityClass } from '../generateUtilityClass';\nexport function generateUtilityClasses(componentName, slots) {\n const result = {};\n slots.forEach(slot => {\n result[slot] = generateUtilityClass(componentName, slot);\n });\n return result;\n}","'use client';\n\nimport * as React from 'react';\nimport * as ReactDOM from 'react-dom';\nimport PropTypes from 'prop-types';\nimport { exactProp, HTMLElementType, unstable_useEnhancedEffect as useEnhancedEffect, unstable_useForkRef as useForkRef, unstable_setRef as setRef } from '@mui/utils';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nfunction getContainer(container) {\n return typeof container === 'function' ? container() : container;\n}\n\n/**\n * Portals provide a first-class way to render children into a DOM node\n * that exists outside the DOM hierarchy of the parent component.\n *\n * Demos:\n *\n * - [Portal](https://mui.com/base-ui/react-portal/)\n *\n * API:\n *\n * - [Portal API](https://mui.com/base-ui/react-portal/components-api/#portal)\n */\nconst Portal = /*#__PURE__*/React.forwardRef(function Portal(props, forwardedRef) {\n const {\n children,\n container,\n disablePortal = false\n } = props;\n const [mountNode, setMountNode] = React.useState(null);\n // @ts-expect-error TODO upstream fix\n const handleRef = useForkRef( /*#__PURE__*/React.isValidElement(children) ? children.ref : null, forwardedRef);\n useEnhancedEffect(() => {\n if (!disablePortal) {\n setMountNode(getContainer(container) || document.body);\n }\n }, [container, disablePortal]);\n useEnhancedEffect(() => {\n if (mountNode && !disablePortal) {\n setRef(forwardedRef, mountNode);\n return () => {\n setRef(forwardedRef, null);\n };\n }\n return undefined;\n }, [forwardedRef, mountNode, disablePortal]);\n if (disablePortal) {\n if ( /*#__PURE__*/React.isValidElement(children)) {\n const newProps = {\n ref: handleRef\n };\n return /*#__PURE__*/React.cloneElement(children, newProps);\n }\n return /*#__PURE__*/_jsx(React.Fragment, {\n children: children\n });\n }\n return /*#__PURE__*/_jsx(React.Fragment, {\n children: mountNode ? /*#__PURE__*/ReactDOM.createPortal(children, mountNode) : mountNode\n });\n});\nprocess.env.NODE_ENV !== \"production\" ? Portal.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * The children to render into the `container`.\n */\n children: PropTypes.node,\n /**\n * An HTML element or function that returns one.\n * The `container` will have the portal children appended to it.\n *\n * You can also provide a callback, which is called in a React layout effect.\n * This lets you set the container from a ref, and also makes server-side rendering possible.\n *\n * By default, it uses the body of the top-level document object,\n * so it's simply `document.body` most of the time.\n */\n container: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.func]),\n /**\n * The `children` will be under the DOM hierarchy of the parent component.\n * @default false\n */\n disablePortal: PropTypes.bool\n} : void 0;\nif (process.env.NODE_ENV !== 'production') {\n // eslint-disable-next-line\n Portal['propTypes' + ''] = exactProp(Portal.propTypes);\n}\nexport { Portal };","export var top = 'top';\nexport var bottom = 'bottom';\nexport var right = 'right';\nexport var left = 'left';\nexport var auto = 'auto';\nexport var basePlacements = [top, bottom, right, left];\nexport var start = 'start';\nexport var end = 'end';\nexport var clippingParents = 'clippingParents';\nexport var viewport = 'viewport';\nexport var popper = 'popper';\nexport var reference = 'reference';\nexport var variationPlacements = /*#__PURE__*/basePlacements.reduce(function (acc, placement) {\n return acc.concat([placement + \"-\" + start, placement + \"-\" + end]);\n}, []);\nexport var placements = /*#__PURE__*/[].concat(basePlacements, [auto]).reduce(function (acc, placement) {\n return acc.concat([placement, placement + \"-\" + start, placement + \"-\" + end]);\n}, []); // modifiers that need to read the DOM\n\nexport var beforeRead = 'beforeRead';\nexport var read = 'read';\nexport var afterRead = 'afterRead'; // pure-logic modifiers\n\nexport var beforeMain = 'beforeMain';\nexport var main = 'main';\nexport var afterMain = 'afterMain'; // modifier with the purpose to write to the DOM (or write into a framework state)\n\nexport var beforeWrite = 'beforeWrite';\nexport var write = 'write';\nexport var afterWrite = 'afterWrite';\nexport var modifierPhases = [beforeRead, read, afterRead, beforeMain, main, afterMain, beforeWrite, write, afterWrite];","export default function getNodeName(element) {\n return element ? (element.nodeName || '').toLowerCase() : null;\n}","export default function getWindow(node) {\n if (node == null) {\n return window;\n }\n\n if (node.toString() !== '[object Window]') {\n var ownerDocument = node.ownerDocument;\n return ownerDocument ? ownerDocument.defaultView || window : window;\n }\n\n return node;\n}","import getWindow from \"./getWindow.js\";\n\nfunction isElement(node) {\n var OwnElement = getWindow(node).Element;\n return node instanceof OwnElement || node instanceof Element;\n}\n\nfunction isHTMLElement(node) {\n var OwnElement = getWindow(node).HTMLElement;\n return node instanceof OwnElement || node instanceof HTMLElement;\n}\n\nfunction isShadowRoot(node) {\n // IE 11 has no ShadowRoot\n if (typeof ShadowRoot === 'undefined') {\n return false;\n }\n\n var OwnElement = getWindow(node).ShadowRoot;\n return node instanceof OwnElement || node instanceof ShadowRoot;\n}\n\nexport { isElement, isHTMLElement, isShadowRoot };","import getNodeName from \"../dom-utils/getNodeName.js\";\nimport { isHTMLElement } from \"../dom-utils/instanceOf.js\"; // This modifier takes the styles prepared by the `computeStyles` modifier\n// and applies them to the HTMLElements such as popper and arrow\n\nfunction applyStyles(_ref) {\n var state = _ref.state;\n Object.keys(state.elements).forEach(function (name) {\n var style = state.styles[name] || {};\n var attributes = state.attributes[name] || {};\n var element = state.elements[name]; // arrow is optional + virtual elements\n\n if (!isHTMLElement(element) || !getNodeName(element)) {\n return;\n } // Flow doesn't support to extend this property, but it's the most\n // effective way to apply styles to an HTMLElement\n // $FlowFixMe[cannot-write]\n\n\n Object.assign(element.style, style);\n Object.keys(attributes).forEach(function (name) {\n var value = attributes[name];\n\n if (value === false) {\n element.removeAttribute(name);\n } else {\n element.setAttribute(name, value === true ? '' : value);\n }\n });\n });\n}\n\nfunction effect(_ref2) {\n var state = _ref2.state;\n var initialStyles = {\n popper: {\n position: state.options.strategy,\n left: '0',\n top: '0',\n margin: '0'\n },\n arrow: {\n position: 'absolute'\n },\n reference: {}\n };\n Object.assign(state.elements.popper.style, initialStyles.popper);\n state.styles = initialStyles;\n\n if (state.elements.arrow) {\n Object.assign(state.elements.arrow.style, initialStyles.arrow);\n }\n\n return function () {\n Object.keys(state.elements).forEach(function (name) {\n var element = state.elements[name];\n var attributes = state.attributes[name] || {};\n var styleProperties = Object.keys(state.styles.hasOwnProperty(name) ? state.styles[name] : initialStyles[name]); // Set all values to an empty string to unset them\n\n var style = styleProperties.reduce(function (style, property) {\n style[property] = '';\n return style;\n }, {}); // arrow is optional + virtual elements\n\n if (!isHTMLElement(element) || !getNodeName(element)) {\n return;\n }\n\n Object.assign(element.style, style);\n Object.keys(attributes).forEach(function (attribute) {\n element.removeAttribute(attribute);\n });\n });\n };\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'applyStyles',\n enabled: true,\n phase: 'write',\n fn: applyStyles,\n effect: effect,\n requires: ['computeStyles']\n};","import { auto } from \"../enums.js\";\nexport default function getBasePlacement(placement) {\n return placement.split('-')[0];\n}","export var max = Math.max;\nexport var min = Math.min;\nexport var round = Math.round;","export default function getUAString() {\n var uaData = navigator.userAgentData;\n\n if (uaData != null && uaData.brands && Array.isArray(uaData.brands)) {\n return uaData.brands.map(function (item) {\n return item.brand + \"/\" + item.version;\n }).join(' ');\n }\n\n return navigator.userAgent;\n}","import getUAString from \"../utils/userAgent.js\";\nexport default function isLayoutViewport() {\n return !/^((?!chrome|android).)*safari/i.test(getUAString());\n}","import { isElement, isHTMLElement } from \"./instanceOf.js\";\nimport { round } from \"../utils/math.js\";\nimport getWindow from \"./getWindow.js\";\nimport isLayoutViewport from \"./isLayoutViewport.js\";\nexport default function getBoundingClientRect(element, includeScale, isFixedStrategy) {\n if (includeScale === void 0) {\n includeScale = false;\n }\n\n if (isFixedStrategy === void 0) {\n isFixedStrategy = false;\n }\n\n var clientRect = element.getBoundingClientRect();\n var scaleX = 1;\n var scaleY = 1;\n\n if (includeScale && isHTMLElement(element)) {\n scaleX = element.offsetWidth > 0 ? round(clientRect.width) / element.offsetWidth || 1 : 1;\n scaleY = element.offsetHeight > 0 ? round(clientRect.height) / element.offsetHeight || 1 : 1;\n }\n\n var _ref = isElement(element) ? getWindow(element) : window,\n visualViewport = _ref.visualViewport;\n\n var addVisualOffsets = !isLayoutViewport() && isFixedStrategy;\n var x = (clientRect.left + (addVisualOffsets && visualViewport ? visualViewport.offsetLeft : 0)) / scaleX;\n var y = (clientRect.top + (addVisualOffsets && visualViewport ? visualViewport.offsetTop : 0)) / scaleY;\n var width = clientRect.width / scaleX;\n var height = clientRect.height / scaleY;\n return {\n width: width,\n height: height,\n top: y,\n right: x + width,\n bottom: y + height,\n left: x,\n x: x,\n y: y\n };\n}","import getBoundingClientRect from \"./getBoundingClientRect.js\"; // Returns the layout rect of an element relative to its offsetParent. Layout\n// means it doesn't take into account transforms.\n\nexport default function getLayoutRect(element) {\n var clientRect = getBoundingClientRect(element); // Use the clientRect sizes if it's not been transformed.\n // Fixes https://github.com/popperjs/popper-core/issues/1223\n\n var width = element.offsetWidth;\n var height = element.offsetHeight;\n\n if (Math.abs(clientRect.width - width) <= 1) {\n width = clientRect.width;\n }\n\n if (Math.abs(clientRect.height - height) <= 1) {\n height = clientRect.height;\n }\n\n return {\n x: element.offsetLeft,\n y: element.offsetTop,\n width: width,\n height: height\n };\n}","import { isShadowRoot } from \"./instanceOf.js\";\nexport default function contains(parent, child) {\n var rootNode = child.getRootNode && child.getRootNode(); // First, attempt with faster native method\n\n if (parent.contains(child)) {\n return true;\n } // then fallback to custom implementation with Shadow DOM support\n else if (rootNode && isShadowRoot(rootNode)) {\n var next = child;\n\n do {\n if (next && parent.isSameNode(next)) {\n return true;\n } // $FlowFixMe[prop-missing]: need a better way to handle this...\n\n\n next = next.parentNode || next.host;\n } while (next);\n } // Give up, the result is false\n\n\n return false;\n}","import getWindow from \"./getWindow.js\";\nexport default function getComputedStyle(element) {\n return getWindow(element).getComputedStyle(element);\n}","import getNodeName from \"./getNodeName.js\";\nexport default function isTableElement(element) {\n return ['table', 'td', 'th'].indexOf(getNodeName(element)) >= 0;\n}","import { isElement } from \"./instanceOf.js\";\nexport default function getDocumentElement(element) {\n // $FlowFixMe[incompatible-return]: assume body is always available\n return ((isElement(element) ? element.ownerDocument : // $FlowFixMe[prop-missing]\n element.document) || window.document).documentElement;\n}","import getNodeName from \"./getNodeName.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport { isShadowRoot } from \"./instanceOf.js\";\nexport default function getParentNode(element) {\n if (getNodeName(element) === 'html') {\n return element;\n }\n\n return (// this is a quicker (but less type safe) way to save quite some bytes from the bundle\n // $FlowFixMe[incompatible-return]\n // $FlowFixMe[prop-missing]\n element.assignedSlot || // step into the shadow DOM of the parent of a slotted node\n element.parentNode || ( // DOM Element detected\n isShadowRoot(element) ? element.host : null) || // ShadowRoot detected\n // $FlowFixMe[incompatible-call]: HTMLElement is a Node\n getDocumentElement(element) // fallback\n\n );\n}","import getWindow from \"./getWindow.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport getComputedStyle from \"./getComputedStyle.js\";\nimport { isHTMLElement, isShadowRoot } from \"./instanceOf.js\";\nimport isTableElement from \"./isTableElement.js\";\nimport getParentNode from \"./getParentNode.js\";\nimport getUAString from \"../utils/userAgent.js\";\n\nfunction getTrueOffsetParent(element) {\n if (!isHTMLElement(element) || // https://github.com/popperjs/popper-core/issues/837\n getComputedStyle(element).position === 'fixed') {\n return null;\n }\n\n return element.offsetParent;\n} // `.offsetParent` reports `null` for fixed elements, while absolute elements\n// return the containing block\n\n\nfunction getContainingBlock(element) {\n var isFirefox = /firefox/i.test(getUAString());\n var isIE = /Trident/i.test(getUAString());\n\n if (isIE && isHTMLElement(element)) {\n // In IE 9, 10 and 11 fixed elements containing block is always established by the viewport\n var elementCss = getComputedStyle(element);\n\n if (elementCss.position === 'fixed') {\n return null;\n }\n }\n\n var currentNode = getParentNode(element);\n\n if (isShadowRoot(currentNode)) {\n currentNode = currentNode.host;\n }\n\n while (isHTMLElement(currentNode) && ['html', 'body'].indexOf(getNodeName(currentNode)) < 0) {\n var css = getComputedStyle(currentNode); // This is non-exhaustive but covers the most common CSS properties that\n // create a containing block.\n // https://developer.mozilla.org/en-US/docs/Web/CSS/Containing_block#identifying_the_containing_block\n\n if (css.transform !== 'none' || css.perspective !== 'none' || css.contain === 'paint' || ['transform', 'perspective'].indexOf(css.willChange) !== -1 || isFirefox && css.willChange === 'filter' || isFirefox && css.filter && css.filter !== 'none') {\n return currentNode;\n } else {\n currentNode = currentNode.parentNode;\n }\n }\n\n return null;\n} // Gets the closest ancestor positioned element. Handles some edge cases,\n// such as table ancestors and cross browser bugs.\n\n\nexport default function getOffsetParent(element) {\n var window = getWindow(element);\n var offsetParent = getTrueOffsetParent(element);\n\n while (offsetParent && isTableElement(offsetParent) && getComputedStyle(offsetParent).position === 'static') {\n offsetParent = getTrueOffsetParent(offsetParent);\n }\n\n if (offsetParent && (getNodeName(offsetParent) === 'html' || getNodeName(offsetParent) === 'body' && getComputedStyle(offsetParent).position === 'static')) {\n return window;\n }\n\n return offsetParent || getContainingBlock(element) || window;\n}","export default function getMainAxisFromPlacement(placement) {\n return ['top', 'bottom'].indexOf(placement) >= 0 ? 'x' : 'y';\n}","import { max as mathMax, min as mathMin } from \"./math.js\";\nexport function within(min, value, max) {\n return mathMax(min, mathMin(value, max));\n}\nexport function withinMaxClamp(min, value, max) {\n var v = within(min, value, max);\n return v > max ? max : v;\n}","export default function getFreshSideObject() {\n return {\n top: 0,\n right: 0,\n bottom: 0,\n left: 0\n };\n}","import getFreshSideObject from \"./getFreshSideObject.js\";\nexport default function mergePaddingObject(paddingObject) {\n return Object.assign({}, getFreshSideObject(), paddingObject);\n}","export default function expandToHashMap(value, keys) {\n return keys.reduce(function (hashMap, key) {\n hashMap[key] = value;\n return hashMap;\n }, {});\n}","import getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getLayoutRect from \"../dom-utils/getLayoutRect.js\";\nimport contains from \"../dom-utils/contains.js\";\nimport getOffsetParent from \"../dom-utils/getOffsetParent.js\";\nimport getMainAxisFromPlacement from \"../utils/getMainAxisFromPlacement.js\";\nimport { within } from \"../utils/within.js\";\nimport mergePaddingObject from \"../utils/mergePaddingObject.js\";\nimport expandToHashMap from \"../utils/expandToHashMap.js\";\nimport { left, right, basePlacements, top, bottom } from \"../enums.js\"; // eslint-disable-next-line import/no-unused-modules\n\nvar toPaddingObject = function toPaddingObject(padding, state) {\n padding = typeof padding === 'function' ? padding(Object.assign({}, state.rects, {\n placement: state.placement\n })) : padding;\n return mergePaddingObject(typeof padding !== 'number' ? padding : expandToHashMap(padding, basePlacements));\n};\n\nfunction arrow(_ref) {\n var _state$modifiersData$;\n\n var state = _ref.state,\n name = _ref.name,\n options = _ref.options;\n var arrowElement = state.elements.arrow;\n var popperOffsets = state.modifiersData.popperOffsets;\n var basePlacement = getBasePlacement(state.placement);\n var axis = getMainAxisFromPlacement(basePlacement);\n var isVertical = [left, right].indexOf(basePlacement) >= 0;\n var len = isVertical ? 'height' : 'width';\n\n if (!arrowElement || !popperOffsets) {\n return;\n }\n\n var paddingObject = toPaddingObject(options.padding, state);\n var arrowRect = getLayoutRect(arrowElement);\n var minProp = axis === 'y' ? top : left;\n var maxProp = axis === 'y' ? bottom : right;\n var endDiff = state.rects.reference[len] + state.rects.reference[axis] - popperOffsets[axis] - state.rects.popper[len];\n var startDiff = popperOffsets[axis] - state.rects.reference[axis];\n var arrowOffsetParent = getOffsetParent(arrowElement);\n var clientSize = arrowOffsetParent ? axis === 'y' ? arrowOffsetParent.clientHeight || 0 : arrowOffsetParent.clientWidth || 0 : 0;\n var centerToReference = endDiff / 2 - startDiff / 2; // Make sure the arrow doesn't overflow the popper if the center point is\n // outside of the popper bounds\n\n var min = paddingObject[minProp];\n var max = clientSize - arrowRect[len] - paddingObject[maxProp];\n var center = clientSize / 2 - arrowRect[len] / 2 + centerToReference;\n var offset = within(min, center, max); // Prevents breaking syntax highlighting...\n\n var axisProp = axis;\n state.modifiersData[name] = (_state$modifiersData$ = {}, _state$modifiersData$[axisProp] = offset, _state$modifiersData$.centerOffset = offset - center, _state$modifiersData$);\n}\n\nfunction effect(_ref2) {\n var state = _ref2.state,\n options = _ref2.options;\n var _options$element = options.element,\n arrowElement = _options$element === void 0 ? '[data-popper-arrow]' : _options$element;\n\n if (arrowElement == null) {\n return;\n } // CSS selector\n\n\n if (typeof arrowElement === 'string') {\n arrowElement = state.elements.popper.querySelector(arrowElement);\n\n if (!arrowElement) {\n return;\n }\n }\n\n if (!contains(state.elements.popper, arrowElement)) {\n return;\n }\n\n state.elements.arrow = arrowElement;\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'arrow',\n enabled: true,\n phase: 'main',\n fn: arrow,\n effect: effect,\n requires: ['popperOffsets'],\n requiresIfExists: ['preventOverflow']\n};","export default function getVariation(placement) {\n return placement.split('-')[1];\n}","import { top, left, right, bottom, end } from \"../enums.js\";\nimport getOffsetParent from \"../dom-utils/getOffsetParent.js\";\nimport getWindow from \"../dom-utils/getWindow.js\";\nimport getDocumentElement from \"../dom-utils/getDocumentElement.js\";\nimport getComputedStyle from \"../dom-utils/getComputedStyle.js\";\nimport getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getVariation from \"../utils/getVariation.js\";\nimport { round } from \"../utils/math.js\"; // eslint-disable-next-line import/no-unused-modules\n\nvar unsetSides = {\n top: 'auto',\n right: 'auto',\n bottom: 'auto',\n left: 'auto'\n}; // Round the offsets to the nearest suitable subpixel based on the DPR.\n// Zooming can change the DPR, but it seems to report a value that will\n// cleanly divide the values into the appropriate subpixels.\n\nfunction roundOffsetsByDPR(_ref, win) {\n var x = _ref.x,\n y = _ref.y;\n var dpr = win.devicePixelRatio || 1;\n return {\n x: round(x * dpr) / dpr || 0,\n y: round(y * dpr) / dpr || 0\n };\n}\n\nexport function mapToStyles(_ref2) {\n var _Object$assign2;\n\n var popper = _ref2.popper,\n popperRect = _ref2.popperRect,\n placement = _ref2.placement,\n variation = _ref2.variation,\n offsets = _ref2.offsets,\n position = _ref2.position,\n gpuAcceleration = _ref2.gpuAcceleration,\n adaptive = _ref2.adaptive,\n roundOffsets = _ref2.roundOffsets,\n isFixed = _ref2.isFixed;\n var _offsets$x = offsets.x,\n x = _offsets$x === void 0 ? 0 : _offsets$x,\n _offsets$y = offsets.y,\n y = _offsets$y === void 0 ? 0 : _offsets$y;\n\n var _ref3 = typeof roundOffsets === 'function' ? roundOffsets({\n x: x,\n y: y\n }) : {\n x: x,\n y: y\n };\n\n x = _ref3.x;\n y = _ref3.y;\n var hasX = offsets.hasOwnProperty('x');\n var hasY = offsets.hasOwnProperty('y');\n var sideX = left;\n var sideY = top;\n var win = window;\n\n if (adaptive) {\n var offsetParent = getOffsetParent(popper);\n var heightProp = 'clientHeight';\n var widthProp = 'clientWidth';\n\n if (offsetParent === getWindow(popper)) {\n offsetParent = getDocumentElement(popper);\n\n if (getComputedStyle(offsetParent).position !== 'static' && position === 'absolute') {\n heightProp = 'scrollHeight';\n widthProp = 'scrollWidth';\n }\n } // $FlowFixMe[incompatible-cast]: force type refinement, we compare offsetParent with window above, but Flow doesn't detect it\n\n\n offsetParent = offsetParent;\n\n if (placement === top || (placement === left || placement === right) && variation === end) {\n sideY = bottom;\n var offsetY = isFixed && offsetParent === win && win.visualViewport ? win.visualViewport.height : // $FlowFixMe[prop-missing]\n offsetParent[heightProp];\n y -= offsetY - popperRect.height;\n y *= gpuAcceleration ? 1 : -1;\n }\n\n if (placement === left || (placement === top || placement === bottom) && variation === end) {\n sideX = right;\n var offsetX = isFixed && offsetParent === win && win.visualViewport ? win.visualViewport.width : // $FlowFixMe[prop-missing]\n offsetParent[widthProp];\n x -= offsetX - popperRect.width;\n x *= gpuAcceleration ? 1 : -1;\n }\n }\n\n var commonStyles = Object.assign({\n position: position\n }, adaptive && unsetSides);\n\n var _ref4 = roundOffsets === true ? roundOffsetsByDPR({\n x: x,\n y: y\n }, getWindow(popper)) : {\n x: x,\n y: y\n };\n\n x = _ref4.x;\n y = _ref4.y;\n\n if (gpuAcceleration) {\n var _Object$assign;\n\n return Object.assign({}, commonStyles, (_Object$assign = {}, _Object$assign[sideY] = hasY ? '0' : '', _Object$assign[sideX] = hasX ? '0' : '', _Object$assign.transform = (win.devicePixelRatio || 1) <= 1 ? \"translate(\" + x + \"px, \" + y + \"px)\" : \"translate3d(\" + x + \"px, \" + y + \"px, 0)\", _Object$assign));\n }\n\n return Object.assign({}, commonStyles, (_Object$assign2 = {}, _Object$assign2[sideY] = hasY ? y + \"px\" : '', _Object$assign2[sideX] = hasX ? x + \"px\" : '', _Object$assign2.transform = '', _Object$assign2));\n}\n\nfunction computeStyles(_ref5) {\n var state = _ref5.state,\n options = _ref5.options;\n var _options$gpuAccelerat = options.gpuAcceleration,\n gpuAcceleration = _options$gpuAccelerat === void 0 ? true : _options$gpuAccelerat,\n _options$adaptive = options.adaptive,\n adaptive = _options$adaptive === void 0 ? true : _options$adaptive,\n _options$roundOffsets = options.roundOffsets,\n roundOffsets = _options$roundOffsets === void 0 ? true : _options$roundOffsets;\n var commonStyles = {\n placement: getBasePlacement(state.placement),\n variation: getVariation(state.placement),\n popper: state.elements.popper,\n popperRect: state.rects.popper,\n gpuAcceleration: gpuAcceleration,\n isFixed: state.options.strategy === 'fixed'\n };\n\n if (state.modifiersData.popperOffsets != null) {\n state.styles.popper = Object.assign({}, state.styles.popper, mapToStyles(Object.assign({}, commonStyles, {\n offsets: state.modifiersData.popperOffsets,\n position: state.options.strategy,\n adaptive: adaptive,\n roundOffsets: roundOffsets\n })));\n }\n\n if (state.modifiersData.arrow != null) {\n state.styles.arrow = Object.assign({}, state.styles.arrow, mapToStyles(Object.assign({}, commonStyles, {\n offsets: state.modifiersData.arrow,\n position: 'absolute',\n adaptive: false,\n roundOffsets: roundOffsets\n })));\n }\n\n state.attributes.popper = Object.assign({}, state.attributes.popper, {\n 'data-popper-placement': state.placement\n });\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'computeStyles',\n enabled: true,\n phase: 'beforeWrite',\n fn: computeStyles,\n data: {}\n};","import getWindow from \"../dom-utils/getWindow.js\"; // eslint-disable-next-line import/no-unused-modules\n\nvar passive = {\n passive: true\n};\n\nfunction effect(_ref) {\n var state = _ref.state,\n instance = _ref.instance,\n options = _ref.options;\n var _options$scroll = options.scroll,\n scroll = _options$scroll === void 0 ? true : _options$scroll,\n _options$resize = options.resize,\n resize = _options$resize === void 0 ? true : _options$resize;\n var window = getWindow(state.elements.popper);\n var scrollParents = [].concat(state.scrollParents.reference, state.scrollParents.popper);\n\n if (scroll) {\n scrollParents.forEach(function (scrollParent) {\n scrollParent.addEventListener('scroll', instance.update, passive);\n });\n }\n\n if (resize) {\n window.addEventListener('resize', instance.update, passive);\n }\n\n return function () {\n if (scroll) {\n scrollParents.forEach(function (scrollParent) {\n scrollParent.removeEventListener('scroll', instance.update, passive);\n });\n }\n\n if (resize) {\n window.removeEventListener('resize', instance.update, passive);\n }\n };\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'eventListeners',\n enabled: true,\n phase: 'write',\n fn: function fn() {},\n effect: effect,\n data: {}\n};","var hash = {\n left: 'right',\n right: 'left',\n bottom: 'top',\n top: 'bottom'\n};\nexport default function getOppositePlacement(placement) {\n return placement.replace(/left|right|bottom|top/g, function (matched) {\n return hash[matched];\n });\n}","var hash = {\n start: 'end',\n end: 'start'\n};\nexport default function getOppositeVariationPlacement(placement) {\n return placement.replace(/start|end/g, function (matched) {\n return hash[matched];\n });\n}","import getWindow from \"./getWindow.js\";\nexport default function getWindowScroll(node) {\n var win = getWindow(node);\n var scrollLeft = win.pageXOffset;\n var scrollTop = win.pageYOffset;\n return {\n scrollLeft: scrollLeft,\n scrollTop: scrollTop\n };\n}","import getBoundingClientRect from \"./getBoundingClientRect.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport getWindowScroll from \"./getWindowScroll.js\";\nexport default function getWindowScrollBarX(element) {\n // If has a CSS width greater than the viewport, then this will be\n // incorrect for RTL.\n // Popper 1 is broken in this case and never had a bug report so let's assume\n // it's not an issue. I don't think anyone ever specifies width on \n // anyway.\n // Browsers where the left scrollbar doesn't cause an issue report `0` for\n // this (e.g. Edge 2019, IE11, Safari)\n return getBoundingClientRect(getDocumentElement(element)).left + getWindowScroll(element).scrollLeft;\n}","import getWindow from \"./getWindow.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport getWindowScrollBarX from \"./getWindowScrollBarX.js\";\nimport isLayoutViewport from \"./isLayoutViewport.js\";\nexport default function getViewportRect(element, strategy) {\n var win = getWindow(element);\n var html = getDocumentElement(element);\n var visualViewport = win.visualViewport;\n var width = html.clientWidth;\n var height = html.clientHeight;\n var x = 0;\n var y = 0;\n\n if (visualViewport) {\n width = visualViewport.width;\n height = visualViewport.height;\n var layoutViewport = isLayoutViewport();\n\n if (layoutViewport || !layoutViewport && strategy === 'fixed') {\n x = visualViewport.offsetLeft;\n y = visualViewport.offsetTop;\n }\n }\n\n return {\n width: width,\n height: height,\n x: x + getWindowScrollBarX(element),\n y: y\n };\n}","import getDocumentElement from \"./getDocumentElement.js\";\nimport getComputedStyle from \"./getComputedStyle.js\";\nimport getWindowScrollBarX from \"./getWindowScrollBarX.js\";\nimport getWindowScroll from \"./getWindowScroll.js\";\nimport { max } from \"../utils/math.js\"; // Gets the entire size of the scrollable document area, even extending outside\n// of the `` and `` rect bounds if horizontally scrollable\n\nexport default function getDocumentRect(element) {\n var _element$ownerDocumen;\n\n var html = getDocumentElement(element);\n var winScroll = getWindowScroll(element);\n var body = (_element$ownerDocumen = element.ownerDocument) == null ? void 0 : _element$ownerDocumen.body;\n var width = max(html.scrollWidth, html.clientWidth, body ? body.scrollWidth : 0, body ? body.clientWidth : 0);\n var height = max(html.scrollHeight, html.clientHeight, body ? body.scrollHeight : 0, body ? body.clientHeight : 0);\n var x = -winScroll.scrollLeft + getWindowScrollBarX(element);\n var y = -winScroll.scrollTop;\n\n if (getComputedStyle(body || html).direction === 'rtl') {\n x += max(html.clientWidth, body ? body.clientWidth : 0) - width;\n }\n\n return {\n width: width,\n height: height,\n x: x,\n y: y\n };\n}","import getComputedStyle from \"./getComputedStyle.js\";\nexport default function isScrollParent(element) {\n // Firefox wants us to check `-x` and `-y` variations as well\n var _getComputedStyle = getComputedStyle(element),\n overflow = _getComputedStyle.overflow,\n overflowX = _getComputedStyle.overflowX,\n overflowY = _getComputedStyle.overflowY;\n\n return /auto|scroll|overlay|hidden/.test(overflow + overflowY + overflowX);\n}","import getParentNode from \"./getParentNode.js\";\nimport isScrollParent from \"./isScrollParent.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport { isHTMLElement } from \"./instanceOf.js\";\nexport default function getScrollParent(node) {\n if (['html', 'body', '#document'].indexOf(getNodeName(node)) >= 0) {\n // $FlowFixMe[incompatible-return]: assume body is always available\n return node.ownerDocument.body;\n }\n\n if (isHTMLElement(node) && isScrollParent(node)) {\n return node;\n }\n\n return getScrollParent(getParentNode(node));\n}","import getScrollParent from \"./getScrollParent.js\";\nimport getParentNode from \"./getParentNode.js\";\nimport getWindow from \"./getWindow.js\";\nimport isScrollParent from \"./isScrollParent.js\";\n/*\ngiven a DOM element, return the list of all scroll parents, up the list of ancesors\nuntil we get to the top window object. This list is what we attach scroll listeners\nto, because if any of these parent elements scroll, we'll need to re-calculate the\nreference element's position.\n*/\n\nexport default function listScrollParents(element, list) {\n var _element$ownerDocumen;\n\n if (list === void 0) {\n list = [];\n }\n\n var scrollParent = getScrollParent(element);\n var isBody = scrollParent === ((_element$ownerDocumen = element.ownerDocument) == null ? void 0 : _element$ownerDocumen.body);\n var win = getWindow(scrollParent);\n var target = isBody ? [win].concat(win.visualViewport || [], isScrollParent(scrollParent) ? scrollParent : []) : scrollParent;\n var updatedList = list.concat(target);\n return isBody ? updatedList : // $FlowFixMe[incompatible-call]: isBody tells us target will be an HTMLElement here\n updatedList.concat(listScrollParents(getParentNode(target)));\n}","export default function rectToClientRect(rect) {\n return Object.assign({}, rect, {\n left: rect.x,\n top: rect.y,\n right: rect.x + rect.width,\n bottom: rect.y + rect.height\n });\n}","import { viewport } from \"../enums.js\";\nimport getViewportRect from \"./getViewportRect.js\";\nimport getDocumentRect from \"./getDocumentRect.js\";\nimport listScrollParents from \"./listScrollParents.js\";\nimport getOffsetParent from \"./getOffsetParent.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport getComputedStyle from \"./getComputedStyle.js\";\nimport { isElement, isHTMLElement } from \"./instanceOf.js\";\nimport getBoundingClientRect from \"./getBoundingClientRect.js\";\nimport getParentNode from \"./getParentNode.js\";\nimport contains from \"./contains.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport rectToClientRect from \"../utils/rectToClientRect.js\";\nimport { max, min } from \"../utils/math.js\";\n\nfunction getInnerBoundingClientRect(element, strategy) {\n var rect = getBoundingClientRect(element, false, strategy === 'fixed');\n rect.top = rect.top + element.clientTop;\n rect.left = rect.left + element.clientLeft;\n rect.bottom = rect.top + element.clientHeight;\n rect.right = rect.left + element.clientWidth;\n rect.width = element.clientWidth;\n rect.height = element.clientHeight;\n rect.x = rect.left;\n rect.y = rect.top;\n return rect;\n}\n\nfunction getClientRectFromMixedType(element, clippingParent, strategy) {\n return clippingParent === viewport ? rectToClientRect(getViewportRect(element, strategy)) : isElement(clippingParent) ? getInnerBoundingClientRect(clippingParent, strategy) : rectToClientRect(getDocumentRect(getDocumentElement(element)));\n} // A \"clipping parent\" is an overflowable container with the characteristic of\n// clipping (or hiding) overflowing elements with a position different from\n// `initial`\n\n\nfunction getClippingParents(element) {\n var clippingParents = listScrollParents(getParentNode(element));\n var canEscapeClipping = ['absolute', 'fixed'].indexOf(getComputedStyle(element).position) >= 0;\n var clipperElement = canEscapeClipping && isHTMLElement(element) ? getOffsetParent(element) : element;\n\n if (!isElement(clipperElement)) {\n return [];\n } // $FlowFixMe[incompatible-return]: https://github.com/facebook/flow/issues/1414\n\n\n return clippingParents.filter(function (clippingParent) {\n return isElement(clippingParent) && contains(clippingParent, clipperElement) && getNodeName(clippingParent) !== 'body';\n });\n} // Gets the maximum area that the element is visible in due to any number of\n// clipping parents\n\n\nexport default function getClippingRect(element, boundary, rootBoundary, strategy) {\n var mainClippingParents = boundary === 'clippingParents' ? getClippingParents(element) : [].concat(boundary);\n var clippingParents = [].concat(mainClippingParents, [rootBoundary]);\n var firstClippingParent = clippingParents[0];\n var clippingRect = clippingParents.reduce(function (accRect, clippingParent) {\n var rect = getClientRectFromMixedType(element, clippingParent, strategy);\n accRect.top = max(rect.top, accRect.top);\n accRect.right = min(rect.right, accRect.right);\n accRect.bottom = min(rect.bottom, accRect.bottom);\n accRect.left = max(rect.left, accRect.left);\n return accRect;\n }, getClientRectFromMixedType(element, firstClippingParent, strategy));\n clippingRect.width = clippingRect.right - clippingRect.left;\n clippingRect.height = clippingRect.bottom - clippingRect.top;\n clippingRect.x = clippingRect.left;\n clippingRect.y = clippingRect.top;\n return clippingRect;\n}","import getBasePlacement from \"./getBasePlacement.js\";\nimport getVariation from \"./getVariation.js\";\nimport getMainAxisFromPlacement from \"./getMainAxisFromPlacement.js\";\nimport { top, right, bottom, left, start, end } from \"../enums.js\";\nexport default function computeOffsets(_ref) {\n var reference = _ref.reference,\n element = _ref.element,\n placement = _ref.placement;\n var basePlacement = placement ? getBasePlacement(placement) : null;\n var variation = placement ? getVariation(placement) : null;\n var commonX = reference.x + reference.width / 2 - element.width / 2;\n var commonY = reference.y + reference.height / 2 - element.height / 2;\n var offsets;\n\n switch (basePlacement) {\n case top:\n offsets = {\n x: commonX,\n y: reference.y - element.height\n };\n break;\n\n case bottom:\n offsets = {\n x: commonX,\n y: reference.y + reference.height\n };\n break;\n\n case right:\n offsets = {\n x: reference.x + reference.width,\n y: commonY\n };\n break;\n\n case left:\n offsets = {\n x: reference.x - element.width,\n y: commonY\n };\n break;\n\n default:\n offsets = {\n x: reference.x,\n y: reference.y\n };\n }\n\n var mainAxis = basePlacement ? getMainAxisFromPlacement(basePlacement) : null;\n\n if (mainAxis != null) {\n var len = mainAxis === 'y' ? 'height' : 'width';\n\n switch (variation) {\n case start:\n offsets[mainAxis] = offsets[mainAxis] - (reference[len] / 2 - element[len] / 2);\n break;\n\n case end:\n offsets[mainAxis] = offsets[mainAxis] + (reference[len] / 2 - element[len] / 2);\n break;\n\n default:\n }\n }\n\n return offsets;\n}","import getClippingRect from \"../dom-utils/getClippingRect.js\";\nimport getDocumentElement from \"../dom-utils/getDocumentElement.js\";\nimport getBoundingClientRect from \"../dom-utils/getBoundingClientRect.js\";\nimport computeOffsets from \"./computeOffsets.js\";\nimport rectToClientRect from \"./rectToClientRect.js\";\nimport { clippingParents, reference, popper, bottom, top, right, basePlacements, viewport } from \"../enums.js\";\nimport { isElement } from \"../dom-utils/instanceOf.js\";\nimport mergePaddingObject from \"./mergePaddingObject.js\";\nimport expandToHashMap from \"./expandToHashMap.js\"; // eslint-disable-next-line import/no-unused-modules\n\nexport default function detectOverflow(state, options) {\n if (options === void 0) {\n options = {};\n }\n\n var _options = options,\n _options$placement = _options.placement,\n placement = _options$placement === void 0 ? state.placement : _options$placement,\n _options$strategy = _options.strategy,\n strategy = _options$strategy === void 0 ? state.strategy : _options$strategy,\n _options$boundary = _options.boundary,\n boundary = _options$boundary === void 0 ? clippingParents : _options$boundary,\n _options$rootBoundary = _options.rootBoundary,\n rootBoundary = _options$rootBoundary === void 0 ? viewport : _options$rootBoundary,\n _options$elementConte = _options.elementContext,\n elementContext = _options$elementConte === void 0 ? popper : _options$elementConte,\n _options$altBoundary = _options.altBoundary,\n altBoundary = _options$altBoundary === void 0 ? false : _options$altBoundary,\n _options$padding = _options.padding,\n padding = _options$padding === void 0 ? 0 : _options$padding;\n var paddingObject = mergePaddingObject(typeof padding !== 'number' ? padding : expandToHashMap(padding, basePlacements));\n var altContext = elementContext === popper ? reference : popper;\n var popperRect = state.rects.popper;\n var element = state.elements[altBoundary ? altContext : elementContext];\n var clippingClientRect = getClippingRect(isElement(element) ? element : element.contextElement || getDocumentElement(state.elements.popper), boundary, rootBoundary, strategy);\n var referenceClientRect = getBoundingClientRect(state.elements.reference);\n var popperOffsets = computeOffsets({\n reference: referenceClientRect,\n element: popperRect,\n strategy: 'absolute',\n placement: placement\n });\n var popperClientRect = rectToClientRect(Object.assign({}, popperRect, popperOffsets));\n var elementClientRect = elementContext === popper ? popperClientRect : referenceClientRect; // positive = overflowing the clipping rect\n // 0 or negative = within the clipping rect\n\n var overflowOffsets = {\n top: clippingClientRect.top - elementClientRect.top + paddingObject.top,\n bottom: elementClientRect.bottom - clippingClientRect.bottom + paddingObject.bottom,\n left: clippingClientRect.left - elementClientRect.left + paddingObject.left,\n right: elementClientRect.right - clippingClientRect.right + paddingObject.right\n };\n var offsetData = state.modifiersData.offset; // Offsets can be applied only to the popper element\n\n if (elementContext === popper && offsetData) {\n var offset = offsetData[placement];\n Object.keys(overflowOffsets).forEach(function (key) {\n var multiply = [right, bottom].indexOf(key) >= 0 ? 1 : -1;\n var axis = [top, bottom].indexOf(key) >= 0 ? 'y' : 'x';\n overflowOffsets[key] += offset[axis] * multiply;\n });\n }\n\n return overflowOffsets;\n}","import getVariation from \"./getVariation.js\";\nimport { variationPlacements, basePlacements, placements as allPlacements } from \"../enums.js\";\nimport detectOverflow from \"./detectOverflow.js\";\nimport getBasePlacement from \"./getBasePlacement.js\";\nexport default function computeAutoPlacement(state, options) {\n if (options === void 0) {\n options = {};\n }\n\n var _options = options,\n placement = _options.placement,\n boundary = _options.boundary,\n rootBoundary = _options.rootBoundary,\n padding = _options.padding,\n flipVariations = _options.flipVariations,\n _options$allowedAutoP = _options.allowedAutoPlacements,\n allowedAutoPlacements = _options$allowedAutoP === void 0 ? allPlacements : _options$allowedAutoP;\n var variation = getVariation(placement);\n var placements = variation ? flipVariations ? variationPlacements : variationPlacements.filter(function (placement) {\n return getVariation(placement) === variation;\n }) : basePlacements;\n var allowedPlacements = placements.filter(function (placement) {\n return allowedAutoPlacements.indexOf(placement) >= 0;\n });\n\n if (allowedPlacements.length === 0) {\n allowedPlacements = placements;\n } // $FlowFixMe[incompatible-type]: Flow seems to have problems with two array unions...\n\n\n var overflows = allowedPlacements.reduce(function (acc, placement) {\n acc[placement] = detectOverflow(state, {\n placement: placement,\n boundary: boundary,\n rootBoundary: rootBoundary,\n padding: padding\n })[getBasePlacement(placement)];\n return acc;\n }, {});\n return Object.keys(overflows).sort(function (a, b) {\n return overflows[a] - overflows[b];\n });\n}","import getOppositePlacement from \"../utils/getOppositePlacement.js\";\nimport getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getOppositeVariationPlacement from \"../utils/getOppositeVariationPlacement.js\";\nimport detectOverflow from \"../utils/detectOverflow.js\";\nimport computeAutoPlacement from \"../utils/computeAutoPlacement.js\";\nimport { bottom, top, start, right, left, auto } from \"../enums.js\";\nimport getVariation from \"../utils/getVariation.js\"; // eslint-disable-next-line import/no-unused-modules\n\nfunction getExpandedFallbackPlacements(placement) {\n if (getBasePlacement(placement) === auto) {\n return [];\n }\n\n var oppositePlacement = getOppositePlacement(placement);\n return [getOppositeVariationPlacement(placement), oppositePlacement, getOppositeVariationPlacement(oppositePlacement)];\n}\n\nfunction flip(_ref) {\n var state = _ref.state,\n options = _ref.options,\n name = _ref.name;\n\n if (state.modifiersData[name]._skip) {\n return;\n }\n\n var _options$mainAxis = options.mainAxis,\n checkMainAxis = _options$mainAxis === void 0 ? true : _options$mainAxis,\n _options$altAxis = options.altAxis,\n checkAltAxis = _options$altAxis === void 0 ? true : _options$altAxis,\n specifiedFallbackPlacements = options.fallbackPlacements,\n padding = options.padding,\n boundary = options.boundary,\n rootBoundary = options.rootBoundary,\n altBoundary = options.altBoundary,\n _options$flipVariatio = options.flipVariations,\n flipVariations = _options$flipVariatio === void 0 ? true : _options$flipVariatio,\n allowedAutoPlacements = options.allowedAutoPlacements;\n var preferredPlacement = state.options.placement;\n var basePlacement = getBasePlacement(preferredPlacement);\n var isBasePlacement = basePlacement === preferredPlacement;\n var fallbackPlacements = specifiedFallbackPlacements || (isBasePlacement || !flipVariations ? [getOppositePlacement(preferredPlacement)] : getExpandedFallbackPlacements(preferredPlacement));\n var placements = [preferredPlacement].concat(fallbackPlacements).reduce(function (acc, placement) {\n return acc.concat(getBasePlacement(placement) === auto ? computeAutoPlacement(state, {\n placement: placement,\n boundary: boundary,\n rootBoundary: rootBoundary,\n padding: padding,\n flipVariations: flipVariations,\n allowedAutoPlacements: allowedAutoPlacements\n }) : placement);\n }, []);\n var referenceRect = state.rects.reference;\n var popperRect = state.rects.popper;\n var checksMap = new Map();\n var makeFallbackChecks = true;\n var firstFittingPlacement = placements[0];\n\n for (var i = 0; i < placements.length; i++) {\n var placement = placements[i];\n\n var _basePlacement = getBasePlacement(placement);\n\n var isStartVariation = getVariation(placement) === start;\n var isVertical = [top, bottom].indexOf(_basePlacement) >= 0;\n var len = isVertical ? 'width' : 'height';\n var overflow = detectOverflow(state, {\n placement: placement,\n boundary: boundary,\n rootBoundary: rootBoundary,\n altBoundary: altBoundary,\n padding: padding\n });\n var mainVariationSide = isVertical ? isStartVariation ? right : left : isStartVariation ? bottom : top;\n\n if (referenceRect[len] > popperRect[len]) {\n mainVariationSide = getOppositePlacement(mainVariationSide);\n }\n\n var altVariationSide = getOppositePlacement(mainVariationSide);\n var checks = [];\n\n if (checkMainAxis) {\n checks.push(overflow[_basePlacement] <= 0);\n }\n\n if (checkAltAxis) {\n checks.push(overflow[mainVariationSide] <= 0, overflow[altVariationSide] <= 0);\n }\n\n if (checks.every(function (check) {\n return check;\n })) {\n firstFittingPlacement = placement;\n makeFallbackChecks = false;\n break;\n }\n\n checksMap.set(placement, checks);\n }\n\n if (makeFallbackChecks) {\n // `2` may be desired in some cases – research later\n var numberOfChecks = flipVariations ? 3 : 1;\n\n var _loop = function _loop(_i) {\n var fittingPlacement = placements.find(function (placement) {\n var checks = checksMap.get(placement);\n\n if (checks) {\n return checks.slice(0, _i).every(function (check) {\n return check;\n });\n }\n });\n\n if (fittingPlacement) {\n firstFittingPlacement = fittingPlacement;\n return \"break\";\n }\n };\n\n for (var _i = numberOfChecks; _i > 0; _i--) {\n var _ret = _loop(_i);\n\n if (_ret === \"break\") break;\n }\n }\n\n if (state.placement !== firstFittingPlacement) {\n state.modifiersData[name]._skip = true;\n state.placement = firstFittingPlacement;\n state.reset = true;\n }\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'flip',\n enabled: true,\n phase: 'main',\n fn: flip,\n requiresIfExists: ['offset'],\n data: {\n _skip: false\n }\n};","import { top, bottom, left, right } from \"../enums.js\";\nimport detectOverflow from \"../utils/detectOverflow.js\";\n\nfunction getSideOffsets(overflow, rect, preventedOffsets) {\n if (preventedOffsets === void 0) {\n preventedOffsets = {\n x: 0,\n y: 0\n };\n }\n\n return {\n top: overflow.top - rect.height - preventedOffsets.y,\n right: overflow.right - rect.width + preventedOffsets.x,\n bottom: overflow.bottom - rect.height + preventedOffsets.y,\n left: overflow.left - rect.width - preventedOffsets.x\n };\n}\n\nfunction isAnySideFullyClipped(overflow) {\n return [top, right, bottom, left].some(function (side) {\n return overflow[side] >= 0;\n });\n}\n\nfunction hide(_ref) {\n var state = _ref.state,\n name = _ref.name;\n var referenceRect = state.rects.reference;\n var popperRect = state.rects.popper;\n var preventedOffsets = state.modifiersData.preventOverflow;\n var referenceOverflow = detectOverflow(state, {\n elementContext: 'reference'\n });\n var popperAltOverflow = detectOverflow(state, {\n altBoundary: true\n });\n var referenceClippingOffsets = getSideOffsets(referenceOverflow, referenceRect);\n var popperEscapeOffsets = getSideOffsets(popperAltOverflow, popperRect, preventedOffsets);\n var isReferenceHidden = isAnySideFullyClipped(referenceClippingOffsets);\n var hasPopperEscaped = isAnySideFullyClipped(popperEscapeOffsets);\n state.modifiersData[name] = {\n referenceClippingOffsets: referenceClippingOffsets,\n popperEscapeOffsets: popperEscapeOffsets,\n isReferenceHidden: isReferenceHidden,\n hasPopperEscaped: hasPopperEscaped\n };\n state.attributes.popper = Object.assign({}, state.attributes.popper, {\n 'data-popper-reference-hidden': isReferenceHidden,\n 'data-popper-escaped': hasPopperEscaped\n });\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'hide',\n enabled: true,\n phase: 'main',\n requiresIfExists: ['preventOverflow'],\n fn: hide\n};","import getBasePlacement from \"../utils/getBasePlacement.js\";\nimport { top, left, right, placements } from \"../enums.js\"; // eslint-disable-next-line import/no-unused-modules\n\nexport function distanceAndSkiddingToXY(placement, rects, offset) {\n var basePlacement = getBasePlacement(placement);\n var invertDistance = [left, top].indexOf(basePlacement) >= 0 ? -1 : 1;\n\n var _ref = typeof offset === 'function' ? offset(Object.assign({}, rects, {\n placement: placement\n })) : offset,\n skidding = _ref[0],\n distance = _ref[1];\n\n skidding = skidding || 0;\n distance = (distance || 0) * invertDistance;\n return [left, right].indexOf(basePlacement) >= 0 ? {\n x: distance,\n y: skidding\n } : {\n x: skidding,\n y: distance\n };\n}\n\nfunction offset(_ref2) {\n var state = _ref2.state,\n options = _ref2.options,\n name = _ref2.name;\n var _options$offset = options.offset,\n offset = _options$offset === void 0 ? [0, 0] : _options$offset;\n var data = placements.reduce(function (acc, placement) {\n acc[placement] = distanceAndSkiddingToXY(placement, state.rects, offset);\n return acc;\n }, {});\n var _data$state$placement = data[state.placement],\n x = _data$state$placement.x,\n y = _data$state$placement.y;\n\n if (state.modifiersData.popperOffsets != null) {\n state.modifiersData.popperOffsets.x += x;\n state.modifiersData.popperOffsets.y += y;\n }\n\n state.modifiersData[name] = data;\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'offset',\n enabled: true,\n phase: 'main',\n requires: ['popperOffsets'],\n fn: offset\n};","import computeOffsets from \"../utils/computeOffsets.js\";\n\nfunction popperOffsets(_ref) {\n var state = _ref.state,\n name = _ref.name;\n // Offsets are the actual position the popper needs to have to be\n // properly positioned near its reference element\n // This is the most basic placement, and will be adjusted by\n // the modifiers in the next step\n state.modifiersData[name] = computeOffsets({\n reference: state.rects.reference,\n element: state.rects.popper,\n strategy: 'absolute',\n placement: state.placement\n });\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'popperOffsets',\n enabled: true,\n phase: 'read',\n fn: popperOffsets,\n data: {}\n};","export default function getAltAxis(axis) {\n return axis === 'x' ? 'y' : 'x';\n}","import { top, left, right, bottom, start } from \"../enums.js\";\nimport getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getMainAxisFromPlacement from \"../utils/getMainAxisFromPlacement.js\";\nimport getAltAxis from \"../utils/getAltAxis.js\";\nimport { within, withinMaxClamp } from \"../utils/within.js\";\nimport getLayoutRect from \"../dom-utils/getLayoutRect.js\";\nimport getOffsetParent from \"../dom-utils/getOffsetParent.js\";\nimport detectOverflow from \"../utils/detectOverflow.js\";\nimport getVariation from \"../utils/getVariation.js\";\nimport getFreshSideObject from \"../utils/getFreshSideObject.js\";\nimport { min as mathMin, max as mathMax } from \"../utils/math.js\";\n\nfunction preventOverflow(_ref) {\n var state = _ref.state,\n options = _ref.options,\n name = _ref.name;\n var _options$mainAxis = options.mainAxis,\n checkMainAxis = _options$mainAxis === void 0 ? true : _options$mainAxis,\n _options$altAxis = options.altAxis,\n checkAltAxis = _options$altAxis === void 0 ? false : _options$altAxis,\n boundary = options.boundary,\n rootBoundary = options.rootBoundary,\n altBoundary = options.altBoundary,\n padding = options.padding,\n _options$tether = options.tether,\n tether = _options$tether === void 0 ? true : _options$tether,\n _options$tetherOffset = options.tetherOffset,\n tetherOffset = _options$tetherOffset === void 0 ? 0 : _options$tetherOffset;\n var overflow = detectOverflow(state, {\n boundary: boundary,\n rootBoundary: rootBoundary,\n padding: padding,\n altBoundary: altBoundary\n });\n var basePlacement = getBasePlacement(state.placement);\n var variation = getVariation(state.placement);\n var isBasePlacement = !variation;\n var mainAxis = getMainAxisFromPlacement(basePlacement);\n var altAxis = getAltAxis(mainAxis);\n var popperOffsets = state.modifiersData.popperOffsets;\n var referenceRect = state.rects.reference;\n var popperRect = state.rects.popper;\n var tetherOffsetValue = typeof tetherOffset === 'function' ? tetherOffset(Object.assign({}, state.rects, {\n placement: state.placement\n })) : tetherOffset;\n var normalizedTetherOffsetValue = typeof tetherOffsetValue === 'number' ? {\n mainAxis: tetherOffsetValue,\n altAxis: tetherOffsetValue\n } : Object.assign({\n mainAxis: 0,\n altAxis: 0\n }, tetherOffsetValue);\n var offsetModifierState = state.modifiersData.offset ? state.modifiersData.offset[state.placement] : null;\n var data = {\n x: 0,\n y: 0\n };\n\n if (!popperOffsets) {\n return;\n }\n\n if (checkMainAxis) {\n var _offsetModifierState$;\n\n var mainSide = mainAxis === 'y' ? top : left;\n var altSide = mainAxis === 'y' ? bottom : right;\n var len = mainAxis === 'y' ? 'height' : 'width';\n var offset = popperOffsets[mainAxis];\n var min = offset + overflow[mainSide];\n var max = offset - overflow[altSide];\n var additive = tether ? -popperRect[len] / 2 : 0;\n var minLen = variation === start ? referenceRect[len] : popperRect[len];\n var maxLen = variation === start ? -popperRect[len] : -referenceRect[len]; // We need to include the arrow in the calculation so the arrow doesn't go\n // outside the reference bounds\n\n var arrowElement = state.elements.arrow;\n var arrowRect = tether && arrowElement ? getLayoutRect(arrowElement) : {\n width: 0,\n height: 0\n };\n var arrowPaddingObject = state.modifiersData['arrow#persistent'] ? state.modifiersData['arrow#persistent'].padding : getFreshSideObject();\n var arrowPaddingMin = arrowPaddingObject[mainSide];\n var arrowPaddingMax = arrowPaddingObject[altSide]; // If the reference length is smaller than the arrow length, we don't want\n // to include its full size in the calculation. If the reference is small\n // and near the edge of a boundary, the popper can overflow even if the\n // reference is not overflowing as well (e.g. virtual elements with no\n // width or height)\n\n var arrowLen = within(0, referenceRect[len], arrowRect[len]);\n var minOffset = isBasePlacement ? referenceRect[len] / 2 - additive - arrowLen - arrowPaddingMin - normalizedTetherOffsetValue.mainAxis : minLen - arrowLen - arrowPaddingMin - normalizedTetherOffsetValue.mainAxis;\n var maxOffset = isBasePlacement ? -referenceRect[len] / 2 + additive + arrowLen + arrowPaddingMax + normalizedTetherOffsetValue.mainAxis : maxLen + arrowLen + arrowPaddingMax + normalizedTetherOffsetValue.mainAxis;\n var arrowOffsetParent = state.elements.arrow && getOffsetParent(state.elements.arrow);\n var clientOffset = arrowOffsetParent ? mainAxis === 'y' ? arrowOffsetParent.clientTop || 0 : arrowOffsetParent.clientLeft || 0 : 0;\n var offsetModifierValue = (_offsetModifierState$ = offsetModifierState == null ? void 0 : offsetModifierState[mainAxis]) != null ? _offsetModifierState$ : 0;\n var tetherMin = offset + minOffset - offsetModifierValue - clientOffset;\n var tetherMax = offset + maxOffset - offsetModifierValue;\n var preventedOffset = within(tether ? mathMin(min, tetherMin) : min, offset, tether ? mathMax(max, tetherMax) : max);\n popperOffsets[mainAxis] = preventedOffset;\n data[mainAxis] = preventedOffset - offset;\n }\n\n if (checkAltAxis) {\n var _offsetModifierState$2;\n\n var _mainSide = mainAxis === 'x' ? top : left;\n\n var _altSide = mainAxis === 'x' ? bottom : right;\n\n var _offset = popperOffsets[altAxis];\n\n var _len = altAxis === 'y' ? 'height' : 'width';\n\n var _min = _offset + overflow[_mainSide];\n\n var _max = _offset - overflow[_altSide];\n\n var isOriginSide = [top, left].indexOf(basePlacement) !== -1;\n\n var _offsetModifierValue = (_offsetModifierState$2 = offsetModifierState == null ? void 0 : offsetModifierState[altAxis]) != null ? _offsetModifierState$2 : 0;\n\n var _tetherMin = isOriginSide ? _min : _offset - referenceRect[_len] - popperRect[_len] - _offsetModifierValue + normalizedTetherOffsetValue.altAxis;\n\n var _tetherMax = isOriginSide ? _offset + referenceRect[_len] + popperRect[_len] - _offsetModifierValue - normalizedTetherOffsetValue.altAxis : _max;\n\n var _preventedOffset = tether && isOriginSide ? withinMaxClamp(_tetherMin, _offset, _tetherMax) : within(tether ? _tetherMin : _min, _offset, tether ? _tetherMax : _max);\n\n popperOffsets[altAxis] = _preventedOffset;\n data[altAxis] = _preventedOffset - _offset;\n }\n\n state.modifiersData[name] = data;\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'preventOverflow',\n enabled: true,\n phase: 'main',\n fn: preventOverflow,\n requiresIfExists: ['offset']\n};","export default function getHTMLElementScroll(element) {\n return {\n scrollLeft: element.scrollLeft,\n scrollTop: element.scrollTop\n };\n}","import getWindowScroll from \"./getWindowScroll.js\";\nimport getWindow from \"./getWindow.js\";\nimport { isHTMLElement } from \"./instanceOf.js\";\nimport getHTMLElementScroll from \"./getHTMLElementScroll.js\";\nexport default function getNodeScroll(node) {\n if (node === getWindow(node) || !isHTMLElement(node)) {\n return getWindowScroll(node);\n } else {\n return getHTMLElementScroll(node);\n }\n}","import getBoundingClientRect from \"./getBoundingClientRect.js\";\nimport getNodeScroll from \"./getNodeScroll.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport { isHTMLElement } from \"./instanceOf.js\";\nimport getWindowScrollBarX from \"./getWindowScrollBarX.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport isScrollParent from \"./isScrollParent.js\";\nimport { round } from \"../utils/math.js\";\n\nfunction isElementScaled(element) {\n var rect = element.getBoundingClientRect();\n var scaleX = round(rect.width) / element.offsetWidth || 1;\n var scaleY = round(rect.height) / element.offsetHeight || 1;\n return scaleX !== 1 || scaleY !== 1;\n} // Returns the composite rect of an element relative to its offsetParent.\n// Composite means it takes into account transforms as well as layout.\n\n\nexport default function getCompositeRect(elementOrVirtualElement, offsetParent, isFixed) {\n if (isFixed === void 0) {\n isFixed = false;\n }\n\n var isOffsetParentAnElement = isHTMLElement(offsetParent);\n var offsetParentIsScaled = isHTMLElement(offsetParent) && isElementScaled(offsetParent);\n var documentElement = getDocumentElement(offsetParent);\n var rect = getBoundingClientRect(elementOrVirtualElement, offsetParentIsScaled, isFixed);\n var scroll = {\n scrollLeft: 0,\n scrollTop: 0\n };\n var offsets = {\n x: 0,\n y: 0\n };\n\n if (isOffsetParentAnElement || !isOffsetParentAnElement && !isFixed) {\n if (getNodeName(offsetParent) !== 'body' || // https://github.com/popperjs/popper-core/issues/1078\n isScrollParent(documentElement)) {\n scroll = getNodeScroll(offsetParent);\n }\n\n if (isHTMLElement(offsetParent)) {\n offsets = getBoundingClientRect(offsetParent, true);\n offsets.x += offsetParent.clientLeft;\n offsets.y += offsetParent.clientTop;\n } else if (documentElement) {\n offsets.x = getWindowScrollBarX(documentElement);\n }\n }\n\n return {\n x: rect.left + scroll.scrollLeft - offsets.x,\n y: rect.top + scroll.scrollTop - offsets.y,\n width: rect.width,\n height: rect.height\n };\n}","import { modifierPhases } from \"../enums.js\"; // source: https://stackoverflow.com/questions/49875255\n\nfunction order(modifiers) {\n var map = new Map();\n var visited = new Set();\n var result = [];\n modifiers.forEach(function (modifier) {\n map.set(modifier.name, modifier);\n }); // On visiting object, check for its dependencies and visit them recursively\n\n function sort(modifier) {\n visited.add(modifier.name);\n var requires = [].concat(modifier.requires || [], modifier.requiresIfExists || []);\n requires.forEach(function (dep) {\n if (!visited.has(dep)) {\n var depModifier = map.get(dep);\n\n if (depModifier) {\n sort(depModifier);\n }\n }\n });\n result.push(modifier);\n }\n\n modifiers.forEach(function (modifier) {\n if (!visited.has(modifier.name)) {\n // check for visited object\n sort(modifier);\n }\n });\n return result;\n}\n\nexport default function orderModifiers(modifiers) {\n // order based on dependencies\n var orderedModifiers = order(modifiers); // order based on phase\n\n return modifierPhases.reduce(function (acc, phase) {\n return acc.concat(orderedModifiers.filter(function (modifier) {\n return modifier.phase === phase;\n }));\n }, []);\n}","export default function debounce(fn) {\n var pending;\n return function () {\n if (!pending) {\n pending = new Promise(function (resolve) {\n Promise.resolve().then(function () {\n pending = undefined;\n resolve(fn());\n });\n });\n }\n\n return pending;\n };\n}","export default function mergeByName(modifiers) {\n var merged = modifiers.reduce(function (merged, current) {\n var existing = merged[current.name];\n merged[current.name] = existing ? Object.assign({}, existing, current, {\n options: Object.assign({}, existing.options, current.options),\n data: Object.assign({}, existing.data, current.data)\n }) : current;\n return merged;\n }, {}); // IE11 does not support Object.values\n\n return Object.keys(merged).map(function (key) {\n return merged[key];\n });\n}","import getCompositeRect from \"./dom-utils/getCompositeRect.js\";\nimport getLayoutRect from \"./dom-utils/getLayoutRect.js\";\nimport listScrollParents from \"./dom-utils/listScrollParents.js\";\nimport getOffsetParent from \"./dom-utils/getOffsetParent.js\";\nimport orderModifiers from \"./utils/orderModifiers.js\";\nimport debounce from \"./utils/debounce.js\";\nimport mergeByName from \"./utils/mergeByName.js\";\nimport detectOverflow from \"./utils/detectOverflow.js\";\nimport { isElement } from \"./dom-utils/instanceOf.js\";\nvar DEFAULT_OPTIONS = {\n placement: 'bottom',\n modifiers: [],\n strategy: 'absolute'\n};\n\nfunction areValidElements() {\n for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {\n args[_key] = arguments[_key];\n }\n\n return !args.some(function (element) {\n return !(element && typeof element.getBoundingClientRect === 'function');\n });\n}\n\nexport function popperGenerator(generatorOptions) {\n if (generatorOptions === void 0) {\n generatorOptions = {};\n }\n\n var _generatorOptions = generatorOptions,\n _generatorOptions$def = _generatorOptions.defaultModifiers,\n defaultModifiers = _generatorOptions$def === void 0 ? [] : _generatorOptions$def,\n _generatorOptions$def2 = _generatorOptions.defaultOptions,\n defaultOptions = _generatorOptions$def2 === void 0 ? DEFAULT_OPTIONS : _generatorOptions$def2;\n return function createPopper(reference, popper, options) {\n if (options === void 0) {\n options = defaultOptions;\n }\n\n var state = {\n placement: 'bottom',\n orderedModifiers: [],\n options: Object.assign({}, DEFAULT_OPTIONS, defaultOptions),\n modifiersData: {},\n elements: {\n reference: reference,\n popper: popper\n },\n attributes: {},\n styles: {}\n };\n var effectCleanupFns = [];\n var isDestroyed = false;\n var instance = {\n state: state,\n setOptions: function setOptions(setOptionsAction) {\n var options = typeof setOptionsAction === 'function' ? setOptionsAction(state.options) : setOptionsAction;\n cleanupModifierEffects();\n state.options = Object.assign({}, defaultOptions, state.options, options);\n state.scrollParents = {\n reference: isElement(reference) ? listScrollParents(reference) : reference.contextElement ? listScrollParents(reference.contextElement) : [],\n popper: listScrollParents(popper)\n }; // Orders the modifiers based on their dependencies and `phase`\n // properties\n\n var orderedModifiers = orderModifiers(mergeByName([].concat(defaultModifiers, state.options.modifiers))); // Strip out disabled modifiers\n\n state.orderedModifiers = orderedModifiers.filter(function (m) {\n return m.enabled;\n });\n runModifierEffects();\n return instance.update();\n },\n // Sync update – it will always be executed, even if not necessary. This\n // is useful for low frequency updates where sync behavior simplifies the\n // logic.\n // For high frequency updates (e.g. `resize` and `scroll` events), always\n // prefer the async Popper#update method\n forceUpdate: function forceUpdate() {\n if (isDestroyed) {\n return;\n }\n\n var _state$elements = state.elements,\n reference = _state$elements.reference,\n popper = _state$elements.popper; // Don't proceed if `reference` or `popper` are not valid elements\n // anymore\n\n if (!areValidElements(reference, popper)) {\n return;\n } // Store the reference and popper rects to be read by modifiers\n\n\n state.rects = {\n reference: getCompositeRect(reference, getOffsetParent(popper), state.options.strategy === 'fixed'),\n popper: getLayoutRect(popper)\n }; // Modifiers have the ability to reset the current update cycle. The\n // most common use case for this is the `flip` modifier changing the\n // placement, which then needs to re-run all the modifiers, because the\n // logic was previously ran for the previous placement and is therefore\n // stale/incorrect\n\n state.reset = false;\n state.placement = state.options.placement; // On each update cycle, the `modifiersData` property for each modifier\n // is filled with the initial data specified by the modifier. This means\n // it doesn't persist and is fresh on each update.\n // To ensure persistent data, use `${name}#persistent`\n\n state.orderedModifiers.forEach(function (modifier) {\n return state.modifiersData[modifier.name] = Object.assign({}, modifier.data);\n });\n\n for (var index = 0; index < state.orderedModifiers.length; index++) {\n if (state.reset === true) {\n state.reset = false;\n index = -1;\n continue;\n }\n\n var _state$orderedModifie = state.orderedModifiers[index],\n fn = _state$orderedModifie.fn,\n _state$orderedModifie2 = _state$orderedModifie.options,\n _options = _state$orderedModifie2 === void 0 ? {} : _state$orderedModifie2,\n name = _state$orderedModifie.name;\n\n if (typeof fn === 'function') {\n state = fn({\n state: state,\n options: _options,\n name: name,\n instance: instance\n }) || state;\n }\n }\n },\n // Async and optimistically optimized update – it will not be executed if\n // not necessary (debounced to run at most once-per-tick)\n update: debounce(function () {\n return new Promise(function (resolve) {\n instance.forceUpdate();\n resolve(state);\n });\n }),\n destroy: function destroy() {\n cleanupModifierEffects();\n isDestroyed = true;\n }\n };\n\n if (!areValidElements(reference, popper)) {\n return instance;\n }\n\n instance.setOptions(options).then(function (state) {\n if (!isDestroyed && options.onFirstUpdate) {\n options.onFirstUpdate(state);\n }\n }); // Modifiers have the ability to execute arbitrary code before the first\n // update cycle runs. They will be executed in the same order as the update\n // cycle. This is useful when a modifier adds some persistent data that\n // other modifiers need to use, but the modifier is run after the dependent\n // one.\n\n function runModifierEffects() {\n state.orderedModifiers.forEach(function (_ref) {\n var name = _ref.name,\n _ref$options = _ref.options,\n options = _ref$options === void 0 ? {} : _ref$options,\n effect = _ref.effect;\n\n if (typeof effect === 'function') {\n var cleanupFn = effect({\n state: state,\n name: name,\n instance: instance,\n options: options\n });\n\n var noopFn = function noopFn() {};\n\n effectCleanupFns.push(cleanupFn || noopFn);\n }\n });\n }\n\n function cleanupModifierEffects() {\n effectCleanupFns.forEach(function (fn) {\n return fn();\n });\n effectCleanupFns = [];\n }\n\n return instance;\n };\n}\nexport var createPopper = /*#__PURE__*/popperGenerator(); // eslint-disable-next-line import/no-unused-modules\n\nexport { detectOverflow };","import { popperGenerator, detectOverflow } from \"./createPopper.js\";\nimport eventListeners from \"./modifiers/eventListeners.js\";\nimport popperOffsets from \"./modifiers/popperOffsets.js\";\nimport computeStyles from \"./modifiers/computeStyles.js\";\nimport applyStyles from \"./modifiers/applyStyles.js\";\nimport offset from \"./modifiers/offset.js\";\nimport flip from \"./modifiers/flip.js\";\nimport preventOverflow from \"./modifiers/preventOverflow.js\";\nimport arrow from \"./modifiers/arrow.js\";\nimport hide from \"./modifiers/hide.js\";\nvar defaultModifiers = [eventListeners, popperOffsets, computeStyles, applyStyles, offset, flip, preventOverflow, arrow, hide];\nvar createPopper = /*#__PURE__*/popperGenerator({\n defaultModifiers: defaultModifiers\n}); // eslint-disable-next-line import/no-unused-modules\n\nexport { createPopper, popperGenerator, defaultModifiers, detectOverflow }; // eslint-disable-next-line import/no-unused-modules\n\nexport { createPopper as createPopperLite } from \"./popper-lite.js\"; // eslint-disable-next-line import/no-unused-modules\n\nexport * from \"./modifiers/index.js\";","import { generateUtilityClass } from '../generateUtilityClass';\nimport { generateUtilityClasses } from '../generateUtilityClasses';\nconst COMPONENT_NAME = 'Popper';\nexport function getPopperUtilityClass(slot) {\n return generateUtilityClass(COMPONENT_NAME, slot);\n}\nexport const popperClasses = generateUtilityClasses(COMPONENT_NAME, ['root']);","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"anchorEl\", \"children\", \"direction\", \"disablePortal\", \"modifiers\", \"open\", \"placement\", \"popperOptions\", \"popperRef\", \"slotProps\", \"slots\", \"TransitionProps\", \"ownerState\"],\n _excluded2 = [\"anchorEl\", \"children\", \"container\", \"direction\", \"disablePortal\", \"keepMounted\", \"modifiers\", \"open\", \"placement\", \"popperOptions\", \"popperRef\", \"style\", \"transition\", \"slotProps\", \"slots\"];\nimport * as React from 'react';\nimport { chainPropTypes, HTMLElementType, refType, unstable_ownerDocument as ownerDocument, unstable_useEnhancedEffect as useEnhancedEffect, unstable_useForkRef as useForkRef } from '@mui/utils';\nimport { createPopper } from '@popperjs/core';\nimport PropTypes from 'prop-types';\nimport { unstable_composeClasses as composeClasses } from '../composeClasses';\nimport { Portal } from '../Portal';\nimport { getPopperUtilityClass } from './popperClasses';\nimport { useSlotProps } from '../utils';\nimport { useClassNamesOverride } from '../utils/ClassNameConfigurator';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nfunction flipPlacement(placement, direction) {\n if (direction === 'ltr') {\n return placement;\n }\n switch (placement) {\n case 'bottom-end':\n return 'bottom-start';\n case 'bottom-start':\n return 'bottom-end';\n case 'top-end':\n return 'top-start';\n case 'top-start':\n return 'top-end';\n default:\n return placement;\n }\n}\nfunction resolveAnchorEl(anchorEl) {\n return typeof anchorEl === 'function' ? anchorEl() : anchorEl;\n}\nfunction isHTMLElement(element) {\n return element.nodeType !== undefined;\n}\nfunction isVirtualElement(element) {\n return !isHTMLElement(element);\n}\nconst useUtilityClasses = () => {\n const slots = {\n root: ['root']\n };\n return composeClasses(slots, useClassNamesOverride(getPopperUtilityClass));\n};\nconst defaultPopperOptions = {};\nconst PopperTooltip = /*#__PURE__*/React.forwardRef(function PopperTooltip(props, forwardedRef) {\n var _slots$root;\n const {\n anchorEl,\n children,\n direction,\n disablePortal,\n modifiers,\n open,\n placement: initialPlacement,\n popperOptions,\n popperRef: popperRefProp,\n slotProps = {},\n slots = {},\n TransitionProps\n // @ts-ignore internal logic\n // prevent from spreading to DOM, it can come from the parent component e.g. Select.\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const tooltipRef = React.useRef(null);\n const ownRef = useForkRef(tooltipRef, forwardedRef);\n const popperRef = React.useRef(null);\n const handlePopperRef = useForkRef(popperRef, popperRefProp);\n const handlePopperRefRef = React.useRef(handlePopperRef);\n useEnhancedEffect(() => {\n handlePopperRefRef.current = handlePopperRef;\n }, [handlePopperRef]);\n React.useImperativeHandle(popperRefProp, () => popperRef.current, []);\n const rtlPlacement = flipPlacement(initialPlacement, direction);\n /**\n * placement initialized from prop but can change during lifetime if modifiers.flip.\n * modifiers.flip is essentially a flip for controlled/uncontrolled behavior\n */\n const [placement, setPlacement] = React.useState(rtlPlacement);\n const [resolvedAnchorElement, setResolvedAnchorElement] = React.useState(resolveAnchorEl(anchorEl));\n React.useEffect(() => {\n if (popperRef.current) {\n popperRef.current.forceUpdate();\n }\n });\n React.useEffect(() => {\n if (anchorEl) {\n setResolvedAnchorElement(resolveAnchorEl(anchorEl));\n }\n }, [anchorEl]);\n useEnhancedEffect(() => {\n if (!resolvedAnchorElement || !open) {\n return undefined;\n }\n const handlePopperUpdate = data => {\n setPlacement(data.placement);\n };\n if (process.env.NODE_ENV !== 'production') {\n if (resolvedAnchorElement && isHTMLElement(resolvedAnchorElement) && resolvedAnchorElement.nodeType === 1) {\n const box = resolvedAnchorElement.getBoundingClientRect();\n if (process.env.NODE_ENV !== 'test' && box.top === 0 && box.left === 0 && box.right === 0 && box.bottom === 0) {\n console.warn(['MUI: The `anchorEl` prop provided to the component is invalid.', 'The anchor element should be part of the document layout.', \"Make sure the element is present in the document or that it's not display none.\"].join('\\n'));\n }\n }\n }\n let popperModifiers = [{\n name: 'preventOverflow',\n options: {\n altBoundary: disablePortal\n }\n }, {\n name: 'flip',\n options: {\n altBoundary: disablePortal\n }\n }, {\n name: 'onUpdate',\n enabled: true,\n phase: 'afterWrite',\n fn: ({\n state\n }) => {\n handlePopperUpdate(state);\n }\n }];\n if (modifiers != null) {\n popperModifiers = popperModifiers.concat(modifiers);\n }\n if (popperOptions && popperOptions.modifiers != null) {\n popperModifiers = popperModifiers.concat(popperOptions.modifiers);\n }\n const popper = createPopper(resolvedAnchorElement, tooltipRef.current, _extends({\n placement: rtlPlacement\n }, popperOptions, {\n modifiers: popperModifiers\n }));\n handlePopperRefRef.current(popper);\n return () => {\n popper.destroy();\n handlePopperRefRef.current(null);\n };\n }, [resolvedAnchorElement, disablePortal, modifiers, open, popperOptions, rtlPlacement]);\n const childProps = {\n placement: placement\n };\n if (TransitionProps !== null) {\n childProps.TransitionProps = TransitionProps;\n }\n const classes = useUtilityClasses();\n const Root = (_slots$root = slots.root) != null ? _slots$root : 'div';\n const rootProps = useSlotProps({\n elementType: Root,\n externalSlotProps: slotProps.root,\n externalForwardedProps: other,\n additionalProps: {\n role: 'tooltip',\n ref: ownRef\n },\n ownerState: props,\n className: classes.root\n });\n return /*#__PURE__*/_jsx(Root, _extends({}, rootProps, {\n children: typeof children === 'function' ? children(childProps) : children\n }));\n});\n\n/**\n * Poppers rely on the 3rd party library [Popper.js](https://popper.js.org/docs/v2/) for positioning.\n *\n * Demos:\n *\n * - [Popper](https://mui.com/base-ui/react-popper/)\n *\n * API:\n *\n * - [Popper API](https://mui.com/base-ui/react-popper/components-api/#popper)\n */\nconst Popper = /*#__PURE__*/React.forwardRef(function Popper(props, forwardedRef) {\n const {\n anchorEl,\n children,\n container: containerProp,\n direction = 'ltr',\n disablePortal = false,\n keepMounted = false,\n modifiers,\n open,\n placement = 'bottom',\n popperOptions = defaultPopperOptions,\n popperRef,\n style,\n transition = false,\n slotProps = {},\n slots = {}\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded2);\n const [exited, setExited] = React.useState(true);\n const handleEnter = () => {\n setExited(false);\n };\n const handleExited = () => {\n setExited(true);\n };\n if (!keepMounted && !open && (!transition || exited)) {\n return null;\n }\n\n // If the container prop is provided, use that\n // If the anchorEl prop is provided, use its parent body element as the container\n // If neither are provided let the Modal take care of choosing the container\n let container;\n if (containerProp) {\n container = containerProp;\n } else if (anchorEl) {\n const resolvedAnchorEl = resolveAnchorEl(anchorEl);\n container = resolvedAnchorEl && isHTMLElement(resolvedAnchorEl) ? ownerDocument(resolvedAnchorEl).body : ownerDocument(null).body;\n }\n const display = !open && keepMounted && (!transition || exited) ? 'none' : undefined;\n const transitionProps = transition ? {\n in: open,\n onEnter: handleEnter,\n onExited: handleExited\n } : undefined;\n return /*#__PURE__*/_jsx(Portal, {\n disablePortal: disablePortal,\n container: container,\n children: /*#__PURE__*/_jsx(PopperTooltip, _extends({\n anchorEl: anchorEl,\n direction: direction,\n disablePortal: disablePortal,\n modifiers: modifiers,\n ref: forwardedRef,\n open: transition ? !exited : open,\n placement: placement,\n popperOptions: popperOptions,\n popperRef: popperRef,\n slotProps: slotProps,\n slots: slots\n }, other, {\n style: _extends({\n // Prevents scroll issue, waiting for Popper.js to add this style once initiated.\n position: 'fixed',\n // Fix Popper.js display issue\n top: 0,\n left: 0,\n display\n }, style),\n TransitionProps: transitionProps,\n children: children\n }))\n });\n});\nprocess.env.NODE_ENV !== \"production\" ? Popper.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * An HTML element, [virtualElement](https://popper.js.org/docs/v2/virtual-elements/),\n * or a function that returns either.\n * It's used to set the position of the popper.\n * The return value will passed as the reference object of the Popper instance.\n */\n anchorEl: chainPropTypes(PropTypes.oneOfType([HTMLElementType, PropTypes.object, PropTypes.func]), props => {\n if (props.open) {\n const resolvedAnchorEl = resolveAnchorEl(props.anchorEl);\n if (resolvedAnchorEl && isHTMLElement(resolvedAnchorEl) && resolvedAnchorEl.nodeType === 1) {\n const box = resolvedAnchorEl.getBoundingClientRect();\n if (process.env.NODE_ENV !== 'test' && box.top === 0 && box.left === 0 && box.right === 0 && box.bottom === 0) {\n return new Error(['MUI: The `anchorEl` prop provided to the component is invalid.', 'The anchor element should be part of the document layout.', \"Make sure the element is present in the document or that it's not display none.\"].join('\\n'));\n }\n } else if (!resolvedAnchorEl || typeof resolvedAnchorEl.getBoundingClientRect !== 'function' || isVirtualElement(resolvedAnchorEl) && resolvedAnchorEl.contextElement != null && resolvedAnchorEl.contextElement.nodeType !== 1) {\n return new Error(['MUI: The `anchorEl` prop provided to the component is invalid.', 'It should be an HTML element instance or a virtualElement ', '(https://popper.js.org/docs/v2/virtual-elements/).'].join('\\n'));\n }\n }\n return null;\n }),\n /**\n * Popper render function or node.\n */\n children: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.node, PropTypes.func]),\n /**\n * An HTML element or function that returns one.\n * The `container` will have the portal children appended to it.\n *\n * You can also provide a callback, which is called in a React layout effect.\n * This lets you set the container from a ref, and also makes server-side rendering possible.\n *\n * By default, it uses the body of the top-level document object,\n * so it's simply `document.body` most of the time.\n */\n container: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.func]),\n /**\n * Direction of the text.\n * @default 'ltr'\n */\n direction: PropTypes.oneOf(['ltr', 'rtl']),\n /**\n * The `children` will be under the DOM hierarchy of the parent component.\n * @default false\n */\n disablePortal: PropTypes.bool,\n /**\n * Always keep the children in the DOM.\n * This prop can be useful in SEO situation or\n * when you want to maximize the responsiveness of the Popper.\n * @default false\n */\n keepMounted: PropTypes.bool,\n /**\n * Popper.js is based on a \"plugin-like\" architecture,\n * most of its features are fully encapsulated \"modifiers\".\n *\n * A modifier is a function that is called each time Popper.js needs to\n * compute the position of the popper.\n * For this reason, modifiers should be very performant to avoid bottlenecks.\n * To learn how to create a modifier, [read the modifiers documentation](https://popper.js.org/docs/v2/modifiers/).\n */\n modifiers: PropTypes.arrayOf(PropTypes.shape({\n data: PropTypes.object,\n effect: PropTypes.func,\n enabled: PropTypes.bool,\n fn: PropTypes.func,\n name: PropTypes.any,\n options: PropTypes.object,\n phase: PropTypes.oneOf(['afterMain', 'afterRead', 'afterWrite', 'beforeMain', 'beforeRead', 'beforeWrite', 'main', 'read', 'write']),\n requires: PropTypes.arrayOf(PropTypes.string),\n requiresIfExists: PropTypes.arrayOf(PropTypes.string)\n })),\n /**\n * If `true`, the component is shown.\n */\n open: PropTypes.bool.isRequired,\n /**\n * Popper placement.\n * @default 'bottom'\n */\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n /**\n * Options provided to the [`Popper.js`](https://popper.js.org/docs/v2/constructors/#options) instance.\n * @default {}\n */\n popperOptions: PropTypes.shape({\n modifiers: PropTypes.array,\n onFirstUpdate: PropTypes.func,\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n strategy: PropTypes.oneOf(['absolute', 'fixed'])\n }),\n /**\n * A ref that points to the used popper instance.\n */\n popperRef: refType,\n /**\n * The props used for each slot inside the Popper.\n * @default {}\n */\n slotProps: PropTypes.shape({\n root: PropTypes.oneOfType([PropTypes.func, PropTypes.object])\n }),\n /**\n * The components used for each slot inside the Popper.\n * Either a string to use a HTML element or a component.\n * @default {}\n */\n slots: PropTypes.shape({\n root: PropTypes.elementType\n }),\n /**\n * Help supporting a react-transition-group/Transition component.\n * @default false\n */\n transition: PropTypes.bool\n} : void 0;\nexport { Popper };","'use client';\n\nimport * as React from 'react';\nimport { useTheme as useThemeSystem } from '@mui/system';\nimport defaultTheme from './defaultTheme';\nimport THEME_ID from './identifier';\nexport default function useTheme() {\n const theme = useThemeSystem(defaultTheme);\n if (process.env.NODE_ENV !== 'production') {\n // eslint-disable-next-line react-hooks/rules-of-hooks\n React.useDebugValue(theme);\n }\n return theme[THEME_ID] || theme;\n}","export default function _setPrototypeOf(o, p) {\n _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function _setPrototypeOf(o, p) {\n o.__proto__ = p;\n return o;\n };\n return _setPrototypeOf(o, p);\n}","import setPrototypeOf from \"./setPrototypeOf.js\";\nexport default function _inheritsLoose(subClass, superClass) {\n subClass.prototype = Object.create(superClass.prototype);\n subClass.prototype.constructor = subClass;\n setPrototypeOf(subClass, superClass);\n}","export default {\n disabled: false\n};","import PropTypes from 'prop-types';\nexport var timeoutsShape = process.env.NODE_ENV !== 'production' ? PropTypes.oneOfType([PropTypes.number, PropTypes.shape({\n enter: PropTypes.number,\n exit: PropTypes.number,\n appear: PropTypes.number\n}).isRequired]) : null;\nexport var classNamesShape = process.env.NODE_ENV !== 'production' ? PropTypes.oneOfType([PropTypes.string, PropTypes.shape({\n enter: PropTypes.string,\n exit: PropTypes.string,\n active: PropTypes.string\n}), PropTypes.shape({\n enter: PropTypes.string,\n enterDone: PropTypes.string,\n enterActive: PropTypes.string,\n exit: PropTypes.string,\n exitDone: PropTypes.string,\n exitActive: PropTypes.string\n})]) : null;","import React from 'react';\nexport default React.createContext(null);","export var forceReflow = function forceReflow(node) {\n return node.scrollTop;\n};","import _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _inheritsLoose from \"@babel/runtime/helpers/esm/inheritsLoose\";\nimport PropTypes from 'prop-types';\nimport React from 'react';\nimport ReactDOM from 'react-dom';\nimport config from './config';\nimport { timeoutsShape } from './utils/PropTypes';\nimport TransitionGroupContext from './TransitionGroupContext';\nimport { forceReflow } from './utils/reflow';\nexport var UNMOUNTED = 'unmounted';\nexport var EXITED = 'exited';\nexport var ENTERING = 'entering';\nexport var ENTERED = 'entered';\nexport var EXITING = 'exiting';\n/**\n * The Transition component lets you describe a transition from one component\n * state to another _over time_ with a simple declarative API. Most commonly\n * it's used to animate the mounting and unmounting of a component, but can also\n * be used to describe in-place transition states as well.\n *\n * ---\n *\n * **Note**: `Transition` is a platform-agnostic base component. If you're using\n * transitions in CSS, you'll probably want to use\n * [`CSSTransition`](https://reactcommunity.org/react-transition-group/css-transition)\n * instead. It inherits all the features of `Transition`, but contains\n * additional features necessary to play nice with CSS transitions (hence the\n * name of the component).\n *\n * ---\n *\n * By default the `Transition` component does not alter the behavior of the\n * component it renders, it only tracks \"enter\" and \"exit\" states for the\n * components. It's up to you to give meaning and effect to those states. For\n * example we can add styles to a component when it enters or exits:\n *\n * ```jsx\n * import { Transition } from 'react-transition-group';\n *\n * const duration = 300;\n *\n * const defaultStyle = {\n * transition: `opacity ${duration}ms ease-in-out`,\n * opacity: 0,\n * }\n *\n * const transitionStyles = {\n * entering: { opacity: 1 },\n * entered: { opacity: 1 },\n * exiting: { opacity: 0 },\n * exited: { opacity: 0 },\n * };\n *\n * const Fade = ({ in: inProp }) => (\n * \n * {state => (\n *
    \n * I'm a fade Transition!\n *
    \n * )}\n *
    \n * );\n * ```\n *\n * There are 4 main states a Transition can be in:\n * - `'entering'`\n * - `'entered'`\n * - `'exiting'`\n * - `'exited'`\n *\n * Transition state is toggled via the `in` prop. When `true` the component\n * begins the \"Enter\" stage. During this stage, the component will shift from\n * its current transition state, to `'entering'` for the duration of the\n * transition and then to the `'entered'` stage once it's complete. Let's take\n * the following example (we'll use the\n * [useState](https://reactjs.org/docs/hooks-reference.html#usestate) hook):\n *\n * ```jsx\n * function App() {\n * const [inProp, setInProp] = useState(false);\n * return (\n *
    \n * \n * {state => (\n * // ...\n * )}\n * \n * \n *
    \n * );\n * }\n * ```\n *\n * When the button is clicked the component will shift to the `'entering'` state\n * and stay there for 500ms (the value of `timeout`) before it finally switches\n * to `'entered'`.\n *\n * When `in` is `false` the same thing happens except the state moves from\n * `'exiting'` to `'exited'`.\n */\n\nvar Transition = /*#__PURE__*/function (_React$Component) {\n _inheritsLoose(Transition, _React$Component);\n\n function Transition(props, context) {\n var _this;\n\n _this = _React$Component.call(this, props, context) || this;\n var parentGroup = context; // In the context of a TransitionGroup all enters are really appears\n\n var appear = parentGroup && !parentGroup.isMounting ? props.enter : props.appear;\n var initialStatus;\n _this.appearStatus = null;\n\n if (props.in) {\n if (appear) {\n initialStatus = EXITED;\n _this.appearStatus = ENTERING;\n } else {\n initialStatus = ENTERED;\n }\n } else {\n if (props.unmountOnExit || props.mountOnEnter) {\n initialStatus = UNMOUNTED;\n } else {\n initialStatus = EXITED;\n }\n }\n\n _this.state = {\n status: initialStatus\n };\n _this.nextCallback = null;\n return _this;\n }\n\n Transition.getDerivedStateFromProps = function getDerivedStateFromProps(_ref, prevState) {\n var nextIn = _ref.in;\n\n if (nextIn && prevState.status === UNMOUNTED) {\n return {\n status: EXITED\n };\n }\n\n return null;\n } // getSnapshotBeforeUpdate(prevProps) {\n // let nextStatus = null\n // if (prevProps !== this.props) {\n // const { status } = this.state\n // if (this.props.in) {\n // if (status !== ENTERING && status !== ENTERED) {\n // nextStatus = ENTERING\n // }\n // } else {\n // if (status === ENTERING || status === ENTERED) {\n // nextStatus = EXITING\n // }\n // }\n // }\n // return { nextStatus }\n // }\n ;\n\n var _proto = Transition.prototype;\n\n _proto.componentDidMount = function componentDidMount() {\n this.updateStatus(true, this.appearStatus);\n };\n\n _proto.componentDidUpdate = function componentDidUpdate(prevProps) {\n var nextStatus = null;\n\n if (prevProps !== this.props) {\n var status = this.state.status;\n\n if (this.props.in) {\n if (status !== ENTERING && status !== ENTERED) {\n nextStatus = ENTERING;\n }\n } else {\n if (status === ENTERING || status === ENTERED) {\n nextStatus = EXITING;\n }\n }\n }\n\n this.updateStatus(false, nextStatus);\n };\n\n _proto.componentWillUnmount = function componentWillUnmount() {\n this.cancelNextCallback();\n };\n\n _proto.getTimeouts = function getTimeouts() {\n var timeout = this.props.timeout;\n var exit, enter, appear;\n exit = enter = appear = timeout;\n\n if (timeout != null && typeof timeout !== 'number') {\n exit = timeout.exit;\n enter = timeout.enter; // TODO: remove fallback for next major\n\n appear = timeout.appear !== undefined ? timeout.appear : enter;\n }\n\n return {\n exit: exit,\n enter: enter,\n appear: appear\n };\n };\n\n _proto.updateStatus = function updateStatus(mounting, nextStatus) {\n if (mounting === void 0) {\n mounting = false;\n }\n\n if (nextStatus !== null) {\n // nextStatus will always be ENTERING or EXITING.\n this.cancelNextCallback();\n\n if (nextStatus === ENTERING) {\n if (this.props.unmountOnExit || this.props.mountOnEnter) {\n var node = this.props.nodeRef ? this.props.nodeRef.current : ReactDOM.findDOMNode(this); // https://github.com/reactjs/react-transition-group/pull/749\n // With unmountOnExit or mountOnEnter, the enter animation should happen at the transition between `exited` and `entering`.\n // To make the animation happen, we have to separate each rendering and avoid being processed as batched.\n\n if (node) forceReflow(node);\n }\n\n this.performEnter(mounting);\n } else {\n this.performExit();\n }\n } else if (this.props.unmountOnExit && this.state.status === EXITED) {\n this.setState({\n status: UNMOUNTED\n });\n }\n };\n\n _proto.performEnter = function performEnter(mounting) {\n var _this2 = this;\n\n var enter = this.props.enter;\n var appearing = this.context ? this.context.isMounting : mounting;\n\n var _ref2 = this.props.nodeRef ? [appearing] : [ReactDOM.findDOMNode(this), appearing],\n maybeNode = _ref2[0],\n maybeAppearing = _ref2[1];\n\n var timeouts = this.getTimeouts();\n var enterTimeout = appearing ? timeouts.appear : timeouts.enter; // no enter animation skip right to ENTERED\n // if we are mounting and running this it means appear _must_ be set\n\n if (!mounting && !enter || config.disabled) {\n this.safeSetState({\n status: ENTERED\n }, function () {\n _this2.props.onEntered(maybeNode);\n });\n return;\n }\n\n this.props.onEnter(maybeNode, maybeAppearing);\n this.safeSetState({\n status: ENTERING\n }, function () {\n _this2.props.onEntering(maybeNode, maybeAppearing);\n\n _this2.onTransitionEnd(enterTimeout, function () {\n _this2.safeSetState({\n status: ENTERED\n }, function () {\n _this2.props.onEntered(maybeNode, maybeAppearing);\n });\n });\n });\n };\n\n _proto.performExit = function performExit() {\n var _this3 = this;\n\n var exit = this.props.exit;\n var timeouts = this.getTimeouts();\n var maybeNode = this.props.nodeRef ? undefined : ReactDOM.findDOMNode(this); // no exit animation skip right to EXITED\n\n if (!exit || config.disabled) {\n this.safeSetState({\n status: EXITED\n }, function () {\n _this3.props.onExited(maybeNode);\n });\n return;\n }\n\n this.props.onExit(maybeNode);\n this.safeSetState({\n status: EXITING\n }, function () {\n _this3.props.onExiting(maybeNode);\n\n _this3.onTransitionEnd(timeouts.exit, function () {\n _this3.safeSetState({\n status: EXITED\n }, function () {\n _this3.props.onExited(maybeNode);\n });\n });\n });\n };\n\n _proto.cancelNextCallback = function cancelNextCallback() {\n if (this.nextCallback !== null) {\n this.nextCallback.cancel();\n this.nextCallback = null;\n }\n };\n\n _proto.safeSetState = function safeSetState(nextState, callback) {\n // This shouldn't be necessary, but there are weird race conditions with\n // setState callbacks and unmounting in testing, so always make sure that\n // we can cancel any pending setState callbacks after we unmount.\n callback = this.setNextCallback(callback);\n this.setState(nextState, callback);\n };\n\n _proto.setNextCallback = function setNextCallback(callback) {\n var _this4 = this;\n\n var active = true;\n\n this.nextCallback = function (event) {\n if (active) {\n active = false;\n _this4.nextCallback = null;\n callback(event);\n }\n };\n\n this.nextCallback.cancel = function () {\n active = false;\n };\n\n return this.nextCallback;\n };\n\n _proto.onTransitionEnd = function onTransitionEnd(timeout, handler) {\n this.setNextCallback(handler);\n var node = this.props.nodeRef ? this.props.nodeRef.current : ReactDOM.findDOMNode(this);\n var doesNotHaveTimeoutOrListener = timeout == null && !this.props.addEndListener;\n\n if (!node || doesNotHaveTimeoutOrListener) {\n setTimeout(this.nextCallback, 0);\n return;\n }\n\n if (this.props.addEndListener) {\n var _ref3 = this.props.nodeRef ? [this.nextCallback] : [node, this.nextCallback],\n maybeNode = _ref3[0],\n maybeNextCallback = _ref3[1];\n\n this.props.addEndListener(maybeNode, maybeNextCallback);\n }\n\n if (timeout != null) {\n setTimeout(this.nextCallback, timeout);\n }\n };\n\n _proto.render = function render() {\n var status = this.state.status;\n\n if (status === UNMOUNTED) {\n return null;\n }\n\n var _this$props = this.props,\n children = _this$props.children,\n _in = _this$props.in,\n _mountOnEnter = _this$props.mountOnEnter,\n _unmountOnExit = _this$props.unmountOnExit,\n _appear = _this$props.appear,\n _enter = _this$props.enter,\n _exit = _this$props.exit,\n _timeout = _this$props.timeout,\n _addEndListener = _this$props.addEndListener,\n _onEnter = _this$props.onEnter,\n _onEntering = _this$props.onEntering,\n _onEntered = _this$props.onEntered,\n _onExit = _this$props.onExit,\n _onExiting = _this$props.onExiting,\n _onExited = _this$props.onExited,\n _nodeRef = _this$props.nodeRef,\n childProps = _objectWithoutPropertiesLoose(_this$props, [\"children\", \"in\", \"mountOnEnter\", \"unmountOnExit\", \"appear\", \"enter\", \"exit\", \"timeout\", \"addEndListener\", \"onEnter\", \"onEntering\", \"onEntered\", \"onExit\", \"onExiting\", \"onExited\", \"nodeRef\"]);\n\n return (\n /*#__PURE__*/\n // allows for nested Transitions\n React.createElement(TransitionGroupContext.Provider, {\n value: null\n }, typeof children === 'function' ? children(status, childProps) : React.cloneElement(React.Children.only(children), childProps))\n );\n };\n\n return Transition;\n}(React.Component);\n\nTransition.contextType = TransitionGroupContext;\nTransition.propTypes = process.env.NODE_ENV !== \"production\" ? {\n /**\n * A React reference to DOM element that need to transition:\n * https://stackoverflow.com/a/51127130/4671932\n *\n * - When `nodeRef` prop is used, `node` is not passed to callback functions\n * (e.g. `onEnter`) because user already has direct access to the node.\n * - When changing `key` prop of `Transition` in a `TransitionGroup` a new\n * `nodeRef` need to be provided to `Transition` with changed `key` prop\n * (see\n * [test/CSSTransition-test.js](https://github.com/reactjs/react-transition-group/blob/13435f897b3ab71f6e19d724f145596f5910581c/test/CSSTransition-test.js#L362-L437)).\n */\n nodeRef: PropTypes.shape({\n current: typeof Element === 'undefined' ? PropTypes.any : function (propValue, key, componentName, location, propFullName, secret) {\n var value = propValue[key];\n return PropTypes.instanceOf(value && 'ownerDocument' in value ? value.ownerDocument.defaultView.Element : Element)(propValue, key, componentName, location, propFullName, secret);\n }\n }),\n\n /**\n * A `function` child can be used instead of a React element. This function is\n * called with the current transition status (`'entering'`, `'entered'`,\n * `'exiting'`, `'exited'`), which can be used to apply context\n * specific props to a component.\n *\n * ```jsx\n * \n * {state => (\n * \n * )}\n * \n * ```\n */\n children: PropTypes.oneOfType([PropTypes.func.isRequired, PropTypes.element.isRequired]).isRequired,\n\n /**\n * Show the component; triggers the enter or exit states\n */\n in: PropTypes.bool,\n\n /**\n * By default the child component is mounted immediately along with\n * the parent `Transition` component. If you want to \"lazy mount\" the component on the\n * first `in={true}` you can set `mountOnEnter`. After the first enter transition the component will stay\n * mounted, even on \"exited\", unless you also specify `unmountOnExit`.\n */\n mountOnEnter: PropTypes.bool,\n\n /**\n * By default the child component stays mounted after it reaches the `'exited'` state.\n * Set `unmountOnExit` if you'd prefer to unmount the component after it finishes exiting.\n */\n unmountOnExit: PropTypes.bool,\n\n /**\n * By default the child component does not perform the enter transition when\n * it first mounts, regardless of the value of `in`. If you want this\n * behavior, set both `appear` and `in` to `true`.\n *\n * > **Note**: there are no special appear states like `appearing`/`appeared`, this prop\n * > only adds an additional enter transition. However, in the\n * > `` component that first enter transition does result in\n * > additional `.appear-*` classes, that way you can choose to style it\n * > differently.\n */\n appear: PropTypes.bool,\n\n /**\n * Enable or disable enter transitions.\n */\n enter: PropTypes.bool,\n\n /**\n * Enable or disable exit transitions.\n */\n exit: PropTypes.bool,\n\n /**\n * The duration of the transition, in milliseconds.\n * Required unless `addEndListener` is provided.\n *\n * You may specify a single timeout for all transitions:\n *\n * ```jsx\n * timeout={500}\n * ```\n *\n * or individually:\n *\n * ```jsx\n * timeout={{\n * appear: 500,\n * enter: 300,\n * exit: 500,\n * }}\n * ```\n *\n * - `appear` defaults to the value of `enter`\n * - `enter` defaults to `0`\n * - `exit` defaults to `0`\n *\n * @type {number | { enter?: number, exit?: number, appear?: number }}\n */\n timeout: function timeout(props) {\n var pt = timeoutsShape;\n if (!props.addEndListener) pt = pt.isRequired;\n\n for (var _len = arguments.length, args = new Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) {\n args[_key - 1] = arguments[_key];\n }\n\n return pt.apply(void 0, [props].concat(args));\n },\n\n /**\n * Add a custom transition end trigger. Called with the transitioning\n * DOM node and a `done` callback. Allows for more fine grained transition end\n * logic. Timeouts are still used as a fallback if provided.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * ```jsx\n * addEndListener={(node, done) => {\n * // use the css transitionend event to mark the finish of a transition\n * node.addEventListener('transitionend', done, false);\n * }}\n * ```\n */\n addEndListener: PropTypes.func,\n\n /**\n * Callback fired before the \"entering\" status is applied. An extra parameter\n * `isAppearing` is supplied to indicate if the enter stage is occurring on the initial mount\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement, isAppearing: bool) -> void\n */\n onEnter: PropTypes.func,\n\n /**\n * Callback fired after the \"entering\" status is applied. An extra parameter\n * `isAppearing` is supplied to indicate if the enter stage is occurring on the initial mount\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement, isAppearing: bool)\n */\n onEntering: PropTypes.func,\n\n /**\n * Callback fired after the \"entered\" status is applied. An extra parameter\n * `isAppearing` is supplied to indicate if the enter stage is occurring on the initial mount\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement, isAppearing: bool) -> void\n */\n onEntered: PropTypes.func,\n\n /**\n * Callback fired before the \"exiting\" status is applied.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement) -> void\n */\n onExit: PropTypes.func,\n\n /**\n * Callback fired after the \"exiting\" status is applied.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement) -> void\n */\n onExiting: PropTypes.func,\n\n /**\n * Callback fired after the \"exited\" status is applied.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed\n *\n * @type Function(node: HtmlElement) -> void\n */\n onExited: PropTypes.func\n} : {}; // Name the function so it is clearer in the documentation\n\nfunction noop() {}\n\nTransition.defaultProps = {\n in: false,\n mountOnEnter: false,\n unmountOnExit: false,\n appear: false,\n enter: true,\n exit: true,\n onEnter: noop,\n onEntering: noop,\n onEntered: noop,\n onExit: noop,\n onExiting: noop,\n onExited: noop\n};\nTransition.UNMOUNTED = UNMOUNTED;\nTransition.EXITED = EXITED;\nTransition.ENTERING = ENTERING;\nTransition.ENTERED = ENTERED;\nTransition.EXITING = EXITING;\nexport default Transition;","export const reflow = node => node.scrollTop;\nexport function getTransitionProps(props, options) {\n var _style$transitionDura, _style$transitionTimi;\n const {\n timeout,\n easing,\n style = {}\n } = props;\n return {\n duration: (_style$transitionDura = style.transitionDuration) != null ? _style$transitionDura : typeof timeout === 'number' ? timeout : timeout[options.mode] || 0,\n easing: (_style$transitionTimi = style.transitionTimingFunction) != null ? _style$transitionTimi : typeof easing === 'object' ? easing[options.mode] : easing,\n delay: style.transitionDelay\n };\n}","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"addEndListener\", \"appear\", \"children\", \"easing\", \"in\", \"onEnter\", \"onEntered\", \"onEntering\", \"onExit\", \"onExited\", \"onExiting\", \"style\", \"timeout\", \"TransitionComponent\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport { elementAcceptingRef, unstable_useTimeout as useTimeout } from '@mui/utils';\nimport { Transition } from 'react-transition-group';\nimport useTheme from '../styles/useTheme';\nimport { getTransitionProps, reflow } from '../transitions/utils';\nimport useForkRef from '../utils/useForkRef';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nfunction getScale(value) {\n return `scale(${value}, ${value ** 2})`;\n}\nconst styles = {\n entering: {\n opacity: 1,\n transform: getScale(1)\n },\n entered: {\n opacity: 1,\n transform: 'none'\n }\n};\n\n/*\n TODO v6: remove\n Conditionally apply a workaround for the CSS transition bug in Safari 15.4 / WebKit browsers.\n */\nconst isWebKit154 = typeof navigator !== 'undefined' && /^((?!chrome|android).)*(safari|mobile)/i.test(navigator.userAgent) && /(os |version\\/)15(.|_)4/i.test(navigator.userAgent);\n\n/**\n * The Grow transition is used by the [Tooltip](/material-ui/react-tooltip/) and\n * [Popover](/material-ui/react-popover/) components.\n * It uses [react-transition-group](https://github.com/reactjs/react-transition-group) internally.\n */\nconst Grow = /*#__PURE__*/React.forwardRef(function Grow(props, ref) {\n const {\n addEndListener,\n appear = true,\n children,\n easing,\n in: inProp,\n onEnter,\n onEntered,\n onEntering,\n onExit,\n onExited,\n onExiting,\n style,\n timeout = 'auto',\n // eslint-disable-next-line react/prop-types\n TransitionComponent = Transition\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const timer = useTimeout();\n const autoTimeout = React.useRef();\n const theme = useTheme();\n const nodeRef = React.useRef(null);\n const handleRef = useForkRef(nodeRef, children.ref, ref);\n const normalizedTransitionCallback = callback => maybeIsAppearing => {\n if (callback) {\n const node = nodeRef.current;\n\n // onEnterXxx and onExitXxx callbacks have a different arguments.length value.\n if (maybeIsAppearing === undefined) {\n callback(node);\n } else {\n callback(node, maybeIsAppearing);\n }\n }\n };\n const handleEntering = normalizedTransitionCallback(onEntering);\n const handleEnter = normalizedTransitionCallback((node, isAppearing) => {\n reflow(node); // So the animation always start from the start.\n\n const {\n duration: transitionDuration,\n delay,\n easing: transitionTimingFunction\n } = getTransitionProps({\n style,\n timeout,\n easing\n }, {\n mode: 'enter'\n });\n let duration;\n if (timeout === 'auto') {\n duration = theme.transitions.getAutoHeightDuration(node.clientHeight);\n autoTimeout.current = duration;\n } else {\n duration = transitionDuration;\n }\n node.style.transition = [theme.transitions.create('opacity', {\n duration,\n delay\n }), theme.transitions.create('transform', {\n duration: isWebKit154 ? duration : duration * 0.666,\n delay,\n easing: transitionTimingFunction\n })].join(',');\n if (onEnter) {\n onEnter(node, isAppearing);\n }\n });\n const handleEntered = normalizedTransitionCallback(onEntered);\n const handleExiting = normalizedTransitionCallback(onExiting);\n const handleExit = normalizedTransitionCallback(node => {\n const {\n duration: transitionDuration,\n delay,\n easing: transitionTimingFunction\n } = getTransitionProps({\n style,\n timeout,\n easing\n }, {\n mode: 'exit'\n });\n let duration;\n if (timeout === 'auto') {\n duration = theme.transitions.getAutoHeightDuration(node.clientHeight);\n autoTimeout.current = duration;\n } else {\n duration = transitionDuration;\n }\n node.style.transition = [theme.transitions.create('opacity', {\n duration,\n delay\n }), theme.transitions.create('transform', {\n duration: isWebKit154 ? duration : duration * 0.666,\n delay: isWebKit154 ? delay : delay || duration * 0.333,\n easing: transitionTimingFunction\n })].join(',');\n node.style.opacity = 0;\n node.style.transform = getScale(0.75);\n if (onExit) {\n onExit(node);\n }\n });\n const handleExited = normalizedTransitionCallback(onExited);\n const handleAddEndListener = next => {\n if (timeout === 'auto') {\n timer.start(autoTimeout.current || 0, next);\n }\n if (addEndListener) {\n // Old call signature before `react-transition-group` implemented `nodeRef`\n addEndListener(nodeRef.current, next);\n }\n };\n return /*#__PURE__*/_jsx(TransitionComponent, _extends({\n appear: appear,\n in: inProp,\n nodeRef: nodeRef,\n onEnter: handleEnter,\n onEntered: handleEntered,\n onEntering: handleEntering,\n onExit: handleExit,\n onExited: handleExited,\n onExiting: handleExiting,\n addEndListener: handleAddEndListener,\n timeout: timeout === 'auto' ? null : timeout\n }, other, {\n children: (state, childProps) => {\n return /*#__PURE__*/React.cloneElement(children, _extends({\n style: _extends({\n opacity: 0,\n transform: getScale(0.75),\n visibility: state === 'exited' && !inProp ? 'hidden' : undefined\n }, styles[state], style, children.props.style),\n ref: handleRef\n }, childProps));\n }\n }));\n});\nprocess.env.NODE_ENV !== \"production\" ? Grow.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the d.ts file and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * Add a custom transition end trigger. Called with the transitioning DOM\n * node and a done callback. Allows for more fine grained transition end\n * logic. Note: Timeouts are still used as a fallback if provided.\n */\n addEndListener: PropTypes.func,\n /**\n * Perform the enter transition when it first mounts if `in` is also `true`.\n * Set this to `false` to disable this behavior.\n * @default true\n */\n appear: PropTypes.bool,\n /**\n * A single child content element.\n */\n children: elementAcceptingRef.isRequired,\n /**\n * The transition timing function.\n * You may specify a single easing or a object containing enter and exit values.\n */\n easing: PropTypes.oneOfType([PropTypes.shape({\n enter: PropTypes.string,\n exit: PropTypes.string\n }), PropTypes.string]),\n /**\n * If `true`, the component will transition in.\n */\n in: PropTypes.bool,\n /**\n * @ignore\n */\n onEnter: PropTypes.func,\n /**\n * @ignore\n */\n onEntered: PropTypes.func,\n /**\n * @ignore\n */\n onEntering: PropTypes.func,\n /**\n * @ignore\n */\n onExit: PropTypes.func,\n /**\n * @ignore\n */\n onExited: PropTypes.func,\n /**\n * @ignore\n */\n onExiting: PropTypes.func,\n /**\n * @ignore\n */\n style: PropTypes.object,\n /**\n * The duration for the transition, in milliseconds.\n * You may specify a single timeout for all transitions, or individually with an object.\n *\n * Set to 'auto' to automatically calculate transition time based on height.\n * @default 'auto'\n */\n timeout: PropTypes.oneOfType([PropTypes.oneOf(['auto']), PropTypes.number, PropTypes.shape({\n appear: PropTypes.number,\n enter: PropTypes.number,\n exit: PropTypes.number\n })])\n} : void 0;\nGrow.muiSupportAuto = true;\nexport default Grow;","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"anchorEl\", \"component\", \"components\", \"componentsProps\", \"container\", \"disablePortal\", \"keepMounted\", \"modifiers\", \"open\", \"placement\", \"popperOptions\", \"popperRef\", \"transition\", \"slots\", \"slotProps\"];\nimport { Popper as BasePopper } from '@mui/base/Popper';\nimport { useThemeWithoutDefault as useTheme } from '@mui/system';\nimport { HTMLElementType, refType } from '@mui/utils';\nimport PropTypes from 'prop-types';\nimport * as React from 'react';\nimport { styled, useThemeProps } from '../styles';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nconst PopperRoot = styled(BasePopper, {\n name: 'MuiPopper',\n slot: 'Root',\n overridesResolver: (props, styles) => styles.root\n})({});\n\n/**\n *\n * Demos:\n *\n * - [Autocomplete](https://mui.com/material-ui/react-autocomplete/)\n * - [Menu](https://mui.com/material-ui/react-menu/)\n * - [Popper](https://mui.com/material-ui/react-popper/)\n *\n * API:\n *\n * - [Popper API](https://mui.com/material-ui/api/popper/)\n */\nconst Popper = /*#__PURE__*/React.forwardRef(function Popper(inProps, ref) {\n var _slots$root;\n const theme = useTheme();\n const props = useThemeProps({\n props: inProps,\n name: 'MuiPopper'\n });\n const {\n anchorEl,\n component,\n components,\n componentsProps,\n container,\n disablePortal,\n keepMounted,\n modifiers,\n open,\n placement,\n popperOptions,\n popperRef,\n transition,\n slots,\n slotProps\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const RootComponent = (_slots$root = slots == null ? void 0 : slots.root) != null ? _slots$root : components == null ? void 0 : components.Root;\n const otherProps = _extends({\n anchorEl,\n container,\n disablePortal,\n keepMounted,\n modifiers,\n open,\n placement,\n popperOptions,\n popperRef,\n transition\n }, other);\n return /*#__PURE__*/_jsx(PopperRoot, _extends({\n as: component,\n direction: theme == null ? void 0 : theme.direction,\n slots: {\n root: RootComponent\n },\n slotProps: slotProps != null ? slotProps : componentsProps\n }, otherProps, {\n ref: ref\n }));\n});\nprocess.env.NODE_ENV !== \"production\" ? Popper.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * An HTML element, [virtualElement](https://popper.js.org/docs/v2/virtual-elements/),\n * or a function that returns either.\n * It's used to set the position of the popper.\n * The return value will passed as the reference object of the Popper instance.\n */\n anchorEl: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.object, PropTypes.func]),\n /**\n * Popper render function or node.\n */\n children: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.node, PropTypes.func]),\n /**\n * The component used for the root node.\n * Either a string to use a HTML element or a component.\n */\n component: PropTypes.elementType,\n /**\n * The components used for each slot inside the Popper.\n * Either a string to use a HTML element or a component.\n * @default {}\n */\n components: PropTypes.shape({\n Root: PropTypes.elementType\n }),\n /**\n * The props used for each slot inside the Popper.\n * @default {}\n */\n componentsProps: PropTypes.shape({\n root: PropTypes.oneOfType([PropTypes.func, PropTypes.object])\n }),\n /**\n * An HTML element or function that returns one.\n * The `container` will have the portal children appended to it.\n *\n * You can also provide a callback, which is called in a React layout effect.\n * This lets you set the container from a ref, and also makes server-side rendering possible.\n *\n * By default, it uses the body of the top-level document object,\n * so it's simply `document.body` most of the time.\n */\n container: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.func]),\n /**\n * The `children` will be under the DOM hierarchy of the parent component.\n * @default false\n */\n disablePortal: PropTypes.bool,\n /**\n * Always keep the children in the DOM.\n * This prop can be useful in SEO situation or\n * when you want to maximize the responsiveness of the Popper.\n * @default false\n */\n keepMounted: PropTypes.bool,\n /**\n * Popper.js is based on a \"plugin-like\" architecture,\n * most of its features are fully encapsulated \"modifiers\".\n *\n * A modifier is a function that is called each time Popper.js needs to\n * compute the position of the popper.\n * For this reason, modifiers should be very performant to avoid bottlenecks.\n * To learn how to create a modifier, [read the modifiers documentation](https://popper.js.org/docs/v2/modifiers/).\n */\n modifiers: PropTypes.arrayOf(PropTypes.shape({\n data: PropTypes.object,\n effect: PropTypes.func,\n enabled: PropTypes.bool,\n fn: PropTypes.func,\n name: PropTypes.any,\n options: PropTypes.object,\n phase: PropTypes.oneOf(['afterMain', 'afterRead', 'afterWrite', 'beforeMain', 'beforeRead', 'beforeWrite', 'main', 'read', 'write']),\n requires: PropTypes.arrayOf(PropTypes.string),\n requiresIfExists: PropTypes.arrayOf(PropTypes.string)\n })),\n /**\n * If `true`, the component is shown.\n */\n open: PropTypes.bool.isRequired,\n /**\n * Popper placement.\n * @default 'bottom'\n */\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n /**\n * Options provided to the [`Popper.js`](https://popper.js.org/docs/v2/constructors/#options) instance.\n * @default {}\n */\n popperOptions: PropTypes.shape({\n modifiers: PropTypes.array,\n onFirstUpdate: PropTypes.func,\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n strategy: PropTypes.oneOf(['absolute', 'fixed'])\n }),\n /**\n * A ref that points to the used popper instance.\n */\n popperRef: refType,\n /**\n * The props used for each slot inside the Popper.\n * @default {}\n */\n slotProps: PropTypes.shape({\n root: PropTypes.oneOfType([PropTypes.func, PropTypes.object])\n }),\n /**\n * The components used for each slot inside the Popper.\n * Either a string to use a HTML element or a component.\n * @default {}\n */\n slots: PropTypes.shape({\n root: PropTypes.elementType\n }),\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Help supporting a react-transition-group/Transition component.\n * @default false\n */\n transition: PropTypes.bool\n} : void 0;\nexport default Popper;","import generateUtilityClasses from '@mui/utils/generateUtilityClasses';\nimport generateUtilityClass from '@mui/utils/generateUtilityClass';\nexport function getTooltipUtilityClass(slot) {\n return generateUtilityClass('MuiTooltip', slot);\n}\nconst tooltipClasses = generateUtilityClasses('MuiTooltip', ['popper', 'popperInteractive', 'popperArrow', 'popperClose', 'tooltip', 'tooltipArrow', 'touch', 'tooltipPlacementLeft', 'tooltipPlacementRight', 'tooltipPlacementTop', 'tooltipPlacementBottom', 'arrow']);\nexport default tooltipClasses;","'use client';\n\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nconst _excluded = [\"arrow\", \"children\", \"classes\", \"components\", \"componentsProps\", \"describeChild\", \"disableFocusListener\", \"disableHoverListener\", \"disableInteractive\", \"disableTouchListener\", \"enterDelay\", \"enterNextDelay\", \"enterTouchDelay\", \"followCursor\", \"id\", \"leaveDelay\", \"leaveTouchDelay\", \"onClose\", \"onOpen\", \"open\", \"placement\", \"PopperComponent\", \"PopperProps\", \"slotProps\", \"slots\", \"title\", \"TransitionComponent\", \"TransitionProps\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport clsx from 'clsx';\nimport { elementAcceptingRef, unstable_useTimeout as useTimeout, unstable_Timeout as Timeout } from '@mui/utils';\nimport { unstable_composeClasses as composeClasses, appendOwnerState } from '@mui/base';\nimport { alpha } from '@mui/system';\nimport styled from '../styles/styled';\nimport useTheme from '../styles/useTheme';\nimport useThemeProps from '../styles/useThemeProps';\nimport capitalize from '../utils/capitalize';\nimport Grow from '../Grow';\nimport Popper from '../Popper';\nimport useEventCallback from '../utils/useEventCallback';\nimport useForkRef from '../utils/useForkRef';\nimport useId from '../utils/useId';\nimport useIsFocusVisible from '../utils/useIsFocusVisible';\nimport useControlled from '../utils/useControlled';\nimport tooltipClasses, { getTooltipUtilityClass } from './tooltipClasses';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nimport { jsxs as _jsxs } from \"react/jsx-runtime\";\nfunction round(value) {\n return Math.round(value * 1e5) / 1e5;\n}\nconst useUtilityClasses = ownerState => {\n const {\n classes,\n disableInteractive,\n arrow,\n touch,\n placement\n } = ownerState;\n const slots = {\n popper: ['popper', !disableInteractive && 'popperInteractive', arrow && 'popperArrow'],\n tooltip: ['tooltip', arrow && 'tooltipArrow', touch && 'touch', `tooltipPlacement${capitalize(placement.split('-')[0])}`],\n arrow: ['arrow']\n };\n return composeClasses(slots, getTooltipUtilityClass, classes);\n};\nconst TooltipPopper = styled(Popper, {\n name: 'MuiTooltip',\n slot: 'Popper',\n overridesResolver: (props, styles) => {\n const {\n ownerState\n } = props;\n return [styles.popper, !ownerState.disableInteractive && styles.popperInteractive, ownerState.arrow && styles.popperArrow, !ownerState.open && styles.popperClose];\n }\n})(({\n theme,\n ownerState,\n open\n}) => _extends({\n zIndex: (theme.vars || theme).zIndex.tooltip,\n pointerEvents: 'none'\n}, !ownerState.disableInteractive && {\n pointerEvents: 'auto'\n}, !open && {\n pointerEvents: 'none'\n}, ownerState.arrow && {\n [`&[data-popper-placement*=\"bottom\"] .${tooltipClasses.arrow}`]: {\n top: 0,\n marginTop: '-0.71em',\n '&::before': {\n transformOrigin: '0 100%'\n }\n },\n [`&[data-popper-placement*=\"top\"] .${tooltipClasses.arrow}`]: {\n bottom: 0,\n marginBottom: '-0.71em',\n '&::before': {\n transformOrigin: '100% 0'\n }\n },\n [`&[data-popper-placement*=\"right\"] .${tooltipClasses.arrow}`]: _extends({}, !ownerState.isRtl ? {\n left: 0,\n marginLeft: '-0.71em'\n } : {\n right: 0,\n marginRight: '-0.71em'\n }, {\n height: '1em',\n width: '0.71em',\n '&::before': {\n transformOrigin: '100% 100%'\n }\n }),\n [`&[data-popper-placement*=\"left\"] .${tooltipClasses.arrow}`]: _extends({}, !ownerState.isRtl ? {\n right: 0,\n marginRight: '-0.71em'\n } : {\n left: 0,\n marginLeft: '-0.71em'\n }, {\n height: '1em',\n width: '0.71em',\n '&::before': {\n transformOrigin: '0 0'\n }\n })\n}));\nconst TooltipTooltip = styled('div', {\n name: 'MuiTooltip',\n slot: 'Tooltip',\n overridesResolver: (props, styles) => {\n const {\n ownerState\n } = props;\n return [styles.tooltip, ownerState.touch && styles.touch, ownerState.arrow && styles.tooltipArrow, styles[`tooltipPlacement${capitalize(ownerState.placement.split('-')[0])}`]];\n }\n})(({\n theme,\n ownerState\n}) => _extends({\n backgroundColor: theme.vars ? theme.vars.palette.Tooltip.bg : alpha(theme.palette.grey[700], 0.92),\n borderRadius: (theme.vars || theme).shape.borderRadius,\n color: (theme.vars || theme).palette.common.white,\n fontFamily: theme.typography.fontFamily,\n padding: '4px 8px',\n fontSize: theme.typography.pxToRem(11),\n maxWidth: 300,\n margin: 2,\n wordWrap: 'break-word',\n fontWeight: theme.typography.fontWeightMedium\n}, ownerState.arrow && {\n position: 'relative',\n margin: 0\n}, ownerState.touch && {\n padding: '8px 16px',\n fontSize: theme.typography.pxToRem(14),\n lineHeight: `${round(16 / 14)}em`,\n fontWeight: theme.typography.fontWeightRegular\n}, {\n [`.${tooltipClasses.popper}[data-popper-placement*=\"left\"] &`]: _extends({\n transformOrigin: 'right center'\n }, !ownerState.isRtl ? _extends({\n marginRight: '14px'\n }, ownerState.touch && {\n marginRight: '24px'\n }) : _extends({\n marginLeft: '14px'\n }, ownerState.touch && {\n marginLeft: '24px'\n })),\n [`.${tooltipClasses.popper}[data-popper-placement*=\"right\"] &`]: _extends({\n transformOrigin: 'left center'\n }, !ownerState.isRtl ? _extends({\n marginLeft: '14px'\n }, ownerState.touch && {\n marginLeft: '24px'\n }) : _extends({\n marginRight: '14px'\n }, ownerState.touch && {\n marginRight: '24px'\n })),\n [`.${tooltipClasses.popper}[data-popper-placement*=\"top\"] &`]: _extends({\n transformOrigin: 'center bottom',\n marginBottom: '14px'\n }, ownerState.touch && {\n marginBottom: '24px'\n }),\n [`.${tooltipClasses.popper}[data-popper-placement*=\"bottom\"] &`]: _extends({\n transformOrigin: 'center top',\n marginTop: '14px'\n }, ownerState.touch && {\n marginTop: '24px'\n })\n}));\nconst TooltipArrow = styled('span', {\n name: 'MuiTooltip',\n slot: 'Arrow',\n overridesResolver: (props, styles) => styles.arrow\n})(({\n theme\n}) => ({\n overflow: 'hidden',\n position: 'absolute',\n width: '1em',\n height: '0.71em' /* = width / sqrt(2) = (length of the hypotenuse) */,\n boxSizing: 'border-box',\n color: theme.vars ? theme.vars.palette.Tooltip.bg : alpha(theme.palette.grey[700], 0.9),\n '&::before': {\n content: '\"\"',\n margin: 'auto',\n display: 'block',\n width: '100%',\n height: '100%',\n backgroundColor: 'currentColor',\n transform: 'rotate(45deg)'\n }\n}));\nlet hystersisOpen = false;\nconst hystersisTimer = new Timeout();\nlet cursorPosition = {\n x: 0,\n y: 0\n};\nexport function testReset() {\n hystersisOpen = false;\n hystersisTimer.clear();\n}\nfunction composeEventHandler(handler, eventHandler) {\n return event => {\n if (eventHandler) {\n eventHandler(event);\n }\n handler(event);\n };\n}\n\n// TODO v6: Remove PopperComponent, PopperProps, TransitionComponent and TransitionProps.\nconst Tooltip = /*#__PURE__*/React.forwardRef(function Tooltip(inProps, ref) {\n var _ref, _slots$popper, _ref2, _ref3, _slots$transition, _ref4, _slots$tooltip, _ref5, _slots$arrow, _slotProps$popper, _ref6, _slotProps$popper2, _slotProps$transition, _slotProps$tooltip, _ref7, _slotProps$tooltip2, _slotProps$arrow, _ref8, _slotProps$arrow2;\n const props = useThemeProps({\n props: inProps,\n name: 'MuiTooltip'\n });\n const {\n arrow = false,\n children: childrenProp,\n components = {},\n componentsProps = {},\n describeChild = false,\n disableFocusListener = false,\n disableHoverListener = false,\n disableInteractive: disableInteractiveProp = false,\n disableTouchListener = false,\n enterDelay = 100,\n enterNextDelay = 0,\n enterTouchDelay = 700,\n followCursor = false,\n id: idProp,\n leaveDelay = 0,\n leaveTouchDelay = 1500,\n onClose,\n onOpen,\n open: openProp,\n placement = 'bottom',\n PopperComponent: PopperComponentProp,\n PopperProps = {},\n slotProps = {},\n slots = {},\n title,\n TransitionComponent: TransitionComponentProp = Grow,\n TransitionProps\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n\n // to prevent runtime errors, developers will need to provide a child as a React element anyway.\n const children = /*#__PURE__*/React.isValidElement(childrenProp) ? childrenProp : /*#__PURE__*/_jsx(\"span\", {\n children: childrenProp\n });\n const theme = useTheme();\n const isRtl = theme.direction === 'rtl';\n const [childNode, setChildNode] = React.useState();\n const [arrowRef, setArrowRef] = React.useState(null);\n const ignoreNonTouchEvents = React.useRef(false);\n const disableInteractive = disableInteractiveProp || followCursor;\n const closeTimer = useTimeout();\n const enterTimer = useTimeout();\n const leaveTimer = useTimeout();\n const touchTimer = useTimeout();\n const [openState, setOpenState] = useControlled({\n controlled: openProp,\n default: false,\n name: 'Tooltip',\n state: 'open'\n });\n let open = openState;\n if (process.env.NODE_ENV !== 'production') {\n // eslint-disable-next-line react-hooks/rules-of-hooks\n const {\n current: isControlled\n } = React.useRef(openProp !== undefined);\n\n // eslint-disable-next-line react-hooks/rules-of-hooks\n React.useEffect(() => {\n if (childNode && childNode.disabled && !isControlled && title !== '' && childNode.tagName.toLowerCase() === 'button') {\n console.error(['MUI: You are providing a disabled `button` child to the Tooltip component.', 'A disabled element does not fire events.', \"Tooltip needs to listen to the child element's events to display the title.\", '', 'Add a simple wrapper element, such as a `span`.'].join('\\n'));\n }\n }, [title, childNode, isControlled]);\n }\n const id = useId(idProp);\n const prevUserSelect = React.useRef();\n const stopTouchInteraction = useEventCallback(() => {\n if (prevUserSelect.current !== undefined) {\n document.body.style.WebkitUserSelect = prevUserSelect.current;\n prevUserSelect.current = undefined;\n }\n touchTimer.clear();\n });\n React.useEffect(() => stopTouchInteraction, [stopTouchInteraction]);\n const handleOpen = event => {\n hystersisTimer.clear();\n hystersisOpen = true;\n\n // The mouseover event will trigger for every nested element in the tooltip.\n // We can skip rerendering when the tooltip is already open.\n // We are using the mouseover event instead of the mouseenter event to fix a hide/show issue.\n setOpenState(true);\n if (onOpen && !open) {\n onOpen(event);\n }\n };\n const handleClose = useEventCallback(\n /**\n * @param {React.SyntheticEvent | Event} event\n */\n event => {\n hystersisTimer.start(800 + leaveDelay, () => {\n hystersisOpen = false;\n });\n setOpenState(false);\n if (onClose && open) {\n onClose(event);\n }\n closeTimer.start(theme.transitions.duration.shortest, () => {\n ignoreNonTouchEvents.current = false;\n });\n });\n const handleEnter = event => {\n if (ignoreNonTouchEvents.current && event.type !== 'touchstart') {\n return;\n }\n\n // Remove the title ahead of time.\n // We don't want to wait for the next render commit.\n // We would risk displaying two tooltips at the same time (native + this one).\n if (childNode) {\n childNode.removeAttribute('title');\n }\n enterTimer.clear();\n leaveTimer.clear();\n if (enterDelay || hystersisOpen && enterNextDelay) {\n enterTimer.start(hystersisOpen ? enterNextDelay : enterDelay, () => {\n handleOpen(event);\n });\n } else {\n handleOpen(event);\n }\n };\n const handleLeave = event => {\n enterTimer.clear();\n leaveTimer.start(leaveDelay, () => {\n handleClose(event);\n });\n };\n const {\n isFocusVisibleRef,\n onBlur: handleBlurVisible,\n onFocus: handleFocusVisible,\n ref: focusVisibleRef\n } = useIsFocusVisible();\n // We don't necessarily care about the focusVisible state (which is safe to access via ref anyway).\n // We just need to re-render the Tooltip if the focus-visible state changes.\n const [, setChildIsFocusVisible] = React.useState(false);\n const handleBlur = event => {\n handleBlurVisible(event);\n if (isFocusVisibleRef.current === false) {\n setChildIsFocusVisible(false);\n handleLeave(event);\n }\n };\n const handleFocus = event => {\n // Workaround for https://github.com/facebook/react/issues/7769\n // The autoFocus of React might trigger the event before the componentDidMount.\n // We need to account for this eventuality.\n if (!childNode) {\n setChildNode(event.currentTarget);\n }\n handleFocusVisible(event);\n if (isFocusVisibleRef.current === true) {\n setChildIsFocusVisible(true);\n handleEnter(event);\n }\n };\n const detectTouchStart = event => {\n ignoreNonTouchEvents.current = true;\n const childrenProps = children.props;\n if (childrenProps.onTouchStart) {\n childrenProps.onTouchStart(event);\n }\n };\n const handleMouseOver = handleEnter;\n const handleMouseLeave = handleLeave;\n const handleTouchStart = event => {\n detectTouchStart(event);\n leaveTimer.clear();\n closeTimer.clear();\n stopTouchInteraction();\n prevUserSelect.current = document.body.style.WebkitUserSelect;\n // Prevent iOS text selection on long-tap.\n document.body.style.WebkitUserSelect = 'none';\n touchTimer.start(enterTouchDelay, () => {\n document.body.style.WebkitUserSelect = prevUserSelect.current;\n handleEnter(event);\n });\n };\n const handleTouchEnd = event => {\n if (children.props.onTouchEnd) {\n children.props.onTouchEnd(event);\n }\n stopTouchInteraction();\n leaveTimer.start(leaveTouchDelay, () => {\n handleClose(event);\n });\n };\n React.useEffect(() => {\n if (!open) {\n return undefined;\n }\n\n /**\n * @param {KeyboardEvent} nativeEvent\n */\n function handleKeyDown(nativeEvent) {\n // IE11, Edge (prior to using Bink?) use 'Esc'\n if (nativeEvent.key === 'Escape' || nativeEvent.key === 'Esc') {\n handleClose(nativeEvent);\n }\n }\n document.addEventListener('keydown', handleKeyDown);\n return () => {\n document.removeEventListener('keydown', handleKeyDown);\n };\n }, [handleClose, open]);\n const handleRef = useForkRef(children.ref, focusVisibleRef, setChildNode, ref);\n\n // There is no point in displaying an empty tooltip.\n // So we exclude all falsy values, except 0, which is valid.\n if (!title && title !== 0) {\n open = false;\n }\n const popperRef = React.useRef();\n const handleMouseMove = event => {\n const childrenProps = children.props;\n if (childrenProps.onMouseMove) {\n childrenProps.onMouseMove(event);\n }\n cursorPosition = {\n x: event.clientX,\n y: event.clientY\n };\n if (popperRef.current) {\n popperRef.current.update();\n }\n };\n const nameOrDescProps = {};\n const titleIsString = typeof title === 'string';\n if (describeChild) {\n nameOrDescProps.title = !open && titleIsString && !disableHoverListener ? title : null;\n nameOrDescProps['aria-describedby'] = open ? id : null;\n } else {\n nameOrDescProps['aria-label'] = titleIsString ? title : null;\n nameOrDescProps['aria-labelledby'] = open && !titleIsString ? id : null;\n }\n const childrenProps = _extends({}, nameOrDescProps, other, children.props, {\n className: clsx(other.className, children.props.className),\n onTouchStart: detectTouchStart,\n ref: handleRef\n }, followCursor ? {\n onMouseMove: handleMouseMove\n } : {});\n if (process.env.NODE_ENV !== 'production') {\n childrenProps['data-mui-internal-clone-element'] = true;\n\n // eslint-disable-next-line react-hooks/rules-of-hooks\n React.useEffect(() => {\n if (childNode && !childNode.getAttribute('data-mui-internal-clone-element')) {\n console.error(['MUI: The `children` component of the Tooltip is not forwarding its props correctly.', 'Please make sure that props are spread on the same element that the ref is applied to.'].join('\\n'));\n }\n }, [childNode]);\n }\n const interactiveWrapperListeners = {};\n if (!disableTouchListener) {\n childrenProps.onTouchStart = handleTouchStart;\n childrenProps.onTouchEnd = handleTouchEnd;\n }\n if (!disableHoverListener) {\n childrenProps.onMouseOver = composeEventHandler(handleMouseOver, childrenProps.onMouseOver);\n childrenProps.onMouseLeave = composeEventHandler(handleMouseLeave, childrenProps.onMouseLeave);\n if (!disableInteractive) {\n interactiveWrapperListeners.onMouseOver = handleMouseOver;\n interactiveWrapperListeners.onMouseLeave = handleMouseLeave;\n }\n }\n if (!disableFocusListener) {\n childrenProps.onFocus = composeEventHandler(handleFocus, childrenProps.onFocus);\n childrenProps.onBlur = composeEventHandler(handleBlur, childrenProps.onBlur);\n if (!disableInteractive) {\n interactiveWrapperListeners.onFocus = handleFocus;\n interactiveWrapperListeners.onBlur = handleBlur;\n }\n }\n if (process.env.NODE_ENV !== 'production') {\n if (children.props.title) {\n console.error(['MUI: You have provided a `title` prop to the child of .', `Remove this title prop \\`${children.props.title}\\` or the Tooltip component.`].join('\\n'));\n }\n }\n const popperOptions = React.useMemo(() => {\n var _PopperProps$popperOp;\n let tooltipModifiers = [{\n name: 'arrow',\n enabled: Boolean(arrowRef),\n options: {\n element: arrowRef,\n padding: 4\n }\n }];\n if ((_PopperProps$popperOp = PopperProps.popperOptions) != null && _PopperProps$popperOp.modifiers) {\n tooltipModifiers = tooltipModifiers.concat(PopperProps.popperOptions.modifiers);\n }\n return _extends({}, PopperProps.popperOptions, {\n modifiers: tooltipModifiers\n });\n }, [arrowRef, PopperProps]);\n const ownerState = _extends({}, props, {\n isRtl,\n arrow,\n disableInteractive,\n placement,\n PopperComponentProp,\n touch: ignoreNonTouchEvents.current\n });\n const classes = useUtilityClasses(ownerState);\n const PopperComponent = (_ref = (_slots$popper = slots.popper) != null ? _slots$popper : components.Popper) != null ? _ref : TooltipPopper;\n const TransitionComponent = (_ref2 = (_ref3 = (_slots$transition = slots.transition) != null ? _slots$transition : components.Transition) != null ? _ref3 : TransitionComponentProp) != null ? _ref2 : Grow;\n const TooltipComponent = (_ref4 = (_slots$tooltip = slots.tooltip) != null ? _slots$tooltip : components.Tooltip) != null ? _ref4 : TooltipTooltip;\n const ArrowComponent = (_ref5 = (_slots$arrow = slots.arrow) != null ? _slots$arrow : components.Arrow) != null ? _ref5 : TooltipArrow;\n const popperProps = appendOwnerState(PopperComponent, _extends({}, PopperProps, (_slotProps$popper = slotProps.popper) != null ? _slotProps$popper : componentsProps.popper, {\n className: clsx(classes.popper, PopperProps == null ? void 0 : PopperProps.className, (_ref6 = (_slotProps$popper2 = slotProps.popper) != null ? _slotProps$popper2 : componentsProps.popper) == null ? void 0 : _ref6.className)\n }), ownerState);\n const transitionProps = appendOwnerState(TransitionComponent, _extends({}, TransitionProps, (_slotProps$transition = slotProps.transition) != null ? _slotProps$transition : componentsProps.transition), ownerState);\n const tooltipProps = appendOwnerState(TooltipComponent, _extends({}, (_slotProps$tooltip = slotProps.tooltip) != null ? _slotProps$tooltip : componentsProps.tooltip, {\n className: clsx(classes.tooltip, (_ref7 = (_slotProps$tooltip2 = slotProps.tooltip) != null ? _slotProps$tooltip2 : componentsProps.tooltip) == null ? void 0 : _ref7.className)\n }), ownerState);\n const tooltipArrowProps = appendOwnerState(ArrowComponent, _extends({}, (_slotProps$arrow = slotProps.arrow) != null ? _slotProps$arrow : componentsProps.arrow, {\n className: clsx(classes.arrow, (_ref8 = (_slotProps$arrow2 = slotProps.arrow) != null ? _slotProps$arrow2 : componentsProps.arrow) == null ? void 0 : _ref8.className)\n }), ownerState);\n return /*#__PURE__*/_jsxs(React.Fragment, {\n children: [/*#__PURE__*/React.cloneElement(children, childrenProps), /*#__PURE__*/_jsx(PopperComponent, _extends({\n as: PopperComponentProp != null ? PopperComponentProp : Popper,\n placement: placement,\n anchorEl: followCursor ? {\n getBoundingClientRect: () => ({\n top: cursorPosition.y,\n left: cursorPosition.x,\n right: cursorPosition.x,\n bottom: cursorPosition.y,\n width: 0,\n height: 0\n })\n } : childNode,\n popperRef: popperRef,\n open: childNode ? open : false,\n id: id,\n transition: true\n }, interactiveWrapperListeners, popperProps, {\n popperOptions: popperOptions,\n children: ({\n TransitionProps: TransitionPropsInner\n }) => /*#__PURE__*/_jsx(TransitionComponent, _extends({\n timeout: theme.transitions.duration.shorter\n }, TransitionPropsInner, transitionProps, {\n children: /*#__PURE__*/_jsxs(TooltipComponent, _extends({}, tooltipProps, {\n children: [title, arrow ? /*#__PURE__*/_jsx(ArrowComponent, _extends({}, tooltipArrowProps, {\n ref: setArrowRef\n })) : null]\n }))\n }))\n }))]\n });\n});\nprocess.env.NODE_ENV !== \"production\" ? Tooltip.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the d.ts file and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * If `true`, adds an arrow to the tooltip.\n * @default false\n */\n arrow: PropTypes.bool,\n /**\n * Tooltip reference element.\n */\n children: elementAcceptingRef.isRequired,\n /**\n * Override or extend the styles applied to the component.\n */\n classes: PropTypes.object,\n /**\n * @ignore\n */\n className: PropTypes.string,\n /**\n * The components used for each slot inside.\n *\n * This prop is an alias for the `slots` prop.\n * It's recommended to use the `slots` prop instead.\n *\n * @default {}\n */\n components: PropTypes.shape({\n Arrow: PropTypes.elementType,\n Popper: PropTypes.elementType,\n Tooltip: PropTypes.elementType,\n Transition: PropTypes.elementType\n }),\n /**\n * The extra props for the slot components.\n * You can override the existing props or add new ones.\n *\n * This prop is an alias for the `slotProps` prop.\n * It's recommended to use the `slotProps` prop instead, as `componentsProps` will be deprecated in the future.\n *\n * @default {}\n */\n componentsProps: PropTypes.shape({\n arrow: PropTypes.object,\n popper: PropTypes.object,\n tooltip: PropTypes.object,\n transition: PropTypes.object\n }),\n /**\n * Set to `true` if the `title` acts as an accessible description.\n * By default the `title` acts as an accessible label for the child.\n * @default false\n */\n describeChild: PropTypes.bool,\n /**\n * Do not respond to focus-visible events.\n * @default false\n */\n disableFocusListener: PropTypes.bool,\n /**\n * Do not respond to hover events.\n * @default false\n */\n disableHoverListener: PropTypes.bool,\n /**\n * Makes a tooltip not interactive, i.e. it will close when the user\n * hovers over the tooltip before the `leaveDelay` is expired.\n * @default false\n */\n disableInteractive: PropTypes.bool,\n /**\n * Do not respond to long press touch events.\n * @default false\n */\n disableTouchListener: PropTypes.bool,\n /**\n * The number of milliseconds to wait before showing the tooltip.\n * This prop won't impact the enter touch delay (`enterTouchDelay`).\n * @default 100\n */\n enterDelay: PropTypes.number,\n /**\n * The number of milliseconds to wait before showing the tooltip when one was already recently opened.\n * @default 0\n */\n enterNextDelay: PropTypes.number,\n /**\n * The number of milliseconds a user must touch the element before showing the tooltip.\n * @default 700\n */\n enterTouchDelay: PropTypes.number,\n /**\n * If `true`, the tooltip follow the cursor over the wrapped element.\n * @default false\n */\n followCursor: PropTypes.bool,\n /**\n * This prop is used to help implement the accessibility logic.\n * If you don't provide this prop. It falls back to a randomly generated id.\n */\n id: PropTypes.string,\n /**\n * The number of milliseconds to wait before hiding the tooltip.\n * This prop won't impact the leave touch delay (`leaveTouchDelay`).\n * @default 0\n */\n leaveDelay: PropTypes.number,\n /**\n * The number of milliseconds after the user stops touching an element before hiding the tooltip.\n * @default 1500\n */\n leaveTouchDelay: PropTypes.number,\n /**\n * Callback fired when the component requests to be closed.\n *\n * @param {React.SyntheticEvent} event The event source of the callback.\n */\n onClose: PropTypes.func,\n /**\n * Callback fired when the component requests to be open.\n *\n * @param {React.SyntheticEvent} event The event source of the callback.\n */\n onOpen: PropTypes.func,\n /**\n * If `true`, the component is shown.\n */\n open: PropTypes.bool,\n /**\n * Tooltip placement.\n * @default 'bottom'\n */\n placement: PropTypes.oneOf(['bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n /**\n * The component used for the popper.\n * @default Popper\n */\n PopperComponent: PropTypes.elementType,\n /**\n * Props applied to the [`Popper`](/material-ui/api/popper/) element.\n * @default {}\n */\n PopperProps: PropTypes.object,\n /**\n * The extra props for the slot components.\n * You can override the existing props or add new ones.\n *\n * This prop is an alias for the `componentsProps` prop, which will be deprecated in the future.\n *\n * @default {}\n */\n slotProps: PropTypes.shape({\n arrow: PropTypes.object,\n popper: PropTypes.object,\n tooltip: PropTypes.object,\n transition: PropTypes.object\n }),\n /**\n * The components used for each slot inside.\n *\n * This prop is an alias for the `components` prop, which will be deprecated in the future.\n *\n * @default {}\n */\n slots: PropTypes.shape({\n arrow: PropTypes.elementType,\n popper: PropTypes.elementType,\n tooltip: PropTypes.elementType,\n transition: PropTypes.elementType\n }),\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Tooltip title. Zero-length titles string, undefined, null and false are never displayed.\n */\n title: PropTypes.node,\n /**\n * The component used for the transition.\n * [Follow this guide](/material-ui/transitions/#transitioncomponent-prop) to learn more about the requirements for this component.\n * @default Grow\n */\n TransitionComponent: PropTypes.elementType,\n /**\n * Props applied to the transition element.\n * By default, the element is based on this [`Transition`](http://reactcommunity.org/react-transition-group/transition/) component.\n */\n TransitionProps: PropTypes.object\n} : void 0;\nexport default Tooltip;","import '@/components/mui/menu-item.component.css';\nimport ArrowRightIcon from '@mui/icons-material/ArrowRight';\nimport {\n ListItemIcon as MuiListItemIcon,\n ListItemText as MuiListItemText,\n MenuItem as MuiMenuItem,\n} from '@mui/material';\nimport Tooltip from '@mui/material/Tooltip';\nimport { Localized, ReferencedItem, SingleColumnMenu } from 'platform-bible-utils';\nimport { MouseEvent, PropsWithChildren } from 'react';\n\ntype MenuItemInfoBase = {\n /** Text (displayable in the UI) as the name of the menu item */\n label: string;\n /** Text to display when the mouse hovers over the menu item */\n tooltip?: string;\n};\n\nexport type Command = MenuItemInfoBase & {\n /** Command to execute (string.string) */\n command: string;\n};\n\ntype SubMenu = MenuItemInfoBase & {\n /** Command to execute (string.string) */\n items: MenuItemInfo[];\n};\n\nexport interface CommandHandler {\n (command: Command): void;\n}\n\nexport type MenuPropsBase = {\n /*\n * The JSON defining the menu whose items are to be rendered. This will typically be one of the\n * menus in the \"defs\" in a Platform.Bible menu (see PlatformMenus). The schema for this is\n * menuDocumentSchema (at the end of menus.model.ts). Note that while this is a\n * \"SingleColumnMenu\", somewhat bizarrely, a MultiColumnMenu is a SingleColumnMenu, so it really\n * could be a MultiColumnMenu, in which case, column had better be defined so it can be used\n * to filter out the actual groups and items to display on the column.\n */\n menuDefinition: Localized;\n\n commandHandler: CommandHandler;\n\n /**\n * Additional action to perform when any menu item is clicked. Allows the caller to handle event\n * (e.g., to close the menu).\n */\n onClick?: (event: MouseEvent) => void;\n};\n\nexport type MenuItemListProps = MenuPropsBase & {\n /** Optional unique (column) identifier */\n columnId?: ReferencedItem;\n};\n\nexport type MenuItemProps = Omit &\n PropsWithChildren<{\n /** Optional unique identifier */\n id?: string;\n\n onClick: (event: MouseEvent) => void;\n }>;\n\ntype MenuItemInfo = (Command | SubMenu) & {\n /**\n * If specified, menu item will be inset if it does not have a leading icon.\n *\n * @default true\n */\n allowForLeadingIcons?: boolean;\n /**\n * If specified, the path to the icon image to display on the leading side of the menu text.\n *\n * @default undefined (no leading icon will be shown)\n */\n iconPathBefore?: string;\n /**\n * If specified, the path to the icon image to display on the trailing side of the menu text.\n *\n * @default undefined (no trailing icon will be shown)\n */\n iconPathAfter?: string;\n /**\n * If true, list item is focused during the first mount\n *\n * @default false\n */\n hasAutoFocus?: boolean;\n\n /** Additional css classes to help with unique styling of the menu item */\n className?: string;\n\n /**\n * If true, the menu item will appear disabled and it will not respond to clicks or mouse hovers.\n *\n * @default false\n */\n isDisabled?: boolean;\n\n /**\n * If true, compact vertical padding designed for keyboard and mouse input is used.\n *\n * @default true\n */\n isDense?: boolean;\n\n /**\n * If true, a right-arrow icon will be displayed (iconPathAfter, if specified, will be ignored).\n *\n * @default false\n */\n isSubMenuParent?: boolean;\n\n /**\n * If true, the left and right padding is removed\n *\n * @default false\n */\n hasDisabledGutters?: boolean;\n\n /**\n * If true, a 1px light border is added to bottom of menu item\n *\n * @default false\n */\n hasDivider?: boolean;\n\n /** Help identify which element has keyboard focus */\n focusVisibleClassName?: string;\n\n /** If it's a submenu, it should have the items property */\n items?: MenuItemInfo[];\n};\n\nfunction getIcon(icon: string | undefined, menuLabel: string, leading: boolean) {\n return icon ? (\n \n {`${leading\n \n ) : undefined;\n}\n\nexport default function MenuItem(props: MenuItemProps) {\n const {\n onClick,\n label,\n tooltip,\n allowForLeadingIcons = true,\n iconPathBefore = undefined,\n iconPathAfter = undefined,\n hasAutoFocus = false,\n className,\n isDisabled = false,\n isDense = true,\n isSubMenuParent = false,\n hasDisabledGutters = false,\n hasDivider = false,\n focusVisibleClassName,\n id,\n children,\n } = props;\n\n const menuItem = (\n \n {label ? (\n <>\n {getIcon(iconPathBefore, label, true)}\n \n {isSubMenuParent ? (\n \n \n \n ) : (\n getIcon(iconPathAfter, label, false)\n )}\n \n ) : (\n children\n )}\n \n );\n\n return tooltip ? (\n \n
    {menuItem}
    \n
    \n ) : (\n menuItem\n );\n}\n","import MenuItem, {\n MenuItemListProps,\n MenuItemProps,\n MenuPropsBase,\n} from '@/components/mui/menu-item.component';\nimport { Menu } from '@mui/material';\nimport {\n Localized,\n MenuGroupDetailsInSubMenu,\n MenuItemContainingCommand,\n MenuItemContainingSubmenu,\n OrderedExtensibleContainer,\n ReferencedItem,\n SingleColumnMenu,\n} from 'platform-bible-utils';\nimport { MouseEvent, useMemo, useState } from 'react';\n\n/**\n * All the exported types in this file should be regarded as \"internal\" (i.e., they should not be\n * exposed via index.ts).\n */\n\nexport type GroupedMenuPropsBase = MenuPropsBase & {\n /** Optional unique (column) identifier */\n columnId?: ReferencedItem;\n};\n\nexport type GroupedMenuItemListProps = MenuItemListProps & {\n /**\n * If the menuDefinition includes \"top-level\" groups (i.e., those that belong to a column as\n * opposed to those that belong to a submenu) that should not be included in the list, then this\n * array specifies which groups to include. Likewise, for a submenu, this list indicates which\n * groups are pertinent for that submenu. So then for a context menu this property need not be\n * specified since it is a top-level menu based on a \"true\" SingleColumnMenu (i.e., one that is\n * not a MultiColumnMenu).\n */\n includedGroups?: {\n id: string;\n group: Localized;\n }[];\n};\n\ninterface ItemInfo {\n item: Localized;\n isLastItemInGroup: boolean;\n}\n\ntype SubMenuProps = MenuPropsBase & {\n parentMenuItem: Localized;\n parentItemProps: Omit, 'iconPathAfter'>;\n};\n\nfunction getAllGroups(menuDefinition: Localized) {\n const groupEntries = Object.entries(menuDefinition.groups);\n // Convert array of entries to array of objects with id and group properties\n return groupEntries.map(([key, value]) => ({ id: key, group: value }));\n}\n\nfunction SubMenu(props: SubMenuProps) {\n const [anchorEl, setAnchorEl] = useState(undefined);\n\n const { parentMenuItem, parentItemProps, menuDefinition } = props;\n\n const handleParentMenuItemClick = (event: MouseEvent) => {\n setAnchorEl(event.currentTarget);\n };\n\n const handleClose = () => {\n setAnchorEl(undefined);\n };\n\n const renderSubMenuItems = () => {\n let includedGroups = getAllGroups(menuDefinition).filter((g) => 'menuItem' in g.group);\n\n // Ensure valid parent menu was provided. (If not, submenu will contain all groups!)\n if (!parentMenuItem?.id) throw new Error('A valid parent menu item is required for submenus.');\n\n // When laying out a submenu, only include groups associated with the provided parent menu.\n // Note: without the (annoying) redundant check that the included groups\n // have the menuItem field, TS doesn't think it exists.\n includedGroups = includedGroups.filter(\n (group) => 'menuItem' in group.group && group.group.menuItem === parentMenuItem.id,\n );\n\n return ;\n };\n\n return (\n <>\n \n \n {renderSubMenuItems()}\n \n \n );\n}\n\nconst getOrderedGroupItems = (\n groupId: string,\n allItems: Localized[],\n) => {\n // Filter items that belong to the specified group\n const itemsForGroup = allItems.filter((item) => item.group === groupId);\n // Sort items based on order\n const sortedItems = itemsForGroup.sort((a, b) => (a.order || 0) - (b.order || 0));\n return sortedItems;\n};\n\n/**\n * This component is internal; it does not need to be exposed to the outside world since it is not\n * useful on its own. It is used to generate and lay out the MenuItems that appear either on a\n * top-level menu (in a GridMenu or ContextMenu) or in a submenu.\n */\nexport default function GroupedMenuItemList(menuProps: GroupedMenuItemListProps) {\n const { menuDefinition, onClick, commandHandler, includedGroups } = menuProps;\n\n const { items, allowForLeadingIcons } = useMemo(() => {\n const groupsToInclude =\n includedGroups && includedGroups.length > 0\n ? includedGroups\n : // We're apparently laying out a single-column menu (presumably a context menu). In this\n // case, all groups should be included except ones that belong to a submenu.\n getAllGroups(menuDefinition).filter((g) => !('menuItem' in g.group));\n\n const sortedGroups = Object.values(groupsToInclude).sort(\n (a, b) => (a.group.order || 0) - (b.group.order || 0),\n );\n\n const itemArray: ItemInfo[] = [];\n\n sortedGroups.forEach((group) => {\n getOrderedGroupItems(group.id, menuDefinition.items).forEach((item) =>\n itemArray.push({ item, isLastItemInGroup: false }),\n );\n if (itemArray.length > 0) itemArray[itemArray.length - 1].isLastItemInGroup = true;\n });\n\n // No divider after last item in final group.\n if (itemArray.length > 0) itemArray[itemArray.length - 1].isLastItemInGroup = false;\n\n const allowSpaceForLeadingIcons = itemArray.some(\n (i) => 'iconPathBefore' in i.item && i.item.iconPathBefore,\n );\n\n return { items: itemArray, allowForLeadingIcons: allowSpaceForLeadingIcons };\n }, [includedGroups, menuDefinition]);\n\n // Create props for MenuItem component including setting hasDivider for the last item in a group\n const createMenuItemProps = ({ item, isLastItemInGroup }: ItemInfo) => {\n const menuItemProps = {\n className: 'papi-menu-item',\n label: item.label,\n tooltip: item.tooltip,\n iconPathBefore: 'iconPathBefore' in item ? item.iconPathBefore : undefined,\n iconPathAfter: 'iconPathAfter' in item ? item.iconPathAfter : undefined,\n hasDivider: isLastItemInGroup, // Set hasDivider to true for the last item in a group\n allowForLeadingIcons,\n };\n\n return menuItemProps;\n };\n\n const [firstItem] = items;\n\n if (!firstItem) return
    ;\n\n const divKey = firstItem.item.group;\n\n return (\n
    \n {items.map((itemInfo, index) => {\n const { item } = itemInfo;\n const menuItemProps = createMenuItemProps(itemInfo);\n if ('command' in item) {\n const key = item.group + index;\n return (\n ) => {\n onClick?.(event);\n commandHandler(item);\n }}\n {...menuItemProps}\n />\n );\n }\n return (\n \n );\n })}\n
    \n );\n}\n","import GroupedMenuItemList from '@/components/mui/grouped-menu-item-list.component';\nimport { MenuItemListProps } from '@/components/mui/menu-item.component';\nimport { MultiColumnMenu } from 'platform-bible-utils';\n\n/**\n * This component is internal; it does not need to be exposed to the outside world since it is not\n * useful on its own. Use either GridMenu or ContextMenu.\n */\nexport default function TopLevelMenu(props: MenuItemListProps) {\n const { menuDefinition, columnId } = props;\n\n const groupEntries = Object.entries(menuDefinition.groups);\n // Convert array of entries to array of objects with id and group properties\n const groups = groupEntries.map(([key, value]) => ({ id: key, group: value }));\n let includedGroups = groups.filter((g) => 'column' in g.group);\n\n // Check if column is provided and menuDefinition is a MultiColumnMenu\n if (\n columnId &&\n 'columns' in menuDefinition &&\n // Without this type assertion, TS doesn't know what columns is.\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n (menuDefinition as MultiColumnMenu).columns[columnId]\n ) {\n // When laying out a single column in a MultiColumnMenu, only include groups associated with\n // the provided column. Note: without the (annoying) redundant check that the included groups\n // have the colum field, TS doesn't think it exists.\n includedGroups = includedGroups.filter(\n (g) => 'column' in g.group && g.group.column === columnId,\n );\n }\n\n return ;\n}\n","import '@/components/mui/grid-menu.component.css';\nimport { GroupedMenuPropsBase } from '@/components/mui/grouped-menu-item-list.component';\nimport { CommandHandler } from '@/components/mui/menu-item.component';\nimport TopLevelMenu from '@/components/mui/top-level-menu.component';\nimport { Grid, List } from '@mui/material';\nimport {\n Localized,\n MenuColumnWithHeader,\n MultiColumnMenu,\n ReferencedItem,\n} from 'platform-bible-utils';\nimport { useMemo } from 'react';\n\ntype ColumnInfo = {\n /*\n * The ID (`${string}.${string}`) of a specific menu column.\n */\n id: ReferencedItem;\n\n /*\n * Metadata (label, order, etc.) for a specific menu column.\n */\n metadata: Localized;\n};\n\ntype MenuColumnProps = ColumnInfo &\n GroupedMenuPropsBase & {\n /** Additional css classes to help with unique styling of the menu column */\n className?: string;\n };\n\nexport type GridMenuInfo = {\n /** The menu object containing information about the columns, groups, and items to display. */\n multiColumnMenu: Localized;\n};\n\nexport type GridMenuProps = GridMenuInfo & {\n /** Optional unique identifier */\n id?: string;\n\n commandHandler: CommandHandler;\n\n /** Additional css classes to help with unique styling of the grid menu */\n className?: string;\n};\n\nfunction MenuColumn({\n commandHandler,\n menuDefinition,\n id,\n metadata,\n onClick,\n className,\n}: MenuColumnProps) {\n return (\n \n

    \n {metadata.label}\n

    \n {/* It would seem as though this List component were unnecessary, since it only contains one\n thing, but the \"dense\" property does affect the layout of the items (in a way I don't fully\n understand). There might be a better way. */}\n \n \n \n \n );\n}\n\nexport default function GridMenu({\n commandHandler,\n className,\n multiColumnMenu,\n id,\n}: GridMenuProps) {\n const { columns } = multiColumnMenu;\n\n const sortedColumns = useMemo(() => {\n const columnNumbers = new Map();\n Object.getOwnPropertyNames(columns).forEach((columnName: string) => {\n // We know for sure there is a (boolean) property 'isExtensible' that we are not interested in.\n if (columnName === 'isExtensible') return;\n // TS doesn't allow `columnName` above to be a ReferencedItem even though the type says it is\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const columnId = columnName as ReferencedItem;\n const column = columns[columnId];\n // As of right now (and hopefully forever after), all remaining properties of the\n // ColumnsWithHeaders object are columns whose property names are the IDs of the columns.\n // This is an additional (redundant) sanity check. Specifically we're interested in\n // MenuColumnWithHeader objects, which TypeScript now \"knows\" we have, but at runtime all we\n // can check for is that it's an object with a valid numeric order field. That's likely good\n // enough.\n if (\n typeof column === 'object' &&\n typeof column.order === 'number' &&\n !Number.isNaN(column.order)\n )\n columnNumbers.set(column.order, { id: columnId, metadata: column });\n else\n console.warn(\n `Property ${columnName} (${typeof column}) on menu ${id} is not a valid column and is being ignored. This might indicate data corruption`,\n );\n });\n\n // Extract values and sort them based on the 'order' property\n return Array.from(columnNumbers.values()).sort((a, b) => {\n return (a.metadata.order || 0) - (b.metadata.order || 0);\n });\n }, [columns, id]);\n\n // We might need something like this if we need to be able to prevent empty columns\n // sortedColumns.filter((c) => multiColumnMenu.groups.some((g) => 'column' in g && (g as .column)...\n\n return (\n \n {sortedColumns.map((col, index) => (\n \n ))}\n \n );\n}\n","import { useEffect, useRef, useState } from 'react';\n\nexport type UsePromiseOptions = {\n /**\n * Whether to leave the value as the most recent resolved promise value or set it back to\n * defaultValue while running the promise again. Defaults to true\n */\n preserveValue?: boolean;\n};\n\n/** Set up defaults for options for usePromise hook */\nfunction getUsePromiseOptionsDefaults(options: UsePromiseOptions): UsePromiseOptions {\n return {\n preserveValue: true,\n ...options,\n };\n}\n\n/**\n * Awaits a promise and returns a loading value while the promise is unresolved\n *\n * @param promiseFactoryCallback A function that returns the promise to await. If this callback is\n * undefined, the current value will be returned (defaultValue unless it was previously changed\n * and `options.preserveValue` is true), and there will be no loading.\n *\n * WARNING: MUST BE STABLE - const or wrapped in useCallback. The reference must not be updated\n * every render\n * @param defaultValue The initial value to return while first awaiting the promise. If\n * `options.preserveValue` is false, this value is also shown while awaiting the promise on\n * subsequent calls.\n *\n * Note: this parameter is internally assigned to a `ref`, so changing it will not cause any hooks\n * to re-run with its new value. This means that, if the `promiseFactoryCallback` changes and\n * `options.preserveValue` is `false`, the returned value will be set to the current\n * `defaultValue`. However, the returned value will not be updated if`defaultValue` changes.\n * @param options Various options for adjusting how this hook runs the `promiseFactoryCallback`\n *\n * Note: this parameter is internally assigned to a `ref`, so changing it will not cause any hooks\n * to re-run with its new value. However, the latest `options.preserveValue` will always be used\n * appropriately to determine whether to preserve the returned value when changing the\n * `promiseFactoryCallback`\n * @returns `[value, isLoading]`\n *\n * - `value`: the current value for the promise, either the defaultValue or the resolved promise value\n * - `isLoading`: whether the promise is waiting to be resolved\n */\nconst usePromise = (\n promiseFactoryCallback: (() => Promise) | undefined,\n defaultValue: T,\n options: UsePromiseOptions = {},\n): [value: T, isLoading: boolean] => {\n // Use defaultValue as a ref so it doesn't update dependency arrays\n const defaultValueRef = useRef(defaultValue);\n defaultValueRef.current = defaultValue;\n // Use options as a ref so it doesn't update dependency arrays\n const optionsDefaultedRef = useRef(options);\n optionsDefaultedRef.current = getUsePromiseOptionsDefaults(optionsDefaultedRef.current);\n\n const [value, setValue] = useState(() => defaultValueRef.current);\n const [isLoading, setIsLoading] = useState(true);\n useEffect(() => {\n let promiseIsCurrent = true;\n // If a promiseFactoryCallback was provided, we are loading. Otherwise, there is no loading to do\n setIsLoading(!!promiseFactoryCallback);\n (async () => {\n // If there is a callback to run, run it\n if (promiseFactoryCallback) {\n const result = await promiseFactoryCallback();\n // If the promise was not already replaced, update the value\n if (promiseIsCurrent) {\n setValue(() => result);\n setIsLoading(false);\n }\n }\n })();\n\n return () => {\n // Mark this promise as old and not to be used\n promiseIsCurrent = false;\n if (!optionsDefaultedRef.current.preserveValue) setValue(() => defaultValueRef.current);\n };\n }, [promiseFactoryCallback]);\n\n return [value, isLoading];\n};\nexport default usePromise;\n","\"use client\";\n\nimport createSvgIcon from './utils/createSvgIcon';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nexport default createSvgIcon( /*#__PURE__*/_jsx(\"path\", {\n d: \"M3 18h18v-2H3zm0-5h18v-2H3zm0-7v2h18V6z\"\n}), 'Menu');","import GridMenu from '@/components/mui/grid-menu.component';\nimport { Command, CommandHandler } from '@/components/mui/menu-item.component';\nimport usePromise from '@/hooks/use-promise.hook';\nimport { Menu as MenuIcon } from '@mui/icons-material';\nimport { Drawer, IconButton } from '@mui/material';\nimport { Localized, MultiColumnMenu } from 'platform-bible-utils';\nimport {\n MouseEvent,\n MutableRefObject,\n PropsWithChildren,\n useCallback,\n useEffect,\n useState,\n} from 'react';\n\nexport interface MultiColumnMenuProvider {\n (isSupportAndDevelopment: boolean): Promise>;\n}\n\nexport type HamburgerMenuButtonProps = PropsWithChildren & {\n /** The handler to use for menu commands (and eventually toolbar commands). */\n commandHandler: CommandHandler;\n\n /**\n * Optional reference to the \"div\" container that determines the where the menu should appear. If\n * not defined, then (1,1) used.\n */\n containerRef?: MutableRefObject;\n\n /**\n * The delegate to use to get the menu data. If not specified or if it returns undefined, the data\n * in normalMenu or fullMenu property will be used.\n */\n menuProvider?: MultiColumnMenuProvider;\n\n /**\n * The menu data to show when the menu is opened if the menuProvider property is not defined.\n * (This allows for a default or test-only static menu to be used.)\n */\n normalMenu?: Localized;\n\n /**\n * The menu data to show for \"full\" menu (when opened with the SHIFT key pressed) if the\n * menuProvider property is not defined. (This allows for a default or test-only static menu to be\n * used.)\n */\n fullMenu?: Localized;\n\n /** Additional css class(es) to help with unique styling of the sub-components */\n className?: string;\n\n /** Value to use as prefix for ARIA labels on interactive sub-components */\n ariaLabelPrefix?: string;\n};\n\nexport default function HamburgerMenuButton({\n menuProvider,\n normalMenu,\n fullMenu,\n commandHandler,\n containerRef,\n className,\n ariaLabelPrefix,\n children,\n}: HamburgerMenuButtonProps) {\n const [isMenuOpen, setMenuOpen] = useState(false);\n const [showFullMenu, setShowFullMenu] = useState(false);\n\n const handleMenuItemClick = useCallback(() => {\n if (isMenuOpen) setMenuOpen(false);\n setShowFullMenu(false);\n }, [isMenuOpen]);\n\n const handleMenuButtonClick = useCallback((e: MouseEvent) => {\n e.stopPropagation();\n setMenuOpen((prevIsOpen) => {\n const isOpening = !prevIsOpen;\n if (isOpening && e.shiftKey) setShowFullMenu(true);\n else if (!isOpening) setShowFullMenu(false);\n return isOpening;\n });\n }, []);\n\n const menuCommandHandler = useCallback(\n (command: Command) => {\n handleMenuItemClick();\n return commandHandler(command);\n },\n [commandHandler, handleMenuItemClick],\n );\n\n const [offset, setOffset] = useState({ top: 1, left: 1 });\n\n useEffect(() => {\n if (isMenuOpen) {\n const node = containerRef?.current;\n if (node) {\n const rect = node.getBoundingClientRect();\n const scrollTop = window.scrollY;\n const scrollLeft = window.scrollX;\n const top = rect.top + scrollTop + node.clientHeight;\n const left = rect.left + scrollLeft;\n setOffset({ top, left });\n }\n }\n }, [isMenuOpen, containerRef]);\n\n const [normalMenuData] = usePromise(\n useCallback(async () => {\n return menuProvider?.(false) ?? normalMenu;\n // isMenuOpen needs to be included for the menu contents to reevaluate when reopened\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [menuProvider, normalMenu, isMenuOpen]),\n normalMenu,\n );\n\n const [fullMenuData] = usePromise(\n useCallback(async () => {\n return menuProvider?.(true) ?? fullMenu ?? normalMenuData;\n // isMenuOpen needs to be included for the menu contents to reevaluate when reopened\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [menuProvider, fullMenu, normalMenuData, isMenuOpen]),\n fullMenu ?? normalMenuData,\n );\n\n const menu = showFullMenu && fullMenuData ? fullMenuData : normalMenuData;\n\n return (\n <>\n \n {children ?? }\n \n \n {menu ? (\n \n ) : undefined}\n \n \n );\n}\n","import '@/components/mui/icon-button.component.css';\nimport { IconButton as MuiIconButton } from '@mui/material';\nimport { MouseEventHandler, PropsWithChildren } from 'react';\n\nexport type IconButtonProps = PropsWithChildren<{\n /** Optional unique identifier */\n id?: string;\n /**\n * Required. Used as both the tooltip (aka, title) and the aria-label (used for accessibility,\n * testing, etc.), unless a distinct tooltip is supplied.\n */\n label: string;\n /**\n * Enabled status of button\n *\n * @default false\n */\n isDisabled?: boolean;\n /** Optional tooltip to display if different from the aria-label. */\n tooltip?: string;\n /** If true, no tooltip will be displayed. */\n isTooltipSuppressed?: boolean;\n /**\n * If given, uses a negative margin to counteract the padding on one side (this is often helpful\n * for aligning the left or right side of the icon with content above or below, without ruining\n * the border size and shape).\n *\n * @default false\n */\n adjustMarginToAlignToEdge?: 'end' | 'start' | false;\n /**\n * The size of the component. small is equivalent to the dense button styling.\n *\n * @default false\n */\n size: 'small' | 'medium' | 'large';\n /** Additional css classes to help with unique styling of the button */\n className?: string;\n /** Optional click handler */\n onClick?: MouseEventHandler;\n}>;\n\n/**\n * Iconic button a user can click to do something\n *\n * Thanks to MUI for heavy inspiration and documentation\n * https://mui.com/material-ui/getting-started/overview/\n */\nfunction IconButton({\n id,\n label,\n isDisabled = false,\n tooltip,\n isTooltipSuppressed = false,\n adjustMarginToAlignToEdge = false,\n size = 'medium',\n className,\n onClick,\n children,\n}: IconButtonProps) {\n return (\n \n {children /* the icon to display */}\n \n );\n}\n\nexport default IconButton;\n","import { cn } from '@/utils/shadcn-ui.util';\nimport { LoaderCircle, LucideProps } from 'lucide-react';\nimport { forwardRef } from 'react';\n\nexport type SpinnerProps = LucideProps;\n\nconst Spinner = forwardRef(({ className, ...props }, ref) => {\n return (\n \n );\n});\n\nSpinner.displayName = 'Spinner';\n\nexport default Spinner;\n","import { Input as ShadInput } from '@/components/shadcn-ui/input';\nimport { Label as ShadLabel } from '@/components/shadcn-ui/label';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { ChangeEventHandler, FocusEventHandler } from 'react';\n\nexport type TextFieldProps = {\n /** Optional unique identifier */\n id?: string;\n /**\n * If `true`, the component is disabled.\n *\n * @default false\n */\n isDisabled?: boolean;\n /**\n * If `true`, the label is displayed in an error state.\n *\n * @default false\n */\n hasError?: boolean;\n /**\n * If `true`, the input will take up the full width of its container.\n *\n * @default false\n */\n isFullWidth?: boolean;\n /** Text that gives the user instructions on what contents the TextField expects */\n helperText?: string;\n /** The title of the TextField */\n label?: string;\n /** The short hint displayed in the `input` before the user enters a value. */\n placeholder?: string;\n /**\n * If `true`, the label is displayed as required and the `input` element is required.\n *\n * @default false\n */\n isRequired?: boolean;\n /** Additional css classes to help with unique styling of the text field */\n className?: string;\n /** Starting value for the text field if it is not controlled */\n defaultValue?: string | number;\n /** Value of the text field if controlled */\n value?: string | number;\n /** Triggers when content of textfield is changed */\n onChange?: ChangeEventHandler;\n /** Triggers when textfield gets focus */\n onFocus?: FocusEventHandler;\n /** Triggers when textfield loses focus */\n onBlur?: FocusEventHandler;\n};\n\n/**\n * Text input field\n *\n * Thanks to Shadcn for heavy inspiration and documentation\n * https://ui.shadcn.com/docs/components/input#with-label\n */\nfunction TextField({\n id,\n isDisabled = false,\n hasError = false,\n isFullWidth = false,\n helperText,\n label,\n placeholder,\n isRequired = false,\n className,\n defaultValue,\n value,\n onChange,\n onFocus,\n onBlur,\n}: TextFieldProps) {\n return (\n
    \n {`${label}${isRequired ? '*' : ''}`}\n \n

    {helperText}

    \n
    \n );\n}\n\nexport default TextField;\n","import HamburgerMenuButton, {\n MultiColumnMenuProvider,\n} from '@/components/mui/hamburger-menu-button.component';\nimport { CommandHandler } from '@/components/mui/menu-item.component';\nimport '@/components/mui/toolbar.component.css';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { AppBar, Toolbar as MuiToolbar } from '@mui/material';\nimport { PropsWithChildren, useRef } from 'react';\n\nexport type ToolbarProps = PropsWithChildren<{\n /** The handler to use for menu commands (and eventually toolbar commands). */\n commandHandler: CommandHandler;\n\n /**\n * The optional delegate to use to get the menu data. If not specified, the \"hamburger\" menu will\n * not display.\n */\n menuProvider?: MultiColumnMenuProvider;\n\n /** Optional unique identifier */\n id?: string;\n\n /** Additional css classes to help with unique styling of the toolbar */\n className?: string;\n}>;\n\nexport default function Toolbar({\n menuProvider,\n commandHandler,\n className,\n id,\n children,\n}: ToolbarProps) {\n // This ref will always be defined\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const containerRef = useRef(undefined!);\n\n return (\n
    \n \n \n {menuProvider ? (\n \n ) : undefined}\n {children ?
    {children}
    : undefined}\n \n
    \n
    \n );\n}\n","import React from 'react';\nimport { cva, type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst alertVariants = cva(\n 'tw-relative tw-w-full tw-rounded-lg tw-border tw-p-4 [&>svg~*]:tw-pl-7 [&>svg+div]:tw-translate-y-[-3px] [&>svg]:tw-absolute [&>svg]:tw-left-4 [&>svg]:tw-top-4 [&>svg]:tw-text-foreground',\n {\n variants: {\n variant: {\n default: 'tw-bg-background tw-text-foreground',\n destructive:\n 'tw-border-destructive/50 tw-text-destructive dark:tw-border-destructive [&>svg]:tw-text-destructive',\n },\n },\n defaultVariants: {\n variant: 'default',\n },\n },\n);\n\nconst Alert = React.forwardRef<\n HTMLDivElement,\n React.HTMLAttributes & VariantProps\n>(({ className, variant, ...props }, ref) => (\n
    \n));\nAlert.displayName = 'Alert';\n\nconst AlertTitle = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n {/* added because of https://github.com/jsx-eslint/eslint-plugin-jsx-a11y/blob/main/docs/rules/heading-has-content.md */}\n {props.children}{' '}\n \n ),\n);\nAlertTitle.displayName = 'AlertTitle';\n\nconst AlertDescription = React.forwardRef<\n HTMLParagraphElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n
    \n));\nAlertDescription.displayName = 'AlertDescription';\n\nexport { Alert, AlertTitle, AlertDescription };\n","import React from 'react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Card = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nCard.displayName = 'Card';\n\nconst CardHeader = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nCardHeader.displayName = 'CardHeader';\n\nconst CardTitle = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n {/* added because of https://github.com/jsx-eslint/eslint-plugin-jsx-a11y/blob/main/docs/rules/heading-has-content.md */}\n {props.children}\n \n ),\n);\nCardTitle.displayName = 'CardTitle';\n\nconst CardDescription = React.forwardRef<\n HTMLParagraphElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n

    \n));\nCardDescription.displayName = 'CardDescription';\n\nconst CardContent = React.forwardRef>(\n ({ className, ...props }, ref) => (\n

    \n ),\n);\nCardContent.displayName = 'CardContent';\n\nconst CardFooter = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nCardFooter.displayName = 'CardFooter';\n\nexport { Card, CardHeader, CardFooter, CardTitle, CardDescription, CardContent };\n","import { ComponentProps } from 'react';\nimport { toast as sonner, Toaster } from 'sonner';\n\ntype SonnerProps = ComponentProps;\n\nfunction Sonner({ ...props }: SonnerProps) {\n return (\n \n );\n}\n\n// The re-export of the sonner function was added manually\nexport { Sonner, sonner };\n","import React from 'react';\nimport * as SliderPrimitive from '@radix-ui/react-slider';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Slider = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n \n \n \n));\nSlider.displayName = SliderPrimitive.Root.displayName;\n\nexport { Slider };\n","import React from 'react';\nimport * as SwitchPrimitives from '@radix-ui/react-switch';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Switch = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n));\nSwitch.displayName = SwitchPrimitives.Root.displayName;\n\nexport { Switch };\n","import React from 'react';\nimport * as TabsPrimitive from '@radix-ui/react-tabs';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport const Tabs = TabsPrimitive.Root;\n\nexport type TabsListProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport type TabsTriggerProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport type TabsContentProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport const TabsList = React.forwardRef<\n React.ElementRef,\n TabsListProps\n>(({ className, ...props }, ref) => (\n \n));\nTabsList.displayName = TabsPrimitive.List.displayName;\n\nexport const TabsTrigger = React.forwardRef<\n React.ElementRef,\n TabsTriggerProps\n>(({ className, ...props }, ref) => (\n \n));\nTabsTrigger.displayName = TabsPrimitive.Trigger.displayName;\n\nexport const TabsContent = React.forwardRef<\n React.ElementRef,\n TabsContentProps\n>(({ className, ...props }, ref) => (\n \n));\nTabsContent.displayName = TabsPrimitive.Content.displayName;\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Download } from 'lucide-react';\n\ntype InstallButtonProps = {\n /** The installing boolean value determines the state of the button. */\n isInstalling: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n /** Optional text for the button. */\n buttonText?: string;\n} & ButtonProps;\n\n/**\n * The InstallButton component is a button designed for initiating installs. It includes visuals for\n * active installing and idle states.\n *\n * @param isInstalling The installing boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @param buttonText Optional text for the button.\n * @returns A install button.\n */\nexport default function InstallButton({\n isInstalling,\n handleClick,\n buttonText,\n className,\n ...props\n}: InstallButtonProps) {\n return (\n \n {isInstalling ? (\n \n ) : (\n <>\n \n {buttonText}\n \n )}\n \n );\n}\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\n\ntype EnableButtonProps = {\n /** The enabling boolean value determines the state of the button. */\n isEnabling: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n} & ButtonProps;\n\n/**\n * The EnableButton component is a button designed for initiating enabling of downloads. It includes\n * visuals for active enabling and idle states.\n *\n * @param isEnabling The enabling boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @returns A button that can be used to enable.\n */\nexport default function EnableButton({\n isEnabling,\n handleClick,\n className,\n ...props\n}: EnableButtonProps) {\n return (\n \n {isEnabling ? (\n <>\n \n Enabling...\n \n ) : (\n 'Enable'\n )}\n \n );\n}\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\n\ntype DisableButtonProps = {\n /** The disabling boolean value determines the state of the button. */\n isDisabling: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n} & ButtonProps;\n\n/**\n * The DisableButton component is a button designed for initiating disabling of downloads. It\n * includes visuals for active disabling and idle states.\n *\n * @param isDisabling The disabling boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @returns A button that can be used to disable.\n */\nexport default function DisableButton({\n isDisabling,\n handleClick,\n className,\n ...props\n}: DisableButtonProps) {\n return (\n \n {isDisabling ? (\n <>\n \n Disabling...\n \n ) : (\n 'Disable'\n )}\n \n );\n}\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\n\ntype UpdateButtonProps = {\n /** The updating boolean value determines the state of the button. */\n isUpdating: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n} & ButtonProps;\n\n/**\n * The UpdateButton component is a button designed for initiating updates for downloaded extensions.\n * It includes visuals for active updating and idle states.\n *\n * @param isUpdating The updating boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @returns A button that can be used to update.\n */\nexport default function UpdateButton({\n isUpdating,\n handleClick,\n className,\n ...props\n}: UpdateButtonProps) {\n return (\n \n {isUpdating ? (\n <>\n \n Updating...\n \n ) : (\n 'Update'\n )}\n \n );\n}\n","import { cn } from '@/utils/shadcn-ui.util';\nimport Markdown, { MarkdownToJSX } from 'markdown-to-jsx';\nimport { useMemo } from 'react';\n\ninterface MarkdownRendererProps {\n /** Optional unique identifier */\n id?: string;\n /** The markdown string to render */\n markdown: string;\n className?: string;\n /**\n * The [`target` attribute for `a` html\n * tags](https://developer.mozilla.org/en-US/docs/Web/HTML/Element/a#target). Defaults to not\n * adding a `target` to `a` tags\n */\n anchorTarget?: string;\n}\n\n/**\n * This component renders markdown content given a markdown string. It uses typography styles from\n * the platform.\n *\n * @param markdown The markdown string to render.\n * @param id Optional unique identifier\n * @returns A div containing the rendered markdown content.\n */\nexport default function MarkdownRenderer({\n id,\n markdown,\n className,\n anchorTarget,\n}: MarkdownRendererProps) {\n const options: MarkdownToJSX.Options = useMemo(\n () => ({\n overrides: {\n a: {\n props: {\n target: anchorTarget,\n },\n },\n },\n }),\n [anchorTarget],\n );\n return (\n
    \n {markdown}\n
    \n );\n}\n","import { Filter, ChevronDown } from 'lucide-react';\nimport { forwardRef } from 'react';\nimport { Button } from '@/components/shadcn-ui/button';\n\n/**\n * The FilterButton component is a button designed for initiating filtering of data. It is designed\n * to be used with the dropdown menu. It uses forwardRef to pass the button to the dropdown trigger\n * asChild.\n *\n * @returns A button that can be used to filter.\n */\nconst FilterButton = forwardRef((props, ref) => {\n return (\n \n \n Filter\n \n \n );\n});\n\nexport default FilterButton;\n","import {\n DropdownMenu,\n DropdownMenuTrigger,\n DropdownMenuContent,\n DropdownMenuLabel,\n DropdownMenuGroup,\n DropdownMenuCheckboxItem,\n DropdownMenuRadioItem,\n DropdownMenuSeparator,\n} from '@/components/shadcn-ui/dropdown-menu';\nimport FilterButton from './buttons/filter-button.component';\n\nexport enum DropdownMenuItemType {\n Check,\n Radio,\n}\n\nexport type DropdownItem = {\n /** The label is the text that will be displayed on the dropdown item. */\n label: string;\n /** The itemType determines the DropdownMenuItemType type as either Check or Radio. */\n itemType: DropdownMenuItemType;\n /** The onClick function is called when the item is clicked. */\n onClick: () => void;\n};\n\nexport type DropdownGroup = {\n /**\n * The label is the text that will be displayed on the dropdown group. It is used to categorize\n * the items in the group.\n */\n label: string;\n /** The items array contains the items that will be displayed in the dropdown group */\n items: DropdownItem[];\n};\n\nexport type FilterDropdownProps = {\n /** Object unique identifier */\n id?: string;\n /** The groups array contains the groups that will be displayed in the dropdown */\n groups: DropdownGroup[];\n}; // TODO: extend the props later\n\n/**\n * The FilterDropdown component is a dropdown designed for filtering content. It includes groups of\n * items that can be checkboxes or radio items.\n *\n * @param id Optional unique identifier\n * @param groups The groups array contains the groups that will be displayed in the dropdown\n * @returns A filter dropdown.\n */\nexport default function FilterDropdown({ id, groups }: FilterDropdownProps) {\n return (\n
    \n {/* TODO: remove this once the DropDown Menu shadcn has an id prop */}\n \n \n \n \n \n {groups.map((group) => (\n
    \n {group.label}\n \n {group.items.map((item) => (\n
    \n {item.itemType === DropdownMenuItemType.Check ? (\n \n {item.label}\n \n ) : (\n \n {item.label}\n \n )}\n
    \n ))}\n
    \n \n
    \n ))}\n
    \n
    \n
    \n );\n}\n","interface NoExtensionsFoundProps {\n /** Optional unique identifier */\n id?: string;\n /** The message to display */\n message: string;\n}\n/**\n * This component displays a message to the user when no extensions are found in the marketplace.\n *\n * @param id Optional unique identifier\n * @param message The message to display.\n * @returns {JSX.Element} - Returns the message component that displays the message to the user.\n */\nexport default function NoExtensionsFound({ id, message }: NoExtensionsFoundProps) {\n return (\n
    \n
    \n

    {message}

    \n
    \n
    \n );\n}\n","import { CircleHelp, Link as LucideLink, User } from 'lucide-react';\nimport { NumberFormat } from 'platform-bible-utils';\n\n/** Interface that stores the parameters passed to the More Info component */\ninterface MoreInfoProps {\n /** Optional unique identifier */\n id?: string;\n /** The category of the extension */\n category: string;\n /** The number of downloads for the extension */\n downloads: Record;\n /** The languages supported by the extension */\n languages: string[];\n /** The URL to the more info page of the extension */\n moreInfoUrl: string;\n}\n/**\n * This component displays the more info section of the extension which includes the category,\n * number of downloads, languages, and links to the website and support\n *\n * @param id Optional unique identifier\n * @param category The category of the extension\n * @param downloads The number of downloads for the extension\n * @param languages The languages supported by the extension\n * @param moreInfoUrl The URL to the more info page of the extension\n * @returns {JSX.Element} - Returns the more info component that displays the category, number of\n * downloads, languages, and links to the website and support\n */\nexport default function MoreInfo({\n id,\n category,\n downloads,\n languages,\n moreInfoUrl,\n}: MoreInfoProps) {\n /**\n * This constant formats the number of downloads into a more readable format.\n *\n * @example 1000 -> 1K\n *\n * @example 1000000 -> 1M\n *\n * @returns The formatted number of downloads\n */\n const numberFormatted = new NumberFormat('en', {\n notation: 'compact',\n compactDisplay: 'short',\n }).format(Object.values(downloads).reduce((a: number, b: number) => a + b, 0));\n\n /** This function scrolls the window to the bottom of the page. */\n const handleScrollToBottom = () => {\n window.scrollTo(0, document.body.scrollHeight);\n };\n\n return (\n \n
    \n
    \n {category}\n
    \n CATEGORY\n
    \n
    \n
    \n
    \n \n {numberFormatted}\n
    \n USERS\n
    \n
    \n
    \n
    \n {languages.slice(0, 3).map((locale) => (\n \n {locale.toUpperCase()}\n \n ))}\n
    \n {languages.length > 3 && (\n handleScrollToBottom()}\n className=\"tw-text-xs tw-text-gray-500 tw-underline\"\n >\n +{languages.length - 3} more languages\n \n )}\n
    \n
    \n
    \n \n Website\n \n \n \n Support\n \n \n
    \n
    \n );\n}\n","import { useState } from 'react';\n\nexport type VersionInformation = {\n /** Date the version was published */\n date: string;\n /** Description of the changes in the version */\n description: string;\n};\n\n/** Type to store the version history information */\nexport type VersionHistoryType = Record;\n\n/** Interface that stores the parameters passed to the Version History component */\ninterface VersionHistoryProps {\n /** Optional unique identifier */\n id?: string;\n /** Object containing the versions mapped with their information */\n versionHistory: VersionHistoryType;\n}\n\n/**\n * Component to render the version history information shown in the footer component. Lists the 5\n * most recent versions, with the options to show all versions by pressing a button.\n *\n * @param versionHistory Object containing the versions mapped with their information\n * @param id Optional unique identifier\n * @returns Rendered version history for the Footer component\n */\nexport default function VersionHistory({ id, versionHistory }: VersionHistoryProps) {\n const [showAllVersions, setShowAllVersions] = useState(false);\n const currentDate = new Date();\n\n /**\n * Function to format the time string for the version history in the form of 'X year(s) ago'.\n *\n * @param dateString ISO Date string to determine the time string from\n * @returns Formatted time string\n */\n function formatTimeString(dateString: string) {\n const date = new Date(dateString);\n const dateDiff = new Date(currentDate.getTime() - date.getTime());\n const yearDiff = dateDiff.getUTCFullYear() - 1970;\n const monthDiff = dateDiff.getUTCMonth();\n const dayDiff = dateDiff.getUTCDate() - 1;\n\n // Determines how long ago the version was published\n let timeString = '';\n if (yearDiff > 0) {\n timeString = `${yearDiff.toString()} year${yearDiff === 1 ? '' : 's'} ago`;\n } else if (monthDiff > 0) {\n timeString = `${monthDiff.toString()} month${monthDiff === 1 ? '' : 's'} ago`;\n } else if (dayDiff === 0) {\n timeString = 'today';\n } else {\n timeString = `${dayDiff.toString()} day${dayDiff === 1 ? '' : 's'} ago`;\n }\n\n return timeString;\n }\n\n // Sorts the version history by version number\n const sortedEntries = Object.entries(versionHistory).sort((a, b) => b[0].localeCompare(a[0]));\n\n return (\n
    \n

    What`s New

    \n
      \n {(showAllVersions ? sortedEntries : sortedEntries.slice(0, 5)).map((entry) => (\n
      \n
      \n
    • \n {entry[1].description}\n
    • \n
      \n
      \n
      Version {entry[0]}
      \n
      {formatTimeString(entry[1].date)}
      \n
      \n
      \n ))}\n
    \n {sortedEntries.length > 5 && (\n setShowAllVersions(!showAllVersions)}\n className=\"tw-text-xs tw-text-gray-500 tw-underline\"\n >\n {showAllVersions ? 'Show Less Version History' : 'Show All Version History'}\n \n )}\n
    \n );\n}\n","import { useMemo } from 'react';\nimport { formatBytes } from 'platform-bible-utils';\nimport VersionHistory, { VersionHistoryType } from './version-history.component';\n\n/** Interface to store the parameters passed to the Footer component */\ninterface FooterProps {\n /** Optional unique identifier */\n id?: string;\n /** Name of the publisher */\n publisherDisplayName: string;\n /** Size of the extension file in bytes */\n fileSize: number;\n /** List of language codes supported by the extension */\n locales: string[];\n /** Object containing the version history mapped with their information */\n versionHistory: VersionHistoryType;\n}\n\n/**\n * Component to render the footer for the extension details which contains information on the\n * publisher, version history, languages, and file size.\n *\n * @param id Optional unique identifier\n * @param publisherDisplayName Name of the publisher\n * @param fileSize Size of the extension file in bytes\n * @param locales List of language codes supported by the extension\n * @param versionHistory Object containing the version history mapped with their information\n * @returns The rendered Footer component\n */\nexport default function Footer({\n id,\n publisherDisplayName,\n fileSize,\n locales,\n versionHistory,\n}: FooterProps) {\n /** Formats the file size into a human-readable format */\n const formattedFileSize = useMemo(() => formatBytes(fileSize), [fileSize]);\n\n /**\n * This function gets the display names of the languages based on the language codes.\n *\n * @param codes The list of language codes\n * @returns The list of language names\n */\n const getLanguageNames = (codes: string[]) => {\n const displayNames = new Intl.DisplayNames(navigator.language, { type: 'language' });\n return codes.map((code) => displayNames.of(code));\n };\n\n const languageNames = getLanguageNames(locales);\n\n return (\n
    \n
    \n \n
    \n
    \n

    Information

    \n
    \n

    \n Publisher\n {publisherDisplayName}\n Size\n {formattedFileSize}\n

    \n
    \n

    \n Languages\n {languageNames.join(', ')}\n

    \n
    \n
    \n
    \n
    \n
    \n );\n}\n","import { PlatformEvent, PlatformEventHandler } from 'platform-bible-utils';\nimport { useEffect } from 'react';\n\n/**\n * Adds an event handler to an event so the event handler runs when the event is emitted. Use\n * `papi.network.getNetworkEvent` to use a networked event with this hook.\n *\n * @param event The event to subscribe to.\n *\n * - If event is a `PlatformEvent`, that event will be used\n * - If event is undefined, the callback will not be subscribed. Useful if the event is not yet\n * available for example\n *\n * @param eventHandler The callback to run when the event is emitted\n *\n * WARNING: MUST BE STABLE - const or wrapped in useCallback. The reference must not be updated\n * every render\n */\nconst useEvent = (\n event: PlatformEvent | undefined,\n eventHandler: PlatformEventHandler,\n) => {\n useEffect(() => {\n // Do nothing if the event is not provided (in case the event is not yet available, for example)\n if (!event) return () => {};\n\n const unsubscriber = event(eventHandler);\n return () => {\n unsubscriber();\n };\n }, [event, eventHandler]);\n};\nexport default useEvent;\n","import { useCallback, useEffect } from 'react';\nimport { PlatformEvent, PlatformEventAsync, PlatformEventHandler } from 'platform-bible-utils';\nimport usePromise from './use-promise.hook';\n\nconst noopUnsubscriber = () => false;\n\n/**\n * Adds an event handler to an asynchronously subscribing/unsubscribing event so the event handler\n * runs when the event is emitted. Use `papi.network.getNetworkEvent` to use a networked event with\n * this hook.\n *\n * @param event The asynchronously (un)subscribing event to subscribe to.\n *\n * - If event is a `PlatformEvent` or `PlatformEventAsync`, that event will be used\n * - If event is undefined, the callback will not be subscribed. Useful if the event is not yet\n * available for example\n *\n * @param eventHandler The callback to run when the event is emitted\n *\n * WARNING: MUST BE STABLE - const or wrapped in useCallback. The reference must not be updated\n * every render\n */\nconst useEventAsync = (\n event: PlatformEvent | PlatformEventAsync | undefined,\n eventHandler: PlatformEventHandler,\n) => {\n // Subscribe to the event asynchronously\n const [unsubscribe] = usePromise(\n useCallback(async () => {\n // Do nothing if the event is not provided (in case the event is not yet available, for example)\n if (!event) return noopUnsubscriber;\n\n // Wrap subscribe and unsubscribe in promises to allow normal events to be used as well\n const unsub = await Promise.resolve(event(eventHandler));\n return async () => unsub();\n }, [eventHandler, event]),\n noopUnsubscriber,\n // We want the unsubscriber to return to default value immediately upon changing subscription\n // So the useEffect below will unsubscribe asap\n { preserveValue: false },\n );\n\n // Unsubscribe from the event asynchronously (but we aren't awaiting the unsub)\n useEffect(() => {\n return () => {\n if (unsubscribe !== noopUnsubscriber) {\n unsubscribe();\n }\n };\n }, [unsubscribe]);\n};\n\nexport default useEventAsync;\n"],"names":["twMergeCustom","extendTailwindMerge","cn","inputs","clsx","Input","React","className","type","props","ref","jsx","BookChapterInput","forwardRef","handleSearch","handleKeyDown","handleOnClick","handleSubmit","jsxs","ShadInput","event","e","History","P","R","t","s","n","N","B","O","S","K","g","k","x","T","X","V","w","L","G","A","H","C","I","y","q","U","m","l","h","c","E","D","i","a","o","u","v","f","d","b","p","J","DropdownMenu","DropdownMenuPrimitive","DropdownMenuTrigger","DropdownMenuGroup","DropdownMenuPortal","DropdownMenuSub","DropdownMenuRadioGroup","DropdownMenuSubTrigger","inset","children","ChevronRight","DropdownMenuSubContent","DropdownMenuContent","sideOffset","DropdownMenuItem","DropdownMenuCheckboxItem","checked","Check","DropdownMenuRadioItem","Circle","DropdownMenuLabel","DropdownMenuSeparator","DropdownMenuShortcut","BookMenuItem","bookId","handleSelectBook","isSelected","handleHighlightBook","bookType","ShadDropdownMenuItem","Canon","ChapterSelect","handleSelectChapter","endChapter","activeChapter","highlightedChapter","handleHighlightedChapter","chapters","_","handleMouse","useCallback","chapterNumber","chapter","GoToMenuItem","handleSort","handleLocationHistory","handleBookmarks","ShadDropdownMenuLabel","ArrowDownWideNarrow","Clock","Bookmark","ALL_BOOK_IDS","BOOK_TYPE_LABELS","BOOK_TYPE_ARRAY","SCROLL_OFFSET","SEARCH_QUERY_FORMATS","fetchGroupedBooks","fetchEndChapter","getChaptersForBook","getAllEnglishNames","isValidBookEnglishName","bookName","getBookIdFromEnglishName","formattedBookName","BookChapterControl","scrRef","searchQuery","setSearchQuery","useState","selectedBookId","setSelectedBookId","setHighlightedChapter","highlightedBookId","setHighlightedBookId","isContentOpen","setIsContentOpen","isContentOpenDelayed","setIsContentOpenDelayed","inputRef","useRef","contentRef","menuItemRef","fetchFilteredBooks","englishNameLowerCase","normalizedQuery","handleSearchInput","searchString","shouldPreventAutoClosing","controlMenuState","open","updateReference","shouldClose","verse","handleInputSubmit","format","matches","book","englishName","handleKeyDownInput","handleKeyDownContent","key","handleKeyDownMenuItem","chapterOffSet","useEffect","useLayoutEffect","scrollTimeout","scrollPosition","ShadDropdownMenu","ShadDropdownMenuTrigger","ShadDropdownMenuContent","bookTypeIndex","element","ShadDropdownMenuSeparator","buttonVariants","cva","Button","variant","size","asChild","Comp","Slot","labelVariants","Label","LabelPrimitive","RadioGroup","RadioGroupPrimitive","RadioGroupItem","Popover","PopoverPrimitive","PopoverTrigger","PopoverContent","align","DialogPortal","DialogPrimitive","DialogOverlay","DialogContent","DialogTitle","DialogDescription","Command","CommandPrimitive","CommandInput","Search","CommandList","CommandEmpty","CommandGroup","CommandSeparator","CommandItem","getOptionLabelDefault","option","ComboBox","id","options","buttonClassName","popoverContentClassName","value","onChange","getOptionLabel","buttonPlaceholder","textPlaceholder","commandEmptyMessage","buttonVariant","dir","isDisabled","setOpen","ChevronsUpDown","ChapterRangeSelector","startChapter","handleSelectStartChapter","handleSelectEndChapter","chapterCount","chapterOptions","useMemo","index","onChangeStartChapter","onChangeEndChapter","Fragment","BookSelectionMode","BOOK_SELECTOR_STRING_KEYS","localizeString","strings","BookSelector","handleBookSelectionModeChange","currentBookName","onSelectBooks","selectedBookIds","localizedStrings","currentBookText","chooseText","chooseBooksText","bookSelectionMode","setBookSelectionMode","onSelectionModeChange","newMode","DataTableViewOptions","table","FilterIcon","column","Select","SelectPrimitive","SelectGroup","SelectValue","SelectTrigger","ChevronDown","SelectScrollUpButton","ChevronUp","SelectScrollDownButton","SelectContent","position","SelectLabel","SelectItem","SelectSeparator","DataTablePagination","pageSize","ArrowLeftIcon","ChevronLeftIcon","ChevronRightIcon","ArrowRightIcon","Table","stickyHeader","TableHeader","TableBody","TableFooter","TableRow","TableHead","TableCell","TableCaption","DataTable","columns","data","enablePagination","showPaginationControls","showColumnVisibilityControls","onRowClickHandler","sorting","setSorting","columnFilters","setColumnFilters","columnVisibility","setColumnVisibility","rowSelection","setRowSelection","useReactTable","getCoreRowModel","getPaginationRowModel","getSortedRowModel","getFilteredRowModel","headerGroup","header","flexRender","_a","row","cell","OccurrencesTable","occurrenceData","setScriptureReference","referenceHeaderText","occurrenceHeaderText","occurrences","uniqueOccurrences","occurrence","uniqueOccurrence","deepEqual","Checkbox","CheckboxPrimitive","getLinesFromUSFM","text","getNumberFromUSFM","regex","match","getBookNumFromId","getStatusForItem","item","approvedItems","unapprovedItems","toggleVariants","Toggle","TogglePrimitive","ToggleGroupContext","ToggleGroup","ToggleGroupPrimitive","ToggleGroupItem","context","getSortingIcon","sortDirection","ArrowUpIcon","ArrowDownIcon","ArrowUpDownIcon","inventoryItemColumn","itemLabel","inventoryAdditionalItemColumn","additionalItemLabel","additionalItemIndex","inventoryCountColumn","countLabel","statusChangeHandler","changedItems","newStatus","onApprovedItemsChange","onUnapprovedItemsChange","newApprovedItems","validItem","newUnapprovedItems","unapprovedItem","inventoryStatusColumn","statusLabel","status","CircleCheckIcon","CircleXIcon","CircleHelpIcon","INVENTORY_STRING_KEYS","filterItemData","itemData","statusFilter","textFilter","filteredItemData","createTableData","scriptureRef","itemRegex","tableData","currentBook","currentChapter","currentVerse","line","items","itemIndex","existingItem","tableEntry","newReference","substring","newItem","Inventory","scriptureReference","extractItems","additionalItemsLabels","scope","onScopeChange","allItemsText","approvedItemsText","unapprovedItemsText","unknownItemsText","scopeBookText","scopeChapterText","scopeVerseText","filterText","showAdditionalItemsText","showAdditionalItems","setShowAdditionalItems","setStatusFilter","setTextFilter","selectedItem","setSelectedItem","reducedTableData","newTableData","firstItem","existingEntry","newTableEntry","filteredTableData","allColumns","numberOfAdditionalItems","additionalColumns","_b","rowClickHandler","newSelection","handleScopeChange","handleStatusFilterChange","SearchBar","onSearch","placeholder","isFullWidth","handleInputChange","VerticalTabs","TabsPrimitive","VerticalTabsList","VerticalTabsTrigger","VerticalTabsContent","TabNavigationContentSearch","tabList","searchPlaceholder","headerTitle","isSearchBarFullWidth","direction","tab","Separator","orientation","decorative","SeparatorPrimitive","Skeleton","TooltipProvider","TooltipPrimitive","Tooltip","TooltipTrigger","TooltipContent","SIDEBAR_WIDTH","SIDEBAR_WIDTH_ICON","SidebarContext","useSidebar","SidebarProvider","defaultOpen","openProp","setOpenProp","style","_open","_setOpen","isOpen","openState","toggleSidebar","state","contextValue","Sidebar","side","collapsible","SidebarTrigger","onClick","PanelLeft","SidebarRail","SidebarInset","SidebarInput","SidebarHeader","SidebarFooter","SidebarSeparator","SidebarContent","SidebarGroup","SidebarGroupLabel","SidebarGroupAction","SidebarGroupContent","SidebarMenu","SidebarMenuItem","sidebarMenuButtonVariants","SidebarMenuButton","isActive","tooltip","button","SidebarMenuAction","showOnHover","SidebarMenuBadge","SidebarMenuSkeleton","showIcon","width","SidebarMenuSub","SidebarMenuSubItem","SidebarMenuSubButton","SettingsSidebar","extensionLabels","projectInfo","handleSelectSidebarItem","selectedSidebarItem","extensionsSidebarGroupLabel","projectsSidebarGroupLabel","buttonPlaceholderText","handleSelectItem","projectId","getProjectNameFromProjectId","project","info","getIsActive","label","selectedProjectName","SettingsSidebarContentSearch","scrBookColId","scrRefColId","typeColId","detailsColId","defaultScrRefColumnName","defaultScrBookGroupName","defaultTypeColumnName","defaultDetailsColumnName","getColumns","colInfo","showSourceColumn","showSrcCol","formatScrRef","compareScrRefs","toRefOrRange","scriptureSelection","offsetStart","offsetEnd","scrRefToBBBCCCVVV","getRowKey","ScriptureResultsViewer","sources","showColumnHeaders","scriptureReferenceColumnName","scriptureBookGroupName","typeColumnName","detailsColumnName","onRowSelected","grouping","setGrouping","scriptureResults","source","getExpandedRowModel","getGroupedRowModel","selectedRows","keys","selectedRow","scrBookGroupName","typeGroupName","groupingOptions","handleSelectChange","selectedGrouping","handleRowClick","getEvenOrOddBandingStyle","getIndent","groupingState","rowIndex","ChevronLeft","DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS","getLocalizeKeyForScrollGroupId","ScrollGroupSelector","availableScrollGroupIds","scrollGroupId","onChangeScrollGroupId","localizedStringsDefaulted","localizedStringKey","localizedStringValue","newScrollGroupString","scrollGroupOptionId","SettingsList","SettingsListItem","primary","secondary","isLoading","loadingMessage","SettingsListHeader","includeSeparator","Checklist","listItems","selectedListItems","handleSelectListItem","createLabel","_interopRequireDefault","obj","module","chainPropTypes","propType1","propType2","args","_extends","target","isPlainObject","prototype","deepClone","output","deepmerge","r","z","reactIs_production_min","hasSymbol","REACT_ELEMENT_TYPE","REACT_PORTAL_TYPE","REACT_FRAGMENT_TYPE","REACT_STRICT_MODE_TYPE","REACT_PROFILER_TYPE","REACT_PROVIDER_TYPE","REACT_CONTEXT_TYPE","REACT_ASYNC_MODE_TYPE","REACT_CONCURRENT_MODE_TYPE","REACT_FORWARD_REF_TYPE","REACT_SUSPENSE_TYPE","REACT_SUSPENSE_LIST_TYPE","REACT_MEMO_TYPE","REACT_LAZY_TYPE","REACT_BLOCK_TYPE","REACT_FUNDAMENTAL_TYPE","REACT_RESPONDER_TYPE","REACT_SCOPE_TYPE","isValidElementType","typeOf","object","$$typeof","$$typeofType","AsyncMode","ConcurrentMode","ContextConsumer","ContextProvider","Element","ForwardRef","Lazy","Memo","Portal","Profiler","StrictMode","Suspense","hasWarnedAboutDeprecatedIsAsyncMode","isAsyncMode","isConcurrentMode","isContextConsumer","isContextProvider","isElement","isForwardRef","isFragment","isLazy","isMemo","isPortal","isProfiler","isStrictMode","isSuspense","reactIs_development","reactIsModule","require$$0","require$$1","getOwnPropertySymbols","hasOwnProperty","propIsEnumerable","toObject","val","shouldUseNative","test1","test2","order2","test3","letter","objectAssign","from","to","symbols","ReactPropTypesSecret","ReactPropTypesSecret_1","has","printWarning","loggedTypeFailures","message","checkPropTypes","typeSpecs","values","location","componentName","getStack","typeSpecName","error","err","ex","stack","checkPropTypes_1","ReactIs","assign","require$$2","require$$3","require$$4","emptyFunctionThatReturnsNull","factoryWithTypeCheckers","isValidElement","throwOnDirectAccess","ITERATOR_SYMBOL","FAUX_ITERATOR_SYMBOL","getIteratorFn","maybeIterable","iteratorFn","ANONYMOUS","ReactPropTypes","createPrimitiveTypeChecker","createAnyTypeChecker","createArrayOfTypeChecker","createElementTypeChecker","createElementTypeTypeChecker","createInstanceTypeChecker","createNodeChecker","createObjectOfTypeChecker","createEnumTypeChecker","createUnionTypeChecker","createShapeTypeChecker","createStrictShapeTypeChecker","is","PropTypeError","createChainableTypeChecker","validate","manualPropTypeCallCache","manualPropTypeWarningCount","checkType","isRequired","propName","propFullName","secret","cacheKey","chainedCheckType","expectedType","propValue","propType","getPropType","preciseType","getPreciseType","typeChecker","expectedClass","expectedClassName","actualClassName","getClassName","expectedValues","valuesString","arrayOfTypeCheckers","checker","getPostfixForTypeWarning","expectedTypes","checkerResult","expectedTypesMessage","isNode","invalidValidatorError","shapeTypes","allKeys","iterator","step","entry","isSymbol","emptyFunction","emptyFunctionWithReset","factoryWithThrowingShims","shim","getShim","propTypesModule","isClassComponent","elementType","acceptingRef","safePropName","warningHint","elementAcceptingRef","PropTypes","elementAcceptingRef$1","specialProperty","exactProp","propTypes","unsupportedProps","prop","formatMuiErrorMessage","code","url","REACT_SERVER_CONTEXT_TYPE","REACT_OFFSCREEN_TYPE","enableScopeAPI","enableCacheElement","enableTransitionTracing","enableLegacyHidden","enableDebugTracing","REACT_MODULE_REFERENCE","SuspenseList","hasWarnedAboutDeprecatedIsConcurrentMode","isSuspenseList","fnNameMatchRegex","getFunctionName","fn","getFunctionComponentName","Component","fallback","getWrappedName","outerType","innerType","wrapperName","functionName","getDisplayName","HTMLElementType","refType","refType$1","capitalize","string","_formatMuiErrorMessage","createChainedFunction","funcs","acc","func","debounce","wait","timeout","debounced","later","deprecatedPropType","validator","reason","componentNameSafe","propFullNameSafe","isMuiElement","muiNames","_muiName","_element$type","ownerDocument","node","ownerWindow","requirePropFactory","componentNameInError","prevPropTypes","requiredProp","defaultTypeChecker","typeCheckerResult","setRef","useEnhancedEffect","useEnhancedEffect$1","globalId","useGlobalId","idOverride","defaultId","setDefaultId","maybeReactUseId","useId","reactId","unsupportedProp","useControlled","controlled","defaultProp","name","isControlled","valueState","setValue","defaultValue","setValueIfUncontrolled","newValue","useEventCallback","useForkRef","refs","instance","UNINITIALIZED","useLazyRef","init","initArg","EMPTY","useOnMount","Timeout","delay","useTimeout","hadKeyboardEvent","hadFocusVisibleRecently","hadFocusVisibleRecentlyTimeout","inputTypesWhitelist","focusTriggersKeyboardModality","tagName","handlePointerDown","handleVisibilityChange","prepare","doc","isFocusVisible","useIsFocusVisible","isFocusVisibleRef","handleBlurVisible","handleFocusVisible","resolveProps","defaultProps","defaultSlotProps","slotProps","slotPropName","composeClasses","slots","getUtilityClass","classes","slot","utilityClass","defaultGenerator","createClassNameGenerator","generate","generator","ClassNameGenerator","ClassNameGenerator$1","globalStateClasses","generateUtilityClass","globalStatePrefix","globalStateClass","generateUtilityClasses","result","clamp","min","max","_objectWithoutPropertiesLoose","excluded","sourceKeys","_excluded","sortBreakpointsValues","breakpointsAsArray","breakpoint1","breakpoint2","createBreakpoints","breakpoints","unit","other","sortedValues","up","down","between","start","end","endIndex","only","not","keyIndex","shape","shape$1","responsivePropType","responsivePropType$1","merge","defaultBreakpoints","handleBreakpoints","styleFromPropValue","theme","themeBreakpoints","breakpoint","mediaKey","cssKey","createEmptyBreakpointObject","breakpointsInput","_breakpointsInput$key","breakpointStyleKey","removeUnusedBreakpoints","breakpointKeys","breakpointOutput","getPath","path","checkVars","getStyleValue","themeMapping","transform","propValueFinal","userValue","cssProperty","themeKey","memoize","cache","arg","properties","directions","aliases","getCssProperties","property","marginKeys","paddingKeys","spacingKeys","createUnaryUnit","_getPath","themeSpacing","abs","createUnarySpacing","getValue","transformer","transformed","getStyleFromPropValue","cssProperties","resolveCssProperty","margin","padding","createSpacing","spacingInput","spacing","argsInput","argument","compose","styles","handlers","borderTransform","createBorderStyle","border","borderTop","borderRight","borderBottom","borderLeft","borderColor","borderTopColor","borderRightColor","borderBottomColor","borderLeftColor","outline","outlineColor","borderRadius","gap","columnGap","rowGap","gridColumn","gridRow","gridAutoFlow","gridAutoColumns","gridAutoRows","gridTemplateColumns","gridTemplateRows","gridTemplateAreas","gridArea","paletteTransform","color","bgcolor","backgroundColor","sizingTransform","maxWidth","_props$theme","_props$theme2","breakpointsValues","minWidth","height","maxHeight","minHeight","boxSizing","defaultSxConfig","defaultSxConfig$1","objectsHaveSameKeys","objects","union","callIfFn","maybeFn","unstable_createStyleFunctionSx","getThemeValue","config","styleFunctionSx","_theme$unstable_sxCon","sx","traverse","sxInput","sxObject","emptyBreakpoints","breakpointsKeys","css","styleKey","styleFunctionSx$1","applyStyles","createTheme","paletteInput","shapeInput","muiTheme","isObjectEmpty","useTheme","defaultTheme","contextTheme","ThemeContext","systemDefaultTheme","useThemeWithoutDefault","_excluded2","_excluded3","isEmpty","isStringTag","tag","shouldForwardProp","lowercaseFirstLetter","resolveTheme","themeId","defaultOverridesResolver","processStyleArg","callableStyle","_ref","ownerState","resolvedStylesArg","resolvedStyle","variants","isMatch","createStyled","input","rootShouldForwardProp","slotShouldForwardProp","systemSx","inputOptions","processStyles","componentSlot","inputSkipVariantsResolver","inputSkipSx","overridesResolver","skipVariantsResolver","skipSx","shouldForwardPropOption","defaultStyledResolver","styledEngineStyled","transformStyleArg","stylesArg","muiStyledResolver","styleArg","expressions","transformedStyleArg","expressionsWithDefaultTheme","styleOverrides","resolvedStyleOverrides","slotKey","slotStyle","_theme$components","themeVariants","numOfCustomFnsApplied","placeholders","displayName","getThemeProps","params","useThemeProps","clampWrapper","hexToRgb","re","colors","decomposeColor","marker","colorSpace","recomposeColor","hslToRgb","rgb","getLuminance","getContrastRatio","foreground","background","lumA","lumB","alpha","darken","coefficient","lighten","createMixins","mixins","common","common$1","grey","grey$1","purple","purple$1","red","red$1","orange","orange$1","blue","blue$1","lightBlue","lightBlue$1","green","green$1","light","dark","addLightOrDark","intent","shade","tonalOffset","tonalOffsetLight","tonalOffsetDark","getDefaultPrimary","mode","getDefaultSecondary","getDefaultError","getDefaultInfo","getDefaultSuccess","getDefaultWarning","createPalette","palette","contrastThreshold","success","warning","getContrastText","contrastText","contrast","augmentColor","mainShade","lightShade","darkShade","modes","round","caseAllCaps","defaultFontFamily","createTypography","typography","fontFamily","fontSize","fontWeightLight","fontWeightRegular","fontWeightMedium","fontWeightBold","htmlFontSize","allVariants","pxToRem2","coef","pxToRem","buildVariant","fontWeight","lineHeight","letterSpacing","casing","shadowKeyUmbraOpacity","shadowKeyPenumbraOpacity","shadowAmbientShadowOpacity","createShadow","px","shadows","shadows$1","easing","duration","formatMs","milliseconds","getAutoHeightDuration","constant","createTransitions","inputTransitions","mergedEasing","mergedDuration","durationOption","easingOption","isString","isNumber","animatedProp","zIndex","zIndex$1","mixinsInput","transitionsInput","typographyInput","systemTheme","systemCreateTheme","stateClasses","component","child","stateClass","defaultTheme$1","THEME_ID","systemUseThemeProps","styled","styled$1","getSvgIconUtilityClass","useUtilityClasses","SvgIconRoot","_theme$transitions","_theme$transitions$cr","_theme$transitions2","_theme$typography","_theme$typography$pxT","_theme$typography2","_theme$typography2$px","_theme$typography3","_theme$typography3$px","_palette$ownerState$c","_palette","_palette2","_palette3","SvgIcon","inProps","htmlColor","inheritViewBox","titleAccess","viewBox","hasSvgAsChild","more","_jsxs","_jsx","SvgIcon$1","createSvgIcon","unstable_ClassNameGenerator","exports","_utils","ArrowRight","default_1","_createSvgIcon","_jsxRuntime","isHostComponent","appendOwnerState","otherProps","defaultContextValue","ClassNameConfiguratorContext","useClassNamesOverride","disableDefaultClasses","extractEventHandlers","excludeKeys","resolveComponentProps","componentProps","slotState","omitEventHandlers","mergeSlotProps","parameters","getSlotProps","additionalProps","externalSlotProps","externalForwardedProps","joinedClasses","mergedStyle","eventHandlers","componentsPropsWithoutEventHandlers","otherPropsWithoutEventHandlers","internalSlotProps","useSlotProps","_parameters$additiona","skipResolvingSlotProps","rest","resolvedComponentsProps","mergedProps","internalRef","GLOBAL_CLASS_PREFIX","buildStateClass","buildSlotClass","getContainer","container","forwardedRef","disablePortal","mountNode","setMountNode","handleRef","newProps","ReactDOM","top","bottom","right","left","auto","basePlacements","clippingParents","viewport","popper","reference","variationPlacements","placement","placements","beforeRead","read","afterRead","beforeMain","main","afterMain","beforeWrite","write","afterWrite","modifierPhases","getNodeName","getWindow","OwnElement","isHTMLElement","isShadowRoot","attributes","effect","_ref2","initialStyles","styleProperties","attribute","applyStyles$1","getBasePlacement","getUAString","uaData","isLayoutViewport","getBoundingClientRect","includeScale","isFixedStrategy","clientRect","scaleX","scaleY","visualViewport","addVisualOffsets","getLayoutRect","contains","parent","rootNode","next","getComputedStyle","isTableElement","getDocumentElement","getParentNode","getTrueOffsetParent","getContainingBlock","isFirefox","isIE","elementCss","currentNode","getOffsetParent","window","offsetParent","getMainAxisFromPlacement","within","mathMax","mathMin","withinMaxClamp","getFreshSideObject","mergePaddingObject","paddingObject","expandToHashMap","hashMap","toPaddingObject","arrow","_state$modifiersData$","arrowElement","popperOffsets","basePlacement","axis","isVertical","len","arrowRect","minProp","maxProp","endDiff","startDiff","arrowOffsetParent","clientSize","centerToReference","center","offset","axisProp","_options$element","arrow$1","getVariation","unsetSides","roundOffsetsByDPR","win","dpr","mapToStyles","_Object$assign2","popperRect","variation","offsets","gpuAcceleration","adaptive","roundOffsets","isFixed","_offsets$x","_offsets$y","_ref3","hasX","hasY","sideX","sideY","heightProp","widthProp","offsetY","offsetX","commonStyles","_ref4","_Object$assign","computeStyles","_ref5","_options$gpuAccelerat","_options$adaptive","_options$roundOffsets","computeStyles$1","passive","_options$scroll","scroll","_options$resize","resize","scrollParents","scrollParent","eventListeners","hash","getOppositePlacement","matched","getOppositeVariationPlacement","getWindowScroll","scrollLeft","scrollTop","getWindowScrollBarX","getViewportRect","strategy","html","layoutViewport","getDocumentRect","_element$ownerDocumen","winScroll","body","isScrollParent","_getComputedStyle","overflow","overflowX","overflowY","getScrollParent","listScrollParents","list","isBody","updatedList","rectToClientRect","rect","getInnerBoundingClientRect","getClientRectFromMixedType","clippingParent","getClippingParents","canEscapeClipping","clipperElement","getClippingRect","boundary","rootBoundary","mainClippingParents","firstClippingParent","clippingRect","accRect","computeOffsets","commonX","commonY","mainAxis","detectOverflow","_options","_options$placement","_options$strategy","_options$boundary","_options$rootBoundary","_options$elementConte","elementContext","_options$altBoundary","altBoundary","_options$padding","altContext","clippingClientRect","referenceClientRect","popperClientRect","elementClientRect","overflowOffsets","offsetData","multiply","computeAutoPlacement","flipVariations","_options$allowedAutoP","allowedAutoPlacements","allPlacements","allowedPlacements","overflows","getExpandedFallbackPlacements","oppositePlacement","flip","_options$mainAxis","checkMainAxis","_options$altAxis","checkAltAxis","specifiedFallbackPlacements","_options$flipVariatio","preferredPlacement","isBasePlacement","fallbackPlacements","referenceRect","checksMap","makeFallbackChecks","firstFittingPlacement","_basePlacement","isStartVariation","mainVariationSide","altVariationSide","checks","check","numberOfChecks","_loop","_i","fittingPlacement","_ret","flip$1","getSideOffsets","preventedOffsets","isAnySideFullyClipped","hide","referenceOverflow","popperAltOverflow","referenceClippingOffsets","popperEscapeOffsets","isReferenceHidden","hasPopperEscaped","hide$1","distanceAndSkiddingToXY","rects","invertDistance","skidding","distance","_options$offset","_data$state$placement","offset$1","popperOffsets$1","getAltAxis","preventOverflow","_options$tether","tether","_options$tetherOffset","tetherOffset","altAxis","tetherOffsetValue","normalizedTetherOffsetValue","offsetModifierState","_offsetModifierState$","mainSide","altSide","additive","minLen","maxLen","arrowPaddingObject","arrowPaddingMin","arrowPaddingMax","arrowLen","minOffset","maxOffset","clientOffset","offsetModifierValue","tetherMin","tetherMax","preventedOffset","_offsetModifierState$2","_mainSide","_altSide","_offset","_len","_min","_max","isOriginSide","_offsetModifierValue","_tetherMin","_tetherMax","_preventedOffset","preventOverflow$1","getHTMLElementScroll","getNodeScroll","isElementScaled","getCompositeRect","elementOrVirtualElement","isOffsetParentAnElement","offsetParentIsScaled","documentElement","order","modifiers","map","visited","modifier","sort","requires","dep","depModifier","orderModifiers","orderedModifiers","phase","pending","resolve","mergeByName","merged","current","existing","DEFAULT_OPTIONS","areValidElements","_key","popperGenerator","generatorOptions","_generatorOptions","_generatorOptions$def","defaultModifiers","_generatorOptions$def2","defaultOptions","effectCleanupFns","isDestroyed","setOptionsAction","cleanupModifierEffects","runModifierEffects","_state$elements","_state$orderedModifie","_state$orderedModifie2","_ref$options","cleanupFn","noopFn","createPopper","COMPONENT_NAME","getPopperUtilityClass","flipPlacement","resolveAnchorEl","anchorEl","isVirtualElement","defaultPopperOptions","PopperTooltip","_slots$root","initialPlacement","popperOptions","popperRefProp","TransitionProps","tooltipRef","ownRef","popperRef","handlePopperRef","handlePopperRefRef","rtlPlacement","setPlacement","resolvedAnchorElement","setResolvedAnchorElement","handlePopperUpdate","box","popperModifiers","childProps","Root","rootProps","Popper","containerProp","keepMounted","transition","exited","setExited","handleEnter","handleExited","resolvedAnchorEl","display","transitionProps","useThemeSystem","_setPrototypeOf","_inheritsLoose","subClass","superClass","setPrototypeOf","timeoutsShape","TransitionGroupContext","forceReflow","UNMOUNTED","EXITED","ENTERING","ENTERED","EXITING","Transition","_React$Component","_this","parentGroup","appear","initialStatus","prevState","nextIn","_proto","prevProps","nextStatus","exit","enter","mounting","_this2","appearing","maybeNode","maybeAppearing","timeouts","enterTimeout","_this3","nextState","callback","_this4","active","handler","doesNotHaveTimeoutOrListener","maybeNextCallback","_this$props","pt","noop","Transition$1","reflow","getTransitionProps","_style$transitionDura","_style$transitionTimi","getScale","isWebKit154","Grow","addEndListener","inProp","onEnter","onEntered","onEntering","onExit","onExited","onExiting","TransitionComponent","timer","autoTimeout","nodeRef","normalizedTransitionCallback","maybeIsAppearing","handleEntering","isAppearing","transitionDuration","transitionTimingFunction","handleEntered","handleExiting","handleExit","handleAddEndListener","Grow$1","PopperRoot","BasePopper","components","componentsProps","RootComponent","Popper$1","getTooltipUtilityClass","tooltipClasses","tooltipClasses$1","disableInteractive","touch","TooltipPopper","TooltipTooltip","TooltipArrow","hystersisOpen","hystersisTimer","cursorPosition","composeEventHandler","eventHandler","_slots$popper","_slots$transition","_slots$tooltip","_slots$arrow","_slotProps$popper","_ref6","_slotProps$popper2","_slotProps$transition","_slotProps$tooltip","_ref7","_slotProps$tooltip2","_slotProps$arrow","_ref8","_slotProps$arrow2","childrenProp","describeChild","disableFocusListener","disableHoverListener","disableInteractiveProp","disableTouchListener","enterDelay","enterNextDelay","enterTouchDelay","followCursor","idProp","leaveDelay","leaveTouchDelay","onClose","onOpen","PopperComponentProp","PopperProps","title","TransitionComponentProp","isRtl","childNode","setChildNode","arrowRef","setArrowRef","ignoreNonTouchEvents","closeTimer","enterTimer","leaveTimer","touchTimer","setOpenState","prevUserSelect","stopTouchInteraction","handleOpen","handleClose","handleLeave","focusVisibleRef","setChildIsFocusVisible","handleBlur","handleFocus","detectTouchStart","childrenProps","handleMouseOver","handleMouseLeave","handleTouchStart","handleTouchEnd","nativeEvent","handleMouseMove","nameOrDescProps","titleIsString","interactiveWrapperListeners","_PopperProps$popperOp","tooltipModifiers","PopperComponent","TooltipComponent","ArrowComponent","popperProps","tooltipProps","tooltipArrowProps","TransitionPropsInner","Tooltip$1","getIcon","icon","menuLabel","leading","MuiListItemIcon","MenuItem","allowForLeadingIcons","iconPathBefore","iconPathAfter","hasAutoFocus","isDense","isSubMenuParent","hasDisabledGutters","hasDivider","focusVisibleClassName","menuItem","MuiMenuItem","MuiListItemText","getAllGroups","menuDefinition","SubMenu","setAnchorEl","parentMenuItem","parentItemProps","handleParentMenuItemClick","renderSubMenuItems","includedGroups","group","GroupedMenuItemList","Menu","getOrderedGroupItems","groupId","allItems","menuProps","commandHandler","groupsToInclude","sortedGroups","itemArray","allowSpaceForLeadingIcons","createMenuItemProps","isLastItemInGroup","divKey","itemInfo","menuItemProps","TopLevelMenu","columnId","MenuColumn","metadata","Grid","List","GridMenu","multiColumnMenu","sortedColumns","columnNumbers","columnName","col","getUsePromiseOptionsDefaults","usePromise","promiseFactoryCallback","defaultValueRef","optionsDefaultedRef","setIsLoading","promiseIsCurrent","MenuIcon","HamburgerMenuButton","menuProvider","normalMenu","fullMenu","containerRef","ariaLabelPrefix","isMenuOpen","setMenuOpen","showFullMenu","setShowFullMenu","handleMenuItemClick","handleMenuButtonClick","prevIsOpen","isOpening","menuCommandHandler","command","setOffset","normalMenuData","fullMenuData","menu","IconButton","Drawer","isTooltipSuppressed","adjustMarginToAlignToEdge","MuiIconButton","Spinner","LoaderCircle","TextField","hasError","helperText","onFocus","onBlur","ShadLabel","Toolbar","AppBar","MuiToolbar","alertVariants","Alert","AlertTitle","AlertDescription","Card","CardHeader","CardTitle","CardDescription","CardContent","CardFooter","Sonner","Toaster","Slider","SliderPrimitive","Switch","SwitchPrimitives","Tabs","TabsList","TabsTrigger","TabsContent","InstallButton","isInstalling","handleClick","buttonText","Download","EnableButton","isEnabling","DisableButton","isDisabling","UpdateButton","isUpdating","MarkdownRenderer","markdown","anchorTarget","Markdown","FilterButton","Filter","DropdownMenuItemType","DropdownMenuItemType2","FilterDropdown","groups","NoExtensionsFound","MoreInfo","category","downloads","languages","moreInfoUrl","numberFormatted","NumberFormat","handleScrollToBottom","User","locale","LucideLink","CircleHelp","VersionHistory","versionHistory","showAllVersions","setShowAllVersions","currentDate","formatTimeString","dateString","date","dateDiff","yearDiff","monthDiff","dayDiff","timeString","sortedEntries","Footer","publisherDisplayName","fileSize","locales","formattedFileSize","formatBytes","languageNames","codes","displayNames","useEvent","unsubscriber","noopUnsubscriber","useEventAsync","unsubscribe","unsub"],"mappings":"48CAGA,MAAMA,GAAgBC,GAAAA,oBAAoB,CAAE,OAAQ,KAAO,CAAA,EAyDpD,SAASC,KAAMC,EAAsB,CACnC,OAAAH,GAAcI,GAAAA,KAAKD,CAAM,CAAC,CACnC,CCzDO,MAAME,GAAQC,EAAM,WACzB,CAAC,CAAE,UAAAC,EAAW,KAAAC,EAAM,GAAGC,CAAA,EAASC,IAE5BC,EAAA,IAAC,QAAA,CACC,KA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ACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MAEA,MAEA,MAEA,MAEA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,MAEA,MAEA,MAEA,MAEA,MACA,MACA,MACA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,KACF,EAAGC,GAAI,CACL,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,KACF,EAAGC,GAAI,CACL,UACA,SACA,YACA,UACA,cACA,SACA,SACA,OACA,WACA,WACA,UACA,UACA,eACA,eACA,OACA,WACA,kBACA,MACA,SACA,WACA,eACA,gBACA,SACA,WACA,eACA,UACA,kBACA,QACA,OACA,OACA,UACA,QACA,QACA,QACA,WACA,YACA,SACA,YACA,UACA,UACA,OACA,OACA,OACA,OACA,SACA,gBACA,gBACA,YACA,YACA,cACA,aACA,kBACA,kBACA,YACA,YACA,QACA,WACA,UACA,QACA,UACA,UACA,SACA,SACA,SACA,OACA,aACA,QACA,SACA,eACA,oBACA,0BACA,SACA,qBACA,sBACA,UACA,qBACA,cACA,cACA,cACA,cACA,mBACA,mBACA,qBACA,YACA,OACA,oBAGA,uBACA,uBACA,sBACA,yBACA,wBACA,qBACA,UACA,UACA,UACA,UACA,UACA,UACA,UACA,eACA,cACA,eACA,oBACA,qBACA,0BACA,0BACA,eACA,eACA,YACA,gBACA,cACA,eACA,iBACA,wBACA,mBACA,WACA,QACA,aACA,aACA,aACA,2BACA,4BACA,YACF,EAAGC,GAAIC,KACP,SAASC,GAAER,EAAGJ,EAAI,GAAI,CACpB,OAAOA,IAAMI,EAAIA,EAAE,YAAa,GAAGA,KAAKM,GAAIA,GAAEN,CAAC,EAAI,CACrD,CACA,SAASS,GAAET,EAAG,CACZ,OAAOQ,GAAER,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AAOA,EACR,EACD,WAAY,CACV,MAAOA,EACR,EACD,aAAc,CACZ,MAAOA,EACR,EACD,cAAe,CACb,MAAOA,EACR,EACD,YAAa,CACX,MAAOA,EACR,EACD,SAAU,CACR,MAAOA,EACR,EACD,SAAU,CACR,MAAOA,EACR,EACD,cAAe,CACb,MAAOA,EACR,EACD,mBAAoB,CAClB,MAAOA,EACR,EACD,iBAAkB,CAChB,MAAOA,EACR,EACD,aAAc,CACZ,MAAOA,EACR,EACD,kBAAmB,CACjB,MAAOA,EACR,EACD,gBAAiB,CACf,MAAOA,EACR,EACD,EAAG,CACD,MAAOD,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,OAAQ,CACN,MAAOA,EACR,EACD,UAAW,CACT,MAAOA,EACR,EACD,YAAa,CACX,MAAOA,EACR,EACD,aAAc,CACZ,MAAOA,EACR,EACD,WAAY,CACV,MAAOA,EACR,EACD,QAAS,CACP,MAAOA,EACR,EACD,QAAS,CACP,MAAOA,EACR,EACD,aAAc,CACZ,MAAOA,EACR,EACD,kBAAmB,CACjB,MAAOA,EACR,EACD,gBAAiB,CACf,MAAOA,EACR,EACD,YAAa,CACX,MAAOA,EACR,EACD,iBAAkB,CAChB,MAAOA,EACR,EACD,eAAgB,CACd,MAAOA,EACR,EAED,aAAc,CACZ,YAAa,GACb,UAAWxwB,IAAU,CACnB,eAAgB,CACd,QAASA,CACV,CACP,EACG,EACD,QAAS,CAAE,EACX,SAAU,CAAE,EACZ,aAAc,CAAE,EAChB,WAAY,CAAE,EACd,WAAY,CAAE,EAEd,UAAW,CAAE,EACb,cAAe,CAAE,EACjB,SAAU,CAAE,EACZ,eAAgB,CAAE,EAClB,WAAY,CAAE,EACd,aAAc,CAAE,EAChB,MAAO,CAAE,EACT,KAAM,C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;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","x_google_ignoreList":[3,43,44,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,83,84,85,86,87,88,89,90,91,92,93,94,95,96,97,98,99,100,101,102,103,104,105,106,107,108,109,110,111,112,113,114,115,116,117,118,119,120,121,122,123,124,125,126,127,128,129,130,131,132,133,134,135,136,137,138,139,140,141,142,143,144,145,146,147,148,149,150,151,152,153,154,155,156,157,158,159,160,161,162,163,164,165,166,167,168,169,170,171,172,173,174,175,176,177,178,179,180,181,182,183,184,185,186,187,188,189,190,191,192,193,194,195,196,197,198,199,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,226]} \ No newline at end of file diff --git a/lib/platform-bible-react/dist/index.js b/lib/platform-bible-react/dist/index.js index 0818f97413..3a424088ac 100644 --- a/lib/platform-bible-react/dist/index.js +++ b/lib/platform-bible-react/dist/index.js @@ -1,6 +1,6 @@ import Xs, { jsx as s, jsxs as x, Fragment as ie } from "react/jsx-runtime"; import * as D from "react"; -import S, { forwardRef as Qn, useCallback as kt, useState as ut, useRef as ge, useEffect as ae, useLayoutEffect as Qo, useMemo as $t } from "react"; +import T, { forwardRef as Qn, useCallback as kt, useState as ut, useRef as ge, useEffect as ae, useLayoutEffect as Qo, useMemo as $t } from "react"; import { History as Ys, ChevronRight as Ka, Check as tr, Circle as Ja, ArrowDownWideNarrow as Ws, Clock as qs, Bookmark as Ks, X as Js, Search as Zs, ChevronsUpDown as Qs, FilterIcon as tl, ChevronDown as er, ChevronUp as el, ArrowLeftIcon as nl, ChevronLeftIcon as rl, ChevronRightIcon as ol, ArrowRightIcon as al, CircleCheckIcon as il, CircleXIcon as sl, CircleHelpIcon as ll, ArrowUpIcon as cl, ArrowDownIcon as dl, ArrowUpDownIcon as pl, PanelLeft as ul, ChevronLeft as wl, LoaderCircle as fl, Download as ml, Filter as hl, User as gl, Link as bl, CircleHelp as vl } from "lucide-react"; import be, { clsx as yl } from "clsx"; import { extendTailwindMerge as xl } from "tailwind-merge"; @@ -23,11 +23,11 @@ import * as Rt from "@radix-ui/react-tabs"; import * as ri from "@radix-ui/react-separator"; import * as En from "@radix-ui/react-tooltip"; import Pl, { ThemeContext as $l, internal_processStyles as Il } from "@mui/styled-engine"; -import { MenuItem as Al, ListItemText as Ml, ListItemIcon as oi, Menu as Dl, Grid as ai, List as Bl, IconButton as ii, Drawer as jl, AppBar as Vl, Toolbar as zl } from "@mui/material"; +import { MenuItem as Al, ListItemText as Ml, ListItemIcon as oi, Menu as Dl, Grid as ai, List as jl, IconButton as ii, Drawer as Bl, AppBar as Vl, Toolbar as zl } from "@mui/material"; import * as Ll from "react-dom"; -import Bn from "react-dom"; +import jn from "react-dom"; import { Toaster as Fl } from "sonner"; -import { toast as Vh } from "sonner"; +import { toast as Bh } from "sonner"; import * as on from "@radix-ui/react-slider"; import * as Xr from "@radix-ui/react-switch"; import Ul from "markdown-to-jsx"; @@ -35,7 +35,7 @@ const Gl = xl({ prefix: "tw-" }); function N(...t) { return Gl(yl(t)); } -const Xe = S.forwardRef( +const Xe = T.forwardRef( ({ className: t, type: e, ...n }, r) => /* @__PURE__ */ s( "input", { @@ -832,7 +832,7 @@ et(St, "defaultVersification", ue.English), et(St, "verseRangeSeparator", "-"), et(St, "ValidStatusType", ui); class Qe extends Error { } -const wo = wt.Root, wi = wt.Trigger, oc = wt.Group, nh = wt.Portal, rh = wt.Sub, oh = wt.RadioGroup, ac = S.forwardRef(({ className: t, inset: e, children: n, ...r }, o) => /* @__PURE__ */ x( +const wo = wt.Root, wi = wt.Trigger, oc = wt.Group, eh = wt.Portal, nh = wt.Sub, rh = wt.RadioGroup, ac = T.forwardRef(({ className: t, inset: e, children: n, ...r }, o) => /* @__PURE__ */ x( wt.SubTrigger, { ref: o, @@ -849,7 +849,7 @@ const wo = wt.Root, wi = wt.Trigger, oc = wt.Group, nh = wt.Portal, rh = wt.Sub, } )); ac.displayName = wt.SubTrigger.displayName; -const ic = S.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( +const ic = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( wt.SubContent, { ref: n, @@ -861,7 +861,7 @@ const ic = S.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( } )); ic.displayName = wt.SubContent.displayName; -const rr = S.forwardRef(({ className: t, sideOffset: e = 4, ...n }, r) => /* @__PURE__ */ s(wt.Portal, { children: /* @__PURE__ */ s( +const rr = T.forwardRef(({ className: t, sideOffset: e = 4, ...n }, r) => /* @__PURE__ */ s(wt.Portal, { children: /* @__PURE__ */ s( wt.Content, { ref: r, @@ -875,7 +875,7 @@ const rr = S.forwardRef(({ className: t, sideOffset: e = 4, ...n }, r) => /* @__ } ) })); rr.displayName = wt.Content.displayName; -const fi = S.forwardRef(({ className: t, inset: e, ...n }, r) => /* @__PURE__ */ s( +const fi = T.forwardRef(({ className: t, inset: e, ...n }, r) => /* @__PURE__ */ s( wt.Item, { ref: r, @@ -889,7 +889,7 @@ const fi = S.forwardRef(({ className: t, inset: e, ...n }, r) => /* @__PURE__ */ } )); fi.displayName = wt.Item.displayName; -const fo = S.forwardRef(({ className: t, children: e, checked: n, ...r }, o) => /* @__PURE__ */ x( +const fo = T.forwardRef(({ className: t, children: e, checked: n, ...r }, o) => /* @__PURE__ */ x( wt.CheckboxItem, { ref: o, @@ -906,7 +906,7 @@ const fo = S.forwardRef(({ className: t, children: e, checked: n, ...r }, o) => } )); fo.displayName = wt.CheckboxItem.displayName; -const mi = S.forwardRef(({ className: t, children: e, ...n }, r) => /* @__PURE__ */ x( +const mi = T.forwardRef(({ className: t, children: e, ...n }, r) => /* @__PURE__ */ x( wt.RadioItem, { ref: r, @@ -922,7 +922,7 @@ const mi = S.forwardRef(({ className: t, children: e, ...n }, r) => /* @__PURE__ } )); mi.displayName = wt.RadioItem.displayName; -const Sn = S.forwardRef(({ className: t, inset: e, ...n }, r) => /* @__PURE__ */ s( +const Sn = T.forwardRef(({ className: t, inset: e, ...n }, r) => /* @__PURE__ */ s( wt.Label, { ref: r, @@ -931,7 +931,7 @@ const Sn = S.forwardRef(({ className: t, inset: e, ...n }, r) => /* @__PURE__ */ } )); Sn.displayName = wt.Label.displayName; -const or = S.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( +const or = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( wt.Separator, { ref: n, @@ -1090,16 +1090,16 @@ function gc(t) { if (hc(e)) return dn.find((r) => ot.bookIdToEnglishName(r) === e); } -function ah({ scrRef: t, handleSubmit: e }) { +function oh({ scrRef: t, handleSubmit: e }) { const [n, r] = ut(""), [o, a] = ut( ot.bookNumberToId(t.bookNum) ), [i, l] = ut(t.chapterNum ?? 0), [c, d] = ut( ot.bookNumberToId(t.bookNum) - ), [p, f] = ut(!1), [w, g] = ut(p), v = ge(void 0), m = ge(void 0), h = ge(void 0), T = kt( - (k) => fc(k).filter((B) => { - const M = ot.bookIdToEnglishName(B).toLowerCase(), J = n.replace(/[^a-zA-Z]/g, "").toLowerCase(); + ), [p, f] = ut(!1), [w, g] = ut(p), v = ge(void 0), m = ge(void 0), h = ge(void 0), S = kt( + (k) => fc(k).filter((j) => { + const M = ot.bookIdToEnglishName(j).toLowerCase(), J = n.replace(/[^a-zA-Z]/g, "").toLowerCase(); return M.includes(J) || // Match book name - B.toLowerCase().includes(J); + j.toLowerCase().includes(J); }), [n] ), A = (k) => { @@ -1111,10 +1111,10 @@ function ah({ scrRef: t, handleSubmit: e }) { } f(k); }, []), b = kt( - (k, B, M, J) => { + (k, j, M, J) => { if (l( ot.bookNumberToId(t.bookNum) !== k ? 1 : t.chapterNum - ), B || tn(k) === -1) { + ), j || tn(k) === -1) { e({ bookNum: ot.bookIdToNumber(k), chapterNum: M || 1, @@ -1122,16 +1122,16 @@ function ah({ scrRef: t, handleSubmit: e }) { }), f(!1), r(""); return; } - a(o !== k ? k : ""), f(!B); + a(o !== k ? k : ""), f(!j); }, [e, t.bookNum, t.chapterNum, o] ), $ = (k) => { k <= 0 || k > tn(o) || b(o, !0, k); }, z = kt(() => { wc.forEach((k) => { - const B = n.match(k); - if (B) { - const [M, J = void 0, q = void 0] = B.slice(1), U = gc(M); + const j = n.match(k); + if (j) { + const [M, J = void 0, q = void 0] = j.slice(1), U = gc(M); (ot.isBookIdValid(M) || U) && b( U ?? M, !0, @@ -1150,24 +1150,24 @@ function ah({ scrRef: t, handleSubmit: e }) { }, [p] ), C = (k) => { - const { key: B } = k; - B === "ArrowRight" || B === "ArrowLeft" || B === "ArrowDown" || B === "ArrowUp" || B === "Enter" || (v.current.dispatchEvent(new KeyboardEvent("keydown", { key: B })), v.current.focus()); + const { key: j } = k; + j === "ArrowRight" || j === "ArrowLeft" || j === "ArrowDown" || j === "ArrowUp" || j === "Enter" || (v.current.dispatchEvent(new KeyboardEvent("keydown", { key: j })), v.current.focus()); }, P = (k) => { - const { key: B } = k; + const { key: j } = k; if (c === o) { - if (B === "Enter") { + if (j === "Enter") { k.preventDefault(), b(o, !0, i); return; } let M = 0; - if (B === "ArrowRight") + if (j === "ArrowRight") if (i < tn(c)) M = 1; else { k.preventDefault(); return; } - else if (B === "ArrowLeft") + else if (j === "ArrowLeft") if (i > 1) M = -1; else { @@ -1175,7 +1175,7 @@ function ah({ scrRef: t, handleSubmit: e }) { return; } else - B === "ArrowDown" ? M = 6 : B === "ArrowUp" && (M = -6); + j === "ArrowDown" ? M = 6 : j === "ArrowUp" && (M = -6); i + M <= 0 || i + M > tn(c) ? l(0) : M !== 0 && (l(i + M), k.preventDefault()); } }; @@ -1229,9 +1229,9 @@ function ah({ scrRef: t, handleSubmit: e }) { } ), na.map( - (k, B) => T(k).length > 0 && /* @__PURE__ */ x("div", { children: [ + (k, j) => S(k).length > 0 && /* @__PURE__ */ x("div", { children: [ /* @__PURE__ */ s(Sn, { className: "tw-font-semibold tw-text-foreground/80", children: pc[k] }), - T(k).map((M) => /* @__PURE__ */ s("div", { children: /* @__PURE__ */ s( + S(k).map((M) => /* @__PURE__ */ s("div", { children: /* @__PURE__ */ s( lc, { bookId: M, @@ -1257,7 +1257,7 @@ function ah({ scrRef: t, handleSubmit: e }) { ) } ) }, M)), - na.length - 1 !== B ? /* @__PURE__ */ s(or, {}) : void 0 + na.length - 1 !== j ? /* @__PURE__ */ s(or, {}) : void 0 ] }, k) ) ] @@ -1289,15 +1289,15 @@ const bc = kn( size: "default" } } -), gt = S.forwardRef( +), gt = T.forwardRef( ({ className: t, variant: e, size: n, asChild: r = !1, ...o }, a) => /* @__PURE__ */ s(r ? He : "button", { className: N(bc({ variant: e, size: n, className: t })), ref: a, ...o }) ); gt.displayName = "Button"; const vc = kn( "tw-text-sm tw-font-medium tw-leading-none peer-disabled:tw-cursor-not-allowed peer-disabled:tw-opacity-70" -), Ht = S.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s(Za.Root, { ref: n, className: N("pr-twp", vc(), t), ...e })); +), Ht = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s(Za.Root, { ref: n, className: N("pr-twp", vc(), t), ...e })); Ht.displayName = Za.Root.displayName; -const hi = S.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( +const hi = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( fn.Root, { className: N("pr-twp tw-grid tw-gap-2", t), @@ -1306,7 +1306,7 @@ const hi = S.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( } )); hi.displayName = fn.Root.displayName; -const Yr = S.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( +const Yr = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( fn.Item, { ref: n, @@ -1319,7 +1319,7 @@ const Yr = S.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( } )); Yr.displayName = fn.Item.displayName; -const yc = mn.Root, xc = mn.Trigger, gi = S.forwardRef(({ className: t, align: e = "center", sideOffset: n = 4, ...r }, o) => /* @__PURE__ */ s(mn.Portal, { children: /* @__PURE__ */ s( +const yc = mn.Root, xc = mn.Trigger, gi = T.forwardRef(({ className: t, align: e = "center", sideOffset: n = 4, ...r }, o) => /* @__PURE__ */ s(mn.Portal, { children: /* @__PURE__ */ s( mn.Content, { ref: o, @@ -1333,7 +1333,7 @@ const yc = mn.Root, xc = mn.Trigger, gi = S.forwardRef(({ className: t, align: e } ) })); gi.displayName = mn.Content.displayName; -const Nc = Yt.Portal, bi = S.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( +const Nc = Yt.Portal, bi = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( Yt.Overlay, { ref: n, @@ -1345,7 +1345,7 @@ const Nc = Yt.Portal, bi = S.forwardRef(({ className: t, ...e }, n) => /* @__PUR } )); bi.displayName = Yt.Overlay.displayName; -const kc = S.forwardRef(({ className: t, children: e, ...n }, r) => /* @__PURE__ */ x(Nc, { children: [ +const kc = T.forwardRef(({ className: t, children: e, ...n }, r) => /* @__PURE__ */ x(Nc, { children: [ /* @__PURE__ */ s(bi, {}), /* @__PURE__ */ x( Yt.Content, @@ -1367,7 +1367,7 @@ const kc = S.forwardRef(({ className: t, children: e, ...n }, r) => /* @__PURE__ ) ] })); kc.displayName = Yt.Content.displayName; -const Ec = S.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( +const Ec = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( Yt.Title, { ref: n, @@ -1376,7 +1376,7 @@ const Ec = S.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( } )); Ec.displayName = Yt.Title.displayName; -const Sc = S.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( +const Sc = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( Yt.Description, { ref: n, @@ -1385,7 +1385,7 @@ const Sc = S.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( } )); Sc.displayName = Yt.Description.displayName; -const vi = S.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( +const vi = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( Ot, { ref: n, @@ -1397,7 +1397,7 @@ const vi = S.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( } )); vi.displayName = Ot.displayName; -const yi = S.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ x("div", { className: "tw-flex tw-items-center tw-border-b tw-px-3", children: [ +const yi = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ x("div", { className: "tw-flex tw-items-center tw-border-b tw-px-3", children: [ /* @__PURE__ */ s(Zs, { className: "tw-me-2 tw-h-4 tw-w-4 tw-shrink-0 tw-opacity-50" }), /* @__PURE__ */ s( Ot.Input, @@ -1412,7 +1412,7 @@ const yi = S.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ x("div", ) ] })); yi.displayName = Ot.Input.displayName; -const xi = S.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( +const xi = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( Ot.List, { ref: n, @@ -1421,9 +1421,9 @@ const xi = S.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( } )); xi.displayName = Ot.List.displayName; -const Ni = S.forwardRef((t, e) => /* @__PURE__ */ s(Ot.Empty, { ref: e, className: "tw-py-6 tw-text-center tw-text-sm", ...t })); +const Ni = T.forwardRef((t, e) => /* @__PURE__ */ s(Ot.Empty, { ref: e, className: "tw-py-6 tw-text-center tw-text-sm", ...t })); Ni.displayName = Ot.Empty.displayName; -const Tc = S.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( +const Tc = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( Ot.Group, { ref: n, @@ -1435,7 +1435,7 @@ const Tc = S.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( } )); Tc.displayName = Ot.Group.displayName; -const Cc = S.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( +const Cc = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( Ot.Separator, { ref: n, @@ -1444,7 +1444,7 @@ const Cc = S.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( } )); Cc.displayName = Ot.Separator.displayName; -const ki = S.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( +const ki = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( Ot.Item, { ref: n, @@ -1566,12 +1566,12 @@ function Rc({ ] }); } var _c = /* @__PURE__ */ ((t) => (t.CURRENT_BOOK = "current book", t.CHOOSE_BOOKS = "choose books", t))(_c || {}); -const ih = Object.freeze([ +const ah = Object.freeze([ "%webView_bookSelector_currentBook%", "%webView_bookSelector_choose%", "%webView_bookSelector_chooseBooks%" ]), _r = (t, e) => t[e] ?? e; -function sh({ +function ih({ handleBookSelectionModeChange: t, currentBookName: e, onSelectBooks: n, @@ -1661,7 +1661,7 @@ function Pc({ table: t }) { ] }) ] }); } -const hn = bt.Root, $c = bt.Group, gn = bt.Value, De = S.forwardRef(({ className: t, children: e, ...n }, r) => /* @__PURE__ */ x( +const hn = bt.Root, $c = bt.Group, gn = bt.Value, De = T.forwardRef(({ className: t, children: e, ...n }, r) => /* @__PURE__ */ x( bt.Trigger, { ref: r, @@ -1677,7 +1677,7 @@ const hn = bt.Root, $c = bt.Group, gn = bt.Value, De = S.forwardRef(({ className } )); De.displayName = bt.Trigger.displayName; -const Ei = S.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( +const Ei = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( bt.ScrollUpButton, { ref: n, @@ -1687,7 +1687,7 @@ const Ei = S.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( } )); Ei.displayName = bt.ScrollUpButton.displayName; -const Si = S.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( +const Si = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( bt.ScrollDownButton, { ref: n, @@ -1697,7 +1697,7 @@ const Si = S.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( } )); Si.displayName = bt.ScrollDownButton.displayName; -const Be = S.forwardRef(({ className: t, children: e, position: n = "popper", ...r }, o) => /* @__PURE__ */ s(bt.Portal, { children: /* @__PURE__ */ x( +const je = T.forwardRef(({ className: t, children: e, position: n = "popper", ...r }, o) => /* @__PURE__ */ s(bt.Portal, { children: /* @__PURE__ */ x( bt.Content, { ref: o, @@ -1724,8 +1724,8 @@ const Be = S.forwardRef(({ className: t, children: e, position: n = "popper", .. ] } ) })); -Be.displayName = bt.Content.displayName; -const Ic = S.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( +je.displayName = bt.Content.displayName; +const Ic = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( bt.Label, { ref: n, @@ -1734,7 +1734,7 @@ const Ic = S.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( } )); Ic.displayName = bt.Label.displayName; -const Ut = S.forwardRef(({ className: t, children: e, ...n }, r) => /* @__PURE__ */ x( +const Ut = T.forwardRef(({ className: t, children: e, ...n }, r) => /* @__PURE__ */ x( bt.Item, { ref: r, @@ -1750,7 +1750,7 @@ const Ut = S.forwardRef(({ className: t, children: e, ...n }, r) => /* @__PURE__ } )); Ut.displayName = bt.Item.displayName; -const Ac = S.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( +const Ac = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( bt.Separator, { ref: n, @@ -1779,7 +1779,7 @@ function Mc({ table: t }) { }, children: [ /* @__PURE__ */ s(De, { className: "tw-h-8 tw-w-[70px]", children: /* @__PURE__ */ s(gn, { placeholder: t.getState().pagination.pageSize }) }), - /* @__PURE__ */ s(Be, { side: "top", children: [10, 20, 30, 40, 50].map((e) => /* @__PURE__ */ s(Ut, { value: `${e}`, children: e }, e)) }) + /* @__PURE__ */ s(je, { side: "top", children: [10, 20, 30, 40, 50].map((e) => /* @__PURE__ */ s(Ut, { value: `${e}`, children: e }, e)) }) ] } ) @@ -1850,7 +1850,7 @@ function Mc({ table: t }) { ] }) ] }) }); } -const ar = S.forwardRef(({ className: t, stickyHeader: e, ...n }, r) => /* @__PURE__ */ s("div", { className: N("pr-twp tw-relative tw-w-full", { "tw-overflow-auto": !e }), children: /* @__PURE__ */ s( +const ar = T.forwardRef(({ className: t, stickyHeader: e, ...n }, r) => /* @__PURE__ */ s("div", { className: N("pr-twp tw-relative tw-w-full", { "tw-overflow-auto": !e }), children: /* @__PURE__ */ s( "table", { ref: r, @@ -1859,7 +1859,7 @@ const ar = S.forwardRef(({ className: t, stickyHeader: e, ...n }, r) => /* @__PU } ) })); ar.displayName = "Table"; -const ir = S.forwardRef(({ className: t, stickyHeader: e, ...n }, r) => /* @__PURE__ */ s( +const ir = T.forwardRef(({ className: t, stickyHeader: e, ...n }, r) => /* @__PURE__ */ s( "thead", { ref: r, @@ -1872,9 +1872,9 @@ const ir = S.forwardRef(({ className: t, stickyHeader: e, ...n }, r) => /* @__PU } )); ir.displayName = "TableHeader"; -const sr = S.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s("tbody", { ref: n, className: N("[&_tr:last-child]:tw-border-0", t), ...e })); +const sr = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s("tbody", { ref: n, className: N("[&_tr:last-child]:tw-border-0", t), ...e })); sr.displayName = "TableBody"; -const Dc = S.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( +const Dc = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( "tfoot", { ref: n, @@ -1883,7 +1883,7 @@ const Dc = S.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( } )); Dc.displayName = "TableFooter"; -const oe = S.forwardRef( +const oe = T.forwardRef( ({ className: t, ...e }, n) => /* @__PURE__ */ s( "tr", { @@ -1897,7 +1897,7 @@ const oe = S.forwardRef( ) ); oe.displayName = "TableRow"; -const bn = S.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( +const bn = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( "th", { ref: n, @@ -1909,7 +1909,7 @@ const bn = S.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( } )); bn.displayName = "TableHead"; -const je = S.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( +const Be = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( "td", { ref: n, @@ -1917,8 +1917,8 @@ const je = S.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( ...e } )); -je.displayName = "TableCell"; -const Bc = S.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( +Be.displayName = "TableCell"; +const jc = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( "caption", { ref: n, @@ -1926,8 +1926,8 @@ const Bc = S.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( ...e } )); -Bc.displayName = "TableCaption"; -function jc({ +jc.displayName = "TableCaption"; +function Bc({ columns: t, data: e, enablePagination: n = !1, @@ -1959,16 +1959,16 @@ function jc({ return /* @__PURE__ */ x("div", { className: "pr-twp", children: [ o && /* @__PURE__ */ s(Pc, { table: m }), /* @__PURE__ */ x(ar, { stickyHeader: a, children: [ - /* @__PURE__ */ s(ir, { stickyHeader: a, children: m.getHeaderGroups().map((T) => /* @__PURE__ */ s(oe, { children: T.headers.map((A) => /* @__PURE__ */ s(bn, { children: A.isPlaceholder ? void 0 : cn(A.column.columnDef.header, A.getContext()) }, A.id)) }, T.id)) }), - /* @__PURE__ */ s(sr, { children: (h = m.getRowModel().rows) != null && h.length ? m.getRowModel().rows.map((T) => /* @__PURE__ */ s( + /* @__PURE__ */ s(ir, { stickyHeader: a, children: m.getHeaderGroups().map((S) => /* @__PURE__ */ s(oe, { children: S.headers.map((A) => /* @__PURE__ */ s(bn, { children: A.isPlaceholder ? void 0 : cn(A.column.columnDef.header, A.getContext()) }, A.id)) }, S.id)) }), + /* @__PURE__ */ s(sr, { children: (h = m.getRowModel().rows) != null && h.length ? m.getRowModel().rows.map((S) => /* @__PURE__ */ s( oe, { - onClick: () => i(T, m), - "data-state": T.getIsSelected() && "selected", - children: T.getVisibleCells().map((A) => /* @__PURE__ */ s(je, { children: cn(A.column.columnDef.cell, A.getContext()) }, A.id)) + onClick: () => i(S, m), + "data-state": S.getIsSelected() && "selected", + children: S.getVisibleCells().map((A) => /* @__PURE__ */ s(Be, { children: cn(A.column.columnDef.cell, A.getContext()) }, A.id)) }, - T.id - )) : /* @__PURE__ */ s(oe, { children: /* @__PURE__ */ s(je, { colSpan: t.length, className: "tw-h-24 tw-text-center", children: "No results." }) }) }) + S.id + )) : /* @__PURE__ */ s(oe, { children: /* @__PURE__ */ s(Be, { colSpan: t.length, className: "tw-h-24 tw-text-center", children: "No results." }) }) }) ] }), n && /* @__PURE__ */ x("div", { className: "tw-flex tw-items-center tw-justify-end tw-space-x-2 tw-py-4", children: [ /* @__PURE__ */ s( @@ -2018,15 +2018,15 @@ function Vc({ e(i.reference); }, children: [ - /* @__PURE__ */ s(je, { children: `${ot.bookNumberToEnglishName(i.reference.bookNum)} ${i.reference.chapterNum}:${i.reference.verseNum}` }), - /* @__PURE__ */ s(je, { children: i.text }) + /* @__PURE__ */ s(Be, { children: `${ot.bookNumberToEnglishName(i.reference.bookNum)} ${i.reference.chapterNum}:${i.reference.verseNum}` }), + /* @__PURE__ */ s(Be, { children: i.text }) ] }, `${i.reference.bookNum} ${i.reference.chapterNum}:${i.reference.verseNum}-${i.text}` )) }) ] }); } -const mo = S.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( +const mo = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( Hr.Root, { ref: n, @@ -2071,7 +2071,7 @@ const zc = (t) => t.split(/(?:\r?\n|\r)|(?=(?:\\(?:v|c|id)))/g), ra = (t) => { size: "default" } } -), Uc = S.forwardRef(({ className: t, variant: e, size: n, ...r }, o) => /* @__PURE__ */ s( +), Uc = T.forwardRef(({ className: t, variant: e, size: n, ...r }, o) => /* @__PURE__ */ s( ni.Root, { ref: o, @@ -2080,10 +2080,10 @@ const zc = (t) => t.split(/(?:\r?\n|\r)|(?=(?:\\(?:v|c|id)))/g), ra = (t) => { } )); Uc.displayName = ni.Root.displayName; -const Ci = S.createContext({ +const Ci = T.createContext({ size: "default", variant: "default" -}), Oi = S.forwardRef(({ className: t, variant: e, size: n, children: r, ...o }, a) => /* @__PURE__ */ s( +}), Oi = T.forwardRef(({ className: t, variant: e, size: n, children: r, ...o }, a) => /* @__PURE__ */ s( nr.Root, { ref: a, @@ -2099,8 +2099,8 @@ const Ci = S.createContext({ } )); Oi.displayName = nr.Root.displayName; -const Un = S.forwardRef(({ className: t, children: e, variant: n, size: r, ...o }, a) => { - const i = S.useContext(Ci); +const Un = T.forwardRef(({ className: t, children: e, variant: n, size: r, ...o }, a) => { + const i = T.useContext(Ci); return /* @__PURE__ */ s( nr.Item, { @@ -2118,7 +2118,7 @@ const Un = S.forwardRef(({ className: t, children: e, variant: n, size: r, ...o ); }); Un.displayName = nr.Item.displayName; -const lr = (t) => t === "asc" ? /* @__PURE__ */ s(cl, { className: "tw-ms-2 tw-h-4 tw-w-4" }) : t === "desc" ? /* @__PURE__ */ s(dl, { className: "tw-ms-2 tw-h-4 tw-w-4" }) : /* @__PURE__ */ s(pl, { className: "tw-ms-2 tw-h-4 tw-w-4" }), lh = (t) => ({ +const lr = (t) => t === "asc" ? /* @__PURE__ */ s(cl, { className: "tw-ms-2 tw-h-4 tw-w-4" }) : t === "desc" ? /* @__PURE__ */ s(dl, { className: "tw-ms-2 tw-h-4 tw-w-4" }) : /* @__PURE__ */ s(pl, { className: "tw-ms-2 tw-h-4 tw-w-4" }), sh = (t) => ({ accessorKey: "item", accessorFn: (e) => e.items[0], header: ({ column: e }) => /* @__PURE__ */ x(gt, { variant: "ghost", onClick: () => e.toggleSorting(void 0), children: [ @@ -2132,7 +2132,7 @@ const lr = (t) => t === "asc" ? /* @__PURE__ */ s(cl, { className: "tw-ms-2 tw-h t, lr(n.getIsSorted()) ] }) -}), ch = (t) => ({ +}), lh = (t) => ({ accessorKey: "count", header: ({ column: e }) => /* @__PURE__ */ s("div", { className: "tw-flex tw-justify-end tw-tabular-nums", children: /* @__PURE__ */ x(gt, { variant: "ghost", onClick: () => e.toggleSorting(void 0), children: [ t, @@ -2148,7 +2148,7 @@ const lr = (t) => t === "asc" ? /* @__PURE__ */ s(cl, { className: "tw-ms-2 tw-h t.forEach((c) => { e === "unapproved" ? l.includes(c) || l.push(c) : l = l.filter((d) => d !== c); }), a(l); -}, dh = (t, e, n, r, o) => ({ +}, ch = (t, e, n, r, o) => ({ accessorKey: "status", header: ({ column: a }) => /* @__PURE__ */ s("div", { className: "tw-flex tw-justify-center", children: /* @__PURE__ */ x(gt, { variant: "ghost", onClick: () => a.toggleSorting(void 0), children: [ t, @@ -2204,7 +2204,7 @@ const lr = (t) => t === "asc" ? /* @__PURE__ */ s(cl, { className: "tw-ms-2 tw-h ) ] }); } -}), ph = Object.freeze([ +}), dh = Object.freeze([ "%webView_inventory_all%", "%webView_inventory_approved%", "%webView_inventory_unapproved%", @@ -2255,7 +2255,7 @@ const lr = (t) => t === "asc" ? /* @__PURE__ */ s(cl, { className: "tw-ms-2 tw-h } }), a; }, Jt = (t, e) => t[e] ?? e; -function uh({ +function ph({ scriptureReference: t, setScriptureReference: e, localizedStrings: n, @@ -2268,10 +2268,10 @@ function uh({ onScopeChange: d, columns: p }) { - const f = Jt(n, "%webView_inventory_all%"), w = Jt(n, "%webView_inventory_approved%"), g = Jt(n, "%webView_inventory_unapproved%"), v = Jt(n, "%webView_inventory_unknown%"), m = Jt(n, "%webView_inventory_scope_currentBook%"), h = Jt(n, "%webView_inventory_scope_chapter%"), T = Jt(n, "%webView_inventory_scope_verse%"), A = Jt(n, "%webView_inventory_filter_text%"), R = Jt( + const f = Jt(n, "%webView_inventory_all%"), w = Jt(n, "%webView_inventory_approved%"), g = Jt(n, "%webView_inventory_unapproved%"), v = Jt(n, "%webView_inventory_unknown%"), m = Jt(n, "%webView_inventory_scope_currentBook%"), h = Jt(n, "%webView_inventory_scope_chapter%"), S = Jt(n, "%webView_inventory_scope_verse%"), A = Jt(n, "%webView_inventory_filter_text%"), R = Jt( n, "%webView_inventory_show_additional_items%" - ), [E, b] = ut(!1), [$, z] = ut("all"), [H, C] = ut(""), [P, k] = ut([]), B = $t(() => l ? r instanceof RegExp ? Xc( + ), [E, b] = ut(!1), [$, z] = ut("all"), [H, C] = ut(""), [P, k] = ut([]), j = $t(() => l ? r instanceof RegExp ? Xc( l, t, a, @@ -2279,9 +2279,9 @@ function uh({ r ) : r(l, t, a, i) : [], [l, r, t, a, i]), M = $t(() => { if (E) - return B; + return j; const y = []; - return B.forEach((O) => { + return j.forEach((O) => { const L = O.items[0], F = y.find( (V) => V.items[0] === L ); @@ -2292,7 +2292,7 @@ function uh({ status: O.status }); }), y; - }, [E, B]), J = $t(() => Hc(M, $, H), [M, $, H]), q = $t(() => { + }, [E, j]), J = $t(() => Hc(M, $, H), [M, $, H]), q = $t(() => { var L, F; if (!E) return p; @@ -2347,7 +2347,7 @@ function uh({ defaultValue: $, children: [ /* @__PURE__ */ s(De, { className: "tw-m-1", children: /* @__PURE__ */ s(gn, { placeholder: "Select filter" }) }), - /* @__PURE__ */ x(Be, { children: [ + /* @__PURE__ */ x(je, { children: [ /* @__PURE__ */ s(Ut, { value: "all", children: f }), /* @__PURE__ */ s(Ut, { value: "approved", children: w }), /* @__PURE__ */ s(Ut, { value: "unapproved", children: g }), @@ -2358,10 +2358,10 @@ function uh({ ), /* @__PURE__ */ x(hn, { onValueChange: (y) => tt(y), defaultValue: c, children: [ /* @__PURE__ */ s(De, { className: "tw-m-1", children: /* @__PURE__ */ s(gn, { placeholder: "Select scope" }) }), - /* @__PURE__ */ x(Be, { children: [ + /* @__PURE__ */ x(je, { children: [ /* @__PURE__ */ s(Ut, { value: "book", children: m }), /* @__PURE__ */ s(Ut, { value: "chapter", children: h }), - /* @__PURE__ */ s(Ut, { value: "verse", children: T }) + /* @__PURE__ */ s(Ut, { value: "verse", children: S }) ] }) ] }), /* @__PURE__ */ s( @@ -2390,7 +2390,7 @@ function uh({ ] }) ] }), /* @__PURE__ */ s("div", { className: "tw-m-1 tw-flex-1 tw-overflow-auto tw-rounded-md tw-border", children: /* @__PURE__ */ s( - jc, + Bc, { columns: q, data: J, @@ -2431,7 +2431,7 @@ function Ri({ } ); } -const _i = S.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( +const _i = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( Rt.Root, { orientation: "vertical", @@ -2441,7 +2441,7 @@ const _i = S.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( } )); _i.displayName = Rt.List.displayName; -const Pi = S.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( +const Pi = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( Rt.List, { ref: n, @@ -2453,7 +2453,7 @@ const Pi = S.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( } )); Pi.displayName = Rt.List.displayName; -const Yc = S.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( +const Yc = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( Rt.Trigger, { ref: n, @@ -2463,7 +2463,7 @@ const Yc = S.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( t ) } -)), $i = S.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( +)), $i = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( Rt.Content, { ref: n, @@ -2476,7 +2476,7 @@ const Yc = S.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( } )); $i.displayName = Rt.Content.displayName; -function wh({ +function uh({ tabList: t, onSearch: e, searchPlaceholder: n, @@ -2502,7 +2502,7 @@ function wh({ ] }) ] }); } -const ho = S.forwardRef(({ className: t, orientation: e = "horizontal", decorative: n = !0, ...r }, o) => /* @__PURE__ */ s( +const ho = T.forwardRef(({ className: t, orientation: e = "horizontal", decorative: n = !0, ...r }, o) => /* @__PURE__ */ s( ri.Root, { ref: o, @@ -2526,7 +2526,7 @@ function oa({ className: t, ...e }) { } ); } -const Wc = En.Provider, qc = En.Root, Kc = En.Trigger, Ii = S.forwardRef(({ className: t, sideOffset: e = 4, ...n }, r) => /* @__PURE__ */ s( +const Wc = En.Provider, qc = En.Root, Kc = En.Trigger, Ii = T.forwardRef(({ className: t, sideOffset: e = 4, ...n }, r) => /* @__PURE__ */ s( En.Content, { ref: r, @@ -2539,14 +2539,14 @@ const Wc = En.Provider, qc = En.Root, Kc = En.Trigger, Ii = S.forwardRef(({ clas } )); Ii.displayName = En.Content.displayName; -const Jc = "16rem", Zc = "3rem", Qc = "b", Ai = S.createContext(void 0); +const Jc = "16rem", Zc = "3rem", Ai = T.createContext(void 0); function cr() { - const t = S.useContext(Ai); + const t = T.useContext(Ai); if (!t) throw new Error("useSidebar must be used within a SidebarProvider."); return t; } -const Mi = S.forwardRef( +const Mi = T.forwardRef( ({ defaultOpen: t = !0, open: e, @@ -2556,20 +2556,13 @@ const Mi = S.forwardRef( children: a, ...i }, l) => { - const [c, d] = S.useState(t), p = e ?? c, f = S.useCallback( + const [c, d] = T.useState(t), p = e ?? c, f = T.useCallback( (m) => { const h = typeof m == "function" ? m(p) : m; n ? n(h) : d(h); }, [n, p] - ), w = S.useCallback(() => f((m) => !m), [f]); - S.useEffect(() => { - const m = (h) => { - h.key === Qc && (h.metaKey || h.ctrlKey) && (h.preventDefault(), w()); - }; - return window.addEventListener("keydown", m), () => window.removeEventListener("keydown", m); - }, [w]); - const g = p ? "expanded" : "collapsed", v = S.useMemo( + ), w = T.useCallback(() => f((m) => !m), [f]), g = p ? "expanded" : "collapsed", v = T.useMemo( () => ({ state: g, open: p, @@ -2591,7 +2584,7 @@ const Mi = S.forwardRef( ), className: N( // Removed tw-min-h-svh - "tw-group/sidebar-wrapper pr-twp tw-flex tw-w-full has-[[data-variant=inset]]:tw-bg-sidebar", + "tw-group/sidebar-wrapper has-[[data-variant=inset]]:tw-bg-sidebar pr-twp tw-flex tw-w-full", r ), ref: l, @@ -2602,7 +2595,7 @@ const Mi = S.forwardRef( } ); Mi.displayName = "SidebarProvider"; -const Di = S.forwardRef( +const Di = T.forwardRef( ({ side: t = "left", variant: e = "sidebar", @@ -2616,7 +2609,7 @@ const Di = S.forwardRef( "div", { className: N( - "tw-flex tw-h-full tw-w-[--sidebar-width] tw-flex-col tw-bg-sidebar tw-text-sidebar-foreground", + "tw-bg-sidebar tw-text-sidebar-foreground tw-flex tw-h-full tw-w-[--sidebar-width] tw-flex-col", r ), ref: i, @@ -2627,7 +2620,7 @@ const Di = S.forwardRef( "div", { ref: i, - className: "tw-group tw-peer tw-hidden tw-text-sidebar-foreground md:tw-block", + className: "tw-text-sidebar-foreground tw-group tw-peer tw-hidden md:tw-block", "data-state": l, "data-collapsible": l === "collapsed" ? n : "", "data-variant": e, @@ -2660,7 +2653,7 @@ const Di = S.forwardRef( "div", { "data-sidebar": "sidebar", - className: "tw-flex tw-h-full tw-w-full tw-flex-col tw-bg-sidebar group-data-[variant=floating]:tw-rounded-lg group-data-[variant=floating]:tw-border group-data-[variant=floating]:tw-border-sidebar-border group-data-[variant=floating]:tw-shadow", + className: "tw-bg-sidebar group-data-[variant=floating]:tw-border-sidebar-border tw-flex tw-h-full tw-w-full tw-flex-col group-data-[variant=floating]:tw-rounded-lg group-data-[variant=floating]:tw-border group-data-[variant=floating]:tw-shadow", children: o } ) @@ -2672,7 +2665,7 @@ const Di = S.forwardRef( } ); Di.displayName = "Sidebar"; -const td = S.forwardRef(({ className: t, onClick: e, ...n }, r) => { +const Qc = T.forwardRef(({ className: t, onClick: e, ...n }, r) => { const { toggleSidebar: o } = cr(); return /* @__PURE__ */ x( gt, @@ -2693,8 +2686,8 @@ const td = S.forwardRef(({ className: t, onClick: e, ...n }, r) => { } ); }); -td.displayName = "SidebarTrigger"; -const ed = S.forwardRef( +Qc.displayName = "SidebarTrigger"; +const td = T.forwardRef( ({ className: t, ...e }, n) => { const { toggleSidebar: r } = cr(); return /* @__PURE__ */ s( @@ -2708,10 +2701,10 @@ const ed = S.forwardRef( onClick: r, title: "Toggle Sidebar", className: N( - "tw-absolute tw-inset-y-0 tw-z-20 tw-hidden tw-w-4 tw--translate-x-1/2 tw-transition-all tw-ease-linear after:tw-absolute after:tw-inset-y-0 after:tw-left-1/2 after:tw-w-[2px] hover:after:tw-bg-sidebar-border group-data-[side=left]:tw--right-4 group-data-[side=right]:tw-left-0 sm:tw-flex", + "hover:after:tw-bg-sidebar-border tw-absolute tw-inset-y-0 tw-z-20 tw-hidden tw-w-4 tw--translate-x-1/2 tw-transition-all tw-ease-linear after:tw-absolute after:tw-inset-y-0 after:tw-left-1/2 after:tw-w-[2px] group-data-[side=left]:tw--right-4 group-data-[side=right]:tw-left-0 sm:tw-flex", "[[data-side=left]_&]:tw-cursor-w-resize [[data-side=right]_&]:tw-cursor-e-resize", "[[data-side=left][data-state=collapsed]_&]:tw-cursor-e-resize [[data-side=right][data-state=collapsed]_&]:tw-cursor-w-resize", - "group-data-[collapsible=offcanvas]:tw-translate-x-0 group-data-[collapsible=offcanvas]:after:tw-left-full group-data-[collapsible=offcanvas]:hover:tw-bg-sidebar", + "group-data-[collapsible=offcanvas]:hover:tw-bg-sidebar group-data-[collapsible=offcanvas]:tw-translate-x-0 group-data-[collapsible=offcanvas]:after:tw-left-full", "[[data-side=left][data-collapsible=offcanvas]_&]:tw--right-2", "[[data-side=right][data-collapsible=offcanvas]_&]:tw--left-2", t @@ -2721,8 +2714,8 @@ const ed = S.forwardRef( ); } ); -ed.displayName = "SidebarRail"; -const Bi = S.forwardRef( +td.displayName = "SidebarRail"; +const ji = T.forwardRef( ({ className: t, ...e }, n) => /* @__PURE__ */ s( "main", { @@ -2737,21 +2730,21 @@ const Bi = S.forwardRef( } ) ); -Bi.displayName = "SidebarInset"; -const nd = S.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( +ji.displayName = "SidebarInset"; +const ed = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( Xe, { ref: n, "data-sidebar": "input", className: N( - "tw-h-8 tw-w-full tw-bg-background tw-shadow-none focus-visible:tw-ring-2 focus-visible:tw-ring-sidebar-ring", + "focus-visible:tw-ring-sidebar-ring tw-h-8 tw-w-full tw-bg-background tw-shadow-none focus-visible:tw-ring-2", t ), ...e } )); -nd.displayName = "SidebarInput"; -const rd = S.forwardRef( +ed.displayName = "SidebarInput"; +const nd = T.forwardRef( ({ className: t, ...e }, n) => /* @__PURE__ */ s( "div", { @@ -2762,8 +2755,8 @@ const rd = S.forwardRef( } ) ); -rd.displayName = "SidebarHeader"; -const od = S.forwardRef( +nd.displayName = "SidebarHeader"; +const rd = T.forwardRef( ({ className: t, ...e }, n) => /* @__PURE__ */ s( "div", { @@ -2774,18 +2767,18 @@ const od = S.forwardRef( } ) ); -od.displayName = "SidebarFooter"; -const ad = S.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( +rd.displayName = "SidebarFooter"; +const od = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( ho, { ref: n, "data-sidebar": "separator", - className: N("tw-mx-2 tw-w-auto tw-bg-sidebar-border", t), + className: N("tw-bg-sidebar-border tw-mx-2 tw-w-auto", t), ...e } )); -ad.displayName = "SidebarSeparator"; -const ji = S.forwardRef( +od.displayName = "SidebarSeparator"; +const Bi = T.forwardRef( ({ className: t, ...e }, n) => /* @__PURE__ */ s( "div", { @@ -2799,8 +2792,8 @@ const ji = S.forwardRef( } ) ); -ji.displayName = "SidebarContent"; -const qr = S.forwardRef( +Bi.displayName = "SidebarContent"; +const qr = T.forwardRef( ({ className: t, ...e }, n) => /* @__PURE__ */ s( "div", { @@ -2812,13 +2805,13 @@ const qr = S.forwardRef( ) ); qr.displayName = "SidebarGroup"; -const Kr = S.forwardRef(({ className: t, asChild: e = !1, ...n }, r) => /* @__PURE__ */ s( +const Kr = T.forwardRef(({ className: t, asChild: e = !1, ...n }, r) => /* @__PURE__ */ s( e ? He : "div", { ref: r, "data-sidebar": "group-label", className: N( - "tw-flex tw-h-8 tw-shrink-0 tw-items-center tw-rounded-md tw-px-2 tw-text-xs tw-font-medium tw-text-sidebar-foreground/70 tw-outline-none tw-ring-sidebar-ring tw-transition-[margin,opa] tw-duration-200 tw-ease-linear focus-visible:tw-ring-2 [&>svg]:tw-size-4 [&>svg]:tw-shrink-0", + "tw-text-sidebar-foreground/70 tw-ring-sidebar-ring tw-flex tw-h-8 tw-shrink-0 tw-items-center tw-rounded-md tw-px-2 tw-text-xs tw-font-medium tw-outline-none tw-transition-[margin,opa] tw-duration-200 tw-ease-linear focus-visible:tw-ring-2 [&>svg]:tw-size-4 [&>svg]:tw-shrink-0", "group-data-[collapsible=icon]:tw--mt-8 group-data-[collapsible=icon]:tw-opacity-0", t ), @@ -2826,13 +2819,13 @@ const Kr = S.forwardRef(({ className: t, asChild: e = !1, ...n }, r) => /* @__PU } )); Kr.displayName = "SidebarGroupLabel"; -const id = S.forwardRef(({ className: t, asChild: e = !1, ...n }, r) => /* @__PURE__ */ s( +const ad = T.forwardRef(({ className: t, asChild: e = !1, ...n }, r) => /* @__PURE__ */ s( e ? He : "button", { ref: r, "data-sidebar": "group-action", className: N( - "tw-absolute tw-right-3 tw-top-3.5 tw-flex tw-aspect-square tw-w-5 tw-items-center tw-justify-center tw-rounded-md tw-p-0 tw-text-sidebar-foreground tw-outline-none tw-ring-sidebar-ring tw-transition-transform hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground focus-visible:tw-ring-2 [&>svg]:tw-size-4 [&>svg]:tw-shrink-0", + "tw-text-sidebar-foreground tw-ring-sidebar-ring hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground tw-absolute tw-right-3 tw-top-3.5 tw-flex tw-aspect-square tw-w-5 tw-items-center tw-justify-center tw-rounded-md tw-p-0 tw-outline-none tw-transition-transform focus-visible:tw-ring-2 [&>svg]:tw-size-4 [&>svg]:tw-shrink-0", // Increases the hit area of the button on mobile. "after:tw-absolute after:tw--inset-2 after:md:tw-hidden", "group-data-[collapsible=icon]:tw-hidden", @@ -2841,8 +2834,8 @@ const id = S.forwardRef(({ className: t, asChild: e = !1, ...n }, r) => /* @__PU ...n } )); -id.displayName = "SidebarGroupAction"; -const Jr = S.forwardRef( +ad.displayName = "SidebarGroupAction"; +const Jr = T.forwardRef( ({ className: t, ...e }, n) => /* @__PURE__ */ s( "div", { @@ -2854,7 +2847,7 @@ const Jr = S.forwardRef( ) ); Jr.displayName = "SidebarGroupContent"; -const Vi = S.forwardRef( +const Vi = T.forwardRef( ({ className: t, ...e }, n) => /* @__PURE__ */ s( "ul", { @@ -2866,7 +2859,7 @@ const Vi = S.forwardRef( ) ); Vi.displayName = "SidebarMenu"; -const zi = S.forwardRef( +const zi = T.forwardRef( ({ className: t, ...e }, n) => /* @__PURE__ */ s( "li", { @@ -2878,7 +2871,7 @@ const zi = S.forwardRef( ) ); zi.displayName = "SidebarMenuItem"; -const sd = kn( +const id = kn( // Removed data-[active=true]:tw-bg-sidebar-accent "tw-peer/menu-button tw-flex tw-w-full tw-items-center tw-gap-2 tw-overflow-hidden tw-rounded-md tw-p-2 tw-text-left tw-text-sm tw-outline-none tw-ring-sidebar-ring tw-transition-[width,height,padding] hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground focus-visible:tw-ring-2 active:tw-bg-sidebar-accent active:tw-text-sidebar-accent-foreground disabled:tw-pointer-events-none disabled:tw-opacity-50 tw-group-has-[[data-sidebar=menu-action]]/menu-item:pr-8 aria-disabled:tw-pointer-events-none aria-disabled:tw-opacity-50 data-[active=true]:tw-font-medium data-[active=true]:tw-text-sidebar-accent-foreground data-[state=open]:hover:tw-bg-sidebar-accent data-[state=open]:hover:tw-text-sidebar-accent-foreground group-data-[collapsible=icon]:tw-!size-8 group-data-[collapsible=icon]:tw-!p-2 [&>span:last-child]:tw-truncate [&>svg]:tw-size-4 [&>svg]:tw-shrink-0", { @@ -2898,7 +2891,7 @@ const sd = kn( size: "default" } } -), Li = S.forwardRef( +), Li = T.forwardRef( ({ asChild: t = !1, isActive: e = !1, @@ -2915,7 +2908,7 @@ const sd = kn( "data-sidebar": "menu-button", "data-size": r, "data-active": e, - className: N(sd({ variant: n, size: r }), a), + className: N(id({ variant: n, size: r }), a), ...i } ); @@ -2928,13 +2921,13 @@ const sd = kn( } ); Li.displayName = "SidebarMenuButton"; -const ld = S.forwardRef(({ className: t, asChild: e = !1, showOnHover: n = !1, ...r }, o) => /* @__PURE__ */ s( +const sd = T.forwardRef(({ className: t, asChild: e = !1, showOnHover: n = !1, ...r }, o) => /* @__PURE__ */ s( e ? He : "button", { ref: o, "data-sidebar": "menu-action", className: N( - "tw-peer-hover/menu-button:text-sidebar-accent-foreground tw-absolute tw-right-1 tw-top-1.5 tw-flex tw-aspect-square tw-w-5 tw-items-center tw-justify-center tw-rounded-md tw-p-0 tw-text-sidebar-foreground tw-outline-none tw-ring-sidebar-ring tw-transition-transform hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground focus-visible:tw-ring-2 [&>svg]:tw-size-4 [&>svg]:tw-shrink-0", + "tw-peer-hover/menu-button:text-sidebar-accent-foreground tw-text-sidebar-foreground tw-ring-sidebar-ring hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground tw-absolute tw-right-1 tw-top-1.5 tw-flex tw-aspect-square tw-w-5 tw-items-center tw-justify-center tw-rounded-md tw-p-0 tw-outline-none tw-transition-transform focus-visible:tw-ring-2 [&>svg]:tw-size-4 [&>svg]:tw-shrink-0", // Increases the hit area of the button on mobile. "after:tw-absolute after:tw--inset-2 after:md:tw-hidden", "tw-peer-data-[size=sm]/menu-button:top-1", @@ -2947,15 +2940,15 @@ const ld = S.forwardRef(({ className: t, asChild: e = !1, showOnHover: n = !1, . ...r } )); -ld.displayName = "SidebarMenuAction"; -const cd = S.forwardRef( +sd.displayName = "SidebarMenuAction"; +const ld = T.forwardRef( ({ className: t, ...e }, n) => /* @__PURE__ */ s( "div", { ref: n, "data-sidebar": "menu-badge", className: N( - "tw-pointer-events-none tw-absolute tw-right-1 tw-flex tw-h-5 tw-min-w-5 tw-select-none tw-items-center tw-justify-center tw-rounded-md tw-px-1 tw-text-xs tw-font-medium tw-tabular-nums tw-text-sidebar-foreground", + "tw-text-sidebar-foreground tw-pointer-events-none tw-absolute tw-right-1 tw-flex tw-h-5 tw-min-w-5 tw-select-none tw-items-center tw-justify-center tw-rounded-md tw-px-1 tw-text-xs tw-font-medium tw-tabular-nums", "tw-peer-hover/menu-button:text-sidebar-accent-foreground tw-peer-data-[active=true]/menu-button:text-sidebar-accent-foreground", "tw-peer-data-[size=sm]/menu-button:top-1", "tw-peer-data-[size=default]/menu-button:top-1.5", @@ -2967,9 +2960,9 @@ const cd = S.forwardRef( } ) ); -cd.displayName = "SidebarMenuBadge"; -const dd = S.forwardRef(({ className: t, showIcon: e = !1, ...n }, r) => { - const o = S.useMemo(() => `${Math.floor(Math.random() * 40) + 50}%`, []); +ld.displayName = "SidebarMenuBadge"; +const cd = T.forwardRef(({ className: t, showIcon: e = !1, ...n }, r) => { + const o = T.useMemo(() => `${Math.floor(Math.random() * 40) + 50}%`, []); return /* @__PURE__ */ x( "div", { @@ -2996,15 +2989,15 @@ const dd = S.forwardRef(({ className: t, showIcon: e = !1, ...n }, r) => { } ); }); -dd.displayName = "SidebarMenuSkeleton"; -const pd = S.forwardRef( +cd.displayName = "SidebarMenuSkeleton"; +const dd = T.forwardRef( ({ className: t, ...e }, n) => /* @__PURE__ */ s( "ul", { ref: n, "data-sidebar": "menu-sub", className: N( - "tw-mx-3.5 tw-flex tw-min-w-0 tw-translate-x-px tw-flex-col tw-gap-1 tw-border-l tw-border-sidebar-border tw-px-2.5 tw-py-0.5", + "tw-border-sidebar-border tw-mx-3.5 tw-flex tw-min-w-0 tw-translate-x-px tw-flex-col tw-gap-1 tw-border-l tw-px-2.5 tw-py-0.5", "group-data-[collapsible=icon]:tw-hidden", t ), @@ -3012,12 +3005,12 @@ const pd = S.forwardRef( } ) ); -pd.displayName = "SidebarMenuSub"; -const ud = S.forwardRef( +dd.displayName = "SidebarMenuSub"; +const pd = T.forwardRef( ({ ...t }, e) => /* @__PURE__ */ s("li", { ref: e, ...t }) ); -ud.displayName = "SidebarMenuSubItem"; -const wd = S.forwardRef(({ asChild: t = !1, size: e = "md", isActive: n, className: r, ...o }, a) => /* @__PURE__ */ s( +pd.displayName = "SidebarMenuSubItem"; +const ud = T.forwardRef(({ asChild: t = !1, size: e = "md", isActive: n, className: r, ...o }, a) => /* @__PURE__ */ s( t ? He : "a", { ref: a, @@ -3025,7 +3018,7 @@ const wd = S.forwardRef(({ asChild: t = !1, size: e = "md", isActive: n, classNa "data-size": e, "data-active": n, className: N( - "tw-flex tw-h-7 tw-min-w-0 tw--translate-x-px tw-items-center tw-gap-2 tw-overflow-hidden tw-rounded-md tw-px-2 tw-text-sidebar-foreground tw-outline-none tw-ring-sidebar-ring hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground focus-visible:tw-ring-2 active:tw-bg-sidebar-accent active:tw-text-sidebar-accent-foreground disabled:tw-pointer-events-none disabled:tw-opacity-50 aria-disabled:tw-pointer-events-none aria-disabled:tw-opacity-50 [&>span:last-child]:tw-truncate [&>svg]:tw-size-4 [&>svg]:tw-shrink-0 [&>svg]:tw-text-sidebar-accent-foreground", + "tw-text-sidebar-foreground tw-ring-sidebar-ring hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground active:tw-bg-sidebar-accent active:tw-text-sidebar-accent-foreground [&>svg]:tw-text-sidebar-accent-foreground tw-flex tw-h-7 tw-min-w-0 tw--translate-x-px tw-items-center tw-gap-2 tw-overflow-hidden tw-rounded-md tw-px-2 tw-outline-none focus-visible:tw-ring-2 disabled:tw-pointer-events-none disabled:tw-opacity-50 aria-disabled:tw-pointer-events-none aria-disabled:tw-opacity-50 [&>span:last-child]:tw-truncate [&>svg]:tw-size-4 [&>svg]:tw-shrink-0", "data-[active=true]:tw-bg-sidebar-accent data-[active=true]:tw-text-sidebar-accent-foreground", e === "sm" && "tw-text-xs", e === "md" && "tw-text-sm", @@ -3035,8 +3028,8 @@ const wd = S.forwardRef(({ asChild: t = !1, size: e = "md", isActive: n, classNa ...o } )); -wd.displayName = "SidebarMenuSubButton"; -function fd({ +ud.displayName = "SidebarMenuSubButton"; +function wd({ id: t, extensionLabels: e, projectInfo: n, @@ -3068,7 +3061,7 @@ function fd({ collapsible: "none", variant: "inset", className: "tw-w-96 tw-gap-2 tw-overflow-y-auto tw-rounded tw-bg-slate-100", - children: /* @__PURE__ */ x(ji, { children: [ + children: /* @__PURE__ */ x(Bi, { children: [ /* @__PURE__ */ x(qr, { children: [ /* @__PURE__ */ s(Kr, { className: "tw-text-sm tw-text-gray-400", children: a }), /* @__PURE__ */ s(Jr, { children: /* @__PURE__ */ s(Vi, { children: e.map((f) => /* @__PURE__ */ s(zi, { children: /* @__PURE__ */ s( @@ -3105,7 +3098,7 @@ function fd({ } ); } -function fh({ +function wh({ id: t, extensionLabels: e, projectInfo: n, @@ -3128,7 +3121,7 @@ function fh({ ) }), /* @__PURE__ */ x(Mi, { id: t, className: "tw-h-full tw-flex-1 tw-gap-4 tw-overflow-auto", children: [ /* @__PURE__ */ s( - fd, + wd, { extensionLabels: e, projectInfo: n, @@ -3139,18 +3132,18 @@ function fh({ buttonPlaceholderText: d } ), - /* @__PURE__ */ s(Bi, { className: "tw-overflow-y-auto", children: r }) + /* @__PURE__ */ s(ji, { className: "tw-overflow-y-auto", children: r }) ] }) ] }); } -const ne = "scrBook", md = "scrRef", we = "source", hd = "details", gd = "Scripture Reference", bd = "Scripture Book", Fi = "Type", vd = "Details"; -function yd(t, e) { +const ne = "scrBook", fd = "scrRef", we = "source", md = "details", hd = "Scripture Reference", gd = "Scripture Book", Fi = "Type", bd = "Details"; +function vd(t, e) { const n = e ?? !1; return [ { accessorFn: (r) => `${ot.bookNumberToId(r.start.bookNum)} ${r.start.chapterNum}:${r.start.verseNum}`, id: ne, - header: (t == null ? void 0 : t.scriptureReferenceColumnName) ?? gd, + header: (t == null ? void 0 : t.scriptureReferenceColumnName) ?? hd, cell: (r) => { const o = r.row.original; return r.row.getIsGrouped() ? ot.bookNumberToEnglishName(o.start.bookNum) : r.row.groupingColumnId === ne ? Or(o.start) : void 0; @@ -3161,7 +3154,7 @@ function yd(t, e) { }, { accessorFn: (r) => Or(r.start), - id: md, + id: fd, header: void 0, cell: (r) => { const o = r.row.original; @@ -3181,14 +3174,14 @@ function yd(t, e) { }, { accessorFn: (r) => r.detail, - id: hd, - header: (t == null ? void 0 : t.detailsColumnName) ?? vd, + id: md, + header: (t == null ? void 0 : t.detailsColumnName) ?? bd, cell: (r) => r.getValue(), enableGrouping: !1 } ]; } -const xd = (t) => { +const yd = (t) => { if (!("offset" in t.start)) throw new Error("No offset available in range start"); if (t.end && !("offset" in t.end)) @@ -3196,8 +3189,8 @@ const xd = (t) => { const { offset: e } = t.start; let n = 0; return t.end && ({ offset: n } = t.end), !t.end || Gr(t.start, t.end) === 0 ? `${Rr(t.start)}+${e}` : `${Rr(t.start)}+${e}-${Rr(t.end)}+${n}`; -}, aa = (t) => `${xd({ start: t.start, end: t.end })} ${t.source.displayName} ${t.detail}`; -function mh({ +}, aa = (t) => `${yd({ start: t.start, end: t.end })} ${t.source.displayName} ${t.detail}`; +function fh({ sources: t, showColumnHeaders: e = !1, showSourceColumn: n = !1, @@ -3215,7 +3208,7 @@ function mh({ }))), [t] ), h = $t( - () => yd( + () => vd( { scriptureReferenceColumnName: r, typeColumnName: a, @@ -3231,7 +3224,7 @@ function mh({ { id: ne, desc: !1 } ]) : w([{ id: ne, desc: !1 }]); }, [d]); - const T = Qa({ + const S = Qa({ data: m, columns: h, state: { @@ -3253,14 +3246,14 @@ function mh({ }); ae(() => { if (l) { - const C = T.getSelectedRowModel().rowsById, P = Object.keys(C); + const C = S.getSelectedRowModel().rowsById, P = Object.keys(C); if (P.length === 1) { - const k = m.find((B) => aa(B) === P[0]) || void 0; + const k = m.find((j) => aa(j) === P[0]) || void 0; k && l(k); } } - }, [g, m, l, T]); - const A = o ?? bd, R = a ?? Fi, E = [ + }, [g, m, l, S]); + const A = o ?? gd, R = a ?? Fi, E = [ { label: "No Grouping", value: [] }, { label: `Group by ${A}`, value: [ne] }, { label: `Group by ${R}`, value: [we] }, @@ -3305,12 +3298,12 @@ function mh({ }, children: [ /* @__PURE__ */ s(De, { className: "tw-mb-1 tw-mt-2", children: /* @__PURE__ */ s(gn, {}) }), - /* @__PURE__ */ s(Be, { position: "item-aligned", children: /* @__PURE__ */ s($c, { children: E.map((C) => /* @__PURE__ */ s(Ut, { value: JSON.stringify(C.value), children: C.label }, C.label)) }) }) + /* @__PURE__ */ s(je, { position: "item-aligned", children: /* @__PURE__ */ s($c, { children: E.map((C) => /* @__PURE__ */ s(Ut, { value: JSON.stringify(C.value), children: C.label }, C.label)) }) }) ] } ), /* @__PURE__ */ x(ar, { className: "tw-relative tw-flex tw-flex-col tw-overflow-y-auto tw-p-0", children: [ - e && /* @__PURE__ */ s(ir, { children: T.getHeaderGroups().map((C) => /* @__PURE__ */ s(oe, { children: C.headers.filter((P) => P.column.columnDef.header).map((P) => ( + e && /* @__PURE__ */ s(ir, { children: S.getHeaderGroups().map((C) => /* @__PURE__ */ s(oe, { children: C.headers.filter((P) => P.column.columnDef.header).map((P) => ( /* For sticky column headers to work, we probably need to change the default definition of the shadcn Table component. See https://github.com/shadcn-ui/ui/issues/1151 */ /* @__PURE__ */ s(bn, { colSpan: P.colSpan, className: "top-0 tw-sticky", children: P.isPlaceholder ? void 0 : /* @__PURE__ */ x("div", { children: [ P.column.getCanGroup() ? /* @__PURE__ */ s( @@ -3327,7 +3320,7 @@ function mh({ cn(P.column.columnDef.header, P.getContext()) ] }) }, P.id) )) }, C.id)) }), - /* @__PURE__ */ s(sr, { children: T.getRowModel().rows.map((C, P) => /* @__PURE__ */ s( + /* @__PURE__ */ s(sr, { children: S.getRowModel().rows.map((C, P) => /* @__PURE__ */ s( oe, { "data-state": C.getIsSelected() ? "selected" : "", @@ -3336,7 +3329,7 @@ function mh({ children: C.getVisibleCells().map((k) => { if (!(k.getIsPlaceholder() || k.column.columnDef.enableGrouping && !k.getIsGrouped() && (k.column.columnDef.id !== we || !n))) return /* @__PURE__ */ s( - je, + Be, { className: N( k.column.columnDef.id, @@ -3399,7 +3392,7 @@ const $r = { [pt(24)]: "Y", [pt(25)]: "Z" }; -function hh({ +function mh({ availableScrollGroupIds: t, scrollGroupId: e, onChangeScrollGroupId: n, @@ -3431,7 +3424,7 @@ function hh({ } ) }), /* @__PURE__ */ s( - Be, + je, { style: { zIndex: 250 }, children: t.map((a) => /* @__PURE__ */ s(Ut, { value: `${a}`, children: o[pt(a)] }, `${a}`)) @@ -3441,10 +3434,10 @@ function hh({ } ); } -function gh({ children: t }) { +function hh({ children: t }) { return /* @__PURE__ */ s("div", { className: "pr-twp tw-grid", children: t }); } -function bh({ +function gh({ primary: t, secondary: e, children: n, @@ -3459,7 +3452,7 @@ function bh({ r ? /* @__PURE__ */ s("p", { className: "tw-text-sm tw-text-muted-foreground", children: o }) : /* @__PURE__ */ s("div", { children: n }) ] }); } -function vh({ +function bh({ primary: t, secondary: e, includeSeparator: n = !1 @@ -3472,7 +3465,7 @@ function vh({ n ? /* @__PURE__ */ s(ho, {}) : "" ] }); } -function yh({ +function vh({ id: t, className: e, listItems: n, @@ -3492,10 +3485,10 @@ function yh({ /* @__PURE__ */ s(Ht, { children: a ? a(i) : i }) ] }, i)) }); } -function Nd(t) { +function xd(t) { return t && t.__esModule && Object.prototype.hasOwnProperty.call(t, "default") ? t.default : t; } -function kd(t) { +function Nd(t) { if (t.__esModule) return t; var e = t.default; @@ -3525,7 +3518,7 @@ var go = {}, Ui = { exports: {} }; } t.exports = e, t.exports.__esModule = !0, t.exports.default = t.exports; })(Ui); -var Ed = Ui.exports, Ir = {}; +var kd = Ui.exports, Ir = {}; function bo(t, e) { return process.env.NODE_ENV === "production" ? () => null : function(...r) { return t(...r) || e(...r); @@ -3563,7 +3556,7 @@ function Zt(t, e, n = { o !== "__proto__" && (he(e[o]) && o in t && he(t[o]) ? r[o] = Zt(t[o], e[o], n) : n.clone ? r[o] = he(e[o]) ? Gi(e[o]) : e[o] : r[o] = e[o]); }), r; } -var Zr = { exports: {} }, jn = { exports: {} }, it = {}; +var Zr = { exports: {} }, Bn = { exports: {} }, it = {}; /** @license React v16.13.1 * react-is.production.min.js * @@ -3573,11 +3566,11 @@ var Zr = { exports: {} }, jn = { exports: {} }, it = {}; * LICENSE file in the root directory of this source tree. */ var ia; -function Sd() { +function Ed() { if (ia) return it; ia = 1; - var t = typeof Symbol == "function" && Symbol.for, e = t ? Symbol.for("react.element") : 60103, n = t ? Symbol.for("react.portal") : 60106, r = t ? Symbol.for("react.fragment") : 60107, o = t ? Symbol.for("react.strict_mode") : 60108, a = t ? Symbol.for("react.profiler") : 60114, i = t ? Symbol.for("react.provider") : 60109, l = t ? Symbol.for("react.context") : 60110, c = t ? Symbol.for("react.async_mode") : 60111, d = t ? Symbol.for("react.concurrent_mode") : 60111, p = t ? Symbol.for("react.forward_ref") : 60112, f = t ? Symbol.for("react.suspense") : 60113, w = t ? Symbol.for("react.suspense_list") : 60120, g = t ? Symbol.for("react.memo") : 60115, v = t ? Symbol.for("react.lazy") : 60116, m = t ? Symbol.for("react.block") : 60121, h = t ? Symbol.for("react.fundamental") : 60117, T = t ? Symbol.for("react.responder") : 60118, A = t ? Symbol.for("react.scope") : 60119; + var t = typeof Symbol == "function" && Symbol.for, e = t ? Symbol.for("react.element") : 60103, n = t ? Symbol.for("react.portal") : 60106, r = t ? Symbol.for("react.fragment") : 60107, o = t ? Symbol.for("react.strict_mode") : 60108, a = t ? Symbol.for("react.profiler") : 60114, i = t ? Symbol.for("react.provider") : 60109, l = t ? Symbol.for("react.context") : 60110, c = t ? Symbol.for("react.async_mode") : 60111, d = t ? Symbol.for("react.concurrent_mode") : 60111, p = t ? Symbol.for("react.forward_ref") : 60112, f = t ? Symbol.for("react.suspense") : 60113, w = t ? Symbol.for("react.suspense_list") : 60120, g = t ? Symbol.for("react.memo") : 60115, v = t ? Symbol.for("react.lazy") : 60116, m = t ? Symbol.for("react.block") : 60121, h = t ? Symbol.for("react.fundamental") : 60117, S = t ? Symbol.for("react.responder") : 60118, A = t ? Symbol.for("react.scope") : 60119; function R(b) { if (typeof b == "object" && b !== null) { var $ = b.$$typeof; @@ -3636,7 +3629,7 @@ function Sd() { }, it.isSuspense = function(b) { return R(b) === f; }, it.isValidElementType = function(b) { - return typeof b == "string" || typeof b == "function" || b === r || b === d || b === a || b === o || b === f || b === w || typeof b == "object" && b !== null && (b.$$typeof === v || b.$$typeof === g || b.$$typeof === i || b.$$typeof === l || b.$$typeof === p || b.$$typeof === h || b.$$typeof === T || b.$$typeof === A || b.$$typeof === m); + return typeof b == "string" || typeof b == "function" || b === r || b === d || b === a || b === o || b === f || b === w || typeof b == "object" && b !== null && (b.$$typeof === v || b.$$typeof === g || b.$$typeof === i || b.$$typeof === l || b.$$typeof === p || b.$$typeof === h || b.$$typeof === S || b.$$typeof === A || b.$$typeof === m); }, it.typeOf = R, it; } var st = {}; @@ -3649,29 +3642,29 @@ var st = {}; * LICENSE file in the root directory of this source tree. */ var sa; -function Td() { +function Sd() { return sa || (sa = 1, process.env.NODE_ENV !== "production" && function() { - var t = typeof Symbol == "function" && Symbol.for, e = t ? Symbol.for("react.element") : 60103, n = t ? Symbol.for("react.portal") : 60106, r = t ? Symbol.for("react.fragment") : 60107, o = t ? Symbol.for("react.strict_mode") : 60108, a = t ? Symbol.for("react.profiler") : 60114, i = t ? Symbol.for("react.provider") : 60109, l = t ? Symbol.for("react.context") : 60110, c = t ? Symbol.for("react.async_mode") : 60111, d = t ? Symbol.for("react.concurrent_mode") : 60111, p = t ? Symbol.for("react.forward_ref") : 60112, f = t ? Symbol.for("react.suspense") : 60113, w = t ? Symbol.for("react.suspense_list") : 60120, g = t ? Symbol.for("react.memo") : 60115, v = t ? Symbol.for("react.lazy") : 60116, m = t ? Symbol.for("react.block") : 60121, h = t ? Symbol.for("react.fundamental") : 60117, T = t ? Symbol.for("react.responder") : 60118, A = t ? Symbol.for("react.scope") : 60119; + var t = typeof Symbol == "function" && Symbol.for, e = t ? Symbol.for("react.element") : 60103, n = t ? Symbol.for("react.portal") : 60106, r = t ? Symbol.for("react.fragment") : 60107, o = t ? Symbol.for("react.strict_mode") : 60108, a = t ? Symbol.for("react.profiler") : 60114, i = t ? Symbol.for("react.provider") : 60109, l = t ? Symbol.for("react.context") : 60110, c = t ? Symbol.for("react.async_mode") : 60111, d = t ? Symbol.for("react.concurrent_mode") : 60111, p = t ? Symbol.for("react.forward_ref") : 60112, f = t ? Symbol.for("react.suspense") : 60113, w = t ? Symbol.for("react.suspense_list") : 60120, g = t ? Symbol.for("react.memo") : 60115, v = t ? Symbol.for("react.lazy") : 60116, m = t ? Symbol.for("react.block") : 60121, h = t ? Symbol.for("react.fundamental") : 60117, S = t ? Symbol.for("react.responder") : 60118, A = t ? Symbol.for("react.scope") : 60119; function R(I) { return typeof I == "string" || typeof I == "function" || // Note: its typeof might be other than 'symbol' or 'number' if it's a polyfill. - I === r || I === d || I === a || I === o || I === f || I === w || typeof I == "object" && I !== null && (I.$$typeof === v || I.$$typeof === g || I.$$typeof === i || I.$$typeof === l || I.$$typeof === p || I.$$typeof === h || I.$$typeof === T || I.$$typeof === A || I.$$typeof === m); + I === r || I === d || I === a || I === o || I === f || I === w || typeof I == "object" && I !== null && (I.$$typeof === v || I.$$typeof === g || I.$$typeof === i || I.$$typeof === l || I.$$typeof === p || I.$$typeof === h || I.$$typeof === S || I.$$typeof === A || I.$$typeof === m); } function E(I) { if (typeof I == "object" && I !== null) { var xt = I.$$typeof; switch (xt) { case e: - var j = I.type; - switch (j) { + var B = I.type; + switch (B) { case c: case d: case r: case a: case o: case f: - return j; + return B; default: - var yt = j && j.$$typeof; + var yt = B && B.$$typeof; switch (yt) { case l: case p: @@ -3688,7 +3681,7 @@ function Td() { } } } - var b = c, $ = d, z = l, H = i, C = e, P = p, k = r, B = v, M = g, J = n, q = a, U = o, tt = f, at = !1; + var b = c, $ = d, z = l, H = i, C = e, P = p, k = r, j = v, M = g, J = n, q = a, U = o, tt = f, at = !1; function rt(I) { return at || (at = !0, console.warn("The ReactIs.isAsyncMode() alias has been deprecated, and will be removed in React 17+. Update your code to use ReactIs.isConcurrentMode() instead. It has the exact same API.")), y(I) || E(I) === c; } @@ -3728,12 +3721,12 @@ function Td() { function dt(I) { return E(I) === f; } - st.AsyncMode = b, st.ConcurrentMode = $, st.ContextConsumer = z, st.ContextProvider = H, st.Element = C, st.ForwardRef = P, st.Fragment = k, st.Lazy = B, st.Memo = M, st.Portal = J, st.Profiler = q, st.StrictMode = U, st.Suspense = tt, st.isAsyncMode = rt, st.isConcurrentMode = y, st.isContextConsumer = O, st.isContextProvider = L, st.isElement = F, st.isForwardRef = V, st.isFragment = W, st.isLazy = X, st.isMemo = Y, st.isPortal = G, st.isProfiler = K, st.isStrictMode = Z, st.isSuspense = dt, st.isValidElementType = R, st.typeOf = E; + st.AsyncMode = b, st.ConcurrentMode = $, st.ContextConsumer = z, st.ContextProvider = H, st.Element = C, st.ForwardRef = P, st.Fragment = k, st.Lazy = j, st.Memo = M, st.Portal = J, st.Profiler = q, st.StrictMode = U, st.Suspense = tt, st.isAsyncMode = rt, st.isConcurrentMode = y, st.isContextConsumer = O, st.isContextProvider = L, st.isElement = F, st.isForwardRef = V, st.isFragment = W, st.isLazy = X, st.isMemo = Y, st.isPortal = G, st.isProfiler = K, st.isStrictMode = Z, st.isSuspense = dt, st.isValidElementType = R, st.typeOf = E; }()), st; } var la; function Hi() { - return la || (la = 1, process.env.NODE_ENV === "production" ? jn.exports = Sd() : jn.exports = Td()), jn.exports; + return la || (la = 1, process.env.NODE_ENV === "production" ? Bn.exports = Ed() : Bn.exports = Sd()), Bn.exports; } /* object-assign @@ -3741,7 +3734,7 @@ object-assign @license MIT */ var Ar, ca; -function Cd() { +function Td() { if (ca) return Ar; ca = 1; @@ -3799,10 +3792,10 @@ var Dr, pa; function Xi() { return pa || (pa = 1, Dr = Function.call.bind(Object.prototype.hasOwnProperty)), Dr; } -var Br, ua; -function Od() { +var jr, ua; +function Cd() { if (ua) - return Br; + return jr; ua = 1; var t = function() { }; @@ -3847,14 +3840,14 @@ function Od() { } return o.resetWarningCache = function() { process.env.NODE_ENV !== "production" && (n = {}); - }, Br = o, Br; + }, jr = o, jr; } -var jr, wa; -function Rd() { +var Br, wa; +function Od() { if (wa) - return jr; + return Br; wa = 1; - var t = Hi(), e = Cd(), n = vo(), r = Xi(), o = Od(), a = function() { + var t = Hi(), e = Td(), n = vo(), r = Xi(), o = Cd(), a = function() { }; process.env.NODE_ENV !== "production" && (a = function(l) { var c = "Warning: " + l; @@ -3867,7 +3860,7 @@ function Rd() { function i() { return null; } - return jr = function(l, c) { + return Br = function(l, c) { var d = typeof Symbol == "function" && Symbol.iterator, p = "@@iterator"; function f(y) { var O = y && (d && y[d] || y[p]); @@ -3875,14 +3868,14 @@ function Rd() { return O; } var w = "<>", g = { - array: T("array"), - bigint: T("bigint"), - bool: T("boolean"), - func: T("function"), - number: T("number"), - object: T("object"), - string: T("string"), - symbol: T("symbol"), + array: S("array"), + bigint: S("bigint"), + bool: S("boolean"), + func: S("function"), + number: S("number"), + object: S("object"), + string: S("string"), + symbol: S("symbol"), any: A(), arrayOf: R, element: E(), @@ -3892,7 +3885,7 @@ function Rd() { objectOf: H, oneOf: z, oneOfType: C, - shape: B, + shape: j, exact: M }; function v(y, O) { @@ -3925,7 +3918,7 @@ function Rd() { var V = F.bind(null, !1); return V.isRequired = F.bind(null, !0), V; } - function T(y) { + function S(y) { function O(L, F, V, W, X, Y) { var G = L[F], K = U(G); if (K !== y) { @@ -4059,7 +4052,7 @@ function Rd() { (y || "React class") + ": " + O + " type `" + L + "." + F + "` is invalid; it must be a function, usually from the `prop-types` package, but received `" + V + "`." ); } - function B(y) { + function j(y) { function O(L, F, V, W, X) { var Y = L[F], G = U(Y); if (G !== "object") @@ -4169,10 +4162,10 @@ Valid keys: ` + JSON.stringify(Object.keys(y), null, " ") return !y.constructor || !y.constructor.name ? w : y.constructor.name; } return g.checkPropTypes = o, g.resetWarningCache = o.resetWarningCache, g.PropTypes = g, g; - }, jr; + }, Br; } var Vr, fa; -function _d() { +function Rd() { if (fa) return Vr; fa = 1; @@ -4221,13 +4214,13 @@ function _d() { }, Vr; } if (process.env.NODE_ENV !== "production") { - var Pd = Hi(), $d = !0; - Zr.exports = Rd()(Pd.isElement, $d); + var _d = Hi(), Pd = !0; + Zr.exports = Od()(_d.isElement, Pd); } else - Zr.exports = _d()(); -var Id = Zr.exports; -const u = /* @__PURE__ */ Nd(Id); -function Ad(t) { + Zr.exports = Rd()(); +var $d = Zr.exports; +const u = /* @__PURE__ */ xd($d); +function Id(t) { const { prototype: e = {} } = t; @@ -4243,14 +4236,14 @@ function Yi(t, e, n, r, o) { return null; let l; const c = a.type; - return typeof c == "function" && !Ad(c) && (l = "Did you accidentally use a plain function component for an element instead?"), l !== void 0 ? new Error(`Invalid ${r} \`${i}\` supplied to \`${n}\`. Expected an element that can hold a ref. ${l} For more information see https://mui.com/r/caveat-with-refs-guide`) : null; + return typeof c == "function" && !Id(c) && (l = "Did you accidentally use a plain function component for an element instead?"), l !== void 0 ? new Error(`Invalid ${r} \`${i}\` supplied to \`${n}\`. Expected an element that can hold a ref. ${l} For more information see https://mui.com/r/caveat-with-refs-guide`) : null; } const Wi = bo(u.element, Yi); Wi.isRequired = bo(u.element.isRequired, Yi); -const qi = Wi, Md = "exact-prop: ​"; -function Dd(t) { +const qi = Wi, Ad = "exact-prop: ​"; +function Md(t) { return process.env.NODE_ENV === "production" ? t : _({}, t, { - [Md]: (e) => { + [Ad]: (e) => { const n = Object.keys(e).filter((r) => !t.hasOwnProperty(r)); return n.length > 0 ? new Error(`The following props are not supported: ${n.map((r) => `\`${r}\``).join(", ")}. Please remove them.`) : null; } @@ -4273,7 +4266,7 @@ var Qr = { exports: {} }, lt = {}; * LICENSE file in the root directory of this source tree. */ var ma; -function Bd() { +function Dd() { if (ma) return lt; ma = 1; @@ -4281,8 +4274,8 @@ function Bd() { v = Symbol.for("react.module.reference"); function m(h) { if (typeof h == "object" && h !== null) { - var T = h.$$typeof; - switch (T) { + var S = h.$$typeof; + switch (S) { case t: switch (h = h.type, h) { case n: @@ -4301,11 +4294,11 @@ function Bd() { case a: return h; default: - return T; + return S; } } case e: - return T; + return S; } } } @@ -4354,21 +4347,21 @@ var ct = {}; var ha; function jd() { return ha || (ha = 1, process.env.NODE_ENV !== "production" && function() { - var t = Symbol.for("react.element"), e = Symbol.for("react.portal"), n = Symbol.for("react.fragment"), r = Symbol.for("react.strict_mode"), o = Symbol.for("react.profiler"), a = Symbol.for("react.provider"), i = Symbol.for("react.context"), l = Symbol.for("react.server_context"), c = Symbol.for("react.forward_ref"), d = Symbol.for("react.suspense"), p = Symbol.for("react.suspense_list"), f = Symbol.for("react.memo"), w = Symbol.for("react.lazy"), g = Symbol.for("react.offscreen"), v = !1, m = !1, h = !1, T = !1, A = !1, R; + var t = Symbol.for("react.element"), e = Symbol.for("react.portal"), n = Symbol.for("react.fragment"), r = Symbol.for("react.strict_mode"), o = Symbol.for("react.profiler"), a = Symbol.for("react.provider"), i = Symbol.for("react.context"), l = Symbol.for("react.server_context"), c = Symbol.for("react.forward_ref"), d = Symbol.for("react.suspense"), p = Symbol.for("react.suspense_list"), f = Symbol.for("react.memo"), w = Symbol.for("react.lazy"), g = Symbol.for("react.offscreen"), v = !1, m = !1, h = !1, S = !1, A = !1, R; R = Symbol.for("react.module.reference"); - function E(j) { - return !!(typeof j == "string" || typeof j == "function" || j === n || j === o || A || j === r || j === d || j === p || T || j === g || v || m || h || typeof j == "object" && j !== null && (j.$$typeof === w || j.$$typeof === f || j.$$typeof === a || j.$$typeof === i || j.$$typeof === c || // This needs to include all possible module reference object + function E(B) { + return !!(typeof B == "string" || typeof B == "function" || B === n || B === o || A || B === r || B === d || B === p || S || B === g || v || m || h || typeof B == "object" && B !== null && (B.$$typeof === w || B.$$typeof === f || B.$$typeof === a || B.$$typeof === i || B.$$typeof === c || // This needs to include all possible module reference object // types supported by any Flight configuration anywhere since // we don't know which Flight build this will end up being used // with. - j.$$typeof === R || j.getModuleId !== void 0)); + B.$$typeof === R || B.getModuleId !== void 0)); } - function b(j) { - if (typeof j == "object" && j !== null) { - var yt = j.$$typeof; + function b(B) { + if (typeof B == "object" && B !== null) { + var yt = B.$$typeof; switch (yt) { case t: - var Lt = j.type; + var Lt = B.type; switch (Lt) { case n: case o: @@ -4395,67 +4388,67 @@ function jd() { } } } - var $ = i, z = a, H = t, C = c, P = n, k = w, B = f, M = e, J = o, q = r, U = d, tt = p, at = !1, rt = !1; - function y(j) { + var $ = i, z = a, H = t, C = c, P = n, k = w, j = f, M = e, J = o, q = r, U = d, tt = p, at = !1, rt = !1; + function y(B) { return at || (at = !0, console.warn("The ReactIs.isAsyncMode() alias has been deprecated, and will be removed in React 18+.")), !1; } - function O(j) { + function O(B) { return rt || (rt = !0, console.warn("The ReactIs.isConcurrentMode() alias has been deprecated, and will be removed in React 18+.")), !1; } - function L(j) { - return b(j) === i; + function L(B) { + return b(B) === i; } - function F(j) { - return b(j) === a; + function F(B) { + return b(B) === a; } - function V(j) { - return typeof j == "object" && j !== null && j.$$typeof === t; + function V(B) { + return typeof B == "object" && B !== null && B.$$typeof === t; } - function W(j) { - return b(j) === c; + function W(B) { + return b(B) === c; } - function X(j) { - return b(j) === n; + function X(B) { + return b(B) === n; } - function Y(j) { - return b(j) === w; + function Y(B) { + return b(B) === w; } - function G(j) { - return b(j) === f; + function G(B) { + return b(B) === f; } - function K(j) { - return b(j) === e; + function K(B) { + return b(B) === e; } - function Z(j) { - return b(j) === o; + function Z(B) { + return b(B) === o; } - function dt(j) { - return b(j) === r; + function dt(B) { + return b(B) === r; } - function I(j) { - return b(j) === d; + function I(B) { + return b(B) === d; } - function xt(j) { - return b(j) === p; + function xt(B) { + return b(B) === p; } - ct.ContextConsumer = $, ct.ContextProvider = z, ct.Element = H, ct.ForwardRef = C, ct.Fragment = P, ct.Lazy = k, ct.Memo = B, ct.Portal = M, ct.Profiler = J, ct.StrictMode = q, ct.Suspense = U, ct.SuspenseList = tt, ct.isAsyncMode = y, ct.isConcurrentMode = O, ct.isContextConsumer = L, ct.isContextProvider = F, ct.isElement = V, ct.isForwardRef = W, ct.isFragment = X, ct.isLazy = Y, ct.isMemo = G, ct.isPortal = K, ct.isProfiler = Z, ct.isStrictMode = dt, ct.isSuspense = I, ct.isSuspenseList = xt, ct.isValidElementType = E, ct.typeOf = b; + ct.ContextConsumer = $, ct.ContextProvider = z, ct.Element = H, ct.ForwardRef = C, ct.Fragment = P, ct.Lazy = k, ct.Memo = j, ct.Portal = M, ct.Profiler = J, ct.StrictMode = q, ct.Suspense = U, ct.SuspenseList = tt, ct.isAsyncMode = y, ct.isConcurrentMode = O, ct.isContextConsumer = L, ct.isContextProvider = F, ct.isElement = V, ct.isForwardRef = W, ct.isFragment = X, ct.isLazy = Y, ct.isMemo = G, ct.isPortal = K, ct.isProfiler = Z, ct.isStrictMode = dt, ct.isSuspense = I, ct.isSuspenseList = xt, ct.isValidElementType = E, ct.typeOf = b; }()), ct; } -process.env.NODE_ENV === "production" ? Qr.exports = Bd() : Qr.exports = jd(); +process.env.NODE_ENV === "production" ? Qr.exports = Dd() : Qr.exports = jd(); var ga = Qr.exports; -const Vd = /^\s*function(?:\s|\s*\/\*.*\*\/\s*)+([^(\s/]*)\s*/; -function zd(t) { - const e = `${t}`.match(Vd); +const Bd = /^\s*function(?:\s|\s*\/\*.*\*\/\s*)+([^(\s/]*)\s*/; +function Vd(t) { + const e = `${t}`.match(Bd); return e && e[1] || ""; } function Ki(t, e = "") { - return t.displayName || t.name || zd(t) || e; + return t.displayName || t.name || Vd(t) || e; } function ba(t, e, n) { const r = Ki(e); return t.displayName || (r !== "" ? `${n}(${r})` : n); } -function Ld(t) { +function zd(t) { if (t != null) { if (typeof t == "string") return t; @@ -4478,19 +4471,19 @@ function vn(t, e, n, r, o) { const a = t[e], i = o || e; return a == null ? null : a && a.nodeType !== 1 ? new Error(`Invalid ${r} \`${i}\` supplied to \`${n}\`. Expected an HTMLElement.`) : null; } -const Fd = u.oneOfType([u.func, u.object]), Ji = Fd; +const Ld = u.oneOfType([u.func, u.object]), Ji = Ld; function Wt(t) { if (typeof t != "string") throw new Error(process.env.NODE_ENV !== "production" ? "MUI: `capitalize(string)` expects a string argument." : Ve(7)); return t.charAt(0).toUpperCase() + t.slice(1); } -function Ud(...t) { +function Fd(...t) { return t.reduce((e, n) => n == null ? e : function(...o) { e.apply(this, o), n.apply(this, o); }, () => { }); } -function Gd(t, e = 166) { +function Ud(t, e = 166) { let n; function r(...o) { const a = () => { @@ -4502,13 +4495,13 @@ function Gd(t, e = 166) { clearTimeout(n); }, r; } -function Hd(t, e) { +function Gd(t, e) { return process.env.NODE_ENV === "production" ? () => null : (n, r, o, a, i) => { const l = o || "<>", c = i || r; return typeof n[r] < "u" ? new Error(`The ${a} \`${c}\` of \`${l}\` is deprecated. ${e}`) : null; }; } -function Xd(t, e) { +function Hd(t, e) { var n, r; return /* @__PURE__ */ D.isValidElement(t) && e.indexOf( // For server components `muiName` is avaialble in element.type._payload.value.muiName @@ -4520,10 +4513,10 @@ function Xd(t, e) { function Yn(t) { return t && t.ownerDocument || document; } -function Yd(t) { +function Xd(t) { return Yn(t).defaultView || window; } -function Wd(t, e) { +function Yd(t, e) { if (process.env.NODE_ENV === "production") return () => null; const n = e ? _({}, e.propTypes) : null; @@ -4540,9 +4533,9 @@ function Wd(t, e) { function Wn(t, e) { typeof t == "function" ? t(e) : t && (t.current = e); } -const qd = typeof window < "u" ? D.useLayoutEffect : D.useEffect, ze = qd; +const Wd = typeof window < "u" ? D.useLayoutEffect : D.useEffect, ze = Wd; let va = 0; -function Kd(t) { +function qd(t) { const [e, n] = D.useState(t), r = t || e; return D.useEffect(() => { e == null && (va += 1, n(`mui-${va}`)); @@ -4554,9 +4547,9 @@ function Zi(t) { const e = ya(); return t ?? e; } - return Kd(t); + return qd(t); } -function Jd(t, e, n, r, o) { +function Kd(t, e, n, r, o) { if (process.env.NODE_ENV === "production") return null; const a = o || e; @@ -4606,13 +4599,13 @@ function xe(...t) { }, t); } const xa = {}; -function Zd(t, e) { +function Jd(t, e) { const n = D.useRef(xa); return n.current === xa && (n.current = t(e)), n; } -const Qd = []; -function tp(t) { - D.useEffect(t, Qd); +const Zd = []; +function Qd(t) { + D.useEffect(t, Zd); } class Tn { constructor() { @@ -4633,11 +4626,11 @@ class Tn { } } function an() { - const t = Zd(Tn.create).current; - return tp(t.disposeEffect), t; + const t = Jd(Tn.create).current; + return Qd(t.disposeEffect), t; } let dr = !0, eo = !1; -const ep = new Tn(), np = { +const tp = new Tn(), ep = { text: !0, search: !0, url: !0, @@ -4652,26 +4645,26 @@ const ep = new Tn(), np = { datetime: !0, "datetime-local": !0 }; -function rp(t) { +function np(t) { const { type: e, tagName: n } = t; - return !!(n === "INPUT" && np[e] && !t.readOnly || n === "TEXTAREA" && !t.readOnly || t.isContentEditable); + return !!(n === "INPUT" && ep[e] && !t.readOnly || n === "TEXTAREA" && !t.readOnly || t.isContentEditable); } -function op(t) { +function rp(t) { t.metaKey || t.altKey || t.ctrlKey || (dr = !0); } function zr() { dr = !1; } -function ap() { +function op() { this.visibilityState === "hidden" && eo && (dr = !0); } -function ip(t) { - t.addEventListener("keydown", op, !0), t.addEventListener("mousedown", zr, !0), t.addEventListener("pointerdown", zr, !0), t.addEventListener("touchstart", zr, !0), t.addEventListener("visibilitychange", ap, !0); +function ap(t) { + t.addEventListener("keydown", rp, !0), t.addEventListener("mousedown", zr, !0), t.addEventListener("pointerdown", zr, !0), t.addEventListener("touchstart", zr, !0), t.addEventListener("visibilitychange", op, !0); } -function sp(t) { +function ip(t) { const { target: e } = t; @@ -4679,19 +4672,19 @@ function sp(t) { return e.matches(":focus-visible"); } catch { } - return dr || rp(e); + return dr || np(e); } function ts() { const t = D.useCallback((o) => { - o != null && ip(o.ownerDocument); + o != null && ap(o.ownerDocument); }, []), e = D.useRef(!1); function n() { - return e.current ? (eo = !0, ep.start(100, () => { + return e.current ? (eo = !0, tp.start(100, () => { eo = !1; }), e.current = !1, !0) : !1; } function r(o) { - return sp(o) ? (e.current = !0, !0) : !1; + return ip(o) ? (e.current = !0, !0) : !1; } return { isFocusVisibleRef: e, @@ -4730,7 +4723,7 @@ function yo(t, e, n = void 0) { } ), r; } -const Na = (t) => t, lp = () => { +const Na = (t) => t, sp = () => { let t = Na; return { configure(e) { @@ -4743,7 +4736,7 @@ const Na = (t) => t, lp = () => { t = Na; } }; -}, cp = lp(), ns = cp, rs = { +}, lp = sp(), ns = lp, rs = { active: "active", checked: "checked", completed: "completed", @@ -4767,7 +4760,7 @@ function os(t, e, n = "Mui") { r[o] = pr(t, o, n); }), r; } -function dp(t, e = Number.MIN_SAFE_INTEGER, n = Number.MAX_SAFE_INTEGER) { +function cp(t, e = Number.MIN_SAFE_INTEGER, n = Number.MAX_SAFE_INTEGER) { return Math.max(e, Math.min(t, n)); } function Nt(t, e) { @@ -4778,7 +4771,7 @@ function Nt(t, e) { o = r[a], !(e.indexOf(o) >= 0) && (n[o] = t[o]); return n; } -const pp = ["values", "unit", "step"], up = (t) => { +const dp = ["values", "unit", "step"], pp = (t) => { const e = Object.keys(t).map((n) => ({ key: n, val: t[n] @@ -4787,7 +4780,7 @@ const pp = ["values", "unit", "step"], up = (t) => { [r.key]: r.val }), {}); }; -function wp(t) { +function up(t) { const { // The breakpoint **start** at this value. // For instance with the first breakpoint xs: [xs, sm). @@ -4805,7 +4798,7 @@ function wp(t) { }, unit: n = "px", step: r = 5 - } = t, o = Nt(t, pp), a = up(e), i = Object.keys(a); + } = t, o = Nt(t, dp), a = pp(e), i = Object.keys(a); function l(w) { return `@media (min-width:${typeof e[w] == "number" ? e[w] : w}${n})`; } @@ -4834,9 +4827,9 @@ function wp(t) { unit: n }, o); } -const fp = { +const wp = { borderRadius: 4 -}, mp = fp, hp = process.env.NODE_ENV !== "production" ? u.oneOfType([u.number, u.string, u.object, u.array]) : {}, se = hp; +}, fp = wp, mp = process.env.NODE_ENV !== "production" ? u.oneOfType([u.number, u.string, u.object, u.array]) : {}, se = mp; function pn(t, e) { return e ? Zt(t, e, { clone: !1 @@ -4881,14 +4874,14 @@ function Qt(t, e, n) { } return n(e); } -function gp(t = {}) { +function hp(t = {}) { var e; return ((e = t.keys) == null ? void 0 : e.reduce((r, o) => { const a = t.up(o); return r[a] = {}, r; }, {})) || {}; } -function bp(t, e) { +function gp(t, e) { return t.reduce((n, r) => { const o = n[r]; return (!o || Object.keys(o).length === 0) && delete n[r], n; @@ -4929,14 +4922,14 @@ function vt(t) { [e]: se } : {}, a.filterProps = [e], a; } -function vp(t) { +function bp(t) { const e = {}; return (n) => (e[n] === void 0 && (e[n] = t(n)), e[n]); } -const yp = { +const vp = { m: "margin", p: "padding" -}, xp = { +}, yp = { t: "Top", r: "Right", b: "Bottom", @@ -4948,15 +4941,15 @@ const yp = { marginY: "my", paddingX: "px", paddingY: "py" -}, Np = vp((t) => { +}, xp = bp((t) => { if (t.length > 2) if (Ea[t]) t = Ea[t]; else return [t]; - const [e, n] = t.split(""), r = yp[e], o = xp[n] || ""; + const [e, n] = t.split(""), r = vp[e], o = yp[n] || ""; return Array.isArray(o) ? o.map((a) => r + a) : [r + o]; -}), wr = ["m", "mt", "mr", "mb", "ml", "mx", "my", "margin", "marginTop", "marginRight", "marginBottom", "marginLeft", "marginX", "marginY", "marginInline", "marginInlineStart", "marginInlineEnd", "marginBlock", "marginBlockStart", "marginBlockEnd"], fr = ["p", "pt", "pr", "pb", "pl", "px", "py", "padding", "paddingTop", "paddingRight", "paddingBottom", "paddingLeft", "paddingX", "paddingY", "paddingInline", "paddingInlineStart", "paddingInlineEnd", "paddingBlock", "paddingBlockStart", "paddingBlockEnd"], kp = [...wr, ...fr]; +}), wr = ["m", "mt", "mr", "mb", "ml", "mx", "my", "margin", "marginTop", "marginRight", "marginBottom", "marginLeft", "marginX", "marginY", "marginInline", "marginInlineStart", "marginInlineEnd", "marginBlock", "marginBlockStart", "marginBlockEnd"], fr = ["p", "pt", "pr", "pb", "pl", "px", "py", "padding", "paddingTop", "paddingRight", "paddingBottom", "paddingLeft", "paddingX", "paddingY", "paddingInline", "paddingInlineStart", "paddingInlineEnd", "paddingBlock", "paddingBlockStart", "paddingBlockEnd"], Np = [...wr, ...fr]; function Cn(t, e, n, r) { var o; const a = (o = ur(t, e, !1)) != null ? o : n; @@ -4975,18 +4968,18 @@ function On(t, e) { const n = Math.abs(e), r = t(n); return e >= 0 ? r : typeof r == "number" ? -r : `-${r}`; } -function Ep(t, e) { +function kp(t, e) { return (n) => t.reduce((r, o) => (r[o] = On(e, n), r), {}); } -function Sp(t, e, n, r) { +function Ep(t, e, n, r) { if (e.indexOf(n) === -1) return null; - const o = Np(n), a = Ep(o, r), i = t[n]; + const o = xp(n), a = kp(o, r), i = t[n]; return Qt(t, i, a); } function is(t, e) { const n = as(t.theme); - return Object.keys(t).map((r) => Sp(t, e, r, n)).reduce(pn, {}); + return Object.keys(t).map((r) => Ep(t, e, r, n)).reduce(pn, {}); } function mt(t) { return is(t, wr); @@ -4998,8 +4991,8 @@ function ht(t) { } ht.propTypes = process.env.NODE_ENV !== "production" ? fr.reduce((t, e) => (t[e] = se, t), {}) : {}; ht.filterProps = fr; -process.env.NODE_ENV !== "production" && kp.reduce((t, e) => (t[e] = se, t), {}); -function Tp(t = 8) { +process.env.NODE_ENV !== "production" && Np.reduce((t, e) => (t[e] = se, t), {}); +function Sp(t = 8) { if (t.mui) return t; const e = as({ @@ -5026,7 +5019,7 @@ function zt(t, e) { transform: e }); } -const Cp = zt("border", Dt), Op = zt("borderTop", Dt), Rp = zt("borderRight", Dt), _p = zt("borderBottom", Dt), Pp = zt("borderLeft", Dt), $p = zt("borderColor"), Ip = zt("borderTopColor"), Ap = zt("borderRightColor"), Mp = zt("borderBottomColor"), Dp = zt("borderLeftColor"), Bp = zt("outline", Dt), jp = zt("outlineColor"), hr = (t) => { +const Tp = zt("border", Dt), Cp = zt("borderTop", Dt), Op = zt("borderRight", Dt), Rp = zt("borderBottom", Dt), _p = zt("borderLeft", Dt), Pp = zt("borderColor"), $p = zt("borderTopColor"), Ip = zt("borderRightColor"), Ap = zt("borderBottomColor"), Mp = zt("borderLeftColor"), Dp = zt("outline", Dt), jp = zt("outlineColor"), hr = (t) => { if (t.borderRadius !== void 0 && t.borderRadius !== null) { const e = Cn(t.theme, "shape.borderRadius", 4, "borderRadius"), n = (r) => ({ borderRadius: On(e, r) @@ -5039,7 +5032,7 @@ hr.propTypes = process.env.NODE_ENV !== "production" ? { borderRadius: se } : {}; hr.filterProps = ["borderRadius"]; -mr(Cp, Op, Rp, _p, Pp, $p, Ip, Ap, Mp, Dp, hr, Bp, jp); +mr(Tp, Cp, Op, Rp, _p, Pp, $p, Ip, Ap, Mp, hr, Dp, jp); const gr = (t) => { if (t.gap !== void 0 && t.gap !== null) { const e = Cn(t.theme, "spacing", 8, "gap"), n = (r) => ({ @@ -5079,48 +5072,48 @@ vr.propTypes = process.env.NODE_ENV !== "production" ? { rowGap: se } : {}; vr.filterProps = ["rowGap"]; -const Vp = vt({ +const Bp = vt({ prop: "gridColumn" -}), zp = vt({ +}), Vp = vt({ prop: "gridRow" -}), Lp = vt({ +}), zp = vt({ prop: "gridAutoFlow" -}), Fp = vt({ +}), Lp = vt({ prop: "gridAutoColumns" -}), Up = vt({ +}), Fp = vt({ prop: "gridAutoRows" -}), Gp = vt({ +}), Up = vt({ prop: "gridTemplateColumns" -}), Hp = vt({ +}), Gp = vt({ prop: "gridTemplateRows" -}), Xp = vt({ +}), Hp = vt({ prop: "gridTemplateAreas" -}), Yp = vt({ +}), Xp = vt({ prop: "gridArea" }); -mr(gr, br, vr, Vp, zp, Lp, Fp, Up, Gp, Hp, Xp, Yp); +mr(gr, br, vr, Bp, Vp, zp, Lp, Fp, Up, Gp, Hp, Xp); function Me(t, e) { return e === "grey" ? e : t; } -const Wp = vt({ +const Yp = vt({ prop: "color", themeKey: "palette", transform: Me -}), qp = vt({ +}), Wp = vt({ prop: "bgcolor", cssProperty: "backgroundColor", themeKey: "palette", transform: Me -}), Kp = vt({ +}), qp = vt({ prop: "backgroundColor", themeKey: "palette", transform: Me }); -mr(Wp, qp, Kp); +mr(Yp, Wp, qp); function It(t) { return t <= 1 && t !== 0 ? `${t * 100}%` : t; } -const Jp = vt({ +const Kp = vt({ prop: "width", transform: It }), No = (t) => { @@ -5141,16 +5134,16 @@ const Jp = vt({ return null; }; No.filterProps = ["maxWidth"]; -const Zp = vt({ +const Jp = vt({ prop: "minWidth", transform: It -}), Qp = vt({ +}), Zp = vt({ prop: "height", transform: It -}), tu = vt({ +}), Qp = vt({ prop: "maxHeight", transform: It -}), eu = vt({ +}), tu = vt({ prop: "minHeight", transform: It }); @@ -5164,11 +5157,11 @@ vt({ cssProperty: "height", transform: It }); -const nu = vt({ +const eu = vt({ prop: "boxSizing" }); -mr(Jp, No, Zp, Qp, tu, eu, nu); -const ru = { +mr(Kp, No, Jp, Zp, Qp, tu, eu); +const nu = { // borders border: { themeKey: "borders", @@ -5452,15 +5445,15 @@ const ru = { cssProperty: !1, themeKey: "typography" } -}, ko = ru; -function ou(...t) { +}, ko = nu; +function ru(...t) { const e = t.reduce((r, o) => r.concat(Object.keys(o)), []), n = new Set(e); return t.every((r) => n.size === Object.keys(r).length); } -function au(t, e) { +function ou(t, e) { return typeof t == "function" ? t(e) : t; } -function iu() { +function au() { function t(n, r, o, a) { const i = { [n]: r, @@ -5507,10 +5500,10 @@ function iu() { return c; if (!d) return null; - const p = gp(a.breakpoints), f = Object.keys(p); + const p = hp(a.breakpoints), f = Object.keys(p); let w = p; return Object.keys(d).forEach((g) => { - const v = au(d[g], a); + const v = ou(d[g], a); if (v != null) if (typeof v == "object") if (i[g]) @@ -5521,36 +5514,36 @@ function iu() { }, v, (h) => ({ [g]: h })); - ou(m, v) ? w[g] = e({ + ru(m, v) ? w[g] = e({ sx: v, theme: a }) : w = pn(w, m); } else w = pn(w, t(g, v, a, i)); - }), bp(f, w); + }), gp(f, w); } return Array.isArray(o) ? o.map(l) : l(o); } return e; } -const ss = iu(); +const ss = au(); ss.filterProps = ["sx"]; const Eo = ss; -function su(t, e) { +function iu(t, e) { const n = this; return n.vars && typeof n.getColorSchemeSelector == "function" ? { [n.getColorSchemeSelector(t).replace(/(\[[^\]]+\])/, "*:where($1)")]: e } : n.palette.mode === t ? e : {}; } -const lu = ["breakpoints", "palette", "spacing", "shape"]; +const su = ["breakpoints", "palette", "spacing", "shape"]; function So(t = {}, ...e) { const { breakpoints: n = {}, palette: r = {}, spacing: o, shape: a = {} - } = t, i = Nt(t, lu), l = wp(n), c = Tp(o); + } = t, i = Nt(t, su), l = up(n), c = Sp(o); let d = Zt({ breakpoints: l, direction: "ltr", @@ -5560,31 +5553,31 @@ function So(t = {}, ...e) { mode: "light" }, r), spacing: c, - shape: _({}, mp, a) + shape: _({}, fp, a) }, i); - return d.applyStyles = su, d = e.reduce((p, f) => Zt(p, f), d), d.unstable_sxConfig = _({}, ko, i == null ? void 0 : i.unstable_sxConfig), d.unstable_sx = function(f) { + return d.applyStyles = iu, d = e.reduce((p, f) => Zt(p, f), d), d.unstable_sxConfig = _({}, ko, i == null ? void 0 : i.unstable_sxConfig), d.unstable_sx = function(f) { return Eo({ sx: f, theme: this }); }, d; } -function cu(t) { +function lu(t) { return Object.keys(t).length === 0; } function ls(t = null) { const e = D.useContext($l); - return !e || cu(e) ? t : e; + return !e || lu(e) ? t : e; } -const du = So(); -function cs(t = du) { +const cu = So(); +function cs(t = cu) { return ls(t); } -const pu = ["ownerState"], uu = ["variants"], wu = ["name", "slot", "skipVariantsResolver", "skipSx", "overridesResolver"]; -function fu(t) { +const du = ["ownerState"], pu = ["variants"], uu = ["name", "slot", "skipVariantsResolver", "skipSx", "overridesResolver"]; +function wu(t) { return Object.keys(t).length === 0; } -function mu(t) { +function fu(t) { return typeof t == "string" && // 96 is one less than the char code // for "a" so this is checking that // it's a lowercase character @@ -5593,21 +5586,21 @@ function mu(t) { function Gn(t) { return t !== "ownerState" && t !== "theme" && t !== "sx" && t !== "as"; } -const hu = So(), Sa = (t) => t && t.charAt(0).toLowerCase() + t.slice(1); +const mu = So(), Sa = (t) => t && t.charAt(0).toLowerCase() + t.slice(1); function Vn({ defaultTheme: t, theme: e, themeId: n }) { - return fu(e) ? t : e[n] || e; + return wu(e) ? t : e[n] || e; } -function gu(t) { +function hu(t) { return t ? (e, n) => n[t] : null; } function Hn(t, e) { let { ownerState: n - } = e, r = Nt(e, pu); + } = e, r = Nt(e, du); const o = typeof t == "function" ? t(_({ ownerState: n }, r)) : t; @@ -5619,7 +5612,7 @@ function Hn(t, e) { const { variants: a = [] } = o; - let l = Nt(o, uu); + let l = Nt(o, pu); return a.forEach((c) => { let d = !0; typeof c.props == "function" ? d = c.props(_({ @@ -5633,10 +5626,10 @@ function Hn(t, e) { } return o; } -function bu(t = {}) { +function gu(t = {}) { const { themeId: e, - defaultTheme: n = hu, + defaultTheme: n = mu, rootShouldForwardProp: r = Gn, slotShouldForwardProp: o = Gn } = t, a = (i) => Eo(_({}, i, { @@ -5654,18 +5647,18 @@ function bu(t = {}) { skipSx: f, // TODO v6: remove `lowercaseFirstLetter()` in the next major release // For more details: https://github.com/mui/material-ui/pull/37908 - overridesResolver: w = gu(Sa(d)) - } = l, g = Nt(l, wu), v = p !== void 0 ? p : ( + overridesResolver: w = hu(Sa(d)) + } = l, g = Nt(l, uu), v = p !== void 0 ? p : ( // TODO v6: remove `Root` in the next major release // For more details: https://github.com/mui/material-ui/pull/37908 d && d !== "Root" && d !== "root" || !1 ), m = f || !1; let h; process.env.NODE_ENV !== "production" && c && (h = `${c}-${Sa(d || "Root")}`); - let T = Gn; - d === "Root" || d === "root" ? T = r : d ? T = o : mu(i) && (T = void 0); + let S = Gn; + d === "Root" || d === "root" ? S = r : d ? S = o : fu(i) && (S = void 0); const A = Pl(i, _({ - shouldForwardProp: T, + shouldForwardProp: S, label: h }, g)), R = (b) => typeof b == "function" && b.__emotion_real !== b || he(b) ? ($) => Hn(b, _({}, $, { theme: Vn({ @@ -5677,24 +5670,24 @@ function bu(t = {}) { let z = R(b); const H = $ ? $.map(R) : []; c && w && H.push((k) => { - const B = Vn(_({}, k, { + const j = Vn(_({}, k, { defaultTheme: n, themeId: e })); - if (!B.components || !B.components[c] || !B.components[c].styleOverrides) + if (!j.components || !j.components[c] || !j.components[c].styleOverrides) return null; - const M = B.components[c].styleOverrides, J = {}; + const M = j.components[c].styleOverrides, J = {}; return Object.entries(M).forEach(([q, U]) => { J[q] = Hn(U, _({}, k, { - theme: B + theme: j })); }), w(k, J); }), c && !v && H.push((k) => { - var B; + var j; const M = Vn(_({}, k, { defaultTheme: n, themeId: e - })), J = M == null || (B = M.components) == null || (B = B[c]) == null ? void 0 : B.variants; + })), J = M == null || (j = M.components) == null || (j = j[c]) == null ? void 0 : j.variants; return Hn({ variants: J }, _({}, k, { @@ -5709,14 +5702,14 @@ function bu(t = {}) { const P = A(z, ...H); if (process.env.NODE_ENV !== "production") { let k; - c && (k = `${c}${Wt(d || "")}`), k === void 0 && (k = `Styled(${Ld(i)})`), P.displayName = k; + c && (k = `${c}${Wt(d || "")}`), k === void 0 && (k = `Styled(${zd(i)})`), P.displayName = k; } return i.muiName && (P.muiName = i.muiName), P; }; return A.withConfig && (E.withConfig = A.withConfig), E; }; } -function vu(t) { +function bu(t) { const { theme: e, name: n, @@ -5724,23 +5717,23 @@ function vu(t) { } = t; return !e || !e.components || !e.components[n] || !e.components[n].defaultProps ? r : es(e.components[n].defaultProps, r); } -function yu({ +function vu({ props: t, name: e, defaultTheme: n, themeId: r }) { let o = cs(n); - return r && (o = o[r] || o), vu({ + return r && (o = o[r] || o), bu({ theme: o, name: e, props: t }); } function To(t, e = 0, n = 1) { - return process.env.NODE_ENV !== "production" && (t < e || t > n) && console.error(`MUI: The value provided ${t} is out of range [${e}, ${n}].`), dp(t, e, n); + return process.env.NODE_ENV !== "production" && (t < e || t > n) && console.error(`MUI: The value provided ${t} is out of range [${e}, ${n}].`), cp(t, e, n); } -function xu(t) { +function yu(t) { t = t.slice(1); const e = new RegExp(`.{1,${t.length >= 6 ? 2 : 1}}`, "g"); let n = t.match(e); @@ -5750,7 +5743,7 @@ function Ne(t) { if (t.type) return t; if (t.charAt(0) === "#") - return Ne(xu(t)); + return Ne(yu(t)); const e = t.indexOf("("), n = t.substring(0, e); if (["rgb", "rgba", "hsl", "hsla", "color"].indexOf(n) === -1) throw new Error(process.env.NODE_ENV !== "production" ? `MUI: Unsupported \`${t}\` color. @@ -5778,7 +5771,7 @@ function yr(t) { } = t; return e.indexOf("rgb") !== -1 ? r = r.map((o, a) => a < 3 ? parseInt(o, 10) : o) : e.indexOf("hsl") !== -1 && (r[1] = `${r[1]}%`, r[2] = `${r[2]}%`), e.indexOf("color") !== -1 ? r = `${n} ${r.join(" ")}` : r = `${r.join(", ")}`, `${e}(${r})`; } -function Nu(t) { +function xu(t) { t = Ne(t); const { values: e @@ -5792,7 +5785,7 @@ function Nu(t) { } function Ta(t) { t = Ne(t); - let e = t.type === "hsl" || t.type === "hsla" ? Ne(Nu(t)).values : t.values; + let e = t.type === "hsl" || t.type === "hsla" ? Ne(xu(t)).values : t.values; return e = e.map((n) => (t.type !== "color" && (n /= 255), n <= 0.03928 ? n / 12.92 : ((n + 0.055) / 1.055) ** 2.4)), Number((0.2126 * e[0] + 0.7152 * e[1] + 0.0722 * e[2]).toFixed(3)); } function Ca(t, e) { @@ -5802,7 +5795,7 @@ function Ca(t, e) { function ds(t, e) { return t = Ne(t), e = To(e), (t.type === "rgb" || t.type === "hsl") && (t.type += "a"), t.type === "color" ? t.values[3] = `/${e}` : t.values[3] = e, yr(t); } -function ku(t, e) { +function Nu(t, e) { if (t = Ne(t), e = To(e), t.type.indexOf("hsl") !== -1) t.values[2] *= 1 - e; else if (t.type.indexOf("rgb") !== -1 || t.type.indexOf("color") !== -1) @@ -5810,7 +5803,7 @@ function ku(t, e) { t.values[n] *= 1 - e; return yr(t); } -function Eu(t, e) { +function ku(t, e) { if (t = Ne(t), e = To(e), t.type.indexOf("hsl") !== -1) t.values[2] += (100 - t.values[2]) * e; else if (t.type.indexOf("rgb") !== -1) @@ -5821,7 +5814,7 @@ function Eu(t, e) { t.values[n] += (1 - t.values[n]) * e; return yr(t); } -function Su(t, e) { +function Eu(t, e) { return _({ toolbar: { minHeight: 56, @@ -5836,10 +5829,10 @@ function Su(t, e) { } }, e); } -const Tu = { +const Su = { black: "#000", white: "#fff" -}, yn = Tu, Cu = { +}, yn = Su, Tu = { 50: "#fafafa", 100: "#f5f5f5", 200: "#eeeeee", @@ -5854,7 +5847,7 @@ const Tu = { A200: "#eeeeee", A400: "#bdbdbd", A700: "#616161" -}, Ou = Cu, Ru = { +}, Cu = Tu, Ou = { 50: "#f3e5f5", 100: "#e1bee7", 200: "#ce93d8", @@ -5869,7 +5862,7 @@ const Tu = { A200: "#e040fb", A400: "#d500f9", A700: "#aa00ff" -}, Oe = Ru, _u = { +}, Oe = Ou, Ru = { 50: "#ffebee", 100: "#ffcdd2", 200: "#ef9a9a", @@ -5884,7 +5877,7 @@ const Tu = { A200: "#ff5252", A400: "#ff1744", A700: "#d50000" -}, Re = _u, Pu = { +}, Re = Ru, _u = { 50: "#fff3e0", 100: "#ffe0b2", 200: "#ffcc80", @@ -5899,7 +5892,7 @@ const Tu = { A200: "#ffab40", A400: "#ff9100", A700: "#ff6d00" -}, en = Pu, $u = { +}, en = _u, Pu = { 50: "#e3f2fd", 100: "#bbdefb", 200: "#90caf9", @@ -5914,7 +5907,7 @@ const Tu = { A200: "#448aff", A400: "#2979ff", A700: "#2962ff" -}, _e = $u, Iu = { +}, _e = Pu, $u = { 50: "#e1f5fe", 100: "#b3e5fc", 200: "#81d4fa", @@ -5929,7 +5922,7 @@ const Tu = { A200: "#40c4ff", A400: "#00b0ff", A700: "#0091ea" -}, Pe = Iu, Au = { +}, Pe = $u, Iu = { 50: "#e8f5e9", 100: "#c8e6c9", 200: "#a5d6a7", @@ -5944,7 +5937,7 @@ const Tu = { A200: "#69f0ae", A400: "#00e676", A700: "#00c853" -}, $e = Au, Mu = ["mode", "contrastThreshold", "tonalOffset"], Oa = { +}, $e = Iu, Au = ["mode", "contrastThreshold", "tonalOffset"], Oa = { // The colors used to style the text. text: { // The most important text. @@ -6009,9 +6002,9 @@ const Tu = { }; function Ra(t, e, n, r) { const o = r.light || r, a = r.dark || r * 1.5; - t[e] || (t.hasOwnProperty(n) ? t[e] = t[n] : e === "light" ? t.light = Eu(t.main, o) : e === "dark" && (t.dark = ku(t.main, a))); + t[e] || (t.hasOwnProperty(n) ? t[e] = t[n] : e === "light" ? t.light = ku(t.main, o) : e === "dark" && (t.dark = Nu(t.main, a))); } -function Du(t = "light") { +function Mu(t = "light") { return t === "dark" ? { main: _e[200], light: _e[50], @@ -6022,7 +6015,7 @@ function Du(t = "light") { dark: _e[800] }; } -function Bu(t = "light") { +function Du(t = "light") { return t === "dark" ? { main: Oe[200], light: Oe[50], @@ -6044,7 +6037,7 @@ function ju(t = "light") { dark: Re[800] }; } -function Vu(t = "light") { +function Bu(t = "light") { return t === "dark" ? { main: Pe[400], light: Pe[300], @@ -6055,7 +6048,7 @@ function Vu(t = "light") { dark: Pe[900] }; } -function zu(t = "light") { +function Vu(t = "light") { return t === "dark" ? { main: $e[400], light: $e[300], @@ -6066,7 +6059,7 @@ function zu(t = "light") { dark: $e[900] }; } -function Lu(t = "light") { +function zu(t = "light") { return t === "dark" ? { main: en[400], light: en[300], @@ -6078,17 +6071,17 @@ function Lu(t = "light") { dark: en[900] }; } -function Fu(t) { +function Lu(t) { const { mode: e = "light", contrastThreshold: n = 3, tonalOffset: r = 0.2 - } = t, o = Nt(t, Mu), a = t.primary || Du(e), i = t.secondary || Bu(e), l = t.error || ju(e), c = t.info || Vu(e), d = t.success || zu(e), p = t.warning || Lu(e); + } = t, o = Nt(t, Au), a = t.primary || Mu(e), i = t.secondary || Du(e), l = t.error || ju(e), c = t.info || Bu(e), d = t.success || Vu(e), p = t.warning || zu(e); function f(m) { const h = Ca(m, Lr.text.primary) >= n ? Lr.text.primary : Oa.text.primary; if (process.env.NODE_ENV !== "production") { - const T = Ca(m, h); - T < 3 && console.error([`MUI: The contrast ratio of ${T}:1 for ${h} on ${m}`, "falls below the WCAG recommended absolute minimum contrast ratio of 3:1.", "https://www.w3.org/TR/2008/REC-WCAG20-20081211/#visual-audio-contrast-contrast"].join(` + const S = Ca(m, h); + S < 3 && console.error([`MUI: The contrast ratio of ${S}:1 for ${h} on ${m}`, "falls below the WCAG recommended absolute minimum contrast ratio of 3:1.", "https://www.w3.org/TR/2008/REC-WCAG20-20081211/#visual-audio-contrast-contrast"].join(` `)); } return h; @@ -6096,13 +6089,13 @@ function Fu(t) { const w = ({ color: m, name: h, - mainShade: T = 500, + mainShade: S = 500, lightShade: A = 300, darkShade: R = 700 }) => { - if (m = _({}, m), !m.main && m[T] && (m.main = m[T]), !m.hasOwnProperty("main")) + if (m = _({}, m), !m.main && m[S] && (m.main = m[S]), !m.hasOwnProperty("main")) throw new Error(process.env.NODE_ENV !== "production" ? `MUI: The color${h ? ` (${h})` : ""} provided to augmentColor(color) is invalid. -The color object needs to have a \`main\` property or a \`${T}\` property.` : Ve(11, h ? ` (${h})` : "", T)); +The color object needs to have a \`main\` property or a \`${S}\` property.` : Ve(11, h ? ` (${h})` : "", S)); if (typeof m.main != "string") throw new Error(process.env.NODE_ENV !== "production" ? `MUI: The color${h ? ` (${h})` : ""} provided to augmentColor(color) is invalid. \`color.main\` should be a string, but \`${JSON.stringify(m.main)}\` was provided instead. @@ -6163,7 +6156,7 @@ const theme2 = createTheme({ palette: { name: "success" }), // The grey colors. - grey: Ou, + grey: Cu, // Used by `getContrastText()` to maximize the contrast between // the background and the text. contrastThreshold: n, @@ -6177,14 +6170,14 @@ const theme2 = createTheme({ palette: { tonalOffset: r }, g[e]), o); } -const Uu = ["fontFamily", "fontSize", "fontWeightLight", "fontWeightRegular", "fontWeightMedium", "fontWeightBold", "htmlFontSize", "allVariants", "pxToRem"]; -function Gu(t) { +const Fu = ["fontFamily", "fontSize", "fontWeightLight", "fontWeightRegular", "fontWeightMedium", "fontWeightBold", "htmlFontSize", "allVariants", "pxToRem"]; +function Uu(t) { return Math.round(t * 1e5) / 1e5; } const _a = { textTransform: "uppercase" }, Pa = '"Roboto", "Helvetica", "Arial", sans-serif'; -function Hu(t, e) { +function Gu(t, e) { const n = typeof e == "function" ? e(t) : e, { fontFamily: r = Pa, // The default font size of the Material Specification. @@ -6200,16 +6193,16 @@ function Hu(t, e) { // Apply the CSS properties to all the variants. allVariants: p, pxToRem: f - } = n, w = Nt(n, Uu); + } = n, w = Nt(n, Fu); process.env.NODE_ENV !== "production" && (typeof o != "number" && console.error("MUI: `fontSize` is required to be a number."), typeof d != "number" && console.error("MUI: `htmlFontSize` is required to be a number.")); - const g = o / 14, v = f || ((T) => `${T / d * g}rem`), m = (T, A, R, E, b) => _({ + const g = o / 14, v = f || ((S) => `${S / d * g}rem`), m = (S, A, R, E, b) => _({ fontFamily: r, - fontWeight: T, + fontWeight: S, fontSize: v(A), // Unitless following https://meyerweb.com/eric/thoughts/2006/02/08/unitless-line-heights/ lineHeight: R }, r === Pa ? { - letterSpacing: `${Gu(E / A)}em` + letterSpacing: `${Uu(E / A)}em` } : {}, b, p), h = { h1: m(a, 96, 1.167, -1.5), h2: m(a, 60, 1.2, -0.5), @@ -6247,11 +6240,11 @@ function Hu(t, e) { // No need to clone deep }); } -const Xu = 0.2, Yu = 0.14, Wu = 0.12; +const Hu = 0.2, Xu = 0.14, Yu = 0.12; function ft(...t) { - return [`${t[0]}px ${t[1]}px ${t[2]}px ${t[3]}px rgba(0,0,0,${Xu})`, `${t[4]}px ${t[5]}px ${t[6]}px ${t[7]}px rgba(0,0,0,${Yu})`, `${t[8]}px ${t[9]}px ${t[10]}px ${t[11]}px rgba(0,0,0,${Wu})`].join(","); + return [`${t[0]}px ${t[1]}px ${t[2]}px ${t[3]}px rgba(0,0,0,${Hu})`, `${t[4]}px ${t[5]}px ${t[6]}px ${t[7]}px rgba(0,0,0,${Xu})`, `${t[8]}px ${t[9]}px ${t[10]}px ${t[11]}px rgba(0,0,0,${Yu})`].join(","); } -const qu = ["none", ft(0, 2, 1, -1, 0, 1, 1, 0, 0, 1, 3, 0), ft(0, 3, 1, -2, 0, 2, 2, 0, 0, 1, 5, 0), ft(0, 3, 3, -2, 0, 3, 4, 0, 0, 1, 8, 0), ft(0, 2, 4, -1, 0, 4, 5, 0, 0, 1, 10, 0), ft(0, 3, 5, -1, 0, 5, 8, 0, 0, 1, 14, 0), ft(0, 3, 5, -1, 0, 6, 10, 0, 0, 1, 18, 0), ft(0, 4, 5, -2, 0, 7, 10, 1, 0, 2, 16, 1), ft(0, 5, 5, -3, 0, 8, 10, 1, 0, 3, 14, 2), ft(0, 5, 6, -3, 0, 9, 12, 1, 0, 3, 16, 2), ft(0, 6, 6, -3, 0, 10, 14, 1, 0, 4, 18, 3), ft(0, 6, 7, -4, 0, 11, 15, 1, 0, 4, 20, 3), ft(0, 7, 8, -4, 0, 12, 17, 2, 0, 5, 22, 4), ft(0, 7, 8, -4, 0, 13, 19, 2, 0, 5, 24, 4), ft(0, 7, 9, -4, 0, 14, 21, 2, 0, 5, 26, 4), ft(0, 8, 9, -5, 0, 15, 22, 2, 0, 6, 28, 5), ft(0, 8, 10, -5, 0, 16, 24, 2, 0, 6, 30, 5), ft(0, 8, 11, -5, 0, 17, 26, 2, 0, 6, 32, 5), ft(0, 9, 11, -5, 0, 18, 28, 2, 0, 7, 34, 6), ft(0, 9, 12, -6, 0, 19, 29, 2, 0, 7, 36, 6), ft(0, 10, 13, -6, 0, 20, 31, 3, 0, 8, 38, 7), ft(0, 10, 13, -6, 0, 21, 33, 3, 0, 8, 40, 7), ft(0, 10, 14, -6, 0, 22, 35, 3, 0, 8, 42, 7), ft(0, 11, 14, -7, 0, 23, 36, 3, 0, 9, 44, 8), ft(0, 11, 15, -7, 0, 24, 38, 3, 0, 9, 46, 8)], Ku = qu, Ju = ["duration", "easing", "delay"], Zu = { +const Wu = ["none", ft(0, 2, 1, -1, 0, 1, 1, 0, 0, 1, 3, 0), ft(0, 3, 1, -2, 0, 2, 2, 0, 0, 1, 5, 0), ft(0, 3, 3, -2, 0, 3, 4, 0, 0, 1, 8, 0), ft(0, 2, 4, -1, 0, 4, 5, 0, 0, 1, 10, 0), ft(0, 3, 5, -1, 0, 5, 8, 0, 0, 1, 14, 0), ft(0, 3, 5, -1, 0, 6, 10, 0, 0, 1, 18, 0), ft(0, 4, 5, -2, 0, 7, 10, 1, 0, 2, 16, 1), ft(0, 5, 5, -3, 0, 8, 10, 1, 0, 3, 14, 2), ft(0, 5, 6, -3, 0, 9, 12, 1, 0, 3, 16, 2), ft(0, 6, 6, -3, 0, 10, 14, 1, 0, 4, 18, 3), ft(0, 6, 7, -4, 0, 11, 15, 1, 0, 4, 20, 3), ft(0, 7, 8, -4, 0, 12, 17, 2, 0, 5, 22, 4), ft(0, 7, 8, -4, 0, 13, 19, 2, 0, 5, 24, 4), ft(0, 7, 9, -4, 0, 14, 21, 2, 0, 5, 26, 4), ft(0, 8, 9, -5, 0, 15, 22, 2, 0, 6, 28, 5), ft(0, 8, 10, -5, 0, 16, 24, 2, 0, 6, 30, 5), ft(0, 8, 11, -5, 0, 17, 26, 2, 0, 6, 32, 5), ft(0, 9, 11, -5, 0, 18, 28, 2, 0, 7, 34, 6), ft(0, 9, 12, -6, 0, 19, 29, 2, 0, 7, 36, 6), ft(0, 10, 13, -6, 0, 20, 31, 3, 0, 8, 38, 7), ft(0, 10, 13, -6, 0, 21, 33, 3, 0, 8, 40, 7), ft(0, 10, 14, -6, 0, 22, 35, 3, 0, 8, 42, 7), ft(0, 11, 14, -7, 0, 23, 36, 3, 0, 9, 44, 8), ft(0, 11, 15, -7, 0, 24, 38, 3, 0, 9, 46, 8)], qu = Wu, Ku = ["duration", "easing", "delay"], Ju = { // This is the most common easing curve. easeInOut: "cubic-bezier(0.4, 0, 0.2, 1)", // Objects enter the screen at full velocity from off-screen and @@ -6261,7 +6254,7 @@ const qu = ["none", ft(0, 2, 1, -1, 0, 1, 1, 0, 0, 1, 3, 0), ft(0, 3, 1, -2, 0, easeIn: "cubic-bezier(0.4, 0, 1, 1)", // The sharp curve is used by objects that may return to the screen at any time. sharp: "cubic-bezier(0.4, 0, 0.6, 1)" -}, Qu = { +}, Zu = { shortest: 150, shorter: 200, short: 250, @@ -6277,22 +6270,22 @@ const qu = ["none", ft(0, 2, 1, -1, 0, 1, 1, 0, 0, 1, 3, 0), ft(0, 3, 1, -2, 0, function $a(t) { return `${Math.round(t)}ms`; } -function tw(t) { +function Qu(t) { if (!t) return 0; const e = t / 36; return Math.round((4 + 15 * e ** 0.25 + e / 5) * 10); } -function ew(t) { - const e = _({}, Zu, t.easing), n = _({}, Qu, t.duration); +function tw(t) { + const e = _({}, Ju, t.easing), n = _({}, Zu, t.duration); return _({ - getAutoHeightDuration: tw, + getAutoHeightDuration: Qu, create: (o = ["all"], a = {}) => { const { duration: i = n.standard, easing: l = e.easeInOut, delay: c = 0 - } = a, d = Nt(a, Ju); + } = a, d = Nt(a, Ku); if (process.env.NODE_ENV !== "production") { const p = (w) => typeof w == "string", f = (w) => !isNaN(parseFloat(w)); !p(o) && !Array.isArray(o) && console.error('MUI: Argument "props" must be a string or Array.'), !f(i) && !p(i) && console.error(`MUI: Argument "duration" must be a number or a string but found ${i}.`), p(l) || console.error('MUI: Argument "easing" must be a string.'), !f(c) && !p(c) && console.error('MUI: Argument "delay" must be a number or a string.'), typeof a != "object" && console.error(["MUI: Secong argument of transition.create must be an object.", "Arguments should be either `create('prop1', options)` or `create(['prop1', 'prop2'], options)`"].join(` @@ -6305,7 +6298,7 @@ function ew(t) { duration: n }); } -const nw = { +const ew = { mobileStepper: 1e3, fab: 1050, speedDial: 1050, @@ -6314,25 +6307,25 @@ const nw = { modal: 1300, snackbar: 1400, tooltip: 1500 -}, rw = nw, ow = ["breakpoints", "mixins", "spacing", "palette", "transitions", "typography", "shape"]; -function aw(t = {}, ...e) { +}, nw = ew, rw = ["breakpoints", "mixins", "spacing", "palette", "transitions", "typography", "shape"]; +function ow(t = {}, ...e) { const { mixins: n = {}, palette: r = {}, transitions: o = {}, typography: a = {} - } = t, i = Nt(t, ow); + } = t, i = Nt(t, rw); if (t.vars) throw new Error(process.env.NODE_ENV !== "production" ? "MUI: `vars` is a private field used for CSS variables support.\nPlease use another name." : Ve(18)); - const l = Fu(r), c = So(t); + const l = Lu(r), c = So(t); let d = Zt(c, { - mixins: Su(c.breakpoints, n), + mixins: Eu(c.breakpoints, n), palette: l, // Don't use [...shadows] until you've verified its transpiled code is not invoking the iterator protocol. - shadows: Ku.slice(), - typography: Hu(l, a), - transitions: ew(o), - zIndex: _({}, rw) + shadows: qu.slice(), + typography: Gu(l, a), + transitions: tw(o), + zIndex: _({}, nw) }); if (d = Zt(d, i), d = e.reduce((p, f) => Zt(p, f), d), process.env.NODE_ENV !== "production") { const p = ["active", "checked", "completed", "disabled", "error", "expanded", "focused", "focusVisible", "required", "selected"], f = (w, g) => { @@ -6365,28 +6358,28 @@ function aw(t = {}, ...e) { }); }, d; } -const iw = aw(), Co = iw, Oo = "$$material"; +const aw = ow(), Co = aw, Oo = "$$material"; function Ro({ props: t, name: e }) { - return yu({ + return vu({ props: t, name: e, defaultTheme: Co, themeId: Oo }); } -const sw = (t) => Gn(t) && t !== "classes", lw = bu({ +const iw = (t) => Gn(t) && t !== "classes", sw = gu({ themeId: Oo, defaultTheme: Co, - rootShouldForwardProp: sw -}), Rn = lw; -function cw(t) { + rootShouldForwardProp: iw +}), Rn = sw; +function lw(t) { return pr("MuiSvgIcon", t); } os("MuiSvgIcon", ["root", "colorPrimary", "colorSecondary", "colorAction", "colorError", "colorDisabled", "fontSizeInherit", "fontSizeSmall", "fontSizeMedium", "fontSizeLarge"]); -const dw = ["children", "className", "color", "component", "fontSize", "htmlColor", "inheritViewBox", "titleAccess", "viewBox"], pw = (t) => { +const cw = ["children", "className", "color", "component", "fontSize", "htmlColor", "inheritViewBox", "titleAccess", "viewBox"], dw = (t) => { const { color: e, fontSize: n, @@ -6394,8 +6387,8 @@ const dw = ["children", "className", "color", "component", "fontSize", "htmlColo } = t, o = { root: ["root", e !== "inherit" && `color${Wt(e)}`, `fontSize${Wt(n)}`] }; - return yo(o, cw, r); -}, uw = Rn("svg", { + return yo(o, lw, r); +}, pw = Rn("svg", { name: "MuiSvgIcon", slot: "Root", overridesResolver: (t, e) => { @@ -6448,7 +6441,7 @@ const dw = ["children", "className", "color", "component", "fontSize", "htmlColo inheritViewBox: p = !1, titleAccess: f, viewBox: w = "0 0 24 24" - } = r, g = Nt(r, dw), v = /* @__PURE__ */ D.isValidElement(o) && o.type === "svg", m = _({}, r, { + } = r, g = Nt(r, cw), v = /* @__PURE__ */ D.isValidElement(o) && o.type === "svg", m = _({}, r, { color: i, component: l, fontSize: c, @@ -6458,10 +6451,10 @@ const dw = ["children", "className", "color", "component", "fontSize", "htmlColo hasSvgAsChild: v }), h = {}; p || (h.viewBox = w); - const T = pw(m); - return /* @__PURE__ */ x(uw, _({ + const S = dw(m); + return /* @__PURE__ */ x(pw, _({ as: l, - className: be(T.root, a), + className: be(S.root, a), focusable: "false", color: d, "aria-hidden": f ? void 0 : !0, @@ -6559,34 +6552,34 @@ function ps(t, e) { } return process.env.NODE_ENV !== "production" && (n.displayName = `${e}Icon`), n.muiName = Ia.muiName, /* @__PURE__ */ D.memo(/* @__PURE__ */ D.forwardRef(n)); } -const ww = { +const uw = { configure: (t) => { process.env.NODE_ENV !== "production" && console.warn(["MUI: `ClassNameGenerator` import from `@mui/material/utils` is outdated and might cause unexpected issues.", "", "You should use `import { unstable_ClassNameGenerator } from '@mui/material/className'` instead", "", "The detail of the issue: https://github.com/mui/material-ui/issues/30011#issuecomment-1024993401", "", "The updated documentation: https://mui.com/guides/classname-generator/"].join(` `)), ns.configure(t); } -}, fw = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({ +}, ww = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({ __proto__: null, capitalize: Wt, - createChainedFunction: Ud, + createChainedFunction: Fd, createSvgIcon: ps, - debounce: Gd, - deprecatedPropType: Hd, - isMuiElement: Xd, + debounce: Ud, + deprecatedPropType: Gd, + isMuiElement: Hd, ownerDocument: Yn, - ownerWindow: Yd, - requirePropFactory: Wd, + ownerWindow: Xd, + requirePropFactory: Yd, setRef: Wn, - unstable_ClassNameGenerator: ww, + unstable_ClassNameGenerator: uw, unstable_useEnhancedEffect: ze, unstable_useId: Zi, - unsupportedProp: Jd, + unsupportedProp: Kd, useControlled: Qi, useEventCallback: to, useForkRef: xe, useIsFocusVisible: ts -}, Symbol.toStringTag, { value: "Module" })), mw = /* @__PURE__ */ kd(fw); +}, Symbol.toStringTag, { value: "Module" })), fw = /* @__PURE__ */ Nd(ww); var Aa; -function hw() { +function mw() { return Aa || (Aa = 1, function(t) { "use client"; Object.defineProperty(t, "__esModule", { @@ -6597,35 +6590,35 @@ function hw() { return e.createSvgIcon; } }); - var e = mw; + var e = fw; }(Ir)), Ir; } -var gw = Ed; +var hw = kd; Object.defineProperty(go, "__esModule", { value: !0 }); -var us = go.default = void 0, bw = gw(hw()), vw = Xs; -us = go.default = (0, bw.default)(/* @__PURE__ */ (0, vw.jsx)("path", { +var us = go.default = void 0, gw = hw(mw()), bw = Xs; +us = go.default = (0, gw.default)(/* @__PURE__ */ (0, bw.jsx)("path", { d: "m10 17 5-5-5-5z" }), "ArrowRight"); -function yw(t) { +function vw(t) { return typeof t == "string"; } function sn(t, e, n) { - return t === void 0 || yw(t) ? e : _({}, e, { + return t === void 0 || vw(t) ? e : _({}, e, { ownerState: _({}, e.ownerState, n) }); } -const xw = { +const yw = { disableDefaultClasses: !1 -}, Nw = /* @__PURE__ */ D.createContext(xw); -function kw(t) { +}, xw = /* @__PURE__ */ D.createContext(yw); +function Nw(t) { const { disableDefaultClasses: e - } = D.useContext(Nw); + } = D.useContext(xw); return (n) => e ? "" : t(n); } -function Ew(t, e = []) { +function kw(t, e = []) { if (t === void 0) return {}; const n = {}; @@ -6633,7 +6626,7 @@ function Ew(t, e = []) { n[r] = t[r]; }), n; } -function Sw(t, e, n) { +function Ew(t, e, n) { return typeof t == "function" ? t(e, n) : t; } function Ma(t) { @@ -6644,7 +6637,7 @@ function Ma(t) { e[n] = t[n]; }), e; } -function Tw(t) { +function Sw(t) { const { getSlotProps: e, additionalProps: n, @@ -6659,24 +6652,24 @@ function Tw(t) { internalRef: void 0 }; } - const i = Ew(_({}, o, r)), l = Ma(r), c = Ma(o), d = e(i), p = be(d == null ? void 0 : d.className, n == null ? void 0 : n.className, a, o == null ? void 0 : o.className, r == null ? void 0 : r.className), f = _({}, d == null ? void 0 : d.style, n == null ? void 0 : n.style, o == null ? void 0 : o.style, r == null ? void 0 : r.style), w = _({}, d, n, c, l); + const i = kw(_({}, o, r)), l = Ma(r), c = Ma(o), d = e(i), p = be(d == null ? void 0 : d.className, n == null ? void 0 : n.className, a, o == null ? void 0 : o.className, r == null ? void 0 : r.className), f = _({}, d == null ? void 0 : d.style, n == null ? void 0 : n.style, o == null ? void 0 : o.style, r == null ? void 0 : r.style), w = _({}, d, n, c, l); return p.length > 0 && (w.className = p), Object.keys(f).length > 0 && (w.style = f), { props: w, internalRef: d.ref }; } -const Cw = ["elementType", "externalSlotProps", "ownerState", "skipResolvingSlotProps"]; -function Ow(t) { +const Tw = ["elementType", "externalSlotProps", "ownerState", "skipResolvingSlotProps"]; +function Cw(t) { var e; const { elementType: n, externalSlotProps: r, ownerState: o, skipResolvingSlotProps: a = !1 - } = t, i = Nt(t, Cw), l = a ? {} : Sw(r, o), { + } = t, i = Nt(t, Tw), l = a ? {} : Ew(r, o), { props: c, internalRef: d - } = Tw(_({}, i, { + } = Sw(_({}, i, { externalSlotProps: l })), p = xe(d, l == null ? void 0 : l.ref, (e = t.additionalProps) == null ? void 0 : e.ref); return sn(n, _({}, c, { @@ -6684,23 +6677,23 @@ function Ow(t) { }), o); } const ws = "base"; -function Rw(t) { +function Ow(t) { return `${ws}--${t}`; } -function _w(t, e) { +function Rw(t, e) { return `${ws}-${t}-${e}`; } function fs(t, e) { const n = rs[e]; - return n ? Rw(n) : _w(t, e); + return n ? Ow(n) : Rw(t, e); } -function Pw(t, e) { +function _w(t, e) { const n = {}; return e.forEach((r) => { n[r] = fs(t, r); }), n; } -function $w(t) { +function Pw(t) { return typeof t == "function" ? t() : t; } const Kn = /* @__PURE__ */ D.forwardRef(function(e, n) { @@ -6710,7 +6703,7 @@ const Kn = /* @__PURE__ */ D.forwardRef(function(e, n) { disablePortal: a = !1 } = e, [i, l] = D.useState(null), c = xe(/* @__PURE__ */ D.isValidElement(r) ? r.ref : null, n); if (ze(() => { - a || l($w(o) || document.body); + a || l(Pw(o) || document.body); }, [o, a]), ze(() => { if (i && !a) return Wn(n, i), () => { @@ -6757,12 +6750,12 @@ process.env.NODE_ENV !== "production" && (Kn.propTypes = { */ disablePortal: u.bool }); -process.env.NODE_ENV !== "production" && (Kn["propTypes"] = Dd(Kn.propTypes)); -var Tt = "top", jt = "bottom", Vt = "right", Ct = "left", Po = "auto", _n = [Tt, jt, Vt, Ct], Le = "start", xn = "end", Iw = "clippingParents", ms = "viewport", nn = "popper", Aw = "reference", Da = /* @__PURE__ */ _n.reduce(function(t, e) { +process.env.NODE_ENV !== "production" && (Kn["propTypes"] = Md(Kn.propTypes)); +var Tt = "top", Bt = "bottom", Vt = "right", Ct = "left", Po = "auto", _n = [Tt, Bt, Vt, Ct], Le = "start", xn = "end", $w = "clippingParents", ms = "viewport", nn = "popper", Iw = "reference", Da = /* @__PURE__ */ _n.reduce(function(t, e) { return t.concat([e + "-" + Le, e + "-" + xn]); }, []), hs = /* @__PURE__ */ [].concat(_n, [Po]).reduce(function(t, e) { return t.concat([e, e + "-" + Le, e + "-" + xn]); -}, []), Mw = "beforeRead", Dw = "read", Bw = "afterRead", jw = "beforeMain", Vw = "main", zw = "afterMain", Lw = "beforeWrite", Fw = "write", Uw = "afterWrite", Gw = [Mw, Dw, Bw, jw, Vw, zw, Lw, Fw, Uw]; +}, []), Aw = "beforeRead", Mw = "read", Dw = "afterRead", jw = "beforeMain", Bw = "main", Vw = "afterMain", zw = "beforeWrite", Lw = "write", Fw = "afterWrite", Uw = [Aw, Mw, Dw, jw, Bw, Vw, zw, Lw, Fw]; function qt(t) { return t ? (t.nodeName || "").toLowerCase() : null; } @@ -6779,7 +6772,7 @@ function ke(t) { var e = At(t).Element; return t instanceof e || t instanceof Element; } -function Bt(t) { +function jt(t) { var e = At(t).HTMLElement; return t instanceof e || t instanceof HTMLElement; } @@ -6789,17 +6782,17 @@ function $o(t) { var e = At(t).ShadowRoot; return t instanceof e || t instanceof ShadowRoot; } -function Hw(t) { +function Gw(t) { var e = t.state; Object.keys(e.elements).forEach(function(n) { var r = e.styles[n] || {}, o = e.attributes[n] || {}, a = e.elements[n]; - !Bt(a) || !qt(a) || (Object.assign(a.style, r), Object.keys(o).forEach(function(i) { + !jt(a) || !qt(a) || (Object.assign(a.style, r), Object.keys(o).forEach(function(i) { var l = o[i]; l === !1 ? a.removeAttribute(i) : a.setAttribute(i, l === !0 ? "" : l); })); }); } -function Xw(t) { +function Hw(t) { var e = t.state, n = { popper: { position: e.options.strategy, @@ -6817,18 +6810,18 @@ function Xw(t) { var o = e.elements[r], a = e.attributes[r] || {}, i = Object.keys(e.styles.hasOwnProperty(r) ? e.styles[r] : n[r]), l = i.reduce(function(c, d) { return c[d] = "", c; }, {}); - !Bt(o) || !qt(o) || (Object.assign(o.style, l), Object.keys(a).forEach(function(c) { + !jt(o) || !qt(o) || (Object.assign(o.style, l), Object.keys(a).forEach(function(c) { o.removeAttribute(c); })); }); }; } -const Yw = { +const Xw = { name: "applyStyles", enabled: !0, phase: "write", - fn: Hw, - effect: Xw, + fn: Gw, + effect: Hw, requires: ["computeStyles"] }; function Xt(t) { @@ -6847,7 +6840,7 @@ function gs() { function Ue(t, e, n) { e === void 0 && (e = !1), n === void 0 && (n = !1); var r = t.getBoundingClientRect(), o = 1, a = 1; - e && Bt(t) && (o = t.offsetWidth > 0 && Fe(r.width) / t.offsetWidth || 1, a = t.offsetHeight > 0 && Fe(r.height) / t.offsetHeight || 1); + e && jt(t) && (o = t.offsetWidth > 0 && Fe(r.width) / t.offsetWidth || 1, a = t.offsetHeight > 0 && Fe(r.height) / t.offsetHeight || 1); var i = ke(t) ? At(t) : window, l = i.visualViewport, c = !gs() && n, d = (r.left + (c && l ? l.offsetLeft : 0)) / o, p = (r.top + (c && l ? l.offsetTop : 0)) / a, f = r.width / o, w = r.height / a; return { width: f, @@ -6886,7 +6879,7 @@ function bs(t, e) { function te(t) { return At(t).getComputedStyle(t); } -function Ww(t) { +function Yw(t) { return ["table", "td", "th"].indexOf(qt(t)) >= 0; } function le(t) { @@ -6907,19 +6900,19 @@ function xr(t) { le(t) ); } -function Ba(t) { - return !Bt(t) || // https://github.com/popperjs/popper-core/issues/837 +function ja(t) { + return !jt(t) || // https://github.com/popperjs/popper-core/issues/837 te(t).position === "fixed" ? null : t.offsetParent; } -function qw(t) { +function Ww(t) { var e = /firefox/i.test(no()), n = /Trident/i.test(no()); - if (n && Bt(t)) { + if (n && jt(t)) { var r = te(t); if (r.position === "fixed") return null; } var o = xr(t); - for ($o(o) && (o = o.host); Bt(o) && ["html", "body"].indexOf(qt(o)) < 0; ) { + for ($o(o) && (o = o.host); jt(o) && ["html", "body"].indexOf(qt(o)) < 0; ) { var a = te(o); if (a.transform !== "none" || a.perspective !== "none" || a.contain === "paint" || ["transform", "perspective"].indexOf(a.willChange) !== -1 || e && a.willChange === "filter" || e && a.filter && a.filter !== "none") return o; @@ -6928,9 +6921,9 @@ function qw(t) { return null; } function Pn(t) { - for (var e = At(t), n = Ba(t); n && Ww(n) && te(n).position === "static"; ) - n = Ba(n); - return n && (qt(n) === "html" || qt(n) === "body" && te(n).position === "static") ? e : n || qw(t) || e; + for (var e = At(t), n = ja(t); n && Yw(n) && te(n).position === "static"; ) + n = ja(n); + return n && (qt(n) === "html" || qt(n) === "body" && te(n).position === "static") ? e : n || Ww(t) || e; } function Ao(t) { return ["top", "bottom"].indexOf(t) >= 0 ? "x" : "y"; @@ -6938,7 +6931,7 @@ function Ao(t) { function un(t, e, n) { return ve(t, Jn(e, n)); } -function Kw(t, e, n) { +function qw(t, e, n) { var r = un(t, e, n); return r > n ? n : r; } @@ -6958,48 +6951,48 @@ function xs(t, e) { return n[r] = t, n; }, {}); } -var Jw = function(e, n) { +var Kw = function(e, n) { return e = typeof e == "function" ? e(Object.assign({}, n.rects, { placement: n.placement })) : e, ys(typeof e != "number" ? e : xs(e, _n)); }; -function Zw(t) { +function Jw(t) { var e, n = t.state, r = t.name, o = t.options, a = n.elements.arrow, i = n.modifiersData.popperOffsets, l = Xt(n.placement), c = Ao(l), d = [Ct, Vt].indexOf(l) >= 0, p = d ? "height" : "width"; if (!(!a || !i)) { - var f = Jw(o.padding, n), w = Io(a), g = c === "y" ? Tt : Ct, v = c === "y" ? jt : Vt, m = n.rects.reference[p] + n.rects.reference[c] - i[c] - n.rects.popper[p], h = i[c] - n.rects.reference[c], T = Pn(a), A = T ? c === "y" ? T.clientHeight || 0 : T.clientWidth || 0 : 0, R = m / 2 - h / 2, E = f[g], b = A - w[p] - f[v], $ = A / 2 - w[p] / 2 + R, z = un(E, $, b), H = c; + var f = Kw(o.padding, n), w = Io(a), g = c === "y" ? Tt : Ct, v = c === "y" ? Bt : Vt, m = n.rects.reference[p] + n.rects.reference[c] - i[c] - n.rects.popper[p], h = i[c] - n.rects.reference[c], S = Pn(a), A = S ? c === "y" ? S.clientHeight || 0 : S.clientWidth || 0 : 0, R = m / 2 - h / 2, E = f[g], b = A - w[p] - f[v], $ = A / 2 - w[p] / 2 + R, z = un(E, $, b), H = c; n.modifiersData[r] = (e = {}, e[H] = z, e.centerOffset = z - $, e); } } -function Qw(t) { +function Zw(t) { var e = t.state, n = t.options, r = n.element, o = r === void 0 ? "[data-popper-arrow]" : r; o != null && (typeof o == "string" && (o = e.elements.popper.querySelector(o), !o) || bs(e.elements.popper, o) && (e.elements.arrow = o)); } -const tf = { +const Qw = { name: "arrow", enabled: !0, phase: "main", - fn: Zw, - effect: Qw, + fn: Jw, + effect: Zw, requires: ["popperOffsets"], requiresIfExists: ["preventOverflow"] }; function Ge(t) { return t.split("-")[1]; } -var ef = { +var tf = { top: "auto", right: "auto", bottom: "auto", left: "auto" }; -function nf(t, e) { +function ef(t, e) { var n = t.x, r = t.y, o = e.devicePixelRatio || 1; return { x: Fe(n * o) / o || 0, y: Fe(r * o) / o || 0 }; } -function ja(t) { +function Ba(t) { var e, n = t.popper, r = t.popperRect, o = t.placement, a = t.variation, i = t.offsets, l = t.position, c = t.gpuAcceleration, d = t.adaptive, p = t.roundOffsets, f = t.isFixed, w = i.x, g = w === void 0 ? 0 : w, v = i.y, m = v === void 0 ? 0 : v, h = typeof p == "function" ? p({ x: g, y: m @@ -7008,18 +7001,18 @@ function ja(t) { y: m }; g = h.x, m = h.y; - var T = i.hasOwnProperty("x"), A = i.hasOwnProperty("y"), R = Ct, E = Tt, b = window; + var S = i.hasOwnProperty("x"), A = i.hasOwnProperty("y"), R = Ct, E = Tt, b = window; if (d) { var $ = Pn(n), z = "clientHeight", H = "clientWidth"; if ($ === At(n) && ($ = le(n), te($).position !== "static" && l === "absolute" && (z = "scrollHeight", H = "scrollWidth")), $ = $, o === Tt || (o === Ct || o === Vt) && a === xn) { - E = jt; + E = Bt; var C = f && $ === b && b.visualViewport ? b.visualViewport.height : ( // $FlowFixMe[prop-missing] $[z] ); m -= C - r.height, m *= c ? 1 : -1; } - if (o === Ct || (o === Tt || o === jt) && a === xn) { + if (o === Ct || (o === Tt || o === Bt) && a === xn) { R = Vt; var P = f && $ === b && b.visualViewport ? b.visualViewport.width : ( // $FlowFixMe[prop-missing] @@ -7030,20 +7023,20 @@ function ja(t) { } var k = Object.assign({ position: l - }, d && ef), B = p === !0 ? nf({ + }, d && tf), j = p === !0 ? ef({ x: g, y: m }, At(n)) : { x: g, y: m }; - if (g = B.x, m = B.y, c) { + if (g = j.x, m = j.y, c) { var M; - return Object.assign({}, k, (M = {}, M[E] = A ? "0" : "", M[R] = T ? "0" : "", M.transform = (b.devicePixelRatio || 1) <= 1 ? "translate(" + g + "px, " + m + "px)" : "translate3d(" + g + "px, " + m + "px, 0)", M)); + return Object.assign({}, k, (M = {}, M[E] = A ? "0" : "", M[R] = S ? "0" : "", M.transform = (b.devicePixelRatio || 1) <= 1 ? "translate(" + g + "px, " + m + "px)" : "translate3d(" + g + "px, " + m + "px, 0)", M)); } - return Object.assign({}, k, (e = {}, e[E] = A ? m + "px" : "", e[R] = T ? g + "px" : "", e.transform = "", e)); + return Object.assign({}, k, (e = {}, e[E] = A ? m + "px" : "", e[R] = S ? g + "px" : "", e.transform = "", e)); } -function rf(t) { +function nf(t) { var e = t.state, n = t.options, r = n.gpuAcceleration, o = r === void 0 ? !0 : r, a = n.adaptive, i = a === void 0 ? !0 : a, l = n.roundOffsets, c = l === void 0 ? !0 : l, d = { placement: Xt(e.placement), variation: Ge(e.placement), @@ -7052,12 +7045,12 @@ function rf(t) { gpuAcceleration: o, isFixed: e.options.strategy === "fixed" }; - e.modifiersData.popperOffsets != null && (e.styles.popper = Object.assign({}, e.styles.popper, ja(Object.assign({}, d, { + e.modifiersData.popperOffsets != null && (e.styles.popper = Object.assign({}, e.styles.popper, Ba(Object.assign({}, d, { offsets: e.modifiersData.popperOffsets, position: e.options.strategy, adaptive: i, roundOffsets: c - })))), e.modifiersData.arrow != null && (e.styles.arrow = Object.assign({}, e.styles.arrow, ja(Object.assign({}, d, { + })))), e.modifiersData.arrow != null && (e.styles.arrow = Object.assign({}, e.styles.arrow, Ba(Object.assign({}, d, { offsets: e.modifiersData.arrow, position: "absolute", adaptive: !1, @@ -7066,17 +7059,17 @@ function rf(t) { "data-popper-placement": e.placement }); } -const of = { +const rf = { name: "computeStyles", enabled: !0, phase: "beforeWrite", - fn: rf, + fn: nf, data: {} }; var zn = { passive: !0 }; -function af(t) { +function of(t) { var e = t.state, n = t.instance, r = t.options, o = r.scroll, a = o === void 0 ? !0 : o, i = r.resize, l = i === void 0 ? !0 : i, c = At(e.elements.popper), d = [].concat(e.scrollParents.reference, e.scrollParents.popper); return a && d.forEach(function(p) { p.addEventListener("scroll", n.update, zn); @@ -7086,16 +7079,16 @@ function af(t) { }), l && c.removeEventListener("resize", n.update, zn); }; } -const sf = { +const af = { name: "eventListeners", enabled: !0, phase: "write", fn: function() { }, - effect: af, + effect: of, data: {} }; -var lf = { +var sf = { left: "right", right: "left", bottom: "top", @@ -7103,16 +7096,16 @@ var lf = { }; function Xn(t) { return t.replace(/left|right|bottom|top/g, function(e) { - return lf[e]; + return sf[e]; }); } -var cf = { +var lf = { start: "end", end: "start" }; function Va(t) { return t.replace(/start|end/g, function(e) { - return cf[e]; + return lf[e]; }); } function Mo(t) { @@ -7125,7 +7118,7 @@ function Mo(t) { function Do(t) { return Ue(le(t)).left + Mo(t).scrollLeft; } -function df(t, e) { +function cf(t, e) { var n = At(t), r = le(t), o = n.visualViewport, a = r.clientWidth, i = r.clientHeight, l = 0, c = 0; if (o) { a = o.width, i = o.height; @@ -7139,7 +7132,7 @@ function df(t, e) { y: c }; } -function pf(t) { +function df(t) { var e, n = le(t), r = Mo(t), o = (e = t.ownerDocument) == null ? void 0 : e.body, a = ve(n.scrollWidth, n.clientWidth, o ? o.scrollWidth : 0, o ? o.clientWidth : 0), i = ve(n.scrollHeight, n.clientHeight, o ? o.scrollHeight : 0, o ? o.clientHeight : 0), l = -r.scrollLeft + Do(t), c = -r.scrollTop; return te(o || n).direction === "rtl" && (l += ve(n.clientWidth, o ? o.clientWidth : 0) - a), { width: a, @@ -7148,17 +7141,17 @@ function pf(t) { y: c }; } -function Bo(t) { +function jo(t) { var e = te(t), n = e.overflow, r = e.overflowX, o = e.overflowY; return /auto|scroll|overlay|hidden/.test(n + o + r); } function Ns(t) { - return ["html", "body", "#document"].indexOf(qt(t)) >= 0 ? t.ownerDocument.body : Bt(t) && Bo(t) ? t : Ns(xr(t)); + return ["html", "body", "#document"].indexOf(qt(t)) >= 0 ? t.ownerDocument.body : jt(t) && jo(t) ? t : Ns(xr(t)); } function wn(t, e) { var n; e === void 0 && (e = []); - var r = Ns(t), o = r === ((n = t.ownerDocument) == null ? void 0 : n.body), a = At(r), i = o ? [a].concat(a.visualViewport || [], Bo(r) ? r : []) : r, l = e.concat(i); + var r = Ns(t), o = r === ((n = t.ownerDocument) == null ? void 0 : n.body), a = At(r), i = o ? [a].concat(a.visualViewport || [], jo(r) ? r : []) : r, l = e.concat(i); return o ? l : ( // $FlowFixMe[incompatible-call]: isBody tells us target will be an HTMLElement here l.concat(wn(xr(i))) @@ -7172,21 +7165,21 @@ function ro(t) { bottom: t.y + t.height }); } -function uf(t, e) { +function pf(t, e) { var n = Ue(t, !1, e === "fixed"); return n.top = n.top + t.clientTop, n.left = n.left + t.clientLeft, n.bottom = n.top + t.clientHeight, n.right = n.left + t.clientWidth, n.width = t.clientWidth, n.height = t.clientHeight, n.x = n.left, n.y = n.top, n; } function za(t, e, n) { - return e === ms ? ro(df(t, n)) : ke(e) ? uf(e, n) : ro(pf(le(t))); + return e === ms ? ro(cf(t, n)) : ke(e) ? pf(e, n) : ro(df(le(t))); } -function wf(t) { - var e = wn(xr(t)), n = ["absolute", "fixed"].indexOf(te(t).position) >= 0, r = n && Bt(t) ? Pn(t) : t; +function uf(t) { + var e = wn(xr(t)), n = ["absolute", "fixed"].indexOf(te(t).position) >= 0, r = n && jt(t) ? Pn(t) : t; return ke(r) ? e.filter(function(o) { return ke(o) && bs(o, r) && qt(o) !== "body"; }) : []; } -function ff(t, e, n, r) { - var o = e === "clippingParents" ? wf(t) : [].concat(e), a = [].concat(o, [n]), i = a[0], l = a.reduce(function(c, d) { +function wf(t, e, n, r) { + var o = e === "clippingParents" ? uf(t) : [].concat(e), a = [].concat(o, [n]), i = a[0], l = a.reduce(function(c, d) { var p = za(t, d, r); return c.top = ve(p.top, c.top), c.right = Jn(p.right, c.right), c.bottom = Jn(p.bottom, c.bottom), c.left = ve(p.left, c.left), c; }, za(t, i, r)); @@ -7201,7 +7194,7 @@ function ks(t) { y: e.y - n.height }; break; - case jt: + case Bt: c = { x: i, y: e.y + e.height @@ -7241,27 +7234,27 @@ function ks(t) { } function Nn(t, e) { e === void 0 && (e = {}); - var n = e, r = n.placement, o = r === void 0 ? t.placement : r, a = n.strategy, i = a === void 0 ? t.strategy : a, l = n.boundary, c = l === void 0 ? Iw : l, d = n.rootBoundary, p = d === void 0 ? ms : d, f = n.elementContext, w = f === void 0 ? nn : f, g = n.altBoundary, v = g === void 0 ? !1 : g, m = n.padding, h = m === void 0 ? 0 : m, T = ys(typeof h != "number" ? h : xs(h, _n)), A = w === nn ? Aw : nn, R = t.rects.popper, E = t.elements[v ? A : w], b = ff(ke(E) ? E : E.contextElement || le(t.elements.popper), c, p, i), $ = Ue(t.elements.reference), z = ks({ + var n = e, r = n.placement, o = r === void 0 ? t.placement : r, a = n.strategy, i = a === void 0 ? t.strategy : a, l = n.boundary, c = l === void 0 ? $w : l, d = n.rootBoundary, p = d === void 0 ? ms : d, f = n.elementContext, w = f === void 0 ? nn : f, g = n.altBoundary, v = g === void 0 ? !1 : g, m = n.padding, h = m === void 0 ? 0 : m, S = ys(typeof h != "number" ? h : xs(h, _n)), A = w === nn ? Iw : nn, R = t.rects.popper, E = t.elements[v ? A : w], b = wf(ke(E) ? E : E.contextElement || le(t.elements.popper), c, p, i), $ = Ue(t.elements.reference), z = ks({ reference: $, element: R, strategy: "absolute", placement: o }), H = ro(Object.assign({}, R, z)), C = w === nn ? H : $, P = { - top: b.top - C.top + T.top, - bottom: C.bottom - b.bottom + T.bottom, - left: b.left - C.left + T.left, - right: C.right - b.right + T.right + top: b.top - C.top + S.top, + bottom: C.bottom - b.bottom + S.bottom, + left: b.left - C.left + S.left, + right: C.right - b.right + S.right }, k = t.modifiersData.offset; if (w === nn && k) { - var B = k[o]; + var j = k[o]; Object.keys(P).forEach(function(M) { - var J = [Vt, jt].indexOf(M) >= 0 ? 1 : -1, q = [Tt, jt].indexOf(M) >= 0 ? "y" : "x"; - P[M] += B[q] * J; + var J = [Vt, Bt].indexOf(M) >= 0 ? 1 : -1, q = [Tt, Bt].indexOf(M) >= 0 ? "y" : "x"; + P[M] += j[q] * J; }); } return P; } -function mf(t, e) { +function ff(t, e) { e === void 0 && (e = {}); var n = e, r = n.placement, o = n.boundary, a = n.rootBoundary, i = n.padding, l = n.flipVariations, c = n.allowedAutoPlacements, d = c === void 0 ? hs : c, p = Ge(r), f = p ? l ? Da : Da.filter(function(v) { return Ge(v) === p; @@ -7281,17 +7274,17 @@ function mf(t, e) { return g[v] - g[m]; }); } -function hf(t) { +function mf(t) { if (Xt(t) === Po) return []; var e = Xn(t); return [Va(t), e, Va(e)]; } -function gf(t) { +function hf(t) { var e = t.state, n = t.options, r = t.name; if (!e.modifiersData[r]._skip) { - for (var o = n.mainAxis, a = o === void 0 ? !0 : o, i = n.altAxis, l = i === void 0 ? !0 : i, c = n.fallbackPlacements, d = n.padding, p = n.boundary, f = n.rootBoundary, w = n.altBoundary, g = n.flipVariations, v = g === void 0 ? !0 : g, m = n.allowedAutoPlacements, h = e.options.placement, T = Xt(h), A = T === h, R = c || (A || !v ? [Xn(h)] : hf(h)), E = [h].concat(R).reduce(function(V, W) { - return V.concat(Xt(W) === Po ? mf(e, { + for (var o = n.mainAxis, a = o === void 0 ? !0 : o, i = n.altAxis, l = i === void 0 ? !0 : i, c = n.fallbackPlacements, d = n.padding, p = n.boundary, f = n.rootBoundary, w = n.altBoundary, g = n.flipVariations, v = g === void 0 ? !0 : g, m = n.allowedAutoPlacements, h = e.options.placement, S = Xt(h), A = S === h, R = c || (A || !v ? [Xn(h)] : mf(h)), E = [h].concat(R).reduce(function(V, W) { + return V.concat(Xt(W) === Po ? ff(e, { placement: W, boundary: p, rootBoundary: f, @@ -7300,16 +7293,16 @@ function gf(t) { allowedAutoPlacements: m }) : W); }, []), b = e.rects.reference, $ = e.rects.popper, z = /* @__PURE__ */ new Map(), H = !0, C = E[0], P = 0; P < E.length; P++) { - var k = E[P], B = Xt(k), M = Ge(k) === Le, J = [Tt, jt].indexOf(B) >= 0, q = J ? "width" : "height", U = Nn(e, { + var k = E[P], j = Xt(k), M = Ge(k) === Le, J = [Tt, Bt].indexOf(j) >= 0, q = J ? "width" : "height", U = Nn(e, { placement: k, boundary: p, rootBoundary: f, altBoundary: w, padding: d - }), tt = J ? M ? Vt : Ct : M ? jt : Tt; + }), tt = J ? M ? Vt : Ct : M ? Bt : Tt; b[q] > $[q] && (tt = Xn(tt)); var at = Xn(tt), rt = []; - if (a && rt.push(U[B] <= 0), l && rt.push(U[tt] <= 0, U[at] <= 0), rt.every(function(V) { + if (a && rt.push(U[j] <= 0), l && rt.push(U[tt] <= 0, U[at] <= 0), rt.every(function(V) { return V; })) { C = k, H = !1; @@ -7336,11 +7329,11 @@ function gf(t) { e.placement !== C && (e.modifiersData[r]._skip = !0, e.placement = C, e.reset = !0); } } -const bf = { +const gf = { name: "flip", enabled: !0, phase: "main", - fn: gf, + fn: hf, requiresIfExists: ["offset"], data: { _skip: !1 @@ -7358,11 +7351,11 @@ function La(t, e, n) { }; } function Fa(t) { - return [Tt, Vt, jt, Ct].some(function(e) { + return [Tt, Vt, Bt, Ct].some(function(e) { return t[e] >= 0; }); } -function vf(t) { +function bf(t) { var e = t.state, n = t.name, r = e.rects.reference, o = e.rects.popper, a = e.modifiersData.preventOverflow, i = Nn(e, { elementContext: "reference" }), l = Nn(e, { @@ -7378,14 +7371,14 @@ function vf(t) { "data-popper-escaped": f }); } -const yf = { +const vf = { name: "hide", enabled: !0, phase: "main", requiresIfExists: ["preventOverflow"], - fn: vf + fn: bf }; -function xf(t, e, n) { +function yf(t, e, n) { var r = Xt(t), o = [Ct, Tt].indexOf(r) >= 0 ? -1 : 1, a = typeof n == "function" ? n(Object.assign({}, e, { placement: t })) : n, i = a[0], l = a[1]; @@ -7397,20 +7390,20 @@ function xf(t, e, n) { y: l }; } -function Nf(t) { +function xf(t) { var e = t.state, n = t.options, r = t.name, o = n.offset, a = o === void 0 ? [0, 0] : o, i = hs.reduce(function(p, f) { - return p[f] = xf(f, e.rects, a), p; + return p[f] = yf(f, e.rects, a), p; }, {}), l = i[e.placement], c = l.x, d = l.y; e.modifiersData.popperOffsets != null && (e.modifiersData.popperOffsets.x += c, e.modifiersData.popperOffsets.y += d), e.modifiersData[r] = i; } -const kf = { +const Nf = { name: "offset", enabled: !0, phase: "main", requires: ["popperOffsets"], - fn: Nf + fn: xf }; -function Ef(t) { +function kf(t) { var e = t.state, n = t.name; e.modifiersData[n] = ks({ reference: e.rects.reference, @@ -7419,23 +7412,23 @@ function Ef(t) { placement: e.placement }); } -const Sf = { +const Ef = { name: "popperOffsets", enabled: !0, phase: "read", - fn: Ef, + fn: kf, data: {} }; -function Tf(t) { +function Sf(t) { return t === "x" ? "y" : "x"; } -function Cf(t) { +function Tf(t) { var e = t.state, n = t.options, r = t.name, o = n.mainAxis, a = o === void 0 ? !0 : o, i = n.altAxis, l = i === void 0 ? !1 : i, c = n.boundary, d = n.rootBoundary, p = n.altBoundary, f = n.padding, w = n.tether, g = w === void 0 ? !0 : w, v = n.tetherOffset, m = v === void 0 ? 0 : v, h = Nn(e, { boundary: c, rootBoundary: d, padding: f, altBoundary: p - }), T = Xt(e.placement), A = Ge(e.placement), R = !A, E = Ao(T), b = Tf(E), $ = e.modifiersData.popperOffsets, z = e.rects.reference, H = e.rects.popper, C = typeof m == "function" ? m(Object.assign({}, e.rects, { + }), S = Xt(e.placement), A = Ge(e.placement), R = !A, E = Ao(S), b = Sf(E), $ = e.modifiersData.popperOffsets, z = e.rects.reference, H = e.rects.popper, C = typeof m == "function" ? m(Object.assign({}, e.rects, { placement: e.placement })) : m, P = typeof C == "number" ? { mainAxis: C, @@ -7443,48 +7436,48 @@ function Cf(t) { } : Object.assign({ mainAxis: 0, altAxis: 0 - }, C), k = e.modifiersData.offset ? e.modifiersData.offset[e.placement] : null, B = { + }, C), k = e.modifiersData.offset ? e.modifiersData.offset[e.placement] : null, j = { x: 0, y: 0 }; if ($) { if (a) { - var M, J = E === "y" ? Tt : Ct, q = E === "y" ? jt : Vt, U = E === "y" ? "height" : "width", tt = $[E], at = tt + h[J], rt = tt - h[q], y = g ? -H[U] / 2 : 0, O = A === Le ? z[U] : H[U], L = A === Le ? -H[U] : -z[U], F = e.elements.arrow, V = g && F ? Io(F) : { + var M, J = E === "y" ? Tt : Ct, q = E === "y" ? Bt : Vt, U = E === "y" ? "height" : "width", tt = $[E], at = tt + h[J], rt = tt - h[q], y = g ? -H[U] / 2 : 0, O = A === Le ? z[U] : H[U], L = A === Le ? -H[U] : -z[U], F = e.elements.arrow, V = g && F ? Io(F) : { width: 0, height: 0 - }, W = e.modifiersData["arrow#persistent"] ? e.modifiersData["arrow#persistent"].padding : vs(), X = W[J], Y = W[q], G = un(0, z[U], V[U]), K = R ? z[U] / 2 - y - G - X - P.mainAxis : O - G - X - P.mainAxis, Z = R ? -z[U] / 2 + y + G + Y + P.mainAxis : L + G + Y + P.mainAxis, dt = e.elements.arrow && Pn(e.elements.arrow), I = dt ? E === "y" ? dt.clientTop || 0 : dt.clientLeft || 0 : 0, xt = (M = k == null ? void 0 : k[E]) != null ? M : 0, j = tt + K - xt - I, yt = tt + Z - xt, Lt = un(g ? Jn(at, j) : at, tt, g ? ve(rt, yt) : rt); - $[E] = Lt, B[E] = Lt - tt; + }, W = e.modifiersData["arrow#persistent"] ? e.modifiersData["arrow#persistent"].padding : vs(), X = W[J], Y = W[q], G = un(0, z[U], V[U]), K = R ? z[U] / 2 - y - G - X - P.mainAxis : O - G - X - P.mainAxis, Z = R ? -z[U] / 2 + y + G + Y + P.mainAxis : L + G + Y + P.mainAxis, dt = e.elements.arrow && Pn(e.elements.arrow), I = dt ? E === "y" ? dt.clientTop || 0 : dt.clientLeft || 0 : 0, xt = (M = k == null ? void 0 : k[E]) != null ? M : 0, B = tt + K - xt - I, yt = tt + Z - xt, Lt = un(g ? Jn(at, B) : at, tt, g ? ve(rt, yt) : rt); + $[E] = Lt, j[E] = Lt - tt; } if (l) { - var ce, Et = E === "x" ? Tt : Ct, In = E === "x" ? jt : Vt, Ft = $[b], Ee = b === "y" ? "height" : "width", de = Ft + h[Et], Se = Ft - h[In], Te = [Tt, Ct].indexOf(T) !== -1, Ce = (ce = k == null ? void 0 : k[b]) != null ? ce : 0, pe = Te ? de : Ft - z[Ee] - H[Ee] - Ce + P.altAxis, We = Te ? Ft + z[Ee] + H[Ee] - Ce - P.altAxis : Se, An = g && Te ? Kw(pe, Ft, We) : un(g ? pe : de, Ft, g ? We : Se); - $[b] = An, B[b] = An - Ft; + var ce, Et = E === "x" ? Tt : Ct, In = E === "x" ? Bt : Vt, Ft = $[b], Ee = b === "y" ? "height" : "width", de = Ft + h[Et], Se = Ft - h[In], Te = [Tt, Ct].indexOf(S) !== -1, Ce = (ce = k == null ? void 0 : k[b]) != null ? ce : 0, pe = Te ? de : Ft - z[Ee] - H[Ee] - Ce + P.altAxis, We = Te ? Ft + z[Ee] + H[Ee] - Ce - P.altAxis : Se, An = g && Te ? qw(pe, Ft, We) : un(g ? pe : de, Ft, g ? We : Se); + $[b] = An, j[b] = An - Ft; } - e.modifiersData[r] = B; + e.modifiersData[r] = j; } } -const Of = { +const Cf = { name: "preventOverflow", enabled: !0, phase: "main", - fn: Cf, + fn: Tf, requiresIfExists: ["offset"] }; -function Rf(t) { +function Of(t) { return { scrollLeft: t.scrollLeft, scrollTop: t.scrollTop }; } -function _f(t) { - return t === At(t) || !Bt(t) ? Mo(t) : Rf(t); +function Rf(t) { + return t === At(t) || !jt(t) ? Mo(t) : Of(t); } -function Pf(t) { +function _f(t) { var e = t.getBoundingClientRect(), n = Fe(e.width) / t.offsetWidth || 1, r = Fe(e.height) / t.offsetHeight || 1; return n !== 1 || r !== 1; } -function $f(t, e, n) { +function Pf(t, e, n) { n === void 0 && (n = !1); - var r = Bt(e), o = Bt(e) && Pf(e), a = le(e), i = Ue(t, o, n), l = { + var r = jt(e), o = jt(e) && _f(e), a = le(e), i = Ue(t, o, n), l = { scrollLeft: 0, scrollTop: 0 }, c = { @@ -7492,14 +7485,14 @@ function $f(t, e, n) { y: 0 }; return (r || !r && !n) && ((qt(e) !== "body" || // https://github.com/popperjs/popper-core/issues/1078 - Bo(a)) && (l = _f(e)), Bt(e) ? (c = Ue(e, !0), c.x += e.clientLeft, c.y += e.clientTop) : a && (c.x = Do(a))), { + jo(a)) && (l = Rf(e)), jt(e) ? (c = Ue(e, !0), c.x += e.clientLeft, c.y += e.clientTop) : a && (c.x = Do(a))), { x: i.left + l.scrollLeft - c.x, y: i.top + l.scrollTop - c.y, width: i.width, height: i.height }; } -function If(t) { +function $f(t) { var e = /* @__PURE__ */ new Map(), n = /* @__PURE__ */ new Set(), r = []; t.forEach(function(a) { e.set(a.name, a); @@ -7518,15 +7511,15 @@ function If(t) { n.has(a.name) || o(a); }), r; } -function Af(t) { - var e = If(t); - return Gw.reduce(function(n, r) { +function If(t) { + var e = $f(t); + return Uw.reduce(function(n, r) { return n.concat(e.filter(function(o) { return o.phase === r; })); }, []); } -function Mf(t) { +function Af(t) { var e; return function() { return e || (e = new Promise(function(n) { @@ -7536,7 +7529,7 @@ function Mf(t) { })), e; }; } -function Df(t) { +function Mf(t) { var e = t.reduce(function(n, r) { var o = n[r.name]; return n[r.name] = o ? Object.assign({}, o, r, { @@ -7560,7 +7553,7 @@ function Ga() { return !(r && typeof r.getBoundingClientRect == "function"); }); } -function Bf(t) { +function Df(t) { t === void 0 && (t = {}); var e = t, n = e.defaultModifiers, r = n === void 0 ? [] : n, o = e.defaultOptions, a = o === void 0 ? Ua : o; return function(l, c, d) { @@ -7578,13 +7571,13 @@ function Bf(t) { styles: {} }, f = [], w = !1, g = { state: p, - setOptions: function(T) { - var A = typeof T == "function" ? T(p.options) : T; + setOptions: function(S) { + var A = typeof S == "function" ? S(p.options) : S; m(), p.options = Object.assign({}, a, p.options, A), p.scrollParents = { reference: ke(l) ? wn(l) : l.contextElement ? wn(l.contextElement) : [], popper: wn(c) }; - var R = Af(Df([].concat(r, p.options.modifiers))); + var R = If(Mf([].concat(r, p.options.modifiers))); return p.orderedModifiers = R.filter(function(E) { return E.enabled; }), v(), g.update(); @@ -7596,10 +7589,10 @@ function Bf(t) { // prefer the async Popper#update method forceUpdate: function() { if (!w) { - var T = p.elements, A = T.reference, R = T.popper; + var S = p.elements, A = S.reference, R = S.popper; if (Ga(A, R)) { p.rects = { - reference: $f(A, Pn(R), p.options.strategy === "fixed"), + reference: Pf(A, Pn(R), p.options.strategy === "fixed"), popper: Io(R) }, p.reset = !1, p.placement = p.options.placement, p.orderedModifiers.forEach(function(P) { return p.modifiersData[P.name] = Object.assign({}, P.data); @@ -7622,7 +7615,7 @@ function Bf(t) { }, // Async and optimistically optimized update – it will not be executed if // not necessary (debounced to run at most once-per-tick) - update: Mf(function() { + update: Af(function() { return new Promise(function(h) { g.forceUpdate(), h(p); }); @@ -7638,11 +7631,11 @@ function Bf(t) { }); function v() { p.orderedModifiers.forEach(function(h) { - var T = h.name, A = h.options, R = A === void 0 ? {} : A, E = h.effect; + var S = h.name, A = h.options, R = A === void 0 ? {} : A, E = h.effect; if (typeof E == "function") { var b = E({ state: p, - name: T, + name: S, instance: g, options: R }), $ = function() { @@ -7659,16 +7652,16 @@ function Bf(t) { return g; }; } -var jf = [sf, Sf, of, Yw, kf, bf, Of, tf, yf], Vf = /* @__PURE__ */ Bf({ +var jf = [af, Ef, rf, Xw, Nf, gf, Cf, Qw, vf], Bf = /* @__PURE__ */ Df({ defaultModifiers: jf }); const Es = "Popper"; -function zf(t) { +function Vf(t) { return fs(Es, t); } -Pw(Es, ["root"]); -const Lf = ["anchorEl", "children", "direction", "disablePortal", "modifiers", "open", "placement", "popperOptions", "popperRef", "slotProps", "slots", "TransitionProps", "ownerState"], Ff = ["anchorEl", "children", "container", "direction", "disablePortal", "keepMounted", "modifiers", "open", "placement", "popperOptions", "popperRef", "style", "transition", "slotProps", "slots"]; -function Uf(t, e) { +_w(Es, ["root"]); +const zf = ["anchorEl", "children", "direction", "disablePortal", "modifiers", "open", "placement", "popperOptions", "popperRef", "slotProps", "slots", "TransitionProps", "ownerState"], Lf = ["anchorEl", "children", "container", "direction", "disablePortal", "keepMounted", "modifiers", "open", "placement", "popperOptions", "popperRef", "style", "transition", "slotProps", "slots"]; +function Ff(t, e) { if (e === "ltr") return t; switch (t) { @@ -7690,12 +7683,12 @@ function Zn(t) { function Nr(t) { return t.nodeType !== void 0; } -function Gf(t) { +function Uf(t) { return !Nr(t); } -const Hf = () => yo({ +const Gf = () => yo({ root: ["root"] -}, kw(zf)), Xf = {}, Yf = /* @__PURE__ */ D.forwardRef(function(e, n) { +}, Nw(Vf)), Hf = {}, Xf = /* @__PURE__ */ D.forwardRef(function(e, n) { var r; const { anchorEl: o, @@ -7712,11 +7705,11 @@ const Hf = () => yo({ TransitionProps: m // @ts-ignore internal logic // prevent from spreading to DOM, it can come from the parent component e.g. Select. - } = e, h = Nt(e, Lf), T = D.useRef(null), A = xe(T, n), R = D.useRef(null), E = xe(R, w), b = D.useRef(E); + } = e, h = Nt(e, zf), S = D.useRef(null), A = xe(S, n), R = D.useRef(null), E = xe(R, w), b = D.useRef(E); ze(() => { b.current = E; }, [E]), D.useImperativeHandle(w, () => R.current, []); - const $ = Uf(p, i), [z, H] = D.useState($), [C, P] = D.useState(Zn(o)); + const $ = Ff(p, i), [z, H] = D.useState($), [C, P] = D.useState(Zn(o)); D.useEffect(() => { R.current && R.current.forceUpdate(); }), D.useEffect(() => { @@ -7753,7 +7746,7 @@ const Hf = () => yo({ } }]; c != null && (U = U.concat(c)), f && f.modifiers != null && (U = U.concat(f.modifiers)); - const tt = Vf(C, T.current, _({ + const tt = Bf(C, S.current, _({ placement: $ }, f, { modifiers: U @@ -7766,7 +7759,7 @@ const Hf = () => yo({ placement: z }; m !== null && (k.TransitionProps = m); - const B = Hf(), M = (r = v.root) != null ? r : "div", J = Ow({ + const j = Gf(), M = (r = v.root) != null ? r : "div", J = Cw({ elementType: M, externalSlotProps: g.root, externalForwardedProps: h, @@ -7775,7 +7768,7 @@ const Hf = () => yo({ ref: A }, ownerState: e, - className: B.root + className: j.root }); return /* @__PURE__ */ s(M, _({}, J, { children: typeof a == "function" ? a(k) : a @@ -7791,13 +7784,13 @@ const Hf = () => yo({ modifiers: d, open: p, placement: f = "bottom", - popperOptions: w = Xf, + popperOptions: w = Hf, popperRef: g, style: v, transition: m = !1, slotProps: h = {}, - slots: T = {} - } = e, A = Nt(e, Ff), [R, E] = D.useState(!0), b = () => { + slots: S = {} + } = e, A = Nt(e, Lf), [R, E] = D.useState(!0), b = () => { E(!1); }, $ = () => { E(!0); @@ -7819,7 +7812,7 @@ const Hf = () => yo({ return /* @__PURE__ */ s(Kn, { disablePortal: l, container: z, - children: /* @__PURE__ */ s(Yf, _({ + children: /* @__PURE__ */ s(Xf, _({ anchorEl: r, direction: i, disablePortal: l, @@ -7830,7 +7823,7 @@ const Hf = () => yo({ popperOptions: w, popperRef: g, slotProps: h, - slots: T + slots: S }, A, { style: _({ // Prevents scroll issue, waiting for Popper.js to add this style once initiated. @@ -7864,7 +7857,7 @@ process.env.NODE_ENV !== "production" && (Ss.propTypes = { if (process.env.NODE_ENV !== "test" && n.top === 0 && n.left === 0 && n.right === 0 && n.bottom === 0) return new Error(["MUI: The `anchorEl` prop provided to the component is invalid.", "The anchor element should be part of the document layout.", "Make sure the element is present in the document or that it's not display none."].join(` `)); - } else if (!e || typeof e.getBoundingClientRect != "function" || Gf(e) && e.contextElement != null && e.contextElement.nodeType !== 1) + } else if (!e || typeof e.getBoundingClientRect != "function" || Uf(e) && e.contextElement != null && e.contextElement.nodeType !== 1) return new Error(["MUI: The `anchorEl` prop provided to the component is invalid.", "It should be an HTML element instance or a virtualElement ", "(https://popper.js.org/docs/v2/virtual-elements/)."].join(` `)); } @@ -7975,13 +7968,13 @@ function oo(t, e) { return r.__proto__ = o, r; }, oo(t, e); } -function Wf(t, e) { +function Yf(t, e) { t.prototype = Object.create(e.prototype), t.prototype.constructor = t, oo(t, e); } const Ha = { disabled: !1 }; -var qf = process.env.NODE_ENV !== "production" ? u.oneOfType([u.number, u.shape({ +var Wf = process.env.NODE_ENV !== "production" ? u.oneOfType([u.number, u.shape({ enter: u.number, exit: u.number, appear: u.number @@ -7998,11 +7991,11 @@ process.env.NODE_ENV !== "production" && u.oneOfType([u.string, u.shape({ exitDone: u.string, exitActive: u.string })]); -const Cs = S.createContext(null); -var Kf = function(e) { +const Cs = T.createContext(null); +var qf = function(e) { return e.scrollTop; }, ln = "unmounted", fe = "exited", me = "entering", Ae = "entered", ao = "exiting", ee = /* @__PURE__ */ function(t) { - Wf(e, t); + Yf(e, t); function e(r, o) { var a; a = t.call(this, r, o) || this; @@ -8040,8 +8033,8 @@ var Kf = function(e) { if (o === void 0 && (o = !1), a !== null) if (this.cancelNextCallback(), a === me) { if (this.props.unmountOnExit || this.props.mountOnEnter) { - var i = this.props.nodeRef ? this.props.nodeRef.current : Bn.findDOMNode(this); - i && Kf(i); + var i = this.props.nodeRef ? this.props.nodeRef.current : jn.findDOMNode(this); + i && qf(i); } this.performEnter(o); } else @@ -8051,7 +8044,7 @@ var Kf = function(e) { status: ln }); }, n.performEnter = function(o) { - var a = this, i = this.props.enter, l = this.context ? this.context.isMounting : o, c = this.props.nodeRef ? [l] : [Bn.findDOMNode(this), l], d = c[0], p = c[1], f = this.getTimeouts(), w = l ? f.appear : f.enter; + var a = this, i = this.props.enter, l = this.context ? this.context.isMounting : o, c = this.props.nodeRef ? [l] : [jn.findDOMNode(this), l], d = c[0], p = c[1], f = this.getTimeouts(), w = l ? f.appear : f.enter; if (!o && !i || Ha.disabled) { this.safeSetState({ status: Ae @@ -8072,7 +8065,7 @@ var Kf = function(e) { }); }); }, n.performExit = function() { - var o = this, a = this.props.exit, i = this.getTimeouts(), l = this.props.nodeRef ? void 0 : Bn.findDOMNode(this); + var o = this, a = this.props.exit, i = this.getTimeouts(), l = this.props.nodeRef ? void 0 : jn.findDOMNode(this); if (!a || Ha.disabled) { this.safeSetState({ status: fe @@ -8105,7 +8098,7 @@ var Kf = function(e) { }, this.nextCallback; }, n.onTransitionEnd = function(o, a) { this.setNextCallback(a); - var i = this.props.nodeRef ? this.props.nodeRef.current : Bn.findDOMNode(this), l = o == null && !this.props.addEndListener; + var i = this.props.nodeRef ? this.props.nodeRef.current : jn.findDOMNode(this), l = o == null && !this.props.addEndListener; if (!i || l) { setTimeout(this.nextCallback, 0); return; @@ -8124,12 +8117,12 @@ var Kf = function(e) { var l = Nt(a, ["children", "in", "mountOnEnter", "unmountOnExit", "appear", "enter", "exit", "timeout", "addEndListener", "onEnter", "onEntering", "onEntered", "onExit", "onExiting", "onExited", "nodeRef"]); return ( // allows for nested Transitions - /* @__PURE__ */ S.createElement(Cs.Provider, { + /* @__PURE__ */ T.createElement(Cs.Provider, { value: null - }, typeof i == "function" ? i(o, l) : S.cloneElement(S.Children.only(i), l)) + }, typeof i == "function" ? i(o, l) : T.cloneElement(T.Children.only(i), l)) ); }, e; -}(S.Component); +}(T.Component); ee.contextType = Cs; ee.propTypes = process.env.NODE_ENV !== "production" ? { /** @@ -8227,7 +8220,7 @@ ee.propTypes = process.env.NODE_ENV !== "production" ? { * @type {number | { enter?: number, exit?: number, appear?: number }} */ timeout: function(e) { - var n = qf; + var n = Wf; e.addEndListener || (n = n.isRequired); for (var r = arguments.length, o = new Array(r > 1 ? r - 1 : 0), a = 1; a < r; a++) o[a - 1] = arguments[a]; @@ -8321,7 +8314,7 @@ ee.EXITED = fe; ee.ENTERING = me; ee.ENTERED = Ae; ee.EXITING = ao; -const Jf = ee, Zf = (t) => t.scrollTop; +const Kf = ee, Jf = (t) => t.scrollTop; function Xa(t, e) { var n, r; const { @@ -8335,11 +8328,11 @@ function Xa(t, e) { delay: i.transitionDelay }; } -const Qf = ["addEndListener", "appear", "children", "easing", "in", "onEnter", "onEntered", "onEntering", "onExit", "onExited", "onExiting", "style", "timeout", "TransitionComponent"]; +const Zf = ["addEndListener", "appear", "children", "easing", "in", "onEnter", "onEntered", "onEntering", "onExit", "onExited", "onExiting", "style", "timeout", "TransitionComponent"]; function io(t) { return `scale(${t}, ${t ** 2})`; } -const tm = { +const Qf = { entering: { opacity: 1, transform: io(1) @@ -8348,7 +8341,7 @@ const tm = { opacity: 1, transform: "none" } -}, Fr = typeof navigator < "u" && /^((?!chrome|android).)*(safari|mobile)/i.test(navigator.userAgent) && /(os |version\/)15(.|_)4/i.test(navigator.userAgent), jo = /* @__PURE__ */ D.forwardRef(function(e, n) { +}, Fr = typeof navigator < "u" && /^((?!chrome|android).)*(safari|mobile)/i.test(navigator.userAgent) && /(os |version\/)15(.|_)4/i.test(navigator.userAgent), Bo = /* @__PURE__ */ D.forwardRef(function(e, n) { const { addEndListener: r, appear: o = !0, @@ -8364,14 +8357,14 @@ const tm = { style: v, timeout: m = "auto", // eslint-disable-next-line react/prop-types - TransitionComponent: h = Jf - } = e, T = Nt(e, Qf), A = an(), R = D.useRef(), E = Ts(), b = D.useRef(null), $ = xe(b, a.ref, n), z = (q) => (U) => { + TransitionComponent: h = Kf + } = e, S = Nt(e, Zf), A = an(), R = D.useRef(), E = Ts(), b = D.useRef(null), $ = xe(b, a.ref, n), z = (q) => (U) => { if (q) { const tt = b.current; U === void 0 ? q(tt) : q(tt, U); } }, H = z(p), C = z((q, U) => { - Zf(q); + Jf(q); const { duration: tt, delay: at, @@ -8392,7 +8385,7 @@ const tm = { delay: at, easing: rt })].join(","), c && c(q, U); - }), P = z(d), k = z(g), B = z((q) => { + }), P = z(d), k = z(g), j = z((q) => { const { duration: U, delay: tt, @@ -8421,25 +8414,25 @@ const tm = { onEnter: C, onEntered: P, onEntering: H, - onExit: B, + onExit: j, onExited: M, onExiting: k, addEndListener: (q) => { m === "auto" && A.start(R.current || 0, q), r && r(b.current, q); }, timeout: m === "auto" ? null : m - }, T, { + }, S, { children: (q, U) => /* @__PURE__ */ D.cloneElement(a, _({ style: _({ opacity: 0, transform: io(0.75), visibility: q === "exited" && !l ? "hidden" : void 0 - }, tm[q], v, a.props.style), + }, Qf[q], v, a.props.style), ref: $ }, U)) })); }); -process.env.NODE_ENV !== "production" && (jo.propTypes = { +process.env.NODE_ENV !== "production" && (Bo.propTypes = { // ┌────────────────────────────── Warning ──────────────────────────────┐ // │ These PropTypes are generated from the TypeScript type definitions. │ // │ To update them, edit the d.ts file and run `pnpm proptypes`. │ @@ -8513,8 +8506,8 @@ process.env.NODE_ENV !== "production" && (jo.propTypes = { exit: u.number })]) }); -jo.muiSupportAuto = !0; -const Ya = jo, em = ["anchorEl", "component", "components", "componentsProps", "container", "disablePortal", "keepMounted", "modifiers", "open", "placement", "popperOptions", "popperRef", "transition", "slots", "slotProps"], nm = Rn(Ss, { +Bo.muiSupportAuto = !0; +const Ya = Bo, tm = ["anchorEl", "component", "components", "componentsProps", "container", "disablePortal", "keepMounted", "modifiers", "open", "placement", "popperOptions", "popperRef", "transition", "slots", "slotProps"], em = Rn(Ss, { name: "MuiPopper", slot: "Root", overridesResolver: (t, e) => e.root @@ -8535,11 +8528,11 @@ const Ya = jo, em = ["anchorEl", "component", "components", "componentsProps", " open: v, placement: m, popperOptions: h, - popperRef: T, + popperRef: S, transition: A, slots: R, slotProps: E - } = a, b = Nt(a, em), $ = (r = R == null ? void 0 : R.root) != null ? r : c == null ? void 0 : c.Root, z = _({ + } = a, b = Nt(a, tm), $ = (r = R == null ? void 0 : R.root) != null ? r : c == null ? void 0 : c.Root, z = _({ anchorEl: i, container: p, disablePortal: f, @@ -8548,10 +8541,10 @@ const Ya = jo, em = ["anchorEl", "component", "components", "componentsProps", " open: v, placement: m, popperOptions: h, - popperRef: T, + popperRef: S, transition: A }, b); - return /* @__PURE__ */ s(nm, _({ + return /* @__PURE__ */ s(em, _({ as: l, direction: o == null ? void 0 : o.direction, slots: { @@ -8690,14 +8683,14 @@ process.env.NODE_ENV !== "production" && (Os.propTypes = { transition: u.bool }); const Rs = Os; -function rm(t) { +function nm(t) { return pr("MuiTooltip", t); } -const om = os("MuiTooltip", ["popper", "popperInteractive", "popperArrow", "popperClose", "tooltip", "tooltipArrow", "touch", "tooltipPlacementLeft", "tooltipPlacementRight", "tooltipPlacementTop", "tooltipPlacementBottom", "arrow"]), re = om, am = ["arrow", "children", "classes", "components", "componentsProps", "describeChild", "disableFocusListener", "disableHoverListener", "disableInteractive", "disableTouchListener", "enterDelay", "enterNextDelay", "enterTouchDelay", "followCursor", "id", "leaveDelay", "leaveTouchDelay", "onClose", "onOpen", "open", "placement", "PopperComponent", "PopperProps", "slotProps", "slots", "title", "TransitionComponent", "TransitionProps"]; -function im(t) { +const rm = os("MuiTooltip", ["popper", "popperInteractive", "popperArrow", "popperClose", "tooltip", "tooltipArrow", "touch", "tooltipPlacementLeft", "tooltipPlacementRight", "tooltipPlacementTop", "tooltipPlacementBottom", "arrow"]), re = rm, om = ["arrow", "children", "classes", "components", "componentsProps", "describeChild", "disableFocusListener", "disableHoverListener", "disableInteractive", "disableTouchListener", "enterDelay", "enterNextDelay", "enterTouchDelay", "followCursor", "id", "leaveDelay", "leaveTouchDelay", "onClose", "onOpen", "open", "placement", "PopperComponent", "PopperProps", "slotProps", "slots", "title", "TransitionComponent", "TransitionProps"]; +function am(t) { return Math.round(t * 1e5) / 1e5; } -const sm = (t) => { +const im = (t) => { const { classes: e, disableInteractive: n, @@ -8709,8 +8702,8 @@ const sm = (t) => { tooltip: ["tooltip", r && "tooltipArrow", o && "touch", `tooltipPlacement${Wt(a.split("-")[0])}`], arrow: ["arrow"] }; - return yo(i, rm, e); -}, lm = Rn(Rs, { + return yo(i, nm, e); +}, sm = Rn(Rs, { name: "MuiTooltip", slot: "Popper", overridesResolver: (t, e) => { @@ -8771,7 +8764,7 @@ const sm = (t) => { transformOrigin: "0 0" } }) -})), cm = Rn("div", { +})), lm = Rn("div", { name: "MuiTooltip", slot: "Tooltip", overridesResolver: (t, e) => { @@ -8800,7 +8793,7 @@ const sm = (t) => { }, e.touch && { padding: "8px 16px", fontSize: t.typography.pxToRem(14), - lineHeight: `${im(16 / 14)}em`, + lineHeight: `${am(16 / 14)}em`, fontWeight: t.typography.fontWeightRegular }, { [`.${re.popper}[data-popper-placement*="left"] &`]: _({ @@ -8837,7 +8830,7 @@ const sm = (t) => { }, e.touch && { marginTop: "24px" }) -})), dm = Rn("span", { +})), cm = Rn("span", { name: "MuiTooltip", slot: "Arrow", overridesResolver: (t, e) => e.arrow @@ -8872,7 +8865,7 @@ function Fn(t, e) { }; } const _s = /* @__PURE__ */ D.forwardRef(function(e, n) { - var r, o, a, i, l, c, d, p, f, w, g, v, m, h, T, A, R, E, b; + var r, o, a, i, l, c, d, p, f, w, g, v, m, h, S, A, R, E, b; const $ = Ro({ props: e, name: "MuiTooltip" @@ -8882,7 +8875,7 @@ const _s = /* @__PURE__ */ D.forwardRef(function(e, n) { components: C = {}, componentsProps: P = {}, describeChild: k = !1, - disableFocusListener: B = !1, + disableFocusListener: j = !1, disableHoverListener: M = !1, disableInteractive: J = !1, disableTouchListener: q = !1, @@ -8904,7 +8897,7 @@ const _s = /* @__PURE__ */ D.forwardRef(function(e, n) { title: dt, TransitionComponent: I = Ya, TransitionProps: xt - } = $, j = Nt($, am), yt = /* @__PURE__ */ D.isValidElement(H) ? H : /* @__PURE__ */ s("span", { + } = $, B = Nt($, om), yt = /* @__PURE__ */ D.isValidElement(H) ? H : /* @__PURE__ */ s("span", { children: H }), Lt = Ts(), ce = Lt.direction === "rtl", [Et, In] = D.useState(), [Ft, Ee] = D.useState(null), de = D.useRef(!1), Se = J || rt, Te = an(), Ce = an(), pe = an(), We = an(), [An, Vo] = Qi({ controlled: W, @@ -8960,11 +8953,11 @@ const _s = /* @__PURE__ */ D.forwardRef(function(e, n) { de.current = !0; const _t = yt.props; _t.onTouchStart && _t.onTouchStart(Q); - }, Yo = Er, Wo = Lo, Bs = (Q) => { + }, Yo = Er, Wo = Lo, js = (Q) => { Xo(Q), pe.clear(), Te.clear(), Mn(), qe.current = document.body.style.WebkitUserSelect, document.body.style.WebkitUserSelect = "none", We.start(at, () => { document.body.style.WebkitUserSelect = qe.current, Er(Q); }); - }, js = (Q) => { + }, Bs = (Q) => { yt.props.onTouchEnd && yt.props.onTouchEnd(Q), Mn(), pe.start(L, () => { Dn(Q); }); @@ -8989,8 +8982,8 @@ const _s = /* @__PURE__ */ D.forwardRef(function(e, n) { }, Sr.current && Sr.current.update(); }, Ke = {}, Tr = typeof dt == "string"; k ? (Ke.title = !Kt && Tr && !M ? dt : null, Ke["aria-describedby"] = Kt ? kr : null) : (Ke["aria-label"] = Tr ? dt : null, Ke["aria-labelledby"] = Kt && !Tr ? kr : null); - const Mt = _({}, Ke, j, yt.props, { - className: be(j.className, yt.props.className), + const Mt = _({}, Ke, B, yt.props, { + className: be(B.className, yt.props.className), onTouchStart: Xo, ref: Vs }, rt ? { @@ -9001,7 +8994,7 @@ const _s = /* @__PURE__ */ D.forwardRef(function(e, n) { `)); }, [Et])); const Je = {}; - q || (Mt.onTouchStart = Bs, Mt.onTouchEnd = js), M || (Mt.onMouseOver = Fn(Yo, Mt.onMouseOver), Mt.onMouseLeave = Fn(Wo, Mt.onMouseLeave), Se || (Je.onMouseOver = Yo, Je.onMouseLeave = Wo)), B || (Mt.onFocus = Fn(Ho, Mt.onFocus), Mt.onBlur = Fn(Go, Mt.onBlur), Se || (Je.onFocus = Ho, Je.onBlur = Go)), process.env.NODE_ENV !== "production" && yt.props.title && console.error(["MUI: You have provided a `title` prop to the child of .", `Remove this title prop \`${yt.props.title}\` or the Tooltip component.`].join(` + q || (Mt.onTouchStart = js, Mt.onTouchEnd = Bs), M || (Mt.onMouseOver = Fn(Yo, Mt.onMouseOver), Mt.onMouseLeave = Fn(Wo, Mt.onMouseLeave), Se || (Je.onMouseOver = Yo, Je.onMouseLeave = Wo)), j || (Mt.onFocus = Fn(Ho, Mt.onFocus), Mt.onBlur = Fn(Go, Mt.onBlur), Se || (Je.onFocus = Ho, Je.onBlur = Go)), process.env.NODE_ENV !== "production" && yt.props.title && console.error(["MUI: You have provided a `title` prop to the child of .", `Remove this title prop \`${yt.props.title}\` or the Tooltip component.`].join(` `)); const Ls = D.useMemo(() => { var Q; @@ -9023,10 +9016,10 @@ const _s = /* @__PURE__ */ D.forwardRef(function(e, n) { placement: X, PopperComponentProp: Y, touch: de.current - }), Cr = sm(Ze), qo = (r = (o = Z.popper) != null ? o : C.Popper) != null ? r : lm, Ko = (a = (i = (l = Z.transition) != null ? l : C.Transition) != null ? i : I) != null ? a : Ya, Jo = (c = (d = Z.tooltip) != null ? d : C.Tooltip) != null ? c : cm, Zo = (p = (f = Z.arrow) != null ? f : C.Arrow) != null ? p : dm, Fs = sn(qo, _({}, G, (w = K.popper) != null ? w : P.popper, { + }), Cr = im(Ze), qo = (r = (o = Z.popper) != null ? o : C.Popper) != null ? r : sm, Ko = (a = (i = (l = Z.transition) != null ? l : C.Transition) != null ? i : I) != null ? a : Ya, Jo = (c = (d = Z.tooltip) != null ? d : C.Tooltip) != null ? c : lm, Zo = (p = (f = Z.arrow) != null ? f : C.Arrow) != null ? p : cm, Fs = sn(qo, _({}, G, (w = K.popper) != null ? w : P.popper, { className: be(Cr.popper, G == null ? void 0 : G.className, (g = (v = K.popper) != null ? v : P.popper) == null ? void 0 : g.className) }), Ze), Us = sn(Ko, _({}, xt, (m = K.transition) != null ? m : P.transition), Ze), Gs = sn(Jo, _({}, (h = K.tooltip) != null ? h : P.tooltip, { - className: be(Cr.tooltip, (T = (A = K.tooltip) != null ? A : P.tooltip) == null ? void 0 : T.className) + className: be(Cr.tooltip, (S = (A = K.tooltip) != null ? A : P.tooltip) == null ? void 0 : S.className) }), Ze), Hs = sn(Zo, _({}, (R = K.arrow) != null ? R : P.arrow, { className: be(Cr.arrow, (E = (b = K.arrow) != null ? b : P.arrow) == null ? void 0 : E.className) }), Ze); @@ -9257,7 +9250,7 @@ process.env.NODE_ENV !== "production" && (_s.propTypes = { */ TransitionProps: u.object }); -const pm = _s; +const dm = _s; function qa(t, e, n) { return t ? /* @__PURE__ */ s(oi, { className: `papi-menu-icon-${n ? "leading" : "trailing"}`, children: /* @__PURE__ */ s("img", { src: t, alt: `${n ? "Leading" : "Trailing"} icon for ${e}` }) }) : void 0; } @@ -9279,7 +9272,7 @@ function Ps(t) { focusVisibleClassName: v, id: m, children: h - } = t, T = /* @__PURE__ */ s( + } = t, S = /* @__PURE__ */ s( Al, { sx: { lineHeight: 0.8 }, @@ -9299,12 +9292,12 @@ function Ps(t) { ] }) : h } ); - return r ? /* @__PURE__ */ s(pm, { title: r, placement: "right", children: /* @__PURE__ */ s("div", { children: T }) }) : T; + return r ? /* @__PURE__ */ s(dm, { title: r, placement: "right", children: /* @__PURE__ */ s("div", { children: S }) }) : S; } function $s(t) { return Object.entries(t.groups).map(([n, r]) => ({ id: n, group: r })); } -function um(t) { +function pm(t) { const [e, n] = ut(void 0), { parentMenuItem: r, parentItemProps: o, menuDefinition: a } = t, i = (d) => { n(d.currentTarget); }, l = () => { @@ -9339,7 +9332,7 @@ function um(t) { ) ] }); } -const wm = (t, e) => e.filter((o) => o.group === t).sort((o, a) => (o.order || 0) - (a.order || 0)); +const um = (t, e) => e.filter((o) => o.group === t).sort((o, a) => (o.order || 0) - (a.order || 0)); function Is(t) { const { menuDefinition: e, onClick: n, commandHandler: r, includedGroups: o } = t, { items: a, allowForLeadingIcons: i } = $t(() => { const p = o && o.length > 0 ? o : ( @@ -9350,7 +9343,7 @@ function Is(t) { (v, m) => (v.group.order || 0) - (m.group.order || 0) ), w = []; f.forEach((v) => { - wm(v.id, e.items).forEach( + um(v.id, e.items).forEach( (m) => w.push({ item: m, isLastItemInGroup: !1 }) ), w.length > 0 && (w[w.length - 1].isLastItemInGroup = !0); }), w.length > 0 && (w[w.length - 1].isLastItemInGroup = !1); @@ -9387,7 +9380,7 @@ function Is(t) { ); } return /* @__PURE__ */ s( - um, + pm, { parentMenuItem: w, parentItemProps: g, @@ -9397,7 +9390,7 @@ function Is(t) { ); }) }, d); } -function fm(t) { +function wm(t) { const { menuDefinition: e, columnId: n } = t; let a = Object.entries(e.groups).map(([i, l]) => ({ id: i, group: l })).filter((i) => "column" in i.group); return n && "columns" in e && // Without this type assertion, TS doesn't know what columns is. @@ -9406,7 +9399,7 @@ function fm(t) { (i) => "column" in i.group && i.group.column === n )), /* @__PURE__ */ s(Is, { ...t, includedGroups: a }); } -function mm({ +function fm({ commandHandler: t, menuDefinition: e, id: n, @@ -9425,8 +9418,8 @@ function mm({ className: `papi-menu-column ${a ?? ""}`, children: [ /* @__PURE__ */ s("h3", { "aria-label": r.label, className: `papi-menu-column-header ${a ?? ""}`, children: r.label }), - /* @__PURE__ */ s(Bl, { id: n, dense: !0, className: a ?? "", children: /* @__PURE__ */ s( - fm, + /* @__PURE__ */ s(jl, { id: n, dense: !0, className: a ?? "", children: /* @__PURE__ */ s( + wm, { commandHandler: t, menuDefinition: e, @@ -9438,7 +9431,7 @@ function mm({ } ); } -function hm({ +function mm({ commandHandler: t, className: e, multiColumnMenu: n, @@ -9466,7 +9459,7 @@ function hm({ "aria-label": "GridMenu", id: r, children: a.map((i, l) => /* @__PURE__ */ s( - mm, + fm, { commandHandler: t, menuDefinition: n, @@ -9478,7 +9471,7 @@ function hm({ } ); } -function gm(t) { +function hm(t) { return { preserveValue: !0, ...t @@ -9488,7 +9481,7 @@ const so = (t, e, n = {}) => { const r = ge(e); r.current = e; const o = ge(n); - o.current = gm(o.current); + o.current = hm(o.current); const [a, i] = ut(() => r.current), [l, c] = ut(!0); return ae(() => { let d = !0; @@ -9501,10 +9494,10 @@ const so = (t, e, n = {}) => { d = !1, o.current.preserveValue || i(() => r.current); }; }, [t]), [a, l]; -}, bm = ps(/* @__PURE__ */ s("path", { +}, gm = ps(/* @__PURE__ */ s("path", { d: "M3 18h18v-2H3zm0-5h18v-2H3zm0-7v2h18V6z" }), "Menu"); -function vm({ +function bm({ menuProvider: t, normalMenu: e, fullMenu: n, @@ -9534,13 +9527,13 @@ function vm({ } } }, [c, o]); - const [T] = so( + const [S] = so( kt(async () => (t == null ? void 0 : t(!1)) ?? e, [t, e, c]), e ), [A] = so( - kt(async () => (t == null ? void 0 : t(!0)) ?? n ?? T, [t, n, T, c]), - n ?? T - ), R = p && A ? A : T; + kt(async () => (t == null ? void 0 : t(!0)) ?? n ?? S, [t, n, S, c]), + n ?? S + ), R = p && A ? A : S; return /* @__PURE__ */ x(ie, { children: [ /* @__PURE__ */ s( ii, @@ -9554,11 +9547,11 @@ function vm({ color: "inherit", "aria-label": `${i ?? ""} menu button`, onClick: g, - children: l ?? /* @__PURE__ */ s(bm, {}) + children: l ?? /* @__PURE__ */ s(gm, {}) } ), /* @__PURE__ */ s( - jl, + Bl, { className: `papi-menu-drawer ${a ?? ""}`, anchor: "left", @@ -9573,7 +9566,7 @@ function vm({ } }, children: R ? /* @__PURE__ */ s( - hm, + mm, { className: a, id: `${i ?? ""} main menu`, @@ -9585,7 +9578,7 @@ function vm({ ) ] }); } -function xh({ +function yh({ id: t, label: e, isDisabled: n = !1, @@ -9614,7 +9607,7 @@ function xh({ } const $n = Qn(({ className: t, ...e }, n) => /* @__PURE__ */ s(fl, { size: 35, className: N("tw-animate-spin", t), ...e, ref: n })); $n.displayName = "Spinner"; -function Nh({ +function xh({ id: t, isDisabled: e = !1, hasError: n = !1, @@ -9660,7 +9653,7 @@ function Nh({ /* @__PURE__ */ s("p", { className: N({ "tw-hidden": !o }), children: o }) ] }); } -function kh({ +function Nh({ menuProvider: t, commandHandler: e, className: n, @@ -9675,7 +9668,7 @@ function kh({ variant: "dense", children: [ t ? /* @__PURE__ */ s( - vm, + bm, { commandHandler: e, containerRef: a, @@ -9687,7 +9680,7 @@ function kh({ } ) }) }); } -const ym = kn( +const vm = kn( "tw-relative tw-w-full tw-rounded-lg tw-border tw-p-4 [&>svg~*]:tw-pl-7 [&>svg+div]:tw-translate-y-[-3px] [&>svg]:tw-absolute [&>svg]:tw-left-4 [&>svg]:tw-top-4 [&>svg]:tw-text-foreground", { variants: { @@ -9700,9 +9693,9 @@ const ym = kn( variant: "default" } } -), xm = S.forwardRef(({ className: t, variant: e, ...n }, r) => /* @__PURE__ */ s("div", { ref: r, role: "alert", className: N(ym({ variant: e }), t), ...n })); -xm.displayName = "Alert"; -const Nm = S.forwardRef( +), ym = T.forwardRef(({ className: t, variant: e, ...n }, r) => /* @__PURE__ */ s("div", { ref: r, role: "alert", className: N(vm({ variant: e }), t), ...n })); +ym.displayName = "Alert"; +const xm = T.forwardRef( ({ className: t, ...e }, n) => /* @__PURE__ */ x( "h5", { @@ -9716,10 +9709,10 @@ const Nm = S.forwardRef( } ) ); -Nm.displayName = "AlertTitle"; -const km = S.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s("div", { ref: n, className: N("tw-text-sm [&_p]:tw-leading-relaxed", t), ...e })); -km.displayName = "AlertDescription"; -const Em = S.forwardRef( +xm.displayName = "AlertTitle"; +const Nm = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s("div", { ref: n, className: N("tw-text-sm [&_p]:tw-leading-relaxed", t), ...e })); +Nm.displayName = "AlertDescription"; +const km = T.forwardRef( ({ className: t, ...e }, n) => /* @__PURE__ */ s( "div", { @@ -9732,8 +9725,8 @@ const Em = S.forwardRef( } ) ); -Em.displayName = "Card"; -const Sm = S.forwardRef( +km.displayName = "Card"; +const Em = T.forwardRef( ({ className: t, ...e }, n) => /* @__PURE__ */ s( "div", { @@ -9743,8 +9736,8 @@ const Sm = S.forwardRef( } ) ); -Sm.displayName = "CardHeader"; -const Tm = S.forwardRef( +Em.displayName = "CardHeader"; +const Sm = T.forwardRef( ({ className: t, ...e }, n) => /* @__PURE__ */ s( "h3", { @@ -9758,14 +9751,14 @@ const Tm = S.forwardRef( } ) ); -Tm.displayName = "CardTitle"; -const Cm = S.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s("p", { ref: n, className: N("pr-twp tw-text-sm tw-text-muted-foreground", t), ...e })); -Cm.displayName = "CardDescription"; -const Om = S.forwardRef( +Sm.displayName = "CardTitle"; +const Tm = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s("p", { ref: n, className: N("pr-twp tw-text-sm tw-text-muted-foreground", t), ...e })); +Tm.displayName = "CardDescription"; +const Cm = T.forwardRef( ({ className: t, ...e }, n) => /* @__PURE__ */ s("div", { ref: n, className: N("pr-twp tw-p-6 tw-pt-0", t), ...e }) ); -Om.displayName = "CardContent"; -const Rm = S.forwardRef( +Cm.displayName = "CardContent"; +const Om = T.forwardRef( ({ className: t, ...e }, n) => /* @__PURE__ */ s( "div", { @@ -9775,8 +9768,8 @@ const Rm = S.forwardRef( } ) ); -Rm.displayName = "CardFooter"; -function Eh({ ...t }) { +Om.displayName = "CardFooter"; +function kh({ ...t }) { return /* @__PURE__ */ s( Fl, { @@ -9793,7 +9786,7 @@ function Eh({ ...t }) { } ); } -const _m = S.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ x( +const Rm = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ x( on.Root, { ref: n, @@ -9808,8 +9801,8 @@ const _m = S.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ x( ] } )); -_m.displayName = on.Root.displayName; -const Pm = S.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( +Rm.displayName = on.Root.displayName; +const _m = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( Xr.Root, { className: N( @@ -9828,8 +9821,8 @@ const Pm = S.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( ) } )); -Pm.displayName = Xr.Root.displayName; -const Sh = Rt.Root, $m = S.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( +_m.displayName = Xr.Root.displayName; +const Eh = Rt.Root, Pm = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( Rt.List, { ref: n, @@ -9840,8 +9833,8 @@ const Sh = Rt.Root, $m = S.forwardRef(({ className: t, ...e }, n) => /* @__PURE_ ...e } )); -$m.displayName = Rt.List.displayName; -const Im = S.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( +Pm.displayName = Rt.List.displayName; +const $m = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( Rt.Trigger, { ref: n, @@ -9852,8 +9845,8 @@ const Im = S.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( ...e } )); -Im.displayName = Rt.Trigger.displayName; -const Am = S.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( +$m.displayName = Rt.Trigger.displayName; +const Im = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( Rt.Content, { ref: n, @@ -9864,8 +9857,8 @@ const Am = S.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( ...e } )); -Am.displayName = Rt.Content.displayName; -function Th({ +Im.displayName = Rt.Content.displayName; +function Sh({ isInstalling: t, handleClick: e, buttonText: n, @@ -9894,7 +9887,7 @@ function Th({ } ); } -function Ch({ +function Th({ isEnabling: t, handleClick: e, className: n, @@ -9919,7 +9912,7 @@ function Ch({ } ); } -function Oh({ +function Ch({ isDisabling: t, handleClick: e, className: n, @@ -9944,7 +9937,7 @@ function Oh({ } ); } -function Rh({ +function Oh({ isUpdating: t, handleClick: e, className: n, @@ -9969,7 +9962,7 @@ function Rh({ } ); } -function _h({ +function Rh({ id: t, markdown: e, className: n, @@ -9989,7 +9982,7 @@ function _h({ ); return /* @__PURE__ */ s("div", { id: t, className: N("pr-twp tw-prose", n), children: /* @__PURE__ */ s(Ul, { options: o, children: e }) }); } -const Mm = Qn((t, e) => /* @__PURE__ */ x( +const Am = Qn((t, e) => /* @__PURE__ */ x( gt, { ref: e, @@ -10008,10 +10001,10 @@ const Mm = Qn((t, e) => /* @__PURE__ */ x( ] } )); -var Dm = /* @__PURE__ */ ((t) => (t[t.Check = 0] = "Check", t[t.Radio = 1] = "Radio", t))(Dm || {}); -function Ph({ id: t, groups: e }) { +var Mm = /* @__PURE__ */ ((t) => (t[t.Check = 0] = "Check", t[t.Radio = 1] = "Radio", t))(Mm || {}); +function _h({ id: t, groups: e }) { return /* @__PURE__ */ s("div", { id: t, children: /* @__PURE__ */ x(wo, { children: [ - /* @__PURE__ */ s(wi, { asChild: !0, children: /* @__PURE__ */ s(Mm, {}) }), + /* @__PURE__ */ s(wi, { asChild: !0, children: /* @__PURE__ */ s(Am, {}) }), /* @__PURE__ */ s(rr, { children: e.map((n) => /* @__PURE__ */ x("div", { children: [ /* @__PURE__ */ s(Sn, { children: n.label }), /* @__PURE__ */ s(oc, { children: n.items.map((r) => /* @__PURE__ */ s("div", { children: r.itemType === 0 ? /* @__PURE__ */ s(fo, { onClick: r.onClick, children: r.label }) : /* @__PURE__ */ s(mi, { onClick: r.onClick, value: r.label, children: r.label }) }, r.label)) }), @@ -10019,10 +10012,10 @@ function Ph({ id: t, groups: e }) { ] }, n.label)) }) ] }) }); } -function $h({ id: t, message: e }) { +function Ph({ id: t, message: e }) { return /* @__PURE__ */ s("div", { id: t, className: "tw-mb-20 tw-mt-20 tw-flex tw-items-center tw-justify-center", children: /* @__PURE__ */ s("div", { className: "tw-w-3/4 tw-rounded-lg tw-bg-gray-100 tw-p-8 tw-text-center", children: /* @__PURE__ */ s("p", { className: "tw-text-lg tw-text-gray-800", children: e }) }) }); } -function Ih({ +function $h({ id: t, category: e, downloads: n, @@ -10110,7 +10103,7 @@ function Ih({ } ); } -function Bm({ id: t, versionHistory: e }) { +function Dm({ id: t, versionHistory: e }) { const [n, r] = ut(!1), o = /* @__PURE__ */ new Date(); function a(l) { const c = new Date(l), d = new Date(o.getTime() - c.getTime()), p = d.getUTCFullYear() - 1970, f = d.getUTCMonth(), w = d.getUTCDate() - 1; @@ -10141,7 +10134,7 @@ function Bm({ id: t, versionHistory: e }) { ) ] }); } -function Ah({ +function Ih({ id: t, publisherDisplayName: e, fileSize: n, @@ -10153,7 +10146,7 @@ function Ah({ return c.map((p) => d.of(p)); })(r); return /* @__PURE__ */ s("div", { id: t, className: "tw-border-t tw-pb-4 tw-pt-4", children: /* @__PURE__ */ x("div", { className: "tw-md:flex-row tw-md:space-x-8 tw-flex tw-flex-col tw-space-x-0", children: [ - /* @__PURE__ */ s(Bm, { versionHistory: o }), + /* @__PURE__ */ s(Dm, { versionHistory: o }), /* @__PURE__ */ s("div", { className: "tw-md:border-t-0 tw-md:border-l tw-md-h-auto tw-md-ml-8 tw-mt-4 tw-border-t tw-border-gray-300" }), /* @__PURE__ */ x("div", { className: "tw-md:mt-0 tw-mt-4 tw-flex-1 tw-space-y-3", children: [ /* @__PURE__ */ s("h2", { className: "tw-text-md tw-font-semibold", children: "Information" }), @@ -10172,7 +10165,7 @@ function Ah({ ] }) ] }) }); } -const Mh = (t, e) => { +const Ah = (t, e) => { ae(() => { if (!t) return () => { @@ -10182,7 +10175,7 @@ const Mh = (t, e) => { n(); }; }, [t, e]); -}, Ur = () => !1, Dh = (t, e) => { +}, Ur = () => !1, Mh = (t, e) => { const [n] = so( kt(async () => { if (!t) @@ -13664,32 +13657,6 @@ video:where(.pr-twp,.pr-twp *) { .banded-row[data-state='selected']:hover { cursor: default; } -.papi-icon-button { - border: 0; - border-radius: 3em; - cursor: pointer; - display: inline-block; -} - -.papi-icon-button.primary { - background-color: #1ea7fd; - color: white; -} - -.papi-icon-button.secondary { - background-color: transparent; - color: #333; -} - -.papi-icon-button.paratext { - background-color: darkgreen; - color: greenyellow; -} - -.papi-icon-button.paratext.bright { - background-color: greenyellow; - color: darkgreen; -} .papi-multi-column-menu { background-color: rgb(222, 222, 222); display: flex; @@ -13724,6 +13691,32 @@ video:where(.pr-twp,.pr-twp *) { color: rgb(76, 106, 76); background-color: rgb(214, 255, 152); } +.papi-icon-button { + border: 0; + border-radius: 3em; + cursor: pointer; + display: inline-block; +} + +.papi-icon-button.primary { + background-color: #1ea7fd; + color: white; +} + +.papi-icon-button.secondary { + background-color: transparent; + color: #333; +} + +.papi-icon-button.paratext { + background-color: darkgreen; + color: greenyellow; +} + +.papi-icon-button.paratext.bright { + background-color: greenyellow; + color: darkgreen; +} .papi-menu-item { background-color: transparent; } @@ -13749,66 +13742,66 @@ video:where(.pr-twp,.pr-twp *) { } `, "top"); export { - xm as Alert, - km as AlertDescription, - Nm as AlertTitle, - ih as BOOK_SELECTOR_STRING_KEYS, - ah as BookChapterControl, + ym as Alert, + Nm as AlertDescription, + xm as AlertTitle, + ah as BOOK_SELECTOR_STRING_KEYS, + oh as BookChapterControl, _c as BookSelectionMode, - sh as BookSelector, + ih as BookSelector, gt as Button, - Em as Card, - Om as CardContent, - Cm as CardDescription, - Rm as CardFooter, - Sm as CardHeader, - Tm as CardTitle, + km as Card, + Cm as CardContent, + Tm as CardDescription, + Om as CardFooter, + Em as CardHeader, + Sm as CardTitle, Rc as ChapterRangeSelector, mo as Checkbox, - yh as Checklist, + vh as Checklist, Wr as ComboBox, - jc as DataTable, - Oh as DisableButton, + Bc as DataTable, + Ch as DisableButton, wo as DropdownMenu, fo as DropdownMenuCheckboxItem, rr as DropdownMenuContent, oc as DropdownMenuGroup, fi as DropdownMenuItem, - Dm as DropdownMenuItemType, + Mm as DropdownMenuItemType, Sn as DropdownMenuLabel, - nh as DropdownMenuPortal, - oh as DropdownMenuRadioGroup, + eh as DropdownMenuPortal, + rh as DropdownMenuRadioGroup, mi as DropdownMenuRadioItem, or as DropdownMenuSeparator, sc as DropdownMenuShortcut, - rh as DropdownMenuSub, + nh as DropdownMenuSub, ic as DropdownMenuSubContent, ac as DropdownMenuSubTrigger, wi as DropdownMenuTrigger, - Ch as EnableButton, - Mm as FilterButton, - Ph as FilterDropdown, - Ah as Footer, - hm as GridMenu, - vm as HamburgerMenuButton, - ph as INVENTORY_STRING_KEYS, - xh as IconButton, + Th as EnableButton, + Am as FilterButton, + _h as FilterDropdown, + Ih as Footer, + mm as GridMenu, + bm as HamburgerMenuButton, + dh as INVENTORY_STRING_KEYS, + yh as IconButton, Xe as Input, - Th as InstallButton, - uh as Inventory, + Sh as InstallButton, + ph as Inventory, Ht as Label, - _h as MarkdownRenderer, + Rh as MarkdownRenderer, Ps as MenuItem, - Ih as MoreInfo, - wh as NavigationContentSearch, - $h as NoExtensionsFound, + $h as MoreInfo, + uh as NavigationContentSearch, + Ph as NoExtensionsFound, hi as RadioGroup, Yr as RadioGroupItem, - mh as ScriptureResultsViewer, - hh as ScrollGroupSelector, + fh as ScriptureResultsViewer, + mh as ScrollGroupSelector, Ri as SearchBar, hn as Select, - Be as SelectContent, + je as SelectContent, $c as SelectGroup, Ut as SelectItem, Ic as SelectLabel, @@ -13818,33 +13811,33 @@ export { De as SelectTrigger, gn as SelectValue, ho as Separator, - gh as SettingsList, - vh as SettingsListHeader, - bh as SettingsListItem, - fd as SettingsSidebar, - fh as SettingsSidebarContentSearch, - _m as Slider, - Eh as Sonner, + hh as SettingsList, + bh as SettingsListHeader, + gh as SettingsListItem, + wd as SettingsSidebar, + wh as SettingsSidebarContentSearch, + Rm as Slider, + kh as Sonner, $n as Spinner, - Pm as Switch, + _m as Switch, ar as Table, sr as TableBody, - Bc as TableCaption, - je as TableCell, + jc as TableCaption, + Be as TableCell, Dc as TableFooter, bn as TableHead, ir as TableHeader, oe as TableRow, - Sh as Tabs, - Am as TabsContent, - $m as TabsList, - Im as TabsTrigger, - Nh as TextField, + Eh as Tabs, + Im as TabsContent, + Pm as TabsList, + $m as TabsTrigger, + xh as TextField, Oi as ToggleGroup, Un as ToggleGroupItem, - kh as Toolbar, - Rh as UpdateButton, - Bm as VersionHistory, + Nh as Toolbar, + Oh as UpdateButton, + Dm as VersionHistory, _i as VerticalTabs, $i as VerticalTabsContent, Pi as VerticalTabsList, @@ -13855,12 +13848,12 @@ export { zc as getLinesFromUSFM, ra as getNumberFromUSFM, Fc as getStatusForItem, - ch as inventoryCountColumn, - lh as inventoryItemColumn, - dh as inventoryStatusColumn, - Vh as sonner, - Mh as useEvent, - Dh as useEventAsync, + lh as inventoryCountColumn, + sh as inventoryItemColumn, + ch as inventoryStatusColumn, + Bh as sonner, + Ah as useEvent, + Mh as useEventAsync, so as usePromise }; //# sourceMappingURL=index.js.map diff --git a/lib/platform-bible-react/dist/index.js.map b/lib/platform-bible-react/dist/index.js.map index 086d4e58af..4ef8862605 100644 --- a/lib/platform-bible-react/dist/index.js.map +++ b/lib/platform-bible-react/dist/index.js.map @@ -1 +1 @@ -{"version":3,"file":"index.js","sources":["../src/utils/shadcn-ui.util.ts","../src/components/shadcn-ui/input.tsx","../src/components/advanced/book-chapter-control/book-chapter-input.component.tsx","../../../node_modules/@sillsdev/scripture/dist/index.es.js","../src/components/shadcn-ui/dropdown-menu.tsx","../src/components/advanced/book-chapter-control/book-menu-item.component.tsx","../src/components/advanced/book-chapter-control/chapter-select.component.tsx","../src/components/advanced/book-chapter-control/go-to-menu-item.component.tsx","../src/components/advanced/book-chapter-control/book-chapter-control.component.tsx","../src/components/shadcn-ui/button.tsx","../src/components/shadcn-ui/label.tsx","../src/components/shadcn-ui/radio-group.tsx","../src/components/shadcn-ui/popover.tsx","../src/components/shadcn-ui/dialog.tsx","../src/components/shadcn-ui/command.tsx","../src/components/basics/combo-box.component.tsx","../src/components/basics/chapter-range-selector.component.tsx","../src/components/advanced/book-selector.component.tsx","../src/components/advanced/data-table/data-table-column-toggle.component.tsx","../src/components/shadcn-ui/select.tsx","../src/components/advanced/data-table/data-table-pagination.component.tsx","../src/components/shadcn-ui/table.tsx","../src/components/advanced/data-table/data-table.component.tsx","../src/components/advanced/inventory/occurrences-table.component.tsx","../src/components/shadcn-ui/checkbox.tsx","../src/components/advanced/inventory/inventory-utils.ts","../src/components/shadcn-ui/toggle.tsx","../src/components/shadcn-ui/toggle-group.tsx","../src/components/advanced/inventory/inventory-columns.tsx","../src/components/advanced/inventory/inventory.component.tsx","../src/components/basics/search-bar.component.tsx","../src/components/basics/tabs-vertical.tsx","../src/components/advanced/tab-navigation-content-search.component.tsx","../src/components/shadcn-ui/separator.tsx","../src/components/shadcn-ui/skeleton.tsx","../src/components/shadcn-ui/tooltip.tsx","../src/components/shadcn-ui/sidebar.tsx","../src/components/advanced/settings-components/settings-sidebar.component.tsx","../src/components/advanced/settings-components/settings-sidebar-content-search.component.tsx","../src/components/advanced/scripture-results-viewer/scripture-results-viewer.component.tsx","../src/components/advanced/scroll-group-selector.component.tsx","../src/components/advanced/settings-components/settings-list.component.tsx","../src/components/basics/checklist.component.tsx","../../../node_modules/@babel/runtime/helpers/interopRequireDefault.js","../../../node_modules/@mui/utils/chainPropTypes/chainPropTypes.js","../../../node_modules/@babel/runtime/helpers/esm/extends.js","../../../node_modules/@mui/utils/deepmerge/deepmerge.js","../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.production.min.js","../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.development.js","../../../node_modules/prop-types/node_modules/react-is/index.js","../../../node_modules/object-assign/index.js","../../../node_modules/prop-types/lib/ReactPropTypesSecret.js","../../../node_modules/prop-types/lib/has.js","../../../node_modules/prop-types/checkPropTypes.js","../../../node_modules/prop-types/factoryWithTypeCheckers.js","../../../node_modules/prop-types/factoryWithThrowingShims.js","../../../node_modules/prop-types/index.js","../../../node_modules/@mui/utils/elementAcceptingRef/elementAcceptingRef.js","../../../node_modules/@mui/utils/exactProp/exactProp.js","../../../node_modules/@mui/utils/formatMuiErrorMessage/formatMuiErrorMessage.js","../../../node_modules/react-is/cjs/react-is.production.min.js","../../../node_modules/react-is/cjs/react-is.development.js","../../../node_modules/react-is/index.js","../../../node_modules/@mui/utils/getDisplayName/getDisplayName.js","../../../node_modules/@mui/utils/HTMLElementType/HTMLElementType.js","../../../node_modules/@mui/utils/refType/refType.js","../../../node_modules/@mui/utils/capitalize/capitalize.js","../../../node_modules/@mui/utils/createChainedFunction/createChainedFunction.js","../../../node_modules/@mui/utils/debounce/debounce.js","../../../node_modules/@mui/utils/deprecatedPropType/deprecatedPropType.js","../../../node_modules/@mui/utils/isMuiElement/isMuiElement.js","../../../node_modules/@mui/utils/ownerDocument/ownerDocument.js","../../../node_modules/@mui/utils/ownerWindow/ownerWindow.js","../../../node_modules/@mui/utils/requirePropFactory/requirePropFactory.js","../../../node_modules/@mui/utils/setRef/setRef.js","../../../node_modules/@mui/utils/useEnhancedEffect/useEnhancedEffect.js","../../../node_modules/@mui/utils/useId/useId.js","../../../node_modules/@mui/utils/unsupportedProp/unsupportedProp.js","../../../node_modules/@mui/utils/useControlled/useControlled.js","../../../node_modules/@mui/utils/useEventCallback/useEventCallback.js","../../../node_modules/@mui/utils/useForkRef/useForkRef.js","../../../node_modules/@mui/utils/useLazyRef/useLazyRef.js","../../../node_modules/@mui/utils/useOnMount/useOnMount.js","../../../node_modules/@mui/utils/useTimeout/useTimeout.js","../../../node_modules/@mui/utils/useIsFocusVisible/useIsFocusVisible.js","../../../node_modules/@mui/utils/resolveProps/resolveProps.js","../../../node_modules/@mui/utils/composeClasses/composeClasses.js","../../../node_modules/@mui/utils/ClassNameGenerator/ClassNameGenerator.js","../../../node_modules/@mui/utils/generateUtilityClass/generateUtilityClass.js","../../../node_modules/@mui/utils/generateUtilityClasses/generateUtilityClasses.js","../../../node_modules/@mui/utils/clamp/clamp.js","../../../node_modules/@babel/runtime/helpers/esm/objectWithoutPropertiesLoose.js","../../../node_modules/@mui/system/esm/createTheme/createBreakpoints.js","../../../node_modules/@mui/system/esm/createTheme/shape.js","../../../node_modules/@mui/system/esm/responsivePropType.js","../../../node_modules/@mui/system/esm/merge.js","../../../node_modules/@mui/system/esm/breakpoints.js","../../../node_modules/@mui/system/esm/style.js","../../../node_modules/@mui/system/esm/memoize.js","../../../node_modules/@mui/system/esm/spacing.js","../../../node_modules/@mui/system/esm/createTheme/createSpacing.js","../../../node_modules/@mui/system/esm/compose.js","../../../node_modules/@mui/system/esm/borders.js","../../../node_modules/@mui/system/esm/cssGrid.js","../../../node_modules/@mui/system/esm/palette.js","../../../node_modules/@mui/system/esm/sizing.js","../../../node_modules/@mui/system/esm/styleFunctionSx/defaultSxConfig.js","../../../node_modules/@mui/system/esm/styleFunctionSx/styleFunctionSx.js","../../../node_modules/@mui/system/esm/createTheme/applyStyles.js","../../../node_modules/@mui/system/esm/createTheme/createTheme.js","../../../node_modules/@mui/system/esm/useThemeWithoutDefault.js","../../../node_modules/@mui/system/esm/useTheme.js","../../../node_modules/@mui/system/esm/createStyled.js","../../../node_modules/@mui/system/esm/useThemeProps/getThemeProps.js","../../../node_modules/@mui/system/esm/useThemeProps/useThemeProps.js","../../../node_modules/@mui/system/esm/colorManipulator.js","../../../node_modules/@mui/material/styles/createMixins.js","../../../node_modules/@mui/material/colors/common.js","../../../node_modules/@mui/material/colors/grey.js","../../../node_modules/@mui/material/colors/purple.js","../../../node_modules/@mui/material/colors/red.js","../../../node_modules/@mui/material/colors/orange.js","../../../node_modules/@mui/material/colors/blue.js","../../../node_modules/@mui/material/colors/lightBlue.js","../../../node_modules/@mui/material/colors/green.js","../../../node_modules/@mui/material/styles/createPalette.js","../../../node_modules/@mui/material/styles/createTypography.js","../../../node_modules/@mui/material/styles/shadows.js","../../../node_modules/@mui/material/styles/createTransitions.js","../../../node_modules/@mui/material/styles/zIndex.js","../../../node_modules/@mui/material/styles/createTheme.js","../../../node_modules/@mui/material/styles/defaultTheme.js","../../../node_modules/@mui/material/styles/identifier.js","../../../node_modules/@mui/material/styles/useThemeProps.js","../../../node_modules/@mui/material/styles/styled.js","../../../node_modules/@mui/material/SvgIcon/svgIconClasses.js","../../../node_modules/@mui/material/SvgIcon/SvgIcon.js","../../../node_modules/@mui/material/utils/createSvgIcon.js","../../../node_modules/@mui/material/utils/index.js","../../../node_modules/@mui/icons-material/utils/createSvgIcon.js","../../../node_modules/@mui/icons-material/ArrowRight.js","../../../node_modules/@mui/base/utils/isHostComponent.js","../../../node_modules/@mui/base/utils/appendOwnerState.js","../../../node_modules/@mui/base/utils/ClassNameConfigurator.js","../../../node_modules/@mui/base/utils/extractEventHandlers.js","../../../node_modules/@mui/base/utils/resolveComponentProps.js","../../../node_modules/@mui/base/utils/omitEventHandlers.js","../../../node_modules/@mui/base/utils/mergeSlotProps.js","../../../node_modules/@mui/base/utils/useSlotProps.js","../../../node_modules/@mui/base/generateUtilityClass/index.js","../../../node_modules/@mui/base/generateUtilityClasses/index.js","../../../node_modules/@mui/base/Portal/Portal.js","../../../node_modules/@popperjs/core/lib/enums.js","../../../node_modules/@popperjs/core/lib/dom-utils/getNodeName.js","../../../node_modules/@popperjs/core/lib/dom-utils/getWindow.js","../../../node_modules/@popperjs/core/lib/dom-utils/instanceOf.js","../../../node_modules/@popperjs/core/lib/modifiers/applyStyles.js","../../../node_modules/@popperjs/core/lib/utils/getBasePlacement.js","../../../node_modules/@popperjs/core/lib/utils/math.js","../../../node_modules/@popperjs/core/lib/utils/userAgent.js","../../../node_modules/@popperjs/core/lib/dom-utils/isLayoutViewport.js","../../../node_modules/@popperjs/core/lib/dom-utils/getBoundingClientRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/getLayoutRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/contains.js","../../../node_modules/@popperjs/core/lib/dom-utils/getComputedStyle.js","../../../node_modules/@popperjs/core/lib/dom-utils/isTableElement.js","../../../node_modules/@popperjs/core/lib/dom-utils/getDocumentElement.js","../../../node_modules/@popperjs/core/lib/dom-utils/getParentNode.js","../../../node_modules/@popperjs/core/lib/dom-utils/getOffsetParent.js","../../../node_modules/@popperjs/core/lib/utils/getMainAxisFromPlacement.js","../../../node_modules/@popperjs/core/lib/utils/within.js","../../../node_modules/@popperjs/core/lib/utils/getFreshSideObject.js","../../../node_modules/@popperjs/core/lib/utils/mergePaddingObject.js","../../../node_modules/@popperjs/core/lib/utils/expandToHashMap.js","../../../node_modules/@popperjs/core/lib/modifiers/arrow.js","../../../node_modules/@popperjs/core/lib/utils/getVariation.js","../../../node_modules/@popperjs/core/lib/modifiers/computeStyles.js","../../../node_modules/@popperjs/core/lib/modifiers/eventListeners.js","../../../node_modules/@popperjs/core/lib/utils/getOppositePlacement.js","../../../node_modules/@popperjs/core/lib/utils/getOppositeVariationPlacement.js","../../../node_modules/@popperjs/core/lib/dom-utils/getWindowScroll.js","../../../node_modules/@popperjs/core/lib/dom-utils/getWindowScrollBarX.js","../../../node_modules/@popperjs/core/lib/dom-utils/getViewportRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/getDocumentRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/isScrollParent.js","../../../node_modules/@popperjs/core/lib/dom-utils/getScrollParent.js","../../../node_modules/@popperjs/core/lib/dom-utils/listScrollParents.js","../../../node_modules/@popperjs/core/lib/utils/rectToClientRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/getClippingRect.js","../../../node_modules/@popperjs/core/lib/utils/computeOffsets.js","../../../node_modules/@popperjs/core/lib/utils/detectOverflow.js","../../../node_modules/@popperjs/core/lib/utils/computeAutoPlacement.js","../../../node_modules/@popperjs/core/lib/modifiers/flip.js","../../../node_modules/@popperjs/core/lib/modifiers/hide.js","../../../node_modules/@popperjs/core/lib/modifiers/offset.js","../../../node_modules/@popperjs/core/lib/modifiers/popperOffsets.js","../../../node_modules/@popperjs/core/lib/utils/getAltAxis.js","../../../node_modules/@popperjs/core/lib/modifiers/preventOverflow.js","../../../node_modules/@popperjs/core/lib/dom-utils/getHTMLElementScroll.js","../../../node_modules/@popperjs/core/lib/dom-utils/getNodeScroll.js","../../../node_modules/@popperjs/core/lib/dom-utils/getCompositeRect.js","../../../node_modules/@popperjs/core/lib/utils/orderModifiers.js","../../../node_modules/@popperjs/core/lib/utils/debounce.js","../../../node_modules/@popperjs/core/lib/utils/mergeByName.js","../../../node_modules/@popperjs/core/lib/createPopper.js","../../../node_modules/@popperjs/core/lib/popper.js","../../../node_modules/@mui/base/Popper/popperClasses.js","../../../node_modules/@mui/base/Popper/Popper.js","../../../node_modules/@mui/material/styles/useTheme.js","../../../node_modules/@babel/runtime/helpers/esm/setPrototypeOf.js","../../../node_modules/@babel/runtime/helpers/esm/inheritsLoose.js","../../../node_modules/react-transition-group/esm/config.js","../../../node_modules/react-transition-group/esm/utils/PropTypes.js","../../../node_modules/react-transition-group/esm/TransitionGroupContext.js","../../../node_modules/react-transition-group/esm/utils/reflow.js","../../../node_modules/react-transition-group/esm/Transition.js","../../../node_modules/@mui/material/transitions/utils.js","../../../node_modules/@mui/material/Grow/Grow.js","../../../node_modules/@mui/material/Popper/Popper.js","../../../node_modules/@mui/material/Tooltip/tooltipClasses.js","../../../node_modules/@mui/material/Tooltip/Tooltip.js","../src/components/mui/menu-item.component.tsx","../src/components/mui/grouped-menu-item-list.component.tsx","../src/components/mui/top-level-menu.component.tsx","../src/components/mui/grid-menu.component.tsx","../src/hooks/use-promise.hook.ts","../../../node_modules/@mui/icons-material/esm/Menu.js","../src/components/mui/hamburger-menu-button.component.tsx","../src/components/mui/icon-button.component.tsx","../src/components/basics/spinner.component.tsx","../src/components/basics/text-field.component.tsx","../src/components/mui/toolbar.component.tsx","../src/components/shadcn-ui/alert.tsx","../src/components/shadcn-ui/card.tsx","../src/components/shadcn-ui/sonner.tsx","../src/components/shadcn-ui/slider.tsx","../src/components/shadcn-ui/switch.tsx","../src/components/shadcn-ui/tabs.tsx","../src/components/advanced/extension-marketplace/buttons/install-button.component.tsx","../src/components/advanced/extension-marketplace/buttons/enable-button.component.tsx","../src/components/advanced/extension-marketplace/buttons/disable-button.component.tsx","../src/components/advanced/extension-marketplace/buttons/update-button.component.tsx","../src/components/advanced/extension-marketplace/markdown-renderer.component.tsx","../src/components/advanced/extension-marketplace/buttons/filter-button.component.tsx","../src/components/advanced/extension-marketplace/filter-dropdown.component.tsx","../src/components/advanced/extension-marketplace/no-extensions-found.component.tsx","../src/components/advanced/extension-marketplace/more-info.component.tsx","../src/components/advanced/extension-marketplace/version-history.component.tsx","../src/components/advanced/extension-marketplace/footer.component.tsx","../src/hooks/use-event.hook.ts","../src/hooks/use-event-async.hook.ts"],"sourcesContent":["import { type ClassValue, clsx } from 'clsx';\nimport { extendTailwindMerge } from 'tailwind-merge';\n\nconst twMergeCustom = extendTailwindMerge({ prefix: 'tw-' });\n\n/**\n * Tailwind and CSS class application helper function. Uses\n * [`clsx`](https://www.npmjs.com/package/clsx) to make it easy to apply classes conditionally using\n * object syntax, and uses [`tailwind-merge`](https://www.npmjs.com/package/tailwind-merge) to make\n * it easy to merge/overwrite Tailwind classes in a programmer-logic-friendly way.\n *\n * Note: `tailwind-merge` is configured to use the prefix `tw-`, so you must use the same prefix\n * with any Tailwind classes you use with this function to successfully overwrite other Tailwind\n * classes. `platform-bible-react` is configured to use `tw-` as its Tailwind prefix, so any\n * Tailwind classes you pass into `platform-bible-react` components will be compared using the `tw-`\n * prefix.\n *\n * This function was popularized by\n * [shadcn/ui](https://ui.shadcn.com/docs/installation/manual#add-a-cn-helper). See [ByteGrad's\n * explanation video](https://www.youtube.com/watch?v=re2JFITR7TI) for more information.\n *\n * @example\n *\n * ```typescript\n * const borderShouldBeBlue = true;\n * const textShouldBeRed = true;\n * const heightShouldBe20 = false;\n * const classString = cn(\n * 'tw-bg-primary tw-h-10 tw-text-primary-foreground',\n * 'tw-bg-secondary',\n * {\n * 'tw-border-blue-500': borderShouldBeBlue,\n * 'tw-text-red-500': textShouldBeRed,\n * 'tw-h-20': heightShouldBe20,\n * },\n * 'some-class',\n * );\n * ```\n *\n * The resulting `classString` is `'tw-h-10 tw-bg-secondary tw-border-blue-500 tw-text-red-500\n * some-class'`\n *\n * - Notice that `'tw-bg-secondary'`, specified later, overwrote `'tw-bg-primary'`, specified earlier,\n * because they are Tailwind classes that affect the same css property\n * - Notice that `'tw-text-red-500'`, specified later, overwrote `'tw-text-primary-foreground'`,\n * specified earlier, because they are Tailwind classes that affect the same css property\n * - Notice that `'tw-h-20'`, specified later, did not overwrite `'tw-h-10'`, specified earlier,\n * because `'tw-h-20'` is part of a conditional class object and its value evaluated to `false`;\n * therefore it was not applied\n * - Notice that `'some-class'` was applied. This function is not limited only to Tailwind classes.\n *\n *\n * @param inputs Class strings or `clsx` conditional class objects to merge. Tailwind classes\n * specified later in the arguments overwrite similar Tailwind classes specified earlier in the\n * arguments\n * @returns Class string containing all applicable classes from the arguments based on the rules\n * described above\n */\n// shadcn/ui uses this export in its boilerplate code\n// eslint-disable-next-line import/prefer-default-export\nexport function cn(...inputs: ClassValue[]) {\n return twMergeCustom(clsx(inputs));\n}\n","import React from 'react';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport interface InputProps extends React.InputHTMLAttributes {}\n\nexport const Input = React.forwardRef(\n ({ className, type, ...props }, ref) => {\n return (\n \n );\n },\n);\nInput.displayName = 'Input';\n","import { FocusEventHandler, forwardRef, KeyboardEvent, MouseEventHandler } from 'react';\nimport { History } from 'lucide-react';\nimport { Input as ShadInput } from '@/components/shadcn-ui/input';\n\nexport type BookChapterInputProps = {\n handleSearch: (searchString: string) => void;\n handleKeyDown: (event: KeyboardEvent) => void;\n handleOnClick: MouseEventHandler;\n handleSubmit: () => void;\n onFocus?: FocusEventHandler;\n value: string;\n placeholder: string;\n};\n\n// Shadcn Input sets type to \"button\"- HAVE to prop spread before setting type\nconst BookChapterInput = forwardRef(\n (\n { handleSearch, handleKeyDown, handleOnClick, handleSubmit, ...props }: BookChapterInputProps,\n ref,\n ) => {\n return (\n
    \n handleSearch(event.target.value)}\n onKeyDown={(e) => {\n if (e.key === 'Enter') {\n handleSubmit();\n }\n handleKeyDown(e);\n }}\n onClick={handleOnClick}\n ref={ref}\n />\n {\n // eslint-disable-next-line no-console\n console.log('back in history');\n }}\n />\n
    \n );\n },\n);\n\nexport default BookChapterInput;\n","var P = Object.defineProperty;\nvar R = (t, e, s) => e in t ? P(t, e, { enumerable: !0, configurable: !0, writable: !0, value: s }) : t[e] = s;\nvar n = (t, e, s) => R(t, typeof e != \"symbol\" ? e + \"\" : e, s);\nclass _ {\n constructor() {\n n(this, \"books\");\n n(this, \"firstSelectedBookNum\");\n n(this, \"lastSelectedBookNum\");\n n(this, \"count\");\n n(this, \"selectedBookNumbers\");\n n(this, \"selectedBookIds\");\n }\n}\nconst N = [\n \"GEN\",\n \"EXO\",\n \"LEV\",\n \"NUM\",\n \"DEU\",\n \"JOS\",\n \"JDG\",\n \"RUT\",\n \"1SA\",\n \"2SA\",\n // 10\n \"1KI\",\n \"2KI\",\n \"1CH\",\n \"2CH\",\n \"EZR\",\n \"NEH\",\n \"EST\",\n \"JOB\",\n \"PSA\",\n \"PRO\",\n // 20\n \"ECC\",\n \"SNG\",\n \"ISA\",\n \"JER\",\n \"LAM\",\n \"EZK\",\n \"DAN\",\n \"HOS\",\n \"JOL\",\n \"AMO\",\n // 30\n \"OBA\",\n \"JON\",\n \"MIC\",\n \"NAM\",\n \"HAB\",\n \"ZEP\",\n \"HAG\",\n \"ZEC\",\n \"MAL\",\n \"MAT\",\n // 40\n \"MRK\",\n \"LUK\",\n \"JHN\",\n \"ACT\",\n \"ROM\",\n \"1CO\",\n \"2CO\",\n \"GAL\",\n \"EPH\",\n \"PHP\",\n // 50\n \"COL\",\n \"1TH\",\n \"2TH\",\n \"1TI\",\n \"2TI\",\n \"TIT\",\n \"PHM\",\n \"HEB\",\n \"JAS\",\n \"1PE\",\n // 60\n \"2PE\",\n \"1JN\",\n \"2JN\",\n \"3JN\",\n \"JUD\",\n \"REV\",\n \"TOB\",\n \"JDT\",\n \"ESG\",\n \"WIS\",\n // 70\n \"SIR\",\n \"BAR\",\n \"LJE\",\n \"S3Y\",\n \"SUS\",\n \"BEL\",\n \"1MA\",\n \"2MA\",\n \"3MA\",\n \"4MA\",\n // 80\n \"1ES\",\n \"2ES\",\n \"MAN\",\n \"PS2\",\n \"ODA\",\n \"PSS\",\n \"JSA\",\n // actual variant text for JOS, now in LXA text\n \"JDB\",\n // actual variant text for JDG, now in LXA text\n \"TBS\",\n // actual variant text for TOB, now in LXA text\n \"SST\",\n // actual variant text for SUS, now in LXA text // 90\n \"DNT\",\n // actual variant text for DAN, now in LXA text\n \"BLT\",\n // actual variant text for BEL, now in LXA text\n \"XXA\",\n \"XXB\",\n \"XXC\",\n \"XXD\",\n \"XXE\",\n \"XXF\",\n \"XXG\",\n \"FRT\",\n // 100\n \"BAK\",\n \"OTH\",\n \"3ES\",\n // Used previously but really should be 2ES\n \"EZA\",\n // Used to be called 4ES, but not actually in any known project\n \"5EZ\",\n // Used to be called 5ES, but not actually in any known project\n \"6EZ\",\n // Used to be called 6ES, but not actually in any known project\n \"INT\",\n \"CNC\",\n \"GLO\",\n \"TDX\",\n // 110\n \"NDX\",\n \"DAG\",\n \"PS3\",\n \"2BA\",\n \"LBA\",\n \"JUB\",\n \"ENO\",\n \"1MQ\",\n \"2MQ\",\n \"3MQ\",\n // 120\n \"REP\",\n \"4BA\",\n \"LAO\"\n], B = [\n \"XXA\",\n \"XXB\",\n \"XXC\",\n \"XXD\",\n \"XXE\",\n \"XXF\",\n \"XXG\",\n \"FRT\",\n \"BAK\",\n \"OTH\",\n \"INT\",\n \"CNC\",\n \"GLO\",\n \"TDX\",\n \"NDX\"\n], O = [\n \"Genesis\",\n \"Exodus\",\n \"Leviticus\",\n \"Numbers\",\n \"Deuteronomy\",\n \"Joshua\",\n \"Judges\",\n \"Ruth\",\n \"1 Samuel\",\n \"2 Samuel\",\n \"1 Kings\",\n \"2 Kings\",\n \"1 Chronicles\",\n \"2 Chronicles\",\n \"Ezra\",\n \"Nehemiah\",\n \"Esther (Hebrew)\",\n \"Job\",\n \"Psalms\",\n \"Proverbs\",\n \"Ecclesiastes\",\n \"Song of Songs\",\n \"Isaiah\",\n \"Jeremiah\",\n \"Lamentations\",\n \"Ezekiel\",\n \"Daniel (Hebrew)\",\n \"Hosea\",\n \"Joel\",\n \"Amos\",\n \"Obadiah\",\n \"Jonah\",\n \"Micah\",\n \"Nahum\",\n \"Habakkuk\",\n \"Zephaniah\",\n \"Haggai\",\n \"Zechariah\",\n \"Malachi\",\n \"Matthew\",\n \"Mark\",\n \"Luke\",\n \"John\",\n \"Acts\",\n \"Romans\",\n \"1 Corinthians\",\n \"2 Corinthians\",\n \"Galatians\",\n \"Ephesians\",\n \"Philippians\",\n \"Colossians\",\n \"1 Thessalonians\",\n \"2 Thessalonians\",\n \"1 Timothy\",\n \"2 Timothy\",\n \"Titus\",\n \"Philemon\",\n \"Hebrews\",\n \"James\",\n \"1 Peter\",\n \"2 Peter\",\n \"1 John\",\n \"2 John\",\n \"3 John\",\n \"Jude\",\n \"Revelation\",\n \"Tobit\",\n \"Judith\",\n \"Esther Greek\",\n \"Wisdom of Solomon\",\n \"Sirach (Ecclesiasticus)\",\n \"Baruch\",\n \"Letter of Jeremiah\",\n \"Song of 3 Young Men\",\n \"Susanna\",\n \"Bel and the Dragon\",\n \"1 Maccabees\",\n \"2 Maccabees\",\n \"3 Maccabees\",\n \"4 Maccabees\",\n \"1 Esdras (Greek)\",\n \"2 Esdras (Latin)\",\n \"Prayer of Manasseh\",\n \"Psalm 151\",\n \"Odes\",\n \"Psalms of Solomon\",\n // WARNING, if you change the spelling of the *obsolete* tag be sure to update\n // IsObsolete routine\n \"Joshua A. *obsolete*\",\n \"Judges B. *obsolete*\",\n \"Tobit S. *obsolete*\",\n \"Susanna Th. *obsolete*\",\n \"Daniel Th. *obsolete*\",\n \"Bel Th. *obsolete*\",\n \"Extra A\",\n \"Extra B\",\n \"Extra C\",\n \"Extra D\",\n \"Extra E\",\n \"Extra F\",\n \"Extra G\",\n \"Front Matter\",\n \"Back Matter\",\n \"Other Matter\",\n \"3 Ezra *obsolete*\",\n \"Apocalypse of Ezra\",\n \"5 Ezra (Latin Prologue)\",\n \"6 Ezra (Latin Epilogue)\",\n \"Introduction\",\n \"Concordance \",\n \"Glossary \",\n \"Topical Index\",\n \"Names Index\",\n \"Daniel Greek\",\n \"Psalms 152-155\",\n \"2 Baruch (Apocalypse)\",\n \"Letter of Baruch\",\n \"Jubilees\",\n \"Enoch\",\n \"1 Meqabyan\",\n \"2 Meqabyan\",\n \"3 Meqabyan\",\n \"Reproof (Proverbs 25-31)\",\n \"4 Baruch (Rest of Baruch)\",\n \"Laodiceans\"\n], S = K();\nfunction g(t, e = !0) {\n return e && (t = t.toUpperCase()), t in S ? S[t] : 0;\n}\nfunction k(t) {\n return g(t) > 0;\n}\nfunction x(t) {\n const e = typeof t == \"string\" ? g(t) : t;\n return e >= 40 && e <= 66;\n}\nfunction T(t) {\n return (typeof t == \"string\" ? g(t) : t) <= 39;\n}\nfunction X(t) {\n return t <= 66;\n}\nfunction V(t) {\n const e = typeof t == \"string\" ? g(t) : t;\n return w(e) && !X(e);\n}\nfunction* L() {\n for (let t = 1; t <= N.length; t++) yield t;\n}\nconst G = 1, A = N.length;\nfunction H() {\n return [\"XXA\", \"XXB\", \"XXC\", \"XXD\", \"XXE\", \"XXF\", \"XXG\"];\n}\nfunction C(t, e = \"***\") {\n const s = t - 1;\n return s < 0 || s >= N.length ? e : N[s];\n}\nfunction I(t) {\n return t <= 0 || t > A ? \"******\" : O[t - 1];\n}\nfunction y(t) {\n return I(g(t));\n}\nfunction w(t) {\n const e = typeof t == \"number\" ? C(t) : t;\n return k(e) && !B.includes(e);\n}\nfunction q(t) {\n const e = typeof t == \"number\" ? C(t) : t;\n return k(e) && B.includes(e);\n}\nfunction U(t) {\n return O[t - 1].includes(\"*obsolete*\");\n}\nfunction K() {\n const t = {};\n for (let e = 0; e < N.length; e++)\n t[N[e]] = e + 1;\n return t;\n}\nconst m = {\n allBookIds: N,\n nonCanonicalIds: B,\n bookIdToNumber: g,\n isBookIdValid: k,\n isBookNT: x,\n isBookOT: T,\n isBookOTNT: X,\n isBookDC: V,\n allBookNumbers: L,\n firstBook: G,\n lastBook: A,\n extraBooks: H,\n bookNumberToId: C,\n bookNumberToEnglishName: I,\n bookIdToEnglishName: y,\n isCanonical: w,\n isExtraMaterial: q,\n isObsolete: U\n};\nvar l = /* @__PURE__ */ ((t) => (t[t.Unknown = 0] = \"Unknown\", t[t.Original = 1] = \"Original\", t[t.Septuagint = 2] = \"Septuagint\", t[t.Vulgate = 3] = \"Vulgate\", t[t.English = 4] = \"English\", t[t.RussianProtestant = 5] = \"RussianProtestant\", t[t.RussianOrthodox = 6] = \"RussianOrthodox\", t))(l || {});\nconst h = class h {\n // private versInfo: Versification;\n constructor(e) {\n n(this, \"name\");\n n(this, \"fullPath\");\n n(this, \"isPresent\");\n n(this, \"hasVerseSegments\");\n n(this, \"isCustomized\");\n n(this, \"baseVersification\");\n n(this, \"scriptureBooks\");\n n(this, \"_type\");\n if (e == null)\n throw new Error(\"Argument undefined\");\n typeof e == \"string\" ? (this.name = e, this._type = l[e]) : (this._type = e, this.name = l[e]);\n }\n get type() {\n return this._type;\n }\n equals(e) {\n return !e.type || !this.type ? !1 : e.type === this.type;\n }\n};\nn(h, \"Original\", new h(l.Original)), n(h, \"Septuagint\", new h(l.Septuagint)), n(h, \"Vulgate\", new h(l.Vulgate)), n(h, \"English\", new h(l.English)), n(h, \"RussianProtestant\", new h(l.RussianProtestant)), n(h, \"RussianOrthodox\", new h(l.RussianOrthodox));\nlet c = h;\nfunction E(t, e) {\n const s = e[0];\n for (let r = 1; r < e.length; r++)\n t = t.split(e[r]).join(s);\n return t.split(s);\n}\nvar D = /* @__PURE__ */ ((t) => (t[t.Valid = 0] = \"Valid\", t[t.UnknownVersification = 1] = \"UnknownVersification\", t[t.OutOfRange = 2] = \"OutOfRange\", t[t.VerseOutOfOrder = 3] = \"VerseOutOfOrder\", t[t.VerseRepeated = 4] = \"VerseRepeated\", t))(D || {});\nconst i = class i {\n constructor(e, s, r, a) {\n /** Not yet implemented. */\n n(this, \"firstChapter\");\n /** Not yet implemented. */\n n(this, \"lastChapter\");\n /** Not yet implemented. */\n n(this, \"lastVerse\");\n /** Not yet implemented. */\n n(this, \"hasSegmentsDefined\");\n /** Not yet implemented. */\n n(this, \"text\");\n /** Not yet implemented. */\n n(this, \"BBBCCCVVVS\");\n /** Not yet implemented. */\n n(this, \"longHashCode\");\n /** The versification of the reference. */\n n(this, \"versification\");\n n(this, \"rtlMark\", \"‏\");\n n(this, \"_bookNum\", 0);\n n(this, \"_chapterNum\", 0);\n n(this, \"_verseNum\", 0);\n n(this, \"_verse\");\n if (r == null && a == null)\n if (e != null && typeof e == \"string\") {\n const o = e, u = s != null && s instanceof c ? s : void 0;\n this.setEmpty(u), this.parse(o);\n } else if (e != null && typeof e == \"number\") {\n const o = s != null && s instanceof c ? s : void 0;\n this.setEmpty(o), this._verseNum = e % i.chapterDigitShifter, this._chapterNum = Math.floor(\n e % i.bookDigitShifter / i.chapterDigitShifter\n ), this._bookNum = Math.floor(e / i.bookDigitShifter);\n } else if (s == null)\n if (e != null && e instanceof i) {\n const o = e;\n this._bookNum = o.bookNum, this._chapterNum = o.chapterNum, this._verseNum = o.verseNum, this._verse = o.verse, this.versification = o.versification;\n } else {\n if (e == null) return;\n const o = e instanceof c ? e : i.defaultVersification;\n this.setEmpty(o);\n }\n else\n throw new Error(\"VerseRef constructor not supported.\");\n else if (e != null && s != null && r != null)\n if (typeof e == \"string\" && typeof s == \"string\" && typeof r == \"string\")\n this.setEmpty(a), this.updateInternal(e, s, r);\n else if (typeof e == \"number\" && typeof s == \"number\" && typeof r == \"number\")\n this._bookNum = e, this._chapterNum = s, this._verseNum = r, this.versification = a ?? i.defaultVersification;\n else\n throw new Error(\"VerseRef constructor not supported.\");\n else\n throw new Error(\"VerseRef constructor not supported.\");\n }\n /**\n * Determines if the verse string is in a valid format (does not consider versification).\n */\n static isVerseParseable(e) {\n return e.length > 0 && \"0123456789\".includes(e[0]) && !e.endsWith(this.verseRangeSeparator) && !e.endsWith(this.verseSequenceIndicator);\n }\n /**\n * Tries to parse the specified string into a verse reference.\n * @param str - The string to attempt to parse.\n * @returns success: `true` if the specified string was successfully parsed, `false` otherwise.\n * @returns verseRef: The result of the parse if successful, or empty VerseRef if it failed\n */\n static tryParse(e) {\n let s;\n try {\n return s = new i(e), { success: !0, verseRef: s };\n } catch (r) {\n if (r instanceof v)\n return s = new i(), { success: !1, verseRef: s };\n throw r;\n }\n }\n /**\n * Gets the reference as a comparable integer where the book, chapter, and verse each occupy 3\n * digits.\n * @param bookNum - Book number (this is 1-based, not an index).\n * @param chapterNum - Chapter number.\n * @param verseNum - Verse number.\n * @returns The reference as a comparable integer where the book, chapter, and verse each occupy 3\n * digits.\n */\n static getBBBCCCVVV(e, s, r) {\n return e % i.bcvMaxValue * i.bookDigitShifter + (s >= 0 ? s % i.bcvMaxValue * i.chapterDigitShifter : 0) + (r >= 0 ? r % i.bcvMaxValue : 0);\n }\n /**\n * Deserializes a serialized VerseRef.\n * @param serializedVerseRef - Serialized VerseRef to create from.\n * @returns the deserialized VerseRef.\n */\n static fromJSON(e) {\n const { book: s, chapterNum: r, verseNum: a, verse: o, versificationStr: u } = e, f = o || a.toString();\n let d;\n return u && (d = new c(u)), s ? new i(s, r.toString(), f, d) : new i();\n }\n /**\n * Parses a verse string and gets the leading numeric portion as a number.\n * @param verseStr - verse string to parse\n * @returns true if the entire string could be parsed as a single, simple verse number (1-999);\n * false if the verse string represented a verse bridge, contained segment letters, or was invalid\n */\n static tryGetVerseNum(e) {\n let s;\n if (!e)\n return s = -1, { success: !0, vNum: s };\n s = 0;\n let r;\n for (let a = 0; a < e.length; a++) {\n if (r = e[a], r < \"0\" || r > \"9\")\n return a === 0 && (s = -1), { success: !1, vNum: s };\n if (s = s * 10 + +r - 0, s > i.bcvMaxValue)\n return s = -1, { success: !1, vNum: s };\n }\n return { success: !0, vNum: s };\n }\n /**\n * Checks to see if a VerseRef hasn't been set - all values are the default.\n */\n get isDefault() {\n return this.bookNum === 0 && this.chapterNum === 0 && this.verseNum === 0 && this.versification == null;\n }\n /**\n * Gets whether the verse contains multiple verses.\n */\n get hasMultiple() {\n return this._verse != null && (this._verse.includes(i.verseRangeSeparator) || this._verse.includes(i.verseSequenceIndicator));\n }\n /**\n * Gets or sets the book of the reference. Book is the 3-letter abbreviation in capital letters,\n * e.g. `'MAT'`.\n */\n get book() {\n return m.bookNumberToId(this.bookNum, \"\");\n }\n set book(e) {\n this.bookNum = m.bookIdToNumber(e);\n }\n /**\n * Gets or sets the chapter of the reference,. e.g. `'3'`.\n */\n get chapter() {\n return this.isDefault || this._chapterNum < 0 ? \"\" : this._chapterNum.toString();\n }\n set chapter(e) {\n const s = +e;\n this._chapterNum = Number.isInteger(s) ? s : -1;\n }\n /**\n * Gets or sets the verse of the reference, including range, segments, and sequences, e.g. `'4'`,\n * or `'4b-5a, 7'`.\n */\n get verse() {\n return this._verse != null ? this._verse : this.isDefault || this._verseNum < 0 ? \"\" : this._verseNum.toString();\n }\n set verse(e) {\n const { success: s, vNum: r } = i.tryGetVerseNum(e);\n this._verse = s ? void 0 : e.replace(this.rtlMark, \"\"), this._verseNum = r, !(this._verseNum >= 0) && ({ vNum: this._verseNum } = i.tryGetVerseNum(this._verse));\n }\n /**\n * Get or set Book based on book number, e.g. `42`.\n */\n get bookNum() {\n return this._bookNum;\n }\n set bookNum(e) {\n if (e <= 0 || e > m.lastBook)\n throw new v(\n \"BookNum must be greater than zero and less than or equal to last book\"\n );\n this._bookNum = e;\n }\n /**\n * Gets or sets the chapter number, e.g. `3`. `-1` if not valid.\n */\n get chapterNum() {\n return this._chapterNum;\n }\n set chapterNum(e) {\n this.chapterNum = e;\n }\n /**\n * Gets or sets verse start number, e.g. `4`. `-1` if not valid.\n */\n get verseNum() {\n return this._verseNum;\n }\n set verseNum(e) {\n this._verseNum = e;\n }\n /**\n * String representing the versification (should ONLY be used for serialization/deserialization).\n *\n * @remarks This is for backwards compatibility when ScrVers was an enumeration.\n */\n get versificationStr() {\n var e;\n return (e = this.versification) == null ? void 0 : e.name;\n }\n set versificationStr(e) {\n this.versification = this.versification != null ? new c(e) : void 0;\n }\n /**\n * Determines if the reference is valid.\n */\n get valid() {\n return this.validStatus === 0;\n }\n /**\n * Get the valid status for this reference.\n */\n get validStatus() {\n return this.validateVerse(i.verseRangeSeparators, i.verseSequenceIndicators);\n }\n /**\n * Gets the reference as a comparable integer where the book,\n * chapter, and verse each occupy three digits and the verse is 0.\n */\n get BBBCCC() {\n return i.getBBBCCCVVV(this._bookNum, this._chapterNum, 0);\n }\n /**\n * Gets the reference as a comparable integer where the book,\n * chapter, and verse each occupy three digits. If verse is not null\n * (i.e., this reference represents a complex reference with verse\n * segments or bridge) this cannot be used for an exact comparison.\n */\n get BBBCCCVVV() {\n return i.getBBBCCCVVV(this._bookNum, this._chapterNum, this._verseNum);\n }\n /**\n * Gets whether the verse is defined as an excluded verse in the versification.\n * Does not handle verse ranges.\n */\n // eslint-disable-next-line @typescript-eslint/class-literal-property-style\n get isExcluded() {\n return !1;\n }\n /**\n * Parses the reference in the specified string.\n * Optionally versification can follow reference as in GEN 3:11/4\n * Throw an exception if\n * - invalid book name\n * - chapter number is missing or not a number\n * - verse number is missing or does not start with a number\n * - versification is invalid\n * @param verseStr - string to parse e.g. 'MAT 3:11'\n */\n parse(e) {\n if (e = e.replace(this.rtlMark, \"\"), e.includes(\"/\")) {\n const o = e.split(\"/\");\n if (e = o[0], o.length > 1)\n try {\n const u = +o[1].trim();\n this.versification = new c(l[u]);\n } catch {\n throw new v(\"Invalid reference : \" + e);\n }\n }\n const s = e.trim().split(\" \");\n if (s.length !== 2)\n throw new v(\"Invalid reference : \" + e);\n const r = s[1].split(\":\"), a = +r[0];\n if (r.length !== 2 || m.bookIdToNumber(s[0]) === 0 || !Number.isInteger(a) || a < 0 || !i.isVerseParseable(r[1]))\n throw new v(\"Invalid reference : \" + e);\n this.updateInternal(s[0], r[0], r[1]);\n }\n /**\n * Simplifies this verse ref so that it has no bridging of verses or\n * verse segments like `'1a'`.\n */\n simplify() {\n this._verse = void 0;\n }\n /**\n * Makes a clone of the reference.\n *\n * @returns The cloned VerseRef.\n */\n clone() {\n return new i(this);\n }\n toString() {\n const e = this.book;\n return e === \"\" ? \"\" : `${e} ${this.chapter}:${this.verse}`;\n }\n toJSON() {\n let e = this.verse;\n (e === \"\" || e === this.verseNum.toString()) && (e = void 0);\n const s = {\n book: this.book,\n chapterNum: this.chapterNum,\n verseNum: this.verseNum,\n verse: e,\n versificationStr: this.versificationStr\n };\n return e || delete s.verse, s;\n }\n /**\n * Compares this `VerseRef` with supplied one.\n * @param verseRef - object to compare this one to.\n * @returns `true` if this `VerseRef` is equal to the supplied one, `false` otherwise.\n */\n equals(e) {\n return e instanceof i ? e._bookNum === this._bookNum && e._chapterNum === this._chapterNum && e._verseNum === this._verseNum && e.verse === this.verse && (e.versification == null && this.versification == null || e.versification != null && this.versification != null && e.versification.equals(this.versification)) : !1;\n }\n /**\n * Enumerate all individual verses contained in a VerseRef.\n * Verse ranges are indicated by \"-\" and consecutive verses by \",\"s.\n * Examples:\n * GEN 1:2 returns GEN 1:2\n * GEN 1:1a-3b,5 returns GEN 1:1a, GEN 1:2, GEN 1:3b, GEN 1:5\n * GEN 1:2a-2c returns //! ??????\n *\n * @param specifiedVersesOnly - if set to true return only verses that are\n * explicitly specified only, not verses within a range. Defaults to `false`.\n * @param verseRangeSeparators - Verse range separators.\n * Defaults to `VerseRef.verseRangeSeparators`.\n * @param verseSequenceSeparators - Verse sequence separators.\n * Defaults to `VerseRef.verseSequenceIndicators`.\n * @returns An array of all single verse references in this VerseRef.\n */\n allVerses(e = !1, s = i.verseRangeSeparators, r = i.verseSequenceIndicators) {\n if (this._verse == null || this.chapterNum <= 0)\n return [this.clone()];\n const a = [], o = E(this._verse, r);\n for (const u of o.map((f) => E(f, s))) {\n const f = this.clone();\n f.verse = u[0];\n const d = f.verseNum;\n if (a.push(f), u.length > 1) {\n const b = this.clone();\n if (b.verse = u[1], !e)\n for (let p = d + 1; p < b.verseNum; p++) {\n const J = new i(\n this._bookNum,\n this._chapterNum,\n p,\n this.versification\n );\n this.isExcluded || a.push(J);\n }\n a.push(b);\n }\n }\n return a;\n }\n /**\n * Validates a verse number using the supplied separators rather than the defaults.\n */\n validateVerse(e, s) {\n if (!this.verse)\n return this.internalValid;\n let r = 0;\n for (const a of this.allVerses(!0, e, s)) {\n const o = a.internalValid;\n if (o !== 0)\n return o;\n const u = a.BBBCCCVVV;\n if (r > u)\n return 3;\n if (r === u)\n return 4;\n r = u;\n }\n return 0;\n }\n /**\n * Gets whether a single verse reference is valid.\n */\n get internalValid() {\n return this.versification == null ? 1 : this._bookNum <= 0 || this._bookNum > m.lastBook ? 2 : (m.isCanonical(this._bookNum), 0);\n }\n setEmpty(e = i.defaultVersification) {\n this._bookNum = 0, this._chapterNum = -1, this._verse = void 0, this.versification = e;\n }\n updateInternal(e, s, r) {\n this.bookNum = m.bookIdToNumber(e), this.chapter = s, this.verse = r;\n }\n};\nn(i, \"defaultVersification\", c.English), n(i, \"verseRangeSeparator\", \"-\"), n(i, \"verseSequenceIndicator\", \",\"), n(i, \"verseRangeSeparators\", [i.verseRangeSeparator]), n(i, \"verseSequenceIndicators\", [i.verseSequenceIndicator]), n(i, \"chapterDigitShifter\", 1e3), n(i, \"bookDigitShifter\", i.chapterDigitShifter * i.chapterDigitShifter), n(i, \"bcvMaxValue\", i.chapterDigitShifter - 1), /**\n * The valid status of the VerseRef.\n */\nn(i, \"ValidStatusType\", D);\nlet M = i;\nclass v extends Error {\n}\nexport {\n _ as BookSet,\n m as Canon,\n c as ScrVers,\n l as ScrVersType,\n M as VerseRef,\n v as VerseRefException\n};\n//# sourceMappingURL=index.es.js.map\n","import React from 'react';\nimport * as DropdownMenuPrimitive from '@radix-ui/react-dropdown-menu';\nimport { Check, ChevronRight, Circle } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport const DropdownMenu = DropdownMenuPrimitive.Root;\n\nexport const DropdownMenuTrigger = DropdownMenuPrimitive.Trigger;\n\nexport const DropdownMenuGroup = DropdownMenuPrimitive.Group;\n\nexport const DropdownMenuPortal = DropdownMenuPrimitive.Portal;\n\nexport const DropdownMenuSub = DropdownMenuPrimitive.Sub;\n\nexport const DropdownMenuRadioGroup = DropdownMenuPrimitive.RadioGroup;\n\nexport type DropdownMenuSubTriggerProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.SubTrigger\n> & {\n className?: string;\n inset?: boolean;\n};\n\nexport type DropdownMenuSubContentProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.SubContent\n> & {\n className?: string;\n};\n\nexport type DropdownMenuContentProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Content\n> & {\n className?: string;\n sideOffset?: number;\n};\n\nexport type DropdownMenuItemProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Item\n> & {\n className?: string;\n inset?: boolean;\n};\n\nexport type DropdownMenuCheckboxItemProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.CheckboxItem\n> & {\n className?: string;\n checked?: boolean;\n};\n\nexport type DropdownMenuRadioItemProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.RadioItem\n> & {\n className?: string;\n};\n\nexport type DropdownMenuLabelProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Label\n> & {\n className?: string;\n inset?: boolean;\n};\n\nexport type DropdownMenuSeparatorProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Separator\n> & {\n className?: string;\n};\n\nexport type DropdownMenuShortcutProps = React.HTMLAttributes & {\n className?: string;\n};\n\nexport const DropdownMenuSubTrigger = React.forwardRef<\n React.ElementRef,\n DropdownMenuSubTriggerProps\n>(({ className, inset, children, ...props }, ref) => (\n \n {children}\n \n \n));\nDropdownMenuSubTrigger.displayName = DropdownMenuPrimitive.SubTrigger.displayName;\n\nexport const DropdownMenuSubContent = React.forwardRef<\n React.ElementRef,\n DropdownMenuSubContentProps\n>(({ className, ...props }, ref) => (\n \n));\nDropdownMenuSubContent.displayName = DropdownMenuPrimitive.SubContent.displayName;\n\nexport const DropdownMenuContent = React.forwardRef<\n React.ElementRef,\n DropdownMenuContentProps\n>(({ className, sideOffset = 4, ...props }, ref) => (\n \n \n \n));\nDropdownMenuContent.displayName = DropdownMenuPrimitive.Content.displayName;\n\n/**\n * TODO: fix: direction is not automatically handled by this component, so that shortcuts are\n * display always to the right\n */\nexport const DropdownMenuItem = React.forwardRef<\n React.ElementRef,\n DropdownMenuItemProps\n>(({ className, inset, ...props }, ref) => (\n \n));\nDropdownMenuItem.displayName = DropdownMenuPrimitive.Item.displayName;\n\nexport const DropdownMenuCheckboxItem = React.forwardRef<\n React.ElementRef,\n DropdownMenuCheckboxItemProps\n>(({ className, children, checked, ...props }, ref) => (\n \n \n \n \n \n \n {children}\n \n));\nDropdownMenuCheckboxItem.displayName = DropdownMenuPrimitive.CheckboxItem.displayName;\n\nexport const DropdownMenuRadioItem = React.forwardRef<\n React.ElementRef,\n DropdownMenuRadioItemProps\n>(({ className, children, ...props }, ref) => (\n \n \n \n \n \n \n {children}\n \n));\nDropdownMenuRadioItem.displayName = DropdownMenuPrimitive.RadioItem.displayName;\n\nexport const DropdownMenuLabel = React.forwardRef<\n React.ElementRef,\n DropdownMenuLabelProps\n>(({ className, inset, ...props }, ref) => (\n \n));\nDropdownMenuLabel.displayName = DropdownMenuPrimitive.Label.displayName;\n\nexport const DropdownMenuSeparator = React.forwardRef<\n React.ElementRef,\n DropdownMenuSeparatorProps\n>(({ className, ...props }, ref) => (\n \n));\nDropdownMenuSeparator.displayName = DropdownMenuPrimitive.Separator.displayName;\n\nexport function DropdownMenuShortcut({ className, ...props }: DropdownMenuShortcutProps) {\n return (\n \n );\n}\nDropdownMenuShortcut.displayName = 'DropdownMenuShortcut';\n","import { Canon } from '@sillsdev/scripture';\nimport { PropsWithChildren, KeyboardEvent, forwardRef } from 'react';\nimport { DropdownMenuItem as ShadDropdownMenuItem } from '@/components/shadcn-ui/dropdown-menu';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport type BookType = 'OT' | 'NT' | 'DC';\n\ntype BookMenuItemProps = PropsWithChildren<{\n /** String id of book */\n bookId: string;\n /** Callback to run when a book menu item is selected */\n handleSelectBook: () => void;\n /** Indicates if this menu item is currently selected */\n isSelected: boolean;\n /** Function that is called upon highlighting a book in the dropdown menu */\n handleHighlightBook: () => void;\n /**\n * Function that is called on pressing a key\n *\n * @param event Event that contains information about the key stroke\n */\n handleKeyDown: (event: KeyboardEvent) => void;\n /**\n * Type of book associated with this menu item, coordinates color labels ? Mock up has the labels\n * coordinated to genre\n */\n bookType: BookType;\n}>;\n\nconst BookMenuItem = forwardRef(\n (\n {\n bookId,\n handleSelectBook,\n isSelected,\n handleHighlightBook,\n handleKeyDown,\n bookType,\n children,\n }: BookMenuItemProps,\n ref,\n ) => {\n return (\n {\n // preventDefault() here prevents the entire dropdown menu from closing when selecting this item\n event.preventDefault();\n handleSelectBook();\n }}\n onKeyDown={(event: KeyboardEvent) => {\n handleKeyDown(event);\n }}\n onFocus={handleHighlightBook}\n onMouseMove={handleHighlightBook}\n >\n \n {Canon.bookIdToEnglishName(bookId)}\n \n {isSelected &&
    {children}
    }\n \n );\n },\n);\n\nexport default BookMenuItem;\n","import { cn } from '@/utils/shadcn-ui.util';\nimport { useCallback } from 'react';\n\nexport type ChapterSelectProps = {\n /**\n * Callback to run when a chapter div is selected\n *\n * @param chapterNumber Number of the chapter that has been selected\n */\n handleSelectChapter: (chapterNumber: number) => void;\n /** The highest chapter number in the book (of course equal to number of chapters in the book) */\n endChapter: number;\n /** The chapter number that is currently selected */\n activeChapter: number;\n /** The chapter number that is currently highlighted using keyboard or mouse navigation */\n highlightedChapter: number;\n /**\n * Callback to run when a chapter is highlighted by the user\n *\n * @param chapterNumber The chapter that is highlighted\n */\n handleHighlightedChapter: (chapterNumber: number) => void;\n};\n\nfunction ChapterSelect({\n handleSelectChapter,\n endChapter,\n activeChapter,\n highlightedChapter,\n handleHighlightedChapter,\n}: ChapterSelectProps) {\n const chapters = Array.from({ length: endChapter }, (_, i) => i + 1);\n\n const handleMouse = useCallback(\n (chapterNumber: number) => {\n handleHighlightedChapter(chapterNumber);\n },\n [handleHighlightedChapter],\n );\n\n return (\n
    \n {chapters.map((chapter) => (\n {\n event.preventDefault();\n event.stopPropagation();\n handleSelectChapter(chapter);\n }}\n role=\"button\"\n onKeyDown={(event) => {\n if (event.key === 'Enter') {\n handleSelectChapter(chapter);\n }\n }}\n tabIndex={0}\n onMouseMove={() => handleMouse(chapter)}\n >\n {chapter}\n
    \n ))}\n
    \n );\n}\n\nexport default ChapterSelect;\n","import { DropdownMenuLabel as ShadDropdownMenuLabel } from '@/components/shadcn-ui/dropdown-menu';\nimport { Bookmark, Clock, ArrowDownWideNarrow } from 'lucide-react';\n\nexport type GoToMenuItemProps = {\n handleSort: () => void;\n handleLocationHistory: () => void;\n handleBookmarks: () => void;\n};\n\nfunction GoToMenuItem({ handleSort, handleLocationHistory, handleBookmarks }: GoToMenuItemProps) {\n return (\n \n

    Go To

    \n
    \n \n \n \n
    \n
    \n );\n}\n\nexport default GoToMenuItem;\n","import BookChapterInput from '@/components/advanced/book-chapter-control/book-chapter-input.component';\nimport BookMenuItem, {\n BookType,\n} from '@/components/advanced/book-chapter-control/book-menu-item.component';\nimport ChapterSelect from '@/components/advanced/book-chapter-control/chapter-select.component';\nimport GoToMenuItem from '@/components/advanced/book-chapter-control/go-to-menu-item.component';\nimport {\n DropdownMenu as ShadDropdownMenu,\n DropdownMenuContent as ShadDropdownMenuContent,\n DropdownMenuLabel as ShadDropdownMenuLabel,\n DropdownMenuSeparator as ShadDropdownMenuSeparator,\n DropdownMenuTrigger as ShadDropdownMenuTrigger,\n} from '@/components/shadcn-ui/dropdown-menu';\nimport { Canon } from '@sillsdev/scripture';\nimport { ScriptureReference, getChaptersForBook } from 'platform-bible-utils';\nimport {\n KeyboardEvent as ReactKeyboardEvent,\n useCallback,\n useEffect,\n useLayoutEffect,\n useRef,\n useState,\n} from 'react';\n\ntype BookTypeLabels = {\n [bookType in BookType]: string;\n};\ntype BookChapterControlProps = {\n scrRef: ScriptureReference;\n handleSubmit: (scrRef: ScriptureReference) => void;\n};\n\nconst ALL_BOOK_IDS = Canon.allBookIds;\nconst BOOK_TYPE_LABELS: BookTypeLabels = {\n OT: 'Old Testament',\n NT: 'New Testament',\n DC: 'Deuterocanon',\n};\nconst BOOK_TYPE_ARRAY: BookType[] = ['OT', 'NT', 'DC'];\n// This is the height of three menu items to offset scrolling to the selected menu item\n// If you use menuItemRef.clientHeight- includes height of chapter div which is too big\nconst SCROLL_OFFSET = 32 + 32 + 32;\nconst SEARCH_QUERY_FORMATS = [\n /^(\\w+)$/i, // Matches a single word (book name or id)\n /^(\\w+)(?:\\s(\\d+))$/i, // Matches a word followed by a chapter number\n /^(\\w+)(?:\\s(\\d+):(\\d+))$/i, // Matches a word followed by a chapter and verse number\n];\nconst fetchGroupedBooks = (bookType: BookType) => {\n const groupedBooks = {\n OT: ALL_BOOK_IDS.filter((bookId) => Canon.isBookOT(bookId)),\n NT: ALL_BOOK_IDS.filter((bookId) => Canon.isBookNT(bookId)),\n DC: ALL_BOOK_IDS.filter((bookId) => Canon.isBookDC(bookId)),\n };\n return groupedBooks[bookType];\n};\nconst fetchEndChapter = (bookId: string) => {\n // getChaptersForBook returns -1 if not found in scrBookData\n // scrBookData only includes OT and NT, so all DC will return -1\n return getChaptersForBook(Canon.bookIdToNumber(bookId));\n};\n\n/**\n * Gets all of the English names from book ids\n *\n * @returns String[]\n */\nfunction getAllEnglishNames(): string[] {\n const allEnglishNames = ALL_BOOK_IDS.map((bookId) => {\n return Canon.bookIdToEnglishName(bookId);\n });\n return allEnglishNames;\n}\n\n/**\n * Determines if bookName is in allEnglishNames\n *\n * @param bookName Book English name\n * @returns True if bookName is included, false otherwise\n */\nfunction isValidBookEnglishName(bookName: string): boolean {\n return getAllEnglishNames().includes(bookName);\n}\n\n/**\n * Gets a bookId from given English name\n *\n * @param bookName Book English name\n * @returns BookId of provided bookName, undefined otherwise\n */\nfunction getBookIdFromEnglishName(bookName: string): string | undefined {\n // Convert bookName to lowercase and then capitalize the first letter\n const formattedBookName = bookName.toLowerCase().replace(/^\\w/, (c) => c.toUpperCase());\n\n if (isValidBookEnglishName(formattedBookName)) {\n const matchingBookId = ALL_BOOK_IDS.find((bookId) => {\n return Canon.bookIdToEnglishName(bookId) === formattedBookName;\n });\n return matchingBookId;\n }\n\n return undefined;\n}\n\nfunction BookChapterControl({ scrRef, handleSubmit }: BookChapterControlProps) {\n const [searchQuery, setSearchQuery] = useState('');\n const [selectedBookId, setSelectedBookId] = useState(\n Canon.bookNumberToId(scrRef.bookNum),\n );\n const [highlightedChapter, setHighlightedChapter] = useState(scrRef.chapterNum ?? 0);\n const [highlightedBookId, setHighlightedBookId] = useState(\n Canon.bookNumberToId(scrRef.bookNum),\n );\n const [isContentOpen, setIsContentOpen] = useState(false);\n const [isContentOpenDelayed, setIsContentOpenDelayed] = useState(isContentOpen);\n\n // This ref will always be defined\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const inputRef = useRef(undefined!);\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const contentRef = useRef(undefined!);\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const menuItemRef = useRef(undefined!);\n\n const fetchFilteredBooks = useCallback(\n (bookType: BookType) => {\n return fetchGroupedBooks(bookType).filter((bookId: string) => {\n const englishNameLowerCase = Canon.bookIdToEnglishName(bookId).toLowerCase();\n const normalizedQuery = searchQuery.replace(/[^a-zA-Z]/g, '').toLowerCase();\n return (\n englishNameLowerCase.includes(normalizedQuery) || // Match book name\n bookId.toLowerCase().includes(normalizedQuery) // Match book ID\n );\n });\n },\n [searchQuery],\n );\n\n const handleSearchInput = (searchString: string) => {\n setSearchQuery(searchString);\n };\n\n /**\n * Whether to prevent radix's logic from closing the dropdown. This is important because radix\n * tries to close the dropdown when the input first focuses, and we don't want it to do that. But\n * we don't want to prevent the dropdown from closing when we click away from the input, so we\n * don't want to just keep it open if the input is focused\n */\n const shouldPreventAutoClosing = useRef(false);\n\n const controlMenuState = useCallback((open: boolean) => {\n if (shouldPreventAutoClosing.current) {\n shouldPreventAutoClosing.current = false;\n return;\n }\n setIsContentOpen(open);\n }, []);\n\n const updateReference = useCallback(\n (bookId: string, shouldClose: boolean, chapter?: number, verse?: number) => {\n setHighlightedChapter(\n Canon.bookNumberToId(scrRef.bookNum) !== bookId ? 1 : scrRef.chapterNum,\n );\n\n if (shouldClose || fetchEndChapter(bookId) === -1) {\n handleSubmit({\n bookNum: Canon.bookIdToNumber(bookId),\n chapterNum: chapter || 1,\n verseNum: verse || 1,\n });\n\n setIsContentOpen(false);\n setSearchQuery('');\n return;\n }\n\n setSelectedBookId(selectedBookId !== bookId ? bookId : '');\n setIsContentOpen(!shouldClose);\n },\n [handleSubmit, scrRef.bookNum, scrRef.chapterNum, selectedBookId],\n );\n\n const handleSelectChapter = (chapterNumber: number) => {\n if (chapterNumber <= 0 || chapterNumber > fetchEndChapter(selectedBookId)) {\n return;\n }\n updateReference(selectedBookId, true, chapterNumber);\n };\n\n const handleInputSubmit = useCallback(() => {\n SEARCH_QUERY_FORMATS.forEach((format) => {\n const matches = searchQuery.match(format);\n if (matches) {\n // Book should be a bookId or an english name\n const [book, chapter = undefined, verse = undefined] = matches.slice(1);\n const englishName = getBookIdFromEnglishName(book);\n\n if (Canon.isBookIdValid(book) || englishName) {\n updateReference(\n englishName ?? book,\n true,\n chapter ? parseInt(chapter, 10) : 1,\n verse ? parseInt(verse, 10) : 1,\n );\n }\n }\n });\n }, [updateReference, searchQuery]);\n\n const handleKeyDownInput = useCallback(\n (event: ReactKeyboardEvent) => {\n if (!isContentOpen) {\n setIsContentOpen(true);\n } else if (event.key === 'ArrowDown' || event.key === 'ArrowUp') {\n if (\n typeof menuItemRef !== 'undefined' &&\n // Ref uses null\n // eslint-disable-next-line no-null/no-null\n menuItemRef.current !== null\n ) {\n menuItemRef.current.focus();\n } else if (\n typeof contentRef !== 'undefined' &&\n // Ref uses null\n // eslint-disable-next-line no-null/no-null\n contentRef.current !== null\n ) {\n contentRef.current.focus();\n }\n event.preventDefault();\n }\n },\n [isContentOpen],\n );\n\n const handleKeyDownContent = (event: ReactKeyboardEvent) => {\n // When the dropdown menu has focus, key strokes should give focus to the input component,\n // unless they're navigation keys (arrows and enter)\n const { key } = event;\n if (\n key === 'ArrowRight' ||\n key === 'ArrowLeft' ||\n key === 'ArrowDown' ||\n key === 'ArrowUp' ||\n key === 'Enter'\n ) {\n return;\n }\n\n inputRef.current.dispatchEvent(new KeyboardEvent('keydown', { key }));\n inputRef.current.focus();\n };\n\n const handleKeyDownMenuItem = (event: ReactKeyboardEvent) => {\n const { key } = event;\n if (highlightedBookId === selectedBookId) {\n if (key === 'Enter') {\n event.preventDefault();\n updateReference(selectedBookId, true, highlightedChapter);\n return;\n }\n\n let chapterOffSet = 0;\n if (key === 'ArrowRight') {\n if (highlightedChapter < fetchEndChapter(highlightedBookId)) {\n chapterOffSet = 1;\n } else {\n event.preventDefault();\n return;\n }\n } else if (key === 'ArrowLeft') {\n if (highlightedChapter > 1) {\n chapterOffSet = -1;\n } else {\n event.preventDefault();\n return;\n }\n } else if (key === 'ArrowDown') {\n chapterOffSet = 6;\n } else if (key === 'ArrowUp') {\n chapterOffSet = -6;\n }\n if (\n highlightedChapter + chapterOffSet <= 0 ||\n highlightedChapter + chapterOffSet > fetchEndChapter(highlightedBookId)\n ) {\n setHighlightedChapter(0);\n } else if (chapterOffSet !== 0) {\n setHighlightedChapter(highlightedChapter + chapterOffSet);\n event.preventDefault();\n }\n }\n };\n\n useEffect(() => {\n if (selectedBookId === highlightedBookId) {\n if (selectedBookId === Canon.bookNumberToId(scrRef.bookNum)) {\n setHighlightedChapter(scrRef.chapterNum);\n } else {\n setHighlightedChapter(1);\n }\n } else {\n setHighlightedChapter(0);\n }\n }, [highlightedBookId, scrRef.bookNum, scrRef.chapterNum, selectedBookId]);\n\n // The purpose of these useLayoutEffects and timeout is to delay the scroll just\n // enough so that the refs are defined and available when they are used after the timeout\n useLayoutEffect(() => {\n setIsContentOpenDelayed(isContentOpen);\n }, [isContentOpen]);\n\n useLayoutEffect(() => {\n const scrollTimeout = setTimeout(() => {\n if (isContentOpenDelayed && contentRef.current && menuItemRef.current) {\n const menuItemOffsetTop = menuItemRef.current.offsetTop;\n const scrollPosition = menuItemOffsetTop - SCROLL_OFFSET;\n contentRef.current.scrollTo({ top: scrollPosition, behavior: 'instant' });\n }\n }, 10);\n return () => {\n clearTimeout(scrollTimeout);\n };\n }, [isContentOpenDelayed]);\n\n return (\n
    \n \n \n {\n setSelectedBookId(Canon.bookNumberToId(scrRef.bookNum));\n setHighlightedBookId(Canon.bookNumberToId(scrRef.bookNum));\n setHighlightedChapter(scrRef.chapterNum > 0 ? scrRef.chapterNum : 0);\n setIsContentOpen(true);\n inputRef.current.focus();\n }}\n onFocus={() => {\n // Radix thinks we want to close because the input is being focused. Prevent that\n shouldPreventAutoClosing.current = true;\n }}\n handleSubmit={handleInputSubmit}\n placeholder={`${Canon.bookNumberToEnglishName(scrRef.bookNum)} ${scrRef.chapterNum}:${scrRef.verseNum}`}\n />\n \n \n console.log('sorting')}\n handleLocationHistory={() => console.log('location history')}\n handleBookmarks={() => console.log('bookmarks')}\n />\n {BOOK_TYPE_ARRAY.map(\n (bookType, bookTypeIndex) =>\n fetchFilteredBooks(bookType).length > 0 && (\n
    \n \n {BOOK_TYPE_LABELS[bookType]}\n \n\n {fetchFilteredBooks(bookType).map((bookId) => (\n
    \n updateReference(bookId, false)}\n isSelected={selectedBookId === bookId}\n handleHighlightBook={() => setHighlightedBookId(bookId)}\n handleKeyDown={handleKeyDownMenuItem}\n bookType={bookType}\n ref={(element: HTMLDivElement) => {\n if (selectedBookId === bookId) menuItemRef.current = element;\n }}\n >\n {\n setHighlightedChapter(chapterNumber);\n }}\n />\n \n
    \n ))}\n {BOOK_TYPE_ARRAY.length - 1 !== bookTypeIndex ? (\n \n ) : undefined}\n
    \n ),\n )}\n \n
    \n
    \n );\n}\n\nexport default BookChapterControl;\n","import React from 'react';\nimport { Slot } from '@radix-ui/react-slot';\nimport { cva, type VariantProps } from 'class-variance-authority';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport const buttonVariants = cva(\n 'pr-twp tw-inline-flex tw-items-center tw-justify-center tw-whitespace-nowrap tw-rounded-md tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-colors focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50',\n {\n variants: {\n variant: {\n default: 'tw-bg-primary tw-text-primary-foreground hover:tw-bg-primary/90',\n destructive: 'tw-bg-destructive tw-text-destructive-foreground hover:tw-bg-destructive/90',\n outline:\n 'tw-border tw-border-input tw-bg-background hover:tw-bg-accent hover:tw-text-accent-foreground',\n secondary: 'tw-bg-secondary tw-text-secondary-foreground hover:tw-bg-secondary/80',\n ghost: 'hover:tw-bg-accent hover:tw-text-accent-foreground',\n link: 'tw-text-primary tw-underline-offset-4 hover:tw-underline',\n },\n size: {\n default: 'tw-h-10 tw-px-4 tw-py-2',\n sm: 'tw-h-9 tw-rounded-md tw-px-3',\n lg: 'tw-h-11 tw-rounded-md tw-px-8',\n icon: 'tw-h-10 tw-w-10',\n },\n },\n defaultVariants: {\n variant: 'default',\n size: 'default',\n },\n },\n);\n\nexport interface ButtonProps\n extends React.ButtonHTMLAttributes,\n VariantProps {\n asChild?: boolean;\n}\n\nexport const Button = React.forwardRef(\n ({ className, variant, size, asChild = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'button';\n return (\n \n );\n },\n);\nButton.displayName = 'Button';\n","import React from 'react';\nimport * as LabelPrimitive from '@radix-ui/react-label';\nimport { cva, type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst labelVariants = cva(\n 'tw-text-sm tw-font-medium tw-leading-none peer-disabled:tw-cursor-not-allowed peer-disabled:tw-opacity-70',\n);\n\nexport const Label = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef & VariantProps\n>(({ className, ...props }, ref) => (\n \n));\nLabel.displayName = LabelPrimitive.Root.displayName;\n","import React from 'react';\nimport * as RadioGroupPrimitive from '@radix-ui/react-radio-group';\nimport { Circle } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst RadioGroup = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => {\n return (\n \n );\n});\nRadioGroup.displayName = RadioGroupPrimitive.Root.displayName;\n\nconst RadioGroupItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => {\n return (\n \n \n \n \n \n );\n});\nRadioGroupItem.displayName = RadioGroupPrimitive.Item.displayName;\n\nexport { RadioGroup, RadioGroupItem };\n","import React from 'react';\nimport * as PopoverPrimitive from '@radix-ui/react-popover';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Popover = PopoverPrimitive.Root;\n\nconst PopoverTrigger = PopoverPrimitive.Trigger;\n\nconst PopoverContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, align = 'center', sideOffset = 4, ...props }, ref) => (\n \n \n \n));\nPopoverContent.displayName = PopoverPrimitive.Content.displayName;\n\nexport { Popover, PopoverTrigger, PopoverContent };\n","import React from 'react';\nimport * as DialogPrimitive from '@radix-ui/react-dialog';\nimport { X } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Dialog = DialogPrimitive.Root;\n\nconst DialogTrigger = DialogPrimitive.Trigger;\n\nconst DialogPortal = DialogPrimitive.Portal;\n\nconst DialogClose = DialogPrimitive.Close;\n\nconst DialogOverlay = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nDialogOverlay.displayName = DialogPrimitive.Overlay.displayName;\n\nconst DialogContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, ...props }, ref) => (\n \n \n \n {children}\n \n \n Close\n \n \n \n));\nDialogContent.displayName = DialogPrimitive.Content.displayName;\n\nfunction DialogHeader({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nDialogHeader.displayName = 'DialogHeader';\n\nfunction DialogFooter({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nDialogFooter.displayName = 'DialogFooter';\n\nconst DialogTitle = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nDialogTitle.displayName = DialogPrimitive.Title.displayName;\n\nconst DialogDescription = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nDialogDescription.displayName = DialogPrimitive.Description.displayName;\n\nexport {\n Dialog,\n DialogPortal,\n DialogOverlay,\n DialogClose,\n DialogTrigger,\n DialogContent,\n DialogHeader,\n DialogFooter,\n DialogTitle,\n DialogDescription,\n};\n","import React from 'react';\nimport { type DialogProps } from '@radix-ui/react-dialog';\nimport { Command as CommandPrimitive } from 'cmdk';\nimport { Search } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Dialog, DialogContent } from '@/components/shadcn-ui/dialog';\n\nconst Command = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nCommand.displayName = CommandPrimitive.displayName;\n\ninterface CommandDialogProps extends DialogProps {}\n\nfunction CommandDialog({ children, ...props }: CommandDialogProps) {\n return (\n \n \n \n {children}\n \n \n \n );\n}\n\nconst CommandInput = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n
    \n \n \n
    \n));\n\nCommandInput.displayName = CommandPrimitive.Input.displayName;\n\nconst CommandList = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\n\nCommandList.displayName = CommandPrimitive.List.displayName;\n\nconst CommandEmpty = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>((props, ref) => (\n \n));\n\nCommandEmpty.displayName = CommandPrimitive.Empty.displayName;\n\nconst CommandGroup = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\n\nCommandGroup.displayName = CommandPrimitive.Group.displayName;\n\nconst CommandSeparator = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nCommandSeparator.displayName = CommandPrimitive.Separator.displayName;\n\nconst CommandItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\n\nCommandItem.displayName = CommandPrimitive.Item.displayName;\n\nfunction CommandShortcut({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nCommandShortcut.displayName = 'CommandShortcut';\n\nexport {\n Command,\n CommandDialog,\n CommandInput,\n CommandList,\n CommandEmpty,\n CommandGroup,\n CommandItem,\n CommandShortcut,\n CommandSeparator,\n};\n","import { useState } from 'react';\nimport { Check, ChevronsUpDown } from 'lucide-react';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport { Popover, PopoverContent, PopoverTrigger } from '@/components/shadcn-ui/popover';\nimport {\n Command,\n CommandEmpty,\n CommandInput,\n CommandItem,\n CommandList,\n} from '@/components/shadcn-ui/command';\nimport { PopoverProps } from '@radix-ui/react-popover';\n\nexport type ComboBoxLabelOption = { label: string };\nexport type ComboBoxOption = string | number | ComboBoxLabelOption;\n\nexport type ComboBoxProps = {\n /** Optional unique identifier */\n id?: string;\n /** Text label title for combobox */\n /** List of available options for the dropdown menu */\n options?: readonly T[];\n /** @deprecated 3 December 2024. Renamed to {@link buttonClassName} */\n className?: string;\n /** Additional css classes to help with unique styling of the combo box button */\n buttonClassName?: string;\n /** Additional css classes to help with unique styling of the combo box popover */\n popoverContentClassName?: string;\n /**\n * The selected value that the combo box currently holds. Must be shallow equal to one of the\n * options entries.\n */\n value?: T;\n /** Triggers when content of textfield is changed */\n onChange?: (newValue: T) => void;\n /** Used to determine the string value for a given option. */\n getOptionLabel?: (option: ComboBoxOption) => string;\n /** Text displayed on button if `value` is undefined */\n buttonPlaceholder?: string;\n /** Placeholder text for text field */\n textPlaceholder?: string;\n /** Text to display when no options match input */\n commandEmptyMessage?: string;\n /** Variant of button */\n buttonVariant?: ButtonProps['variant'];\n /** Text direction ltr or rtl */\n dir?: Direction;\n /** Optional boolean to set if trigger should be disabled */\n isDisabled?: boolean;\n} & PopoverProps;\n\ntype Direction = 'ltr' | 'rtl';\n\nfunction getOptionLabelDefault(option: ComboBoxOption): string {\n if (typeof option === 'string') {\n return option;\n }\n if (typeof option === 'number') {\n return option.toString();\n }\n return option.label;\n}\n\n/**\n * Autocomplete input and command palette with a list of suggestions.\n *\n * Thanks to Shadcn for heavy inspiration and documentation\n * https://ui.shadcn.com/docs/components/combobox\n */\nfunction ComboBox({\n id,\n options = [],\n buttonClassName,\n popoverContentClassName,\n value,\n onChange = () => {},\n getOptionLabel = getOptionLabelDefault,\n buttonPlaceholder = '',\n textPlaceholder = '',\n commandEmptyMessage = 'No option found',\n buttonVariant = 'outline',\n dir = 'ltr',\n isDisabled = false,\n ...props\n}: ComboBoxProps) {\n const [open, setOpen] = useState(false);\n\n return (\n \n \n \n \n {value ? getOptionLabel(value) : buttonPlaceholder}\n \n \n \n \n \n \n \n {commandEmptyMessage}\n \n {options.map((option) => (\n {\n onChange(option);\n setOpen(false);\n }}\n >\n \n {getOptionLabel(option)}\n \n ))}\n \n \n \n \n );\n}\n\nexport default ComboBox;\n","import { useMemo } from 'react';\nimport ComboBox from '@/components/basics/combo-box.component';\nimport { Label } from '@/components/shadcn-ui/label';\n\nexport type ChapterRangeSelectorProps = {\n startChapter: number;\n endChapter: number;\n handleSelectStartChapter: (chapter: number) => void;\n handleSelectEndChapter: (chapter: number) => void;\n isDisabled?: boolean;\n chapterCount: number;\n};\n\nexport default function ChapterRangeSelector({\n startChapter,\n endChapter,\n handleSelectStartChapter,\n handleSelectEndChapter,\n isDisabled = false,\n chapterCount,\n}: ChapterRangeSelectorProps) {\n const chapterOptions = useMemo(\n () => Array.from({ length: chapterCount }, (_, index) => index + 1),\n [chapterCount],\n );\n\n const onChangeStartChapter = (value: number) => {\n handleSelectStartChapter(value);\n if (value > endChapter) {\n handleSelectEndChapter(value);\n }\n };\n\n const onChangeEndChapter = (value: number) => {\n handleSelectEndChapter(value);\n if (value < startChapter) {\n handleSelectStartChapter(value);\n }\n };\n\n return (\n <>\n \n option.toString()}\n value={startChapter}\n />\n\n \n option.toString()}\n value={endChapter}\n />\n \n );\n}\n","import { Button } from '@/components/shadcn-ui/button';\nimport { Label } from '@/components/shadcn-ui/label';\nimport { RadioGroup, RadioGroupItem } from '@/components/shadcn-ui/radio-group';\nimport { Canon } from '@sillsdev/scripture';\nimport { LocalizedStringValue } from 'platform-bible-utils';\nimport { useState } from 'react';\nimport ChapterRangeSelector, {\n ChapterRangeSelectorProps,\n} from '../basics/chapter-range-selector.component';\n\nexport enum BookSelectionMode {\n CURRENT_BOOK = 'current book',\n CHOOSE_BOOKS = 'choose books',\n}\n\n/**\n * Object containing all keys used for localization in this component. If you're using this\n * component in an extension, you can pass it into the useLocalizedStrings hook to easily obtain the\n * localized strings and pass them into the localizedStrings prop of this component\n */\nexport const BOOK_SELECTOR_STRING_KEYS = Object.freeze([\n '%webView_bookSelector_currentBook%',\n '%webView_bookSelector_choose%',\n '%webView_bookSelector_chooseBooks%',\n] as const);\n\nexport type BookSelectorLocalizedStrings = {\n [localizedInventoryKey in (typeof BOOK_SELECTOR_STRING_KEYS)[number]]?: LocalizedStringValue;\n};\n\n/**\n * Gets the localized value for the provided key\n *\n * @param strings Object containing localized string\n * @param key Key for a localized string\n * @returns The localized value for the provided key, if available. Returns the key if no localized\n * value is available\n */\nconst localizeString = (\n strings: BookSelectorLocalizedStrings,\n key: keyof BookSelectorLocalizedStrings,\n) => {\n return strings[key] ?? key;\n};\n\ntype BookSelectorProps = ChapterRangeSelectorProps & {\n handleBookSelectionModeChange: (newMode: BookSelectionMode) => void;\n currentBookName: string;\n onSelectBooks: () => void;\n selectedBookIds: string[];\n localizedStrings: BookSelectorLocalizedStrings;\n};\n\nexport default function BookSelector({\n handleBookSelectionModeChange,\n currentBookName,\n onSelectBooks,\n selectedBookIds,\n chapterCount,\n endChapter,\n handleSelectEndChapter,\n startChapter,\n handleSelectStartChapter,\n localizedStrings,\n}: BookSelectorProps) {\n const currentBookText = localizeString(localizedStrings, '%webView_bookSelector_currentBook%');\n const chooseText = localizeString(localizedStrings, '%webView_bookSelector_choose%');\n const chooseBooksText = localizeString(localizedStrings, '%webView_bookSelector_chooseBooks%');\n\n const [bookSelectionMode, setBookSelectionMode] = useState(\n BookSelectionMode.CURRENT_BOOK,\n );\n\n const onSelectionModeChange = (newMode: BookSelectionMode) => {\n setBookSelectionMode(newMode);\n handleBookSelectionModeChange(newMode);\n };\n\n return (\n onSelectionModeChange(value as BookSelectionMode)}\n >\n
    \n
    \n
    \n \n \n
    \n \n
    \n \n
    \n
    \n
    \n
    \n \n \n
    \n \n onSelectBooks()}\n >\n {chooseText}\n \n
    \n
    \n \n );\n}\n","import { DropdownMenuTrigger } from '@radix-ui/react-dropdown-menu';\nimport { FilterIcon } from 'lucide-react';\nimport { Table } from '@tanstack/react-table';\n\nimport { Button } from '@/components/shadcn-ui/button';\nimport {\n DropdownMenu,\n DropdownMenuCheckboxItem,\n DropdownMenuContent,\n DropdownMenuLabel,\n DropdownMenuSeparator,\n} from '@/components/shadcn-ui/dropdown-menu';\n\ninterface DataTableViewOptionsProps {\n table: Table;\n}\n\nfunction DataTableViewOptions({ table }: DataTableViewOptionsProps) {\n return (\n \n \n \n \n \n Toggle columns\n \n {table\n .getAllColumns()\n .filter((column) => column.getCanHide())\n .map((column) => {\n return (\n column.toggleVisibility(!!value)}\n >\n {column.id}\n \n );\n })}\n \n \n );\n}\n\nexport default DataTableViewOptions;\n","import React from 'react';\nimport * as SelectPrimitive from '@radix-ui/react-select';\nimport { Check, ChevronDown, ChevronUp } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Select = SelectPrimitive.Root;\n\nconst SelectGroup = SelectPrimitive.Group;\n\nconst SelectValue = SelectPrimitive.Value;\n\nconst SelectTrigger = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, ...props }, ref) => (\n span]:tw-line-clamp-1',\n className,\n )}\n {...props}\n >\n {children}\n \n \n \n \n));\nSelectTrigger.displayName = SelectPrimitive.Trigger.displayName;\n\nconst SelectScrollUpButton = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n));\nSelectScrollUpButton.displayName = SelectPrimitive.ScrollUpButton.displayName;\n\nconst SelectScrollDownButton = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n));\nSelectScrollDownButton.displayName = SelectPrimitive.ScrollDownButton.displayName;\n\nconst SelectContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, position = 'popper', ...props }, ref) => (\n \n \n \n \n {children}\n \n \n \n \n));\nSelectContent.displayName = SelectPrimitive.Content.displayName;\n\nconst SelectLabel = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSelectLabel.displayName = SelectPrimitive.Label.displayName;\n\nconst SelectItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, ...props }, ref) => (\n \n \n \n \n \n \n\n {children}\n \n));\nSelectItem.displayName = SelectPrimitive.Item.displayName;\n\nconst SelectSeparator = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSelectSeparator.displayName = SelectPrimitive.Separator.displayName;\n\nexport {\n Select,\n SelectGroup,\n SelectValue,\n SelectTrigger,\n SelectContent,\n SelectLabel,\n SelectItem,\n SelectSeparator,\n SelectScrollUpButton,\n SelectScrollDownButton,\n};\n","import { ChevronLeftIcon, ChevronRightIcon, ArrowLeftIcon, ArrowRightIcon } from 'lucide-react';\nimport { Table } from '@tanstack/react-table';\n\nimport { Button } from '@/components/shadcn-ui/button';\nimport {\n Select,\n SelectContent,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\n\ninterface DataTablePaginationProps {\n table: Table;\n}\n\nfunction DataTablePagination({ table }: DataTablePaginationProps) {\n return (\n
    \n
    \n
    \n {table.getFilteredSelectedRowModel().rows.length} of{' '}\n {table.getFilteredRowModel().rows.length} row(s) selected\n
    \n
    \n

    Rows per page

    \n {\n table.setPageSize(Number(value));\n }}\n >\n \n \n \n \n {[10, 20, 30, 40, 50].map((pageSize) => (\n \n {pageSize}\n \n ))}\n \n \n
    \n
    \n Page {table.getState().pagination.pageIndex + 1} of {table.getPageCount()}\n
    \n
    \n table.setPageIndex(0)}\n disabled={!table.getCanPreviousPage()}\n >\n Go to first page\n \n \n table.previousPage()}\n disabled={!table.getCanPreviousPage()}\n >\n Go to previous page\n \n \n table.nextPage()}\n disabled={!table.getCanNextPage()}\n >\n Go to next page\n \n \n table.setPageIndex(table.getPageCount() - 1)}\n disabled={!table.getCanNextPage()}\n >\n Go to last page\n \n \n
    \n
    \n
    \n );\n}\n\nexport default DataTablePagination;\n","import React from 'react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Table = React.forwardRef<\n HTMLTableElement,\n React.HTMLAttributes & { stickyHeader?: boolean }\n>(({ className, stickyHeader, ...props }, ref) => (\n
    \n \n
    \n));\nTable.displayName = 'Table';\n\nconst TableHeader = React.forwardRef<\n HTMLTableSectionElement,\n React.HTMLAttributes & { stickyHeader?: boolean }\n>(({ className, stickyHeader, ...props }, ref) => (\n \n));\nTableHeader.displayName = 'TableHeader';\n\nconst TableBody = React.forwardRef<\n HTMLTableSectionElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableBody.displayName = 'TableBody';\n\nconst TableFooter = React.forwardRef<\n HTMLTableSectionElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n tr]:last:tw-border-b-0', className)}\n {...props}\n />\n));\nTableFooter.displayName = 'TableFooter';\n\nconst TableRow = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nTableRow.displayName = 'TableRow';\n\nconst TableHead = React.forwardRef<\n HTMLTableCellElement,\n React.ThHTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableHead.displayName = 'TableHead';\n\nconst TableCell = React.forwardRef<\n HTMLTableCellElement,\n React.TdHTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableCell.displayName = 'TableCell';\n\nconst TableCaption = React.forwardRef<\n HTMLTableCaptionElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableCaption.displayName = 'TableCaption';\n\nexport { Table, TableHeader, TableBody, TableFooter, TableHead, TableRow, TableCell, TableCaption };\n","import { useState } from 'react';\n\nimport {\n ColumnFiltersState,\n flexRender,\n getCoreRowModel,\n getFilteredRowModel,\n getPaginationRowModel,\n getSortedRowModel,\n SortingState,\n ColumnDef as TSColumnDef,\n Row as TSRow,\n RowSelectionState as TSRowSelectionState,\n SortDirection as TSSortDirection,\n Table as TSTable,\n useReactTable,\n VisibilityState,\n} from '@tanstack/react-table';\n\nimport DataTableViewOptions from '@/components/advanced/data-table/data-table-column-toggle.component';\nimport DataTablePagination from '@/components/advanced/data-table/data-table-pagination.component';\nimport { Button } from '@/components/shadcn-ui/button';\nimport {\n Table,\n TableBody,\n TableCell,\n TableHead,\n TableHeader,\n TableRow,\n} from '@/components/shadcn-ui/table';\n\nexport type ColumnDef = TSColumnDef;\nexport type RowContents = TSRow;\nexport type TableContents = TSTable;\nexport type SortDirection = TSSortDirection;\nexport type RowSelectionState = TSRowSelectionState;\n\ninterface DataTableProps {\n columns: ColumnDef[];\n data: TData[];\n enablePagination?: boolean;\n showPaginationControls?: boolean;\n showColumnVisibilityControls?: boolean;\n stickyHeader?: boolean;\n onRowClickHandler?: (row: RowContents, table: TableContents) => void;\n}\n\n/**\n * Feature-rich table component that infuses our basic shadcn-based Table component with features\n * from TanStack's React Table library\n */\nfunction DataTable({\n columns,\n data,\n enablePagination = false,\n showPaginationControls = false,\n showColumnVisibilityControls = false,\n stickyHeader = false,\n onRowClickHandler = () => {},\n}: DataTableProps) {\n const [sorting, setSorting] = useState([]);\n const [columnFilters, setColumnFilters] = useState([]);\n const [columnVisibility, setColumnVisibility] = useState({});\n const [rowSelection, setRowSelection] = useState({});\n\n const table = useReactTable({\n data,\n columns,\n getCoreRowModel: getCoreRowModel(),\n ...(enablePagination && { getPaginationRowModel: getPaginationRowModel() }),\n onSortingChange: setSorting,\n getSortedRowModel: getSortedRowModel(),\n onColumnFiltersChange: setColumnFilters,\n getFilteredRowModel: getFilteredRowModel(),\n onColumnVisibilityChange: setColumnVisibility,\n onRowSelectionChange: setRowSelection,\n state: {\n sorting,\n columnFilters,\n columnVisibility,\n rowSelection,\n },\n });\n\n return (\n
    \n {showColumnVisibilityControls && }\n \n \n {table.getHeaderGroups().map((headerGroup) => (\n \n {headerGroup.headers.map((header) => {\n return (\n \n {header.isPlaceholder\n ? undefined\n : flexRender(header.column.columnDef.header, header.getContext())}\n \n );\n })}\n \n ))}\n \n \n {table.getRowModel().rows?.length ? (\n table.getRowModel().rows.map((row) => (\n onRowClickHandler(row, table)}\n key={row.id}\n data-state={row.getIsSelected() && 'selected'}\n >\n {row.getVisibleCells().map((cell) => (\n \n {flexRender(cell.column.columnDef.cell, cell.getContext())}\n \n ))}\n \n ))\n ) : (\n \n \n No results.\n \n \n )}\n \n
    \n {enablePagination && (\n
    \n table.previousPage()}\n disabled={!table.getCanPreviousPage()}\n >\n Previous\n \n table.nextPage()}\n disabled={!table.getCanNextPage()}\n >\n Next\n \n
    \n )}\n {enablePagination && showPaginationControls && }\n
    \n );\n}\n\nexport default DataTable;\n","import {\n Table,\n TableBody,\n TableCell,\n TableHead,\n TableHeader,\n TableRow,\n} from '@/components/shadcn-ui/table';\nimport { Canon } from '@sillsdev/scripture';\nimport { deepEqual, LanguageStrings, ScriptureReference } from 'platform-bible-utils';\nimport { useMemo } from 'react';\nimport { InventoryItemOccurrence } from './inventory-utils';\n\n/** Props for the OccurrencesTable component */\ntype OccurrencesTableProps = {\n /** Data that contains scriptures references and snippets of scripture */\n occurrenceData: InventoryItemOccurrence[];\n /** Callback function that is executed when the scripture reference is changed */\n setScriptureReference: (scriptureReference: ScriptureReference) => void;\n /**\n * Object with all localized strings that the OccurrencesTable needs to work well across multiple\n * languages\n */\n localizedStrings: LanguageStrings;\n};\n\n/**\n * Table that shows occurrences of specified inventory item(s). The first column shows the related\n * scripture reference. The second column shows the snippet of scripture that contains the specified\n * inventory item\n */\nfunction OccurrencesTable({\n occurrenceData,\n setScriptureReference,\n localizedStrings,\n}: OccurrencesTableProps) {\n const referenceHeaderText =\n localizedStrings['%webView_inventory_occurrences_table_header_reference%'];\n const occurrenceHeaderText =\n localizedStrings['%webView_inventory_occurrences_table_header_occurrence%'];\n\n const occurrences: InventoryItemOccurrence[] = useMemo(() => {\n const uniqueOccurrences: InventoryItemOccurrence[] = [];\n\n occurrenceData.forEach((occurrence) => {\n if (!uniqueOccurrences.some((uniqueOccurrence) => deepEqual(uniqueOccurrence, occurrence))) {\n uniqueOccurrences.push(occurrence);\n }\n });\n\n return uniqueOccurrences;\n }, [occurrenceData]);\n\n return (\n \n \n \n {referenceHeaderText}\n {occurrenceHeaderText}\n \n \n \n {occurrences.length > 0 &&\n occurrences.map((occurrence) => (\n {\n setScriptureReference(occurrence.reference);\n }}\n >\n {`${Canon.bookNumberToEnglishName(occurrence.reference.bookNum)} ${occurrence.reference.chapterNum}:${occurrence.reference.verseNum}`}\n {occurrence.text}\n \n ))}\n \n
    \n );\n}\n\nexport default OccurrencesTable;\n","import React from 'react';\nimport * as CheckboxPrimitive from '@radix-ui/react-checkbox';\nimport { Check } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Checkbox = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n \n \n));\nCheckbox.displayName = CheckboxPrimitive.Root.displayName;\n\nexport default Checkbox;\n","import { Canon } from '@sillsdev/scripture';\nimport { ScriptureReference } from 'platform-bible-utils';\n\n/* #region Types */\n\n/**\n * Status of items that appear in inventories. 'approved' and 'unapproved' items are defined in the\n * project's `Settings.xml`. All other items are defined as 'unknown'\n */\nexport type Status = 'approved' | 'unapproved' | 'unknown';\n\n/** Occurrence of item in inventory. Primarily used by table that shows occurrences */\nexport type InventoryItemOccurrence = {\n /** Reference to scripture where the item appears */\n reference: ScriptureReference;\n /** Snippet of scripture that contains the occurrence */\n text: string;\n};\n\n/** Data structure that contains all information on an item that is shown in an inventory */\nexport type InventoryTableData = {\n /**\n * The item (e.g. a character in the characters inventory, a marker in the marker inventory) In\n * most cases the array will only have one element. In case of additional items (e.g. the\n * preceding marker in the markers check), the primary item should be stored in the first index.\n * To show additional items in the inventory, make sure to configure the `additionalItemsLabels`\n * prop for the Inventory component\n */\n items: string[];\n /** The number of times this item occurs in the selected scope */\n count: number;\n /** The status of this item (see documentation for `Status` type for more information) */\n status: Status;\n /** Occurrences of this item in the scripture text for the selected scope */\n occurrences: InventoryItemOccurrence[];\n};\n\n/* #endregion */\n\n/* #region Functions */\n\n/**\n * Splits USFM string into shorter line-like segments\n *\n * @param text A single (likely very large) USFM string\n * @returns An array containing the input text, split into shorter segments\n */\nexport const getLinesFromUSFM = (text: string) => {\n // Splits on (CR)LF, CR, \\v, \\c and \\id\n return text.split(/(?:\\r?\\n|\\r)|(?=(?:\\\\(?:v|c|id)))/g);\n};\n\n/**\n * Extracts chapter or verse number from USFM strings that start with a \\c or \\v marker\n *\n * @param text USFM string that is expected to start with \\c or \\v marker\n * @returns Chapter or verse number if one is found. Else returns 0.\n */\nexport const getNumberFromUSFM = (text: string): number | undefined => {\n // Captures all digits that follow \\v or \\c markers followed by whitespace located at the start of a string\n const regex = /^\\\\[vc]\\s+(\\d+)/;\n const match = text.match(regex);\n\n if (match) {\n return +match[1];\n }\n return undefined;\n};\n\n/**\n * Gets book ID from USFM string that starts with the \\id marker, and returns book number for it\n *\n * @param text USFM string that is expected to start with \\id marker\n * @returns Book number corresponding to the \\id marker in the input text. Returns 0 if no marker is\n * found or the marker is not valid\n */\nexport const getBookNumFromId = (text: string): number => {\n // Captures all digits that follow an \\id marker followed by whitespace located at the start of a string\n const match = text.match(/^\\\\id\\s+([A-Za-z]+)/);\n if (match) {\n return Canon.bookIdToNumber(match[1]);\n }\n return 0;\n};\n\n/**\n * Gets the status for an item, typically used in the Inventory component\n *\n * @param item The item for which the status is being requested\n * @param approvedItems Array of approved items, typically as defined in `Settings.xml`\n * @param unapprovedItems Array of unapproved items, typically as defined in `Settings.xml`\n * @returns The status for the specified item\n */\nexport const getStatusForItem = (\n item: string,\n approvedItems: string[],\n unapprovedItems: string[],\n): Status => {\n if (unapprovedItems.includes(item)) return 'unapproved';\n if (approvedItems.includes(item)) return 'approved';\n return 'unknown';\n};\n\n/* #endregion */\n","import React from 'react';\nimport * as TogglePrimitive from '@radix-ui/react-toggle';\nimport { cva, type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst toggleVariants = cva(\n 'pr-twp tw-inline-flex tw-items-center tw-justify-center tw-rounded-md tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-colors hover:tw-bg-muted hover:tw-text-muted-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50 data-[state=on]:tw-bg-accent data-[state=on]:tw-text-accent-foreground',\n {\n variants: {\n variant: {\n default: 'tw-bg-transparent',\n outline:\n 'tw-border tw-border-input tw-bg-transparent hover:tw-bg-accent hover:tw-text-accent-foreground',\n },\n size: {\n default: 'tw-h-10 tw-px-3',\n sm: 'tw-h-9 tw-px-2.5',\n lg: 'tw-h-11 tw-px-5',\n },\n },\n defaultVariants: {\n variant: 'default',\n size: 'default',\n },\n },\n);\n\nconst Toggle = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef & VariantProps\n>(({ className, variant, size, ...props }, ref) => (\n \n));\n\nToggle.displayName = TogglePrimitive.Root.displayName;\n\nexport { Toggle, toggleVariants };\n","import React from 'react';\nimport * as ToggleGroupPrimitive from '@radix-ui/react-toggle-group';\nimport { type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { toggleVariants } from '@/components/shadcn-ui/toggle';\n\nconst ToggleGroupContext = React.createContext>({\n size: 'default',\n variant: 'default',\n});\n\nconst ToggleGroup = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef &\n VariantProps\n>(({ className, variant, size, children, ...props }, ref) => (\n \n \n {children}\n \n \n));\n\nToggleGroup.displayName = ToggleGroupPrimitive.Root.displayName;\n\nconst ToggleGroupItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef &\n VariantProps\n>(({ className, children, variant, size, ...props }, ref) => {\n const context = React.useContext(ToggleGroupContext);\n\n return (\n \n {children}\n \n );\n});\n\nToggleGroupItem.displayName = ToggleGroupPrimitive.Item.displayName;\n\nexport { ToggleGroup, ToggleGroupItem };\n","import { ColumnDef, SortDirection } from '@/components/advanced/data-table/data-table.component';\nimport { Button } from '@/components/shadcn-ui/button';\nimport { ToggleGroup, ToggleGroupItem } from '@/components/shadcn-ui/toggle-group';\nimport {\n ArrowDownIcon,\n ArrowUpDownIcon,\n ArrowUpIcon,\n CircleCheckIcon,\n CircleHelpIcon,\n CircleXIcon,\n} from 'lucide-react';\nimport { ReactNode } from 'react';\nimport { InventoryTableData, Status } from './inventory-utils';\n\n/**\n * Gets an icon that indicates the current sorting direction based on the provided input\n *\n * @param sortDirection Sorting direction. Can be ascending ('asc'), descending ('desc') or false (\n * i.e. not sorted)\n * @returns The appropriate sorting icon for the provided sorting direction\n */\nconst getSortingIcon = (sortDirection: false | SortDirection): ReactNode => {\n if (sortDirection === 'asc') {\n return ;\n }\n if (sortDirection === 'desc') {\n return ;\n }\n return ;\n};\n\n/**\n * Function that creates the item column for inventories\n *\n * @param itemLabel Localized label for the item column (e.g. 'Character', 'Repeated Word', etc.)\n * @returns Column that shows the inventory items. Should be used with the DataTable component\n */\nexport const inventoryItemColumn = (itemLabel: string): ColumnDef => {\n return {\n accessorKey: 'item',\n accessorFn: (row: InventoryTableData) => row.items[0],\n header: ({ column }) => (\n \n ),\n };\n};\n\n/**\n * Function that creates the additional item columns for inventories\n *\n * @param additionalItemLabel Localized label for the additional item column (e.g. 'Preceding\n * Marker')\n * @param additionalItemIndex Index that locates the desired item in the items array of the\n * inventory\n * @returns Column that shows additional inventory items. Should be used with the DataTable\n * component\n */\nexport const inventoryAdditionalItemColumn = (\n additionalItemLabel: string,\n additionalItemIndex: number,\n): ColumnDef => {\n return {\n accessorKey: `item${additionalItemIndex}`,\n accessorFn: (row: InventoryTableData) => row.items[additionalItemIndex],\n header: ({ column }) => (\n \n ),\n };\n};\n\n/**\n * Function that creates the count column for inventories. Should be used with the DataTable\n * component.\n *\n * @param itemLabel Localized label for the count column\n * @returns Column that shows the number of occurrences of the related inventory items\n */\nexport const inventoryCountColumn = (countLabel: string): ColumnDef => {\n return {\n accessorKey: 'count',\n header: ({ column }) => (\n
    \n \n
    \n ),\n cell: ({ row }) =>
    {row.getValue('count')}
    ,\n };\n};\n\n/**\n * Function that updates project settings when status for item(s) changes\n *\n * @param changedItems Array of items for which the status is being updated\n * @param newStatus The status that the items are being given\n * @param approvedItems Array of currently approved items\n * @param onApprovedItemsChange Callback function that stores the updated list of approved items\n * @param unapprovedItems Array of currently unapproved items\n * @param onUnapprovedItemsChange Callback function that stores the updated list of unapproved items\n */\nconst statusChangeHandler = (\n changedItems: string[],\n newStatus: Status,\n approvedItems: string[],\n onApprovedItemsChange: (items: string[]) => void,\n unapprovedItems: string[],\n onUnapprovedItemsChange: (items: string[]) => void,\n) => {\n let newApprovedItems: string[] = [...approvedItems];\n changedItems.forEach((item) => {\n if (newStatus === 'approved') {\n if (!newApprovedItems.includes(item)) {\n newApprovedItems.push(item);\n }\n } else {\n newApprovedItems = newApprovedItems.filter((validItem) => validItem !== item);\n }\n });\n onApprovedItemsChange(newApprovedItems);\n\n let newUnapprovedItems: string[] = [...unapprovedItems];\n changedItems.forEach((item) => {\n if (newStatus === 'unapproved') {\n if (!newUnapprovedItems.includes(item)) {\n newUnapprovedItems.push(item);\n }\n } else {\n newUnapprovedItems = newUnapprovedItems.filter((unapprovedItem) => unapprovedItem !== item);\n }\n });\n onUnapprovedItemsChange(newUnapprovedItems);\n};\n\n/**\n * Function that creates the status column for inventories. Should be used with the DataTable\n * component.\n *\n * @param statusLabel Localized label for the status column\n * @param approvedItems Array of approved items, typically as defined in `Settings.xml`\n * @param onApprovedItemsChange Callback function that stores the updated list of approved items\n * @param unapprovedItems Array of unapproved items, typically as defined in `Settings.xml`\n * @param onUnapprovedItemsChange Callback function that stores the updated list of unapproved items\n * @returns Column that shows the status buttons for the related inventory item. The button for the\n * current status of the item is selected\n */\nexport const inventoryStatusColumn = (\n statusLabel: string,\n approvedItems: string[],\n onApprovedItemsChange: (items: string[]) => void,\n unapprovedItems: string[],\n onUnapprovedItemsChange: (items: string[]) => void,\n): ColumnDef => {\n return {\n accessorKey: 'status',\n header: ({ column }) => {\n return (\n
    \n \n
    \n );\n },\n cell: ({ row }) => {\n const status: Status = row.getValue('status');\n const item: string = row.getValue('item');\n return (\n \n \n statusChangeHandler(\n [item],\n 'approved',\n approvedItems,\n onApprovedItemsChange,\n unapprovedItems,\n onUnapprovedItemsChange,\n )\n }\n value=\"approved\"\n >\n \n \n \n statusChangeHandler(\n [item],\n 'unapproved',\n approvedItems,\n onApprovedItemsChange,\n unapprovedItems,\n onUnapprovedItemsChange,\n )\n }\n value=\"unapproved\"\n >\n \n \n \n statusChangeHandler(\n [item],\n 'unknown',\n approvedItems,\n onApprovedItemsChange,\n unapprovedItems,\n onUnapprovedItemsChange,\n )\n }\n value=\"unknown\"\n >\n \n \n \n );\n },\n };\n};\n","import DataTable, {\n ColumnDef,\n RowContents,\n RowSelectionState,\n TableContents,\n} from '@/components/advanced/data-table/data-table.component';\nimport OccurrencesTable from '@/components/advanced/inventory/occurrences-table.component';\nimport Checkbox from '@/components/shadcn-ui/checkbox';\nimport { Input } from '@/components/shadcn-ui/input';\nimport { Label } from '@/components/shadcn-ui/label';\nimport {\n Select,\n SelectContent,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\nimport {\n deepEqual,\n LocalizedStringValue,\n ScriptureReference,\n substring,\n} from 'platform-bible-utils';\nimport { useEffect, useMemo, useState } from 'react';\nimport {\n getBookNumFromId,\n getLinesFromUSFM,\n getNumberFromUSFM,\n getStatusForItem,\n InventoryItemOccurrence,\n InventoryTableData,\n Status,\n} from './inventory-utils';\nimport { inventoryAdditionalItemColumn } from './inventory-columns';\n\n/**\n * Object containing all keys used for localization in this component. If you're using this\n * component in an extension, you can pass it into the useLocalizedStrings hook to easily obtain the\n * localized strings and pass them into the localizedStrings prop of this component\n */\nexport const INVENTORY_STRING_KEYS = Object.freeze([\n '%webView_inventory_all%',\n '%webView_inventory_approved%',\n '%webView_inventory_unapproved%',\n '%webView_inventory_unknown%',\n '%webView_inventory_scope_currentBook%',\n '%webView_inventory_scope_chapter%',\n '%webView_inventory_scope_verse%',\n '%webView_inventory_filter_text%',\n '%webView_inventory_show_additional_items%',\n '%webView_inventory_occurrences_table_header_reference%',\n '%webView_inventory_occurrences_table_header_occurrence%',\n] as const);\n\nexport type InventoryLocalizedStrings = {\n [localizedInventoryKey in (typeof INVENTORY_STRING_KEYS)[number]]?: LocalizedStringValue;\n};\n\n/** Scope of scripture that the inventory can operate on */\nexport type Scope = 'book' | 'chapter' | 'verse';\n\n/** Status values that the status filter can select from */\ntype StatusFilter = Status | 'all';\n\n/** Text labels for the inventory columns and the control components of additional inventory items */\ntype AdditionalItemsLabels = {\n checkboxText?: string;\n tableHeaders?: string[];\n};\n\n/**\n * Filters data that is shown in the DataTable section of the Inventory\n *\n * @param itemData All inventory items and their related information\n * @param statusFilter Allows filtering by status (i.e. show all items, or only items that are\n * 'approved', 'unapproved' or 'unknown')\n * @param textFilter Allows filtering by text. All items that include the filter text will be\n * selected.\n * @returns Array of items and their related information that are matched by the specified filters\n */\nconst filterItemData = (\n itemData: InventoryTableData[],\n statusFilter: StatusFilter,\n textFilter: string,\n): InventoryTableData[] => {\n let filteredItemData: InventoryTableData[] = itemData;\n\n if (statusFilter !== 'all') {\n filteredItemData = filteredItemData.filter(\n (item) =>\n (statusFilter === 'approved' && item.status === 'approved') ||\n (statusFilter === 'unapproved' && item.status === 'unapproved') ||\n (statusFilter === 'unknown' && item.status === 'unknown'),\n );\n }\n\n if (textFilter !== '')\n filteredItemData = filteredItemData.filter((item) => item.items[0].includes(textFilter));\n\n return filteredItemData;\n};\n\n/**\n * Turns array of strings into array of inventory items, along with their count and status\n *\n * @param text The source scripture text that is searched for inventory items\n * @param scriptureRef The scripture reference that the application is currently set to\n * @param approvedItems Array of approved items, typically as defined in `Settings.xml`\n * @param unapprovedItems Array of unapproved items, typically as defined in `Settings.xml`\n * @param itemRegex Regular expression that describes what items this Inventory should extract from\n * the provided scripture text\n * @returns Array of inventory items, along with their count and status\n */\nconst createTableData = (\n text: string | undefined,\n scriptureRef: ScriptureReference,\n approvedItems: string[],\n unapprovedItems: string[],\n itemRegex: RegExp,\n): InventoryTableData[] => {\n if (!text) return [];\n\n const tableData: InventoryTableData[] = [];\n\n let currentBook: number | undefined = scriptureRef.bookNum;\n let currentChapter: number | undefined = scriptureRef.chapterNum;\n let currentVerse: number | undefined = scriptureRef.verseNum;\n\n const lines = getLinesFromUSFM(text);\n\n lines.forEach((line: string) => {\n if (line.startsWith('\\\\id')) {\n currentBook = getBookNumFromId(line);\n currentChapter = 0;\n currentVerse = 0;\n }\n if (line.startsWith('\\\\c')) {\n currentChapter = getNumberFromUSFM(line);\n currentVerse = 0;\n }\n if (line.startsWith('\\\\v')) {\n currentVerse = getNumberFromUSFM(line);\n if (currentChapter === 0) {\n currentChapter = scriptureRef.chapterNum;\n }\n }\n\n let match: RegExpExecArray | undefined = itemRegex.exec(line) ?? undefined;\n while (match) {\n const items: string[] = [];\n match.forEach((item) => items.push(item));\n const itemIndex = match.index;\n const existingItem = tableData.find((tableEntry) => deepEqual(tableEntry.items, items));\n const newReference: InventoryItemOccurrence = {\n reference: {\n bookNum: currentBook !== undefined ? currentBook : -1,\n chapterNum: currentChapter !== undefined ? currentChapter : -1,\n verseNum: currentVerse !== undefined ? currentVerse : -1,\n },\n text: substring(line, Math.max(0, itemIndex - 25), Math.min(itemIndex + 25, line.length)),\n };\n if (existingItem) {\n existingItem.count += 1;\n existingItem.occurrences.push(newReference);\n } else {\n const newItem: InventoryTableData = {\n items,\n count: 1,\n status: getStatusForItem(items[0], approvedItems, unapprovedItems),\n occurrences: [newReference],\n };\n tableData.push(newItem);\n }\n\n match = itemRegex.exec(line) ?? undefined;\n }\n });\n\n return tableData;\n};\n\n/**\n * Gets the localized value for the provided key\n *\n * @param strings Object containing localized string\n * @param key Key for a localized string\n * @returns The localized value for the provided key, if available. Returns the key if no localized\n * value is available\n */\nconst localizeString = (\n strings: InventoryLocalizedStrings,\n key: keyof InventoryLocalizedStrings,\n) => {\n return strings[key] ?? key;\n};\n\n/** Props for the Inventory component */\ntype InventoryProps = {\n /** The scripture reference that the application is currently set to */\n scriptureReference: ScriptureReference;\n /** Callback function that is executed when the scripture reference is changed */\n setScriptureReference: (scriptureReference: ScriptureReference) => void;\n /**\n * Object with all localized strings that the Inventory needs to work well across multiple\n * languages. When using this component with Platform.Bible, you can import\n * `INVENTORY_STRING_KEYS` from this library, pass it in to the Platform's localization hook, and\n * pass the localized keys that are returned by the hook into this prop.\n */\n localizedStrings: InventoryLocalizedStrings;\n /**\n * The logic that finds the desired items in the source text. This can either be a Regular\n * expression that captures one or multiple items (preferred), or a custom function that builds\n * and return an InventoryDataTable[] manually. Note: In case the logic captures more than one\n * item (i.e. InventoryTableData.items has a length greater than 1), you must provide text labels\n * for the related columns and control elements to show by setting the `additionalItemsLabels`\n * prop\n */\n extractItems:\n | RegExp\n | ((\n text: string | undefined,\n scriptureRef: ScriptureReference,\n approvedItems: string[],\n unapprovedItems: string[],\n ) => InventoryTableData[]);\n /**\n * Text labels for control elements and additional column headers in case your Inventory has more\n * than one item to show (e.g. The 'Preceding Marker' in the Markers Inventory)\n */\n additionalItemsLabels?: AdditionalItemsLabels;\n /** Array of approved items, typically as defined in `Settings.xml` */\n approvedItems: string[];\n /** Array of unapproved items, typically as defined in `Settings.xml` */\n unapprovedItems: string[];\n /** The source scripture text that is searched for in inventory items */\n text: string | undefined;\n /** Scope of scripture that the inventory will operate on */\n scope: Scope;\n /** Callback function that is executed when the scope is changed from the Inventory */\n onScopeChange: (scope: Scope) => void;\n /**\n * Column definitions for the Inventory data table. The most commonly used column definitions are\n * pre-configured for your convenience and can be imported (e.g. inventoryItemColumn,\n * inventoryAdditionalItemColumn inventoryCountColumn, and inventoryStatusColumn). If you need any\n * other columns you can add these yourself\n */\n columns: ColumnDef[];\n};\n\n/** Inventory component that is used to view and control the status of provided project settings */\nexport default function Inventory({\n scriptureReference,\n setScriptureReference,\n localizedStrings,\n extractItems,\n additionalItemsLabels,\n approvedItems,\n unapprovedItems,\n text,\n scope,\n onScopeChange,\n columns,\n}: InventoryProps) {\n const allItemsText = localizeString(localizedStrings, '%webView_inventory_all%');\n const approvedItemsText = localizeString(localizedStrings, '%webView_inventory_approved%');\n const unapprovedItemsText = localizeString(localizedStrings, '%webView_inventory_unapproved%');\n const unknownItemsText = localizeString(localizedStrings, '%webView_inventory_unknown%');\n const scopeBookText = localizeString(localizedStrings, '%webView_inventory_scope_currentBook%');\n const scopeChapterText = localizeString(localizedStrings, '%webView_inventory_scope_chapter%');\n const scopeVerseText = localizeString(localizedStrings, '%webView_inventory_scope_verse%');\n const filterText = localizeString(localizedStrings, '%webView_inventory_filter_text%');\n const showAdditionalItemsText = localizeString(\n localizedStrings,\n '%webView_inventory_show_additional_items%',\n );\n\n const [showAdditionalItems, setShowAdditionalItems] = useState(false);\n const [statusFilter, setStatusFilter] = useState('all');\n const [textFilter, setTextFilter] = useState('');\n const [selectedItem, setSelectedItem] = useState([]);\n\n const tableData: InventoryTableData[] = useMemo(() => {\n if (!text) return [];\n if (extractItems instanceof RegExp)\n return createTableData(\n text,\n scriptureReference,\n approvedItems,\n unapprovedItems,\n extractItems,\n );\n return extractItems(text, scriptureReference, approvedItems, unapprovedItems);\n }, [text, extractItems, scriptureReference, approvedItems, unapprovedItems]);\n\n const reducedTableData: InventoryTableData[] = useMemo(() => {\n if (showAdditionalItems) return tableData;\n\n const newTableData: InventoryTableData[] = [];\n\n tableData.forEach((tableEntry) => {\n const firstItem = tableEntry.items[0];\n\n const existingEntry = newTableData.find(\n (newTableEntry) => newTableEntry.items[0] === firstItem,\n );\n\n if (existingEntry) {\n existingEntry.count += tableEntry.count;\n existingEntry.occurrences = existingEntry.occurrences.concat(tableEntry.occurrences);\n } else {\n newTableData.push({\n items: [firstItem],\n count: tableEntry.count,\n occurrences: tableEntry.occurrences,\n status: tableEntry.status,\n });\n }\n });\n\n return newTableData;\n }, [showAdditionalItems, tableData]);\n\n const filteredTableData: InventoryTableData[] = useMemo(() => {\n return filterItemData(reducedTableData, statusFilter, textFilter);\n }, [reducedTableData, statusFilter, textFilter]);\n\n const allColumns: ColumnDef[] = useMemo(() => {\n if (!showAdditionalItems) return columns;\n\n const numberOfAdditionalItems = additionalItemsLabels?.tableHeaders?.length;\n if (!numberOfAdditionalItems) return columns;\n\n const additionalColumns: ColumnDef[] = [];\n\n for (let index = 0; index < numberOfAdditionalItems; index++) {\n additionalColumns.push(\n inventoryAdditionalItemColumn(\n additionalItemsLabels?.tableHeaders?.[index] || 'Additional Item',\n index + 1,\n ),\n );\n }\n\n return [...additionalColumns, ...columns];\n }, [additionalItemsLabels?.tableHeaders, columns, showAdditionalItems]);\n\n useEffect(() => {\n setSelectedItem([]);\n }, [filteredTableData]);\n\n const rowClickHandler = (\n row: RowContents,\n table: TableContents,\n ) => {\n table.setRowSelection(() => {\n const newSelection: RowSelectionState = {};\n newSelection[row.index] = true;\n return newSelection;\n });\n\n setSelectedItem(row.original.items);\n };\n\n const handleScopeChange = (value: string) => {\n if (value === 'book' || value === 'chapter' || value === 'verse') {\n onScopeChange(value);\n } else {\n throw new Error(`Invalid scope value: ${value}`);\n }\n };\n\n const handleStatusFilterChange = (value: string) => {\n if (value === 'all' || value === 'approved' || value === 'unapproved' || value === 'unknown') {\n setStatusFilter(value);\n } else {\n throw new Error(`Invalid status filter value: ${value}`);\n }\n };\n\n const occurrenceData: InventoryItemOccurrence[] = useMemo(() => {\n if (reducedTableData.length === 0 || selectedItem.length === 0) return [];\n const occurrence = reducedTableData.filter((tableEntry: InventoryTableData) => {\n return deepEqual(\n showAdditionalItems ? tableEntry.items : [tableEntry.items[0]],\n selectedItem,\n );\n });\n if (occurrence.length > 1) throw new Error('Selected item is not unique');\n return occurrence[0].occurrences;\n }, [selectedItem, showAdditionalItems, reducedTableData]);\n\n return (\n
    \n
    \n handleStatusFilterChange(value)}\n defaultValue={statusFilter}\n >\n \n \n \n \n {allItemsText}\n {approvedItemsText}\n {unapprovedItemsText}\n {unknownItemsText}\n \n \n \n {\n setTextFilter(event.target.value);\n }}\n />\n {additionalItemsLabels && (\n
    \n {\n setSelectedItem([]);\n setShowAdditionalItems(checked);\n }}\n />\n \n
    \n )}\n
    \n
    \n \n
    \n {occurrenceData.length > 0 && (\n
    \n \n
    \n )}\n
    \n );\n}\n","import { Input } from '@/components/shadcn-ui/input';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { useState } from 'react';\n\n/** Props for the SearchBar component. */\nexport type SearchBarProps = {\n /** Additional css classes to help with unique styling of the search bar */\n className?: string;\n /**\n * Callback fired to handle the search query when button pressed\n *\n * @param searchQuery\n */\n onSearch: (searchQuery: string) => void;\n\n /** Optional string that appears in the search bar without a search string */\n placeholder?: string;\n\n /** Optional boolean to set the input base to full width */\n isFullWidth?: boolean;\n};\n\nexport default function SearchBar({\n className,\n onSearch,\n placeholder,\n isFullWidth,\n}: SearchBarProps) {\n const [searchQuery, setSearchQuery] = useState('');\n\n const handleInputChange = (searchString: string) => {\n setSearchQuery(searchString);\n onSearch(searchString);\n };\n\n return (\n handleInputChange(e.target.value)}\n />\n );\n}\n","// adapted from: https://github.com/shadcn-ui/ui/discussions/752\n\n'use client';\n\nimport { TabsContentProps, TabsListProps, TabsTriggerProps } from '@/components/shadcn-ui/tabs';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport * as TabsPrimitive from '@radix-ui/react-tabs';\nimport React from 'react';\n\nexport type VerticalTabsProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport type LeftTabsTriggerProps = TabsTriggerProps & {\n value: string;\n ref?: React.Ref;\n};\n\nexport const VerticalTabs = React.forwardRef<\n React.ElementRef,\n VerticalTabsProps\n>(({ className, ...props }, ref) => (\n \n));\n\nVerticalTabs.displayName = TabsPrimitive.List.displayName;\n\nexport const VerticalTabsList = React.forwardRef<\n React.ElementRef,\n TabsListProps\n>(({ className, ...props }, ref) => (\n \n));\nVerticalTabsList.displayName = TabsPrimitive.List.displayName;\n\nexport const VerticalTabsTrigger = React.forwardRef<\n React.ElementRef,\n LeftTabsTriggerProps\n>(({ className, ...props }, ref) => (\n \n));\n\nexport const VerticalTabsContent = React.forwardRef<\n React.ElementRef,\n TabsContentProps\n>(({ className, ...props }, ref) => (\n \n));\nVerticalTabsContent.displayName = TabsPrimitive.Content.displayName;\n","import SearchBar from '@/components/basics/search-bar.component';\nimport {\n VerticalTabs,\n VerticalTabsContent,\n VerticalTabsList,\n VerticalTabsTrigger,\n} from '@/components/basics/tabs-vertical';\nimport { ReactNode } from 'react';\n\nexport type TabKeyValueContent = {\n key: string;\n value: string;\n content: ReactNode;\n};\n\nexport type TabNavigationContentSearchProps = {\n /** List of values and keys for each tab this component should provide */\n tabList: TabKeyValueContent[];\n\n /** Handler to run when the value of the search bar changes */\n onSearch: (searchQuery: string) => void;\n\n /** Optional placeholder for the search bar */\n searchPlaceholder?: string;\n\n /** Optional title to include in the header */\n headerTitle?: string;\n\n /** Optional flag to make the search bar appear full width */\n isSearchBarFullWidth?: boolean;\n\n /** Text direction ltr or rtl */\n direction?: 'ltr' | 'rtl';\n};\n\nexport default function TabNavigationContentSearch({\n tabList,\n onSearch,\n searchPlaceholder,\n headerTitle,\n isSearchBarFullWidth = false,\n direction = 'ltr',\n}: TabNavigationContentSearchProps) {\n return (\n
    \n
    \n {headerTitle ?

    {headerTitle}

    : ''}\n \n
    \n \n \n {tabList.map((tab) => (\n \n {tab.value}\n \n ))}\n \n {tabList.map((tab) => (\n \n {tab.content}\n \n ))}\n \n
    \n );\n}\n","import React from 'react';\nimport * as SeparatorPrimitive from '@radix-ui/react-separator';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Separator = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, orientation = 'horizontal', decorative = true, ...props }, ref) => (\n \n));\nSeparator.displayName = SeparatorPrimitive.Root.displayName;\n\nexport { Separator };\n","import React from 'react';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nfunction Skeleton({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\n\nexport { Skeleton };\n","import React from 'react';\nimport * as TooltipPrimitive from '@radix-ui/react-tooltip';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst TooltipProvider = TooltipPrimitive.Provider;\n\nconst Tooltip = TooltipPrimitive.Root;\n\nconst TooltipTrigger = TooltipPrimitive.Trigger;\n\nconst TooltipContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, sideOffset = 4, ...props }, ref) => (\n \n));\nTooltipContent.displayName = TooltipPrimitive.Content.displayName;\n\nexport { Tooltip, TooltipTrigger, TooltipContent, TooltipProvider };\n","import React from 'react';\nimport { Slot } from '@radix-ui/react-slot';\nimport { VariantProps, cva } from 'class-variance-authority';\nimport { PanelLeft } from 'lucide-react';\n\nimport { Button } from '@/components/shadcn-ui/button';\nimport { Input } from '@/components/shadcn-ui/input';\nimport { Separator } from '@/components/shadcn-ui/separator';\nimport { Skeleton } from '@/components/shadcn-ui/skeleton';\nimport {\n Tooltip,\n TooltipContent,\n TooltipProvider,\n TooltipTrigger,\n} from '@/components/shadcn-ui/tooltip';\nimport { cn } from '@/utils/shadcn-ui.util';\n\n/**\n * Changes from the original code from Shadcn- Removed uses of useIsMobile, Sheet, and SheetContent.\n * Also removed the parts setting COOKIES.\n */\n\nconst SIDEBAR_WIDTH = '16rem';\nconst SIDEBAR_WIDTH_ICON = '3rem';\nconst SIDEBAR_KEYBOARD_SHORTCUT = 'b';\n\ntype SidebarContextProps = {\n state: 'expanded' | 'collapsed';\n open: boolean;\n setOpen: (open: boolean) => void;\n toggleSidebar: () => void;\n};\n\nconst SidebarContext = React.createContext(undefined);\n\nfunction useSidebar() {\n const context = React.useContext(SidebarContext);\n if (!context) {\n throw new Error('useSidebar must be used within a SidebarProvider.');\n }\n\n return context;\n}\n\nconst SidebarProvider = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & {\n defaultOpen?: boolean;\n open?: boolean;\n onOpenChange?: (open: boolean) => void;\n }\n>(\n (\n {\n defaultOpen = true,\n open: openProp,\n onOpenChange: setOpenProp,\n className,\n style,\n children,\n ...props\n },\n ref,\n ) => {\n // This is the internal state of the sidebar.\n // We use openProp and setOpenProp for control from outside the component.\n const [_open, _setOpen] = React.useState(defaultOpen);\n const isOpen = openProp ?? _open;\n const setOpen = React.useCallback(\n (value: boolean | ((value: boolean) => boolean)) => {\n const openState = typeof value === 'function' ? value(isOpen) : value;\n if (setOpenProp) {\n setOpenProp(openState);\n } else {\n _setOpen(openState);\n }\n },\n [setOpenProp, isOpen],\n );\n\n // Helper to toggle the sidebar.\n const toggleSidebar = React.useCallback(() => {\n return setOpen((open) => !open);\n }, [setOpen]);\n\n // Adds a keyboard shortcut to toggle the sidebar.\n React.useEffect(() => {\n const handleKeyDown = (event: KeyboardEvent) => {\n if (event.key === SIDEBAR_KEYBOARD_SHORTCUT && (event.metaKey || event.ctrlKey)) {\n event.preventDefault();\n toggleSidebar();\n }\n };\n\n window.addEventListener('keydown', handleKeyDown);\n return () => window.removeEventListener('keydown', handleKeyDown);\n }, [toggleSidebar]);\n\n // We add a state so that we can do data-state=\"expanded\" or \"collapsed\".\n // This makes it easier to style the sidebar with Tailwind classes.\n const state = isOpen ? 'expanded' : 'collapsed';\n\n const contextValue = React.useMemo(\n () => ({\n state,\n open: isOpen,\n setOpen,\n toggleSidebar,\n }),\n [state, isOpen, setOpen, toggleSidebar],\n );\n\n return (\n \n \n \n {children}\n
    \n \n \n );\n },\n);\nSidebarProvider.displayName = 'SidebarProvider';\n\nconst Sidebar = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & {\n side?: 'left' | 'right';\n variant?: 'sidebar' | 'floating' | 'inset';\n collapsible?: 'offcanvas' | 'icon' | 'none';\n }\n>(\n (\n {\n side = 'left',\n variant = 'sidebar',\n collapsible = 'offcanvas',\n className,\n children,\n ...props\n },\n ref,\n ) => {\n const { state } = useSidebar();\n\n if (collapsible === 'none') {\n return (\n \n {children}\n
    \n );\n }\n\n return (\n \n {/* This is what handles the sidebar gap on desktop */}\n \n \n \n {children}\n
    \n
    \n
    \n );\n },\n);\nSidebar.displayName = 'Sidebar';\n\nconst SidebarTrigger = React.forwardRef<\n React.ElementRef,\n React.ComponentProps\n>(({ className, onClick, ...props }, ref) => {\n const { toggleSidebar } = useSidebar();\n\n return (\n {\n onClick?.(event);\n toggleSidebar();\n }}\n {...props}\n >\n \n Toggle Sidebar\n \n );\n});\nSidebarTrigger.displayName = 'SidebarTrigger';\n\nconst SidebarRail = React.forwardRef>(\n ({ className, ...props }, ref) => {\n const { toggleSidebar } = useSidebar();\n\n return (\n \n );\n },\n);\nSidebarRail.displayName = 'SidebarRail';\n\nconst SidebarInset = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarInset.displayName = 'SidebarInset';\n\nconst SidebarInput = React.forwardRef<\n React.ElementRef,\n React.ComponentProps\n>(({ className, ...props }, ref) => {\n return (\n \n );\n});\nSidebarInput.displayName = 'SidebarInput';\n\nconst SidebarHeader = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarHeader.displayName = 'SidebarHeader';\n\nconst SidebarFooter = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarFooter.displayName = 'SidebarFooter';\n\nconst SidebarSeparator = React.forwardRef<\n React.ElementRef,\n React.ComponentProps\n>(({ className, ...props }, ref) => {\n return (\n \n );\n});\nSidebarSeparator.displayName = 'SidebarSeparator';\n\nconst SidebarContent = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarContent.displayName = 'SidebarContent';\n\nconst SidebarGroup = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarGroup.displayName = 'SidebarGroup';\n\nconst SidebarGroupLabel = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & { asChild?: boolean }\n>(({ className, asChild = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'div';\n\n return (\n svg]:tw-size-4 [&>svg]:tw-shrink-0',\n 'group-data-[collapsible=icon]:tw--mt-8 group-data-[collapsible=icon]:tw-opacity-0',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarGroupLabel.displayName = 'SidebarGroupLabel';\n\nconst SidebarGroupAction = React.forwardRef<\n HTMLButtonElement,\n React.ComponentProps<'button'> & { asChild?: boolean }\n>(({ className, asChild = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'button';\n\n return (\n svg]:tw-size-4 [&>svg]:tw-shrink-0',\n // Increases the hit area of the button on mobile.\n 'after:tw-absolute after:tw--inset-2 after:md:tw-hidden',\n 'group-data-[collapsible=icon]:tw-hidden',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarGroupAction.displayName = 'SidebarGroupAction';\n\nconst SidebarGroupContent = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarGroupContent.displayName = 'SidebarGroupContent';\n\nconst SidebarMenu = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenu.displayName = 'SidebarMenu';\n\nconst SidebarMenuItem = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenuItem.displayName = 'SidebarMenuItem';\n\nconst sidebarMenuButtonVariants = cva(\n // Removed data-[active=true]:tw-bg-sidebar-accent\n 'tw-peer/menu-button tw-flex tw-w-full tw-items-center tw-gap-2 tw-overflow-hidden tw-rounded-md tw-p-2 tw-text-left tw-text-sm tw-outline-none tw-ring-sidebar-ring tw-transition-[width,height,padding] hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground focus-visible:tw-ring-2 active:tw-bg-sidebar-accent active:tw-text-sidebar-accent-foreground disabled:tw-pointer-events-none disabled:tw-opacity-50 tw-group-has-[[data-sidebar=menu-action]]/menu-item:pr-8 aria-disabled:tw-pointer-events-none aria-disabled:tw-opacity-50 data-[active=true]:tw-font-medium data-[active=true]:tw-text-sidebar-accent-foreground data-[state=open]:hover:tw-bg-sidebar-accent data-[state=open]:hover:tw-text-sidebar-accent-foreground group-data-[collapsible=icon]:tw-!size-8 group-data-[collapsible=icon]:tw-!p-2 [&>span:last-child]:tw-truncate [&>svg]:tw-size-4 [&>svg]:tw-shrink-0',\n {\n variants: {\n variant: {\n default: 'hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground',\n outline:\n 'tw-bg-background tw-shadow-[0_0_0_1px_hsl(var(--sidebar-border))] hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground hover:tw-shadow-[0_0_0_1px_hsl(var(--sidebar-accent))]',\n },\n size: {\n default: 'tw-h-8 tw-text-sm',\n sm: 'tw-h-7 tw-text-xs',\n lg: 'tw-h-12 tw-text-sm group-data-[collapsible=icon]:tw-!p-0',\n },\n },\n defaultVariants: {\n variant: 'default',\n size: 'default',\n },\n },\n);\n\nconst SidebarMenuButton = React.forwardRef<\n HTMLButtonElement,\n React.ComponentProps<'button'> & {\n asChild?: boolean;\n isActive?: boolean;\n tooltip?: string | React.ComponentProps;\n } & VariantProps\n>(\n (\n {\n asChild = false,\n isActive = false,\n variant = 'default',\n size = 'default',\n tooltip,\n className,\n ...props\n },\n ref,\n ) => {\n const Comp = asChild ? Slot : 'button';\n const { state } = useSidebar();\n\n const button = (\n \n );\n\n if (!tooltip) {\n return button;\n }\n\n if (typeof tooltip === 'string') {\n // eslint-disable-next-line no-param-reassign\n tooltip = {\n children: tooltip,\n };\n }\n\n return (\n \n {button}\n \n );\n },\n);\nSidebarMenuButton.displayName = 'SidebarMenuButton';\n\nconst SidebarMenuAction = React.forwardRef<\n HTMLButtonElement,\n React.ComponentProps<'button'> & {\n asChild?: boolean;\n showOnHover?: boolean;\n }\n>(({ className, asChild = false, showOnHover = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'button';\n\n return (\n svg]:tw-size-4 [&>svg]:tw-shrink-0',\n // Increases the hit area of the button on mobile.\n 'after:tw-absolute after:tw--inset-2 after:md:tw-hidden',\n 'tw-peer-data-[size=sm]/menu-button:top-1',\n 'tw-peer-data-[size=default]/menu-button:top-1.5',\n 'tw-peer-data-[size=lg]/menu-button:top-2.5',\n 'group-data-[collapsible=icon]:tw-hidden',\n showOnHover &&\n 'tw-group-focus-within/menu-item:opacity-100 tw-group-hover/menu-item:opacity-100 tw-peer-data-[active=true]/menu-button:text-sidebar-accent-foreground data-[state=open]:tw-opacity-100 md:tw-opacity-0',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarMenuAction.displayName = 'SidebarMenuAction';\n\nconst SidebarMenuBadge = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenuBadge.displayName = 'SidebarMenuBadge';\n\nconst SidebarMenuSkeleton = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & {\n showIcon?: boolean;\n }\n>(({ className, showIcon = false, ...props }, ref) => {\n // Random width between 50 to 90%.\n const width = React.useMemo(() => {\n return `${Math.floor(Math.random() * 40) + 50}%`;\n }, []);\n\n return (\n \n {showIcon && (\n \n )}\n \n
    \n );\n});\nSidebarMenuSkeleton.displayName = 'SidebarMenuSkeleton';\n\nconst SidebarMenuSub = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenuSub.displayName = 'SidebarMenuSub';\n\nconst SidebarMenuSubItem = React.forwardRef>(\n ({ ...props }, ref) =>
  • ,\n);\nSidebarMenuSubItem.displayName = 'SidebarMenuSubItem';\n\nconst SidebarMenuSubButton = React.forwardRef<\n HTMLAnchorElement,\n React.ComponentProps<'a'> & {\n asChild?: boolean;\n size?: 'sm' | 'md';\n isActive?: boolean;\n }\n>(({ asChild = false, size = 'md', isActive, className, ...props }, ref) => {\n const Comp = asChild ? Slot : 'a';\n\n return (\n span:last-child]:tw-truncate [&>svg]:tw-size-4 [&>svg]:tw-shrink-0 [&>svg]:tw-text-sidebar-accent-foreground',\n 'data-[active=true]:tw-bg-sidebar-accent data-[active=true]:tw-text-sidebar-accent-foreground',\n size === 'sm' && 'tw-text-xs',\n size === 'md' && 'tw-text-sm',\n 'group-data-[collapsible=icon]:tw-hidden',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarMenuSubButton.displayName = 'SidebarMenuSubButton';\n\nexport {\n Sidebar,\n SidebarContent,\n SidebarFooter,\n SidebarGroup,\n SidebarGroupAction,\n SidebarGroupContent,\n SidebarGroupLabel,\n SidebarHeader,\n SidebarInput,\n SidebarInset,\n SidebarMenu,\n SidebarMenuAction,\n SidebarMenuBadge,\n SidebarMenuButton,\n SidebarMenuItem,\n SidebarMenuSkeleton,\n SidebarMenuSub,\n SidebarMenuSubButton,\n SidebarMenuSubItem,\n SidebarProvider,\n SidebarRail,\n SidebarSeparator,\n SidebarTrigger,\n useSidebar,\n};\n","import ComboBox, { ComboBoxOption } from '@/components/basics/combo-box.component';\nimport {\n Sidebar,\n SidebarContent,\n SidebarGroup,\n SidebarGroupLabel,\n SidebarGroupContent,\n SidebarMenu,\n SidebarMenuItem,\n SidebarMenuButton,\n} from '@/components/shadcn-ui/sidebar';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { useCallback } from 'react';\n\nexport type SelectedSettingsSidebarItem = {\n label: string;\n projectId?: string;\n};\n\nexport type ProjectInfo = { projectId: string; projectName: string };\n\nexport type SettingsSidebarProps = {\n /** Optional id for testing */\n id?: string;\n\n /** Extension labels from contribution */\n extensionLabels: string[];\n\n /** Project names and ids */\n projectInfo: ProjectInfo[];\n\n /** Handler for selecting a sidebar item */\n handleSelectSidebarItem: (key: string, projectId?: string) => void;\n\n /** The current selected value in the sidebar */\n selectedSidebarItem: SelectedSettingsSidebarItem;\n\n /** Label for the group of extensions setting groups */\n extensionsSidebarGroupLabel: string;\n\n /** Label for the group of projects settings */\n projectsSidebarGroupLabel: string;\n\n /** Placeholder text for the button */\n buttonPlaceholderText: string;\n};\n\nexport default function SettingsSidebar({\n id,\n extensionLabels,\n projectInfo,\n handleSelectSidebarItem,\n selectedSidebarItem,\n extensionsSidebarGroupLabel,\n projectsSidebarGroupLabel,\n buttonPlaceholderText,\n}: SettingsSidebarProps) {\n const handleSelectItem = useCallback(\n (item: string, projectId?: string) => {\n handleSelectSidebarItem(item, projectId);\n },\n [handleSelectSidebarItem],\n );\n\n const getProjectNameFromProjectId = useCallback(\n (projectId: string) => {\n const project = projectInfo.find((info) => info.projectId === projectId);\n return project ? project.projectName : projectId;\n },\n [projectInfo],\n );\n\n const getIsActive: (label: string) => boolean = useCallback(\n (label: string) => !selectedSidebarItem.projectId && label === selectedSidebarItem.label,\n [selectedSidebarItem],\n );\n\n return (\n \n \n \n \n {extensionsSidebarGroupLabel}\n \n \n \n {extensionLabels.map((label) => (\n \n handleSelectItem(label)}\n isActive={getIsActive(label)}\n >\n {label}\n \n \n ))}\n \n \n \n \n \n {projectsSidebarGroupLabel}\n \n \n info.projectId)}\n getOptionLabel={(projectId: ComboBoxOption) => {\n // This function expects a ComboBoxOption, but we know it is a string\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n return getProjectNameFromProjectId(projectId as string);\n }}\n buttonPlaceholder={buttonPlaceholderText}\n onChange={(projectId: string) => {\n const selectedProjectName = getProjectNameFromProjectId(projectId);\n handleSelectItem(selectedProjectName, projectId);\n }}\n value={selectedSidebarItem?.projectId ?? undefined}\n />\n \n \n \n \n );\n}\n","import { SidebarInset, SidebarProvider } from '@/components/shadcn-ui/sidebar';\nimport { PropsWithChildren } from 'react';\nimport SearchBar from '@/components/basics/search-bar.component';\nimport SettingsSidebar, { SettingsSidebarProps } from './settings-sidebar.component';\n\nexport type SettingsSidebarContentSearchProps = SettingsSidebarProps &\n PropsWithChildren & {\n /** Optional id for testing */\n id?: string;\n\n /** Handler to run when the value of the search bar changes */\n onSearch: (searchQuery: string) => void;\n };\n\nexport default function SettingsSidebarContentSearch({\n id,\n extensionLabels,\n projectInfo,\n children,\n handleSelectSidebarItem,\n selectedSidebarItem,\n onSearch,\n extensionsSidebarGroupLabel,\n projectsSidebarGroupLabel,\n buttonPlaceholderText,\n}: SettingsSidebarContentSearchProps) {\n return (\n
    \n
    \n \n
    \n \n \n {children}\n \n
    \n );\n}\n","import { Button } from '@/components/shadcn-ui/button';\nimport {\n Select,\n SelectContent,\n SelectGroup,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\nimport {\n Table,\n TableBody,\n TableCell,\n TableHead,\n TableHeader,\n TableRow,\n} from '@/components/shadcn-ui/table';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Canon } from '@sillsdev/scripture';\nimport {\n Cell,\n ColumnDef,\n flexRender,\n getCoreRowModel,\n getExpandedRowModel,\n getGroupedRowModel,\n getSortedRowModel,\n GroupingState,\n Row,\n RowSelectionState,\n SortingState,\n useReactTable,\n} from '@tanstack/react-table';\nimport '@/components/advanced/scripture-results-viewer/scripture-results-viewer.component.css';\nimport {\n compareScrRefs,\n formatScrRef,\n ScriptureSelection,\n scrRefToBBBCCCVVV,\n} from 'platform-bible-utils';\nimport { MouseEvent, useEffect, useMemo, useState } from 'react';\nimport { ChevronDown, ChevronLeft, ChevronRight } from 'lucide-react';\n\n/**\n * Information (e.g., a checking error or some other type of \"transient\" annotation) about something\n * noteworthy at a specific place in an instance of the Scriptures.\n */\nexport type ScriptureItemDetail = ScriptureSelection & {\n /**\n * Text of the error, note, etc. In the future, we might want to support something more than just\n * text so that a JSX element could be provided with a link or some other controls related to the\n * issue being reported.\n */\n detail: string;\n};\n\n/**\n * A uniquely identifiable source of results that can be displayed in the ScriptureResultsViewer.\n * Generally, the source will be a particular Scripture check, but there may be other types of\n * sources.\n */\nexport type ResultsSource = {\n /**\n * Uniquely identifies the source.\n *\n * @type {string}\n */\n id: string;\n\n /**\n * Name (potentially localized) of the source, suitable for display in the UI.\n *\n * @type {string}\n */\n displayName: string;\n};\n\nexport type ScriptureSrcItemDetail = ScriptureItemDetail & {\n /** Source/type of detail. Can be used for grouping. */\n source: ResultsSource;\n};\n\n/**\n * Represents a set of results keyed by Scripture reference. Generally, the source will be a\n * particular Scripture check, but this type also allows for other types of uniquely identifiable\n * sources.\n */\nexport type ResultsSet = {\n /**\n * The backing source associated with this set of results.\n *\n * @type {ResultsSource}\n */\n source: ResultsSource;\n\n /**\n * Array of Scripture item details (messages keyed by Scripture reference).\n *\n * @type {ScriptureItemDetail[]}\n */\n data: ScriptureItemDetail[];\n};\n\nconst scrBookColId = 'scrBook';\nconst scrRefColId = 'scrRef';\nconst typeColId = 'source';\nconst detailsColId = 'details';\n\nconst defaultScrRefColumnName = 'Scripture Reference';\nconst defaultScrBookGroupName = 'Scripture Book';\nconst defaultTypeColumnName = 'Type';\nconst defaultDetailsColumnName = 'Details';\n\nexport type ScriptureResultsViewerColumnInfo = {\n /** Optional header to display for the Reference column. Default value: 'Scripture Reference'. */\n scriptureReferenceColumnName?: string;\n\n /** Optional text to display to refer to the Scripture book group. Default value: 'Scripture Book'. */\n scriptureBookGroupName?: string;\n\n /** Optional header to display for the Type column. Default value: 'Type'. */\n typeColumnName?: string;\n\n /** Optional header to display for the Details column. Default value: 'Details' */\n detailsColumnName?: string;\n};\n\nexport type ScriptureResultsViewerProps = ScriptureResultsViewerColumnInfo & {\n /** Groups of ScriptureItemDetail objects from particular sources (e.g., Scripture checks) */\n sources: ResultsSet[];\n\n /** Flag indicating whether to display column headers. Default is false. */\n showColumnHeaders?: boolean;\n\n /** Flag indicating whether to display source column. Default is false. */\n showSourceColumn?: boolean;\n\n /** Callback function to notify when a row is selected */\n onRowSelected?: (selectedRow: ScriptureSrcItemDetail | undefined) => void;\n\n /** Text direction ltr or rtl */\n direction?: 'ltr' | 'rtl';\n};\n\nfunction getColumns(\n colInfo?: ScriptureResultsViewerColumnInfo,\n showSourceColumn?: boolean,\n): ColumnDef[] {\n const showSrcCol = showSourceColumn ?? false;\n return [\n {\n accessorFn: (row) =>\n `${Canon.bookNumberToId(row.start.bookNum)} ${row.start.chapterNum}:${row.start.verseNum}`,\n id: scrBookColId,\n header: colInfo?.scriptureReferenceColumnName ?? defaultScrRefColumnName,\n cell: (info) => {\n const row = info.row.original;\n if (info.row.getIsGrouped()) {\n return Canon.bookNumberToEnglishName(row.start.bookNum);\n }\n return info.row.groupingColumnId === scrBookColId ? formatScrRef(row.start) : undefined;\n },\n getGroupingValue: (row) => row.start.bookNum,\n sortingFn: (a, b) => {\n return compareScrRefs(a.original.start, b.original.start);\n },\n enableGrouping: true,\n },\n {\n accessorFn: (row) => formatScrRef(row.start),\n id: scrRefColId,\n header: undefined,\n cell: (info) => {\n const row = info.row.original;\n return info.row.getIsGrouped() ? undefined : formatScrRef(row.start);\n },\n sortingFn: (a, b) => {\n return compareScrRefs(a.original.start, b.original.start);\n },\n enableGrouping: false,\n },\n {\n accessorFn: (row) => row.source.displayName,\n id: typeColId,\n header: showSrcCol ? (colInfo?.typeColumnName ?? defaultTypeColumnName) : undefined,\n cell: (info) => (showSrcCol || info.row.getIsGrouped() ? info.getValue() : undefined),\n getGroupingValue: (row) => row.source.id,\n sortingFn: (a, b) =>\n a.original.source.displayName.localeCompare(b.original.source.displayName),\n enableGrouping: true,\n },\n {\n accessorFn: (row) => row.detail,\n id: detailsColId,\n header: colInfo?.detailsColumnName ?? defaultDetailsColumnName,\n cell: (info) => info.getValue(),\n enableGrouping: false,\n },\n ];\n}\n\nconst toRefOrRange = (scriptureSelection: ScriptureSelection) => {\n if (!('offset' in scriptureSelection.start))\n throw new Error('No offset available in range start');\n if (scriptureSelection.end && !('offset' in scriptureSelection.end))\n throw new Error('No offset available in range end');\n const { offset: offsetStart } = scriptureSelection.start;\n let offsetEnd: number = 0;\n if (scriptureSelection.end) ({ offset: offsetEnd } = scriptureSelection.end);\n if (\n !scriptureSelection.end ||\n compareScrRefs(scriptureSelection.start, scriptureSelection.end) === 0\n )\n return `${scrRefToBBBCCCVVV(scriptureSelection.start)}+${offsetStart}`;\n return `${scrRefToBBBCCCVVV(scriptureSelection.start)}+${offsetStart}-${scrRefToBBBCCCVVV(scriptureSelection.end)}+${offsetEnd}`;\n};\n\nconst getRowKey = (row: ScriptureSrcItemDetail) =>\n `${toRefOrRange({ start: row.start, end: row.end })} ${row.source.displayName} ${row.detail}`;\n\n/**\n * Component to display a combined list of detailed items from one or more sources, where the items\n * are keyed primarily by Scripture reference. This is particularly useful for displaying a list of\n * results from Scripture checks, but more generally could be used to display any \"results\" from any\n * source(s). The component allows for grouping by Scripture book, source, or both. By default, it\n * displays somewhat \"tree-like\" which allows it to be more horizontally compact and intuitive. But\n * it also has the option of displaying as a traditional table with column headings (with or without\n * the source column showing).\n */\nexport default function ScriptureResultsViewer({\n sources,\n showColumnHeaders = false,\n showSourceColumn = false,\n scriptureReferenceColumnName,\n scriptureBookGroupName,\n typeColumnName,\n detailsColumnName,\n onRowSelected,\n direction = 'ltr',\n}: ScriptureResultsViewerProps) {\n const [grouping, setGrouping] = useState([]);\n const [sorting, setSorting] = useState([{ id: scrBookColId, desc: false }]);\n const [rowSelection, setRowSelection] = useState({});\n\n const scriptureResults = useMemo(\n () =>\n sources.flatMap((source) => {\n return source.data.map((item) => ({\n ...item,\n source: source.source,\n }));\n }),\n [sources],\n );\n\n const columns = useMemo(\n () =>\n getColumns(\n {\n scriptureReferenceColumnName,\n typeColumnName,\n detailsColumnName,\n },\n showSourceColumn,\n ),\n [scriptureReferenceColumnName, typeColumnName, detailsColumnName, showSourceColumn],\n );\n\n useEffect(() => {\n // Ensure sorting is applied correctly when grouped by type\n if (grouping.includes(typeColId)) {\n setSorting([\n { id: typeColId, desc: false },\n { id: scrBookColId, desc: false },\n ]);\n } else {\n setSorting([{ id: scrBookColId, desc: false }]);\n }\n }, [grouping]);\n\n const table = useReactTable({\n data: scriptureResults,\n columns,\n state: {\n grouping,\n sorting,\n rowSelection,\n },\n onGroupingChange: setGrouping,\n onSortingChange: setSorting,\n onRowSelectionChange: setRowSelection,\n getExpandedRowModel: getExpandedRowModel(),\n getGroupedRowModel: getGroupedRowModel(),\n getCoreRowModel: getCoreRowModel(),\n getSortedRowModel: getSortedRowModel(),\n getRowId: getRowKey,\n autoResetExpanded: false,\n enableMultiRowSelection: false,\n enableSubRowSelection: false,\n });\n\n useEffect(() => {\n if (onRowSelected) {\n const selectedRows = table.getSelectedRowModel().rowsById;\n const keys = Object.keys(selectedRows);\n if (keys.length === 1) {\n const selectedRow = scriptureResults.find((row) => getRowKey(row) === keys[0]) || undefined;\n if (selectedRow) onRowSelected(selectedRow);\n }\n }\n }, [rowSelection, scriptureResults, onRowSelected, table]);\n\n // Define possible grouping options\n const scrBookGroupName = scriptureBookGroupName ?? defaultScrBookGroupName;\n const typeGroupName = typeColumnName ?? defaultTypeColumnName;\n\n const groupingOptions = [\n { label: 'No Grouping', value: [] },\n { label: `Group by ${scrBookGroupName}`, value: [scrBookColId] },\n { label: `Group by ${typeGroupName}`, value: [typeColId] },\n {\n label: `Group by ${scrBookGroupName} and ${typeGroupName}`,\n value: [scrBookColId, typeColId],\n },\n {\n label: `Group by ${typeGroupName} and ${scrBookGroupName}`,\n value: [typeColId, scrBookColId],\n },\n ];\n\n const handleSelectChange = (selectedGrouping: string) => {\n setGrouping(JSON.parse(selectedGrouping));\n };\n\n const handleRowClick = (row: Row, event: MouseEvent) => {\n if (!row.getIsGrouped() && !row.getIsSelected()) {\n row.getToggleSelectedHandler()(event);\n }\n };\n\n const getEvenOrOddBandingStyle = (row: Row, index: number) => {\n if (row.getIsGrouped()) return '';\n // UX has now said they don't think they want banding. I'm leaving in the code to\n // set even and odd styles, but there's nothing in the CSS to style them differently.\n // The \"even\" style used to also have tw-bg-neutral-300 (along with even) to create\n // a visual banding effect. That could be added back in if UX changes the decision.\n return cn('banded-row', index % 2 === 0 ? 'even' : 'odd');\n };\n\n const getIndent = (\n groupingState: GroupingState,\n row: Row,\n cell: Cell,\n ) => {\n if (groupingState?.length === 0 || row.depth < cell.column.getGroupedIndex()) return undefined;\n if (row.getIsGrouped()) {\n switch (row.depth) {\n case 1:\n return 'tw-ps-4';\n default:\n return undefined;\n }\n }\n switch (row.depth) {\n case 1:\n return 'tw-ps-8';\n case 2:\n return 'tw-ps-12';\n default:\n return undefined;\n }\n };\n\n return (\n
    \n {!showColumnHeaders && (\n {\n handleSelectChange(value);\n }}\n >\n \n \n \n \n \n {groupingOptions.map((option) => (\n \n {option.label}\n \n ))}\n \n \n \n )}\n \n {showColumnHeaders && (\n \n {table.getHeaderGroups().map((headerGroup) => (\n \n {headerGroup.headers\n .filter((h) => h.column.columnDef.header)\n .map((header) => (\n /* For sticky column headers to work, we probably need to change the default definition of the shadcn Table component. See https://github.com/shadcn-ui/ui/issues/1151 */\n \n {header.isPlaceholder ? undefined : (\n
    \n {header.column.getCanGroup() ? (\n \n {header.column.getIsGrouped() ? `🛑` : `👊 `}\n \n ) : undefined}{' '}\n {flexRender(header.column.columnDef.header, header.getContext())}\n
    \n )}\n
    \n ))}\n
    \n ))}\n
    \n )}\n \n {table.getRowModel().rows.map((row, rowIndex) => {\n return (\n handleRowClick(row, event)}\n >\n {row.getVisibleCells().map((cell) => {\n if (\n cell.getIsPlaceholder() ||\n (cell.column.columnDef.enableGrouping &&\n !cell.getIsGrouped() &&\n (cell.column.columnDef.id !== typeColId || !showSourceColumn))\n )\n return undefined;\n return (\n \n {(() => {\n if (cell.getIsGrouped()) {\n return (\n \n {row.getIsExpanded() && }\n {!row.getIsExpanded() &&\n (direction === 'ltr' ? : )}{' '}\n {flexRender(cell.column.columnDef.cell, cell.getContext())} (\n {row.subRows.length})\n \n );\n }\n\n // if (cell.getIsAggregated()) {\n // flexRender(\n // cell.column.columnDef.aggregatedCell ?? cell.column.columnDef.cell,\n // cell.getContext(),\n // );\n // }\n\n return flexRender(cell.column.columnDef.cell, cell.getContext());\n })()}\n \n );\n })}\n \n );\n })}\n \n
    \n
    \n );\n}\n","import {\n getLocalizeKeyForScrollGroupId,\n LanguageStrings,\n ScrollGroupId,\n} from 'platform-bible-utils';\nimport {\n Select,\n SelectContent,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\n\nconst DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS = {\n [getLocalizeKeyForScrollGroupId('undefined')]: 'Ø',\n [getLocalizeKeyForScrollGroupId(0)]: 'A',\n [getLocalizeKeyForScrollGroupId(1)]: 'B',\n [getLocalizeKeyForScrollGroupId(2)]: 'C',\n [getLocalizeKeyForScrollGroupId(3)]: 'D',\n [getLocalizeKeyForScrollGroupId(4)]: 'E',\n [getLocalizeKeyForScrollGroupId(5)]: 'F',\n [getLocalizeKeyForScrollGroupId(6)]: 'G',\n [getLocalizeKeyForScrollGroupId(7)]: 'H',\n [getLocalizeKeyForScrollGroupId(8)]: 'I',\n [getLocalizeKeyForScrollGroupId(9)]: 'J',\n [getLocalizeKeyForScrollGroupId(10)]: 'K',\n [getLocalizeKeyForScrollGroupId(11)]: 'L',\n [getLocalizeKeyForScrollGroupId(12)]: 'M',\n [getLocalizeKeyForScrollGroupId(13)]: 'N',\n [getLocalizeKeyForScrollGroupId(14)]: 'O',\n [getLocalizeKeyForScrollGroupId(15)]: 'P',\n [getLocalizeKeyForScrollGroupId(16)]: 'Q',\n [getLocalizeKeyForScrollGroupId(17)]: 'R',\n [getLocalizeKeyForScrollGroupId(18)]: 'S',\n [getLocalizeKeyForScrollGroupId(19)]: 'T',\n [getLocalizeKeyForScrollGroupId(20)]: 'U',\n [getLocalizeKeyForScrollGroupId(21)]: 'V',\n [getLocalizeKeyForScrollGroupId(22)]: 'W',\n [getLocalizeKeyForScrollGroupId(23)]: 'X',\n [getLocalizeKeyForScrollGroupId(24)]: 'Y',\n [getLocalizeKeyForScrollGroupId(25)]: 'Z',\n};\n\nexport type ScrollGroupSelectorProps = {\n /**\n * List of scroll group ids to show to the user. Either a {@link ScrollGroupId} or `undefined` for\n * no scroll group\n */\n availableScrollGroupIds: (ScrollGroupId | undefined)[];\n /** Currently selected scroll group id. `undefined` for no scroll group */\n scrollGroupId: ScrollGroupId | undefined;\n /** Callback function run when the user tries to change the scroll group id */\n onChangeScrollGroupId: (newScrollGroupId: ScrollGroupId | undefined) => void;\n /**\n * Localized strings to use for displaying scroll group ids. Must be an object whose keys are\n * `getLocalizeKeyForScrollGroupId(scrollGroupId)` for all scroll group ids (and `undefined` if\n * included) in {@link ScrollGroupSelectorProps.availableScrollGroupIds} and whose values are the\n * localized strings to use for those scroll group ids.\n *\n * Defaults to English localizations of English alphabet for scroll groups 0-25 (e.g. 0 is A) and\n * Ø for `undefined`. Will fill in any that are not provided with these English localizations.\n * Also, if any values match the keys, the English localization will be used. This is useful in\n * case you want to pass in a temporary version of the localized strings while your localized\n * strings load.\n *\n * @example\n *\n * ```typescript\n * const myScrollGroupIdLocalizedStrings = {\n * [getLocalizeKeyForScrollGroupId('undefined')]: 'Ø',\n * [getLocalizeKeyForScrollGroupId(0)]: 'A',\n * [getLocalizeKeyForScrollGroupId(1)]: 'B',\n * [getLocalizeKeyForScrollGroupId(2)]: 'C',\n * [getLocalizeKeyForScrollGroupId(3)]: 'D',\n * [getLocalizeKeyForScrollGroupId(4)]: 'E',\n * };\n * ```\n *\n * @example\n *\n * ```tsx\n * const availableScrollGroupIds = [undefined, 0, 1, 2, 3, 4];\n *\n * const localizeKeys = getLocalizeKeysForScrollGroupIds();\n *\n * const [localizedStrings] = useLocalizedStrings(localizeKeys);\n *\n * ...\n *\n * \n * ```\n */\n localizedStrings?: LanguageStrings;\n};\n\n/** Selector component for choosing a scroll group */\nexport default function ScrollGroupSelector({\n availableScrollGroupIds,\n scrollGroupId,\n onChangeScrollGroupId,\n localizedStrings = {},\n}: ScrollGroupSelectorProps) {\n const localizedStringsDefaulted = {\n ...DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS,\n ...Object.fromEntries(\n Object.entries(localizedStrings).map(\n ([localizedStringKey, localizedStringValue]: [string, string]) => [\n localizedStringKey,\n localizedStringKey === localizedStringValue &&\n localizedStringKey in DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS\n ? DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS[localizedStringKey]\n : localizedStringValue,\n ],\n ),\n ),\n };\n return (\n \n onChangeScrollGroupId(\n newScrollGroupString === 'undefined' ? undefined : parseInt(newScrollGroupString, 10),\n )\n }\n >\n \n \n \n \n {availableScrollGroupIds.map((scrollGroupOptionId) => (\n \n {localizedStringsDefaulted[getLocalizeKeyForScrollGroupId(scrollGroupOptionId)]}\n \n ))}\n \n \n );\n}\n","import { PropsWithChildren } from 'react';\nimport { Separator } from '@/components/shadcn-ui/separator';\n\n/** Props for the SettingsList component, currently just children */\ntype SettingsListProps = PropsWithChildren;\n\n/**\n * SettingsList component is a wrapper for list items. Rendered with a formatted div\n *\n * @param children To populate the list with\n * @returns Formatted div encompassing the children\n */\nexport function SettingsList({ children }: SettingsListProps) {\n return
    {children}
    ;\n}\n\n/** Props for SettingsListItem component */\ntype SettingsListItemProps = PropsWithChildren & {\n /** Primary text of the list item */\n primary: string;\n\n /** Optional text of the list item */\n secondary?: string | undefined;\n\n /** Optional boolean to display a message if the children aren't loaded yet. Defaults to false */\n isLoading?: boolean;\n\n /** Optional message to display if isLoading */\n loadingMessage?: string;\n};\n\n/**\n * SettingsListItem component is a common list item. Rendered with a formatted div\n *\n * @param primary Primary text of the list item\n * @param secondary Optional secondary text of the list item\n * @param isLoading Optional, to display a message if the action component isn't generated yet,\n * defaults to false\n * @param children The action component(s) to provide for this item\n * @param loadingMessage Optional, message to display if isLoading\n * @returns Formatted div encompassing the list item content\n */\nexport function SettingsListItem({\n primary,\n secondary,\n children,\n isLoading = false,\n loadingMessage,\n}: SettingsListItemProps) {\n return (\n
    \n
    \n

    {primary}

    \n

    \n {secondary}\n

    \n
    \n\n {isLoading ? (\n

    {loadingMessage}

    \n ) : (\n
    {children}
    \n )}\n
    \n );\n}\n\n/** Props for SettingsListHeader component */\ntype SettingsListHeaderProps = {\n /** The primary text of the list header */\n primary: string;\n\n /** Optional secondary text of the list header */\n secondary?: string | undefined;\n\n /** Optional boolean to include a separator underneath the secondary text. Defaults to false */\n includeSeparator?: boolean;\n};\n\n/**\n * SettingsListHeader component displays text above the list\n *\n * @param primary The primary text of the list header\n * @param secondary Optional secondary text of the list header\n * @param includeSeparator Optional boolean to include a separator underneath the secondary text.\n * Defaults to false\n * @returns Formatted div with list header content\n */\nexport function SettingsListHeader({\n primary,\n secondary,\n includeSeparator = false,\n}: SettingsListHeaderProps) {\n return (\n
    \n
    \n

    {primary}

    \n

    {secondary}

    \n
    \n {includeSeparator ? : ''}\n
    \n );\n}\n","import Checkbox from '@/components/shadcn-ui/checkbox';\nimport { Label } from '@/components/shadcn-ui/label';\n\nexport type ChecklistProps = {\n /** Optional string representing the id attribute of the Checklist */\n id?: string;\n /** Optional string representing CSS class name(s) for styling */\n className?: string;\n /** Array of strings representing the checkable items */\n listItems: string[];\n /** Array of strings representing the checked items */\n selectedListItems: string[];\n /**\n * Function that is called when a checkbox item is selected or deselected\n *\n * @param item The string description for this item\n * @param selected True if selected, false if not selected\n */\n handleSelectListItem: (item: string, selected: boolean) => void;\n\n /**\n * Optional function creates a label for a provided checkable item\n *\n * @param item The item for which a label is to be created\n * @returns A string representing the label text for the checkbox associated with that item\n */\n createLabel?: (item: string) => string;\n};\n\n/** Renders a list of checkboxes. Each checkbox corresponds to an item from the `listItems` array. */\nexport default function Checklist({\n id,\n className,\n listItems,\n selectedListItems,\n handleSelectListItem,\n createLabel,\n}: ChecklistProps) {\n return (\n
    \n {listItems.map((item) => (\n
    \n handleSelectListItem(item, value)}\n />\n \n
    \n ))}\n
    \n );\n}\n","function _interopRequireDefault(obj) {\n return obj && obj.__esModule ? obj : {\n \"default\": obj\n };\n}\nmodule.exports = _interopRequireDefault, module.exports.__esModule = true, module.exports[\"default\"] = module.exports;","export default function chainPropTypes(propType1, propType2) {\n if (process.env.NODE_ENV === 'production') {\n return () => null;\n }\n return function validate(...args) {\n return propType1(...args) || propType2(...args);\n };\n}","export default function _extends() {\n _extends = Object.assign ? Object.assign.bind() : function (target) {\n for (var i = 1; i < arguments.length; i++) {\n var source = arguments[i];\n for (var key in source) {\n if (Object.prototype.hasOwnProperty.call(source, key)) {\n target[key] = source[key];\n }\n }\n }\n return target;\n };\n return _extends.apply(this, arguments);\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\n// https://github.com/sindresorhus/is-plain-obj/blob/main/index.js\nexport function isPlainObject(item) {\n if (typeof item !== 'object' || item === null) {\n return false;\n }\n const prototype = Object.getPrototypeOf(item);\n return (prototype === null || prototype === Object.prototype || Object.getPrototypeOf(prototype) === null) && !(Symbol.toStringTag in item) && !(Symbol.iterator in item);\n}\nfunction deepClone(source) {\n if (!isPlainObject(source)) {\n return source;\n }\n const output = {};\n Object.keys(source).forEach(key => {\n output[key] = deepClone(source[key]);\n });\n return output;\n}\nexport default function deepmerge(target, source, options = {\n clone: true\n}) {\n const output = options.clone ? _extends({}, target) : target;\n if (isPlainObject(target) && isPlainObject(source)) {\n Object.keys(source).forEach(key => {\n // Avoid prototype pollution\n if (key === '__proto__') {\n return;\n }\n if (isPlainObject(source[key]) && key in target && isPlainObject(target[key])) {\n // Since `output` is a clone of `target` and we have narrowed `target` in this block we can cast to the same type.\n output[key] = deepmerge(target[key], source[key], options);\n } else if (options.clone) {\n output[key] = isPlainObject(source[key]) ? deepClone(source[key]) : source[key];\n } else {\n output[key] = source[key];\n }\n });\n }\n return output;\n}","/** @license React v16.13.1\n * react-is.production.min.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';var b=\"function\"===typeof Symbol&&Symbol.for,c=b?Symbol.for(\"react.element\"):60103,d=b?Symbol.for(\"react.portal\"):60106,e=b?Symbol.for(\"react.fragment\"):60107,f=b?Symbol.for(\"react.strict_mode\"):60108,g=b?Symbol.for(\"react.profiler\"):60114,h=b?Symbol.for(\"react.provider\"):60109,k=b?Symbol.for(\"react.context\"):60110,l=b?Symbol.for(\"react.async_mode\"):60111,m=b?Symbol.for(\"react.concurrent_mode\"):60111,n=b?Symbol.for(\"react.forward_ref\"):60112,p=b?Symbol.for(\"react.suspense\"):60113,q=b?\nSymbol.for(\"react.suspense_list\"):60120,r=b?Symbol.for(\"react.memo\"):60115,t=b?Symbol.for(\"react.lazy\"):60116,v=b?Symbol.for(\"react.block\"):60121,w=b?Symbol.for(\"react.fundamental\"):60117,x=b?Symbol.for(\"react.responder\"):60118,y=b?Symbol.for(\"react.scope\"):60119;\nfunction z(a){if(\"object\"===typeof a&&null!==a){var u=a.$$typeof;switch(u){case c:switch(a=a.type,a){case l:case m:case e:case g:case f:case p:return a;default:switch(a=a&&a.$$typeof,a){case k:case n:case t:case r:case h:return a;default:return u}}case d:return u}}}function A(a){return z(a)===m}exports.AsyncMode=l;exports.ConcurrentMode=m;exports.ContextConsumer=k;exports.ContextProvider=h;exports.Element=c;exports.ForwardRef=n;exports.Fragment=e;exports.Lazy=t;exports.Memo=r;exports.Portal=d;\nexports.Profiler=g;exports.StrictMode=f;exports.Suspense=p;exports.isAsyncMode=function(a){return A(a)||z(a)===l};exports.isConcurrentMode=A;exports.isContextConsumer=function(a){return z(a)===k};exports.isContextProvider=function(a){return z(a)===h};exports.isElement=function(a){return\"object\"===typeof a&&null!==a&&a.$$typeof===c};exports.isForwardRef=function(a){return z(a)===n};exports.isFragment=function(a){return z(a)===e};exports.isLazy=function(a){return z(a)===t};\nexports.isMemo=function(a){return z(a)===r};exports.isPortal=function(a){return z(a)===d};exports.isProfiler=function(a){return z(a)===g};exports.isStrictMode=function(a){return z(a)===f};exports.isSuspense=function(a){return z(a)===p};\nexports.isValidElementType=function(a){return\"string\"===typeof a||\"function\"===typeof a||a===e||a===m||a===g||a===f||a===p||a===q||\"object\"===typeof a&&null!==a&&(a.$$typeof===t||a.$$typeof===r||a.$$typeof===h||a.$$typeof===k||a.$$typeof===n||a.$$typeof===w||a.$$typeof===x||a.$$typeof===y||a.$$typeof===v)};exports.typeOf=z;\n","/** @license React v16.13.1\n * react-is.development.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\n\n\nif (process.env.NODE_ENV !== \"production\") {\n (function() {\n'use strict';\n\n// The Symbol used to tag the ReactElement-like types. If there is no native Symbol\n// nor polyfill, then a plain number is used for performance.\nvar hasSymbol = typeof Symbol === 'function' && Symbol.for;\nvar REACT_ELEMENT_TYPE = hasSymbol ? Symbol.for('react.element') : 0xeac7;\nvar REACT_PORTAL_TYPE = hasSymbol ? Symbol.for('react.portal') : 0xeaca;\nvar REACT_FRAGMENT_TYPE = hasSymbol ? Symbol.for('react.fragment') : 0xeacb;\nvar REACT_STRICT_MODE_TYPE = hasSymbol ? Symbol.for('react.strict_mode') : 0xeacc;\nvar REACT_PROFILER_TYPE = hasSymbol ? Symbol.for('react.profiler') : 0xead2;\nvar REACT_PROVIDER_TYPE = hasSymbol ? Symbol.for('react.provider') : 0xeacd;\nvar REACT_CONTEXT_TYPE = hasSymbol ? Symbol.for('react.context') : 0xeace; // TODO: We don't use AsyncMode or ConcurrentMode anymore. They were temporary\n// (unstable) APIs that have been removed. Can we remove the symbols?\n\nvar REACT_ASYNC_MODE_TYPE = hasSymbol ? Symbol.for('react.async_mode') : 0xeacf;\nvar REACT_CONCURRENT_MODE_TYPE = hasSymbol ? Symbol.for('react.concurrent_mode') : 0xeacf;\nvar REACT_FORWARD_REF_TYPE = hasSymbol ? Symbol.for('react.forward_ref') : 0xead0;\nvar REACT_SUSPENSE_TYPE = hasSymbol ? Symbol.for('react.suspense') : 0xead1;\nvar REACT_SUSPENSE_LIST_TYPE = hasSymbol ? Symbol.for('react.suspense_list') : 0xead8;\nvar REACT_MEMO_TYPE = hasSymbol ? Symbol.for('react.memo') : 0xead3;\nvar REACT_LAZY_TYPE = hasSymbol ? Symbol.for('react.lazy') : 0xead4;\nvar REACT_BLOCK_TYPE = hasSymbol ? Symbol.for('react.block') : 0xead9;\nvar REACT_FUNDAMENTAL_TYPE = hasSymbol ? Symbol.for('react.fundamental') : 0xead5;\nvar REACT_RESPONDER_TYPE = hasSymbol ? Symbol.for('react.responder') : 0xead6;\nvar REACT_SCOPE_TYPE = hasSymbol ? Symbol.for('react.scope') : 0xead7;\n\nfunction isValidElementType(type) {\n return typeof type === 'string' || typeof type === 'function' || // Note: its typeof might be other than 'symbol' or 'number' if it's a polyfill.\n type === REACT_FRAGMENT_TYPE || type === REACT_CONCURRENT_MODE_TYPE || type === REACT_PROFILER_TYPE || type === REACT_STRICT_MODE_TYPE || type === REACT_SUSPENSE_TYPE || type === REACT_SUSPENSE_LIST_TYPE || typeof type === 'object' && type !== null && (type.$$typeof === REACT_LAZY_TYPE || type.$$typeof === REACT_MEMO_TYPE || type.$$typeof === REACT_PROVIDER_TYPE || type.$$typeof === REACT_CONTEXT_TYPE || type.$$typeof === REACT_FORWARD_REF_TYPE || type.$$typeof === REACT_FUNDAMENTAL_TYPE || type.$$typeof === REACT_RESPONDER_TYPE || type.$$typeof === REACT_SCOPE_TYPE || type.$$typeof === REACT_BLOCK_TYPE);\n}\n\nfunction typeOf(object) {\n if (typeof object === 'object' && object !== null) {\n var $$typeof = object.$$typeof;\n\n switch ($$typeof) {\n case REACT_ELEMENT_TYPE:\n var type = object.type;\n\n switch (type) {\n case REACT_ASYNC_MODE_TYPE:\n case REACT_CONCURRENT_MODE_TYPE:\n case REACT_FRAGMENT_TYPE:\n case REACT_PROFILER_TYPE:\n case REACT_STRICT_MODE_TYPE:\n case REACT_SUSPENSE_TYPE:\n return type;\n\n default:\n var $$typeofType = type && type.$$typeof;\n\n switch ($$typeofType) {\n case REACT_CONTEXT_TYPE:\n case REACT_FORWARD_REF_TYPE:\n case REACT_LAZY_TYPE:\n case REACT_MEMO_TYPE:\n case REACT_PROVIDER_TYPE:\n return $$typeofType;\n\n default:\n return $$typeof;\n }\n\n }\n\n case REACT_PORTAL_TYPE:\n return $$typeof;\n }\n }\n\n return undefined;\n} // AsyncMode is deprecated along with isAsyncMode\n\nvar AsyncMode = REACT_ASYNC_MODE_TYPE;\nvar ConcurrentMode = REACT_CONCURRENT_MODE_TYPE;\nvar ContextConsumer = REACT_CONTEXT_TYPE;\nvar ContextProvider = REACT_PROVIDER_TYPE;\nvar Element = REACT_ELEMENT_TYPE;\nvar ForwardRef = REACT_FORWARD_REF_TYPE;\nvar Fragment = REACT_FRAGMENT_TYPE;\nvar Lazy = REACT_LAZY_TYPE;\nvar Memo = REACT_MEMO_TYPE;\nvar Portal = REACT_PORTAL_TYPE;\nvar Profiler = REACT_PROFILER_TYPE;\nvar StrictMode = REACT_STRICT_MODE_TYPE;\nvar Suspense = REACT_SUSPENSE_TYPE;\nvar hasWarnedAboutDeprecatedIsAsyncMode = false; // AsyncMode should be deprecated\n\nfunction isAsyncMode(object) {\n {\n if (!hasWarnedAboutDeprecatedIsAsyncMode) {\n hasWarnedAboutDeprecatedIsAsyncMode = true; // Using console['warn'] to evade Babel and ESLint\n\n console['warn']('The ReactIs.isAsyncMode() alias has been deprecated, ' + 'and will be removed in React 17+. Update your code to use ' + 'ReactIs.isConcurrentMode() instead. It has the exact same API.');\n }\n }\n\n return isConcurrentMode(object) || typeOf(object) === REACT_ASYNC_MODE_TYPE;\n}\nfunction isConcurrentMode(object) {\n return typeOf(object) === REACT_CONCURRENT_MODE_TYPE;\n}\nfunction isContextConsumer(object) {\n return typeOf(object) === REACT_CONTEXT_TYPE;\n}\nfunction isContextProvider(object) {\n return typeOf(object) === REACT_PROVIDER_TYPE;\n}\nfunction isElement(object) {\n return typeof object === 'object' && object !== null && object.$$typeof === REACT_ELEMENT_TYPE;\n}\nfunction isForwardRef(object) {\n return typeOf(object) === REACT_FORWARD_REF_TYPE;\n}\nfunction isFragment(object) {\n return typeOf(object) === REACT_FRAGMENT_TYPE;\n}\nfunction isLazy(object) {\n return typeOf(object) === REACT_LAZY_TYPE;\n}\nfunction isMemo(object) {\n return typeOf(object) === REACT_MEMO_TYPE;\n}\nfunction isPortal(object) {\n return typeOf(object) === REACT_PORTAL_TYPE;\n}\nfunction isProfiler(object) {\n return typeOf(object) === REACT_PROFILER_TYPE;\n}\nfunction isStrictMode(object) {\n return typeOf(object) === REACT_STRICT_MODE_TYPE;\n}\nfunction isSuspense(object) {\n return typeOf(object) === REACT_SUSPENSE_TYPE;\n}\n\nexports.AsyncMode = AsyncMode;\nexports.ConcurrentMode = ConcurrentMode;\nexports.ContextConsumer = ContextConsumer;\nexports.ContextProvider = ContextProvider;\nexports.Element = Element;\nexports.ForwardRef = ForwardRef;\nexports.Fragment = Fragment;\nexports.Lazy = Lazy;\nexports.Memo = Memo;\nexports.Portal = Portal;\nexports.Profiler = Profiler;\nexports.StrictMode = StrictMode;\nexports.Suspense = Suspense;\nexports.isAsyncMode = isAsyncMode;\nexports.isConcurrentMode = isConcurrentMode;\nexports.isContextConsumer = isContextConsumer;\nexports.isContextProvider = isContextProvider;\nexports.isElement = isElement;\nexports.isForwardRef = isForwardRef;\nexports.isFragment = isFragment;\nexports.isLazy = isLazy;\nexports.isMemo = isMemo;\nexports.isPortal = isPortal;\nexports.isProfiler = isProfiler;\nexports.isStrictMode = isStrictMode;\nexports.isSuspense = isSuspense;\nexports.isValidElementType = isValidElementType;\nexports.typeOf = typeOf;\n })();\n}\n","'use strict';\n\nif (process.env.NODE_ENV === 'production') {\n module.exports = require('./cjs/react-is.production.min.js');\n} else {\n module.exports = require('./cjs/react-is.development.js');\n}\n","/*\nobject-assign\n(c) Sindre Sorhus\n@license MIT\n*/\n\n'use strict';\n/* eslint-disable no-unused-vars */\nvar getOwnPropertySymbols = Object.getOwnPropertySymbols;\nvar hasOwnProperty = Object.prototype.hasOwnProperty;\nvar propIsEnumerable = Object.prototype.propertyIsEnumerable;\n\nfunction toObject(val) {\n\tif (val === null || val === undefined) {\n\t\tthrow new TypeError('Object.assign cannot be called with null or undefined');\n\t}\n\n\treturn Object(val);\n}\n\nfunction shouldUseNative() {\n\ttry {\n\t\tif (!Object.assign) {\n\t\t\treturn false;\n\t\t}\n\n\t\t// Detect buggy property enumeration order in older V8 versions.\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=4118\n\t\tvar test1 = new String('abc'); // eslint-disable-line no-new-wrappers\n\t\ttest1[5] = 'de';\n\t\tif (Object.getOwnPropertyNames(test1)[0] === '5') {\n\t\t\treturn false;\n\t\t}\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=3056\n\t\tvar test2 = {};\n\t\tfor (var i = 0; i < 10; i++) {\n\t\t\ttest2['_' + String.fromCharCode(i)] = i;\n\t\t}\n\t\tvar order2 = Object.getOwnPropertyNames(test2).map(function (n) {\n\t\t\treturn test2[n];\n\t\t});\n\t\tif (order2.join('') !== '0123456789') {\n\t\t\treturn false;\n\t\t}\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=3056\n\t\tvar test3 = {};\n\t\t'abcdefghijklmnopqrst'.split('').forEach(function (letter) {\n\t\t\ttest3[letter] = letter;\n\t\t});\n\t\tif (Object.keys(Object.assign({}, test3)).join('') !==\n\t\t\t\t'abcdefghijklmnopqrst') {\n\t\t\treturn false;\n\t\t}\n\n\t\treturn true;\n\t} catch (err) {\n\t\t// We don't expect any of the above to throw, but better to be safe.\n\t\treturn false;\n\t}\n}\n\nmodule.exports = shouldUseNative() ? Object.assign : function (target, source) {\n\tvar from;\n\tvar to = toObject(target);\n\tvar symbols;\n\n\tfor (var s = 1; s < arguments.length; s++) {\n\t\tfrom = Object(arguments[s]);\n\n\t\tfor (var key in from) {\n\t\t\tif (hasOwnProperty.call(from, key)) {\n\t\t\t\tto[key] = from[key];\n\t\t\t}\n\t\t}\n\n\t\tif (getOwnPropertySymbols) {\n\t\t\tsymbols = getOwnPropertySymbols(from);\n\t\t\tfor (var i = 0; i < symbols.length; i++) {\n\t\t\t\tif (propIsEnumerable.call(from, symbols[i])) {\n\t\t\t\t\tto[symbols[i]] = from[symbols[i]];\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\n\treturn to;\n};\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar ReactPropTypesSecret = 'SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED';\n\nmodule.exports = ReactPropTypesSecret;\n","module.exports = Function.call.bind(Object.prototype.hasOwnProperty);\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar printWarning = function() {};\n\nif (process.env.NODE_ENV !== 'production') {\n var ReactPropTypesSecret = require('./lib/ReactPropTypesSecret');\n var loggedTypeFailures = {};\n var has = require('./lib/has');\n\n printWarning = function(text) {\n var message = 'Warning: ' + text;\n if (typeof console !== 'undefined') {\n console.error(message);\n }\n try {\n // --- Welcome to debugging React ---\n // This error was thrown as a convenience so that you can use this stack\n // to find the callsite that caused this warning to fire.\n throw new Error(message);\n } catch (x) { /**/ }\n };\n}\n\n/**\n * Assert that the values match with the type specs.\n * Error messages are memorized and will only be shown once.\n *\n * @param {object} typeSpecs Map of name to a ReactPropType\n * @param {object} values Runtime values that need to be type-checked\n * @param {string} location e.g. \"prop\", \"context\", \"child context\"\n * @param {string} componentName Name of the component for error messages.\n * @param {?Function} getStack Returns the component stack.\n * @private\n */\nfunction checkPropTypes(typeSpecs, values, location, componentName, getStack) {\n if (process.env.NODE_ENV !== 'production') {\n for (var typeSpecName in typeSpecs) {\n if (has(typeSpecs, typeSpecName)) {\n var error;\n // Prop type validation may throw. In case they do, we don't want to\n // fail the render phase where it didn't fail before. So we log it.\n // After these have been cleaned up, we'll let them throw.\n try {\n // This is intentionally an invariant that gets caught. It's the same\n // behavior as without this statement except with a better message.\n if (typeof typeSpecs[typeSpecName] !== 'function') {\n var err = Error(\n (componentName || 'React class') + ': ' + location + ' type `' + typeSpecName + '` is invalid; ' +\n 'it must be a function, usually from the `prop-types` package, but received `' + typeof typeSpecs[typeSpecName] + '`.' +\n 'This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.'\n );\n err.name = 'Invariant Violation';\n throw err;\n }\n error = typeSpecs[typeSpecName](values, typeSpecName, componentName, location, null, ReactPropTypesSecret);\n } catch (ex) {\n error = ex;\n }\n if (error && !(error instanceof Error)) {\n printWarning(\n (componentName || 'React class') + ': type specification of ' +\n location + ' `' + typeSpecName + '` is invalid; the type checker ' +\n 'function must return `null` or an `Error` but returned a ' + typeof error + '. ' +\n 'You may have forgotten to pass an argument to the type checker ' +\n 'creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and ' +\n 'shape all require an argument).'\n );\n }\n if (error instanceof Error && !(error.message in loggedTypeFailures)) {\n // Only monitor this failure once because there tends to be a lot of the\n // same error.\n loggedTypeFailures[error.message] = true;\n\n var stack = getStack ? getStack() : '';\n\n printWarning(\n 'Failed ' + location + ' type: ' + error.message + (stack != null ? stack : '')\n );\n }\n }\n }\n }\n}\n\n/**\n * Resets warning cache when testing.\n *\n * @private\n */\ncheckPropTypes.resetWarningCache = function() {\n if (process.env.NODE_ENV !== 'production') {\n loggedTypeFailures = {};\n }\n}\n\nmodule.exports = checkPropTypes;\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar ReactIs = require('react-is');\nvar assign = require('object-assign');\n\nvar ReactPropTypesSecret = require('./lib/ReactPropTypesSecret');\nvar has = require('./lib/has');\nvar checkPropTypes = require('./checkPropTypes');\n\nvar printWarning = function() {};\n\nif (process.env.NODE_ENV !== 'production') {\n printWarning = function(text) {\n var message = 'Warning: ' + text;\n if (typeof console !== 'undefined') {\n console.error(message);\n }\n try {\n // --- Welcome to debugging React ---\n // This error was thrown as a convenience so that you can use this stack\n // to find the callsite that caused this warning to fire.\n throw new Error(message);\n } catch (x) {}\n };\n}\n\nfunction emptyFunctionThatReturnsNull() {\n return null;\n}\n\nmodule.exports = function(isValidElement, throwOnDirectAccess) {\n /* global Symbol */\n var ITERATOR_SYMBOL = typeof Symbol === 'function' && Symbol.iterator;\n var FAUX_ITERATOR_SYMBOL = '@@iterator'; // Before Symbol spec.\n\n /**\n * Returns the iterator method function contained on the iterable object.\n *\n * Be sure to invoke the function with the iterable as context:\n *\n * var iteratorFn = getIteratorFn(myIterable);\n * if (iteratorFn) {\n * var iterator = iteratorFn.call(myIterable);\n * ...\n * }\n *\n * @param {?object} maybeIterable\n * @return {?function}\n */\n function getIteratorFn(maybeIterable) {\n var iteratorFn = maybeIterable && (ITERATOR_SYMBOL && maybeIterable[ITERATOR_SYMBOL] || maybeIterable[FAUX_ITERATOR_SYMBOL]);\n if (typeof iteratorFn === 'function') {\n return iteratorFn;\n }\n }\n\n /**\n * Collection of methods that allow declaration and validation of props that are\n * supplied to React components. Example usage:\n *\n * var Props = require('ReactPropTypes');\n * var MyArticle = React.createClass({\n * propTypes: {\n * // An optional string prop named \"description\".\n * description: Props.string,\n *\n * // A required enum prop named \"category\".\n * category: Props.oneOf(['News','Photos']).isRequired,\n *\n * // A prop named \"dialog\" that requires an instance of Dialog.\n * dialog: Props.instanceOf(Dialog).isRequired\n * },\n * render: function() { ... }\n * });\n *\n * A more formal specification of how these methods are used:\n *\n * type := array|bool|func|object|number|string|oneOf([...])|instanceOf(...)\n * decl := ReactPropTypes.{type}(.isRequired)?\n *\n * Each and every declaration produces a function with the same signature. This\n * allows the creation of custom validation functions. For example:\n *\n * var MyLink = React.createClass({\n * propTypes: {\n * // An optional string or URI prop named \"href\".\n * href: function(props, propName, componentName) {\n * var propValue = props[propName];\n * if (propValue != null && typeof propValue !== 'string' &&\n * !(propValue instanceof URI)) {\n * return new Error(\n * 'Expected a string or an URI for ' + propName + ' in ' +\n * componentName\n * );\n * }\n * }\n * },\n * render: function() {...}\n * });\n *\n * @internal\n */\n\n var ANONYMOUS = '<>';\n\n // Important!\n // Keep this list in sync with production version in `./factoryWithThrowingShims.js`.\n var ReactPropTypes = {\n array: createPrimitiveTypeChecker('array'),\n bigint: createPrimitiveTypeChecker('bigint'),\n bool: createPrimitiveTypeChecker('boolean'),\n func: createPrimitiveTypeChecker('function'),\n number: createPrimitiveTypeChecker('number'),\n object: createPrimitiveTypeChecker('object'),\n string: createPrimitiveTypeChecker('string'),\n symbol: createPrimitiveTypeChecker('symbol'),\n\n any: createAnyTypeChecker(),\n arrayOf: createArrayOfTypeChecker,\n element: createElementTypeChecker(),\n elementType: createElementTypeTypeChecker(),\n instanceOf: createInstanceTypeChecker,\n node: createNodeChecker(),\n objectOf: createObjectOfTypeChecker,\n oneOf: createEnumTypeChecker,\n oneOfType: createUnionTypeChecker,\n shape: createShapeTypeChecker,\n exact: createStrictShapeTypeChecker,\n };\n\n /**\n * inlined Object.is polyfill to avoid requiring consumers ship their own\n * https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object/is\n */\n /*eslint-disable no-self-compare*/\n function is(x, y) {\n // SameValue algorithm\n if (x === y) {\n // Steps 1-5, 7-10\n // Steps 6.b-6.e: +0 != -0\n return x !== 0 || 1 / x === 1 / y;\n } else {\n // Step 6.a: NaN == NaN\n return x !== x && y !== y;\n }\n }\n /*eslint-enable no-self-compare*/\n\n /**\n * We use an Error-like object for backward compatibility as people may call\n * PropTypes directly and inspect their output. However, we don't use real\n * Errors anymore. We don't inspect their stack anyway, and creating them\n * is prohibitively expensive if they are created too often, such as what\n * happens in oneOfType() for any type before the one that matched.\n */\n function PropTypeError(message, data) {\n this.message = message;\n this.data = data && typeof data === 'object' ? data: {};\n this.stack = '';\n }\n // Make `instanceof Error` still work for returned errors.\n PropTypeError.prototype = Error.prototype;\n\n function createChainableTypeChecker(validate) {\n if (process.env.NODE_ENV !== 'production') {\n var manualPropTypeCallCache = {};\n var manualPropTypeWarningCount = 0;\n }\n function checkType(isRequired, props, propName, componentName, location, propFullName, secret) {\n componentName = componentName || ANONYMOUS;\n propFullName = propFullName || propName;\n\n if (secret !== ReactPropTypesSecret) {\n if (throwOnDirectAccess) {\n // New behavior only for users of `prop-types` package\n var err = new Error(\n 'Calling PropTypes validators directly is not supported by the `prop-types` package. ' +\n 'Use `PropTypes.checkPropTypes()` to call them. ' +\n 'Read more at http://fb.me/use-check-prop-types'\n );\n err.name = 'Invariant Violation';\n throw err;\n } else if (process.env.NODE_ENV !== 'production' && typeof console !== 'undefined') {\n // Old behavior for people using React.PropTypes\n var cacheKey = componentName + ':' + propName;\n if (\n !manualPropTypeCallCache[cacheKey] &&\n // Avoid spamming the console because they are often not actionable except for lib authors\n manualPropTypeWarningCount < 3\n ) {\n printWarning(\n 'You are manually calling a React.PropTypes validation ' +\n 'function for the `' + propFullName + '` prop on `' + componentName + '`. This is deprecated ' +\n 'and will throw in the standalone `prop-types` package. ' +\n 'You may be seeing this warning due to a third-party PropTypes ' +\n 'library. See https://fb.me/react-warning-dont-call-proptypes ' + 'for details.'\n );\n manualPropTypeCallCache[cacheKey] = true;\n manualPropTypeWarningCount++;\n }\n }\n }\n if (props[propName] == null) {\n if (isRequired) {\n if (props[propName] === null) {\n return new PropTypeError('The ' + location + ' `' + propFullName + '` is marked as required ' + ('in `' + componentName + '`, but its value is `null`.'));\n }\n return new PropTypeError('The ' + location + ' `' + propFullName + '` is marked as required in ' + ('`' + componentName + '`, but its value is `undefined`.'));\n }\n return null;\n } else {\n return validate(props, propName, componentName, location, propFullName);\n }\n }\n\n var chainedCheckType = checkType.bind(null, false);\n chainedCheckType.isRequired = checkType.bind(null, true);\n\n return chainedCheckType;\n }\n\n function createPrimitiveTypeChecker(expectedType) {\n function validate(props, propName, componentName, location, propFullName, secret) {\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== expectedType) {\n // `propValue` being instance of, say, date/regexp, pass the 'object'\n // check, but we can offer a more precise error message here rather than\n // 'of type `object`'.\n var preciseType = getPreciseType(propValue);\n\n return new PropTypeError(\n 'Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + preciseType + '` supplied to `' + componentName + '`, expected ') + ('`' + expectedType + '`.'),\n {expectedType: expectedType}\n );\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createAnyTypeChecker() {\n return createChainableTypeChecker(emptyFunctionThatReturnsNull);\n }\n\n function createArrayOfTypeChecker(typeChecker) {\n function validate(props, propName, componentName, location, propFullName) {\n if (typeof typeChecker !== 'function') {\n return new PropTypeError('Property `' + propFullName + '` of component `' + componentName + '` has invalid PropType notation inside arrayOf.');\n }\n var propValue = props[propName];\n if (!Array.isArray(propValue)) {\n var propType = getPropType(propValue);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected an array.'));\n }\n for (var i = 0; i < propValue.length; i++) {\n var error = typeChecker(propValue, i, componentName, location, propFullName + '[' + i + ']', ReactPropTypesSecret);\n if (error instanceof Error) {\n return error;\n }\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createElementTypeChecker() {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n if (!isValidElement(propValue)) {\n var propType = getPropType(propValue);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected a single ReactElement.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createElementTypeTypeChecker() {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n if (!ReactIs.isValidElementType(propValue)) {\n var propType = getPropType(propValue);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected a single ReactElement type.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createInstanceTypeChecker(expectedClass) {\n function validate(props, propName, componentName, location, propFullName) {\n if (!(props[propName] instanceof expectedClass)) {\n var expectedClassName = expectedClass.name || ANONYMOUS;\n var actualClassName = getClassName(props[propName]);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + actualClassName + '` supplied to `' + componentName + '`, expected ') + ('instance of `' + expectedClassName + '`.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createEnumTypeChecker(expectedValues) {\n if (!Array.isArray(expectedValues)) {\n if (process.env.NODE_ENV !== 'production') {\n if (arguments.length > 1) {\n printWarning(\n 'Invalid arguments supplied to oneOf, expected an array, got ' + arguments.length + ' arguments. ' +\n 'A common mistake is to write oneOf(x, y, z) instead of oneOf([x, y, z]).'\n );\n } else {\n printWarning('Invalid argument supplied to oneOf, expected an array.');\n }\n }\n return emptyFunctionThatReturnsNull;\n }\n\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n for (var i = 0; i < expectedValues.length; i++) {\n if (is(propValue, expectedValues[i])) {\n return null;\n }\n }\n\n var valuesString = JSON.stringify(expectedValues, function replacer(key, value) {\n var type = getPreciseType(value);\n if (type === 'symbol') {\n return String(value);\n }\n return value;\n });\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of value `' + String(propValue) + '` ' + ('supplied to `' + componentName + '`, expected one of ' + valuesString + '.'));\n }\n return createChainableTypeChecker(validate);\n }\n\n function createObjectOfTypeChecker(typeChecker) {\n function validate(props, propName, componentName, location, propFullName) {\n if (typeof typeChecker !== 'function') {\n return new PropTypeError('Property `' + propFullName + '` of component `' + componentName + '` has invalid PropType notation inside objectOf.');\n }\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== 'object') {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected an object.'));\n }\n for (var key in propValue) {\n if (has(propValue, key)) {\n var error = typeChecker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret);\n if (error instanceof Error) {\n return error;\n }\n }\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createUnionTypeChecker(arrayOfTypeCheckers) {\n if (!Array.isArray(arrayOfTypeCheckers)) {\n process.env.NODE_ENV !== 'production' ? printWarning('Invalid argument supplied to oneOfType, expected an instance of array.') : void 0;\n return emptyFunctionThatReturnsNull;\n }\n\n for (var i = 0; i < arrayOfTypeCheckers.length; i++) {\n var checker = arrayOfTypeCheckers[i];\n if (typeof checker !== 'function') {\n printWarning(\n 'Invalid argument supplied to oneOfType. Expected an array of check functions, but ' +\n 'received ' + getPostfixForTypeWarning(checker) + ' at index ' + i + '.'\n );\n return emptyFunctionThatReturnsNull;\n }\n }\n\n function validate(props, propName, componentName, location, propFullName) {\n var expectedTypes = [];\n for (var i = 0; i < arrayOfTypeCheckers.length; i++) {\n var checker = arrayOfTypeCheckers[i];\n var checkerResult = checker(props, propName, componentName, location, propFullName, ReactPropTypesSecret);\n if (checkerResult == null) {\n return null;\n }\n if (checkerResult.data && has(checkerResult.data, 'expectedType')) {\n expectedTypes.push(checkerResult.data.expectedType);\n }\n }\n var expectedTypesMessage = (expectedTypes.length > 0) ? ', expected one of type [' + expectedTypes.join(', ') + ']': '';\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` supplied to ' + ('`' + componentName + '`' + expectedTypesMessage + '.'));\n }\n return createChainableTypeChecker(validate);\n }\n\n function createNodeChecker() {\n function validate(props, propName, componentName, location, propFullName) {\n if (!isNode(props[propName])) {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` supplied to ' + ('`' + componentName + '`, expected a ReactNode.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function invalidValidatorError(componentName, location, propFullName, key, type) {\n return new PropTypeError(\n (componentName || 'React class') + ': ' + location + ' type `' + propFullName + '.' + key + '` is invalid; ' +\n 'it must be a function, usually from the `prop-types` package, but received `' + type + '`.'\n );\n }\n\n function createShapeTypeChecker(shapeTypes) {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== 'object') {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type `' + propType + '` ' + ('supplied to `' + componentName + '`, expected `object`.'));\n }\n for (var key in shapeTypes) {\n var checker = shapeTypes[key];\n if (typeof checker !== 'function') {\n return invalidValidatorError(componentName, location, propFullName, key, getPreciseType(checker));\n }\n var error = checker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret);\n if (error) {\n return error;\n }\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createStrictShapeTypeChecker(shapeTypes) {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== 'object') {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type `' + propType + '` ' + ('supplied to `' + componentName + '`, expected `object`.'));\n }\n // We need to check all keys in case some are required but missing from props.\n var allKeys = assign({}, props[propName], shapeTypes);\n for (var key in allKeys) {\n var checker = shapeTypes[key];\n if (has(shapeTypes, key) && typeof checker !== 'function') {\n return invalidValidatorError(componentName, location, propFullName, key, getPreciseType(checker));\n }\n if (!checker) {\n return new PropTypeError(\n 'Invalid ' + location + ' `' + propFullName + '` key `' + key + '` supplied to `' + componentName + '`.' +\n '\\nBad object: ' + JSON.stringify(props[propName], null, ' ') +\n '\\nValid keys: ' + JSON.stringify(Object.keys(shapeTypes), null, ' ')\n );\n }\n var error = checker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret);\n if (error) {\n return error;\n }\n }\n return null;\n }\n\n return createChainableTypeChecker(validate);\n }\n\n function isNode(propValue) {\n switch (typeof propValue) {\n case 'number':\n case 'string':\n case 'undefined':\n return true;\n case 'boolean':\n return !propValue;\n case 'object':\n if (Array.isArray(propValue)) {\n return propValue.every(isNode);\n }\n if (propValue === null || isValidElement(propValue)) {\n return true;\n }\n\n var iteratorFn = getIteratorFn(propValue);\n if (iteratorFn) {\n var iterator = iteratorFn.call(propValue);\n var step;\n if (iteratorFn !== propValue.entries) {\n while (!(step = iterator.next()).done) {\n if (!isNode(step.value)) {\n return false;\n }\n }\n } else {\n // Iterator will provide entry [k,v] tuples rather than values.\n while (!(step = iterator.next()).done) {\n var entry = step.value;\n if (entry) {\n if (!isNode(entry[1])) {\n return false;\n }\n }\n }\n }\n } else {\n return false;\n }\n\n return true;\n default:\n return false;\n }\n }\n\n function isSymbol(propType, propValue) {\n // Native Symbol.\n if (propType === 'symbol') {\n return true;\n }\n\n // falsy value can't be a Symbol\n if (!propValue) {\n return false;\n }\n\n // 19.4.3.5 Symbol.prototype[@@toStringTag] === 'Symbol'\n if (propValue['@@toStringTag'] === 'Symbol') {\n return true;\n }\n\n // Fallback for non-spec compliant Symbols which are polyfilled.\n if (typeof Symbol === 'function' && propValue instanceof Symbol) {\n return true;\n }\n\n return false;\n }\n\n // Equivalent of `typeof` but with special handling for array and regexp.\n function getPropType(propValue) {\n var propType = typeof propValue;\n if (Array.isArray(propValue)) {\n return 'array';\n }\n if (propValue instanceof RegExp) {\n // Old webkits (at least until Android 4.0) return 'function' rather than\n // 'object' for typeof a RegExp. We'll normalize this here so that /bla/\n // passes PropTypes.object.\n return 'object';\n }\n if (isSymbol(propType, propValue)) {\n return 'symbol';\n }\n return propType;\n }\n\n // This handles more types than `getPropType`. Only used for error messages.\n // See `createPrimitiveTypeChecker`.\n function getPreciseType(propValue) {\n if (typeof propValue === 'undefined' || propValue === null) {\n return '' + propValue;\n }\n var propType = getPropType(propValue);\n if (propType === 'object') {\n if (propValue instanceof Date) {\n return 'date';\n } else if (propValue instanceof RegExp) {\n return 'regexp';\n }\n }\n return propType;\n }\n\n // Returns a string that is postfixed to a warning about an invalid type.\n // For example, \"undefined\" or \"of type array\"\n function getPostfixForTypeWarning(value) {\n var type = getPreciseType(value);\n switch (type) {\n case 'array':\n case 'object':\n return 'an ' + type;\n case 'boolean':\n case 'date':\n case 'regexp':\n return 'a ' + type;\n default:\n return type;\n }\n }\n\n // Returns class name of the object, if any.\n function getClassName(propValue) {\n if (!propValue.constructor || !propValue.constructor.name) {\n return ANONYMOUS;\n }\n return propValue.constructor.name;\n }\n\n ReactPropTypes.checkPropTypes = checkPropTypes;\n ReactPropTypes.resetWarningCache = checkPropTypes.resetWarningCache;\n ReactPropTypes.PropTypes = ReactPropTypes;\n\n return ReactPropTypes;\n};\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar ReactPropTypesSecret = require('./lib/ReactPropTypesSecret');\n\nfunction emptyFunction() {}\nfunction emptyFunctionWithReset() {}\nemptyFunctionWithReset.resetWarningCache = emptyFunction;\n\nmodule.exports = function() {\n function shim(props, propName, componentName, location, propFullName, secret) {\n if (secret === ReactPropTypesSecret) {\n // It is still safe when called from React.\n return;\n }\n var err = new Error(\n 'Calling PropTypes validators directly is not supported by the `prop-types` package. ' +\n 'Use PropTypes.checkPropTypes() to call them. ' +\n 'Read more at http://fb.me/use-check-prop-types'\n );\n err.name = 'Invariant Violation';\n throw err;\n };\n shim.isRequired = shim;\n function getShim() {\n return shim;\n };\n // Important!\n // Keep this list in sync with production version in `./factoryWithTypeCheckers.js`.\n var ReactPropTypes = {\n array: shim,\n bigint: shim,\n bool: shim,\n func: shim,\n number: shim,\n object: shim,\n string: shim,\n symbol: shim,\n\n any: shim,\n arrayOf: getShim,\n element: shim,\n elementType: shim,\n instanceOf: getShim,\n node: shim,\n objectOf: getShim,\n oneOf: getShim,\n oneOfType: getShim,\n shape: getShim,\n exact: getShim,\n\n checkPropTypes: emptyFunctionWithReset,\n resetWarningCache: emptyFunction\n };\n\n ReactPropTypes.PropTypes = ReactPropTypes;\n\n return ReactPropTypes;\n};\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\nif (process.env.NODE_ENV !== 'production') {\n var ReactIs = require('react-is');\n\n // By explicitly using `prop-types` you are opting into new development behavior.\n // http://fb.me/prop-types-in-prod\n var throwOnDirectAccess = true;\n module.exports = require('./factoryWithTypeCheckers')(ReactIs.isElement, throwOnDirectAccess);\n} else {\n // By explicitly using `prop-types` you are opting into new production behavior.\n // http://fb.me/prop-types-in-prod\n module.exports = require('./factoryWithThrowingShims')();\n}\n","import PropTypes from 'prop-types';\nimport chainPropTypes from '../chainPropTypes';\nfunction isClassComponent(elementType) {\n // elementType.prototype?.isReactComponent\n const {\n prototype = {}\n } = elementType;\n return Boolean(prototype.isReactComponent);\n}\nfunction acceptingRef(props, propName, componentName, location, propFullName) {\n const element = props[propName];\n const safePropName = propFullName || propName;\n if (element == null ||\n // When server-side rendering React doesn't warn either.\n // This is not an accurate check for SSR.\n // This is only in place for Emotion compat.\n // TODO: Revisit once https://github.com/facebook/react/issues/20047 is resolved.\n typeof window === 'undefined') {\n return null;\n }\n let warningHint;\n const elementType = element.type;\n /**\n * Blacklisting instead of whitelisting\n *\n * Blacklisting will miss some components, such as React.Fragment. Those will at least\n * trigger a warning in React.\n * We can't whitelist because there is no safe way to detect React.forwardRef\n * or class components. \"Safe\" means there's no public API.\n *\n */\n if (typeof elementType === 'function' && !isClassComponent(elementType)) {\n warningHint = 'Did you accidentally use a plain function component for an element instead?';\n }\n if (warningHint !== undefined) {\n return new Error(`Invalid ${location} \\`${safePropName}\\` supplied to \\`${componentName}\\`. ` + `Expected an element that can hold a ref. ${warningHint} ` + 'For more information see https://mui.com/r/caveat-with-refs-guide');\n }\n return null;\n}\nconst elementAcceptingRef = chainPropTypes(PropTypes.element, acceptingRef);\nelementAcceptingRef.isRequired = chainPropTypes(PropTypes.element.isRequired, acceptingRef);\nexport default elementAcceptingRef;","import _extends from \"@babel/runtime/helpers/esm/extends\";\n// This module is based on https://github.com/airbnb/prop-types-exact repository.\n// However, in order to reduce the number of dependencies and to remove some extra safe checks\n// the module was forked.\n\nconst specialProperty = 'exact-prop: \\u200b';\nexport default function exactProp(propTypes) {\n if (process.env.NODE_ENV === 'production') {\n return propTypes;\n }\n return _extends({}, propTypes, {\n [specialProperty]: props => {\n const unsupportedProps = Object.keys(props).filter(prop => !propTypes.hasOwnProperty(prop));\n if (unsupportedProps.length > 0) {\n return new Error(`The following props are not supported: ${unsupportedProps.map(prop => `\\`${prop}\\``).join(', ')}. Please remove them.`);\n }\n return null;\n }\n });\n}","/**\n * WARNING: Don't import this directly.\n * Use `MuiError` from `@mui/internal-babel-macros/MuiError.macro` instead.\n * @param {number} code\n */\nexport default function formatMuiErrorMessage(code) {\n // Apply babel-plugin-transform-template-literals in loose mode\n // loose mode is safe if we're concatenating primitives\n // see https://babeljs.io/docs/en/babel-plugin-transform-template-literals#loose\n /* eslint-disable prefer-template */\n let url = 'https://mui.com/production-error/?code=' + code;\n for (let i = 1; i < arguments.length; i += 1) {\n // rest params over-transpile for this case\n // eslint-disable-next-line prefer-rest-params\n url += '&args[]=' + encodeURIComponent(arguments[i]);\n }\n return 'Minified MUI error #' + code + '; visit ' + url + ' for the full message.';\n /* eslint-enable prefer-template */\n}","/**\n * @license React\n * react-is.production.min.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n'use strict';var b=Symbol.for(\"react.element\"),c=Symbol.for(\"react.portal\"),d=Symbol.for(\"react.fragment\"),e=Symbol.for(\"react.strict_mode\"),f=Symbol.for(\"react.profiler\"),g=Symbol.for(\"react.provider\"),h=Symbol.for(\"react.context\"),k=Symbol.for(\"react.server_context\"),l=Symbol.for(\"react.forward_ref\"),m=Symbol.for(\"react.suspense\"),n=Symbol.for(\"react.suspense_list\"),p=Symbol.for(\"react.memo\"),q=Symbol.for(\"react.lazy\"),t=Symbol.for(\"react.offscreen\"),u;u=Symbol.for(\"react.module.reference\");\nfunction v(a){if(\"object\"===typeof a&&null!==a){var r=a.$$typeof;switch(r){case b:switch(a=a.type,a){case d:case f:case e:case m:case n:return a;default:switch(a=a&&a.$$typeof,a){case k:case h:case l:case q:case p:case g:return a;default:return r}}case c:return r}}}exports.ContextConsumer=h;exports.ContextProvider=g;exports.Element=b;exports.ForwardRef=l;exports.Fragment=d;exports.Lazy=q;exports.Memo=p;exports.Portal=c;exports.Profiler=f;exports.StrictMode=e;exports.Suspense=m;\nexports.SuspenseList=n;exports.isAsyncMode=function(){return!1};exports.isConcurrentMode=function(){return!1};exports.isContextConsumer=function(a){return v(a)===h};exports.isContextProvider=function(a){return v(a)===g};exports.isElement=function(a){return\"object\"===typeof a&&null!==a&&a.$$typeof===b};exports.isForwardRef=function(a){return v(a)===l};exports.isFragment=function(a){return v(a)===d};exports.isLazy=function(a){return v(a)===q};exports.isMemo=function(a){return v(a)===p};\nexports.isPortal=function(a){return v(a)===c};exports.isProfiler=function(a){return v(a)===f};exports.isStrictMode=function(a){return v(a)===e};exports.isSuspense=function(a){return v(a)===m};exports.isSuspenseList=function(a){return v(a)===n};\nexports.isValidElementType=function(a){return\"string\"===typeof a||\"function\"===typeof a||a===d||a===f||a===e||a===m||a===n||a===t||\"object\"===typeof a&&null!==a&&(a.$$typeof===q||a.$$typeof===p||a.$$typeof===g||a.$$typeof===h||a.$$typeof===l||a.$$typeof===u||void 0!==a.getModuleId)?!0:!1};exports.typeOf=v;\n","/**\n * @license React\n * react-is.development.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nif (process.env.NODE_ENV !== \"production\") {\n (function() {\n'use strict';\n\n// ATTENTION\n// When adding new symbols to this file,\n// Please consider also adding to 'react-devtools-shared/src/backend/ReactSymbols'\n// The Symbol used to tag the ReactElement-like types.\nvar REACT_ELEMENT_TYPE = Symbol.for('react.element');\nvar REACT_PORTAL_TYPE = Symbol.for('react.portal');\nvar REACT_FRAGMENT_TYPE = Symbol.for('react.fragment');\nvar REACT_STRICT_MODE_TYPE = Symbol.for('react.strict_mode');\nvar REACT_PROFILER_TYPE = Symbol.for('react.profiler');\nvar REACT_PROVIDER_TYPE = Symbol.for('react.provider');\nvar REACT_CONTEXT_TYPE = Symbol.for('react.context');\nvar REACT_SERVER_CONTEXT_TYPE = Symbol.for('react.server_context');\nvar REACT_FORWARD_REF_TYPE = Symbol.for('react.forward_ref');\nvar REACT_SUSPENSE_TYPE = Symbol.for('react.suspense');\nvar REACT_SUSPENSE_LIST_TYPE = Symbol.for('react.suspense_list');\nvar REACT_MEMO_TYPE = Symbol.for('react.memo');\nvar REACT_LAZY_TYPE = Symbol.for('react.lazy');\nvar REACT_OFFSCREEN_TYPE = Symbol.for('react.offscreen');\n\n// -----------------------------------------------------------------------------\n\nvar enableScopeAPI = false; // Experimental Create Event Handle API.\nvar enableCacheElement = false;\nvar enableTransitionTracing = false; // No known bugs, but needs performance testing\n\nvar enableLegacyHidden = false; // Enables unstable_avoidThisFallback feature in Fiber\n// stuff. Intended to enable React core members to more easily debug scheduling\n// issues in DEV builds.\n\nvar enableDebugTracing = false; // Track which Fiber(s) schedule render work.\n\nvar REACT_MODULE_REFERENCE;\n\n{\n REACT_MODULE_REFERENCE = Symbol.for('react.module.reference');\n}\n\nfunction isValidElementType(type) {\n if (typeof type === 'string' || typeof type === 'function') {\n return true;\n } // Note: typeof might be other than 'symbol' or 'number' (e.g. if it's a polyfill).\n\n\n if (type === REACT_FRAGMENT_TYPE || type === REACT_PROFILER_TYPE || enableDebugTracing || type === REACT_STRICT_MODE_TYPE || type === REACT_SUSPENSE_TYPE || type === REACT_SUSPENSE_LIST_TYPE || enableLegacyHidden || type === REACT_OFFSCREEN_TYPE || enableScopeAPI || enableCacheElement || enableTransitionTracing ) {\n return true;\n }\n\n if (typeof type === 'object' && type !== null) {\n if (type.$$typeof === REACT_LAZY_TYPE || type.$$typeof === REACT_MEMO_TYPE || type.$$typeof === REACT_PROVIDER_TYPE || type.$$typeof === REACT_CONTEXT_TYPE || type.$$typeof === REACT_FORWARD_REF_TYPE || // This needs to include all possible module reference object\n // types supported by any Flight configuration anywhere since\n // we don't know which Flight build this will end up being used\n // with.\n type.$$typeof === REACT_MODULE_REFERENCE || type.getModuleId !== undefined) {\n return true;\n }\n }\n\n return false;\n}\n\nfunction typeOf(object) {\n if (typeof object === 'object' && object !== null) {\n var $$typeof = object.$$typeof;\n\n switch ($$typeof) {\n case REACT_ELEMENT_TYPE:\n var type = object.type;\n\n switch (type) {\n case REACT_FRAGMENT_TYPE:\n case REACT_PROFILER_TYPE:\n case REACT_STRICT_MODE_TYPE:\n case REACT_SUSPENSE_TYPE:\n case REACT_SUSPENSE_LIST_TYPE:\n return type;\n\n default:\n var $$typeofType = type && type.$$typeof;\n\n switch ($$typeofType) {\n case REACT_SERVER_CONTEXT_TYPE:\n case REACT_CONTEXT_TYPE:\n case REACT_FORWARD_REF_TYPE:\n case REACT_LAZY_TYPE:\n case REACT_MEMO_TYPE:\n case REACT_PROVIDER_TYPE:\n return $$typeofType;\n\n default:\n return $$typeof;\n }\n\n }\n\n case REACT_PORTAL_TYPE:\n return $$typeof;\n }\n }\n\n return undefined;\n}\nvar ContextConsumer = REACT_CONTEXT_TYPE;\nvar ContextProvider = REACT_PROVIDER_TYPE;\nvar Element = REACT_ELEMENT_TYPE;\nvar ForwardRef = REACT_FORWARD_REF_TYPE;\nvar Fragment = REACT_FRAGMENT_TYPE;\nvar Lazy = REACT_LAZY_TYPE;\nvar Memo = REACT_MEMO_TYPE;\nvar Portal = REACT_PORTAL_TYPE;\nvar Profiler = REACT_PROFILER_TYPE;\nvar StrictMode = REACT_STRICT_MODE_TYPE;\nvar Suspense = REACT_SUSPENSE_TYPE;\nvar SuspenseList = REACT_SUSPENSE_LIST_TYPE;\nvar hasWarnedAboutDeprecatedIsAsyncMode = false;\nvar hasWarnedAboutDeprecatedIsConcurrentMode = false; // AsyncMode should be deprecated\n\nfunction isAsyncMode(object) {\n {\n if (!hasWarnedAboutDeprecatedIsAsyncMode) {\n hasWarnedAboutDeprecatedIsAsyncMode = true; // Using console['warn'] to evade Babel and ESLint\n\n console['warn']('The ReactIs.isAsyncMode() alias has been deprecated, ' + 'and will be removed in React 18+.');\n }\n }\n\n return false;\n}\nfunction isConcurrentMode(object) {\n {\n if (!hasWarnedAboutDeprecatedIsConcurrentMode) {\n hasWarnedAboutDeprecatedIsConcurrentMode = true; // Using console['warn'] to evade Babel and ESLint\n\n console['warn']('The ReactIs.isConcurrentMode() alias has been deprecated, ' + 'and will be removed in React 18+.');\n }\n }\n\n return false;\n}\nfunction isContextConsumer(object) {\n return typeOf(object) === REACT_CONTEXT_TYPE;\n}\nfunction isContextProvider(object) {\n return typeOf(object) === REACT_PROVIDER_TYPE;\n}\nfunction isElement(object) {\n return typeof object === 'object' && object !== null && object.$$typeof === REACT_ELEMENT_TYPE;\n}\nfunction isForwardRef(object) {\n return typeOf(object) === REACT_FORWARD_REF_TYPE;\n}\nfunction isFragment(object) {\n return typeOf(object) === REACT_FRAGMENT_TYPE;\n}\nfunction isLazy(object) {\n return typeOf(object) === REACT_LAZY_TYPE;\n}\nfunction isMemo(object) {\n return typeOf(object) === REACT_MEMO_TYPE;\n}\nfunction isPortal(object) {\n return typeOf(object) === REACT_PORTAL_TYPE;\n}\nfunction isProfiler(object) {\n return typeOf(object) === REACT_PROFILER_TYPE;\n}\nfunction isStrictMode(object) {\n return typeOf(object) === REACT_STRICT_MODE_TYPE;\n}\nfunction isSuspense(object) {\n return typeOf(object) === REACT_SUSPENSE_TYPE;\n}\nfunction isSuspenseList(object) {\n return typeOf(object) === REACT_SUSPENSE_LIST_TYPE;\n}\n\nexports.ContextConsumer = ContextConsumer;\nexports.ContextProvider = ContextProvider;\nexports.Element = Element;\nexports.ForwardRef = ForwardRef;\nexports.Fragment = Fragment;\nexports.Lazy = Lazy;\nexports.Memo = Memo;\nexports.Portal = Portal;\nexports.Profiler = Profiler;\nexports.StrictMode = StrictMode;\nexports.Suspense = Suspense;\nexports.SuspenseList = SuspenseList;\nexports.isAsyncMode = isAsyncMode;\nexports.isConcurrentMode = isConcurrentMode;\nexports.isContextConsumer = isContextConsumer;\nexports.isContextProvider = isContextProvider;\nexports.isElement = isElement;\nexports.isForwardRef = isForwardRef;\nexports.isFragment = isFragment;\nexports.isLazy = isLazy;\nexports.isMemo = isMemo;\nexports.isPortal = isPortal;\nexports.isProfiler = isProfiler;\nexports.isStrictMode = isStrictMode;\nexports.isSuspense = isSuspense;\nexports.isSuspenseList = isSuspenseList;\nexports.isValidElementType = isValidElementType;\nexports.typeOf = typeOf;\n })();\n}\n","'use strict';\n\nif (process.env.NODE_ENV === 'production') {\n module.exports = require('./cjs/react-is.production.min.js');\n} else {\n module.exports = require('./cjs/react-is.development.js');\n}\n","import { ForwardRef, Memo } from 'react-is';\n\n// Simplified polyfill for IE11 support\n// https://github.com/JamesMGreene/Function.name/blob/58b314d4a983110c3682f1228f845d39ccca1817/Function.name.js#L3\nconst fnNameMatchRegex = /^\\s*function(?:\\s|\\s*\\/\\*.*\\*\\/\\s*)+([^(\\s/]*)\\s*/;\nexport function getFunctionName(fn) {\n const match = `${fn}`.match(fnNameMatchRegex);\n const name = match && match[1];\n return name || '';\n}\nfunction getFunctionComponentName(Component, fallback = '') {\n return Component.displayName || Component.name || getFunctionName(Component) || fallback;\n}\nfunction getWrappedName(outerType, innerType, wrapperName) {\n const functionName = getFunctionComponentName(innerType);\n return outerType.displayName || (functionName !== '' ? `${wrapperName}(${functionName})` : wrapperName);\n}\n\n/**\n * cherry-pick from\n * https://github.com/facebook/react/blob/769b1f270e1251d9dbdce0fcbd9e92e502d059b8/packages/shared/getComponentName.js\n * originally forked from recompose/getDisplayName with added IE11 support\n */\nexport default function getDisplayName(Component) {\n if (Component == null) {\n return undefined;\n }\n if (typeof Component === 'string') {\n return Component;\n }\n if (typeof Component === 'function') {\n return getFunctionComponentName(Component, 'Component');\n }\n\n // TypeScript can't have components as objects but they exist in the form of `memo` or `Suspense`\n if (typeof Component === 'object') {\n switch (Component.$$typeof) {\n case ForwardRef:\n return getWrappedName(Component, Component.render, 'ForwardRef');\n case Memo:\n return getWrappedName(Component, Component.type, 'memo');\n default:\n return undefined;\n }\n }\n return undefined;\n}","export default function HTMLElementType(props, propName, componentName, location, propFullName) {\n if (process.env.NODE_ENV === 'production') {\n return null;\n }\n const propValue = props[propName];\n const safePropName = propFullName || propName;\n if (propValue == null) {\n return null;\n }\n if (propValue && propValue.nodeType !== 1) {\n return new Error(`Invalid ${location} \\`${safePropName}\\` supplied to \\`${componentName}\\`. ` + `Expected an HTMLElement.`);\n }\n return null;\n}","import PropTypes from 'prop-types';\nconst refType = PropTypes.oneOfType([PropTypes.func, PropTypes.object]);\nexport default refType;","import _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\n// It should to be noted that this function isn't equivalent to `text-transform: capitalize`.\n//\n// A strict capitalization should uppercase the first letter of each word in the sentence.\n// We only handle the first word.\nexport default function capitalize(string) {\n if (typeof string !== 'string') {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: \\`capitalize(string)\\` expects a string argument.` : _formatMuiErrorMessage(7));\n }\n return string.charAt(0).toUpperCase() + string.slice(1);\n}","/**\n * Safe chained function.\n *\n * Will only create a new function if needed,\n * otherwise will pass back existing functions or null.\n */\nexport default function createChainedFunction(...funcs) {\n return funcs.reduce((acc, func) => {\n if (func == null) {\n return acc;\n }\n return function chainedFunction(...args) {\n acc.apply(this, args);\n func.apply(this, args);\n };\n }, () => {});\n}","// Corresponds to 10 frames at 60 Hz.\n// A few bytes payload overhead when lodash/debounce is ~3 kB and debounce ~300 B.\nexport default function debounce(func, wait = 166) {\n let timeout;\n function debounced(...args) {\n const later = () => {\n // @ts-ignore\n func.apply(this, args);\n };\n clearTimeout(timeout);\n timeout = setTimeout(later, wait);\n }\n debounced.clear = () => {\n clearTimeout(timeout);\n };\n return debounced;\n}","export default function deprecatedPropType(validator, reason) {\n if (process.env.NODE_ENV === 'production') {\n return () => null;\n }\n return (props, propName, componentName, location, propFullName) => {\n const componentNameSafe = componentName || '<>';\n const propFullNameSafe = propFullName || propName;\n if (typeof props[propName] !== 'undefined') {\n return new Error(`The ${location} \\`${propFullNameSafe}\\` of ` + `\\`${componentNameSafe}\\` is deprecated. ${reason}`);\n }\n return null;\n };\n}","import * as React from 'react';\nexport default function isMuiElement(element, muiNames) {\n var _muiName, _element$type;\n return /*#__PURE__*/React.isValidElement(element) && muiNames.indexOf( // For server components `muiName` is avaialble in element.type._payload.value.muiName\n // relevant info - https://github.com/facebook/react/blob/2807d781a08db8e9873687fccc25c0f12b4fb3d4/packages/react/src/ReactLazy.js#L45\n // eslint-disable-next-line no-underscore-dangle\n (_muiName = element.type.muiName) != null ? _muiName : (_element$type = element.type) == null || (_element$type = _element$type._payload) == null || (_element$type = _element$type.value) == null ? void 0 : _element$type.muiName) !== -1;\n}","export default function ownerDocument(node) {\n return node && node.ownerDocument || document;\n}","import ownerDocument from '../ownerDocument';\nexport default function ownerWindow(node) {\n const doc = ownerDocument(node);\n return doc.defaultView || window;\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nexport default function requirePropFactory(componentNameInError, Component) {\n if (process.env.NODE_ENV === 'production') {\n return () => null;\n }\n\n // eslint-disable-next-line react/forbid-foreign-prop-types\n const prevPropTypes = Component ? _extends({}, Component.propTypes) : null;\n const requireProp = requiredProp => (props, propName, componentName, location, propFullName, ...args) => {\n const propFullNameSafe = propFullName || propName;\n const defaultTypeChecker = prevPropTypes == null ? void 0 : prevPropTypes[propFullNameSafe];\n if (defaultTypeChecker) {\n const typeCheckerResult = defaultTypeChecker(props, propName, componentName, location, propFullName, ...args);\n if (typeCheckerResult) {\n return typeCheckerResult;\n }\n }\n if (typeof props[propName] !== 'undefined' && !props[requiredProp]) {\n return new Error(`The prop \\`${propFullNameSafe}\\` of ` + `\\`${componentNameInError}\\` can only be used together with the \\`${requiredProp}\\` prop.`);\n }\n return null;\n };\n return requireProp;\n}","/**\n * TODO v5: consider making it private\n *\n * passes {value} to {ref}\n *\n * WARNING: Be sure to only call this inside a callback that is passed as a ref.\n * Otherwise, make sure to cleanup the previous {ref} if it changes. See\n * https://github.com/mui/material-ui/issues/13539\n *\n * Useful if you want to expose the ref of an inner component to the public API\n * while still using it inside the component.\n * @param ref A ref callback or ref object. If anything falsy, this is a no-op.\n */\nexport default function setRef(ref, value) {\n if (typeof ref === 'function') {\n ref(value);\n } else if (ref) {\n ref.current = value;\n }\n}","'use client';\n\nimport * as React from 'react';\n\n/**\n * A version of `React.useLayoutEffect` that does not show a warning when server-side rendering.\n * This is useful for effects that are only needed for client-side rendering but not for SSR.\n *\n * Before you use this hook, make sure to read https://gist.github.com/gaearon/e7d97cdf38a2907924ea12e4ebdf3c85\n * and confirm it doesn't apply to your use-case.\n */\nconst useEnhancedEffect = typeof window !== 'undefined' ? React.useLayoutEffect : React.useEffect;\nexport default useEnhancedEffect;","'use client';\n\nimport * as React from 'react';\nlet globalId = 0;\nfunction useGlobalId(idOverride) {\n const [defaultId, setDefaultId] = React.useState(idOverride);\n const id = idOverride || defaultId;\n React.useEffect(() => {\n if (defaultId == null) {\n // Fallback to this default id when possible.\n // Use the incrementing value for client-side rendering only.\n // We can't use it server-side.\n // If you want to use random values please consider the Birthday Problem: https://en.wikipedia.org/wiki/Birthday_problem\n globalId += 1;\n setDefaultId(`mui-${globalId}`);\n }\n }, [defaultId]);\n return id;\n}\n\n// downstream bundlers may remove unnecessary concatenation, but won't remove toString call -- Workaround for https://github.com/webpack/webpack/issues/14814\nconst maybeReactUseId = React['useId'.toString()];\n/**\n *\n * @example
    \n * @param idOverride\n * @returns {string}\n */\nexport default function useId(idOverride) {\n if (maybeReactUseId !== undefined) {\n const reactId = maybeReactUseId();\n return idOverride != null ? idOverride : reactId;\n }\n // eslint-disable-next-line react-hooks/rules-of-hooks -- `React.useId` is invariant at runtime.\n return useGlobalId(idOverride);\n}","export default function unsupportedProp(props, propName, componentName, location, propFullName) {\n if (process.env.NODE_ENV === 'production') {\n return null;\n }\n const propFullNameSafe = propFullName || propName;\n if (typeof props[propName] !== 'undefined') {\n return new Error(`The prop \\`${propFullNameSafe}\\` is not supported. Please remove it.`);\n }\n return null;\n}","'use client';\n\n/* eslint-disable react-hooks/rules-of-hooks, react-hooks/exhaustive-deps */\nimport * as React from 'react';\nexport default function useControlled({\n controlled,\n default: defaultProp,\n name,\n state = 'value'\n}) {\n // isControlled is ignored in the hook dependency lists as it should never change.\n const {\n current: isControlled\n } = React.useRef(controlled !== undefined);\n const [valueState, setValue] = React.useState(defaultProp);\n const value = isControlled ? controlled : valueState;\n if (process.env.NODE_ENV !== 'production') {\n React.useEffect(() => {\n if (isControlled !== (controlled !== undefined)) {\n console.error([`MUI: A component is changing the ${isControlled ? '' : 'un'}controlled ${state} state of ${name} to be ${isControlled ? 'un' : ''}controlled.`, 'Elements should not switch from uncontrolled to controlled (or vice versa).', `Decide between using a controlled or uncontrolled ${name} ` + 'element for the lifetime of the component.', \"The nature of the state is determined during the first render. It's considered controlled if the value is not `undefined`.\", 'More info: https://fb.me/react-controlled-components'].join('\\n'));\n }\n }, [state, name, controlled]);\n const {\n current: defaultValue\n } = React.useRef(defaultProp);\n React.useEffect(() => {\n if (!isControlled && defaultValue !== defaultProp) {\n console.error([`MUI: A component is changing the default ${state} state of an uncontrolled ${name} after being initialized. ` + `To suppress this warning opt to use a controlled ${name}.`].join('\\n'));\n }\n }, [JSON.stringify(defaultProp)]);\n }\n const setValueIfUncontrolled = React.useCallback(newValue => {\n if (!isControlled) {\n setValue(newValue);\n }\n }, []);\n return [value, setValueIfUncontrolled];\n}","'use client';\n\nimport * as React from 'react';\nimport useEnhancedEffect from '../useEnhancedEffect';\n\n/**\n * Inspired by https://github.com/facebook/react/issues/14099#issuecomment-440013892\n * See RFC in https://github.com/reactjs/rfcs/pull/220\n */\n\nfunction useEventCallback(fn) {\n const ref = React.useRef(fn);\n useEnhancedEffect(() => {\n ref.current = fn;\n });\n return React.useRef((...args) =>\n // @ts-expect-error hide `this`\n (0, ref.current)(...args)).current;\n}\nexport default useEventCallback;","'use client';\n\nimport * as React from 'react';\nimport setRef from '../setRef';\nexport default function useForkRef(...refs) {\n /**\n * This will create a new function if the refs passed to this hook change and are all defined.\n * This means react will call the old forkRef with `null` and the new forkRef\n * with the ref. Cleanup naturally emerges from this behavior.\n */\n return React.useMemo(() => {\n if (refs.every(ref => ref == null)) {\n return null;\n }\n return instance => {\n refs.forEach(ref => {\n setRef(ref, instance);\n });\n };\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, refs);\n}","'use client';\n\nimport * as React from 'react';\nconst UNINITIALIZED = {};\n\n/**\n * A React.useRef() that is initialized lazily with a function. Note that it accepts an optional\n * initialization argument, so the initialization function doesn't need to be an inline closure.\n *\n * @usage\n * const ref = useLazyRef(sortColumns, columns)\n */\nexport default function useLazyRef(init, initArg) {\n const ref = React.useRef(UNINITIALIZED);\n if (ref.current === UNINITIALIZED) {\n ref.current = init(initArg);\n }\n return ref;\n}","'use client';\n\nimport * as React from 'react';\nconst EMPTY = [];\n\n/**\n * A React.useEffect equivalent that runs once, when the component is mounted.\n */\nexport default function useOnMount(fn) {\n /* eslint-disable react-hooks/exhaustive-deps */\n React.useEffect(fn, EMPTY);\n /* eslint-enable react-hooks/exhaustive-deps */\n}","'use client';\n\nimport useLazyRef from '../useLazyRef/useLazyRef';\nimport useOnMount from '../useOnMount/useOnMount';\nexport class Timeout {\n constructor() {\n this.currentId = null;\n this.clear = () => {\n if (this.currentId !== null) {\n clearTimeout(this.currentId);\n this.currentId = null;\n }\n };\n this.disposeEffect = () => {\n return this.clear;\n };\n }\n static create() {\n return new Timeout();\n }\n /**\n * Executes `fn` after `delay`, clearing any previously scheduled call.\n */\n start(delay, fn) {\n this.clear();\n this.currentId = setTimeout(() => {\n this.currentId = null;\n fn();\n }, delay);\n }\n}\nexport default function useTimeout() {\n const timeout = useLazyRef(Timeout.create).current;\n useOnMount(timeout.disposeEffect);\n return timeout;\n}","'use client';\n\n// based on https://github.com/WICG/focus-visible/blob/v4.1.5/src/focus-visible.js\nimport * as React from 'react';\nimport { Timeout } from '../useTimeout/useTimeout';\nlet hadKeyboardEvent = true;\nlet hadFocusVisibleRecently = false;\nconst hadFocusVisibleRecentlyTimeout = new Timeout();\nconst inputTypesWhitelist = {\n text: true,\n search: true,\n url: true,\n tel: true,\n email: true,\n password: true,\n number: true,\n date: true,\n month: true,\n week: true,\n time: true,\n datetime: true,\n 'datetime-local': true\n};\n\n/**\n * Computes whether the given element should automatically trigger the\n * `focus-visible` class being added, i.e. whether it should always match\n * `:focus-visible` when focused.\n * @param {Element} node\n * @returns {boolean}\n */\nfunction focusTriggersKeyboardModality(node) {\n const {\n type,\n tagName\n } = node;\n if (tagName === 'INPUT' && inputTypesWhitelist[type] && !node.readOnly) {\n return true;\n }\n if (tagName === 'TEXTAREA' && !node.readOnly) {\n return true;\n }\n if (node.isContentEditable) {\n return true;\n }\n return false;\n}\n\n/**\n * Keep track of our keyboard modality state with `hadKeyboardEvent`.\n * If the most recent user interaction was via the keyboard;\n * and the key press did not include a meta, alt/option, or control key;\n * then the modality is keyboard. Otherwise, the modality is not keyboard.\n * @param {KeyboardEvent} event\n */\nfunction handleKeyDown(event) {\n if (event.metaKey || event.altKey || event.ctrlKey) {\n return;\n }\n hadKeyboardEvent = true;\n}\n\n/**\n * If at any point a user clicks with a pointing device, ensure that we change\n * the modality away from keyboard.\n * This avoids the situation where a user presses a key on an already focused\n * element, and then clicks on a different element, focusing it with a\n * pointing device, while we still think we're in keyboard modality.\n */\nfunction handlePointerDown() {\n hadKeyboardEvent = false;\n}\nfunction handleVisibilityChange() {\n if (this.visibilityState === 'hidden') {\n // If the tab becomes active again, the browser will handle calling focus\n // on the element (Safari actually calls it twice).\n // If this tab change caused a blur on an element with focus-visible,\n // re-apply the class when the user switches back to the tab.\n if (hadFocusVisibleRecently) {\n hadKeyboardEvent = true;\n }\n }\n}\nfunction prepare(doc) {\n doc.addEventListener('keydown', handleKeyDown, true);\n doc.addEventListener('mousedown', handlePointerDown, true);\n doc.addEventListener('pointerdown', handlePointerDown, true);\n doc.addEventListener('touchstart', handlePointerDown, true);\n doc.addEventListener('visibilitychange', handleVisibilityChange, true);\n}\nexport function teardown(doc) {\n doc.removeEventListener('keydown', handleKeyDown, true);\n doc.removeEventListener('mousedown', handlePointerDown, true);\n doc.removeEventListener('pointerdown', handlePointerDown, true);\n doc.removeEventListener('touchstart', handlePointerDown, true);\n doc.removeEventListener('visibilitychange', handleVisibilityChange, true);\n}\nfunction isFocusVisible(event) {\n const {\n target\n } = event;\n try {\n return target.matches(':focus-visible');\n } catch (error) {\n // Browsers not implementing :focus-visible will throw a SyntaxError.\n // We use our own heuristic for those browsers.\n // Rethrow might be better if it's not the expected error but do we really\n // want to crash if focus-visible malfunctioned?\n }\n\n // No need for validFocusTarget check. The user does that by attaching it to\n // focusable events only.\n return hadKeyboardEvent || focusTriggersKeyboardModality(target);\n}\nexport default function useIsFocusVisible() {\n const ref = React.useCallback(node => {\n if (node != null) {\n prepare(node.ownerDocument);\n }\n }, []);\n const isFocusVisibleRef = React.useRef(false);\n\n /**\n * Should be called if a blur event is fired\n */\n function handleBlurVisible() {\n // checking against potential state variable does not suffice if we focus and blur synchronously.\n // React wouldn't have time to trigger a re-render so `focusVisible` would be stale.\n // Ideally we would adjust `isFocusVisible(event)` to look at `relatedTarget` for blur events.\n // This doesn't work in IE11 due to https://github.com/facebook/react/issues/3751\n // TODO: check again if React releases their internal changes to focus event handling (https://github.com/facebook/react/pull/19186).\n if (isFocusVisibleRef.current) {\n // To detect a tab/window switch, we look for a blur event followed\n // rapidly by a visibility change.\n // If we don't see a visibility change within 100ms, it's probably a\n // regular focus change.\n hadFocusVisibleRecently = true;\n hadFocusVisibleRecentlyTimeout.start(100, () => {\n hadFocusVisibleRecently = false;\n });\n isFocusVisibleRef.current = false;\n return true;\n }\n return false;\n }\n\n /**\n * Should be called if a blur event is fired\n */\n function handleFocusVisible(event) {\n if (isFocusVisible(event)) {\n isFocusVisibleRef.current = true;\n return true;\n }\n return false;\n }\n return {\n isFocusVisibleRef,\n onFocus: handleFocusVisible,\n onBlur: handleBlurVisible,\n ref\n };\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\n/**\n * Add keys, values of `defaultProps` that does not exist in `props`\n * @param {object} defaultProps\n * @param {object} props\n * @returns {object} resolved props\n */\nexport default function resolveProps(defaultProps, props) {\n const output = _extends({}, props);\n Object.keys(defaultProps).forEach(propName => {\n if (propName.toString().match(/^(components|slots)$/)) {\n output[propName] = _extends({}, defaultProps[propName], output[propName]);\n } else if (propName.toString().match(/^(componentsProps|slotProps)$/)) {\n const defaultSlotProps = defaultProps[propName] || {};\n const slotProps = props[propName];\n output[propName] = {};\n if (!slotProps || !Object.keys(slotProps)) {\n // Reduce the iteration if the slot props is empty\n output[propName] = defaultSlotProps;\n } else if (!defaultSlotProps || !Object.keys(defaultSlotProps)) {\n // Reduce the iteration if the default slot props is empty\n output[propName] = slotProps;\n } else {\n output[propName] = _extends({}, slotProps);\n Object.keys(defaultSlotProps).forEach(slotPropName => {\n output[propName][slotPropName] = resolveProps(defaultSlotProps[slotPropName], slotProps[slotPropName]);\n });\n }\n } else if (output[propName] === undefined) {\n output[propName] = defaultProps[propName];\n }\n });\n return output;\n}","export default function composeClasses(slots, getUtilityClass, classes = undefined) {\n const output = {};\n Object.keys(slots).forEach(\n // `Object.keys(slots)` can't be wider than `T` because we infer `T` from `slots`.\n // @ts-expect-error https://github.com/microsoft/TypeScript/pull/12253#issuecomment-263132208\n slot => {\n output[slot] = slots[slot].reduce((acc, key) => {\n if (key) {\n const utilityClass = getUtilityClass(key);\n if (utilityClass !== '') {\n acc.push(utilityClass);\n }\n if (classes && classes[key]) {\n acc.push(classes[key]);\n }\n }\n return acc;\n }, []).join(' ');\n });\n return output;\n}","const defaultGenerator = componentName => componentName;\nconst createClassNameGenerator = () => {\n let generate = defaultGenerator;\n return {\n configure(generator) {\n generate = generator;\n },\n generate(componentName) {\n return generate(componentName);\n },\n reset() {\n generate = defaultGenerator;\n }\n };\n};\nconst ClassNameGenerator = createClassNameGenerator();\nexport default ClassNameGenerator;","import ClassNameGenerator from '../ClassNameGenerator';\nexport const globalStateClasses = {\n active: 'active',\n checked: 'checked',\n completed: 'completed',\n disabled: 'disabled',\n error: 'error',\n expanded: 'expanded',\n focused: 'focused',\n focusVisible: 'focusVisible',\n open: 'open',\n readOnly: 'readOnly',\n required: 'required',\n selected: 'selected'\n};\nexport default function generateUtilityClass(componentName, slot, globalStatePrefix = 'Mui') {\n const globalStateClass = globalStateClasses[slot];\n return globalStateClass ? `${globalStatePrefix}-${globalStateClass}` : `${ClassNameGenerator.generate(componentName)}-${slot}`;\n}\nexport function isGlobalState(slot) {\n return globalStateClasses[slot] !== undefined;\n}","import generateUtilityClass from '../generateUtilityClass';\nexport default function generateUtilityClasses(componentName, slots, globalStatePrefix = 'Mui') {\n const result = {};\n slots.forEach(slot => {\n result[slot] = generateUtilityClass(componentName, slot, globalStatePrefix);\n });\n return result;\n}","function clamp(val, min = Number.MIN_SAFE_INTEGER, max = Number.MAX_SAFE_INTEGER) {\n return Math.max(min, Math.min(val, max));\n}\nexport default clamp;","export default function _objectWithoutPropertiesLoose(source, excluded) {\n if (source == null) return {};\n var target = {};\n var sourceKeys = Object.keys(source);\n var key, i;\n for (i = 0; i < sourceKeys.length; i++) {\n key = sourceKeys[i];\n if (excluded.indexOf(key) >= 0) continue;\n target[key] = source[key];\n }\n return target;\n}","import _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nconst _excluded = [\"values\", \"unit\", \"step\"];\n// Sorted ASC by size. That's important.\n// It can't be configured as it's used statically for propTypes.\nexport const breakpointKeys = ['xs', 'sm', 'md', 'lg', 'xl'];\nconst sortBreakpointsValues = values => {\n const breakpointsAsArray = Object.keys(values).map(key => ({\n key,\n val: values[key]\n })) || [];\n // Sort in ascending order\n breakpointsAsArray.sort((breakpoint1, breakpoint2) => breakpoint1.val - breakpoint2.val);\n return breakpointsAsArray.reduce((acc, obj) => {\n return _extends({}, acc, {\n [obj.key]: obj.val\n });\n }, {});\n};\n\n// Keep in mind that @media is inclusive by the CSS specification.\nexport default function createBreakpoints(breakpoints) {\n const {\n // The breakpoint **start** at this value.\n // For instance with the first breakpoint xs: [xs, sm).\n values = {\n xs: 0,\n // phone\n sm: 600,\n // tablet\n md: 900,\n // small laptop\n lg: 1200,\n // desktop\n xl: 1536 // large screen\n },\n unit = 'px',\n step = 5\n } = breakpoints,\n other = _objectWithoutPropertiesLoose(breakpoints, _excluded);\n const sortedValues = sortBreakpointsValues(values);\n const keys = Object.keys(sortedValues);\n function up(key) {\n const value = typeof values[key] === 'number' ? values[key] : key;\n return `@media (min-width:${value}${unit})`;\n }\n function down(key) {\n const value = typeof values[key] === 'number' ? values[key] : key;\n return `@media (max-width:${value - step / 100}${unit})`;\n }\n function between(start, end) {\n const endIndex = keys.indexOf(end);\n return `@media (min-width:${typeof values[start] === 'number' ? values[start] : start}${unit}) and ` + `(max-width:${(endIndex !== -1 && typeof values[keys[endIndex]] === 'number' ? values[keys[endIndex]] : end) - step / 100}${unit})`;\n }\n function only(key) {\n if (keys.indexOf(key) + 1 < keys.length) {\n return between(key, keys[keys.indexOf(key) + 1]);\n }\n return up(key);\n }\n function not(key) {\n // handle first and last key separately, for better readability\n const keyIndex = keys.indexOf(key);\n if (keyIndex === 0) {\n return up(keys[1]);\n }\n if (keyIndex === keys.length - 1) {\n return down(keys[keyIndex]);\n }\n return between(key, keys[keys.indexOf(key) + 1]).replace('@media', '@media not all and');\n }\n return _extends({\n keys,\n values: sortedValues,\n up,\n down,\n between,\n only,\n not,\n unit\n }, other);\n}","const shape = {\n borderRadius: 4\n};\nexport default shape;","import PropTypes from 'prop-types';\nconst responsivePropType = process.env.NODE_ENV !== 'production' ? PropTypes.oneOfType([PropTypes.number, PropTypes.string, PropTypes.object, PropTypes.array]) : {};\nexport default responsivePropType;","import deepmerge from '@mui/utils/deepmerge';\nfunction merge(acc, item) {\n if (!item) {\n return acc;\n }\n return deepmerge(acc, item, {\n clone: false // No need to clone deep, it's way faster.\n });\n}\nexport default merge;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport PropTypes from 'prop-types';\nimport deepmerge from '@mui/utils/deepmerge';\nimport merge from './merge';\n\n// The breakpoint **start** at this value.\n// For instance with the first breakpoint xs: [xs, sm[.\nexport const values = {\n xs: 0,\n // phone\n sm: 600,\n // tablet\n md: 900,\n // small laptop\n lg: 1200,\n // desktop\n xl: 1536 // large screen\n};\nconst defaultBreakpoints = {\n // Sorted ASC by size. That's important.\n // It can't be configured as it's used statically for propTypes.\n keys: ['xs', 'sm', 'md', 'lg', 'xl'],\n up: key => `@media (min-width:${values[key]}px)`\n};\nexport function handleBreakpoints(props, propValue, styleFromPropValue) {\n const theme = props.theme || {};\n if (Array.isArray(propValue)) {\n const themeBreakpoints = theme.breakpoints || defaultBreakpoints;\n return propValue.reduce((acc, item, index) => {\n acc[themeBreakpoints.up(themeBreakpoints.keys[index])] = styleFromPropValue(propValue[index]);\n return acc;\n }, {});\n }\n if (typeof propValue === 'object') {\n const themeBreakpoints = theme.breakpoints || defaultBreakpoints;\n return Object.keys(propValue).reduce((acc, breakpoint) => {\n // key is breakpoint\n if (Object.keys(themeBreakpoints.values || values).indexOf(breakpoint) !== -1) {\n const mediaKey = themeBreakpoints.up(breakpoint);\n acc[mediaKey] = styleFromPropValue(propValue[breakpoint], breakpoint);\n } else {\n const cssKey = breakpoint;\n acc[cssKey] = propValue[cssKey];\n }\n return acc;\n }, {});\n }\n const output = styleFromPropValue(propValue);\n return output;\n}\nfunction breakpoints(styleFunction) {\n // false positive\n // eslint-disable-next-line react/function-component-definition\n const newStyleFunction = props => {\n const theme = props.theme || {};\n const base = styleFunction(props);\n const themeBreakpoints = theme.breakpoints || defaultBreakpoints;\n const extended = themeBreakpoints.keys.reduce((acc, key) => {\n if (props[key]) {\n acc = acc || {};\n acc[themeBreakpoints.up(key)] = styleFunction(_extends({\n theme\n }, props[key]));\n }\n return acc;\n }, null);\n return merge(base, extended);\n };\n newStyleFunction.propTypes = process.env.NODE_ENV !== 'production' ? _extends({}, styleFunction.propTypes, {\n xs: PropTypes.object,\n sm: PropTypes.object,\n md: PropTypes.object,\n lg: PropTypes.object,\n xl: PropTypes.object\n }) : {};\n newStyleFunction.filterProps = ['xs', 'sm', 'md', 'lg', 'xl', ...styleFunction.filterProps];\n return newStyleFunction;\n}\nexport function createEmptyBreakpointObject(breakpointsInput = {}) {\n var _breakpointsInput$key;\n const breakpointsInOrder = (_breakpointsInput$key = breakpointsInput.keys) == null ? void 0 : _breakpointsInput$key.reduce((acc, key) => {\n const breakpointStyleKey = breakpointsInput.up(key);\n acc[breakpointStyleKey] = {};\n return acc;\n }, {});\n return breakpointsInOrder || {};\n}\nexport function removeUnusedBreakpoints(breakpointKeys, style) {\n return breakpointKeys.reduce((acc, key) => {\n const breakpointOutput = acc[key];\n const isBreakpointUnused = !breakpointOutput || Object.keys(breakpointOutput).length === 0;\n if (isBreakpointUnused) {\n delete acc[key];\n }\n return acc;\n }, style);\n}\nexport function mergeBreakpointsInOrder(breakpointsInput, ...styles) {\n const emptyBreakpoints = createEmptyBreakpointObject(breakpointsInput);\n const mergedOutput = [emptyBreakpoints, ...styles].reduce((prev, next) => deepmerge(prev, next), {});\n return removeUnusedBreakpoints(Object.keys(emptyBreakpoints), mergedOutput);\n}\n\n// compute base for responsive values; e.g.,\n// [1,2,3] => {xs: true, sm: true, md: true}\n// {xs: 1, sm: 2, md: 3} => {xs: true, sm: true, md: true}\nexport function computeBreakpointsBase(breakpointValues, themeBreakpoints) {\n // fixed value\n if (typeof breakpointValues !== 'object') {\n return {};\n }\n const base = {};\n const breakpointsKeys = Object.keys(themeBreakpoints);\n if (Array.isArray(breakpointValues)) {\n breakpointsKeys.forEach((breakpoint, i) => {\n if (i < breakpointValues.length) {\n base[breakpoint] = true;\n }\n });\n } else {\n breakpointsKeys.forEach(breakpoint => {\n if (breakpointValues[breakpoint] != null) {\n base[breakpoint] = true;\n }\n });\n }\n return base;\n}\nexport function resolveBreakpointValues({\n values: breakpointValues,\n breakpoints: themeBreakpoints,\n base: customBase\n}) {\n const base = customBase || computeBreakpointsBase(breakpointValues, themeBreakpoints);\n const keys = Object.keys(base);\n if (keys.length === 0) {\n return breakpointValues;\n }\n let previous;\n return keys.reduce((acc, breakpoint, i) => {\n if (Array.isArray(breakpointValues)) {\n acc[breakpoint] = breakpointValues[i] != null ? breakpointValues[i] : breakpointValues[previous];\n previous = i;\n } else if (typeof breakpointValues === 'object') {\n acc[breakpoint] = breakpointValues[breakpoint] != null ? breakpointValues[breakpoint] : breakpointValues[previous];\n previous = breakpoint;\n } else {\n acc[breakpoint] = breakpointValues;\n }\n return acc;\n }, {});\n}\nexport default breakpoints;","import capitalize from '@mui/utils/capitalize';\nimport responsivePropType from './responsivePropType';\nimport { handleBreakpoints } from './breakpoints';\nexport function getPath(obj, path, checkVars = true) {\n if (!path || typeof path !== 'string') {\n return null;\n }\n\n // Check if CSS variables are used\n if (obj && obj.vars && checkVars) {\n const val = `vars.${path}`.split('.').reduce((acc, item) => acc && acc[item] ? acc[item] : null, obj);\n if (val != null) {\n return val;\n }\n }\n return path.split('.').reduce((acc, item) => {\n if (acc && acc[item] != null) {\n return acc[item];\n }\n return null;\n }, obj);\n}\nexport function getStyleValue(themeMapping, transform, propValueFinal, userValue = propValueFinal) {\n let value;\n if (typeof themeMapping === 'function') {\n value = themeMapping(propValueFinal);\n } else if (Array.isArray(themeMapping)) {\n value = themeMapping[propValueFinal] || userValue;\n } else {\n value = getPath(themeMapping, propValueFinal) || userValue;\n }\n if (transform) {\n value = transform(value, userValue, themeMapping);\n }\n return value;\n}\nfunction style(options) {\n const {\n prop,\n cssProperty = options.prop,\n themeKey,\n transform\n } = options;\n\n // false positive\n // eslint-disable-next-line react/function-component-definition\n const fn = props => {\n if (props[prop] == null) {\n return null;\n }\n const propValue = props[prop];\n const theme = props.theme;\n const themeMapping = getPath(theme, themeKey) || {};\n const styleFromPropValue = propValueFinal => {\n let value = getStyleValue(themeMapping, transform, propValueFinal);\n if (propValueFinal === value && typeof propValueFinal === 'string') {\n // Haven't found value\n value = getStyleValue(themeMapping, transform, `${prop}${propValueFinal === 'default' ? '' : capitalize(propValueFinal)}`, propValueFinal);\n }\n if (cssProperty === false) {\n return value;\n }\n return {\n [cssProperty]: value\n };\n };\n return handleBreakpoints(props, propValue, styleFromPropValue);\n };\n fn.propTypes = process.env.NODE_ENV !== 'production' ? {\n [prop]: responsivePropType\n } : {};\n fn.filterProps = [prop];\n return fn;\n}\nexport default style;","export default function memoize(fn) {\n const cache = {};\n return arg => {\n if (cache[arg] === undefined) {\n cache[arg] = fn(arg);\n }\n return cache[arg];\n };\n}","import responsivePropType from './responsivePropType';\nimport { handleBreakpoints } from './breakpoints';\nimport { getPath } from './style';\nimport merge from './merge';\nimport memoize from './memoize';\nconst properties = {\n m: 'margin',\n p: 'padding'\n};\nconst directions = {\n t: 'Top',\n r: 'Right',\n b: 'Bottom',\n l: 'Left',\n x: ['Left', 'Right'],\n y: ['Top', 'Bottom']\n};\nconst aliases = {\n marginX: 'mx',\n marginY: 'my',\n paddingX: 'px',\n paddingY: 'py'\n};\n\n// memoize() impact:\n// From 300,000 ops/sec\n// To 350,000 ops/sec\nconst getCssProperties = memoize(prop => {\n // It's not a shorthand notation.\n if (prop.length > 2) {\n if (aliases[prop]) {\n prop = aliases[prop];\n } else {\n return [prop];\n }\n }\n const [a, b] = prop.split('');\n const property = properties[a];\n const direction = directions[b] || '';\n return Array.isArray(direction) ? direction.map(dir => property + dir) : [property + direction];\n});\nexport const marginKeys = ['m', 'mt', 'mr', 'mb', 'ml', 'mx', 'my', 'margin', 'marginTop', 'marginRight', 'marginBottom', 'marginLeft', 'marginX', 'marginY', 'marginInline', 'marginInlineStart', 'marginInlineEnd', 'marginBlock', 'marginBlockStart', 'marginBlockEnd'];\nexport const paddingKeys = ['p', 'pt', 'pr', 'pb', 'pl', 'px', 'py', 'padding', 'paddingTop', 'paddingRight', 'paddingBottom', 'paddingLeft', 'paddingX', 'paddingY', 'paddingInline', 'paddingInlineStart', 'paddingInlineEnd', 'paddingBlock', 'paddingBlockStart', 'paddingBlockEnd'];\nconst spacingKeys = [...marginKeys, ...paddingKeys];\nexport function createUnaryUnit(theme, themeKey, defaultValue, propName) {\n var _getPath;\n const themeSpacing = (_getPath = getPath(theme, themeKey, false)) != null ? _getPath : defaultValue;\n if (typeof themeSpacing === 'number') {\n return abs => {\n if (typeof abs === 'string') {\n return abs;\n }\n if (process.env.NODE_ENV !== 'production') {\n if (typeof abs !== 'number') {\n console.error(`MUI: Expected ${propName} argument to be a number or a string, got ${abs}.`);\n }\n }\n return themeSpacing * abs;\n };\n }\n if (Array.isArray(themeSpacing)) {\n return abs => {\n if (typeof abs === 'string') {\n return abs;\n }\n if (process.env.NODE_ENV !== 'production') {\n if (!Number.isInteger(abs)) {\n console.error([`MUI: The \\`theme.${themeKey}\\` array type cannot be combined with non integer values.` + `You should either use an integer value that can be used as index, or define the \\`theme.${themeKey}\\` as a number.`].join('\\n'));\n } else if (abs > themeSpacing.length - 1) {\n console.error([`MUI: The value provided (${abs}) overflows.`, `The supported values are: ${JSON.stringify(themeSpacing)}.`, `${abs} > ${themeSpacing.length - 1}, you need to add the missing values.`].join('\\n'));\n }\n }\n return themeSpacing[abs];\n };\n }\n if (typeof themeSpacing === 'function') {\n return themeSpacing;\n }\n if (process.env.NODE_ENV !== 'production') {\n console.error([`MUI: The \\`theme.${themeKey}\\` value (${themeSpacing}) is invalid.`, 'It should be a number, an array or a function.'].join('\\n'));\n }\n return () => undefined;\n}\nexport function createUnarySpacing(theme) {\n return createUnaryUnit(theme, 'spacing', 8, 'spacing');\n}\nexport function getValue(transformer, propValue) {\n if (typeof propValue === 'string' || propValue == null) {\n return propValue;\n }\n const abs = Math.abs(propValue);\n const transformed = transformer(abs);\n if (propValue >= 0) {\n return transformed;\n }\n if (typeof transformed === 'number') {\n return -transformed;\n }\n return `-${transformed}`;\n}\nexport function getStyleFromPropValue(cssProperties, transformer) {\n return propValue => cssProperties.reduce((acc, cssProperty) => {\n acc[cssProperty] = getValue(transformer, propValue);\n return acc;\n }, {});\n}\nfunction resolveCssProperty(props, keys, prop, transformer) {\n // Using a hash computation over an array iteration could be faster, but with only 28 items,\n // it's doesn't worth the bundle size.\n if (keys.indexOf(prop) === -1) {\n return null;\n }\n const cssProperties = getCssProperties(prop);\n const styleFromPropValue = getStyleFromPropValue(cssProperties, transformer);\n const propValue = props[prop];\n return handleBreakpoints(props, propValue, styleFromPropValue);\n}\nfunction style(props, keys) {\n const transformer = createUnarySpacing(props.theme);\n return Object.keys(props).map(prop => resolveCssProperty(props, keys, prop, transformer)).reduce(merge, {});\n}\nexport function margin(props) {\n return style(props, marginKeys);\n}\nmargin.propTypes = process.env.NODE_ENV !== 'production' ? marginKeys.reduce((obj, key) => {\n obj[key] = responsivePropType;\n return obj;\n}, {}) : {};\nmargin.filterProps = marginKeys;\nexport function padding(props) {\n return style(props, paddingKeys);\n}\npadding.propTypes = process.env.NODE_ENV !== 'production' ? paddingKeys.reduce((obj, key) => {\n obj[key] = responsivePropType;\n return obj;\n}, {}) : {};\npadding.filterProps = paddingKeys;\nfunction spacing(props) {\n return style(props, spacingKeys);\n}\nspacing.propTypes = process.env.NODE_ENV !== 'production' ? spacingKeys.reduce((obj, key) => {\n obj[key] = responsivePropType;\n return obj;\n}, {}) : {};\nspacing.filterProps = spacingKeys;\nexport default spacing;","import { createUnarySpacing } from '../spacing';\n\n// The different signatures imply different meaning for their arguments that can't be expressed structurally.\n// We express the difference with variable names.\n\nexport default function createSpacing(spacingInput = 8) {\n // Already transformed.\n if (spacingInput.mui) {\n return spacingInput;\n }\n\n // Material Design layouts are visually balanced. Most measurements align to an 8dp grid, which aligns both spacing and the overall layout.\n // Smaller components, such as icons, can align to a 4dp grid.\n // https://m2.material.io/design/layout/understanding-layout.html\n const transform = createUnarySpacing({\n spacing: spacingInput\n });\n const spacing = (...argsInput) => {\n if (process.env.NODE_ENV !== 'production') {\n if (!(argsInput.length <= 4)) {\n console.error(`MUI: Too many arguments provided, expected between 0 and 4, got ${argsInput.length}`);\n }\n }\n const args = argsInput.length === 0 ? [1] : argsInput;\n return args.map(argument => {\n const output = transform(argument);\n return typeof output === 'number' ? `${output}px` : output;\n }).join(' ');\n };\n spacing.mui = true;\n return spacing;\n}","import merge from './merge';\nfunction compose(...styles) {\n const handlers = styles.reduce((acc, style) => {\n style.filterProps.forEach(prop => {\n acc[prop] = style;\n });\n return acc;\n }, {});\n\n // false positive\n // eslint-disable-next-line react/function-component-definition\n const fn = props => {\n return Object.keys(props).reduce((acc, prop) => {\n if (handlers[prop]) {\n return merge(acc, handlers[prop](props));\n }\n return acc;\n }, {});\n };\n fn.propTypes = process.env.NODE_ENV !== 'production' ? styles.reduce((acc, style) => Object.assign(acc, style.propTypes), {}) : {};\n fn.filterProps = styles.reduce((acc, style) => acc.concat(style.filterProps), []);\n return fn;\n}\nexport default compose;","import responsivePropType from './responsivePropType';\nimport style from './style';\nimport compose from './compose';\nimport { createUnaryUnit, getValue } from './spacing';\nimport { handleBreakpoints } from './breakpoints';\nexport function borderTransform(value) {\n if (typeof value !== 'number') {\n return value;\n }\n return `${value}px solid`;\n}\nfunction createBorderStyle(prop, transform) {\n return style({\n prop,\n themeKey: 'borders',\n transform\n });\n}\nexport const border = createBorderStyle('border', borderTransform);\nexport const borderTop = createBorderStyle('borderTop', borderTransform);\nexport const borderRight = createBorderStyle('borderRight', borderTransform);\nexport const borderBottom = createBorderStyle('borderBottom', borderTransform);\nexport const borderLeft = createBorderStyle('borderLeft', borderTransform);\nexport const borderColor = createBorderStyle('borderColor');\nexport const borderTopColor = createBorderStyle('borderTopColor');\nexport const borderRightColor = createBorderStyle('borderRightColor');\nexport const borderBottomColor = createBorderStyle('borderBottomColor');\nexport const borderLeftColor = createBorderStyle('borderLeftColor');\nexport const outline = createBorderStyle('outline', borderTransform);\nexport const outlineColor = createBorderStyle('outlineColor');\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const borderRadius = props => {\n if (props.borderRadius !== undefined && props.borderRadius !== null) {\n const transformer = createUnaryUnit(props.theme, 'shape.borderRadius', 4, 'borderRadius');\n const styleFromPropValue = propValue => ({\n borderRadius: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.borderRadius, styleFromPropValue);\n }\n return null;\n};\nborderRadius.propTypes = process.env.NODE_ENV !== 'production' ? {\n borderRadius: responsivePropType\n} : {};\nborderRadius.filterProps = ['borderRadius'];\nconst borders = compose(border, borderTop, borderRight, borderBottom, borderLeft, borderColor, borderTopColor, borderRightColor, borderBottomColor, borderLeftColor, borderRadius, outline, outlineColor);\nexport default borders;","import style from './style';\nimport compose from './compose';\nimport { createUnaryUnit, getValue } from './spacing';\nimport { handleBreakpoints } from './breakpoints';\nimport responsivePropType from './responsivePropType';\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const gap = props => {\n if (props.gap !== undefined && props.gap !== null) {\n const transformer = createUnaryUnit(props.theme, 'spacing', 8, 'gap');\n const styleFromPropValue = propValue => ({\n gap: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.gap, styleFromPropValue);\n }\n return null;\n};\ngap.propTypes = process.env.NODE_ENV !== 'production' ? {\n gap: responsivePropType\n} : {};\ngap.filterProps = ['gap'];\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const columnGap = props => {\n if (props.columnGap !== undefined && props.columnGap !== null) {\n const transformer = createUnaryUnit(props.theme, 'spacing', 8, 'columnGap');\n const styleFromPropValue = propValue => ({\n columnGap: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.columnGap, styleFromPropValue);\n }\n return null;\n};\ncolumnGap.propTypes = process.env.NODE_ENV !== 'production' ? {\n columnGap: responsivePropType\n} : {};\ncolumnGap.filterProps = ['columnGap'];\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const rowGap = props => {\n if (props.rowGap !== undefined && props.rowGap !== null) {\n const transformer = createUnaryUnit(props.theme, 'spacing', 8, 'rowGap');\n const styleFromPropValue = propValue => ({\n rowGap: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.rowGap, styleFromPropValue);\n }\n return null;\n};\nrowGap.propTypes = process.env.NODE_ENV !== 'production' ? {\n rowGap: responsivePropType\n} : {};\nrowGap.filterProps = ['rowGap'];\nexport const gridColumn = style({\n prop: 'gridColumn'\n});\nexport const gridRow = style({\n prop: 'gridRow'\n});\nexport const gridAutoFlow = style({\n prop: 'gridAutoFlow'\n});\nexport const gridAutoColumns = style({\n prop: 'gridAutoColumns'\n});\nexport const gridAutoRows = style({\n prop: 'gridAutoRows'\n});\nexport const gridTemplateColumns = style({\n prop: 'gridTemplateColumns'\n});\nexport const gridTemplateRows = style({\n prop: 'gridTemplateRows'\n});\nexport const gridTemplateAreas = style({\n prop: 'gridTemplateAreas'\n});\nexport const gridArea = style({\n prop: 'gridArea'\n});\nconst grid = compose(gap, columnGap, rowGap, gridColumn, gridRow, gridAutoFlow, gridAutoColumns, gridAutoRows, gridTemplateColumns, gridTemplateRows, gridTemplateAreas, gridArea);\nexport default grid;","import style from './style';\nimport compose from './compose';\nexport function paletteTransform(value, userValue) {\n if (userValue === 'grey') {\n return userValue;\n }\n return value;\n}\nexport const color = style({\n prop: 'color',\n themeKey: 'palette',\n transform: paletteTransform\n});\nexport const bgcolor = style({\n prop: 'bgcolor',\n cssProperty: 'backgroundColor',\n themeKey: 'palette',\n transform: paletteTransform\n});\nexport const backgroundColor = style({\n prop: 'backgroundColor',\n themeKey: 'palette',\n transform: paletteTransform\n});\nconst palette = compose(color, bgcolor, backgroundColor);\nexport default palette;","import style from './style';\nimport compose from './compose';\nimport { handleBreakpoints, values as breakpointsValues } from './breakpoints';\nexport function sizingTransform(value) {\n return value <= 1 && value !== 0 ? `${value * 100}%` : value;\n}\nexport const width = style({\n prop: 'width',\n transform: sizingTransform\n});\nexport const maxWidth = props => {\n if (props.maxWidth !== undefined && props.maxWidth !== null) {\n const styleFromPropValue = propValue => {\n var _props$theme, _props$theme2;\n const breakpoint = ((_props$theme = props.theme) == null || (_props$theme = _props$theme.breakpoints) == null || (_props$theme = _props$theme.values) == null ? void 0 : _props$theme[propValue]) || breakpointsValues[propValue];\n if (!breakpoint) {\n return {\n maxWidth: sizingTransform(propValue)\n };\n }\n if (((_props$theme2 = props.theme) == null || (_props$theme2 = _props$theme2.breakpoints) == null ? void 0 : _props$theme2.unit) !== 'px') {\n return {\n maxWidth: `${breakpoint}${props.theme.breakpoints.unit}`\n };\n }\n return {\n maxWidth: breakpoint\n };\n };\n return handleBreakpoints(props, props.maxWidth, styleFromPropValue);\n }\n return null;\n};\nmaxWidth.filterProps = ['maxWidth'];\nexport const minWidth = style({\n prop: 'minWidth',\n transform: sizingTransform\n});\nexport const height = style({\n prop: 'height',\n transform: sizingTransform\n});\nexport const maxHeight = style({\n prop: 'maxHeight',\n transform: sizingTransform\n});\nexport const minHeight = style({\n prop: 'minHeight',\n transform: sizingTransform\n});\nexport const sizeWidth = style({\n prop: 'size',\n cssProperty: 'width',\n transform: sizingTransform\n});\nexport const sizeHeight = style({\n prop: 'size',\n cssProperty: 'height',\n transform: sizingTransform\n});\nexport const boxSizing = style({\n prop: 'boxSizing'\n});\nconst sizing = compose(width, maxWidth, minWidth, height, maxHeight, minHeight, boxSizing);\nexport default sizing;","import { padding, margin } from '../spacing';\nimport { borderRadius, borderTransform } from '../borders';\nimport { gap, rowGap, columnGap } from '../cssGrid';\nimport { paletteTransform } from '../palette';\nimport { maxWidth, sizingTransform } from '../sizing';\nconst defaultSxConfig = {\n // borders\n border: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderTop: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderRight: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderBottom: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderLeft: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderColor: {\n themeKey: 'palette'\n },\n borderTopColor: {\n themeKey: 'palette'\n },\n borderRightColor: {\n themeKey: 'palette'\n },\n borderBottomColor: {\n themeKey: 'palette'\n },\n borderLeftColor: {\n themeKey: 'palette'\n },\n outline: {\n themeKey: 'borders',\n transform: borderTransform\n },\n outlineColor: {\n themeKey: 'palette'\n },\n borderRadius: {\n themeKey: 'shape.borderRadius',\n style: borderRadius\n },\n // palette\n color: {\n themeKey: 'palette',\n transform: paletteTransform\n },\n bgcolor: {\n themeKey: 'palette',\n cssProperty: 'backgroundColor',\n transform: paletteTransform\n },\n backgroundColor: {\n themeKey: 'palette',\n transform: paletteTransform\n },\n // spacing\n p: {\n style: padding\n },\n pt: {\n style: padding\n },\n pr: {\n style: padding\n },\n pb: {\n style: padding\n },\n pl: {\n style: padding\n },\n px: {\n style: padding\n },\n py: {\n style: padding\n },\n padding: {\n style: padding\n },\n paddingTop: {\n style: padding\n },\n paddingRight: {\n style: padding\n },\n paddingBottom: {\n style: padding\n },\n paddingLeft: {\n style: padding\n },\n paddingX: {\n style: padding\n },\n paddingY: {\n style: padding\n },\n paddingInline: {\n style: padding\n },\n paddingInlineStart: {\n style: padding\n },\n paddingInlineEnd: {\n style: padding\n },\n paddingBlock: {\n style: padding\n },\n paddingBlockStart: {\n style: padding\n },\n paddingBlockEnd: {\n style: padding\n },\n m: {\n style: margin\n },\n mt: {\n style: margin\n },\n mr: {\n style: margin\n },\n mb: {\n style: margin\n },\n ml: {\n style: margin\n },\n mx: {\n style: margin\n },\n my: {\n style: margin\n },\n margin: {\n style: margin\n },\n marginTop: {\n style: margin\n },\n marginRight: {\n style: margin\n },\n marginBottom: {\n style: margin\n },\n marginLeft: {\n style: margin\n },\n marginX: {\n style: margin\n },\n marginY: {\n style: margin\n },\n marginInline: {\n style: margin\n },\n marginInlineStart: {\n style: margin\n },\n marginInlineEnd: {\n style: margin\n },\n marginBlock: {\n style: margin\n },\n marginBlockStart: {\n style: margin\n },\n marginBlockEnd: {\n style: margin\n },\n // display\n displayPrint: {\n cssProperty: false,\n transform: value => ({\n '@media print': {\n display: value\n }\n })\n },\n display: {},\n overflow: {},\n textOverflow: {},\n visibility: {},\n whiteSpace: {},\n // flexbox\n flexBasis: {},\n flexDirection: {},\n flexWrap: {},\n justifyContent: {},\n alignItems: {},\n alignContent: {},\n order: {},\n flex: {},\n flexGrow: {},\n flexShrink: {},\n alignSelf: {},\n justifyItems: {},\n justifySelf: {},\n // grid\n gap: {\n style: gap\n },\n rowGap: {\n style: rowGap\n },\n columnGap: {\n style: columnGap\n },\n gridColumn: {},\n gridRow: {},\n gridAutoFlow: {},\n gridAutoColumns: {},\n gridAutoRows: {},\n gridTemplateColumns: {},\n gridTemplateRows: {},\n gridTemplateAreas: {},\n gridArea: {},\n // positions\n position: {},\n zIndex: {\n themeKey: 'zIndex'\n },\n top: {},\n right: {},\n bottom: {},\n left: {},\n // shadows\n boxShadow: {\n themeKey: 'shadows'\n },\n // sizing\n width: {\n transform: sizingTransform\n },\n maxWidth: {\n style: maxWidth\n },\n minWidth: {\n transform: sizingTransform\n },\n height: {\n transform: sizingTransform\n },\n maxHeight: {\n transform: sizingTransform\n },\n minHeight: {\n transform: sizingTransform\n },\n boxSizing: {},\n // typography\n fontFamily: {\n themeKey: 'typography'\n },\n fontSize: {\n themeKey: 'typography'\n },\n fontStyle: {\n themeKey: 'typography'\n },\n fontWeight: {\n themeKey: 'typography'\n },\n letterSpacing: {},\n textTransform: {},\n lineHeight: {},\n textAlign: {},\n typography: {\n cssProperty: false,\n themeKey: 'typography'\n }\n};\nexport default defaultSxConfig;","import capitalize from '@mui/utils/capitalize';\nimport merge from '../merge';\nimport { getPath, getStyleValue as getValue } from '../style';\nimport { handleBreakpoints, createEmptyBreakpointObject, removeUnusedBreakpoints } from '../breakpoints';\nimport defaultSxConfig from './defaultSxConfig';\nfunction objectsHaveSameKeys(...objects) {\n const allKeys = objects.reduce((keys, object) => keys.concat(Object.keys(object)), []);\n const union = new Set(allKeys);\n return objects.every(object => union.size === Object.keys(object).length);\n}\nfunction callIfFn(maybeFn, arg) {\n return typeof maybeFn === 'function' ? maybeFn(arg) : maybeFn;\n}\n\n// eslint-disable-next-line @typescript-eslint/naming-convention\nexport function unstable_createStyleFunctionSx() {\n function getThemeValue(prop, val, theme, config) {\n const props = {\n [prop]: val,\n theme\n };\n const options = config[prop];\n if (!options) {\n return {\n [prop]: val\n };\n }\n const {\n cssProperty = prop,\n themeKey,\n transform,\n style\n } = options;\n if (val == null) {\n return null;\n }\n\n // TODO v6: remove, see https://github.com/mui/material-ui/pull/38123\n if (themeKey === 'typography' && val === 'inherit') {\n return {\n [prop]: val\n };\n }\n const themeMapping = getPath(theme, themeKey) || {};\n if (style) {\n return style(props);\n }\n const styleFromPropValue = propValueFinal => {\n let value = getValue(themeMapping, transform, propValueFinal);\n if (propValueFinal === value && typeof propValueFinal === 'string') {\n // Haven't found value\n value = getValue(themeMapping, transform, `${prop}${propValueFinal === 'default' ? '' : capitalize(propValueFinal)}`, propValueFinal);\n }\n if (cssProperty === false) {\n return value;\n }\n return {\n [cssProperty]: value\n };\n };\n return handleBreakpoints(props, val, styleFromPropValue);\n }\n function styleFunctionSx(props) {\n var _theme$unstable_sxCon;\n const {\n sx,\n theme = {}\n } = props || {};\n if (!sx) {\n return null; // Emotion & styled-components will neglect null\n }\n const config = (_theme$unstable_sxCon = theme.unstable_sxConfig) != null ? _theme$unstable_sxCon : defaultSxConfig;\n\n /*\n * Receive `sxInput` as object or callback\n * and then recursively check keys & values to create media query object styles.\n * (the result will be used in `styled`)\n */\n function traverse(sxInput) {\n let sxObject = sxInput;\n if (typeof sxInput === 'function') {\n sxObject = sxInput(theme);\n } else if (typeof sxInput !== 'object') {\n // value\n return sxInput;\n }\n if (!sxObject) {\n return null;\n }\n const emptyBreakpoints = createEmptyBreakpointObject(theme.breakpoints);\n const breakpointsKeys = Object.keys(emptyBreakpoints);\n let css = emptyBreakpoints;\n Object.keys(sxObject).forEach(styleKey => {\n const value = callIfFn(sxObject[styleKey], theme);\n if (value !== null && value !== undefined) {\n if (typeof value === 'object') {\n if (config[styleKey]) {\n css = merge(css, getThemeValue(styleKey, value, theme, config));\n } else {\n const breakpointsValues = handleBreakpoints({\n theme\n }, value, x => ({\n [styleKey]: x\n }));\n if (objectsHaveSameKeys(breakpointsValues, value)) {\n css[styleKey] = styleFunctionSx({\n sx: value,\n theme\n });\n } else {\n css = merge(css, breakpointsValues);\n }\n }\n } else {\n css = merge(css, getThemeValue(styleKey, value, theme, config));\n }\n }\n });\n return removeUnusedBreakpoints(breakpointsKeys, css);\n }\n return Array.isArray(sx) ? sx.map(traverse) : traverse(sx);\n }\n return styleFunctionSx;\n}\nconst styleFunctionSx = unstable_createStyleFunctionSx();\nstyleFunctionSx.filterProps = ['sx'];\nexport default styleFunctionSx;","/**\n * A universal utility to style components with multiple color modes. Always use it from the theme object.\n * It works with:\n * - [Basic theme](https://mui.com/material-ui/customization/dark-mode/)\n * - [CSS theme variables](https://mui.com/material-ui/experimental-api/css-theme-variables/overview/)\n * - Zero-runtime engine\n *\n * Tips: Use an array over object spread and place `theme.applyStyles()` last.\n *\n * ✅ [{ background: '#e5e5e5' }, theme.applyStyles('dark', { background: '#1c1c1c' })]\n *\n * 🚫 { background: '#e5e5e5', ...theme.applyStyles('dark', { background: '#1c1c1c' })}\n *\n * @example\n * 1. using with `styled`:\n * ```jsx\n * const Component = styled('div')(({ theme }) => [\n * { background: '#e5e5e5' },\n * theme.applyStyles('dark', {\n * background: '#1c1c1c',\n * color: '#fff',\n * }),\n * ]);\n * ```\n *\n * @example\n * 2. using with `sx` prop:\n * ```jsx\n * [\n * { background: '#e5e5e5' },\n * theme.applyStyles('dark', {\n * background: '#1c1c1c',\n * color: '#fff',\n * }),\n * ]}\n * />\n * ```\n *\n * @example\n * 3. theming a component:\n * ```jsx\n * extendTheme({\n * components: {\n * MuiButton: {\n * styleOverrides: {\n * root: ({ theme }) => [\n * { background: '#e5e5e5' },\n * theme.applyStyles('dark', {\n * background: '#1c1c1c',\n * color: '#fff',\n * }),\n * ],\n * },\n * }\n * }\n * })\n *```\n */\nexport default function applyStyles(key, styles) {\n // @ts-expect-error this is 'any' type\n const theme = this;\n if (theme.vars && typeof theme.getColorSchemeSelector === 'function') {\n // If CssVarsProvider is used as a provider,\n // returns '* :where([data-mui-color-scheme=\"light|dark\"]) &'\n const selector = theme.getColorSchemeSelector(key).replace(/(\\[[^\\]]+\\])/, '*:where($1)');\n return {\n [selector]: styles\n };\n }\n if (theme.palette.mode === key) {\n return styles;\n }\n return {};\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"breakpoints\", \"palette\", \"spacing\", \"shape\"];\nimport deepmerge from '@mui/utils/deepmerge';\nimport createBreakpoints from './createBreakpoints';\nimport shape from './shape';\nimport createSpacing from './createSpacing';\nimport styleFunctionSx from '../styleFunctionSx/styleFunctionSx';\nimport defaultSxConfig from '../styleFunctionSx/defaultSxConfig';\nimport applyStyles from './applyStyles';\nfunction createTheme(options = {}, ...args) {\n const {\n breakpoints: breakpointsInput = {},\n palette: paletteInput = {},\n spacing: spacingInput,\n shape: shapeInput = {}\n } = options,\n other = _objectWithoutPropertiesLoose(options, _excluded);\n const breakpoints = createBreakpoints(breakpointsInput);\n const spacing = createSpacing(spacingInput);\n let muiTheme = deepmerge({\n breakpoints,\n direction: 'ltr',\n components: {},\n // Inject component definitions.\n palette: _extends({\n mode: 'light'\n }, paletteInput),\n spacing,\n shape: _extends({}, shape, shapeInput)\n }, other);\n muiTheme.applyStyles = applyStyles;\n muiTheme = args.reduce((acc, argument) => deepmerge(acc, argument), muiTheme);\n muiTheme.unstable_sxConfig = _extends({}, defaultSxConfig, other == null ? void 0 : other.unstable_sxConfig);\n muiTheme.unstable_sx = function sx(props) {\n return styleFunctionSx({\n sx: props,\n theme: this\n });\n };\n return muiTheme;\n}\nexport default createTheme;","'use client';\n\nimport * as React from 'react';\nimport { ThemeContext } from '@mui/styled-engine';\nfunction isObjectEmpty(obj) {\n return Object.keys(obj).length === 0;\n}\nfunction useTheme(defaultTheme = null) {\n const contextTheme = React.useContext(ThemeContext);\n return !contextTheme || isObjectEmpty(contextTheme) ? defaultTheme : contextTheme;\n}\nexport default useTheme;","'use client';\n\nimport createTheme from './createTheme';\nimport useThemeWithoutDefault from './useThemeWithoutDefault';\nexport const systemDefaultTheme = createTheme();\nfunction useTheme(defaultTheme = systemDefaultTheme) {\n return useThemeWithoutDefault(defaultTheme);\n}\nexport default useTheme;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"ownerState\"],\n _excluded2 = [\"variants\"],\n _excluded3 = [\"name\", \"slot\", \"skipVariantsResolver\", \"skipSx\", \"overridesResolver\"];\n/* eslint-disable no-underscore-dangle */\nimport styledEngineStyled, { internal_processStyles as processStyles } from '@mui/styled-engine';\nimport { isPlainObject } from '@mui/utils/deepmerge';\nimport capitalize from '@mui/utils/capitalize';\nimport getDisplayName from '@mui/utils/getDisplayName';\nimport createTheme from './createTheme';\nimport styleFunctionSx from './styleFunctionSx';\nfunction isEmpty(obj) {\n return Object.keys(obj).length === 0;\n}\n\n// https://github.com/emotion-js/emotion/blob/26ded6109fcd8ca9875cc2ce4564fee678a3f3c5/packages/styled/src/utils.js#L40\nfunction isStringTag(tag) {\n return typeof tag === 'string' &&\n // 96 is one less than the char code\n // for \"a\" so this is checking that\n // it's a lowercase character\n tag.charCodeAt(0) > 96;\n}\n\n// Update /system/styled/#api in case if this changes\nexport function shouldForwardProp(prop) {\n return prop !== 'ownerState' && prop !== 'theme' && prop !== 'sx' && prop !== 'as';\n}\nexport const systemDefaultTheme = createTheme();\nconst lowercaseFirstLetter = string => {\n if (!string) {\n return string;\n }\n return string.charAt(0).toLowerCase() + string.slice(1);\n};\nfunction resolveTheme({\n defaultTheme,\n theme,\n themeId\n}) {\n return isEmpty(theme) ? defaultTheme : theme[themeId] || theme;\n}\nfunction defaultOverridesResolver(slot) {\n if (!slot) {\n return null;\n }\n return (props, styles) => styles[slot];\n}\nfunction processStyleArg(callableStyle, _ref) {\n let {\n ownerState\n } = _ref,\n props = _objectWithoutPropertiesLoose(_ref, _excluded);\n const resolvedStylesArg = typeof callableStyle === 'function' ? callableStyle(_extends({\n ownerState\n }, props)) : callableStyle;\n if (Array.isArray(resolvedStylesArg)) {\n return resolvedStylesArg.flatMap(resolvedStyle => processStyleArg(resolvedStyle, _extends({\n ownerState\n }, props)));\n }\n if (!!resolvedStylesArg && typeof resolvedStylesArg === 'object' && Array.isArray(resolvedStylesArg.variants)) {\n const {\n variants = []\n } = resolvedStylesArg,\n otherStyles = _objectWithoutPropertiesLoose(resolvedStylesArg, _excluded2);\n let result = otherStyles;\n variants.forEach(variant => {\n let isMatch = true;\n if (typeof variant.props === 'function') {\n isMatch = variant.props(_extends({\n ownerState\n }, props, ownerState));\n } else {\n Object.keys(variant.props).forEach(key => {\n if ((ownerState == null ? void 0 : ownerState[key]) !== variant.props[key] && props[key] !== variant.props[key]) {\n isMatch = false;\n }\n });\n }\n if (isMatch) {\n if (!Array.isArray(result)) {\n result = [result];\n }\n result.push(typeof variant.style === 'function' ? variant.style(_extends({\n ownerState\n }, props, ownerState)) : variant.style);\n }\n });\n return result;\n }\n return resolvedStylesArg;\n}\nexport default function createStyled(input = {}) {\n const {\n themeId,\n defaultTheme = systemDefaultTheme,\n rootShouldForwardProp = shouldForwardProp,\n slotShouldForwardProp = shouldForwardProp\n } = input;\n const systemSx = props => {\n return styleFunctionSx(_extends({}, props, {\n theme: resolveTheme(_extends({}, props, {\n defaultTheme,\n themeId\n }))\n }));\n };\n systemSx.__mui_systemSx = true;\n return (tag, inputOptions = {}) => {\n // Filter out the `sx` style function from the previous styled component to prevent unnecessary styles generated by the composite components.\n processStyles(tag, styles => styles.filter(style => !(style != null && style.__mui_systemSx)));\n const {\n name: componentName,\n slot: componentSlot,\n skipVariantsResolver: inputSkipVariantsResolver,\n skipSx: inputSkipSx,\n // TODO v6: remove `lowercaseFirstLetter()` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n overridesResolver = defaultOverridesResolver(lowercaseFirstLetter(componentSlot))\n } = inputOptions,\n options = _objectWithoutPropertiesLoose(inputOptions, _excluded3);\n\n // if skipVariantsResolver option is defined, take the value, otherwise, true for root and false for other slots.\n const skipVariantsResolver = inputSkipVariantsResolver !== undefined ? inputSkipVariantsResolver :\n // TODO v6: remove `Root` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n componentSlot && componentSlot !== 'Root' && componentSlot !== 'root' || false;\n const skipSx = inputSkipSx || false;\n let label;\n if (process.env.NODE_ENV !== 'production') {\n if (componentName) {\n // TODO v6: remove `lowercaseFirstLetter()` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n label = `${componentName}-${lowercaseFirstLetter(componentSlot || 'Root')}`;\n }\n }\n let shouldForwardPropOption = shouldForwardProp;\n\n // TODO v6: remove `Root` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n if (componentSlot === 'Root' || componentSlot === 'root') {\n shouldForwardPropOption = rootShouldForwardProp;\n } else if (componentSlot) {\n // any other slot specified\n shouldForwardPropOption = slotShouldForwardProp;\n } else if (isStringTag(tag)) {\n // for string (html) tag, preserve the behavior in emotion & styled-components.\n shouldForwardPropOption = undefined;\n }\n const defaultStyledResolver = styledEngineStyled(tag, _extends({\n shouldForwardProp: shouldForwardPropOption,\n label\n }, options));\n const transformStyleArg = stylesArg => {\n // On the server Emotion doesn't use React.forwardRef for creating components, so the created\n // component stays as a function. This condition makes sure that we do not interpolate functions\n // which are basically components used as a selectors.\n if (typeof stylesArg === 'function' && stylesArg.__emotion_real !== stylesArg || isPlainObject(stylesArg)) {\n return props => processStyleArg(stylesArg, _extends({}, props, {\n theme: resolveTheme({\n theme: props.theme,\n defaultTheme,\n themeId\n })\n }));\n }\n return stylesArg;\n };\n const muiStyledResolver = (styleArg, ...expressions) => {\n let transformedStyleArg = transformStyleArg(styleArg);\n const expressionsWithDefaultTheme = expressions ? expressions.map(transformStyleArg) : [];\n if (componentName && overridesResolver) {\n expressionsWithDefaultTheme.push(props => {\n const theme = resolveTheme(_extends({}, props, {\n defaultTheme,\n themeId\n }));\n if (!theme.components || !theme.components[componentName] || !theme.components[componentName].styleOverrides) {\n return null;\n }\n const styleOverrides = theme.components[componentName].styleOverrides;\n const resolvedStyleOverrides = {};\n // TODO: v7 remove iteration and use `resolveStyleArg(styleOverrides[slot])` directly\n Object.entries(styleOverrides).forEach(([slotKey, slotStyle]) => {\n resolvedStyleOverrides[slotKey] = processStyleArg(slotStyle, _extends({}, props, {\n theme\n }));\n });\n return overridesResolver(props, resolvedStyleOverrides);\n });\n }\n if (componentName && !skipVariantsResolver) {\n expressionsWithDefaultTheme.push(props => {\n var _theme$components;\n const theme = resolveTheme(_extends({}, props, {\n defaultTheme,\n themeId\n }));\n const themeVariants = theme == null || (_theme$components = theme.components) == null || (_theme$components = _theme$components[componentName]) == null ? void 0 : _theme$components.variants;\n return processStyleArg({\n variants: themeVariants\n }, _extends({}, props, {\n theme\n }));\n });\n }\n if (!skipSx) {\n expressionsWithDefaultTheme.push(systemSx);\n }\n const numOfCustomFnsApplied = expressionsWithDefaultTheme.length - expressions.length;\n if (Array.isArray(styleArg) && numOfCustomFnsApplied > 0) {\n const placeholders = new Array(numOfCustomFnsApplied).fill('');\n // If the type is array, than we need to add placeholders in the template for the overrides, variants and the sx styles.\n transformedStyleArg = [...styleArg, ...placeholders];\n transformedStyleArg.raw = [...styleArg.raw, ...placeholders];\n }\n const Component = defaultStyledResolver(transformedStyleArg, ...expressionsWithDefaultTheme);\n if (process.env.NODE_ENV !== 'production') {\n let displayName;\n if (componentName) {\n displayName = `${componentName}${capitalize(componentSlot || '')}`;\n }\n if (displayName === undefined) {\n displayName = `Styled(${getDisplayName(tag)})`;\n }\n Component.displayName = displayName;\n }\n if (tag.muiName) {\n Component.muiName = tag.muiName;\n }\n return Component;\n };\n if (defaultStyledResolver.withConfig) {\n muiStyledResolver.withConfig = defaultStyledResolver.withConfig;\n }\n return muiStyledResolver;\n };\n}","import resolveProps from '@mui/utils/resolveProps';\nexport default function getThemeProps(params) {\n const {\n theme,\n name,\n props\n } = params;\n if (!theme || !theme.components || !theme.components[name] || !theme.components[name].defaultProps) {\n return props;\n }\n return resolveProps(theme.components[name].defaultProps, props);\n}","'use client';\n\nimport getThemeProps from './getThemeProps';\nimport useTheme from '../useTheme';\nexport default function useThemeProps({\n props,\n name,\n defaultTheme,\n themeId\n}) {\n let theme = useTheme(defaultTheme);\n if (themeId) {\n theme = theme[themeId] || theme;\n }\n const mergedProps = getThemeProps({\n theme,\n name,\n props\n });\n return mergedProps;\n}","import _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\n/* eslint-disable @typescript-eslint/naming-convention */\nimport clamp from '@mui/utils/clamp';\n/**\n * Returns a number whose value is limited to the given range.\n * @param {number} value The value to be clamped\n * @param {number} min The lower boundary of the output range\n * @param {number} max The upper boundary of the output range\n * @returns {number} A number in the range [min, max]\n */\nfunction clampWrapper(value, min = 0, max = 1) {\n if (process.env.NODE_ENV !== 'production') {\n if (value < min || value > max) {\n console.error(`MUI: The value provided ${value} is out of range [${min}, ${max}].`);\n }\n }\n return clamp(value, min, max);\n}\n\n/**\n * Converts a color from CSS hex format to CSS rgb format.\n * @param {string} color - Hex color, i.e. #nnn or #nnnnnn\n * @returns {string} A CSS rgb color string\n */\nexport function hexToRgb(color) {\n color = color.slice(1);\n const re = new RegExp(`.{1,${color.length >= 6 ? 2 : 1}}`, 'g');\n let colors = color.match(re);\n if (colors && colors[0].length === 1) {\n colors = colors.map(n => n + n);\n }\n return colors ? `rgb${colors.length === 4 ? 'a' : ''}(${colors.map((n, index) => {\n return index < 3 ? parseInt(n, 16) : Math.round(parseInt(n, 16) / 255 * 1000) / 1000;\n }).join(', ')})` : '';\n}\nfunction intToHex(int) {\n const hex = int.toString(16);\n return hex.length === 1 ? `0${hex}` : hex;\n}\n\n/**\n * Returns an object with the type and values of a color.\n *\n * Note: Does not support rgb % values.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @returns {object} - A MUI color object: {type: string, values: number[]}\n */\nexport function decomposeColor(color) {\n // Idempotent\n if (color.type) {\n return color;\n }\n if (color.charAt(0) === '#') {\n return decomposeColor(hexToRgb(color));\n }\n const marker = color.indexOf('(');\n const type = color.substring(0, marker);\n if (['rgb', 'rgba', 'hsl', 'hsla', 'color'].indexOf(type) === -1) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: Unsupported \\`${color}\\` color.\nThe following formats are supported: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color().` : _formatMuiErrorMessage(9, color));\n }\n let values = color.substring(marker + 1, color.length - 1);\n let colorSpace;\n if (type === 'color') {\n values = values.split(' ');\n colorSpace = values.shift();\n if (values.length === 4 && values[3].charAt(0) === '/') {\n values[3] = values[3].slice(1);\n }\n if (['srgb', 'display-p3', 'a98-rgb', 'prophoto-rgb', 'rec-2020'].indexOf(colorSpace) === -1) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: unsupported \\`${colorSpace}\\` color space.\nThe following color spaces are supported: srgb, display-p3, a98-rgb, prophoto-rgb, rec-2020.` : _formatMuiErrorMessage(10, colorSpace));\n }\n } else {\n values = values.split(',');\n }\n values = values.map(value => parseFloat(value));\n return {\n type,\n values,\n colorSpace\n };\n}\n\n/**\n * Returns a channel created from the input color.\n *\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @returns {string} - The channel for the color, that can be used in rgba or hsla colors\n */\nexport const colorChannel = color => {\n const decomposedColor = decomposeColor(color);\n return decomposedColor.values.slice(0, 3).map((val, idx) => decomposedColor.type.indexOf('hsl') !== -1 && idx !== 0 ? `${val}%` : val).join(' ');\n};\nexport const private_safeColorChannel = (color, warning) => {\n try {\n return colorChannel(color);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n};\n\n/**\n * Converts a color object with type and values to a string.\n * @param {object} color - Decomposed color\n * @param {string} color.type - One of: 'rgb', 'rgba', 'hsl', 'hsla', 'color'\n * @param {array} color.values - [n,n,n] or [n,n,n,n]\n * @returns {string} A CSS color string\n */\nexport function recomposeColor(color) {\n const {\n type,\n colorSpace\n } = color;\n let {\n values\n } = color;\n if (type.indexOf('rgb') !== -1) {\n // Only convert the first 3 values to int (i.e. not alpha)\n values = values.map((n, i) => i < 3 ? parseInt(n, 10) : n);\n } else if (type.indexOf('hsl') !== -1) {\n values[1] = `${values[1]}%`;\n values[2] = `${values[2]}%`;\n }\n if (type.indexOf('color') !== -1) {\n values = `${colorSpace} ${values.join(' ')}`;\n } else {\n values = `${values.join(', ')}`;\n }\n return `${type}(${values})`;\n}\n\n/**\n * Converts a color from CSS rgb format to CSS hex format.\n * @param {string} color - RGB color, i.e. rgb(n, n, n)\n * @returns {string} A CSS rgb color string, i.e. #nnnnnn\n */\nexport function rgbToHex(color) {\n // Idempotent\n if (color.indexOf('#') === 0) {\n return color;\n }\n const {\n values\n } = decomposeColor(color);\n return `#${values.map((n, i) => intToHex(i === 3 ? Math.round(255 * n) : n)).join('')}`;\n}\n\n/**\n * Converts a color from hsl format to rgb format.\n * @param {string} color - HSL color values\n * @returns {string} rgb color values\n */\nexport function hslToRgb(color) {\n color = decomposeColor(color);\n const {\n values\n } = color;\n const h = values[0];\n const s = values[1] / 100;\n const l = values[2] / 100;\n const a = s * Math.min(l, 1 - l);\n const f = (n, k = (n + h / 30) % 12) => l - a * Math.max(Math.min(k - 3, 9 - k, 1), -1);\n let type = 'rgb';\n const rgb = [Math.round(f(0) * 255), Math.round(f(8) * 255), Math.round(f(4) * 255)];\n if (color.type === 'hsla') {\n type += 'a';\n rgb.push(values[3]);\n }\n return recomposeColor({\n type,\n values: rgb\n });\n}\n/**\n * The relative brightness of any point in a color space,\n * normalized to 0 for darkest black and 1 for lightest white.\n *\n * Formula: https://www.w3.org/TR/WCAG20-TECHS/G17.html#G17-tests\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @returns {number} The relative brightness of the color in the range 0 - 1\n */\nexport function getLuminance(color) {\n color = decomposeColor(color);\n let rgb = color.type === 'hsl' || color.type === 'hsla' ? decomposeColor(hslToRgb(color)).values : color.values;\n rgb = rgb.map(val => {\n if (color.type !== 'color') {\n val /= 255; // normalized\n }\n return val <= 0.03928 ? val / 12.92 : ((val + 0.055) / 1.055) ** 2.4;\n });\n\n // Truncate at 3 digits\n return Number((0.2126 * rgb[0] + 0.7152 * rgb[1] + 0.0722 * rgb[2]).toFixed(3));\n}\n\n/**\n * Calculates the contrast ratio between two colors.\n *\n * Formula: https://www.w3.org/TR/WCAG20-TECHS/G17.html#G17-tests\n * @param {string} foreground - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla()\n * @param {string} background - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla()\n * @returns {number} A contrast ratio value in the range 0 - 21.\n */\nexport function getContrastRatio(foreground, background) {\n const lumA = getLuminance(foreground);\n const lumB = getLuminance(background);\n return (Math.max(lumA, lumB) + 0.05) / (Math.min(lumA, lumB) + 0.05);\n}\n\n/**\n * Sets the absolute transparency of a color.\n * Any existing alpha values are overwritten.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} value - value to set the alpha channel to in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function alpha(color, value) {\n color = decomposeColor(color);\n value = clampWrapper(value);\n if (color.type === 'rgb' || color.type === 'hsl') {\n color.type += 'a';\n }\n if (color.type === 'color') {\n color.values[3] = `/${value}`;\n } else {\n color.values[3] = value;\n }\n return recomposeColor(color);\n}\nexport function private_safeAlpha(color, value, warning) {\n try {\n return alpha(color, value);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Darkens a color.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} coefficient - multiplier in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function darken(color, coefficient) {\n color = decomposeColor(color);\n coefficient = clampWrapper(coefficient);\n if (color.type.indexOf('hsl') !== -1) {\n color.values[2] *= 1 - coefficient;\n } else if (color.type.indexOf('rgb') !== -1 || color.type.indexOf('color') !== -1) {\n for (let i = 0; i < 3; i += 1) {\n color.values[i] *= 1 - coefficient;\n }\n }\n return recomposeColor(color);\n}\nexport function private_safeDarken(color, coefficient, warning) {\n try {\n return darken(color, coefficient);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Lightens a color.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} coefficient - multiplier in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function lighten(color, coefficient) {\n color = decomposeColor(color);\n coefficient = clampWrapper(coefficient);\n if (color.type.indexOf('hsl') !== -1) {\n color.values[2] += (100 - color.values[2]) * coefficient;\n } else if (color.type.indexOf('rgb') !== -1) {\n for (let i = 0; i < 3; i += 1) {\n color.values[i] += (255 - color.values[i]) * coefficient;\n }\n } else if (color.type.indexOf('color') !== -1) {\n for (let i = 0; i < 3; i += 1) {\n color.values[i] += (1 - color.values[i]) * coefficient;\n }\n }\n return recomposeColor(color);\n}\nexport function private_safeLighten(color, coefficient, warning) {\n try {\n return lighten(color, coefficient);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Darken or lighten a color, depending on its luminance.\n * Light colors are darkened, dark colors are lightened.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} coefficient=0.15 - multiplier in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function emphasize(color, coefficient = 0.15) {\n return getLuminance(color) > 0.5 ? darken(color, coefficient) : lighten(color, coefficient);\n}\nexport function private_safeEmphasize(color, coefficient, warning) {\n try {\n return emphasize(color, coefficient);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Blend a transparent overlay color with a background color, resulting in a single\n * RGB color.\n * @param {string} background - CSS color\n * @param {string} overlay - CSS color\n * @param {number} opacity - Opacity multiplier in the range 0 - 1\n * @param {number} [gamma=1.0] - Gamma correction factor. For gamma-correct blending, 2.2 is usual.\n */\nexport function blend(background, overlay, opacity, gamma = 1.0) {\n const blendChannel = (b, o) => Math.round((b ** (1 / gamma) * (1 - opacity) + o ** (1 / gamma) * opacity) ** gamma);\n const backgroundColor = decomposeColor(background);\n const overlayColor = decomposeColor(overlay);\n const rgb = [blendChannel(backgroundColor.values[0], overlayColor.values[0]), blendChannel(backgroundColor.values[1], overlayColor.values[1]), blendChannel(backgroundColor.values[2], overlayColor.values[2])];\n return recomposeColor({\n type: 'rgb',\n values: rgb\n });\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nexport default function createMixins(breakpoints, mixins) {\n return _extends({\n toolbar: {\n minHeight: 56,\n [breakpoints.up('xs')]: {\n '@media (orientation: landscape)': {\n minHeight: 48\n }\n },\n [breakpoints.up('sm')]: {\n minHeight: 64\n }\n }\n }, mixins);\n}","const common = {\n black: '#000',\n white: '#fff'\n};\nexport default common;","const grey = {\n 50: '#fafafa',\n 100: '#f5f5f5',\n 200: '#eeeeee',\n 300: '#e0e0e0',\n 400: '#bdbdbd',\n 500: '#9e9e9e',\n 600: '#757575',\n 700: '#616161',\n 800: '#424242',\n 900: '#212121',\n A100: '#f5f5f5',\n A200: '#eeeeee',\n A400: '#bdbdbd',\n A700: '#616161'\n};\nexport default grey;","const purple = {\n 50: '#f3e5f5',\n 100: '#e1bee7',\n 200: '#ce93d8',\n 300: '#ba68c8',\n 400: '#ab47bc',\n 500: '#9c27b0',\n 600: '#8e24aa',\n 700: '#7b1fa2',\n 800: '#6a1b9a',\n 900: '#4a148c',\n A100: '#ea80fc',\n A200: '#e040fb',\n A400: '#d500f9',\n A700: '#aa00ff'\n};\nexport default purple;","const red = {\n 50: '#ffebee',\n 100: '#ffcdd2',\n 200: '#ef9a9a',\n 300: '#e57373',\n 400: '#ef5350',\n 500: '#f44336',\n 600: '#e53935',\n 700: '#d32f2f',\n 800: '#c62828',\n 900: '#b71c1c',\n A100: '#ff8a80',\n A200: '#ff5252',\n A400: '#ff1744',\n A700: '#d50000'\n};\nexport default red;","const orange = {\n 50: '#fff3e0',\n 100: '#ffe0b2',\n 200: '#ffcc80',\n 300: '#ffb74d',\n 400: '#ffa726',\n 500: '#ff9800',\n 600: '#fb8c00',\n 700: '#f57c00',\n 800: '#ef6c00',\n 900: '#e65100',\n A100: '#ffd180',\n A200: '#ffab40',\n A400: '#ff9100',\n A700: '#ff6d00'\n};\nexport default orange;","const blue = {\n 50: '#e3f2fd',\n 100: '#bbdefb',\n 200: '#90caf9',\n 300: '#64b5f6',\n 400: '#42a5f5',\n 500: '#2196f3',\n 600: '#1e88e5',\n 700: '#1976d2',\n 800: '#1565c0',\n 900: '#0d47a1',\n A100: '#82b1ff',\n A200: '#448aff',\n A400: '#2979ff',\n A700: '#2962ff'\n};\nexport default blue;","const lightBlue = {\n 50: '#e1f5fe',\n 100: '#b3e5fc',\n 200: '#81d4fa',\n 300: '#4fc3f7',\n 400: '#29b6f6',\n 500: '#03a9f4',\n 600: '#039be5',\n 700: '#0288d1',\n 800: '#0277bd',\n 900: '#01579b',\n A100: '#80d8ff',\n A200: '#40c4ff',\n A400: '#00b0ff',\n A700: '#0091ea'\n};\nexport default lightBlue;","const green = {\n 50: '#e8f5e9',\n 100: '#c8e6c9',\n 200: '#a5d6a7',\n 300: '#81c784',\n 400: '#66bb6a',\n 500: '#4caf50',\n 600: '#43a047',\n 700: '#388e3c',\n 800: '#2e7d32',\n 900: '#1b5e20',\n A100: '#b9f6ca',\n A200: '#69f0ae',\n A400: '#00e676',\n A700: '#00c853'\n};\nexport default green;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\nconst _excluded = [\"mode\", \"contrastThreshold\", \"tonalOffset\"];\nimport { deepmerge } from '@mui/utils';\nimport { darken, getContrastRatio, lighten } from '@mui/system';\nimport common from '../colors/common';\nimport grey from '../colors/grey';\nimport purple from '../colors/purple';\nimport red from '../colors/red';\nimport orange from '../colors/orange';\nimport blue from '../colors/blue';\nimport lightBlue from '../colors/lightBlue';\nimport green from '../colors/green';\nexport const light = {\n // The colors used to style the text.\n text: {\n // The most important text.\n primary: 'rgba(0, 0, 0, 0.87)',\n // Secondary text.\n secondary: 'rgba(0, 0, 0, 0.6)',\n // Disabled text have even lower visual prominence.\n disabled: 'rgba(0, 0, 0, 0.38)'\n },\n // The color used to divide different elements.\n divider: 'rgba(0, 0, 0, 0.12)',\n // The background colors used to style the surfaces.\n // Consistency between these values is important.\n background: {\n paper: common.white,\n default: common.white\n },\n // The colors used to style the action elements.\n action: {\n // The color of an active action like an icon button.\n active: 'rgba(0, 0, 0, 0.54)',\n // The color of an hovered action.\n hover: 'rgba(0, 0, 0, 0.04)',\n hoverOpacity: 0.04,\n // The color of a selected action.\n selected: 'rgba(0, 0, 0, 0.08)',\n selectedOpacity: 0.08,\n // The color of a disabled action.\n disabled: 'rgba(0, 0, 0, 0.26)',\n // The background color of a disabled action.\n disabledBackground: 'rgba(0, 0, 0, 0.12)',\n disabledOpacity: 0.38,\n focus: 'rgba(0, 0, 0, 0.12)',\n focusOpacity: 0.12,\n activatedOpacity: 0.12\n }\n};\nexport const dark = {\n text: {\n primary: common.white,\n secondary: 'rgba(255, 255, 255, 0.7)',\n disabled: 'rgba(255, 255, 255, 0.5)',\n icon: 'rgba(255, 255, 255, 0.5)'\n },\n divider: 'rgba(255, 255, 255, 0.12)',\n background: {\n paper: '#121212',\n default: '#121212'\n },\n action: {\n active: common.white,\n hover: 'rgba(255, 255, 255, 0.08)',\n hoverOpacity: 0.08,\n selected: 'rgba(255, 255, 255, 0.16)',\n selectedOpacity: 0.16,\n disabled: 'rgba(255, 255, 255, 0.3)',\n disabledBackground: 'rgba(255, 255, 255, 0.12)',\n disabledOpacity: 0.38,\n focus: 'rgba(255, 255, 255, 0.12)',\n focusOpacity: 0.12,\n activatedOpacity: 0.24\n }\n};\nfunction addLightOrDark(intent, direction, shade, tonalOffset) {\n const tonalOffsetLight = tonalOffset.light || tonalOffset;\n const tonalOffsetDark = tonalOffset.dark || tonalOffset * 1.5;\n if (!intent[direction]) {\n if (intent.hasOwnProperty(shade)) {\n intent[direction] = intent[shade];\n } else if (direction === 'light') {\n intent.light = lighten(intent.main, tonalOffsetLight);\n } else if (direction === 'dark') {\n intent.dark = darken(intent.main, tonalOffsetDark);\n }\n }\n}\nfunction getDefaultPrimary(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: blue[200],\n light: blue[50],\n dark: blue[400]\n };\n }\n return {\n main: blue[700],\n light: blue[400],\n dark: blue[800]\n };\n}\nfunction getDefaultSecondary(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: purple[200],\n light: purple[50],\n dark: purple[400]\n };\n }\n return {\n main: purple[500],\n light: purple[300],\n dark: purple[700]\n };\n}\nfunction getDefaultError(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: red[500],\n light: red[300],\n dark: red[700]\n };\n }\n return {\n main: red[700],\n light: red[400],\n dark: red[800]\n };\n}\nfunction getDefaultInfo(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: lightBlue[400],\n light: lightBlue[300],\n dark: lightBlue[700]\n };\n }\n return {\n main: lightBlue[700],\n light: lightBlue[500],\n dark: lightBlue[900]\n };\n}\nfunction getDefaultSuccess(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: green[400],\n light: green[300],\n dark: green[700]\n };\n }\n return {\n main: green[800],\n light: green[500],\n dark: green[900]\n };\n}\nfunction getDefaultWarning(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: orange[400],\n light: orange[300],\n dark: orange[700]\n };\n }\n return {\n main: '#ed6c02',\n // closest to orange[800] that pass 3:1.\n light: orange[500],\n dark: orange[900]\n };\n}\nexport default function createPalette(palette) {\n const {\n mode = 'light',\n contrastThreshold = 3,\n tonalOffset = 0.2\n } = palette,\n other = _objectWithoutPropertiesLoose(palette, _excluded);\n const primary = palette.primary || getDefaultPrimary(mode);\n const secondary = palette.secondary || getDefaultSecondary(mode);\n const error = palette.error || getDefaultError(mode);\n const info = palette.info || getDefaultInfo(mode);\n const success = palette.success || getDefaultSuccess(mode);\n const warning = palette.warning || getDefaultWarning(mode);\n\n // Use the same logic as\n // Bootstrap: https://github.com/twbs/bootstrap/blob/1d6e3710dd447de1a200f29e8fa521f8a0908f70/scss/_functions.scss#L59\n // and material-components-web https://github.com/material-components/material-components-web/blob/ac46b8863c4dab9fc22c4c662dc6bd1b65dd652f/packages/mdc-theme/_functions.scss#L54\n function getContrastText(background) {\n const contrastText = getContrastRatio(background, dark.text.primary) >= contrastThreshold ? dark.text.primary : light.text.primary;\n if (process.env.NODE_ENV !== 'production') {\n const contrast = getContrastRatio(background, contrastText);\n if (contrast < 3) {\n console.error([`MUI: The contrast ratio of ${contrast}:1 for ${contrastText} on ${background}`, 'falls below the WCAG recommended absolute minimum contrast ratio of 3:1.', 'https://www.w3.org/TR/2008/REC-WCAG20-20081211/#visual-audio-contrast-contrast'].join('\\n'));\n }\n }\n return contrastText;\n }\n const augmentColor = ({\n color,\n name,\n mainShade = 500,\n lightShade = 300,\n darkShade = 700\n }) => {\n color = _extends({}, color);\n if (!color.main && color[mainShade]) {\n color.main = color[mainShade];\n }\n if (!color.hasOwnProperty('main')) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: The color${name ? ` (${name})` : ''} provided to augmentColor(color) is invalid.\nThe color object needs to have a \\`main\\` property or a \\`${mainShade}\\` property.` : _formatMuiErrorMessage(11, name ? ` (${name})` : '', mainShade));\n }\n if (typeof color.main !== 'string') {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: The color${name ? ` (${name})` : ''} provided to augmentColor(color) is invalid.\n\\`color.main\\` should be a string, but \\`${JSON.stringify(color.main)}\\` was provided instead.\n\nDid you intend to use one of the following approaches?\n\nimport { green } from \"@mui/material/colors\";\n\nconst theme1 = createTheme({ palette: {\n primary: green,\n} });\n\nconst theme2 = createTheme({ palette: {\n primary: { main: green[500] },\n} });` : _formatMuiErrorMessage(12, name ? ` (${name})` : '', JSON.stringify(color.main)));\n }\n addLightOrDark(color, 'light', lightShade, tonalOffset);\n addLightOrDark(color, 'dark', darkShade, tonalOffset);\n if (!color.contrastText) {\n color.contrastText = getContrastText(color.main);\n }\n return color;\n };\n const modes = {\n dark,\n light\n };\n if (process.env.NODE_ENV !== 'production') {\n if (!modes[mode]) {\n console.error(`MUI: The palette mode \\`${mode}\\` is not supported.`);\n }\n }\n const paletteOutput = deepmerge(_extends({\n // A collection of common colors.\n common: _extends({}, common),\n // prevent mutable object.\n // The palette mode, can be light or dark.\n mode,\n // The colors used to represent primary interface elements for a user.\n primary: augmentColor({\n color: primary,\n name: 'primary'\n }),\n // The colors used to represent secondary interface elements for a user.\n secondary: augmentColor({\n color: secondary,\n name: 'secondary',\n mainShade: 'A400',\n lightShade: 'A200',\n darkShade: 'A700'\n }),\n // The colors used to represent interface elements that the user should be made aware of.\n error: augmentColor({\n color: error,\n name: 'error'\n }),\n // The colors used to represent potentially dangerous actions or important messages.\n warning: augmentColor({\n color: warning,\n name: 'warning'\n }),\n // The colors used to present information to the user that is neutral and not necessarily important.\n info: augmentColor({\n color: info,\n name: 'info'\n }),\n // The colors used to indicate the successful completion of an action that user triggered.\n success: augmentColor({\n color: success,\n name: 'success'\n }),\n // The grey colors.\n grey,\n // Used by `getContrastText()` to maximize the contrast between\n // the background and the text.\n contrastThreshold,\n // Takes a background color and returns the text color that maximizes the contrast.\n getContrastText,\n // Generate a rich color object.\n augmentColor,\n // Used by the functions below to shift a color's luminance by approximately\n // two indexes within its tonal palette.\n // E.g., shift from Red 500 to Red 300 or Red 700.\n tonalOffset\n }, modes[mode]), other);\n return paletteOutput;\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"fontFamily\", \"fontSize\", \"fontWeightLight\", \"fontWeightRegular\", \"fontWeightMedium\", \"fontWeightBold\", \"htmlFontSize\", \"allVariants\", \"pxToRem\"];\nimport { deepmerge } from '@mui/utils';\nfunction round(value) {\n return Math.round(value * 1e5) / 1e5;\n}\nconst caseAllCaps = {\n textTransform: 'uppercase'\n};\nconst defaultFontFamily = '\"Roboto\", \"Helvetica\", \"Arial\", sans-serif';\n\n/**\n * @see @link{https://m2.material.io/design/typography/the-type-system.html}\n * @see @link{https://m2.material.io/design/typography/understanding-typography.html}\n */\nexport default function createTypography(palette, typography) {\n const _ref = typeof typography === 'function' ? typography(palette) : typography,\n {\n fontFamily = defaultFontFamily,\n // The default font size of the Material Specification.\n fontSize = 14,\n // px\n fontWeightLight = 300,\n fontWeightRegular = 400,\n fontWeightMedium = 500,\n fontWeightBold = 700,\n // Tell MUI what's the font-size on the html element.\n // 16px is the default font-size used by browsers.\n htmlFontSize = 16,\n // Apply the CSS properties to all the variants.\n allVariants,\n pxToRem: pxToRem2\n } = _ref,\n other = _objectWithoutPropertiesLoose(_ref, _excluded);\n if (process.env.NODE_ENV !== 'production') {\n if (typeof fontSize !== 'number') {\n console.error('MUI: `fontSize` is required to be a number.');\n }\n if (typeof htmlFontSize !== 'number') {\n console.error('MUI: `htmlFontSize` is required to be a number.');\n }\n }\n const coef = fontSize / 14;\n const pxToRem = pxToRem2 || (size => `${size / htmlFontSize * coef}rem`);\n const buildVariant = (fontWeight, size, lineHeight, letterSpacing, casing) => _extends({\n fontFamily,\n fontWeight,\n fontSize: pxToRem(size),\n // Unitless following https://meyerweb.com/eric/thoughts/2006/02/08/unitless-line-heights/\n lineHeight\n }, fontFamily === defaultFontFamily ? {\n letterSpacing: `${round(letterSpacing / size)}em`\n } : {}, casing, allVariants);\n const variants = {\n h1: buildVariant(fontWeightLight, 96, 1.167, -1.5),\n h2: buildVariant(fontWeightLight, 60, 1.2, -0.5),\n h3: buildVariant(fontWeightRegular, 48, 1.167, 0),\n h4: buildVariant(fontWeightRegular, 34, 1.235, 0.25),\n h5: buildVariant(fontWeightRegular, 24, 1.334, 0),\n h6: buildVariant(fontWeightMedium, 20, 1.6, 0.15),\n subtitle1: buildVariant(fontWeightRegular, 16, 1.75, 0.15),\n subtitle2: buildVariant(fontWeightMedium, 14, 1.57, 0.1),\n body1: buildVariant(fontWeightRegular, 16, 1.5, 0.15),\n body2: buildVariant(fontWeightRegular, 14, 1.43, 0.15),\n button: buildVariant(fontWeightMedium, 14, 1.75, 0.4, caseAllCaps),\n caption: buildVariant(fontWeightRegular, 12, 1.66, 0.4),\n overline: buildVariant(fontWeightRegular, 12, 2.66, 1, caseAllCaps),\n // TODO v6: Remove handling of 'inherit' variant from the theme as it is already handled in Material UI's Typography component. Also, remember to remove the associated types.\n inherit: {\n fontFamily: 'inherit',\n fontWeight: 'inherit',\n fontSize: 'inherit',\n lineHeight: 'inherit',\n letterSpacing: 'inherit'\n }\n };\n return deepmerge(_extends({\n htmlFontSize,\n pxToRem,\n fontFamily,\n fontSize,\n fontWeightLight,\n fontWeightRegular,\n fontWeightMedium,\n fontWeightBold\n }, variants), other, {\n clone: false // No need to clone deep\n });\n}","const shadowKeyUmbraOpacity = 0.2;\nconst shadowKeyPenumbraOpacity = 0.14;\nconst shadowAmbientShadowOpacity = 0.12;\nfunction createShadow(...px) {\n return [`${px[0]}px ${px[1]}px ${px[2]}px ${px[3]}px rgba(0,0,0,${shadowKeyUmbraOpacity})`, `${px[4]}px ${px[5]}px ${px[6]}px ${px[7]}px rgba(0,0,0,${shadowKeyPenumbraOpacity})`, `${px[8]}px ${px[9]}px ${px[10]}px ${px[11]}px rgba(0,0,0,${shadowAmbientShadowOpacity})`].join(',');\n}\n\n// Values from https://github.com/material-components/material-components-web/blob/be8747f94574669cb5e7add1a7c54fa41a89cec7/packages/mdc-elevation/_variables.scss\nconst shadows = ['none', createShadow(0, 2, 1, -1, 0, 1, 1, 0, 0, 1, 3, 0), createShadow(0, 3, 1, -2, 0, 2, 2, 0, 0, 1, 5, 0), createShadow(0, 3, 3, -2, 0, 3, 4, 0, 0, 1, 8, 0), createShadow(0, 2, 4, -1, 0, 4, 5, 0, 0, 1, 10, 0), createShadow(0, 3, 5, -1, 0, 5, 8, 0, 0, 1, 14, 0), createShadow(0, 3, 5, -1, 0, 6, 10, 0, 0, 1, 18, 0), createShadow(0, 4, 5, -2, 0, 7, 10, 1, 0, 2, 16, 1), createShadow(0, 5, 5, -3, 0, 8, 10, 1, 0, 3, 14, 2), createShadow(0, 5, 6, -3, 0, 9, 12, 1, 0, 3, 16, 2), createShadow(0, 6, 6, -3, 0, 10, 14, 1, 0, 4, 18, 3), createShadow(0, 6, 7, -4, 0, 11, 15, 1, 0, 4, 20, 3), createShadow(0, 7, 8, -4, 0, 12, 17, 2, 0, 5, 22, 4), createShadow(0, 7, 8, -4, 0, 13, 19, 2, 0, 5, 24, 4), createShadow(0, 7, 9, -4, 0, 14, 21, 2, 0, 5, 26, 4), createShadow(0, 8, 9, -5, 0, 15, 22, 2, 0, 6, 28, 5), createShadow(0, 8, 10, -5, 0, 16, 24, 2, 0, 6, 30, 5), createShadow(0, 8, 11, -5, 0, 17, 26, 2, 0, 6, 32, 5), createShadow(0, 9, 11, -5, 0, 18, 28, 2, 0, 7, 34, 6), createShadow(0, 9, 12, -6, 0, 19, 29, 2, 0, 7, 36, 6), createShadow(0, 10, 13, -6, 0, 20, 31, 3, 0, 8, 38, 7), createShadow(0, 10, 13, -6, 0, 21, 33, 3, 0, 8, 40, 7), createShadow(0, 10, 14, -6, 0, 22, 35, 3, 0, 8, 42, 7), createShadow(0, 11, 14, -7, 0, 23, 36, 3, 0, 9, 44, 8), createShadow(0, 11, 15, -7, 0, 24, 38, 3, 0, 9, 46, 8)];\nexport default shadows;","import _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nconst _excluded = [\"duration\", \"easing\", \"delay\"];\n// Follow https://material.google.com/motion/duration-easing.html#duration-easing-natural-easing-curves\n// to learn the context in which each easing should be used.\nexport const easing = {\n // This is the most common easing curve.\n easeInOut: 'cubic-bezier(0.4, 0, 0.2, 1)',\n // Objects enter the screen at full velocity from off-screen and\n // slowly decelerate to a resting point.\n easeOut: 'cubic-bezier(0.0, 0, 0.2, 1)',\n // Objects leave the screen at full velocity. They do not decelerate when off-screen.\n easeIn: 'cubic-bezier(0.4, 0, 1, 1)',\n // The sharp curve is used by objects that may return to the screen at any time.\n sharp: 'cubic-bezier(0.4, 0, 0.6, 1)'\n};\n\n// Follow https://m2.material.io/guidelines/motion/duration-easing.html#duration-easing-common-durations\n// to learn when use what timing\nexport const duration = {\n shortest: 150,\n shorter: 200,\n short: 250,\n // most basic recommended timing\n standard: 300,\n // this is to be used in complex animations\n complex: 375,\n // recommended when something is entering screen\n enteringScreen: 225,\n // recommended when something is leaving screen\n leavingScreen: 195\n};\nfunction formatMs(milliseconds) {\n return `${Math.round(milliseconds)}ms`;\n}\nfunction getAutoHeightDuration(height) {\n if (!height) {\n return 0;\n }\n const constant = height / 36;\n\n // https://www.wolframalpha.com/input/?i=(4+%2B+15+*+(x+%2F+36+)+**+0.25+%2B+(x+%2F+36)+%2F+5)+*+10\n return Math.round((4 + 15 * constant ** 0.25 + constant / 5) * 10);\n}\nexport default function createTransitions(inputTransitions) {\n const mergedEasing = _extends({}, easing, inputTransitions.easing);\n const mergedDuration = _extends({}, duration, inputTransitions.duration);\n const create = (props = ['all'], options = {}) => {\n const {\n duration: durationOption = mergedDuration.standard,\n easing: easingOption = mergedEasing.easeInOut,\n delay = 0\n } = options,\n other = _objectWithoutPropertiesLoose(options, _excluded);\n if (process.env.NODE_ENV !== 'production') {\n const isString = value => typeof value === 'string';\n // IE11 support, replace with Number.isNaN\n // eslint-disable-next-line no-restricted-globals\n const isNumber = value => !isNaN(parseFloat(value));\n if (!isString(props) && !Array.isArray(props)) {\n console.error('MUI: Argument \"props\" must be a string or Array.');\n }\n if (!isNumber(durationOption) && !isString(durationOption)) {\n console.error(`MUI: Argument \"duration\" must be a number or a string but found ${durationOption}.`);\n }\n if (!isString(easingOption)) {\n console.error('MUI: Argument \"easing\" must be a string.');\n }\n if (!isNumber(delay) && !isString(delay)) {\n console.error('MUI: Argument \"delay\" must be a number or a string.');\n }\n if (typeof options !== 'object') {\n console.error(['MUI: Secong argument of transition.create must be an object.', \"Arguments should be either `create('prop1', options)` or `create(['prop1', 'prop2'], options)`\"].join('\\n'));\n }\n if (Object.keys(other).length !== 0) {\n console.error(`MUI: Unrecognized argument(s) [${Object.keys(other).join(',')}].`);\n }\n }\n return (Array.isArray(props) ? props : [props]).map(animatedProp => `${animatedProp} ${typeof durationOption === 'string' ? durationOption : formatMs(durationOption)} ${easingOption} ${typeof delay === 'string' ? delay : formatMs(delay)}`).join(',');\n };\n return _extends({\n getAutoHeightDuration,\n create\n }, inputTransitions, {\n easing: mergedEasing,\n duration: mergedDuration\n });\n}","// We need to centralize the zIndex definitions as they work\n// like global values in the browser.\nconst zIndex = {\n mobileStepper: 1000,\n fab: 1050,\n speedDial: 1050,\n appBar: 1100,\n drawer: 1200,\n modal: 1300,\n snackbar: 1400,\n tooltip: 1500\n};\nexport default zIndex;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\nconst _excluded = [\"breakpoints\", \"mixins\", \"spacing\", \"palette\", \"transitions\", \"typography\", \"shape\"];\nimport { deepmerge } from '@mui/utils';\nimport { createTheme as systemCreateTheme, unstable_defaultSxConfig as defaultSxConfig, unstable_styleFunctionSx as styleFunctionSx } from '@mui/system';\nimport generateUtilityClass from '@mui/utils/generateUtilityClass';\nimport createMixins from './createMixins';\nimport createPalette from './createPalette';\nimport createTypography from './createTypography';\nimport shadows from './shadows';\nimport createTransitions from './createTransitions';\nimport zIndex from './zIndex';\nfunction createTheme(options = {}, ...args) {\n const {\n mixins: mixinsInput = {},\n palette: paletteInput = {},\n transitions: transitionsInput = {},\n typography: typographyInput = {}\n } = options,\n other = _objectWithoutPropertiesLoose(options, _excluded);\n if (options.vars) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: \\`vars\\` is a private field used for CSS variables support.\nPlease use another name.` : _formatMuiErrorMessage(18));\n }\n const palette = createPalette(paletteInput);\n const systemTheme = systemCreateTheme(options);\n let muiTheme = deepmerge(systemTheme, {\n mixins: createMixins(systemTheme.breakpoints, mixinsInput),\n palette,\n // Don't use [...shadows] until you've verified its transpiled code is not invoking the iterator protocol.\n shadows: shadows.slice(),\n typography: createTypography(palette, typographyInput),\n transitions: createTransitions(transitionsInput),\n zIndex: _extends({}, zIndex)\n });\n muiTheme = deepmerge(muiTheme, other);\n muiTheme = args.reduce((acc, argument) => deepmerge(acc, argument), muiTheme);\n if (process.env.NODE_ENV !== 'production') {\n // TODO v6: Refactor to use globalStateClassesMapping from @mui/utils once `readOnly` state class is used in Rating component.\n const stateClasses = ['active', 'checked', 'completed', 'disabled', 'error', 'expanded', 'focused', 'focusVisible', 'required', 'selected'];\n const traverse = (node, component) => {\n let key;\n\n // eslint-disable-next-line guard-for-in, no-restricted-syntax\n for (key in node) {\n const child = node[key];\n if (stateClasses.indexOf(key) !== -1 && Object.keys(child).length > 0) {\n if (process.env.NODE_ENV !== 'production') {\n const stateClass = generateUtilityClass('', key);\n console.error([`MUI: The \\`${component}\\` component increases ` + `the CSS specificity of the \\`${key}\\` internal state.`, 'You can not override it like this: ', JSON.stringify(node, null, 2), '', `Instead, you need to use the '&.${stateClass}' syntax:`, JSON.stringify({\n root: {\n [`&.${stateClass}`]: child\n }\n }, null, 2), '', 'https://mui.com/r/state-classes-guide'].join('\\n'));\n }\n // Remove the style to prevent global conflicts.\n node[key] = {};\n }\n }\n };\n Object.keys(muiTheme.components).forEach(component => {\n const styleOverrides = muiTheme.components[component].styleOverrides;\n if (styleOverrides && component.indexOf('Mui') === 0) {\n traverse(styleOverrides, component);\n }\n });\n }\n muiTheme.unstable_sxConfig = _extends({}, defaultSxConfig, other == null ? void 0 : other.unstable_sxConfig);\n muiTheme.unstable_sx = function sx(props) {\n return styleFunctionSx({\n sx: props,\n theme: this\n });\n };\n return muiTheme;\n}\nlet warnedOnce = false;\nexport function createMuiTheme(...args) {\n if (process.env.NODE_ENV !== 'production') {\n if (!warnedOnce) {\n warnedOnce = true;\n console.error(['MUI: the createMuiTheme function was renamed to createTheme.', '', \"You should use `import { createTheme } from '@mui/material/styles'`\"].join('\\n'));\n }\n }\n return createTheme(...args);\n}\nexport default createTheme;","'use client';\n\nimport createTheme from './createTheme';\nconst defaultTheme = createTheme();\nexport default defaultTheme;","export default '$$material';","'use client';\n\nimport { useThemeProps as systemUseThemeProps } from '@mui/system';\nimport defaultTheme from './defaultTheme';\nimport THEME_ID from './identifier';\nexport default function useThemeProps({\n props,\n name\n}) {\n return systemUseThemeProps({\n props,\n name,\n defaultTheme,\n themeId: THEME_ID\n });\n}","'use client';\n\nimport { createStyled, shouldForwardProp } from '@mui/system';\nimport defaultTheme from './defaultTheme';\nimport THEME_ID from './identifier';\nexport const rootShouldForwardProp = prop => shouldForwardProp(prop) && prop !== 'classes';\nexport const slotShouldForwardProp = shouldForwardProp;\nconst styled = createStyled({\n themeId: THEME_ID,\n defaultTheme,\n rootShouldForwardProp\n});\nexport default styled;","import generateUtilityClasses from '@mui/utils/generateUtilityClasses';\nimport generateUtilityClass from '@mui/utils/generateUtilityClass';\nexport function getSvgIconUtilityClass(slot) {\n return generateUtilityClass('MuiSvgIcon', slot);\n}\nconst svgIconClasses = generateUtilityClasses('MuiSvgIcon', ['root', 'colorPrimary', 'colorSecondary', 'colorAction', 'colorError', 'colorDisabled', 'fontSizeInherit', 'fontSizeSmall', 'fontSizeMedium', 'fontSizeLarge']);\nexport default svgIconClasses;","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"children\", \"className\", \"color\", \"component\", \"fontSize\", \"htmlColor\", \"inheritViewBox\", \"titleAccess\", \"viewBox\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport clsx from 'clsx';\nimport { unstable_composeClasses as composeClasses } from '@mui/base/composeClasses';\nimport capitalize from '../utils/capitalize';\nimport useThemeProps from '../styles/useThemeProps';\nimport styled from '../styles/styled';\nimport { getSvgIconUtilityClass } from './svgIconClasses';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nimport { jsxs as _jsxs } from \"react/jsx-runtime\";\nconst useUtilityClasses = ownerState => {\n const {\n color,\n fontSize,\n classes\n } = ownerState;\n const slots = {\n root: ['root', color !== 'inherit' && `color${capitalize(color)}`, `fontSize${capitalize(fontSize)}`]\n };\n return composeClasses(slots, getSvgIconUtilityClass, classes);\n};\nconst SvgIconRoot = styled('svg', {\n name: 'MuiSvgIcon',\n slot: 'Root',\n overridesResolver: (props, styles) => {\n const {\n ownerState\n } = props;\n return [styles.root, ownerState.color !== 'inherit' && styles[`color${capitalize(ownerState.color)}`], styles[`fontSize${capitalize(ownerState.fontSize)}`]];\n }\n})(({\n theme,\n ownerState\n}) => {\n var _theme$transitions, _theme$transitions$cr, _theme$transitions2, _theme$typography, _theme$typography$pxT, _theme$typography2, _theme$typography2$px, _theme$typography3, _theme$typography3$px, _palette$ownerState$c, _palette, _palette2, _palette3;\n return {\n userSelect: 'none',\n width: '1em',\n height: '1em',\n display: 'inline-block',\n // the will define the property that has `currentColor`\n // e.g. heroicons uses fill=\"none\" and stroke=\"currentColor\"\n fill: ownerState.hasSvgAsChild ? undefined : 'currentColor',\n flexShrink: 0,\n transition: (_theme$transitions = theme.transitions) == null || (_theme$transitions$cr = _theme$transitions.create) == null ? void 0 : _theme$transitions$cr.call(_theme$transitions, 'fill', {\n duration: (_theme$transitions2 = theme.transitions) == null || (_theme$transitions2 = _theme$transitions2.duration) == null ? void 0 : _theme$transitions2.shorter\n }),\n fontSize: {\n inherit: 'inherit',\n small: ((_theme$typography = theme.typography) == null || (_theme$typography$pxT = _theme$typography.pxToRem) == null ? void 0 : _theme$typography$pxT.call(_theme$typography, 20)) || '1.25rem',\n medium: ((_theme$typography2 = theme.typography) == null || (_theme$typography2$px = _theme$typography2.pxToRem) == null ? void 0 : _theme$typography2$px.call(_theme$typography2, 24)) || '1.5rem',\n large: ((_theme$typography3 = theme.typography) == null || (_theme$typography3$px = _theme$typography3.pxToRem) == null ? void 0 : _theme$typography3$px.call(_theme$typography3, 35)) || '2.1875rem'\n }[ownerState.fontSize],\n // TODO v5 deprecate, v6 remove for sx\n color: (_palette$ownerState$c = (_palette = (theme.vars || theme).palette) == null || (_palette = _palette[ownerState.color]) == null ? void 0 : _palette.main) != null ? _palette$ownerState$c : {\n action: (_palette2 = (theme.vars || theme).palette) == null || (_palette2 = _palette2.action) == null ? void 0 : _palette2.active,\n disabled: (_palette3 = (theme.vars || theme).palette) == null || (_palette3 = _palette3.action) == null ? void 0 : _palette3.disabled,\n inherit: undefined\n }[ownerState.color]\n };\n});\nconst SvgIcon = /*#__PURE__*/React.forwardRef(function SvgIcon(inProps, ref) {\n const props = useThemeProps({\n props: inProps,\n name: 'MuiSvgIcon'\n });\n const {\n children,\n className,\n color = 'inherit',\n component = 'svg',\n fontSize = 'medium',\n htmlColor,\n inheritViewBox = false,\n titleAccess,\n viewBox = '0 0 24 24'\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const hasSvgAsChild = /*#__PURE__*/React.isValidElement(children) && children.type === 'svg';\n const ownerState = _extends({}, props, {\n color,\n component,\n fontSize,\n instanceFontSize: inProps.fontSize,\n inheritViewBox,\n viewBox,\n hasSvgAsChild\n });\n const more = {};\n if (!inheritViewBox) {\n more.viewBox = viewBox;\n }\n const classes = useUtilityClasses(ownerState);\n return /*#__PURE__*/_jsxs(SvgIconRoot, _extends({\n as: component,\n className: clsx(classes.root, className),\n focusable: \"false\",\n color: htmlColor,\n \"aria-hidden\": titleAccess ? undefined : true,\n role: titleAccess ? 'img' : undefined,\n ref: ref\n }, more, other, hasSvgAsChild && children.props, {\n ownerState: ownerState,\n children: [hasSvgAsChild ? children.props.children : children, titleAccess ? /*#__PURE__*/_jsx(\"title\", {\n children: titleAccess\n }) : null]\n }));\n});\nprocess.env.NODE_ENV !== \"production\" ? SvgIcon.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the d.ts file and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * Node passed into the SVG element.\n */\n children: PropTypes.node,\n /**\n * Override or extend the styles applied to the component.\n */\n classes: PropTypes.object,\n /**\n * @ignore\n */\n className: PropTypes.string,\n /**\n * The color of the component.\n * It supports both default and custom theme colors, which can be added as shown in the\n * [palette customization guide](https://mui.com/material-ui/customization/palette/#custom-colors).\n * You can use the `htmlColor` prop to apply a color attribute to the SVG element.\n * @default 'inherit'\n */\n color: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.oneOf(['inherit', 'action', 'disabled', 'primary', 'secondary', 'error', 'info', 'success', 'warning']), PropTypes.string]),\n /**\n * The component used for the root node.\n * Either a string to use a HTML element or a component.\n */\n component: PropTypes.elementType,\n /**\n * The fontSize applied to the icon. Defaults to 24px, but can be configure to inherit font size.\n * @default 'medium'\n */\n fontSize: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.oneOf(['inherit', 'large', 'medium', 'small']), PropTypes.string]),\n /**\n * Applies a color attribute to the SVG element.\n */\n htmlColor: PropTypes.string,\n /**\n * If `true`, the root node will inherit the custom `component`'s viewBox and the `viewBox`\n * prop will be ignored.\n * Useful when you want to reference a custom `component` and have `SvgIcon` pass that\n * `component`'s viewBox to the root node.\n * @default false\n */\n inheritViewBox: PropTypes.bool,\n /**\n * The shape-rendering attribute. The behavior of the different options is described on the\n * [MDN Web Docs](https://developer.mozilla.org/en-US/docs/Web/SVG/Attribute/shape-rendering).\n * If you are having issues with blurry icons you should investigate this prop.\n */\n shapeRendering: PropTypes.string,\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Provides a human-readable title for the element that contains it.\n * https://www.w3.org/TR/SVG-access/#Equivalent\n */\n titleAccess: PropTypes.string,\n /**\n * Allows you to redefine what the coordinates without units mean inside an SVG element.\n * For example, if the SVG element is 500 (width) by 200 (height),\n * and you pass viewBox=\"0 0 50 20\",\n * this means that the coordinates inside the SVG will go from the top left corner (0,0)\n * to bottom right (50,20) and each unit will be worth 10px.\n * @default '0 0 24 24'\n */\n viewBox: PropTypes.string\n} : void 0;\nSvgIcon.muiName = 'SvgIcon';\nexport default SvgIcon;","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport * as React from 'react';\nimport SvgIcon from '../SvgIcon';\n\n/**\n * Private module reserved for @mui packages.\n */\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nexport default function createSvgIcon(path, displayName) {\n function Component(props, ref) {\n return /*#__PURE__*/_jsx(SvgIcon, _extends({\n \"data-testid\": `${displayName}Icon`,\n ref: ref\n }, props, {\n children: path\n }));\n }\n if (process.env.NODE_ENV !== 'production') {\n // Need to set `displayName` on the inner component for React.memo.\n // React prior to 16.14 ignores `displayName` on the wrapper.\n Component.displayName = `${displayName}Icon`;\n }\n Component.muiName = SvgIcon.muiName;\n return /*#__PURE__*/React.memo( /*#__PURE__*/React.forwardRef(Component));\n}","'use client';\n\nimport { unstable_ClassNameGenerator as ClassNameGenerator } from '@mui/base/ClassNameGenerator';\nexport { default as capitalize } from './capitalize';\nexport { default as createChainedFunction } from './createChainedFunction';\nexport { default as createSvgIcon } from './createSvgIcon';\nexport { default as debounce } from './debounce';\nexport { default as deprecatedPropType } from './deprecatedPropType';\nexport { default as isMuiElement } from './isMuiElement';\nexport { default as ownerDocument } from './ownerDocument';\nexport { default as ownerWindow } from './ownerWindow';\nexport { default as requirePropFactory } from './requirePropFactory';\nexport { default as setRef } from './setRef';\nexport { default as unstable_useEnhancedEffect } from './useEnhancedEffect';\nexport { default as unstable_useId } from './useId';\nexport { default as unsupportedProp } from './unsupportedProp';\nexport { default as useControlled } from './useControlled';\nexport { default as useEventCallback } from './useEventCallback';\nexport { default as useForkRef } from './useForkRef';\nexport { default as useIsFocusVisible } from './useIsFocusVisible';\n// TODO: remove this export once ClassNameGenerator is stable\n// eslint-disable-next-line @typescript-eslint/naming-convention\nexport const unstable_ClassNameGenerator = {\n configure: generator => {\n if (process.env.NODE_ENV !== 'production') {\n console.warn(['MUI: `ClassNameGenerator` import from `@mui/material/utils` is outdated and might cause unexpected issues.', '', \"You should use `import { unstable_ClassNameGenerator } from '@mui/material/className'` instead\", '', 'The detail of the issue: https://github.com/mui/material-ui/issues/30011#issuecomment-1024993401', '', 'The updated documentation: https://mui.com/guides/classname-generator/'].join('\\n'));\n }\n ClassNameGenerator.configure(generator);\n }\n};","\"use strict\";\n'use client';\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nObject.defineProperty(exports, \"default\", {\n enumerable: true,\n get: function () {\n return _utils.createSvgIcon;\n }\n});\nvar _utils = require(\"@mui/material/utils\");","\"use strict\";\n\"use client\";\n\nvar _interopRequireDefault = require(\"@babel/runtime/helpers/interopRequireDefault\");\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = void 0;\nvar _createSvgIcon = _interopRequireDefault(require(\"./utils/createSvgIcon\"));\nvar _jsxRuntime = require(\"react/jsx-runtime\");\nvar _default = exports.default = (0, _createSvgIcon.default)( /*#__PURE__*/(0, _jsxRuntime.jsx)(\"path\", {\n d: \"m10 17 5-5-5-5z\"\n}), 'ArrowRight');","/**\n * Determines if a given element is a DOM element name (i.e. not a React component).\n */\nexport function isHostComponent(element) {\n return typeof element === 'string';\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport { isHostComponent } from './isHostComponent';\n\n/**\n * Type of the ownerState based on the type of an element it applies to.\n * This resolves to the provided OwnerState for React components and `undefined` for host components.\n * Falls back to `OwnerState | undefined` when the exact type can't be determined in development time.\n */\n\n/**\n * Appends the ownerState object to the props, merging with the existing one if necessary.\n *\n * @param elementType Type of the element that owns the `existingProps`. If the element is a DOM node or undefined, `ownerState` is not applied.\n * @param otherProps Props of the element.\n * @param ownerState\n */\nexport function appendOwnerState(elementType, otherProps, ownerState) {\n if (elementType === undefined || isHostComponent(elementType)) {\n return otherProps;\n }\n return _extends({}, otherProps, {\n ownerState: _extends({}, otherProps.ownerState, ownerState)\n });\n}","'use client';\n\nimport * as React from 'react';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nconst defaultContextValue = {\n disableDefaultClasses: false\n};\nconst ClassNameConfiguratorContext = /*#__PURE__*/React.createContext(defaultContextValue);\n/**\n * @ignore - internal hook.\n *\n * Wraps the `generateUtilityClass` function and controls how the classes are generated.\n * Currently it only affects whether the classes are applied or not.\n *\n * @returns Function to be called with the `generateUtilityClass` function specific to a component to generate the classes.\n */\nexport function useClassNamesOverride(generateUtilityClass) {\n const {\n disableDefaultClasses\n } = React.useContext(ClassNameConfiguratorContext);\n return slot => {\n if (disableDefaultClasses) {\n return '';\n }\n return generateUtilityClass(slot);\n };\n}\n\n/**\n * Allows to configure the components within to not apply any built-in classes.\n */\nexport function ClassNameConfigurator(props) {\n const {\n disableDefaultClasses,\n children\n } = props;\n const contextValue = React.useMemo(() => ({\n disableDefaultClasses: disableDefaultClasses != null ? disableDefaultClasses : false\n }), [disableDefaultClasses]);\n return /*#__PURE__*/_jsx(ClassNameConfiguratorContext.Provider, {\n value: contextValue,\n children: children\n });\n}","/**\n * Extracts event handlers from a given object.\n * A prop is considered an event handler if it is a function and its name starts with `on`.\n *\n * @param object An object to extract event handlers from.\n * @param excludeKeys An array of keys to exclude from the returned object.\n */\nexport function extractEventHandlers(object, excludeKeys = []) {\n if (object === undefined) {\n return {};\n }\n const result = {};\n Object.keys(object).filter(prop => prop.match(/^on[A-Z]/) && typeof object[prop] === 'function' && !excludeKeys.includes(prop)).forEach(prop => {\n result[prop] = object[prop];\n });\n return result;\n}","/**\n * If `componentProps` is a function, calls it with the provided `ownerState`.\n * Otherwise, just returns `componentProps`.\n */\nexport function resolveComponentProps(componentProps, ownerState, slotState) {\n if (typeof componentProps === 'function') {\n return componentProps(ownerState, slotState);\n }\n return componentProps;\n}","/**\n * Removes event handlers from the given object.\n * A field is considered an event handler if it is a function with a name beginning with `on`.\n *\n * @param object Object to remove event handlers from.\n * @returns Object with event handlers removed.\n */\nexport function omitEventHandlers(object) {\n if (object === undefined) {\n return {};\n }\n const result = {};\n Object.keys(object).filter(prop => !(prop.match(/^on[A-Z]/) && typeof object[prop] === 'function')).forEach(prop => {\n result[prop] = object[prop];\n });\n return result;\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport clsx from 'clsx';\nimport { extractEventHandlers } from './extractEventHandlers';\nimport { omitEventHandlers } from './omitEventHandlers';\n/**\n * Merges the slot component internal props (usually coming from a hook)\n * with the externally provided ones.\n *\n * The merge order is (the latter overrides the former):\n * 1. The internal props (specified as a getter function to work with get*Props hook result)\n * 2. Additional props (specified internally on a Base UI component)\n * 3. External props specified on the owner component. These should only be used on a root slot.\n * 4. External props specified in the `slotProps.*` prop.\n * 5. The `className` prop - combined from all the above.\n * @param parameters\n * @returns\n */\nexport function mergeSlotProps(parameters) {\n const {\n getSlotProps,\n additionalProps,\n externalSlotProps,\n externalForwardedProps,\n className\n } = parameters;\n if (!getSlotProps) {\n // The simpler case - getSlotProps is not defined, so no internal event handlers are defined,\n // so we can simply merge all the props without having to worry about extracting event handlers.\n const joinedClasses = clsx(additionalProps == null ? void 0 : additionalProps.className, className, externalForwardedProps == null ? void 0 : externalForwardedProps.className, externalSlotProps == null ? void 0 : externalSlotProps.className);\n const mergedStyle = _extends({}, additionalProps == null ? void 0 : additionalProps.style, externalForwardedProps == null ? void 0 : externalForwardedProps.style, externalSlotProps == null ? void 0 : externalSlotProps.style);\n const props = _extends({}, additionalProps, externalForwardedProps, externalSlotProps);\n if (joinedClasses.length > 0) {\n props.className = joinedClasses;\n }\n if (Object.keys(mergedStyle).length > 0) {\n props.style = mergedStyle;\n }\n return {\n props,\n internalRef: undefined\n };\n }\n\n // In this case, getSlotProps is responsible for calling the external event handlers.\n // We don't need to include them in the merged props because of this.\n\n const eventHandlers = extractEventHandlers(_extends({}, externalForwardedProps, externalSlotProps));\n const componentsPropsWithoutEventHandlers = omitEventHandlers(externalSlotProps);\n const otherPropsWithoutEventHandlers = omitEventHandlers(externalForwardedProps);\n const internalSlotProps = getSlotProps(eventHandlers);\n\n // The order of classes is important here.\n // Emotion (that we use in libraries consuming Base UI) depends on this order\n // to properly override style. It requires the most important classes to be last\n // (see https://github.com/mui/material-ui/pull/33205) for the related discussion.\n const joinedClasses = clsx(internalSlotProps == null ? void 0 : internalSlotProps.className, additionalProps == null ? void 0 : additionalProps.className, className, externalForwardedProps == null ? void 0 : externalForwardedProps.className, externalSlotProps == null ? void 0 : externalSlotProps.className);\n const mergedStyle = _extends({}, internalSlotProps == null ? void 0 : internalSlotProps.style, additionalProps == null ? void 0 : additionalProps.style, externalForwardedProps == null ? void 0 : externalForwardedProps.style, externalSlotProps == null ? void 0 : externalSlotProps.style);\n const props = _extends({}, internalSlotProps, additionalProps, otherPropsWithoutEventHandlers, componentsPropsWithoutEventHandlers);\n if (joinedClasses.length > 0) {\n props.className = joinedClasses;\n }\n if (Object.keys(mergedStyle).length > 0) {\n props.style = mergedStyle;\n }\n return {\n props,\n internalRef: internalSlotProps.ref\n };\n}","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"elementType\", \"externalSlotProps\", \"ownerState\", \"skipResolvingSlotProps\"];\nimport { unstable_useForkRef as useForkRef } from '@mui/utils';\nimport { appendOwnerState } from './appendOwnerState';\nimport { mergeSlotProps } from './mergeSlotProps';\nimport { resolveComponentProps } from './resolveComponentProps';\n/**\n * @ignore - do not document.\n * Builds the props to be passed into the slot of an unstyled component.\n * It merges the internal props of the component with the ones supplied by the user, allowing to customize the behavior.\n * If the slot component is not a host component, it also merges in the `ownerState`.\n *\n * @param parameters.getSlotProps - A function that returns the props to be passed to the slot component.\n */\nexport function useSlotProps(parameters) {\n var _parameters$additiona;\n const {\n elementType,\n externalSlotProps,\n ownerState,\n skipResolvingSlotProps = false\n } = parameters,\n rest = _objectWithoutPropertiesLoose(parameters, _excluded);\n const resolvedComponentsProps = skipResolvingSlotProps ? {} : resolveComponentProps(externalSlotProps, ownerState);\n const {\n props: mergedProps,\n internalRef\n } = mergeSlotProps(_extends({}, rest, {\n externalSlotProps: resolvedComponentsProps\n }));\n const ref = useForkRef(internalRef, resolvedComponentsProps == null ? void 0 : resolvedComponentsProps.ref, (_parameters$additiona = parameters.additionalProps) == null ? void 0 : _parameters$additiona.ref);\n const props = appendOwnerState(elementType, _extends({}, mergedProps, {\n ref\n }), ownerState);\n return props;\n}","import { globalStateClasses } from '@mui/utils/generateUtilityClass';\nconst GLOBAL_CLASS_PREFIX = 'base';\nfunction buildStateClass(state) {\n return `${GLOBAL_CLASS_PREFIX}--${state}`;\n}\nfunction buildSlotClass(componentName, slot) {\n return `${GLOBAL_CLASS_PREFIX}-${componentName}-${slot}`;\n}\nexport function generateUtilityClass(componentName, slot) {\n const globalStateClass = globalStateClasses[slot];\n return globalStateClass ? buildStateClass(globalStateClass) : buildSlotClass(componentName, slot);\n}\nexport function isGlobalState(slot) {\n return globalStateClasses[slot] !== undefined;\n}","import { generateUtilityClass } from '../generateUtilityClass';\nexport function generateUtilityClasses(componentName, slots) {\n const result = {};\n slots.forEach(slot => {\n result[slot] = generateUtilityClass(componentName, slot);\n });\n return result;\n}","'use client';\n\nimport * as React from 'react';\nimport * as ReactDOM from 'react-dom';\nimport PropTypes from 'prop-types';\nimport { exactProp, HTMLElementType, unstable_useEnhancedEffect as useEnhancedEffect, unstable_useForkRef as useForkRef, unstable_setRef as setRef } from '@mui/utils';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nfunction getContainer(container) {\n return typeof container === 'function' ? container() : container;\n}\n\n/**\n * Portals provide a first-class way to render children into a DOM node\n * that exists outside the DOM hierarchy of the parent component.\n *\n * Demos:\n *\n * - [Portal](https://mui.com/base-ui/react-portal/)\n *\n * API:\n *\n * - [Portal API](https://mui.com/base-ui/react-portal/components-api/#portal)\n */\nconst Portal = /*#__PURE__*/React.forwardRef(function Portal(props, forwardedRef) {\n const {\n children,\n container,\n disablePortal = false\n } = props;\n const [mountNode, setMountNode] = React.useState(null);\n // @ts-expect-error TODO upstream fix\n const handleRef = useForkRef( /*#__PURE__*/React.isValidElement(children) ? children.ref : null, forwardedRef);\n useEnhancedEffect(() => {\n if (!disablePortal) {\n setMountNode(getContainer(container) || document.body);\n }\n }, [container, disablePortal]);\n useEnhancedEffect(() => {\n if (mountNode && !disablePortal) {\n setRef(forwardedRef, mountNode);\n return () => {\n setRef(forwardedRef, null);\n };\n }\n return undefined;\n }, [forwardedRef, mountNode, disablePortal]);\n if (disablePortal) {\n if ( /*#__PURE__*/React.isValidElement(children)) {\n const newProps = {\n ref: handleRef\n };\n return /*#__PURE__*/React.cloneElement(children, newProps);\n }\n return /*#__PURE__*/_jsx(React.Fragment, {\n children: children\n });\n }\n return /*#__PURE__*/_jsx(React.Fragment, {\n children: mountNode ? /*#__PURE__*/ReactDOM.createPortal(children, mountNode) : mountNode\n });\n});\nprocess.env.NODE_ENV !== \"production\" ? Portal.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * The children to render into the `container`.\n */\n children: PropTypes.node,\n /**\n * An HTML element or function that returns one.\n * The `container` will have the portal children appended to it.\n *\n * You can also provide a callback, which is called in a React layout effect.\n * This lets you set the container from a ref, and also makes server-side rendering possible.\n *\n * By default, it uses the body of the top-level document object,\n * so it's simply `document.body` most of the time.\n */\n container: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.func]),\n /**\n * The `children` will be under the DOM hierarchy of the parent component.\n * @default false\n */\n disablePortal: PropTypes.bool\n} : void 0;\nif (process.env.NODE_ENV !== 'production') {\n // eslint-disable-next-line\n Portal['propTypes' + ''] = exactProp(Portal.propTypes);\n}\nexport { Portal };","export var top = 'top';\nexport var bottom = 'bottom';\nexport var right = 'right';\nexport var left = 'left';\nexport var auto = 'auto';\nexport var basePlacements = [top, bottom, right, left];\nexport var start = 'start';\nexport var end = 'end';\nexport var clippingParents = 'clippingParents';\nexport var viewport = 'viewport';\nexport var popper = 'popper';\nexport var reference = 'reference';\nexport var variationPlacements = /*#__PURE__*/basePlacements.reduce(function (acc, placement) {\n return acc.concat([placement + \"-\" + start, placement + \"-\" + end]);\n}, []);\nexport var placements = /*#__PURE__*/[].concat(basePlacements, [auto]).reduce(function (acc, placement) {\n return acc.concat([placement, placement + \"-\" + start, placement + \"-\" + end]);\n}, []); // modifiers that need to read the DOM\n\nexport var beforeRead = 'beforeRead';\nexport var read = 'read';\nexport var afterRead = 'afterRead'; // pure-logic modifiers\n\nexport var beforeMain = 'beforeMain';\nexport var main = 'main';\nexport var afterMain = 'afterMain'; // modifier with the purpose to write to the DOM (or write into a framework state)\n\nexport var beforeWrite = 'beforeWrite';\nexport var write = 'write';\nexport var afterWrite = 'afterWrite';\nexport var modifierPhases = [beforeRead, read, afterRead, beforeMain, main, afterMain, beforeWrite, write, afterWrite];","export default function getNodeName(element) {\n return element ? (element.nodeName || '').toLowerCase() : null;\n}","export default function getWindow(node) {\n if (node == null) {\n return window;\n }\n\n if (node.toString() !== '[object Window]') {\n var ownerDocument = node.ownerDocument;\n return ownerDocument ? ownerDocument.defaultView || window : window;\n }\n\n return node;\n}","import getWindow from \"./getWindow.js\";\n\nfunction isElement(node) {\n var OwnElement = getWindow(node).Element;\n return node instanceof OwnElement || node instanceof Element;\n}\n\nfunction isHTMLElement(node) {\n var OwnElement = getWindow(node).HTMLElement;\n return node instanceof OwnElement || node instanceof HTMLElement;\n}\n\nfunction isShadowRoot(node) {\n // IE 11 has no ShadowRoot\n if (typeof ShadowRoot === 'undefined') {\n return false;\n }\n\n var OwnElement = getWindow(node).ShadowRoot;\n return node instanceof OwnElement || node instanceof ShadowRoot;\n}\n\nexport { isElement, isHTMLElement, isShadowRoot };","import getNodeName from \"../dom-utils/getNodeName.js\";\nimport { isHTMLElement } from \"../dom-utils/instanceOf.js\"; // This modifier takes the styles prepared by the `computeStyles` modifier\n// and applies them to the HTMLElements such as popper and arrow\n\nfunction applyStyles(_ref) {\n var state = _ref.state;\n Object.keys(state.elements).forEach(function (name) {\n var style = state.styles[name] || {};\n var attributes = state.attributes[name] || {};\n var element = state.elements[name]; // arrow is optional + virtual elements\n\n if (!isHTMLElement(element) || !getNodeName(element)) {\n return;\n } // Flow doesn't support to extend this property, but it's the most\n // effective way to apply styles to an HTMLElement\n // $FlowFixMe[cannot-write]\n\n\n Object.assign(element.style, style);\n Object.keys(attributes).forEach(function (name) {\n var value = attributes[name];\n\n if (value === false) {\n element.removeAttribute(name);\n } else {\n element.setAttribute(name, value === true ? '' : value);\n }\n });\n });\n}\n\nfunction effect(_ref2) {\n var state = _ref2.state;\n var initialStyles = {\n popper: {\n position: state.options.strategy,\n left: '0',\n top: '0',\n margin: '0'\n },\n arrow: {\n position: 'absolute'\n },\n reference: {}\n };\n Object.assign(state.elements.popper.style, initialStyles.popper);\n state.styles = initialStyles;\n\n if (state.elements.arrow) {\n Object.assign(state.elements.arrow.style, initialStyles.arrow);\n }\n\n return function () {\n Object.keys(state.elements).forEach(function (name) {\n var element = state.elements[name];\n var attributes = state.attributes[name] || {};\n var styleProperties = Object.keys(state.styles.hasOwnProperty(name) ? state.styles[name] : initialStyles[name]); // Set all values to an empty string to unset them\n\n var style = styleProperties.reduce(function (style, property) {\n style[property] = '';\n return style;\n }, {}); // arrow is optional + virtual elements\n\n if (!isHTMLElement(element) || !getNodeName(element)) {\n return;\n }\n\n Object.assign(element.style, style);\n Object.keys(attributes).forEach(function (attribute) {\n element.removeAttribute(attribute);\n });\n });\n };\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'applyStyles',\n enabled: true,\n phase: 'write',\n fn: applyStyles,\n effect: effect,\n requires: ['computeStyles']\n};","import { auto } from \"../enums.js\";\nexport default function getBasePlacement(placement) {\n return placement.split('-')[0];\n}","export var max = Math.max;\nexport var min = Math.min;\nexport var round = Math.round;","export default function getUAString() {\n var uaData = navigator.userAgentData;\n\n if (uaData != null && uaData.brands && Array.isArray(uaData.brands)) {\n return uaData.brands.map(function (item) {\n return item.brand + \"/\" + item.version;\n }).join(' ');\n }\n\n return navigator.userAgent;\n}","import getUAString from \"../utils/userAgent.js\";\nexport default function isLayoutViewport() {\n return !/^((?!chrome|android).)*safari/i.test(getUAString());\n}","import { isElement, isHTMLElement } from \"./instanceOf.js\";\nimport { round } from \"../utils/math.js\";\nimport getWindow from \"./getWindow.js\";\nimport isLayoutViewport from \"./isLayoutViewport.js\";\nexport default function getBoundingClientRect(element, includeScale, isFixedStrategy) {\n if (includeScale === void 0) {\n includeScale = false;\n }\n\n if (isFixedStrategy === void 0) {\n isFixedStrategy = false;\n }\n\n var clientRect = element.getBoundingClientRect();\n var scaleX = 1;\n var scaleY = 1;\n\n if (includeScale && isHTMLElement(element)) {\n scaleX = element.offsetWidth > 0 ? round(clientRect.width) / element.offsetWidth || 1 : 1;\n scaleY = element.offsetHeight > 0 ? round(clientRect.height) / element.offsetHeight || 1 : 1;\n }\n\n var _ref = isElement(element) ? getWindow(element) : window,\n visualViewport = _ref.visualViewport;\n\n var addVisualOffsets = !isLayoutViewport() && isFixedStrategy;\n var x = (clientRect.left + (addVisualOffsets && visualViewport ? visualViewport.offsetLeft : 0)) / scaleX;\n var y = (clientRect.top + (addVisualOffsets && visualViewport ? visualViewport.offsetTop : 0)) / scaleY;\n var width = clientRect.width / scaleX;\n var height = clientRect.height / scaleY;\n return {\n width: width,\n height: height,\n top: y,\n right: x + width,\n bottom: y + height,\n left: x,\n x: x,\n y: y\n };\n}","import getBoundingClientRect from \"./getBoundingClientRect.js\"; // Returns the layout rect of an element relative to its offsetParent. Layout\n// means it doesn't take into account transforms.\n\nexport default function getLayoutRect(element) {\n var clientRect = getBoundingClientRect(element); // Use the clientRect sizes if it's not been transformed.\n // Fixes https://github.com/popperjs/popper-core/issues/1223\n\n var width = element.offsetWidth;\n var height = element.offsetHeight;\n\n if (Math.abs(clientRect.width - width) <= 1) {\n width = clientRect.width;\n }\n\n if (Math.abs(clientRect.height - height) <= 1) {\n height = clientRect.height;\n }\n\n return {\n x: element.offsetLeft,\n y: element.offsetTop,\n width: width,\n height: height\n };\n}","import { isShadowRoot } from \"./instanceOf.js\";\nexport default function contains(parent, child) {\n var rootNode = child.getRootNode && child.getRootNode(); // First, attempt with faster native method\n\n if (parent.contains(child)) {\n return true;\n } // then fallback to custom implementation with Shadow DOM support\n else if (rootNode && isShadowRoot(rootNode)) {\n var next = child;\n\n do {\n if (next && parent.isSameNode(next)) {\n return true;\n } // $FlowFixMe[prop-missing]: need a better way to handle this...\n\n\n next = next.parentNode || next.host;\n } while (next);\n } // Give up, the result is false\n\n\n return false;\n}","import getWindow from \"./getWindow.js\";\nexport default function getComputedStyle(element) {\n return getWindow(element).getComputedStyle(element);\n}","import getNodeName from \"./getNodeName.js\";\nexport default function isTableElement(element) {\n return ['table', 'td', 'th'].indexOf(getNodeName(element)) >= 0;\n}","import { isElement } from \"./instanceOf.js\";\nexport default function getDocumentElement(element) {\n // $FlowFixMe[incompatible-return]: assume body is always available\n return ((isElement(element) ? element.ownerDocument : // $FlowFixMe[prop-missing]\n element.document) || window.document).documentElement;\n}","import getNodeName from \"./getNodeName.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport { isShadowRoot } from \"./instanceOf.js\";\nexport default function getParentNode(element) {\n if (getNodeName(element) === 'html') {\n return element;\n }\n\n return (// this is a quicker (but less type safe) way to save quite some bytes from the bundle\n // $FlowFixMe[incompatible-return]\n // $FlowFixMe[prop-missing]\n element.assignedSlot || // step into the shadow DOM of the parent of a slotted node\n element.parentNode || ( // DOM Element detected\n isShadowRoot(element) ? element.host : null) || // ShadowRoot detected\n // $FlowFixMe[incompatible-call]: HTMLElement is a Node\n getDocumentElement(element) // fallback\n\n );\n}","import getWindow from \"./getWindow.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport getComputedStyle from \"./getComputedStyle.js\";\nimport { isHTMLElement, isShadowRoot } from \"./instanceOf.js\";\nimport isTableElement from \"./isTableElement.js\";\nimport getParentNode from \"./getParentNode.js\";\nimport getUAString from \"../utils/userAgent.js\";\n\nfunction getTrueOffsetParent(element) {\n if (!isHTMLElement(element) || // https://github.com/popperjs/popper-core/issues/837\n getComputedStyle(element).position === 'fixed') {\n return null;\n }\n\n return element.offsetParent;\n} // `.offsetParent` reports `null` for fixed elements, while absolute elements\n// return the containing block\n\n\nfunction getContainingBlock(element) {\n var isFirefox = /firefox/i.test(getUAString());\n var isIE = /Trident/i.test(getUAString());\n\n if (isIE && isHTMLElement(element)) {\n // In IE 9, 10 and 11 fixed elements containing block is always established by the viewport\n var elementCss = getComputedStyle(element);\n\n if (elementCss.position === 'fixed') {\n return null;\n }\n }\n\n var currentNode = getParentNode(element);\n\n if (isShadowRoot(currentNode)) {\n currentNode = currentNode.host;\n }\n\n while (isHTMLElement(currentNode) && ['html', 'body'].indexOf(getNodeName(currentNode)) < 0) {\n var css = getComputedStyle(currentNode); // This is non-exhaustive but covers the most common CSS properties that\n // create a containing block.\n // https://developer.mozilla.org/en-US/docs/Web/CSS/Containing_block#identifying_the_containing_block\n\n if (css.transform !== 'none' || css.perspective !== 'none' || css.contain === 'paint' || ['transform', 'perspective'].indexOf(css.willChange) !== -1 || isFirefox && css.willChange === 'filter' || isFirefox && css.filter && css.filter !== 'none') {\n return currentNode;\n } else {\n currentNode = currentNode.parentNode;\n }\n }\n\n return null;\n} // Gets the closest ancestor positioned element. Handles some edge cases,\n// such as table ancestors and cross browser bugs.\n\n\nexport default function getOffsetParent(element) {\n var window = getWindow(element);\n var offsetParent = getTrueOffsetParent(element);\n\n while (offsetParent && isTableElement(offsetParent) && getComputedStyle(offsetParent).position === 'static') {\n offsetParent = getTrueOffsetParent(offsetParent);\n }\n\n if (offsetParent && (getNodeName(offsetParent) === 'html' || getNodeName(offsetParent) === 'body' && getComputedStyle(offsetParent).position === 'static')) {\n return window;\n }\n\n return offsetParent || getContainingBlock(element) || window;\n}","export default function getMainAxisFromPlacement(placement) {\n return ['top', 'bottom'].indexOf(placement) >= 0 ? 'x' : 'y';\n}","import { max as mathMax, min as mathMin } from \"./math.js\";\nexport function within(min, value, max) {\n return mathMax(min, mathMin(value, max));\n}\nexport function withinMaxClamp(min, value, max) {\n var v = within(min, value, max);\n return v > max ? max : v;\n}","export default function getFreshSideObject() {\n return {\n top: 0,\n right: 0,\n bottom: 0,\n left: 0\n };\n}","import getFreshSideObject from \"./getFreshSideObject.js\";\nexport default function mergePaddingObject(paddingObject) {\n return Object.assign({}, getFreshSideObject(), paddingObject);\n}","export default function expandToHashMap(value, keys) {\n return keys.reduce(function (hashMap, key) {\n hashMap[key] = value;\n return hashMap;\n }, {});\n}","import getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getLayoutRect from \"../dom-utils/getLayoutRect.js\";\nimport contains from \"../dom-utils/contains.js\";\nimport getOffsetParent from \"../dom-utils/getOffsetParent.js\";\nimport getMainAxisFromPlacement from \"../utils/getMainAxisFromPlacement.js\";\nimport { within } from \"../utils/within.js\";\nimport mergePaddingObject from \"../utils/mergePaddingObject.js\";\nimport expandToHashMap from \"../utils/expandToHashMap.js\";\nimport { left, right, basePlacements, top, bottom } from \"../enums.js\"; // eslint-disable-next-line import/no-unused-modules\n\nvar toPaddingObject = function toPaddingObject(padding, state) {\n padding = typeof padding === 'function' ? padding(Object.assign({}, state.rects, {\n placement: state.placement\n })) : padding;\n return mergePaddingObject(typeof padding !== 'number' ? padding : expandToHashMap(padding, basePlacements));\n};\n\nfunction arrow(_ref) {\n var _state$modifiersData$;\n\n var state = _ref.state,\n name = _ref.name,\n options = _ref.options;\n var arrowElement = state.elements.arrow;\n var popperOffsets = state.modifiersData.popperOffsets;\n var basePlacement = getBasePlacement(state.placement);\n var axis = getMainAxisFromPlacement(basePlacement);\n var isVertical = [left, right].indexOf(basePlacement) >= 0;\n var len = isVertical ? 'height' : 'width';\n\n if (!arrowElement || !popperOffsets) {\n return;\n }\n\n var paddingObject = toPaddingObject(options.padding, state);\n var arrowRect = getLayoutRect(arrowElement);\n var minProp = axis === 'y' ? top : left;\n var maxProp = axis === 'y' ? bottom : right;\n var endDiff = state.rects.reference[len] + state.rects.reference[axis] - popperOffsets[axis] - state.rects.popper[len];\n var startDiff = popperOffsets[axis] - state.rects.reference[axis];\n var arrowOffsetParent = getOffsetParent(arrowElement);\n var clientSize = arrowOffsetParent ? axis === 'y' ? arrowOffsetParent.clientHeight || 0 : arrowOffsetParent.clientWidth || 0 : 0;\n var centerToReference = endDiff / 2 - startDiff / 2; // Make sure the arrow doesn't overflow the popper if the center point is\n // outside of the popper bounds\n\n var min = paddingObject[minProp];\n var max = clientSize - arrowRect[len] - paddingObject[maxProp];\n var center = clientSize / 2 - arrowRect[len] / 2 + centerToReference;\n var offset = within(min, center, max); // Prevents breaking syntax highlighting...\n\n var axisProp = axis;\n state.modifiersData[name] = (_state$modifiersData$ = {}, _state$modifiersData$[axisProp] = offset, _state$modifiersData$.centerOffset = offset - center, _state$modifiersData$);\n}\n\nfunction effect(_ref2) {\n var state = _ref2.state,\n options = _ref2.options;\n var _options$element = options.element,\n arrowElement = _options$element === void 0 ? '[data-popper-arrow]' : _options$element;\n\n if (arrowElement == null) {\n return;\n } // CSS selector\n\n\n if (typeof arrowElement === 'string') {\n arrowElement = state.elements.popper.querySelector(arrowElement);\n\n if (!arrowElement) {\n return;\n }\n }\n\n if (!contains(state.elements.popper, arrowElement)) {\n return;\n }\n\n state.elements.arrow = arrowElement;\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'arrow',\n enabled: true,\n phase: 'main',\n fn: arrow,\n effect: effect,\n requires: ['popperOffsets'],\n requiresIfExists: ['preventOverflow']\n};","export default function getVariation(placement) {\n return placement.split('-')[1];\n}","import { top, left, right, bottom, end } from \"../enums.js\";\nimport getOffsetParent from \"../dom-utils/getOffsetParent.js\";\nimport getWindow from \"../dom-utils/getWindow.js\";\nimport getDocumentElement from \"../dom-utils/getDocumentElement.js\";\nimport getComputedStyle from \"../dom-utils/getComputedStyle.js\";\nimport getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getVariation from \"../utils/getVariation.js\";\nimport { round } from \"../utils/math.js\"; // eslint-disable-next-line import/no-unused-modules\n\nvar unsetSides = {\n top: 'auto',\n right: 'auto',\n bottom: 'auto',\n left: 'auto'\n}; // Round the offsets to the nearest suitable subpixel based on the DPR.\n// Zooming can change the DPR, but it seems to report a value that will\n// cleanly divide the values into the appropriate subpixels.\n\nfunction roundOffsetsByDPR(_ref, win) {\n var x = _ref.x,\n y = _ref.y;\n var dpr = win.devicePixelRatio || 1;\n return {\n x: round(x * dpr) / dpr || 0,\n y: round(y * dpr) / dpr || 0\n };\n}\n\nexport function mapToStyles(_ref2) {\n var _Object$assign2;\n\n var popper = _ref2.popper,\n popperRect = _ref2.popperRect,\n placement = _ref2.placement,\n variation = _ref2.variation,\n offsets = _ref2.offsets,\n position = _ref2.position,\n gpuAcceleration = _ref2.gpuAcceleration,\n adaptive = _ref2.adaptive,\n roundOffsets = _ref2.roundOffsets,\n isFixed = _ref2.isFixed;\n var _offsets$x = offsets.x,\n x = _offsets$x === void 0 ? 0 : _offsets$x,\n _offsets$y = offsets.y,\n y = _offsets$y === void 0 ? 0 : _offsets$y;\n\n var _ref3 = typeof roundOffsets === 'function' ? roundOffsets({\n x: x,\n y: y\n }) : {\n x: x,\n y: y\n };\n\n x = _ref3.x;\n y = _ref3.y;\n var hasX = offsets.hasOwnProperty('x');\n var hasY = offsets.hasOwnProperty('y');\n var sideX = left;\n var sideY = top;\n var win = window;\n\n if (adaptive) {\n var offsetParent = getOffsetParent(popper);\n var heightProp = 'clientHeight';\n var widthProp = 'clientWidth';\n\n if (offsetParent === getWindow(popper)) {\n offsetParent = getDocumentElement(popper);\n\n if (getComputedStyle(offsetParent).position !== 'static' && position === 'absolute') {\n heightProp = 'scrollHeight';\n widthProp = 'scrollWidth';\n }\n } // $FlowFixMe[incompatible-cast]: force type refinement, we compare offsetParent with window above, but Flow doesn't detect it\n\n\n offsetParent = offsetParent;\n\n if (placement === top || (placement === left || placement === right) && variation === end) {\n sideY = bottom;\n var offsetY = isFixed && offsetParent === win && win.visualViewport ? win.visualViewport.height : // $FlowFixMe[prop-missing]\n offsetParent[heightProp];\n y -= offsetY - popperRect.height;\n y *= gpuAcceleration ? 1 : -1;\n }\n\n if (placement === left || (placement === top || placement === bottom) && variation === end) {\n sideX = right;\n var offsetX = isFixed && offsetParent === win && win.visualViewport ? win.visualViewport.width : // $FlowFixMe[prop-missing]\n offsetParent[widthProp];\n x -= offsetX - popperRect.width;\n x *= gpuAcceleration ? 1 : -1;\n }\n }\n\n var commonStyles = Object.assign({\n position: position\n }, adaptive && unsetSides);\n\n var _ref4 = roundOffsets === true ? roundOffsetsByDPR({\n x: x,\n y: y\n }, getWindow(popper)) : {\n x: x,\n y: y\n };\n\n x = _ref4.x;\n y = _ref4.y;\n\n if (gpuAcceleration) {\n var _Object$assign;\n\n return Object.assign({}, commonStyles, (_Object$assign = {}, _Object$assign[sideY] = hasY ? '0' : '', _Object$assign[sideX] = hasX ? '0' : '', _Object$assign.transform = (win.devicePixelRatio || 1) <= 1 ? \"translate(\" + x + \"px, \" + y + \"px)\" : \"translate3d(\" + x + \"px, \" + y + \"px, 0)\", _Object$assign));\n }\n\n return Object.assign({}, commonStyles, (_Object$assign2 = {}, _Object$assign2[sideY] = hasY ? y + \"px\" : '', _Object$assign2[sideX] = hasX ? x + \"px\" : '', _Object$assign2.transform = '', _Object$assign2));\n}\n\nfunction computeStyles(_ref5) {\n var state = _ref5.state,\n options = _ref5.options;\n var _options$gpuAccelerat = options.gpuAcceleration,\n gpuAcceleration = _options$gpuAccelerat === void 0 ? true : _options$gpuAccelerat,\n _options$adaptive = options.adaptive,\n adaptive = _options$adaptive === void 0 ? true : _options$adaptive,\n _options$roundOffsets = options.roundOffsets,\n roundOffsets = _options$roundOffsets === void 0 ? true : _options$roundOffsets;\n var commonStyles = {\n placement: getBasePlacement(state.placement),\n variation: getVariation(state.placement),\n popper: state.elements.popper,\n popperRect: state.rects.popper,\n gpuAcceleration: gpuAcceleration,\n isFixed: state.options.strategy === 'fixed'\n };\n\n if (state.modifiersData.popperOffsets != null) {\n state.styles.popper = Object.assign({}, state.styles.popper, mapToStyles(Object.assign({}, commonStyles, {\n offsets: state.modifiersData.popperOffsets,\n position: state.options.strategy,\n adaptive: adaptive,\n roundOffsets: roundOffsets\n })));\n }\n\n if (state.modifiersData.arrow != null) {\n state.styles.arrow = Object.assign({}, state.styles.arrow, mapToStyles(Object.assign({}, commonStyles, {\n offsets: state.modifiersData.arrow,\n position: 'absolute',\n adaptive: false,\n roundOffsets: roundOffsets\n })));\n }\n\n state.attributes.popper = Object.assign({}, state.attributes.popper, {\n 'data-popper-placement': state.placement\n });\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'computeStyles',\n enabled: true,\n phase: 'beforeWrite',\n fn: computeStyles,\n data: {}\n};","import getWindow from \"../dom-utils/getWindow.js\"; // eslint-disable-next-line import/no-unused-modules\n\nvar passive = {\n passive: true\n};\n\nfunction effect(_ref) {\n var state = _ref.state,\n instance = _ref.instance,\n options = _ref.options;\n var _options$scroll = options.scroll,\n scroll = _options$scroll === void 0 ? true : _options$scroll,\n _options$resize = options.resize,\n resize = _options$resize === void 0 ? true : _options$resize;\n var window = getWindow(state.elements.popper);\n var scrollParents = [].concat(state.scrollParents.reference, state.scrollParents.popper);\n\n if (scroll) {\n scrollParents.forEach(function (scrollParent) {\n scrollParent.addEventListener('scroll', instance.update, passive);\n });\n }\n\n if (resize) {\n window.addEventListener('resize', instance.update, passive);\n }\n\n return function () {\n if (scroll) {\n scrollParents.forEach(function (scrollParent) {\n scrollParent.removeEventListener('scroll', instance.update, passive);\n });\n }\n\n if (resize) {\n window.removeEventListener('resize', instance.update, passive);\n }\n };\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'eventListeners',\n enabled: true,\n phase: 'write',\n fn: function fn() {},\n effect: effect,\n data: {}\n};","var hash = {\n left: 'right',\n right: 'left',\n bottom: 'top',\n top: 'bottom'\n};\nexport default function getOppositePlacement(placement) {\n return placement.replace(/left|right|bottom|top/g, function (matched) {\n return hash[matched];\n });\n}","var hash = {\n start: 'end',\n end: 'start'\n};\nexport default function getOppositeVariationPlacement(placement) {\n return placement.replace(/start|end/g, function (matched) {\n return hash[matched];\n });\n}","import getWindow from \"./getWindow.js\";\nexport default function getWindowScroll(node) {\n var win = getWindow(node);\n var scrollLeft = win.pageXOffset;\n var scrollTop = win.pageYOffset;\n return {\n scrollLeft: scrollLeft,\n scrollTop: scrollTop\n };\n}","import getBoundingClientRect from \"./getBoundingClientRect.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport getWindowScroll from \"./getWindowScroll.js\";\nexport default function getWindowScrollBarX(element) {\n // If has a CSS width greater than the viewport, then this will be\n // incorrect for RTL.\n // Popper 1 is broken in this case and never had a bug report so let's assume\n // it's not an issue. I don't think anyone ever specifies width on \n // anyway.\n // Browsers where the left scrollbar doesn't cause an issue report `0` for\n // this (e.g. Edge 2019, IE11, Safari)\n return getBoundingClientRect(getDocumentElement(element)).left + getWindowScroll(element).scrollLeft;\n}","import getWindow from \"./getWindow.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport getWindowScrollBarX from \"./getWindowScrollBarX.js\";\nimport isLayoutViewport from \"./isLayoutViewport.js\";\nexport default function getViewportRect(element, strategy) {\n var win = getWindow(element);\n var html = getDocumentElement(element);\n var visualViewport = win.visualViewport;\n var width = html.clientWidth;\n var height = html.clientHeight;\n var x = 0;\n var y = 0;\n\n if (visualViewport) {\n width = visualViewport.width;\n height = visualViewport.height;\n var layoutViewport = isLayoutViewport();\n\n if (layoutViewport || !layoutViewport && strategy === 'fixed') {\n x = visualViewport.offsetLeft;\n y = visualViewport.offsetTop;\n }\n }\n\n return {\n width: width,\n height: height,\n x: x + getWindowScrollBarX(element),\n y: y\n };\n}","import getDocumentElement from \"./getDocumentElement.js\";\nimport getComputedStyle from \"./getComputedStyle.js\";\nimport getWindowScrollBarX from \"./getWindowScrollBarX.js\";\nimport getWindowScroll from \"./getWindowScroll.js\";\nimport { max } from \"../utils/math.js\"; // Gets the entire size of the scrollable document area, even extending outside\n// of the `` and `` rect bounds if horizontally scrollable\n\nexport default function getDocumentRect(element) {\n var _element$ownerDocumen;\n\n var html = getDocumentElement(element);\n var winScroll = getWindowScroll(element);\n var body = (_element$ownerDocumen = element.ownerDocument) == null ? void 0 : _element$ownerDocumen.body;\n var width = max(html.scrollWidth, html.clientWidth, body ? body.scrollWidth : 0, body ? body.clientWidth : 0);\n var height = max(html.scrollHeight, html.clientHeight, body ? body.scrollHeight : 0, body ? body.clientHeight : 0);\n var x = -winScroll.scrollLeft + getWindowScrollBarX(element);\n var y = -winScroll.scrollTop;\n\n if (getComputedStyle(body || html).direction === 'rtl') {\n x += max(html.clientWidth, body ? body.clientWidth : 0) - width;\n }\n\n return {\n width: width,\n height: height,\n x: x,\n y: y\n };\n}","import getComputedStyle from \"./getComputedStyle.js\";\nexport default function isScrollParent(element) {\n // Firefox wants us to check `-x` and `-y` variations as well\n var _getComputedStyle = getComputedStyle(element),\n overflow = _getComputedStyle.overflow,\n overflowX = _getComputedStyle.overflowX,\n overflowY = _getComputedStyle.overflowY;\n\n return /auto|scroll|overlay|hidden/.test(overflow + overflowY + overflowX);\n}","import getParentNode from \"./getParentNode.js\";\nimport isScrollParent from \"./isScrollParent.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport { isHTMLElement } from \"./instanceOf.js\";\nexport default function getScrollParent(node) {\n if (['html', 'body', '#document'].indexOf(getNodeName(node)) >= 0) {\n // $FlowFixMe[incompatible-return]: assume body is always available\n return node.ownerDocument.body;\n }\n\n if (isHTMLElement(node) && isScrollParent(node)) {\n return node;\n }\n\n return getScrollParent(getParentNode(node));\n}","import getScrollParent from \"./getScrollParent.js\";\nimport getParentNode from \"./getParentNode.js\";\nimport getWindow from \"./getWindow.js\";\nimport isScrollParent from \"./isScrollParent.js\";\n/*\ngiven a DOM element, return the list of all scroll parents, up the list of ancesors\nuntil we get to the top window object. This list is what we attach scroll listeners\nto, because if any of these parent elements scroll, we'll need to re-calculate the\nreference element's position.\n*/\n\nexport default function listScrollParents(element, list) {\n var _element$ownerDocumen;\n\n if (list === void 0) {\n list = [];\n }\n\n var scrollParent = getScrollParent(element);\n var isBody = scrollParent === ((_element$ownerDocumen = element.ownerDocument) == null ? void 0 : _element$ownerDocumen.body);\n var win = getWindow(scrollParent);\n var target = isBody ? [win].concat(win.visualViewport || [], isScrollParent(scrollParent) ? scrollParent : []) : scrollParent;\n var updatedList = list.concat(target);\n return isBody ? updatedList : // $FlowFixMe[incompatible-call]: isBody tells us target will be an HTMLElement here\n updatedList.concat(listScrollParents(getParentNode(target)));\n}","export default function rectToClientRect(rect) {\n return Object.assign({}, rect, {\n left: rect.x,\n top: rect.y,\n right: rect.x + rect.width,\n bottom: rect.y + rect.height\n });\n}","import { viewport } from \"../enums.js\";\nimport getViewportRect from \"./getViewportRect.js\";\nimport getDocumentRect from \"./getDocumentRect.js\";\nimport listScrollParents from \"./listScrollParents.js\";\nimport getOffsetParent from \"./getOffsetParent.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport getComputedStyle from \"./getComputedStyle.js\";\nimport { isElement, isHTMLElement } from \"./instanceOf.js\";\nimport getBoundingClientRect from \"./getBoundingClientRect.js\";\nimport getParentNode from \"./getParentNode.js\";\nimport contains from \"./contains.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport rectToClientRect from \"../utils/rectToClientRect.js\";\nimport { max, min } from \"../utils/math.js\";\n\nfunction getInnerBoundingClientRect(element, strategy) {\n var rect = getBoundingClientRect(element, false, strategy === 'fixed');\n rect.top = rect.top + element.clientTop;\n rect.left = rect.left + element.clientLeft;\n rect.bottom = rect.top + element.clientHeight;\n rect.right = rect.left + element.clientWidth;\n rect.width = element.clientWidth;\n rect.height = element.clientHeight;\n rect.x = rect.left;\n rect.y = rect.top;\n return rect;\n}\n\nfunction getClientRectFromMixedType(element, clippingParent, strategy) {\n return clippingParent === viewport ? rectToClientRect(getViewportRect(element, strategy)) : isElement(clippingParent) ? getInnerBoundingClientRect(clippingParent, strategy) : rectToClientRect(getDocumentRect(getDocumentElement(element)));\n} // A \"clipping parent\" is an overflowable container with the characteristic of\n// clipping (or hiding) overflowing elements with a position different from\n// `initial`\n\n\nfunction getClippingParents(element) {\n var clippingParents = listScrollParents(getParentNode(element));\n var canEscapeClipping = ['absolute', 'fixed'].indexOf(getComputedStyle(element).position) >= 0;\n var clipperElement = canEscapeClipping && isHTMLElement(element) ? getOffsetParent(element) : element;\n\n if (!isElement(clipperElement)) {\n return [];\n } // $FlowFixMe[incompatible-return]: https://github.com/facebook/flow/issues/1414\n\n\n return clippingParents.filter(function (clippingParent) {\n return isElement(clippingParent) && contains(clippingParent, clipperElement) && getNodeName(clippingParent) !== 'body';\n });\n} // Gets the maximum area that the element is visible in due to any number of\n// clipping parents\n\n\nexport default function getClippingRect(element, boundary, rootBoundary, strategy) {\n var mainClippingParents = boundary === 'clippingParents' ? getClippingParents(element) : [].concat(boundary);\n var clippingParents = [].concat(mainClippingParents, [rootBoundary]);\n var firstClippingParent = clippingParents[0];\n var clippingRect = clippingParents.reduce(function (accRect, clippingParent) {\n var rect = getClientRectFromMixedType(element, clippingParent, strategy);\n accRect.top = max(rect.top, accRect.top);\n accRect.right = min(rect.right, accRect.right);\n accRect.bottom = min(rect.bottom, accRect.bottom);\n accRect.left = max(rect.left, accRect.left);\n return accRect;\n }, getClientRectFromMixedType(element, firstClippingParent, strategy));\n clippingRect.width = clippingRect.right - clippingRect.left;\n clippingRect.height = clippingRect.bottom - clippingRect.top;\n clippingRect.x = clippingRect.left;\n clippingRect.y = clippingRect.top;\n return clippingRect;\n}","import getBasePlacement from \"./getBasePlacement.js\";\nimport getVariation from \"./getVariation.js\";\nimport getMainAxisFromPlacement from \"./getMainAxisFromPlacement.js\";\nimport { top, right, bottom, left, start, end } from \"../enums.js\";\nexport default function computeOffsets(_ref) {\n var reference = _ref.reference,\n element = _ref.element,\n placement = _ref.placement;\n var basePlacement = placement ? getBasePlacement(placement) : null;\n var variation = placement ? getVariation(placement) : null;\n var commonX = reference.x + reference.width / 2 - element.width / 2;\n var commonY = reference.y + reference.height / 2 - element.height / 2;\n var offsets;\n\n switch (basePlacement) {\n case top:\n offsets = {\n x: commonX,\n y: reference.y - element.height\n };\n break;\n\n case bottom:\n offsets = {\n x: commonX,\n y: reference.y + reference.height\n };\n break;\n\n case right:\n offsets = {\n x: reference.x + reference.width,\n y: commonY\n };\n break;\n\n case left:\n offsets = {\n x: reference.x - element.width,\n y: commonY\n };\n break;\n\n default:\n offsets = {\n x: reference.x,\n y: reference.y\n };\n }\n\n var mainAxis = basePlacement ? getMainAxisFromPlacement(basePlacement) : null;\n\n if (mainAxis != null) {\n var len = mainAxis === 'y' ? 'height' : 'width';\n\n switch (variation) {\n case start:\n offsets[mainAxis] = offsets[mainAxis] - (reference[len] / 2 - element[len] / 2);\n break;\n\n case end:\n offsets[mainAxis] = offsets[mainAxis] + (reference[len] / 2 - element[len] / 2);\n break;\n\n default:\n }\n }\n\n return offsets;\n}","import getClippingRect from \"../dom-utils/getClippingRect.js\";\nimport getDocumentElement from \"../dom-utils/getDocumentElement.js\";\nimport getBoundingClientRect from \"../dom-utils/getBoundingClientRect.js\";\nimport computeOffsets from \"./computeOffsets.js\";\nimport rectToClientRect from \"./rectToClientRect.js\";\nimport { clippingParents, reference, popper, bottom, top, right, basePlacements, viewport } from \"../enums.js\";\nimport { isElement } from \"../dom-utils/instanceOf.js\";\nimport mergePaddingObject from \"./mergePaddingObject.js\";\nimport expandToHashMap from \"./expandToHashMap.js\"; // eslint-disable-next-line import/no-unused-modules\n\nexport default function detectOverflow(state, options) {\n if (options === void 0) {\n options = {};\n }\n\n var _options = options,\n _options$placement = _options.placement,\n placement = _options$placement === void 0 ? state.placement : _options$placement,\n _options$strategy = _options.strategy,\n strategy = _options$strategy === void 0 ? state.strategy : _options$strategy,\n _options$boundary = _options.boundary,\n boundary = _options$boundary === void 0 ? clippingParents : _options$boundary,\n _options$rootBoundary = _options.rootBoundary,\n rootBoundary = _options$rootBoundary === void 0 ? viewport : _options$rootBoundary,\n _options$elementConte = _options.elementContext,\n elementContext = _options$elementConte === void 0 ? popper : _options$elementConte,\n _options$altBoundary = _options.altBoundary,\n altBoundary = _options$altBoundary === void 0 ? false : _options$altBoundary,\n _options$padding = _options.padding,\n padding = _options$padding === void 0 ? 0 : _options$padding;\n var paddingObject = mergePaddingObject(typeof padding !== 'number' ? padding : expandToHashMap(padding, basePlacements));\n var altContext = elementContext === popper ? reference : popper;\n var popperRect = state.rects.popper;\n var element = state.elements[altBoundary ? altContext : elementContext];\n var clippingClientRect = getClippingRect(isElement(element) ? element : element.contextElement || getDocumentElement(state.elements.popper), boundary, rootBoundary, strategy);\n var referenceClientRect = getBoundingClientRect(state.elements.reference);\n var popperOffsets = computeOffsets({\n reference: referenceClientRect,\n element: popperRect,\n strategy: 'absolute',\n placement: placement\n });\n var popperClientRect = rectToClientRect(Object.assign({}, popperRect, popperOffsets));\n var elementClientRect = elementContext === popper ? popperClientRect : referenceClientRect; // positive = overflowing the clipping rect\n // 0 or negative = within the clipping rect\n\n var overflowOffsets = {\n top: clippingClientRect.top - elementClientRect.top + paddingObject.top,\n bottom: elementClientRect.bottom - clippingClientRect.bottom + paddingObject.bottom,\n left: clippingClientRect.left - elementClientRect.left + paddingObject.left,\n right: elementClientRect.right - clippingClientRect.right + paddingObject.right\n };\n var offsetData = state.modifiersData.offset; // Offsets can be applied only to the popper element\n\n if (elementContext === popper && offsetData) {\n var offset = offsetData[placement];\n Object.keys(overflowOffsets).forEach(function (key) {\n var multiply = [right, bottom].indexOf(key) >= 0 ? 1 : -1;\n var axis = [top, bottom].indexOf(key) >= 0 ? 'y' : 'x';\n overflowOffsets[key] += offset[axis] * multiply;\n });\n }\n\n return overflowOffsets;\n}","import getVariation from \"./getVariation.js\";\nimport { variationPlacements, basePlacements, placements as allPlacements } from \"../enums.js\";\nimport detectOverflow from \"./detectOverflow.js\";\nimport getBasePlacement from \"./getBasePlacement.js\";\nexport default function computeAutoPlacement(state, options) {\n if (options === void 0) {\n options = {};\n }\n\n var _options = options,\n placement = _options.placement,\n boundary = _options.boundary,\n rootBoundary = _options.rootBoundary,\n padding = _options.padding,\n flipVariations = _options.flipVariations,\n _options$allowedAutoP = _options.allowedAutoPlacements,\n allowedAutoPlacements = _options$allowedAutoP === void 0 ? allPlacements : _options$allowedAutoP;\n var variation = getVariation(placement);\n var placements = variation ? flipVariations ? variationPlacements : variationPlacements.filter(function (placement) {\n return getVariation(placement) === variation;\n }) : basePlacements;\n var allowedPlacements = placements.filter(function (placement) {\n return allowedAutoPlacements.indexOf(placement) >= 0;\n });\n\n if (allowedPlacements.length === 0) {\n allowedPlacements = placements;\n } // $FlowFixMe[incompatible-type]: Flow seems to have problems with two array unions...\n\n\n var overflows = allowedPlacements.reduce(function (acc, placement) {\n acc[placement] = detectOverflow(state, {\n placement: placement,\n boundary: boundary,\n rootBoundary: rootBoundary,\n padding: padding\n })[getBasePlacement(placement)];\n return acc;\n }, {});\n return Object.keys(overflows).sort(function (a, b) {\n return overflows[a] - overflows[b];\n });\n}","import getOppositePlacement from \"../utils/getOppositePlacement.js\";\nimport getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getOppositeVariationPlacement from \"../utils/getOppositeVariationPlacement.js\";\nimport detectOverflow from \"../utils/detectOverflow.js\";\nimport computeAutoPlacement from \"../utils/computeAutoPlacement.js\";\nimport { bottom, top, start, right, left, auto } from \"../enums.js\";\nimport getVariation from \"../utils/getVariation.js\"; // eslint-disable-next-line import/no-unused-modules\n\nfunction getExpandedFallbackPlacements(placement) {\n if (getBasePlacement(placement) === auto) {\n return [];\n }\n\n var oppositePlacement = getOppositePlacement(placement);\n return [getOppositeVariationPlacement(placement), oppositePlacement, getOppositeVariationPlacement(oppositePlacement)];\n}\n\nfunction flip(_ref) {\n var state = _ref.state,\n options = _ref.options,\n name = _ref.name;\n\n if (state.modifiersData[name]._skip) {\n return;\n }\n\n var _options$mainAxis = options.mainAxis,\n checkMainAxis = _options$mainAxis === void 0 ? true : _options$mainAxis,\n _options$altAxis = options.altAxis,\n checkAltAxis = _options$altAxis === void 0 ? true : _options$altAxis,\n specifiedFallbackPlacements = options.fallbackPlacements,\n padding = options.padding,\n boundary = options.boundary,\n rootBoundary = options.rootBoundary,\n altBoundary = options.altBoundary,\n _options$flipVariatio = options.flipVariations,\n flipVariations = _options$flipVariatio === void 0 ? true : _options$flipVariatio,\n allowedAutoPlacements = options.allowedAutoPlacements;\n var preferredPlacement = state.options.placement;\n var basePlacement = getBasePlacement(preferredPlacement);\n var isBasePlacement = basePlacement === preferredPlacement;\n var fallbackPlacements = specifiedFallbackPlacements || (isBasePlacement || !flipVariations ? [getOppositePlacement(preferredPlacement)] : getExpandedFallbackPlacements(preferredPlacement));\n var placements = [preferredPlacement].concat(fallbackPlacements).reduce(function (acc, placement) {\n return acc.concat(getBasePlacement(placement) === auto ? computeAutoPlacement(state, {\n placement: placement,\n boundary: boundary,\n rootBoundary: rootBoundary,\n padding: padding,\n flipVariations: flipVariations,\n allowedAutoPlacements: allowedAutoPlacements\n }) : placement);\n }, []);\n var referenceRect = state.rects.reference;\n var popperRect = state.rects.popper;\n var checksMap = new Map();\n var makeFallbackChecks = true;\n var firstFittingPlacement = placements[0];\n\n for (var i = 0; i < placements.length; i++) {\n var placement = placements[i];\n\n var _basePlacement = getBasePlacement(placement);\n\n var isStartVariation = getVariation(placement) === start;\n var isVertical = [top, bottom].indexOf(_basePlacement) >= 0;\n var len = isVertical ? 'width' : 'height';\n var overflow = detectOverflow(state, {\n placement: placement,\n boundary: boundary,\n rootBoundary: rootBoundary,\n altBoundary: altBoundary,\n padding: padding\n });\n var mainVariationSide = isVertical ? isStartVariation ? right : left : isStartVariation ? bottom : top;\n\n if (referenceRect[len] > popperRect[len]) {\n mainVariationSide = getOppositePlacement(mainVariationSide);\n }\n\n var altVariationSide = getOppositePlacement(mainVariationSide);\n var checks = [];\n\n if (checkMainAxis) {\n checks.push(overflow[_basePlacement] <= 0);\n }\n\n if (checkAltAxis) {\n checks.push(overflow[mainVariationSide] <= 0, overflow[altVariationSide] <= 0);\n }\n\n if (checks.every(function (check) {\n return check;\n })) {\n firstFittingPlacement = placement;\n makeFallbackChecks = false;\n break;\n }\n\n checksMap.set(placement, checks);\n }\n\n if (makeFallbackChecks) {\n // `2` may be desired in some cases – research later\n var numberOfChecks = flipVariations ? 3 : 1;\n\n var _loop = function _loop(_i) {\n var fittingPlacement = placements.find(function (placement) {\n var checks = checksMap.get(placement);\n\n if (checks) {\n return checks.slice(0, _i).every(function (check) {\n return check;\n });\n }\n });\n\n if (fittingPlacement) {\n firstFittingPlacement = fittingPlacement;\n return \"break\";\n }\n };\n\n for (var _i = numberOfChecks; _i > 0; _i--) {\n var _ret = _loop(_i);\n\n if (_ret === \"break\") break;\n }\n }\n\n if (state.placement !== firstFittingPlacement) {\n state.modifiersData[name]._skip = true;\n state.placement = firstFittingPlacement;\n state.reset = true;\n }\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'flip',\n enabled: true,\n phase: 'main',\n fn: flip,\n requiresIfExists: ['offset'],\n data: {\n _skip: false\n }\n};","import { top, bottom, left, right } from \"../enums.js\";\nimport detectOverflow from \"../utils/detectOverflow.js\";\n\nfunction getSideOffsets(overflow, rect, preventedOffsets) {\n if (preventedOffsets === void 0) {\n preventedOffsets = {\n x: 0,\n y: 0\n };\n }\n\n return {\n top: overflow.top - rect.height - preventedOffsets.y,\n right: overflow.right - rect.width + preventedOffsets.x,\n bottom: overflow.bottom - rect.height + preventedOffsets.y,\n left: overflow.left - rect.width - preventedOffsets.x\n };\n}\n\nfunction isAnySideFullyClipped(overflow) {\n return [top, right, bottom, left].some(function (side) {\n return overflow[side] >= 0;\n });\n}\n\nfunction hide(_ref) {\n var state = _ref.state,\n name = _ref.name;\n var referenceRect = state.rects.reference;\n var popperRect = state.rects.popper;\n var preventedOffsets = state.modifiersData.preventOverflow;\n var referenceOverflow = detectOverflow(state, {\n elementContext: 'reference'\n });\n var popperAltOverflow = detectOverflow(state, {\n altBoundary: true\n });\n var referenceClippingOffsets = getSideOffsets(referenceOverflow, referenceRect);\n var popperEscapeOffsets = getSideOffsets(popperAltOverflow, popperRect, preventedOffsets);\n var isReferenceHidden = isAnySideFullyClipped(referenceClippingOffsets);\n var hasPopperEscaped = isAnySideFullyClipped(popperEscapeOffsets);\n state.modifiersData[name] = {\n referenceClippingOffsets: referenceClippingOffsets,\n popperEscapeOffsets: popperEscapeOffsets,\n isReferenceHidden: isReferenceHidden,\n hasPopperEscaped: hasPopperEscaped\n };\n state.attributes.popper = Object.assign({}, state.attributes.popper, {\n 'data-popper-reference-hidden': isReferenceHidden,\n 'data-popper-escaped': hasPopperEscaped\n });\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'hide',\n enabled: true,\n phase: 'main',\n requiresIfExists: ['preventOverflow'],\n fn: hide\n};","import getBasePlacement from \"../utils/getBasePlacement.js\";\nimport { top, left, right, placements } from \"../enums.js\"; // eslint-disable-next-line import/no-unused-modules\n\nexport function distanceAndSkiddingToXY(placement, rects, offset) {\n var basePlacement = getBasePlacement(placement);\n var invertDistance = [left, top].indexOf(basePlacement) >= 0 ? -1 : 1;\n\n var _ref = typeof offset === 'function' ? offset(Object.assign({}, rects, {\n placement: placement\n })) : offset,\n skidding = _ref[0],\n distance = _ref[1];\n\n skidding = skidding || 0;\n distance = (distance || 0) * invertDistance;\n return [left, right].indexOf(basePlacement) >= 0 ? {\n x: distance,\n y: skidding\n } : {\n x: skidding,\n y: distance\n };\n}\n\nfunction offset(_ref2) {\n var state = _ref2.state,\n options = _ref2.options,\n name = _ref2.name;\n var _options$offset = options.offset,\n offset = _options$offset === void 0 ? [0, 0] : _options$offset;\n var data = placements.reduce(function (acc, placement) {\n acc[placement] = distanceAndSkiddingToXY(placement, state.rects, offset);\n return acc;\n }, {});\n var _data$state$placement = data[state.placement],\n x = _data$state$placement.x,\n y = _data$state$placement.y;\n\n if (state.modifiersData.popperOffsets != null) {\n state.modifiersData.popperOffsets.x += x;\n state.modifiersData.popperOffsets.y += y;\n }\n\n state.modifiersData[name] = data;\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'offset',\n enabled: true,\n phase: 'main',\n requires: ['popperOffsets'],\n fn: offset\n};","import computeOffsets from \"../utils/computeOffsets.js\";\n\nfunction popperOffsets(_ref) {\n var state = _ref.state,\n name = _ref.name;\n // Offsets are the actual position the popper needs to have to be\n // properly positioned near its reference element\n // This is the most basic placement, and will be adjusted by\n // the modifiers in the next step\n state.modifiersData[name] = computeOffsets({\n reference: state.rects.reference,\n element: state.rects.popper,\n strategy: 'absolute',\n placement: state.placement\n });\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'popperOffsets',\n enabled: true,\n phase: 'read',\n fn: popperOffsets,\n data: {}\n};","export default function getAltAxis(axis) {\n return axis === 'x' ? 'y' : 'x';\n}","import { top, left, right, bottom, start } from \"../enums.js\";\nimport getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getMainAxisFromPlacement from \"../utils/getMainAxisFromPlacement.js\";\nimport getAltAxis from \"../utils/getAltAxis.js\";\nimport { within, withinMaxClamp } from \"../utils/within.js\";\nimport getLayoutRect from \"../dom-utils/getLayoutRect.js\";\nimport getOffsetParent from \"../dom-utils/getOffsetParent.js\";\nimport detectOverflow from \"../utils/detectOverflow.js\";\nimport getVariation from \"../utils/getVariation.js\";\nimport getFreshSideObject from \"../utils/getFreshSideObject.js\";\nimport { min as mathMin, max as mathMax } from \"../utils/math.js\";\n\nfunction preventOverflow(_ref) {\n var state = _ref.state,\n options = _ref.options,\n name = _ref.name;\n var _options$mainAxis = options.mainAxis,\n checkMainAxis = _options$mainAxis === void 0 ? true : _options$mainAxis,\n _options$altAxis = options.altAxis,\n checkAltAxis = _options$altAxis === void 0 ? false : _options$altAxis,\n boundary = options.boundary,\n rootBoundary = options.rootBoundary,\n altBoundary = options.altBoundary,\n padding = options.padding,\n _options$tether = options.tether,\n tether = _options$tether === void 0 ? true : _options$tether,\n _options$tetherOffset = options.tetherOffset,\n tetherOffset = _options$tetherOffset === void 0 ? 0 : _options$tetherOffset;\n var overflow = detectOverflow(state, {\n boundary: boundary,\n rootBoundary: rootBoundary,\n padding: padding,\n altBoundary: altBoundary\n });\n var basePlacement = getBasePlacement(state.placement);\n var variation = getVariation(state.placement);\n var isBasePlacement = !variation;\n var mainAxis = getMainAxisFromPlacement(basePlacement);\n var altAxis = getAltAxis(mainAxis);\n var popperOffsets = state.modifiersData.popperOffsets;\n var referenceRect = state.rects.reference;\n var popperRect = state.rects.popper;\n var tetherOffsetValue = typeof tetherOffset === 'function' ? tetherOffset(Object.assign({}, state.rects, {\n placement: state.placement\n })) : tetherOffset;\n var normalizedTetherOffsetValue = typeof tetherOffsetValue === 'number' ? {\n mainAxis: tetherOffsetValue,\n altAxis: tetherOffsetValue\n } : Object.assign({\n mainAxis: 0,\n altAxis: 0\n }, tetherOffsetValue);\n var offsetModifierState = state.modifiersData.offset ? state.modifiersData.offset[state.placement] : null;\n var data = {\n x: 0,\n y: 0\n };\n\n if (!popperOffsets) {\n return;\n }\n\n if (checkMainAxis) {\n var _offsetModifierState$;\n\n var mainSide = mainAxis === 'y' ? top : left;\n var altSide = mainAxis === 'y' ? bottom : right;\n var len = mainAxis === 'y' ? 'height' : 'width';\n var offset = popperOffsets[mainAxis];\n var min = offset + overflow[mainSide];\n var max = offset - overflow[altSide];\n var additive = tether ? -popperRect[len] / 2 : 0;\n var minLen = variation === start ? referenceRect[len] : popperRect[len];\n var maxLen = variation === start ? -popperRect[len] : -referenceRect[len]; // We need to include the arrow in the calculation so the arrow doesn't go\n // outside the reference bounds\n\n var arrowElement = state.elements.arrow;\n var arrowRect = tether && arrowElement ? getLayoutRect(arrowElement) : {\n width: 0,\n height: 0\n };\n var arrowPaddingObject = state.modifiersData['arrow#persistent'] ? state.modifiersData['arrow#persistent'].padding : getFreshSideObject();\n var arrowPaddingMin = arrowPaddingObject[mainSide];\n var arrowPaddingMax = arrowPaddingObject[altSide]; // If the reference length is smaller than the arrow length, we don't want\n // to include its full size in the calculation. If the reference is small\n // and near the edge of a boundary, the popper can overflow even if the\n // reference is not overflowing as well (e.g. virtual elements with no\n // width or height)\n\n var arrowLen = within(0, referenceRect[len], arrowRect[len]);\n var minOffset = isBasePlacement ? referenceRect[len] / 2 - additive - arrowLen - arrowPaddingMin - normalizedTetherOffsetValue.mainAxis : minLen - arrowLen - arrowPaddingMin - normalizedTetherOffsetValue.mainAxis;\n var maxOffset = isBasePlacement ? -referenceRect[len] / 2 + additive + arrowLen + arrowPaddingMax + normalizedTetherOffsetValue.mainAxis : maxLen + arrowLen + arrowPaddingMax + normalizedTetherOffsetValue.mainAxis;\n var arrowOffsetParent = state.elements.arrow && getOffsetParent(state.elements.arrow);\n var clientOffset = arrowOffsetParent ? mainAxis === 'y' ? arrowOffsetParent.clientTop || 0 : arrowOffsetParent.clientLeft || 0 : 0;\n var offsetModifierValue = (_offsetModifierState$ = offsetModifierState == null ? void 0 : offsetModifierState[mainAxis]) != null ? _offsetModifierState$ : 0;\n var tetherMin = offset + minOffset - offsetModifierValue - clientOffset;\n var tetherMax = offset + maxOffset - offsetModifierValue;\n var preventedOffset = within(tether ? mathMin(min, tetherMin) : min, offset, tether ? mathMax(max, tetherMax) : max);\n popperOffsets[mainAxis] = preventedOffset;\n data[mainAxis] = preventedOffset - offset;\n }\n\n if (checkAltAxis) {\n var _offsetModifierState$2;\n\n var _mainSide = mainAxis === 'x' ? top : left;\n\n var _altSide = mainAxis === 'x' ? bottom : right;\n\n var _offset = popperOffsets[altAxis];\n\n var _len = altAxis === 'y' ? 'height' : 'width';\n\n var _min = _offset + overflow[_mainSide];\n\n var _max = _offset - overflow[_altSide];\n\n var isOriginSide = [top, left].indexOf(basePlacement) !== -1;\n\n var _offsetModifierValue = (_offsetModifierState$2 = offsetModifierState == null ? void 0 : offsetModifierState[altAxis]) != null ? _offsetModifierState$2 : 0;\n\n var _tetherMin = isOriginSide ? _min : _offset - referenceRect[_len] - popperRect[_len] - _offsetModifierValue + normalizedTetherOffsetValue.altAxis;\n\n var _tetherMax = isOriginSide ? _offset + referenceRect[_len] + popperRect[_len] - _offsetModifierValue - normalizedTetherOffsetValue.altAxis : _max;\n\n var _preventedOffset = tether && isOriginSide ? withinMaxClamp(_tetherMin, _offset, _tetherMax) : within(tether ? _tetherMin : _min, _offset, tether ? _tetherMax : _max);\n\n popperOffsets[altAxis] = _preventedOffset;\n data[altAxis] = _preventedOffset - _offset;\n }\n\n state.modifiersData[name] = data;\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'preventOverflow',\n enabled: true,\n phase: 'main',\n fn: preventOverflow,\n requiresIfExists: ['offset']\n};","export default function getHTMLElementScroll(element) {\n return {\n scrollLeft: element.scrollLeft,\n scrollTop: element.scrollTop\n };\n}","import getWindowScroll from \"./getWindowScroll.js\";\nimport getWindow from \"./getWindow.js\";\nimport { isHTMLElement } from \"./instanceOf.js\";\nimport getHTMLElementScroll from \"./getHTMLElementScroll.js\";\nexport default function getNodeScroll(node) {\n if (node === getWindow(node) || !isHTMLElement(node)) {\n return getWindowScroll(node);\n } else {\n return getHTMLElementScroll(node);\n }\n}","import getBoundingClientRect from \"./getBoundingClientRect.js\";\nimport getNodeScroll from \"./getNodeScroll.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport { isHTMLElement } from \"./instanceOf.js\";\nimport getWindowScrollBarX from \"./getWindowScrollBarX.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport isScrollParent from \"./isScrollParent.js\";\nimport { round } from \"../utils/math.js\";\n\nfunction isElementScaled(element) {\n var rect = element.getBoundingClientRect();\n var scaleX = round(rect.width) / element.offsetWidth || 1;\n var scaleY = round(rect.height) / element.offsetHeight || 1;\n return scaleX !== 1 || scaleY !== 1;\n} // Returns the composite rect of an element relative to its offsetParent.\n// Composite means it takes into account transforms as well as layout.\n\n\nexport default function getCompositeRect(elementOrVirtualElement, offsetParent, isFixed) {\n if (isFixed === void 0) {\n isFixed = false;\n }\n\n var isOffsetParentAnElement = isHTMLElement(offsetParent);\n var offsetParentIsScaled = isHTMLElement(offsetParent) && isElementScaled(offsetParent);\n var documentElement = getDocumentElement(offsetParent);\n var rect = getBoundingClientRect(elementOrVirtualElement, offsetParentIsScaled, isFixed);\n var scroll = {\n scrollLeft: 0,\n scrollTop: 0\n };\n var offsets = {\n x: 0,\n y: 0\n };\n\n if (isOffsetParentAnElement || !isOffsetParentAnElement && !isFixed) {\n if (getNodeName(offsetParent) !== 'body' || // https://github.com/popperjs/popper-core/issues/1078\n isScrollParent(documentElement)) {\n scroll = getNodeScroll(offsetParent);\n }\n\n if (isHTMLElement(offsetParent)) {\n offsets = getBoundingClientRect(offsetParent, true);\n offsets.x += offsetParent.clientLeft;\n offsets.y += offsetParent.clientTop;\n } else if (documentElement) {\n offsets.x = getWindowScrollBarX(documentElement);\n }\n }\n\n return {\n x: rect.left + scroll.scrollLeft - offsets.x,\n y: rect.top + scroll.scrollTop - offsets.y,\n width: rect.width,\n height: rect.height\n };\n}","import { modifierPhases } from \"../enums.js\"; // source: https://stackoverflow.com/questions/49875255\n\nfunction order(modifiers) {\n var map = new Map();\n var visited = new Set();\n var result = [];\n modifiers.forEach(function (modifier) {\n map.set(modifier.name, modifier);\n }); // On visiting object, check for its dependencies and visit them recursively\n\n function sort(modifier) {\n visited.add(modifier.name);\n var requires = [].concat(modifier.requires || [], modifier.requiresIfExists || []);\n requires.forEach(function (dep) {\n if (!visited.has(dep)) {\n var depModifier = map.get(dep);\n\n if (depModifier) {\n sort(depModifier);\n }\n }\n });\n result.push(modifier);\n }\n\n modifiers.forEach(function (modifier) {\n if (!visited.has(modifier.name)) {\n // check for visited object\n sort(modifier);\n }\n });\n return result;\n}\n\nexport default function orderModifiers(modifiers) {\n // order based on dependencies\n var orderedModifiers = order(modifiers); // order based on phase\n\n return modifierPhases.reduce(function (acc, phase) {\n return acc.concat(orderedModifiers.filter(function (modifier) {\n return modifier.phase === phase;\n }));\n }, []);\n}","export default function debounce(fn) {\n var pending;\n return function () {\n if (!pending) {\n pending = new Promise(function (resolve) {\n Promise.resolve().then(function () {\n pending = undefined;\n resolve(fn());\n });\n });\n }\n\n return pending;\n };\n}","export default function mergeByName(modifiers) {\n var merged = modifiers.reduce(function (merged, current) {\n var existing = merged[current.name];\n merged[current.name] = existing ? Object.assign({}, existing, current, {\n options: Object.assign({}, existing.options, current.options),\n data: Object.assign({}, existing.data, current.data)\n }) : current;\n return merged;\n }, {}); // IE11 does not support Object.values\n\n return Object.keys(merged).map(function (key) {\n return merged[key];\n });\n}","import getCompositeRect from \"./dom-utils/getCompositeRect.js\";\nimport getLayoutRect from \"./dom-utils/getLayoutRect.js\";\nimport listScrollParents from \"./dom-utils/listScrollParents.js\";\nimport getOffsetParent from \"./dom-utils/getOffsetParent.js\";\nimport orderModifiers from \"./utils/orderModifiers.js\";\nimport debounce from \"./utils/debounce.js\";\nimport mergeByName from \"./utils/mergeByName.js\";\nimport detectOverflow from \"./utils/detectOverflow.js\";\nimport { isElement } from \"./dom-utils/instanceOf.js\";\nvar DEFAULT_OPTIONS = {\n placement: 'bottom',\n modifiers: [],\n strategy: 'absolute'\n};\n\nfunction areValidElements() {\n for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {\n args[_key] = arguments[_key];\n }\n\n return !args.some(function (element) {\n return !(element && typeof element.getBoundingClientRect === 'function');\n });\n}\n\nexport function popperGenerator(generatorOptions) {\n if (generatorOptions === void 0) {\n generatorOptions = {};\n }\n\n var _generatorOptions = generatorOptions,\n _generatorOptions$def = _generatorOptions.defaultModifiers,\n defaultModifiers = _generatorOptions$def === void 0 ? [] : _generatorOptions$def,\n _generatorOptions$def2 = _generatorOptions.defaultOptions,\n defaultOptions = _generatorOptions$def2 === void 0 ? DEFAULT_OPTIONS : _generatorOptions$def2;\n return function createPopper(reference, popper, options) {\n if (options === void 0) {\n options = defaultOptions;\n }\n\n var state = {\n placement: 'bottom',\n orderedModifiers: [],\n options: Object.assign({}, DEFAULT_OPTIONS, defaultOptions),\n modifiersData: {},\n elements: {\n reference: reference,\n popper: popper\n },\n attributes: {},\n styles: {}\n };\n var effectCleanupFns = [];\n var isDestroyed = false;\n var instance = {\n state: state,\n setOptions: function setOptions(setOptionsAction) {\n var options = typeof setOptionsAction === 'function' ? setOptionsAction(state.options) : setOptionsAction;\n cleanupModifierEffects();\n state.options = Object.assign({}, defaultOptions, state.options, options);\n state.scrollParents = {\n reference: isElement(reference) ? listScrollParents(reference) : reference.contextElement ? listScrollParents(reference.contextElement) : [],\n popper: listScrollParents(popper)\n }; // Orders the modifiers based on their dependencies and `phase`\n // properties\n\n var orderedModifiers = orderModifiers(mergeByName([].concat(defaultModifiers, state.options.modifiers))); // Strip out disabled modifiers\n\n state.orderedModifiers = orderedModifiers.filter(function (m) {\n return m.enabled;\n });\n runModifierEffects();\n return instance.update();\n },\n // Sync update – it will always be executed, even if not necessary. This\n // is useful for low frequency updates where sync behavior simplifies the\n // logic.\n // For high frequency updates (e.g. `resize` and `scroll` events), always\n // prefer the async Popper#update method\n forceUpdate: function forceUpdate() {\n if (isDestroyed) {\n return;\n }\n\n var _state$elements = state.elements,\n reference = _state$elements.reference,\n popper = _state$elements.popper; // Don't proceed if `reference` or `popper` are not valid elements\n // anymore\n\n if (!areValidElements(reference, popper)) {\n return;\n } // Store the reference and popper rects to be read by modifiers\n\n\n state.rects = {\n reference: getCompositeRect(reference, getOffsetParent(popper), state.options.strategy === 'fixed'),\n popper: getLayoutRect(popper)\n }; // Modifiers have the ability to reset the current update cycle. The\n // most common use case for this is the `flip` modifier changing the\n // placement, which then needs to re-run all the modifiers, because the\n // logic was previously ran for the previous placement and is therefore\n // stale/incorrect\n\n state.reset = false;\n state.placement = state.options.placement; // On each update cycle, the `modifiersData` property for each modifier\n // is filled with the initial data specified by the modifier. This means\n // it doesn't persist and is fresh on each update.\n // To ensure persistent data, use `${name}#persistent`\n\n state.orderedModifiers.forEach(function (modifier) {\n return state.modifiersData[modifier.name] = Object.assign({}, modifier.data);\n });\n\n for (var index = 0; index < state.orderedModifiers.length; index++) {\n if (state.reset === true) {\n state.reset = false;\n index = -1;\n continue;\n }\n\n var _state$orderedModifie = state.orderedModifiers[index],\n fn = _state$orderedModifie.fn,\n _state$orderedModifie2 = _state$orderedModifie.options,\n _options = _state$orderedModifie2 === void 0 ? {} : _state$orderedModifie2,\n name = _state$orderedModifie.name;\n\n if (typeof fn === 'function') {\n state = fn({\n state: state,\n options: _options,\n name: name,\n instance: instance\n }) || state;\n }\n }\n },\n // Async and optimistically optimized update – it will not be executed if\n // not necessary (debounced to run at most once-per-tick)\n update: debounce(function () {\n return new Promise(function (resolve) {\n instance.forceUpdate();\n resolve(state);\n });\n }),\n destroy: function destroy() {\n cleanupModifierEffects();\n isDestroyed = true;\n }\n };\n\n if (!areValidElements(reference, popper)) {\n return instance;\n }\n\n instance.setOptions(options).then(function (state) {\n if (!isDestroyed && options.onFirstUpdate) {\n options.onFirstUpdate(state);\n }\n }); // Modifiers have the ability to execute arbitrary code before the first\n // update cycle runs. They will be executed in the same order as the update\n // cycle. This is useful when a modifier adds some persistent data that\n // other modifiers need to use, but the modifier is run after the dependent\n // one.\n\n function runModifierEffects() {\n state.orderedModifiers.forEach(function (_ref) {\n var name = _ref.name,\n _ref$options = _ref.options,\n options = _ref$options === void 0 ? {} : _ref$options,\n effect = _ref.effect;\n\n if (typeof effect === 'function') {\n var cleanupFn = effect({\n state: state,\n name: name,\n instance: instance,\n options: options\n });\n\n var noopFn = function noopFn() {};\n\n effectCleanupFns.push(cleanupFn || noopFn);\n }\n });\n }\n\n function cleanupModifierEffects() {\n effectCleanupFns.forEach(function (fn) {\n return fn();\n });\n effectCleanupFns = [];\n }\n\n return instance;\n };\n}\nexport var createPopper = /*#__PURE__*/popperGenerator(); // eslint-disable-next-line import/no-unused-modules\n\nexport { detectOverflow };","import { popperGenerator, detectOverflow } from \"./createPopper.js\";\nimport eventListeners from \"./modifiers/eventListeners.js\";\nimport popperOffsets from \"./modifiers/popperOffsets.js\";\nimport computeStyles from \"./modifiers/computeStyles.js\";\nimport applyStyles from \"./modifiers/applyStyles.js\";\nimport offset from \"./modifiers/offset.js\";\nimport flip from \"./modifiers/flip.js\";\nimport preventOverflow from \"./modifiers/preventOverflow.js\";\nimport arrow from \"./modifiers/arrow.js\";\nimport hide from \"./modifiers/hide.js\";\nvar defaultModifiers = [eventListeners, popperOffsets, computeStyles, applyStyles, offset, flip, preventOverflow, arrow, hide];\nvar createPopper = /*#__PURE__*/popperGenerator({\n defaultModifiers: defaultModifiers\n}); // eslint-disable-next-line import/no-unused-modules\n\nexport { createPopper, popperGenerator, defaultModifiers, detectOverflow }; // eslint-disable-next-line import/no-unused-modules\n\nexport { createPopper as createPopperLite } from \"./popper-lite.js\"; // eslint-disable-next-line import/no-unused-modules\n\nexport * from \"./modifiers/index.js\";","import { generateUtilityClass } from '../generateUtilityClass';\nimport { generateUtilityClasses } from '../generateUtilityClasses';\nconst COMPONENT_NAME = 'Popper';\nexport function getPopperUtilityClass(slot) {\n return generateUtilityClass(COMPONENT_NAME, slot);\n}\nexport const popperClasses = generateUtilityClasses(COMPONENT_NAME, ['root']);","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"anchorEl\", \"children\", \"direction\", \"disablePortal\", \"modifiers\", \"open\", \"placement\", \"popperOptions\", \"popperRef\", \"slotProps\", \"slots\", \"TransitionProps\", \"ownerState\"],\n _excluded2 = [\"anchorEl\", \"children\", \"container\", \"direction\", \"disablePortal\", \"keepMounted\", \"modifiers\", \"open\", \"placement\", \"popperOptions\", \"popperRef\", \"style\", \"transition\", \"slotProps\", \"slots\"];\nimport * as React from 'react';\nimport { chainPropTypes, HTMLElementType, refType, unstable_ownerDocument as ownerDocument, unstable_useEnhancedEffect as useEnhancedEffect, unstable_useForkRef as useForkRef } from '@mui/utils';\nimport { createPopper } from '@popperjs/core';\nimport PropTypes from 'prop-types';\nimport { unstable_composeClasses as composeClasses } from '../composeClasses';\nimport { Portal } from '../Portal';\nimport { getPopperUtilityClass } from './popperClasses';\nimport { useSlotProps } from '../utils';\nimport { useClassNamesOverride } from '../utils/ClassNameConfigurator';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nfunction flipPlacement(placement, direction) {\n if (direction === 'ltr') {\n return placement;\n }\n switch (placement) {\n case 'bottom-end':\n return 'bottom-start';\n case 'bottom-start':\n return 'bottom-end';\n case 'top-end':\n return 'top-start';\n case 'top-start':\n return 'top-end';\n default:\n return placement;\n }\n}\nfunction resolveAnchorEl(anchorEl) {\n return typeof anchorEl === 'function' ? anchorEl() : anchorEl;\n}\nfunction isHTMLElement(element) {\n return element.nodeType !== undefined;\n}\nfunction isVirtualElement(element) {\n return !isHTMLElement(element);\n}\nconst useUtilityClasses = () => {\n const slots = {\n root: ['root']\n };\n return composeClasses(slots, useClassNamesOverride(getPopperUtilityClass));\n};\nconst defaultPopperOptions = {};\nconst PopperTooltip = /*#__PURE__*/React.forwardRef(function PopperTooltip(props, forwardedRef) {\n var _slots$root;\n const {\n anchorEl,\n children,\n direction,\n disablePortal,\n modifiers,\n open,\n placement: initialPlacement,\n popperOptions,\n popperRef: popperRefProp,\n slotProps = {},\n slots = {},\n TransitionProps\n // @ts-ignore internal logic\n // prevent from spreading to DOM, it can come from the parent component e.g. Select.\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const tooltipRef = React.useRef(null);\n const ownRef = useForkRef(tooltipRef, forwardedRef);\n const popperRef = React.useRef(null);\n const handlePopperRef = useForkRef(popperRef, popperRefProp);\n const handlePopperRefRef = React.useRef(handlePopperRef);\n useEnhancedEffect(() => {\n handlePopperRefRef.current = handlePopperRef;\n }, [handlePopperRef]);\n React.useImperativeHandle(popperRefProp, () => popperRef.current, []);\n const rtlPlacement = flipPlacement(initialPlacement, direction);\n /**\n * placement initialized from prop but can change during lifetime if modifiers.flip.\n * modifiers.flip is essentially a flip for controlled/uncontrolled behavior\n */\n const [placement, setPlacement] = React.useState(rtlPlacement);\n const [resolvedAnchorElement, setResolvedAnchorElement] = React.useState(resolveAnchorEl(anchorEl));\n React.useEffect(() => {\n if (popperRef.current) {\n popperRef.current.forceUpdate();\n }\n });\n React.useEffect(() => {\n if (anchorEl) {\n setResolvedAnchorElement(resolveAnchorEl(anchorEl));\n }\n }, [anchorEl]);\n useEnhancedEffect(() => {\n if (!resolvedAnchorElement || !open) {\n return undefined;\n }\n const handlePopperUpdate = data => {\n setPlacement(data.placement);\n };\n if (process.env.NODE_ENV !== 'production') {\n if (resolvedAnchorElement && isHTMLElement(resolvedAnchorElement) && resolvedAnchorElement.nodeType === 1) {\n const box = resolvedAnchorElement.getBoundingClientRect();\n if (process.env.NODE_ENV !== 'test' && box.top === 0 && box.left === 0 && box.right === 0 && box.bottom === 0) {\n console.warn(['MUI: The `anchorEl` prop provided to the component is invalid.', 'The anchor element should be part of the document layout.', \"Make sure the element is present in the document or that it's not display none.\"].join('\\n'));\n }\n }\n }\n let popperModifiers = [{\n name: 'preventOverflow',\n options: {\n altBoundary: disablePortal\n }\n }, {\n name: 'flip',\n options: {\n altBoundary: disablePortal\n }\n }, {\n name: 'onUpdate',\n enabled: true,\n phase: 'afterWrite',\n fn: ({\n state\n }) => {\n handlePopperUpdate(state);\n }\n }];\n if (modifiers != null) {\n popperModifiers = popperModifiers.concat(modifiers);\n }\n if (popperOptions && popperOptions.modifiers != null) {\n popperModifiers = popperModifiers.concat(popperOptions.modifiers);\n }\n const popper = createPopper(resolvedAnchorElement, tooltipRef.current, _extends({\n placement: rtlPlacement\n }, popperOptions, {\n modifiers: popperModifiers\n }));\n handlePopperRefRef.current(popper);\n return () => {\n popper.destroy();\n handlePopperRefRef.current(null);\n };\n }, [resolvedAnchorElement, disablePortal, modifiers, open, popperOptions, rtlPlacement]);\n const childProps = {\n placement: placement\n };\n if (TransitionProps !== null) {\n childProps.TransitionProps = TransitionProps;\n }\n const classes = useUtilityClasses();\n const Root = (_slots$root = slots.root) != null ? _slots$root : 'div';\n const rootProps = useSlotProps({\n elementType: Root,\n externalSlotProps: slotProps.root,\n externalForwardedProps: other,\n additionalProps: {\n role: 'tooltip',\n ref: ownRef\n },\n ownerState: props,\n className: classes.root\n });\n return /*#__PURE__*/_jsx(Root, _extends({}, rootProps, {\n children: typeof children === 'function' ? children(childProps) : children\n }));\n});\n\n/**\n * Poppers rely on the 3rd party library [Popper.js](https://popper.js.org/docs/v2/) for positioning.\n *\n * Demos:\n *\n * - [Popper](https://mui.com/base-ui/react-popper/)\n *\n * API:\n *\n * - [Popper API](https://mui.com/base-ui/react-popper/components-api/#popper)\n */\nconst Popper = /*#__PURE__*/React.forwardRef(function Popper(props, forwardedRef) {\n const {\n anchorEl,\n children,\n container: containerProp,\n direction = 'ltr',\n disablePortal = false,\n keepMounted = false,\n modifiers,\n open,\n placement = 'bottom',\n popperOptions = defaultPopperOptions,\n popperRef,\n style,\n transition = false,\n slotProps = {},\n slots = {}\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded2);\n const [exited, setExited] = React.useState(true);\n const handleEnter = () => {\n setExited(false);\n };\n const handleExited = () => {\n setExited(true);\n };\n if (!keepMounted && !open && (!transition || exited)) {\n return null;\n }\n\n // If the container prop is provided, use that\n // If the anchorEl prop is provided, use its parent body element as the container\n // If neither are provided let the Modal take care of choosing the container\n let container;\n if (containerProp) {\n container = containerProp;\n } else if (anchorEl) {\n const resolvedAnchorEl = resolveAnchorEl(anchorEl);\n container = resolvedAnchorEl && isHTMLElement(resolvedAnchorEl) ? ownerDocument(resolvedAnchorEl).body : ownerDocument(null).body;\n }\n const display = !open && keepMounted && (!transition || exited) ? 'none' : undefined;\n const transitionProps = transition ? {\n in: open,\n onEnter: handleEnter,\n onExited: handleExited\n } : undefined;\n return /*#__PURE__*/_jsx(Portal, {\n disablePortal: disablePortal,\n container: container,\n children: /*#__PURE__*/_jsx(PopperTooltip, _extends({\n anchorEl: anchorEl,\n direction: direction,\n disablePortal: disablePortal,\n modifiers: modifiers,\n ref: forwardedRef,\n open: transition ? !exited : open,\n placement: placement,\n popperOptions: popperOptions,\n popperRef: popperRef,\n slotProps: slotProps,\n slots: slots\n }, other, {\n style: _extends({\n // Prevents scroll issue, waiting for Popper.js to add this style once initiated.\n position: 'fixed',\n // Fix Popper.js display issue\n top: 0,\n left: 0,\n display\n }, style),\n TransitionProps: transitionProps,\n children: children\n }))\n });\n});\nprocess.env.NODE_ENV !== \"production\" ? Popper.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * An HTML element, [virtualElement](https://popper.js.org/docs/v2/virtual-elements/),\n * or a function that returns either.\n * It's used to set the position of the popper.\n * The return value will passed as the reference object of the Popper instance.\n */\n anchorEl: chainPropTypes(PropTypes.oneOfType([HTMLElementType, PropTypes.object, PropTypes.func]), props => {\n if (props.open) {\n const resolvedAnchorEl = resolveAnchorEl(props.anchorEl);\n if (resolvedAnchorEl && isHTMLElement(resolvedAnchorEl) && resolvedAnchorEl.nodeType === 1) {\n const box = resolvedAnchorEl.getBoundingClientRect();\n if (process.env.NODE_ENV !== 'test' && box.top === 0 && box.left === 0 && box.right === 0 && box.bottom === 0) {\n return new Error(['MUI: The `anchorEl` prop provided to the component is invalid.', 'The anchor element should be part of the document layout.', \"Make sure the element is present in the document or that it's not display none.\"].join('\\n'));\n }\n } else if (!resolvedAnchorEl || typeof resolvedAnchorEl.getBoundingClientRect !== 'function' || isVirtualElement(resolvedAnchorEl) && resolvedAnchorEl.contextElement != null && resolvedAnchorEl.contextElement.nodeType !== 1) {\n return new Error(['MUI: The `anchorEl` prop provided to the component is invalid.', 'It should be an HTML element instance or a virtualElement ', '(https://popper.js.org/docs/v2/virtual-elements/).'].join('\\n'));\n }\n }\n return null;\n }),\n /**\n * Popper render function or node.\n */\n children: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.node, PropTypes.func]),\n /**\n * An HTML element or function that returns one.\n * The `container` will have the portal children appended to it.\n *\n * You can also provide a callback, which is called in a React layout effect.\n * This lets you set the container from a ref, and also makes server-side rendering possible.\n *\n * By default, it uses the body of the top-level document object,\n * so it's simply `document.body` most of the time.\n */\n container: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.func]),\n /**\n * Direction of the text.\n * @default 'ltr'\n */\n direction: PropTypes.oneOf(['ltr', 'rtl']),\n /**\n * The `children` will be under the DOM hierarchy of the parent component.\n * @default false\n */\n disablePortal: PropTypes.bool,\n /**\n * Always keep the children in the DOM.\n * This prop can be useful in SEO situation or\n * when you want to maximize the responsiveness of the Popper.\n * @default false\n */\n keepMounted: PropTypes.bool,\n /**\n * Popper.js is based on a \"plugin-like\" architecture,\n * most of its features are fully encapsulated \"modifiers\".\n *\n * A modifier is a function that is called each time Popper.js needs to\n * compute the position of the popper.\n * For this reason, modifiers should be very performant to avoid bottlenecks.\n * To learn how to create a modifier, [read the modifiers documentation](https://popper.js.org/docs/v2/modifiers/).\n */\n modifiers: PropTypes.arrayOf(PropTypes.shape({\n data: PropTypes.object,\n effect: PropTypes.func,\n enabled: PropTypes.bool,\n fn: PropTypes.func,\n name: PropTypes.any,\n options: PropTypes.object,\n phase: PropTypes.oneOf(['afterMain', 'afterRead', 'afterWrite', 'beforeMain', 'beforeRead', 'beforeWrite', 'main', 'read', 'write']),\n requires: PropTypes.arrayOf(PropTypes.string),\n requiresIfExists: PropTypes.arrayOf(PropTypes.string)\n })),\n /**\n * If `true`, the component is shown.\n */\n open: PropTypes.bool.isRequired,\n /**\n * Popper placement.\n * @default 'bottom'\n */\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n /**\n * Options provided to the [`Popper.js`](https://popper.js.org/docs/v2/constructors/#options) instance.\n * @default {}\n */\n popperOptions: PropTypes.shape({\n modifiers: PropTypes.array,\n onFirstUpdate: PropTypes.func,\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n strategy: PropTypes.oneOf(['absolute', 'fixed'])\n }),\n /**\n * A ref that points to the used popper instance.\n */\n popperRef: refType,\n /**\n * The props used for each slot inside the Popper.\n * @default {}\n */\n slotProps: PropTypes.shape({\n root: PropTypes.oneOfType([PropTypes.func, PropTypes.object])\n }),\n /**\n * The components used for each slot inside the Popper.\n * Either a string to use a HTML element or a component.\n * @default {}\n */\n slots: PropTypes.shape({\n root: PropTypes.elementType\n }),\n /**\n * Help supporting a react-transition-group/Transition component.\n * @default false\n */\n transition: PropTypes.bool\n} : void 0;\nexport { Popper };","'use client';\n\nimport * as React from 'react';\nimport { useTheme as useThemeSystem } from '@mui/system';\nimport defaultTheme from './defaultTheme';\nimport THEME_ID from './identifier';\nexport default function useTheme() {\n const theme = useThemeSystem(defaultTheme);\n if (process.env.NODE_ENV !== 'production') {\n // eslint-disable-next-line react-hooks/rules-of-hooks\n React.useDebugValue(theme);\n }\n return theme[THEME_ID] || theme;\n}","export default function _setPrototypeOf(o, p) {\n _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function _setPrototypeOf(o, p) {\n o.__proto__ = p;\n return o;\n };\n return _setPrototypeOf(o, p);\n}","import setPrototypeOf from \"./setPrototypeOf.js\";\nexport default function _inheritsLoose(subClass, superClass) {\n subClass.prototype = Object.create(superClass.prototype);\n subClass.prototype.constructor = subClass;\n setPrototypeOf(subClass, superClass);\n}","export default {\n disabled: false\n};","import PropTypes from 'prop-types';\nexport var timeoutsShape = process.env.NODE_ENV !== 'production' ? PropTypes.oneOfType([PropTypes.number, PropTypes.shape({\n enter: PropTypes.number,\n exit: PropTypes.number,\n appear: PropTypes.number\n}).isRequired]) : null;\nexport var classNamesShape = process.env.NODE_ENV !== 'production' ? PropTypes.oneOfType([PropTypes.string, PropTypes.shape({\n enter: PropTypes.string,\n exit: PropTypes.string,\n active: PropTypes.string\n}), PropTypes.shape({\n enter: PropTypes.string,\n enterDone: PropTypes.string,\n enterActive: PropTypes.string,\n exit: PropTypes.string,\n exitDone: PropTypes.string,\n exitActive: PropTypes.string\n})]) : null;","import React from 'react';\nexport default React.createContext(null);","export var forceReflow = function forceReflow(node) {\n return node.scrollTop;\n};","import _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _inheritsLoose from \"@babel/runtime/helpers/esm/inheritsLoose\";\nimport PropTypes from 'prop-types';\nimport React from 'react';\nimport ReactDOM from 'react-dom';\nimport config from './config';\nimport { timeoutsShape } from './utils/PropTypes';\nimport TransitionGroupContext from './TransitionGroupContext';\nimport { forceReflow } from './utils/reflow';\nexport var UNMOUNTED = 'unmounted';\nexport var EXITED = 'exited';\nexport var ENTERING = 'entering';\nexport var ENTERED = 'entered';\nexport var EXITING = 'exiting';\n/**\n * The Transition component lets you describe a transition from one component\n * state to another _over time_ with a simple declarative API. Most commonly\n * it's used to animate the mounting and unmounting of a component, but can also\n * be used to describe in-place transition states as well.\n *\n * ---\n *\n * **Note**: `Transition` is a platform-agnostic base component. If you're using\n * transitions in CSS, you'll probably want to use\n * [`CSSTransition`](https://reactcommunity.org/react-transition-group/css-transition)\n * instead. It inherits all the features of `Transition`, but contains\n * additional features necessary to play nice with CSS transitions (hence the\n * name of the component).\n *\n * ---\n *\n * By default the `Transition` component does not alter the behavior of the\n * component it renders, it only tracks \"enter\" and \"exit\" states for the\n * components. It's up to you to give meaning and effect to those states. For\n * example we can add styles to a component when it enters or exits:\n *\n * ```jsx\n * import { Transition } from 'react-transition-group';\n *\n * const duration = 300;\n *\n * const defaultStyle = {\n * transition: `opacity ${duration}ms ease-in-out`,\n * opacity: 0,\n * }\n *\n * const transitionStyles = {\n * entering: { opacity: 1 },\n * entered: { opacity: 1 },\n * exiting: { opacity: 0 },\n * exited: { opacity: 0 },\n * };\n *\n * const Fade = ({ in: inProp }) => (\n * \n * {state => (\n *
    \n * I'm a fade Transition!\n *
    \n * )}\n *
    \n * );\n * ```\n *\n * There are 4 main states a Transition can be in:\n * - `'entering'`\n * - `'entered'`\n * - `'exiting'`\n * - `'exited'`\n *\n * Transition state is toggled via the `in` prop. When `true` the component\n * begins the \"Enter\" stage. During this stage, the component will shift from\n * its current transition state, to `'entering'` for the duration of the\n * transition and then to the `'entered'` stage once it's complete. Let's take\n * the following example (we'll use the\n * [useState](https://reactjs.org/docs/hooks-reference.html#usestate) hook):\n *\n * ```jsx\n * function App() {\n * const [inProp, setInProp] = useState(false);\n * return (\n *
    \n * \n * {state => (\n * // ...\n * )}\n * \n * \n *
    \n * );\n * }\n * ```\n *\n * When the button is clicked the component will shift to the `'entering'` state\n * and stay there for 500ms (the value of `timeout`) before it finally switches\n * to `'entered'`.\n *\n * When `in` is `false` the same thing happens except the state moves from\n * `'exiting'` to `'exited'`.\n */\n\nvar Transition = /*#__PURE__*/function (_React$Component) {\n _inheritsLoose(Transition, _React$Component);\n\n function Transition(props, context) {\n var _this;\n\n _this = _React$Component.call(this, props, context) || this;\n var parentGroup = context; // In the context of a TransitionGroup all enters are really appears\n\n var appear = parentGroup && !parentGroup.isMounting ? props.enter : props.appear;\n var initialStatus;\n _this.appearStatus = null;\n\n if (props.in) {\n if (appear) {\n initialStatus = EXITED;\n _this.appearStatus = ENTERING;\n } else {\n initialStatus = ENTERED;\n }\n } else {\n if (props.unmountOnExit || props.mountOnEnter) {\n initialStatus = UNMOUNTED;\n } else {\n initialStatus = EXITED;\n }\n }\n\n _this.state = {\n status: initialStatus\n };\n _this.nextCallback = null;\n return _this;\n }\n\n Transition.getDerivedStateFromProps = function getDerivedStateFromProps(_ref, prevState) {\n var nextIn = _ref.in;\n\n if (nextIn && prevState.status === UNMOUNTED) {\n return {\n status: EXITED\n };\n }\n\n return null;\n } // getSnapshotBeforeUpdate(prevProps) {\n // let nextStatus = null\n // if (prevProps !== this.props) {\n // const { status } = this.state\n // if (this.props.in) {\n // if (status !== ENTERING && status !== ENTERED) {\n // nextStatus = ENTERING\n // }\n // } else {\n // if (status === ENTERING || status === ENTERED) {\n // nextStatus = EXITING\n // }\n // }\n // }\n // return { nextStatus }\n // }\n ;\n\n var _proto = Transition.prototype;\n\n _proto.componentDidMount = function componentDidMount() {\n this.updateStatus(true, this.appearStatus);\n };\n\n _proto.componentDidUpdate = function componentDidUpdate(prevProps) {\n var nextStatus = null;\n\n if (prevProps !== this.props) {\n var status = this.state.status;\n\n if (this.props.in) {\n if (status !== ENTERING && status !== ENTERED) {\n nextStatus = ENTERING;\n }\n } else {\n if (status === ENTERING || status === ENTERED) {\n nextStatus = EXITING;\n }\n }\n }\n\n this.updateStatus(false, nextStatus);\n };\n\n _proto.componentWillUnmount = function componentWillUnmount() {\n this.cancelNextCallback();\n };\n\n _proto.getTimeouts = function getTimeouts() {\n var timeout = this.props.timeout;\n var exit, enter, appear;\n exit = enter = appear = timeout;\n\n if (timeout != null && typeof timeout !== 'number') {\n exit = timeout.exit;\n enter = timeout.enter; // TODO: remove fallback for next major\n\n appear = timeout.appear !== undefined ? timeout.appear : enter;\n }\n\n return {\n exit: exit,\n enter: enter,\n appear: appear\n };\n };\n\n _proto.updateStatus = function updateStatus(mounting, nextStatus) {\n if (mounting === void 0) {\n mounting = false;\n }\n\n if (nextStatus !== null) {\n // nextStatus will always be ENTERING or EXITING.\n this.cancelNextCallback();\n\n if (nextStatus === ENTERING) {\n if (this.props.unmountOnExit || this.props.mountOnEnter) {\n var node = this.props.nodeRef ? this.props.nodeRef.current : ReactDOM.findDOMNode(this); // https://github.com/reactjs/react-transition-group/pull/749\n // With unmountOnExit or mountOnEnter, the enter animation should happen at the transition between `exited` and `entering`.\n // To make the animation happen, we have to separate each rendering and avoid being processed as batched.\n\n if (node) forceReflow(node);\n }\n\n this.performEnter(mounting);\n } else {\n this.performExit();\n }\n } else if (this.props.unmountOnExit && this.state.status === EXITED) {\n this.setState({\n status: UNMOUNTED\n });\n }\n };\n\n _proto.performEnter = function performEnter(mounting) {\n var _this2 = this;\n\n var enter = this.props.enter;\n var appearing = this.context ? this.context.isMounting : mounting;\n\n var _ref2 = this.props.nodeRef ? [appearing] : [ReactDOM.findDOMNode(this), appearing],\n maybeNode = _ref2[0],\n maybeAppearing = _ref2[1];\n\n var timeouts = this.getTimeouts();\n var enterTimeout = appearing ? timeouts.appear : timeouts.enter; // no enter animation skip right to ENTERED\n // if we are mounting and running this it means appear _must_ be set\n\n if (!mounting && !enter || config.disabled) {\n this.safeSetState({\n status: ENTERED\n }, function () {\n _this2.props.onEntered(maybeNode);\n });\n return;\n }\n\n this.props.onEnter(maybeNode, maybeAppearing);\n this.safeSetState({\n status: ENTERING\n }, function () {\n _this2.props.onEntering(maybeNode, maybeAppearing);\n\n _this2.onTransitionEnd(enterTimeout, function () {\n _this2.safeSetState({\n status: ENTERED\n }, function () {\n _this2.props.onEntered(maybeNode, maybeAppearing);\n });\n });\n });\n };\n\n _proto.performExit = function performExit() {\n var _this3 = this;\n\n var exit = this.props.exit;\n var timeouts = this.getTimeouts();\n var maybeNode = this.props.nodeRef ? undefined : ReactDOM.findDOMNode(this); // no exit animation skip right to EXITED\n\n if (!exit || config.disabled) {\n this.safeSetState({\n status: EXITED\n }, function () {\n _this3.props.onExited(maybeNode);\n });\n return;\n }\n\n this.props.onExit(maybeNode);\n this.safeSetState({\n status: EXITING\n }, function () {\n _this3.props.onExiting(maybeNode);\n\n _this3.onTransitionEnd(timeouts.exit, function () {\n _this3.safeSetState({\n status: EXITED\n }, function () {\n _this3.props.onExited(maybeNode);\n });\n });\n });\n };\n\n _proto.cancelNextCallback = function cancelNextCallback() {\n if (this.nextCallback !== null) {\n this.nextCallback.cancel();\n this.nextCallback = null;\n }\n };\n\n _proto.safeSetState = function safeSetState(nextState, callback) {\n // This shouldn't be necessary, but there are weird race conditions with\n // setState callbacks and unmounting in testing, so always make sure that\n // we can cancel any pending setState callbacks after we unmount.\n callback = this.setNextCallback(callback);\n this.setState(nextState, callback);\n };\n\n _proto.setNextCallback = function setNextCallback(callback) {\n var _this4 = this;\n\n var active = true;\n\n this.nextCallback = function (event) {\n if (active) {\n active = false;\n _this4.nextCallback = null;\n callback(event);\n }\n };\n\n this.nextCallback.cancel = function () {\n active = false;\n };\n\n return this.nextCallback;\n };\n\n _proto.onTransitionEnd = function onTransitionEnd(timeout, handler) {\n this.setNextCallback(handler);\n var node = this.props.nodeRef ? this.props.nodeRef.current : ReactDOM.findDOMNode(this);\n var doesNotHaveTimeoutOrListener = timeout == null && !this.props.addEndListener;\n\n if (!node || doesNotHaveTimeoutOrListener) {\n setTimeout(this.nextCallback, 0);\n return;\n }\n\n if (this.props.addEndListener) {\n var _ref3 = this.props.nodeRef ? [this.nextCallback] : [node, this.nextCallback],\n maybeNode = _ref3[0],\n maybeNextCallback = _ref3[1];\n\n this.props.addEndListener(maybeNode, maybeNextCallback);\n }\n\n if (timeout != null) {\n setTimeout(this.nextCallback, timeout);\n }\n };\n\n _proto.render = function render() {\n var status = this.state.status;\n\n if (status === UNMOUNTED) {\n return null;\n }\n\n var _this$props = this.props,\n children = _this$props.children,\n _in = _this$props.in,\n _mountOnEnter = _this$props.mountOnEnter,\n _unmountOnExit = _this$props.unmountOnExit,\n _appear = _this$props.appear,\n _enter = _this$props.enter,\n _exit = _this$props.exit,\n _timeout = _this$props.timeout,\n _addEndListener = _this$props.addEndListener,\n _onEnter = _this$props.onEnter,\n _onEntering = _this$props.onEntering,\n _onEntered = _this$props.onEntered,\n _onExit = _this$props.onExit,\n _onExiting = _this$props.onExiting,\n _onExited = _this$props.onExited,\n _nodeRef = _this$props.nodeRef,\n childProps = _objectWithoutPropertiesLoose(_this$props, [\"children\", \"in\", \"mountOnEnter\", \"unmountOnExit\", \"appear\", \"enter\", \"exit\", \"timeout\", \"addEndListener\", \"onEnter\", \"onEntering\", \"onEntered\", \"onExit\", \"onExiting\", \"onExited\", \"nodeRef\"]);\n\n return (\n /*#__PURE__*/\n // allows for nested Transitions\n React.createElement(TransitionGroupContext.Provider, {\n value: null\n }, typeof children === 'function' ? children(status, childProps) : React.cloneElement(React.Children.only(children), childProps))\n );\n };\n\n return Transition;\n}(React.Component);\n\nTransition.contextType = TransitionGroupContext;\nTransition.propTypes = process.env.NODE_ENV !== \"production\" ? {\n /**\n * A React reference to DOM element that need to transition:\n * https://stackoverflow.com/a/51127130/4671932\n *\n * - When `nodeRef` prop is used, `node` is not passed to callback functions\n * (e.g. `onEnter`) because user already has direct access to the node.\n * - When changing `key` prop of `Transition` in a `TransitionGroup` a new\n * `nodeRef` need to be provided to `Transition` with changed `key` prop\n * (see\n * [test/CSSTransition-test.js](https://github.com/reactjs/react-transition-group/blob/13435f897b3ab71f6e19d724f145596f5910581c/test/CSSTransition-test.js#L362-L437)).\n */\n nodeRef: PropTypes.shape({\n current: typeof Element === 'undefined' ? PropTypes.any : function (propValue, key, componentName, location, propFullName, secret) {\n var value = propValue[key];\n return PropTypes.instanceOf(value && 'ownerDocument' in value ? value.ownerDocument.defaultView.Element : Element)(propValue, key, componentName, location, propFullName, secret);\n }\n }),\n\n /**\n * A `function` child can be used instead of a React element. This function is\n * called with the current transition status (`'entering'`, `'entered'`,\n * `'exiting'`, `'exited'`), which can be used to apply context\n * specific props to a component.\n *\n * ```jsx\n * \n * {state => (\n * \n * )}\n * \n * ```\n */\n children: PropTypes.oneOfType([PropTypes.func.isRequired, PropTypes.element.isRequired]).isRequired,\n\n /**\n * Show the component; triggers the enter or exit states\n */\n in: PropTypes.bool,\n\n /**\n * By default the child component is mounted immediately along with\n * the parent `Transition` component. If you want to \"lazy mount\" the component on the\n * first `in={true}` you can set `mountOnEnter`. After the first enter transition the component will stay\n * mounted, even on \"exited\", unless you also specify `unmountOnExit`.\n */\n mountOnEnter: PropTypes.bool,\n\n /**\n * By default the child component stays mounted after it reaches the `'exited'` state.\n * Set `unmountOnExit` if you'd prefer to unmount the component after it finishes exiting.\n */\n unmountOnExit: PropTypes.bool,\n\n /**\n * By default the child component does not perform the enter transition when\n * it first mounts, regardless of the value of `in`. If you want this\n * behavior, set both `appear` and `in` to `true`.\n *\n * > **Note**: there are no special appear states like `appearing`/`appeared`, this prop\n * > only adds an additional enter transition. However, in the\n * > `` component that first enter transition does result in\n * > additional `.appear-*` classes, that way you can choose to style it\n * > differently.\n */\n appear: PropTypes.bool,\n\n /**\n * Enable or disable enter transitions.\n */\n enter: PropTypes.bool,\n\n /**\n * Enable or disable exit transitions.\n */\n exit: PropTypes.bool,\n\n /**\n * The duration of the transition, in milliseconds.\n * Required unless `addEndListener` is provided.\n *\n * You may specify a single timeout for all transitions:\n *\n * ```jsx\n * timeout={500}\n * ```\n *\n * or individually:\n *\n * ```jsx\n * timeout={{\n * appear: 500,\n * enter: 300,\n * exit: 500,\n * }}\n * ```\n *\n * - `appear` defaults to the value of `enter`\n * - `enter` defaults to `0`\n * - `exit` defaults to `0`\n *\n * @type {number | { enter?: number, exit?: number, appear?: number }}\n */\n timeout: function timeout(props) {\n var pt = timeoutsShape;\n if (!props.addEndListener) pt = pt.isRequired;\n\n for (var _len = arguments.length, args = new Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) {\n args[_key - 1] = arguments[_key];\n }\n\n return pt.apply(void 0, [props].concat(args));\n },\n\n /**\n * Add a custom transition end trigger. Called with the transitioning\n * DOM node and a `done` callback. Allows for more fine grained transition end\n * logic. Timeouts are still used as a fallback if provided.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * ```jsx\n * addEndListener={(node, done) => {\n * // use the css transitionend event to mark the finish of a transition\n * node.addEventListener('transitionend', done, false);\n * }}\n * ```\n */\n addEndListener: PropTypes.func,\n\n /**\n * Callback fired before the \"entering\" status is applied. An extra parameter\n * `isAppearing` is supplied to indicate if the enter stage is occurring on the initial mount\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement, isAppearing: bool) -> void\n */\n onEnter: PropTypes.func,\n\n /**\n * Callback fired after the \"entering\" status is applied. An extra parameter\n * `isAppearing` is supplied to indicate if the enter stage is occurring on the initial mount\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement, isAppearing: bool)\n */\n onEntering: PropTypes.func,\n\n /**\n * Callback fired after the \"entered\" status is applied. An extra parameter\n * `isAppearing` is supplied to indicate if the enter stage is occurring on the initial mount\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement, isAppearing: bool) -> void\n */\n onEntered: PropTypes.func,\n\n /**\n * Callback fired before the \"exiting\" status is applied.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement) -> void\n */\n onExit: PropTypes.func,\n\n /**\n * Callback fired after the \"exiting\" status is applied.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement) -> void\n */\n onExiting: PropTypes.func,\n\n /**\n * Callback fired after the \"exited\" status is applied.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed\n *\n * @type Function(node: HtmlElement) -> void\n */\n onExited: PropTypes.func\n} : {}; // Name the function so it is clearer in the documentation\n\nfunction noop() {}\n\nTransition.defaultProps = {\n in: false,\n mountOnEnter: false,\n unmountOnExit: false,\n appear: false,\n enter: true,\n exit: true,\n onEnter: noop,\n onEntering: noop,\n onEntered: noop,\n onExit: noop,\n onExiting: noop,\n onExited: noop\n};\nTransition.UNMOUNTED = UNMOUNTED;\nTransition.EXITED = EXITED;\nTransition.ENTERING = ENTERING;\nTransition.ENTERED = ENTERED;\nTransition.EXITING = EXITING;\nexport default Transition;","export const reflow = node => node.scrollTop;\nexport function getTransitionProps(props, options) {\n var _style$transitionDura, _style$transitionTimi;\n const {\n timeout,\n easing,\n style = {}\n } = props;\n return {\n duration: (_style$transitionDura = style.transitionDuration) != null ? _style$transitionDura : typeof timeout === 'number' ? timeout : timeout[options.mode] || 0,\n easing: (_style$transitionTimi = style.transitionTimingFunction) != null ? _style$transitionTimi : typeof easing === 'object' ? easing[options.mode] : easing,\n delay: style.transitionDelay\n };\n}","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"addEndListener\", \"appear\", \"children\", \"easing\", \"in\", \"onEnter\", \"onEntered\", \"onEntering\", \"onExit\", \"onExited\", \"onExiting\", \"style\", \"timeout\", \"TransitionComponent\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport { elementAcceptingRef, unstable_useTimeout as useTimeout } from '@mui/utils';\nimport { Transition } from 'react-transition-group';\nimport useTheme from '../styles/useTheme';\nimport { getTransitionProps, reflow } from '../transitions/utils';\nimport useForkRef from '../utils/useForkRef';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nfunction getScale(value) {\n return `scale(${value}, ${value ** 2})`;\n}\nconst styles = {\n entering: {\n opacity: 1,\n transform: getScale(1)\n },\n entered: {\n opacity: 1,\n transform: 'none'\n }\n};\n\n/*\n TODO v6: remove\n Conditionally apply a workaround for the CSS transition bug in Safari 15.4 / WebKit browsers.\n */\nconst isWebKit154 = typeof navigator !== 'undefined' && /^((?!chrome|android).)*(safari|mobile)/i.test(navigator.userAgent) && /(os |version\\/)15(.|_)4/i.test(navigator.userAgent);\n\n/**\n * The Grow transition is used by the [Tooltip](/material-ui/react-tooltip/) and\n * [Popover](/material-ui/react-popover/) components.\n * It uses [react-transition-group](https://github.com/reactjs/react-transition-group) internally.\n */\nconst Grow = /*#__PURE__*/React.forwardRef(function Grow(props, ref) {\n const {\n addEndListener,\n appear = true,\n children,\n easing,\n in: inProp,\n onEnter,\n onEntered,\n onEntering,\n onExit,\n onExited,\n onExiting,\n style,\n timeout = 'auto',\n // eslint-disable-next-line react/prop-types\n TransitionComponent = Transition\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const timer = useTimeout();\n const autoTimeout = React.useRef();\n const theme = useTheme();\n const nodeRef = React.useRef(null);\n const handleRef = useForkRef(nodeRef, children.ref, ref);\n const normalizedTransitionCallback = callback => maybeIsAppearing => {\n if (callback) {\n const node = nodeRef.current;\n\n // onEnterXxx and onExitXxx callbacks have a different arguments.length value.\n if (maybeIsAppearing === undefined) {\n callback(node);\n } else {\n callback(node, maybeIsAppearing);\n }\n }\n };\n const handleEntering = normalizedTransitionCallback(onEntering);\n const handleEnter = normalizedTransitionCallback((node, isAppearing) => {\n reflow(node); // So the animation always start from the start.\n\n const {\n duration: transitionDuration,\n delay,\n easing: transitionTimingFunction\n } = getTransitionProps({\n style,\n timeout,\n easing\n }, {\n mode: 'enter'\n });\n let duration;\n if (timeout === 'auto') {\n duration = theme.transitions.getAutoHeightDuration(node.clientHeight);\n autoTimeout.current = duration;\n } else {\n duration = transitionDuration;\n }\n node.style.transition = [theme.transitions.create('opacity', {\n duration,\n delay\n }), theme.transitions.create('transform', {\n duration: isWebKit154 ? duration : duration * 0.666,\n delay,\n easing: transitionTimingFunction\n })].join(',');\n if (onEnter) {\n onEnter(node, isAppearing);\n }\n });\n const handleEntered = normalizedTransitionCallback(onEntered);\n const handleExiting = normalizedTransitionCallback(onExiting);\n const handleExit = normalizedTransitionCallback(node => {\n const {\n duration: transitionDuration,\n delay,\n easing: transitionTimingFunction\n } = getTransitionProps({\n style,\n timeout,\n easing\n }, {\n mode: 'exit'\n });\n let duration;\n if (timeout === 'auto') {\n duration = theme.transitions.getAutoHeightDuration(node.clientHeight);\n autoTimeout.current = duration;\n } else {\n duration = transitionDuration;\n }\n node.style.transition = [theme.transitions.create('opacity', {\n duration,\n delay\n }), theme.transitions.create('transform', {\n duration: isWebKit154 ? duration : duration * 0.666,\n delay: isWebKit154 ? delay : delay || duration * 0.333,\n easing: transitionTimingFunction\n })].join(',');\n node.style.opacity = 0;\n node.style.transform = getScale(0.75);\n if (onExit) {\n onExit(node);\n }\n });\n const handleExited = normalizedTransitionCallback(onExited);\n const handleAddEndListener = next => {\n if (timeout === 'auto') {\n timer.start(autoTimeout.current || 0, next);\n }\n if (addEndListener) {\n // Old call signature before `react-transition-group` implemented `nodeRef`\n addEndListener(nodeRef.current, next);\n }\n };\n return /*#__PURE__*/_jsx(TransitionComponent, _extends({\n appear: appear,\n in: inProp,\n nodeRef: nodeRef,\n onEnter: handleEnter,\n onEntered: handleEntered,\n onEntering: handleEntering,\n onExit: handleExit,\n onExited: handleExited,\n onExiting: handleExiting,\n addEndListener: handleAddEndListener,\n timeout: timeout === 'auto' ? null : timeout\n }, other, {\n children: (state, childProps) => {\n return /*#__PURE__*/React.cloneElement(children, _extends({\n style: _extends({\n opacity: 0,\n transform: getScale(0.75),\n visibility: state === 'exited' && !inProp ? 'hidden' : undefined\n }, styles[state], style, children.props.style),\n ref: handleRef\n }, childProps));\n }\n }));\n});\nprocess.env.NODE_ENV !== \"production\" ? Grow.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the d.ts file and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * Add a custom transition end trigger. Called with the transitioning DOM\n * node and a done callback. Allows for more fine grained transition end\n * logic. Note: Timeouts are still used as a fallback if provided.\n */\n addEndListener: PropTypes.func,\n /**\n * Perform the enter transition when it first mounts if `in` is also `true`.\n * Set this to `false` to disable this behavior.\n * @default true\n */\n appear: PropTypes.bool,\n /**\n * A single child content element.\n */\n children: elementAcceptingRef.isRequired,\n /**\n * The transition timing function.\n * You may specify a single easing or a object containing enter and exit values.\n */\n easing: PropTypes.oneOfType([PropTypes.shape({\n enter: PropTypes.string,\n exit: PropTypes.string\n }), PropTypes.string]),\n /**\n * If `true`, the component will transition in.\n */\n in: PropTypes.bool,\n /**\n * @ignore\n */\n onEnter: PropTypes.func,\n /**\n * @ignore\n */\n onEntered: PropTypes.func,\n /**\n * @ignore\n */\n onEntering: PropTypes.func,\n /**\n * @ignore\n */\n onExit: PropTypes.func,\n /**\n * @ignore\n */\n onExited: PropTypes.func,\n /**\n * @ignore\n */\n onExiting: PropTypes.func,\n /**\n * @ignore\n */\n style: PropTypes.object,\n /**\n * The duration for the transition, in milliseconds.\n * You may specify a single timeout for all transitions, or individually with an object.\n *\n * Set to 'auto' to automatically calculate transition time based on height.\n * @default 'auto'\n */\n timeout: PropTypes.oneOfType([PropTypes.oneOf(['auto']), PropTypes.number, PropTypes.shape({\n appear: PropTypes.number,\n enter: PropTypes.number,\n exit: PropTypes.number\n })])\n} : void 0;\nGrow.muiSupportAuto = true;\nexport default Grow;","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"anchorEl\", \"component\", \"components\", \"componentsProps\", \"container\", \"disablePortal\", \"keepMounted\", \"modifiers\", \"open\", \"placement\", \"popperOptions\", \"popperRef\", \"transition\", \"slots\", \"slotProps\"];\nimport { Popper as BasePopper } from '@mui/base/Popper';\nimport { useThemeWithoutDefault as useTheme } from '@mui/system';\nimport { HTMLElementType, refType } from '@mui/utils';\nimport PropTypes from 'prop-types';\nimport * as React from 'react';\nimport { styled, useThemeProps } from '../styles';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nconst PopperRoot = styled(BasePopper, {\n name: 'MuiPopper',\n slot: 'Root',\n overridesResolver: (props, styles) => styles.root\n})({});\n\n/**\n *\n * Demos:\n *\n * - [Autocomplete](https://mui.com/material-ui/react-autocomplete/)\n * - [Menu](https://mui.com/material-ui/react-menu/)\n * - [Popper](https://mui.com/material-ui/react-popper/)\n *\n * API:\n *\n * - [Popper API](https://mui.com/material-ui/api/popper/)\n */\nconst Popper = /*#__PURE__*/React.forwardRef(function Popper(inProps, ref) {\n var _slots$root;\n const theme = useTheme();\n const props = useThemeProps({\n props: inProps,\n name: 'MuiPopper'\n });\n const {\n anchorEl,\n component,\n components,\n componentsProps,\n container,\n disablePortal,\n keepMounted,\n modifiers,\n open,\n placement,\n popperOptions,\n popperRef,\n transition,\n slots,\n slotProps\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const RootComponent = (_slots$root = slots == null ? void 0 : slots.root) != null ? _slots$root : components == null ? void 0 : components.Root;\n const otherProps = _extends({\n anchorEl,\n container,\n disablePortal,\n keepMounted,\n modifiers,\n open,\n placement,\n popperOptions,\n popperRef,\n transition\n }, other);\n return /*#__PURE__*/_jsx(PopperRoot, _extends({\n as: component,\n direction: theme == null ? void 0 : theme.direction,\n slots: {\n root: RootComponent\n },\n slotProps: slotProps != null ? slotProps : componentsProps\n }, otherProps, {\n ref: ref\n }));\n});\nprocess.env.NODE_ENV !== \"production\" ? Popper.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * An HTML element, [virtualElement](https://popper.js.org/docs/v2/virtual-elements/),\n * or a function that returns either.\n * It's used to set the position of the popper.\n * The return value will passed as the reference object of the Popper instance.\n */\n anchorEl: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.object, PropTypes.func]),\n /**\n * Popper render function or node.\n */\n children: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.node, PropTypes.func]),\n /**\n * The component used for the root node.\n * Either a string to use a HTML element or a component.\n */\n component: PropTypes.elementType,\n /**\n * The components used for each slot inside the Popper.\n * Either a string to use a HTML element or a component.\n * @default {}\n */\n components: PropTypes.shape({\n Root: PropTypes.elementType\n }),\n /**\n * The props used for each slot inside the Popper.\n * @default {}\n */\n componentsProps: PropTypes.shape({\n root: PropTypes.oneOfType([PropTypes.func, PropTypes.object])\n }),\n /**\n * An HTML element or function that returns one.\n * The `container` will have the portal children appended to it.\n *\n * You can also provide a callback, which is called in a React layout effect.\n * This lets you set the container from a ref, and also makes server-side rendering possible.\n *\n * By default, it uses the body of the top-level document object,\n * so it's simply `document.body` most of the time.\n */\n container: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.func]),\n /**\n * The `children` will be under the DOM hierarchy of the parent component.\n * @default false\n */\n disablePortal: PropTypes.bool,\n /**\n * Always keep the children in the DOM.\n * This prop can be useful in SEO situation or\n * when you want to maximize the responsiveness of the Popper.\n * @default false\n */\n keepMounted: PropTypes.bool,\n /**\n * Popper.js is based on a \"plugin-like\" architecture,\n * most of its features are fully encapsulated \"modifiers\".\n *\n * A modifier is a function that is called each time Popper.js needs to\n * compute the position of the popper.\n * For this reason, modifiers should be very performant to avoid bottlenecks.\n * To learn how to create a modifier, [read the modifiers documentation](https://popper.js.org/docs/v2/modifiers/).\n */\n modifiers: PropTypes.arrayOf(PropTypes.shape({\n data: PropTypes.object,\n effect: PropTypes.func,\n enabled: PropTypes.bool,\n fn: PropTypes.func,\n name: PropTypes.any,\n options: PropTypes.object,\n phase: PropTypes.oneOf(['afterMain', 'afterRead', 'afterWrite', 'beforeMain', 'beforeRead', 'beforeWrite', 'main', 'read', 'write']),\n requires: PropTypes.arrayOf(PropTypes.string),\n requiresIfExists: PropTypes.arrayOf(PropTypes.string)\n })),\n /**\n * If `true`, the component is shown.\n */\n open: PropTypes.bool.isRequired,\n /**\n * Popper placement.\n * @default 'bottom'\n */\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n /**\n * Options provided to the [`Popper.js`](https://popper.js.org/docs/v2/constructors/#options) instance.\n * @default {}\n */\n popperOptions: PropTypes.shape({\n modifiers: PropTypes.array,\n onFirstUpdate: PropTypes.func,\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n strategy: PropTypes.oneOf(['absolute', 'fixed'])\n }),\n /**\n * A ref that points to the used popper instance.\n */\n popperRef: refType,\n /**\n * The props used for each slot inside the Popper.\n * @default {}\n */\n slotProps: PropTypes.shape({\n root: PropTypes.oneOfType([PropTypes.func, PropTypes.object])\n }),\n /**\n * The components used for each slot inside the Popper.\n * Either a string to use a HTML element or a component.\n * @default {}\n */\n slots: PropTypes.shape({\n root: PropTypes.elementType\n }),\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Help supporting a react-transition-group/Transition component.\n * @default false\n */\n transition: PropTypes.bool\n} : void 0;\nexport default Popper;","import generateUtilityClasses from '@mui/utils/generateUtilityClasses';\nimport generateUtilityClass from '@mui/utils/generateUtilityClass';\nexport function getTooltipUtilityClass(slot) {\n return generateUtilityClass('MuiTooltip', slot);\n}\nconst tooltipClasses = generateUtilityClasses('MuiTooltip', ['popper', 'popperInteractive', 'popperArrow', 'popperClose', 'tooltip', 'tooltipArrow', 'touch', 'tooltipPlacementLeft', 'tooltipPlacementRight', 'tooltipPlacementTop', 'tooltipPlacementBottom', 'arrow']);\nexport default tooltipClasses;","'use client';\n\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nconst _excluded = [\"arrow\", \"children\", \"classes\", \"components\", \"componentsProps\", \"describeChild\", \"disableFocusListener\", \"disableHoverListener\", \"disableInteractive\", \"disableTouchListener\", \"enterDelay\", \"enterNextDelay\", \"enterTouchDelay\", \"followCursor\", \"id\", \"leaveDelay\", \"leaveTouchDelay\", \"onClose\", \"onOpen\", \"open\", \"placement\", \"PopperComponent\", \"PopperProps\", \"slotProps\", \"slots\", \"title\", \"TransitionComponent\", \"TransitionProps\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport clsx from 'clsx';\nimport { elementAcceptingRef, unstable_useTimeout as useTimeout, unstable_Timeout as Timeout } from '@mui/utils';\nimport { unstable_composeClasses as composeClasses, appendOwnerState } from '@mui/base';\nimport { alpha } from '@mui/system';\nimport styled from '../styles/styled';\nimport useTheme from '../styles/useTheme';\nimport useThemeProps from '../styles/useThemeProps';\nimport capitalize from '../utils/capitalize';\nimport Grow from '../Grow';\nimport Popper from '../Popper';\nimport useEventCallback from '../utils/useEventCallback';\nimport useForkRef from '../utils/useForkRef';\nimport useId from '../utils/useId';\nimport useIsFocusVisible from '../utils/useIsFocusVisible';\nimport useControlled from '../utils/useControlled';\nimport tooltipClasses, { getTooltipUtilityClass } from './tooltipClasses';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nimport { jsxs as _jsxs } from \"react/jsx-runtime\";\nfunction round(value) {\n return Math.round(value * 1e5) / 1e5;\n}\nconst useUtilityClasses = ownerState => {\n const {\n classes,\n disableInteractive,\n arrow,\n touch,\n placement\n } = ownerState;\n const slots = {\n popper: ['popper', !disableInteractive && 'popperInteractive', arrow && 'popperArrow'],\n tooltip: ['tooltip', arrow && 'tooltipArrow', touch && 'touch', `tooltipPlacement${capitalize(placement.split('-')[0])}`],\n arrow: ['arrow']\n };\n return composeClasses(slots, getTooltipUtilityClass, classes);\n};\nconst TooltipPopper = styled(Popper, {\n name: 'MuiTooltip',\n slot: 'Popper',\n overridesResolver: (props, styles) => {\n const {\n ownerState\n } = props;\n return [styles.popper, !ownerState.disableInteractive && styles.popperInteractive, ownerState.arrow && styles.popperArrow, !ownerState.open && styles.popperClose];\n }\n})(({\n theme,\n ownerState,\n open\n}) => _extends({\n zIndex: (theme.vars || theme).zIndex.tooltip,\n pointerEvents: 'none'\n}, !ownerState.disableInteractive && {\n pointerEvents: 'auto'\n}, !open && {\n pointerEvents: 'none'\n}, ownerState.arrow && {\n [`&[data-popper-placement*=\"bottom\"] .${tooltipClasses.arrow}`]: {\n top: 0,\n marginTop: '-0.71em',\n '&::before': {\n transformOrigin: '0 100%'\n }\n },\n [`&[data-popper-placement*=\"top\"] .${tooltipClasses.arrow}`]: {\n bottom: 0,\n marginBottom: '-0.71em',\n '&::before': {\n transformOrigin: '100% 0'\n }\n },\n [`&[data-popper-placement*=\"right\"] .${tooltipClasses.arrow}`]: _extends({}, !ownerState.isRtl ? {\n left: 0,\n marginLeft: '-0.71em'\n } : {\n right: 0,\n marginRight: '-0.71em'\n }, {\n height: '1em',\n width: '0.71em',\n '&::before': {\n transformOrigin: '100% 100%'\n }\n }),\n [`&[data-popper-placement*=\"left\"] .${tooltipClasses.arrow}`]: _extends({}, !ownerState.isRtl ? {\n right: 0,\n marginRight: '-0.71em'\n } : {\n left: 0,\n marginLeft: '-0.71em'\n }, {\n height: '1em',\n width: '0.71em',\n '&::before': {\n transformOrigin: '0 0'\n }\n })\n}));\nconst TooltipTooltip = styled('div', {\n name: 'MuiTooltip',\n slot: 'Tooltip',\n overridesResolver: (props, styles) => {\n const {\n ownerState\n } = props;\n return [styles.tooltip, ownerState.touch && styles.touch, ownerState.arrow && styles.tooltipArrow, styles[`tooltipPlacement${capitalize(ownerState.placement.split('-')[0])}`]];\n }\n})(({\n theme,\n ownerState\n}) => _extends({\n backgroundColor: theme.vars ? theme.vars.palette.Tooltip.bg : alpha(theme.palette.grey[700], 0.92),\n borderRadius: (theme.vars || theme).shape.borderRadius,\n color: (theme.vars || theme).palette.common.white,\n fontFamily: theme.typography.fontFamily,\n padding: '4px 8px',\n fontSize: theme.typography.pxToRem(11),\n maxWidth: 300,\n margin: 2,\n wordWrap: 'break-word',\n fontWeight: theme.typography.fontWeightMedium\n}, ownerState.arrow && {\n position: 'relative',\n margin: 0\n}, ownerState.touch && {\n padding: '8px 16px',\n fontSize: theme.typography.pxToRem(14),\n lineHeight: `${round(16 / 14)}em`,\n fontWeight: theme.typography.fontWeightRegular\n}, {\n [`.${tooltipClasses.popper}[data-popper-placement*=\"left\"] &`]: _extends({\n transformOrigin: 'right center'\n }, !ownerState.isRtl ? _extends({\n marginRight: '14px'\n }, ownerState.touch && {\n marginRight: '24px'\n }) : _extends({\n marginLeft: '14px'\n }, ownerState.touch && {\n marginLeft: '24px'\n })),\n [`.${tooltipClasses.popper}[data-popper-placement*=\"right\"] &`]: _extends({\n transformOrigin: 'left center'\n }, !ownerState.isRtl ? _extends({\n marginLeft: '14px'\n }, ownerState.touch && {\n marginLeft: '24px'\n }) : _extends({\n marginRight: '14px'\n }, ownerState.touch && {\n marginRight: '24px'\n })),\n [`.${tooltipClasses.popper}[data-popper-placement*=\"top\"] &`]: _extends({\n transformOrigin: 'center bottom',\n marginBottom: '14px'\n }, ownerState.touch && {\n marginBottom: '24px'\n }),\n [`.${tooltipClasses.popper}[data-popper-placement*=\"bottom\"] &`]: _extends({\n transformOrigin: 'center top',\n marginTop: '14px'\n }, ownerState.touch && {\n marginTop: '24px'\n })\n}));\nconst TooltipArrow = styled('span', {\n name: 'MuiTooltip',\n slot: 'Arrow',\n overridesResolver: (props, styles) => styles.arrow\n})(({\n theme\n}) => ({\n overflow: 'hidden',\n position: 'absolute',\n width: '1em',\n height: '0.71em' /* = width / sqrt(2) = (length of the hypotenuse) */,\n boxSizing: 'border-box',\n color: theme.vars ? theme.vars.palette.Tooltip.bg : alpha(theme.palette.grey[700], 0.9),\n '&::before': {\n content: '\"\"',\n margin: 'auto',\n display: 'block',\n width: '100%',\n height: '100%',\n backgroundColor: 'currentColor',\n transform: 'rotate(45deg)'\n }\n}));\nlet hystersisOpen = false;\nconst hystersisTimer = new Timeout();\nlet cursorPosition = {\n x: 0,\n y: 0\n};\nexport function testReset() {\n hystersisOpen = false;\n hystersisTimer.clear();\n}\nfunction composeEventHandler(handler, eventHandler) {\n return event => {\n if (eventHandler) {\n eventHandler(event);\n }\n handler(event);\n };\n}\n\n// TODO v6: Remove PopperComponent, PopperProps, TransitionComponent and TransitionProps.\nconst Tooltip = /*#__PURE__*/React.forwardRef(function Tooltip(inProps, ref) {\n var _ref, _slots$popper, _ref2, _ref3, _slots$transition, _ref4, _slots$tooltip, _ref5, _slots$arrow, _slotProps$popper, _ref6, _slotProps$popper2, _slotProps$transition, _slotProps$tooltip, _ref7, _slotProps$tooltip2, _slotProps$arrow, _ref8, _slotProps$arrow2;\n const props = useThemeProps({\n props: inProps,\n name: 'MuiTooltip'\n });\n const {\n arrow = false,\n children: childrenProp,\n components = {},\n componentsProps = {},\n describeChild = false,\n disableFocusListener = false,\n disableHoverListener = false,\n disableInteractive: disableInteractiveProp = false,\n disableTouchListener = false,\n enterDelay = 100,\n enterNextDelay = 0,\n enterTouchDelay = 700,\n followCursor = false,\n id: idProp,\n leaveDelay = 0,\n leaveTouchDelay = 1500,\n onClose,\n onOpen,\n open: openProp,\n placement = 'bottom',\n PopperComponent: PopperComponentProp,\n PopperProps = {},\n slotProps = {},\n slots = {},\n title,\n TransitionComponent: TransitionComponentProp = Grow,\n TransitionProps\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n\n // to prevent runtime errors, developers will need to provide a child as a React element anyway.\n const children = /*#__PURE__*/React.isValidElement(childrenProp) ? childrenProp : /*#__PURE__*/_jsx(\"span\", {\n children: childrenProp\n });\n const theme = useTheme();\n const isRtl = theme.direction === 'rtl';\n const [childNode, setChildNode] = React.useState();\n const [arrowRef, setArrowRef] = React.useState(null);\n const ignoreNonTouchEvents = React.useRef(false);\n const disableInteractive = disableInteractiveProp || followCursor;\n const closeTimer = useTimeout();\n const enterTimer = useTimeout();\n const leaveTimer = useTimeout();\n const touchTimer = useTimeout();\n const [openState, setOpenState] = useControlled({\n controlled: openProp,\n default: false,\n name: 'Tooltip',\n state: 'open'\n });\n let open = openState;\n if (process.env.NODE_ENV !== 'production') {\n // eslint-disable-next-line react-hooks/rules-of-hooks\n const {\n current: isControlled\n } = React.useRef(openProp !== undefined);\n\n // eslint-disable-next-line react-hooks/rules-of-hooks\n React.useEffect(() => {\n if (childNode && childNode.disabled && !isControlled && title !== '' && childNode.tagName.toLowerCase() === 'button') {\n console.error(['MUI: You are providing a disabled `button` child to the Tooltip component.', 'A disabled element does not fire events.', \"Tooltip needs to listen to the child element's events to display the title.\", '', 'Add a simple wrapper element, such as a `span`.'].join('\\n'));\n }\n }, [title, childNode, isControlled]);\n }\n const id = useId(idProp);\n const prevUserSelect = React.useRef();\n const stopTouchInteraction = useEventCallback(() => {\n if (prevUserSelect.current !== undefined) {\n document.body.style.WebkitUserSelect = prevUserSelect.current;\n prevUserSelect.current = undefined;\n }\n touchTimer.clear();\n });\n React.useEffect(() => stopTouchInteraction, [stopTouchInteraction]);\n const handleOpen = event => {\n hystersisTimer.clear();\n hystersisOpen = true;\n\n // The mouseover event will trigger for every nested element in the tooltip.\n // We can skip rerendering when the tooltip is already open.\n // We are using the mouseover event instead of the mouseenter event to fix a hide/show issue.\n setOpenState(true);\n if (onOpen && !open) {\n onOpen(event);\n }\n };\n const handleClose = useEventCallback(\n /**\n * @param {React.SyntheticEvent | Event} event\n */\n event => {\n hystersisTimer.start(800 + leaveDelay, () => {\n hystersisOpen = false;\n });\n setOpenState(false);\n if (onClose && open) {\n onClose(event);\n }\n closeTimer.start(theme.transitions.duration.shortest, () => {\n ignoreNonTouchEvents.current = false;\n });\n });\n const handleEnter = event => {\n if (ignoreNonTouchEvents.current && event.type !== 'touchstart') {\n return;\n }\n\n // Remove the title ahead of time.\n // We don't want to wait for the next render commit.\n // We would risk displaying two tooltips at the same time (native + this one).\n if (childNode) {\n childNode.removeAttribute('title');\n }\n enterTimer.clear();\n leaveTimer.clear();\n if (enterDelay || hystersisOpen && enterNextDelay) {\n enterTimer.start(hystersisOpen ? enterNextDelay : enterDelay, () => {\n handleOpen(event);\n });\n } else {\n handleOpen(event);\n }\n };\n const handleLeave = event => {\n enterTimer.clear();\n leaveTimer.start(leaveDelay, () => {\n handleClose(event);\n });\n };\n const {\n isFocusVisibleRef,\n onBlur: handleBlurVisible,\n onFocus: handleFocusVisible,\n ref: focusVisibleRef\n } = useIsFocusVisible();\n // We don't necessarily care about the focusVisible state (which is safe to access via ref anyway).\n // We just need to re-render the Tooltip if the focus-visible state changes.\n const [, setChildIsFocusVisible] = React.useState(false);\n const handleBlur = event => {\n handleBlurVisible(event);\n if (isFocusVisibleRef.current === false) {\n setChildIsFocusVisible(false);\n handleLeave(event);\n }\n };\n const handleFocus = event => {\n // Workaround for https://github.com/facebook/react/issues/7769\n // The autoFocus of React might trigger the event before the componentDidMount.\n // We need to account for this eventuality.\n if (!childNode) {\n setChildNode(event.currentTarget);\n }\n handleFocusVisible(event);\n if (isFocusVisibleRef.current === true) {\n setChildIsFocusVisible(true);\n handleEnter(event);\n }\n };\n const detectTouchStart = event => {\n ignoreNonTouchEvents.current = true;\n const childrenProps = children.props;\n if (childrenProps.onTouchStart) {\n childrenProps.onTouchStart(event);\n }\n };\n const handleMouseOver = handleEnter;\n const handleMouseLeave = handleLeave;\n const handleTouchStart = event => {\n detectTouchStart(event);\n leaveTimer.clear();\n closeTimer.clear();\n stopTouchInteraction();\n prevUserSelect.current = document.body.style.WebkitUserSelect;\n // Prevent iOS text selection on long-tap.\n document.body.style.WebkitUserSelect = 'none';\n touchTimer.start(enterTouchDelay, () => {\n document.body.style.WebkitUserSelect = prevUserSelect.current;\n handleEnter(event);\n });\n };\n const handleTouchEnd = event => {\n if (children.props.onTouchEnd) {\n children.props.onTouchEnd(event);\n }\n stopTouchInteraction();\n leaveTimer.start(leaveTouchDelay, () => {\n handleClose(event);\n });\n };\n React.useEffect(() => {\n if (!open) {\n return undefined;\n }\n\n /**\n * @param {KeyboardEvent} nativeEvent\n */\n function handleKeyDown(nativeEvent) {\n // IE11, Edge (prior to using Bink?) use 'Esc'\n if (nativeEvent.key === 'Escape' || nativeEvent.key === 'Esc') {\n handleClose(nativeEvent);\n }\n }\n document.addEventListener('keydown', handleKeyDown);\n return () => {\n document.removeEventListener('keydown', handleKeyDown);\n };\n }, [handleClose, open]);\n const handleRef = useForkRef(children.ref, focusVisibleRef, setChildNode, ref);\n\n // There is no point in displaying an empty tooltip.\n // So we exclude all falsy values, except 0, which is valid.\n if (!title && title !== 0) {\n open = false;\n }\n const popperRef = React.useRef();\n const handleMouseMove = event => {\n const childrenProps = children.props;\n if (childrenProps.onMouseMove) {\n childrenProps.onMouseMove(event);\n }\n cursorPosition = {\n x: event.clientX,\n y: event.clientY\n };\n if (popperRef.current) {\n popperRef.current.update();\n }\n };\n const nameOrDescProps = {};\n const titleIsString = typeof title === 'string';\n if (describeChild) {\n nameOrDescProps.title = !open && titleIsString && !disableHoverListener ? title : null;\n nameOrDescProps['aria-describedby'] = open ? id : null;\n } else {\n nameOrDescProps['aria-label'] = titleIsString ? title : null;\n nameOrDescProps['aria-labelledby'] = open && !titleIsString ? id : null;\n }\n const childrenProps = _extends({}, nameOrDescProps, other, children.props, {\n className: clsx(other.className, children.props.className),\n onTouchStart: detectTouchStart,\n ref: handleRef\n }, followCursor ? {\n onMouseMove: handleMouseMove\n } : {});\n if (process.env.NODE_ENV !== 'production') {\n childrenProps['data-mui-internal-clone-element'] = true;\n\n // eslint-disable-next-line react-hooks/rules-of-hooks\n React.useEffect(() => {\n if (childNode && !childNode.getAttribute('data-mui-internal-clone-element')) {\n console.error(['MUI: The `children` component of the Tooltip is not forwarding its props correctly.', 'Please make sure that props are spread on the same element that the ref is applied to.'].join('\\n'));\n }\n }, [childNode]);\n }\n const interactiveWrapperListeners = {};\n if (!disableTouchListener) {\n childrenProps.onTouchStart = handleTouchStart;\n childrenProps.onTouchEnd = handleTouchEnd;\n }\n if (!disableHoverListener) {\n childrenProps.onMouseOver = composeEventHandler(handleMouseOver, childrenProps.onMouseOver);\n childrenProps.onMouseLeave = composeEventHandler(handleMouseLeave, childrenProps.onMouseLeave);\n if (!disableInteractive) {\n interactiveWrapperListeners.onMouseOver = handleMouseOver;\n interactiveWrapperListeners.onMouseLeave = handleMouseLeave;\n }\n }\n if (!disableFocusListener) {\n childrenProps.onFocus = composeEventHandler(handleFocus, childrenProps.onFocus);\n childrenProps.onBlur = composeEventHandler(handleBlur, childrenProps.onBlur);\n if (!disableInteractive) {\n interactiveWrapperListeners.onFocus = handleFocus;\n interactiveWrapperListeners.onBlur = handleBlur;\n }\n }\n if (process.env.NODE_ENV !== 'production') {\n if (children.props.title) {\n console.error(['MUI: You have provided a `title` prop to the child of .', `Remove this title prop \\`${children.props.title}\\` or the Tooltip component.`].join('\\n'));\n }\n }\n const popperOptions = React.useMemo(() => {\n var _PopperProps$popperOp;\n let tooltipModifiers = [{\n name: 'arrow',\n enabled: Boolean(arrowRef),\n options: {\n element: arrowRef,\n padding: 4\n }\n }];\n if ((_PopperProps$popperOp = PopperProps.popperOptions) != null && _PopperProps$popperOp.modifiers) {\n tooltipModifiers = tooltipModifiers.concat(PopperProps.popperOptions.modifiers);\n }\n return _extends({}, PopperProps.popperOptions, {\n modifiers: tooltipModifiers\n });\n }, [arrowRef, PopperProps]);\n const ownerState = _extends({}, props, {\n isRtl,\n arrow,\n disableInteractive,\n placement,\n PopperComponentProp,\n touch: ignoreNonTouchEvents.current\n });\n const classes = useUtilityClasses(ownerState);\n const PopperComponent = (_ref = (_slots$popper = slots.popper) != null ? _slots$popper : components.Popper) != null ? _ref : TooltipPopper;\n const TransitionComponent = (_ref2 = (_ref3 = (_slots$transition = slots.transition) != null ? _slots$transition : components.Transition) != null ? _ref3 : TransitionComponentProp) != null ? _ref2 : Grow;\n const TooltipComponent = (_ref4 = (_slots$tooltip = slots.tooltip) != null ? _slots$tooltip : components.Tooltip) != null ? _ref4 : TooltipTooltip;\n const ArrowComponent = (_ref5 = (_slots$arrow = slots.arrow) != null ? _slots$arrow : components.Arrow) != null ? _ref5 : TooltipArrow;\n const popperProps = appendOwnerState(PopperComponent, _extends({}, PopperProps, (_slotProps$popper = slotProps.popper) != null ? _slotProps$popper : componentsProps.popper, {\n className: clsx(classes.popper, PopperProps == null ? void 0 : PopperProps.className, (_ref6 = (_slotProps$popper2 = slotProps.popper) != null ? _slotProps$popper2 : componentsProps.popper) == null ? void 0 : _ref6.className)\n }), ownerState);\n const transitionProps = appendOwnerState(TransitionComponent, _extends({}, TransitionProps, (_slotProps$transition = slotProps.transition) != null ? _slotProps$transition : componentsProps.transition), ownerState);\n const tooltipProps = appendOwnerState(TooltipComponent, _extends({}, (_slotProps$tooltip = slotProps.tooltip) != null ? _slotProps$tooltip : componentsProps.tooltip, {\n className: clsx(classes.tooltip, (_ref7 = (_slotProps$tooltip2 = slotProps.tooltip) != null ? _slotProps$tooltip2 : componentsProps.tooltip) == null ? void 0 : _ref7.className)\n }), ownerState);\n const tooltipArrowProps = appendOwnerState(ArrowComponent, _extends({}, (_slotProps$arrow = slotProps.arrow) != null ? _slotProps$arrow : componentsProps.arrow, {\n className: clsx(classes.arrow, (_ref8 = (_slotProps$arrow2 = slotProps.arrow) != null ? _slotProps$arrow2 : componentsProps.arrow) == null ? void 0 : _ref8.className)\n }), ownerState);\n return /*#__PURE__*/_jsxs(React.Fragment, {\n children: [/*#__PURE__*/React.cloneElement(children, childrenProps), /*#__PURE__*/_jsx(PopperComponent, _extends({\n as: PopperComponentProp != null ? PopperComponentProp : Popper,\n placement: placement,\n anchorEl: followCursor ? {\n getBoundingClientRect: () => ({\n top: cursorPosition.y,\n left: cursorPosition.x,\n right: cursorPosition.x,\n bottom: cursorPosition.y,\n width: 0,\n height: 0\n })\n } : childNode,\n popperRef: popperRef,\n open: childNode ? open : false,\n id: id,\n transition: true\n }, interactiveWrapperListeners, popperProps, {\n popperOptions: popperOptions,\n children: ({\n TransitionProps: TransitionPropsInner\n }) => /*#__PURE__*/_jsx(TransitionComponent, _extends({\n timeout: theme.transitions.duration.shorter\n }, TransitionPropsInner, transitionProps, {\n children: /*#__PURE__*/_jsxs(TooltipComponent, _extends({}, tooltipProps, {\n children: [title, arrow ? /*#__PURE__*/_jsx(ArrowComponent, _extends({}, tooltipArrowProps, {\n ref: setArrowRef\n })) : null]\n }))\n }))\n }))]\n });\n});\nprocess.env.NODE_ENV !== \"production\" ? Tooltip.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the d.ts file and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * If `true`, adds an arrow to the tooltip.\n * @default false\n */\n arrow: PropTypes.bool,\n /**\n * Tooltip reference element.\n */\n children: elementAcceptingRef.isRequired,\n /**\n * Override or extend the styles applied to the component.\n */\n classes: PropTypes.object,\n /**\n * @ignore\n */\n className: PropTypes.string,\n /**\n * The components used for each slot inside.\n *\n * This prop is an alias for the `slots` prop.\n * It's recommended to use the `slots` prop instead.\n *\n * @default {}\n */\n components: PropTypes.shape({\n Arrow: PropTypes.elementType,\n Popper: PropTypes.elementType,\n Tooltip: PropTypes.elementType,\n Transition: PropTypes.elementType\n }),\n /**\n * The extra props for the slot components.\n * You can override the existing props or add new ones.\n *\n * This prop is an alias for the `slotProps` prop.\n * It's recommended to use the `slotProps` prop instead, as `componentsProps` will be deprecated in the future.\n *\n * @default {}\n */\n componentsProps: PropTypes.shape({\n arrow: PropTypes.object,\n popper: PropTypes.object,\n tooltip: PropTypes.object,\n transition: PropTypes.object\n }),\n /**\n * Set to `true` if the `title` acts as an accessible description.\n * By default the `title` acts as an accessible label for the child.\n * @default false\n */\n describeChild: PropTypes.bool,\n /**\n * Do not respond to focus-visible events.\n * @default false\n */\n disableFocusListener: PropTypes.bool,\n /**\n * Do not respond to hover events.\n * @default false\n */\n disableHoverListener: PropTypes.bool,\n /**\n * Makes a tooltip not interactive, i.e. it will close when the user\n * hovers over the tooltip before the `leaveDelay` is expired.\n * @default false\n */\n disableInteractive: PropTypes.bool,\n /**\n * Do not respond to long press touch events.\n * @default false\n */\n disableTouchListener: PropTypes.bool,\n /**\n * The number of milliseconds to wait before showing the tooltip.\n * This prop won't impact the enter touch delay (`enterTouchDelay`).\n * @default 100\n */\n enterDelay: PropTypes.number,\n /**\n * The number of milliseconds to wait before showing the tooltip when one was already recently opened.\n * @default 0\n */\n enterNextDelay: PropTypes.number,\n /**\n * The number of milliseconds a user must touch the element before showing the tooltip.\n * @default 700\n */\n enterTouchDelay: PropTypes.number,\n /**\n * If `true`, the tooltip follow the cursor over the wrapped element.\n * @default false\n */\n followCursor: PropTypes.bool,\n /**\n * This prop is used to help implement the accessibility logic.\n * If you don't provide this prop. It falls back to a randomly generated id.\n */\n id: PropTypes.string,\n /**\n * The number of milliseconds to wait before hiding the tooltip.\n * This prop won't impact the leave touch delay (`leaveTouchDelay`).\n * @default 0\n */\n leaveDelay: PropTypes.number,\n /**\n * The number of milliseconds after the user stops touching an element before hiding the tooltip.\n * @default 1500\n */\n leaveTouchDelay: PropTypes.number,\n /**\n * Callback fired when the component requests to be closed.\n *\n * @param {React.SyntheticEvent} event The event source of the callback.\n */\n onClose: PropTypes.func,\n /**\n * Callback fired when the component requests to be open.\n *\n * @param {React.SyntheticEvent} event The event source of the callback.\n */\n onOpen: PropTypes.func,\n /**\n * If `true`, the component is shown.\n */\n open: PropTypes.bool,\n /**\n * Tooltip placement.\n * @default 'bottom'\n */\n placement: PropTypes.oneOf(['bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n /**\n * The component used for the popper.\n * @default Popper\n */\n PopperComponent: PropTypes.elementType,\n /**\n * Props applied to the [`Popper`](/material-ui/api/popper/) element.\n * @default {}\n */\n PopperProps: PropTypes.object,\n /**\n * The extra props for the slot components.\n * You can override the existing props or add new ones.\n *\n * This prop is an alias for the `componentsProps` prop, which will be deprecated in the future.\n *\n * @default {}\n */\n slotProps: PropTypes.shape({\n arrow: PropTypes.object,\n popper: PropTypes.object,\n tooltip: PropTypes.object,\n transition: PropTypes.object\n }),\n /**\n * The components used for each slot inside.\n *\n * This prop is an alias for the `components` prop, which will be deprecated in the future.\n *\n * @default {}\n */\n slots: PropTypes.shape({\n arrow: PropTypes.elementType,\n popper: PropTypes.elementType,\n tooltip: PropTypes.elementType,\n transition: PropTypes.elementType\n }),\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Tooltip title. Zero-length titles string, undefined, null and false are never displayed.\n */\n title: PropTypes.node,\n /**\n * The component used for the transition.\n * [Follow this guide](/material-ui/transitions/#transitioncomponent-prop) to learn more about the requirements for this component.\n * @default Grow\n */\n TransitionComponent: PropTypes.elementType,\n /**\n * Props applied to the transition element.\n * By default, the element is based on this [`Transition`](http://reactcommunity.org/react-transition-group/transition/) component.\n */\n TransitionProps: PropTypes.object\n} : void 0;\nexport default Tooltip;","import '@/components/mui/menu-item.component.css';\nimport ArrowRightIcon from '@mui/icons-material/ArrowRight';\nimport {\n ListItemIcon as MuiListItemIcon,\n ListItemText as MuiListItemText,\n MenuItem as MuiMenuItem,\n} from '@mui/material';\nimport Tooltip from '@mui/material/Tooltip';\nimport { Localized, ReferencedItem, SingleColumnMenu } from 'platform-bible-utils';\nimport { MouseEvent, PropsWithChildren } from 'react';\n\ntype MenuItemInfoBase = {\n /** Text (displayable in the UI) as the name of the menu item */\n label: string;\n /** Text to display when the mouse hovers over the menu item */\n tooltip?: string;\n};\n\nexport type Command = MenuItemInfoBase & {\n /** Command to execute (string.string) */\n command: string;\n};\n\ntype SubMenu = MenuItemInfoBase & {\n /** Command to execute (string.string) */\n items: MenuItemInfo[];\n};\n\nexport interface CommandHandler {\n (command: Command): void;\n}\n\nexport type MenuPropsBase = {\n /*\n * The JSON defining the menu whose items are to be rendered. This will typically be one of the\n * menus in the \"defs\" in a Platform.Bible menu (see PlatformMenus). The schema for this is\n * menuDocumentSchema (at the end of menus.model.ts). Note that while this is a\n * \"SingleColumnMenu\", somewhat bizarrely, a MultiColumnMenu is a SingleColumnMenu, so it really\n * could be a MultiColumnMenu, in which case, column had better be defined so it can be used\n * to filter out the actual groups and items to display on the column.\n */\n menuDefinition: Localized;\n\n commandHandler: CommandHandler;\n\n /**\n * Additional action to perform when any menu item is clicked. Allows the caller to handle event\n * (e.g., to close the menu).\n */\n onClick?: (event: MouseEvent) => void;\n};\n\nexport type MenuItemListProps = MenuPropsBase & {\n /** Optional unique (column) identifier */\n columnId?: ReferencedItem;\n};\n\nexport type MenuItemProps = Omit &\n PropsWithChildren<{\n /** Optional unique identifier */\n id?: string;\n\n onClick: (event: MouseEvent) => void;\n }>;\n\ntype MenuItemInfo = (Command | SubMenu) & {\n /**\n * If specified, menu item will be inset if it does not have a leading icon.\n *\n * @default true\n */\n allowForLeadingIcons?: boolean;\n /**\n * If specified, the path to the icon image to display on the leading side of the menu text.\n *\n * @default undefined (no leading icon will be shown)\n */\n iconPathBefore?: string;\n /**\n * If specified, the path to the icon image to display on the trailing side of the menu text.\n *\n * @default undefined (no trailing icon will be shown)\n */\n iconPathAfter?: string;\n /**\n * If true, list item is focused during the first mount\n *\n * @default false\n */\n hasAutoFocus?: boolean;\n\n /** Additional css classes to help with unique styling of the menu item */\n className?: string;\n\n /**\n * If true, the menu item will appear disabled and it will not respond to clicks or mouse hovers.\n *\n * @default false\n */\n isDisabled?: boolean;\n\n /**\n * If true, compact vertical padding designed for keyboard and mouse input is used.\n *\n * @default true\n */\n isDense?: boolean;\n\n /**\n * If true, a right-arrow icon will be displayed (iconPathAfter, if specified, will be ignored).\n *\n * @default false\n */\n isSubMenuParent?: boolean;\n\n /**\n * If true, the left and right padding is removed\n *\n * @default false\n */\n hasDisabledGutters?: boolean;\n\n /**\n * If true, a 1px light border is added to bottom of menu item\n *\n * @default false\n */\n hasDivider?: boolean;\n\n /** Help identify which element has keyboard focus */\n focusVisibleClassName?: string;\n\n /** If it's a submenu, it should have the items property */\n items?: MenuItemInfo[];\n};\n\nfunction getIcon(icon: string | undefined, menuLabel: string, leading: boolean) {\n return icon ? (\n \n {`${leading\n \n ) : undefined;\n}\n\nexport default function MenuItem(props: MenuItemProps) {\n const {\n onClick,\n label,\n tooltip,\n allowForLeadingIcons = true,\n iconPathBefore = undefined,\n iconPathAfter = undefined,\n hasAutoFocus = false,\n className,\n isDisabled = false,\n isDense = true,\n isSubMenuParent = false,\n hasDisabledGutters = false,\n hasDivider = false,\n focusVisibleClassName,\n id,\n children,\n } = props;\n\n const menuItem = (\n \n {label ? (\n <>\n {getIcon(iconPathBefore, label, true)}\n \n {isSubMenuParent ? (\n \n \n \n ) : (\n getIcon(iconPathAfter, label, false)\n )}\n \n ) : (\n children\n )}\n \n );\n\n return tooltip ? (\n \n
    {menuItem}
    \n
    \n ) : (\n menuItem\n );\n}\n","import MenuItem, {\n MenuItemListProps,\n MenuItemProps,\n MenuPropsBase,\n} from '@/components/mui/menu-item.component';\nimport { Menu } from '@mui/material';\nimport {\n Localized,\n MenuGroupDetailsInSubMenu,\n MenuItemContainingCommand,\n MenuItemContainingSubmenu,\n OrderedExtensibleContainer,\n ReferencedItem,\n SingleColumnMenu,\n} from 'platform-bible-utils';\nimport { MouseEvent, useMemo, useState } from 'react';\n\n/**\n * All the exported types in this file should be regarded as \"internal\" (i.e., they should not be\n * exposed via index.ts).\n */\n\nexport type GroupedMenuPropsBase = MenuPropsBase & {\n /** Optional unique (column) identifier */\n columnId?: ReferencedItem;\n};\n\nexport type GroupedMenuItemListProps = MenuItemListProps & {\n /**\n * If the menuDefinition includes \"top-level\" groups (i.e., those that belong to a column as\n * opposed to those that belong to a submenu) that should not be included in the list, then this\n * array specifies which groups to include. Likewise, for a submenu, this list indicates which\n * groups are pertinent for that submenu. So then for a context menu this property need not be\n * specified since it is a top-level menu based on a \"true\" SingleColumnMenu (i.e., one that is\n * not a MultiColumnMenu).\n */\n includedGroups?: {\n id: string;\n group: Localized;\n }[];\n};\n\ninterface ItemInfo {\n item: Localized;\n isLastItemInGroup: boolean;\n}\n\ntype SubMenuProps = MenuPropsBase & {\n parentMenuItem: Localized;\n parentItemProps: Omit, 'iconPathAfter'>;\n};\n\nfunction getAllGroups(menuDefinition: Localized) {\n const groupEntries = Object.entries(menuDefinition.groups);\n // Convert array of entries to array of objects with id and group properties\n return groupEntries.map(([key, value]) => ({ id: key, group: value }));\n}\n\nfunction SubMenu(props: SubMenuProps) {\n const [anchorEl, setAnchorEl] = useState(undefined);\n\n const { parentMenuItem, parentItemProps, menuDefinition } = props;\n\n const handleParentMenuItemClick = (event: MouseEvent) => {\n setAnchorEl(event.currentTarget);\n };\n\n const handleClose = () => {\n setAnchorEl(undefined);\n };\n\n const renderSubMenuItems = () => {\n let includedGroups = getAllGroups(menuDefinition).filter((g) => 'menuItem' in g.group);\n\n // Ensure valid parent menu was provided. (If not, submenu will contain all groups!)\n if (!parentMenuItem?.id) throw new Error('A valid parent menu item is required for submenus.');\n\n // When laying out a submenu, only include groups associated with the provided parent menu.\n // Note: without the (annoying) redundant check that the included groups\n // have the menuItem field, TS doesn't think it exists.\n includedGroups = includedGroups.filter(\n (group) => 'menuItem' in group.group && group.group.menuItem === parentMenuItem.id,\n );\n\n return ;\n };\n\n return (\n <>\n \n \n {renderSubMenuItems()}\n \n \n );\n}\n\nconst getOrderedGroupItems = (\n groupId: string,\n allItems: Localized[],\n) => {\n // Filter items that belong to the specified group\n const itemsForGroup = allItems.filter((item) => item.group === groupId);\n // Sort items based on order\n const sortedItems = itemsForGroup.sort((a, b) => (a.order || 0) - (b.order || 0));\n return sortedItems;\n};\n\n/**\n * This component is internal; it does not need to be exposed to the outside world since it is not\n * useful on its own. It is used to generate and lay out the MenuItems that appear either on a\n * top-level menu (in a GridMenu or ContextMenu) or in a submenu.\n */\nexport default function GroupedMenuItemList(menuProps: GroupedMenuItemListProps) {\n const { menuDefinition, onClick, commandHandler, includedGroups } = menuProps;\n\n const { items, allowForLeadingIcons } = useMemo(() => {\n const groupsToInclude =\n includedGroups && includedGroups.length > 0\n ? includedGroups\n : // We're apparently laying out a single-column menu (presumably a context menu). In this\n // case, all groups should be included except ones that belong to a submenu.\n getAllGroups(menuDefinition).filter((g) => !('menuItem' in g.group));\n\n const sortedGroups = Object.values(groupsToInclude).sort(\n (a, b) => (a.group.order || 0) - (b.group.order || 0),\n );\n\n const itemArray: ItemInfo[] = [];\n\n sortedGroups.forEach((group) => {\n getOrderedGroupItems(group.id, menuDefinition.items).forEach((item) =>\n itemArray.push({ item, isLastItemInGroup: false }),\n );\n if (itemArray.length > 0) itemArray[itemArray.length - 1].isLastItemInGroup = true;\n });\n\n // No divider after last item in final group.\n if (itemArray.length > 0) itemArray[itemArray.length - 1].isLastItemInGroup = false;\n\n const allowSpaceForLeadingIcons = itemArray.some(\n (i) => 'iconPathBefore' in i.item && i.item.iconPathBefore,\n );\n\n return { items: itemArray, allowForLeadingIcons: allowSpaceForLeadingIcons };\n }, [includedGroups, menuDefinition]);\n\n // Create props for MenuItem component including setting hasDivider for the last item in a group\n const createMenuItemProps = ({ item, isLastItemInGroup }: ItemInfo) => {\n const menuItemProps = {\n className: 'papi-menu-item',\n label: item.label,\n tooltip: item.tooltip,\n iconPathBefore: 'iconPathBefore' in item ? item.iconPathBefore : undefined,\n iconPathAfter: 'iconPathAfter' in item ? item.iconPathAfter : undefined,\n hasDivider: isLastItemInGroup, // Set hasDivider to true for the last item in a group\n allowForLeadingIcons,\n };\n\n return menuItemProps;\n };\n\n const [firstItem] = items;\n\n if (!firstItem) return
    ;\n\n const divKey = firstItem.item.group;\n\n return (\n
    \n {items.map((itemInfo, index) => {\n const { item } = itemInfo;\n const menuItemProps = createMenuItemProps(itemInfo);\n if ('command' in item) {\n const key = item.group + index;\n return (\n ) => {\n onClick?.(event);\n commandHandler(item);\n }}\n {...menuItemProps}\n />\n );\n }\n return (\n \n );\n })}\n
    \n );\n}\n","import GroupedMenuItemList from '@/components/mui/grouped-menu-item-list.component';\nimport { MenuItemListProps } from '@/components/mui/menu-item.component';\nimport { MultiColumnMenu } from 'platform-bible-utils';\n\n/**\n * This component is internal; it does not need to be exposed to the outside world since it is not\n * useful on its own. Use either GridMenu or ContextMenu.\n */\nexport default function TopLevelMenu(props: MenuItemListProps) {\n const { menuDefinition, columnId } = props;\n\n const groupEntries = Object.entries(menuDefinition.groups);\n // Convert array of entries to array of objects with id and group properties\n const groups = groupEntries.map(([key, value]) => ({ id: key, group: value }));\n let includedGroups = groups.filter((g) => 'column' in g.group);\n\n // Check if column is provided and menuDefinition is a MultiColumnMenu\n if (\n columnId &&\n 'columns' in menuDefinition &&\n // Without this type assertion, TS doesn't know what columns is.\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n (menuDefinition as MultiColumnMenu).columns[columnId]\n ) {\n // When laying out a single column in a MultiColumnMenu, only include groups associated with\n // the provided column. Note: without the (annoying) redundant check that the included groups\n // have the colum field, TS doesn't think it exists.\n includedGroups = includedGroups.filter(\n (g) => 'column' in g.group && g.group.column === columnId,\n );\n }\n\n return ;\n}\n","import '@/components/mui/grid-menu.component.css';\nimport { GroupedMenuPropsBase } from '@/components/mui/grouped-menu-item-list.component';\nimport { CommandHandler } from '@/components/mui/menu-item.component';\nimport TopLevelMenu from '@/components/mui/top-level-menu.component';\nimport { Grid, List } from '@mui/material';\nimport {\n Localized,\n MenuColumnWithHeader,\n MultiColumnMenu,\n ReferencedItem,\n} from 'platform-bible-utils';\nimport { useMemo } from 'react';\n\ntype ColumnInfo = {\n /*\n * The ID (`${string}.${string}`) of a specific menu column.\n */\n id: ReferencedItem;\n\n /*\n * Metadata (label, order, etc.) for a specific menu column.\n */\n metadata: Localized;\n};\n\ntype MenuColumnProps = ColumnInfo &\n GroupedMenuPropsBase & {\n /** Additional css classes to help with unique styling of the menu column */\n className?: string;\n };\n\nexport type GridMenuInfo = {\n /** The menu object containing information about the columns, groups, and items to display. */\n multiColumnMenu: Localized;\n};\n\nexport type GridMenuProps = GridMenuInfo & {\n /** Optional unique identifier */\n id?: string;\n\n commandHandler: CommandHandler;\n\n /** Additional css classes to help with unique styling of the grid menu */\n className?: string;\n};\n\nfunction MenuColumn({\n commandHandler,\n menuDefinition,\n id,\n metadata,\n onClick,\n className,\n}: MenuColumnProps) {\n return (\n \n

    \n {metadata.label}\n

    \n {/* It would seem as though this List component were unnecessary, since it only contains one\n thing, but the \"dense\" property does affect the layout of the items (in a way I don't fully\n understand). There might be a better way. */}\n \n \n \n \n );\n}\n\nexport default function GridMenu({\n commandHandler,\n className,\n multiColumnMenu,\n id,\n}: GridMenuProps) {\n const { columns } = multiColumnMenu;\n\n const sortedColumns = useMemo(() => {\n const columnNumbers = new Map();\n Object.getOwnPropertyNames(columns).forEach((columnName: string) => {\n // We know for sure there is a (boolean) property 'isExtensible' that we are not interested in.\n if (columnName === 'isExtensible') return;\n // TS doesn't allow `columnName` above to be a ReferencedItem even though the type says it is\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const columnId = columnName as ReferencedItem;\n const column = columns[columnId];\n // As of right now (and hopefully forever after), all remaining properties of the\n // ColumnsWithHeaders object are columns whose property names are the IDs of the columns.\n // This is an additional (redundant) sanity check. Specifically we're interested in\n // MenuColumnWithHeader objects, which TypeScript now \"knows\" we have, but at runtime all we\n // can check for is that it's an object with a valid numeric order field. That's likely good\n // enough.\n if (\n typeof column === 'object' &&\n typeof column.order === 'number' &&\n !Number.isNaN(column.order)\n )\n columnNumbers.set(column.order, { id: columnId, metadata: column });\n else\n console.warn(\n `Property ${columnName} (${typeof column}) on menu ${id} is not a valid column and is being ignored. This might indicate data corruption`,\n );\n });\n\n // Extract values and sort them based on the 'order' property\n return Array.from(columnNumbers.values()).sort((a, b) => {\n return (a.metadata.order || 0) - (b.metadata.order || 0);\n });\n }, [columns, id]);\n\n // We might need something like this if we need to be able to prevent empty columns\n // sortedColumns.filter((c) => multiColumnMenu.groups.some((g) => 'column' in g && (g as .column)...\n\n return (\n \n {sortedColumns.map((col, index) => (\n \n ))}\n \n );\n}\n","import { useEffect, useRef, useState } from 'react';\n\nexport type UsePromiseOptions = {\n /**\n * Whether to leave the value as the most recent resolved promise value or set it back to\n * defaultValue while running the promise again. Defaults to true\n */\n preserveValue?: boolean;\n};\n\n/** Set up defaults for options for usePromise hook */\nfunction getUsePromiseOptionsDefaults(options: UsePromiseOptions): UsePromiseOptions {\n return {\n preserveValue: true,\n ...options,\n };\n}\n\n/**\n * Awaits a promise and returns a loading value while the promise is unresolved\n *\n * @param promiseFactoryCallback A function that returns the promise to await. If this callback is\n * undefined, the current value will be returned (defaultValue unless it was previously changed\n * and `options.preserveValue` is true), and there will be no loading.\n *\n * WARNING: MUST BE STABLE - const or wrapped in useCallback. The reference must not be updated\n * every render\n * @param defaultValue The initial value to return while first awaiting the promise. If\n * `options.preserveValue` is false, this value is also shown while awaiting the promise on\n * subsequent calls.\n *\n * Note: this parameter is internally assigned to a `ref`, so changing it will not cause any hooks\n * to re-run with its new value. This means that, if the `promiseFactoryCallback` changes and\n * `options.preserveValue` is `false`, the returned value will be set to the current\n * `defaultValue`. However, the returned value will not be updated if`defaultValue` changes.\n * @param options Various options for adjusting how this hook runs the `promiseFactoryCallback`\n *\n * Note: this parameter is internally assigned to a `ref`, so changing it will not cause any hooks\n * to re-run with its new value. However, the latest `options.preserveValue` will always be used\n * appropriately to determine whether to preserve the returned value when changing the\n * `promiseFactoryCallback`\n * @returns `[value, isLoading]`\n *\n * - `value`: the current value for the promise, either the defaultValue or the resolved promise value\n * - `isLoading`: whether the promise is waiting to be resolved\n */\nconst usePromise = (\n promiseFactoryCallback: (() => Promise) | undefined,\n defaultValue: T,\n options: UsePromiseOptions = {},\n): [value: T, isLoading: boolean] => {\n // Use defaultValue as a ref so it doesn't update dependency arrays\n const defaultValueRef = useRef(defaultValue);\n defaultValueRef.current = defaultValue;\n // Use options as a ref so it doesn't update dependency arrays\n const optionsDefaultedRef = useRef(options);\n optionsDefaultedRef.current = getUsePromiseOptionsDefaults(optionsDefaultedRef.current);\n\n const [value, setValue] = useState(() => defaultValueRef.current);\n const [isLoading, setIsLoading] = useState(true);\n useEffect(() => {\n let promiseIsCurrent = true;\n // If a promiseFactoryCallback was provided, we are loading. Otherwise, there is no loading to do\n setIsLoading(!!promiseFactoryCallback);\n (async () => {\n // If there is a callback to run, run it\n if (promiseFactoryCallback) {\n const result = await promiseFactoryCallback();\n // If the promise was not already replaced, update the value\n if (promiseIsCurrent) {\n setValue(() => result);\n setIsLoading(false);\n }\n }\n })();\n\n return () => {\n // Mark this promise as old and not to be used\n promiseIsCurrent = false;\n if (!optionsDefaultedRef.current.preserveValue) setValue(() => defaultValueRef.current);\n };\n }, [promiseFactoryCallback]);\n\n return [value, isLoading];\n};\nexport default usePromise;\n","\"use client\";\n\nimport createSvgIcon from './utils/createSvgIcon';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nexport default createSvgIcon( /*#__PURE__*/_jsx(\"path\", {\n d: \"M3 18h18v-2H3zm0-5h18v-2H3zm0-7v2h18V6z\"\n}), 'Menu');","import GridMenu from '@/components/mui/grid-menu.component';\nimport { Command, CommandHandler } from '@/components/mui/menu-item.component';\nimport usePromise from '@/hooks/use-promise.hook';\nimport { Menu as MenuIcon } from '@mui/icons-material';\nimport { Drawer, IconButton } from '@mui/material';\nimport { Localized, MultiColumnMenu } from 'platform-bible-utils';\nimport {\n MouseEvent,\n MutableRefObject,\n PropsWithChildren,\n useCallback,\n useEffect,\n useState,\n} from 'react';\n\nexport interface MultiColumnMenuProvider {\n (isSupportAndDevelopment: boolean): Promise>;\n}\n\nexport type HamburgerMenuButtonProps = PropsWithChildren & {\n /** The handler to use for menu commands (and eventually toolbar commands). */\n commandHandler: CommandHandler;\n\n /**\n * Optional reference to the \"div\" container that determines the where the menu should appear. If\n * not defined, then (1,1) used.\n */\n containerRef?: MutableRefObject;\n\n /**\n * The delegate to use to get the menu data. If not specified or if it returns undefined, the data\n * in normalMenu or fullMenu property will be used.\n */\n menuProvider?: MultiColumnMenuProvider;\n\n /**\n * The menu data to show when the menu is opened if the menuProvider property is not defined.\n * (This allows for a default or test-only static menu to be used.)\n */\n normalMenu?: Localized;\n\n /**\n * The menu data to show for \"full\" menu (when opened with the SHIFT key pressed) if the\n * menuProvider property is not defined. (This allows for a default or test-only static menu to be\n * used.)\n */\n fullMenu?: Localized;\n\n /** Additional css class(es) to help with unique styling of the sub-components */\n className?: string;\n\n /** Value to use as prefix for ARIA labels on interactive sub-components */\n ariaLabelPrefix?: string;\n};\n\nexport default function HamburgerMenuButton({\n menuProvider,\n normalMenu,\n fullMenu,\n commandHandler,\n containerRef,\n className,\n ariaLabelPrefix,\n children,\n}: HamburgerMenuButtonProps) {\n const [isMenuOpen, setMenuOpen] = useState(false);\n const [showFullMenu, setShowFullMenu] = useState(false);\n\n const handleMenuItemClick = useCallback(() => {\n if (isMenuOpen) setMenuOpen(false);\n setShowFullMenu(false);\n }, [isMenuOpen]);\n\n const handleMenuButtonClick = useCallback((e: MouseEvent) => {\n e.stopPropagation();\n setMenuOpen((prevIsOpen) => {\n const isOpening = !prevIsOpen;\n if (isOpening && e.shiftKey) setShowFullMenu(true);\n else if (!isOpening) setShowFullMenu(false);\n return isOpening;\n });\n }, []);\n\n const menuCommandHandler = useCallback(\n (command: Command) => {\n handleMenuItemClick();\n return commandHandler(command);\n },\n [commandHandler, handleMenuItemClick],\n );\n\n const [offset, setOffset] = useState({ top: 1, left: 1 });\n\n useEffect(() => {\n if (isMenuOpen) {\n const node = containerRef?.current;\n if (node) {\n const rect = node.getBoundingClientRect();\n const scrollTop = window.scrollY;\n const scrollLeft = window.scrollX;\n const top = rect.top + scrollTop + node.clientHeight;\n const left = rect.left + scrollLeft;\n setOffset({ top, left });\n }\n }\n }, [isMenuOpen, containerRef]);\n\n const [normalMenuData] = usePromise(\n useCallback(async () => {\n return menuProvider?.(false) ?? normalMenu;\n // isMenuOpen needs to be included for the menu contents to reevaluate when reopened\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [menuProvider, normalMenu, isMenuOpen]),\n normalMenu,\n );\n\n const [fullMenuData] = usePromise(\n useCallback(async () => {\n return menuProvider?.(true) ?? fullMenu ?? normalMenuData;\n // isMenuOpen needs to be included for the menu contents to reevaluate when reopened\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [menuProvider, fullMenu, normalMenuData, isMenuOpen]),\n fullMenu ?? normalMenuData,\n );\n\n const menu = showFullMenu && fullMenuData ? fullMenuData : normalMenuData;\n\n return (\n <>\n \n {children ?? }\n \n \n {menu ? (\n \n ) : undefined}\n \n \n );\n}\n","import '@/components/mui/icon-button.component.css';\nimport { IconButton as MuiIconButton } from '@mui/material';\nimport { MouseEventHandler, PropsWithChildren } from 'react';\n\nexport type IconButtonProps = PropsWithChildren<{\n /** Optional unique identifier */\n id?: string;\n /**\n * Required. Used as both the tooltip (aka, title) and the aria-label (used for accessibility,\n * testing, etc.), unless a distinct tooltip is supplied.\n */\n label: string;\n /**\n * Enabled status of button\n *\n * @default false\n */\n isDisabled?: boolean;\n /** Optional tooltip to display if different from the aria-label. */\n tooltip?: string;\n /** If true, no tooltip will be displayed. */\n isTooltipSuppressed?: boolean;\n /**\n * If given, uses a negative margin to counteract the padding on one side (this is often helpful\n * for aligning the left or right side of the icon with content above or below, without ruining\n * the border size and shape).\n *\n * @default false\n */\n adjustMarginToAlignToEdge?: 'end' | 'start' | false;\n /**\n * The size of the component. small is equivalent to the dense button styling.\n *\n * @default false\n */\n size: 'small' | 'medium' | 'large';\n /** Additional css classes to help with unique styling of the button */\n className?: string;\n /** Optional click handler */\n onClick?: MouseEventHandler;\n}>;\n\n/**\n * Iconic button a user can click to do something\n *\n * Thanks to MUI for heavy inspiration and documentation\n * https://mui.com/material-ui/getting-started/overview/\n */\nfunction IconButton({\n id,\n label,\n isDisabled = false,\n tooltip,\n isTooltipSuppressed = false,\n adjustMarginToAlignToEdge = false,\n size = 'medium',\n className,\n onClick,\n children,\n}: IconButtonProps) {\n return (\n \n {children /* the icon to display */}\n \n );\n}\n\nexport default IconButton;\n","import { cn } from '@/utils/shadcn-ui.util';\nimport { LoaderCircle, LucideProps } from 'lucide-react';\nimport { forwardRef } from 'react';\n\nexport type SpinnerProps = LucideProps;\n\nconst Spinner = forwardRef(({ className, ...props }, ref) => {\n return (\n \n );\n});\n\nSpinner.displayName = 'Spinner';\n\nexport default Spinner;\n","import { Input as ShadInput } from '@/components/shadcn-ui/input';\nimport { Label as ShadLabel } from '@/components/shadcn-ui/label';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { ChangeEventHandler, FocusEventHandler } from 'react';\n\nexport type TextFieldProps = {\n /** Optional unique identifier */\n id?: string;\n /**\n * If `true`, the component is disabled.\n *\n * @default false\n */\n isDisabled?: boolean;\n /**\n * If `true`, the label is displayed in an error state.\n *\n * @default false\n */\n hasError?: boolean;\n /**\n * If `true`, the input will take up the full width of its container.\n *\n * @default false\n */\n isFullWidth?: boolean;\n /** Text that gives the user instructions on what contents the TextField expects */\n helperText?: string;\n /** The title of the TextField */\n label?: string;\n /** The short hint displayed in the `input` before the user enters a value. */\n placeholder?: string;\n /**\n * If `true`, the label is displayed as required and the `input` element is required.\n *\n * @default false\n */\n isRequired?: boolean;\n /** Additional css classes to help with unique styling of the text field */\n className?: string;\n /** Starting value for the text field if it is not controlled */\n defaultValue?: string | number;\n /** Value of the text field if controlled */\n value?: string | number;\n /** Triggers when content of textfield is changed */\n onChange?: ChangeEventHandler;\n /** Triggers when textfield gets focus */\n onFocus?: FocusEventHandler;\n /** Triggers when textfield loses focus */\n onBlur?: FocusEventHandler;\n};\n\n/**\n * Text input field\n *\n * Thanks to Shadcn for heavy inspiration and documentation\n * https://ui.shadcn.com/docs/components/input#with-label\n */\nfunction TextField({\n id,\n isDisabled = false,\n hasError = false,\n isFullWidth = false,\n helperText,\n label,\n placeholder,\n isRequired = false,\n className,\n defaultValue,\n value,\n onChange,\n onFocus,\n onBlur,\n}: TextFieldProps) {\n return (\n
    \n {`${label}${isRequired ? '*' : ''}`}\n \n

    {helperText}

    \n
    \n );\n}\n\nexport default TextField;\n","import HamburgerMenuButton, {\n MultiColumnMenuProvider,\n} from '@/components/mui/hamburger-menu-button.component';\nimport { CommandHandler } from '@/components/mui/menu-item.component';\nimport '@/components/mui/toolbar.component.css';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { AppBar, Toolbar as MuiToolbar } from '@mui/material';\nimport { PropsWithChildren, useRef } from 'react';\n\nexport type ToolbarProps = PropsWithChildren<{\n /** The handler to use for menu commands (and eventually toolbar commands). */\n commandHandler: CommandHandler;\n\n /**\n * The optional delegate to use to get the menu data. If not specified, the \"hamburger\" menu will\n * not display.\n */\n menuProvider?: MultiColumnMenuProvider;\n\n /** Optional unique identifier */\n id?: string;\n\n /** Additional css classes to help with unique styling of the toolbar */\n className?: string;\n}>;\n\nexport default function Toolbar({\n menuProvider,\n commandHandler,\n className,\n id,\n children,\n}: ToolbarProps) {\n // This ref will always be defined\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const containerRef = useRef(undefined!);\n\n return (\n
    \n \n \n {menuProvider ? (\n \n ) : undefined}\n {children ?
    {children}
    : undefined}\n \n
    \n
    \n );\n}\n","import React from 'react';\nimport { cva, type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst alertVariants = cva(\n 'tw-relative tw-w-full tw-rounded-lg tw-border tw-p-4 [&>svg~*]:tw-pl-7 [&>svg+div]:tw-translate-y-[-3px] [&>svg]:tw-absolute [&>svg]:tw-left-4 [&>svg]:tw-top-4 [&>svg]:tw-text-foreground',\n {\n variants: {\n variant: {\n default: 'tw-bg-background tw-text-foreground',\n destructive:\n 'tw-border-destructive/50 tw-text-destructive dark:tw-border-destructive [&>svg]:tw-text-destructive',\n },\n },\n defaultVariants: {\n variant: 'default',\n },\n },\n);\n\nconst Alert = React.forwardRef<\n HTMLDivElement,\n React.HTMLAttributes & VariantProps\n>(({ className, variant, ...props }, ref) => (\n
    \n));\nAlert.displayName = 'Alert';\n\nconst AlertTitle = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n {/* added because of https://github.com/jsx-eslint/eslint-plugin-jsx-a11y/blob/main/docs/rules/heading-has-content.md */}\n {props.children}{' '}\n \n ),\n);\nAlertTitle.displayName = 'AlertTitle';\n\nconst AlertDescription = React.forwardRef<\n HTMLParagraphElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n
    \n));\nAlertDescription.displayName = 'AlertDescription';\n\nexport { Alert, AlertTitle, AlertDescription };\n","import React from 'react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Card = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nCard.displayName = 'Card';\n\nconst CardHeader = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nCardHeader.displayName = 'CardHeader';\n\nconst CardTitle = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n {/* added because of https://github.com/jsx-eslint/eslint-plugin-jsx-a11y/blob/main/docs/rules/heading-has-content.md */}\n {props.children}\n \n ),\n);\nCardTitle.displayName = 'CardTitle';\n\nconst CardDescription = React.forwardRef<\n HTMLParagraphElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n

    \n));\nCardDescription.displayName = 'CardDescription';\n\nconst CardContent = React.forwardRef>(\n ({ className, ...props }, ref) => (\n

    \n ),\n);\nCardContent.displayName = 'CardContent';\n\nconst CardFooter = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nCardFooter.displayName = 'CardFooter';\n\nexport { Card, CardHeader, CardFooter, CardTitle, CardDescription, CardContent };\n","import { ComponentProps } from 'react';\nimport { toast as sonner, Toaster } from 'sonner';\n\ntype SonnerProps = ComponentProps;\n\nfunction Sonner({ ...props }: SonnerProps) {\n return (\n \n );\n}\n\n// The re-export of the sonner function was added manually\nexport { Sonner, sonner };\n","import React from 'react';\nimport * as SliderPrimitive from '@radix-ui/react-slider';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Slider = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n \n \n \n));\nSlider.displayName = SliderPrimitive.Root.displayName;\n\nexport { Slider };\n","import React from 'react';\nimport * as SwitchPrimitives from '@radix-ui/react-switch';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Switch = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n));\nSwitch.displayName = SwitchPrimitives.Root.displayName;\n\nexport { Switch };\n","import React from 'react';\nimport * as TabsPrimitive from '@radix-ui/react-tabs';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport const Tabs = TabsPrimitive.Root;\n\nexport type TabsListProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport type TabsTriggerProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport type TabsContentProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport const TabsList = React.forwardRef<\n React.ElementRef,\n TabsListProps\n>(({ className, ...props }, ref) => (\n \n));\nTabsList.displayName = TabsPrimitive.List.displayName;\n\nexport const TabsTrigger = React.forwardRef<\n React.ElementRef,\n TabsTriggerProps\n>(({ className, ...props }, ref) => (\n \n));\nTabsTrigger.displayName = TabsPrimitive.Trigger.displayName;\n\nexport const TabsContent = React.forwardRef<\n React.ElementRef,\n TabsContentProps\n>(({ className, ...props }, ref) => (\n \n));\nTabsContent.displayName = TabsPrimitive.Content.displayName;\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Download } from 'lucide-react';\n\ntype InstallButtonProps = {\n /** The installing boolean value determines the state of the button. */\n isInstalling: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n /** Optional text for the button. */\n buttonText?: string;\n} & ButtonProps;\n\n/**\n * The InstallButton component is a button designed for initiating installs. It includes visuals for\n * active installing and idle states.\n *\n * @param isInstalling The installing boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @param buttonText Optional text for the button.\n * @returns A install button.\n */\nexport default function InstallButton({\n isInstalling,\n handleClick,\n buttonText,\n className,\n ...props\n}: InstallButtonProps) {\n return (\n \n {isInstalling ? (\n \n ) : (\n <>\n \n {buttonText}\n \n )}\n \n );\n}\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\n\ntype EnableButtonProps = {\n /** The enabling boolean value determines the state of the button. */\n isEnabling: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n} & ButtonProps;\n\n/**\n * The EnableButton component is a button designed for initiating enabling of downloads. It includes\n * visuals for active enabling and idle states.\n *\n * @param isEnabling The enabling boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @returns A button that can be used to enable.\n */\nexport default function EnableButton({\n isEnabling,\n handleClick,\n className,\n ...props\n}: EnableButtonProps) {\n return (\n \n {isEnabling ? (\n <>\n \n Enabling...\n \n ) : (\n 'Enable'\n )}\n \n );\n}\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\n\ntype DisableButtonProps = {\n /** The disabling boolean value determines the state of the button. */\n isDisabling: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n} & ButtonProps;\n\n/**\n * The DisableButton component is a button designed for initiating disabling of downloads. It\n * includes visuals for active disabling and idle states.\n *\n * @param isDisabling The disabling boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @returns A button that can be used to disable.\n */\nexport default function DisableButton({\n isDisabling,\n handleClick,\n className,\n ...props\n}: DisableButtonProps) {\n return (\n \n {isDisabling ? (\n <>\n \n Disabling...\n \n ) : (\n 'Disable'\n )}\n \n );\n}\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\n\ntype UpdateButtonProps = {\n /** The updating boolean value determines the state of the button. */\n isUpdating: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n} & ButtonProps;\n\n/**\n * The UpdateButton component is a button designed for initiating updates for downloaded extensions.\n * It includes visuals for active updating and idle states.\n *\n * @param isUpdating The updating boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @returns A button that can be used to update.\n */\nexport default function UpdateButton({\n isUpdating,\n handleClick,\n className,\n ...props\n}: UpdateButtonProps) {\n return (\n \n {isUpdating ? (\n <>\n \n Updating...\n \n ) : (\n 'Update'\n )}\n \n );\n}\n","import { cn } from '@/utils/shadcn-ui.util';\nimport Markdown, { MarkdownToJSX } from 'markdown-to-jsx';\nimport { useMemo } from 'react';\n\ninterface MarkdownRendererProps {\n /** Optional unique identifier */\n id?: string;\n /** The markdown string to render */\n markdown: string;\n className?: string;\n /**\n * The [`target` attribute for `a` html\n * tags](https://developer.mozilla.org/en-US/docs/Web/HTML/Element/a#target). Defaults to not\n * adding a `target` to `a` tags\n */\n anchorTarget?: string;\n}\n\n/**\n * This component renders markdown content given a markdown string. It uses typography styles from\n * the platform.\n *\n * @param markdown The markdown string to render.\n * @param id Optional unique identifier\n * @returns A div containing the rendered markdown content.\n */\nexport default function MarkdownRenderer({\n id,\n markdown,\n className,\n anchorTarget,\n}: MarkdownRendererProps) {\n const options: MarkdownToJSX.Options = useMemo(\n () => ({\n overrides: {\n a: {\n props: {\n target: anchorTarget,\n },\n },\n },\n }),\n [anchorTarget],\n );\n return (\n
    \n {markdown}\n
    \n );\n}\n","import { Filter, ChevronDown } from 'lucide-react';\nimport { forwardRef } from 'react';\nimport { Button } from '@/components/shadcn-ui/button';\n\n/**\n * The FilterButton component is a button designed for initiating filtering of data. It is designed\n * to be used with the dropdown menu. It uses forwardRef to pass the button to the dropdown trigger\n * asChild.\n *\n * @returns A button that can be used to filter.\n */\nconst FilterButton = forwardRef((props, ref) => {\n return (\n \n \n Filter\n \n \n );\n});\n\nexport default FilterButton;\n","import {\n DropdownMenu,\n DropdownMenuTrigger,\n DropdownMenuContent,\n DropdownMenuLabel,\n DropdownMenuGroup,\n DropdownMenuCheckboxItem,\n DropdownMenuRadioItem,\n DropdownMenuSeparator,\n} from '@/components/shadcn-ui/dropdown-menu';\nimport FilterButton from './buttons/filter-button.component';\n\nexport enum DropdownMenuItemType {\n Check,\n Radio,\n}\n\nexport type DropdownItem = {\n /** The label is the text that will be displayed on the dropdown item. */\n label: string;\n /** The itemType determines the DropdownMenuItemType type as either Check or Radio. */\n itemType: DropdownMenuItemType;\n /** The onClick function is called when the item is clicked. */\n onClick: () => void;\n};\n\nexport type DropdownGroup = {\n /**\n * The label is the text that will be displayed on the dropdown group. It is used to categorize\n * the items in the group.\n */\n label: string;\n /** The items array contains the items that will be displayed in the dropdown group */\n items: DropdownItem[];\n};\n\nexport type FilterDropdownProps = {\n /** Object unique identifier */\n id?: string;\n /** The groups array contains the groups that will be displayed in the dropdown */\n groups: DropdownGroup[];\n}; // TODO: extend the props later\n\n/**\n * The FilterDropdown component is a dropdown designed for filtering content. It includes groups of\n * items that can be checkboxes or radio items.\n *\n * @param id Optional unique identifier\n * @param groups The groups array contains the groups that will be displayed in the dropdown\n * @returns A filter dropdown.\n */\nexport default function FilterDropdown({ id, groups }: FilterDropdownProps) {\n return (\n
    \n {/* TODO: remove this once the DropDown Menu shadcn has an id prop */}\n \n \n \n \n \n {groups.map((group) => (\n
    \n {group.label}\n \n {group.items.map((item) => (\n
    \n {item.itemType === DropdownMenuItemType.Check ? (\n \n {item.label}\n \n ) : (\n \n {item.label}\n \n )}\n
    \n ))}\n
    \n \n
    \n ))}\n
    \n
    \n
    \n );\n}\n","interface NoExtensionsFoundProps {\n /** Optional unique identifier */\n id?: string;\n /** The message to display */\n message: string;\n}\n/**\n * This component displays a message to the user when no extensions are found in the marketplace.\n *\n * @param id Optional unique identifier\n * @param message The message to display.\n * @returns {JSX.Element} - Returns the message component that displays the message to the user.\n */\nexport default function NoExtensionsFound({ id, message }: NoExtensionsFoundProps) {\n return (\n
    \n
    \n

    {message}

    \n
    \n
    \n );\n}\n","import { CircleHelp, Link as LucideLink, User } from 'lucide-react';\nimport { NumberFormat } from 'platform-bible-utils';\n\n/** Interface that stores the parameters passed to the More Info component */\ninterface MoreInfoProps {\n /** Optional unique identifier */\n id?: string;\n /** The category of the extension */\n category: string;\n /** The number of downloads for the extension */\n downloads: Record;\n /** The languages supported by the extension */\n languages: string[];\n /** The URL to the more info page of the extension */\n moreInfoUrl: string;\n}\n/**\n * This component displays the more info section of the extension which includes the category,\n * number of downloads, languages, and links to the website and support\n *\n * @param id Optional unique identifier\n * @param category The category of the extension\n * @param downloads The number of downloads for the extension\n * @param languages The languages supported by the extension\n * @param moreInfoUrl The URL to the more info page of the extension\n * @returns {JSX.Element} - Returns the more info component that displays the category, number of\n * downloads, languages, and links to the website and support\n */\nexport default function MoreInfo({\n id,\n category,\n downloads,\n languages,\n moreInfoUrl,\n}: MoreInfoProps) {\n /**\n * This constant formats the number of downloads into a more readable format.\n *\n * @example 1000 -> 1K\n *\n * @example 1000000 -> 1M\n *\n * @returns The formatted number of downloads\n */\n const numberFormatted = new NumberFormat('en', {\n notation: 'compact',\n compactDisplay: 'short',\n }).format(Object.values(downloads).reduce((a: number, b: number) => a + b, 0));\n\n /** This function scrolls the window to the bottom of the page. */\n const handleScrollToBottom = () => {\n window.scrollTo(0, document.body.scrollHeight);\n };\n\n return (\n \n
    \n
    \n {category}\n
    \n CATEGORY\n
    \n
    \n
    \n
    \n \n {numberFormatted}\n
    \n USERS\n
    \n
    \n
    \n
    \n {languages.slice(0, 3).map((locale) => (\n \n {locale.toUpperCase()}\n \n ))}\n
    \n {languages.length > 3 && (\n handleScrollToBottom()}\n className=\"tw-text-xs tw-text-gray-500 tw-underline\"\n >\n +{languages.length - 3} more languages\n \n )}\n
    \n
    \n
    \n \n Website\n \n \n \n Support\n \n \n
    \n
    \n );\n}\n","import { useState } from 'react';\n\nexport type VersionInformation = {\n /** Date the version was published */\n date: string;\n /** Description of the changes in the version */\n description: string;\n};\n\n/** Type to store the version history information */\nexport type VersionHistoryType = Record;\n\n/** Interface that stores the parameters passed to the Version History component */\ninterface VersionHistoryProps {\n /** Optional unique identifier */\n id?: string;\n /** Object containing the versions mapped with their information */\n versionHistory: VersionHistoryType;\n}\n\n/**\n * Component to render the version history information shown in the footer component. Lists the 5\n * most recent versions, with the options to show all versions by pressing a button.\n *\n * @param versionHistory Object containing the versions mapped with their information\n * @param id Optional unique identifier\n * @returns Rendered version history for the Footer component\n */\nexport default function VersionHistory({ id, versionHistory }: VersionHistoryProps) {\n const [showAllVersions, setShowAllVersions] = useState(false);\n const currentDate = new Date();\n\n /**\n * Function to format the time string for the version history in the form of 'X year(s) ago'.\n *\n * @param dateString ISO Date string to determine the time string from\n * @returns Formatted time string\n */\n function formatTimeString(dateString: string) {\n const date = new Date(dateString);\n const dateDiff = new Date(currentDate.getTime() - date.getTime());\n const yearDiff = dateDiff.getUTCFullYear() - 1970;\n const monthDiff = dateDiff.getUTCMonth();\n const dayDiff = dateDiff.getUTCDate() - 1;\n\n // Determines how long ago the version was published\n let timeString = '';\n if (yearDiff > 0) {\n timeString = `${yearDiff.toString()} year${yearDiff === 1 ? '' : 's'} ago`;\n } else if (monthDiff > 0) {\n timeString = `${monthDiff.toString()} month${monthDiff === 1 ? '' : 's'} ago`;\n } else if (dayDiff === 0) {\n timeString = 'today';\n } else {\n timeString = `${dayDiff.toString()} day${dayDiff === 1 ? '' : 's'} ago`;\n }\n\n return timeString;\n }\n\n // Sorts the version history by version number\n const sortedEntries = Object.entries(versionHistory).sort((a, b) => b[0].localeCompare(a[0]));\n\n return (\n
    \n

    What`s New

    \n
      \n {(showAllVersions ? sortedEntries : sortedEntries.slice(0, 5)).map((entry) => (\n
      \n
      \n
    • \n {entry[1].description}\n
    • \n
      \n
      \n
      Version {entry[0]}
      \n
      {formatTimeString(entry[1].date)}
      \n
      \n
      \n ))}\n
    \n {sortedEntries.length > 5 && (\n setShowAllVersions(!showAllVersions)}\n className=\"tw-text-xs tw-text-gray-500 tw-underline\"\n >\n {showAllVersions ? 'Show Less Version History' : 'Show All Version History'}\n \n )}\n
    \n );\n}\n","import { useMemo } from 'react';\nimport { formatBytes } from 'platform-bible-utils';\nimport VersionHistory, { VersionHistoryType } from './version-history.component';\n\n/** Interface to store the parameters passed to the Footer component */\ninterface FooterProps {\n /** Optional unique identifier */\n id?: string;\n /** Name of the publisher */\n publisherDisplayName: string;\n /** Size of the extension file in bytes */\n fileSize: number;\n /** List of language codes supported by the extension */\n locales: string[];\n /** Object containing the version history mapped with their information */\n versionHistory: VersionHistoryType;\n}\n\n/**\n * Component to render the footer for the extension details which contains information on the\n * publisher, version history, languages, and file size.\n *\n * @param id Optional unique identifier\n * @param publisherDisplayName Name of the publisher\n * @param fileSize Size of the extension file in bytes\n * @param locales List of language codes supported by the extension\n * @param versionHistory Object containing the version history mapped with their information\n * @returns The rendered Footer component\n */\nexport default function Footer({\n id,\n publisherDisplayName,\n fileSize,\n locales,\n versionHistory,\n}: FooterProps) {\n /** Formats the file size into a human-readable format */\n const formattedFileSize = useMemo(() => formatBytes(fileSize), [fileSize]);\n\n /**\n * This function gets the display names of the languages based on the language codes.\n *\n * @param codes The list of language codes\n * @returns The list of language names\n */\n const getLanguageNames = (codes: string[]) => {\n const displayNames = new Intl.DisplayNames(navigator.language, { type: 'language' });\n return codes.map((code) => displayNames.of(code));\n };\n\n const languageNames = getLanguageNames(locales);\n\n return (\n
    \n
    \n \n
    \n
    \n

    Information

    \n
    \n

    \n Publisher\n {publisherDisplayName}\n Size\n {formattedFileSize}\n

    \n
    \n

    \n Languages\n {languageNames.join(', ')}\n

    \n
    \n
    \n
    \n
    \n
    \n );\n}\n","import { PlatformEvent, PlatformEventHandler } from 'platform-bible-utils';\nimport { useEffect } from 'react';\n\n/**\n * Adds an event handler to an event so the event handler runs when the event is emitted. Use\n * `papi.network.getNetworkEvent` to use a networked event with this hook.\n *\n * @param event The event to subscribe to.\n *\n * - If event is a `PlatformEvent`, that event will be used\n * - If event is undefined, the callback will not be subscribed. Useful if the event is not yet\n * available for example\n *\n * @param eventHandler The callback to run when the event is emitted\n *\n * WARNING: MUST BE STABLE - const or wrapped in useCallback. The reference must not be updated\n * every render\n */\nconst useEvent = (\n event: PlatformEvent | undefined,\n eventHandler: PlatformEventHandler,\n) => {\n useEffect(() => {\n // Do nothing if the event is not provided (in case the event is not yet available, for example)\n if (!event) return () => {};\n\n const unsubscriber = event(eventHandler);\n return () => {\n unsubscriber();\n };\n }, [event, eventHandler]);\n};\nexport default useEvent;\n","import { useCallback, useEffect } from 'react';\nimport { PlatformEvent, PlatformEventAsync, PlatformEventHandler } from 'platform-bible-utils';\nimport usePromise from './use-promise.hook';\n\nconst noopUnsubscriber = () => false;\n\n/**\n * Adds an event handler to an asynchronously subscribing/unsubscribing event so the event handler\n * runs when the event is emitted. Use `papi.network.getNetworkEvent` to use a networked event with\n * this hook.\n *\n * @param event The asynchronously (un)subscribing event to subscribe to.\n *\n * - If event is a `PlatformEvent` or `PlatformEventAsync`, that event will be used\n * - If event is undefined, the callback will not be subscribed. Useful if the event is not yet\n * available for example\n *\n * @param eventHandler The callback to run when the event is emitted\n *\n * WARNING: MUST BE STABLE - const or wrapped in useCallback. The reference must not be updated\n * every render\n */\nconst useEventAsync = (\n event: PlatformEvent | PlatformEventAsync | undefined,\n eventHandler: PlatformEventHandler,\n) => {\n // Subscribe to the event asynchronously\n const [unsubscribe] = usePromise(\n useCallback(async () => {\n // Do nothing if the event is not provided (in case the event is not yet available, for example)\n if (!event) return noopUnsubscriber;\n\n // Wrap subscribe and unsubscribe in promises to allow normal events to be used as well\n const unsub = await Promise.resolve(event(eventHandler));\n return async () => unsub();\n }, [eventHandler, event]),\n noopUnsubscriber,\n // We want the unsubscriber to return to default value immediately upon changing subscription\n // So the useEffect below will unsubscribe asap\n { preserveValue: false },\n );\n\n // Unsubscribe from the event asynchronously (but we aren't awaiting the unsub)\n useEffect(() => {\n return () => {\n if (unsubscribe !== noopUnsubscriber) {\n unsubscribe();\n }\n };\n }, [unsubscribe]);\n};\n\nexport default useEventAsync;\n"],"names":["twMergeCustom","extendTailwindMerge","cn","inputs","clsx","Input","React","className","type","props","ref","jsx","BookChapterInput","forwardRef","handleSearch","handleKeyDown","handleOnClick","handleSubmit","jsxs","ShadInput","event","e","History","P","R","s","n","N","B","O","S","K","g","k","x","T","X","V","w","L","G","A","H","C","I","y","q","U","m","l","h","c","E","D","i","a","o","u","v","f","d","b","J","DropdownMenu","DropdownMenuPrimitive","DropdownMenuTrigger","DropdownMenuGroup","DropdownMenuPortal","DropdownMenuSub","DropdownMenuRadioGroup","DropdownMenuSubTrigger","inset","children","ChevronRight","DropdownMenuSubContent","DropdownMenuContent","sideOffset","DropdownMenuItem","DropdownMenuCheckboxItem","checked","Check","DropdownMenuRadioItem","Circle","DropdownMenuLabel","DropdownMenuSeparator","DropdownMenuShortcut","BookMenuItem","bookId","handleSelectBook","isSelected","handleHighlightBook","bookType","ShadDropdownMenuItem","Canon","ChapterSelect","handleSelectChapter","endChapter","activeChapter","highlightedChapter","handleHighlightedChapter","chapters","_","handleMouse","useCallback","chapterNumber","chapter","GoToMenuItem","handleSort","handleLocationHistory","handleBookmarks","ShadDropdownMenuLabel","ArrowDownWideNarrow","Clock","Bookmark","ALL_BOOK_IDS","BOOK_TYPE_LABELS","BOOK_TYPE_ARRAY","SCROLL_OFFSET","SEARCH_QUERY_FORMATS","fetchGroupedBooks","fetchEndChapter","getChaptersForBook","getAllEnglishNames","isValidBookEnglishName","bookName","getBookIdFromEnglishName","formattedBookName","BookChapterControl","scrRef","searchQuery","setSearchQuery","useState","selectedBookId","setSelectedBookId","setHighlightedChapter","highlightedBookId","setHighlightedBookId","isContentOpen","setIsContentOpen","isContentOpenDelayed","setIsContentOpenDelayed","inputRef","useRef","contentRef","menuItemRef","fetchFilteredBooks","englishNameLowerCase","normalizedQuery","handleSearchInput","searchString","shouldPreventAutoClosing","controlMenuState","open","updateReference","shouldClose","verse","handleInputSubmit","format","matches","book","englishName","handleKeyDownInput","handleKeyDownContent","key","handleKeyDownMenuItem","chapterOffSet","useEffect","useLayoutEffect","scrollTimeout","scrollPosition","ShadDropdownMenu","ShadDropdownMenuTrigger","ShadDropdownMenuContent","bookTypeIndex","element","ShadDropdownMenuSeparator","buttonVariants","cva","Button","variant","size","asChild","Slot","labelVariants","Label","LabelPrimitive","RadioGroup","RadioGroupPrimitive","RadioGroupItem","Popover","PopoverPrimitive","PopoverTrigger","PopoverContent","align","DialogPortal","DialogPrimitive","DialogOverlay","DialogContent","DialogTitle","DialogDescription","Command","CommandPrimitive","CommandInput","Search","CommandList","CommandEmpty","CommandGroup","CommandSeparator","CommandItem","getOptionLabelDefault","option","ComboBox","id","options","buttonClassName","popoverContentClassName","value","onChange","getOptionLabel","buttonPlaceholder","textPlaceholder","commandEmptyMessage","buttonVariant","dir","isDisabled","setOpen","ChevronsUpDown","ChapterRangeSelector","startChapter","handleSelectStartChapter","handleSelectEndChapter","chapterCount","chapterOptions","useMemo","index","Fragment","BookSelectionMode","BOOK_SELECTOR_STRING_KEYS","localizeString","strings","BookSelector","handleBookSelectionModeChange","currentBookName","onSelectBooks","selectedBookIds","localizedStrings","currentBookText","chooseText","chooseBooksText","bookSelectionMode","setBookSelectionMode","onSelectionModeChange","newMode","DataTableViewOptions","table","FilterIcon","column","Select","SelectPrimitive","SelectGroup","SelectValue","SelectTrigger","ChevronDown","SelectScrollUpButton","ChevronUp","SelectScrollDownButton","SelectContent","position","SelectLabel","SelectItem","SelectSeparator","DataTablePagination","pageSize","ArrowLeftIcon","ChevronLeftIcon","ChevronRightIcon","ArrowRightIcon","Table","stickyHeader","TableHeader","TableBody","TableFooter","TableRow","TableHead","TableCell","TableCaption","DataTable","columns","data","enablePagination","showPaginationControls","showColumnVisibilityControls","onRowClickHandler","sorting","setSorting","columnFilters","setColumnFilters","columnVisibility","setColumnVisibility","rowSelection","setRowSelection","useReactTable","getCoreRowModel","getPaginationRowModel","getSortedRowModel","getFilteredRowModel","headerGroup","header","flexRender","_a","row","cell","OccurrencesTable","occurrenceData","setScriptureReference","referenceHeaderText","occurrenceHeaderText","occurrences","uniqueOccurrences","occurrence","uniqueOccurrence","deepEqual","Checkbox","CheckboxPrimitive","getLinesFromUSFM","text","getNumberFromUSFM","regex","match","getBookNumFromId","getStatusForItem","item","approvedItems","unapprovedItems","toggleVariants","Toggle","TogglePrimitive","ToggleGroupContext","ToggleGroup","ToggleGroupPrimitive","ToggleGroupItem","context","getSortingIcon","sortDirection","ArrowUpIcon","ArrowDownIcon","ArrowUpDownIcon","inventoryItemColumn","itemLabel","inventoryAdditionalItemColumn","additionalItemLabel","additionalItemIndex","inventoryCountColumn","countLabel","statusChangeHandler","changedItems","newStatus","onApprovedItemsChange","onUnapprovedItemsChange","newApprovedItems","validItem","newUnapprovedItems","unapprovedItem","inventoryStatusColumn","statusLabel","status","CircleCheckIcon","CircleXIcon","CircleHelpIcon","INVENTORY_STRING_KEYS","filterItemData","itemData","statusFilter","textFilter","filteredItemData","createTableData","scriptureRef","itemRegex","tableData","currentBook","currentChapter","currentVerse","line","items","itemIndex","existingItem","tableEntry","newReference","substring","newItem","Inventory","scriptureReference","extractItems","additionalItemsLabels","scope","onScopeChange","allItemsText","approvedItemsText","unapprovedItemsText","unknownItemsText","scopeBookText","scopeChapterText","scopeVerseText","filterText","showAdditionalItemsText","showAdditionalItems","setShowAdditionalItems","setStatusFilter","setTextFilter","selectedItem","setSelectedItem","reducedTableData","newTableData","firstItem","existingEntry","newTableEntry","filteredTableData","allColumns","numberOfAdditionalItems","additionalColumns","_b","rowClickHandler","newSelection","handleScopeChange","handleStatusFilterChange","SearchBar","onSearch","placeholder","isFullWidth","handleInputChange","VerticalTabs","TabsPrimitive","VerticalTabsList","VerticalTabsTrigger","VerticalTabsContent","TabNavigationContentSearch","tabList","searchPlaceholder","headerTitle","isSearchBarFullWidth","direction","tab","Separator","orientation","decorative","SeparatorPrimitive","Skeleton","TooltipProvider","TooltipPrimitive","Tooltip","TooltipTrigger","TooltipContent","SIDEBAR_WIDTH","SIDEBAR_WIDTH_ICON","SIDEBAR_KEYBOARD_SHORTCUT","SidebarContext","useSidebar","SidebarProvider","defaultOpen","openProp","setOpenProp","style","_open","_setOpen","isOpen","openState","toggleSidebar","state","contextValue","Sidebar","side","collapsible","SidebarTrigger","onClick","PanelLeft","SidebarRail","SidebarInset","SidebarInput","SidebarHeader","SidebarFooter","SidebarSeparator","SidebarContent","SidebarGroup","SidebarGroupLabel","SidebarGroupAction","SidebarGroupContent","SidebarMenu","SidebarMenuItem","sidebarMenuButtonVariants","SidebarMenuButton","isActive","tooltip","Comp","button","SidebarMenuAction","showOnHover","SidebarMenuBadge","SidebarMenuSkeleton","showIcon","width","SidebarMenuSub","SidebarMenuSubItem","SidebarMenuSubButton","SettingsSidebar","extensionLabels","projectInfo","handleSelectSidebarItem","selectedSidebarItem","extensionsSidebarGroupLabel","projectsSidebarGroupLabel","buttonPlaceholderText","handleSelectItem","projectId","getProjectNameFromProjectId","project","info","getIsActive","label","selectedProjectName","SettingsSidebarContentSearch","scrBookColId","scrRefColId","typeColId","detailsColId","defaultScrRefColumnName","defaultScrBookGroupName","defaultTypeColumnName","defaultDetailsColumnName","getColumns","colInfo","showSourceColumn","showSrcCol","formatScrRef","compareScrRefs","toRefOrRange","scriptureSelection","offsetStart","offsetEnd","scrRefToBBBCCCVVV","getRowKey","ScriptureResultsViewer","sources","showColumnHeaders","scriptureReferenceColumnName","scriptureBookGroupName","typeColumnName","detailsColumnName","onRowSelected","grouping","setGrouping","scriptureResults","source","getExpandedRowModel","getGroupedRowModel","selectedRows","keys","selectedRow","scrBookGroupName","typeGroupName","groupingOptions","handleSelectChange","selectedGrouping","handleRowClick","getEvenOrOddBandingStyle","getIndent","groupingState","rowIndex","ChevronLeft","DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS","getLocalizeKeyForScrollGroupId","ScrollGroupSelector","availableScrollGroupIds","scrollGroupId","onChangeScrollGroupId","localizedStringsDefaulted","localizedStringKey","localizedStringValue","newScrollGroupString","scrollGroupOptionId","SettingsList","SettingsListItem","primary","secondary","isLoading","loadingMessage","SettingsListHeader","includeSeparator","Checklist","listItems","selectedListItems","handleSelectListItem","createLabel","_interopRequireDefault","obj","module","chainPropTypes","propType1","propType2","args","_extends","target","isPlainObject","prototype","deepClone","output","deepmerge","p","r","t","z","reactIs_production_min","hasSymbol","REACT_ELEMENT_TYPE","REACT_PORTAL_TYPE","REACT_FRAGMENT_TYPE","REACT_STRICT_MODE_TYPE","REACT_PROFILER_TYPE","REACT_PROVIDER_TYPE","REACT_CONTEXT_TYPE","REACT_ASYNC_MODE_TYPE","REACT_CONCURRENT_MODE_TYPE","REACT_FORWARD_REF_TYPE","REACT_SUSPENSE_TYPE","REACT_SUSPENSE_LIST_TYPE","REACT_MEMO_TYPE","REACT_LAZY_TYPE","REACT_BLOCK_TYPE","REACT_FUNDAMENTAL_TYPE","REACT_RESPONDER_TYPE","REACT_SCOPE_TYPE","isValidElementType","typeOf","object","$$typeof","$$typeofType","AsyncMode","ConcurrentMode","ContextConsumer","ContextProvider","Element","ForwardRef","Lazy","Memo","Portal","Profiler","StrictMode","Suspense","hasWarnedAboutDeprecatedIsAsyncMode","isAsyncMode","isConcurrentMode","isContextConsumer","isContextProvider","isElement","isForwardRef","isFragment","isLazy","isMemo","isPortal","isProfiler","isStrictMode","isSuspense","reactIs_development","reactIsModule","require$$0","require$$1","getOwnPropertySymbols","hasOwnProperty","propIsEnumerable","toObject","val","shouldUseNative","test1","test2","order2","test3","letter","objectAssign","from","to","symbols","ReactPropTypesSecret","ReactPropTypesSecret_1","has","printWarning","loggedTypeFailures","message","checkPropTypes","typeSpecs","values","location","componentName","getStack","typeSpecName","error","err","ex","stack","checkPropTypes_1","ReactIs","assign","require$$2","require$$3","require$$4","emptyFunctionThatReturnsNull","factoryWithTypeCheckers","isValidElement","throwOnDirectAccess","ITERATOR_SYMBOL","FAUX_ITERATOR_SYMBOL","getIteratorFn","maybeIterable","iteratorFn","ANONYMOUS","ReactPropTypes","createPrimitiveTypeChecker","createAnyTypeChecker","createArrayOfTypeChecker","createElementTypeChecker","createElementTypeTypeChecker","createInstanceTypeChecker","createNodeChecker","createObjectOfTypeChecker","createEnumTypeChecker","createUnionTypeChecker","createShapeTypeChecker","createStrictShapeTypeChecker","is","PropTypeError","createChainableTypeChecker","validate","manualPropTypeCallCache","manualPropTypeWarningCount","checkType","isRequired","propName","propFullName","secret","cacheKey","chainedCheckType","expectedType","propValue","propType","getPropType","preciseType","getPreciseType","typeChecker","expectedClass","expectedClassName","actualClassName","getClassName","expectedValues","valuesString","arrayOfTypeCheckers","checker","getPostfixForTypeWarning","expectedTypes","checkerResult","expectedTypesMessage","isNode","invalidValidatorError","shapeTypes","allKeys","iterator","step","entry","isSymbol","emptyFunction","emptyFunctionWithReset","factoryWithThrowingShims","shim","getShim","propTypesModule","isClassComponent","elementType","acceptingRef","safePropName","warningHint","elementAcceptingRef","PropTypes","elementAcceptingRef$1","specialProperty","exactProp","propTypes","unsupportedProps","prop","formatMuiErrorMessage","code","url","REACT_SERVER_CONTEXT_TYPE","REACT_OFFSCREEN_TYPE","enableScopeAPI","enableCacheElement","enableTransitionTracing","enableLegacyHidden","enableDebugTracing","REACT_MODULE_REFERENCE","SuspenseList","hasWarnedAboutDeprecatedIsConcurrentMode","isSuspenseList","fnNameMatchRegex","getFunctionName","fn","getFunctionComponentName","Component","fallback","getWrappedName","outerType","innerType","wrapperName","functionName","getDisplayName","HTMLElementType","refType","refType$1","capitalize","string","_formatMuiErrorMessage","createChainedFunction","funcs","acc","func","debounce","wait","timeout","debounced","later","deprecatedPropType","validator","reason","componentNameSafe","propFullNameSafe","isMuiElement","muiNames","_muiName","_element$type","ownerDocument","node","ownerWindow","requirePropFactory","componentNameInError","prevPropTypes","requiredProp","defaultTypeChecker","typeCheckerResult","setRef","useEnhancedEffect","useEnhancedEffect$1","globalId","useGlobalId","idOverride","defaultId","setDefaultId","maybeReactUseId","useId","reactId","unsupportedProp","useControlled","controlled","defaultProp","name","isControlled","valueState","setValue","defaultValue","setValueIfUncontrolled","newValue","useEventCallback","useForkRef","refs","instance","UNINITIALIZED","useLazyRef","init","initArg","EMPTY","useOnMount","Timeout","delay","useTimeout","hadKeyboardEvent","hadFocusVisibleRecently","hadFocusVisibleRecentlyTimeout","inputTypesWhitelist","focusTriggersKeyboardModality","tagName","handlePointerDown","handleVisibilityChange","prepare","doc","isFocusVisible","useIsFocusVisible","isFocusVisibleRef","handleBlurVisible","handleFocusVisible","resolveProps","defaultProps","defaultSlotProps","slotProps","slotPropName","composeClasses","slots","getUtilityClass","classes","slot","utilityClass","defaultGenerator","createClassNameGenerator","generate","generator","ClassNameGenerator","ClassNameGenerator$1","globalStateClasses","generateUtilityClass","globalStatePrefix","globalStateClass","generateUtilityClasses","result","clamp","min","max","_objectWithoutPropertiesLoose","excluded","sourceKeys","_excluded","sortBreakpointsValues","breakpointsAsArray","breakpoint1","breakpoint2","createBreakpoints","breakpoints","unit","other","sortedValues","up","down","between","start","end","endIndex","only","not","keyIndex","shape","shape$1","responsivePropType","responsivePropType$1","merge","defaultBreakpoints","handleBreakpoints","styleFromPropValue","theme","themeBreakpoints","breakpoint","mediaKey","cssKey","createEmptyBreakpointObject","breakpointsInput","_breakpointsInput$key","breakpointStyleKey","removeUnusedBreakpoints","breakpointKeys","breakpointOutput","getPath","path","checkVars","getStyleValue","themeMapping","transform","propValueFinal","userValue","cssProperty","themeKey","memoize","cache","arg","properties","directions","aliases","getCssProperties","property","marginKeys","paddingKeys","spacingKeys","createUnaryUnit","_getPath","themeSpacing","abs","createUnarySpacing","getValue","transformer","transformed","getStyleFromPropValue","cssProperties","resolveCssProperty","margin","padding","createSpacing","spacingInput","spacing","argsInput","argument","compose","styles","handlers","borderTransform","createBorderStyle","border","borderTop","borderRight","borderBottom","borderLeft","borderColor","borderTopColor","borderRightColor","borderBottomColor","borderLeftColor","outline","outlineColor","borderRadius","gap","columnGap","rowGap","gridColumn","gridRow","gridAutoFlow","gridAutoColumns","gridAutoRows","gridTemplateColumns","gridTemplateRows","gridTemplateAreas","gridArea","paletteTransform","color","bgcolor","backgroundColor","sizingTransform","maxWidth","_props$theme","_props$theme2","breakpointsValues","minWidth","height","maxHeight","minHeight","boxSizing","defaultSxConfig","defaultSxConfig$1","objectsHaveSameKeys","objects","union","callIfFn","maybeFn","unstable_createStyleFunctionSx","getThemeValue","config","styleFunctionSx","_theme$unstable_sxCon","sx","traverse","sxInput","sxObject","emptyBreakpoints","breakpointsKeys","css","styleKey","styleFunctionSx$1","applyStyles","createTheme","paletteInput","shapeInput","muiTheme","isObjectEmpty","useTheme","defaultTheme","contextTheme","ThemeContext","systemDefaultTheme","useThemeWithoutDefault","_excluded2","_excluded3","isEmpty","isStringTag","tag","shouldForwardProp","lowercaseFirstLetter","resolveTheme","themeId","defaultOverridesResolver","processStyleArg","callableStyle","_ref","ownerState","resolvedStylesArg","resolvedStyle","variants","isMatch","createStyled","input","rootShouldForwardProp","slotShouldForwardProp","systemSx","inputOptions","processStyles","componentSlot","inputSkipVariantsResolver","inputSkipSx","overridesResolver","skipVariantsResolver","skipSx","shouldForwardPropOption","defaultStyledResolver","styledEngineStyled","transformStyleArg","stylesArg","muiStyledResolver","styleArg","expressions","transformedStyleArg","expressionsWithDefaultTheme","styleOverrides","resolvedStyleOverrides","slotKey","slotStyle","_theme$components","themeVariants","numOfCustomFnsApplied","placeholders","displayName","getThemeProps","params","useThemeProps","clampWrapper","hexToRgb","re","colors","decomposeColor","marker","colorSpace","recomposeColor","hslToRgb","rgb","getLuminance","getContrastRatio","foreground","background","lumA","lumB","alpha","darken","coefficient","lighten","createMixins","mixins","common","common$1","grey","grey$1","purple","purple$1","red","red$1","orange","orange$1","blue","blue$1","lightBlue","lightBlue$1","green","green$1","light","dark","addLightOrDark","intent","shade","tonalOffset","tonalOffsetLight","tonalOffsetDark","getDefaultPrimary","mode","getDefaultSecondary","getDefaultError","getDefaultInfo","getDefaultSuccess","getDefaultWarning","createPalette","palette","contrastThreshold","success","warning","getContrastText","contrastText","contrast","augmentColor","mainShade","lightShade","darkShade","modes","round","caseAllCaps","defaultFontFamily","createTypography","typography","fontFamily","fontSize","fontWeightLight","fontWeightRegular","fontWeightMedium","fontWeightBold","htmlFontSize","allVariants","pxToRem2","coef","pxToRem","buildVariant","fontWeight","lineHeight","letterSpacing","casing","shadowKeyUmbraOpacity","shadowKeyPenumbraOpacity","shadowAmbientShadowOpacity","createShadow","px","shadows","shadows$1","easing","duration","formatMs","milliseconds","getAutoHeightDuration","constant","createTransitions","inputTransitions","mergedEasing","mergedDuration","durationOption","easingOption","isString","isNumber","animatedProp","zIndex","zIndex$1","mixinsInput","transitionsInput","typographyInput","systemTheme","systemCreateTheme","stateClasses","component","child","stateClass","defaultTheme$1","THEME_ID","systemUseThemeProps","styled","styled$1","getSvgIconUtilityClass","useUtilityClasses","SvgIconRoot","_theme$transitions","_theme$transitions$cr","_theme$transitions2","_theme$typography","_theme$typography$pxT","_theme$typography2","_theme$typography2$px","_theme$typography3","_theme$typography3$px","_palette$ownerState$c","_palette","_palette2","_palette3","SvgIcon","inProps","htmlColor","inheritViewBox","titleAccess","viewBox","hasSvgAsChild","more","_jsxs","_jsx","SvgIcon$1","createSvgIcon","unstable_ClassNameGenerator","exports","_utils","ArrowRight","default_1","_createSvgIcon","_jsxRuntime","isHostComponent","appendOwnerState","otherProps","defaultContextValue","ClassNameConfiguratorContext","useClassNamesOverride","disableDefaultClasses","extractEventHandlers","excludeKeys","resolveComponentProps","componentProps","slotState","omitEventHandlers","mergeSlotProps","parameters","getSlotProps","additionalProps","externalSlotProps","externalForwardedProps","joinedClasses","mergedStyle","eventHandlers","componentsPropsWithoutEventHandlers","otherPropsWithoutEventHandlers","internalSlotProps","useSlotProps","_parameters$additiona","skipResolvingSlotProps","rest","resolvedComponentsProps","mergedProps","internalRef","GLOBAL_CLASS_PREFIX","buildStateClass","buildSlotClass","getContainer","container","forwardedRef","disablePortal","mountNode","setMountNode","handleRef","newProps","ReactDOM","top","bottom","right","left","auto","basePlacements","clippingParents","viewport","popper","reference","variationPlacements","placement","placements","beforeRead","read","afterRead","beforeMain","main","afterMain","beforeWrite","write","afterWrite","modifierPhases","getNodeName","getWindow","OwnElement","isHTMLElement","isShadowRoot","attributes","effect","_ref2","initialStyles","styleProperties","attribute","applyStyles$1","getBasePlacement","getUAString","uaData","isLayoutViewport","getBoundingClientRect","includeScale","isFixedStrategy","clientRect","scaleX","scaleY","visualViewport","addVisualOffsets","getLayoutRect","contains","parent","rootNode","next","getComputedStyle","isTableElement","getDocumentElement","getParentNode","getTrueOffsetParent","getContainingBlock","isFirefox","isIE","elementCss","currentNode","getOffsetParent","window","offsetParent","getMainAxisFromPlacement","within","mathMax","mathMin","withinMaxClamp","getFreshSideObject","mergePaddingObject","paddingObject","expandToHashMap","hashMap","toPaddingObject","arrow","_state$modifiersData$","arrowElement","popperOffsets","basePlacement","axis","isVertical","len","arrowRect","minProp","maxProp","endDiff","startDiff","arrowOffsetParent","clientSize","centerToReference","center","offset","axisProp","_options$element","arrow$1","getVariation","unsetSides","roundOffsetsByDPR","win","dpr","mapToStyles","_Object$assign2","popperRect","variation","offsets","gpuAcceleration","adaptive","roundOffsets","isFixed","_offsets$x","_offsets$y","_ref3","hasX","hasY","sideX","sideY","heightProp","widthProp","offsetY","offsetX","commonStyles","_ref4","_Object$assign","computeStyles","_ref5","_options$gpuAccelerat","_options$adaptive","_options$roundOffsets","computeStyles$1","passive","_options$scroll","scroll","_options$resize","resize","scrollParents","scrollParent","eventListeners","hash","getOppositePlacement","matched","getOppositeVariationPlacement","getWindowScroll","scrollLeft","scrollTop","getWindowScrollBarX","getViewportRect","strategy","html","layoutViewport","getDocumentRect","_element$ownerDocumen","winScroll","body","isScrollParent","_getComputedStyle","overflow","overflowX","overflowY","getScrollParent","listScrollParents","list","isBody","updatedList","rectToClientRect","rect","getInnerBoundingClientRect","getClientRectFromMixedType","clippingParent","getClippingParents","canEscapeClipping","clipperElement","getClippingRect","boundary","rootBoundary","mainClippingParents","firstClippingParent","clippingRect","accRect","computeOffsets","commonX","commonY","mainAxis","detectOverflow","_options","_options$placement","_options$strategy","_options$boundary","_options$rootBoundary","_options$elementConte","elementContext","_options$altBoundary","altBoundary","_options$padding","altContext","clippingClientRect","referenceClientRect","popperClientRect","elementClientRect","overflowOffsets","offsetData","multiply","computeAutoPlacement","flipVariations","_options$allowedAutoP","allowedAutoPlacements","allPlacements","allowedPlacements","overflows","getExpandedFallbackPlacements","oppositePlacement","flip","_options$mainAxis","checkMainAxis","_options$altAxis","checkAltAxis","specifiedFallbackPlacements","_options$flipVariatio","preferredPlacement","isBasePlacement","fallbackPlacements","referenceRect","checksMap","makeFallbackChecks","firstFittingPlacement","_basePlacement","isStartVariation","mainVariationSide","altVariationSide","checks","check","numberOfChecks","_loop","_i","fittingPlacement","_ret","flip$1","getSideOffsets","preventedOffsets","isAnySideFullyClipped","hide","referenceOverflow","popperAltOverflow","referenceClippingOffsets","popperEscapeOffsets","isReferenceHidden","hasPopperEscaped","hide$1","distanceAndSkiddingToXY","rects","invertDistance","skidding","distance","_options$offset","_data$state$placement","offset$1","popperOffsets$1","getAltAxis","preventOverflow","_options$tether","tether","_options$tetherOffset","tetherOffset","altAxis","tetherOffsetValue","normalizedTetherOffsetValue","offsetModifierState","_offsetModifierState$","mainSide","altSide","additive","minLen","maxLen","arrowPaddingObject","arrowPaddingMin","arrowPaddingMax","arrowLen","minOffset","maxOffset","clientOffset","offsetModifierValue","tetherMin","tetherMax","preventedOffset","_offsetModifierState$2","_mainSide","_altSide","_offset","_len","_min","_max","isOriginSide","_offsetModifierValue","_tetherMin","_tetherMax","_preventedOffset","preventOverflow$1","getHTMLElementScroll","getNodeScroll","isElementScaled","getCompositeRect","elementOrVirtualElement","isOffsetParentAnElement","offsetParentIsScaled","documentElement","order","modifiers","map","visited","modifier","sort","requires","dep","depModifier","orderModifiers","orderedModifiers","phase","pending","resolve","mergeByName","merged","current","existing","DEFAULT_OPTIONS","areValidElements","_key","popperGenerator","generatorOptions","_generatorOptions","_generatorOptions$def","defaultModifiers","_generatorOptions$def2","defaultOptions","effectCleanupFns","isDestroyed","setOptionsAction","cleanupModifierEffects","runModifierEffects","_state$elements","_state$orderedModifie","_state$orderedModifie2","_ref$options","cleanupFn","noopFn","createPopper","COMPONENT_NAME","getPopperUtilityClass","flipPlacement","resolveAnchorEl","anchorEl","isVirtualElement","defaultPopperOptions","PopperTooltip","_slots$root","initialPlacement","popperOptions","popperRefProp","TransitionProps","tooltipRef","ownRef","popperRef","handlePopperRef","handlePopperRefRef","rtlPlacement","setPlacement","resolvedAnchorElement","setResolvedAnchorElement","handlePopperUpdate","box","popperModifiers","childProps","Root","rootProps","Popper","containerProp","keepMounted","transition","exited","setExited","handleEnter","handleExited","resolvedAnchorEl","display","transitionProps","useThemeSystem","_setPrototypeOf","_inheritsLoose","subClass","superClass","setPrototypeOf","timeoutsShape","TransitionGroupContext","forceReflow","UNMOUNTED","EXITED","ENTERING","ENTERED","EXITING","Transition","_React$Component","_this","parentGroup","appear","initialStatus","prevState","nextIn","_proto","prevProps","nextStatus","exit","enter","mounting","_this2","appearing","maybeNode","maybeAppearing","timeouts","enterTimeout","_this3","nextState","callback","_this4","active","handler","doesNotHaveTimeoutOrListener","maybeNextCallback","_this$props","pt","noop","Transition$1","reflow","getTransitionProps","_style$transitionDura","_style$transitionTimi","getScale","isWebKit154","Grow","addEndListener","inProp","onEnter","onEntered","onEntering","onExit","onExited","onExiting","TransitionComponent","timer","autoTimeout","nodeRef","normalizedTransitionCallback","maybeIsAppearing","handleEntering","isAppearing","transitionDuration","transitionTimingFunction","handleEntered","handleExiting","handleExit","Grow$1","PopperRoot","BasePopper","components","componentsProps","RootComponent","Popper$1","getTooltipUtilityClass","tooltipClasses","tooltipClasses$1","disableInteractive","touch","TooltipPopper","TooltipTooltip","TooltipArrow","hystersisOpen","hystersisTimer","cursorPosition","composeEventHandler","eventHandler","_slots$popper","_slots$transition","_slots$tooltip","_slots$arrow","_slotProps$popper","_ref6","_slotProps$popper2","_slotProps$transition","_slotProps$tooltip","_ref7","_slotProps$tooltip2","_slotProps$arrow","_ref8","_slotProps$arrow2","childrenProp","describeChild","disableFocusListener","disableHoverListener","disableInteractiveProp","disableTouchListener","enterDelay","enterNextDelay","enterTouchDelay","followCursor","idProp","leaveDelay","leaveTouchDelay","onClose","onOpen","PopperComponentProp","PopperProps","title","TransitionComponentProp","isRtl","childNode","setChildNode","arrowRef","setArrowRef","ignoreNonTouchEvents","closeTimer","enterTimer","leaveTimer","touchTimer","setOpenState","prevUserSelect","stopTouchInteraction","handleOpen","handleClose","handleLeave","focusVisibleRef","setChildIsFocusVisible","handleBlur","handleFocus","detectTouchStart","childrenProps","handleMouseOver","handleMouseLeave","handleTouchStart","handleTouchEnd","nativeEvent","handleMouseMove","nameOrDescProps","titleIsString","interactiveWrapperListeners","_PopperProps$popperOp","tooltipModifiers","PopperComponent","TooltipComponent","ArrowComponent","popperProps","tooltipProps","tooltipArrowProps","TransitionPropsInner","Tooltip$1","getIcon","icon","menuLabel","leading","MuiListItemIcon","MenuItem","allowForLeadingIcons","iconPathBefore","iconPathAfter","hasAutoFocus","isDense","isSubMenuParent","hasDisabledGutters","hasDivider","focusVisibleClassName","menuItem","MuiMenuItem","MuiListItemText","getAllGroups","menuDefinition","SubMenu","setAnchorEl","parentMenuItem","parentItemProps","handleParentMenuItemClick","renderSubMenuItems","includedGroups","group","GroupedMenuItemList","Menu","getOrderedGroupItems","groupId","allItems","menuProps","commandHandler","groupsToInclude","sortedGroups","itemArray","allowSpaceForLeadingIcons","createMenuItemProps","isLastItemInGroup","divKey","itemInfo","menuItemProps","TopLevelMenu","columnId","MenuColumn","metadata","Grid","List","GridMenu","multiColumnMenu","sortedColumns","columnNumbers","columnName","col","getUsePromiseOptionsDefaults","usePromise","promiseFactoryCallback","defaultValueRef","optionsDefaultedRef","setIsLoading","promiseIsCurrent","MenuIcon","HamburgerMenuButton","menuProvider","normalMenu","fullMenu","containerRef","ariaLabelPrefix","isMenuOpen","setMenuOpen","showFullMenu","setShowFullMenu","handleMenuItemClick","handleMenuButtonClick","prevIsOpen","isOpening","menuCommandHandler","command","setOffset","normalMenuData","fullMenuData","menu","IconButton","Drawer","isTooltipSuppressed","adjustMarginToAlignToEdge","MuiIconButton","Spinner","LoaderCircle","TextField","hasError","helperText","onFocus","onBlur","ShadLabel","Toolbar","AppBar","MuiToolbar","alertVariants","Alert","AlertTitle","AlertDescription","Card","CardHeader","CardTitle","CardDescription","CardContent","CardFooter","Sonner","Toaster","Slider","SliderPrimitive","Switch","SwitchPrimitives","Tabs","TabsList","TabsTrigger","TabsContent","InstallButton","isInstalling","handleClick","buttonText","Download","EnableButton","isEnabling","DisableButton","isDisabling","UpdateButton","isUpdating","MarkdownRenderer","markdown","anchorTarget","Markdown","FilterButton","Filter","DropdownMenuItemType","DropdownMenuItemType2","FilterDropdown","groups","NoExtensionsFound","MoreInfo","category","downloads","languages","moreInfoUrl","numberFormatted","NumberFormat","handleScrollToBottom","User","locale","LucideLink","CircleHelp","VersionHistory","versionHistory","showAllVersions","setShowAllVersions","currentDate","formatTimeString","dateString","date","dateDiff","yearDiff","monthDiff","dayDiff","timeString","sortedEntries","Footer","publisherDisplayName","fileSize","locales","formattedFileSize","formatBytes","languageNames","codes","displayNames","useEvent","unsubscriber","noopUnsubscriber","useEventAsync","unsubscribe","unsub"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAGA,MAAMA,KAAgBC,GAAoB,EAAE,QAAQ,MAAO,CAAA;AAyDpD,SAASC,KAAMC,GAAsB;AACnC,SAAAH,GAAcI,GAAKD,CAAM,CAAC;AACnC;ACzDO,MAAME,KAAQC,EAAM;AAAA,EACzB,CAAC,EAAE,WAAAC,GAAW,MAAAC,GAAM,GAAGC,EAAA,GAASC,MAE5B,gBAAAC;AAAA,IAAC;AAAA,IAAA;AAAA,MACC,MAAAH;AAAA,MACA,WAAWN;AAAA,QACT;AAAA,QACAK;AAAA,MACF;AAAA,MACA,KAAAG;AAAA,MAEC,GAAGD;AAAA,IAAA;AAAA,EAAA;AAIZ;AACAJ,GAAM,cAAc;ACNpB,MAAMO,KAAmBC;AAAA,EACvB,CACE,EAAE,cAAAC,GAAc,eAAAC,GAAe,eAAAC,GAAe,cAAAC,GAAc,GAAGR,EAAM,GACrEC,MAGE,gBAAAQ,EAAC,OAAI,EAAA,WAAU,eACb,UAAA;AAAA,IAAA,gBAAAP;AAAA,MAACQ;AAAAA,MAAA;AAAA,QACE,GAAGV;AAAA,QACJ,MAAK;AAAA,QACL,WAAU;AAAA,QACV,UAAU,CAACW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AAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA;AAAA;AAAA,EAGA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AACF,GA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;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","x_google_ignoreList":[3,43,44,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,83,84,85,86,87,88,89,90,91,92,93,94,95,96,97,98,99,100,101,102,103,104,105,106,107,108,109,110,111,112,113,114,115,116,117,118,119,120,121,122,123,124,125,126,127,128,129,130,131,132,133,134,135,136,137,138,139,140,141,142,143,144,145,146,147,148,149,150,151,152,153,154,155,156,157,158,159,160,161,162,163,164,165,166,167,168,169,170,171,172,173,174,175,176,177,178,179,180,181,182,183,184,185,186,187,188,189,190,191,192,193,194,195,196,197,198,199,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,226]} \ No newline at end of file +{"version":3,"file":"index.js","sources":["../src/utils/shadcn-ui.util.ts","../src/components/shadcn-ui/input.tsx","../src/components/advanced/book-chapter-control/book-chapter-input.component.tsx","../../../node_modules/@sillsdev/scripture/dist/index.es.js","../src/components/shadcn-ui/dropdown-menu.tsx","../src/components/advanced/book-chapter-control/book-menu-item.component.tsx","../src/components/advanced/book-chapter-control/chapter-select.component.tsx","../src/components/advanced/book-chapter-control/go-to-menu-item.component.tsx","../src/components/advanced/book-chapter-control/book-chapter-control.component.tsx","../src/components/shadcn-ui/button.tsx","../src/components/shadcn-ui/label.tsx","../src/components/shadcn-ui/radio-group.tsx","../src/components/shadcn-ui/popover.tsx","../src/components/shadcn-ui/dialog.tsx","../src/components/shadcn-ui/command.tsx","../src/components/basics/combo-box.component.tsx","../src/components/basics/chapter-range-selector.component.tsx","../src/components/advanced/book-selector.component.tsx","../src/components/advanced/data-table/data-table-column-toggle.component.tsx","../src/components/shadcn-ui/select.tsx","../src/components/advanced/data-table/data-table-pagination.component.tsx","../src/components/shadcn-ui/table.tsx","../src/components/advanced/data-table/data-table.component.tsx","../src/components/advanced/inventory/occurrences-table.component.tsx","../src/components/shadcn-ui/checkbox.tsx","../src/components/advanced/inventory/inventory-utils.ts","../src/components/shadcn-ui/toggle.tsx","../src/components/shadcn-ui/toggle-group.tsx","../src/components/advanced/inventory/inventory-columns.tsx","../src/components/advanced/inventory/inventory.component.tsx","../src/components/basics/search-bar.component.tsx","../src/components/basics/tabs-vertical.tsx","../src/components/advanced/tab-navigation-content-search.component.tsx","../src/components/shadcn-ui/separator.tsx","../src/components/shadcn-ui/skeleton.tsx","../src/components/shadcn-ui/tooltip.tsx","../src/components/shadcn-ui/sidebar.tsx","../src/components/advanced/settings-components/settings-sidebar.component.tsx","../src/components/advanced/settings-components/settings-sidebar-content-search.component.tsx","../src/components/advanced/scripture-results-viewer/scripture-results-viewer.component.tsx","../src/components/advanced/scroll-group-selector.component.tsx","../src/components/advanced/settings-components/settings-list.component.tsx","../src/components/basics/checklist.component.tsx","../../../node_modules/@babel/runtime/helpers/interopRequireDefault.js","../../../node_modules/@mui/utils/chainPropTypes/chainPropTypes.js","../../../node_modules/@babel/runtime/helpers/esm/extends.js","../../../node_modules/@mui/utils/deepmerge/deepmerge.js","../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.production.min.js","../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.development.js","../../../node_modules/prop-types/node_modules/react-is/index.js","../../../node_modules/object-assign/index.js","../../../node_modules/prop-types/lib/ReactPropTypesSecret.js","../../../node_modules/prop-types/lib/has.js","../../../node_modules/prop-types/checkPropTypes.js","../../../node_modules/prop-types/factoryWithTypeCheckers.js","../../../node_modules/prop-types/factoryWithThrowingShims.js","../../../node_modules/prop-types/index.js","../../../node_modules/@mui/utils/elementAcceptingRef/elementAcceptingRef.js","../../../node_modules/@mui/utils/exactProp/exactProp.js","../../../node_modules/@mui/utils/formatMuiErrorMessage/formatMuiErrorMessage.js","../../../node_modules/react-is/cjs/react-is.production.min.js","../../../node_modules/react-is/cjs/react-is.development.js","../../../node_modules/react-is/index.js","../../../node_modules/@mui/utils/getDisplayName/getDisplayName.js","../../../node_modules/@mui/utils/HTMLElementType/HTMLElementType.js","../../../node_modules/@mui/utils/refType/refType.js","../../../node_modules/@mui/utils/capitalize/capitalize.js","../../../node_modules/@mui/utils/createChainedFunction/createChainedFunction.js","../../../node_modules/@mui/utils/debounce/debounce.js","../../../node_modules/@mui/utils/deprecatedPropType/deprecatedPropType.js","../../../node_modules/@mui/utils/isMuiElement/isMuiElement.js","../../../node_modules/@mui/utils/ownerDocument/ownerDocument.js","../../../node_modules/@mui/utils/ownerWindow/ownerWindow.js","../../../node_modules/@mui/utils/requirePropFactory/requirePropFactory.js","../../../node_modules/@mui/utils/setRef/setRef.js","../../../node_modules/@mui/utils/useEnhancedEffect/useEnhancedEffect.js","../../../node_modules/@mui/utils/useId/useId.js","../../../node_modules/@mui/utils/unsupportedProp/unsupportedProp.js","../../../node_modules/@mui/utils/useControlled/useControlled.js","../../../node_modules/@mui/utils/useEventCallback/useEventCallback.js","../../../node_modules/@mui/utils/useForkRef/useForkRef.js","../../../node_modules/@mui/utils/useLazyRef/useLazyRef.js","../../../node_modules/@mui/utils/useOnMount/useOnMount.js","../../../node_modules/@mui/utils/useTimeout/useTimeout.js","../../../node_modules/@mui/utils/useIsFocusVisible/useIsFocusVisible.js","../../../node_modules/@mui/utils/resolveProps/resolveProps.js","../../../node_modules/@mui/utils/composeClasses/composeClasses.js","../../../node_modules/@mui/utils/ClassNameGenerator/ClassNameGenerator.js","../../../node_modules/@mui/utils/generateUtilityClass/generateUtilityClass.js","../../../node_modules/@mui/utils/generateUtilityClasses/generateUtilityClasses.js","../../../node_modules/@mui/utils/clamp/clamp.js","../../../node_modules/@babel/runtime/helpers/esm/objectWithoutPropertiesLoose.js","../../../node_modules/@mui/system/esm/createTheme/createBreakpoints.js","../../../node_modules/@mui/system/esm/createTheme/shape.js","../../../node_modules/@mui/system/esm/responsivePropType.js","../../../node_modules/@mui/system/esm/merge.js","../../../node_modules/@mui/system/esm/breakpoints.js","../../../node_modules/@mui/system/esm/style.js","../../../node_modules/@mui/system/esm/memoize.js","../../../node_modules/@mui/system/esm/spacing.js","../../../node_modules/@mui/system/esm/createTheme/createSpacing.js","../../../node_modules/@mui/system/esm/compose.js","../../../node_modules/@mui/system/esm/borders.js","../../../node_modules/@mui/system/esm/cssGrid.js","../../../node_modules/@mui/system/esm/palette.js","../../../node_modules/@mui/system/esm/sizing.js","../../../node_modules/@mui/system/esm/styleFunctionSx/defaultSxConfig.js","../../../node_modules/@mui/system/esm/styleFunctionSx/styleFunctionSx.js","../../../node_modules/@mui/system/esm/createTheme/applyStyles.js","../../../node_modules/@mui/system/esm/createTheme/createTheme.js","../../../node_modules/@mui/system/esm/useThemeWithoutDefault.js","../../../node_modules/@mui/system/esm/useTheme.js","../../../node_modules/@mui/system/esm/createStyled.js","../../../node_modules/@mui/system/esm/useThemeProps/getThemeProps.js","../../../node_modules/@mui/system/esm/useThemeProps/useThemeProps.js","../../../node_modules/@mui/system/esm/colorManipulator.js","../../../node_modules/@mui/material/styles/createMixins.js","../../../node_modules/@mui/material/colors/common.js","../../../node_modules/@mui/material/colors/grey.js","../../../node_modules/@mui/material/colors/purple.js","../../../node_modules/@mui/material/colors/red.js","../../../node_modules/@mui/material/colors/orange.js","../../../node_modules/@mui/material/colors/blue.js","../../../node_modules/@mui/material/colors/lightBlue.js","../../../node_modules/@mui/material/colors/green.js","../../../node_modules/@mui/material/styles/createPalette.js","../../../node_modules/@mui/material/styles/createTypography.js","../../../node_modules/@mui/material/styles/shadows.js","../../../node_modules/@mui/material/styles/createTransitions.js","../../../node_modules/@mui/material/styles/zIndex.js","../../../node_modules/@mui/material/styles/createTheme.js","../../../node_modules/@mui/material/styles/defaultTheme.js","../../../node_modules/@mui/material/styles/identifier.js","../../../node_modules/@mui/material/styles/useThemeProps.js","../../../node_modules/@mui/material/styles/styled.js","../../../node_modules/@mui/material/SvgIcon/svgIconClasses.js","../../../node_modules/@mui/material/SvgIcon/SvgIcon.js","../../../node_modules/@mui/material/utils/createSvgIcon.js","../../../node_modules/@mui/material/utils/index.js","../../../node_modules/@mui/icons-material/utils/createSvgIcon.js","../../../node_modules/@mui/icons-material/ArrowRight.js","../../../node_modules/@mui/base/utils/isHostComponent.js","../../../node_modules/@mui/base/utils/appendOwnerState.js","../../../node_modules/@mui/base/utils/ClassNameConfigurator.js","../../../node_modules/@mui/base/utils/extractEventHandlers.js","../../../node_modules/@mui/base/utils/resolveComponentProps.js","../../../node_modules/@mui/base/utils/omitEventHandlers.js","../../../node_modules/@mui/base/utils/mergeSlotProps.js","../../../node_modules/@mui/base/utils/useSlotProps.js","../../../node_modules/@mui/base/generateUtilityClass/index.js","../../../node_modules/@mui/base/generateUtilityClasses/index.js","../../../node_modules/@mui/base/Portal/Portal.js","../../../node_modules/@popperjs/core/lib/enums.js","../../../node_modules/@popperjs/core/lib/dom-utils/getNodeName.js","../../../node_modules/@popperjs/core/lib/dom-utils/getWindow.js","../../../node_modules/@popperjs/core/lib/dom-utils/instanceOf.js","../../../node_modules/@popperjs/core/lib/modifiers/applyStyles.js","../../../node_modules/@popperjs/core/lib/utils/getBasePlacement.js","../../../node_modules/@popperjs/core/lib/utils/math.js","../../../node_modules/@popperjs/core/lib/utils/userAgent.js","../../../node_modules/@popperjs/core/lib/dom-utils/isLayoutViewport.js","../../../node_modules/@popperjs/core/lib/dom-utils/getBoundingClientRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/getLayoutRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/contains.js","../../../node_modules/@popperjs/core/lib/dom-utils/getComputedStyle.js","../../../node_modules/@popperjs/core/lib/dom-utils/isTableElement.js","../../../node_modules/@popperjs/core/lib/dom-utils/getDocumentElement.js","../../../node_modules/@popperjs/core/lib/dom-utils/getParentNode.js","../../../node_modules/@popperjs/core/lib/dom-utils/getOffsetParent.js","../../../node_modules/@popperjs/core/lib/utils/getMainAxisFromPlacement.js","../../../node_modules/@popperjs/core/lib/utils/within.js","../../../node_modules/@popperjs/core/lib/utils/getFreshSideObject.js","../../../node_modules/@popperjs/core/lib/utils/mergePaddingObject.js","../../../node_modules/@popperjs/core/lib/utils/expandToHashMap.js","../../../node_modules/@popperjs/core/lib/modifiers/arrow.js","../../../node_modules/@popperjs/core/lib/utils/getVariation.js","../../../node_modules/@popperjs/core/lib/modifiers/computeStyles.js","../../../node_modules/@popperjs/core/lib/modifiers/eventListeners.js","../../../node_modules/@popperjs/core/lib/utils/getOppositePlacement.js","../../../node_modules/@popperjs/core/lib/utils/getOppositeVariationPlacement.js","../../../node_modules/@popperjs/core/lib/dom-utils/getWindowScroll.js","../../../node_modules/@popperjs/core/lib/dom-utils/getWindowScrollBarX.js","../../../node_modules/@popperjs/core/lib/dom-utils/getViewportRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/getDocumentRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/isScrollParent.js","../../../node_modules/@popperjs/core/lib/dom-utils/getScrollParent.js","../../../node_modules/@popperjs/core/lib/dom-utils/listScrollParents.js","../../../node_modules/@popperjs/core/lib/utils/rectToClientRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/getClippingRect.js","../../../node_modules/@popperjs/core/lib/utils/computeOffsets.js","../../../node_modules/@popperjs/core/lib/utils/detectOverflow.js","../../../node_modules/@popperjs/core/lib/utils/computeAutoPlacement.js","../../../node_modules/@popperjs/core/lib/modifiers/flip.js","../../../node_modules/@popperjs/core/lib/modifiers/hide.js","../../../node_modules/@popperjs/core/lib/modifiers/offset.js","../../../node_modules/@popperjs/core/lib/modifiers/popperOffsets.js","../../../node_modules/@popperjs/core/lib/utils/getAltAxis.js","../../../node_modules/@popperjs/core/lib/modifiers/preventOverflow.js","../../../node_modules/@popperjs/core/lib/dom-utils/getHTMLElementScroll.js","../../../node_modules/@popperjs/core/lib/dom-utils/getNodeScroll.js","../../../node_modules/@popperjs/core/lib/dom-utils/getCompositeRect.js","../../../node_modules/@popperjs/core/lib/utils/orderModifiers.js","../../../node_modules/@popperjs/core/lib/utils/debounce.js","../../../node_modules/@popperjs/core/lib/utils/mergeByName.js","../../../node_modules/@popperjs/core/lib/createPopper.js","../../../node_modules/@popperjs/core/lib/popper.js","../../../node_modules/@mui/base/Popper/popperClasses.js","../../../node_modules/@mui/base/Popper/Popper.js","../../../node_modules/@mui/material/styles/useTheme.js","../../../node_modules/@babel/runtime/helpers/esm/setPrototypeOf.js","../../../node_modules/@babel/runtime/helpers/esm/inheritsLoose.js","../../../node_modules/react-transition-group/esm/config.js","../../../node_modules/react-transition-group/esm/utils/PropTypes.js","../../../node_modules/react-transition-group/esm/TransitionGroupContext.js","../../../node_modules/react-transition-group/esm/utils/reflow.js","../../../node_modules/react-transition-group/esm/Transition.js","../../../node_modules/@mui/material/transitions/utils.js","../../../node_modules/@mui/material/Grow/Grow.js","../../../node_modules/@mui/material/Popper/Popper.js","../../../node_modules/@mui/material/Tooltip/tooltipClasses.js","../../../node_modules/@mui/material/Tooltip/Tooltip.js","../src/components/mui/menu-item.component.tsx","../src/components/mui/grouped-menu-item-list.component.tsx","../src/components/mui/top-level-menu.component.tsx","../src/components/mui/grid-menu.component.tsx","../src/hooks/use-promise.hook.ts","../../../node_modules/@mui/icons-material/esm/Menu.js","../src/components/mui/hamburger-menu-button.component.tsx","../src/components/mui/icon-button.component.tsx","../src/components/basics/spinner.component.tsx","../src/components/basics/text-field.component.tsx","../src/components/mui/toolbar.component.tsx","../src/components/shadcn-ui/alert.tsx","../src/components/shadcn-ui/card.tsx","../src/components/shadcn-ui/sonner.tsx","../src/components/shadcn-ui/slider.tsx","../src/components/shadcn-ui/switch.tsx","../src/components/shadcn-ui/tabs.tsx","../src/components/advanced/extension-marketplace/buttons/install-button.component.tsx","../src/components/advanced/extension-marketplace/buttons/enable-button.component.tsx","../src/components/advanced/extension-marketplace/buttons/disable-button.component.tsx","../src/components/advanced/extension-marketplace/buttons/update-button.component.tsx","../src/components/advanced/extension-marketplace/markdown-renderer.component.tsx","../src/components/advanced/extension-marketplace/buttons/filter-button.component.tsx","../src/components/advanced/extension-marketplace/filter-dropdown.component.tsx","../src/components/advanced/extension-marketplace/no-extensions-found.component.tsx","../src/components/advanced/extension-marketplace/more-info.component.tsx","../src/components/advanced/extension-marketplace/version-history.component.tsx","../src/components/advanced/extension-marketplace/footer.component.tsx","../src/hooks/use-event.hook.ts","../src/hooks/use-event-async.hook.ts"],"sourcesContent":["import { type ClassValue, clsx } from 'clsx';\nimport { extendTailwindMerge } from 'tailwind-merge';\n\nconst twMergeCustom = extendTailwindMerge({ prefix: 'tw-' });\n\n/**\n * Tailwind and CSS class application helper function. Uses\n * [`clsx`](https://www.npmjs.com/package/clsx) to make it easy to apply classes conditionally using\n * object syntax, and uses [`tailwind-merge`](https://www.npmjs.com/package/tailwind-merge) to make\n * it easy to merge/overwrite Tailwind classes in a programmer-logic-friendly way.\n *\n * Note: `tailwind-merge` is configured to use the prefix `tw-`, so you must use the same prefix\n * with any Tailwind classes you use with this function to successfully overwrite other Tailwind\n * classes. `platform-bible-react` is configured to use `tw-` as its Tailwind prefix, so any\n * Tailwind classes you pass into `platform-bible-react` components will be compared using the `tw-`\n * prefix.\n *\n * This function was popularized by\n * [shadcn/ui](https://ui.shadcn.com/docs/installation/manual#add-a-cn-helper). See [ByteGrad's\n * explanation video](https://www.youtube.com/watch?v=re2JFITR7TI) for more information.\n *\n * @example\n *\n * ```typescript\n * const borderShouldBeBlue = true;\n * const textShouldBeRed = true;\n * const heightShouldBe20 = false;\n * const classString = cn(\n * 'tw-bg-primary tw-h-10 tw-text-primary-foreground',\n * 'tw-bg-secondary',\n * {\n * 'tw-border-blue-500': borderShouldBeBlue,\n * 'tw-text-red-500': textShouldBeRed,\n * 'tw-h-20': heightShouldBe20,\n * },\n * 'some-class',\n * );\n * ```\n *\n * The resulting `classString` is `'tw-h-10 tw-bg-secondary tw-border-blue-500 tw-text-red-500\n * some-class'`\n *\n * - Notice that `'tw-bg-secondary'`, specified later, overwrote `'tw-bg-primary'`, specified earlier,\n * because they are Tailwind classes that affect the same css property\n * - Notice that `'tw-text-red-500'`, specified later, overwrote `'tw-text-primary-foreground'`,\n * specified earlier, because they are Tailwind classes that affect the same css property\n * - Notice that `'tw-h-20'`, specified later, did not overwrite `'tw-h-10'`, specified earlier,\n * because `'tw-h-20'` is part of a conditional class object and its value evaluated to `false`;\n * therefore it was not applied\n * - Notice that `'some-class'` was applied. This function is not limited only to Tailwind classes.\n *\n *\n * @param inputs Class strings or `clsx` conditional class objects to merge. Tailwind classes\n * specified later in the arguments overwrite similar Tailwind classes specified earlier in the\n * arguments\n * @returns Class string containing all applicable classes from the arguments based on the rules\n * described above\n */\n// shadcn/ui uses this export in its boilerplate code\n// eslint-disable-next-line import/prefer-default-export\nexport function cn(...inputs: ClassValue[]) {\n return twMergeCustom(clsx(inputs));\n}\n","import React from 'react';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport interface InputProps extends React.InputHTMLAttributes {}\n\nexport const Input = React.forwardRef(\n ({ className, type, ...props }, ref) => {\n return (\n \n );\n },\n);\nInput.displayName = 'Input';\n","import { FocusEventHandler, forwardRef, KeyboardEvent, MouseEventHandler } from 'react';\nimport { History } from 'lucide-react';\nimport { Input as ShadInput } from '@/components/shadcn-ui/input';\n\nexport type BookChapterInputProps = {\n handleSearch: (searchString: string) => void;\n handleKeyDown: (event: KeyboardEvent) => void;\n handleOnClick: MouseEventHandler;\n handleSubmit: () => void;\n onFocus?: FocusEventHandler;\n value: string;\n placeholder: string;\n};\n\n// Shadcn Input sets type to \"button\"- HAVE to prop spread before setting type\nconst BookChapterInput = forwardRef(\n (\n { handleSearch, handleKeyDown, handleOnClick, handleSubmit, ...props }: BookChapterInputProps,\n ref,\n ) => {\n return (\n
    \n handleSearch(event.target.value)}\n onKeyDown={(e) => {\n if (e.key === 'Enter') {\n handleSubmit();\n }\n handleKeyDown(e);\n }}\n onClick={handleOnClick}\n ref={ref}\n />\n {\n // eslint-disable-next-line no-console\n console.log('back in history');\n }}\n />\n
    \n );\n },\n);\n\nexport default BookChapterInput;\n","var P = Object.defineProperty;\nvar R = (t, e, s) => e in t ? P(t, e, { enumerable: !0, configurable: !0, writable: !0, value: s }) : t[e] = s;\nvar n = (t, e, s) => R(t, typeof e != \"symbol\" ? e + \"\" : e, s);\nclass _ {\n constructor() {\n n(this, \"books\");\n n(this, \"firstSelectedBookNum\");\n n(this, \"lastSelectedBookNum\");\n n(this, \"count\");\n n(this, \"selectedBookNumbers\");\n n(this, \"selectedBookIds\");\n }\n}\nconst N = [\n \"GEN\",\n \"EXO\",\n \"LEV\",\n \"NUM\",\n \"DEU\",\n \"JOS\",\n \"JDG\",\n \"RUT\",\n \"1SA\",\n \"2SA\",\n // 10\n \"1KI\",\n \"2KI\",\n \"1CH\",\n \"2CH\",\n \"EZR\",\n \"NEH\",\n \"EST\",\n \"JOB\",\n \"PSA\",\n \"PRO\",\n // 20\n \"ECC\",\n \"SNG\",\n \"ISA\",\n \"JER\",\n \"LAM\",\n \"EZK\",\n \"DAN\",\n \"HOS\",\n \"JOL\",\n \"AMO\",\n // 30\n \"OBA\",\n \"JON\",\n \"MIC\",\n \"NAM\",\n \"HAB\",\n \"ZEP\",\n \"HAG\",\n \"ZEC\",\n \"MAL\",\n \"MAT\",\n // 40\n \"MRK\",\n \"LUK\",\n \"JHN\",\n \"ACT\",\n \"ROM\",\n \"1CO\",\n \"2CO\",\n \"GAL\",\n \"EPH\",\n \"PHP\",\n // 50\n \"COL\",\n \"1TH\",\n \"2TH\",\n \"1TI\",\n \"2TI\",\n \"TIT\",\n \"PHM\",\n \"HEB\",\n \"JAS\",\n \"1PE\",\n // 60\n \"2PE\",\n \"1JN\",\n \"2JN\",\n \"3JN\",\n \"JUD\",\n \"REV\",\n \"TOB\",\n \"JDT\",\n \"ESG\",\n \"WIS\",\n // 70\n \"SIR\",\n \"BAR\",\n \"LJE\",\n \"S3Y\",\n \"SUS\",\n \"BEL\",\n \"1MA\",\n \"2MA\",\n \"3MA\",\n \"4MA\",\n // 80\n \"1ES\",\n \"2ES\",\n \"MAN\",\n \"PS2\",\n \"ODA\",\n \"PSS\",\n \"JSA\",\n // actual variant text for JOS, now in LXA text\n \"JDB\",\n // actual variant text for JDG, now in LXA text\n \"TBS\",\n // actual variant text for TOB, now in LXA text\n \"SST\",\n // actual variant text for SUS, now in LXA text // 90\n \"DNT\",\n // actual variant text for DAN, now in LXA text\n \"BLT\",\n // actual variant text for BEL, now in LXA text\n \"XXA\",\n \"XXB\",\n \"XXC\",\n \"XXD\",\n \"XXE\",\n \"XXF\",\n \"XXG\",\n \"FRT\",\n // 100\n \"BAK\",\n \"OTH\",\n \"3ES\",\n // Used previously but really should be 2ES\n \"EZA\",\n // Used to be called 4ES, but not actually in any known project\n \"5EZ\",\n // Used to be called 5ES, but not actually in any known project\n \"6EZ\",\n // Used to be called 6ES, but not actually in any known project\n \"INT\",\n \"CNC\",\n \"GLO\",\n \"TDX\",\n // 110\n \"NDX\",\n \"DAG\",\n \"PS3\",\n \"2BA\",\n \"LBA\",\n \"JUB\",\n \"ENO\",\n \"1MQ\",\n \"2MQ\",\n \"3MQ\",\n // 120\n \"REP\",\n \"4BA\",\n \"LAO\"\n], B = [\n \"XXA\",\n \"XXB\",\n \"XXC\",\n \"XXD\",\n \"XXE\",\n \"XXF\",\n \"XXG\",\n \"FRT\",\n \"BAK\",\n \"OTH\",\n \"INT\",\n \"CNC\",\n \"GLO\",\n \"TDX\",\n \"NDX\"\n], O = [\n \"Genesis\",\n \"Exodus\",\n \"Leviticus\",\n \"Numbers\",\n \"Deuteronomy\",\n \"Joshua\",\n \"Judges\",\n \"Ruth\",\n \"1 Samuel\",\n \"2 Samuel\",\n \"1 Kings\",\n \"2 Kings\",\n \"1 Chronicles\",\n \"2 Chronicles\",\n \"Ezra\",\n \"Nehemiah\",\n \"Esther (Hebrew)\",\n \"Job\",\n \"Psalms\",\n \"Proverbs\",\n \"Ecclesiastes\",\n \"Song of Songs\",\n \"Isaiah\",\n \"Jeremiah\",\n \"Lamentations\",\n \"Ezekiel\",\n \"Daniel (Hebrew)\",\n \"Hosea\",\n \"Joel\",\n \"Amos\",\n \"Obadiah\",\n \"Jonah\",\n \"Micah\",\n \"Nahum\",\n \"Habakkuk\",\n \"Zephaniah\",\n \"Haggai\",\n \"Zechariah\",\n \"Malachi\",\n \"Matthew\",\n \"Mark\",\n \"Luke\",\n \"John\",\n \"Acts\",\n \"Romans\",\n \"1 Corinthians\",\n \"2 Corinthians\",\n \"Galatians\",\n \"Ephesians\",\n \"Philippians\",\n \"Colossians\",\n \"1 Thessalonians\",\n \"2 Thessalonians\",\n \"1 Timothy\",\n \"2 Timothy\",\n \"Titus\",\n \"Philemon\",\n \"Hebrews\",\n \"James\",\n \"1 Peter\",\n \"2 Peter\",\n \"1 John\",\n \"2 John\",\n \"3 John\",\n \"Jude\",\n \"Revelation\",\n \"Tobit\",\n \"Judith\",\n \"Esther Greek\",\n \"Wisdom of Solomon\",\n \"Sirach (Ecclesiasticus)\",\n \"Baruch\",\n \"Letter of Jeremiah\",\n \"Song of 3 Young Men\",\n \"Susanna\",\n \"Bel and the Dragon\",\n \"1 Maccabees\",\n \"2 Maccabees\",\n \"3 Maccabees\",\n \"4 Maccabees\",\n \"1 Esdras (Greek)\",\n \"2 Esdras (Latin)\",\n \"Prayer of Manasseh\",\n \"Psalm 151\",\n \"Odes\",\n \"Psalms of Solomon\",\n // WARNING, if you change the spelling of the *obsolete* tag be sure to update\n // IsObsolete routine\n \"Joshua A. *obsolete*\",\n \"Judges B. *obsolete*\",\n \"Tobit S. *obsolete*\",\n \"Susanna Th. *obsolete*\",\n \"Daniel Th. *obsolete*\",\n \"Bel Th. *obsolete*\",\n \"Extra A\",\n \"Extra B\",\n \"Extra C\",\n \"Extra D\",\n \"Extra E\",\n \"Extra F\",\n \"Extra G\",\n \"Front Matter\",\n \"Back Matter\",\n \"Other Matter\",\n \"3 Ezra *obsolete*\",\n \"Apocalypse of Ezra\",\n \"5 Ezra (Latin Prologue)\",\n \"6 Ezra (Latin Epilogue)\",\n \"Introduction\",\n \"Concordance \",\n \"Glossary \",\n \"Topical Index\",\n \"Names Index\",\n \"Daniel Greek\",\n \"Psalms 152-155\",\n \"2 Baruch (Apocalypse)\",\n \"Letter of Baruch\",\n \"Jubilees\",\n \"Enoch\",\n \"1 Meqabyan\",\n \"2 Meqabyan\",\n \"3 Meqabyan\",\n \"Reproof (Proverbs 25-31)\",\n \"4 Baruch (Rest of Baruch)\",\n \"Laodiceans\"\n], S = K();\nfunction g(t, e = !0) {\n return e && (t = t.toUpperCase()), t in S ? S[t] : 0;\n}\nfunction k(t) {\n return g(t) > 0;\n}\nfunction x(t) {\n const e = typeof t == \"string\" ? g(t) : t;\n return e >= 40 && e <= 66;\n}\nfunction T(t) {\n return (typeof t == \"string\" ? g(t) : t) <= 39;\n}\nfunction X(t) {\n return t <= 66;\n}\nfunction V(t) {\n const e = typeof t == \"string\" ? g(t) : t;\n return w(e) && !X(e);\n}\nfunction* L() {\n for (let t = 1; t <= N.length; t++) yield t;\n}\nconst G = 1, A = N.length;\nfunction H() {\n return [\"XXA\", \"XXB\", \"XXC\", \"XXD\", \"XXE\", \"XXF\", \"XXG\"];\n}\nfunction C(t, e = \"***\") {\n const s = t - 1;\n return s < 0 || s >= N.length ? e : N[s];\n}\nfunction I(t) {\n return t <= 0 || t > A ? \"******\" : O[t - 1];\n}\nfunction y(t) {\n return I(g(t));\n}\nfunction w(t) {\n const e = typeof t == \"number\" ? C(t) : t;\n return k(e) && !B.includes(e);\n}\nfunction q(t) {\n const e = typeof t == \"number\" ? C(t) : t;\n return k(e) && B.includes(e);\n}\nfunction U(t) {\n return O[t - 1].includes(\"*obsolete*\");\n}\nfunction K() {\n const t = {};\n for (let e = 0; e < N.length; e++)\n t[N[e]] = e + 1;\n return t;\n}\nconst m = {\n allBookIds: N,\n nonCanonicalIds: B,\n bookIdToNumber: g,\n isBookIdValid: k,\n isBookNT: x,\n isBookOT: T,\n isBookOTNT: X,\n isBookDC: V,\n allBookNumbers: L,\n firstBook: G,\n lastBook: A,\n extraBooks: H,\n bookNumberToId: C,\n bookNumberToEnglishName: I,\n bookIdToEnglishName: y,\n isCanonical: w,\n isExtraMaterial: q,\n isObsolete: U\n};\nvar l = /* @__PURE__ */ ((t) => (t[t.Unknown = 0] = \"Unknown\", t[t.Original = 1] = \"Original\", t[t.Septuagint = 2] = \"Septuagint\", t[t.Vulgate = 3] = \"Vulgate\", t[t.English = 4] = \"English\", t[t.RussianProtestant = 5] = \"RussianProtestant\", t[t.RussianOrthodox = 6] = \"RussianOrthodox\", t))(l || {});\nconst h = class h {\n // private versInfo: Versification;\n constructor(e) {\n n(this, \"name\");\n n(this, \"fullPath\");\n n(this, \"isPresent\");\n n(this, \"hasVerseSegments\");\n n(this, \"isCustomized\");\n n(this, \"baseVersification\");\n n(this, \"scriptureBooks\");\n n(this, \"_type\");\n if (e == null)\n throw new Error(\"Argument undefined\");\n typeof e == \"string\" ? (this.name = e, this._type = l[e]) : (this._type = e, this.name = l[e]);\n }\n get type() {\n return this._type;\n }\n equals(e) {\n return !e.type || !this.type ? !1 : e.type === this.type;\n }\n};\nn(h, \"Original\", new h(l.Original)), n(h, \"Septuagint\", new h(l.Septuagint)), n(h, \"Vulgate\", new h(l.Vulgate)), n(h, \"English\", new h(l.English)), n(h, \"RussianProtestant\", new h(l.RussianProtestant)), n(h, \"RussianOrthodox\", new h(l.RussianOrthodox));\nlet c = h;\nfunction E(t, e) {\n const s = e[0];\n for (let r = 1; r < e.length; r++)\n t = t.split(e[r]).join(s);\n return t.split(s);\n}\nvar D = /* @__PURE__ */ ((t) => (t[t.Valid = 0] = \"Valid\", t[t.UnknownVersification = 1] = \"UnknownVersification\", t[t.OutOfRange = 2] = \"OutOfRange\", t[t.VerseOutOfOrder = 3] = \"VerseOutOfOrder\", t[t.VerseRepeated = 4] = \"VerseRepeated\", t))(D || {});\nconst i = class i {\n constructor(e, s, r, a) {\n /** Not yet implemented. */\n n(this, \"firstChapter\");\n /** Not yet implemented. */\n n(this, \"lastChapter\");\n /** Not yet implemented. */\n n(this, \"lastVerse\");\n /** Not yet implemented. */\n n(this, \"hasSegmentsDefined\");\n /** Not yet implemented. */\n n(this, \"text\");\n /** Not yet implemented. */\n n(this, \"BBBCCCVVVS\");\n /** Not yet implemented. */\n n(this, \"longHashCode\");\n /** The versification of the reference. */\n n(this, \"versification\");\n n(this, \"rtlMark\", \"‏\");\n n(this, \"_bookNum\", 0);\n n(this, \"_chapterNum\", 0);\n n(this, \"_verseNum\", 0);\n n(this, \"_verse\");\n if (r == null && a == null)\n if (e != null && typeof e == \"string\") {\n const o = e, u = s != null && s instanceof c ? s : void 0;\n this.setEmpty(u), this.parse(o);\n } else if (e != null && typeof e == \"number\") {\n const o = s != null && s instanceof c ? s : void 0;\n this.setEmpty(o), this._verseNum = e % i.chapterDigitShifter, this._chapterNum = Math.floor(\n e % i.bookDigitShifter / i.chapterDigitShifter\n ), this._bookNum = Math.floor(e / i.bookDigitShifter);\n } else if (s == null)\n if (e != null && e instanceof i) {\n const o = e;\n this._bookNum = o.bookNum, this._chapterNum = o.chapterNum, this._verseNum = o.verseNum, this._verse = o.verse, this.versification = o.versification;\n } else {\n if (e == null) return;\n const o = e instanceof c ? e : i.defaultVersification;\n this.setEmpty(o);\n }\n else\n throw new Error(\"VerseRef constructor not supported.\");\n else if (e != null && s != null && r != null)\n if (typeof e == \"string\" && typeof s == \"string\" && typeof r == \"string\")\n this.setEmpty(a), this.updateInternal(e, s, r);\n else if (typeof e == \"number\" && typeof s == \"number\" && typeof r == \"number\")\n this._bookNum = e, this._chapterNum = s, this._verseNum = r, this.versification = a ?? i.defaultVersification;\n else\n throw new Error(\"VerseRef constructor not supported.\");\n else\n throw new Error(\"VerseRef constructor not supported.\");\n }\n /**\n * Determines if the verse string is in a valid format (does not consider versification).\n */\n static isVerseParseable(e) {\n return e.length > 0 && \"0123456789\".includes(e[0]) && !e.endsWith(this.verseRangeSeparator) && !e.endsWith(this.verseSequenceIndicator);\n }\n /**\n * Tries to parse the specified string into a verse reference.\n * @param str - The string to attempt to parse.\n * @returns success: `true` if the specified string was successfully parsed, `false` otherwise.\n * @returns verseRef: The result of the parse if successful, or empty VerseRef if it failed\n */\n static tryParse(e) {\n let s;\n try {\n return s = new i(e), { success: !0, verseRef: s };\n } catch (r) {\n if (r instanceof v)\n return s = new i(), { success: !1, verseRef: s };\n throw r;\n }\n }\n /**\n * Gets the reference as a comparable integer where the book, chapter, and verse each occupy 3\n * digits.\n * @param bookNum - Book number (this is 1-based, not an index).\n * @param chapterNum - Chapter number.\n * @param verseNum - Verse number.\n * @returns The reference as a comparable integer where the book, chapter, and verse each occupy 3\n * digits.\n */\n static getBBBCCCVVV(e, s, r) {\n return e % i.bcvMaxValue * i.bookDigitShifter + (s >= 0 ? s % i.bcvMaxValue * i.chapterDigitShifter : 0) + (r >= 0 ? r % i.bcvMaxValue : 0);\n }\n /**\n * Deserializes a serialized VerseRef.\n * @param serializedVerseRef - Serialized VerseRef to create from.\n * @returns the deserialized VerseRef.\n */\n static fromJSON(e) {\n const { book: s, chapterNum: r, verseNum: a, verse: o, versificationStr: u } = e, f = o || a.toString();\n let d;\n return u && (d = new c(u)), s ? new i(s, r.toString(), f, d) : new i();\n }\n /**\n * Parses a verse string and gets the leading numeric portion as a number.\n * @param verseStr - verse string to parse\n * @returns true if the entire string could be parsed as a single, simple verse number (1-999);\n * false if the verse string represented a verse bridge, contained segment letters, or was invalid\n */\n static tryGetVerseNum(e) {\n let s;\n if (!e)\n return s = -1, { success: !0, vNum: s };\n s = 0;\n let r;\n for (let a = 0; a < e.length; a++) {\n if (r = e[a], r < \"0\" || r > \"9\")\n return a === 0 && (s = -1), { success: !1, vNum: s };\n if (s = s * 10 + +r - 0, s > i.bcvMaxValue)\n return s = -1, { success: !1, vNum: s };\n }\n return { success: !0, vNum: s };\n }\n /**\n * Checks to see if a VerseRef hasn't been set - all values are the default.\n */\n get isDefault() {\n return this.bookNum === 0 && this.chapterNum === 0 && this.verseNum === 0 && this.versification == null;\n }\n /**\n * Gets whether the verse contains multiple verses.\n */\n get hasMultiple() {\n return this._verse != null && (this._verse.includes(i.verseRangeSeparator) || this._verse.includes(i.verseSequenceIndicator));\n }\n /**\n * Gets or sets the book of the reference. Book is the 3-letter abbreviation in capital letters,\n * e.g. `'MAT'`.\n */\n get book() {\n return m.bookNumberToId(this.bookNum, \"\");\n }\n set book(e) {\n this.bookNum = m.bookIdToNumber(e);\n }\n /**\n * Gets or sets the chapter of the reference,. e.g. `'3'`.\n */\n get chapter() {\n return this.isDefault || this._chapterNum < 0 ? \"\" : this._chapterNum.toString();\n }\n set chapter(e) {\n const s = +e;\n this._chapterNum = Number.isInteger(s) ? s : -1;\n }\n /**\n * Gets or sets the verse of the reference, including range, segments, and sequences, e.g. `'4'`,\n * or `'4b-5a, 7'`.\n */\n get verse() {\n return this._verse != null ? this._verse : this.isDefault || this._verseNum < 0 ? \"\" : this._verseNum.toString();\n }\n set verse(e) {\n const { success: s, vNum: r } = i.tryGetVerseNum(e);\n this._verse = s ? void 0 : e.replace(this.rtlMark, \"\"), this._verseNum = r, !(this._verseNum >= 0) && ({ vNum: this._verseNum } = i.tryGetVerseNum(this._verse));\n }\n /**\n * Get or set Book based on book number, e.g. `42`.\n */\n get bookNum() {\n return this._bookNum;\n }\n set bookNum(e) {\n if (e <= 0 || e > m.lastBook)\n throw new v(\n \"BookNum must be greater than zero and less than or equal to last book\"\n );\n this._bookNum = e;\n }\n /**\n * Gets or sets the chapter number, e.g. `3`. `-1` if not valid.\n */\n get chapterNum() {\n return this._chapterNum;\n }\n set chapterNum(e) {\n this.chapterNum = e;\n }\n /**\n * Gets or sets verse start number, e.g. `4`. `-1` if not valid.\n */\n get verseNum() {\n return this._verseNum;\n }\n set verseNum(e) {\n this._verseNum = e;\n }\n /**\n * String representing the versification (should ONLY be used for serialization/deserialization).\n *\n * @remarks This is for backwards compatibility when ScrVers was an enumeration.\n */\n get versificationStr() {\n var e;\n return (e = this.versification) == null ? void 0 : e.name;\n }\n set versificationStr(e) {\n this.versification = this.versification != null ? new c(e) : void 0;\n }\n /**\n * Determines if the reference is valid.\n */\n get valid() {\n return this.validStatus === 0;\n }\n /**\n * Get the valid status for this reference.\n */\n get validStatus() {\n return this.validateVerse(i.verseRangeSeparators, i.verseSequenceIndicators);\n }\n /**\n * Gets the reference as a comparable integer where the book,\n * chapter, and verse each occupy three digits and the verse is 0.\n */\n get BBBCCC() {\n return i.getBBBCCCVVV(this._bookNum, this._chapterNum, 0);\n }\n /**\n * Gets the reference as a comparable integer where the book,\n * chapter, and verse each occupy three digits. If verse is not null\n * (i.e., this reference represents a complex reference with verse\n * segments or bridge) this cannot be used for an exact comparison.\n */\n get BBBCCCVVV() {\n return i.getBBBCCCVVV(this._bookNum, this._chapterNum, this._verseNum);\n }\n /**\n * Gets whether the verse is defined as an excluded verse in the versification.\n * Does not handle verse ranges.\n */\n // eslint-disable-next-line @typescript-eslint/class-literal-property-style\n get isExcluded() {\n return !1;\n }\n /**\n * Parses the reference in the specified string.\n * Optionally versification can follow reference as in GEN 3:11/4\n * Throw an exception if\n * - invalid book name\n * - chapter number is missing or not a number\n * - verse number is missing or does not start with a number\n * - versification is invalid\n * @param verseStr - string to parse e.g. 'MAT 3:11'\n */\n parse(e) {\n if (e = e.replace(this.rtlMark, \"\"), e.includes(\"/\")) {\n const o = e.split(\"/\");\n if (e = o[0], o.length > 1)\n try {\n const u = +o[1].trim();\n this.versification = new c(l[u]);\n } catch {\n throw new v(\"Invalid reference : \" + e);\n }\n }\n const s = e.trim().split(\" \");\n if (s.length !== 2)\n throw new v(\"Invalid reference : \" + e);\n const r = s[1].split(\":\"), a = +r[0];\n if (r.length !== 2 || m.bookIdToNumber(s[0]) === 0 || !Number.isInteger(a) || a < 0 || !i.isVerseParseable(r[1]))\n throw new v(\"Invalid reference : \" + e);\n this.updateInternal(s[0], r[0], r[1]);\n }\n /**\n * Simplifies this verse ref so that it has no bridging of verses or\n * verse segments like `'1a'`.\n */\n simplify() {\n this._verse = void 0;\n }\n /**\n * Makes a clone of the reference.\n *\n * @returns The cloned VerseRef.\n */\n clone() {\n return new i(this);\n }\n toString() {\n const e = this.book;\n return e === \"\" ? \"\" : `${e} ${this.chapter}:${this.verse}`;\n }\n toJSON() {\n let e = this.verse;\n (e === \"\" || e === this.verseNum.toString()) && (e = void 0);\n const s = {\n book: this.book,\n chapterNum: this.chapterNum,\n verseNum: this.verseNum,\n verse: e,\n versificationStr: this.versificationStr\n };\n return e || delete s.verse, s;\n }\n /**\n * Compares this `VerseRef` with supplied one.\n * @param verseRef - object to compare this one to.\n * @returns `true` if this `VerseRef` is equal to the supplied one, `false` otherwise.\n */\n equals(e) {\n return e instanceof i ? e._bookNum === this._bookNum && e._chapterNum === this._chapterNum && e._verseNum === this._verseNum && e.verse === this.verse && (e.versification == null && this.versification == null || e.versification != null && this.versification != null && e.versification.equals(this.versification)) : !1;\n }\n /**\n * Enumerate all individual verses contained in a VerseRef.\n * Verse ranges are indicated by \"-\" and consecutive verses by \",\"s.\n * Examples:\n * GEN 1:2 returns GEN 1:2\n * GEN 1:1a-3b,5 returns GEN 1:1a, GEN 1:2, GEN 1:3b, GEN 1:5\n * GEN 1:2a-2c returns //! ??????\n *\n * @param specifiedVersesOnly - if set to true return only verses that are\n * explicitly specified only, not verses within a range. Defaults to `false`.\n * @param verseRangeSeparators - Verse range separators.\n * Defaults to `VerseRef.verseRangeSeparators`.\n * @param verseSequenceSeparators - Verse sequence separators.\n * Defaults to `VerseRef.verseSequenceIndicators`.\n * @returns An array of all single verse references in this VerseRef.\n */\n allVerses(e = !1, s = i.verseRangeSeparators, r = i.verseSequenceIndicators) {\n if (this._verse == null || this.chapterNum <= 0)\n return [this.clone()];\n const a = [], o = E(this._verse, r);\n for (const u of o.map((f) => E(f, s))) {\n const f = this.clone();\n f.verse = u[0];\n const d = f.verseNum;\n if (a.push(f), u.length > 1) {\n const b = this.clone();\n if (b.verse = u[1], !e)\n for (let p = d + 1; p < b.verseNum; p++) {\n const J = new i(\n this._bookNum,\n this._chapterNum,\n p,\n this.versification\n );\n this.isExcluded || a.push(J);\n }\n a.push(b);\n }\n }\n return a;\n }\n /**\n * Validates a verse number using the supplied separators rather than the defaults.\n */\n validateVerse(e, s) {\n if (!this.verse)\n return this.internalValid;\n let r = 0;\n for (const a of this.allVerses(!0, e, s)) {\n const o = a.internalValid;\n if (o !== 0)\n return o;\n const u = a.BBBCCCVVV;\n if (r > u)\n return 3;\n if (r === u)\n return 4;\n r = u;\n }\n return 0;\n }\n /**\n * Gets whether a single verse reference is valid.\n */\n get internalValid() {\n return this.versification == null ? 1 : this._bookNum <= 0 || this._bookNum > m.lastBook ? 2 : (m.isCanonical(this._bookNum), 0);\n }\n setEmpty(e = i.defaultVersification) {\n this._bookNum = 0, this._chapterNum = -1, this._verse = void 0, this.versification = e;\n }\n updateInternal(e, s, r) {\n this.bookNum = m.bookIdToNumber(e), this.chapter = s, this.verse = r;\n }\n};\nn(i, \"defaultVersification\", c.English), n(i, \"verseRangeSeparator\", \"-\"), n(i, \"verseSequenceIndicator\", \",\"), n(i, \"verseRangeSeparators\", [i.verseRangeSeparator]), n(i, \"verseSequenceIndicators\", [i.verseSequenceIndicator]), n(i, \"chapterDigitShifter\", 1e3), n(i, \"bookDigitShifter\", i.chapterDigitShifter * i.chapterDigitShifter), n(i, \"bcvMaxValue\", i.chapterDigitShifter - 1), /**\n * The valid status of the VerseRef.\n */\nn(i, \"ValidStatusType\", D);\nlet M = i;\nclass v extends Error {\n}\nexport {\n _ as BookSet,\n m as Canon,\n c as ScrVers,\n l as ScrVersType,\n M as VerseRef,\n v as VerseRefException\n};\n//# sourceMappingURL=index.es.js.map\n","import React from 'react';\nimport * as DropdownMenuPrimitive from '@radix-ui/react-dropdown-menu';\nimport { Check, ChevronRight, Circle } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport const DropdownMenu = DropdownMenuPrimitive.Root;\n\nexport const DropdownMenuTrigger = DropdownMenuPrimitive.Trigger;\n\nexport const DropdownMenuGroup = DropdownMenuPrimitive.Group;\n\nexport const DropdownMenuPortal = DropdownMenuPrimitive.Portal;\n\nexport const DropdownMenuSub = DropdownMenuPrimitive.Sub;\n\nexport const DropdownMenuRadioGroup = DropdownMenuPrimitive.RadioGroup;\n\nexport type DropdownMenuSubTriggerProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.SubTrigger\n> & {\n className?: string;\n inset?: boolean;\n};\n\nexport type DropdownMenuSubContentProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.SubContent\n> & {\n className?: string;\n};\n\nexport type DropdownMenuContentProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Content\n> & {\n className?: string;\n sideOffset?: number;\n};\n\nexport type DropdownMenuItemProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Item\n> & {\n className?: string;\n inset?: boolean;\n};\n\nexport type DropdownMenuCheckboxItemProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.CheckboxItem\n> & {\n className?: string;\n checked?: boolean;\n};\n\nexport type DropdownMenuRadioItemProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.RadioItem\n> & {\n className?: string;\n};\n\nexport type DropdownMenuLabelProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Label\n> & {\n className?: string;\n inset?: boolean;\n};\n\nexport type DropdownMenuSeparatorProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Separator\n> & {\n className?: string;\n};\n\nexport type DropdownMenuShortcutProps = React.HTMLAttributes & {\n className?: string;\n};\n\nexport const DropdownMenuSubTrigger = React.forwardRef<\n React.ElementRef,\n DropdownMenuSubTriggerProps\n>(({ className, inset, children, ...props }, ref) => (\n \n {children}\n \n \n));\nDropdownMenuSubTrigger.displayName = DropdownMenuPrimitive.SubTrigger.displayName;\n\nexport const DropdownMenuSubContent = React.forwardRef<\n React.ElementRef,\n DropdownMenuSubContentProps\n>(({ className, ...props }, ref) => (\n \n));\nDropdownMenuSubContent.displayName = DropdownMenuPrimitive.SubContent.displayName;\n\nexport const DropdownMenuContent = React.forwardRef<\n React.ElementRef,\n DropdownMenuContentProps\n>(({ className, sideOffset = 4, ...props }, ref) => (\n \n \n \n));\nDropdownMenuContent.displayName = DropdownMenuPrimitive.Content.displayName;\n\n/**\n * TODO: fix: direction is not automatically handled by this component, so that shortcuts are\n * display always to the right\n */\nexport const DropdownMenuItem = React.forwardRef<\n React.ElementRef,\n DropdownMenuItemProps\n>(({ className, inset, ...props }, ref) => (\n \n));\nDropdownMenuItem.displayName = DropdownMenuPrimitive.Item.displayName;\n\nexport const DropdownMenuCheckboxItem = React.forwardRef<\n React.ElementRef,\n DropdownMenuCheckboxItemProps\n>(({ className, children, checked, ...props }, ref) => (\n \n \n \n \n \n \n {children}\n \n));\nDropdownMenuCheckboxItem.displayName = DropdownMenuPrimitive.CheckboxItem.displayName;\n\nexport const DropdownMenuRadioItem = React.forwardRef<\n React.ElementRef,\n DropdownMenuRadioItemProps\n>(({ className, children, ...props }, ref) => (\n \n \n \n \n \n \n {children}\n \n));\nDropdownMenuRadioItem.displayName = DropdownMenuPrimitive.RadioItem.displayName;\n\nexport const DropdownMenuLabel = React.forwardRef<\n React.ElementRef,\n DropdownMenuLabelProps\n>(({ className, inset, ...props }, ref) => (\n \n));\nDropdownMenuLabel.displayName = DropdownMenuPrimitive.Label.displayName;\n\nexport const DropdownMenuSeparator = React.forwardRef<\n React.ElementRef,\n DropdownMenuSeparatorProps\n>(({ className, ...props }, ref) => (\n \n));\nDropdownMenuSeparator.displayName = DropdownMenuPrimitive.Separator.displayName;\n\nexport function DropdownMenuShortcut({ className, ...props }: DropdownMenuShortcutProps) {\n return (\n \n );\n}\nDropdownMenuShortcut.displayName = 'DropdownMenuShortcut';\n","import { Canon } from '@sillsdev/scripture';\nimport { PropsWithChildren, KeyboardEvent, forwardRef } from 'react';\nimport { DropdownMenuItem as ShadDropdownMenuItem } from '@/components/shadcn-ui/dropdown-menu';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport type BookType = 'OT' | 'NT' | 'DC';\n\ntype BookMenuItemProps = PropsWithChildren<{\n /** String id of book */\n bookId: string;\n /** Callback to run when a book menu item is selected */\n handleSelectBook: () => void;\n /** Indicates if this menu item is currently selected */\n isSelected: boolean;\n /** Function that is called upon highlighting a book in the dropdown menu */\n handleHighlightBook: () => void;\n /**\n * Function that is called on pressing a key\n *\n * @param event Event that contains information about the key stroke\n */\n handleKeyDown: (event: KeyboardEvent) => void;\n /**\n * Type of book associated with this menu item, coordinates color labels ? Mock up has the labels\n * coordinated to genre\n */\n bookType: BookType;\n}>;\n\nconst BookMenuItem = forwardRef(\n (\n {\n bookId,\n handleSelectBook,\n isSelected,\n handleHighlightBook,\n handleKeyDown,\n bookType,\n children,\n }: BookMenuItemProps,\n ref,\n ) => {\n return (\n {\n // preventDefault() here prevents the entire dropdown menu from closing when selecting this item\n event.preventDefault();\n handleSelectBook();\n }}\n onKeyDown={(event: KeyboardEvent) => {\n handleKeyDown(event);\n }}\n onFocus={handleHighlightBook}\n onMouseMove={handleHighlightBook}\n >\n \n {Canon.bookIdToEnglishName(bookId)}\n \n {isSelected &&
    {children}
    }\n \n );\n },\n);\n\nexport default BookMenuItem;\n","import { cn } from '@/utils/shadcn-ui.util';\nimport { useCallback } from 'react';\n\nexport type ChapterSelectProps = {\n /**\n * Callback to run when a chapter div is selected\n *\n * @param chapterNumber Number of the chapter that has been selected\n */\n handleSelectChapter: (chapterNumber: number) => void;\n /** The highest chapter number in the book (of course equal to number of chapters in the book) */\n endChapter: number;\n /** The chapter number that is currently selected */\n activeChapter: number;\n /** The chapter number that is currently highlighted using keyboard or mouse navigation */\n highlightedChapter: number;\n /**\n * Callback to run when a chapter is highlighted by the user\n *\n * @param chapterNumber The chapter that is highlighted\n */\n handleHighlightedChapter: (chapterNumber: number) => void;\n};\n\nfunction ChapterSelect({\n handleSelectChapter,\n endChapter,\n activeChapter,\n highlightedChapter,\n handleHighlightedChapter,\n}: ChapterSelectProps) {\n const chapters = Array.from({ length: endChapter }, (_, i) => i + 1);\n\n const handleMouse = useCallback(\n (chapterNumber: number) => {\n handleHighlightedChapter(chapterNumber);\n },\n [handleHighlightedChapter],\n );\n\n return (\n
    \n {chapters.map((chapter) => (\n {\n event.preventDefault();\n event.stopPropagation();\n handleSelectChapter(chapter);\n }}\n role=\"button\"\n onKeyDown={(event) => {\n if (event.key === 'Enter') {\n handleSelectChapter(chapter);\n }\n }}\n tabIndex={0}\n onMouseMove={() => handleMouse(chapter)}\n >\n {chapter}\n
    \n ))}\n
    \n );\n}\n\nexport default ChapterSelect;\n","import { DropdownMenuLabel as ShadDropdownMenuLabel } from '@/components/shadcn-ui/dropdown-menu';\nimport { Bookmark, Clock, ArrowDownWideNarrow } from 'lucide-react';\n\nexport type GoToMenuItemProps = {\n handleSort: () => void;\n handleLocationHistory: () => void;\n handleBookmarks: () => void;\n};\n\nfunction GoToMenuItem({ handleSort, handleLocationHistory, handleBookmarks }: GoToMenuItemProps) {\n return (\n \n

    Go To

    \n
    \n \n \n \n
    \n
    \n );\n}\n\nexport default GoToMenuItem;\n","import BookChapterInput from '@/components/advanced/book-chapter-control/book-chapter-input.component';\nimport BookMenuItem, {\n BookType,\n} from '@/components/advanced/book-chapter-control/book-menu-item.component';\nimport ChapterSelect from '@/components/advanced/book-chapter-control/chapter-select.component';\nimport GoToMenuItem from '@/components/advanced/book-chapter-control/go-to-menu-item.component';\nimport {\n DropdownMenu as ShadDropdownMenu,\n DropdownMenuContent as ShadDropdownMenuContent,\n DropdownMenuLabel as ShadDropdownMenuLabel,\n DropdownMenuSeparator as ShadDropdownMenuSeparator,\n DropdownMenuTrigger as ShadDropdownMenuTrigger,\n} from '@/components/shadcn-ui/dropdown-menu';\nimport { Canon } from '@sillsdev/scripture';\nimport { ScriptureReference, getChaptersForBook } from 'platform-bible-utils';\nimport {\n KeyboardEvent as ReactKeyboardEvent,\n useCallback,\n useEffect,\n useLayoutEffect,\n useRef,\n useState,\n} from 'react';\n\ntype BookTypeLabels = {\n [bookType in BookType]: string;\n};\ntype BookChapterControlProps = {\n scrRef: ScriptureReference;\n handleSubmit: (scrRef: ScriptureReference) => void;\n};\n\nconst ALL_BOOK_IDS = Canon.allBookIds;\nconst BOOK_TYPE_LABELS: BookTypeLabels = {\n OT: 'Old Testament',\n NT: 'New Testament',\n DC: 'Deuterocanon',\n};\nconst BOOK_TYPE_ARRAY: BookType[] = ['OT', 'NT', 'DC'];\n// This is the height of three menu items to offset scrolling to the selected menu item\n// If you use menuItemRef.clientHeight- includes height of chapter div which is too big\nconst SCROLL_OFFSET = 32 + 32 + 32;\nconst SEARCH_QUERY_FORMATS = [\n /^(\\w+)$/i, // Matches a single word (book name or id)\n /^(\\w+)(?:\\s(\\d+))$/i, // Matches a word followed by a chapter number\n /^(\\w+)(?:\\s(\\d+):(\\d+))$/i, // Matches a word followed by a chapter and verse number\n];\nconst fetchGroupedBooks = (bookType: BookType) => {\n const groupedBooks = {\n OT: ALL_BOOK_IDS.filter((bookId) => Canon.isBookOT(bookId)),\n NT: ALL_BOOK_IDS.filter((bookId) => Canon.isBookNT(bookId)),\n DC: ALL_BOOK_IDS.filter((bookId) => Canon.isBookDC(bookId)),\n };\n return groupedBooks[bookType];\n};\nconst fetchEndChapter = (bookId: string) => {\n // getChaptersForBook returns -1 if not found in scrBookData\n // scrBookData only includes OT and NT, so all DC will return -1\n return getChaptersForBook(Canon.bookIdToNumber(bookId));\n};\n\n/**\n * Gets all of the English names from book ids\n *\n * @returns String[]\n */\nfunction getAllEnglishNames(): string[] {\n const allEnglishNames = ALL_BOOK_IDS.map((bookId) => {\n return Canon.bookIdToEnglishName(bookId);\n });\n return allEnglishNames;\n}\n\n/**\n * Determines if bookName is in allEnglishNames\n *\n * @param bookName Book English name\n * @returns True if bookName is included, false otherwise\n */\nfunction isValidBookEnglishName(bookName: string): boolean {\n return getAllEnglishNames().includes(bookName);\n}\n\n/**\n * Gets a bookId from given English name\n *\n * @param bookName Book English name\n * @returns BookId of provided bookName, undefined otherwise\n */\nfunction getBookIdFromEnglishName(bookName: string): string | undefined {\n // Convert bookName to lowercase and then capitalize the first letter\n const formattedBookName = bookName.toLowerCase().replace(/^\\w/, (c) => c.toUpperCase());\n\n if (isValidBookEnglishName(formattedBookName)) {\n const matchingBookId = ALL_BOOK_IDS.find((bookId) => {\n return Canon.bookIdToEnglishName(bookId) === formattedBookName;\n });\n return matchingBookId;\n }\n\n return undefined;\n}\n\nfunction BookChapterControl({ scrRef, handleSubmit }: BookChapterControlProps) {\n const [searchQuery, setSearchQuery] = useState('');\n const [selectedBookId, setSelectedBookId] = useState(\n Canon.bookNumberToId(scrRef.bookNum),\n );\n const [highlightedChapter, setHighlightedChapter] = useState(scrRef.chapterNum ?? 0);\n const [highlightedBookId, setHighlightedBookId] = useState(\n Canon.bookNumberToId(scrRef.bookNum),\n );\n const [isContentOpen, setIsContentOpen] = useState(false);\n const [isContentOpenDelayed, setIsContentOpenDelayed] = useState(isContentOpen);\n\n // This ref will always be defined\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const inputRef = useRef(undefined!);\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const contentRef = useRef(undefined!);\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const menuItemRef = useRef(undefined!);\n\n const fetchFilteredBooks = useCallback(\n (bookType: BookType) => {\n return fetchGroupedBooks(bookType).filter((bookId: string) => {\n const englishNameLowerCase = Canon.bookIdToEnglishName(bookId).toLowerCase();\n const normalizedQuery = searchQuery.replace(/[^a-zA-Z]/g, '').toLowerCase();\n return (\n englishNameLowerCase.includes(normalizedQuery) || // Match book name\n bookId.toLowerCase().includes(normalizedQuery) // Match book ID\n );\n });\n },\n [searchQuery],\n );\n\n const handleSearchInput = (searchString: string) => {\n setSearchQuery(searchString);\n };\n\n /**\n * Whether to prevent radix's logic from closing the dropdown. This is important because radix\n * tries to close the dropdown when the input first focuses, and we don't want it to do that. But\n * we don't want to prevent the dropdown from closing when we click away from the input, so we\n * don't want to just keep it open if the input is focused\n */\n const shouldPreventAutoClosing = useRef(false);\n\n const controlMenuState = useCallback((open: boolean) => {\n if (shouldPreventAutoClosing.current) {\n shouldPreventAutoClosing.current = false;\n return;\n }\n setIsContentOpen(open);\n }, []);\n\n const updateReference = useCallback(\n (bookId: string, shouldClose: boolean, chapter?: number, verse?: number) => {\n setHighlightedChapter(\n Canon.bookNumberToId(scrRef.bookNum) !== bookId ? 1 : scrRef.chapterNum,\n );\n\n if (shouldClose || fetchEndChapter(bookId) === -1) {\n handleSubmit({\n bookNum: Canon.bookIdToNumber(bookId),\n chapterNum: chapter || 1,\n verseNum: verse || 1,\n });\n\n setIsContentOpen(false);\n setSearchQuery('');\n return;\n }\n\n setSelectedBookId(selectedBookId !== bookId ? bookId : '');\n setIsContentOpen(!shouldClose);\n },\n [handleSubmit, scrRef.bookNum, scrRef.chapterNum, selectedBookId],\n );\n\n const handleSelectChapter = (chapterNumber: number) => {\n if (chapterNumber <= 0 || chapterNumber > fetchEndChapter(selectedBookId)) {\n return;\n }\n updateReference(selectedBookId, true, chapterNumber);\n };\n\n const handleInputSubmit = useCallback(() => {\n SEARCH_QUERY_FORMATS.forEach((format) => {\n const matches = searchQuery.match(format);\n if (matches) {\n // Book should be a bookId or an english name\n const [book, chapter = undefined, verse = undefined] = matches.slice(1);\n const englishName = getBookIdFromEnglishName(book);\n\n if (Canon.isBookIdValid(book) || englishName) {\n updateReference(\n englishName ?? book,\n true,\n chapter ? parseInt(chapter, 10) : 1,\n verse ? parseInt(verse, 10) : 1,\n );\n }\n }\n });\n }, [updateReference, searchQuery]);\n\n const handleKeyDownInput = useCallback(\n (event: ReactKeyboardEvent) => {\n if (!isContentOpen) {\n setIsContentOpen(true);\n } else if (event.key === 'ArrowDown' || event.key === 'ArrowUp') {\n if (\n typeof menuItemRef !== 'undefined' &&\n // Ref uses null\n // eslint-disable-next-line no-null/no-null\n menuItemRef.current !== null\n ) {\n menuItemRef.current.focus();\n } else if (\n typeof contentRef !== 'undefined' &&\n // Ref uses null\n // eslint-disable-next-line no-null/no-null\n contentRef.current !== null\n ) {\n contentRef.current.focus();\n }\n event.preventDefault();\n }\n },\n [isContentOpen],\n );\n\n const handleKeyDownContent = (event: ReactKeyboardEvent) => {\n // When the dropdown menu has focus, key strokes should give focus to the input component,\n // unless they're navigation keys (arrows and enter)\n const { key } = event;\n if (\n key === 'ArrowRight' ||\n key === 'ArrowLeft' ||\n key === 'ArrowDown' ||\n key === 'ArrowUp' ||\n key === 'Enter'\n ) {\n return;\n }\n\n inputRef.current.dispatchEvent(new KeyboardEvent('keydown', { key }));\n inputRef.current.focus();\n };\n\n const handleKeyDownMenuItem = (event: ReactKeyboardEvent) => {\n const { key } = event;\n if (highlightedBookId === selectedBookId) {\n if (key === 'Enter') {\n event.preventDefault();\n updateReference(selectedBookId, true, highlightedChapter);\n return;\n }\n\n let chapterOffSet = 0;\n if (key === 'ArrowRight') {\n if (highlightedChapter < fetchEndChapter(highlightedBookId)) {\n chapterOffSet = 1;\n } else {\n event.preventDefault();\n return;\n }\n } else if (key === 'ArrowLeft') {\n if (highlightedChapter > 1) {\n chapterOffSet = -1;\n } else {\n event.preventDefault();\n return;\n }\n } else if (key === 'ArrowDown') {\n chapterOffSet = 6;\n } else if (key === 'ArrowUp') {\n chapterOffSet = -6;\n }\n if (\n highlightedChapter + chapterOffSet <= 0 ||\n highlightedChapter + chapterOffSet > fetchEndChapter(highlightedBookId)\n ) {\n setHighlightedChapter(0);\n } else if (chapterOffSet !== 0) {\n setHighlightedChapter(highlightedChapter + chapterOffSet);\n event.preventDefault();\n }\n }\n };\n\n useEffect(() => {\n if (selectedBookId === highlightedBookId) {\n if (selectedBookId === Canon.bookNumberToId(scrRef.bookNum)) {\n setHighlightedChapter(scrRef.chapterNum);\n } else {\n setHighlightedChapter(1);\n }\n } else {\n setHighlightedChapter(0);\n }\n }, [highlightedBookId, scrRef.bookNum, scrRef.chapterNum, selectedBookId]);\n\n // The purpose of these useLayoutEffects and timeout is to delay the scroll just\n // enough so that the refs are defined and available when they are used after the timeout\n useLayoutEffect(() => {\n setIsContentOpenDelayed(isContentOpen);\n }, [isContentOpen]);\n\n useLayoutEffect(() => {\n const scrollTimeout = setTimeout(() => {\n if (isContentOpenDelayed && contentRef.current && menuItemRef.current) {\n const menuItemOffsetTop = menuItemRef.current.offsetTop;\n const scrollPosition = menuItemOffsetTop - SCROLL_OFFSET;\n contentRef.current.scrollTo({ top: scrollPosition, behavior: 'instant' });\n }\n }, 10);\n return () => {\n clearTimeout(scrollTimeout);\n };\n }, [isContentOpenDelayed]);\n\n return (\n
    \n \n \n {\n setSelectedBookId(Canon.bookNumberToId(scrRef.bookNum));\n setHighlightedBookId(Canon.bookNumberToId(scrRef.bookNum));\n setHighlightedChapter(scrRef.chapterNum > 0 ? scrRef.chapterNum : 0);\n setIsContentOpen(true);\n inputRef.current.focus();\n }}\n onFocus={() => {\n // Radix thinks we want to close because the input is being focused. Prevent that\n shouldPreventAutoClosing.current = true;\n }}\n handleSubmit={handleInputSubmit}\n placeholder={`${Canon.bookNumberToEnglishName(scrRef.bookNum)} ${scrRef.chapterNum}:${scrRef.verseNum}`}\n />\n \n \n console.log('sorting')}\n handleLocationHistory={() => console.log('location history')}\n handleBookmarks={() => console.log('bookmarks')}\n />\n {BOOK_TYPE_ARRAY.map(\n (bookType, bookTypeIndex) =>\n fetchFilteredBooks(bookType).length > 0 && (\n
    \n \n {BOOK_TYPE_LABELS[bookType]}\n \n\n {fetchFilteredBooks(bookType).map((bookId) => (\n
    \n updateReference(bookId, false)}\n isSelected={selectedBookId === bookId}\n handleHighlightBook={() => setHighlightedBookId(bookId)}\n handleKeyDown={handleKeyDownMenuItem}\n bookType={bookType}\n ref={(element: HTMLDivElement) => {\n if (selectedBookId === bookId) menuItemRef.current = element;\n }}\n >\n {\n setHighlightedChapter(chapterNumber);\n }}\n />\n \n
    \n ))}\n {BOOK_TYPE_ARRAY.length - 1 !== bookTypeIndex ? (\n \n ) : undefined}\n
    \n ),\n )}\n \n
    \n
    \n );\n}\n\nexport default BookChapterControl;\n","import React from 'react';\nimport { Slot } from '@radix-ui/react-slot';\nimport { cva, type VariantProps } from 'class-variance-authority';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport const buttonVariants = cva(\n 'pr-twp tw-inline-flex tw-items-center tw-justify-center tw-whitespace-nowrap tw-rounded-md tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-colors focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50',\n {\n variants: {\n variant: {\n default: 'tw-bg-primary tw-text-primary-foreground hover:tw-bg-primary/90',\n destructive: 'tw-bg-destructive tw-text-destructive-foreground hover:tw-bg-destructive/90',\n outline:\n 'tw-border tw-border-input tw-bg-background hover:tw-bg-accent hover:tw-text-accent-foreground',\n secondary: 'tw-bg-secondary tw-text-secondary-foreground hover:tw-bg-secondary/80',\n ghost: 'hover:tw-bg-accent hover:tw-text-accent-foreground',\n link: 'tw-text-primary tw-underline-offset-4 hover:tw-underline',\n },\n size: {\n default: 'tw-h-10 tw-px-4 tw-py-2',\n sm: 'tw-h-9 tw-rounded-md tw-px-3',\n lg: 'tw-h-11 tw-rounded-md tw-px-8',\n icon: 'tw-h-10 tw-w-10',\n },\n },\n defaultVariants: {\n variant: 'default',\n size: 'default',\n },\n },\n);\n\nexport interface ButtonProps\n extends React.ButtonHTMLAttributes,\n VariantProps {\n asChild?: boolean;\n}\n\nexport const Button = React.forwardRef(\n ({ className, variant, size, asChild = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'button';\n return (\n \n );\n },\n);\nButton.displayName = 'Button';\n","import React from 'react';\nimport * as LabelPrimitive from '@radix-ui/react-label';\nimport { cva, type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst labelVariants = cva(\n 'tw-text-sm tw-font-medium tw-leading-none peer-disabled:tw-cursor-not-allowed peer-disabled:tw-opacity-70',\n);\n\nexport const Label = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef & VariantProps\n>(({ className, ...props }, ref) => (\n \n));\nLabel.displayName = LabelPrimitive.Root.displayName;\n","import React from 'react';\nimport * as RadioGroupPrimitive from '@radix-ui/react-radio-group';\nimport { Circle } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst RadioGroup = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => {\n return (\n \n );\n});\nRadioGroup.displayName = RadioGroupPrimitive.Root.displayName;\n\nconst RadioGroupItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => {\n return (\n \n \n \n \n \n );\n});\nRadioGroupItem.displayName = RadioGroupPrimitive.Item.displayName;\n\nexport { RadioGroup, RadioGroupItem };\n","import React from 'react';\nimport * as PopoverPrimitive from '@radix-ui/react-popover';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Popover = PopoverPrimitive.Root;\n\nconst PopoverTrigger = PopoverPrimitive.Trigger;\n\nconst PopoverContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, align = 'center', sideOffset = 4, ...props }, ref) => (\n \n \n \n));\nPopoverContent.displayName = PopoverPrimitive.Content.displayName;\n\nexport { Popover, PopoverTrigger, PopoverContent };\n","import React from 'react';\nimport * as DialogPrimitive from '@radix-ui/react-dialog';\nimport { X } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Dialog = DialogPrimitive.Root;\n\nconst DialogTrigger = DialogPrimitive.Trigger;\n\nconst DialogPortal = DialogPrimitive.Portal;\n\nconst DialogClose = DialogPrimitive.Close;\n\nconst DialogOverlay = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nDialogOverlay.displayName = DialogPrimitive.Overlay.displayName;\n\nconst DialogContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, ...props }, ref) => (\n \n \n \n {children}\n \n \n Close\n \n \n \n));\nDialogContent.displayName = DialogPrimitive.Content.displayName;\n\nfunction DialogHeader({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nDialogHeader.displayName = 'DialogHeader';\n\nfunction DialogFooter({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nDialogFooter.displayName = 'DialogFooter';\n\nconst DialogTitle = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nDialogTitle.displayName = DialogPrimitive.Title.displayName;\n\nconst DialogDescription = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nDialogDescription.displayName = DialogPrimitive.Description.displayName;\n\nexport {\n Dialog,\n DialogPortal,\n DialogOverlay,\n DialogClose,\n DialogTrigger,\n DialogContent,\n DialogHeader,\n DialogFooter,\n DialogTitle,\n DialogDescription,\n};\n","import React from 'react';\nimport { type DialogProps } from '@radix-ui/react-dialog';\nimport { Command as CommandPrimitive } from 'cmdk';\nimport { Search } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Dialog, DialogContent } from '@/components/shadcn-ui/dialog';\n\nconst Command = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nCommand.displayName = CommandPrimitive.displayName;\n\ninterface CommandDialogProps extends DialogProps {}\n\nfunction CommandDialog({ children, ...props }: CommandDialogProps) {\n return (\n \n \n \n {children}\n \n \n \n );\n}\n\nconst CommandInput = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n
    \n \n \n
    \n));\n\nCommandInput.displayName = CommandPrimitive.Input.displayName;\n\nconst CommandList = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\n\nCommandList.displayName = CommandPrimitive.List.displayName;\n\nconst CommandEmpty = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>((props, ref) => (\n \n));\n\nCommandEmpty.displayName = CommandPrimitive.Empty.displayName;\n\nconst CommandGroup = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\n\nCommandGroup.displayName = CommandPrimitive.Group.displayName;\n\nconst CommandSeparator = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nCommandSeparator.displayName = CommandPrimitive.Separator.displayName;\n\nconst CommandItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\n\nCommandItem.displayName = CommandPrimitive.Item.displayName;\n\nfunction CommandShortcut({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nCommandShortcut.displayName = 'CommandShortcut';\n\nexport {\n Command,\n CommandDialog,\n CommandInput,\n CommandList,\n CommandEmpty,\n CommandGroup,\n CommandItem,\n CommandShortcut,\n CommandSeparator,\n};\n","import { useState } from 'react';\nimport { Check, ChevronsUpDown } from 'lucide-react';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport { Popover, PopoverContent, PopoverTrigger } from '@/components/shadcn-ui/popover';\nimport {\n Command,\n CommandEmpty,\n CommandInput,\n CommandItem,\n CommandList,\n} from '@/components/shadcn-ui/command';\nimport { PopoverProps } from '@radix-ui/react-popover';\n\nexport type ComboBoxLabelOption = { label: string };\nexport type ComboBoxOption = string | number | ComboBoxLabelOption;\n\nexport type ComboBoxProps = {\n /** Optional unique identifier */\n id?: string;\n /** Text label title for combobox */\n /** List of available options for the dropdown menu */\n options?: readonly T[];\n /** @deprecated 3 December 2024. Renamed to {@link buttonClassName} */\n className?: string;\n /** Additional css classes to help with unique styling of the combo box button */\n buttonClassName?: string;\n /** Additional css classes to help with unique styling of the combo box popover */\n popoverContentClassName?: string;\n /**\n * The selected value that the combo box currently holds. Must be shallow equal to one of the\n * options entries.\n */\n value?: T;\n /** Triggers when content of textfield is changed */\n onChange?: (newValue: T) => void;\n /** Used to determine the string value for a given option. */\n getOptionLabel?: (option: ComboBoxOption) => string;\n /** Text displayed on button if `value` is undefined */\n buttonPlaceholder?: string;\n /** Placeholder text for text field */\n textPlaceholder?: string;\n /** Text to display when no options match input */\n commandEmptyMessage?: string;\n /** Variant of button */\n buttonVariant?: ButtonProps['variant'];\n /** Text direction ltr or rtl */\n dir?: Direction;\n /** Optional boolean to set if trigger should be disabled */\n isDisabled?: boolean;\n} & PopoverProps;\n\ntype Direction = 'ltr' | 'rtl';\n\nfunction getOptionLabelDefault(option: ComboBoxOption): string {\n if (typeof option === 'string') {\n return option;\n }\n if (typeof option === 'number') {\n return option.toString();\n }\n return option.label;\n}\n\n/**\n * Autocomplete input and command palette with a list of suggestions.\n *\n * Thanks to Shadcn for heavy inspiration and documentation\n * https://ui.shadcn.com/docs/components/combobox\n */\nfunction ComboBox({\n id,\n options = [],\n buttonClassName,\n popoverContentClassName,\n value,\n onChange = () => {},\n getOptionLabel = getOptionLabelDefault,\n buttonPlaceholder = '',\n textPlaceholder = '',\n commandEmptyMessage = 'No option found',\n buttonVariant = 'outline',\n dir = 'ltr',\n isDisabled = false,\n ...props\n}: ComboBoxProps) {\n const [open, setOpen] = useState(false);\n\n return (\n \n \n \n \n {value ? getOptionLabel(value) : buttonPlaceholder}\n \n \n \n \n \n \n \n {commandEmptyMessage}\n \n {options.map((option) => (\n {\n onChange(option);\n setOpen(false);\n }}\n >\n \n {getOptionLabel(option)}\n \n ))}\n \n \n \n \n );\n}\n\nexport default ComboBox;\n","import { useMemo } from 'react';\nimport ComboBox from '@/components/basics/combo-box.component';\nimport { Label } from '@/components/shadcn-ui/label';\n\nexport type ChapterRangeSelectorProps = {\n startChapter: number;\n endChapter: number;\n handleSelectStartChapter: (chapter: number) => void;\n handleSelectEndChapter: (chapter: number) => void;\n isDisabled?: boolean;\n chapterCount: number;\n};\n\nexport default function ChapterRangeSelector({\n startChapter,\n endChapter,\n handleSelectStartChapter,\n handleSelectEndChapter,\n isDisabled = false,\n chapterCount,\n}: ChapterRangeSelectorProps) {\n const chapterOptions = useMemo(\n () => Array.from({ length: chapterCount }, (_, index) => index + 1),\n [chapterCount],\n );\n\n const onChangeStartChapter = (value: number) => {\n handleSelectStartChapter(value);\n if (value > endChapter) {\n handleSelectEndChapter(value);\n }\n };\n\n const onChangeEndChapter = (value: number) => {\n handleSelectEndChapter(value);\n if (value < startChapter) {\n handleSelectStartChapter(value);\n }\n };\n\n return (\n <>\n \n option.toString()}\n value={startChapter}\n />\n\n \n option.toString()}\n value={endChapter}\n />\n \n );\n}\n","import { Button } from '@/components/shadcn-ui/button';\nimport { Label } from '@/components/shadcn-ui/label';\nimport { RadioGroup, RadioGroupItem } from '@/components/shadcn-ui/radio-group';\nimport { Canon } from '@sillsdev/scripture';\nimport { LocalizedStringValue } from 'platform-bible-utils';\nimport { useState } from 'react';\nimport ChapterRangeSelector, {\n ChapterRangeSelectorProps,\n} from '../basics/chapter-range-selector.component';\n\nexport enum BookSelectionMode {\n CURRENT_BOOK = 'current book',\n CHOOSE_BOOKS = 'choose books',\n}\n\n/**\n * Object containing all keys used for localization in this component. If you're using this\n * component in an extension, you can pass it into the useLocalizedStrings hook to easily obtain the\n * localized strings and pass them into the localizedStrings prop of this component\n */\nexport const BOOK_SELECTOR_STRING_KEYS = Object.freeze([\n '%webView_bookSelector_currentBook%',\n '%webView_bookSelector_choose%',\n '%webView_bookSelector_chooseBooks%',\n] as const);\n\nexport type BookSelectorLocalizedStrings = {\n [localizedInventoryKey in (typeof BOOK_SELECTOR_STRING_KEYS)[number]]?: LocalizedStringValue;\n};\n\n/**\n * Gets the localized value for the provided key\n *\n * @param strings Object containing localized string\n * @param key Key for a localized string\n * @returns The localized value for the provided key, if available. Returns the key if no localized\n * value is available\n */\nconst localizeString = (\n strings: BookSelectorLocalizedStrings,\n key: keyof BookSelectorLocalizedStrings,\n) => {\n return strings[key] ?? key;\n};\n\ntype BookSelectorProps = ChapterRangeSelectorProps & {\n handleBookSelectionModeChange: (newMode: BookSelectionMode) => void;\n currentBookName: string;\n onSelectBooks: () => void;\n selectedBookIds: string[];\n localizedStrings: BookSelectorLocalizedStrings;\n};\n\nexport default function BookSelector({\n handleBookSelectionModeChange,\n currentBookName,\n onSelectBooks,\n selectedBookIds,\n chapterCount,\n endChapter,\n handleSelectEndChapter,\n startChapter,\n handleSelectStartChapter,\n localizedStrings,\n}: BookSelectorProps) {\n const currentBookText = localizeString(localizedStrings, '%webView_bookSelector_currentBook%');\n const chooseText = localizeString(localizedStrings, '%webView_bookSelector_choose%');\n const chooseBooksText = localizeString(localizedStrings, '%webView_bookSelector_chooseBooks%');\n\n const [bookSelectionMode, setBookSelectionMode] = useState(\n BookSelectionMode.CURRENT_BOOK,\n );\n\n const onSelectionModeChange = (newMode: BookSelectionMode) => {\n setBookSelectionMode(newMode);\n handleBookSelectionModeChange(newMode);\n };\n\n return (\n onSelectionModeChange(value as BookSelectionMode)}\n >\n
    \n
    \n
    \n \n \n
    \n \n
    \n \n
    \n
    \n
    \n
    \n \n \n
    \n \n onSelectBooks()}\n >\n {chooseText}\n \n
    \n
    \n \n );\n}\n","import { DropdownMenuTrigger } from '@radix-ui/react-dropdown-menu';\nimport { FilterIcon } from 'lucide-react';\nimport { Table } from '@tanstack/react-table';\n\nimport { Button } from '@/components/shadcn-ui/button';\nimport {\n DropdownMenu,\n DropdownMenuCheckboxItem,\n DropdownMenuContent,\n DropdownMenuLabel,\n DropdownMenuSeparator,\n} from '@/components/shadcn-ui/dropdown-menu';\n\ninterface DataTableViewOptionsProps {\n table: Table;\n}\n\nfunction DataTableViewOptions({ table }: DataTableViewOptionsProps) {\n return (\n \n \n \n \n \n Toggle columns\n \n {table\n .getAllColumns()\n .filter((column) => column.getCanHide())\n .map((column) => {\n return (\n column.toggleVisibility(!!value)}\n >\n {column.id}\n \n );\n })}\n \n \n );\n}\n\nexport default DataTableViewOptions;\n","import React from 'react';\nimport * as SelectPrimitive from '@radix-ui/react-select';\nimport { Check, ChevronDown, ChevronUp } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Select = SelectPrimitive.Root;\n\nconst SelectGroup = SelectPrimitive.Group;\n\nconst SelectValue = SelectPrimitive.Value;\n\nconst SelectTrigger = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, ...props }, ref) => (\n span]:tw-line-clamp-1',\n className,\n )}\n {...props}\n >\n {children}\n \n \n \n \n));\nSelectTrigger.displayName = SelectPrimitive.Trigger.displayName;\n\nconst SelectScrollUpButton = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n));\nSelectScrollUpButton.displayName = SelectPrimitive.ScrollUpButton.displayName;\n\nconst SelectScrollDownButton = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n));\nSelectScrollDownButton.displayName = SelectPrimitive.ScrollDownButton.displayName;\n\nconst SelectContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, position = 'popper', ...props }, ref) => (\n \n \n \n \n {children}\n \n \n \n \n));\nSelectContent.displayName = SelectPrimitive.Content.displayName;\n\nconst SelectLabel = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSelectLabel.displayName = SelectPrimitive.Label.displayName;\n\nconst SelectItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, ...props }, ref) => (\n \n \n \n \n \n \n\n {children}\n \n));\nSelectItem.displayName = SelectPrimitive.Item.displayName;\n\nconst SelectSeparator = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSelectSeparator.displayName = SelectPrimitive.Separator.displayName;\n\nexport {\n Select,\n SelectGroup,\n SelectValue,\n SelectTrigger,\n SelectContent,\n SelectLabel,\n SelectItem,\n SelectSeparator,\n SelectScrollUpButton,\n SelectScrollDownButton,\n};\n","import { ChevronLeftIcon, ChevronRightIcon, ArrowLeftIcon, ArrowRightIcon } from 'lucide-react';\nimport { Table } from '@tanstack/react-table';\n\nimport { Button } from '@/components/shadcn-ui/button';\nimport {\n Select,\n SelectContent,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\n\ninterface DataTablePaginationProps {\n table: Table;\n}\n\nfunction DataTablePagination({ table }: DataTablePaginationProps) {\n return (\n
    \n
    \n
    \n {table.getFilteredSelectedRowModel().rows.length} of{' '}\n {table.getFilteredRowModel().rows.length} row(s) selected\n
    \n
    \n

    Rows per page

    \n {\n table.setPageSize(Number(value));\n }}\n >\n \n \n \n \n {[10, 20, 30, 40, 50].map((pageSize) => (\n \n {pageSize}\n \n ))}\n \n \n
    \n
    \n Page {table.getState().pagination.pageIndex + 1} of {table.getPageCount()}\n
    \n
    \n table.setPageIndex(0)}\n disabled={!table.getCanPreviousPage()}\n >\n Go to first page\n \n \n table.previousPage()}\n disabled={!table.getCanPreviousPage()}\n >\n Go to previous page\n \n \n table.nextPage()}\n disabled={!table.getCanNextPage()}\n >\n Go to next page\n \n \n table.setPageIndex(table.getPageCount() - 1)}\n disabled={!table.getCanNextPage()}\n >\n Go to last page\n \n \n
    \n
    \n
    \n );\n}\n\nexport default DataTablePagination;\n","import React from 'react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Table = React.forwardRef<\n HTMLTableElement,\n React.HTMLAttributes & { stickyHeader?: boolean }\n>(({ className, stickyHeader, ...props }, ref) => (\n
    \n \n
    \n));\nTable.displayName = 'Table';\n\nconst TableHeader = React.forwardRef<\n HTMLTableSectionElement,\n React.HTMLAttributes & { stickyHeader?: boolean }\n>(({ className, stickyHeader, ...props }, ref) => (\n \n));\nTableHeader.displayName = 'TableHeader';\n\nconst TableBody = React.forwardRef<\n HTMLTableSectionElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableBody.displayName = 'TableBody';\n\nconst TableFooter = React.forwardRef<\n HTMLTableSectionElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n tr]:last:tw-border-b-0', className)}\n {...props}\n />\n));\nTableFooter.displayName = 'TableFooter';\n\nconst TableRow = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nTableRow.displayName = 'TableRow';\n\nconst TableHead = React.forwardRef<\n HTMLTableCellElement,\n React.ThHTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableHead.displayName = 'TableHead';\n\nconst TableCell = React.forwardRef<\n HTMLTableCellElement,\n React.TdHTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableCell.displayName = 'TableCell';\n\nconst TableCaption = React.forwardRef<\n HTMLTableCaptionElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableCaption.displayName = 'TableCaption';\n\nexport { Table, TableHeader, TableBody, TableFooter, TableHead, TableRow, TableCell, TableCaption };\n","import { useState } from 'react';\n\nimport {\n ColumnFiltersState,\n flexRender,\n getCoreRowModel,\n getFilteredRowModel,\n getPaginationRowModel,\n getSortedRowModel,\n SortingState,\n ColumnDef as TSColumnDef,\n Row as TSRow,\n RowSelectionState as TSRowSelectionState,\n SortDirection as TSSortDirection,\n Table as TSTable,\n useReactTable,\n VisibilityState,\n} from '@tanstack/react-table';\n\nimport DataTableViewOptions from '@/components/advanced/data-table/data-table-column-toggle.component';\nimport DataTablePagination from '@/components/advanced/data-table/data-table-pagination.component';\nimport { Button } from '@/components/shadcn-ui/button';\nimport {\n Table,\n TableBody,\n TableCell,\n TableHead,\n TableHeader,\n TableRow,\n} from '@/components/shadcn-ui/table';\n\nexport type ColumnDef = TSColumnDef;\nexport type RowContents = TSRow;\nexport type TableContents = TSTable;\nexport type SortDirection = TSSortDirection;\nexport type RowSelectionState = TSRowSelectionState;\n\ninterface DataTableProps {\n columns: ColumnDef[];\n data: TData[];\n enablePagination?: boolean;\n showPaginationControls?: boolean;\n showColumnVisibilityControls?: boolean;\n stickyHeader?: boolean;\n onRowClickHandler?: (row: RowContents, table: TableContents) => void;\n}\n\n/**\n * Feature-rich table component that infuses our basic shadcn-based Table component with features\n * from TanStack's React Table library\n */\nfunction DataTable({\n columns,\n data,\n enablePagination = false,\n showPaginationControls = false,\n showColumnVisibilityControls = false,\n stickyHeader = false,\n onRowClickHandler = () => {},\n}: DataTableProps) {\n const [sorting, setSorting] = useState([]);\n const [columnFilters, setColumnFilters] = useState([]);\n const [columnVisibility, setColumnVisibility] = useState({});\n const [rowSelection, setRowSelection] = useState({});\n\n const table = useReactTable({\n data,\n columns,\n getCoreRowModel: getCoreRowModel(),\n ...(enablePagination && { getPaginationRowModel: getPaginationRowModel() }),\n onSortingChange: setSorting,\n getSortedRowModel: getSortedRowModel(),\n onColumnFiltersChange: setColumnFilters,\n getFilteredRowModel: getFilteredRowModel(),\n onColumnVisibilityChange: setColumnVisibility,\n onRowSelectionChange: setRowSelection,\n state: {\n sorting,\n columnFilters,\n columnVisibility,\n rowSelection,\n },\n });\n\n return (\n
    \n {showColumnVisibilityControls && }\n \n \n {table.getHeaderGroups().map((headerGroup) => (\n \n {headerGroup.headers.map((header) => {\n return (\n \n {header.isPlaceholder\n ? undefined\n : flexRender(header.column.columnDef.header, header.getContext())}\n \n );\n })}\n \n ))}\n \n \n {table.getRowModel().rows?.length ? (\n table.getRowModel().rows.map((row) => (\n onRowClickHandler(row, table)}\n key={row.id}\n data-state={row.getIsSelected() && 'selected'}\n >\n {row.getVisibleCells().map((cell) => (\n \n {flexRender(cell.column.columnDef.cell, cell.getContext())}\n \n ))}\n \n ))\n ) : (\n \n \n No results.\n \n \n )}\n \n
    \n {enablePagination && (\n
    \n table.previousPage()}\n disabled={!table.getCanPreviousPage()}\n >\n Previous\n \n table.nextPage()}\n disabled={!table.getCanNextPage()}\n >\n Next\n \n
    \n )}\n {enablePagination && showPaginationControls && }\n
    \n );\n}\n\nexport default DataTable;\n","import {\n Table,\n TableBody,\n TableCell,\n TableHead,\n TableHeader,\n TableRow,\n} from '@/components/shadcn-ui/table';\nimport { Canon } from '@sillsdev/scripture';\nimport { deepEqual, LanguageStrings, ScriptureReference } from 'platform-bible-utils';\nimport { useMemo } from 'react';\nimport { InventoryItemOccurrence } from './inventory-utils';\n\n/** Props for the OccurrencesTable component */\ntype OccurrencesTableProps = {\n /** Data that contains scriptures references and snippets of scripture */\n occurrenceData: InventoryItemOccurrence[];\n /** Callback function that is executed when the scripture reference is changed */\n setScriptureReference: (scriptureReference: ScriptureReference) => void;\n /**\n * Object with all localized strings that the OccurrencesTable needs to work well across multiple\n * languages\n */\n localizedStrings: LanguageStrings;\n};\n\n/**\n * Table that shows occurrences of specified inventory item(s). The first column shows the related\n * scripture reference. The second column shows the snippet of scripture that contains the specified\n * inventory item\n */\nfunction OccurrencesTable({\n occurrenceData,\n setScriptureReference,\n localizedStrings,\n}: OccurrencesTableProps) {\n const referenceHeaderText =\n localizedStrings['%webView_inventory_occurrences_table_header_reference%'];\n const occurrenceHeaderText =\n localizedStrings['%webView_inventory_occurrences_table_header_occurrence%'];\n\n const occurrences: InventoryItemOccurrence[] = useMemo(() => {\n const uniqueOccurrences: InventoryItemOccurrence[] = [];\n\n occurrenceData.forEach((occurrence) => {\n if (!uniqueOccurrences.some((uniqueOccurrence) => deepEqual(uniqueOccurrence, occurrence))) {\n uniqueOccurrences.push(occurrence);\n }\n });\n\n return uniqueOccurrences;\n }, [occurrenceData]);\n\n return (\n \n \n \n {referenceHeaderText}\n {occurrenceHeaderText}\n \n \n \n {occurrences.length > 0 &&\n occurrences.map((occurrence) => (\n {\n setScriptureReference(occurrence.reference);\n }}\n >\n {`${Canon.bookNumberToEnglishName(occurrence.reference.bookNum)} ${occurrence.reference.chapterNum}:${occurrence.reference.verseNum}`}\n {occurrence.text}\n \n ))}\n \n
    \n );\n}\n\nexport default OccurrencesTable;\n","import React from 'react';\nimport * as CheckboxPrimitive from '@radix-ui/react-checkbox';\nimport { Check } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Checkbox = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n \n \n));\nCheckbox.displayName = CheckboxPrimitive.Root.displayName;\n\nexport default Checkbox;\n","import { Canon } from '@sillsdev/scripture';\nimport { ScriptureReference } from 'platform-bible-utils';\n\n/* #region Types */\n\n/**\n * Status of items that appear in inventories. 'approved' and 'unapproved' items are defined in the\n * project's `Settings.xml`. All other items are defined as 'unknown'\n */\nexport type Status = 'approved' | 'unapproved' | 'unknown';\n\n/** Occurrence of item in inventory. Primarily used by table that shows occurrences */\nexport type InventoryItemOccurrence = {\n /** Reference to scripture where the item appears */\n reference: ScriptureReference;\n /** Snippet of scripture that contains the occurrence */\n text: string;\n};\n\n/** Data structure that contains all information on an item that is shown in an inventory */\nexport type InventoryTableData = {\n /**\n * The item (e.g. a character in the characters inventory, a marker in the marker inventory) In\n * most cases the array will only have one element. In case of additional items (e.g. the\n * preceding marker in the markers check), the primary item should be stored in the first index.\n * To show additional items in the inventory, make sure to configure the `additionalItemsLabels`\n * prop for the Inventory component\n */\n items: string[];\n /** The number of times this item occurs in the selected scope */\n count: number;\n /** The status of this item (see documentation for `Status` type for more information) */\n status: Status;\n /** Occurrences of this item in the scripture text for the selected scope */\n occurrences: InventoryItemOccurrence[];\n};\n\n/* #endregion */\n\n/* #region Functions */\n\n/**\n * Splits USFM string into shorter line-like segments\n *\n * @param text A single (likely very large) USFM string\n * @returns An array containing the input text, split into shorter segments\n */\nexport const getLinesFromUSFM = (text: string) => {\n // Splits on (CR)LF, CR, \\v, \\c and \\id\n return text.split(/(?:\\r?\\n|\\r)|(?=(?:\\\\(?:v|c|id)))/g);\n};\n\n/**\n * Extracts chapter or verse number from USFM strings that start with a \\c or \\v marker\n *\n * @param text USFM string that is expected to start with \\c or \\v marker\n * @returns Chapter or verse number if one is found. Else returns 0.\n */\nexport const getNumberFromUSFM = (text: string): number | undefined => {\n // Captures all digits that follow \\v or \\c markers followed by whitespace located at the start of a string\n const regex = /^\\\\[vc]\\s+(\\d+)/;\n const match = text.match(regex);\n\n if (match) {\n return +match[1];\n }\n return undefined;\n};\n\n/**\n * Gets book ID from USFM string that starts with the \\id marker, and returns book number for it\n *\n * @param text USFM string that is expected to start with \\id marker\n * @returns Book number corresponding to the \\id marker in the input text. Returns 0 if no marker is\n * found or the marker is not valid\n */\nexport const getBookNumFromId = (text: string): number => {\n // Captures all digits that follow an \\id marker followed by whitespace located at the start of a string\n const match = text.match(/^\\\\id\\s+([A-Za-z]+)/);\n if (match) {\n return Canon.bookIdToNumber(match[1]);\n }\n return 0;\n};\n\n/**\n * Gets the status for an item, typically used in the Inventory component\n *\n * @param item The item for which the status is being requested\n * @param approvedItems Array of approved items, typically as defined in `Settings.xml`\n * @param unapprovedItems Array of unapproved items, typically as defined in `Settings.xml`\n * @returns The status for the specified item\n */\nexport const getStatusForItem = (\n item: string,\n approvedItems: string[],\n unapprovedItems: string[],\n): Status => {\n if (unapprovedItems.includes(item)) return 'unapproved';\n if (approvedItems.includes(item)) return 'approved';\n return 'unknown';\n};\n\n/* #endregion */\n","import React from 'react';\nimport * as TogglePrimitive from '@radix-ui/react-toggle';\nimport { cva, type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst toggleVariants = cva(\n 'pr-twp tw-inline-flex tw-items-center tw-justify-center tw-rounded-md tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-colors hover:tw-bg-muted hover:tw-text-muted-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50 data-[state=on]:tw-bg-accent data-[state=on]:tw-text-accent-foreground',\n {\n variants: {\n variant: {\n default: 'tw-bg-transparent',\n outline:\n 'tw-border tw-border-input tw-bg-transparent hover:tw-bg-accent hover:tw-text-accent-foreground',\n },\n size: {\n default: 'tw-h-10 tw-px-3',\n sm: 'tw-h-9 tw-px-2.5',\n lg: 'tw-h-11 tw-px-5',\n },\n },\n defaultVariants: {\n variant: 'default',\n size: 'default',\n },\n },\n);\n\nconst Toggle = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef & VariantProps\n>(({ className, variant, size, ...props }, ref) => (\n \n));\n\nToggle.displayName = TogglePrimitive.Root.displayName;\n\nexport { Toggle, toggleVariants };\n","import React from 'react';\nimport * as ToggleGroupPrimitive from '@radix-ui/react-toggle-group';\nimport { type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { toggleVariants } from '@/components/shadcn-ui/toggle';\n\nconst ToggleGroupContext = React.createContext>({\n size: 'default',\n variant: 'default',\n});\n\nconst ToggleGroup = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef &\n VariantProps\n>(({ className, variant, size, children, ...props }, ref) => (\n \n \n {children}\n \n \n));\n\nToggleGroup.displayName = ToggleGroupPrimitive.Root.displayName;\n\nconst ToggleGroupItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef &\n VariantProps\n>(({ className, children, variant, size, ...props }, ref) => {\n const context = React.useContext(ToggleGroupContext);\n\n return (\n \n {children}\n \n );\n});\n\nToggleGroupItem.displayName = ToggleGroupPrimitive.Item.displayName;\n\nexport { ToggleGroup, ToggleGroupItem };\n","import { ColumnDef, SortDirection } from '@/components/advanced/data-table/data-table.component';\nimport { Button } from '@/components/shadcn-ui/button';\nimport { ToggleGroup, ToggleGroupItem } from '@/components/shadcn-ui/toggle-group';\nimport {\n ArrowDownIcon,\n ArrowUpDownIcon,\n ArrowUpIcon,\n CircleCheckIcon,\n CircleHelpIcon,\n CircleXIcon,\n} from 'lucide-react';\nimport { ReactNode } from 'react';\nimport { InventoryTableData, Status } from './inventory-utils';\n\n/**\n * Gets an icon that indicates the current sorting direction based on the provided input\n *\n * @param sortDirection Sorting direction. Can be ascending ('asc'), descending ('desc') or false (\n * i.e. not sorted)\n * @returns The appropriate sorting icon for the provided sorting direction\n */\nconst getSortingIcon = (sortDirection: false | SortDirection): ReactNode => {\n if (sortDirection === 'asc') {\n return ;\n }\n if (sortDirection === 'desc') {\n return ;\n }\n return ;\n};\n\n/**\n * Function that creates the item column for inventories\n *\n * @param itemLabel Localized label for the item column (e.g. 'Character', 'Repeated Word', etc.)\n * @returns Column that shows the inventory items. Should be used with the DataTable component\n */\nexport const inventoryItemColumn = (itemLabel: string): ColumnDef => {\n return {\n accessorKey: 'item',\n accessorFn: (row: InventoryTableData) => row.items[0],\n header: ({ column }) => (\n \n ),\n };\n};\n\n/**\n * Function that creates the additional item columns for inventories\n *\n * @param additionalItemLabel Localized label for the additional item column (e.g. 'Preceding\n * Marker')\n * @param additionalItemIndex Index that locates the desired item in the items array of the\n * inventory\n * @returns Column that shows additional inventory items. Should be used with the DataTable\n * component\n */\nexport const inventoryAdditionalItemColumn = (\n additionalItemLabel: string,\n additionalItemIndex: number,\n): ColumnDef => {\n return {\n accessorKey: `item${additionalItemIndex}`,\n accessorFn: (row: InventoryTableData) => row.items[additionalItemIndex],\n header: ({ column }) => (\n \n ),\n };\n};\n\n/**\n * Function that creates the count column for inventories. Should be used with the DataTable\n * component.\n *\n * @param itemLabel Localized label for the count column\n * @returns Column that shows the number of occurrences of the related inventory items\n */\nexport const inventoryCountColumn = (countLabel: string): ColumnDef => {\n return {\n accessorKey: 'count',\n header: ({ column }) => (\n
    \n \n
    \n ),\n cell: ({ row }) =>
    {row.getValue('count')}
    ,\n };\n};\n\n/**\n * Function that updates project settings when status for item(s) changes\n *\n * @param changedItems Array of items for which the status is being updated\n * @param newStatus The status that the items are being given\n * @param approvedItems Array of currently approved items\n * @param onApprovedItemsChange Callback function that stores the updated list of approved items\n * @param unapprovedItems Array of currently unapproved items\n * @param onUnapprovedItemsChange Callback function that stores the updated list of unapproved items\n */\nconst statusChangeHandler = (\n changedItems: string[],\n newStatus: Status,\n approvedItems: string[],\n onApprovedItemsChange: (items: string[]) => void,\n unapprovedItems: string[],\n onUnapprovedItemsChange: (items: string[]) => void,\n) => {\n let newApprovedItems: string[] = [...approvedItems];\n changedItems.forEach((item) => {\n if (newStatus === 'approved') {\n if (!newApprovedItems.includes(item)) {\n newApprovedItems.push(item);\n }\n } else {\n newApprovedItems = newApprovedItems.filter((validItem) => validItem !== item);\n }\n });\n onApprovedItemsChange(newApprovedItems);\n\n let newUnapprovedItems: string[] = [...unapprovedItems];\n changedItems.forEach((item) => {\n if (newStatus === 'unapproved') {\n if (!newUnapprovedItems.includes(item)) {\n newUnapprovedItems.push(item);\n }\n } else {\n newUnapprovedItems = newUnapprovedItems.filter((unapprovedItem) => unapprovedItem !== item);\n }\n });\n onUnapprovedItemsChange(newUnapprovedItems);\n};\n\n/**\n * Function that creates the status column for inventories. Should be used with the DataTable\n * component.\n *\n * @param statusLabel Localized label for the status column\n * @param approvedItems Array of approved items, typically as defined in `Settings.xml`\n * @param onApprovedItemsChange Callback function that stores the updated list of approved items\n * @param unapprovedItems Array of unapproved items, typically as defined in `Settings.xml`\n * @param onUnapprovedItemsChange Callback function that stores the updated list of unapproved items\n * @returns Column that shows the status buttons for the related inventory item. The button for the\n * current status of the item is selected\n */\nexport const inventoryStatusColumn = (\n statusLabel: string,\n approvedItems: string[],\n onApprovedItemsChange: (items: string[]) => void,\n unapprovedItems: string[],\n onUnapprovedItemsChange: (items: string[]) => void,\n): ColumnDef => {\n return {\n accessorKey: 'status',\n header: ({ column }) => {\n return (\n
    \n \n
    \n );\n },\n cell: ({ row }) => {\n const status: Status = row.getValue('status');\n const item: string = row.getValue('item');\n return (\n \n \n statusChangeHandler(\n [item],\n 'approved',\n approvedItems,\n onApprovedItemsChange,\n unapprovedItems,\n onUnapprovedItemsChange,\n )\n }\n value=\"approved\"\n >\n \n \n \n statusChangeHandler(\n [item],\n 'unapproved',\n approvedItems,\n onApprovedItemsChange,\n unapprovedItems,\n onUnapprovedItemsChange,\n )\n }\n value=\"unapproved\"\n >\n \n \n \n statusChangeHandler(\n [item],\n 'unknown',\n approvedItems,\n onApprovedItemsChange,\n unapprovedItems,\n onUnapprovedItemsChange,\n )\n }\n value=\"unknown\"\n >\n \n \n \n );\n },\n };\n};\n","import DataTable, {\n ColumnDef,\n RowContents,\n RowSelectionState,\n TableContents,\n} from '@/components/advanced/data-table/data-table.component';\nimport OccurrencesTable from '@/components/advanced/inventory/occurrences-table.component';\nimport Checkbox from '@/components/shadcn-ui/checkbox';\nimport { Input } from '@/components/shadcn-ui/input';\nimport { Label } from '@/components/shadcn-ui/label';\nimport {\n Select,\n SelectContent,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\nimport {\n deepEqual,\n LocalizedStringValue,\n ScriptureReference,\n substring,\n} from 'platform-bible-utils';\nimport { useEffect, useMemo, useState } from 'react';\nimport {\n getBookNumFromId,\n getLinesFromUSFM,\n getNumberFromUSFM,\n getStatusForItem,\n InventoryItemOccurrence,\n InventoryTableData,\n Status,\n} from './inventory-utils';\nimport { inventoryAdditionalItemColumn } from './inventory-columns';\n\n/**\n * Object containing all keys used for localization in this component. If you're using this\n * component in an extension, you can pass it into the useLocalizedStrings hook to easily obtain the\n * localized strings and pass them into the localizedStrings prop of this component\n */\nexport const INVENTORY_STRING_KEYS = Object.freeze([\n '%webView_inventory_all%',\n '%webView_inventory_approved%',\n '%webView_inventory_unapproved%',\n '%webView_inventory_unknown%',\n '%webView_inventory_scope_currentBook%',\n '%webView_inventory_scope_chapter%',\n '%webView_inventory_scope_verse%',\n '%webView_inventory_filter_text%',\n '%webView_inventory_show_additional_items%',\n '%webView_inventory_occurrences_table_header_reference%',\n '%webView_inventory_occurrences_table_header_occurrence%',\n] as const);\n\nexport type InventoryLocalizedStrings = {\n [localizedInventoryKey in (typeof INVENTORY_STRING_KEYS)[number]]?: LocalizedStringValue;\n};\n\n/** Scope of scripture that the inventory can operate on */\nexport type Scope = 'book' | 'chapter' | 'verse';\n\n/** Status values that the status filter can select from */\ntype StatusFilter = Status | 'all';\n\n/** Text labels for the inventory columns and the control components of additional inventory items */\ntype AdditionalItemsLabels = {\n checkboxText?: string;\n tableHeaders?: string[];\n};\n\n/**\n * Filters data that is shown in the DataTable section of the Inventory\n *\n * @param itemData All inventory items and their related information\n * @param statusFilter Allows filtering by status (i.e. show all items, or only items that are\n * 'approved', 'unapproved' or 'unknown')\n * @param textFilter Allows filtering by text. All items that include the filter text will be\n * selected.\n * @returns Array of items and their related information that are matched by the specified filters\n */\nconst filterItemData = (\n itemData: InventoryTableData[],\n statusFilter: StatusFilter,\n textFilter: string,\n): InventoryTableData[] => {\n let filteredItemData: InventoryTableData[] = itemData;\n\n if (statusFilter !== 'all') {\n filteredItemData = filteredItemData.filter(\n (item) =>\n (statusFilter === 'approved' && item.status === 'approved') ||\n (statusFilter === 'unapproved' && item.status === 'unapproved') ||\n (statusFilter === 'unknown' && item.status === 'unknown'),\n );\n }\n\n if (textFilter !== '')\n filteredItemData = filteredItemData.filter((item) => item.items[0].includes(textFilter));\n\n return filteredItemData;\n};\n\n/**\n * Turns array of strings into array of inventory items, along with their count and status\n *\n * @param text The source scripture text that is searched for inventory items\n * @param scriptureRef The scripture reference that the application is currently set to\n * @param approvedItems Array of approved items, typically as defined in `Settings.xml`\n * @param unapprovedItems Array of unapproved items, typically as defined in `Settings.xml`\n * @param itemRegex Regular expression that describes what items this Inventory should extract from\n * the provided scripture text\n * @returns Array of inventory items, along with their count and status\n */\nconst createTableData = (\n text: string | undefined,\n scriptureRef: ScriptureReference,\n approvedItems: string[],\n unapprovedItems: string[],\n itemRegex: RegExp,\n): InventoryTableData[] => {\n if (!text) return [];\n\n const tableData: InventoryTableData[] = [];\n\n let currentBook: number | undefined = scriptureRef.bookNum;\n let currentChapter: number | undefined = scriptureRef.chapterNum;\n let currentVerse: number | undefined = scriptureRef.verseNum;\n\n const lines = getLinesFromUSFM(text);\n\n lines.forEach((line: string) => {\n if (line.startsWith('\\\\id')) {\n currentBook = getBookNumFromId(line);\n currentChapter = 0;\n currentVerse = 0;\n }\n if (line.startsWith('\\\\c')) {\n currentChapter = getNumberFromUSFM(line);\n currentVerse = 0;\n }\n if (line.startsWith('\\\\v')) {\n currentVerse = getNumberFromUSFM(line);\n if (currentChapter === 0) {\n currentChapter = scriptureRef.chapterNum;\n }\n }\n\n let match: RegExpExecArray | undefined = itemRegex.exec(line) ?? undefined;\n while (match) {\n const items: string[] = [];\n match.forEach((item) => items.push(item));\n const itemIndex = match.index;\n const existingItem = tableData.find((tableEntry) => deepEqual(tableEntry.items, items));\n const newReference: InventoryItemOccurrence = {\n reference: {\n bookNum: currentBook !== undefined ? currentBook : -1,\n chapterNum: currentChapter !== undefined ? currentChapter : -1,\n verseNum: currentVerse !== undefined ? currentVerse : -1,\n },\n text: substring(line, Math.max(0, itemIndex - 25), Math.min(itemIndex + 25, line.length)),\n };\n if (existingItem) {\n existingItem.count += 1;\n existingItem.occurrences.push(newReference);\n } else {\n const newItem: InventoryTableData = {\n items,\n count: 1,\n status: getStatusForItem(items[0], approvedItems, unapprovedItems),\n occurrences: [newReference],\n };\n tableData.push(newItem);\n }\n\n match = itemRegex.exec(line) ?? undefined;\n }\n });\n\n return tableData;\n};\n\n/**\n * Gets the localized value for the provided key\n *\n * @param strings Object containing localized string\n * @param key Key for a localized string\n * @returns The localized value for the provided key, if available. Returns the key if no localized\n * value is available\n */\nconst localizeString = (\n strings: InventoryLocalizedStrings,\n key: keyof InventoryLocalizedStrings,\n) => {\n return strings[key] ?? key;\n};\n\n/** Props for the Inventory component */\ntype InventoryProps = {\n /** The scripture reference that the application is currently set to */\n scriptureReference: ScriptureReference;\n /** Callback function that is executed when the scripture reference is changed */\n setScriptureReference: (scriptureReference: ScriptureReference) => void;\n /**\n * Object with all localized strings that the Inventory needs to work well across multiple\n * languages. When using this component with Platform.Bible, you can import\n * `INVENTORY_STRING_KEYS` from this library, pass it in to the Platform's localization hook, and\n * pass the localized keys that are returned by the hook into this prop.\n */\n localizedStrings: InventoryLocalizedStrings;\n /**\n * The logic that finds the desired items in the source text. This can either be a Regular\n * expression that captures one or multiple items (preferred), or a custom function that builds\n * and return an InventoryDataTable[] manually. Note: In case the logic captures more than one\n * item (i.e. InventoryTableData.items has a length greater than 1), you must provide text labels\n * for the related columns and control elements to show by setting the `additionalItemsLabels`\n * prop\n */\n extractItems:\n | RegExp\n | ((\n text: string | undefined,\n scriptureRef: ScriptureReference,\n approvedItems: string[],\n unapprovedItems: string[],\n ) => InventoryTableData[]);\n /**\n * Text labels for control elements and additional column headers in case your Inventory has more\n * than one item to show (e.g. The 'Preceding Marker' in the Markers Inventory)\n */\n additionalItemsLabels?: AdditionalItemsLabels;\n /** Array of approved items, typically as defined in `Settings.xml` */\n approvedItems: string[];\n /** Array of unapproved items, typically as defined in `Settings.xml` */\n unapprovedItems: string[];\n /** The source scripture text that is searched for in inventory items */\n text: string | undefined;\n /** Scope of scripture that the inventory will operate on */\n scope: Scope;\n /** Callback function that is executed when the scope is changed from the Inventory */\n onScopeChange: (scope: Scope) => void;\n /**\n * Column definitions for the Inventory data table. The most commonly used column definitions are\n * pre-configured for your convenience and can be imported (e.g. inventoryItemColumn,\n * inventoryAdditionalItemColumn inventoryCountColumn, and inventoryStatusColumn). If you need any\n * other columns you can add these yourself\n */\n columns: ColumnDef[];\n};\n\n/** Inventory component that is used to view and control the status of provided project settings */\nexport default function Inventory({\n scriptureReference,\n setScriptureReference,\n localizedStrings,\n extractItems,\n additionalItemsLabels,\n approvedItems,\n unapprovedItems,\n text,\n scope,\n onScopeChange,\n columns,\n}: InventoryProps) {\n const allItemsText = localizeString(localizedStrings, '%webView_inventory_all%');\n const approvedItemsText = localizeString(localizedStrings, '%webView_inventory_approved%');\n const unapprovedItemsText = localizeString(localizedStrings, '%webView_inventory_unapproved%');\n const unknownItemsText = localizeString(localizedStrings, '%webView_inventory_unknown%');\n const scopeBookText = localizeString(localizedStrings, '%webView_inventory_scope_currentBook%');\n const scopeChapterText = localizeString(localizedStrings, '%webView_inventory_scope_chapter%');\n const scopeVerseText = localizeString(localizedStrings, '%webView_inventory_scope_verse%');\n const filterText = localizeString(localizedStrings, '%webView_inventory_filter_text%');\n const showAdditionalItemsText = localizeString(\n localizedStrings,\n '%webView_inventory_show_additional_items%',\n );\n\n const [showAdditionalItems, setShowAdditionalItems] = useState(false);\n const [statusFilter, setStatusFilter] = useState('all');\n const [textFilter, setTextFilter] = useState('');\n const [selectedItem, setSelectedItem] = useState([]);\n\n const tableData: InventoryTableData[] = useMemo(() => {\n if (!text) return [];\n if (extractItems instanceof RegExp)\n return createTableData(\n text,\n scriptureReference,\n approvedItems,\n unapprovedItems,\n extractItems,\n );\n return extractItems(text, scriptureReference, approvedItems, unapprovedItems);\n }, [text, extractItems, scriptureReference, approvedItems, unapprovedItems]);\n\n const reducedTableData: InventoryTableData[] = useMemo(() => {\n if (showAdditionalItems) return tableData;\n\n const newTableData: InventoryTableData[] = [];\n\n tableData.forEach((tableEntry) => {\n const firstItem = tableEntry.items[0];\n\n const existingEntry = newTableData.find(\n (newTableEntry) => newTableEntry.items[0] === firstItem,\n );\n\n if (existingEntry) {\n existingEntry.count += tableEntry.count;\n existingEntry.occurrences = existingEntry.occurrences.concat(tableEntry.occurrences);\n } else {\n newTableData.push({\n items: [firstItem],\n count: tableEntry.count,\n occurrences: tableEntry.occurrences,\n status: tableEntry.status,\n });\n }\n });\n\n return newTableData;\n }, [showAdditionalItems, tableData]);\n\n const filteredTableData: InventoryTableData[] = useMemo(() => {\n return filterItemData(reducedTableData, statusFilter, textFilter);\n }, [reducedTableData, statusFilter, textFilter]);\n\n const allColumns: ColumnDef[] = useMemo(() => {\n if (!showAdditionalItems) return columns;\n\n const numberOfAdditionalItems = additionalItemsLabels?.tableHeaders?.length;\n if (!numberOfAdditionalItems) return columns;\n\n const additionalColumns: ColumnDef[] = [];\n\n for (let index = 0; index < numberOfAdditionalItems; index++) {\n additionalColumns.push(\n inventoryAdditionalItemColumn(\n additionalItemsLabels?.tableHeaders?.[index] || 'Additional Item',\n index + 1,\n ),\n );\n }\n\n return [...additionalColumns, ...columns];\n }, [additionalItemsLabels?.tableHeaders, columns, showAdditionalItems]);\n\n useEffect(() => {\n setSelectedItem([]);\n }, [filteredTableData]);\n\n const rowClickHandler = (\n row: RowContents,\n table: TableContents,\n ) => {\n table.setRowSelection(() => {\n const newSelection: RowSelectionState = {};\n newSelection[row.index] = true;\n return newSelection;\n });\n\n setSelectedItem(row.original.items);\n };\n\n const handleScopeChange = (value: string) => {\n if (value === 'book' || value === 'chapter' || value === 'verse') {\n onScopeChange(value);\n } else {\n throw new Error(`Invalid scope value: ${value}`);\n }\n };\n\n const handleStatusFilterChange = (value: string) => {\n if (value === 'all' || value === 'approved' || value === 'unapproved' || value === 'unknown') {\n setStatusFilter(value);\n } else {\n throw new Error(`Invalid status filter value: ${value}`);\n }\n };\n\n const occurrenceData: InventoryItemOccurrence[] = useMemo(() => {\n if (reducedTableData.length === 0 || selectedItem.length === 0) return [];\n const occurrence = reducedTableData.filter((tableEntry: InventoryTableData) => {\n return deepEqual(\n showAdditionalItems ? tableEntry.items : [tableEntry.items[0]],\n selectedItem,\n );\n });\n if (occurrence.length > 1) throw new Error('Selected item is not unique');\n return occurrence[0].occurrences;\n }, [selectedItem, showAdditionalItems, reducedTableData]);\n\n return (\n
    \n
    \n handleStatusFilterChange(value)}\n defaultValue={statusFilter}\n >\n \n \n \n \n {allItemsText}\n {approvedItemsText}\n {unapprovedItemsText}\n {unknownItemsText}\n \n \n \n {\n setTextFilter(event.target.value);\n }}\n />\n {additionalItemsLabels && (\n
    \n {\n setSelectedItem([]);\n setShowAdditionalItems(checked);\n }}\n />\n \n
    \n )}\n
    \n
    \n \n
    \n {occurrenceData.length > 0 && (\n
    \n \n
    \n )}\n
    \n );\n}\n","import { Input } from '@/components/shadcn-ui/input';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { useState } from 'react';\n\n/** Props for the SearchBar component. */\nexport type SearchBarProps = {\n /** Additional css classes to help with unique styling of the search bar */\n className?: string;\n /**\n * Callback fired to handle the search query when button pressed\n *\n * @param searchQuery\n */\n onSearch: (searchQuery: string) => void;\n\n /** Optional string that appears in the search bar without a search string */\n placeholder?: string;\n\n /** Optional boolean to set the input base to full width */\n isFullWidth?: boolean;\n};\n\nexport default function SearchBar({\n className,\n onSearch,\n placeholder,\n isFullWidth,\n}: SearchBarProps) {\n const [searchQuery, setSearchQuery] = useState('');\n\n const handleInputChange = (searchString: string) => {\n setSearchQuery(searchString);\n onSearch(searchString);\n };\n\n return (\n handleInputChange(e.target.value)}\n />\n );\n}\n","// adapted from: https://github.com/shadcn-ui/ui/discussions/752\n\n'use client';\n\nimport { TabsContentProps, TabsListProps, TabsTriggerProps } from '@/components/shadcn-ui/tabs';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport * as TabsPrimitive from '@radix-ui/react-tabs';\nimport React from 'react';\n\nexport type VerticalTabsProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport type LeftTabsTriggerProps = TabsTriggerProps & {\n value: string;\n ref?: React.Ref;\n};\n\nexport const VerticalTabs = React.forwardRef<\n React.ElementRef,\n VerticalTabsProps\n>(({ className, ...props }, ref) => (\n \n));\n\nVerticalTabs.displayName = TabsPrimitive.List.displayName;\n\nexport const VerticalTabsList = React.forwardRef<\n React.ElementRef,\n TabsListProps\n>(({ className, ...props }, ref) => (\n \n));\nVerticalTabsList.displayName = TabsPrimitive.List.displayName;\n\nexport const VerticalTabsTrigger = React.forwardRef<\n React.ElementRef,\n LeftTabsTriggerProps\n>(({ className, ...props }, ref) => (\n \n));\n\nexport const VerticalTabsContent = React.forwardRef<\n React.ElementRef,\n TabsContentProps\n>(({ className, ...props }, ref) => (\n \n));\nVerticalTabsContent.displayName = TabsPrimitive.Content.displayName;\n","import SearchBar from '@/components/basics/search-bar.component';\nimport {\n VerticalTabs,\n VerticalTabsContent,\n VerticalTabsList,\n VerticalTabsTrigger,\n} from '@/components/basics/tabs-vertical';\nimport { ReactNode } from 'react';\n\nexport type TabKeyValueContent = {\n key: string;\n value: string;\n content: ReactNode;\n};\n\nexport type TabNavigationContentSearchProps = {\n /** List of values and keys for each tab this component should provide */\n tabList: TabKeyValueContent[];\n\n /** Handler to run when the value of the search bar changes */\n onSearch: (searchQuery: string) => void;\n\n /** Optional placeholder for the search bar */\n searchPlaceholder?: string;\n\n /** Optional title to include in the header */\n headerTitle?: string;\n\n /** Optional flag to make the search bar appear full width */\n isSearchBarFullWidth?: boolean;\n\n /** Text direction ltr or rtl */\n direction?: 'ltr' | 'rtl';\n};\n\nexport default function TabNavigationContentSearch({\n tabList,\n onSearch,\n searchPlaceholder,\n headerTitle,\n isSearchBarFullWidth = false,\n direction = 'ltr',\n}: TabNavigationContentSearchProps) {\n return (\n
    \n
    \n {headerTitle ?

    {headerTitle}

    : ''}\n \n
    \n \n \n {tabList.map((tab) => (\n \n {tab.value}\n \n ))}\n \n {tabList.map((tab) => (\n \n {tab.content}\n \n ))}\n \n
    \n );\n}\n","import React from 'react';\nimport * as SeparatorPrimitive from '@radix-ui/react-separator';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Separator = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, orientation = 'horizontal', decorative = true, ...props }, ref) => (\n \n));\nSeparator.displayName = SeparatorPrimitive.Root.displayName;\n\nexport { Separator };\n","import React from 'react';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nfunction Skeleton({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\n\nexport { Skeleton };\n","import React from 'react';\nimport * as TooltipPrimitive from '@radix-ui/react-tooltip';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst TooltipProvider = TooltipPrimitive.Provider;\n\nconst Tooltip = TooltipPrimitive.Root;\n\nconst TooltipTrigger = TooltipPrimitive.Trigger;\n\nconst TooltipContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, sideOffset = 4, ...props }, ref) => (\n \n));\nTooltipContent.displayName = TooltipPrimitive.Content.displayName;\n\nexport { Tooltip, TooltipTrigger, TooltipContent, TooltipProvider };\n","import React from 'react';\nimport { Slot } from '@radix-ui/react-slot';\nimport { VariantProps, cva } from 'class-variance-authority';\nimport { PanelLeft } from 'lucide-react';\n\nimport { Button } from '@/components/shadcn-ui/button';\nimport { Input } from '@/components/shadcn-ui/input';\nimport { Separator } from '@/components/shadcn-ui/separator';\nimport { Skeleton } from '@/components/shadcn-ui/skeleton';\nimport {\n Tooltip,\n TooltipContent,\n TooltipProvider,\n TooltipTrigger,\n} from '@/components/shadcn-ui/tooltip';\nimport { cn } from '@/utils/shadcn-ui.util';\n\n/**\n * Changes from the original code from Shadcn- Removed uses of useIsMobile, Sheet, and SheetContent.\n * Also removed the parts setting COOKIES.\n */\n\nconst SIDEBAR_WIDTH = '16rem';\nconst SIDEBAR_WIDTH_ICON = '3rem';\n// Commented this out pending a discussion with UX about keyboard shortcuts\n// const SIDEBAR_KEYBOARD_SHORTCUT = 'b';\n\ntype SidebarContextProps = {\n state: 'expanded' | 'collapsed';\n open: boolean;\n setOpen: (open: boolean) => void;\n toggleSidebar: () => void;\n};\n\nconst SidebarContext = React.createContext(undefined);\n\nfunction useSidebar() {\n const context = React.useContext(SidebarContext);\n if (!context) {\n throw new Error('useSidebar must be used within a SidebarProvider.');\n }\n\n return context;\n}\n\nconst SidebarProvider = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & {\n defaultOpen?: boolean;\n open?: boolean;\n onOpenChange?: (open: boolean) => void;\n }\n>(\n (\n {\n defaultOpen = true,\n open: openProp,\n onOpenChange: setOpenProp,\n className,\n style,\n children,\n ...props\n },\n ref,\n ) => {\n // This is the internal state of the sidebar.\n // We use openProp and setOpenProp for control from outside the component.\n const [_open, _setOpen] = React.useState(defaultOpen);\n const isOpen = openProp ?? _open;\n const setOpen = React.useCallback(\n (value: boolean | ((value: boolean) => boolean)) => {\n const openState = typeof value === 'function' ? value(isOpen) : value;\n if (setOpenProp) {\n setOpenProp(openState);\n } else {\n _setOpen(openState);\n }\n },\n [setOpenProp, isOpen],\n );\n\n // Helper to toggle the sidebar.\n const toggleSidebar = React.useCallback(() => {\n return setOpen((open) => !open);\n }, [setOpen]);\n\n // Commented this out pending a discussion with UX about keyboard shortcuts\n // Adds a keyboard shortcut to toggle the sidebar.\n // React.useEffect(() => {\n // const handleKeyDown = (event: KeyboardEvent) => {\n // if (event.key === SIDEBAR_KEYBOARD_SHORTCUT && (event.metaKey || event.ctrlKey)) {\n // event.preventDefault();\n // toggleSidebar();\n // }\n // };\n\n // window.addEventListener('keydown', handleKeyDown);\n // return () => window.removeEventListener('keydown', handleKeyDown);\n // }, [toggleSidebar]);\n\n // We add a state so that we can do data-state=\"expanded\" or \"collapsed\".\n // This makes it easier to style the sidebar with Tailwind classes.\n const state = isOpen ? 'expanded' : 'collapsed';\n\n const contextValue = React.useMemo(\n () => ({\n state,\n open: isOpen,\n setOpen,\n toggleSidebar,\n }),\n [state, isOpen, setOpen, toggleSidebar],\n );\n\n return (\n \n \n \n {children}\n
    \n \n \n );\n },\n);\nSidebarProvider.displayName = 'SidebarProvider';\n\nconst Sidebar = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & {\n side?: 'left' | 'right';\n variant?: 'sidebar' | 'floating' | 'inset';\n collapsible?: 'offcanvas' | 'icon' | 'none';\n }\n>(\n (\n {\n side = 'left',\n variant = 'sidebar',\n collapsible = 'offcanvas',\n className,\n children,\n ...props\n },\n ref,\n ) => {\n const { state } = useSidebar();\n\n if (collapsible === 'none') {\n return (\n \n {children}\n
    \n );\n }\n\n return (\n \n {/* This is what handles the sidebar gap on desktop */}\n \n \n \n {children}\n
    \n
    \n
    \n );\n },\n);\nSidebar.displayName = 'Sidebar';\n\nconst SidebarTrigger = React.forwardRef<\n React.ElementRef,\n React.ComponentProps\n>(({ className, onClick, ...props }, ref) => {\n const { toggleSidebar } = useSidebar();\n\n return (\n {\n onClick?.(event);\n toggleSidebar();\n }}\n {...props}\n >\n \n Toggle Sidebar\n \n );\n});\nSidebarTrigger.displayName = 'SidebarTrigger';\n\nconst SidebarRail = React.forwardRef>(\n ({ className, ...props }, ref) => {\n const { toggleSidebar } = useSidebar();\n\n return (\n \n );\n },\n);\nSidebarRail.displayName = 'SidebarRail';\n\nconst SidebarInset = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarInset.displayName = 'SidebarInset';\n\nconst SidebarInput = React.forwardRef<\n React.ElementRef,\n React.ComponentProps\n>(({ className, ...props }, ref) => {\n return (\n \n );\n});\nSidebarInput.displayName = 'SidebarInput';\n\nconst SidebarHeader = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarHeader.displayName = 'SidebarHeader';\n\nconst SidebarFooter = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarFooter.displayName = 'SidebarFooter';\n\nconst SidebarSeparator = React.forwardRef<\n React.ElementRef,\n React.ComponentProps\n>(({ className, ...props }, ref) => {\n return (\n \n );\n});\nSidebarSeparator.displayName = 'SidebarSeparator';\n\nconst SidebarContent = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarContent.displayName = 'SidebarContent';\n\nconst SidebarGroup = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarGroup.displayName = 'SidebarGroup';\n\nconst SidebarGroupLabel = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & { asChild?: boolean }\n>(({ className, asChild = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'div';\n\n return (\n svg]:tw-size-4 [&>svg]:tw-shrink-0',\n 'group-data-[collapsible=icon]:tw--mt-8 group-data-[collapsible=icon]:tw-opacity-0',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarGroupLabel.displayName = 'SidebarGroupLabel';\n\nconst SidebarGroupAction = React.forwardRef<\n HTMLButtonElement,\n React.ComponentProps<'button'> & { asChild?: boolean }\n>(({ className, asChild = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'button';\n\n return (\n svg]:tw-size-4 [&>svg]:tw-shrink-0',\n // Increases the hit area of the button on mobile.\n 'after:tw-absolute after:tw--inset-2 after:md:tw-hidden',\n 'group-data-[collapsible=icon]:tw-hidden',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarGroupAction.displayName = 'SidebarGroupAction';\n\nconst SidebarGroupContent = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarGroupContent.displayName = 'SidebarGroupContent';\n\nconst SidebarMenu = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenu.displayName = 'SidebarMenu';\n\nconst SidebarMenuItem = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenuItem.displayName = 'SidebarMenuItem';\n\nconst sidebarMenuButtonVariants = cva(\n // Removed data-[active=true]:tw-bg-sidebar-accent\n 'tw-peer/menu-button tw-flex tw-w-full tw-items-center tw-gap-2 tw-overflow-hidden tw-rounded-md tw-p-2 tw-text-left tw-text-sm tw-outline-none tw-ring-sidebar-ring tw-transition-[width,height,padding] hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground focus-visible:tw-ring-2 active:tw-bg-sidebar-accent active:tw-text-sidebar-accent-foreground disabled:tw-pointer-events-none disabled:tw-opacity-50 tw-group-has-[[data-sidebar=menu-action]]/menu-item:pr-8 aria-disabled:tw-pointer-events-none aria-disabled:tw-opacity-50 data-[active=true]:tw-font-medium data-[active=true]:tw-text-sidebar-accent-foreground data-[state=open]:hover:tw-bg-sidebar-accent data-[state=open]:hover:tw-text-sidebar-accent-foreground group-data-[collapsible=icon]:tw-!size-8 group-data-[collapsible=icon]:tw-!p-2 [&>span:last-child]:tw-truncate [&>svg]:tw-size-4 [&>svg]:tw-shrink-0',\n {\n variants: {\n variant: {\n default: 'hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground',\n outline:\n 'tw-bg-background tw-shadow-[0_0_0_1px_hsl(var(--sidebar-border))] hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground hover:tw-shadow-[0_0_0_1px_hsl(var(--sidebar-accent))]',\n },\n size: {\n default: 'tw-h-8 tw-text-sm',\n sm: 'tw-h-7 tw-text-xs',\n lg: 'tw-h-12 tw-text-sm group-data-[collapsible=icon]:tw-!p-0',\n },\n },\n defaultVariants: {\n variant: 'default',\n size: 'default',\n },\n },\n);\n\nconst SidebarMenuButton = React.forwardRef<\n HTMLButtonElement,\n React.ComponentProps<'button'> & {\n asChild?: boolean;\n isActive?: boolean;\n tooltip?: string | React.ComponentProps;\n } & VariantProps\n>(\n (\n {\n asChild = false,\n isActive = false,\n variant = 'default',\n size = 'default',\n tooltip,\n className,\n ...props\n },\n ref,\n ) => {\n const Comp = asChild ? Slot : 'button';\n const { state } = useSidebar();\n\n const button = (\n \n );\n\n if (!tooltip) {\n return button;\n }\n\n if (typeof tooltip === 'string') {\n // eslint-disable-next-line no-param-reassign\n tooltip = {\n children: tooltip,\n };\n }\n\n return (\n \n {button}\n \n );\n },\n);\nSidebarMenuButton.displayName = 'SidebarMenuButton';\n\nconst SidebarMenuAction = React.forwardRef<\n HTMLButtonElement,\n React.ComponentProps<'button'> & {\n asChild?: boolean;\n showOnHover?: boolean;\n }\n>(({ className, asChild = false, showOnHover = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'button';\n\n return (\n svg]:tw-size-4 [&>svg]:tw-shrink-0',\n // Increases the hit area of the button on mobile.\n 'after:tw-absolute after:tw--inset-2 after:md:tw-hidden',\n 'tw-peer-data-[size=sm]/menu-button:top-1',\n 'tw-peer-data-[size=default]/menu-button:top-1.5',\n 'tw-peer-data-[size=lg]/menu-button:top-2.5',\n 'group-data-[collapsible=icon]:tw-hidden',\n showOnHover &&\n 'tw-group-focus-within/menu-item:opacity-100 tw-group-hover/menu-item:opacity-100 tw-peer-data-[active=true]/menu-button:text-sidebar-accent-foreground data-[state=open]:tw-opacity-100 md:tw-opacity-0',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarMenuAction.displayName = 'SidebarMenuAction';\n\nconst SidebarMenuBadge = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenuBadge.displayName = 'SidebarMenuBadge';\n\nconst SidebarMenuSkeleton = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & {\n showIcon?: boolean;\n }\n>(({ className, showIcon = false, ...props }, ref) => {\n // Random width between 50 to 90%.\n const width = React.useMemo(() => {\n return `${Math.floor(Math.random() * 40) + 50}%`;\n }, []);\n\n return (\n \n {showIcon && (\n \n )}\n \n
    \n );\n});\nSidebarMenuSkeleton.displayName = 'SidebarMenuSkeleton';\n\nconst SidebarMenuSub = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenuSub.displayName = 'SidebarMenuSub';\n\nconst SidebarMenuSubItem = React.forwardRef>(\n ({ ...props }, ref) =>
  • ,\n);\nSidebarMenuSubItem.displayName = 'SidebarMenuSubItem';\n\nconst SidebarMenuSubButton = React.forwardRef<\n HTMLAnchorElement,\n React.ComponentProps<'a'> & {\n asChild?: boolean;\n size?: 'sm' | 'md';\n isActive?: boolean;\n }\n>(({ asChild = false, size = 'md', isActive, className, ...props }, ref) => {\n const Comp = asChild ? Slot : 'a';\n\n return (\n svg]:tw-text-sidebar-accent-foreground tw-flex tw-h-7 tw-min-w-0 tw--translate-x-px tw-items-center tw-gap-2 tw-overflow-hidden tw-rounded-md tw-px-2 tw-outline-none focus-visible:tw-ring-2 disabled:tw-pointer-events-none disabled:tw-opacity-50 aria-disabled:tw-pointer-events-none aria-disabled:tw-opacity-50 [&>span:last-child]:tw-truncate [&>svg]:tw-size-4 [&>svg]:tw-shrink-0',\n 'data-[active=true]:tw-bg-sidebar-accent data-[active=true]:tw-text-sidebar-accent-foreground',\n size === 'sm' && 'tw-text-xs',\n size === 'md' && 'tw-text-sm',\n 'group-data-[collapsible=icon]:tw-hidden',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarMenuSubButton.displayName = 'SidebarMenuSubButton';\n\nexport {\n Sidebar,\n SidebarContent,\n SidebarFooter,\n SidebarGroup,\n SidebarGroupAction,\n SidebarGroupContent,\n SidebarGroupLabel,\n SidebarHeader,\n SidebarInput,\n SidebarInset,\n SidebarMenu,\n SidebarMenuAction,\n SidebarMenuBadge,\n SidebarMenuButton,\n SidebarMenuItem,\n SidebarMenuSkeleton,\n SidebarMenuSub,\n SidebarMenuSubButton,\n SidebarMenuSubItem,\n SidebarProvider,\n SidebarRail,\n SidebarSeparator,\n SidebarTrigger,\n useSidebar,\n};\n","import ComboBox, { ComboBoxOption } from '@/components/basics/combo-box.component';\nimport {\n Sidebar,\n SidebarContent,\n SidebarGroup,\n SidebarGroupLabel,\n SidebarGroupContent,\n SidebarMenu,\n SidebarMenuItem,\n SidebarMenuButton,\n} from '@/components/shadcn-ui/sidebar';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { useCallback } from 'react';\n\nexport type SelectedSettingsSidebarItem = {\n label: string;\n projectId?: string;\n};\n\nexport type ProjectInfo = { projectId: string; projectName: string };\n\nexport type SettingsSidebarProps = {\n /** Optional id for testing */\n id?: string;\n\n /** Extension labels from contribution */\n extensionLabels: string[];\n\n /** Project names and ids */\n projectInfo: ProjectInfo[];\n\n /** Handler for selecting a sidebar item */\n handleSelectSidebarItem: (key: string, projectId?: string) => void;\n\n /** The current selected value in the sidebar */\n selectedSidebarItem: SelectedSettingsSidebarItem;\n\n /** Label for the group of extensions setting groups */\n extensionsSidebarGroupLabel: string;\n\n /** Label for the group of projects settings */\n projectsSidebarGroupLabel: string;\n\n /** Placeholder text for the button */\n buttonPlaceholderText: string;\n};\n\nexport default function SettingsSidebar({\n id,\n extensionLabels,\n projectInfo,\n handleSelectSidebarItem,\n selectedSidebarItem,\n extensionsSidebarGroupLabel,\n projectsSidebarGroupLabel,\n buttonPlaceholderText,\n}: SettingsSidebarProps) {\n const handleSelectItem = useCallback(\n (item: string, projectId?: string) => {\n handleSelectSidebarItem(item, projectId);\n },\n [handleSelectSidebarItem],\n );\n\n const getProjectNameFromProjectId = useCallback(\n (projectId: string) => {\n const project = projectInfo.find((info) => info.projectId === projectId);\n return project ? project.projectName : projectId;\n },\n [projectInfo],\n );\n\n const getIsActive: (label: string) => boolean = useCallback(\n (label: string) => !selectedSidebarItem.projectId && label === selectedSidebarItem.label,\n [selectedSidebarItem],\n );\n\n return (\n \n \n \n \n {extensionsSidebarGroupLabel}\n \n \n \n {extensionLabels.map((label) => (\n \n handleSelectItem(label)}\n isActive={getIsActive(label)}\n >\n {label}\n \n \n ))}\n \n \n \n \n \n {projectsSidebarGroupLabel}\n \n \n info.projectId)}\n getOptionLabel={(projectId: ComboBoxOption) => {\n // This function expects a ComboBoxOption, but we know it is a string\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n return getProjectNameFromProjectId(projectId as string);\n }}\n buttonPlaceholder={buttonPlaceholderText}\n onChange={(projectId: string) => {\n const selectedProjectName = getProjectNameFromProjectId(projectId);\n handleSelectItem(selectedProjectName, projectId);\n }}\n value={selectedSidebarItem?.projectId ?? undefined}\n />\n \n \n \n \n );\n}\n","import { SidebarInset, SidebarProvider } from '@/components/shadcn-ui/sidebar';\nimport { PropsWithChildren } from 'react';\nimport SearchBar from '@/components/basics/search-bar.component';\nimport SettingsSidebar, { SettingsSidebarProps } from './settings-sidebar.component';\n\nexport type SettingsSidebarContentSearchProps = SettingsSidebarProps &\n PropsWithChildren & {\n /** Optional id for testing */\n id?: string;\n\n /** Handler to run when the value of the search bar changes */\n onSearch: (searchQuery: string) => void;\n };\n\nexport default function SettingsSidebarContentSearch({\n id,\n extensionLabels,\n projectInfo,\n children,\n handleSelectSidebarItem,\n selectedSidebarItem,\n onSearch,\n extensionsSidebarGroupLabel,\n projectsSidebarGroupLabel,\n buttonPlaceholderText,\n}: SettingsSidebarContentSearchProps) {\n return (\n
    \n
    \n \n
    \n \n \n {children}\n \n
    \n );\n}\n","import { Button } from '@/components/shadcn-ui/button';\nimport {\n Select,\n SelectContent,\n SelectGroup,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\nimport {\n Table,\n TableBody,\n TableCell,\n TableHead,\n TableHeader,\n TableRow,\n} from '@/components/shadcn-ui/table';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Canon } from '@sillsdev/scripture';\nimport {\n Cell,\n ColumnDef,\n flexRender,\n getCoreRowModel,\n getExpandedRowModel,\n getGroupedRowModel,\n getSortedRowModel,\n GroupingState,\n Row,\n RowSelectionState,\n SortingState,\n useReactTable,\n} from '@tanstack/react-table';\nimport '@/components/advanced/scripture-results-viewer/scripture-results-viewer.component.css';\nimport {\n compareScrRefs,\n formatScrRef,\n ScriptureSelection,\n scrRefToBBBCCCVVV,\n} from 'platform-bible-utils';\nimport { MouseEvent, useEffect, useMemo, useState } from 'react';\nimport { ChevronDown, ChevronLeft, ChevronRight } from 'lucide-react';\n\n/**\n * Information (e.g., a checking error or some other type of \"transient\" annotation) about something\n * noteworthy at a specific place in an instance of the Scriptures.\n */\nexport type ScriptureItemDetail = ScriptureSelection & {\n /**\n * Text of the error, note, etc. In the future, we might want to support something more than just\n * text so that a JSX element could be provided with a link or some other controls related to the\n * issue being reported.\n */\n detail: string;\n};\n\n/**\n * A uniquely identifiable source of results that can be displayed in the ScriptureResultsViewer.\n * Generally, the source will be a particular Scripture check, but there may be other types of\n * sources.\n */\nexport type ResultsSource = {\n /**\n * Uniquely identifies the source.\n *\n * @type {string}\n */\n id: string;\n\n /**\n * Name (potentially localized) of the source, suitable for display in the UI.\n *\n * @type {string}\n */\n displayName: string;\n};\n\nexport type ScriptureSrcItemDetail = ScriptureItemDetail & {\n /** Source/type of detail. Can be used for grouping. */\n source: ResultsSource;\n};\n\n/**\n * Represents a set of results keyed by Scripture reference. Generally, the source will be a\n * particular Scripture check, but this type also allows for other types of uniquely identifiable\n * sources.\n */\nexport type ResultsSet = {\n /**\n * The backing source associated with this set of results.\n *\n * @type {ResultsSource}\n */\n source: ResultsSource;\n\n /**\n * Array of Scripture item details (messages keyed by Scripture reference).\n *\n * @type {ScriptureItemDetail[]}\n */\n data: ScriptureItemDetail[];\n};\n\nconst scrBookColId = 'scrBook';\nconst scrRefColId = 'scrRef';\nconst typeColId = 'source';\nconst detailsColId = 'details';\n\nconst defaultScrRefColumnName = 'Scripture Reference';\nconst defaultScrBookGroupName = 'Scripture Book';\nconst defaultTypeColumnName = 'Type';\nconst defaultDetailsColumnName = 'Details';\n\nexport type ScriptureResultsViewerColumnInfo = {\n /** Optional header to display for the Reference column. Default value: 'Scripture Reference'. */\n scriptureReferenceColumnName?: string;\n\n /** Optional text to display to refer to the Scripture book group. Default value: 'Scripture Book'. */\n scriptureBookGroupName?: string;\n\n /** Optional header to display for the Type column. Default value: 'Type'. */\n typeColumnName?: string;\n\n /** Optional header to display for the Details column. Default value: 'Details' */\n detailsColumnName?: string;\n};\n\nexport type ScriptureResultsViewerProps = ScriptureResultsViewerColumnInfo & {\n /** Groups of ScriptureItemDetail objects from particular sources (e.g., Scripture checks) */\n sources: ResultsSet[];\n\n /** Flag indicating whether to display column headers. Default is false. */\n showColumnHeaders?: boolean;\n\n /** Flag indicating whether to display source column. Default is false. */\n showSourceColumn?: boolean;\n\n /** Callback function to notify when a row is selected */\n onRowSelected?: (selectedRow: ScriptureSrcItemDetail | undefined) => void;\n\n /** Text direction ltr or rtl */\n direction?: 'ltr' | 'rtl';\n};\n\nfunction getColumns(\n colInfo?: ScriptureResultsViewerColumnInfo,\n showSourceColumn?: boolean,\n): ColumnDef[] {\n const showSrcCol = showSourceColumn ?? false;\n return [\n {\n accessorFn: (row) =>\n `${Canon.bookNumberToId(row.start.bookNum)} ${row.start.chapterNum}:${row.start.verseNum}`,\n id: scrBookColId,\n header: colInfo?.scriptureReferenceColumnName ?? defaultScrRefColumnName,\n cell: (info) => {\n const row = info.row.original;\n if (info.row.getIsGrouped()) {\n return Canon.bookNumberToEnglishName(row.start.bookNum);\n }\n return info.row.groupingColumnId === scrBookColId ? formatScrRef(row.start) : undefined;\n },\n getGroupingValue: (row) => row.start.bookNum,\n sortingFn: (a, b) => {\n return compareScrRefs(a.original.start, b.original.start);\n },\n enableGrouping: true,\n },\n {\n accessorFn: (row) => formatScrRef(row.start),\n id: scrRefColId,\n header: undefined,\n cell: (info) => {\n const row = info.row.original;\n return info.row.getIsGrouped() ? undefined : formatScrRef(row.start);\n },\n sortingFn: (a, b) => {\n return compareScrRefs(a.original.start, b.original.start);\n },\n enableGrouping: false,\n },\n {\n accessorFn: (row) => row.source.displayName,\n id: typeColId,\n header: showSrcCol ? (colInfo?.typeColumnName ?? defaultTypeColumnName) : undefined,\n cell: (info) => (showSrcCol || info.row.getIsGrouped() ? info.getValue() : undefined),\n getGroupingValue: (row) => row.source.id,\n sortingFn: (a, b) =>\n a.original.source.displayName.localeCompare(b.original.source.displayName),\n enableGrouping: true,\n },\n {\n accessorFn: (row) => row.detail,\n id: detailsColId,\n header: colInfo?.detailsColumnName ?? defaultDetailsColumnName,\n cell: (info) => info.getValue(),\n enableGrouping: false,\n },\n ];\n}\n\nconst toRefOrRange = (scriptureSelection: ScriptureSelection) => {\n if (!('offset' in scriptureSelection.start))\n throw new Error('No offset available in range start');\n if (scriptureSelection.end && !('offset' in scriptureSelection.end))\n throw new Error('No offset available in range end');\n const { offset: offsetStart } = scriptureSelection.start;\n let offsetEnd: number = 0;\n if (scriptureSelection.end) ({ offset: offsetEnd } = scriptureSelection.end);\n if (\n !scriptureSelection.end ||\n compareScrRefs(scriptureSelection.start, scriptureSelection.end) === 0\n )\n return `${scrRefToBBBCCCVVV(scriptureSelection.start)}+${offsetStart}`;\n return `${scrRefToBBBCCCVVV(scriptureSelection.start)}+${offsetStart}-${scrRefToBBBCCCVVV(scriptureSelection.end)}+${offsetEnd}`;\n};\n\nconst getRowKey = (row: ScriptureSrcItemDetail) =>\n `${toRefOrRange({ start: row.start, end: row.end })} ${row.source.displayName} ${row.detail}`;\n\n/**\n * Component to display a combined list of detailed items from one or more sources, where the items\n * are keyed primarily by Scripture reference. This is particularly useful for displaying a list of\n * results from Scripture checks, but more generally could be used to display any \"results\" from any\n * source(s). The component allows for grouping by Scripture book, source, or both. By default, it\n * displays somewhat \"tree-like\" which allows it to be more horizontally compact and intuitive. But\n * it also has the option of displaying as a traditional table with column headings (with or without\n * the source column showing).\n */\nexport default function ScriptureResultsViewer({\n sources,\n showColumnHeaders = false,\n showSourceColumn = false,\n scriptureReferenceColumnName,\n scriptureBookGroupName,\n typeColumnName,\n detailsColumnName,\n onRowSelected,\n direction = 'ltr',\n}: ScriptureResultsViewerProps) {\n const [grouping, setGrouping] = useState([]);\n const [sorting, setSorting] = useState([{ id: scrBookColId, desc: false }]);\n const [rowSelection, setRowSelection] = useState({});\n\n const scriptureResults = useMemo(\n () =>\n sources.flatMap((source) => {\n return source.data.map((item) => ({\n ...item,\n source: source.source,\n }));\n }),\n [sources],\n );\n\n const columns = useMemo(\n () =>\n getColumns(\n {\n scriptureReferenceColumnName,\n typeColumnName,\n detailsColumnName,\n },\n showSourceColumn,\n ),\n [scriptureReferenceColumnName, typeColumnName, detailsColumnName, showSourceColumn],\n );\n\n useEffect(() => {\n // Ensure sorting is applied correctly when grouped by type\n if (grouping.includes(typeColId)) {\n setSorting([\n { id: typeColId, desc: false },\n { id: scrBookColId, desc: false },\n ]);\n } else {\n setSorting([{ id: scrBookColId, desc: false }]);\n }\n }, [grouping]);\n\n const table = useReactTable({\n data: scriptureResults,\n columns,\n state: {\n grouping,\n sorting,\n rowSelection,\n },\n onGroupingChange: setGrouping,\n onSortingChange: setSorting,\n onRowSelectionChange: setRowSelection,\n getExpandedRowModel: getExpandedRowModel(),\n getGroupedRowModel: getGroupedRowModel(),\n getCoreRowModel: getCoreRowModel(),\n getSortedRowModel: getSortedRowModel(),\n getRowId: getRowKey,\n autoResetExpanded: false,\n enableMultiRowSelection: false,\n enableSubRowSelection: false,\n });\n\n useEffect(() => {\n if (onRowSelected) {\n const selectedRows = table.getSelectedRowModel().rowsById;\n const keys = Object.keys(selectedRows);\n if (keys.length === 1) {\n const selectedRow = scriptureResults.find((row) => getRowKey(row) === keys[0]) || undefined;\n if (selectedRow) onRowSelected(selectedRow);\n }\n }\n }, [rowSelection, scriptureResults, onRowSelected, table]);\n\n // Define possible grouping options\n const scrBookGroupName = scriptureBookGroupName ?? defaultScrBookGroupName;\n const typeGroupName = typeColumnName ?? defaultTypeColumnName;\n\n const groupingOptions = [\n { label: 'No Grouping', value: [] },\n { label: `Group by ${scrBookGroupName}`, value: [scrBookColId] },\n { label: `Group by ${typeGroupName}`, value: [typeColId] },\n {\n label: `Group by ${scrBookGroupName} and ${typeGroupName}`,\n value: [scrBookColId, typeColId],\n },\n {\n label: `Group by ${typeGroupName} and ${scrBookGroupName}`,\n value: [typeColId, scrBookColId],\n },\n ];\n\n const handleSelectChange = (selectedGrouping: string) => {\n setGrouping(JSON.parse(selectedGrouping));\n };\n\n const handleRowClick = (row: Row, event: MouseEvent) => {\n if (!row.getIsGrouped() && !row.getIsSelected()) {\n row.getToggleSelectedHandler()(event);\n }\n };\n\n const getEvenOrOddBandingStyle = (row: Row, index: number) => {\n if (row.getIsGrouped()) return '';\n // UX has now said they don't think they want banding. I'm leaving in the code to\n // set even and odd styles, but there's nothing in the CSS to style them differently.\n // The \"even\" style used to also have tw-bg-neutral-300 (along with even) to create\n // a visual banding effect. That could be added back in if UX changes the decision.\n return cn('banded-row', index % 2 === 0 ? 'even' : 'odd');\n };\n\n const getIndent = (\n groupingState: GroupingState,\n row: Row,\n cell: Cell,\n ) => {\n if (groupingState?.length === 0 || row.depth < cell.column.getGroupedIndex()) return undefined;\n if (row.getIsGrouped()) {\n switch (row.depth) {\n case 1:\n return 'tw-ps-4';\n default:\n return undefined;\n }\n }\n switch (row.depth) {\n case 1:\n return 'tw-ps-8';\n case 2:\n return 'tw-ps-12';\n default:\n return undefined;\n }\n };\n\n return (\n
    \n {!showColumnHeaders && (\n {\n handleSelectChange(value);\n }}\n >\n \n \n \n \n \n {groupingOptions.map((option) => (\n \n {option.label}\n \n ))}\n \n \n \n )}\n \n {showColumnHeaders && (\n \n {table.getHeaderGroups().map((headerGroup) => (\n \n {headerGroup.headers\n .filter((h) => h.column.columnDef.header)\n .map((header) => (\n /* For sticky column headers to work, we probably need to change the default definition of the shadcn Table component. See https://github.com/shadcn-ui/ui/issues/1151 */\n \n {header.isPlaceholder ? undefined : (\n
    \n {header.column.getCanGroup() ? (\n \n {header.column.getIsGrouped() ? `🛑` : `👊 `}\n \n ) : undefined}{' '}\n {flexRender(header.column.columnDef.header, header.getContext())}\n
    \n )}\n
    \n ))}\n
    \n ))}\n
    \n )}\n \n {table.getRowModel().rows.map((row, rowIndex) => {\n return (\n handleRowClick(row, event)}\n >\n {row.getVisibleCells().map((cell) => {\n if (\n cell.getIsPlaceholder() ||\n (cell.column.columnDef.enableGrouping &&\n !cell.getIsGrouped() &&\n (cell.column.columnDef.id !== typeColId || !showSourceColumn))\n )\n return undefined;\n return (\n \n {(() => {\n if (cell.getIsGrouped()) {\n return (\n \n {row.getIsExpanded() && }\n {!row.getIsExpanded() &&\n (direction === 'ltr' ? : )}{' '}\n {flexRender(cell.column.columnDef.cell, cell.getContext())} (\n {row.subRows.length})\n \n );\n }\n\n // if (cell.getIsAggregated()) {\n // flexRender(\n // cell.column.columnDef.aggregatedCell ?? cell.column.columnDef.cell,\n // cell.getContext(),\n // );\n // }\n\n return flexRender(cell.column.columnDef.cell, cell.getContext());\n })()}\n \n );\n })}\n \n );\n })}\n \n
    \n
    \n );\n}\n","import {\n getLocalizeKeyForScrollGroupId,\n LanguageStrings,\n ScrollGroupId,\n} from 'platform-bible-utils';\nimport {\n Select,\n SelectContent,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\n\nconst DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS = {\n [getLocalizeKeyForScrollGroupId('undefined')]: 'Ø',\n [getLocalizeKeyForScrollGroupId(0)]: 'A',\n [getLocalizeKeyForScrollGroupId(1)]: 'B',\n [getLocalizeKeyForScrollGroupId(2)]: 'C',\n [getLocalizeKeyForScrollGroupId(3)]: 'D',\n [getLocalizeKeyForScrollGroupId(4)]: 'E',\n [getLocalizeKeyForScrollGroupId(5)]: 'F',\n [getLocalizeKeyForScrollGroupId(6)]: 'G',\n [getLocalizeKeyForScrollGroupId(7)]: 'H',\n [getLocalizeKeyForScrollGroupId(8)]: 'I',\n [getLocalizeKeyForScrollGroupId(9)]: 'J',\n [getLocalizeKeyForScrollGroupId(10)]: 'K',\n [getLocalizeKeyForScrollGroupId(11)]: 'L',\n [getLocalizeKeyForScrollGroupId(12)]: 'M',\n [getLocalizeKeyForScrollGroupId(13)]: 'N',\n [getLocalizeKeyForScrollGroupId(14)]: 'O',\n [getLocalizeKeyForScrollGroupId(15)]: 'P',\n [getLocalizeKeyForScrollGroupId(16)]: 'Q',\n [getLocalizeKeyForScrollGroupId(17)]: 'R',\n [getLocalizeKeyForScrollGroupId(18)]: 'S',\n [getLocalizeKeyForScrollGroupId(19)]: 'T',\n [getLocalizeKeyForScrollGroupId(20)]: 'U',\n [getLocalizeKeyForScrollGroupId(21)]: 'V',\n [getLocalizeKeyForScrollGroupId(22)]: 'W',\n [getLocalizeKeyForScrollGroupId(23)]: 'X',\n [getLocalizeKeyForScrollGroupId(24)]: 'Y',\n [getLocalizeKeyForScrollGroupId(25)]: 'Z',\n};\n\nexport type ScrollGroupSelectorProps = {\n /**\n * List of scroll group ids to show to the user. Either a {@link ScrollGroupId} or `undefined` for\n * no scroll group\n */\n availableScrollGroupIds: (ScrollGroupId | undefined)[];\n /** Currently selected scroll group id. `undefined` for no scroll group */\n scrollGroupId: ScrollGroupId | undefined;\n /** Callback function run when the user tries to change the scroll group id */\n onChangeScrollGroupId: (newScrollGroupId: ScrollGroupId | undefined) => void;\n /**\n * Localized strings to use for displaying scroll group ids. Must be an object whose keys are\n * `getLocalizeKeyForScrollGroupId(scrollGroupId)` for all scroll group ids (and `undefined` if\n * included) in {@link ScrollGroupSelectorProps.availableScrollGroupIds} and whose values are the\n * localized strings to use for those scroll group ids.\n *\n * Defaults to English localizations of English alphabet for scroll groups 0-25 (e.g. 0 is A) and\n * Ø for `undefined`. Will fill in any that are not provided with these English localizations.\n * Also, if any values match the keys, the English localization will be used. This is useful in\n * case you want to pass in a temporary version of the localized strings while your localized\n * strings load.\n *\n * @example\n *\n * ```typescript\n * const myScrollGroupIdLocalizedStrings = {\n * [getLocalizeKeyForScrollGroupId('undefined')]: 'Ø',\n * [getLocalizeKeyForScrollGroupId(0)]: 'A',\n * [getLocalizeKeyForScrollGroupId(1)]: 'B',\n * [getLocalizeKeyForScrollGroupId(2)]: 'C',\n * [getLocalizeKeyForScrollGroupId(3)]: 'D',\n * [getLocalizeKeyForScrollGroupId(4)]: 'E',\n * };\n * ```\n *\n * @example\n *\n * ```tsx\n * const availableScrollGroupIds = [undefined, 0, 1, 2, 3, 4];\n *\n * const localizeKeys = getLocalizeKeysForScrollGroupIds();\n *\n * const [localizedStrings] = useLocalizedStrings(localizeKeys);\n *\n * ...\n *\n * \n * ```\n */\n localizedStrings?: LanguageStrings;\n};\n\n/** Selector component for choosing a scroll group */\nexport default function ScrollGroupSelector({\n availableScrollGroupIds,\n scrollGroupId,\n onChangeScrollGroupId,\n localizedStrings = {},\n}: ScrollGroupSelectorProps) {\n const localizedStringsDefaulted = {\n ...DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS,\n ...Object.fromEntries(\n Object.entries(localizedStrings).map(\n ([localizedStringKey, localizedStringValue]: [string, string]) => [\n localizedStringKey,\n localizedStringKey === localizedStringValue &&\n localizedStringKey in DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS\n ? DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS[localizedStringKey]\n : localizedStringValue,\n ],\n ),\n ),\n };\n return (\n \n onChangeScrollGroupId(\n newScrollGroupString === 'undefined' ? undefined : parseInt(newScrollGroupString, 10),\n )\n }\n >\n \n \n \n \n {availableScrollGroupIds.map((scrollGroupOptionId) => (\n \n {localizedStringsDefaulted[getLocalizeKeyForScrollGroupId(scrollGroupOptionId)]}\n \n ))}\n \n \n );\n}\n","import { PropsWithChildren } from 'react';\nimport { Separator } from '@/components/shadcn-ui/separator';\n\n/** Props for the SettingsList component, currently just children */\ntype SettingsListProps = PropsWithChildren;\n\n/**\n * SettingsList component is a wrapper for list items. Rendered with a formatted div\n *\n * @param children To populate the list with\n * @returns Formatted div encompassing the children\n */\nexport function SettingsList({ children }: SettingsListProps) {\n return
    {children}
    ;\n}\n\n/** Props for SettingsListItem component */\ntype SettingsListItemProps = PropsWithChildren & {\n /** Primary text of the list item */\n primary: string;\n\n /** Optional text of the list item */\n secondary?: string | undefined;\n\n /** Optional boolean to display a message if the children aren't loaded yet. Defaults to false */\n isLoading?: boolean;\n\n /** Optional message to display if isLoading */\n loadingMessage?: string;\n};\n\n/**\n * SettingsListItem component is a common list item. Rendered with a formatted div\n *\n * @param primary Primary text of the list item\n * @param secondary Optional secondary text of the list item\n * @param isLoading Optional, to display a message if the action component isn't generated yet,\n * defaults to false\n * @param children The action component(s) to provide for this item\n * @param loadingMessage Optional, message to display if isLoading\n * @returns Formatted div encompassing the list item content\n */\nexport function SettingsListItem({\n primary,\n secondary,\n children,\n isLoading = false,\n loadingMessage,\n}: SettingsListItemProps) {\n return (\n
    \n
    \n

    {primary}

    \n

    \n {secondary}\n

    \n
    \n\n {isLoading ? (\n

    {loadingMessage}

    \n ) : (\n
    {children}
    \n )}\n
    \n );\n}\n\n/** Props for SettingsListHeader component */\ntype SettingsListHeaderProps = {\n /** The primary text of the list header */\n primary: string;\n\n /** Optional secondary text of the list header */\n secondary?: string | undefined;\n\n /** Optional boolean to include a separator underneath the secondary text. Defaults to false */\n includeSeparator?: boolean;\n};\n\n/**\n * SettingsListHeader component displays text above the list\n *\n * @param primary The primary text of the list header\n * @param secondary Optional secondary text of the list header\n * @param includeSeparator Optional boolean to include a separator underneath the secondary text.\n * Defaults to false\n * @returns Formatted div with list header content\n */\nexport function SettingsListHeader({\n primary,\n secondary,\n includeSeparator = false,\n}: SettingsListHeaderProps) {\n return (\n
    \n
    \n

    {primary}

    \n

    {secondary}

    \n
    \n {includeSeparator ? : ''}\n
    \n );\n}\n","import Checkbox from '@/components/shadcn-ui/checkbox';\nimport { Label } from '@/components/shadcn-ui/label';\n\nexport type ChecklistProps = {\n /** Optional string representing the id attribute of the Checklist */\n id?: string;\n /** Optional string representing CSS class name(s) for styling */\n className?: string;\n /** Array of strings representing the checkable items */\n listItems: string[];\n /** Array of strings representing the checked items */\n selectedListItems: string[];\n /**\n * Function that is called when a checkbox item is selected or deselected\n *\n * @param item The string description for this item\n * @param selected True if selected, false if not selected\n */\n handleSelectListItem: (item: string, selected: boolean) => void;\n\n /**\n * Optional function creates a label for a provided checkable item\n *\n * @param item The item for which a label is to be created\n * @returns A string representing the label text for the checkbox associated with that item\n */\n createLabel?: (item: string) => string;\n};\n\n/** Renders a list of checkboxes. Each checkbox corresponds to an item from the `listItems` array. */\nexport default function Checklist({\n id,\n className,\n listItems,\n selectedListItems,\n handleSelectListItem,\n createLabel,\n}: ChecklistProps) {\n return (\n
    \n {listItems.map((item) => (\n
    \n handleSelectListItem(item, value)}\n />\n \n
    \n ))}\n
    \n );\n}\n","function _interopRequireDefault(obj) {\n return obj && obj.__esModule ? obj : {\n \"default\": obj\n };\n}\nmodule.exports = _interopRequireDefault, module.exports.__esModule = true, module.exports[\"default\"] = module.exports;","export default function chainPropTypes(propType1, propType2) {\n if (process.env.NODE_ENV === 'production') {\n return () => null;\n }\n return function validate(...args) {\n return propType1(...args) || propType2(...args);\n };\n}","export default function _extends() {\n _extends = Object.assign ? Object.assign.bind() : function (target) {\n for (var i = 1; i < arguments.length; i++) {\n var source = arguments[i];\n for (var key in source) {\n if (Object.prototype.hasOwnProperty.call(source, key)) {\n target[key] = source[key];\n }\n }\n }\n return target;\n };\n return _extends.apply(this, arguments);\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\n// https://github.com/sindresorhus/is-plain-obj/blob/main/index.js\nexport function isPlainObject(item) {\n if (typeof item !== 'object' || item === null) {\n return false;\n }\n const prototype = Object.getPrototypeOf(item);\n return (prototype === null || prototype === Object.prototype || Object.getPrototypeOf(prototype) === null) && !(Symbol.toStringTag in item) && !(Symbol.iterator in item);\n}\nfunction deepClone(source) {\n if (!isPlainObject(source)) {\n return source;\n }\n const output = {};\n Object.keys(source).forEach(key => {\n output[key] = deepClone(source[key]);\n });\n return output;\n}\nexport default function deepmerge(target, source, options = {\n clone: true\n}) {\n const output = options.clone ? _extends({}, target) : target;\n if (isPlainObject(target) && isPlainObject(source)) {\n Object.keys(source).forEach(key => {\n // Avoid prototype pollution\n if (key === '__proto__') {\n return;\n }\n if (isPlainObject(source[key]) && key in target && isPlainObject(target[key])) {\n // Since `output` is a clone of `target` and we have narrowed `target` in this block we can cast to the same type.\n output[key] = deepmerge(target[key], source[key], options);\n } else if (options.clone) {\n output[key] = isPlainObject(source[key]) ? deepClone(source[key]) : source[key];\n } else {\n output[key] = source[key];\n }\n });\n }\n return output;\n}","/** @license React v16.13.1\n * react-is.production.min.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';var b=\"function\"===typeof Symbol&&Symbol.for,c=b?Symbol.for(\"react.element\"):60103,d=b?Symbol.for(\"react.portal\"):60106,e=b?Symbol.for(\"react.fragment\"):60107,f=b?Symbol.for(\"react.strict_mode\"):60108,g=b?Symbol.for(\"react.profiler\"):60114,h=b?Symbol.for(\"react.provider\"):60109,k=b?Symbol.for(\"react.context\"):60110,l=b?Symbol.for(\"react.async_mode\"):60111,m=b?Symbol.for(\"react.concurrent_mode\"):60111,n=b?Symbol.for(\"react.forward_ref\"):60112,p=b?Symbol.for(\"react.suspense\"):60113,q=b?\nSymbol.for(\"react.suspense_list\"):60120,r=b?Symbol.for(\"react.memo\"):60115,t=b?Symbol.for(\"react.lazy\"):60116,v=b?Symbol.for(\"react.block\"):60121,w=b?Symbol.for(\"react.fundamental\"):60117,x=b?Symbol.for(\"react.responder\"):60118,y=b?Symbol.for(\"react.scope\"):60119;\nfunction z(a){if(\"object\"===typeof a&&null!==a){var u=a.$$typeof;switch(u){case c:switch(a=a.type,a){case l:case m:case e:case g:case f:case p:return a;default:switch(a=a&&a.$$typeof,a){case k:case n:case t:case r:case h:return a;default:return u}}case d:return u}}}function A(a){return z(a)===m}exports.AsyncMode=l;exports.ConcurrentMode=m;exports.ContextConsumer=k;exports.ContextProvider=h;exports.Element=c;exports.ForwardRef=n;exports.Fragment=e;exports.Lazy=t;exports.Memo=r;exports.Portal=d;\nexports.Profiler=g;exports.StrictMode=f;exports.Suspense=p;exports.isAsyncMode=function(a){return A(a)||z(a)===l};exports.isConcurrentMode=A;exports.isContextConsumer=function(a){return z(a)===k};exports.isContextProvider=function(a){return z(a)===h};exports.isElement=function(a){return\"object\"===typeof a&&null!==a&&a.$$typeof===c};exports.isForwardRef=function(a){return z(a)===n};exports.isFragment=function(a){return z(a)===e};exports.isLazy=function(a){return z(a)===t};\nexports.isMemo=function(a){return z(a)===r};exports.isPortal=function(a){return z(a)===d};exports.isProfiler=function(a){return z(a)===g};exports.isStrictMode=function(a){return z(a)===f};exports.isSuspense=function(a){return z(a)===p};\nexports.isValidElementType=function(a){return\"string\"===typeof a||\"function\"===typeof a||a===e||a===m||a===g||a===f||a===p||a===q||\"object\"===typeof a&&null!==a&&(a.$$typeof===t||a.$$typeof===r||a.$$typeof===h||a.$$typeof===k||a.$$typeof===n||a.$$typeof===w||a.$$typeof===x||a.$$typeof===y||a.$$typeof===v)};exports.typeOf=z;\n","/** @license React v16.13.1\n * react-is.development.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\n\n\nif (process.env.NODE_ENV !== \"production\") {\n (function() {\n'use strict';\n\n// The Symbol used to tag the ReactElement-like types. If there is no native Symbol\n// nor polyfill, then a plain number is used for performance.\nvar hasSymbol = typeof Symbol === 'function' && Symbol.for;\nvar REACT_ELEMENT_TYPE = hasSymbol ? Symbol.for('react.element') : 0xeac7;\nvar REACT_PORTAL_TYPE = hasSymbol ? Symbol.for('react.portal') : 0xeaca;\nvar REACT_FRAGMENT_TYPE = hasSymbol ? Symbol.for('react.fragment') : 0xeacb;\nvar REACT_STRICT_MODE_TYPE = hasSymbol ? Symbol.for('react.strict_mode') : 0xeacc;\nvar REACT_PROFILER_TYPE = hasSymbol ? Symbol.for('react.profiler') : 0xead2;\nvar REACT_PROVIDER_TYPE = hasSymbol ? Symbol.for('react.provider') : 0xeacd;\nvar REACT_CONTEXT_TYPE = hasSymbol ? Symbol.for('react.context') : 0xeace; // TODO: We don't use AsyncMode or ConcurrentMode anymore. They were temporary\n// (unstable) APIs that have been removed. Can we remove the symbols?\n\nvar REACT_ASYNC_MODE_TYPE = hasSymbol ? Symbol.for('react.async_mode') : 0xeacf;\nvar REACT_CONCURRENT_MODE_TYPE = hasSymbol ? Symbol.for('react.concurrent_mode') : 0xeacf;\nvar REACT_FORWARD_REF_TYPE = hasSymbol ? Symbol.for('react.forward_ref') : 0xead0;\nvar REACT_SUSPENSE_TYPE = hasSymbol ? Symbol.for('react.suspense') : 0xead1;\nvar REACT_SUSPENSE_LIST_TYPE = hasSymbol ? Symbol.for('react.suspense_list') : 0xead8;\nvar REACT_MEMO_TYPE = hasSymbol ? Symbol.for('react.memo') : 0xead3;\nvar REACT_LAZY_TYPE = hasSymbol ? Symbol.for('react.lazy') : 0xead4;\nvar REACT_BLOCK_TYPE = hasSymbol ? Symbol.for('react.block') : 0xead9;\nvar REACT_FUNDAMENTAL_TYPE = hasSymbol ? Symbol.for('react.fundamental') : 0xead5;\nvar REACT_RESPONDER_TYPE = hasSymbol ? Symbol.for('react.responder') : 0xead6;\nvar REACT_SCOPE_TYPE = hasSymbol ? Symbol.for('react.scope') : 0xead7;\n\nfunction isValidElementType(type) {\n return typeof type === 'string' || typeof type === 'function' || // Note: its typeof might be other than 'symbol' or 'number' if it's a polyfill.\n type === REACT_FRAGMENT_TYPE || type === REACT_CONCURRENT_MODE_TYPE || type === REACT_PROFILER_TYPE || type === REACT_STRICT_MODE_TYPE || type === REACT_SUSPENSE_TYPE || type === REACT_SUSPENSE_LIST_TYPE || typeof type === 'object' && type !== null && (type.$$typeof === REACT_LAZY_TYPE || type.$$typeof === REACT_MEMO_TYPE || type.$$typeof === REACT_PROVIDER_TYPE || type.$$typeof === REACT_CONTEXT_TYPE || type.$$typeof === REACT_FORWARD_REF_TYPE || type.$$typeof === REACT_FUNDAMENTAL_TYPE || type.$$typeof === REACT_RESPONDER_TYPE || type.$$typeof === REACT_SCOPE_TYPE || type.$$typeof === REACT_BLOCK_TYPE);\n}\n\nfunction typeOf(object) {\n if (typeof object === 'object' && object !== null) {\n var $$typeof = object.$$typeof;\n\n switch ($$typeof) {\n case REACT_ELEMENT_TYPE:\n var type = object.type;\n\n switch (type) {\n case REACT_ASYNC_MODE_TYPE:\n case REACT_CONCURRENT_MODE_TYPE:\n case REACT_FRAGMENT_TYPE:\n case REACT_PROFILER_TYPE:\n case REACT_STRICT_MODE_TYPE:\n case REACT_SUSPENSE_TYPE:\n return type;\n\n default:\n var $$typeofType = type && type.$$typeof;\n\n switch ($$typeofType) {\n case REACT_CONTEXT_TYPE:\n case REACT_FORWARD_REF_TYPE:\n case REACT_LAZY_TYPE:\n case REACT_MEMO_TYPE:\n case REACT_PROVIDER_TYPE:\n return $$typeofType;\n\n default:\n return $$typeof;\n }\n\n }\n\n case REACT_PORTAL_TYPE:\n return $$typeof;\n }\n }\n\n return undefined;\n} // AsyncMode is deprecated along with isAsyncMode\n\nvar AsyncMode = REACT_ASYNC_MODE_TYPE;\nvar ConcurrentMode = REACT_CONCURRENT_MODE_TYPE;\nvar ContextConsumer = REACT_CONTEXT_TYPE;\nvar ContextProvider = REACT_PROVIDER_TYPE;\nvar Element = REACT_ELEMENT_TYPE;\nvar ForwardRef = REACT_FORWARD_REF_TYPE;\nvar Fragment = REACT_FRAGMENT_TYPE;\nvar Lazy = REACT_LAZY_TYPE;\nvar Memo = REACT_MEMO_TYPE;\nvar Portal = REACT_PORTAL_TYPE;\nvar Profiler = REACT_PROFILER_TYPE;\nvar StrictMode = REACT_STRICT_MODE_TYPE;\nvar Suspense = REACT_SUSPENSE_TYPE;\nvar hasWarnedAboutDeprecatedIsAsyncMode = false; // AsyncMode should be deprecated\n\nfunction isAsyncMode(object) {\n {\n if (!hasWarnedAboutDeprecatedIsAsyncMode) {\n hasWarnedAboutDeprecatedIsAsyncMode = true; // Using console['warn'] to evade Babel and ESLint\n\n console['warn']('The ReactIs.isAsyncMode() alias has been deprecated, ' + 'and will be removed in React 17+. Update your code to use ' + 'ReactIs.isConcurrentMode() instead. It has the exact same API.');\n }\n }\n\n return isConcurrentMode(object) || typeOf(object) === REACT_ASYNC_MODE_TYPE;\n}\nfunction isConcurrentMode(object) {\n return typeOf(object) === REACT_CONCURRENT_MODE_TYPE;\n}\nfunction isContextConsumer(object) {\n return typeOf(object) === REACT_CONTEXT_TYPE;\n}\nfunction isContextProvider(object) {\n return typeOf(object) === REACT_PROVIDER_TYPE;\n}\nfunction isElement(object) {\n return typeof object === 'object' && object !== null && object.$$typeof === REACT_ELEMENT_TYPE;\n}\nfunction isForwardRef(object) {\n return typeOf(object) === REACT_FORWARD_REF_TYPE;\n}\nfunction isFragment(object) {\n return typeOf(object) === REACT_FRAGMENT_TYPE;\n}\nfunction isLazy(object) {\n return typeOf(object) === REACT_LAZY_TYPE;\n}\nfunction isMemo(object) {\n return typeOf(object) === REACT_MEMO_TYPE;\n}\nfunction isPortal(object) {\n return typeOf(object) === REACT_PORTAL_TYPE;\n}\nfunction isProfiler(object) {\n return typeOf(object) === REACT_PROFILER_TYPE;\n}\nfunction isStrictMode(object) {\n return typeOf(object) === REACT_STRICT_MODE_TYPE;\n}\nfunction isSuspense(object) {\n return typeOf(object) === REACT_SUSPENSE_TYPE;\n}\n\nexports.AsyncMode = AsyncMode;\nexports.ConcurrentMode = ConcurrentMode;\nexports.ContextConsumer = ContextConsumer;\nexports.ContextProvider = ContextProvider;\nexports.Element = Element;\nexports.ForwardRef = ForwardRef;\nexports.Fragment = Fragment;\nexports.Lazy = Lazy;\nexports.Memo = Memo;\nexports.Portal = Portal;\nexports.Profiler = Profiler;\nexports.StrictMode = StrictMode;\nexports.Suspense = Suspense;\nexports.isAsyncMode = isAsyncMode;\nexports.isConcurrentMode = isConcurrentMode;\nexports.isContextConsumer = isContextConsumer;\nexports.isContextProvider = isContextProvider;\nexports.isElement = isElement;\nexports.isForwardRef = isForwardRef;\nexports.isFragment = isFragment;\nexports.isLazy = isLazy;\nexports.isMemo = isMemo;\nexports.isPortal = isPortal;\nexports.isProfiler = isProfiler;\nexports.isStrictMode = isStrictMode;\nexports.isSuspense = isSuspense;\nexports.isValidElementType = isValidElementType;\nexports.typeOf = typeOf;\n })();\n}\n","'use strict';\n\nif (process.env.NODE_ENV === 'production') {\n module.exports = require('./cjs/react-is.production.min.js');\n} else {\n module.exports = require('./cjs/react-is.development.js');\n}\n","/*\nobject-assign\n(c) Sindre Sorhus\n@license MIT\n*/\n\n'use strict';\n/* eslint-disable no-unused-vars */\nvar getOwnPropertySymbols = Object.getOwnPropertySymbols;\nvar hasOwnProperty = Object.prototype.hasOwnProperty;\nvar propIsEnumerable = Object.prototype.propertyIsEnumerable;\n\nfunction toObject(val) {\n\tif (val === null || val === undefined) {\n\t\tthrow new TypeError('Object.assign cannot be called with null or undefined');\n\t}\n\n\treturn Object(val);\n}\n\nfunction shouldUseNative() {\n\ttry {\n\t\tif (!Object.assign) {\n\t\t\treturn false;\n\t\t}\n\n\t\t// Detect buggy property enumeration order in older V8 versions.\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=4118\n\t\tvar test1 = new String('abc'); // eslint-disable-line no-new-wrappers\n\t\ttest1[5] = 'de';\n\t\tif (Object.getOwnPropertyNames(test1)[0] === '5') {\n\t\t\treturn false;\n\t\t}\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=3056\n\t\tvar test2 = {};\n\t\tfor (var i = 0; i < 10; i++) {\n\t\t\ttest2['_' + String.fromCharCode(i)] = i;\n\t\t}\n\t\tvar order2 = Object.getOwnPropertyNames(test2).map(function (n) {\n\t\t\treturn test2[n];\n\t\t});\n\t\tif (order2.join('') !== '0123456789') {\n\t\t\treturn false;\n\t\t}\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=3056\n\t\tvar test3 = {};\n\t\t'abcdefghijklmnopqrst'.split('').forEach(function (letter) {\n\t\t\ttest3[letter] = letter;\n\t\t});\n\t\tif (Object.keys(Object.assign({}, test3)).join('') !==\n\t\t\t\t'abcdefghijklmnopqrst') {\n\t\t\treturn false;\n\t\t}\n\n\t\treturn true;\n\t} catch (err) {\n\t\t// We don't expect any of the above to throw, but better to be safe.\n\t\treturn false;\n\t}\n}\n\nmodule.exports = shouldUseNative() ? Object.assign : function (target, source) {\n\tvar from;\n\tvar to = toObject(target);\n\tvar symbols;\n\n\tfor (var s = 1; s < arguments.length; s++) {\n\t\tfrom = Object(arguments[s]);\n\n\t\tfor (var key in from) {\n\t\t\tif (hasOwnProperty.call(from, key)) {\n\t\t\t\tto[key] = from[key];\n\t\t\t}\n\t\t}\n\n\t\tif (getOwnPropertySymbols) {\n\t\t\tsymbols = getOwnPropertySymbols(from);\n\t\t\tfor (var i = 0; i < symbols.length; i++) {\n\t\t\t\tif (propIsEnumerable.call(from, symbols[i])) {\n\t\t\t\t\tto[symbols[i]] = from[symbols[i]];\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\n\treturn to;\n};\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar ReactPropTypesSecret = 'SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED';\n\nmodule.exports = ReactPropTypesSecret;\n","module.exports = Function.call.bind(Object.prototype.hasOwnProperty);\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar printWarning = function() {};\n\nif (process.env.NODE_ENV !== 'production') {\n var ReactPropTypesSecret = require('./lib/ReactPropTypesSecret');\n var loggedTypeFailures = {};\n var has = require('./lib/has');\n\n printWarning = function(text) {\n var message = 'Warning: ' + text;\n if (typeof console !== 'undefined') {\n console.error(message);\n }\n try {\n // --- Welcome to debugging React ---\n // This error was thrown as a convenience so that you can use this stack\n // to find the callsite that caused this warning to fire.\n throw new Error(message);\n } catch (x) { /**/ }\n };\n}\n\n/**\n * Assert that the values match with the type specs.\n * Error messages are memorized and will only be shown once.\n *\n * @param {object} typeSpecs Map of name to a ReactPropType\n * @param {object} values Runtime values that need to be type-checked\n * @param {string} location e.g. \"prop\", \"context\", \"child context\"\n * @param {string} componentName Name of the component for error messages.\n * @param {?Function} getStack Returns the component stack.\n * @private\n */\nfunction checkPropTypes(typeSpecs, values, location, componentName, getStack) {\n if (process.env.NODE_ENV !== 'production') {\n for (var typeSpecName in typeSpecs) {\n if (has(typeSpecs, typeSpecName)) {\n var error;\n // Prop type validation may throw. In case they do, we don't want to\n // fail the render phase where it didn't fail before. So we log it.\n // After these have been cleaned up, we'll let them throw.\n try {\n // This is intentionally an invariant that gets caught. It's the same\n // behavior as without this statement except with a better message.\n if (typeof typeSpecs[typeSpecName] !== 'function') {\n var err = Error(\n (componentName || 'React class') + ': ' + location + ' type `' + typeSpecName + '` is invalid; ' +\n 'it must be a function, usually from the `prop-types` package, but received `' + typeof typeSpecs[typeSpecName] + '`.' +\n 'This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.'\n );\n err.name = 'Invariant Violation';\n throw err;\n }\n error = typeSpecs[typeSpecName](values, typeSpecName, componentName, location, null, ReactPropTypesSecret);\n } catch (ex) {\n error = ex;\n }\n if (error && !(error instanceof Error)) {\n printWarning(\n (componentName || 'React class') + ': type specification of ' +\n location + ' `' + typeSpecName + '` is invalid; the type checker ' +\n 'function must return `null` or an `Error` but returned a ' + typeof error + '. ' +\n 'You may have forgotten to pass an argument to the type checker ' +\n 'creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and ' +\n 'shape all require an argument).'\n );\n }\n if (error instanceof Error && !(error.message in loggedTypeFailures)) {\n // Only monitor this failure once because there tends to be a lot of the\n // same error.\n loggedTypeFailures[error.message] = true;\n\n var stack = getStack ? getStack() : '';\n\n printWarning(\n 'Failed ' + location + ' type: ' + error.message + (stack != null ? stack : '')\n );\n }\n }\n }\n }\n}\n\n/**\n * Resets warning cache when testing.\n *\n * @private\n */\ncheckPropTypes.resetWarningCache = function() {\n if (process.env.NODE_ENV !== 'production') {\n loggedTypeFailures = {};\n }\n}\n\nmodule.exports = checkPropTypes;\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar ReactIs = require('react-is');\nvar assign = require('object-assign');\n\nvar ReactPropTypesSecret = require('./lib/ReactPropTypesSecret');\nvar has = require('./lib/has');\nvar checkPropTypes = require('./checkPropTypes');\n\nvar printWarning = function() {};\n\nif (process.env.NODE_ENV !== 'production') {\n printWarning = function(text) {\n var message = 'Warning: ' + text;\n if (typeof console !== 'undefined') {\n console.error(message);\n }\n try {\n // --- Welcome to debugging React ---\n // This error was thrown as a convenience so that you can use this stack\n // to find the callsite that caused this warning to fire.\n throw new Error(message);\n } catch (x) {}\n };\n}\n\nfunction emptyFunctionThatReturnsNull() {\n return null;\n}\n\nmodule.exports = function(isValidElement, throwOnDirectAccess) {\n /* global Symbol */\n var ITERATOR_SYMBOL = typeof Symbol === 'function' && Symbol.iterator;\n var FAUX_ITERATOR_SYMBOL = '@@iterator'; // Before Symbol spec.\n\n /**\n * Returns the iterator method function contained on the iterable object.\n *\n * Be sure to invoke the function with the iterable as context:\n *\n * var iteratorFn = getIteratorFn(myIterable);\n * if (iteratorFn) {\n * var iterator = iteratorFn.call(myIterable);\n * ...\n * }\n *\n * @param {?object} maybeIterable\n * @return {?function}\n */\n function getIteratorFn(maybeIterable) {\n var iteratorFn = maybeIterable && (ITERATOR_SYMBOL && maybeIterable[ITERATOR_SYMBOL] || maybeIterable[FAUX_ITERATOR_SYMBOL]);\n if (typeof iteratorFn === 'function') {\n return iteratorFn;\n }\n }\n\n /**\n * Collection of methods that allow declaration and validation of props that are\n * supplied to React components. Example usage:\n *\n * var Props = require('ReactPropTypes');\n * var MyArticle = React.createClass({\n * propTypes: {\n * // An optional string prop named \"description\".\n * description: Props.string,\n *\n * // A required enum prop named \"category\".\n * category: Props.oneOf(['News','Photos']).isRequired,\n *\n * // A prop named \"dialog\" that requires an instance of Dialog.\n * dialog: Props.instanceOf(Dialog).isRequired\n * },\n * render: function() { ... }\n * });\n *\n * A more formal specification of how these methods are used:\n *\n * type := array|bool|func|object|number|string|oneOf([...])|instanceOf(...)\n * decl := ReactPropTypes.{type}(.isRequired)?\n *\n * Each and every declaration produces a function with the same signature. This\n * allows the creation of custom validation functions. For example:\n *\n * var MyLink = React.createClass({\n * propTypes: {\n * // An optional string or URI prop named \"href\".\n * href: function(props, propName, componentName) {\n * var propValue = props[propName];\n * if (propValue != null && typeof propValue !== 'string' &&\n * !(propValue instanceof URI)) {\n * return new Error(\n * 'Expected a string or an URI for ' + propName + ' in ' +\n * componentName\n * );\n * }\n * }\n * },\n * render: function() {...}\n * });\n *\n * @internal\n */\n\n var ANONYMOUS = '<>';\n\n // Important!\n // Keep this list in sync with production version in `./factoryWithThrowingShims.js`.\n var ReactPropTypes = {\n array: createPrimitiveTypeChecker('array'),\n bigint: createPrimitiveTypeChecker('bigint'),\n bool: createPrimitiveTypeChecker('boolean'),\n func: createPrimitiveTypeChecker('function'),\n number: createPrimitiveTypeChecker('number'),\n object: createPrimitiveTypeChecker('object'),\n string: createPrimitiveTypeChecker('string'),\n symbol: createPrimitiveTypeChecker('symbol'),\n\n any: createAnyTypeChecker(),\n arrayOf: createArrayOfTypeChecker,\n element: createElementTypeChecker(),\n elementType: createElementTypeTypeChecker(),\n instanceOf: createInstanceTypeChecker,\n node: createNodeChecker(),\n objectOf: createObjectOfTypeChecker,\n oneOf: createEnumTypeChecker,\n oneOfType: createUnionTypeChecker,\n shape: createShapeTypeChecker,\n exact: createStrictShapeTypeChecker,\n };\n\n /**\n * inlined Object.is polyfill to avoid requiring consumers ship their own\n * https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object/is\n */\n /*eslint-disable no-self-compare*/\n function is(x, y) {\n // SameValue algorithm\n if (x === y) {\n // Steps 1-5, 7-10\n // Steps 6.b-6.e: +0 != -0\n return x !== 0 || 1 / x === 1 / y;\n } else {\n // Step 6.a: NaN == NaN\n return x !== x && y !== y;\n }\n }\n /*eslint-enable no-self-compare*/\n\n /**\n * We use an Error-like object for backward compatibility as people may call\n * PropTypes directly and inspect their output. However, we don't use real\n * Errors anymore. We don't inspect their stack anyway, and creating them\n * is prohibitively expensive if they are created too often, such as what\n * happens in oneOfType() for any type before the one that matched.\n */\n function PropTypeError(message, data) {\n this.message = message;\n this.data = data && typeof data === 'object' ? data: {};\n this.stack = '';\n }\n // Make `instanceof Error` still work for returned errors.\n PropTypeError.prototype = Error.prototype;\n\n function createChainableTypeChecker(validate) {\n if (process.env.NODE_ENV !== 'production') {\n var manualPropTypeCallCache = {};\n var manualPropTypeWarningCount = 0;\n }\n function checkType(isRequired, props, propName, componentName, location, propFullName, secret) {\n componentName = componentName || ANONYMOUS;\n propFullName = propFullName || propName;\n\n if (secret !== ReactPropTypesSecret) {\n if (throwOnDirectAccess) {\n // New behavior only for users of `prop-types` package\n var err = new Error(\n 'Calling PropTypes validators directly is not supported by the `prop-types` package. ' +\n 'Use `PropTypes.checkPropTypes()` to call them. ' +\n 'Read more at http://fb.me/use-check-prop-types'\n );\n err.name = 'Invariant Violation';\n throw err;\n } else if (process.env.NODE_ENV !== 'production' && typeof console !== 'undefined') {\n // Old behavior for people using React.PropTypes\n var cacheKey = componentName + ':' + propName;\n if (\n !manualPropTypeCallCache[cacheKey] &&\n // Avoid spamming the console because they are often not actionable except for lib authors\n manualPropTypeWarningCount < 3\n ) {\n printWarning(\n 'You are manually calling a React.PropTypes validation ' +\n 'function for the `' + propFullName + '` prop on `' + componentName + '`. This is deprecated ' +\n 'and will throw in the standalone `prop-types` package. ' +\n 'You may be seeing this warning due to a third-party PropTypes ' +\n 'library. See https://fb.me/react-warning-dont-call-proptypes ' + 'for details.'\n );\n manualPropTypeCallCache[cacheKey] = true;\n manualPropTypeWarningCount++;\n }\n }\n }\n if (props[propName] == null) {\n if (isRequired) {\n if (props[propName] === null) {\n return new PropTypeError('The ' + location + ' `' + propFullName + '` is marked as required ' + ('in `' + componentName + '`, but its value is `null`.'));\n }\n return new PropTypeError('The ' + location + ' `' + propFullName + '` is marked as required in ' + ('`' + componentName + '`, but its value is `undefined`.'));\n }\n return null;\n } else {\n return validate(props, propName, componentName, location, propFullName);\n }\n }\n\n var chainedCheckType = checkType.bind(null, false);\n chainedCheckType.isRequired = checkType.bind(null, true);\n\n return chainedCheckType;\n }\n\n function createPrimitiveTypeChecker(expectedType) {\n function validate(props, propName, componentName, location, propFullName, secret) {\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== expectedType) {\n // `propValue` being instance of, say, date/regexp, pass the 'object'\n // check, but we can offer a more precise error message here rather than\n // 'of type `object`'.\n var preciseType = getPreciseType(propValue);\n\n return new PropTypeError(\n 'Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + preciseType + '` supplied to `' + componentName + '`, expected ') + ('`' + expectedType + '`.'),\n {expectedType: expectedType}\n );\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createAnyTypeChecker() {\n return createChainableTypeChecker(emptyFunctionThatReturnsNull);\n }\n\n function createArrayOfTypeChecker(typeChecker) {\n function validate(props, propName, componentName, location, propFullName) {\n if (typeof typeChecker !== 'function') {\n return new PropTypeError('Property `' + propFullName + '` of component `' + componentName + '` has invalid PropType notation inside arrayOf.');\n }\n var propValue = props[propName];\n if (!Array.isArray(propValue)) {\n var propType = getPropType(propValue);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected an array.'));\n }\n for (var i = 0; i < propValue.length; i++) {\n var error = typeChecker(propValue, i, componentName, location, propFullName + '[' + i + ']', ReactPropTypesSecret);\n if (error instanceof Error) {\n return error;\n }\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createElementTypeChecker() {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n if (!isValidElement(propValue)) {\n var propType = getPropType(propValue);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected a single ReactElement.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createElementTypeTypeChecker() {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n if (!ReactIs.isValidElementType(propValue)) {\n var propType = getPropType(propValue);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected a single ReactElement type.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createInstanceTypeChecker(expectedClass) {\n function validate(props, propName, componentName, location, propFullName) {\n if (!(props[propName] instanceof expectedClass)) {\n var expectedClassName = expectedClass.name || ANONYMOUS;\n var actualClassName = getClassName(props[propName]);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + actualClassName + '` supplied to `' + componentName + '`, expected ') + ('instance of `' + expectedClassName + '`.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createEnumTypeChecker(expectedValues) {\n if (!Array.isArray(expectedValues)) {\n if (process.env.NODE_ENV !== 'production') {\n if (arguments.length > 1) {\n printWarning(\n 'Invalid arguments supplied to oneOf, expected an array, got ' + arguments.length + ' arguments. ' +\n 'A common mistake is to write oneOf(x, y, z) instead of oneOf([x, y, z]).'\n );\n } else {\n printWarning('Invalid argument supplied to oneOf, expected an array.');\n }\n }\n return emptyFunctionThatReturnsNull;\n }\n\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n for (var i = 0; i < expectedValues.length; i++) {\n if (is(propValue, expectedValues[i])) {\n return null;\n }\n }\n\n var valuesString = JSON.stringify(expectedValues, function replacer(key, value) {\n var type = getPreciseType(value);\n if (type === 'symbol') {\n return String(value);\n }\n return value;\n });\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of value `' + String(propValue) + '` ' + ('supplied to `' + componentName + '`, expected one of ' + valuesString + '.'));\n }\n return createChainableTypeChecker(validate);\n }\n\n function createObjectOfTypeChecker(typeChecker) {\n function validate(props, propName, componentName, location, propFullName) {\n if (typeof typeChecker !== 'function') {\n return new PropTypeError('Property `' + propFullName + '` of component `' + componentName + '` has invalid PropType notation inside objectOf.');\n }\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== 'object') {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected an object.'));\n }\n for (var key in propValue) {\n if (has(propValue, key)) {\n var error = typeChecker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret);\n if (error instanceof Error) {\n return error;\n }\n }\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createUnionTypeChecker(arrayOfTypeCheckers) {\n if (!Array.isArray(arrayOfTypeCheckers)) {\n process.env.NODE_ENV !== 'production' ? printWarning('Invalid argument supplied to oneOfType, expected an instance of array.') : void 0;\n return emptyFunctionThatReturnsNull;\n }\n\n for (var i = 0; i < arrayOfTypeCheckers.length; i++) {\n var checker = arrayOfTypeCheckers[i];\n if (typeof checker !== 'function') {\n printWarning(\n 'Invalid argument supplied to oneOfType. Expected an array of check functions, but ' +\n 'received ' + getPostfixForTypeWarning(checker) + ' at index ' + i + '.'\n );\n return emptyFunctionThatReturnsNull;\n }\n }\n\n function validate(props, propName, componentName, location, propFullName) {\n var expectedTypes = [];\n for (var i = 0; i < arrayOfTypeCheckers.length; i++) {\n var checker = arrayOfTypeCheckers[i];\n var checkerResult = checker(props, propName, componentName, location, propFullName, ReactPropTypesSecret);\n if (checkerResult == null) {\n return null;\n }\n if (checkerResult.data && has(checkerResult.data, 'expectedType')) {\n expectedTypes.push(checkerResult.data.expectedType);\n }\n }\n var expectedTypesMessage = (expectedTypes.length > 0) ? ', expected one of type [' + expectedTypes.join(', ') + ']': '';\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` supplied to ' + ('`' + componentName + '`' + expectedTypesMessage + '.'));\n }\n return createChainableTypeChecker(validate);\n }\n\n function createNodeChecker() {\n function validate(props, propName, componentName, location, propFullName) {\n if (!isNode(props[propName])) {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` supplied to ' + ('`' + componentName + '`, expected a ReactNode.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function invalidValidatorError(componentName, location, propFullName, key, type) {\n return new PropTypeError(\n (componentName || 'React class') + ': ' + location + ' type `' + propFullName + '.' + key + '` is invalid; ' +\n 'it must be a function, usually from the `prop-types` package, but received `' + type + '`.'\n );\n }\n\n function createShapeTypeChecker(shapeTypes) {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== 'object') {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type `' + propType + '` ' + ('supplied to `' + componentName + '`, expected `object`.'));\n }\n for (var key in shapeTypes) {\n var checker = shapeTypes[key];\n if (typeof checker !== 'function') {\n return invalidValidatorError(componentName, location, propFullName, key, getPreciseType(checker));\n }\n var error = checker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret);\n if (error) {\n return error;\n }\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createStrictShapeTypeChecker(shapeTypes) {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== 'object') {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type `' + propType + '` ' + ('supplied to `' + componentName + '`, expected `object`.'));\n }\n // We need to check all keys in case some are required but missing from props.\n var allKeys = assign({}, props[propName], shapeTypes);\n for (var key in allKeys) {\n var checker = shapeTypes[key];\n if (has(shapeTypes, key) && typeof checker !== 'function') {\n return invalidValidatorError(componentName, location, propFullName, key, getPreciseType(checker));\n }\n if (!checker) {\n return new PropTypeError(\n 'Invalid ' + location + ' `' + propFullName + '` key `' + key + '` supplied to `' + componentName + '`.' +\n '\\nBad object: ' + JSON.stringify(props[propName], null, ' ') +\n '\\nValid keys: ' + JSON.stringify(Object.keys(shapeTypes), null, ' ')\n );\n }\n var error = checker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret);\n if (error) {\n return error;\n }\n }\n return null;\n }\n\n return createChainableTypeChecker(validate);\n }\n\n function isNode(propValue) {\n switch (typeof propValue) {\n case 'number':\n case 'string':\n case 'undefined':\n return true;\n case 'boolean':\n return !propValue;\n case 'object':\n if (Array.isArray(propValue)) {\n return propValue.every(isNode);\n }\n if (propValue === null || isValidElement(propValue)) {\n return true;\n }\n\n var iteratorFn = getIteratorFn(propValue);\n if (iteratorFn) {\n var iterator = iteratorFn.call(propValue);\n var step;\n if (iteratorFn !== propValue.entries) {\n while (!(step = iterator.next()).done) {\n if (!isNode(step.value)) {\n return false;\n }\n }\n } else {\n // Iterator will provide entry [k,v] tuples rather than values.\n while (!(step = iterator.next()).done) {\n var entry = step.value;\n if (entry) {\n if (!isNode(entry[1])) {\n return false;\n }\n }\n }\n }\n } else {\n return false;\n }\n\n return true;\n default:\n return false;\n }\n }\n\n function isSymbol(propType, propValue) {\n // Native Symbol.\n if (propType === 'symbol') {\n return true;\n }\n\n // falsy value can't be a Symbol\n if (!propValue) {\n return false;\n }\n\n // 19.4.3.5 Symbol.prototype[@@toStringTag] === 'Symbol'\n if (propValue['@@toStringTag'] === 'Symbol') {\n return true;\n }\n\n // Fallback for non-spec compliant Symbols which are polyfilled.\n if (typeof Symbol === 'function' && propValue instanceof Symbol) {\n return true;\n }\n\n return false;\n }\n\n // Equivalent of `typeof` but with special handling for array and regexp.\n function getPropType(propValue) {\n var propType = typeof propValue;\n if (Array.isArray(propValue)) {\n return 'array';\n }\n if (propValue instanceof RegExp) {\n // Old webkits (at least until Android 4.0) return 'function' rather than\n // 'object' for typeof a RegExp. We'll normalize this here so that /bla/\n // passes PropTypes.object.\n return 'object';\n }\n if (isSymbol(propType, propValue)) {\n return 'symbol';\n }\n return propType;\n }\n\n // This handles more types than `getPropType`. Only used for error messages.\n // See `createPrimitiveTypeChecker`.\n function getPreciseType(propValue) {\n if (typeof propValue === 'undefined' || propValue === null) {\n return '' + propValue;\n }\n var propType = getPropType(propValue);\n if (propType === 'object') {\n if (propValue instanceof Date) {\n return 'date';\n } else if (propValue instanceof RegExp) {\n return 'regexp';\n }\n }\n return propType;\n }\n\n // Returns a string that is postfixed to a warning about an invalid type.\n // For example, \"undefined\" or \"of type array\"\n function getPostfixForTypeWarning(value) {\n var type = getPreciseType(value);\n switch (type) {\n case 'array':\n case 'object':\n return 'an ' + type;\n case 'boolean':\n case 'date':\n case 'regexp':\n return 'a ' + type;\n default:\n return type;\n }\n }\n\n // Returns class name of the object, if any.\n function getClassName(propValue) {\n if (!propValue.constructor || !propValue.constructor.name) {\n return ANONYMOUS;\n }\n return propValue.constructor.name;\n }\n\n ReactPropTypes.checkPropTypes = checkPropTypes;\n ReactPropTypes.resetWarningCache = checkPropTypes.resetWarningCache;\n ReactPropTypes.PropTypes = ReactPropTypes;\n\n return ReactPropTypes;\n};\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar ReactPropTypesSecret = require('./lib/ReactPropTypesSecret');\n\nfunction emptyFunction() {}\nfunction emptyFunctionWithReset() {}\nemptyFunctionWithReset.resetWarningCache = emptyFunction;\n\nmodule.exports = function() {\n function shim(props, propName, componentName, location, propFullName, secret) {\n if (secret === ReactPropTypesSecret) {\n // It is still safe when called from React.\n return;\n }\n var err = new Error(\n 'Calling PropTypes validators directly is not supported by the `prop-types` package. ' +\n 'Use PropTypes.checkPropTypes() to call them. ' +\n 'Read more at http://fb.me/use-check-prop-types'\n );\n err.name = 'Invariant Violation';\n throw err;\n };\n shim.isRequired = shim;\n function getShim() {\n return shim;\n };\n // Important!\n // Keep this list in sync with production version in `./factoryWithTypeCheckers.js`.\n var ReactPropTypes = {\n array: shim,\n bigint: shim,\n bool: shim,\n func: shim,\n number: shim,\n object: shim,\n string: shim,\n symbol: shim,\n\n any: shim,\n arrayOf: getShim,\n element: shim,\n elementType: shim,\n instanceOf: getShim,\n node: shim,\n objectOf: getShim,\n oneOf: getShim,\n oneOfType: getShim,\n shape: getShim,\n exact: getShim,\n\n checkPropTypes: emptyFunctionWithReset,\n resetWarningCache: emptyFunction\n };\n\n ReactPropTypes.PropTypes = ReactPropTypes;\n\n return ReactPropTypes;\n};\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\nif (process.env.NODE_ENV !== 'production') {\n var ReactIs = require('react-is');\n\n // By explicitly using `prop-types` you are opting into new development behavior.\n // http://fb.me/prop-types-in-prod\n var throwOnDirectAccess = true;\n module.exports = require('./factoryWithTypeCheckers')(ReactIs.isElement, throwOnDirectAccess);\n} else {\n // By explicitly using `prop-types` you are opting into new production behavior.\n // http://fb.me/prop-types-in-prod\n module.exports = require('./factoryWithThrowingShims')();\n}\n","import PropTypes from 'prop-types';\nimport chainPropTypes from '../chainPropTypes';\nfunction isClassComponent(elementType) {\n // elementType.prototype?.isReactComponent\n const {\n prototype = {}\n } = elementType;\n return Boolean(prototype.isReactComponent);\n}\nfunction acceptingRef(props, propName, componentName, location, propFullName) {\n const element = props[propName];\n const safePropName = propFullName || propName;\n if (element == null ||\n // When server-side rendering React doesn't warn either.\n // This is not an accurate check for SSR.\n // This is only in place for Emotion compat.\n // TODO: Revisit once https://github.com/facebook/react/issues/20047 is resolved.\n typeof window === 'undefined') {\n return null;\n }\n let warningHint;\n const elementType = element.type;\n /**\n * Blacklisting instead of whitelisting\n *\n * Blacklisting will miss some components, such as React.Fragment. Those will at least\n * trigger a warning in React.\n * We can't whitelist because there is no safe way to detect React.forwardRef\n * or class components. \"Safe\" means there's no public API.\n *\n */\n if (typeof elementType === 'function' && !isClassComponent(elementType)) {\n warningHint = 'Did you accidentally use a plain function component for an element instead?';\n }\n if (warningHint !== undefined) {\n return new Error(`Invalid ${location} \\`${safePropName}\\` supplied to \\`${componentName}\\`. ` + `Expected an element that can hold a ref. ${warningHint} ` + 'For more information see https://mui.com/r/caveat-with-refs-guide');\n }\n return null;\n}\nconst elementAcceptingRef = chainPropTypes(PropTypes.element, acceptingRef);\nelementAcceptingRef.isRequired = chainPropTypes(PropTypes.element.isRequired, acceptingRef);\nexport default elementAcceptingRef;","import _extends from \"@babel/runtime/helpers/esm/extends\";\n// This module is based on https://github.com/airbnb/prop-types-exact repository.\n// However, in order to reduce the number of dependencies and to remove some extra safe checks\n// the module was forked.\n\nconst specialProperty = 'exact-prop: \\u200b';\nexport default function exactProp(propTypes) {\n if (process.env.NODE_ENV === 'production') {\n return propTypes;\n }\n return _extends({}, propTypes, {\n [specialProperty]: props => {\n const unsupportedProps = Object.keys(props).filter(prop => !propTypes.hasOwnProperty(prop));\n if (unsupportedProps.length > 0) {\n return new Error(`The following props are not supported: ${unsupportedProps.map(prop => `\\`${prop}\\``).join(', ')}. Please remove them.`);\n }\n return null;\n }\n });\n}","/**\n * WARNING: Don't import this directly.\n * Use `MuiError` from `@mui/internal-babel-macros/MuiError.macro` instead.\n * @param {number} code\n */\nexport default function formatMuiErrorMessage(code) {\n // Apply babel-plugin-transform-template-literals in loose mode\n // loose mode is safe if we're concatenating primitives\n // see https://babeljs.io/docs/en/babel-plugin-transform-template-literals#loose\n /* eslint-disable prefer-template */\n let url = 'https://mui.com/production-error/?code=' + code;\n for (let i = 1; i < arguments.length; i += 1) {\n // rest params over-transpile for this case\n // eslint-disable-next-line prefer-rest-params\n url += '&args[]=' + encodeURIComponent(arguments[i]);\n }\n return 'Minified MUI error #' + code + '; visit ' + url + ' for the full message.';\n /* eslint-enable prefer-template */\n}","/**\n * @license React\n * react-is.production.min.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n'use strict';var b=Symbol.for(\"react.element\"),c=Symbol.for(\"react.portal\"),d=Symbol.for(\"react.fragment\"),e=Symbol.for(\"react.strict_mode\"),f=Symbol.for(\"react.profiler\"),g=Symbol.for(\"react.provider\"),h=Symbol.for(\"react.context\"),k=Symbol.for(\"react.server_context\"),l=Symbol.for(\"react.forward_ref\"),m=Symbol.for(\"react.suspense\"),n=Symbol.for(\"react.suspense_list\"),p=Symbol.for(\"react.memo\"),q=Symbol.for(\"react.lazy\"),t=Symbol.for(\"react.offscreen\"),u;u=Symbol.for(\"react.module.reference\");\nfunction v(a){if(\"object\"===typeof a&&null!==a){var r=a.$$typeof;switch(r){case b:switch(a=a.type,a){case d:case f:case e:case m:case n:return a;default:switch(a=a&&a.$$typeof,a){case k:case h:case l:case q:case p:case g:return a;default:return r}}case c:return r}}}exports.ContextConsumer=h;exports.ContextProvider=g;exports.Element=b;exports.ForwardRef=l;exports.Fragment=d;exports.Lazy=q;exports.Memo=p;exports.Portal=c;exports.Profiler=f;exports.StrictMode=e;exports.Suspense=m;\nexports.SuspenseList=n;exports.isAsyncMode=function(){return!1};exports.isConcurrentMode=function(){return!1};exports.isContextConsumer=function(a){return v(a)===h};exports.isContextProvider=function(a){return v(a)===g};exports.isElement=function(a){return\"object\"===typeof a&&null!==a&&a.$$typeof===b};exports.isForwardRef=function(a){return v(a)===l};exports.isFragment=function(a){return v(a)===d};exports.isLazy=function(a){return v(a)===q};exports.isMemo=function(a){return v(a)===p};\nexports.isPortal=function(a){return v(a)===c};exports.isProfiler=function(a){return v(a)===f};exports.isStrictMode=function(a){return v(a)===e};exports.isSuspense=function(a){return v(a)===m};exports.isSuspenseList=function(a){return v(a)===n};\nexports.isValidElementType=function(a){return\"string\"===typeof a||\"function\"===typeof a||a===d||a===f||a===e||a===m||a===n||a===t||\"object\"===typeof a&&null!==a&&(a.$$typeof===q||a.$$typeof===p||a.$$typeof===g||a.$$typeof===h||a.$$typeof===l||a.$$typeof===u||void 0!==a.getModuleId)?!0:!1};exports.typeOf=v;\n","/**\n * @license React\n * react-is.development.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nif (process.env.NODE_ENV !== \"production\") {\n (function() {\n'use strict';\n\n// ATTENTION\n// When adding new symbols to this file,\n// Please consider also adding to 'react-devtools-shared/src/backend/ReactSymbols'\n// The Symbol used to tag the ReactElement-like types.\nvar REACT_ELEMENT_TYPE = Symbol.for('react.element');\nvar REACT_PORTAL_TYPE = Symbol.for('react.portal');\nvar REACT_FRAGMENT_TYPE = Symbol.for('react.fragment');\nvar REACT_STRICT_MODE_TYPE = Symbol.for('react.strict_mode');\nvar REACT_PROFILER_TYPE = Symbol.for('react.profiler');\nvar REACT_PROVIDER_TYPE = Symbol.for('react.provider');\nvar REACT_CONTEXT_TYPE = Symbol.for('react.context');\nvar REACT_SERVER_CONTEXT_TYPE = Symbol.for('react.server_context');\nvar REACT_FORWARD_REF_TYPE = Symbol.for('react.forward_ref');\nvar REACT_SUSPENSE_TYPE = Symbol.for('react.suspense');\nvar REACT_SUSPENSE_LIST_TYPE = Symbol.for('react.suspense_list');\nvar REACT_MEMO_TYPE = Symbol.for('react.memo');\nvar REACT_LAZY_TYPE = Symbol.for('react.lazy');\nvar REACT_OFFSCREEN_TYPE = Symbol.for('react.offscreen');\n\n// -----------------------------------------------------------------------------\n\nvar enableScopeAPI = false; // Experimental Create Event Handle API.\nvar enableCacheElement = false;\nvar enableTransitionTracing = false; // No known bugs, but needs performance testing\n\nvar enableLegacyHidden = false; // Enables unstable_avoidThisFallback feature in Fiber\n// stuff. Intended to enable React core members to more easily debug scheduling\n// issues in DEV builds.\n\nvar enableDebugTracing = false; // Track which Fiber(s) schedule render work.\n\nvar REACT_MODULE_REFERENCE;\n\n{\n REACT_MODULE_REFERENCE = Symbol.for('react.module.reference');\n}\n\nfunction isValidElementType(type) {\n if (typeof type === 'string' || typeof type === 'function') {\n return true;\n } // Note: typeof might be other than 'symbol' or 'number' (e.g. if it's a polyfill).\n\n\n if (type === REACT_FRAGMENT_TYPE || type === REACT_PROFILER_TYPE || enableDebugTracing || type === REACT_STRICT_MODE_TYPE || type === REACT_SUSPENSE_TYPE || type === REACT_SUSPENSE_LIST_TYPE || enableLegacyHidden || type === REACT_OFFSCREEN_TYPE || enableScopeAPI || enableCacheElement || enableTransitionTracing ) {\n return true;\n }\n\n if (typeof type === 'object' && type !== null) {\n if (type.$$typeof === REACT_LAZY_TYPE || type.$$typeof === REACT_MEMO_TYPE || type.$$typeof === REACT_PROVIDER_TYPE || type.$$typeof === REACT_CONTEXT_TYPE || type.$$typeof === REACT_FORWARD_REF_TYPE || // This needs to include all possible module reference object\n // types supported by any Flight configuration anywhere since\n // we don't know which Flight build this will end up being used\n // with.\n type.$$typeof === REACT_MODULE_REFERENCE || type.getModuleId !== undefined) {\n return true;\n }\n }\n\n return false;\n}\n\nfunction typeOf(object) {\n if (typeof object === 'object' && object !== null) {\n var $$typeof = object.$$typeof;\n\n switch ($$typeof) {\n case REACT_ELEMENT_TYPE:\n var type = object.type;\n\n switch (type) {\n case REACT_FRAGMENT_TYPE:\n case REACT_PROFILER_TYPE:\n case REACT_STRICT_MODE_TYPE:\n case REACT_SUSPENSE_TYPE:\n case REACT_SUSPENSE_LIST_TYPE:\n return type;\n\n default:\n var $$typeofType = type && type.$$typeof;\n\n switch ($$typeofType) {\n case REACT_SERVER_CONTEXT_TYPE:\n case REACT_CONTEXT_TYPE:\n case REACT_FORWARD_REF_TYPE:\n case REACT_LAZY_TYPE:\n case REACT_MEMO_TYPE:\n case REACT_PROVIDER_TYPE:\n return $$typeofType;\n\n default:\n return $$typeof;\n }\n\n }\n\n case REACT_PORTAL_TYPE:\n return $$typeof;\n }\n }\n\n return undefined;\n}\nvar ContextConsumer = REACT_CONTEXT_TYPE;\nvar ContextProvider = REACT_PROVIDER_TYPE;\nvar Element = REACT_ELEMENT_TYPE;\nvar ForwardRef = REACT_FORWARD_REF_TYPE;\nvar Fragment = REACT_FRAGMENT_TYPE;\nvar Lazy = REACT_LAZY_TYPE;\nvar Memo = REACT_MEMO_TYPE;\nvar Portal = REACT_PORTAL_TYPE;\nvar Profiler = REACT_PROFILER_TYPE;\nvar StrictMode = REACT_STRICT_MODE_TYPE;\nvar Suspense = REACT_SUSPENSE_TYPE;\nvar SuspenseList = REACT_SUSPENSE_LIST_TYPE;\nvar hasWarnedAboutDeprecatedIsAsyncMode = false;\nvar hasWarnedAboutDeprecatedIsConcurrentMode = false; // AsyncMode should be deprecated\n\nfunction isAsyncMode(object) {\n {\n if (!hasWarnedAboutDeprecatedIsAsyncMode) {\n hasWarnedAboutDeprecatedIsAsyncMode = true; // Using console['warn'] to evade Babel and ESLint\n\n console['warn']('The ReactIs.isAsyncMode() alias has been deprecated, ' + 'and will be removed in React 18+.');\n }\n }\n\n return false;\n}\nfunction isConcurrentMode(object) {\n {\n if (!hasWarnedAboutDeprecatedIsConcurrentMode) {\n hasWarnedAboutDeprecatedIsConcurrentMode = true; // Using console['warn'] to evade Babel and ESLint\n\n console['warn']('The ReactIs.isConcurrentMode() alias has been deprecated, ' + 'and will be removed in React 18+.');\n }\n }\n\n return false;\n}\nfunction isContextConsumer(object) {\n return typeOf(object) === REACT_CONTEXT_TYPE;\n}\nfunction isContextProvider(object) {\n return typeOf(object) === REACT_PROVIDER_TYPE;\n}\nfunction isElement(object) {\n return typeof object === 'object' && object !== null && object.$$typeof === REACT_ELEMENT_TYPE;\n}\nfunction isForwardRef(object) {\n return typeOf(object) === REACT_FORWARD_REF_TYPE;\n}\nfunction isFragment(object) {\n return typeOf(object) === REACT_FRAGMENT_TYPE;\n}\nfunction isLazy(object) {\n return typeOf(object) === REACT_LAZY_TYPE;\n}\nfunction isMemo(object) {\n return typeOf(object) === REACT_MEMO_TYPE;\n}\nfunction isPortal(object) {\n return typeOf(object) === REACT_PORTAL_TYPE;\n}\nfunction isProfiler(object) {\n return typeOf(object) === REACT_PROFILER_TYPE;\n}\nfunction isStrictMode(object) {\n return typeOf(object) === REACT_STRICT_MODE_TYPE;\n}\nfunction isSuspense(object) {\n return typeOf(object) === REACT_SUSPENSE_TYPE;\n}\nfunction isSuspenseList(object) {\n return typeOf(object) === REACT_SUSPENSE_LIST_TYPE;\n}\n\nexports.ContextConsumer = ContextConsumer;\nexports.ContextProvider = ContextProvider;\nexports.Element = Element;\nexports.ForwardRef = ForwardRef;\nexports.Fragment = Fragment;\nexports.Lazy = Lazy;\nexports.Memo = Memo;\nexports.Portal = Portal;\nexports.Profiler = Profiler;\nexports.StrictMode = StrictMode;\nexports.Suspense = Suspense;\nexports.SuspenseList = SuspenseList;\nexports.isAsyncMode = isAsyncMode;\nexports.isConcurrentMode = isConcurrentMode;\nexports.isContextConsumer = isContextConsumer;\nexports.isContextProvider = isContextProvider;\nexports.isElement = isElement;\nexports.isForwardRef = isForwardRef;\nexports.isFragment = isFragment;\nexports.isLazy = isLazy;\nexports.isMemo = isMemo;\nexports.isPortal = isPortal;\nexports.isProfiler = isProfiler;\nexports.isStrictMode = isStrictMode;\nexports.isSuspense = isSuspense;\nexports.isSuspenseList = isSuspenseList;\nexports.isValidElementType = isValidElementType;\nexports.typeOf = typeOf;\n })();\n}\n","'use strict';\n\nif (process.env.NODE_ENV === 'production') {\n module.exports = require('./cjs/react-is.production.min.js');\n} else {\n module.exports = require('./cjs/react-is.development.js');\n}\n","import { ForwardRef, Memo } from 'react-is';\n\n// Simplified polyfill for IE11 support\n// https://github.com/JamesMGreene/Function.name/blob/58b314d4a983110c3682f1228f845d39ccca1817/Function.name.js#L3\nconst fnNameMatchRegex = /^\\s*function(?:\\s|\\s*\\/\\*.*\\*\\/\\s*)+([^(\\s/]*)\\s*/;\nexport function getFunctionName(fn) {\n const match = `${fn}`.match(fnNameMatchRegex);\n const name = match && match[1];\n return name || '';\n}\nfunction getFunctionComponentName(Component, fallback = '') {\n return Component.displayName || Component.name || getFunctionName(Component) || fallback;\n}\nfunction getWrappedName(outerType, innerType, wrapperName) {\n const functionName = getFunctionComponentName(innerType);\n return outerType.displayName || (functionName !== '' ? `${wrapperName}(${functionName})` : wrapperName);\n}\n\n/**\n * cherry-pick from\n * https://github.com/facebook/react/blob/769b1f270e1251d9dbdce0fcbd9e92e502d059b8/packages/shared/getComponentName.js\n * originally forked from recompose/getDisplayName with added IE11 support\n */\nexport default function getDisplayName(Component) {\n if (Component == null) {\n return undefined;\n }\n if (typeof Component === 'string') {\n return Component;\n }\n if (typeof Component === 'function') {\n return getFunctionComponentName(Component, 'Component');\n }\n\n // TypeScript can't have components as objects but they exist in the form of `memo` or `Suspense`\n if (typeof Component === 'object') {\n switch (Component.$$typeof) {\n case ForwardRef:\n return getWrappedName(Component, Component.render, 'ForwardRef');\n case Memo:\n return getWrappedName(Component, Component.type, 'memo');\n default:\n return undefined;\n }\n }\n return undefined;\n}","export default function HTMLElementType(props, propName, componentName, location, propFullName) {\n if (process.env.NODE_ENV === 'production') {\n return null;\n }\n const propValue = props[propName];\n const safePropName = propFullName || propName;\n if (propValue == null) {\n return null;\n }\n if (propValue && propValue.nodeType !== 1) {\n return new Error(`Invalid ${location} \\`${safePropName}\\` supplied to \\`${componentName}\\`. ` + `Expected an HTMLElement.`);\n }\n return null;\n}","import PropTypes from 'prop-types';\nconst refType = PropTypes.oneOfType([PropTypes.func, PropTypes.object]);\nexport default refType;","import _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\n// It should to be noted that this function isn't equivalent to `text-transform: capitalize`.\n//\n// A strict capitalization should uppercase the first letter of each word in the sentence.\n// We only handle the first word.\nexport default function capitalize(string) {\n if (typeof string !== 'string') {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: \\`capitalize(string)\\` expects a string argument.` : _formatMuiErrorMessage(7));\n }\n return string.charAt(0).toUpperCase() + string.slice(1);\n}","/**\n * Safe chained function.\n *\n * Will only create a new function if needed,\n * otherwise will pass back existing functions or null.\n */\nexport default function createChainedFunction(...funcs) {\n return funcs.reduce((acc, func) => {\n if (func == null) {\n return acc;\n }\n return function chainedFunction(...args) {\n acc.apply(this, args);\n func.apply(this, args);\n };\n }, () => {});\n}","// Corresponds to 10 frames at 60 Hz.\n// A few bytes payload overhead when lodash/debounce is ~3 kB and debounce ~300 B.\nexport default function debounce(func, wait = 166) {\n let timeout;\n function debounced(...args) {\n const later = () => {\n // @ts-ignore\n func.apply(this, args);\n };\n clearTimeout(timeout);\n timeout = setTimeout(later, wait);\n }\n debounced.clear = () => {\n clearTimeout(timeout);\n };\n return debounced;\n}","export default function deprecatedPropType(validator, reason) {\n if (process.env.NODE_ENV === 'production') {\n return () => null;\n }\n return (props, propName, componentName, location, propFullName) => {\n const componentNameSafe = componentName || '<>';\n const propFullNameSafe = propFullName || propName;\n if (typeof props[propName] !== 'undefined') {\n return new Error(`The ${location} \\`${propFullNameSafe}\\` of ` + `\\`${componentNameSafe}\\` is deprecated. ${reason}`);\n }\n return null;\n };\n}","import * as React from 'react';\nexport default function isMuiElement(element, muiNames) {\n var _muiName, _element$type;\n return /*#__PURE__*/React.isValidElement(element) && muiNames.indexOf( // For server components `muiName` is avaialble in element.type._payload.value.muiName\n // relevant info - https://github.com/facebook/react/blob/2807d781a08db8e9873687fccc25c0f12b4fb3d4/packages/react/src/ReactLazy.js#L45\n // eslint-disable-next-line no-underscore-dangle\n (_muiName = element.type.muiName) != null ? _muiName : (_element$type = element.type) == null || (_element$type = _element$type._payload) == null || (_element$type = _element$type.value) == null ? void 0 : _element$type.muiName) !== -1;\n}","export default function ownerDocument(node) {\n return node && node.ownerDocument || document;\n}","import ownerDocument from '../ownerDocument';\nexport default function ownerWindow(node) {\n const doc = ownerDocument(node);\n return doc.defaultView || window;\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nexport default function requirePropFactory(componentNameInError, Component) {\n if (process.env.NODE_ENV === 'production') {\n return () => null;\n }\n\n // eslint-disable-next-line react/forbid-foreign-prop-types\n const prevPropTypes = Component ? _extends({}, Component.propTypes) : null;\n const requireProp = requiredProp => (props, propName, componentName, location, propFullName, ...args) => {\n const propFullNameSafe = propFullName || propName;\n const defaultTypeChecker = prevPropTypes == null ? void 0 : prevPropTypes[propFullNameSafe];\n if (defaultTypeChecker) {\n const typeCheckerResult = defaultTypeChecker(props, propName, componentName, location, propFullName, ...args);\n if (typeCheckerResult) {\n return typeCheckerResult;\n }\n }\n if (typeof props[propName] !== 'undefined' && !props[requiredProp]) {\n return new Error(`The prop \\`${propFullNameSafe}\\` of ` + `\\`${componentNameInError}\\` can only be used together with the \\`${requiredProp}\\` prop.`);\n }\n return null;\n };\n return requireProp;\n}","/**\n * TODO v5: consider making it private\n *\n * passes {value} to {ref}\n *\n * WARNING: Be sure to only call this inside a callback that is passed as a ref.\n * Otherwise, make sure to cleanup the previous {ref} if it changes. See\n * https://github.com/mui/material-ui/issues/13539\n *\n * Useful if you want to expose the ref of an inner component to the public API\n * while still using it inside the component.\n * @param ref A ref callback or ref object. If anything falsy, this is a no-op.\n */\nexport default function setRef(ref, value) {\n if (typeof ref === 'function') {\n ref(value);\n } else if (ref) {\n ref.current = value;\n }\n}","'use client';\n\nimport * as React from 'react';\n\n/**\n * A version of `React.useLayoutEffect` that does not show a warning when server-side rendering.\n * This is useful for effects that are only needed for client-side rendering but not for SSR.\n *\n * Before you use this hook, make sure to read https://gist.github.com/gaearon/e7d97cdf38a2907924ea12e4ebdf3c85\n * and confirm it doesn't apply to your use-case.\n */\nconst useEnhancedEffect = typeof window !== 'undefined' ? React.useLayoutEffect : React.useEffect;\nexport default useEnhancedEffect;","'use client';\n\nimport * as React from 'react';\nlet globalId = 0;\nfunction useGlobalId(idOverride) {\n const [defaultId, setDefaultId] = React.useState(idOverride);\n const id = idOverride || defaultId;\n React.useEffect(() => {\n if (defaultId == null) {\n // Fallback to this default id when possible.\n // Use the incrementing value for client-side rendering only.\n // We can't use it server-side.\n // If you want to use random values please consider the Birthday Problem: https://en.wikipedia.org/wiki/Birthday_problem\n globalId += 1;\n setDefaultId(`mui-${globalId}`);\n }\n }, [defaultId]);\n return id;\n}\n\n// downstream bundlers may remove unnecessary concatenation, but won't remove toString call -- Workaround for https://github.com/webpack/webpack/issues/14814\nconst maybeReactUseId = React['useId'.toString()];\n/**\n *\n * @example
    \n * @param idOverride\n * @returns {string}\n */\nexport default function useId(idOverride) {\n if (maybeReactUseId !== undefined) {\n const reactId = maybeReactUseId();\n return idOverride != null ? idOverride : reactId;\n }\n // eslint-disable-next-line react-hooks/rules-of-hooks -- `React.useId` is invariant at runtime.\n return useGlobalId(idOverride);\n}","export default function unsupportedProp(props, propName, componentName, location, propFullName) {\n if (process.env.NODE_ENV === 'production') {\n return null;\n }\n const propFullNameSafe = propFullName || propName;\n if (typeof props[propName] !== 'undefined') {\n return new Error(`The prop \\`${propFullNameSafe}\\` is not supported. Please remove it.`);\n }\n return null;\n}","'use client';\n\n/* eslint-disable react-hooks/rules-of-hooks, react-hooks/exhaustive-deps */\nimport * as React from 'react';\nexport default function useControlled({\n controlled,\n default: defaultProp,\n name,\n state = 'value'\n}) {\n // isControlled is ignored in the hook dependency lists as it should never change.\n const {\n current: isControlled\n } = React.useRef(controlled !== undefined);\n const [valueState, setValue] = React.useState(defaultProp);\n const value = isControlled ? controlled : valueState;\n if (process.env.NODE_ENV !== 'production') {\n React.useEffect(() => {\n if (isControlled !== (controlled !== undefined)) {\n console.error([`MUI: A component is changing the ${isControlled ? '' : 'un'}controlled ${state} state of ${name} to be ${isControlled ? 'un' : ''}controlled.`, 'Elements should not switch from uncontrolled to controlled (or vice versa).', `Decide between using a controlled or uncontrolled ${name} ` + 'element for the lifetime of the component.', \"The nature of the state is determined during the first render. It's considered controlled if the value is not `undefined`.\", 'More info: https://fb.me/react-controlled-components'].join('\\n'));\n }\n }, [state, name, controlled]);\n const {\n current: defaultValue\n } = React.useRef(defaultProp);\n React.useEffect(() => {\n if (!isControlled && defaultValue !== defaultProp) {\n console.error([`MUI: A component is changing the default ${state} state of an uncontrolled ${name} after being initialized. ` + `To suppress this warning opt to use a controlled ${name}.`].join('\\n'));\n }\n }, [JSON.stringify(defaultProp)]);\n }\n const setValueIfUncontrolled = React.useCallback(newValue => {\n if (!isControlled) {\n setValue(newValue);\n }\n }, []);\n return [value, setValueIfUncontrolled];\n}","'use client';\n\nimport * as React from 'react';\nimport useEnhancedEffect from '../useEnhancedEffect';\n\n/**\n * Inspired by https://github.com/facebook/react/issues/14099#issuecomment-440013892\n * See RFC in https://github.com/reactjs/rfcs/pull/220\n */\n\nfunction useEventCallback(fn) {\n const ref = React.useRef(fn);\n useEnhancedEffect(() => {\n ref.current = fn;\n });\n return React.useRef((...args) =>\n // @ts-expect-error hide `this`\n (0, ref.current)(...args)).current;\n}\nexport default useEventCallback;","'use client';\n\nimport * as React from 'react';\nimport setRef from '../setRef';\nexport default function useForkRef(...refs) {\n /**\n * This will create a new function if the refs passed to this hook change and are all defined.\n * This means react will call the old forkRef with `null` and the new forkRef\n * with the ref. Cleanup naturally emerges from this behavior.\n */\n return React.useMemo(() => {\n if (refs.every(ref => ref == null)) {\n return null;\n }\n return instance => {\n refs.forEach(ref => {\n setRef(ref, instance);\n });\n };\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, refs);\n}","'use client';\n\nimport * as React from 'react';\nconst UNINITIALIZED = {};\n\n/**\n * A React.useRef() that is initialized lazily with a function. Note that it accepts an optional\n * initialization argument, so the initialization function doesn't need to be an inline closure.\n *\n * @usage\n * const ref = useLazyRef(sortColumns, columns)\n */\nexport default function useLazyRef(init, initArg) {\n const ref = React.useRef(UNINITIALIZED);\n if (ref.current === UNINITIALIZED) {\n ref.current = init(initArg);\n }\n return ref;\n}","'use client';\n\nimport * as React from 'react';\nconst EMPTY = [];\n\n/**\n * A React.useEffect equivalent that runs once, when the component is mounted.\n */\nexport default function useOnMount(fn) {\n /* eslint-disable react-hooks/exhaustive-deps */\n React.useEffect(fn, EMPTY);\n /* eslint-enable react-hooks/exhaustive-deps */\n}","'use client';\n\nimport useLazyRef from '../useLazyRef/useLazyRef';\nimport useOnMount from '../useOnMount/useOnMount';\nexport class Timeout {\n constructor() {\n this.currentId = null;\n this.clear = () => {\n if (this.currentId !== null) {\n clearTimeout(this.currentId);\n this.currentId = null;\n }\n };\n this.disposeEffect = () => {\n return this.clear;\n };\n }\n static create() {\n return new Timeout();\n }\n /**\n * Executes `fn` after `delay`, clearing any previously scheduled call.\n */\n start(delay, fn) {\n this.clear();\n this.currentId = setTimeout(() => {\n this.currentId = null;\n fn();\n }, delay);\n }\n}\nexport default function useTimeout() {\n const timeout = useLazyRef(Timeout.create).current;\n useOnMount(timeout.disposeEffect);\n return timeout;\n}","'use client';\n\n// based on https://github.com/WICG/focus-visible/blob/v4.1.5/src/focus-visible.js\nimport * as React from 'react';\nimport { Timeout } from '../useTimeout/useTimeout';\nlet hadKeyboardEvent = true;\nlet hadFocusVisibleRecently = false;\nconst hadFocusVisibleRecentlyTimeout = new Timeout();\nconst inputTypesWhitelist = {\n text: true,\n search: true,\n url: true,\n tel: true,\n email: true,\n password: true,\n number: true,\n date: true,\n month: true,\n week: true,\n time: true,\n datetime: true,\n 'datetime-local': true\n};\n\n/**\n * Computes whether the given element should automatically trigger the\n * `focus-visible` class being added, i.e. whether it should always match\n * `:focus-visible` when focused.\n * @param {Element} node\n * @returns {boolean}\n */\nfunction focusTriggersKeyboardModality(node) {\n const {\n type,\n tagName\n } = node;\n if (tagName === 'INPUT' && inputTypesWhitelist[type] && !node.readOnly) {\n return true;\n }\n if (tagName === 'TEXTAREA' && !node.readOnly) {\n return true;\n }\n if (node.isContentEditable) {\n return true;\n }\n return false;\n}\n\n/**\n * Keep track of our keyboard modality state with `hadKeyboardEvent`.\n * If the most recent user interaction was via the keyboard;\n * and the key press did not include a meta, alt/option, or control key;\n * then the modality is keyboard. Otherwise, the modality is not keyboard.\n * @param {KeyboardEvent} event\n */\nfunction handleKeyDown(event) {\n if (event.metaKey || event.altKey || event.ctrlKey) {\n return;\n }\n hadKeyboardEvent = true;\n}\n\n/**\n * If at any point a user clicks with a pointing device, ensure that we change\n * the modality away from keyboard.\n * This avoids the situation where a user presses a key on an already focused\n * element, and then clicks on a different element, focusing it with a\n * pointing device, while we still think we're in keyboard modality.\n */\nfunction handlePointerDown() {\n hadKeyboardEvent = false;\n}\nfunction handleVisibilityChange() {\n if (this.visibilityState === 'hidden') {\n // If the tab becomes active again, the browser will handle calling focus\n // on the element (Safari actually calls it twice).\n // If this tab change caused a blur on an element with focus-visible,\n // re-apply the class when the user switches back to the tab.\n if (hadFocusVisibleRecently) {\n hadKeyboardEvent = true;\n }\n }\n}\nfunction prepare(doc) {\n doc.addEventListener('keydown', handleKeyDown, true);\n doc.addEventListener('mousedown', handlePointerDown, true);\n doc.addEventListener('pointerdown', handlePointerDown, true);\n doc.addEventListener('touchstart', handlePointerDown, true);\n doc.addEventListener('visibilitychange', handleVisibilityChange, true);\n}\nexport function teardown(doc) {\n doc.removeEventListener('keydown', handleKeyDown, true);\n doc.removeEventListener('mousedown', handlePointerDown, true);\n doc.removeEventListener('pointerdown', handlePointerDown, true);\n doc.removeEventListener('touchstart', handlePointerDown, true);\n doc.removeEventListener('visibilitychange', handleVisibilityChange, true);\n}\nfunction isFocusVisible(event) {\n const {\n target\n } = event;\n try {\n return target.matches(':focus-visible');\n } catch (error) {\n // Browsers not implementing :focus-visible will throw a SyntaxError.\n // We use our own heuristic for those browsers.\n // Rethrow might be better if it's not the expected error but do we really\n // want to crash if focus-visible malfunctioned?\n }\n\n // No need for validFocusTarget check. The user does that by attaching it to\n // focusable events only.\n return hadKeyboardEvent || focusTriggersKeyboardModality(target);\n}\nexport default function useIsFocusVisible() {\n const ref = React.useCallback(node => {\n if (node != null) {\n prepare(node.ownerDocument);\n }\n }, []);\n const isFocusVisibleRef = React.useRef(false);\n\n /**\n * Should be called if a blur event is fired\n */\n function handleBlurVisible() {\n // checking against potential state variable does not suffice if we focus and blur synchronously.\n // React wouldn't have time to trigger a re-render so `focusVisible` would be stale.\n // Ideally we would adjust `isFocusVisible(event)` to look at `relatedTarget` for blur events.\n // This doesn't work in IE11 due to https://github.com/facebook/react/issues/3751\n // TODO: check again if React releases their internal changes to focus event handling (https://github.com/facebook/react/pull/19186).\n if (isFocusVisibleRef.current) {\n // To detect a tab/window switch, we look for a blur event followed\n // rapidly by a visibility change.\n // If we don't see a visibility change within 100ms, it's probably a\n // regular focus change.\n hadFocusVisibleRecently = true;\n hadFocusVisibleRecentlyTimeout.start(100, () => {\n hadFocusVisibleRecently = false;\n });\n isFocusVisibleRef.current = false;\n return true;\n }\n return false;\n }\n\n /**\n * Should be called if a blur event is fired\n */\n function handleFocusVisible(event) {\n if (isFocusVisible(event)) {\n isFocusVisibleRef.current = true;\n return true;\n }\n return false;\n }\n return {\n isFocusVisibleRef,\n onFocus: handleFocusVisible,\n onBlur: handleBlurVisible,\n ref\n };\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\n/**\n * Add keys, values of `defaultProps` that does not exist in `props`\n * @param {object} defaultProps\n * @param {object} props\n * @returns {object} resolved props\n */\nexport default function resolveProps(defaultProps, props) {\n const output = _extends({}, props);\n Object.keys(defaultProps).forEach(propName => {\n if (propName.toString().match(/^(components|slots)$/)) {\n output[propName] = _extends({}, defaultProps[propName], output[propName]);\n } else if (propName.toString().match(/^(componentsProps|slotProps)$/)) {\n const defaultSlotProps = defaultProps[propName] || {};\n const slotProps = props[propName];\n output[propName] = {};\n if (!slotProps || !Object.keys(slotProps)) {\n // Reduce the iteration if the slot props is empty\n output[propName] = defaultSlotProps;\n } else if (!defaultSlotProps || !Object.keys(defaultSlotProps)) {\n // Reduce the iteration if the default slot props is empty\n output[propName] = slotProps;\n } else {\n output[propName] = _extends({}, slotProps);\n Object.keys(defaultSlotProps).forEach(slotPropName => {\n output[propName][slotPropName] = resolveProps(defaultSlotProps[slotPropName], slotProps[slotPropName]);\n });\n }\n } else if (output[propName] === undefined) {\n output[propName] = defaultProps[propName];\n }\n });\n return output;\n}","export default function composeClasses(slots, getUtilityClass, classes = undefined) {\n const output = {};\n Object.keys(slots).forEach(\n // `Object.keys(slots)` can't be wider than `T` because we infer `T` from `slots`.\n // @ts-expect-error https://github.com/microsoft/TypeScript/pull/12253#issuecomment-263132208\n slot => {\n output[slot] = slots[slot].reduce((acc, key) => {\n if (key) {\n const utilityClass = getUtilityClass(key);\n if (utilityClass !== '') {\n acc.push(utilityClass);\n }\n if (classes && classes[key]) {\n acc.push(classes[key]);\n }\n }\n return acc;\n }, []).join(' ');\n });\n return output;\n}","const defaultGenerator = componentName => componentName;\nconst createClassNameGenerator = () => {\n let generate = defaultGenerator;\n return {\n configure(generator) {\n generate = generator;\n },\n generate(componentName) {\n return generate(componentName);\n },\n reset() {\n generate = defaultGenerator;\n }\n };\n};\nconst ClassNameGenerator = createClassNameGenerator();\nexport default ClassNameGenerator;","import ClassNameGenerator from '../ClassNameGenerator';\nexport const globalStateClasses = {\n active: 'active',\n checked: 'checked',\n completed: 'completed',\n disabled: 'disabled',\n error: 'error',\n expanded: 'expanded',\n focused: 'focused',\n focusVisible: 'focusVisible',\n open: 'open',\n readOnly: 'readOnly',\n required: 'required',\n selected: 'selected'\n};\nexport default function generateUtilityClass(componentName, slot, globalStatePrefix = 'Mui') {\n const globalStateClass = globalStateClasses[slot];\n return globalStateClass ? `${globalStatePrefix}-${globalStateClass}` : `${ClassNameGenerator.generate(componentName)}-${slot}`;\n}\nexport function isGlobalState(slot) {\n return globalStateClasses[slot] !== undefined;\n}","import generateUtilityClass from '../generateUtilityClass';\nexport default function generateUtilityClasses(componentName, slots, globalStatePrefix = 'Mui') {\n const result = {};\n slots.forEach(slot => {\n result[slot] = generateUtilityClass(componentName, slot, globalStatePrefix);\n });\n return result;\n}","function clamp(val, min = Number.MIN_SAFE_INTEGER, max = Number.MAX_SAFE_INTEGER) {\n return Math.max(min, Math.min(val, max));\n}\nexport default clamp;","export default function _objectWithoutPropertiesLoose(source, excluded) {\n if (source == null) return {};\n var target = {};\n var sourceKeys = Object.keys(source);\n var key, i;\n for (i = 0; i < sourceKeys.length; i++) {\n key = sourceKeys[i];\n if (excluded.indexOf(key) >= 0) continue;\n target[key] = source[key];\n }\n return target;\n}","import _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nconst _excluded = [\"values\", \"unit\", \"step\"];\n// Sorted ASC by size. That's important.\n// It can't be configured as it's used statically for propTypes.\nexport const breakpointKeys = ['xs', 'sm', 'md', 'lg', 'xl'];\nconst sortBreakpointsValues = values => {\n const breakpointsAsArray = Object.keys(values).map(key => ({\n key,\n val: values[key]\n })) || [];\n // Sort in ascending order\n breakpointsAsArray.sort((breakpoint1, breakpoint2) => breakpoint1.val - breakpoint2.val);\n return breakpointsAsArray.reduce((acc, obj) => {\n return _extends({}, acc, {\n [obj.key]: obj.val\n });\n }, {});\n};\n\n// Keep in mind that @media is inclusive by the CSS specification.\nexport default function createBreakpoints(breakpoints) {\n const {\n // The breakpoint **start** at this value.\n // For instance with the first breakpoint xs: [xs, sm).\n values = {\n xs: 0,\n // phone\n sm: 600,\n // tablet\n md: 900,\n // small laptop\n lg: 1200,\n // desktop\n xl: 1536 // large screen\n },\n unit = 'px',\n step = 5\n } = breakpoints,\n other = _objectWithoutPropertiesLoose(breakpoints, _excluded);\n const sortedValues = sortBreakpointsValues(values);\n const keys = Object.keys(sortedValues);\n function up(key) {\n const value = typeof values[key] === 'number' ? values[key] : key;\n return `@media (min-width:${value}${unit})`;\n }\n function down(key) {\n const value = typeof values[key] === 'number' ? values[key] : key;\n return `@media (max-width:${value - step / 100}${unit})`;\n }\n function between(start, end) {\n const endIndex = keys.indexOf(end);\n return `@media (min-width:${typeof values[start] === 'number' ? values[start] : start}${unit}) and ` + `(max-width:${(endIndex !== -1 && typeof values[keys[endIndex]] === 'number' ? values[keys[endIndex]] : end) - step / 100}${unit})`;\n }\n function only(key) {\n if (keys.indexOf(key) + 1 < keys.length) {\n return between(key, keys[keys.indexOf(key) + 1]);\n }\n return up(key);\n }\n function not(key) {\n // handle first and last key separately, for better readability\n const keyIndex = keys.indexOf(key);\n if (keyIndex === 0) {\n return up(keys[1]);\n }\n if (keyIndex === keys.length - 1) {\n return down(keys[keyIndex]);\n }\n return between(key, keys[keys.indexOf(key) + 1]).replace('@media', '@media not all and');\n }\n return _extends({\n keys,\n values: sortedValues,\n up,\n down,\n between,\n only,\n not,\n unit\n }, other);\n}","const shape = {\n borderRadius: 4\n};\nexport default shape;","import PropTypes from 'prop-types';\nconst responsivePropType = process.env.NODE_ENV !== 'production' ? PropTypes.oneOfType([PropTypes.number, PropTypes.string, PropTypes.object, PropTypes.array]) : {};\nexport default responsivePropType;","import deepmerge from '@mui/utils/deepmerge';\nfunction merge(acc, item) {\n if (!item) {\n return acc;\n }\n return deepmerge(acc, item, {\n clone: false // No need to clone deep, it's way faster.\n });\n}\nexport default merge;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport PropTypes from 'prop-types';\nimport deepmerge from '@mui/utils/deepmerge';\nimport merge from './merge';\n\n// The breakpoint **start** at this value.\n// For instance with the first breakpoint xs: [xs, sm[.\nexport const values = {\n xs: 0,\n // phone\n sm: 600,\n // tablet\n md: 900,\n // small laptop\n lg: 1200,\n // desktop\n xl: 1536 // large screen\n};\nconst defaultBreakpoints = {\n // Sorted ASC by size. That's important.\n // It can't be configured as it's used statically for propTypes.\n keys: ['xs', 'sm', 'md', 'lg', 'xl'],\n up: key => `@media (min-width:${values[key]}px)`\n};\nexport function handleBreakpoints(props, propValue, styleFromPropValue) {\n const theme = props.theme || {};\n if (Array.isArray(propValue)) {\n const themeBreakpoints = theme.breakpoints || defaultBreakpoints;\n return propValue.reduce((acc, item, index) => {\n acc[themeBreakpoints.up(themeBreakpoints.keys[index])] = styleFromPropValue(propValue[index]);\n return acc;\n }, {});\n }\n if (typeof propValue === 'object') {\n const themeBreakpoints = theme.breakpoints || defaultBreakpoints;\n return Object.keys(propValue).reduce((acc, breakpoint) => {\n // key is breakpoint\n if (Object.keys(themeBreakpoints.values || values).indexOf(breakpoint) !== -1) {\n const mediaKey = themeBreakpoints.up(breakpoint);\n acc[mediaKey] = styleFromPropValue(propValue[breakpoint], breakpoint);\n } else {\n const cssKey = breakpoint;\n acc[cssKey] = propValue[cssKey];\n }\n return acc;\n }, {});\n }\n const output = styleFromPropValue(propValue);\n return output;\n}\nfunction breakpoints(styleFunction) {\n // false positive\n // eslint-disable-next-line react/function-component-definition\n const newStyleFunction = props => {\n const theme = props.theme || {};\n const base = styleFunction(props);\n const themeBreakpoints = theme.breakpoints || defaultBreakpoints;\n const extended = themeBreakpoints.keys.reduce((acc, key) => {\n if (props[key]) {\n acc = acc || {};\n acc[themeBreakpoints.up(key)] = styleFunction(_extends({\n theme\n }, props[key]));\n }\n return acc;\n }, null);\n return merge(base, extended);\n };\n newStyleFunction.propTypes = process.env.NODE_ENV !== 'production' ? _extends({}, styleFunction.propTypes, {\n xs: PropTypes.object,\n sm: PropTypes.object,\n md: PropTypes.object,\n lg: PropTypes.object,\n xl: PropTypes.object\n }) : {};\n newStyleFunction.filterProps = ['xs', 'sm', 'md', 'lg', 'xl', ...styleFunction.filterProps];\n return newStyleFunction;\n}\nexport function createEmptyBreakpointObject(breakpointsInput = {}) {\n var _breakpointsInput$key;\n const breakpointsInOrder = (_breakpointsInput$key = breakpointsInput.keys) == null ? void 0 : _breakpointsInput$key.reduce((acc, key) => {\n const breakpointStyleKey = breakpointsInput.up(key);\n acc[breakpointStyleKey] = {};\n return acc;\n }, {});\n return breakpointsInOrder || {};\n}\nexport function removeUnusedBreakpoints(breakpointKeys, style) {\n return breakpointKeys.reduce((acc, key) => {\n const breakpointOutput = acc[key];\n const isBreakpointUnused = !breakpointOutput || Object.keys(breakpointOutput).length === 0;\n if (isBreakpointUnused) {\n delete acc[key];\n }\n return acc;\n }, style);\n}\nexport function mergeBreakpointsInOrder(breakpointsInput, ...styles) {\n const emptyBreakpoints = createEmptyBreakpointObject(breakpointsInput);\n const mergedOutput = [emptyBreakpoints, ...styles].reduce((prev, next) => deepmerge(prev, next), {});\n return removeUnusedBreakpoints(Object.keys(emptyBreakpoints), mergedOutput);\n}\n\n// compute base for responsive values; e.g.,\n// [1,2,3] => {xs: true, sm: true, md: true}\n// {xs: 1, sm: 2, md: 3} => {xs: true, sm: true, md: true}\nexport function computeBreakpointsBase(breakpointValues, themeBreakpoints) {\n // fixed value\n if (typeof breakpointValues !== 'object') {\n return {};\n }\n const base = {};\n const breakpointsKeys = Object.keys(themeBreakpoints);\n if (Array.isArray(breakpointValues)) {\n breakpointsKeys.forEach((breakpoint, i) => {\n if (i < breakpointValues.length) {\n base[breakpoint] = true;\n }\n });\n } else {\n breakpointsKeys.forEach(breakpoint => {\n if (breakpointValues[breakpoint] != null) {\n base[breakpoint] = true;\n }\n });\n }\n return base;\n}\nexport function resolveBreakpointValues({\n values: breakpointValues,\n breakpoints: themeBreakpoints,\n base: customBase\n}) {\n const base = customBase || computeBreakpointsBase(breakpointValues, themeBreakpoints);\n const keys = Object.keys(base);\n if (keys.length === 0) {\n return breakpointValues;\n }\n let previous;\n return keys.reduce((acc, breakpoint, i) => {\n if (Array.isArray(breakpointValues)) {\n acc[breakpoint] = breakpointValues[i] != null ? breakpointValues[i] : breakpointValues[previous];\n previous = i;\n } else if (typeof breakpointValues === 'object') {\n acc[breakpoint] = breakpointValues[breakpoint] != null ? breakpointValues[breakpoint] : breakpointValues[previous];\n previous = breakpoint;\n } else {\n acc[breakpoint] = breakpointValues;\n }\n return acc;\n }, {});\n}\nexport default breakpoints;","import capitalize from '@mui/utils/capitalize';\nimport responsivePropType from './responsivePropType';\nimport { handleBreakpoints } from './breakpoints';\nexport function getPath(obj, path, checkVars = true) {\n if (!path || typeof path !== 'string') {\n return null;\n }\n\n // Check if CSS variables are used\n if (obj && obj.vars && checkVars) {\n const val = `vars.${path}`.split('.').reduce((acc, item) => acc && acc[item] ? acc[item] : null, obj);\n if (val != null) {\n return val;\n }\n }\n return path.split('.').reduce((acc, item) => {\n if (acc && acc[item] != null) {\n return acc[item];\n }\n return null;\n }, obj);\n}\nexport function getStyleValue(themeMapping, transform, propValueFinal, userValue = propValueFinal) {\n let value;\n if (typeof themeMapping === 'function') {\n value = themeMapping(propValueFinal);\n } else if (Array.isArray(themeMapping)) {\n value = themeMapping[propValueFinal] || userValue;\n } else {\n value = getPath(themeMapping, propValueFinal) || userValue;\n }\n if (transform) {\n value = transform(value, userValue, themeMapping);\n }\n return value;\n}\nfunction style(options) {\n const {\n prop,\n cssProperty = options.prop,\n themeKey,\n transform\n } = options;\n\n // false positive\n // eslint-disable-next-line react/function-component-definition\n const fn = props => {\n if (props[prop] == null) {\n return null;\n }\n const propValue = props[prop];\n const theme = props.theme;\n const themeMapping = getPath(theme, themeKey) || {};\n const styleFromPropValue = propValueFinal => {\n let value = getStyleValue(themeMapping, transform, propValueFinal);\n if (propValueFinal === value && typeof propValueFinal === 'string') {\n // Haven't found value\n value = getStyleValue(themeMapping, transform, `${prop}${propValueFinal === 'default' ? '' : capitalize(propValueFinal)}`, propValueFinal);\n }\n if (cssProperty === false) {\n return value;\n }\n return {\n [cssProperty]: value\n };\n };\n return handleBreakpoints(props, propValue, styleFromPropValue);\n };\n fn.propTypes = process.env.NODE_ENV !== 'production' ? {\n [prop]: responsivePropType\n } : {};\n fn.filterProps = [prop];\n return fn;\n}\nexport default style;","export default function memoize(fn) {\n const cache = {};\n return arg => {\n if (cache[arg] === undefined) {\n cache[arg] = fn(arg);\n }\n return cache[arg];\n };\n}","import responsivePropType from './responsivePropType';\nimport { handleBreakpoints } from './breakpoints';\nimport { getPath } from './style';\nimport merge from './merge';\nimport memoize from './memoize';\nconst properties = {\n m: 'margin',\n p: 'padding'\n};\nconst directions = {\n t: 'Top',\n r: 'Right',\n b: 'Bottom',\n l: 'Left',\n x: ['Left', 'Right'],\n y: ['Top', 'Bottom']\n};\nconst aliases = {\n marginX: 'mx',\n marginY: 'my',\n paddingX: 'px',\n paddingY: 'py'\n};\n\n// memoize() impact:\n// From 300,000 ops/sec\n// To 350,000 ops/sec\nconst getCssProperties = memoize(prop => {\n // It's not a shorthand notation.\n if (prop.length > 2) {\n if (aliases[prop]) {\n prop = aliases[prop];\n } else {\n return [prop];\n }\n }\n const [a, b] = prop.split('');\n const property = properties[a];\n const direction = directions[b] || '';\n return Array.isArray(direction) ? direction.map(dir => property + dir) : [property + direction];\n});\nexport const marginKeys = ['m', 'mt', 'mr', 'mb', 'ml', 'mx', 'my', 'margin', 'marginTop', 'marginRight', 'marginBottom', 'marginLeft', 'marginX', 'marginY', 'marginInline', 'marginInlineStart', 'marginInlineEnd', 'marginBlock', 'marginBlockStart', 'marginBlockEnd'];\nexport const paddingKeys = ['p', 'pt', 'pr', 'pb', 'pl', 'px', 'py', 'padding', 'paddingTop', 'paddingRight', 'paddingBottom', 'paddingLeft', 'paddingX', 'paddingY', 'paddingInline', 'paddingInlineStart', 'paddingInlineEnd', 'paddingBlock', 'paddingBlockStart', 'paddingBlockEnd'];\nconst spacingKeys = [...marginKeys, ...paddingKeys];\nexport function createUnaryUnit(theme, themeKey, defaultValue, propName) {\n var _getPath;\n const themeSpacing = (_getPath = getPath(theme, themeKey, false)) != null ? _getPath : defaultValue;\n if (typeof themeSpacing === 'number') {\n return abs => {\n if (typeof abs === 'string') {\n return abs;\n }\n if (process.env.NODE_ENV !== 'production') {\n if (typeof abs !== 'number') {\n console.error(`MUI: Expected ${propName} argument to be a number or a string, got ${abs}.`);\n }\n }\n return themeSpacing * abs;\n };\n }\n if (Array.isArray(themeSpacing)) {\n return abs => {\n if (typeof abs === 'string') {\n return abs;\n }\n if (process.env.NODE_ENV !== 'production') {\n if (!Number.isInteger(abs)) {\n console.error([`MUI: The \\`theme.${themeKey}\\` array type cannot be combined with non integer values.` + `You should either use an integer value that can be used as index, or define the \\`theme.${themeKey}\\` as a number.`].join('\\n'));\n } else if (abs > themeSpacing.length - 1) {\n console.error([`MUI: The value provided (${abs}) overflows.`, `The supported values are: ${JSON.stringify(themeSpacing)}.`, `${abs} > ${themeSpacing.length - 1}, you need to add the missing values.`].join('\\n'));\n }\n }\n return themeSpacing[abs];\n };\n }\n if (typeof themeSpacing === 'function') {\n return themeSpacing;\n }\n if (process.env.NODE_ENV !== 'production') {\n console.error([`MUI: The \\`theme.${themeKey}\\` value (${themeSpacing}) is invalid.`, 'It should be a number, an array or a function.'].join('\\n'));\n }\n return () => undefined;\n}\nexport function createUnarySpacing(theme) {\n return createUnaryUnit(theme, 'spacing', 8, 'spacing');\n}\nexport function getValue(transformer, propValue) {\n if (typeof propValue === 'string' || propValue == null) {\n return propValue;\n }\n const abs = Math.abs(propValue);\n const transformed = transformer(abs);\n if (propValue >= 0) {\n return transformed;\n }\n if (typeof transformed === 'number') {\n return -transformed;\n }\n return `-${transformed}`;\n}\nexport function getStyleFromPropValue(cssProperties, transformer) {\n return propValue => cssProperties.reduce((acc, cssProperty) => {\n acc[cssProperty] = getValue(transformer, propValue);\n return acc;\n }, {});\n}\nfunction resolveCssProperty(props, keys, prop, transformer) {\n // Using a hash computation over an array iteration could be faster, but with only 28 items,\n // it's doesn't worth the bundle size.\n if (keys.indexOf(prop) === -1) {\n return null;\n }\n const cssProperties = getCssProperties(prop);\n const styleFromPropValue = getStyleFromPropValue(cssProperties, transformer);\n const propValue = props[prop];\n return handleBreakpoints(props, propValue, styleFromPropValue);\n}\nfunction style(props, keys) {\n const transformer = createUnarySpacing(props.theme);\n return Object.keys(props).map(prop => resolveCssProperty(props, keys, prop, transformer)).reduce(merge, {});\n}\nexport function margin(props) {\n return style(props, marginKeys);\n}\nmargin.propTypes = process.env.NODE_ENV !== 'production' ? marginKeys.reduce((obj, key) => {\n obj[key] = responsivePropType;\n return obj;\n}, {}) : {};\nmargin.filterProps = marginKeys;\nexport function padding(props) {\n return style(props, paddingKeys);\n}\npadding.propTypes = process.env.NODE_ENV !== 'production' ? paddingKeys.reduce((obj, key) => {\n obj[key] = responsivePropType;\n return obj;\n}, {}) : {};\npadding.filterProps = paddingKeys;\nfunction spacing(props) {\n return style(props, spacingKeys);\n}\nspacing.propTypes = process.env.NODE_ENV !== 'production' ? spacingKeys.reduce((obj, key) => {\n obj[key] = responsivePropType;\n return obj;\n}, {}) : {};\nspacing.filterProps = spacingKeys;\nexport default spacing;","import { createUnarySpacing } from '../spacing';\n\n// The different signatures imply different meaning for their arguments that can't be expressed structurally.\n// We express the difference with variable names.\n\nexport default function createSpacing(spacingInput = 8) {\n // Already transformed.\n if (spacingInput.mui) {\n return spacingInput;\n }\n\n // Material Design layouts are visually balanced. Most measurements align to an 8dp grid, which aligns both spacing and the overall layout.\n // Smaller components, such as icons, can align to a 4dp grid.\n // https://m2.material.io/design/layout/understanding-layout.html\n const transform = createUnarySpacing({\n spacing: spacingInput\n });\n const spacing = (...argsInput) => {\n if (process.env.NODE_ENV !== 'production') {\n if (!(argsInput.length <= 4)) {\n console.error(`MUI: Too many arguments provided, expected between 0 and 4, got ${argsInput.length}`);\n }\n }\n const args = argsInput.length === 0 ? [1] : argsInput;\n return args.map(argument => {\n const output = transform(argument);\n return typeof output === 'number' ? `${output}px` : output;\n }).join(' ');\n };\n spacing.mui = true;\n return spacing;\n}","import merge from './merge';\nfunction compose(...styles) {\n const handlers = styles.reduce((acc, style) => {\n style.filterProps.forEach(prop => {\n acc[prop] = style;\n });\n return acc;\n }, {});\n\n // false positive\n // eslint-disable-next-line react/function-component-definition\n const fn = props => {\n return Object.keys(props).reduce((acc, prop) => {\n if (handlers[prop]) {\n return merge(acc, handlers[prop](props));\n }\n return acc;\n }, {});\n };\n fn.propTypes = process.env.NODE_ENV !== 'production' ? styles.reduce((acc, style) => Object.assign(acc, style.propTypes), {}) : {};\n fn.filterProps = styles.reduce((acc, style) => acc.concat(style.filterProps), []);\n return fn;\n}\nexport default compose;","import responsivePropType from './responsivePropType';\nimport style from './style';\nimport compose from './compose';\nimport { createUnaryUnit, getValue } from './spacing';\nimport { handleBreakpoints } from './breakpoints';\nexport function borderTransform(value) {\n if (typeof value !== 'number') {\n return value;\n }\n return `${value}px solid`;\n}\nfunction createBorderStyle(prop, transform) {\n return style({\n prop,\n themeKey: 'borders',\n transform\n });\n}\nexport const border = createBorderStyle('border', borderTransform);\nexport const borderTop = createBorderStyle('borderTop', borderTransform);\nexport const borderRight = createBorderStyle('borderRight', borderTransform);\nexport const borderBottom = createBorderStyle('borderBottom', borderTransform);\nexport const borderLeft = createBorderStyle('borderLeft', borderTransform);\nexport const borderColor = createBorderStyle('borderColor');\nexport const borderTopColor = createBorderStyle('borderTopColor');\nexport const borderRightColor = createBorderStyle('borderRightColor');\nexport const borderBottomColor = createBorderStyle('borderBottomColor');\nexport const borderLeftColor = createBorderStyle('borderLeftColor');\nexport const outline = createBorderStyle('outline', borderTransform);\nexport const outlineColor = createBorderStyle('outlineColor');\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const borderRadius = props => {\n if (props.borderRadius !== undefined && props.borderRadius !== null) {\n const transformer = createUnaryUnit(props.theme, 'shape.borderRadius', 4, 'borderRadius');\n const styleFromPropValue = propValue => ({\n borderRadius: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.borderRadius, styleFromPropValue);\n }\n return null;\n};\nborderRadius.propTypes = process.env.NODE_ENV !== 'production' ? {\n borderRadius: responsivePropType\n} : {};\nborderRadius.filterProps = ['borderRadius'];\nconst borders = compose(border, borderTop, borderRight, borderBottom, borderLeft, borderColor, borderTopColor, borderRightColor, borderBottomColor, borderLeftColor, borderRadius, outline, outlineColor);\nexport default borders;","import style from './style';\nimport compose from './compose';\nimport { createUnaryUnit, getValue } from './spacing';\nimport { handleBreakpoints } from './breakpoints';\nimport responsivePropType from './responsivePropType';\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const gap = props => {\n if (props.gap !== undefined && props.gap !== null) {\n const transformer = createUnaryUnit(props.theme, 'spacing', 8, 'gap');\n const styleFromPropValue = propValue => ({\n gap: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.gap, styleFromPropValue);\n }\n return null;\n};\ngap.propTypes = process.env.NODE_ENV !== 'production' ? {\n gap: responsivePropType\n} : {};\ngap.filterProps = ['gap'];\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const columnGap = props => {\n if (props.columnGap !== undefined && props.columnGap !== null) {\n const transformer = createUnaryUnit(props.theme, 'spacing', 8, 'columnGap');\n const styleFromPropValue = propValue => ({\n columnGap: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.columnGap, styleFromPropValue);\n }\n return null;\n};\ncolumnGap.propTypes = process.env.NODE_ENV !== 'production' ? {\n columnGap: responsivePropType\n} : {};\ncolumnGap.filterProps = ['columnGap'];\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const rowGap = props => {\n if (props.rowGap !== undefined && props.rowGap !== null) {\n const transformer = createUnaryUnit(props.theme, 'spacing', 8, 'rowGap');\n const styleFromPropValue = propValue => ({\n rowGap: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.rowGap, styleFromPropValue);\n }\n return null;\n};\nrowGap.propTypes = process.env.NODE_ENV !== 'production' ? {\n rowGap: responsivePropType\n} : {};\nrowGap.filterProps = ['rowGap'];\nexport const gridColumn = style({\n prop: 'gridColumn'\n});\nexport const gridRow = style({\n prop: 'gridRow'\n});\nexport const gridAutoFlow = style({\n prop: 'gridAutoFlow'\n});\nexport const gridAutoColumns = style({\n prop: 'gridAutoColumns'\n});\nexport const gridAutoRows = style({\n prop: 'gridAutoRows'\n});\nexport const gridTemplateColumns = style({\n prop: 'gridTemplateColumns'\n});\nexport const gridTemplateRows = style({\n prop: 'gridTemplateRows'\n});\nexport const gridTemplateAreas = style({\n prop: 'gridTemplateAreas'\n});\nexport const gridArea = style({\n prop: 'gridArea'\n});\nconst grid = compose(gap, columnGap, rowGap, gridColumn, gridRow, gridAutoFlow, gridAutoColumns, gridAutoRows, gridTemplateColumns, gridTemplateRows, gridTemplateAreas, gridArea);\nexport default grid;","import style from './style';\nimport compose from './compose';\nexport function paletteTransform(value, userValue) {\n if (userValue === 'grey') {\n return userValue;\n }\n return value;\n}\nexport const color = style({\n prop: 'color',\n themeKey: 'palette',\n transform: paletteTransform\n});\nexport const bgcolor = style({\n prop: 'bgcolor',\n cssProperty: 'backgroundColor',\n themeKey: 'palette',\n transform: paletteTransform\n});\nexport const backgroundColor = style({\n prop: 'backgroundColor',\n themeKey: 'palette',\n transform: paletteTransform\n});\nconst palette = compose(color, bgcolor, backgroundColor);\nexport default palette;","import style from './style';\nimport compose from './compose';\nimport { handleBreakpoints, values as breakpointsValues } from './breakpoints';\nexport function sizingTransform(value) {\n return value <= 1 && value !== 0 ? `${value * 100}%` : value;\n}\nexport const width = style({\n prop: 'width',\n transform: sizingTransform\n});\nexport const maxWidth = props => {\n if (props.maxWidth !== undefined && props.maxWidth !== null) {\n const styleFromPropValue = propValue => {\n var _props$theme, _props$theme2;\n const breakpoint = ((_props$theme = props.theme) == null || (_props$theme = _props$theme.breakpoints) == null || (_props$theme = _props$theme.values) == null ? void 0 : _props$theme[propValue]) || breakpointsValues[propValue];\n if (!breakpoint) {\n return {\n maxWidth: sizingTransform(propValue)\n };\n }\n if (((_props$theme2 = props.theme) == null || (_props$theme2 = _props$theme2.breakpoints) == null ? void 0 : _props$theme2.unit) !== 'px') {\n return {\n maxWidth: `${breakpoint}${props.theme.breakpoints.unit}`\n };\n }\n return {\n maxWidth: breakpoint\n };\n };\n return handleBreakpoints(props, props.maxWidth, styleFromPropValue);\n }\n return null;\n};\nmaxWidth.filterProps = ['maxWidth'];\nexport const minWidth = style({\n prop: 'minWidth',\n transform: sizingTransform\n});\nexport const height = style({\n prop: 'height',\n transform: sizingTransform\n});\nexport const maxHeight = style({\n prop: 'maxHeight',\n transform: sizingTransform\n});\nexport const minHeight = style({\n prop: 'minHeight',\n transform: sizingTransform\n});\nexport const sizeWidth = style({\n prop: 'size',\n cssProperty: 'width',\n transform: sizingTransform\n});\nexport const sizeHeight = style({\n prop: 'size',\n cssProperty: 'height',\n transform: sizingTransform\n});\nexport const boxSizing = style({\n prop: 'boxSizing'\n});\nconst sizing = compose(width, maxWidth, minWidth, height, maxHeight, minHeight, boxSizing);\nexport default sizing;","import { padding, margin } from '../spacing';\nimport { borderRadius, borderTransform } from '../borders';\nimport { gap, rowGap, columnGap } from '../cssGrid';\nimport { paletteTransform } from '../palette';\nimport { maxWidth, sizingTransform } from '../sizing';\nconst defaultSxConfig = {\n // borders\n border: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderTop: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderRight: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderBottom: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderLeft: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderColor: {\n themeKey: 'palette'\n },\n borderTopColor: {\n themeKey: 'palette'\n },\n borderRightColor: {\n themeKey: 'palette'\n },\n borderBottomColor: {\n themeKey: 'palette'\n },\n borderLeftColor: {\n themeKey: 'palette'\n },\n outline: {\n themeKey: 'borders',\n transform: borderTransform\n },\n outlineColor: {\n themeKey: 'palette'\n },\n borderRadius: {\n themeKey: 'shape.borderRadius',\n style: borderRadius\n },\n // palette\n color: {\n themeKey: 'palette',\n transform: paletteTransform\n },\n bgcolor: {\n themeKey: 'palette',\n cssProperty: 'backgroundColor',\n transform: paletteTransform\n },\n backgroundColor: {\n themeKey: 'palette',\n transform: paletteTransform\n },\n // spacing\n p: {\n style: padding\n },\n pt: {\n style: padding\n },\n pr: {\n style: padding\n },\n pb: {\n style: padding\n },\n pl: {\n style: padding\n },\n px: {\n style: padding\n },\n py: {\n style: padding\n },\n padding: {\n style: padding\n },\n paddingTop: {\n style: padding\n },\n paddingRight: {\n style: padding\n },\n paddingBottom: {\n style: padding\n },\n paddingLeft: {\n style: padding\n },\n paddingX: {\n style: padding\n },\n paddingY: {\n style: padding\n },\n paddingInline: {\n style: padding\n },\n paddingInlineStart: {\n style: padding\n },\n paddingInlineEnd: {\n style: padding\n },\n paddingBlock: {\n style: padding\n },\n paddingBlockStart: {\n style: padding\n },\n paddingBlockEnd: {\n style: padding\n },\n m: {\n style: margin\n },\n mt: {\n style: margin\n },\n mr: {\n style: margin\n },\n mb: {\n style: margin\n },\n ml: {\n style: margin\n },\n mx: {\n style: margin\n },\n my: {\n style: margin\n },\n margin: {\n style: margin\n },\n marginTop: {\n style: margin\n },\n marginRight: {\n style: margin\n },\n marginBottom: {\n style: margin\n },\n marginLeft: {\n style: margin\n },\n marginX: {\n style: margin\n },\n marginY: {\n style: margin\n },\n marginInline: {\n style: margin\n },\n marginInlineStart: {\n style: margin\n },\n marginInlineEnd: {\n style: margin\n },\n marginBlock: {\n style: margin\n },\n marginBlockStart: {\n style: margin\n },\n marginBlockEnd: {\n style: margin\n },\n // display\n displayPrint: {\n cssProperty: false,\n transform: value => ({\n '@media print': {\n display: value\n }\n })\n },\n display: {},\n overflow: {},\n textOverflow: {},\n visibility: {},\n whiteSpace: {},\n // flexbox\n flexBasis: {},\n flexDirection: {},\n flexWrap: {},\n justifyContent: {},\n alignItems: {},\n alignContent: {},\n order: {},\n flex: {},\n flexGrow: {},\n flexShrink: {},\n alignSelf: {},\n justifyItems: {},\n justifySelf: {},\n // grid\n gap: {\n style: gap\n },\n rowGap: {\n style: rowGap\n },\n columnGap: {\n style: columnGap\n },\n gridColumn: {},\n gridRow: {},\n gridAutoFlow: {},\n gridAutoColumns: {},\n gridAutoRows: {},\n gridTemplateColumns: {},\n gridTemplateRows: {},\n gridTemplateAreas: {},\n gridArea: {},\n // positions\n position: {},\n zIndex: {\n themeKey: 'zIndex'\n },\n top: {},\n right: {},\n bottom: {},\n left: {},\n // shadows\n boxShadow: {\n themeKey: 'shadows'\n },\n // sizing\n width: {\n transform: sizingTransform\n },\n maxWidth: {\n style: maxWidth\n },\n minWidth: {\n transform: sizingTransform\n },\n height: {\n transform: sizingTransform\n },\n maxHeight: {\n transform: sizingTransform\n },\n minHeight: {\n transform: sizingTransform\n },\n boxSizing: {},\n // typography\n fontFamily: {\n themeKey: 'typography'\n },\n fontSize: {\n themeKey: 'typography'\n },\n fontStyle: {\n themeKey: 'typography'\n },\n fontWeight: {\n themeKey: 'typography'\n },\n letterSpacing: {},\n textTransform: {},\n lineHeight: {},\n textAlign: {},\n typography: {\n cssProperty: false,\n themeKey: 'typography'\n }\n};\nexport default defaultSxConfig;","import capitalize from '@mui/utils/capitalize';\nimport merge from '../merge';\nimport { getPath, getStyleValue as getValue } from '../style';\nimport { handleBreakpoints, createEmptyBreakpointObject, removeUnusedBreakpoints } from '../breakpoints';\nimport defaultSxConfig from './defaultSxConfig';\nfunction objectsHaveSameKeys(...objects) {\n const allKeys = objects.reduce((keys, object) => keys.concat(Object.keys(object)), []);\n const union = new Set(allKeys);\n return objects.every(object => union.size === Object.keys(object).length);\n}\nfunction callIfFn(maybeFn, arg) {\n return typeof maybeFn === 'function' ? maybeFn(arg) : maybeFn;\n}\n\n// eslint-disable-next-line @typescript-eslint/naming-convention\nexport function unstable_createStyleFunctionSx() {\n function getThemeValue(prop, val, theme, config) {\n const props = {\n [prop]: val,\n theme\n };\n const options = config[prop];\n if (!options) {\n return {\n [prop]: val\n };\n }\n const {\n cssProperty = prop,\n themeKey,\n transform,\n style\n } = options;\n if (val == null) {\n return null;\n }\n\n // TODO v6: remove, see https://github.com/mui/material-ui/pull/38123\n if (themeKey === 'typography' && val === 'inherit') {\n return {\n [prop]: val\n };\n }\n const themeMapping = getPath(theme, themeKey) || {};\n if (style) {\n return style(props);\n }\n const styleFromPropValue = propValueFinal => {\n let value = getValue(themeMapping, transform, propValueFinal);\n if (propValueFinal === value && typeof propValueFinal === 'string') {\n // Haven't found value\n value = getValue(themeMapping, transform, `${prop}${propValueFinal === 'default' ? '' : capitalize(propValueFinal)}`, propValueFinal);\n }\n if (cssProperty === false) {\n return value;\n }\n return {\n [cssProperty]: value\n };\n };\n return handleBreakpoints(props, val, styleFromPropValue);\n }\n function styleFunctionSx(props) {\n var _theme$unstable_sxCon;\n const {\n sx,\n theme = {}\n } = props || {};\n if (!sx) {\n return null; // Emotion & styled-components will neglect null\n }\n const config = (_theme$unstable_sxCon = theme.unstable_sxConfig) != null ? _theme$unstable_sxCon : defaultSxConfig;\n\n /*\n * Receive `sxInput` as object or callback\n * and then recursively check keys & values to create media query object styles.\n * (the result will be used in `styled`)\n */\n function traverse(sxInput) {\n let sxObject = sxInput;\n if (typeof sxInput === 'function') {\n sxObject = sxInput(theme);\n } else if (typeof sxInput !== 'object') {\n // value\n return sxInput;\n }\n if (!sxObject) {\n return null;\n }\n const emptyBreakpoints = createEmptyBreakpointObject(theme.breakpoints);\n const breakpointsKeys = Object.keys(emptyBreakpoints);\n let css = emptyBreakpoints;\n Object.keys(sxObject).forEach(styleKey => {\n const value = callIfFn(sxObject[styleKey], theme);\n if (value !== null && value !== undefined) {\n if (typeof value === 'object') {\n if (config[styleKey]) {\n css = merge(css, getThemeValue(styleKey, value, theme, config));\n } else {\n const breakpointsValues = handleBreakpoints({\n theme\n }, value, x => ({\n [styleKey]: x\n }));\n if (objectsHaveSameKeys(breakpointsValues, value)) {\n css[styleKey] = styleFunctionSx({\n sx: value,\n theme\n });\n } else {\n css = merge(css, breakpointsValues);\n }\n }\n } else {\n css = merge(css, getThemeValue(styleKey, value, theme, config));\n }\n }\n });\n return removeUnusedBreakpoints(breakpointsKeys, css);\n }\n return Array.isArray(sx) ? sx.map(traverse) : traverse(sx);\n }\n return styleFunctionSx;\n}\nconst styleFunctionSx = unstable_createStyleFunctionSx();\nstyleFunctionSx.filterProps = ['sx'];\nexport default styleFunctionSx;","/**\n * A universal utility to style components with multiple color modes. Always use it from the theme object.\n * It works with:\n * - [Basic theme](https://mui.com/material-ui/customization/dark-mode/)\n * - [CSS theme variables](https://mui.com/material-ui/experimental-api/css-theme-variables/overview/)\n * - Zero-runtime engine\n *\n * Tips: Use an array over object spread and place `theme.applyStyles()` last.\n *\n * ✅ [{ background: '#e5e5e5' }, theme.applyStyles('dark', { background: '#1c1c1c' })]\n *\n * 🚫 { background: '#e5e5e5', ...theme.applyStyles('dark', { background: '#1c1c1c' })}\n *\n * @example\n * 1. using with `styled`:\n * ```jsx\n * const Component = styled('div')(({ theme }) => [\n * { background: '#e5e5e5' },\n * theme.applyStyles('dark', {\n * background: '#1c1c1c',\n * color: '#fff',\n * }),\n * ]);\n * ```\n *\n * @example\n * 2. using with `sx` prop:\n * ```jsx\n * [\n * { background: '#e5e5e5' },\n * theme.applyStyles('dark', {\n * background: '#1c1c1c',\n * color: '#fff',\n * }),\n * ]}\n * />\n * ```\n *\n * @example\n * 3. theming a component:\n * ```jsx\n * extendTheme({\n * components: {\n * MuiButton: {\n * styleOverrides: {\n * root: ({ theme }) => [\n * { background: '#e5e5e5' },\n * theme.applyStyles('dark', {\n * background: '#1c1c1c',\n * color: '#fff',\n * }),\n * ],\n * },\n * }\n * }\n * })\n *```\n */\nexport default function applyStyles(key, styles) {\n // @ts-expect-error this is 'any' type\n const theme = this;\n if (theme.vars && typeof theme.getColorSchemeSelector === 'function') {\n // If CssVarsProvider is used as a provider,\n // returns '* :where([data-mui-color-scheme=\"light|dark\"]) &'\n const selector = theme.getColorSchemeSelector(key).replace(/(\\[[^\\]]+\\])/, '*:where($1)');\n return {\n [selector]: styles\n };\n }\n if (theme.palette.mode === key) {\n return styles;\n }\n return {};\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"breakpoints\", \"palette\", \"spacing\", \"shape\"];\nimport deepmerge from '@mui/utils/deepmerge';\nimport createBreakpoints from './createBreakpoints';\nimport shape from './shape';\nimport createSpacing from './createSpacing';\nimport styleFunctionSx from '../styleFunctionSx/styleFunctionSx';\nimport defaultSxConfig from '../styleFunctionSx/defaultSxConfig';\nimport applyStyles from './applyStyles';\nfunction createTheme(options = {}, ...args) {\n const {\n breakpoints: breakpointsInput = {},\n palette: paletteInput = {},\n spacing: spacingInput,\n shape: shapeInput = {}\n } = options,\n other = _objectWithoutPropertiesLoose(options, _excluded);\n const breakpoints = createBreakpoints(breakpointsInput);\n const spacing = createSpacing(spacingInput);\n let muiTheme = deepmerge({\n breakpoints,\n direction: 'ltr',\n components: {},\n // Inject component definitions.\n palette: _extends({\n mode: 'light'\n }, paletteInput),\n spacing,\n shape: _extends({}, shape, shapeInput)\n }, other);\n muiTheme.applyStyles = applyStyles;\n muiTheme = args.reduce((acc, argument) => deepmerge(acc, argument), muiTheme);\n muiTheme.unstable_sxConfig = _extends({}, defaultSxConfig, other == null ? void 0 : other.unstable_sxConfig);\n muiTheme.unstable_sx = function sx(props) {\n return styleFunctionSx({\n sx: props,\n theme: this\n });\n };\n return muiTheme;\n}\nexport default createTheme;","'use client';\n\nimport * as React from 'react';\nimport { ThemeContext } from '@mui/styled-engine';\nfunction isObjectEmpty(obj) {\n return Object.keys(obj).length === 0;\n}\nfunction useTheme(defaultTheme = null) {\n const contextTheme = React.useContext(ThemeContext);\n return !contextTheme || isObjectEmpty(contextTheme) ? defaultTheme : contextTheme;\n}\nexport default useTheme;","'use client';\n\nimport createTheme from './createTheme';\nimport useThemeWithoutDefault from './useThemeWithoutDefault';\nexport const systemDefaultTheme = createTheme();\nfunction useTheme(defaultTheme = systemDefaultTheme) {\n return useThemeWithoutDefault(defaultTheme);\n}\nexport default useTheme;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"ownerState\"],\n _excluded2 = [\"variants\"],\n _excluded3 = [\"name\", \"slot\", \"skipVariantsResolver\", \"skipSx\", \"overridesResolver\"];\n/* eslint-disable no-underscore-dangle */\nimport styledEngineStyled, { internal_processStyles as processStyles } from '@mui/styled-engine';\nimport { isPlainObject } from '@mui/utils/deepmerge';\nimport capitalize from '@mui/utils/capitalize';\nimport getDisplayName from '@mui/utils/getDisplayName';\nimport createTheme from './createTheme';\nimport styleFunctionSx from './styleFunctionSx';\nfunction isEmpty(obj) {\n return Object.keys(obj).length === 0;\n}\n\n// https://github.com/emotion-js/emotion/blob/26ded6109fcd8ca9875cc2ce4564fee678a3f3c5/packages/styled/src/utils.js#L40\nfunction isStringTag(tag) {\n return typeof tag === 'string' &&\n // 96 is one less than the char code\n // for \"a\" so this is checking that\n // it's a lowercase character\n tag.charCodeAt(0) > 96;\n}\n\n// Update /system/styled/#api in case if this changes\nexport function shouldForwardProp(prop) {\n return prop !== 'ownerState' && prop !== 'theme' && prop !== 'sx' && prop !== 'as';\n}\nexport const systemDefaultTheme = createTheme();\nconst lowercaseFirstLetter = string => {\n if (!string) {\n return string;\n }\n return string.charAt(0).toLowerCase() + string.slice(1);\n};\nfunction resolveTheme({\n defaultTheme,\n theme,\n themeId\n}) {\n return isEmpty(theme) ? defaultTheme : theme[themeId] || theme;\n}\nfunction defaultOverridesResolver(slot) {\n if (!slot) {\n return null;\n }\n return (props, styles) => styles[slot];\n}\nfunction processStyleArg(callableStyle, _ref) {\n let {\n ownerState\n } = _ref,\n props = _objectWithoutPropertiesLoose(_ref, _excluded);\n const resolvedStylesArg = typeof callableStyle === 'function' ? callableStyle(_extends({\n ownerState\n }, props)) : callableStyle;\n if (Array.isArray(resolvedStylesArg)) {\n return resolvedStylesArg.flatMap(resolvedStyle => processStyleArg(resolvedStyle, _extends({\n ownerState\n }, props)));\n }\n if (!!resolvedStylesArg && typeof resolvedStylesArg === 'object' && Array.isArray(resolvedStylesArg.variants)) {\n const {\n variants = []\n } = resolvedStylesArg,\n otherStyles = _objectWithoutPropertiesLoose(resolvedStylesArg, _excluded2);\n let result = otherStyles;\n variants.forEach(variant => {\n let isMatch = true;\n if (typeof variant.props === 'function') {\n isMatch = variant.props(_extends({\n ownerState\n }, props, ownerState));\n } else {\n Object.keys(variant.props).forEach(key => {\n if ((ownerState == null ? void 0 : ownerState[key]) !== variant.props[key] && props[key] !== variant.props[key]) {\n isMatch = false;\n }\n });\n }\n if (isMatch) {\n if (!Array.isArray(result)) {\n result = [result];\n }\n result.push(typeof variant.style === 'function' ? variant.style(_extends({\n ownerState\n }, props, ownerState)) : variant.style);\n }\n });\n return result;\n }\n return resolvedStylesArg;\n}\nexport default function createStyled(input = {}) {\n const {\n themeId,\n defaultTheme = systemDefaultTheme,\n rootShouldForwardProp = shouldForwardProp,\n slotShouldForwardProp = shouldForwardProp\n } = input;\n const systemSx = props => {\n return styleFunctionSx(_extends({}, props, {\n theme: resolveTheme(_extends({}, props, {\n defaultTheme,\n themeId\n }))\n }));\n };\n systemSx.__mui_systemSx = true;\n return (tag, inputOptions = {}) => {\n // Filter out the `sx` style function from the previous styled component to prevent unnecessary styles generated by the composite components.\n processStyles(tag, styles => styles.filter(style => !(style != null && style.__mui_systemSx)));\n const {\n name: componentName,\n slot: componentSlot,\n skipVariantsResolver: inputSkipVariantsResolver,\n skipSx: inputSkipSx,\n // TODO v6: remove `lowercaseFirstLetter()` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n overridesResolver = defaultOverridesResolver(lowercaseFirstLetter(componentSlot))\n } = inputOptions,\n options = _objectWithoutPropertiesLoose(inputOptions, _excluded3);\n\n // if skipVariantsResolver option is defined, take the value, otherwise, true for root and false for other slots.\n const skipVariantsResolver = inputSkipVariantsResolver !== undefined ? inputSkipVariantsResolver :\n // TODO v6: remove `Root` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n componentSlot && componentSlot !== 'Root' && componentSlot !== 'root' || false;\n const skipSx = inputSkipSx || false;\n let label;\n if (process.env.NODE_ENV !== 'production') {\n if (componentName) {\n // TODO v6: remove `lowercaseFirstLetter()` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n label = `${componentName}-${lowercaseFirstLetter(componentSlot || 'Root')}`;\n }\n }\n let shouldForwardPropOption = shouldForwardProp;\n\n // TODO v6: remove `Root` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n if (componentSlot === 'Root' || componentSlot === 'root') {\n shouldForwardPropOption = rootShouldForwardProp;\n } else if (componentSlot) {\n // any other slot specified\n shouldForwardPropOption = slotShouldForwardProp;\n } else if (isStringTag(tag)) {\n // for string (html) tag, preserve the behavior in emotion & styled-components.\n shouldForwardPropOption = undefined;\n }\n const defaultStyledResolver = styledEngineStyled(tag, _extends({\n shouldForwardProp: shouldForwardPropOption,\n label\n }, options));\n const transformStyleArg = stylesArg => {\n // On the server Emotion doesn't use React.forwardRef for creating components, so the created\n // component stays as a function. This condition makes sure that we do not interpolate functions\n // which are basically components used as a selectors.\n if (typeof stylesArg === 'function' && stylesArg.__emotion_real !== stylesArg || isPlainObject(stylesArg)) {\n return props => processStyleArg(stylesArg, _extends({}, props, {\n theme: resolveTheme({\n theme: props.theme,\n defaultTheme,\n themeId\n })\n }));\n }\n return stylesArg;\n };\n const muiStyledResolver = (styleArg, ...expressions) => {\n let transformedStyleArg = transformStyleArg(styleArg);\n const expressionsWithDefaultTheme = expressions ? expressions.map(transformStyleArg) : [];\n if (componentName && overridesResolver) {\n expressionsWithDefaultTheme.push(props => {\n const theme = resolveTheme(_extends({}, props, {\n defaultTheme,\n themeId\n }));\n if (!theme.components || !theme.components[componentName] || !theme.components[componentName].styleOverrides) {\n return null;\n }\n const styleOverrides = theme.components[componentName].styleOverrides;\n const resolvedStyleOverrides = {};\n // TODO: v7 remove iteration and use `resolveStyleArg(styleOverrides[slot])` directly\n Object.entries(styleOverrides).forEach(([slotKey, slotStyle]) => {\n resolvedStyleOverrides[slotKey] = processStyleArg(slotStyle, _extends({}, props, {\n theme\n }));\n });\n return overridesResolver(props, resolvedStyleOverrides);\n });\n }\n if (componentName && !skipVariantsResolver) {\n expressionsWithDefaultTheme.push(props => {\n var _theme$components;\n const theme = resolveTheme(_extends({}, props, {\n defaultTheme,\n themeId\n }));\n const themeVariants = theme == null || (_theme$components = theme.components) == null || (_theme$components = _theme$components[componentName]) == null ? void 0 : _theme$components.variants;\n return processStyleArg({\n variants: themeVariants\n }, _extends({}, props, {\n theme\n }));\n });\n }\n if (!skipSx) {\n expressionsWithDefaultTheme.push(systemSx);\n }\n const numOfCustomFnsApplied = expressionsWithDefaultTheme.length - expressions.length;\n if (Array.isArray(styleArg) && numOfCustomFnsApplied > 0) {\n const placeholders = new Array(numOfCustomFnsApplied).fill('');\n // If the type is array, than we need to add placeholders in the template for the overrides, variants and the sx styles.\n transformedStyleArg = [...styleArg, ...placeholders];\n transformedStyleArg.raw = [...styleArg.raw, ...placeholders];\n }\n const Component = defaultStyledResolver(transformedStyleArg, ...expressionsWithDefaultTheme);\n if (process.env.NODE_ENV !== 'production') {\n let displayName;\n if (componentName) {\n displayName = `${componentName}${capitalize(componentSlot || '')}`;\n }\n if (displayName === undefined) {\n displayName = `Styled(${getDisplayName(tag)})`;\n }\n Component.displayName = displayName;\n }\n if (tag.muiName) {\n Component.muiName = tag.muiName;\n }\n return Component;\n };\n if (defaultStyledResolver.withConfig) {\n muiStyledResolver.withConfig = defaultStyledResolver.withConfig;\n }\n return muiStyledResolver;\n };\n}","import resolveProps from '@mui/utils/resolveProps';\nexport default function getThemeProps(params) {\n const {\n theme,\n name,\n props\n } = params;\n if (!theme || !theme.components || !theme.components[name] || !theme.components[name].defaultProps) {\n return props;\n }\n return resolveProps(theme.components[name].defaultProps, props);\n}","'use client';\n\nimport getThemeProps from './getThemeProps';\nimport useTheme from '../useTheme';\nexport default function useThemeProps({\n props,\n name,\n defaultTheme,\n themeId\n}) {\n let theme = useTheme(defaultTheme);\n if (themeId) {\n theme = theme[themeId] || theme;\n }\n const mergedProps = getThemeProps({\n theme,\n name,\n props\n });\n return mergedProps;\n}","import _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\n/* eslint-disable @typescript-eslint/naming-convention */\nimport clamp from '@mui/utils/clamp';\n/**\n * Returns a number whose value is limited to the given range.\n * @param {number} value The value to be clamped\n * @param {number} min The lower boundary of the output range\n * @param {number} max The upper boundary of the output range\n * @returns {number} A number in the range [min, max]\n */\nfunction clampWrapper(value, min = 0, max = 1) {\n if (process.env.NODE_ENV !== 'production') {\n if (value < min || value > max) {\n console.error(`MUI: The value provided ${value} is out of range [${min}, ${max}].`);\n }\n }\n return clamp(value, min, max);\n}\n\n/**\n * Converts a color from CSS hex format to CSS rgb format.\n * @param {string} color - Hex color, i.e. #nnn or #nnnnnn\n * @returns {string} A CSS rgb color string\n */\nexport function hexToRgb(color) {\n color = color.slice(1);\n const re = new RegExp(`.{1,${color.length >= 6 ? 2 : 1}}`, 'g');\n let colors = color.match(re);\n if (colors && colors[0].length === 1) {\n colors = colors.map(n => n + n);\n }\n return colors ? `rgb${colors.length === 4 ? 'a' : ''}(${colors.map((n, index) => {\n return index < 3 ? parseInt(n, 16) : Math.round(parseInt(n, 16) / 255 * 1000) / 1000;\n }).join(', ')})` : '';\n}\nfunction intToHex(int) {\n const hex = int.toString(16);\n return hex.length === 1 ? `0${hex}` : hex;\n}\n\n/**\n * Returns an object with the type and values of a color.\n *\n * Note: Does not support rgb % values.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @returns {object} - A MUI color object: {type: string, values: number[]}\n */\nexport function decomposeColor(color) {\n // Idempotent\n if (color.type) {\n return color;\n }\n if (color.charAt(0) === '#') {\n return decomposeColor(hexToRgb(color));\n }\n const marker = color.indexOf('(');\n const type = color.substring(0, marker);\n if (['rgb', 'rgba', 'hsl', 'hsla', 'color'].indexOf(type) === -1) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: Unsupported \\`${color}\\` color.\nThe following formats are supported: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color().` : _formatMuiErrorMessage(9, color));\n }\n let values = color.substring(marker + 1, color.length - 1);\n let colorSpace;\n if (type === 'color') {\n values = values.split(' ');\n colorSpace = values.shift();\n if (values.length === 4 && values[3].charAt(0) === '/') {\n values[3] = values[3].slice(1);\n }\n if (['srgb', 'display-p3', 'a98-rgb', 'prophoto-rgb', 'rec-2020'].indexOf(colorSpace) === -1) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: unsupported \\`${colorSpace}\\` color space.\nThe following color spaces are supported: srgb, display-p3, a98-rgb, prophoto-rgb, rec-2020.` : _formatMuiErrorMessage(10, colorSpace));\n }\n } else {\n values = values.split(',');\n }\n values = values.map(value => parseFloat(value));\n return {\n type,\n values,\n colorSpace\n };\n}\n\n/**\n * Returns a channel created from the input color.\n *\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @returns {string} - The channel for the color, that can be used in rgba or hsla colors\n */\nexport const colorChannel = color => {\n const decomposedColor = decomposeColor(color);\n return decomposedColor.values.slice(0, 3).map((val, idx) => decomposedColor.type.indexOf('hsl') !== -1 && idx !== 0 ? `${val}%` : val).join(' ');\n};\nexport const private_safeColorChannel = (color, warning) => {\n try {\n return colorChannel(color);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n};\n\n/**\n * Converts a color object with type and values to a string.\n * @param {object} color - Decomposed color\n * @param {string} color.type - One of: 'rgb', 'rgba', 'hsl', 'hsla', 'color'\n * @param {array} color.values - [n,n,n] or [n,n,n,n]\n * @returns {string} A CSS color string\n */\nexport function recomposeColor(color) {\n const {\n type,\n colorSpace\n } = color;\n let {\n values\n } = color;\n if (type.indexOf('rgb') !== -1) {\n // Only convert the first 3 values to int (i.e. not alpha)\n values = values.map((n, i) => i < 3 ? parseInt(n, 10) : n);\n } else if (type.indexOf('hsl') !== -1) {\n values[1] = `${values[1]}%`;\n values[2] = `${values[2]}%`;\n }\n if (type.indexOf('color') !== -1) {\n values = `${colorSpace} ${values.join(' ')}`;\n } else {\n values = `${values.join(', ')}`;\n }\n return `${type}(${values})`;\n}\n\n/**\n * Converts a color from CSS rgb format to CSS hex format.\n * @param {string} color - RGB color, i.e. rgb(n, n, n)\n * @returns {string} A CSS rgb color string, i.e. #nnnnnn\n */\nexport function rgbToHex(color) {\n // Idempotent\n if (color.indexOf('#') === 0) {\n return color;\n }\n const {\n values\n } = decomposeColor(color);\n return `#${values.map((n, i) => intToHex(i === 3 ? Math.round(255 * n) : n)).join('')}`;\n}\n\n/**\n * Converts a color from hsl format to rgb format.\n * @param {string} color - HSL color values\n * @returns {string} rgb color values\n */\nexport function hslToRgb(color) {\n color = decomposeColor(color);\n const {\n values\n } = color;\n const h = values[0];\n const s = values[1] / 100;\n const l = values[2] / 100;\n const a = s * Math.min(l, 1 - l);\n const f = (n, k = (n + h / 30) % 12) => l - a * Math.max(Math.min(k - 3, 9 - k, 1), -1);\n let type = 'rgb';\n const rgb = [Math.round(f(0) * 255), Math.round(f(8) * 255), Math.round(f(4) * 255)];\n if (color.type === 'hsla') {\n type += 'a';\n rgb.push(values[3]);\n }\n return recomposeColor({\n type,\n values: rgb\n });\n}\n/**\n * The relative brightness of any point in a color space,\n * normalized to 0 for darkest black and 1 for lightest white.\n *\n * Formula: https://www.w3.org/TR/WCAG20-TECHS/G17.html#G17-tests\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @returns {number} The relative brightness of the color in the range 0 - 1\n */\nexport function getLuminance(color) {\n color = decomposeColor(color);\n let rgb = color.type === 'hsl' || color.type === 'hsla' ? decomposeColor(hslToRgb(color)).values : color.values;\n rgb = rgb.map(val => {\n if (color.type !== 'color') {\n val /= 255; // normalized\n }\n return val <= 0.03928 ? val / 12.92 : ((val + 0.055) / 1.055) ** 2.4;\n });\n\n // Truncate at 3 digits\n return Number((0.2126 * rgb[0] + 0.7152 * rgb[1] + 0.0722 * rgb[2]).toFixed(3));\n}\n\n/**\n * Calculates the contrast ratio between two colors.\n *\n * Formula: https://www.w3.org/TR/WCAG20-TECHS/G17.html#G17-tests\n * @param {string} foreground - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla()\n * @param {string} background - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla()\n * @returns {number} A contrast ratio value in the range 0 - 21.\n */\nexport function getContrastRatio(foreground, background) {\n const lumA = getLuminance(foreground);\n const lumB = getLuminance(background);\n return (Math.max(lumA, lumB) + 0.05) / (Math.min(lumA, lumB) + 0.05);\n}\n\n/**\n * Sets the absolute transparency of a color.\n * Any existing alpha values are overwritten.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} value - value to set the alpha channel to in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function alpha(color, value) {\n color = decomposeColor(color);\n value = clampWrapper(value);\n if (color.type === 'rgb' || color.type === 'hsl') {\n color.type += 'a';\n }\n if (color.type === 'color') {\n color.values[3] = `/${value}`;\n } else {\n color.values[3] = value;\n }\n return recomposeColor(color);\n}\nexport function private_safeAlpha(color, value, warning) {\n try {\n return alpha(color, value);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Darkens a color.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} coefficient - multiplier in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function darken(color, coefficient) {\n color = decomposeColor(color);\n coefficient = clampWrapper(coefficient);\n if (color.type.indexOf('hsl') !== -1) {\n color.values[2] *= 1 - coefficient;\n } else if (color.type.indexOf('rgb') !== -1 || color.type.indexOf('color') !== -1) {\n for (let i = 0; i < 3; i += 1) {\n color.values[i] *= 1 - coefficient;\n }\n }\n return recomposeColor(color);\n}\nexport function private_safeDarken(color, coefficient, warning) {\n try {\n return darken(color, coefficient);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Lightens a color.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} coefficient - multiplier in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function lighten(color, coefficient) {\n color = decomposeColor(color);\n coefficient = clampWrapper(coefficient);\n if (color.type.indexOf('hsl') !== -1) {\n color.values[2] += (100 - color.values[2]) * coefficient;\n } else if (color.type.indexOf('rgb') !== -1) {\n for (let i = 0; i < 3; i += 1) {\n color.values[i] += (255 - color.values[i]) * coefficient;\n }\n } else if (color.type.indexOf('color') !== -1) {\n for (let i = 0; i < 3; i += 1) {\n color.values[i] += (1 - color.values[i]) * coefficient;\n }\n }\n return recomposeColor(color);\n}\nexport function private_safeLighten(color, coefficient, warning) {\n try {\n return lighten(color, coefficient);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Darken or lighten a color, depending on its luminance.\n * Light colors are darkened, dark colors are lightened.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} coefficient=0.15 - multiplier in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function emphasize(color, coefficient = 0.15) {\n return getLuminance(color) > 0.5 ? darken(color, coefficient) : lighten(color, coefficient);\n}\nexport function private_safeEmphasize(color, coefficient, warning) {\n try {\n return emphasize(color, coefficient);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Blend a transparent overlay color with a background color, resulting in a single\n * RGB color.\n * @param {string} background - CSS color\n * @param {string} overlay - CSS color\n * @param {number} opacity - Opacity multiplier in the range 0 - 1\n * @param {number} [gamma=1.0] - Gamma correction factor. For gamma-correct blending, 2.2 is usual.\n */\nexport function blend(background, overlay, opacity, gamma = 1.0) {\n const blendChannel = (b, o) => Math.round((b ** (1 / gamma) * (1 - opacity) + o ** (1 / gamma) * opacity) ** gamma);\n const backgroundColor = decomposeColor(background);\n const overlayColor = decomposeColor(overlay);\n const rgb = [blendChannel(backgroundColor.values[0], overlayColor.values[0]), blendChannel(backgroundColor.values[1], overlayColor.values[1]), blendChannel(backgroundColor.values[2], overlayColor.values[2])];\n return recomposeColor({\n type: 'rgb',\n values: rgb\n });\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nexport default function createMixins(breakpoints, mixins) {\n return _extends({\n toolbar: {\n minHeight: 56,\n [breakpoints.up('xs')]: {\n '@media (orientation: landscape)': {\n minHeight: 48\n }\n },\n [breakpoints.up('sm')]: {\n minHeight: 64\n }\n }\n }, mixins);\n}","const common = {\n black: '#000',\n white: '#fff'\n};\nexport default common;","const grey = {\n 50: '#fafafa',\n 100: '#f5f5f5',\n 200: '#eeeeee',\n 300: '#e0e0e0',\n 400: '#bdbdbd',\n 500: '#9e9e9e',\n 600: '#757575',\n 700: '#616161',\n 800: '#424242',\n 900: '#212121',\n A100: '#f5f5f5',\n A200: '#eeeeee',\n A400: '#bdbdbd',\n A700: '#616161'\n};\nexport default grey;","const purple = {\n 50: '#f3e5f5',\n 100: '#e1bee7',\n 200: '#ce93d8',\n 300: '#ba68c8',\n 400: '#ab47bc',\n 500: '#9c27b0',\n 600: '#8e24aa',\n 700: '#7b1fa2',\n 800: '#6a1b9a',\n 900: '#4a148c',\n A100: '#ea80fc',\n A200: '#e040fb',\n A400: '#d500f9',\n A700: '#aa00ff'\n};\nexport default purple;","const red = {\n 50: '#ffebee',\n 100: '#ffcdd2',\n 200: '#ef9a9a',\n 300: '#e57373',\n 400: '#ef5350',\n 500: '#f44336',\n 600: '#e53935',\n 700: '#d32f2f',\n 800: '#c62828',\n 900: '#b71c1c',\n A100: '#ff8a80',\n A200: '#ff5252',\n A400: '#ff1744',\n A700: '#d50000'\n};\nexport default red;","const orange = {\n 50: '#fff3e0',\n 100: '#ffe0b2',\n 200: '#ffcc80',\n 300: '#ffb74d',\n 400: '#ffa726',\n 500: '#ff9800',\n 600: '#fb8c00',\n 700: '#f57c00',\n 800: '#ef6c00',\n 900: '#e65100',\n A100: '#ffd180',\n A200: '#ffab40',\n A400: '#ff9100',\n A700: '#ff6d00'\n};\nexport default orange;","const blue = {\n 50: '#e3f2fd',\n 100: '#bbdefb',\n 200: '#90caf9',\n 300: '#64b5f6',\n 400: '#42a5f5',\n 500: '#2196f3',\n 600: '#1e88e5',\n 700: '#1976d2',\n 800: '#1565c0',\n 900: '#0d47a1',\n A100: '#82b1ff',\n A200: '#448aff',\n A400: '#2979ff',\n A700: '#2962ff'\n};\nexport default blue;","const lightBlue = {\n 50: '#e1f5fe',\n 100: '#b3e5fc',\n 200: '#81d4fa',\n 300: '#4fc3f7',\n 400: '#29b6f6',\n 500: '#03a9f4',\n 600: '#039be5',\n 700: '#0288d1',\n 800: '#0277bd',\n 900: '#01579b',\n A100: '#80d8ff',\n A200: '#40c4ff',\n A400: '#00b0ff',\n A700: '#0091ea'\n};\nexport default lightBlue;","const green = {\n 50: '#e8f5e9',\n 100: '#c8e6c9',\n 200: '#a5d6a7',\n 300: '#81c784',\n 400: '#66bb6a',\n 500: '#4caf50',\n 600: '#43a047',\n 700: '#388e3c',\n 800: '#2e7d32',\n 900: '#1b5e20',\n A100: '#b9f6ca',\n A200: '#69f0ae',\n A400: '#00e676',\n A700: '#00c853'\n};\nexport default green;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\nconst _excluded = [\"mode\", \"contrastThreshold\", \"tonalOffset\"];\nimport { deepmerge } from '@mui/utils';\nimport { darken, getContrastRatio, lighten } from '@mui/system';\nimport common from '../colors/common';\nimport grey from '../colors/grey';\nimport purple from '../colors/purple';\nimport red from '../colors/red';\nimport orange from '../colors/orange';\nimport blue from '../colors/blue';\nimport lightBlue from '../colors/lightBlue';\nimport green from '../colors/green';\nexport const light = {\n // The colors used to style the text.\n text: {\n // The most important text.\n primary: 'rgba(0, 0, 0, 0.87)',\n // Secondary text.\n secondary: 'rgba(0, 0, 0, 0.6)',\n // Disabled text have even lower visual prominence.\n disabled: 'rgba(0, 0, 0, 0.38)'\n },\n // The color used to divide different elements.\n divider: 'rgba(0, 0, 0, 0.12)',\n // The background colors used to style the surfaces.\n // Consistency between these values is important.\n background: {\n paper: common.white,\n default: common.white\n },\n // The colors used to style the action elements.\n action: {\n // The color of an active action like an icon button.\n active: 'rgba(0, 0, 0, 0.54)',\n // The color of an hovered action.\n hover: 'rgba(0, 0, 0, 0.04)',\n hoverOpacity: 0.04,\n // The color of a selected action.\n selected: 'rgba(0, 0, 0, 0.08)',\n selectedOpacity: 0.08,\n // The color of a disabled action.\n disabled: 'rgba(0, 0, 0, 0.26)',\n // The background color of a disabled action.\n disabledBackground: 'rgba(0, 0, 0, 0.12)',\n disabledOpacity: 0.38,\n focus: 'rgba(0, 0, 0, 0.12)',\n focusOpacity: 0.12,\n activatedOpacity: 0.12\n }\n};\nexport const dark = {\n text: {\n primary: common.white,\n secondary: 'rgba(255, 255, 255, 0.7)',\n disabled: 'rgba(255, 255, 255, 0.5)',\n icon: 'rgba(255, 255, 255, 0.5)'\n },\n divider: 'rgba(255, 255, 255, 0.12)',\n background: {\n paper: '#121212',\n default: '#121212'\n },\n action: {\n active: common.white,\n hover: 'rgba(255, 255, 255, 0.08)',\n hoverOpacity: 0.08,\n selected: 'rgba(255, 255, 255, 0.16)',\n selectedOpacity: 0.16,\n disabled: 'rgba(255, 255, 255, 0.3)',\n disabledBackground: 'rgba(255, 255, 255, 0.12)',\n disabledOpacity: 0.38,\n focus: 'rgba(255, 255, 255, 0.12)',\n focusOpacity: 0.12,\n activatedOpacity: 0.24\n }\n};\nfunction addLightOrDark(intent, direction, shade, tonalOffset) {\n const tonalOffsetLight = tonalOffset.light || tonalOffset;\n const tonalOffsetDark = tonalOffset.dark || tonalOffset * 1.5;\n if (!intent[direction]) {\n if (intent.hasOwnProperty(shade)) {\n intent[direction] = intent[shade];\n } else if (direction === 'light') {\n intent.light = lighten(intent.main, tonalOffsetLight);\n } else if (direction === 'dark') {\n intent.dark = darken(intent.main, tonalOffsetDark);\n }\n }\n}\nfunction getDefaultPrimary(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: blue[200],\n light: blue[50],\n dark: blue[400]\n };\n }\n return {\n main: blue[700],\n light: blue[400],\n dark: blue[800]\n };\n}\nfunction getDefaultSecondary(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: purple[200],\n light: purple[50],\n dark: purple[400]\n };\n }\n return {\n main: purple[500],\n light: purple[300],\n dark: purple[700]\n };\n}\nfunction getDefaultError(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: red[500],\n light: red[300],\n dark: red[700]\n };\n }\n return {\n main: red[700],\n light: red[400],\n dark: red[800]\n };\n}\nfunction getDefaultInfo(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: lightBlue[400],\n light: lightBlue[300],\n dark: lightBlue[700]\n };\n }\n return {\n main: lightBlue[700],\n light: lightBlue[500],\n dark: lightBlue[900]\n };\n}\nfunction getDefaultSuccess(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: green[400],\n light: green[300],\n dark: green[700]\n };\n }\n return {\n main: green[800],\n light: green[500],\n dark: green[900]\n };\n}\nfunction getDefaultWarning(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: orange[400],\n light: orange[300],\n dark: orange[700]\n };\n }\n return {\n main: '#ed6c02',\n // closest to orange[800] that pass 3:1.\n light: orange[500],\n dark: orange[900]\n };\n}\nexport default function createPalette(palette) {\n const {\n mode = 'light',\n contrastThreshold = 3,\n tonalOffset = 0.2\n } = palette,\n other = _objectWithoutPropertiesLoose(palette, _excluded);\n const primary = palette.primary || getDefaultPrimary(mode);\n const secondary = palette.secondary || getDefaultSecondary(mode);\n const error = palette.error || getDefaultError(mode);\n const info = palette.info || getDefaultInfo(mode);\n const success = palette.success || getDefaultSuccess(mode);\n const warning = palette.warning || getDefaultWarning(mode);\n\n // Use the same logic as\n // Bootstrap: https://github.com/twbs/bootstrap/blob/1d6e3710dd447de1a200f29e8fa521f8a0908f70/scss/_functions.scss#L59\n // and material-components-web https://github.com/material-components/material-components-web/blob/ac46b8863c4dab9fc22c4c662dc6bd1b65dd652f/packages/mdc-theme/_functions.scss#L54\n function getContrastText(background) {\n const contrastText = getContrastRatio(background, dark.text.primary) >= contrastThreshold ? dark.text.primary : light.text.primary;\n if (process.env.NODE_ENV !== 'production') {\n const contrast = getContrastRatio(background, contrastText);\n if (contrast < 3) {\n console.error([`MUI: The contrast ratio of ${contrast}:1 for ${contrastText} on ${background}`, 'falls below the WCAG recommended absolute minimum contrast ratio of 3:1.', 'https://www.w3.org/TR/2008/REC-WCAG20-20081211/#visual-audio-contrast-contrast'].join('\\n'));\n }\n }\n return contrastText;\n }\n const augmentColor = ({\n color,\n name,\n mainShade = 500,\n lightShade = 300,\n darkShade = 700\n }) => {\n color = _extends({}, color);\n if (!color.main && color[mainShade]) {\n color.main = color[mainShade];\n }\n if (!color.hasOwnProperty('main')) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: The color${name ? ` (${name})` : ''} provided to augmentColor(color) is invalid.\nThe color object needs to have a \\`main\\` property or a \\`${mainShade}\\` property.` : _formatMuiErrorMessage(11, name ? ` (${name})` : '', mainShade));\n }\n if (typeof color.main !== 'string') {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: The color${name ? ` (${name})` : ''} provided to augmentColor(color) is invalid.\n\\`color.main\\` should be a string, but \\`${JSON.stringify(color.main)}\\` was provided instead.\n\nDid you intend to use one of the following approaches?\n\nimport { green } from \"@mui/material/colors\";\n\nconst theme1 = createTheme({ palette: {\n primary: green,\n} });\n\nconst theme2 = createTheme({ palette: {\n primary: { main: green[500] },\n} });` : _formatMuiErrorMessage(12, name ? ` (${name})` : '', JSON.stringify(color.main)));\n }\n addLightOrDark(color, 'light', lightShade, tonalOffset);\n addLightOrDark(color, 'dark', darkShade, tonalOffset);\n if (!color.contrastText) {\n color.contrastText = getContrastText(color.main);\n }\n return color;\n };\n const modes = {\n dark,\n light\n };\n if (process.env.NODE_ENV !== 'production') {\n if (!modes[mode]) {\n console.error(`MUI: The palette mode \\`${mode}\\` is not supported.`);\n }\n }\n const paletteOutput = deepmerge(_extends({\n // A collection of common colors.\n common: _extends({}, common),\n // prevent mutable object.\n // The palette mode, can be light or dark.\n mode,\n // The colors used to represent primary interface elements for a user.\n primary: augmentColor({\n color: primary,\n name: 'primary'\n }),\n // The colors used to represent secondary interface elements for a user.\n secondary: augmentColor({\n color: secondary,\n name: 'secondary',\n mainShade: 'A400',\n lightShade: 'A200',\n darkShade: 'A700'\n }),\n // The colors used to represent interface elements that the user should be made aware of.\n error: augmentColor({\n color: error,\n name: 'error'\n }),\n // The colors used to represent potentially dangerous actions or important messages.\n warning: augmentColor({\n color: warning,\n name: 'warning'\n }),\n // The colors used to present information to the user that is neutral and not necessarily important.\n info: augmentColor({\n color: info,\n name: 'info'\n }),\n // The colors used to indicate the successful completion of an action that user triggered.\n success: augmentColor({\n color: success,\n name: 'success'\n }),\n // The grey colors.\n grey,\n // Used by `getContrastText()` to maximize the contrast between\n // the background and the text.\n contrastThreshold,\n // Takes a background color and returns the text color that maximizes the contrast.\n getContrastText,\n // Generate a rich color object.\n augmentColor,\n // Used by the functions below to shift a color's luminance by approximately\n // two indexes within its tonal palette.\n // E.g., shift from Red 500 to Red 300 or Red 700.\n tonalOffset\n }, modes[mode]), other);\n return paletteOutput;\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"fontFamily\", \"fontSize\", \"fontWeightLight\", \"fontWeightRegular\", \"fontWeightMedium\", \"fontWeightBold\", \"htmlFontSize\", \"allVariants\", \"pxToRem\"];\nimport { deepmerge } from '@mui/utils';\nfunction round(value) {\n return Math.round(value * 1e5) / 1e5;\n}\nconst caseAllCaps = {\n textTransform: 'uppercase'\n};\nconst defaultFontFamily = '\"Roboto\", \"Helvetica\", \"Arial\", sans-serif';\n\n/**\n * @see @link{https://m2.material.io/design/typography/the-type-system.html}\n * @see @link{https://m2.material.io/design/typography/understanding-typography.html}\n */\nexport default function createTypography(palette, typography) {\n const _ref = typeof typography === 'function' ? typography(palette) : typography,\n {\n fontFamily = defaultFontFamily,\n // The default font size of the Material Specification.\n fontSize = 14,\n // px\n fontWeightLight = 300,\n fontWeightRegular = 400,\n fontWeightMedium = 500,\n fontWeightBold = 700,\n // Tell MUI what's the font-size on the html element.\n // 16px is the default font-size used by browsers.\n htmlFontSize = 16,\n // Apply the CSS properties to all the variants.\n allVariants,\n pxToRem: pxToRem2\n } = _ref,\n other = _objectWithoutPropertiesLoose(_ref, _excluded);\n if (process.env.NODE_ENV !== 'production') {\n if (typeof fontSize !== 'number') {\n console.error('MUI: `fontSize` is required to be a number.');\n }\n if (typeof htmlFontSize !== 'number') {\n console.error('MUI: `htmlFontSize` is required to be a number.');\n }\n }\n const coef = fontSize / 14;\n const pxToRem = pxToRem2 || (size => `${size / htmlFontSize * coef}rem`);\n const buildVariant = (fontWeight, size, lineHeight, letterSpacing, casing) => _extends({\n fontFamily,\n fontWeight,\n fontSize: pxToRem(size),\n // Unitless following https://meyerweb.com/eric/thoughts/2006/02/08/unitless-line-heights/\n lineHeight\n }, fontFamily === defaultFontFamily ? {\n letterSpacing: `${round(letterSpacing / size)}em`\n } : {}, casing, allVariants);\n const variants = {\n h1: buildVariant(fontWeightLight, 96, 1.167, -1.5),\n h2: buildVariant(fontWeightLight, 60, 1.2, -0.5),\n h3: buildVariant(fontWeightRegular, 48, 1.167, 0),\n h4: buildVariant(fontWeightRegular, 34, 1.235, 0.25),\n h5: buildVariant(fontWeightRegular, 24, 1.334, 0),\n h6: buildVariant(fontWeightMedium, 20, 1.6, 0.15),\n subtitle1: buildVariant(fontWeightRegular, 16, 1.75, 0.15),\n subtitle2: buildVariant(fontWeightMedium, 14, 1.57, 0.1),\n body1: buildVariant(fontWeightRegular, 16, 1.5, 0.15),\n body2: buildVariant(fontWeightRegular, 14, 1.43, 0.15),\n button: buildVariant(fontWeightMedium, 14, 1.75, 0.4, caseAllCaps),\n caption: buildVariant(fontWeightRegular, 12, 1.66, 0.4),\n overline: buildVariant(fontWeightRegular, 12, 2.66, 1, caseAllCaps),\n // TODO v6: Remove handling of 'inherit' variant from the theme as it is already handled in Material UI's Typography component. Also, remember to remove the associated types.\n inherit: {\n fontFamily: 'inherit',\n fontWeight: 'inherit',\n fontSize: 'inherit',\n lineHeight: 'inherit',\n letterSpacing: 'inherit'\n }\n };\n return deepmerge(_extends({\n htmlFontSize,\n pxToRem,\n fontFamily,\n fontSize,\n fontWeightLight,\n fontWeightRegular,\n fontWeightMedium,\n fontWeightBold\n }, variants), other, {\n clone: false // No need to clone deep\n });\n}","const shadowKeyUmbraOpacity = 0.2;\nconst shadowKeyPenumbraOpacity = 0.14;\nconst shadowAmbientShadowOpacity = 0.12;\nfunction createShadow(...px) {\n return [`${px[0]}px ${px[1]}px ${px[2]}px ${px[3]}px rgba(0,0,0,${shadowKeyUmbraOpacity})`, `${px[4]}px ${px[5]}px ${px[6]}px ${px[7]}px rgba(0,0,0,${shadowKeyPenumbraOpacity})`, `${px[8]}px ${px[9]}px ${px[10]}px ${px[11]}px rgba(0,0,0,${shadowAmbientShadowOpacity})`].join(',');\n}\n\n// Values from https://github.com/material-components/material-components-web/blob/be8747f94574669cb5e7add1a7c54fa41a89cec7/packages/mdc-elevation/_variables.scss\nconst shadows = ['none', createShadow(0, 2, 1, -1, 0, 1, 1, 0, 0, 1, 3, 0), createShadow(0, 3, 1, -2, 0, 2, 2, 0, 0, 1, 5, 0), createShadow(0, 3, 3, -2, 0, 3, 4, 0, 0, 1, 8, 0), createShadow(0, 2, 4, -1, 0, 4, 5, 0, 0, 1, 10, 0), createShadow(0, 3, 5, -1, 0, 5, 8, 0, 0, 1, 14, 0), createShadow(0, 3, 5, -1, 0, 6, 10, 0, 0, 1, 18, 0), createShadow(0, 4, 5, -2, 0, 7, 10, 1, 0, 2, 16, 1), createShadow(0, 5, 5, -3, 0, 8, 10, 1, 0, 3, 14, 2), createShadow(0, 5, 6, -3, 0, 9, 12, 1, 0, 3, 16, 2), createShadow(0, 6, 6, -3, 0, 10, 14, 1, 0, 4, 18, 3), createShadow(0, 6, 7, -4, 0, 11, 15, 1, 0, 4, 20, 3), createShadow(0, 7, 8, -4, 0, 12, 17, 2, 0, 5, 22, 4), createShadow(0, 7, 8, -4, 0, 13, 19, 2, 0, 5, 24, 4), createShadow(0, 7, 9, -4, 0, 14, 21, 2, 0, 5, 26, 4), createShadow(0, 8, 9, -5, 0, 15, 22, 2, 0, 6, 28, 5), createShadow(0, 8, 10, -5, 0, 16, 24, 2, 0, 6, 30, 5), createShadow(0, 8, 11, -5, 0, 17, 26, 2, 0, 6, 32, 5), createShadow(0, 9, 11, -5, 0, 18, 28, 2, 0, 7, 34, 6), createShadow(0, 9, 12, -6, 0, 19, 29, 2, 0, 7, 36, 6), createShadow(0, 10, 13, -6, 0, 20, 31, 3, 0, 8, 38, 7), createShadow(0, 10, 13, -6, 0, 21, 33, 3, 0, 8, 40, 7), createShadow(0, 10, 14, -6, 0, 22, 35, 3, 0, 8, 42, 7), createShadow(0, 11, 14, -7, 0, 23, 36, 3, 0, 9, 44, 8), createShadow(0, 11, 15, -7, 0, 24, 38, 3, 0, 9, 46, 8)];\nexport default shadows;","import _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nconst _excluded = [\"duration\", \"easing\", \"delay\"];\n// Follow https://material.google.com/motion/duration-easing.html#duration-easing-natural-easing-curves\n// to learn the context in which each easing should be used.\nexport const easing = {\n // This is the most common easing curve.\n easeInOut: 'cubic-bezier(0.4, 0, 0.2, 1)',\n // Objects enter the screen at full velocity from off-screen and\n // slowly decelerate to a resting point.\n easeOut: 'cubic-bezier(0.0, 0, 0.2, 1)',\n // Objects leave the screen at full velocity. They do not decelerate when off-screen.\n easeIn: 'cubic-bezier(0.4, 0, 1, 1)',\n // The sharp curve is used by objects that may return to the screen at any time.\n sharp: 'cubic-bezier(0.4, 0, 0.6, 1)'\n};\n\n// Follow https://m2.material.io/guidelines/motion/duration-easing.html#duration-easing-common-durations\n// to learn when use what timing\nexport const duration = {\n shortest: 150,\n shorter: 200,\n short: 250,\n // most basic recommended timing\n standard: 300,\n // this is to be used in complex animations\n complex: 375,\n // recommended when something is entering screen\n enteringScreen: 225,\n // recommended when something is leaving screen\n leavingScreen: 195\n};\nfunction formatMs(milliseconds) {\n return `${Math.round(milliseconds)}ms`;\n}\nfunction getAutoHeightDuration(height) {\n if (!height) {\n return 0;\n }\n const constant = height / 36;\n\n // https://www.wolframalpha.com/input/?i=(4+%2B+15+*+(x+%2F+36+)+**+0.25+%2B+(x+%2F+36)+%2F+5)+*+10\n return Math.round((4 + 15 * constant ** 0.25 + constant / 5) * 10);\n}\nexport default function createTransitions(inputTransitions) {\n const mergedEasing = _extends({}, easing, inputTransitions.easing);\n const mergedDuration = _extends({}, duration, inputTransitions.duration);\n const create = (props = ['all'], options = {}) => {\n const {\n duration: durationOption = mergedDuration.standard,\n easing: easingOption = mergedEasing.easeInOut,\n delay = 0\n } = options,\n other = _objectWithoutPropertiesLoose(options, _excluded);\n if (process.env.NODE_ENV !== 'production') {\n const isString = value => typeof value === 'string';\n // IE11 support, replace with Number.isNaN\n // eslint-disable-next-line no-restricted-globals\n const isNumber = value => !isNaN(parseFloat(value));\n if (!isString(props) && !Array.isArray(props)) {\n console.error('MUI: Argument \"props\" must be a string or Array.');\n }\n if (!isNumber(durationOption) && !isString(durationOption)) {\n console.error(`MUI: Argument \"duration\" must be a number or a string but found ${durationOption}.`);\n }\n if (!isString(easingOption)) {\n console.error('MUI: Argument \"easing\" must be a string.');\n }\n if (!isNumber(delay) && !isString(delay)) {\n console.error('MUI: Argument \"delay\" must be a number or a string.');\n }\n if (typeof options !== 'object') {\n console.error(['MUI: Secong argument of transition.create must be an object.', \"Arguments should be either `create('prop1', options)` or `create(['prop1', 'prop2'], options)`\"].join('\\n'));\n }\n if (Object.keys(other).length !== 0) {\n console.error(`MUI: Unrecognized argument(s) [${Object.keys(other).join(',')}].`);\n }\n }\n return (Array.isArray(props) ? props : [props]).map(animatedProp => `${animatedProp} ${typeof durationOption === 'string' ? durationOption : formatMs(durationOption)} ${easingOption} ${typeof delay === 'string' ? delay : formatMs(delay)}`).join(',');\n };\n return _extends({\n getAutoHeightDuration,\n create\n }, inputTransitions, {\n easing: mergedEasing,\n duration: mergedDuration\n });\n}","// We need to centralize the zIndex definitions as they work\n// like global values in the browser.\nconst zIndex = {\n mobileStepper: 1000,\n fab: 1050,\n speedDial: 1050,\n appBar: 1100,\n drawer: 1200,\n modal: 1300,\n snackbar: 1400,\n tooltip: 1500\n};\nexport default zIndex;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\nconst _excluded = [\"breakpoints\", \"mixins\", \"spacing\", \"palette\", \"transitions\", \"typography\", \"shape\"];\nimport { deepmerge } from '@mui/utils';\nimport { createTheme as systemCreateTheme, unstable_defaultSxConfig as defaultSxConfig, unstable_styleFunctionSx as styleFunctionSx } from '@mui/system';\nimport generateUtilityClass from '@mui/utils/generateUtilityClass';\nimport createMixins from './createMixins';\nimport createPalette from './createPalette';\nimport createTypography from './createTypography';\nimport shadows from './shadows';\nimport createTransitions from './createTransitions';\nimport zIndex from './zIndex';\nfunction createTheme(options = {}, ...args) {\n const {\n mixins: mixinsInput = {},\n palette: paletteInput = {},\n transitions: transitionsInput = {},\n typography: typographyInput = {}\n } = options,\n other = _objectWithoutPropertiesLoose(options, _excluded);\n if (options.vars) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: \\`vars\\` is a private field used for CSS variables support.\nPlease use another name.` : _formatMuiErrorMessage(18));\n }\n const palette = createPalette(paletteInput);\n const systemTheme = systemCreateTheme(options);\n let muiTheme = deepmerge(systemTheme, {\n mixins: createMixins(systemTheme.breakpoints, mixinsInput),\n palette,\n // Don't use [...shadows] until you've verified its transpiled code is not invoking the iterator protocol.\n shadows: shadows.slice(),\n typography: createTypography(palette, typographyInput),\n transitions: createTransitions(transitionsInput),\n zIndex: _extends({}, zIndex)\n });\n muiTheme = deepmerge(muiTheme, other);\n muiTheme = args.reduce((acc, argument) => deepmerge(acc, argument), muiTheme);\n if (process.env.NODE_ENV !== 'production') {\n // TODO v6: Refactor to use globalStateClassesMapping from @mui/utils once `readOnly` state class is used in Rating component.\n const stateClasses = ['active', 'checked', 'completed', 'disabled', 'error', 'expanded', 'focused', 'focusVisible', 'required', 'selected'];\n const traverse = (node, component) => {\n let key;\n\n // eslint-disable-next-line guard-for-in, no-restricted-syntax\n for (key in node) {\n const child = node[key];\n if (stateClasses.indexOf(key) !== -1 && Object.keys(child).length > 0) {\n if (process.env.NODE_ENV !== 'production') {\n const stateClass = generateUtilityClass('', key);\n console.error([`MUI: The \\`${component}\\` component increases ` + `the CSS specificity of the \\`${key}\\` internal state.`, 'You can not override it like this: ', JSON.stringify(node, null, 2), '', `Instead, you need to use the '&.${stateClass}' syntax:`, JSON.stringify({\n root: {\n [`&.${stateClass}`]: child\n }\n }, null, 2), '', 'https://mui.com/r/state-classes-guide'].join('\\n'));\n }\n // Remove the style to prevent global conflicts.\n node[key] = {};\n }\n }\n };\n Object.keys(muiTheme.components).forEach(component => {\n const styleOverrides = muiTheme.components[component].styleOverrides;\n if (styleOverrides && component.indexOf('Mui') === 0) {\n traverse(styleOverrides, component);\n }\n });\n }\n muiTheme.unstable_sxConfig = _extends({}, defaultSxConfig, other == null ? void 0 : other.unstable_sxConfig);\n muiTheme.unstable_sx = function sx(props) {\n return styleFunctionSx({\n sx: props,\n theme: this\n });\n };\n return muiTheme;\n}\nlet warnedOnce = false;\nexport function createMuiTheme(...args) {\n if (process.env.NODE_ENV !== 'production') {\n if (!warnedOnce) {\n warnedOnce = true;\n console.error(['MUI: the createMuiTheme function was renamed to createTheme.', '', \"You should use `import { createTheme } from '@mui/material/styles'`\"].join('\\n'));\n }\n }\n return createTheme(...args);\n}\nexport default createTheme;","'use client';\n\nimport createTheme from './createTheme';\nconst defaultTheme = createTheme();\nexport default defaultTheme;","export default '$$material';","'use client';\n\nimport { useThemeProps as systemUseThemeProps } from '@mui/system';\nimport defaultTheme from './defaultTheme';\nimport THEME_ID from './identifier';\nexport default function useThemeProps({\n props,\n name\n}) {\n return systemUseThemeProps({\n props,\n name,\n defaultTheme,\n themeId: THEME_ID\n });\n}","'use client';\n\nimport { createStyled, shouldForwardProp } from '@mui/system';\nimport defaultTheme from './defaultTheme';\nimport THEME_ID from './identifier';\nexport const rootShouldForwardProp = prop => shouldForwardProp(prop) && prop !== 'classes';\nexport const slotShouldForwardProp = shouldForwardProp;\nconst styled = createStyled({\n themeId: THEME_ID,\n defaultTheme,\n rootShouldForwardProp\n});\nexport default styled;","import generateUtilityClasses from '@mui/utils/generateUtilityClasses';\nimport generateUtilityClass from '@mui/utils/generateUtilityClass';\nexport function getSvgIconUtilityClass(slot) {\n return generateUtilityClass('MuiSvgIcon', slot);\n}\nconst svgIconClasses = generateUtilityClasses('MuiSvgIcon', ['root', 'colorPrimary', 'colorSecondary', 'colorAction', 'colorError', 'colorDisabled', 'fontSizeInherit', 'fontSizeSmall', 'fontSizeMedium', 'fontSizeLarge']);\nexport default svgIconClasses;","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"children\", \"className\", \"color\", \"component\", \"fontSize\", \"htmlColor\", \"inheritViewBox\", \"titleAccess\", \"viewBox\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport clsx from 'clsx';\nimport { unstable_composeClasses as composeClasses } from '@mui/base/composeClasses';\nimport capitalize from '../utils/capitalize';\nimport useThemeProps from '../styles/useThemeProps';\nimport styled from '../styles/styled';\nimport { getSvgIconUtilityClass } from './svgIconClasses';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nimport { jsxs as _jsxs } from \"react/jsx-runtime\";\nconst useUtilityClasses = ownerState => {\n const {\n color,\n fontSize,\n classes\n } = ownerState;\n const slots = {\n root: ['root', color !== 'inherit' && `color${capitalize(color)}`, `fontSize${capitalize(fontSize)}`]\n };\n return composeClasses(slots, getSvgIconUtilityClass, classes);\n};\nconst SvgIconRoot = styled('svg', {\n name: 'MuiSvgIcon',\n slot: 'Root',\n overridesResolver: (props, styles) => {\n const {\n ownerState\n } = props;\n return [styles.root, ownerState.color !== 'inherit' && styles[`color${capitalize(ownerState.color)}`], styles[`fontSize${capitalize(ownerState.fontSize)}`]];\n }\n})(({\n theme,\n ownerState\n}) => {\n var _theme$transitions, _theme$transitions$cr, _theme$transitions2, _theme$typography, _theme$typography$pxT, _theme$typography2, _theme$typography2$px, _theme$typography3, _theme$typography3$px, _palette$ownerState$c, _palette, _palette2, _palette3;\n return {\n userSelect: 'none',\n width: '1em',\n height: '1em',\n display: 'inline-block',\n // the will define the property that has `currentColor`\n // e.g. heroicons uses fill=\"none\" and stroke=\"currentColor\"\n fill: ownerState.hasSvgAsChild ? undefined : 'currentColor',\n flexShrink: 0,\n transition: (_theme$transitions = theme.transitions) == null || (_theme$transitions$cr = _theme$transitions.create) == null ? void 0 : _theme$transitions$cr.call(_theme$transitions, 'fill', {\n duration: (_theme$transitions2 = theme.transitions) == null || (_theme$transitions2 = _theme$transitions2.duration) == null ? void 0 : _theme$transitions2.shorter\n }),\n fontSize: {\n inherit: 'inherit',\n small: ((_theme$typography = theme.typography) == null || (_theme$typography$pxT = _theme$typography.pxToRem) == null ? void 0 : _theme$typography$pxT.call(_theme$typography, 20)) || '1.25rem',\n medium: ((_theme$typography2 = theme.typography) == null || (_theme$typography2$px = _theme$typography2.pxToRem) == null ? void 0 : _theme$typography2$px.call(_theme$typography2, 24)) || '1.5rem',\n large: ((_theme$typography3 = theme.typography) == null || (_theme$typography3$px = _theme$typography3.pxToRem) == null ? void 0 : _theme$typography3$px.call(_theme$typography3, 35)) || '2.1875rem'\n }[ownerState.fontSize],\n // TODO v5 deprecate, v6 remove for sx\n color: (_palette$ownerState$c = (_palette = (theme.vars || theme).palette) == null || (_palette = _palette[ownerState.color]) == null ? void 0 : _palette.main) != null ? _palette$ownerState$c : {\n action: (_palette2 = (theme.vars || theme).palette) == null || (_palette2 = _palette2.action) == null ? void 0 : _palette2.active,\n disabled: (_palette3 = (theme.vars || theme).palette) == null || (_palette3 = _palette3.action) == null ? void 0 : _palette3.disabled,\n inherit: undefined\n }[ownerState.color]\n };\n});\nconst SvgIcon = /*#__PURE__*/React.forwardRef(function SvgIcon(inProps, ref) {\n const props = useThemeProps({\n props: inProps,\n name: 'MuiSvgIcon'\n });\n const {\n children,\n className,\n color = 'inherit',\n component = 'svg',\n fontSize = 'medium',\n htmlColor,\n inheritViewBox = false,\n titleAccess,\n viewBox = '0 0 24 24'\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const hasSvgAsChild = /*#__PURE__*/React.isValidElement(children) && children.type === 'svg';\n const ownerState = _extends({}, props, {\n color,\n component,\n fontSize,\n instanceFontSize: inProps.fontSize,\n inheritViewBox,\n viewBox,\n hasSvgAsChild\n });\n const more = {};\n if (!inheritViewBox) {\n more.viewBox = viewBox;\n }\n const classes = useUtilityClasses(ownerState);\n return /*#__PURE__*/_jsxs(SvgIconRoot, _extends({\n as: component,\n className: clsx(classes.root, className),\n focusable: \"false\",\n color: htmlColor,\n \"aria-hidden\": titleAccess ? undefined : true,\n role: titleAccess ? 'img' : undefined,\n ref: ref\n }, more, other, hasSvgAsChild && children.props, {\n ownerState: ownerState,\n children: [hasSvgAsChild ? children.props.children : children, titleAccess ? /*#__PURE__*/_jsx(\"title\", {\n children: titleAccess\n }) : null]\n }));\n});\nprocess.env.NODE_ENV !== \"production\" ? SvgIcon.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the d.ts file and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * Node passed into the SVG element.\n */\n children: PropTypes.node,\n /**\n * Override or extend the styles applied to the component.\n */\n classes: PropTypes.object,\n /**\n * @ignore\n */\n className: PropTypes.string,\n /**\n * The color of the component.\n * It supports both default and custom theme colors, which can be added as shown in the\n * [palette customization guide](https://mui.com/material-ui/customization/palette/#custom-colors).\n * You can use the `htmlColor` prop to apply a color attribute to the SVG element.\n * @default 'inherit'\n */\n color: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.oneOf(['inherit', 'action', 'disabled', 'primary', 'secondary', 'error', 'info', 'success', 'warning']), PropTypes.string]),\n /**\n * The component used for the root node.\n * Either a string to use a HTML element or a component.\n */\n component: PropTypes.elementType,\n /**\n * The fontSize applied to the icon. Defaults to 24px, but can be configure to inherit font size.\n * @default 'medium'\n */\n fontSize: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.oneOf(['inherit', 'large', 'medium', 'small']), PropTypes.string]),\n /**\n * Applies a color attribute to the SVG element.\n */\n htmlColor: PropTypes.string,\n /**\n * If `true`, the root node will inherit the custom `component`'s viewBox and the `viewBox`\n * prop will be ignored.\n * Useful when you want to reference a custom `component` and have `SvgIcon` pass that\n * `component`'s viewBox to the root node.\n * @default false\n */\n inheritViewBox: PropTypes.bool,\n /**\n * The shape-rendering attribute. The behavior of the different options is described on the\n * [MDN Web Docs](https://developer.mozilla.org/en-US/docs/Web/SVG/Attribute/shape-rendering).\n * If you are having issues with blurry icons you should investigate this prop.\n */\n shapeRendering: PropTypes.string,\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Provides a human-readable title for the element that contains it.\n * https://www.w3.org/TR/SVG-access/#Equivalent\n */\n titleAccess: PropTypes.string,\n /**\n * Allows you to redefine what the coordinates without units mean inside an SVG element.\n * For example, if the SVG element is 500 (width) by 200 (height),\n * and you pass viewBox=\"0 0 50 20\",\n * this means that the coordinates inside the SVG will go from the top left corner (0,0)\n * to bottom right (50,20) and each unit will be worth 10px.\n * @default '0 0 24 24'\n */\n viewBox: PropTypes.string\n} : void 0;\nSvgIcon.muiName = 'SvgIcon';\nexport default SvgIcon;","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport * as React from 'react';\nimport SvgIcon from '../SvgIcon';\n\n/**\n * Private module reserved for @mui packages.\n */\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nexport default function createSvgIcon(path, displayName) {\n function Component(props, ref) {\n return /*#__PURE__*/_jsx(SvgIcon, _extends({\n \"data-testid\": `${displayName}Icon`,\n ref: ref\n }, props, {\n children: path\n }));\n }\n if (process.env.NODE_ENV !== 'production') {\n // Need to set `displayName` on the inner component for React.memo.\n // React prior to 16.14 ignores `displayName` on the wrapper.\n Component.displayName = `${displayName}Icon`;\n }\n Component.muiName = SvgIcon.muiName;\n return /*#__PURE__*/React.memo( /*#__PURE__*/React.forwardRef(Component));\n}","'use client';\n\nimport { unstable_ClassNameGenerator as ClassNameGenerator } from '@mui/base/ClassNameGenerator';\nexport { default as capitalize } from './capitalize';\nexport { default as createChainedFunction } from './createChainedFunction';\nexport { default as createSvgIcon } from './createSvgIcon';\nexport { default as debounce } from './debounce';\nexport { default as deprecatedPropType } from './deprecatedPropType';\nexport { default as isMuiElement } from './isMuiElement';\nexport { default as ownerDocument } from './ownerDocument';\nexport { default as ownerWindow } from './ownerWindow';\nexport { default as requirePropFactory } from './requirePropFactory';\nexport { default as setRef } from './setRef';\nexport { default as unstable_useEnhancedEffect } from './useEnhancedEffect';\nexport { default as unstable_useId } from './useId';\nexport { default as unsupportedProp } from './unsupportedProp';\nexport { default as useControlled } from './useControlled';\nexport { default as useEventCallback } from './useEventCallback';\nexport { default as useForkRef } from './useForkRef';\nexport { default as useIsFocusVisible } from './useIsFocusVisible';\n// TODO: remove this export once ClassNameGenerator is stable\n// eslint-disable-next-line @typescript-eslint/naming-convention\nexport const unstable_ClassNameGenerator = {\n configure: generator => {\n if (process.env.NODE_ENV !== 'production') {\n console.warn(['MUI: `ClassNameGenerator` import from `@mui/material/utils` is outdated and might cause unexpected issues.', '', \"You should use `import { unstable_ClassNameGenerator } from '@mui/material/className'` instead\", '', 'The detail of the issue: https://github.com/mui/material-ui/issues/30011#issuecomment-1024993401', '', 'The updated documentation: https://mui.com/guides/classname-generator/'].join('\\n'));\n }\n ClassNameGenerator.configure(generator);\n }\n};","\"use strict\";\n'use client';\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nObject.defineProperty(exports, \"default\", {\n enumerable: true,\n get: function () {\n return _utils.createSvgIcon;\n }\n});\nvar _utils = require(\"@mui/material/utils\");","\"use strict\";\n\"use client\";\n\nvar _interopRequireDefault = require(\"@babel/runtime/helpers/interopRequireDefault\");\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = void 0;\nvar _createSvgIcon = _interopRequireDefault(require(\"./utils/createSvgIcon\"));\nvar _jsxRuntime = require(\"react/jsx-runtime\");\nvar _default = exports.default = (0, _createSvgIcon.default)( /*#__PURE__*/(0, _jsxRuntime.jsx)(\"path\", {\n d: \"m10 17 5-5-5-5z\"\n}), 'ArrowRight');","/**\n * Determines if a given element is a DOM element name (i.e. not a React component).\n */\nexport function isHostComponent(element) {\n return typeof element === 'string';\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport { isHostComponent } from './isHostComponent';\n\n/**\n * Type of the ownerState based on the type of an element it applies to.\n * This resolves to the provided OwnerState for React components and `undefined` for host components.\n * Falls back to `OwnerState | undefined` when the exact type can't be determined in development time.\n */\n\n/**\n * Appends the ownerState object to the props, merging with the existing one if necessary.\n *\n * @param elementType Type of the element that owns the `existingProps`. If the element is a DOM node or undefined, `ownerState` is not applied.\n * @param otherProps Props of the element.\n * @param ownerState\n */\nexport function appendOwnerState(elementType, otherProps, ownerState) {\n if (elementType === undefined || isHostComponent(elementType)) {\n return otherProps;\n }\n return _extends({}, otherProps, {\n ownerState: _extends({}, otherProps.ownerState, ownerState)\n });\n}","'use client';\n\nimport * as React from 'react';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nconst defaultContextValue = {\n disableDefaultClasses: false\n};\nconst ClassNameConfiguratorContext = /*#__PURE__*/React.createContext(defaultContextValue);\n/**\n * @ignore - internal hook.\n *\n * Wraps the `generateUtilityClass` function and controls how the classes are generated.\n * Currently it only affects whether the classes are applied or not.\n *\n * @returns Function to be called with the `generateUtilityClass` function specific to a component to generate the classes.\n */\nexport function useClassNamesOverride(generateUtilityClass) {\n const {\n disableDefaultClasses\n } = React.useContext(ClassNameConfiguratorContext);\n return slot => {\n if (disableDefaultClasses) {\n return '';\n }\n return generateUtilityClass(slot);\n };\n}\n\n/**\n * Allows to configure the components within to not apply any built-in classes.\n */\nexport function ClassNameConfigurator(props) {\n const {\n disableDefaultClasses,\n children\n } = props;\n const contextValue = React.useMemo(() => ({\n disableDefaultClasses: disableDefaultClasses != null ? disableDefaultClasses : false\n }), [disableDefaultClasses]);\n return /*#__PURE__*/_jsx(ClassNameConfiguratorContext.Provider, {\n value: contextValue,\n children: children\n });\n}","/**\n * Extracts event handlers from a given object.\n * A prop is considered an event handler if it is a function and its name starts with `on`.\n *\n * @param object An object to extract event handlers from.\n * @param excludeKeys An array of keys to exclude from the returned object.\n */\nexport function extractEventHandlers(object, excludeKeys = []) {\n if (object === undefined) {\n return {};\n }\n const result = {};\n Object.keys(object).filter(prop => prop.match(/^on[A-Z]/) && typeof object[prop] === 'function' && !excludeKeys.includes(prop)).forEach(prop => {\n result[prop] = object[prop];\n });\n return result;\n}","/**\n * If `componentProps` is a function, calls it with the provided `ownerState`.\n * Otherwise, just returns `componentProps`.\n */\nexport function resolveComponentProps(componentProps, ownerState, slotState) {\n if (typeof componentProps === 'function') {\n return componentProps(ownerState, slotState);\n }\n return componentProps;\n}","/**\n * Removes event handlers from the given object.\n * A field is considered an event handler if it is a function with a name beginning with `on`.\n *\n * @param object Object to remove event handlers from.\n * @returns Object with event handlers removed.\n */\nexport function omitEventHandlers(object) {\n if (object === undefined) {\n return {};\n }\n const result = {};\n Object.keys(object).filter(prop => !(prop.match(/^on[A-Z]/) && typeof object[prop] === 'function')).forEach(prop => {\n result[prop] = object[prop];\n });\n return result;\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport clsx from 'clsx';\nimport { extractEventHandlers } from './extractEventHandlers';\nimport { omitEventHandlers } from './omitEventHandlers';\n/**\n * Merges the slot component internal props (usually coming from a hook)\n * with the externally provided ones.\n *\n * The merge order is (the latter overrides the former):\n * 1. The internal props (specified as a getter function to work with get*Props hook result)\n * 2. Additional props (specified internally on a Base UI component)\n * 3. External props specified on the owner component. These should only be used on a root slot.\n * 4. External props specified in the `slotProps.*` prop.\n * 5. The `className` prop - combined from all the above.\n * @param parameters\n * @returns\n */\nexport function mergeSlotProps(parameters) {\n const {\n getSlotProps,\n additionalProps,\n externalSlotProps,\n externalForwardedProps,\n className\n } = parameters;\n if (!getSlotProps) {\n // The simpler case - getSlotProps is not defined, so no internal event handlers are defined,\n // so we can simply merge all the props without having to worry about extracting event handlers.\n const joinedClasses = clsx(additionalProps == null ? void 0 : additionalProps.className, className, externalForwardedProps == null ? void 0 : externalForwardedProps.className, externalSlotProps == null ? void 0 : externalSlotProps.className);\n const mergedStyle = _extends({}, additionalProps == null ? void 0 : additionalProps.style, externalForwardedProps == null ? void 0 : externalForwardedProps.style, externalSlotProps == null ? void 0 : externalSlotProps.style);\n const props = _extends({}, additionalProps, externalForwardedProps, externalSlotProps);\n if (joinedClasses.length > 0) {\n props.className = joinedClasses;\n }\n if (Object.keys(mergedStyle).length > 0) {\n props.style = mergedStyle;\n }\n return {\n props,\n internalRef: undefined\n };\n }\n\n // In this case, getSlotProps is responsible for calling the external event handlers.\n // We don't need to include them in the merged props because of this.\n\n const eventHandlers = extractEventHandlers(_extends({}, externalForwardedProps, externalSlotProps));\n const componentsPropsWithoutEventHandlers = omitEventHandlers(externalSlotProps);\n const otherPropsWithoutEventHandlers = omitEventHandlers(externalForwardedProps);\n const internalSlotProps = getSlotProps(eventHandlers);\n\n // The order of classes is important here.\n // Emotion (that we use in libraries consuming Base UI) depends on this order\n // to properly override style. It requires the most important classes to be last\n // (see https://github.com/mui/material-ui/pull/33205) for the related discussion.\n const joinedClasses = clsx(internalSlotProps == null ? void 0 : internalSlotProps.className, additionalProps == null ? void 0 : additionalProps.className, className, externalForwardedProps == null ? void 0 : externalForwardedProps.className, externalSlotProps == null ? void 0 : externalSlotProps.className);\n const mergedStyle = _extends({}, internalSlotProps == null ? void 0 : internalSlotProps.style, additionalProps == null ? void 0 : additionalProps.style, externalForwardedProps == null ? void 0 : externalForwardedProps.style, externalSlotProps == null ? void 0 : externalSlotProps.style);\n const props = _extends({}, internalSlotProps, additionalProps, otherPropsWithoutEventHandlers, componentsPropsWithoutEventHandlers);\n if (joinedClasses.length > 0) {\n props.className = joinedClasses;\n }\n if (Object.keys(mergedStyle).length > 0) {\n props.style = mergedStyle;\n }\n return {\n props,\n internalRef: internalSlotProps.ref\n };\n}","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"elementType\", \"externalSlotProps\", \"ownerState\", \"skipResolvingSlotProps\"];\nimport { unstable_useForkRef as useForkRef } from '@mui/utils';\nimport { appendOwnerState } from './appendOwnerState';\nimport { mergeSlotProps } from './mergeSlotProps';\nimport { resolveComponentProps } from './resolveComponentProps';\n/**\n * @ignore - do not document.\n * Builds the props to be passed into the slot of an unstyled component.\n * It merges the internal props of the component with the ones supplied by the user, allowing to customize the behavior.\n * If the slot component is not a host component, it also merges in the `ownerState`.\n *\n * @param parameters.getSlotProps - A function that returns the props to be passed to the slot component.\n */\nexport function useSlotProps(parameters) {\n var _parameters$additiona;\n const {\n elementType,\n externalSlotProps,\n ownerState,\n skipResolvingSlotProps = false\n } = parameters,\n rest = _objectWithoutPropertiesLoose(parameters, _excluded);\n const resolvedComponentsProps = skipResolvingSlotProps ? {} : resolveComponentProps(externalSlotProps, ownerState);\n const {\n props: mergedProps,\n internalRef\n } = mergeSlotProps(_extends({}, rest, {\n externalSlotProps: resolvedComponentsProps\n }));\n const ref = useForkRef(internalRef, resolvedComponentsProps == null ? void 0 : resolvedComponentsProps.ref, (_parameters$additiona = parameters.additionalProps) == null ? void 0 : _parameters$additiona.ref);\n const props = appendOwnerState(elementType, _extends({}, mergedProps, {\n ref\n }), ownerState);\n return props;\n}","import { globalStateClasses } from '@mui/utils/generateUtilityClass';\nconst GLOBAL_CLASS_PREFIX = 'base';\nfunction buildStateClass(state) {\n return `${GLOBAL_CLASS_PREFIX}--${state}`;\n}\nfunction buildSlotClass(componentName, slot) {\n return `${GLOBAL_CLASS_PREFIX}-${componentName}-${slot}`;\n}\nexport function generateUtilityClass(componentName, slot) {\n const globalStateClass = globalStateClasses[slot];\n return globalStateClass ? buildStateClass(globalStateClass) : buildSlotClass(componentName, slot);\n}\nexport function isGlobalState(slot) {\n return globalStateClasses[slot] !== undefined;\n}","import { generateUtilityClass } from '../generateUtilityClass';\nexport function generateUtilityClasses(componentName, slots) {\n const result = {};\n slots.forEach(slot => {\n result[slot] = generateUtilityClass(componentName, slot);\n });\n return result;\n}","'use client';\n\nimport * as React from 'react';\nimport * as ReactDOM from 'react-dom';\nimport PropTypes from 'prop-types';\nimport { exactProp, HTMLElementType, unstable_useEnhancedEffect as useEnhancedEffect, unstable_useForkRef as useForkRef, unstable_setRef as setRef } from '@mui/utils';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nfunction getContainer(container) {\n return typeof container === 'function' ? container() : container;\n}\n\n/**\n * Portals provide a first-class way to render children into a DOM node\n * that exists outside the DOM hierarchy of the parent component.\n *\n * Demos:\n *\n * - [Portal](https://mui.com/base-ui/react-portal/)\n *\n * API:\n *\n * - [Portal API](https://mui.com/base-ui/react-portal/components-api/#portal)\n */\nconst Portal = /*#__PURE__*/React.forwardRef(function Portal(props, forwardedRef) {\n const {\n children,\n container,\n disablePortal = false\n } = props;\n const [mountNode, setMountNode] = React.useState(null);\n // @ts-expect-error TODO upstream fix\n const handleRef = useForkRef( /*#__PURE__*/React.isValidElement(children) ? children.ref : null, forwardedRef);\n useEnhancedEffect(() => {\n if (!disablePortal) {\n setMountNode(getContainer(container) || document.body);\n }\n }, [container, disablePortal]);\n useEnhancedEffect(() => {\n if (mountNode && !disablePortal) {\n setRef(forwardedRef, mountNode);\n return () => {\n setRef(forwardedRef, null);\n };\n }\n return undefined;\n }, [forwardedRef, mountNode, disablePortal]);\n if (disablePortal) {\n if ( /*#__PURE__*/React.isValidElement(children)) {\n const newProps = {\n ref: handleRef\n };\n return /*#__PURE__*/React.cloneElement(children, newProps);\n }\n return /*#__PURE__*/_jsx(React.Fragment, {\n children: children\n });\n }\n return /*#__PURE__*/_jsx(React.Fragment, {\n children: mountNode ? /*#__PURE__*/ReactDOM.createPortal(children, mountNode) : mountNode\n });\n});\nprocess.env.NODE_ENV !== \"production\" ? Portal.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * The children to render into the `container`.\n */\n children: PropTypes.node,\n /**\n * An HTML element or function that returns one.\n * The `container` will have the portal children appended to it.\n *\n * You can also provide a callback, which is called in a React layout effect.\n * This lets you set the container from a ref, and also makes server-side rendering possible.\n *\n * By default, it uses the body of the top-level document object,\n * so it's simply `document.body` most of the time.\n */\n container: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.func]),\n /**\n * The `children` will be under the DOM hierarchy of the parent component.\n * @default false\n */\n disablePortal: PropTypes.bool\n} : void 0;\nif (process.env.NODE_ENV !== 'production') {\n // eslint-disable-next-line\n Portal['propTypes' + ''] = exactProp(Portal.propTypes);\n}\nexport { Portal };","export var top = 'top';\nexport var bottom = 'bottom';\nexport var right = 'right';\nexport var left = 'left';\nexport var auto = 'auto';\nexport var basePlacements = [top, bottom, right, left];\nexport var start = 'start';\nexport var end = 'end';\nexport var clippingParents = 'clippingParents';\nexport var viewport = 'viewport';\nexport var popper = 'popper';\nexport var reference = 'reference';\nexport var variationPlacements = /*#__PURE__*/basePlacements.reduce(function (acc, placement) {\n return acc.concat([placement + \"-\" + start, placement + \"-\" + end]);\n}, []);\nexport var placements = /*#__PURE__*/[].concat(basePlacements, [auto]).reduce(function (acc, placement) {\n return acc.concat([placement, placement + \"-\" + start, placement + \"-\" + end]);\n}, []); // modifiers that need to read the DOM\n\nexport var beforeRead = 'beforeRead';\nexport var read = 'read';\nexport var afterRead = 'afterRead'; // pure-logic modifiers\n\nexport var beforeMain = 'beforeMain';\nexport var main = 'main';\nexport var afterMain = 'afterMain'; // modifier with the purpose to write to the DOM (or write into a framework state)\n\nexport var beforeWrite = 'beforeWrite';\nexport var write = 'write';\nexport var afterWrite = 'afterWrite';\nexport var modifierPhases = [beforeRead, read, afterRead, beforeMain, main, afterMain, beforeWrite, write, afterWrite];","export default function getNodeName(element) {\n return element ? (element.nodeName || '').toLowerCase() : null;\n}","export default function getWindow(node) {\n if (node == null) {\n return window;\n }\n\n if (node.toString() !== '[object Window]') {\n var ownerDocument = node.ownerDocument;\n return ownerDocument ? ownerDocument.defaultView || window : window;\n }\n\n return node;\n}","import getWindow from \"./getWindow.js\";\n\nfunction isElement(node) {\n var OwnElement = getWindow(node).Element;\n return node instanceof OwnElement || node instanceof Element;\n}\n\nfunction isHTMLElement(node) {\n var OwnElement = getWindow(node).HTMLElement;\n return node instanceof OwnElement || node instanceof HTMLElement;\n}\n\nfunction isShadowRoot(node) {\n // IE 11 has no ShadowRoot\n if (typeof ShadowRoot === 'undefined') {\n return false;\n }\n\n var OwnElement = getWindow(node).ShadowRoot;\n return node instanceof OwnElement || node instanceof ShadowRoot;\n}\n\nexport { isElement, isHTMLElement, isShadowRoot };","import getNodeName from \"../dom-utils/getNodeName.js\";\nimport { isHTMLElement } from \"../dom-utils/instanceOf.js\"; // This modifier takes the styles prepared by the `computeStyles` modifier\n// and applies them to the HTMLElements such as popper and arrow\n\nfunction applyStyles(_ref) {\n var state = _ref.state;\n Object.keys(state.elements).forEach(function (name) {\n var style = state.styles[name] || {};\n var attributes = state.attributes[name] || {};\n var element = state.elements[name]; // arrow is optional + virtual elements\n\n if (!isHTMLElement(element) || !getNodeName(element)) {\n return;\n } // Flow doesn't support to extend this property, but it's the most\n // effective way to apply styles to an HTMLElement\n // $FlowFixMe[cannot-write]\n\n\n Object.assign(element.style, style);\n Object.keys(attributes).forEach(function (name) {\n var value = attributes[name];\n\n if (value === false) {\n element.removeAttribute(name);\n } else {\n element.setAttribute(name, value === true ? '' : value);\n }\n });\n });\n}\n\nfunction effect(_ref2) {\n var state = _ref2.state;\n var initialStyles = {\n popper: {\n position: state.options.strategy,\n left: '0',\n top: '0',\n margin: '0'\n },\n arrow: {\n position: 'absolute'\n },\n reference: {}\n };\n Object.assign(state.elements.popper.style, initialStyles.popper);\n state.styles = initialStyles;\n\n if (state.elements.arrow) {\n Object.assign(state.elements.arrow.style, initialStyles.arrow);\n }\n\n return function () {\n Object.keys(state.elements).forEach(function (name) {\n var element = state.elements[name];\n var attributes = state.attributes[name] || {};\n var styleProperties = Object.keys(state.styles.hasOwnProperty(name) ? state.styles[name] : initialStyles[name]); // Set all values to an empty string to unset them\n\n var style = styleProperties.reduce(function (style, property) {\n style[property] = '';\n return style;\n }, {}); // arrow is optional + virtual elements\n\n if (!isHTMLElement(element) || !getNodeName(element)) {\n return;\n }\n\n Object.assign(element.style, style);\n Object.keys(attributes).forEach(function (attribute) {\n element.removeAttribute(attribute);\n });\n });\n };\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'applyStyles',\n enabled: true,\n phase: 'write',\n fn: applyStyles,\n effect: effect,\n requires: ['computeStyles']\n};","import { auto } from \"../enums.js\";\nexport default function getBasePlacement(placement) {\n return placement.split('-')[0];\n}","export var max = Math.max;\nexport var min = Math.min;\nexport var round = Math.round;","export default function getUAString() {\n var uaData = navigator.userAgentData;\n\n if (uaData != null && uaData.brands && Array.isArray(uaData.brands)) {\n return uaData.brands.map(function (item) {\n return item.brand + \"/\" + item.version;\n }).join(' ');\n }\n\n return navigator.userAgent;\n}","import getUAString from \"../utils/userAgent.js\";\nexport default function isLayoutViewport() {\n return !/^((?!chrome|android).)*safari/i.test(getUAString());\n}","import { isElement, isHTMLElement } from \"./instanceOf.js\";\nimport { round } from \"../utils/math.js\";\nimport getWindow from \"./getWindow.js\";\nimport isLayoutViewport from \"./isLayoutViewport.js\";\nexport default function getBoundingClientRect(element, includeScale, isFixedStrategy) {\n if (includeScale === void 0) {\n includeScale = false;\n }\n\n if (isFixedStrategy === void 0) {\n isFixedStrategy = false;\n }\n\n var clientRect = element.getBoundingClientRect();\n var scaleX = 1;\n var scaleY = 1;\n\n if (includeScale && isHTMLElement(element)) {\n scaleX = element.offsetWidth > 0 ? round(clientRect.width) / element.offsetWidth || 1 : 1;\n scaleY = element.offsetHeight > 0 ? round(clientRect.height) / element.offsetHeight || 1 : 1;\n }\n\n var _ref = isElement(element) ? getWindow(element) : window,\n visualViewport = _ref.visualViewport;\n\n var addVisualOffsets = !isLayoutViewport() && isFixedStrategy;\n var x = (clientRect.left + (addVisualOffsets && visualViewport ? visualViewport.offsetLeft : 0)) / scaleX;\n var y = (clientRect.top + (addVisualOffsets && visualViewport ? visualViewport.offsetTop : 0)) / scaleY;\n var width = clientRect.width / scaleX;\n var height = clientRect.height / scaleY;\n return {\n width: width,\n height: height,\n top: y,\n right: x + width,\n bottom: y + height,\n left: x,\n x: x,\n y: y\n };\n}","import getBoundingClientRect from \"./getBoundingClientRect.js\"; // Returns the layout rect of an element relative to its offsetParent. Layout\n// means it doesn't take into account transforms.\n\nexport default function getLayoutRect(element) {\n var clientRect = getBoundingClientRect(element); // Use the clientRect sizes if it's not been transformed.\n // Fixes https://github.com/popperjs/popper-core/issues/1223\n\n var width = element.offsetWidth;\n var height = element.offsetHeight;\n\n if (Math.abs(clientRect.width - width) <= 1) {\n width = clientRect.width;\n }\n\n if (Math.abs(clientRect.height - height) <= 1) {\n height = clientRect.height;\n }\n\n return {\n x: element.offsetLeft,\n y: element.offsetTop,\n width: width,\n height: height\n };\n}","import { isShadowRoot } from \"./instanceOf.js\";\nexport default function contains(parent, child) {\n var rootNode = child.getRootNode && child.getRootNode(); // First, attempt with faster native method\n\n if (parent.contains(child)) {\n return true;\n } // then fallback to custom implementation with Shadow DOM support\n else if (rootNode && isShadowRoot(rootNode)) {\n var next = child;\n\n do {\n if (next && parent.isSameNode(next)) {\n return true;\n } // $FlowFixMe[prop-missing]: need a better way to handle this...\n\n\n next = next.parentNode || next.host;\n } while (next);\n } // Give up, the result is false\n\n\n return false;\n}","import getWindow from \"./getWindow.js\";\nexport default function getComputedStyle(element) {\n return getWindow(element).getComputedStyle(element);\n}","import getNodeName from \"./getNodeName.js\";\nexport default function isTableElement(element) {\n return ['table', 'td', 'th'].indexOf(getNodeName(element)) >= 0;\n}","import { isElement } from \"./instanceOf.js\";\nexport default function getDocumentElement(element) {\n // $FlowFixMe[incompatible-return]: assume body is always available\n return ((isElement(element) ? element.ownerDocument : // $FlowFixMe[prop-missing]\n element.document) || window.document).documentElement;\n}","import getNodeName from \"./getNodeName.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport { isShadowRoot } from \"./instanceOf.js\";\nexport default function getParentNode(element) {\n if (getNodeName(element) === 'html') {\n return element;\n }\n\n return (// this is a quicker (but less type safe) way to save quite some bytes from the bundle\n // $FlowFixMe[incompatible-return]\n // $FlowFixMe[prop-missing]\n element.assignedSlot || // step into the shadow DOM of the parent of a slotted node\n element.parentNode || ( // DOM Element detected\n isShadowRoot(element) ? element.host : null) || // ShadowRoot detected\n // $FlowFixMe[incompatible-call]: HTMLElement is a Node\n getDocumentElement(element) // fallback\n\n );\n}","import getWindow from \"./getWindow.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport getComputedStyle from \"./getComputedStyle.js\";\nimport { isHTMLElement, isShadowRoot } from \"./instanceOf.js\";\nimport isTableElement from \"./isTableElement.js\";\nimport getParentNode from \"./getParentNode.js\";\nimport getUAString from \"../utils/userAgent.js\";\n\nfunction getTrueOffsetParent(element) {\n if (!isHTMLElement(element) || // https://github.com/popperjs/popper-core/issues/837\n getComputedStyle(element).position === 'fixed') {\n return null;\n }\n\n return element.offsetParent;\n} // `.offsetParent` reports `null` for fixed elements, while absolute elements\n// return the containing block\n\n\nfunction getContainingBlock(element) {\n var isFirefox = /firefox/i.test(getUAString());\n var isIE = /Trident/i.test(getUAString());\n\n if (isIE && isHTMLElement(element)) {\n // In IE 9, 10 and 11 fixed elements containing block is always established by the viewport\n var elementCss = getComputedStyle(element);\n\n if (elementCss.position === 'fixed') {\n return null;\n }\n }\n\n var currentNode = getParentNode(element);\n\n if (isShadowRoot(currentNode)) {\n currentNode = currentNode.host;\n }\n\n while (isHTMLElement(currentNode) && ['html', 'body'].indexOf(getNodeName(currentNode)) < 0) {\n var css = getComputedStyle(currentNode); // This is non-exhaustive but covers the most common CSS properties that\n // create a containing block.\n // https://developer.mozilla.org/en-US/docs/Web/CSS/Containing_block#identifying_the_containing_block\n\n if (css.transform !== 'none' || css.perspective !== 'none' || css.contain === 'paint' || ['transform', 'perspective'].indexOf(css.willChange) !== -1 || isFirefox && css.willChange === 'filter' || isFirefox && css.filter && css.filter !== 'none') {\n return currentNode;\n } else {\n currentNode = currentNode.parentNode;\n }\n }\n\n return null;\n} // Gets the closest ancestor positioned element. Handles some edge cases,\n// such as table ancestors and cross browser bugs.\n\n\nexport default function getOffsetParent(element) {\n var window = getWindow(element);\n var offsetParent = getTrueOffsetParent(element);\n\n while (offsetParent && isTableElement(offsetParent) && getComputedStyle(offsetParent).position === 'static') {\n offsetParent = getTrueOffsetParent(offsetParent);\n }\n\n if (offsetParent && (getNodeName(offsetParent) === 'html' || getNodeName(offsetParent) === 'body' && getComputedStyle(offsetParent).position === 'static')) {\n return window;\n }\n\n return offsetParent || getContainingBlock(element) || window;\n}","export default function getMainAxisFromPlacement(placement) {\n return ['top', 'bottom'].indexOf(placement) >= 0 ? 'x' : 'y';\n}","import { max as mathMax, min as mathMin } from \"./math.js\";\nexport function within(min, value, max) {\n return mathMax(min, mathMin(value, max));\n}\nexport function withinMaxClamp(min, value, max) {\n var v = within(min, value, max);\n return v > max ? max : v;\n}","export default function getFreshSideObject() {\n return {\n top: 0,\n right: 0,\n bottom: 0,\n left: 0\n };\n}","import getFreshSideObject from \"./getFreshSideObject.js\";\nexport default function mergePaddingObject(paddingObject) {\n return Object.assign({}, getFreshSideObject(), paddingObject);\n}","export default function expandToHashMap(value, keys) {\n return keys.reduce(function (hashMap, key) {\n hashMap[key] = value;\n return hashMap;\n }, {});\n}","import getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getLayoutRect from \"../dom-utils/getLayoutRect.js\";\nimport contains from \"../dom-utils/contains.js\";\nimport getOffsetParent from \"../dom-utils/getOffsetParent.js\";\nimport getMainAxisFromPlacement from \"../utils/getMainAxisFromPlacement.js\";\nimport { within } from \"../utils/within.js\";\nimport mergePaddingObject from \"../utils/mergePaddingObject.js\";\nimport expandToHashMap from \"../utils/expandToHashMap.js\";\nimport { left, right, basePlacements, top, bottom } from \"../enums.js\"; // eslint-disable-next-line import/no-unused-modules\n\nvar toPaddingObject = function toPaddingObject(padding, state) {\n padding = typeof padding === 'function' ? padding(Object.assign({}, state.rects, {\n placement: state.placement\n })) : padding;\n return mergePaddingObject(typeof padding !== 'number' ? padding : expandToHashMap(padding, basePlacements));\n};\n\nfunction arrow(_ref) {\n var _state$modifiersData$;\n\n var state = _ref.state,\n name = _ref.name,\n options = _ref.options;\n var arrowElement = state.elements.arrow;\n var popperOffsets = state.modifiersData.popperOffsets;\n var basePlacement = getBasePlacement(state.placement);\n var axis = getMainAxisFromPlacement(basePlacement);\n var isVertical = [left, right].indexOf(basePlacement) >= 0;\n var len = isVertical ? 'height' : 'width';\n\n if (!arrowElement || !popperOffsets) {\n return;\n }\n\n var paddingObject = toPaddingObject(options.padding, state);\n var arrowRect = getLayoutRect(arrowElement);\n var minProp = axis === 'y' ? top : left;\n var maxProp = axis === 'y' ? bottom : right;\n var endDiff = state.rects.reference[len] + state.rects.reference[axis] - popperOffsets[axis] - state.rects.popper[len];\n var startDiff = popperOffsets[axis] - state.rects.reference[axis];\n var arrowOffsetParent = getOffsetParent(arrowElement);\n var clientSize = arrowOffsetParent ? axis === 'y' ? arrowOffsetParent.clientHeight || 0 : arrowOffsetParent.clientWidth || 0 : 0;\n var centerToReference = endDiff / 2 - startDiff / 2; // Make sure the arrow doesn't overflow the popper if the center point is\n // outside of the popper bounds\n\n var min = paddingObject[minProp];\n var max = clientSize - arrowRect[len] - paddingObject[maxProp];\n var center = clientSize / 2 - arrowRect[len] / 2 + centerToReference;\n var offset = within(min, center, max); // Prevents breaking syntax highlighting...\n\n var axisProp = axis;\n state.modifiersData[name] = (_state$modifiersData$ = {}, _state$modifiersData$[axisProp] = offset, _state$modifiersData$.centerOffset = offset - center, _state$modifiersData$);\n}\n\nfunction effect(_ref2) {\n var state = _ref2.state,\n options = _ref2.options;\n var _options$element = options.element,\n arrowElement = _options$element === void 0 ? '[data-popper-arrow]' : _options$element;\n\n if (arrowElement == null) {\n return;\n } // CSS selector\n\n\n if (typeof arrowElement === 'string') {\n arrowElement = state.elements.popper.querySelector(arrowElement);\n\n if (!arrowElement) {\n return;\n }\n }\n\n if (!contains(state.elements.popper, arrowElement)) {\n return;\n }\n\n state.elements.arrow = arrowElement;\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'arrow',\n enabled: true,\n phase: 'main',\n fn: arrow,\n effect: effect,\n requires: ['popperOffsets'],\n requiresIfExists: ['preventOverflow']\n};","export default function getVariation(placement) {\n return placement.split('-')[1];\n}","import { top, left, right, bottom, end } from \"../enums.js\";\nimport getOffsetParent from \"../dom-utils/getOffsetParent.js\";\nimport getWindow from \"../dom-utils/getWindow.js\";\nimport getDocumentElement from \"../dom-utils/getDocumentElement.js\";\nimport getComputedStyle from \"../dom-utils/getComputedStyle.js\";\nimport getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getVariation from \"../utils/getVariation.js\";\nimport { round } from \"../utils/math.js\"; // eslint-disable-next-line import/no-unused-modules\n\nvar unsetSides = {\n top: 'auto',\n right: 'auto',\n bottom: 'auto',\n left: 'auto'\n}; // Round the offsets to the nearest suitable subpixel based on the DPR.\n// Zooming can change the DPR, but it seems to report a value that will\n// cleanly divide the values into the appropriate subpixels.\n\nfunction roundOffsetsByDPR(_ref, win) {\n var x = _ref.x,\n y = _ref.y;\n var dpr = win.devicePixelRatio || 1;\n return {\n x: round(x * dpr) / dpr || 0,\n y: round(y * dpr) / dpr || 0\n };\n}\n\nexport function mapToStyles(_ref2) {\n var _Object$assign2;\n\n var popper = _ref2.popper,\n popperRect = _ref2.popperRect,\n placement = _ref2.placement,\n variation = _ref2.variation,\n offsets = _ref2.offsets,\n position = _ref2.position,\n gpuAcceleration = _ref2.gpuAcceleration,\n adaptive = _ref2.adaptive,\n roundOffsets = _ref2.roundOffsets,\n isFixed = _ref2.isFixed;\n var _offsets$x = offsets.x,\n x = _offsets$x === void 0 ? 0 : _offsets$x,\n _offsets$y = offsets.y,\n y = _offsets$y === void 0 ? 0 : _offsets$y;\n\n var _ref3 = typeof roundOffsets === 'function' ? roundOffsets({\n x: x,\n y: y\n }) : {\n x: x,\n y: y\n };\n\n x = _ref3.x;\n y = _ref3.y;\n var hasX = offsets.hasOwnProperty('x');\n var hasY = offsets.hasOwnProperty('y');\n var sideX = left;\n var sideY = top;\n var win = window;\n\n if (adaptive) {\n var offsetParent = getOffsetParent(popper);\n var heightProp = 'clientHeight';\n var widthProp = 'clientWidth';\n\n if (offsetParent === getWindow(popper)) {\n offsetParent = getDocumentElement(popper);\n\n if (getComputedStyle(offsetParent).position !== 'static' && position === 'absolute') {\n heightProp = 'scrollHeight';\n widthProp = 'scrollWidth';\n }\n } // $FlowFixMe[incompatible-cast]: force type refinement, we compare offsetParent with window above, but Flow doesn't detect it\n\n\n offsetParent = offsetParent;\n\n if (placement === top || (placement === left || placement === right) && variation === end) {\n sideY = bottom;\n var offsetY = isFixed && offsetParent === win && win.visualViewport ? win.visualViewport.height : // $FlowFixMe[prop-missing]\n offsetParent[heightProp];\n y -= offsetY - popperRect.height;\n y *= gpuAcceleration ? 1 : -1;\n }\n\n if (placement === left || (placement === top || placement === bottom) && variation === end) {\n sideX = right;\n var offsetX = isFixed && offsetParent === win && win.visualViewport ? win.visualViewport.width : // $FlowFixMe[prop-missing]\n offsetParent[widthProp];\n x -= offsetX - popperRect.width;\n x *= gpuAcceleration ? 1 : -1;\n }\n }\n\n var commonStyles = Object.assign({\n position: position\n }, adaptive && unsetSides);\n\n var _ref4 = roundOffsets === true ? roundOffsetsByDPR({\n x: x,\n y: y\n }, getWindow(popper)) : {\n x: x,\n y: y\n };\n\n x = _ref4.x;\n y = _ref4.y;\n\n if (gpuAcceleration) {\n var _Object$assign;\n\n return Object.assign({}, commonStyles, (_Object$assign = {}, _Object$assign[sideY] = hasY ? '0' : '', _Object$assign[sideX] = hasX ? '0' : '', _Object$assign.transform = (win.devicePixelRatio || 1) <= 1 ? \"translate(\" + x + \"px, \" + y + \"px)\" : \"translate3d(\" + x + \"px, \" + y + \"px, 0)\", _Object$assign));\n }\n\n return Object.assign({}, commonStyles, (_Object$assign2 = {}, _Object$assign2[sideY] = hasY ? y + \"px\" : '', _Object$assign2[sideX] = hasX ? x + \"px\" : '', _Object$assign2.transform = '', _Object$assign2));\n}\n\nfunction computeStyles(_ref5) {\n var state = _ref5.state,\n options = _ref5.options;\n var _options$gpuAccelerat = options.gpuAcceleration,\n gpuAcceleration = _options$gpuAccelerat === void 0 ? true : _options$gpuAccelerat,\n _options$adaptive = options.adaptive,\n adaptive = _options$adaptive === void 0 ? true : _options$adaptive,\n _options$roundOffsets = options.roundOffsets,\n roundOffsets = _options$roundOffsets === void 0 ? true : _options$roundOffsets;\n var commonStyles = {\n placement: getBasePlacement(state.placement),\n variation: getVariation(state.placement),\n popper: state.elements.popper,\n popperRect: state.rects.popper,\n gpuAcceleration: gpuAcceleration,\n isFixed: state.options.strategy === 'fixed'\n };\n\n if (state.modifiersData.popperOffsets != null) {\n state.styles.popper = Object.assign({}, state.styles.popper, mapToStyles(Object.assign({}, commonStyles, {\n offsets: state.modifiersData.popperOffsets,\n position: state.options.strategy,\n adaptive: adaptive,\n roundOffsets: roundOffsets\n })));\n }\n\n if (state.modifiersData.arrow != null) {\n state.styles.arrow = Object.assign({}, state.styles.arrow, mapToStyles(Object.assign({}, commonStyles, {\n offsets: state.modifiersData.arrow,\n position: 'absolute',\n adaptive: false,\n roundOffsets: roundOffsets\n })));\n }\n\n state.attributes.popper = Object.assign({}, state.attributes.popper, {\n 'data-popper-placement': state.placement\n });\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'computeStyles',\n enabled: true,\n phase: 'beforeWrite',\n fn: computeStyles,\n data: {}\n};","import getWindow from \"../dom-utils/getWindow.js\"; // eslint-disable-next-line import/no-unused-modules\n\nvar passive = {\n passive: true\n};\n\nfunction effect(_ref) {\n var state = _ref.state,\n instance = _ref.instance,\n options = _ref.options;\n var _options$scroll = options.scroll,\n scroll = _options$scroll === void 0 ? true : _options$scroll,\n _options$resize = options.resize,\n resize = _options$resize === void 0 ? true : _options$resize;\n var window = getWindow(state.elements.popper);\n var scrollParents = [].concat(state.scrollParents.reference, state.scrollParents.popper);\n\n if (scroll) {\n scrollParents.forEach(function (scrollParent) {\n scrollParent.addEventListener('scroll', instance.update, passive);\n });\n }\n\n if (resize) {\n window.addEventListener('resize', instance.update, passive);\n }\n\n return function () {\n if (scroll) {\n scrollParents.forEach(function (scrollParent) {\n scrollParent.removeEventListener('scroll', instance.update, passive);\n });\n }\n\n if (resize) {\n window.removeEventListener('resize', instance.update, passive);\n }\n };\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'eventListeners',\n enabled: true,\n phase: 'write',\n fn: function fn() {},\n effect: effect,\n data: {}\n};","var hash = {\n left: 'right',\n right: 'left',\n bottom: 'top',\n top: 'bottom'\n};\nexport default function getOppositePlacement(placement) {\n return placement.replace(/left|right|bottom|top/g, function (matched) {\n return hash[matched];\n });\n}","var hash = {\n start: 'end',\n end: 'start'\n};\nexport default function getOppositeVariationPlacement(placement) {\n return placement.replace(/start|end/g, function (matched) {\n return hash[matched];\n });\n}","import getWindow from \"./getWindow.js\";\nexport default function getWindowScroll(node) {\n var win = getWindow(node);\n var scrollLeft = win.pageXOffset;\n var scrollTop = win.pageYOffset;\n return {\n scrollLeft: scrollLeft,\n scrollTop: scrollTop\n };\n}","import getBoundingClientRect from \"./getBoundingClientRect.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport getWindowScroll from \"./getWindowScroll.js\";\nexport default function getWindowScrollBarX(element) {\n // If has a CSS width greater than the viewport, then this will be\n // incorrect for RTL.\n // Popper 1 is broken in this case and never had a bug report so let's assume\n // it's not an issue. I don't think anyone ever specifies width on \n // anyway.\n // Browsers where the left scrollbar doesn't cause an issue report `0` for\n // this (e.g. Edge 2019, IE11, Safari)\n return getBoundingClientRect(getDocumentElement(element)).left + getWindowScroll(element).scrollLeft;\n}","import getWindow from \"./getWindow.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport getWindowScrollBarX from \"./getWindowScrollBarX.js\";\nimport isLayoutViewport from \"./isLayoutViewport.js\";\nexport default function getViewportRect(element, strategy) {\n var win = getWindow(element);\n var html = getDocumentElement(element);\n var visualViewport = win.visualViewport;\n var width = html.clientWidth;\n var height = html.clientHeight;\n var x = 0;\n var y = 0;\n\n if (visualViewport) {\n width = visualViewport.width;\n height = visualViewport.height;\n var layoutViewport = isLayoutViewport();\n\n if (layoutViewport || !layoutViewport && strategy === 'fixed') {\n x = visualViewport.offsetLeft;\n y = visualViewport.offsetTop;\n }\n }\n\n return {\n width: width,\n height: height,\n x: x + getWindowScrollBarX(element),\n y: y\n };\n}","import getDocumentElement from \"./getDocumentElement.js\";\nimport getComputedStyle from \"./getComputedStyle.js\";\nimport getWindowScrollBarX from \"./getWindowScrollBarX.js\";\nimport getWindowScroll from \"./getWindowScroll.js\";\nimport { max } from \"../utils/math.js\"; // Gets the entire size of the scrollable document area, even extending outside\n// of the `` and `` rect bounds if horizontally scrollable\n\nexport default function getDocumentRect(element) {\n var _element$ownerDocumen;\n\n var html = getDocumentElement(element);\n var winScroll = getWindowScroll(element);\n var body = (_element$ownerDocumen = element.ownerDocument) == null ? void 0 : _element$ownerDocumen.body;\n var width = max(html.scrollWidth, html.clientWidth, body ? body.scrollWidth : 0, body ? body.clientWidth : 0);\n var height = max(html.scrollHeight, html.clientHeight, body ? body.scrollHeight : 0, body ? body.clientHeight : 0);\n var x = -winScroll.scrollLeft + getWindowScrollBarX(element);\n var y = -winScroll.scrollTop;\n\n if (getComputedStyle(body || html).direction === 'rtl') {\n x += max(html.clientWidth, body ? body.clientWidth : 0) - width;\n }\n\n return {\n width: width,\n height: height,\n x: x,\n y: y\n };\n}","import getComputedStyle from \"./getComputedStyle.js\";\nexport default function isScrollParent(element) {\n // Firefox wants us to check `-x` and `-y` variations as well\n var _getComputedStyle = getComputedStyle(element),\n overflow = _getComputedStyle.overflow,\n overflowX = _getComputedStyle.overflowX,\n overflowY = _getComputedStyle.overflowY;\n\n return /auto|scroll|overlay|hidden/.test(overflow + overflowY + overflowX);\n}","import getParentNode from \"./getParentNode.js\";\nimport isScrollParent from \"./isScrollParent.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport { isHTMLElement } from \"./instanceOf.js\";\nexport default function getScrollParent(node) {\n if (['html', 'body', '#document'].indexOf(getNodeName(node)) >= 0) {\n // $FlowFixMe[incompatible-return]: assume body is always available\n return node.ownerDocument.body;\n }\n\n if (isHTMLElement(node) && isScrollParent(node)) {\n return node;\n }\n\n return getScrollParent(getParentNode(node));\n}","import getScrollParent from \"./getScrollParent.js\";\nimport getParentNode from \"./getParentNode.js\";\nimport getWindow from \"./getWindow.js\";\nimport isScrollParent from \"./isScrollParent.js\";\n/*\ngiven a DOM element, return the list of all scroll parents, up the list of ancesors\nuntil we get to the top window object. This list is what we attach scroll listeners\nto, because if any of these parent elements scroll, we'll need to re-calculate the\nreference element's position.\n*/\n\nexport default function listScrollParents(element, list) {\n var _element$ownerDocumen;\n\n if (list === void 0) {\n list = [];\n }\n\n var scrollParent = getScrollParent(element);\n var isBody = scrollParent === ((_element$ownerDocumen = element.ownerDocument) == null ? void 0 : _element$ownerDocumen.body);\n var win = getWindow(scrollParent);\n var target = isBody ? [win].concat(win.visualViewport || [], isScrollParent(scrollParent) ? scrollParent : []) : scrollParent;\n var updatedList = list.concat(target);\n return isBody ? updatedList : // $FlowFixMe[incompatible-call]: isBody tells us target will be an HTMLElement here\n updatedList.concat(listScrollParents(getParentNode(target)));\n}","export default function rectToClientRect(rect) {\n return Object.assign({}, rect, {\n left: rect.x,\n top: rect.y,\n right: rect.x + rect.width,\n bottom: rect.y + rect.height\n });\n}","import { viewport } from \"../enums.js\";\nimport getViewportRect from \"./getViewportRect.js\";\nimport getDocumentRect from \"./getDocumentRect.js\";\nimport listScrollParents from \"./listScrollParents.js\";\nimport getOffsetParent from \"./getOffsetParent.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport getComputedStyle from \"./getComputedStyle.js\";\nimport { isElement, isHTMLElement } from \"./instanceOf.js\";\nimport getBoundingClientRect from \"./getBoundingClientRect.js\";\nimport getParentNode from \"./getParentNode.js\";\nimport contains from \"./contains.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport rectToClientRect from \"../utils/rectToClientRect.js\";\nimport { max, min } from \"../utils/math.js\";\n\nfunction getInnerBoundingClientRect(element, strategy) {\n var rect = getBoundingClientRect(element, false, strategy === 'fixed');\n rect.top = rect.top + element.clientTop;\n rect.left = rect.left + element.clientLeft;\n rect.bottom = rect.top + element.clientHeight;\n rect.right = rect.left + element.clientWidth;\n rect.width = element.clientWidth;\n rect.height = element.clientHeight;\n rect.x = rect.left;\n rect.y = rect.top;\n return rect;\n}\n\nfunction getClientRectFromMixedType(element, clippingParent, strategy) {\n return clippingParent === viewport ? rectToClientRect(getViewportRect(element, strategy)) : isElement(clippingParent) ? getInnerBoundingClientRect(clippingParent, strategy) : rectToClientRect(getDocumentRect(getDocumentElement(element)));\n} // A \"clipping parent\" is an overflowable container with the characteristic of\n// clipping (or hiding) overflowing elements with a position different from\n// `initial`\n\n\nfunction getClippingParents(element) {\n var clippingParents = listScrollParents(getParentNode(element));\n var canEscapeClipping = ['absolute', 'fixed'].indexOf(getComputedStyle(element).position) >= 0;\n var clipperElement = canEscapeClipping && isHTMLElement(element) ? getOffsetParent(element) : element;\n\n if (!isElement(clipperElement)) {\n return [];\n } // $FlowFixMe[incompatible-return]: https://github.com/facebook/flow/issues/1414\n\n\n return clippingParents.filter(function (clippingParent) {\n return isElement(clippingParent) && contains(clippingParent, clipperElement) && getNodeName(clippingParent) !== 'body';\n });\n} // Gets the maximum area that the element is visible in due to any number of\n// clipping parents\n\n\nexport default function getClippingRect(element, boundary, rootBoundary, strategy) {\n var mainClippingParents = boundary === 'clippingParents' ? getClippingParents(element) : [].concat(boundary);\n var clippingParents = [].concat(mainClippingParents, [rootBoundary]);\n var firstClippingParent = clippingParents[0];\n var clippingRect = clippingParents.reduce(function (accRect, clippingParent) {\n var rect = getClientRectFromMixedType(element, clippingParent, strategy);\n accRect.top = max(rect.top, accRect.top);\n accRect.right = min(rect.right, accRect.right);\n accRect.bottom = min(rect.bottom, accRect.bottom);\n accRect.left = max(rect.left, accRect.left);\n return accRect;\n }, getClientRectFromMixedType(element, firstClippingParent, strategy));\n clippingRect.width = clippingRect.right - clippingRect.left;\n clippingRect.height = clippingRect.bottom - clippingRect.top;\n clippingRect.x = clippingRect.left;\n clippingRect.y = clippingRect.top;\n return clippingRect;\n}","import getBasePlacement from \"./getBasePlacement.js\";\nimport getVariation from \"./getVariation.js\";\nimport getMainAxisFromPlacement from \"./getMainAxisFromPlacement.js\";\nimport { top, right, bottom, left, start, end } from \"../enums.js\";\nexport default function computeOffsets(_ref) {\n var reference = _ref.reference,\n element = _ref.element,\n placement = _ref.placement;\n var basePlacement = placement ? getBasePlacement(placement) : null;\n var variation = placement ? getVariation(placement) : null;\n var commonX = reference.x + reference.width / 2 - element.width / 2;\n var commonY = reference.y + reference.height / 2 - element.height / 2;\n var offsets;\n\n switch (basePlacement) {\n case top:\n offsets = {\n x: commonX,\n y: reference.y - element.height\n };\n break;\n\n case bottom:\n offsets = {\n x: commonX,\n y: reference.y + reference.height\n };\n break;\n\n case right:\n offsets = {\n x: reference.x + reference.width,\n y: commonY\n };\n break;\n\n case left:\n offsets = {\n x: reference.x - element.width,\n y: commonY\n };\n break;\n\n default:\n offsets = {\n x: reference.x,\n y: reference.y\n };\n }\n\n var mainAxis = basePlacement ? getMainAxisFromPlacement(basePlacement) : null;\n\n if (mainAxis != null) {\n var len = mainAxis === 'y' ? 'height' : 'width';\n\n switch (variation) {\n case start:\n offsets[mainAxis] = offsets[mainAxis] - (reference[len] / 2 - element[len] / 2);\n break;\n\n case end:\n offsets[mainAxis] = offsets[mainAxis] + (reference[len] / 2 - element[len] / 2);\n break;\n\n default:\n }\n }\n\n return offsets;\n}","import getClippingRect from \"../dom-utils/getClippingRect.js\";\nimport getDocumentElement from \"../dom-utils/getDocumentElement.js\";\nimport getBoundingClientRect from \"../dom-utils/getBoundingClientRect.js\";\nimport computeOffsets from \"./computeOffsets.js\";\nimport rectToClientRect from \"./rectToClientRect.js\";\nimport { clippingParents, reference, popper, bottom, top, right, basePlacements, viewport } from \"../enums.js\";\nimport { isElement } from \"../dom-utils/instanceOf.js\";\nimport mergePaddingObject from \"./mergePaddingObject.js\";\nimport expandToHashMap from \"./expandToHashMap.js\"; // eslint-disable-next-line import/no-unused-modules\n\nexport default function detectOverflow(state, options) {\n if (options === void 0) {\n options = {};\n }\n\n var _options = options,\n _options$placement = _options.placement,\n placement = _options$placement === void 0 ? state.placement : _options$placement,\n _options$strategy = _options.strategy,\n strategy = _options$strategy === void 0 ? state.strategy : _options$strategy,\n _options$boundary = _options.boundary,\n boundary = _options$boundary === void 0 ? clippingParents : _options$boundary,\n _options$rootBoundary = _options.rootBoundary,\n rootBoundary = _options$rootBoundary === void 0 ? viewport : _options$rootBoundary,\n _options$elementConte = _options.elementContext,\n elementContext = _options$elementConte === void 0 ? popper : _options$elementConte,\n _options$altBoundary = _options.altBoundary,\n altBoundary = _options$altBoundary === void 0 ? false : _options$altBoundary,\n _options$padding = _options.padding,\n padding = _options$padding === void 0 ? 0 : _options$padding;\n var paddingObject = mergePaddingObject(typeof padding !== 'number' ? padding : expandToHashMap(padding, basePlacements));\n var altContext = elementContext === popper ? reference : popper;\n var popperRect = state.rects.popper;\n var element = state.elements[altBoundary ? altContext : elementContext];\n var clippingClientRect = getClippingRect(isElement(element) ? element : element.contextElement || getDocumentElement(state.elements.popper), boundary, rootBoundary, strategy);\n var referenceClientRect = getBoundingClientRect(state.elements.reference);\n var popperOffsets = computeOffsets({\n reference: referenceClientRect,\n element: popperRect,\n strategy: 'absolute',\n placement: placement\n });\n var popperClientRect = rectToClientRect(Object.assign({}, popperRect, popperOffsets));\n var elementClientRect = elementContext === popper ? popperClientRect : referenceClientRect; // positive = overflowing the clipping rect\n // 0 or negative = within the clipping rect\n\n var overflowOffsets = {\n top: clippingClientRect.top - elementClientRect.top + paddingObject.top,\n bottom: elementClientRect.bottom - clippingClientRect.bottom + paddingObject.bottom,\n left: clippingClientRect.left - elementClientRect.left + paddingObject.left,\n right: elementClientRect.right - clippingClientRect.right + paddingObject.right\n };\n var offsetData = state.modifiersData.offset; // Offsets can be applied only to the popper element\n\n if (elementContext === popper && offsetData) {\n var offset = offsetData[placement];\n Object.keys(overflowOffsets).forEach(function (key) {\n var multiply = [right, bottom].indexOf(key) >= 0 ? 1 : -1;\n var axis = [top, bottom].indexOf(key) >= 0 ? 'y' : 'x';\n overflowOffsets[key] += offset[axis] * multiply;\n });\n }\n\n return overflowOffsets;\n}","import getVariation from \"./getVariation.js\";\nimport { variationPlacements, basePlacements, placements as allPlacements } from \"../enums.js\";\nimport detectOverflow from \"./detectOverflow.js\";\nimport getBasePlacement from \"./getBasePlacement.js\";\nexport default function computeAutoPlacement(state, options) {\n if (options === void 0) {\n options = {};\n }\n\n var _options = options,\n placement = _options.placement,\n boundary = _options.boundary,\n rootBoundary = _options.rootBoundary,\n padding = _options.padding,\n flipVariations = _options.flipVariations,\n _options$allowedAutoP = _options.allowedAutoPlacements,\n allowedAutoPlacements = _options$allowedAutoP === void 0 ? allPlacements : _options$allowedAutoP;\n var variation = getVariation(placement);\n var placements = variation ? flipVariations ? variationPlacements : variationPlacements.filter(function (placement) {\n return getVariation(placement) === variation;\n }) : basePlacements;\n var allowedPlacements = placements.filter(function (placement) {\n return allowedAutoPlacements.indexOf(placement) >= 0;\n });\n\n if (allowedPlacements.length === 0) {\n allowedPlacements = placements;\n } // $FlowFixMe[incompatible-type]: Flow seems to have problems with two array unions...\n\n\n var overflows = allowedPlacements.reduce(function (acc, placement) {\n acc[placement] = detectOverflow(state, {\n placement: placement,\n boundary: boundary,\n rootBoundary: rootBoundary,\n padding: padding\n })[getBasePlacement(placement)];\n return acc;\n }, {});\n return Object.keys(overflows).sort(function (a, b) {\n return overflows[a] - overflows[b];\n });\n}","import getOppositePlacement from \"../utils/getOppositePlacement.js\";\nimport getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getOppositeVariationPlacement from \"../utils/getOppositeVariationPlacement.js\";\nimport detectOverflow from \"../utils/detectOverflow.js\";\nimport computeAutoPlacement from \"../utils/computeAutoPlacement.js\";\nimport { bottom, top, start, right, left, auto } from \"../enums.js\";\nimport getVariation from \"../utils/getVariation.js\"; // eslint-disable-next-line import/no-unused-modules\n\nfunction getExpandedFallbackPlacements(placement) {\n if (getBasePlacement(placement) === auto) {\n return [];\n }\n\n var oppositePlacement = getOppositePlacement(placement);\n return [getOppositeVariationPlacement(placement), oppositePlacement, getOppositeVariationPlacement(oppositePlacement)];\n}\n\nfunction flip(_ref) {\n var state = _ref.state,\n options = _ref.options,\n name = _ref.name;\n\n if (state.modifiersData[name]._skip) {\n return;\n }\n\n var _options$mainAxis = options.mainAxis,\n checkMainAxis = _options$mainAxis === void 0 ? true : _options$mainAxis,\n _options$altAxis = options.altAxis,\n checkAltAxis = _options$altAxis === void 0 ? true : _options$altAxis,\n specifiedFallbackPlacements = options.fallbackPlacements,\n padding = options.padding,\n boundary = options.boundary,\n rootBoundary = options.rootBoundary,\n altBoundary = options.altBoundary,\n _options$flipVariatio = options.flipVariations,\n flipVariations = _options$flipVariatio === void 0 ? true : _options$flipVariatio,\n allowedAutoPlacements = options.allowedAutoPlacements;\n var preferredPlacement = state.options.placement;\n var basePlacement = getBasePlacement(preferredPlacement);\n var isBasePlacement = basePlacement === preferredPlacement;\n var fallbackPlacements = specifiedFallbackPlacements || (isBasePlacement || !flipVariations ? [getOppositePlacement(preferredPlacement)] : getExpandedFallbackPlacements(preferredPlacement));\n var placements = [preferredPlacement].concat(fallbackPlacements).reduce(function (acc, placement) {\n return acc.concat(getBasePlacement(placement) === auto ? computeAutoPlacement(state, {\n placement: placement,\n boundary: boundary,\n rootBoundary: rootBoundary,\n padding: padding,\n flipVariations: flipVariations,\n allowedAutoPlacements: allowedAutoPlacements\n }) : placement);\n }, []);\n var referenceRect = state.rects.reference;\n var popperRect = state.rects.popper;\n var checksMap = new Map();\n var makeFallbackChecks = true;\n var firstFittingPlacement = placements[0];\n\n for (var i = 0; i < placements.length; i++) {\n var placement = placements[i];\n\n var _basePlacement = getBasePlacement(placement);\n\n var isStartVariation = getVariation(placement) === start;\n var isVertical = [top, bottom].indexOf(_basePlacement) >= 0;\n var len = isVertical ? 'width' : 'height';\n var overflow = detectOverflow(state, {\n placement: placement,\n boundary: boundary,\n rootBoundary: rootBoundary,\n altBoundary: altBoundary,\n padding: padding\n });\n var mainVariationSide = isVertical ? isStartVariation ? right : left : isStartVariation ? bottom : top;\n\n if (referenceRect[len] > popperRect[len]) {\n mainVariationSide = getOppositePlacement(mainVariationSide);\n }\n\n var altVariationSide = getOppositePlacement(mainVariationSide);\n var checks = [];\n\n if (checkMainAxis) {\n checks.push(overflow[_basePlacement] <= 0);\n }\n\n if (checkAltAxis) {\n checks.push(overflow[mainVariationSide] <= 0, overflow[altVariationSide] <= 0);\n }\n\n if (checks.every(function (check) {\n return check;\n })) {\n firstFittingPlacement = placement;\n makeFallbackChecks = false;\n break;\n }\n\n checksMap.set(placement, checks);\n }\n\n if (makeFallbackChecks) {\n // `2` may be desired in some cases – research later\n var numberOfChecks = flipVariations ? 3 : 1;\n\n var _loop = function _loop(_i) {\n var fittingPlacement = placements.find(function (placement) {\n var checks = checksMap.get(placement);\n\n if (checks) {\n return checks.slice(0, _i).every(function (check) {\n return check;\n });\n }\n });\n\n if (fittingPlacement) {\n firstFittingPlacement = fittingPlacement;\n return \"break\";\n }\n };\n\n for (var _i = numberOfChecks; _i > 0; _i--) {\n var _ret = _loop(_i);\n\n if (_ret === \"break\") break;\n }\n }\n\n if (state.placement !== firstFittingPlacement) {\n state.modifiersData[name]._skip = true;\n state.placement = firstFittingPlacement;\n state.reset = true;\n }\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'flip',\n enabled: true,\n phase: 'main',\n fn: flip,\n requiresIfExists: ['offset'],\n data: {\n _skip: false\n }\n};","import { top, bottom, left, right } from \"../enums.js\";\nimport detectOverflow from \"../utils/detectOverflow.js\";\n\nfunction getSideOffsets(overflow, rect, preventedOffsets) {\n if (preventedOffsets === void 0) {\n preventedOffsets = {\n x: 0,\n y: 0\n };\n }\n\n return {\n top: overflow.top - rect.height - preventedOffsets.y,\n right: overflow.right - rect.width + preventedOffsets.x,\n bottom: overflow.bottom - rect.height + preventedOffsets.y,\n left: overflow.left - rect.width - preventedOffsets.x\n };\n}\n\nfunction isAnySideFullyClipped(overflow) {\n return [top, right, bottom, left].some(function (side) {\n return overflow[side] >= 0;\n });\n}\n\nfunction hide(_ref) {\n var state = _ref.state,\n name = _ref.name;\n var referenceRect = state.rects.reference;\n var popperRect = state.rects.popper;\n var preventedOffsets = state.modifiersData.preventOverflow;\n var referenceOverflow = detectOverflow(state, {\n elementContext: 'reference'\n });\n var popperAltOverflow = detectOverflow(state, {\n altBoundary: true\n });\n var referenceClippingOffsets = getSideOffsets(referenceOverflow, referenceRect);\n var popperEscapeOffsets = getSideOffsets(popperAltOverflow, popperRect, preventedOffsets);\n var isReferenceHidden = isAnySideFullyClipped(referenceClippingOffsets);\n var hasPopperEscaped = isAnySideFullyClipped(popperEscapeOffsets);\n state.modifiersData[name] = {\n referenceClippingOffsets: referenceClippingOffsets,\n popperEscapeOffsets: popperEscapeOffsets,\n isReferenceHidden: isReferenceHidden,\n hasPopperEscaped: hasPopperEscaped\n };\n state.attributes.popper = Object.assign({}, state.attributes.popper, {\n 'data-popper-reference-hidden': isReferenceHidden,\n 'data-popper-escaped': hasPopperEscaped\n });\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'hide',\n enabled: true,\n phase: 'main',\n requiresIfExists: ['preventOverflow'],\n fn: hide\n};","import getBasePlacement from \"../utils/getBasePlacement.js\";\nimport { top, left, right, placements } from \"../enums.js\"; // eslint-disable-next-line import/no-unused-modules\n\nexport function distanceAndSkiddingToXY(placement, rects, offset) {\n var basePlacement = getBasePlacement(placement);\n var invertDistance = [left, top].indexOf(basePlacement) >= 0 ? -1 : 1;\n\n var _ref = typeof offset === 'function' ? offset(Object.assign({}, rects, {\n placement: placement\n })) : offset,\n skidding = _ref[0],\n distance = _ref[1];\n\n skidding = skidding || 0;\n distance = (distance || 0) * invertDistance;\n return [left, right].indexOf(basePlacement) >= 0 ? {\n x: distance,\n y: skidding\n } : {\n x: skidding,\n y: distance\n };\n}\n\nfunction offset(_ref2) {\n var state = _ref2.state,\n options = _ref2.options,\n name = _ref2.name;\n var _options$offset = options.offset,\n offset = _options$offset === void 0 ? [0, 0] : _options$offset;\n var data = placements.reduce(function (acc, placement) {\n acc[placement] = distanceAndSkiddingToXY(placement, state.rects, offset);\n return acc;\n }, {});\n var _data$state$placement = data[state.placement],\n x = _data$state$placement.x,\n y = _data$state$placement.y;\n\n if (state.modifiersData.popperOffsets != null) {\n state.modifiersData.popperOffsets.x += x;\n state.modifiersData.popperOffsets.y += y;\n }\n\n state.modifiersData[name] = data;\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'offset',\n enabled: true,\n phase: 'main',\n requires: ['popperOffsets'],\n fn: offset\n};","import computeOffsets from \"../utils/computeOffsets.js\";\n\nfunction popperOffsets(_ref) {\n var state = _ref.state,\n name = _ref.name;\n // Offsets are the actual position the popper needs to have to be\n // properly positioned near its reference element\n // This is the most basic placement, and will be adjusted by\n // the modifiers in the next step\n state.modifiersData[name] = computeOffsets({\n reference: state.rects.reference,\n element: state.rects.popper,\n strategy: 'absolute',\n placement: state.placement\n });\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'popperOffsets',\n enabled: true,\n phase: 'read',\n fn: popperOffsets,\n data: {}\n};","export default function getAltAxis(axis) {\n return axis === 'x' ? 'y' : 'x';\n}","import { top, left, right, bottom, start } from \"../enums.js\";\nimport getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getMainAxisFromPlacement from \"../utils/getMainAxisFromPlacement.js\";\nimport getAltAxis from \"../utils/getAltAxis.js\";\nimport { within, withinMaxClamp } from \"../utils/within.js\";\nimport getLayoutRect from \"../dom-utils/getLayoutRect.js\";\nimport getOffsetParent from \"../dom-utils/getOffsetParent.js\";\nimport detectOverflow from \"../utils/detectOverflow.js\";\nimport getVariation from \"../utils/getVariation.js\";\nimport getFreshSideObject from \"../utils/getFreshSideObject.js\";\nimport { min as mathMin, max as mathMax } from \"../utils/math.js\";\n\nfunction preventOverflow(_ref) {\n var state = _ref.state,\n options = _ref.options,\n name = _ref.name;\n var _options$mainAxis = options.mainAxis,\n checkMainAxis = _options$mainAxis === void 0 ? true : _options$mainAxis,\n _options$altAxis = options.altAxis,\n checkAltAxis = _options$altAxis === void 0 ? false : _options$altAxis,\n boundary = options.boundary,\n rootBoundary = options.rootBoundary,\n altBoundary = options.altBoundary,\n padding = options.padding,\n _options$tether = options.tether,\n tether = _options$tether === void 0 ? true : _options$tether,\n _options$tetherOffset = options.tetherOffset,\n tetherOffset = _options$tetherOffset === void 0 ? 0 : _options$tetherOffset;\n var overflow = detectOverflow(state, {\n boundary: boundary,\n rootBoundary: rootBoundary,\n padding: padding,\n altBoundary: altBoundary\n });\n var basePlacement = getBasePlacement(state.placement);\n var variation = getVariation(state.placement);\n var isBasePlacement = !variation;\n var mainAxis = getMainAxisFromPlacement(basePlacement);\n var altAxis = getAltAxis(mainAxis);\n var popperOffsets = state.modifiersData.popperOffsets;\n var referenceRect = state.rects.reference;\n var popperRect = state.rects.popper;\n var tetherOffsetValue = typeof tetherOffset === 'function' ? tetherOffset(Object.assign({}, state.rects, {\n placement: state.placement\n })) : tetherOffset;\n var normalizedTetherOffsetValue = typeof tetherOffsetValue === 'number' ? {\n mainAxis: tetherOffsetValue,\n altAxis: tetherOffsetValue\n } : Object.assign({\n mainAxis: 0,\n altAxis: 0\n }, tetherOffsetValue);\n var offsetModifierState = state.modifiersData.offset ? state.modifiersData.offset[state.placement] : null;\n var data = {\n x: 0,\n y: 0\n };\n\n if (!popperOffsets) {\n return;\n }\n\n if (checkMainAxis) {\n var _offsetModifierState$;\n\n var mainSide = mainAxis === 'y' ? top : left;\n var altSide = mainAxis === 'y' ? bottom : right;\n var len = mainAxis === 'y' ? 'height' : 'width';\n var offset = popperOffsets[mainAxis];\n var min = offset + overflow[mainSide];\n var max = offset - overflow[altSide];\n var additive = tether ? -popperRect[len] / 2 : 0;\n var minLen = variation === start ? referenceRect[len] : popperRect[len];\n var maxLen = variation === start ? -popperRect[len] : -referenceRect[len]; // We need to include the arrow in the calculation so the arrow doesn't go\n // outside the reference bounds\n\n var arrowElement = state.elements.arrow;\n var arrowRect = tether && arrowElement ? getLayoutRect(arrowElement) : {\n width: 0,\n height: 0\n };\n var arrowPaddingObject = state.modifiersData['arrow#persistent'] ? state.modifiersData['arrow#persistent'].padding : getFreshSideObject();\n var arrowPaddingMin = arrowPaddingObject[mainSide];\n var arrowPaddingMax = arrowPaddingObject[altSide]; // If the reference length is smaller than the arrow length, we don't want\n // to include its full size in the calculation. If the reference is small\n // and near the edge of a boundary, the popper can overflow even if the\n // reference is not overflowing as well (e.g. virtual elements with no\n // width or height)\n\n var arrowLen = within(0, referenceRect[len], arrowRect[len]);\n var minOffset = isBasePlacement ? referenceRect[len] / 2 - additive - arrowLen - arrowPaddingMin - normalizedTetherOffsetValue.mainAxis : minLen - arrowLen - arrowPaddingMin - normalizedTetherOffsetValue.mainAxis;\n var maxOffset = isBasePlacement ? -referenceRect[len] / 2 + additive + arrowLen + arrowPaddingMax + normalizedTetherOffsetValue.mainAxis : maxLen + arrowLen + arrowPaddingMax + normalizedTetherOffsetValue.mainAxis;\n var arrowOffsetParent = state.elements.arrow && getOffsetParent(state.elements.arrow);\n var clientOffset = arrowOffsetParent ? mainAxis === 'y' ? arrowOffsetParent.clientTop || 0 : arrowOffsetParent.clientLeft || 0 : 0;\n var offsetModifierValue = (_offsetModifierState$ = offsetModifierState == null ? void 0 : offsetModifierState[mainAxis]) != null ? _offsetModifierState$ : 0;\n var tetherMin = offset + minOffset - offsetModifierValue - clientOffset;\n var tetherMax = offset + maxOffset - offsetModifierValue;\n var preventedOffset = within(tether ? mathMin(min, tetherMin) : min, offset, tether ? mathMax(max, tetherMax) : max);\n popperOffsets[mainAxis] = preventedOffset;\n data[mainAxis] = preventedOffset - offset;\n }\n\n if (checkAltAxis) {\n var _offsetModifierState$2;\n\n var _mainSide = mainAxis === 'x' ? top : left;\n\n var _altSide = mainAxis === 'x' ? bottom : right;\n\n var _offset = popperOffsets[altAxis];\n\n var _len = altAxis === 'y' ? 'height' : 'width';\n\n var _min = _offset + overflow[_mainSide];\n\n var _max = _offset - overflow[_altSide];\n\n var isOriginSide = [top, left].indexOf(basePlacement) !== -1;\n\n var _offsetModifierValue = (_offsetModifierState$2 = offsetModifierState == null ? void 0 : offsetModifierState[altAxis]) != null ? _offsetModifierState$2 : 0;\n\n var _tetherMin = isOriginSide ? _min : _offset - referenceRect[_len] - popperRect[_len] - _offsetModifierValue + normalizedTetherOffsetValue.altAxis;\n\n var _tetherMax = isOriginSide ? _offset + referenceRect[_len] + popperRect[_len] - _offsetModifierValue - normalizedTetherOffsetValue.altAxis : _max;\n\n var _preventedOffset = tether && isOriginSide ? withinMaxClamp(_tetherMin, _offset, _tetherMax) : within(tether ? _tetherMin : _min, _offset, tether ? _tetherMax : _max);\n\n popperOffsets[altAxis] = _preventedOffset;\n data[altAxis] = _preventedOffset - _offset;\n }\n\n state.modifiersData[name] = data;\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'preventOverflow',\n enabled: true,\n phase: 'main',\n fn: preventOverflow,\n requiresIfExists: ['offset']\n};","export default function getHTMLElementScroll(element) {\n return {\n scrollLeft: element.scrollLeft,\n scrollTop: element.scrollTop\n };\n}","import getWindowScroll from \"./getWindowScroll.js\";\nimport getWindow from \"./getWindow.js\";\nimport { isHTMLElement } from \"./instanceOf.js\";\nimport getHTMLElementScroll from \"./getHTMLElementScroll.js\";\nexport default function getNodeScroll(node) {\n if (node === getWindow(node) || !isHTMLElement(node)) {\n return getWindowScroll(node);\n } else {\n return getHTMLElementScroll(node);\n }\n}","import getBoundingClientRect from \"./getBoundingClientRect.js\";\nimport getNodeScroll from \"./getNodeScroll.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport { isHTMLElement } from \"./instanceOf.js\";\nimport getWindowScrollBarX from \"./getWindowScrollBarX.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport isScrollParent from \"./isScrollParent.js\";\nimport { round } from \"../utils/math.js\";\n\nfunction isElementScaled(element) {\n var rect = element.getBoundingClientRect();\n var scaleX = round(rect.width) / element.offsetWidth || 1;\n var scaleY = round(rect.height) / element.offsetHeight || 1;\n return scaleX !== 1 || scaleY !== 1;\n} // Returns the composite rect of an element relative to its offsetParent.\n// Composite means it takes into account transforms as well as layout.\n\n\nexport default function getCompositeRect(elementOrVirtualElement, offsetParent, isFixed) {\n if (isFixed === void 0) {\n isFixed = false;\n }\n\n var isOffsetParentAnElement = isHTMLElement(offsetParent);\n var offsetParentIsScaled = isHTMLElement(offsetParent) && isElementScaled(offsetParent);\n var documentElement = getDocumentElement(offsetParent);\n var rect = getBoundingClientRect(elementOrVirtualElement, offsetParentIsScaled, isFixed);\n var scroll = {\n scrollLeft: 0,\n scrollTop: 0\n };\n var offsets = {\n x: 0,\n y: 0\n };\n\n if (isOffsetParentAnElement || !isOffsetParentAnElement && !isFixed) {\n if (getNodeName(offsetParent) !== 'body' || // https://github.com/popperjs/popper-core/issues/1078\n isScrollParent(documentElement)) {\n scroll = getNodeScroll(offsetParent);\n }\n\n if (isHTMLElement(offsetParent)) {\n offsets = getBoundingClientRect(offsetParent, true);\n offsets.x += offsetParent.clientLeft;\n offsets.y += offsetParent.clientTop;\n } else if (documentElement) {\n offsets.x = getWindowScrollBarX(documentElement);\n }\n }\n\n return {\n x: rect.left + scroll.scrollLeft - offsets.x,\n y: rect.top + scroll.scrollTop - offsets.y,\n width: rect.width,\n height: rect.height\n };\n}","import { modifierPhases } from \"../enums.js\"; // source: https://stackoverflow.com/questions/49875255\n\nfunction order(modifiers) {\n var map = new Map();\n var visited = new Set();\n var result = [];\n modifiers.forEach(function (modifier) {\n map.set(modifier.name, modifier);\n }); // On visiting object, check for its dependencies and visit them recursively\n\n function sort(modifier) {\n visited.add(modifier.name);\n var requires = [].concat(modifier.requires || [], modifier.requiresIfExists || []);\n requires.forEach(function (dep) {\n if (!visited.has(dep)) {\n var depModifier = map.get(dep);\n\n if (depModifier) {\n sort(depModifier);\n }\n }\n });\n result.push(modifier);\n }\n\n modifiers.forEach(function (modifier) {\n if (!visited.has(modifier.name)) {\n // check for visited object\n sort(modifier);\n }\n });\n return result;\n}\n\nexport default function orderModifiers(modifiers) {\n // order based on dependencies\n var orderedModifiers = order(modifiers); // order based on phase\n\n return modifierPhases.reduce(function (acc, phase) {\n return acc.concat(orderedModifiers.filter(function (modifier) {\n return modifier.phase === phase;\n }));\n }, []);\n}","export default function debounce(fn) {\n var pending;\n return function () {\n if (!pending) {\n pending = new Promise(function (resolve) {\n Promise.resolve().then(function () {\n pending = undefined;\n resolve(fn());\n });\n });\n }\n\n return pending;\n };\n}","export default function mergeByName(modifiers) {\n var merged = modifiers.reduce(function (merged, current) {\n var existing = merged[current.name];\n merged[current.name] = existing ? Object.assign({}, existing, current, {\n options: Object.assign({}, existing.options, current.options),\n data: Object.assign({}, existing.data, current.data)\n }) : current;\n return merged;\n }, {}); // IE11 does not support Object.values\n\n return Object.keys(merged).map(function (key) {\n return merged[key];\n });\n}","import getCompositeRect from \"./dom-utils/getCompositeRect.js\";\nimport getLayoutRect from \"./dom-utils/getLayoutRect.js\";\nimport listScrollParents from \"./dom-utils/listScrollParents.js\";\nimport getOffsetParent from \"./dom-utils/getOffsetParent.js\";\nimport orderModifiers from \"./utils/orderModifiers.js\";\nimport debounce from \"./utils/debounce.js\";\nimport mergeByName from \"./utils/mergeByName.js\";\nimport detectOverflow from \"./utils/detectOverflow.js\";\nimport { isElement } from \"./dom-utils/instanceOf.js\";\nvar DEFAULT_OPTIONS = {\n placement: 'bottom',\n modifiers: [],\n strategy: 'absolute'\n};\n\nfunction areValidElements() {\n for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {\n args[_key] = arguments[_key];\n }\n\n return !args.some(function (element) {\n return !(element && typeof element.getBoundingClientRect === 'function');\n });\n}\n\nexport function popperGenerator(generatorOptions) {\n if (generatorOptions === void 0) {\n generatorOptions = {};\n }\n\n var _generatorOptions = generatorOptions,\n _generatorOptions$def = _generatorOptions.defaultModifiers,\n defaultModifiers = _generatorOptions$def === void 0 ? [] : _generatorOptions$def,\n _generatorOptions$def2 = _generatorOptions.defaultOptions,\n defaultOptions = _generatorOptions$def2 === void 0 ? DEFAULT_OPTIONS : _generatorOptions$def2;\n return function createPopper(reference, popper, options) {\n if (options === void 0) {\n options = defaultOptions;\n }\n\n var state = {\n placement: 'bottom',\n orderedModifiers: [],\n options: Object.assign({}, DEFAULT_OPTIONS, defaultOptions),\n modifiersData: {},\n elements: {\n reference: reference,\n popper: popper\n },\n attributes: {},\n styles: {}\n };\n var effectCleanupFns = [];\n var isDestroyed = false;\n var instance = {\n state: state,\n setOptions: function setOptions(setOptionsAction) {\n var options = typeof setOptionsAction === 'function' ? setOptionsAction(state.options) : setOptionsAction;\n cleanupModifierEffects();\n state.options = Object.assign({}, defaultOptions, state.options, options);\n state.scrollParents = {\n reference: isElement(reference) ? listScrollParents(reference) : reference.contextElement ? listScrollParents(reference.contextElement) : [],\n popper: listScrollParents(popper)\n }; // Orders the modifiers based on their dependencies and `phase`\n // properties\n\n var orderedModifiers = orderModifiers(mergeByName([].concat(defaultModifiers, state.options.modifiers))); // Strip out disabled modifiers\n\n state.orderedModifiers = orderedModifiers.filter(function (m) {\n return m.enabled;\n });\n runModifierEffects();\n return instance.update();\n },\n // Sync update – it will always be executed, even if not necessary. This\n // is useful for low frequency updates where sync behavior simplifies the\n // logic.\n // For high frequency updates (e.g. `resize` and `scroll` events), always\n // prefer the async Popper#update method\n forceUpdate: function forceUpdate() {\n if (isDestroyed) {\n return;\n }\n\n var _state$elements = state.elements,\n reference = _state$elements.reference,\n popper = _state$elements.popper; // Don't proceed if `reference` or `popper` are not valid elements\n // anymore\n\n if (!areValidElements(reference, popper)) {\n return;\n } // Store the reference and popper rects to be read by modifiers\n\n\n state.rects = {\n reference: getCompositeRect(reference, getOffsetParent(popper), state.options.strategy === 'fixed'),\n popper: getLayoutRect(popper)\n }; // Modifiers have the ability to reset the current update cycle. The\n // most common use case for this is the `flip` modifier changing the\n // placement, which then needs to re-run all the modifiers, because the\n // logic was previously ran for the previous placement and is therefore\n // stale/incorrect\n\n state.reset = false;\n state.placement = state.options.placement; // On each update cycle, the `modifiersData` property for each modifier\n // is filled with the initial data specified by the modifier. This means\n // it doesn't persist and is fresh on each update.\n // To ensure persistent data, use `${name}#persistent`\n\n state.orderedModifiers.forEach(function (modifier) {\n return state.modifiersData[modifier.name] = Object.assign({}, modifier.data);\n });\n\n for (var index = 0; index < state.orderedModifiers.length; index++) {\n if (state.reset === true) {\n state.reset = false;\n index = -1;\n continue;\n }\n\n var _state$orderedModifie = state.orderedModifiers[index],\n fn = _state$orderedModifie.fn,\n _state$orderedModifie2 = _state$orderedModifie.options,\n _options = _state$orderedModifie2 === void 0 ? {} : _state$orderedModifie2,\n name = _state$orderedModifie.name;\n\n if (typeof fn === 'function') {\n state = fn({\n state: state,\n options: _options,\n name: name,\n instance: instance\n }) || state;\n }\n }\n },\n // Async and optimistically optimized update – it will not be executed if\n // not necessary (debounced to run at most once-per-tick)\n update: debounce(function () {\n return new Promise(function (resolve) {\n instance.forceUpdate();\n resolve(state);\n });\n }),\n destroy: function destroy() {\n cleanupModifierEffects();\n isDestroyed = true;\n }\n };\n\n if (!areValidElements(reference, popper)) {\n return instance;\n }\n\n instance.setOptions(options).then(function (state) {\n if (!isDestroyed && options.onFirstUpdate) {\n options.onFirstUpdate(state);\n }\n }); // Modifiers have the ability to execute arbitrary code before the first\n // update cycle runs. They will be executed in the same order as the update\n // cycle. This is useful when a modifier adds some persistent data that\n // other modifiers need to use, but the modifier is run after the dependent\n // one.\n\n function runModifierEffects() {\n state.orderedModifiers.forEach(function (_ref) {\n var name = _ref.name,\n _ref$options = _ref.options,\n options = _ref$options === void 0 ? {} : _ref$options,\n effect = _ref.effect;\n\n if (typeof effect === 'function') {\n var cleanupFn = effect({\n state: state,\n name: name,\n instance: instance,\n options: options\n });\n\n var noopFn = function noopFn() {};\n\n effectCleanupFns.push(cleanupFn || noopFn);\n }\n });\n }\n\n function cleanupModifierEffects() {\n effectCleanupFns.forEach(function (fn) {\n return fn();\n });\n effectCleanupFns = [];\n }\n\n return instance;\n };\n}\nexport var createPopper = /*#__PURE__*/popperGenerator(); // eslint-disable-next-line import/no-unused-modules\n\nexport { detectOverflow };","import { popperGenerator, detectOverflow } from \"./createPopper.js\";\nimport eventListeners from \"./modifiers/eventListeners.js\";\nimport popperOffsets from \"./modifiers/popperOffsets.js\";\nimport computeStyles from \"./modifiers/computeStyles.js\";\nimport applyStyles from \"./modifiers/applyStyles.js\";\nimport offset from \"./modifiers/offset.js\";\nimport flip from \"./modifiers/flip.js\";\nimport preventOverflow from \"./modifiers/preventOverflow.js\";\nimport arrow from \"./modifiers/arrow.js\";\nimport hide from \"./modifiers/hide.js\";\nvar defaultModifiers = [eventListeners, popperOffsets, computeStyles, applyStyles, offset, flip, preventOverflow, arrow, hide];\nvar createPopper = /*#__PURE__*/popperGenerator({\n defaultModifiers: defaultModifiers\n}); // eslint-disable-next-line import/no-unused-modules\n\nexport { createPopper, popperGenerator, defaultModifiers, detectOverflow }; // eslint-disable-next-line import/no-unused-modules\n\nexport { createPopper as createPopperLite } from \"./popper-lite.js\"; // eslint-disable-next-line import/no-unused-modules\n\nexport * from \"./modifiers/index.js\";","import { generateUtilityClass } from '../generateUtilityClass';\nimport { generateUtilityClasses } from '../generateUtilityClasses';\nconst COMPONENT_NAME = 'Popper';\nexport function getPopperUtilityClass(slot) {\n return generateUtilityClass(COMPONENT_NAME, slot);\n}\nexport const popperClasses = generateUtilityClasses(COMPONENT_NAME, ['root']);","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"anchorEl\", \"children\", \"direction\", \"disablePortal\", \"modifiers\", \"open\", \"placement\", \"popperOptions\", \"popperRef\", \"slotProps\", \"slots\", \"TransitionProps\", \"ownerState\"],\n _excluded2 = [\"anchorEl\", \"children\", \"container\", \"direction\", \"disablePortal\", \"keepMounted\", \"modifiers\", \"open\", \"placement\", \"popperOptions\", \"popperRef\", \"style\", \"transition\", \"slotProps\", \"slots\"];\nimport * as React from 'react';\nimport { chainPropTypes, HTMLElementType, refType, unstable_ownerDocument as ownerDocument, unstable_useEnhancedEffect as useEnhancedEffect, unstable_useForkRef as useForkRef } from '@mui/utils';\nimport { createPopper } from '@popperjs/core';\nimport PropTypes from 'prop-types';\nimport { unstable_composeClasses as composeClasses } from '../composeClasses';\nimport { Portal } from '../Portal';\nimport { getPopperUtilityClass } from './popperClasses';\nimport { useSlotProps } from '../utils';\nimport { useClassNamesOverride } from '../utils/ClassNameConfigurator';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nfunction flipPlacement(placement, direction) {\n if (direction === 'ltr') {\n return placement;\n }\n switch (placement) {\n case 'bottom-end':\n return 'bottom-start';\n case 'bottom-start':\n return 'bottom-end';\n case 'top-end':\n return 'top-start';\n case 'top-start':\n return 'top-end';\n default:\n return placement;\n }\n}\nfunction resolveAnchorEl(anchorEl) {\n return typeof anchorEl === 'function' ? anchorEl() : anchorEl;\n}\nfunction isHTMLElement(element) {\n return element.nodeType !== undefined;\n}\nfunction isVirtualElement(element) {\n return !isHTMLElement(element);\n}\nconst useUtilityClasses = () => {\n const slots = {\n root: ['root']\n };\n return composeClasses(slots, useClassNamesOverride(getPopperUtilityClass));\n};\nconst defaultPopperOptions = {};\nconst PopperTooltip = /*#__PURE__*/React.forwardRef(function PopperTooltip(props, forwardedRef) {\n var _slots$root;\n const {\n anchorEl,\n children,\n direction,\n disablePortal,\n modifiers,\n open,\n placement: initialPlacement,\n popperOptions,\n popperRef: popperRefProp,\n slotProps = {},\n slots = {},\n TransitionProps\n // @ts-ignore internal logic\n // prevent from spreading to DOM, it can come from the parent component e.g. Select.\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const tooltipRef = React.useRef(null);\n const ownRef = useForkRef(tooltipRef, forwardedRef);\n const popperRef = React.useRef(null);\n const handlePopperRef = useForkRef(popperRef, popperRefProp);\n const handlePopperRefRef = React.useRef(handlePopperRef);\n useEnhancedEffect(() => {\n handlePopperRefRef.current = handlePopperRef;\n }, [handlePopperRef]);\n React.useImperativeHandle(popperRefProp, () => popperRef.current, []);\n const rtlPlacement = flipPlacement(initialPlacement, direction);\n /**\n * placement initialized from prop but can change during lifetime if modifiers.flip.\n * modifiers.flip is essentially a flip for controlled/uncontrolled behavior\n */\n const [placement, setPlacement] = React.useState(rtlPlacement);\n const [resolvedAnchorElement, setResolvedAnchorElement] = React.useState(resolveAnchorEl(anchorEl));\n React.useEffect(() => {\n if (popperRef.current) {\n popperRef.current.forceUpdate();\n }\n });\n React.useEffect(() => {\n if (anchorEl) {\n setResolvedAnchorElement(resolveAnchorEl(anchorEl));\n }\n }, [anchorEl]);\n useEnhancedEffect(() => {\n if (!resolvedAnchorElement || !open) {\n return undefined;\n }\n const handlePopperUpdate = data => {\n setPlacement(data.placement);\n };\n if (process.env.NODE_ENV !== 'production') {\n if (resolvedAnchorElement && isHTMLElement(resolvedAnchorElement) && resolvedAnchorElement.nodeType === 1) {\n const box = resolvedAnchorElement.getBoundingClientRect();\n if (process.env.NODE_ENV !== 'test' && box.top === 0 && box.left === 0 && box.right === 0 && box.bottom === 0) {\n console.warn(['MUI: The `anchorEl` prop provided to the component is invalid.', 'The anchor element should be part of the document layout.', \"Make sure the element is present in the document or that it's not display none.\"].join('\\n'));\n }\n }\n }\n let popperModifiers = [{\n name: 'preventOverflow',\n options: {\n altBoundary: disablePortal\n }\n }, {\n name: 'flip',\n options: {\n altBoundary: disablePortal\n }\n }, {\n name: 'onUpdate',\n enabled: true,\n phase: 'afterWrite',\n fn: ({\n state\n }) => {\n handlePopperUpdate(state);\n }\n }];\n if (modifiers != null) {\n popperModifiers = popperModifiers.concat(modifiers);\n }\n if (popperOptions && popperOptions.modifiers != null) {\n popperModifiers = popperModifiers.concat(popperOptions.modifiers);\n }\n const popper = createPopper(resolvedAnchorElement, tooltipRef.current, _extends({\n placement: rtlPlacement\n }, popperOptions, {\n modifiers: popperModifiers\n }));\n handlePopperRefRef.current(popper);\n return () => {\n popper.destroy();\n handlePopperRefRef.current(null);\n };\n }, [resolvedAnchorElement, disablePortal, modifiers, open, popperOptions, rtlPlacement]);\n const childProps = {\n placement: placement\n };\n if (TransitionProps !== null) {\n childProps.TransitionProps = TransitionProps;\n }\n const classes = useUtilityClasses();\n const Root = (_slots$root = slots.root) != null ? _slots$root : 'div';\n const rootProps = useSlotProps({\n elementType: Root,\n externalSlotProps: slotProps.root,\n externalForwardedProps: other,\n additionalProps: {\n role: 'tooltip',\n ref: ownRef\n },\n ownerState: props,\n className: classes.root\n });\n return /*#__PURE__*/_jsx(Root, _extends({}, rootProps, {\n children: typeof children === 'function' ? children(childProps) : children\n }));\n});\n\n/**\n * Poppers rely on the 3rd party library [Popper.js](https://popper.js.org/docs/v2/) for positioning.\n *\n * Demos:\n *\n * - [Popper](https://mui.com/base-ui/react-popper/)\n *\n * API:\n *\n * - [Popper API](https://mui.com/base-ui/react-popper/components-api/#popper)\n */\nconst Popper = /*#__PURE__*/React.forwardRef(function Popper(props, forwardedRef) {\n const {\n anchorEl,\n children,\n container: containerProp,\n direction = 'ltr',\n disablePortal = false,\n keepMounted = false,\n modifiers,\n open,\n placement = 'bottom',\n popperOptions = defaultPopperOptions,\n popperRef,\n style,\n transition = false,\n slotProps = {},\n slots = {}\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded2);\n const [exited, setExited] = React.useState(true);\n const handleEnter = () => {\n setExited(false);\n };\n const handleExited = () => {\n setExited(true);\n };\n if (!keepMounted && !open && (!transition || exited)) {\n return null;\n }\n\n // If the container prop is provided, use that\n // If the anchorEl prop is provided, use its parent body element as the container\n // If neither are provided let the Modal take care of choosing the container\n let container;\n if (containerProp) {\n container = containerProp;\n } else if (anchorEl) {\n const resolvedAnchorEl = resolveAnchorEl(anchorEl);\n container = resolvedAnchorEl && isHTMLElement(resolvedAnchorEl) ? ownerDocument(resolvedAnchorEl).body : ownerDocument(null).body;\n }\n const display = !open && keepMounted && (!transition || exited) ? 'none' : undefined;\n const transitionProps = transition ? {\n in: open,\n onEnter: handleEnter,\n onExited: handleExited\n } : undefined;\n return /*#__PURE__*/_jsx(Portal, {\n disablePortal: disablePortal,\n container: container,\n children: /*#__PURE__*/_jsx(PopperTooltip, _extends({\n anchorEl: anchorEl,\n direction: direction,\n disablePortal: disablePortal,\n modifiers: modifiers,\n ref: forwardedRef,\n open: transition ? !exited : open,\n placement: placement,\n popperOptions: popperOptions,\n popperRef: popperRef,\n slotProps: slotProps,\n slots: slots\n }, other, {\n style: _extends({\n // Prevents scroll issue, waiting for Popper.js to add this style once initiated.\n position: 'fixed',\n // Fix Popper.js display issue\n top: 0,\n left: 0,\n display\n }, style),\n TransitionProps: transitionProps,\n children: children\n }))\n });\n});\nprocess.env.NODE_ENV !== \"production\" ? Popper.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * An HTML element, [virtualElement](https://popper.js.org/docs/v2/virtual-elements/),\n * or a function that returns either.\n * It's used to set the position of the popper.\n * The return value will passed as the reference object of the Popper instance.\n */\n anchorEl: chainPropTypes(PropTypes.oneOfType([HTMLElementType, PropTypes.object, PropTypes.func]), props => {\n if (props.open) {\n const resolvedAnchorEl = resolveAnchorEl(props.anchorEl);\n if (resolvedAnchorEl && isHTMLElement(resolvedAnchorEl) && resolvedAnchorEl.nodeType === 1) {\n const box = resolvedAnchorEl.getBoundingClientRect();\n if (process.env.NODE_ENV !== 'test' && box.top === 0 && box.left === 0 && box.right === 0 && box.bottom === 0) {\n return new Error(['MUI: The `anchorEl` prop provided to the component is invalid.', 'The anchor element should be part of the document layout.', \"Make sure the element is present in the document or that it's not display none.\"].join('\\n'));\n }\n } else if (!resolvedAnchorEl || typeof resolvedAnchorEl.getBoundingClientRect !== 'function' || isVirtualElement(resolvedAnchorEl) && resolvedAnchorEl.contextElement != null && resolvedAnchorEl.contextElement.nodeType !== 1) {\n return new Error(['MUI: The `anchorEl` prop provided to the component is invalid.', 'It should be an HTML element instance or a virtualElement ', '(https://popper.js.org/docs/v2/virtual-elements/).'].join('\\n'));\n }\n }\n return null;\n }),\n /**\n * Popper render function or node.\n */\n children: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.node, PropTypes.func]),\n /**\n * An HTML element or function that returns one.\n * The `container` will have the portal children appended to it.\n *\n * You can also provide a callback, which is called in a React layout effect.\n * This lets you set the container from a ref, and also makes server-side rendering possible.\n *\n * By default, it uses the body of the top-level document object,\n * so it's simply `document.body` most of the time.\n */\n container: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.func]),\n /**\n * Direction of the text.\n * @default 'ltr'\n */\n direction: PropTypes.oneOf(['ltr', 'rtl']),\n /**\n * The `children` will be under the DOM hierarchy of the parent component.\n * @default false\n */\n disablePortal: PropTypes.bool,\n /**\n * Always keep the children in the DOM.\n * This prop can be useful in SEO situation or\n * when you want to maximize the responsiveness of the Popper.\n * @default false\n */\n keepMounted: PropTypes.bool,\n /**\n * Popper.js is based on a \"plugin-like\" architecture,\n * most of its features are fully encapsulated \"modifiers\".\n *\n * A modifier is a function that is called each time Popper.js needs to\n * compute the position of the popper.\n * For this reason, modifiers should be very performant to avoid bottlenecks.\n * To learn how to create a modifier, [read the modifiers documentation](https://popper.js.org/docs/v2/modifiers/).\n */\n modifiers: PropTypes.arrayOf(PropTypes.shape({\n data: PropTypes.object,\n effect: PropTypes.func,\n enabled: PropTypes.bool,\n fn: PropTypes.func,\n name: PropTypes.any,\n options: PropTypes.object,\n phase: PropTypes.oneOf(['afterMain', 'afterRead', 'afterWrite', 'beforeMain', 'beforeRead', 'beforeWrite', 'main', 'read', 'write']),\n requires: PropTypes.arrayOf(PropTypes.string),\n requiresIfExists: PropTypes.arrayOf(PropTypes.string)\n })),\n /**\n * If `true`, the component is shown.\n */\n open: PropTypes.bool.isRequired,\n /**\n * Popper placement.\n * @default 'bottom'\n */\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n /**\n * Options provided to the [`Popper.js`](https://popper.js.org/docs/v2/constructors/#options) instance.\n * @default {}\n */\n popperOptions: PropTypes.shape({\n modifiers: PropTypes.array,\n onFirstUpdate: PropTypes.func,\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n strategy: PropTypes.oneOf(['absolute', 'fixed'])\n }),\n /**\n * A ref that points to the used popper instance.\n */\n popperRef: refType,\n /**\n * The props used for each slot inside the Popper.\n * @default {}\n */\n slotProps: PropTypes.shape({\n root: PropTypes.oneOfType([PropTypes.func, PropTypes.object])\n }),\n /**\n * The components used for each slot inside the Popper.\n * Either a string to use a HTML element or a component.\n * @default {}\n */\n slots: PropTypes.shape({\n root: PropTypes.elementType\n }),\n /**\n * Help supporting a react-transition-group/Transition component.\n * @default false\n */\n transition: PropTypes.bool\n} : void 0;\nexport { Popper };","'use client';\n\nimport * as React from 'react';\nimport { useTheme as useThemeSystem } from '@mui/system';\nimport defaultTheme from './defaultTheme';\nimport THEME_ID from './identifier';\nexport default function useTheme() {\n const theme = useThemeSystem(defaultTheme);\n if (process.env.NODE_ENV !== 'production') {\n // eslint-disable-next-line react-hooks/rules-of-hooks\n React.useDebugValue(theme);\n }\n return theme[THEME_ID] || theme;\n}","export default function _setPrototypeOf(o, p) {\n _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function _setPrototypeOf(o, p) {\n o.__proto__ = p;\n return o;\n };\n return _setPrototypeOf(o, p);\n}","import setPrototypeOf from \"./setPrototypeOf.js\";\nexport default function _inheritsLoose(subClass, superClass) {\n subClass.prototype = Object.create(superClass.prototype);\n subClass.prototype.constructor = subClass;\n setPrototypeOf(subClass, superClass);\n}","export default {\n disabled: false\n};","import PropTypes from 'prop-types';\nexport var timeoutsShape = process.env.NODE_ENV !== 'production' ? PropTypes.oneOfType([PropTypes.number, PropTypes.shape({\n enter: PropTypes.number,\n exit: PropTypes.number,\n appear: PropTypes.number\n}).isRequired]) : null;\nexport var classNamesShape = process.env.NODE_ENV !== 'production' ? PropTypes.oneOfType([PropTypes.string, PropTypes.shape({\n enter: PropTypes.string,\n exit: PropTypes.string,\n active: PropTypes.string\n}), PropTypes.shape({\n enter: PropTypes.string,\n enterDone: PropTypes.string,\n enterActive: PropTypes.string,\n exit: PropTypes.string,\n exitDone: PropTypes.string,\n exitActive: PropTypes.string\n})]) : null;","import React from 'react';\nexport default React.createContext(null);","export var forceReflow = function forceReflow(node) {\n return node.scrollTop;\n};","import _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _inheritsLoose from \"@babel/runtime/helpers/esm/inheritsLoose\";\nimport PropTypes from 'prop-types';\nimport React from 'react';\nimport ReactDOM from 'react-dom';\nimport config from './config';\nimport { timeoutsShape } from './utils/PropTypes';\nimport TransitionGroupContext from './TransitionGroupContext';\nimport { forceReflow } from './utils/reflow';\nexport var UNMOUNTED = 'unmounted';\nexport var EXITED = 'exited';\nexport var ENTERING = 'entering';\nexport var ENTERED = 'entered';\nexport var EXITING = 'exiting';\n/**\n * The Transition component lets you describe a transition from one component\n * state to another _over time_ with a simple declarative API. Most commonly\n * it's used to animate the mounting and unmounting of a component, but can also\n * be used to describe in-place transition states as well.\n *\n * ---\n *\n * **Note**: `Transition` is a platform-agnostic base component. If you're using\n * transitions in CSS, you'll probably want to use\n * [`CSSTransition`](https://reactcommunity.org/react-transition-group/css-transition)\n * instead. It inherits all the features of `Transition`, but contains\n * additional features necessary to play nice with CSS transitions (hence the\n * name of the component).\n *\n * ---\n *\n * By default the `Transition` component does not alter the behavior of the\n * component it renders, it only tracks \"enter\" and \"exit\" states for the\n * components. It's up to you to give meaning and effect to those states. For\n * example we can add styles to a component when it enters or exits:\n *\n * ```jsx\n * import { Transition } from 'react-transition-group';\n *\n * const duration = 300;\n *\n * const defaultStyle = {\n * transition: `opacity ${duration}ms ease-in-out`,\n * opacity: 0,\n * }\n *\n * const transitionStyles = {\n * entering: { opacity: 1 },\n * entered: { opacity: 1 },\n * exiting: { opacity: 0 },\n * exited: { opacity: 0 },\n * };\n *\n * const Fade = ({ in: inProp }) => (\n * \n * {state => (\n *
    \n * I'm a fade Transition!\n *
    \n * )}\n *
    \n * );\n * ```\n *\n * There are 4 main states a Transition can be in:\n * - `'entering'`\n * - `'entered'`\n * - `'exiting'`\n * - `'exited'`\n *\n * Transition state is toggled via the `in` prop. When `true` the component\n * begins the \"Enter\" stage. During this stage, the component will shift from\n * its current transition state, to `'entering'` for the duration of the\n * transition and then to the `'entered'` stage once it's complete. Let's take\n * the following example (we'll use the\n * [useState](https://reactjs.org/docs/hooks-reference.html#usestate) hook):\n *\n * ```jsx\n * function App() {\n * const [inProp, setInProp] = useState(false);\n * return (\n *
    \n * \n * {state => (\n * // ...\n * )}\n * \n * \n *
    \n * );\n * }\n * ```\n *\n * When the button is clicked the component will shift to the `'entering'` state\n * and stay there for 500ms (the value of `timeout`) before it finally switches\n * to `'entered'`.\n *\n * When `in` is `false` the same thing happens except the state moves from\n * `'exiting'` to `'exited'`.\n */\n\nvar Transition = /*#__PURE__*/function (_React$Component) {\n _inheritsLoose(Transition, _React$Component);\n\n function Transition(props, context) {\n var _this;\n\n _this = _React$Component.call(this, props, context) || this;\n var parentGroup = context; // In the context of a TransitionGroup all enters are really appears\n\n var appear = parentGroup && !parentGroup.isMounting ? props.enter : props.appear;\n var initialStatus;\n _this.appearStatus = null;\n\n if (props.in) {\n if (appear) {\n initialStatus = EXITED;\n _this.appearStatus = ENTERING;\n } else {\n initialStatus = ENTERED;\n }\n } else {\n if (props.unmountOnExit || props.mountOnEnter) {\n initialStatus = UNMOUNTED;\n } else {\n initialStatus = EXITED;\n }\n }\n\n _this.state = {\n status: initialStatus\n };\n _this.nextCallback = null;\n return _this;\n }\n\n Transition.getDerivedStateFromProps = function getDerivedStateFromProps(_ref, prevState) {\n var nextIn = _ref.in;\n\n if (nextIn && prevState.status === UNMOUNTED) {\n return {\n status: EXITED\n };\n }\n\n return null;\n } // getSnapshotBeforeUpdate(prevProps) {\n // let nextStatus = null\n // if (prevProps !== this.props) {\n // const { status } = this.state\n // if (this.props.in) {\n // if (status !== ENTERING && status !== ENTERED) {\n // nextStatus = ENTERING\n // }\n // } else {\n // if (status === ENTERING || status === ENTERED) {\n // nextStatus = EXITING\n // }\n // }\n // }\n // return { nextStatus }\n // }\n ;\n\n var _proto = Transition.prototype;\n\n _proto.componentDidMount = function componentDidMount() {\n this.updateStatus(true, this.appearStatus);\n };\n\n _proto.componentDidUpdate = function componentDidUpdate(prevProps) {\n var nextStatus = null;\n\n if (prevProps !== this.props) {\n var status = this.state.status;\n\n if (this.props.in) {\n if (status !== ENTERING && status !== ENTERED) {\n nextStatus = ENTERING;\n }\n } else {\n if (status === ENTERING || status === ENTERED) {\n nextStatus = EXITING;\n }\n }\n }\n\n this.updateStatus(false, nextStatus);\n };\n\n _proto.componentWillUnmount = function componentWillUnmount() {\n this.cancelNextCallback();\n };\n\n _proto.getTimeouts = function getTimeouts() {\n var timeout = this.props.timeout;\n var exit, enter, appear;\n exit = enter = appear = timeout;\n\n if (timeout != null && typeof timeout !== 'number') {\n exit = timeout.exit;\n enter = timeout.enter; // TODO: remove fallback for next major\n\n appear = timeout.appear !== undefined ? timeout.appear : enter;\n }\n\n return {\n exit: exit,\n enter: enter,\n appear: appear\n };\n };\n\n _proto.updateStatus = function updateStatus(mounting, nextStatus) {\n if (mounting === void 0) {\n mounting = false;\n }\n\n if (nextStatus !== null) {\n // nextStatus will always be ENTERING or EXITING.\n this.cancelNextCallback();\n\n if (nextStatus === ENTERING) {\n if (this.props.unmountOnExit || this.props.mountOnEnter) {\n var node = this.props.nodeRef ? this.props.nodeRef.current : ReactDOM.findDOMNode(this); // https://github.com/reactjs/react-transition-group/pull/749\n // With unmountOnExit or mountOnEnter, the enter animation should happen at the transition between `exited` and `entering`.\n // To make the animation happen, we have to separate each rendering and avoid being processed as batched.\n\n if (node) forceReflow(node);\n }\n\n this.performEnter(mounting);\n } else {\n this.performExit();\n }\n } else if (this.props.unmountOnExit && this.state.status === EXITED) {\n this.setState({\n status: UNMOUNTED\n });\n }\n };\n\n _proto.performEnter = function performEnter(mounting) {\n var _this2 = this;\n\n var enter = this.props.enter;\n var appearing = this.context ? this.context.isMounting : mounting;\n\n var _ref2 = this.props.nodeRef ? [appearing] : [ReactDOM.findDOMNode(this), appearing],\n maybeNode = _ref2[0],\n maybeAppearing = _ref2[1];\n\n var timeouts = this.getTimeouts();\n var enterTimeout = appearing ? timeouts.appear : timeouts.enter; // no enter animation skip right to ENTERED\n // if we are mounting and running this it means appear _must_ be set\n\n if (!mounting && !enter || config.disabled) {\n this.safeSetState({\n status: ENTERED\n }, function () {\n _this2.props.onEntered(maybeNode);\n });\n return;\n }\n\n this.props.onEnter(maybeNode, maybeAppearing);\n this.safeSetState({\n status: ENTERING\n }, function () {\n _this2.props.onEntering(maybeNode, maybeAppearing);\n\n _this2.onTransitionEnd(enterTimeout, function () {\n _this2.safeSetState({\n status: ENTERED\n }, function () {\n _this2.props.onEntered(maybeNode, maybeAppearing);\n });\n });\n });\n };\n\n _proto.performExit = function performExit() {\n var _this3 = this;\n\n var exit = this.props.exit;\n var timeouts = this.getTimeouts();\n var maybeNode = this.props.nodeRef ? undefined : ReactDOM.findDOMNode(this); // no exit animation skip right to EXITED\n\n if (!exit || config.disabled) {\n this.safeSetState({\n status: EXITED\n }, function () {\n _this3.props.onExited(maybeNode);\n });\n return;\n }\n\n this.props.onExit(maybeNode);\n this.safeSetState({\n status: EXITING\n }, function () {\n _this3.props.onExiting(maybeNode);\n\n _this3.onTransitionEnd(timeouts.exit, function () {\n _this3.safeSetState({\n status: EXITED\n }, function () {\n _this3.props.onExited(maybeNode);\n });\n });\n });\n };\n\n _proto.cancelNextCallback = function cancelNextCallback() {\n if (this.nextCallback !== null) {\n this.nextCallback.cancel();\n this.nextCallback = null;\n }\n };\n\n _proto.safeSetState = function safeSetState(nextState, callback) {\n // This shouldn't be necessary, but there are weird race conditions with\n // setState callbacks and unmounting in testing, so always make sure that\n // we can cancel any pending setState callbacks after we unmount.\n callback = this.setNextCallback(callback);\n this.setState(nextState, callback);\n };\n\n _proto.setNextCallback = function setNextCallback(callback) {\n var _this4 = this;\n\n var active = true;\n\n this.nextCallback = function (event) {\n if (active) {\n active = false;\n _this4.nextCallback = null;\n callback(event);\n }\n };\n\n this.nextCallback.cancel = function () {\n active = false;\n };\n\n return this.nextCallback;\n };\n\n _proto.onTransitionEnd = function onTransitionEnd(timeout, handler) {\n this.setNextCallback(handler);\n var node = this.props.nodeRef ? this.props.nodeRef.current : ReactDOM.findDOMNode(this);\n var doesNotHaveTimeoutOrListener = timeout == null && !this.props.addEndListener;\n\n if (!node || doesNotHaveTimeoutOrListener) {\n setTimeout(this.nextCallback, 0);\n return;\n }\n\n if (this.props.addEndListener) {\n var _ref3 = this.props.nodeRef ? [this.nextCallback] : [node, this.nextCallback],\n maybeNode = _ref3[0],\n maybeNextCallback = _ref3[1];\n\n this.props.addEndListener(maybeNode, maybeNextCallback);\n }\n\n if (timeout != null) {\n setTimeout(this.nextCallback, timeout);\n }\n };\n\n _proto.render = function render() {\n var status = this.state.status;\n\n if (status === UNMOUNTED) {\n return null;\n }\n\n var _this$props = this.props,\n children = _this$props.children,\n _in = _this$props.in,\n _mountOnEnter = _this$props.mountOnEnter,\n _unmountOnExit = _this$props.unmountOnExit,\n _appear = _this$props.appear,\n _enter = _this$props.enter,\n _exit = _this$props.exit,\n _timeout = _this$props.timeout,\n _addEndListener = _this$props.addEndListener,\n _onEnter = _this$props.onEnter,\n _onEntering = _this$props.onEntering,\n _onEntered = _this$props.onEntered,\n _onExit = _this$props.onExit,\n _onExiting = _this$props.onExiting,\n _onExited = _this$props.onExited,\n _nodeRef = _this$props.nodeRef,\n childProps = _objectWithoutPropertiesLoose(_this$props, [\"children\", \"in\", \"mountOnEnter\", \"unmountOnExit\", \"appear\", \"enter\", \"exit\", \"timeout\", \"addEndListener\", \"onEnter\", \"onEntering\", \"onEntered\", \"onExit\", \"onExiting\", \"onExited\", \"nodeRef\"]);\n\n return (\n /*#__PURE__*/\n // allows for nested Transitions\n React.createElement(TransitionGroupContext.Provider, {\n value: null\n }, typeof children === 'function' ? children(status, childProps) : React.cloneElement(React.Children.only(children), childProps))\n );\n };\n\n return Transition;\n}(React.Component);\n\nTransition.contextType = TransitionGroupContext;\nTransition.propTypes = process.env.NODE_ENV !== \"production\" ? {\n /**\n * A React reference to DOM element that need to transition:\n * https://stackoverflow.com/a/51127130/4671932\n *\n * - When `nodeRef` prop is used, `node` is not passed to callback functions\n * (e.g. `onEnter`) because user already has direct access to the node.\n * - When changing `key` prop of `Transition` in a `TransitionGroup` a new\n * `nodeRef` need to be provided to `Transition` with changed `key` prop\n * (see\n * [test/CSSTransition-test.js](https://github.com/reactjs/react-transition-group/blob/13435f897b3ab71f6e19d724f145596f5910581c/test/CSSTransition-test.js#L362-L437)).\n */\n nodeRef: PropTypes.shape({\n current: typeof Element === 'undefined' ? PropTypes.any : function (propValue, key, componentName, location, propFullName, secret) {\n var value = propValue[key];\n return PropTypes.instanceOf(value && 'ownerDocument' in value ? value.ownerDocument.defaultView.Element : Element)(propValue, key, componentName, location, propFullName, secret);\n }\n }),\n\n /**\n * A `function` child can be used instead of a React element. This function is\n * called with the current transition status (`'entering'`, `'entered'`,\n * `'exiting'`, `'exited'`), which can be used to apply context\n * specific props to a component.\n *\n * ```jsx\n * \n * {state => (\n * \n * )}\n * \n * ```\n */\n children: PropTypes.oneOfType([PropTypes.func.isRequired, PropTypes.element.isRequired]).isRequired,\n\n /**\n * Show the component; triggers the enter or exit states\n */\n in: PropTypes.bool,\n\n /**\n * By default the child component is mounted immediately along with\n * the parent `Transition` component. If you want to \"lazy mount\" the component on the\n * first `in={true}` you can set `mountOnEnter`. After the first enter transition the component will stay\n * mounted, even on \"exited\", unless you also specify `unmountOnExit`.\n */\n mountOnEnter: PropTypes.bool,\n\n /**\n * By default the child component stays mounted after it reaches the `'exited'` state.\n * Set `unmountOnExit` if you'd prefer to unmount the component after it finishes exiting.\n */\n unmountOnExit: PropTypes.bool,\n\n /**\n * By default the child component does not perform the enter transition when\n * it first mounts, regardless of the value of `in`. If you want this\n * behavior, set both `appear` and `in` to `true`.\n *\n * > **Note**: there are no special appear states like `appearing`/`appeared`, this prop\n * > only adds an additional enter transition. However, in the\n * > `` component that first enter transition does result in\n * > additional `.appear-*` classes, that way you can choose to style it\n * > differently.\n */\n appear: PropTypes.bool,\n\n /**\n * Enable or disable enter transitions.\n */\n enter: PropTypes.bool,\n\n /**\n * Enable or disable exit transitions.\n */\n exit: PropTypes.bool,\n\n /**\n * The duration of the transition, in milliseconds.\n * Required unless `addEndListener` is provided.\n *\n * You may specify a single timeout for all transitions:\n *\n * ```jsx\n * timeout={500}\n * ```\n *\n * or individually:\n *\n * ```jsx\n * timeout={{\n * appear: 500,\n * enter: 300,\n * exit: 500,\n * }}\n * ```\n *\n * - `appear` defaults to the value of `enter`\n * - `enter` defaults to `0`\n * - `exit` defaults to `0`\n *\n * @type {number | { enter?: number, exit?: number, appear?: number }}\n */\n timeout: function timeout(props) {\n var pt = timeoutsShape;\n if (!props.addEndListener) pt = pt.isRequired;\n\n for (var _len = arguments.length, args = new Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) {\n args[_key - 1] = arguments[_key];\n }\n\n return pt.apply(void 0, [props].concat(args));\n },\n\n /**\n * Add a custom transition end trigger. Called with the transitioning\n * DOM node and a `done` callback. Allows for more fine grained transition end\n * logic. Timeouts are still used as a fallback if provided.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * ```jsx\n * addEndListener={(node, done) => {\n * // use the css transitionend event to mark the finish of a transition\n * node.addEventListener('transitionend', done, false);\n * }}\n * ```\n */\n addEndListener: PropTypes.func,\n\n /**\n * Callback fired before the \"entering\" status is applied. An extra parameter\n * `isAppearing` is supplied to indicate if the enter stage is occurring on the initial mount\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement, isAppearing: bool) -> void\n */\n onEnter: PropTypes.func,\n\n /**\n * Callback fired after the \"entering\" status is applied. An extra parameter\n * `isAppearing` is supplied to indicate if the enter stage is occurring on the initial mount\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement, isAppearing: bool)\n */\n onEntering: PropTypes.func,\n\n /**\n * Callback fired after the \"entered\" status is applied. An extra parameter\n * `isAppearing` is supplied to indicate if the enter stage is occurring on the initial mount\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement, isAppearing: bool) -> void\n */\n onEntered: PropTypes.func,\n\n /**\n * Callback fired before the \"exiting\" status is applied.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement) -> void\n */\n onExit: PropTypes.func,\n\n /**\n * Callback fired after the \"exiting\" status is applied.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement) -> void\n */\n onExiting: PropTypes.func,\n\n /**\n * Callback fired after the \"exited\" status is applied.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed\n *\n * @type Function(node: HtmlElement) -> void\n */\n onExited: PropTypes.func\n} : {}; // Name the function so it is clearer in the documentation\n\nfunction noop() {}\n\nTransition.defaultProps = {\n in: false,\n mountOnEnter: false,\n unmountOnExit: false,\n appear: false,\n enter: true,\n exit: true,\n onEnter: noop,\n onEntering: noop,\n onEntered: noop,\n onExit: noop,\n onExiting: noop,\n onExited: noop\n};\nTransition.UNMOUNTED = UNMOUNTED;\nTransition.EXITED = EXITED;\nTransition.ENTERING = ENTERING;\nTransition.ENTERED = ENTERED;\nTransition.EXITING = EXITING;\nexport default Transition;","export const reflow = node => node.scrollTop;\nexport function getTransitionProps(props, options) {\n var _style$transitionDura, _style$transitionTimi;\n const {\n timeout,\n easing,\n style = {}\n } = props;\n return {\n duration: (_style$transitionDura = style.transitionDuration) != null ? _style$transitionDura : typeof timeout === 'number' ? timeout : timeout[options.mode] || 0,\n easing: (_style$transitionTimi = style.transitionTimingFunction) != null ? _style$transitionTimi : typeof easing === 'object' ? easing[options.mode] : easing,\n delay: style.transitionDelay\n };\n}","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"addEndListener\", \"appear\", \"children\", \"easing\", \"in\", \"onEnter\", \"onEntered\", \"onEntering\", \"onExit\", \"onExited\", \"onExiting\", \"style\", \"timeout\", \"TransitionComponent\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport { elementAcceptingRef, unstable_useTimeout as useTimeout } from '@mui/utils';\nimport { Transition } from 'react-transition-group';\nimport useTheme from '../styles/useTheme';\nimport { getTransitionProps, reflow } from '../transitions/utils';\nimport useForkRef from '../utils/useForkRef';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nfunction getScale(value) {\n return `scale(${value}, ${value ** 2})`;\n}\nconst styles = {\n entering: {\n opacity: 1,\n transform: getScale(1)\n },\n entered: {\n opacity: 1,\n transform: 'none'\n }\n};\n\n/*\n TODO v6: remove\n Conditionally apply a workaround for the CSS transition bug in Safari 15.4 / WebKit browsers.\n */\nconst isWebKit154 = typeof navigator !== 'undefined' && /^((?!chrome|android).)*(safari|mobile)/i.test(navigator.userAgent) && /(os |version\\/)15(.|_)4/i.test(navigator.userAgent);\n\n/**\n * The Grow transition is used by the [Tooltip](/material-ui/react-tooltip/) and\n * [Popover](/material-ui/react-popover/) components.\n * It uses [react-transition-group](https://github.com/reactjs/react-transition-group) internally.\n */\nconst Grow = /*#__PURE__*/React.forwardRef(function Grow(props, ref) {\n const {\n addEndListener,\n appear = true,\n children,\n easing,\n in: inProp,\n onEnter,\n onEntered,\n onEntering,\n onExit,\n onExited,\n onExiting,\n style,\n timeout = 'auto',\n // eslint-disable-next-line react/prop-types\n TransitionComponent = Transition\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const timer = useTimeout();\n const autoTimeout = React.useRef();\n const theme = useTheme();\n const nodeRef = React.useRef(null);\n const handleRef = useForkRef(nodeRef, children.ref, ref);\n const normalizedTransitionCallback = callback => maybeIsAppearing => {\n if (callback) {\n const node = nodeRef.current;\n\n // onEnterXxx and onExitXxx callbacks have a different arguments.length value.\n if (maybeIsAppearing === undefined) {\n callback(node);\n } else {\n callback(node, maybeIsAppearing);\n }\n }\n };\n const handleEntering = normalizedTransitionCallback(onEntering);\n const handleEnter = normalizedTransitionCallback((node, isAppearing) => {\n reflow(node); // So the animation always start from the start.\n\n const {\n duration: transitionDuration,\n delay,\n easing: transitionTimingFunction\n } = getTransitionProps({\n style,\n timeout,\n easing\n }, {\n mode: 'enter'\n });\n let duration;\n if (timeout === 'auto') {\n duration = theme.transitions.getAutoHeightDuration(node.clientHeight);\n autoTimeout.current = duration;\n } else {\n duration = transitionDuration;\n }\n node.style.transition = [theme.transitions.create('opacity', {\n duration,\n delay\n }), theme.transitions.create('transform', {\n duration: isWebKit154 ? duration : duration * 0.666,\n delay,\n easing: transitionTimingFunction\n })].join(',');\n if (onEnter) {\n onEnter(node, isAppearing);\n }\n });\n const handleEntered = normalizedTransitionCallback(onEntered);\n const handleExiting = normalizedTransitionCallback(onExiting);\n const handleExit = normalizedTransitionCallback(node => {\n const {\n duration: transitionDuration,\n delay,\n easing: transitionTimingFunction\n } = getTransitionProps({\n style,\n timeout,\n easing\n }, {\n mode: 'exit'\n });\n let duration;\n if (timeout === 'auto') {\n duration = theme.transitions.getAutoHeightDuration(node.clientHeight);\n autoTimeout.current = duration;\n } else {\n duration = transitionDuration;\n }\n node.style.transition = [theme.transitions.create('opacity', {\n duration,\n delay\n }), theme.transitions.create('transform', {\n duration: isWebKit154 ? duration : duration * 0.666,\n delay: isWebKit154 ? delay : delay || duration * 0.333,\n easing: transitionTimingFunction\n })].join(',');\n node.style.opacity = 0;\n node.style.transform = getScale(0.75);\n if (onExit) {\n onExit(node);\n }\n });\n const handleExited = normalizedTransitionCallback(onExited);\n const handleAddEndListener = next => {\n if (timeout === 'auto') {\n timer.start(autoTimeout.current || 0, next);\n }\n if (addEndListener) {\n // Old call signature before `react-transition-group` implemented `nodeRef`\n addEndListener(nodeRef.current, next);\n }\n };\n return /*#__PURE__*/_jsx(TransitionComponent, _extends({\n appear: appear,\n in: inProp,\n nodeRef: nodeRef,\n onEnter: handleEnter,\n onEntered: handleEntered,\n onEntering: handleEntering,\n onExit: handleExit,\n onExited: handleExited,\n onExiting: handleExiting,\n addEndListener: handleAddEndListener,\n timeout: timeout === 'auto' ? null : timeout\n }, other, {\n children: (state, childProps) => {\n return /*#__PURE__*/React.cloneElement(children, _extends({\n style: _extends({\n opacity: 0,\n transform: getScale(0.75),\n visibility: state === 'exited' && !inProp ? 'hidden' : undefined\n }, styles[state], style, children.props.style),\n ref: handleRef\n }, childProps));\n }\n }));\n});\nprocess.env.NODE_ENV !== \"production\" ? Grow.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the d.ts file and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * Add a custom transition end trigger. Called with the transitioning DOM\n * node and a done callback. Allows for more fine grained transition end\n * logic. Note: Timeouts are still used as a fallback if provided.\n */\n addEndListener: PropTypes.func,\n /**\n * Perform the enter transition when it first mounts if `in` is also `true`.\n * Set this to `false` to disable this behavior.\n * @default true\n */\n appear: PropTypes.bool,\n /**\n * A single child content element.\n */\n children: elementAcceptingRef.isRequired,\n /**\n * The transition timing function.\n * You may specify a single easing or a object containing enter and exit values.\n */\n easing: PropTypes.oneOfType([PropTypes.shape({\n enter: PropTypes.string,\n exit: PropTypes.string\n }), PropTypes.string]),\n /**\n * If `true`, the component will transition in.\n */\n in: PropTypes.bool,\n /**\n * @ignore\n */\n onEnter: PropTypes.func,\n /**\n * @ignore\n */\n onEntered: PropTypes.func,\n /**\n * @ignore\n */\n onEntering: PropTypes.func,\n /**\n * @ignore\n */\n onExit: PropTypes.func,\n /**\n * @ignore\n */\n onExited: PropTypes.func,\n /**\n * @ignore\n */\n onExiting: PropTypes.func,\n /**\n * @ignore\n */\n style: PropTypes.object,\n /**\n * The duration for the transition, in milliseconds.\n * You may specify a single timeout for all transitions, or individually with an object.\n *\n * Set to 'auto' to automatically calculate transition time based on height.\n * @default 'auto'\n */\n timeout: PropTypes.oneOfType([PropTypes.oneOf(['auto']), PropTypes.number, PropTypes.shape({\n appear: PropTypes.number,\n enter: PropTypes.number,\n exit: PropTypes.number\n })])\n} : void 0;\nGrow.muiSupportAuto = true;\nexport default Grow;","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"anchorEl\", \"component\", \"components\", \"componentsProps\", \"container\", \"disablePortal\", \"keepMounted\", \"modifiers\", \"open\", \"placement\", \"popperOptions\", \"popperRef\", \"transition\", \"slots\", \"slotProps\"];\nimport { Popper as BasePopper } from '@mui/base/Popper';\nimport { useThemeWithoutDefault as useTheme } from '@mui/system';\nimport { HTMLElementType, refType } from '@mui/utils';\nimport PropTypes from 'prop-types';\nimport * as React from 'react';\nimport { styled, useThemeProps } from '../styles';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nconst PopperRoot = styled(BasePopper, {\n name: 'MuiPopper',\n slot: 'Root',\n overridesResolver: (props, styles) => styles.root\n})({});\n\n/**\n *\n * Demos:\n *\n * - [Autocomplete](https://mui.com/material-ui/react-autocomplete/)\n * - [Menu](https://mui.com/material-ui/react-menu/)\n * - [Popper](https://mui.com/material-ui/react-popper/)\n *\n * API:\n *\n * - [Popper API](https://mui.com/material-ui/api/popper/)\n */\nconst Popper = /*#__PURE__*/React.forwardRef(function Popper(inProps, ref) {\n var _slots$root;\n const theme = useTheme();\n const props = useThemeProps({\n props: inProps,\n name: 'MuiPopper'\n });\n const {\n anchorEl,\n component,\n components,\n componentsProps,\n container,\n disablePortal,\n keepMounted,\n modifiers,\n open,\n placement,\n popperOptions,\n popperRef,\n transition,\n slots,\n slotProps\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const RootComponent = (_slots$root = slots == null ? void 0 : slots.root) != null ? _slots$root : components == null ? void 0 : components.Root;\n const otherProps = _extends({\n anchorEl,\n container,\n disablePortal,\n keepMounted,\n modifiers,\n open,\n placement,\n popperOptions,\n popperRef,\n transition\n }, other);\n return /*#__PURE__*/_jsx(PopperRoot, _extends({\n as: component,\n direction: theme == null ? void 0 : theme.direction,\n slots: {\n root: RootComponent\n },\n slotProps: slotProps != null ? slotProps : componentsProps\n }, otherProps, {\n ref: ref\n }));\n});\nprocess.env.NODE_ENV !== \"production\" ? Popper.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * An HTML element, [virtualElement](https://popper.js.org/docs/v2/virtual-elements/),\n * or a function that returns either.\n * It's used to set the position of the popper.\n * The return value will passed as the reference object of the Popper instance.\n */\n anchorEl: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.object, PropTypes.func]),\n /**\n * Popper render function or node.\n */\n children: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.node, PropTypes.func]),\n /**\n * The component used for the root node.\n * Either a string to use a HTML element or a component.\n */\n component: PropTypes.elementType,\n /**\n * The components used for each slot inside the Popper.\n * Either a string to use a HTML element or a component.\n * @default {}\n */\n components: PropTypes.shape({\n Root: PropTypes.elementType\n }),\n /**\n * The props used for each slot inside the Popper.\n * @default {}\n */\n componentsProps: PropTypes.shape({\n root: PropTypes.oneOfType([PropTypes.func, PropTypes.object])\n }),\n /**\n * An HTML element or function that returns one.\n * The `container` will have the portal children appended to it.\n *\n * You can also provide a callback, which is called in a React layout effect.\n * This lets you set the container from a ref, and also makes server-side rendering possible.\n *\n * By default, it uses the body of the top-level document object,\n * so it's simply `document.body` most of the time.\n */\n container: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.func]),\n /**\n * The `children` will be under the DOM hierarchy of the parent component.\n * @default false\n */\n disablePortal: PropTypes.bool,\n /**\n * Always keep the children in the DOM.\n * This prop can be useful in SEO situation or\n * when you want to maximize the responsiveness of the Popper.\n * @default false\n */\n keepMounted: PropTypes.bool,\n /**\n * Popper.js is based on a \"plugin-like\" architecture,\n * most of its features are fully encapsulated \"modifiers\".\n *\n * A modifier is a function that is called each time Popper.js needs to\n * compute the position of the popper.\n * For this reason, modifiers should be very performant to avoid bottlenecks.\n * To learn how to create a modifier, [read the modifiers documentation](https://popper.js.org/docs/v2/modifiers/).\n */\n modifiers: PropTypes.arrayOf(PropTypes.shape({\n data: PropTypes.object,\n effect: PropTypes.func,\n enabled: PropTypes.bool,\n fn: PropTypes.func,\n name: PropTypes.any,\n options: PropTypes.object,\n phase: PropTypes.oneOf(['afterMain', 'afterRead', 'afterWrite', 'beforeMain', 'beforeRead', 'beforeWrite', 'main', 'read', 'write']),\n requires: PropTypes.arrayOf(PropTypes.string),\n requiresIfExists: PropTypes.arrayOf(PropTypes.string)\n })),\n /**\n * If `true`, the component is shown.\n */\n open: PropTypes.bool.isRequired,\n /**\n * Popper placement.\n * @default 'bottom'\n */\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n /**\n * Options provided to the [`Popper.js`](https://popper.js.org/docs/v2/constructors/#options) instance.\n * @default {}\n */\n popperOptions: PropTypes.shape({\n modifiers: PropTypes.array,\n onFirstUpdate: PropTypes.func,\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n strategy: PropTypes.oneOf(['absolute', 'fixed'])\n }),\n /**\n * A ref that points to the used popper instance.\n */\n popperRef: refType,\n /**\n * The props used for each slot inside the Popper.\n * @default {}\n */\n slotProps: PropTypes.shape({\n root: PropTypes.oneOfType([PropTypes.func, PropTypes.object])\n }),\n /**\n * The components used for each slot inside the Popper.\n * Either a string to use a HTML element or a component.\n * @default {}\n */\n slots: PropTypes.shape({\n root: PropTypes.elementType\n }),\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Help supporting a react-transition-group/Transition component.\n * @default false\n */\n transition: PropTypes.bool\n} : void 0;\nexport default Popper;","import generateUtilityClasses from '@mui/utils/generateUtilityClasses';\nimport generateUtilityClass from '@mui/utils/generateUtilityClass';\nexport function getTooltipUtilityClass(slot) {\n return generateUtilityClass('MuiTooltip', slot);\n}\nconst tooltipClasses = generateUtilityClasses('MuiTooltip', ['popper', 'popperInteractive', 'popperArrow', 'popperClose', 'tooltip', 'tooltipArrow', 'touch', 'tooltipPlacementLeft', 'tooltipPlacementRight', 'tooltipPlacementTop', 'tooltipPlacementBottom', 'arrow']);\nexport default tooltipClasses;","'use client';\n\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nconst _excluded = [\"arrow\", \"children\", \"classes\", \"components\", \"componentsProps\", \"describeChild\", \"disableFocusListener\", \"disableHoverListener\", \"disableInteractive\", \"disableTouchListener\", \"enterDelay\", \"enterNextDelay\", \"enterTouchDelay\", \"followCursor\", \"id\", \"leaveDelay\", \"leaveTouchDelay\", \"onClose\", \"onOpen\", \"open\", \"placement\", \"PopperComponent\", \"PopperProps\", \"slotProps\", \"slots\", \"title\", \"TransitionComponent\", \"TransitionProps\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport clsx from 'clsx';\nimport { elementAcceptingRef, unstable_useTimeout as useTimeout, unstable_Timeout as Timeout } from '@mui/utils';\nimport { unstable_composeClasses as composeClasses, appendOwnerState } from '@mui/base';\nimport { alpha } from '@mui/system';\nimport styled from '../styles/styled';\nimport useTheme from '../styles/useTheme';\nimport useThemeProps from '../styles/useThemeProps';\nimport capitalize from '../utils/capitalize';\nimport Grow from '../Grow';\nimport Popper from '../Popper';\nimport useEventCallback from '../utils/useEventCallback';\nimport useForkRef from '../utils/useForkRef';\nimport useId from '../utils/useId';\nimport useIsFocusVisible from '../utils/useIsFocusVisible';\nimport useControlled from '../utils/useControlled';\nimport tooltipClasses, { getTooltipUtilityClass } from './tooltipClasses';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nimport { jsxs as _jsxs } from \"react/jsx-runtime\";\nfunction round(value) {\n return Math.round(value * 1e5) / 1e5;\n}\nconst useUtilityClasses = ownerState => {\n const {\n classes,\n disableInteractive,\n arrow,\n touch,\n placement\n } = ownerState;\n const slots = {\n popper: ['popper', !disableInteractive && 'popperInteractive', arrow && 'popperArrow'],\n tooltip: ['tooltip', arrow && 'tooltipArrow', touch && 'touch', `tooltipPlacement${capitalize(placement.split('-')[0])}`],\n arrow: ['arrow']\n };\n return composeClasses(slots, getTooltipUtilityClass, classes);\n};\nconst TooltipPopper = styled(Popper, {\n name: 'MuiTooltip',\n slot: 'Popper',\n overridesResolver: (props, styles) => {\n const {\n ownerState\n } = props;\n return [styles.popper, !ownerState.disableInteractive && styles.popperInteractive, ownerState.arrow && styles.popperArrow, !ownerState.open && styles.popperClose];\n }\n})(({\n theme,\n ownerState,\n open\n}) => _extends({\n zIndex: (theme.vars || theme).zIndex.tooltip,\n pointerEvents: 'none'\n}, !ownerState.disableInteractive && {\n pointerEvents: 'auto'\n}, !open && {\n pointerEvents: 'none'\n}, ownerState.arrow && {\n [`&[data-popper-placement*=\"bottom\"] .${tooltipClasses.arrow}`]: {\n top: 0,\n marginTop: '-0.71em',\n '&::before': {\n transformOrigin: '0 100%'\n }\n },\n [`&[data-popper-placement*=\"top\"] .${tooltipClasses.arrow}`]: {\n bottom: 0,\n marginBottom: '-0.71em',\n '&::before': {\n transformOrigin: '100% 0'\n }\n },\n [`&[data-popper-placement*=\"right\"] .${tooltipClasses.arrow}`]: _extends({}, !ownerState.isRtl ? {\n left: 0,\n marginLeft: '-0.71em'\n } : {\n right: 0,\n marginRight: '-0.71em'\n }, {\n height: '1em',\n width: '0.71em',\n '&::before': {\n transformOrigin: '100% 100%'\n }\n }),\n [`&[data-popper-placement*=\"left\"] .${tooltipClasses.arrow}`]: _extends({}, !ownerState.isRtl ? {\n right: 0,\n marginRight: '-0.71em'\n } : {\n left: 0,\n marginLeft: '-0.71em'\n }, {\n height: '1em',\n width: '0.71em',\n '&::before': {\n transformOrigin: '0 0'\n }\n })\n}));\nconst TooltipTooltip = styled('div', {\n name: 'MuiTooltip',\n slot: 'Tooltip',\n overridesResolver: (props, styles) => {\n const {\n ownerState\n } = props;\n return [styles.tooltip, ownerState.touch && styles.touch, ownerState.arrow && styles.tooltipArrow, styles[`tooltipPlacement${capitalize(ownerState.placement.split('-')[0])}`]];\n }\n})(({\n theme,\n ownerState\n}) => _extends({\n backgroundColor: theme.vars ? theme.vars.palette.Tooltip.bg : alpha(theme.palette.grey[700], 0.92),\n borderRadius: (theme.vars || theme).shape.borderRadius,\n color: (theme.vars || theme).palette.common.white,\n fontFamily: theme.typography.fontFamily,\n padding: '4px 8px',\n fontSize: theme.typography.pxToRem(11),\n maxWidth: 300,\n margin: 2,\n wordWrap: 'break-word',\n fontWeight: theme.typography.fontWeightMedium\n}, ownerState.arrow && {\n position: 'relative',\n margin: 0\n}, ownerState.touch && {\n padding: '8px 16px',\n fontSize: theme.typography.pxToRem(14),\n lineHeight: `${round(16 / 14)}em`,\n fontWeight: theme.typography.fontWeightRegular\n}, {\n [`.${tooltipClasses.popper}[data-popper-placement*=\"left\"] &`]: _extends({\n transformOrigin: 'right center'\n }, !ownerState.isRtl ? _extends({\n marginRight: '14px'\n }, ownerState.touch && {\n marginRight: '24px'\n }) : _extends({\n marginLeft: '14px'\n }, ownerState.touch && {\n marginLeft: '24px'\n })),\n [`.${tooltipClasses.popper}[data-popper-placement*=\"right\"] &`]: _extends({\n transformOrigin: 'left center'\n }, !ownerState.isRtl ? _extends({\n marginLeft: '14px'\n }, ownerState.touch && {\n marginLeft: '24px'\n }) : _extends({\n marginRight: '14px'\n }, ownerState.touch && {\n marginRight: '24px'\n })),\n [`.${tooltipClasses.popper}[data-popper-placement*=\"top\"] &`]: _extends({\n transformOrigin: 'center bottom',\n marginBottom: '14px'\n }, ownerState.touch && {\n marginBottom: '24px'\n }),\n [`.${tooltipClasses.popper}[data-popper-placement*=\"bottom\"] &`]: _extends({\n transformOrigin: 'center top',\n marginTop: '14px'\n }, ownerState.touch && {\n marginTop: '24px'\n })\n}));\nconst TooltipArrow = styled('span', {\n name: 'MuiTooltip',\n slot: 'Arrow',\n overridesResolver: (props, styles) => styles.arrow\n})(({\n theme\n}) => ({\n overflow: 'hidden',\n position: 'absolute',\n width: '1em',\n height: '0.71em' /* = width / sqrt(2) = (length of the hypotenuse) */,\n boxSizing: 'border-box',\n color: theme.vars ? theme.vars.palette.Tooltip.bg : alpha(theme.palette.grey[700], 0.9),\n '&::before': {\n content: '\"\"',\n margin: 'auto',\n display: 'block',\n width: '100%',\n height: '100%',\n backgroundColor: 'currentColor',\n transform: 'rotate(45deg)'\n }\n}));\nlet hystersisOpen = false;\nconst hystersisTimer = new Timeout();\nlet cursorPosition = {\n x: 0,\n y: 0\n};\nexport function testReset() {\n hystersisOpen = false;\n hystersisTimer.clear();\n}\nfunction composeEventHandler(handler, eventHandler) {\n return event => {\n if (eventHandler) {\n eventHandler(event);\n }\n handler(event);\n };\n}\n\n// TODO v6: Remove PopperComponent, PopperProps, TransitionComponent and TransitionProps.\nconst Tooltip = /*#__PURE__*/React.forwardRef(function Tooltip(inProps, ref) {\n var _ref, _slots$popper, _ref2, _ref3, _slots$transition, _ref4, _slots$tooltip, _ref5, _slots$arrow, _slotProps$popper, _ref6, _slotProps$popper2, _slotProps$transition, _slotProps$tooltip, _ref7, _slotProps$tooltip2, _slotProps$arrow, _ref8, _slotProps$arrow2;\n const props = useThemeProps({\n props: inProps,\n name: 'MuiTooltip'\n });\n const {\n arrow = false,\n children: childrenProp,\n components = {},\n componentsProps = {},\n describeChild = false,\n disableFocusListener = false,\n disableHoverListener = false,\n disableInteractive: disableInteractiveProp = false,\n disableTouchListener = false,\n enterDelay = 100,\n enterNextDelay = 0,\n enterTouchDelay = 700,\n followCursor = false,\n id: idProp,\n leaveDelay = 0,\n leaveTouchDelay = 1500,\n onClose,\n onOpen,\n open: openProp,\n placement = 'bottom',\n PopperComponent: PopperComponentProp,\n PopperProps = {},\n slotProps = {},\n slots = {},\n title,\n TransitionComponent: TransitionComponentProp = Grow,\n TransitionProps\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n\n // to prevent runtime errors, developers will need to provide a child as a React element anyway.\n const children = /*#__PURE__*/React.isValidElement(childrenProp) ? childrenProp : /*#__PURE__*/_jsx(\"span\", {\n children: childrenProp\n });\n const theme = useTheme();\n const isRtl = theme.direction === 'rtl';\n const [childNode, setChildNode] = React.useState();\n const [arrowRef, setArrowRef] = React.useState(null);\n const ignoreNonTouchEvents = React.useRef(false);\n const disableInteractive = disableInteractiveProp || followCursor;\n const closeTimer = useTimeout();\n const enterTimer = useTimeout();\n const leaveTimer = useTimeout();\n const touchTimer = useTimeout();\n const [openState, setOpenState] = useControlled({\n controlled: openProp,\n default: false,\n name: 'Tooltip',\n state: 'open'\n });\n let open = openState;\n if (process.env.NODE_ENV !== 'production') {\n // eslint-disable-next-line react-hooks/rules-of-hooks\n const {\n current: isControlled\n } = React.useRef(openProp !== undefined);\n\n // eslint-disable-next-line react-hooks/rules-of-hooks\n React.useEffect(() => {\n if (childNode && childNode.disabled && !isControlled && title !== '' && childNode.tagName.toLowerCase() === 'button') {\n console.error(['MUI: You are providing a disabled `button` child to the Tooltip component.', 'A disabled element does not fire events.', \"Tooltip needs to listen to the child element's events to display the title.\", '', 'Add a simple wrapper element, such as a `span`.'].join('\\n'));\n }\n }, [title, childNode, isControlled]);\n }\n const id = useId(idProp);\n const prevUserSelect = React.useRef();\n const stopTouchInteraction = useEventCallback(() => {\n if (prevUserSelect.current !== undefined) {\n document.body.style.WebkitUserSelect = prevUserSelect.current;\n prevUserSelect.current = undefined;\n }\n touchTimer.clear();\n });\n React.useEffect(() => stopTouchInteraction, [stopTouchInteraction]);\n const handleOpen = event => {\n hystersisTimer.clear();\n hystersisOpen = true;\n\n // The mouseover event will trigger for every nested element in the tooltip.\n // We can skip rerendering when the tooltip is already open.\n // We are using the mouseover event instead of the mouseenter event to fix a hide/show issue.\n setOpenState(true);\n if (onOpen && !open) {\n onOpen(event);\n }\n };\n const handleClose = useEventCallback(\n /**\n * @param {React.SyntheticEvent | Event} event\n */\n event => {\n hystersisTimer.start(800 + leaveDelay, () => {\n hystersisOpen = false;\n });\n setOpenState(false);\n if (onClose && open) {\n onClose(event);\n }\n closeTimer.start(theme.transitions.duration.shortest, () => {\n ignoreNonTouchEvents.current = false;\n });\n });\n const handleEnter = event => {\n if (ignoreNonTouchEvents.current && event.type !== 'touchstart') {\n return;\n }\n\n // Remove the title ahead of time.\n // We don't want to wait for the next render commit.\n // We would risk displaying two tooltips at the same time (native + this one).\n if (childNode) {\n childNode.removeAttribute('title');\n }\n enterTimer.clear();\n leaveTimer.clear();\n if (enterDelay || hystersisOpen && enterNextDelay) {\n enterTimer.start(hystersisOpen ? enterNextDelay : enterDelay, () => {\n handleOpen(event);\n });\n } else {\n handleOpen(event);\n }\n };\n const handleLeave = event => {\n enterTimer.clear();\n leaveTimer.start(leaveDelay, () => {\n handleClose(event);\n });\n };\n const {\n isFocusVisibleRef,\n onBlur: handleBlurVisible,\n onFocus: handleFocusVisible,\n ref: focusVisibleRef\n } = useIsFocusVisible();\n // We don't necessarily care about the focusVisible state (which is safe to access via ref anyway).\n // We just need to re-render the Tooltip if the focus-visible state changes.\n const [, setChildIsFocusVisible] = React.useState(false);\n const handleBlur = event => {\n handleBlurVisible(event);\n if (isFocusVisibleRef.current === false) {\n setChildIsFocusVisible(false);\n handleLeave(event);\n }\n };\n const handleFocus = event => {\n // Workaround for https://github.com/facebook/react/issues/7769\n // The autoFocus of React might trigger the event before the componentDidMount.\n // We need to account for this eventuality.\n if (!childNode) {\n setChildNode(event.currentTarget);\n }\n handleFocusVisible(event);\n if (isFocusVisibleRef.current === true) {\n setChildIsFocusVisible(true);\n handleEnter(event);\n }\n };\n const detectTouchStart = event => {\n ignoreNonTouchEvents.current = true;\n const childrenProps = children.props;\n if (childrenProps.onTouchStart) {\n childrenProps.onTouchStart(event);\n }\n };\n const handleMouseOver = handleEnter;\n const handleMouseLeave = handleLeave;\n const handleTouchStart = event => {\n detectTouchStart(event);\n leaveTimer.clear();\n closeTimer.clear();\n stopTouchInteraction();\n prevUserSelect.current = document.body.style.WebkitUserSelect;\n // Prevent iOS text selection on long-tap.\n document.body.style.WebkitUserSelect = 'none';\n touchTimer.start(enterTouchDelay, () => {\n document.body.style.WebkitUserSelect = prevUserSelect.current;\n handleEnter(event);\n });\n };\n const handleTouchEnd = event => {\n if (children.props.onTouchEnd) {\n children.props.onTouchEnd(event);\n }\n stopTouchInteraction();\n leaveTimer.start(leaveTouchDelay, () => {\n handleClose(event);\n });\n };\n React.useEffect(() => {\n if (!open) {\n return undefined;\n }\n\n /**\n * @param {KeyboardEvent} nativeEvent\n */\n function handleKeyDown(nativeEvent) {\n // IE11, Edge (prior to using Bink?) use 'Esc'\n if (nativeEvent.key === 'Escape' || nativeEvent.key === 'Esc') {\n handleClose(nativeEvent);\n }\n }\n document.addEventListener('keydown', handleKeyDown);\n return () => {\n document.removeEventListener('keydown', handleKeyDown);\n };\n }, [handleClose, open]);\n const handleRef = useForkRef(children.ref, focusVisibleRef, setChildNode, ref);\n\n // There is no point in displaying an empty tooltip.\n // So we exclude all falsy values, except 0, which is valid.\n if (!title && title !== 0) {\n open = false;\n }\n const popperRef = React.useRef();\n const handleMouseMove = event => {\n const childrenProps = children.props;\n if (childrenProps.onMouseMove) {\n childrenProps.onMouseMove(event);\n }\n cursorPosition = {\n x: event.clientX,\n y: event.clientY\n };\n if (popperRef.current) {\n popperRef.current.update();\n }\n };\n const nameOrDescProps = {};\n const titleIsString = typeof title === 'string';\n if (describeChild) {\n nameOrDescProps.title = !open && titleIsString && !disableHoverListener ? title : null;\n nameOrDescProps['aria-describedby'] = open ? id : null;\n } else {\n nameOrDescProps['aria-label'] = titleIsString ? title : null;\n nameOrDescProps['aria-labelledby'] = open && !titleIsString ? id : null;\n }\n const childrenProps = _extends({}, nameOrDescProps, other, children.props, {\n className: clsx(other.className, children.props.className),\n onTouchStart: detectTouchStart,\n ref: handleRef\n }, followCursor ? {\n onMouseMove: handleMouseMove\n } : {});\n if (process.env.NODE_ENV !== 'production') {\n childrenProps['data-mui-internal-clone-element'] = true;\n\n // eslint-disable-next-line react-hooks/rules-of-hooks\n React.useEffect(() => {\n if (childNode && !childNode.getAttribute('data-mui-internal-clone-element')) {\n console.error(['MUI: The `children` component of the Tooltip is not forwarding its props correctly.', 'Please make sure that props are spread on the same element that the ref is applied to.'].join('\\n'));\n }\n }, [childNode]);\n }\n const interactiveWrapperListeners = {};\n if (!disableTouchListener) {\n childrenProps.onTouchStart = handleTouchStart;\n childrenProps.onTouchEnd = handleTouchEnd;\n }\n if (!disableHoverListener) {\n childrenProps.onMouseOver = composeEventHandler(handleMouseOver, childrenProps.onMouseOver);\n childrenProps.onMouseLeave = composeEventHandler(handleMouseLeave, childrenProps.onMouseLeave);\n if (!disableInteractive) {\n interactiveWrapperListeners.onMouseOver = handleMouseOver;\n interactiveWrapperListeners.onMouseLeave = handleMouseLeave;\n }\n }\n if (!disableFocusListener) {\n childrenProps.onFocus = composeEventHandler(handleFocus, childrenProps.onFocus);\n childrenProps.onBlur = composeEventHandler(handleBlur, childrenProps.onBlur);\n if (!disableInteractive) {\n interactiveWrapperListeners.onFocus = handleFocus;\n interactiveWrapperListeners.onBlur = handleBlur;\n }\n }\n if (process.env.NODE_ENV !== 'production') {\n if (children.props.title) {\n console.error(['MUI: You have provided a `title` prop to the child of .', `Remove this title prop \\`${children.props.title}\\` or the Tooltip component.`].join('\\n'));\n }\n }\n const popperOptions = React.useMemo(() => {\n var _PopperProps$popperOp;\n let tooltipModifiers = [{\n name: 'arrow',\n enabled: Boolean(arrowRef),\n options: {\n element: arrowRef,\n padding: 4\n }\n }];\n if ((_PopperProps$popperOp = PopperProps.popperOptions) != null && _PopperProps$popperOp.modifiers) {\n tooltipModifiers = tooltipModifiers.concat(PopperProps.popperOptions.modifiers);\n }\n return _extends({}, PopperProps.popperOptions, {\n modifiers: tooltipModifiers\n });\n }, [arrowRef, PopperProps]);\n const ownerState = _extends({}, props, {\n isRtl,\n arrow,\n disableInteractive,\n placement,\n PopperComponentProp,\n touch: ignoreNonTouchEvents.current\n });\n const classes = useUtilityClasses(ownerState);\n const PopperComponent = (_ref = (_slots$popper = slots.popper) != null ? _slots$popper : components.Popper) != null ? _ref : TooltipPopper;\n const TransitionComponent = (_ref2 = (_ref3 = (_slots$transition = slots.transition) != null ? _slots$transition : components.Transition) != null ? _ref3 : TransitionComponentProp) != null ? _ref2 : Grow;\n const TooltipComponent = (_ref4 = (_slots$tooltip = slots.tooltip) != null ? _slots$tooltip : components.Tooltip) != null ? _ref4 : TooltipTooltip;\n const ArrowComponent = (_ref5 = (_slots$arrow = slots.arrow) != null ? _slots$arrow : components.Arrow) != null ? _ref5 : TooltipArrow;\n const popperProps = appendOwnerState(PopperComponent, _extends({}, PopperProps, (_slotProps$popper = slotProps.popper) != null ? _slotProps$popper : componentsProps.popper, {\n className: clsx(classes.popper, PopperProps == null ? void 0 : PopperProps.className, (_ref6 = (_slotProps$popper2 = slotProps.popper) != null ? _slotProps$popper2 : componentsProps.popper) == null ? void 0 : _ref6.className)\n }), ownerState);\n const transitionProps = appendOwnerState(TransitionComponent, _extends({}, TransitionProps, (_slotProps$transition = slotProps.transition) != null ? _slotProps$transition : componentsProps.transition), ownerState);\n const tooltipProps = appendOwnerState(TooltipComponent, _extends({}, (_slotProps$tooltip = slotProps.tooltip) != null ? _slotProps$tooltip : componentsProps.tooltip, {\n className: clsx(classes.tooltip, (_ref7 = (_slotProps$tooltip2 = slotProps.tooltip) != null ? _slotProps$tooltip2 : componentsProps.tooltip) == null ? void 0 : _ref7.className)\n }), ownerState);\n const tooltipArrowProps = appendOwnerState(ArrowComponent, _extends({}, (_slotProps$arrow = slotProps.arrow) != null ? _slotProps$arrow : componentsProps.arrow, {\n className: clsx(classes.arrow, (_ref8 = (_slotProps$arrow2 = slotProps.arrow) != null ? _slotProps$arrow2 : componentsProps.arrow) == null ? void 0 : _ref8.className)\n }), ownerState);\n return /*#__PURE__*/_jsxs(React.Fragment, {\n children: [/*#__PURE__*/React.cloneElement(children, childrenProps), /*#__PURE__*/_jsx(PopperComponent, _extends({\n as: PopperComponentProp != null ? PopperComponentProp : Popper,\n placement: placement,\n anchorEl: followCursor ? {\n getBoundingClientRect: () => ({\n top: cursorPosition.y,\n left: cursorPosition.x,\n right: cursorPosition.x,\n bottom: cursorPosition.y,\n width: 0,\n height: 0\n })\n } : childNode,\n popperRef: popperRef,\n open: childNode ? open : false,\n id: id,\n transition: true\n }, interactiveWrapperListeners, popperProps, {\n popperOptions: popperOptions,\n children: ({\n TransitionProps: TransitionPropsInner\n }) => /*#__PURE__*/_jsx(TransitionComponent, _extends({\n timeout: theme.transitions.duration.shorter\n }, TransitionPropsInner, transitionProps, {\n children: /*#__PURE__*/_jsxs(TooltipComponent, _extends({}, tooltipProps, {\n children: [title, arrow ? /*#__PURE__*/_jsx(ArrowComponent, _extends({}, tooltipArrowProps, {\n ref: setArrowRef\n })) : null]\n }))\n }))\n }))]\n });\n});\nprocess.env.NODE_ENV !== \"production\" ? Tooltip.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the d.ts file and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * If `true`, adds an arrow to the tooltip.\n * @default false\n */\n arrow: PropTypes.bool,\n /**\n * Tooltip reference element.\n */\n children: elementAcceptingRef.isRequired,\n /**\n * Override or extend the styles applied to the component.\n */\n classes: PropTypes.object,\n /**\n * @ignore\n */\n className: PropTypes.string,\n /**\n * The components used for each slot inside.\n *\n * This prop is an alias for the `slots` prop.\n * It's recommended to use the `slots` prop instead.\n *\n * @default {}\n */\n components: PropTypes.shape({\n Arrow: PropTypes.elementType,\n Popper: PropTypes.elementType,\n Tooltip: PropTypes.elementType,\n Transition: PropTypes.elementType\n }),\n /**\n * The extra props for the slot components.\n * You can override the existing props or add new ones.\n *\n * This prop is an alias for the `slotProps` prop.\n * It's recommended to use the `slotProps` prop instead, as `componentsProps` will be deprecated in the future.\n *\n * @default {}\n */\n componentsProps: PropTypes.shape({\n arrow: PropTypes.object,\n popper: PropTypes.object,\n tooltip: PropTypes.object,\n transition: PropTypes.object\n }),\n /**\n * Set to `true` if the `title` acts as an accessible description.\n * By default the `title` acts as an accessible label for the child.\n * @default false\n */\n describeChild: PropTypes.bool,\n /**\n * Do not respond to focus-visible events.\n * @default false\n */\n disableFocusListener: PropTypes.bool,\n /**\n * Do not respond to hover events.\n * @default false\n */\n disableHoverListener: PropTypes.bool,\n /**\n * Makes a tooltip not interactive, i.e. it will close when the user\n * hovers over the tooltip before the `leaveDelay` is expired.\n * @default false\n */\n disableInteractive: PropTypes.bool,\n /**\n * Do not respond to long press touch events.\n * @default false\n */\n disableTouchListener: PropTypes.bool,\n /**\n * The number of milliseconds to wait before showing the tooltip.\n * This prop won't impact the enter touch delay (`enterTouchDelay`).\n * @default 100\n */\n enterDelay: PropTypes.number,\n /**\n * The number of milliseconds to wait before showing the tooltip when one was already recently opened.\n * @default 0\n */\n enterNextDelay: PropTypes.number,\n /**\n * The number of milliseconds a user must touch the element before showing the tooltip.\n * @default 700\n */\n enterTouchDelay: PropTypes.number,\n /**\n * If `true`, the tooltip follow the cursor over the wrapped element.\n * @default false\n */\n followCursor: PropTypes.bool,\n /**\n * This prop is used to help implement the accessibility logic.\n * If you don't provide this prop. It falls back to a randomly generated id.\n */\n id: PropTypes.string,\n /**\n * The number of milliseconds to wait before hiding the tooltip.\n * This prop won't impact the leave touch delay (`leaveTouchDelay`).\n * @default 0\n */\n leaveDelay: PropTypes.number,\n /**\n * The number of milliseconds after the user stops touching an element before hiding the tooltip.\n * @default 1500\n */\n leaveTouchDelay: PropTypes.number,\n /**\n * Callback fired when the component requests to be closed.\n *\n * @param {React.SyntheticEvent} event The event source of the callback.\n */\n onClose: PropTypes.func,\n /**\n * Callback fired when the component requests to be open.\n *\n * @param {React.SyntheticEvent} event The event source of the callback.\n */\n onOpen: PropTypes.func,\n /**\n * If `true`, the component is shown.\n */\n open: PropTypes.bool,\n /**\n * Tooltip placement.\n * @default 'bottom'\n */\n placement: PropTypes.oneOf(['bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n /**\n * The component used for the popper.\n * @default Popper\n */\n PopperComponent: PropTypes.elementType,\n /**\n * Props applied to the [`Popper`](/material-ui/api/popper/) element.\n * @default {}\n */\n PopperProps: PropTypes.object,\n /**\n * The extra props for the slot components.\n * You can override the existing props or add new ones.\n *\n * This prop is an alias for the `componentsProps` prop, which will be deprecated in the future.\n *\n * @default {}\n */\n slotProps: PropTypes.shape({\n arrow: PropTypes.object,\n popper: PropTypes.object,\n tooltip: PropTypes.object,\n transition: PropTypes.object\n }),\n /**\n * The components used for each slot inside.\n *\n * This prop is an alias for the `components` prop, which will be deprecated in the future.\n *\n * @default {}\n */\n slots: PropTypes.shape({\n arrow: PropTypes.elementType,\n popper: PropTypes.elementType,\n tooltip: PropTypes.elementType,\n transition: PropTypes.elementType\n }),\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Tooltip title. Zero-length titles string, undefined, null and false are never displayed.\n */\n title: PropTypes.node,\n /**\n * The component used for the transition.\n * [Follow this guide](/material-ui/transitions/#transitioncomponent-prop) to learn more about the requirements for this component.\n * @default Grow\n */\n TransitionComponent: PropTypes.elementType,\n /**\n * Props applied to the transition element.\n * By default, the element is based on this [`Transition`](http://reactcommunity.org/react-transition-group/transition/) component.\n */\n TransitionProps: PropTypes.object\n} : void 0;\nexport default Tooltip;","import '@/components/mui/menu-item.component.css';\nimport ArrowRightIcon from '@mui/icons-material/ArrowRight';\nimport {\n ListItemIcon as MuiListItemIcon,\n ListItemText as MuiListItemText,\n MenuItem as MuiMenuItem,\n} from '@mui/material';\nimport Tooltip from '@mui/material/Tooltip';\nimport { Localized, ReferencedItem, SingleColumnMenu } from 'platform-bible-utils';\nimport { MouseEvent, PropsWithChildren } from 'react';\n\ntype MenuItemInfoBase = {\n /** Text (displayable in the UI) as the name of the menu item */\n label: string;\n /** Text to display when the mouse hovers over the menu item */\n tooltip?: string;\n};\n\nexport type Command = MenuItemInfoBase & {\n /** Command to execute (string.string) */\n command: string;\n};\n\ntype SubMenu = MenuItemInfoBase & {\n /** Command to execute (string.string) */\n items: MenuItemInfo[];\n};\n\nexport interface CommandHandler {\n (command: Command): void;\n}\n\nexport type MenuPropsBase = {\n /*\n * The JSON defining the menu whose items are to be rendered. This will typically be one of the\n * menus in the \"defs\" in a Platform.Bible menu (see PlatformMenus). The schema for this is\n * menuDocumentSchema (at the end of menus.model.ts). Note that while this is a\n * \"SingleColumnMenu\", somewhat bizarrely, a MultiColumnMenu is a SingleColumnMenu, so it really\n * could be a MultiColumnMenu, in which case, column had better be defined so it can be used\n * to filter out the actual groups and items to display on the column.\n */\n menuDefinition: Localized;\n\n commandHandler: CommandHandler;\n\n /**\n * Additional action to perform when any menu item is clicked. Allows the caller to handle event\n * (e.g., to close the menu).\n */\n onClick?: (event: MouseEvent) => void;\n};\n\nexport type MenuItemListProps = MenuPropsBase & {\n /** Optional unique (column) identifier */\n columnId?: ReferencedItem;\n};\n\nexport type MenuItemProps = Omit &\n PropsWithChildren<{\n /** Optional unique identifier */\n id?: string;\n\n onClick: (event: MouseEvent) => void;\n }>;\n\ntype MenuItemInfo = (Command | SubMenu) & {\n /**\n * If specified, menu item will be inset if it does not have a leading icon.\n *\n * @default true\n */\n allowForLeadingIcons?: boolean;\n /**\n * If specified, the path to the icon image to display on the leading side of the menu text.\n *\n * @default undefined (no leading icon will be shown)\n */\n iconPathBefore?: string;\n /**\n * If specified, the path to the icon image to display on the trailing side of the menu text.\n *\n * @default undefined (no trailing icon will be shown)\n */\n iconPathAfter?: string;\n /**\n * If true, list item is focused during the first mount\n *\n * @default false\n */\n hasAutoFocus?: boolean;\n\n /** Additional css classes to help with unique styling of the menu item */\n className?: string;\n\n /**\n * If true, the menu item will appear disabled and it will not respond to clicks or mouse hovers.\n *\n * @default false\n */\n isDisabled?: boolean;\n\n /**\n * If true, compact vertical padding designed for keyboard and mouse input is used.\n *\n * @default true\n */\n isDense?: boolean;\n\n /**\n * If true, a right-arrow icon will be displayed (iconPathAfter, if specified, will be ignored).\n *\n * @default false\n */\n isSubMenuParent?: boolean;\n\n /**\n * If true, the left and right padding is removed\n *\n * @default false\n */\n hasDisabledGutters?: boolean;\n\n /**\n * If true, a 1px light border is added to bottom of menu item\n *\n * @default false\n */\n hasDivider?: boolean;\n\n /** Help identify which element has keyboard focus */\n focusVisibleClassName?: string;\n\n /** If it's a submenu, it should have the items property */\n items?: MenuItemInfo[];\n};\n\nfunction getIcon(icon: string | undefined, menuLabel: string, leading: boolean) {\n return icon ? (\n \n {`${leading\n \n ) : undefined;\n}\n\nexport default function MenuItem(props: MenuItemProps) {\n const {\n onClick,\n label,\n tooltip,\n allowForLeadingIcons = true,\n iconPathBefore = undefined,\n iconPathAfter = undefined,\n hasAutoFocus = false,\n className,\n isDisabled = false,\n isDense = true,\n isSubMenuParent = false,\n hasDisabledGutters = false,\n hasDivider = false,\n focusVisibleClassName,\n id,\n children,\n } = props;\n\n const menuItem = (\n \n {label ? (\n <>\n {getIcon(iconPathBefore, label, true)}\n \n {isSubMenuParent ? (\n \n \n \n ) : (\n getIcon(iconPathAfter, label, false)\n )}\n \n ) : (\n children\n )}\n \n );\n\n return tooltip ? (\n \n
    {menuItem}
    \n
    \n ) : (\n menuItem\n );\n}\n","import MenuItem, {\n MenuItemListProps,\n MenuItemProps,\n MenuPropsBase,\n} from '@/components/mui/menu-item.component';\nimport { Menu } from '@mui/material';\nimport {\n Localized,\n MenuGroupDetailsInSubMenu,\n MenuItemContainingCommand,\n MenuItemContainingSubmenu,\n OrderedExtensibleContainer,\n ReferencedItem,\n SingleColumnMenu,\n} from 'platform-bible-utils';\nimport { MouseEvent, useMemo, useState } from 'react';\n\n/**\n * All the exported types in this file should be regarded as \"internal\" (i.e., they should not be\n * exposed via index.ts).\n */\n\nexport type GroupedMenuPropsBase = MenuPropsBase & {\n /** Optional unique (column) identifier */\n columnId?: ReferencedItem;\n};\n\nexport type GroupedMenuItemListProps = MenuItemListProps & {\n /**\n * If the menuDefinition includes \"top-level\" groups (i.e., those that belong to a column as\n * opposed to those that belong to a submenu) that should not be included in the list, then this\n * array specifies which groups to include. Likewise, for a submenu, this list indicates which\n * groups are pertinent for that submenu. So then for a context menu this property need not be\n * specified since it is a top-level menu based on a \"true\" SingleColumnMenu (i.e., one that is\n * not a MultiColumnMenu).\n */\n includedGroups?: {\n id: string;\n group: Localized;\n }[];\n};\n\ninterface ItemInfo {\n item: Localized;\n isLastItemInGroup: boolean;\n}\n\ntype SubMenuProps = MenuPropsBase & {\n parentMenuItem: Localized;\n parentItemProps: Omit, 'iconPathAfter'>;\n};\n\nfunction getAllGroups(menuDefinition: Localized) {\n const groupEntries = Object.entries(menuDefinition.groups);\n // Convert array of entries to array of objects with id and group properties\n return groupEntries.map(([key, value]) => ({ id: key, group: value }));\n}\n\nfunction SubMenu(props: SubMenuProps) {\n const [anchorEl, setAnchorEl] = useState(undefined);\n\n const { parentMenuItem, parentItemProps, menuDefinition } = props;\n\n const handleParentMenuItemClick = (event: MouseEvent) => {\n setAnchorEl(event.currentTarget);\n };\n\n const handleClose = () => {\n setAnchorEl(undefined);\n };\n\n const renderSubMenuItems = () => {\n let includedGroups = getAllGroups(menuDefinition).filter((g) => 'menuItem' in g.group);\n\n // Ensure valid parent menu was provided. (If not, submenu will contain all groups!)\n if (!parentMenuItem?.id) throw new Error('A valid parent menu item is required for submenus.');\n\n // When laying out a submenu, only include groups associated with the provided parent menu.\n // Note: without the (annoying) redundant check that the included groups\n // have the menuItem field, TS doesn't think it exists.\n includedGroups = includedGroups.filter(\n (group) => 'menuItem' in group.group && group.group.menuItem === parentMenuItem.id,\n );\n\n return ;\n };\n\n return (\n <>\n \n \n {renderSubMenuItems()}\n \n \n );\n}\n\nconst getOrderedGroupItems = (\n groupId: string,\n allItems: Localized[],\n) => {\n // Filter items that belong to the specified group\n const itemsForGroup = allItems.filter((item) => item.group === groupId);\n // Sort items based on order\n const sortedItems = itemsForGroup.sort((a, b) => (a.order || 0) - (b.order || 0));\n return sortedItems;\n};\n\n/**\n * This component is internal; it does not need to be exposed to the outside world since it is not\n * useful on its own. It is used to generate and lay out the MenuItems that appear either on a\n * top-level menu (in a GridMenu or ContextMenu) or in a submenu.\n */\nexport default function GroupedMenuItemList(menuProps: GroupedMenuItemListProps) {\n const { menuDefinition, onClick, commandHandler, includedGroups } = menuProps;\n\n const { items, allowForLeadingIcons } = useMemo(() => {\n const groupsToInclude =\n includedGroups && includedGroups.length > 0\n ? includedGroups\n : // We're apparently laying out a single-column menu (presumably a context menu). In this\n // case, all groups should be included except ones that belong to a submenu.\n getAllGroups(menuDefinition).filter((g) => !('menuItem' in g.group));\n\n const sortedGroups = Object.values(groupsToInclude).sort(\n (a, b) => (a.group.order || 0) - (b.group.order || 0),\n );\n\n const itemArray: ItemInfo[] = [];\n\n sortedGroups.forEach((group) => {\n getOrderedGroupItems(group.id, menuDefinition.items).forEach((item) =>\n itemArray.push({ item, isLastItemInGroup: false }),\n );\n if (itemArray.length > 0) itemArray[itemArray.length - 1].isLastItemInGroup = true;\n });\n\n // No divider after last item in final group.\n if (itemArray.length > 0) itemArray[itemArray.length - 1].isLastItemInGroup = false;\n\n const allowSpaceForLeadingIcons = itemArray.some(\n (i) => 'iconPathBefore' in i.item && i.item.iconPathBefore,\n );\n\n return { items: itemArray, allowForLeadingIcons: allowSpaceForLeadingIcons };\n }, [includedGroups, menuDefinition]);\n\n // Create props for MenuItem component including setting hasDivider for the last item in a group\n const createMenuItemProps = ({ item, isLastItemInGroup }: ItemInfo) => {\n const menuItemProps = {\n className: 'papi-menu-item',\n label: item.label,\n tooltip: item.tooltip,\n iconPathBefore: 'iconPathBefore' in item ? item.iconPathBefore : undefined,\n iconPathAfter: 'iconPathAfter' in item ? item.iconPathAfter : undefined,\n hasDivider: isLastItemInGroup, // Set hasDivider to true for the last item in a group\n allowForLeadingIcons,\n };\n\n return menuItemProps;\n };\n\n const [firstItem] = items;\n\n if (!firstItem) return
    ;\n\n const divKey = firstItem.item.group;\n\n return (\n
    \n {items.map((itemInfo, index) => {\n const { item } = itemInfo;\n const menuItemProps = createMenuItemProps(itemInfo);\n if ('command' in item) {\n const key = item.group + index;\n return (\n ) => {\n onClick?.(event);\n commandHandler(item);\n }}\n {...menuItemProps}\n />\n );\n }\n return (\n \n );\n })}\n
    \n );\n}\n","import GroupedMenuItemList from '@/components/mui/grouped-menu-item-list.component';\nimport { MenuItemListProps } from '@/components/mui/menu-item.component';\nimport { MultiColumnMenu } from 'platform-bible-utils';\n\n/**\n * This component is internal; it does not need to be exposed to the outside world since it is not\n * useful on its own. Use either GridMenu or ContextMenu.\n */\nexport default function TopLevelMenu(props: MenuItemListProps) {\n const { menuDefinition, columnId } = props;\n\n const groupEntries = Object.entries(menuDefinition.groups);\n // Convert array of entries to array of objects with id and group properties\n const groups = groupEntries.map(([key, value]) => ({ id: key, group: value }));\n let includedGroups = groups.filter((g) => 'column' in g.group);\n\n // Check if column is provided and menuDefinition is a MultiColumnMenu\n if (\n columnId &&\n 'columns' in menuDefinition &&\n // Without this type assertion, TS doesn't know what columns is.\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n (menuDefinition as MultiColumnMenu).columns[columnId]\n ) {\n // When laying out a single column in a MultiColumnMenu, only include groups associated with\n // the provided column. Note: without the (annoying) redundant check that the included groups\n // have the colum field, TS doesn't think it exists.\n includedGroups = includedGroups.filter(\n (g) => 'column' in g.group && g.group.column === columnId,\n );\n }\n\n return ;\n}\n","import '@/components/mui/grid-menu.component.css';\nimport { GroupedMenuPropsBase } from '@/components/mui/grouped-menu-item-list.component';\nimport { CommandHandler } from '@/components/mui/menu-item.component';\nimport TopLevelMenu from '@/components/mui/top-level-menu.component';\nimport { Grid, List } from '@mui/material';\nimport {\n Localized,\n MenuColumnWithHeader,\n MultiColumnMenu,\n ReferencedItem,\n} from 'platform-bible-utils';\nimport { useMemo } from 'react';\n\ntype ColumnInfo = {\n /*\n * The ID (`${string}.${string}`) of a specific menu column.\n */\n id: ReferencedItem;\n\n /*\n * Metadata (label, order, etc.) for a specific menu column.\n */\n metadata: Localized;\n};\n\ntype MenuColumnProps = ColumnInfo &\n GroupedMenuPropsBase & {\n /** Additional css classes to help with unique styling of the menu column */\n className?: string;\n };\n\nexport type GridMenuInfo = {\n /** The menu object containing information about the columns, groups, and items to display. */\n multiColumnMenu: Localized;\n};\n\nexport type GridMenuProps = GridMenuInfo & {\n /** Optional unique identifier */\n id?: string;\n\n commandHandler: CommandHandler;\n\n /** Additional css classes to help with unique styling of the grid menu */\n className?: string;\n};\n\nfunction MenuColumn({\n commandHandler,\n menuDefinition,\n id,\n metadata,\n onClick,\n className,\n}: MenuColumnProps) {\n return (\n \n

    \n {metadata.label}\n

    \n {/* It would seem as though this List component were unnecessary, since it only contains one\n thing, but the \"dense\" property does affect the layout of the items (in a way I don't fully\n understand). There might be a better way. */}\n \n \n \n \n );\n}\n\nexport default function GridMenu({\n commandHandler,\n className,\n multiColumnMenu,\n id,\n}: GridMenuProps) {\n const { columns } = multiColumnMenu;\n\n const sortedColumns = useMemo(() => {\n const columnNumbers = new Map();\n Object.getOwnPropertyNames(columns).forEach((columnName: string) => {\n // We know for sure there is a (boolean) property 'isExtensible' that we are not interested in.\n if (columnName === 'isExtensible') return;\n // TS doesn't allow `columnName` above to be a ReferencedItem even though the type says it is\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const columnId = columnName as ReferencedItem;\n const column = columns[columnId];\n // As of right now (and hopefully forever after), all remaining properties of the\n // ColumnsWithHeaders object are columns whose property names are the IDs of the columns.\n // This is an additional (redundant) sanity check. Specifically we're interested in\n // MenuColumnWithHeader objects, which TypeScript now \"knows\" we have, but at runtime all we\n // can check for is that it's an object with a valid numeric order field. That's likely good\n // enough.\n if (\n typeof column === 'object' &&\n typeof column.order === 'number' &&\n !Number.isNaN(column.order)\n )\n columnNumbers.set(column.order, { id: columnId, metadata: column });\n else\n console.warn(\n `Property ${columnName} (${typeof column}) on menu ${id} is not a valid column and is being ignored. This might indicate data corruption`,\n );\n });\n\n // Extract values and sort them based on the 'order' property\n return Array.from(columnNumbers.values()).sort((a, b) => {\n return (a.metadata.order || 0) - (b.metadata.order || 0);\n });\n }, [columns, id]);\n\n // We might need something like this if we need to be able to prevent empty columns\n // sortedColumns.filter((c) => multiColumnMenu.groups.some((g) => 'column' in g && (g as .column)...\n\n return (\n \n {sortedColumns.map((col, index) => (\n \n ))}\n \n );\n}\n","import { useEffect, useRef, useState } from 'react';\n\nexport type UsePromiseOptions = {\n /**\n * Whether to leave the value as the most recent resolved promise value or set it back to\n * defaultValue while running the promise again. Defaults to true\n */\n preserveValue?: boolean;\n};\n\n/** Set up defaults for options for usePromise hook */\nfunction getUsePromiseOptionsDefaults(options: UsePromiseOptions): UsePromiseOptions {\n return {\n preserveValue: true,\n ...options,\n };\n}\n\n/**\n * Awaits a promise and returns a loading value while the promise is unresolved\n *\n * @param promiseFactoryCallback A function that returns the promise to await. If this callback is\n * undefined, the current value will be returned (defaultValue unless it was previously changed\n * and `options.preserveValue` is true), and there will be no loading.\n *\n * WARNING: MUST BE STABLE - const or wrapped in useCallback. The reference must not be updated\n * every render\n * @param defaultValue The initial value to return while first awaiting the promise. If\n * `options.preserveValue` is false, this value is also shown while awaiting the promise on\n * subsequent calls.\n *\n * Note: this parameter is internally assigned to a `ref`, so changing it will not cause any hooks\n * to re-run with its new value. This means that, if the `promiseFactoryCallback` changes and\n * `options.preserveValue` is `false`, the returned value will be set to the current\n * `defaultValue`. However, the returned value will not be updated if`defaultValue` changes.\n * @param options Various options for adjusting how this hook runs the `promiseFactoryCallback`\n *\n * Note: this parameter is internally assigned to a `ref`, so changing it will not cause any hooks\n * to re-run with its new value. However, the latest `options.preserveValue` will always be used\n * appropriately to determine whether to preserve the returned value when changing the\n * `promiseFactoryCallback`\n * @returns `[value, isLoading]`\n *\n * - `value`: the current value for the promise, either the defaultValue or the resolved promise value\n * - `isLoading`: whether the promise is waiting to be resolved\n */\nconst usePromise = (\n promiseFactoryCallback: (() => Promise) | undefined,\n defaultValue: T,\n options: UsePromiseOptions = {},\n): [value: T, isLoading: boolean] => {\n // Use defaultValue as a ref so it doesn't update dependency arrays\n const defaultValueRef = useRef(defaultValue);\n defaultValueRef.current = defaultValue;\n // Use options as a ref so it doesn't update dependency arrays\n const optionsDefaultedRef = useRef(options);\n optionsDefaultedRef.current = getUsePromiseOptionsDefaults(optionsDefaultedRef.current);\n\n const [value, setValue] = useState(() => defaultValueRef.current);\n const [isLoading, setIsLoading] = useState(true);\n useEffect(() => {\n let promiseIsCurrent = true;\n // If a promiseFactoryCallback was provided, we are loading. Otherwise, there is no loading to do\n setIsLoading(!!promiseFactoryCallback);\n (async () => {\n // If there is a callback to run, run it\n if (promiseFactoryCallback) {\n const result = await promiseFactoryCallback();\n // If the promise was not already replaced, update the value\n if (promiseIsCurrent) {\n setValue(() => result);\n setIsLoading(false);\n }\n }\n })();\n\n return () => {\n // Mark this promise as old and not to be used\n promiseIsCurrent = false;\n if (!optionsDefaultedRef.current.preserveValue) setValue(() => defaultValueRef.current);\n };\n }, [promiseFactoryCallback]);\n\n return [value, isLoading];\n};\nexport default usePromise;\n","\"use client\";\n\nimport createSvgIcon from './utils/createSvgIcon';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nexport default createSvgIcon( /*#__PURE__*/_jsx(\"path\", {\n d: \"M3 18h18v-2H3zm0-5h18v-2H3zm0-7v2h18V6z\"\n}), 'Menu');","import GridMenu from '@/components/mui/grid-menu.component';\nimport { Command, CommandHandler } from '@/components/mui/menu-item.component';\nimport usePromise from '@/hooks/use-promise.hook';\nimport { Menu as MenuIcon } from '@mui/icons-material';\nimport { Drawer, IconButton } from '@mui/material';\nimport { Localized, MultiColumnMenu } from 'platform-bible-utils';\nimport {\n MouseEvent,\n MutableRefObject,\n PropsWithChildren,\n useCallback,\n useEffect,\n useState,\n} from 'react';\n\nexport interface MultiColumnMenuProvider {\n (isSupportAndDevelopment: boolean): Promise>;\n}\n\nexport type HamburgerMenuButtonProps = PropsWithChildren & {\n /** The handler to use for menu commands (and eventually toolbar commands). */\n commandHandler: CommandHandler;\n\n /**\n * Optional reference to the \"div\" container that determines the where the menu should appear. If\n * not defined, then (1,1) used.\n */\n containerRef?: MutableRefObject;\n\n /**\n * The delegate to use to get the menu data. If not specified or if it returns undefined, the data\n * in normalMenu or fullMenu property will be used.\n */\n menuProvider?: MultiColumnMenuProvider;\n\n /**\n * The menu data to show when the menu is opened if the menuProvider property is not defined.\n * (This allows for a default or test-only static menu to be used.)\n */\n normalMenu?: Localized;\n\n /**\n * The menu data to show for \"full\" menu (when opened with the SHIFT key pressed) if the\n * menuProvider property is not defined. (This allows for a default or test-only static menu to be\n * used.)\n */\n fullMenu?: Localized;\n\n /** Additional css class(es) to help with unique styling of the sub-components */\n className?: string;\n\n /** Value to use as prefix for ARIA labels on interactive sub-components */\n ariaLabelPrefix?: string;\n};\n\nexport default function HamburgerMenuButton({\n menuProvider,\n normalMenu,\n fullMenu,\n commandHandler,\n containerRef,\n className,\n ariaLabelPrefix,\n children,\n}: HamburgerMenuButtonProps) {\n const [isMenuOpen, setMenuOpen] = useState(false);\n const [showFullMenu, setShowFullMenu] = useState(false);\n\n const handleMenuItemClick = useCallback(() => {\n if (isMenuOpen) setMenuOpen(false);\n setShowFullMenu(false);\n }, [isMenuOpen]);\n\n const handleMenuButtonClick = useCallback((e: MouseEvent) => {\n e.stopPropagation();\n setMenuOpen((prevIsOpen) => {\n const isOpening = !prevIsOpen;\n if (isOpening && e.shiftKey) setShowFullMenu(true);\n else if (!isOpening) setShowFullMenu(false);\n return isOpening;\n });\n }, []);\n\n const menuCommandHandler = useCallback(\n (command: Command) => {\n handleMenuItemClick();\n return commandHandler(command);\n },\n [commandHandler, handleMenuItemClick],\n );\n\n const [offset, setOffset] = useState({ top: 1, left: 1 });\n\n useEffect(() => {\n if (isMenuOpen) {\n const node = containerRef?.current;\n if (node) {\n const rect = node.getBoundingClientRect();\n const scrollTop = window.scrollY;\n const scrollLeft = window.scrollX;\n const top = rect.top + scrollTop + node.clientHeight;\n const left = rect.left + scrollLeft;\n setOffset({ top, left });\n }\n }\n }, [isMenuOpen, containerRef]);\n\n const [normalMenuData] = usePromise(\n useCallback(async () => {\n return menuProvider?.(false) ?? normalMenu;\n // isMenuOpen needs to be included for the menu contents to reevaluate when reopened\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [menuProvider, normalMenu, isMenuOpen]),\n normalMenu,\n );\n\n const [fullMenuData] = usePromise(\n useCallback(async () => {\n return menuProvider?.(true) ?? fullMenu ?? normalMenuData;\n // isMenuOpen needs to be included for the menu contents to reevaluate when reopened\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [menuProvider, fullMenu, normalMenuData, isMenuOpen]),\n fullMenu ?? normalMenuData,\n );\n\n const menu = showFullMenu && fullMenuData ? fullMenuData : normalMenuData;\n\n return (\n <>\n \n {children ?? }\n \n \n {menu ? (\n \n ) : undefined}\n \n \n );\n}\n","import '@/components/mui/icon-button.component.css';\nimport { IconButton as MuiIconButton } from '@mui/material';\nimport { MouseEventHandler, PropsWithChildren } from 'react';\n\nexport type IconButtonProps = PropsWithChildren<{\n /** Optional unique identifier */\n id?: string;\n /**\n * Required. Used as both the tooltip (aka, title) and the aria-label (used for accessibility,\n * testing, etc.), unless a distinct tooltip is supplied.\n */\n label: string;\n /**\n * Enabled status of button\n *\n * @default false\n */\n isDisabled?: boolean;\n /** Optional tooltip to display if different from the aria-label. */\n tooltip?: string;\n /** If true, no tooltip will be displayed. */\n isTooltipSuppressed?: boolean;\n /**\n * If given, uses a negative margin to counteract the padding on one side (this is often helpful\n * for aligning the left or right side of the icon with content above or below, without ruining\n * the border size and shape).\n *\n * @default false\n */\n adjustMarginToAlignToEdge?: 'end' | 'start' | false;\n /**\n * The size of the component. small is equivalent to the dense button styling.\n *\n * @default false\n */\n size: 'small' | 'medium' | 'large';\n /** Additional css classes to help with unique styling of the button */\n className?: string;\n /** Optional click handler */\n onClick?: MouseEventHandler;\n}>;\n\n/**\n * Iconic button a user can click to do something\n *\n * Thanks to MUI for heavy inspiration and documentation\n * https://mui.com/material-ui/getting-started/overview/\n */\nfunction IconButton({\n id,\n label,\n isDisabled = false,\n tooltip,\n isTooltipSuppressed = false,\n adjustMarginToAlignToEdge = false,\n size = 'medium',\n className,\n onClick,\n children,\n}: IconButtonProps) {\n return (\n \n {children /* the icon to display */}\n \n );\n}\n\nexport default IconButton;\n","import { cn } from '@/utils/shadcn-ui.util';\nimport { LoaderCircle, LucideProps } from 'lucide-react';\nimport { forwardRef } from 'react';\n\nexport type SpinnerProps = LucideProps;\n\nconst Spinner = forwardRef(({ className, ...props }, ref) => {\n return (\n \n );\n});\n\nSpinner.displayName = 'Spinner';\n\nexport default Spinner;\n","import { Input as ShadInput } from '@/components/shadcn-ui/input';\nimport { Label as ShadLabel } from '@/components/shadcn-ui/label';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { ChangeEventHandler, FocusEventHandler } from 'react';\n\nexport type TextFieldProps = {\n /** Optional unique identifier */\n id?: string;\n /**\n * If `true`, the component is disabled.\n *\n * @default false\n */\n isDisabled?: boolean;\n /**\n * If `true`, the label is displayed in an error state.\n *\n * @default false\n */\n hasError?: boolean;\n /**\n * If `true`, the input will take up the full width of its container.\n *\n * @default false\n */\n isFullWidth?: boolean;\n /** Text that gives the user instructions on what contents the TextField expects */\n helperText?: string;\n /** The title of the TextField */\n label?: string;\n /** The short hint displayed in the `input` before the user enters a value. */\n placeholder?: string;\n /**\n * If `true`, the label is displayed as required and the `input` element is required.\n *\n * @default false\n */\n isRequired?: boolean;\n /** Additional css classes to help with unique styling of the text field */\n className?: string;\n /** Starting value for the text field if it is not controlled */\n defaultValue?: string | number;\n /** Value of the text field if controlled */\n value?: string | number;\n /** Triggers when content of textfield is changed */\n onChange?: ChangeEventHandler;\n /** Triggers when textfield gets focus */\n onFocus?: FocusEventHandler;\n /** Triggers when textfield loses focus */\n onBlur?: FocusEventHandler;\n};\n\n/**\n * Text input field\n *\n * Thanks to Shadcn for heavy inspiration and documentation\n * https://ui.shadcn.com/docs/components/input#with-label\n */\nfunction TextField({\n id,\n isDisabled = false,\n hasError = false,\n isFullWidth = false,\n helperText,\n label,\n placeholder,\n isRequired = false,\n className,\n defaultValue,\n value,\n onChange,\n onFocus,\n onBlur,\n}: TextFieldProps) {\n return (\n
    \n {`${label}${isRequired ? '*' : ''}`}\n \n

    {helperText}

    \n
    \n );\n}\n\nexport default TextField;\n","import HamburgerMenuButton, {\n MultiColumnMenuProvider,\n} from '@/components/mui/hamburger-menu-button.component';\nimport { CommandHandler } from '@/components/mui/menu-item.component';\nimport '@/components/mui/toolbar.component.css';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { AppBar, Toolbar as MuiToolbar } from '@mui/material';\nimport { PropsWithChildren, useRef } from 'react';\n\nexport type ToolbarProps = PropsWithChildren<{\n /** The handler to use for menu commands (and eventually toolbar commands). */\n commandHandler: CommandHandler;\n\n /**\n * The optional delegate to use to get the menu data. If not specified, the \"hamburger\" menu will\n * not display.\n */\n menuProvider?: MultiColumnMenuProvider;\n\n /** Optional unique identifier */\n id?: string;\n\n /** Additional css classes to help with unique styling of the toolbar */\n className?: string;\n}>;\n\nexport default function Toolbar({\n menuProvider,\n commandHandler,\n className,\n id,\n children,\n}: ToolbarProps) {\n // This ref will always be defined\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const containerRef = useRef(undefined!);\n\n return (\n
    \n \n \n {menuProvider ? (\n \n ) : undefined}\n {children ?
    {children}
    : undefined}\n \n
    \n
    \n );\n}\n","import React from 'react';\nimport { cva, type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst alertVariants = cva(\n 'tw-relative tw-w-full tw-rounded-lg tw-border tw-p-4 [&>svg~*]:tw-pl-7 [&>svg+div]:tw-translate-y-[-3px] [&>svg]:tw-absolute [&>svg]:tw-left-4 [&>svg]:tw-top-4 [&>svg]:tw-text-foreground',\n {\n variants: {\n variant: {\n default: 'tw-bg-background tw-text-foreground',\n destructive:\n 'tw-border-destructive/50 tw-text-destructive dark:tw-border-destructive [&>svg]:tw-text-destructive',\n },\n },\n defaultVariants: {\n variant: 'default',\n },\n },\n);\n\nconst Alert = React.forwardRef<\n HTMLDivElement,\n React.HTMLAttributes & VariantProps\n>(({ className, variant, ...props }, ref) => (\n
    \n));\nAlert.displayName = 'Alert';\n\nconst AlertTitle = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n {/* added because of https://github.com/jsx-eslint/eslint-plugin-jsx-a11y/blob/main/docs/rules/heading-has-content.md */}\n {props.children}{' '}\n \n ),\n);\nAlertTitle.displayName = 'AlertTitle';\n\nconst AlertDescription = React.forwardRef<\n HTMLParagraphElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n
    \n));\nAlertDescription.displayName = 'AlertDescription';\n\nexport { Alert, AlertTitle, AlertDescription };\n","import React from 'react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Card = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nCard.displayName = 'Card';\n\nconst CardHeader = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nCardHeader.displayName = 'CardHeader';\n\nconst CardTitle = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n {/* added because of https://github.com/jsx-eslint/eslint-plugin-jsx-a11y/blob/main/docs/rules/heading-has-content.md */}\n {props.children}\n \n ),\n);\nCardTitle.displayName = 'CardTitle';\n\nconst CardDescription = React.forwardRef<\n HTMLParagraphElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n

    \n));\nCardDescription.displayName = 'CardDescription';\n\nconst CardContent = React.forwardRef>(\n ({ className, ...props }, ref) => (\n

    \n ),\n);\nCardContent.displayName = 'CardContent';\n\nconst CardFooter = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nCardFooter.displayName = 'CardFooter';\n\nexport { Card, CardHeader, CardFooter, CardTitle, CardDescription, CardContent };\n","import { ComponentProps } from 'react';\nimport { toast as sonner, Toaster } from 'sonner';\n\ntype SonnerProps = ComponentProps;\n\nfunction Sonner({ ...props }: SonnerProps) {\n return (\n \n );\n}\n\n// The re-export of the sonner function was added manually\nexport { Sonner, sonner };\n","import React from 'react';\nimport * as SliderPrimitive from '@radix-ui/react-slider';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Slider = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n \n \n \n));\nSlider.displayName = SliderPrimitive.Root.displayName;\n\nexport { Slider };\n","import React from 'react';\nimport * as SwitchPrimitives from '@radix-ui/react-switch';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Switch = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n));\nSwitch.displayName = SwitchPrimitives.Root.displayName;\n\nexport { Switch };\n","import React from 'react';\nimport * as TabsPrimitive from '@radix-ui/react-tabs';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport const Tabs = TabsPrimitive.Root;\n\nexport type TabsListProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport type TabsTriggerProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport type TabsContentProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport const TabsList = React.forwardRef<\n React.ElementRef,\n TabsListProps\n>(({ className, ...props }, ref) => (\n \n));\nTabsList.displayName = TabsPrimitive.List.displayName;\n\nexport const TabsTrigger = React.forwardRef<\n React.ElementRef,\n TabsTriggerProps\n>(({ className, ...props }, ref) => (\n \n));\nTabsTrigger.displayName = TabsPrimitive.Trigger.displayName;\n\nexport const TabsContent = React.forwardRef<\n React.ElementRef,\n TabsContentProps\n>(({ className, ...props }, ref) => (\n \n));\nTabsContent.displayName = TabsPrimitive.Content.displayName;\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Download } from 'lucide-react';\n\ntype InstallButtonProps = {\n /** The installing boolean value determines the state of the button. */\n isInstalling: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n /** Optional text for the button. */\n buttonText?: string;\n} & ButtonProps;\n\n/**\n * The InstallButton component is a button designed for initiating installs. It includes visuals for\n * active installing and idle states.\n *\n * @param isInstalling The installing boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @param buttonText Optional text for the button.\n * @returns A install button.\n */\nexport default function InstallButton({\n isInstalling,\n handleClick,\n buttonText,\n className,\n ...props\n}: InstallButtonProps) {\n return (\n \n {isInstalling ? (\n \n ) : (\n <>\n \n {buttonText}\n \n )}\n \n );\n}\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\n\ntype EnableButtonProps = {\n /** The enabling boolean value determines the state of the button. */\n isEnabling: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n} & ButtonProps;\n\n/**\n * The EnableButton component is a button designed for initiating enabling of downloads. It includes\n * visuals for active enabling and idle states.\n *\n * @param isEnabling The enabling boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @returns A button that can be used to enable.\n */\nexport default function EnableButton({\n isEnabling,\n handleClick,\n className,\n ...props\n}: EnableButtonProps) {\n return (\n \n {isEnabling ? (\n <>\n \n Enabling...\n \n ) : (\n 'Enable'\n )}\n \n );\n}\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\n\ntype DisableButtonProps = {\n /** The disabling boolean value determines the state of the button. */\n isDisabling: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n} & ButtonProps;\n\n/**\n * The DisableButton component is a button designed for initiating disabling of downloads. It\n * includes visuals for active disabling and idle states.\n *\n * @param isDisabling The disabling boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @returns A button that can be used to disable.\n */\nexport default function DisableButton({\n isDisabling,\n handleClick,\n className,\n ...props\n}: DisableButtonProps) {\n return (\n \n {isDisabling ? (\n <>\n \n Disabling...\n \n ) : (\n 'Disable'\n )}\n \n );\n}\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\n\ntype UpdateButtonProps = {\n /** The updating boolean value determines the state of the button. */\n isUpdating: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n} & ButtonProps;\n\n/**\n * The UpdateButton component is a button designed for initiating updates for downloaded extensions.\n * It includes visuals for active updating and idle states.\n *\n * @param isUpdating The updating boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @returns A button that can be used to update.\n */\nexport default function UpdateButton({\n isUpdating,\n handleClick,\n className,\n ...props\n}: UpdateButtonProps) {\n return (\n \n {isUpdating ? (\n <>\n \n Updating...\n \n ) : (\n 'Update'\n )}\n \n );\n}\n","import { cn } from '@/utils/shadcn-ui.util';\nimport Markdown, { MarkdownToJSX } from 'markdown-to-jsx';\nimport { useMemo } from 'react';\n\ninterface MarkdownRendererProps {\n /** Optional unique identifier */\n id?: string;\n /** The markdown string to render */\n markdown: string;\n className?: string;\n /**\n * The [`target` attribute for `a` html\n * tags](https://developer.mozilla.org/en-US/docs/Web/HTML/Element/a#target). Defaults to not\n * adding a `target` to `a` tags\n */\n anchorTarget?: string;\n}\n\n/**\n * This component renders markdown content given a markdown string. It uses typography styles from\n * the platform.\n *\n * @param markdown The markdown string to render.\n * @param id Optional unique identifier\n * @returns A div containing the rendered markdown content.\n */\nexport default function MarkdownRenderer({\n id,\n markdown,\n className,\n anchorTarget,\n}: MarkdownRendererProps) {\n const options: MarkdownToJSX.Options = useMemo(\n () => ({\n overrides: {\n a: {\n props: {\n target: anchorTarget,\n },\n },\n },\n }),\n [anchorTarget],\n );\n return (\n
    \n {markdown}\n
    \n );\n}\n","import { Filter, ChevronDown } from 'lucide-react';\nimport { forwardRef } from 'react';\nimport { Button } from '@/components/shadcn-ui/button';\n\n/**\n * The FilterButton component is a button designed for initiating filtering of data. It is designed\n * to be used with the dropdown menu. It uses forwardRef to pass the button to the dropdown trigger\n * asChild.\n *\n * @returns A button that can be used to filter.\n */\nconst FilterButton = forwardRef((props, ref) => {\n return (\n \n \n Filter\n \n \n );\n});\n\nexport default FilterButton;\n","import {\n DropdownMenu,\n DropdownMenuTrigger,\n DropdownMenuContent,\n DropdownMenuLabel,\n DropdownMenuGroup,\n DropdownMenuCheckboxItem,\n DropdownMenuRadioItem,\n DropdownMenuSeparator,\n} from '@/components/shadcn-ui/dropdown-menu';\nimport FilterButton from './buttons/filter-button.component';\n\nexport enum DropdownMenuItemType {\n Check,\n Radio,\n}\n\nexport type DropdownItem = {\n /** The label is the text that will be displayed on the dropdown item. */\n label: string;\n /** The itemType determines the DropdownMenuItemType type as either Check or Radio. */\n itemType: DropdownMenuItemType;\n /** The onClick function is called when the item is clicked. */\n onClick: () => void;\n};\n\nexport type DropdownGroup = {\n /**\n * The label is the text that will be displayed on the dropdown group. It is used to categorize\n * the items in the group.\n */\n label: string;\n /** The items array contains the items that will be displayed in the dropdown group */\n items: DropdownItem[];\n};\n\nexport type FilterDropdownProps = {\n /** Object unique identifier */\n id?: string;\n /** The groups array contains the groups that will be displayed in the dropdown */\n groups: DropdownGroup[];\n}; // TODO: extend the props later\n\n/**\n * The FilterDropdown component is a dropdown designed for filtering content. It includes groups of\n * items that can be checkboxes or radio items.\n *\n * @param id Optional unique identifier\n * @param groups The groups array contains the groups that will be displayed in the dropdown\n * @returns A filter dropdown.\n */\nexport default function FilterDropdown({ id, groups }: FilterDropdownProps) {\n return (\n
    \n {/* TODO: remove this once the DropDown Menu shadcn has an id prop */}\n \n \n \n \n \n {groups.map((group) => (\n
    \n {group.label}\n \n {group.items.map((item) => (\n
    \n {item.itemType === DropdownMenuItemType.Check ? (\n \n {item.label}\n \n ) : (\n \n {item.label}\n \n )}\n
    \n ))}\n
    \n \n
    \n ))}\n
    \n
    \n
    \n );\n}\n","interface NoExtensionsFoundProps {\n /** Optional unique identifier */\n id?: string;\n /** The message to display */\n message: string;\n}\n/**\n * This component displays a message to the user when no extensions are found in the marketplace.\n *\n * @param id Optional unique identifier\n * @param message The message to display.\n * @returns {JSX.Element} - Returns the message component that displays the message to the user.\n */\nexport default function NoExtensionsFound({ id, message }: NoExtensionsFoundProps) {\n return (\n
    \n
    \n

    {message}

    \n
    \n
    \n );\n}\n","import { CircleHelp, Link as LucideLink, User } from 'lucide-react';\nimport { NumberFormat } from 'platform-bible-utils';\n\n/** Interface that stores the parameters passed to the More Info component */\ninterface MoreInfoProps {\n /** Optional unique identifier */\n id?: string;\n /** The category of the extension */\n category: string;\n /** The number of downloads for the extension */\n downloads: Record;\n /** The languages supported by the extension */\n languages: string[];\n /** The URL to the more info page of the extension */\n moreInfoUrl: string;\n}\n/**\n * This component displays the more info section of the extension which includes the category,\n * number of downloads, languages, and links to the website and support\n *\n * @param id Optional unique identifier\n * @param category The category of the extension\n * @param downloads The number of downloads for the extension\n * @param languages The languages supported by the extension\n * @param moreInfoUrl The URL to the more info page of the extension\n * @returns {JSX.Element} - Returns the more info component that displays the category, number of\n * downloads, languages, and links to the website and support\n */\nexport default function MoreInfo({\n id,\n category,\n downloads,\n languages,\n moreInfoUrl,\n}: MoreInfoProps) {\n /**\n * This constant formats the number of downloads into a more readable format.\n *\n * @example 1000 -> 1K\n *\n * @example 1000000 -> 1M\n *\n * @returns The formatted number of downloads\n */\n const numberFormatted = new NumberFormat('en', {\n notation: 'compact',\n compactDisplay: 'short',\n }).format(Object.values(downloads).reduce((a: number, b: number) => a + b, 0));\n\n /** This function scrolls the window to the bottom of the page. */\n const handleScrollToBottom = () => {\n window.scrollTo(0, document.body.scrollHeight);\n };\n\n return (\n \n
    \n
    \n {category}\n
    \n CATEGORY\n
    \n
    \n
    \n
    \n \n {numberFormatted}\n
    \n USERS\n
    \n
    \n
    \n
    \n {languages.slice(0, 3).map((locale) => (\n \n {locale.toUpperCase()}\n \n ))}\n
    \n {languages.length > 3 && (\n handleScrollToBottom()}\n className=\"tw-text-xs tw-text-gray-500 tw-underline\"\n >\n +{languages.length - 3} more languages\n \n )}\n
    \n
    \n
    \n \n Website\n \n \n \n Support\n \n \n
    \n
    \n );\n}\n","import { useState } from 'react';\n\nexport type VersionInformation = {\n /** Date the version was published */\n date: string;\n /** Description of the changes in the version */\n description: string;\n};\n\n/** Type to store the version history information */\nexport type VersionHistoryType = Record;\n\n/** Interface that stores the parameters passed to the Version History component */\ninterface VersionHistoryProps {\n /** Optional unique identifier */\n id?: string;\n /** Object containing the versions mapped with their information */\n versionHistory: VersionHistoryType;\n}\n\n/**\n * Component to render the version history information shown in the footer component. Lists the 5\n * most recent versions, with the options to show all versions by pressing a button.\n *\n * @param versionHistory Object containing the versions mapped with their information\n * @param id Optional unique identifier\n * @returns Rendered version history for the Footer component\n */\nexport default function VersionHistory({ id, versionHistory }: VersionHistoryProps) {\n const [showAllVersions, setShowAllVersions] = useState(false);\n const currentDate = new Date();\n\n /**\n * Function to format the time string for the version history in the form of 'X year(s) ago'.\n *\n * @param dateString ISO Date string to determine the time string from\n * @returns Formatted time string\n */\n function formatTimeString(dateString: string) {\n const date = new Date(dateString);\n const dateDiff = new Date(currentDate.getTime() - date.getTime());\n const yearDiff = dateDiff.getUTCFullYear() - 1970;\n const monthDiff = dateDiff.getUTCMonth();\n const dayDiff = dateDiff.getUTCDate() - 1;\n\n // Determines how long ago the version was published\n let timeString = '';\n if (yearDiff > 0) {\n timeString = `${yearDiff.toString()} year${yearDiff === 1 ? '' : 's'} ago`;\n } else if (monthDiff > 0) {\n timeString = `${monthDiff.toString()} month${monthDiff === 1 ? '' : 's'} ago`;\n } else if (dayDiff === 0) {\n timeString = 'today';\n } else {\n timeString = `${dayDiff.toString()} day${dayDiff === 1 ? '' : 's'} ago`;\n }\n\n return timeString;\n }\n\n // Sorts the version history by version number\n const sortedEntries = Object.entries(versionHistory).sort((a, b) => b[0].localeCompare(a[0]));\n\n return (\n
    \n

    What`s New

    \n
      \n {(showAllVersions ? sortedEntries : sortedEntries.slice(0, 5)).map((entry) => (\n
      \n
      \n
    • \n {entry[1].description}\n
    • \n
      \n
      \n
      Version {entry[0]}
      \n
      {formatTimeString(entry[1].date)}
      \n
      \n
      \n ))}\n
    \n {sortedEntries.length > 5 && (\n setShowAllVersions(!showAllVersions)}\n className=\"tw-text-xs tw-text-gray-500 tw-underline\"\n >\n {showAllVersions ? 'Show Less Version History' : 'Show All Version History'}\n \n )}\n
    \n );\n}\n","import { useMemo } from 'react';\nimport { formatBytes } from 'platform-bible-utils';\nimport VersionHistory, { VersionHistoryType } from './version-history.component';\n\n/** Interface to store the parameters passed to the Footer component */\ninterface FooterProps {\n /** Optional unique identifier */\n id?: string;\n /** Name of the publisher */\n publisherDisplayName: string;\n /** Size of the extension file in bytes */\n fileSize: number;\n /** List of language codes supported by the extension */\n locales: string[];\n /** Object containing the version history mapped with their information */\n versionHistory: VersionHistoryType;\n}\n\n/**\n * Component to render the footer for the extension details which contains information on the\n * publisher, version history, languages, and file size.\n *\n * @param id Optional unique identifier\n * @param publisherDisplayName Name of the publisher\n * @param fileSize Size of the extension file in bytes\n * @param locales List of language codes supported by the extension\n * @param versionHistory Object containing the version history mapped with their information\n * @returns The rendered Footer component\n */\nexport default function Footer({\n id,\n publisherDisplayName,\n fileSize,\n locales,\n versionHistory,\n}: FooterProps) {\n /** Formats the file size into a human-readable format */\n const formattedFileSize = useMemo(() => formatBytes(fileSize), [fileSize]);\n\n /**\n * This function gets the display names of the languages based on the language codes.\n *\n * @param codes The list of language codes\n * @returns The list of language names\n */\n const getLanguageNames = (codes: string[]) => {\n const displayNames = new Intl.DisplayNames(navigator.language, { type: 'language' });\n return codes.map((code) => displayNames.of(code));\n };\n\n const languageNames = getLanguageNames(locales);\n\n return (\n
    \n
    \n \n
    \n
    \n

    Information

    \n
    \n

    \n Publisher\n {publisherDisplayName}\n Size\n {formattedFileSize}\n

    \n
    \n

    \n Languages\n {languageNames.join(', ')}\n

    \n
    \n
    \n
    \n
    \n
    \n );\n}\n","import { PlatformEvent, PlatformEventHandler } from 'platform-bible-utils';\nimport { useEffect } from 'react';\n\n/**\n * Adds an event handler to an event so the event handler runs when the event is emitted. Use\n * `papi.network.getNetworkEvent` to use a networked event with this hook.\n *\n * @param event The event to subscribe to.\n *\n * - If event is a `PlatformEvent`, that event will be used\n * - If event is undefined, the callback will not be subscribed. Useful if the event is not yet\n * available for example\n *\n * @param eventHandler The callback to run when the event is emitted\n *\n * WARNING: MUST BE STABLE - const or wrapped in useCallback. The reference must not be updated\n * every render\n */\nconst useEvent = (\n event: PlatformEvent | undefined,\n eventHandler: PlatformEventHandler,\n) => {\n useEffect(() => {\n // Do nothing if the event is not provided (in case the event is not yet available, for example)\n if (!event) return () => {};\n\n const unsubscriber = event(eventHandler);\n return () => {\n unsubscriber();\n };\n }, [event, eventHandler]);\n};\nexport default useEvent;\n","import { useCallback, useEffect } from 'react';\nimport { PlatformEvent, PlatformEventAsync, PlatformEventHandler } from 'platform-bible-utils';\nimport usePromise from './use-promise.hook';\n\nconst noopUnsubscriber = () => false;\n\n/**\n * Adds an event handler to an asynchronously subscribing/unsubscribing event so the event handler\n * runs when the event is emitted. Use `papi.network.getNetworkEvent` to use a networked event with\n * this hook.\n *\n * @param event The asynchronously (un)subscribing event to subscribe to.\n *\n * - If event is a `PlatformEvent` or `PlatformEventAsync`, that event will be used\n * - If event is undefined, the callback will not be subscribed. Useful if the event is not yet\n * available for example\n *\n * @param eventHandler The callback to run when the event is emitted\n *\n * WARNING: MUST BE STABLE - const or wrapped in useCallback. The reference must not be updated\n * every render\n */\nconst useEventAsync = (\n event: PlatformEvent | PlatformEventAsync | undefined,\n eventHandler: PlatformEventHandler,\n) => {\n // Subscribe to the event asynchronously\n const [unsubscribe] = usePromise(\n useCallback(async () => {\n // Do nothing if the event is not provided (in case the event is not yet available, for example)\n if (!event) return noopUnsubscriber;\n\n // Wrap subscribe and unsubscribe in promises to allow normal events to be used as well\n const unsub = await Promise.resolve(event(eventHandler));\n return async () => unsub();\n }, [eventHandler, event]),\n noopUnsubscriber,\n // We want the unsubscriber to return to default value immediately upon changing subscription\n // So the useEffect below will unsubscribe asap\n { preserveValue: false },\n );\n\n // Unsubscribe from the event asynchronously (but we aren't awaiting the unsub)\n useEffect(() => {\n return () => {\n if (unsubscribe !== noopUnsubscriber) {\n unsubscribe();\n }\n };\n }, [unsubscribe]);\n};\n\nexport default useEventAsync;\n"],"names":["twMergeCustom","extendTailwindMerge","cn","inputs","clsx","Input","React","className","type","props","ref","jsx","BookChapterInput","forwardRef","handleSearch","handleKeyDown","handleOnClick","handleSubmit","jsxs","ShadInput","event","e","History","P","R","s","n","N","B","O","S","K","g","k","x","T","X","V","w","L","G","A","H","C","I","y","q","U","m","l","h","c","E","D","i","a","o","u","v","f","d","b","J","DropdownMenu","DropdownMenuPrimitive","DropdownMenuTrigger","DropdownMenuGroup","DropdownMenuPortal","DropdownMenuSub","DropdownMenuRadioGroup","DropdownMenuSubTrigger","inset","children","ChevronRight","DropdownMenuSubContent","DropdownMenuContent","sideOffset","DropdownMenuItem","DropdownMenuCheckboxItem","checked","Check","DropdownMenuRadioItem","Circle","DropdownMenuLabel","DropdownMenuSeparator","DropdownMenuShortcut","BookMenuItem","bookId","handleSelectBook","isSelected","handleHighlightBook","bookType","ShadDropdownMenuItem","Canon","ChapterSelect","handleSelectChapter","endChapter","activeChapter","highlightedChapter","handleHighlightedChapter","chapters","_","handleMouse","useCallback","chapterNumber","chapter","GoToMenuItem","handleSort","handleLocationHistory","handleBookmarks","ShadDropdownMenuLabel","ArrowDownWideNarrow","Clock","Bookmark","ALL_BOOK_IDS","BOOK_TYPE_LABELS","BOOK_TYPE_ARRAY","SCROLL_OFFSET","SEARCH_QUERY_FORMATS","fetchGroupedBooks","fetchEndChapter","getChaptersForBook","getAllEnglishNames","isValidBookEnglishName","bookName","getBookIdFromEnglishName","formattedBookName","BookChapterControl","scrRef","searchQuery","setSearchQuery","useState","selectedBookId","setSelectedBookId","setHighlightedChapter","highlightedBookId","setHighlightedBookId","isContentOpen","setIsContentOpen","isContentOpenDelayed","setIsContentOpenDelayed","inputRef","useRef","contentRef","menuItemRef","fetchFilteredBooks","englishNameLowerCase","normalizedQuery","handleSearchInput","searchString","shouldPreventAutoClosing","controlMenuState","open","updateReference","shouldClose","verse","handleInputSubmit","format","matches","book","englishName","handleKeyDownInput","handleKeyDownContent","key","handleKeyDownMenuItem","chapterOffSet","useEffect","useLayoutEffect","scrollTimeout","scrollPosition","ShadDropdownMenu","ShadDropdownMenuTrigger","ShadDropdownMenuContent","bookTypeIndex","element","ShadDropdownMenuSeparator","buttonVariants","cva","Button","variant","size","asChild","Slot","labelVariants","Label","LabelPrimitive","RadioGroup","RadioGroupPrimitive","RadioGroupItem","Popover","PopoverPrimitive","PopoverTrigger","PopoverContent","align","DialogPortal","DialogPrimitive","DialogOverlay","DialogContent","DialogTitle","DialogDescription","Command","CommandPrimitive","CommandInput","Search","CommandList","CommandEmpty","CommandGroup","CommandSeparator","CommandItem","getOptionLabelDefault","option","ComboBox","id","options","buttonClassName","popoverContentClassName","value","onChange","getOptionLabel","buttonPlaceholder","textPlaceholder","commandEmptyMessage","buttonVariant","dir","isDisabled","setOpen","ChevronsUpDown","ChapterRangeSelector","startChapter","handleSelectStartChapter","handleSelectEndChapter","chapterCount","chapterOptions","useMemo","index","Fragment","BookSelectionMode","BOOK_SELECTOR_STRING_KEYS","localizeString","strings","BookSelector","handleBookSelectionModeChange","currentBookName","onSelectBooks","selectedBookIds","localizedStrings","currentBookText","chooseText","chooseBooksText","bookSelectionMode","setBookSelectionMode","onSelectionModeChange","newMode","DataTableViewOptions","table","FilterIcon","column","Select","SelectPrimitive","SelectGroup","SelectValue","SelectTrigger","ChevronDown","SelectScrollUpButton","ChevronUp","SelectScrollDownButton","SelectContent","position","SelectLabel","SelectItem","SelectSeparator","DataTablePagination","pageSize","ArrowLeftIcon","ChevronLeftIcon","ChevronRightIcon","ArrowRightIcon","Table","stickyHeader","TableHeader","TableBody","TableFooter","TableRow","TableHead","TableCell","TableCaption","DataTable","columns","data","enablePagination","showPaginationControls","showColumnVisibilityControls","onRowClickHandler","sorting","setSorting","columnFilters","setColumnFilters","columnVisibility","setColumnVisibility","rowSelection","setRowSelection","useReactTable","getCoreRowModel","getPaginationRowModel","getSortedRowModel","getFilteredRowModel","headerGroup","header","flexRender","_a","row","cell","OccurrencesTable","occurrenceData","setScriptureReference","referenceHeaderText","occurrenceHeaderText","occurrences","uniqueOccurrences","occurrence","uniqueOccurrence","deepEqual","Checkbox","CheckboxPrimitive","getLinesFromUSFM","text","getNumberFromUSFM","regex","match","getBookNumFromId","getStatusForItem","item","approvedItems","unapprovedItems","toggleVariants","Toggle","TogglePrimitive","ToggleGroupContext","ToggleGroup","ToggleGroupPrimitive","ToggleGroupItem","context","getSortingIcon","sortDirection","ArrowUpIcon","ArrowDownIcon","ArrowUpDownIcon","inventoryItemColumn","itemLabel","inventoryAdditionalItemColumn","additionalItemLabel","additionalItemIndex","inventoryCountColumn","countLabel","statusChangeHandler","changedItems","newStatus","onApprovedItemsChange","onUnapprovedItemsChange","newApprovedItems","validItem","newUnapprovedItems","unapprovedItem","inventoryStatusColumn","statusLabel","status","CircleCheckIcon","CircleXIcon","CircleHelpIcon","INVENTORY_STRING_KEYS","filterItemData","itemData","statusFilter","textFilter","filteredItemData","createTableData","scriptureRef","itemRegex","tableData","currentBook","currentChapter","currentVerse","line","items","itemIndex","existingItem","tableEntry","newReference","substring","newItem","Inventory","scriptureReference","extractItems","additionalItemsLabels","scope","onScopeChange","allItemsText","approvedItemsText","unapprovedItemsText","unknownItemsText","scopeBookText","scopeChapterText","scopeVerseText","filterText","showAdditionalItemsText","showAdditionalItems","setShowAdditionalItems","setStatusFilter","setTextFilter","selectedItem","setSelectedItem","reducedTableData","newTableData","firstItem","existingEntry","newTableEntry","filteredTableData","allColumns","numberOfAdditionalItems","additionalColumns","_b","rowClickHandler","newSelection","handleScopeChange","handleStatusFilterChange","SearchBar","onSearch","placeholder","isFullWidth","handleInputChange","VerticalTabs","TabsPrimitive","VerticalTabsList","VerticalTabsTrigger","VerticalTabsContent","TabNavigationContentSearch","tabList","searchPlaceholder","headerTitle","isSearchBarFullWidth","direction","tab","Separator","orientation","decorative","SeparatorPrimitive","Skeleton","TooltipProvider","TooltipPrimitive","Tooltip","TooltipTrigger","TooltipContent","SIDEBAR_WIDTH","SIDEBAR_WIDTH_ICON","SidebarContext","useSidebar","SidebarProvider","defaultOpen","openProp","setOpenProp","style","_open","_setOpen","isOpen","openState","toggleSidebar","state","contextValue","Sidebar","side","collapsible","SidebarTrigger","onClick","PanelLeft","SidebarRail","SidebarInset","SidebarInput","SidebarHeader","SidebarFooter","SidebarSeparator","SidebarContent","SidebarGroup","SidebarGroupLabel","SidebarGroupAction","SidebarGroupContent","SidebarMenu","SidebarMenuItem","sidebarMenuButtonVariants","SidebarMenuButton","isActive","tooltip","Comp","button","SidebarMenuAction","showOnHover","SidebarMenuBadge","SidebarMenuSkeleton","showIcon","width","SidebarMenuSub","SidebarMenuSubItem","SidebarMenuSubButton","SettingsSidebar","extensionLabels","projectInfo","handleSelectSidebarItem","selectedSidebarItem","extensionsSidebarGroupLabel","projectsSidebarGroupLabel","buttonPlaceholderText","handleSelectItem","projectId","getProjectNameFromProjectId","project","info","getIsActive","label","selectedProjectName","SettingsSidebarContentSearch","scrBookColId","scrRefColId","typeColId","detailsColId","defaultScrRefColumnName","defaultScrBookGroupName","defaultTypeColumnName","defaultDetailsColumnName","getColumns","colInfo","showSourceColumn","showSrcCol","formatScrRef","compareScrRefs","toRefOrRange","scriptureSelection","offsetStart","offsetEnd","scrRefToBBBCCCVVV","getRowKey","ScriptureResultsViewer","sources","showColumnHeaders","scriptureReferenceColumnName","scriptureBookGroupName","typeColumnName","detailsColumnName","onRowSelected","grouping","setGrouping","scriptureResults","source","getExpandedRowModel","getGroupedRowModel","selectedRows","keys","selectedRow","scrBookGroupName","typeGroupName","groupingOptions","handleSelectChange","selectedGrouping","handleRowClick","getEvenOrOddBandingStyle","getIndent","groupingState","rowIndex","ChevronLeft","DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS","getLocalizeKeyForScrollGroupId","ScrollGroupSelector","availableScrollGroupIds","scrollGroupId","onChangeScrollGroupId","localizedStringsDefaulted","localizedStringKey","localizedStringValue","newScrollGroupString","scrollGroupOptionId","SettingsList","SettingsListItem","primary","secondary","isLoading","loadingMessage","SettingsListHeader","includeSeparator","Checklist","listItems","selectedListItems","handleSelectListItem","createLabel","_interopRequireDefault","obj","module","chainPropTypes","propType1","propType2","args","_extends","target","isPlainObject","prototype","deepClone","output","deepmerge","p","r","t","z","reactIs_production_min","hasSymbol","REACT_ELEMENT_TYPE","REACT_PORTAL_TYPE","REACT_FRAGMENT_TYPE","REACT_STRICT_MODE_TYPE","REACT_PROFILER_TYPE","REACT_PROVIDER_TYPE","REACT_CONTEXT_TYPE","REACT_ASYNC_MODE_TYPE","REACT_CONCURRENT_MODE_TYPE","REACT_FORWARD_REF_TYPE","REACT_SUSPENSE_TYPE","REACT_SUSPENSE_LIST_TYPE","REACT_MEMO_TYPE","REACT_LAZY_TYPE","REACT_BLOCK_TYPE","REACT_FUNDAMENTAL_TYPE","REACT_RESPONDER_TYPE","REACT_SCOPE_TYPE","isValidElementType","typeOf","object","$$typeof","$$typeofType","AsyncMode","ConcurrentMode","ContextConsumer","ContextProvider","Element","ForwardRef","Lazy","Memo","Portal","Profiler","StrictMode","Suspense","hasWarnedAboutDeprecatedIsAsyncMode","isAsyncMode","isConcurrentMode","isContextConsumer","isContextProvider","isElement","isForwardRef","isFragment","isLazy","isMemo","isPortal","isProfiler","isStrictMode","isSuspense","reactIs_development","reactIsModule","require$$0","require$$1","getOwnPropertySymbols","hasOwnProperty","propIsEnumerable","toObject","val","shouldUseNative","test1","test2","order2","test3","letter","objectAssign","from","to","symbols","ReactPropTypesSecret","ReactPropTypesSecret_1","has","printWarning","loggedTypeFailures","message","checkPropTypes","typeSpecs","values","location","componentName","getStack","typeSpecName","error","err","ex","stack","checkPropTypes_1","ReactIs","assign","require$$2","require$$3","require$$4","emptyFunctionThatReturnsNull","factoryWithTypeCheckers","isValidElement","throwOnDirectAccess","ITERATOR_SYMBOL","FAUX_ITERATOR_SYMBOL","getIteratorFn","maybeIterable","iteratorFn","ANONYMOUS","ReactPropTypes","createPrimitiveTypeChecker","createAnyTypeChecker","createArrayOfTypeChecker","createElementTypeChecker","createElementTypeTypeChecker","createInstanceTypeChecker","createNodeChecker","createObjectOfTypeChecker","createEnumTypeChecker","createUnionTypeChecker","createShapeTypeChecker","createStrictShapeTypeChecker","is","PropTypeError","createChainableTypeChecker","validate","manualPropTypeCallCache","manualPropTypeWarningCount","checkType","isRequired","propName","propFullName","secret","cacheKey","chainedCheckType","expectedType","propValue","propType","getPropType","preciseType","getPreciseType","typeChecker","expectedClass","expectedClassName","actualClassName","getClassName","expectedValues","valuesString","arrayOfTypeCheckers","checker","getPostfixForTypeWarning","expectedTypes","checkerResult","expectedTypesMessage","isNode","invalidValidatorError","shapeTypes","allKeys","iterator","step","entry","isSymbol","emptyFunction","emptyFunctionWithReset","factoryWithThrowingShims","shim","getShim","propTypesModule","isClassComponent","elementType","acceptingRef","safePropName","warningHint","elementAcceptingRef","PropTypes","elementAcceptingRef$1","specialProperty","exactProp","propTypes","unsupportedProps","prop","formatMuiErrorMessage","code","url","REACT_SERVER_CONTEXT_TYPE","REACT_OFFSCREEN_TYPE","enableScopeAPI","enableCacheElement","enableTransitionTracing","enableLegacyHidden","enableDebugTracing","REACT_MODULE_REFERENCE","SuspenseList","hasWarnedAboutDeprecatedIsConcurrentMode","isSuspenseList","fnNameMatchRegex","getFunctionName","fn","getFunctionComponentName","Component","fallback","getWrappedName","outerType","innerType","wrapperName","functionName","getDisplayName","HTMLElementType","refType","refType$1","capitalize","string","_formatMuiErrorMessage","createChainedFunction","funcs","acc","func","debounce","wait","timeout","debounced","later","deprecatedPropType","validator","reason","componentNameSafe","propFullNameSafe","isMuiElement","muiNames","_muiName","_element$type","ownerDocument","node","ownerWindow","requirePropFactory","componentNameInError","prevPropTypes","requiredProp","defaultTypeChecker","typeCheckerResult","setRef","useEnhancedEffect","useEnhancedEffect$1","globalId","useGlobalId","idOverride","defaultId","setDefaultId","maybeReactUseId","useId","reactId","unsupportedProp","useControlled","controlled","defaultProp","name","isControlled","valueState","setValue","defaultValue","setValueIfUncontrolled","newValue","useEventCallback","useForkRef","refs","instance","UNINITIALIZED","useLazyRef","init","initArg","EMPTY","useOnMount","Timeout","delay","useTimeout","hadKeyboardEvent","hadFocusVisibleRecently","hadFocusVisibleRecentlyTimeout","inputTypesWhitelist","focusTriggersKeyboardModality","tagName","handlePointerDown","handleVisibilityChange","prepare","doc","isFocusVisible","useIsFocusVisible","isFocusVisibleRef","handleBlurVisible","handleFocusVisible","resolveProps","defaultProps","defaultSlotProps","slotProps","slotPropName","composeClasses","slots","getUtilityClass","classes","slot","utilityClass","defaultGenerator","createClassNameGenerator","generate","generator","ClassNameGenerator","ClassNameGenerator$1","globalStateClasses","generateUtilityClass","globalStatePrefix","globalStateClass","generateUtilityClasses","result","clamp","min","max","_objectWithoutPropertiesLoose","excluded","sourceKeys","_excluded","sortBreakpointsValues","breakpointsAsArray","breakpoint1","breakpoint2","createBreakpoints","breakpoints","unit","other","sortedValues","up","down","between","start","end","endIndex","only","not","keyIndex","shape","shape$1","responsivePropType","responsivePropType$1","merge","defaultBreakpoints","handleBreakpoints","styleFromPropValue","theme","themeBreakpoints","breakpoint","mediaKey","cssKey","createEmptyBreakpointObject","breakpointsInput","_breakpointsInput$key","breakpointStyleKey","removeUnusedBreakpoints","breakpointKeys","breakpointOutput","getPath","path","checkVars","getStyleValue","themeMapping","transform","propValueFinal","userValue","cssProperty","themeKey","memoize","cache","arg","properties","directions","aliases","getCssProperties","property","marginKeys","paddingKeys","spacingKeys","createUnaryUnit","_getPath","themeSpacing","abs","createUnarySpacing","getValue","transformer","transformed","getStyleFromPropValue","cssProperties","resolveCssProperty","margin","padding","createSpacing","spacingInput","spacing","argsInput","argument","compose","styles","handlers","borderTransform","createBorderStyle","border","borderTop","borderRight","borderBottom","borderLeft","borderColor","borderTopColor","borderRightColor","borderBottomColor","borderLeftColor","outline","outlineColor","borderRadius","gap","columnGap","rowGap","gridColumn","gridRow","gridAutoFlow","gridAutoColumns","gridAutoRows","gridTemplateColumns","gridTemplateRows","gridTemplateAreas","gridArea","paletteTransform","color","bgcolor","backgroundColor","sizingTransform","maxWidth","_props$theme","_props$theme2","breakpointsValues","minWidth","height","maxHeight","minHeight","boxSizing","defaultSxConfig","defaultSxConfig$1","objectsHaveSameKeys","objects","union","callIfFn","maybeFn","unstable_createStyleFunctionSx","getThemeValue","config","styleFunctionSx","_theme$unstable_sxCon","sx","traverse","sxInput","sxObject","emptyBreakpoints","breakpointsKeys","css","styleKey","styleFunctionSx$1","applyStyles","createTheme","paletteInput","shapeInput","muiTheme","isObjectEmpty","useTheme","defaultTheme","contextTheme","ThemeContext","systemDefaultTheme","useThemeWithoutDefault","_excluded2","_excluded3","isEmpty","isStringTag","tag","shouldForwardProp","lowercaseFirstLetter","resolveTheme","themeId","defaultOverridesResolver","processStyleArg","callableStyle","_ref","ownerState","resolvedStylesArg","resolvedStyle","variants","isMatch","createStyled","input","rootShouldForwardProp","slotShouldForwardProp","systemSx","inputOptions","processStyles","componentSlot","inputSkipVariantsResolver","inputSkipSx","overridesResolver","skipVariantsResolver","skipSx","shouldForwardPropOption","defaultStyledResolver","styledEngineStyled","transformStyleArg","stylesArg","muiStyledResolver","styleArg","expressions","transformedStyleArg","expressionsWithDefaultTheme","styleOverrides","resolvedStyleOverrides","slotKey","slotStyle","_theme$components","themeVariants","numOfCustomFnsApplied","placeholders","displayName","getThemeProps","params","useThemeProps","clampWrapper","hexToRgb","re","colors","decomposeColor","marker","colorSpace","recomposeColor","hslToRgb","rgb","getLuminance","getContrastRatio","foreground","background","lumA","lumB","alpha","darken","coefficient","lighten","createMixins","mixins","common","common$1","grey","grey$1","purple","purple$1","red","red$1","orange","orange$1","blue","blue$1","lightBlue","lightBlue$1","green","green$1","light","dark","addLightOrDark","intent","shade","tonalOffset","tonalOffsetLight","tonalOffsetDark","getDefaultPrimary","mode","getDefaultSecondary","getDefaultError","getDefaultInfo","getDefaultSuccess","getDefaultWarning","createPalette","palette","contrastThreshold","success","warning","getContrastText","contrastText","contrast","augmentColor","mainShade","lightShade","darkShade","modes","round","caseAllCaps","defaultFontFamily","createTypography","typography","fontFamily","fontSize","fontWeightLight","fontWeightRegular","fontWeightMedium","fontWeightBold","htmlFontSize","allVariants","pxToRem2","coef","pxToRem","buildVariant","fontWeight","lineHeight","letterSpacing","casing","shadowKeyUmbraOpacity","shadowKeyPenumbraOpacity","shadowAmbientShadowOpacity","createShadow","px","shadows","shadows$1","easing","duration","formatMs","milliseconds","getAutoHeightDuration","constant","createTransitions","inputTransitions","mergedEasing","mergedDuration","durationOption","easingOption","isString","isNumber","animatedProp","zIndex","zIndex$1","mixinsInput","transitionsInput","typographyInput","systemTheme","systemCreateTheme","stateClasses","component","child","stateClass","defaultTheme$1","THEME_ID","systemUseThemeProps","styled","styled$1","getSvgIconUtilityClass","useUtilityClasses","SvgIconRoot","_theme$transitions","_theme$transitions$cr","_theme$transitions2","_theme$typography","_theme$typography$pxT","_theme$typography2","_theme$typography2$px","_theme$typography3","_theme$typography3$px","_palette$ownerState$c","_palette","_palette2","_palette3","SvgIcon","inProps","htmlColor","inheritViewBox","titleAccess","viewBox","hasSvgAsChild","more","_jsxs","_jsx","SvgIcon$1","createSvgIcon","unstable_ClassNameGenerator","exports","_utils","ArrowRight","default_1","_createSvgIcon","_jsxRuntime","isHostComponent","appendOwnerState","otherProps","defaultContextValue","ClassNameConfiguratorContext","useClassNamesOverride","disableDefaultClasses","extractEventHandlers","excludeKeys","resolveComponentProps","componentProps","slotState","omitEventHandlers","mergeSlotProps","parameters","getSlotProps","additionalProps","externalSlotProps","externalForwardedProps","joinedClasses","mergedStyle","eventHandlers","componentsPropsWithoutEventHandlers","otherPropsWithoutEventHandlers","internalSlotProps","useSlotProps","_parameters$additiona","skipResolvingSlotProps","rest","resolvedComponentsProps","mergedProps","internalRef","GLOBAL_CLASS_PREFIX","buildStateClass","buildSlotClass","getContainer","container","forwardedRef","disablePortal","mountNode","setMountNode","handleRef","newProps","ReactDOM","top","bottom","right","left","auto","basePlacements","clippingParents","viewport","popper","reference","variationPlacements","placement","placements","beforeRead","read","afterRead","beforeMain","main","afterMain","beforeWrite","write","afterWrite","modifierPhases","getNodeName","getWindow","OwnElement","isHTMLElement","isShadowRoot","attributes","effect","_ref2","initialStyles","styleProperties","attribute","applyStyles$1","getBasePlacement","getUAString","uaData","isLayoutViewport","getBoundingClientRect","includeScale","isFixedStrategy","clientRect","scaleX","scaleY","visualViewport","addVisualOffsets","getLayoutRect","contains","parent","rootNode","next","getComputedStyle","isTableElement","getDocumentElement","getParentNode","getTrueOffsetParent","getContainingBlock","isFirefox","isIE","elementCss","currentNode","getOffsetParent","window","offsetParent","getMainAxisFromPlacement","within","mathMax","mathMin","withinMaxClamp","getFreshSideObject","mergePaddingObject","paddingObject","expandToHashMap","hashMap","toPaddingObject","arrow","_state$modifiersData$","arrowElement","popperOffsets","basePlacement","axis","isVertical","len","arrowRect","minProp","maxProp","endDiff","startDiff","arrowOffsetParent","clientSize","centerToReference","center","offset","axisProp","_options$element","arrow$1","getVariation","unsetSides","roundOffsetsByDPR","win","dpr","mapToStyles","_Object$assign2","popperRect","variation","offsets","gpuAcceleration","adaptive","roundOffsets","isFixed","_offsets$x","_offsets$y","_ref3","hasX","hasY","sideX","sideY","heightProp","widthProp","offsetY","offsetX","commonStyles","_ref4","_Object$assign","computeStyles","_ref5","_options$gpuAccelerat","_options$adaptive","_options$roundOffsets","computeStyles$1","passive","_options$scroll","scroll","_options$resize","resize","scrollParents","scrollParent","eventListeners","hash","getOppositePlacement","matched","getOppositeVariationPlacement","getWindowScroll","scrollLeft","scrollTop","getWindowScrollBarX","getViewportRect","strategy","html","layoutViewport","getDocumentRect","_element$ownerDocumen","winScroll","body","isScrollParent","_getComputedStyle","overflow","overflowX","overflowY","getScrollParent","listScrollParents","list","isBody","updatedList","rectToClientRect","rect","getInnerBoundingClientRect","getClientRectFromMixedType","clippingParent","getClippingParents","canEscapeClipping","clipperElement","getClippingRect","boundary","rootBoundary","mainClippingParents","firstClippingParent","clippingRect","accRect","computeOffsets","commonX","commonY","mainAxis","detectOverflow","_options","_options$placement","_options$strategy","_options$boundary","_options$rootBoundary","_options$elementConte","elementContext","_options$altBoundary","altBoundary","_options$padding","altContext","clippingClientRect","referenceClientRect","popperClientRect","elementClientRect","overflowOffsets","offsetData","multiply","computeAutoPlacement","flipVariations","_options$allowedAutoP","allowedAutoPlacements","allPlacements","allowedPlacements","overflows","getExpandedFallbackPlacements","oppositePlacement","flip","_options$mainAxis","checkMainAxis","_options$altAxis","checkAltAxis","specifiedFallbackPlacements","_options$flipVariatio","preferredPlacement","isBasePlacement","fallbackPlacements","referenceRect","checksMap","makeFallbackChecks","firstFittingPlacement","_basePlacement","isStartVariation","mainVariationSide","altVariationSide","checks","check","numberOfChecks","_loop","_i","fittingPlacement","_ret","flip$1","getSideOffsets","preventedOffsets","isAnySideFullyClipped","hide","referenceOverflow","popperAltOverflow","referenceClippingOffsets","popperEscapeOffsets","isReferenceHidden","hasPopperEscaped","hide$1","distanceAndSkiddingToXY","rects","invertDistance","skidding","distance","_options$offset","_data$state$placement","offset$1","popperOffsets$1","getAltAxis","preventOverflow","_options$tether","tether","_options$tetherOffset","tetherOffset","altAxis","tetherOffsetValue","normalizedTetherOffsetValue","offsetModifierState","_offsetModifierState$","mainSide","altSide","additive","minLen","maxLen","arrowPaddingObject","arrowPaddingMin","arrowPaddingMax","arrowLen","minOffset","maxOffset","clientOffset","offsetModifierValue","tetherMin","tetherMax","preventedOffset","_offsetModifierState$2","_mainSide","_altSide","_offset","_len","_min","_max","isOriginSide","_offsetModifierValue","_tetherMin","_tetherMax","_preventedOffset","preventOverflow$1","getHTMLElementScroll","getNodeScroll","isElementScaled","getCompositeRect","elementOrVirtualElement","isOffsetParentAnElement","offsetParentIsScaled","documentElement","order","modifiers","map","visited","modifier","sort","requires","dep","depModifier","orderModifiers","orderedModifiers","phase","pending","resolve","mergeByName","merged","current","existing","DEFAULT_OPTIONS","areValidElements","_key","popperGenerator","generatorOptions","_generatorOptions","_generatorOptions$def","defaultModifiers","_generatorOptions$def2","defaultOptions","effectCleanupFns","isDestroyed","setOptionsAction","cleanupModifierEffects","runModifierEffects","_state$elements","_state$orderedModifie","_state$orderedModifie2","_ref$options","cleanupFn","noopFn","createPopper","COMPONENT_NAME","getPopperUtilityClass","flipPlacement","resolveAnchorEl","anchorEl","isVirtualElement","defaultPopperOptions","PopperTooltip","_slots$root","initialPlacement","popperOptions","popperRefProp","TransitionProps","tooltipRef","ownRef","popperRef","handlePopperRef","handlePopperRefRef","rtlPlacement","setPlacement","resolvedAnchorElement","setResolvedAnchorElement","handlePopperUpdate","box","popperModifiers","childProps","Root","rootProps","Popper","containerProp","keepMounted","transition","exited","setExited","handleEnter","handleExited","resolvedAnchorEl","display","transitionProps","useThemeSystem","_setPrototypeOf","_inheritsLoose","subClass","superClass","setPrototypeOf","timeoutsShape","TransitionGroupContext","forceReflow","UNMOUNTED","EXITED","ENTERING","ENTERED","EXITING","Transition","_React$Component","_this","parentGroup","appear","initialStatus","prevState","nextIn","_proto","prevProps","nextStatus","exit","enter","mounting","_this2","appearing","maybeNode","maybeAppearing","timeouts","enterTimeout","_this3","nextState","callback","_this4","active","handler","doesNotHaveTimeoutOrListener","maybeNextCallback","_this$props","pt","noop","Transition$1","reflow","getTransitionProps","_style$transitionDura","_style$transitionTimi","getScale","isWebKit154","Grow","addEndListener","inProp","onEnter","onEntered","onEntering","onExit","onExited","onExiting","TransitionComponent","timer","autoTimeout","nodeRef","normalizedTransitionCallback","maybeIsAppearing","handleEntering","isAppearing","transitionDuration","transitionTimingFunction","handleEntered","handleExiting","handleExit","Grow$1","PopperRoot","BasePopper","components","componentsProps","RootComponent","Popper$1","getTooltipUtilityClass","tooltipClasses","tooltipClasses$1","disableInteractive","touch","TooltipPopper","TooltipTooltip","TooltipArrow","hystersisOpen","hystersisTimer","cursorPosition","composeEventHandler","eventHandler","_slots$popper","_slots$transition","_slots$tooltip","_slots$arrow","_slotProps$popper","_ref6","_slotProps$popper2","_slotProps$transition","_slotProps$tooltip","_ref7","_slotProps$tooltip2","_slotProps$arrow","_ref8","_slotProps$arrow2","childrenProp","describeChild","disableFocusListener","disableHoverListener","disableInteractiveProp","disableTouchListener","enterDelay","enterNextDelay","enterTouchDelay","followCursor","idProp","leaveDelay","leaveTouchDelay","onClose","onOpen","PopperComponentProp","PopperProps","title","TransitionComponentProp","isRtl","childNode","setChildNode","arrowRef","setArrowRef","ignoreNonTouchEvents","closeTimer","enterTimer","leaveTimer","touchTimer","setOpenState","prevUserSelect","stopTouchInteraction","handleOpen","handleClose","handleLeave","focusVisibleRef","setChildIsFocusVisible","handleBlur","handleFocus","detectTouchStart","childrenProps","handleMouseOver","handleMouseLeave","handleTouchStart","handleTouchEnd","nativeEvent","handleMouseMove","nameOrDescProps","titleIsString","interactiveWrapperListeners","_PopperProps$popperOp","tooltipModifiers","PopperComponent","TooltipComponent","ArrowComponent","popperProps","tooltipProps","tooltipArrowProps","TransitionPropsInner","Tooltip$1","getIcon","icon","menuLabel","leading","MuiListItemIcon","MenuItem","allowForLeadingIcons","iconPathBefore","iconPathAfter","hasAutoFocus","isDense","isSubMenuParent","hasDisabledGutters","hasDivider","focusVisibleClassName","menuItem","MuiMenuItem","MuiListItemText","getAllGroups","menuDefinition","SubMenu","setAnchorEl","parentMenuItem","parentItemProps","handleParentMenuItemClick","renderSubMenuItems","includedGroups","group","GroupedMenuItemList","Menu","getOrderedGroupItems","groupId","allItems","menuProps","commandHandler","groupsToInclude","sortedGroups","itemArray","allowSpaceForLeadingIcons","createMenuItemProps","isLastItemInGroup","divKey","itemInfo","menuItemProps","TopLevelMenu","columnId","MenuColumn","metadata","Grid","List","GridMenu","multiColumnMenu","sortedColumns","columnNumbers","columnName","col","getUsePromiseOptionsDefaults","usePromise","promiseFactoryCallback","defaultValueRef","optionsDefaultedRef","setIsLoading","promiseIsCurrent","MenuIcon","HamburgerMenuButton","menuProvider","normalMenu","fullMenu","containerRef","ariaLabelPrefix","isMenuOpen","setMenuOpen","showFullMenu","setShowFullMenu","handleMenuItemClick","handleMenuButtonClick","prevIsOpen","isOpening","menuCommandHandler","command","setOffset","normalMenuData","fullMenuData","menu","IconButton","Drawer","isTooltipSuppressed","adjustMarginToAlignToEdge","MuiIconButton","Spinner","LoaderCircle","TextField","hasError","helperText","onFocus","onBlur","ShadLabel","Toolbar","AppBar","MuiToolbar","alertVariants","Alert","AlertTitle","AlertDescription","Card","CardHeader","CardTitle","CardDescription","CardContent","CardFooter","Sonner","Toaster","Slider","SliderPrimitive","Switch","SwitchPrimitives","Tabs","TabsList","TabsTrigger","TabsContent","InstallButton","isInstalling","handleClick","buttonText","Download","EnableButton","isEnabling","DisableButton","isDisabling","UpdateButton","isUpdating","MarkdownRenderer","markdown","anchorTarget","Markdown","FilterButton","Filter","DropdownMenuItemType","DropdownMenuItemType2","FilterDropdown","groups","NoExtensionsFound","MoreInfo","category","downloads","languages","moreInfoUrl","numberFormatted","NumberFormat","handleScrollToBottom","User","locale","LucideLink","CircleHelp","VersionHistory","versionHistory","showAllVersions","setShowAllVersions","currentDate","formatTimeString","dateString","date","dateDiff","yearDiff","monthDiff","dayDiff","timeString","sortedEntries","Footer","publisherDisplayName","fileSize","locales","formattedFileSize","formatBytes","languageNames","codes","displayNames","useEvent","unsubscriber","noopUnsubscriber","useEventAsync","unsubscribe","unsub"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAGA,MAAMA,KAAgBC,GAAoB,EAAE,QAAQ,MAAO,CA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;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","x_google_ignoreList":[3,43,44,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,83,84,85,86,87,88,89,90,91,92,93,94,95,96,97,98,99,100,101,102,103,104,105,106,107,108,109,110,111,112,113,114,115,116,117,118,119,120,121,122,123,124,125,126,127,128,129,130,131,132,133,134,135,136,137,138,139,140,141,142,143,144,145,146,147,148,149,150,151,152,153,154,155,156,157,158,159,160,161,162,163,164,165,166,167,168,169,170,171,172,173,174,175,176,177,178,179,180,181,182,183,184,185,186,187,188,189,190,191,192,193,194,195,196,197,198,199,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,226]} \ No newline at end of file diff --git a/lib/platform-bible-react/src/components/shadcn-ui/sidebar.tsx b/lib/platform-bible-react/src/components/shadcn-ui/sidebar.tsx index 4a4a4a1a9a..322a3ead1d 100644 --- a/lib/platform-bible-react/src/components/shadcn-ui/sidebar.tsx +++ b/lib/platform-bible-react/src/components/shadcn-ui/sidebar.tsx @@ -22,7 +22,8 @@ import { cn } from '@/utils/shadcn-ui.util'; const SIDEBAR_WIDTH = '16rem'; const SIDEBAR_WIDTH_ICON = '3rem'; -const SIDEBAR_KEYBOARD_SHORTCUT = 'b'; +// Commented this out pending a discussion with UX about keyboard shortcuts +// const SIDEBAR_KEYBOARD_SHORTCUT = 'b'; type SidebarContextProps = { state: 'expanded' | 'collapsed'; @@ -83,18 +84,19 @@ const SidebarProvider = React.forwardRef< return setOpen((open) => !open); }, [setOpen]); + // Commented this out pending a discussion with UX about keyboard shortcuts // Adds a keyboard shortcut to toggle the sidebar. - React.useEffect(() => { - const handleKeyDown = (event: KeyboardEvent) => { - if (event.key === SIDEBAR_KEYBOARD_SHORTCUT && (event.metaKey || event.ctrlKey)) { - event.preventDefault(); - toggleSidebar(); - } - }; - - window.addEventListener('keydown', handleKeyDown); - return () => window.removeEventListener('keydown', handleKeyDown); - }, [toggleSidebar]); + // React.useEffect(() => { + // const handleKeyDown = (event: KeyboardEvent) => { + // if (event.key === SIDEBAR_KEYBOARD_SHORTCUT && (event.metaKey || event.ctrlKey)) { + // event.preventDefault(); + // toggleSidebar(); + // } + // }; + + // window.addEventListener('keydown', handleKeyDown); + // return () => window.removeEventListener('keydown', handleKeyDown); + // }, [toggleSidebar]); // We add a state so that we can do data-state="expanded" or "collapsed". // This makes it easier to style the sidebar with Tailwind classes. diff --git a/src/renderer/services/web-view.service-host.ts b/src/renderer/services/web-view.service-host.ts index 6bf47ce0e6..c77bd13968 100644 --- a/src/renderer/services/web-view.service-host.ts +++ b/src/renderer/services/web-view.service-host.ts @@ -1436,7 +1436,7 @@ async function openSettingsTab(webViewId: WebViewId): Promise Date: Thu, 5 Dec 2024 11:09:37 -0500 Subject: [PATCH 17/18] Fix deprecated command and prop --- lib/platform-bible-react/dist/index.cjs | 100 +-- lib/platform-bible-react/dist/index.cjs.map | 2 +- lib/platform-bible-react/dist/index.d.ts | 2 +- lib/platform-bible-react/dist/index.js | 601 +++++++++--------- lib/platform-bible-react/dist/index.js.map | 2 +- .../components/basics/combo-box.component.tsx | 3 +- src/declarations/papi-shared-types.ts | 2 + .../services/web-view.service-host.ts | 2 + 8 files changed, 360 insertions(+), 354 deletions(-) diff --git a/lib/platform-bible-react/dist/index.cjs b/lib/platform-bible-react/dist/index.cjs index ae84fcc8d8..d1dae3558c 100644 --- a/lib/platform-bible-react/dist/index.cjs +++ b/lib/platform-bible-react/dist/index.cjs @@ -1,22 +1,22 @@ -"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const a=require("react/jsx-runtime"),g=require("react"),ee=require("lucide-react"),ot=require("clsx"),pl=require("tailwind-merge"),Ja=require("@radix-ui/react-dropdown-menu"),W=require("platform-bible-utils"),Ht=require("@radix-ui/react-slot"),kn=require("class-variance-authority"),wl=require("@radix-ui/react-label"),fl=require("@radix-ui/react-radio-group"),ml=require("@radix-ui/react-popover"),Ce=require("cmdk"),hl=require("@radix-ui/react-dialog"),ke=require("@tanstack/react-table"),gl=require("@radix-ui/react-select"),bl=require("@radix-ui/react-checkbox"),vl=require("@radix-ui/react-toggle-group"),xl=require("@radix-ui/react-toggle"),yl=require("@radix-ui/react-tabs"),Nl=require("@radix-ui/react-separator"),kl=require("@radix-ui/react-tooltip"),Fr=require("@mui/styled-engine"),Ie=require("@mui/material"),sn=require("react-dom"),Za=require("sonner"),Sl=require("@radix-ui/react-slider"),El=require("@radix-ui/react-switch"),jl=require("markdown-to-jsx");function Ne(e){const t=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(e){for(const n in e)if(n!=="default"){const r=Object.getOwnPropertyDescriptor(e,n);Object.defineProperty(t,n,r.get?r:{enumerable:!0,get:()=>e[n]})}}return t.default=e,Object.freeze(t)}const $=Ne(g),pe=Ne(Ja),Qa=Ne(wl),gn=Ne(fl),bn=Ne(ml),Xe=Ne(hl),ge=Ne(gl),Gr=Ne(bl),rr=Ne(vl),es=Ne(xl),Re=Ne(yl),ts=Ne(Nl),Sn=Ne(kl),Tl=Ne(sn),ln=Ne(Sl),Ur=Ne(El);const Cl=pl.extendTailwindMerge({prefix:"tw-"});function N(...e){return Cl(ot.clsx(e))}const St=g.forwardRef(({className:e,type:t,...n},r)=>a.jsx("input",{type:t,className:N("pr-twp tw-flex tw-h-10 tw-rounded-md tw-border tw-border-input tw-bg-background tw-px-3 tw-py-2 tw-text-sm tw-ring-offset-background file:tw-border-0 file:tw-bg-transparent file:tw-text-sm file:tw-font-medium file:tw-text-foreground placeholder:tw-text-muted-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-cursor-not-allowed disabled:tw-opacity-50",e),ref:r,...n}));St.displayName="Input";const Rl=g.forwardRef(({handleSearch:e,handleKeyDown:t,handleOnClick:n,handleSubmit:r,...o},s)=>a.jsxs("div",{className:"tw-relative",children:[a.jsx(St,{...o,type:"text",className:"tw-box-border tw-gap-2.5 tw-rounded-lg tw-border tw-border-solid tw-bg-background tw-py-2 tw-pl-4 tw-pr-3 tw-font-medium tw-shadow-none tw-outline-none",onChange:i=>e(i.target.value),onKeyDown:i=>{i.key==="Enter"&&r(),t(i)},onClick:n,ref:s}),a.jsx(ee.History,{className:"tw-absolute tw-right-3 tw-top-1/2 tw-h-4 tw-w-4 tw--translate-y-1/2 tw-transform tw-cursor-pointer tw-text-muted-foreground",onClick:()=>{console.log("back in history")}})]}));var Ol=Object.defineProperty,_l=(e,t,n)=>t in e?Ol(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,ne=(e,t,n)=>_l(e,typeof t!="symbol"?t+"":t,n);const gt=["GEN","EXO","LEV","NUM","DEU","JOS","JDG","RUT","1SA","2SA","1KI","2KI","1CH","2CH","EZR","NEH","EST","JOB","PSA","PRO","ECC","SNG","ISA","JER","LAM","EZK","DAN","HOS","JOL","AMO","OBA","JON","MIC","NAM","HAB","ZEP","HAG","ZEC","MAL","MAT","MRK","LUK","JHN","ACT","ROM","1CO","2CO","GAL","EPH","PHP","COL","1TH","2TH","1TI","2TI","TIT","PHM","HEB","JAS","1PE","2PE","1JN","2JN","3JN","JUD","REV","TOB","JDT","ESG","WIS","SIR","BAR","LJE","S3Y","SUS","BEL","1MA","2MA","3MA","4MA","1ES","2ES","MAN","PS2","ODA","PSS","JSA","JDB","TBS","SST","DNT","BLT","XXA","XXB","XXC","XXD","XXE","XXF","XXG","FRT","BAK","OTH","3ES","EZA","5EZ","6EZ","INT","CNC","GLO","TDX","NDX","DAG","PS3","2BA","LBA","JUB","ENO","1MQ","2MQ","3MQ","REP","4BA","LAO"],oo=["XXA","XXB","XXC","XXD","XXE","XXF","XXG","FRT","BAK","OTH","INT","CNC","GLO","TDX","NDX"],ns=["Genesis","Exodus","Leviticus","Numbers","Deuteronomy","Joshua","Judges","Ruth","1 Samuel","2 Samuel","1 Kings","2 Kings","1 Chronicles","2 Chronicles","Ezra","Nehemiah","Esther (Hebrew)","Job","Psalms","Proverbs","Ecclesiastes","Song of Songs","Isaiah","Jeremiah","Lamentations","Ezekiel","Daniel (Hebrew)","Hosea","Joel","Amos","Obadiah","Jonah","Micah","Nahum","Habakkuk","Zephaniah","Haggai","Zechariah","Malachi","Matthew","Mark","Luke","John","Acts","Romans","1 Corinthians","2 Corinthians","Galatians","Ephesians","Philippians","Colossians","1 Thessalonians","2 Thessalonians","1 Timothy","2 Timothy","Titus","Philemon","Hebrews","James","1 Peter","2 Peter","1 John","2 John","3 John","Jude","Revelation","Tobit","Judith","Esther Greek","Wisdom of Solomon","Sirach (Ecclesiasticus)","Baruch","Letter of Jeremiah","Song of 3 Young Men","Susanna","Bel and the Dragon","1 Maccabees","2 Maccabees","3 Maccabees","4 Maccabees","1 Esdras (Greek)","2 Esdras (Latin)","Prayer of Manasseh","Psalm 151","Odes","Psalms of Solomon","Joshua A. *obsolete*","Judges B. *obsolete*","Tobit S. *obsolete*","Susanna Th. *obsolete*","Daniel Th. *obsolete*","Bel Th. *obsolete*","Extra A","Extra B","Extra C","Extra D","Extra E","Extra F","Extra G","Front Matter","Back Matter","Other Matter","3 Ezra *obsolete*","Apocalypse of Ezra","5 Ezra (Latin Prologue)","6 Ezra (Latin Epilogue)","Introduction","Concordance ","Glossary ","Topical Index","Names Index","Daniel Greek","Psalms 152-155","2 Baruch (Apocalypse)","Letter of Baruch","Jubilees","Enoch","1 Meqabyan","2 Meqabyan","3 Meqabyan","Reproof (Proverbs 25-31)","4 Baruch (Rest of Baruch)","Laodiceans"],na=Ll();function Xt(e,t=!0){return t&&(e=e.toUpperCase()),e in na?na[e]:0}function ao(e){return Xt(e)>0}function Pl(e){const t=typeof e=="string"?Xt(e):e;return t>=40&&t<=66}function Il(e){return(typeof e=="string"?Xt(e):e)<=39}function rs(e){return e<=66}function Ml(e){const t=typeof e=="string"?Xt(e):e;return ss(t)&&!rs(t)}function*$l(){for(let e=1;e<=gt.length;e++)yield e}const Al=1,os=gt.length;function Dl(){return["XXA","XXB","XXC","XXD","XXE","XXF","XXG"]}function so(e,t="***"){const n=e-1;return n<0||n>=gt.length?t:gt[n]}function as(e){return e<=0||e>os?"******":ns[e-1]}function Bl(e){return as(Xt(e))}function ss(e){const t=typeof e=="number"?so(e):e;return ao(t)&&!oo.includes(t)}function Vl(e){const t=typeof e=="number"?so(e):e;return ao(t)&&oo.includes(t)}function zl(e){return ns[e-1].includes("*obsolete*")}function Ll(){const e={};for(let t=0;t(e[e.Unknown=0]="Unknown",e[e.Original=1]="Original",e[e.Septuagint=2]="Septuagint",e[e.Vulgate=3]="Vulgate",e[e.English=4]="English",e[e.RussianProtestant=5]="RussianProtestant",e[e.RussianOrthodox=6]="RussianOrthodox",e))(qe||{});const _e=class{constructor(t){if(ne(this,"name"),ne(this,"fullPath"),ne(this,"isPresent"),ne(this,"hasVerseSegments"),ne(this,"isCustomized"),ne(this,"baseVersification"),ne(this,"scriptureBooks"),ne(this,"_type"),t==null)throw new Error("Argument undefined");typeof t=="string"?(this.name=t,this._type=qe[t]):(this._type=t,this.name=qe[t])}get type(){return this._type}equals(t){return!t.type||!this.type?!1:t.type===this.type}};ne(_e,"Original",new _e(qe.Original)),ne(_e,"Septuagint",new _e(qe.Septuagint)),ne(_e,"Vulgate",new _e(qe.Vulgate)),ne(_e,"English",new _e(qe.English)),ne(_e,"RussianProtestant",new _e(qe.RussianProtestant)),ne(_e,"RussianOrthodox",new _e(qe.RussianOrthodox));let ut=_e;function ra(e,t){const n=t[0];for(let r=1;r(e[e.Valid=0]="Valid",e[e.UnknownVersification=1]="UnknownVersification",e[e.OutOfRange=2]="OutOfRange",e[e.VerseOutOfOrder=3]="VerseOutOfOrder",e[e.VerseRepeated=4]="VerseRepeated",e))(is||{});const Ee=class re{constructor(t,n,r,o){if(ne(this,"firstChapter"),ne(this,"lastChapter"),ne(this,"lastVerse"),ne(this,"hasSegmentsDefined"),ne(this,"text"),ne(this,"BBBCCCVVVS"),ne(this,"longHashCode"),ne(this,"versification"),ne(this,"rtlMark","‏"),ne(this,"_bookNum",0),ne(this,"_chapterNum",0),ne(this,"_verseNum",0),ne(this,"_verse"),r==null&&o==null)if(t!=null&&typeof t=="string"){const s=t,i=n!=null&&n instanceof ut?n:void 0;this.setEmpty(i),this.parse(s)}else if(t!=null&&typeof t=="number"){const s=n!=null&&n instanceof ut?n:void 0;this.setEmpty(s),this._verseNum=t%re.chapterDigitShifter,this._chapterNum=Math.floor(t%re.bookDigitShifter/re.chapterDigitShifter),this._bookNum=Math.floor(t/re.bookDigitShifter)}else if(n==null)if(t!=null&&t instanceof re){const s=t;this._bookNum=s.bookNum,this._chapterNum=s.chapterNum,this._verseNum=s.verseNum,this._verse=s.verse,this.versification=s.versification}else{if(t==null)return;const s=t instanceof ut?t:re.defaultVersification;this.setEmpty(s)}else throw new Error("VerseRef constructor not supported.");else if(t!=null&&n!=null&&r!=null)if(typeof t=="string"&&typeof n=="string"&&typeof r=="string")this.setEmpty(o),this.updateInternal(t,n,r);else if(typeof t=="number"&&typeof n=="number"&&typeof r=="number")this._bookNum=t,this._chapterNum=n,this._verseNum=r,this.versification=o??re.defaultVersification;else throw new Error("VerseRef constructor not supported.");else throw new Error("VerseRef constructor not supported.")}static isVerseParseable(t){return t.length>0&&"0123456789".includes(t[0])&&!t.endsWith(this.verseRangeSeparator)&&!t.endsWith(this.verseSequenceIndicator)}static tryParse(t){let n;try{return n=new re(t),{success:!0,verseRef:n}}catch(r){if(r instanceof tn)return n=new re,{success:!1,verseRef:n};throw r}}static getBBBCCCVVV(t,n,r){return t%re.bcvMaxValue*re.bookDigitShifter+(n>=0?n%re.bcvMaxValue*re.chapterDigitShifter:0)+(r>=0?r%re.bcvMaxValue:0)}static fromJSON(t){const{book:n,chapterNum:r,verseNum:o,verse:s,versificationStr:i}=t,l=s||o.toString();let c;return i&&(c=new ut(i)),n?new re(n,r.toString(),l,c):new re}static tryGetVerseNum(t){let n;if(!t)return n=-1,{success:!0,vNum:n};n=0;let r;for(let o=0;o"9")return o===0&&(n=-1),{success:!1,vNum:n};if(n=n*10+ +r-0,n>re.bcvMaxValue)return n=-1,{success:!1,vNum:n}}return{success:!0,vNum:n}}get isDefault(){return this.bookNum===0&&this.chapterNum===0&&this.verseNum===0&&this.versification==null}get hasMultiple(){return this._verse!=null&&(this._verse.includes(re.verseRangeSeparator)||this._verse.includes(re.verseSequenceIndicator))}get book(){return ae.bookNumberToId(this.bookNum,"")}set book(t){this.bookNum=ae.bookIdToNumber(t)}get chapter(){return this.isDefault||this._chapterNum<0?"":this._chapterNum.toString()}set chapter(t){const n=+t;this._chapterNum=Number.isInteger(n)?n:-1}get verse(){return this._verse!=null?this._verse:this.isDefault||this._verseNum<0?"":this._verseNum.toString()}set verse(t){const{success:n,vNum:r}=re.tryGetVerseNum(t);this._verse=n?void 0:t.replace(this.rtlMark,""),this._verseNum=r,!(this._verseNum>=0)&&({vNum:this._verseNum}=re.tryGetVerseNum(this._verse))}get bookNum(){return this._bookNum}set bookNum(t){if(t<=0||t>ae.lastBook)throw new tn("BookNum must be greater than zero and less than or equal to last book");this._bookNum=t}get chapterNum(){return this._chapterNum}set chapterNum(t){this.chapterNum=t}get verseNum(){return this._verseNum}set verseNum(t){this._verseNum=t}get versificationStr(){var t;return(t=this.versification)==null?void 0:t.name}set versificationStr(t){this.versification=this.versification!=null?new ut(t):void 0}get valid(){return this.validStatus===0}get validStatus(){return this.validateVerse(re.verseRangeSeparators,re.verseSequenceIndicators)}get BBBCCC(){return re.getBBBCCCVVV(this._bookNum,this._chapterNum,0)}get BBBCCCVVV(){return re.getBBBCCCVVV(this._bookNum,this._chapterNum,this._verseNum)}get isExcluded(){return!1}parse(t){if(t=t.replace(this.rtlMark,""),t.includes("/")){const s=t.split("/");if(t=s[0],s.length>1)try{const i=+s[1].trim();this.versification=new ut(qe[i])}catch{throw new tn("Invalid reference : "+t)}}const n=t.trim().split(" ");if(n.length!==2)throw new tn("Invalid reference : "+t);const r=n[1].split(":"),o=+r[0];if(r.length!==2||ae.bookIdToNumber(n[0])===0||!Number.isInteger(o)||o<0||!re.isVerseParseable(r[1]))throw new tn("Invalid reference : "+t);this.updateInternal(n[0],r[0],r[1])}simplify(){this._verse=void 0}clone(){return new re(this)}toString(){const t=this.book;return t===""?"":`${t} ${this.chapter}:${this.verse}`}toJSON(){let t=this.verse;(t===""||t===this.verseNum.toString())&&(t=void 0);const n={book:this.book,chapterNum:this.chapterNum,verseNum:this.verseNum,verse:t,versificationStr:this.versificationStr};return t||delete n.verse,n}equals(t){return t instanceof re?t._bookNum===this._bookNum&&t._chapterNum===this._chapterNum&&t._verseNum===this._verseNum&&t.verse===this.verse&&(t.versification==null&&this.versification==null||t.versification!=null&&this.versification!=null&&t.versification.equals(this.versification)):!1}allVerses(t=!1,n=re.verseRangeSeparators,r=re.verseSequenceIndicators){if(this._verse==null||this.chapterNum<=0)return[this.clone()];const o=[],s=ra(this._verse,r);for(const i of s.map(l=>ra(l,n))){const l=this.clone();l.verse=i[0];const c=l.verseNum;if(o.push(l),i.length>1){const d=this.clone();if(d.verse=i[1],!t)for(let u=c+1;ui)return 3;if(r===i)return 4;r=i}return 0}get internalValid(){return this.versification==null?1:this._bookNum<=0||this._bookNum>ae.lastBook?2:(ae.isCanonical(this._bookNum),0)}setEmpty(t=re.defaultVersification){this._bookNum=0,this._chapterNum=-1,this._verse=void 0,this.versification=t}updateInternal(t,n,r){this.bookNum=ae.bookIdToNumber(t),this.chapter=n,this.verse=r}};ne(Ee,"defaultVersification",ut.English),ne(Ee,"verseRangeSeparator","-"),ne(Ee,"verseSequenceIndicator",","),ne(Ee,"verseRangeSeparators",[Ee.verseRangeSeparator]),ne(Ee,"verseSequenceIndicators",[Ee.verseSequenceIndicator]),ne(Ee,"chapterDigitShifter",1e3),ne(Ee,"bookDigitShifter",Ee.chapterDigitShifter*Ee.chapterDigitShifter),ne(Ee,"bcvMaxValue",Ee.chapterDigitShifter-1),ne(Ee,"ValidStatusType",is);class tn extends Error{}const or=pe.Root,io=pe.Trigger,ls=pe.Group,Fl=pe.Portal,Gl=pe.Sub,Ul=pe.RadioGroup,cs=g.forwardRef(({className:e,inset:t,children:n,...r},o)=>a.jsxs(pe.SubTrigger,{ref:o,className:N("tw-flex tw-cursor-default tw-select-none tw-items-center tw-rounded-sm tw-px-2 tw-py-1.5 tw-text-sm tw-outline-none focus:tw-bg-accent data-[state=open]:tw-bg-accent",t&&"tw-pl-8",e),...r,children:[n,a.jsx(ee.ChevronRight,{className:"tw-ml-auto tw-h-4 tw-w-4"})]}));cs.displayName=pe.SubTrigger.displayName;const ds=g.forwardRef(({className:e,...t},n)=>a.jsx(pe.SubContent,{ref:n,className:N("tw-z-50 tw-min-w-[8rem] tw-overflow-hidden tw-rounded-md tw-border tw-bg-popover tw-p-1 tw-text-popover-foreground tw-shadow-lg data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0 data-[state=closed]:tw-zoom-out-95 data-[state=open]:tw-zoom-in-95 data-[side=bottom]:tw-slide-in-from-top-2 data-[side=left]:tw-slide-in-from-right-2 data-[side=right]:tw-slide-in-from-left-2 data-[side=top]:tw-slide-in-from-bottom-2",e),...t}));ds.displayName=pe.SubContent.displayName;const En=g.forwardRef(({className:e,sideOffset:t=4,...n},r)=>a.jsx(pe.Portal,{children:a.jsx(pe.Content,{ref:r,sideOffset:t,className:N("pr-twp tw-z-50 tw-min-w-[8rem] tw-overflow-hidden tw-rounded-md tw-border tw-bg-popover tw-p-1 tw-text-popover-foreground tw-shadow-md data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0 data-[state=closed]:tw-zoom-out-95 data-[state=open]:tw-zoom-in-95 data-[side=bottom]:tw-slide-in-from-top-2 data-[side=left]:tw-slide-in-from-right-2 data-[side=right]:tw-slide-in-from-left-2 data-[side=top]:tw-slide-in-from-bottom-2",e),...n})}));En.displayName=pe.Content.displayName;const lo=g.forwardRef(({className:e,inset:t,...n},r)=>a.jsx(pe.Item,{ref:r,className:N("tw-cursor-default tw-select-none tw-items-center tw-rounded-sm tw-px-2 tw-py-1.5 tw-text-sm tw-outline-none tw-transition-colors focus:tw-bg-accent data-[disabled]:tw-pointer-events-none data-[disabled]:tw-opacity-50",t&&"tw-pl-8",e),...n}));lo.displayName=pe.Item.displayName;const ar=g.forwardRef(({className:e,children:t,checked:n,...r},o)=>a.jsxs(pe.CheckboxItem,{ref:o,className:N("tw-relative tw-flex tw-cursor-default tw-select-none tw-items-center tw-rounded-sm tw-py-1.5 tw-pl-8 tw-pr-2 tw-text-sm tw-outline-none tw-transition-colors focus:tw-bg-accent focus:tw-text-accent-foreground data-[disabled]:tw-pointer-events-none data-[disabled]:tw-opacity-50",e),checked:n,...r,children:[a.jsx("span",{className:"tw-absolute tw-left-2 tw-flex tw-h-3.5 tw-w-3.5 tw-items-center tw-justify-center",children:a.jsx(pe.ItemIndicator,{children:a.jsx(ee.Check,{className:"tw-h-4 tw-w-4"})})}),t]}));ar.displayName=pe.CheckboxItem.displayName;const co=g.forwardRef(({className:e,children:t,...n},r)=>a.jsxs(pe.RadioItem,{ref:r,className:N("tw-relative tw-flex tw-cursor-default tw-select-none tw-items-center tw-rounded-sm tw-py-1.5 tw-pl-8 tw-pr-2 tw-text-sm tw-outline-none tw-transition-colors focus:tw-bg-accent focus:tw-text-accent-foreground data-[disabled]:tw-pointer-events-none data-[disabled]:tw-opacity-50",e),...n,children:[a.jsx("span",{className:"tw-absolute tw-left-2 tw-flex tw-h-3.5 tw-w-3.5 tw-items-center tw-justify-center",children:a.jsx(pe.ItemIndicator,{children:a.jsx(ee.Circle,{className:"tw-h-2 tw-w-2 tw-fill-current"})})}),t]}));co.displayName=pe.RadioItem.displayName;const Yt=g.forwardRef(({className:e,inset:t,...n},r)=>a.jsx(pe.Label,{ref:r,className:N("tw-px-2 tw-py-1.5 tw-text-sm tw-font-semibold",t&&"tw-pl-8",e),...n}));Yt.displayName=pe.Label.displayName;const jn=g.forwardRef(({className:e,...t},n)=>a.jsx(pe.Separator,{ref:n,className:N("tw--mx-1 tw-my-1 tw-h-px tw-bg-muted",e),...t}));jn.displayName=pe.Separator.displayName;function us({className:e,...t}){return a.jsx("span",{className:N("tw-ml-auto tw-text-xs tw-tracking-widest tw-opacity-60",e),...t})}us.displayName="DropdownMenuShortcut";const ql=g.forwardRef(({bookId:e,handleSelectBook:t,isSelected:n,handleHighlightBook:r,handleKeyDown:o,bookType:s,children:i},l)=>a.jsxs(lo,{ref:l,textValue:e,className:N("tw-mx-1 tw-px-1 tw-font-normal tw-text-foreground/80",{"tw-bg-amber-50 tw-text-yellow-900 data-[highlighted]:tw-bg-amber-100":n}),onSelect:c=>{c.preventDefault(),t()},onKeyDown:c=>{o(c)},onFocus:r,onMouseMove:r,children:[a.jsx("span",{className:N("tw-border-b-0 tw-border-l-2 tw-border-r-0 tw-border-t-0 tw-border-solid tw-px-2",{"tw-font-bold":n,"tw-border-l-red-200":s.toLowerCase()==="ot","tw-border-l-purple-200":s.toLowerCase()==="nt","tw-border-l-indigo-200":s.toLowerCase()==="dc"}),children:ae.bookIdToEnglishName(e)}),n&&a.jsx("div",{children:i})]},e));function Hl({handleSelectChapter:e,endChapter:t,activeChapter:n,highlightedChapter:r,handleHighlightedChapter:o}){const s=Array.from({length:t},(l,c)=>c+1),i=g.useCallback(l=>{o(l)},[o]);return a.jsx("div",{className:N("tw-flex tw-flex-wrap tw-items-start tw-justify-start tw-self-stretch"),children:s.map(l=>a.jsx("div",{className:N("tw-box-content tw-flex tw-h-4 tw-w-4 tw-cursor-pointer tw-items-center tw-justify-end tw-rounded-md tw-p-2 tw-text-amber-800",{"tw-font-semibold tw-text-amber-900":l===n,"tw-bg-amber-200":l===r}),onClick:c=>{c.preventDefault(),c.stopPropagation(),e(l)},role:"button",onKeyDown:c=>{c.key==="Enter"&&e(l)},tabIndex:0,onMouseMove:()=>i(l),children:l},l))})}function Xl({handleSort:e,handleLocationHistory:t,handleBookmarks:n}){return a.jsxs(Yt,{className:"tw-flex tw-justify-between",children:[a.jsx("p",{className:"tw-inline-block tw-align-middle",children:"Go To"}),a.jsxs("div",{className:"tw-flex tw-items-center",children:[a.jsx(ee.ArrowDownWideNarrow,{onClick:e,className:"tw-m-2 tw-h-4 tw-w-4 tw-cursor-pointer tw-gap-2"}),a.jsx(ee.Clock,{onClick:t,className:"tw-m-2 tw-h-4 tw-w-4 tw-cursor-pointer tw-gap-2"}),a.jsx(ee.Bookmark,{onClick:n,className:"tw-m-2 tw-h-4 tw-w-4 tw-cursor-pointer tw-gap-2"})]})]})}const pn=ae.allBookIds,Yl={OT:"Old Testament",NT:"New Testament",DC:"Deuterocanon"},oa=["OT","NT","DC"],Wl=32+32+32,Kl=[/^(\w+)$/i,/^(\w+)(?:\s(\d+))$/i,/^(\w+)(?:\s(\d+):(\d+))$/i],Jl=e=>({OT:pn.filter(n=>ae.isBookOT(n)),NT:pn.filter(n=>ae.isBookNT(n)),DC:pn.filter(n=>ae.isBookDC(n))})[e],nn=e=>W.getChaptersForBook(ae.bookIdToNumber(e));function Zl(){return pn.map(t=>ae.bookIdToEnglishName(t))}function Ql(e){return Zl().includes(e)}function ec(e){const t=e.toLowerCase().replace(/^\w/,n=>n.toUpperCase());if(Ql(t))return pn.find(r=>ae.bookIdToEnglishName(r)===t)}function tc({scrRef:e,handleSubmit:t}){const[n,r]=g.useState(""),[o,s]=g.useState(ae.bookNumberToId(e.bookNum)),[i,l]=g.useState(e.chapterNum??0),[c,d]=g.useState(ae.bookNumberToId(e.bookNum)),[u,f]=g.useState(!1),[w,b]=g.useState(u),x=g.useRef(void 0),m=g.useRef(void 0),h=g.useRef(void 0),E=g.useCallback(k=>Jl(k).filter(A=>{const M=ae.bookIdToEnglishName(A).toLowerCase(),J=n.replace(/[^a-zA-Z]/g,"").toLowerCase();return M.includes(J)||A.toLowerCase().includes(J)}),[n]),I=k=>{r(k)},C=g.useRef(!1),S=g.useCallback(k=>{if(C.current){C.current=!1;return}f(k)},[]),v=g.useCallback((k,A,M,J)=>{if(l(ae.bookNumberToId(e.bookNum)!==k?1:e.chapterNum),A||nn(k)===-1){t({bookNum:ae.bookIdToNumber(k),chapterNum:M||1,verseNum:J||1}),f(!1),r("");return}s(o!==k?k:""),f(!A)},[t,e.bookNum,e.chapterNum,o]),_=k=>{k<=0||k>nn(o)||v(o,!0,k)},V=g.useCallback(()=>{Kl.forEach(k=>{const A=n.match(k);if(A){const[M,J=void 0,Y=void 0]=A.slice(1),F=ec(M);(ae.isBookIdValid(M)||F)&&v(F??M,!0,J?parseInt(J,10):1,Y?parseInt(Y,10):1)}})},[v,n]),U=g.useCallback(k=>{u?(k.key==="ArrowDown"||k.key==="ArrowUp")&&(typeof h<"u"&&h.current!==null?h.current.focus():typeof m<"u"&&m.current!==null&&m.current.focus(),k.preventDefault()):f(!0)},[u]),j=k=>{const{key:A}=k;A==="ArrowRight"||A==="ArrowLeft"||A==="ArrowDown"||A==="ArrowUp"||A==="Enter"||(x.current.dispatchEvent(new KeyboardEvent("keydown",{key:A})),x.current.focus())},O=k=>{const{key:A}=k;if(c===o){if(A==="Enter"){k.preventDefault(),v(o,!0,i);return}let M=0;if(A==="ArrowRight")if(i1)M=-1;else{k.preventDefault();return}else A==="ArrowDown"?M=6:A==="ArrowUp"&&(M=-6);i+M<=0||i+M>nn(c)?l(0):M!==0&&(l(i+M),k.preventDefault())}};return g.useEffect(()=>{o===c?o===ae.bookNumberToId(e.bookNum)?l(e.chapterNum):l(1):l(0)},[c,e.bookNum,e.chapterNum,o]),g.useLayoutEffect(()=>{b(u)},[u]),g.useLayoutEffect(()=>{const k=setTimeout(()=>{if(w&&m.current&&h.current){const M=h.current.offsetTop-Wl;m.current.scrollTo({top:M,behavior:"instant"})}},10);return()=>{clearTimeout(k)}},[w]),a.jsx("div",{className:"pr-twp tw-flex",children:a.jsxs(or,{modal:!1,open:u,onOpenChange:S,children:[a.jsx(io,{asChild:!0,children:a.jsx(Rl,{ref:x,value:n,handleSearch:I,handleKeyDown:U,handleOnClick:()=>{s(ae.bookNumberToId(e.bookNum)),d(ae.bookNumberToId(e.bookNum)),l(e.chapterNum>0?e.chapterNum:0),f(!0),x.current.focus()},onFocus:()=>{C.current=!0},handleSubmit:V,placeholder:`${ae.bookNumberToEnglishName(e.bookNum)} ${e.chapterNum}:${e.verseNum}`})}),a.jsxs(En,{className:"tw-m-1 tw-overflow-y-auto tw-p-0 tw-font-normal tw-text-foreground/80",style:{width:"233px",maxHeight:"500px",zIndex:"250"},onKeyDown:j,align:"start",ref:m,children:[a.jsx(Xl,{handleSort:()=>console.log("sorting"),handleLocationHistory:()=>console.log("location history"),handleBookmarks:()=>console.log("bookmarks")}),oa.map((k,A)=>E(k).length>0&&a.jsxs("div",{children:[a.jsx(Yt,{className:"tw-font-semibold tw-text-foreground/80",children:Yl[k]}),E(k).map(M=>a.jsx("div",{children:a.jsx(ql,{bookId:M,handleSelectBook:()=>v(M,!1),isSelected:o===M,handleHighlightBook:()=>d(M),handleKeyDown:O,bookType:k,ref:J=>{o===M&&(h.current=J)},children:a.jsx(Hl,{handleSelectChapter:_,endChapter:nn(M),activeChapter:e.bookNum===ae.bookIdToNumber(M)?e.chapterNum:0,highlightedChapter:i,handleHighlightedChapter:J=>{l(J)}})})},M)),oa.length-1!==A?a.jsx(jn,{}):void 0]},k))]})]})})}const ps=kn.cva("pr-twp tw-inline-flex tw-items-center tw-justify-center tw-whitespace-nowrap tw-rounded-md tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-colors focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50",{variants:{variant:{default:"tw-bg-primary tw-text-primary-foreground hover:tw-bg-primary/90",destructive:"tw-bg-destructive tw-text-destructive-foreground hover:tw-bg-destructive/90",outline:"tw-border tw-border-input tw-bg-background hover:tw-bg-accent hover:tw-text-accent-foreground",secondary:"tw-bg-secondary tw-text-secondary-foreground hover:tw-bg-secondary/80",ghost:"hover:tw-bg-accent hover:tw-text-accent-foreground",link:"tw-text-primary tw-underline-offset-4 hover:tw-underline"},size:{default:"tw-h-10 tw-px-4 tw-py-2",sm:"tw-h-9 tw-rounded-md tw-px-3",lg:"tw-h-11 tw-rounded-md tw-px-8",icon:"tw-h-10 tw-w-10"}},defaultVariants:{variant:"default",size:"default"}}),fe=g.forwardRef(({className:e,variant:t,size:n,asChild:r=!1,...o},s)=>{const i=r?Ht.Slot:"button";return a.jsx(i,{className:N(ps({variant:t,size:n,className:e})),ref:s,...o})});fe.displayName="Button";const nc=kn.cva("tw-text-sm tw-font-medium tw-leading-none peer-disabled:tw-cursor-not-allowed peer-disabled:tw-opacity-70"),Ue=g.forwardRef(({className:e,...t},n)=>a.jsx(Qa.Root,{ref:n,className:N("pr-twp",nc(),e),...t}));Ue.displayName=Qa.Root.displayName;const uo=g.forwardRef(({className:e,...t},n)=>a.jsx(gn.Root,{className:N("pr-twp tw-grid tw-gap-2",e),...t,ref:n}));uo.displayName=gn.Root.displayName;const Yn=g.forwardRef(({className:e,...t},n)=>a.jsx(gn.Item,{ref:n,className:N("pr-twp tw-aspect-square tw-h-4 tw-w-4 tw-rounded-full tw-border tw-border-primary tw-text-primary tw-ring-offset-background focus:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-cursor-not-allowed disabled:tw-opacity-50",e),...t,children:a.jsx(gn.Indicator,{className:"tw-flex tw-items-center tw-justify-center",children:a.jsx(ee.Circle,{className:"tw-h-2.5 tw-w-2.5 tw-fill-current tw-text-current"})})}));Yn.displayName=gn.Item.displayName;const rc=bn.Root,oc=bn.Trigger,ws=g.forwardRef(({className:e,align:t="center",sideOffset:n=4,...r},o)=>a.jsx(bn.Portal,{children:a.jsx(bn.Content,{ref:o,align:t,sideOffset:n,className:N("pr-twp tw-z-50 tw-w-72 tw-rounded-md tw-border tw-bg-popover tw-p-4 tw-text-popover-foreground tw-shadow-md tw-outline-none data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0 data-[state=closed]:tw-zoom-out-95 data-[state=open]:tw-zoom-in-95 data-[side=bottom]:tw-slide-in-from-top-2 data-[side=left]:tw-slide-in-from-right-2 data-[side=right]:tw-slide-in-from-left-2 data-[side=top]:tw-slide-in-from-bottom-2",e),...r})}));ws.displayName=bn.Content.displayName;const ac=Xe.Portal,fs=g.forwardRef(({className:e,...t},n)=>a.jsx(Xe.Overlay,{ref:n,className:N("tw-fixed tw-inset-0 tw-z-50 tw-bg-black/80 data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0",e),...t}));fs.displayName=Xe.Overlay.displayName;const sc=g.forwardRef(({className:e,children:t,...n},r)=>a.jsxs(ac,{children:[a.jsx(fs,{}),a.jsxs(Xe.Content,{ref:r,className:N("tw-fixed tw-left-[50%] tw-top-[50%] tw-z-50 tw-grid tw-w-full tw-max-w-lg tw-translate-x-[-50%] tw-translate-y-[-50%] tw-gap-4 tw-border tw-bg-background tw-p-6 tw-shadow-lg tw-duration-200 data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0 data-[state=closed]:tw-zoom-out-95 data-[state=open]:tw-zoom-in-95 data-[state=closed]:tw-slide-out-to-left-1/2 data-[state=closed]:tw-slide-out-to-top-[48%] data-[state=open]:tw-slide-in-from-left-1/2 data-[state=open]:tw-slide-in-from-top-[48%] sm:tw-rounded-lg",e),...n,children:[t,a.jsxs(Xe.Close,{className:"tw-absolute tw-right-4 tw-top-4 tw-rounded-sm tw-opacity-70 tw-ring-offset-background tw-transition-opacity hover:tw-opacity-100 focus:tw-outline-none focus:tw-ring-2 focus:tw-ring-ring focus:tw-ring-offset-2 disabled:tw-pointer-events-none data-[state=open]:tw-bg-accent data-[state=open]:tw-text-muted-foreground",children:[a.jsx(ee.X,{className:"tw-h-4 tw-w-4"}),a.jsx("span",{className:"tw-sr-only",children:"Close"})]})]})]}));sc.displayName=Xe.Content.displayName;const ic=g.forwardRef(({className:e,...t},n)=>a.jsx(Xe.Title,{ref:n,className:N("tw-text-lg tw-font-semibold tw-leading-none tw-tracking-tight",e),...t}));ic.displayName=Xe.Title.displayName;const lc=g.forwardRef(({className:e,...t},n)=>a.jsx(Xe.Description,{ref:n,className:N("tw-text-sm tw-text-muted-foreground",e),...t}));lc.displayName=Xe.Description.displayName;const ms=g.forwardRef(({className:e,...t},n)=>a.jsx(Ce.Command,{ref:n,className:N("tw-flex tw-h-full tw-w-full tw-flex-col tw-overflow-hidden tw-rounded-md tw-bg-popover tw-text-popover-foreground",e),...t}));ms.displayName=Ce.Command.displayName;const hs=g.forwardRef(({className:e,...t},n)=>a.jsxs("div",{className:"tw-flex tw-items-center tw-border-b tw-px-3",children:[a.jsx(ee.Search,{className:"tw-me-2 tw-h-4 tw-w-4 tw-shrink-0 tw-opacity-50"}),a.jsx(Ce.Command.Input,{ref:n,className:N("tw-flex tw-h-11 tw-w-full tw-rounded-md tw-bg-transparent tw-py-3 tw-text-sm tw-outline-none placeholder:tw-text-muted-foreground disabled:tw-cursor-not-allowed disabled:tw-opacity-50",e),...t})]}));hs.displayName=Ce.Command.Input.displayName;const gs=g.forwardRef(({className:e,...t},n)=>a.jsx(Ce.Command.List,{ref:n,className:N("tw-max-h-[300px] tw-overflow-y-auto tw-overflow-x-hidden",e),...t}));gs.displayName=Ce.Command.List.displayName;const bs=g.forwardRef((e,t)=>a.jsx(Ce.Command.Empty,{ref:t,className:"tw-py-6 tw-text-center tw-text-sm",...e}));bs.displayName=Ce.Command.Empty.displayName;const cc=g.forwardRef(({className:e,...t},n)=>a.jsx(Ce.Command.Group,{ref:n,className:N("tw-overflow-hidden tw-p-1 tw-text-foreground [&_[cmdk-group-heading]]:tw-px-2 [&_[cmdk-group-heading]]:tw-py-1.5 [&_[cmdk-group-heading]]:tw-text-xs [&_[cmdk-group-heading]]:tw-font-medium [&_[cmdk-group-heading]]:tw-text-muted-foreground",e),...t}));cc.displayName=Ce.Command.Group.displayName;const dc=g.forwardRef(({className:e,...t},n)=>a.jsx(Ce.Command.Separator,{ref:n,className:N("tw--mx-1 tw-h-px tw-bg-border",e),...t}));dc.displayName=Ce.Command.Separator.displayName;const vs=g.forwardRef(({className:e,...t},n)=>a.jsx(Ce.Command.Item,{ref:n,className:N("tw-relative tw-flex tw-cursor-default tw-select-none tw-items-center tw-rounded-sm tw-px-2 tw-py-1.5 tw-text-sm tw-outline-none data-[disabled=true]:tw-pointer-events-none data-[selected=true]:tw-bg-accent data-[selected=true]:tw-text-accent-foreground data-[disabled=true]:tw-opacity-50",e),...t}));vs.displayName=Ce.Command.Item.displayName;function uc(e){return typeof e=="string"?e:typeof e=="number"?e.toString():e.label}function Wn({id:e,options:t=[],buttonClassName:n,popoverContentClassName:r,value:o,onChange:s=()=>{},getOptionLabel:i=uc,buttonPlaceholder:l="",textPlaceholder:c="",commandEmptyMessage:d="No option found",buttonVariant:u="outline",dir:f="ltr",isDisabled:w=!1,...b}){const[x,m]=g.useState(!1);return a.jsxs(rc,{open:x,onOpenChange:m,...b,children:[a.jsx(oc,{asChild:!0,children:a.jsxs(fe,{variant:u,role:"combobox","aria-expanded":x,id:e,className:N("tw-w-[200px] tw-justify-between",n),disabled:w,children:[a.jsx("span",{className:"tw-overflow-hidden tw-text-ellipsis tw-whitespace-nowrap",children:o?i(o):l}),a.jsx(ee.ChevronsUpDown,{className:"tw-ms-2 tw-h-4 tw-w-4 tw-shrink-0 tw-opacity-50"})]})}),a.jsx(ws,{className:N("tw-w-[200px] tw-p-0",r),dir:f,children:a.jsxs(ms,{children:[a.jsx(hs,{dir:f,placeholder:c,className:"tw-text-inherit"}),a.jsx(bs,{children:d}),a.jsx(gs,{children:t.map(h=>a.jsxs(vs,{value:i(h),onSelect:()=>{s(h),m(!1)},children:[a.jsx(ee.Check,{className:N("tw-me-2 tw-h-4 tw-w-4",{"tw-opacity-0":!o||i(o)!==i(h)})}),i(h)]},i(h)))})]})})]})}function xs({startChapter:e,endChapter:t,handleSelectStartChapter:n,handleSelectEndChapter:r,isDisabled:o=!1,chapterCount:s}){const i=g.useMemo(()=>Array.from({length:s},(d,u)=>u+1),[s]),l=d=>{n(d),d>t&&r(d)},c=d=>{r(d),dd.toString(),value:e},"start chapter"),a.jsx(Ue,{htmlFor:"end-chapters-combobox",children:"to"}),a.jsx(Wn,{isDisabled:o,onChange:c,buttonClassName:"tw-ml-2 tw-w-20",options:i,getOptionLabel:d=>d.toString(),value:t},"end chapter")]})}var ys=(e=>(e.CURRENT_BOOK="current book",e.CHOOSE_BOOKS="choose books",e))(ys||{});const pc=Object.freeze(["%webView_bookSelector_currentBook%","%webView_bookSelector_choose%","%webView_bookSelector_chooseBooks%"]),Cr=(e,t)=>e[t]??t;function wc({handleBookSelectionModeChange:e,currentBookName:t,onSelectBooks:n,selectedBookIds:r,chapterCount:o,endChapter:s,handleSelectEndChapter:i,startChapter:l,handleSelectStartChapter:c,localizedStrings:d}){const u=Cr(d,"%webView_bookSelector_currentBook%"),f=Cr(d,"%webView_bookSelector_choose%"),w=Cr(d,"%webView_bookSelector_chooseBooks%"),[b,x]=g.useState("current book"),m=h=>{x(h),e(h)};return a.jsx(uo,{className:"pr-twp tw-flex",value:b,onValueChange:h=>m(h),children:a.jsxs("div",{className:"tw-flex tw-w-full tw-flex-col tw-gap-4",children:[a.jsxs("div",{className:"tw-grid tw-grid-cols-[25%,25%,50%]",children:[a.jsxs("div",{className:"tw-flex tw-items-center",children:[a.jsx(Yn,{value:"current book"}),a.jsx(Ue,{className:"tw-ml-1",children:u})]}),a.jsx(Ue,{className:"tw-flex tw-items-center",children:t}),a.jsx("div",{className:"tw-flex tw-items-center tw-justify-end",children:a.jsx(xs,{isDisabled:b==="choose books",handleSelectStartChapter:c,handleSelectEndChapter:i,chapterCount:o,startChapter:l,endChapter:s})})]}),a.jsxs("div",{className:"tw-grid tw-grid-cols-[25%,50%,25%]",children:[a.jsxs("div",{className:"tw-flex tw-items-center",children:[a.jsx(Yn,{value:"choose books"}),a.jsx(Ue,{className:"tw-ml-1",children:w})]}),a.jsx(Ue,{className:"tw-flex tw-items-center",children:r.map(h=>ae.bookIdToEnglishName(h)).join(", ")}),a.jsx(fe,{disabled:b==="current book",onClick:()=>n(),children:f})]})]})})}function fc({table:e}){return a.jsxs(or,{children:[a.jsx(Ja.DropdownMenuTrigger,{asChild:!0,children:a.jsxs(fe,{variant:"outline",size:"sm",className:"tw-ml-auto tw-hidden tw-h-8 lg:tw-flex",children:[a.jsx(ee.FilterIcon,{className:"tw-mr-2 tw-h-4 tw-w-4"}),"View"]})}),a.jsxs(En,{align:"end",className:"tw-w-[150px]",children:[a.jsx(Yt,{children:"Toggle columns"}),a.jsx(jn,{}),e.getAllColumns().filter(t=>t.getCanHide()).map(t=>a.jsx(ar,{className:"tw-capitalize",checked:t.getIsVisible(),onCheckedChange:n=>t.toggleVisibility(!!n),children:t.id},t.id))]})]})}const Dt=ge.Root,Ns=ge.Group,Bt=ge.Value,bt=g.forwardRef(({className:e,children:t,...n},r)=>a.jsxs(ge.Trigger,{ref:r,className:N("tw-flex tw-h-10 tw-w-full tw-items-center tw-justify-between tw-rounded-md tw-border tw-border-input tw-bg-background tw-px-3 tw-py-2 tw-text-sm tw-ring-offset-background placeholder:tw-text-muted-foreground focus:tw-outline-none focus:tw-ring-2 focus:tw-ring-ring focus:tw-ring-offset-2 disabled:tw-cursor-not-allowed disabled:tw-opacity-50 [&>span]:tw-line-clamp-1",e),...n,children:[t,a.jsx(ge.Icon,{asChild:!0,children:a.jsx(ee.ChevronDown,{className:"tw-h-4 tw-w-4 tw-opacity-50"})})]}));bt.displayName=ge.Trigger.displayName;const po=g.forwardRef(({className:e,...t},n)=>a.jsx(ge.ScrollUpButton,{ref:n,className:N("tw-flex tw-cursor-default tw-items-center tw-justify-center tw-py-1",e),...t,children:a.jsx(ee.ChevronUp,{className:"tw-h-4 tw-w-4"})}));po.displayName=ge.ScrollUpButton.displayName;const wo=g.forwardRef(({className:e,...t},n)=>a.jsx(ge.ScrollDownButton,{ref:n,className:N("tw-flex tw-cursor-default tw-items-center tw-justify-center tw-py-1",e),...t,children:a.jsx(ee.ChevronDown,{className:"tw-h-4 tw-w-4"})}));wo.displayName=ge.ScrollDownButton.displayName;const vt=g.forwardRef(({className:e,children:t,position:n="popper",...r},o)=>a.jsx(ge.Portal,{children:a.jsxs(ge.Content,{ref:o,className:N("pr-twp tw-relative tw-z-50 tw-max-h-96 tw-min-w-[8rem] tw-overflow-hidden tw-rounded-md tw-border tw-bg-popover tw-text-popover-foreground tw-shadow-md data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0 data-[state=closed]:tw-zoom-out-95 data-[state=open]:tw-zoom-in-95 data-[side=bottom]:tw-slide-in-from-top-2 data-[side=left]:tw-slide-in-from-right-2 data-[side=right]:tw-slide-in-from-left-2 data-[side=top]:tw-slide-in-from-bottom-2",n==="popper"&&"data-[side=bottom]:tw-translate-y-1 data-[side=left]:tw--translate-x-1 data-[side=right]:tw-translate-x-1 data-[side=top]:tw--translate-y-1",e),position:n,...r,children:[a.jsx(po,{}),a.jsx(ge.Viewport,{className:N("tw-p-1",n==="popper"&&"tw-h-[var(--radix-select-trigger-height)] tw-w-full tw-min-w-[var(--radix-select-trigger-width)]"),children:t}),a.jsx(wo,{})]})}));vt.displayName=ge.Content.displayName;const ks=g.forwardRef(({className:e,...t},n)=>a.jsx(ge.Label,{ref:n,className:N("tw-py-1.5 tw-pl-8 tw-pr-2 tw-text-sm tw-font-semibold",e),...t}));ks.displayName=ge.Label.displayName;const Ae=g.forwardRef(({className:e,children:t,...n},r)=>a.jsxs(ge.Item,{ref:r,className:N("tw-relative tw-flex tw-w-full tw-cursor-default tw-select-none tw-items-center tw-rounded-sm tw-py-1.5 tw-pl-8 tw-pr-2 tw-text-sm tw-outline-none focus:tw-bg-accent focus:tw-text-accent-foreground data-[disabled]:tw-pointer-events-none data-[disabled]:tw-opacity-50",e),...n,children:[a.jsx("span",{className:"tw-absolute tw-left-2 tw-flex tw-h-3.5 tw-w-3.5 tw-items-center tw-justify-center",children:a.jsx(ge.ItemIndicator,{children:a.jsx(ee.Check,{className:"tw-h-4 tw-w-4"})})}),a.jsx(ge.ItemText,{children:t})]}));Ae.displayName=ge.Item.displayName;const Ss=g.forwardRef(({className:e,...t},n)=>a.jsx(ge.Separator,{ref:n,className:N("tw--mx-1 tw-my-1 tw-h-px tw-bg-muted",e),...t}));Ss.displayName=ge.Separator.displayName;function mc({table:e}){return a.jsx("div",{className:"tw-flex tw-items-center tw-justify-between tw-px-2 tw-pb-3 tw-pt-3",children:a.jsxs("div",{className:"tw-flex tw-items-center tw-space-x-6 lg:tw-space-x-8",children:[a.jsxs("div",{className:"tw-flex-1 tw-text-sm tw-text-muted-foreground",children:[e.getFilteredSelectedRowModel().rows.length," of"," ",e.getFilteredRowModel().rows.length," row(s) selected"]}),a.jsxs("div",{className:"tw-flex tw-items-center tw-space-x-2",children:[a.jsx("p",{className:"tw-text-nowrap tw-text-sm tw-font-medium",children:"Rows per page"}),a.jsxs(Dt,{value:`${e.getState().pagination.pageSize}`,onValueChange:t=>{e.setPageSize(Number(t))},children:[a.jsx(bt,{className:"tw-h-8 tw-w-[70px]",children:a.jsx(Bt,{placeholder:e.getState().pagination.pageSize})}),a.jsx(vt,{side:"top",children:[10,20,30,40,50].map(t=>a.jsx(Ae,{value:`${t}`,children:t},t))})]})]}),a.jsxs("div",{className:"tw-flex tw-w-[100px] tw-items-center tw-justify-center tw-text-sm tw-font-medium",children:["Page ",e.getState().pagination.pageIndex+1," of ",e.getPageCount()]}),a.jsxs("div",{className:"tw-flex tw-items-center tw-space-x-2",children:[a.jsxs(fe,{variant:"outline",size:"icon",className:"tw-hidden tw-h-8 tw-w-8 tw-p-0 lg:tw-flex",onClick:()=>e.setPageIndex(0),disabled:!e.getCanPreviousPage(),children:[a.jsx("span",{className:"tw-sr-only",children:"Go to first page"}),a.jsx(ee.ArrowLeftIcon,{className:"tw-h-4 tw-w-4"})]}),a.jsxs(fe,{variant:"outline",size:"icon",className:"tw-h-8 tw-w-8 tw-p-0",onClick:()=>e.previousPage(),disabled:!e.getCanPreviousPage(),children:[a.jsx("span",{className:"tw-sr-only",children:"Go to previous page"}),a.jsx(ee.ChevronLeftIcon,{className:"tw-h-4 tw-w-4"})]}),a.jsxs(fe,{variant:"outline",size:"icon",className:"tw-h-8 tw-w-8 tw-p-0",onClick:()=>e.nextPage(),disabled:!e.getCanNextPage(),children:[a.jsx("span",{className:"tw-sr-only",children:"Go to next page"}),a.jsx(ee.ChevronRightIcon,{className:"tw-h-4 tw-w-4"})]}),a.jsxs(fe,{variant:"outline",size:"icon",className:"tw-hidden tw-h-8 tw-w-8 tw-p-0 lg:tw-flex",onClick:()=>e.setPageIndex(e.getPageCount()-1),disabled:!e.getCanNextPage(),children:[a.jsx("span",{className:"tw-sr-only",children:"Go to last page"}),a.jsx(ee.ArrowRightIcon,{className:"tw-h-4 tw-w-4"})]})]})]})})}const Tn=g.forwardRef(({className:e,stickyHeader:t,...n},r)=>a.jsx("div",{className:N("pr-twp tw-relative tw-w-full",{"tw-overflow-auto":!t}),children:a.jsx("table",{ref:r,className:N("tw-w-full tw-caption-bottom tw-text-sm",e),...n})}));Tn.displayName="Table";const Cn=g.forwardRef(({className:e,stickyHeader:t,...n},r)=>a.jsx("thead",{ref:r,className:N({"tw-sticky tw-top-[-1px] tw-bg-background tw-drop-shadow-sm":t},"[&_tr]:tw-border-b",e),...n}));Cn.displayName="TableHeader";const Rn=g.forwardRef(({className:e,...t},n)=>a.jsx("tbody",{ref:n,className:N("[&_tr:last-child]:tw-border-0",e),...t}));Rn.displayName="TableBody";const Es=g.forwardRef(({className:e,...t},n)=>a.jsx("tfoot",{ref:n,className:N("tw-border-t tw-bg-muted/50 tw-font-medium [&>tr]:last:tw-border-b-0",e),...t}));Es.displayName="TableFooter";const Ze=g.forwardRef(({className:e,...t},n)=>a.jsx("tr",{ref:n,className:N("tw-border-b tw-transition-colors hover:tw-bg-muted/50 data-[state=selected]:tw-bg-muted",e),...t}));Ze.displayName="TableRow";const Vt=g.forwardRef(({className:e,...t},n)=>a.jsx("th",{ref:n,className:N("tw-h-12 tw-px-4 tw-text-start tw-align-middle tw-font-medium tw-text-muted-foreground [&:has([role=checkbox])]:tw-pe-0",e),...t}));Vt.displayName="TableHead";const xt=g.forwardRef(({className:e,...t},n)=>a.jsx("td",{ref:n,className:N("tw-p-4 tw-align-middle [&:has([role=checkbox])]:tw-pe-0",e),...t}));xt.displayName="TableCell";const js=g.forwardRef(({className:e,...t},n)=>a.jsx("caption",{ref:n,className:N("tw-mt-4 tw-text-sm tw-text-muted-foreground",e),...t}));js.displayName="TableCaption";function Ts({columns:e,data:t,enablePagination:n=!1,showPaginationControls:r=!1,showColumnVisibilityControls:o=!1,stickyHeader:s=!1,onRowClickHandler:i=()=>{}}){var h;const[l,c]=g.useState([]),[d,u]=g.useState([]),[f,w]=g.useState({}),[b,x]=g.useState({}),m=ke.useReactTable({data:t,columns:e,getCoreRowModel:ke.getCoreRowModel(),...n&&{getPaginationRowModel:ke.getPaginationRowModel()},onSortingChange:c,getSortedRowModel:ke.getSortedRowModel(),onColumnFiltersChange:u,getFilteredRowModel:ke.getFilteredRowModel(),onColumnVisibilityChange:w,onRowSelectionChange:x,state:{sorting:l,columnFilters:d,columnVisibility:f,rowSelection:b}});return a.jsxs("div",{className:"pr-twp",children:[o&&a.jsx(fc,{table:m}),a.jsxs(Tn,{stickyHeader:s,children:[a.jsx(Cn,{stickyHeader:s,children:m.getHeaderGroups().map(E=>a.jsx(Ze,{children:E.headers.map(I=>a.jsx(Vt,{children:I.isPlaceholder?void 0:ke.flexRender(I.column.columnDef.header,I.getContext())},I.id))},E.id))}),a.jsx(Rn,{children:(h=m.getRowModel().rows)!=null&&h.length?m.getRowModel().rows.map(E=>a.jsx(Ze,{onClick:()=>i(E,m),"data-state":E.getIsSelected()&&"selected",children:E.getVisibleCells().map(I=>a.jsx(xt,{children:ke.flexRender(I.column.columnDef.cell,I.getContext())},I.id))},E.id)):a.jsx(Ze,{children:a.jsx(xt,{colSpan:e.length,className:"tw-h-24 tw-text-center",children:"No results."})})})]}),n&&a.jsxs("div",{className:"tw-flex tw-items-center tw-justify-end tw-space-x-2 tw-py-4",children:[a.jsx(fe,{variant:"outline",size:"sm",onClick:()=>m.previousPage(),disabled:!m.getCanPreviousPage(),children:"Previous"}),a.jsx(fe,{variant:"outline",size:"sm",onClick:()=>m.nextPage(),disabled:!m.getCanNextPage(),children:"Next"})]}),n&&r&&a.jsx(mc,{table:m})]})}function hc({occurrenceData:e,setScriptureReference:t,localizedStrings:n}){const r=n["%webView_inventory_occurrences_table_header_reference%"],o=n["%webView_inventory_occurrences_table_header_occurrence%"],s=g.useMemo(()=>{const i=[];return e.forEach(l=>{i.some(c=>W.deepEqual(c,l))||i.push(l)}),i},[e]);return a.jsxs(Tn,{stickyHeader:!0,children:[a.jsx(Cn,{stickyHeader:!0,children:a.jsxs(Ze,{children:[a.jsx(Vt,{children:r}),a.jsx(Vt,{children:o})]})}),a.jsx(Rn,{children:s.length>0&&s.map(i=>a.jsxs(Ze,{onClick:()=>{t(i.reference)},children:[a.jsx(xt,{children:`${ae.bookNumberToEnglishName(i.reference.bookNum)} ${i.reference.chapterNum}:${i.reference.verseNum}`}),a.jsx(xt,{children:i.text})]},`${i.reference.bookNum} ${i.reference.chapterNum}:${i.reference.verseNum}-${i.text}`))})]})}const sr=g.forwardRef(({className:e,...t},n)=>a.jsx(Gr.Root,{ref:n,className:N("tw-peer pr-twp tw-h-4 tw-w-4 tw-shrink-0 tw-rounded-sm tw-border tw-border-primary tw-ring-offset-background focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-cursor-not-allowed disabled:tw-opacity-50 data-[state=checked]:tw-bg-primary data-[state=checked]:tw-text-primary-foreground",e),...t,children:a.jsx(Gr.Indicator,{className:N("tw-flex tw-items-center tw-justify-center tw-text-current"),children:a.jsx(ee.Check,{className:"tw-h-4 tw-w-4"})})}));sr.displayName=Gr.Root.displayName;const Cs=e=>e.split(/(?:\r?\n|\r)|(?=(?:\\(?:v|c|id)))/g),qr=e=>{const t=/^\\[vc]\s+(\d+)/,n=e.match(t);if(n)return+n[1]},Rs=e=>{const t=e.match(/^\\id\s+([A-Za-z]+)/);return t?ae.bookIdToNumber(t[1]):0},Os=(e,t,n)=>n.includes(e)?"unapproved":t.includes(e)?"approved":"unknown",_s=kn.cva("pr-twp tw-inline-flex tw-items-center tw-justify-center tw-rounded-md tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-colors hover:tw-bg-muted hover:tw-text-muted-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50 data-[state=on]:tw-bg-accent data-[state=on]:tw-text-accent-foreground",{variants:{variant:{default:"tw-bg-transparent",outline:"tw-border tw-border-input tw-bg-transparent hover:tw-bg-accent hover:tw-text-accent-foreground"},size:{default:"tw-h-10 tw-px-3",sm:"tw-h-9 tw-px-2.5",lg:"tw-h-11 tw-px-5"}},defaultVariants:{variant:"default",size:"default"}}),gc=g.forwardRef(({className:e,variant:t,size:n,...r},o)=>a.jsx(es.Root,{ref:o,className:N(_s({variant:t,size:n,className:e})),...r}));gc.displayName=es.Root.displayName;const Ps=g.createContext({size:"default",variant:"default"}),fo=g.forwardRef(({className:e,variant:t,size:n,children:r,...o},s)=>a.jsx(rr.Root,{ref:s,className:N("pr-twp tw-flex tw-items-center tw-justify-center tw-gap-1",e),...o,children:a.jsx(Ps.Provider,{value:{variant:t,size:n},children:r})}));fo.displayName=rr.Root.displayName;const wn=g.forwardRef(({className:e,children:t,variant:n,size:r,...o},s)=>{const i=g.useContext(Ps);return a.jsx(rr.Item,{ref:s,className:N(_s({variant:i.variant||n,size:i.size||r}),e),...o,children:t})});wn.displayName=rr.Item.displayName;const ir=e=>e==="asc"?a.jsx(ee.ArrowUpIcon,{className:"tw-ms-2 tw-h-4 tw-w-4"}):e==="desc"?a.jsx(ee.ArrowDownIcon,{className:"tw-ms-2 tw-h-4 tw-w-4"}):a.jsx(ee.ArrowUpDownIcon,{className:"tw-ms-2 tw-h-4 tw-w-4"}),bc=e=>({accessorKey:"item",accessorFn:t=>t.items[0],header:({column:t})=>a.jsxs(fe,{variant:"ghost",onClick:()=>t.toggleSorting(void 0),children:[e,ir(t.getIsSorted())]})}),vc=(e,t)=>({accessorKey:`item${t}`,accessorFn:n=>n.items[t],header:({column:n})=>a.jsxs(fe,{variant:"ghost",onClick:()=>n.toggleSorting(void 0),children:[e,ir(n.getIsSorted())]})}),xc=e=>({accessorKey:"count",header:({column:t})=>a.jsx("div",{className:"tw-flex tw-justify-end tw-tabular-nums",children:a.jsxs(fe,{variant:"ghost",onClick:()=>t.toggleSorting(void 0),children:[e,ir(t.getIsSorted())]})}),cell:({row:t})=>a.jsx("div",{className:"tw-flex tw-justify-end",children:t.getValue("count")})}),Rr=(e,t,n,r,o,s)=>{let i=[...n];e.forEach(c=>{t==="approved"?i.includes(c)||i.push(c):i=i.filter(d=>d!==c)}),r(i);let l=[...o];e.forEach(c=>{t==="unapproved"?l.includes(c)||l.push(c):l=l.filter(d=>d!==c)}),s(l)},yc=(e,t,n,r,o)=>({accessorKey:"status",header:({column:s})=>a.jsx("div",{className:"tw-flex tw-justify-center",children:a.jsxs(fe,{variant:"ghost",onClick:()=>s.toggleSorting(void 0),children:[e,ir(s.getIsSorted())]})}),cell:({row:s})=>{const i=s.getValue("status"),l=s.getValue("item");return a.jsxs(fo,{value:i,variant:"outline",type:"single",children:[a.jsx(wn,{onClick:()=>Rr([l],"approved",t,n,r,o),value:"approved",children:a.jsx(ee.CircleCheckIcon,{})}),a.jsx(wn,{onClick:()=>Rr([l],"unapproved",t,n,r,o),value:"unapproved",children:a.jsx(ee.CircleXIcon,{})}),a.jsx(wn,{onClick:()=>Rr([l],"unknown",t,n,r,o),value:"unknown",children:a.jsx(ee.CircleHelpIcon,{})})]})}}),Nc=Object.freeze(["%webView_inventory_all%","%webView_inventory_approved%","%webView_inventory_unapproved%","%webView_inventory_unknown%","%webView_inventory_scope_currentBook%","%webView_inventory_scope_chapter%","%webView_inventory_scope_verse%","%webView_inventory_filter_text%","%webView_inventory_show_additional_items%","%webView_inventory_occurrences_table_header_reference%","%webView_inventory_occurrences_table_header_occurrence%"]),kc=(e,t,n)=>{let r=e;return t!=="all"&&(r=r.filter(o=>t==="approved"&&o.status==="approved"||t==="unapproved"&&o.status==="unapproved"||t==="unknown"&&o.status==="unknown")),n!==""&&(r=r.filter(o=>o.items[0].includes(n))),r},Sc=(e,t,n,r,o)=>{if(!e)return[];const s=[];let i=t.bookNum,l=t.chapterNum,c=t.verseNum;return Cs(e).forEach(u=>{u.startsWith("\\id")&&(i=Rs(u),l=0,c=0),u.startsWith("\\c")&&(l=qr(u),c=0),u.startsWith("\\v")&&(c=qr(u),l===0&&(l=t.chapterNum));let f=o.exec(u)??void 0;for(;f;){const w=[];f.forEach(h=>w.push(h));const b=f.index,x=s.find(h=>W.deepEqual(h.items,w)),m={reference:{bookNum:i!==void 0?i:-1,chapterNum:l!==void 0?l:-1,verseNum:c!==void 0?c:-1},text:W.substring(u,Math.max(0,b-25),Math.min(b+25,u.length))};if(x)x.count+=1,x.occurrences.push(m);else{const h={items:w,count:1,status:Os(w[0],n,r),occurrences:[m]};s.push(h)}f=o.exec(u)??void 0}}),s},Je=(e,t)=>e[t]??t;function Ec({scriptureReference:e,setScriptureReference:t,localizedStrings:n,extractItems:r,additionalItemsLabels:o,approvedItems:s,unapprovedItems:i,text:l,scope:c,onScopeChange:d,columns:u}){const f=Je(n,"%webView_inventory_all%"),w=Je(n,"%webView_inventory_approved%"),b=Je(n,"%webView_inventory_unapproved%"),x=Je(n,"%webView_inventory_unknown%"),m=Je(n,"%webView_inventory_scope_currentBook%"),h=Je(n,"%webView_inventory_scope_chapter%"),E=Je(n,"%webView_inventory_scope_verse%"),I=Je(n,"%webView_inventory_filter_text%"),C=Je(n,"%webView_inventory_show_additional_items%"),[S,v]=g.useState(!1),[_,V]=g.useState("all"),[U,j]=g.useState(""),[O,k]=g.useState([]),A=g.useMemo(()=>l?r instanceof RegExp?Sc(l,e,s,i,r):r(l,e,s,i):[],[l,r,e,s,i]),M=g.useMemo(()=>{if(S)return A;const y=[];return A.forEach(T=>{const z=T.items[0],L=y.find(B=>B.items[0]===z);L?(L.count+=T.count,L.occurrences=L.occurrences.concat(T.occurrences)):y.push({items:[z],count:T.count,occurrences:T.occurrences,status:T.status})}),y},[S,A]),J=g.useMemo(()=>kc(M,_,U),[M,_,U]),Y=g.useMemo(()=>{var z,L;if(!S)return u;const y=(z=o==null?void 0:o.tableHeaders)==null?void 0:z.length;if(!y)return u;const T=[];for(let B=0;B{k([])},[J]);const F=(y,T)=>{T.setRowSelection(()=>{const z={};return z[y.index]=!0,z}),k(y.original.items)},te=y=>{if(y==="book"||y==="chapter"||y==="verse")d(y);else throw new Error(`Invalid scope value: ${y}`)},se=y=>{if(y==="all"||y==="approved"||y==="unapproved"||y==="unknown")V(y);else throw new Error(`Invalid status filter value: ${y}`)},oe=g.useMemo(()=>{if(M.length===0||O.length===0)return[];const y=M.filter(T=>W.deepEqual(S?T.items:[T.items[0]],O));if(y.length>1)throw new Error("Selected item is not unique");return y[0].occurrences},[O,S,M]);return a.jsxs("div",{className:"pr-twp tw-flex tw-h-full tw-flex-col",children:[a.jsxs("div",{className:"tw-flex tw-items-stretch",children:[a.jsxs(Dt,{onValueChange:y=>se(y),defaultValue:_,children:[a.jsx(bt,{className:"tw-m-1",children:a.jsx(Bt,{placeholder:"Select filter"})}),a.jsxs(vt,{children:[a.jsx(Ae,{value:"all",children:f}),a.jsx(Ae,{value:"approved",children:w}),a.jsx(Ae,{value:"unapproved",children:b}),a.jsx(Ae,{value:"unknown",children:x})]})]}),a.jsxs(Dt,{onValueChange:y=>te(y),defaultValue:c,children:[a.jsx(bt,{className:"tw-m-1",children:a.jsx(Bt,{placeholder:"Select scope"})}),a.jsxs(vt,{children:[a.jsx(Ae,{value:"book",children:m}),a.jsx(Ae,{value:"chapter",children:h}),a.jsx(Ae,{value:"verse",children:E})]})]}),a.jsx(St,{className:"tw-m-1 tw-rounded-md tw-border",placeholder:I,value:U,onChange:y=>{j(y.target.value)}}),o&&a.jsxs("div",{className:"tw-m-1 tw-flex tw-items-center tw-rounded-md tw-border",children:[a.jsx(sr,{className:"tw-m-1",checked:S,onCheckedChange:y=>{k([]),v(y)}}),a.jsx(Ue,{className:"tw-m-1 tw-flex-shrink-0 tw-whitespace-nowrap",children:(o==null?void 0:o.checkboxText)??C})]})]}),a.jsx("div",{className:"tw-m-1 tw-flex-1 tw-overflow-auto tw-rounded-md tw-border",children:a.jsx(Ts,{columns:Y,data:J,onRowClickHandler:F,stickyHeader:!0})}),oe.length>0&&a.jsx("div",{className:"tw-m-1 tw-flex-1 tw-overflow-auto tw-rounded-md tw-border",children:a.jsx(hc,{occurrenceData:oe,setScriptureReference:t,localizedStrings:n})})]})}function mo({className:e,onSearch:t,placeholder:n,isFullWidth:r}){const[o,s]=g.useState(""),i=l=>{s(l),t(l)};return a.jsx(St,{className:N("tw-flex tw-h-10 tw-rounded-md tw-border tw-border-input tw-bg-background tw-px-3 tw-py-2 tw-text-sm tw-ring-offset-background file:tw-border-0 file:tw-bg-transparent file:tw-text-sm file:tw-font-medium placeholder:tw-text-muted-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-[color:hsl(240,5%,64.9%)] focus-visible:tw-ring-offset-2 disabled:tw-cursor-not-allowed disabled:tw-opacity-50",{"tw-w-full":r},e),placeholder:n,value:o,onChange:l=>i(l.target.value)})}const ho=g.forwardRef(({className:e,...t},n)=>a.jsx(Re.Root,{orientation:"vertical",ref:n,className:N("tw-flex tw-gap-1 tw-rounded-md tw-text-muted-foreground",e),...t}));ho.displayName=Re.List.displayName;const go=g.forwardRef(({className:e,...t},n)=>a.jsx(Re.List,{ref:n,className:N("tw-flex-fit tw-mlk-items-center tw-w-[124px] tw-justify-center tw-rounded-md tw-bg-muted tw-p-1 tw-text-muted-foreground",e),...t}));go.displayName=Re.List.displayName;const Is=g.forwardRef(({className:e,...t},n)=>a.jsx(Re.Trigger,{ref:n,...t,className:N("overflow-clip tw-inline-flex tw-w-[116px] tw-cursor-pointer tw-items-center tw-justify-center tw-break-words tw-rounded-sm tw-border-0 tw-bg-muted tw-px-3 tw-py-1.5 tw-text-sm tw-font-medium tw-text-inherit tw-ring-offset-background tw-transition-all hover:tw-text-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50 data-[state=active]:tw-bg-background data-[state=active]:tw-text-foreground data-[state=active]:tw-shadow-sm",e)})),bo=g.forwardRef(({className:e,...t},n)=>a.jsx(Re.Content,{ref:n,className:N("tw-ms-5 tw-flex-grow tw-text-foreground tw-ring-offset-background focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2",e),...t}));bo.displayName=Re.Content.displayName;function jc({tabList:e,onSearch:t,searchPlaceholder:n,headerTitle:r,isSearchBarFullWidth:o=!1,direction:s="ltr"}){return a.jsxs("div",{className:"pr-twp",children:[a.jsxs("div",{className:"tw-sticky tw-top-0 tw-space-y-2 tw-pb-2",children:[r?a.jsx("h1",{children:r}):"",a.jsx(mo,{isFullWidth:o,onSearch:t,placeholder:n})]}),a.jsxs(ho,{dir:s,children:[a.jsx(go,{children:e.map(i=>a.jsx(Is,{value:i.value,children:i.value},i.key))}),e.map(i=>a.jsx(bo,{value:i.value,children:i.content},i.key))]})]})}const lr=g.forwardRef(({className:e,orientation:t="horizontal",decorative:n=!0,...r},o)=>a.jsx(ts.Root,{ref:o,decorative:n,orientation:t,className:N("pr-twp tw-shrink-0 tw-bg-border",t==="horizontal"?"tw-h-[1px] tw-w-full":"tw-h-full tw-w-[1px]",e),...r}));lr.displayName=ts.Root.displayName;function aa({className:e,...t}){return a.jsx("div",{className:N("pr-twp tw-animate-pulse tw-rounded-md tw-bg-muted",e),...t})}const Tc=Sn.Provider,Cc=Sn.Root,Rc=Sn.Trigger,Ms=g.forwardRef(({className:e,sideOffset:t=4,...n},r)=>a.jsx(Sn.Content,{ref:r,sideOffset:t,className:N("pr-twp tw-z-50 tw-overflow-hidden tw-rounded-md tw-border tw-bg-popover tw-px-3 tw-py-1.5 tw-text-sm tw-text-popover-foreground tw-shadow-md tw-animate-in tw-fade-in-0 tw-zoom-in-95 data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=closed]:tw-zoom-out-95 data-[side=bottom]:tw-slide-in-from-top-2 data-[side=left]:tw-slide-in-from-right-2 data-[side=right]:tw-slide-in-from-left-2 data-[side=top]:tw-slide-in-from-bottom-2",e),...n}));Ms.displayName=Sn.Content.displayName;const Oc="16rem",_c="3rem",$s=g.createContext(void 0);function cr(){const e=g.useContext($s);if(!e)throw new Error("useSidebar must be used within a SidebarProvider.");return e}const As=g.forwardRef(({defaultOpen:e=!0,open:t,onOpenChange:n,className:r,style:o,children:s,...i},l)=>{const[c,d]=g.useState(e),u=t??c,f=g.useCallback(m=>{const h=typeof m=="function"?m(u):m;n?n(h):d(h)},[n,u]),w=g.useCallback(()=>f(m=>!m),[f]),b=u?"expanded":"collapsed",x=g.useMemo(()=>({state:b,open:u,setOpen:f,toggleSidebar:w}),[b,u,f,w]);return a.jsx($s.Provider,{value:x,children:a.jsx(Tc,{delayDuration:0,children:a.jsx("div",{style:{"--sidebar-width":Oc,"--sidebar-width-icon":_c,...o},className:N("tw-group/sidebar-wrapper has-[[data-variant=inset]]:tw-bg-sidebar pr-twp tw-flex tw-w-full",r),ref:l,...i,children:s})})})});As.displayName="SidebarProvider";const Ds=g.forwardRef(({side:e="left",variant:t="sidebar",collapsible:n="offcanvas",className:r,children:o,...s},i)=>{const{state:l}=cr();return n==="none"?a.jsx("div",{className:N("tw-bg-sidebar tw-text-sidebar-foreground tw-flex tw-h-full tw-w-[--sidebar-width] tw-flex-col",r),ref:i,...s,children:o}):a.jsxs("div",{ref:i,className:"tw-text-sidebar-foreground tw-group tw-peer tw-hidden md:tw-block","data-state":l,"data-collapsible":l==="collapsed"?n:"","data-variant":t,"data-side":e,children:[a.jsx("div",{className:N("tw-relative tw-h-svh tw-w-[--sidebar-width] tw-bg-transparent tw-transition-[width] tw-duration-200 tw-ease-linear","group-data-[collapsible=offcanvas]:tw-w-0","group-data-[side=right]:tw-rotate-180",t==="floating"||t==="inset"?"group-data-[collapsible=icon]:tw-w-[calc(var(--sidebar-width-icon)_+_theme(spacing.4))]":"group-data-[collapsible=icon]:tw-w-[--sidebar-width-icon]")}),a.jsx("div",{className:N("tw-absolute tw-inset-y-0 tw-z-10 tw-hidden tw-h-svh tw-w-[--sidebar-width] tw-transition-[left,right,width] tw-duration-200 tw-ease-linear md:tw-flex",e==="left"?"tw-left-0 group-data-[collapsible=offcanvas]:tw-left-[calc(var(--sidebar-width)*-1)]":"tw-right-0 group-data-[collapsible=offcanvas]:tw-right-[calc(var(--sidebar-width)*-1)]",t==="floating"||t==="inset"?"tw-p-2 group-data-[collapsible=icon]:tw-w-[calc(var(--sidebar-width-icon)_+_theme(spacing.4)_+2px)]":"group-data-[collapsible=icon]:tw-w-[--sidebar-width-icon] group-data-[side=left]:tw-border-r group-data-[side=right]:tw-border-l",r),...s,children:a.jsx("div",{"data-sidebar":"sidebar",className:"tw-bg-sidebar group-data-[variant=floating]:tw-border-sidebar-border tw-flex tw-h-full tw-w-full tw-flex-col group-data-[variant=floating]:tw-rounded-lg group-data-[variant=floating]:tw-border group-data-[variant=floating]:tw-shadow",children:o})})]})});Ds.displayName="Sidebar";const Pc=g.forwardRef(({className:e,onClick:t,...n},r)=>{const{toggleSidebar:o}=cr();return a.jsxs(fe,{ref:r,"data-sidebar":"trigger",variant:"ghost",size:"icon",className:N("tw-h-7 tw-w-7",e),onClick:s=>{t==null||t(s),o()},...n,children:[a.jsx(ee.PanelLeft,{}),a.jsx("span",{className:"tw-sr-only",children:"Toggle Sidebar"})]})});Pc.displayName="SidebarTrigger";const Ic=g.forwardRef(({className:e,...t},n)=>{const{toggleSidebar:r}=cr();return a.jsx("button",{type:"button",ref:n,"data-sidebar":"rail","aria-label":"Toggle Sidebar",tabIndex:-1,onClick:r,title:"Toggle Sidebar",className:N("hover:after:tw-bg-sidebar-border tw-absolute tw-inset-y-0 tw-z-20 tw-hidden tw-w-4 tw--translate-x-1/2 tw-transition-all tw-ease-linear after:tw-absolute after:tw-inset-y-0 after:tw-left-1/2 after:tw-w-[2px] group-data-[side=left]:tw--right-4 group-data-[side=right]:tw-left-0 sm:tw-flex","[[data-side=left]_&]:tw-cursor-w-resize [[data-side=right]_&]:tw-cursor-e-resize","[[data-side=left][data-state=collapsed]_&]:tw-cursor-e-resize [[data-side=right][data-state=collapsed]_&]:tw-cursor-w-resize","group-data-[collapsible=offcanvas]:hover:tw-bg-sidebar group-data-[collapsible=offcanvas]:tw-translate-x-0 group-data-[collapsible=offcanvas]:after:tw-left-full","[[data-side=left][data-collapsible=offcanvas]_&]:tw--right-2","[[data-side=right][data-collapsible=offcanvas]_&]:tw--left-2",e),...t})});Ic.displayName="SidebarRail";const Bs=g.forwardRef(({className:e,...t},n)=>a.jsx("main",{ref:n,className:N("tw-relative tw-flex tw-flex-1 tw-flex-col tw-bg-background","peer-data-[variant=inset]:tw-min-h-[calc(100svh-theme(spacing.4))] md:peer-data-[variant=inset]:tw-m-2 md:peer-data-[state=collapsed]:peer-data-[variant=inset]:tw-ml-2 md:peer-data-[variant=inset]:tw-ml-0 md:peer-data-[variant=inset]:tw-rounded-xl md:peer-data-[variant=inset]:tw-shadow",e),...t}));Bs.displayName="SidebarInset";const Mc=g.forwardRef(({className:e,...t},n)=>a.jsx(St,{ref:n,"data-sidebar":"input",className:N("focus-visible:tw-ring-sidebar-ring tw-h-8 tw-w-full tw-bg-background tw-shadow-none focus-visible:tw-ring-2",e),...t}));Mc.displayName="SidebarInput";const $c=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,"data-sidebar":"header",className:N("tw-flex tw-flex-col tw-gap-2 tw-p-2",e),...t}));$c.displayName="SidebarHeader";const Ac=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,"data-sidebar":"footer",className:N("tw-flex tw-flex-col tw-gap-2 tw-p-2",e),...t}));Ac.displayName="SidebarFooter";const Dc=g.forwardRef(({className:e,...t},n)=>a.jsx(lr,{ref:n,"data-sidebar":"separator",className:N("tw-bg-sidebar-border tw-mx-2 tw-w-auto",e),...t}));Dc.displayName="SidebarSeparator";const Vs=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,"data-sidebar":"content",className:N("tw-flex tw-min-h-0 tw-flex-1 tw-flex-col tw-gap-2 tw-overflow-auto group-data-[collapsible=icon]:tw-overflow-hidden",e),...t}));Vs.displayName="SidebarContent";const Hr=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,"data-sidebar":"group",className:N("tw-relative tw-flex tw-w-full tw-min-w-0 tw-flex-col tw-p-2",e),...t}));Hr.displayName="SidebarGroup";const Xr=g.forwardRef(({className:e,asChild:t=!1,...n},r)=>{const o=t?Ht.Slot:"div";return a.jsx(o,{ref:r,"data-sidebar":"group-label",className:N("tw-text-sidebar-foreground/70 tw-ring-sidebar-ring tw-flex tw-h-8 tw-shrink-0 tw-items-center tw-rounded-md tw-px-2 tw-text-xs tw-font-medium tw-outline-none tw-transition-[margin,opa] tw-duration-200 tw-ease-linear focus-visible:tw-ring-2 [&>svg]:tw-size-4 [&>svg]:tw-shrink-0","group-data-[collapsible=icon]:tw--mt-8 group-data-[collapsible=icon]:tw-opacity-0",e),...n})});Xr.displayName="SidebarGroupLabel";const Bc=g.forwardRef(({className:e,asChild:t=!1,...n},r)=>{const o=t?Ht.Slot:"button";return a.jsx(o,{ref:r,"data-sidebar":"group-action",className:N("tw-text-sidebar-foreground tw-ring-sidebar-ring hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground tw-absolute tw-right-3 tw-top-3.5 tw-flex tw-aspect-square tw-w-5 tw-items-center tw-justify-center tw-rounded-md tw-p-0 tw-outline-none tw-transition-transform focus-visible:tw-ring-2 [&>svg]:tw-size-4 [&>svg]:tw-shrink-0","after:tw-absolute after:tw--inset-2 after:md:tw-hidden","group-data-[collapsible=icon]:tw-hidden",e),...n})});Bc.displayName="SidebarGroupAction";const Yr=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,"data-sidebar":"group-content",className:N("tw-w-full tw-text-sm",e),...t}));Yr.displayName="SidebarGroupContent";const zs=g.forwardRef(({className:e,...t},n)=>a.jsx("ul",{ref:n,"data-sidebar":"menu",className:N("tw-flex tw-w-full tw-min-w-0 tw-flex-col tw-gap-1",e),...t}));zs.displayName="SidebarMenu";const Ls=g.forwardRef(({className:e,...t},n)=>a.jsx("li",{ref:n,"data-sidebar":"menu-item",className:N("tw-group/menu-item tw-relative",e),...t}));Ls.displayName="SidebarMenuItem";const Vc=kn.cva("tw-peer/menu-button tw-flex tw-w-full tw-items-center tw-gap-2 tw-overflow-hidden tw-rounded-md tw-p-2 tw-text-left tw-text-sm tw-outline-none tw-ring-sidebar-ring tw-transition-[width,height,padding] hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground focus-visible:tw-ring-2 active:tw-bg-sidebar-accent active:tw-text-sidebar-accent-foreground disabled:tw-pointer-events-none disabled:tw-opacity-50 tw-group-has-[[data-sidebar=menu-action]]/menu-item:pr-8 aria-disabled:tw-pointer-events-none aria-disabled:tw-opacity-50 data-[active=true]:tw-font-medium data-[active=true]:tw-text-sidebar-accent-foreground data-[state=open]:hover:tw-bg-sidebar-accent data-[state=open]:hover:tw-text-sidebar-accent-foreground group-data-[collapsible=icon]:tw-!size-8 group-data-[collapsible=icon]:tw-!p-2 [&>span:last-child]:tw-truncate [&>svg]:tw-size-4 [&>svg]:tw-shrink-0",{variants:{variant:{default:"hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground",outline:"tw-bg-background tw-shadow-[0_0_0_1px_hsl(var(--sidebar-border))] hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground hover:tw-shadow-[0_0_0_1px_hsl(var(--sidebar-accent))]"},size:{default:"tw-h-8 tw-text-sm",sm:"tw-h-7 tw-text-xs",lg:"tw-h-12 tw-text-sm group-data-[collapsible=icon]:tw-!p-0"}},defaultVariants:{variant:"default",size:"default"}}),Fs=g.forwardRef(({asChild:e=!1,isActive:t=!1,variant:n="default",size:r="default",tooltip:o,className:s,...i},l)=>{const c=e?Ht.Slot:"button",{state:d}=cr(),u=a.jsx(c,{ref:l,"data-sidebar":"menu-button","data-size":r,"data-active":t,className:N(Vc({variant:n,size:r}),s),...i});return o?(typeof o=="string"&&(o={children:o}),a.jsxs(Cc,{children:[a.jsx(Rc,{asChild:!0,children:u}),a.jsx(Ms,{side:"right",align:"center",hidden:d!=="collapsed",...o})]})):u});Fs.displayName="SidebarMenuButton";const zc=g.forwardRef(({className:e,asChild:t=!1,showOnHover:n=!1,...r},o)=>{const s=t?Ht.Slot:"button";return a.jsx(s,{ref:o,"data-sidebar":"menu-action",className:N("tw-peer-hover/menu-button:text-sidebar-accent-foreground tw-text-sidebar-foreground tw-ring-sidebar-ring hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground tw-absolute tw-right-1 tw-top-1.5 tw-flex tw-aspect-square tw-w-5 tw-items-center tw-justify-center tw-rounded-md tw-p-0 tw-outline-none tw-transition-transform focus-visible:tw-ring-2 [&>svg]:tw-size-4 [&>svg]:tw-shrink-0","after:tw-absolute after:tw--inset-2 after:md:tw-hidden","tw-peer-data-[size=sm]/menu-button:top-1","tw-peer-data-[size=default]/menu-button:top-1.5","tw-peer-data-[size=lg]/menu-button:top-2.5","group-data-[collapsible=icon]:tw-hidden",n&&"tw-group-focus-within/menu-item:opacity-100 tw-group-hover/menu-item:opacity-100 tw-peer-data-[active=true]/menu-button:text-sidebar-accent-foreground data-[state=open]:tw-opacity-100 md:tw-opacity-0",e),...r})});zc.displayName="SidebarMenuAction";const Lc=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,"data-sidebar":"menu-badge",className:N("tw-text-sidebar-foreground tw-pointer-events-none tw-absolute tw-right-1 tw-flex tw-h-5 tw-min-w-5 tw-select-none tw-items-center tw-justify-center tw-rounded-md tw-px-1 tw-text-xs tw-font-medium tw-tabular-nums","tw-peer-hover/menu-button:text-sidebar-accent-foreground tw-peer-data-[active=true]/menu-button:text-sidebar-accent-foreground","tw-peer-data-[size=sm]/menu-button:top-1","tw-peer-data-[size=default]/menu-button:top-1.5","tw-peer-data-[size=lg]/menu-button:top-2.5","group-data-[collapsible=icon]:tw-hidden",e),...t}));Lc.displayName="SidebarMenuBadge";const Fc=g.forwardRef(({className:e,showIcon:t=!1,...n},r)=>{const o=g.useMemo(()=>`${Math.floor(Math.random()*40)+50}%`,[]);return a.jsxs("div",{ref:r,"data-sidebar":"menu-skeleton",className:N("tw-flex tw-h-8 tw-items-center tw-gap-2 tw-rounded-md tw-px-2",e),...n,children:[t&&a.jsx(aa,{className:"tw-size-4 tw-rounded-md","data-sidebar":"menu-skeleton-icon"}),a.jsx(aa,{className:"tw-h-4 tw-max-w-[--skeleton-width] tw-flex-1","data-sidebar":"menu-skeleton-text",style:{"--skeleton-width":o}})]})});Fc.displayName="SidebarMenuSkeleton";const Gc=g.forwardRef(({className:e,...t},n)=>a.jsx("ul",{ref:n,"data-sidebar":"menu-sub",className:N("tw-border-sidebar-border tw-mx-3.5 tw-flex tw-min-w-0 tw-translate-x-px tw-flex-col tw-gap-1 tw-border-l tw-px-2.5 tw-py-0.5","group-data-[collapsible=icon]:tw-hidden",e),...t}));Gc.displayName="SidebarMenuSub";const Uc=g.forwardRef(({...e},t)=>a.jsx("li",{ref:t,...e}));Uc.displayName="SidebarMenuSubItem";const qc=g.forwardRef(({asChild:e=!1,size:t="md",isActive:n,className:r,...o},s)=>{const i=e?Ht.Slot:"a";return a.jsx(i,{ref:s,"data-sidebar":"menu-sub-button","data-size":t,"data-active":n,className:N("tw-text-sidebar-foreground tw-ring-sidebar-ring hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground active:tw-bg-sidebar-accent active:tw-text-sidebar-accent-foreground [&>svg]:tw-text-sidebar-accent-foreground tw-flex tw-h-7 tw-min-w-0 tw--translate-x-px tw-items-center tw-gap-2 tw-overflow-hidden tw-rounded-md tw-px-2 tw-outline-none focus-visible:tw-ring-2 disabled:tw-pointer-events-none disabled:tw-opacity-50 aria-disabled:tw-pointer-events-none aria-disabled:tw-opacity-50 [&>span:last-child]:tw-truncate [&>svg]:tw-size-4 [&>svg]:tw-shrink-0","data-[active=true]:tw-bg-sidebar-accent data-[active=true]:tw-text-sidebar-accent-foreground",t==="sm"&&"tw-text-xs",t==="md"&&"tw-text-sm","group-data-[collapsible=icon]:tw-hidden",r),...o})});qc.displayName="SidebarMenuSubButton";function Gs({id:e,extensionLabels:t,projectInfo:n,handleSelectSidebarItem:r,selectedSidebarItem:o,extensionsSidebarGroupLabel:s,projectsSidebarGroupLabel:i,buttonPlaceholderText:l}){const c=g.useCallback((f,w)=>{r(f,w)},[r]),d=g.useCallback(f=>{const w=n.find(b=>b.projectId===f);return w?w.projectName:f},[n]),u=g.useCallback(f=>!o.projectId&&f===o.label,[o]);return a.jsx(Ds,{id:e,collapsible:"none",variant:"inset",className:"tw-w-96 tw-gap-2 tw-overflow-y-auto tw-rounded tw-bg-slate-100",children:a.jsxs(Vs,{children:[a.jsxs(Hr,{children:[a.jsx(Xr,{className:"tw-text-sm tw-text-gray-400",children:s}),a.jsx(Yr,{children:a.jsx(zs,{children:t.map(f=>a.jsx(Ls,{children:a.jsx(Fs,{className:N("tw-rounded tw-py-2 tw-text-sm tw-text-gray-500 hover:tw-bg-white hover:tw-text-gray-900 hover:tw-shadow-sm active:tw-bg-white",{"tw-bg-white tw-text-gray-900 tw-shadow-sm":u(f)}),onClick:()=>c(f),isActive:u(f),children:a.jsx("span",{className:"tw-pl-3",children:f})})},f))})})]}),a.jsxs(Hr,{children:[a.jsx(Xr,{className:"tw-text-sm tw-text-gray-400",children:i}),a.jsx(Yr,{className:"tw-pl-3",children:a.jsx(Wn,{popoverContentClassName:"tw-z-[1000]",options:n.flatMap(f=>f.projectId),getOptionLabel:f=>d(f),buttonPlaceholder:l,onChange:f=>{const w=d(f);c(w,f)},value:(o==null?void 0:o.projectId)??void 0})})]})]})})}function Hc({id:e,extensionLabels:t,projectInfo:n,children:r,handleSelectSidebarItem:o,selectedSidebarItem:s,onSearch:i,extensionsSidebarGroupLabel:l,projectsSidebarGroupLabel:c,buttonPlaceholderText:d}){return a.jsxs("div",{className:"tw-box-border tw-flex tw-h-full tw-flex-col tw-p-3",children:[a.jsx("div",{className:"tw-box-border tw-flex tw-items-center tw-justify-center tw-py-4",children:a.jsx(mo,{className:"tw-w-9/12",onSearch:i,placeholder:"Search app settings, extension settings, and project settings"})}),a.jsxs(As,{id:e,className:"tw-h-full tw-flex-1 tw-gap-4 tw-overflow-auto",children:[a.jsx(Gs,{extensionLabels:t,projectInfo:n,handleSelectSidebarItem:o,selectedSidebarItem:s,extensionsSidebarGroupLabel:l,projectsSidebarGroupLabel:c,buttonPlaceholderText:d}),a.jsx(Bs,{className:"tw-overflow-y-auto",children:r})]})]})}const rt="scrBook",Xc="scrRef",pt="source",Yc="details",Wc="Scripture Reference",Kc="Scripture Book",Us="Type",Jc="Details";function Zc(e,t){const n=t??!1;return[{accessorFn:r=>`${ae.bookNumberToId(r.start.bookNum)} ${r.start.chapterNum}:${r.start.verseNum}`,id:rt,header:(e==null?void 0:e.scriptureReferenceColumnName)??Wc,cell:r=>{const o=r.row.original;return r.row.getIsGrouped()?ae.bookNumberToEnglishName(o.start.bookNum):r.row.groupingColumnId===rt?W.formatScrRef(o.start):void 0},getGroupingValue:r=>r.start.bookNum,sortingFn:(r,o)=>W.compareScrRefs(r.original.start,o.original.start),enableGrouping:!0},{accessorFn:r=>W.formatScrRef(r.start),id:Xc,header:void 0,cell:r=>{const o=r.row.original;return r.row.getIsGrouped()?void 0:W.formatScrRef(o.start)},sortingFn:(r,o)=>W.compareScrRefs(r.original.start,o.original.start),enableGrouping:!1},{accessorFn:r=>r.source.displayName,id:pt,header:n?(e==null?void 0:e.typeColumnName)??Us:void 0,cell:r=>n||r.row.getIsGrouped()?r.getValue():void 0,getGroupingValue:r=>r.source.id,sortingFn:(r,o)=>r.original.source.displayName.localeCompare(o.original.source.displayName),enableGrouping:!0},{accessorFn:r=>r.detail,id:Yc,header:(e==null?void 0:e.detailsColumnName)??Jc,cell:r=>r.getValue(),enableGrouping:!1}]}const Qc=e=>{if(!("offset"in e.start))throw new Error("No offset available in range start");if(e.end&&!("offset"in e.end))throw new Error("No offset available in range end");const{offset:t}=e.start;let n=0;return e.end&&({offset:n}=e.end),!e.end||W.compareScrRefs(e.start,e.end)===0?`${W.scrRefToBBBCCCVVV(e.start)}+${t}`:`${W.scrRefToBBBCCCVVV(e.start)}+${t}-${W.scrRefToBBBCCCVVV(e.end)}+${n}`},sa=e=>`${Qc({start:e.start,end:e.end})} ${e.source.displayName} ${e.detail}`;function ed({sources:e,showColumnHeaders:t=!1,showSourceColumn:n=!1,scriptureReferenceColumnName:r,scriptureBookGroupName:o,typeColumnName:s,detailsColumnName:i,onRowSelected:l,direction:c="ltr"}){const[d,u]=g.useState([]),[f,w]=g.useState([{id:rt,desc:!1}]),[b,x]=g.useState({}),m=g.useMemo(()=>e.flatMap(j=>j.data.map(O=>({...O,source:j.source}))),[e]),h=g.useMemo(()=>Zc({scriptureReferenceColumnName:r,typeColumnName:s,detailsColumnName:i},n),[r,s,i,n]);g.useEffect(()=>{d.includes(pt)?w([{id:pt,desc:!1},{id:rt,desc:!1}]):w([{id:rt,desc:!1}])},[d]);const E=ke.useReactTable({data:m,columns:h,state:{grouping:d,sorting:f,rowSelection:b},onGroupingChange:u,onSortingChange:w,onRowSelectionChange:x,getExpandedRowModel:ke.getExpandedRowModel(),getGroupedRowModel:ke.getGroupedRowModel(),getCoreRowModel:ke.getCoreRowModel(),getSortedRowModel:ke.getSortedRowModel(),getRowId:sa,autoResetExpanded:!1,enableMultiRowSelection:!1,enableSubRowSelection:!1});g.useEffect(()=>{if(l){const j=E.getSelectedRowModel().rowsById,O=Object.keys(j);if(O.length===1){const k=m.find(A=>sa(A)===O[0])||void 0;k&&l(k)}}},[b,m,l,E]);const I=o??Kc,C=s??Us,S=[{label:"No Grouping",value:[]},{label:`Group by ${I}`,value:[rt]},{label:`Group by ${C}`,value:[pt]},{label:`Group by ${I} and ${C}`,value:[rt,pt]},{label:`Group by ${C} and ${I}`,value:[pt,rt]}],v=j=>{u(JSON.parse(j))},_=(j,O)=>{!j.getIsGrouped()&&!j.getIsSelected()&&j.getToggleSelectedHandler()(O)},V=(j,O)=>j.getIsGrouped()?"":N("banded-row",O%2===0?"even":"odd"),U=(j,O,k)=>{if(!((j==null?void 0:j.length)===0||O.depth{v(j)},children:[a.jsx(bt,{className:"tw-mb-1 tw-mt-2",children:a.jsx(Bt,{})}),a.jsx(vt,{position:"item-aligned",children:a.jsx(Ns,{children:S.map(j=>a.jsx(Ae,{value:JSON.stringify(j.value),children:j.label},j.label))})})]}),a.jsxs(Tn,{className:"tw-relative tw-flex tw-flex-col tw-overflow-y-auto tw-p-0",children:[t&&a.jsx(Cn,{children:E.getHeaderGroups().map(j=>a.jsx(Ze,{children:j.headers.filter(O=>O.column.columnDef.header).map(O=>a.jsx(Vt,{colSpan:O.colSpan,className:"top-0 tw-sticky",children:O.isPlaceholder?void 0:a.jsxs("div",{children:[O.column.getCanGroup()?a.jsx(fe,{variant:"ghost",title:`Toggle grouping by ${O.column.columnDef.header}`,onClick:O.column.getToggleGroupingHandler(),type:"button",children:O.column.getIsGrouped()?"🛑":"👊 "}):void 0," ",ke.flexRender(O.column.columnDef.header,O.getContext())]})},O.id))},j.id))}),a.jsx(Rn,{children:E.getRowModel().rows.map((j,O)=>a.jsx(Ze,{"data-state":j.getIsSelected()?"selected":"",className:N(V(j,O)),onClick:k=>_(j,k),children:j.getVisibleCells().map(k=>{if(!(k.getIsPlaceholder()||k.column.columnDef.enableGrouping&&!k.getIsGrouped()&&(k.column.columnDef.id!==pt||!n)))return a.jsx(xt,{className:N(k.column.columnDef.id,"tw-p-[1px]",U(d,j,k)),children:(()=>k.getIsGrouped()?a.jsxs(fe,{variant:"link",onClick:j.getToggleExpandedHandler(),type:"button",children:[j.getIsExpanded()&&a.jsx(ee.ChevronDown,{}),!j.getIsExpanded()&&(c==="ltr"?a.jsx(ee.ChevronRight,{}):a.jsx(ee.ChevronLeft,{}))," ",ke.flexRender(k.column.columnDef.cell,k.getContext())," (",j.subRows.length,")"]}):ke.flexRender(k.column.columnDef.cell,k.getContext()))()},k.id)})},j.id))})]})]})}const Or={[W.getLocalizeKeyForScrollGroupId("undefined")]:"Ø",[W.getLocalizeKeyForScrollGroupId(0)]:"A",[W.getLocalizeKeyForScrollGroupId(1)]:"B",[W.getLocalizeKeyForScrollGroupId(2)]:"C",[W.getLocalizeKeyForScrollGroupId(3)]:"D",[W.getLocalizeKeyForScrollGroupId(4)]:"E",[W.getLocalizeKeyForScrollGroupId(5)]:"F",[W.getLocalizeKeyForScrollGroupId(6)]:"G",[W.getLocalizeKeyForScrollGroupId(7)]:"H",[W.getLocalizeKeyForScrollGroupId(8)]:"I",[W.getLocalizeKeyForScrollGroupId(9)]:"J",[W.getLocalizeKeyForScrollGroupId(10)]:"K",[W.getLocalizeKeyForScrollGroupId(11)]:"L",[W.getLocalizeKeyForScrollGroupId(12)]:"M",[W.getLocalizeKeyForScrollGroupId(13)]:"N",[W.getLocalizeKeyForScrollGroupId(14)]:"O",[W.getLocalizeKeyForScrollGroupId(15)]:"P",[W.getLocalizeKeyForScrollGroupId(16)]:"Q",[W.getLocalizeKeyForScrollGroupId(17)]:"R",[W.getLocalizeKeyForScrollGroupId(18)]:"S",[W.getLocalizeKeyForScrollGroupId(19)]:"T",[W.getLocalizeKeyForScrollGroupId(20)]:"U",[W.getLocalizeKeyForScrollGroupId(21)]:"V",[W.getLocalizeKeyForScrollGroupId(22)]:"W",[W.getLocalizeKeyForScrollGroupId(23)]:"X",[W.getLocalizeKeyForScrollGroupId(24)]:"Y",[W.getLocalizeKeyForScrollGroupId(25)]:"Z"};function td({availableScrollGroupIds:e,scrollGroupId:t,onChangeScrollGroupId:n,localizedStrings:r={}}){const o={...Or,...Object.fromEntries(Object.entries(r).map(([s,i])=>[s,s===i&&s in Or?Or[s]:i]))};return a.jsxs(Dt,{value:`${t}`,onValueChange:s=>n(s==="undefined"?void 0:parseInt(s,10)),children:[a.jsx(bt,{className:"pr-twp tw-w-auto",children:a.jsx(Bt,{placeholder:o[W.getLocalizeKeyForScrollGroupId(t)]??t})}),a.jsx(vt,{style:{zIndex:250},children:e.map(s=>a.jsx(Ae,{value:`${s}`,children:o[W.getLocalizeKeyForScrollGroupId(s)]},`${s}`))})]})}function nd({children:e}){return a.jsx("div",{className:"pr-twp tw-grid",children:e})}function rd({primary:e,secondary:t,children:n,isLoading:r=!1,loadingMessage:o}){return a.jsxs("div",{className:"tw-flex tw-items-center tw-justify-between tw-space-x-4 tw-py-2",children:[a.jsxs("div",{children:[a.jsx("p",{className:"tw-text-sm tw-font-medium tw-leading-none",children:e}),a.jsx("p",{className:"tw-whitespace-normal tw-break-words tw-text-sm tw-text-muted-foreground",children:t})]}),r?a.jsx("p",{className:"tw-text-sm tw-text-muted-foreground",children:o}):a.jsx("div",{children:n})]})}function od({primary:e,secondary:t,includeSeparator:n=!1}){return a.jsxs("div",{className:"tw-space-y-4 tw-py-2",children:[a.jsxs("div",{children:[a.jsx("h3",{className:"tw-text-lg tw-font-medium",children:e}),a.jsx("p",{className:"tw-text-sm tw-text-muted-foreground",children:t})]}),n?a.jsx(lr,{}):""]})}function ad({id:e,className:t,listItems:n,selectedListItems:r,handleSelectListItem:o,createLabel:s}){return a.jsx("div",{id:e,className:t,children:n.map(i=>a.jsxs("div",{className:"tw-m-2 tw-flex tw-items-center",children:[a.jsx(sr,{className:"tw-mr-2 tw-align-middle",checked:r.includes(i),onCheckedChange:l=>o(i,l)}),a.jsx(Ue,{children:s?s(i):i})]},i))})}function sd(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}function id(e){if(e.__esModule)return e;var t=e.default;if(typeof t=="function"){var n=function r(){return this instanceof r?Reflect.construct(t,arguments,this.constructor):t.apply(this,arguments)};n.prototype=t.prototype}else n={};return Object.defineProperty(n,"__esModule",{value:!0}),Object.keys(e).forEach(function(r){var o=Object.getOwnPropertyDescriptor(e,r);Object.defineProperty(n,r,o.get?o:{enumerable:!0,get:function(){return e[r]}})}),n}var vo={},qs={exports:{}};(function(e){function t(n){return n&&n.__esModule?n:{default:n}}e.exports=t,e.exports.__esModule=!0,e.exports.default=e.exports})(qs);var ld=qs.exports,_r={};function xo(e,t){return process.env.NODE_ENV==="production"?()=>null:function(...r){return e(...r)||t(...r)}}function R(){return R=Object.assign?Object.assign.bind():function(e){for(var t=1;t{t[n]=Hs(e[n])}),t}function Qe(e,t,n={clone:!0}){const r=n.clone?R({},e):e;return mt(e)&&mt(t)&&Object.keys(t).forEach(o=>{o!=="__proto__"&&(mt(t[o])&&o in e&&mt(e[o])?r[o]=Qe(e[o],t[o],n):n.clone?r[o]=mt(t[o])?Hs(t[o]):t[o]:r[o]=t[o])}),r}var Wr={exports:{}},zn={exports:{}},ie={};/** @license React v16.13.1 +"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const a=require("react/jsx-runtime"),g=require("react"),ee=require("lucide-react"),ot=require("clsx"),pl=require("tailwind-merge"),Ja=require("@radix-ui/react-dropdown-menu"),W=require("platform-bible-utils"),Ht=require("@radix-ui/react-slot"),kn=require("class-variance-authority"),wl=require("@radix-ui/react-label"),fl=require("@radix-ui/react-radio-group"),ml=require("@radix-ui/react-popover"),Ce=require("cmdk"),hl=require("@radix-ui/react-dialog"),ke=require("@tanstack/react-table"),gl=require("@radix-ui/react-select"),bl=require("@radix-ui/react-checkbox"),vl=require("@radix-ui/react-toggle-group"),xl=require("@radix-ui/react-toggle"),yl=require("@radix-ui/react-tabs"),Nl=require("@radix-ui/react-separator"),kl=require("@radix-ui/react-tooltip"),Fr=require("@mui/styled-engine"),Ie=require("@mui/material"),sn=require("react-dom"),Za=require("sonner"),Sl=require("@radix-ui/react-slider"),El=require("@radix-ui/react-switch"),jl=require("markdown-to-jsx");function Ne(e){const t=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(e){for(const n in e)if(n!=="default"){const r=Object.getOwnPropertyDescriptor(e,n);Object.defineProperty(t,n,r.get?r:{enumerable:!0,get:()=>e[n]})}}return t.default=e,Object.freeze(t)}const $=Ne(g),pe=Ne(Ja),Qa=Ne(wl),gn=Ne(fl),bn=Ne(ml),Xe=Ne(hl),ge=Ne(gl),Gr=Ne(bl),rr=Ne(vl),es=Ne(xl),Re=Ne(yl),ts=Ne(Nl),Sn=Ne(kl),Tl=Ne(sn),ln=Ne(Sl),Ur=Ne(El);const Cl=pl.extendTailwindMerge({prefix:"tw-"});function N(...e){return Cl(ot.clsx(e))}const St=g.forwardRef(({className:e,type:t,...n},r)=>a.jsx("input",{type:t,className:N("pr-twp tw-flex tw-h-10 tw-rounded-md tw-border tw-border-input tw-bg-background tw-px-3 tw-py-2 tw-text-sm tw-ring-offset-background file:tw-border-0 file:tw-bg-transparent file:tw-text-sm file:tw-font-medium file:tw-text-foreground placeholder:tw-text-muted-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-cursor-not-allowed disabled:tw-opacity-50",e),ref:r,...n}));St.displayName="Input";const Rl=g.forwardRef(({handleSearch:e,handleKeyDown:t,handleOnClick:n,handleSubmit:r,...o},s)=>a.jsxs("div",{className:"tw-relative",children:[a.jsx(St,{...o,type:"text",className:"tw-box-border tw-gap-2.5 tw-rounded-lg tw-border tw-border-solid tw-bg-background tw-py-2 tw-pl-4 tw-pr-3 tw-font-medium tw-shadow-none tw-outline-none",onChange:i=>e(i.target.value),onKeyDown:i=>{i.key==="Enter"&&r(),t(i)},onClick:n,ref:s}),a.jsx(ee.History,{className:"tw-absolute tw-right-3 tw-top-1/2 tw-h-4 tw-w-4 tw--translate-y-1/2 tw-transform tw-cursor-pointer tw-text-muted-foreground",onClick:()=>{console.log("back in history")}})]}));var Ol=Object.defineProperty,_l=(e,t,n)=>t in e?Ol(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,ne=(e,t,n)=>_l(e,typeof t!="symbol"?t+"":t,n);const gt=["GEN","EXO","LEV","NUM","DEU","JOS","JDG","RUT","1SA","2SA","1KI","2KI","1CH","2CH","EZR","NEH","EST","JOB","PSA","PRO","ECC","SNG","ISA","JER","LAM","EZK","DAN","HOS","JOL","AMO","OBA","JON","MIC","NAM","HAB","ZEP","HAG","ZEC","MAL","MAT","MRK","LUK","JHN","ACT","ROM","1CO","2CO","GAL","EPH","PHP","COL","1TH","2TH","1TI","2TI","TIT","PHM","HEB","JAS","1PE","2PE","1JN","2JN","3JN","JUD","REV","TOB","JDT","ESG","WIS","SIR","BAR","LJE","S3Y","SUS","BEL","1MA","2MA","3MA","4MA","1ES","2ES","MAN","PS2","ODA","PSS","JSA","JDB","TBS","SST","DNT","BLT","XXA","XXB","XXC","XXD","XXE","XXF","XXG","FRT","BAK","OTH","3ES","EZA","5EZ","6EZ","INT","CNC","GLO","TDX","NDX","DAG","PS3","2BA","LBA","JUB","ENO","1MQ","2MQ","3MQ","REP","4BA","LAO"],oo=["XXA","XXB","XXC","XXD","XXE","XXF","XXG","FRT","BAK","OTH","INT","CNC","GLO","TDX","NDX"],ns=["Genesis","Exodus","Leviticus","Numbers","Deuteronomy","Joshua","Judges","Ruth","1 Samuel","2 Samuel","1 Kings","2 Kings","1 Chronicles","2 Chronicles","Ezra","Nehemiah","Esther (Hebrew)","Job","Psalms","Proverbs","Ecclesiastes","Song of Songs","Isaiah","Jeremiah","Lamentations","Ezekiel","Daniel (Hebrew)","Hosea","Joel","Amos","Obadiah","Jonah","Micah","Nahum","Habakkuk","Zephaniah","Haggai","Zechariah","Malachi","Matthew","Mark","Luke","John","Acts","Romans","1 Corinthians","2 Corinthians","Galatians","Ephesians","Philippians","Colossians","1 Thessalonians","2 Thessalonians","1 Timothy","2 Timothy","Titus","Philemon","Hebrews","James","1 Peter","2 Peter","1 John","2 John","3 John","Jude","Revelation","Tobit","Judith","Esther Greek","Wisdom of Solomon","Sirach (Ecclesiasticus)","Baruch","Letter of Jeremiah","Song of 3 Young Men","Susanna","Bel and the Dragon","1 Maccabees","2 Maccabees","3 Maccabees","4 Maccabees","1 Esdras (Greek)","2 Esdras (Latin)","Prayer of Manasseh","Psalm 151","Odes","Psalms of Solomon","Joshua A. *obsolete*","Judges B. *obsolete*","Tobit S. *obsolete*","Susanna Th. *obsolete*","Daniel Th. *obsolete*","Bel Th. *obsolete*","Extra A","Extra B","Extra C","Extra D","Extra E","Extra F","Extra G","Front Matter","Back Matter","Other Matter","3 Ezra *obsolete*","Apocalypse of Ezra","5 Ezra (Latin Prologue)","6 Ezra (Latin Epilogue)","Introduction","Concordance ","Glossary ","Topical Index","Names Index","Daniel Greek","Psalms 152-155","2 Baruch (Apocalypse)","Letter of Baruch","Jubilees","Enoch","1 Meqabyan","2 Meqabyan","3 Meqabyan","Reproof (Proverbs 25-31)","4 Baruch (Rest of Baruch)","Laodiceans"],na=Ll();function Xt(e,t=!0){return t&&(e=e.toUpperCase()),e in na?na[e]:0}function ao(e){return Xt(e)>0}function Pl(e){const t=typeof e=="string"?Xt(e):e;return t>=40&&t<=66}function Il(e){return(typeof e=="string"?Xt(e):e)<=39}function rs(e){return e<=66}function Ml(e){const t=typeof e=="string"?Xt(e):e;return ss(t)&&!rs(t)}function*$l(){for(let e=1;e<=gt.length;e++)yield e}const Al=1,os=gt.length;function Dl(){return["XXA","XXB","XXC","XXD","XXE","XXF","XXG"]}function so(e,t="***"){const n=e-1;return n<0||n>=gt.length?t:gt[n]}function as(e){return e<=0||e>os?"******":ns[e-1]}function Bl(e){return as(Xt(e))}function ss(e){const t=typeof e=="number"?so(e):e;return ao(t)&&!oo.includes(t)}function Vl(e){const t=typeof e=="number"?so(e):e;return ao(t)&&oo.includes(t)}function zl(e){return ns[e-1].includes("*obsolete*")}function Ll(){const e={};for(let t=0;t(e[e.Unknown=0]="Unknown",e[e.Original=1]="Original",e[e.Septuagint=2]="Septuagint",e[e.Vulgate=3]="Vulgate",e[e.English=4]="English",e[e.RussianProtestant=5]="RussianProtestant",e[e.RussianOrthodox=6]="RussianOrthodox",e))(qe||{});const _e=class{constructor(t){if(ne(this,"name"),ne(this,"fullPath"),ne(this,"isPresent"),ne(this,"hasVerseSegments"),ne(this,"isCustomized"),ne(this,"baseVersification"),ne(this,"scriptureBooks"),ne(this,"_type"),t==null)throw new Error("Argument undefined");typeof t=="string"?(this.name=t,this._type=qe[t]):(this._type=t,this.name=qe[t])}get type(){return this._type}equals(t){return!t.type||!this.type?!1:t.type===this.type}};ne(_e,"Original",new _e(qe.Original)),ne(_e,"Septuagint",new _e(qe.Septuagint)),ne(_e,"Vulgate",new _e(qe.Vulgate)),ne(_e,"English",new _e(qe.English)),ne(_e,"RussianProtestant",new _e(qe.RussianProtestant)),ne(_e,"RussianOrthodox",new _e(qe.RussianOrthodox));let ut=_e;function ra(e,t){const n=t[0];for(let r=1;r(e[e.Valid=0]="Valid",e[e.UnknownVersification=1]="UnknownVersification",e[e.OutOfRange=2]="OutOfRange",e[e.VerseOutOfOrder=3]="VerseOutOfOrder",e[e.VerseRepeated=4]="VerseRepeated",e))(is||{});const Ee=class re{constructor(t,n,r,o){if(ne(this,"firstChapter"),ne(this,"lastChapter"),ne(this,"lastVerse"),ne(this,"hasSegmentsDefined"),ne(this,"text"),ne(this,"BBBCCCVVVS"),ne(this,"longHashCode"),ne(this,"versification"),ne(this,"rtlMark","‏"),ne(this,"_bookNum",0),ne(this,"_chapterNum",0),ne(this,"_verseNum",0),ne(this,"_verse"),r==null&&o==null)if(t!=null&&typeof t=="string"){const s=t,i=n!=null&&n instanceof ut?n:void 0;this.setEmpty(i),this.parse(s)}else if(t!=null&&typeof t=="number"){const s=n!=null&&n instanceof ut?n:void 0;this.setEmpty(s),this._verseNum=t%re.chapterDigitShifter,this._chapterNum=Math.floor(t%re.bookDigitShifter/re.chapterDigitShifter),this._bookNum=Math.floor(t/re.bookDigitShifter)}else if(n==null)if(t!=null&&t instanceof re){const s=t;this._bookNum=s.bookNum,this._chapterNum=s.chapterNum,this._verseNum=s.verseNum,this._verse=s.verse,this.versification=s.versification}else{if(t==null)return;const s=t instanceof ut?t:re.defaultVersification;this.setEmpty(s)}else throw new Error("VerseRef constructor not supported.");else if(t!=null&&n!=null&&r!=null)if(typeof t=="string"&&typeof n=="string"&&typeof r=="string")this.setEmpty(o),this.updateInternal(t,n,r);else if(typeof t=="number"&&typeof n=="number"&&typeof r=="number")this._bookNum=t,this._chapterNum=n,this._verseNum=r,this.versification=o??re.defaultVersification;else throw new Error("VerseRef constructor not supported.");else throw new Error("VerseRef constructor not supported.")}static isVerseParseable(t){return t.length>0&&"0123456789".includes(t[0])&&!t.endsWith(this.verseRangeSeparator)&&!t.endsWith(this.verseSequenceIndicator)}static tryParse(t){let n;try{return n=new re(t),{success:!0,verseRef:n}}catch(r){if(r instanceof tn)return n=new re,{success:!1,verseRef:n};throw r}}static getBBBCCCVVV(t,n,r){return t%re.bcvMaxValue*re.bookDigitShifter+(n>=0?n%re.bcvMaxValue*re.chapterDigitShifter:0)+(r>=0?r%re.bcvMaxValue:0)}static fromJSON(t){const{book:n,chapterNum:r,verseNum:o,verse:s,versificationStr:i}=t,l=s||o.toString();let c;return i&&(c=new ut(i)),n?new re(n,r.toString(),l,c):new re}static tryGetVerseNum(t){let n;if(!t)return n=-1,{success:!0,vNum:n};n=0;let r;for(let o=0;o"9")return o===0&&(n=-1),{success:!1,vNum:n};if(n=n*10+ +r-0,n>re.bcvMaxValue)return n=-1,{success:!1,vNum:n}}return{success:!0,vNum:n}}get isDefault(){return this.bookNum===0&&this.chapterNum===0&&this.verseNum===0&&this.versification==null}get hasMultiple(){return this._verse!=null&&(this._verse.includes(re.verseRangeSeparator)||this._verse.includes(re.verseSequenceIndicator))}get book(){return ae.bookNumberToId(this.bookNum,"")}set book(t){this.bookNum=ae.bookIdToNumber(t)}get chapter(){return this.isDefault||this._chapterNum<0?"":this._chapterNum.toString()}set chapter(t){const n=+t;this._chapterNum=Number.isInteger(n)?n:-1}get verse(){return this._verse!=null?this._verse:this.isDefault||this._verseNum<0?"":this._verseNum.toString()}set verse(t){const{success:n,vNum:r}=re.tryGetVerseNum(t);this._verse=n?void 0:t.replace(this.rtlMark,""),this._verseNum=r,!(this._verseNum>=0)&&({vNum:this._verseNum}=re.tryGetVerseNum(this._verse))}get bookNum(){return this._bookNum}set bookNum(t){if(t<=0||t>ae.lastBook)throw new tn("BookNum must be greater than zero and less than or equal to last book");this._bookNum=t}get chapterNum(){return this._chapterNum}set chapterNum(t){this.chapterNum=t}get verseNum(){return this._verseNum}set verseNum(t){this._verseNum=t}get versificationStr(){var t;return(t=this.versification)==null?void 0:t.name}set versificationStr(t){this.versification=this.versification!=null?new ut(t):void 0}get valid(){return this.validStatus===0}get validStatus(){return this.validateVerse(re.verseRangeSeparators,re.verseSequenceIndicators)}get BBBCCC(){return re.getBBBCCCVVV(this._bookNum,this._chapterNum,0)}get BBBCCCVVV(){return re.getBBBCCCVVV(this._bookNum,this._chapterNum,this._verseNum)}get isExcluded(){return!1}parse(t){if(t=t.replace(this.rtlMark,""),t.includes("/")){const s=t.split("/");if(t=s[0],s.length>1)try{const i=+s[1].trim();this.versification=new ut(qe[i])}catch{throw new tn("Invalid reference : "+t)}}const n=t.trim().split(" ");if(n.length!==2)throw new tn("Invalid reference : "+t);const r=n[1].split(":"),o=+r[0];if(r.length!==2||ae.bookIdToNumber(n[0])===0||!Number.isInteger(o)||o<0||!re.isVerseParseable(r[1]))throw new tn("Invalid reference : "+t);this.updateInternal(n[0],r[0],r[1])}simplify(){this._verse=void 0}clone(){return new re(this)}toString(){const t=this.book;return t===""?"":`${t} ${this.chapter}:${this.verse}`}toJSON(){let t=this.verse;(t===""||t===this.verseNum.toString())&&(t=void 0);const n={book:this.book,chapterNum:this.chapterNum,verseNum:this.verseNum,verse:t,versificationStr:this.versificationStr};return t||delete n.verse,n}equals(t){return t instanceof re?t._bookNum===this._bookNum&&t._chapterNum===this._chapterNum&&t._verseNum===this._verseNum&&t.verse===this.verse&&(t.versification==null&&this.versification==null||t.versification!=null&&this.versification!=null&&t.versification.equals(this.versification)):!1}allVerses(t=!1,n=re.verseRangeSeparators,r=re.verseSequenceIndicators){if(this._verse==null||this.chapterNum<=0)return[this.clone()];const o=[],s=ra(this._verse,r);for(const i of s.map(l=>ra(l,n))){const l=this.clone();l.verse=i[0];const c=l.verseNum;if(o.push(l),i.length>1){const d=this.clone();if(d.verse=i[1],!t)for(let u=c+1;ui)return 3;if(r===i)return 4;r=i}return 0}get internalValid(){return this.versification==null?1:this._bookNum<=0||this._bookNum>ae.lastBook?2:(ae.isCanonical(this._bookNum),0)}setEmpty(t=re.defaultVersification){this._bookNum=0,this._chapterNum=-1,this._verse=void 0,this.versification=t}updateInternal(t,n,r){this.bookNum=ae.bookIdToNumber(t),this.chapter=n,this.verse=r}};ne(Ee,"defaultVersification",ut.English),ne(Ee,"verseRangeSeparator","-"),ne(Ee,"verseSequenceIndicator",","),ne(Ee,"verseRangeSeparators",[Ee.verseRangeSeparator]),ne(Ee,"verseSequenceIndicators",[Ee.verseSequenceIndicator]),ne(Ee,"chapterDigitShifter",1e3),ne(Ee,"bookDigitShifter",Ee.chapterDigitShifter*Ee.chapterDigitShifter),ne(Ee,"bcvMaxValue",Ee.chapterDigitShifter-1),ne(Ee,"ValidStatusType",is);class tn extends Error{}const or=pe.Root,io=pe.Trigger,ls=pe.Group,Fl=pe.Portal,Gl=pe.Sub,Ul=pe.RadioGroup,cs=g.forwardRef(({className:e,inset:t,children:n,...r},o)=>a.jsxs(pe.SubTrigger,{ref:o,className:N("tw-flex tw-cursor-default tw-select-none tw-items-center tw-rounded-sm tw-px-2 tw-py-1.5 tw-text-sm tw-outline-none focus:tw-bg-accent data-[state=open]:tw-bg-accent",t&&"tw-pl-8",e),...r,children:[n,a.jsx(ee.ChevronRight,{className:"tw-ml-auto tw-h-4 tw-w-4"})]}));cs.displayName=pe.SubTrigger.displayName;const ds=g.forwardRef(({className:e,...t},n)=>a.jsx(pe.SubContent,{ref:n,className:N("tw-z-50 tw-min-w-[8rem] tw-overflow-hidden tw-rounded-md tw-border tw-bg-popover tw-p-1 tw-text-popover-foreground tw-shadow-lg data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0 data-[state=closed]:tw-zoom-out-95 data-[state=open]:tw-zoom-in-95 data-[side=bottom]:tw-slide-in-from-top-2 data-[side=left]:tw-slide-in-from-right-2 data-[side=right]:tw-slide-in-from-left-2 data-[side=top]:tw-slide-in-from-bottom-2",e),...t}));ds.displayName=pe.SubContent.displayName;const En=g.forwardRef(({className:e,sideOffset:t=4,...n},r)=>a.jsx(pe.Portal,{children:a.jsx(pe.Content,{ref:r,sideOffset:t,className:N("pr-twp tw-z-50 tw-min-w-[8rem] tw-overflow-hidden tw-rounded-md tw-border tw-bg-popover tw-p-1 tw-text-popover-foreground tw-shadow-md data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0 data-[state=closed]:tw-zoom-out-95 data-[state=open]:tw-zoom-in-95 data-[side=bottom]:tw-slide-in-from-top-2 data-[side=left]:tw-slide-in-from-right-2 data-[side=right]:tw-slide-in-from-left-2 data-[side=top]:tw-slide-in-from-bottom-2",e),...n})}));En.displayName=pe.Content.displayName;const lo=g.forwardRef(({className:e,inset:t,...n},r)=>a.jsx(pe.Item,{ref:r,className:N("tw-cursor-default tw-select-none tw-items-center tw-rounded-sm tw-px-2 tw-py-1.5 tw-text-sm tw-outline-none tw-transition-colors focus:tw-bg-accent data-[disabled]:tw-pointer-events-none data-[disabled]:tw-opacity-50",t&&"tw-pl-8",e),...n}));lo.displayName=pe.Item.displayName;const ar=g.forwardRef(({className:e,children:t,checked:n,...r},o)=>a.jsxs(pe.CheckboxItem,{ref:o,className:N("tw-relative tw-flex tw-cursor-default tw-select-none tw-items-center tw-rounded-sm tw-py-1.5 tw-pl-8 tw-pr-2 tw-text-sm tw-outline-none tw-transition-colors focus:tw-bg-accent focus:tw-text-accent-foreground data-[disabled]:tw-pointer-events-none data-[disabled]:tw-opacity-50",e),checked:n,...r,children:[a.jsx("span",{className:"tw-absolute tw-left-2 tw-flex tw-h-3.5 tw-w-3.5 tw-items-center tw-justify-center",children:a.jsx(pe.ItemIndicator,{children:a.jsx(ee.Check,{className:"tw-h-4 tw-w-4"})})}),t]}));ar.displayName=pe.CheckboxItem.displayName;const co=g.forwardRef(({className:e,children:t,...n},r)=>a.jsxs(pe.RadioItem,{ref:r,className:N("tw-relative tw-flex tw-cursor-default tw-select-none tw-items-center tw-rounded-sm tw-py-1.5 tw-pl-8 tw-pr-2 tw-text-sm tw-outline-none tw-transition-colors focus:tw-bg-accent focus:tw-text-accent-foreground data-[disabled]:tw-pointer-events-none data-[disabled]:tw-opacity-50",e),...n,children:[a.jsx("span",{className:"tw-absolute tw-left-2 tw-flex tw-h-3.5 tw-w-3.5 tw-items-center tw-justify-center",children:a.jsx(pe.ItemIndicator,{children:a.jsx(ee.Circle,{className:"tw-h-2 tw-w-2 tw-fill-current"})})}),t]}));co.displayName=pe.RadioItem.displayName;const Yt=g.forwardRef(({className:e,inset:t,...n},r)=>a.jsx(pe.Label,{ref:r,className:N("tw-px-2 tw-py-1.5 tw-text-sm tw-font-semibold",t&&"tw-pl-8",e),...n}));Yt.displayName=pe.Label.displayName;const jn=g.forwardRef(({className:e,...t},n)=>a.jsx(pe.Separator,{ref:n,className:N("tw--mx-1 tw-my-1 tw-h-px tw-bg-muted",e),...t}));jn.displayName=pe.Separator.displayName;function us({className:e,...t}){return a.jsx("span",{className:N("tw-ml-auto tw-text-xs tw-tracking-widest tw-opacity-60",e),...t})}us.displayName="DropdownMenuShortcut";const ql=g.forwardRef(({bookId:e,handleSelectBook:t,isSelected:n,handleHighlightBook:r,handleKeyDown:o,bookType:s,children:i},l)=>a.jsxs(lo,{ref:l,textValue:e,className:N("tw-mx-1 tw-px-1 tw-font-normal tw-text-foreground/80",{"tw-bg-amber-50 tw-text-yellow-900 data-[highlighted]:tw-bg-amber-100":n}),onSelect:c=>{c.preventDefault(),t()},onKeyDown:c=>{o(c)},onFocus:r,onMouseMove:r,children:[a.jsx("span",{className:N("tw-border-b-0 tw-border-l-2 tw-border-r-0 tw-border-t-0 tw-border-solid tw-px-2",{"tw-font-bold":n,"tw-border-l-red-200":s.toLowerCase()==="ot","tw-border-l-purple-200":s.toLowerCase()==="nt","tw-border-l-indigo-200":s.toLowerCase()==="dc"}),children:ae.bookIdToEnglishName(e)}),n&&a.jsx("div",{children:i})]},e));function Hl({handleSelectChapter:e,endChapter:t,activeChapter:n,highlightedChapter:r,handleHighlightedChapter:o}){const s=Array.from({length:t},(l,c)=>c+1),i=g.useCallback(l=>{o(l)},[o]);return a.jsx("div",{className:N("tw-flex tw-flex-wrap tw-items-start tw-justify-start tw-self-stretch"),children:s.map(l=>a.jsx("div",{className:N("tw-box-content tw-flex tw-h-4 tw-w-4 tw-cursor-pointer tw-items-center tw-justify-end tw-rounded-md tw-p-2 tw-text-amber-800",{"tw-font-semibold tw-text-amber-900":l===n,"tw-bg-amber-200":l===r}),onClick:c=>{c.preventDefault(),c.stopPropagation(),e(l)},role:"button",onKeyDown:c=>{c.key==="Enter"&&e(l)},tabIndex:0,onMouseMove:()=>i(l),children:l},l))})}function Xl({handleSort:e,handleLocationHistory:t,handleBookmarks:n}){return a.jsxs(Yt,{className:"tw-flex tw-justify-between",children:[a.jsx("p",{className:"tw-inline-block tw-align-middle",children:"Go To"}),a.jsxs("div",{className:"tw-flex tw-items-center",children:[a.jsx(ee.ArrowDownWideNarrow,{onClick:e,className:"tw-m-2 tw-h-4 tw-w-4 tw-cursor-pointer tw-gap-2"}),a.jsx(ee.Clock,{onClick:t,className:"tw-m-2 tw-h-4 tw-w-4 tw-cursor-pointer tw-gap-2"}),a.jsx(ee.Bookmark,{onClick:n,className:"tw-m-2 tw-h-4 tw-w-4 tw-cursor-pointer tw-gap-2"})]})]})}const pn=ae.allBookIds,Yl={OT:"Old Testament",NT:"New Testament",DC:"Deuterocanon"},oa=["OT","NT","DC"],Wl=32+32+32,Kl=[/^(\w+)$/i,/^(\w+)(?:\s(\d+))$/i,/^(\w+)(?:\s(\d+):(\d+))$/i],Jl=e=>({OT:pn.filter(n=>ae.isBookOT(n)),NT:pn.filter(n=>ae.isBookNT(n)),DC:pn.filter(n=>ae.isBookDC(n))})[e],nn=e=>W.getChaptersForBook(ae.bookIdToNumber(e));function Zl(){return pn.map(t=>ae.bookIdToEnglishName(t))}function Ql(e){return Zl().includes(e)}function ec(e){const t=e.toLowerCase().replace(/^\w/,n=>n.toUpperCase());if(Ql(t))return pn.find(r=>ae.bookIdToEnglishName(r)===t)}function tc({scrRef:e,handleSubmit:t}){const[n,r]=g.useState(""),[o,s]=g.useState(ae.bookNumberToId(e.bookNum)),[i,l]=g.useState(e.chapterNum??0),[c,d]=g.useState(ae.bookNumberToId(e.bookNum)),[u,f]=g.useState(!1),[w,b]=g.useState(u),x=g.useRef(void 0),m=g.useRef(void 0),h=g.useRef(void 0),k=g.useCallback(S=>Jl(S).filter(A=>{const M=ae.bookIdToEnglishName(A).toLowerCase(),J=n.replace(/[^a-zA-Z]/g,"").toLowerCase();return M.includes(J)||A.toLowerCase().includes(J)}),[n]),I=S=>{r(S)},C=g.useRef(!1),E=g.useCallback(S=>{if(C.current){C.current=!1;return}f(S)},[]),v=g.useCallback((S,A,M,J)=>{if(l(ae.bookNumberToId(e.bookNum)!==S?1:e.chapterNum),A||nn(S)===-1){t({bookNum:ae.bookIdToNumber(S),chapterNum:M||1,verseNum:J||1}),f(!1),r("");return}s(o!==S?S:""),f(!A)},[t,e.bookNum,e.chapterNum,o]),_=S=>{S<=0||S>nn(o)||v(o,!0,S)},V=g.useCallback(()=>{Kl.forEach(S=>{const A=n.match(S);if(A){const[M,J=void 0,Y=void 0]=A.slice(1),F=ec(M);(ae.isBookIdValid(M)||F)&&v(F??M,!0,J?parseInt(J,10):1,Y?parseInt(Y,10):1)}})},[v,n]),U=g.useCallback(S=>{u?(S.key==="ArrowDown"||S.key==="ArrowUp")&&(typeof h<"u"&&h.current!==null?h.current.focus():typeof m<"u"&&m.current!==null&&m.current.focus(),S.preventDefault()):f(!0)},[u]),j=S=>{const{key:A}=S;A==="ArrowRight"||A==="ArrowLeft"||A==="ArrowDown"||A==="ArrowUp"||A==="Enter"||(x.current.dispatchEvent(new KeyboardEvent("keydown",{key:A})),x.current.focus())},O=S=>{const{key:A}=S;if(c===o){if(A==="Enter"){S.preventDefault(),v(o,!0,i);return}let M=0;if(A==="ArrowRight")if(i1)M=-1;else{S.preventDefault();return}else A==="ArrowDown"?M=6:A==="ArrowUp"&&(M=-6);i+M<=0||i+M>nn(c)?l(0):M!==0&&(l(i+M),S.preventDefault())}};return g.useEffect(()=>{o===c?o===ae.bookNumberToId(e.bookNum)?l(e.chapterNum):l(1):l(0)},[c,e.bookNum,e.chapterNum,o]),g.useLayoutEffect(()=>{b(u)},[u]),g.useLayoutEffect(()=>{const S=setTimeout(()=>{if(w&&m.current&&h.current){const M=h.current.offsetTop-Wl;m.current.scrollTo({top:M,behavior:"instant"})}},10);return()=>{clearTimeout(S)}},[w]),a.jsx("div",{className:"pr-twp tw-flex",children:a.jsxs(or,{modal:!1,open:u,onOpenChange:E,children:[a.jsx(io,{asChild:!0,children:a.jsx(Rl,{ref:x,value:n,handleSearch:I,handleKeyDown:U,handleOnClick:()=>{s(ae.bookNumberToId(e.bookNum)),d(ae.bookNumberToId(e.bookNum)),l(e.chapterNum>0?e.chapterNum:0),f(!0),x.current.focus()},onFocus:()=>{C.current=!0},handleSubmit:V,placeholder:`${ae.bookNumberToEnglishName(e.bookNum)} ${e.chapterNum}:${e.verseNum}`})}),a.jsxs(En,{className:"tw-m-1 tw-overflow-y-auto tw-p-0 tw-font-normal tw-text-foreground/80",style:{width:"233px",maxHeight:"500px",zIndex:"250"},onKeyDown:j,align:"start",ref:m,children:[a.jsx(Xl,{handleSort:()=>console.log("sorting"),handleLocationHistory:()=>console.log("location history"),handleBookmarks:()=>console.log("bookmarks")}),oa.map((S,A)=>k(S).length>0&&a.jsxs("div",{children:[a.jsx(Yt,{className:"tw-font-semibold tw-text-foreground/80",children:Yl[S]}),k(S).map(M=>a.jsx("div",{children:a.jsx(ql,{bookId:M,handleSelectBook:()=>v(M,!1),isSelected:o===M,handleHighlightBook:()=>d(M),handleKeyDown:O,bookType:S,ref:J=>{o===M&&(h.current=J)},children:a.jsx(Hl,{handleSelectChapter:_,endChapter:nn(M),activeChapter:e.bookNum===ae.bookIdToNumber(M)?e.chapterNum:0,highlightedChapter:i,handleHighlightedChapter:J=>{l(J)}})})},M)),oa.length-1!==A?a.jsx(jn,{}):void 0]},S))]})]})})}const ps=kn.cva("pr-twp tw-inline-flex tw-items-center tw-justify-center tw-whitespace-nowrap tw-rounded-md tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-colors focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50",{variants:{variant:{default:"tw-bg-primary tw-text-primary-foreground hover:tw-bg-primary/90",destructive:"tw-bg-destructive tw-text-destructive-foreground hover:tw-bg-destructive/90",outline:"tw-border tw-border-input tw-bg-background hover:tw-bg-accent hover:tw-text-accent-foreground",secondary:"tw-bg-secondary tw-text-secondary-foreground hover:tw-bg-secondary/80",ghost:"hover:tw-bg-accent hover:tw-text-accent-foreground",link:"tw-text-primary tw-underline-offset-4 hover:tw-underline"},size:{default:"tw-h-10 tw-px-4 tw-py-2",sm:"tw-h-9 tw-rounded-md tw-px-3",lg:"tw-h-11 tw-rounded-md tw-px-8",icon:"tw-h-10 tw-w-10"}},defaultVariants:{variant:"default",size:"default"}}),fe=g.forwardRef(({className:e,variant:t,size:n,asChild:r=!1,...o},s)=>{const i=r?Ht.Slot:"button";return a.jsx(i,{className:N(ps({variant:t,size:n,className:e})),ref:s,...o})});fe.displayName="Button";const nc=kn.cva("tw-text-sm tw-font-medium tw-leading-none peer-disabled:tw-cursor-not-allowed peer-disabled:tw-opacity-70"),Ue=g.forwardRef(({className:e,...t},n)=>a.jsx(Qa.Root,{ref:n,className:N("pr-twp",nc(),e),...t}));Ue.displayName=Qa.Root.displayName;const uo=g.forwardRef(({className:e,...t},n)=>a.jsx(gn.Root,{className:N("pr-twp tw-grid tw-gap-2",e),...t,ref:n}));uo.displayName=gn.Root.displayName;const Yn=g.forwardRef(({className:e,...t},n)=>a.jsx(gn.Item,{ref:n,className:N("pr-twp tw-aspect-square tw-h-4 tw-w-4 tw-rounded-full tw-border tw-border-primary tw-text-primary tw-ring-offset-background focus:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-cursor-not-allowed disabled:tw-opacity-50",e),...t,children:a.jsx(gn.Indicator,{className:"tw-flex tw-items-center tw-justify-center",children:a.jsx(ee.Circle,{className:"tw-h-2.5 tw-w-2.5 tw-fill-current tw-text-current"})})}));Yn.displayName=gn.Item.displayName;const rc=bn.Root,oc=bn.Trigger,ws=g.forwardRef(({className:e,align:t="center",sideOffset:n=4,...r},o)=>a.jsx(bn.Portal,{children:a.jsx(bn.Content,{ref:o,align:t,sideOffset:n,className:N("pr-twp tw-z-50 tw-w-72 tw-rounded-md tw-border tw-bg-popover tw-p-4 tw-text-popover-foreground tw-shadow-md tw-outline-none data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0 data-[state=closed]:tw-zoom-out-95 data-[state=open]:tw-zoom-in-95 data-[side=bottom]:tw-slide-in-from-top-2 data-[side=left]:tw-slide-in-from-right-2 data-[side=right]:tw-slide-in-from-left-2 data-[side=top]:tw-slide-in-from-bottom-2",e),...r})}));ws.displayName=bn.Content.displayName;const ac=Xe.Portal,fs=g.forwardRef(({className:e,...t},n)=>a.jsx(Xe.Overlay,{ref:n,className:N("tw-fixed tw-inset-0 tw-z-50 tw-bg-black/80 data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0",e),...t}));fs.displayName=Xe.Overlay.displayName;const sc=g.forwardRef(({className:e,children:t,...n},r)=>a.jsxs(ac,{children:[a.jsx(fs,{}),a.jsxs(Xe.Content,{ref:r,className:N("tw-fixed tw-left-[50%] tw-top-[50%] tw-z-50 tw-grid tw-w-full tw-max-w-lg tw-translate-x-[-50%] tw-translate-y-[-50%] tw-gap-4 tw-border tw-bg-background tw-p-6 tw-shadow-lg tw-duration-200 data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0 data-[state=closed]:tw-zoom-out-95 data-[state=open]:tw-zoom-in-95 data-[state=closed]:tw-slide-out-to-left-1/2 data-[state=closed]:tw-slide-out-to-top-[48%] data-[state=open]:tw-slide-in-from-left-1/2 data-[state=open]:tw-slide-in-from-top-[48%] sm:tw-rounded-lg",e),...n,children:[t,a.jsxs(Xe.Close,{className:"tw-absolute tw-right-4 tw-top-4 tw-rounded-sm tw-opacity-70 tw-ring-offset-background tw-transition-opacity hover:tw-opacity-100 focus:tw-outline-none focus:tw-ring-2 focus:tw-ring-ring focus:tw-ring-offset-2 disabled:tw-pointer-events-none data-[state=open]:tw-bg-accent data-[state=open]:tw-text-muted-foreground",children:[a.jsx(ee.X,{className:"tw-h-4 tw-w-4"}),a.jsx("span",{className:"tw-sr-only",children:"Close"})]})]})]}));sc.displayName=Xe.Content.displayName;const ic=g.forwardRef(({className:e,...t},n)=>a.jsx(Xe.Title,{ref:n,className:N("tw-text-lg tw-font-semibold tw-leading-none tw-tracking-tight",e),...t}));ic.displayName=Xe.Title.displayName;const lc=g.forwardRef(({className:e,...t},n)=>a.jsx(Xe.Description,{ref:n,className:N("tw-text-sm tw-text-muted-foreground",e),...t}));lc.displayName=Xe.Description.displayName;const ms=g.forwardRef(({className:e,...t},n)=>a.jsx(Ce.Command,{ref:n,className:N("tw-flex tw-h-full tw-w-full tw-flex-col tw-overflow-hidden tw-rounded-md tw-bg-popover tw-text-popover-foreground",e),...t}));ms.displayName=Ce.Command.displayName;const hs=g.forwardRef(({className:e,...t},n)=>a.jsxs("div",{className:"tw-flex tw-items-center tw-border-b tw-px-3",children:[a.jsx(ee.Search,{className:"tw-me-2 tw-h-4 tw-w-4 tw-shrink-0 tw-opacity-50"}),a.jsx(Ce.Command.Input,{ref:n,className:N("tw-flex tw-h-11 tw-w-full tw-rounded-md tw-bg-transparent tw-py-3 tw-text-sm tw-outline-none placeholder:tw-text-muted-foreground disabled:tw-cursor-not-allowed disabled:tw-opacity-50",e),...t})]}));hs.displayName=Ce.Command.Input.displayName;const gs=g.forwardRef(({className:e,...t},n)=>a.jsx(Ce.Command.List,{ref:n,className:N("tw-max-h-[300px] tw-overflow-y-auto tw-overflow-x-hidden",e),...t}));gs.displayName=Ce.Command.List.displayName;const bs=g.forwardRef((e,t)=>a.jsx(Ce.Command.Empty,{ref:t,className:"tw-py-6 tw-text-center tw-text-sm",...e}));bs.displayName=Ce.Command.Empty.displayName;const cc=g.forwardRef(({className:e,...t},n)=>a.jsx(Ce.Command.Group,{ref:n,className:N("tw-overflow-hidden tw-p-1 tw-text-foreground [&_[cmdk-group-heading]]:tw-px-2 [&_[cmdk-group-heading]]:tw-py-1.5 [&_[cmdk-group-heading]]:tw-text-xs [&_[cmdk-group-heading]]:tw-font-medium [&_[cmdk-group-heading]]:tw-text-muted-foreground",e),...t}));cc.displayName=Ce.Command.Group.displayName;const dc=g.forwardRef(({className:e,...t},n)=>a.jsx(Ce.Command.Separator,{ref:n,className:N("tw--mx-1 tw-h-px tw-bg-border",e),...t}));dc.displayName=Ce.Command.Separator.displayName;const vs=g.forwardRef(({className:e,...t},n)=>a.jsx(Ce.Command.Item,{ref:n,className:N("tw-relative tw-flex tw-cursor-default tw-select-none tw-items-center tw-rounded-sm tw-px-2 tw-py-1.5 tw-text-sm tw-outline-none data-[disabled=true]:tw-pointer-events-none data-[selected=true]:tw-bg-accent data-[selected=true]:tw-text-accent-foreground data-[disabled=true]:tw-opacity-50",e),...t}));vs.displayName=Ce.Command.Item.displayName;function uc(e){return typeof e=="string"?e:typeof e=="number"?e.toString():e.label}function Wn({id:e,options:t=[],className:n,buttonClassName:r,popoverContentClassName:o,value:s,onChange:i=()=>{},getOptionLabel:l=uc,buttonPlaceholder:c="",textPlaceholder:d="",commandEmptyMessage:u="No option found",buttonVariant:f="outline",dir:w="ltr",isDisabled:b=!1,...x}){const[m,h]=g.useState(!1);return a.jsxs(rc,{open:m,onOpenChange:h,...x,children:[a.jsx(oc,{asChild:!0,children:a.jsxs(fe,{variant:f,role:"combobox","aria-expanded":m,id:e,className:N("tw-w-[200px] tw-justify-between",r??n),disabled:b,children:[a.jsx("span",{className:"tw-overflow-hidden tw-text-ellipsis tw-whitespace-nowrap",children:s?l(s):c}),a.jsx(ee.ChevronsUpDown,{className:"tw-ms-2 tw-h-4 tw-w-4 tw-shrink-0 tw-opacity-50"})]})}),a.jsx(ws,{className:N("tw-w-[200px] tw-p-0",o),dir:w,children:a.jsxs(ms,{children:[a.jsx(hs,{dir:w,placeholder:d,className:"tw-text-inherit"}),a.jsx(bs,{children:u}),a.jsx(gs,{children:t.map(k=>a.jsxs(vs,{value:l(k),onSelect:()=>{i(k),h(!1)},children:[a.jsx(ee.Check,{className:N("tw-me-2 tw-h-4 tw-w-4",{"tw-opacity-0":!s||l(s)!==l(k)})}),l(k)]},l(k)))})]})})]})}function xs({startChapter:e,endChapter:t,handleSelectStartChapter:n,handleSelectEndChapter:r,isDisabled:o=!1,chapterCount:s}){const i=g.useMemo(()=>Array.from({length:s},(d,u)=>u+1),[s]),l=d=>{n(d),d>t&&r(d)},c=d=>{r(d),dd.toString(),value:e},"start chapter"),a.jsx(Ue,{htmlFor:"end-chapters-combobox",children:"to"}),a.jsx(Wn,{isDisabled:o,onChange:c,buttonClassName:"tw-ml-2 tw-w-20",options:i,getOptionLabel:d=>d.toString(),value:t},"end chapter")]})}var ys=(e=>(e.CURRENT_BOOK="current book",e.CHOOSE_BOOKS="choose books",e))(ys||{});const pc=Object.freeze(["%webView_bookSelector_currentBook%","%webView_bookSelector_choose%","%webView_bookSelector_chooseBooks%"]),Cr=(e,t)=>e[t]??t;function wc({handleBookSelectionModeChange:e,currentBookName:t,onSelectBooks:n,selectedBookIds:r,chapterCount:o,endChapter:s,handleSelectEndChapter:i,startChapter:l,handleSelectStartChapter:c,localizedStrings:d}){const u=Cr(d,"%webView_bookSelector_currentBook%"),f=Cr(d,"%webView_bookSelector_choose%"),w=Cr(d,"%webView_bookSelector_chooseBooks%"),[b,x]=g.useState("current book"),m=h=>{x(h),e(h)};return a.jsx(uo,{className:"pr-twp tw-flex",value:b,onValueChange:h=>m(h),children:a.jsxs("div",{className:"tw-flex tw-w-full tw-flex-col tw-gap-4",children:[a.jsxs("div",{className:"tw-grid tw-grid-cols-[25%,25%,50%]",children:[a.jsxs("div",{className:"tw-flex tw-items-center",children:[a.jsx(Yn,{value:"current book"}),a.jsx(Ue,{className:"tw-ml-1",children:u})]}),a.jsx(Ue,{className:"tw-flex tw-items-center",children:t}),a.jsx("div",{className:"tw-flex tw-items-center tw-justify-end",children:a.jsx(xs,{isDisabled:b==="choose books",handleSelectStartChapter:c,handleSelectEndChapter:i,chapterCount:o,startChapter:l,endChapter:s})})]}),a.jsxs("div",{className:"tw-grid tw-grid-cols-[25%,50%,25%]",children:[a.jsxs("div",{className:"tw-flex tw-items-center",children:[a.jsx(Yn,{value:"choose books"}),a.jsx(Ue,{className:"tw-ml-1",children:w})]}),a.jsx(Ue,{className:"tw-flex tw-items-center",children:r.map(h=>ae.bookIdToEnglishName(h)).join(", ")}),a.jsx(fe,{disabled:b==="current book",onClick:()=>n(),children:f})]})]})})}function fc({table:e}){return a.jsxs(or,{children:[a.jsx(Ja.DropdownMenuTrigger,{asChild:!0,children:a.jsxs(fe,{variant:"outline",size:"sm",className:"tw-ml-auto tw-hidden tw-h-8 lg:tw-flex",children:[a.jsx(ee.FilterIcon,{className:"tw-mr-2 tw-h-4 tw-w-4"}),"View"]})}),a.jsxs(En,{align:"end",className:"tw-w-[150px]",children:[a.jsx(Yt,{children:"Toggle columns"}),a.jsx(jn,{}),e.getAllColumns().filter(t=>t.getCanHide()).map(t=>a.jsx(ar,{className:"tw-capitalize",checked:t.getIsVisible(),onCheckedChange:n=>t.toggleVisibility(!!n),children:t.id},t.id))]})]})}const Dt=ge.Root,Ns=ge.Group,Bt=ge.Value,bt=g.forwardRef(({className:e,children:t,...n},r)=>a.jsxs(ge.Trigger,{ref:r,className:N("tw-flex tw-h-10 tw-w-full tw-items-center tw-justify-between tw-rounded-md tw-border tw-border-input tw-bg-background tw-px-3 tw-py-2 tw-text-sm tw-ring-offset-background placeholder:tw-text-muted-foreground focus:tw-outline-none focus:tw-ring-2 focus:tw-ring-ring focus:tw-ring-offset-2 disabled:tw-cursor-not-allowed disabled:tw-opacity-50 [&>span]:tw-line-clamp-1",e),...n,children:[t,a.jsx(ge.Icon,{asChild:!0,children:a.jsx(ee.ChevronDown,{className:"tw-h-4 tw-w-4 tw-opacity-50"})})]}));bt.displayName=ge.Trigger.displayName;const po=g.forwardRef(({className:e,...t},n)=>a.jsx(ge.ScrollUpButton,{ref:n,className:N("tw-flex tw-cursor-default tw-items-center tw-justify-center tw-py-1",e),...t,children:a.jsx(ee.ChevronUp,{className:"tw-h-4 tw-w-4"})}));po.displayName=ge.ScrollUpButton.displayName;const wo=g.forwardRef(({className:e,...t},n)=>a.jsx(ge.ScrollDownButton,{ref:n,className:N("tw-flex tw-cursor-default tw-items-center tw-justify-center tw-py-1",e),...t,children:a.jsx(ee.ChevronDown,{className:"tw-h-4 tw-w-4"})}));wo.displayName=ge.ScrollDownButton.displayName;const vt=g.forwardRef(({className:e,children:t,position:n="popper",...r},o)=>a.jsx(ge.Portal,{children:a.jsxs(ge.Content,{ref:o,className:N("pr-twp tw-relative tw-z-50 tw-max-h-96 tw-min-w-[8rem] tw-overflow-hidden tw-rounded-md tw-border tw-bg-popover tw-text-popover-foreground tw-shadow-md data-[state=open]:tw-animate-in data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=open]:tw-fade-in-0 data-[state=closed]:tw-zoom-out-95 data-[state=open]:tw-zoom-in-95 data-[side=bottom]:tw-slide-in-from-top-2 data-[side=left]:tw-slide-in-from-right-2 data-[side=right]:tw-slide-in-from-left-2 data-[side=top]:tw-slide-in-from-bottom-2",n==="popper"&&"data-[side=bottom]:tw-translate-y-1 data-[side=left]:tw--translate-x-1 data-[side=right]:tw-translate-x-1 data-[side=top]:tw--translate-y-1",e),position:n,...r,children:[a.jsx(po,{}),a.jsx(ge.Viewport,{className:N("tw-p-1",n==="popper"&&"tw-h-[var(--radix-select-trigger-height)] tw-w-full tw-min-w-[var(--radix-select-trigger-width)]"),children:t}),a.jsx(wo,{})]})}));vt.displayName=ge.Content.displayName;const ks=g.forwardRef(({className:e,...t},n)=>a.jsx(ge.Label,{ref:n,className:N("tw-py-1.5 tw-pl-8 tw-pr-2 tw-text-sm tw-font-semibold",e),...t}));ks.displayName=ge.Label.displayName;const Ae=g.forwardRef(({className:e,children:t,...n},r)=>a.jsxs(ge.Item,{ref:r,className:N("tw-relative tw-flex tw-w-full tw-cursor-default tw-select-none tw-items-center tw-rounded-sm tw-py-1.5 tw-pl-8 tw-pr-2 tw-text-sm tw-outline-none focus:tw-bg-accent focus:tw-text-accent-foreground data-[disabled]:tw-pointer-events-none data-[disabled]:tw-opacity-50",e),...n,children:[a.jsx("span",{className:"tw-absolute tw-left-2 tw-flex tw-h-3.5 tw-w-3.5 tw-items-center tw-justify-center",children:a.jsx(ge.ItemIndicator,{children:a.jsx(ee.Check,{className:"tw-h-4 tw-w-4"})})}),a.jsx(ge.ItemText,{children:t})]}));Ae.displayName=ge.Item.displayName;const Ss=g.forwardRef(({className:e,...t},n)=>a.jsx(ge.Separator,{ref:n,className:N("tw--mx-1 tw-my-1 tw-h-px tw-bg-muted",e),...t}));Ss.displayName=ge.Separator.displayName;function mc({table:e}){return a.jsx("div",{className:"tw-flex tw-items-center tw-justify-between tw-px-2 tw-pb-3 tw-pt-3",children:a.jsxs("div",{className:"tw-flex tw-items-center tw-space-x-6 lg:tw-space-x-8",children:[a.jsxs("div",{className:"tw-flex-1 tw-text-sm tw-text-muted-foreground",children:[e.getFilteredSelectedRowModel().rows.length," of"," ",e.getFilteredRowModel().rows.length," row(s) selected"]}),a.jsxs("div",{className:"tw-flex tw-items-center tw-space-x-2",children:[a.jsx("p",{className:"tw-text-nowrap tw-text-sm tw-font-medium",children:"Rows per page"}),a.jsxs(Dt,{value:`${e.getState().pagination.pageSize}`,onValueChange:t=>{e.setPageSize(Number(t))},children:[a.jsx(bt,{className:"tw-h-8 tw-w-[70px]",children:a.jsx(Bt,{placeholder:e.getState().pagination.pageSize})}),a.jsx(vt,{side:"top",children:[10,20,30,40,50].map(t=>a.jsx(Ae,{value:`${t}`,children:t},t))})]})]}),a.jsxs("div",{className:"tw-flex tw-w-[100px] tw-items-center tw-justify-center tw-text-sm tw-font-medium",children:["Page ",e.getState().pagination.pageIndex+1," of ",e.getPageCount()]}),a.jsxs("div",{className:"tw-flex tw-items-center tw-space-x-2",children:[a.jsxs(fe,{variant:"outline",size:"icon",className:"tw-hidden tw-h-8 tw-w-8 tw-p-0 lg:tw-flex",onClick:()=>e.setPageIndex(0),disabled:!e.getCanPreviousPage(),children:[a.jsx("span",{className:"tw-sr-only",children:"Go to first page"}),a.jsx(ee.ArrowLeftIcon,{className:"tw-h-4 tw-w-4"})]}),a.jsxs(fe,{variant:"outline",size:"icon",className:"tw-h-8 tw-w-8 tw-p-0",onClick:()=>e.previousPage(),disabled:!e.getCanPreviousPage(),children:[a.jsx("span",{className:"tw-sr-only",children:"Go to previous page"}),a.jsx(ee.ChevronLeftIcon,{className:"tw-h-4 tw-w-4"})]}),a.jsxs(fe,{variant:"outline",size:"icon",className:"tw-h-8 tw-w-8 tw-p-0",onClick:()=>e.nextPage(),disabled:!e.getCanNextPage(),children:[a.jsx("span",{className:"tw-sr-only",children:"Go to next page"}),a.jsx(ee.ChevronRightIcon,{className:"tw-h-4 tw-w-4"})]}),a.jsxs(fe,{variant:"outline",size:"icon",className:"tw-hidden tw-h-8 tw-w-8 tw-p-0 lg:tw-flex",onClick:()=>e.setPageIndex(e.getPageCount()-1),disabled:!e.getCanNextPage(),children:[a.jsx("span",{className:"tw-sr-only",children:"Go to last page"}),a.jsx(ee.ArrowRightIcon,{className:"tw-h-4 tw-w-4"})]})]})]})})}const Tn=g.forwardRef(({className:e,stickyHeader:t,...n},r)=>a.jsx("div",{className:N("pr-twp tw-relative tw-w-full",{"tw-overflow-auto":!t}),children:a.jsx("table",{ref:r,className:N("tw-w-full tw-caption-bottom tw-text-sm",e),...n})}));Tn.displayName="Table";const Cn=g.forwardRef(({className:e,stickyHeader:t,...n},r)=>a.jsx("thead",{ref:r,className:N({"tw-sticky tw-top-[-1px] tw-bg-background tw-drop-shadow-sm":t},"[&_tr]:tw-border-b",e),...n}));Cn.displayName="TableHeader";const Rn=g.forwardRef(({className:e,...t},n)=>a.jsx("tbody",{ref:n,className:N("[&_tr:last-child]:tw-border-0",e),...t}));Rn.displayName="TableBody";const Es=g.forwardRef(({className:e,...t},n)=>a.jsx("tfoot",{ref:n,className:N("tw-border-t tw-bg-muted/50 tw-font-medium [&>tr]:last:tw-border-b-0",e),...t}));Es.displayName="TableFooter";const Ze=g.forwardRef(({className:e,...t},n)=>a.jsx("tr",{ref:n,className:N("tw-border-b tw-transition-colors hover:tw-bg-muted/50 data-[state=selected]:tw-bg-muted",e),...t}));Ze.displayName="TableRow";const Vt=g.forwardRef(({className:e,...t},n)=>a.jsx("th",{ref:n,className:N("tw-h-12 tw-px-4 tw-text-start tw-align-middle tw-font-medium tw-text-muted-foreground [&:has([role=checkbox])]:tw-pe-0",e),...t}));Vt.displayName="TableHead";const xt=g.forwardRef(({className:e,...t},n)=>a.jsx("td",{ref:n,className:N("tw-p-4 tw-align-middle [&:has([role=checkbox])]:tw-pe-0",e),...t}));xt.displayName="TableCell";const js=g.forwardRef(({className:e,...t},n)=>a.jsx("caption",{ref:n,className:N("tw-mt-4 tw-text-sm tw-text-muted-foreground",e),...t}));js.displayName="TableCaption";function Ts({columns:e,data:t,enablePagination:n=!1,showPaginationControls:r=!1,showColumnVisibilityControls:o=!1,stickyHeader:s=!1,onRowClickHandler:i=()=>{}}){var h;const[l,c]=g.useState([]),[d,u]=g.useState([]),[f,w]=g.useState({}),[b,x]=g.useState({}),m=ke.useReactTable({data:t,columns:e,getCoreRowModel:ke.getCoreRowModel(),...n&&{getPaginationRowModel:ke.getPaginationRowModel()},onSortingChange:c,getSortedRowModel:ke.getSortedRowModel(),onColumnFiltersChange:u,getFilteredRowModel:ke.getFilteredRowModel(),onColumnVisibilityChange:w,onRowSelectionChange:x,state:{sorting:l,columnFilters:d,columnVisibility:f,rowSelection:b}});return a.jsxs("div",{className:"pr-twp",children:[o&&a.jsx(fc,{table:m}),a.jsxs(Tn,{stickyHeader:s,children:[a.jsx(Cn,{stickyHeader:s,children:m.getHeaderGroups().map(k=>a.jsx(Ze,{children:k.headers.map(I=>a.jsx(Vt,{children:I.isPlaceholder?void 0:ke.flexRender(I.column.columnDef.header,I.getContext())},I.id))},k.id))}),a.jsx(Rn,{children:(h=m.getRowModel().rows)!=null&&h.length?m.getRowModel().rows.map(k=>a.jsx(Ze,{onClick:()=>i(k,m),"data-state":k.getIsSelected()&&"selected",children:k.getVisibleCells().map(I=>a.jsx(xt,{children:ke.flexRender(I.column.columnDef.cell,I.getContext())},I.id))},k.id)):a.jsx(Ze,{children:a.jsx(xt,{colSpan:e.length,className:"tw-h-24 tw-text-center",children:"No results."})})})]}),n&&a.jsxs("div",{className:"tw-flex tw-items-center tw-justify-end tw-space-x-2 tw-py-4",children:[a.jsx(fe,{variant:"outline",size:"sm",onClick:()=>m.previousPage(),disabled:!m.getCanPreviousPage(),children:"Previous"}),a.jsx(fe,{variant:"outline",size:"sm",onClick:()=>m.nextPage(),disabled:!m.getCanNextPage(),children:"Next"})]}),n&&r&&a.jsx(mc,{table:m})]})}function hc({occurrenceData:e,setScriptureReference:t,localizedStrings:n}){const r=n["%webView_inventory_occurrences_table_header_reference%"],o=n["%webView_inventory_occurrences_table_header_occurrence%"],s=g.useMemo(()=>{const i=[];return e.forEach(l=>{i.some(c=>W.deepEqual(c,l))||i.push(l)}),i},[e]);return a.jsxs(Tn,{stickyHeader:!0,children:[a.jsx(Cn,{stickyHeader:!0,children:a.jsxs(Ze,{children:[a.jsx(Vt,{children:r}),a.jsx(Vt,{children:o})]})}),a.jsx(Rn,{children:s.length>0&&s.map(i=>a.jsxs(Ze,{onClick:()=>{t(i.reference)},children:[a.jsx(xt,{children:`${ae.bookNumberToEnglishName(i.reference.bookNum)} ${i.reference.chapterNum}:${i.reference.verseNum}`}),a.jsx(xt,{children:i.text})]},`${i.reference.bookNum} ${i.reference.chapterNum}:${i.reference.verseNum}-${i.text}`))})]})}const sr=g.forwardRef(({className:e,...t},n)=>a.jsx(Gr.Root,{ref:n,className:N("tw-peer pr-twp tw-h-4 tw-w-4 tw-shrink-0 tw-rounded-sm tw-border tw-border-primary tw-ring-offset-background focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-cursor-not-allowed disabled:tw-opacity-50 data-[state=checked]:tw-bg-primary data-[state=checked]:tw-text-primary-foreground",e),...t,children:a.jsx(Gr.Indicator,{className:N("tw-flex tw-items-center tw-justify-center tw-text-current"),children:a.jsx(ee.Check,{className:"tw-h-4 tw-w-4"})})}));sr.displayName=Gr.Root.displayName;const Cs=e=>e.split(/(?:\r?\n|\r)|(?=(?:\\(?:v|c|id)))/g),qr=e=>{const t=/^\\[vc]\s+(\d+)/,n=e.match(t);if(n)return+n[1]},Rs=e=>{const t=e.match(/^\\id\s+([A-Za-z]+)/);return t?ae.bookIdToNumber(t[1]):0},Os=(e,t,n)=>n.includes(e)?"unapproved":t.includes(e)?"approved":"unknown",_s=kn.cva("pr-twp tw-inline-flex tw-items-center tw-justify-center tw-rounded-md tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-colors hover:tw-bg-muted hover:tw-text-muted-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50 data-[state=on]:tw-bg-accent data-[state=on]:tw-text-accent-foreground",{variants:{variant:{default:"tw-bg-transparent",outline:"tw-border tw-border-input tw-bg-transparent hover:tw-bg-accent hover:tw-text-accent-foreground"},size:{default:"tw-h-10 tw-px-3",sm:"tw-h-9 tw-px-2.5",lg:"tw-h-11 tw-px-5"}},defaultVariants:{variant:"default",size:"default"}}),gc=g.forwardRef(({className:e,variant:t,size:n,...r},o)=>a.jsx(es.Root,{ref:o,className:N(_s({variant:t,size:n,className:e})),...r}));gc.displayName=es.Root.displayName;const Ps=g.createContext({size:"default",variant:"default"}),fo=g.forwardRef(({className:e,variant:t,size:n,children:r,...o},s)=>a.jsx(rr.Root,{ref:s,className:N("pr-twp tw-flex tw-items-center tw-justify-center tw-gap-1",e),...o,children:a.jsx(Ps.Provider,{value:{variant:t,size:n},children:r})}));fo.displayName=rr.Root.displayName;const wn=g.forwardRef(({className:e,children:t,variant:n,size:r,...o},s)=>{const i=g.useContext(Ps);return a.jsx(rr.Item,{ref:s,className:N(_s({variant:i.variant||n,size:i.size||r}),e),...o,children:t})});wn.displayName=rr.Item.displayName;const ir=e=>e==="asc"?a.jsx(ee.ArrowUpIcon,{className:"tw-ms-2 tw-h-4 tw-w-4"}):e==="desc"?a.jsx(ee.ArrowDownIcon,{className:"tw-ms-2 tw-h-4 tw-w-4"}):a.jsx(ee.ArrowUpDownIcon,{className:"tw-ms-2 tw-h-4 tw-w-4"}),bc=e=>({accessorKey:"item",accessorFn:t=>t.items[0],header:({column:t})=>a.jsxs(fe,{variant:"ghost",onClick:()=>t.toggleSorting(void 0),children:[e,ir(t.getIsSorted())]})}),vc=(e,t)=>({accessorKey:`item${t}`,accessorFn:n=>n.items[t],header:({column:n})=>a.jsxs(fe,{variant:"ghost",onClick:()=>n.toggleSorting(void 0),children:[e,ir(n.getIsSorted())]})}),xc=e=>({accessorKey:"count",header:({column:t})=>a.jsx("div",{className:"tw-flex tw-justify-end tw-tabular-nums",children:a.jsxs(fe,{variant:"ghost",onClick:()=>t.toggleSorting(void 0),children:[e,ir(t.getIsSorted())]})}),cell:({row:t})=>a.jsx("div",{className:"tw-flex tw-justify-end",children:t.getValue("count")})}),Rr=(e,t,n,r,o,s)=>{let i=[...n];e.forEach(c=>{t==="approved"?i.includes(c)||i.push(c):i=i.filter(d=>d!==c)}),r(i);let l=[...o];e.forEach(c=>{t==="unapproved"?l.includes(c)||l.push(c):l=l.filter(d=>d!==c)}),s(l)},yc=(e,t,n,r,o)=>({accessorKey:"status",header:({column:s})=>a.jsx("div",{className:"tw-flex tw-justify-center",children:a.jsxs(fe,{variant:"ghost",onClick:()=>s.toggleSorting(void 0),children:[e,ir(s.getIsSorted())]})}),cell:({row:s})=>{const i=s.getValue("status"),l=s.getValue("item");return a.jsxs(fo,{value:i,variant:"outline",type:"single",children:[a.jsx(wn,{onClick:()=>Rr([l],"approved",t,n,r,o),value:"approved",children:a.jsx(ee.CircleCheckIcon,{})}),a.jsx(wn,{onClick:()=>Rr([l],"unapproved",t,n,r,o),value:"unapproved",children:a.jsx(ee.CircleXIcon,{})}),a.jsx(wn,{onClick:()=>Rr([l],"unknown",t,n,r,o),value:"unknown",children:a.jsx(ee.CircleHelpIcon,{})})]})}}),Nc=Object.freeze(["%webView_inventory_all%","%webView_inventory_approved%","%webView_inventory_unapproved%","%webView_inventory_unknown%","%webView_inventory_scope_currentBook%","%webView_inventory_scope_chapter%","%webView_inventory_scope_verse%","%webView_inventory_filter_text%","%webView_inventory_show_additional_items%","%webView_inventory_occurrences_table_header_reference%","%webView_inventory_occurrences_table_header_occurrence%"]),kc=(e,t,n)=>{let r=e;return t!=="all"&&(r=r.filter(o=>t==="approved"&&o.status==="approved"||t==="unapproved"&&o.status==="unapproved"||t==="unknown"&&o.status==="unknown")),n!==""&&(r=r.filter(o=>o.items[0].includes(n))),r},Sc=(e,t,n,r,o)=>{if(!e)return[];const s=[];let i=t.bookNum,l=t.chapterNum,c=t.verseNum;return Cs(e).forEach(u=>{u.startsWith("\\id")&&(i=Rs(u),l=0,c=0),u.startsWith("\\c")&&(l=qr(u),c=0),u.startsWith("\\v")&&(c=qr(u),l===0&&(l=t.chapterNum));let f=o.exec(u)??void 0;for(;f;){const w=[];f.forEach(h=>w.push(h));const b=f.index,x=s.find(h=>W.deepEqual(h.items,w)),m={reference:{bookNum:i!==void 0?i:-1,chapterNum:l!==void 0?l:-1,verseNum:c!==void 0?c:-1},text:W.substring(u,Math.max(0,b-25),Math.min(b+25,u.length))};if(x)x.count+=1,x.occurrences.push(m);else{const h={items:w,count:1,status:Os(w[0],n,r),occurrences:[m]};s.push(h)}f=o.exec(u)??void 0}}),s},Je=(e,t)=>e[t]??t;function Ec({scriptureReference:e,setScriptureReference:t,localizedStrings:n,extractItems:r,additionalItemsLabels:o,approvedItems:s,unapprovedItems:i,text:l,scope:c,onScopeChange:d,columns:u}){const f=Je(n,"%webView_inventory_all%"),w=Je(n,"%webView_inventory_approved%"),b=Je(n,"%webView_inventory_unapproved%"),x=Je(n,"%webView_inventory_unknown%"),m=Je(n,"%webView_inventory_scope_currentBook%"),h=Je(n,"%webView_inventory_scope_chapter%"),k=Je(n,"%webView_inventory_scope_verse%"),I=Je(n,"%webView_inventory_filter_text%"),C=Je(n,"%webView_inventory_show_additional_items%"),[E,v]=g.useState(!1),[_,V]=g.useState("all"),[U,j]=g.useState(""),[O,S]=g.useState([]),A=g.useMemo(()=>l?r instanceof RegExp?Sc(l,e,s,i,r):r(l,e,s,i):[],[l,r,e,s,i]),M=g.useMemo(()=>{if(E)return A;const y=[];return A.forEach(T=>{const z=T.items[0],L=y.find(B=>B.items[0]===z);L?(L.count+=T.count,L.occurrences=L.occurrences.concat(T.occurrences)):y.push({items:[z],count:T.count,occurrences:T.occurrences,status:T.status})}),y},[E,A]),J=g.useMemo(()=>kc(M,_,U),[M,_,U]),Y=g.useMemo(()=>{var z,L;if(!E)return u;const y=(z=o==null?void 0:o.tableHeaders)==null?void 0:z.length;if(!y)return u;const T=[];for(let B=0;B{S([])},[J]);const F=(y,T)=>{T.setRowSelection(()=>{const z={};return z[y.index]=!0,z}),S(y.original.items)},te=y=>{if(y==="book"||y==="chapter"||y==="verse")d(y);else throw new Error(`Invalid scope value: ${y}`)},se=y=>{if(y==="all"||y==="approved"||y==="unapproved"||y==="unknown")V(y);else throw new Error(`Invalid status filter value: ${y}`)},oe=g.useMemo(()=>{if(M.length===0||O.length===0)return[];const y=M.filter(T=>W.deepEqual(E?T.items:[T.items[0]],O));if(y.length>1)throw new Error("Selected item is not unique");return y[0].occurrences},[O,E,M]);return a.jsxs("div",{className:"pr-twp tw-flex tw-h-full tw-flex-col",children:[a.jsxs("div",{className:"tw-flex tw-items-stretch",children:[a.jsxs(Dt,{onValueChange:y=>se(y),defaultValue:_,children:[a.jsx(bt,{className:"tw-m-1",children:a.jsx(Bt,{placeholder:"Select filter"})}),a.jsxs(vt,{children:[a.jsx(Ae,{value:"all",children:f}),a.jsx(Ae,{value:"approved",children:w}),a.jsx(Ae,{value:"unapproved",children:b}),a.jsx(Ae,{value:"unknown",children:x})]})]}),a.jsxs(Dt,{onValueChange:y=>te(y),defaultValue:c,children:[a.jsx(bt,{className:"tw-m-1",children:a.jsx(Bt,{placeholder:"Select scope"})}),a.jsxs(vt,{children:[a.jsx(Ae,{value:"book",children:m}),a.jsx(Ae,{value:"chapter",children:h}),a.jsx(Ae,{value:"verse",children:k})]})]}),a.jsx(St,{className:"tw-m-1 tw-rounded-md tw-border",placeholder:I,value:U,onChange:y=>{j(y.target.value)}}),o&&a.jsxs("div",{className:"tw-m-1 tw-flex tw-items-center tw-rounded-md tw-border",children:[a.jsx(sr,{className:"tw-m-1",checked:E,onCheckedChange:y=>{S([]),v(y)}}),a.jsx(Ue,{className:"tw-m-1 tw-flex-shrink-0 tw-whitespace-nowrap",children:(o==null?void 0:o.checkboxText)??C})]})]}),a.jsx("div",{className:"tw-m-1 tw-flex-1 tw-overflow-auto tw-rounded-md tw-border",children:a.jsx(Ts,{columns:Y,data:J,onRowClickHandler:F,stickyHeader:!0})}),oe.length>0&&a.jsx("div",{className:"tw-m-1 tw-flex-1 tw-overflow-auto tw-rounded-md tw-border",children:a.jsx(hc,{occurrenceData:oe,setScriptureReference:t,localizedStrings:n})})]})}function mo({className:e,onSearch:t,placeholder:n,isFullWidth:r}){const[o,s]=g.useState(""),i=l=>{s(l),t(l)};return a.jsx(St,{className:N("tw-flex tw-h-10 tw-rounded-md tw-border tw-border-input tw-bg-background tw-px-3 tw-py-2 tw-text-sm tw-ring-offset-background file:tw-border-0 file:tw-bg-transparent file:tw-text-sm file:tw-font-medium placeholder:tw-text-muted-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-[color:hsl(240,5%,64.9%)] focus-visible:tw-ring-offset-2 disabled:tw-cursor-not-allowed disabled:tw-opacity-50",{"tw-w-full":r},e),placeholder:n,value:o,onChange:l=>i(l.target.value)})}const ho=g.forwardRef(({className:e,...t},n)=>a.jsx(Re.Root,{orientation:"vertical",ref:n,className:N("tw-flex tw-gap-1 tw-rounded-md tw-text-muted-foreground",e),...t}));ho.displayName=Re.List.displayName;const go=g.forwardRef(({className:e,...t},n)=>a.jsx(Re.List,{ref:n,className:N("tw-flex-fit tw-mlk-items-center tw-w-[124px] tw-justify-center tw-rounded-md tw-bg-muted tw-p-1 tw-text-muted-foreground",e),...t}));go.displayName=Re.List.displayName;const Is=g.forwardRef(({className:e,...t},n)=>a.jsx(Re.Trigger,{ref:n,...t,className:N("overflow-clip tw-inline-flex tw-w-[116px] tw-cursor-pointer tw-items-center tw-justify-center tw-break-words tw-rounded-sm tw-border-0 tw-bg-muted tw-px-3 tw-py-1.5 tw-text-sm tw-font-medium tw-text-inherit tw-ring-offset-background tw-transition-all hover:tw-text-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50 data-[state=active]:tw-bg-background data-[state=active]:tw-text-foreground data-[state=active]:tw-shadow-sm",e)})),bo=g.forwardRef(({className:e,...t},n)=>a.jsx(Re.Content,{ref:n,className:N("tw-ms-5 tw-flex-grow tw-text-foreground tw-ring-offset-background focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2",e),...t}));bo.displayName=Re.Content.displayName;function jc({tabList:e,onSearch:t,searchPlaceholder:n,headerTitle:r,isSearchBarFullWidth:o=!1,direction:s="ltr"}){return a.jsxs("div",{className:"pr-twp",children:[a.jsxs("div",{className:"tw-sticky tw-top-0 tw-space-y-2 tw-pb-2",children:[r?a.jsx("h1",{children:r}):"",a.jsx(mo,{isFullWidth:o,onSearch:t,placeholder:n})]}),a.jsxs(ho,{dir:s,children:[a.jsx(go,{children:e.map(i=>a.jsx(Is,{value:i.value,children:i.value},i.key))}),e.map(i=>a.jsx(bo,{value:i.value,children:i.content},i.key))]})]})}const lr=g.forwardRef(({className:e,orientation:t="horizontal",decorative:n=!0,...r},o)=>a.jsx(ts.Root,{ref:o,decorative:n,orientation:t,className:N("pr-twp tw-shrink-0 tw-bg-border",t==="horizontal"?"tw-h-[1px] tw-w-full":"tw-h-full tw-w-[1px]",e),...r}));lr.displayName=ts.Root.displayName;function aa({className:e,...t}){return a.jsx("div",{className:N("pr-twp tw-animate-pulse tw-rounded-md tw-bg-muted",e),...t})}const Tc=Sn.Provider,Cc=Sn.Root,Rc=Sn.Trigger,Ms=g.forwardRef(({className:e,sideOffset:t=4,...n},r)=>a.jsx(Sn.Content,{ref:r,sideOffset:t,className:N("pr-twp tw-z-50 tw-overflow-hidden tw-rounded-md tw-border tw-bg-popover tw-px-3 tw-py-1.5 tw-text-sm tw-text-popover-foreground tw-shadow-md tw-animate-in tw-fade-in-0 tw-zoom-in-95 data-[state=closed]:tw-animate-out data-[state=closed]:tw-fade-out-0 data-[state=closed]:tw-zoom-out-95 data-[side=bottom]:tw-slide-in-from-top-2 data-[side=left]:tw-slide-in-from-right-2 data-[side=right]:tw-slide-in-from-left-2 data-[side=top]:tw-slide-in-from-bottom-2",e),...n}));Ms.displayName=Sn.Content.displayName;const Oc="16rem",_c="3rem",$s=g.createContext(void 0);function cr(){const e=g.useContext($s);if(!e)throw new Error("useSidebar must be used within a SidebarProvider.");return e}const As=g.forwardRef(({defaultOpen:e=!0,open:t,onOpenChange:n,className:r,style:o,children:s,...i},l)=>{const[c,d]=g.useState(e),u=t??c,f=g.useCallback(m=>{const h=typeof m=="function"?m(u):m;n?n(h):d(h)},[n,u]),w=g.useCallback(()=>f(m=>!m),[f]),b=u?"expanded":"collapsed",x=g.useMemo(()=>({state:b,open:u,setOpen:f,toggleSidebar:w}),[b,u,f,w]);return a.jsx($s.Provider,{value:x,children:a.jsx(Tc,{delayDuration:0,children:a.jsx("div",{style:{"--sidebar-width":Oc,"--sidebar-width-icon":_c,...o},className:N("tw-group/sidebar-wrapper pr-twp tw-flex tw-w-full has-[[data-variant=inset]]:tw-bg-sidebar",r),ref:l,...i,children:s})})})});As.displayName="SidebarProvider";const Ds=g.forwardRef(({side:e="left",variant:t="sidebar",collapsible:n="offcanvas",className:r,children:o,...s},i)=>{const{state:l}=cr();return n==="none"?a.jsx("div",{className:N("tw-flex tw-h-full tw-w-[--sidebar-width] tw-flex-col tw-bg-sidebar tw-text-sidebar-foreground",r),ref:i,...s,children:o}):a.jsxs("div",{ref:i,className:"tw-group tw-peer tw-hidden tw-text-sidebar-foreground md:tw-block","data-state":l,"data-collapsible":l==="collapsed"?n:"","data-variant":t,"data-side":e,children:[a.jsx("div",{className:N("tw-relative tw-h-svh tw-w-[--sidebar-width] tw-bg-transparent tw-transition-[width] tw-duration-200 tw-ease-linear","group-data-[collapsible=offcanvas]:tw-w-0","group-data-[side=right]:tw-rotate-180",t==="floating"||t==="inset"?"group-data-[collapsible=icon]:tw-w-[calc(var(--sidebar-width-icon)_+_theme(spacing.4))]":"group-data-[collapsible=icon]:tw-w-[--sidebar-width-icon]")}),a.jsx("div",{className:N("tw-absolute tw-inset-y-0 tw-z-10 tw-hidden tw-h-svh tw-w-[--sidebar-width] tw-transition-[left,right,width] tw-duration-200 tw-ease-linear md:tw-flex",e==="left"?"tw-left-0 group-data-[collapsible=offcanvas]:tw-left-[calc(var(--sidebar-width)*-1)]":"tw-right-0 group-data-[collapsible=offcanvas]:tw-right-[calc(var(--sidebar-width)*-1)]",t==="floating"||t==="inset"?"tw-p-2 group-data-[collapsible=icon]:tw-w-[calc(var(--sidebar-width-icon)_+_theme(spacing.4)_+2px)]":"group-data-[collapsible=icon]:tw-w-[--sidebar-width-icon] group-data-[side=left]:tw-border-r group-data-[side=right]:tw-border-l",r),...s,children:a.jsx("div",{"data-sidebar":"sidebar",className:"tw-flex tw-h-full tw-w-full tw-flex-col tw-bg-sidebar group-data-[variant=floating]:tw-rounded-lg group-data-[variant=floating]:tw-border group-data-[variant=floating]:tw-border-sidebar-border group-data-[variant=floating]:tw-shadow",children:o})})]})});Ds.displayName="Sidebar";const Pc=g.forwardRef(({className:e,onClick:t,...n},r)=>{const{toggleSidebar:o}=cr();return a.jsxs(fe,{ref:r,"data-sidebar":"trigger",variant:"ghost",size:"icon",className:N("tw-h-7 tw-w-7",e),onClick:s=>{t==null||t(s),o()},...n,children:[a.jsx(ee.PanelLeft,{}),a.jsx("span",{className:"tw-sr-only",children:"Toggle Sidebar"})]})});Pc.displayName="SidebarTrigger";const Ic=g.forwardRef(({className:e,...t},n)=>{const{toggleSidebar:r}=cr();return a.jsx("button",{type:"button",ref:n,"data-sidebar":"rail","aria-label":"Toggle Sidebar",tabIndex:-1,onClick:r,title:"Toggle Sidebar",className:N("tw-absolute tw-inset-y-0 tw-z-20 tw-hidden tw-w-4 tw--translate-x-1/2 tw-transition-all tw-ease-linear after:tw-absolute after:tw-inset-y-0 after:tw-left-1/2 after:tw-w-[2px] hover:after:tw-bg-sidebar-border group-data-[side=left]:tw--right-4 group-data-[side=right]:tw-left-0 sm:tw-flex","[[data-side=left]_&]:tw-cursor-w-resize [[data-side=right]_&]:tw-cursor-e-resize","[[data-side=left][data-state=collapsed]_&]:tw-cursor-e-resize [[data-side=right][data-state=collapsed]_&]:tw-cursor-w-resize","group-data-[collapsible=offcanvas]:tw-translate-x-0 group-data-[collapsible=offcanvas]:after:tw-left-full group-data-[collapsible=offcanvas]:hover:tw-bg-sidebar","[[data-side=left][data-collapsible=offcanvas]_&]:tw--right-2","[[data-side=right][data-collapsible=offcanvas]_&]:tw--left-2",e),...t})});Ic.displayName="SidebarRail";const Bs=g.forwardRef(({className:e,...t},n)=>a.jsx("main",{ref:n,className:N("tw-relative tw-flex tw-flex-1 tw-flex-col tw-bg-background","peer-data-[variant=inset]:tw-min-h-[calc(100svh-theme(spacing.4))] md:peer-data-[variant=inset]:tw-m-2 md:peer-data-[state=collapsed]:peer-data-[variant=inset]:tw-ml-2 md:peer-data-[variant=inset]:tw-ml-0 md:peer-data-[variant=inset]:tw-rounded-xl md:peer-data-[variant=inset]:tw-shadow",e),...t}));Bs.displayName="SidebarInset";const Mc=g.forwardRef(({className:e,...t},n)=>a.jsx(St,{ref:n,"data-sidebar":"input",className:N("tw-h-8 tw-w-full tw-bg-background tw-shadow-none focus-visible:tw-ring-2 focus-visible:tw-ring-sidebar-ring",e),...t}));Mc.displayName="SidebarInput";const $c=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,"data-sidebar":"header",className:N("tw-flex tw-flex-col tw-gap-2 tw-p-2",e),...t}));$c.displayName="SidebarHeader";const Ac=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,"data-sidebar":"footer",className:N("tw-flex tw-flex-col tw-gap-2 tw-p-2",e),...t}));Ac.displayName="SidebarFooter";const Dc=g.forwardRef(({className:e,...t},n)=>a.jsx(lr,{ref:n,"data-sidebar":"separator",className:N("tw-mx-2 tw-w-auto tw-bg-sidebar-border",e),...t}));Dc.displayName="SidebarSeparator";const Vs=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,"data-sidebar":"content",className:N("tw-flex tw-min-h-0 tw-flex-1 tw-flex-col tw-gap-2 tw-overflow-auto group-data-[collapsible=icon]:tw-overflow-hidden",e),...t}));Vs.displayName="SidebarContent";const Hr=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,"data-sidebar":"group",className:N("tw-relative tw-flex tw-w-full tw-min-w-0 tw-flex-col tw-p-2",e),...t}));Hr.displayName="SidebarGroup";const Xr=g.forwardRef(({className:e,asChild:t=!1,...n},r)=>{const o=t?Ht.Slot:"div";return a.jsx(o,{ref:r,"data-sidebar":"group-label",className:N("tw-flex tw-h-8 tw-shrink-0 tw-items-center tw-rounded-md tw-px-2 tw-text-xs tw-font-medium tw-text-sidebar-foreground/70 tw-outline-none tw-ring-sidebar-ring tw-transition-[margin,opa] tw-duration-200 tw-ease-linear focus-visible:tw-ring-2 [&>svg]:tw-size-4 [&>svg]:tw-shrink-0","group-data-[collapsible=icon]:tw--mt-8 group-data-[collapsible=icon]:tw-opacity-0",e),...n})});Xr.displayName="SidebarGroupLabel";const Bc=g.forwardRef(({className:e,asChild:t=!1,...n},r)=>{const o=t?Ht.Slot:"button";return a.jsx(o,{ref:r,"data-sidebar":"group-action",className:N("tw-absolute tw-right-3 tw-top-3.5 tw-flex tw-aspect-square tw-w-5 tw-items-center tw-justify-center tw-rounded-md tw-p-0 tw-text-sidebar-foreground tw-outline-none tw-ring-sidebar-ring tw-transition-transform hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground focus-visible:tw-ring-2 [&>svg]:tw-size-4 [&>svg]:tw-shrink-0","after:tw-absolute after:tw--inset-2 after:md:tw-hidden","group-data-[collapsible=icon]:tw-hidden",e),...n})});Bc.displayName="SidebarGroupAction";const Yr=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,"data-sidebar":"group-content",className:N("tw-w-full tw-text-sm",e),...t}));Yr.displayName="SidebarGroupContent";const zs=g.forwardRef(({className:e,...t},n)=>a.jsx("ul",{ref:n,"data-sidebar":"menu",className:N("tw-flex tw-w-full tw-min-w-0 tw-flex-col tw-gap-1",e),...t}));zs.displayName="SidebarMenu";const Ls=g.forwardRef(({className:e,...t},n)=>a.jsx("li",{ref:n,"data-sidebar":"menu-item",className:N("tw-group/menu-item tw-relative",e),...t}));Ls.displayName="SidebarMenuItem";const Vc=kn.cva("tw-peer/menu-button tw-flex tw-w-full tw-items-center tw-gap-2 tw-overflow-hidden tw-rounded-md tw-p-2 tw-text-left tw-text-sm tw-outline-none tw-ring-sidebar-ring tw-transition-[width,height,padding] hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground focus-visible:tw-ring-2 active:tw-bg-sidebar-accent active:tw-text-sidebar-accent-foreground disabled:tw-pointer-events-none disabled:tw-opacity-50 tw-group-has-[[data-sidebar=menu-action]]/menu-item:pr-8 aria-disabled:tw-pointer-events-none aria-disabled:tw-opacity-50 data-[active=true]:tw-font-medium data-[active=true]:tw-text-sidebar-accent-foreground data-[state=open]:hover:tw-bg-sidebar-accent data-[state=open]:hover:tw-text-sidebar-accent-foreground group-data-[collapsible=icon]:tw-!size-8 group-data-[collapsible=icon]:tw-!p-2 [&>span:last-child]:tw-truncate [&>svg]:tw-size-4 [&>svg]:tw-shrink-0",{variants:{variant:{default:"hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground",outline:"tw-bg-background tw-shadow-[0_0_0_1px_hsl(var(--sidebar-border))] hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground hover:tw-shadow-[0_0_0_1px_hsl(var(--sidebar-accent))]"},size:{default:"tw-h-8 tw-text-sm",sm:"tw-h-7 tw-text-xs",lg:"tw-h-12 tw-text-sm group-data-[collapsible=icon]:tw-!p-0"}},defaultVariants:{variant:"default",size:"default"}}),Fs=g.forwardRef(({asChild:e=!1,isActive:t=!1,variant:n="default",size:r="default",tooltip:o,className:s,...i},l)=>{const c=e?Ht.Slot:"button",{state:d}=cr(),u=a.jsx(c,{ref:l,"data-sidebar":"menu-button","data-size":r,"data-active":t,className:N(Vc({variant:n,size:r}),s),...i});return o?(typeof o=="string"&&(o={children:o}),a.jsxs(Cc,{children:[a.jsx(Rc,{asChild:!0,children:u}),a.jsx(Ms,{side:"right",align:"center",hidden:d!=="collapsed",...o})]})):u});Fs.displayName="SidebarMenuButton";const zc=g.forwardRef(({className:e,asChild:t=!1,showOnHover:n=!1,...r},o)=>{const s=t?Ht.Slot:"button";return a.jsx(s,{ref:o,"data-sidebar":"menu-action",className:N("tw-peer-hover/menu-button:text-sidebar-accent-foreground tw-absolute tw-right-1 tw-top-1.5 tw-flex tw-aspect-square tw-w-5 tw-items-center tw-justify-center tw-rounded-md tw-p-0 tw-text-sidebar-foreground tw-outline-none tw-ring-sidebar-ring tw-transition-transform hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground focus-visible:tw-ring-2 [&>svg]:tw-size-4 [&>svg]:tw-shrink-0","after:tw-absolute after:tw--inset-2 after:md:tw-hidden","tw-peer-data-[size=sm]/menu-button:top-1","tw-peer-data-[size=default]/menu-button:top-1.5","tw-peer-data-[size=lg]/menu-button:top-2.5","group-data-[collapsible=icon]:tw-hidden",n&&"tw-group-focus-within/menu-item:opacity-100 tw-group-hover/menu-item:opacity-100 tw-peer-data-[active=true]/menu-button:text-sidebar-accent-foreground data-[state=open]:tw-opacity-100 md:tw-opacity-0",e),...r})});zc.displayName="SidebarMenuAction";const Lc=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,"data-sidebar":"menu-badge",className:N("tw-pointer-events-none tw-absolute tw-right-1 tw-flex tw-h-5 tw-min-w-5 tw-select-none tw-items-center tw-justify-center tw-rounded-md tw-px-1 tw-text-xs tw-font-medium tw-tabular-nums tw-text-sidebar-foreground","tw-peer-hover/menu-button:text-sidebar-accent-foreground tw-peer-data-[active=true]/menu-button:text-sidebar-accent-foreground","tw-peer-data-[size=sm]/menu-button:top-1","tw-peer-data-[size=default]/menu-button:top-1.5","tw-peer-data-[size=lg]/menu-button:top-2.5","group-data-[collapsible=icon]:tw-hidden",e),...t}));Lc.displayName="SidebarMenuBadge";const Fc=g.forwardRef(({className:e,showIcon:t=!1,...n},r)=>{const o=g.useMemo(()=>`${Math.floor(Math.random()*40)+50}%`,[]);return a.jsxs("div",{ref:r,"data-sidebar":"menu-skeleton",className:N("tw-flex tw-h-8 tw-items-center tw-gap-2 tw-rounded-md tw-px-2",e),...n,children:[t&&a.jsx(aa,{className:"tw-size-4 tw-rounded-md","data-sidebar":"menu-skeleton-icon"}),a.jsx(aa,{className:"tw-h-4 tw-max-w-[--skeleton-width] tw-flex-1","data-sidebar":"menu-skeleton-text",style:{"--skeleton-width":o}})]})});Fc.displayName="SidebarMenuSkeleton";const Gc=g.forwardRef(({className:e,...t},n)=>a.jsx("ul",{ref:n,"data-sidebar":"menu-sub",className:N("tw-mx-3.5 tw-flex tw-min-w-0 tw-translate-x-px tw-flex-col tw-gap-1 tw-border-l tw-border-sidebar-border tw-px-2.5 tw-py-0.5","group-data-[collapsible=icon]:tw-hidden",e),...t}));Gc.displayName="SidebarMenuSub";const Uc=g.forwardRef(({...e},t)=>a.jsx("li",{ref:t,...e}));Uc.displayName="SidebarMenuSubItem";const qc=g.forwardRef(({asChild:e=!1,size:t="md",isActive:n,className:r,...o},s)=>{const i=e?Ht.Slot:"a";return a.jsx(i,{ref:s,"data-sidebar":"menu-sub-button","data-size":t,"data-active":n,className:N("tw-flex tw-h-7 tw-min-w-0 tw--translate-x-px tw-items-center tw-gap-2 tw-overflow-hidden tw-rounded-md tw-px-2 tw-text-sidebar-foreground tw-outline-none tw-ring-sidebar-ring hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground focus-visible:tw-ring-2 active:tw-bg-sidebar-accent active:tw-text-sidebar-accent-foreground disabled:tw-pointer-events-none disabled:tw-opacity-50 aria-disabled:tw-pointer-events-none aria-disabled:tw-opacity-50 [&>span:last-child]:tw-truncate [&>svg]:tw-size-4 [&>svg]:tw-shrink-0 [&>svg]:tw-text-sidebar-accent-foreground","data-[active=true]:tw-bg-sidebar-accent data-[active=true]:tw-text-sidebar-accent-foreground",t==="sm"&&"tw-text-xs",t==="md"&&"tw-text-sm","group-data-[collapsible=icon]:tw-hidden",r),...o})});qc.displayName="SidebarMenuSubButton";function Gs({id:e,extensionLabels:t,projectInfo:n,handleSelectSidebarItem:r,selectedSidebarItem:o,extensionsSidebarGroupLabel:s,projectsSidebarGroupLabel:i,buttonPlaceholderText:l}){const c=g.useCallback((f,w)=>{r(f,w)},[r]),d=g.useCallback(f=>{const w=n.find(b=>b.projectId===f);return w?w.projectName:f},[n]),u=g.useCallback(f=>!o.projectId&&f===o.label,[o]);return a.jsx(Ds,{id:e,collapsible:"none",variant:"inset",className:"tw-w-96 tw-gap-2 tw-overflow-y-auto tw-rounded tw-bg-slate-100",children:a.jsxs(Vs,{children:[a.jsxs(Hr,{children:[a.jsx(Xr,{className:"tw-text-sm tw-text-gray-400",children:s}),a.jsx(Yr,{children:a.jsx(zs,{children:t.map(f=>a.jsx(Ls,{children:a.jsx(Fs,{className:N("tw-rounded tw-py-2 tw-text-sm tw-text-gray-500 hover:tw-bg-white hover:tw-text-gray-900 hover:tw-shadow-sm active:tw-bg-white",{"tw-bg-white tw-text-gray-900 tw-shadow-sm":u(f)}),onClick:()=>c(f),isActive:u(f),children:a.jsx("span",{className:"tw-pl-3",children:f})})},f))})})]}),a.jsxs(Hr,{children:[a.jsx(Xr,{className:"tw-text-sm tw-text-gray-400",children:i}),a.jsx(Yr,{className:"tw-pl-3",children:a.jsx(Wn,{popoverContentClassName:"tw-z-[1000]",options:n.flatMap(f=>f.projectId),getOptionLabel:f=>d(f),buttonPlaceholder:l,onChange:f=>{const w=d(f);c(w,f)},value:(o==null?void 0:o.projectId)??void 0})})]})]})})}function Hc({id:e,extensionLabels:t,projectInfo:n,children:r,handleSelectSidebarItem:o,selectedSidebarItem:s,onSearch:i,extensionsSidebarGroupLabel:l,projectsSidebarGroupLabel:c,buttonPlaceholderText:d}){return a.jsxs("div",{className:"tw-box-border tw-flex tw-h-full tw-flex-col tw-p-3",children:[a.jsx("div",{className:"tw-box-border tw-flex tw-items-center tw-justify-center tw-py-4",children:a.jsx(mo,{className:"tw-w-9/12",onSearch:i,placeholder:"Search app settings, extension settings, and project settings"})}),a.jsxs(As,{id:e,className:"tw-h-full tw-flex-1 tw-gap-4 tw-overflow-auto",children:[a.jsx(Gs,{extensionLabels:t,projectInfo:n,handleSelectSidebarItem:o,selectedSidebarItem:s,extensionsSidebarGroupLabel:l,projectsSidebarGroupLabel:c,buttonPlaceholderText:d}),a.jsx(Bs,{className:"tw-overflow-y-auto",children:r})]})]})}const rt="scrBook",Xc="scrRef",pt="source",Yc="details",Wc="Scripture Reference",Kc="Scripture Book",Us="Type",Jc="Details";function Zc(e,t){const n=t??!1;return[{accessorFn:r=>`${ae.bookNumberToId(r.start.bookNum)} ${r.start.chapterNum}:${r.start.verseNum}`,id:rt,header:(e==null?void 0:e.scriptureReferenceColumnName)??Wc,cell:r=>{const o=r.row.original;return r.row.getIsGrouped()?ae.bookNumberToEnglishName(o.start.bookNum):r.row.groupingColumnId===rt?W.formatScrRef(o.start):void 0},getGroupingValue:r=>r.start.bookNum,sortingFn:(r,o)=>W.compareScrRefs(r.original.start,o.original.start),enableGrouping:!0},{accessorFn:r=>W.formatScrRef(r.start),id:Xc,header:void 0,cell:r=>{const o=r.row.original;return r.row.getIsGrouped()?void 0:W.formatScrRef(o.start)},sortingFn:(r,o)=>W.compareScrRefs(r.original.start,o.original.start),enableGrouping:!1},{accessorFn:r=>r.source.displayName,id:pt,header:n?(e==null?void 0:e.typeColumnName)??Us:void 0,cell:r=>n||r.row.getIsGrouped()?r.getValue():void 0,getGroupingValue:r=>r.source.id,sortingFn:(r,o)=>r.original.source.displayName.localeCompare(o.original.source.displayName),enableGrouping:!0},{accessorFn:r=>r.detail,id:Yc,header:(e==null?void 0:e.detailsColumnName)??Jc,cell:r=>r.getValue(),enableGrouping:!1}]}const Qc=e=>{if(!("offset"in e.start))throw new Error("No offset available in range start");if(e.end&&!("offset"in e.end))throw new Error("No offset available in range end");const{offset:t}=e.start;let n=0;return e.end&&({offset:n}=e.end),!e.end||W.compareScrRefs(e.start,e.end)===0?`${W.scrRefToBBBCCCVVV(e.start)}+${t}`:`${W.scrRefToBBBCCCVVV(e.start)}+${t}-${W.scrRefToBBBCCCVVV(e.end)}+${n}`},sa=e=>`${Qc({start:e.start,end:e.end})} ${e.source.displayName} ${e.detail}`;function ed({sources:e,showColumnHeaders:t=!1,showSourceColumn:n=!1,scriptureReferenceColumnName:r,scriptureBookGroupName:o,typeColumnName:s,detailsColumnName:i,onRowSelected:l,direction:c="ltr"}){const[d,u]=g.useState([]),[f,w]=g.useState([{id:rt,desc:!1}]),[b,x]=g.useState({}),m=g.useMemo(()=>e.flatMap(j=>j.data.map(O=>({...O,source:j.source}))),[e]),h=g.useMemo(()=>Zc({scriptureReferenceColumnName:r,typeColumnName:s,detailsColumnName:i},n),[r,s,i,n]);g.useEffect(()=>{d.includes(pt)?w([{id:pt,desc:!1},{id:rt,desc:!1}]):w([{id:rt,desc:!1}])},[d]);const k=ke.useReactTable({data:m,columns:h,state:{grouping:d,sorting:f,rowSelection:b},onGroupingChange:u,onSortingChange:w,onRowSelectionChange:x,getExpandedRowModel:ke.getExpandedRowModel(),getGroupedRowModel:ke.getGroupedRowModel(),getCoreRowModel:ke.getCoreRowModel(),getSortedRowModel:ke.getSortedRowModel(),getRowId:sa,autoResetExpanded:!1,enableMultiRowSelection:!1,enableSubRowSelection:!1});g.useEffect(()=>{if(l){const j=k.getSelectedRowModel().rowsById,O=Object.keys(j);if(O.length===1){const S=m.find(A=>sa(A)===O[0])||void 0;S&&l(S)}}},[b,m,l,k]);const I=o??Kc,C=s??Us,E=[{label:"No Grouping",value:[]},{label:`Group by ${I}`,value:[rt]},{label:`Group by ${C}`,value:[pt]},{label:`Group by ${I} and ${C}`,value:[rt,pt]},{label:`Group by ${C} and ${I}`,value:[pt,rt]}],v=j=>{u(JSON.parse(j))},_=(j,O)=>{!j.getIsGrouped()&&!j.getIsSelected()&&j.getToggleSelectedHandler()(O)},V=(j,O)=>j.getIsGrouped()?"":N("banded-row",O%2===0?"even":"odd"),U=(j,O,S)=>{if(!((j==null?void 0:j.length)===0||O.depth{v(j)},children:[a.jsx(bt,{className:"tw-mb-1 tw-mt-2",children:a.jsx(Bt,{})}),a.jsx(vt,{position:"item-aligned",children:a.jsx(Ns,{children:E.map(j=>a.jsx(Ae,{value:JSON.stringify(j.value),children:j.label},j.label))})})]}),a.jsxs(Tn,{className:"tw-relative tw-flex tw-flex-col tw-overflow-y-auto tw-p-0",children:[t&&a.jsx(Cn,{children:k.getHeaderGroups().map(j=>a.jsx(Ze,{children:j.headers.filter(O=>O.column.columnDef.header).map(O=>a.jsx(Vt,{colSpan:O.colSpan,className:"top-0 tw-sticky",children:O.isPlaceholder?void 0:a.jsxs("div",{children:[O.column.getCanGroup()?a.jsx(fe,{variant:"ghost",title:`Toggle grouping by ${O.column.columnDef.header}`,onClick:O.column.getToggleGroupingHandler(),type:"button",children:O.column.getIsGrouped()?"🛑":"👊 "}):void 0," ",ke.flexRender(O.column.columnDef.header,O.getContext())]})},O.id))},j.id))}),a.jsx(Rn,{children:k.getRowModel().rows.map((j,O)=>a.jsx(Ze,{"data-state":j.getIsSelected()?"selected":"",className:N(V(j,O)),onClick:S=>_(j,S),children:j.getVisibleCells().map(S=>{if(!(S.getIsPlaceholder()||S.column.columnDef.enableGrouping&&!S.getIsGrouped()&&(S.column.columnDef.id!==pt||!n)))return a.jsx(xt,{className:N(S.column.columnDef.id,"tw-p-[1px]",U(d,j,S)),children:(()=>S.getIsGrouped()?a.jsxs(fe,{variant:"link",onClick:j.getToggleExpandedHandler(),type:"button",children:[j.getIsExpanded()&&a.jsx(ee.ChevronDown,{}),!j.getIsExpanded()&&(c==="ltr"?a.jsx(ee.ChevronRight,{}):a.jsx(ee.ChevronLeft,{}))," ",ke.flexRender(S.column.columnDef.cell,S.getContext())," (",j.subRows.length,")"]}):ke.flexRender(S.column.columnDef.cell,S.getContext()))()},S.id)})},j.id))})]})]})}const Or={[W.getLocalizeKeyForScrollGroupId("undefined")]:"Ø",[W.getLocalizeKeyForScrollGroupId(0)]:"A",[W.getLocalizeKeyForScrollGroupId(1)]:"B",[W.getLocalizeKeyForScrollGroupId(2)]:"C",[W.getLocalizeKeyForScrollGroupId(3)]:"D",[W.getLocalizeKeyForScrollGroupId(4)]:"E",[W.getLocalizeKeyForScrollGroupId(5)]:"F",[W.getLocalizeKeyForScrollGroupId(6)]:"G",[W.getLocalizeKeyForScrollGroupId(7)]:"H",[W.getLocalizeKeyForScrollGroupId(8)]:"I",[W.getLocalizeKeyForScrollGroupId(9)]:"J",[W.getLocalizeKeyForScrollGroupId(10)]:"K",[W.getLocalizeKeyForScrollGroupId(11)]:"L",[W.getLocalizeKeyForScrollGroupId(12)]:"M",[W.getLocalizeKeyForScrollGroupId(13)]:"N",[W.getLocalizeKeyForScrollGroupId(14)]:"O",[W.getLocalizeKeyForScrollGroupId(15)]:"P",[W.getLocalizeKeyForScrollGroupId(16)]:"Q",[W.getLocalizeKeyForScrollGroupId(17)]:"R",[W.getLocalizeKeyForScrollGroupId(18)]:"S",[W.getLocalizeKeyForScrollGroupId(19)]:"T",[W.getLocalizeKeyForScrollGroupId(20)]:"U",[W.getLocalizeKeyForScrollGroupId(21)]:"V",[W.getLocalizeKeyForScrollGroupId(22)]:"W",[W.getLocalizeKeyForScrollGroupId(23)]:"X",[W.getLocalizeKeyForScrollGroupId(24)]:"Y",[W.getLocalizeKeyForScrollGroupId(25)]:"Z"};function td({availableScrollGroupIds:e,scrollGroupId:t,onChangeScrollGroupId:n,localizedStrings:r={}}){const o={...Or,...Object.fromEntries(Object.entries(r).map(([s,i])=>[s,s===i&&s in Or?Or[s]:i]))};return a.jsxs(Dt,{value:`${t}`,onValueChange:s=>n(s==="undefined"?void 0:parseInt(s,10)),children:[a.jsx(bt,{className:"pr-twp tw-w-auto",children:a.jsx(Bt,{placeholder:o[W.getLocalizeKeyForScrollGroupId(t)]??t})}),a.jsx(vt,{style:{zIndex:250},children:e.map(s=>a.jsx(Ae,{value:`${s}`,children:o[W.getLocalizeKeyForScrollGroupId(s)]},`${s}`))})]})}function nd({children:e}){return a.jsx("div",{className:"pr-twp tw-grid",children:e})}function rd({primary:e,secondary:t,children:n,isLoading:r=!1,loadingMessage:o}){return a.jsxs("div",{className:"tw-flex tw-items-center tw-justify-between tw-space-x-4 tw-py-2",children:[a.jsxs("div",{children:[a.jsx("p",{className:"tw-text-sm tw-font-medium tw-leading-none",children:e}),a.jsx("p",{className:"tw-whitespace-normal tw-break-words tw-text-sm tw-text-muted-foreground",children:t})]}),r?a.jsx("p",{className:"tw-text-sm tw-text-muted-foreground",children:o}):a.jsx("div",{children:n})]})}function od({primary:e,secondary:t,includeSeparator:n=!1}){return a.jsxs("div",{className:"tw-space-y-4 tw-py-2",children:[a.jsxs("div",{children:[a.jsx("h3",{className:"tw-text-lg tw-font-medium",children:e}),a.jsx("p",{className:"tw-text-sm tw-text-muted-foreground",children:t})]}),n?a.jsx(lr,{}):""]})}function ad({id:e,className:t,listItems:n,selectedListItems:r,handleSelectListItem:o,createLabel:s}){return a.jsx("div",{id:e,className:t,children:n.map(i=>a.jsxs("div",{className:"tw-m-2 tw-flex tw-items-center",children:[a.jsx(sr,{className:"tw-mr-2 tw-align-middle",checked:r.includes(i),onCheckedChange:l=>o(i,l)}),a.jsx(Ue,{children:s?s(i):i})]},i))})}function sd(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}function id(e){if(e.__esModule)return e;var t=e.default;if(typeof t=="function"){var n=function r(){return this instanceof r?Reflect.construct(t,arguments,this.constructor):t.apply(this,arguments)};n.prototype=t.prototype}else n={};return Object.defineProperty(n,"__esModule",{value:!0}),Object.keys(e).forEach(function(r){var o=Object.getOwnPropertyDescriptor(e,r);Object.defineProperty(n,r,o.get?o:{enumerable:!0,get:function(){return e[r]}})}),n}var vo={},qs={exports:{}};(function(e){function t(n){return n&&n.__esModule?n:{default:n}}e.exports=t,e.exports.__esModule=!0,e.exports.default=e.exports})(qs);var ld=qs.exports,_r={};function xo(e,t){return process.env.NODE_ENV==="production"?()=>null:function(...r){return e(...r)||t(...r)}}function R(){return R=Object.assign?Object.assign.bind():function(e){for(var t=1;t{t[n]=Hs(e[n])}),t}function Qe(e,t,n={clone:!0}){const r=n.clone?R({},e):e;return mt(e)&&mt(t)&&Object.keys(t).forEach(o=>{o!=="__proto__"&&(mt(t[o])&&o in e&&mt(e[o])?r[o]=Qe(e[o],t[o],n):n.clone?r[o]=mt(t[o])?Hs(t[o]):t[o]:r[o]=t[o])}),r}var Wr={exports:{}},zn={exports:{}},ie={};/** @license React v16.13.1 * react-is.production.min.js * * Copyright (c) Facebook, Inc. and its affiliates. * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. - */var ia;function cd(){if(ia)return ie;ia=1;var e=typeof Symbol=="function"&&Symbol.for,t=e?Symbol.for("react.element"):60103,n=e?Symbol.for("react.portal"):60106,r=e?Symbol.for("react.fragment"):60107,o=e?Symbol.for("react.strict_mode"):60108,s=e?Symbol.for("react.profiler"):60114,i=e?Symbol.for("react.provider"):60109,l=e?Symbol.for("react.context"):60110,c=e?Symbol.for("react.async_mode"):60111,d=e?Symbol.for("react.concurrent_mode"):60111,u=e?Symbol.for("react.forward_ref"):60112,f=e?Symbol.for("react.suspense"):60113,w=e?Symbol.for("react.suspense_list"):60120,b=e?Symbol.for("react.memo"):60115,x=e?Symbol.for("react.lazy"):60116,m=e?Symbol.for("react.block"):60121,h=e?Symbol.for("react.fundamental"):60117,E=e?Symbol.for("react.responder"):60118,I=e?Symbol.for("react.scope"):60119;function C(v){if(typeof v=="object"&&v!==null){var _=v.$$typeof;switch(_){case t:switch(v=v.type,v){case c:case d:case r:case s:case o:case f:return v;default:switch(v=v&&v.$$typeof,v){case l:case u:case x:case b:case i:return v;default:return _}}case n:return _}}}function S(v){return C(v)===d}return ie.AsyncMode=c,ie.ConcurrentMode=d,ie.ContextConsumer=l,ie.ContextProvider=i,ie.Element=t,ie.ForwardRef=u,ie.Fragment=r,ie.Lazy=x,ie.Memo=b,ie.Portal=n,ie.Profiler=s,ie.StrictMode=o,ie.Suspense=f,ie.isAsyncMode=function(v){return S(v)||C(v)===c},ie.isConcurrentMode=S,ie.isContextConsumer=function(v){return C(v)===l},ie.isContextProvider=function(v){return C(v)===i},ie.isElement=function(v){return typeof v=="object"&&v!==null&&v.$$typeof===t},ie.isForwardRef=function(v){return C(v)===u},ie.isFragment=function(v){return C(v)===r},ie.isLazy=function(v){return C(v)===x},ie.isMemo=function(v){return C(v)===b},ie.isPortal=function(v){return C(v)===n},ie.isProfiler=function(v){return C(v)===s},ie.isStrictMode=function(v){return C(v)===o},ie.isSuspense=function(v){return C(v)===f},ie.isValidElementType=function(v){return typeof v=="string"||typeof v=="function"||v===r||v===d||v===s||v===o||v===f||v===w||typeof v=="object"&&v!==null&&(v.$$typeof===x||v.$$typeof===b||v.$$typeof===i||v.$$typeof===l||v.$$typeof===u||v.$$typeof===h||v.$$typeof===E||v.$$typeof===I||v.$$typeof===m)},ie.typeOf=C,ie}var le={};/** @license React v16.13.1 + */var ia;function cd(){if(ia)return ie;ia=1;var e=typeof Symbol=="function"&&Symbol.for,t=e?Symbol.for("react.element"):60103,n=e?Symbol.for("react.portal"):60106,r=e?Symbol.for("react.fragment"):60107,o=e?Symbol.for("react.strict_mode"):60108,s=e?Symbol.for("react.profiler"):60114,i=e?Symbol.for("react.provider"):60109,l=e?Symbol.for("react.context"):60110,c=e?Symbol.for("react.async_mode"):60111,d=e?Symbol.for("react.concurrent_mode"):60111,u=e?Symbol.for("react.forward_ref"):60112,f=e?Symbol.for("react.suspense"):60113,w=e?Symbol.for("react.suspense_list"):60120,b=e?Symbol.for("react.memo"):60115,x=e?Symbol.for("react.lazy"):60116,m=e?Symbol.for("react.block"):60121,h=e?Symbol.for("react.fundamental"):60117,k=e?Symbol.for("react.responder"):60118,I=e?Symbol.for("react.scope"):60119;function C(v){if(typeof v=="object"&&v!==null){var _=v.$$typeof;switch(_){case t:switch(v=v.type,v){case c:case d:case r:case s:case o:case f:return v;default:switch(v=v&&v.$$typeof,v){case l:case u:case x:case b:case i:return v;default:return _}}case n:return _}}}function E(v){return C(v)===d}return ie.AsyncMode=c,ie.ConcurrentMode=d,ie.ContextConsumer=l,ie.ContextProvider=i,ie.Element=t,ie.ForwardRef=u,ie.Fragment=r,ie.Lazy=x,ie.Memo=b,ie.Portal=n,ie.Profiler=s,ie.StrictMode=o,ie.Suspense=f,ie.isAsyncMode=function(v){return E(v)||C(v)===c},ie.isConcurrentMode=E,ie.isContextConsumer=function(v){return C(v)===l},ie.isContextProvider=function(v){return C(v)===i},ie.isElement=function(v){return typeof v=="object"&&v!==null&&v.$$typeof===t},ie.isForwardRef=function(v){return C(v)===u},ie.isFragment=function(v){return C(v)===r},ie.isLazy=function(v){return C(v)===x},ie.isMemo=function(v){return C(v)===b},ie.isPortal=function(v){return C(v)===n},ie.isProfiler=function(v){return C(v)===s},ie.isStrictMode=function(v){return C(v)===o},ie.isSuspense=function(v){return C(v)===f},ie.isValidElementType=function(v){return typeof v=="string"||typeof v=="function"||v===r||v===d||v===s||v===o||v===f||v===w||typeof v=="object"&&v!==null&&(v.$$typeof===x||v.$$typeof===b||v.$$typeof===i||v.$$typeof===l||v.$$typeof===u||v.$$typeof===h||v.$$typeof===k||v.$$typeof===I||v.$$typeof===m)},ie.typeOf=C,ie}var le={};/** @license React v16.13.1 * react-is.development.js * * Copyright (c) Facebook, Inc. and its affiliates. * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. - */var la;function dd(){return la||(la=1,process.env.NODE_ENV!=="production"&&function(){var e=typeof Symbol=="function"&&Symbol.for,t=e?Symbol.for("react.element"):60103,n=e?Symbol.for("react.portal"):60106,r=e?Symbol.for("react.fragment"):60107,o=e?Symbol.for("react.strict_mode"):60108,s=e?Symbol.for("react.profiler"):60114,i=e?Symbol.for("react.provider"):60109,l=e?Symbol.for("react.context"):60110,c=e?Symbol.for("react.async_mode"):60111,d=e?Symbol.for("react.concurrent_mode"):60111,u=e?Symbol.for("react.forward_ref"):60112,f=e?Symbol.for("react.suspense"):60113,w=e?Symbol.for("react.suspense_list"):60120,b=e?Symbol.for("react.memo"):60115,x=e?Symbol.for("react.lazy"):60116,m=e?Symbol.for("react.block"):60121,h=e?Symbol.for("react.fundamental"):60117,E=e?Symbol.for("react.responder"):60118,I=e?Symbol.for("react.scope"):60119;function C(P){return typeof P=="string"||typeof P=="function"||P===r||P===d||P===s||P===o||P===f||P===w||typeof P=="object"&&P!==null&&(P.$$typeof===x||P.$$typeof===b||P.$$typeof===i||P.$$typeof===l||P.$$typeof===u||P.$$typeof===h||P.$$typeof===E||P.$$typeof===I||P.$$typeof===m)}function S(P){if(typeof P=="object"&&P!==null){var xe=P.$$typeof;switch(xe){case t:var D=P.type;switch(D){case c:case d:case r:case s:case o:case f:return D;default:var ve=D&&D.$$typeof;switch(ve){case l:case u:case x:case b:case i:return ve;default:return xe}}case n:return xe}}}var v=c,_=d,V=l,U=i,j=t,O=u,k=r,A=x,M=b,J=n,Y=s,F=o,te=f,se=!1;function oe(P){return se||(se=!0,console.warn("The ReactIs.isAsyncMode() alias has been deprecated, and will be removed in React 17+. Update your code to use ReactIs.isConcurrentMode() instead. It has the exact same API.")),y(P)||S(P)===c}function y(P){return S(P)===d}function T(P){return S(P)===l}function z(P){return S(P)===i}function L(P){return typeof P=="object"&&P!==null&&P.$$typeof===t}function B(P){return S(P)===u}function X(P){return S(P)===r}function q(P){return S(P)===x}function H(P){return S(P)===b}function G(P){return S(P)===n}function K(P){return S(P)===s}function Z(P){return S(P)===o}function ue(P){return S(P)===f}le.AsyncMode=v,le.ConcurrentMode=_,le.ContextConsumer=V,le.ContextProvider=U,le.Element=j,le.ForwardRef=O,le.Fragment=k,le.Lazy=A,le.Memo=M,le.Portal=J,le.Profiler=Y,le.StrictMode=F,le.Suspense=te,le.isAsyncMode=oe,le.isConcurrentMode=y,le.isContextConsumer=T,le.isContextProvider=z,le.isElement=L,le.isForwardRef=B,le.isFragment=X,le.isLazy=q,le.isMemo=H,le.isPortal=G,le.isProfiler=K,le.isStrictMode=Z,le.isSuspense=ue,le.isValidElementType=C,le.typeOf=S}()),le}var ca;function Xs(){return ca||(ca=1,process.env.NODE_ENV==="production"?zn.exports=cd():zn.exports=dd()),zn.exports}/* + */var la;function dd(){return la||(la=1,process.env.NODE_ENV!=="production"&&function(){var e=typeof Symbol=="function"&&Symbol.for,t=e?Symbol.for("react.element"):60103,n=e?Symbol.for("react.portal"):60106,r=e?Symbol.for("react.fragment"):60107,o=e?Symbol.for("react.strict_mode"):60108,s=e?Symbol.for("react.profiler"):60114,i=e?Symbol.for("react.provider"):60109,l=e?Symbol.for("react.context"):60110,c=e?Symbol.for("react.async_mode"):60111,d=e?Symbol.for("react.concurrent_mode"):60111,u=e?Symbol.for("react.forward_ref"):60112,f=e?Symbol.for("react.suspense"):60113,w=e?Symbol.for("react.suspense_list"):60120,b=e?Symbol.for("react.memo"):60115,x=e?Symbol.for("react.lazy"):60116,m=e?Symbol.for("react.block"):60121,h=e?Symbol.for("react.fundamental"):60117,k=e?Symbol.for("react.responder"):60118,I=e?Symbol.for("react.scope"):60119;function C(P){return typeof P=="string"||typeof P=="function"||P===r||P===d||P===s||P===o||P===f||P===w||typeof P=="object"&&P!==null&&(P.$$typeof===x||P.$$typeof===b||P.$$typeof===i||P.$$typeof===l||P.$$typeof===u||P.$$typeof===h||P.$$typeof===k||P.$$typeof===I||P.$$typeof===m)}function E(P){if(typeof P=="object"&&P!==null){var xe=P.$$typeof;switch(xe){case t:var D=P.type;switch(D){case c:case d:case r:case s:case o:case f:return D;default:var ve=D&&D.$$typeof;switch(ve){case l:case u:case x:case b:case i:return ve;default:return xe}}case n:return xe}}}var v=c,_=d,V=l,U=i,j=t,O=u,S=r,A=x,M=b,J=n,Y=s,F=o,te=f,se=!1;function oe(P){return se||(se=!0,console.warn("The ReactIs.isAsyncMode() alias has been deprecated, and will be removed in React 17+. Update your code to use ReactIs.isConcurrentMode() instead. It has the exact same API.")),y(P)||E(P)===c}function y(P){return E(P)===d}function T(P){return E(P)===l}function z(P){return E(P)===i}function L(P){return typeof P=="object"&&P!==null&&P.$$typeof===t}function B(P){return E(P)===u}function X(P){return E(P)===r}function q(P){return E(P)===x}function H(P){return E(P)===b}function G(P){return E(P)===n}function K(P){return E(P)===s}function Z(P){return E(P)===o}function ue(P){return E(P)===f}le.AsyncMode=v,le.ConcurrentMode=_,le.ContextConsumer=V,le.ContextProvider=U,le.Element=j,le.ForwardRef=O,le.Fragment=S,le.Lazy=A,le.Memo=M,le.Portal=J,le.Profiler=Y,le.StrictMode=F,le.Suspense=te,le.isAsyncMode=oe,le.isConcurrentMode=y,le.isContextConsumer=T,le.isContextProvider=z,le.isElement=L,le.isForwardRef=B,le.isFragment=X,le.isLazy=q,le.isMemo=H,le.isPortal=G,le.isProfiler=K,le.isStrictMode=Z,le.isSuspense=ue,le.isValidElementType=C,le.typeOf=E}()),le}var ca;function Xs(){return ca||(ca=1,process.env.NODE_ENV==="production"?zn.exports=cd():zn.exports=dd()),zn.exports}/* object-assign (c) Sindre Sorhus @license MIT -*/var Pr,da;function ud(){if(da)return Pr;da=1;var e=Object.getOwnPropertySymbols,t=Object.prototype.hasOwnProperty,n=Object.prototype.propertyIsEnumerable;function r(s){if(s==null)throw new TypeError("Object.assign cannot be called with null or undefined");return Object(s)}function o(){try{if(!Object.assign)return!1;var s=new String("abc");if(s[5]="de",Object.getOwnPropertyNames(s)[0]==="5")return!1;for(var i={},l=0;l<10;l++)i["_"+String.fromCharCode(l)]=l;var c=Object.getOwnPropertyNames(i).map(function(u){return i[u]});if(c.join("")!=="0123456789")return!1;var d={};return"abcdefghijklmnopqrst".split("").forEach(function(u){d[u]=u}),Object.keys(Object.assign({},d)).join("")==="abcdefghijklmnopqrst"}catch{return!1}}return Pr=o()?Object.assign:function(s,i){for(var l,c=r(s),d,u=1;u1?s("Invalid arguments supplied to oneOf, expected an array, got "+arguments.length+" arguments. A common mistake is to write oneOf(x, y, z) instead of oneOf([x, y, z])."):s("Invalid argument supplied to oneOf, expected an array.")),i;function T(z,L,B,X,q){for(var H=z[L],G=0;G0?", expected one of type ["+K.join(", ")+"]":"";return new m("Invalid "+H+" `"+G+"` supplied to "+("`"+q+"`"+xe+"."))}return h(L)}function O(){function y(T,z,L,B,X){return J(T[z])?null:new m("Invalid "+B+" `"+X+"` supplied to "+("`"+L+"`, expected a ReactNode."))}return h(y)}function k(y,T,z,L,B){return new m((y||"React class")+": "+T+" type `"+z+"."+L+"` is invalid; it must be a function, usually from the `prop-types` package, but received `"+B+"`.")}function A(y){function T(z,L,B,X,q){var H=z[L],G=F(H);if(G!=="object")return new m("Invalid "+X+" `"+q+"` of type `"+G+"` "+("supplied to `"+B+"`, expected `object`."));for(var K in y){var Z=y[K];if(typeof Z!="function")return k(B,X,q,K,te(Z));var ue=Z(H,K,B,X,q+"."+K,n);if(ue)return ue}return null}return h(T)}function M(y){function T(z,L,B,X,q){var H=z[L],G=F(H);if(G!=="object")return new m("Invalid "+X+" `"+q+"` of type `"+G+"` "+("supplied to `"+B+"`, expected `object`."));var K=t({},z[L],y);for(var Z in K){var ue=y[Z];if(r(y,Z)&&typeof ue!="function")return k(B,X,q,Z,te(ue));if(!ue)return new m("Invalid "+X+" `"+q+"` key `"+Z+"` supplied to `"+B+"`.\nBad object: "+JSON.stringify(z[L],null," ")+` +*/var Pr,da;function ud(){if(da)return Pr;da=1;var e=Object.getOwnPropertySymbols,t=Object.prototype.hasOwnProperty,n=Object.prototype.propertyIsEnumerable;function r(s){if(s==null)throw new TypeError("Object.assign cannot be called with null or undefined");return Object(s)}function o(){try{if(!Object.assign)return!1;var s=new String("abc");if(s[5]="de",Object.getOwnPropertyNames(s)[0]==="5")return!1;for(var i={},l=0;l<10;l++)i["_"+String.fromCharCode(l)]=l;var c=Object.getOwnPropertyNames(i).map(function(u){return i[u]});if(c.join("")!=="0123456789")return!1;var d={};return"abcdefghijklmnopqrst".split("").forEach(function(u){d[u]=u}),Object.keys(Object.assign({},d)).join("")==="abcdefghijklmnopqrst"}catch{return!1}}return Pr=o()?Object.assign:function(s,i){for(var l,c=r(s),d,u=1;u1?s("Invalid arguments supplied to oneOf, expected an array, got "+arguments.length+" arguments. A common mistake is to write oneOf(x, y, z) instead of oneOf([x, y, z])."):s("Invalid argument supplied to oneOf, expected an array.")),i;function T(z,L,B,X,q){for(var H=z[L],G=0;G0?", expected one of type ["+K.join(", ")+"]":"";return new m("Invalid "+H+" `"+G+"` supplied to "+("`"+q+"`"+xe+"."))}return h(L)}function O(){function y(T,z,L,B,X){return J(T[z])?null:new m("Invalid "+B+" `"+X+"` supplied to "+("`"+L+"`, expected a ReactNode."))}return h(y)}function S(y,T,z,L,B){return new m((y||"React class")+": "+T+" type `"+z+"."+L+"` is invalid; it must be a function, usually from the `prop-types` package, but received `"+B+"`.")}function A(y){function T(z,L,B,X,q){var H=z[L],G=F(H);if(G!=="object")return new m("Invalid "+X+" `"+q+"` of type `"+G+"` "+("supplied to `"+B+"`, expected `object`."));for(var K in y){var Z=y[K];if(typeof Z!="function")return S(B,X,q,K,te(Z));var ue=Z(H,K,B,X,q+"."+K,n);if(ue)return ue}return null}return h(T)}function M(y){function T(z,L,B,X,q){var H=z[L],G=F(H);if(G!=="object")return new m("Invalid "+X+" `"+q+"` of type `"+G+"` "+("supplied to `"+B+"`, expected `object`."));var K=t({},z[L],y);for(var Z in K){var ue=y[Z];if(r(y,Z)&&typeof ue!="function")return S(B,X,q,Z,te(ue));if(!ue)return new m("Invalid "+X+" `"+q+"` key `"+Z+"` supplied to `"+B+"`.\nBad object: "+JSON.stringify(z[L],null," ")+` Valid keys: `+JSON.stringify(Object.keys(y),null," "));var P=ue(H,Z,B,X,q+"."+Z,n);if(P)return P}return null}return h(T)}function J(y){switch(typeof y){case"number":case"string":case"undefined":return!0;case"boolean":return!y;case"object":if(Array.isArray(y))return y.every(J);if(y===null||l(y))return!0;var T=f(y);if(T){var z=T.call(y),L;if(T!==y.entries){for(;!(L=z.next()).done;)if(!J(L.value))return!1}else for(;!(L=z.next()).done;){var B=L.value;if(B&&!J(B[1]))return!1}}else return!1;return!0;default:return!1}}function Y(y,T){return y==="symbol"?!0:T?T["@@toStringTag"]==="Symbol"||typeof Symbol=="function"&&T instanceof Symbol:!1}function F(y){var T=typeof y;return Array.isArray(y)?"array":y instanceof RegExp?"object":Y(T,y)?"symbol":T}function te(y){if(typeof y>"u"||y===null)return""+y;var T=F(y);if(T==="object"){if(y instanceof Date)return"date";if(y instanceof RegExp)return"regexp"}return T}function se(y){var T=te(y);switch(T){case"array":case"object":return"an "+T;case"boolean":case"date":case"regexp":return"a "+T;default:return T}}function oe(y){return!y.constructor||!y.constructor.name?w:y.constructor.name}return b.checkPropTypes=o,b.resetWarningCache=o.resetWarningCache,b.PropTypes=b,b},Ar}var Dr,ma;function fd(){if(ma)return Dr;ma=1;var e=yo();function t(){}function n(){}return n.resetWarningCache=t,Dr=function(){function r(i,l,c,d,u,f){if(f!==e){var w=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types");throw w.name="Invariant Violation",w}}r.isRequired=r;function o(){return r}var s={array:r,bigint:r,bool:r,func:r,number:r,object:r,string:r,symbol:r,any:r,arrayOf:o,element:r,elementType:r,instanceOf:o,node:r,objectOf:o,oneOf:o,oneOfType:o,shape:o,exact:o,checkPropTypes:n,resetWarningCache:t};return s.PropTypes=s,s},Dr}if(process.env.NODE_ENV!=="production"){var md=Xs(),hd=!0;Wr.exports=wd()(md.isElement,hd)}else Wr.exports=fd()();var gd=Wr.exports;const p=sd(gd);function bd(e){const{prototype:t={}}=e;return!!t.isReactComponent}function Ws(e,t,n,r,o){const s=e[t],i=o||t;if(s==null||typeof window>"u")return null;let l;const c=s.type;return typeof c=="function"&&!bd(c)&&(l="Did you accidentally use a plain function component for an element instead?"),l!==void 0?new Error(`Invalid ${r} \`${i}\` supplied to \`${n}\`. Expected an element that can hold a ref. ${l} For more information see https://mui.com/r/caveat-with-refs-guide`):null}const Ks=xo(p.element,Ws);Ks.isRequired=xo(p.element.isRequired,Ws);const Js=Ks,vd="exact-prop: ​";function xd(e){return process.env.NODE_ENV==="production"?e:R({},e,{[vd]:t=>{const n=Object.keys(t).filter(r=>!e.hasOwnProperty(r));return n.length>0?new Error(`The following props are not supported: ${n.map(r=>`\`${r}\``).join(", ")}. Please remove them.`):null}})}function zt(e){let t="https://mui.com/production-error/?code="+e;for(let n=1;nn==null?t:function(...o){t.apply(this,o),n.apply(this,o)},()=>{})}function Cd(e,t=166){let n;function r(...o){const s=()=>{e.apply(this,o)};clearTimeout(n),n=setTimeout(s,t)}return r.clear=()=>{clearTimeout(n)},r}function Rd(e,t){return process.env.NODE_ENV==="production"?()=>null:(n,r,o,s,i)=>{const l=o||"<>",c=i||r;return typeof n[r]<"u"?new Error(`The ${s} \`${c}\` of \`${l}\` is deprecated. ${t}`):null}}function Od(e,t){var n,r;return $.isValidElement(e)&&t.indexOf((n=e.type.muiName)!=null?n:(r=e.type)==null||(r=r._payload)==null||(r=r.value)==null?void 0:r.muiName)!==-1}function Kn(e){return e&&e.ownerDocument||document}function _d(e){return Kn(e).defaultView||window}function Pd(e,t){if(process.env.NODE_ENV==="production")return()=>null;const n=t?R({},t.propTypes):null;return o=>(s,i,l,c,d,...u)=>{const f=d||i,w=n==null?void 0:n[f];if(w){const b=w(s,i,l,c,d,...u);if(b)return b}return typeof s[i]<"u"&&!s[o]?new Error(`The prop \`${f}\` of \`${e}\` can only be used together with the \`${o}\` prop.`):null}}function Jn(e,t){typeof e=="function"?e(t):e&&(e.current=t)}const Id=typeof window<"u"?$.useLayoutEffect:$.useEffect,Lt=Id;let xa=0;function Md(e){const[t,n]=$.useState(e),r=e||t;return $.useEffect(()=>{t==null&&(xa+=1,n(`mui-${xa}`))},[t]),r}const ya=$["useId".toString()];function ei(e){if(ya!==void 0){const t=ya();return e??t}return Md(e)}function $d(e,t,n,r,o){if(process.env.NODE_ENV==="production")return null;const s=o||t;return typeof e[t]<"u"?new Error(`The prop \`${s}\` is not supported. Please remove it.`):null}function ti({controlled:e,default:t,name:n,state:r="value"}){const{current:o}=$.useRef(e!==void 0),[s,i]=$.useState(t),l=o?e:s;if(process.env.NODE_ENV!=="production"){$.useEffect(()=>{o!==(e!==void 0)&&console.error([`MUI: A component is changing the ${o?"":"un"}controlled ${r} state of ${n} to be ${o?"un":""}controlled.`,"Elements should not switch from uncontrolled to controlled (or vice versa).",`Decide between using a controlled or uncontrolled ${n} element for the lifetime of the component.`,"The nature of the state is determined during the first render. It's considered controlled if the value is not `undefined`.","More info: https://fb.me/react-controlled-components"].join(` + */var ga;function Nd(){return ga||(ga=1,process.env.NODE_ENV!=="production"&&function(){var e=Symbol.for("react.element"),t=Symbol.for("react.portal"),n=Symbol.for("react.fragment"),r=Symbol.for("react.strict_mode"),o=Symbol.for("react.profiler"),s=Symbol.for("react.provider"),i=Symbol.for("react.context"),l=Symbol.for("react.server_context"),c=Symbol.for("react.forward_ref"),d=Symbol.for("react.suspense"),u=Symbol.for("react.suspense_list"),f=Symbol.for("react.memo"),w=Symbol.for("react.lazy"),b=Symbol.for("react.offscreen"),x=!1,m=!1,h=!1,k=!1,I=!1,C;C=Symbol.for("react.module.reference");function E(D){return!!(typeof D=="string"||typeof D=="function"||D===n||D===o||I||D===r||D===d||D===u||k||D===b||x||m||h||typeof D=="object"&&D!==null&&(D.$$typeof===w||D.$$typeof===f||D.$$typeof===s||D.$$typeof===i||D.$$typeof===c||D.$$typeof===C||D.getModuleId!==void 0))}function v(D){if(typeof D=="object"&&D!==null){var ve=D.$$typeof;switch(ve){case e:var Fe=D.type;switch(Fe){case n:case o:case r:case d:case u:return Fe;default:var lt=Fe&&Fe.$$typeof;switch(lt){case l:case i:case c:case w:case f:case s:return lt;default:return ve}}case t:return ve}}}var _=i,V=s,U=e,j=c,O=n,S=w,A=f,M=t,J=o,Y=r,F=d,te=u,se=!1,oe=!1;function y(D){return se||(se=!0,console.warn("The ReactIs.isAsyncMode() alias has been deprecated, and will be removed in React 18+.")),!1}function T(D){return oe||(oe=!0,console.warn("The ReactIs.isConcurrentMode() alias has been deprecated, and will be removed in React 18+.")),!1}function z(D){return v(D)===i}function L(D){return v(D)===s}function B(D){return typeof D=="object"&&D!==null&&D.$$typeof===e}function X(D){return v(D)===c}function q(D){return v(D)===n}function H(D){return v(D)===w}function G(D){return v(D)===f}function K(D){return v(D)===t}function Z(D){return v(D)===o}function ue(D){return v(D)===r}function P(D){return v(D)===d}function xe(D){return v(D)===u}de.ContextConsumer=_,de.ContextProvider=V,de.Element=U,de.ForwardRef=j,de.Fragment=O,de.Lazy=S,de.Memo=A,de.Portal=M,de.Profiler=J,de.StrictMode=Y,de.Suspense=F,de.SuspenseList=te,de.isAsyncMode=y,de.isConcurrentMode=T,de.isContextConsumer=z,de.isContextProvider=L,de.isElement=B,de.isForwardRef=X,de.isFragment=q,de.isLazy=H,de.isMemo=G,de.isPortal=K,de.isProfiler=Z,de.isStrictMode=ue,de.isSuspense=P,de.isSuspenseList=xe,de.isValidElementType=E,de.typeOf=v}()),de}process.env.NODE_ENV==="production"?Kr.exports=yd():Kr.exports=Nd();var ba=Kr.exports;const kd=/^\s*function(?:\s|\s*\/\*.*\*\/\s*)+([^(\s/]*)\s*/;function Sd(e){const t=`${e}`.match(kd);return t&&t[1]||""}function Zs(e,t=""){return e.displayName||e.name||Sd(e)||t}function va(e,t,n){const r=Zs(t);return e.displayName||(r!==""?`${n}(${r})`:n)}function Ed(e){if(e!=null){if(typeof e=="string")return e;if(typeof e=="function")return Zs(e,"Component");if(typeof e=="object")switch(e.$$typeof){case ba.ForwardRef:return va(e,e.render,"ForwardRef");case ba.Memo:return va(e,e.type,"memo");default:return}}}function vn(e,t,n,r,o){if(process.env.NODE_ENV==="production")return null;const s=e[t],i=o||t;return s==null?null:s&&s.nodeType!==1?new Error(`Invalid ${r} \`${i}\` supplied to \`${n}\`. Expected an HTMLElement.`):null}const jd=p.oneOfType([p.func,p.object]),Qs=jd;function Ye(e){if(typeof e!="string")throw new Error(process.env.NODE_ENV!=="production"?"MUI: `capitalize(string)` expects a string argument.":zt(7));return e.charAt(0).toUpperCase()+e.slice(1)}function Td(...e){return e.reduce((t,n)=>n==null?t:function(...o){t.apply(this,o),n.apply(this,o)},()=>{})}function Cd(e,t=166){let n;function r(...o){const s=()=>{e.apply(this,o)};clearTimeout(n),n=setTimeout(s,t)}return r.clear=()=>{clearTimeout(n)},r}function Rd(e,t){return process.env.NODE_ENV==="production"?()=>null:(n,r,o,s,i)=>{const l=o||"<>",c=i||r;return typeof n[r]<"u"?new Error(`The ${s} \`${c}\` of \`${l}\` is deprecated. ${t}`):null}}function Od(e,t){var n,r;return $.isValidElement(e)&&t.indexOf((n=e.type.muiName)!=null?n:(r=e.type)==null||(r=r._payload)==null||(r=r.value)==null?void 0:r.muiName)!==-1}function Kn(e){return e&&e.ownerDocument||document}function _d(e){return Kn(e).defaultView||window}function Pd(e,t){if(process.env.NODE_ENV==="production")return()=>null;const n=t?R({},t.propTypes):null;return o=>(s,i,l,c,d,...u)=>{const f=d||i,w=n==null?void 0:n[f];if(w){const b=w(s,i,l,c,d,...u);if(b)return b}return typeof s[i]<"u"&&!s[o]?new Error(`The prop \`${f}\` of \`${e}\` can only be used together with the \`${o}\` prop.`):null}}function Jn(e,t){typeof e=="function"?e(t):e&&(e.current=t)}const Id=typeof window<"u"?$.useLayoutEffect:$.useEffect,Lt=Id;let xa=0;function Md(e){const[t,n]=$.useState(e),r=e||t;return $.useEffect(()=>{t==null&&(xa+=1,n(`mui-${xa}`))},[t]),r}const ya=$["useId".toString()];function ei(e){if(ya!==void 0){const t=ya();return e??t}return Md(e)}function $d(e,t,n,r,o){if(process.env.NODE_ENV==="production")return null;const s=o||t;return typeof e[t]<"u"?new Error(`The prop \`${s}\` is not supported. Please remove it.`):null}function ti({controlled:e,default:t,name:n,state:r="value"}){const{current:o}=$.useRef(e!==void 0),[s,i]=$.useState(t),l=o?e:s;if(process.env.NODE_ENV!=="production"){$.useEffect(()=>{o!==(e!==void 0)&&console.error([`MUI: A component is changing the ${o?"":"un"}controlled ${r} state of ${n} to be ${o?"un":""}controlled.`,"Elements should not switch from uncontrolled to controlled (or vice versa).",`Decide between using a controlled or uncontrolled ${n} element for the lifetime of the component.`,"The nature of the state is determined during the first render. It's considered controlled if the value is not `undefined`.","More info: https://fb.me/react-controlled-components"].join(` `))},[r,n,e]);const{current:d}=$.useRef(t);$.useEffect(()=>{!o&&d!==t&&console.error([`MUI: A component is changing the default ${r} state of an uncontrolled ${n} after being initialized. To suppress this warning opt to use a controlled ${n}.`].join(` `))},[JSON.stringify(t)])}const c=$.useCallback(d=>{o||i(d)},[]);return[l,c]}function Jr(e){const t=$.useRef(e);return Lt(()=>{t.current=e}),$.useRef((...n)=>(0,t.current)(...n)).current}function yt(...e){return $.useMemo(()=>e.every(t=>t==null)?null:t=>{e.forEach(n=>{Jn(n,t)})},e)}const Na={};function Ad(e,t){const n=$.useRef(Na);return n.current===Na&&(n.current=e(t)),n}const Dd=[];function Bd(e){$.useEffect(e,Dd)}class On{constructor(){this.currentId=null,this.clear=()=>{this.currentId!==null&&(clearTimeout(this.currentId),this.currentId=null)},this.disposeEffect=()=>this.clear}static create(){return new On}start(t,n){this.clear(),this.currentId=setTimeout(()=>{this.currentId=null,n()},t)}}function cn(){const e=Ad(On.create).current;return Bd(e.disposeEffect),e}let dr=!0,Zr=!1;const Vd=new On,zd={text:!0,search:!0,url:!0,tel:!0,email:!0,password:!0,number:!0,date:!0,month:!0,week:!0,time:!0,datetime:!0,"datetime-local":!0};function Ld(e){const{type:t,tagName:n}=e;return!!(n==="INPUT"&&zd[t]&&!e.readOnly||n==="TEXTAREA"&&!e.readOnly||e.isContentEditable)}function Fd(e){e.metaKey||e.altKey||e.ctrlKey||(dr=!0)}function Br(){dr=!1}function Gd(){this.visibilityState==="hidden"&&Zr&&(dr=!0)}function Ud(e){e.addEventListener("keydown",Fd,!0),e.addEventListener("mousedown",Br,!0),e.addEventListener("pointerdown",Br,!0),e.addEventListener("touchstart",Br,!0),e.addEventListener("visibilitychange",Gd,!0)}function qd(e){const{target:t}=e;try{return t.matches(":focus-visible")}catch{}return dr||Ld(t)}function ni(){const e=$.useCallback(o=>{o!=null&&Ud(o.ownerDocument)},[]),t=$.useRef(!1);function n(){return t.current?(Zr=!0,Vd.start(100,()=>{Zr=!1}),t.current=!1,!0):!1}function r(o){return qd(o)?(t.current=!0,!0):!1}return{isFocusVisibleRef:t,onFocus:r,onBlur:n,ref:e}}function ri(e,t){const n=R({},t);return Object.keys(e).forEach(r=>{if(r.toString().match(/^(components|slots)$/))n[r]=R({},e[r],n[r]);else if(r.toString().match(/^(componentsProps|slotProps)$/)){const o=e[r]||{},s=t[r];n[r]={},!s||!Object.keys(s)?n[r]=o:!o||!Object.keys(o)?n[r]=s:(n[r]=R({},s),Object.keys(o).forEach(i=>{n[r][i]=ri(o[i],s[i])}))}else n[r]===void 0&&(n[r]=e[r])}),n}function No(e,t,n=void 0){const r={};return Object.keys(e).forEach(o=>{r[o]=e[o].reduce((s,i)=>{if(i){const l=t(i);l!==""&&s.push(l),n&&n[i]&&s.push(n[i])}return s},[]).join(" ")}),r}const ka=e=>e,Hd=()=>{let e=ka;return{configure(t){e=t},generate(t){return e(t)},reset(){e=ka}}},Xd=Hd(),oi=Xd,ai={active:"active",checked:"checked",completed:"completed",disabled:"disabled",error:"error",expanded:"expanded",focused:"focused",focusVisible:"focusVisible",open:"open",readOnly:"readOnly",required:"required",selected:"selected"};function ur(e,t,n="Mui"){const r=ai[t];return r?`${n}-${r}`:`${oi.generate(e)}-${t}`}function si(e,t,n="Mui"){const r={};return t.forEach(o=>{r[o]=ur(e,o,n)}),r}function Yd(e,t=Number.MIN_SAFE_INTEGER,n=Number.MAX_SAFE_INTEGER){return Math.max(t,Math.min(e,n))}function ye(e,t){if(e==null)return{};var n={},r=Object.keys(e),o,s;for(s=0;s=0)&&(n[o]=e[o]);return n}const Wd=["values","unit","step"],Kd=e=>{const t=Object.keys(e).map(n=>({key:n,val:e[n]}))||[];return t.sort((n,r)=>n.val-r.val),t.reduce((n,r)=>R({},n,{[r.key]:r.val}),{})};function Jd(e){const{values:t={xs:0,sm:600,md:900,lg:1200,xl:1536},unit:n="px",step:r=5}=e,o=ye(e,Wd),s=Kd(t),i=Object.keys(s);function l(w){return`@media (min-width:${typeof t[w]=="number"?t[w]:w}${n})`}function c(w){return`@media (max-width:${(typeof t[w]=="number"?t[w]:w)-r/100}${n})`}function d(w,b){const x=i.indexOf(b);return`@media (min-width:${typeof t[w]=="number"?t[w]:w}${n}) and (max-width:${(x!==-1&&typeof t[i[x]]=="number"?t[i[x]]:b)-r/100}${n})`}function u(w){return i.indexOf(w)+1`@media (min-width:${ko[e]}px)`};function et(e,t,n){const r=e.theme||{};if(Array.isArray(t)){const s=r.breakpoints||Sa;return t.reduce((i,l,c)=>(i[s.up(s.keys[c])]=n(t[c]),i),{})}if(typeof t=="object"){const s=r.breakpoints||Sa;return Object.keys(t).reduce((i,l)=>{if(Object.keys(s.values||ko).indexOf(l)!==-1){const c=s.up(l);i[c]=n(t[l],l)}else{const c=l;i[c]=t[c]}return i},{})}return n(t)}function tu(e={}){var t;return((t=e.keys)==null?void 0:t.reduce((r,o)=>{const s=e.up(o);return r[s]={},r},{}))||{}}function nu(e,t){return e.reduce((n,r)=>{const o=n[r];return(!o||Object.keys(o).length===0)&&delete n[r],n},t)}function pr(e,t,n=!0){if(!t||typeof t!="string")return null;if(e&&e.vars&&n){const r=`vars.${t}`.split(".").reduce((o,s)=>o&&o[s]?o[s]:null,e);if(r!=null)return r}return t.split(".").reduce((r,o)=>r&&r[o]!=null?r[o]:null,e)}function Zn(e,t,n,r=n){let o;return typeof e=="function"?o=e(n):Array.isArray(e)?o=e[n]||r:o=pr(e,n)||r,t&&(o=t(o,r,e)),o}function be(e){const{prop:t,cssProperty:n=e.prop,themeKey:r,transform:o}=e,s=i=>{if(i[t]==null)return null;const l=i[t],c=i.theme,d=pr(c,r)||{};return et(i,l,f=>{let w=Zn(d,o,f);return f===w&&typeof f=="string"&&(w=Zn(d,o,`${t}${f==="default"?"":Ye(f)}`,f)),n===!1?w:{[n]:w}})};return s.propTypes=process.env.NODE_ENV!=="production"?{[t]:st}:{},s.filterProps=[t],s}function ru(e){const t={};return n=>(t[n]===void 0&&(t[n]=e(n)),t[n])}const ou={m:"margin",p:"padding"},au={t:"Top",r:"Right",b:"Bottom",l:"Left",x:["Left","Right"],y:["Top","Bottom"]},Ea={marginX:"mx",marginY:"my",paddingX:"px",paddingY:"py"},su=ru(e=>{if(e.length>2)if(Ea[e])e=Ea[e];else return[e];const[t,n]=e.split(""),r=ou[t],o=au[n]||"";return Array.isArray(o)?o.map(s=>r+s):[r+o]}),wr=["m","mt","mr","mb","ml","mx","my","margin","marginTop","marginRight","marginBottom","marginLeft","marginX","marginY","marginInline","marginInlineStart","marginInlineEnd","marginBlock","marginBlockStart","marginBlockEnd"],fr=["p","pt","pr","pb","pl","px","py","padding","paddingTop","paddingRight","paddingBottom","paddingLeft","paddingX","paddingY","paddingInline","paddingInlineStart","paddingInlineEnd","paddingBlock","paddingBlockStart","paddingBlockEnd"],iu=[...wr,...fr];function _n(e,t,n,r){var o;const s=(o=pr(e,t,!1))!=null?o:n;return typeof s=="number"?i=>typeof i=="string"?i:(process.env.NODE_ENV!=="production"&&typeof i!="number"&&console.error(`MUI: Expected ${r} argument to be a number or a string, got ${i}.`),s*i):Array.isArray(s)?i=>typeof i=="string"?i:(process.env.NODE_ENV!=="production"&&(Number.isInteger(i)?i>s.length-1&&console.error([`MUI: The value provided (${i}) overflows.`,`The supported values are: ${JSON.stringify(s)}.`,`${i} > ${s.length-1}, you need to add the missing values.`].join(` `)):console.error([`MUI: The \`theme.${t}\` array type cannot be combined with non integer values.You should either use an integer value that can be used as index, or define the \`theme.${t}\` as a number.`].join(` `))),s[i]):typeof s=="function"?s:(process.env.NODE_ENV!=="production"&&console.error([`MUI: The \`theme.${t}\` value (${s}) is invalid.`,"It should be a number, an array or a function."].join(` -`)),()=>{})}function ii(e){return _n(e,"spacing",8,"spacing")}function Pn(e,t){if(typeof t=="string"||t==null)return t;const n=Math.abs(t),r=e(n);return t>=0?r:typeof r=="number"?-r:`-${r}`}function lu(e,t){return n=>e.reduce((r,o)=>(r[o]=Pn(t,n),r),{})}function cu(e,t,n,r){if(t.indexOf(n)===-1)return null;const o=su(n),s=lu(o,r),i=e[n];return et(e,i,s)}function li(e,t){const n=ii(e.theme);return Object.keys(e).map(r=>cu(e,t,r,n)).reduce(fn,{})}function me(e){return li(e,wr)}me.propTypes=process.env.NODE_ENV!=="production"?wr.reduce((e,t)=>(e[t]=st,e),{}):{};me.filterProps=wr;function he(e){return li(e,fr)}he.propTypes=process.env.NODE_ENV!=="production"?fr.reduce((e,t)=>(e[t]=st,e),{}):{};he.filterProps=fr;process.env.NODE_ENV!=="production"&&iu.reduce((e,t)=>(e[t]=st,e),{});function du(e=8){if(e.mui)return e;const t=ii({spacing:e}),n=(...r)=>(process.env.NODE_ENV!=="production"&&(r.length<=4||console.error(`MUI: Too many arguments provided, expected between 0 and 4, got ${r.length}`)),(r.length===0?[1]:r).map(s=>{const i=t(s);return typeof i=="number"?`${i}px`:i}).join(" "));return n.mui=!0,n}function mr(...e){const t=e.reduce((r,o)=>(o.filterProps.forEach(s=>{r[s]=o}),r),{}),n=r=>Object.keys(r).reduce((o,s)=>t[s]?fn(o,t[s](r)):o,{});return n.propTypes=process.env.NODE_ENV!=="production"?e.reduce((r,o)=>Object.assign(r,o.propTypes),{}):{},n.filterProps=e.reduce((r,o)=>r.concat(o.filterProps),[]),n}function De(e){return typeof e!="number"?e:`${e}px solid`}function Le(e,t){return be({prop:e,themeKey:"borders",transform:t})}const uu=Le("border",De),pu=Le("borderTop",De),wu=Le("borderRight",De),fu=Le("borderBottom",De),mu=Le("borderLeft",De),hu=Le("borderColor"),gu=Le("borderTopColor"),bu=Le("borderRightColor"),vu=Le("borderBottomColor"),xu=Le("borderLeftColor"),yu=Le("outline",De),Nu=Le("outlineColor"),hr=e=>{if(e.borderRadius!==void 0&&e.borderRadius!==null){const t=_n(e.theme,"shape.borderRadius",4,"borderRadius"),n=r=>({borderRadius:Pn(t,r)});return et(e,e.borderRadius,n)}return null};hr.propTypes=process.env.NODE_ENV!=="production"?{borderRadius:st}:{};hr.filterProps=["borderRadius"];mr(uu,pu,wu,fu,mu,hu,gu,bu,vu,xu,hr,yu,Nu);const gr=e=>{if(e.gap!==void 0&&e.gap!==null){const t=_n(e.theme,"spacing",8,"gap"),n=r=>({gap:Pn(t,r)});return et(e,e.gap,n)}return null};gr.propTypes=process.env.NODE_ENV!=="production"?{gap:st}:{};gr.filterProps=["gap"];const br=e=>{if(e.columnGap!==void 0&&e.columnGap!==null){const t=_n(e.theme,"spacing",8,"columnGap"),n=r=>({columnGap:Pn(t,r)});return et(e,e.columnGap,n)}return null};br.propTypes=process.env.NODE_ENV!=="production"?{columnGap:st}:{};br.filterProps=["columnGap"];const vr=e=>{if(e.rowGap!==void 0&&e.rowGap!==null){const t=_n(e.theme,"spacing",8,"rowGap"),n=r=>({rowGap:Pn(t,r)});return et(e,e.rowGap,n)}return null};vr.propTypes=process.env.NODE_ENV!=="production"?{rowGap:st}:{};vr.filterProps=["rowGap"];const ku=be({prop:"gridColumn"}),Su=be({prop:"gridRow"}),Eu=be({prop:"gridAutoFlow"}),ju=be({prop:"gridAutoColumns"}),Tu=be({prop:"gridAutoRows"}),Cu=be({prop:"gridTemplateColumns"}),Ru=be({prop:"gridTemplateRows"}),Ou=be({prop:"gridTemplateAreas"}),_u=be({prop:"gridArea"});mr(gr,br,vr,ku,Su,Eu,ju,Tu,Cu,Ru,Ou,_u);function At(e,t){return t==="grey"?t:e}const Pu=be({prop:"color",themeKey:"palette",transform:At}),Iu=be({prop:"bgcolor",cssProperty:"backgroundColor",themeKey:"palette",transform:At}),Mu=be({prop:"backgroundColor",themeKey:"palette",transform:At});mr(Pu,Iu,Mu);function Pe(e){return e<=1&&e!==0?`${e*100}%`:e}const $u=be({prop:"width",transform:Pe}),So=e=>{if(e.maxWidth!==void 0&&e.maxWidth!==null){const t=n=>{var r,o;const s=((r=e.theme)==null||(r=r.breakpoints)==null||(r=r.values)==null?void 0:r[n])||ko[n];return s?((o=e.theme)==null||(o=o.breakpoints)==null?void 0:o.unit)!=="px"?{maxWidth:`${s}${e.theme.breakpoints.unit}`}:{maxWidth:s}:{maxWidth:Pe(n)}};return et(e,e.maxWidth,t)}return null};So.filterProps=["maxWidth"];const Au=be({prop:"minWidth",transform:Pe}),Du=be({prop:"height",transform:Pe}),Bu=be({prop:"maxHeight",transform:Pe}),Vu=be({prop:"minHeight",transform:Pe});be({prop:"size",cssProperty:"width",transform:Pe});be({prop:"size",cssProperty:"height",transform:Pe});const zu=be({prop:"boxSizing"});mr($u,So,Au,Du,Bu,Vu,zu);const Lu={border:{themeKey:"borders",transform:De},borderTop:{themeKey:"borders",transform:De},borderRight:{themeKey:"borders",transform:De},borderBottom:{themeKey:"borders",transform:De},borderLeft:{themeKey:"borders",transform:De},borderColor:{themeKey:"palette"},borderTopColor:{themeKey:"palette"},borderRightColor:{themeKey:"palette"},borderBottomColor:{themeKey:"palette"},borderLeftColor:{themeKey:"palette"},outline:{themeKey:"borders",transform:De},outlineColor:{themeKey:"palette"},borderRadius:{themeKey:"shape.borderRadius",style:hr},color:{themeKey:"palette",transform:At},bgcolor:{themeKey:"palette",cssProperty:"backgroundColor",transform:At},backgroundColor:{themeKey:"palette",transform:At},p:{style:he},pt:{style:he},pr:{style:he},pb:{style:he},pl:{style:he},px:{style:he},py:{style:he},padding:{style:he},paddingTop:{style:he},paddingRight:{style:he},paddingBottom:{style:he},paddingLeft:{style:he},paddingX:{style:he},paddingY:{style:he},paddingInline:{style:he},paddingInlineStart:{style:he},paddingInlineEnd:{style:he},paddingBlock:{style:he},paddingBlockStart:{style:he},paddingBlockEnd:{style:he},m:{style:me},mt:{style:me},mr:{style:me},mb:{style:me},ml:{style:me},mx:{style:me},my:{style:me},margin:{style:me},marginTop:{style:me},marginRight:{style:me},marginBottom:{style:me},marginLeft:{style:me},marginX:{style:me},marginY:{style:me},marginInline:{style:me},marginInlineStart:{style:me},marginInlineEnd:{style:me},marginBlock:{style:me},marginBlockStart:{style:me},marginBlockEnd:{style:me},displayPrint:{cssProperty:!1,transform:e=>({"@media print":{display:e}})},display:{},overflow:{},textOverflow:{},visibility:{},whiteSpace:{},flexBasis:{},flexDirection:{},flexWrap:{},justifyContent:{},alignItems:{},alignContent:{},order:{},flex:{},flexGrow:{},flexShrink:{},alignSelf:{},justifyItems:{},justifySelf:{},gap:{style:gr},rowGap:{style:vr},columnGap:{style:br},gridColumn:{},gridRow:{},gridAutoFlow:{},gridAutoColumns:{},gridAutoRows:{},gridTemplateColumns:{},gridTemplateRows:{},gridTemplateAreas:{},gridArea:{},position:{},zIndex:{themeKey:"zIndex"},top:{},right:{},bottom:{},left:{},boxShadow:{themeKey:"shadows"},width:{transform:Pe},maxWidth:{style:So},minWidth:{transform:Pe},height:{transform:Pe},maxHeight:{transform:Pe},minHeight:{transform:Pe},boxSizing:{},fontFamily:{themeKey:"typography"},fontSize:{themeKey:"typography"},fontStyle:{themeKey:"typography"},fontWeight:{themeKey:"typography"},letterSpacing:{},textTransform:{},lineHeight:{},textAlign:{},typography:{cssProperty:!1,themeKey:"typography"}},Eo=Lu;function Fu(...e){const t=e.reduce((r,o)=>r.concat(Object.keys(o)),[]),n=new Set(t);return e.every(r=>n.size===Object.keys(r).length)}function Gu(e,t){return typeof e=="function"?e(t):e}function Uu(){function e(n,r,o,s){const i={[n]:r,theme:o},l=s[n];if(!l)return{[n]:r};const{cssProperty:c=n,themeKey:d,transform:u,style:f}=l;if(r==null)return null;if(d==="typography"&&r==="inherit")return{[n]:r};const w=pr(o,d)||{};return f?f(i):et(i,r,x=>{let m=Zn(w,u,x);return x===m&&typeof x=="string"&&(m=Zn(w,u,`${n}${x==="default"?"":Ye(x)}`,x)),c===!1?m:{[c]:m}})}function t(n){var r;const{sx:o,theme:s={}}=n||{};if(!o)return null;const i=(r=s.unstable_sxConfig)!=null?r:Eo;function l(c){let d=c;if(typeof c=="function")d=c(s);else if(typeof c!="object")return c;if(!d)return null;const u=tu(s.breakpoints),f=Object.keys(u);let w=u;return Object.keys(d).forEach(b=>{const x=Gu(d[b],s);if(x!=null)if(typeof x=="object")if(i[b])w=fn(w,e(b,x,s,i));else{const m=et({theme:s},x,h=>({[b]:h}));Fu(m,x)?w[b]=t({sx:x,theme:s}):w=fn(w,m)}else w=fn(w,e(b,x,s,i))}),nu(f,w)}return Array.isArray(o)?o.map(l):l(o)}return t}const ci=Uu();ci.filterProps=["sx"];const jo=ci;function qu(e,t){const n=this;return n.vars&&typeof n.getColorSchemeSelector=="function"?{[n.getColorSchemeSelector(e).replace(/(\[[^\]]+\])/,"*:where($1)")]:t}:n.palette.mode===e?t:{}}const Hu=["breakpoints","palette","spacing","shape"];function To(e={},...t){const{breakpoints:n={},palette:r={},spacing:o,shape:s={}}=e,i=ye(e,Hu),l=Jd(n),c=du(o);let d=Qe({breakpoints:l,direction:"ltr",components:{},palette:R({mode:"light"},r),spacing:c,shape:R({},Qd,s)},i);return d.applyStyles=qu,d=t.reduce((u,f)=>Qe(u,f),d),d.unstable_sxConfig=R({},Eo,i==null?void 0:i.unstable_sxConfig),d.unstable_sx=function(f){return jo({sx:f,theme:this})},d}function Xu(e){return Object.keys(e).length===0}function di(e=null){const t=$.useContext(Fr.ThemeContext);return!t||Xu(t)?e:t}const Yu=To();function ui(e=Yu){return di(e)}const Wu=["ownerState"],Ku=["variants"],Ju=["name","slot","skipVariantsResolver","skipSx","overridesResolver"];function Zu(e){return Object.keys(e).length===0}function Qu(e){return typeof e=="string"&&e.charCodeAt(0)>96}function qn(e){return e!=="ownerState"&&e!=="theme"&&e!=="sx"&&e!=="as"}const ep=To(),ja=e=>e&&e.charAt(0).toLowerCase()+e.slice(1);function Ln({defaultTheme:e,theme:t,themeId:n}){return Zu(t)?e:t[n]||t}function tp(e){return e?(t,n)=>n[e]:null}function Hn(e,t){let{ownerState:n}=t,r=ye(t,Wu);const o=typeof e=="function"?e(R({ownerState:n},r)):e;if(Array.isArray(o))return o.flatMap(s=>Hn(s,R({ownerState:n},r)));if(o&&typeof o=="object"&&Array.isArray(o.variants)){const{variants:s=[]}=o;let l=ye(o,Ku);return s.forEach(c=>{let d=!0;typeof c.props=="function"?d=c.props(R({ownerState:n},r,n)):Object.keys(c.props).forEach(u=>{(n==null?void 0:n[u])!==c.props[u]&&r[u]!==c.props[u]&&(d=!1)}),d&&(Array.isArray(l)||(l=[l]),l.push(typeof c.style=="function"?c.style(R({ownerState:n},r,n)):c.style))}),l}return o}function np(e={}){const{themeId:t,defaultTheme:n=ep,rootShouldForwardProp:r=qn,slotShouldForwardProp:o=qn}=e,s=i=>jo(R({},i,{theme:Ln(R({},i,{defaultTheme:n,themeId:t}))}));return s.__mui_systemSx=!0,(i,l={})=>{Fr.internal_processStyles(i,v=>v.filter(_=>!(_!=null&&_.__mui_systemSx)));const{name:c,slot:d,skipVariantsResolver:u,skipSx:f,overridesResolver:w=tp(ja(d))}=l,b=ye(l,Ju),x=u!==void 0?u:d&&d!=="Root"&&d!=="root"||!1,m=f||!1;let h;process.env.NODE_ENV!=="production"&&c&&(h=`${c}-${ja(d||"Root")}`);let E=qn;d==="Root"||d==="root"?E=r:d?E=o:Qu(i)&&(E=void 0);const I=Fr(i,R({shouldForwardProp:E,label:h},b)),C=v=>typeof v=="function"&&v.__emotion_real!==v||mt(v)?_=>Hn(v,R({},_,{theme:Ln({theme:_.theme,defaultTheme:n,themeId:t})})):v,S=(v,..._)=>{let V=C(v);const U=_?_.map(C):[];c&&w&&U.push(k=>{const A=Ln(R({},k,{defaultTheme:n,themeId:t}));if(!A.components||!A.components[c]||!A.components[c].styleOverrides)return null;const M=A.components[c].styleOverrides,J={};return Object.entries(M).forEach(([Y,F])=>{J[Y]=Hn(F,R({},k,{theme:A}))}),w(k,J)}),c&&!x&&U.push(k=>{var A;const M=Ln(R({},k,{defaultTheme:n,themeId:t})),J=M==null||(A=M.components)==null||(A=A[c])==null?void 0:A.variants;return Hn({variants:J},R({},k,{theme:M}))}),m||U.push(s);const j=U.length-_.length;if(Array.isArray(v)&&j>0){const k=new Array(j).fill("");V=[...v,...k],V.raw=[...v.raw,...k]}const O=I(V,...U);if(process.env.NODE_ENV!=="production"){let k;c&&(k=`${c}${Ye(d||"")}`),k===void 0&&(k=`Styled(${Ed(i)})`),O.displayName=k}return i.muiName&&(O.muiName=i.muiName),O};return I.withConfig&&(S.withConfig=I.withConfig),S}}function rp(e){const{theme:t,name:n,props:r}=e;return!t||!t.components||!t.components[n]||!t.components[n].defaultProps?r:ri(t.components[n].defaultProps,r)}function op({props:e,name:t,defaultTheme:n,themeId:r}){let o=ui(n);return r&&(o=o[r]||o),rp({theme:o,name:t,props:e})}function Co(e,t=0,n=1){return process.env.NODE_ENV!=="production"&&(en)&&console.error(`MUI: The value provided ${e} is out of range [${t}, ${n}].`),Yd(e,t,n)}function ap(e){e=e.slice(1);const t=new RegExp(`.{1,${e.length>=6?2:1}}`,"g");let n=e.match(t);return n&&n[0].length===1&&(n=n.map(r=>r+r)),n?`rgb${n.length===4?"a":""}(${n.map((r,o)=>o<3?parseInt(r,16):Math.round(parseInt(r,16)/255*1e3)/1e3).join(", ")})`:""}function Nt(e){if(e.type)return e;if(e.charAt(0)==="#")return Nt(ap(e));const t=e.indexOf("("),n=e.substring(0,t);if(["rgb","rgba","hsl","hsla","color"].indexOf(n)===-1)throw new Error(process.env.NODE_ENV!=="production"?`MUI: Unsupported \`${e}\` color. +`)),()=>{})}function ii(e){return _n(e,"spacing",8,"spacing")}function Pn(e,t){if(typeof t=="string"||t==null)return t;const n=Math.abs(t),r=e(n);return t>=0?r:typeof r=="number"?-r:`-${r}`}function lu(e,t){return n=>e.reduce((r,o)=>(r[o]=Pn(t,n),r),{})}function cu(e,t,n,r){if(t.indexOf(n)===-1)return null;const o=su(n),s=lu(o,r),i=e[n];return et(e,i,s)}function li(e,t){const n=ii(e.theme);return Object.keys(e).map(r=>cu(e,t,r,n)).reduce(fn,{})}function me(e){return li(e,wr)}me.propTypes=process.env.NODE_ENV!=="production"?wr.reduce((e,t)=>(e[t]=st,e),{}):{};me.filterProps=wr;function he(e){return li(e,fr)}he.propTypes=process.env.NODE_ENV!=="production"?fr.reduce((e,t)=>(e[t]=st,e),{}):{};he.filterProps=fr;process.env.NODE_ENV!=="production"&&iu.reduce((e,t)=>(e[t]=st,e),{});function du(e=8){if(e.mui)return e;const t=ii({spacing:e}),n=(...r)=>(process.env.NODE_ENV!=="production"&&(r.length<=4||console.error(`MUI: Too many arguments provided, expected between 0 and 4, got ${r.length}`)),(r.length===0?[1]:r).map(s=>{const i=t(s);return typeof i=="number"?`${i}px`:i}).join(" "));return n.mui=!0,n}function mr(...e){const t=e.reduce((r,o)=>(o.filterProps.forEach(s=>{r[s]=o}),r),{}),n=r=>Object.keys(r).reduce((o,s)=>t[s]?fn(o,t[s](r)):o,{});return n.propTypes=process.env.NODE_ENV!=="production"?e.reduce((r,o)=>Object.assign(r,o.propTypes),{}):{},n.filterProps=e.reduce((r,o)=>r.concat(o.filterProps),[]),n}function De(e){return typeof e!="number"?e:`${e}px solid`}function Le(e,t){return be({prop:e,themeKey:"borders",transform:t})}const uu=Le("border",De),pu=Le("borderTop",De),wu=Le("borderRight",De),fu=Le("borderBottom",De),mu=Le("borderLeft",De),hu=Le("borderColor"),gu=Le("borderTopColor"),bu=Le("borderRightColor"),vu=Le("borderBottomColor"),xu=Le("borderLeftColor"),yu=Le("outline",De),Nu=Le("outlineColor"),hr=e=>{if(e.borderRadius!==void 0&&e.borderRadius!==null){const t=_n(e.theme,"shape.borderRadius",4,"borderRadius"),n=r=>({borderRadius:Pn(t,r)});return et(e,e.borderRadius,n)}return null};hr.propTypes=process.env.NODE_ENV!=="production"?{borderRadius:st}:{};hr.filterProps=["borderRadius"];mr(uu,pu,wu,fu,mu,hu,gu,bu,vu,xu,hr,yu,Nu);const gr=e=>{if(e.gap!==void 0&&e.gap!==null){const t=_n(e.theme,"spacing",8,"gap"),n=r=>({gap:Pn(t,r)});return et(e,e.gap,n)}return null};gr.propTypes=process.env.NODE_ENV!=="production"?{gap:st}:{};gr.filterProps=["gap"];const br=e=>{if(e.columnGap!==void 0&&e.columnGap!==null){const t=_n(e.theme,"spacing",8,"columnGap"),n=r=>({columnGap:Pn(t,r)});return et(e,e.columnGap,n)}return null};br.propTypes=process.env.NODE_ENV!=="production"?{columnGap:st}:{};br.filterProps=["columnGap"];const vr=e=>{if(e.rowGap!==void 0&&e.rowGap!==null){const t=_n(e.theme,"spacing",8,"rowGap"),n=r=>({rowGap:Pn(t,r)});return et(e,e.rowGap,n)}return null};vr.propTypes=process.env.NODE_ENV!=="production"?{rowGap:st}:{};vr.filterProps=["rowGap"];const ku=be({prop:"gridColumn"}),Su=be({prop:"gridRow"}),Eu=be({prop:"gridAutoFlow"}),ju=be({prop:"gridAutoColumns"}),Tu=be({prop:"gridAutoRows"}),Cu=be({prop:"gridTemplateColumns"}),Ru=be({prop:"gridTemplateRows"}),Ou=be({prop:"gridTemplateAreas"}),_u=be({prop:"gridArea"});mr(gr,br,vr,ku,Su,Eu,ju,Tu,Cu,Ru,Ou,_u);function At(e,t){return t==="grey"?t:e}const Pu=be({prop:"color",themeKey:"palette",transform:At}),Iu=be({prop:"bgcolor",cssProperty:"backgroundColor",themeKey:"palette",transform:At}),Mu=be({prop:"backgroundColor",themeKey:"palette",transform:At});mr(Pu,Iu,Mu);function Pe(e){return e<=1&&e!==0?`${e*100}%`:e}const $u=be({prop:"width",transform:Pe}),So=e=>{if(e.maxWidth!==void 0&&e.maxWidth!==null){const t=n=>{var r,o;const s=((r=e.theme)==null||(r=r.breakpoints)==null||(r=r.values)==null?void 0:r[n])||ko[n];return s?((o=e.theme)==null||(o=o.breakpoints)==null?void 0:o.unit)!=="px"?{maxWidth:`${s}${e.theme.breakpoints.unit}`}:{maxWidth:s}:{maxWidth:Pe(n)}};return et(e,e.maxWidth,t)}return null};So.filterProps=["maxWidth"];const Au=be({prop:"minWidth",transform:Pe}),Du=be({prop:"height",transform:Pe}),Bu=be({prop:"maxHeight",transform:Pe}),Vu=be({prop:"minHeight",transform:Pe});be({prop:"size",cssProperty:"width",transform:Pe});be({prop:"size",cssProperty:"height",transform:Pe});const zu=be({prop:"boxSizing"});mr($u,So,Au,Du,Bu,Vu,zu);const Lu={border:{themeKey:"borders",transform:De},borderTop:{themeKey:"borders",transform:De},borderRight:{themeKey:"borders",transform:De},borderBottom:{themeKey:"borders",transform:De},borderLeft:{themeKey:"borders",transform:De},borderColor:{themeKey:"palette"},borderTopColor:{themeKey:"palette"},borderRightColor:{themeKey:"palette"},borderBottomColor:{themeKey:"palette"},borderLeftColor:{themeKey:"palette"},outline:{themeKey:"borders",transform:De},outlineColor:{themeKey:"palette"},borderRadius:{themeKey:"shape.borderRadius",style:hr},color:{themeKey:"palette",transform:At},bgcolor:{themeKey:"palette",cssProperty:"backgroundColor",transform:At},backgroundColor:{themeKey:"palette",transform:At},p:{style:he},pt:{style:he},pr:{style:he},pb:{style:he},pl:{style:he},px:{style:he},py:{style:he},padding:{style:he},paddingTop:{style:he},paddingRight:{style:he},paddingBottom:{style:he},paddingLeft:{style:he},paddingX:{style:he},paddingY:{style:he},paddingInline:{style:he},paddingInlineStart:{style:he},paddingInlineEnd:{style:he},paddingBlock:{style:he},paddingBlockStart:{style:he},paddingBlockEnd:{style:he},m:{style:me},mt:{style:me},mr:{style:me},mb:{style:me},ml:{style:me},mx:{style:me},my:{style:me},margin:{style:me},marginTop:{style:me},marginRight:{style:me},marginBottom:{style:me},marginLeft:{style:me},marginX:{style:me},marginY:{style:me},marginInline:{style:me},marginInlineStart:{style:me},marginInlineEnd:{style:me},marginBlock:{style:me},marginBlockStart:{style:me},marginBlockEnd:{style:me},displayPrint:{cssProperty:!1,transform:e=>({"@media print":{display:e}})},display:{},overflow:{},textOverflow:{},visibility:{},whiteSpace:{},flexBasis:{},flexDirection:{},flexWrap:{},justifyContent:{},alignItems:{},alignContent:{},order:{},flex:{},flexGrow:{},flexShrink:{},alignSelf:{},justifyItems:{},justifySelf:{},gap:{style:gr},rowGap:{style:vr},columnGap:{style:br},gridColumn:{},gridRow:{},gridAutoFlow:{},gridAutoColumns:{},gridAutoRows:{},gridTemplateColumns:{},gridTemplateRows:{},gridTemplateAreas:{},gridArea:{},position:{},zIndex:{themeKey:"zIndex"},top:{},right:{},bottom:{},left:{},boxShadow:{themeKey:"shadows"},width:{transform:Pe},maxWidth:{style:So},minWidth:{transform:Pe},height:{transform:Pe},maxHeight:{transform:Pe},minHeight:{transform:Pe},boxSizing:{},fontFamily:{themeKey:"typography"},fontSize:{themeKey:"typography"},fontStyle:{themeKey:"typography"},fontWeight:{themeKey:"typography"},letterSpacing:{},textTransform:{},lineHeight:{},textAlign:{},typography:{cssProperty:!1,themeKey:"typography"}},Eo=Lu;function Fu(...e){const t=e.reduce((r,o)=>r.concat(Object.keys(o)),[]),n=new Set(t);return e.every(r=>n.size===Object.keys(r).length)}function Gu(e,t){return typeof e=="function"?e(t):e}function Uu(){function e(n,r,o,s){const i={[n]:r,theme:o},l=s[n];if(!l)return{[n]:r};const{cssProperty:c=n,themeKey:d,transform:u,style:f}=l;if(r==null)return null;if(d==="typography"&&r==="inherit")return{[n]:r};const w=pr(o,d)||{};return f?f(i):et(i,r,x=>{let m=Zn(w,u,x);return x===m&&typeof x=="string"&&(m=Zn(w,u,`${n}${x==="default"?"":Ye(x)}`,x)),c===!1?m:{[c]:m}})}function t(n){var r;const{sx:o,theme:s={}}=n||{};if(!o)return null;const i=(r=s.unstable_sxConfig)!=null?r:Eo;function l(c){let d=c;if(typeof c=="function")d=c(s);else if(typeof c!="object")return c;if(!d)return null;const u=tu(s.breakpoints),f=Object.keys(u);let w=u;return Object.keys(d).forEach(b=>{const x=Gu(d[b],s);if(x!=null)if(typeof x=="object")if(i[b])w=fn(w,e(b,x,s,i));else{const m=et({theme:s},x,h=>({[b]:h}));Fu(m,x)?w[b]=t({sx:x,theme:s}):w=fn(w,m)}else w=fn(w,e(b,x,s,i))}),nu(f,w)}return Array.isArray(o)?o.map(l):l(o)}return t}const ci=Uu();ci.filterProps=["sx"];const jo=ci;function qu(e,t){const n=this;return n.vars&&typeof n.getColorSchemeSelector=="function"?{[n.getColorSchemeSelector(e).replace(/(\[[^\]]+\])/,"*:where($1)")]:t}:n.palette.mode===e?t:{}}const Hu=["breakpoints","palette","spacing","shape"];function To(e={},...t){const{breakpoints:n={},palette:r={},spacing:o,shape:s={}}=e,i=ye(e,Hu),l=Jd(n),c=du(o);let d=Qe({breakpoints:l,direction:"ltr",components:{},palette:R({mode:"light"},r),spacing:c,shape:R({},Qd,s)},i);return d.applyStyles=qu,d=t.reduce((u,f)=>Qe(u,f),d),d.unstable_sxConfig=R({},Eo,i==null?void 0:i.unstable_sxConfig),d.unstable_sx=function(f){return jo({sx:f,theme:this})},d}function Xu(e){return Object.keys(e).length===0}function di(e=null){const t=$.useContext(Fr.ThemeContext);return!t||Xu(t)?e:t}const Yu=To();function ui(e=Yu){return di(e)}const Wu=["ownerState"],Ku=["variants"],Ju=["name","slot","skipVariantsResolver","skipSx","overridesResolver"];function Zu(e){return Object.keys(e).length===0}function Qu(e){return typeof e=="string"&&e.charCodeAt(0)>96}function qn(e){return e!=="ownerState"&&e!=="theme"&&e!=="sx"&&e!=="as"}const ep=To(),ja=e=>e&&e.charAt(0).toLowerCase()+e.slice(1);function Ln({defaultTheme:e,theme:t,themeId:n}){return Zu(t)?e:t[n]||t}function tp(e){return e?(t,n)=>n[e]:null}function Hn(e,t){let{ownerState:n}=t,r=ye(t,Wu);const o=typeof e=="function"?e(R({ownerState:n},r)):e;if(Array.isArray(o))return o.flatMap(s=>Hn(s,R({ownerState:n},r)));if(o&&typeof o=="object"&&Array.isArray(o.variants)){const{variants:s=[]}=o;let l=ye(o,Ku);return s.forEach(c=>{let d=!0;typeof c.props=="function"?d=c.props(R({ownerState:n},r,n)):Object.keys(c.props).forEach(u=>{(n==null?void 0:n[u])!==c.props[u]&&r[u]!==c.props[u]&&(d=!1)}),d&&(Array.isArray(l)||(l=[l]),l.push(typeof c.style=="function"?c.style(R({ownerState:n},r,n)):c.style))}),l}return o}function np(e={}){const{themeId:t,defaultTheme:n=ep,rootShouldForwardProp:r=qn,slotShouldForwardProp:o=qn}=e,s=i=>jo(R({},i,{theme:Ln(R({},i,{defaultTheme:n,themeId:t}))}));return s.__mui_systemSx=!0,(i,l={})=>{Fr.internal_processStyles(i,v=>v.filter(_=>!(_!=null&&_.__mui_systemSx)));const{name:c,slot:d,skipVariantsResolver:u,skipSx:f,overridesResolver:w=tp(ja(d))}=l,b=ye(l,Ju),x=u!==void 0?u:d&&d!=="Root"&&d!=="root"||!1,m=f||!1;let h;process.env.NODE_ENV!=="production"&&c&&(h=`${c}-${ja(d||"Root")}`);let k=qn;d==="Root"||d==="root"?k=r:d?k=o:Qu(i)&&(k=void 0);const I=Fr(i,R({shouldForwardProp:k,label:h},b)),C=v=>typeof v=="function"&&v.__emotion_real!==v||mt(v)?_=>Hn(v,R({},_,{theme:Ln({theme:_.theme,defaultTheme:n,themeId:t})})):v,E=(v,..._)=>{let V=C(v);const U=_?_.map(C):[];c&&w&&U.push(S=>{const A=Ln(R({},S,{defaultTheme:n,themeId:t}));if(!A.components||!A.components[c]||!A.components[c].styleOverrides)return null;const M=A.components[c].styleOverrides,J={};return Object.entries(M).forEach(([Y,F])=>{J[Y]=Hn(F,R({},S,{theme:A}))}),w(S,J)}),c&&!x&&U.push(S=>{var A;const M=Ln(R({},S,{defaultTheme:n,themeId:t})),J=M==null||(A=M.components)==null||(A=A[c])==null?void 0:A.variants;return Hn({variants:J},R({},S,{theme:M}))}),m||U.push(s);const j=U.length-_.length;if(Array.isArray(v)&&j>0){const S=new Array(j).fill("");V=[...v,...S],V.raw=[...v.raw,...S]}const O=I(V,...U);if(process.env.NODE_ENV!=="production"){let S;c&&(S=`${c}${Ye(d||"")}`),S===void 0&&(S=`Styled(${Ed(i)})`),O.displayName=S}return i.muiName&&(O.muiName=i.muiName),O};return I.withConfig&&(E.withConfig=I.withConfig),E}}function rp(e){const{theme:t,name:n,props:r}=e;return!t||!t.components||!t.components[n]||!t.components[n].defaultProps?r:ri(t.components[n].defaultProps,r)}function op({props:e,name:t,defaultTheme:n,themeId:r}){let o=ui(n);return r&&(o=o[r]||o),rp({theme:o,name:t,props:e})}function Co(e,t=0,n=1){return process.env.NODE_ENV!=="production"&&(en)&&console.error(`MUI: The value provided ${e} is out of range [${t}, ${n}].`),Yd(e,t,n)}function ap(e){e=e.slice(1);const t=new RegExp(`.{1,${e.length>=6?2:1}}`,"g");let n=e.match(t);return n&&n[0].length===1&&(n=n.map(r=>r+r)),n?`rgb${n.length===4?"a":""}(${n.map((r,o)=>o<3?parseInt(r,16):Math.round(parseInt(r,16)/255*1e3)/1e3).join(", ")})`:""}function Nt(e){if(e.type)return e;if(e.charAt(0)==="#")return Nt(ap(e));const t=e.indexOf("("),n=e.substring(0,t);if(["rgb","rgba","hsl","hsla","color"].indexOf(n)===-1)throw new Error(process.env.NODE_ENV!=="production"?`MUI: Unsupported \`${e}\` color. The following formats are supported: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color().`:zt(9,e));let r=e.substring(t+1,e.length-1),o;if(n==="color"){if(r=r.split(" "),o=r.shift(),r.length===4&&r[3].charAt(0)==="/"&&(r[3]=r[3].slice(1)),["srgb","display-p3","a98-rgb","prophoto-rgb","rec-2020"].indexOf(o)===-1)throw new Error(process.env.NODE_ENV!=="production"?`MUI: unsupported \`${o}\` color space. -The following color spaces are supported: srgb, display-p3, a98-rgb, prophoto-rgb, rec-2020.`:zt(10,o))}else r=r.split(",");return r=r.map(s=>parseFloat(s)),{type:n,values:r,colorSpace:o}}function xr(e){const{type:t,colorSpace:n}=e;let{values:r}=e;return t.indexOf("rgb")!==-1?r=r.map((o,s)=>s<3?parseInt(o,10):o):t.indexOf("hsl")!==-1&&(r[1]=`${r[1]}%`,r[2]=`${r[2]}%`),t.indexOf("color")!==-1?r=`${n} ${r.join(" ")}`:r=`${r.join(", ")}`,`${t}(${r})`}function sp(e){e=Nt(e);const{values:t}=e,n=t[0],r=t[1]/100,o=t[2]/100,s=r*Math.min(o,1-o),i=(d,u=(d+n/30)%12)=>o-s*Math.max(Math.min(u-3,9-u,1),-1);let l="rgb";const c=[Math.round(i(0)*255),Math.round(i(8)*255),Math.round(i(4)*255)];return e.type==="hsla"&&(l+="a",c.push(t[3])),xr({type:l,values:c})}function Ta(e){e=Nt(e);let t=e.type==="hsl"||e.type==="hsla"?Nt(sp(e)).values:e.values;return t=t.map(n=>(e.type!=="color"&&(n/=255),n<=.03928?n/12.92:((n+.055)/1.055)**2.4)),Number((.2126*t[0]+.7152*t[1]+.0722*t[2]).toFixed(3))}function Ca(e,t){const n=Ta(e),r=Ta(t);return(Math.max(n,r)+.05)/(Math.min(n,r)+.05)}function pi(e,t){return e=Nt(e),t=Co(t),(e.type==="rgb"||e.type==="hsl")&&(e.type+="a"),e.type==="color"?e.values[3]=`/${t}`:e.values[3]=t,xr(e)}function ip(e,t){if(e=Nt(e),t=Co(t),e.type.indexOf("hsl")!==-1)e.values[2]*=1-t;else if(e.type.indexOf("rgb")!==-1||e.type.indexOf("color")!==-1)for(let n=0;n<3;n+=1)e.values[n]*=1-t;return xr(e)}function lp(e,t){if(e=Nt(e),t=Co(t),e.type.indexOf("hsl")!==-1)e.values[2]+=(100-e.values[2])*t;else if(e.type.indexOf("rgb")!==-1)for(let n=0;n<3;n+=1)e.values[n]+=(255-e.values[n])*t;else if(e.type.indexOf("color")!==-1)for(let n=0;n<3;n+=1)e.values[n]+=(1-e.values[n])*t;return xr(e)}function cp(e,t){return R({toolbar:{minHeight:56,[e.up("xs")]:{"@media (orientation: landscape)":{minHeight:48}},[e.up("sm")]:{minHeight:64}}},t)}const dp={black:"#000",white:"#fff"},xn=dp,up={50:"#fafafa",100:"#f5f5f5",200:"#eeeeee",300:"#e0e0e0",400:"#bdbdbd",500:"#9e9e9e",600:"#757575",700:"#616161",800:"#424242",900:"#212121",A100:"#f5f5f5",A200:"#eeeeee",A400:"#bdbdbd",A700:"#616161"},pp=up,wp={50:"#f3e5f5",100:"#e1bee7",200:"#ce93d8",300:"#ba68c8",400:"#ab47bc",500:"#9c27b0",600:"#8e24aa",700:"#7b1fa2",800:"#6a1b9a",900:"#4a148c",A100:"#ea80fc",A200:"#e040fb",A400:"#d500f9",A700:"#aa00ff"},Rt=wp,fp={50:"#ffebee",100:"#ffcdd2",200:"#ef9a9a",300:"#e57373",400:"#ef5350",500:"#f44336",600:"#e53935",700:"#d32f2f",800:"#c62828",900:"#b71c1c",A100:"#ff8a80",A200:"#ff5252",A400:"#ff1744",A700:"#d50000"},Ot=fp,mp={50:"#fff3e0",100:"#ffe0b2",200:"#ffcc80",300:"#ffb74d",400:"#ffa726",500:"#ff9800",600:"#fb8c00",700:"#f57c00",800:"#ef6c00",900:"#e65100",A100:"#ffd180",A200:"#ffab40",A400:"#ff9100",A700:"#ff6d00"},rn=mp,hp={50:"#e3f2fd",100:"#bbdefb",200:"#90caf9",300:"#64b5f6",400:"#42a5f5",500:"#2196f3",600:"#1e88e5",700:"#1976d2",800:"#1565c0",900:"#0d47a1",A100:"#82b1ff",A200:"#448aff",A400:"#2979ff",A700:"#2962ff"},_t=hp,gp={50:"#e1f5fe",100:"#b3e5fc",200:"#81d4fa",300:"#4fc3f7",400:"#29b6f6",500:"#03a9f4",600:"#039be5",700:"#0288d1",800:"#0277bd",900:"#01579b",A100:"#80d8ff",A200:"#40c4ff",A400:"#00b0ff",A700:"#0091ea"},Pt=gp,bp={50:"#e8f5e9",100:"#c8e6c9",200:"#a5d6a7",300:"#81c784",400:"#66bb6a",500:"#4caf50",600:"#43a047",700:"#388e3c",800:"#2e7d32",900:"#1b5e20",A100:"#b9f6ca",A200:"#69f0ae",A400:"#00e676",A700:"#00c853"},It=bp,vp=["mode","contrastThreshold","tonalOffset"],Ra={text:{primary:"rgba(0, 0, 0, 0.87)",secondary:"rgba(0, 0, 0, 0.6)",disabled:"rgba(0, 0, 0, 0.38)"},divider:"rgba(0, 0, 0, 0.12)",background:{paper:xn.white,default:xn.white},action:{active:"rgba(0, 0, 0, 0.54)",hover:"rgba(0, 0, 0, 0.04)",hoverOpacity:.04,selected:"rgba(0, 0, 0, 0.08)",selectedOpacity:.08,disabled:"rgba(0, 0, 0, 0.26)",disabledBackground:"rgba(0, 0, 0, 0.12)",disabledOpacity:.38,focus:"rgba(0, 0, 0, 0.12)",focusOpacity:.12,activatedOpacity:.12}},Vr={text:{primary:xn.white,secondary:"rgba(255, 255, 255, 0.7)",disabled:"rgba(255, 255, 255, 0.5)",icon:"rgba(255, 255, 255, 0.5)"},divider:"rgba(255, 255, 255, 0.12)",background:{paper:"#121212",default:"#121212"},action:{active:xn.white,hover:"rgba(255, 255, 255, 0.08)",hoverOpacity:.08,selected:"rgba(255, 255, 255, 0.16)",selectedOpacity:.16,disabled:"rgba(255, 255, 255, 0.3)",disabledBackground:"rgba(255, 255, 255, 0.12)",disabledOpacity:.38,focus:"rgba(255, 255, 255, 0.12)",focusOpacity:.12,activatedOpacity:.24}};function Oa(e,t,n,r){const o=r.light||r,s=r.dark||r*1.5;e[t]||(e.hasOwnProperty(n)?e[t]=e[n]:t==="light"?e.light=lp(e.main,o):t==="dark"&&(e.dark=ip(e.main,s)))}function xp(e="light"){return e==="dark"?{main:_t[200],light:_t[50],dark:_t[400]}:{main:_t[700],light:_t[400],dark:_t[800]}}function yp(e="light"){return e==="dark"?{main:Rt[200],light:Rt[50],dark:Rt[400]}:{main:Rt[500],light:Rt[300],dark:Rt[700]}}function Np(e="light"){return e==="dark"?{main:Ot[500],light:Ot[300],dark:Ot[700]}:{main:Ot[700],light:Ot[400],dark:Ot[800]}}function kp(e="light"){return e==="dark"?{main:Pt[400],light:Pt[300],dark:Pt[700]}:{main:Pt[700],light:Pt[500],dark:Pt[900]}}function Sp(e="light"){return e==="dark"?{main:It[400],light:It[300],dark:It[700]}:{main:It[800],light:It[500],dark:It[900]}}function Ep(e="light"){return e==="dark"?{main:rn[400],light:rn[300],dark:rn[700]}:{main:"#ed6c02",light:rn[500],dark:rn[900]}}function jp(e){const{mode:t="light",contrastThreshold:n=3,tonalOffset:r=.2}=e,o=ye(e,vp),s=e.primary||xp(t),i=e.secondary||yp(t),l=e.error||Np(t),c=e.info||kp(t),d=e.success||Sp(t),u=e.warning||Ep(t);function f(m){const h=Ca(m,Vr.text.primary)>=n?Vr.text.primary:Ra.text.primary;if(process.env.NODE_ENV!=="production"){const E=Ca(m,h);E<3&&console.error([`MUI: The contrast ratio of ${E}:1 for ${h} on ${m}`,"falls below the WCAG recommended absolute minimum contrast ratio of 3:1.","https://www.w3.org/TR/2008/REC-WCAG20-20081211/#visual-audio-contrast-contrast"].join(` -`))}return h}const w=({color:m,name:h,mainShade:E=500,lightShade:I=300,darkShade:C=700})=>{if(m=R({},m),!m.main&&m[E]&&(m.main=m[E]),!m.hasOwnProperty("main"))throw new Error(process.env.NODE_ENV!=="production"?`MUI: The color${h?` (${h})`:""} provided to augmentColor(color) is invalid. -The color object needs to have a \`main\` property or a \`${E}\` property.`:zt(11,h?` (${h})`:"",E));if(typeof m.main!="string")throw new Error(process.env.NODE_ENV!=="production"?`MUI: The color${h?` (${h})`:""} provided to augmentColor(color) is invalid. +The following color spaces are supported: srgb, display-p3, a98-rgb, prophoto-rgb, rec-2020.`:zt(10,o))}else r=r.split(",");return r=r.map(s=>parseFloat(s)),{type:n,values:r,colorSpace:o}}function xr(e){const{type:t,colorSpace:n}=e;let{values:r}=e;return t.indexOf("rgb")!==-1?r=r.map((o,s)=>s<3?parseInt(o,10):o):t.indexOf("hsl")!==-1&&(r[1]=`${r[1]}%`,r[2]=`${r[2]}%`),t.indexOf("color")!==-1?r=`${n} ${r.join(" ")}`:r=`${r.join(", ")}`,`${t}(${r})`}function sp(e){e=Nt(e);const{values:t}=e,n=t[0],r=t[1]/100,o=t[2]/100,s=r*Math.min(o,1-o),i=(d,u=(d+n/30)%12)=>o-s*Math.max(Math.min(u-3,9-u,1),-1);let l="rgb";const c=[Math.round(i(0)*255),Math.round(i(8)*255),Math.round(i(4)*255)];return e.type==="hsla"&&(l+="a",c.push(t[3])),xr({type:l,values:c})}function Ta(e){e=Nt(e);let t=e.type==="hsl"||e.type==="hsla"?Nt(sp(e)).values:e.values;return t=t.map(n=>(e.type!=="color"&&(n/=255),n<=.03928?n/12.92:((n+.055)/1.055)**2.4)),Number((.2126*t[0]+.7152*t[1]+.0722*t[2]).toFixed(3))}function Ca(e,t){const n=Ta(e),r=Ta(t);return(Math.max(n,r)+.05)/(Math.min(n,r)+.05)}function pi(e,t){return e=Nt(e),t=Co(t),(e.type==="rgb"||e.type==="hsl")&&(e.type+="a"),e.type==="color"?e.values[3]=`/${t}`:e.values[3]=t,xr(e)}function ip(e,t){if(e=Nt(e),t=Co(t),e.type.indexOf("hsl")!==-1)e.values[2]*=1-t;else if(e.type.indexOf("rgb")!==-1||e.type.indexOf("color")!==-1)for(let n=0;n<3;n+=1)e.values[n]*=1-t;return xr(e)}function lp(e,t){if(e=Nt(e),t=Co(t),e.type.indexOf("hsl")!==-1)e.values[2]+=(100-e.values[2])*t;else if(e.type.indexOf("rgb")!==-1)for(let n=0;n<3;n+=1)e.values[n]+=(255-e.values[n])*t;else if(e.type.indexOf("color")!==-1)for(let n=0;n<3;n+=1)e.values[n]+=(1-e.values[n])*t;return xr(e)}function cp(e,t){return R({toolbar:{minHeight:56,[e.up("xs")]:{"@media (orientation: landscape)":{minHeight:48}},[e.up("sm")]:{minHeight:64}}},t)}const dp={black:"#000",white:"#fff"},xn=dp,up={50:"#fafafa",100:"#f5f5f5",200:"#eeeeee",300:"#e0e0e0",400:"#bdbdbd",500:"#9e9e9e",600:"#757575",700:"#616161",800:"#424242",900:"#212121",A100:"#f5f5f5",A200:"#eeeeee",A400:"#bdbdbd",A700:"#616161"},pp=up,wp={50:"#f3e5f5",100:"#e1bee7",200:"#ce93d8",300:"#ba68c8",400:"#ab47bc",500:"#9c27b0",600:"#8e24aa",700:"#7b1fa2",800:"#6a1b9a",900:"#4a148c",A100:"#ea80fc",A200:"#e040fb",A400:"#d500f9",A700:"#aa00ff"},Rt=wp,fp={50:"#ffebee",100:"#ffcdd2",200:"#ef9a9a",300:"#e57373",400:"#ef5350",500:"#f44336",600:"#e53935",700:"#d32f2f",800:"#c62828",900:"#b71c1c",A100:"#ff8a80",A200:"#ff5252",A400:"#ff1744",A700:"#d50000"},Ot=fp,mp={50:"#fff3e0",100:"#ffe0b2",200:"#ffcc80",300:"#ffb74d",400:"#ffa726",500:"#ff9800",600:"#fb8c00",700:"#f57c00",800:"#ef6c00",900:"#e65100",A100:"#ffd180",A200:"#ffab40",A400:"#ff9100",A700:"#ff6d00"},rn=mp,hp={50:"#e3f2fd",100:"#bbdefb",200:"#90caf9",300:"#64b5f6",400:"#42a5f5",500:"#2196f3",600:"#1e88e5",700:"#1976d2",800:"#1565c0",900:"#0d47a1",A100:"#82b1ff",A200:"#448aff",A400:"#2979ff",A700:"#2962ff"},_t=hp,gp={50:"#e1f5fe",100:"#b3e5fc",200:"#81d4fa",300:"#4fc3f7",400:"#29b6f6",500:"#03a9f4",600:"#039be5",700:"#0288d1",800:"#0277bd",900:"#01579b",A100:"#80d8ff",A200:"#40c4ff",A400:"#00b0ff",A700:"#0091ea"},Pt=gp,bp={50:"#e8f5e9",100:"#c8e6c9",200:"#a5d6a7",300:"#81c784",400:"#66bb6a",500:"#4caf50",600:"#43a047",700:"#388e3c",800:"#2e7d32",900:"#1b5e20",A100:"#b9f6ca",A200:"#69f0ae",A400:"#00e676",A700:"#00c853"},It=bp,vp=["mode","contrastThreshold","tonalOffset"],Ra={text:{primary:"rgba(0, 0, 0, 0.87)",secondary:"rgba(0, 0, 0, 0.6)",disabled:"rgba(0, 0, 0, 0.38)"},divider:"rgba(0, 0, 0, 0.12)",background:{paper:xn.white,default:xn.white},action:{active:"rgba(0, 0, 0, 0.54)",hover:"rgba(0, 0, 0, 0.04)",hoverOpacity:.04,selected:"rgba(0, 0, 0, 0.08)",selectedOpacity:.08,disabled:"rgba(0, 0, 0, 0.26)",disabledBackground:"rgba(0, 0, 0, 0.12)",disabledOpacity:.38,focus:"rgba(0, 0, 0, 0.12)",focusOpacity:.12,activatedOpacity:.12}},Vr={text:{primary:xn.white,secondary:"rgba(255, 255, 255, 0.7)",disabled:"rgba(255, 255, 255, 0.5)",icon:"rgba(255, 255, 255, 0.5)"},divider:"rgba(255, 255, 255, 0.12)",background:{paper:"#121212",default:"#121212"},action:{active:xn.white,hover:"rgba(255, 255, 255, 0.08)",hoverOpacity:.08,selected:"rgba(255, 255, 255, 0.16)",selectedOpacity:.16,disabled:"rgba(255, 255, 255, 0.3)",disabledBackground:"rgba(255, 255, 255, 0.12)",disabledOpacity:.38,focus:"rgba(255, 255, 255, 0.12)",focusOpacity:.12,activatedOpacity:.24}};function Oa(e,t,n,r){const o=r.light||r,s=r.dark||r*1.5;e[t]||(e.hasOwnProperty(n)?e[t]=e[n]:t==="light"?e.light=lp(e.main,o):t==="dark"&&(e.dark=ip(e.main,s)))}function xp(e="light"){return e==="dark"?{main:_t[200],light:_t[50],dark:_t[400]}:{main:_t[700],light:_t[400],dark:_t[800]}}function yp(e="light"){return e==="dark"?{main:Rt[200],light:Rt[50],dark:Rt[400]}:{main:Rt[500],light:Rt[300],dark:Rt[700]}}function Np(e="light"){return e==="dark"?{main:Ot[500],light:Ot[300],dark:Ot[700]}:{main:Ot[700],light:Ot[400],dark:Ot[800]}}function kp(e="light"){return e==="dark"?{main:Pt[400],light:Pt[300],dark:Pt[700]}:{main:Pt[700],light:Pt[500],dark:Pt[900]}}function Sp(e="light"){return e==="dark"?{main:It[400],light:It[300],dark:It[700]}:{main:It[800],light:It[500],dark:It[900]}}function Ep(e="light"){return e==="dark"?{main:rn[400],light:rn[300],dark:rn[700]}:{main:"#ed6c02",light:rn[500],dark:rn[900]}}function jp(e){const{mode:t="light",contrastThreshold:n=3,tonalOffset:r=.2}=e,o=ye(e,vp),s=e.primary||xp(t),i=e.secondary||yp(t),l=e.error||Np(t),c=e.info||kp(t),d=e.success||Sp(t),u=e.warning||Ep(t);function f(m){const h=Ca(m,Vr.text.primary)>=n?Vr.text.primary:Ra.text.primary;if(process.env.NODE_ENV!=="production"){const k=Ca(m,h);k<3&&console.error([`MUI: The contrast ratio of ${k}:1 for ${h} on ${m}`,"falls below the WCAG recommended absolute minimum contrast ratio of 3:1.","https://www.w3.org/TR/2008/REC-WCAG20-20081211/#visual-audio-contrast-contrast"].join(` +`))}return h}const w=({color:m,name:h,mainShade:k=500,lightShade:I=300,darkShade:C=700})=>{if(m=R({},m),!m.main&&m[k]&&(m.main=m[k]),!m.hasOwnProperty("main"))throw new Error(process.env.NODE_ENV!=="production"?`MUI: The color${h?` (${h})`:""} provided to augmentColor(color) is invalid. +The color object needs to have a \`main\` property or a \`${k}\` property.`:zt(11,h?` (${h})`:"",k));if(typeof m.main!="string")throw new Error(process.env.NODE_ENV!=="production"?`MUI: The color${h?` (${h})`:""} provided to augmentColor(color) is invalid. \`color.main\` should be a string, but \`${JSON.stringify(m.main)}\` was provided instead. Did you intend to use one of the following approaches? @@ -55,16 +55,16 @@ const theme1 = createTheme({ palette: { const theme2 = createTheme({ palette: { primary: { main: green[500] }, -} });`:zt(12,h?` (${h})`:"",JSON.stringify(m.main)));return Oa(m,"light",I,r),Oa(m,"dark",C,r),m.contrastText||(m.contrastText=f(m.main)),m},b={dark:Vr,light:Ra};return process.env.NODE_ENV!=="production"&&(b[t]||console.error(`MUI: The palette mode \`${t}\` is not supported.`)),Qe(R({common:R({},xn),mode:t,primary:w({color:s,name:"primary"}),secondary:w({color:i,name:"secondary",mainShade:"A400",lightShade:"A200",darkShade:"A700"}),error:w({color:l,name:"error"}),warning:w({color:u,name:"warning"}),info:w({color:c,name:"info"}),success:w({color:d,name:"success"}),grey:pp,contrastThreshold:n,getContrastText:f,augmentColor:w,tonalOffset:r},b[t]),o)}const Tp=["fontFamily","fontSize","fontWeightLight","fontWeightRegular","fontWeightMedium","fontWeightBold","htmlFontSize","allVariants","pxToRem"];function Cp(e){return Math.round(e*1e5)/1e5}const _a={textTransform:"uppercase"},Pa='"Roboto", "Helvetica", "Arial", sans-serif';function Rp(e,t){const n=typeof t=="function"?t(e):t,{fontFamily:r=Pa,fontSize:o=14,fontWeightLight:s=300,fontWeightRegular:i=400,fontWeightMedium:l=500,fontWeightBold:c=700,htmlFontSize:d=16,allVariants:u,pxToRem:f}=n,w=ye(n,Tp);process.env.NODE_ENV!=="production"&&(typeof o!="number"&&console.error("MUI: `fontSize` is required to be a number."),typeof d!="number"&&console.error("MUI: `htmlFontSize` is required to be a number."));const b=o/14,x=f||(E=>`${E/d*b}rem`),m=(E,I,C,S,v)=>R({fontFamily:r,fontWeight:E,fontSize:x(I),lineHeight:C},r===Pa?{letterSpacing:`${Cp(S/I)}em`}:{},v,u),h={h1:m(s,96,1.167,-1.5),h2:m(s,60,1.2,-.5),h3:m(i,48,1.167,0),h4:m(i,34,1.235,.25),h5:m(i,24,1.334,0),h6:m(l,20,1.6,.15),subtitle1:m(i,16,1.75,.15),subtitle2:m(l,14,1.57,.1),body1:m(i,16,1.5,.15),body2:m(i,14,1.43,.15),button:m(l,14,1.75,.4,_a),caption:m(i,12,1.66,.4),overline:m(i,12,2.66,1,_a),inherit:{fontFamily:"inherit",fontWeight:"inherit",fontSize:"inherit",lineHeight:"inherit",letterSpacing:"inherit"}};return Qe(R({htmlFontSize:d,pxToRem:x,fontFamily:r,fontSize:o,fontWeightLight:s,fontWeightRegular:i,fontWeightMedium:l,fontWeightBold:c},h),w,{clone:!1})}const Op=.2,_p=.14,Pp=.12;function we(...e){return[`${e[0]}px ${e[1]}px ${e[2]}px ${e[3]}px rgba(0,0,0,${Op})`,`${e[4]}px ${e[5]}px ${e[6]}px ${e[7]}px rgba(0,0,0,${_p})`,`${e[8]}px ${e[9]}px ${e[10]}px ${e[11]}px rgba(0,0,0,${Pp})`].join(",")}const Ip=["none",we(0,2,1,-1,0,1,1,0,0,1,3,0),we(0,3,1,-2,0,2,2,0,0,1,5,0),we(0,3,3,-2,0,3,4,0,0,1,8,0),we(0,2,4,-1,0,4,5,0,0,1,10,0),we(0,3,5,-1,0,5,8,0,0,1,14,0),we(0,3,5,-1,0,6,10,0,0,1,18,0),we(0,4,5,-2,0,7,10,1,0,2,16,1),we(0,5,5,-3,0,8,10,1,0,3,14,2),we(0,5,6,-3,0,9,12,1,0,3,16,2),we(0,6,6,-3,0,10,14,1,0,4,18,3),we(0,6,7,-4,0,11,15,1,0,4,20,3),we(0,7,8,-4,0,12,17,2,0,5,22,4),we(0,7,8,-4,0,13,19,2,0,5,24,4),we(0,7,9,-4,0,14,21,2,0,5,26,4),we(0,8,9,-5,0,15,22,2,0,6,28,5),we(0,8,10,-5,0,16,24,2,0,6,30,5),we(0,8,11,-5,0,17,26,2,0,6,32,5),we(0,9,11,-5,0,18,28,2,0,7,34,6),we(0,9,12,-6,0,19,29,2,0,7,36,6),we(0,10,13,-6,0,20,31,3,0,8,38,7),we(0,10,13,-6,0,21,33,3,0,8,40,7),we(0,10,14,-6,0,22,35,3,0,8,42,7),we(0,11,14,-7,0,23,36,3,0,9,44,8),we(0,11,15,-7,0,24,38,3,0,9,46,8)],Mp=Ip,$p=["duration","easing","delay"],Ap={easeInOut:"cubic-bezier(0.4, 0, 0.2, 1)",easeOut:"cubic-bezier(0.0, 0, 0.2, 1)",easeIn:"cubic-bezier(0.4, 0, 1, 1)",sharp:"cubic-bezier(0.4, 0, 0.6, 1)"},Dp={shortest:150,shorter:200,short:250,standard:300,complex:375,enteringScreen:225,leavingScreen:195};function Ia(e){return`${Math.round(e)}ms`}function Bp(e){if(!e)return 0;const t=e/36;return Math.round((4+15*t**.25+t/5)*10)}function Vp(e){const t=R({},Ap,e.easing),n=R({},Dp,e.duration);return R({getAutoHeightDuration:Bp,create:(o=["all"],s={})=>{const{duration:i=n.standard,easing:l=t.easeInOut,delay:c=0}=s,d=ye(s,$p);if(process.env.NODE_ENV!=="production"){const u=w=>typeof w=="string",f=w=>!isNaN(parseFloat(w));!u(o)&&!Array.isArray(o)&&console.error('MUI: Argument "props" must be a string or Array.'),!f(i)&&!u(i)&&console.error(`MUI: Argument "duration" must be a number or a string but found ${i}.`),u(l)||console.error('MUI: Argument "easing" must be a string.'),!f(c)&&!u(c)&&console.error('MUI: Argument "delay" must be a number or a string.'),typeof s!="object"&&console.error(["MUI: Secong argument of transition.create must be an object.","Arguments should be either `create('prop1', options)` or `create(['prop1', 'prop2'], options)`"].join(` +} });`:zt(12,h?` (${h})`:"",JSON.stringify(m.main)));return Oa(m,"light",I,r),Oa(m,"dark",C,r),m.contrastText||(m.contrastText=f(m.main)),m},b={dark:Vr,light:Ra};return process.env.NODE_ENV!=="production"&&(b[t]||console.error(`MUI: The palette mode \`${t}\` is not supported.`)),Qe(R({common:R({},xn),mode:t,primary:w({color:s,name:"primary"}),secondary:w({color:i,name:"secondary",mainShade:"A400",lightShade:"A200",darkShade:"A700"}),error:w({color:l,name:"error"}),warning:w({color:u,name:"warning"}),info:w({color:c,name:"info"}),success:w({color:d,name:"success"}),grey:pp,contrastThreshold:n,getContrastText:f,augmentColor:w,tonalOffset:r},b[t]),o)}const Tp=["fontFamily","fontSize","fontWeightLight","fontWeightRegular","fontWeightMedium","fontWeightBold","htmlFontSize","allVariants","pxToRem"];function Cp(e){return Math.round(e*1e5)/1e5}const _a={textTransform:"uppercase"},Pa='"Roboto", "Helvetica", "Arial", sans-serif';function Rp(e,t){const n=typeof t=="function"?t(e):t,{fontFamily:r=Pa,fontSize:o=14,fontWeightLight:s=300,fontWeightRegular:i=400,fontWeightMedium:l=500,fontWeightBold:c=700,htmlFontSize:d=16,allVariants:u,pxToRem:f}=n,w=ye(n,Tp);process.env.NODE_ENV!=="production"&&(typeof o!="number"&&console.error("MUI: `fontSize` is required to be a number."),typeof d!="number"&&console.error("MUI: `htmlFontSize` is required to be a number."));const b=o/14,x=f||(k=>`${k/d*b}rem`),m=(k,I,C,E,v)=>R({fontFamily:r,fontWeight:k,fontSize:x(I),lineHeight:C},r===Pa?{letterSpacing:`${Cp(E/I)}em`}:{},v,u),h={h1:m(s,96,1.167,-1.5),h2:m(s,60,1.2,-.5),h3:m(i,48,1.167,0),h4:m(i,34,1.235,.25),h5:m(i,24,1.334,0),h6:m(l,20,1.6,.15),subtitle1:m(i,16,1.75,.15),subtitle2:m(l,14,1.57,.1),body1:m(i,16,1.5,.15),body2:m(i,14,1.43,.15),button:m(l,14,1.75,.4,_a),caption:m(i,12,1.66,.4),overline:m(i,12,2.66,1,_a),inherit:{fontFamily:"inherit",fontWeight:"inherit",fontSize:"inherit",lineHeight:"inherit",letterSpacing:"inherit"}};return Qe(R({htmlFontSize:d,pxToRem:x,fontFamily:r,fontSize:o,fontWeightLight:s,fontWeightRegular:i,fontWeightMedium:l,fontWeightBold:c},h),w,{clone:!1})}const Op=.2,_p=.14,Pp=.12;function we(...e){return[`${e[0]}px ${e[1]}px ${e[2]}px ${e[3]}px rgba(0,0,0,${Op})`,`${e[4]}px ${e[5]}px ${e[6]}px ${e[7]}px rgba(0,0,0,${_p})`,`${e[8]}px ${e[9]}px ${e[10]}px ${e[11]}px rgba(0,0,0,${Pp})`].join(",")}const Ip=["none",we(0,2,1,-1,0,1,1,0,0,1,3,0),we(0,3,1,-2,0,2,2,0,0,1,5,0),we(0,3,3,-2,0,3,4,0,0,1,8,0),we(0,2,4,-1,0,4,5,0,0,1,10,0),we(0,3,5,-1,0,5,8,0,0,1,14,0),we(0,3,5,-1,0,6,10,0,0,1,18,0),we(0,4,5,-2,0,7,10,1,0,2,16,1),we(0,5,5,-3,0,8,10,1,0,3,14,2),we(0,5,6,-3,0,9,12,1,0,3,16,2),we(0,6,6,-3,0,10,14,1,0,4,18,3),we(0,6,7,-4,0,11,15,1,0,4,20,3),we(0,7,8,-4,0,12,17,2,0,5,22,4),we(0,7,8,-4,0,13,19,2,0,5,24,4),we(0,7,9,-4,0,14,21,2,0,5,26,4),we(0,8,9,-5,0,15,22,2,0,6,28,5),we(0,8,10,-5,0,16,24,2,0,6,30,5),we(0,8,11,-5,0,17,26,2,0,6,32,5),we(0,9,11,-5,0,18,28,2,0,7,34,6),we(0,9,12,-6,0,19,29,2,0,7,36,6),we(0,10,13,-6,0,20,31,3,0,8,38,7),we(0,10,13,-6,0,21,33,3,0,8,40,7),we(0,10,14,-6,0,22,35,3,0,8,42,7),we(0,11,14,-7,0,23,36,3,0,9,44,8),we(0,11,15,-7,0,24,38,3,0,9,46,8)],Mp=Ip,$p=["duration","easing","delay"],Ap={easeInOut:"cubic-bezier(0.4, 0, 0.2, 1)",easeOut:"cubic-bezier(0.0, 0, 0.2, 1)",easeIn:"cubic-bezier(0.4, 0, 1, 1)",sharp:"cubic-bezier(0.4, 0, 0.6, 1)"},Dp={shortest:150,shorter:200,short:250,standard:300,complex:375,enteringScreen:225,leavingScreen:195};function Ia(e){return`${Math.round(e)}ms`}function Bp(e){if(!e)return 0;const t=e/36;return Math.round((4+15*t**.25+t/5)*10)}function Vp(e){const t=R({},Ap,e.easing),n=R({},Dp,e.duration);return R({getAutoHeightDuration:Bp,create:(o=["all"],s={})=>{const{duration:i=n.standard,easing:l=t.easeInOut,delay:c=0}=s,d=ye(s,$p);if(process.env.NODE_ENV!=="production"){const u=w=>typeof w=="string",f=w=>!isNaN(parseFloat(w));!u(o)&&!Array.isArray(o)&&console.error('MUI: Argument "props" must be a string or Array.'),!f(i)&&!u(i)&&console.error(`MUI: Argument "duration" must be a number or a string but found ${i}.`),u(l)||console.error('MUI: Argument "easing" must be a string.'),!f(c)&&!u(c)&&console.error('MUI: Argument "delay" must be a number or a string.'),typeof s!="object"&&console.error(["MUI: Secong argument of transition.create must be an object.","Arguments should be either `create('prop1', options)` or `create(['prop1', 'prop2'], options)`"].join(` `)),Object.keys(d).length!==0&&console.error(`MUI: Unrecognized argument(s) [${Object.keys(d).join(",")}].`)}return(Array.isArray(o)?o:[o]).map(u=>`${u} ${typeof i=="string"?i:Ia(i)} ${l} ${typeof c=="string"?c:Ia(c)}`).join(",")}},e,{easing:t,duration:n})}const zp={mobileStepper:1e3,fab:1050,speedDial:1050,appBar:1100,drawer:1200,modal:1300,snackbar:1400,tooltip:1500},Lp=zp,Fp=["breakpoints","mixins","spacing","palette","transitions","typography","shape"];function Gp(e={},...t){const{mixins:n={},palette:r={},transitions:o={},typography:s={}}=e,i=ye(e,Fp);if(e.vars)throw new Error(process.env.NODE_ENV!=="production"?"MUI: `vars` is a private field used for CSS variables support.\nPlease use another name.":zt(18));const l=jp(r),c=To(e);let d=Qe(c,{mixins:cp(c.breakpoints,n),palette:l,shadows:Mp.slice(),typography:Rp(l,s),transitions:Vp(o),zIndex:R({},Lp)});if(d=Qe(d,i),d=t.reduce((u,f)=>Qe(u,f),d),process.env.NODE_ENV!=="production"){const u=["active","checked","completed","disabled","error","expanded","focused","focusVisible","required","selected"],f=(w,b)=>{let x;for(x in w){const m=w[x];if(u.indexOf(x)!==-1&&Object.keys(m).length>0){if(process.env.NODE_ENV!=="production"){const h=ur("",x);console.error([`MUI: The \`${b}\` component increases the CSS specificity of the \`${x}\` internal state.`,"You can not override it like this: ",JSON.stringify(w,null,2),"",`Instead, you need to use the '&.${h}' syntax:`,JSON.stringify({root:{[`&.${h}`]:m}},null,2),"","https://mui.com/r/state-classes-guide"].join(` -`))}w[x]={}}}};Object.keys(d.components).forEach(w=>{const b=d.components[w].styleOverrides;b&&w.indexOf("Mui")===0&&f(b,w)})}return d.unstable_sxConfig=R({},Eo,i==null?void 0:i.unstable_sxConfig),d.unstable_sx=function(f){return jo({sx:f,theme:this})},d}const Up=Gp(),Ro=Up,Oo="$$material";function _o({props:e,name:t}){return op({props:e,name:t,defaultTheme:Ro,themeId:Oo})}const qp=e=>qn(e)&&e!=="classes",Hp=np({themeId:Oo,defaultTheme:Ro,rootShouldForwardProp:qp}),In=Hp;function Xp(e){return ur("MuiSvgIcon",e)}si("MuiSvgIcon",["root","colorPrimary","colorSecondary","colorAction","colorError","colorDisabled","fontSizeInherit","fontSizeSmall","fontSizeMedium","fontSizeLarge"]);const Yp=["children","className","color","component","fontSize","htmlColor","inheritViewBox","titleAccess","viewBox"],Wp=e=>{const{color:t,fontSize:n,classes:r}=e,o={root:["root",t!=="inherit"&&`color${Ye(t)}`,`fontSize${Ye(n)}`]};return No(o,Xp,r)},Kp=In("svg",{name:"MuiSvgIcon",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.root,n.color!=="inherit"&&t[`color${Ye(n.color)}`],t[`fontSize${Ye(n.fontSize)}`]]}})(({theme:e,ownerState:t})=>{var n,r,o,s,i,l,c,d,u,f,w,b,x;return{userSelect:"none",width:"1em",height:"1em",display:"inline-block",fill:t.hasSvgAsChild?void 0:"currentColor",flexShrink:0,transition:(n=e.transitions)==null||(r=n.create)==null?void 0:r.call(n,"fill",{duration:(o=e.transitions)==null||(o=o.duration)==null?void 0:o.shorter}),fontSize:{inherit:"inherit",small:((s=e.typography)==null||(i=s.pxToRem)==null?void 0:i.call(s,20))||"1.25rem",medium:((l=e.typography)==null||(c=l.pxToRem)==null?void 0:c.call(l,24))||"1.5rem",large:((d=e.typography)==null||(u=d.pxToRem)==null?void 0:u.call(d,35))||"2.1875rem"}[t.fontSize],color:(f=(w=(e.vars||e).palette)==null||(w=w[t.color])==null?void 0:w.main)!=null?f:{action:(b=(e.vars||e).palette)==null||(b=b.action)==null?void 0:b.active,disabled:(x=(e.vars||e).palette)==null||(x=x.action)==null?void 0:x.disabled,inherit:void 0}[t.color]}}),Po=$.forwardRef(function(t,n){const r=_o({props:t,name:"MuiSvgIcon"}),{children:o,className:s,color:i="inherit",component:l="svg",fontSize:c="medium",htmlColor:d,inheritViewBox:u=!1,titleAccess:f,viewBox:w="0 0 24 24"}=r,b=ye(r,Yp),x=$.isValidElement(o)&&o.type==="svg",m=R({},r,{color:i,component:l,fontSize:c,instanceFontSize:t.fontSize,inheritViewBox:u,viewBox:w,hasSvgAsChild:x}),h={};u||(h.viewBox=w);const E=Wp(m);return a.jsxs(Kp,R({as:l,className:ot(E.root,s),focusable:"false",color:d,"aria-hidden":f?void 0:!0,role:f?"img":void 0,ref:n},h,b,x&&o.props,{ownerState:m,children:[x?o.props.children:o,f?a.jsx("title",{children:f}):null]}))});process.env.NODE_ENV!=="production"&&(Po.propTypes={children:p.node,classes:p.object,className:p.string,color:p.oneOfType([p.oneOf(["inherit","action","disabled","primary","secondary","error","info","success","warning"]),p.string]),component:p.elementType,fontSize:p.oneOfType([p.oneOf(["inherit","large","medium","small"]),p.string]),htmlColor:p.string,inheritViewBox:p.bool,shapeRendering:p.string,sx:p.oneOfType([p.arrayOf(p.oneOfType([p.func,p.object,p.bool])),p.func,p.object]),titleAccess:p.string,viewBox:p.string});Po.muiName="SvgIcon";const Ma=Po;function wi(e,t){function n(r,o){return a.jsx(Ma,R({"data-testid":`${t}Icon`,ref:o},r,{children:e}))}return process.env.NODE_ENV!=="production"&&(n.displayName=`${t}Icon`),n.muiName=Ma.muiName,$.memo($.forwardRef(n))}const Jp={configure:e=>{process.env.NODE_ENV!=="production"&&console.warn(["MUI: `ClassNameGenerator` import from `@mui/material/utils` is outdated and might cause unexpected issues.","","You should use `import { unstable_ClassNameGenerator } from '@mui/material/className'` instead","","The detail of the issue: https://github.com/mui/material-ui/issues/30011#issuecomment-1024993401","","The updated documentation: https://mui.com/guides/classname-generator/"].join(` -`)),oi.configure(e)}},Zp=Object.freeze(Object.defineProperty({__proto__:null,capitalize:Ye,createChainedFunction:Td,createSvgIcon:wi,debounce:Cd,deprecatedPropType:Rd,isMuiElement:Od,ownerDocument:Kn,ownerWindow:_d,requirePropFactory:Pd,setRef:Jn,unstable_ClassNameGenerator:Jp,unstable_useEnhancedEffect:Lt,unstable_useId:ei,unsupportedProp:$d,useControlled:ti,useEventCallback:Jr,useForkRef:yt,useIsFocusVisible:ni},Symbol.toStringTag,{value:"Module"})),Qp=id(Zp);var $a;function ew(){return $a||($a=1,function(e){"use client";Object.defineProperty(e,"__esModule",{value:!0}),Object.defineProperty(e,"default",{enumerable:!0,get:function(){return t.createSvgIcon}});var t=Qp}(_r)),_r}var tw=ld;Object.defineProperty(vo,"__esModule",{value:!0});var fi=vo.default=void 0,nw=tw(ew()),rw=a;fi=vo.default=(0,nw.default)((0,rw.jsx)("path",{d:"m10 17 5-5-5-5z"}),"ArrowRight");function ow(e){return typeof e=="string"}function dn(e,t,n){return e===void 0||ow(e)?t:R({},t,{ownerState:R({},t.ownerState,n)})}const aw={disableDefaultClasses:!1},sw=$.createContext(aw);function iw(e){const{disableDefaultClasses:t}=$.useContext(sw);return n=>t?"":e(n)}function lw(e,t=[]){if(e===void 0)return{};const n={};return Object.keys(e).filter(r=>r.match(/^on[A-Z]/)&&typeof e[r]=="function"&&!t.includes(r)).forEach(r=>{n[r]=e[r]}),n}function cw(e,t,n){return typeof e=="function"?e(t,n):e}function Aa(e){if(e===void 0)return{};const t={};return Object.keys(e).filter(n=>!(n.match(/^on[A-Z]/)&&typeof e[n]=="function")).forEach(n=>{t[n]=e[n]}),t}function dw(e){const{getSlotProps:t,additionalProps:n,externalSlotProps:r,externalForwardedProps:o,className:s}=e;if(!t){const b=ot(n==null?void 0:n.className,s,o==null?void 0:o.className,r==null?void 0:r.className),x=R({},n==null?void 0:n.style,o==null?void 0:o.style,r==null?void 0:r.style),m=R({},n,o,r);return b.length>0&&(m.className=b),Object.keys(x).length>0&&(m.style=x),{props:m,internalRef:void 0}}const i=lw(R({},o,r)),l=Aa(r),c=Aa(o),d=t(i),u=ot(d==null?void 0:d.className,n==null?void 0:n.className,s,o==null?void 0:o.className,r==null?void 0:r.className),f=R({},d==null?void 0:d.style,n==null?void 0:n.style,o==null?void 0:o.style,r==null?void 0:r.style),w=R({},d,n,c,l);return u.length>0&&(w.className=u),Object.keys(f).length>0&&(w.style=f),{props:w,internalRef:d.ref}}const uw=["elementType","externalSlotProps","ownerState","skipResolvingSlotProps"];function pw(e){var t;const{elementType:n,externalSlotProps:r,ownerState:o,skipResolvingSlotProps:s=!1}=e,i=ye(e,uw),l=s?{}:cw(r,o),{props:c,internalRef:d}=dw(R({},i,{externalSlotProps:l})),u=yt(d,l==null?void 0:l.ref,(t=e.additionalProps)==null?void 0:t.ref);return dn(n,R({},c,{ref:u}),o)}const mi="base";function ww(e){return`${mi}--${e}`}function fw(e,t){return`${mi}-${e}-${t}`}function hi(e,t){const n=ai[t];return n?ww(n):fw(e,t)}function mw(e,t){const n={};return t.forEach(r=>{n[r]=hi(e,r)}),n}function hw(e){return typeof e=="function"?e():e}const Qn=$.forwardRef(function(t,n){const{children:r,container:o,disablePortal:s=!1}=t,[i,l]=$.useState(null),c=yt($.isValidElement(r)?r.ref:null,n);if(Lt(()=>{s||l(hw(o)||document.body)},[o,s]),Lt(()=>{if(i&&!s)return Jn(n,i),()=>{Jn(n,null)}},[n,i,s]),s){if($.isValidElement(r)){const d={ref:c};return $.cloneElement(r,d)}return a.jsx($.Fragment,{children:r})}return a.jsx($.Fragment,{children:i&&Tl.createPortal(r,i)})});process.env.NODE_ENV!=="production"&&(Qn.propTypes={children:p.node,container:p.oneOfType([vn,p.func]),disablePortal:p.bool});process.env.NODE_ENV!=="production"&&(Qn["propTypes"]=xd(Qn.propTypes));var je="top",Ve="bottom",ze="right",Te="left",Io="auto",Mn=[je,Ve,ze,Te],Ft="start",yn="end",gw="clippingParents",gi="viewport",on="popper",bw="reference",Da=Mn.reduce(function(e,t){return e.concat([t+"-"+Ft,t+"-"+yn])},[]),bi=[].concat(Mn,[Io]).reduce(function(e,t){return e.concat([t,t+"-"+Ft,t+"-"+yn])},[]),vw="beforeRead",xw="read",yw="afterRead",Nw="beforeMain",kw="main",Sw="afterMain",Ew="beforeWrite",jw="write",Tw="afterWrite",Cw=[vw,xw,yw,Nw,kw,Sw,Ew,jw,Tw];function We(e){return e?(e.nodeName||"").toLowerCase():null}function Me(e){if(e==null)return window;if(e.toString()!=="[object Window]"){var t=e.ownerDocument;return t&&t.defaultView||window}return e}function kt(e){var t=Me(e).Element;return e instanceof t||e instanceof Element}function Be(e){var t=Me(e).HTMLElement;return e instanceof t||e instanceof HTMLElement}function Mo(e){if(typeof ShadowRoot>"u")return!1;var t=Me(e).ShadowRoot;return e instanceof t||e instanceof ShadowRoot}function Rw(e){var t=e.state;Object.keys(t.elements).forEach(function(n){var r=t.styles[n]||{},o=t.attributes[n]||{},s=t.elements[n];!Be(s)||!We(s)||(Object.assign(s.style,r),Object.keys(o).forEach(function(i){var l=o[i];l===!1?s.removeAttribute(i):s.setAttribute(i,l===!0?"":l)}))})}function Ow(e){var t=e.state,n={popper:{position:t.options.strategy,left:"0",top:"0",margin:"0"},arrow:{position:"absolute"},reference:{}};return Object.assign(t.elements.popper.style,n.popper),t.styles=n,t.elements.arrow&&Object.assign(t.elements.arrow.style,n.arrow),function(){Object.keys(t.elements).forEach(function(r){var o=t.elements[r],s=t.attributes[r]||{},i=Object.keys(t.styles.hasOwnProperty(r)?t.styles[r]:n[r]),l=i.reduce(function(c,d){return c[d]="",c},{});!Be(o)||!We(o)||(Object.assign(o.style,l),Object.keys(s).forEach(function(c){o.removeAttribute(c)}))})}}const _w={name:"applyStyles",enabled:!0,phase:"write",fn:Rw,effect:Ow,requires:["computeStyles"]};function He(e){return e.split("-")[0]}var ht=Math.max,er=Math.min,Gt=Math.round;function Qr(){var e=navigator.userAgentData;return e!=null&&e.brands&&Array.isArray(e.brands)?e.brands.map(function(t){return t.brand+"/"+t.version}).join(" "):navigator.userAgent}function vi(){return!/^((?!chrome|android).)*safari/i.test(Qr())}function Ut(e,t,n){t===void 0&&(t=!1),n===void 0&&(n=!1);var r=e.getBoundingClientRect(),o=1,s=1;t&&Be(e)&&(o=e.offsetWidth>0&&Gt(r.width)/e.offsetWidth||1,s=e.offsetHeight>0&&Gt(r.height)/e.offsetHeight||1);var i=kt(e)?Me(e):window,l=i.visualViewport,c=!vi()&&n,d=(r.left+(c&&l?l.offsetLeft:0))/o,u=(r.top+(c&&l?l.offsetTop:0))/s,f=r.width/o,w=r.height/s;return{width:f,height:w,top:u,right:d+f,bottom:u+w,left:d,x:d,y:u}}function $o(e){var t=Ut(e),n=e.offsetWidth,r=e.offsetHeight;return Math.abs(t.width-n)<=1&&(n=t.width),Math.abs(t.height-r)<=1&&(r=t.height),{x:e.offsetLeft,y:e.offsetTop,width:n,height:r}}function xi(e,t){var n=t.getRootNode&&t.getRootNode();if(e.contains(t))return!0;if(n&&Mo(n)){var r=t;do{if(r&&e.isSameNode(r))return!0;r=r.parentNode||r.host}while(r)}return!1}function tt(e){return Me(e).getComputedStyle(e)}function Pw(e){return["table","td","th"].indexOf(We(e))>=0}function it(e){return((kt(e)?e.ownerDocument:e.document)||window.document).documentElement}function yr(e){return We(e)==="html"?e:e.assignedSlot||e.parentNode||(Mo(e)?e.host:null)||it(e)}function Ba(e){return!Be(e)||tt(e).position==="fixed"?null:e.offsetParent}function Iw(e){var t=/firefox/i.test(Qr()),n=/Trident/i.test(Qr());if(n&&Be(e)){var r=tt(e);if(r.position==="fixed")return null}var o=yr(e);for(Mo(o)&&(o=o.host);Be(o)&&["html","body"].indexOf(We(o))<0;){var s=tt(o);if(s.transform!=="none"||s.perspective!=="none"||s.contain==="paint"||["transform","perspective"].indexOf(s.willChange)!==-1||t&&s.willChange==="filter"||t&&s.filter&&s.filter!=="none")return o;o=o.parentNode}return null}function $n(e){for(var t=Me(e),n=Ba(e);n&&Pw(n)&&tt(n).position==="static";)n=Ba(n);return n&&(We(n)==="html"||We(n)==="body"&&tt(n).position==="static")?t:n||Iw(e)||t}function Ao(e){return["top","bottom"].indexOf(e)>=0?"x":"y"}function mn(e,t,n){return ht(e,er(t,n))}function Mw(e,t,n){var r=mn(e,t,n);return r>n?n:r}function yi(){return{top:0,right:0,bottom:0,left:0}}function Ni(e){return Object.assign({},yi(),e)}function ki(e,t){return t.reduce(function(n,r){return n[r]=e,n},{})}var $w=function(t,n){return t=typeof t=="function"?t(Object.assign({},n.rects,{placement:n.placement})):t,Ni(typeof t!="number"?t:ki(t,Mn))};function Aw(e){var t,n=e.state,r=e.name,o=e.options,s=n.elements.arrow,i=n.modifiersData.popperOffsets,l=He(n.placement),c=Ao(l),d=[Te,ze].indexOf(l)>=0,u=d?"height":"width";if(!(!s||!i)){var f=$w(o.padding,n),w=$o(s),b=c==="y"?je:Te,x=c==="y"?Ve:ze,m=n.rects.reference[u]+n.rects.reference[c]-i[c]-n.rects.popper[u],h=i[c]-n.rects.reference[c],E=$n(s),I=E?c==="y"?E.clientHeight||0:E.clientWidth||0:0,C=m/2-h/2,S=f[b],v=I-w[u]-f[x],_=I/2-w[u]/2+C,V=mn(S,_,v),U=c;n.modifiersData[r]=(t={},t[U]=V,t.centerOffset=V-_,t)}}function Dw(e){var t=e.state,n=e.options,r=n.element,o=r===void 0?"[data-popper-arrow]":r;o!=null&&(typeof o=="string"&&(o=t.elements.popper.querySelector(o),!o)||xi(t.elements.popper,o)&&(t.elements.arrow=o))}const Bw={name:"arrow",enabled:!0,phase:"main",fn:Aw,effect:Dw,requires:["popperOffsets"],requiresIfExists:["preventOverflow"]};function qt(e){return e.split("-")[1]}var Vw={top:"auto",right:"auto",bottom:"auto",left:"auto"};function zw(e,t){var n=e.x,r=e.y,o=t.devicePixelRatio||1;return{x:Gt(n*o)/o||0,y:Gt(r*o)/o||0}}function Va(e){var t,n=e.popper,r=e.popperRect,o=e.placement,s=e.variation,i=e.offsets,l=e.position,c=e.gpuAcceleration,d=e.adaptive,u=e.roundOffsets,f=e.isFixed,w=i.x,b=w===void 0?0:w,x=i.y,m=x===void 0?0:x,h=typeof u=="function"?u({x:b,y:m}):{x:b,y:m};b=h.x,m=h.y;var E=i.hasOwnProperty("x"),I=i.hasOwnProperty("y"),C=Te,S=je,v=window;if(d){var _=$n(n),V="clientHeight",U="clientWidth";if(_===Me(n)&&(_=it(n),tt(_).position!=="static"&&l==="absolute"&&(V="scrollHeight",U="scrollWidth")),_=_,o===je||(o===Te||o===ze)&&s===yn){S=Ve;var j=f&&_===v&&v.visualViewport?v.visualViewport.height:_[V];m-=j-r.height,m*=c?1:-1}if(o===Te||(o===je||o===Ve)&&s===yn){C=ze;var O=f&&_===v&&v.visualViewport?v.visualViewport.width:_[U];b-=O-r.width,b*=c?1:-1}}var k=Object.assign({position:l},d&&Vw),A=u===!0?zw({x:b,y:m},Me(n)):{x:b,y:m};if(b=A.x,m=A.y,c){var M;return Object.assign({},k,(M={},M[S]=I?"0":"",M[C]=E?"0":"",M.transform=(v.devicePixelRatio||1)<=1?"translate("+b+"px, "+m+"px)":"translate3d("+b+"px, "+m+"px, 0)",M))}return Object.assign({},k,(t={},t[S]=I?m+"px":"",t[C]=E?b+"px":"",t.transform="",t))}function Lw(e){var t=e.state,n=e.options,r=n.gpuAcceleration,o=r===void 0?!0:r,s=n.adaptive,i=s===void 0?!0:s,l=n.roundOffsets,c=l===void 0?!0:l,d={placement:He(t.placement),variation:qt(t.placement),popper:t.elements.popper,popperRect:t.rects.popper,gpuAcceleration:o,isFixed:t.options.strategy==="fixed"};t.modifiersData.popperOffsets!=null&&(t.styles.popper=Object.assign({},t.styles.popper,Va(Object.assign({},d,{offsets:t.modifiersData.popperOffsets,position:t.options.strategy,adaptive:i,roundOffsets:c})))),t.modifiersData.arrow!=null&&(t.styles.arrow=Object.assign({},t.styles.arrow,Va(Object.assign({},d,{offsets:t.modifiersData.arrow,position:"absolute",adaptive:!1,roundOffsets:c})))),t.attributes.popper=Object.assign({},t.attributes.popper,{"data-popper-placement":t.placement})}const Fw={name:"computeStyles",enabled:!0,phase:"beforeWrite",fn:Lw,data:{}};var Fn={passive:!0};function Gw(e){var t=e.state,n=e.instance,r=e.options,o=r.scroll,s=o===void 0?!0:o,i=r.resize,l=i===void 0?!0:i,c=Me(t.elements.popper),d=[].concat(t.scrollParents.reference,t.scrollParents.popper);return s&&d.forEach(function(u){u.addEventListener("scroll",n.update,Fn)}),l&&c.addEventListener("resize",n.update,Fn),function(){s&&d.forEach(function(u){u.removeEventListener("scroll",n.update,Fn)}),l&&c.removeEventListener("resize",n.update,Fn)}}const Uw={name:"eventListeners",enabled:!0,phase:"write",fn:function(){},effect:Gw,data:{}};var qw={left:"right",right:"left",bottom:"top",top:"bottom"};function Xn(e){return e.replace(/left|right|bottom|top/g,function(t){return qw[t]})}var Hw={start:"end",end:"start"};function za(e){return e.replace(/start|end/g,function(t){return Hw[t]})}function Do(e){var t=Me(e),n=t.pageXOffset,r=t.pageYOffset;return{scrollLeft:n,scrollTop:r}}function Bo(e){return Ut(it(e)).left+Do(e).scrollLeft}function Xw(e,t){var n=Me(e),r=it(e),o=n.visualViewport,s=r.clientWidth,i=r.clientHeight,l=0,c=0;if(o){s=o.width,i=o.height;var d=vi();(d||!d&&t==="fixed")&&(l=o.offsetLeft,c=o.offsetTop)}return{width:s,height:i,x:l+Bo(e),y:c}}function Yw(e){var t,n=it(e),r=Do(e),o=(t=e.ownerDocument)==null?void 0:t.body,s=ht(n.scrollWidth,n.clientWidth,o?o.scrollWidth:0,o?o.clientWidth:0),i=ht(n.scrollHeight,n.clientHeight,o?o.scrollHeight:0,o?o.clientHeight:0),l=-r.scrollLeft+Bo(e),c=-r.scrollTop;return tt(o||n).direction==="rtl"&&(l+=ht(n.clientWidth,o?o.clientWidth:0)-s),{width:s,height:i,x:l,y:c}}function Vo(e){var t=tt(e),n=t.overflow,r=t.overflowX,o=t.overflowY;return/auto|scroll|overlay|hidden/.test(n+o+r)}function Si(e){return["html","body","#document"].indexOf(We(e))>=0?e.ownerDocument.body:Be(e)&&Vo(e)?e:Si(yr(e))}function hn(e,t){var n;t===void 0&&(t=[]);var r=Si(e),o=r===((n=e.ownerDocument)==null?void 0:n.body),s=Me(r),i=o?[s].concat(s.visualViewport||[],Vo(r)?r:[]):r,l=t.concat(i);return o?l:l.concat(hn(yr(i)))}function eo(e){return Object.assign({},e,{left:e.x,top:e.y,right:e.x+e.width,bottom:e.y+e.height})}function Ww(e,t){var n=Ut(e,!1,t==="fixed");return n.top=n.top+e.clientTop,n.left=n.left+e.clientLeft,n.bottom=n.top+e.clientHeight,n.right=n.left+e.clientWidth,n.width=e.clientWidth,n.height=e.clientHeight,n.x=n.left,n.y=n.top,n}function La(e,t,n){return t===gi?eo(Xw(e,n)):kt(t)?Ww(t,n):eo(Yw(it(e)))}function Kw(e){var t=hn(yr(e)),n=["absolute","fixed"].indexOf(tt(e).position)>=0,r=n&&Be(e)?$n(e):e;return kt(r)?t.filter(function(o){return kt(o)&&xi(o,r)&&We(o)!=="body"}):[]}function Jw(e,t,n,r){var o=t==="clippingParents"?Kw(e):[].concat(t),s=[].concat(o,[n]),i=s[0],l=s.reduce(function(c,d){var u=La(e,d,r);return c.top=ht(u.top,c.top),c.right=er(u.right,c.right),c.bottom=er(u.bottom,c.bottom),c.left=ht(u.left,c.left),c},La(e,i,r));return l.width=l.right-l.left,l.height=l.bottom-l.top,l.x=l.left,l.y=l.top,l}function Ei(e){var t=e.reference,n=e.element,r=e.placement,o=r?He(r):null,s=r?qt(r):null,i=t.x+t.width/2-n.width/2,l=t.y+t.height/2-n.height/2,c;switch(o){case je:c={x:i,y:t.y-n.height};break;case Ve:c={x:i,y:t.y+t.height};break;case ze:c={x:t.x+t.width,y:l};break;case Te:c={x:t.x-n.width,y:l};break;default:c={x:t.x,y:t.y}}var d=o?Ao(o):null;if(d!=null){var u=d==="y"?"height":"width";switch(s){case Ft:c[d]=c[d]-(t[u]/2-n[u]/2);break;case yn:c[d]=c[d]+(t[u]/2-n[u]/2);break}}return c}function Nn(e,t){t===void 0&&(t={});var n=t,r=n.placement,o=r===void 0?e.placement:r,s=n.strategy,i=s===void 0?e.strategy:s,l=n.boundary,c=l===void 0?gw:l,d=n.rootBoundary,u=d===void 0?gi:d,f=n.elementContext,w=f===void 0?on:f,b=n.altBoundary,x=b===void 0?!1:b,m=n.padding,h=m===void 0?0:m,E=Ni(typeof h!="number"?h:ki(h,Mn)),I=w===on?bw:on,C=e.rects.popper,S=e.elements[x?I:w],v=Jw(kt(S)?S:S.contextElement||it(e.elements.popper),c,u,i),_=Ut(e.elements.reference),V=Ei({reference:_,element:C,strategy:"absolute",placement:o}),U=eo(Object.assign({},C,V)),j=w===on?U:_,O={top:v.top-j.top+E.top,bottom:j.bottom-v.bottom+E.bottom,left:v.left-j.left+E.left,right:j.right-v.right+E.right},k=e.modifiersData.offset;if(w===on&&k){var A=k[o];Object.keys(O).forEach(function(M){var J=[ze,Ve].indexOf(M)>=0?1:-1,Y=[je,Ve].indexOf(M)>=0?"y":"x";O[M]+=A[Y]*J})}return O}function Zw(e,t){t===void 0&&(t={});var n=t,r=n.placement,o=n.boundary,s=n.rootBoundary,i=n.padding,l=n.flipVariations,c=n.allowedAutoPlacements,d=c===void 0?bi:c,u=qt(r),f=u?l?Da:Da.filter(function(x){return qt(x)===u}):Mn,w=f.filter(function(x){return d.indexOf(x)>=0});w.length===0&&(w=f);var b=w.reduce(function(x,m){return x[m]=Nn(e,{placement:m,boundary:o,rootBoundary:s,padding:i})[He(m)],x},{});return Object.keys(b).sort(function(x,m){return b[x]-b[m]})}function Qw(e){if(He(e)===Io)return[];var t=Xn(e);return[za(e),t,za(t)]}function ef(e){var t=e.state,n=e.options,r=e.name;if(!t.modifiersData[r]._skip){for(var o=n.mainAxis,s=o===void 0?!0:o,i=n.altAxis,l=i===void 0?!0:i,c=n.fallbackPlacements,d=n.padding,u=n.boundary,f=n.rootBoundary,w=n.altBoundary,b=n.flipVariations,x=b===void 0?!0:b,m=n.allowedAutoPlacements,h=t.options.placement,E=He(h),I=E===h,C=c||(I||!x?[Xn(h)]:Qw(h)),S=[h].concat(C).reduce(function(B,X){return B.concat(He(X)===Io?Zw(t,{placement:X,boundary:u,rootBoundary:f,padding:d,flipVariations:x,allowedAutoPlacements:m}):X)},[]),v=t.rects.reference,_=t.rects.popper,V=new Map,U=!0,j=S[0],O=0;O=0,Y=J?"width":"height",F=Nn(t,{placement:k,boundary:u,rootBoundary:f,altBoundary:w,padding:d}),te=J?M?ze:Te:M?Ve:je;v[Y]>_[Y]&&(te=Xn(te));var se=Xn(te),oe=[];if(s&&oe.push(F[A]<=0),l&&oe.push(F[te]<=0,F[se]<=0),oe.every(function(B){return B})){j=k,U=!1;break}V.set(k,oe)}if(U)for(var y=x?3:1,T=function(X){var q=S.find(function(H){var G=V.get(H);if(G)return G.slice(0,X).every(function(K){return K})});if(q)return j=q,"break"},z=y;z>0;z--){var L=T(z);if(L==="break")break}t.placement!==j&&(t.modifiersData[r]._skip=!0,t.placement=j,t.reset=!0)}}const tf={name:"flip",enabled:!0,phase:"main",fn:ef,requiresIfExists:["offset"],data:{_skip:!1}};function Fa(e,t,n){return n===void 0&&(n={x:0,y:0}),{top:e.top-t.height-n.y,right:e.right-t.width+n.x,bottom:e.bottom-t.height+n.y,left:e.left-t.width-n.x}}function Ga(e){return[je,ze,Ve,Te].some(function(t){return e[t]>=0})}function nf(e){var t=e.state,n=e.name,r=t.rects.reference,o=t.rects.popper,s=t.modifiersData.preventOverflow,i=Nn(t,{elementContext:"reference"}),l=Nn(t,{altBoundary:!0}),c=Fa(i,r),d=Fa(l,o,s),u=Ga(c),f=Ga(d);t.modifiersData[n]={referenceClippingOffsets:c,popperEscapeOffsets:d,isReferenceHidden:u,hasPopperEscaped:f},t.attributes.popper=Object.assign({},t.attributes.popper,{"data-popper-reference-hidden":u,"data-popper-escaped":f})}const rf={name:"hide",enabled:!0,phase:"main",requiresIfExists:["preventOverflow"],fn:nf};function of(e,t,n){var r=He(e),o=[Te,je].indexOf(r)>=0?-1:1,s=typeof n=="function"?n(Object.assign({},t,{placement:e})):n,i=s[0],l=s[1];return i=i||0,l=(l||0)*o,[Te,ze].indexOf(r)>=0?{x:l,y:i}:{x:i,y:l}}function af(e){var t=e.state,n=e.options,r=e.name,o=n.offset,s=o===void 0?[0,0]:o,i=bi.reduce(function(u,f){return u[f]=of(f,t.rects,s),u},{}),l=i[t.placement],c=l.x,d=l.y;t.modifiersData.popperOffsets!=null&&(t.modifiersData.popperOffsets.x+=c,t.modifiersData.popperOffsets.y+=d),t.modifiersData[r]=i}const sf={name:"offset",enabled:!0,phase:"main",requires:["popperOffsets"],fn:af};function lf(e){var t=e.state,n=e.name;t.modifiersData[n]=Ei({reference:t.rects.reference,element:t.rects.popper,strategy:"absolute",placement:t.placement})}const cf={name:"popperOffsets",enabled:!0,phase:"read",fn:lf,data:{}};function df(e){return e==="x"?"y":"x"}function uf(e){var t=e.state,n=e.options,r=e.name,o=n.mainAxis,s=o===void 0?!0:o,i=n.altAxis,l=i===void 0?!1:i,c=n.boundary,d=n.rootBoundary,u=n.altBoundary,f=n.padding,w=n.tether,b=w===void 0?!0:w,x=n.tetherOffset,m=x===void 0?0:x,h=Nn(t,{boundary:c,rootBoundary:d,padding:f,altBoundary:u}),E=He(t.placement),I=qt(t.placement),C=!I,S=Ao(E),v=df(S),_=t.modifiersData.popperOffsets,V=t.rects.reference,U=t.rects.popper,j=typeof m=="function"?m(Object.assign({},t.rects,{placement:t.placement})):m,O=typeof j=="number"?{mainAxis:j,altAxis:j}:Object.assign({mainAxis:0,altAxis:0},j),k=t.modifiersData.offset?t.modifiersData.offset[t.placement]:null,A={x:0,y:0};if(_){if(s){var M,J=S==="y"?je:Te,Y=S==="y"?Ve:ze,F=S==="y"?"height":"width",te=_[S],se=te+h[J],oe=te-h[Y],y=b?-U[F]/2:0,T=I===Ft?V[F]:U[F],z=I===Ft?-U[F]:-V[F],L=t.elements.arrow,B=b&&L?$o(L):{width:0,height:0},X=t.modifiersData["arrow#persistent"]?t.modifiersData["arrow#persistent"].padding:yi(),q=X[J],H=X[Y],G=mn(0,V[F],B[F]),K=C?V[F]/2-y-G-q-O.mainAxis:T-G-q-O.mainAxis,Z=C?-V[F]/2+y+G+H+O.mainAxis:z+G+H+O.mainAxis,ue=t.elements.arrow&&$n(t.elements.arrow),P=ue?S==="y"?ue.clientTop||0:ue.clientLeft||0:0,xe=(M=k==null?void 0:k[S])!=null?M:0,D=te+K-xe-P,ve=te+Z-xe,Fe=mn(b?er(se,D):se,te,b?ht(oe,ve):oe);_[S]=Fe,A[S]=Fe-te}if(l){var lt,Se=S==="x"?je:Te,An=S==="x"?Ve:ze,Ge=_[v],Et=v==="y"?"height":"width",ct=Ge+h[Se],jt=Ge-h[An],Tt=[je,Te].indexOf(E)!==-1,Ct=(lt=k==null?void 0:k[v])!=null?lt:0,dt=Tt?ct:Ge-V[Et]-U[Et]-Ct+O.altAxis,Kt=Tt?Ge+V[Et]+U[Et]-Ct-O.altAxis:jt,Dn=b&&Tt?Mw(dt,Ge,Kt):mn(b?dt:ct,Ge,b?Kt:jt);_[v]=Dn,A[v]=Dn-Ge}t.modifiersData[r]=A}}const pf={name:"preventOverflow",enabled:!0,phase:"main",fn:uf,requiresIfExists:["offset"]};function wf(e){return{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}}function ff(e){return e===Me(e)||!Be(e)?Do(e):wf(e)}function mf(e){var t=e.getBoundingClientRect(),n=Gt(t.width)/e.offsetWidth||1,r=Gt(t.height)/e.offsetHeight||1;return n!==1||r!==1}function hf(e,t,n){n===void 0&&(n=!1);var r=Be(t),o=Be(t)&&mf(t),s=it(t),i=Ut(e,o,n),l={scrollLeft:0,scrollTop:0},c={x:0,y:0};return(r||!r&&!n)&&((We(t)!=="body"||Vo(s))&&(l=ff(t)),Be(t)?(c=Ut(t,!0),c.x+=t.clientLeft,c.y+=t.clientTop):s&&(c.x=Bo(s))),{x:i.left+l.scrollLeft-c.x,y:i.top+l.scrollTop-c.y,width:i.width,height:i.height}}function gf(e){var t=new Map,n=new Set,r=[];e.forEach(function(s){t.set(s.name,s)});function o(s){n.add(s.name);var i=[].concat(s.requires||[],s.requiresIfExists||[]);i.forEach(function(l){if(!n.has(l)){var c=t.get(l);c&&o(c)}}),r.push(s)}return e.forEach(function(s){n.has(s.name)||o(s)}),r}function bf(e){var t=gf(e);return Cw.reduce(function(n,r){return n.concat(t.filter(function(o){return o.phase===r}))},[])}function vf(e){var t;return function(){return t||(t=new Promise(function(n){Promise.resolve().then(function(){t=void 0,n(e())})})),t}}function xf(e){var t=e.reduce(function(n,r){var o=n[r.name];return n[r.name]=o?Object.assign({},o,r,{options:Object.assign({},o.options,r.options),data:Object.assign({},o.data,r.data)}):r,n},{});return Object.keys(t).map(function(n){return t[n]})}var Ua={placement:"bottom",modifiers:[],strategy:"absolute"};function qa(){for(var e=arguments.length,t=new Array(e),n=0;nNo({root:["root"]},iw(Sf)),Of={},_f=$.forwardRef(function(t,n){var r;const{anchorEl:o,children:s,direction:i,disablePortal:l,modifiers:c,open:d,placement:u,popperOptions:f,popperRef:w,slotProps:b={},slots:x={},TransitionProps:m}=t,h=ye(t,Ef),E=$.useRef(null),I=yt(E,n),C=$.useRef(null),S=yt(C,w),v=$.useRef(S);Lt(()=>{v.current=S},[S]),$.useImperativeHandle(w,()=>C.current,[]);const _=Tf(u,i),[V,U]=$.useState(_),[j,O]=$.useState(tr(o));$.useEffect(()=>{C.current&&C.current.forceUpdate()}),$.useEffect(()=>{o&&O(tr(o))},[o]),Lt(()=>{if(!j||!d)return;const Y=se=>{U(se.placement)};if(process.env.NODE_ENV!=="production"&&j&&Nr(j)&&j.nodeType===1){const se=j.getBoundingClientRect();process.env.NODE_ENV!=="test"&&se.top===0&&se.left===0&&se.right===0&&se.bottom===0&&console.warn(["MUI: The `anchorEl` prop provided to the component is invalid.","The anchor element should be part of the document layout.","Make sure the element is present in the document or that it's not display none."].join(` -`))}let F=[{name:"preventOverflow",options:{altBoundary:l}},{name:"flip",options:{altBoundary:l}},{name:"onUpdate",enabled:!0,phase:"afterWrite",fn:({state:se})=>{Y(se)}}];c!=null&&(F=F.concat(c)),f&&f.modifiers!=null&&(F=F.concat(f.modifiers));const te=kf(j,E.current,R({placement:_},f,{modifiers:F}));return v.current(te),()=>{te.destroy(),v.current(null)}},[j,l,c,d,f,_]);const k={placement:V};m!==null&&(k.TransitionProps=m);const A=Rf(),M=(r=x.root)!=null?r:"div",J=pw({elementType:M,externalSlotProps:b.root,externalForwardedProps:h,additionalProps:{role:"tooltip",ref:I},ownerState:t,className:A.root});return a.jsx(M,R({},J,{children:typeof s=="function"?s(k):s}))}),Ti=$.forwardRef(function(t,n){const{anchorEl:r,children:o,container:s,direction:i="ltr",disablePortal:l=!1,keepMounted:c=!1,modifiers:d,open:u,placement:f="bottom",popperOptions:w=Of,popperRef:b,style:x,transition:m=!1,slotProps:h={},slots:E={}}=t,I=ye(t,jf),[C,S]=$.useState(!0),v=()=>{S(!1)},_=()=>{S(!0)};if(!c&&!u&&(!m||C))return null;let V;if(s)V=s;else if(r){const O=tr(r);V=O&&Nr(O)?Kn(O).body:Kn(null).body}const U=!u&&c&&(!m||C)?"none":void 0,j=m?{in:u,onEnter:v,onExited:_}:void 0;return a.jsx(Qn,{disablePortal:l,container:V,children:a.jsx(_f,R({anchorEl:r,direction:i,disablePortal:l,modifiers:d,ref:n,open:m?!C:u,placement:f,popperOptions:w,popperRef:b,slotProps:h,slots:E},I,{style:R({position:"fixed",top:0,left:0,display:U},x),TransitionProps:j,children:o}))})});process.env.NODE_ENV!=="production"&&(Ti.propTypes={anchorEl:xo(p.oneOfType([vn,p.object,p.func]),e=>{if(e.open){const t=tr(e.anchorEl);if(t&&Nr(t)&&t.nodeType===1){const n=t.getBoundingClientRect();if(process.env.NODE_ENV!=="test"&&n.top===0&&n.left===0&&n.right===0&&n.bottom===0)return new Error(["MUI: The `anchorEl` prop provided to the component is invalid.","The anchor element should be part of the document layout.","Make sure the element is present in the document or that it's not display none."].join(` +`))}w[x]={}}}};Object.keys(d.components).forEach(w=>{const b=d.components[w].styleOverrides;b&&w.indexOf("Mui")===0&&f(b,w)})}return d.unstable_sxConfig=R({},Eo,i==null?void 0:i.unstable_sxConfig),d.unstable_sx=function(f){return jo({sx:f,theme:this})},d}const Up=Gp(),Ro=Up,Oo="$$material";function _o({props:e,name:t}){return op({props:e,name:t,defaultTheme:Ro,themeId:Oo})}const qp=e=>qn(e)&&e!=="classes",Hp=np({themeId:Oo,defaultTheme:Ro,rootShouldForwardProp:qp}),In=Hp;function Xp(e){return ur("MuiSvgIcon",e)}si("MuiSvgIcon",["root","colorPrimary","colorSecondary","colorAction","colorError","colorDisabled","fontSizeInherit","fontSizeSmall","fontSizeMedium","fontSizeLarge"]);const Yp=["children","className","color","component","fontSize","htmlColor","inheritViewBox","titleAccess","viewBox"],Wp=e=>{const{color:t,fontSize:n,classes:r}=e,o={root:["root",t!=="inherit"&&`color${Ye(t)}`,`fontSize${Ye(n)}`]};return No(o,Xp,r)},Kp=In("svg",{name:"MuiSvgIcon",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.root,n.color!=="inherit"&&t[`color${Ye(n.color)}`],t[`fontSize${Ye(n.fontSize)}`]]}})(({theme:e,ownerState:t})=>{var n,r,o,s,i,l,c,d,u,f,w,b,x;return{userSelect:"none",width:"1em",height:"1em",display:"inline-block",fill:t.hasSvgAsChild?void 0:"currentColor",flexShrink:0,transition:(n=e.transitions)==null||(r=n.create)==null?void 0:r.call(n,"fill",{duration:(o=e.transitions)==null||(o=o.duration)==null?void 0:o.shorter}),fontSize:{inherit:"inherit",small:((s=e.typography)==null||(i=s.pxToRem)==null?void 0:i.call(s,20))||"1.25rem",medium:((l=e.typography)==null||(c=l.pxToRem)==null?void 0:c.call(l,24))||"1.5rem",large:((d=e.typography)==null||(u=d.pxToRem)==null?void 0:u.call(d,35))||"2.1875rem"}[t.fontSize],color:(f=(w=(e.vars||e).palette)==null||(w=w[t.color])==null?void 0:w.main)!=null?f:{action:(b=(e.vars||e).palette)==null||(b=b.action)==null?void 0:b.active,disabled:(x=(e.vars||e).palette)==null||(x=x.action)==null?void 0:x.disabled,inherit:void 0}[t.color]}}),Po=$.forwardRef(function(t,n){const r=_o({props:t,name:"MuiSvgIcon"}),{children:o,className:s,color:i="inherit",component:l="svg",fontSize:c="medium",htmlColor:d,inheritViewBox:u=!1,titleAccess:f,viewBox:w="0 0 24 24"}=r,b=ye(r,Yp),x=$.isValidElement(o)&&o.type==="svg",m=R({},r,{color:i,component:l,fontSize:c,instanceFontSize:t.fontSize,inheritViewBox:u,viewBox:w,hasSvgAsChild:x}),h={};u||(h.viewBox=w);const k=Wp(m);return a.jsxs(Kp,R({as:l,className:ot(k.root,s),focusable:"false",color:d,"aria-hidden":f?void 0:!0,role:f?"img":void 0,ref:n},h,b,x&&o.props,{ownerState:m,children:[x?o.props.children:o,f?a.jsx("title",{children:f}):null]}))});process.env.NODE_ENV!=="production"&&(Po.propTypes={children:p.node,classes:p.object,className:p.string,color:p.oneOfType([p.oneOf(["inherit","action","disabled","primary","secondary","error","info","success","warning"]),p.string]),component:p.elementType,fontSize:p.oneOfType([p.oneOf(["inherit","large","medium","small"]),p.string]),htmlColor:p.string,inheritViewBox:p.bool,shapeRendering:p.string,sx:p.oneOfType([p.arrayOf(p.oneOfType([p.func,p.object,p.bool])),p.func,p.object]),titleAccess:p.string,viewBox:p.string});Po.muiName="SvgIcon";const Ma=Po;function wi(e,t){function n(r,o){return a.jsx(Ma,R({"data-testid":`${t}Icon`,ref:o},r,{children:e}))}return process.env.NODE_ENV!=="production"&&(n.displayName=`${t}Icon`),n.muiName=Ma.muiName,$.memo($.forwardRef(n))}const Jp={configure:e=>{process.env.NODE_ENV!=="production"&&console.warn(["MUI: `ClassNameGenerator` import from `@mui/material/utils` is outdated and might cause unexpected issues.","","You should use `import { unstable_ClassNameGenerator } from '@mui/material/className'` instead","","The detail of the issue: https://github.com/mui/material-ui/issues/30011#issuecomment-1024993401","","The updated documentation: https://mui.com/guides/classname-generator/"].join(` +`)),oi.configure(e)}},Zp=Object.freeze(Object.defineProperty({__proto__:null,capitalize:Ye,createChainedFunction:Td,createSvgIcon:wi,debounce:Cd,deprecatedPropType:Rd,isMuiElement:Od,ownerDocument:Kn,ownerWindow:_d,requirePropFactory:Pd,setRef:Jn,unstable_ClassNameGenerator:Jp,unstable_useEnhancedEffect:Lt,unstable_useId:ei,unsupportedProp:$d,useControlled:ti,useEventCallback:Jr,useForkRef:yt,useIsFocusVisible:ni},Symbol.toStringTag,{value:"Module"})),Qp=id(Zp);var $a;function ew(){return $a||($a=1,function(e){"use client";Object.defineProperty(e,"__esModule",{value:!0}),Object.defineProperty(e,"default",{enumerable:!0,get:function(){return t.createSvgIcon}});var t=Qp}(_r)),_r}var tw=ld;Object.defineProperty(vo,"__esModule",{value:!0});var fi=vo.default=void 0,nw=tw(ew()),rw=a;fi=vo.default=(0,nw.default)((0,rw.jsx)("path",{d:"m10 17 5-5-5-5z"}),"ArrowRight");function ow(e){return typeof e=="string"}function dn(e,t,n){return e===void 0||ow(e)?t:R({},t,{ownerState:R({},t.ownerState,n)})}const aw={disableDefaultClasses:!1},sw=$.createContext(aw);function iw(e){const{disableDefaultClasses:t}=$.useContext(sw);return n=>t?"":e(n)}function lw(e,t=[]){if(e===void 0)return{};const n={};return Object.keys(e).filter(r=>r.match(/^on[A-Z]/)&&typeof e[r]=="function"&&!t.includes(r)).forEach(r=>{n[r]=e[r]}),n}function cw(e,t,n){return typeof e=="function"?e(t,n):e}function Aa(e){if(e===void 0)return{};const t={};return Object.keys(e).filter(n=>!(n.match(/^on[A-Z]/)&&typeof e[n]=="function")).forEach(n=>{t[n]=e[n]}),t}function dw(e){const{getSlotProps:t,additionalProps:n,externalSlotProps:r,externalForwardedProps:o,className:s}=e;if(!t){const b=ot(n==null?void 0:n.className,s,o==null?void 0:o.className,r==null?void 0:r.className),x=R({},n==null?void 0:n.style,o==null?void 0:o.style,r==null?void 0:r.style),m=R({},n,o,r);return b.length>0&&(m.className=b),Object.keys(x).length>0&&(m.style=x),{props:m,internalRef:void 0}}const i=lw(R({},o,r)),l=Aa(r),c=Aa(o),d=t(i),u=ot(d==null?void 0:d.className,n==null?void 0:n.className,s,o==null?void 0:o.className,r==null?void 0:r.className),f=R({},d==null?void 0:d.style,n==null?void 0:n.style,o==null?void 0:o.style,r==null?void 0:r.style),w=R({},d,n,c,l);return u.length>0&&(w.className=u),Object.keys(f).length>0&&(w.style=f),{props:w,internalRef:d.ref}}const uw=["elementType","externalSlotProps","ownerState","skipResolvingSlotProps"];function pw(e){var t;const{elementType:n,externalSlotProps:r,ownerState:o,skipResolvingSlotProps:s=!1}=e,i=ye(e,uw),l=s?{}:cw(r,o),{props:c,internalRef:d}=dw(R({},i,{externalSlotProps:l})),u=yt(d,l==null?void 0:l.ref,(t=e.additionalProps)==null?void 0:t.ref);return dn(n,R({},c,{ref:u}),o)}const mi="base";function ww(e){return`${mi}--${e}`}function fw(e,t){return`${mi}-${e}-${t}`}function hi(e,t){const n=ai[t];return n?ww(n):fw(e,t)}function mw(e,t){const n={};return t.forEach(r=>{n[r]=hi(e,r)}),n}function hw(e){return typeof e=="function"?e():e}const Qn=$.forwardRef(function(t,n){const{children:r,container:o,disablePortal:s=!1}=t,[i,l]=$.useState(null),c=yt($.isValidElement(r)?r.ref:null,n);if(Lt(()=>{s||l(hw(o)||document.body)},[o,s]),Lt(()=>{if(i&&!s)return Jn(n,i),()=>{Jn(n,null)}},[n,i,s]),s){if($.isValidElement(r)){const d={ref:c};return $.cloneElement(r,d)}return a.jsx($.Fragment,{children:r})}return a.jsx($.Fragment,{children:i&&Tl.createPortal(r,i)})});process.env.NODE_ENV!=="production"&&(Qn.propTypes={children:p.node,container:p.oneOfType([vn,p.func]),disablePortal:p.bool});process.env.NODE_ENV!=="production"&&(Qn["propTypes"]=xd(Qn.propTypes));var je="top",Ve="bottom",ze="right",Te="left",Io="auto",Mn=[je,Ve,ze,Te],Ft="start",yn="end",gw="clippingParents",gi="viewport",on="popper",bw="reference",Da=Mn.reduce(function(e,t){return e.concat([t+"-"+Ft,t+"-"+yn])},[]),bi=[].concat(Mn,[Io]).reduce(function(e,t){return e.concat([t,t+"-"+Ft,t+"-"+yn])},[]),vw="beforeRead",xw="read",yw="afterRead",Nw="beforeMain",kw="main",Sw="afterMain",Ew="beforeWrite",jw="write",Tw="afterWrite",Cw=[vw,xw,yw,Nw,kw,Sw,Ew,jw,Tw];function We(e){return e?(e.nodeName||"").toLowerCase():null}function Me(e){if(e==null)return window;if(e.toString()!=="[object Window]"){var t=e.ownerDocument;return t&&t.defaultView||window}return e}function kt(e){var t=Me(e).Element;return e instanceof t||e instanceof Element}function Be(e){var t=Me(e).HTMLElement;return e instanceof t||e instanceof HTMLElement}function Mo(e){if(typeof ShadowRoot>"u")return!1;var t=Me(e).ShadowRoot;return e instanceof t||e instanceof ShadowRoot}function Rw(e){var t=e.state;Object.keys(t.elements).forEach(function(n){var r=t.styles[n]||{},o=t.attributes[n]||{},s=t.elements[n];!Be(s)||!We(s)||(Object.assign(s.style,r),Object.keys(o).forEach(function(i){var l=o[i];l===!1?s.removeAttribute(i):s.setAttribute(i,l===!0?"":l)}))})}function Ow(e){var t=e.state,n={popper:{position:t.options.strategy,left:"0",top:"0",margin:"0"},arrow:{position:"absolute"},reference:{}};return Object.assign(t.elements.popper.style,n.popper),t.styles=n,t.elements.arrow&&Object.assign(t.elements.arrow.style,n.arrow),function(){Object.keys(t.elements).forEach(function(r){var o=t.elements[r],s=t.attributes[r]||{},i=Object.keys(t.styles.hasOwnProperty(r)?t.styles[r]:n[r]),l=i.reduce(function(c,d){return c[d]="",c},{});!Be(o)||!We(o)||(Object.assign(o.style,l),Object.keys(s).forEach(function(c){o.removeAttribute(c)}))})}}const _w={name:"applyStyles",enabled:!0,phase:"write",fn:Rw,effect:Ow,requires:["computeStyles"]};function He(e){return e.split("-")[0]}var ht=Math.max,er=Math.min,Gt=Math.round;function Qr(){var e=navigator.userAgentData;return e!=null&&e.brands&&Array.isArray(e.brands)?e.brands.map(function(t){return t.brand+"/"+t.version}).join(" "):navigator.userAgent}function vi(){return!/^((?!chrome|android).)*safari/i.test(Qr())}function Ut(e,t,n){t===void 0&&(t=!1),n===void 0&&(n=!1);var r=e.getBoundingClientRect(),o=1,s=1;t&&Be(e)&&(o=e.offsetWidth>0&&Gt(r.width)/e.offsetWidth||1,s=e.offsetHeight>0&&Gt(r.height)/e.offsetHeight||1);var i=kt(e)?Me(e):window,l=i.visualViewport,c=!vi()&&n,d=(r.left+(c&&l?l.offsetLeft:0))/o,u=(r.top+(c&&l?l.offsetTop:0))/s,f=r.width/o,w=r.height/s;return{width:f,height:w,top:u,right:d+f,bottom:u+w,left:d,x:d,y:u}}function $o(e){var t=Ut(e),n=e.offsetWidth,r=e.offsetHeight;return Math.abs(t.width-n)<=1&&(n=t.width),Math.abs(t.height-r)<=1&&(r=t.height),{x:e.offsetLeft,y:e.offsetTop,width:n,height:r}}function xi(e,t){var n=t.getRootNode&&t.getRootNode();if(e.contains(t))return!0;if(n&&Mo(n)){var r=t;do{if(r&&e.isSameNode(r))return!0;r=r.parentNode||r.host}while(r)}return!1}function tt(e){return Me(e).getComputedStyle(e)}function Pw(e){return["table","td","th"].indexOf(We(e))>=0}function it(e){return((kt(e)?e.ownerDocument:e.document)||window.document).documentElement}function yr(e){return We(e)==="html"?e:e.assignedSlot||e.parentNode||(Mo(e)?e.host:null)||it(e)}function Ba(e){return!Be(e)||tt(e).position==="fixed"?null:e.offsetParent}function Iw(e){var t=/firefox/i.test(Qr()),n=/Trident/i.test(Qr());if(n&&Be(e)){var r=tt(e);if(r.position==="fixed")return null}var o=yr(e);for(Mo(o)&&(o=o.host);Be(o)&&["html","body"].indexOf(We(o))<0;){var s=tt(o);if(s.transform!=="none"||s.perspective!=="none"||s.contain==="paint"||["transform","perspective"].indexOf(s.willChange)!==-1||t&&s.willChange==="filter"||t&&s.filter&&s.filter!=="none")return o;o=o.parentNode}return null}function $n(e){for(var t=Me(e),n=Ba(e);n&&Pw(n)&&tt(n).position==="static";)n=Ba(n);return n&&(We(n)==="html"||We(n)==="body"&&tt(n).position==="static")?t:n||Iw(e)||t}function Ao(e){return["top","bottom"].indexOf(e)>=0?"x":"y"}function mn(e,t,n){return ht(e,er(t,n))}function Mw(e,t,n){var r=mn(e,t,n);return r>n?n:r}function yi(){return{top:0,right:0,bottom:0,left:0}}function Ni(e){return Object.assign({},yi(),e)}function ki(e,t){return t.reduce(function(n,r){return n[r]=e,n},{})}var $w=function(t,n){return t=typeof t=="function"?t(Object.assign({},n.rects,{placement:n.placement})):t,Ni(typeof t!="number"?t:ki(t,Mn))};function Aw(e){var t,n=e.state,r=e.name,o=e.options,s=n.elements.arrow,i=n.modifiersData.popperOffsets,l=He(n.placement),c=Ao(l),d=[Te,ze].indexOf(l)>=0,u=d?"height":"width";if(!(!s||!i)){var f=$w(o.padding,n),w=$o(s),b=c==="y"?je:Te,x=c==="y"?Ve:ze,m=n.rects.reference[u]+n.rects.reference[c]-i[c]-n.rects.popper[u],h=i[c]-n.rects.reference[c],k=$n(s),I=k?c==="y"?k.clientHeight||0:k.clientWidth||0:0,C=m/2-h/2,E=f[b],v=I-w[u]-f[x],_=I/2-w[u]/2+C,V=mn(E,_,v),U=c;n.modifiersData[r]=(t={},t[U]=V,t.centerOffset=V-_,t)}}function Dw(e){var t=e.state,n=e.options,r=n.element,o=r===void 0?"[data-popper-arrow]":r;o!=null&&(typeof o=="string"&&(o=t.elements.popper.querySelector(o),!o)||xi(t.elements.popper,o)&&(t.elements.arrow=o))}const Bw={name:"arrow",enabled:!0,phase:"main",fn:Aw,effect:Dw,requires:["popperOffsets"],requiresIfExists:["preventOverflow"]};function qt(e){return e.split("-")[1]}var Vw={top:"auto",right:"auto",bottom:"auto",left:"auto"};function zw(e,t){var n=e.x,r=e.y,o=t.devicePixelRatio||1;return{x:Gt(n*o)/o||0,y:Gt(r*o)/o||0}}function Va(e){var t,n=e.popper,r=e.popperRect,o=e.placement,s=e.variation,i=e.offsets,l=e.position,c=e.gpuAcceleration,d=e.adaptive,u=e.roundOffsets,f=e.isFixed,w=i.x,b=w===void 0?0:w,x=i.y,m=x===void 0?0:x,h=typeof u=="function"?u({x:b,y:m}):{x:b,y:m};b=h.x,m=h.y;var k=i.hasOwnProperty("x"),I=i.hasOwnProperty("y"),C=Te,E=je,v=window;if(d){var _=$n(n),V="clientHeight",U="clientWidth";if(_===Me(n)&&(_=it(n),tt(_).position!=="static"&&l==="absolute"&&(V="scrollHeight",U="scrollWidth")),_=_,o===je||(o===Te||o===ze)&&s===yn){E=Ve;var j=f&&_===v&&v.visualViewport?v.visualViewport.height:_[V];m-=j-r.height,m*=c?1:-1}if(o===Te||(o===je||o===Ve)&&s===yn){C=ze;var O=f&&_===v&&v.visualViewport?v.visualViewport.width:_[U];b-=O-r.width,b*=c?1:-1}}var S=Object.assign({position:l},d&&Vw),A=u===!0?zw({x:b,y:m},Me(n)):{x:b,y:m};if(b=A.x,m=A.y,c){var M;return Object.assign({},S,(M={},M[E]=I?"0":"",M[C]=k?"0":"",M.transform=(v.devicePixelRatio||1)<=1?"translate("+b+"px, "+m+"px)":"translate3d("+b+"px, "+m+"px, 0)",M))}return Object.assign({},S,(t={},t[E]=I?m+"px":"",t[C]=k?b+"px":"",t.transform="",t))}function Lw(e){var t=e.state,n=e.options,r=n.gpuAcceleration,o=r===void 0?!0:r,s=n.adaptive,i=s===void 0?!0:s,l=n.roundOffsets,c=l===void 0?!0:l,d={placement:He(t.placement),variation:qt(t.placement),popper:t.elements.popper,popperRect:t.rects.popper,gpuAcceleration:o,isFixed:t.options.strategy==="fixed"};t.modifiersData.popperOffsets!=null&&(t.styles.popper=Object.assign({},t.styles.popper,Va(Object.assign({},d,{offsets:t.modifiersData.popperOffsets,position:t.options.strategy,adaptive:i,roundOffsets:c})))),t.modifiersData.arrow!=null&&(t.styles.arrow=Object.assign({},t.styles.arrow,Va(Object.assign({},d,{offsets:t.modifiersData.arrow,position:"absolute",adaptive:!1,roundOffsets:c})))),t.attributes.popper=Object.assign({},t.attributes.popper,{"data-popper-placement":t.placement})}const Fw={name:"computeStyles",enabled:!0,phase:"beforeWrite",fn:Lw,data:{}};var Fn={passive:!0};function Gw(e){var t=e.state,n=e.instance,r=e.options,o=r.scroll,s=o===void 0?!0:o,i=r.resize,l=i===void 0?!0:i,c=Me(t.elements.popper),d=[].concat(t.scrollParents.reference,t.scrollParents.popper);return s&&d.forEach(function(u){u.addEventListener("scroll",n.update,Fn)}),l&&c.addEventListener("resize",n.update,Fn),function(){s&&d.forEach(function(u){u.removeEventListener("scroll",n.update,Fn)}),l&&c.removeEventListener("resize",n.update,Fn)}}const Uw={name:"eventListeners",enabled:!0,phase:"write",fn:function(){},effect:Gw,data:{}};var qw={left:"right",right:"left",bottom:"top",top:"bottom"};function Xn(e){return e.replace(/left|right|bottom|top/g,function(t){return qw[t]})}var Hw={start:"end",end:"start"};function za(e){return e.replace(/start|end/g,function(t){return Hw[t]})}function Do(e){var t=Me(e),n=t.pageXOffset,r=t.pageYOffset;return{scrollLeft:n,scrollTop:r}}function Bo(e){return Ut(it(e)).left+Do(e).scrollLeft}function Xw(e,t){var n=Me(e),r=it(e),o=n.visualViewport,s=r.clientWidth,i=r.clientHeight,l=0,c=0;if(o){s=o.width,i=o.height;var d=vi();(d||!d&&t==="fixed")&&(l=o.offsetLeft,c=o.offsetTop)}return{width:s,height:i,x:l+Bo(e),y:c}}function Yw(e){var t,n=it(e),r=Do(e),o=(t=e.ownerDocument)==null?void 0:t.body,s=ht(n.scrollWidth,n.clientWidth,o?o.scrollWidth:0,o?o.clientWidth:0),i=ht(n.scrollHeight,n.clientHeight,o?o.scrollHeight:0,o?o.clientHeight:0),l=-r.scrollLeft+Bo(e),c=-r.scrollTop;return tt(o||n).direction==="rtl"&&(l+=ht(n.clientWidth,o?o.clientWidth:0)-s),{width:s,height:i,x:l,y:c}}function Vo(e){var t=tt(e),n=t.overflow,r=t.overflowX,o=t.overflowY;return/auto|scroll|overlay|hidden/.test(n+o+r)}function Si(e){return["html","body","#document"].indexOf(We(e))>=0?e.ownerDocument.body:Be(e)&&Vo(e)?e:Si(yr(e))}function hn(e,t){var n;t===void 0&&(t=[]);var r=Si(e),o=r===((n=e.ownerDocument)==null?void 0:n.body),s=Me(r),i=o?[s].concat(s.visualViewport||[],Vo(r)?r:[]):r,l=t.concat(i);return o?l:l.concat(hn(yr(i)))}function eo(e){return Object.assign({},e,{left:e.x,top:e.y,right:e.x+e.width,bottom:e.y+e.height})}function Ww(e,t){var n=Ut(e,!1,t==="fixed");return n.top=n.top+e.clientTop,n.left=n.left+e.clientLeft,n.bottom=n.top+e.clientHeight,n.right=n.left+e.clientWidth,n.width=e.clientWidth,n.height=e.clientHeight,n.x=n.left,n.y=n.top,n}function La(e,t,n){return t===gi?eo(Xw(e,n)):kt(t)?Ww(t,n):eo(Yw(it(e)))}function Kw(e){var t=hn(yr(e)),n=["absolute","fixed"].indexOf(tt(e).position)>=0,r=n&&Be(e)?$n(e):e;return kt(r)?t.filter(function(o){return kt(o)&&xi(o,r)&&We(o)!=="body"}):[]}function Jw(e,t,n,r){var o=t==="clippingParents"?Kw(e):[].concat(t),s=[].concat(o,[n]),i=s[0],l=s.reduce(function(c,d){var u=La(e,d,r);return c.top=ht(u.top,c.top),c.right=er(u.right,c.right),c.bottom=er(u.bottom,c.bottom),c.left=ht(u.left,c.left),c},La(e,i,r));return l.width=l.right-l.left,l.height=l.bottom-l.top,l.x=l.left,l.y=l.top,l}function Ei(e){var t=e.reference,n=e.element,r=e.placement,o=r?He(r):null,s=r?qt(r):null,i=t.x+t.width/2-n.width/2,l=t.y+t.height/2-n.height/2,c;switch(o){case je:c={x:i,y:t.y-n.height};break;case Ve:c={x:i,y:t.y+t.height};break;case ze:c={x:t.x+t.width,y:l};break;case Te:c={x:t.x-n.width,y:l};break;default:c={x:t.x,y:t.y}}var d=o?Ao(o):null;if(d!=null){var u=d==="y"?"height":"width";switch(s){case Ft:c[d]=c[d]-(t[u]/2-n[u]/2);break;case yn:c[d]=c[d]+(t[u]/2-n[u]/2);break}}return c}function Nn(e,t){t===void 0&&(t={});var n=t,r=n.placement,o=r===void 0?e.placement:r,s=n.strategy,i=s===void 0?e.strategy:s,l=n.boundary,c=l===void 0?gw:l,d=n.rootBoundary,u=d===void 0?gi:d,f=n.elementContext,w=f===void 0?on:f,b=n.altBoundary,x=b===void 0?!1:b,m=n.padding,h=m===void 0?0:m,k=Ni(typeof h!="number"?h:ki(h,Mn)),I=w===on?bw:on,C=e.rects.popper,E=e.elements[x?I:w],v=Jw(kt(E)?E:E.contextElement||it(e.elements.popper),c,u,i),_=Ut(e.elements.reference),V=Ei({reference:_,element:C,strategy:"absolute",placement:o}),U=eo(Object.assign({},C,V)),j=w===on?U:_,O={top:v.top-j.top+k.top,bottom:j.bottom-v.bottom+k.bottom,left:v.left-j.left+k.left,right:j.right-v.right+k.right},S=e.modifiersData.offset;if(w===on&&S){var A=S[o];Object.keys(O).forEach(function(M){var J=[ze,Ve].indexOf(M)>=0?1:-1,Y=[je,Ve].indexOf(M)>=0?"y":"x";O[M]+=A[Y]*J})}return O}function Zw(e,t){t===void 0&&(t={});var n=t,r=n.placement,o=n.boundary,s=n.rootBoundary,i=n.padding,l=n.flipVariations,c=n.allowedAutoPlacements,d=c===void 0?bi:c,u=qt(r),f=u?l?Da:Da.filter(function(x){return qt(x)===u}):Mn,w=f.filter(function(x){return d.indexOf(x)>=0});w.length===0&&(w=f);var b=w.reduce(function(x,m){return x[m]=Nn(e,{placement:m,boundary:o,rootBoundary:s,padding:i})[He(m)],x},{});return Object.keys(b).sort(function(x,m){return b[x]-b[m]})}function Qw(e){if(He(e)===Io)return[];var t=Xn(e);return[za(e),t,za(t)]}function ef(e){var t=e.state,n=e.options,r=e.name;if(!t.modifiersData[r]._skip){for(var o=n.mainAxis,s=o===void 0?!0:o,i=n.altAxis,l=i===void 0?!0:i,c=n.fallbackPlacements,d=n.padding,u=n.boundary,f=n.rootBoundary,w=n.altBoundary,b=n.flipVariations,x=b===void 0?!0:b,m=n.allowedAutoPlacements,h=t.options.placement,k=He(h),I=k===h,C=c||(I||!x?[Xn(h)]:Qw(h)),E=[h].concat(C).reduce(function(B,X){return B.concat(He(X)===Io?Zw(t,{placement:X,boundary:u,rootBoundary:f,padding:d,flipVariations:x,allowedAutoPlacements:m}):X)},[]),v=t.rects.reference,_=t.rects.popper,V=new Map,U=!0,j=E[0],O=0;O=0,Y=J?"width":"height",F=Nn(t,{placement:S,boundary:u,rootBoundary:f,altBoundary:w,padding:d}),te=J?M?ze:Te:M?Ve:je;v[Y]>_[Y]&&(te=Xn(te));var se=Xn(te),oe=[];if(s&&oe.push(F[A]<=0),l&&oe.push(F[te]<=0,F[se]<=0),oe.every(function(B){return B})){j=S,U=!1;break}V.set(S,oe)}if(U)for(var y=x?3:1,T=function(X){var q=E.find(function(H){var G=V.get(H);if(G)return G.slice(0,X).every(function(K){return K})});if(q)return j=q,"break"},z=y;z>0;z--){var L=T(z);if(L==="break")break}t.placement!==j&&(t.modifiersData[r]._skip=!0,t.placement=j,t.reset=!0)}}const tf={name:"flip",enabled:!0,phase:"main",fn:ef,requiresIfExists:["offset"],data:{_skip:!1}};function Fa(e,t,n){return n===void 0&&(n={x:0,y:0}),{top:e.top-t.height-n.y,right:e.right-t.width+n.x,bottom:e.bottom-t.height+n.y,left:e.left-t.width-n.x}}function Ga(e){return[je,ze,Ve,Te].some(function(t){return e[t]>=0})}function nf(e){var t=e.state,n=e.name,r=t.rects.reference,o=t.rects.popper,s=t.modifiersData.preventOverflow,i=Nn(t,{elementContext:"reference"}),l=Nn(t,{altBoundary:!0}),c=Fa(i,r),d=Fa(l,o,s),u=Ga(c),f=Ga(d);t.modifiersData[n]={referenceClippingOffsets:c,popperEscapeOffsets:d,isReferenceHidden:u,hasPopperEscaped:f},t.attributes.popper=Object.assign({},t.attributes.popper,{"data-popper-reference-hidden":u,"data-popper-escaped":f})}const rf={name:"hide",enabled:!0,phase:"main",requiresIfExists:["preventOverflow"],fn:nf};function of(e,t,n){var r=He(e),o=[Te,je].indexOf(r)>=0?-1:1,s=typeof n=="function"?n(Object.assign({},t,{placement:e})):n,i=s[0],l=s[1];return i=i||0,l=(l||0)*o,[Te,ze].indexOf(r)>=0?{x:l,y:i}:{x:i,y:l}}function af(e){var t=e.state,n=e.options,r=e.name,o=n.offset,s=o===void 0?[0,0]:o,i=bi.reduce(function(u,f){return u[f]=of(f,t.rects,s),u},{}),l=i[t.placement],c=l.x,d=l.y;t.modifiersData.popperOffsets!=null&&(t.modifiersData.popperOffsets.x+=c,t.modifiersData.popperOffsets.y+=d),t.modifiersData[r]=i}const sf={name:"offset",enabled:!0,phase:"main",requires:["popperOffsets"],fn:af};function lf(e){var t=e.state,n=e.name;t.modifiersData[n]=Ei({reference:t.rects.reference,element:t.rects.popper,strategy:"absolute",placement:t.placement})}const cf={name:"popperOffsets",enabled:!0,phase:"read",fn:lf,data:{}};function df(e){return e==="x"?"y":"x"}function uf(e){var t=e.state,n=e.options,r=e.name,o=n.mainAxis,s=o===void 0?!0:o,i=n.altAxis,l=i===void 0?!1:i,c=n.boundary,d=n.rootBoundary,u=n.altBoundary,f=n.padding,w=n.tether,b=w===void 0?!0:w,x=n.tetherOffset,m=x===void 0?0:x,h=Nn(t,{boundary:c,rootBoundary:d,padding:f,altBoundary:u}),k=He(t.placement),I=qt(t.placement),C=!I,E=Ao(k),v=df(E),_=t.modifiersData.popperOffsets,V=t.rects.reference,U=t.rects.popper,j=typeof m=="function"?m(Object.assign({},t.rects,{placement:t.placement})):m,O=typeof j=="number"?{mainAxis:j,altAxis:j}:Object.assign({mainAxis:0,altAxis:0},j),S=t.modifiersData.offset?t.modifiersData.offset[t.placement]:null,A={x:0,y:0};if(_){if(s){var M,J=E==="y"?je:Te,Y=E==="y"?Ve:ze,F=E==="y"?"height":"width",te=_[E],se=te+h[J],oe=te-h[Y],y=b?-U[F]/2:0,T=I===Ft?V[F]:U[F],z=I===Ft?-U[F]:-V[F],L=t.elements.arrow,B=b&&L?$o(L):{width:0,height:0},X=t.modifiersData["arrow#persistent"]?t.modifiersData["arrow#persistent"].padding:yi(),q=X[J],H=X[Y],G=mn(0,V[F],B[F]),K=C?V[F]/2-y-G-q-O.mainAxis:T-G-q-O.mainAxis,Z=C?-V[F]/2+y+G+H+O.mainAxis:z+G+H+O.mainAxis,ue=t.elements.arrow&&$n(t.elements.arrow),P=ue?E==="y"?ue.clientTop||0:ue.clientLeft||0:0,xe=(M=S==null?void 0:S[E])!=null?M:0,D=te+K-xe-P,ve=te+Z-xe,Fe=mn(b?er(se,D):se,te,b?ht(oe,ve):oe);_[E]=Fe,A[E]=Fe-te}if(l){var lt,Se=E==="x"?je:Te,An=E==="x"?Ve:ze,Ge=_[v],Et=v==="y"?"height":"width",ct=Ge+h[Se],jt=Ge-h[An],Tt=[je,Te].indexOf(k)!==-1,Ct=(lt=S==null?void 0:S[v])!=null?lt:0,dt=Tt?ct:Ge-V[Et]-U[Et]-Ct+O.altAxis,Kt=Tt?Ge+V[Et]+U[Et]-Ct-O.altAxis:jt,Dn=b&&Tt?Mw(dt,Ge,Kt):mn(b?dt:ct,Ge,b?Kt:jt);_[v]=Dn,A[v]=Dn-Ge}t.modifiersData[r]=A}}const pf={name:"preventOverflow",enabled:!0,phase:"main",fn:uf,requiresIfExists:["offset"]};function wf(e){return{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}}function ff(e){return e===Me(e)||!Be(e)?Do(e):wf(e)}function mf(e){var t=e.getBoundingClientRect(),n=Gt(t.width)/e.offsetWidth||1,r=Gt(t.height)/e.offsetHeight||1;return n!==1||r!==1}function hf(e,t,n){n===void 0&&(n=!1);var r=Be(t),o=Be(t)&&mf(t),s=it(t),i=Ut(e,o,n),l={scrollLeft:0,scrollTop:0},c={x:0,y:0};return(r||!r&&!n)&&((We(t)!=="body"||Vo(s))&&(l=ff(t)),Be(t)?(c=Ut(t,!0),c.x+=t.clientLeft,c.y+=t.clientTop):s&&(c.x=Bo(s))),{x:i.left+l.scrollLeft-c.x,y:i.top+l.scrollTop-c.y,width:i.width,height:i.height}}function gf(e){var t=new Map,n=new Set,r=[];e.forEach(function(s){t.set(s.name,s)});function o(s){n.add(s.name);var i=[].concat(s.requires||[],s.requiresIfExists||[]);i.forEach(function(l){if(!n.has(l)){var c=t.get(l);c&&o(c)}}),r.push(s)}return e.forEach(function(s){n.has(s.name)||o(s)}),r}function bf(e){var t=gf(e);return Cw.reduce(function(n,r){return n.concat(t.filter(function(o){return o.phase===r}))},[])}function vf(e){var t;return function(){return t||(t=new Promise(function(n){Promise.resolve().then(function(){t=void 0,n(e())})})),t}}function xf(e){var t=e.reduce(function(n,r){var o=n[r.name];return n[r.name]=o?Object.assign({},o,r,{options:Object.assign({},o.options,r.options),data:Object.assign({},o.data,r.data)}):r,n},{});return Object.keys(t).map(function(n){return t[n]})}var Ua={placement:"bottom",modifiers:[],strategy:"absolute"};function qa(){for(var e=arguments.length,t=new Array(e),n=0;nNo({root:["root"]},iw(Sf)),Of={},_f=$.forwardRef(function(t,n){var r;const{anchorEl:o,children:s,direction:i,disablePortal:l,modifiers:c,open:d,placement:u,popperOptions:f,popperRef:w,slotProps:b={},slots:x={},TransitionProps:m}=t,h=ye(t,Ef),k=$.useRef(null),I=yt(k,n),C=$.useRef(null),E=yt(C,w),v=$.useRef(E);Lt(()=>{v.current=E},[E]),$.useImperativeHandle(w,()=>C.current,[]);const _=Tf(u,i),[V,U]=$.useState(_),[j,O]=$.useState(tr(o));$.useEffect(()=>{C.current&&C.current.forceUpdate()}),$.useEffect(()=>{o&&O(tr(o))},[o]),Lt(()=>{if(!j||!d)return;const Y=se=>{U(se.placement)};if(process.env.NODE_ENV!=="production"&&j&&Nr(j)&&j.nodeType===1){const se=j.getBoundingClientRect();process.env.NODE_ENV!=="test"&&se.top===0&&se.left===0&&se.right===0&&se.bottom===0&&console.warn(["MUI: The `anchorEl` prop provided to the component is invalid.","The anchor element should be part of the document layout.","Make sure the element is present in the document or that it's not display none."].join(` +`))}let F=[{name:"preventOverflow",options:{altBoundary:l}},{name:"flip",options:{altBoundary:l}},{name:"onUpdate",enabled:!0,phase:"afterWrite",fn:({state:se})=>{Y(se)}}];c!=null&&(F=F.concat(c)),f&&f.modifiers!=null&&(F=F.concat(f.modifiers));const te=kf(j,k.current,R({placement:_},f,{modifiers:F}));return v.current(te),()=>{te.destroy(),v.current(null)}},[j,l,c,d,f,_]);const S={placement:V};m!==null&&(S.TransitionProps=m);const A=Rf(),M=(r=x.root)!=null?r:"div",J=pw({elementType:M,externalSlotProps:b.root,externalForwardedProps:h,additionalProps:{role:"tooltip",ref:I},ownerState:t,className:A.root});return a.jsx(M,R({},J,{children:typeof s=="function"?s(S):s}))}),Ti=$.forwardRef(function(t,n){const{anchorEl:r,children:o,container:s,direction:i="ltr",disablePortal:l=!1,keepMounted:c=!1,modifiers:d,open:u,placement:f="bottom",popperOptions:w=Of,popperRef:b,style:x,transition:m=!1,slotProps:h={},slots:k={}}=t,I=ye(t,jf),[C,E]=$.useState(!0),v=()=>{E(!1)},_=()=>{E(!0)};if(!c&&!u&&(!m||C))return null;let V;if(s)V=s;else if(r){const O=tr(r);V=O&&Nr(O)?Kn(O).body:Kn(null).body}const U=!u&&c&&(!m||C)?"none":void 0,j=m?{in:u,onEnter:v,onExited:_}:void 0;return a.jsx(Qn,{disablePortal:l,container:V,children:a.jsx(_f,R({anchorEl:r,direction:i,disablePortal:l,modifiers:d,ref:n,open:m?!C:u,placement:f,popperOptions:w,popperRef:b,slotProps:h,slots:k},I,{style:R({position:"fixed",top:0,left:0,display:U},x),TransitionProps:j,children:o}))})});process.env.NODE_ENV!=="production"&&(Ti.propTypes={anchorEl:xo(p.oneOfType([vn,p.object,p.func]),e=>{if(e.open){const t=tr(e.anchorEl);if(t&&Nr(t)&&t.nodeType===1){const n=t.getBoundingClientRect();if(process.env.NODE_ENV!=="test"&&n.top===0&&n.left===0&&n.right===0&&n.bottom===0)return new Error(["MUI: The `anchorEl` prop provided to the component is invalid.","The anchor element should be part of the document layout.","Make sure the element is present in the document or that it's not display none."].join(` `))}else if(!t||typeof t.getBoundingClientRect!="function"||Cf(t)&&t.contextElement!=null&&t.contextElement.nodeType!==1)return new Error(["MUI: The `anchorEl` prop provided to the component is invalid.","It should be an HTML element instance or a virtualElement ","(https://popper.js.org/docs/v2/virtual-elements/)."].join(` -`))}return null}),children:p.oneOfType([p.node,p.func]),container:p.oneOfType([vn,p.func]),direction:p.oneOf(["ltr","rtl"]),disablePortal:p.bool,keepMounted:p.bool,modifiers:p.arrayOf(p.shape({data:p.object,effect:p.func,enabled:p.bool,fn:p.func,name:p.any,options:p.object,phase:p.oneOf(["afterMain","afterRead","afterWrite","beforeMain","beforeRead","beforeWrite","main","read","write"]),requires:p.arrayOf(p.string),requiresIfExists:p.arrayOf(p.string)})),open:p.bool.isRequired,placement:p.oneOf(["auto-end","auto-start","auto","bottom-end","bottom-start","bottom","left-end","left-start","left","right-end","right-start","right","top-end","top-start","top"]),popperOptions:p.shape({modifiers:p.array,onFirstUpdate:p.func,placement:p.oneOf(["auto-end","auto-start","auto","bottom-end","bottom-start","bottom","left-end","left-start","left","right-end","right-start","right","top-end","top-start","top"]),strategy:p.oneOf(["absolute","fixed"])}),popperRef:Qs,slotProps:p.shape({root:p.oneOfType([p.func,p.object])}),slots:p.shape({root:p.elementType}),transition:p.bool});function Ci(){const e=ui(Ro);return process.env.NODE_ENV!=="production"&&$.useDebugValue(e),e[Oo]||e}function to(e,t){return to=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,o){return r.__proto__=o,r},to(e,t)}function Pf(e,t){e.prototype=Object.create(t.prototype),e.prototype.constructor=e,to(e,t)}const Ha={disabled:!1};var If=process.env.NODE_ENV!=="production"?p.oneOfType([p.number,p.shape({enter:p.number,exit:p.number,appear:p.number}).isRequired]):null;process.env.NODE_ENV!=="production"&&p.oneOfType([p.string,p.shape({enter:p.string,exit:p.string,active:p.string}),p.shape({enter:p.string,enterDone:p.string,enterActive:p.string,exit:p.string,exitDone:p.string,exitActive:p.string})]);const Ri=g.createContext(null);var Mf=function(t){return t.scrollTop},un="unmounted",wt="exited",ft="entering",$t="entered",no="exiting",nt=function(e){Pf(t,e);function t(r,o){var s;s=e.call(this,r,o)||this;var i=o,l=i&&!i.isMounting?r.enter:r.appear,c;return s.appearStatus=null,r.in?l?(c=wt,s.appearStatus=ft):c=$t:r.unmountOnExit||r.mountOnEnter?c=un:c=wt,s.state={status:c},s.nextCallback=null,s}t.getDerivedStateFromProps=function(o,s){var i=o.in;return i&&s.status===un?{status:wt}:null};var n=t.prototype;return n.componentDidMount=function(){this.updateStatus(!0,this.appearStatus)},n.componentDidUpdate=function(o){var s=null;if(o!==this.props){var i=this.state.status;this.props.in?i!==ft&&i!==$t&&(s=ft):(i===ft||i===$t)&&(s=no)}this.updateStatus(!1,s)},n.componentWillUnmount=function(){this.cancelNextCallback()},n.getTimeouts=function(){var o=this.props.timeout,s,i,l;return s=i=l=o,o!=null&&typeof o!="number"&&(s=o.exit,i=o.enter,l=o.appear!==void 0?o.appear:i),{exit:s,enter:i,appear:l}},n.updateStatus=function(o,s){if(o===void 0&&(o=!1),s!==null)if(this.cancelNextCallback(),s===ft){if(this.props.unmountOnExit||this.props.mountOnEnter){var i=this.props.nodeRef?this.props.nodeRef.current:sn.findDOMNode(this);i&&Mf(i)}this.performEnter(o)}else this.performExit();else this.props.unmountOnExit&&this.state.status===wt&&this.setState({status:un})},n.performEnter=function(o){var s=this,i=this.props.enter,l=this.context?this.context.isMounting:o,c=this.props.nodeRef?[l]:[sn.findDOMNode(this),l],d=c[0],u=c[1],f=this.getTimeouts(),w=l?f.appear:f.enter;if(!o&&!i||Ha.disabled){this.safeSetState({status:$t},function(){s.props.onEntered(d)});return}this.props.onEnter(d,u),this.safeSetState({status:ft},function(){s.props.onEntering(d,u),s.onTransitionEnd(w,function(){s.safeSetState({status:$t},function(){s.props.onEntered(d,u)})})})},n.performExit=function(){var o=this,s=this.props.exit,i=this.getTimeouts(),l=this.props.nodeRef?void 0:sn.findDOMNode(this);if(!s||Ha.disabled){this.safeSetState({status:wt},function(){o.props.onExited(l)});return}this.props.onExit(l),this.safeSetState({status:no},function(){o.props.onExiting(l),o.onTransitionEnd(i.exit,function(){o.safeSetState({status:wt},function(){o.props.onExited(l)})})})},n.cancelNextCallback=function(){this.nextCallback!==null&&(this.nextCallback.cancel(),this.nextCallback=null)},n.safeSetState=function(o,s){s=this.setNextCallback(s),this.setState(o,s)},n.setNextCallback=function(o){var s=this,i=!0;return this.nextCallback=function(l){i&&(i=!1,s.nextCallback=null,o(l))},this.nextCallback.cancel=function(){i=!1},this.nextCallback},n.onTransitionEnd=function(o,s){this.setNextCallback(s);var i=this.props.nodeRef?this.props.nodeRef.current:sn.findDOMNode(this),l=o==null&&!this.props.addEndListener;if(!i||l){setTimeout(this.nextCallback,0);return}if(this.props.addEndListener){var c=this.props.nodeRef?[this.nextCallback]:[i,this.nextCallback],d=c[0],u=c[1];this.props.addEndListener(d,u)}o!=null&&setTimeout(this.nextCallback,o)},n.render=function(){var o=this.state.status;if(o===un)return null;var s=this.props,i=s.children;s.in,s.mountOnEnter,s.unmountOnExit,s.appear,s.enter,s.exit,s.timeout,s.addEndListener,s.onEnter,s.onEntering,s.onEntered,s.onExit,s.onExiting,s.onExited,s.nodeRef;var l=ye(s,["children","in","mountOnEnter","unmountOnExit","appear","enter","exit","timeout","addEndListener","onEnter","onEntering","onEntered","onExit","onExiting","onExited","nodeRef"]);return g.createElement(Ri.Provider,{value:null},typeof i=="function"?i(o,l):g.cloneElement(g.Children.only(i),l))},t}(g.Component);nt.contextType=Ri;nt.propTypes=process.env.NODE_ENV!=="production"?{nodeRef:p.shape({current:typeof Element>"u"?p.any:function(e,t,n,r,o,s){var i=e[t];return p.instanceOf(i&&"ownerDocument"in i?i.ownerDocument.defaultView.Element:Element)(e,t,n,r,o,s)}}),children:p.oneOfType([p.func.isRequired,p.element.isRequired]).isRequired,in:p.bool,mountOnEnter:p.bool,unmountOnExit:p.bool,appear:p.bool,enter:p.bool,exit:p.bool,timeout:function(t){var n=If;t.addEndListener||(n=n.isRequired);for(var r=arguments.length,o=new Array(r>1?r-1:0),s=1;se.scrollTop;function Xa(e,t){var n,r;const{timeout:o,easing:s,style:i={}}=e;return{duration:(n=i.transitionDuration)!=null?n:typeof o=="number"?o:o[t.mode]||0,easing:(r=i.transitionTimingFunction)!=null?r:typeof s=="object"?s[t.mode]:s,delay:i.transitionDelay}}const Df=["addEndListener","appear","children","easing","in","onEnter","onEntered","onEntering","onExit","onExited","onExiting","style","timeout","TransitionComponent"];function ro(e){return`scale(${e}, ${e**2})`}const Bf={entering:{opacity:1,transform:ro(1)},entered:{opacity:1,transform:"none"}},zr=typeof navigator<"u"&&/^((?!chrome|android).)*(safari|mobile)/i.test(navigator.userAgent)&&/(os |version\/)15(.|_)4/i.test(navigator.userAgent),zo=$.forwardRef(function(t,n){const{addEndListener:r,appear:o=!0,children:s,easing:i,in:l,onEnter:c,onEntered:d,onEntering:u,onExit:f,onExited:w,onExiting:b,style:x,timeout:m="auto",TransitionComponent:h=$f}=t,E=ye(t,Df),I=cn(),C=$.useRef(),S=Ci(),v=$.useRef(null),_=yt(v,s.ref,n),V=Y=>F=>{if(Y){const te=v.current;F===void 0?Y(te):Y(te,F)}},U=V(u),j=V((Y,F)=>{Af(Y);const{duration:te,delay:se,easing:oe}=Xa({style:x,timeout:m,easing:i},{mode:"enter"});let y;m==="auto"?(y=S.transitions.getAutoHeightDuration(Y.clientHeight),C.current=y):y=te,Y.style.transition=[S.transitions.create("opacity",{duration:y,delay:se}),S.transitions.create("transform",{duration:zr?y:y*.666,delay:se,easing:oe})].join(","),c&&c(Y,F)}),O=V(d),k=V(b),A=V(Y=>{const{duration:F,delay:te,easing:se}=Xa({style:x,timeout:m,easing:i},{mode:"exit"});let oe;m==="auto"?(oe=S.transitions.getAutoHeightDuration(Y.clientHeight),C.current=oe):oe=F,Y.style.transition=[S.transitions.create("opacity",{duration:oe,delay:te}),S.transitions.create("transform",{duration:zr?oe:oe*.666,delay:zr?te:te||oe*.333,easing:se})].join(","),Y.style.opacity=0,Y.style.transform=ro(.75),f&&f(Y)}),M=V(w),J=Y=>{m==="auto"&&I.start(C.current||0,Y),r&&r(v.current,Y)};return a.jsx(h,R({appear:o,in:l,nodeRef:v,onEnter:j,onEntered:O,onEntering:U,onExit:A,onExited:M,onExiting:k,addEndListener:J,timeout:m==="auto"?null:m},E,{children:(Y,F)=>$.cloneElement(s,R({style:R({opacity:0,transform:ro(.75),visibility:Y==="exited"&&!l?"hidden":void 0},Bf[Y],x,s.props.style),ref:_},F))}))});process.env.NODE_ENV!=="production"&&(zo.propTypes={addEndListener:p.func,appear:p.bool,children:Js.isRequired,easing:p.oneOfType([p.shape({enter:p.string,exit:p.string}),p.string]),in:p.bool,onEnter:p.func,onEntered:p.func,onEntering:p.func,onExit:p.func,onExited:p.func,onExiting:p.func,style:p.object,timeout:p.oneOfType([p.oneOf(["auto"]),p.number,p.shape({appear:p.number,enter:p.number,exit:p.number})])});zo.muiSupportAuto=!0;const Ya=zo,Vf=["anchorEl","component","components","componentsProps","container","disablePortal","keepMounted","modifiers","open","placement","popperOptions","popperRef","transition","slots","slotProps"],zf=In(Ti,{name:"MuiPopper",slot:"Root",overridesResolver:(e,t)=>t.root})({}),Oi=$.forwardRef(function(t,n){var r;const o=di(),s=_o({props:t,name:"MuiPopper"}),{anchorEl:i,component:l,components:c,componentsProps:d,container:u,disablePortal:f,keepMounted:w,modifiers:b,open:x,placement:m,popperOptions:h,popperRef:E,transition:I,slots:C,slotProps:S}=s,v=ye(s,Vf),_=(r=C==null?void 0:C.root)!=null?r:c==null?void 0:c.Root,V=R({anchorEl:i,container:u,disablePortal:f,keepMounted:w,modifiers:b,open:x,placement:m,popperOptions:h,popperRef:E,transition:I},v);return a.jsx(zf,R({as:l,direction:o==null?void 0:o.direction,slots:{root:_},slotProps:S??d},V,{ref:n}))});process.env.NODE_ENV!=="production"&&(Oi.propTypes={anchorEl:p.oneOfType([vn,p.object,p.func]),children:p.oneOfType([p.node,p.func]),component:p.elementType,components:p.shape({Root:p.elementType}),componentsProps:p.shape({root:p.oneOfType([p.func,p.object])}),container:p.oneOfType([vn,p.func]),disablePortal:p.bool,keepMounted:p.bool,modifiers:p.arrayOf(p.shape({data:p.object,effect:p.func,enabled:p.bool,fn:p.func,name:p.any,options:p.object,phase:p.oneOf(["afterMain","afterRead","afterWrite","beforeMain","beforeRead","beforeWrite","main","read","write"]),requires:p.arrayOf(p.string),requiresIfExists:p.arrayOf(p.string)})),open:p.bool.isRequired,placement:p.oneOf(["auto-end","auto-start","auto","bottom-end","bottom-start","bottom","left-end","left-start","left","right-end","right-start","right","top-end","top-start","top"]),popperOptions:p.shape({modifiers:p.array,onFirstUpdate:p.func,placement:p.oneOf(["auto-end","auto-start","auto","bottom-end","bottom-start","bottom","left-end","left-start","left","right-end","right-start","right","top-end","top-start","top"]),strategy:p.oneOf(["absolute","fixed"])}),popperRef:Qs,slotProps:p.shape({root:p.oneOfType([p.func,p.object])}),slots:p.shape({root:p.elementType}),sx:p.oneOfType([p.arrayOf(p.oneOfType([p.func,p.object,p.bool])),p.func,p.object]),transition:p.bool});const _i=Oi;function Lf(e){return ur("MuiTooltip",e)}const Ff=si("MuiTooltip",["popper","popperInteractive","popperArrow","popperClose","tooltip","tooltipArrow","touch","tooltipPlacementLeft","tooltipPlacementRight","tooltipPlacementTop","tooltipPlacementBottom","arrow"]),at=Ff,Gf=["arrow","children","classes","components","componentsProps","describeChild","disableFocusListener","disableHoverListener","disableInteractive","disableTouchListener","enterDelay","enterNextDelay","enterTouchDelay","followCursor","id","leaveDelay","leaveTouchDelay","onClose","onOpen","open","placement","PopperComponent","PopperProps","slotProps","slots","title","TransitionComponent","TransitionProps"];function Uf(e){return Math.round(e*1e5)/1e5}const qf=e=>{const{classes:t,disableInteractive:n,arrow:r,touch:o,placement:s}=e,i={popper:["popper",!n&&"popperInteractive",r&&"popperArrow"],tooltip:["tooltip",r&&"tooltipArrow",o&&"touch",`tooltipPlacement${Ye(s.split("-")[0])}`],arrow:["arrow"]};return No(i,Lf,t)},Hf=In(_i,{name:"MuiTooltip",slot:"Popper",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.popper,!n.disableInteractive&&t.popperInteractive,n.arrow&&t.popperArrow,!n.open&&t.popperClose]}})(({theme:e,ownerState:t,open:n})=>R({zIndex:(e.vars||e).zIndex.tooltip,pointerEvents:"none"},!t.disableInteractive&&{pointerEvents:"auto"},!n&&{pointerEvents:"none"},t.arrow&&{[`&[data-popper-placement*="bottom"] .${at.arrow}`]:{top:0,marginTop:"-0.71em","&::before":{transformOrigin:"0 100%"}},[`&[data-popper-placement*="top"] .${at.arrow}`]:{bottom:0,marginBottom:"-0.71em","&::before":{transformOrigin:"100% 0"}},[`&[data-popper-placement*="right"] .${at.arrow}`]:R({},t.isRtl?{right:0,marginRight:"-0.71em"}:{left:0,marginLeft:"-0.71em"},{height:"1em",width:"0.71em","&::before":{transformOrigin:"100% 100%"}}),[`&[data-popper-placement*="left"] .${at.arrow}`]:R({},t.isRtl?{left:0,marginLeft:"-0.71em"}:{right:0,marginRight:"-0.71em"},{height:"1em",width:"0.71em","&::before":{transformOrigin:"0 0"}})})),Xf=In("div",{name:"MuiTooltip",slot:"Tooltip",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.tooltip,n.touch&&t.touch,n.arrow&&t.tooltipArrow,t[`tooltipPlacement${Ye(n.placement.split("-")[0])}`]]}})(({theme:e,ownerState:t})=>R({backgroundColor:e.vars?e.vars.palette.Tooltip.bg:pi(e.palette.grey[700],.92),borderRadius:(e.vars||e).shape.borderRadius,color:(e.vars||e).palette.common.white,fontFamily:e.typography.fontFamily,padding:"4px 8px",fontSize:e.typography.pxToRem(11),maxWidth:300,margin:2,wordWrap:"break-word",fontWeight:e.typography.fontWeightMedium},t.arrow&&{position:"relative",margin:0},t.touch&&{padding:"8px 16px",fontSize:e.typography.pxToRem(14),lineHeight:`${Uf(16/14)}em`,fontWeight:e.typography.fontWeightRegular},{[`.${at.popper}[data-popper-placement*="left"] &`]:R({transformOrigin:"right center"},t.isRtl?R({marginLeft:"14px"},t.touch&&{marginLeft:"24px"}):R({marginRight:"14px"},t.touch&&{marginRight:"24px"})),[`.${at.popper}[data-popper-placement*="right"] &`]:R({transformOrigin:"left center"},t.isRtl?R({marginRight:"14px"},t.touch&&{marginRight:"24px"}):R({marginLeft:"14px"},t.touch&&{marginLeft:"24px"})),[`.${at.popper}[data-popper-placement*="top"] &`]:R({transformOrigin:"center bottom",marginBottom:"14px"},t.touch&&{marginBottom:"24px"}),[`.${at.popper}[data-popper-placement*="bottom"] &`]:R({transformOrigin:"center top",marginTop:"14px"},t.touch&&{marginTop:"24px"})})),Yf=In("span",{name:"MuiTooltip",slot:"Arrow",overridesResolver:(e,t)=>t.arrow})(({theme:e})=>({overflow:"hidden",position:"absolute",width:"1em",height:"0.71em",boxSizing:"border-box",color:e.vars?e.vars.palette.Tooltip.bg:pi(e.palette.grey[700],.9),"&::before":{content:'""',margin:"auto",display:"block",width:"100%",height:"100%",backgroundColor:"currentColor",transform:"rotate(45deg)"}}));let Gn=!1;const Wa=new On;let an={x:0,y:0};function Un(e,t){return n=>{t&&t(n),e(n)}}const Pi=$.forwardRef(function(t,n){var r,o,s,i,l,c,d,u,f,w,b,x,m,h,E,I,C,S,v;const _=_o({props:t,name:"MuiTooltip"}),{arrow:V=!1,children:U,components:j={},componentsProps:O={},describeChild:k=!1,disableFocusListener:A=!1,disableHoverListener:M=!1,disableInteractive:J=!1,disableTouchListener:Y=!1,enterDelay:F=100,enterNextDelay:te=0,enterTouchDelay:se=700,followCursor:oe=!1,id:y,leaveDelay:T=0,leaveTouchDelay:z=1500,onClose:L,onOpen:B,open:X,placement:q="bottom",PopperComponent:H,PopperProps:G={},slotProps:K={},slots:Z={},title:ue,TransitionComponent:P=Ya,TransitionProps:xe}=_,D=ye(_,Gf),ve=$.isValidElement(U)?U:a.jsx("span",{children:U}),Fe=Ci(),lt=Fe.direction==="rtl",[Se,An]=$.useState(),[Ge,Et]=$.useState(null),ct=$.useRef(!1),jt=J||oe,Tt=cn(),Ct=cn(),dt=cn(),Kt=cn(),[Dn,Fo]=ti({controlled:X,default:!1,name:"Tooltip",state:"open"});let Ke=Dn;if(process.env.NODE_ENV!=="production"){const{current:Q}=$.useRef(X!==void 0);$.useEffect(()=>{Se&&Se.disabled&&!Q&&ue!==""&&Se.tagName.toLowerCase()==="button"&&console.error(["MUI: You are providing a disabled `button` child to the Tooltip component.","A disabled element does not fire events.","Tooltip needs to listen to the child element's events to display the title.","","Add a simple wrapper element, such as a `span`."].join(` -`))},[ue,Se,Q])}const kr=ei(y),Jt=$.useRef(),Bn=Jr(()=>{Jt.current!==void 0&&(document.body.style.WebkitUserSelect=Jt.current,Jt.current=void 0),Kt.clear()});$.useEffect(()=>Bn,[Bn]);const Go=Q=>{Wa.clear(),Gn=!0,Fo(!0),B&&!Ke&&B(Q)},Vn=Jr(Q=>{Wa.start(800+T,()=>{Gn=!1}),Fo(!1),L&&Ke&&L(Q),Tt.start(Fe.transitions.duration.shortest,()=>{ct.current=!1})}),Sr=Q=>{ct.current&&Q.type!=="touchstart"||(Se&&Se.removeAttribute("title"),Ct.clear(),dt.clear(),F||Gn&&te?Ct.start(Gn?te:F,()=>{Go(Q)}):Go(Q))},Uo=Q=>{Ct.clear(),dt.start(T,()=>{Vn(Q)})},{isFocusVisibleRef:qo,onBlur:el,onFocus:tl,ref:nl}=ni(),[,Ho]=$.useState(!1),Xo=Q=>{el(Q),qo.current===!1&&(Ho(!1),Uo(Q))},Yo=Q=>{Se||An(Q.currentTarget),tl(Q),qo.current===!0&&(Ho(!0),Sr(Q))},Wo=Q=>{ct.current=!0;const Oe=ve.props;Oe.onTouchStart&&Oe.onTouchStart(Q)},Ko=Sr,Jo=Uo,rl=Q=>{Wo(Q),dt.clear(),Tt.clear(),Bn(),Jt.current=document.body.style.WebkitUserSelect,document.body.style.WebkitUserSelect="none",Kt.start(se,()=>{document.body.style.WebkitUserSelect=Jt.current,Sr(Q)})},ol=Q=>{ve.props.onTouchEnd&&ve.props.onTouchEnd(Q),Bn(),dt.start(z,()=>{Vn(Q)})};$.useEffect(()=>{if(!Ke)return;function Q(Oe){(Oe.key==="Escape"||Oe.key==="Esc")&&Vn(Oe)}return document.addEventListener("keydown",Q),()=>{document.removeEventListener("keydown",Q)}},[Vn,Ke]);const al=yt(ve.ref,nl,An,n);!ue&&ue!==0&&(Ke=!1);const Er=$.useRef(),sl=Q=>{const Oe=ve.props;Oe.onMouseMove&&Oe.onMouseMove(Q),an={x:Q.clientX,y:Q.clientY},Er.current&&Er.current.update()},Zt={},jr=typeof ue=="string";k?(Zt.title=!Ke&&jr&&!M?ue:null,Zt["aria-describedby"]=Ke?kr:null):(Zt["aria-label"]=jr?ue:null,Zt["aria-labelledby"]=Ke&&!jr?kr:null);const $e=R({},Zt,D,ve.props,{className:ot(D.className,ve.props.className),onTouchStart:Wo,ref:al},oe?{onMouseMove:sl}:{});process.env.NODE_ENV!=="production"&&($e["data-mui-internal-clone-element"]=!0,$.useEffect(()=>{Se&&!Se.getAttribute("data-mui-internal-clone-element")&&console.error(["MUI: The `children` component of the Tooltip is not forwarding its props correctly.","Please make sure that props are spread on the same element that the ref is applied to."].join(` +`))}return null}),children:p.oneOfType([p.node,p.func]),container:p.oneOfType([vn,p.func]),direction:p.oneOf(["ltr","rtl"]),disablePortal:p.bool,keepMounted:p.bool,modifiers:p.arrayOf(p.shape({data:p.object,effect:p.func,enabled:p.bool,fn:p.func,name:p.any,options:p.object,phase:p.oneOf(["afterMain","afterRead","afterWrite","beforeMain","beforeRead","beforeWrite","main","read","write"]),requires:p.arrayOf(p.string),requiresIfExists:p.arrayOf(p.string)})),open:p.bool.isRequired,placement:p.oneOf(["auto-end","auto-start","auto","bottom-end","bottom-start","bottom","left-end","left-start","left","right-end","right-start","right","top-end","top-start","top"]),popperOptions:p.shape({modifiers:p.array,onFirstUpdate:p.func,placement:p.oneOf(["auto-end","auto-start","auto","bottom-end","bottom-start","bottom","left-end","left-start","left","right-end","right-start","right","top-end","top-start","top"]),strategy:p.oneOf(["absolute","fixed"])}),popperRef:Qs,slotProps:p.shape({root:p.oneOfType([p.func,p.object])}),slots:p.shape({root:p.elementType}),transition:p.bool});function Ci(){const e=ui(Ro);return process.env.NODE_ENV!=="production"&&$.useDebugValue(e),e[Oo]||e}function to(e,t){return to=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,o){return r.__proto__=o,r},to(e,t)}function Pf(e,t){e.prototype=Object.create(t.prototype),e.prototype.constructor=e,to(e,t)}const Ha={disabled:!1};var If=process.env.NODE_ENV!=="production"?p.oneOfType([p.number,p.shape({enter:p.number,exit:p.number,appear:p.number}).isRequired]):null;process.env.NODE_ENV!=="production"&&p.oneOfType([p.string,p.shape({enter:p.string,exit:p.string,active:p.string}),p.shape({enter:p.string,enterDone:p.string,enterActive:p.string,exit:p.string,exitDone:p.string,exitActive:p.string})]);const Ri=g.createContext(null);var Mf=function(t){return t.scrollTop},un="unmounted",wt="exited",ft="entering",$t="entered",no="exiting",nt=function(e){Pf(t,e);function t(r,o){var s;s=e.call(this,r,o)||this;var i=o,l=i&&!i.isMounting?r.enter:r.appear,c;return s.appearStatus=null,r.in?l?(c=wt,s.appearStatus=ft):c=$t:r.unmountOnExit||r.mountOnEnter?c=un:c=wt,s.state={status:c},s.nextCallback=null,s}t.getDerivedStateFromProps=function(o,s){var i=o.in;return i&&s.status===un?{status:wt}:null};var n=t.prototype;return n.componentDidMount=function(){this.updateStatus(!0,this.appearStatus)},n.componentDidUpdate=function(o){var s=null;if(o!==this.props){var i=this.state.status;this.props.in?i!==ft&&i!==$t&&(s=ft):(i===ft||i===$t)&&(s=no)}this.updateStatus(!1,s)},n.componentWillUnmount=function(){this.cancelNextCallback()},n.getTimeouts=function(){var o=this.props.timeout,s,i,l;return s=i=l=o,o!=null&&typeof o!="number"&&(s=o.exit,i=o.enter,l=o.appear!==void 0?o.appear:i),{exit:s,enter:i,appear:l}},n.updateStatus=function(o,s){if(o===void 0&&(o=!1),s!==null)if(this.cancelNextCallback(),s===ft){if(this.props.unmountOnExit||this.props.mountOnEnter){var i=this.props.nodeRef?this.props.nodeRef.current:sn.findDOMNode(this);i&&Mf(i)}this.performEnter(o)}else this.performExit();else this.props.unmountOnExit&&this.state.status===wt&&this.setState({status:un})},n.performEnter=function(o){var s=this,i=this.props.enter,l=this.context?this.context.isMounting:o,c=this.props.nodeRef?[l]:[sn.findDOMNode(this),l],d=c[0],u=c[1],f=this.getTimeouts(),w=l?f.appear:f.enter;if(!o&&!i||Ha.disabled){this.safeSetState({status:$t},function(){s.props.onEntered(d)});return}this.props.onEnter(d,u),this.safeSetState({status:ft},function(){s.props.onEntering(d,u),s.onTransitionEnd(w,function(){s.safeSetState({status:$t},function(){s.props.onEntered(d,u)})})})},n.performExit=function(){var o=this,s=this.props.exit,i=this.getTimeouts(),l=this.props.nodeRef?void 0:sn.findDOMNode(this);if(!s||Ha.disabled){this.safeSetState({status:wt},function(){o.props.onExited(l)});return}this.props.onExit(l),this.safeSetState({status:no},function(){o.props.onExiting(l),o.onTransitionEnd(i.exit,function(){o.safeSetState({status:wt},function(){o.props.onExited(l)})})})},n.cancelNextCallback=function(){this.nextCallback!==null&&(this.nextCallback.cancel(),this.nextCallback=null)},n.safeSetState=function(o,s){s=this.setNextCallback(s),this.setState(o,s)},n.setNextCallback=function(o){var s=this,i=!0;return this.nextCallback=function(l){i&&(i=!1,s.nextCallback=null,o(l))},this.nextCallback.cancel=function(){i=!1},this.nextCallback},n.onTransitionEnd=function(o,s){this.setNextCallback(s);var i=this.props.nodeRef?this.props.nodeRef.current:sn.findDOMNode(this),l=o==null&&!this.props.addEndListener;if(!i||l){setTimeout(this.nextCallback,0);return}if(this.props.addEndListener){var c=this.props.nodeRef?[this.nextCallback]:[i,this.nextCallback],d=c[0],u=c[1];this.props.addEndListener(d,u)}o!=null&&setTimeout(this.nextCallback,o)},n.render=function(){var o=this.state.status;if(o===un)return null;var s=this.props,i=s.children;s.in,s.mountOnEnter,s.unmountOnExit,s.appear,s.enter,s.exit,s.timeout,s.addEndListener,s.onEnter,s.onEntering,s.onEntered,s.onExit,s.onExiting,s.onExited,s.nodeRef;var l=ye(s,["children","in","mountOnEnter","unmountOnExit","appear","enter","exit","timeout","addEndListener","onEnter","onEntering","onEntered","onExit","onExiting","onExited","nodeRef"]);return g.createElement(Ri.Provider,{value:null},typeof i=="function"?i(o,l):g.cloneElement(g.Children.only(i),l))},t}(g.Component);nt.contextType=Ri;nt.propTypes=process.env.NODE_ENV!=="production"?{nodeRef:p.shape({current:typeof Element>"u"?p.any:function(e,t,n,r,o,s){var i=e[t];return p.instanceOf(i&&"ownerDocument"in i?i.ownerDocument.defaultView.Element:Element)(e,t,n,r,o,s)}}),children:p.oneOfType([p.func.isRequired,p.element.isRequired]).isRequired,in:p.bool,mountOnEnter:p.bool,unmountOnExit:p.bool,appear:p.bool,enter:p.bool,exit:p.bool,timeout:function(t){var n=If;t.addEndListener||(n=n.isRequired);for(var r=arguments.length,o=new Array(r>1?r-1:0),s=1;se.scrollTop;function Xa(e,t){var n,r;const{timeout:o,easing:s,style:i={}}=e;return{duration:(n=i.transitionDuration)!=null?n:typeof o=="number"?o:o[t.mode]||0,easing:(r=i.transitionTimingFunction)!=null?r:typeof s=="object"?s[t.mode]:s,delay:i.transitionDelay}}const Df=["addEndListener","appear","children","easing","in","onEnter","onEntered","onEntering","onExit","onExited","onExiting","style","timeout","TransitionComponent"];function ro(e){return`scale(${e}, ${e**2})`}const Bf={entering:{opacity:1,transform:ro(1)},entered:{opacity:1,transform:"none"}},zr=typeof navigator<"u"&&/^((?!chrome|android).)*(safari|mobile)/i.test(navigator.userAgent)&&/(os |version\/)15(.|_)4/i.test(navigator.userAgent),zo=$.forwardRef(function(t,n){const{addEndListener:r,appear:o=!0,children:s,easing:i,in:l,onEnter:c,onEntered:d,onEntering:u,onExit:f,onExited:w,onExiting:b,style:x,timeout:m="auto",TransitionComponent:h=$f}=t,k=ye(t,Df),I=cn(),C=$.useRef(),E=Ci(),v=$.useRef(null),_=yt(v,s.ref,n),V=Y=>F=>{if(Y){const te=v.current;F===void 0?Y(te):Y(te,F)}},U=V(u),j=V((Y,F)=>{Af(Y);const{duration:te,delay:se,easing:oe}=Xa({style:x,timeout:m,easing:i},{mode:"enter"});let y;m==="auto"?(y=E.transitions.getAutoHeightDuration(Y.clientHeight),C.current=y):y=te,Y.style.transition=[E.transitions.create("opacity",{duration:y,delay:se}),E.transitions.create("transform",{duration:zr?y:y*.666,delay:se,easing:oe})].join(","),c&&c(Y,F)}),O=V(d),S=V(b),A=V(Y=>{const{duration:F,delay:te,easing:se}=Xa({style:x,timeout:m,easing:i},{mode:"exit"});let oe;m==="auto"?(oe=E.transitions.getAutoHeightDuration(Y.clientHeight),C.current=oe):oe=F,Y.style.transition=[E.transitions.create("opacity",{duration:oe,delay:te}),E.transitions.create("transform",{duration:zr?oe:oe*.666,delay:zr?te:te||oe*.333,easing:se})].join(","),Y.style.opacity=0,Y.style.transform=ro(.75),f&&f(Y)}),M=V(w),J=Y=>{m==="auto"&&I.start(C.current||0,Y),r&&r(v.current,Y)};return a.jsx(h,R({appear:o,in:l,nodeRef:v,onEnter:j,onEntered:O,onEntering:U,onExit:A,onExited:M,onExiting:S,addEndListener:J,timeout:m==="auto"?null:m},k,{children:(Y,F)=>$.cloneElement(s,R({style:R({opacity:0,transform:ro(.75),visibility:Y==="exited"&&!l?"hidden":void 0},Bf[Y],x,s.props.style),ref:_},F))}))});process.env.NODE_ENV!=="production"&&(zo.propTypes={addEndListener:p.func,appear:p.bool,children:Js.isRequired,easing:p.oneOfType([p.shape({enter:p.string,exit:p.string}),p.string]),in:p.bool,onEnter:p.func,onEntered:p.func,onEntering:p.func,onExit:p.func,onExited:p.func,onExiting:p.func,style:p.object,timeout:p.oneOfType([p.oneOf(["auto"]),p.number,p.shape({appear:p.number,enter:p.number,exit:p.number})])});zo.muiSupportAuto=!0;const Ya=zo,Vf=["anchorEl","component","components","componentsProps","container","disablePortal","keepMounted","modifiers","open","placement","popperOptions","popperRef","transition","slots","slotProps"],zf=In(Ti,{name:"MuiPopper",slot:"Root",overridesResolver:(e,t)=>t.root})({}),Oi=$.forwardRef(function(t,n){var r;const o=di(),s=_o({props:t,name:"MuiPopper"}),{anchorEl:i,component:l,components:c,componentsProps:d,container:u,disablePortal:f,keepMounted:w,modifiers:b,open:x,placement:m,popperOptions:h,popperRef:k,transition:I,slots:C,slotProps:E}=s,v=ye(s,Vf),_=(r=C==null?void 0:C.root)!=null?r:c==null?void 0:c.Root,V=R({anchorEl:i,container:u,disablePortal:f,keepMounted:w,modifiers:b,open:x,placement:m,popperOptions:h,popperRef:k,transition:I},v);return a.jsx(zf,R({as:l,direction:o==null?void 0:o.direction,slots:{root:_},slotProps:E??d},V,{ref:n}))});process.env.NODE_ENV!=="production"&&(Oi.propTypes={anchorEl:p.oneOfType([vn,p.object,p.func]),children:p.oneOfType([p.node,p.func]),component:p.elementType,components:p.shape({Root:p.elementType}),componentsProps:p.shape({root:p.oneOfType([p.func,p.object])}),container:p.oneOfType([vn,p.func]),disablePortal:p.bool,keepMounted:p.bool,modifiers:p.arrayOf(p.shape({data:p.object,effect:p.func,enabled:p.bool,fn:p.func,name:p.any,options:p.object,phase:p.oneOf(["afterMain","afterRead","afterWrite","beforeMain","beforeRead","beforeWrite","main","read","write"]),requires:p.arrayOf(p.string),requiresIfExists:p.arrayOf(p.string)})),open:p.bool.isRequired,placement:p.oneOf(["auto-end","auto-start","auto","bottom-end","bottom-start","bottom","left-end","left-start","left","right-end","right-start","right","top-end","top-start","top"]),popperOptions:p.shape({modifiers:p.array,onFirstUpdate:p.func,placement:p.oneOf(["auto-end","auto-start","auto","bottom-end","bottom-start","bottom","left-end","left-start","left","right-end","right-start","right","top-end","top-start","top"]),strategy:p.oneOf(["absolute","fixed"])}),popperRef:Qs,slotProps:p.shape({root:p.oneOfType([p.func,p.object])}),slots:p.shape({root:p.elementType}),sx:p.oneOfType([p.arrayOf(p.oneOfType([p.func,p.object,p.bool])),p.func,p.object]),transition:p.bool});const _i=Oi;function Lf(e){return ur("MuiTooltip",e)}const Ff=si("MuiTooltip",["popper","popperInteractive","popperArrow","popperClose","tooltip","tooltipArrow","touch","tooltipPlacementLeft","tooltipPlacementRight","tooltipPlacementTop","tooltipPlacementBottom","arrow"]),at=Ff,Gf=["arrow","children","classes","components","componentsProps","describeChild","disableFocusListener","disableHoverListener","disableInteractive","disableTouchListener","enterDelay","enterNextDelay","enterTouchDelay","followCursor","id","leaveDelay","leaveTouchDelay","onClose","onOpen","open","placement","PopperComponent","PopperProps","slotProps","slots","title","TransitionComponent","TransitionProps"];function Uf(e){return Math.round(e*1e5)/1e5}const qf=e=>{const{classes:t,disableInteractive:n,arrow:r,touch:o,placement:s}=e,i={popper:["popper",!n&&"popperInteractive",r&&"popperArrow"],tooltip:["tooltip",r&&"tooltipArrow",o&&"touch",`tooltipPlacement${Ye(s.split("-")[0])}`],arrow:["arrow"]};return No(i,Lf,t)},Hf=In(_i,{name:"MuiTooltip",slot:"Popper",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.popper,!n.disableInteractive&&t.popperInteractive,n.arrow&&t.popperArrow,!n.open&&t.popperClose]}})(({theme:e,ownerState:t,open:n})=>R({zIndex:(e.vars||e).zIndex.tooltip,pointerEvents:"none"},!t.disableInteractive&&{pointerEvents:"auto"},!n&&{pointerEvents:"none"},t.arrow&&{[`&[data-popper-placement*="bottom"] .${at.arrow}`]:{top:0,marginTop:"-0.71em","&::before":{transformOrigin:"0 100%"}},[`&[data-popper-placement*="top"] .${at.arrow}`]:{bottom:0,marginBottom:"-0.71em","&::before":{transformOrigin:"100% 0"}},[`&[data-popper-placement*="right"] .${at.arrow}`]:R({},t.isRtl?{right:0,marginRight:"-0.71em"}:{left:0,marginLeft:"-0.71em"},{height:"1em",width:"0.71em","&::before":{transformOrigin:"100% 100%"}}),[`&[data-popper-placement*="left"] .${at.arrow}`]:R({},t.isRtl?{left:0,marginLeft:"-0.71em"}:{right:0,marginRight:"-0.71em"},{height:"1em",width:"0.71em","&::before":{transformOrigin:"0 0"}})})),Xf=In("div",{name:"MuiTooltip",slot:"Tooltip",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.tooltip,n.touch&&t.touch,n.arrow&&t.tooltipArrow,t[`tooltipPlacement${Ye(n.placement.split("-")[0])}`]]}})(({theme:e,ownerState:t})=>R({backgroundColor:e.vars?e.vars.palette.Tooltip.bg:pi(e.palette.grey[700],.92),borderRadius:(e.vars||e).shape.borderRadius,color:(e.vars||e).palette.common.white,fontFamily:e.typography.fontFamily,padding:"4px 8px",fontSize:e.typography.pxToRem(11),maxWidth:300,margin:2,wordWrap:"break-word",fontWeight:e.typography.fontWeightMedium},t.arrow&&{position:"relative",margin:0},t.touch&&{padding:"8px 16px",fontSize:e.typography.pxToRem(14),lineHeight:`${Uf(16/14)}em`,fontWeight:e.typography.fontWeightRegular},{[`.${at.popper}[data-popper-placement*="left"] &`]:R({transformOrigin:"right center"},t.isRtl?R({marginLeft:"14px"},t.touch&&{marginLeft:"24px"}):R({marginRight:"14px"},t.touch&&{marginRight:"24px"})),[`.${at.popper}[data-popper-placement*="right"] &`]:R({transformOrigin:"left center"},t.isRtl?R({marginRight:"14px"},t.touch&&{marginRight:"24px"}):R({marginLeft:"14px"},t.touch&&{marginLeft:"24px"})),[`.${at.popper}[data-popper-placement*="top"] &`]:R({transformOrigin:"center bottom",marginBottom:"14px"},t.touch&&{marginBottom:"24px"}),[`.${at.popper}[data-popper-placement*="bottom"] &`]:R({transformOrigin:"center top",marginTop:"14px"},t.touch&&{marginTop:"24px"})})),Yf=In("span",{name:"MuiTooltip",slot:"Arrow",overridesResolver:(e,t)=>t.arrow})(({theme:e})=>({overflow:"hidden",position:"absolute",width:"1em",height:"0.71em",boxSizing:"border-box",color:e.vars?e.vars.palette.Tooltip.bg:pi(e.palette.grey[700],.9),"&::before":{content:'""',margin:"auto",display:"block",width:"100%",height:"100%",backgroundColor:"currentColor",transform:"rotate(45deg)"}}));let Gn=!1;const Wa=new On;let an={x:0,y:0};function Un(e,t){return n=>{t&&t(n),e(n)}}const Pi=$.forwardRef(function(t,n){var r,o,s,i,l,c,d,u,f,w,b,x,m,h,k,I,C,E,v;const _=_o({props:t,name:"MuiTooltip"}),{arrow:V=!1,children:U,components:j={},componentsProps:O={},describeChild:S=!1,disableFocusListener:A=!1,disableHoverListener:M=!1,disableInteractive:J=!1,disableTouchListener:Y=!1,enterDelay:F=100,enterNextDelay:te=0,enterTouchDelay:se=700,followCursor:oe=!1,id:y,leaveDelay:T=0,leaveTouchDelay:z=1500,onClose:L,onOpen:B,open:X,placement:q="bottom",PopperComponent:H,PopperProps:G={},slotProps:K={},slots:Z={},title:ue,TransitionComponent:P=Ya,TransitionProps:xe}=_,D=ye(_,Gf),ve=$.isValidElement(U)?U:a.jsx("span",{children:U}),Fe=Ci(),lt=Fe.direction==="rtl",[Se,An]=$.useState(),[Ge,Et]=$.useState(null),ct=$.useRef(!1),jt=J||oe,Tt=cn(),Ct=cn(),dt=cn(),Kt=cn(),[Dn,Fo]=ti({controlled:X,default:!1,name:"Tooltip",state:"open"});let Ke=Dn;if(process.env.NODE_ENV!=="production"){const{current:Q}=$.useRef(X!==void 0);$.useEffect(()=>{Se&&Se.disabled&&!Q&&ue!==""&&Se.tagName.toLowerCase()==="button"&&console.error(["MUI: You are providing a disabled `button` child to the Tooltip component.","A disabled element does not fire events.","Tooltip needs to listen to the child element's events to display the title.","","Add a simple wrapper element, such as a `span`."].join(` +`))},[ue,Se,Q])}const kr=ei(y),Jt=$.useRef(),Bn=Jr(()=>{Jt.current!==void 0&&(document.body.style.WebkitUserSelect=Jt.current,Jt.current=void 0),Kt.clear()});$.useEffect(()=>Bn,[Bn]);const Go=Q=>{Wa.clear(),Gn=!0,Fo(!0),B&&!Ke&&B(Q)},Vn=Jr(Q=>{Wa.start(800+T,()=>{Gn=!1}),Fo(!1),L&&Ke&&L(Q),Tt.start(Fe.transitions.duration.shortest,()=>{ct.current=!1})}),Sr=Q=>{ct.current&&Q.type!=="touchstart"||(Se&&Se.removeAttribute("title"),Ct.clear(),dt.clear(),F||Gn&&te?Ct.start(Gn?te:F,()=>{Go(Q)}):Go(Q))},Uo=Q=>{Ct.clear(),dt.start(T,()=>{Vn(Q)})},{isFocusVisibleRef:qo,onBlur:el,onFocus:tl,ref:nl}=ni(),[,Ho]=$.useState(!1),Xo=Q=>{el(Q),qo.current===!1&&(Ho(!1),Uo(Q))},Yo=Q=>{Se||An(Q.currentTarget),tl(Q),qo.current===!0&&(Ho(!0),Sr(Q))},Wo=Q=>{ct.current=!0;const Oe=ve.props;Oe.onTouchStart&&Oe.onTouchStart(Q)},Ko=Sr,Jo=Uo,rl=Q=>{Wo(Q),dt.clear(),Tt.clear(),Bn(),Jt.current=document.body.style.WebkitUserSelect,document.body.style.WebkitUserSelect="none",Kt.start(se,()=>{document.body.style.WebkitUserSelect=Jt.current,Sr(Q)})},ol=Q=>{ve.props.onTouchEnd&&ve.props.onTouchEnd(Q),Bn(),dt.start(z,()=>{Vn(Q)})};$.useEffect(()=>{if(!Ke)return;function Q(Oe){(Oe.key==="Escape"||Oe.key==="Esc")&&Vn(Oe)}return document.addEventListener("keydown",Q),()=>{document.removeEventListener("keydown",Q)}},[Vn,Ke]);const al=yt(ve.ref,nl,An,n);!ue&&ue!==0&&(Ke=!1);const Er=$.useRef(),sl=Q=>{const Oe=ve.props;Oe.onMouseMove&&Oe.onMouseMove(Q),an={x:Q.clientX,y:Q.clientY},Er.current&&Er.current.update()},Zt={},jr=typeof ue=="string";S?(Zt.title=!Ke&&jr&&!M?ue:null,Zt["aria-describedby"]=Ke?kr:null):(Zt["aria-label"]=jr?ue:null,Zt["aria-labelledby"]=Ke&&!jr?kr:null);const $e=R({},Zt,D,ve.props,{className:ot(D.className,ve.props.className),onTouchStart:Wo,ref:al},oe?{onMouseMove:sl}:{});process.env.NODE_ENV!=="production"&&($e["data-mui-internal-clone-element"]=!0,$.useEffect(()=>{Se&&!Se.getAttribute("data-mui-internal-clone-element")&&console.error(["MUI: The `children` component of the Tooltip is not forwarding its props correctly.","Please make sure that props are spread on the same element that the ref is applied to."].join(` `))},[Se]));const Qt={};Y||($e.onTouchStart=rl,$e.onTouchEnd=ol),M||($e.onMouseOver=Un(Ko,$e.onMouseOver),$e.onMouseLeave=Un(Jo,$e.onMouseLeave),jt||(Qt.onMouseOver=Ko,Qt.onMouseLeave=Jo)),A||($e.onFocus=Un(Yo,$e.onFocus),$e.onBlur=Un(Xo,$e.onBlur),jt||(Qt.onFocus=Yo,Qt.onBlur=Xo)),process.env.NODE_ENV!=="production"&&ve.props.title&&console.error(["MUI: You have provided a `title` prop to the child of .",`Remove this title prop \`${ve.props.title}\` or the Tooltip component.`].join(` -`));const il=$.useMemo(()=>{var Q;let Oe=[{name:"arrow",enabled:!!Ge,options:{element:Ge,padding:4}}];return(Q=G.popperOptions)!=null&&Q.modifiers&&(Oe=Oe.concat(G.popperOptions.modifiers)),R({},G.popperOptions,{modifiers:Oe})},[Ge,G]),en=R({},_,{isRtl:lt,arrow:V,disableInteractive:jt,placement:q,PopperComponentProp:H,touch:ct.current}),Tr=qf(en),Zo=(r=(o=Z.popper)!=null?o:j.Popper)!=null?r:Hf,Qo=(s=(i=(l=Z.transition)!=null?l:j.Transition)!=null?i:P)!=null?s:Ya,ea=(c=(d=Z.tooltip)!=null?d:j.Tooltip)!=null?c:Xf,ta=(u=(f=Z.arrow)!=null?f:j.Arrow)!=null?u:Yf,ll=dn(Zo,R({},G,(w=K.popper)!=null?w:O.popper,{className:ot(Tr.popper,G==null?void 0:G.className,(b=(x=K.popper)!=null?x:O.popper)==null?void 0:b.className)}),en),cl=dn(Qo,R({},xe,(m=K.transition)!=null?m:O.transition),en),dl=dn(ea,R({},(h=K.tooltip)!=null?h:O.tooltip,{className:ot(Tr.tooltip,(E=(I=K.tooltip)!=null?I:O.tooltip)==null?void 0:E.className)}),en),ul=dn(ta,R({},(C=K.arrow)!=null?C:O.arrow,{className:ot(Tr.arrow,(S=(v=K.arrow)!=null?v:O.arrow)==null?void 0:S.className)}),en);return a.jsxs($.Fragment,{children:[$.cloneElement(ve,$e),a.jsx(Zo,R({as:H??_i,placement:q,anchorEl:oe?{getBoundingClientRect:()=>({top:an.y,left:an.x,right:an.x,bottom:an.y,width:0,height:0})}:Se,popperRef:Er,open:Se?Ke:!1,id:kr,transition:!0},Qt,ll,{popperOptions:il,children:({TransitionProps:Q})=>a.jsx(Qo,R({timeout:Fe.transitions.duration.shorter},Q,cl,{children:a.jsxs(ea,R({},dl,{children:[ue,V?a.jsx(ta,R({},ul,{ref:Et})):null]}))}))}))]})});process.env.NODE_ENV!=="production"&&(Pi.propTypes={arrow:p.bool,children:Js.isRequired,classes:p.object,className:p.string,components:p.shape({Arrow:p.elementType,Popper:p.elementType,Tooltip:p.elementType,Transition:p.elementType}),componentsProps:p.shape({arrow:p.object,popper:p.object,tooltip:p.object,transition:p.object}),describeChild:p.bool,disableFocusListener:p.bool,disableHoverListener:p.bool,disableInteractive:p.bool,disableTouchListener:p.bool,enterDelay:p.number,enterNextDelay:p.number,enterTouchDelay:p.number,followCursor:p.bool,id:p.string,leaveDelay:p.number,leaveTouchDelay:p.number,onClose:p.func,onOpen:p.func,open:p.bool,placement:p.oneOf(["bottom-end","bottom-start","bottom","left-end","left-start","left","right-end","right-start","right","top-end","top-start","top"]),PopperComponent:p.elementType,PopperProps:p.object,slotProps:p.shape({arrow:p.object,popper:p.object,tooltip:p.object,transition:p.object}),slots:p.shape({arrow:p.elementType,popper:p.elementType,tooltip:p.elementType,transition:p.elementType}),sx:p.oneOfType([p.arrayOf(p.oneOfType([p.func,p.object,p.bool])),p.func,p.object]),title:p.node,TransitionComponent:p.elementType,TransitionProps:p.object});const Wf=Pi;function Ka(e,t,n){return e?a.jsx(Ie.ListItemIcon,{className:`papi-menu-icon-${n?"leading":"trailing"}`,children:a.jsx("img",{src:e,alt:`${n?"Leading":"Trailing"} icon for ${t}`})}):void 0}function Lo(e){const{onClick:t,label:n,tooltip:r,allowForLeadingIcons:o=!0,iconPathBefore:s=void 0,iconPathAfter:i=void 0,hasAutoFocus:l=!1,className:c,isDisabled:d=!1,isDense:u=!0,isSubMenuParent:f=!1,hasDisabledGutters:w=!1,hasDivider:b=!1,focusVisibleClassName:x,id:m,children:h}=e,E=a.jsx(Ie.MenuItem,{sx:{lineHeight:.8},autoFocus:l,className:c,disabled:d,dense:u,disableGutters:w,divider:b,focusVisibleClassName:x,onClick:t,id:m,children:n?a.jsxs(a.Fragment,{children:[Ka(s,n,!0),a.jsx(Ie.ListItemText,{primary:n,inset:!s&&o}),f?a.jsx(Ie.ListItemIcon,{className:"papi-menu-icon-trailing",children:a.jsx(fi,{})}):Ka(i,n,!1)]}):h});return r?a.jsx(Wf,{title:r,placement:"right",children:a.jsx("div",{children:E})}):E}function Ii(e){return Object.entries(e.groups).map(([n,r])=>({id:n,group:r}))}function Kf(e){const[t,n]=g.useState(void 0),{parentMenuItem:r,parentItemProps:o,menuDefinition:s}=e,i=d=>{n(d.currentTarget)},l=()=>{n(void 0)},c=()=>{let d=Ii(s).filter(u=>"menuItem"in u.group);if(!(r!=null&&r.id))throw new Error("A valid parent menu item is required for submenus.");return d=d.filter(u=>"menuItem"in u.group&&u.group.menuItem===r.id),a.jsx(Mi,{...e,includedGroups:d})};return a.jsxs(a.Fragment,{children:[a.jsx(Lo,{onClick:i,...o,isSubMenuParent:!0}),a.jsx(Ie.Menu,{anchorEl:t,open:!!t,onClose:l,anchorOrigin:{vertical:"top",horizontal:"right"},transformOrigin:{vertical:"top",horizontal:"left"},children:c()},r.id)]})}const Jf=(e,t)=>t.filter(o=>o.group===e).sort((o,s)=>(o.order||0)-(s.order||0));function Mi(e){const{menuDefinition:t,onClick:n,commandHandler:r,includedGroups:o}=e,{items:s,allowForLeadingIcons:i}=g.useMemo(()=>{const u=o&&o.length>0?o:Ii(t).filter(x=>!("menuItem"in x.group)),f=Object.values(u).sort((x,m)=>(x.group.order||0)-(m.group.order||0)),w=[];f.forEach(x=>{Jf(x.id,t.items).forEach(m=>w.push({item:m,isLastItemInGroup:!1})),w.length>0&&(w[w.length-1].isLastItemInGroup=!0)}),w.length>0&&(w[w.length-1].isLastItemInGroup=!1);const b=w.some(x=>"iconPathBefore"in x.item&&x.item.iconPathBefore);return{items:w,allowForLeadingIcons:b}},[o,t]),l=({item:u,isLastItemInGroup:f})=>({className:"papi-menu-item",label:u.label,tooltip:u.tooltip,iconPathBefore:"iconPathBefore"in u?u.iconPathBefore:void 0,iconPathAfter:"iconPathAfter"in u?u.iconPathAfter:void 0,hasDivider:f,allowForLeadingIcons:i}),[c]=s;if(!c)return a.jsx("div",{});const d=c.item.group;return a.jsx("div",{role:"menu","aria-label":d,children:s.map((u,f)=>{const{item:w}=u,b=l(u);if("command"in w){const x=w.group+f;return a.jsx(Lo,{onClick:m=>{n==null||n(m),r(w)},...b},x)}return a.jsx(Kf,{parentMenuItem:w,parentItemProps:b,...e},d+w.id)})},d)}function Zf(e){const{menuDefinition:t,columnId:n}=e;let s=Object.entries(t.groups).map(([i,l])=>({id:i,group:l})).filter(i=>"column"in i.group);return n&&"columns"in t&&t.columns[n]&&(s=s.filter(i=>"column"in i.group&&i.group.column===n)),a.jsx(Mi,{...e,includedGroups:s})}function Qf({commandHandler:e,menuDefinition:t,id:n,metadata:r,onClick:o,className:s}){return a.jsxs(Ie.Grid,{id:n,item:!0,xs:"auto",role:"menu","aria-label":n,className:`papi-menu-column ${s??""}`,children:[a.jsx("h3",{"aria-label":r.label,className:`papi-menu-column-header ${s??""}`,children:r.label}),a.jsx(Ie.List,{id:n,dense:!0,className:s??"",children:a.jsx(Zf,{commandHandler:e,menuDefinition:t,columnId:n,onClick:o})})]})}function $i({commandHandler:e,className:t,multiColumnMenu:n,id:r}){const{columns:o}=n,s=g.useMemo(()=>{const i=new Map;return Object.getOwnPropertyNames(o).forEach(l=>{if(l==="isExtensible")return;const c=l,d=o[c];typeof d=="object"&&typeof d.order=="number"&&!Number.isNaN(d.order)?i.set(d.order,{id:c,metadata:d}):console.warn(`Property ${l} (${typeof d}) on menu ${r} is not a valid column and is being ignored. This might indicate data corruption`)}),Array.from(i.values()).sort((l,c)=>(l.metadata.order||0)-(c.metadata.order||0))},[o,r]);return a.jsx(Ie.Grid,{container:!0,spacing:0,className:`papi-multi-column-menu ${t??""}`,columns:s.length,role:"menu","aria-label":"GridMenu",id:r,children:s.map((i,l)=>a.jsx(Qf,{commandHandler:e,menuDefinition:n,...i,className:t},l))})}function em(e){return{preserveValue:!0,...e}}const nr=(e,t,n={})=>{const r=g.useRef(t);r.current=t;const o=g.useRef(n);o.current=em(o.current);const[s,i]=g.useState(()=>r.current),[l,c]=g.useState(!0);return g.useEffect(()=>{let d=!0;return c(!!e),(async()=>{if(e){const u=await e();d&&(i(()=>u),c(!1))}})(),()=>{d=!1,o.current.preserveValue||i(()=>r.current)}},[e]),[s,l]},tm=wi(a.jsx("path",{d:"M3 18h18v-2H3zm0-5h18v-2H3zm0-7v2h18V6z"}),"Menu");function Ai({menuProvider:e,normalMenu:t,fullMenu:n,commandHandler:r,containerRef:o,className:s,ariaLabelPrefix:i,children:l}){const[c,d]=g.useState(!1),[u,f]=g.useState(!1),w=g.useCallback(()=>{c&&d(!1),f(!1)},[c]),b=g.useCallback(S=>{S.stopPropagation(),d(v=>{const _=!v;return _&&S.shiftKey?f(!0):_||f(!1),_})},[]),x=g.useCallback(S=>(w(),r(S)),[r,w]),[m,h]=g.useState({top:1,left:1});g.useEffect(()=>{if(c){const S=o==null?void 0:o.current;if(S){const v=S.getBoundingClientRect(),_=window.scrollY,V=window.scrollX,U=v.top+_+S.clientHeight,j=v.left+V;h({top:U,left:j})}}},[c,o]);const[E]=nr(g.useCallback(async()=>(e==null?void 0:e(!1))??t,[e,t,c]),t),[I]=nr(g.useCallback(async()=>(e==null?void 0:e(!0))??n??E,[e,n,E,c]),n??E),C=u&&I?I:E;return a.jsxs(a.Fragment,{children:[a.jsx(Ie.IconButton,{sx:{paddingTop:0,paddingBottom:0},edge:"start",className:`papi-menuButton ${s??""}`,color:"inherit","aria-label":`${i??""} menu button`,onClick:b,children:l??a.jsx(tm,{})}),a.jsx(Ie.Drawer,{className:`papi-menu-drawer ${s??""}`,anchor:"left",variant:"temporary",open:c,onClose:w,PaperProps:{className:"papi-menu-drawer-paper",style:{top:m.top,left:m.left}},children:C?a.jsx($i,{className:s,id:`${i??""} main menu`,commandHandler:x,multiColumnMenu:C}):void 0})]})}function nm({id:e,label:t,isDisabled:n=!1,tooltip:r,isTooltipSuppressed:o=!1,adjustMarginToAlignToEdge:s=!1,size:i="medium",className:l,onClick:c,children:d}){return a.jsx(Ie.IconButton,{id:e,disabled:n,edge:s,size:i,"aria-label":t,title:o?void 0:r??t,className:`papi-icon-button ${l??""}`,onClick:c,children:d})}const Wt=g.forwardRef(({className:e,...t},n)=>a.jsx(ee.LoaderCircle,{size:35,className:N("tw-animate-spin",e),...t,ref:n}));Wt.displayName="Spinner";function rm({id:e,isDisabled:t=!1,hasError:n=!1,isFullWidth:r=!1,helperText:o,label:s,placeholder:i,isRequired:l=!1,className:c,defaultValue:d,value:u,onChange:f,onFocus:w,onBlur:b}){return a.jsxs("div",{className:N("tw-inline-grid tw-items-center tw-gap-1.5",{"tw-w-full":r}),children:[a.jsx(Ue,{htmlFor:e,className:N({"tw-text-red-600":n,"tw-hidden":!s}),children:`${s}${l?"*":""}`}),a.jsx(St,{id:e,disabled:t,placeholder:i,required:l,className:N(c,{"tw-border-red-600":n}),defaultValue:d,value:u,onChange:f,onFocus:w,onBlur:b}),a.jsx("p",{className:N({"tw-hidden":!o}),children:o})]})}function om({menuProvider:e,commandHandler:t,className:n,id:r,children:o}){const s=g.useRef(void 0);return a.jsx("div",{ref:s,style:{position:"relative"},children:a.jsx(Ie.AppBar,{position:"static",id:r,children:a.jsxs(Ie.Toolbar,{className:N("tw-bg-muted tw-text-muted-foreground",n),variant:"dense",children:[e?a.jsx(Ai,{commandHandler:t,containerRef:s,menuProvider:e}):void 0,o?a.jsx("div",{className:"papi-toolbar-children",children:o}):void 0]})})})}const am=kn.cva("tw-relative tw-w-full tw-rounded-lg tw-border tw-p-4 [&>svg~*]:tw-pl-7 [&>svg+div]:tw-translate-y-[-3px] [&>svg]:tw-absolute [&>svg]:tw-left-4 [&>svg]:tw-top-4 [&>svg]:tw-text-foreground",{variants:{variant:{default:"tw-bg-background tw-text-foreground",destructive:"tw-border-destructive/50 tw-text-destructive dark:tw-border-destructive [&>svg]:tw-text-destructive"}},defaultVariants:{variant:"default"}}),Di=g.forwardRef(({className:e,variant:t,...n},r)=>a.jsx("div",{ref:r,role:"alert",className:N(am({variant:t}),e),...n}));Di.displayName="Alert";const Bi=g.forwardRef(({className:e,...t},n)=>a.jsxs("h5",{ref:n,className:N("tw-mb-1 tw-font-medium tw-leading-none tw-tracking-tight",e),...t,children:[t.children," "]}));Bi.displayName="AlertTitle";const Vi=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,className:N("tw-text-sm [&_p]:tw-leading-relaxed",e),...t}));Vi.displayName="AlertDescription";const zi=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,className:N("pr-twp tw-rounded-lg tw-border tw-bg-card tw-text-card-foreground tw-shadow-sm",e),...t}));zi.displayName="Card";const Li=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,className:N("pr-twp tw-flex tw-flex-col tw-space-y-1.5 tw-p-6",e),...t}));Li.displayName="CardHeader";const Fi=g.forwardRef(({className:e,...t},n)=>a.jsx("h3",{ref:n,className:N("pr-twp tw-text-2xl tw-font-semibold tw-leading-none tw-tracking-tight",e),...t,children:t.children}));Fi.displayName="CardTitle";const Gi=g.forwardRef(({className:e,...t},n)=>a.jsx("p",{ref:n,className:N("pr-twp tw-text-sm tw-text-muted-foreground",e),...t}));Gi.displayName="CardDescription";const Ui=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,className:N("pr-twp tw-p-6 tw-pt-0",e),...t}));Ui.displayName="CardContent";const qi=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,className:N("pr-twp tw-flex tw-items-center tw-p-6 tw-pt-0",e),...t}));qi.displayName="CardFooter";function sm({...e}){return a.jsx(Za.Toaster,{className:"tw-toaster tw-group",toastOptions:{classNames:{toast:"group toast group-[.toaster]:bg-background group-[.toaster]:text-foreground group-[.toaster]:border-border group-[.toaster]:shadow-lg",description:"group-[.toast]:text-muted-foreground",actionButton:"group-[.toast]:bg-primary group-[.toast]:text-primary-foreground",cancelButton:"group-[.toast]:bg-muted group-[.toast]:text-muted-foreground"}},...e})}const Hi=g.forwardRef(({className:e,...t},n)=>a.jsxs(ln.Root,{ref:n,className:N("pr-twp tw-relative tw-flex tw-w-full tw-touch-none tw-select-none tw-items-center",e),...t,children:[a.jsx(ln.Track,{className:"tw-relative tw-h-2 tw-w-full tw-grow tw-overflow-hidden tw-rounded-full tw-bg-secondary",children:a.jsx(ln.Range,{className:"tw-absolute tw-h-full tw-bg-primary"})}),a.jsx(ln.Thumb,{className:"tw-block tw-h-5 tw-w-5 tw-rounded-full tw-border-2 tw-border-primary tw-bg-background tw-ring-offset-background tw-transition-colors focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50"})]}));Hi.displayName=ln.Root.displayName;const Xi=g.forwardRef(({className:e,...t},n)=>a.jsx(Ur.Root,{className:N("tw-peer pr-twp tw-inline-flex tw-h-6 tw-w-11 tw-shrink-0 tw-cursor-pointer tw-items-center tw-rounded-full tw-border-2 tw-border-transparent tw-transition-colors focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 focus-visible:tw-ring-offset-background disabled:tw-cursor-not-allowed disabled:tw-opacity-50 data-[state=checked]:tw-bg-primary data-[state=unchecked]:tw-bg-input",e),...t,ref:n,children:a.jsx(Ur.Thumb,{className:N("pr-twp tw-pointer-events-none tw-block tw-h-5 tw-w-5 tw-rounded-full tw-bg-background tw-shadow-lg tw-ring-0 tw-transition-transform data-[state=checked]:tw-translate-x-5 data-[state=unchecked]:tw-translate-x-0")})}));Xi.displayName=Ur.Root.displayName;const im=Re.Root,Yi=g.forwardRef(({className:e,...t},n)=>a.jsx(Re.List,{ref:n,className:N("tw-inline-flex tw-h-10 tw-items-center tw-justify-center tw-rounded-md tw-bg-muted tw-p-1 tw-text-muted-foreground",e),...t}));Yi.displayName=Re.List.displayName;const Wi=g.forwardRef(({className:e,...t},n)=>a.jsx(Re.Trigger,{ref:n,className:N("tw-inline-flex tw-items-center tw-justify-center tw-whitespace-nowrap tw-rounded-sm tw-px-3 tw-py-1.5 tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-all hover:tw-text-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50 data-[state=active]:tw-bg-background data-[state=active]:tw-text-foreground data-[state=active]:tw-shadow-sm",e),...t}));Wi.displayName=Re.Trigger.displayName;const Ki=g.forwardRef(({className:e,...t},n)=>a.jsx(Re.Content,{ref:n,className:N("tw-mt-2 tw-ring-offset-background focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2",e),...t}));Ki.displayName=Re.Content.displayName;function lm({isInstalling:e,handleClick:t,buttonText:n,className:r,...o}){return a.jsx(fe,{className:N("tw-h-8 tw-rounded-md tw-text-white tw-transition tw-duration-300 tw-ease-in-out hover:tw-bg-blue-700",{"tw-cursor-not-allowed tw-bg-blue-700":e,"tw-bg-blue-600":!e,"tw-bg-white tw-text-blue-600 hover:tw-text-white":!n,"tw-w-20":n},r),onClick:t,...o,children:e?a.jsx(Wt,{size:15}):a.jsxs(a.Fragment,{children:[a.jsx(ee.Download,{size:25,className:N("tw-h-4 tw-w-4",{"tw-mr-1":n})}),n]})})}function cm({isEnabling:e,handleClick:t,className:n,...r}){return a.jsx(fe,{className:N("tw-h-8 tw-rounded-md tw-bg-blue-600 tw-px-4 tw-text-white tw-transition tw-duration-300 tw-ease-in-out hover:tw-bg-blue-700",{"tw-cursor-not-allowed tw-bg-blue-700":e},n),onClick:t,...r,children:e?a.jsxs(a.Fragment,{children:[a.jsx(Wt,{size:15,className:"tw-mr-1 tw-text-white"}),"Enabling..."]}):"Enable"})}function dm({isDisabling:e,handleClick:t,className:n,...r}){return a.jsx(fe,{className:N("tw-h-8 tw-rounded-md tw-bg-gray-300 tw-text-black tw-transition tw-duration-300 tw-ease-in-out hover:tw-bg-gray-400",{"tw-cursor-not-allowed tw-bg-gray-400":e},n),onClick:t,...r,children:e?a.jsxs(a.Fragment,{children:[a.jsx(Wt,{size:15,className:"tw-mr-1 tw-text-black"}),"Disabling..."]}):"Disable"})}function um({isUpdating:e,handleClick:t,className:n,...r}){return a.jsx(fe,{className:N("tw-h-8 tw-rounded-md tw-bg-blue-600 tw-px-4 tw-text-white tw-transition tw-duration-300 tw-ease-in-out hover:tw-bg-blue-700 hover:tw-text-white",{"tw-cursor-not-allowed tw-bg-blue-700":e},n),onClick:t,...r,children:e?a.jsxs(a.Fragment,{children:[a.jsx(Wt,{size:15,className:"tw-mr-1 tw-text-white"}),"Updating..."]}):"Update"})}function pm({id:e,markdown:t,className:n,anchorTarget:r}){const o=g.useMemo(()=>({overrides:{a:{props:{target:r}}}}),[r]);return a.jsx("div",{id:e,className:N("pr-twp tw-prose",n),children:a.jsx(jl,{options:o,children:t})})}const Ji=g.forwardRef((e,t)=>a.jsxs(fe,{ref:t,className:"tw-rounded-md tw-border tw-border-dashed tw-border-gray-400 tw-bg-white tw-px-4 tw-py-2 tw-text-black tw-transition tw-duration-300 tw-ease-in-out hover:tw-border-blue-600 hover:tw-bg-white hover:tw-text-blue-600",...e,children:[a.jsx(ee.Filter,{size:16,className:"tw-mr-2 tw-h-4 tw-w-4 tw-text-gray-700 hover:tw-text-blue-600"}),"Filter",a.jsx(ee.ChevronDown,{size:16,className:"tw-ml-2 tw-h-4 tw-w-4 tw-text-gray-700 hover:tw-text-blue-600"})]}));var Zi=(e=>(e[e.Check=0]="Check",e[e.Radio=1]="Radio",e))(Zi||{});function wm({id:e,groups:t}){return a.jsx("div",{id:e,children:a.jsxs(or,{children:[a.jsx(io,{asChild:!0,children:a.jsx(Ji,{})}),a.jsx(En,{children:t.map(n=>a.jsxs("div",{children:[a.jsx(Yt,{children:n.label}),a.jsx(ls,{children:n.items.map(r=>a.jsx("div",{children:r.itemType===0?a.jsx(ar,{onClick:r.onClick,children:r.label}):a.jsx(co,{onClick:r.onClick,value:r.label,children:r.label})},r.label))}),a.jsx(jn,{})]},n.label))})]})})}function fm({id:e,message:t}){return a.jsx("div",{id:e,className:"tw-mb-20 tw-mt-20 tw-flex tw-items-center tw-justify-center",children:a.jsx("div",{className:"tw-w-3/4 tw-rounded-lg tw-bg-gray-100 tw-p-8 tw-text-center",children:a.jsx("p",{className:"tw-text-lg tw-text-gray-800",children:t})})})}function mm({id:e,category:t,downloads:n,languages:r,moreInfoUrl:o}){const s=new W.NumberFormat("en",{notation:"compact",compactDisplay:"short"}).format(Object.values(n).reduce((l,c)=>l+c,0)),i=()=>{window.scrollTo(0,document.body.scrollHeight)};return a.jsxs("div",{id:e,className:"tw-flex tw-flex-wrap tw-items-start tw-space-x-4 tw-border-b tw-border-t tw-bg-white tw-pb-4 tw-pt-4",children:[a.jsxs("div",{className:"tw-flex tw-flex-col tw-items-center",children:[a.jsx("div",{className:"tw-flex tw-items-center tw-rounded-md tw-bg-gray-100 tw-px-2 tw-py-1",children:a.jsx("span",{className:"tw-text-xs tw-font-semibold tw-text-gray-700",children:t})}),a.jsx("span",{className:"tw-text-xs tw-text-gray-500",children:"CATEGORY"})]}),a.jsx("div",{className:"tw-mx-2 tw-h-10 tw-border-l tw-border-gray-300"}),a.jsxs("div",{className:"tw-flex tw-flex-col tw-items-center",children:[a.jsxs("div",{className:"tw-flex tw-items-center tw-rounded-md tw-bg-gray-100 tw-px-2 tw-py-1",children:[a.jsx(ee.User,{className:"tw-mr-1 tw-h-4 tw-w-4"}),a.jsx("span",{className:"tw-text-xs tw-font-semibold tw-text-gray-700",children:s})]}),a.jsx("span",{className:"tw-text-xs tw-text-gray-500",children:"USERS"})]}),a.jsx("div",{className:"tw-mx-2 tw-h-10 tw-border-l tw-border-gray-300"}),a.jsxs("div",{className:"tw-flex tw-flex-col tw-items-center",children:[a.jsx("div",{className:"tw-flex tw-items-center",children:r.slice(0,3).map(l=>a.jsx("span",{className:"tw-ml-1 tw-rounded-md tw-bg-gray-100 tw-px-2 tw-py-1 tw-text-xs tw-font-semibold tw-text-gray-700",children:l.toUpperCase()},l))}),r.length>3&&a.jsxs("button",{type:"button",onClick:()=>i(),className:"tw-text-xs tw-text-gray-500 tw-underline",children:["+",r.length-3," more languages"]})]}),a.jsx("div",{className:"tw-mx-2 tw-h-10 tw-border-l tw-border-gray-300"}),a.jsxs("div",{className:"tw-ml-auto tw-flex tw-flex-col tw-space-y-2",children:[a.jsxs("a",{href:o,target:"_blank",rel:"noreferrer",className:"tw-flex tw-items-center tw-text-xs tw-font-semibold tw-text-gray-500 tw-underline",children:["Website",a.jsx(ee.Link,{className:"tw-ml-1 tw-inline tw-h-4 tw-w-4"})]}),a.jsxs("a",{href:"https://example.com",target:"_blank",rel:"noreferrer",className:"tw-flex tw-items-center tw-text-xs tw-font-semibold tw-text-gray-500 tw-underline",children:["Support",a.jsx(ee.CircleHelp,{className:"tw-ml-1 tw-inline tw-h-4 tw-w-4"})]})]})]})}function Qi({id:e,versionHistory:t}){const[n,r]=g.useState(!1),o=new Date;function s(l){const c=new Date(l),d=new Date(o.getTime()-c.getTime()),u=d.getUTCFullYear()-1970,f=d.getUTCMonth(),w=d.getUTCDate()-1;let b="";return u>0?b=`${u.toString()} year${u===1?"":"s"} ago`:f>0?b=`${f.toString()} month${f===1?"":"s"} ago`:w===0?b="today":b=`${w.toString()} day${w===1?"":"s"} ago`,b}const i=Object.entries(t).sort((l,c)=>c[0].localeCompare(l[0]));return a.jsxs("div",{id:e,children:[a.jsx("h3",{className:"tw-text-md tw-font-semibold",children:"What`s New"}),a.jsx("ul",{className:"tw-list-disc tw-pl-5 tw-pr-4 tw-text-xs tw-text-gray-600",children:(n?i:i.slice(0,5)).map(l=>a.jsxs("div",{className:"tw-mt-3 tw-flex tw-justify-between",children:[a.jsx("div",{className:"tw-text-gray-600",children:a.jsx("li",{className:"tw-prose tw-text-xs",children:a.jsx("span",{children:l[1].description})})}),a.jsxs("div",{className:"tw-justify-end tw-text-right",children:[a.jsxs("div",{children:["Version ",l[0]]}),a.jsx("div",{children:s(l[1].date)})]})]},l[0]))}),i.length>5&&a.jsx("button",{type:"button",onClick:()=>r(!n),className:"tw-text-xs tw-text-gray-500 tw-underline",children:n?"Show Less Version History":"Show All Version History"})]})}function hm({id:e,publisherDisplayName:t,fileSize:n,locales:r,versionHistory:o}){const s=g.useMemo(()=>W.formatBytes(n),[n]),l=(c=>{const d=new Intl.DisplayNames(navigator.language,{type:"language"});return c.map(u=>d.of(u))})(r);return a.jsx("div",{id:e,className:"tw-border-t tw-pb-4 tw-pt-4",children:a.jsxs("div",{className:"tw-md:flex-row tw-md:space-x-8 tw-flex tw-flex-col tw-space-x-0",children:[a.jsx(Qi,{versionHistory:o}),a.jsx("div",{className:"tw-md:border-t-0 tw-md:border-l tw-md-h-auto tw-md-ml-8 tw-mt-4 tw-border-t tw-border-gray-300"}),a.jsxs("div",{className:"tw-md:mt-0 tw-mt-4 tw-flex-1 tw-space-y-3",children:[a.jsx("h2",{className:"tw-text-md tw-font-semibold",children:"Information"}),a.jsxs("div",{className:"tw-flex tw-items-start tw-justify-between tw-pr-4 tw-text-xs tw-text-gray-600",children:[a.jsxs("p",{className:"tw-flex tw-flex-col tw-justify-start",children:[a.jsx("span",{className:"tw-mb-2",children:"Publisher"}),a.jsx("span",{className:"tw-font-semibold",children:t}),a.jsx("span",{className:"tw-mb-2 tw-mt-4",children:"Size"}),a.jsx("span",{className:"tw-font-semibold",children:s})]}),a.jsx("div",{className:"tw-flex tw-w-3/4 tw-items-center tw-justify-between tw-text-xs tw-text-gray-600",children:a.jsxs("p",{className:"tw-flex tw-flex-col tw-justify-start",children:[a.jsx("span",{className:"tw-mb-2",children:"Languages"}),a.jsx("span",{className:"tw-font-semibold",children:l.join(", ")})]})})]})]})]})})}const gm=(e,t)=>{g.useEffect(()=>{if(!e)return()=>{};const n=e(t);return()=>{n()}},[e,t])},Lr=()=>!1,bm=(e,t)=>{const[n]=nr(g.useCallback(async()=>{if(!e)return Lr;const r=await Promise.resolve(e(t));return async()=>r()},[t,e]),Lr,{preserveValue:!1});g.useEffect(()=>()=>{n!==Lr&&n()},[n])};Object.defineProperty(exports,"sonner",{enumerable:!0,get:()=>Za.toast});exports.Alert=Di;exports.AlertDescription=Vi;exports.AlertTitle=Bi;exports.BOOK_SELECTOR_STRING_KEYS=pc;exports.BookChapterControl=tc;exports.BookSelectionMode=ys;exports.BookSelector=wc;exports.Button=fe;exports.Card=zi;exports.CardContent=Ui;exports.CardDescription=Gi;exports.CardFooter=qi;exports.CardHeader=Li;exports.CardTitle=Fi;exports.ChapterRangeSelector=xs;exports.Checkbox=sr;exports.Checklist=ad;exports.ComboBox=Wn;exports.DataTable=Ts;exports.DisableButton=dm;exports.DropdownMenu=or;exports.DropdownMenuCheckboxItem=ar;exports.DropdownMenuContent=En;exports.DropdownMenuGroup=ls;exports.DropdownMenuItem=lo;exports.DropdownMenuItemType=Zi;exports.DropdownMenuLabel=Yt;exports.DropdownMenuPortal=Fl;exports.DropdownMenuRadioGroup=Ul;exports.DropdownMenuRadioItem=co;exports.DropdownMenuSeparator=jn;exports.DropdownMenuShortcut=us;exports.DropdownMenuSub=Gl;exports.DropdownMenuSubContent=ds;exports.DropdownMenuSubTrigger=cs;exports.DropdownMenuTrigger=io;exports.EnableButton=cm;exports.FilterButton=Ji;exports.FilterDropdown=wm;exports.Footer=hm;exports.GridMenu=$i;exports.HamburgerMenuButton=Ai;exports.INVENTORY_STRING_KEYS=Nc;exports.IconButton=nm;exports.Input=St;exports.InstallButton=lm;exports.Inventory=Ec;exports.Label=Ue;exports.MarkdownRenderer=pm;exports.MenuItem=Lo;exports.MoreInfo=mm;exports.NavigationContentSearch=jc;exports.NoExtensionsFound=fm;exports.RadioGroup=uo;exports.RadioGroupItem=Yn;exports.ScriptureResultsViewer=ed;exports.ScrollGroupSelector=td;exports.SearchBar=mo;exports.Select=Dt;exports.SelectContent=vt;exports.SelectGroup=Ns;exports.SelectItem=Ae;exports.SelectLabel=ks;exports.SelectScrollDownButton=wo;exports.SelectScrollUpButton=po;exports.SelectSeparator=Ss;exports.SelectTrigger=bt;exports.SelectValue=Bt;exports.Separator=lr;exports.SettingsList=nd;exports.SettingsListHeader=od;exports.SettingsListItem=rd;exports.SettingsSidebar=Gs;exports.SettingsSidebarContentSearch=Hc;exports.Slider=Hi;exports.Sonner=sm;exports.Spinner=Wt;exports.Switch=Xi;exports.Table=Tn;exports.TableBody=Rn;exports.TableCaption=js;exports.TableCell=xt;exports.TableFooter=Es;exports.TableHead=Vt;exports.TableHeader=Cn;exports.TableRow=Ze;exports.Tabs=im;exports.TabsContent=Ki;exports.TabsList=Yi;exports.TabsTrigger=Wi;exports.TextField=rm;exports.ToggleGroup=fo;exports.ToggleGroupItem=wn;exports.Toolbar=om;exports.UpdateButton=um;exports.VersionHistory=Qi;exports.VerticalTabs=ho;exports.VerticalTabsContent=bo;exports.VerticalTabsList=go;exports.VerticalTabsTrigger=Is;exports.buttonVariants=ps;exports.cn=N;exports.getBookNumFromId=Rs;exports.getLinesFromUSFM=Cs;exports.getNumberFromUSFM=qr;exports.getStatusForItem=Os;exports.inventoryCountColumn=xc;exports.inventoryItemColumn=bc;exports.inventoryStatusColumn=yc;exports.useEvent=gm;exports.useEventAsync=bm;exports.usePromise=nr;function vm(e,t="top"){if(!e||typeof document>"u")return;const n=document.head||document.querySelector("head"),r=n.querySelector(":first-child"),o=document.createElement("style");o.appendChild(document.createTextNode(e)),t==="top"&&r?n.insertBefore(o,r):n.appendChild(o)}vm(`*, ::before, ::after { +`));const il=$.useMemo(()=>{var Q;let Oe=[{name:"arrow",enabled:!!Ge,options:{element:Ge,padding:4}}];return(Q=G.popperOptions)!=null&&Q.modifiers&&(Oe=Oe.concat(G.popperOptions.modifiers)),R({},G.popperOptions,{modifiers:Oe})},[Ge,G]),en=R({},_,{isRtl:lt,arrow:V,disableInteractive:jt,placement:q,PopperComponentProp:H,touch:ct.current}),Tr=qf(en),Zo=(r=(o=Z.popper)!=null?o:j.Popper)!=null?r:Hf,Qo=(s=(i=(l=Z.transition)!=null?l:j.Transition)!=null?i:P)!=null?s:Ya,ea=(c=(d=Z.tooltip)!=null?d:j.Tooltip)!=null?c:Xf,ta=(u=(f=Z.arrow)!=null?f:j.Arrow)!=null?u:Yf,ll=dn(Zo,R({},G,(w=K.popper)!=null?w:O.popper,{className:ot(Tr.popper,G==null?void 0:G.className,(b=(x=K.popper)!=null?x:O.popper)==null?void 0:b.className)}),en),cl=dn(Qo,R({},xe,(m=K.transition)!=null?m:O.transition),en),dl=dn(ea,R({},(h=K.tooltip)!=null?h:O.tooltip,{className:ot(Tr.tooltip,(k=(I=K.tooltip)!=null?I:O.tooltip)==null?void 0:k.className)}),en),ul=dn(ta,R({},(C=K.arrow)!=null?C:O.arrow,{className:ot(Tr.arrow,(E=(v=K.arrow)!=null?v:O.arrow)==null?void 0:E.className)}),en);return a.jsxs($.Fragment,{children:[$.cloneElement(ve,$e),a.jsx(Zo,R({as:H??_i,placement:q,anchorEl:oe?{getBoundingClientRect:()=>({top:an.y,left:an.x,right:an.x,bottom:an.y,width:0,height:0})}:Se,popperRef:Er,open:Se?Ke:!1,id:kr,transition:!0},Qt,ll,{popperOptions:il,children:({TransitionProps:Q})=>a.jsx(Qo,R({timeout:Fe.transitions.duration.shorter},Q,cl,{children:a.jsxs(ea,R({},dl,{children:[ue,V?a.jsx(ta,R({},ul,{ref:Et})):null]}))}))}))]})});process.env.NODE_ENV!=="production"&&(Pi.propTypes={arrow:p.bool,children:Js.isRequired,classes:p.object,className:p.string,components:p.shape({Arrow:p.elementType,Popper:p.elementType,Tooltip:p.elementType,Transition:p.elementType}),componentsProps:p.shape({arrow:p.object,popper:p.object,tooltip:p.object,transition:p.object}),describeChild:p.bool,disableFocusListener:p.bool,disableHoverListener:p.bool,disableInteractive:p.bool,disableTouchListener:p.bool,enterDelay:p.number,enterNextDelay:p.number,enterTouchDelay:p.number,followCursor:p.bool,id:p.string,leaveDelay:p.number,leaveTouchDelay:p.number,onClose:p.func,onOpen:p.func,open:p.bool,placement:p.oneOf(["bottom-end","bottom-start","bottom","left-end","left-start","left","right-end","right-start","right","top-end","top-start","top"]),PopperComponent:p.elementType,PopperProps:p.object,slotProps:p.shape({arrow:p.object,popper:p.object,tooltip:p.object,transition:p.object}),slots:p.shape({arrow:p.elementType,popper:p.elementType,tooltip:p.elementType,transition:p.elementType}),sx:p.oneOfType([p.arrayOf(p.oneOfType([p.func,p.object,p.bool])),p.func,p.object]),title:p.node,TransitionComponent:p.elementType,TransitionProps:p.object});const Wf=Pi;function Ka(e,t,n){return e?a.jsx(Ie.ListItemIcon,{className:`papi-menu-icon-${n?"leading":"trailing"}`,children:a.jsx("img",{src:e,alt:`${n?"Leading":"Trailing"} icon for ${t}`})}):void 0}function Lo(e){const{onClick:t,label:n,tooltip:r,allowForLeadingIcons:o=!0,iconPathBefore:s=void 0,iconPathAfter:i=void 0,hasAutoFocus:l=!1,className:c,isDisabled:d=!1,isDense:u=!0,isSubMenuParent:f=!1,hasDisabledGutters:w=!1,hasDivider:b=!1,focusVisibleClassName:x,id:m,children:h}=e,k=a.jsx(Ie.MenuItem,{sx:{lineHeight:.8},autoFocus:l,className:c,disabled:d,dense:u,disableGutters:w,divider:b,focusVisibleClassName:x,onClick:t,id:m,children:n?a.jsxs(a.Fragment,{children:[Ka(s,n,!0),a.jsx(Ie.ListItemText,{primary:n,inset:!s&&o}),f?a.jsx(Ie.ListItemIcon,{className:"papi-menu-icon-trailing",children:a.jsx(fi,{})}):Ka(i,n,!1)]}):h});return r?a.jsx(Wf,{title:r,placement:"right",children:a.jsx("div",{children:k})}):k}function Ii(e){return Object.entries(e.groups).map(([n,r])=>({id:n,group:r}))}function Kf(e){const[t,n]=g.useState(void 0),{parentMenuItem:r,parentItemProps:o,menuDefinition:s}=e,i=d=>{n(d.currentTarget)},l=()=>{n(void 0)},c=()=>{let d=Ii(s).filter(u=>"menuItem"in u.group);if(!(r!=null&&r.id))throw new Error("A valid parent menu item is required for submenus.");return d=d.filter(u=>"menuItem"in u.group&&u.group.menuItem===r.id),a.jsx(Mi,{...e,includedGroups:d})};return a.jsxs(a.Fragment,{children:[a.jsx(Lo,{onClick:i,...o,isSubMenuParent:!0}),a.jsx(Ie.Menu,{anchorEl:t,open:!!t,onClose:l,anchorOrigin:{vertical:"top",horizontal:"right"},transformOrigin:{vertical:"top",horizontal:"left"},children:c()},r.id)]})}const Jf=(e,t)=>t.filter(o=>o.group===e).sort((o,s)=>(o.order||0)-(s.order||0));function Mi(e){const{menuDefinition:t,onClick:n,commandHandler:r,includedGroups:o}=e,{items:s,allowForLeadingIcons:i}=g.useMemo(()=>{const u=o&&o.length>0?o:Ii(t).filter(x=>!("menuItem"in x.group)),f=Object.values(u).sort((x,m)=>(x.group.order||0)-(m.group.order||0)),w=[];f.forEach(x=>{Jf(x.id,t.items).forEach(m=>w.push({item:m,isLastItemInGroup:!1})),w.length>0&&(w[w.length-1].isLastItemInGroup=!0)}),w.length>0&&(w[w.length-1].isLastItemInGroup=!1);const b=w.some(x=>"iconPathBefore"in x.item&&x.item.iconPathBefore);return{items:w,allowForLeadingIcons:b}},[o,t]),l=({item:u,isLastItemInGroup:f})=>({className:"papi-menu-item",label:u.label,tooltip:u.tooltip,iconPathBefore:"iconPathBefore"in u?u.iconPathBefore:void 0,iconPathAfter:"iconPathAfter"in u?u.iconPathAfter:void 0,hasDivider:f,allowForLeadingIcons:i}),[c]=s;if(!c)return a.jsx("div",{});const d=c.item.group;return a.jsx("div",{role:"menu","aria-label":d,children:s.map((u,f)=>{const{item:w}=u,b=l(u);if("command"in w){const x=w.group+f;return a.jsx(Lo,{onClick:m=>{n==null||n(m),r(w)},...b},x)}return a.jsx(Kf,{parentMenuItem:w,parentItemProps:b,...e},d+w.id)})},d)}function Zf(e){const{menuDefinition:t,columnId:n}=e;let s=Object.entries(t.groups).map(([i,l])=>({id:i,group:l})).filter(i=>"column"in i.group);return n&&"columns"in t&&t.columns[n]&&(s=s.filter(i=>"column"in i.group&&i.group.column===n)),a.jsx(Mi,{...e,includedGroups:s})}function Qf({commandHandler:e,menuDefinition:t,id:n,metadata:r,onClick:o,className:s}){return a.jsxs(Ie.Grid,{id:n,item:!0,xs:"auto",role:"menu","aria-label":n,className:`papi-menu-column ${s??""}`,children:[a.jsx("h3",{"aria-label":r.label,className:`papi-menu-column-header ${s??""}`,children:r.label}),a.jsx(Ie.List,{id:n,dense:!0,className:s??"",children:a.jsx(Zf,{commandHandler:e,menuDefinition:t,columnId:n,onClick:o})})]})}function $i({commandHandler:e,className:t,multiColumnMenu:n,id:r}){const{columns:o}=n,s=g.useMemo(()=>{const i=new Map;return Object.getOwnPropertyNames(o).forEach(l=>{if(l==="isExtensible")return;const c=l,d=o[c];typeof d=="object"&&typeof d.order=="number"&&!Number.isNaN(d.order)?i.set(d.order,{id:c,metadata:d}):console.warn(`Property ${l} (${typeof d}) on menu ${r} is not a valid column and is being ignored. This might indicate data corruption`)}),Array.from(i.values()).sort((l,c)=>(l.metadata.order||0)-(c.metadata.order||0))},[o,r]);return a.jsx(Ie.Grid,{container:!0,spacing:0,className:`papi-multi-column-menu ${t??""}`,columns:s.length,role:"menu","aria-label":"GridMenu",id:r,children:s.map((i,l)=>a.jsx(Qf,{commandHandler:e,menuDefinition:n,...i,className:t},l))})}function em(e){return{preserveValue:!0,...e}}const nr=(e,t,n={})=>{const r=g.useRef(t);r.current=t;const o=g.useRef(n);o.current=em(o.current);const[s,i]=g.useState(()=>r.current),[l,c]=g.useState(!0);return g.useEffect(()=>{let d=!0;return c(!!e),(async()=>{if(e){const u=await e();d&&(i(()=>u),c(!1))}})(),()=>{d=!1,o.current.preserveValue||i(()=>r.current)}},[e]),[s,l]},tm=wi(a.jsx("path",{d:"M3 18h18v-2H3zm0-5h18v-2H3zm0-7v2h18V6z"}),"Menu");function Ai({menuProvider:e,normalMenu:t,fullMenu:n,commandHandler:r,containerRef:o,className:s,ariaLabelPrefix:i,children:l}){const[c,d]=g.useState(!1),[u,f]=g.useState(!1),w=g.useCallback(()=>{c&&d(!1),f(!1)},[c]),b=g.useCallback(E=>{E.stopPropagation(),d(v=>{const _=!v;return _&&E.shiftKey?f(!0):_||f(!1),_})},[]),x=g.useCallback(E=>(w(),r(E)),[r,w]),[m,h]=g.useState({top:1,left:1});g.useEffect(()=>{if(c){const E=o==null?void 0:o.current;if(E){const v=E.getBoundingClientRect(),_=window.scrollY,V=window.scrollX,U=v.top+_+E.clientHeight,j=v.left+V;h({top:U,left:j})}}},[c,o]);const[k]=nr(g.useCallback(async()=>(e==null?void 0:e(!1))??t,[e,t,c]),t),[I]=nr(g.useCallback(async()=>(e==null?void 0:e(!0))??n??k,[e,n,k,c]),n??k),C=u&&I?I:k;return a.jsxs(a.Fragment,{children:[a.jsx(Ie.IconButton,{sx:{paddingTop:0,paddingBottom:0},edge:"start",className:`papi-menuButton ${s??""}`,color:"inherit","aria-label":`${i??""} menu button`,onClick:b,children:l??a.jsx(tm,{})}),a.jsx(Ie.Drawer,{className:`papi-menu-drawer ${s??""}`,anchor:"left",variant:"temporary",open:c,onClose:w,PaperProps:{className:"papi-menu-drawer-paper",style:{top:m.top,left:m.left}},children:C?a.jsx($i,{className:s,id:`${i??""} main menu`,commandHandler:x,multiColumnMenu:C}):void 0})]})}function nm({id:e,label:t,isDisabled:n=!1,tooltip:r,isTooltipSuppressed:o=!1,adjustMarginToAlignToEdge:s=!1,size:i="medium",className:l,onClick:c,children:d}){return a.jsx(Ie.IconButton,{id:e,disabled:n,edge:s,size:i,"aria-label":t,title:o?void 0:r??t,className:`papi-icon-button ${l??""}`,onClick:c,children:d})}const Wt=g.forwardRef(({className:e,...t},n)=>a.jsx(ee.LoaderCircle,{size:35,className:N("tw-animate-spin",e),...t,ref:n}));Wt.displayName="Spinner";function rm({id:e,isDisabled:t=!1,hasError:n=!1,isFullWidth:r=!1,helperText:o,label:s,placeholder:i,isRequired:l=!1,className:c,defaultValue:d,value:u,onChange:f,onFocus:w,onBlur:b}){return a.jsxs("div",{className:N("tw-inline-grid tw-items-center tw-gap-1.5",{"tw-w-full":r}),children:[a.jsx(Ue,{htmlFor:e,className:N({"tw-text-red-600":n,"tw-hidden":!s}),children:`${s}${l?"*":""}`}),a.jsx(St,{id:e,disabled:t,placeholder:i,required:l,className:N(c,{"tw-border-red-600":n}),defaultValue:d,value:u,onChange:f,onFocus:w,onBlur:b}),a.jsx("p",{className:N({"tw-hidden":!o}),children:o})]})}function om({menuProvider:e,commandHandler:t,className:n,id:r,children:o}){const s=g.useRef(void 0);return a.jsx("div",{ref:s,style:{position:"relative"},children:a.jsx(Ie.AppBar,{position:"static",id:r,children:a.jsxs(Ie.Toolbar,{className:N("tw-bg-muted tw-text-muted-foreground",n),variant:"dense",children:[e?a.jsx(Ai,{commandHandler:t,containerRef:s,menuProvider:e}):void 0,o?a.jsx("div",{className:"papi-toolbar-children",children:o}):void 0]})})})}const am=kn.cva("tw-relative tw-w-full tw-rounded-lg tw-border tw-p-4 [&>svg~*]:tw-pl-7 [&>svg+div]:tw-translate-y-[-3px] [&>svg]:tw-absolute [&>svg]:tw-left-4 [&>svg]:tw-top-4 [&>svg]:tw-text-foreground",{variants:{variant:{default:"tw-bg-background tw-text-foreground",destructive:"tw-border-destructive/50 tw-text-destructive dark:tw-border-destructive [&>svg]:tw-text-destructive"}},defaultVariants:{variant:"default"}}),Di=g.forwardRef(({className:e,variant:t,...n},r)=>a.jsx("div",{ref:r,role:"alert",className:N(am({variant:t}),e),...n}));Di.displayName="Alert";const Bi=g.forwardRef(({className:e,...t},n)=>a.jsxs("h5",{ref:n,className:N("tw-mb-1 tw-font-medium tw-leading-none tw-tracking-tight",e),...t,children:[t.children," "]}));Bi.displayName="AlertTitle";const Vi=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,className:N("tw-text-sm [&_p]:tw-leading-relaxed",e),...t}));Vi.displayName="AlertDescription";const zi=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,className:N("pr-twp tw-rounded-lg tw-border tw-bg-card tw-text-card-foreground tw-shadow-sm",e),...t}));zi.displayName="Card";const Li=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,className:N("pr-twp tw-flex tw-flex-col tw-space-y-1.5 tw-p-6",e),...t}));Li.displayName="CardHeader";const Fi=g.forwardRef(({className:e,...t},n)=>a.jsx("h3",{ref:n,className:N("pr-twp tw-text-2xl tw-font-semibold tw-leading-none tw-tracking-tight",e),...t,children:t.children}));Fi.displayName="CardTitle";const Gi=g.forwardRef(({className:e,...t},n)=>a.jsx("p",{ref:n,className:N("pr-twp tw-text-sm tw-text-muted-foreground",e),...t}));Gi.displayName="CardDescription";const Ui=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,className:N("pr-twp tw-p-6 tw-pt-0",e),...t}));Ui.displayName="CardContent";const qi=g.forwardRef(({className:e,...t},n)=>a.jsx("div",{ref:n,className:N("pr-twp tw-flex tw-items-center tw-p-6 tw-pt-0",e),...t}));qi.displayName="CardFooter";function sm({...e}){return a.jsx(Za.Toaster,{className:"tw-toaster tw-group",toastOptions:{classNames:{toast:"group toast group-[.toaster]:bg-background group-[.toaster]:text-foreground group-[.toaster]:border-border group-[.toaster]:shadow-lg",description:"group-[.toast]:text-muted-foreground",actionButton:"group-[.toast]:bg-primary group-[.toast]:text-primary-foreground",cancelButton:"group-[.toast]:bg-muted group-[.toast]:text-muted-foreground"}},...e})}const Hi=g.forwardRef(({className:e,...t},n)=>a.jsxs(ln.Root,{ref:n,className:N("pr-twp tw-relative tw-flex tw-w-full tw-touch-none tw-select-none tw-items-center",e),...t,children:[a.jsx(ln.Track,{className:"tw-relative tw-h-2 tw-w-full tw-grow tw-overflow-hidden tw-rounded-full tw-bg-secondary",children:a.jsx(ln.Range,{className:"tw-absolute tw-h-full tw-bg-primary"})}),a.jsx(ln.Thumb,{className:"tw-block tw-h-5 tw-w-5 tw-rounded-full tw-border-2 tw-border-primary tw-bg-background tw-ring-offset-background tw-transition-colors focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50"})]}));Hi.displayName=ln.Root.displayName;const Xi=g.forwardRef(({className:e,...t},n)=>a.jsx(Ur.Root,{className:N("tw-peer pr-twp tw-inline-flex tw-h-6 tw-w-11 tw-shrink-0 tw-cursor-pointer tw-items-center tw-rounded-full tw-border-2 tw-border-transparent tw-transition-colors focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 focus-visible:tw-ring-offset-background disabled:tw-cursor-not-allowed disabled:tw-opacity-50 data-[state=checked]:tw-bg-primary data-[state=unchecked]:tw-bg-input",e),...t,ref:n,children:a.jsx(Ur.Thumb,{className:N("pr-twp tw-pointer-events-none tw-block tw-h-5 tw-w-5 tw-rounded-full tw-bg-background tw-shadow-lg tw-ring-0 tw-transition-transform data-[state=checked]:tw-translate-x-5 data-[state=unchecked]:tw-translate-x-0")})}));Xi.displayName=Ur.Root.displayName;const im=Re.Root,Yi=g.forwardRef(({className:e,...t},n)=>a.jsx(Re.List,{ref:n,className:N("tw-inline-flex tw-h-10 tw-items-center tw-justify-center tw-rounded-md tw-bg-muted tw-p-1 tw-text-muted-foreground",e),...t}));Yi.displayName=Re.List.displayName;const Wi=g.forwardRef(({className:e,...t},n)=>a.jsx(Re.Trigger,{ref:n,className:N("tw-inline-flex tw-items-center tw-justify-center tw-whitespace-nowrap tw-rounded-sm tw-px-3 tw-py-1.5 tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-all hover:tw-text-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50 data-[state=active]:tw-bg-background data-[state=active]:tw-text-foreground data-[state=active]:tw-shadow-sm",e),...t}));Wi.displayName=Re.Trigger.displayName;const Ki=g.forwardRef(({className:e,...t},n)=>a.jsx(Re.Content,{ref:n,className:N("tw-mt-2 tw-ring-offset-background focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2",e),...t}));Ki.displayName=Re.Content.displayName;function lm({isInstalling:e,handleClick:t,buttonText:n,className:r,...o}){return a.jsx(fe,{className:N("tw-h-8 tw-rounded-md tw-text-white tw-transition tw-duration-300 tw-ease-in-out hover:tw-bg-blue-700",{"tw-cursor-not-allowed tw-bg-blue-700":e,"tw-bg-blue-600":!e,"tw-bg-white tw-text-blue-600 hover:tw-text-white":!n,"tw-w-20":n},r),onClick:t,...o,children:e?a.jsx(Wt,{size:15}):a.jsxs(a.Fragment,{children:[a.jsx(ee.Download,{size:25,className:N("tw-h-4 tw-w-4",{"tw-mr-1":n})}),n]})})}function cm({isEnabling:e,handleClick:t,className:n,...r}){return a.jsx(fe,{className:N("tw-h-8 tw-rounded-md tw-bg-blue-600 tw-px-4 tw-text-white tw-transition tw-duration-300 tw-ease-in-out hover:tw-bg-blue-700",{"tw-cursor-not-allowed tw-bg-blue-700":e},n),onClick:t,...r,children:e?a.jsxs(a.Fragment,{children:[a.jsx(Wt,{size:15,className:"tw-mr-1 tw-text-white"}),"Enabling..."]}):"Enable"})}function dm({isDisabling:e,handleClick:t,className:n,...r}){return a.jsx(fe,{className:N("tw-h-8 tw-rounded-md tw-bg-gray-300 tw-text-black tw-transition tw-duration-300 tw-ease-in-out hover:tw-bg-gray-400",{"tw-cursor-not-allowed tw-bg-gray-400":e},n),onClick:t,...r,children:e?a.jsxs(a.Fragment,{children:[a.jsx(Wt,{size:15,className:"tw-mr-1 tw-text-black"}),"Disabling..."]}):"Disable"})}function um({isUpdating:e,handleClick:t,className:n,...r}){return a.jsx(fe,{className:N("tw-h-8 tw-rounded-md tw-bg-blue-600 tw-px-4 tw-text-white tw-transition tw-duration-300 tw-ease-in-out hover:tw-bg-blue-700 hover:tw-text-white",{"tw-cursor-not-allowed tw-bg-blue-700":e},n),onClick:t,...r,children:e?a.jsxs(a.Fragment,{children:[a.jsx(Wt,{size:15,className:"tw-mr-1 tw-text-white"}),"Updating..."]}):"Update"})}function pm({id:e,markdown:t,className:n,anchorTarget:r}){const o=g.useMemo(()=>({overrides:{a:{props:{target:r}}}}),[r]);return a.jsx("div",{id:e,className:N("pr-twp tw-prose",n),children:a.jsx(jl,{options:o,children:t})})}const Ji=g.forwardRef((e,t)=>a.jsxs(fe,{ref:t,className:"tw-rounded-md tw-border tw-border-dashed tw-border-gray-400 tw-bg-white tw-px-4 tw-py-2 tw-text-black tw-transition tw-duration-300 tw-ease-in-out hover:tw-border-blue-600 hover:tw-bg-white hover:tw-text-blue-600",...e,children:[a.jsx(ee.Filter,{size:16,className:"tw-mr-2 tw-h-4 tw-w-4 tw-text-gray-700 hover:tw-text-blue-600"}),"Filter",a.jsx(ee.ChevronDown,{size:16,className:"tw-ml-2 tw-h-4 tw-w-4 tw-text-gray-700 hover:tw-text-blue-600"})]}));var Zi=(e=>(e[e.Check=0]="Check",e[e.Radio=1]="Radio",e))(Zi||{});function wm({id:e,groups:t}){return a.jsx("div",{id:e,children:a.jsxs(or,{children:[a.jsx(io,{asChild:!0,children:a.jsx(Ji,{})}),a.jsx(En,{children:t.map(n=>a.jsxs("div",{children:[a.jsx(Yt,{children:n.label}),a.jsx(ls,{children:n.items.map(r=>a.jsx("div",{children:r.itemType===0?a.jsx(ar,{onClick:r.onClick,children:r.label}):a.jsx(co,{onClick:r.onClick,value:r.label,children:r.label})},r.label))}),a.jsx(jn,{})]},n.label))})]})})}function fm({id:e,message:t}){return a.jsx("div",{id:e,className:"tw-mb-20 tw-mt-20 tw-flex tw-items-center tw-justify-center",children:a.jsx("div",{className:"tw-w-3/4 tw-rounded-lg tw-bg-gray-100 tw-p-8 tw-text-center",children:a.jsx("p",{className:"tw-text-lg tw-text-gray-800",children:t})})})}function mm({id:e,category:t,downloads:n,languages:r,moreInfoUrl:o}){const s=new W.NumberFormat("en",{notation:"compact",compactDisplay:"short"}).format(Object.values(n).reduce((l,c)=>l+c,0)),i=()=>{window.scrollTo(0,document.body.scrollHeight)};return a.jsxs("div",{id:e,className:"tw-flex tw-flex-wrap tw-items-start tw-space-x-4 tw-border-b tw-border-t tw-bg-white tw-pb-4 tw-pt-4",children:[a.jsxs("div",{className:"tw-flex tw-flex-col tw-items-center",children:[a.jsx("div",{className:"tw-flex tw-items-center tw-rounded-md tw-bg-gray-100 tw-px-2 tw-py-1",children:a.jsx("span",{className:"tw-text-xs tw-font-semibold tw-text-gray-700",children:t})}),a.jsx("span",{className:"tw-text-xs tw-text-gray-500",children:"CATEGORY"})]}),a.jsx("div",{className:"tw-mx-2 tw-h-10 tw-border-l tw-border-gray-300"}),a.jsxs("div",{className:"tw-flex tw-flex-col tw-items-center",children:[a.jsxs("div",{className:"tw-flex tw-items-center tw-rounded-md tw-bg-gray-100 tw-px-2 tw-py-1",children:[a.jsx(ee.User,{className:"tw-mr-1 tw-h-4 tw-w-4"}),a.jsx("span",{className:"tw-text-xs tw-font-semibold tw-text-gray-700",children:s})]}),a.jsx("span",{className:"tw-text-xs tw-text-gray-500",children:"USERS"})]}),a.jsx("div",{className:"tw-mx-2 tw-h-10 tw-border-l tw-border-gray-300"}),a.jsxs("div",{className:"tw-flex tw-flex-col tw-items-center",children:[a.jsx("div",{className:"tw-flex tw-items-center",children:r.slice(0,3).map(l=>a.jsx("span",{className:"tw-ml-1 tw-rounded-md tw-bg-gray-100 tw-px-2 tw-py-1 tw-text-xs tw-font-semibold tw-text-gray-700",children:l.toUpperCase()},l))}),r.length>3&&a.jsxs("button",{type:"button",onClick:()=>i(),className:"tw-text-xs tw-text-gray-500 tw-underline",children:["+",r.length-3," more languages"]})]}),a.jsx("div",{className:"tw-mx-2 tw-h-10 tw-border-l tw-border-gray-300"}),a.jsxs("div",{className:"tw-ml-auto tw-flex tw-flex-col tw-space-y-2",children:[a.jsxs("a",{href:o,target:"_blank",rel:"noreferrer",className:"tw-flex tw-items-center tw-text-xs tw-font-semibold tw-text-gray-500 tw-underline",children:["Website",a.jsx(ee.Link,{className:"tw-ml-1 tw-inline tw-h-4 tw-w-4"})]}),a.jsxs("a",{href:"https://example.com",target:"_blank",rel:"noreferrer",className:"tw-flex tw-items-center tw-text-xs tw-font-semibold tw-text-gray-500 tw-underline",children:["Support",a.jsx(ee.CircleHelp,{className:"tw-ml-1 tw-inline tw-h-4 tw-w-4"})]})]})]})}function Qi({id:e,versionHistory:t}){const[n,r]=g.useState(!1),o=new Date;function s(l){const c=new Date(l),d=new Date(o.getTime()-c.getTime()),u=d.getUTCFullYear()-1970,f=d.getUTCMonth(),w=d.getUTCDate()-1;let b="";return u>0?b=`${u.toString()} year${u===1?"":"s"} ago`:f>0?b=`${f.toString()} month${f===1?"":"s"} ago`:w===0?b="today":b=`${w.toString()} day${w===1?"":"s"} ago`,b}const i=Object.entries(t).sort((l,c)=>c[0].localeCompare(l[0]));return a.jsxs("div",{id:e,children:[a.jsx("h3",{className:"tw-text-md tw-font-semibold",children:"What`s New"}),a.jsx("ul",{className:"tw-list-disc tw-pl-5 tw-pr-4 tw-text-xs tw-text-gray-600",children:(n?i:i.slice(0,5)).map(l=>a.jsxs("div",{className:"tw-mt-3 tw-flex tw-justify-between",children:[a.jsx("div",{className:"tw-text-gray-600",children:a.jsx("li",{className:"tw-prose tw-text-xs",children:a.jsx("span",{children:l[1].description})})}),a.jsxs("div",{className:"tw-justify-end tw-text-right",children:[a.jsxs("div",{children:["Version ",l[0]]}),a.jsx("div",{children:s(l[1].date)})]})]},l[0]))}),i.length>5&&a.jsx("button",{type:"button",onClick:()=>r(!n),className:"tw-text-xs tw-text-gray-500 tw-underline",children:n?"Show Less Version History":"Show All Version History"})]})}function hm({id:e,publisherDisplayName:t,fileSize:n,locales:r,versionHistory:o}){const s=g.useMemo(()=>W.formatBytes(n),[n]),l=(c=>{const d=new Intl.DisplayNames(navigator.language,{type:"language"});return c.map(u=>d.of(u))})(r);return a.jsx("div",{id:e,className:"tw-border-t tw-pb-4 tw-pt-4",children:a.jsxs("div",{className:"tw-md:flex-row tw-md:space-x-8 tw-flex tw-flex-col tw-space-x-0",children:[a.jsx(Qi,{versionHistory:o}),a.jsx("div",{className:"tw-md:border-t-0 tw-md:border-l tw-md-h-auto tw-md-ml-8 tw-mt-4 tw-border-t tw-border-gray-300"}),a.jsxs("div",{className:"tw-md:mt-0 tw-mt-4 tw-flex-1 tw-space-y-3",children:[a.jsx("h2",{className:"tw-text-md tw-font-semibold",children:"Information"}),a.jsxs("div",{className:"tw-flex tw-items-start tw-justify-between tw-pr-4 tw-text-xs tw-text-gray-600",children:[a.jsxs("p",{className:"tw-flex tw-flex-col tw-justify-start",children:[a.jsx("span",{className:"tw-mb-2",children:"Publisher"}),a.jsx("span",{className:"tw-font-semibold",children:t}),a.jsx("span",{className:"tw-mb-2 tw-mt-4",children:"Size"}),a.jsx("span",{className:"tw-font-semibold",children:s})]}),a.jsx("div",{className:"tw-flex tw-w-3/4 tw-items-center tw-justify-between tw-text-xs tw-text-gray-600",children:a.jsxs("p",{className:"tw-flex tw-flex-col tw-justify-start",children:[a.jsx("span",{className:"tw-mb-2",children:"Languages"}),a.jsx("span",{className:"tw-font-semibold",children:l.join(", ")})]})})]})]})]})})}const gm=(e,t)=>{g.useEffect(()=>{if(!e)return()=>{};const n=e(t);return()=>{n()}},[e,t])},Lr=()=>!1,bm=(e,t)=>{const[n]=nr(g.useCallback(async()=>{if(!e)return Lr;const r=await Promise.resolve(e(t));return async()=>r()},[t,e]),Lr,{preserveValue:!1});g.useEffect(()=>()=>{n!==Lr&&n()},[n])};Object.defineProperty(exports,"sonner",{enumerable:!0,get:()=>Za.toast});exports.Alert=Di;exports.AlertDescription=Vi;exports.AlertTitle=Bi;exports.BOOK_SELECTOR_STRING_KEYS=pc;exports.BookChapterControl=tc;exports.BookSelectionMode=ys;exports.BookSelector=wc;exports.Button=fe;exports.Card=zi;exports.CardContent=Ui;exports.CardDescription=Gi;exports.CardFooter=qi;exports.CardHeader=Li;exports.CardTitle=Fi;exports.ChapterRangeSelector=xs;exports.Checkbox=sr;exports.Checklist=ad;exports.ComboBox=Wn;exports.DataTable=Ts;exports.DisableButton=dm;exports.DropdownMenu=or;exports.DropdownMenuCheckboxItem=ar;exports.DropdownMenuContent=En;exports.DropdownMenuGroup=ls;exports.DropdownMenuItem=lo;exports.DropdownMenuItemType=Zi;exports.DropdownMenuLabel=Yt;exports.DropdownMenuPortal=Fl;exports.DropdownMenuRadioGroup=Ul;exports.DropdownMenuRadioItem=co;exports.DropdownMenuSeparator=jn;exports.DropdownMenuShortcut=us;exports.DropdownMenuSub=Gl;exports.DropdownMenuSubContent=ds;exports.DropdownMenuSubTrigger=cs;exports.DropdownMenuTrigger=io;exports.EnableButton=cm;exports.FilterButton=Ji;exports.FilterDropdown=wm;exports.Footer=hm;exports.GridMenu=$i;exports.HamburgerMenuButton=Ai;exports.INVENTORY_STRING_KEYS=Nc;exports.IconButton=nm;exports.Input=St;exports.InstallButton=lm;exports.Inventory=Ec;exports.Label=Ue;exports.MarkdownRenderer=pm;exports.MenuItem=Lo;exports.MoreInfo=mm;exports.NavigationContentSearch=jc;exports.NoExtensionsFound=fm;exports.RadioGroup=uo;exports.RadioGroupItem=Yn;exports.ScriptureResultsViewer=ed;exports.ScrollGroupSelector=td;exports.SearchBar=mo;exports.Select=Dt;exports.SelectContent=vt;exports.SelectGroup=Ns;exports.SelectItem=Ae;exports.SelectLabel=ks;exports.SelectScrollDownButton=wo;exports.SelectScrollUpButton=po;exports.SelectSeparator=Ss;exports.SelectTrigger=bt;exports.SelectValue=Bt;exports.Separator=lr;exports.SettingsList=nd;exports.SettingsListHeader=od;exports.SettingsListItem=rd;exports.SettingsSidebar=Gs;exports.SettingsSidebarContentSearch=Hc;exports.Slider=Hi;exports.Sonner=sm;exports.Spinner=Wt;exports.Switch=Xi;exports.Table=Tn;exports.TableBody=Rn;exports.TableCaption=js;exports.TableCell=xt;exports.TableFooter=Es;exports.TableHead=Vt;exports.TableHeader=Cn;exports.TableRow=Ze;exports.Tabs=im;exports.TabsContent=Ki;exports.TabsList=Yi;exports.TabsTrigger=Wi;exports.TextField=rm;exports.ToggleGroup=fo;exports.ToggleGroupItem=wn;exports.Toolbar=om;exports.UpdateButton=um;exports.VersionHistory=Qi;exports.VerticalTabs=ho;exports.VerticalTabsContent=bo;exports.VerticalTabsList=go;exports.VerticalTabsTrigger=Is;exports.buttonVariants=ps;exports.cn=N;exports.getBookNumFromId=Rs;exports.getLinesFromUSFM=Cs;exports.getNumberFromUSFM=qr;exports.getStatusForItem=Os;exports.inventoryCountColumn=xc;exports.inventoryItemColumn=bc;exports.inventoryStatusColumn=yc;exports.useEvent=gm;exports.useEventAsync=bm;exports.usePromise=nr;function vm(e,t="top"){if(!e||typeof document>"u")return;const n=document.head||document.querySelector("head"),r=n.querySelector(":first-child"),o=document.createElement("style");o.appendChild(document.createTextNode(e)),t==="top"&&r?n.insertBefore(o,r):n.appendChild(o)}vm(`*, ::before, ::after { --tw-border-spacing-x: 0; --tw-border-spacing-y: 0; --tw-translate-x: 0; @@ -2520,7 +2520,7 @@ video:where(.pr-twp,.pr-twp *) { animation-timing-function: linear; } -/* #region shared with https://github.com/paranext/paranext-extension-template/blob/main/tailwind.css */ +/* #region shared with https://github.com/paranext/paranext-extension-template/blob/main/src/tailwind.css */ /* #endregion */ @@ -3516,12 +3516,31 @@ video:where(.pr-twp,.pr-twp *) { [data-side=right] .\\[\\[data-side\\=right\\]_\\&\\]\\:tw-cursor-e-resize { cursor: e-resize; } -.banded-row:hover { +.papi-icon-button { + border: 0; + border-radius: 3em; cursor: pointer; + display: inline-block; } -.banded-row[data-state='selected']:hover { - cursor: default; +.papi-icon-button.primary { + background-color: #1ea7fd; + color: white; +} + +.papi-icon-button.secondary { + background-color: transparent; + color: #333; +} + +.papi-icon-button.paratext { + background-color: darkgreen; + color: greenyellow; +} + +.papi-icon-button.paratext.bright { + background-color: greenyellow; + color: darkgreen; } .papi-multi-column-menu { background-color: rgb(222, 222, 222); @@ -3557,31 +3576,22 @@ video:where(.pr-twp,.pr-twp *) { color: rgb(76, 106, 76); background-color: rgb(214, 255, 152); } -.papi-icon-button { - border: 0; - border-radius: 3em; +.banded-row:hover { cursor: pointer; - display: inline-block; -} - -.papi-icon-button.primary { - background-color: #1ea7fd; - color: white; } -.papi-icon-button.secondary { - background-color: transparent; - color: #333; +.banded-row[data-state='selected']:hover { + cursor: default; } - -.papi-icon-button.paratext { - background-color: darkgreen; - color: greenyellow; +.papi-menu-drawer-paper { + height: fit-content !important; + position: absolute !important; } -.papi-icon-button.paratext.bright { - background-color: greenyellow; - color: darkgreen; +.papi-toolbar-children { + padding: 10px; + display: flex; + gap: 8px; } .papi-menu-item { background-color: transparent; @@ -3596,15 +3606,5 @@ video:where(.pr-twp,.pr-twp *) { max-width: 24px; max-height: 24px; } -.papi-menu-drawer-paper { - height: fit-content !important; - position: absolute !important; -} - -.papi-toolbar-children { - padding: 10px; - display: flex; - gap: 8px; -} `,"top"); //# sourceMappingURL=index.cjs.map diff --git a/lib/platform-bible-react/dist/index.cjs.map b/lib/platform-bible-react/dist/index.cjs.map index 902d5fa2d6..655888eca7 100644 --- a/lib/platform-bible-react/dist/index.cjs.map +++ b/lib/platform-bible-react/dist/index.cjs.map @@ -1 +1 @@ -{"version":3,"file":"index.cjs","sources":["../src/utils/shadcn-ui.util.ts","../src/components/shadcn-ui/input.tsx","../src/components/advanced/book-chapter-control/book-chapter-input.component.tsx","../../../node_modules/@sillsdev/scripture/dist/index.es.js","../src/components/shadcn-ui/dropdown-menu.tsx","../src/components/advanced/book-chapter-control/book-menu-item.component.tsx","../src/components/advanced/book-chapter-control/chapter-select.component.tsx","../src/components/advanced/book-chapter-control/go-to-menu-item.component.tsx","../src/components/advanced/book-chapter-control/book-chapter-control.component.tsx","../src/components/shadcn-ui/button.tsx","../src/components/shadcn-ui/label.tsx","../src/components/shadcn-ui/radio-group.tsx","../src/components/shadcn-ui/popover.tsx","../src/components/shadcn-ui/dialog.tsx","../src/components/shadcn-ui/command.tsx","../src/components/basics/combo-box.component.tsx","../src/components/basics/chapter-range-selector.component.tsx","../src/components/advanced/book-selector.component.tsx","../src/components/advanced/data-table/data-table-column-toggle.component.tsx","../src/components/shadcn-ui/select.tsx","../src/components/advanced/data-table/data-table-pagination.component.tsx","../src/components/shadcn-ui/table.tsx","../src/components/advanced/data-table/data-table.component.tsx","../src/components/advanced/inventory/occurrences-table.component.tsx","../src/components/shadcn-ui/checkbox.tsx","../src/components/advanced/inventory/inventory-utils.ts","../src/components/shadcn-ui/toggle.tsx","../src/components/shadcn-ui/toggle-group.tsx","../src/components/advanced/inventory/inventory-columns.tsx","../src/components/advanced/inventory/inventory.component.tsx","../src/components/basics/search-bar.component.tsx","../src/components/basics/tabs-vertical.tsx","../src/components/advanced/tab-navigation-content-search.component.tsx","../src/components/shadcn-ui/separator.tsx","../src/components/shadcn-ui/skeleton.tsx","../src/components/shadcn-ui/tooltip.tsx","../src/components/shadcn-ui/sidebar.tsx","../src/components/advanced/settings-components/settings-sidebar.component.tsx","../src/components/advanced/settings-components/settings-sidebar-content-search.component.tsx","../src/components/advanced/scripture-results-viewer/scripture-results-viewer.component.tsx","../src/components/advanced/scroll-group-selector.component.tsx","../src/components/advanced/settings-components/settings-list.component.tsx","../src/components/basics/checklist.component.tsx","../../../node_modules/@babel/runtime/helpers/interopRequireDefault.js","../../../node_modules/@mui/utils/chainPropTypes/chainPropTypes.js","../../../node_modules/@babel/runtime/helpers/esm/extends.js","../../../node_modules/@mui/utils/deepmerge/deepmerge.js","../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.production.min.js","../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.development.js","../../../node_modules/prop-types/node_modules/react-is/index.js","../../../node_modules/object-assign/index.js","../../../node_modules/prop-types/lib/ReactPropTypesSecret.js","../../../node_modules/prop-types/lib/has.js","../../../node_modules/prop-types/checkPropTypes.js","../../../node_modules/prop-types/factoryWithTypeCheckers.js","../../../node_modules/prop-types/factoryWithThrowingShims.js","../../../node_modules/prop-types/index.js","../../../node_modules/@mui/utils/elementAcceptingRef/elementAcceptingRef.js","../../../node_modules/@mui/utils/exactProp/exactProp.js","../../../node_modules/@mui/utils/formatMuiErrorMessage/formatMuiErrorMessage.js","../../../node_modules/react-is/cjs/react-is.production.min.js","../../../node_modules/react-is/cjs/react-is.development.js","../../../node_modules/react-is/index.js","../../../node_modules/@mui/utils/getDisplayName/getDisplayName.js","../../../node_modules/@mui/utils/HTMLElementType/HTMLElementType.js","../../../node_modules/@mui/utils/refType/refType.js","../../../node_modules/@mui/utils/capitalize/capitalize.js","../../../node_modules/@mui/utils/createChainedFunction/createChainedFunction.js","../../../node_modules/@mui/utils/debounce/debounce.js","../../../node_modules/@mui/utils/deprecatedPropType/deprecatedPropType.js","../../../node_modules/@mui/utils/isMuiElement/isMuiElement.js","../../../node_modules/@mui/utils/ownerDocument/ownerDocument.js","../../../node_modules/@mui/utils/ownerWindow/ownerWindow.js","../../../node_modules/@mui/utils/requirePropFactory/requirePropFactory.js","../../../node_modules/@mui/utils/setRef/setRef.js","../../../node_modules/@mui/utils/useEnhancedEffect/useEnhancedEffect.js","../../../node_modules/@mui/utils/useId/useId.js","../../../node_modules/@mui/utils/unsupportedProp/unsupportedProp.js","../../../node_modules/@mui/utils/useControlled/useControlled.js","../../../node_modules/@mui/utils/useEventCallback/useEventCallback.js","../../../node_modules/@mui/utils/useForkRef/useForkRef.js","../../../node_modules/@mui/utils/useLazyRef/useLazyRef.js","../../../node_modules/@mui/utils/useOnMount/useOnMount.js","../../../node_modules/@mui/utils/useTimeout/useTimeout.js","../../../node_modules/@mui/utils/useIsFocusVisible/useIsFocusVisible.js","../../../node_modules/@mui/utils/resolveProps/resolveProps.js","../../../node_modules/@mui/utils/composeClasses/composeClasses.js","../../../node_modules/@mui/utils/ClassNameGenerator/ClassNameGenerator.js","../../../node_modules/@mui/utils/generateUtilityClass/generateUtilityClass.js","../../../node_modules/@mui/utils/generateUtilityClasses/generateUtilityClasses.js","../../../node_modules/@mui/utils/clamp/clamp.js","../../../node_modules/@babel/runtime/helpers/esm/objectWithoutPropertiesLoose.js","../../../node_modules/@mui/system/esm/createTheme/createBreakpoints.js","../../../node_modules/@mui/system/esm/createTheme/shape.js","../../../node_modules/@mui/system/esm/responsivePropType.js","../../../node_modules/@mui/system/esm/merge.js","../../../node_modules/@mui/system/esm/breakpoints.js","../../../node_modules/@mui/system/esm/style.js","../../../node_modules/@mui/system/esm/memoize.js","../../../node_modules/@mui/system/esm/spacing.js","../../../node_modules/@mui/system/esm/createTheme/createSpacing.js","../../../node_modules/@mui/system/esm/compose.js","../../../node_modules/@mui/system/esm/borders.js","../../../node_modules/@mui/system/esm/cssGrid.js","../../../node_modules/@mui/system/esm/palette.js","../../../node_modules/@mui/system/esm/sizing.js","../../../node_modules/@mui/system/esm/styleFunctionSx/defaultSxConfig.js","../../../node_modules/@mui/system/esm/styleFunctionSx/styleFunctionSx.js","../../../node_modules/@mui/system/esm/createTheme/applyStyles.js","../../../node_modules/@mui/system/esm/createTheme/createTheme.js","../../../node_modules/@mui/system/esm/useThemeWithoutDefault.js","../../../node_modules/@mui/system/esm/useTheme.js","../../../node_modules/@mui/system/esm/createStyled.js","../../../node_modules/@mui/system/esm/useThemeProps/getThemeProps.js","../../../node_modules/@mui/system/esm/useThemeProps/useThemeProps.js","../../../node_modules/@mui/system/esm/colorManipulator.js","../../../node_modules/@mui/material/styles/createMixins.js","../../../node_modules/@mui/material/colors/common.js","../../../node_modules/@mui/material/colors/grey.js","../../../node_modules/@mui/material/colors/purple.js","../../../node_modules/@mui/material/colors/red.js","../../../node_modules/@mui/material/colors/orange.js","../../../node_modules/@mui/material/colors/blue.js","../../../node_modules/@mui/material/colors/lightBlue.js","../../../node_modules/@mui/material/colors/green.js","../../../node_modules/@mui/material/styles/createPalette.js","../../../node_modules/@mui/material/styles/createTypography.js","../../../node_modules/@mui/material/styles/shadows.js","../../../node_modules/@mui/material/styles/createTransitions.js","../../../node_modules/@mui/material/styles/zIndex.js","../../../node_modules/@mui/material/styles/createTheme.js","../../../node_modules/@mui/material/styles/defaultTheme.js","../../../node_modules/@mui/material/styles/identifier.js","../../../node_modules/@mui/material/styles/useThemeProps.js","../../../node_modules/@mui/material/styles/styled.js","../../../node_modules/@mui/material/SvgIcon/svgIconClasses.js","../../../node_modules/@mui/material/SvgIcon/SvgIcon.js","../../../node_modules/@mui/material/utils/createSvgIcon.js","../../../node_modules/@mui/material/utils/index.js","../../../node_modules/@mui/icons-material/utils/createSvgIcon.js","../../../node_modules/@mui/icons-material/ArrowRight.js","../../../node_modules/@mui/base/utils/isHostComponent.js","../../../node_modules/@mui/base/utils/appendOwnerState.js","../../../node_modules/@mui/base/utils/ClassNameConfigurator.js","../../../node_modules/@mui/base/utils/extractEventHandlers.js","../../../node_modules/@mui/base/utils/resolveComponentProps.js","../../../node_modules/@mui/base/utils/omitEventHandlers.js","../../../node_modules/@mui/base/utils/mergeSlotProps.js","../../../node_modules/@mui/base/utils/useSlotProps.js","../../../node_modules/@mui/base/generateUtilityClass/index.js","../../../node_modules/@mui/base/generateUtilityClasses/index.js","../../../node_modules/@mui/base/Portal/Portal.js","../../../node_modules/@popperjs/core/lib/enums.js","../../../node_modules/@popperjs/core/lib/dom-utils/getNodeName.js","../../../node_modules/@popperjs/core/lib/dom-utils/getWindow.js","../../../node_modules/@popperjs/core/lib/dom-utils/instanceOf.js","../../../node_modules/@popperjs/core/lib/modifiers/applyStyles.js","../../../node_modules/@popperjs/core/lib/utils/getBasePlacement.js","../../../node_modules/@popperjs/core/lib/utils/math.js","../../../node_modules/@popperjs/core/lib/utils/userAgent.js","../../../node_modules/@popperjs/core/lib/dom-utils/isLayoutViewport.js","../../../node_modules/@popperjs/core/lib/dom-utils/getBoundingClientRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/getLayoutRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/contains.js","../../../node_modules/@popperjs/core/lib/dom-utils/getComputedStyle.js","../../../node_modules/@popperjs/core/lib/dom-utils/isTableElement.js","../../../node_modules/@popperjs/core/lib/dom-utils/getDocumentElement.js","../../../node_modules/@popperjs/core/lib/dom-utils/getParentNode.js","../../../node_modules/@popperjs/core/lib/dom-utils/getOffsetParent.js","../../../node_modules/@popperjs/core/lib/utils/getMainAxisFromPlacement.js","../../../node_modules/@popperjs/core/lib/utils/within.js","../../../node_modules/@popperjs/core/lib/utils/getFreshSideObject.js","../../../node_modules/@popperjs/core/lib/utils/mergePaddingObject.js","../../../node_modules/@popperjs/core/lib/utils/expandToHashMap.js","../../../node_modules/@popperjs/core/lib/modifiers/arrow.js","../../../node_modules/@popperjs/core/lib/utils/getVariation.js","../../../node_modules/@popperjs/core/lib/modifiers/computeStyles.js","../../../node_modules/@popperjs/core/lib/modifiers/eventListeners.js","../../../node_modules/@popperjs/core/lib/utils/getOppositePlacement.js","../../../node_modules/@popperjs/core/lib/utils/getOppositeVariationPlacement.js","../../../node_modules/@popperjs/core/lib/dom-utils/getWindowScroll.js","../../../node_modules/@popperjs/core/lib/dom-utils/getWindowScrollBarX.js","../../../node_modules/@popperjs/core/lib/dom-utils/getViewportRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/getDocumentRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/isScrollParent.js","../../../node_modules/@popperjs/core/lib/dom-utils/getScrollParent.js","../../../node_modules/@popperjs/core/lib/dom-utils/listScrollParents.js","../../../node_modules/@popperjs/core/lib/utils/rectToClientRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/getClippingRect.js","../../../node_modules/@popperjs/core/lib/utils/computeOffsets.js","../../../node_modules/@popperjs/core/lib/utils/detectOverflow.js","../../../node_modules/@popperjs/core/lib/utils/computeAutoPlacement.js","../../../node_modules/@popperjs/core/lib/modifiers/flip.js","../../../node_modules/@popperjs/core/lib/modifiers/hide.js","../../../node_modules/@popperjs/core/lib/modifiers/offset.js","../../../node_modules/@popperjs/core/lib/modifiers/popperOffsets.js","../../../node_modules/@popperjs/core/lib/utils/getAltAxis.js","../../../node_modules/@popperjs/core/lib/modifiers/preventOverflow.js","../../../node_modules/@popperjs/core/lib/dom-utils/getHTMLElementScroll.js","../../../node_modules/@popperjs/core/lib/dom-utils/getNodeScroll.js","../../../node_modules/@popperjs/core/lib/dom-utils/getCompositeRect.js","../../../node_modules/@popperjs/core/lib/utils/orderModifiers.js","../../../node_modules/@popperjs/core/lib/utils/debounce.js","../../../node_modules/@popperjs/core/lib/utils/mergeByName.js","../../../node_modules/@popperjs/core/lib/createPopper.js","../../../node_modules/@popperjs/core/lib/popper.js","../../../node_modules/@mui/base/Popper/popperClasses.js","../../../node_modules/@mui/base/Popper/Popper.js","../../../node_modules/@mui/material/styles/useTheme.js","../../../node_modules/@babel/runtime/helpers/esm/setPrototypeOf.js","../../../node_modules/@babel/runtime/helpers/esm/inheritsLoose.js","../../../node_modules/react-transition-group/esm/config.js","../../../node_modules/react-transition-group/esm/utils/PropTypes.js","../../../node_modules/react-transition-group/esm/TransitionGroupContext.js","../../../node_modules/react-transition-group/esm/utils/reflow.js","../../../node_modules/react-transition-group/esm/Transition.js","../../../node_modules/@mui/material/transitions/utils.js","../../../node_modules/@mui/material/Grow/Grow.js","../../../node_modules/@mui/material/Popper/Popper.js","../../../node_modules/@mui/material/Tooltip/tooltipClasses.js","../../../node_modules/@mui/material/Tooltip/Tooltip.js","../src/components/mui/menu-item.component.tsx","../src/components/mui/grouped-menu-item-list.component.tsx","../src/components/mui/top-level-menu.component.tsx","../src/components/mui/grid-menu.component.tsx","../src/hooks/use-promise.hook.ts","../../../node_modules/@mui/icons-material/esm/Menu.js","../src/components/mui/hamburger-menu-button.component.tsx","../src/components/mui/icon-button.component.tsx","../src/components/basics/spinner.component.tsx","../src/components/basics/text-field.component.tsx","../src/components/mui/toolbar.component.tsx","../src/components/shadcn-ui/alert.tsx","../src/components/shadcn-ui/card.tsx","../src/components/shadcn-ui/sonner.tsx","../src/components/shadcn-ui/slider.tsx","../src/components/shadcn-ui/switch.tsx","../src/components/shadcn-ui/tabs.tsx","../src/components/advanced/extension-marketplace/buttons/install-button.component.tsx","../src/components/advanced/extension-marketplace/buttons/enable-button.component.tsx","../src/components/advanced/extension-marketplace/buttons/disable-button.component.tsx","../src/components/advanced/extension-marketplace/buttons/update-button.component.tsx","../src/components/advanced/extension-marketplace/markdown-renderer.component.tsx","../src/components/advanced/extension-marketplace/buttons/filter-button.component.tsx","../src/components/advanced/extension-marketplace/filter-dropdown.component.tsx","../src/components/advanced/extension-marketplace/no-extensions-found.component.tsx","../src/components/advanced/extension-marketplace/more-info.component.tsx","../src/components/advanced/extension-marketplace/version-history.component.tsx","../src/components/advanced/extension-marketplace/footer.component.tsx","../src/hooks/use-event.hook.ts","../src/hooks/use-event-async.hook.ts"],"sourcesContent":["import { type ClassValue, clsx } from 'clsx';\nimport { extendTailwindMerge } from 'tailwind-merge';\n\nconst twMergeCustom = extendTailwindMerge({ prefix: 'tw-' });\n\n/**\n * Tailwind and CSS class application helper function. Uses\n * [`clsx`](https://www.npmjs.com/package/clsx) to make it easy to apply classes conditionally using\n * object syntax, and uses [`tailwind-merge`](https://www.npmjs.com/package/tailwind-merge) to make\n * it easy to merge/overwrite Tailwind classes in a programmer-logic-friendly way.\n *\n * Note: `tailwind-merge` is configured to use the prefix `tw-`, so you must use the same prefix\n * with any Tailwind classes you use with this function to successfully overwrite other Tailwind\n * classes. `platform-bible-react` is configured to use `tw-` as its Tailwind prefix, so any\n * Tailwind classes you pass into `platform-bible-react` components will be compared using the `tw-`\n * prefix.\n *\n * This function was popularized by\n * [shadcn/ui](https://ui.shadcn.com/docs/installation/manual#add-a-cn-helper). See [ByteGrad's\n * explanation video](https://www.youtube.com/watch?v=re2JFITR7TI) for more information.\n *\n * @example\n *\n * ```typescript\n * const borderShouldBeBlue = true;\n * const textShouldBeRed = true;\n * const heightShouldBe20 = false;\n * const classString = cn(\n * 'tw-bg-primary tw-h-10 tw-text-primary-foreground',\n * 'tw-bg-secondary',\n * {\n * 'tw-border-blue-500': borderShouldBeBlue,\n * 'tw-text-red-500': textShouldBeRed,\n * 'tw-h-20': heightShouldBe20,\n * },\n * 'some-class',\n * );\n * ```\n *\n * The resulting `classString` is `'tw-h-10 tw-bg-secondary tw-border-blue-500 tw-text-red-500\n * some-class'`\n *\n * - Notice that `'tw-bg-secondary'`, specified later, overwrote `'tw-bg-primary'`, specified earlier,\n * because they are Tailwind classes that affect the same css property\n * - Notice that `'tw-text-red-500'`, specified later, overwrote `'tw-text-primary-foreground'`,\n * specified earlier, because they are Tailwind classes that affect the same css property\n * - Notice that `'tw-h-20'`, specified later, did not overwrite `'tw-h-10'`, specified earlier,\n * because `'tw-h-20'` is part of a conditional class object and its value evaluated to `false`;\n * therefore it was not applied\n * - Notice that `'some-class'` was applied. This function is not limited only to Tailwind classes.\n *\n *\n * @param inputs Class strings or `clsx` conditional class objects to merge. Tailwind classes\n * specified later in the arguments overwrite similar Tailwind classes specified earlier in the\n * arguments\n * @returns Class string containing all applicable classes from the arguments based on the rules\n * described above\n */\n// shadcn/ui uses this export in its boilerplate code\n// eslint-disable-next-line import/prefer-default-export\nexport function cn(...inputs: ClassValue[]) {\n return twMergeCustom(clsx(inputs));\n}\n","import React from 'react';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport interface InputProps extends React.InputHTMLAttributes {}\n\nexport const Input = React.forwardRef(\n ({ className, type, ...props }, ref) => {\n return (\n \n );\n },\n);\nInput.displayName = 'Input';\n","import { FocusEventHandler, forwardRef, KeyboardEvent, MouseEventHandler } from 'react';\nimport { History } from 'lucide-react';\nimport { Input as ShadInput } from '@/components/shadcn-ui/input';\n\nexport type BookChapterInputProps = {\n handleSearch: (searchString: string) => void;\n handleKeyDown: (event: KeyboardEvent) => void;\n handleOnClick: MouseEventHandler;\n handleSubmit: () => void;\n onFocus?: FocusEventHandler;\n value: string;\n placeholder: string;\n};\n\n// Shadcn Input sets type to \"button\"- HAVE to prop spread before setting type\nconst BookChapterInput = forwardRef(\n (\n { handleSearch, handleKeyDown, handleOnClick, handleSubmit, ...props }: BookChapterInputProps,\n ref,\n ) => {\n return (\n
    \n handleSearch(event.target.value)}\n onKeyDown={(e) => {\n if (e.key === 'Enter') {\n handleSubmit();\n }\n handleKeyDown(e);\n }}\n onClick={handleOnClick}\n ref={ref}\n />\n {\n // eslint-disable-next-line no-console\n console.log('back in history');\n }}\n />\n
    \n );\n },\n);\n\nexport default BookChapterInput;\n","var P = Object.defineProperty;\nvar R = (t, e, s) => e in t ? P(t, e, { enumerable: !0, configurable: !0, writable: !0, value: s }) : t[e] = s;\nvar n = (t, e, s) => R(t, typeof e != \"symbol\" ? e + \"\" : e, s);\nclass _ {\n constructor() {\n n(this, \"books\");\n n(this, \"firstSelectedBookNum\");\n n(this, \"lastSelectedBookNum\");\n n(this, \"count\");\n n(this, \"selectedBookNumbers\");\n n(this, \"selectedBookIds\");\n }\n}\nconst N = [\n \"GEN\",\n \"EXO\",\n \"LEV\",\n \"NUM\",\n \"DEU\",\n \"JOS\",\n \"JDG\",\n \"RUT\",\n \"1SA\",\n \"2SA\",\n // 10\n \"1KI\",\n \"2KI\",\n \"1CH\",\n \"2CH\",\n \"EZR\",\n \"NEH\",\n \"EST\",\n \"JOB\",\n \"PSA\",\n \"PRO\",\n // 20\n \"ECC\",\n \"SNG\",\n \"ISA\",\n \"JER\",\n \"LAM\",\n \"EZK\",\n \"DAN\",\n \"HOS\",\n \"JOL\",\n \"AMO\",\n // 30\n \"OBA\",\n \"JON\",\n \"MIC\",\n \"NAM\",\n \"HAB\",\n \"ZEP\",\n \"HAG\",\n \"ZEC\",\n \"MAL\",\n \"MAT\",\n // 40\n \"MRK\",\n \"LUK\",\n \"JHN\",\n \"ACT\",\n \"ROM\",\n \"1CO\",\n \"2CO\",\n \"GAL\",\n \"EPH\",\n \"PHP\",\n // 50\n \"COL\",\n \"1TH\",\n \"2TH\",\n \"1TI\",\n \"2TI\",\n \"TIT\",\n \"PHM\",\n \"HEB\",\n \"JAS\",\n \"1PE\",\n // 60\n \"2PE\",\n \"1JN\",\n \"2JN\",\n \"3JN\",\n \"JUD\",\n \"REV\",\n \"TOB\",\n \"JDT\",\n \"ESG\",\n \"WIS\",\n // 70\n \"SIR\",\n \"BAR\",\n \"LJE\",\n \"S3Y\",\n \"SUS\",\n \"BEL\",\n \"1MA\",\n \"2MA\",\n \"3MA\",\n \"4MA\",\n // 80\n \"1ES\",\n \"2ES\",\n \"MAN\",\n \"PS2\",\n \"ODA\",\n \"PSS\",\n \"JSA\",\n // actual variant text for JOS, now in LXA text\n \"JDB\",\n // actual variant text for JDG, now in LXA text\n \"TBS\",\n // actual variant text for TOB, now in LXA text\n \"SST\",\n // actual variant text for SUS, now in LXA text // 90\n \"DNT\",\n // actual variant text for DAN, now in LXA text\n \"BLT\",\n // actual variant text for BEL, now in LXA text\n \"XXA\",\n \"XXB\",\n \"XXC\",\n \"XXD\",\n \"XXE\",\n \"XXF\",\n \"XXG\",\n \"FRT\",\n // 100\n \"BAK\",\n \"OTH\",\n \"3ES\",\n // Used previously but really should be 2ES\n \"EZA\",\n // Used to be called 4ES, but not actually in any known project\n \"5EZ\",\n // Used to be called 5ES, but not actually in any known project\n \"6EZ\",\n // Used to be called 6ES, but not actually in any known project\n \"INT\",\n \"CNC\",\n \"GLO\",\n \"TDX\",\n // 110\n \"NDX\",\n \"DAG\",\n \"PS3\",\n \"2BA\",\n \"LBA\",\n \"JUB\",\n \"ENO\",\n \"1MQ\",\n \"2MQ\",\n \"3MQ\",\n // 120\n \"REP\",\n \"4BA\",\n \"LAO\"\n], B = [\n \"XXA\",\n \"XXB\",\n \"XXC\",\n \"XXD\",\n \"XXE\",\n \"XXF\",\n \"XXG\",\n \"FRT\",\n \"BAK\",\n \"OTH\",\n \"INT\",\n \"CNC\",\n \"GLO\",\n \"TDX\",\n \"NDX\"\n], O = [\n \"Genesis\",\n \"Exodus\",\n \"Leviticus\",\n \"Numbers\",\n \"Deuteronomy\",\n \"Joshua\",\n \"Judges\",\n \"Ruth\",\n \"1 Samuel\",\n \"2 Samuel\",\n \"1 Kings\",\n \"2 Kings\",\n \"1 Chronicles\",\n \"2 Chronicles\",\n \"Ezra\",\n \"Nehemiah\",\n \"Esther (Hebrew)\",\n \"Job\",\n \"Psalms\",\n \"Proverbs\",\n \"Ecclesiastes\",\n \"Song of Songs\",\n \"Isaiah\",\n \"Jeremiah\",\n \"Lamentations\",\n \"Ezekiel\",\n \"Daniel (Hebrew)\",\n \"Hosea\",\n \"Joel\",\n \"Amos\",\n \"Obadiah\",\n \"Jonah\",\n \"Micah\",\n \"Nahum\",\n \"Habakkuk\",\n \"Zephaniah\",\n \"Haggai\",\n \"Zechariah\",\n \"Malachi\",\n \"Matthew\",\n \"Mark\",\n \"Luke\",\n \"John\",\n \"Acts\",\n \"Romans\",\n \"1 Corinthians\",\n \"2 Corinthians\",\n \"Galatians\",\n \"Ephesians\",\n \"Philippians\",\n \"Colossians\",\n \"1 Thessalonians\",\n \"2 Thessalonians\",\n \"1 Timothy\",\n \"2 Timothy\",\n \"Titus\",\n \"Philemon\",\n \"Hebrews\",\n \"James\",\n \"1 Peter\",\n \"2 Peter\",\n \"1 John\",\n \"2 John\",\n \"3 John\",\n \"Jude\",\n \"Revelation\",\n \"Tobit\",\n \"Judith\",\n \"Esther Greek\",\n \"Wisdom of Solomon\",\n \"Sirach (Ecclesiasticus)\",\n \"Baruch\",\n \"Letter of Jeremiah\",\n \"Song of 3 Young Men\",\n \"Susanna\",\n \"Bel and the Dragon\",\n \"1 Maccabees\",\n \"2 Maccabees\",\n \"3 Maccabees\",\n \"4 Maccabees\",\n \"1 Esdras (Greek)\",\n \"2 Esdras (Latin)\",\n \"Prayer of Manasseh\",\n \"Psalm 151\",\n \"Odes\",\n \"Psalms of Solomon\",\n // WARNING, if you change the spelling of the *obsolete* tag be sure to update\n // IsObsolete routine\n \"Joshua A. *obsolete*\",\n \"Judges B. *obsolete*\",\n \"Tobit S. *obsolete*\",\n \"Susanna Th. *obsolete*\",\n \"Daniel Th. *obsolete*\",\n \"Bel Th. *obsolete*\",\n \"Extra A\",\n \"Extra B\",\n \"Extra C\",\n \"Extra D\",\n \"Extra E\",\n \"Extra F\",\n \"Extra G\",\n \"Front Matter\",\n \"Back Matter\",\n \"Other Matter\",\n \"3 Ezra *obsolete*\",\n \"Apocalypse of Ezra\",\n \"5 Ezra (Latin Prologue)\",\n \"6 Ezra (Latin Epilogue)\",\n \"Introduction\",\n \"Concordance \",\n \"Glossary \",\n \"Topical Index\",\n \"Names Index\",\n \"Daniel Greek\",\n \"Psalms 152-155\",\n \"2 Baruch (Apocalypse)\",\n \"Letter of Baruch\",\n \"Jubilees\",\n \"Enoch\",\n \"1 Meqabyan\",\n \"2 Meqabyan\",\n \"3 Meqabyan\",\n \"Reproof (Proverbs 25-31)\",\n \"4 Baruch (Rest of Baruch)\",\n \"Laodiceans\"\n], S = K();\nfunction g(t, e = !0) {\n return e && (t = t.toUpperCase()), t in S ? S[t] : 0;\n}\nfunction k(t) {\n return g(t) > 0;\n}\nfunction x(t) {\n const e = typeof t == \"string\" ? g(t) : t;\n return e >= 40 && e <= 66;\n}\nfunction T(t) {\n return (typeof t == \"string\" ? g(t) : t) <= 39;\n}\nfunction X(t) {\n return t <= 66;\n}\nfunction V(t) {\n const e = typeof t == \"string\" ? g(t) : t;\n return w(e) && !X(e);\n}\nfunction* L() {\n for (let t = 1; t <= N.length; t++) yield t;\n}\nconst G = 1, A = N.length;\nfunction H() {\n return [\"XXA\", \"XXB\", \"XXC\", \"XXD\", \"XXE\", \"XXF\", \"XXG\"];\n}\nfunction C(t, e = \"***\") {\n const s = t - 1;\n return s < 0 || s >= N.length ? e : N[s];\n}\nfunction I(t) {\n return t <= 0 || t > A ? \"******\" : O[t - 1];\n}\nfunction y(t) {\n return I(g(t));\n}\nfunction w(t) {\n const e = typeof t == \"number\" ? C(t) : t;\n return k(e) && !B.includes(e);\n}\nfunction q(t) {\n const e = typeof t == \"number\" ? C(t) : t;\n return k(e) && B.includes(e);\n}\nfunction U(t) {\n return O[t - 1].includes(\"*obsolete*\");\n}\nfunction K() {\n const t = {};\n for (let e = 0; e < N.length; e++)\n t[N[e]] = e + 1;\n return t;\n}\nconst m = {\n allBookIds: N,\n nonCanonicalIds: B,\n bookIdToNumber: g,\n isBookIdValid: k,\n isBookNT: x,\n isBookOT: T,\n isBookOTNT: X,\n isBookDC: V,\n allBookNumbers: L,\n firstBook: G,\n lastBook: A,\n extraBooks: H,\n bookNumberToId: C,\n bookNumberToEnglishName: I,\n bookIdToEnglishName: y,\n isCanonical: w,\n isExtraMaterial: q,\n isObsolete: U\n};\nvar l = /* @__PURE__ */ ((t) => (t[t.Unknown = 0] = \"Unknown\", t[t.Original = 1] = \"Original\", t[t.Septuagint = 2] = \"Septuagint\", t[t.Vulgate = 3] = \"Vulgate\", t[t.English = 4] = \"English\", t[t.RussianProtestant = 5] = \"RussianProtestant\", t[t.RussianOrthodox = 6] = \"RussianOrthodox\", t))(l || {});\nconst h = class h {\n // private versInfo: Versification;\n constructor(e) {\n n(this, \"name\");\n n(this, \"fullPath\");\n n(this, \"isPresent\");\n n(this, \"hasVerseSegments\");\n n(this, \"isCustomized\");\n n(this, \"baseVersification\");\n n(this, \"scriptureBooks\");\n n(this, \"_type\");\n if (e == null)\n throw new Error(\"Argument undefined\");\n typeof e == \"string\" ? (this.name = e, this._type = l[e]) : (this._type = e, this.name = l[e]);\n }\n get type() {\n return this._type;\n }\n equals(e) {\n return !e.type || !this.type ? !1 : e.type === this.type;\n }\n};\nn(h, \"Original\", new h(l.Original)), n(h, \"Septuagint\", new h(l.Septuagint)), n(h, \"Vulgate\", new h(l.Vulgate)), n(h, \"English\", new h(l.English)), n(h, \"RussianProtestant\", new h(l.RussianProtestant)), n(h, \"RussianOrthodox\", new h(l.RussianOrthodox));\nlet c = h;\nfunction E(t, e) {\n const s = e[0];\n for (let r = 1; r < e.length; r++)\n t = t.split(e[r]).join(s);\n return t.split(s);\n}\nvar D = /* @__PURE__ */ ((t) => (t[t.Valid = 0] = \"Valid\", t[t.UnknownVersification = 1] = \"UnknownVersification\", t[t.OutOfRange = 2] = \"OutOfRange\", t[t.VerseOutOfOrder = 3] = \"VerseOutOfOrder\", t[t.VerseRepeated = 4] = \"VerseRepeated\", t))(D || {});\nconst i = class i {\n constructor(e, s, r, a) {\n /** Not yet implemented. */\n n(this, \"firstChapter\");\n /** Not yet implemented. */\n n(this, \"lastChapter\");\n /** Not yet implemented. */\n n(this, \"lastVerse\");\n /** Not yet implemented. */\n n(this, \"hasSegmentsDefined\");\n /** Not yet implemented. */\n n(this, \"text\");\n /** Not yet implemented. */\n n(this, \"BBBCCCVVVS\");\n /** Not yet implemented. */\n n(this, \"longHashCode\");\n /** The versification of the reference. */\n n(this, \"versification\");\n n(this, \"rtlMark\", \"‏\");\n n(this, \"_bookNum\", 0);\n n(this, \"_chapterNum\", 0);\n n(this, \"_verseNum\", 0);\n n(this, \"_verse\");\n if (r == null && a == null)\n if (e != null && typeof e == \"string\") {\n const o = e, u = s != null && s instanceof c ? s : void 0;\n this.setEmpty(u), this.parse(o);\n } else if (e != null && typeof e == \"number\") {\n const o = s != null && s instanceof c ? s : void 0;\n this.setEmpty(o), this._verseNum = e % i.chapterDigitShifter, this._chapterNum = Math.floor(\n e % i.bookDigitShifter / i.chapterDigitShifter\n ), this._bookNum = Math.floor(e / i.bookDigitShifter);\n } else if (s == null)\n if (e != null && e instanceof i) {\n const o = e;\n this._bookNum = o.bookNum, this._chapterNum = o.chapterNum, this._verseNum = o.verseNum, this._verse = o.verse, this.versification = o.versification;\n } else {\n if (e == null) return;\n const o = e instanceof c ? e : i.defaultVersification;\n this.setEmpty(o);\n }\n else\n throw new Error(\"VerseRef constructor not supported.\");\n else if (e != null && s != null && r != null)\n if (typeof e == \"string\" && typeof s == \"string\" && typeof r == \"string\")\n this.setEmpty(a), this.updateInternal(e, s, r);\n else if (typeof e == \"number\" && typeof s == \"number\" && typeof r == \"number\")\n this._bookNum = e, this._chapterNum = s, this._verseNum = r, this.versification = a ?? i.defaultVersification;\n else\n throw new Error(\"VerseRef constructor not supported.\");\n else\n throw new Error(\"VerseRef constructor not supported.\");\n }\n /**\n * Determines if the verse string is in a valid format (does not consider versification).\n */\n static isVerseParseable(e) {\n return e.length > 0 && \"0123456789\".includes(e[0]) && !e.endsWith(this.verseRangeSeparator) && !e.endsWith(this.verseSequenceIndicator);\n }\n /**\n * Tries to parse the specified string into a verse reference.\n * @param str - The string to attempt to parse.\n * @returns success: `true` if the specified string was successfully parsed, `false` otherwise.\n * @returns verseRef: The result of the parse if successful, or empty VerseRef if it failed\n */\n static tryParse(e) {\n let s;\n try {\n return s = new i(e), { success: !0, verseRef: s };\n } catch (r) {\n if (r instanceof v)\n return s = new i(), { success: !1, verseRef: s };\n throw r;\n }\n }\n /**\n * Gets the reference as a comparable integer where the book, chapter, and verse each occupy 3\n * digits.\n * @param bookNum - Book number (this is 1-based, not an index).\n * @param chapterNum - Chapter number.\n * @param verseNum - Verse number.\n * @returns The reference as a comparable integer where the book, chapter, and verse each occupy 3\n * digits.\n */\n static getBBBCCCVVV(e, s, r) {\n return e % i.bcvMaxValue * i.bookDigitShifter + (s >= 0 ? s % i.bcvMaxValue * i.chapterDigitShifter : 0) + (r >= 0 ? r % i.bcvMaxValue : 0);\n }\n /**\n * Deserializes a serialized VerseRef.\n * @param serializedVerseRef - Serialized VerseRef to create from.\n * @returns the deserialized VerseRef.\n */\n static fromJSON(e) {\n const { book: s, chapterNum: r, verseNum: a, verse: o, versificationStr: u } = e, f = o || a.toString();\n let d;\n return u && (d = new c(u)), s ? new i(s, r.toString(), f, d) : new i();\n }\n /**\n * Parses a verse string and gets the leading numeric portion as a number.\n * @param verseStr - verse string to parse\n * @returns true if the entire string could be parsed as a single, simple verse number (1-999);\n * false if the verse string represented a verse bridge, contained segment letters, or was invalid\n */\n static tryGetVerseNum(e) {\n let s;\n if (!e)\n return s = -1, { success: !0, vNum: s };\n s = 0;\n let r;\n for (let a = 0; a < e.length; a++) {\n if (r = e[a], r < \"0\" || r > \"9\")\n return a === 0 && (s = -1), { success: !1, vNum: s };\n if (s = s * 10 + +r - 0, s > i.bcvMaxValue)\n return s = -1, { success: !1, vNum: s };\n }\n return { success: !0, vNum: s };\n }\n /**\n * Checks to see if a VerseRef hasn't been set - all values are the default.\n */\n get isDefault() {\n return this.bookNum === 0 && this.chapterNum === 0 && this.verseNum === 0 && this.versification == null;\n }\n /**\n * Gets whether the verse contains multiple verses.\n */\n get hasMultiple() {\n return this._verse != null && (this._verse.includes(i.verseRangeSeparator) || this._verse.includes(i.verseSequenceIndicator));\n }\n /**\n * Gets or sets the book of the reference. Book is the 3-letter abbreviation in capital letters,\n * e.g. `'MAT'`.\n */\n get book() {\n return m.bookNumberToId(this.bookNum, \"\");\n }\n set book(e) {\n this.bookNum = m.bookIdToNumber(e);\n }\n /**\n * Gets or sets the chapter of the reference,. e.g. `'3'`.\n */\n get chapter() {\n return this.isDefault || this._chapterNum < 0 ? \"\" : this._chapterNum.toString();\n }\n set chapter(e) {\n const s = +e;\n this._chapterNum = Number.isInteger(s) ? s : -1;\n }\n /**\n * Gets or sets the verse of the reference, including range, segments, and sequences, e.g. `'4'`,\n * or `'4b-5a, 7'`.\n */\n get verse() {\n return this._verse != null ? this._verse : this.isDefault || this._verseNum < 0 ? \"\" : this._verseNum.toString();\n }\n set verse(e) {\n const { success: s, vNum: r } = i.tryGetVerseNum(e);\n this._verse = s ? void 0 : e.replace(this.rtlMark, \"\"), this._verseNum = r, !(this._verseNum >= 0) && ({ vNum: this._verseNum } = i.tryGetVerseNum(this._verse));\n }\n /**\n * Get or set Book based on book number, e.g. `42`.\n */\n get bookNum() {\n return this._bookNum;\n }\n set bookNum(e) {\n if (e <= 0 || e > m.lastBook)\n throw new v(\n \"BookNum must be greater than zero and less than or equal to last book\"\n );\n this._bookNum = e;\n }\n /**\n * Gets or sets the chapter number, e.g. `3`. `-1` if not valid.\n */\n get chapterNum() {\n return this._chapterNum;\n }\n set chapterNum(e) {\n this.chapterNum = e;\n }\n /**\n * Gets or sets verse start number, e.g. `4`. `-1` if not valid.\n */\n get verseNum() {\n return this._verseNum;\n }\n set verseNum(e) {\n this._verseNum = e;\n }\n /**\n * String representing the versification (should ONLY be used for serialization/deserialization).\n *\n * @remarks This is for backwards compatibility when ScrVers was an enumeration.\n */\n get versificationStr() {\n var e;\n return (e = this.versification) == null ? void 0 : e.name;\n }\n set versificationStr(e) {\n this.versification = this.versification != null ? new c(e) : void 0;\n }\n /**\n * Determines if the reference is valid.\n */\n get valid() {\n return this.validStatus === 0;\n }\n /**\n * Get the valid status for this reference.\n */\n get validStatus() {\n return this.validateVerse(i.verseRangeSeparators, i.verseSequenceIndicators);\n }\n /**\n * Gets the reference as a comparable integer where the book,\n * chapter, and verse each occupy three digits and the verse is 0.\n */\n get BBBCCC() {\n return i.getBBBCCCVVV(this._bookNum, this._chapterNum, 0);\n }\n /**\n * Gets the reference as a comparable integer where the book,\n * chapter, and verse each occupy three digits. If verse is not null\n * (i.e., this reference represents a complex reference with verse\n * segments or bridge) this cannot be used for an exact comparison.\n */\n get BBBCCCVVV() {\n return i.getBBBCCCVVV(this._bookNum, this._chapterNum, this._verseNum);\n }\n /**\n * Gets whether the verse is defined as an excluded verse in the versification.\n * Does not handle verse ranges.\n */\n // eslint-disable-next-line @typescript-eslint/class-literal-property-style\n get isExcluded() {\n return !1;\n }\n /**\n * Parses the reference in the specified string.\n * Optionally versification can follow reference as in GEN 3:11/4\n * Throw an exception if\n * - invalid book name\n * - chapter number is missing or not a number\n * - verse number is missing or does not start with a number\n * - versification is invalid\n * @param verseStr - string to parse e.g. 'MAT 3:11'\n */\n parse(e) {\n if (e = e.replace(this.rtlMark, \"\"), e.includes(\"/\")) {\n const o = e.split(\"/\");\n if (e = o[0], o.length > 1)\n try {\n const u = +o[1].trim();\n this.versification = new c(l[u]);\n } catch {\n throw new v(\"Invalid reference : \" + e);\n }\n }\n const s = e.trim().split(\" \");\n if (s.length !== 2)\n throw new v(\"Invalid reference : \" + e);\n const r = s[1].split(\":\"), a = +r[0];\n if (r.length !== 2 || m.bookIdToNumber(s[0]) === 0 || !Number.isInteger(a) || a < 0 || !i.isVerseParseable(r[1]))\n throw new v(\"Invalid reference : \" + e);\n this.updateInternal(s[0], r[0], r[1]);\n }\n /**\n * Simplifies this verse ref so that it has no bridging of verses or\n * verse segments like `'1a'`.\n */\n simplify() {\n this._verse = void 0;\n }\n /**\n * Makes a clone of the reference.\n *\n * @returns The cloned VerseRef.\n */\n clone() {\n return new i(this);\n }\n toString() {\n const e = this.book;\n return e === \"\" ? \"\" : `${e} ${this.chapter}:${this.verse}`;\n }\n toJSON() {\n let e = this.verse;\n (e === \"\" || e === this.verseNum.toString()) && (e = void 0);\n const s = {\n book: this.book,\n chapterNum: this.chapterNum,\n verseNum: this.verseNum,\n verse: e,\n versificationStr: this.versificationStr\n };\n return e || delete s.verse, s;\n }\n /**\n * Compares this `VerseRef` with supplied one.\n * @param verseRef - object to compare this one to.\n * @returns `true` if this `VerseRef` is equal to the supplied one, `false` otherwise.\n */\n equals(e) {\n return e instanceof i ? e._bookNum === this._bookNum && e._chapterNum === this._chapterNum && e._verseNum === this._verseNum && e.verse === this.verse && (e.versification == null && this.versification == null || e.versification != null && this.versification != null && e.versification.equals(this.versification)) : !1;\n }\n /**\n * Enumerate all individual verses contained in a VerseRef.\n * Verse ranges are indicated by \"-\" and consecutive verses by \",\"s.\n * Examples:\n * GEN 1:2 returns GEN 1:2\n * GEN 1:1a-3b,5 returns GEN 1:1a, GEN 1:2, GEN 1:3b, GEN 1:5\n * GEN 1:2a-2c returns //! ??????\n *\n * @param specifiedVersesOnly - if set to true return only verses that are\n * explicitly specified only, not verses within a range. Defaults to `false`.\n * @param verseRangeSeparators - Verse range separators.\n * Defaults to `VerseRef.verseRangeSeparators`.\n * @param verseSequenceSeparators - Verse sequence separators.\n * Defaults to `VerseRef.verseSequenceIndicators`.\n * @returns An array of all single verse references in this VerseRef.\n */\n allVerses(e = !1, s = i.verseRangeSeparators, r = i.verseSequenceIndicators) {\n if (this._verse == null || this.chapterNum <= 0)\n return [this.clone()];\n const a = [], o = E(this._verse, r);\n for (const u of o.map((f) => E(f, s))) {\n const f = this.clone();\n f.verse = u[0];\n const d = f.verseNum;\n if (a.push(f), u.length > 1) {\n const b = this.clone();\n if (b.verse = u[1], !e)\n for (let p = d + 1; p < b.verseNum; p++) {\n const J = new i(\n this._bookNum,\n this._chapterNum,\n p,\n this.versification\n );\n this.isExcluded || a.push(J);\n }\n a.push(b);\n }\n }\n return a;\n }\n /**\n * Validates a verse number using the supplied separators rather than the defaults.\n */\n validateVerse(e, s) {\n if (!this.verse)\n return this.internalValid;\n let r = 0;\n for (const a of this.allVerses(!0, e, s)) {\n const o = a.internalValid;\n if (o !== 0)\n return o;\n const u = a.BBBCCCVVV;\n if (r > u)\n return 3;\n if (r === u)\n return 4;\n r = u;\n }\n return 0;\n }\n /**\n * Gets whether a single verse reference is valid.\n */\n get internalValid() {\n return this.versification == null ? 1 : this._bookNum <= 0 || this._bookNum > m.lastBook ? 2 : (m.isCanonical(this._bookNum), 0);\n }\n setEmpty(e = i.defaultVersification) {\n this._bookNum = 0, this._chapterNum = -1, this._verse = void 0, this.versification = e;\n }\n updateInternal(e, s, r) {\n this.bookNum = m.bookIdToNumber(e), this.chapter = s, this.verse = r;\n }\n};\nn(i, \"defaultVersification\", c.English), n(i, \"verseRangeSeparator\", \"-\"), n(i, \"verseSequenceIndicator\", \",\"), n(i, \"verseRangeSeparators\", [i.verseRangeSeparator]), n(i, \"verseSequenceIndicators\", [i.verseSequenceIndicator]), n(i, \"chapterDigitShifter\", 1e3), n(i, \"bookDigitShifter\", i.chapterDigitShifter * i.chapterDigitShifter), n(i, \"bcvMaxValue\", i.chapterDigitShifter - 1), /**\n * The valid status of the VerseRef.\n */\nn(i, \"ValidStatusType\", D);\nlet M = i;\nclass v extends Error {\n}\nexport {\n _ as BookSet,\n m as Canon,\n c as ScrVers,\n l as ScrVersType,\n M as VerseRef,\n v as VerseRefException\n};\n//# sourceMappingURL=index.es.js.map\n","import React from 'react';\nimport * as DropdownMenuPrimitive from '@radix-ui/react-dropdown-menu';\nimport { Check, ChevronRight, Circle } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport const DropdownMenu = DropdownMenuPrimitive.Root;\n\nexport const DropdownMenuTrigger = DropdownMenuPrimitive.Trigger;\n\nexport const DropdownMenuGroup = DropdownMenuPrimitive.Group;\n\nexport const DropdownMenuPortal = DropdownMenuPrimitive.Portal;\n\nexport const DropdownMenuSub = DropdownMenuPrimitive.Sub;\n\nexport const DropdownMenuRadioGroup = DropdownMenuPrimitive.RadioGroup;\n\nexport type DropdownMenuSubTriggerProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.SubTrigger\n> & {\n className?: string;\n inset?: boolean;\n};\n\nexport type DropdownMenuSubContentProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.SubContent\n> & {\n className?: string;\n};\n\nexport type DropdownMenuContentProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Content\n> & {\n className?: string;\n sideOffset?: number;\n};\n\nexport type DropdownMenuItemProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Item\n> & {\n className?: string;\n inset?: boolean;\n};\n\nexport type DropdownMenuCheckboxItemProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.CheckboxItem\n> & {\n className?: string;\n checked?: boolean;\n};\n\nexport type DropdownMenuRadioItemProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.RadioItem\n> & {\n className?: string;\n};\n\nexport type DropdownMenuLabelProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Label\n> & {\n className?: string;\n inset?: boolean;\n};\n\nexport type DropdownMenuSeparatorProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Separator\n> & {\n className?: string;\n};\n\nexport type DropdownMenuShortcutProps = React.HTMLAttributes & {\n className?: string;\n};\n\nexport const DropdownMenuSubTrigger = React.forwardRef<\n React.ElementRef,\n DropdownMenuSubTriggerProps\n>(({ className, inset, children, ...props }, ref) => (\n \n {children}\n \n \n));\nDropdownMenuSubTrigger.displayName = DropdownMenuPrimitive.SubTrigger.displayName;\n\nexport const DropdownMenuSubContent = React.forwardRef<\n React.ElementRef,\n DropdownMenuSubContentProps\n>(({ className, ...props }, ref) => (\n \n));\nDropdownMenuSubContent.displayName = DropdownMenuPrimitive.SubContent.displayName;\n\nexport const DropdownMenuContent = React.forwardRef<\n React.ElementRef,\n DropdownMenuContentProps\n>(({ className, sideOffset = 4, ...props }, ref) => (\n \n \n \n));\nDropdownMenuContent.displayName = DropdownMenuPrimitive.Content.displayName;\n\n/**\n * TODO: fix: direction is not automatically handled by this component, so that shortcuts are\n * display always to the right\n */\nexport const DropdownMenuItem = React.forwardRef<\n React.ElementRef,\n DropdownMenuItemProps\n>(({ className, inset, ...props }, ref) => (\n \n));\nDropdownMenuItem.displayName = DropdownMenuPrimitive.Item.displayName;\n\nexport const DropdownMenuCheckboxItem = React.forwardRef<\n React.ElementRef,\n DropdownMenuCheckboxItemProps\n>(({ className, children, checked, ...props }, ref) => (\n \n \n \n \n \n \n {children}\n \n));\nDropdownMenuCheckboxItem.displayName = DropdownMenuPrimitive.CheckboxItem.displayName;\n\nexport const DropdownMenuRadioItem = React.forwardRef<\n React.ElementRef,\n DropdownMenuRadioItemProps\n>(({ className, children, ...props }, ref) => (\n \n \n \n \n \n \n {children}\n \n));\nDropdownMenuRadioItem.displayName = DropdownMenuPrimitive.RadioItem.displayName;\n\nexport const DropdownMenuLabel = React.forwardRef<\n React.ElementRef,\n DropdownMenuLabelProps\n>(({ className, inset, ...props }, ref) => (\n \n));\nDropdownMenuLabel.displayName = DropdownMenuPrimitive.Label.displayName;\n\nexport const DropdownMenuSeparator = React.forwardRef<\n React.ElementRef,\n DropdownMenuSeparatorProps\n>(({ className, ...props }, ref) => (\n \n));\nDropdownMenuSeparator.displayName = DropdownMenuPrimitive.Separator.displayName;\n\nexport function DropdownMenuShortcut({ className, ...props }: DropdownMenuShortcutProps) {\n return (\n \n );\n}\nDropdownMenuShortcut.displayName = 'DropdownMenuShortcut';\n","import { Canon } from '@sillsdev/scripture';\nimport { PropsWithChildren, KeyboardEvent, forwardRef } from 'react';\nimport { DropdownMenuItem as ShadDropdownMenuItem } from '@/components/shadcn-ui/dropdown-menu';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport type BookType = 'OT' | 'NT' | 'DC';\n\ntype BookMenuItemProps = PropsWithChildren<{\n /** String id of book */\n bookId: string;\n /** Callback to run when a book menu item is selected */\n handleSelectBook: () => void;\n /** Indicates if this menu item is currently selected */\n isSelected: boolean;\n /** Function that is called upon highlighting a book in the dropdown menu */\n handleHighlightBook: () => void;\n /**\n * Function that is called on pressing a key\n *\n * @param event Event that contains information about the key stroke\n */\n handleKeyDown: (event: KeyboardEvent) => void;\n /**\n * Type of book associated with this menu item, coordinates color labels ? Mock up has the labels\n * coordinated to genre\n */\n bookType: BookType;\n}>;\n\nconst BookMenuItem = forwardRef(\n (\n {\n bookId,\n handleSelectBook,\n isSelected,\n handleHighlightBook,\n handleKeyDown,\n bookType,\n children,\n }: BookMenuItemProps,\n ref,\n ) => {\n return (\n {\n // preventDefault() here prevents the entire dropdown menu from closing when selecting this item\n event.preventDefault();\n handleSelectBook();\n }}\n onKeyDown={(event: KeyboardEvent) => {\n handleKeyDown(event);\n }}\n onFocus={handleHighlightBook}\n onMouseMove={handleHighlightBook}\n >\n \n {Canon.bookIdToEnglishName(bookId)}\n \n {isSelected &&
    {children}
    }\n \n );\n },\n);\n\nexport default BookMenuItem;\n","import { cn } from '@/utils/shadcn-ui.util';\nimport { useCallback } from 'react';\n\nexport type ChapterSelectProps = {\n /**\n * Callback to run when a chapter div is selected\n *\n * @param chapterNumber Number of the chapter that has been selected\n */\n handleSelectChapter: (chapterNumber: number) => void;\n /** The highest chapter number in the book (of course equal to number of chapters in the book) */\n endChapter: number;\n /** The chapter number that is currently selected */\n activeChapter: number;\n /** The chapter number that is currently highlighted using keyboard or mouse navigation */\n highlightedChapter: number;\n /**\n * Callback to run when a chapter is highlighted by the user\n *\n * @param chapterNumber The chapter that is highlighted\n */\n handleHighlightedChapter: (chapterNumber: number) => void;\n};\n\nfunction ChapterSelect({\n handleSelectChapter,\n endChapter,\n activeChapter,\n highlightedChapter,\n handleHighlightedChapter,\n}: ChapterSelectProps) {\n const chapters = Array.from({ length: endChapter }, (_, i) => i + 1);\n\n const handleMouse = useCallback(\n (chapterNumber: number) => {\n handleHighlightedChapter(chapterNumber);\n },\n [handleHighlightedChapter],\n );\n\n return (\n
    \n {chapters.map((chapter) => (\n {\n event.preventDefault();\n event.stopPropagation();\n handleSelectChapter(chapter);\n }}\n role=\"button\"\n onKeyDown={(event) => {\n if (event.key === 'Enter') {\n handleSelectChapter(chapter);\n }\n }}\n tabIndex={0}\n onMouseMove={() => handleMouse(chapter)}\n >\n {chapter}\n
    \n ))}\n
    \n );\n}\n\nexport default ChapterSelect;\n","import { DropdownMenuLabel as ShadDropdownMenuLabel } from '@/components/shadcn-ui/dropdown-menu';\nimport { Bookmark, Clock, ArrowDownWideNarrow } from 'lucide-react';\n\nexport type GoToMenuItemProps = {\n handleSort: () => void;\n handleLocationHistory: () => void;\n handleBookmarks: () => void;\n};\n\nfunction GoToMenuItem({ handleSort, handleLocationHistory, handleBookmarks }: GoToMenuItemProps) {\n return (\n \n

    Go To

    \n
    \n \n \n \n
    \n
    \n );\n}\n\nexport default GoToMenuItem;\n","import BookChapterInput from '@/components/advanced/book-chapter-control/book-chapter-input.component';\nimport BookMenuItem, {\n BookType,\n} from '@/components/advanced/book-chapter-control/book-menu-item.component';\nimport ChapterSelect from '@/components/advanced/book-chapter-control/chapter-select.component';\nimport GoToMenuItem from '@/components/advanced/book-chapter-control/go-to-menu-item.component';\nimport {\n DropdownMenu as ShadDropdownMenu,\n DropdownMenuContent as ShadDropdownMenuContent,\n DropdownMenuLabel as ShadDropdownMenuLabel,\n DropdownMenuSeparator as ShadDropdownMenuSeparator,\n DropdownMenuTrigger as ShadDropdownMenuTrigger,\n} from '@/components/shadcn-ui/dropdown-menu';\nimport { Canon } from '@sillsdev/scripture';\nimport { ScriptureReference, getChaptersForBook } from 'platform-bible-utils';\nimport {\n KeyboardEvent as ReactKeyboardEvent,\n useCallback,\n useEffect,\n useLayoutEffect,\n useRef,\n useState,\n} from 'react';\n\ntype BookTypeLabels = {\n [bookType in BookType]: string;\n};\ntype BookChapterControlProps = {\n scrRef: ScriptureReference;\n handleSubmit: (scrRef: ScriptureReference) => void;\n};\n\nconst ALL_BOOK_IDS = Canon.allBookIds;\nconst BOOK_TYPE_LABELS: BookTypeLabels = {\n OT: 'Old Testament',\n NT: 'New Testament',\n DC: 'Deuterocanon',\n};\nconst BOOK_TYPE_ARRAY: BookType[] = ['OT', 'NT', 'DC'];\n// This is the height of three menu items to offset scrolling to the selected menu item\n// If you use menuItemRef.clientHeight- includes height of chapter div which is too big\nconst SCROLL_OFFSET = 32 + 32 + 32;\nconst SEARCH_QUERY_FORMATS = [\n /^(\\w+)$/i, // Matches a single word (book name or id)\n /^(\\w+)(?:\\s(\\d+))$/i, // Matches a word followed by a chapter number\n /^(\\w+)(?:\\s(\\d+):(\\d+))$/i, // Matches a word followed by a chapter and verse number\n];\nconst fetchGroupedBooks = (bookType: BookType) => {\n const groupedBooks = {\n OT: ALL_BOOK_IDS.filter((bookId) => Canon.isBookOT(bookId)),\n NT: ALL_BOOK_IDS.filter((bookId) => Canon.isBookNT(bookId)),\n DC: ALL_BOOK_IDS.filter((bookId) => Canon.isBookDC(bookId)),\n };\n return groupedBooks[bookType];\n};\nconst fetchEndChapter = (bookId: string) => {\n // getChaptersForBook returns -1 if not found in scrBookData\n // scrBookData only includes OT and NT, so all DC will return -1\n return getChaptersForBook(Canon.bookIdToNumber(bookId));\n};\n\n/**\n * Gets all of the English names from book ids\n *\n * @returns String[]\n */\nfunction getAllEnglishNames(): string[] {\n const allEnglishNames = ALL_BOOK_IDS.map((bookId) => {\n return Canon.bookIdToEnglishName(bookId);\n });\n return allEnglishNames;\n}\n\n/**\n * Determines if bookName is in allEnglishNames\n *\n * @param bookName Book English name\n * @returns True if bookName is included, false otherwise\n */\nfunction isValidBookEnglishName(bookName: string): boolean {\n return getAllEnglishNames().includes(bookName);\n}\n\n/**\n * Gets a bookId from given English name\n *\n * @param bookName Book English name\n * @returns BookId of provided bookName, undefined otherwise\n */\nfunction getBookIdFromEnglishName(bookName: string): string | undefined {\n // Convert bookName to lowercase and then capitalize the first letter\n const formattedBookName = bookName.toLowerCase().replace(/^\\w/, (c) => c.toUpperCase());\n\n if (isValidBookEnglishName(formattedBookName)) {\n const matchingBookId = ALL_BOOK_IDS.find((bookId) => {\n return Canon.bookIdToEnglishName(bookId) === formattedBookName;\n });\n return matchingBookId;\n }\n\n return undefined;\n}\n\nfunction BookChapterControl({ scrRef, handleSubmit }: BookChapterControlProps) {\n const [searchQuery, setSearchQuery] = useState('');\n const [selectedBookId, setSelectedBookId] = useState(\n Canon.bookNumberToId(scrRef.bookNum),\n );\n const [highlightedChapter, setHighlightedChapter] = useState(scrRef.chapterNum ?? 0);\n const [highlightedBookId, setHighlightedBookId] = useState(\n Canon.bookNumberToId(scrRef.bookNum),\n );\n const [isContentOpen, setIsContentOpen] = useState(false);\n const [isContentOpenDelayed, setIsContentOpenDelayed] = useState(isContentOpen);\n\n // This ref will always be defined\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const inputRef = useRef(undefined!);\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const contentRef = useRef(undefined!);\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const menuItemRef = useRef(undefined!);\n\n const fetchFilteredBooks = useCallback(\n (bookType: BookType) => {\n return fetchGroupedBooks(bookType).filter((bookId: string) => {\n const englishNameLowerCase = Canon.bookIdToEnglishName(bookId).toLowerCase();\n const normalizedQuery = searchQuery.replace(/[^a-zA-Z]/g, '').toLowerCase();\n return (\n englishNameLowerCase.includes(normalizedQuery) || // Match book name\n bookId.toLowerCase().includes(normalizedQuery) // Match book ID\n );\n });\n },\n [searchQuery],\n );\n\n const handleSearchInput = (searchString: string) => {\n setSearchQuery(searchString);\n };\n\n /**\n * Whether to prevent radix's logic from closing the dropdown. This is important because radix\n * tries to close the dropdown when the input first focuses, and we don't want it to do that. But\n * we don't want to prevent the dropdown from closing when we click away from the input, so we\n * don't want to just keep it open if the input is focused\n */\n const shouldPreventAutoClosing = useRef(false);\n\n const controlMenuState = useCallback((open: boolean) => {\n if (shouldPreventAutoClosing.current) {\n shouldPreventAutoClosing.current = false;\n return;\n }\n setIsContentOpen(open);\n }, []);\n\n const updateReference = useCallback(\n (bookId: string, shouldClose: boolean, chapter?: number, verse?: number) => {\n setHighlightedChapter(\n Canon.bookNumberToId(scrRef.bookNum) !== bookId ? 1 : scrRef.chapterNum,\n );\n\n if (shouldClose || fetchEndChapter(bookId) === -1) {\n handleSubmit({\n bookNum: Canon.bookIdToNumber(bookId),\n chapterNum: chapter || 1,\n verseNum: verse || 1,\n });\n\n setIsContentOpen(false);\n setSearchQuery('');\n return;\n }\n\n setSelectedBookId(selectedBookId !== bookId ? bookId : '');\n setIsContentOpen(!shouldClose);\n },\n [handleSubmit, scrRef.bookNum, scrRef.chapterNum, selectedBookId],\n );\n\n const handleSelectChapter = (chapterNumber: number) => {\n if (chapterNumber <= 0 || chapterNumber > fetchEndChapter(selectedBookId)) {\n return;\n }\n updateReference(selectedBookId, true, chapterNumber);\n };\n\n const handleInputSubmit = useCallback(() => {\n SEARCH_QUERY_FORMATS.forEach((format) => {\n const matches = searchQuery.match(format);\n if (matches) {\n // Book should be a bookId or an english name\n const [book, chapter = undefined, verse = undefined] = matches.slice(1);\n const englishName = getBookIdFromEnglishName(book);\n\n if (Canon.isBookIdValid(book) || englishName) {\n updateReference(\n englishName ?? book,\n true,\n chapter ? parseInt(chapter, 10) : 1,\n verse ? parseInt(verse, 10) : 1,\n );\n }\n }\n });\n }, [updateReference, searchQuery]);\n\n const handleKeyDownInput = useCallback(\n (event: ReactKeyboardEvent) => {\n if (!isContentOpen) {\n setIsContentOpen(true);\n } else if (event.key === 'ArrowDown' || event.key === 'ArrowUp') {\n if (\n typeof menuItemRef !== 'undefined' &&\n // Ref uses null\n // eslint-disable-next-line no-null/no-null\n menuItemRef.current !== null\n ) {\n menuItemRef.current.focus();\n } else if (\n typeof contentRef !== 'undefined' &&\n // Ref uses null\n // eslint-disable-next-line no-null/no-null\n contentRef.current !== null\n ) {\n contentRef.current.focus();\n }\n event.preventDefault();\n }\n },\n [isContentOpen],\n );\n\n const handleKeyDownContent = (event: ReactKeyboardEvent) => {\n // When the dropdown menu has focus, key strokes should give focus to the input component,\n // unless they're navigation keys (arrows and enter)\n const { key } = event;\n if (\n key === 'ArrowRight' ||\n key === 'ArrowLeft' ||\n key === 'ArrowDown' ||\n key === 'ArrowUp' ||\n key === 'Enter'\n ) {\n return;\n }\n\n inputRef.current.dispatchEvent(new KeyboardEvent('keydown', { key }));\n inputRef.current.focus();\n };\n\n const handleKeyDownMenuItem = (event: ReactKeyboardEvent) => {\n const { key } = event;\n if (highlightedBookId === selectedBookId) {\n if (key === 'Enter') {\n event.preventDefault();\n updateReference(selectedBookId, true, highlightedChapter);\n return;\n }\n\n let chapterOffSet = 0;\n if (key === 'ArrowRight') {\n if (highlightedChapter < fetchEndChapter(highlightedBookId)) {\n chapterOffSet = 1;\n } else {\n event.preventDefault();\n return;\n }\n } else if (key === 'ArrowLeft') {\n if (highlightedChapter > 1) {\n chapterOffSet = -1;\n } else {\n event.preventDefault();\n return;\n }\n } else if (key === 'ArrowDown') {\n chapterOffSet = 6;\n } else if (key === 'ArrowUp') {\n chapterOffSet = -6;\n }\n if (\n highlightedChapter + chapterOffSet <= 0 ||\n highlightedChapter + chapterOffSet > fetchEndChapter(highlightedBookId)\n ) {\n setHighlightedChapter(0);\n } else if (chapterOffSet !== 0) {\n setHighlightedChapter(highlightedChapter + chapterOffSet);\n event.preventDefault();\n }\n }\n };\n\n useEffect(() => {\n if (selectedBookId === highlightedBookId) {\n if (selectedBookId === Canon.bookNumberToId(scrRef.bookNum)) {\n setHighlightedChapter(scrRef.chapterNum);\n } else {\n setHighlightedChapter(1);\n }\n } else {\n setHighlightedChapter(0);\n }\n }, [highlightedBookId, scrRef.bookNum, scrRef.chapterNum, selectedBookId]);\n\n // The purpose of these useLayoutEffects and timeout is to delay the scroll just\n // enough so that the refs are defined and available when they are used after the timeout\n useLayoutEffect(() => {\n setIsContentOpenDelayed(isContentOpen);\n }, [isContentOpen]);\n\n useLayoutEffect(() => {\n const scrollTimeout = setTimeout(() => {\n if (isContentOpenDelayed && contentRef.current && menuItemRef.current) {\n const menuItemOffsetTop = menuItemRef.current.offsetTop;\n const scrollPosition = menuItemOffsetTop - SCROLL_OFFSET;\n contentRef.current.scrollTo({ top: scrollPosition, behavior: 'instant' });\n }\n }, 10);\n return () => {\n clearTimeout(scrollTimeout);\n };\n }, [isContentOpenDelayed]);\n\n return (\n
    \n \n \n {\n setSelectedBookId(Canon.bookNumberToId(scrRef.bookNum));\n setHighlightedBookId(Canon.bookNumberToId(scrRef.bookNum));\n setHighlightedChapter(scrRef.chapterNum > 0 ? scrRef.chapterNum : 0);\n setIsContentOpen(true);\n inputRef.current.focus();\n }}\n onFocus={() => {\n // Radix thinks we want to close because the input is being focused. Prevent that\n shouldPreventAutoClosing.current = true;\n }}\n handleSubmit={handleInputSubmit}\n placeholder={`${Canon.bookNumberToEnglishName(scrRef.bookNum)} ${scrRef.chapterNum}:${scrRef.verseNum}`}\n />\n \n \n console.log('sorting')}\n handleLocationHistory={() => console.log('location history')}\n handleBookmarks={() => console.log('bookmarks')}\n />\n {BOOK_TYPE_ARRAY.map(\n (bookType, bookTypeIndex) =>\n fetchFilteredBooks(bookType).length > 0 && (\n
    \n \n {BOOK_TYPE_LABELS[bookType]}\n \n\n {fetchFilteredBooks(bookType).map((bookId) => (\n
    \n updateReference(bookId, false)}\n isSelected={selectedBookId === bookId}\n handleHighlightBook={() => setHighlightedBookId(bookId)}\n handleKeyDown={handleKeyDownMenuItem}\n bookType={bookType}\n ref={(element: HTMLDivElement) => {\n if (selectedBookId === bookId) menuItemRef.current = element;\n }}\n >\n {\n setHighlightedChapter(chapterNumber);\n }}\n />\n \n
    \n ))}\n {BOOK_TYPE_ARRAY.length - 1 !== bookTypeIndex ? (\n \n ) : undefined}\n
    \n ),\n )}\n \n
    \n
    \n );\n}\n\nexport default BookChapterControl;\n","import React from 'react';\nimport { Slot } from '@radix-ui/react-slot';\nimport { cva, type VariantProps } from 'class-variance-authority';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport const buttonVariants = cva(\n 'pr-twp tw-inline-flex tw-items-center tw-justify-center tw-whitespace-nowrap tw-rounded-md tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-colors focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50',\n {\n variants: {\n variant: {\n default: 'tw-bg-primary tw-text-primary-foreground hover:tw-bg-primary/90',\n destructive: 'tw-bg-destructive tw-text-destructive-foreground hover:tw-bg-destructive/90',\n outline:\n 'tw-border tw-border-input tw-bg-background hover:tw-bg-accent hover:tw-text-accent-foreground',\n secondary: 'tw-bg-secondary tw-text-secondary-foreground hover:tw-bg-secondary/80',\n ghost: 'hover:tw-bg-accent hover:tw-text-accent-foreground',\n link: 'tw-text-primary tw-underline-offset-4 hover:tw-underline',\n },\n size: {\n default: 'tw-h-10 tw-px-4 tw-py-2',\n sm: 'tw-h-9 tw-rounded-md tw-px-3',\n lg: 'tw-h-11 tw-rounded-md tw-px-8',\n icon: 'tw-h-10 tw-w-10',\n },\n },\n defaultVariants: {\n variant: 'default',\n size: 'default',\n },\n },\n);\n\nexport interface ButtonProps\n extends React.ButtonHTMLAttributes,\n VariantProps {\n asChild?: boolean;\n}\n\nexport const Button = React.forwardRef(\n ({ className, variant, size, asChild = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'button';\n return (\n \n );\n },\n);\nButton.displayName = 'Button';\n","import React from 'react';\nimport * as LabelPrimitive from '@radix-ui/react-label';\nimport { cva, type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst labelVariants = cva(\n 'tw-text-sm tw-font-medium tw-leading-none peer-disabled:tw-cursor-not-allowed peer-disabled:tw-opacity-70',\n);\n\nexport const Label = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef & VariantProps\n>(({ className, ...props }, ref) => (\n \n));\nLabel.displayName = LabelPrimitive.Root.displayName;\n","import React from 'react';\nimport * as RadioGroupPrimitive from '@radix-ui/react-radio-group';\nimport { Circle } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst RadioGroup = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => {\n return (\n \n );\n});\nRadioGroup.displayName = RadioGroupPrimitive.Root.displayName;\n\nconst RadioGroupItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => {\n return (\n \n \n \n \n \n );\n});\nRadioGroupItem.displayName = RadioGroupPrimitive.Item.displayName;\n\nexport { RadioGroup, RadioGroupItem };\n","import React from 'react';\nimport * as PopoverPrimitive from '@radix-ui/react-popover';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Popover = PopoverPrimitive.Root;\n\nconst PopoverTrigger = PopoverPrimitive.Trigger;\n\nconst PopoverContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, align = 'center', sideOffset = 4, ...props }, ref) => (\n \n \n \n));\nPopoverContent.displayName = PopoverPrimitive.Content.displayName;\n\nexport { Popover, PopoverTrigger, PopoverContent };\n","import React from 'react';\nimport * as DialogPrimitive from '@radix-ui/react-dialog';\nimport { X } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Dialog = DialogPrimitive.Root;\n\nconst DialogTrigger = DialogPrimitive.Trigger;\n\nconst DialogPortal = DialogPrimitive.Portal;\n\nconst DialogClose = DialogPrimitive.Close;\n\nconst DialogOverlay = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nDialogOverlay.displayName = DialogPrimitive.Overlay.displayName;\n\nconst DialogContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, ...props }, ref) => (\n \n \n \n {children}\n \n \n Close\n \n \n \n));\nDialogContent.displayName = DialogPrimitive.Content.displayName;\n\nfunction DialogHeader({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nDialogHeader.displayName = 'DialogHeader';\n\nfunction DialogFooter({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nDialogFooter.displayName = 'DialogFooter';\n\nconst DialogTitle = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nDialogTitle.displayName = DialogPrimitive.Title.displayName;\n\nconst DialogDescription = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nDialogDescription.displayName = DialogPrimitive.Description.displayName;\n\nexport {\n Dialog,\n DialogPortal,\n DialogOverlay,\n DialogClose,\n DialogTrigger,\n DialogContent,\n DialogHeader,\n DialogFooter,\n DialogTitle,\n DialogDescription,\n};\n","import React from 'react';\nimport { type DialogProps } from '@radix-ui/react-dialog';\nimport { Command as CommandPrimitive } from 'cmdk';\nimport { Search } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Dialog, DialogContent } from '@/components/shadcn-ui/dialog';\n\nconst Command = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nCommand.displayName = CommandPrimitive.displayName;\n\ninterface CommandDialogProps extends DialogProps {}\n\nfunction CommandDialog({ children, ...props }: CommandDialogProps) {\n return (\n \n \n \n {children}\n \n \n \n );\n}\n\nconst CommandInput = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n
    \n \n \n
    \n));\n\nCommandInput.displayName = CommandPrimitive.Input.displayName;\n\nconst CommandList = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\n\nCommandList.displayName = CommandPrimitive.List.displayName;\n\nconst CommandEmpty = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>((props, ref) => (\n \n));\n\nCommandEmpty.displayName = CommandPrimitive.Empty.displayName;\n\nconst CommandGroup = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\n\nCommandGroup.displayName = CommandPrimitive.Group.displayName;\n\nconst CommandSeparator = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nCommandSeparator.displayName = CommandPrimitive.Separator.displayName;\n\nconst CommandItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\n\nCommandItem.displayName = CommandPrimitive.Item.displayName;\n\nfunction CommandShortcut({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nCommandShortcut.displayName = 'CommandShortcut';\n\nexport {\n Command,\n CommandDialog,\n CommandInput,\n CommandList,\n CommandEmpty,\n CommandGroup,\n CommandItem,\n CommandShortcut,\n CommandSeparator,\n};\n","import { useState } from 'react';\nimport { Check, ChevronsUpDown } from 'lucide-react';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport { Popover, PopoverContent, PopoverTrigger } from '@/components/shadcn-ui/popover';\nimport {\n Command,\n CommandEmpty,\n CommandInput,\n CommandItem,\n CommandList,\n} from '@/components/shadcn-ui/command';\nimport { PopoverProps } from '@radix-ui/react-popover';\n\nexport type ComboBoxLabelOption = { label: string };\nexport type ComboBoxOption = string | number | ComboBoxLabelOption;\n\nexport type ComboBoxProps = {\n /** Optional unique identifier */\n id?: string;\n /** Text label title for combobox */\n /** List of available options for the dropdown menu */\n options?: readonly T[];\n /** @deprecated 3 December 2024. Renamed to {@link buttonClassName} */\n className?: string;\n /** Additional css classes to help with unique styling of the combo box button */\n buttonClassName?: string;\n /** Additional css classes to help with unique styling of the combo box popover */\n popoverContentClassName?: string;\n /**\n * The selected value that the combo box currently holds. Must be shallow equal to one of the\n * options entries.\n */\n value?: T;\n /** Triggers when content of textfield is changed */\n onChange?: (newValue: T) => void;\n /** Used to determine the string value for a given option. */\n getOptionLabel?: (option: ComboBoxOption) => string;\n /** Text displayed on button if `value` is undefined */\n buttonPlaceholder?: string;\n /** Placeholder text for text field */\n textPlaceholder?: string;\n /** Text to display when no options match input */\n commandEmptyMessage?: string;\n /** Variant of button */\n buttonVariant?: ButtonProps['variant'];\n /** Text direction ltr or rtl */\n dir?: Direction;\n /** Optional boolean to set if trigger should be disabled */\n isDisabled?: boolean;\n} & PopoverProps;\n\ntype Direction = 'ltr' | 'rtl';\n\nfunction getOptionLabelDefault(option: ComboBoxOption): string {\n if (typeof option === 'string') {\n return option;\n }\n if (typeof option === 'number') {\n return option.toString();\n }\n return option.label;\n}\n\n/**\n * Autocomplete input and command palette with a list of suggestions.\n *\n * Thanks to Shadcn for heavy inspiration and documentation\n * https://ui.shadcn.com/docs/components/combobox\n */\nfunction ComboBox({\n id,\n options = [],\n buttonClassName,\n popoverContentClassName,\n value,\n onChange = () => {},\n getOptionLabel = getOptionLabelDefault,\n buttonPlaceholder = '',\n textPlaceholder = '',\n commandEmptyMessage = 'No option found',\n buttonVariant = 'outline',\n dir = 'ltr',\n isDisabled = false,\n ...props\n}: ComboBoxProps) {\n const [open, setOpen] = useState(false);\n\n return (\n \n \n \n \n {value ? getOptionLabel(value) : buttonPlaceholder}\n \n \n \n \n \n \n \n {commandEmptyMessage}\n \n {options.map((option) => (\n {\n onChange(option);\n setOpen(false);\n }}\n >\n \n {getOptionLabel(option)}\n \n ))}\n \n \n \n \n );\n}\n\nexport default ComboBox;\n","import { useMemo } from 'react';\nimport ComboBox from '@/components/basics/combo-box.component';\nimport { Label } from '@/components/shadcn-ui/label';\n\nexport type ChapterRangeSelectorProps = {\n startChapter: number;\n endChapter: number;\n handleSelectStartChapter: (chapter: number) => void;\n handleSelectEndChapter: (chapter: number) => void;\n isDisabled?: boolean;\n chapterCount: number;\n};\n\nexport default function ChapterRangeSelector({\n startChapter,\n endChapter,\n handleSelectStartChapter,\n handleSelectEndChapter,\n isDisabled = false,\n chapterCount,\n}: ChapterRangeSelectorProps) {\n const chapterOptions = useMemo(\n () => Array.from({ length: chapterCount }, (_, index) => index + 1),\n [chapterCount],\n );\n\n const onChangeStartChapter = (value: number) => {\n handleSelectStartChapter(value);\n if (value > endChapter) {\n handleSelectEndChapter(value);\n }\n };\n\n const onChangeEndChapter = (value: number) => {\n handleSelectEndChapter(value);\n if (value < startChapter) {\n handleSelectStartChapter(value);\n }\n };\n\n return (\n <>\n \n option.toString()}\n value={startChapter}\n />\n\n \n option.toString()}\n value={endChapter}\n />\n \n );\n}\n","import { Button } from '@/components/shadcn-ui/button';\nimport { Label } from '@/components/shadcn-ui/label';\nimport { RadioGroup, RadioGroupItem } from '@/components/shadcn-ui/radio-group';\nimport { Canon } from '@sillsdev/scripture';\nimport { LocalizedStringValue } from 'platform-bible-utils';\nimport { useState } from 'react';\nimport ChapterRangeSelector, {\n ChapterRangeSelectorProps,\n} from '../basics/chapter-range-selector.component';\n\nexport enum BookSelectionMode {\n CURRENT_BOOK = 'current book',\n CHOOSE_BOOKS = 'choose books',\n}\n\n/**\n * Object containing all keys used for localization in this component. If you're using this\n * component in an extension, you can pass it into the useLocalizedStrings hook to easily obtain the\n * localized strings and pass them into the localizedStrings prop of this component\n */\nexport const BOOK_SELECTOR_STRING_KEYS = Object.freeze([\n '%webView_bookSelector_currentBook%',\n '%webView_bookSelector_choose%',\n '%webView_bookSelector_chooseBooks%',\n] as const);\n\nexport type BookSelectorLocalizedStrings = {\n [localizedInventoryKey in (typeof BOOK_SELECTOR_STRING_KEYS)[number]]?: LocalizedStringValue;\n};\n\n/**\n * Gets the localized value for the provided key\n *\n * @param strings Object containing localized string\n * @param key Key for a localized string\n * @returns The localized value for the provided key, if available. Returns the key if no localized\n * value is available\n */\nconst localizeString = (\n strings: BookSelectorLocalizedStrings,\n key: keyof BookSelectorLocalizedStrings,\n) => {\n return strings[key] ?? key;\n};\n\ntype BookSelectorProps = ChapterRangeSelectorProps & {\n handleBookSelectionModeChange: (newMode: BookSelectionMode) => void;\n currentBookName: string;\n onSelectBooks: () => void;\n selectedBookIds: string[];\n localizedStrings: BookSelectorLocalizedStrings;\n};\n\nexport default function BookSelector({\n handleBookSelectionModeChange,\n currentBookName,\n onSelectBooks,\n selectedBookIds,\n chapterCount,\n endChapter,\n handleSelectEndChapter,\n startChapter,\n handleSelectStartChapter,\n localizedStrings,\n}: BookSelectorProps) {\n const currentBookText = localizeString(localizedStrings, '%webView_bookSelector_currentBook%');\n const chooseText = localizeString(localizedStrings, '%webView_bookSelector_choose%');\n const chooseBooksText = localizeString(localizedStrings, '%webView_bookSelector_chooseBooks%');\n\n const [bookSelectionMode, setBookSelectionMode] = useState(\n BookSelectionMode.CURRENT_BOOK,\n );\n\n const onSelectionModeChange = (newMode: BookSelectionMode) => {\n setBookSelectionMode(newMode);\n handleBookSelectionModeChange(newMode);\n };\n\n return (\n onSelectionModeChange(value as BookSelectionMode)}\n >\n
    \n
    \n
    \n \n \n
    \n \n
    \n \n
    \n
    \n
    \n
    \n \n \n
    \n \n onSelectBooks()}\n >\n {chooseText}\n \n
    \n
    \n \n );\n}\n","import { DropdownMenuTrigger } from '@radix-ui/react-dropdown-menu';\nimport { FilterIcon } from 'lucide-react';\nimport { Table } from '@tanstack/react-table';\n\nimport { Button } from '@/components/shadcn-ui/button';\nimport {\n DropdownMenu,\n DropdownMenuCheckboxItem,\n DropdownMenuContent,\n DropdownMenuLabel,\n DropdownMenuSeparator,\n} from '@/components/shadcn-ui/dropdown-menu';\n\ninterface DataTableViewOptionsProps {\n table: Table;\n}\n\nfunction DataTableViewOptions({ table }: DataTableViewOptionsProps) {\n return (\n \n \n \n \n \n Toggle columns\n \n {table\n .getAllColumns()\n .filter((column) => column.getCanHide())\n .map((column) => {\n return (\n column.toggleVisibility(!!value)}\n >\n {column.id}\n \n );\n })}\n \n \n );\n}\n\nexport default DataTableViewOptions;\n","import React from 'react';\nimport * as SelectPrimitive from '@radix-ui/react-select';\nimport { Check, ChevronDown, ChevronUp } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Select = SelectPrimitive.Root;\n\nconst SelectGroup = SelectPrimitive.Group;\n\nconst SelectValue = SelectPrimitive.Value;\n\nconst SelectTrigger = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, ...props }, ref) => (\n span]:tw-line-clamp-1',\n className,\n )}\n {...props}\n >\n {children}\n \n \n \n \n));\nSelectTrigger.displayName = SelectPrimitive.Trigger.displayName;\n\nconst SelectScrollUpButton = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n));\nSelectScrollUpButton.displayName = SelectPrimitive.ScrollUpButton.displayName;\n\nconst SelectScrollDownButton = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n));\nSelectScrollDownButton.displayName = SelectPrimitive.ScrollDownButton.displayName;\n\nconst SelectContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, position = 'popper', ...props }, ref) => (\n \n \n \n \n {children}\n \n \n \n \n));\nSelectContent.displayName = SelectPrimitive.Content.displayName;\n\nconst SelectLabel = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSelectLabel.displayName = SelectPrimitive.Label.displayName;\n\nconst SelectItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, ...props }, ref) => (\n \n \n \n \n \n \n\n {children}\n \n));\nSelectItem.displayName = SelectPrimitive.Item.displayName;\n\nconst SelectSeparator = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSelectSeparator.displayName = SelectPrimitive.Separator.displayName;\n\nexport {\n Select,\n SelectGroup,\n SelectValue,\n SelectTrigger,\n SelectContent,\n SelectLabel,\n SelectItem,\n SelectSeparator,\n SelectScrollUpButton,\n SelectScrollDownButton,\n};\n","import { ChevronLeftIcon, ChevronRightIcon, ArrowLeftIcon, ArrowRightIcon } from 'lucide-react';\nimport { Table } from '@tanstack/react-table';\n\nimport { Button } from '@/components/shadcn-ui/button';\nimport {\n Select,\n SelectContent,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\n\ninterface DataTablePaginationProps {\n table: Table;\n}\n\nfunction DataTablePagination({ table }: DataTablePaginationProps) {\n return (\n
    \n
    \n
    \n {table.getFilteredSelectedRowModel().rows.length} of{' '}\n {table.getFilteredRowModel().rows.length} row(s) selected\n
    \n
    \n

    Rows per page

    \n {\n table.setPageSize(Number(value));\n }}\n >\n \n \n \n \n {[10, 20, 30, 40, 50].map((pageSize) => (\n \n {pageSize}\n \n ))}\n \n \n
    \n
    \n Page {table.getState().pagination.pageIndex + 1} of {table.getPageCount()}\n
    \n
    \n table.setPageIndex(0)}\n disabled={!table.getCanPreviousPage()}\n >\n Go to first page\n \n \n table.previousPage()}\n disabled={!table.getCanPreviousPage()}\n >\n Go to previous page\n \n \n table.nextPage()}\n disabled={!table.getCanNextPage()}\n >\n Go to next page\n \n \n table.setPageIndex(table.getPageCount() - 1)}\n disabled={!table.getCanNextPage()}\n >\n Go to last page\n \n \n
    \n
    \n
    \n );\n}\n\nexport default DataTablePagination;\n","import React from 'react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Table = React.forwardRef<\n HTMLTableElement,\n React.HTMLAttributes & { stickyHeader?: boolean }\n>(({ className, stickyHeader, ...props }, ref) => (\n
    \n \n
    \n));\nTable.displayName = 'Table';\n\nconst TableHeader = React.forwardRef<\n HTMLTableSectionElement,\n React.HTMLAttributes & { stickyHeader?: boolean }\n>(({ className, stickyHeader, ...props }, ref) => (\n \n));\nTableHeader.displayName = 'TableHeader';\n\nconst TableBody = React.forwardRef<\n HTMLTableSectionElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableBody.displayName = 'TableBody';\n\nconst TableFooter = React.forwardRef<\n HTMLTableSectionElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n tr]:last:tw-border-b-0', className)}\n {...props}\n />\n));\nTableFooter.displayName = 'TableFooter';\n\nconst TableRow = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nTableRow.displayName = 'TableRow';\n\nconst TableHead = React.forwardRef<\n HTMLTableCellElement,\n React.ThHTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableHead.displayName = 'TableHead';\n\nconst TableCell = React.forwardRef<\n HTMLTableCellElement,\n React.TdHTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableCell.displayName = 'TableCell';\n\nconst TableCaption = React.forwardRef<\n HTMLTableCaptionElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableCaption.displayName = 'TableCaption';\n\nexport { Table, TableHeader, TableBody, TableFooter, TableHead, TableRow, TableCell, TableCaption };\n","import { useState } from 'react';\n\nimport {\n ColumnFiltersState,\n flexRender,\n getCoreRowModel,\n getFilteredRowModel,\n getPaginationRowModel,\n getSortedRowModel,\n SortingState,\n ColumnDef as TSColumnDef,\n Row as TSRow,\n RowSelectionState as TSRowSelectionState,\n SortDirection as TSSortDirection,\n Table as TSTable,\n useReactTable,\n VisibilityState,\n} from '@tanstack/react-table';\n\nimport DataTableViewOptions from '@/components/advanced/data-table/data-table-column-toggle.component';\nimport DataTablePagination from '@/components/advanced/data-table/data-table-pagination.component';\nimport { Button } from '@/components/shadcn-ui/button';\nimport {\n Table,\n TableBody,\n TableCell,\n TableHead,\n TableHeader,\n TableRow,\n} from '@/components/shadcn-ui/table';\n\nexport type ColumnDef = TSColumnDef;\nexport type RowContents = TSRow;\nexport type TableContents = TSTable;\nexport type SortDirection = TSSortDirection;\nexport type RowSelectionState = TSRowSelectionState;\n\ninterface DataTableProps {\n columns: ColumnDef[];\n data: TData[];\n enablePagination?: boolean;\n showPaginationControls?: boolean;\n showColumnVisibilityControls?: boolean;\n stickyHeader?: boolean;\n onRowClickHandler?: (row: RowContents, table: TableContents) => void;\n}\n\n/**\n * Feature-rich table component that infuses our basic shadcn-based Table component with features\n * from TanStack's React Table library\n */\nfunction DataTable({\n columns,\n data,\n enablePagination = false,\n showPaginationControls = false,\n showColumnVisibilityControls = false,\n stickyHeader = false,\n onRowClickHandler = () => {},\n}: DataTableProps) {\n const [sorting, setSorting] = useState([]);\n const [columnFilters, setColumnFilters] = useState([]);\n const [columnVisibility, setColumnVisibility] = useState({});\n const [rowSelection, setRowSelection] = useState({});\n\n const table = useReactTable({\n data,\n columns,\n getCoreRowModel: getCoreRowModel(),\n ...(enablePagination && { getPaginationRowModel: getPaginationRowModel() }),\n onSortingChange: setSorting,\n getSortedRowModel: getSortedRowModel(),\n onColumnFiltersChange: setColumnFilters,\n getFilteredRowModel: getFilteredRowModel(),\n onColumnVisibilityChange: setColumnVisibility,\n onRowSelectionChange: setRowSelection,\n state: {\n sorting,\n columnFilters,\n columnVisibility,\n rowSelection,\n },\n });\n\n return (\n
    \n {showColumnVisibilityControls && }\n \n \n {table.getHeaderGroups().map((headerGroup) => (\n \n {headerGroup.headers.map((header) => {\n return (\n \n {header.isPlaceholder\n ? undefined\n : flexRender(header.column.columnDef.header, header.getContext())}\n \n );\n })}\n \n ))}\n \n \n {table.getRowModel().rows?.length ? (\n table.getRowModel().rows.map((row) => (\n onRowClickHandler(row, table)}\n key={row.id}\n data-state={row.getIsSelected() && 'selected'}\n >\n {row.getVisibleCells().map((cell) => (\n \n {flexRender(cell.column.columnDef.cell, cell.getContext())}\n \n ))}\n \n ))\n ) : (\n \n \n No results.\n \n \n )}\n \n
    \n {enablePagination && (\n
    \n table.previousPage()}\n disabled={!table.getCanPreviousPage()}\n >\n Previous\n \n table.nextPage()}\n disabled={!table.getCanNextPage()}\n >\n Next\n \n
    \n )}\n {enablePagination && showPaginationControls && }\n
    \n );\n}\n\nexport default DataTable;\n","import {\n Table,\n TableBody,\n TableCell,\n TableHead,\n TableHeader,\n TableRow,\n} from '@/components/shadcn-ui/table';\nimport { Canon } from '@sillsdev/scripture';\nimport { deepEqual, LanguageStrings, ScriptureReference } from 'platform-bible-utils';\nimport { useMemo } from 'react';\nimport { InventoryItemOccurrence } from './inventory-utils';\n\n/** Props for the OccurrencesTable component */\ntype OccurrencesTableProps = {\n /** Data that contains scriptures references and snippets of scripture */\n occurrenceData: InventoryItemOccurrence[];\n /** Callback function that is executed when the scripture reference is changed */\n setScriptureReference: (scriptureReference: ScriptureReference) => void;\n /**\n * Object with all localized strings that the OccurrencesTable needs to work well across multiple\n * languages\n */\n localizedStrings: LanguageStrings;\n};\n\n/**\n * Table that shows occurrences of specified inventory item(s). The first column shows the related\n * scripture reference. The second column shows the snippet of scripture that contains the specified\n * inventory item\n */\nfunction OccurrencesTable({\n occurrenceData,\n setScriptureReference,\n localizedStrings,\n}: OccurrencesTableProps) {\n const referenceHeaderText =\n localizedStrings['%webView_inventory_occurrences_table_header_reference%'];\n const occurrenceHeaderText =\n localizedStrings['%webView_inventory_occurrences_table_header_occurrence%'];\n\n const occurrences: InventoryItemOccurrence[] = useMemo(() => {\n const uniqueOccurrences: InventoryItemOccurrence[] = [];\n\n occurrenceData.forEach((occurrence) => {\n if (!uniqueOccurrences.some((uniqueOccurrence) => deepEqual(uniqueOccurrence, occurrence))) {\n uniqueOccurrences.push(occurrence);\n }\n });\n\n return uniqueOccurrences;\n }, [occurrenceData]);\n\n return (\n \n \n \n {referenceHeaderText}\n {occurrenceHeaderText}\n \n \n \n {occurrences.length > 0 &&\n occurrences.map((occurrence) => (\n {\n setScriptureReference(occurrence.reference);\n }}\n >\n {`${Canon.bookNumberToEnglishName(occurrence.reference.bookNum)} ${occurrence.reference.chapterNum}:${occurrence.reference.verseNum}`}\n {occurrence.text}\n \n ))}\n \n
    \n );\n}\n\nexport default OccurrencesTable;\n","import React from 'react';\nimport * as CheckboxPrimitive from '@radix-ui/react-checkbox';\nimport { Check } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Checkbox = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n \n \n));\nCheckbox.displayName = CheckboxPrimitive.Root.displayName;\n\nexport default Checkbox;\n","import { Canon } from '@sillsdev/scripture';\nimport { ScriptureReference } from 'platform-bible-utils';\n\n/* #region Types */\n\n/**\n * Status of items that appear in inventories. 'approved' and 'unapproved' items are defined in the\n * project's `Settings.xml`. All other items are defined as 'unknown'\n */\nexport type Status = 'approved' | 'unapproved' | 'unknown';\n\n/** Occurrence of item in inventory. Primarily used by table that shows occurrences */\nexport type InventoryItemOccurrence = {\n /** Reference to scripture where the item appears */\n reference: ScriptureReference;\n /** Snippet of scripture that contains the occurrence */\n text: string;\n};\n\n/** Data structure that contains all information on an item that is shown in an inventory */\nexport type InventoryTableData = {\n /**\n * The item (e.g. a character in the characters inventory, a marker in the marker inventory) In\n * most cases the array will only have one element. In case of additional items (e.g. the\n * preceding marker in the markers check), the primary item should be stored in the first index.\n * To show additional items in the inventory, make sure to configure the `additionalItemsLabels`\n * prop for the Inventory component\n */\n items: string[];\n /** The number of times this item occurs in the selected scope */\n count: number;\n /** The status of this item (see documentation for `Status` type for more information) */\n status: Status;\n /** Occurrences of this item in the scripture text for the selected scope */\n occurrences: InventoryItemOccurrence[];\n};\n\n/* #endregion */\n\n/* #region Functions */\n\n/**\n * Splits USFM string into shorter line-like segments\n *\n * @param text A single (likely very large) USFM string\n * @returns An array containing the input text, split into shorter segments\n */\nexport const getLinesFromUSFM = (text: string) => {\n // Splits on (CR)LF, CR, \\v, \\c and \\id\n return text.split(/(?:\\r?\\n|\\r)|(?=(?:\\\\(?:v|c|id)))/g);\n};\n\n/**\n * Extracts chapter or verse number from USFM strings that start with a \\c or \\v marker\n *\n * @param text USFM string that is expected to start with \\c or \\v marker\n * @returns Chapter or verse number if one is found. Else returns 0.\n */\nexport const getNumberFromUSFM = (text: string): number | undefined => {\n // Captures all digits that follow \\v or \\c markers followed by whitespace located at the start of a string\n const regex = /^\\\\[vc]\\s+(\\d+)/;\n const match = text.match(regex);\n\n if (match) {\n return +match[1];\n }\n return undefined;\n};\n\n/**\n * Gets book ID from USFM string that starts with the \\id marker, and returns book number for it\n *\n * @param text USFM string that is expected to start with \\id marker\n * @returns Book number corresponding to the \\id marker in the input text. Returns 0 if no marker is\n * found or the marker is not valid\n */\nexport const getBookNumFromId = (text: string): number => {\n // Captures all digits that follow an \\id marker followed by whitespace located at the start of a string\n const match = text.match(/^\\\\id\\s+([A-Za-z]+)/);\n if (match) {\n return Canon.bookIdToNumber(match[1]);\n }\n return 0;\n};\n\n/**\n * Gets the status for an item, typically used in the Inventory component\n *\n * @param item The item for which the status is being requested\n * @param approvedItems Array of approved items, typically as defined in `Settings.xml`\n * @param unapprovedItems Array of unapproved items, typically as defined in `Settings.xml`\n * @returns The status for the specified item\n */\nexport const getStatusForItem = (\n item: string,\n approvedItems: string[],\n unapprovedItems: string[],\n): Status => {\n if (unapprovedItems.includes(item)) return 'unapproved';\n if (approvedItems.includes(item)) return 'approved';\n return 'unknown';\n};\n\n/* #endregion */\n","import React from 'react';\nimport * as TogglePrimitive from '@radix-ui/react-toggle';\nimport { cva, type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst toggleVariants = cva(\n 'pr-twp tw-inline-flex tw-items-center tw-justify-center tw-rounded-md tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-colors hover:tw-bg-muted hover:tw-text-muted-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50 data-[state=on]:tw-bg-accent data-[state=on]:tw-text-accent-foreground',\n {\n variants: {\n variant: {\n default: 'tw-bg-transparent',\n outline:\n 'tw-border tw-border-input tw-bg-transparent hover:tw-bg-accent hover:tw-text-accent-foreground',\n },\n size: {\n default: 'tw-h-10 tw-px-3',\n sm: 'tw-h-9 tw-px-2.5',\n lg: 'tw-h-11 tw-px-5',\n },\n },\n defaultVariants: {\n variant: 'default',\n size: 'default',\n },\n },\n);\n\nconst Toggle = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef & VariantProps\n>(({ className, variant, size, ...props }, ref) => (\n \n));\n\nToggle.displayName = TogglePrimitive.Root.displayName;\n\nexport { Toggle, toggleVariants };\n","import React from 'react';\nimport * as ToggleGroupPrimitive from '@radix-ui/react-toggle-group';\nimport { type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { toggleVariants } from '@/components/shadcn-ui/toggle';\n\nconst ToggleGroupContext = React.createContext>({\n size: 'default',\n variant: 'default',\n});\n\nconst ToggleGroup = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef &\n VariantProps\n>(({ className, variant, size, children, ...props }, ref) => (\n \n \n {children}\n \n \n));\n\nToggleGroup.displayName = ToggleGroupPrimitive.Root.displayName;\n\nconst ToggleGroupItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef &\n VariantProps\n>(({ className, children, variant, size, ...props }, ref) => {\n const context = React.useContext(ToggleGroupContext);\n\n return (\n \n {children}\n \n );\n});\n\nToggleGroupItem.displayName = ToggleGroupPrimitive.Item.displayName;\n\nexport { ToggleGroup, ToggleGroupItem };\n","import { ColumnDef, SortDirection } from '@/components/advanced/data-table/data-table.component';\nimport { Button } from '@/components/shadcn-ui/button';\nimport { ToggleGroup, ToggleGroupItem } from '@/components/shadcn-ui/toggle-group';\nimport {\n ArrowDownIcon,\n ArrowUpDownIcon,\n ArrowUpIcon,\n CircleCheckIcon,\n CircleHelpIcon,\n CircleXIcon,\n} from 'lucide-react';\nimport { ReactNode } from 'react';\nimport { InventoryTableData, Status } from './inventory-utils';\n\n/**\n * Gets an icon that indicates the current sorting direction based on the provided input\n *\n * @param sortDirection Sorting direction. Can be ascending ('asc'), descending ('desc') or false (\n * i.e. not sorted)\n * @returns The appropriate sorting icon for the provided sorting direction\n */\nconst getSortingIcon = (sortDirection: false | SortDirection): ReactNode => {\n if (sortDirection === 'asc') {\n return ;\n }\n if (sortDirection === 'desc') {\n return ;\n }\n return ;\n};\n\n/**\n * Function that creates the item column for inventories\n *\n * @param itemLabel Localized label for the item column (e.g. 'Character', 'Repeated Word', etc.)\n * @returns Column that shows the inventory items. Should be used with the DataTable component\n */\nexport const inventoryItemColumn = (itemLabel: string): ColumnDef => {\n return {\n accessorKey: 'item',\n accessorFn: (row: InventoryTableData) => row.items[0],\n header: ({ column }) => (\n \n ),\n };\n};\n\n/**\n * Function that creates the additional item columns for inventories\n *\n * @param additionalItemLabel Localized label for the additional item column (e.g. 'Preceding\n * Marker')\n * @param additionalItemIndex Index that locates the desired item in the items array of the\n * inventory\n * @returns Column that shows additional inventory items. Should be used with the DataTable\n * component\n */\nexport const inventoryAdditionalItemColumn = (\n additionalItemLabel: string,\n additionalItemIndex: number,\n): ColumnDef => {\n return {\n accessorKey: `item${additionalItemIndex}`,\n accessorFn: (row: InventoryTableData) => row.items[additionalItemIndex],\n header: ({ column }) => (\n \n ),\n };\n};\n\n/**\n * Function that creates the count column for inventories. Should be used with the DataTable\n * component.\n *\n * @param itemLabel Localized label for the count column\n * @returns Column that shows the number of occurrences of the related inventory items\n */\nexport const inventoryCountColumn = (countLabel: string): ColumnDef => {\n return {\n accessorKey: 'count',\n header: ({ column }) => (\n
    \n \n
    \n ),\n cell: ({ row }) =>
    {row.getValue('count')}
    ,\n };\n};\n\n/**\n * Function that updates project settings when status for item(s) changes\n *\n * @param changedItems Array of items for which the status is being updated\n * @param newStatus The status that the items are being given\n * @param approvedItems Array of currently approved items\n * @param onApprovedItemsChange Callback function that stores the updated list of approved items\n * @param unapprovedItems Array of currently unapproved items\n * @param onUnapprovedItemsChange Callback function that stores the updated list of unapproved items\n */\nconst statusChangeHandler = (\n changedItems: string[],\n newStatus: Status,\n approvedItems: string[],\n onApprovedItemsChange: (items: string[]) => void,\n unapprovedItems: string[],\n onUnapprovedItemsChange: (items: string[]) => void,\n) => {\n let newApprovedItems: string[] = [...approvedItems];\n changedItems.forEach((item) => {\n if (newStatus === 'approved') {\n if (!newApprovedItems.includes(item)) {\n newApprovedItems.push(item);\n }\n } else {\n newApprovedItems = newApprovedItems.filter((validItem) => validItem !== item);\n }\n });\n onApprovedItemsChange(newApprovedItems);\n\n let newUnapprovedItems: string[] = [...unapprovedItems];\n changedItems.forEach((item) => {\n if (newStatus === 'unapproved') {\n if (!newUnapprovedItems.includes(item)) {\n newUnapprovedItems.push(item);\n }\n } else {\n newUnapprovedItems = newUnapprovedItems.filter((unapprovedItem) => unapprovedItem !== item);\n }\n });\n onUnapprovedItemsChange(newUnapprovedItems);\n};\n\n/**\n * Function that creates the status column for inventories. Should be used with the DataTable\n * component.\n *\n * @param statusLabel Localized label for the status column\n * @param approvedItems Array of approved items, typically as defined in `Settings.xml`\n * @param onApprovedItemsChange Callback function that stores the updated list of approved items\n * @param unapprovedItems Array of unapproved items, typically as defined in `Settings.xml`\n * @param onUnapprovedItemsChange Callback function that stores the updated list of unapproved items\n * @returns Column that shows the status buttons for the related inventory item. The button for the\n * current status of the item is selected\n */\nexport const inventoryStatusColumn = (\n statusLabel: string,\n approvedItems: string[],\n onApprovedItemsChange: (items: string[]) => void,\n unapprovedItems: string[],\n onUnapprovedItemsChange: (items: string[]) => void,\n): ColumnDef => {\n return {\n accessorKey: 'status',\n header: ({ column }) => {\n return (\n
    \n \n
    \n );\n },\n cell: ({ row }) => {\n const status: Status = row.getValue('status');\n const item: string = row.getValue('item');\n return (\n \n \n statusChangeHandler(\n [item],\n 'approved',\n approvedItems,\n onApprovedItemsChange,\n unapprovedItems,\n onUnapprovedItemsChange,\n )\n }\n value=\"approved\"\n >\n \n \n \n statusChangeHandler(\n [item],\n 'unapproved',\n approvedItems,\n onApprovedItemsChange,\n unapprovedItems,\n onUnapprovedItemsChange,\n )\n }\n value=\"unapproved\"\n >\n \n \n \n statusChangeHandler(\n [item],\n 'unknown',\n approvedItems,\n onApprovedItemsChange,\n unapprovedItems,\n onUnapprovedItemsChange,\n )\n }\n value=\"unknown\"\n >\n \n \n \n );\n },\n };\n};\n","import DataTable, {\n ColumnDef,\n RowContents,\n RowSelectionState,\n TableContents,\n} from '@/components/advanced/data-table/data-table.component';\nimport OccurrencesTable from '@/components/advanced/inventory/occurrences-table.component';\nimport Checkbox from '@/components/shadcn-ui/checkbox';\nimport { Input } from '@/components/shadcn-ui/input';\nimport { Label } from '@/components/shadcn-ui/label';\nimport {\n Select,\n SelectContent,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\nimport {\n deepEqual,\n LocalizedStringValue,\n ScriptureReference,\n substring,\n} from 'platform-bible-utils';\nimport { useEffect, useMemo, useState } from 'react';\nimport {\n getBookNumFromId,\n getLinesFromUSFM,\n getNumberFromUSFM,\n getStatusForItem,\n InventoryItemOccurrence,\n InventoryTableData,\n Status,\n} from './inventory-utils';\nimport { inventoryAdditionalItemColumn } from './inventory-columns';\n\n/**\n * Object containing all keys used for localization in this component. If you're using this\n * component in an extension, you can pass it into the useLocalizedStrings hook to easily obtain the\n * localized strings and pass them into the localizedStrings prop of this component\n */\nexport const INVENTORY_STRING_KEYS = Object.freeze([\n '%webView_inventory_all%',\n '%webView_inventory_approved%',\n '%webView_inventory_unapproved%',\n '%webView_inventory_unknown%',\n '%webView_inventory_scope_currentBook%',\n '%webView_inventory_scope_chapter%',\n '%webView_inventory_scope_verse%',\n '%webView_inventory_filter_text%',\n '%webView_inventory_show_additional_items%',\n '%webView_inventory_occurrences_table_header_reference%',\n '%webView_inventory_occurrences_table_header_occurrence%',\n] as const);\n\nexport type InventoryLocalizedStrings = {\n [localizedInventoryKey in (typeof INVENTORY_STRING_KEYS)[number]]?: LocalizedStringValue;\n};\n\n/** Scope of scripture that the inventory can operate on */\nexport type Scope = 'book' | 'chapter' | 'verse';\n\n/** Status values that the status filter can select from */\ntype StatusFilter = Status | 'all';\n\n/** Text labels for the inventory columns and the control components of additional inventory items */\ntype AdditionalItemsLabels = {\n checkboxText?: string;\n tableHeaders?: string[];\n};\n\n/**\n * Filters data that is shown in the DataTable section of the Inventory\n *\n * @param itemData All inventory items and their related information\n * @param statusFilter Allows filtering by status (i.e. show all items, or only items that are\n * 'approved', 'unapproved' or 'unknown')\n * @param textFilter Allows filtering by text. All items that include the filter text will be\n * selected.\n * @returns Array of items and their related information that are matched by the specified filters\n */\nconst filterItemData = (\n itemData: InventoryTableData[],\n statusFilter: StatusFilter,\n textFilter: string,\n): InventoryTableData[] => {\n let filteredItemData: InventoryTableData[] = itemData;\n\n if (statusFilter !== 'all') {\n filteredItemData = filteredItemData.filter(\n (item) =>\n (statusFilter === 'approved' && item.status === 'approved') ||\n (statusFilter === 'unapproved' && item.status === 'unapproved') ||\n (statusFilter === 'unknown' && item.status === 'unknown'),\n );\n }\n\n if (textFilter !== '')\n filteredItemData = filteredItemData.filter((item) => item.items[0].includes(textFilter));\n\n return filteredItemData;\n};\n\n/**\n * Turns array of strings into array of inventory items, along with their count and status\n *\n * @param text The source scripture text that is searched for inventory items\n * @param scriptureRef The scripture reference that the application is currently set to\n * @param approvedItems Array of approved items, typically as defined in `Settings.xml`\n * @param unapprovedItems Array of unapproved items, typically as defined in `Settings.xml`\n * @param itemRegex Regular expression that describes what items this Inventory should extract from\n * the provided scripture text\n * @returns Array of inventory items, along with their count and status\n */\nconst createTableData = (\n text: string | undefined,\n scriptureRef: ScriptureReference,\n approvedItems: string[],\n unapprovedItems: string[],\n itemRegex: RegExp,\n): InventoryTableData[] => {\n if (!text) return [];\n\n const tableData: InventoryTableData[] = [];\n\n let currentBook: number | undefined = scriptureRef.bookNum;\n let currentChapter: number | undefined = scriptureRef.chapterNum;\n let currentVerse: number | undefined = scriptureRef.verseNum;\n\n const lines = getLinesFromUSFM(text);\n\n lines.forEach((line: string) => {\n if (line.startsWith('\\\\id')) {\n currentBook = getBookNumFromId(line);\n currentChapter = 0;\n currentVerse = 0;\n }\n if (line.startsWith('\\\\c')) {\n currentChapter = getNumberFromUSFM(line);\n currentVerse = 0;\n }\n if (line.startsWith('\\\\v')) {\n currentVerse = getNumberFromUSFM(line);\n if (currentChapter === 0) {\n currentChapter = scriptureRef.chapterNum;\n }\n }\n\n let match: RegExpExecArray | undefined = itemRegex.exec(line) ?? undefined;\n while (match) {\n const items: string[] = [];\n match.forEach((item) => items.push(item));\n const itemIndex = match.index;\n const existingItem = tableData.find((tableEntry) => deepEqual(tableEntry.items, items));\n const newReference: InventoryItemOccurrence = {\n reference: {\n bookNum: currentBook !== undefined ? currentBook : -1,\n chapterNum: currentChapter !== undefined ? currentChapter : -1,\n verseNum: currentVerse !== undefined ? currentVerse : -1,\n },\n text: substring(line, Math.max(0, itemIndex - 25), Math.min(itemIndex + 25, line.length)),\n };\n if (existingItem) {\n existingItem.count += 1;\n existingItem.occurrences.push(newReference);\n } else {\n const newItem: InventoryTableData = {\n items,\n count: 1,\n status: getStatusForItem(items[0], approvedItems, unapprovedItems),\n occurrences: [newReference],\n };\n tableData.push(newItem);\n }\n\n match = itemRegex.exec(line) ?? undefined;\n }\n });\n\n return tableData;\n};\n\n/**\n * Gets the localized value for the provided key\n *\n * @param strings Object containing localized string\n * @param key Key for a localized string\n * @returns The localized value for the provided key, if available. Returns the key if no localized\n * value is available\n */\nconst localizeString = (\n strings: InventoryLocalizedStrings,\n key: keyof InventoryLocalizedStrings,\n) => {\n return strings[key] ?? key;\n};\n\n/** Props for the Inventory component */\ntype InventoryProps = {\n /** The scripture reference that the application is currently set to */\n scriptureReference: ScriptureReference;\n /** Callback function that is executed when the scripture reference is changed */\n setScriptureReference: (scriptureReference: ScriptureReference) => void;\n /**\n * Object with all localized strings that the Inventory needs to work well across multiple\n * languages. When using this component with Platform.Bible, you can import\n * `INVENTORY_STRING_KEYS` from this library, pass it in to the Platform's localization hook, and\n * pass the localized keys that are returned by the hook into this prop.\n */\n localizedStrings: InventoryLocalizedStrings;\n /**\n * The logic that finds the desired items in the source text. This can either be a Regular\n * expression that captures one or multiple items (preferred), or a custom function that builds\n * and return an InventoryDataTable[] manually. Note: In case the logic captures more than one\n * item (i.e. InventoryTableData.items has a length greater than 1), you must provide text labels\n * for the related columns and control elements to show by setting the `additionalItemsLabels`\n * prop\n */\n extractItems:\n | RegExp\n | ((\n text: string | undefined,\n scriptureRef: ScriptureReference,\n approvedItems: string[],\n unapprovedItems: string[],\n ) => InventoryTableData[]);\n /**\n * Text labels for control elements and additional column headers in case your Inventory has more\n * than one item to show (e.g. The 'Preceding Marker' in the Markers Inventory)\n */\n additionalItemsLabels?: AdditionalItemsLabels;\n /** Array of approved items, typically as defined in `Settings.xml` */\n approvedItems: string[];\n /** Array of unapproved items, typically as defined in `Settings.xml` */\n unapprovedItems: string[];\n /** The source scripture text that is searched for in inventory items */\n text: string | undefined;\n /** Scope of scripture that the inventory will operate on */\n scope: Scope;\n /** Callback function that is executed when the scope is changed from the Inventory */\n onScopeChange: (scope: Scope) => void;\n /**\n * Column definitions for the Inventory data table. The most commonly used column definitions are\n * pre-configured for your convenience and can be imported (e.g. inventoryItemColumn,\n * inventoryAdditionalItemColumn inventoryCountColumn, and inventoryStatusColumn). If you need any\n * other columns you can add these yourself\n */\n columns: ColumnDef[];\n};\n\n/** Inventory component that is used to view and control the status of provided project settings */\nexport default function Inventory({\n scriptureReference,\n setScriptureReference,\n localizedStrings,\n extractItems,\n additionalItemsLabels,\n approvedItems,\n unapprovedItems,\n text,\n scope,\n onScopeChange,\n columns,\n}: InventoryProps) {\n const allItemsText = localizeString(localizedStrings, '%webView_inventory_all%');\n const approvedItemsText = localizeString(localizedStrings, '%webView_inventory_approved%');\n const unapprovedItemsText = localizeString(localizedStrings, '%webView_inventory_unapproved%');\n const unknownItemsText = localizeString(localizedStrings, '%webView_inventory_unknown%');\n const scopeBookText = localizeString(localizedStrings, '%webView_inventory_scope_currentBook%');\n const scopeChapterText = localizeString(localizedStrings, '%webView_inventory_scope_chapter%');\n const scopeVerseText = localizeString(localizedStrings, '%webView_inventory_scope_verse%');\n const filterText = localizeString(localizedStrings, '%webView_inventory_filter_text%');\n const showAdditionalItemsText = localizeString(\n localizedStrings,\n '%webView_inventory_show_additional_items%',\n );\n\n const [showAdditionalItems, setShowAdditionalItems] = useState(false);\n const [statusFilter, setStatusFilter] = useState('all');\n const [textFilter, setTextFilter] = useState('');\n const [selectedItem, setSelectedItem] = useState([]);\n\n const tableData: InventoryTableData[] = useMemo(() => {\n if (!text) return [];\n if (extractItems instanceof RegExp)\n return createTableData(\n text,\n scriptureReference,\n approvedItems,\n unapprovedItems,\n extractItems,\n );\n return extractItems(text, scriptureReference, approvedItems, unapprovedItems);\n }, [text, extractItems, scriptureReference, approvedItems, unapprovedItems]);\n\n const reducedTableData: InventoryTableData[] = useMemo(() => {\n if (showAdditionalItems) return tableData;\n\n const newTableData: InventoryTableData[] = [];\n\n tableData.forEach((tableEntry) => {\n const firstItem = tableEntry.items[0];\n\n const existingEntry = newTableData.find(\n (newTableEntry) => newTableEntry.items[0] === firstItem,\n );\n\n if (existingEntry) {\n existingEntry.count += tableEntry.count;\n existingEntry.occurrences = existingEntry.occurrences.concat(tableEntry.occurrences);\n } else {\n newTableData.push({\n items: [firstItem],\n count: tableEntry.count,\n occurrences: tableEntry.occurrences,\n status: tableEntry.status,\n });\n }\n });\n\n return newTableData;\n }, [showAdditionalItems, tableData]);\n\n const filteredTableData: InventoryTableData[] = useMemo(() => {\n return filterItemData(reducedTableData, statusFilter, textFilter);\n }, [reducedTableData, statusFilter, textFilter]);\n\n const allColumns: ColumnDef[] = useMemo(() => {\n if (!showAdditionalItems) return columns;\n\n const numberOfAdditionalItems = additionalItemsLabels?.tableHeaders?.length;\n if (!numberOfAdditionalItems) return columns;\n\n const additionalColumns: ColumnDef[] = [];\n\n for (let index = 0; index < numberOfAdditionalItems; index++) {\n additionalColumns.push(\n inventoryAdditionalItemColumn(\n additionalItemsLabels?.tableHeaders?.[index] || 'Additional Item',\n index + 1,\n ),\n );\n }\n\n return [...additionalColumns, ...columns];\n }, [additionalItemsLabels?.tableHeaders, columns, showAdditionalItems]);\n\n useEffect(() => {\n setSelectedItem([]);\n }, [filteredTableData]);\n\n const rowClickHandler = (\n row: RowContents,\n table: TableContents,\n ) => {\n table.setRowSelection(() => {\n const newSelection: RowSelectionState = {};\n newSelection[row.index] = true;\n return newSelection;\n });\n\n setSelectedItem(row.original.items);\n };\n\n const handleScopeChange = (value: string) => {\n if (value === 'book' || value === 'chapter' || value === 'verse') {\n onScopeChange(value);\n } else {\n throw new Error(`Invalid scope value: ${value}`);\n }\n };\n\n const handleStatusFilterChange = (value: string) => {\n if (value === 'all' || value === 'approved' || value === 'unapproved' || value === 'unknown') {\n setStatusFilter(value);\n } else {\n throw new Error(`Invalid status filter value: ${value}`);\n }\n };\n\n const occurrenceData: InventoryItemOccurrence[] = useMemo(() => {\n if (reducedTableData.length === 0 || selectedItem.length === 0) return [];\n const occurrence = reducedTableData.filter((tableEntry: InventoryTableData) => {\n return deepEqual(\n showAdditionalItems ? tableEntry.items : [tableEntry.items[0]],\n selectedItem,\n );\n });\n if (occurrence.length > 1) throw new Error('Selected item is not unique');\n return occurrence[0].occurrences;\n }, [selectedItem, showAdditionalItems, reducedTableData]);\n\n return (\n
    \n
    \n handleStatusFilterChange(value)}\n defaultValue={statusFilter}\n >\n \n \n \n \n {allItemsText}\n {approvedItemsText}\n {unapprovedItemsText}\n {unknownItemsText}\n \n \n \n {\n setTextFilter(event.target.value);\n }}\n />\n {additionalItemsLabels && (\n
    \n {\n setSelectedItem([]);\n setShowAdditionalItems(checked);\n }}\n />\n \n
    \n )}\n
    \n
    \n \n
    \n {occurrenceData.length > 0 && (\n
    \n \n
    \n )}\n
    \n );\n}\n","import { Input } from '@/components/shadcn-ui/input';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { useState } from 'react';\n\n/** Props for the SearchBar component. */\nexport type SearchBarProps = {\n /** Additional css classes to help with unique styling of the search bar */\n className?: string;\n /**\n * Callback fired to handle the search query when button pressed\n *\n * @param searchQuery\n */\n onSearch: (searchQuery: string) => void;\n\n /** Optional string that appears in the search bar without a search string */\n placeholder?: string;\n\n /** Optional boolean to set the input base to full width */\n isFullWidth?: boolean;\n};\n\nexport default function SearchBar({\n className,\n onSearch,\n placeholder,\n isFullWidth,\n}: SearchBarProps) {\n const [searchQuery, setSearchQuery] = useState('');\n\n const handleInputChange = (searchString: string) => {\n setSearchQuery(searchString);\n onSearch(searchString);\n };\n\n return (\n handleInputChange(e.target.value)}\n />\n );\n}\n","// adapted from: https://github.com/shadcn-ui/ui/discussions/752\n\n'use client';\n\nimport { TabsContentProps, TabsListProps, TabsTriggerProps } from '@/components/shadcn-ui/tabs';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport * as TabsPrimitive from '@radix-ui/react-tabs';\nimport React from 'react';\n\nexport type VerticalTabsProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport type LeftTabsTriggerProps = TabsTriggerProps & {\n value: string;\n ref?: React.Ref;\n};\n\nexport const VerticalTabs = React.forwardRef<\n React.ElementRef,\n VerticalTabsProps\n>(({ className, ...props }, ref) => (\n \n));\n\nVerticalTabs.displayName = TabsPrimitive.List.displayName;\n\nexport const VerticalTabsList = React.forwardRef<\n React.ElementRef,\n TabsListProps\n>(({ className, ...props }, ref) => (\n \n));\nVerticalTabsList.displayName = TabsPrimitive.List.displayName;\n\nexport const VerticalTabsTrigger = React.forwardRef<\n React.ElementRef,\n LeftTabsTriggerProps\n>(({ className, ...props }, ref) => (\n \n));\n\nexport const VerticalTabsContent = React.forwardRef<\n React.ElementRef,\n TabsContentProps\n>(({ className, ...props }, ref) => (\n \n));\nVerticalTabsContent.displayName = TabsPrimitive.Content.displayName;\n","import SearchBar from '@/components/basics/search-bar.component';\nimport {\n VerticalTabs,\n VerticalTabsContent,\n VerticalTabsList,\n VerticalTabsTrigger,\n} from '@/components/basics/tabs-vertical';\nimport { ReactNode } from 'react';\n\nexport type TabKeyValueContent = {\n key: string;\n value: string;\n content: ReactNode;\n};\n\nexport type TabNavigationContentSearchProps = {\n /** List of values and keys for each tab this component should provide */\n tabList: TabKeyValueContent[];\n\n /** Handler to run when the value of the search bar changes */\n onSearch: (searchQuery: string) => void;\n\n /** Optional placeholder for the search bar */\n searchPlaceholder?: string;\n\n /** Optional title to include in the header */\n headerTitle?: string;\n\n /** Optional flag to make the search bar appear full width */\n isSearchBarFullWidth?: boolean;\n\n /** Text direction ltr or rtl */\n direction?: 'ltr' | 'rtl';\n};\n\nexport default function TabNavigationContentSearch({\n tabList,\n onSearch,\n searchPlaceholder,\n headerTitle,\n isSearchBarFullWidth = false,\n direction = 'ltr',\n}: TabNavigationContentSearchProps) {\n return (\n
    \n
    \n {headerTitle ?

    {headerTitle}

    : ''}\n \n
    \n \n \n {tabList.map((tab) => (\n \n {tab.value}\n \n ))}\n \n {tabList.map((tab) => (\n \n {tab.content}\n \n ))}\n \n
    \n );\n}\n","import React from 'react';\nimport * as SeparatorPrimitive from '@radix-ui/react-separator';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Separator = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, orientation = 'horizontal', decorative = true, ...props }, ref) => (\n \n));\nSeparator.displayName = SeparatorPrimitive.Root.displayName;\n\nexport { Separator };\n","import React from 'react';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nfunction Skeleton({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\n\nexport { Skeleton };\n","import React from 'react';\nimport * as TooltipPrimitive from '@radix-ui/react-tooltip';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst TooltipProvider = TooltipPrimitive.Provider;\n\nconst Tooltip = TooltipPrimitive.Root;\n\nconst TooltipTrigger = TooltipPrimitive.Trigger;\n\nconst TooltipContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, sideOffset = 4, ...props }, ref) => (\n \n));\nTooltipContent.displayName = TooltipPrimitive.Content.displayName;\n\nexport { Tooltip, TooltipTrigger, TooltipContent, TooltipProvider };\n","import React from 'react';\nimport { Slot } from '@radix-ui/react-slot';\nimport { VariantProps, cva } from 'class-variance-authority';\nimport { PanelLeft } from 'lucide-react';\n\nimport { Button } from '@/components/shadcn-ui/button';\nimport { Input } from '@/components/shadcn-ui/input';\nimport { Separator } from '@/components/shadcn-ui/separator';\nimport { Skeleton } from '@/components/shadcn-ui/skeleton';\nimport {\n Tooltip,\n TooltipContent,\n TooltipProvider,\n TooltipTrigger,\n} from '@/components/shadcn-ui/tooltip';\nimport { cn } from '@/utils/shadcn-ui.util';\n\n/**\n * Changes from the original code from Shadcn- Removed uses of useIsMobile, Sheet, and SheetContent.\n * Also removed the parts setting COOKIES.\n */\n\nconst SIDEBAR_WIDTH = '16rem';\nconst SIDEBAR_WIDTH_ICON = '3rem';\n// Commented this out pending a discussion with UX about keyboard shortcuts\n// const SIDEBAR_KEYBOARD_SHORTCUT = 'b';\n\ntype SidebarContextProps = {\n state: 'expanded' | 'collapsed';\n open: boolean;\n setOpen: (open: boolean) => void;\n toggleSidebar: () => void;\n};\n\nconst SidebarContext = React.createContext(undefined);\n\nfunction useSidebar() {\n const context = React.useContext(SidebarContext);\n if (!context) {\n throw new Error('useSidebar must be used within a SidebarProvider.');\n }\n\n return context;\n}\n\nconst SidebarProvider = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & {\n defaultOpen?: boolean;\n open?: boolean;\n onOpenChange?: (open: boolean) => void;\n }\n>(\n (\n {\n defaultOpen = true,\n open: openProp,\n onOpenChange: setOpenProp,\n className,\n style,\n children,\n ...props\n },\n ref,\n ) => {\n // This is the internal state of the sidebar.\n // We use openProp and setOpenProp for control from outside the component.\n const [_open, _setOpen] = React.useState(defaultOpen);\n const isOpen = openProp ?? _open;\n const setOpen = React.useCallback(\n (value: boolean | ((value: boolean) => boolean)) => {\n const openState = typeof value === 'function' ? value(isOpen) : value;\n if (setOpenProp) {\n setOpenProp(openState);\n } else {\n _setOpen(openState);\n }\n },\n [setOpenProp, isOpen],\n );\n\n // Helper to toggle the sidebar.\n const toggleSidebar = React.useCallback(() => {\n return setOpen((open) => !open);\n }, [setOpen]);\n\n // Commented this out pending a discussion with UX about keyboard shortcuts\n // Adds a keyboard shortcut to toggle the sidebar.\n // React.useEffect(() => {\n // const handleKeyDown = (event: KeyboardEvent) => {\n // if (event.key === SIDEBAR_KEYBOARD_SHORTCUT && (event.metaKey || event.ctrlKey)) {\n // event.preventDefault();\n // toggleSidebar();\n // }\n // };\n\n // window.addEventListener('keydown', handleKeyDown);\n // return () => window.removeEventListener('keydown', handleKeyDown);\n // }, [toggleSidebar]);\n\n // We add a state so that we can do data-state=\"expanded\" or \"collapsed\".\n // This makes it easier to style the sidebar with Tailwind classes.\n const state = isOpen ? 'expanded' : 'collapsed';\n\n const contextValue = React.useMemo(\n () => ({\n state,\n open: isOpen,\n setOpen,\n toggleSidebar,\n }),\n [state, isOpen, setOpen, toggleSidebar],\n );\n\n return (\n \n \n \n {children}\n
    \n \n \n );\n },\n);\nSidebarProvider.displayName = 'SidebarProvider';\n\nconst Sidebar = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & {\n side?: 'left' | 'right';\n variant?: 'sidebar' | 'floating' | 'inset';\n collapsible?: 'offcanvas' | 'icon' | 'none';\n }\n>(\n (\n {\n side = 'left',\n variant = 'sidebar',\n collapsible = 'offcanvas',\n className,\n children,\n ...props\n },\n ref,\n ) => {\n const { state } = useSidebar();\n\n if (collapsible === 'none') {\n return (\n \n {children}\n
    \n );\n }\n\n return (\n \n {/* This is what handles the sidebar gap on desktop */}\n \n \n \n {children}\n
    \n
    \n
    \n );\n },\n);\nSidebar.displayName = 'Sidebar';\n\nconst SidebarTrigger = React.forwardRef<\n React.ElementRef,\n React.ComponentProps\n>(({ className, onClick, ...props }, ref) => {\n const { toggleSidebar } = useSidebar();\n\n return (\n {\n onClick?.(event);\n toggleSidebar();\n }}\n {...props}\n >\n \n Toggle Sidebar\n \n );\n});\nSidebarTrigger.displayName = 'SidebarTrigger';\n\nconst SidebarRail = React.forwardRef>(\n ({ className, ...props }, ref) => {\n const { toggleSidebar } = useSidebar();\n\n return (\n \n );\n },\n);\nSidebarRail.displayName = 'SidebarRail';\n\nconst SidebarInset = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarInset.displayName = 'SidebarInset';\n\nconst SidebarInput = React.forwardRef<\n React.ElementRef,\n React.ComponentProps\n>(({ className, ...props }, ref) => {\n return (\n \n );\n});\nSidebarInput.displayName = 'SidebarInput';\n\nconst SidebarHeader = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarHeader.displayName = 'SidebarHeader';\n\nconst SidebarFooter = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarFooter.displayName = 'SidebarFooter';\n\nconst SidebarSeparator = React.forwardRef<\n React.ElementRef,\n React.ComponentProps\n>(({ className, ...props }, ref) => {\n return (\n \n );\n});\nSidebarSeparator.displayName = 'SidebarSeparator';\n\nconst SidebarContent = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarContent.displayName = 'SidebarContent';\n\nconst SidebarGroup = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarGroup.displayName = 'SidebarGroup';\n\nconst SidebarGroupLabel = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & { asChild?: boolean }\n>(({ className, asChild = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'div';\n\n return (\n svg]:tw-size-4 [&>svg]:tw-shrink-0',\n 'group-data-[collapsible=icon]:tw--mt-8 group-data-[collapsible=icon]:tw-opacity-0',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarGroupLabel.displayName = 'SidebarGroupLabel';\n\nconst SidebarGroupAction = React.forwardRef<\n HTMLButtonElement,\n React.ComponentProps<'button'> & { asChild?: boolean }\n>(({ className, asChild = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'button';\n\n return (\n svg]:tw-size-4 [&>svg]:tw-shrink-0',\n // Increases the hit area of the button on mobile.\n 'after:tw-absolute after:tw--inset-2 after:md:tw-hidden',\n 'group-data-[collapsible=icon]:tw-hidden',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarGroupAction.displayName = 'SidebarGroupAction';\n\nconst SidebarGroupContent = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarGroupContent.displayName = 'SidebarGroupContent';\n\nconst SidebarMenu = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenu.displayName = 'SidebarMenu';\n\nconst SidebarMenuItem = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenuItem.displayName = 'SidebarMenuItem';\n\nconst sidebarMenuButtonVariants = cva(\n // Removed data-[active=true]:tw-bg-sidebar-accent\n 'tw-peer/menu-button tw-flex tw-w-full tw-items-center tw-gap-2 tw-overflow-hidden tw-rounded-md tw-p-2 tw-text-left tw-text-sm tw-outline-none tw-ring-sidebar-ring tw-transition-[width,height,padding] hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground focus-visible:tw-ring-2 active:tw-bg-sidebar-accent active:tw-text-sidebar-accent-foreground disabled:tw-pointer-events-none disabled:tw-opacity-50 tw-group-has-[[data-sidebar=menu-action]]/menu-item:pr-8 aria-disabled:tw-pointer-events-none aria-disabled:tw-opacity-50 data-[active=true]:tw-font-medium data-[active=true]:tw-text-sidebar-accent-foreground data-[state=open]:hover:tw-bg-sidebar-accent data-[state=open]:hover:tw-text-sidebar-accent-foreground group-data-[collapsible=icon]:tw-!size-8 group-data-[collapsible=icon]:tw-!p-2 [&>span:last-child]:tw-truncate [&>svg]:tw-size-4 [&>svg]:tw-shrink-0',\n {\n variants: {\n variant: {\n default: 'hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground',\n outline:\n 'tw-bg-background tw-shadow-[0_0_0_1px_hsl(var(--sidebar-border))] hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground hover:tw-shadow-[0_0_0_1px_hsl(var(--sidebar-accent))]',\n },\n size: {\n default: 'tw-h-8 tw-text-sm',\n sm: 'tw-h-7 tw-text-xs',\n lg: 'tw-h-12 tw-text-sm group-data-[collapsible=icon]:tw-!p-0',\n },\n },\n defaultVariants: {\n variant: 'default',\n size: 'default',\n },\n },\n);\n\nconst SidebarMenuButton = React.forwardRef<\n HTMLButtonElement,\n React.ComponentProps<'button'> & {\n asChild?: boolean;\n isActive?: boolean;\n tooltip?: string | React.ComponentProps;\n } & VariantProps\n>(\n (\n {\n asChild = false,\n isActive = false,\n variant = 'default',\n size = 'default',\n tooltip,\n className,\n ...props\n },\n ref,\n ) => {\n const Comp = asChild ? Slot : 'button';\n const { state } = useSidebar();\n\n const button = (\n \n );\n\n if (!tooltip) {\n return button;\n }\n\n if (typeof tooltip === 'string') {\n // eslint-disable-next-line no-param-reassign\n tooltip = {\n children: tooltip,\n };\n }\n\n return (\n \n {button}\n \n );\n },\n);\nSidebarMenuButton.displayName = 'SidebarMenuButton';\n\nconst SidebarMenuAction = React.forwardRef<\n HTMLButtonElement,\n React.ComponentProps<'button'> & {\n asChild?: boolean;\n showOnHover?: boolean;\n }\n>(({ className, asChild = false, showOnHover = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'button';\n\n return (\n svg]:tw-size-4 [&>svg]:tw-shrink-0',\n // Increases the hit area of the button on mobile.\n 'after:tw-absolute after:tw--inset-2 after:md:tw-hidden',\n 'tw-peer-data-[size=sm]/menu-button:top-1',\n 'tw-peer-data-[size=default]/menu-button:top-1.5',\n 'tw-peer-data-[size=lg]/menu-button:top-2.5',\n 'group-data-[collapsible=icon]:tw-hidden',\n showOnHover &&\n 'tw-group-focus-within/menu-item:opacity-100 tw-group-hover/menu-item:opacity-100 tw-peer-data-[active=true]/menu-button:text-sidebar-accent-foreground data-[state=open]:tw-opacity-100 md:tw-opacity-0',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarMenuAction.displayName = 'SidebarMenuAction';\n\nconst SidebarMenuBadge = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenuBadge.displayName = 'SidebarMenuBadge';\n\nconst SidebarMenuSkeleton = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & {\n showIcon?: boolean;\n }\n>(({ className, showIcon = false, ...props }, ref) => {\n // Random width between 50 to 90%.\n const width = React.useMemo(() => {\n return `${Math.floor(Math.random() * 40) + 50}%`;\n }, []);\n\n return (\n \n {showIcon && (\n \n )}\n \n
    \n );\n});\nSidebarMenuSkeleton.displayName = 'SidebarMenuSkeleton';\n\nconst SidebarMenuSub = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenuSub.displayName = 'SidebarMenuSub';\n\nconst SidebarMenuSubItem = React.forwardRef>(\n ({ ...props }, ref) =>
  • ,\n);\nSidebarMenuSubItem.displayName = 'SidebarMenuSubItem';\n\nconst SidebarMenuSubButton = React.forwardRef<\n HTMLAnchorElement,\n React.ComponentProps<'a'> & {\n asChild?: boolean;\n size?: 'sm' | 'md';\n isActive?: boolean;\n }\n>(({ asChild = false, size = 'md', isActive, className, ...props }, ref) => {\n const Comp = asChild ? Slot : 'a';\n\n return (\n svg]:tw-text-sidebar-accent-foreground tw-flex tw-h-7 tw-min-w-0 tw--translate-x-px tw-items-center tw-gap-2 tw-overflow-hidden tw-rounded-md tw-px-2 tw-outline-none focus-visible:tw-ring-2 disabled:tw-pointer-events-none disabled:tw-opacity-50 aria-disabled:tw-pointer-events-none aria-disabled:tw-opacity-50 [&>span:last-child]:tw-truncate [&>svg]:tw-size-4 [&>svg]:tw-shrink-0',\n 'data-[active=true]:tw-bg-sidebar-accent data-[active=true]:tw-text-sidebar-accent-foreground',\n size === 'sm' && 'tw-text-xs',\n size === 'md' && 'tw-text-sm',\n 'group-data-[collapsible=icon]:tw-hidden',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarMenuSubButton.displayName = 'SidebarMenuSubButton';\n\nexport {\n Sidebar,\n SidebarContent,\n SidebarFooter,\n SidebarGroup,\n SidebarGroupAction,\n SidebarGroupContent,\n SidebarGroupLabel,\n SidebarHeader,\n SidebarInput,\n SidebarInset,\n SidebarMenu,\n SidebarMenuAction,\n SidebarMenuBadge,\n SidebarMenuButton,\n SidebarMenuItem,\n SidebarMenuSkeleton,\n SidebarMenuSub,\n SidebarMenuSubButton,\n SidebarMenuSubItem,\n SidebarProvider,\n SidebarRail,\n SidebarSeparator,\n SidebarTrigger,\n useSidebar,\n};\n","import ComboBox, { ComboBoxOption } from '@/components/basics/combo-box.component';\nimport {\n Sidebar,\n SidebarContent,\n SidebarGroup,\n SidebarGroupLabel,\n SidebarGroupContent,\n SidebarMenu,\n SidebarMenuItem,\n SidebarMenuButton,\n} from '@/components/shadcn-ui/sidebar';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { useCallback } from 'react';\n\nexport type SelectedSettingsSidebarItem = {\n label: string;\n projectId?: string;\n};\n\nexport type ProjectInfo = { projectId: string; projectName: string };\n\nexport type SettingsSidebarProps = {\n /** Optional id for testing */\n id?: string;\n\n /** Extension labels from contribution */\n extensionLabels: string[];\n\n /** Project names and ids */\n projectInfo: ProjectInfo[];\n\n /** Handler for selecting a sidebar item */\n handleSelectSidebarItem: (key: string, projectId?: string) => void;\n\n /** The current selected value in the sidebar */\n selectedSidebarItem: SelectedSettingsSidebarItem;\n\n /** Label for the group of extensions setting groups */\n extensionsSidebarGroupLabel: string;\n\n /** Label for the group of projects settings */\n projectsSidebarGroupLabel: string;\n\n /** Placeholder text for the button */\n buttonPlaceholderText: string;\n};\n\nexport default function SettingsSidebar({\n id,\n extensionLabels,\n projectInfo,\n handleSelectSidebarItem,\n selectedSidebarItem,\n extensionsSidebarGroupLabel,\n projectsSidebarGroupLabel,\n buttonPlaceholderText,\n}: SettingsSidebarProps) {\n const handleSelectItem = useCallback(\n (item: string, projectId?: string) => {\n handleSelectSidebarItem(item, projectId);\n },\n [handleSelectSidebarItem],\n );\n\n const getProjectNameFromProjectId = useCallback(\n (projectId: string) => {\n const project = projectInfo.find((info) => info.projectId === projectId);\n return project ? project.projectName : projectId;\n },\n [projectInfo],\n );\n\n const getIsActive: (label: string) => boolean = useCallback(\n (label: string) => !selectedSidebarItem.projectId && label === selectedSidebarItem.label,\n [selectedSidebarItem],\n );\n\n return (\n \n \n \n \n {extensionsSidebarGroupLabel}\n \n \n \n {extensionLabels.map((label) => (\n \n handleSelectItem(label)}\n isActive={getIsActive(label)}\n >\n {label}\n \n \n ))}\n \n \n \n \n \n {projectsSidebarGroupLabel}\n \n \n info.projectId)}\n getOptionLabel={(projectId: ComboBoxOption) => {\n // This function expects a ComboBoxOption, but we know it is a string\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n return getProjectNameFromProjectId(projectId as string);\n }}\n buttonPlaceholder={buttonPlaceholderText}\n onChange={(projectId: string) => {\n const selectedProjectName = getProjectNameFromProjectId(projectId);\n handleSelectItem(selectedProjectName, projectId);\n }}\n value={selectedSidebarItem?.projectId ?? undefined}\n />\n \n \n \n \n );\n}\n","import { SidebarInset, SidebarProvider } from '@/components/shadcn-ui/sidebar';\nimport { PropsWithChildren } from 'react';\nimport SearchBar from '@/components/basics/search-bar.component';\nimport SettingsSidebar, { SettingsSidebarProps } from './settings-sidebar.component';\n\nexport type SettingsSidebarContentSearchProps = SettingsSidebarProps &\n PropsWithChildren & {\n /** Optional id for testing */\n id?: string;\n\n /** Handler to run when the value of the search bar changes */\n onSearch: (searchQuery: string) => void;\n };\n\nexport default function SettingsSidebarContentSearch({\n id,\n extensionLabels,\n projectInfo,\n children,\n handleSelectSidebarItem,\n selectedSidebarItem,\n onSearch,\n extensionsSidebarGroupLabel,\n projectsSidebarGroupLabel,\n buttonPlaceholderText,\n}: SettingsSidebarContentSearchProps) {\n return (\n
    \n
    \n \n
    \n \n \n {children}\n \n
    \n );\n}\n","import { Button } from '@/components/shadcn-ui/button';\nimport {\n Select,\n SelectContent,\n SelectGroup,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\nimport {\n Table,\n TableBody,\n TableCell,\n TableHead,\n TableHeader,\n TableRow,\n} from '@/components/shadcn-ui/table';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Canon } from '@sillsdev/scripture';\nimport {\n Cell,\n ColumnDef,\n flexRender,\n getCoreRowModel,\n getExpandedRowModel,\n getGroupedRowModel,\n getSortedRowModel,\n GroupingState,\n Row,\n RowSelectionState,\n SortingState,\n useReactTable,\n} from '@tanstack/react-table';\nimport '@/components/advanced/scripture-results-viewer/scripture-results-viewer.component.css';\nimport {\n compareScrRefs,\n formatScrRef,\n ScriptureSelection,\n scrRefToBBBCCCVVV,\n} from 'platform-bible-utils';\nimport { MouseEvent, useEffect, useMemo, useState } from 'react';\nimport { ChevronDown, ChevronLeft, ChevronRight } from 'lucide-react';\n\n/**\n * Information (e.g., a checking error or some other type of \"transient\" annotation) about something\n * noteworthy at a specific place in an instance of the Scriptures.\n */\nexport type ScriptureItemDetail = ScriptureSelection & {\n /**\n * Text of the error, note, etc. In the future, we might want to support something more than just\n * text so that a JSX element could be provided with a link or some other controls related to the\n * issue being reported.\n */\n detail: string;\n};\n\n/**\n * A uniquely identifiable source of results that can be displayed in the ScriptureResultsViewer.\n * Generally, the source will be a particular Scripture check, but there may be other types of\n * sources.\n */\nexport type ResultsSource = {\n /**\n * Uniquely identifies the source.\n *\n * @type {string}\n */\n id: string;\n\n /**\n * Name (potentially localized) of the source, suitable for display in the UI.\n *\n * @type {string}\n */\n displayName: string;\n};\n\nexport type ScriptureSrcItemDetail = ScriptureItemDetail & {\n /** Source/type of detail. Can be used for grouping. */\n source: ResultsSource;\n};\n\n/**\n * Represents a set of results keyed by Scripture reference. Generally, the source will be a\n * particular Scripture check, but this type also allows for other types of uniquely identifiable\n * sources.\n */\nexport type ResultsSet = {\n /**\n * The backing source associated with this set of results.\n *\n * @type {ResultsSource}\n */\n source: ResultsSource;\n\n /**\n * Array of Scripture item details (messages keyed by Scripture reference).\n *\n * @type {ScriptureItemDetail[]}\n */\n data: ScriptureItemDetail[];\n};\n\nconst scrBookColId = 'scrBook';\nconst scrRefColId = 'scrRef';\nconst typeColId = 'source';\nconst detailsColId = 'details';\n\nconst defaultScrRefColumnName = 'Scripture Reference';\nconst defaultScrBookGroupName = 'Scripture Book';\nconst defaultTypeColumnName = 'Type';\nconst defaultDetailsColumnName = 'Details';\n\nexport type ScriptureResultsViewerColumnInfo = {\n /** Optional header to display for the Reference column. Default value: 'Scripture Reference'. */\n scriptureReferenceColumnName?: string;\n\n /** Optional text to display to refer to the Scripture book group. Default value: 'Scripture Book'. */\n scriptureBookGroupName?: string;\n\n /** Optional header to display for the Type column. Default value: 'Type'. */\n typeColumnName?: string;\n\n /** Optional header to display for the Details column. Default value: 'Details' */\n detailsColumnName?: string;\n};\n\nexport type ScriptureResultsViewerProps = ScriptureResultsViewerColumnInfo & {\n /** Groups of ScriptureItemDetail objects from particular sources (e.g., Scripture checks) */\n sources: ResultsSet[];\n\n /** Flag indicating whether to display column headers. Default is false. */\n showColumnHeaders?: boolean;\n\n /** Flag indicating whether to display source column. Default is false. */\n showSourceColumn?: boolean;\n\n /** Callback function to notify when a row is selected */\n onRowSelected?: (selectedRow: ScriptureSrcItemDetail | undefined) => void;\n\n /** Text direction ltr or rtl */\n direction?: 'ltr' | 'rtl';\n};\n\nfunction getColumns(\n colInfo?: ScriptureResultsViewerColumnInfo,\n showSourceColumn?: boolean,\n): ColumnDef[] {\n const showSrcCol = showSourceColumn ?? false;\n return [\n {\n accessorFn: (row) =>\n `${Canon.bookNumberToId(row.start.bookNum)} ${row.start.chapterNum}:${row.start.verseNum}`,\n id: scrBookColId,\n header: colInfo?.scriptureReferenceColumnName ?? defaultScrRefColumnName,\n cell: (info) => {\n const row = info.row.original;\n if (info.row.getIsGrouped()) {\n return Canon.bookNumberToEnglishName(row.start.bookNum);\n }\n return info.row.groupingColumnId === scrBookColId ? formatScrRef(row.start) : undefined;\n },\n getGroupingValue: (row) => row.start.bookNum,\n sortingFn: (a, b) => {\n return compareScrRefs(a.original.start, b.original.start);\n },\n enableGrouping: true,\n },\n {\n accessorFn: (row) => formatScrRef(row.start),\n id: scrRefColId,\n header: undefined,\n cell: (info) => {\n const row = info.row.original;\n return info.row.getIsGrouped() ? undefined : formatScrRef(row.start);\n },\n sortingFn: (a, b) => {\n return compareScrRefs(a.original.start, b.original.start);\n },\n enableGrouping: false,\n },\n {\n accessorFn: (row) => row.source.displayName,\n id: typeColId,\n header: showSrcCol ? (colInfo?.typeColumnName ?? defaultTypeColumnName) : undefined,\n cell: (info) => (showSrcCol || info.row.getIsGrouped() ? info.getValue() : undefined),\n getGroupingValue: (row) => row.source.id,\n sortingFn: (a, b) =>\n a.original.source.displayName.localeCompare(b.original.source.displayName),\n enableGrouping: true,\n },\n {\n accessorFn: (row) => row.detail,\n id: detailsColId,\n header: colInfo?.detailsColumnName ?? defaultDetailsColumnName,\n cell: (info) => info.getValue(),\n enableGrouping: false,\n },\n ];\n}\n\nconst toRefOrRange = (scriptureSelection: ScriptureSelection) => {\n if (!('offset' in scriptureSelection.start))\n throw new Error('No offset available in range start');\n if (scriptureSelection.end && !('offset' in scriptureSelection.end))\n throw new Error('No offset available in range end');\n const { offset: offsetStart } = scriptureSelection.start;\n let offsetEnd: number = 0;\n if (scriptureSelection.end) ({ offset: offsetEnd } = scriptureSelection.end);\n if (\n !scriptureSelection.end ||\n compareScrRefs(scriptureSelection.start, scriptureSelection.end) === 0\n )\n return `${scrRefToBBBCCCVVV(scriptureSelection.start)}+${offsetStart}`;\n return `${scrRefToBBBCCCVVV(scriptureSelection.start)}+${offsetStart}-${scrRefToBBBCCCVVV(scriptureSelection.end)}+${offsetEnd}`;\n};\n\nconst getRowKey = (row: ScriptureSrcItemDetail) =>\n `${toRefOrRange({ start: row.start, end: row.end })} ${row.source.displayName} ${row.detail}`;\n\n/**\n * Component to display a combined list of detailed items from one or more sources, where the items\n * are keyed primarily by Scripture reference. This is particularly useful for displaying a list of\n * results from Scripture checks, but more generally could be used to display any \"results\" from any\n * source(s). The component allows for grouping by Scripture book, source, or both. By default, it\n * displays somewhat \"tree-like\" which allows it to be more horizontally compact and intuitive. But\n * it also has the option of displaying as a traditional table with column headings (with or without\n * the source column showing).\n */\nexport default function ScriptureResultsViewer({\n sources,\n showColumnHeaders = false,\n showSourceColumn = false,\n scriptureReferenceColumnName,\n scriptureBookGroupName,\n typeColumnName,\n detailsColumnName,\n onRowSelected,\n direction = 'ltr',\n}: ScriptureResultsViewerProps) {\n const [grouping, setGrouping] = useState([]);\n const [sorting, setSorting] = useState([{ id: scrBookColId, desc: false }]);\n const [rowSelection, setRowSelection] = useState({});\n\n const scriptureResults = useMemo(\n () =>\n sources.flatMap((source) => {\n return source.data.map((item) => ({\n ...item,\n source: source.source,\n }));\n }),\n [sources],\n );\n\n const columns = useMemo(\n () =>\n getColumns(\n {\n scriptureReferenceColumnName,\n typeColumnName,\n detailsColumnName,\n },\n showSourceColumn,\n ),\n [scriptureReferenceColumnName, typeColumnName, detailsColumnName, showSourceColumn],\n );\n\n useEffect(() => {\n // Ensure sorting is applied correctly when grouped by type\n if (grouping.includes(typeColId)) {\n setSorting([\n { id: typeColId, desc: false },\n { id: scrBookColId, desc: false },\n ]);\n } else {\n setSorting([{ id: scrBookColId, desc: false }]);\n }\n }, [grouping]);\n\n const table = useReactTable({\n data: scriptureResults,\n columns,\n state: {\n grouping,\n sorting,\n rowSelection,\n },\n onGroupingChange: setGrouping,\n onSortingChange: setSorting,\n onRowSelectionChange: setRowSelection,\n getExpandedRowModel: getExpandedRowModel(),\n getGroupedRowModel: getGroupedRowModel(),\n getCoreRowModel: getCoreRowModel(),\n getSortedRowModel: getSortedRowModel(),\n getRowId: getRowKey,\n autoResetExpanded: false,\n enableMultiRowSelection: false,\n enableSubRowSelection: false,\n });\n\n useEffect(() => {\n if (onRowSelected) {\n const selectedRows = table.getSelectedRowModel().rowsById;\n const keys = Object.keys(selectedRows);\n if (keys.length === 1) {\n const selectedRow = scriptureResults.find((row) => getRowKey(row) === keys[0]) || undefined;\n if (selectedRow) onRowSelected(selectedRow);\n }\n }\n }, [rowSelection, scriptureResults, onRowSelected, table]);\n\n // Define possible grouping options\n const scrBookGroupName = scriptureBookGroupName ?? defaultScrBookGroupName;\n const typeGroupName = typeColumnName ?? defaultTypeColumnName;\n\n const groupingOptions = [\n { label: 'No Grouping', value: [] },\n { label: `Group by ${scrBookGroupName}`, value: [scrBookColId] },\n { label: `Group by ${typeGroupName}`, value: [typeColId] },\n {\n label: `Group by ${scrBookGroupName} and ${typeGroupName}`,\n value: [scrBookColId, typeColId],\n },\n {\n label: `Group by ${typeGroupName} and ${scrBookGroupName}`,\n value: [typeColId, scrBookColId],\n },\n ];\n\n const handleSelectChange = (selectedGrouping: string) => {\n setGrouping(JSON.parse(selectedGrouping));\n };\n\n const handleRowClick = (row: Row, event: MouseEvent) => {\n if (!row.getIsGrouped() && !row.getIsSelected()) {\n row.getToggleSelectedHandler()(event);\n }\n };\n\n const getEvenOrOddBandingStyle = (row: Row, index: number) => {\n if (row.getIsGrouped()) return '';\n // UX has now said they don't think they want banding. I'm leaving in the code to\n // set even and odd styles, but there's nothing in the CSS to style them differently.\n // The \"even\" style used to also have tw-bg-neutral-300 (along with even) to create\n // a visual banding effect. That could be added back in if UX changes the decision.\n return cn('banded-row', index % 2 === 0 ? 'even' : 'odd');\n };\n\n const getIndent = (\n groupingState: GroupingState,\n row: Row,\n cell: Cell,\n ) => {\n if (groupingState?.length === 0 || row.depth < cell.column.getGroupedIndex()) return undefined;\n if (row.getIsGrouped()) {\n switch (row.depth) {\n case 1:\n return 'tw-ps-4';\n default:\n return undefined;\n }\n }\n switch (row.depth) {\n case 1:\n return 'tw-ps-8';\n case 2:\n return 'tw-ps-12';\n default:\n return undefined;\n }\n };\n\n return (\n
    \n {!showColumnHeaders && (\n {\n handleSelectChange(value);\n }}\n >\n \n \n \n \n \n {groupingOptions.map((option) => (\n \n {option.label}\n \n ))}\n \n \n \n )}\n \n {showColumnHeaders && (\n \n {table.getHeaderGroups().map((headerGroup) => (\n \n {headerGroup.headers\n .filter((h) => h.column.columnDef.header)\n .map((header) => (\n /* For sticky column headers to work, we probably need to change the default definition of the shadcn Table component. See https://github.com/shadcn-ui/ui/issues/1151 */\n \n {header.isPlaceholder ? undefined : (\n
    \n {header.column.getCanGroup() ? (\n \n {header.column.getIsGrouped() ? `🛑` : `👊 `}\n \n ) : undefined}{' '}\n {flexRender(header.column.columnDef.header, header.getContext())}\n
    \n )}\n
    \n ))}\n
    \n ))}\n
    \n )}\n \n {table.getRowModel().rows.map((row, rowIndex) => {\n return (\n handleRowClick(row, event)}\n >\n {row.getVisibleCells().map((cell) => {\n if (\n cell.getIsPlaceholder() ||\n (cell.column.columnDef.enableGrouping &&\n !cell.getIsGrouped() &&\n (cell.column.columnDef.id !== typeColId || !showSourceColumn))\n )\n return undefined;\n return (\n \n {(() => {\n if (cell.getIsGrouped()) {\n return (\n \n {row.getIsExpanded() && }\n {!row.getIsExpanded() &&\n (direction === 'ltr' ? : )}{' '}\n {flexRender(cell.column.columnDef.cell, cell.getContext())} (\n {row.subRows.length})\n \n );\n }\n\n // if (cell.getIsAggregated()) {\n // flexRender(\n // cell.column.columnDef.aggregatedCell ?? cell.column.columnDef.cell,\n // cell.getContext(),\n // );\n // }\n\n return flexRender(cell.column.columnDef.cell, cell.getContext());\n })()}\n \n );\n })}\n \n );\n })}\n \n
    \n
    \n );\n}\n","import {\n getLocalizeKeyForScrollGroupId,\n LanguageStrings,\n ScrollGroupId,\n} from 'platform-bible-utils';\nimport {\n Select,\n SelectContent,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\n\nconst DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS = {\n [getLocalizeKeyForScrollGroupId('undefined')]: 'Ø',\n [getLocalizeKeyForScrollGroupId(0)]: 'A',\n [getLocalizeKeyForScrollGroupId(1)]: 'B',\n [getLocalizeKeyForScrollGroupId(2)]: 'C',\n [getLocalizeKeyForScrollGroupId(3)]: 'D',\n [getLocalizeKeyForScrollGroupId(4)]: 'E',\n [getLocalizeKeyForScrollGroupId(5)]: 'F',\n [getLocalizeKeyForScrollGroupId(6)]: 'G',\n [getLocalizeKeyForScrollGroupId(7)]: 'H',\n [getLocalizeKeyForScrollGroupId(8)]: 'I',\n [getLocalizeKeyForScrollGroupId(9)]: 'J',\n [getLocalizeKeyForScrollGroupId(10)]: 'K',\n [getLocalizeKeyForScrollGroupId(11)]: 'L',\n [getLocalizeKeyForScrollGroupId(12)]: 'M',\n [getLocalizeKeyForScrollGroupId(13)]: 'N',\n [getLocalizeKeyForScrollGroupId(14)]: 'O',\n [getLocalizeKeyForScrollGroupId(15)]: 'P',\n [getLocalizeKeyForScrollGroupId(16)]: 'Q',\n [getLocalizeKeyForScrollGroupId(17)]: 'R',\n [getLocalizeKeyForScrollGroupId(18)]: 'S',\n [getLocalizeKeyForScrollGroupId(19)]: 'T',\n [getLocalizeKeyForScrollGroupId(20)]: 'U',\n [getLocalizeKeyForScrollGroupId(21)]: 'V',\n [getLocalizeKeyForScrollGroupId(22)]: 'W',\n [getLocalizeKeyForScrollGroupId(23)]: 'X',\n [getLocalizeKeyForScrollGroupId(24)]: 'Y',\n [getLocalizeKeyForScrollGroupId(25)]: 'Z',\n};\n\nexport type ScrollGroupSelectorProps = {\n /**\n * List of scroll group ids to show to the user. Either a {@link ScrollGroupId} or `undefined` for\n * no scroll group\n */\n availableScrollGroupIds: (ScrollGroupId | undefined)[];\n /** Currently selected scroll group id. `undefined` for no scroll group */\n scrollGroupId: ScrollGroupId | undefined;\n /** Callback function run when the user tries to change the scroll group id */\n onChangeScrollGroupId: (newScrollGroupId: ScrollGroupId | undefined) => void;\n /**\n * Localized strings to use for displaying scroll group ids. Must be an object whose keys are\n * `getLocalizeKeyForScrollGroupId(scrollGroupId)` for all scroll group ids (and `undefined` if\n * included) in {@link ScrollGroupSelectorProps.availableScrollGroupIds} and whose values are the\n * localized strings to use for those scroll group ids.\n *\n * Defaults to English localizations of English alphabet for scroll groups 0-25 (e.g. 0 is A) and\n * Ø for `undefined`. Will fill in any that are not provided with these English localizations.\n * Also, if any values match the keys, the English localization will be used. This is useful in\n * case you want to pass in a temporary version of the localized strings while your localized\n * strings load.\n *\n * @example\n *\n * ```typescript\n * const myScrollGroupIdLocalizedStrings = {\n * [getLocalizeKeyForScrollGroupId('undefined')]: 'Ø',\n * [getLocalizeKeyForScrollGroupId(0)]: 'A',\n * [getLocalizeKeyForScrollGroupId(1)]: 'B',\n * [getLocalizeKeyForScrollGroupId(2)]: 'C',\n * [getLocalizeKeyForScrollGroupId(3)]: 'D',\n * [getLocalizeKeyForScrollGroupId(4)]: 'E',\n * };\n * ```\n *\n * @example\n *\n * ```tsx\n * const availableScrollGroupIds = [undefined, 0, 1, 2, 3, 4];\n *\n * const localizeKeys = getLocalizeKeysForScrollGroupIds();\n *\n * const [localizedStrings] = useLocalizedStrings(localizeKeys);\n *\n * ...\n *\n * \n * ```\n */\n localizedStrings?: LanguageStrings;\n};\n\n/** Selector component for choosing a scroll group */\nexport default function ScrollGroupSelector({\n availableScrollGroupIds,\n scrollGroupId,\n onChangeScrollGroupId,\n localizedStrings = {},\n}: ScrollGroupSelectorProps) {\n const localizedStringsDefaulted = {\n ...DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS,\n ...Object.fromEntries(\n Object.entries(localizedStrings).map(\n ([localizedStringKey, localizedStringValue]: [string, string]) => [\n localizedStringKey,\n localizedStringKey === localizedStringValue &&\n localizedStringKey in DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS\n ? DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS[localizedStringKey]\n : localizedStringValue,\n ],\n ),\n ),\n };\n return (\n \n onChangeScrollGroupId(\n newScrollGroupString === 'undefined' ? undefined : parseInt(newScrollGroupString, 10),\n )\n }\n >\n \n \n \n \n {availableScrollGroupIds.map((scrollGroupOptionId) => (\n \n {localizedStringsDefaulted[getLocalizeKeyForScrollGroupId(scrollGroupOptionId)]}\n \n ))}\n \n \n );\n}\n","import { PropsWithChildren } from 'react';\nimport { Separator } from '@/components/shadcn-ui/separator';\n\n/** Props for the SettingsList component, currently just children */\ntype SettingsListProps = PropsWithChildren;\n\n/**\n * SettingsList component is a wrapper for list items. Rendered with a formatted div\n *\n * @param children To populate the list with\n * @returns Formatted div encompassing the children\n */\nexport function SettingsList({ children }: SettingsListProps) {\n return
    {children}
    ;\n}\n\n/** Props for SettingsListItem component */\ntype SettingsListItemProps = PropsWithChildren & {\n /** Primary text of the list item */\n primary: string;\n\n /** Optional text of the list item */\n secondary?: string | undefined;\n\n /** Optional boolean to display a message if the children aren't loaded yet. Defaults to false */\n isLoading?: boolean;\n\n /** Optional message to display if isLoading */\n loadingMessage?: string;\n};\n\n/**\n * SettingsListItem component is a common list item. Rendered with a formatted div\n *\n * @param primary Primary text of the list item\n * @param secondary Optional secondary text of the list item\n * @param isLoading Optional, to display a message if the action component isn't generated yet,\n * defaults to false\n * @param children The action component(s) to provide for this item\n * @param loadingMessage Optional, message to display if isLoading\n * @returns Formatted div encompassing the list item content\n */\nexport function SettingsListItem({\n primary,\n secondary,\n children,\n isLoading = false,\n loadingMessage,\n}: SettingsListItemProps) {\n return (\n
    \n
    \n

    {primary}

    \n

    \n {secondary}\n

    \n
    \n\n {isLoading ? (\n

    {loadingMessage}

    \n ) : (\n
    {children}
    \n )}\n
    \n );\n}\n\n/** Props for SettingsListHeader component */\ntype SettingsListHeaderProps = {\n /** The primary text of the list header */\n primary: string;\n\n /** Optional secondary text of the list header */\n secondary?: string | undefined;\n\n /** Optional boolean to include a separator underneath the secondary text. Defaults to false */\n includeSeparator?: boolean;\n};\n\n/**\n * SettingsListHeader component displays text above the list\n *\n * @param primary The primary text of the list header\n * @param secondary Optional secondary text of the list header\n * @param includeSeparator Optional boolean to include a separator underneath the secondary text.\n * Defaults to false\n * @returns Formatted div with list header content\n */\nexport function SettingsListHeader({\n primary,\n secondary,\n includeSeparator = false,\n}: SettingsListHeaderProps) {\n return (\n
    \n
    \n

    {primary}

    \n

    {secondary}

    \n
    \n {includeSeparator ? : ''}\n
    \n );\n}\n","import Checkbox from '@/components/shadcn-ui/checkbox';\nimport { Label } from '@/components/shadcn-ui/label';\n\nexport type ChecklistProps = {\n /** Optional string representing the id attribute of the Checklist */\n id?: string;\n /** Optional string representing CSS class name(s) for styling */\n className?: string;\n /** Array of strings representing the checkable items */\n listItems: string[];\n /** Array of strings representing the checked items */\n selectedListItems: string[];\n /**\n * Function that is called when a checkbox item is selected or deselected\n *\n * @param item The string description for this item\n * @param selected True if selected, false if not selected\n */\n handleSelectListItem: (item: string, selected: boolean) => void;\n\n /**\n * Optional function creates a label for a provided checkable item\n *\n * @param item The item for which a label is to be created\n * @returns A string representing the label text for the checkbox associated with that item\n */\n createLabel?: (item: string) => string;\n};\n\n/** Renders a list of checkboxes. Each checkbox corresponds to an item from the `listItems` array. */\nexport default function Checklist({\n id,\n className,\n listItems,\n selectedListItems,\n handleSelectListItem,\n createLabel,\n}: ChecklistProps) {\n return (\n
    \n {listItems.map((item) => (\n
    \n handleSelectListItem(item, value)}\n />\n \n
    \n ))}\n
    \n );\n}\n","function _interopRequireDefault(obj) {\n return obj && obj.__esModule ? obj : {\n \"default\": obj\n };\n}\nmodule.exports = _interopRequireDefault, module.exports.__esModule = true, module.exports[\"default\"] = module.exports;","export default function chainPropTypes(propType1, propType2) {\n if (process.env.NODE_ENV === 'production') {\n return () => null;\n }\n return function validate(...args) {\n return propType1(...args) || propType2(...args);\n };\n}","export default function _extends() {\n _extends = Object.assign ? Object.assign.bind() : function (target) {\n for (var i = 1; i < arguments.length; i++) {\n var source = arguments[i];\n for (var key in source) {\n if (Object.prototype.hasOwnProperty.call(source, key)) {\n target[key] = source[key];\n }\n }\n }\n return target;\n };\n return _extends.apply(this, arguments);\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\n// https://github.com/sindresorhus/is-plain-obj/blob/main/index.js\nexport function isPlainObject(item) {\n if (typeof item !== 'object' || item === null) {\n return false;\n }\n const prototype = Object.getPrototypeOf(item);\n return (prototype === null || prototype === Object.prototype || Object.getPrototypeOf(prototype) === null) && !(Symbol.toStringTag in item) && !(Symbol.iterator in item);\n}\nfunction deepClone(source) {\n if (!isPlainObject(source)) {\n return source;\n }\n const output = {};\n Object.keys(source).forEach(key => {\n output[key] = deepClone(source[key]);\n });\n return output;\n}\nexport default function deepmerge(target, source, options = {\n clone: true\n}) {\n const output = options.clone ? _extends({}, target) : target;\n if (isPlainObject(target) && isPlainObject(source)) {\n Object.keys(source).forEach(key => {\n // Avoid prototype pollution\n if (key === '__proto__') {\n return;\n }\n if (isPlainObject(source[key]) && key in target && isPlainObject(target[key])) {\n // Since `output` is a clone of `target` and we have narrowed `target` in this block we can cast to the same type.\n output[key] = deepmerge(target[key], source[key], options);\n } else if (options.clone) {\n output[key] = isPlainObject(source[key]) ? deepClone(source[key]) : source[key];\n } else {\n output[key] = source[key];\n }\n });\n }\n return output;\n}","/** @license React v16.13.1\n * react-is.production.min.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';var b=\"function\"===typeof Symbol&&Symbol.for,c=b?Symbol.for(\"react.element\"):60103,d=b?Symbol.for(\"react.portal\"):60106,e=b?Symbol.for(\"react.fragment\"):60107,f=b?Symbol.for(\"react.strict_mode\"):60108,g=b?Symbol.for(\"react.profiler\"):60114,h=b?Symbol.for(\"react.provider\"):60109,k=b?Symbol.for(\"react.context\"):60110,l=b?Symbol.for(\"react.async_mode\"):60111,m=b?Symbol.for(\"react.concurrent_mode\"):60111,n=b?Symbol.for(\"react.forward_ref\"):60112,p=b?Symbol.for(\"react.suspense\"):60113,q=b?\nSymbol.for(\"react.suspense_list\"):60120,r=b?Symbol.for(\"react.memo\"):60115,t=b?Symbol.for(\"react.lazy\"):60116,v=b?Symbol.for(\"react.block\"):60121,w=b?Symbol.for(\"react.fundamental\"):60117,x=b?Symbol.for(\"react.responder\"):60118,y=b?Symbol.for(\"react.scope\"):60119;\nfunction z(a){if(\"object\"===typeof a&&null!==a){var u=a.$$typeof;switch(u){case c:switch(a=a.type,a){case l:case m:case e:case g:case f:case p:return a;default:switch(a=a&&a.$$typeof,a){case k:case n:case t:case r:case h:return a;default:return u}}case d:return u}}}function A(a){return z(a)===m}exports.AsyncMode=l;exports.ConcurrentMode=m;exports.ContextConsumer=k;exports.ContextProvider=h;exports.Element=c;exports.ForwardRef=n;exports.Fragment=e;exports.Lazy=t;exports.Memo=r;exports.Portal=d;\nexports.Profiler=g;exports.StrictMode=f;exports.Suspense=p;exports.isAsyncMode=function(a){return A(a)||z(a)===l};exports.isConcurrentMode=A;exports.isContextConsumer=function(a){return z(a)===k};exports.isContextProvider=function(a){return z(a)===h};exports.isElement=function(a){return\"object\"===typeof a&&null!==a&&a.$$typeof===c};exports.isForwardRef=function(a){return z(a)===n};exports.isFragment=function(a){return z(a)===e};exports.isLazy=function(a){return z(a)===t};\nexports.isMemo=function(a){return z(a)===r};exports.isPortal=function(a){return z(a)===d};exports.isProfiler=function(a){return z(a)===g};exports.isStrictMode=function(a){return z(a)===f};exports.isSuspense=function(a){return z(a)===p};\nexports.isValidElementType=function(a){return\"string\"===typeof a||\"function\"===typeof a||a===e||a===m||a===g||a===f||a===p||a===q||\"object\"===typeof a&&null!==a&&(a.$$typeof===t||a.$$typeof===r||a.$$typeof===h||a.$$typeof===k||a.$$typeof===n||a.$$typeof===w||a.$$typeof===x||a.$$typeof===y||a.$$typeof===v)};exports.typeOf=z;\n","/** @license React v16.13.1\n * react-is.development.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\n\n\nif (process.env.NODE_ENV !== \"production\") {\n (function() {\n'use strict';\n\n// The Symbol used to tag the ReactElement-like types. If there is no native Symbol\n// nor polyfill, then a plain number is used for performance.\nvar hasSymbol = typeof Symbol === 'function' && Symbol.for;\nvar REACT_ELEMENT_TYPE = hasSymbol ? Symbol.for('react.element') : 0xeac7;\nvar REACT_PORTAL_TYPE = hasSymbol ? Symbol.for('react.portal') : 0xeaca;\nvar REACT_FRAGMENT_TYPE = hasSymbol ? Symbol.for('react.fragment') : 0xeacb;\nvar REACT_STRICT_MODE_TYPE = hasSymbol ? Symbol.for('react.strict_mode') : 0xeacc;\nvar REACT_PROFILER_TYPE = hasSymbol ? Symbol.for('react.profiler') : 0xead2;\nvar REACT_PROVIDER_TYPE = hasSymbol ? Symbol.for('react.provider') : 0xeacd;\nvar REACT_CONTEXT_TYPE = hasSymbol ? Symbol.for('react.context') : 0xeace; // TODO: We don't use AsyncMode or ConcurrentMode anymore. They were temporary\n// (unstable) APIs that have been removed. Can we remove the symbols?\n\nvar REACT_ASYNC_MODE_TYPE = hasSymbol ? Symbol.for('react.async_mode') : 0xeacf;\nvar REACT_CONCURRENT_MODE_TYPE = hasSymbol ? Symbol.for('react.concurrent_mode') : 0xeacf;\nvar REACT_FORWARD_REF_TYPE = hasSymbol ? Symbol.for('react.forward_ref') : 0xead0;\nvar REACT_SUSPENSE_TYPE = hasSymbol ? Symbol.for('react.suspense') : 0xead1;\nvar REACT_SUSPENSE_LIST_TYPE = hasSymbol ? Symbol.for('react.suspense_list') : 0xead8;\nvar REACT_MEMO_TYPE = hasSymbol ? Symbol.for('react.memo') : 0xead3;\nvar REACT_LAZY_TYPE = hasSymbol ? Symbol.for('react.lazy') : 0xead4;\nvar REACT_BLOCK_TYPE = hasSymbol ? Symbol.for('react.block') : 0xead9;\nvar REACT_FUNDAMENTAL_TYPE = hasSymbol ? Symbol.for('react.fundamental') : 0xead5;\nvar REACT_RESPONDER_TYPE = hasSymbol ? Symbol.for('react.responder') : 0xead6;\nvar REACT_SCOPE_TYPE = hasSymbol ? Symbol.for('react.scope') : 0xead7;\n\nfunction isValidElementType(type) {\n return typeof type === 'string' || typeof type === 'function' || // Note: its typeof might be other than 'symbol' or 'number' if it's a polyfill.\n type === REACT_FRAGMENT_TYPE || type === REACT_CONCURRENT_MODE_TYPE || type === REACT_PROFILER_TYPE || type === REACT_STRICT_MODE_TYPE || type === REACT_SUSPENSE_TYPE || type === REACT_SUSPENSE_LIST_TYPE || typeof type === 'object' && type !== null && (type.$$typeof === REACT_LAZY_TYPE || type.$$typeof === REACT_MEMO_TYPE || type.$$typeof === REACT_PROVIDER_TYPE || type.$$typeof === REACT_CONTEXT_TYPE || type.$$typeof === REACT_FORWARD_REF_TYPE || type.$$typeof === REACT_FUNDAMENTAL_TYPE || type.$$typeof === REACT_RESPONDER_TYPE || type.$$typeof === REACT_SCOPE_TYPE || type.$$typeof === REACT_BLOCK_TYPE);\n}\n\nfunction typeOf(object) {\n if (typeof object === 'object' && object !== null) {\n var $$typeof = object.$$typeof;\n\n switch ($$typeof) {\n case REACT_ELEMENT_TYPE:\n var type = object.type;\n\n switch (type) {\n case REACT_ASYNC_MODE_TYPE:\n case REACT_CONCURRENT_MODE_TYPE:\n case REACT_FRAGMENT_TYPE:\n case REACT_PROFILER_TYPE:\n case REACT_STRICT_MODE_TYPE:\n case REACT_SUSPENSE_TYPE:\n return type;\n\n default:\n var $$typeofType = type && type.$$typeof;\n\n switch ($$typeofType) {\n case REACT_CONTEXT_TYPE:\n case REACT_FORWARD_REF_TYPE:\n case REACT_LAZY_TYPE:\n case REACT_MEMO_TYPE:\n case REACT_PROVIDER_TYPE:\n return $$typeofType;\n\n default:\n return $$typeof;\n }\n\n }\n\n case REACT_PORTAL_TYPE:\n return $$typeof;\n }\n }\n\n return undefined;\n} // AsyncMode is deprecated along with isAsyncMode\n\nvar AsyncMode = REACT_ASYNC_MODE_TYPE;\nvar ConcurrentMode = REACT_CONCURRENT_MODE_TYPE;\nvar ContextConsumer = REACT_CONTEXT_TYPE;\nvar ContextProvider = REACT_PROVIDER_TYPE;\nvar Element = REACT_ELEMENT_TYPE;\nvar ForwardRef = REACT_FORWARD_REF_TYPE;\nvar Fragment = REACT_FRAGMENT_TYPE;\nvar Lazy = REACT_LAZY_TYPE;\nvar Memo = REACT_MEMO_TYPE;\nvar Portal = REACT_PORTAL_TYPE;\nvar Profiler = REACT_PROFILER_TYPE;\nvar StrictMode = REACT_STRICT_MODE_TYPE;\nvar Suspense = REACT_SUSPENSE_TYPE;\nvar hasWarnedAboutDeprecatedIsAsyncMode = false; // AsyncMode should be deprecated\n\nfunction isAsyncMode(object) {\n {\n if (!hasWarnedAboutDeprecatedIsAsyncMode) {\n hasWarnedAboutDeprecatedIsAsyncMode = true; // Using console['warn'] to evade Babel and ESLint\n\n console['warn']('The ReactIs.isAsyncMode() alias has been deprecated, ' + 'and will be removed in React 17+. Update your code to use ' + 'ReactIs.isConcurrentMode() instead. It has the exact same API.');\n }\n }\n\n return isConcurrentMode(object) || typeOf(object) === REACT_ASYNC_MODE_TYPE;\n}\nfunction isConcurrentMode(object) {\n return typeOf(object) === REACT_CONCURRENT_MODE_TYPE;\n}\nfunction isContextConsumer(object) {\n return typeOf(object) === REACT_CONTEXT_TYPE;\n}\nfunction isContextProvider(object) {\n return typeOf(object) === REACT_PROVIDER_TYPE;\n}\nfunction isElement(object) {\n return typeof object === 'object' && object !== null && object.$$typeof === REACT_ELEMENT_TYPE;\n}\nfunction isForwardRef(object) {\n return typeOf(object) === REACT_FORWARD_REF_TYPE;\n}\nfunction isFragment(object) {\n return typeOf(object) === REACT_FRAGMENT_TYPE;\n}\nfunction isLazy(object) {\n return typeOf(object) === REACT_LAZY_TYPE;\n}\nfunction isMemo(object) {\n return typeOf(object) === REACT_MEMO_TYPE;\n}\nfunction isPortal(object) {\n return typeOf(object) === REACT_PORTAL_TYPE;\n}\nfunction isProfiler(object) {\n return typeOf(object) === REACT_PROFILER_TYPE;\n}\nfunction isStrictMode(object) {\n return typeOf(object) === REACT_STRICT_MODE_TYPE;\n}\nfunction isSuspense(object) {\n return typeOf(object) === REACT_SUSPENSE_TYPE;\n}\n\nexports.AsyncMode = AsyncMode;\nexports.ConcurrentMode = ConcurrentMode;\nexports.ContextConsumer = ContextConsumer;\nexports.ContextProvider = ContextProvider;\nexports.Element = Element;\nexports.ForwardRef = ForwardRef;\nexports.Fragment = Fragment;\nexports.Lazy = Lazy;\nexports.Memo = Memo;\nexports.Portal = Portal;\nexports.Profiler = Profiler;\nexports.StrictMode = StrictMode;\nexports.Suspense = Suspense;\nexports.isAsyncMode = isAsyncMode;\nexports.isConcurrentMode = isConcurrentMode;\nexports.isContextConsumer = isContextConsumer;\nexports.isContextProvider = isContextProvider;\nexports.isElement = isElement;\nexports.isForwardRef = isForwardRef;\nexports.isFragment = isFragment;\nexports.isLazy = isLazy;\nexports.isMemo = isMemo;\nexports.isPortal = isPortal;\nexports.isProfiler = isProfiler;\nexports.isStrictMode = isStrictMode;\nexports.isSuspense = isSuspense;\nexports.isValidElementType = isValidElementType;\nexports.typeOf = typeOf;\n })();\n}\n","'use strict';\n\nif (process.env.NODE_ENV === 'production') {\n module.exports = require('./cjs/react-is.production.min.js');\n} else {\n module.exports = require('./cjs/react-is.development.js');\n}\n","/*\nobject-assign\n(c) Sindre Sorhus\n@license MIT\n*/\n\n'use strict';\n/* eslint-disable no-unused-vars */\nvar getOwnPropertySymbols = Object.getOwnPropertySymbols;\nvar hasOwnProperty = Object.prototype.hasOwnProperty;\nvar propIsEnumerable = Object.prototype.propertyIsEnumerable;\n\nfunction toObject(val) {\n\tif (val === null || val === undefined) {\n\t\tthrow new TypeError('Object.assign cannot be called with null or undefined');\n\t}\n\n\treturn Object(val);\n}\n\nfunction shouldUseNative() {\n\ttry {\n\t\tif (!Object.assign) {\n\t\t\treturn false;\n\t\t}\n\n\t\t// Detect buggy property enumeration order in older V8 versions.\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=4118\n\t\tvar test1 = new String('abc'); // eslint-disable-line no-new-wrappers\n\t\ttest1[5] = 'de';\n\t\tif (Object.getOwnPropertyNames(test1)[0] === '5') {\n\t\t\treturn false;\n\t\t}\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=3056\n\t\tvar test2 = {};\n\t\tfor (var i = 0; i < 10; i++) {\n\t\t\ttest2['_' + String.fromCharCode(i)] = i;\n\t\t}\n\t\tvar order2 = Object.getOwnPropertyNames(test2).map(function (n) {\n\t\t\treturn test2[n];\n\t\t});\n\t\tif (order2.join('') !== '0123456789') {\n\t\t\treturn false;\n\t\t}\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=3056\n\t\tvar test3 = {};\n\t\t'abcdefghijklmnopqrst'.split('').forEach(function (letter) {\n\t\t\ttest3[letter] = letter;\n\t\t});\n\t\tif (Object.keys(Object.assign({}, test3)).join('') !==\n\t\t\t\t'abcdefghijklmnopqrst') {\n\t\t\treturn false;\n\t\t}\n\n\t\treturn true;\n\t} catch (err) {\n\t\t// We don't expect any of the above to throw, but better to be safe.\n\t\treturn false;\n\t}\n}\n\nmodule.exports = shouldUseNative() ? Object.assign : function (target, source) {\n\tvar from;\n\tvar to = toObject(target);\n\tvar symbols;\n\n\tfor (var s = 1; s < arguments.length; s++) {\n\t\tfrom = Object(arguments[s]);\n\n\t\tfor (var key in from) {\n\t\t\tif (hasOwnProperty.call(from, key)) {\n\t\t\t\tto[key] = from[key];\n\t\t\t}\n\t\t}\n\n\t\tif (getOwnPropertySymbols) {\n\t\t\tsymbols = getOwnPropertySymbols(from);\n\t\t\tfor (var i = 0; i < symbols.length; i++) {\n\t\t\t\tif (propIsEnumerable.call(from, symbols[i])) {\n\t\t\t\t\tto[symbols[i]] = from[symbols[i]];\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\n\treturn to;\n};\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar ReactPropTypesSecret = 'SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED';\n\nmodule.exports = ReactPropTypesSecret;\n","module.exports = Function.call.bind(Object.prototype.hasOwnProperty);\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar printWarning = function() {};\n\nif (process.env.NODE_ENV !== 'production') {\n var ReactPropTypesSecret = require('./lib/ReactPropTypesSecret');\n var loggedTypeFailures = {};\n var has = require('./lib/has');\n\n printWarning = function(text) {\n var message = 'Warning: ' + text;\n if (typeof console !== 'undefined') {\n console.error(message);\n }\n try {\n // --- Welcome to debugging React ---\n // This error was thrown as a convenience so that you can use this stack\n // to find the callsite that caused this warning to fire.\n throw new Error(message);\n } catch (x) { /**/ }\n };\n}\n\n/**\n * Assert that the values match with the type specs.\n * Error messages are memorized and will only be shown once.\n *\n * @param {object} typeSpecs Map of name to a ReactPropType\n * @param {object} values Runtime values that need to be type-checked\n * @param {string} location e.g. \"prop\", \"context\", \"child context\"\n * @param {string} componentName Name of the component for error messages.\n * @param {?Function} getStack Returns the component stack.\n * @private\n */\nfunction checkPropTypes(typeSpecs, values, location, componentName, getStack) {\n if (process.env.NODE_ENV !== 'production') {\n for (var typeSpecName in typeSpecs) {\n if (has(typeSpecs, typeSpecName)) {\n var error;\n // Prop type validation may throw. In case they do, we don't want to\n // fail the render phase where it didn't fail before. So we log it.\n // After these have been cleaned up, we'll let them throw.\n try {\n // This is intentionally an invariant that gets caught. It's the same\n // behavior as without this statement except with a better message.\n if (typeof typeSpecs[typeSpecName] !== 'function') {\n var err = Error(\n (componentName || 'React class') + ': ' + location + ' type `' + typeSpecName + '` is invalid; ' +\n 'it must be a function, usually from the `prop-types` package, but received `' + typeof typeSpecs[typeSpecName] + '`.' +\n 'This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.'\n );\n err.name = 'Invariant Violation';\n throw err;\n }\n error = typeSpecs[typeSpecName](values, typeSpecName, componentName, location, null, ReactPropTypesSecret);\n } catch (ex) {\n error = ex;\n }\n if (error && !(error instanceof Error)) {\n printWarning(\n (componentName || 'React class') + ': type specification of ' +\n location + ' `' + typeSpecName + '` is invalid; the type checker ' +\n 'function must return `null` or an `Error` but returned a ' + typeof error + '. ' +\n 'You may have forgotten to pass an argument to the type checker ' +\n 'creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and ' +\n 'shape all require an argument).'\n );\n }\n if (error instanceof Error && !(error.message in loggedTypeFailures)) {\n // Only monitor this failure once because there tends to be a lot of the\n // same error.\n loggedTypeFailures[error.message] = true;\n\n var stack = getStack ? getStack() : '';\n\n printWarning(\n 'Failed ' + location + ' type: ' + error.message + (stack != null ? stack : '')\n );\n }\n }\n }\n }\n}\n\n/**\n * Resets warning cache when testing.\n *\n * @private\n */\ncheckPropTypes.resetWarningCache = function() {\n if (process.env.NODE_ENV !== 'production') {\n loggedTypeFailures = {};\n }\n}\n\nmodule.exports = checkPropTypes;\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar ReactIs = require('react-is');\nvar assign = require('object-assign');\n\nvar ReactPropTypesSecret = require('./lib/ReactPropTypesSecret');\nvar has = require('./lib/has');\nvar checkPropTypes = require('./checkPropTypes');\n\nvar printWarning = function() {};\n\nif (process.env.NODE_ENV !== 'production') {\n printWarning = function(text) {\n var message = 'Warning: ' + text;\n if (typeof console !== 'undefined') {\n console.error(message);\n }\n try {\n // --- Welcome to debugging React ---\n // This error was thrown as a convenience so that you can use this stack\n // to find the callsite that caused this warning to fire.\n throw new Error(message);\n } catch (x) {}\n };\n}\n\nfunction emptyFunctionThatReturnsNull() {\n return null;\n}\n\nmodule.exports = function(isValidElement, throwOnDirectAccess) {\n /* global Symbol */\n var ITERATOR_SYMBOL = typeof Symbol === 'function' && Symbol.iterator;\n var FAUX_ITERATOR_SYMBOL = '@@iterator'; // Before Symbol spec.\n\n /**\n * Returns the iterator method function contained on the iterable object.\n *\n * Be sure to invoke the function with the iterable as context:\n *\n * var iteratorFn = getIteratorFn(myIterable);\n * if (iteratorFn) {\n * var iterator = iteratorFn.call(myIterable);\n * ...\n * }\n *\n * @param {?object} maybeIterable\n * @return {?function}\n */\n function getIteratorFn(maybeIterable) {\n var iteratorFn = maybeIterable && (ITERATOR_SYMBOL && maybeIterable[ITERATOR_SYMBOL] || maybeIterable[FAUX_ITERATOR_SYMBOL]);\n if (typeof iteratorFn === 'function') {\n return iteratorFn;\n }\n }\n\n /**\n * Collection of methods that allow declaration and validation of props that are\n * supplied to React components. Example usage:\n *\n * var Props = require('ReactPropTypes');\n * var MyArticle = React.createClass({\n * propTypes: {\n * // An optional string prop named \"description\".\n * description: Props.string,\n *\n * // A required enum prop named \"category\".\n * category: Props.oneOf(['News','Photos']).isRequired,\n *\n * // A prop named \"dialog\" that requires an instance of Dialog.\n * dialog: Props.instanceOf(Dialog).isRequired\n * },\n * render: function() { ... }\n * });\n *\n * A more formal specification of how these methods are used:\n *\n * type := array|bool|func|object|number|string|oneOf([...])|instanceOf(...)\n * decl := ReactPropTypes.{type}(.isRequired)?\n *\n * Each and every declaration produces a function with the same signature. This\n * allows the creation of custom validation functions. For example:\n *\n * var MyLink = React.createClass({\n * propTypes: {\n * // An optional string or URI prop named \"href\".\n * href: function(props, propName, componentName) {\n * var propValue = props[propName];\n * if (propValue != null && typeof propValue !== 'string' &&\n * !(propValue instanceof URI)) {\n * return new Error(\n * 'Expected a string or an URI for ' + propName + ' in ' +\n * componentName\n * );\n * }\n * }\n * },\n * render: function() {...}\n * });\n *\n * @internal\n */\n\n var ANONYMOUS = '<>';\n\n // Important!\n // Keep this list in sync with production version in `./factoryWithThrowingShims.js`.\n var ReactPropTypes = {\n array: createPrimitiveTypeChecker('array'),\n bigint: createPrimitiveTypeChecker('bigint'),\n bool: createPrimitiveTypeChecker('boolean'),\n func: createPrimitiveTypeChecker('function'),\n number: createPrimitiveTypeChecker('number'),\n object: createPrimitiveTypeChecker('object'),\n string: createPrimitiveTypeChecker('string'),\n symbol: createPrimitiveTypeChecker('symbol'),\n\n any: createAnyTypeChecker(),\n arrayOf: createArrayOfTypeChecker,\n element: createElementTypeChecker(),\n elementType: createElementTypeTypeChecker(),\n instanceOf: createInstanceTypeChecker,\n node: createNodeChecker(),\n objectOf: createObjectOfTypeChecker,\n oneOf: createEnumTypeChecker,\n oneOfType: createUnionTypeChecker,\n shape: createShapeTypeChecker,\n exact: createStrictShapeTypeChecker,\n };\n\n /**\n * inlined Object.is polyfill to avoid requiring consumers ship their own\n * https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object/is\n */\n /*eslint-disable no-self-compare*/\n function is(x, y) {\n // SameValue algorithm\n if (x === y) {\n // Steps 1-5, 7-10\n // Steps 6.b-6.e: +0 != -0\n return x !== 0 || 1 / x === 1 / y;\n } else {\n // Step 6.a: NaN == NaN\n return x !== x && y !== y;\n }\n }\n /*eslint-enable no-self-compare*/\n\n /**\n * We use an Error-like object for backward compatibility as people may call\n * PropTypes directly and inspect their output. However, we don't use real\n * Errors anymore. We don't inspect their stack anyway, and creating them\n * is prohibitively expensive if they are created too often, such as what\n * happens in oneOfType() for any type before the one that matched.\n */\n function PropTypeError(message, data) {\n this.message = message;\n this.data = data && typeof data === 'object' ? data: {};\n this.stack = '';\n }\n // Make `instanceof Error` still work for returned errors.\n PropTypeError.prototype = Error.prototype;\n\n function createChainableTypeChecker(validate) {\n if (process.env.NODE_ENV !== 'production') {\n var manualPropTypeCallCache = {};\n var manualPropTypeWarningCount = 0;\n }\n function checkType(isRequired, props, propName, componentName, location, propFullName, secret) {\n componentName = componentName || ANONYMOUS;\n propFullName = propFullName || propName;\n\n if (secret !== ReactPropTypesSecret) {\n if (throwOnDirectAccess) {\n // New behavior only for users of `prop-types` package\n var err = new Error(\n 'Calling PropTypes validators directly is not supported by the `prop-types` package. ' +\n 'Use `PropTypes.checkPropTypes()` to call them. ' +\n 'Read more at http://fb.me/use-check-prop-types'\n );\n err.name = 'Invariant Violation';\n throw err;\n } else if (process.env.NODE_ENV !== 'production' && typeof console !== 'undefined') {\n // Old behavior for people using React.PropTypes\n var cacheKey = componentName + ':' + propName;\n if (\n !manualPropTypeCallCache[cacheKey] &&\n // Avoid spamming the console because they are often not actionable except for lib authors\n manualPropTypeWarningCount < 3\n ) {\n printWarning(\n 'You are manually calling a React.PropTypes validation ' +\n 'function for the `' + propFullName + '` prop on `' + componentName + '`. This is deprecated ' +\n 'and will throw in the standalone `prop-types` package. ' +\n 'You may be seeing this warning due to a third-party PropTypes ' +\n 'library. See https://fb.me/react-warning-dont-call-proptypes ' + 'for details.'\n );\n manualPropTypeCallCache[cacheKey] = true;\n manualPropTypeWarningCount++;\n }\n }\n }\n if (props[propName] == null) {\n if (isRequired) {\n if (props[propName] === null) {\n return new PropTypeError('The ' + location + ' `' + propFullName + '` is marked as required ' + ('in `' + componentName + '`, but its value is `null`.'));\n }\n return new PropTypeError('The ' + location + ' `' + propFullName + '` is marked as required in ' + ('`' + componentName + '`, but its value is `undefined`.'));\n }\n return null;\n } else {\n return validate(props, propName, componentName, location, propFullName);\n }\n }\n\n var chainedCheckType = checkType.bind(null, false);\n chainedCheckType.isRequired = checkType.bind(null, true);\n\n return chainedCheckType;\n }\n\n function createPrimitiveTypeChecker(expectedType) {\n function validate(props, propName, componentName, location, propFullName, secret) {\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== expectedType) {\n // `propValue` being instance of, say, date/regexp, pass the 'object'\n // check, but we can offer a more precise error message here rather than\n // 'of type `object`'.\n var preciseType = getPreciseType(propValue);\n\n return new PropTypeError(\n 'Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + preciseType + '` supplied to `' + componentName + '`, expected ') + ('`' + expectedType + '`.'),\n {expectedType: expectedType}\n );\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createAnyTypeChecker() {\n return createChainableTypeChecker(emptyFunctionThatReturnsNull);\n }\n\n function createArrayOfTypeChecker(typeChecker) {\n function validate(props, propName, componentName, location, propFullName) {\n if (typeof typeChecker !== 'function') {\n return new PropTypeError('Property `' + propFullName + '` of component `' + componentName + '` has invalid PropType notation inside arrayOf.');\n }\n var propValue = props[propName];\n if (!Array.isArray(propValue)) {\n var propType = getPropType(propValue);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected an array.'));\n }\n for (var i = 0; i < propValue.length; i++) {\n var error = typeChecker(propValue, i, componentName, location, propFullName + '[' + i + ']', ReactPropTypesSecret);\n if (error instanceof Error) {\n return error;\n }\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createElementTypeChecker() {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n if (!isValidElement(propValue)) {\n var propType = getPropType(propValue);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected a single ReactElement.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createElementTypeTypeChecker() {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n if (!ReactIs.isValidElementType(propValue)) {\n var propType = getPropType(propValue);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected a single ReactElement type.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createInstanceTypeChecker(expectedClass) {\n function validate(props, propName, componentName, location, propFullName) {\n if (!(props[propName] instanceof expectedClass)) {\n var expectedClassName = expectedClass.name || ANONYMOUS;\n var actualClassName = getClassName(props[propName]);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + actualClassName + '` supplied to `' + componentName + '`, expected ') + ('instance of `' + expectedClassName + '`.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createEnumTypeChecker(expectedValues) {\n if (!Array.isArray(expectedValues)) {\n if (process.env.NODE_ENV !== 'production') {\n if (arguments.length > 1) {\n printWarning(\n 'Invalid arguments supplied to oneOf, expected an array, got ' + arguments.length + ' arguments. ' +\n 'A common mistake is to write oneOf(x, y, z) instead of oneOf([x, y, z]).'\n );\n } else {\n printWarning('Invalid argument supplied to oneOf, expected an array.');\n }\n }\n return emptyFunctionThatReturnsNull;\n }\n\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n for (var i = 0; i < expectedValues.length; i++) {\n if (is(propValue, expectedValues[i])) {\n return null;\n }\n }\n\n var valuesString = JSON.stringify(expectedValues, function replacer(key, value) {\n var type = getPreciseType(value);\n if (type === 'symbol') {\n return String(value);\n }\n return value;\n });\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of value `' + String(propValue) + '` ' + ('supplied to `' + componentName + '`, expected one of ' + valuesString + '.'));\n }\n return createChainableTypeChecker(validate);\n }\n\n function createObjectOfTypeChecker(typeChecker) {\n function validate(props, propName, componentName, location, propFullName) {\n if (typeof typeChecker !== 'function') {\n return new PropTypeError('Property `' + propFullName + '` of component `' + componentName + '` has invalid PropType notation inside objectOf.');\n }\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== 'object') {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected an object.'));\n }\n for (var key in propValue) {\n if (has(propValue, key)) {\n var error = typeChecker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret);\n if (error instanceof Error) {\n return error;\n }\n }\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createUnionTypeChecker(arrayOfTypeCheckers) {\n if (!Array.isArray(arrayOfTypeCheckers)) {\n process.env.NODE_ENV !== 'production' ? printWarning('Invalid argument supplied to oneOfType, expected an instance of array.') : void 0;\n return emptyFunctionThatReturnsNull;\n }\n\n for (var i = 0; i < arrayOfTypeCheckers.length; i++) {\n var checker = arrayOfTypeCheckers[i];\n if (typeof checker !== 'function') {\n printWarning(\n 'Invalid argument supplied to oneOfType. Expected an array of check functions, but ' +\n 'received ' + getPostfixForTypeWarning(checker) + ' at index ' + i + '.'\n );\n return emptyFunctionThatReturnsNull;\n }\n }\n\n function validate(props, propName, componentName, location, propFullName) {\n var expectedTypes = [];\n for (var i = 0; i < arrayOfTypeCheckers.length; i++) {\n var checker = arrayOfTypeCheckers[i];\n var checkerResult = checker(props, propName, componentName, location, propFullName, ReactPropTypesSecret);\n if (checkerResult == null) {\n return null;\n }\n if (checkerResult.data && has(checkerResult.data, 'expectedType')) {\n expectedTypes.push(checkerResult.data.expectedType);\n }\n }\n var expectedTypesMessage = (expectedTypes.length > 0) ? ', expected one of type [' + expectedTypes.join(', ') + ']': '';\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` supplied to ' + ('`' + componentName + '`' + expectedTypesMessage + '.'));\n }\n return createChainableTypeChecker(validate);\n }\n\n function createNodeChecker() {\n function validate(props, propName, componentName, location, propFullName) {\n if (!isNode(props[propName])) {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` supplied to ' + ('`' + componentName + '`, expected a ReactNode.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function invalidValidatorError(componentName, location, propFullName, key, type) {\n return new PropTypeError(\n (componentName || 'React class') + ': ' + location + ' type `' + propFullName + '.' + key + '` is invalid; ' +\n 'it must be a function, usually from the `prop-types` package, but received `' + type + '`.'\n );\n }\n\n function createShapeTypeChecker(shapeTypes) {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== 'object') {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type `' + propType + '` ' + ('supplied to `' + componentName + '`, expected `object`.'));\n }\n for (var key in shapeTypes) {\n var checker = shapeTypes[key];\n if (typeof checker !== 'function') {\n return invalidValidatorError(componentName, location, propFullName, key, getPreciseType(checker));\n }\n var error = checker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret);\n if (error) {\n return error;\n }\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createStrictShapeTypeChecker(shapeTypes) {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== 'object') {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type `' + propType + '` ' + ('supplied to `' + componentName + '`, expected `object`.'));\n }\n // We need to check all keys in case some are required but missing from props.\n var allKeys = assign({}, props[propName], shapeTypes);\n for (var key in allKeys) {\n var checker = shapeTypes[key];\n if (has(shapeTypes, key) && typeof checker !== 'function') {\n return invalidValidatorError(componentName, location, propFullName, key, getPreciseType(checker));\n }\n if (!checker) {\n return new PropTypeError(\n 'Invalid ' + location + ' `' + propFullName + '` key `' + key + '` supplied to `' + componentName + '`.' +\n '\\nBad object: ' + JSON.stringify(props[propName], null, ' ') +\n '\\nValid keys: ' + JSON.stringify(Object.keys(shapeTypes), null, ' ')\n );\n }\n var error = checker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret);\n if (error) {\n return error;\n }\n }\n return null;\n }\n\n return createChainableTypeChecker(validate);\n }\n\n function isNode(propValue) {\n switch (typeof propValue) {\n case 'number':\n case 'string':\n case 'undefined':\n return true;\n case 'boolean':\n return !propValue;\n case 'object':\n if (Array.isArray(propValue)) {\n return propValue.every(isNode);\n }\n if (propValue === null || isValidElement(propValue)) {\n return true;\n }\n\n var iteratorFn = getIteratorFn(propValue);\n if (iteratorFn) {\n var iterator = iteratorFn.call(propValue);\n var step;\n if (iteratorFn !== propValue.entries) {\n while (!(step = iterator.next()).done) {\n if (!isNode(step.value)) {\n return false;\n }\n }\n } else {\n // Iterator will provide entry [k,v] tuples rather than values.\n while (!(step = iterator.next()).done) {\n var entry = step.value;\n if (entry) {\n if (!isNode(entry[1])) {\n return false;\n }\n }\n }\n }\n } else {\n return false;\n }\n\n return true;\n default:\n return false;\n }\n }\n\n function isSymbol(propType, propValue) {\n // Native Symbol.\n if (propType === 'symbol') {\n return true;\n }\n\n // falsy value can't be a Symbol\n if (!propValue) {\n return false;\n }\n\n // 19.4.3.5 Symbol.prototype[@@toStringTag] === 'Symbol'\n if (propValue['@@toStringTag'] === 'Symbol') {\n return true;\n }\n\n // Fallback for non-spec compliant Symbols which are polyfilled.\n if (typeof Symbol === 'function' && propValue instanceof Symbol) {\n return true;\n }\n\n return false;\n }\n\n // Equivalent of `typeof` but with special handling for array and regexp.\n function getPropType(propValue) {\n var propType = typeof propValue;\n if (Array.isArray(propValue)) {\n return 'array';\n }\n if (propValue instanceof RegExp) {\n // Old webkits (at least until Android 4.0) return 'function' rather than\n // 'object' for typeof a RegExp. We'll normalize this here so that /bla/\n // passes PropTypes.object.\n return 'object';\n }\n if (isSymbol(propType, propValue)) {\n return 'symbol';\n }\n return propType;\n }\n\n // This handles more types than `getPropType`. Only used for error messages.\n // See `createPrimitiveTypeChecker`.\n function getPreciseType(propValue) {\n if (typeof propValue === 'undefined' || propValue === null) {\n return '' + propValue;\n }\n var propType = getPropType(propValue);\n if (propType === 'object') {\n if (propValue instanceof Date) {\n return 'date';\n } else if (propValue instanceof RegExp) {\n return 'regexp';\n }\n }\n return propType;\n }\n\n // Returns a string that is postfixed to a warning about an invalid type.\n // For example, \"undefined\" or \"of type array\"\n function getPostfixForTypeWarning(value) {\n var type = getPreciseType(value);\n switch (type) {\n case 'array':\n case 'object':\n return 'an ' + type;\n case 'boolean':\n case 'date':\n case 'regexp':\n return 'a ' + type;\n default:\n return type;\n }\n }\n\n // Returns class name of the object, if any.\n function getClassName(propValue) {\n if (!propValue.constructor || !propValue.constructor.name) {\n return ANONYMOUS;\n }\n return propValue.constructor.name;\n }\n\n ReactPropTypes.checkPropTypes = checkPropTypes;\n ReactPropTypes.resetWarningCache = checkPropTypes.resetWarningCache;\n ReactPropTypes.PropTypes = ReactPropTypes;\n\n return ReactPropTypes;\n};\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar ReactPropTypesSecret = require('./lib/ReactPropTypesSecret');\n\nfunction emptyFunction() {}\nfunction emptyFunctionWithReset() {}\nemptyFunctionWithReset.resetWarningCache = emptyFunction;\n\nmodule.exports = function() {\n function shim(props, propName, componentName, location, propFullName, secret) {\n if (secret === ReactPropTypesSecret) {\n // It is still safe when called from React.\n return;\n }\n var err = new Error(\n 'Calling PropTypes validators directly is not supported by the `prop-types` package. ' +\n 'Use PropTypes.checkPropTypes() to call them. ' +\n 'Read more at http://fb.me/use-check-prop-types'\n );\n err.name = 'Invariant Violation';\n throw err;\n };\n shim.isRequired = shim;\n function getShim() {\n return shim;\n };\n // Important!\n // Keep this list in sync with production version in `./factoryWithTypeCheckers.js`.\n var ReactPropTypes = {\n array: shim,\n bigint: shim,\n bool: shim,\n func: shim,\n number: shim,\n object: shim,\n string: shim,\n symbol: shim,\n\n any: shim,\n arrayOf: getShim,\n element: shim,\n elementType: shim,\n instanceOf: getShim,\n node: shim,\n objectOf: getShim,\n oneOf: getShim,\n oneOfType: getShim,\n shape: getShim,\n exact: getShim,\n\n checkPropTypes: emptyFunctionWithReset,\n resetWarningCache: emptyFunction\n };\n\n ReactPropTypes.PropTypes = ReactPropTypes;\n\n return ReactPropTypes;\n};\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\nif (process.env.NODE_ENV !== 'production') {\n var ReactIs = require('react-is');\n\n // By explicitly using `prop-types` you are opting into new development behavior.\n // http://fb.me/prop-types-in-prod\n var throwOnDirectAccess = true;\n module.exports = require('./factoryWithTypeCheckers')(ReactIs.isElement, throwOnDirectAccess);\n} else {\n // By explicitly using `prop-types` you are opting into new production behavior.\n // http://fb.me/prop-types-in-prod\n module.exports = require('./factoryWithThrowingShims')();\n}\n","import PropTypes from 'prop-types';\nimport chainPropTypes from '../chainPropTypes';\nfunction isClassComponent(elementType) {\n // elementType.prototype?.isReactComponent\n const {\n prototype = {}\n } = elementType;\n return Boolean(prototype.isReactComponent);\n}\nfunction acceptingRef(props, propName, componentName, location, propFullName) {\n const element = props[propName];\n const safePropName = propFullName || propName;\n if (element == null ||\n // When server-side rendering React doesn't warn either.\n // This is not an accurate check for SSR.\n // This is only in place for Emotion compat.\n // TODO: Revisit once https://github.com/facebook/react/issues/20047 is resolved.\n typeof window === 'undefined') {\n return null;\n }\n let warningHint;\n const elementType = element.type;\n /**\n * Blacklisting instead of whitelisting\n *\n * Blacklisting will miss some components, such as React.Fragment. Those will at least\n * trigger a warning in React.\n * We can't whitelist because there is no safe way to detect React.forwardRef\n * or class components. \"Safe\" means there's no public API.\n *\n */\n if (typeof elementType === 'function' && !isClassComponent(elementType)) {\n warningHint = 'Did you accidentally use a plain function component for an element instead?';\n }\n if (warningHint !== undefined) {\n return new Error(`Invalid ${location} \\`${safePropName}\\` supplied to \\`${componentName}\\`. ` + `Expected an element that can hold a ref. ${warningHint} ` + 'For more information see https://mui.com/r/caveat-with-refs-guide');\n }\n return null;\n}\nconst elementAcceptingRef = chainPropTypes(PropTypes.element, acceptingRef);\nelementAcceptingRef.isRequired = chainPropTypes(PropTypes.element.isRequired, acceptingRef);\nexport default elementAcceptingRef;","import _extends from \"@babel/runtime/helpers/esm/extends\";\n// This module is based on https://github.com/airbnb/prop-types-exact repository.\n// However, in order to reduce the number of dependencies and to remove some extra safe checks\n// the module was forked.\n\nconst specialProperty = 'exact-prop: \\u200b';\nexport default function exactProp(propTypes) {\n if (process.env.NODE_ENV === 'production') {\n return propTypes;\n }\n return _extends({}, propTypes, {\n [specialProperty]: props => {\n const unsupportedProps = Object.keys(props).filter(prop => !propTypes.hasOwnProperty(prop));\n if (unsupportedProps.length > 0) {\n return new Error(`The following props are not supported: ${unsupportedProps.map(prop => `\\`${prop}\\``).join(', ')}. Please remove them.`);\n }\n return null;\n }\n });\n}","/**\n * WARNING: Don't import this directly.\n * Use `MuiError` from `@mui/internal-babel-macros/MuiError.macro` instead.\n * @param {number} code\n */\nexport default function formatMuiErrorMessage(code) {\n // Apply babel-plugin-transform-template-literals in loose mode\n // loose mode is safe if we're concatenating primitives\n // see https://babeljs.io/docs/en/babel-plugin-transform-template-literals#loose\n /* eslint-disable prefer-template */\n let url = 'https://mui.com/production-error/?code=' + code;\n for (let i = 1; i < arguments.length; i += 1) {\n // rest params over-transpile for this case\n // eslint-disable-next-line prefer-rest-params\n url += '&args[]=' + encodeURIComponent(arguments[i]);\n }\n return 'Minified MUI error #' + code + '; visit ' + url + ' for the full message.';\n /* eslint-enable prefer-template */\n}","/**\n * @license React\n * react-is.production.min.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n'use strict';var b=Symbol.for(\"react.element\"),c=Symbol.for(\"react.portal\"),d=Symbol.for(\"react.fragment\"),e=Symbol.for(\"react.strict_mode\"),f=Symbol.for(\"react.profiler\"),g=Symbol.for(\"react.provider\"),h=Symbol.for(\"react.context\"),k=Symbol.for(\"react.server_context\"),l=Symbol.for(\"react.forward_ref\"),m=Symbol.for(\"react.suspense\"),n=Symbol.for(\"react.suspense_list\"),p=Symbol.for(\"react.memo\"),q=Symbol.for(\"react.lazy\"),t=Symbol.for(\"react.offscreen\"),u;u=Symbol.for(\"react.module.reference\");\nfunction v(a){if(\"object\"===typeof a&&null!==a){var r=a.$$typeof;switch(r){case b:switch(a=a.type,a){case d:case f:case e:case m:case n:return a;default:switch(a=a&&a.$$typeof,a){case k:case h:case l:case q:case p:case g:return a;default:return r}}case c:return r}}}exports.ContextConsumer=h;exports.ContextProvider=g;exports.Element=b;exports.ForwardRef=l;exports.Fragment=d;exports.Lazy=q;exports.Memo=p;exports.Portal=c;exports.Profiler=f;exports.StrictMode=e;exports.Suspense=m;\nexports.SuspenseList=n;exports.isAsyncMode=function(){return!1};exports.isConcurrentMode=function(){return!1};exports.isContextConsumer=function(a){return v(a)===h};exports.isContextProvider=function(a){return v(a)===g};exports.isElement=function(a){return\"object\"===typeof a&&null!==a&&a.$$typeof===b};exports.isForwardRef=function(a){return v(a)===l};exports.isFragment=function(a){return v(a)===d};exports.isLazy=function(a){return v(a)===q};exports.isMemo=function(a){return v(a)===p};\nexports.isPortal=function(a){return v(a)===c};exports.isProfiler=function(a){return v(a)===f};exports.isStrictMode=function(a){return v(a)===e};exports.isSuspense=function(a){return v(a)===m};exports.isSuspenseList=function(a){return v(a)===n};\nexports.isValidElementType=function(a){return\"string\"===typeof a||\"function\"===typeof a||a===d||a===f||a===e||a===m||a===n||a===t||\"object\"===typeof a&&null!==a&&(a.$$typeof===q||a.$$typeof===p||a.$$typeof===g||a.$$typeof===h||a.$$typeof===l||a.$$typeof===u||void 0!==a.getModuleId)?!0:!1};exports.typeOf=v;\n","/**\n * @license React\n * react-is.development.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nif (process.env.NODE_ENV !== \"production\") {\n (function() {\n'use strict';\n\n// ATTENTION\n// When adding new symbols to this file,\n// Please consider also adding to 'react-devtools-shared/src/backend/ReactSymbols'\n// The Symbol used to tag the ReactElement-like types.\nvar REACT_ELEMENT_TYPE = Symbol.for('react.element');\nvar REACT_PORTAL_TYPE = Symbol.for('react.portal');\nvar REACT_FRAGMENT_TYPE = Symbol.for('react.fragment');\nvar REACT_STRICT_MODE_TYPE = Symbol.for('react.strict_mode');\nvar REACT_PROFILER_TYPE = Symbol.for('react.profiler');\nvar REACT_PROVIDER_TYPE = Symbol.for('react.provider');\nvar REACT_CONTEXT_TYPE = Symbol.for('react.context');\nvar REACT_SERVER_CONTEXT_TYPE = Symbol.for('react.server_context');\nvar REACT_FORWARD_REF_TYPE = Symbol.for('react.forward_ref');\nvar REACT_SUSPENSE_TYPE = Symbol.for('react.suspense');\nvar REACT_SUSPENSE_LIST_TYPE = Symbol.for('react.suspense_list');\nvar REACT_MEMO_TYPE = Symbol.for('react.memo');\nvar REACT_LAZY_TYPE = Symbol.for('react.lazy');\nvar REACT_OFFSCREEN_TYPE = Symbol.for('react.offscreen');\n\n// -----------------------------------------------------------------------------\n\nvar enableScopeAPI = false; // Experimental Create Event Handle API.\nvar enableCacheElement = false;\nvar enableTransitionTracing = false; // No known bugs, but needs performance testing\n\nvar enableLegacyHidden = false; // Enables unstable_avoidThisFallback feature in Fiber\n// stuff. Intended to enable React core members to more easily debug scheduling\n// issues in DEV builds.\n\nvar enableDebugTracing = false; // Track which Fiber(s) schedule render work.\n\nvar REACT_MODULE_REFERENCE;\n\n{\n REACT_MODULE_REFERENCE = Symbol.for('react.module.reference');\n}\n\nfunction isValidElementType(type) {\n if (typeof type === 'string' || typeof type === 'function') {\n return true;\n } // Note: typeof might be other than 'symbol' or 'number' (e.g. if it's a polyfill).\n\n\n if (type === REACT_FRAGMENT_TYPE || type === REACT_PROFILER_TYPE || enableDebugTracing || type === REACT_STRICT_MODE_TYPE || type === REACT_SUSPENSE_TYPE || type === REACT_SUSPENSE_LIST_TYPE || enableLegacyHidden || type === REACT_OFFSCREEN_TYPE || enableScopeAPI || enableCacheElement || enableTransitionTracing ) {\n return true;\n }\n\n if (typeof type === 'object' && type !== null) {\n if (type.$$typeof === REACT_LAZY_TYPE || type.$$typeof === REACT_MEMO_TYPE || type.$$typeof === REACT_PROVIDER_TYPE || type.$$typeof === REACT_CONTEXT_TYPE || type.$$typeof === REACT_FORWARD_REF_TYPE || // This needs to include all possible module reference object\n // types supported by any Flight configuration anywhere since\n // we don't know which Flight build this will end up being used\n // with.\n type.$$typeof === REACT_MODULE_REFERENCE || type.getModuleId !== undefined) {\n return true;\n }\n }\n\n return false;\n}\n\nfunction typeOf(object) {\n if (typeof object === 'object' && object !== null) {\n var $$typeof = object.$$typeof;\n\n switch ($$typeof) {\n case REACT_ELEMENT_TYPE:\n var type = object.type;\n\n switch (type) {\n case REACT_FRAGMENT_TYPE:\n case REACT_PROFILER_TYPE:\n case REACT_STRICT_MODE_TYPE:\n case REACT_SUSPENSE_TYPE:\n case REACT_SUSPENSE_LIST_TYPE:\n return type;\n\n default:\n var $$typeofType = type && type.$$typeof;\n\n switch ($$typeofType) {\n case REACT_SERVER_CONTEXT_TYPE:\n case REACT_CONTEXT_TYPE:\n case REACT_FORWARD_REF_TYPE:\n case REACT_LAZY_TYPE:\n case REACT_MEMO_TYPE:\n case REACT_PROVIDER_TYPE:\n return $$typeofType;\n\n default:\n return $$typeof;\n }\n\n }\n\n case REACT_PORTAL_TYPE:\n return $$typeof;\n }\n }\n\n return undefined;\n}\nvar ContextConsumer = REACT_CONTEXT_TYPE;\nvar ContextProvider = REACT_PROVIDER_TYPE;\nvar Element = REACT_ELEMENT_TYPE;\nvar ForwardRef = REACT_FORWARD_REF_TYPE;\nvar Fragment = REACT_FRAGMENT_TYPE;\nvar Lazy = REACT_LAZY_TYPE;\nvar Memo = REACT_MEMO_TYPE;\nvar Portal = REACT_PORTAL_TYPE;\nvar Profiler = REACT_PROFILER_TYPE;\nvar StrictMode = REACT_STRICT_MODE_TYPE;\nvar Suspense = REACT_SUSPENSE_TYPE;\nvar SuspenseList = REACT_SUSPENSE_LIST_TYPE;\nvar hasWarnedAboutDeprecatedIsAsyncMode = false;\nvar hasWarnedAboutDeprecatedIsConcurrentMode = false; // AsyncMode should be deprecated\n\nfunction isAsyncMode(object) {\n {\n if (!hasWarnedAboutDeprecatedIsAsyncMode) {\n hasWarnedAboutDeprecatedIsAsyncMode = true; // Using console['warn'] to evade Babel and ESLint\n\n console['warn']('The ReactIs.isAsyncMode() alias has been deprecated, ' + 'and will be removed in React 18+.');\n }\n }\n\n return false;\n}\nfunction isConcurrentMode(object) {\n {\n if (!hasWarnedAboutDeprecatedIsConcurrentMode) {\n hasWarnedAboutDeprecatedIsConcurrentMode = true; // Using console['warn'] to evade Babel and ESLint\n\n console['warn']('The ReactIs.isConcurrentMode() alias has been deprecated, ' + 'and will be removed in React 18+.');\n }\n }\n\n return false;\n}\nfunction isContextConsumer(object) {\n return typeOf(object) === REACT_CONTEXT_TYPE;\n}\nfunction isContextProvider(object) {\n return typeOf(object) === REACT_PROVIDER_TYPE;\n}\nfunction isElement(object) {\n return typeof object === 'object' && object !== null && object.$$typeof === REACT_ELEMENT_TYPE;\n}\nfunction isForwardRef(object) {\n return typeOf(object) === REACT_FORWARD_REF_TYPE;\n}\nfunction isFragment(object) {\n return typeOf(object) === REACT_FRAGMENT_TYPE;\n}\nfunction isLazy(object) {\n return typeOf(object) === REACT_LAZY_TYPE;\n}\nfunction isMemo(object) {\n return typeOf(object) === REACT_MEMO_TYPE;\n}\nfunction isPortal(object) {\n return typeOf(object) === REACT_PORTAL_TYPE;\n}\nfunction isProfiler(object) {\n return typeOf(object) === REACT_PROFILER_TYPE;\n}\nfunction isStrictMode(object) {\n return typeOf(object) === REACT_STRICT_MODE_TYPE;\n}\nfunction isSuspense(object) {\n return typeOf(object) === REACT_SUSPENSE_TYPE;\n}\nfunction isSuspenseList(object) {\n return typeOf(object) === REACT_SUSPENSE_LIST_TYPE;\n}\n\nexports.ContextConsumer = ContextConsumer;\nexports.ContextProvider = ContextProvider;\nexports.Element = Element;\nexports.ForwardRef = ForwardRef;\nexports.Fragment = Fragment;\nexports.Lazy = Lazy;\nexports.Memo = Memo;\nexports.Portal = Portal;\nexports.Profiler = Profiler;\nexports.StrictMode = StrictMode;\nexports.Suspense = Suspense;\nexports.SuspenseList = SuspenseList;\nexports.isAsyncMode = isAsyncMode;\nexports.isConcurrentMode = isConcurrentMode;\nexports.isContextConsumer = isContextConsumer;\nexports.isContextProvider = isContextProvider;\nexports.isElement = isElement;\nexports.isForwardRef = isForwardRef;\nexports.isFragment = isFragment;\nexports.isLazy = isLazy;\nexports.isMemo = isMemo;\nexports.isPortal = isPortal;\nexports.isProfiler = isProfiler;\nexports.isStrictMode = isStrictMode;\nexports.isSuspense = isSuspense;\nexports.isSuspenseList = isSuspenseList;\nexports.isValidElementType = isValidElementType;\nexports.typeOf = typeOf;\n })();\n}\n","'use strict';\n\nif (process.env.NODE_ENV === 'production') {\n module.exports = require('./cjs/react-is.production.min.js');\n} else {\n module.exports = require('./cjs/react-is.development.js');\n}\n","import { ForwardRef, Memo } from 'react-is';\n\n// Simplified polyfill for IE11 support\n// https://github.com/JamesMGreene/Function.name/blob/58b314d4a983110c3682f1228f845d39ccca1817/Function.name.js#L3\nconst fnNameMatchRegex = /^\\s*function(?:\\s|\\s*\\/\\*.*\\*\\/\\s*)+([^(\\s/]*)\\s*/;\nexport function getFunctionName(fn) {\n const match = `${fn}`.match(fnNameMatchRegex);\n const name = match && match[1];\n return name || '';\n}\nfunction getFunctionComponentName(Component, fallback = '') {\n return Component.displayName || Component.name || getFunctionName(Component) || fallback;\n}\nfunction getWrappedName(outerType, innerType, wrapperName) {\n const functionName = getFunctionComponentName(innerType);\n return outerType.displayName || (functionName !== '' ? `${wrapperName}(${functionName})` : wrapperName);\n}\n\n/**\n * cherry-pick from\n * https://github.com/facebook/react/blob/769b1f270e1251d9dbdce0fcbd9e92e502d059b8/packages/shared/getComponentName.js\n * originally forked from recompose/getDisplayName with added IE11 support\n */\nexport default function getDisplayName(Component) {\n if (Component == null) {\n return undefined;\n }\n if (typeof Component === 'string') {\n return Component;\n }\n if (typeof Component === 'function') {\n return getFunctionComponentName(Component, 'Component');\n }\n\n // TypeScript can't have components as objects but they exist in the form of `memo` or `Suspense`\n if (typeof Component === 'object') {\n switch (Component.$$typeof) {\n case ForwardRef:\n return getWrappedName(Component, Component.render, 'ForwardRef');\n case Memo:\n return getWrappedName(Component, Component.type, 'memo');\n default:\n return undefined;\n }\n }\n return undefined;\n}","export default function HTMLElementType(props, propName, componentName, location, propFullName) {\n if (process.env.NODE_ENV === 'production') {\n return null;\n }\n const propValue = props[propName];\n const safePropName = propFullName || propName;\n if (propValue == null) {\n return null;\n }\n if (propValue && propValue.nodeType !== 1) {\n return new Error(`Invalid ${location} \\`${safePropName}\\` supplied to \\`${componentName}\\`. ` + `Expected an HTMLElement.`);\n }\n return null;\n}","import PropTypes from 'prop-types';\nconst refType = PropTypes.oneOfType([PropTypes.func, PropTypes.object]);\nexport default refType;","import _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\n// It should to be noted that this function isn't equivalent to `text-transform: capitalize`.\n//\n// A strict capitalization should uppercase the first letter of each word in the sentence.\n// We only handle the first word.\nexport default function capitalize(string) {\n if (typeof string !== 'string') {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: \\`capitalize(string)\\` expects a string argument.` : _formatMuiErrorMessage(7));\n }\n return string.charAt(0).toUpperCase() + string.slice(1);\n}","/**\n * Safe chained function.\n *\n * Will only create a new function if needed,\n * otherwise will pass back existing functions or null.\n */\nexport default function createChainedFunction(...funcs) {\n return funcs.reduce((acc, func) => {\n if (func == null) {\n return acc;\n }\n return function chainedFunction(...args) {\n acc.apply(this, args);\n func.apply(this, args);\n };\n }, () => {});\n}","// Corresponds to 10 frames at 60 Hz.\n// A few bytes payload overhead when lodash/debounce is ~3 kB and debounce ~300 B.\nexport default function debounce(func, wait = 166) {\n let timeout;\n function debounced(...args) {\n const later = () => {\n // @ts-ignore\n func.apply(this, args);\n };\n clearTimeout(timeout);\n timeout = setTimeout(later, wait);\n }\n debounced.clear = () => {\n clearTimeout(timeout);\n };\n return debounced;\n}","export default function deprecatedPropType(validator, reason) {\n if (process.env.NODE_ENV === 'production') {\n return () => null;\n }\n return (props, propName, componentName, location, propFullName) => {\n const componentNameSafe = componentName || '<>';\n const propFullNameSafe = propFullName || propName;\n if (typeof props[propName] !== 'undefined') {\n return new Error(`The ${location} \\`${propFullNameSafe}\\` of ` + `\\`${componentNameSafe}\\` is deprecated. ${reason}`);\n }\n return null;\n };\n}","import * as React from 'react';\nexport default function isMuiElement(element, muiNames) {\n var _muiName, _element$type;\n return /*#__PURE__*/React.isValidElement(element) && muiNames.indexOf( // For server components `muiName` is avaialble in element.type._payload.value.muiName\n // relevant info - https://github.com/facebook/react/blob/2807d781a08db8e9873687fccc25c0f12b4fb3d4/packages/react/src/ReactLazy.js#L45\n // eslint-disable-next-line no-underscore-dangle\n (_muiName = element.type.muiName) != null ? _muiName : (_element$type = element.type) == null || (_element$type = _element$type._payload) == null || (_element$type = _element$type.value) == null ? void 0 : _element$type.muiName) !== -1;\n}","export default function ownerDocument(node) {\n return node && node.ownerDocument || document;\n}","import ownerDocument from '../ownerDocument';\nexport default function ownerWindow(node) {\n const doc = ownerDocument(node);\n return doc.defaultView || window;\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nexport default function requirePropFactory(componentNameInError, Component) {\n if (process.env.NODE_ENV === 'production') {\n return () => null;\n }\n\n // eslint-disable-next-line react/forbid-foreign-prop-types\n const prevPropTypes = Component ? _extends({}, Component.propTypes) : null;\n const requireProp = requiredProp => (props, propName, componentName, location, propFullName, ...args) => {\n const propFullNameSafe = propFullName || propName;\n const defaultTypeChecker = prevPropTypes == null ? void 0 : prevPropTypes[propFullNameSafe];\n if (defaultTypeChecker) {\n const typeCheckerResult = defaultTypeChecker(props, propName, componentName, location, propFullName, ...args);\n if (typeCheckerResult) {\n return typeCheckerResult;\n }\n }\n if (typeof props[propName] !== 'undefined' && !props[requiredProp]) {\n return new Error(`The prop \\`${propFullNameSafe}\\` of ` + `\\`${componentNameInError}\\` can only be used together with the \\`${requiredProp}\\` prop.`);\n }\n return null;\n };\n return requireProp;\n}","/**\n * TODO v5: consider making it private\n *\n * passes {value} to {ref}\n *\n * WARNING: Be sure to only call this inside a callback that is passed as a ref.\n * Otherwise, make sure to cleanup the previous {ref} if it changes. See\n * https://github.com/mui/material-ui/issues/13539\n *\n * Useful if you want to expose the ref of an inner component to the public API\n * while still using it inside the component.\n * @param ref A ref callback or ref object. If anything falsy, this is a no-op.\n */\nexport default function setRef(ref, value) {\n if (typeof ref === 'function') {\n ref(value);\n } else if (ref) {\n ref.current = value;\n }\n}","'use client';\n\nimport * as React from 'react';\n\n/**\n * A version of `React.useLayoutEffect` that does not show a warning when server-side rendering.\n * This is useful for effects that are only needed for client-side rendering but not for SSR.\n *\n * Before you use this hook, make sure to read https://gist.github.com/gaearon/e7d97cdf38a2907924ea12e4ebdf3c85\n * and confirm it doesn't apply to your use-case.\n */\nconst useEnhancedEffect = typeof window !== 'undefined' ? React.useLayoutEffect : React.useEffect;\nexport default useEnhancedEffect;","'use client';\n\nimport * as React from 'react';\nlet globalId = 0;\nfunction useGlobalId(idOverride) {\n const [defaultId, setDefaultId] = React.useState(idOverride);\n const id = idOverride || defaultId;\n React.useEffect(() => {\n if (defaultId == null) {\n // Fallback to this default id when possible.\n // Use the incrementing value for client-side rendering only.\n // We can't use it server-side.\n // If you want to use random values please consider the Birthday Problem: https://en.wikipedia.org/wiki/Birthday_problem\n globalId += 1;\n setDefaultId(`mui-${globalId}`);\n }\n }, [defaultId]);\n return id;\n}\n\n// downstream bundlers may remove unnecessary concatenation, but won't remove toString call -- Workaround for https://github.com/webpack/webpack/issues/14814\nconst maybeReactUseId = React['useId'.toString()];\n/**\n *\n * @example
    \n * @param idOverride\n * @returns {string}\n */\nexport default function useId(idOverride) {\n if (maybeReactUseId !== undefined) {\n const reactId = maybeReactUseId();\n return idOverride != null ? idOverride : reactId;\n }\n // eslint-disable-next-line react-hooks/rules-of-hooks -- `React.useId` is invariant at runtime.\n return useGlobalId(idOverride);\n}","export default function unsupportedProp(props, propName, componentName, location, propFullName) {\n if (process.env.NODE_ENV === 'production') {\n return null;\n }\n const propFullNameSafe = propFullName || propName;\n if (typeof props[propName] !== 'undefined') {\n return new Error(`The prop \\`${propFullNameSafe}\\` is not supported. Please remove it.`);\n }\n return null;\n}","'use client';\n\n/* eslint-disable react-hooks/rules-of-hooks, react-hooks/exhaustive-deps */\nimport * as React from 'react';\nexport default function useControlled({\n controlled,\n default: defaultProp,\n name,\n state = 'value'\n}) {\n // isControlled is ignored in the hook dependency lists as it should never change.\n const {\n current: isControlled\n } = React.useRef(controlled !== undefined);\n const [valueState, setValue] = React.useState(defaultProp);\n const value = isControlled ? controlled : valueState;\n if (process.env.NODE_ENV !== 'production') {\n React.useEffect(() => {\n if (isControlled !== (controlled !== undefined)) {\n console.error([`MUI: A component is changing the ${isControlled ? '' : 'un'}controlled ${state} state of ${name} to be ${isControlled ? 'un' : ''}controlled.`, 'Elements should not switch from uncontrolled to controlled (or vice versa).', `Decide between using a controlled or uncontrolled ${name} ` + 'element for the lifetime of the component.', \"The nature of the state is determined during the first render. It's considered controlled if the value is not `undefined`.\", 'More info: https://fb.me/react-controlled-components'].join('\\n'));\n }\n }, [state, name, controlled]);\n const {\n current: defaultValue\n } = React.useRef(defaultProp);\n React.useEffect(() => {\n if (!isControlled && defaultValue !== defaultProp) {\n console.error([`MUI: A component is changing the default ${state} state of an uncontrolled ${name} after being initialized. ` + `To suppress this warning opt to use a controlled ${name}.`].join('\\n'));\n }\n }, [JSON.stringify(defaultProp)]);\n }\n const setValueIfUncontrolled = React.useCallback(newValue => {\n if (!isControlled) {\n setValue(newValue);\n }\n }, []);\n return [value, setValueIfUncontrolled];\n}","'use client';\n\nimport * as React from 'react';\nimport useEnhancedEffect from '../useEnhancedEffect';\n\n/**\n * Inspired by https://github.com/facebook/react/issues/14099#issuecomment-440013892\n * See RFC in https://github.com/reactjs/rfcs/pull/220\n */\n\nfunction useEventCallback(fn) {\n const ref = React.useRef(fn);\n useEnhancedEffect(() => {\n ref.current = fn;\n });\n return React.useRef((...args) =>\n // @ts-expect-error hide `this`\n (0, ref.current)(...args)).current;\n}\nexport default useEventCallback;","'use client';\n\nimport * as React from 'react';\nimport setRef from '../setRef';\nexport default function useForkRef(...refs) {\n /**\n * This will create a new function if the refs passed to this hook change and are all defined.\n * This means react will call the old forkRef with `null` and the new forkRef\n * with the ref. Cleanup naturally emerges from this behavior.\n */\n return React.useMemo(() => {\n if (refs.every(ref => ref == null)) {\n return null;\n }\n return instance => {\n refs.forEach(ref => {\n setRef(ref, instance);\n });\n };\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, refs);\n}","'use client';\n\nimport * as React from 'react';\nconst UNINITIALIZED = {};\n\n/**\n * A React.useRef() that is initialized lazily with a function. Note that it accepts an optional\n * initialization argument, so the initialization function doesn't need to be an inline closure.\n *\n * @usage\n * const ref = useLazyRef(sortColumns, columns)\n */\nexport default function useLazyRef(init, initArg) {\n const ref = React.useRef(UNINITIALIZED);\n if (ref.current === UNINITIALIZED) {\n ref.current = init(initArg);\n }\n return ref;\n}","'use client';\n\nimport * as React from 'react';\nconst EMPTY = [];\n\n/**\n * A React.useEffect equivalent that runs once, when the component is mounted.\n */\nexport default function useOnMount(fn) {\n /* eslint-disable react-hooks/exhaustive-deps */\n React.useEffect(fn, EMPTY);\n /* eslint-enable react-hooks/exhaustive-deps */\n}","'use client';\n\nimport useLazyRef from '../useLazyRef/useLazyRef';\nimport useOnMount from '../useOnMount/useOnMount';\nexport class Timeout {\n constructor() {\n this.currentId = null;\n this.clear = () => {\n if (this.currentId !== null) {\n clearTimeout(this.currentId);\n this.currentId = null;\n }\n };\n this.disposeEffect = () => {\n return this.clear;\n };\n }\n static create() {\n return new Timeout();\n }\n /**\n * Executes `fn` after `delay`, clearing any previously scheduled call.\n */\n start(delay, fn) {\n this.clear();\n this.currentId = setTimeout(() => {\n this.currentId = null;\n fn();\n }, delay);\n }\n}\nexport default function useTimeout() {\n const timeout = useLazyRef(Timeout.create).current;\n useOnMount(timeout.disposeEffect);\n return timeout;\n}","'use client';\n\n// based on https://github.com/WICG/focus-visible/blob/v4.1.5/src/focus-visible.js\nimport * as React from 'react';\nimport { Timeout } from '../useTimeout/useTimeout';\nlet hadKeyboardEvent = true;\nlet hadFocusVisibleRecently = false;\nconst hadFocusVisibleRecentlyTimeout = new Timeout();\nconst inputTypesWhitelist = {\n text: true,\n search: true,\n url: true,\n tel: true,\n email: true,\n password: true,\n number: true,\n date: true,\n month: true,\n week: true,\n time: true,\n datetime: true,\n 'datetime-local': true\n};\n\n/**\n * Computes whether the given element should automatically trigger the\n * `focus-visible` class being added, i.e. whether it should always match\n * `:focus-visible` when focused.\n * @param {Element} node\n * @returns {boolean}\n */\nfunction focusTriggersKeyboardModality(node) {\n const {\n type,\n tagName\n } = node;\n if (tagName === 'INPUT' && inputTypesWhitelist[type] && !node.readOnly) {\n return true;\n }\n if (tagName === 'TEXTAREA' && !node.readOnly) {\n return true;\n }\n if (node.isContentEditable) {\n return true;\n }\n return false;\n}\n\n/**\n * Keep track of our keyboard modality state with `hadKeyboardEvent`.\n * If the most recent user interaction was via the keyboard;\n * and the key press did not include a meta, alt/option, or control key;\n * then the modality is keyboard. Otherwise, the modality is not keyboard.\n * @param {KeyboardEvent} event\n */\nfunction handleKeyDown(event) {\n if (event.metaKey || event.altKey || event.ctrlKey) {\n return;\n }\n hadKeyboardEvent = true;\n}\n\n/**\n * If at any point a user clicks with a pointing device, ensure that we change\n * the modality away from keyboard.\n * This avoids the situation where a user presses a key on an already focused\n * element, and then clicks on a different element, focusing it with a\n * pointing device, while we still think we're in keyboard modality.\n */\nfunction handlePointerDown() {\n hadKeyboardEvent = false;\n}\nfunction handleVisibilityChange() {\n if (this.visibilityState === 'hidden') {\n // If the tab becomes active again, the browser will handle calling focus\n // on the element (Safari actually calls it twice).\n // If this tab change caused a blur on an element with focus-visible,\n // re-apply the class when the user switches back to the tab.\n if (hadFocusVisibleRecently) {\n hadKeyboardEvent = true;\n }\n }\n}\nfunction prepare(doc) {\n doc.addEventListener('keydown', handleKeyDown, true);\n doc.addEventListener('mousedown', handlePointerDown, true);\n doc.addEventListener('pointerdown', handlePointerDown, true);\n doc.addEventListener('touchstart', handlePointerDown, true);\n doc.addEventListener('visibilitychange', handleVisibilityChange, true);\n}\nexport function teardown(doc) {\n doc.removeEventListener('keydown', handleKeyDown, true);\n doc.removeEventListener('mousedown', handlePointerDown, true);\n doc.removeEventListener('pointerdown', handlePointerDown, true);\n doc.removeEventListener('touchstart', handlePointerDown, true);\n doc.removeEventListener('visibilitychange', handleVisibilityChange, true);\n}\nfunction isFocusVisible(event) {\n const {\n target\n } = event;\n try {\n return target.matches(':focus-visible');\n } catch (error) {\n // Browsers not implementing :focus-visible will throw a SyntaxError.\n // We use our own heuristic for those browsers.\n // Rethrow might be better if it's not the expected error but do we really\n // want to crash if focus-visible malfunctioned?\n }\n\n // No need for validFocusTarget check. The user does that by attaching it to\n // focusable events only.\n return hadKeyboardEvent || focusTriggersKeyboardModality(target);\n}\nexport default function useIsFocusVisible() {\n const ref = React.useCallback(node => {\n if (node != null) {\n prepare(node.ownerDocument);\n }\n }, []);\n const isFocusVisibleRef = React.useRef(false);\n\n /**\n * Should be called if a blur event is fired\n */\n function handleBlurVisible() {\n // checking against potential state variable does not suffice if we focus and blur synchronously.\n // React wouldn't have time to trigger a re-render so `focusVisible` would be stale.\n // Ideally we would adjust `isFocusVisible(event)` to look at `relatedTarget` for blur events.\n // This doesn't work in IE11 due to https://github.com/facebook/react/issues/3751\n // TODO: check again if React releases their internal changes to focus event handling (https://github.com/facebook/react/pull/19186).\n if (isFocusVisibleRef.current) {\n // To detect a tab/window switch, we look for a blur event followed\n // rapidly by a visibility change.\n // If we don't see a visibility change within 100ms, it's probably a\n // regular focus change.\n hadFocusVisibleRecently = true;\n hadFocusVisibleRecentlyTimeout.start(100, () => {\n hadFocusVisibleRecently = false;\n });\n isFocusVisibleRef.current = false;\n return true;\n }\n return false;\n }\n\n /**\n * Should be called if a blur event is fired\n */\n function handleFocusVisible(event) {\n if (isFocusVisible(event)) {\n isFocusVisibleRef.current = true;\n return true;\n }\n return false;\n }\n return {\n isFocusVisibleRef,\n onFocus: handleFocusVisible,\n onBlur: handleBlurVisible,\n ref\n };\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\n/**\n * Add keys, values of `defaultProps` that does not exist in `props`\n * @param {object} defaultProps\n * @param {object} props\n * @returns {object} resolved props\n */\nexport default function resolveProps(defaultProps, props) {\n const output = _extends({}, props);\n Object.keys(defaultProps).forEach(propName => {\n if (propName.toString().match(/^(components|slots)$/)) {\n output[propName] = _extends({}, defaultProps[propName], output[propName]);\n } else if (propName.toString().match(/^(componentsProps|slotProps)$/)) {\n const defaultSlotProps = defaultProps[propName] || {};\n const slotProps = props[propName];\n output[propName] = {};\n if (!slotProps || !Object.keys(slotProps)) {\n // Reduce the iteration if the slot props is empty\n output[propName] = defaultSlotProps;\n } else if (!defaultSlotProps || !Object.keys(defaultSlotProps)) {\n // Reduce the iteration if the default slot props is empty\n output[propName] = slotProps;\n } else {\n output[propName] = _extends({}, slotProps);\n Object.keys(defaultSlotProps).forEach(slotPropName => {\n output[propName][slotPropName] = resolveProps(defaultSlotProps[slotPropName], slotProps[slotPropName]);\n });\n }\n } else if (output[propName] === undefined) {\n output[propName] = defaultProps[propName];\n }\n });\n return output;\n}","export default function composeClasses(slots, getUtilityClass, classes = undefined) {\n const output = {};\n Object.keys(slots).forEach(\n // `Object.keys(slots)` can't be wider than `T` because we infer `T` from `slots`.\n // @ts-expect-error https://github.com/microsoft/TypeScript/pull/12253#issuecomment-263132208\n slot => {\n output[slot] = slots[slot].reduce((acc, key) => {\n if (key) {\n const utilityClass = getUtilityClass(key);\n if (utilityClass !== '') {\n acc.push(utilityClass);\n }\n if (classes && classes[key]) {\n acc.push(classes[key]);\n }\n }\n return acc;\n }, []).join(' ');\n });\n return output;\n}","const defaultGenerator = componentName => componentName;\nconst createClassNameGenerator = () => {\n let generate = defaultGenerator;\n return {\n configure(generator) {\n generate = generator;\n },\n generate(componentName) {\n return generate(componentName);\n },\n reset() {\n generate = defaultGenerator;\n }\n };\n};\nconst ClassNameGenerator = createClassNameGenerator();\nexport default ClassNameGenerator;","import ClassNameGenerator from '../ClassNameGenerator';\nexport const globalStateClasses = {\n active: 'active',\n checked: 'checked',\n completed: 'completed',\n disabled: 'disabled',\n error: 'error',\n expanded: 'expanded',\n focused: 'focused',\n focusVisible: 'focusVisible',\n open: 'open',\n readOnly: 'readOnly',\n required: 'required',\n selected: 'selected'\n};\nexport default function generateUtilityClass(componentName, slot, globalStatePrefix = 'Mui') {\n const globalStateClass = globalStateClasses[slot];\n return globalStateClass ? `${globalStatePrefix}-${globalStateClass}` : `${ClassNameGenerator.generate(componentName)}-${slot}`;\n}\nexport function isGlobalState(slot) {\n return globalStateClasses[slot] !== undefined;\n}","import generateUtilityClass from '../generateUtilityClass';\nexport default function generateUtilityClasses(componentName, slots, globalStatePrefix = 'Mui') {\n const result = {};\n slots.forEach(slot => {\n result[slot] = generateUtilityClass(componentName, slot, globalStatePrefix);\n });\n return result;\n}","function clamp(val, min = Number.MIN_SAFE_INTEGER, max = Number.MAX_SAFE_INTEGER) {\n return Math.max(min, Math.min(val, max));\n}\nexport default clamp;","export default function _objectWithoutPropertiesLoose(source, excluded) {\n if (source == null) return {};\n var target = {};\n var sourceKeys = Object.keys(source);\n var key, i;\n for (i = 0; i < sourceKeys.length; i++) {\n key = sourceKeys[i];\n if (excluded.indexOf(key) >= 0) continue;\n target[key] = source[key];\n }\n return target;\n}","import _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nconst _excluded = [\"values\", \"unit\", \"step\"];\n// Sorted ASC by size. That's important.\n// It can't be configured as it's used statically for propTypes.\nexport const breakpointKeys = ['xs', 'sm', 'md', 'lg', 'xl'];\nconst sortBreakpointsValues = values => {\n const breakpointsAsArray = Object.keys(values).map(key => ({\n key,\n val: values[key]\n })) || [];\n // Sort in ascending order\n breakpointsAsArray.sort((breakpoint1, breakpoint2) => breakpoint1.val - breakpoint2.val);\n return breakpointsAsArray.reduce((acc, obj) => {\n return _extends({}, acc, {\n [obj.key]: obj.val\n });\n }, {});\n};\n\n// Keep in mind that @media is inclusive by the CSS specification.\nexport default function createBreakpoints(breakpoints) {\n const {\n // The breakpoint **start** at this value.\n // For instance with the first breakpoint xs: [xs, sm).\n values = {\n xs: 0,\n // phone\n sm: 600,\n // tablet\n md: 900,\n // small laptop\n lg: 1200,\n // desktop\n xl: 1536 // large screen\n },\n unit = 'px',\n step = 5\n } = breakpoints,\n other = _objectWithoutPropertiesLoose(breakpoints, _excluded);\n const sortedValues = sortBreakpointsValues(values);\n const keys = Object.keys(sortedValues);\n function up(key) {\n const value = typeof values[key] === 'number' ? values[key] : key;\n return `@media (min-width:${value}${unit})`;\n }\n function down(key) {\n const value = typeof values[key] === 'number' ? values[key] : key;\n return `@media (max-width:${value - step / 100}${unit})`;\n }\n function between(start, end) {\n const endIndex = keys.indexOf(end);\n return `@media (min-width:${typeof values[start] === 'number' ? values[start] : start}${unit}) and ` + `(max-width:${(endIndex !== -1 && typeof values[keys[endIndex]] === 'number' ? values[keys[endIndex]] : end) - step / 100}${unit})`;\n }\n function only(key) {\n if (keys.indexOf(key) + 1 < keys.length) {\n return between(key, keys[keys.indexOf(key) + 1]);\n }\n return up(key);\n }\n function not(key) {\n // handle first and last key separately, for better readability\n const keyIndex = keys.indexOf(key);\n if (keyIndex === 0) {\n return up(keys[1]);\n }\n if (keyIndex === keys.length - 1) {\n return down(keys[keyIndex]);\n }\n return between(key, keys[keys.indexOf(key) + 1]).replace('@media', '@media not all and');\n }\n return _extends({\n keys,\n values: sortedValues,\n up,\n down,\n between,\n only,\n not,\n unit\n }, other);\n}","const shape = {\n borderRadius: 4\n};\nexport default shape;","import PropTypes from 'prop-types';\nconst responsivePropType = process.env.NODE_ENV !== 'production' ? PropTypes.oneOfType([PropTypes.number, PropTypes.string, PropTypes.object, PropTypes.array]) : {};\nexport default responsivePropType;","import deepmerge from '@mui/utils/deepmerge';\nfunction merge(acc, item) {\n if (!item) {\n return acc;\n }\n return deepmerge(acc, item, {\n clone: false // No need to clone deep, it's way faster.\n });\n}\nexport default merge;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport PropTypes from 'prop-types';\nimport deepmerge from '@mui/utils/deepmerge';\nimport merge from './merge';\n\n// The breakpoint **start** at this value.\n// For instance with the first breakpoint xs: [xs, sm[.\nexport const values = {\n xs: 0,\n // phone\n sm: 600,\n // tablet\n md: 900,\n // small laptop\n lg: 1200,\n // desktop\n xl: 1536 // large screen\n};\nconst defaultBreakpoints = {\n // Sorted ASC by size. That's important.\n // It can't be configured as it's used statically for propTypes.\n keys: ['xs', 'sm', 'md', 'lg', 'xl'],\n up: key => `@media (min-width:${values[key]}px)`\n};\nexport function handleBreakpoints(props, propValue, styleFromPropValue) {\n const theme = props.theme || {};\n if (Array.isArray(propValue)) {\n const themeBreakpoints = theme.breakpoints || defaultBreakpoints;\n return propValue.reduce((acc, item, index) => {\n acc[themeBreakpoints.up(themeBreakpoints.keys[index])] = styleFromPropValue(propValue[index]);\n return acc;\n }, {});\n }\n if (typeof propValue === 'object') {\n const themeBreakpoints = theme.breakpoints || defaultBreakpoints;\n return Object.keys(propValue).reduce((acc, breakpoint) => {\n // key is breakpoint\n if (Object.keys(themeBreakpoints.values || values).indexOf(breakpoint) !== -1) {\n const mediaKey = themeBreakpoints.up(breakpoint);\n acc[mediaKey] = styleFromPropValue(propValue[breakpoint], breakpoint);\n } else {\n const cssKey = breakpoint;\n acc[cssKey] = propValue[cssKey];\n }\n return acc;\n }, {});\n }\n const output = styleFromPropValue(propValue);\n return output;\n}\nfunction breakpoints(styleFunction) {\n // false positive\n // eslint-disable-next-line react/function-component-definition\n const newStyleFunction = props => {\n const theme = props.theme || {};\n const base = styleFunction(props);\n const themeBreakpoints = theme.breakpoints || defaultBreakpoints;\n const extended = themeBreakpoints.keys.reduce((acc, key) => {\n if (props[key]) {\n acc = acc || {};\n acc[themeBreakpoints.up(key)] = styleFunction(_extends({\n theme\n }, props[key]));\n }\n return acc;\n }, null);\n return merge(base, extended);\n };\n newStyleFunction.propTypes = process.env.NODE_ENV !== 'production' ? _extends({}, styleFunction.propTypes, {\n xs: PropTypes.object,\n sm: PropTypes.object,\n md: PropTypes.object,\n lg: PropTypes.object,\n xl: PropTypes.object\n }) : {};\n newStyleFunction.filterProps = ['xs', 'sm', 'md', 'lg', 'xl', ...styleFunction.filterProps];\n return newStyleFunction;\n}\nexport function createEmptyBreakpointObject(breakpointsInput = {}) {\n var _breakpointsInput$key;\n const breakpointsInOrder = (_breakpointsInput$key = breakpointsInput.keys) == null ? void 0 : _breakpointsInput$key.reduce((acc, key) => {\n const breakpointStyleKey = breakpointsInput.up(key);\n acc[breakpointStyleKey] = {};\n return acc;\n }, {});\n return breakpointsInOrder || {};\n}\nexport function removeUnusedBreakpoints(breakpointKeys, style) {\n return breakpointKeys.reduce((acc, key) => {\n const breakpointOutput = acc[key];\n const isBreakpointUnused = !breakpointOutput || Object.keys(breakpointOutput).length === 0;\n if (isBreakpointUnused) {\n delete acc[key];\n }\n return acc;\n }, style);\n}\nexport function mergeBreakpointsInOrder(breakpointsInput, ...styles) {\n const emptyBreakpoints = createEmptyBreakpointObject(breakpointsInput);\n const mergedOutput = [emptyBreakpoints, ...styles].reduce((prev, next) => deepmerge(prev, next), {});\n return removeUnusedBreakpoints(Object.keys(emptyBreakpoints), mergedOutput);\n}\n\n// compute base for responsive values; e.g.,\n// [1,2,3] => {xs: true, sm: true, md: true}\n// {xs: 1, sm: 2, md: 3} => {xs: true, sm: true, md: true}\nexport function computeBreakpointsBase(breakpointValues, themeBreakpoints) {\n // fixed value\n if (typeof breakpointValues !== 'object') {\n return {};\n }\n const base = {};\n const breakpointsKeys = Object.keys(themeBreakpoints);\n if (Array.isArray(breakpointValues)) {\n breakpointsKeys.forEach((breakpoint, i) => {\n if (i < breakpointValues.length) {\n base[breakpoint] = true;\n }\n });\n } else {\n breakpointsKeys.forEach(breakpoint => {\n if (breakpointValues[breakpoint] != null) {\n base[breakpoint] = true;\n }\n });\n }\n return base;\n}\nexport function resolveBreakpointValues({\n values: breakpointValues,\n breakpoints: themeBreakpoints,\n base: customBase\n}) {\n const base = customBase || computeBreakpointsBase(breakpointValues, themeBreakpoints);\n const keys = Object.keys(base);\n if (keys.length === 0) {\n return breakpointValues;\n }\n let previous;\n return keys.reduce((acc, breakpoint, i) => {\n if (Array.isArray(breakpointValues)) {\n acc[breakpoint] = breakpointValues[i] != null ? breakpointValues[i] : breakpointValues[previous];\n previous = i;\n } else if (typeof breakpointValues === 'object') {\n acc[breakpoint] = breakpointValues[breakpoint] != null ? breakpointValues[breakpoint] : breakpointValues[previous];\n previous = breakpoint;\n } else {\n acc[breakpoint] = breakpointValues;\n }\n return acc;\n }, {});\n}\nexport default breakpoints;","import capitalize from '@mui/utils/capitalize';\nimport responsivePropType from './responsivePropType';\nimport { handleBreakpoints } from './breakpoints';\nexport function getPath(obj, path, checkVars = true) {\n if (!path || typeof path !== 'string') {\n return null;\n }\n\n // Check if CSS variables are used\n if (obj && obj.vars && checkVars) {\n const val = `vars.${path}`.split('.').reduce((acc, item) => acc && acc[item] ? acc[item] : null, obj);\n if (val != null) {\n return val;\n }\n }\n return path.split('.').reduce((acc, item) => {\n if (acc && acc[item] != null) {\n return acc[item];\n }\n return null;\n }, obj);\n}\nexport function getStyleValue(themeMapping, transform, propValueFinal, userValue = propValueFinal) {\n let value;\n if (typeof themeMapping === 'function') {\n value = themeMapping(propValueFinal);\n } else if (Array.isArray(themeMapping)) {\n value = themeMapping[propValueFinal] || userValue;\n } else {\n value = getPath(themeMapping, propValueFinal) || userValue;\n }\n if (transform) {\n value = transform(value, userValue, themeMapping);\n }\n return value;\n}\nfunction style(options) {\n const {\n prop,\n cssProperty = options.prop,\n themeKey,\n transform\n } = options;\n\n // false positive\n // eslint-disable-next-line react/function-component-definition\n const fn = props => {\n if (props[prop] == null) {\n return null;\n }\n const propValue = props[prop];\n const theme = props.theme;\n const themeMapping = getPath(theme, themeKey) || {};\n const styleFromPropValue = propValueFinal => {\n let value = getStyleValue(themeMapping, transform, propValueFinal);\n if (propValueFinal === value && typeof propValueFinal === 'string') {\n // Haven't found value\n value = getStyleValue(themeMapping, transform, `${prop}${propValueFinal === 'default' ? '' : capitalize(propValueFinal)}`, propValueFinal);\n }\n if (cssProperty === false) {\n return value;\n }\n return {\n [cssProperty]: value\n };\n };\n return handleBreakpoints(props, propValue, styleFromPropValue);\n };\n fn.propTypes = process.env.NODE_ENV !== 'production' ? {\n [prop]: responsivePropType\n } : {};\n fn.filterProps = [prop];\n return fn;\n}\nexport default style;","export default function memoize(fn) {\n const cache = {};\n return arg => {\n if (cache[arg] === undefined) {\n cache[arg] = fn(arg);\n }\n return cache[arg];\n };\n}","import responsivePropType from './responsivePropType';\nimport { handleBreakpoints } from './breakpoints';\nimport { getPath } from './style';\nimport merge from './merge';\nimport memoize from './memoize';\nconst properties = {\n m: 'margin',\n p: 'padding'\n};\nconst directions = {\n t: 'Top',\n r: 'Right',\n b: 'Bottom',\n l: 'Left',\n x: ['Left', 'Right'],\n y: ['Top', 'Bottom']\n};\nconst aliases = {\n marginX: 'mx',\n marginY: 'my',\n paddingX: 'px',\n paddingY: 'py'\n};\n\n// memoize() impact:\n// From 300,000 ops/sec\n// To 350,000 ops/sec\nconst getCssProperties = memoize(prop => {\n // It's not a shorthand notation.\n if (prop.length > 2) {\n if (aliases[prop]) {\n prop = aliases[prop];\n } else {\n return [prop];\n }\n }\n const [a, b] = prop.split('');\n const property = properties[a];\n const direction = directions[b] || '';\n return Array.isArray(direction) ? direction.map(dir => property + dir) : [property + direction];\n});\nexport const marginKeys = ['m', 'mt', 'mr', 'mb', 'ml', 'mx', 'my', 'margin', 'marginTop', 'marginRight', 'marginBottom', 'marginLeft', 'marginX', 'marginY', 'marginInline', 'marginInlineStart', 'marginInlineEnd', 'marginBlock', 'marginBlockStart', 'marginBlockEnd'];\nexport const paddingKeys = ['p', 'pt', 'pr', 'pb', 'pl', 'px', 'py', 'padding', 'paddingTop', 'paddingRight', 'paddingBottom', 'paddingLeft', 'paddingX', 'paddingY', 'paddingInline', 'paddingInlineStart', 'paddingInlineEnd', 'paddingBlock', 'paddingBlockStart', 'paddingBlockEnd'];\nconst spacingKeys = [...marginKeys, ...paddingKeys];\nexport function createUnaryUnit(theme, themeKey, defaultValue, propName) {\n var _getPath;\n const themeSpacing = (_getPath = getPath(theme, themeKey, false)) != null ? _getPath : defaultValue;\n if (typeof themeSpacing === 'number') {\n return abs => {\n if (typeof abs === 'string') {\n return abs;\n }\n if (process.env.NODE_ENV !== 'production') {\n if (typeof abs !== 'number') {\n console.error(`MUI: Expected ${propName} argument to be a number or a string, got ${abs}.`);\n }\n }\n return themeSpacing * abs;\n };\n }\n if (Array.isArray(themeSpacing)) {\n return abs => {\n if (typeof abs === 'string') {\n return abs;\n }\n if (process.env.NODE_ENV !== 'production') {\n if (!Number.isInteger(abs)) {\n console.error([`MUI: The \\`theme.${themeKey}\\` array type cannot be combined with non integer values.` + `You should either use an integer value that can be used as index, or define the \\`theme.${themeKey}\\` as a number.`].join('\\n'));\n } else if (abs > themeSpacing.length - 1) {\n console.error([`MUI: The value provided (${abs}) overflows.`, `The supported values are: ${JSON.stringify(themeSpacing)}.`, `${abs} > ${themeSpacing.length - 1}, you need to add the missing values.`].join('\\n'));\n }\n }\n return themeSpacing[abs];\n };\n }\n if (typeof themeSpacing === 'function') {\n return themeSpacing;\n }\n if (process.env.NODE_ENV !== 'production') {\n console.error([`MUI: The \\`theme.${themeKey}\\` value (${themeSpacing}) is invalid.`, 'It should be a number, an array or a function.'].join('\\n'));\n }\n return () => undefined;\n}\nexport function createUnarySpacing(theme) {\n return createUnaryUnit(theme, 'spacing', 8, 'spacing');\n}\nexport function getValue(transformer, propValue) {\n if (typeof propValue === 'string' || propValue == null) {\n return propValue;\n }\n const abs = Math.abs(propValue);\n const transformed = transformer(abs);\n if (propValue >= 0) {\n return transformed;\n }\n if (typeof transformed === 'number') {\n return -transformed;\n }\n return `-${transformed}`;\n}\nexport function getStyleFromPropValue(cssProperties, transformer) {\n return propValue => cssProperties.reduce((acc, cssProperty) => {\n acc[cssProperty] = getValue(transformer, propValue);\n return acc;\n }, {});\n}\nfunction resolveCssProperty(props, keys, prop, transformer) {\n // Using a hash computation over an array iteration could be faster, but with only 28 items,\n // it's doesn't worth the bundle size.\n if (keys.indexOf(prop) === -1) {\n return null;\n }\n const cssProperties = getCssProperties(prop);\n const styleFromPropValue = getStyleFromPropValue(cssProperties, transformer);\n const propValue = props[prop];\n return handleBreakpoints(props, propValue, styleFromPropValue);\n}\nfunction style(props, keys) {\n const transformer = createUnarySpacing(props.theme);\n return Object.keys(props).map(prop => resolveCssProperty(props, keys, prop, transformer)).reduce(merge, {});\n}\nexport function margin(props) {\n return style(props, marginKeys);\n}\nmargin.propTypes = process.env.NODE_ENV !== 'production' ? marginKeys.reduce((obj, key) => {\n obj[key] = responsivePropType;\n return obj;\n}, {}) : {};\nmargin.filterProps = marginKeys;\nexport function padding(props) {\n return style(props, paddingKeys);\n}\npadding.propTypes = process.env.NODE_ENV !== 'production' ? paddingKeys.reduce((obj, key) => {\n obj[key] = responsivePropType;\n return obj;\n}, {}) : {};\npadding.filterProps = paddingKeys;\nfunction spacing(props) {\n return style(props, spacingKeys);\n}\nspacing.propTypes = process.env.NODE_ENV !== 'production' ? spacingKeys.reduce((obj, key) => {\n obj[key] = responsivePropType;\n return obj;\n}, {}) : {};\nspacing.filterProps = spacingKeys;\nexport default spacing;","import { createUnarySpacing } from '../spacing';\n\n// The different signatures imply different meaning for their arguments that can't be expressed structurally.\n// We express the difference with variable names.\n\nexport default function createSpacing(spacingInput = 8) {\n // Already transformed.\n if (spacingInput.mui) {\n return spacingInput;\n }\n\n // Material Design layouts are visually balanced. Most measurements align to an 8dp grid, which aligns both spacing and the overall layout.\n // Smaller components, such as icons, can align to a 4dp grid.\n // https://m2.material.io/design/layout/understanding-layout.html\n const transform = createUnarySpacing({\n spacing: spacingInput\n });\n const spacing = (...argsInput) => {\n if (process.env.NODE_ENV !== 'production') {\n if (!(argsInput.length <= 4)) {\n console.error(`MUI: Too many arguments provided, expected between 0 and 4, got ${argsInput.length}`);\n }\n }\n const args = argsInput.length === 0 ? [1] : argsInput;\n return args.map(argument => {\n const output = transform(argument);\n return typeof output === 'number' ? `${output}px` : output;\n }).join(' ');\n };\n spacing.mui = true;\n return spacing;\n}","import merge from './merge';\nfunction compose(...styles) {\n const handlers = styles.reduce((acc, style) => {\n style.filterProps.forEach(prop => {\n acc[prop] = style;\n });\n return acc;\n }, {});\n\n // false positive\n // eslint-disable-next-line react/function-component-definition\n const fn = props => {\n return Object.keys(props).reduce((acc, prop) => {\n if (handlers[prop]) {\n return merge(acc, handlers[prop](props));\n }\n return acc;\n }, {});\n };\n fn.propTypes = process.env.NODE_ENV !== 'production' ? styles.reduce((acc, style) => Object.assign(acc, style.propTypes), {}) : {};\n fn.filterProps = styles.reduce((acc, style) => acc.concat(style.filterProps), []);\n return fn;\n}\nexport default compose;","import responsivePropType from './responsivePropType';\nimport style from './style';\nimport compose from './compose';\nimport { createUnaryUnit, getValue } from './spacing';\nimport { handleBreakpoints } from './breakpoints';\nexport function borderTransform(value) {\n if (typeof value !== 'number') {\n return value;\n }\n return `${value}px solid`;\n}\nfunction createBorderStyle(prop, transform) {\n return style({\n prop,\n themeKey: 'borders',\n transform\n });\n}\nexport const border = createBorderStyle('border', borderTransform);\nexport const borderTop = createBorderStyle('borderTop', borderTransform);\nexport const borderRight = createBorderStyle('borderRight', borderTransform);\nexport const borderBottom = createBorderStyle('borderBottom', borderTransform);\nexport const borderLeft = createBorderStyle('borderLeft', borderTransform);\nexport const borderColor = createBorderStyle('borderColor');\nexport const borderTopColor = createBorderStyle('borderTopColor');\nexport const borderRightColor = createBorderStyle('borderRightColor');\nexport const borderBottomColor = createBorderStyle('borderBottomColor');\nexport const borderLeftColor = createBorderStyle('borderLeftColor');\nexport const outline = createBorderStyle('outline', borderTransform);\nexport const outlineColor = createBorderStyle('outlineColor');\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const borderRadius = props => {\n if (props.borderRadius !== undefined && props.borderRadius !== null) {\n const transformer = createUnaryUnit(props.theme, 'shape.borderRadius', 4, 'borderRadius');\n const styleFromPropValue = propValue => ({\n borderRadius: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.borderRadius, styleFromPropValue);\n }\n return null;\n};\nborderRadius.propTypes = process.env.NODE_ENV !== 'production' ? {\n borderRadius: responsivePropType\n} : {};\nborderRadius.filterProps = ['borderRadius'];\nconst borders = compose(border, borderTop, borderRight, borderBottom, borderLeft, borderColor, borderTopColor, borderRightColor, borderBottomColor, borderLeftColor, borderRadius, outline, outlineColor);\nexport default borders;","import style from './style';\nimport compose from './compose';\nimport { createUnaryUnit, getValue } from './spacing';\nimport { handleBreakpoints } from './breakpoints';\nimport responsivePropType from './responsivePropType';\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const gap = props => {\n if (props.gap !== undefined && props.gap !== null) {\n const transformer = createUnaryUnit(props.theme, 'spacing', 8, 'gap');\n const styleFromPropValue = propValue => ({\n gap: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.gap, styleFromPropValue);\n }\n return null;\n};\ngap.propTypes = process.env.NODE_ENV !== 'production' ? {\n gap: responsivePropType\n} : {};\ngap.filterProps = ['gap'];\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const columnGap = props => {\n if (props.columnGap !== undefined && props.columnGap !== null) {\n const transformer = createUnaryUnit(props.theme, 'spacing', 8, 'columnGap');\n const styleFromPropValue = propValue => ({\n columnGap: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.columnGap, styleFromPropValue);\n }\n return null;\n};\ncolumnGap.propTypes = process.env.NODE_ENV !== 'production' ? {\n columnGap: responsivePropType\n} : {};\ncolumnGap.filterProps = ['columnGap'];\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const rowGap = props => {\n if (props.rowGap !== undefined && props.rowGap !== null) {\n const transformer = createUnaryUnit(props.theme, 'spacing', 8, 'rowGap');\n const styleFromPropValue = propValue => ({\n rowGap: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.rowGap, styleFromPropValue);\n }\n return null;\n};\nrowGap.propTypes = process.env.NODE_ENV !== 'production' ? {\n rowGap: responsivePropType\n} : {};\nrowGap.filterProps = ['rowGap'];\nexport const gridColumn = style({\n prop: 'gridColumn'\n});\nexport const gridRow = style({\n prop: 'gridRow'\n});\nexport const gridAutoFlow = style({\n prop: 'gridAutoFlow'\n});\nexport const gridAutoColumns = style({\n prop: 'gridAutoColumns'\n});\nexport const gridAutoRows = style({\n prop: 'gridAutoRows'\n});\nexport const gridTemplateColumns = style({\n prop: 'gridTemplateColumns'\n});\nexport const gridTemplateRows = style({\n prop: 'gridTemplateRows'\n});\nexport const gridTemplateAreas = style({\n prop: 'gridTemplateAreas'\n});\nexport const gridArea = style({\n prop: 'gridArea'\n});\nconst grid = compose(gap, columnGap, rowGap, gridColumn, gridRow, gridAutoFlow, gridAutoColumns, gridAutoRows, gridTemplateColumns, gridTemplateRows, gridTemplateAreas, gridArea);\nexport default grid;","import style from './style';\nimport compose from './compose';\nexport function paletteTransform(value, userValue) {\n if (userValue === 'grey') {\n return userValue;\n }\n return value;\n}\nexport const color = style({\n prop: 'color',\n themeKey: 'palette',\n transform: paletteTransform\n});\nexport const bgcolor = style({\n prop: 'bgcolor',\n cssProperty: 'backgroundColor',\n themeKey: 'palette',\n transform: paletteTransform\n});\nexport const backgroundColor = style({\n prop: 'backgroundColor',\n themeKey: 'palette',\n transform: paletteTransform\n});\nconst palette = compose(color, bgcolor, backgroundColor);\nexport default palette;","import style from './style';\nimport compose from './compose';\nimport { handleBreakpoints, values as breakpointsValues } from './breakpoints';\nexport function sizingTransform(value) {\n return value <= 1 && value !== 0 ? `${value * 100}%` : value;\n}\nexport const width = style({\n prop: 'width',\n transform: sizingTransform\n});\nexport const maxWidth = props => {\n if (props.maxWidth !== undefined && props.maxWidth !== null) {\n const styleFromPropValue = propValue => {\n var _props$theme, _props$theme2;\n const breakpoint = ((_props$theme = props.theme) == null || (_props$theme = _props$theme.breakpoints) == null || (_props$theme = _props$theme.values) == null ? void 0 : _props$theme[propValue]) || breakpointsValues[propValue];\n if (!breakpoint) {\n return {\n maxWidth: sizingTransform(propValue)\n };\n }\n if (((_props$theme2 = props.theme) == null || (_props$theme2 = _props$theme2.breakpoints) == null ? void 0 : _props$theme2.unit) !== 'px') {\n return {\n maxWidth: `${breakpoint}${props.theme.breakpoints.unit}`\n };\n }\n return {\n maxWidth: breakpoint\n };\n };\n return handleBreakpoints(props, props.maxWidth, styleFromPropValue);\n }\n return null;\n};\nmaxWidth.filterProps = ['maxWidth'];\nexport const minWidth = style({\n prop: 'minWidth',\n transform: sizingTransform\n});\nexport const height = style({\n prop: 'height',\n transform: sizingTransform\n});\nexport const maxHeight = style({\n prop: 'maxHeight',\n transform: sizingTransform\n});\nexport const minHeight = style({\n prop: 'minHeight',\n transform: sizingTransform\n});\nexport const sizeWidth = style({\n prop: 'size',\n cssProperty: 'width',\n transform: sizingTransform\n});\nexport const sizeHeight = style({\n prop: 'size',\n cssProperty: 'height',\n transform: sizingTransform\n});\nexport const boxSizing = style({\n prop: 'boxSizing'\n});\nconst sizing = compose(width, maxWidth, minWidth, height, maxHeight, minHeight, boxSizing);\nexport default sizing;","import { padding, margin } from '../spacing';\nimport { borderRadius, borderTransform } from '../borders';\nimport { gap, rowGap, columnGap } from '../cssGrid';\nimport { paletteTransform } from '../palette';\nimport { maxWidth, sizingTransform } from '../sizing';\nconst defaultSxConfig = {\n // borders\n border: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderTop: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderRight: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderBottom: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderLeft: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderColor: {\n themeKey: 'palette'\n },\n borderTopColor: {\n themeKey: 'palette'\n },\n borderRightColor: {\n themeKey: 'palette'\n },\n borderBottomColor: {\n themeKey: 'palette'\n },\n borderLeftColor: {\n themeKey: 'palette'\n },\n outline: {\n themeKey: 'borders',\n transform: borderTransform\n },\n outlineColor: {\n themeKey: 'palette'\n },\n borderRadius: {\n themeKey: 'shape.borderRadius',\n style: borderRadius\n },\n // palette\n color: {\n themeKey: 'palette',\n transform: paletteTransform\n },\n bgcolor: {\n themeKey: 'palette',\n cssProperty: 'backgroundColor',\n transform: paletteTransform\n },\n backgroundColor: {\n themeKey: 'palette',\n transform: paletteTransform\n },\n // spacing\n p: {\n style: padding\n },\n pt: {\n style: padding\n },\n pr: {\n style: padding\n },\n pb: {\n style: padding\n },\n pl: {\n style: padding\n },\n px: {\n style: padding\n },\n py: {\n style: padding\n },\n padding: {\n style: padding\n },\n paddingTop: {\n style: padding\n },\n paddingRight: {\n style: padding\n },\n paddingBottom: {\n style: padding\n },\n paddingLeft: {\n style: padding\n },\n paddingX: {\n style: padding\n },\n paddingY: {\n style: padding\n },\n paddingInline: {\n style: padding\n },\n paddingInlineStart: {\n style: padding\n },\n paddingInlineEnd: {\n style: padding\n },\n paddingBlock: {\n style: padding\n },\n paddingBlockStart: {\n style: padding\n },\n paddingBlockEnd: {\n style: padding\n },\n m: {\n style: margin\n },\n mt: {\n style: margin\n },\n mr: {\n style: margin\n },\n mb: {\n style: margin\n },\n ml: {\n style: margin\n },\n mx: {\n style: margin\n },\n my: {\n style: margin\n },\n margin: {\n style: margin\n },\n marginTop: {\n style: margin\n },\n marginRight: {\n style: margin\n },\n marginBottom: {\n style: margin\n },\n marginLeft: {\n style: margin\n },\n marginX: {\n style: margin\n },\n marginY: {\n style: margin\n },\n marginInline: {\n style: margin\n },\n marginInlineStart: {\n style: margin\n },\n marginInlineEnd: {\n style: margin\n },\n marginBlock: {\n style: margin\n },\n marginBlockStart: {\n style: margin\n },\n marginBlockEnd: {\n style: margin\n },\n // display\n displayPrint: {\n cssProperty: false,\n transform: value => ({\n '@media print': {\n display: value\n }\n })\n },\n display: {},\n overflow: {},\n textOverflow: {},\n visibility: {},\n whiteSpace: {},\n // flexbox\n flexBasis: {},\n flexDirection: {},\n flexWrap: {},\n justifyContent: {},\n alignItems: {},\n alignContent: {},\n order: {},\n flex: {},\n flexGrow: {},\n flexShrink: {},\n alignSelf: {},\n justifyItems: {},\n justifySelf: {},\n // grid\n gap: {\n style: gap\n },\n rowGap: {\n style: rowGap\n },\n columnGap: {\n style: columnGap\n },\n gridColumn: {},\n gridRow: {},\n gridAutoFlow: {},\n gridAutoColumns: {},\n gridAutoRows: {},\n gridTemplateColumns: {},\n gridTemplateRows: {},\n gridTemplateAreas: {},\n gridArea: {},\n // positions\n position: {},\n zIndex: {\n themeKey: 'zIndex'\n },\n top: {},\n right: {},\n bottom: {},\n left: {},\n // shadows\n boxShadow: {\n themeKey: 'shadows'\n },\n // sizing\n width: {\n transform: sizingTransform\n },\n maxWidth: {\n style: maxWidth\n },\n minWidth: {\n transform: sizingTransform\n },\n height: {\n transform: sizingTransform\n },\n maxHeight: {\n transform: sizingTransform\n },\n minHeight: {\n transform: sizingTransform\n },\n boxSizing: {},\n // typography\n fontFamily: {\n themeKey: 'typography'\n },\n fontSize: {\n themeKey: 'typography'\n },\n fontStyle: {\n themeKey: 'typography'\n },\n fontWeight: {\n themeKey: 'typography'\n },\n letterSpacing: {},\n textTransform: {},\n lineHeight: {},\n textAlign: {},\n typography: {\n cssProperty: false,\n themeKey: 'typography'\n }\n};\nexport default defaultSxConfig;","import capitalize from '@mui/utils/capitalize';\nimport merge from '../merge';\nimport { getPath, getStyleValue as getValue } from '../style';\nimport { handleBreakpoints, createEmptyBreakpointObject, removeUnusedBreakpoints } from '../breakpoints';\nimport defaultSxConfig from './defaultSxConfig';\nfunction objectsHaveSameKeys(...objects) {\n const allKeys = objects.reduce((keys, object) => keys.concat(Object.keys(object)), []);\n const union = new Set(allKeys);\n return objects.every(object => union.size === Object.keys(object).length);\n}\nfunction callIfFn(maybeFn, arg) {\n return typeof maybeFn === 'function' ? maybeFn(arg) : maybeFn;\n}\n\n// eslint-disable-next-line @typescript-eslint/naming-convention\nexport function unstable_createStyleFunctionSx() {\n function getThemeValue(prop, val, theme, config) {\n const props = {\n [prop]: val,\n theme\n };\n const options = config[prop];\n if (!options) {\n return {\n [prop]: val\n };\n }\n const {\n cssProperty = prop,\n themeKey,\n transform,\n style\n } = options;\n if (val == null) {\n return null;\n }\n\n // TODO v6: remove, see https://github.com/mui/material-ui/pull/38123\n if (themeKey === 'typography' && val === 'inherit') {\n return {\n [prop]: val\n };\n }\n const themeMapping = getPath(theme, themeKey) || {};\n if (style) {\n return style(props);\n }\n const styleFromPropValue = propValueFinal => {\n let value = getValue(themeMapping, transform, propValueFinal);\n if (propValueFinal === value && typeof propValueFinal === 'string') {\n // Haven't found value\n value = getValue(themeMapping, transform, `${prop}${propValueFinal === 'default' ? '' : capitalize(propValueFinal)}`, propValueFinal);\n }\n if (cssProperty === false) {\n return value;\n }\n return {\n [cssProperty]: value\n };\n };\n return handleBreakpoints(props, val, styleFromPropValue);\n }\n function styleFunctionSx(props) {\n var _theme$unstable_sxCon;\n const {\n sx,\n theme = {}\n } = props || {};\n if (!sx) {\n return null; // Emotion & styled-components will neglect null\n }\n const config = (_theme$unstable_sxCon = theme.unstable_sxConfig) != null ? _theme$unstable_sxCon : defaultSxConfig;\n\n /*\n * Receive `sxInput` as object or callback\n * and then recursively check keys & values to create media query object styles.\n * (the result will be used in `styled`)\n */\n function traverse(sxInput) {\n let sxObject = sxInput;\n if (typeof sxInput === 'function') {\n sxObject = sxInput(theme);\n } else if (typeof sxInput !== 'object') {\n // value\n return sxInput;\n }\n if (!sxObject) {\n return null;\n }\n const emptyBreakpoints = createEmptyBreakpointObject(theme.breakpoints);\n const breakpointsKeys = Object.keys(emptyBreakpoints);\n let css = emptyBreakpoints;\n Object.keys(sxObject).forEach(styleKey => {\n const value = callIfFn(sxObject[styleKey], theme);\n if (value !== null && value !== undefined) {\n if (typeof value === 'object') {\n if (config[styleKey]) {\n css = merge(css, getThemeValue(styleKey, value, theme, config));\n } else {\n const breakpointsValues = handleBreakpoints({\n theme\n }, value, x => ({\n [styleKey]: x\n }));\n if (objectsHaveSameKeys(breakpointsValues, value)) {\n css[styleKey] = styleFunctionSx({\n sx: value,\n theme\n });\n } else {\n css = merge(css, breakpointsValues);\n }\n }\n } else {\n css = merge(css, getThemeValue(styleKey, value, theme, config));\n }\n }\n });\n return removeUnusedBreakpoints(breakpointsKeys, css);\n }\n return Array.isArray(sx) ? sx.map(traverse) : traverse(sx);\n }\n return styleFunctionSx;\n}\nconst styleFunctionSx = unstable_createStyleFunctionSx();\nstyleFunctionSx.filterProps = ['sx'];\nexport default styleFunctionSx;","/**\n * A universal utility to style components with multiple color modes. Always use it from the theme object.\n * It works with:\n * - [Basic theme](https://mui.com/material-ui/customization/dark-mode/)\n * - [CSS theme variables](https://mui.com/material-ui/experimental-api/css-theme-variables/overview/)\n * - Zero-runtime engine\n *\n * Tips: Use an array over object spread and place `theme.applyStyles()` last.\n *\n * ✅ [{ background: '#e5e5e5' }, theme.applyStyles('dark', { background: '#1c1c1c' })]\n *\n * 🚫 { background: '#e5e5e5', ...theme.applyStyles('dark', { background: '#1c1c1c' })}\n *\n * @example\n * 1. using with `styled`:\n * ```jsx\n * const Component = styled('div')(({ theme }) => [\n * { background: '#e5e5e5' },\n * theme.applyStyles('dark', {\n * background: '#1c1c1c',\n * color: '#fff',\n * }),\n * ]);\n * ```\n *\n * @example\n * 2. using with `sx` prop:\n * ```jsx\n * [\n * { background: '#e5e5e5' },\n * theme.applyStyles('dark', {\n * background: '#1c1c1c',\n * color: '#fff',\n * }),\n * ]}\n * />\n * ```\n *\n * @example\n * 3. theming a component:\n * ```jsx\n * extendTheme({\n * components: {\n * MuiButton: {\n * styleOverrides: {\n * root: ({ theme }) => [\n * { background: '#e5e5e5' },\n * theme.applyStyles('dark', {\n * background: '#1c1c1c',\n * color: '#fff',\n * }),\n * ],\n * },\n * }\n * }\n * })\n *```\n */\nexport default function applyStyles(key, styles) {\n // @ts-expect-error this is 'any' type\n const theme = this;\n if (theme.vars && typeof theme.getColorSchemeSelector === 'function') {\n // If CssVarsProvider is used as a provider,\n // returns '* :where([data-mui-color-scheme=\"light|dark\"]) &'\n const selector = theme.getColorSchemeSelector(key).replace(/(\\[[^\\]]+\\])/, '*:where($1)');\n return {\n [selector]: styles\n };\n }\n if (theme.palette.mode === key) {\n return styles;\n }\n return {};\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"breakpoints\", \"palette\", \"spacing\", \"shape\"];\nimport deepmerge from '@mui/utils/deepmerge';\nimport createBreakpoints from './createBreakpoints';\nimport shape from './shape';\nimport createSpacing from './createSpacing';\nimport styleFunctionSx from '../styleFunctionSx/styleFunctionSx';\nimport defaultSxConfig from '../styleFunctionSx/defaultSxConfig';\nimport applyStyles from './applyStyles';\nfunction createTheme(options = {}, ...args) {\n const {\n breakpoints: breakpointsInput = {},\n palette: paletteInput = {},\n spacing: spacingInput,\n shape: shapeInput = {}\n } = options,\n other = _objectWithoutPropertiesLoose(options, _excluded);\n const breakpoints = createBreakpoints(breakpointsInput);\n const spacing = createSpacing(spacingInput);\n let muiTheme = deepmerge({\n breakpoints,\n direction: 'ltr',\n components: {},\n // Inject component definitions.\n palette: _extends({\n mode: 'light'\n }, paletteInput),\n spacing,\n shape: _extends({}, shape, shapeInput)\n }, other);\n muiTheme.applyStyles = applyStyles;\n muiTheme = args.reduce((acc, argument) => deepmerge(acc, argument), muiTheme);\n muiTheme.unstable_sxConfig = _extends({}, defaultSxConfig, other == null ? void 0 : other.unstable_sxConfig);\n muiTheme.unstable_sx = function sx(props) {\n return styleFunctionSx({\n sx: props,\n theme: this\n });\n };\n return muiTheme;\n}\nexport default createTheme;","'use client';\n\nimport * as React from 'react';\nimport { ThemeContext } from '@mui/styled-engine';\nfunction isObjectEmpty(obj) {\n return Object.keys(obj).length === 0;\n}\nfunction useTheme(defaultTheme = null) {\n const contextTheme = React.useContext(ThemeContext);\n return !contextTheme || isObjectEmpty(contextTheme) ? defaultTheme : contextTheme;\n}\nexport default useTheme;","'use client';\n\nimport createTheme from './createTheme';\nimport useThemeWithoutDefault from './useThemeWithoutDefault';\nexport const systemDefaultTheme = createTheme();\nfunction useTheme(defaultTheme = systemDefaultTheme) {\n return useThemeWithoutDefault(defaultTheme);\n}\nexport default useTheme;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"ownerState\"],\n _excluded2 = [\"variants\"],\n _excluded3 = [\"name\", \"slot\", \"skipVariantsResolver\", \"skipSx\", \"overridesResolver\"];\n/* eslint-disable no-underscore-dangle */\nimport styledEngineStyled, { internal_processStyles as processStyles } from '@mui/styled-engine';\nimport { isPlainObject } from '@mui/utils/deepmerge';\nimport capitalize from '@mui/utils/capitalize';\nimport getDisplayName from '@mui/utils/getDisplayName';\nimport createTheme from './createTheme';\nimport styleFunctionSx from './styleFunctionSx';\nfunction isEmpty(obj) {\n return Object.keys(obj).length === 0;\n}\n\n// https://github.com/emotion-js/emotion/blob/26ded6109fcd8ca9875cc2ce4564fee678a3f3c5/packages/styled/src/utils.js#L40\nfunction isStringTag(tag) {\n return typeof tag === 'string' &&\n // 96 is one less than the char code\n // for \"a\" so this is checking that\n // it's a lowercase character\n tag.charCodeAt(0) > 96;\n}\n\n// Update /system/styled/#api in case if this changes\nexport function shouldForwardProp(prop) {\n return prop !== 'ownerState' && prop !== 'theme' && prop !== 'sx' && prop !== 'as';\n}\nexport const systemDefaultTheme = createTheme();\nconst lowercaseFirstLetter = string => {\n if (!string) {\n return string;\n }\n return string.charAt(0).toLowerCase() + string.slice(1);\n};\nfunction resolveTheme({\n defaultTheme,\n theme,\n themeId\n}) {\n return isEmpty(theme) ? defaultTheme : theme[themeId] || theme;\n}\nfunction defaultOverridesResolver(slot) {\n if (!slot) {\n return null;\n }\n return (props, styles) => styles[slot];\n}\nfunction processStyleArg(callableStyle, _ref) {\n let {\n ownerState\n } = _ref,\n props = _objectWithoutPropertiesLoose(_ref, _excluded);\n const resolvedStylesArg = typeof callableStyle === 'function' ? callableStyle(_extends({\n ownerState\n }, props)) : callableStyle;\n if (Array.isArray(resolvedStylesArg)) {\n return resolvedStylesArg.flatMap(resolvedStyle => processStyleArg(resolvedStyle, _extends({\n ownerState\n }, props)));\n }\n if (!!resolvedStylesArg && typeof resolvedStylesArg === 'object' && Array.isArray(resolvedStylesArg.variants)) {\n const {\n variants = []\n } = resolvedStylesArg,\n otherStyles = _objectWithoutPropertiesLoose(resolvedStylesArg, _excluded2);\n let result = otherStyles;\n variants.forEach(variant => {\n let isMatch = true;\n if (typeof variant.props === 'function') {\n isMatch = variant.props(_extends({\n ownerState\n }, props, ownerState));\n } else {\n Object.keys(variant.props).forEach(key => {\n if ((ownerState == null ? void 0 : ownerState[key]) !== variant.props[key] && props[key] !== variant.props[key]) {\n isMatch = false;\n }\n });\n }\n if (isMatch) {\n if (!Array.isArray(result)) {\n result = [result];\n }\n result.push(typeof variant.style === 'function' ? variant.style(_extends({\n ownerState\n }, props, ownerState)) : variant.style);\n }\n });\n return result;\n }\n return resolvedStylesArg;\n}\nexport default function createStyled(input = {}) {\n const {\n themeId,\n defaultTheme = systemDefaultTheme,\n rootShouldForwardProp = shouldForwardProp,\n slotShouldForwardProp = shouldForwardProp\n } = input;\n const systemSx = props => {\n return styleFunctionSx(_extends({}, props, {\n theme: resolveTheme(_extends({}, props, {\n defaultTheme,\n themeId\n }))\n }));\n };\n systemSx.__mui_systemSx = true;\n return (tag, inputOptions = {}) => {\n // Filter out the `sx` style function from the previous styled component to prevent unnecessary styles generated by the composite components.\n processStyles(tag, styles => styles.filter(style => !(style != null && style.__mui_systemSx)));\n const {\n name: componentName,\n slot: componentSlot,\n skipVariantsResolver: inputSkipVariantsResolver,\n skipSx: inputSkipSx,\n // TODO v6: remove `lowercaseFirstLetter()` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n overridesResolver = defaultOverridesResolver(lowercaseFirstLetter(componentSlot))\n } = inputOptions,\n options = _objectWithoutPropertiesLoose(inputOptions, _excluded3);\n\n // if skipVariantsResolver option is defined, take the value, otherwise, true for root and false for other slots.\n const skipVariantsResolver = inputSkipVariantsResolver !== undefined ? inputSkipVariantsResolver :\n // TODO v6: remove `Root` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n componentSlot && componentSlot !== 'Root' && componentSlot !== 'root' || false;\n const skipSx = inputSkipSx || false;\n let label;\n if (process.env.NODE_ENV !== 'production') {\n if (componentName) {\n // TODO v6: remove `lowercaseFirstLetter()` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n label = `${componentName}-${lowercaseFirstLetter(componentSlot || 'Root')}`;\n }\n }\n let shouldForwardPropOption = shouldForwardProp;\n\n // TODO v6: remove `Root` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n if (componentSlot === 'Root' || componentSlot === 'root') {\n shouldForwardPropOption = rootShouldForwardProp;\n } else if (componentSlot) {\n // any other slot specified\n shouldForwardPropOption = slotShouldForwardProp;\n } else if (isStringTag(tag)) {\n // for string (html) tag, preserve the behavior in emotion & styled-components.\n shouldForwardPropOption = undefined;\n }\n const defaultStyledResolver = styledEngineStyled(tag, _extends({\n shouldForwardProp: shouldForwardPropOption,\n label\n }, options));\n const transformStyleArg = stylesArg => {\n // On the server Emotion doesn't use React.forwardRef for creating components, so the created\n // component stays as a function. This condition makes sure that we do not interpolate functions\n // which are basically components used as a selectors.\n if (typeof stylesArg === 'function' && stylesArg.__emotion_real !== stylesArg || isPlainObject(stylesArg)) {\n return props => processStyleArg(stylesArg, _extends({}, props, {\n theme: resolveTheme({\n theme: props.theme,\n defaultTheme,\n themeId\n })\n }));\n }\n return stylesArg;\n };\n const muiStyledResolver = (styleArg, ...expressions) => {\n let transformedStyleArg = transformStyleArg(styleArg);\n const expressionsWithDefaultTheme = expressions ? expressions.map(transformStyleArg) : [];\n if (componentName && overridesResolver) {\n expressionsWithDefaultTheme.push(props => {\n const theme = resolveTheme(_extends({}, props, {\n defaultTheme,\n themeId\n }));\n if (!theme.components || !theme.components[componentName] || !theme.components[componentName].styleOverrides) {\n return null;\n }\n const styleOverrides = theme.components[componentName].styleOverrides;\n const resolvedStyleOverrides = {};\n // TODO: v7 remove iteration and use `resolveStyleArg(styleOverrides[slot])` directly\n Object.entries(styleOverrides).forEach(([slotKey, slotStyle]) => {\n resolvedStyleOverrides[slotKey] = processStyleArg(slotStyle, _extends({}, props, {\n theme\n }));\n });\n return overridesResolver(props, resolvedStyleOverrides);\n });\n }\n if (componentName && !skipVariantsResolver) {\n expressionsWithDefaultTheme.push(props => {\n var _theme$components;\n const theme = resolveTheme(_extends({}, props, {\n defaultTheme,\n themeId\n }));\n const themeVariants = theme == null || (_theme$components = theme.components) == null || (_theme$components = _theme$components[componentName]) == null ? void 0 : _theme$components.variants;\n return processStyleArg({\n variants: themeVariants\n }, _extends({}, props, {\n theme\n }));\n });\n }\n if (!skipSx) {\n expressionsWithDefaultTheme.push(systemSx);\n }\n const numOfCustomFnsApplied = expressionsWithDefaultTheme.length - expressions.length;\n if (Array.isArray(styleArg) && numOfCustomFnsApplied > 0) {\n const placeholders = new Array(numOfCustomFnsApplied).fill('');\n // If the type is array, than we need to add placeholders in the template for the overrides, variants and the sx styles.\n transformedStyleArg = [...styleArg, ...placeholders];\n transformedStyleArg.raw = [...styleArg.raw, ...placeholders];\n }\n const Component = defaultStyledResolver(transformedStyleArg, ...expressionsWithDefaultTheme);\n if (process.env.NODE_ENV !== 'production') {\n let displayName;\n if (componentName) {\n displayName = `${componentName}${capitalize(componentSlot || '')}`;\n }\n if (displayName === undefined) {\n displayName = `Styled(${getDisplayName(tag)})`;\n }\n Component.displayName = displayName;\n }\n if (tag.muiName) {\n Component.muiName = tag.muiName;\n }\n return Component;\n };\n if (defaultStyledResolver.withConfig) {\n muiStyledResolver.withConfig = defaultStyledResolver.withConfig;\n }\n return muiStyledResolver;\n };\n}","import resolveProps from '@mui/utils/resolveProps';\nexport default function getThemeProps(params) {\n const {\n theme,\n name,\n props\n } = params;\n if (!theme || !theme.components || !theme.components[name] || !theme.components[name].defaultProps) {\n return props;\n }\n return resolveProps(theme.components[name].defaultProps, props);\n}","'use client';\n\nimport getThemeProps from './getThemeProps';\nimport useTheme from '../useTheme';\nexport default function useThemeProps({\n props,\n name,\n defaultTheme,\n themeId\n}) {\n let theme = useTheme(defaultTheme);\n if (themeId) {\n theme = theme[themeId] || theme;\n }\n const mergedProps = getThemeProps({\n theme,\n name,\n props\n });\n return mergedProps;\n}","import _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\n/* eslint-disable @typescript-eslint/naming-convention */\nimport clamp from '@mui/utils/clamp';\n/**\n * Returns a number whose value is limited to the given range.\n * @param {number} value The value to be clamped\n * @param {number} min The lower boundary of the output range\n * @param {number} max The upper boundary of the output range\n * @returns {number} A number in the range [min, max]\n */\nfunction clampWrapper(value, min = 0, max = 1) {\n if (process.env.NODE_ENV !== 'production') {\n if (value < min || value > max) {\n console.error(`MUI: The value provided ${value} is out of range [${min}, ${max}].`);\n }\n }\n return clamp(value, min, max);\n}\n\n/**\n * Converts a color from CSS hex format to CSS rgb format.\n * @param {string} color - Hex color, i.e. #nnn or #nnnnnn\n * @returns {string} A CSS rgb color string\n */\nexport function hexToRgb(color) {\n color = color.slice(1);\n const re = new RegExp(`.{1,${color.length >= 6 ? 2 : 1}}`, 'g');\n let colors = color.match(re);\n if (colors && colors[0].length === 1) {\n colors = colors.map(n => n + n);\n }\n return colors ? `rgb${colors.length === 4 ? 'a' : ''}(${colors.map((n, index) => {\n return index < 3 ? parseInt(n, 16) : Math.round(parseInt(n, 16) / 255 * 1000) / 1000;\n }).join(', ')})` : '';\n}\nfunction intToHex(int) {\n const hex = int.toString(16);\n return hex.length === 1 ? `0${hex}` : hex;\n}\n\n/**\n * Returns an object with the type and values of a color.\n *\n * Note: Does not support rgb % values.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @returns {object} - A MUI color object: {type: string, values: number[]}\n */\nexport function decomposeColor(color) {\n // Idempotent\n if (color.type) {\n return color;\n }\n if (color.charAt(0) === '#') {\n return decomposeColor(hexToRgb(color));\n }\n const marker = color.indexOf('(');\n const type = color.substring(0, marker);\n if (['rgb', 'rgba', 'hsl', 'hsla', 'color'].indexOf(type) === -1) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: Unsupported \\`${color}\\` color.\nThe following formats are supported: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color().` : _formatMuiErrorMessage(9, color));\n }\n let values = color.substring(marker + 1, color.length - 1);\n let colorSpace;\n if (type === 'color') {\n values = values.split(' ');\n colorSpace = values.shift();\n if (values.length === 4 && values[3].charAt(0) === '/') {\n values[3] = values[3].slice(1);\n }\n if (['srgb', 'display-p3', 'a98-rgb', 'prophoto-rgb', 'rec-2020'].indexOf(colorSpace) === -1) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: unsupported \\`${colorSpace}\\` color space.\nThe following color spaces are supported: srgb, display-p3, a98-rgb, prophoto-rgb, rec-2020.` : _formatMuiErrorMessage(10, colorSpace));\n }\n } else {\n values = values.split(',');\n }\n values = values.map(value => parseFloat(value));\n return {\n type,\n values,\n colorSpace\n };\n}\n\n/**\n * Returns a channel created from the input color.\n *\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @returns {string} - The channel for the color, that can be used in rgba or hsla colors\n */\nexport const colorChannel = color => {\n const decomposedColor = decomposeColor(color);\n return decomposedColor.values.slice(0, 3).map((val, idx) => decomposedColor.type.indexOf('hsl') !== -1 && idx !== 0 ? `${val}%` : val).join(' ');\n};\nexport const private_safeColorChannel = (color, warning) => {\n try {\n return colorChannel(color);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n};\n\n/**\n * Converts a color object with type and values to a string.\n * @param {object} color - Decomposed color\n * @param {string} color.type - One of: 'rgb', 'rgba', 'hsl', 'hsla', 'color'\n * @param {array} color.values - [n,n,n] or [n,n,n,n]\n * @returns {string} A CSS color string\n */\nexport function recomposeColor(color) {\n const {\n type,\n colorSpace\n } = color;\n let {\n values\n } = color;\n if (type.indexOf('rgb') !== -1) {\n // Only convert the first 3 values to int (i.e. not alpha)\n values = values.map((n, i) => i < 3 ? parseInt(n, 10) : n);\n } else if (type.indexOf('hsl') !== -1) {\n values[1] = `${values[1]}%`;\n values[2] = `${values[2]}%`;\n }\n if (type.indexOf('color') !== -1) {\n values = `${colorSpace} ${values.join(' ')}`;\n } else {\n values = `${values.join(', ')}`;\n }\n return `${type}(${values})`;\n}\n\n/**\n * Converts a color from CSS rgb format to CSS hex format.\n * @param {string} color - RGB color, i.e. rgb(n, n, n)\n * @returns {string} A CSS rgb color string, i.e. #nnnnnn\n */\nexport function rgbToHex(color) {\n // Idempotent\n if (color.indexOf('#') === 0) {\n return color;\n }\n const {\n values\n } = decomposeColor(color);\n return `#${values.map((n, i) => intToHex(i === 3 ? Math.round(255 * n) : n)).join('')}`;\n}\n\n/**\n * Converts a color from hsl format to rgb format.\n * @param {string} color - HSL color values\n * @returns {string} rgb color values\n */\nexport function hslToRgb(color) {\n color = decomposeColor(color);\n const {\n values\n } = color;\n const h = values[0];\n const s = values[1] / 100;\n const l = values[2] / 100;\n const a = s * Math.min(l, 1 - l);\n const f = (n, k = (n + h / 30) % 12) => l - a * Math.max(Math.min(k - 3, 9 - k, 1), -1);\n let type = 'rgb';\n const rgb = [Math.round(f(0) * 255), Math.round(f(8) * 255), Math.round(f(4) * 255)];\n if (color.type === 'hsla') {\n type += 'a';\n rgb.push(values[3]);\n }\n return recomposeColor({\n type,\n values: rgb\n });\n}\n/**\n * The relative brightness of any point in a color space,\n * normalized to 0 for darkest black and 1 for lightest white.\n *\n * Formula: https://www.w3.org/TR/WCAG20-TECHS/G17.html#G17-tests\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @returns {number} The relative brightness of the color in the range 0 - 1\n */\nexport function getLuminance(color) {\n color = decomposeColor(color);\n let rgb = color.type === 'hsl' || color.type === 'hsla' ? decomposeColor(hslToRgb(color)).values : color.values;\n rgb = rgb.map(val => {\n if (color.type !== 'color') {\n val /= 255; // normalized\n }\n return val <= 0.03928 ? val / 12.92 : ((val + 0.055) / 1.055) ** 2.4;\n });\n\n // Truncate at 3 digits\n return Number((0.2126 * rgb[0] + 0.7152 * rgb[1] + 0.0722 * rgb[2]).toFixed(3));\n}\n\n/**\n * Calculates the contrast ratio between two colors.\n *\n * Formula: https://www.w3.org/TR/WCAG20-TECHS/G17.html#G17-tests\n * @param {string} foreground - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla()\n * @param {string} background - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla()\n * @returns {number} A contrast ratio value in the range 0 - 21.\n */\nexport function getContrastRatio(foreground, background) {\n const lumA = getLuminance(foreground);\n const lumB = getLuminance(background);\n return (Math.max(lumA, lumB) + 0.05) / (Math.min(lumA, lumB) + 0.05);\n}\n\n/**\n * Sets the absolute transparency of a color.\n * Any existing alpha values are overwritten.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} value - value to set the alpha channel to in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function alpha(color, value) {\n color = decomposeColor(color);\n value = clampWrapper(value);\n if (color.type === 'rgb' || color.type === 'hsl') {\n color.type += 'a';\n }\n if (color.type === 'color') {\n color.values[3] = `/${value}`;\n } else {\n color.values[3] = value;\n }\n return recomposeColor(color);\n}\nexport function private_safeAlpha(color, value, warning) {\n try {\n return alpha(color, value);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Darkens a color.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} coefficient - multiplier in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function darken(color, coefficient) {\n color = decomposeColor(color);\n coefficient = clampWrapper(coefficient);\n if (color.type.indexOf('hsl') !== -1) {\n color.values[2] *= 1 - coefficient;\n } else if (color.type.indexOf('rgb') !== -1 || color.type.indexOf('color') !== -1) {\n for (let i = 0; i < 3; i += 1) {\n color.values[i] *= 1 - coefficient;\n }\n }\n return recomposeColor(color);\n}\nexport function private_safeDarken(color, coefficient, warning) {\n try {\n return darken(color, coefficient);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Lightens a color.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} coefficient - multiplier in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function lighten(color, coefficient) {\n color = decomposeColor(color);\n coefficient = clampWrapper(coefficient);\n if (color.type.indexOf('hsl') !== -1) {\n color.values[2] += (100 - color.values[2]) * coefficient;\n } else if (color.type.indexOf('rgb') !== -1) {\n for (let i = 0; i < 3; i += 1) {\n color.values[i] += (255 - color.values[i]) * coefficient;\n }\n } else if (color.type.indexOf('color') !== -1) {\n for (let i = 0; i < 3; i += 1) {\n color.values[i] += (1 - color.values[i]) * coefficient;\n }\n }\n return recomposeColor(color);\n}\nexport function private_safeLighten(color, coefficient, warning) {\n try {\n return lighten(color, coefficient);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Darken or lighten a color, depending on its luminance.\n * Light colors are darkened, dark colors are lightened.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} coefficient=0.15 - multiplier in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function emphasize(color, coefficient = 0.15) {\n return getLuminance(color) > 0.5 ? darken(color, coefficient) : lighten(color, coefficient);\n}\nexport function private_safeEmphasize(color, coefficient, warning) {\n try {\n return emphasize(color, coefficient);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Blend a transparent overlay color with a background color, resulting in a single\n * RGB color.\n * @param {string} background - CSS color\n * @param {string} overlay - CSS color\n * @param {number} opacity - Opacity multiplier in the range 0 - 1\n * @param {number} [gamma=1.0] - Gamma correction factor. For gamma-correct blending, 2.2 is usual.\n */\nexport function blend(background, overlay, opacity, gamma = 1.0) {\n const blendChannel = (b, o) => Math.round((b ** (1 / gamma) * (1 - opacity) + o ** (1 / gamma) * opacity) ** gamma);\n const backgroundColor = decomposeColor(background);\n const overlayColor = decomposeColor(overlay);\n const rgb = [blendChannel(backgroundColor.values[0], overlayColor.values[0]), blendChannel(backgroundColor.values[1], overlayColor.values[1]), blendChannel(backgroundColor.values[2], overlayColor.values[2])];\n return recomposeColor({\n type: 'rgb',\n values: rgb\n });\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nexport default function createMixins(breakpoints, mixins) {\n return _extends({\n toolbar: {\n minHeight: 56,\n [breakpoints.up('xs')]: {\n '@media (orientation: landscape)': {\n minHeight: 48\n }\n },\n [breakpoints.up('sm')]: {\n minHeight: 64\n }\n }\n }, mixins);\n}","const common = {\n black: '#000',\n white: '#fff'\n};\nexport default common;","const grey = {\n 50: '#fafafa',\n 100: '#f5f5f5',\n 200: '#eeeeee',\n 300: '#e0e0e0',\n 400: '#bdbdbd',\n 500: '#9e9e9e',\n 600: '#757575',\n 700: '#616161',\n 800: '#424242',\n 900: '#212121',\n A100: '#f5f5f5',\n A200: '#eeeeee',\n A400: '#bdbdbd',\n A700: '#616161'\n};\nexport default grey;","const purple = {\n 50: '#f3e5f5',\n 100: '#e1bee7',\n 200: '#ce93d8',\n 300: '#ba68c8',\n 400: '#ab47bc',\n 500: '#9c27b0',\n 600: '#8e24aa',\n 700: '#7b1fa2',\n 800: '#6a1b9a',\n 900: '#4a148c',\n A100: '#ea80fc',\n A200: '#e040fb',\n A400: '#d500f9',\n A700: '#aa00ff'\n};\nexport default purple;","const red = {\n 50: '#ffebee',\n 100: '#ffcdd2',\n 200: '#ef9a9a',\n 300: '#e57373',\n 400: '#ef5350',\n 500: '#f44336',\n 600: '#e53935',\n 700: '#d32f2f',\n 800: '#c62828',\n 900: '#b71c1c',\n A100: '#ff8a80',\n A200: '#ff5252',\n A400: '#ff1744',\n A700: '#d50000'\n};\nexport default red;","const orange = {\n 50: '#fff3e0',\n 100: '#ffe0b2',\n 200: '#ffcc80',\n 300: '#ffb74d',\n 400: '#ffa726',\n 500: '#ff9800',\n 600: '#fb8c00',\n 700: '#f57c00',\n 800: '#ef6c00',\n 900: '#e65100',\n A100: '#ffd180',\n A200: '#ffab40',\n A400: '#ff9100',\n A700: '#ff6d00'\n};\nexport default orange;","const blue = {\n 50: '#e3f2fd',\n 100: '#bbdefb',\n 200: '#90caf9',\n 300: '#64b5f6',\n 400: '#42a5f5',\n 500: '#2196f3',\n 600: '#1e88e5',\n 700: '#1976d2',\n 800: '#1565c0',\n 900: '#0d47a1',\n A100: '#82b1ff',\n A200: '#448aff',\n A400: '#2979ff',\n A700: '#2962ff'\n};\nexport default blue;","const lightBlue = {\n 50: '#e1f5fe',\n 100: '#b3e5fc',\n 200: '#81d4fa',\n 300: '#4fc3f7',\n 400: '#29b6f6',\n 500: '#03a9f4',\n 600: '#039be5',\n 700: '#0288d1',\n 800: '#0277bd',\n 900: '#01579b',\n A100: '#80d8ff',\n A200: '#40c4ff',\n A400: '#00b0ff',\n A700: '#0091ea'\n};\nexport default lightBlue;","const green = {\n 50: '#e8f5e9',\n 100: '#c8e6c9',\n 200: '#a5d6a7',\n 300: '#81c784',\n 400: '#66bb6a',\n 500: '#4caf50',\n 600: '#43a047',\n 700: '#388e3c',\n 800: '#2e7d32',\n 900: '#1b5e20',\n A100: '#b9f6ca',\n A200: '#69f0ae',\n A400: '#00e676',\n A700: '#00c853'\n};\nexport default green;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\nconst _excluded = [\"mode\", \"contrastThreshold\", \"tonalOffset\"];\nimport { deepmerge } from '@mui/utils';\nimport { darken, getContrastRatio, lighten } from '@mui/system';\nimport common from '../colors/common';\nimport grey from '../colors/grey';\nimport purple from '../colors/purple';\nimport red from '../colors/red';\nimport orange from '../colors/orange';\nimport blue from '../colors/blue';\nimport lightBlue from '../colors/lightBlue';\nimport green from '../colors/green';\nexport const light = {\n // The colors used to style the text.\n text: {\n // The most important text.\n primary: 'rgba(0, 0, 0, 0.87)',\n // Secondary text.\n secondary: 'rgba(0, 0, 0, 0.6)',\n // Disabled text have even lower visual prominence.\n disabled: 'rgba(0, 0, 0, 0.38)'\n },\n // The color used to divide different elements.\n divider: 'rgba(0, 0, 0, 0.12)',\n // The background colors used to style the surfaces.\n // Consistency between these values is important.\n background: {\n paper: common.white,\n default: common.white\n },\n // The colors used to style the action elements.\n action: {\n // The color of an active action like an icon button.\n active: 'rgba(0, 0, 0, 0.54)',\n // The color of an hovered action.\n hover: 'rgba(0, 0, 0, 0.04)',\n hoverOpacity: 0.04,\n // The color of a selected action.\n selected: 'rgba(0, 0, 0, 0.08)',\n selectedOpacity: 0.08,\n // The color of a disabled action.\n disabled: 'rgba(0, 0, 0, 0.26)',\n // The background color of a disabled action.\n disabledBackground: 'rgba(0, 0, 0, 0.12)',\n disabledOpacity: 0.38,\n focus: 'rgba(0, 0, 0, 0.12)',\n focusOpacity: 0.12,\n activatedOpacity: 0.12\n }\n};\nexport const dark = {\n text: {\n primary: common.white,\n secondary: 'rgba(255, 255, 255, 0.7)',\n disabled: 'rgba(255, 255, 255, 0.5)',\n icon: 'rgba(255, 255, 255, 0.5)'\n },\n divider: 'rgba(255, 255, 255, 0.12)',\n background: {\n paper: '#121212',\n default: '#121212'\n },\n action: {\n active: common.white,\n hover: 'rgba(255, 255, 255, 0.08)',\n hoverOpacity: 0.08,\n selected: 'rgba(255, 255, 255, 0.16)',\n selectedOpacity: 0.16,\n disabled: 'rgba(255, 255, 255, 0.3)',\n disabledBackground: 'rgba(255, 255, 255, 0.12)',\n disabledOpacity: 0.38,\n focus: 'rgba(255, 255, 255, 0.12)',\n focusOpacity: 0.12,\n activatedOpacity: 0.24\n }\n};\nfunction addLightOrDark(intent, direction, shade, tonalOffset) {\n const tonalOffsetLight = tonalOffset.light || tonalOffset;\n const tonalOffsetDark = tonalOffset.dark || tonalOffset * 1.5;\n if (!intent[direction]) {\n if (intent.hasOwnProperty(shade)) {\n intent[direction] = intent[shade];\n } else if (direction === 'light') {\n intent.light = lighten(intent.main, tonalOffsetLight);\n } else if (direction === 'dark') {\n intent.dark = darken(intent.main, tonalOffsetDark);\n }\n }\n}\nfunction getDefaultPrimary(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: blue[200],\n light: blue[50],\n dark: blue[400]\n };\n }\n return {\n main: blue[700],\n light: blue[400],\n dark: blue[800]\n };\n}\nfunction getDefaultSecondary(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: purple[200],\n light: purple[50],\n dark: purple[400]\n };\n }\n return {\n main: purple[500],\n light: purple[300],\n dark: purple[700]\n };\n}\nfunction getDefaultError(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: red[500],\n light: red[300],\n dark: red[700]\n };\n }\n return {\n main: red[700],\n light: red[400],\n dark: red[800]\n };\n}\nfunction getDefaultInfo(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: lightBlue[400],\n light: lightBlue[300],\n dark: lightBlue[700]\n };\n }\n return {\n main: lightBlue[700],\n light: lightBlue[500],\n dark: lightBlue[900]\n };\n}\nfunction getDefaultSuccess(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: green[400],\n light: green[300],\n dark: green[700]\n };\n }\n return {\n main: green[800],\n light: green[500],\n dark: green[900]\n };\n}\nfunction getDefaultWarning(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: orange[400],\n light: orange[300],\n dark: orange[700]\n };\n }\n return {\n main: '#ed6c02',\n // closest to orange[800] that pass 3:1.\n light: orange[500],\n dark: orange[900]\n };\n}\nexport default function createPalette(palette) {\n const {\n mode = 'light',\n contrastThreshold = 3,\n tonalOffset = 0.2\n } = palette,\n other = _objectWithoutPropertiesLoose(palette, _excluded);\n const primary = palette.primary || getDefaultPrimary(mode);\n const secondary = palette.secondary || getDefaultSecondary(mode);\n const error = palette.error || getDefaultError(mode);\n const info = palette.info || getDefaultInfo(mode);\n const success = palette.success || getDefaultSuccess(mode);\n const warning = palette.warning || getDefaultWarning(mode);\n\n // Use the same logic as\n // Bootstrap: https://github.com/twbs/bootstrap/blob/1d6e3710dd447de1a200f29e8fa521f8a0908f70/scss/_functions.scss#L59\n // and material-components-web https://github.com/material-components/material-components-web/blob/ac46b8863c4dab9fc22c4c662dc6bd1b65dd652f/packages/mdc-theme/_functions.scss#L54\n function getContrastText(background) {\n const contrastText = getContrastRatio(background, dark.text.primary) >= contrastThreshold ? dark.text.primary : light.text.primary;\n if (process.env.NODE_ENV !== 'production') {\n const contrast = getContrastRatio(background, contrastText);\n if (contrast < 3) {\n console.error([`MUI: The contrast ratio of ${contrast}:1 for ${contrastText} on ${background}`, 'falls below the WCAG recommended absolute minimum contrast ratio of 3:1.', 'https://www.w3.org/TR/2008/REC-WCAG20-20081211/#visual-audio-contrast-contrast'].join('\\n'));\n }\n }\n return contrastText;\n }\n const augmentColor = ({\n color,\n name,\n mainShade = 500,\n lightShade = 300,\n darkShade = 700\n }) => {\n color = _extends({}, color);\n if (!color.main && color[mainShade]) {\n color.main = color[mainShade];\n }\n if (!color.hasOwnProperty('main')) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: The color${name ? ` (${name})` : ''} provided to augmentColor(color) is invalid.\nThe color object needs to have a \\`main\\` property or a \\`${mainShade}\\` property.` : _formatMuiErrorMessage(11, name ? ` (${name})` : '', mainShade));\n }\n if (typeof color.main !== 'string') {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: The color${name ? ` (${name})` : ''} provided to augmentColor(color) is invalid.\n\\`color.main\\` should be a string, but \\`${JSON.stringify(color.main)}\\` was provided instead.\n\nDid you intend to use one of the following approaches?\n\nimport { green } from \"@mui/material/colors\";\n\nconst theme1 = createTheme({ palette: {\n primary: green,\n} });\n\nconst theme2 = createTheme({ palette: {\n primary: { main: green[500] },\n} });` : _formatMuiErrorMessage(12, name ? ` (${name})` : '', JSON.stringify(color.main)));\n }\n addLightOrDark(color, 'light', lightShade, tonalOffset);\n addLightOrDark(color, 'dark', darkShade, tonalOffset);\n if (!color.contrastText) {\n color.contrastText = getContrastText(color.main);\n }\n return color;\n };\n const modes = {\n dark,\n light\n };\n if (process.env.NODE_ENV !== 'production') {\n if (!modes[mode]) {\n console.error(`MUI: The palette mode \\`${mode}\\` is not supported.`);\n }\n }\n const paletteOutput = deepmerge(_extends({\n // A collection of common colors.\n common: _extends({}, common),\n // prevent mutable object.\n // The palette mode, can be light or dark.\n mode,\n // The colors used to represent primary interface elements for a user.\n primary: augmentColor({\n color: primary,\n name: 'primary'\n }),\n // The colors used to represent secondary interface elements for a user.\n secondary: augmentColor({\n color: secondary,\n name: 'secondary',\n mainShade: 'A400',\n lightShade: 'A200',\n darkShade: 'A700'\n }),\n // The colors used to represent interface elements that the user should be made aware of.\n error: augmentColor({\n color: error,\n name: 'error'\n }),\n // The colors used to represent potentially dangerous actions or important messages.\n warning: augmentColor({\n color: warning,\n name: 'warning'\n }),\n // The colors used to present information to the user that is neutral and not necessarily important.\n info: augmentColor({\n color: info,\n name: 'info'\n }),\n // The colors used to indicate the successful completion of an action that user triggered.\n success: augmentColor({\n color: success,\n name: 'success'\n }),\n // The grey colors.\n grey,\n // Used by `getContrastText()` to maximize the contrast between\n // the background and the text.\n contrastThreshold,\n // Takes a background color and returns the text color that maximizes the contrast.\n getContrastText,\n // Generate a rich color object.\n augmentColor,\n // Used by the functions below to shift a color's luminance by approximately\n // two indexes within its tonal palette.\n // E.g., shift from Red 500 to Red 300 or Red 700.\n tonalOffset\n }, modes[mode]), other);\n return paletteOutput;\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"fontFamily\", \"fontSize\", \"fontWeightLight\", \"fontWeightRegular\", \"fontWeightMedium\", \"fontWeightBold\", \"htmlFontSize\", \"allVariants\", \"pxToRem\"];\nimport { deepmerge } from '@mui/utils';\nfunction round(value) {\n return Math.round(value * 1e5) / 1e5;\n}\nconst caseAllCaps = {\n textTransform: 'uppercase'\n};\nconst defaultFontFamily = '\"Roboto\", \"Helvetica\", \"Arial\", sans-serif';\n\n/**\n * @see @link{https://m2.material.io/design/typography/the-type-system.html}\n * @see @link{https://m2.material.io/design/typography/understanding-typography.html}\n */\nexport default function createTypography(palette, typography) {\n const _ref = typeof typography === 'function' ? typography(palette) : typography,\n {\n fontFamily = defaultFontFamily,\n // The default font size of the Material Specification.\n fontSize = 14,\n // px\n fontWeightLight = 300,\n fontWeightRegular = 400,\n fontWeightMedium = 500,\n fontWeightBold = 700,\n // Tell MUI what's the font-size on the html element.\n // 16px is the default font-size used by browsers.\n htmlFontSize = 16,\n // Apply the CSS properties to all the variants.\n allVariants,\n pxToRem: pxToRem2\n } = _ref,\n other = _objectWithoutPropertiesLoose(_ref, _excluded);\n if (process.env.NODE_ENV !== 'production') {\n if (typeof fontSize !== 'number') {\n console.error('MUI: `fontSize` is required to be a number.');\n }\n if (typeof htmlFontSize !== 'number') {\n console.error('MUI: `htmlFontSize` is required to be a number.');\n }\n }\n const coef = fontSize / 14;\n const pxToRem = pxToRem2 || (size => `${size / htmlFontSize * coef}rem`);\n const buildVariant = (fontWeight, size, lineHeight, letterSpacing, casing) => _extends({\n fontFamily,\n fontWeight,\n fontSize: pxToRem(size),\n // Unitless following https://meyerweb.com/eric/thoughts/2006/02/08/unitless-line-heights/\n lineHeight\n }, fontFamily === defaultFontFamily ? {\n letterSpacing: `${round(letterSpacing / size)}em`\n } : {}, casing, allVariants);\n const variants = {\n h1: buildVariant(fontWeightLight, 96, 1.167, -1.5),\n h2: buildVariant(fontWeightLight, 60, 1.2, -0.5),\n h3: buildVariant(fontWeightRegular, 48, 1.167, 0),\n h4: buildVariant(fontWeightRegular, 34, 1.235, 0.25),\n h5: buildVariant(fontWeightRegular, 24, 1.334, 0),\n h6: buildVariant(fontWeightMedium, 20, 1.6, 0.15),\n subtitle1: buildVariant(fontWeightRegular, 16, 1.75, 0.15),\n subtitle2: buildVariant(fontWeightMedium, 14, 1.57, 0.1),\n body1: buildVariant(fontWeightRegular, 16, 1.5, 0.15),\n body2: buildVariant(fontWeightRegular, 14, 1.43, 0.15),\n button: buildVariant(fontWeightMedium, 14, 1.75, 0.4, caseAllCaps),\n caption: buildVariant(fontWeightRegular, 12, 1.66, 0.4),\n overline: buildVariant(fontWeightRegular, 12, 2.66, 1, caseAllCaps),\n // TODO v6: Remove handling of 'inherit' variant from the theme as it is already handled in Material UI's Typography component. Also, remember to remove the associated types.\n inherit: {\n fontFamily: 'inherit',\n fontWeight: 'inherit',\n fontSize: 'inherit',\n lineHeight: 'inherit',\n letterSpacing: 'inherit'\n }\n };\n return deepmerge(_extends({\n htmlFontSize,\n pxToRem,\n fontFamily,\n fontSize,\n fontWeightLight,\n fontWeightRegular,\n fontWeightMedium,\n fontWeightBold\n }, variants), other, {\n clone: false // No need to clone deep\n });\n}","const shadowKeyUmbraOpacity = 0.2;\nconst shadowKeyPenumbraOpacity = 0.14;\nconst shadowAmbientShadowOpacity = 0.12;\nfunction createShadow(...px) {\n return [`${px[0]}px ${px[1]}px ${px[2]}px ${px[3]}px rgba(0,0,0,${shadowKeyUmbraOpacity})`, `${px[4]}px ${px[5]}px ${px[6]}px ${px[7]}px rgba(0,0,0,${shadowKeyPenumbraOpacity})`, `${px[8]}px ${px[9]}px ${px[10]}px ${px[11]}px rgba(0,0,0,${shadowAmbientShadowOpacity})`].join(',');\n}\n\n// Values from https://github.com/material-components/material-components-web/blob/be8747f94574669cb5e7add1a7c54fa41a89cec7/packages/mdc-elevation/_variables.scss\nconst shadows = ['none', createShadow(0, 2, 1, -1, 0, 1, 1, 0, 0, 1, 3, 0), createShadow(0, 3, 1, -2, 0, 2, 2, 0, 0, 1, 5, 0), createShadow(0, 3, 3, -2, 0, 3, 4, 0, 0, 1, 8, 0), createShadow(0, 2, 4, -1, 0, 4, 5, 0, 0, 1, 10, 0), createShadow(0, 3, 5, -1, 0, 5, 8, 0, 0, 1, 14, 0), createShadow(0, 3, 5, -1, 0, 6, 10, 0, 0, 1, 18, 0), createShadow(0, 4, 5, -2, 0, 7, 10, 1, 0, 2, 16, 1), createShadow(0, 5, 5, -3, 0, 8, 10, 1, 0, 3, 14, 2), createShadow(0, 5, 6, -3, 0, 9, 12, 1, 0, 3, 16, 2), createShadow(0, 6, 6, -3, 0, 10, 14, 1, 0, 4, 18, 3), createShadow(0, 6, 7, -4, 0, 11, 15, 1, 0, 4, 20, 3), createShadow(0, 7, 8, -4, 0, 12, 17, 2, 0, 5, 22, 4), createShadow(0, 7, 8, -4, 0, 13, 19, 2, 0, 5, 24, 4), createShadow(0, 7, 9, -4, 0, 14, 21, 2, 0, 5, 26, 4), createShadow(0, 8, 9, -5, 0, 15, 22, 2, 0, 6, 28, 5), createShadow(0, 8, 10, -5, 0, 16, 24, 2, 0, 6, 30, 5), createShadow(0, 8, 11, -5, 0, 17, 26, 2, 0, 6, 32, 5), createShadow(0, 9, 11, -5, 0, 18, 28, 2, 0, 7, 34, 6), createShadow(0, 9, 12, -6, 0, 19, 29, 2, 0, 7, 36, 6), createShadow(0, 10, 13, -6, 0, 20, 31, 3, 0, 8, 38, 7), createShadow(0, 10, 13, -6, 0, 21, 33, 3, 0, 8, 40, 7), createShadow(0, 10, 14, -6, 0, 22, 35, 3, 0, 8, 42, 7), createShadow(0, 11, 14, -7, 0, 23, 36, 3, 0, 9, 44, 8), createShadow(0, 11, 15, -7, 0, 24, 38, 3, 0, 9, 46, 8)];\nexport default shadows;","import _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nconst _excluded = [\"duration\", \"easing\", \"delay\"];\n// Follow https://material.google.com/motion/duration-easing.html#duration-easing-natural-easing-curves\n// to learn the context in which each easing should be used.\nexport const easing = {\n // This is the most common easing curve.\n easeInOut: 'cubic-bezier(0.4, 0, 0.2, 1)',\n // Objects enter the screen at full velocity from off-screen and\n // slowly decelerate to a resting point.\n easeOut: 'cubic-bezier(0.0, 0, 0.2, 1)',\n // Objects leave the screen at full velocity. They do not decelerate when off-screen.\n easeIn: 'cubic-bezier(0.4, 0, 1, 1)',\n // The sharp curve is used by objects that may return to the screen at any time.\n sharp: 'cubic-bezier(0.4, 0, 0.6, 1)'\n};\n\n// Follow https://m2.material.io/guidelines/motion/duration-easing.html#duration-easing-common-durations\n// to learn when use what timing\nexport const duration = {\n shortest: 150,\n shorter: 200,\n short: 250,\n // most basic recommended timing\n standard: 300,\n // this is to be used in complex animations\n complex: 375,\n // recommended when something is entering screen\n enteringScreen: 225,\n // recommended when something is leaving screen\n leavingScreen: 195\n};\nfunction formatMs(milliseconds) {\n return `${Math.round(milliseconds)}ms`;\n}\nfunction getAutoHeightDuration(height) {\n if (!height) {\n return 0;\n }\n const constant = height / 36;\n\n // https://www.wolframalpha.com/input/?i=(4+%2B+15+*+(x+%2F+36+)+**+0.25+%2B+(x+%2F+36)+%2F+5)+*+10\n return Math.round((4 + 15 * constant ** 0.25 + constant / 5) * 10);\n}\nexport default function createTransitions(inputTransitions) {\n const mergedEasing = _extends({}, easing, inputTransitions.easing);\n const mergedDuration = _extends({}, duration, inputTransitions.duration);\n const create = (props = ['all'], options = {}) => {\n const {\n duration: durationOption = mergedDuration.standard,\n easing: easingOption = mergedEasing.easeInOut,\n delay = 0\n } = options,\n other = _objectWithoutPropertiesLoose(options, _excluded);\n if (process.env.NODE_ENV !== 'production') {\n const isString = value => typeof value === 'string';\n // IE11 support, replace with Number.isNaN\n // eslint-disable-next-line no-restricted-globals\n const isNumber = value => !isNaN(parseFloat(value));\n if (!isString(props) && !Array.isArray(props)) {\n console.error('MUI: Argument \"props\" must be a string or Array.');\n }\n if (!isNumber(durationOption) && !isString(durationOption)) {\n console.error(`MUI: Argument \"duration\" must be a number or a string but found ${durationOption}.`);\n }\n if (!isString(easingOption)) {\n console.error('MUI: Argument \"easing\" must be a string.');\n }\n if (!isNumber(delay) && !isString(delay)) {\n console.error('MUI: Argument \"delay\" must be a number or a string.');\n }\n if (typeof options !== 'object') {\n console.error(['MUI: Secong argument of transition.create must be an object.', \"Arguments should be either `create('prop1', options)` or `create(['prop1', 'prop2'], options)`\"].join('\\n'));\n }\n if (Object.keys(other).length !== 0) {\n console.error(`MUI: Unrecognized argument(s) [${Object.keys(other).join(',')}].`);\n }\n }\n return (Array.isArray(props) ? props : [props]).map(animatedProp => `${animatedProp} ${typeof durationOption === 'string' ? durationOption : formatMs(durationOption)} ${easingOption} ${typeof delay === 'string' ? delay : formatMs(delay)}`).join(',');\n };\n return _extends({\n getAutoHeightDuration,\n create\n }, inputTransitions, {\n easing: mergedEasing,\n duration: mergedDuration\n });\n}","// We need to centralize the zIndex definitions as they work\n// like global values in the browser.\nconst zIndex = {\n mobileStepper: 1000,\n fab: 1050,\n speedDial: 1050,\n appBar: 1100,\n drawer: 1200,\n modal: 1300,\n snackbar: 1400,\n tooltip: 1500\n};\nexport default zIndex;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\nconst _excluded = [\"breakpoints\", \"mixins\", \"spacing\", \"palette\", \"transitions\", \"typography\", \"shape\"];\nimport { deepmerge } from '@mui/utils';\nimport { createTheme as systemCreateTheme, unstable_defaultSxConfig as defaultSxConfig, unstable_styleFunctionSx as styleFunctionSx } from '@mui/system';\nimport generateUtilityClass from '@mui/utils/generateUtilityClass';\nimport createMixins from './createMixins';\nimport createPalette from './createPalette';\nimport createTypography from './createTypography';\nimport shadows from './shadows';\nimport createTransitions from './createTransitions';\nimport zIndex from './zIndex';\nfunction createTheme(options = {}, ...args) {\n const {\n mixins: mixinsInput = {},\n palette: paletteInput = {},\n transitions: transitionsInput = {},\n typography: typographyInput = {}\n } = options,\n other = _objectWithoutPropertiesLoose(options, _excluded);\n if (options.vars) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: \\`vars\\` is a private field used for CSS variables support.\nPlease use another name.` : _formatMuiErrorMessage(18));\n }\n const palette = createPalette(paletteInput);\n const systemTheme = systemCreateTheme(options);\n let muiTheme = deepmerge(systemTheme, {\n mixins: createMixins(systemTheme.breakpoints, mixinsInput),\n palette,\n // Don't use [...shadows] until you've verified its transpiled code is not invoking the iterator protocol.\n shadows: shadows.slice(),\n typography: createTypography(palette, typographyInput),\n transitions: createTransitions(transitionsInput),\n zIndex: _extends({}, zIndex)\n });\n muiTheme = deepmerge(muiTheme, other);\n muiTheme = args.reduce((acc, argument) => deepmerge(acc, argument), muiTheme);\n if (process.env.NODE_ENV !== 'production') {\n // TODO v6: Refactor to use globalStateClassesMapping from @mui/utils once `readOnly` state class is used in Rating component.\n const stateClasses = ['active', 'checked', 'completed', 'disabled', 'error', 'expanded', 'focused', 'focusVisible', 'required', 'selected'];\n const traverse = (node, component) => {\n let key;\n\n // eslint-disable-next-line guard-for-in, no-restricted-syntax\n for (key in node) {\n const child = node[key];\n if (stateClasses.indexOf(key) !== -1 && Object.keys(child).length > 0) {\n if (process.env.NODE_ENV !== 'production') {\n const stateClass = generateUtilityClass('', key);\n console.error([`MUI: The \\`${component}\\` component increases ` + `the CSS specificity of the \\`${key}\\` internal state.`, 'You can not override it like this: ', JSON.stringify(node, null, 2), '', `Instead, you need to use the '&.${stateClass}' syntax:`, JSON.stringify({\n root: {\n [`&.${stateClass}`]: child\n }\n }, null, 2), '', 'https://mui.com/r/state-classes-guide'].join('\\n'));\n }\n // Remove the style to prevent global conflicts.\n node[key] = {};\n }\n }\n };\n Object.keys(muiTheme.components).forEach(component => {\n const styleOverrides = muiTheme.components[component].styleOverrides;\n if (styleOverrides && component.indexOf('Mui') === 0) {\n traverse(styleOverrides, component);\n }\n });\n }\n muiTheme.unstable_sxConfig = _extends({}, defaultSxConfig, other == null ? void 0 : other.unstable_sxConfig);\n muiTheme.unstable_sx = function sx(props) {\n return styleFunctionSx({\n sx: props,\n theme: this\n });\n };\n return muiTheme;\n}\nlet warnedOnce = false;\nexport function createMuiTheme(...args) {\n if (process.env.NODE_ENV !== 'production') {\n if (!warnedOnce) {\n warnedOnce = true;\n console.error(['MUI: the createMuiTheme function was renamed to createTheme.', '', \"You should use `import { createTheme } from '@mui/material/styles'`\"].join('\\n'));\n }\n }\n return createTheme(...args);\n}\nexport default createTheme;","'use client';\n\nimport createTheme from './createTheme';\nconst defaultTheme = createTheme();\nexport default defaultTheme;","export default '$$material';","'use client';\n\nimport { useThemeProps as systemUseThemeProps } from '@mui/system';\nimport defaultTheme from './defaultTheme';\nimport THEME_ID from './identifier';\nexport default function useThemeProps({\n props,\n name\n}) {\n return systemUseThemeProps({\n props,\n name,\n defaultTheme,\n themeId: THEME_ID\n });\n}","'use client';\n\nimport { createStyled, shouldForwardProp } from '@mui/system';\nimport defaultTheme from './defaultTheme';\nimport THEME_ID from './identifier';\nexport const rootShouldForwardProp = prop => shouldForwardProp(prop) && prop !== 'classes';\nexport const slotShouldForwardProp = shouldForwardProp;\nconst styled = createStyled({\n themeId: THEME_ID,\n defaultTheme,\n rootShouldForwardProp\n});\nexport default styled;","import generateUtilityClasses from '@mui/utils/generateUtilityClasses';\nimport generateUtilityClass from '@mui/utils/generateUtilityClass';\nexport function getSvgIconUtilityClass(slot) {\n return generateUtilityClass('MuiSvgIcon', slot);\n}\nconst svgIconClasses = generateUtilityClasses('MuiSvgIcon', ['root', 'colorPrimary', 'colorSecondary', 'colorAction', 'colorError', 'colorDisabled', 'fontSizeInherit', 'fontSizeSmall', 'fontSizeMedium', 'fontSizeLarge']);\nexport default svgIconClasses;","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"children\", \"className\", \"color\", \"component\", \"fontSize\", \"htmlColor\", \"inheritViewBox\", \"titleAccess\", \"viewBox\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport clsx from 'clsx';\nimport { unstable_composeClasses as composeClasses } from '@mui/base/composeClasses';\nimport capitalize from '../utils/capitalize';\nimport useThemeProps from '../styles/useThemeProps';\nimport styled from '../styles/styled';\nimport { getSvgIconUtilityClass } from './svgIconClasses';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nimport { jsxs as _jsxs } from \"react/jsx-runtime\";\nconst useUtilityClasses = ownerState => {\n const {\n color,\n fontSize,\n classes\n } = ownerState;\n const slots = {\n root: ['root', color !== 'inherit' && `color${capitalize(color)}`, `fontSize${capitalize(fontSize)}`]\n };\n return composeClasses(slots, getSvgIconUtilityClass, classes);\n};\nconst SvgIconRoot = styled('svg', {\n name: 'MuiSvgIcon',\n slot: 'Root',\n overridesResolver: (props, styles) => {\n const {\n ownerState\n } = props;\n return [styles.root, ownerState.color !== 'inherit' && styles[`color${capitalize(ownerState.color)}`], styles[`fontSize${capitalize(ownerState.fontSize)}`]];\n }\n})(({\n theme,\n ownerState\n}) => {\n var _theme$transitions, _theme$transitions$cr, _theme$transitions2, _theme$typography, _theme$typography$pxT, _theme$typography2, _theme$typography2$px, _theme$typography3, _theme$typography3$px, _palette$ownerState$c, _palette, _palette2, _palette3;\n return {\n userSelect: 'none',\n width: '1em',\n height: '1em',\n display: 'inline-block',\n // the will define the property that has `currentColor`\n // e.g. heroicons uses fill=\"none\" and stroke=\"currentColor\"\n fill: ownerState.hasSvgAsChild ? undefined : 'currentColor',\n flexShrink: 0,\n transition: (_theme$transitions = theme.transitions) == null || (_theme$transitions$cr = _theme$transitions.create) == null ? void 0 : _theme$transitions$cr.call(_theme$transitions, 'fill', {\n duration: (_theme$transitions2 = theme.transitions) == null || (_theme$transitions2 = _theme$transitions2.duration) == null ? void 0 : _theme$transitions2.shorter\n }),\n fontSize: {\n inherit: 'inherit',\n small: ((_theme$typography = theme.typography) == null || (_theme$typography$pxT = _theme$typography.pxToRem) == null ? void 0 : _theme$typography$pxT.call(_theme$typography, 20)) || '1.25rem',\n medium: ((_theme$typography2 = theme.typography) == null || (_theme$typography2$px = _theme$typography2.pxToRem) == null ? void 0 : _theme$typography2$px.call(_theme$typography2, 24)) || '1.5rem',\n large: ((_theme$typography3 = theme.typography) == null || (_theme$typography3$px = _theme$typography3.pxToRem) == null ? void 0 : _theme$typography3$px.call(_theme$typography3, 35)) || '2.1875rem'\n }[ownerState.fontSize],\n // TODO v5 deprecate, v6 remove for sx\n color: (_palette$ownerState$c = (_palette = (theme.vars || theme).palette) == null || (_palette = _palette[ownerState.color]) == null ? void 0 : _palette.main) != null ? _palette$ownerState$c : {\n action: (_palette2 = (theme.vars || theme).palette) == null || (_palette2 = _palette2.action) == null ? void 0 : _palette2.active,\n disabled: (_palette3 = (theme.vars || theme).palette) == null || (_palette3 = _palette3.action) == null ? void 0 : _palette3.disabled,\n inherit: undefined\n }[ownerState.color]\n };\n});\nconst SvgIcon = /*#__PURE__*/React.forwardRef(function SvgIcon(inProps, ref) {\n const props = useThemeProps({\n props: inProps,\n name: 'MuiSvgIcon'\n });\n const {\n children,\n className,\n color = 'inherit',\n component = 'svg',\n fontSize = 'medium',\n htmlColor,\n inheritViewBox = false,\n titleAccess,\n viewBox = '0 0 24 24'\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const hasSvgAsChild = /*#__PURE__*/React.isValidElement(children) && children.type === 'svg';\n const ownerState = _extends({}, props, {\n color,\n component,\n fontSize,\n instanceFontSize: inProps.fontSize,\n inheritViewBox,\n viewBox,\n hasSvgAsChild\n });\n const more = {};\n if (!inheritViewBox) {\n more.viewBox = viewBox;\n }\n const classes = useUtilityClasses(ownerState);\n return /*#__PURE__*/_jsxs(SvgIconRoot, _extends({\n as: component,\n className: clsx(classes.root, className),\n focusable: \"false\",\n color: htmlColor,\n \"aria-hidden\": titleAccess ? undefined : true,\n role: titleAccess ? 'img' : undefined,\n ref: ref\n }, more, other, hasSvgAsChild && children.props, {\n ownerState: ownerState,\n children: [hasSvgAsChild ? children.props.children : children, titleAccess ? /*#__PURE__*/_jsx(\"title\", {\n children: titleAccess\n }) : null]\n }));\n});\nprocess.env.NODE_ENV !== \"production\" ? SvgIcon.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the d.ts file and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * Node passed into the SVG element.\n */\n children: PropTypes.node,\n /**\n * Override or extend the styles applied to the component.\n */\n classes: PropTypes.object,\n /**\n * @ignore\n */\n className: PropTypes.string,\n /**\n * The color of the component.\n * It supports both default and custom theme colors, which can be added as shown in the\n * [palette customization guide](https://mui.com/material-ui/customization/palette/#custom-colors).\n * You can use the `htmlColor` prop to apply a color attribute to the SVG element.\n * @default 'inherit'\n */\n color: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.oneOf(['inherit', 'action', 'disabled', 'primary', 'secondary', 'error', 'info', 'success', 'warning']), PropTypes.string]),\n /**\n * The component used for the root node.\n * Either a string to use a HTML element or a component.\n */\n component: PropTypes.elementType,\n /**\n * The fontSize applied to the icon. Defaults to 24px, but can be configure to inherit font size.\n * @default 'medium'\n */\n fontSize: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.oneOf(['inherit', 'large', 'medium', 'small']), PropTypes.string]),\n /**\n * Applies a color attribute to the SVG element.\n */\n htmlColor: PropTypes.string,\n /**\n * If `true`, the root node will inherit the custom `component`'s viewBox and the `viewBox`\n * prop will be ignored.\n * Useful when you want to reference a custom `component` and have `SvgIcon` pass that\n * `component`'s viewBox to the root node.\n * @default false\n */\n inheritViewBox: PropTypes.bool,\n /**\n * The shape-rendering attribute. The behavior of the different options is described on the\n * [MDN Web Docs](https://developer.mozilla.org/en-US/docs/Web/SVG/Attribute/shape-rendering).\n * If you are having issues with blurry icons you should investigate this prop.\n */\n shapeRendering: PropTypes.string,\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Provides a human-readable title for the element that contains it.\n * https://www.w3.org/TR/SVG-access/#Equivalent\n */\n titleAccess: PropTypes.string,\n /**\n * Allows you to redefine what the coordinates without units mean inside an SVG element.\n * For example, if the SVG element is 500 (width) by 200 (height),\n * and you pass viewBox=\"0 0 50 20\",\n * this means that the coordinates inside the SVG will go from the top left corner (0,0)\n * to bottom right (50,20) and each unit will be worth 10px.\n * @default '0 0 24 24'\n */\n viewBox: PropTypes.string\n} : void 0;\nSvgIcon.muiName = 'SvgIcon';\nexport default SvgIcon;","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport * as React from 'react';\nimport SvgIcon from '../SvgIcon';\n\n/**\n * Private module reserved for @mui packages.\n */\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nexport default function createSvgIcon(path, displayName) {\n function Component(props, ref) {\n return /*#__PURE__*/_jsx(SvgIcon, _extends({\n \"data-testid\": `${displayName}Icon`,\n ref: ref\n }, props, {\n children: path\n }));\n }\n if (process.env.NODE_ENV !== 'production') {\n // Need to set `displayName` on the inner component for React.memo.\n // React prior to 16.14 ignores `displayName` on the wrapper.\n Component.displayName = `${displayName}Icon`;\n }\n Component.muiName = SvgIcon.muiName;\n return /*#__PURE__*/React.memo( /*#__PURE__*/React.forwardRef(Component));\n}","'use client';\n\nimport { unstable_ClassNameGenerator as ClassNameGenerator } from '@mui/base/ClassNameGenerator';\nexport { default as capitalize } from './capitalize';\nexport { default as createChainedFunction } from './createChainedFunction';\nexport { default as createSvgIcon } from './createSvgIcon';\nexport { default as debounce } from './debounce';\nexport { default as deprecatedPropType } from './deprecatedPropType';\nexport { default as isMuiElement } from './isMuiElement';\nexport { default as ownerDocument } from './ownerDocument';\nexport { default as ownerWindow } from './ownerWindow';\nexport { default as requirePropFactory } from './requirePropFactory';\nexport { default as setRef } from './setRef';\nexport { default as unstable_useEnhancedEffect } from './useEnhancedEffect';\nexport { default as unstable_useId } from './useId';\nexport { default as unsupportedProp } from './unsupportedProp';\nexport { default as useControlled } from './useControlled';\nexport { default as useEventCallback } from './useEventCallback';\nexport { default as useForkRef } from './useForkRef';\nexport { default as useIsFocusVisible } from './useIsFocusVisible';\n// TODO: remove this export once ClassNameGenerator is stable\n// eslint-disable-next-line @typescript-eslint/naming-convention\nexport const unstable_ClassNameGenerator = {\n configure: generator => {\n if (process.env.NODE_ENV !== 'production') {\n console.warn(['MUI: `ClassNameGenerator` import from `@mui/material/utils` is outdated and might cause unexpected issues.', '', \"You should use `import { unstable_ClassNameGenerator } from '@mui/material/className'` instead\", '', 'The detail of the issue: https://github.com/mui/material-ui/issues/30011#issuecomment-1024993401', '', 'The updated documentation: https://mui.com/guides/classname-generator/'].join('\\n'));\n }\n ClassNameGenerator.configure(generator);\n }\n};","\"use strict\";\n'use client';\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nObject.defineProperty(exports, \"default\", {\n enumerable: true,\n get: function () {\n return _utils.createSvgIcon;\n }\n});\nvar _utils = require(\"@mui/material/utils\");","\"use strict\";\n\"use client\";\n\nvar _interopRequireDefault = require(\"@babel/runtime/helpers/interopRequireDefault\");\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = void 0;\nvar _createSvgIcon = _interopRequireDefault(require(\"./utils/createSvgIcon\"));\nvar _jsxRuntime = require(\"react/jsx-runtime\");\nvar _default = exports.default = (0, _createSvgIcon.default)( /*#__PURE__*/(0, _jsxRuntime.jsx)(\"path\", {\n d: \"m10 17 5-5-5-5z\"\n}), 'ArrowRight');","/**\n * Determines if a given element is a DOM element name (i.e. not a React component).\n */\nexport function isHostComponent(element) {\n return typeof element === 'string';\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport { isHostComponent } from './isHostComponent';\n\n/**\n * Type of the ownerState based on the type of an element it applies to.\n * This resolves to the provided OwnerState for React components and `undefined` for host components.\n * Falls back to `OwnerState | undefined` when the exact type can't be determined in development time.\n */\n\n/**\n * Appends the ownerState object to the props, merging with the existing one if necessary.\n *\n * @param elementType Type of the element that owns the `existingProps`. If the element is a DOM node or undefined, `ownerState` is not applied.\n * @param otherProps Props of the element.\n * @param ownerState\n */\nexport function appendOwnerState(elementType, otherProps, ownerState) {\n if (elementType === undefined || isHostComponent(elementType)) {\n return otherProps;\n }\n return _extends({}, otherProps, {\n ownerState: _extends({}, otherProps.ownerState, ownerState)\n });\n}","'use client';\n\nimport * as React from 'react';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nconst defaultContextValue = {\n disableDefaultClasses: false\n};\nconst ClassNameConfiguratorContext = /*#__PURE__*/React.createContext(defaultContextValue);\n/**\n * @ignore - internal hook.\n *\n * Wraps the `generateUtilityClass` function and controls how the classes are generated.\n * Currently it only affects whether the classes are applied or not.\n *\n * @returns Function to be called with the `generateUtilityClass` function specific to a component to generate the classes.\n */\nexport function useClassNamesOverride(generateUtilityClass) {\n const {\n disableDefaultClasses\n } = React.useContext(ClassNameConfiguratorContext);\n return slot => {\n if (disableDefaultClasses) {\n return '';\n }\n return generateUtilityClass(slot);\n };\n}\n\n/**\n * Allows to configure the components within to not apply any built-in classes.\n */\nexport function ClassNameConfigurator(props) {\n const {\n disableDefaultClasses,\n children\n } = props;\n const contextValue = React.useMemo(() => ({\n disableDefaultClasses: disableDefaultClasses != null ? disableDefaultClasses : false\n }), [disableDefaultClasses]);\n return /*#__PURE__*/_jsx(ClassNameConfiguratorContext.Provider, {\n value: contextValue,\n children: children\n });\n}","/**\n * Extracts event handlers from a given object.\n * A prop is considered an event handler if it is a function and its name starts with `on`.\n *\n * @param object An object to extract event handlers from.\n * @param excludeKeys An array of keys to exclude from the returned object.\n */\nexport function extractEventHandlers(object, excludeKeys = []) {\n if (object === undefined) {\n return {};\n }\n const result = {};\n Object.keys(object).filter(prop => prop.match(/^on[A-Z]/) && typeof object[prop] === 'function' && !excludeKeys.includes(prop)).forEach(prop => {\n result[prop] = object[prop];\n });\n return result;\n}","/**\n * If `componentProps` is a function, calls it with the provided `ownerState`.\n * Otherwise, just returns `componentProps`.\n */\nexport function resolveComponentProps(componentProps, ownerState, slotState) {\n if (typeof componentProps === 'function') {\n return componentProps(ownerState, slotState);\n }\n return componentProps;\n}","/**\n * Removes event handlers from the given object.\n * A field is considered an event handler if it is a function with a name beginning with `on`.\n *\n * @param object Object to remove event handlers from.\n * @returns Object with event handlers removed.\n */\nexport function omitEventHandlers(object) {\n if (object === undefined) {\n return {};\n }\n const result = {};\n Object.keys(object).filter(prop => !(prop.match(/^on[A-Z]/) && typeof object[prop] === 'function')).forEach(prop => {\n result[prop] = object[prop];\n });\n return result;\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport clsx from 'clsx';\nimport { extractEventHandlers } from './extractEventHandlers';\nimport { omitEventHandlers } from './omitEventHandlers';\n/**\n * Merges the slot component internal props (usually coming from a hook)\n * with the externally provided ones.\n *\n * The merge order is (the latter overrides the former):\n * 1. The internal props (specified as a getter function to work with get*Props hook result)\n * 2. Additional props (specified internally on a Base UI component)\n * 3. External props specified on the owner component. These should only be used on a root slot.\n * 4. External props specified in the `slotProps.*` prop.\n * 5. The `className` prop - combined from all the above.\n * @param parameters\n * @returns\n */\nexport function mergeSlotProps(parameters) {\n const {\n getSlotProps,\n additionalProps,\n externalSlotProps,\n externalForwardedProps,\n className\n } = parameters;\n if (!getSlotProps) {\n // The simpler case - getSlotProps is not defined, so no internal event handlers are defined,\n // so we can simply merge all the props without having to worry about extracting event handlers.\n const joinedClasses = clsx(additionalProps == null ? void 0 : additionalProps.className, className, externalForwardedProps == null ? void 0 : externalForwardedProps.className, externalSlotProps == null ? void 0 : externalSlotProps.className);\n const mergedStyle = _extends({}, additionalProps == null ? void 0 : additionalProps.style, externalForwardedProps == null ? void 0 : externalForwardedProps.style, externalSlotProps == null ? void 0 : externalSlotProps.style);\n const props = _extends({}, additionalProps, externalForwardedProps, externalSlotProps);\n if (joinedClasses.length > 0) {\n props.className = joinedClasses;\n }\n if (Object.keys(mergedStyle).length > 0) {\n props.style = mergedStyle;\n }\n return {\n props,\n internalRef: undefined\n };\n }\n\n // In this case, getSlotProps is responsible for calling the external event handlers.\n // We don't need to include them in the merged props because of this.\n\n const eventHandlers = extractEventHandlers(_extends({}, externalForwardedProps, externalSlotProps));\n const componentsPropsWithoutEventHandlers = omitEventHandlers(externalSlotProps);\n const otherPropsWithoutEventHandlers = omitEventHandlers(externalForwardedProps);\n const internalSlotProps = getSlotProps(eventHandlers);\n\n // The order of classes is important here.\n // Emotion (that we use in libraries consuming Base UI) depends on this order\n // to properly override style. It requires the most important classes to be last\n // (see https://github.com/mui/material-ui/pull/33205) for the related discussion.\n const joinedClasses = clsx(internalSlotProps == null ? void 0 : internalSlotProps.className, additionalProps == null ? void 0 : additionalProps.className, className, externalForwardedProps == null ? void 0 : externalForwardedProps.className, externalSlotProps == null ? void 0 : externalSlotProps.className);\n const mergedStyle = _extends({}, internalSlotProps == null ? void 0 : internalSlotProps.style, additionalProps == null ? void 0 : additionalProps.style, externalForwardedProps == null ? void 0 : externalForwardedProps.style, externalSlotProps == null ? void 0 : externalSlotProps.style);\n const props = _extends({}, internalSlotProps, additionalProps, otherPropsWithoutEventHandlers, componentsPropsWithoutEventHandlers);\n if (joinedClasses.length > 0) {\n props.className = joinedClasses;\n }\n if (Object.keys(mergedStyle).length > 0) {\n props.style = mergedStyle;\n }\n return {\n props,\n internalRef: internalSlotProps.ref\n };\n}","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"elementType\", \"externalSlotProps\", \"ownerState\", \"skipResolvingSlotProps\"];\nimport { unstable_useForkRef as useForkRef } from '@mui/utils';\nimport { appendOwnerState } from './appendOwnerState';\nimport { mergeSlotProps } from './mergeSlotProps';\nimport { resolveComponentProps } from './resolveComponentProps';\n/**\n * @ignore - do not document.\n * Builds the props to be passed into the slot of an unstyled component.\n * It merges the internal props of the component with the ones supplied by the user, allowing to customize the behavior.\n * If the slot component is not a host component, it also merges in the `ownerState`.\n *\n * @param parameters.getSlotProps - A function that returns the props to be passed to the slot component.\n */\nexport function useSlotProps(parameters) {\n var _parameters$additiona;\n const {\n elementType,\n externalSlotProps,\n ownerState,\n skipResolvingSlotProps = false\n } = parameters,\n rest = _objectWithoutPropertiesLoose(parameters, _excluded);\n const resolvedComponentsProps = skipResolvingSlotProps ? {} : resolveComponentProps(externalSlotProps, ownerState);\n const {\n props: mergedProps,\n internalRef\n } = mergeSlotProps(_extends({}, rest, {\n externalSlotProps: resolvedComponentsProps\n }));\n const ref = useForkRef(internalRef, resolvedComponentsProps == null ? void 0 : resolvedComponentsProps.ref, (_parameters$additiona = parameters.additionalProps) == null ? void 0 : _parameters$additiona.ref);\n const props = appendOwnerState(elementType, _extends({}, mergedProps, {\n ref\n }), ownerState);\n return props;\n}","import { globalStateClasses } from '@mui/utils/generateUtilityClass';\nconst GLOBAL_CLASS_PREFIX = 'base';\nfunction buildStateClass(state) {\n return `${GLOBAL_CLASS_PREFIX}--${state}`;\n}\nfunction buildSlotClass(componentName, slot) {\n return `${GLOBAL_CLASS_PREFIX}-${componentName}-${slot}`;\n}\nexport function generateUtilityClass(componentName, slot) {\n const globalStateClass = globalStateClasses[slot];\n return globalStateClass ? buildStateClass(globalStateClass) : buildSlotClass(componentName, slot);\n}\nexport function isGlobalState(slot) {\n return globalStateClasses[slot] !== undefined;\n}","import { generateUtilityClass } from '../generateUtilityClass';\nexport function generateUtilityClasses(componentName, slots) {\n const result = {};\n slots.forEach(slot => {\n result[slot] = generateUtilityClass(componentName, slot);\n });\n return result;\n}","'use client';\n\nimport * as React from 'react';\nimport * as ReactDOM from 'react-dom';\nimport PropTypes from 'prop-types';\nimport { exactProp, HTMLElementType, unstable_useEnhancedEffect as useEnhancedEffect, unstable_useForkRef as useForkRef, unstable_setRef as setRef } from '@mui/utils';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nfunction getContainer(container) {\n return typeof container === 'function' ? container() : container;\n}\n\n/**\n * Portals provide a first-class way to render children into a DOM node\n * that exists outside the DOM hierarchy of the parent component.\n *\n * Demos:\n *\n * - [Portal](https://mui.com/base-ui/react-portal/)\n *\n * API:\n *\n * - [Portal API](https://mui.com/base-ui/react-portal/components-api/#portal)\n */\nconst Portal = /*#__PURE__*/React.forwardRef(function Portal(props, forwardedRef) {\n const {\n children,\n container,\n disablePortal = false\n } = props;\n const [mountNode, setMountNode] = React.useState(null);\n // @ts-expect-error TODO upstream fix\n const handleRef = useForkRef( /*#__PURE__*/React.isValidElement(children) ? children.ref : null, forwardedRef);\n useEnhancedEffect(() => {\n if (!disablePortal) {\n setMountNode(getContainer(container) || document.body);\n }\n }, [container, disablePortal]);\n useEnhancedEffect(() => {\n if (mountNode && !disablePortal) {\n setRef(forwardedRef, mountNode);\n return () => {\n setRef(forwardedRef, null);\n };\n }\n return undefined;\n }, [forwardedRef, mountNode, disablePortal]);\n if (disablePortal) {\n if ( /*#__PURE__*/React.isValidElement(children)) {\n const newProps = {\n ref: handleRef\n };\n return /*#__PURE__*/React.cloneElement(children, newProps);\n }\n return /*#__PURE__*/_jsx(React.Fragment, {\n children: children\n });\n }\n return /*#__PURE__*/_jsx(React.Fragment, {\n children: mountNode ? /*#__PURE__*/ReactDOM.createPortal(children, mountNode) : mountNode\n });\n});\nprocess.env.NODE_ENV !== \"production\" ? Portal.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * The children to render into the `container`.\n */\n children: PropTypes.node,\n /**\n * An HTML element or function that returns one.\n * The `container` will have the portal children appended to it.\n *\n * You can also provide a callback, which is called in a React layout effect.\n * This lets you set the container from a ref, and also makes server-side rendering possible.\n *\n * By default, it uses the body of the top-level document object,\n * so it's simply `document.body` most of the time.\n */\n container: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.func]),\n /**\n * The `children` will be under the DOM hierarchy of the parent component.\n * @default false\n */\n disablePortal: PropTypes.bool\n} : void 0;\nif (process.env.NODE_ENV !== 'production') {\n // eslint-disable-next-line\n Portal['propTypes' + ''] = exactProp(Portal.propTypes);\n}\nexport { Portal };","export var top = 'top';\nexport var bottom = 'bottom';\nexport var right = 'right';\nexport var left = 'left';\nexport var auto = 'auto';\nexport var basePlacements = [top, bottom, right, left];\nexport var start = 'start';\nexport var end = 'end';\nexport var clippingParents = 'clippingParents';\nexport var viewport = 'viewport';\nexport var popper = 'popper';\nexport var reference = 'reference';\nexport var variationPlacements = /*#__PURE__*/basePlacements.reduce(function (acc, placement) {\n return acc.concat([placement + \"-\" + start, placement + \"-\" + end]);\n}, []);\nexport var placements = /*#__PURE__*/[].concat(basePlacements, [auto]).reduce(function (acc, placement) {\n return acc.concat([placement, placement + \"-\" + start, placement + \"-\" + end]);\n}, []); // modifiers that need to read the DOM\n\nexport var beforeRead = 'beforeRead';\nexport var read = 'read';\nexport var afterRead = 'afterRead'; // pure-logic modifiers\n\nexport var beforeMain = 'beforeMain';\nexport var main = 'main';\nexport var afterMain = 'afterMain'; // modifier with the purpose to write to the DOM (or write into a framework state)\n\nexport var beforeWrite = 'beforeWrite';\nexport var write = 'write';\nexport var afterWrite = 'afterWrite';\nexport var modifierPhases = [beforeRead, read, afterRead, beforeMain, main, afterMain, beforeWrite, write, afterWrite];","export default function getNodeName(element) {\n return element ? (element.nodeName || '').toLowerCase() : null;\n}","export default function getWindow(node) {\n if (node == null) {\n return window;\n }\n\n if (node.toString() !== '[object Window]') {\n var ownerDocument = node.ownerDocument;\n return ownerDocument ? ownerDocument.defaultView || window : window;\n }\n\n return node;\n}","import getWindow from \"./getWindow.js\";\n\nfunction isElement(node) {\n var OwnElement = getWindow(node).Element;\n return node instanceof OwnElement || node instanceof Element;\n}\n\nfunction isHTMLElement(node) {\n var OwnElement = getWindow(node).HTMLElement;\n return node instanceof OwnElement || node instanceof HTMLElement;\n}\n\nfunction isShadowRoot(node) {\n // IE 11 has no ShadowRoot\n if (typeof ShadowRoot === 'undefined') {\n return false;\n }\n\n var OwnElement = getWindow(node).ShadowRoot;\n return node instanceof OwnElement || node instanceof ShadowRoot;\n}\n\nexport { isElement, isHTMLElement, isShadowRoot };","import getNodeName from \"../dom-utils/getNodeName.js\";\nimport { isHTMLElement } from \"../dom-utils/instanceOf.js\"; // This modifier takes the styles prepared by the `computeStyles` modifier\n// and applies them to the HTMLElements such as popper and arrow\n\nfunction applyStyles(_ref) {\n var state = _ref.state;\n Object.keys(state.elements).forEach(function (name) {\n var style = state.styles[name] || {};\n var attributes = state.attributes[name] || {};\n var element = state.elements[name]; // arrow is optional + virtual elements\n\n if (!isHTMLElement(element) || !getNodeName(element)) {\n return;\n } // Flow doesn't support to extend this property, but it's the most\n // effective way to apply styles to an HTMLElement\n // $FlowFixMe[cannot-write]\n\n\n Object.assign(element.style, style);\n Object.keys(attributes).forEach(function (name) {\n var value = attributes[name];\n\n if (value === false) {\n element.removeAttribute(name);\n } else {\n element.setAttribute(name, value === true ? '' : value);\n }\n });\n });\n}\n\nfunction effect(_ref2) {\n var state = _ref2.state;\n var initialStyles = {\n popper: {\n position: state.options.strategy,\n left: '0',\n top: '0',\n margin: '0'\n },\n arrow: {\n position: 'absolute'\n },\n reference: {}\n };\n Object.assign(state.elements.popper.style, initialStyles.popper);\n state.styles = initialStyles;\n\n if (state.elements.arrow) {\n Object.assign(state.elements.arrow.style, initialStyles.arrow);\n }\n\n return function () {\n Object.keys(state.elements).forEach(function (name) {\n var element = state.elements[name];\n var attributes = state.attributes[name] || {};\n var styleProperties = Object.keys(state.styles.hasOwnProperty(name) ? state.styles[name] : initialStyles[name]); // Set all values to an empty string to unset them\n\n var style = styleProperties.reduce(function (style, property) {\n style[property] = '';\n return style;\n }, {}); // arrow is optional + virtual elements\n\n if (!isHTMLElement(element) || !getNodeName(element)) {\n return;\n }\n\n Object.assign(element.style, style);\n Object.keys(attributes).forEach(function (attribute) {\n element.removeAttribute(attribute);\n });\n });\n };\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'applyStyles',\n enabled: true,\n phase: 'write',\n fn: applyStyles,\n effect: effect,\n requires: ['computeStyles']\n};","import { auto } from \"../enums.js\";\nexport default function getBasePlacement(placement) {\n return placement.split('-')[0];\n}","export var max = Math.max;\nexport var min = Math.min;\nexport var round = Math.round;","export default function getUAString() {\n var uaData = navigator.userAgentData;\n\n if (uaData != null && uaData.brands && Array.isArray(uaData.brands)) {\n return uaData.brands.map(function (item) {\n return item.brand + \"/\" + item.version;\n }).join(' ');\n }\n\n return navigator.userAgent;\n}","import getUAString from \"../utils/userAgent.js\";\nexport default function isLayoutViewport() {\n return !/^((?!chrome|android).)*safari/i.test(getUAString());\n}","import { isElement, isHTMLElement } from \"./instanceOf.js\";\nimport { round } from \"../utils/math.js\";\nimport getWindow from \"./getWindow.js\";\nimport isLayoutViewport from \"./isLayoutViewport.js\";\nexport default function getBoundingClientRect(element, includeScale, isFixedStrategy) {\n if (includeScale === void 0) {\n includeScale = false;\n }\n\n if (isFixedStrategy === void 0) {\n isFixedStrategy = false;\n }\n\n var clientRect = element.getBoundingClientRect();\n var scaleX = 1;\n var scaleY = 1;\n\n if (includeScale && isHTMLElement(element)) {\n scaleX = element.offsetWidth > 0 ? round(clientRect.width) / element.offsetWidth || 1 : 1;\n scaleY = element.offsetHeight > 0 ? round(clientRect.height) / element.offsetHeight || 1 : 1;\n }\n\n var _ref = isElement(element) ? getWindow(element) : window,\n visualViewport = _ref.visualViewport;\n\n var addVisualOffsets = !isLayoutViewport() && isFixedStrategy;\n var x = (clientRect.left + (addVisualOffsets && visualViewport ? visualViewport.offsetLeft : 0)) / scaleX;\n var y = (clientRect.top + (addVisualOffsets && visualViewport ? visualViewport.offsetTop : 0)) / scaleY;\n var width = clientRect.width / scaleX;\n var height = clientRect.height / scaleY;\n return {\n width: width,\n height: height,\n top: y,\n right: x + width,\n bottom: y + height,\n left: x,\n x: x,\n y: y\n };\n}","import getBoundingClientRect from \"./getBoundingClientRect.js\"; // Returns the layout rect of an element relative to its offsetParent. Layout\n// means it doesn't take into account transforms.\n\nexport default function getLayoutRect(element) {\n var clientRect = getBoundingClientRect(element); // Use the clientRect sizes if it's not been transformed.\n // Fixes https://github.com/popperjs/popper-core/issues/1223\n\n var width = element.offsetWidth;\n var height = element.offsetHeight;\n\n if (Math.abs(clientRect.width - width) <= 1) {\n width = clientRect.width;\n }\n\n if (Math.abs(clientRect.height - height) <= 1) {\n height = clientRect.height;\n }\n\n return {\n x: element.offsetLeft,\n y: element.offsetTop,\n width: width,\n height: height\n };\n}","import { isShadowRoot } from \"./instanceOf.js\";\nexport default function contains(parent, child) {\n var rootNode = child.getRootNode && child.getRootNode(); // First, attempt with faster native method\n\n if (parent.contains(child)) {\n return true;\n } // then fallback to custom implementation with Shadow DOM support\n else if (rootNode && isShadowRoot(rootNode)) {\n var next = child;\n\n do {\n if (next && parent.isSameNode(next)) {\n return true;\n } // $FlowFixMe[prop-missing]: need a better way to handle this...\n\n\n next = next.parentNode || next.host;\n } while (next);\n } // Give up, the result is false\n\n\n return false;\n}","import getWindow from \"./getWindow.js\";\nexport default function getComputedStyle(element) {\n return getWindow(element).getComputedStyle(element);\n}","import getNodeName from \"./getNodeName.js\";\nexport default function isTableElement(element) {\n return ['table', 'td', 'th'].indexOf(getNodeName(element)) >= 0;\n}","import { isElement } from \"./instanceOf.js\";\nexport default function getDocumentElement(element) {\n // $FlowFixMe[incompatible-return]: assume body is always available\n return ((isElement(element) ? element.ownerDocument : // $FlowFixMe[prop-missing]\n element.document) || window.document).documentElement;\n}","import getNodeName from \"./getNodeName.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport { isShadowRoot } from \"./instanceOf.js\";\nexport default function getParentNode(element) {\n if (getNodeName(element) === 'html') {\n return element;\n }\n\n return (// this is a quicker (but less type safe) way to save quite some bytes from the bundle\n // $FlowFixMe[incompatible-return]\n // $FlowFixMe[prop-missing]\n element.assignedSlot || // step into the shadow DOM of the parent of a slotted node\n element.parentNode || ( // DOM Element detected\n isShadowRoot(element) ? element.host : null) || // ShadowRoot detected\n // $FlowFixMe[incompatible-call]: HTMLElement is a Node\n getDocumentElement(element) // fallback\n\n );\n}","import getWindow from \"./getWindow.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport getComputedStyle from \"./getComputedStyle.js\";\nimport { isHTMLElement, isShadowRoot } from \"./instanceOf.js\";\nimport isTableElement from \"./isTableElement.js\";\nimport getParentNode from \"./getParentNode.js\";\nimport getUAString from \"../utils/userAgent.js\";\n\nfunction getTrueOffsetParent(element) {\n if (!isHTMLElement(element) || // https://github.com/popperjs/popper-core/issues/837\n getComputedStyle(element).position === 'fixed') {\n return null;\n }\n\n return element.offsetParent;\n} // `.offsetParent` reports `null` for fixed elements, while absolute elements\n// return the containing block\n\n\nfunction getContainingBlock(element) {\n var isFirefox = /firefox/i.test(getUAString());\n var isIE = /Trident/i.test(getUAString());\n\n if (isIE && isHTMLElement(element)) {\n // In IE 9, 10 and 11 fixed elements containing block is always established by the viewport\n var elementCss = getComputedStyle(element);\n\n if (elementCss.position === 'fixed') {\n return null;\n }\n }\n\n var currentNode = getParentNode(element);\n\n if (isShadowRoot(currentNode)) {\n currentNode = currentNode.host;\n }\n\n while (isHTMLElement(currentNode) && ['html', 'body'].indexOf(getNodeName(currentNode)) < 0) {\n var css = getComputedStyle(currentNode); // This is non-exhaustive but covers the most common CSS properties that\n // create a containing block.\n // https://developer.mozilla.org/en-US/docs/Web/CSS/Containing_block#identifying_the_containing_block\n\n if (css.transform !== 'none' || css.perspective !== 'none' || css.contain === 'paint' || ['transform', 'perspective'].indexOf(css.willChange) !== -1 || isFirefox && css.willChange === 'filter' || isFirefox && css.filter && css.filter !== 'none') {\n return currentNode;\n } else {\n currentNode = currentNode.parentNode;\n }\n }\n\n return null;\n} // Gets the closest ancestor positioned element. Handles some edge cases,\n// such as table ancestors and cross browser bugs.\n\n\nexport default function getOffsetParent(element) {\n var window = getWindow(element);\n var offsetParent = getTrueOffsetParent(element);\n\n while (offsetParent && isTableElement(offsetParent) && getComputedStyle(offsetParent).position === 'static') {\n offsetParent = getTrueOffsetParent(offsetParent);\n }\n\n if (offsetParent && (getNodeName(offsetParent) === 'html' || getNodeName(offsetParent) === 'body' && getComputedStyle(offsetParent).position === 'static')) {\n return window;\n }\n\n return offsetParent || getContainingBlock(element) || window;\n}","export default function getMainAxisFromPlacement(placement) {\n return ['top', 'bottom'].indexOf(placement) >= 0 ? 'x' : 'y';\n}","import { max as mathMax, min as mathMin } from \"./math.js\";\nexport function within(min, value, max) {\n return mathMax(min, mathMin(value, max));\n}\nexport function withinMaxClamp(min, value, max) {\n var v = within(min, value, max);\n return v > max ? max : v;\n}","export default function getFreshSideObject() {\n return {\n top: 0,\n right: 0,\n bottom: 0,\n left: 0\n };\n}","import getFreshSideObject from \"./getFreshSideObject.js\";\nexport default function mergePaddingObject(paddingObject) {\n return Object.assign({}, getFreshSideObject(), paddingObject);\n}","export default function expandToHashMap(value, keys) {\n return keys.reduce(function (hashMap, key) {\n hashMap[key] = value;\n return hashMap;\n }, {});\n}","import getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getLayoutRect from \"../dom-utils/getLayoutRect.js\";\nimport contains from \"../dom-utils/contains.js\";\nimport getOffsetParent from \"../dom-utils/getOffsetParent.js\";\nimport getMainAxisFromPlacement from \"../utils/getMainAxisFromPlacement.js\";\nimport { within } from \"../utils/within.js\";\nimport mergePaddingObject from \"../utils/mergePaddingObject.js\";\nimport expandToHashMap from \"../utils/expandToHashMap.js\";\nimport { left, right, basePlacements, top, bottom } from \"../enums.js\"; // eslint-disable-next-line import/no-unused-modules\n\nvar toPaddingObject = function toPaddingObject(padding, state) {\n padding = typeof padding === 'function' ? padding(Object.assign({}, state.rects, {\n placement: state.placement\n })) : padding;\n return mergePaddingObject(typeof padding !== 'number' ? padding : expandToHashMap(padding, basePlacements));\n};\n\nfunction arrow(_ref) {\n var _state$modifiersData$;\n\n var state = _ref.state,\n name = _ref.name,\n options = _ref.options;\n var arrowElement = state.elements.arrow;\n var popperOffsets = state.modifiersData.popperOffsets;\n var basePlacement = getBasePlacement(state.placement);\n var axis = getMainAxisFromPlacement(basePlacement);\n var isVertical = [left, right].indexOf(basePlacement) >= 0;\n var len = isVertical ? 'height' : 'width';\n\n if (!arrowElement || !popperOffsets) {\n return;\n }\n\n var paddingObject = toPaddingObject(options.padding, state);\n var arrowRect = getLayoutRect(arrowElement);\n var minProp = axis === 'y' ? top : left;\n var maxProp = axis === 'y' ? bottom : right;\n var endDiff = state.rects.reference[len] + state.rects.reference[axis] - popperOffsets[axis] - state.rects.popper[len];\n var startDiff = popperOffsets[axis] - state.rects.reference[axis];\n var arrowOffsetParent = getOffsetParent(arrowElement);\n var clientSize = arrowOffsetParent ? axis === 'y' ? arrowOffsetParent.clientHeight || 0 : arrowOffsetParent.clientWidth || 0 : 0;\n var centerToReference = endDiff / 2 - startDiff / 2; // Make sure the arrow doesn't overflow the popper if the center point is\n // outside of the popper bounds\n\n var min = paddingObject[minProp];\n var max = clientSize - arrowRect[len] - paddingObject[maxProp];\n var center = clientSize / 2 - arrowRect[len] / 2 + centerToReference;\n var offset = within(min, center, max); // Prevents breaking syntax highlighting...\n\n var axisProp = axis;\n state.modifiersData[name] = (_state$modifiersData$ = {}, _state$modifiersData$[axisProp] = offset, _state$modifiersData$.centerOffset = offset - center, _state$modifiersData$);\n}\n\nfunction effect(_ref2) {\n var state = _ref2.state,\n options = _ref2.options;\n var _options$element = options.element,\n arrowElement = _options$element === void 0 ? '[data-popper-arrow]' : _options$element;\n\n if (arrowElement == null) {\n return;\n } // CSS selector\n\n\n if (typeof arrowElement === 'string') {\n arrowElement = state.elements.popper.querySelector(arrowElement);\n\n if (!arrowElement) {\n return;\n }\n }\n\n if (!contains(state.elements.popper, arrowElement)) {\n return;\n }\n\n state.elements.arrow = arrowElement;\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'arrow',\n enabled: true,\n phase: 'main',\n fn: arrow,\n effect: effect,\n requires: ['popperOffsets'],\n requiresIfExists: ['preventOverflow']\n};","export default function getVariation(placement) {\n return placement.split('-')[1];\n}","import { top, left, right, bottom, end } from \"../enums.js\";\nimport getOffsetParent from \"../dom-utils/getOffsetParent.js\";\nimport getWindow from \"../dom-utils/getWindow.js\";\nimport getDocumentElement from \"../dom-utils/getDocumentElement.js\";\nimport getComputedStyle from \"../dom-utils/getComputedStyle.js\";\nimport getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getVariation from \"../utils/getVariation.js\";\nimport { round } from \"../utils/math.js\"; // eslint-disable-next-line import/no-unused-modules\n\nvar unsetSides = {\n top: 'auto',\n right: 'auto',\n bottom: 'auto',\n left: 'auto'\n}; // Round the offsets to the nearest suitable subpixel based on the DPR.\n// Zooming can change the DPR, but it seems to report a value that will\n// cleanly divide the values into the appropriate subpixels.\n\nfunction roundOffsetsByDPR(_ref, win) {\n var x = _ref.x,\n y = _ref.y;\n var dpr = win.devicePixelRatio || 1;\n return {\n x: round(x * dpr) / dpr || 0,\n y: round(y * dpr) / dpr || 0\n };\n}\n\nexport function mapToStyles(_ref2) {\n var _Object$assign2;\n\n var popper = _ref2.popper,\n popperRect = _ref2.popperRect,\n placement = _ref2.placement,\n variation = _ref2.variation,\n offsets = _ref2.offsets,\n position = _ref2.position,\n gpuAcceleration = _ref2.gpuAcceleration,\n adaptive = _ref2.adaptive,\n roundOffsets = _ref2.roundOffsets,\n isFixed = _ref2.isFixed;\n var _offsets$x = offsets.x,\n x = _offsets$x === void 0 ? 0 : _offsets$x,\n _offsets$y = offsets.y,\n y = _offsets$y === void 0 ? 0 : _offsets$y;\n\n var _ref3 = typeof roundOffsets === 'function' ? roundOffsets({\n x: x,\n y: y\n }) : {\n x: x,\n y: y\n };\n\n x = _ref3.x;\n y = _ref3.y;\n var hasX = offsets.hasOwnProperty('x');\n var hasY = offsets.hasOwnProperty('y');\n var sideX = left;\n var sideY = top;\n var win = window;\n\n if (adaptive) {\n var offsetParent = getOffsetParent(popper);\n var heightProp = 'clientHeight';\n var widthProp = 'clientWidth';\n\n if (offsetParent === getWindow(popper)) {\n offsetParent = getDocumentElement(popper);\n\n if (getComputedStyle(offsetParent).position !== 'static' && position === 'absolute') {\n heightProp = 'scrollHeight';\n widthProp = 'scrollWidth';\n }\n } // $FlowFixMe[incompatible-cast]: force type refinement, we compare offsetParent with window above, but Flow doesn't detect it\n\n\n offsetParent = offsetParent;\n\n if (placement === top || (placement === left || placement === right) && variation === end) {\n sideY = bottom;\n var offsetY = isFixed && offsetParent === win && win.visualViewport ? win.visualViewport.height : // $FlowFixMe[prop-missing]\n offsetParent[heightProp];\n y -= offsetY - popperRect.height;\n y *= gpuAcceleration ? 1 : -1;\n }\n\n if (placement === left || (placement === top || placement === bottom) && variation === end) {\n sideX = right;\n var offsetX = isFixed && offsetParent === win && win.visualViewport ? win.visualViewport.width : // $FlowFixMe[prop-missing]\n offsetParent[widthProp];\n x -= offsetX - popperRect.width;\n x *= gpuAcceleration ? 1 : -1;\n }\n }\n\n var commonStyles = Object.assign({\n position: position\n }, adaptive && unsetSides);\n\n var _ref4 = roundOffsets === true ? roundOffsetsByDPR({\n x: x,\n y: y\n }, getWindow(popper)) : {\n x: x,\n y: y\n };\n\n x = _ref4.x;\n y = _ref4.y;\n\n if (gpuAcceleration) {\n var _Object$assign;\n\n return Object.assign({}, commonStyles, (_Object$assign = {}, _Object$assign[sideY] = hasY ? '0' : '', _Object$assign[sideX] = hasX ? '0' : '', _Object$assign.transform = (win.devicePixelRatio || 1) <= 1 ? \"translate(\" + x + \"px, \" + y + \"px)\" : \"translate3d(\" + x + \"px, \" + y + \"px, 0)\", _Object$assign));\n }\n\n return Object.assign({}, commonStyles, (_Object$assign2 = {}, _Object$assign2[sideY] = hasY ? y + \"px\" : '', _Object$assign2[sideX] = hasX ? x + \"px\" : '', _Object$assign2.transform = '', _Object$assign2));\n}\n\nfunction computeStyles(_ref5) {\n var state = _ref5.state,\n options = _ref5.options;\n var _options$gpuAccelerat = options.gpuAcceleration,\n gpuAcceleration = _options$gpuAccelerat === void 0 ? true : _options$gpuAccelerat,\n _options$adaptive = options.adaptive,\n adaptive = _options$adaptive === void 0 ? true : _options$adaptive,\n _options$roundOffsets = options.roundOffsets,\n roundOffsets = _options$roundOffsets === void 0 ? true : _options$roundOffsets;\n var commonStyles = {\n placement: getBasePlacement(state.placement),\n variation: getVariation(state.placement),\n popper: state.elements.popper,\n popperRect: state.rects.popper,\n gpuAcceleration: gpuAcceleration,\n isFixed: state.options.strategy === 'fixed'\n };\n\n if (state.modifiersData.popperOffsets != null) {\n state.styles.popper = Object.assign({}, state.styles.popper, mapToStyles(Object.assign({}, commonStyles, {\n offsets: state.modifiersData.popperOffsets,\n position: state.options.strategy,\n adaptive: adaptive,\n roundOffsets: roundOffsets\n })));\n }\n\n if (state.modifiersData.arrow != null) {\n state.styles.arrow = Object.assign({}, state.styles.arrow, mapToStyles(Object.assign({}, commonStyles, {\n offsets: state.modifiersData.arrow,\n position: 'absolute',\n adaptive: false,\n roundOffsets: roundOffsets\n })));\n }\n\n state.attributes.popper = Object.assign({}, state.attributes.popper, {\n 'data-popper-placement': state.placement\n });\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'computeStyles',\n enabled: true,\n phase: 'beforeWrite',\n fn: computeStyles,\n data: {}\n};","import getWindow from \"../dom-utils/getWindow.js\"; // eslint-disable-next-line import/no-unused-modules\n\nvar passive = {\n passive: true\n};\n\nfunction effect(_ref) {\n var state = _ref.state,\n instance = _ref.instance,\n options = _ref.options;\n var _options$scroll = options.scroll,\n scroll = _options$scroll === void 0 ? true : _options$scroll,\n _options$resize = options.resize,\n resize = _options$resize === void 0 ? true : _options$resize;\n var window = getWindow(state.elements.popper);\n var scrollParents = [].concat(state.scrollParents.reference, state.scrollParents.popper);\n\n if (scroll) {\n scrollParents.forEach(function (scrollParent) {\n scrollParent.addEventListener('scroll', instance.update, passive);\n });\n }\n\n if (resize) {\n window.addEventListener('resize', instance.update, passive);\n }\n\n return function () {\n if (scroll) {\n scrollParents.forEach(function (scrollParent) {\n scrollParent.removeEventListener('scroll', instance.update, passive);\n });\n }\n\n if (resize) {\n window.removeEventListener('resize', instance.update, passive);\n }\n };\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'eventListeners',\n enabled: true,\n phase: 'write',\n fn: function fn() {},\n effect: effect,\n data: {}\n};","var hash = {\n left: 'right',\n right: 'left',\n bottom: 'top',\n top: 'bottom'\n};\nexport default function getOppositePlacement(placement) {\n return placement.replace(/left|right|bottom|top/g, function (matched) {\n return hash[matched];\n });\n}","var hash = {\n start: 'end',\n end: 'start'\n};\nexport default function getOppositeVariationPlacement(placement) {\n return placement.replace(/start|end/g, function (matched) {\n return hash[matched];\n });\n}","import getWindow from \"./getWindow.js\";\nexport default function getWindowScroll(node) {\n var win = getWindow(node);\n var scrollLeft = win.pageXOffset;\n var scrollTop = win.pageYOffset;\n return {\n scrollLeft: scrollLeft,\n scrollTop: scrollTop\n };\n}","import getBoundingClientRect from \"./getBoundingClientRect.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport getWindowScroll from \"./getWindowScroll.js\";\nexport default function getWindowScrollBarX(element) {\n // If has a CSS width greater than the viewport, then this will be\n // incorrect for RTL.\n // Popper 1 is broken in this case and never had a bug report so let's assume\n // it's not an issue. I don't think anyone ever specifies width on \n // anyway.\n // Browsers where the left scrollbar doesn't cause an issue report `0` for\n // this (e.g. Edge 2019, IE11, Safari)\n return getBoundingClientRect(getDocumentElement(element)).left + getWindowScroll(element).scrollLeft;\n}","import getWindow from \"./getWindow.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport getWindowScrollBarX from \"./getWindowScrollBarX.js\";\nimport isLayoutViewport from \"./isLayoutViewport.js\";\nexport default function getViewportRect(element, strategy) {\n var win = getWindow(element);\n var html = getDocumentElement(element);\n var visualViewport = win.visualViewport;\n var width = html.clientWidth;\n var height = html.clientHeight;\n var x = 0;\n var y = 0;\n\n if (visualViewport) {\n width = visualViewport.width;\n height = visualViewport.height;\n var layoutViewport = isLayoutViewport();\n\n if (layoutViewport || !layoutViewport && strategy === 'fixed') {\n x = visualViewport.offsetLeft;\n y = visualViewport.offsetTop;\n }\n }\n\n return {\n width: width,\n height: height,\n x: x + getWindowScrollBarX(element),\n y: y\n };\n}","import getDocumentElement from \"./getDocumentElement.js\";\nimport getComputedStyle from \"./getComputedStyle.js\";\nimport getWindowScrollBarX from \"./getWindowScrollBarX.js\";\nimport getWindowScroll from \"./getWindowScroll.js\";\nimport { max } from \"../utils/math.js\"; // Gets the entire size of the scrollable document area, even extending outside\n// of the `` and `` rect bounds if horizontally scrollable\n\nexport default function getDocumentRect(element) {\n var _element$ownerDocumen;\n\n var html = getDocumentElement(element);\n var winScroll = getWindowScroll(element);\n var body = (_element$ownerDocumen = element.ownerDocument) == null ? void 0 : _element$ownerDocumen.body;\n var width = max(html.scrollWidth, html.clientWidth, body ? body.scrollWidth : 0, body ? body.clientWidth : 0);\n var height = max(html.scrollHeight, html.clientHeight, body ? body.scrollHeight : 0, body ? body.clientHeight : 0);\n var x = -winScroll.scrollLeft + getWindowScrollBarX(element);\n var y = -winScroll.scrollTop;\n\n if (getComputedStyle(body || html).direction === 'rtl') {\n x += max(html.clientWidth, body ? body.clientWidth : 0) - width;\n }\n\n return {\n width: width,\n height: height,\n x: x,\n y: y\n };\n}","import getComputedStyle from \"./getComputedStyle.js\";\nexport default function isScrollParent(element) {\n // Firefox wants us to check `-x` and `-y` variations as well\n var _getComputedStyle = getComputedStyle(element),\n overflow = _getComputedStyle.overflow,\n overflowX = _getComputedStyle.overflowX,\n overflowY = _getComputedStyle.overflowY;\n\n return /auto|scroll|overlay|hidden/.test(overflow + overflowY + overflowX);\n}","import getParentNode from \"./getParentNode.js\";\nimport isScrollParent from \"./isScrollParent.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport { isHTMLElement } from \"./instanceOf.js\";\nexport default function getScrollParent(node) {\n if (['html', 'body', '#document'].indexOf(getNodeName(node)) >= 0) {\n // $FlowFixMe[incompatible-return]: assume body is always available\n return node.ownerDocument.body;\n }\n\n if (isHTMLElement(node) && isScrollParent(node)) {\n return node;\n }\n\n return getScrollParent(getParentNode(node));\n}","import getScrollParent from \"./getScrollParent.js\";\nimport getParentNode from \"./getParentNode.js\";\nimport getWindow from \"./getWindow.js\";\nimport isScrollParent from \"./isScrollParent.js\";\n/*\ngiven a DOM element, return the list of all scroll parents, up the list of ancesors\nuntil we get to the top window object. This list is what we attach scroll listeners\nto, because if any of these parent elements scroll, we'll need to re-calculate the\nreference element's position.\n*/\n\nexport default function listScrollParents(element, list) {\n var _element$ownerDocumen;\n\n if (list === void 0) {\n list = [];\n }\n\n var scrollParent = getScrollParent(element);\n var isBody = scrollParent === ((_element$ownerDocumen = element.ownerDocument) == null ? void 0 : _element$ownerDocumen.body);\n var win = getWindow(scrollParent);\n var target = isBody ? [win].concat(win.visualViewport || [], isScrollParent(scrollParent) ? scrollParent : []) : scrollParent;\n var updatedList = list.concat(target);\n return isBody ? updatedList : // $FlowFixMe[incompatible-call]: isBody tells us target will be an HTMLElement here\n updatedList.concat(listScrollParents(getParentNode(target)));\n}","export default function rectToClientRect(rect) {\n return Object.assign({}, rect, {\n left: rect.x,\n top: rect.y,\n right: rect.x + rect.width,\n bottom: rect.y + rect.height\n });\n}","import { viewport } from \"../enums.js\";\nimport getViewportRect from \"./getViewportRect.js\";\nimport getDocumentRect from \"./getDocumentRect.js\";\nimport listScrollParents from \"./listScrollParents.js\";\nimport getOffsetParent from \"./getOffsetParent.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport getComputedStyle from \"./getComputedStyle.js\";\nimport { isElement, isHTMLElement } from \"./instanceOf.js\";\nimport getBoundingClientRect from \"./getBoundingClientRect.js\";\nimport getParentNode from \"./getParentNode.js\";\nimport contains from \"./contains.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport rectToClientRect from \"../utils/rectToClientRect.js\";\nimport { max, min } from \"../utils/math.js\";\n\nfunction getInnerBoundingClientRect(element, strategy) {\n var rect = getBoundingClientRect(element, false, strategy === 'fixed');\n rect.top = rect.top + element.clientTop;\n rect.left = rect.left + element.clientLeft;\n rect.bottom = rect.top + element.clientHeight;\n rect.right = rect.left + element.clientWidth;\n rect.width = element.clientWidth;\n rect.height = element.clientHeight;\n rect.x = rect.left;\n rect.y = rect.top;\n return rect;\n}\n\nfunction getClientRectFromMixedType(element, clippingParent, strategy) {\n return clippingParent === viewport ? rectToClientRect(getViewportRect(element, strategy)) : isElement(clippingParent) ? getInnerBoundingClientRect(clippingParent, strategy) : rectToClientRect(getDocumentRect(getDocumentElement(element)));\n} // A \"clipping parent\" is an overflowable container with the characteristic of\n// clipping (or hiding) overflowing elements with a position different from\n// `initial`\n\n\nfunction getClippingParents(element) {\n var clippingParents = listScrollParents(getParentNode(element));\n var canEscapeClipping = ['absolute', 'fixed'].indexOf(getComputedStyle(element).position) >= 0;\n var clipperElement = canEscapeClipping && isHTMLElement(element) ? getOffsetParent(element) : element;\n\n if (!isElement(clipperElement)) {\n return [];\n } // $FlowFixMe[incompatible-return]: https://github.com/facebook/flow/issues/1414\n\n\n return clippingParents.filter(function (clippingParent) {\n return isElement(clippingParent) && contains(clippingParent, clipperElement) && getNodeName(clippingParent) !== 'body';\n });\n} // Gets the maximum area that the element is visible in due to any number of\n// clipping parents\n\n\nexport default function getClippingRect(element, boundary, rootBoundary, strategy) {\n var mainClippingParents = boundary === 'clippingParents' ? getClippingParents(element) : [].concat(boundary);\n var clippingParents = [].concat(mainClippingParents, [rootBoundary]);\n var firstClippingParent = clippingParents[0];\n var clippingRect = clippingParents.reduce(function (accRect, clippingParent) {\n var rect = getClientRectFromMixedType(element, clippingParent, strategy);\n accRect.top = max(rect.top, accRect.top);\n accRect.right = min(rect.right, accRect.right);\n accRect.bottom = min(rect.bottom, accRect.bottom);\n accRect.left = max(rect.left, accRect.left);\n return accRect;\n }, getClientRectFromMixedType(element, firstClippingParent, strategy));\n clippingRect.width = clippingRect.right - clippingRect.left;\n clippingRect.height = clippingRect.bottom - clippingRect.top;\n clippingRect.x = clippingRect.left;\n clippingRect.y = clippingRect.top;\n return clippingRect;\n}","import getBasePlacement from \"./getBasePlacement.js\";\nimport getVariation from \"./getVariation.js\";\nimport getMainAxisFromPlacement from \"./getMainAxisFromPlacement.js\";\nimport { top, right, bottom, left, start, end } from \"../enums.js\";\nexport default function computeOffsets(_ref) {\n var reference = _ref.reference,\n element = _ref.element,\n placement = _ref.placement;\n var basePlacement = placement ? getBasePlacement(placement) : null;\n var variation = placement ? getVariation(placement) : null;\n var commonX = reference.x + reference.width / 2 - element.width / 2;\n var commonY = reference.y + reference.height / 2 - element.height / 2;\n var offsets;\n\n switch (basePlacement) {\n case top:\n offsets = {\n x: commonX,\n y: reference.y - element.height\n };\n break;\n\n case bottom:\n offsets = {\n x: commonX,\n y: reference.y + reference.height\n };\n break;\n\n case right:\n offsets = {\n x: reference.x + reference.width,\n y: commonY\n };\n break;\n\n case left:\n offsets = {\n x: reference.x - element.width,\n y: commonY\n };\n break;\n\n default:\n offsets = {\n x: reference.x,\n y: reference.y\n };\n }\n\n var mainAxis = basePlacement ? getMainAxisFromPlacement(basePlacement) : null;\n\n if (mainAxis != null) {\n var len = mainAxis === 'y' ? 'height' : 'width';\n\n switch (variation) {\n case start:\n offsets[mainAxis] = offsets[mainAxis] - (reference[len] / 2 - element[len] / 2);\n break;\n\n case end:\n offsets[mainAxis] = offsets[mainAxis] + (reference[len] / 2 - element[len] / 2);\n break;\n\n default:\n }\n }\n\n return offsets;\n}","import getClippingRect from \"../dom-utils/getClippingRect.js\";\nimport getDocumentElement from \"../dom-utils/getDocumentElement.js\";\nimport getBoundingClientRect from \"../dom-utils/getBoundingClientRect.js\";\nimport computeOffsets from \"./computeOffsets.js\";\nimport rectToClientRect from \"./rectToClientRect.js\";\nimport { clippingParents, reference, popper, bottom, top, right, basePlacements, viewport } from \"../enums.js\";\nimport { isElement } from \"../dom-utils/instanceOf.js\";\nimport mergePaddingObject from \"./mergePaddingObject.js\";\nimport expandToHashMap from \"./expandToHashMap.js\"; // eslint-disable-next-line import/no-unused-modules\n\nexport default function detectOverflow(state, options) {\n if (options === void 0) {\n options = {};\n }\n\n var _options = options,\n _options$placement = _options.placement,\n placement = _options$placement === void 0 ? state.placement : _options$placement,\n _options$strategy = _options.strategy,\n strategy = _options$strategy === void 0 ? state.strategy : _options$strategy,\n _options$boundary = _options.boundary,\n boundary = _options$boundary === void 0 ? clippingParents : _options$boundary,\n _options$rootBoundary = _options.rootBoundary,\n rootBoundary = _options$rootBoundary === void 0 ? viewport : _options$rootBoundary,\n _options$elementConte = _options.elementContext,\n elementContext = _options$elementConte === void 0 ? popper : _options$elementConte,\n _options$altBoundary = _options.altBoundary,\n altBoundary = _options$altBoundary === void 0 ? false : _options$altBoundary,\n _options$padding = _options.padding,\n padding = _options$padding === void 0 ? 0 : _options$padding;\n var paddingObject = mergePaddingObject(typeof padding !== 'number' ? padding : expandToHashMap(padding, basePlacements));\n var altContext = elementContext === popper ? reference : popper;\n var popperRect = state.rects.popper;\n var element = state.elements[altBoundary ? altContext : elementContext];\n var clippingClientRect = getClippingRect(isElement(element) ? element : element.contextElement || getDocumentElement(state.elements.popper), boundary, rootBoundary, strategy);\n var referenceClientRect = getBoundingClientRect(state.elements.reference);\n var popperOffsets = computeOffsets({\n reference: referenceClientRect,\n element: popperRect,\n strategy: 'absolute',\n placement: placement\n });\n var popperClientRect = rectToClientRect(Object.assign({}, popperRect, popperOffsets));\n var elementClientRect = elementContext === popper ? popperClientRect : referenceClientRect; // positive = overflowing the clipping rect\n // 0 or negative = within the clipping rect\n\n var overflowOffsets = {\n top: clippingClientRect.top - elementClientRect.top + paddingObject.top,\n bottom: elementClientRect.bottom - clippingClientRect.bottom + paddingObject.bottom,\n left: clippingClientRect.left - elementClientRect.left + paddingObject.left,\n right: elementClientRect.right - clippingClientRect.right + paddingObject.right\n };\n var offsetData = state.modifiersData.offset; // Offsets can be applied only to the popper element\n\n if (elementContext === popper && offsetData) {\n var offset = offsetData[placement];\n Object.keys(overflowOffsets).forEach(function (key) {\n var multiply = [right, bottom].indexOf(key) >= 0 ? 1 : -1;\n var axis = [top, bottom].indexOf(key) >= 0 ? 'y' : 'x';\n overflowOffsets[key] += offset[axis] * multiply;\n });\n }\n\n return overflowOffsets;\n}","import getVariation from \"./getVariation.js\";\nimport { variationPlacements, basePlacements, placements as allPlacements } from \"../enums.js\";\nimport detectOverflow from \"./detectOverflow.js\";\nimport getBasePlacement from \"./getBasePlacement.js\";\nexport default function computeAutoPlacement(state, options) {\n if (options === void 0) {\n options = {};\n }\n\n var _options = options,\n placement = _options.placement,\n boundary = _options.boundary,\n rootBoundary = _options.rootBoundary,\n padding = _options.padding,\n flipVariations = _options.flipVariations,\n _options$allowedAutoP = _options.allowedAutoPlacements,\n allowedAutoPlacements = _options$allowedAutoP === void 0 ? allPlacements : _options$allowedAutoP;\n var variation = getVariation(placement);\n var placements = variation ? flipVariations ? variationPlacements : variationPlacements.filter(function (placement) {\n return getVariation(placement) === variation;\n }) : basePlacements;\n var allowedPlacements = placements.filter(function (placement) {\n return allowedAutoPlacements.indexOf(placement) >= 0;\n });\n\n if (allowedPlacements.length === 0) {\n allowedPlacements = placements;\n } // $FlowFixMe[incompatible-type]: Flow seems to have problems with two array unions...\n\n\n var overflows = allowedPlacements.reduce(function (acc, placement) {\n acc[placement] = detectOverflow(state, {\n placement: placement,\n boundary: boundary,\n rootBoundary: rootBoundary,\n padding: padding\n })[getBasePlacement(placement)];\n return acc;\n }, {});\n return Object.keys(overflows).sort(function (a, b) {\n return overflows[a] - overflows[b];\n });\n}","import getOppositePlacement from \"../utils/getOppositePlacement.js\";\nimport getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getOppositeVariationPlacement from \"../utils/getOppositeVariationPlacement.js\";\nimport detectOverflow from \"../utils/detectOverflow.js\";\nimport computeAutoPlacement from \"../utils/computeAutoPlacement.js\";\nimport { bottom, top, start, right, left, auto } from \"../enums.js\";\nimport getVariation from \"../utils/getVariation.js\"; // eslint-disable-next-line import/no-unused-modules\n\nfunction getExpandedFallbackPlacements(placement) {\n if (getBasePlacement(placement) === auto) {\n return [];\n }\n\n var oppositePlacement = getOppositePlacement(placement);\n return [getOppositeVariationPlacement(placement), oppositePlacement, getOppositeVariationPlacement(oppositePlacement)];\n}\n\nfunction flip(_ref) {\n var state = _ref.state,\n options = _ref.options,\n name = _ref.name;\n\n if (state.modifiersData[name]._skip) {\n return;\n }\n\n var _options$mainAxis = options.mainAxis,\n checkMainAxis = _options$mainAxis === void 0 ? true : _options$mainAxis,\n _options$altAxis = options.altAxis,\n checkAltAxis = _options$altAxis === void 0 ? true : _options$altAxis,\n specifiedFallbackPlacements = options.fallbackPlacements,\n padding = options.padding,\n boundary = options.boundary,\n rootBoundary = options.rootBoundary,\n altBoundary = options.altBoundary,\n _options$flipVariatio = options.flipVariations,\n flipVariations = _options$flipVariatio === void 0 ? true : _options$flipVariatio,\n allowedAutoPlacements = options.allowedAutoPlacements;\n var preferredPlacement = state.options.placement;\n var basePlacement = getBasePlacement(preferredPlacement);\n var isBasePlacement = basePlacement === preferredPlacement;\n var fallbackPlacements = specifiedFallbackPlacements || (isBasePlacement || !flipVariations ? [getOppositePlacement(preferredPlacement)] : getExpandedFallbackPlacements(preferredPlacement));\n var placements = [preferredPlacement].concat(fallbackPlacements).reduce(function (acc, placement) {\n return acc.concat(getBasePlacement(placement) === auto ? computeAutoPlacement(state, {\n placement: placement,\n boundary: boundary,\n rootBoundary: rootBoundary,\n padding: padding,\n flipVariations: flipVariations,\n allowedAutoPlacements: allowedAutoPlacements\n }) : placement);\n }, []);\n var referenceRect = state.rects.reference;\n var popperRect = state.rects.popper;\n var checksMap = new Map();\n var makeFallbackChecks = true;\n var firstFittingPlacement = placements[0];\n\n for (var i = 0; i < placements.length; i++) {\n var placement = placements[i];\n\n var _basePlacement = getBasePlacement(placement);\n\n var isStartVariation = getVariation(placement) === start;\n var isVertical = [top, bottom].indexOf(_basePlacement) >= 0;\n var len = isVertical ? 'width' : 'height';\n var overflow = detectOverflow(state, {\n placement: placement,\n boundary: boundary,\n rootBoundary: rootBoundary,\n altBoundary: altBoundary,\n padding: padding\n });\n var mainVariationSide = isVertical ? isStartVariation ? right : left : isStartVariation ? bottom : top;\n\n if (referenceRect[len] > popperRect[len]) {\n mainVariationSide = getOppositePlacement(mainVariationSide);\n }\n\n var altVariationSide = getOppositePlacement(mainVariationSide);\n var checks = [];\n\n if (checkMainAxis) {\n checks.push(overflow[_basePlacement] <= 0);\n }\n\n if (checkAltAxis) {\n checks.push(overflow[mainVariationSide] <= 0, overflow[altVariationSide] <= 0);\n }\n\n if (checks.every(function (check) {\n return check;\n })) {\n firstFittingPlacement = placement;\n makeFallbackChecks = false;\n break;\n }\n\n checksMap.set(placement, checks);\n }\n\n if (makeFallbackChecks) {\n // `2` may be desired in some cases – research later\n var numberOfChecks = flipVariations ? 3 : 1;\n\n var _loop = function _loop(_i) {\n var fittingPlacement = placements.find(function (placement) {\n var checks = checksMap.get(placement);\n\n if (checks) {\n return checks.slice(0, _i).every(function (check) {\n return check;\n });\n }\n });\n\n if (fittingPlacement) {\n firstFittingPlacement = fittingPlacement;\n return \"break\";\n }\n };\n\n for (var _i = numberOfChecks; _i > 0; _i--) {\n var _ret = _loop(_i);\n\n if (_ret === \"break\") break;\n }\n }\n\n if (state.placement !== firstFittingPlacement) {\n state.modifiersData[name]._skip = true;\n state.placement = firstFittingPlacement;\n state.reset = true;\n }\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'flip',\n enabled: true,\n phase: 'main',\n fn: flip,\n requiresIfExists: ['offset'],\n data: {\n _skip: false\n }\n};","import { top, bottom, left, right } from \"../enums.js\";\nimport detectOverflow from \"../utils/detectOverflow.js\";\n\nfunction getSideOffsets(overflow, rect, preventedOffsets) {\n if (preventedOffsets === void 0) {\n preventedOffsets = {\n x: 0,\n y: 0\n };\n }\n\n return {\n top: overflow.top - rect.height - preventedOffsets.y,\n right: overflow.right - rect.width + preventedOffsets.x,\n bottom: overflow.bottom - rect.height + preventedOffsets.y,\n left: overflow.left - rect.width - preventedOffsets.x\n };\n}\n\nfunction isAnySideFullyClipped(overflow) {\n return [top, right, bottom, left].some(function (side) {\n return overflow[side] >= 0;\n });\n}\n\nfunction hide(_ref) {\n var state = _ref.state,\n name = _ref.name;\n var referenceRect = state.rects.reference;\n var popperRect = state.rects.popper;\n var preventedOffsets = state.modifiersData.preventOverflow;\n var referenceOverflow = detectOverflow(state, {\n elementContext: 'reference'\n });\n var popperAltOverflow = detectOverflow(state, {\n altBoundary: true\n });\n var referenceClippingOffsets = getSideOffsets(referenceOverflow, referenceRect);\n var popperEscapeOffsets = getSideOffsets(popperAltOverflow, popperRect, preventedOffsets);\n var isReferenceHidden = isAnySideFullyClipped(referenceClippingOffsets);\n var hasPopperEscaped = isAnySideFullyClipped(popperEscapeOffsets);\n state.modifiersData[name] = {\n referenceClippingOffsets: referenceClippingOffsets,\n popperEscapeOffsets: popperEscapeOffsets,\n isReferenceHidden: isReferenceHidden,\n hasPopperEscaped: hasPopperEscaped\n };\n state.attributes.popper = Object.assign({}, state.attributes.popper, {\n 'data-popper-reference-hidden': isReferenceHidden,\n 'data-popper-escaped': hasPopperEscaped\n });\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'hide',\n enabled: true,\n phase: 'main',\n requiresIfExists: ['preventOverflow'],\n fn: hide\n};","import getBasePlacement from \"../utils/getBasePlacement.js\";\nimport { top, left, right, placements } from \"../enums.js\"; // eslint-disable-next-line import/no-unused-modules\n\nexport function distanceAndSkiddingToXY(placement, rects, offset) {\n var basePlacement = getBasePlacement(placement);\n var invertDistance = [left, top].indexOf(basePlacement) >= 0 ? -1 : 1;\n\n var _ref = typeof offset === 'function' ? offset(Object.assign({}, rects, {\n placement: placement\n })) : offset,\n skidding = _ref[0],\n distance = _ref[1];\n\n skidding = skidding || 0;\n distance = (distance || 0) * invertDistance;\n return [left, right].indexOf(basePlacement) >= 0 ? {\n x: distance,\n y: skidding\n } : {\n x: skidding,\n y: distance\n };\n}\n\nfunction offset(_ref2) {\n var state = _ref2.state,\n options = _ref2.options,\n name = _ref2.name;\n var _options$offset = options.offset,\n offset = _options$offset === void 0 ? [0, 0] : _options$offset;\n var data = placements.reduce(function (acc, placement) {\n acc[placement] = distanceAndSkiddingToXY(placement, state.rects, offset);\n return acc;\n }, {});\n var _data$state$placement = data[state.placement],\n x = _data$state$placement.x,\n y = _data$state$placement.y;\n\n if (state.modifiersData.popperOffsets != null) {\n state.modifiersData.popperOffsets.x += x;\n state.modifiersData.popperOffsets.y += y;\n }\n\n state.modifiersData[name] = data;\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'offset',\n enabled: true,\n phase: 'main',\n requires: ['popperOffsets'],\n fn: offset\n};","import computeOffsets from \"../utils/computeOffsets.js\";\n\nfunction popperOffsets(_ref) {\n var state = _ref.state,\n name = _ref.name;\n // Offsets are the actual position the popper needs to have to be\n // properly positioned near its reference element\n // This is the most basic placement, and will be adjusted by\n // the modifiers in the next step\n state.modifiersData[name] = computeOffsets({\n reference: state.rects.reference,\n element: state.rects.popper,\n strategy: 'absolute',\n placement: state.placement\n });\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'popperOffsets',\n enabled: true,\n phase: 'read',\n fn: popperOffsets,\n data: {}\n};","export default function getAltAxis(axis) {\n return axis === 'x' ? 'y' : 'x';\n}","import { top, left, right, bottom, start } from \"../enums.js\";\nimport getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getMainAxisFromPlacement from \"../utils/getMainAxisFromPlacement.js\";\nimport getAltAxis from \"../utils/getAltAxis.js\";\nimport { within, withinMaxClamp } from \"../utils/within.js\";\nimport getLayoutRect from \"../dom-utils/getLayoutRect.js\";\nimport getOffsetParent from \"../dom-utils/getOffsetParent.js\";\nimport detectOverflow from \"../utils/detectOverflow.js\";\nimport getVariation from \"../utils/getVariation.js\";\nimport getFreshSideObject from \"../utils/getFreshSideObject.js\";\nimport { min as mathMin, max as mathMax } from \"../utils/math.js\";\n\nfunction preventOverflow(_ref) {\n var state = _ref.state,\n options = _ref.options,\n name = _ref.name;\n var _options$mainAxis = options.mainAxis,\n checkMainAxis = _options$mainAxis === void 0 ? true : _options$mainAxis,\n _options$altAxis = options.altAxis,\n checkAltAxis = _options$altAxis === void 0 ? false : _options$altAxis,\n boundary = options.boundary,\n rootBoundary = options.rootBoundary,\n altBoundary = options.altBoundary,\n padding = options.padding,\n _options$tether = options.tether,\n tether = _options$tether === void 0 ? true : _options$tether,\n _options$tetherOffset = options.tetherOffset,\n tetherOffset = _options$tetherOffset === void 0 ? 0 : _options$tetherOffset;\n var overflow = detectOverflow(state, {\n boundary: boundary,\n rootBoundary: rootBoundary,\n padding: padding,\n altBoundary: altBoundary\n });\n var basePlacement = getBasePlacement(state.placement);\n var variation = getVariation(state.placement);\n var isBasePlacement = !variation;\n var mainAxis = getMainAxisFromPlacement(basePlacement);\n var altAxis = getAltAxis(mainAxis);\n var popperOffsets = state.modifiersData.popperOffsets;\n var referenceRect = state.rects.reference;\n var popperRect = state.rects.popper;\n var tetherOffsetValue = typeof tetherOffset === 'function' ? tetherOffset(Object.assign({}, state.rects, {\n placement: state.placement\n })) : tetherOffset;\n var normalizedTetherOffsetValue = typeof tetherOffsetValue === 'number' ? {\n mainAxis: tetherOffsetValue,\n altAxis: tetherOffsetValue\n } : Object.assign({\n mainAxis: 0,\n altAxis: 0\n }, tetherOffsetValue);\n var offsetModifierState = state.modifiersData.offset ? state.modifiersData.offset[state.placement] : null;\n var data = {\n x: 0,\n y: 0\n };\n\n if (!popperOffsets) {\n return;\n }\n\n if (checkMainAxis) {\n var _offsetModifierState$;\n\n var mainSide = mainAxis === 'y' ? top : left;\n var altSide = mainAxis === 'y' ? bottom : right;\n var len = mainAxis === 'y' ? 'height' : 'width';\n var offset = popperOffsets[mainAxis];\n var min = offset + overflow[mainSide];\n var max = offset - overflow[altSide];\n var additive = tether ? -popperRect[len] / 2 : 0;\n var minLen = variation === start ? referenceRect[len] : popperRect[len];\n var maxLen = variation === start ? -popperRect[len] : -referenceRect[len]; // We need to include the arrow in the calculation so the arrow doesn't go\n // outside the reference bounds\n\n var arrowElement = state.elements.arrow;\n var arrowRect = tether && arrowElement ? getLayoutRect(arrowElement) : {\n width: 0,\n height: 0\n };\n var arrowPaddingObject = state.modifiersData['arrow#persistent'] ? state.modifiersData['arrow#persistent'].padding : getFreshSideObject();\n var arrowPaddingMin = arrowPaddingObject[mainSide];\n var arrowPaddingMax = arrowPaddingObject[altSide]; // If the reference length is smaller than the arrow length, we don't want\n // to include its full size in the calculation. If the reference is small\n // and near the edge of a boundary, the popper can overflow even if the\n // reference is not overflowing as well (e.g. virtual elements with no\n // width or height)\n\n var arrowLen = within(0, referenceRect[len], arrowRect[len]);\n var minOffset = isBasePlacement ? referenceRect[len] / 2 - additive - arrowLen - arrowPaddingMin - normalizedTetherOffsetValue.mainAxis : minLen - arrowLen - arrowPaddingMin - normalizedTetherOffsetValue.mainAxis;\n var maxOffset = isBasePlacement ? -referenceRect[len] / 2 + additive + arrowLen + arrowPaddingMax + normalizedTetherOffsetValue.mainAxis : maxLen + arrowLen + arrowPaddingMax + normalizedTetherOffsetValue.mainAxis;\n var arrowOffsetParent = state.elements.arrow && getOffsetParent(state.elements.arrow);\n var clientOffset = arrowOffsetParent ? mainAxis === 'y' ? arrowOffsetParent.clientTop || 0 : arrowOffsetParent.clientLeft || 0 : 0;\n var offsetModifierValue = (_offsetModifierState$ = offsetModifierState == null ? void 0 : offsetModifierState[mainAxis]) != null ? _offsetModifierState$ : 0;\n var tetherMin = offset + minOffset - offsetModifierValue - clientOffset;\n var tetherMax = offset + maxOffset - offsetModifierValue;\n var preventedOffset = within(tether ? mathMin(min, tetherMin) : min, offset, tether ? mathMax(max, tetherMax) : max);\n popperOffsets[mainAxis] = preventedOffset;\n data[mainAxis] = preventedOffset - offset;\n }\n\n if (checkAltAxis) {\n var _offsetModifierState$2;\n\n var _mainSide = mainAxis === 'x' ? top : left;\n\n var _altSide = mainAxis === 'x' ? bottom : right;\n\n var _offset = popperOffsets[altAxis];\n\n var _len = altAxis === 'y' ? 'height' : 'width';\n\n var _min = _offset + overflow[_mainSide];\n\n var _max = _offset - overflow[_altSide];\n\n var isOriginSide = [top, left].indexOf(basePlacement) !== -1;\n\n var _offsetModifierValue = (_offsetModifierState$2 = offsetModifierState == null ? void 0 : offsetModifierState[altAxis]) != null ? _offsetModifierState$2 : 0;\n\n var _tetherMin = isOriginSide ? _min : _offset - referenceRect[_len] - popperRect[_len] - _offsetModifierValue + normalizedTetherOffsetValue.altAxis;\n\n var _tetherMax = isOriginSide ? _offset + referenceRect[_len] + popperRect[_len] - _offsetModifierValue - normalizedTetherOffsetValue.altAxis : _max;\n\n var _preventedOffset = tether && isOriginSide ? withinMaxClamp(_tetherMin, _offset, _tetherMax) : within(tether ? _tetherMin : _min, _offset, tether ? _tetherMax : _max);\n\n popperOffsets[altAxis] = _preventedOffset;\n data[altAxis] = _preventedOffset - _offset;\n }\n\n state.modifiersData[name] = data;\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'preventOverflow',\n enabled: true,\n phase: 'main',\n fn: preventOverflow,\n requiresIfExists: ['offset']\n};","export default function getHTMLElementScroll(element) {\n return {\n scrollLeft: element.scrollLeft,\n scrollTop: element.scrollTop\n };\n}","import getWindowScroll from \"./getWindowScroll.js\";\nimport getWindow from \"./getWindow.js\";\nimport { isHTMLElement } from \"./instanceOf.js\";\nimport getHTMLElementScroll from \"./getHTMLElementScroll.js\";\nexport default function getNodeScroll(node) {\n if (node === getWindow(node) || !isHTMLElement(node)) {\n return getWindowScroll(node);\n } else {\n return getHTMLElementScroll(node);\n }\n}","import getBoundingClientRect from \"./getBoundingClientRect.js\";\nimport getNodeScroll from \"./getNodeScroll.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport { isHTMLElement } from \"./instanceOf.js\";\nimport getWindowScrollBarX from \"./getWindowScrollBarX.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport isScrollParent from \"./isScrollParent.js\";\nimport { round } from \"../utils/math.js\";\n\nfunction isElementScaled(element) {\n var rect = element.getBoundingClientRect();\n var scaleX = round(rect.width) / element.offsetWidth || 1;\n var scaleY = round(rect.height) / element.offsetHeight || 1;\n return scaleX !== 1 || scaleY !== 1;\n} // Returns the composite rect of an element relative to its offsetParent.\n// Composite means it takes into account transforms as well as layout.\n\n\nexport default function getCompositeRect(elementOrVirtualElement, offsetParent, isFixed) {\n if (isFixed === void 0) {\n isFixed = false;\n }\n\n var isOffsetParentAnElement = isHTMLElement(offsetParent);\n var offsetParentIsScaled = isHTMLElement(offsetParent) && isElementScaled(offsetParent);\n var documentElement = getDocumentElement(offsetParent);\n var rect = getBoundingClientRect(elementOrVirtualElement, offsetParentIsScaled, isFixed);\n var scroll = {\n scrollLeft: 0,\n scrollTop: 0\n };\n var offsets = {\n x: 0,\n y: 0\n };\n\n if (isOffsetParentAnElement || !isOffsetParentAnElement && !isFixed) {\n if (getNodeName(offsetParent) !== 'body' || // https://github.com/popperjs/popper-core/issues/1078\n isScrollParent(documentElement)) {\n scroll = getNodeScroll(offsetParent);\n }\n\n if (isHTMLElement(offsetParent)) {\n offsets = getBoundingClientRect(offsetParent, true);\n offsets.x += offsetParent.clientLeft;\n offsets.y += offsetParent.clientTop;\n } else if (documentElement) {\n offsets.x = getWindowScrollBarX(documentElement);\n }\n }\n\n return {\n x: rect.left + scroll.scrollLeft - offsets.x,\n y: rect.top + scroll.scrollTop - offsets.y,\n width: rect.width,\n height: rect.height\n };\n}","import { modifierPhases } from \"../enums.js\"; // source: https://stackoverflow.com/questions/49875255\n\nfunction order(modifiers) {\n var map = new Map();\n var visited = new Set();\n var result = [];\n modifiers.forEach(function (modifier) {\n map.set(modifier.name, modifier);\n }); // On visiting object, check for its dependencies and visit them recursively\n\n function sort(modifier) {\n visited.add(modifier.name);\n var requires = [].concat(modifier.requires || [], modifier.requiresIfExists || []);\n requires.forEach(function (dep) {\n if (!visited.has(dep)) {\n var depModifier = map.get(dep);\n\n if (depModifier) {\n sort(depModifier);\n }\n }\n });\n result.push(modifier);\n }\n\n modifiers.forEach(function (modifier) {\n if (!visited.has(modifier.name)) {\n // check for visited object\n sort(modifier);\n }\n });\n return result;\n}\n\nexport default function orderModifiers(modifiers) {\n // order based on dependencies\n var orderedModifiers = order(modifiers); // order based on phase\n\n return modifierPhases.reduce(function (acc, phase) {\n return acc.concat(orderedModifiers.filter(function (modifier) {\n return modifier.phase === phase;\n }));\n }, []);\n}","export default function debounce(fn) {\n var pending;\n return function () {\n if (!pending) {\n pending = new Promise(function (resolve) {\n Promise.resolve().then(function () {\n pending = undefined;\n resolve(fn());\n });\n });\n }\n\n return pending;\n };\n}","export default function mergeByName(modifiers) {\n var merged = modifiers.reduce(function (merged, current) {\n var existing = merged[current.name];\n merged[current.name] = existing ? Object.assign({}, existing, current, {\n options: Object.assign({}, existing.options, current.options),\n data: Object.assign({}, existing.data, current.data)\n }) : current;\n return merged;\n }, {}); // IE11 does not support Object.values\n\n return Object.keys(merged).map(function (key) {\n return merged[key];\n });\n}","import getCompositeRect from \"./dom-utils/getCompositeRect.js\";\nimport getLayoutRect from \"./dom-utils/getLayoutRect.js\";\nimport listScrollParents from \"./dom-utils/listScrollParents.js\";\nimport getOffsetParent from \"./dom-utils/getOffsetParent.js\";\nimport orderModifiers from \"./utils/orderModifiers.js\";\nimport debounce from \"./utils/debounce.js\";\nimport mergeByName from \"./utils/mergeByName.js\";\nimport detectOverflow from \"./utils/detectOverflow.js\";\nimport { isElement } from \"./dom-utils/instanceOf.js\";\nvar DEFAULT_OPTIONS = {\n placement: 'bottom',\n modifiers: [],\n strategy: 'absolute'\n};\n\nfunction areValidElements() {\n for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {\n args[_key] = arguments[_key];\n }\n\n return !args.some(function (element) {\n return !(element && typeof element.getBoundingClientRect === 'function');\n });\n}\n\nexport function popperGenerator(generatorOptions) {\n if (generatorOptions === void 0) {\n generatorOptions = {};\n }\n\n var _generatorOptions = generatorOptions,\n _generatorOptions$def = _generatorOptions.defaultModifiers,\n defaultModifiers = _generatorOptions$def === void 0 ? [] : _generatorOptions$def,\n _generatorOptions$def2 = _generatorOptions.defaultOptions,\n defaultOptions = _generatorOptions$def2 === void 0 ? DEFAULT_OPTIONS : _generatorOptions$def2;\n return function createPopper(reference, popper, options) {\n if (options === void 0) {\n options = defaultOptions;\n }\n\n var state = {\n placement: 'bottom',\n orderedModifiers: [],\n options: Object.assign({}, DEFAULT_OPTIONS, defaultOptions),\n modifiersData: {},\n elements: {\n reference: reference,\n popper: popper\n },\n attributes: {},\n styles: {}\n };\n var effectCleanupFns = [];\n var isDestroyed = false;\n var instance = {\n state: state,\n setOptions: function setOptions(setOptionsAction) {\n var options = typeof setOptionsAction === 'function' ? setOptionsAction(state.options) : setOptionsAction;\n cleanupModifierEffects();\n state.options = Object.assign({}, defaultOptions, state.options, options);\n state.scrollParents = {\n reference: isElement(reference) ? listScrollParents(reference) : reference.contextElement ? listScrollParents(reference.contextElement) : [],\n popper: listScrollParents(popper)\n }; // Orders the modifiers based on their dependencies and `phase`\n // properties\n\n var orderedModifiers = orderModifiers(mergeByName([].concat(defaultModifiers, state.options.modifiers))); // Strip out disabled modifiers\n\n state.orderedModifiers = orderedModifiers.filter(function (m) {\n return m.enabled;\n });\n runModifierEffects();\n return instance.update();\n },\n // Sync update – it will always be executed, even if not necessary. This\n // is useful for low frequency updates where sync behavior simplifies the\n // logic.\n // For high frequency updates (e.g. `resize` and `scroll` events), always\n // prefer the async Popper#update method\n forceUpdate: function forceUpdate() {\n if (isDestroyed) {\n return;\n }\n\n var _state$elements = state.elements,\n reference = _state$elements.reference,\n popper = _state$elements.popper; // Don't proceed if `reference` or `popper` are not valid elements\n // anymore\n\n if (!areValidElements(reference, popper)) {\n return;\n } // Store the reference and popper rects to be read by modifiers\n\n\n state.rects = {\n reference: getCompositeRect(reference, getOffsetParent(popper), state.options.strategy === 'fixed'),\n popper: getLayoutRect(popper)\n }; // Modifiers have the ability to reset the current update cycle. The\n // most common use case for this is the `flip` modifier changing the\n // placement, which then needs to re-run all the modifiers, because the\n // logic was previously ran for the previous placement and is therefore\n // stale/incorrect\n\n state.reset = false;\n state.placement = state.options.placement; // On each update cycle, the `modifiersData` property for each modifier\n // is filled with the initial data specified by the modifier. This means\n // it doesn't persist and is fresh on each update.\n // To ensure persistent data, use `${name}#persistent`\n\n state.orderedModifiers.forEach(function (modifier) {\n return state.modifiersData[modifier.name] = Object.assign({}, modifier.data);\n });\n\n for (var index = 0; index < state.orderedModifiers.length; index++) {\n if (state.reset === true) {\n state.reset = false;\n index = -1;\n continue;\n }\n\n var _state$orderedModifie = state.orderedModifiers[index],\n fn = _state$orderedModifie.fn,\n _state$orderedModifie2 = _state$orderedModifie.options,\n _options = _state$orderedModifie2 === void 0 ? {} : _state$orderedModifie2,\n name = _state$orderedModifie.name;\n\n if (typeof fn === 'function') {\n state = fn({\n state: state,\n options: _options,\n name: name,\n instance: instance\n }) || state;\n }\n }\n },\n // Async and optimistically optimized update – it will not be executed if\n // not necessary (debounced to run at most once-per-tick)\n update: debounce(function () {\n return new Promise(function (resolve) {\n instance.forceUpdate();\n resolve(state);\n });\n }),\n destroy: function destroy() {\n cleanupModifierEffects();\n isDestroyed = true;\n }\n };\n\n if (!areValidElements(reference, popper)) {\n return instance;\n }\n\n instance.setOptions(options).then(function (state) {\n if (!isDestroyed && options.onFirstUpdate) {\n options.onFirstUpdate(state);\n }\n }); // Modifiers have the ability to execute arbitrary code before the first\n // update cycle runs. They will be executed in the same order as the update\n // cycle. This is useful when a modifier adds some persistent data that\n // other modifiers need to use, but the modifier is run after the dependent\n // one.\n\n function runModifierEffects() {\n state.orderedModifiers.forEach(function (_ref) {\n var name = _ref.name,\n _ref$options = _ref.options,\n options = _ref$options === void 0 ? {} : _ref$options,\n effect = _ref.effect;\n\n if (typeof effect === 'function') {\n var cleanupFn = effect({\n state: state,\n name: name,\n instance: instance,\n options: options\n });\n\n var noopFn = function noopFn() {};\n\n effectCleanupFns.push(cleanupFn || noopFn);\n }\n });\n }\n\n function cleanupModifierEffects() {\n effectCleanupFns.forEach(function (fn) {\n return fn();\n });\n effectCleanupFns = [];\n }\n\n return instance;\n };\n}\nexport var createPopper = /*#__PURE__*/popperGenerator(); // eslint-disable-next-line import/no-unused-modules\n\nexport { detectOverflow };","import { popperGenerator, detectOverflow } from \"./createPopper.js\";\nimport eventListeners from \"./modifiers/eventListeners.js\";\nimport popperOffsets from \"./modifiers/popperOffsets.js\";\nimport computeStyles from \"./modifiers/computeStyles.js\";\nimport applyStyles from \"./modifiers/applyStyles.js\";\nimport offset from \"./modifiers/offset.js\";\nimport flip from \"./modifiers/flip.js\";\nimport preventOverflow from \"./modifiers/preventOverflow.js\";\nimport arrow from \"./modifiers/arrow.js\";\nimport hide from \"./modifiers/hide.js\";\nvar defaultModifiers = [eventListeners, popperOffsets, computeStyles, applyStyles, offset, flip, preventOverflow, arrow, hide];\nvar createPopper = /*#__PURE__*/popperGenerator({\n defaultModifiers: defaultModifiers\n}); // eslint-disable-next-line import/no-unused-modules\n\nexport { createPopper, popperGenerator, defaultModifiers, detectOverflow }; // eslint-disable-next-line import/no-unused-modules\n\nexport { createPopper as createPopperLite } from \"./popper-lite.js\"; // eslint-disable-next-line import/no-unused-modules\n\nexport * from \"./modifiers/index.js\";","import { generateUtilityClass } from '../generateUtilityClass';\nimport { generateUtilityClasses } from '../generateUtilityClasses';\nconst COMPONENT_NAME = 'Popper';\nexport function getPopperUtilityClass(slot) {\n return generateUtilityClass(COMPONENT_NAME, slot);\n}\nexport const popperClasses = generateUtilityClasses(COMPONENT_NAME, ['root']);","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"anchorEl\", \"children\", \"direction\", \"disablePortal\", \"modifiers\", \"open\", \"placement\", \"popperOptions\", \"popperRef\", \"slotProps\", \"slots\", \"TransitionProps\", \"ownerState\"],\n _excluded2 = [\"anchorEl\", \"children\", \"container\", \"direction\", \"disablePortal\", \"keepMounted\", \"modifiers\", \"open\", \"placement\", \"popperOptions\", \"popperRef\", \"style\", \"transition\", \"slotProps\", \"slots\"];\nimport * as React from 'react';\nimport { chainPropTypes, HTMLElementType, refType, unstable_ownerDocument as ownerDocument, unstable_useEnhancedEffect as useEnhancedEffect, unstable_useForkRef as useForkRef } from '@mui/utils';\nimport { createPopper } from '@popperjs/core';\nimport PropTypes from 'prop-types';\nimport { unstable_composeClasses as composeClasses } from '../composeClasses';\nimport { Portal } from '../Portal';\nimport { getPopperUtilityClass } from './popperClasses';\nimport { useSlotProps } from '../utils';\nimport { useClassNamesOverride } from '../utils/ClassNameConfigurator';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nfunction flipPlacement(placement, direction) {\n if (direction === 'ltr') {\n return placement;\n }\n switch (placement) {\n case 'bottom-end':\n return 'bottom-start';\n case 'bottom-start':\n return 'bottom-end';\n case 'top-end':\n return 'top-start';\n case 'top-start':\n return 'top-end';\n default:\n return placement;\n }\n}\nfunction resolveAnchorEl(anchorEl) {\n return typeof anchorEl === 'function' ? anchorEl() : anchorEl;\n}\nfunction isHTMLElement(element) {\n return element.nodeType !== undefined;\n}\nfunction isVirtualElement(element) {\n return !isHTMLElement(element);\n}\nconst useUtilityClasses = () => {\n const slots = {\n root: ['root']\n };\n return composeClasses(slots, useClassNamesOverride(getPopperUtilityClass));\n};\nconst defaultPopperOptions = {};\nconst PopperTooltip = /*#__PURE__*/React.forwardRef(function PopperTooltip(props, forwardedRef) {\n var _slots$root;\n const {\n anchorEl,\n children,\n direction,\n disablePortal,\n modifiers,\n open,\n placement: initialPlacement,\n popperOptions,\n popperRef: popperRefProp,\n slotProps = {},\n slots = {},\n TransitionProps\n // @ts-ignore internal logic\n // prevent from spreading to DOM, it can come from the parent component e.g. Select.\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const tooltipRef = React.useRef(null);\n const ownRef = useForkRef(tooltipRef, forwardedRef);\n const popperRef = React.useRef(null);\n const handlePopperRef = useForkRef(popperRef, popperRefProp);\n const handlePopperRefRef = React.useRef(handlePopperRef);\n useEnhancedEffect(() => {\n handlePopperRefRef.current = handlePopperRef;\n }, [handlePopperRef]);\n React.useImperativeHandle(popperRefProp, () => popperRef.current, []);\n const rtlPlacement = flipPlacement(initialPlacement, direction);\n /**\n * placement initialized from prop but can change during lifetime if modifiers.flip.\n * modifiers.flip is essentially a flip for controlled/uncontrolled behavior\n */\n const [placement, setPlacement] = React.useState(rtlPlacement);\n const [resolvedAnchorElement, setResolvedAnchorElement] = React.useState(resolveAnchorEl(anchorEl));\n React.useEffect(() => {\n if (popperRef.current) {\n popperRef.current.forceUpdate();\n }\n });\n React.useEffect(() => {\n if (anchorEl) {\n setResolvedAnchorElement(resolveAnchorEl(anchorEl));\n }\n }, [anchorEl]);\n useEnhancedEffect(() => {\n if (!resolvedAnchorElement || !open) {\n return undefined;\n }\n const handlePopperUpdate = data => {\n setPlacement(data.placement);\n };\n if (process.env.NODE_ENV !== 'production') {\n if (resolvedAnchorElement && isHTMLElement(resolvedAnchorElement) && resolvedAnchorElement.nodeType === 1) {\n const box = resolvedAnchorElement.getBoundingClientRect();\n if (process.env.NODE_ENV !== 'test' && box.top === 0 && box.left === 0 && box.right === 0 && box.bottom === 0) {\n console.warn(['MUI: The `anchorEl` prop provided to the component is invalid.', 'The anchor element should be part of the document layout.', \"Make sure the element is present in the document or that it's not display none.\"].join('\\n'));\n }\n }\n }\n let popperModifiers = [{\n name: 'preventOverflow',\n options: {\n altBoundary: disablePortal\n }\n }, {\n name: 'flip',\n options: {\n altBoundary: disablePortal\n }\n }, {\n name: 'onUpdate',\n enabled: true,\n phase: 'afterWrite',\n fn: ({\n state\n }) => {\n handlePopperUpdate(state);\n }\n }];\n if (modifiers != null) {\n popperModifiers = popperModifiers.concat(modifiers);\n }\n if (popperOptions && popperOptions.modifiers != null) {\n popperModifiers = popperModifiers.concat(popperOptions.modifiers);\n }\n const popper = createPopper(resolvedAnchorElement, tooltipRef.current, _extends({\n placement: rtlPlacement\n }, popperOptions, {\n modifiers: popperModifiers\n }));\n handlePopperRefRef.current(popper);\n return () => {\n popper.destroy();\n handlePopperRefRef.current(null);\n };\n }, [resolvedAnchorElement, disablePortal, modifiers, open, popperOptions, rtlPlacement]);\n const childProps = {\n placement: placement\n };\n if (TransitionProps !== null) {\n childProps.TransitionProps = TransitionProps;\n }\n const classes = useUtilityClasses();\n const Root = (_slots$root = slots.root) != null ? _slots$root : 'div';\n const rootProps = useSlotProps({\n elementType: Root,\n externalSlotProps: slotProps.root,\n externalForwardedProps: other,\n additionalProps: {\n role: 'tooltip',\n ref: ownRef\n },\n ownerState: props,\n className: classes.root\n });\n return /*#__PURE__*/_jsx(Root, _extends({}, rootProps, {\n children: typeof children === 'function' ? children(childProps) : children\n }));\n});\n\n/**\n * Poppers rely on the 3rd party library [Popper.js](https://popper.js.org/docs/v2/) for positioning.\n *\n * Demos:\n *\n * - [Popper](https://mui.com/base-ui/react-popper/)\n *\n * API:\n *\n * - [Popper API](https://mui.com/base-ui/react-popper/components-api/#popper)\n */\nconst Popper = /*#__PURE__*/React.forwardRef(function Popper(props, forwardedRef) {\n const {\n anchorEl,\n children,\n container: containerProp,\n direction = 'ltr',\n disablePortal = false,\n keepMounted = false,\n modifiers,\n open,\n placement = 'bottom',\n popperOptions = defaultPopperOptions,\n popperRef,\n style,\n transition = false,\n slotProps = {},\n slots = {}\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded2);\n const [exited, setExited] = React.useState(true);\n const handleEnter = () => {\n setExited(false);\n };\n const handleExited = () => {\n setExited(true);\n };\n if (!keepMounted && !open && (!transition || exited)) {\n return null;\n }\n\n // If the container prop is provided, use that\n // If the anchorEl prop is provided, use its parent body element as the container\n // If neither are provided let the Modal take care of choosing the container\n let container;\n if (containerProp) {\n container = containerProp;\n } else if (anchorEl) {\n const resolvedAnchorEl = resolveAnchorEl(anchorEl);\n container = resolvedAnchorEl && isHTMLElement(resolvedAnchorEl) ? ownerDocument(resolvedAnchorEl).body : ownerDocument(null).body;\n }\n const display = !open && keepMounted && (!transition || exited) ? 'none' : undefined;\n const transitionProps = transition ? {\n in: open,\n onEnter: handleEnter,\n onExited: handleExited\n } : undefined;\n return /*#__PURE__*/_jsx(Portal, {\n disablePortal: disablePortal,\n container: container,\n children: /*#__PURE__*/_jsx(PopperTooltip, _extends({\n anchorEl: anchorEl,\n direction: direction,\n disablePortal: disablePortal,\n modifiers: modifiers,\n ref: forwardedRef,\n open: transition ? !exited : open,\n placement: placement,\n popperOptions: popperOptions,\n popperRef: popperRef,\n slotProps: slotProps,\n slots: slots\n }, other, {\n style: _extends({\n // Prevents scroll issue, waiting for Popper.js to add this style once initiated.\n position: 'fixed',\n // Fix Popper.js display issue\n top: 0,\n left: 0,\n display\n }, style),\n TransitionProps: transitionProps,\n children: children\n }))\n });\n});\nprocess.env.NODE_ENV !== \"production\" ? Popper.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * An HTML element, [virtualElement](https://popper.js.org/docs/v2/virtual-elements/),\n * or a function that returns either.\n * It's used to set the position of the popper.\n * The return value will passed as the reference object of the Popper instance.\n */\n anchorEl: chainPropTypes(PropTypes.oneOfType([HTMLElementType, PropTypes.object, PropTypes.func]), props => {\n if (props.open) {\n const resolvedAnchorEl = resolveAnchorEl(props.anchorEl);\n if (resolvedAnchorEl && isHTMLElement(resolvedAnchorEl) && resolvedAnchorEl.nodeType === 1) {\n const box = resolvedAnchorEl.getBoundingClientRect();\n if (process.env.NODE_ENV !== 'test' && box.top === 0 && box.left === 0 && box.right === 0 && box.bottom === 0) {\n return new Error(['MUI: The `anchorEl` prop provided to the component is invalid.', 'The anchor element should be part of the document layout.', \"Make sure the element is present in the document or that it's not display none.\"].join('\\n'));\n }\n } else if (!resolvedAnchorEl || typeof resolvedAnchorEl.getBoundingClientRect !== 'function' || isVirtualElement(resolvedAnchorEl) && resolvedAnchorEl.contextElement != null && resolvedAnchorEl.contextElement.nodeType !== 1) {\n return new Error(['MUI: The `anchorEl` prop provided to the component is invalid.', 'It should be an HTML element instance or a virtualElement ', '(https://popper.js.org/docs/v2/virtual-elements/).'].join('\\n'));\n }\n }\n return null;\n }),\n /**\n * Popper render function or node.\n */\n children: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.node, PropTypes.func]),\n /**\n * An HTML element or function that returns one.\n * The `container` will have the portal children appended to it.\n *\n * You can also provide a callback, which is called in a React layout effect.\n * This lets you set the container from a ref, and also makes server-side rendering possible.\n *\n * By default, it uses the body of the top-level document object,\n * so it's simply `document.body` most of the time.\n */\n container: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.func]),\n /**\n * Direction of the text.\n * @default 'ltr'\n */\n direction: PropTypes.oneOf(['ltr', 'rtl']),\n /**\n * The `children` will be under the DOM hierarchy of the parent component.\n * @default false\n */\n disablePortal: PropTypes.bool,\n /**\n * Always keep the children in the DOM.\n * This prop can be useful in SEO situation or\n * when you want to maximize the responsiveness of the Popper.\n * @default false\n */\n keepMounted: PropTypes.bool,\n /**\n * Popper.js is based on a \"plugin-like\" architecture,\n * most of its features are fully encapsulated \"modifiers\".\n *\n * A modifier is a function that is called each time Popper.js needs to\n * compute the position of the popper.\n * For this reason, modifiers should be very performant to avoid bottlenecks.\n * To learn how to create a modifier, [read the modifiers documentation](https://popper.js.org/docs/v2/modifiers/).\n */\n modifiers: PropTypes.arrayOf(PropTypes.shape({\n data: PropTypes.object,\n effect: PropTypes.func,\n enabled: PropTypes.bool,\n fn: PropTypes.func,\n name: PropTypes.any,\n options: PropTypes.object,\n phase: PropTypes.oneOf(['afterMain', 'afterRead', 'afterWrite', 'beforeMain', 'beforeRead', 'beforeWrite', 'main', 'read', 'write']),\n requires: PropTypes.arrayOf(PropTypes.string),\n requiresIfExists: PropTypes.arrayOf(PropTypes.string)\n })),\n /**\n * If `true`, the component is shown.\n */\n open: PropTypes.bool.isRequired,\n /**\n * Popper placement.\n * @default 'bottom'\n */\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n /**\n * Options provided to the [`Popper.js`](https://popper.js.org/docs/v2/constructors/#options) instance.\n * @default {}\n */\n popperOptions: PropTypes.shape({\n modifiers: PropTypes.array,\n onFirstUpdate: PropTypes.func,\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n strategy: PropTypes.oneOf(['absolute', 'fixed'])\n }),\n /**\n * A ref that points to the used popper instance.\n */\n popperRef: refType,\n /**\n * The props used for each slot inside the Popper.\n * @default {}\n */\n slotProps: PropTypes.shape({\n root: PropTypes.oneOfType([PropTypes.func, PropTypes.object])\n }),\n /**\n * The components used for each slot inside the Popper.\n * Either a string to use a HTML element or a component.\n * @default {}\n */\n slots: PropTypes.shape({\n root: PropTypes.elementType\n }),\n /**\n * Help supporting a react-transition-group/Transition component.\n * @default false\n */\n transition: PropTypes.bool\n} : void 0;\nexport { Popper };","'use client';\n\nimport * as React from 'react';\nimport { useTheme as useThemeSystem } from '@mui/system';\nimport defaultTheme from './defaultTheme';\nimport THEME_ID from './identifier';\nexport default function useTheme() {\n const theme = useThemeSystem(defaultTheme);\n if (process.env.NODE_ENV !== 'production') {\n // eslint-disable-next-line react-hooks/rules-of-hooks\n React.useDebugValue(theme);\n }\n return theme[THEME_ID] || theme;\n}","export default function _setPrototypeOf(o, p) {\n _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function _setPrototypeOf(o, p) {\n o.__proto__ = p;\n return o;\n };\n return _setPrototypeOf(o, p);\n}","import setPrototypeOf from \"./setPrototypeOf.js\";\nexport default function _inheritsLoose(subClass, superClass) {\n subClass.prototype = Object.create(superClass.prototype);\n subClass.prototype.constructor = subClass;\n setPrototypeOf(subClass, superClass);\n}","export default {\n disabled: false\n};","import PropTypes from 'prop-types';\nexport var timeoutsShape = process.env.NODE_ENV !== 'production' ? PropTypes.oneOfType([PropTypes.number, PropTypes.shape({\n enter: PropTypes.number,\n exit: PropTypes.number,\n appear: PropTypes.number\n}).isRequired]) : null;\nexport var classNamesShape = process.env.NODE_ENV !== 'production' ? PropTypes.oneOfType([PropTypes.string, PropTypes.shape({\n enter: PropTypes.string,\n exit: PropTypes.string,\n active: PropTypes.string\n}), PropTypes.shape({\n enter: PropTypes.string,\n enterDone: PropTypes.string,\n enterActive: PropTypes.string,\n exit: PropTypes.string,\n exitDone: PropTypes.string,\n exitActive: PropTypes.string\n})]) : null;","import React from 'react';\nexport default React.createContext(null);","export var forceReflow = function forceReflow(node) {\n return node.scrollTop;\n};","import _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _inheritsLoose from \"@babel/runtime/helpers/esm/inheritsLoose\";\nimport PropTypes from 'prop-types';\nimport React from 'react';\nimport ReactDOM from 'react-dom';\nimport config from './config';\nimport { timeoutsShape } from './utils/PropTypes';\nimport TransitionGroupContext from './TransitionGroupContext';\nimport { forceReflow } from './utils/reflow';\nexport var UNMOUNTED = 'unmounted';\nexport var EXITED = 'exited';\nexport var ENTERING = 'entering';\nexport var ENTERED = 'entered';\nexport var EXITING = 'exiting';\n/**\n * The Transition component lets you describe a transition from one component\n * state to another _over time_ with a simple declarative API. Most commonly\n * it's used to animate the mounting and unmounting of a component, but can also\n * be used to describe in-place transition states as well.\n *\n * ---\n *\n * **Note**: `Transition` is a platform-agnostic base component. If you're using\n * transitions in CSS, you'll probably want to use\n * [`CSSTransition`](https://reactcommunity.org/react-transition-group/css-transition)\n * instead. It inherits all the features of `Transition`, but contains\n * additional features necessary to play nice with CSS transitions (hence the\n * name of the component).\n *\n * ---\n *\n * By default the `Transition` component does not alter the behavior of the\n * component it renders, it only tracks \"enter\" and \"exit\" states for the\n * components. It's up to you to give meaning and effect to those states. For\n * example we can add styles to a component when it enters or exits:\n *\n * ```jsx\n * import { Transition } from 'react-transition-group';\n *\n * const duration = 300;\n *\n * const defaultStyle = {\n * transition: `opacity ${duration}ms ease-in-out`,\n * opacity: 0,\n * }\n *\n * const transitionStyles = {\n * entering: { opacity: 1 },\n * entered: { opacity: 1 },\n * exiting: { opacity: 0 },\n * exited: { opacity: 0 },\n * };\n *\n * const Fade = ({ in: inProp }) => (\n * \n * {state => (\n *
    \n * I'm a fade Transition!\n *
    \n * )}\n *
    \n * );\n * ```\n *\n * There are 4 main states a Transition can be in:\n * - `'entering'`\n * - `'entered'`\n * - `'exiting'`\n * - `'exited'`\n *\n * Transition state is toggled via the `in` prop. When `true` the component\n * begins the \"Enter\" stage. During this stage, the component will shift from\n * its current transition state, to `'entering'` for the duration of the\n * transition and then to the `'entered'` stage once it's complete. Let's take\n * the following example (we'll use the\n * [useState](https://reactjs.org/docs/hooks-reference.html#usestate) hook):\n *\n * ```jsx\n * function App() {\n * const [inProp, setInProp] = useState(false);\n * return (\n *
    \n * \n * {state => (\n * // ...\n * )}\n * \n * \n *
    \n * );\n * }\n * ```\n *\n * When the button is clicked the component will shift to the `'entering'` state\n * and stay there for 500ms (the value of `timeout`) before it finally switches\n * to `'entered'`.\n *\n * When `in` is `false` the same thing happens except the state moves from\n * `'exiting'` to `'exited'`.\n */\n\nvar Transition = /*#__PURE__*/function (_React$Component) {\n _inheritsLoose(Transition, _React$Component);\n\n function Transition(props, context) {\n var _this;\n\n _this = _React$Component.call(this, props, context) || this;\n var parentGroup = context; // In the context of a TransitionGroup all enters are really appears\n\n var appear = parentGroup && !parentGroup.isMounting ? props.enter : props.appear;\n var initialStatus;\n _this.appearStatus = null;\n\n if (props.in) {\n if (appear) {\n initialStatus = EXITED;\n _this.appearStatus = ENTERING;\n } else {\n initialStatus = ENTERED;\n }\n } else {\n if (props.unmountOnExit || props.mountOnEnter) {\n initialStatus = UNMOUNTED;\n } else {\n initialStatus = EXITED;\n }\n }\n\n _this.state = {\n status: initialStatus\n };\n _this.nextCallback = null;\n return _this;\n }\n\n Transition.getDerivedStateFromProps = function getDerivedStateFromProps(_ref, prevState) {\n var nextIn = _ref.in;\n\n if (nextIn && prevState.status === UNMOUNTED) {\n return {\n status: EXITED\n };\n }\n\n return null;\n } // getSnapshotBeforeUpdate(prevProps) {\n // let nextStatus = null\n // if (prevProps !== this.props) {\n // const { status } = this.state\n // if (this.props.in) {\n // if (status !== ENTERING && status !== ENTERED) {\n // nextStatus = ENTERING\n // }\n // } else {\n // if (status === ENTERING || status === ENTERED) {\n // nextStatus = EXITING\n // }\n // }\n // }\n // return { nextStatus }\n // }\n ;\n\n var _proto = Transition.prototype;\n\n _proto.componentDidMount = function componentDidMount() {\n this.updateStatus(true, this.appearStatus);\n };\n\n _proto.componentDidUpdate = function componentDidUpdate(prevProps) {\n var nextStatus = null;\n\n if (prevProps !== this.props) {\n var status = this.state.status;\n\n if (this.props.in) {\n if (status !== ENTERING && status !== ENTERED) {\n nextStatus = ENTERING;\n }\n } else {\n if (status === ENTERING || status === ENTERED) {\n nextStatus = EXITING;\n }\n }\n }\n\n this.updateStatus(false, nextStatus);\n };\n\n _proto.componentWillUnmount = function componentWillUnmount() {\n this.cancelNextCallback();\n };\n\n _proto.getTimeouts = function getTimeouts() {\n var timeout = this.props.timeout;\n var exit, enter, appear;\n exit = enter = appear = timeout;\n\n if (timeout != null && typeof timeout !== 'number') {\n exit = timeout.exit;\n enter = timeout.enter; // TODO: remove fallback for next major\n\n appear = timeout.appear !== undefined ? timeout.appear : enter;\n }\n\n return {\n exit: exit,\n enter: enter,\n appear: appear\n };\n };\n\n _proto.updateStatus = function updateStatus(mounting, nextStatus) {\n if (mounting === void 0) {\n mounting = false;\n }\n\n if (nextStatus !== null) {\n // nextStatus will always be ENTERING or EXITING.\n this.cancelNextCallback();\n\n if (nextStatus === ENTERING) {\n if (this.props.unmountOnExit || this.props.mountOnEnter) {\n var node = this.props.nodeRef ? this.props.nodeRef.current : ReactDOM.findDOMNode(this); // https://github.com/reactjs/react-transition-group/pull/749\n // With unmountOnExit or mountOnEnter, the enter animation should happen at the transition between `exited` and `entering`.\n // To make the animation happen, we have to separate each rendering and avoid being processed as batched.\n\n if (node) forceReflow(node);\n }\n\n this.performEnter(mounting);\n } else {\n this.performExit();\n }\n } else if (this.props.unmountOnExit && this.state.status === EXITED) {\n this.setState({\n status: UNMOUNTED\n });\n }\n };\n\n _proto.performEnter = function performEnter(mounting) {\n var _this2 = this;\n\n var enter = this.props.enter;\n var appearing = this.context ? this.context.isMounting : mounting;\n\n var _ref2 = this.props.nodeRef ? [appearing] : [ReactDOM.findDOMNode(this), appearing],\n maybeNode = _ref2[0],\n maybeAppearing = _ref2[1];\n\n var timeouts = this.getTimeouts();\n var enterTimeout = appearing ? timeouts.appear : timeouts.enter; // no enter animation skip right to ENTERED\n // if we are mounting and running this it means appear _must_ be set\n\n if (!mounting && !enter || config.disabled) {\n this.safeSetState({\n status: ENTERED\n }, function () {\n _this2.props.onEntered(maybeNode);\n });\n return;\n }\n\n this.props.onEnter(maybeNode, maybeAppearing);\n this.safeSetState({\n status: ENTERING\n }, function () {\n _this2.props.onEntering(maybeNode, maybeAppearing);\n\n _this2.onTransitionEnd(enterTimeout, function () {\n _this2.safeSetState({\n status: ENTERED\n }, function () {\n _this2.props.onEntered(maybeNode, maybeAppearing);\n });\n });\n });\n };\n\n _proto.performExit = function performExit() {\n var _this3 = this;\n\n var exit = this.props.exit;\n var timeouts = this.getTimeouts();\n var maybeNode = this.props.nodeRef ? undefined : ReactDOM.findDOMNode(this); // no exit animation skip right to EXITED\n\n if (!exit || config.disabled) {\n this.safeSetState({\n status: EXITED\n }, function () {\n _this3.props.onExited(maybeNode);\n });\n return;\n }\n\n this.props.onExit(maybeNode);\n this.safeSetState({\n status: EXITING\n }, function () {\n _this3.props.onExiting(maybeNode);\n\n _this3.onTransitionEnd(timeouts.exit, function () {\n _this3.safeSetState({\n status: EXITED\n }, function () {\n _this3.props.onExited(maybeNode);\n });\n });\n });\n };\n\n _proto.cancelNextCallback = function cancelNextCallback() {\n if (this.nextCallback !== null) {\n this.nextCallback.cancel();\n this.nextCallback = null;\n }\n };\n\n _proto.safeSetState = function safeSetState(nextState, callback) {\n // This shouldn't be necessary, but there are weird race conditions with\n // setState callbacks and unmounting in testing, so always make sure that\n // we can cancel any pending setState callbacks after we unmount.\n callback = this.setNextCallback(callback);\n this.setState(nextState, callback);\n };\n\n _proto.setNextCallback = function setNextCallback(callback) {\n var _this4 = this;\n\n var active = true;\n\n this.nextCallback = function (event) {\n if (active) {\n active = false;\n _this4.nextCallback = null;\n callback(event);\n }\n };\n\n this.nextCallback.cancel = function () {\n active = false;\n };\n\n return this.nextCallback;\n };\n\n _proto.onTransitionEnd = function onTransitionEnd(timeout, handler) {\n this.setNextCallback(handler);\n var node = this.props.nodeRef ? this.props.nodeRef.current : ReactDOM.findDOMNode(this);\n var doesNotHaveTimeoutOrListener = timeout == null && !this.props.addEndListener;\n\n if (!node || doesNotHaveTimeoutOrListener) {\n setTimeout(this.nextCallback, 0);\n return;\n }\n\n if (this.props.addEndListener) {\n var _ref3 = this.props.nodeRef ? [this.nextCallback] : [node, this.nextCallback],\n maybeNode = _ref3[0],\n maybeNextCallback = _ref3[1];\n\n this.props.addEndListener(maybeNode, maybeNextCallback);\n }\n\n if (timeout != null) {\n setTimeout(this.nextCallback, timeout);\n }\n };\n\n _proto.render = function render() {\n var status = this.state.status;\n\n if (status === UNMOUNTED) {\n return null;\n }\n\n var _this$props = this.props,\n children = _this$props.children,\n _in = _this$props.in,\n _mountOnEnter = _this$props.mountOnEnter,\n _unmountOnExit = _this$props.unmountOnExit,\n _appear = _this$props.appear,\n _enter = _this$props.enter,\n _exit = _this$props.exit,\n _timeout = _this$props.timeout,\n _addEndListener = _this$props.addEndListener,\n _onEnter = _this$props.onEnter,\n _onEntering = _this$props.onEntering,\n _onEntered = _this$props.onEntered,\n _onExit = _this$props.onExit,\n _onExiting = _this$props.onExiting,\n _onExited = _this$props.onExited,\n _nodeRef = _this$props.nodeRef,\n childProps = _objectWithoutPropertiesLoose(_this$props, [\"children\", \"in\", \"mountOnEnter\", \"unmountOnExit\", \"appear\", \"enter\", \"exit\", \"timeout\", \"addEndListener\", \"onEnter\", \"onEntering\", \"onEntered\", \"onExit\", \"onExiting\", \"onExited\", \"nodeRef\"]);\n\n return (\n /*#__PURE__*/\n // allows for nested Transitions\n React.createElement(TransitionGroupContext.Provider, {\n value: null\n }, typeof children === 'function' ? children(status, childProps) : React.cloneElement(React.Children.only(children), childProps))\n );\n };\n\n return Transition;\n}(React.Component);\n\nTransition.contextType = TransitionGroupContext;\nTransition.propTypes = process.env.NODE_ENV !== \"production\" ? {\n /**\n * A React reference to DOM element that need to transition:\n * https://stackoverflow.com/a/51127130/4671932\n *\n * - When `nodeRef` prop is used, `node` is not passed to callback functions\n * (e.g. `onEnter`) because user already has direct access to the node.\n * - When changing `key` prop of `Transition` in a `TransitionGroup` a new\n * `nodeRef` need to be provided to `Transition` with changed `key` prop\n * (see\n * [test/CSSTransition-test.js](https://github.com/reactjs/react-transition-group/blob/13435f897b3ab71f6e19d724f145596f5910581c/test/CSSTransition-test.js#L362-L437)).\n */\n nodeRef: PropTypes.shape({\n current: typeof Element === 'undefined' ? PropTypes.any : function (propValue, key, componentName, location, propFullName, secret) {\n var value = propValue[key];\n return PropTypes.instanceOf(value && 'ownerDocument' in value ? value.ownerDocument.defaultView.Element : Element)(propValue, key, componentName, location, propFullName, secret);\n }\n }),\n\n /**\n * A `function` child can be used instead of a React element. This function is\n * called with the current transition status (`'entering'`, `'entered'`,\n * `'exiting'`, `'exited'`), which can be used to apply context\n * specific props to a component.\n *\n * ```jsx\n * \n * {state => (\n * \n * )}\n * \n * ```\n */\n children: PropTypes.oneOfType([PropTypes.func.isRequired, PropTypes.element.isRequired]).isRequired,\n\n /**\n * Show the component; triggers the enter or exit states\n */\n in: PropTypes.bool,\n\n /**\n * By default the child component is mounted immediately along with\n * the parent `Transition` component. If you want to \"lazy mount\" the component on the\n * first `in={true}` you can set `mountOnEnter`. After the first enter transition the component will stay\n * mounted, even on \"exited\", unless you also specify `unmountOnExit`.\n */\n mountOnEnter: PropTypes.bool,\n\n /**\n * By default the child component stays mounted after it reaches the `'exited'` state.\n * Set `unmountOnExit` if you'd prefer to unmount the component after it finishes exiting.\n */\n unmountOnExit: PropTypes.bool,\n\n /**\n * By default the child component does not perform the enter transition when\n * it first mounts, regardless of the value of `in`. If you want this\n * behavior, set both `appear` and `in` to `true`.\n *\n * > **Note**: there are no special appear states like `appearing`/`appeared`, this prop\n * > only adds an additional enter transition. However, in the\n * > `` component that first enter transition does result in\n * > additional `.appear-*` classes, that way you can choose to style it\n * > differently.\n */\n appear: PropTypes.bool,\n\n /**\n * Enable or disable enter transitions.\n */\n enter: PropTypes.bool,\n\n /**\n * Enable or disable exit transitions.\n */\n exit: PropTypes.bool,\n\n /**\n * The duration of the transition, in milliseconds.\n * Required unless `addEndListener` is provided.\n *\n * You may specify a single timeout for all transitions:\n *\n * ```jsx\n * timeout={500}\n * ```\n *\n * or individually:\n *\n * ```jsx\n * timeout={{\n * appear: 500,\n * enter: 300,\n * exit: 500,\n * }}\n * ```\n *\n * - `appear` defaults to the value of `enter`\n * - `enter` defaults to `0`\n * - `exit` defaults to `0`\n *\n * @type {number | { enter?: number, exit?: number, appear?: number }}\n */\n timeout: function timeout(props) {\n var pt = timeoutsShape;\n if (!props.addEndListener) pt = pt.isRequired;\n\n for (var _len = arguments.length, args = new Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) {\n args[_key - 1] = arguments[_key];\n }\n\n return pt.apply(void 0, [props].concat(args));\n },\n\n /**\n * Add a custom transition end trigger. Called with the transitioning\n * DOM node and a `done` callback. Allows for more fine grained transition end\n * logic. Timeouts are still used as a fallback if provided.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * ```jsx\n * addEndListener={(node, done) => {\n * // use the css transitionend event to mark the finish of a transition\n * node.addEventListener('transitionend', done, false);\n * }}\n * ```\n */\n addEndListener: PropTypes.func,\n\n /**\n * Callback fired before the \"entering\" status is applied. An extra parameter\n * `isAppearing` is supplied to indicate if the enter stage is occurring on the initial mount\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement, isAppearing: bool) -> void\n */\n onEnter: PropTypes.func,\n\n /**\n * Callback fired after the \"entering\" status is applied. An extra parameter\n * `isAppearing` is supplied to indicate if the enter stage is occurring on the initial mount\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement, isAppearing: bool)\n */\n onEntering: PropTypes.func,\n\n /**\n * Callback fired after the \"entered\" status is applied. An extra parameter\n * `isAppearing` is supplied to indicate if the enter stage is occurring on the initial mount\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement, isAppearing: bool) -> void\n */\n onEntered: PropTypes.func,\n\n /**\n * Callback fired before the \"exiting\" status is applied.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement) -> void\n */\n onExit: PropTypes.func,\n\n /**\n * Callback fired after the \"exiting\" status is applied.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement) -> void\n */\n onExiting: PropTypes.func,\n\n /**\n * Callback fired after the \"exited\" status is applied.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed\n *\n * @type Function(node: HtmlElement) -> void\n */\n onExited: PropTypes.func\n} : {}; // Name the function so it is clearer in the documentation\n\nfunction noop() {}\n\nTransition.defaultProps = {\n in: false,\n mountOnEnter: false,\n unmountOnExit: false,\n appear: false,\n enter: true,\n exit: true,\n onEnter: noop,\n onEntering: noop,\n onEntered: noop,\n onExit: noop,\n onExiting: noop,\n onExited: noop\n};\nTransition.UNMOUNTED = UNMOUNTED;\nTransition.EXITED = EXITED;\nTransition.ENTERING = ENTERING;\nTransition.ENTERED = ENTERED;\nTransition.EXITING = EXITING;\nexport default Transition;","export const reflow = node => node.scrollTop;\nexport function getTransitionProps(props, options) {\n var _style$transitionDura, _style$transitionTimi;\n const {\n timeout,\n easing,\n style = {}\n } = props;\n return {\n duration: (_style$transitionDura = style.transitionDuration) != null ? _style$transitionDura : typeof timeout === 'number' ? timeout : timeout[options.mode] || 0,\n easing: (_style$transitionTimi = style.transitionTimingFunction) != null ? _style$transitionTimi : typeof easing === 'object' ? easing[options.mode] : easing,\n delay: style.transitionDelay\n };\n}","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"addEndListener\", \"appear\", \"children\", \"easing\", \"in\", \"onEnter\", \"onEntered\", \"onEntering\", \"onExit\", \"onExited\", \"onExiting\", \"style\", \"timeout\", \"TransitionComponent\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport { elementAcceptingRef, unstable_useTimeout as useTimeout } from '@mui/utils';\nimport { Transition } from 'react-transition-group';\nimport useTheme from '../styles/useTheme';\nimport { getTransitionProps, reflow } from '../transitions/utils';\nimport useForkRef from '../utils/useForkRef';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nfunction getScale(value) {\n return `scale(${value}, ${value ** 2})`;\n}\nconst styles = {\n entering: {\n opacity: 1,\n transform: getScale(1)\n },\n entered: {\n opacity: 1,\n transform: 'none'\n }\n};\n\n/*\n TODO v6: remove\n Conditionally apply a workaround for the CSS transition bug in Safari 15.4 / WebKit browsers.\n */\nconst isWebKit154 = typeof navigator !== 'undefined' && /^((?!chrome|android).)*(safari|mobile)/i.test(navigator.userAgent) && /(os |version\\/)15(.|_)4/i.test(navigator.userAgent);\n\n/**\n * The Grow transition is used by the [Tooltip](/material-ui/react-tooltip/) and\n * [Popover](/material-ui/react-popover/) components.\n * It uses [react-transition-group](https://github.com/reactjs/react-transition-group) internally.\n */\nconst Grow = /*#__PURE__*/React.forwardRef(function Grow(props, ref) {\n const {\n addEndListener,\n appear = true,\n children,\n easing,\n in: inProp,\n onEnter,\n onEntered,\n onEntering,\n onExit,\n onExited,\n onExiting,\n style,\n timeout = 'auto',\n // eslint-disable-next-line react/prop-types\n TransitionComponent = Transition\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const timer = useTimeout();\n const autoTimeout = React.useRef();\n const theme = useTheme();\n const nodeRef = React.useRef(null);\n const handleRef = useForkRef(nodeRef, children.ref, ref);\n const normalizedTransitionCallback = callback => maybeIsAppearing => {\n if (callback) {\n const node = nodeRef.current;\n\n // onEnterXxx and onExitXxx callbacks have a different arguments.length value.\n if (maybeIsAppearing === undefined) {\n callback(node);\n } else {\n callback(node, maybeIsAppearing);\n }\n }\n };\n const handleEntering = normalizedTransitionCallback(onEntering);\n const handleEnter = normalizedTransitionCallback((node, isAppearing) => {\n reflow(node); // So the animation always start from the start.\n\n const {\n duration: transitionDuration,\n delay,\n easing: transitionTimingFunction\n } = getTransitionProps({\n style,\n timeout,\n easing\n }, {\n mode: 'enter'\n });\n let duration;\n if (timeout === 'auto') {\n duration = theme.transitions.getAutoHeightDuration(node.clientHeight);\n autoTimeout.current = duration;\n } else {\n duration = transitionDuration;\n }\n node.style.transition = [theme.transitions.create('opacity', {\n duration,\n delay\n }), theme.transitions.create('transform', {\n duration: isWebKit154 ? duration : duration * 0.666,\n delay,\n easing: transitionTimingFunction\n })].join(',');\n if (onEnter) {\n onEnter(node, isAppearing);\n }\n });\n const handleEntered = normalizedTransitionCallback(onEntered);\n const handleExiting = normalizedTransitionCallback(onExiting);\n const handleExit = normalizedTransitionCallback(node => {\n const {\n duration: transitionDuration,\n delay,\n easing: transitionTimingFunction\n } = getTransitionProps({\n style,\n timeout,\n easing\n }, {\n mode: 'exit'\n });\n let duration;\n if (timeout === 'auto') {\n duration = theme.transitions.getAutoHeightDuration(node.clientHeight);\n autoTimeout.current = duration;\n } else {\n duration = transitionDuration;\n }\n node.style.transition = [theme.transitions.create('opacity', {\n duration,\n delay\n }), theme.transitions.create('transform', {\n duration: isWebKit154 ? duration : duration * 0.666,\n delay: isWebKit154 ? delay : delay || duration * 0.333,\n easing: transitionTimingFunction\n })].join(',');\n node.style.opacity = 0;\n node.style.transform = getScale(0.75);\n if (onExit) {\n onExit(node);\n }\n });\n const handleExited = normalizedTransitionCallback(onExited);\n const handleAddEndListener = next => {\n if (timeout === 'auto') {\n timer.start(autoTimeout.current || 0, next);\n }\n if (addEndListener) {\n // Old call signature before `react-transition-group` implemented `nodeRef`\n addEndListener(nodeRef.current, next);\n }\n };\n return /*#__PURE__*/_jsx(TransitionComponent, _extends({\n appear: appear,\n in: inProp,\n nodeRef: nodeRef,\n onEnter: handleEnter,\n onEntered: handleEntered,\n onEntering: handleEntering,\n onExit: handleExit,\n onExited: handleExited,\n onExiting: handleExiting,\n addEndListener: handleAddEndListener,\n timeout: timeout === 'auto' ? null : timeout\n }, other, {\n children: (state, childProps) => {\n return /*#__PURE__*/React.cloneElement(children, _extends({\n style: _extends({\n opacity: 0,\n transform: getScale(0.75),\n visibility: state === 'exited' && !inProp ? 'hidden' : undefined\n }, styles[state], style, children.props.style),\n ref: handleRef\n }, childProps));\n }\n }));\n});\nprocess.env.NODE_ENV !== \"production\" ? Grow.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the d.ts file and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * Add a custom transition end trigger. Called with the transitioning DOM\n * node and a done callback. Allows for more fine grained transition end\n * logic. Note: Timeouts are still used as a fallback if provided.\n */\n addEndListener: PropTypes.func,\n /**\n * Perform the enter transition when it first mounts if `in` is also `true`.\n * Set this to `false` to disable this behavior.\n * @default true\n */\n appear: PropTypes.bool,\n /**\n * A single child content element.\n */\n children: elementAcceptingRef.isRequired,\n /**\n * The transition timing function.\n * You may specify a single easing or a object containing enter and exit values.\n */\n easing: PropTypes.oneOfType([PropTypes.shape({\n enter: PropTypes.string,\n exit: PropTypes.string\n }), PropTypes.string]),\n /**\n * If `true`, the component will transition in.\n */\n in: PropTypes.bool,\n /**\n * @ignore\n */\n onEnter: PropTypes.func,\n /**\n * @ignore\n */\n onEntered: PropTypes.func,\n /**\n * @ignore\n */\n onEntering: PropTypes.func,\n /**\n * @ignore\n */\n onExit: PropTypes.func,\n /**\n * @ignore\n */\n onExited: PropTypes.func,\n /**\n * @ignore\n */\n onExiting: PropTypes.func,\n /**\n * @ignore\n */\n style: PropTypes.object,\n /**\n * The duration for the transition, in milliseconds.\n * You may specify a single timeout for all transitions, or individually with an object.\n *\n * Set to 'auto' to automatically calculate transition time based on height.\n * @default 'auto'\n */\n timeout: PropTypes.oneOfType([PropTypes.oneOf(['auto']), PropTypes.number, PropTypes.shape({\n appear: PropTypes.number,\n enter: PropTypes.number,\n exit: PropTypes.number\n })])\n} : void 0;\nGrow.muiSupportAuto = true;\nexport default Grow;","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"anchorEl\", \"component\", \"components\", \"componentsProps\", \"container\", \"disablePortal\", \"keepMounted\", \"modifiers\", \"open\", \"placement\", \"popperOptions\", \"popperRef\", \"transition\", \"slots\", \"slotProps\"];\nimport { Popper as BasePopper } from '@mui/base/Popper';\nimport { useThemeWithoutDefault as useTheme } from '@mui/system';\nimport { HTMLElementType, refType } from '@mui/utils';\nimport PropTypes from 'prop-types';\nimport * as React from 'react';\nimport { styled, useThemeProps } from '../styles';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nconst PopperRoot = styled(BasePopper, {\n name: 'MuiPopper',\n slot: 'Root',\n overridesResolver: (props, styles) => styles.root\n})({});\n\n/**\n *\n * Demos:\n *\n * - [Autocomplete](https://mui.com/material-ui/react-autocomplete/)\n * - [Menu](https://mui.com/material-ui/react-menu/)\n * - [Popper](https://mui.com/material-ui/react-popper/)\n *\n * API:\n *\n * - [Popper API](https://mui.com/material-ui/api/popper/)\n */\nconst Popper = /*#__PURE__*/React.forwardRef(function Popper(inProps, ref) {\n var _slots$root;\n const theme = useTheme();\n const props = useThemeProps({\n props: inProps,\n name: 'MuiPopper'\n });\n const {\n anchorEl,\n component,\n components,\n componentsProps,\n container,\n disablePortal,\n keepMounted,\n modifiers,\n open,\n placement,\n popperOptions,\n popperRef,\n transition,\n slots,\n slotProps\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const RootComponent = (_slots$root = slots == null ? void 0 : slots.root) != null ? _slots$root : components == null ? void 0 : components.Root;\n const otherProps = _extends({\n anchorEl,\n container,\n disablePortal,\n keepMounted,\n modifiers,\n open,\n placement,\n popperOptions,\n popperRef,\n transition\n }, other);\n return /*#__PURE__*/_jsx(PopperRoot, _extends({\n as: component,\n direction: theme == null ? void 0 : theme.direction,\n slots: {\n root: RootComponent\n },\n slotProps: slotProps != null ? slotProps : componentsProps\n }, otherProps, {\n ref: ref\n }));\n});\nprocess.env.NODE_ENV !== \"production\" ? Popper.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * An HTML element, [virtualElement](https://popper.js.org/docs/v2/virtual-elements/),\n * or a function that returns either.\n * It's used to set the position of the popper.\n * The return value will passed as the reference object of the Popper instance.\n */\n anchorEl: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.object, PropTypes.func]),\n /**\n * Popper render function or node.\n */\n children: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.node, PropTypes.func]),\n /**\n * The component used for the root node.\n * Either a string to use a HTML element or a component.\n */\n component: PropTypes.elementType,\n /**\n * The components used for each slot inside the Popper.\n * Either a string to use a HTML element or a component.\n * @default {}\n */\n components: PropTypes.shape({\n Root: PropTypes.elementType\n }),\n /**\n * The props used for each slot inside the Popper.\n * @default {}\n */\n componentsProps: PropTypes.shape({\n root: PropTypes.oneOfType([PropTypes.func, PropTypes.object])\n }),\n /**\n * An HTML element or function that returns one.\n * The `container` will have the portal children appended to it.\n *\n * You can also provide a callback, which is called in a React layout effect.\n * This lets you set the container from a ref, and also makes server-side rendering possible.\n *\n * By default, it uses the body of the top-level document object,\n * so it's simply `document.body` most of the time.\n */\n container: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.func]),\n /**\n * The `children` will be under the DOM hierarchy of the parent component.\n * @default false\n */\n disablePortal: PropTypes.bool,\n /**\n * Always keep the children in the DOM.\n * This prop can be useful in SEO situation or\n * when you want to maximize the responsiveness of the Popper.\n * @default false\n */\n keepMounted: PropTypes.bool,\n /**\n * Popper.js is based on a \"plugin-like\" architecture,\n * most of its features are fully encapsulated \"modifiers\".\n *\n * A modifier is a function that is called each time Popper.js needs to\n * compute the position of the popper.\n * For this reason, modifiers should be very performant to avoid bottlenecks.\n * To learn how to create a modifier, [read the modifiers documentation](https://popper.js.org/docs/v2/modifiers/).\n */\n modifiers: PropTypes.arrayOf(PropTypes.shape({\n data: PropTypes.object,\n effect: PropTypes.func,\n enabled: PropTypes.bool,\n fn: PropTypes.func,\n name: PropTypes.any,\n options: PropTypes.object,\n phase: PropTypes.oneOf(['afterMain', 'afterRead', 'afterWrite', 'beforeMain', 'beforeRead', 'beforeWrite', 'main', 'read', 'write']),\n requires: PropTypes.arrayOf(PropTypes.string),\n requiresIfExists: PropTypes.arrayOf(PropTypes.string)\n })),\n /**\n * If `true`, the component is shown.\n */\n open: PropTypes.bool.isRequired,\n /**\n * Popper placement.\n * @default 'bottom'\n */\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n /**\n * Options provided to the [`Popper.js`](https://popper.js.org/docs/v2/constructors/#options) instance.\n * @default {}\n */\n popperOptions: PropTypes.shape({\n modifiers: PropTypes.array,\n onFirstUpdate: PropTypes.func,\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n strategy: PropTypes.oneOf(['absolute', 'fixed'])\n }),\n /**\n * A ref that points to the used popper instance.\n */\n popperRef: refType,\n /**\n * The props used for each slot inside the Popper.\n * @default {}\n */\n slotProps: PropTypes.shape({\n root: PropTypes.oneOfType([PropTypes.func, PropTypes.object])\n }),\n /**\n * The components used for each slot inside the Popper.\n * Either a string to use a HTML element or a component.\n * @default {}\n */\n slots: PropTypes.shape({\n root: PropTypes.elementType\n }),\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Help supporting a react-transition-group/Transition component.\n * @default false\n */\n transition: PropTypes.bool\n} : void 0;\nexport default Popper;","import generateUtilityClasses from '@mui/utils/generateUtilityClasses';\nimport generateUtilityClass from '@mui/utils/generateUtilityClass';\nexport function getTooltipUtilityClass(slot) {\n return generateUtilityClass('MuiTooltip', slot);\n}\nconst tooltipClasses = generateUtilityClasses('MuiTooltip', ['popper', 'popperInteractive', 'popperArrow', 'popperClose', 'tooltip', 'tooltipArrow', 'touch', 'tooltipPlacementLeft', 'tooltipPlacementRight', 'tooltipPlacementTop', 'tooltipPlacementBottom', 'arrow']);\nexport default tooltipClasses;","'use client';\n\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nconst _excluded = [\"arrow\", \"children\", \"classes\", \"components\", \"componentsProps\", \"describeChild\", \"disableFocusListener\", \"disableHoverListener\", \"disableInteractive\", \"disableTouchListener\", \"enterDelay\", \"enterNextDelay\", \"enterTouchDelay\", \"followCursor\", \"id\", \"leaveDelay\", \"leaveTouchDelay\", \"onClose\", \"onOpen\", \"open\", \"placement\", \"PopperComponent\", \"PopperProps\", \"slotProps\", \"slots\", \"title\", \"TransitionComponent\", \"TransitionProps\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport clsx from 'clsx';\nimport { elementAcceptingRef, unstable_useTimeout as useTimeout, unstable_Timeout as Timeout } from '@mui/utils';\nimport { unstable_composeClasses as composeClasses, appendOwnerState } from '@mui/base';\nimport { alpha } from '@mui/system';\nimport styled from '../styles/styled';\nimport useTheme from '../styles/useTheme';\nimport useThemeProps from '../styles/useThemeProps';\nimport capitalize from '../utils/capitalize';\nimport Grow from '../Grow';\nimport Popper from '../Popper';\nimport useEventCallback from '../utils/useEventCallback';\nimport useForkRef from '../utils/useForkRef';\nimport useId from '../utils/useId';\nimport useIsFocusVisible from '../utils/useIsFocusVisible';\nimport useControlled from '../utils/useControlled';\nimport tooltipClasses, { getTooltipUtilityClass } from './tooltipClasses';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nimport { jsxs as _jsxs } from \"react/jsx-runtime\";\nfunction round(value) {\n return Math.round(value * 1e5) / 1e5;\n}\nconst useUtilityClasses = ownerState => {\n const {\n classes,\n disableInteractive,\n arrow,\n touch,\n placement\n } = ownerState;\n const slots = {\n popper: ['popper', !disableInteractive && 'popperInteractive', arrow && 'popperArrow'],\n tooltip: ['tooltip', arrow && 'tooltipArrow', touch && 'touch', `tooltipPlacement${capitalize(placement.split('-')[0])}`],\n arrow: ['arrow']\n };\n return composeClasses(slots, getTooltipUtilityClass, classes);\n};\nconst TooltipPopper = styled(Popper, {\n name: 'MuiTooltip',\n slot: 'Popper',\n overridesResolver: (props, styles) => {\n const {\n ownerState\n } = props;\n return [styles.popper, !ownerState.disableInteractive && styles.popperInteractive, ownerState.arrow && styles.popperArrow, !ownerState.open && styles.popperClose];\n }\n})(({\n theme,\n ownerState,\n open\n}) => _extends({\n zIndex: (theme.vars || theme).zIndex.tooltip,\n pointerEvents: 'none'\n}, !ownerState.disableInteractive && {\n pointerEvents: 'auto'\n}, !open && {\n pointerEvents: 'none'\n}, ownerState.arrow && {\n [`&[data-popper-placement*=\"bottom\"] .${tooltipClasses.arrow}`]: {\n top: 0,\n marginTop: '-0.71em',\n '&::before': {\n transformOrigin: '0 100%'\n }\n },\n [`&[data-popper-placement*=\"top\"] .${tooltipClasses.arrow}`]: {\n bottom: 0,\n marginBottom: '-0.71em',\n '&::before': {\n transformOrigin: '100% 0'\n }\n },\n [`&[data-popper-placement*=\"right\"] .${tooltipClasses.arrow}`]: _extends({}, !ownerState.isRtl ? {\n left: 0,\n marginLeft: '-0.71em'\n } : {\n right: 0,\n marginRight: '-0.71em'\n }, {\n height: '1em',\n width: '0.71em',\n '&::before': {\n transformOrigin: '100% 100%'\n }\n }),\n [`&[data-popper-placement*=\"left\"] .${tooltipClasses.arrow}`]: _extends({}, !ownerState.isRtl ? {\n right: 0,\n marginRight: '-0.71em'\n } : {\n left: 0,\n marginLeft: '-0.71em'\n }, {\n height: '1em',\n width: '0.71em',\n '&::before': {\n transformOrigin: '0 0'\n }\n })\n}));\nconst TooltipTooltip = styled('div', {\n name: 'MuiTooltip',\n slot: 'Tooltip',\n overridesResolver: (props, styles) => {\n const {\n ownerState\n } = props;\n return [styles.tooltip, ownerState.touch && styles.touch, ownerState.arrow && styles.tooltipArrow, styles[`tooltipPlacement${capitalize(ownerState.placement.split('-')[0])}`]];\n }\n})(({\n theme,\n ownerState\n}) => _extends({\n backgroundColor: theme.vars ? theme.vars.palette.Tooltip.bg : alpha(theme.palette.grey[700], 0.92),\n borderRadius: (theme.vars || theme).shape.borderRadius,\n color: (theme.vars || theme).palette.common.white,\n fontFamily: theme.typography.fontFamily,\n padding: '4px 8px',\n fontSize: theme.typography.pxToRem(11),\n maxWidth: 300,\n margin: 2,\n wordWrap: 'break-word',\n fontWeight: theme.typography.fontWeightMedium\n}, ownerState.arrow && {\n position: 'relative',\n margin: 0\n}, ownerState.touch && {\n padding: '8px 16px',\n fontSize: theme.typography.pxToRem(14),\n lineHeight: `${round(16 / 14)}em`,\n fontWeight: theme.typography.fontWeightRegular\n}, {\n [`.${tooltipClasses.popper}[data-popper-placement*=\"left\"] &`]: _extends({\n transformOrigin: 'right center'\n }, !ownerState.isRtl ? _extends({\n marginRight: '14px'\n }, ownerState.touch && {\n marginRight: '24px'\n }) : _extends({\n marginLeft: '14px'\n }, ownerState.touch && {\n marginLeft: '24px'\n })),\n [`.${tooltipClasses.popper}[data-popper-placement*=\"right\"] &`]: _extends({\n transformOrigin: 'left center'\n }, !ownerState.isRtl ? _extends({\n marginLeft: '14px'\n }, ownerState.touch && {\n marginLeft: '24px'\n }) : _extends({\n marginRight: '14px'\n }, ownerState.touch && {\n marginRight: '24px'\n })),\n [`.${tooltipClasses.popper}[data-popper-placement*=\"top\"] &`]: _extends({\n transformOrigin: 'center bottom',\n marginBottom: '14px'\n }, ownerState.touch && {\n marginBottom: '24px'\n }),\n [`.${tooltipClasses.popper}[data-popper-placement*=\"bottom\"] &`]: _extends({\n transformOrigin: 'center top',\n marginTop: '14px'\n }, ownerState.touch && {\n marginTop: '24px'\n })\n}));\nconst TooltipArrow = styled('span', {\n name: 'MuiTooltip',\n slot: 'Arrow',\n overridesResolver: (props, styles) => styles.arrow\n})(({\n theme\n}) => ({\n overflow: 'hidden',\n position: 'absolute',\n width: '1em',\n height: '0.71em' /* = width / sqrt(2) = (length of the hypotenuse) */,\n boxSizing: 'border-box',\n color: theme.vars ? theme.vars.palette.Tooltip.bg : alpha(theme.palette.grey[700], 0.9),\n '&::before': {\n content: '\"\"',\n margin: 'auto',\n display: 'block',\n width: '100%',\n height: '100%',\n backgroundColor: 'currentColor',\n transform: 'rotate(45deg)'\n }\n}));\nlet hystersisOpen = false;\nconst hystersisTimer = new Timeout();\nlet cursorPosition = {\n x: 0,\n y: 0\n};\nexport function testReset() {\n hystersisOpen = false;\n hystersisTimer.clear();\n}\nfunction composeEventHandler(handler, eventHandler) {\n return event => {\n if (eventHandler) {\n eventHandler(event);\n }\n handler(event);\n };\n}\n\n// TODO v6: Remove PopperComponent, PopperProps, TransitionComponent and TransitionProps.\nconst Tooltip = /*#__PURE__*/React.forwardRef(function Tooltip(inProps, ref) {\n var _ref, _slots$popper, _ref2, _ref3, _slots$transition, _ref4, _slots$tooltip, _ref5, _slots$arrow, _slotProps$popper, _ref6, _slotProps$popper2, _slotProps$transition, _slotProps$tooltip, _ref7, _slotProps$tooltip2, _slotProps$arrow, _ref8, _slotProps$arrow2;\n const props = useThemeProps({\n props: inProps,\n name: 'MuiTooltip'\n });\n const {\n arrow = false,\n children: childrenProp,\n components = {},\n componentsProps = {},\n describeChild = false,\n disableFocusListener = false,\n disableHoverListener = false,\n disableInteractive: disableInteractiveProp = false,\n disableTouchListener = false,\n enterDelay = 100,\n enterNextDelay = 0,\n enterTouchDelay = 700,\n followCursor = false,\n id: idProp,\n leaveDelay = 0,\n leaveTouchDelay = 1500,\n onClose,\n onOpen,\n open: openProp,\n placement = 'bottom',\n PopperComponent: PopperComponentProp,\n PopperProps = {},\n slotProps = {},\n slots = {},\n title,\n TransitionComponent: TransitionComponentProp = Grow,\n TransitionProps\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n\n // to prevent runtime errors, developers will need to provide a child as a React element anyway.\n const children = /*#__PURE__*/React.isValidElement(childrenProp) ? childrenProp : /*#__PURE__*/_jsx(\"span\", {\n children: childrenProp\n });\n const theme = useTheme();\n const isRtl = theme.direction === 'rtl';\n const [childNode, setChildNode] = React.useState();\n const [arrowRef, setArrowRef] = React.useState(null);\n const ignoreNonTouchEvents = React.useRef(false);\n const disableInteractive = disableInteractiveProp || followCursor;\n const closeTimer = useTimeout();\n const enterTimer = useTimeout();\n const leaveTimer = useTimeout();\n const touchTimer = useTimeout();\n const [openState, setOpenState] = useControlled({\n controlled: openProp,\n default: false,\n name: 'Tooltip',\n state: 'open'\n });\n let open = openState;\n if (process.env.NODE_ENV !== 'production') {\n // eslint-disable-next-line react-hooks/rules-of-hooks\n const {\n current: isControlled\n } = React.useRef(openProp !== undefined);\n\n // eslint-disable-next-line react-hooks/rules-of-hooks\n React.useEffect(() => {\n if (childNode && childNode.disabled && !isControlled && title !== '' && childNode.tagName.toLowerCase() === 'button') {\n console.error(['MUI: You are providing a disabled `button` child to the Tooltip component.', 'A disabled element does not fire events.', \"Tooltip needs to listen to the child element's events to display the title.\", '', 'Add a simple wrapper element, such as a `span`.'].join('\\n'));\n }\n }, [title, childNode, isControlled]);\n }\n const id = useId(idProp);\n const prevUserSelect = React.useRef();\n const stopTouchInteraction = useEventCallback(() => {\n if (prevUserSelect.current !== undefined) {\n document.body.style.WebkitUserSelect = prevUserSelect.current;\n prevUserSelect.current = undefined;\n }\n touchTimer.clear();\n });\n React.useEffect(() => stopTouchInteraction, [stopTouchInteraction]);\n const handleOpen = event => {\n hystersisTimer.clear();\n hystersisOpen = true;\n\n // The mouseover event will trigger for every nested element in the tooltip.\n // We can skip rerendering when the tooltip is already open.\n // We are using the mouseover event instead of the mouseenter event to fix a hide/show issue.\n setOpenState(true);\n if (onOpen && !open) {\n onOpen(event);\n }\n };\n const handleClose = useEventCallback(\n /**\n * @param {React.SyntheticEvent | Event} event\n */\n event => {\n hystersisTimer.start(800 + leaveDelay, () => {\n hystersisOpen = false;\n });\n setOpenState(false);\n if (onClose && open) {\n onClose(event);\n }\n closeTimer.start(theme.transitions.duration.shortest, () => {\n ignoreNonTouchEvents.current = false;\n });\n });\n const handleEnter = event => {\n if (ignoreNonTouchEvents.current && event.type !== 'touchstart') {\n return;\n }\n\n // Remove the title ahead of time.\n // We don't want to wait for the next render commit.\n // We would risk displaying two tooltips at the same time (native + this one).\n if (childNode) {\n childNode.removeAttribute('title');\n }\n enterTimer.clear();\n leaveTimer.clear();\n if (enterDelay || hystersisOpen && enterNextDelay) {\n enterTimer.start(hystersisOpen ? enterNextDelay : enterDelay, () => {\n handleOpen(event);\n });\n } else {\n handleOpen(event);\n }\n };\n const handleLeave = event => {\n enterTimer.clear();\n leaveTimer.start(leaveDelay, () => {\n handleClose(event);\n });\n };\n const {\n isFocusVisibleRef,\n onBlur: handleBlurVisible,\n onFocus: handleFocusVisible,\n ref: focusVisibleRef\n } = useIsFocusVisible();\n // We don't necessarily care about the focusVisible state (which is safe to access via ref anyway).\n // We just need to re-render the Tooltip if the focus-visible state changes.\n const [, setChildIsFocusVisible] = React.useState(false);\n const handleBlur = event => {\n handleBlurVisible(event);\n if (isFocusVisibleRef.current === false) {\n setChildIsFocusVisible(false);\n handleLeave(event);\n }\n };\n const handleFocus = event => {\n // Workaround for https://github.com/facebook/react/issues/7769\n // The autoFocus of React might trigger the event before the componentDidMount.\n // We need to account for this eventuality.\n if (!childNode) {\n setChildNode(event.currentTarget);\n }\n handleFocusVisible(event);\n if (isFocusVisibleRef.current === true) {\n setChildIsFocusVisible(true);\n handleEnter(event);\n }\n };\n const detectTouchStart = event => {\n ignoreNonTouchEvents.current = true;\n const childrenProps = children.props;\n if (childrenProps.onTouchStart) {\n childrenProps.onTouchStart(event);\n }\n };\n const handleMouseOver = handleEnter;\n const handleMouseLeave = handleLeave;\n const handleTouchStart = event => {\n detectTouchStart(event);\n leaveTimer.clear();\n closeTimer.clear();\n stopTouchInteraction();\n prevUserSelect.current = document.body.style.WebkitUserSelect;\n // Prevent iOS text selection on long-tap.\n document.body.style.WebkitUserSelect = 'none';\n touchTimer.start(enterTouchDelay, () => {\n document.body.style.WebkitUserSelect = prevUserSelect.current;\n handleEnter(event);\n });\n };\n const handleTouchEnd = event => {\n if (children.props.onTouchEnd) {\n children.props.onTouchEnd(event);\n }\n stopTouchInteraction();\n leaveTimer.start(leaveTouchDelay, () => {\n handleClose(event);\n });\n };\n React.useEffect(() => {\n if (!open) {\n return undefined;\n }\n\n /**\n * @param {KeyboardEvent} nativeEvent\n */\n function handleKeyDown(nativeEvent) {\n // IE11, Edge (prior to using Bink?) use 'Esc'\n if (nativeEvent.key === 'Escape' || nativeEvent.key === 'Esc') {\n handleClose(nativeEvent);\n }\n }\n document.addEventListener('keydown', handleKeyDown);\n return () => {\n document.removeEventListener('keydown', handleKeyDown);\n };\n }, [handleClose, open]);\n const handleRef = useForkRef(children.ref, focusVisibleRef, setChildNode, ref);\n\n // There is no point in displaying an empty tooltip.\n // So we exclude all falsy values, except 0, which is valid.\n if (!title && title !== 0) {\n open = false;\n }\n const popperRef = React.useRef();\n const handleMouseMove = event => {\n const childrenProps = children.props;\n if (childrenProps.onMouseMove) {\n childrenProps.onMouseMove(event);\n }\n cursorPosition = {\n x: event.clientX,\n y: event.clientY\n };\n if (popperRef.current) {\n popperRef.current.update();\n }\n };\n const nameOrDescProps = {};\n const titleIsString = typeof title === 'string';\n if (describeChild) {\n nameOrDescProps.title = !open && titleIsString && !disableHoverListener ? title : null;\n nameOrDescProps['aria-describedby'] = open ? id : null;\n } else {\n nameOrDescProps['aria-label'] = titleIsString ? title : null;\n nameOrDescProps['aria-labelledby'] = open && !titleIsString ? id : null;\n }\n const childrenProps = _extends({}, nameOrDescProps, other, children.props, {\n className: clsx(other.className, children.props.className),\n onTouchStart: detectTouchStart,\n ref: handleRef\n }, followCursor ? {\n onMouseMove: handleMouseMove\n } : {});\n if (process.env.NODE_ENV !== 'production') {\n childrenProps['data-mui-internal-clone-element'] = true;\n\n // eslint-disable-next-line react-hooks/rules-of-hooks\n React.useEffect(() => {\n if (childNode && !childNode.getAttribute('data-mui-internal-clone-element')) {\n console.error(['MUI: The `children` component of the Tooltip is not forwarding its props correctly.', 'Please make sure that props are spread on the same element that the ref is applied to.'].join('\\n'));\n }\n }, [childNode]);\n }\n const interactiveWrapperListeners = {};\n if (!disableTouchListener) {\n childrenProps.onTouchStart = handleTouchStart;\n childrenProps.onTouchEnd = handleTouchEnd;\n }\n if (!disableHoverListener) {\n childrenProps.onMouseOver = composeEventHandler(handleMouseOver, childrenProps.onMouseOver);\n childrenProps.onMouseLeave = composeEventHandler(handleMouseLeave, childrenProps.onMouseLeave);\n if (!disableInteractive) {\n interactiveWrapperListeners.onMouseOver = handleMouseOver;\n interactiveWrapperListeners.onMouseLeave = handleMouseLeave;\n }\n }\n if (!disableFocusListener) {\n childrenProps.onFocus = composeEventHandler(handleFocus, childrenProps.onFocus);\n childrenProps.onBlur = composeEventHandler(handleBlur, childrenProps.onBlur);\n if (!disableInteractive) {\n interactiveWrapperListeners.onFocus = handleFocus;\n interactiveWrapperListeners.onBlur = handleBlur;\n }\n }\n if (process.env.NODE_ENV !== 'production') {\n if (children.props.title) {\n console.error(['MUI: You have provided a `title` prop to the child of .', `Remove this title prop \\`${children.props.title}\\` or the Tooltip component.`].join('\\n'));\n }\n }\n const popperOptions = React.useMemo(() => {\n var _PopperProps$popperOp;\n let tooltipModifiers = [{\n name: 'arrow',\n enabled: Boolean(arrowRef),\n options: {\n element: arrowRef,\n padding: 4\n }\n }];\n if ((_PopperProps$popperOp = PopperProps.popperOptions) != null && _PopperProps$popperOp.modifiers) {\n tooltipModifiers = tooltipModifiers.concat(PopperProps.popperOptions.modifiers);\n }\n return _extends({}, PopperProps.popperOptions, {\n modifiers: tooltipModifiers\n });\n }, [arrowRef, PopperProps]);\n const ownerState = _extends({}, props, {\n isRtl,\n arrow,\n disableInteractive,\n placement,\n PopperComponentProp,\n touch: ignoreNonTouchEvents.current\n });\n const classes = useUtilityClasses(ownerState);\n const PopperComponent = (_ref = (_slots$popper = slots.popper) != null ? _slots$popper : components.Popper) != null ? _ref : TooltipPopper;\n const TransitionComponent = (_ref2 = (_ref3 = (_slots$transition = slots.transition) != null ? _slots$transition : components.Transition) != null ? _ref3 : TransitionComponentProp) != null ? _ref2 : Grow;\n const TooltipComponent = (_ref4 = (_slots$tooltip = slots.tooltip) != null ? _slots$tooltip : components.Tooltip) != null ? _ref4 : TooltipTooltip;\n const ArrowComponent = (_ref5 = (_slots$arrow = slots.arrow) != null ? _slots$arrow : components.Arrow) != null ? _ref5 : TooltipArrow;\n const popperProps = appendOwnerState(PopperComponent, _extends({}, PopperProps, (_slotProps$popper = slotProps.popper) != null ? _slotProps$popper : componentsProps.popper, {\n className: clsx(classes.popper, PopperProps == null ? void 0 : PopperProps.className, (_ref6 = (_slotProps$popper2 = slotProps.popper) != null ? _slotProps$popper2 : componentsProps.popper) == null ? void 0 : _ref6.className)\n }), ownerState);\n const transitionProps = appendOwnerState(TransitionComponent, _extends({}, TransitionProps, (_slotProps$transition = slotProps.transition) != null ? _slotProps$transition : componentsProps.transition), ownerState);\n const tooltipProps = appendOwnerState(TooltipComponent, _extends({}, (_slotProps$tooltip = slotProps.tooltip) != null ? _slotProps$tooltip : componentsProps.tooltip, {\n className: clsx(classes.tooltip, (_ref7 = (_slotProps$tooltip2 = slotProps.tooltip) != null ? _slotProps$tooltip2 : componentsProps.tooltip) == null ? void 0 : _ref7.className)\n }), ownerState);\n const tooltipArrowProps = appendOwnerState(ArrowComponent, _extends({}, (_slotProps$arrow = slotProps.arrow) != null ? _slotProps$arrow : componentsProps.arrow, {\n className: clsx(classes.arrow, (_ref8 = (_slotProps$arrow2 = slotProps.arrow) != null ? _slotProps$arrow2 : componentsProps.arrow) == null ? void 0 : _ref8.className)\n }), ownerState);\n return /*#__PURE__*/_jsxs(React.Fragment, {\n children: [/*#__PURE__*/React.cloneElement(children, childrenProps), /*#__PURE__*/_jsx(PopperComponent, _extends({\n as: PopperComponentProp != null ? PopperComponentProp : Popper,\n placement: placement,\n anchorEl: followCursor ? {\n getBoundingClientRect: () => ({\n top: cursorPosition.y,\n left: cursorPosition.x,\n right: cursorPosition.x,\n bottom: cursorPosition.y,\n width: 0,\n height: 0\n })\n } : childNode,\n popperRef: popperRef,\n open: childNode ? open : false,\n id: id,\n transition: true\n }, interactiveWrapperListeners, popperProps, {\n popperOptions: popperOptions,\n children: ({\n TransitionProps: TransitionPropsInner\n }) => /*#__PURE__*/_jsx(TransitionComponent, _extends({\n timeout: theme.transitions.duration.shorter\n }, TransitionPropsInner, transitionProps, {\n children: /*#__PURE__*/_jsxs(TooltipComponent, _extends({}, tooltipProps, {\n children: [title, arrow ? /*#__PURE__*/_jsx(ArrowComponent, _extends({}, tooltipArrowProps, {\n ref: setArrowRef\n })) : null]\n }))\n }))\n }))]\n });\n});\nprocess.env.NODE_ENV !== \"production\" ? Tooltip.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the d.ts file and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * If `true`, adds an arrow to the tooltip.\n * @default false\n */\n arrow: PropTypes.bool,\n /**\n * Tooltip reference element.\n */\n children: elementAcceptingRef.isRequired,\n /**\n * Override or extend the styles applied to the component.\n */\n classes: PropTypes.object,\n /**\n * @ignore\n */\n className: PropTypes.string,\n /**\n * The components used for each slot inside.\n *\n * This prop is an alias for the `slots` prop.\n * It's recommended to use the `slots` prop instead.\n *\n * @default {}\n */\n components: PropTypes.shape({\n Arrow: PropTypes.elementType,\n Popper: PropTypes.elementType,\n Tooltip: PropTypes.elementType,\n Transition: PropTypes.elementType\n }),\n /**\n * The extra props for the slot components.\n * You can override the existing props or add new ones.\n *\n * This prop is an alias for the `slotProps` prop.\n * It's recommended to use the `slotProps` prop instead, as `componentsProps` will be deprecated in the future.\n *\n * @default {}\n */\n componentsProps: PropTypes.shape({\n arrow: PropTypes.object,\n popper: PropTypes.object,\n tooltip: PropTypes.object,\n transition: PropTypes.object\n }),\n /**\n * Set to `true` if the `title` acts as an accessible description.\n * By default the `title` acts as an accessible label for the child.\n * @default false\n */\n describeChild: PropTypes.bool,\n /**\n * Do not respond to focus-visible events.\n * @default false\n */\n disableFocusListener: PropTypes.bool,\n /**\n * Do not respond to hover events.\n * @default false\n */\n disableHoverListener: PropTypes.bool,\n /**\n * Makes a tooltip not interactive, i.e. it will close when the user\n * hovers over the tooltip before the `leaveDelay` is expired.\n * @default false\n */\n disableInteractive: PropTypes.bool,\n /**\n * Do not respond to long press touch events.\n * @default false\n */\n disableTouchListener: PropTypes.bool,\n /**\n * The number of milliseconds to wait before showing the tooltip.\n * This prop won't impact the enter touch delay (`enterTouchDelay`).\n * @default 100\n */\n enterDelay: PropTypes.number,\n /**\n * The number of milliseconds to wait before showing the tooltip when one was already recently opened.\n * @default 0\n */\n enterNextDelay: PropTypes.number,\n /**\n * The number of milliseconds a user must touch the element before showing the tooltip.\n * @default 700\n */\n enterTouchDelay: PropTypes.number,\n /**\n * If `true`, the tooltip follow the cursor over the wrapped element.\n * @default false\n */\n followCursor: PropTypes.bool,\n /**\n * This prop is used to help implement the accessibility logic.\n * If you don't provide this prop. It falls back to a randomly generated id.\n */\n id: PropTypes.string,\n /**\n * The number of milliseconds to wait before hiding the tooltip.\n * This prop won't impact the leave touch delay (`leaveTouchDelay`).\n * @default 0\n */\n leaveDelay: PropTypes.number,\n /**\n * The number of milliseconds after the user stops touching an element before hiding the tooltip.\n * @default 1500\n */\n leaveTouchDelay: PropTypes.number,\n /**\n * Callback fired when the component requests to be closed.\n *\n * @param {React.SyntheticEvent} event The event source of the callback.\n */\n onClose: PropTypes.func,\n /**\n * Callback fired when the component requests to be open.\n *\n * @param {React.SyntheticEvent} event The event source of the callback.\n */\n onOpen: PropTypes.func,\n /**\n * If `true`, the component is shown.\n */\n open: PropTypes.bool,\n /**\n * Tooltip placement.\n * @default 'bottom'\n */\n placement: PropTypes.oneOf(['bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n /**\n * The component used for the popper.\n * @default Popper\n */\n PopperComponent: PropTypes.elementType,\n /**\n * Props applied to the [`Popper`](/material-ui/api/popper/) element.\n * @default {}\n */\n PopperProps: PropTypes.object,\n /**\n * The extra props for the slot components.\n * You can override the existing props or add new ones.\n *\n * This prop is an alias for the `componentsProps` prop, which will be deprecated in the future.\n *\n * @default {}\n */\n slotProps: PropTypes.shape({\n arrow: PropTypes.object,\n popper: PropTypes.object,\n tooltip: PropTypes.object,\n transition: PropTypes.object\n }),\n /**\n * The components used for each slot inside.\n *\n * This prop is an alias for the `components` prop, which will be deprecated in the future.\n *\n * @default {}\n */\n slots: PropTypes.shape({\n arrow: PropTypes.elementType,\n popper: PropTypes.elementType,\n tooltip: PropTypes.elementType,\n transition: PropTypes.elementType\n }),\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Tooltip title. Zero-length titles string, undefined, null and false are never displayed.\n */\n title: PropTypes.node,\n /**\n * The component used for the transition.\n * [Follow this guide](/material-ui/transitions/#transitioncomponent-prop) to learn more about the requirements for this component.\n * @default Grow\n */\n TransitionComponent: PropTypes.elementType,\n /**\n * Props applied to the transition element.\n * By default, the element is based on this [`Transition`](http://reactcommunity.org/react-transition-group/transition/) component.\n */\n TransitionProps: PropTypes.object\n} : void 0;\nexport default Tooltip;","import '@/components/mui/menu-item.component.css';\nimport ArrowRightIcon from '@mui/icons-material/ArrowRight';\nimport {\n ListItemIcon as MuiListItemIcon,\n ListItemText as MuiListItemText,\n MenuItem as MuiMenuItem,\n} from '@mui/material';\nimport Tooltip from '@mui/material/Tooltip';\nimport { Localized, ReferencedItem, SingleColumnMenu } from 'platform-bible-utils';\nimport { MouseEvent, PropsWithChildren } from 'react';\n\ntype MenuItemInfoBase = {\n /** Text (displayable in the UI) as the name of the menu item */\n label: string;\n /** Text to display when the mouse hovers over the menu item */\n tooltip?: string;\n};\n\nexport type Command = MenuItemInfoBase & {\n /** Command to execute (string.string) */\n command: string;\n};\n\ntype SubMenu = MenuItemInfoBase & {\n /** Command to execute (string.string) */\n items: MenuItemInfo[];\n};\n\nexport interface CommandHandler {\n (command: Command): void;\n}\n\nexport type MenuPropsBase = {\n /*\n * The JSON defining the menu whose items are to be rendered. This will typically be one of the\n * menus in the \"defs\" in a Platform.Bible menu (see PlatformMenus). The schema for this is\n * menuDocumentSchema (at the end of menus.model.ts). Note that while this is a\n * \"SingleColumnMenu\", somewhat bizarrely, a MultiColumnMenu is a SingleColumnMenu, so it really\n * could be a MultiColumnMenu, in which case, column had better be defined so it can be used\n * to filter out the actual groups and items to display on the column.\n */\n menuDefinition: Localized;\n\n commandHandler: CommandHandler;\n\n /**\n * Additional action to perform when any menu item is clicked. Allows the caller to handle event\n * (e.g., to close the menu).\n */\n onClick?: (event: MouseEvent) => void;\n};\n\nexport type MenuItemListProps = MenuPropsBase & {\n /** Optional unique (column) identifier */\n columnId?: ReferencedItem;\n};\n\nexport type MenuItemProps = Omit &\n PropsWithChildren<{\n /** Optional unique identifier */\n id?: string;\n\n onClick: (event: MouseEvent) => void;\n }>;\n\ntype MenuItemInfo = (Command | SubMenu) & {\n /**\n * If specified, menu item will be inset if it does not have a leading icon.\n *\n * @default true\n */\n allowForLeadingIcons?: boolean;\n /**\n * If specified, the path to the icon image to display on the leading side of the menu text.\n *\n * @default undefined (no leading icon will be shown)\n */\n iconPathBefore?: string;\n /**\n * If specified, the path to the icon image to display on the trailing side of the menu text.\n *\n * @default undefined (no trailing icon will be shown)\n */\n iconPathAfter?: string;\n /**\n * If true, list item is focused during the first mount\n *\n * @default false\n */\n hasAutoFocus?: boolean;\n\n /** Additional css classes to help with unique styling of the menu item */\n className?: string;\n\n /**\n * If true, the menu item will appear disabled and it will not respond to clicks or mouse hovers.\n *\n * @default false\n */\n isDisabled?: boolean;\n\n /**\n * If true, compact vertical padding designed for keyboard and mouse input is used.\n *\n * @default true\n */\n isDense?: boolean;\n\n /**\n * If true, a right-arrow icon will be displayed (iconPathAfter, if specified, will be ignored).\n *\n * @default false\n */\n isSubMenuParent?: boolean;\n\n /**\n * If true, the left and right padding is removed\n *\n * @default false\n */\n hasDisabledGutters?: boolean;\n\n /**\n * If true, a 1px light border is added to bottom of menu item\n *\n * @default false\n */\n hasDivider?: boolean;\n\n /** Help identify which element has keyboard focus */\n focusVisibleClassName?: string;\n\n /** If it's a submenu, it should have the items property */\n items?: MenuItemInfo[];\n};\n\nfunction getIcon(icon: string | undefined, menuLabel: string, leading: boolean) {\n return icon ? (\n \n {`${leading\n \n ) : undefined;\n}\n\nexport default function MenuItem(props: MenuItemProps) {\n const {\n onClick,\n label,\n tooltip,\n allowForLeadingIcons = true,\n iconPathBefore = undefined,\n iconPathAfter = undefined,\n hasAutoFocus = false,\n className,\n isDisabled = false,\n isDense = true,\n isSubMenuParent = false,\n hasDisabledGutters = false,\n hasDivider = false,\n focusVisibleClassName,\n id,\n children,\n } = props;\n\n const menuItem = (\n \n {label ? (\n <>\n {getIcon(iconPathBefore, label, true)}\n \n {isSubMenuParent ? (\n \n \n \n ) : (\n getIcon(iconPathAfter, label, false)\n )}\n \n ) : (\n children\n )}\n \n );\n\n return tooltip ? (\n \n
    {menuItem}
    \n
    \n ) : (\n menuItem\n );\n}\n","import MenuItem, {\n MenuItemListProps,\n MenuItemProps,\n MenuPropsBase,\n} from '@/components/mui/menu-item.component';\nimport { Menu } from '@mui/material';\nimport {\n Localized,\n MenuGroupDetailsInSubMenu,\n MenuItemContainingCommand,\n MenuItemContainingSubmenu,\n OrderedExtensibleContainer,\n ReferencedItem,\n SingleColumnMenu,\n} from 'platform-bible-utils';\nimport { MouseEvent, useMemo, useState } from 'react';\n\n/**\n * All the exported types in this file should be regarded as \"internal\" (i.e., they should not be\n * exposed via index.ts).\n */\n\nexport type GroupedMenuPropsBase = MenuPropsBase & {\n /** Optional unique (column) identifier */\n columnId?: ReferencedItem;\n};\n\nexport type GroupedMenuItemListProps = MenuItemListProps & {\n /**\n * If the menuDefinition includes \"top-level\" groups (i.e., those that belong to a column as\n * opposed to those that belong to a submenu) that should not be included in the list, then this\n * array specifies which groups to include. Likewise, for a submenu, this list indicates which\n * groups are pertinent for that submenu. So then for a context menu this property need not be\n * specified since it is a top-level menu based on a \"true\" SingleColumnMenu (i.e., one that is\n * not a MultiColumnMenu).\n */\n includedGroups?: {\n id: string;\n group: Localized;\n }[];\n};\n\ninterface ItemInfo {\n item: Localized;\n isLastItemInGroup: boolean;\n}\n\ntype SubMenuProps = MenuPropsBase & {\n parentMenuItem: Localized;\n parentItemProps: Omit, 'iconPathAfter'>;\n};\n\nfunction getAllGroups(menuDefinition: Localized) {\n const groupEntries = Object.entries(menuDefinition.groups);\n // Convert array of entries to array of objects with id and group properties\n return groupEntries.map(([key, value]) => ({ id: key, group: value }));\n}\n\nfunction SubMenu(props: SubMenuProps) {\n const [anchorEl, setAnchorEl] = useState(undefined);\n\n const { parentMenuItem, parentItemProps, menuDefinition } = props;\n\n const handleParentMenuItemClick = (event: MouseEvent) => {\n setAnchorEl(event.currentTarget);\n };\n\n const handleClose = () => {\n setAnchorEl(undefined);\n };\n\n const renderSubMenuItems = () => {\n let includedGroups = getAllGroups(menuDefinition).filter((g) => 'menuItem' in g.group);\n\n // Ensure valid parent menu was provided. (If not, submenu will contain all groups!)\n if (!parentMenuItem?.id) throw new Error('A valid parent menu item is required for submenus.');\n\n // When laying out a submenu, only include groups associated with the provided parent menu.\n // Note: without the (annoying) redundant check that the included groups\n // have the menuItem field, TS doesn't think it exists.\n includedGroups = includedGroups.filter(\n (group) => 'menuItem' in group.group && group.group.menuItem === parentMenuItem.id,\n );\n\n return ;\n };\n\n return (\n <>\n \n \n {renderSubMenuItems()}\n \n \n );\n}\n\nconst getOrderedGroupItems = (\n groupId: string,\n allItems: Localized[],\n) => {\n // Filter items that belong to the specified group\n const itemsForGroup = allItems.filter((item) => item.group === groupId);\n // Sort items based on order\n const sortedItems = itemsForGroup.sort((a, b) => (a.order || 0) - (b.order || 0));\n return sortedItems;\n};\n\n/**\n * This component is internal; it does not need to be exposed to the outside world since it is not\n * useful on its own. It is used to generate and lay out the MenuItems that appear either on a\n * top-level menu (in a GridMenu or ContextMenu) or in a submenu.\n */\nexport default function GroupedMenuItemList(menuProps: GroupedMenuItemListProps) {\n const { menuDefinition, onClick, commandHandler, includedGroups } = menuProps;\n\n const { items, allowForLeadingIcons } = useMemo(() => {\n const groupsToInclude =\n includedGroups && includedGroups.length > 0\n ? includedGroups\n : // We're apparently laying out a single-column menu (presumably a context menu). In this\n // case, all groups should be included except ones that belong to a submenu.\n getAllGroups(menuDefinition).filter((g) => !('menuItem' in g.group));\n\n const sortedGroups = Object.values(groupsToInclude).sort(\n (a, b) => (a.group.order || 0) - (b.group.order || 0),\n );\n\n const itemArray: ItemInfo[] = [];\n\n sortedGroups.forEach((group) => {\n getOrderedGroupItems(group.id, menuDefinition.items).forEach((item) =>\n itemArray.push({ item, isLastItemInGroup: false }),\n );\n if (itemArray.length > 0) itemArray[itemArray.length - 1].isLastItemInGroup = true;\n });\n\n // No divider after last item in final group.\n if (itemArray.length > 0) itemArray[itemArray.length - 1].isLastItemInGroup = false;\n\n const allowSpaceForLeadingIcons = itemArray.some(\n (i) => 'iconPathBefore' in i.item && i.item.iconPathBefore,\n );\n\n return { items: itemArray, allowForLeadingIcons: allowSpaceForLeadingIcons };\n }, [includedGroups, menuDefinition]);\n\n // Create props for MenuItem component including setting hasDivider for the last item in a group\n const createMenuItemProps = ({ item, isLastItemInGroup }: ItemInfo) => {\n const menuItemProps = {\n className: 'papi-menu-item',\n label: item.label,\n tooltip: item.tooltip,\n iconPathBefore: 'iconPathBefore' in item ? item.iconPathBefore : undefined,\n iconPathAfter: 'iconPathAfter' in item ? item.iconPathAfter : undefined,\n hasDivider: isLastItemInGroup, // Set hasDivider to true for the last item in a group\n allowForLeadingIcons,\n };\n\n return menuItemProps;\n };\n\n const [firstItem] = items;\n\n if (!firstItem) return
    ;\n\n const divKey = firstItem.item.group;\n\n return (\n
    \n {items.map((itemInfo, index) => {\n const { item } = itemInfo;\n const menuItemProps = createMenuItemProps(itemInfo);\n if ('command' in item) {\n const key = item.group + index;\n return (\n ) => {\n onClick?.(event);\n commandHandler(item);\n }}\n {...menuItemProps}\n />\n );\n }\n return (\n \n );\n })}\n
    \n );\n}\n","import GroupedMenuItemList from '@/components/mui/grouped-menu-item-list.component';\nimport { MenuItemListProps } from '@/components/mui/menu-item.component';\nimport { MultiColumnMenu } from 'platform-bible-utils';\n\n/**\n * This component is internal; it does not need to be exposed to the outside world since it is not\n * useful on its own. Use either GridMenu or ContextMenu.\n */\nexport default function TopLevelMenu(props: MenuItemListProps) {\n const { menuDefinition, columnId } = props;\n\n const groupEntries = Object.entries(menuDefinition.groups);\n // Convert array of entries to array of objects with id and group properties\n const groups = groupEntries.map(([key, value]) => ({ id: key, group: value }));\n let includedGroups = groups.filter((g) => 'column' in g.group);\n\n // Check if column is provided and menuDefinition is a MultiColumnMenu\n if (\n columnId &&\n 'columns' in menuDefinition &&\n // Without this type assertion, TS doesn't know what columns is.\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n (menuDefinition as MultiColumnMenu).columns[columnId]\n ) {\n // When laying out a single column in a MultiColumnMenu, only include groups associated with\n // the provided column. Note: without the (annoying) redundant check that the included groups\n // have the colum field, TS doesn't think it exists.\n includedGroups = includedGroups.filter(\n (g) => 'column' in g.group && g.group.column === columnId,\n );\n }\n\n return ;\n}\n","import '@/components/mui/grid-menu.component.css';\nimport { GroupedMenuPropsBase } from '@/components/mui/grouped-menu-item-list.component';\nimport { CommandHandler } from '@/components/mui/menu-item.component';\nimport TopLevelMenu from '@/components/mui/top-level-menu.component';\nimport { Grid, List } from '@mui/material';\nimport {\n Localized,\n MenuColumnWithHeader,\n MultiColumnMenu,\n ReferencedItem,\n} from 'platform-bible-utils';\nimport { useMemo } from 'react';\n\ntype ColumnInfo = {\n /*\n * The ID (`${string}.${string}`) of a specific menu column.\n */\n id: ReferencedItem;\n\n /*\n * Metadata (label, order, etc.) for a specific menu column.\n */\n metadata: Localized;\n};\n\ntype MenuColumnProps = ColumnInfo &\n GroupedMenuPropsBase & {\n /** Additional css classes to help with unique styling of the menu column */\n className?: string;\n };\n\nexport type GridMenuInfo = {\n /** The menu object containing information about the columns, groups, and items to display. */\n multiColumnMenu: Localized;\n};\n\nexport type GridMenuProps = GridMenuInfo & {\n /** Optional unique identifier */\n id?: string;\n\n commandHandler: CommandHandler;\n\n /** Additional css classes to help with unique styling of the grid menu */\n className?: string;\n};\n\nfunction MenuColumn({\n commandHandler,\n menuDefinition,\n id,\n metadata,\n onClick,\n className,\n}: MenuColumnProps) {\n return (\n \n

    \n {metadata.label}\n

    \n {/* It would seem as though this List component were unnecessary, since it only contains one\n thing, but the \"dense\" property does affect the layout of the items (in a way I don't fully\n understand). There might be a better way. */}\n \n \n \n \n );\n}\n\nexport default function GridMenu({\n commandHandler,\n className,\n multiColumnMenu,\n id,\n}: GridMenuProps) {\n const { columns } = multiColumnMenu;\n\n const sortedColumns = useMemo(() => {\n const columnNumbers = new Map();\n Object.getOwnPropertyNames(columns).forEach((columnName: string) => {\n // We know for sure there is a (boolean) property 'isExtensible' that we are not interested in.\n if (columnName === 'isExtensible') return;\n // TS doesn't allow `columnName` above to be a ReferencedItem even though the type says it is\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const columnId = columnName as ReferencedItem;\n const column = columns[columnId];\n // As of right now (and hopefully forever after), all remaining properties of the\n // ColumnsWithHeaders object are columns whose property names are the IDs of the columns.\n // This is an additional (redundant) sanity check. Specifically we're interested in\n // MenuColumnWithHeader objects, which TypeScript now \"knows\" we have, but at runtime all we\n // can check for is that it's an object with a valid numeric order field. That's likely good\n // enough.\n if (\n typeof column === 'object' &&\n typeof column.order === 'number' &&\n !Number.isNaN(column.order)\n )\n columnNumbers.set(column.order, { id: columnId, metadata: column });\n else\n console.warn(\n `Property ${columnName} (${typeof column}) on menu ${id} is not a valid column and is being ignored. This might indicate data corruption`,\n );\n });\n\n // Extract values and sort them based on the 'order' property\n return Array.from(columnNumbers.values()).sort((a, b) => {\n return (a.metadata.order || 0) - (b.metadata.order || 0);\n });\n }, [columns, id]);\n\n // We might need something like this if we need to be able to prevent empty columns\n // sortedColumns.filter((c) => multiColumnMenu.groups.some((g) => 'column' in g && (g as .column)...\n\n return (\n \n {sortedColumns.map((col, index) => (\n \n ))}\n \n );\n}\n","import { useEffect, useRef, useState } from 'react';\n\nexport type UsePromiseOptions = {\n /**\n * Whether to leave the value as the most recent resolved promise value or set it back to\n * defaultValue while running the promise again. Defaults to true\n */\n preserveValue?: boolean;\n};\n\n/** Set up defaults for options for usePromise hook */\nfunction getUsePromiseOptionsDefaults(options: UsePromiseOptions): UsePromiseOptions {\n return {\n preserveValue: true,\n ...options,\n };\n}\n\n/**\n * Awaits a promise and returns a loading value while the promise is unresolved\n *\n * @param promiseFactoryCallback A function that returns the promise to await. If this callback is\n * undefined, the current value will be returned (defaultValue unless it was previously changed\n * and `options.preserveValue` is true), and there will be no loading.\n *\n * WARNING: MUST BE STABLE - const or wrapped in useCallback. The reference must not be updated\n * every render\n * @param defaultValue The initial value to return while first awaiting the promise. If\n * `options.preserveValue` is false, this value is also shown while awaiting the promise on\n * subsequent calls.\n *\n * Note: this parameter is internally assigned to a `ref`, so changing it will not cause any hooks\n * to re-run with its new value. This means that, if the `promiseFactoryCallback` changes and\n * `options.preserveValue` is `false`, the returned value will be set to the current\n * `defaultValue`. However, the returned value will not be updated if`defaultValue` changes.\n * @param options Various options for adjusting how this hook runs the `promiseFactoryCallback`\n *\n * Note: this parameter is internally assigned to a `ref`, so changing it will not cause any hooks\n * to re-run with its new value. However, the latest `options.preserveValue` will always be used\n * appropriately to determine whether to preserve the returned value when changing the\n * `promiseFactoryCallback`\n * @returns `[value, isLoading]`\n *\n * - `value`: the current value for the promise, either the defaultValue or the resolved promise value\n * - `isLoading`: whether the promise is waiting to be resolved\n */\nconst usePromise = (\n promiseFactoryCallback: (() => Promise) | undefined,\n defaultValue: T,\n options: UsePromiseOptions = {},\n): [value: T, isLoading: boolean] => {\n // Use defaultValue as a ref so it doesn't update dependency arrays\n const defaultValueRef = useRef(defaultValue);\n defaultValueRef.current = defaultValue;\n // Use options as a ref so it doesn't update dependency arrays\n const optionsDefaultedRef = useRef(options);\n optionsDefaultedRef.current = getUsePromiseOptionsDefaults(optionsDefaultedRef.current);\n\n const [value, setValue] = useState(() => defaultValueRef.current);\n const [isLoading, setIsLoading] = useState(true);\n useEffect(() => {\n let promiseIsCurrent = true;\n // If a promiseFactoryCallback was provided, we are loading. Otherwise, there is no loading to do\n setIsLoading(!!promiseFactoryCallback);\n (async () => {\n // If there is a callback to run, run it\n if (promiseFactoryCallback) {\n const result = await promiseFactoryCallback();\n // If the promise was not already replaced, update the value\n if (promiseIsCurrent) {\n setValue(() => result);\n setIsLoading(false);\n }\n }\n })();\n\n return () => {\n // Mark this promise as old and not to be used\n promiseIsCurrent = false;\n if (!optionsDefaultedRef.current.preserveValue) setValue(() => defaultValueRef.current);\n };\n }, [promiseFactoryCallback]);\n\n return [value, isLoading];\n};\nexport default usePromise;\n","\"use client\";\n\nimport createSvgIcon from './utils/createSvgIcon';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nexport default createSvgIcon( /*#__PURE__*/_jsx(\"path\", {\n d: \"M3 18h18v-2H3zm0-5h18v-2H3zm0-7v2h18V6z\"\n}), 'Menu');","import GridMenu from '@/components/mui/grid-menu.component';\nimport { Command, CommandHandler } from '@/components/mui/menu-item.component';\nimport usePromise from '@/hooks/use-promise.hook';\nimport { Menu as MenuIcon } from '@mui/icons-material';\nimport { Drawer, IconButton } from '@mui/material';\nimport { Localized, MultiColumnMenu } from 'platform-bible-utils';\nimport {\n MouseEvent,\n MutableRefObject,\n PropsWithChildren,\n useCallback,\n useEffect,\n useState,\n} from 'react';\n\nexport interface MultiColumnMenuProvider {\n (isSupportAndDevelopment: boolean): Promise>;\n}\n\nexport type HamburgerMenuButtonProps = PropsWithChildren & {\n /** The handler to use for menu commands (and eventually toolbar commands). */\n commandHandler: CommandHandler;\n\n /**\n * Optional reference to the \"div\" container that determines the where the menu should appear. If\n * not defined, then (1,1) used.\n */\n containerRef?: MutableRefObject;\n\n /**\n * The delegate to use to get the menu data. If not specified or if it returns undefined, the data\n * in normalMenu or fullMenu property will be used.\n */\n menuProvider?: MultiColumnMenuProvider;\n\n /**\n * The menu data to show when the menu is opened if the menuProvider property is not defined.\n * (This allows for a default or test-only static menu to be used.)\n */\n normalMenu?: Localized;\n\n /**\n * The menu data to show for \"full\" menu (when opened with the SHIFT key pressed) if the\n * menuProvider property is not defined. (This allows for a default or test-only static menu to be\n * used.)\n */\n fullMenu?: Localized;\n\n /** Additional css class(es) to help with unique styling of the sub-components */\n className?: string;\n\n /** Value to use as prefix for ARIA labels on interactive sub-components */\n ariaLabelPrefix?: string;\n};\n\nexport default function HamburgerMenuButton({\n menuProvider,\n normalMenu,\n fullMenu,\n commandHandler,\n containerRef,\n className,\n ariaLabelPrefix,\n children,\n}: HamburgerMenuButtonProps) {\n const [isMenuOpen, setMenuOpen] = useState(false);\n const [showFullMenu, setShowFullMenu] = useState(false);\n\n const handleMenuItemClick = useCallback(() => {\n if (isMenuOpen) setMenuOpen(false);\n setShowFullMenu(false);\n }, [isMenuOpen]);\n\n const handleMenuButtonClick = useCallback((e: MouseEvent) => {\n e.stopPropagation();\n setMenuOpen((prevIsOpen) => {\n const isOpening = !prevIsOpen;\n if (isOpening && e.shiftKey) setShowFullMenu(true);\n else if (!isOpening) setShowFullMenu(false);\n return isOpening;\n });\n }, []);\n\n const menuCommandHandler = useCallback(\n (command: Command) => {\n handleMenuItemClick();\n return commandHandler(command);\n },\n [commandHandler, handleMenuItemClick],\n );\n\n const [offset, setOffset] = useState({ top: 1, left: 1 });\n\n useEffect(() => {\n if (isMenuOpen) {\n const node = containerRef?.current;\n if (node) {\n const rect = node.getBoundingClientRect();\n const scrollTop = window.scrollY;\n const scrollLeft = window.scrollX;\n const top = rect.top + scrollTop + node.clientHeight;\n const left = rect.left + scrollLeft;\n setOffset({ top, left });\n }\n }\n }, [isMenuOpen, containerRef]);\n\n const [normalMenuData] = usePromise(\n useCallback(async () => {\n return menuProvider?.(false) ?? normalMenu;\n // isMenuOpen needs to be included for the menu contents to reevaluate when reopened\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [menuProvider, normalMenu, isMenuOpen]),\n normalMenu,\n );\n\n const [fullMenuData] = usePromise(\n useCallback(async () => {\n return menuProvider?.(true) ?? fullMenu ?? normalMenuData;\n // isMenuOpen needs to be included for the menu contents to reevaluate when reopened\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [menuProvider, fullMenu, normalMenuData, isMenuOpen]),\n fullMenu ?? normalMenuData,\n );\n\n const menu = showFullMenu && fullMenuData ? fullMenuData : normalMenuData;\n\n return (\n <>\n \n {children ?? }\n \n \n {menu ? (\n \n ) : undefined}\n \n \n );\n}\n","import '@/components/mui/icon-button.component.css';\nimport { IconButton as MuiIconButton } from '@mui/material';\nimport { MouseEventHandler, PropsWithChildren } from 'react';\n\nexport type IconButtonProps = PropsWithChildren<{\n /** Optional unique identifier */\n id?: string;\n /**\n * Required. Used as both the tooltip (aka, title) and the aria-label (used for accessibility,\n * testing, etc.), unless a distinct tooltip is supplied.\n */\n label: string;\n /**\n * Enabled status of button\n *\n * @default false\n */\n isDisabled?: boolean;\n /** Optional tooltip to display if different from the aria-label. */\n tooltip?: string;\n /** If true, no tooltip will be displayed. */\n isTooltipSuppressed?: boolean;\n /**\n * If given, uses a negative margin to counteract the padding on one side (this is often helpful\n * for aligning the left or right side of the icon with content above or below, without ruining\n * the border size and shape).\n *\n * @default false\n */\n adjustMarginToAlignToEdge?: 'end' | 'start' | false;\n /**\n * The size of the component. small is equivalent to the dense button styling.\n *\n * @default false\n */\n size: 'small' | 'medium' | 'large';\n /** Additional css classes to help with unique styling of the button */\n className?: string;\n /** Optional click handler */\n onClick?: MouseEventHandler;\n}>;\n\n/**\n * Iconic button a user can click to do something\n *\n * Thanks to MUI for heavy inspiration and documentation\n * https://mui.com/material-ui/getting-started/overview/\n */\nfunction IconButton({\n id,\n label,\n isDisabled = false,\n tooltip,\n isTooltipSuppressed = false,\n adjustMarginToAlignToEdge = false,\n size = 'medium',\n className,\n onClick,\n children,\n}: IconButtonProps) {\n return (\n \n {children /* the icon to display */}\n \n );\n}\n\nexport default IconButton;\n","import { cn } from '@/utils/shadcn-ui.util';\nimport { LoaderCircle, LucideProps } from 'lucide-react';\nimport { forwardRef } from 'react';\n\nexport type SpinnerProps = LucideProps;\n\nconst Spinner = forwardRef(({ className, ...props }, ref) => {\n return (\n \n );\n});\n\nSpinner.displayName = 'Spinner';\n\nexport default Spinner;\n","import { Input as ShadInput } from '@/components/shadcn-ui/input';\nimport { Label as ShadLabel } from '@/components/shadcn-ui/label';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { ChangeEventHandler, FocusEventHandler } from 'react';\n\nexport type TextFieldProps = {\n /** Optional unique identifier */\n id?: string;\n /**\n * If `true`, the component is disabled.\n *\n * @default false\n */\n isDisabled?: boolean;\n /**\n * If `true`, the label is displayed in an error state.\n *\n * @default false\n */\n hasError?: boolean;\n /**\n * If `true`, the input will take up the full width of its container.\n *\n * @default false\n */\n isFullWidth?: boolean;\n /** Text that gives the user instructions on what contents the TextField expects */\n helperText?: string;\n /** The title of the TextField */\n label?: string;\n /** The short hint displayed in the `input` before the user enters a value. */\n placeholder?: string;\n /**\n * If `true`, the label is displayed as required and the `input` element is required.\n *\n * @default false\n */\n isRequired?: boolean;\n /** Additional css classes to help with unique styling of the text field */\n className?: string;\n /** Starting value for the text field if it is not controlled */\n defaultValue?: string | number;\n /** Value of the text field if controlled */\n value?: string | number;\n /** Triggers when content of textfield is changed */\n onChange?: ChangeEventHandler;\n /** Triggers when textfield gets focus */\n onFocus?: FocusEventHandler;\n /** Triggers when textfield loses focus */\n onBlur?: FocusEventHandler;\n};\n\n/**\n * Text input field\n *\n * Thanks to Shadcn for heavy inspiration and documentation\n * https://ui.shadcn.com/docs/components/input#with-label\n */\nfunction TextField({\n id,\n isDisabled = false,\n hasError = false,\n isFullWidth = false,\n helperText,\n label,\n placeholder,\n isRequired = false,\n className,\n defaultValue,\n value,\n onChange,\n onFocus,\n onBlur,\n}: TextFieldProps) {\n return (\n
    \n {`${label}${isRequired ? '*' : ''}`}\n \n

    {helperText}

    \n
    \n );\n}\n\nexport default TextField;\n","import HamburgerMenuButton, {\n MultiColumnMenuProvider,\n} from '@/components/mui/hamburger-menu-button.component';\nimport { CommandHandler } from '@/components/mui/menu-item.component';\nimport '@/components/mui/toolbar.component.css';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { AppBar, Toolbar as MuiToolbar } from '@mui/material';\nimport { PropsWithChildren, useRef } from 'react';\n\nexport type ToolbarProps = PropsWithChildren<{\n /** The handler to use for menu commands (and eventually toolbar commands). */\n commandHandler: CommandHandler;\n\n /**\n * The optional delegate to use to get the menu data. If not specified, the \"hamburger\" menu will\n * not display.\n */\n menuProvider?: MultiColumnMenuProvider;\n\n /** Optional unique identifier */\n id?: string;\n\n /** Additional css classes to help with unique styling of the toolbar */\n className?: string;\n}>;\n\nexport default function Toolbar({\n menuProvider,\n commandHandler,\n className,\n id,\n children,\n}: ToolbarProps) {\n // This ref will always be defined\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const containerRef = useRef(undefined!);\n\n return (\n
    \n \n \n {menuProvider ? (\n \n ) : undefined}\n {children ?
    {children}
    : undefined}\n \n
    \n
    \n );\n}\n","import React from 'react';\nimport { cva, type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst alertVariants = cva(\n 'tw-relative tw-w-full tw-rounded-lg tw-border tw-p-4 [&>svg~*]:tw-pl-7 [&>svg+div]:tw-translate-y-[-3px] [&>svg]:tw-absolute [&>svg]:tw-left-4 [&>svg]:tw-top-4 [&>svg]:tw-text-foreground',\n {\n variants: {\n variant: {\n default: 'tw-bg-background tw-text-foreground',\n destructive:\n 'tw-border-destructive/50 tw-text-destructive dark:tw-border-destructive [&>svg]:tw-text-destructive',\n },\n },\n defaultVariants: {\n variant: 'default',\n },\n },\n);\n\nconst Alert = React.forwardRef<\n HTMLDivElement,\n React.HTMLAttributes & VariantProps\n>(({ className, variant, ...props }, ref) => (\n
    \n));\nAlert.displayName = 'Alert';\n\nconst AlertTitle = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n {/* added because of https://github.com/jsx-eslint/eslint-plugin-jsx-a11y/blob/main/docs/rules/heading-has-content.md */}\n {props.children}{' '}\n \n ),\n);\nAlertTitle.displayName = 'AlertTitle';\n\nconst AlertDescription = React.forwardRef<\n HTMLParagraphElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n
    \n));\nAlertDescription.displayName = 'AlertDescription';\n\nexport { Alert, AlertTitle, AlertDescription };\n","import React from 'react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Card = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nCard.displayName = 'Card';\n\nconst CardHeader = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nCardHeader.displayName = 'CardHeader';\n\nconst CardTitle = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n {/* added because of https://github.com/jsx-eslint/eslint-plugin-jsx-a11y/blob/main/docs/rules/heading-has-content.md */}\n {props.children}\n \n ),\n);\nCardTitle.displayName = 'CardTitle';\n\nconst CardDescription = React.forwardRef<\n HTMLParagraphElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n

    \n));\nCardDescription.displayName = 'CardDescription';\n\nconst CardContent = React.forwardRef>(\n ({ className, ...props }, ref) => (\n

    \n ),\n);\nCardContent.displayName = 'CardContent';\n\nconst CardFooter = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nCardFooter.displayName = 'CardFooter';\n\nexport { Card, CardHeader, CardFooter, CardTitle, CardDescription, CardContent };\n","import { ComponentProps } from 'react';\nimport { toast as sonner, Toaster } from 'sonner';\n\ntype SonnerProps = ComponentProps;\n\nfunction Sonner({ ...props }: SonnerProps) {\n return (\n \n );\n}\n\n// The re-export of the sonner function was added manually\nexport { Sonner, sonner };\n","import React from 'react';\nimport * as SliderPrimitive from '@radix-ui/react-slider';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Slider = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n \n \n \n));\nSlider.displayName = SliderPrimitive.Root.displayName;\n\nexport { Slider };\n","import React from 'react';\nimport * as SwitchPrimitives from '@radix-ui/react-switch';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Switch = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n));\nSwitch.displayName = SwitchPrimitives.Root.displayName;\n\nexport { Switch };\n","import React from 'react';\nimport * as TabsPrimitive from '@radix-ui/react-tabs';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport const Tabs = TabsPrimitive.Root;\n\nexport type TabsListProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport type TabsTriggerProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport type TabsContentProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport const TabsList = React.forwardRef<\n React.ElementRef,\n TabsListProps\n>(({ className, ...props }, ref) => (\n \n));\nTabsList.displayName = TabsPrimitive.List.displayName;\n\nexport const TabsTrigger = React.forwardRef<\n React.ElementRef,\n TabsTriggerProps\n>(({ className, ...props }, ref) => (\n \n));\nTabsTrigger.displayName = TabsPrimitive.Trigger.displayName;\n\nexport const TabsContent = React.forwardRef<\n React.ElementRef,\n TabsContentProps\n>(({ className, ...props }, ref) => (\n \n));\nTabsContent.displayName = TabsPrimitive.Content.displayName;\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Download } from 'lucide-react';\n\ntype InstallButtonProps = {\n /** The installing boolean value determines the state of the button. */\n isInstalling: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n /** Optional text for the button. */\n buttonText?: string;\n} & ButtonProps;\n\n/**\n * The InstallButton component is a button designed for initiating installs. It includes visuals for\n * active installing and idle states.\n *\n * @param isInstalling The installing boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @param buttonText Optional text for the button.\n * @returns A install button.\n */\nexport default function InstallButton({\n isInstalling,\n handleClick,\n buttonText,\n className,\n ...props\n}: InstallButtonProps) {\n return (\n \n {isInstalling ? (\n \n ) : (\n <>\n \n {buttonText}\n \n )}\n \n );\n}\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\n\ntype EnableButtonProps = {\n /** The enabling boolean value determines the state of the button. */\n isEnabling: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n} & ButtonProps;\n\n/**\n * The EnableButton component is a button designed for initiating enabling of downloads. It includes\n * visuals for active enabling and idle states.\n *\n * @param isEnabling The enabling boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @returns A button that can be used to enable.\n */\nexport default function EnableButton({\n isEnabling,\n handleClick,\n className,\n ...props\n}: EnableButtonProps) {\n return (\n \n {isEnabling ? (\n <>\n \n Enabling...\n \n ) : (\n 'Enable'\n )}\n \n );\n}\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\n\ntype DisableButtonProps = {\n /** The disabling boolean value determines the state of the button. */\n isDisabling: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n} & ButtonProps;\n\n/**\n * The DisableButton component is a button designed for initiating disabling of downloads. It\n * includes visuals for active disabling and idle states.\n *\n * @param isDisabling The disabling boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @returns A button that can be used to disable.\n */\nexport default function DisableButton({\n isDisabling,\n handleClick,\n className,\n ...props\n}: DisableButtonProps) {\n return (\n \n {isDisabling ? (\n <>\n \n Disabling...\n \n ) : (\n 'Disable'\n )}\n \n );\n}\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\n\ntype UpdateButtonProps = {\n /** The updating boolean value determines the state of the button. */\n isUpdating: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n} & ButtonProps;\n\n/**\n * The UpdateButton component is a button designed for initiating updates for downloaded extensions.\n * It includes visuals for active updating and idle states.\n *\n * @param isUpdating The updating boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @returns A button that can be used to update.\n */\nexport default function UpdateButton({\n isUpdating,\n handleClick,\n className,\n ...props\n}: UpdateButtonProps) {\n return (\n \n {isUpdating ? (\n <>\n \n Updating...\n \n ) : (\n 'Update'\n )}\n \n );\n}\n","import { cn } from '@/utils/shadcn-ui.util';\nimport Markdown, { MarkdownToJSX } from 'markdown-to-jsx';\nimport { useMemo } from 'react';\n\ninterface MarkdownRendererProps {\n /** Optional unique identifier */\n id?: string;\n /** The markdown string to render */\n markdown: string;\n className?: string;\n /**\n * The [`target` attribute for `a` html\n * tags](https://developer.mozilla.org/en-US/docs/Web/HTML/Element/a#target). Defaults to not\n * adding a `target` to `a` tags\n */\n anchorTarget?: string;\n}\n\n/**\n * This component renders markdown content given a markdown string. It uses typography styles from\n * the platform.\n *\n * @param markdown The markdown string to render.\n * @param id Optional unique identifier\n * @returns A div containing the rendered markdown content.\n */\nexport default function MarkdownRenderer({\n id,\n markdown,\n className,\n anchorTarget,\n}: MarkdownRendererProps) {\n const options: MarkdownToJSX.Options = useMemo(\n () => ({\n overrides: {\n a: {\n props: {\n target: anchorTarget,\n },\n },\n },\n }),\n [anchorTarget],\n );\n return (\n
    \n {markdown}\n
    \n );\n}\n","import { Filter, ChevronDown } from 'lucide-react';\nimport { forwardRef } from 'react';\nimport { Button } from '@/components/shadcn-ui/button';\n\n/**\n * The FilterButton component is a button designed for initiating filtering of data. It is designed\n * to be used with the dropdown menu. It uses forwardRef to pass the button to the dropdown trigger\n * asChild.\n *\n * @returns A button that can be used to filter.\n */\nconst FilterButton = forwardRef((props, ref) => {\n return (\n \n \n Filter\n \n \n );\n});\n\nexport default FilterButton;\n","import {\n DropdownMenu,\n DropdownMenuTrigger,\n DropdownMenuContent,\n DropdownMenuLabel,\n DropdownMenuGroup,\n DropdownMenuCheckboxItem,\n DropdownMenuRadioItem,\n DropdownMenuSeparator,\n} from '@/components/shadcn-ui/dropdown-menu';\nimport FilterButton from './buttons/filter-button.component';\n\nexport enum DropdownMenuItemType {\n Check,\n Radio,\n}\n\nexport type DropdownItem = {\n /** The label is the text that will be displayed on the dropdown item. */\n label: string;\n /** The itemType determines the DropdownMenuItemType type as either Check or Radio. */\n itemType: DropdownMenuItemType;\n /** The onClick function is called when the item is clicked. */\n onClick: () => void;\n};\n\nexport type DropdownGroup = {\n /**\n * The label is the text that will be displayed on the dropdown group. It is used to categorize\n * the items in the group.\n */\n label: string;\n /** The items array contains the items that will be displayed in the dropdown group */\n items: DropdownItem[];\n};\n\nexport type FilterDropdownProps = {\n /** Object unique identifier */\n id?: string;\n /** The groups array contains the groups that will be displayed in the dropdown */\n groups: DropdownGroup[];\n}; // TODO: extend the props later\n\n/**\n * The FilterDropdown component is a dropdown designed for filtering content. It includes groups of\n * items that can be checkboxes or radio items.\n *\n * @param id Optional unique identifier\n * @param groups The groups array contains the groups that will be displayed in the dropdown\n * @returns A filter dropdown.\n */\nexport default function FilterDropdown({ id, groups }: FilterDropdownProps) {\n return (\n
    \n {/* TODO: remove this once the DropDown Menu shadcn has an id prop */}\n \n \n \n \n \n {groups.map((group) => (\n
    \n {group.label}\n \n {group.items.map((item) => (\n
    \n {item.itemType === DropdownMenuItemType.Check ? (\n \n {item.label}\n \n ) : (\n \n {item.label}\n \n )}\n
    \n ))}\n
    \n \n
    \n ))}\n
    \n
    \n
    \n );\n}\n","interface NoExtensionsFoundProps {\n /** Optional unique identifier */\n id?: string;\n /** The message to display */\n message: string;\n}\n/**\n * This component displays a message to the user when no extensions are found in the marketplace.\n *\n * @param id Optional unique identifier\n * @param message The message to display.\n * @returns {JSX.Element} - Returns the message component that displays the message to the user.\n */\nexport default function NoExtensionsFound({ id, message }: NoExtensionsFoundProps) {\n return (\n
    \n
    \n

    {message}

    \n
    \n
    \n );\n}\n","import { CircleHelp, Link as LucideLink, User } from 'lucide-react';\nimport { NumberFormat } from 'platform-bible-utils';\n\n/** Interface that stores the parameters passed to the More Info component */\ninterface MoreInfoProps {\n /** Optional unique identifier */\n id?: string;\n /** The category of the extension */\n category: string;\n /** The number of downloads for the extension */\n downloads: Record;\n /** The languages supported by the extension */\n languages: string[];\n /** The URL to the more info page of the extension */\n moreInfoUrl: string;\n}\n/**\n * This component displays the more info section of the extension which includes the category,\n * number of downloads, languages, and links to the website and support\n *\n * @param id Optional unique identifier\n * @param category The category of the extension\n * @param downloads The number of downloads for the extension\n * @param languages The languages supported by the extension\n * @param moreInfoUrl The URL to the more info page of the extension\n * @returns {JSX.Element} - Returns the more info component that displays the category, number of\n * downloads, languages, and links to the website and support\n */\nexport default function MoreInfo({\n id,\n category,\n downloads,\n languages,\n moreInfoUrl,\n}: MoreInfoProps) {\n /**\n * This constant formats the number of downloads into a more readable format.\n *\n * @example 1000 -> 1K\n *\n * @example 1000000 -> 1M\n *\n * @returns The formatted number of downloads\n */\n const numberFormatted = new NumberFormat('en', {\n notation: 'compact',\n compactDisplay: 'short',\n }).format(Object.values(downloads).reduce((a: number, b: number) => a + b, 0));\n\n /** This function scrolls the window to the bottom of the page. */\n const handleScrollToBottom = () => {\n window.scrollTo(0, document.body.scrollHeight);\n };\n\n return (\n \n
    \n
    \n {category}\n
    \n CATEGORY\n
    \n
    \n
    \n
    \n \n {numberFormatted}\n
    \n USERS\n
    \n
    \n
    \n
    \n {languages.slice(0, 3).map((locale) => (\n \n {locale.toUpperCase()}\n \n ))}\n
    \n {languages.length > 3 && (\n handleScrollToBottom()}\n className=\"tw-text-xs tw-text-gray-500 tw-underline\"\n >\n +{languages.length - 3} more languages\n \n )}\n
    \n
    \n
    \n \n Website\n \n \n \n Support\n \n \n
    \n
    \n );\n}\n","import { useState } from 'react';\n\nexport type VersionInformation = {\n /** Date the version was published */\n date: string;\n /** Description of the changes in the version */\n description: string;\n};\n\n/** Type to store the version history information */\nexport type VersionHistoryType = Record;\n\n/** Interface that stores the parameters passed to the Version History component */\ninterface VersionHistoryProps {\n /** Optional unique identifier */\n id?: string;\n /** Object containing the versions mapped with their information */\n versionHistory: VersionHistoryType;\n}\n\n/**\n * Component to render the version history information shown in the footer component. Lists the 5\n * most recent versions, with the options to show all versions by pressing a button.\n *\n * @param versionHistory Object containing the versions mapped with their information\n * @param id Optional unique identifier\n * @returns Rendered version history for the Footer component\n */\nexport default function VersionHistory({ id, versionHistory }: VersionHistoryProps) {\n const [showAllVersions, setShowAllVersions] = useState(false);\n const currentDate = new Date();\n\n /**\n * Function to format the time string for the version history in the form of 'X year(s) ago'.\n *\n * @param dateString ISO Date string to determine the time string from\n * @returns Formatted time string\n */\n function formatTimeString(dateString: string) {\n const date = new Date(dateString);\n const dateDiff = new Date(currentDate.getTime() - date.getTime());\n const yearDiff = dateDiff.getUTCFullYear() - 1970;\n const monthDiff = dateDiff.getUTCMonth();\n const dayDiff = dateDiff.getUTCDate() - 1;\n\n // Determines how long ago the version was published\n let timeString = '';\n if (yearDiff > 0) {\n timeString = `${yearDiff.toString()} year${yearDiff === 1 ? '' : 's'} ago`;\n } else if (monthDiff > 0) {\n timeString = `${monthDiff.toString()} month${monthDiff === 1 ? '' : 's'} ago`;\n } else if (dayDiff === 0) {\n timeString = 'today';\n } else {\n timeString = `${dayDiff.toString()} day${dayDiff === 1 ? '' : 's'} ago`;\n }\n\n return timeString;\n }\n\n // Sorts the version history by version number\n const sortedEntries = Object.entries(versionHistory).sort((a, b) => b[0].localeCompare(a[0]));\n\n return (\n
    \n

    What`s New

    \n
      \n {(showAllVersions ? sortedEntries : sortedEntries.slice(0, 5)).map((entry) => (\n
      \n
      \n
    • \n {entry[1].description}\n
    • \n
      \n
      \n
      Version {entry[0]}
      \n
      {formatTimeString(entry[1].date)}
      \n
      \n
      \n ))}\n
    \n {sortedEntries.length > 5 && (\n setShowAllVersions(!showAllVersions)}\n className=\"tw-text-xs tw-text-gray-500 tw-underline\"\n >\n {showAllVersions ? 'Show Less Version History' : 'Show All Version History'}\n \n )}\n
    \n );\n}\n","import { useMemo } from 'react';\nimport { formatBytes } from 'platform-bible-utils';\nimport VersionHistory, { VersionHistoryType } from './version-history.component';\n\n/** Interface to store the parameters passed to the Footer component */\ninterface FooterProps {\n /** Optional unique identifier */\n id?: string;\n /** Name of the publisher */\n publisherDisplayName: string;\n /** Size of the extension file in bytes */\n fileSize: number;\n /** List of language codes supported by the extension */\n locales: string[];\n /** Object containing the version history mapped with their information */\n versionHistory: VersionHistoryType;\n}\n\n/**\n * Component to render the footer for the extension details which contains information on the\n * publisher, version history, languages, and file size.\n *\n * @param id Optional unique identifier\n * @param publisherDisplayName Name of the publisher\n * @param fileSize Size of the extension file in bytes\n * @param locales List of language codes supported by the extension\n * @param versionHistory Object containing the version history mapped with their information\n * @returns The rendered Footer component\n */\nexport default function Footer({\n id,\n publisherDisplayName,\n fileSize,\n locales,\n versionHistory,\n}: FooterProps) {\n /** Formats the file size into a human-readable format */\n const formattedFileSize = useMemo(() => formatBytes(fileSize), [fileSize]);\n\n /**\n * This function gets the display names of the languages based on the language codes.\n *\n * @param codes The list of language codes\n * @returns The list of language names\n */\n const getLanguageNames = (codes: string[]) => {\n const displayNames = new Intl.DisplayNames(navigator.language, { type: 'language' });\n return codes.map((code) => displayNames.of(code));\n };\n\n const languageNames = getLanguageNames(locales);\n\n return (\n
    \n
    \n \n
    \n
    \n

    Information

    \n
    \n

    \n Publisher\n {publisherDisplayName}\n Size\n {formattedFileSize}\n

    \n
    \n

    \n Languages\n {languageNames.join(', ')}\n

    \n
    \n
    \n
    \n
    \n
    \n );\n}\n","import { PlatformEvent, PlatformEventHandler } from 'platform-bible-utils';\nimport { useEffect } from 'react';\n\n/**\n * Adds an event handler to an event so the event handler runs when the event is emitted. Use\n * `papi.network.getNetworkEvent` to use a networked event with this hook.\n *\n * @param event The event to subscribe to.\n *\n * - If event is a `PlatformEvent`, that event will be used\n * - If event is undefined, the callback will not be subscribed. Useful if the event is not yet\n * available for example\n *\n * @param eventHandler The callback to run when the event is emitted\n *\n * WARNING: MUST BE STABLE - const or wrapped in useCallback. The reference must not be updated\n * every render\n */\nconst useEvent = (\n event: PlatformEvent | undefined,\n eventHandler: PlatformEventHandler,\n) => {\n useEffect(() => {\n // Do nothing if the event is not provided (in case the event is not yet available, for example)\n if (!event) return () => {};\n\n const unsubscriber = event(eventHandler);\n return () => {\n unsubscriber();\n };\n }, [event, eventHandler]);\n};\nexport default useEvent;\n","import { useCallback, useEffect } from 'react';\nimport { PlatformEvent, PlatformEventAsync, PlatformEventHandler } from 'platform-bible-utils';\nimport usePromise from './use-promise.hook';\n\nconst noopUnsubscriber = () => false;\n\n/**\n * Adds an event handler to an asynchronously subscribing/unsubscribing event so the event handler\n * runs when the event is emitted. Use `papi.network.getNetworkEvent` to use a networked event with\n * this hook.\n *\n * @param event The asynchronously (un)subscribing event to subscribe to.\n *\n * - If event is a `PlatformEvent` or `PlatformEventAsync`, that event will be used\n * - If event is undefined, the callback will not be subscribed. Useful if the event is not yet\n * available for example\n *\n * @param eventHandler The callback to run when the event is emitted\n *\n * WARNING: MUST BE STABLE - const or wrapped in useCallback. The reference must not be updated\n * every render\n */\nconst useEventAsync = (\n event: PlatformEvent | PlatformEventAsync | undefined,\n eventHandler: PlatformEventHandler,\n) => {\n // Subscribe to the event asynchronously\n const [unsubscribe] = usePromise(\n useCallback(async () => {\n // Do nothing if the event is not provided (in case the event is not yet available, for example)\n if (!event) return noopUnsubscriber;\n\n // Wrap subscribe and unsubscribe in promises to allow normal events to be used as well\n const unsub = await Promise.resolve(event(eventHandler));\n return async () => unsub();\n }, [eventHandler, event]),\n noopUnsubscriber,\n // We want the unsubscriber to return to default value immediately upon changing subscription\n // So the useEffect below will unsubscribe asap\n { preserveValue: false },\n );\n\n // Unsubscribe from the event asynchronously (but we aren't awaiting the unsub)\n useEffect(() => {\n return () => {\n if (unsubscribe !== noopUnsubscriber) {\n unsubscribe();\n }\n };\n }, [unsubscribe]);\n};\n\nexport default useEventAsync;\n"],"names":["twMergeCustom","extendTailwindMerge","cn","inputs","clsx","Input","React","className","type","props","ref","jsx","BookChapterInput","forwardRef","handleSearch","handleKeyDown","handleOnClick","handleSubmit","jsxs","ShadInput","event","e","History","P","R","t","s","n","N","B","O","S","K","g","k","x","T","X","V","w","L","G","A","H","C","I","y","q","U","m","l","h","c","E","D","i","a","o","u","v","f","d","b","p","J","DropdownMenu","DropdownMenuPrimitive","DropdownMenuTrigger","DropdownMenuGroup","DropdownMenuPortal","DropdownMenuSub","DropdownMenuRadioGroup","DropdownMenuSubTrigger","inset","children","ChevronRight","DropdownMenuSubContent","DropdownMenuContent","sideOffset","DropdownMenuItem","DropdownMenuCheckboxItem","checked","Check","DropdownMenuRadioItem","Circle","DropdownMenuLabel","DropdownMenuSeparator","DropdownMenuShortcut","BookMenuItem","bookId","handleSelectBook","isSelected","handleHighlightBook","bookType","ShadDropdownMenuItem","Canon","ChapterSelect","handleSelectChapter","endChapter","activeChapter","highlightedChapter","handleHighlightedChapter","chapters","_","handleMouse","useCallback","chapterNumber","chapter","GoToMenuItem","handleSort","handleLocationHistory","handleBookmarks","ShadDropdownMenuLabel","ArrowDownWideNarrow","Clock","Bookmark","ALL_BOOK_IDS","BOOK_TYPE_LABELS","BOOK_TYPE_ARRAY","SCROLL_OFFSET","SEARCH_QUERY_FORMATS","fetchGroupedBooks","fetchEndChapter","getChaptersForBook","getAllEnglishNames","isValidBookEnglishName","bookName","getBookIdFromEnglishName","formattedBookName","BookChapterControl","scrRef","searchQuery","setSearchQuery","useState","selectedBookId","setSelectedBookId","setHighlightedChapter","highlightedBookId","setHighlightedBookId","isContentOpen","setIsContentOpen","isContentOpenDelayed","setIsContentOpenDelayed","inputRef","useRef","contentRef","menuItemRef","fetchFilteredBooks","englishNameLowerCase","normalizedQuery","handleSearchInput","searchString","shouldPreventAutoClosing","controlMenuState","open","updateReference","shouldClose","verse","handleInputSubmit","format","matches","book","englishName","handleKeyDownInput","handleKeyDownContent","key","handleKeyDownMenuItem","chapterOffSet","useEffect","useLayoutEffect","scrollTimeout","scrollPosition","ShadDropdownMenu","ShadDropdownMenuTrigger","ShadDropdownMenuContent","bookTypeIndex","element","ShadDropdownMenuSeparator","buttonVariants","cva","Button","variant","size","asChild","Comp","Slot","labelVariants","Label","LabelPrimitive","RadioGroup","RadioGroupPrimitive","RadioGroupItem","Popover","PopoverPrimitive","PopoverTrigger","PopoverContent","align","DialogPortal","DialogPrimitive","DialogOverlay","DialogContent","DialogTitle","DialogDescription","Command","CommandPrimitive","CommandInput","Search","CommandList","CommandEmpty","CommandGroup","CommandSeparator","CommandItem","getOptionLabelDefault","option","ComboBox","id","options","buttonClassName","popoverContentClassName","value","onChange","getOptionLabel","buttonPlaceholder","textPlaceholder","commandEmptyMessage","buttonVariant","dir","isDisabled","setOpen","ChevronsUpDown","ChapterRangeSelector","startChapter","handleSelectStartChapter","handleSelectEndChapter","chapterCount","chapterOptions","useMemo","index","onChangeStartChapter","onChangeEndChapter","Fragment","BookSelectionMode","BOOK_SELECTOR_STRING_KEYS","localizeString","strings","BookSelector","handleBookSelectionModeChange","currentBookName","onSelectBooks","selectedBookIds","localizedStrings","currentBookText","chooseText","chooseBooksText","bookSelectionMode","setBookSelectionMode","onSelectionModeChange","newMode","DataTableViewOptions","table","FilterIcon","column","Select","SelectPrimitive","SelectGroup","SelectValue","SelectTrigger","ChevronDown","SelectScrollUpButton","ChevronUp","SelectScrollDownButton","SelectContent","position","SelectLabel","SelectItem","SelectSeparator","DataTablePagination","pageSize","ArrowLeftIcon","ChevronLeftIcon","ChevronRightIcon","ArrowRightIcon","Table","stickyHeader","TableHeader","TableBody","TableFooter","TableRow","TableHead","TableCell","TableCaption","DataTable","columns","data","enablePagination","showPaginationControls","showColumnVisibilityControls","onRowClickHandler","sorting","setSorting","columnFilters","setColumnFilters","columnVisibility","setColumnVisibility","rowSelection","setRowSelection","useReactTable","getCoreRowModel","getPaginationRowModel","getSortedRowModel","getFilteredRowModel","headerGroup","header","flexRender","_a","row","cell","OccurrencesTable","occurrenceData","setScriptureReference","referenceHeaderText","occurrenceHeaderText","occurrences","uniqueOccurrences","occurrence","uniqueOccurrence","deepEqual","Checkbox","CheckboxPrimitive","getLinesFromUSFM","text","getNumberFromUSFM","regex","match","getBookNumFromId","getStatusForItem","item","approvedItems","unapprovedItems","toggleVariants","Toggle","TogglePrimitive","ToggleGroupContext","ToggleGroup","ToggleGroupPrimitive","ToggleGroupItem","context","getSortingIcon","sortDirection","ArrowUpIcon","ArrowDownIcon","ArrowUpDownIcon","inventoryItemColumn","itemLabel","inventoryAdditionalItemColumn","additionalItemLabel","additionalItemIndex","inventoryCountColumn","countLabel","statusChangeHandler","changedItems","newStatus","onApprovedItemsChange","onUnapprovedItemsChange","newApprovedItems","validItem","newUnapprovedItems","unapprovedItem","inventoryStatusColumn","statusLabel","status","CircleCheckIcon","CircleXIcon","CircleHelpIcon","INVENTORY_STRING_KEYS","filterItemData","itemData","statusFilter","textFilter","filteredItemData","createTableData","scriptureRef","itemRegex","tableData","currentBook","currentChapter","currentVerse","line","items","itemIndex","existingItem","tableEntry","newReference","substring","newItem","Inventory","scriptureReference","extractItems","additionalItemsLabels","scope","onScopeChange","allItemsText","approvedItemsText","unapprovedItemsText","unknownItemsText","scopeBookText","scopeChapterText","scopeVerseText","filterText","showAdditionalItemsText","showAdditionalItems","setShowAdditionalItems","setStatusFilter","setTextFilter","selectedItem","setSelectedItem","reducedTableData","newTableData","firstItem","existingEntry","newTableEntry","filteredTableData","allColumns","numberOfAdditionalItems","additionalColumns","_b","rowClickHandler","newSelection","handleScopeChange","handleStatusFilterChange","SearchBar","onSearch","placeholder","isFullWidth","handleInputChange","VerticalTabs","TabsPrimitive","VerticalTabsList","VerticalTabsTrigger","VerticalTabsContent","TabNavigationContentSearch","tabList","searchPlaceholder","headerTitle","isSearchBarFullWidth","direction","tab","Separator","orientation","decorative","SeparatorPrimitive","Skeleton","TooltipProvider","TooltipPrimitive","Tooltip","TooltipTrigger","TooltipContent","SIDEBAR_WIDTH","SIDEBAR_WIDTH_ICON","SidebarContext","useSidebar","SidebarProvider","defaultOpen","openProp","setOpenProp","style","_open","_setOpen","isOpen","openState","toggleSidebar","state","contextValue","Sidebar","side","collapsible","SidebarTrigger","onClick","PanelLeft","SidebarRail","SidebarInset","SidebarInput","SidebarHeader","SidebarFooter","SidebarSeparator","SidebarContent","SidebarGroup","SidebarGroupLabel","SidebarGroupAction","SidebarGroupContent","SidebarMenu","SidebarMenuItem","sidebarMenuButtonVariants","SidebarMenuButton","isActive","tooltip","button","SidebarMenuAction","showOnHover","SidebarMenuBadge","SidebarMenuSkeleton","showIcon","width","SidebarMenuSub","SidebarMenuSubItem","SidebarMenuSubButton","SettingsSidebar","extensionLabels","projectInfo","handleSelectSidebarItem","selectedSidebarItem","extensionsSidebarGroupLabel","projectsSidebarGroupLabel","buttonPlaceholderText","handleSelectItem","projectId","getProjectNameFromProjectId","project","info","getIsActive","label","selectedProjectName","SettingsSidebarContentSearch","scrBookColId","scrRefColId","typeColId","detailsColId","defaultScrRefColumnName","defaultScrBookGroupName","defaultTypeColumnName","defaultDetailsColumnName","getColumns","colInfo","showSourceColumn","showSrcCol","formatScrRef","compareScrRefs","toRefOrRange","scriptureSelection","offsetStart","offsetEnd","scrRefToBBBCCCVVV","getRowKey","ScriptureResultsViewer","sources","showColumnHeaders","scriptureReferenceColumnName","scriptureBookGroupName","typeColumnName","detailsColumnName","onRowSelected","grouping","setGrouping","scriptureResults","source","getExpandedRowModel","getGroupedRowModel","selectedRows","keys","selectedRow","scrBookGroupName","typeGroupName","groupingOptions","handleSelectChange","selectedGrouping","handleRowClick","getEvenOrOddBandingStyle","getIndent","groupingState","rowIndex","ChevronLeft","DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS","getLocalizeKeyForScrollGroupId","ScrollGroupSelector","availableScrollGroupIds","scrollGroupId","onChangeScrollGroupId","localizedStringsDefaulted","localizedStringKey","localizedStringValue","newScrollGroupString","scrollGroupOptionId","SettingsList","SettingsListItem","primary","secondary","isLoading","loadingMessage","SettingsListHeader","includeSeparator","Checklist","listItems","selectedListItems","handleSelectListItem","createLabel","_interopRequireDefault","obj","module","chainPropTypes","propType1","propType2","args","_extends","target","isPlainObject","prototype","deepClone","output","deepmerge","r","z","reactIs_production_min","hasSymbol","REACT_ELEMENT_TYPE","REACT_PORTAL_TYPE","REACT_FRAGMENT_TYPE","REACT_STRICT_MODE_TYPE","REACT_PROFILER_TYPE","REACT_PROVIDER_TYPE","REACT_CONTEXT_TYPE","REACT_ASYNC_MODE_TYPE","REACT_CONCURRENT_MODE_TYPE","REACT_FORWARD_REF_TYPE","REACT_SUSPENSE_TYPE","REACT_SUSPENSE_LIST_TYPE","REACT_MEMO_TYPE","REACT_LAZY_TYPE","REACT_BLOCK_TYPE","REACT_FUNDAMENTAL_TYPE","REACT_RESPONDER_TYPE","REACT_SCOPE_TYPE","isValidElementType","typeOf","object","$$typeof","$$typeofType","AsyncMode","ConcurrentMode","ContextConsumer","ContextProvider","Element","ForwardRef","Lazy","Memo","Portal","Profiler","StrictMode","Suspense","hasWarnedAboutDeprecatedIsAsyncMode","isAsyncMode","isConcurrentMode","isContextConsumer","isContextProvider","isElement","isForwardRef","isFragment","isLazy","isMemo","isPortal","isProfiler","isStrictMode","isSuspense","reactIs_development","reactIsModule","require$$0","require$$1","getOwnPropertySymbols","hasOwnProperty","propIsEnumerable","toObject","val","shouldUseNative","test1","test2","order2","test3","letter","objectAssign","from","to","symbols","ReactPropTypesSecret","ReactPropTypesSecret_1","has","printWarning","loggedTypeFailures","message","checkPropTypes","typeSpecs","values","location","componentName","getStack","typeSpecName","error","err","ex","stack","checkPropTypes_1","ReactIs","assign","require$$2","require$$3","require$$4","emptyFunctionThatReturnsNull","factoryWithTypeCheckers","isValidElement","throwOnDirectAccess","ITERATOR_SYMBOL","FAUX_ITERATOR_SYMBOL","getIteratorFn","maybeIterable","iteratorFn","ANONYMOUS","ReactPropTypes","createPrimitiveTypeChecker","createAnyTypeChecker","createArrayOfTypeChecker","createElementTypeChecker","createElementTypeTypeChecker","createInstanceTypeChecker","createNodeChecker","createObjectOfTypeChecker","createEnumTypeChecker","createUnionTypeChecker","createShapeTypeChecker","createStrictShapeTypeChecker","is","PropTypeError","createChainableTypeChecker","validate","manualPropTypeCallCache","manualPropTypeWarningCount","checkType","isRequired","propName","propFullName","secret","cacheKey","chainedCheckType","expectedType","propValue","propType","getPropType","preciseType","getPreciseType","typeChecker","expectedClass","expectedClassName","actualClassName","getClassName","expectedValues","valuesString","arrayOfTypeCheckers","checker","getPostfixForTypeWarning","expectedTypes","checkerResult","expectedTypesMessage","isNode","invalidValidatorError","shapeTypes","allKeys","iterator","step","entry","isSymbol","emptyFunction","emptyFunctionWithReset","factoryWithThrowingShims","shim","getShim","propTypesModule","isClassComponent","elementType","acceptingRef","safePropName","warningHint","elementAcceptingRef","PropTypes","elementAcceptingRef$1","specialProperty","exactProp","propTypes","unsupportedProps","prop","formatMuiErrorMessage","code","url","REACT_SERVER_CONTEXT_TYPE","REACT_OFFSCREEN_TYPE","enableScopeAPI","enableCacheElement","enableTransitionTracing","enableLegacyHidden","enableDebugTracing","REACT_MODULE_REFERENCE","SuspenseList","hasWarnedAboutDeprecatedIsConcurrentMode","isSuspenseList","fnNameMatchRegex","getFunctionName","fn","getFunctionComponentName","Component","fallback","getWrappedName","outerType","innerType","wrapperName","functionName","getDisplayName","HTMLElementType","refType","refType$1","capitalize","string","_formatMuiErrorMessage","createChainedFunction","funcs","acc","func","debounce","wait","timeout","debounced","later","deprecatedPropType","validator","reason","componentNameSafe","propFullNameSafe","isMuiElement","muiNames","_muiName","_element$type","ownerDocument","node","ownerWindow","requirePropFactory","componentNameInError","prevPropTypes","requiredProp","defaultTypeChecker","typeCheckerResult","setRef","useEnhancedEffect","useEnhancedEffect$1","globalId","useGlobalId","idOverride","defaultId","setDefaultId","maybeReactUseId","useId","reactId","unsupportedProp","useControlled","controlled","defaultProp","name","isControlled","valueState","setValue","defaultValue","setValueIfUncontrolled","newValue","useEventCallback","useForkRef","refs","instance","UNINITIALIZED","useLazyRef","init","initArg","EMPTY","useOnMount","Timeout","delay","useTimeout","hadKeyboardEvent","hadFocusVisibleRecently","hadFocusVisibleRecentlyTimeout","inputTypesWhitelist","focusTriggersKeyboardModality","tagName","handlePointerDown","handleVisibilityChange","prepare","doc","isFocusVisible","useIsFocusVisible","isFocusVisibleRef","handleBlurVisible","handleFocusVisible","resolveProps","defaultProps","defaultSlotProps","slotProps","slotPropName","composeClasses","slots","getUtilityClass","classes","slot","utilityClass","defaultGenerator","createClassNameGenerator","generate","generator","ClassNameGenerator","ClassNameGenerator$1","globalStateClasses","generateUtilityClass","globalStatePrefix","globalStateClass","generateUtilityClasses","result","clamp","min","max","_objectWithoutPropertiesLoose","excluded","sourceKeys","_excluded","sortBreakpointsValues","breakpointsAsArray","breakpoint1","breakpoint2","createBreakpoints","breakpoints","unit","other","sortedValues","up","down","between","start","end","endIndex","only","not","keyIndex","shape","shape$1","responsivePropType","responsivePropType$1","merge","defaultBreakpoints","handleBreakpoints","styleFromPropValue","theme","themeBreakpoints","breakpoint","mediaKey","cssKey","createEmptyBreakpointObject","breakpointsInput","_breakpointsInput$key","breakpointStyleKey","removeUnusedBreakpoints","breakpointKeys","breakpointOutput","getPath","path","checkVars","getStyleValue","themeMapping","transform","propValueFinal","userValue","cssProperty","themeKey","memoize","cache","arg","properties","directions","aliases","getCssProperties","property","marginKeys","paddingKeys","spacingKeys","createUnaryUnit","_getPath","themeSpacing","abs","createUnarySpacing","getValue","transformer","transformed","getStyleFromPropValue","cssProperties","resolveCssProperty","margin","padding","createSpacing","spacingInput","spacing","argsInput","argument","compose","styles","handlers","borderTransform","createBorderStyle","border","borderTop","borderRight","borderBottom","borderLeft","borderColor","borderTopColor","borderRightColor","borderBottomColor","borderLeftColor","outline","outlineColor","borderRadius","gap","columnGap","rowGap","gridColumn","gridRow","gridAutoFlow","gridAutoColumns","gridAutoRows","gridTemplateColumns","gridTemplateRows","gridTemplateAreas","gridArea","paletteTransform","color","bgcolor","backgroundColor","sizingTransform","maxWidth","_props$theme","_props$theme2","breakpointsValues","minWidth","height","maxHeight","minHeight","boxSizing","defaultSxConfig","defaultSxConfig$1","objectsHaveSameKeys","objects","union","callIfFn","maybeFn","unstable_createStyleFunctionSx","getThemeValue","config","styleFunctionSx","_theme$unstable_sxCon","sx","traverse","sxInput","sxObject","emptyBreakpoints","breakpointsKeys","css","styleKey","styleFunctionSx$1","applyStyles","createTheme","paletteInput","shapeInput","muiTheme","isObjectEmpty","useTheme","defaultTheme","contextTheme","ThemeContext","systemDefaultTheme","useThemeWithoutDefault","_excluded2","_excluded3","isEmpty","isStringTag","tag","shouldForwardProp","lowercaseFirstLetter","resolveTheme","themeId","defaultOverridesResolver","processStyleArg","callableStyle","_ref","ownerState","resolvedStylesArg","resolvedStyle","variants","isMatch","createStyled","input","rootShouldForwardProp","slotShouldForwardProp","systemSx","inputOptions","processStyles","componentSlot","inputSkipVariantsResolver","inputSkipSx","overridesResolver","skipVariantsResolver","skipSx","shouldForwardPropOption","defaultStyledResolver","styledEngineStyled","transformStyleArg","stylesArg","muiStyledResolver","styleArg","expressions","transformedStyleArg","expressionsWithDefaultTheme","styleOverrides","resolvedStyleOverrides","slotKey","slotStyle","_theme$components","themeVariants","numOfCustomFnsApplied","placeholders","displayName","getThemeProps","params","useThemeProps","clampWrapper","hexToRgb","re","colors","decomposeColor","marker","colorSpace","recomposeColor","hslToRgb","rgb","getLuminance","getContrastRatio","foreground","background","lumA","lumB","alpha","darken","coefficient","lighten","createMixins","mixins","common","common$1","grey","grey$1","purple","purple$1","red","red$1","orange","orange$1","blue","blue$1","lightBlue","lightBlue$1","green","green$1","light","dark","addLightOrDark","intent","shade","tonalOffset","tonalOffsetLight","tonalOffsetDark","getDefaultPrimary","mode","getDefaultSecondary","getDefaultError","getDefaultInfo","getDefaultSuccess","getDefaultWarning","createPalette","palette","contrastThreshold","success","warning","getContrastText","contrastText","contrast","augmentColor","mainShade","lightShade","darkShade","modes","round","caseAllCaps","defaultFontFamily","createTypography","typography","fontFamily","fontSize","fontWeightLight","fontWeightRegular","fontWeightMedium","fontWeightBold","htmlFontSize","allVariants","pxToRem2","coef","pxToRem","buildVariant","fontWeight","lineHeight","letterSpacing","casing","shadowKeyUmbraOpacity","shadowKeyPenumbraOpacity","shadowAmbientShadowOpacity","createShadow","px","shadows","shadows$1","easing","duration","formatMs","milliseconds","getAutoHeightDuration","constant","createTransitions","inputTransitions","mergedEasing","mergedDuration","durationOption","easingOption","isString","isNumber","animatedProp","zIndex","zIndex$1","mixinsInput","transitionsInput","typographyInput","systemTheme","systemCreateTheme","stateClasses","component","child","stateClass","defaultTheme$1","THEME_ID","systemUseThemeProps","styled","styled$1","getSvgIconUtilityClass","useUtilityClasses","SvgIconRoot","_theme$transitions","_theme$transitions$cr","_theme$transitions2","_theme$typography","_theme$typography$pxT","_theme$typography2","_theme$typography2$px","_theme$typography3","_theme$typography3$px","_palette$ownerState$c","_palette","_palette2","_palette3","SvgIcon","inProps","htmlColor","inheritViewBox","titleAccess","viewBox","hasSvgAsChild","more","_jsxs","_jsx","SvgIcon$1","createSvgIcon","unstable_ClassNameGenerator","exports","_utils","ArrowRight","default_1","_createSvgIcon","_jsxRuntime","isHostComponent","appendOwnerState","otherProps","defaultContextValue","ClassNameConfiguratorContext","useClassNamesOverride","disableDefaultClasses","extractEventHandlers","excludeKeys","resolveComponentProps","componentProps","slotState","omitEventHandlers","mergeSlotProps","parameters","getSlotProps","additionalProps","externalSlotProps","externalForwardedProps","joinedClasses","mergedStyle","eventHandlers","componentsPropsWithoutEventHandlers","otherPropsWithoutEventHandlers","internalSlotProps","useSlotProps","_parameters$additiona","skipResolvingSlotProps","rest","resolvedComponentsProps","mergedProps","internalRef","GLOBAL_CLASS_PREFIX","buildStateClass","buildSlotClass","getContainer","container","forwardedRef","disablePortal","mountNode","setMountNode","handleRef","newProps","ReactDOM","top","bottom","right","left","auto","basePlacements","clippingParents","viewport","popper","reference","variationPlacements","placement","placements","beforeRead","read","afterRead","beforeMain","main","afterMain","beforeWrite","write","afterWrite","modifierPhases","getNodeName","getWindow","OwnElement","isHTMLElement","isShadowRoot","attributes","effect","_ref2","initialStyles","styleProperties","attribute","applyStyles$1","getBasePlacement","getUAString","uaData","isLayoutViewport","getBoundingClientRect","includeScale","isFixedStrategy","clientRect","scaleX","scaleY","visualViewport","addVisualOffsets","getLayoutRect","contains","parent","rootNode","next","getComputedStyle","isTableElement","getDocumentElement","getParentNode","getTrueOffsetParent","getContainingBlock","isFirefox","isIE","elementCss","currentNode","getOffsetParent","window","offsetParent","getMainAxisFromPlacement","within","mathMax","mathMin","withinMaxClamp","getFreshSideObject","mergePaddingObject","paddingObject","expandToHashMap","hashMap","toPaddingObject","arrow","_state$modifiersData$","arrowElement","popperOffsets","basePlacement","axis","isVertical","len","arrowRect","minProp","maxProp","endDiff","startDiff","arrowOffsetParent","clientSize","centerToReference","center","offset","axisProp","_options$element","arrow$1","getVariation","unsetSides","roundOffsetsByDPR","win","dpr","mapToStyles","_Object$assign2","popperRect","variation","offsets","gpuAcceleration","adaptive","roundOffsets","isFixed","_offsets$x","_offsets$y","_ref3","hasX","hasY","sideX","sideY","heightProp","widthProp","offsetY","offsetX","commonStyles","_ref4","_Object$assign","computeStyles","_ref5","_options$gpuAccelerat","_options$adaptive","_options$roundOffsets","computeStyles$1","passive","_options$scroll","scroll","_options$resize","resize","scrollParents","scrollParent","eventListeners","hash","getOppositePlacement","matched","getOppositeVariationPlacement","getWindowScroll","scrollLeft","scrollTop","getWindowScrollBarX","getViewportRect","strategy","html","layoutViewport","getDocumentRect","_element$ownerDocumen","winScroll","body","isScrollParent","_getComputedStyle","overflow","overflowX","overflowY","getScrollParent","listScrollParents","list","isBody","updatedList","rectToClientRect","rect","getInnerBoundingClientRect","getClientRectFromMixedType","clippingParent","getClippingParents","canEscapeClipping","clipperElement","getClippingRect","boundary","rootBoundary","mainClippingParents","firstClippingParent","clippingRect","accRect","computeOffsets","commonX","commonY","mainAxis","detectOverflow","_options","_options$placement","_options$strategy","_options$boundary","_options$rootBoundary","_options$elementConte","elementContext","_options$altBoundary","altBoundary","_options$padding","altContext","clippingClientRect","referenceClientRect","popperClientRect","elementClientRect","overflowOffsets","offsetData","multiply","computeAutoPlacement","flipVariations","_options$allowedAutoP","allowedAutoPlacements","allPlacements","allowedPlacements","overflows","getExpandedFallbackPlacements","oppositePlacement","flip","_options$mainAxis","checkMainAxis","_options$altAxis","checkAltAxis","specifiedFallbackPlacements","_options$flipVariatio","preferredPlacement","isBasePlacement","fallbackPlacements","referenceRect","checksMap","makeFallbackChecks","firstFittingPlacement","_basePlacement","isStartVariation","mainVariationSide","altVariationSide","checks","check","numberOfChecks","_loop","_i","fittingPlacement","_ret","flip$1","getSideOffsets","preventedOffsets","isAnySideFullyClipped","hide","referenceOverflow","popperAltOverflow","referenceClippingOffsets","popperEscapeOffsets","isReferenceHidden","hasPopperEscaped","hide$1","distanceAndSkiddingToXY","rects","invertDistance","skidding","distance","_options$offset","_data$state$placement","offset$1","popperOffsets$1","getAltAxis","preventOverflow","_options$tether","tether","_options$tetherOffset","tetherOffset","altAxis","tetherOffsetValue","normalizedTetherOffsetValue","offsetModifierState","_offsetModifierState$","mainSide","altSide","additive","minLen","maxLen","arrowPaddingObject","arrowPaddingMin","arrowPaddingMax","arrowLen","minOffset","maxOffset","clientOffset","offsetModifierValue","tetherMin","tetherMax","preventedOffset","_offsetModifierState$2","_mainSide","_altSide","_offset","_len","_min","_max","isOriginSide","_offsetModifierValue","_tetherMin","_tetherMax","_preventedOffset","preventOverflow$1","getHTMLElementScroll","getNodeScroll","isElementScaled","getCompositeRect","elementOrVirtualElement","isOffsetParentAnElement","offsetParentIsScaled","documentElement","order","modifiers","map","visited","modifier","sort","requires","dep","depModifier","orderModifiers","orderedModifiers","phase","pending","resolve","mergeByName","merged","current","existing","DEFAULT_OPTIONS","areValidElements","_key","popperGenerator","generatorOptions","_generatorOptions","_generatorOptions$def","defaultModifiers","_generatorOptions$def2","defaultOptions","effectCleanupFns","isDestroyed","setOptionsAction","cleanupModifierEffects","runModifierEffects","_state$elements","_state$orderedModifie","_state$orderedModifie2","_ref$options","cleanupFn","noopFn","createPopper","COMPONENT_NAME","getPopperUtilityClass","flipPlacement","resolveAnchorEl","anchorEl","isVirtualElement","defaultPopperOptions","PopperTooltip","_slots$root","initialPlacement","popperOptions","popperRefProp","TransitionProps","tooltipRef","ownRef","popperRef","handlePopperRef","handlePopperRefRef","rtlPlacement","setPlacement","resolvedAnchorElement","setResolvedAnchorElement","handlePopperUpdate","box","popperModifiers","childProps","Root","rootProps","Popper","containerProp","keepMounted","transition","exited","setExited","handleEnter","handleExited","resolvedAnchorEl","display","transitionProps","useThemeSystem","_setPrototypeOf","_inheritsLoose","subClass","superClass","setPrototypeOf","timeoutsShape","TransitionGroupContext","forceReflow","UNMOUNTED","EXITED","ENTERING","ENTERED","EXITING","Transition","_React$Component","_this","parentGroup","appear","initialStatus","prevState","nextIn","_proto","prevProps","nextStatus","exit","enter","mounting","_this2","appearing","maybeNode","maybeAppearing","timeouts","enterTimeout","_this3","nextState","callback","_this4","active","handler","doesNotHaveTimeoutOrListener","maybeNextCallback","_this$props","pt","noop","Transition$1","reflow","getTransitionProps","_style$transitionDura","_style$transitionTimi","getScale","isWebKit154","Grow","addEndListener","inProp","onEnter","onEntered","onEntering","onExit","onExited","onExiting","TransitionComponent","timer","autoTimeout","nodeRef","normalizedTransitionCallback","maybeIsAppearing","handleEntering","isAppearing","transitionDuration","transitionTimingFunction","handleEntered","handleExiting","handleExit","handleAddEndListener","Grow$1","PopperRoot","BasePopper","components","componentsProps","RootComponent","Popper$1","getTooltipUtilityClass","tooltipClasses","tooltipClasses$1","disableInteractive","touch","TooltipPopper","TooltipTooltip","TooltipArrow","hystersisOpen","hystersisTimer","cursorPosition","composeEventHandler","eventHandler","_slots$popper","_slots$transition","_slots$tooltip","_slots$arrow","_slotProps$popper","_ref6","_slotProps$popper2","_slotProps$transition","_slotProps$tooltip","_ref7","_slotProps$tooltip2","_slotProps$arrow","_ref8","_slotProps$arrow2","childrenProp","describeChild","disableFocusListener","disableHoverListener","disableInteractiveProp","disableTouchListener","enterDelay","enterNextDelay","enterTouchDelay","followCursor","idProp","leaveDelay","leaveTouchDelay","onClose","onOpen","PopperComponentProp","PopperProps","title","TransitionComponentProp","isRtl","childNode","setChildNode","arrowRef","setArrowRef","ignoreNonTouchEvents","closeTimer","enterTimer","leaveTimer","touchTimer","setOpenState","prevUserSelect","stopTouchInteraction","handleOpen","handleClose","handleLeave","focusVisibleRef","setChildIsFocusVisible","handleBlur","handleFocus","detectTouchStart","childrenProps","handleMouseOver","handleMouseLeave","handleTouchStart","handleTouchEnd","nativeEvent","handleMouseMove","nameOrDescProps","titleIsString","interactiveWrapperListeners","_PopperProps$popperOp","tooltipModifiers","PopperComponent","TooltipComponent","ArrowComponent","popperProps","tooltipProps","tooltipArrowProps","TransitionPropsInner","Tooltip$1","getIcon","icon","menuLabel","leading","MuiListItemIcon","MenuItem","allowForLeadingIcons","iconPathBefore","iconPathAfter","hasAutoFocus","isDense","isSubMenuParent","hasDisabledGutters","hasDivider","focusVisibleClassName","menuItem","MuiMenuItem","MuiListItemText","getAllGroups","menuDefinition","SubMenu","setAnchorEl","parentMenuItem","parentItemProps","handleParentMenuItemClick","renderSubMenuItems","includedGroups","group","GroupedMenuItemList","Menu","getOrderedGroupItems","groupId","allItems","menuProps","commandHandler","groupsToInclude","sortedGroups","itemArray","allowSpaceForLeadingIcons","createMenuItemProps","isLastItemInGroup","divKey","itemInfo","menuItemProps","TopLevelMenu","columnId","MenuColumn","metadata","Grid","List","GridMenu","multiColumnMenu","sortedColumns","columnNumbers","columnName","col","getUsePromiseOptionsDefaults","usePromise","promiseFactoryCallback","defaultValueRef","optionsDefaultedRef","setIsLoading","promiseIsCurrent","MenuIcon","HamburgerMenuButton","menuProvider","normalMenu","fullMenu","containerRef","ariaLabelPrefix","isMenuOpen","setMenuOpen","showFullMenu","setShowFullMenu","handleMenuItemClick","handleMenuButtonClick","prevIsOpen","isOpening","menuCommandHandler","command","setOffset","normalMenuData","fullMenuData","menu","IconButton","Drawer","isTooltipSuppressed","adjustMarginToAlignToEdge","MuiIconButton","Spinner","LoaderCircle","TextField","hasError","helperText","onFocus","onBlur","ShadLabel","Toolbar","AppBar","MuiToolbar","alertVariants","Alert","AlertTitle","AlertDescription","Card","CardHeader","CardTitle","CardDescription","CardContent","CardFooter","Sonner","Toaster","Slider","SliderPrimitive","Switch","SwitchPrimitives","Tabs","TabsList","TabsTrigger","TabsContent","InstallButton","isInstalling","handleClick","buttonText","Download","EnableButton","isEnabling","DisableButton","isDisabling","UpdateButton","isUpdating","MarkdownRenderer","markdown","anchorTarget","Markdown","FilterButton","Filter","DropdownMenuItemType","DropdownMenuItemType2","FilterDropdown","groups","NoExtensionsFound","MoreInfo","category","downloads","languages","moreInfoUrl","numberFormatted","NumberFormat","handleScrollToBottom","User","locale","LucideLink","CircleHelp","VersionHistory","versionHistory","showAllVersions","setShowAllVersions","currentDate","formatTimeString","dateString","date","dateDiff","yearDiff","monthDiff","dayDiff","timeString","sortedEntries","Footer","publisherDisplayName","fileSize","locales","formattedFileSize","formatBytes","languageNames","codes","displayNames","useEvent","unsubscriber","noopUnsubscriber","useEventAsync","unsubscribe","unsub"],"mappings":"48CAGA,MAAMA,GAAgBC,GAAAA,oBAAoB,CAAE,OAAQ,KAAO,CAAA,EAyDpD,SAASC,KAAMC,EAAsB,CACnC,OAAAH,GAAcI,GAAAA,KAAKD,CAAM,CAAC,CACnC,CCzDO,MAAME,GAAQC,EAAM,WACzB,CAAC,CAAE,UAAAC,EAAW,KAAAC,EAAM,GAAGC,CAAA,EAASC,IAE5BC,EAAA,IAAC,QAAA,CACC,KAAAH,EACA,UAAWN,EACT,sbACAK,CACF,EACA,IAAAG,EAEC,GAAGD,CAAA,CAAA,CAIZ,EACAJ,GAAM,YAAc,QCNpB,MAAMO,GAAmBC,EAAA,WACvB,CACE,CAAE,aAAAC,EAAc,cAAAC,EAAe,cAAAC,EAAe,aAAAC,EAAc,GAAGR,CAAM,EACrEC,IAGEQ,EAAA,KAAC,MAAI,CAAA,UAAU,cACb,SAAA,CAAAP,EAAA,IAACQ,GAAA,CACE,GAAGV,EACJ,KAAK,OACL,UAAU,0JACV,SAAWW,GAAUN,EAAaM,EAAM,OAAO,KAAK,EACpD,UAAYC,GAAM,CACZA,EAAE,MAAQ,SACCJ,IAEfF,EAAcM,CAAC,CACjB,EACA,QAASL,EACT,IAAAN,CAAA,CACF,EACAC,EAAA,IAACW,GAAA,QAAA,CACC,UAAU,8HACV,QAAS,IAAM,CAEb,QAAQ,IAAI,iBAAiB,CAC/B,CAAA,CACF,CACF,CAAA,CAAA,CAGN,EC9CA,IAAIC,GAAI,OAAO,eACXC,GAAI,CAACC,EAAGJ,EAAGK,IAAML,KAAKI,EAAIF,GAAEE,EAAGJ,EAAG,CAAE,WAAY,GAAI,aAAc,GAAI,SAAU,GAAI,MAAOK,CAAC,CAAE,EAAID,EAAEJ,CAAC,EAAIK,EACzGC,GAAI,CAACF,EAAGJ,EAAGK,IAAMF,GAAEC,EAAG,OAAOJ,GAAK,SAAWA,EAAI,GAAKA,EAAGK,CAAC,EAW9D,MAAME,GAAI,CACR,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MAEA,MAEA,MAEA,MAEA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,MAEA,MAEA,MAEA,MAEA,MACA,MACA,MACA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,KACF,EAAGC,GAAI,CACL,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,KACF,EAAGC,GAAI,CACL,UACA,SACA,YACA,UACA,cACA,SACA,SACA,OACA,WACA,WACA,UACA,UACA,eACA,eACA,OACA,WACA,kBACA,MACA,SACA,WACA,eACA,gBACA,SACA,WACA,eACA,UACA,kBACA,QACA,OACA,OACA,UACA,QACA,QACA,QACA,WACA,YACA,SACA,YACA,UACA,UACA,OACA,OACA,OACA,OACA,SACA,gBACA,gBACA,YACA,YACA,cACA,aACA,kBACA,kBACA,YACA,YACA,QACA,WACA,UACA,QACA,UACA,UACA,SACA,SACA,SACA,OACA,aACA,QACA,SACA,eACA,oBACA,0BACA,SACA,qBACA,sBACA,UACA,qBACA,cACA,cACA,cACA,cACA,mBACA,mBACA,qBACA,YACA,OACA,oBAGA,uBACA,uBACA,sBACA,yBACA,wBACA,qBACA,UACA,UACA,UACA,UACA,UACA,UACA,UACA,eACA,cACA,eACA,oBACA,qBACA,0BACA,0BACA,eACA,eACA,YACA,gBACA,cACA,eACA,iBACA,wBACA,mBACA,WACA,QACA,aACA,aACA,aACA,2BACA,4BACA,YACF,EAAGC,GAAIC,KACP,SAASC,GAAER,EAAGJ,EAAI,GAAI,CACpB,OAAOA,IAAMI,EAAIA,EAAE,YAAa,GAAGA,KAAKM,GAAIA,GAAEN,CAAC,EAAI,CACrD,CACA,SAASS,GAAET,EAAG,CACZ,OAAOQ,GAAER,CAAC,EAAI,CAChB,CACA,SAASU,GAAEV,EAAG,CACZ,MAAMJ,EAAI,OAAOI,GAAK,SAAWQ,GAAER,CAAC,EAAIA,EACxC,OAAOJ,GAAK,IAAMA,GAAK,EACzB,CACA,SAASe,GAAEX,EAAG,CACZ,OAAQ,OAAOA,GAAK,SAAWQ,GAAER,CAAC,EAAIA,IAAM,EAC9C,CACA,SAASY,GAAEZ,EAAG,CACZ,OAAOA,GAAK,EACd,CACA,SAASa,GAAEb,EAAG,CACZ,MAAMJ,EAAI,OAAOI,GAAK,SAAWQ,GAAER,CAAC,EAAIA,EACxC,OAAOc,GAAElB,CAAC,GAAK,CAACgB,GAAEhB,CAAC,CACrB,CACA,SAAUmB,IAAI,CACZ,QAASf,EAAI,EAAGA,GAAKG,GAAE,OAAQH,IAAK,MAAMA,CAC5C,CACA,MAAMgB,GAAI,EAAGC,GAAId,GAAE,OACnB,SAASe,IAAI,CACX,MAAO,CAAC,MAAO,MAAO,MAAO,MA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V,SAAU,UACV,UAAWA,EACZ,EACD,YAAa,CACX,SAAU,SACX,EACD,eAAgB,CACd,SAAU,SACX,EACD,iBAAkB,CAChB,SAAU,SACX,EACD,kBAAmB,CACjB,SAAU,SACX,EACD,gBAAiB,CACf,SAAU,SACX,EACD,QAAS,CACP,SAAU,UACV,UAAWA,EACZ,EACD,aAAc,CACZ,SAAU,SACX,EACD,aAAc,CACZ,SAAU,qBACV,MAAOc,EACR,EAED,MAAO,CACL,SAAU,UACV,UAAWa,EACZ,EACD,QAAS,CACP,SAAU,UACV,YAAa,kBACb,UAAWA,EACZ,EACD,gBAAiB,CACf,SAAU,UACV,UAAWA,EACZ,EAED,EAAG,CACD,MAAOpC,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,QAAS,CACP,MAAOA,EACR,EACD,WAAY,CACV,MAAOA,EACR,EACD,aAAc,CACZ,MAAOA,EACR,EACD,cAAe,CACb,MAAOA,EACR,EACD,YAAa,CACX,MAAOA,EACR,EACD,SAAU,CACR,MAAOA,EACR,EACD,SAAU,CACR,MAAOA,EACR,EACD,cAAe,CACb,MAAOA,EACR,EACD,mBAAoB,CAClB,MAAOA,EACR,EACD,iBAAkB,CAChB,MAAOA,EACR,EACD,aAAc,CACZ,MAAOA,EACR,EACD,kBAAmB,CACjB,MAAOA,EACR,EACD,gBAAiB,CACf,MAAOA,EACR,EACD,EAAG,CACD,MAAOD,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,OAAQ,CACN,MAAOA,EACR,EACD,UAAW,CACT,MAAOA,EACR,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;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","x_google_ignoreList":[3,43,44,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,83,84,85,86,87,88,89,90,91,92,93,94,95,96,97,98,99,100,101,102,103,104,105,106,107,108,109,110,111,112,113,114,115,116,117,118,119,120,121,122,123,124,125,126,127,128,129,130,131,132,133,134,135,136,137,138,139,140,141,142,143,144,145,146,147,148,149,150,151,152,153,154,155,156,157,158,159,160,161,162,163,164,165,166,167,168,169,170,171,172,173,174,175,176,177,178,179,180,181,182,183,184,185,186,187,188,189,190,191,192,193,194,195,196,197,198,199,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,226]} \ No newline at end of file +{"version":3,"file":"index.cjs","sources":["../src/utils/shadcn-ui.util.ts","../src/components/shadcn-ui/input.tsx","../src/components/advanced/book-chapter-control/book-chapter-input.component.tsx","../../../node_modules/@sillsdev/scripture/dist/index.es.js","../src/components/shadcn-ui/dropdown-menu.tsx","../src/components/advanced/book-chapter-control/book-menu-item.component.tsx","../src/components/advanced/book-chapter-control/chapter-select.component.tsx","../src/components/advanced/book-chapter-control/go-to-menu-item.component.tsx","../src/components/advanced/book-chapter-control/book-chapter-control.component.tsx","../src/components/shadcn-ui/button.tsx","../src/components/shadcn-ui/label.tsx","../src/components/shadcn-ui/radio-group.tsx","../src/components/shadcn-ui/popover.tsx","../src/components/shadcn-ui/dialog.tsx","../src/components/shadcn-ui/command.tsx","../src/components/basics/combo-box.component.tsx","../src/components/basics/chapter-range-selector.component.tsx","../src/components/advanced/book-selector.component.tsx","../src/components/advanced/data-table/data-table-column-toggle.component.tsx","../src/components/shadcn-ui/select.tsx","../src/components/advanced/data-table/data-table-pagination.component.tsx","../src/components/shadcn-ui/table.tsx","../src/components/advanced/data-table/data-table.component.tsx","../src/components/advanced/inventory/occurrences-table.component.tsx","../src/components/shadcn-ui/checkbox.tsx","../src/components/advanced/inventory/inventory-utils.ts","../src/components/shadcn-ui/toggle.tsx","../src/components/shadcn-ui/toggle-group.tsx","../src/components/advanced/inventory/inventory-columns.tsx","../src/components/advanced/inventory/inventory.component.tsx","../src/components/basics/search-bar.component.tsx","../src/components/basics/tabs-vertical.tsx","../src/components/advanced/tab-navigation-content-search.component.tsx","../src/components/shadcn-ui/separator.tsx","../src/components/shadcn-ui/skeleton.tsx","../src/components/shadcn-ui/tooltip.tsx","../src/components/shadcn-ui/sidebar.tsx","../src/components/advanced/settings-components/settings-sidebar.component.tsx","../src/components/advanced/settings-components/settings-sidebar-content-search.component.tsx","../src/components/advanced/scripture-results-viewer/scripture-results-viewer.component.tsx","../src/components/advanced/scroll-group-selector.component.tsx","../src/components/advanced/settings-components/settings-list.component.tsx","../src/components/basics/checklist.component.tsx","../../../node_modules/@babel/runtime/helpers/interopRequireDefault.js","../../../node_modules/@mui/utils/chainPropTypes/chainPropTypes.js","../../../node_modules/@babel/runtime/helpers/esm/extends.js","../../../node_modules/@mui/utils/deepmerge/deepmerge.js","../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.production.min.js","../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.development.js","../../../node_modules/prop-types/node_modules/react-is/index.js","../../../node_modules/object-assign/index.js","../../../node_modules/prop-types/lib/ReactPropTypesSecret.js","../../../node_modules/prop-types/lib/has.js","../../../node_modules/prop-types/checkPropTypes.js","../../../node_modules/prop-types/factoryWithTypeCheckers.js","../../../node_modules/prop-types/factoryWithThrowingShims.js","../../../node_modules/prop-types/index.js","../../../node_modules/@mui/utils/elementAcceptingRef/elementAcceptingRef.js","../../../node_modules/@mui/utils/exactProp/exactProp.js","../../../node_modules/@mui/utils/formatMuiErrorMessage/formatMuiErrorMessage.js","../../../node_modules/react-is/cjs/react-is.production.min.js","../../../node_modules/react-is/cjs/react-is.development.js","../../../node_modules/react-is/index.js","../../../node_modules/@mui/utils/getDisplayName/getDisplayName.js","../../../node_modules/@mui/utils/HTMLElementType/HTMLElementType.js","../../../node_modules/@mui/utils/refType/refType.js","../../../node_modules/@mui/utils/capitalize/capitalize.js","../../../node_modules/@mui/utils/createChainedFunction/createChainedFunction.js","../../../node_modules/@mui/utils/debounce/debounce.js","../../../node_modules/@mui/utils/deprecatedPropType/deprecatedPropType.js","../../../node_modules/@mui/utils/isMuiElement/isMuiElement.js","../../../node_modules/@mui/utils/ownerDocument/ownerDocument.js","../../../node_modules/@mui/utils/ownerWindow/ownerWindow.js","../../../node_modules/@mui/utils/requirePropFactory/requirePropFactory.js","../../../node_modules/@mui/utils/setRef/setRef.js","../../../node_modules/@mui/utils/useEnhancedEffect/useEnhancedEffect.js","../../../node_modules/@mui/utils/useId/useId.js","../../../node_modules/@mui/utils/unsupportedProp/unsupportedProp.js","../../../node_modules/@mui/utils/useControlled/useControlled.js","../../../node_modules/@mui/utils/useEventCallback/useEventCallback.js","../../../node_modules/@mui/utils/useForkRef/useForkRef.js","../../../node_modules/@mui/utils/useLazyRef/useLazyRef.js","../../../node_modules/@mui/utils/useOnMount/useOnMount.js","../../../node_modules/@mui/utils/useTimeout/useTimeout.js","../../../node_modules/@mui/utils/useIsFocusVisible/useIsFocusVisible.js","../../../node_modules/@mui/utils/resolveProps/resolveProps.js","../../../node_modules/@mui/utils/composeClasses/composeClasses.js","../../../node_modules/@mui/utils/ClassNameGenerator/ClassNameGenerator.js","../../../node_modules/@mui/utils/generateUtilityClass/generateUtilityClass.js","../../../node_modules/@mui/utils/generateUtilityClasses/generateUtilityClasses.js","../../../node_modules/@mui/utils/clamp/clamp.js","../../../node_modules/@babel/runtime/helpers/esm/objectWithoutPropertiesLoose.js","../../../node_modules/@mui/system/esm/createTheme/createBreakpoints.js","../../../node_modules/@mui/system/esm/createTheme/shape.js","../../../node_modules/@mui/system/esm/responsivePropType.js","../../../node_modules/@mui/system/esm/merge.js","../../../node_modules/@mui/system/esm/breakpoints.js","../../../node_modules/@mui/system/esm/style.js","../../../node_modules/@mui/system/esm/memoize.js","../../../node_modules/@mui/system/esm/spacing.js","../../../node_modules/@mui/system/esm/createTheme/createSpacing.js","../../../node_modules/@mui/system/esm/compose.js","../../../node_modules/@mui/system/esm/borders.js","../../../node_modules/@mui/system/esm/cssGrid.js","../../../node_modules/@mui/system/esm/palette.js","../../../node_modules/@mui/system/esm/sizing.js","../../../node_modules/@mui/system/esm/styleFunctionSx/defaultSxConfig.js","../../../node_modules/@mui/system/esm/styleFunctionSx/styleFunctionSx.js","../../../node_modules/@mui/system/esm/createTheme/applyStyles.js","../../../node_modules/@mui/system/esm/createTheme/createTheme.js","../../../node_modules/@mui/system/esm/useThemeWithoutDefault.js","../../../node_modules/@mui/system/esm/useTheme.js","../../../node_modules/@mui/system/esm/createStyled.js","../../../node_modules/@mui/system/esm/useThemeProps/getThemeProps.js","../../../node_modules/@mui/system/esm/useThemeProps/useThemeProps.js","../../../node_modules/@mui/system/esm/colorManipulator.js","../../../node_modules/@mui/material/styles/createMixins.js","../../../node_modules/@mui/material/colors/common.js","../../../node_modules/@mui/material/colors/grey.js","../../../node_modules/@mui/material/colors/purple.js","../../../node_modules/@mui/material/colors/red.js","../../../node_modules/@mui/material/colors/orange.js","../../../node_modules/@mui/material/colors/blue.js","../../../node_modules/@mui/material/colors/lightBlue.js","../../../node_modules/@mui/material/colors/green.js","../../../node_modules/@mui/material/styles/createPalette.js","../../../node_modules/@mui/material/styles/createTypography.js","../../../node_modules/@mui/material/styles/shadows.js","../../../node_modules/@mui/material/styles/createTransitions.js","../../../node_modules/@mui/material/styles/zIndex.js","../../../node_modules/@mui/material/styles/createTheme.js","../../../node_modules/@mui/material/styles/defaultTheme.js","../../../node_modules/@mui/material/styles/identifier.js","../../../node_modules/@mui/material/styles/useThemeProps.js","../../../node_modules/@mui/material/styles/styled.js","../../../node_modules/@mui/material/SvgIcon/svgIconClasses.js","../../../node_modules/@mui/material/SvgIcon/SvgIcon.js","../../../node_modules/@mui/material/utils/createSvgIcon.js","../../../node_modules/@mui/material/utils/index.js","../../../node_modules/@mui/icons-material/utils/createSvgIcon.js","../../../node_modules/@mui/icons-material/ArrowRight.js","../../../node_modules/@mui/base/utils/isHostComponent.js","../../../node_modules/@mui/base/utils/appendOwnerState.js","../../../node_modules/@mui/base/utils/ClassNameConfigurator.js","../../../node_modules/@mui/base/utils/extractEventHandlers.js","../../../node_modules/@mui/base/utils/resolveComponentProps.js","../../../node_modules/@mui/base/utils/omitEventHandlers.js","../../../node_modules/@mui/base/utils/mergeSlotProps.js","../../../node_modules/@mui/base/utils/useSlotProps.js","../../../node_modules/@mui/base/generateUtilityClass/index.js","../../../node_modules/@mui/base/generateUtilityClasses/index.js","../../../node_modules/@mui/base/Portal/Portal.js","../../../node_modules/@popperjs/core/lib/enums.js","../../../node_modules/@popperjs/core/lib/dom-utils/getNodeName.js","../../../node_modules/@popperjs/core/lib/dom-utils/getWindow.js","../../../node_modules/@popperjs/core/lib/dom-utils/instanceOf.js","../../../node_modules/@popperjs/core/lib/modifiers/applyStyles.js","../../../node_modules/@popperjs/core/lib/utils/getBasePlacement.js","../../../node_modules/@popperjs/core/lib/utils/math.js","../../../node_modules/@popperjs/core/lib/utils/userAgent.js","../../../node_modules/@popperjs/core/lib/dom-utils/isLayoutViewport.js","../../../node_modules/@popperjs/core/lib/dom-utils/getBoundingClientRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/getLayoutRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/contains.js","../../../node_modules/@popperjs/core/lib/dom-utils/getComputedStyle.js","../../../node_modules/@popperjs/core/lib/dom-utils/isTableElement.js","../../../node_modules/@popperjs/core/lib/dom-utils/getDocumentElement.js","../../../node_modules/@popperjs/core/lib/dom-utils/getParentNode.js","../../../node_modules/@popperjs/core/lib/dom-utils/getOffsetParent.js","../../../node_modules/@popperjs/core/lib/utils/getMainAxisFromPlacement.js","../../../node_modules/@popperjs/core/lib/utils/within.js","../../../node_modules/@popperjs/core/lib/utils/getFreshSideObject.js","../../../node_modules/@popperjs/core/lib/utils/mergePaddingObject.js","../../../node_modules/@popperjs/core/lib/utils/expandToHashMap.js","../../../node_modules/@popperjs/core/lib/modifiers/arrow.js","../../../node_modules/@popperjs/core/lib/utils/getVariation.js","../../../node_modules/@popperjs/core/lib/modifiers/computeStyles.js","../../../node_modules/@popperjs/core/lib/modifiers/eventListeners.js","../../../node_modules/@popperjs/core/lib/utils/getOppositePlacement.js","../../../node_modules/@popperjs/core/lib/utils/getOppositeVariationPlacement.js","../../../node_modules/@popperjs/core/lib/dom-utils/getWindowScroll.js","../../../node_modules/@popperjs/core/lib/dom-utils/getWindowScrollBarX.js","../../../node_modules/@popperjs/core/lib/dom-utils/getViewportRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/getDocumentRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/isScrollParent.js","../../../node_modules/@popperjs/core/lib/dom-utils/getScrollParent.js","../../../node_modules/@popperjs/core/lib/dom-utils/listScrollParents.js","../../../node_modules/@popperjs/core/lib/utils/rectToClientRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/getClippingRect.js","../../../node_modules/@popperjs/core/lib/utils/computeOffsets.js","../../../node_modules/@popperjs/core/lib/utils/detectOverflow.js","../../../node_modules/@popperjs/core/lib/utils/computeAutoPlacement.js","../../../node_modules/@popperjs/core/lib/modifiers/flip.js","../../../node_modules/@popperjs/core/lib/modifiers/hide.js","../../../node_modules/@popperjs/core/lib/modifiers/offset.js","../../../node_modules/@popperjs/core/lib/modifiers/popperOffsets.js","../../../node_modules/@popperjs/core/lib/utils/getAltAxis.js","../../../node_modules/@popperjs/core/lib/modifiers/preventOverflow.js","../../../node_modules/@popperjs/core/lib/dom-utils/getHTMLElementScroll.js","../../../node_modules/@popperjs/core/lib/dom-utils/getNodeScroll.js","../../../node_modules/@popperjs/core/lib/dom-utils/getCompositeRect.js","../../../node_modules/@popperjs/core/lib/utils/orderModifiers.js","../../../node_modules/@popperjs/core/lib/utils/debounce.js","../../../node_modules/@popperjs/core/lib/utils/mergeByName.js","../../../node_modules/@popperjs/core/lib/createPopper.js","../../../node_modules/@popperjs/core/lib/popper.js","../../../node_modules/@mui/base/Popper/popperClasses.js","../../../node_modules/@mui/base/Popper/Popper.js","../../../node_modules/@mui/material/styles/useTheme.js","../../../node_modules/@babel/runtime/helpers/esm/setPrototypeOf.js","../../../node_modules/@babel/runtime/helpers/esm/inheritsLoose.js","../../../node_modules/react-transition-group/esm/config.js","../../../node_modules/react-transition-group/esm/utils/PropTypes.js","../../../node_modules/react-transition-group/esm/TransitionGroupContext.js","../../../node_modules/react-transition-group/esm/utils/reflow.js","../../../node_modules/react-transition-group/esm/Transition.js","../../../node_modules/@mui/material/transitions/utils.js","../../../node_modules/@mui/material/Grow/Grow.js","../../../node_modules/@mui/material/Popper/Popper.js","../../../node_modules/@mui/material/Tooltip/tooltipClasses.js","../../../node_modules/@mui/material/Tooltip/Tooltip.js","../src/components/mui/menu-item.component.tsx","../src/components/mui/grouped-menu-item-list.component.tsx","../src/components/mui/top-level-menu.component.tsx","../src/components/mui/grid-menu.component.tsx","../src/hooks/use-promise.hook.ts","../../../node_modules/@mui/icons-material/esm/Menu.js","../src/components/mui/hamburger-menu-button.component.tsx","../src/components/mui/icon-button.component.tsx","../src/components/basics/spinner.component.tsx","../src/components/basics/text-field.component.tsx","../src/components/mui/toolbar.component.tsx","../src/components/shadcn-ui/alert.tsx","../src/components/shadcn-ui/card.tsx","../src/components/shadcn-ui/sonner.tsx","../src/components/shadcn-ui/slider.tsx","../src/components/shadcn-ui/switch.tsx","../src/components/shadcn-ui/tabs.tsx","../src/components/advanced/extension-marketplace/buttons/install-button.component.tsx","../src/components/advanced/extension-marketplace/buttons/enable-button.component.tsx","../src/components/advanced/extension-marketplace/buttons/disable-button.component.tsx","../src/components/advanced/extension-marketplace/buttons/update-button.component.tsx","../src/components/advanced/extension-marketplace/markdown-renderer.component.tsx","../src/components/advanced/extension-marketplace/buttons/filter-button.component.tsx","../src/components/advanced/extension-marketplace/filter-dropdown.component.tsx","../src/components/advanced/extension-marketplace/no-extensions-found.component.tsx","../src/components/advanced/extension-marketplace/more-info.component.tsx","../src/components/advanced/extension-marketplace/version-history.component.tsx","../src/components/advanced/extension-marketplace/footer.component.tsx","../src/hooks/use-event.hook.ts","../src/hooks/use-event-async.hook.ts"],"sourcesContent":["import { type ClassValue, clsx } from 'clsx';\nimport { extendTailwindMerge } from 'tailwind-merge';\n\nconst twMergeCustom = extendTailwindMerge({ prefix: 'tw-' });\n\n/**\n * Tailwind and CSS class application helper function. Uses\n * [`clsx`](https://www.npmjs.com/package/clsx) to make it easy to apply classes conditionally using\n * object syntax, and uses [`tailwind-merge`](https://www.npmjs.com/package/tailwind-merge) to make\n * it easy to merge/overwrite Tailwind classes in a programmer-logic-friendly way.\n *\n * Note: `tailwind-merge` is configured to use the prefix `tw-`, so you must use the same prefix\n * with any Tailwind classes you use with this function to successfully overwrite other Tailwind\n * classes. `platform-bible-react` is configured to use `tw-` as its Tailwind prefix, so any\n * Tailwind classes you pass into `platform-bible-react` components will be compared using the `tw-`\n * prefix.\n *\n * This function was popularized by\n * [shadcn/ui](https://ui.shadcn.com/docs/installation/manual#add-a-cn-helper). See [ByteGrad's\n * explanation video](https://www.youtube.com/watch?v=re2JFITR7TI) for more information.\n *\n * @example\n *\n * ```typescript\n * const borderShouldBeBlue = true;\n * const textShouldBeRed = true;\n * const heightShouldBe20 = false;\n * const classString = cn(\n * 'tw-bg-primary tw-h-10 tw-text-primary-foreground',\n * 'tw-bg-secondary',\n * {\n * 'tw-border-blue-500': borderShouldBeBlue,\n * 'tw-text-red-500': textShouldBeRed,\n * 'tw-h-20': heightShouldBe20,\n * },\n * 'some-class',\n * );\n * ```\n *\n * The resulting `classString` is `'tw-h-10 tw-bg-secondary tw-border-blue-500 tw-text-red-500\n * some-class'`\n *\n * - Notice that `'tw-bg-secondary'`, specified later, overwrote `'tw-bg-primary'`, specified earlier,\n * because they are Tailwind classes that affect the same css property\n * - Notice that `'tw-text-red-500'`, specified later, overwrote `'tw-text-primary-foreground'`,\n * specified earlier, because they are Tailwind classes that affect the same css property\n * - Notice that `'tw-h-20'`, specified later, did not overwrite `'tw-h-10'`, specified earlier,\n * because `'tw-h-20'` is part of a conditional class object and its value evaluated to `false`;\n * therefore it was not applied\n * - Notice that `'some-class'` was applied. This function is not limited only to Tailwind classes.\n *\n *\n * @param inputs Class strings or `clsx` conditional class objects to merge. Tailwind classes\n * specified later in the arguments overwrite similar Tailwind classes specified earlier in the\n * arguments\n * @returns Class string containing all applicable classes from the arguments based on the rules\n * described above\n */\n// shadcn/ui uses this export in its boilerplate code\n// eslint-disable-next-line import/prefer-default-export\nexport function cn(...inputs: ClassValue[]) {\n return twMergeCustom(clsx(inputs));\n}\n","import React from 'react';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport interface InputProps extends React.InputHTMLAttributes {}\n\nexport const Input = React.forwardRef(\n ({ className, type, ...props }, ref) => {\n return (\n \n );\n },\n);\nInput.displayName = 'Input';\n","import { FocusEventHandler, forwardRef, KeyboardEvent, MouseEventHandler } from 'react';\nimport { History } from 'lucide-react';\nimport { Input as ShadInput } from '@/components/shadcn-ui/input';\n\nexport type BookChapterInputProps = {\n handleSearch: (searchString: string) => void;\n handleKeyDown: (event: KeyboardEvent) => void;\n handleOnClick: MouseEventHandler;\n handleSubmit: () => void;\n onFocus?: FocusEventHandler;\n value: string;\n placeholder: string;\n};\n\n// Shadcn Input sets type to \"button\"- HAVE to prop spread before setting type\nconst BookChapterInput = forwardRef(\n (\n { handleSearch, handleKeyDown, handleOnClick, handleSubmit, ...props }: BookChapterInputProps,\n ref,\n ) => {\n return (\n
    \n handleSearch(event.target.value)}\n onKeyDown={(e) => {\n if (e.key === 'Enter') {\n handleSubmit();\n }\n handleKeyDown(e);\n }}\n onClick={handleOnClick}\n ref={ref}\n />\n {\n // eslint-disable-next-line no-console\n console.log('back in history');\n }}\n />\n
    \n );\n },\n);\n\nexport default BookChapterInput;\n","var P = Object.defineProperty;\nvar R = (t, e, s) => e in t ? P(t, e, { enumerable: !0, configurable: !0, writable: !0, value: s }) : t[e] = s;\nvar n = (t, e, s) => R(t, typeof e != \"symbol\" ? e + \"\" : e, s);\nclass _ {\n constructor() {\n n(this, \"books\");\n n(this, \"firstSelectedBookNum\");\n n(this, \"lastSelectedBookNum\");\n n(this, \"count\");\n n(this, \"selectedBookNumbers\");\n n(this, \"selectedBookIds\");\n }\n}\nconst N = [\n \"GEN\",\n \"EXO\",\n \"LEV\",\n \"NUM\",\n \"DEU\",\n \"JOS\",\n \"JDG\",\n \"RUT\",\n \"1SA\",\n \"2SA\",\n // 10\n \"1KI\",\n \"2KI\",\n \"1CH\",\n \"2CH\",\n \"EZR\",\n \"NEH\",\n \"EST\",\n \"JOB\",\n \"PSA\",\n \"PRO\",\n // 20\n \"ECC\",\n \"SNG\",\n \"ISA\",\n \"JER\",\n \"LAM\",\n \"EZK\",\n \"DAN\",\n \"HOS\",\n \"JOL\",\n \"AMO\",\n // 30\n \"OBA\",\n \"JON\",\n \"MIC\",\n \"NAM\",\n \"HAB\",\n \"ZEP\",\n \"HAG\",\n \"ZEC\",\n \"MAL\",\n \"MAT\",\n // 40\n \"MRK\",\n \"LUK\",\n \"JHN\",\n \"ACT\",\n \"ROM\",\n \"1CO\",\n \"2CO\",\n \"GAL\",\n \"EPH\",\n \"PHP\",\n // 50\n \"COL\",\n \"1TH\",\n \"2TH\",\n \"1TI\",\n \"2TI\",\n \"TIT\",\n \"PHM\",\n \"HEB\",\n \"JAS\",\n \"1PE\",\n // 60\n \"2PE\",\n \"1JN\",\n \"2JN\",\n \"3JN\",\n \"JUD\",\n \"REV\",\n \"TOB\",\n \"JDT\",\n \"ESG\",\n \"WIS\",\n // 70\n \"SIR\",\n \"BAR\",\n \"LJE\",\n \"S3Y\",\n \"SUS\",\n \"BEL\",\n \"1MA\",\n \"2MA\",\n \"3MA\",\n \"4MA\",\n // 80\n \"1ES\",\n \"2ES\",\n \"MAN\",\n \"PS2\",\n \"ODA\",\n \"PSS\",\n \"JSA\",\n // actual variant text for JOS, now in LXA text\n \"JDB\",\n // actual variant text for JDG, now in LXA text\n \"TBS\",\n // actual variant text for TOB, now in LXA text\n \"SST\",\n // actual variant text for SUS, now in LXA text // 90\n \"DNT\",\n // actual variant text for DAN, now in LXA text\n \"BLT\",\n // actual variant text for BEL, now in LXA text\n \"XXA\",\n \"XXB\",\n \"XXC\",\n \"XXD\",\n \"XXE\",\n \"XXF\",\n \"XXG\",\n \"FRT\",\n // 100\n \"BAK\",\n \"OTH\",\n \"3ES\",\n // Used previously but really should be 2ES\n \"EZA\",\n // Used to be called 4ES, but not actually in any known project\n \"5EZ\",\n // Used to be called 5ES, but not actually in any known project\n \"6EZ\",\n // Used to be called 6ES, but not actually in any known project\n \"INT\",\n \"CNC\",\n \"GLO\",\n \"TDX\",\n // 110\n \"NDX\",\n \"DAG\",\n \"PS3\",\n \"2BA\",\n \"LBA\",\n \"JUB\",\n \"ENO\",\n \"1MQ\",\n \"2MQ\",\n \"3MQ\",\n // 120\n \"REP\",\n \"4BA\",\n \"LAO\"\n], B = [\n \"XXA\",\n \"XXB\",\n \"XXC\",\n \"XXD\",\n \"XXE\",\n \"XXF\",\n \"XXG\",\n \"FRT\",\n \"BAK\",\n \"OTH\",\n \"INT\",\n \"CNC\",\n \"GLO\",\n \"TDX\",\n \"NDX\"\n], O = [\n \"Genesis\",\n \"Exodus\",\n \"Leviticus\",\n \"Numbers\",\n \"Deuteronomy\",\n \"Joshua\",\n \"Judges\",\n \"Ruth\",\n \"1 Samuel\",\n \"2 Samuel\",\n \"1 Kings\",\n \"2 Kings\",\n \"1 Chronicles\",\n \"2 Chronicles\",\n \"Ezra\",\n \"Nehemiah\",\n \"Esther (Hebrew)\",\n \"Job\",\n \"Psalms\",\n \"Proverbs\",\n \"Ecclesiastes\",\n \"Song of Songs\",\n \"Isaiah\",\n \"Jeremiah\",\n \"Lamentations\",\n \"Ezekiel\",\n \"Daniel (Hebrew)\",\n \"Hosea\",\n \"Joel\",\n \"Amos\",\n \"Obadiah\",\n \"Jonah\",\n \"Micah\",\n \"Nahum\",\n \"Habakkuk\",\n \"Zephaniah\",\n \"Haggai\",\n \"Zechariah\",\n \"Malachi\",\n \"Matthew\",\n \"Mark\",\n \"Luke\",\n \"John\",\n \"Acts\",\n \"Romans\",\n \"1 Corinthians\",\n \"2 Corinthians\",\n \"Galatians\",\n \"Ephesians\",\n \"Philippians\",\n \"Colossians\",\n \"1 Thessalonians\",\n \"2 Thessalonians\",\n \"1 Timothy\",\n \"2 Timothy\",\n \"Titus\",\n \"Philemon\",\n \"Hebrews\",\n \"James\",\n \"1 Peter\",\n \"2 Peter\",\n \"1 John\",\n \"2 John\",\n \"3 John\",\n \"Jude\",\n \"Revelation\",\n \"Tobit\",\n \"Judith\",\n \"Esther Greek\",\n \"Wisdom of Solomon\",\n \"Sirach (Ecclesiasticus)\",\n \"Baruch\",\n \"Letter of Jeremiah\",\n \"Song of 3 Young Men\",\n \"Susanna\",\n \"Bel and the Dragon\",\n \"1 Maccabees\",\n \"2 Maccabees\",\n \"3 Maccabees\",\n \"4 Maccabees\",\n \"1 Esdras (Greek)\",\n \"2 Esdras (Latin)\",\n \"Prayer of Manasseh\",\n \"Psalm 151\",\n \"Odes\",\n \"Psalms of Solomon\",\n // WARNING, if you change the spelling of the *obsolete* tag be sure to update\n // IsObsolete routine\n \"Joshua A. *obsolete*\",\n \"Judges B. *obsolete*\",\n \"Tobit S. *obsolete*\",\n \"Susanna Th. *obsolete*\",\n \"Daniel Th. *obsolete*\",\n \"Bel Th. *obsolete*\",\n \"Extra A\",\n \"Extra B\",\n \"Extra C\",\n \"Extra D\",\n \"Extra E\",\n \"Extra F\",\n \"Extra G\",\n \"Front Matter\",\n \"Back Matter\",\n \"Other Matter\",\n \"3 Ezra *obsolete*\",\n \"Apocalypse of Ezra\",\n \"5 Ezra (Latin Prologue)\",\n \"6 Ezra (Latin Epilogue)\",\n \"Introduction\",\n \"Concordance \",\n \"Glossary \",\n \"Topical Index\",\n \"Names Index\",\n \"Daniel Greek\",\n \"Psalms 152-155\",\n \"2 Baruch (Apocalypse)\",\n \"Letter of Baruch\",\n \"Jubilees\",\n \"Enoch\",\n \"1 Meqabyan\",\n \"2 Meqabyan\",\n \"3 Meqabyan\",\n \"Reproof (Proverbs 25-31)\",\n \"4 Baruch (Rest of Baruch)\",\n \"Laodiceans\"\n], S = K();\nfunction g(t, e = !0) {\n return e && (t = t.toUpperCase()), t in S ? S[t] : 0;\n}\nfunction k(t) {\n return g(t) > 0;\n}\nfunction x(t) {\n const e = typeof t == \"string\" ? g(t) : t;\n return e >= 40 && e <= 66;\n}\nfunction T(t) {\n return (typeof t == \"string\" ? g(t) : t) <= 39;\n}\nfunction X(t) {\n return t <= 66;\n}\nfunction V(t) {\n const e = typeof t == \"string\" ? g(t) : t;\n return w(e) && !X(e);\n}\nfunction* L() {\n for (let t = 1; t <= N.length; t++) yield t;\n}\nconst G = 1, A = N.length;\nfunction H() {\n return [\"XXA\", \"XXB\", \"XXC\", \"XXD\", \"XXE\", \"XXF\", \"XXG\"];\n}\nfunction C(t, e = \"***\") {\n const s = t - 1;\n return s < 0 || s >= N.length ? e : N[s];\n}\nfunction I(t) {\n return t <= 0 || t > A ? \"******\" : O[t - 1];\n}\nfunction y(t) {\n return I(g(t));\n}\nfunction w(t) {\n const e = typeof t == \"number\" ? C(t) : t;\n return k(e) && !B.includes(e);\n}\nfunction q(t) {\n const e = typeof t == \"number\" ? C(t) : t;\n return k(e) && B.includes(e);\n}\nfunction U(t) {\n return O[t - 1].includes(\"*obsolete*\");\n}\nfunction K() {\n const t = {};\n for (let e = 0; e < N.length; e++)\n t[N[e]] = e + 1;\n return t;\n}\nconst m = {\n allBookIds: N,\n nonCanonicalIds: B,\n bookIdToNumber: g,\n isBookIdValid: k,\n isBookNT: x,\n isBookOT: T,\n isBookOTNT: X,\n isBookDC: V,\n allBookNumbers: L,\n firstBook: G,\n lastBook: A,\n extraBooks: H,\n bookNumberToId: C,\n bookNumberToEnglishName: I,\n bookIdToEnglishName: y,\n isCanonical: w,\n isExtraMaterial: q,\n isObsolete: U\n};\nvar l = /* @__PURE__ */ ((t) => (t[t.Unknown = 0] = \"Unknown\", t[t.Original = 1] = \"Original\", t[t.Septuagint = 2] = \"Septuagint\", t[t.Vulgate = 3] = \"Vulgate\", t[t.English = 4] = \"English\", t[t.RussianProtestant = 5] = \"RussianProtestant\", t[t.RussianOrthodox = 6] = \"RussianOrthodox\", t))(l || {});\nconst h = class h {\n // private versInfo: Versification;\n constructor(e) {\n n(this, \"name\");\n n(this, \"fullPath\");\n n(this, \"isPresent\");\n n(this, \"hasVerseSegments\");\n n(this, \"isCustomized\");\n n(this, \"baseVersification\");\n n(this, \"scriptureBooks\");\n n(this, \"_type\");\n if (e == null)\n throw new Error(\"Argument undefined\");\n typeof e == \"string\" ? (this.name = e, this._type = l[e]) : (this._type = e, this.name = l[e]);\n }\n get type() {\n return this._type;\n }\n equals(e) {\n return !e.type || !this.type ? !1 : e.type === this.type;\n }\n};\nn(h, \"Original\", new h(l.Original)), n(h, \"Septuagint\", new h(l.Septuagint)), n(h, \"Vulgate\", new h(l.Vulgate)), n(h, \"English\", new h(l.English)), n(h, \"RussianProtestant\", new h(l.RussianProtestant)), n(h, \"RussianOrthodox\", new h(l.RussianOrthodox));\nlet c = h;\nfunction E(t, e) {\n const s = e[0];\n for (let r = 1; r < e.length; r++)\n t = t.split(e[r]).join(s);\n return t.split(s);\n}\nvar D = /* @__PURE__ */ ((t) => (t[t.Valid = 0] = \"Valid\", t[t.UnknownVersification = 1] = \"UnknownVersification\", t[t.OutOfRange = 2] = \"OutOfRange\", t[t.VerseOutOfOrder = 3] = \"VerseOutOfOrder\", t[t.VerseRepeated = 4] = \"VerseRepeated\", t))(D || {});\nconst i = class i {\n constructor(e, s, r, a) {\n /** Not yet implemented. */\n n(this, \"firstChapter\");\n /** Not yet implemented. */\n n(this, \"lastChapter\");\n /** Not yet implemented. */\n n(this, \"lastVerse\");\n /** Not yet implemented. */\n n(this, \"hasSegmentsDefined\");\n /** Not yet implemented. */\n n(this, \"text\");\n /** Not yet implemented. */\n n(this, \"BBBCCCVVVS\");\n /** Not yet implemented. */\n n(this, \"longHashCode\");\n /** The versification of the reference. */\n n(this, \"versification\");\n n(this, \"rtlMark\", \"‏\");\n n(this, \"_bookNum\", 0);\n n(this, \"_chapterNum\", 0);\n n(this, \"_verseNum\", 0);\n n(this, \"_verse\");\n if (r == null && a == null)\n if (e != null && typeof e == \"string\") {\n const o = e, u = s != null && s instanceof c ? s : void 0;\n this.setEmpty(u), this.parse(o);\n } else if (e != null && typeof e == \"number\") {\n const o = s != null && s instanceof c ? s : void 0;\n this.setEmpty(o), this._verseNum = e % i.chapterDigitShifter, this._chapterNum = Math.floor(\n e % i.bookDigitShifter / i.chapterDigitShifter\n ), this._bookNum = Math.floor(e / i.bookDigitShifter);\n } else if (s == null)\n if (e != null && e instanceof i) {\n const o = e;\n this._bookNum = o.bookNum, this._chapterNum = o.chapterNum, this._verseNum = o.verseNum, this._verse = o.verse, this.versification = o.versification;\n } else {\n if (e == null) return;\n const o = e instanceof c ? e : i.defaultVersification;\n this.setEmpty(o);\n }\n else\n throw new Error(\"VerseRef constructor not supported.\");\n else if (e != null && s != null && r != null)\n if (typeof e == \"string\" && typeof s == \"string\" && typeof r == \"string\")\n this.setEmpty(a), this.updateInternal(e, s, r);\n else if (typeof e == \"number\" && typeof s == \"number\" && typeof r == \"number\")\n this._bookNum = e, this._chapterNum = s, this._verseNum = r, this.versification = a ?? i.defaultVersification;\n else\n throw new Error(\"VerseRef constructor not supported.\");\n else\n throw new Error(\"VerseRef constructor not supported.\");\n }\n /**\n * Determines if the verse string is in a valid format (does not consider versification).\n */\n static isVerseParseable(e) {\n return e.length > 0 && \"0123456789\".includes(e[0]) && !e.endsWith(this.verseRangeSeparator) && !e.endsWith(this.verseSequenceIndicator);\n }\n /**\n * Tries to parse the specified string into a verse reference.\n * @param str - The string to attempt to parse.\n * @returns success: `true` if the specified string was successfully parsed, `false` otherwise.\n * @returns verseRef: The result of the parse if successful, or empty VerseRef if it failed\n */\n static tryParse(e) {\n let s;\n try {\n return s = new i(e), { success: !0, verseRef: s };\n } catch (r) {\n if (r instanceof v)\n return s = new i(), { success: !1, verseRef: s };\n throw r;\n }\n }\n /**\n * Gets the reference as a comparable integer where the book, chapter, and verse each occupy 3\n * digits.\n * @param bookNum - Book number (this is 1-based, not an index).\n * @param chapterNum - Chapter number.\n * @param verseNum - Verse number.\n * @returns The reference as a comparable integer where the book, chapter, and verse each occupy 3\n * digits.\n */\n static getBBBCCCVVV(e, s, r) {\n return e % i.bcvMaxValue * i.bookDigitShifter + (s >= 0 ? s % i.bcvMaxValue * i.chapterDigitShifter : 0) + (r >= 0 ? r % i.bcvMaxValue : 0);\n }\n /**\n * Deserializes a serialized VerseRef.\n * @param serializedVerseRef - Serialized VerseRef to create from.\n * @returns the deserialized VerseRef.\n */\n static fromJSON(e) {\n const { book: s, chapterNum: r, verseNum: a, verse: o, versificationStr: u } = e, f = o || a.toString();\n let d;\n return u && (d = new c(u)), s ? new i(s, r.toString(), f, d) : new i();\n }\n /**\n * Parses a verse string and gets the leading numeric portion as a number.\n * @param verseStr - verse string to parse\n * @returns true if the entire string could be parsed as a single, simple verse number (1-999);\n * false if the verse string represented a verse bridge, contained segment letters, or was invalid\n */\n static tryGetVerseNum(e) {\n let s;\n if (!e)\n return s = -1, { success: !0, vNum: s };\n s = 0;\n let r;\n for (let a = 0; a < e.length; a++) {\n if (r = e[a], r < \"0\" || r > \"9\")\n return a === 0 && (s = -1), { success: !1, vNum: s };\n if (s = s * 10 + +r - 0, s > i.bcvMaxValue)\n return s = -1, { success: !1, vNum: s };\n }\n return { success: !0, vNum: s };\n }\n /**\n * Checks to see if a VerseRef hasn't been set - all values are the default.\n */\n get isDefault() {\n return this.bookNum === 0 && this.chapterNum === 0 && this.verseNum === 0 && this.versification == null;\n }\n /**\n * Gets whether the verse contains multiple verses.\n */\n get hasMultiple() {\n return this._verse != null && (this._verse.includes(i.verseRangeSeparator) || this._verse.includes(i.verseSequenceIndicator));\n }\n /**\n * Gets or sets the book of the reference. Book is the 3-letter abbreviation in capital letters,\n * e.g. `'MAT'`.\n */\n get book() {\n return m.bookNumberToId(this.bookNum, \"\");\n }\n set book(e) {\n this.bookNum = m.bookIdToNumber(e);\n }\n /**\n * Gets or sets the chapter of the reference,. e.g. `'3'`.\n */\n get chapter() {\n return this.isDefault || this._chapterNum < 0 ? \"\" : this._chapterNum.toString();\n }\n set chapter(e) {\n const s = +e;\n this._chapterNum = Number.isInteger(s) ? s : -1;\n }\n /**\n * Gets or sets the verse of the reference, including range, segments, and sequences, e.g. `'4'`,\n * or `'4b-5a, 7'`.\n */\n get verse() {\n return this._verse != null ? this._verse : this.isDefault || this._verseNum < 0 ? \"\" : this._verseNum.toString();\n }\n set verse(e) {\n const { success: s, vNum: r } = i.tryGetVerseNum(e);\n this._verse = s ? void 0 : e.replace(this.rtlMark, \"\"), this._verseNum = r, !(this._verseNum >= 0) && ({ vNum: this._verseNum } = i.tryGetVerseNum(this._verse));\n }\n /**\n * Get or set Book based on book number, e.g. `42`.\n */\n get bookNum() {\n return this._bookNum;\n }\n set bookNum(e) {\n if (e <= 0 || e > m.lastBook)\n throw new v(\n \"BookNum must be greater than zero and less than or equal to last book\"\n );\n this._bookNum = e;\n }\n /**\n * Gets or sets the chapter number, e.g. `3`. `-1` if not valid.\n */\n get chapterNum() {\n return this._chapterNum;\n }\n set chapterNum(e) {\n this.chapterNum = e;\n }\n /**\n * Gets or sets verse start number, e.g. `4`. `-1` if not valid.\n */\n get verseNum() {\n return this._verseNum;\n }\n set verseNum(e) {\n this._verseNum = e;\n }\n /**\n * String representing the versification (should ONLY be used for serialization/deserialization).\n *\n * @remarks This is for backwards compatibility when ScrVers was an enumeration.\n */\n get versificationStr() {\n var e;\n return (e = this.versification) == null ? void 0 : e.name;\n }\n set versificationStr(e) {\n this.versification = this.versification != null ? new c(e) : void 0;\n }\n /**\n * Determines if the reference is valid.\n */\n get valid() {\n return this.validStatus === 0;\n }\n /**\n * Get the valid status for this reference.\n */\n get validStatus() {\n return this.validateVerse(i.verseRangeSeparators, i.verseSequenceIndicators);\n }\n /**\n * Gets the reference as a comparable integer where the book,\n * chapter, and verse each occupy three digits and the verse is 0.\n */\n get BBBCCC() {\n return i.getBBBCCCVVV(this._bookNum, this._chapterNum, 0);\n }\n /**\n * Gets the reference as a comparable integer where the book,\n * chapter, and verse each occupy three digits. If verse is not null\n * (i.e., this reference represents a complex reference with verse\n * segments or bridge) this cannot be used for an exact comparison.\n */\n get BBBCCCVVV() {\n return i.getBBBCCCVVV(this._bookNum, this._chapterNum, this._verseNum);\n }\n /**\n * Gets whether the verse is defined as an excluded verse in the versification.\n * Does not handle verse ranges.\n */\n // eslint-disable-next-line @typescript-eslint/class-literal-property-style\n get isExcluded() {\n return !1;\n }\n /**\n * Parses the reference in the specified string.\n * Optionally versification can follow reference as in GEN 3:11/4\n * Throw an exception if\n * - invalid book name\n * - chapter number is missing or not a number\n * - verse number is missing or does not start with a number\n * - versification is invalid\n * @param verseStr - string to parse e.g. 'MAT 3:11'\n */\n parse(e) {\n if (e = e.replace(this.rtlMark, \"\"), e.includes(\"/\")) {\n const o = e.split(\"/\");\n if (e = o[0], o.length > 1)\n try {\n const u = +o[1].trim();\n this.versification = new c(l[u]);\n } catch {\n throw new v(\"Invalid reference : \" + e);\n }\n }\n const s = e.trim().split(\" \");\n if (s.length !== 2)\n throw new v(\"Invalid reference : \" + e);\n const r = s[1].split(\":\"), a = +r[0];\n if (r.length !== 2 || m.bookIdToNumber(s[0]) === 0 || !Number.isInteger(a) || a < 0 || !i.isVerseParseable(r[1]))\n throw new v(\"Invalid reference : \" + e);\n this.updateInternal(s[0], r[0], r[1]);\n }\n /**\n * Simplifies this verse ref so that it has no bridging of verses or\n * verse segments like `'1a'`.\n */\n simplify() {\n this._verse = void 0;\n }\n /**\n * Makes a clone of the reference.\n *\n * @returns The cloned VerseRef.\n */\n clone() {\n return new i(this);\n }\n toString() {\n const e = this.book;\n return e === \"\" ? \"\" : `${e} ${this.chapter}:${this.verse}`;\n }\n toJSON() {\n let e = this.verse;\n (e === \"\" || e === this.verseNum.toString()) && (e = void 0);\n const s = {\n book: this.book,\n chapterNum: this.chapterNum,\n verseNum: this.verseNum,\n verse: e,\n versificationStr: this.versificationStr\n };\n return e || delete s.verse, s;\n }\n /**\n * Compares this `VerseRef` with supplied one.\n * @param verseRef - object to compare this one to.\n * @returns `true` if this `VerseRef` is equal to the supplied one, `false` otherwise.\n */\n equals(e) {\n return e instanceof i ? e._bookNum === this._bookNum && e._chapterNum === this._chapterNum && e._verseNum === this._verseNum && e.verse === this.verse && (e.versification == null && this.versification == null || e.versification != null && this.versification != null && e.versification.equals(this.versification)) : !1;\n }\n /**\n * Enumerate all individual verses contained in a VerseRef.\n * Verse ranges are indicated by \"-\" and consecutive verses by \",\"s.\n * Examples:\n * GEN 1:2 returns GEN 1:2\n * GEN 1:1a-3b,5 returns GEN 1:1a, GEN 1:2, GEN 1:3b, GEN 1:5\n * GEN 1:2a-2c returns //! ??????\n *\n * @param specifiedVersesOnly - if set to true return only verses that are\n * explicitly specified only, not verses within a range. Defaults to `false`.\n * @param verseRangeSeparators - Verse range separators.\n * Defaults to `VerseRef.verseRangeSeparators`.\n * @param verseSequenceSeparators - Verse sequence separators.\n * Defaults to `VerseRef.verseSequenceIndicators`.\n * @returns An array of all single verse references in this VerseRef.\n */\n allVerses(e = !1, s = i.verseRangeSeparators, r = i.verseSequenceIndicators) {\n if (this._verse == null || this.chapterNum <= 0)\n return [this.clone()];\n const a = [], o = E(this._verse, r);\n for (const u of o.map((f) => E(f, s))) {\n const f = this.clone();\n f.verse = u[0];\n const d = f.verseNum;\n if (a.push(f), u.length > 1) {\n const b = this.clone();\n if (b.verse = u[1], !e)\n for (let p = d + 1; p < b.verseNum; p++) {\n const J = new i(\n this._bookNum,\n this._chapterNum,\n p,\n this.versification\n );\n this.isExcluded || a.push(J);\n }\n a.push(b);\n }\n }\n return a;\n }\n /**\n * Validates a verse number using the supplied separators rather than the defaults.\n */\n validateVerse(e, s) {\n if (!this.verse)\n return this.internalValid;\n let r = 0;\n for (const a of this.allVerses(!0, e, s)) {\n const o = a.internalValid;\n if (o !== 0)\n return o;\n const u = a.BBBCCCVVV;\n if (r > u)\n return 3;\n if (r === u)\n return 4;\n r = u;\n }\n return 0;\n }\n /**\n * Gets whether a single verse reference is valid.\n */\n get internalValid() {\n return this.versification == null ? 1 : this._bookNum <= 0 || this._bookNum > m.lastBook ? 2 : (m.isCanonical(this._bookNum), 0);\n }\n setEmpty(e = i.defaultVersification) {\n this._bookNum = 0, this._chapterNum = -1, this._verse = void 0, this.versification = e;\n }\n updateInternal(e, s, r) {\n this.bookNum = m.bookIdToNumber(e), this.chapter = s, this.verse = r;\n }\n};\nn(i, \"defaultVersification\", c.English), n(i, \"verseRangeSeparator\", \"-\"), n(i, \"verseSequenceIndicator\", \",\"), n(i, \"verseRangeSeparators\", [i.verseRangeSeparator]), n(i, \"verseSequenceIndicators\", [i.verseSequenceIndicator]), n(i, \"chapterDigitShifter\", 1e3), n(i, \"bookDigitShifter\", i.chapterDigitShifter * i.chapterDigitShifter), n(i, \"bcvMaxValue\", i.chapterDigitShifter - 1), /**\n * The valid status of the VerseRef.\n */\nn(i, \"ValidStatusType\", D);\nlet M = i;\nclass v extends Error {\n}\nexport {\n _ as BookSet,\n m as Canon,\n c as ScrVers,\n l as ScrVersType,\n M as VerseRef,\n v as VerseRefException\n};\n//# sourceMappingURL=index.es.js.map\n","import React from 'react';\nimport * as DropdownMenuPrimitive from '@radix-ui/react-dropdown-menu';\nimport { Check, ChevronRight, Circle } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport const DropdownMenu = DropdownMenuPrimitive.Root;\n\nexport const DropdownMenuTrigger = DropdownMenuPrimitive.Trigger;\n\nexport const DropdownMenuGroup = DropdownMenuPrimitive.Group;\n\nexport const DropdownMenuPortal = DropdownMenuPrimitive.Portal;\n\nexport const DropdownMenuSub = DropdownMenuPrimitive.Sub;\n\nexport const DropdownMenuRadioGroup = DropdownMenuPrimitive.RadioGroup;\n\nexport type DropdownMenuSubTriggerProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.SubTrigger\n> & {\n className?: string;\n inset?: boolean;\n};\n\nexport type DropdownMenuSubContentProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.SubContent\n> & {\n className?: string;\n};\n\nexport type DropdownMenuContentProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Content\n> & {\n className?: string;\n sideOffset?: number;\n};\n\nexport type DropdownMenuItemProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Item\n> & {\n className?: string;\n inset?: boolean;\n};\n\nexport type DropdownMenuCheckboxItemProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.CheckboxItem\n> & {\n className?: string;\n checked?: boolean;\n};\n\nexport type DropdownMenuRadioItemProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.RadioItem\n> & {\n className?: string;\n};\n\nexport type DropdownMenuLabelProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Label\n> & {\n className?: string;\n inset?: boolean;\n};\n\nexport type DropdownMenuSeparatorProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Separator\n> & {\n className?: string;\n};\n\nexport type DropdownMenuShortcutProps = React.HTMLAttributes & {\n className?: string;\n};\n\nexport const DropdownMenuSubTrigger = React.forwardRef<\n React.ElementRef,\n DropdownMenuSubTriggerProps\n>(({ className, inset, children, ...props }, ref) => (\n \n {children}\n \n \n));\nDropdownMenuSubTrigger.displayName = DropdownMenuPrimitive.SubTrigger.displayName;\n\nexport const DropdownMenuSubContent = React.forwardRef<\n React.ElementRef,\n DropdownMenuSubContentProps\n>(({ className, ...props }, ref) => (\n \n));\nDropdownMenuSubContent.displayName = DropdownMenuPrimitive.SubContent.displayName;\n\nexport const DropdownMenuContent = React.forwardRef<\n React.ElementRef,\n DropdownMenuContentProps\n>(({ className, sideOffset = 4, ...props }, ref) => (\n \n \n \n));\nDropdownMenuContent.displayName = DropdownMenuPrimitive.Content.displayName;\n\n/**\n * TODO: fix: direction is not automatically handled by this component, so that shortcuts are\n * display always to the right\n */\nexport const DropdownMenuItem = React.forwardRef<\n React.ElementRef,\n DropdownMenuItemProps\n>(({ className, inset, ...props }, ref) => (\n \n));\nDropdownMenuItem.displayName = DropdownMenuPrimitive.Item.displayName;\n\nexport const DropdownMenuCheckboxItem = React.forwardRef<\n React.ElementRef,\n DropdownMenuCheckboxItemProps\n>(({ className, children, checked, ...props }, ref) => (\n \n \n \n \n \n \n {children}\n \n));\nDropdownMenuCheckboxItem.displayName = DropdownMenuPrimitive.CheckboxItem.displayName;\n\nexport const DropdownMenuRadioItem = React.forwardRef<\n React.ElementRef,\n DropdownMenuRadioItemProps\n>(({ className, children, ...props }, ref) => (\n \n \n \n \n \n \n {children}\n \n));\nDropdownMenuRadioItem.displayName = DropdownMenuPrimitive.RadioItem.displayName;\n\nexport const DropdownMenuLabel = React.forwardRef<\n React.ElementRef,\n DropdownMenuLabelProps\n>(({ className, inset, ...props }, ref) => (\n \n));\nDropdownMenuLabel.displayName = DropdownMenuPrimitive.Label.displayName;\n\nexport const DropdownMenuSeparator = React.forwardRef<\n React.ElementRef,\n DropdownMenuSeparatorProps\n>(({ className, ...props }, ref) => (\n \n));\nDropdownMenuSeparator.displayName = DropdownMenuPrimitive.Separator.displayName;\n\nexport function DropdownMenuShortcut({ className, ...props }: DropdownMenuShortcutProps) {\n return (\n \n );\n}\nDropdownMenuShortcut.displayName = 'DropdownMenuShortcut';\n","import { Canon } from '@sillsdev/scripture';\nimport { PropsWithChildren, KeyboardEvent, forwardRef } from 'react';\nimport { DropdownMenuItem as ShadDropdownMenuItem } from '@/components/shadcn-ui/dropdown-menu';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport type BookType = 'OT' | 'NT' | 'DC';\n\ntype BookMenuItemProps = PropsWithChildren<{\n /** String id of book */\n bookId: string;\n /** Callback to run when a book menu item is selected */\n handleSelectBook: () => void;\n /** Indicates if this menu item is currently selected */\n isSelected: boolean;\n /** Function that is called upon highlighting a book in the dropdown menu */\n handleHighlightBook: () => void;\n /**\n * Function that is called on pressing a key\n *\n * @param event Event that contains information about the key stroke\n */\n handleKeyDown: (event: KeyboardEvent) => void;\n /**\n * Type of book associated with this menu item, coordinates color labels ? Mock up has the labels\n * coordinated to genre\n */\n bookType: BookType;\n}>;\n\nconst BookMenuItem = forwardRef(\n (\n {\n bookId,\n handleSelectBook,\n isSelected,\n handleHighlightBook,\n handleKeyDown,\n bookType,\n children,\n }: BookMenuItemProps,\n ref,\n ) => {\n return (\n {\n // preventDefault() here prevents the entire dropdown menu from closing when selecting this item\n event.preventDefault();\n handleSelectBook();\n }}\n onKeyDown={(event: KeyboardEvent) => {\n handleKeyDown(event);\n }}\n onFocus={handleHighlightBook}\n onMouseMove={handleHighlightBook}\n >\n \n {Canon.bookIdToEnglishName(bookId)}\n \n {isSelected &&
    {children}
    }\n \n );\n },\n);\n\nexport default BookMenuItem;\n","import { cn } from '@/utils/shadcn-ui.util';\nimport { useCallback } from 'react';\n\nexport type ChapterSelectProps = {\n /**\n * Callback to run when a chapter div is selected\n *\n * @param chapterNumber Number of the chapter that has been selected\n */\n handleSelectChapter: (chapterNumber: number) => void;\n /** The highest chapter number in the book (of course equal to number of chapters in the book) */\n endChapter: number;\n /** The chapter number that is currently selected */\n activeChapter: number;\n /** The chapter number that is currently highlighted using keyboard or mouse navigation */\n highlightedChapter: number;\n /**\n * Callback to run when a chapter is highlighted by the user\n *\n * @param chapterNumber The chapter that is highlighted\n */\n handleHighlightedChapter: (chapterNumber: number) => void;\n};\n\nfunction ChapterSelect({\n handleSelectChapter,\n endChapter,\n activeChapter,\n highlightedChapter,\n handleHighlightedChapter,\n}: ChapterSelectProps) {\n const chapters = Array.from({ length: endChapter }, (_, i) => i + 1);\n\n const handleMouse = useCallback(\n (chapterNumber: number) => {\n handleHighlightedChapter(chapterNumber);\n },\n [handleHighlightedChapter],\n );\n\n return (\n
    \n {chapters.map((chapter) => (\n {\n event.preventDefault();\n event.stopPropagation();\n handleSelectChapter(chapter);\n }}\n role=\"button\"\n onKeyDown={(event) => {\n if (event.key === 'Enter') {\n handleSelectChapter(chapter);\n }\n }}\n tabIndex={0}\n onMouseMove={() => handleMouse(chapter)}\n >\n {chapter}\n
    \n ))}\n
    \n );\n}\n\nexport default ChapterSelect;\n","import { DropdownMenuLabel as ShadDropdownMenuLabel } from '@/components/shadcn-ui/dropdown-menu';\nimport { Bookmark, Clock, ArrowDownWideNarrow } from 'lucide-react';\n\nexport type GoToMenuItemProps = {\n handleSort: () => void;\n handleLocationHistory: () => void;\n handleBookmarks: () => void;\n};\n\nfunction GoToMenuItem({ handleSort, handleLocationHistory, handleBookmarks }: GoToMenuItemProps) {\n return (\n \n

    Go To

    \n
    \n \n \n \n
    \n
    \n );\n}\n\nexport default GoToMenuItem;\n","import BookChapterInput from '@/components/advanced/book-chapter-control/book-chapter-input.component';\nimport BookMenuItem, {\n BookType,\n} from '@/components/advanced/book-chapter-control/book-menu-item.component';\nimport ChapterSelect from '@/components/advanced/book-chapter-control/chapter-select.component';\nimport GoToMenuItem from '@/components/advanced/book-chapter-control/go-to-menu-item.component';\nimport {\n DropdownMenu as ShadDropdownMenu,\n DropdownMenuContent as ShadDropdownMenuContent,\n DropdownMenuLabel as ShadDropdownMenuLabel,\n DropdownMenuSeparator as ShadDropdownMenuSeparator,\n DropdownMenuTrigger as ShadDropdownMenuTrigger,\n} from '@/components/shadcn-ui/dropdown-menu';\nimport { Canon } from '@sillsdev/scripture';\nimport { ScriptureReference, getChaptersForBook } from 'platform-bible-utils';\nimport {\n KeyboardEvent as ReactKeyboardEvent,\n useCallback,\n useEffect,\n useLayoutEffect,\n useRef,\n useState,\n} from 'react';\n\ntype BookTypeLabels = {\n [bookType in BookType]: string;\n};\ntype BookChapterControlProps = {\n scrRef: ScriptureReference;\n handleSubmit: (scrRef: ScriptureReference) => void;\n};\n\nconst ALL_BOOK_IDS = Canon.allBookIds;\nconst BOOK_TYPE_LABELS: BookTypeLabels = {\n OT: 'Old Testament',\n NT: 'New Testament',\n DC: 'Deuterocanon',\n};\nconst BOOK_TYPE_ARRAY: BookType[] = ['OT', 'NT', 'DC'];\n// This is the height of three menu items to offset scrolling to the selected menu item\n// If you use menuItemRef.clientHeight- includes height of chapter div which is too big\nconst SCROLL_OFFSET = 32 + 32 + 32;\nconst SEARCH_QUERY_FORMATS = [\n /^(\\w+)$/i, // Matches a single word (book name or id)\n /^(\\w+)(?:\\s(\\d+))$/i, // Matches a word followed by a chapter number\n /^(\\w+)(?:\\s(\\d+):(\\d+))$/i, // Matches a word followed by a chapter and verse number\n];\nconst fetchGroupedBooks = (bookType: BookType) => {\n const groupedBooks = {\n OT: ALL_BOOK_IDS.filter((bookId) => Canon.isBookOT(bookId)),\n NT: ALL_BOOK_IDS.filter((bookId) => Canon.isBookNT(bookId)),\n DC: ALL_BOOK_IDS.filter((bookId) => Canon.isBookDC(bookId)),\n };\n return groupedBooks[bookType];\n};\nconst fetchEndChapter = (bookId: string) => {\n // getChaptersForBook returns -1 if not found in scrBookData\n // scrBookData only includes OT and NT, so all DC will return -1\n return getChaptersForBook(Canon.bookIdToNumber(bookId));\n};\n\n/**\n * Gets all of the English names from book ids\n *\n * @returns String[]\n */\nfunction getAllEnglishNames(): string[] {\n const allEnglishNames = ALL_BOOK_IDS.map((bookId) => {\n return Canon.bookIdToEnglishName(bookId);\n });\n return allEnglishNames;\n}\n\n/**\n * Determines if bookName is in allEnglishNames\n *\n * @param bookName Book English name\n * @returns True if bookName is included, false otherwise\n */\nfunction isValidBookEnglishName(bookName: string): boolean {\n return getAllEnglishNames().includes(bookName);\n}\n\n/**\n * Gets a bookId from given English name\n *\n * @param bookName Book English name\n * @returns BookId of provided bookName, undefined otherwise\n */\nfunction getBookIdFromEnglishName(bookName: string): string | undefined {\n // Convert bookName to lowercase and then capitalize the first letter\n const formattedBookName = bookName.toLowerCase().replace(/^\\w/, (c) => c.toUpperCase());\n\n if (isValidBookEnglishName(formattedBookName)) {\n const matchingBookId = ALL_BOOK_IDS.find((bookId) => {\n return Canon.bookIdToEnglishName(bookId) === formattedBookName;\n });\n return matchingBookId;\n }\n\n return undefined;\n}\n\nfunction BookChapterControl({ scrRef, handleSubmit }: BookChapterControlProps) {\n const [searchQuery, setSearchQuery] = useState('');\n const [selectedBookId, setSelectedBookId] = useState(\n Canon.bookNumberToId(scrRef.bookNum),\n );\n const [highlightedChapter, setHighlightedChapter] = useState(scrRef.chapterNum ?? 0);\n const [highlightedBookId, setHighlightedBookId] = useState(\n Canon.bookNumberToId(scrRef.bookNum),\n );\n const [isContentOpen, setIsContentOpen] = useState(false);\n const [isContentOpenDelayed, setIsContentOpenDelayed] = useState(isContentOpen);\n\n // This ref will always be defined\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const inputRef = useRef(undefined!);\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const contentRef = useRef(undefined!);\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const menuItemRef = useRef(undefined!);\n\n const fetchFilteredBooks = useCallback(\n (bookType: BookType) => {\n return fetchGroupedBooks(bookType).filter((bookId: string) => {\n const englishNameLowerCase = Canon.bookIdToEnglishName(bookId).toLowerCase();\n const normalizedQuery = searchQuery.replace(/[^a-zA-Z]/g, '').toLowerCase();\n return (\n englishNameLowerCase.includes(normalizedQuery) || // Match book name\n bookId.toLowerCase().includes(normalizedQuery) // Match book ID\n );\n });\n },\n [searchQuery],\n );\n\n const handleSearchInput = (searchString: string) => {\n setSearchQuery(searchString);\n };\n\n /**\n * Whether to prevent radix's logic from closing the dropdown. This is important because radix\n * tries to close the dropdown when the input first focuses, and we don't want it to do that. But\n * we don't want to prevent the dropdown from closing when we click away from the input, so we\n * don't want to just keep it open if the input is focused\n */\n const shouldPreventAutoClosing = useRef(false);\n\n const controlMenuState = useCallback((open: boolean) => {\n if (shouldPreventAutoClosing.current) {\n shouldPreventAutoClosing.current = false;\n return;\n }\n setIsContentOpen(open);\n }, []);\n\n const updateReference = useCallback(\n (bookId: string, shouldClose: boolean, chapter?: number, verse?: number) => {\n setHighlightedChapter(\n Canon.bookNumberToId(scrRef.bookNum) !== bookId ? 1 : scrRef.chapterNum,\n );\n\n if (shouldClose || fetchEndChapter(bookId) === -1) {\n handleSubmit({\n bookNum: Canon.bookIdToNumber(bookId),\n chapterNum: chapter || 1,\n verseNum: verse || 1,\n });\n\n setIsContentOpen(false);\n setSearchQuery('');\n return;\n }\n\n setSelectedBookId(selectedBookId !== bookId ? bookId : '');\n setIsContentOpen(!shouldClose);\n },\n [handleSubmit, scrRef.bookNum, scrRef.chapterNum, selectedBookId],\n );\n\n const handleSelectChapter = (chapterNumber: number) => {\n if (chapterNumber <= 0 || chapterNumber > fetchEndChapter(selectedBookId)) {\n return;\n }\n updateReference(selectedBookId, true, chapterNumber);\n };\n\n const handleInputSubmit = useCallback(() => {\n SEARCH_QUERY_FORMATS.forEach((format) => {\n const matches = searchQuery.match(format);\n if (matches) {\n // Book should be a bookId or an english name\n const [book, chapter = undefined, verse = undefined] = matches.slice(1);\n const englishName = getBookIdFromEnglishName(book);\n\n if (Canon.isBookIdValid(book) || englishName) {\n updateReference(\n englishName ?? book,\n true,\n chapter ? parseInt(chapter, 10) : 1,\n verse ? parseInt(verse, 10) : 1,\n );\n }\n }\n });\n }, [updateReference, searchQuery]);\n\n const handleKeyDownInput = useCallback(\n (event: ReactKeyboardEvent) => {\n if (!isContentOpen) {\n setIsContentOpen(true);\n } else if (event.key === 'ArrowDown' || event.key === 'ArrowUp') {\n if (\n typeof menuItemRef !== 'undefined' &&\n // Ref uses null\n // eslint-disable-next-line no-null/no-null\n menuItemRef.current !== null\n ) {\n menuItemRef.current.focus();\n } else if (\n typeof contentRef !== 'undefined' &&\n // Ref uses null\n // eslint-disable-next-line no-null/no-null\n contentRef.current !== null\n ) {\n contentRef.current.focus();\n }\n event.preventDefault();\n }\n },\n [isContentOpen],\n );\n\n const handleKeyDownContent = (event: ReactKeyboardEvent) => {\n // When the dropdown menu has focus, key strokes should give focus to the input component,\n // unless they're navigation keys (arrows and enter)\n const { key } = event;\n if (\n key === 'ArrowRight' ||\n key === 'ArrowLeft' ||\n key === 'ArrowDown' ||\n key === 'ArrowUp' ||\n key === 'Enter'\n ) {\n return;\n }\n\n inputRef.current.dispatchEvent(new KeyboardEvent('keydown', { key }));\n inputRef.current.focus();\n };\n\n const handleKeyDownMenuItem = (event: ReactKeyboardEvent) => {\n const { key } = event;\n if (highlightedBookId === selectedBookId) {\n if (key === 'Enter') {\n event.preventDefault();\n updateReference(selectedBookId, true, highlightedChapter);\n return;\n }\n\n let chapterOffSet = 0;\n if (key === 'ArrowRight') {\n if (highlightedChapter < fetchEndChapter(highlightedBookId)) {\n chapterOffSet = 1;\n } else {\n event.preventDefault();\n return;\n }\n } else if (key === 'ArrowLeft') {\n if (highlightedChapter > 1) {\n chapterOffSet = -1;\n } else {\n event.preventDefault();\n return;\n }\n } else if (key === 'ArrowDown') {\n chapterOffSet = 6;\n } else if (key === 'ArrowUp') {\n chapterOffSet = -6;\n }\n if (\n highlightedChapter + chapterOffSet <= 0 ||\n highlightedChapter + chapterOffSet > fetchEndChapter(highlightedBookId)\n ) {\n setHighlightedChapter(0);\n } else if (chapterOffSet !== 0) {\n setHighlightedChapter(highlightedChapter + chapterOffSet);\n event.preventDefault();\n }\n }\n };\n\n useEffect(() => {\n if (selectedBookId === highlightedBookId) {\n if (selectedBookId === Canon.bookNumberToId(scrRef.bookNum)) {\n setHighlightedChapter(scrRef.chapterNum);\n } else {\n setHighlightedChapter(1);\n }\n } else {\n setHighlightedChapter(0);\n }\n }, [highlightedBookId, scrRef.bookNum, scrRef.chapterNum, selectedBookId]);\n\n // The purpose of these useLayoutEffects and timeout is to delay the scroll just\n // enough so that the refs are defined and available when they are used after the timeout\n useLayoutEffect(() => {\n setIsContentOpenDelayed(isContentOpen);\n }, [isContentOpen]);\n\n useLayoutEffect(() => {\n const scrollTimeout = setTimeout(() => {\n if (isContentOpenDelayed && contentRef.current && menuItemRef.current) {\n const menuItemOffsetTop = menuItemRef.current.offsetTop;\n const scrollPosition = menuItemOffsetTop - SCROLL_OFFSET;\n contentRef.current.scrollTo({ top: scrollPosition, behavior: 'instant' });\n }\n }, 10);\n return () => {\n clearTimeout(scrollTimeout);\n };\n }, [isContentOpenDelayed]);\n\n return (\n
    \n \n \n {\n setSelectedBookId(Canon.bookNumberToId(scrRef.bookNum));\n setHighlightedBookId(Canon.bookNumberToId(scrRef.bookNum));\n setHighlightedChapter(scrRef.chapterNum > 0 ? scrRef.chapterNum : 0);\n setIsContentOpen(true);\n inputRef.current.focus();\n }}\n onFocus={() => {\n // Radix thinks we want to close because the input is being focused. Prevent that\n shouldPreventAutoClosing.current = true;\n }}\n handleSubmit={handleInputSubmit}\n placeholder={`${Canon.bookNumberToEnglishName(scrRef.bookNum)} ${scrRef.chapterNum}:${scrRef.verseNum}`}\n />\n \n \n console.log('sorting')}\n handleLocationHistory={() => console.log('location history')}\n handleBookmarks={() => console.log('bookmarks')}\n />\n {BOOK_TYPE_ARRAY.map(\n (bookType, bookTypeIndex) =>\n fetchFilteredBooks(bookType).length > 0 && (\n
    \n \n {BOOK_TYPE_LABELS[bookType]}\n \n\n {fetchFilteredBooks(bookType).map((bookId) => (\n
    \n updateReference(bookId, false)}\n isSelected={selectedBookId === bookId}\n handleHighlightBook={() => setHighlightedBookId(bookId)}\n handleKeyDown={handleKeyDownMenuItem}\n bookType={bookType}\n ref={(element: HTMLDivElement) => {\n if (selectedBookId === bookId) menuItemRef.current = element;\n }}\n >\n {\n setHighlightedChapter(chapterNumber);\n }}\n />\n \n
    \n ))}\n {BOOK_TYPE_ARRAY.length - 1 !== bookTypeIndex ? (\n \n ) : undefined}\n
    \n ),\n )}\n \n
    \n
    \n );\n}\n\nexport default BookChapterControl;\n","import React from 'react';\nimport { Slot } from '@radix-ui/react-slot';\nimport { cva, type VariantProps } from 'class-variance-authority';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport const buttonVariants = cva(\n 'pr-twp tw-inline-flex tw-items-center tw-justify-center tw-whitespace-nowrap tw-rounded-md tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-colors focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50',\n {\n variants: {\n variant: {\n default: 'tw-bg-primary tw-text-primary-foreground hover:tw-bg-primary/90',\n destructive: 'tw-bg-destructive tw-text-destructive-foreground hover:tw-bg-destructive/90',\n outline:\n 'tw-border tw-border-input tw-bg-background hover:tw-bg-accent hover:tw-text-accent-foreground',\n secondary: 'tw-bg-secondary tw-text-secondary-foreground hover:tw-bg-secondary/80',\n ghost: 'hover:tw-bg-accent hover:tw-text-accent-foreground',\n link: 'tw-text-primary tw-underline-offset-4 hover:tw-underline',\n },\n size: {\n default: 'tw-h-10 tw-px-4 tw-py-2',\n sm: 'tw-h-9 tw-rounded-md tw-px-3',\n lg: 'tw-h-11 tw-rounded-md tw-px-8',\n icon: 'tw-h-10 tw-w-10',\n },\n },\n defaultVariants: {\n variant: 'default',\n size: 'default',\n },\n },\n);\n\nexport interface ButtonProps\n extends React.ButtonHTMLAttributes,\n VariantProps {\n asChild?: boolean;\n}\n\nexport const Button = React.forwardRef(\n ({ className, variant, size, asChild = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'button';\n return (\n \n );\n },\n);\nButton.displayName = 'Button';\n","import React from 'react';\nimport * as LabelPrimitive from '@radix-ui/react-label';\nimport { cva, type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst labelVariants = cva(\n 'tw-text-sm tw-font-medium tw-leading-none peer-disabled:tw-cursor-not-allowed peer-disabled:tw-opacity-70',\n);\n\nexport const Label = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef & VariantProps\n>(({ className, ...props }, ref) => (\n \n));\nLabel.displayName = LabelPrimitive.Root.displayName;\n","import React from 'react';\nimport * as RadioGroupPrimitive from '@radix-ui/react-radio-group';\nimport { Circle } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst RadioGroup = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => {\n return (\n \n );\n});\nRadioGroup.displayName = RadioGroupPrimitive.Root.displayName;\n\nconst RadioGroupItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => {\n return (\n \n \n \n \n \n );\n});\nRadioGroupItem.displayName = RadioGroupPrimitive.Item.displayName;\n\nexport { RadioGroup, RadioGroupItem };\n","import React from 'react';\nimport * as PopoverPrimitive from '@radix-ui/react-popover';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Popover = PopoverPrimitive.Root;\n\nconst PopoverTrigger = PopoverPrimitive.Trigger;\n\nconst PopoverContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, align = 'center', sideOffset = 4, ...props }, ref) => (\n \n \n \n));\nPopoverContent.displayName = PopoverPrimitive.Content.displayName;\n\nexport { Popover, PopoverTrigger, PopoverContent };\n","import React from 'react';\nimport * as DialogPrimitive from '@radix-ui/react-dialog';\nimport { X } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Dialog = DialogPrimitive.Root;\n\nconst DialogTrigger = DialogPrimitive.Trigger;\n\nconst DialogPortal = DialogPrimitive.Portal;\n\nconst DialogClose = DialogPrimitive.Close;\n\nconst DialogOverlay = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nDialogOverlay.displayName = DialogPrimitive.Overlay.displayName;\n\nconst DialogContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, ...props }, ref) => (\n \n \n \n {children}\n \n \n Close\n \n \n \n));\nDialogContent.displayName = DialogPrimitive.Content.displayName;\n\nfunction DialogHeader({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nDialogHeader.displayName = 'DialogHeader';\n\nfunction DialogFooter({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nDialogFooter.displayName = 'DialogFooter';\n\nconst DialogTitle = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nDialogTitle.displayName = DialogPrimitive.Title.displayName;\n\nconst DialogDescription = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nDialogDescription.displayName = DialogPrimitive.Description.displayName;\n\nexport {\n Dialog,\n DialogPortal,\n DialogOverlay,\n DialogClose,\n DialogTrigger,\n DialogContent,\n DialogHeader,\n DialogFooter,\n DialogTitle,\n DialogDescription,\n};\n","import React from 'react';\nimport { type DialogProps } from '@radix-ui/react-dialog';\nimport { Command as CommandPrimitive } from 'cmdk';\nimport { Search } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Dialog, DialogContent } from '@/components/shadcn-ui/dialog';\n\nconst Command = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nCommand.displayName = CommandPrimitive.displayName;\n\ninterface CommandDialogProps extends DialogProps {}\n\nfunction CommandDialog({ children, ...props }: CommandDialogProps) {\n return (\n \n \n \n {children}\n \n \n \n );\n}\n\nconst CommandInput = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n
    \n \n \n
    \n));\n\nCommandInput.displayName = CommandPrimitive.Input.displayName;\n\nconst CommandList = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\n\nCommandList.displayName = CommandPrimitive.List.displayName;\n\nconst CommandEmpty = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>((props, ref) => (\n \n));\n\nCommandEmpty.displayName = CommandPrimitive.Empty.displayName;\n\nconst CommandGroup = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\n\nCommandGroup.displayName = CommandPrimitive.Group.displayName;\n\nconst CommandSeparator = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nCommandSeparator.displayName = CommandPrimitive.Separator.displayName;\n\nconst CommandItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\n\nCommandItem.displayName = CommandPrimitive.Item.displayName;\n\nfunction CommandShortcut({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nCommandShortcut.displayName = 'CommandShortcut';\n\nexport {\n Command,\n CommandDialog,\n CommandInput,\n CommandList,\n CommandEmpty,\n CommandGroup,\n CommandItem,\n CommandShortcut,\n CommandSeparator,\n};\n","import { useState } from 'react';\nimport { Check, ChevronsUpDown } from 'lucide-react';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport { Popover, PopoverContent, PopoverTrigger } from '@/components/shadcn-ui/popover';\nimport {\n Command,\n CommandEmpty,\n CommandInput,\n CommandItem,\n CommandList,\n} from '@/components/shadcn-ui/command';\nimport { PopoverProps } from '@radix-ui/react-popover';\n\nexport type ComboBoxLabelOption = { label: string };\nexport type ComboBoxOption = string | number | ComboBoxLabelOption;\n\nexport type ComboBoxProps = {\n /** Optional unique identifier */\n id?: string;\n /** Text label title for combobox */\n /** List of available options for the dropdown menu */\n options?: readonly T[];\n /** @deprecated 3 December 2024. Renamed to {@link buttonClassName} */\n className?: string;\n /** Additional css classes to help with unique styling of the combo box button */\n buttonClassName?: string;\n /** Additional css classes to help with unique styling of the combo box popover */\n popoverContentClassName?: string;\n /**\n * The selected value that the combo box currently holds. Must be shallow equal to one of the\n * options entries.\n */\n value?: T;\n /** Triggers when content of textfield is changed */\n onChange?: (newValue: T) => void;\n /** Used to determine the string value for a given option. */\n getOptionLabel?: (option: ComboBoxOption) => string;\n /** Text displayed on button if `value` is undefined */\n buttonPlaceholder?: string;\n /** Placeholder text for text field */\n textPlaceholder?: string;\n /** Text to display when no options match input */\n commandEmptyMessage?: string;\n /** Variant of button */\n buttonVariant?: ButtonProps['variant'];\n /** Text direction ltr or rtl */\n dir?: Direction;\n /** Optional boolean to set if trigger should be disabled */\n isDisabled?: boolean;\n} & PopoverProps;\n\ntype Direction = 'ltr' | 'rtl';\n\nfunction getOptionLabelDefault(option: ComboBoxOption): string {\n if (typeof option === 'string') {\n return option;\n }\n if (typeof option === 'number') {\n return option.toString();\n }\n return option.label;\n}\n\n/**\n * Autocomplete input and command palette with a list of suggestions.\n *\n * Thanks to Shadcn for heavy inspiration and documentation\n * https://ui.shadcn.com/docs/components/combobox\n */\nfunction ComboBox({\n id,\n options = [],\n className,\n buttonClassName,\n popoverContentClassName,\n value,\n onChange = () => {},\n getOptionLabel = getOptionLabelDefault,\n buttonPlaceholder = '',\n textPlaceholder = '',\n commandEmptyMessage = 'No option found',\n buttonVariant = 'outline',\n dir = 'ltr',\n isDisabled = false,\n ...props\n}: ComboBoxProps) {\n const [open, setOpen] = useState(false);\n\n return (\n \n \n \n \n {value ? getOptionLabel(value) : buttonPlaceholder}\n \n \n \n \n \n \n \n {commandEmptyMessage}\n \n {options.map((option) => (\n {\n onChange(option);\n setOpen(false);\n }}\n >\n \n {getOptionLabel(option)}\n \n ))}\n \n \n \n \n );\n}\n\nexport default ComboBox;\n","import { useMemo } from 'react';\nimport ComboBox from '@/components/basics/combo-box.component';\nimport { Label } from '@/components/shadcn-ui/label';\n\nexport type ChapterRangeSelectorProps = {\n startChapter: number;\n endChapter: number;\n handleSelectStartChapter: (chapter: number) => void;\n handleSelectEndChapter: (chapter: number) => void;\n isDisabled?: boolean;\n chapterCount: number;\n};\n\nexport default function ChapterRangeSelector({\n startChapter,\n endChapter,\n handleSelectStartChapter,\n handleSelectEndChapter,\n isDisabled = false,\n chapterCount,\n}: ChapterRangeSelectorProps) {\n const chapterOptions = useMemo(\n () => Array.from({ length: chapterCount }, (_, index) => index + 1),\n [chapterCount],\n );\n\n const onChangeStartChapter = (value: number) => {\n handleSelectStartChapter(value);\n if (value > endChapter) {\n handleSelectEndChapter(value);\n }\n };\n\n const onChangeEndChapter = (value: number) => {\n handleSelectEndChapter(value);\n if (value < startChapter) {\n handleSelectStartChapter(value);\n }\n };\n\n return (\n <>\n \n option.toString()}\n value={startChapter}\n />\n\n \n option.toString()}\n value={endChapter}\n />\n \n );\n}\n","import { Button } from '@/components/shadcn-ui/button';\nimport { Label } from '@/components/shadcn-ui/label';\nimport { RadioGroup, RadioGroupItem } from '@/components/shadcn-ui/radio-group';\nimport { Canon } from '@sillsdev/scripture';\nimport { LocalizedStringValue } from 'platform-bible-utils';\nimport { useState } from 'react';\nimport ChapterRangeSelector, {\n ChapterRangeSelectorProps,\n} from '../basics/chapter-range-selector.component';\n\nexport enum BookSelectionMode {\n CURRENT_BOOK = 'current book',\n CHOOSE_BOOKS = 'choose books',\n}\n\n/**\n * Object containing all keys used for localization in this component. If you're using this\n * component in an extension, you can pass it into the useLocalizedStrings hook to easily obtain the\n * localized strings and pass them into the localizedStrings prop of this component\n */\nexport const BOOK_SELECTOR_STRING_KEYS = Object.freeze([\n '%webView_bookSelector_currentBook%',\n '%webView_bookSelector_choose%',\n '%webView_bookSelector_chooseBooks%',\n] as const);\n\nexport type BookSelectorLocalizedStrings = {\n [localizedInventoryKey in (typeof BOOK_SELECTOR_STRING_KEYS)[number]]?: LocalizedStringValue;\n};\n\n/**\n * Gets the localized value for the provided key\n *\n * @param strings Object containing localized string\n * @param key Key for a localized string\n * @returns The localized value for the provided key, if available. Returns the key if no localized\n * value is available\n */\nconst localizeString = (\n strings: BookSelectorLocalizedStrings,\n key: keyof BookSelectorLocalizedStrings,\n) => {\n return strings[key] ?? key;\n};\n\ntype BookSelectorProps = ChapterRangeSelectorProps & {\n handleBookSelectionModeChange: (newMode: BookSelectionMode) => void;\n currentBookName: string;\n onSelectBooks: () => void;\n selectedBookIds: string[];\n localizedStrings: BookSelectorLocalizedStrings;\n};\n\nexport default function BookSelector({\n handleBookSelectionModeChange,\n currentBookName,\n onSelectBooks,\n selectedBookIds,\n chapterCount,\n endChapter,\n handleSelectEndChapter,\n startChapter,\n handleSelectStartChapter,\n localizedStrings,\n}: BookSelectorProps) {\n const currentBookText = localizeString(localizedStrings, '%webView_bookSelector_currentBook%');\n const chooseText = localizeString(localizedStrings, '%webView_bookSelector_choose%');\n const chooseBooksText = localizeString(localizedStrings, '%webView_bookSelector_chooseBooks%');\n\n const [bookSelectionMode, setBookSelectionMode] = useState(\n BookSelectionMode.CURRENT_BOOK,\n );\n\n const onSelectionModeChange = (newMode: BookSelectionMode) => {\n setBookSelectionMode(newMode);\n handleBookSelectionModeChange(newMode);\n };\n\n return (\n onSelectionModeChange(value as BookSelectionMode)}\n >\n
    \n
    \n
    \n \n \n
    \n \n
    \n \n
    \n
    \n
    \n
    \n \n \n
    \n \n onSelectBooks()}\n >\n {chooseText}\n \n
    \n
    \n \n );\n}\n","import { DropdownMenuTrigger } from '@radix-ui/react-dropdown-menu';\nimport { FilterIcon } from 'lucide-react';\nimport { Table } from '@tanstack/react-table';\n\nimport { Button } from '@/components/shadcn-ui/button';\nimport {\n DropdownMenu,\n DropdownMenuCheckboxItem,\n DropdownMenuContent,\n DropdownMenuLabel,\n DropdownMenuSeparator,\n} from '@/components/shadcn-ui/dropdown-menu';\n\ninterface DataTableViewOptionsProps {\n table: Table;\n}\n\nfunction DataTableViewOptions({ table }: DataTableViewOptionsProps) {\n return (\n \n \n \n \n \n Toggle columns\n \n {table\n .getAllColumns()\n .filter((column) => column.getCanHide())\n .map((column) => {\n return (\n column.toggleVisibility(!!value)}\n >\n {column.id}\n \n );\n })}\n \n \n );\n}\n\nexport default DataTableViewOptions;\n","import React from 'react';\nimport * as SelectPrimitive from '@radix-ui/react-select';\nimport { Check, ChevronDown, ChevronUp } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Select = SelectPrimitive.Root;\n\nconst SelectGroup = SelectPrimitive.Group;\n\nconst SelectValue = SelectPrimitive.Value;\n\nconst SelectTrigger = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, ...props }, ref) => (\n span]:tw-line-clamp-1',\n className,\n )}\n {...props}\n >\n {children}\n \n \n \n \n));\nSelectTrigger.displayName = SelectPrimitive.Trigger.displayName;\n\nconst SelectScrollUpButton = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n));\nSelectScrollUpButton.displayName = SelectPrimitive.ScrollUpButton.displayName;\n\nconst SelectScrollDownButton = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n));\nSelectScrollDownButton.displayName = SelectPrimitive.ScrollDownButton.displayName;\n\nconst SelectContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, position = 'popper', ...props }, ref) => (\n \n \n \n \n {children}\n \n \n \n \n));\nSelectContent.displayName = SelectPrimitive.Content.displayName;\n\nconst SelectLabel = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSelectLabel.displayName = SelectPrimitive.Label.displayName;\n\nconst SelectItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, ...props }, ref) => (\n \n \n \n \n \n \n\n {children}\n \n));\nSelectItem.displayName = SelectPrimitive.Item.displayName;\n\nconst SelectSeparator = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSelectSeparator.displayName = SelectPrimitive.Separator.displayName;\n\nexport {\n Select,\n SelectGroup,\n SelectValue,\n SelectTrigger,\n SelectContent,\n SelectLabel,\n SelectItem,\n SelectSeparator,\n SelectScrollUpButton,\n SelectScrollDownButton,\n};\n","import { ChevronLeftIcon, ChevronRightIcon, ArrowLeftIcon, ArrowRightIcon } from 'lucide-react';\nimport { Table } from '@tanstack/react-table';\n\nimport { Button } from '@/components/shadcn-ui/button';\nimport {\n Select,\n SelectContent,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\n\ninterface DataTablePaginationProps {\n table: Table;\n}\n\nfunction DataTablePagination({ table }: DataTablePaginationProps) {\n return (\n
    \n
    \n
    \n {table.getFilteredSelectedRowModel().rows.length} of{' '}\n {table.getFilteredRowModel().rows.length} row(s) selected\n
    \n
    \n

    Rows per page

    \n {\n table.setPageSize(Number(value));\n }}\n >\n \n \n \n \n {[10, 20, 30, 40, 50].map((pageSize) => (\n \n {pageSize}\n \n ))}\n \n \n
    \n
    \n Page {table.getState().pagination.pageIndex + 1} of {table.getPageCount()}\n
    \n
    \n table.setPageIndex(0)}\n disabled={!table.getCanPreviousPage()}\n >\n Go to first page\n \n \n table.previousPage()}\n disabled={!table.getCanPreviousPage()}\n >\n Go to previous page\n \n \n table.nextPage()}\n disabled={!table.getCanNextPage()}\n >\n Go to next page\n \n \n table.setPageIndex(table.getPageCount() - 1)}\n disabled={!table.getCanNextPage()}\n >\n Go to last page\n \n \n
    \n
    \n
    \n );\n}\n\nexport default DataTablePagination;\n","import React from 'react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Table = React.forwardRef<\n HTMLTableElement,\n React.HTMLAttributes & { stickyHeader?: boolean }\n>(({ className, stickyHeader, ...props }, ref) => (\n
    \n \n
    \n));\nTable.displayName = 'Table';\n\nconst TableHeader = React.forwardRef<\n HTMLTableSectionElement,\n React.HTMLAttributes & { stickyHeader?: boolean }\n>(({ className, stickyHeader, ...props }, ref) => (\n \n));\nTableHeader.displayName = 'TableHeader';\n\nconst TableBody = React.forwardRef<\n HTMLTableSectionElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableBody.displayName = 'TableBody';\n\nconst TableFooter = React.forwardRef<\n HTMLTableSectionElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n tr]:last:tw-border-b-0', className)}\n {...props}\n />\n));\nTableFooter.displayName = 'TableFooter';\n\nconst TableRow = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nTableRow.displayName = 'TableRow';\n\nconst TableHead = React.forwardRef<\n HTMLTableCellElement,\n React.ThHTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableHead.displayName = 'TableHead';\n\nconst TableCell = React.forwardRef<\n HTMLTableCellElement,\n React.TdHTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableCell.displayName = 'TableCell';\n\nconst TableCaption = React.forwardRef<\n HTMLTableCaptionElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableCaption.displayName = 'TableCaption';\n\nexport { Table, TableHeader, TableBody, TableFooter, TableHead, TableRow, TableCell, TableCaption };\n","import { useState } from 'react';\n\nimport {\n ColumnFiltersState,\n flexRender,\n getCoreRowModel,\n getFilteredRowModel,\n getPaginationRowModel,\n getSortedRowModel,\n SortingState,\n ColumnDef as TSColumnDef,\n Row as TSRow,\n RowSelectionState as TSRowSelectionState,\n SortDirection as TSSortDirection,\n Table as TSTable,\n useReactTable,\n VisibilityState,\n} from '@tanstack/react-table';\n\nimport DataTableViewOptions from '@/components/advanced/data-table/data-table-column-toggle.component';\nimport DataTablePagination from '@/components/advanced/data-table/data-table-pagination.component';\nimport { Button } from '@/components/shadcn-ui/button';\nimport {\n Table,\n TableBody,\n TableCell,\n TableHead,\n TableHeader,\n TableRow,\n} from '@/components/shadcn-ui/table';\n\nexport type ColumnDef = TSColumnDef;\nexport type RowContents = TSRow;\nexport type TableContents = TSTable;\nexport type SortDirection = TSSortDirection;\nexport type RowSelectionState = TSRowSelectionState;\n\ninterface DataTableProps {\n columns: ColumnDef[];\n data: TData[];\n enablePagination?: boolean;\n showPaginationControls?: boolean;\n showColumnVisibilityControls?: boolean;\n stickyHeader?: boolean;\n onRowClickHandler?: (row: RowContents, table: TableContents) => void;\n}\n\n/**\n * Feature-rich table component that infuses our basic shadcn-based Table component with features\n * from TanStack's React Table library\n */\nfunction DataTable({\n columns,\n data,\n enablePagination = false,\n showPaginationControls = false,\n showColumnVisibilityControls = false,\n stickyHeader = false,\n onRowClickHandler = () => {},\n}: DataTableProps) {\n const [sorting, setSorting] = useState([]);\n const [columnFilters, setColumnFilters] = useState([]);\n const [columnVisibility, setColumnVisibility] = useState({});\n const [rowSelection, setRowSelection] = useState({});\n\n const table = useReactTable({\n data,\n columns,\n getCoreRowModel: getCoreRowModel(),\n ...(enablePagination && { getPaginationRowModel: getPaginationRowModel() }),\n onSortingChange: setSorting,\n getSortedRowModel: getSortedRowModel(),\n onColumnFiltersChange: setColumnFilters,\n getFilteredRowModel: getFilteredRowModel(),\n onColumnVisibilityChange: setColumnVisibility,\n onRowSelectionChange: setRowSelection,\n state: {\n sorting,\n columnFilters,\n columnVisibility,\n rowSelection,\n },\n });\n\n return (\n
    \n {showColumnVisibilityControls && }\n \n \n {table.getHeaderGroups().map((headerGroup) => (\n \n {headerGroup.headers.map((header) => {\n return (\n \n {header.isPlaceholder\n ? undefined\n : flexRender(header.column.columnDef.header, header.getContext())}\n \n );\n })}\n \n ))}\n \n \n {table.getRowModel().rows?.length ? (\n table.getRowModel().rows.map((row) => (\n onRowClickHandler(row, table)}\n key={row.id}\n data-state={row.getIsSelected() && 'selected'}\n >\n {row.getVisibleCells().map((cell) => (\n \n {flexRender(cell.column.columnDef.cell, cell.getContext())}\n \n ))}\n \n ))\n ) : (\n \n \n No results.\n \n \n )}\n \n
    \n {enablePagination && (\n
    \n table.previousPage()}\n disabled={!table.getCanPreviousPage()}\n >\n Previous\n \n table.nextPage()}\n disabled={!table.getCanNextPage()}\n >\n Next\n \n
    \n )}\n {enablePagination && showPaginationControls && }\n
    \n );\n}\n\nexport default DataTable;\n","import {\n Table,\n TableBody,\n TableCell,\n TableHead,\n TableHeader,\n TableRow,\n} from '@/components/shadcn-ui/table';\nimport { Canon } from '@sillsdev/scripture';\nimport { deepEqual, LanguageStrings, ScriptureReference } from 'platform-bible-utils';\nimport { useMemo } from 'react';\nimport { InventoryItemOccurrence } from './inventory-utils';\n\n/** Props for the OccurrencesTable component */\ntype OccurrencesTableProps = {\n /** Data that contains scriptures references and snippets of scripture */\n occurrenceData: InventoryItemOccurrence[];\n /** Callback function that is executed when the scripture reference is changed */\n setScriptureReference: (scriptureReference: ScriptureReference) => void;\n /**\n * Object with all localized strings that the OccurrencesTable needs to work well across multiple\n * languages\n */\n localizedStrings: LanguageStrings;\n};\n\n/**\n * Table that shows occurrences of specified inventory item(s). The first column shows the related\n * scripture reference. The second column shows the snippet of scripture that contains the specified\n * inventory item\n */\nfunction OccurrencesTable({\n occurrenceData,\n setScriptureReference,\n localizedStrings,\n}: OccurrencesTableProps) {\n const referenceHeaderText =\n localizedStrings['%webView_inventory_occurrences_table_header_reference%'];\n const occurrenceHeaderText =\n localizedStrings['%webView_inventory_occurrences_table_header_occurrence%'];\n\n const occurrences: InventoryItemOccurrence[] = useMemo(() => {\n const uniqueOccurrences: InventoryItemOccurrence[] = [];\n\n occurrenceData.forEach((occurrence) => {\n if (!uniqueOccurrences.some((uniqueOccurrence) => deepEqual(uniqueOccurrence, occurrence))) {\n uniqueOccurrences.push(occurrence);\n }\n });\n\n return uniqueOccurrences;\n }, [occurrenceData]);\n\n return (\n \n \n \n {referenceHeaderText}\n {occurrenceHeaderText}\n \n \n \n {occurrences.length > 0 &&\n occurrences.map((occurrence) => (\n {\n setScriptureReference(occurrence.reference);\n }}\n >\n {`${Canon.bookNumberToEnglishName(occurrence.reference.bookNum)} ${occurrence.reference.chapterNum}:${occurrence.reference.verseNum}`}\n {occurrence.text}\n \n ))}\n \n
    \n );\n}\n\nexport default OccurrencesTable;\n","import React from 'react';\nimport * as CheckboxPrimitive from '@radix-ui/react-checkbox';\nimport { Check } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Checkbox = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n \n \n));\nCheckbox.displayName = CheckboxPrimitive.Root.displayName;\n\nexport default Checkbox;\n","import { Canon } from '@sillsdev/scripture';\nimport { ScriptureReference } from 'platform-bible-utils';\n\n/* #region Types */\n\n/**\n * Status of items that appear in inventories. 'approved' and 'unapproved' items are defined in the\n * project's `Settings.xml`. All other items are defined as 'unknown'\n */\nexport type Status = 'approved' | 'unapproved' | 'unknown';\n\n/** Occurrence of item in inventory. Primarily used by table that shows occurrences */\nexport type InventoryItemOccurrence = {\n /** Reference to scripture where the item appears */\n reference: ScriptureReference;\n /** Snippet of scripture that contains the occurrence */\n text: string;\n};\n\n/** Data structure that contains all information on an item that is shown in an inventory */\nexport type InventoryTableData = {\n /**\n * The item (e.g. a character in the characters inventory, a marker in the marker inventory) In\n * most cases the array will only have one element. In case of additional items (e.g. the\n * preceding marker in the markers check), the primary item should be stored in the first index.\n * To show additional items in the inventory, make sure to configure the `additionalItemsLabels`\n * prop for the Inventory component\n */\n items: string[];\n /** The number of times this item occurs in the selected scope */\n count: number;\n /** The status of this item (see documentation for `Status` type for more information) */\n status: Status;\n /** Occurrences of this item in the scripture text for the selected scope */\n occurrences: InventoryItemOccurrence[];\n};\n\n/* #endregion */\n\n/* #region Functions */\n\n/**\n * Splits USFM string into shorter line-like segments\n *\n * @param text A single (likely very large) USFM string\n * @returns An array containing the input text, split into shorter segments\n */\nexport const getLinesFromUSFM = (text: string) => {\n // Splits on (CR)LF, CR, \\v, \\c and \\id\n return text.split(/(?:\\r?\\n|\\r)|(?=(?:\\\\(?:v|c|id)))/g);\n};\n\n/**\n * Extracts chapter or verse number from USFM strings that start with a \\c or \\v marker\n *\n * @param text USFM string that is expected to start with \\c or \\v marker\n * @returns Chapter or verse number if one is found. Else returns 0.\n */\nexport const getNumberFromUSFM = (text: string): number | undefined => {\n // Captures all digits that follow \\v or \\c markers followed by whitespace located at the start of a string\n const regex = /^\\\\[vc]\\s+(\\d+)/;\n const match = text.match(regex);\n\n if (match) {\n return +match[1];\n }\n return undefined;\n};\n\n/**\n * Gets book ID from USFM string that starts with the \\id marker, and returns book number for it\n *\n * @param text USFM string that is expected to start with \\id marker\n * @returns Book number corresponding to the \\id marker in the input text. Returns 0 if no marker is\n * found or the marker is not valid\n */\nexport const getBookNumFromId = (text: string): number => {\n // Captures all digits that follow an \\id marker followed by whitespace located at the start of a string\n const match = text.match(/^\\\\id\\s+([A-Za-z]+)/);\n if (match) {\n return Canon.bookIdToNumber(match[1]);\n }\n return 0;\n};\n\n/**\n * Gets the status for an item, typically used in the Inventory component\n *\n * @param item The item for which the status is being requested\n * @param approvedItems Array of approved items, typically as defined in `Settings.xml`\n * @param unapprovedItems Array of unapproved items, typically as defined in `Settings.xml`\n * @returns The status for the specified item\n */\nexport const getStatusForItem = (\n item: string,\n approvedItems: string[],\n unapprovedItems: string[],\n): Status => {\n if (unapprovedItems.includes(item)) return 'unapproved';\n if (approvedItems.includes(item)) return 'approved';\n return 'unknown';\n};\n\n/* #endregion */\n","import React from 'react';\nimport * as TogglePrimitive from '@radix-ui/react-toggle';\nimport { cva, type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst toggleVariants = cva(\n 'pr-twp tw-inline-flex tw-items-center tw-justify-center tw-rounded-md tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-colors hover:tw-bg-muted hover:tw-text-muted-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50 data-[state=on]:tw-bg-accent data-[state=on]:tw-text-accent-foreground',\n {\n variants: {\n variant: {\n default: 'tw-bg-transparent',\n outline:\n 'tw-border tw-border-input tw-bg-transparent hover:tw-bg-accent hover:tw-text-accent-foreground',\n },\n size: {\n default: 'tw-h-10 tw-px-3',\n sm: 'tw-h-9 tw-px-2.5',\n lg: 'tw-h-11 tw-px-5',\n },\n },\n defaultVariants: {\n variant: 'default',\n size: 'default',\n },\n },\n);\n\nconst Toggle = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef & VariantProps\n>(({ className, variant, size, ...props }, ref) => (\n \n));\n\nToggle.displayName = TogglePrimitive.Root.displayName;\n\nexport { Toggle, toggleVariants };\n","import React from 'react';\nimport * as ToggleGroupPrimitive from '@radix-ui/react-toggle-group';\nimport { type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { toggleVariants } from '@/components/shadcn-ui/toggle';\n\nconst ToggleGroupContext = React.createContext>({\n size: 'default',\n variant: 'default',\n});\n\nconst ToggleGroup = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef &\n VariantProps\n>(({ className, variant, size, children, ...props }, ref) => (\n \n \n {children}\n \n \n));\n\nToggleGroup.displayName = ToggleGroupPrimitive.Root.displayName;\n\nconst ToggleGroupItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef &\n VariantProps\n>(({ className, children, variant, size, ...props }, ref) => {\n const context = React.useContext(ToggleGroupContext);\n\n return (\n \n {children}\n \n );\n});\n\nToggleGroupItem.displayName = ToggleGroupPrimitive.Item.displayName;\n\nexport { ToggleGroup, ToggleGroupItem };\n","import { ColumnDef, SortDirection } from '@/components/advanced/data-table/data-table.component';\nimport { Button } from '@/components/shadcn-ui/button';\nimport { ToggleGroup, ToggleGroupItem } from '@/components/shadcn-ui/toggle-group';\nimport {\n ArrowDownIcon,\n ArrowUpDownIcon,\n ArrowUpIcon,\n CircleCheckIcon,\n CircleHelpIcon,\n CircleXIcon,\n} from 'lucide-react';\nimport { ReactNode } from 'react';\nimport { InventoryTableData, Status } from './inventory-utils';\n\n/**\n * Gets an icon that indicates the current sorting direction based on the provided input\n *\n * @param sortDirection Sorting direction. Can be ascending ('asc'), descending ('desc') or false (\n * i.e. not sorted)\n * @returns The appropriate sorting icon for the provided sorting direction\n */\nconst getSortingIcon = (sortDirection: false | SortDirection): ReactNode => {\n if (sortDirection === 'asc') {\n return ;\n }\n if (sortDirection === 'desc') {\n return ;\n }\n return ;\n};\n\n/**\n * Function that creates the item column for inventories\n *\n * @param itemLabel Localized label for the item column (e.g. 'Character', 'Repeated Word', etc.)\n * @returns Column that shows the inventory items. Should be used with the DataTable component\n */\nexport const inventoryItemColumn = (itemLabel: string): ColumnDef => {\n return {\n accessorKey: 'item',\n accessorFn: (row: InventoryTableData) => row.items[0],\n header: ({ column }) => (\n \n ),\n };\n};\n\n/**\n * Function that creates the additional item columns for inventories\n *\n * @param additionalItemLabel Localized label for the additional item column (e.g. 'Preceding\n * Marker')\n * @param additionalItemIndex Index that locates the desired item in the items array of the\n * inventory\n * @returns Column that shows additional inventory items. Should be used with the DataTable\n * component\n */\nexport const inventoryAdditionalItemColumn = (\n additionalItemLabel: string,\n additionalItemIndex: number,\n): ColumnDef => {\n return {\n accessorKey: `item${additionalItemIndex}`,\n accessorFn: (row: InventoryTableData) => row.items[additionalItemIndex],\n header: ({ column }) => (\n \n ),\n };\n};\n\n/**\n * Function that creates the count column for inventories. Should be used with the DataTable\n * component.\n *\n * @param itemLabel Localized label for the count column\n * @returns Column that shows the number of occurrences of the related inventory items\n */\nexport const inventoryCountColumn = (countLabel: string): ColumnDef => {\n return {\n accessorKey: 'count',\n header: ({ column }) => (\n
    \n \n
    \n ),\n cell: ({ row }) =>
    {row.getValue('count')}
    ,\n };\n};\n\n/**\n * Function that updates project settings when status for item(s) changes\n *\n * @param changedItems Array of items for which the status is being updated\n * @param newStatus The status that the items are being given\n * @param approvedItems Array of currently approved items\n * @param onApprovedItemsChange Callback function that stores the updated list of approved items\n * @param unapprovedItems Array of currently unapproved items\n * @param onUnapprovedItemsChange Callback function that stores the updated list of unapproved items\n */\nconst statusChangeHandler = (\n changedItems: string[],\n newStatus: Status,\n approvedItems: string[],\n onApprovedItemsChange: (items: string[]) => void,\n unapprovedItems: string[],\n onUnapprovedItemsChange: (items: string[]) => void,\n) => {\n let newApprovedItems: string[] = [...approvedItems];\n changedItems.forEach((item) => {\n if (newStatus === 'approved') {\n if (!newApprovedItems.includes(item)) {\n newApprovedItems.push(item);\n }\n } else {\n newApprovedItems = newApprovedItems.filter((validItem) => validItem !== item);\n }\n });\n onApprovedItemsChange(newApprovedItems);\n\n let newUnapprovedItems: string[] = [...unapprovedItems];\n changedItems.forEach((item) => {\n if (newStatus === 'unapproved') {\n if (!newUnapprovedItems.includes(item)) {\n newUnapprovedItems.push(item);\n }\n } else {\n newUnapprovedItems = newUnapprovedItems.filter((unapprovedItem) => unapprovedItem !== item);\n }\n });\n onUnapprovedItemsChange(newUnapprovedItems);\n};\n\n/**\n * Function that creates the status column for inventories. Should be used with the DataTable\n * component.\n *\n * @param statusLabel Localized label for the status column\n * @param approvedItems Array of approved items, typically as defined in `Settings.xml`\n * @param onApprovedItemsChange Callback function that stores the updated list of approved items\n * @param unapprovedItems Array of unapproved items, typically as defined in `Settings.xml`\n * @param onUnapprovedItemsChange Callback function that stores the updated list of unapproved items\n * @returns Column that shows the status buttons for the related inventory item. The button for the\n * current status of the item is selected\n */\nexport const inventoryStatusColumn = (\n statusLabel: string,\n approvedItems: string[],\n onApprovedItemsChange: (items: string[]) => void,\n unapprovedItems: string[],\n onUnapprovedItemsChange: (items: string[]) => void,\n): ColumnDef => {\n return {\n accessorKey: 'status',\n header: ({ column }) => {\n return (\n
    \n \n
    \n );\n },\n cell: ({ row }) => {\n const status: Status = row.getValue('status');\n const item: string = row.getValue('item');\n return (\n \n \n statusChangeHandler(\n [item],\n 'approved',\n approvedItems,\n onApprovedItemsChange,\n unapprovedItems,\n onUnapprovedItemsChange,\n )\n }\n value=\"approved\"\n >\n \n \n \n statusChangeHandler(\n [item],\n 'unapproved',\n approvedItems,\n onApprovedItemsChange,\n unapprovedItems,\n onUnapprovedItemsChange,\n )\n }\n value=\"unapproved\"\n >\n \n \n \n statusChangeHandler(\n [item],\n 'unknown',\n approvedItems,\n onApprovedItemsChange,\n unapprovedItems,\n onUnapprovedItemsChange,\n )\n }\n value=\"unknown\"\n >\n \n \n \n );\n },\n };\n};\n","import DataTable, {\n ColumnDef,\n RowContents,\n RowSelectionState,\n TableContents,\n} from '@/components/advanced/data-table/data-table.component';\nimport OccurrencesTable from '@/components/advanced/inventory/occurrences-table.component';\nimport Checkbox from '@/components/shadcn-ui/checkbox';\nimport { Input } from '@/components/shadcn-ui/input';\nimport { Label } from '@/components/shadcn-ui/label';\nimport {\n Select,\n SelectContent,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\nimport {\n deepEqual,\n LocalizedStringValue,\n ScriptureReference,\n substring,\n} from 'platform-bible-utils';\nimport { useEffect, useMemo, useState } from 'react';\nimport {\n getBookNumFromId,\n getLinesFromUSFM,\n getNumberFromUSFM,\n getStatusForItem,\n InventoryItemOccurrence,\n InventoryTableData,\n Status,\n} from './inventory-utils';\nimport { inventoryAdditionalItemColumn } from './inventory-columns';\n\n/**\n * Object containing all keys used for localization in this component. If you're using this\n * component in an extension, you can pass it into the useLocalizedStrings hook to easily obtain the\n * localized strings and pass them into the localizedStrings prop of this component\n */\nexport const INVENTORY_STRING_KEYS = Object.freeze([\n '%webView_inventory_all%',\n '%webView_inventory_approved%',\n '%webView_inventory_unapproved%',\n '%webView_inventory_unknown%',\n '%webView_inventory_scope_currentBook%',\n '%webView_inventory_scope_chapter%',\n '%webView_inventory_scope_verse%',\n '%webView_inventory_filter_text%',\n '%webView_inventory_show_additional_items%',\n '%webView_inventory_occurrences_table_header_reference%',\n '%webView_inventory_occurrences_table_header_occurrence%',\n] as const);\n\nexport type InventoryLocalizedStrings = {\n [localizedInventoryKey in (typeof INVENTORY_STRING_KEYS)[number]]?: LocalizedStringValue;\n};\n\n/** Scope of scripture that the inventory can operate on */\nexport type Scope = 'book' | 'chapter' | 'verse';\n\n/** Status values that the status filter can select from */\ntype StatusFilter = Status | 'all';\n\n/** Text labels for the inventory columns and the control components of additional inventory items */\ntype AdditionalItemsLabels = {\n checkboxText?: string;\n tableHeaders?: string[];\n};\n\n/**\n * Filters data that is shown in the DataTable section of the Inventory\n *\n * @param itemData All inventory items and their related information\n * @param statusFilter Allows filtering by status (i.e. show all items, or only items that are\n * 'approved', 'unapproved' or 'unknown')\n * @param textFilter Allows filtering by text. All items that include the filter text will be\n * selected.\n * @returns Array of items and their related information that are matched by the specified filters\n */\nconst filterItemData = (\n itemData: InventoryTableData[],\n statusFilter: StatusFilter,\n textFilter: string,\n): InventoryTableData[] => {\n let filteredItemData: InventoryTableData[] = itemData;\n\n if (statusFilter !== 'all') {\n filteredItemData = filteredItemData.filter(\n (item) =>\n (statusFilter === 'approved' && item.status === 'approved') ||\n (statusFilter === 'unapproved' && item.status === 'unapproved') ||\n (statusFilter === 'unknown' && item.status === 'unknown'),\n );\n }\n\n if (textFilter !== '')\n filteredItemData = filteredItemData.filter((item) => item.items[0].includes(textFilter));\n\n return filteredItemData;\n};\n\n/**\n * Turns array of strings into array of inventory items, along with their count and status\n *\n * @param text The source scripture text that is searched for inventory items\n * @param scriptureRef The scripture reference that the application is currently set to\n * @param approvedItems Array of approved items, typically as defined in `Settings.xml`\n * @param unapprovedItems Array of unapproved items, typically as defined in `Settings.xml`\n * @param itemRegex Regular expression that describes what items this Inventory should extract from\n * the provided scripture text\n * @returns Array of inventory items, along with their count and status\n */\nconst createTableData = (\n text: string | undefined,\n scriptureRef: ScriptureReference,\n approvedItems: string[],\n unapprovedItems: string[],\n itemRegex: RegExp,\n): InventoryTableData[] => {\n if (!text) return [];\n\n const tableData: InventoryTableData[] = [];\n\n let currentBook: number | undefined = scriptureRef.bookNum;\n let currentChapter: number | undefined = scriptureRef.chapterNum;\n let currentVerse: number | undefined = scriptureRef.verseNum;\n\n const lines = getLinesFromUSFM(text);\n\n lines.forEach((line: string) => {\n if (line.startsWith('\\\\id')) {\n currentBook = getBookNumFromId(line);\n currentChapter = 0;\n currentVerse = 0;\n }\n if (line.startsWith('\\\\c')) {\n currentChapter = getNumberFromUSFM(line);\n currentVerse = 0;\n }\n if (line.startsWith('\\\\v')) {\n currentVerse = getNumberFromUSFM(line);\n if (currentChapter === 0) {\n currentChapter = scriptureRef.chapterNum;\n }\n }\n\n let match: RegExpExecArray | undefined = itemRegex.exec(line) ?? undefined;\n while (match) {\n const items: string[] = [];\n match.forEach((item) => items.push(item));\n const itemIndex = match.index;\n const existingItem = tableData.find((tableEntry) => deepEqual(tableEntry.items, items));\n const newReference: InventoryItemOccurrence = {\n reference: {\n bookNum: currentBook !== undefined ? currentBook : -1,\n chapterNum: currentChapter !== undefined ? currentChapter : -1,\n verseNum: currentVerse !== undefined ? currentVerse : -1,\n },\n text: substring(line, Math.max(0, itemIndex - 25), Math.min(itemIndex + 25, line.length)),\n };\n if (existingItem) {\n existingItem.count += 1;\n existingItem.occurrences.push(newReference);\n } else {\n const newItem: InventoryTableData = {\n items,\n count: 1,\n status: getStatusForItem(items[0], approvedItems, unapprovedItems),\n occurrences: [newReference],\n };\n tableData.push(newItem);\n }\n\n match = itemRegex.exec(line) ?? undefined;\n }\n });\n\n return tableData;\n};\n\n/**\n * Gets the localized value for the provided key\n *\n * @param strings Object containing localized string\n * @param key Key for a localized string\n * @returns The localized value for the provided key, if available. Returns the key if no localized\n * value is available\n */\nconst localizeString = (\n strings: InventoryLocalizedStrings,\n key: keyof InventoryLocalizedStrings,\n) => {\n return strings[key] ?? key;\n};\n\n/** Props for the Inventory component */\ntype InventoryProps = {\n /** The scripture reference that the application is currently set to */\n scriptureReference: ScriptureReference;\n /** Callback function that is executed when the scripture reference is changed */\n setScriptureReference: (scriptureReference: ScriptureReference) => void;\n /**\n * Object with all localized strings that the Inventory needs to work well across multiple\n * languages. When using this component with Platform.Bible, you can import\n * `INVENTORY_STRING_KEYS` from this library, pass it in to the Platform's localization hook, and\n * pass the localized keys that are returned by the hook into this prop.\n */\n localizedStrings: InventoryLocalizedStrings;\n /**\n * The logic that finds the desired items in the source text. This can either be a Regular\n * expression that captures one or multiple items (preferred), or a custom function that builds\n * and return an InventoryDataTable[] manually. Note: In case the logic captures more than one\n * item (i.e. InventoryTableData.items has a length greater than 1), you must provide text labels\n * for the related columns and control elements to show by setting the `additionalItemsLabels`\n * prop\n */\n extractItems:\n | RegExp\n | ((\n text: string | undefined,\n scriptureRef: ScriptureReference,\n approvedItems: string[],\n unapprovedItems: string[],\n ) => InventoryTableData[]);\n /**\n * Text labels for control elements and additional column headers in case your Inventory has more\n * than one item to show (e.g. The 'Preceding Marker' in the Markers Inventory)\n */\n additionalItemsLabels?: AdditionalItemsLabels;\n /** Array of approved items, typically as defined in `Settings.xml` */\n approvedItems: string[];\n /** Array of unapproved items, typically as defined in `Settings.xml` */\n unapprovedItems: string[];\n /** The source scripture text that is searched for in inventory items */\n text: string | undefined;\n /** Scope of scripture that the inventory will operate on */\n scope: Scope;\n /** Callback function that is executed when the scope is changed from the Inventory */\n onScopeChange: (scope: Scope) => void;\n /**\n * Column definitions for the Inventory data table. The most commonly used column definitions are\n * pre-configured for your convenience and can be imported (e.g. inventoryItemColumn,\n * inventoryAdditionalItemColumn inventoryCountColumn, and inventoryStatusColumn). If you need any\n * other columns you can add these yourself\n */\n columns: ColumnDef[];\n};\n\n/** Inventory component that is used to view and control the status of provided project settings */\nexport default function Inventory({\n scriptureReference,\n setScriptureReference,\n localizedStrings,\n extractItems,\n additionalItemsLabels,\n approvedItems,\n unapprovedItems,\n text,\n scope,\n onScopeChange,\n columns,\n}: InventoryProps) {\n const allItemsText = localizeString(localizedStrings, '%webView_inventory_all%');\n const approvedItemsText = localizeString(localizedStrings, '%webView_inventory_approved%');\n const unapprovedItemsText = localizeString(localizedStrings, '%webView_inventory_unapproved%');\n const unknownItemsText = localizeString(localizedStrings, '%webView_inventory_unknown%');\n const scopeBookText = localizeString(localizedStrings, '%webView_inventory_scope_currentBook%');\n const scopeChapterText = localizeString(localizedStrings, '%webView_inventory_scope_chapter%');\n const scopeVerseText = localizeString(localizedStrings, '%webView_inventory_scope_verse%');\n const filterText = localizeString(localizedStrings, '%webView_inventory_filter_text%');\n const showAdditionalItemsText = localizeString(\n localizedStrings,\n '%webView_inventory_show_additional_items%',\n );\n\n const [showAdditionalItems, setShowAdditionalItems] = useState(false);\n const [statusFilter, setStatusFilter] = useState('all');\n const [textFilter, setTextFilter] = useState('');\n const [selectedItem, setSelectedItem] = useState([]);\n\n const tableData: InventoryTableData[] = useMemo(() => {\n if (!text) return [];\n if (extractItems instanceof RegExp)\n return createTableData(\n text,\n scriptureReference,\n approvedItems,\n unapprovedItems,\n extractItems,\n );\n return extractItems(text, scriptureReference, approvedItems, unapprovedItems);\n }, [text, extractItems, scriptureReference, approvedItems, unapprovedItems]);\n\n const reducedTableData: InventoryTableData[] = useMemo(() => {\n if (showAdditionalItems) return tableData;\n\n const newTableData: InventoryTableData[] = [];\n\n tableData.forEach((tableEntry) => {\n const firstItem = tableEntry.items[0];\n\n const existingEntry = newTableData.find(\n (newTableEntry) => newTableEntry.items[0] === firstItem,\n );\n\n if (existingEntry) {\n existingEntry.count += tableEntry.count;\n existingEntry.occurrences = existingEntry.occurrences.concat(tableEntry.occurrences);\n } else {\n newTableData.push({\n items: [firstItem],\n count: tableEntry.count,\n occurrences: tableEntry.occurrences,\n status: tableEntry.status,\n });\n }\n });\n\n return newTableData;\n }, [showAdditionalItems, tableData]);\n\n const filteredTableData: InventoryTableData[] = useMemo(() => {\n return filterItemData(reducedTableData, statusFilter, textFilter);\n }, [reducedTableData, statusFilter, textFilter]);\n\n const allColumns: ColumnDef[] = useMemo(() => {\n if (!showAdditionalItems) return columns;\n\n const numberOfAdditionalItems = additionalItemsLabels?.tableHeaders?.length;\n if (!numberOfAdditionalItems) return columns;\n\n const additionalColumns: ColumnDef[] = [];\n\n for (let index = 0; index < numberOfAdditionalItems; index++) {\n additionalColumns.push(\n inventoryAdditionalItemColumn(\n additionalItemsLabels?.tableHeaders?.[index] || 'Additional Item',\n index + 1,\n ),\n );\n }\n\n return [...additionalColumns, ...columns];\n }, [additionalItemsLabels?.tableHeaders, columns, showAdditionalItems]);\n\n useEffect(() => {\n setSelectedItem([]);\n }, [filteredTableData]);\n\n const rowClickHandler = (\n row: RowContents,\n table: TableContents,\n ) => {\n table.setRowSelection(() => {\n const newSelection: RowSelectionState = {};\n newSelection[row.index] = true;\n return newSelection;\n });\n\n setSelectedItem(row.original.items);\n };\n\n const handleScopeChange = (value: string) => {\n if (value === 'book' || value === 'chapter' || value === 'verse') {\n onScopeChange(value);\n } else {\n throw new Error(`Invalid scope value: ${value}`);\n }\n };\n\n const handleStatusFilterChange = (value: string) => {\n if (value === 'all' || value === 'approved' || value === 'unapproved' || value === 'unknown') {\n setStatusFilter(value);\n } else {\n throw new Error(`Invalid status filter value: ${value}`);\n }\n };\n\n const occurrenceData: InventoryItemOccurrence[] = useMemo(() => {\n if (reducedTableData.length === 0 || selectedItem.length === 0) return [];\n const occurrence = reducedTableData.filter((tableEntry: InventoryTableData) => {\n return deepEqual(\n showAdditionalItems ? tableEntry.items : [tableEntry.items[0]],\n selectedItem,\n );\n });\n if (occurrence.length > 1) throw new Error('Selected item is not unique');\n return occurrence[0].occurrences;\n }, [selectedItem, showAdditionalItems, reducedTableData]);\n\n return (\n
    \n
    \n handleStatusFilterChange(value)}\n defaultValue={statusFilter}\n >\n \n \n \n \n {allItemsText}\n {approvedItemsText}\n {unapprovedItemsText}\n {unknownItemsText}\n \n \n \n {\n setTextFilter(event.target.value);\n }}\n />\n {additionalItemsLabels && (\n
    \n {\n setSelectedItem([]);\n setShowAdditionalItems(checked);\n }}\n />\n \n
    \n )}\n
    \n
    \n \n
    \n {occurrenceData.length > 0 && (\n
    \n \n
    \n )}\n
    \n );\n}\n","import { Input } from '@/components/shadcn-ui/input';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { useState } from 'react';\n\n/** Props for the SearchBar component. */\nexport type SearchBarProps = {\n /** Additional css classes to help with unique styling of the search bar */\n className?: string;\n /**\n * Callback fired to handle the search query when button pressed\n *\n * @param searchQuery\n */\n onSearch: (searchQuery: string) => void;\n\n /** Optional string that appears in the search bar without a search string */\n placeholder?: string;\n\n /** Optional boolean to set the input base to full width */\n isFullWidth?: boolean;\n};\n\nexport default function SearchBar({\n className,\n onSearch,\n placeholder,\n isFullWidth,\n}: SearchBarProps) {\n const [searchQuery, setSearchQuery] = useState('');\n\n const handleInputChange = (searchString: string) => {\n setSearchQuery(searchString);\n onSearch(searchString);\n };\n\n return (\n handleInputChange(e.target.value)}\n />\n );\n}\n","// adapted from: https://github.com/shadcn-ui/ui/discussions/752\n\n'use client';\n\nimport { TabsContentProps, TabsListProps, TabsTriggerProps } from '@/components/shadcn-ui/tabs';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport * as TabsPrimitive from '@radix-ui/react-tabs';\nimport React from 'react';\n\nexport type VerticalTabsProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport type LeftTabsTriggerProps = TabsTriggerProps & {\n value: string;\n ref?: React.Ref;\n};\n\nexport const VerticalTabs = React.forwardRef<\n React.ElementRef,\n VerticalTabsProps\n>(({ className, ...props }, ref) => (\n \n));\n\nVerticalTabs.displayName = TabsPrimitive.List.displayName;\n\nexport const VerticalTabsList = React.forwardRef<\n React.ElementRef,\n TabsListProps\n>(({ className, ...props }, ref) => (\n \n));\nVerticalTabsList.displayName = TabsPrimitive.List.displayName;\n\nexport const VerticalTabsTrigger = React.forwardRef<\n React.ElementRef,\n LeftTabsTriggerProps\n>(({ className, ...props }, ref) => (\n \n));\n\nexport const VerticalTabsContent = React.forwardRef<\n React.ElementRef,\n TabsContentProps\n>(({ className, ...props }, ref) => (\n \n));\nVerticalTabsContent.displayName = TabsPrimitive.Content.displayName;\n","import SearchBar from '@/components/basics/search-bar.component';\nimport {\n VerticalTabs,\n VerticalTabsContent,\n VerticalTabsList,\n VerticalTabsTrigger,\n} from '@/components/basics/tabs-vertical';\nimport { ReactNode } from 'react';\n\nexport type TabKeyValueContent = {\n key: string;\n value: string;\n content: ReactNode;\n};\n\nexport type TabNavigationContentSearchProps = {\n /** List of values and keys for each tab this component should provide */\n tabList: TabKeyValueContent[];\n\n /** Handler to run when the value of the search bar changes */\n onSearch: (searchQuery: string) => void;\n\n /** Optional placeholder for the search bar */\n searchPlaceholder?: string;\n\n /** Optional title to include in the header */\n headerTitle?: string;\n\n /** Optional flag to make the search bar appear full width */\n isSearchBarFullWidth?: boolean;\n\n /** Text direction ltr or rtl */\n direction?: 'ltr' | 'rtl';\n};\n\nexport default function TabNavigationContentSearch({\n tabList,\n onSearch,\n searchPlaceholder,\n headerTitle,\n isSearchBarFullWidth = false,\n direction = 'ltr',\n}: TabNavigationContentSearchProps) {\n return (\n
    \n
    \n {headerTitle ?

    {headerTitle}

    : ''}\n \n
    \n \n \n {tabList.map((tab) => (\n \n {tab.value}\n \n ))}\n \n {tabList.map((tab) => (\n \n {tab.content}\n \n ))}\n \n
    \n );\n}\n","import React from 'react';\nimport * as SeparatorPrimitive from '@radix-ui/react-separator';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Separator = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, orientation = 'horizontal', decorative = true, ...props }, ref) => (\n \n));\nSeparator.displayName = SeparatorPrimitive.Root.displayName;\n\nexport { Separator };\n","import React from 'react';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nfunction Skeleton({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\n\nexport { Skeleton };\n","import React from 'react';\nimport * as TooltipPrimitive from '@radix-ui/react-tooltip';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst TooltipProvider = TooltipPrimitive.Provider;\n\nconst Tooltip = TooltipPrimitive.Root;\n\nconst TooltipTrigger = TooltipPrimitive.Trigger;\n\nconst TooltipContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, sideOffset = 4, ...props }, ref) => (\n \n));\nTooltipContent.displayName = TooltipPrimitive.Content.displayName;\n\nexport { Tooltip, TooltipTrigger, TooltipContent, TooltipProvider };\n","import React from 'react';\nimport { Slot } from '@radix-ui/react-slot';\nimport { VariantProps, cva } from 'class-variance-authority';\nimport { PanelLeft } from 'lucide-react';\n\nimport { Button } from '@/components/shadcn-ui/button';\nimport { Input } from '@/components/shadcn-ui/input';\nimport { Separator } from '@/components/shadcn-ui/separator';\nimport { Skeleton } from '@/components/shadcn-ui/skeleton';\nimport {\n Tooltip,\n TooltipContent,\n TooltipProvider,\n TooltipTrigger,\n} from '@/components/shadcn-ui/tooltip';\nimport { cn } from '@/utils/shadcn-ui.util';\n\n/**\n * Changes from the original code from Shadcn- Removed uses of useIsMobile, Sheet, and SheetContent.\n * Also removed the parts setting COOKIES.\n */\n\nconst SIDEBAR_WIDTH = '16rem';\nconst SIDEBAR_WIDTH_ICON = '3rem';\n// Commented this out pending a discussion with UX about keyboard shortcuts\n// const SIDEBAR_KEYBOARD_SHORTCUT = 'b';\n\ntype SidebarContextProps = {\n state: 'expanded' | 'collapsed';\n open: boolean;\n setOpen: (open: boolean) => void;\n toggleSidebar: () => void;\n};\n\nconst SidebarContext = React.createContext(undefined);\n\nfunction useSidebar() {\n const context = React.useContext(SidebarContext);\n if (!context) {\n throw new Error('useSidebar must be used within a SidebarProvider.');\n }\n\n return context;\n}\n\nconst SidebarProvider = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & {\n defaultOpen?: boolean;\n open?: boolean;\n onOpenChange?: (open: boolean) => void;\n }\n>(\n (\n {\n defaultOpen = true,\n open: openProp,\n onOpenChange: setOpenProp,\n className,\n style,\n children,\n ...props\n },\n ref,\n ) => {\n // This is the internal state of the sidebar.\n // We use openProp and setOpenProp for control from outside the component.\n const [_open, _setOpen] = React.useState(defaultOpen);\n const isOpen = openProp ?? _open;\n const setOpen = React.useCallback(\n (value: boolean | ((value: boolean) => boolean)) => {\n const openState = typeof value === 'function' ? value(isOpen) : value;\n if (setOpenProp) {\n setOpenProp(openState);\n } else {\n _setOpen(openState);\n }\n },\n [setOpenProp, isOpen],\n );\n\n // Helper to toggle the sidebar.\n const toggleSidebar = React.useCallback(() => {\n return setOpen((open) => !open);\n }, [setOpen]);\n\n // Commented this out pending a discussion with UX about keyboard shortcuts\n // Adds a keyboard shortcut to toggle the sidebar.\n // React.useEffect(() => {\n // const handleKeyDown = (event: KeyboardEvent) => {\n // if (event.key === SIDEBAR_KEYBOARD_SHORTCUT && (event.metaKey || event.ctrlKey)) {\n // event.preventDefault();\n // toggleSidebar();\n // }\n // };\n\n // window.addEventListener('keydown', handleKeyDown);\n // return () => window.removeEventListener('keydown', handleKeyDown);\n // }, [toggleSidebar]);\n\n // We add a state so that we can do data-state=\"expanded\" or \"collapsed\".\n // This makes it easier to style the sidebar with Tailwind classes.\n const state = isOpen ? 'expanded' : 'collapsed';\n\n const contextValue = React.useMemo(\n () => ({\n state,\n open: isOpen,\n setOpen,\n toggleSidebar,\n }),\n [state, isOpen, setOpen, toggleSidebar],\n );\n\n return (\n \n \n \n {children}\n
    \n \n \n );\n },\n);\nSidebarProvider.displayName = 'SidebarProvider';\n\nconst Sidebar = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & {\n side?: 'left' | 'right';\n variant?: 'sidebar' | 'floating' | 'inset';\n collapsible?: 'offcanvas' | 'icon' | 'none';\n }\n>(\n (\n {\n side = 'left',\n variant = 'sidebar',\n collapsible = 'offcanvas',\n className,\n children,\n ...props\n },\n ref,\n ) => {\n const { state } = useSidebar();\n\n if (collapsible === 'none') {\n return (\n \n {children}\n
    \n );\n }\n\n return (\n \n {/* This is what handles the sidebar gap on desktop */}\n \n \n \n {children}\n
    \n
    \n
    \n );\n },\n);\nSidebar.displayName = 'Sidebar';\n\nconst SidebarTrigger = React.forwardRef<\n React.ElementRef,\n React.ComponentProps\n>(({ className, onClick, ...props }, ref) => {\n const { toggleSidebar } = useSidebar();\n\n return (\n {\n onClick?.(event);\n toggleSidebar();\n }}\n {...props}\n >\n \n Toggle Sidebar\n \n );\n});\nSidebarTrigger.displayName = 'SidebarTrigger';\n\nconst SidebarRail = React.forwardRef>(\n ({ className, ...props }, ref) => {\n const { toggleSidebar } = useSidebar();\n\n return (\n \n );\n },\n);\nSidebarRail.displayName = 'SidebarRail';\n\nconst SidebarInset = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarInset.displayName = 'SidebarInset';\n\nconst SidebarInput = React.forwardRef<\n React.ElementRef,\n React.ComponentProps\n>(({ className, ...props }, ref) => {\n return (\n \n );\n});\nSidebarInput.displayName = 'SidebarInput';\n\nconst SidebarHeader = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarHeader.displayName = 'SidebarHeader';\n\nconst SidebarFooter = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarFooter.displayName = 'SidebarFooter';\n\nconst SidebarSeparator = React.forwardRef<\n React.ElementRef,\n React.ComponentProps\n>(({ className, ...props }, ref) => {\n return (\n \n );\n});\nSidebarSeparator.displayName = 'SidebarSeparator';\n\nconst SidebarContent = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarContent.displayName = 'SidebarContent';\n\nconst SidebarGroup = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarGroup.displayName = 'SidebarGroup';\n\nconst SidebarGroupLabel = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & { asChild?: boolean }\n>(({ className, asChild = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'div';\n\n return (\n svg]:tw-size-4 [&>svg]:tw-shrink-0',\n 'group-data-[collapsible=icon]:tw--mt-8 group-data-[collapsible=icon]:tw-opacity-0',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarGroupLabel.displayName = 'SidebarGroupLabel';\n\nconst SidebarGroupAction = React.forwardRef<\n HTMLButtonElement,\n React.ComponentProps<'button'> & { asChild?: boolean }\n>(({ className, asChild = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'button';\n\n return (\n svg]:tw-size-4 [&>svg]:tw-shrink-0',\n // Increases the hit area of the button on mobile.\n 'after:tw-absolute after:tw--inset-2 after:md:tw-hidden',\n 'group-data-[collapsible=icon]:tw-hidden',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarGroupAction.displayName = 'SidebarGroupAction';\n\nconst SidebarGroupContent = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarGroupContent.displayName = 'SidebarGroupContent';\n\nconst SidebarMenu = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenu.displayName = 'SidebarMenu';\n\nconst SidebarMenuItem = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenuItem.displayName = 'SidebarMenuItem';\n\nconst sidebarMenuButtonVariants = cva(\n // Removed data-[active=true]:tw-bg-sidebar-accent\n 'tw-peer/menu-button tw-flex tw-w-full tw-items-center tw-gap-2 tw-overflow-hidden tw-rounded-md tw-p-2 tw-text-left tw-text-sm tw-outline-none tw-ring-sidebar-ring tw-transition-[width,height,padding] hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground focus-visible:tw-ring-2 active:tw-bg-sidebar-accent active:tw-text-sidebar-accent-foreground disabled:tw-pointer-events-none disabled:tw-opacity-50 tw-group-has-[[data-sidebar=menu-action]]/menu-item:pr-8 aria-disabled:tw-pointer-events-none aria-disabled:tw-opacity-50 data-[active=true]:tw-font-medium data-[active=true]:tw-text-sidebar-accent-foreground data-[state=open]:hover:tw-bg-sidebar-accent data-[state=open]:hover:tw-text-sidebar-accent-foreground group-data-[collapsible=icon]:tw-!size-8 group-data-[collapsible=icon]:tw-!p-2 [&>span:last-child]:tw-truncate [&>svg]:tw-size-4 [&>svg]:tw-shrink-0',\n {\n variants: {\n variant: {\n default: 'hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground',\n outline:\n 'tw-bg-background tw-shadow-[0_0_0_1px_hsl(var(--sidebar-border))] hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground hover:tw-shadow-[0_0_0_1px_hsl(var(--sidebar-accent))]',\n },\n size: {\n default: 'tw-h-8 tw-text-sm',\n sm: 'tw-h-7 tw-text-xs',\n lg: 'tw-h-12 tw-text-sm group-data-[collapsible=icon]:tw-!p-0',\n },\n },\n defaultVariants: {\n variant: 'default',\n size: 'default',\n },\n },\n);\n\nconst SidebarMenuButton = React.forwardRef<\n HTMLButtonElement,\n React.ComponentProps<'button'> & {\n asChild?: boolean;\n isActive?: boolean;\n tooltip?: string | React.ComponentProps;\n } & VariantProps\n>(\n (\n {\n asChild = false,\n isActive = false,\n variant = 'default',\n size = 'default',\n tooltip,\n className,\n ...props\n },\n ref,\n ) => {\n const Comp = asChild ? Slot : 'button';\n const { state } = useSidebar();\n\n const button = (\n \n );\n\n if (!tooltip) {\n return button;\n }\n\n if (typeof tooltip === 'string') {\n // eslint-disable-next-line no-param-reassign\n tooltip = {\n children: tooltip,\n };\n }\n\n return (\n \n {button}\n \n );\n },\n);\nSidebarMenuButton.displayName = 'SidebarMenuButton';\n\nconst SidebarMenuAction = React.forwardRef<\n HTMLButtonElement,\n React.ComponentProps<'button'> & {\n asChild?: boolean;\n showOnHover?: boolean;\n }\n>(({ className, asChild = false, showOnHover = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'button';\n\n return (\n svg]:tw-size-4 [&>svg]:tw-shrink-0',\n // Increases the hit area of the button on mobile.\n 'after:tw-absolute after:tw--inset-2 after:md:tw-hidden',\n 'tw-peer-data-[size=sm]/menu-button:top-1',\n 'tw-peer-data-[size=default]/menu-button:top-1.5',\n 'tw-peer-data-[size=lg]/menu-button:top-2.5',\n 'group-data-[collapsible=icon]:tw-hidden',\n showOnHover &&\n 'tw-group-focus-within/menu-item:opacity-100 tw-group-hover/menu-item:opacity-100 tw-peer-data-[active=true]/menu-button:text-sidebar-accent-foreground data-[state=open]:tw-opacity-100 md:tw-opacity-0',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarMenuAction.displayName = 'SidebarMenuAction';\n\nconst SidebarMenuBadge = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenuBadge.displayName = 'SidebarMenuBadge';\n\nconst SidebarMenuSkeleton = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & {\n showIcon?: boolean;\n }\n>(({ className, showIcon = false, ...props }, ref) => {\n // Random width between 50 to 90%.\n const width = React.useMemo(() => {\n return `${Math.floor(Math.random() * 40) + 50}%`;\n }, []);\n\n return (\n \n {showIcon && (\n \n )}\n \n
    \n );\n});\nSidebarMenuSkeleton.displayName = 'SidebarMenuSkeleton';\n\nconst SidebarMenuSub = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenuSub.displayName = 'SidebarMenuSub';\n\nconst SidebarMenuSubItem = React.forwardRef>(\n ({ ...props }, ref) =>
  • ,\n);\nSidebarMenuSubItem.displayName = 'SidebarMenuSubItem';\n\nconst SidebarMenuSubButton = React.forwardRef<\n HTMLAnchorElement,\n React.ComponentProps<'a'> & {\n asChild?: boolean;\n size?: 'sm' | 'md';\n isActive?: boolean;\n }\n>(({ asChild = false, size = 'md', isActive, className, ...props }, ref) => {\n const Comp = asChild ? Slot : 'a';\n\n return (\n span:last-child]:tw-truncate [&>svg]:tw-size-4 [&>svg]:tw-shrink-0 [&>svg]:tw-text-sidebar-accent-foreground',\n 'data-[active=true]:tw-bg-sidebar-accent data-[active=true]:tw-text-sidebar-accent-foreground',\n size === 'sm' && 'tw-text-xs',\n size === 'md' && 'tw-text-sm',\n 'group-data-[collapsible=icon]:tw-hidden',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarMenuSubButton.displayName = 'SidebarMenuSubButton';\n\nexport {\n Sidebar,\n SidebarContent,\n SidebarFooter,\n SidebarGroup,\n SidebarGroupAction,\n SidebarGroupContent,\n SidebarGroupLabel,\n SidebarHeader,\n SidebarInput,\n SidebarInset,\n SidebarMenu,\n SidebarMenuAction,\n SidebarMenuBadge,\n SidebarMenuButton,\n SidebarMenuItem,\n SidebarMenuSkeleton,\n SidebarMenuSub,\n SidebarMenuSubButton,\n SidebarMenuSubItem,\n SidebarProvider,\n SidebarRail,\n SidebarSeparator,\n SidebarTrigger,\n useSidebar,\n};\n","import ComboBox, { ComboBoxOption } from '@/components/basics/combo-box.component';\nimport {\n Sidebar,\n SidebarContent,\n SidebarGroup,\n SidebarGroupLabel,\n SidebarGroupContent,\n SidebarMenu,\n SidebarMenuItem,\n SidebarMenuButton,\n} from '@/components/shadcn-ui/sidebar';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { useCallback } from 'react';\n\nexport type SelectedSettingsSidebarItem = {\n label: string;\n projectId?: string;\n};\n\nexport type ProjectInfo = { projectId: string; projectName: string };\n\nexport type SettingsSidebarProps = {\n /** Optional id for testing */\n id?: string;\n\n /** Extension labels from contribution */\n extensionLabels: string[];\n\n /** Project names and ids */\n projectInfo: ProjectInfo[];\n\n /** Handler for selecting a sidebar item */\n handleSelectSidebarItem: (key: string, projectId?: string) => void;\n\n /** The current selected value in the sidebar */\n selectedSidebarItem: SelectedSettingsSidebarItem;\n\n /** Label for the group of extensions setting groups */\n extensionsSidebarGroupLabel: string;\n\n /** Label for the group of projects settings */\n projectsSidebarGroupLabel: string;\n\n /** Placeholder text for the button */\n buttonPlaceholderText: string;\n};\n\nexport default function SettingsSidebar({\n id,\n extensionLabels,\n projectInfo,\n handleSelectSidebarItem,\n selectedSidebarItem,\n extensionsSidebarGroupLabel,\n projectsSidebarGroupLabel,\n buttonPlaceholderText,\n}: SettingsSidebarProps) {\n const handleSelectItem = useCallback(\n (item: string, projectId?: string) => {\n handleSelectSidebarItem(item, projectId);\n },\n [handleSelectSidebarItem],\n );\n\n const getProjectNameFromProjectId = useCallback(\n (projectId: string) => {\n const project = projectInfo.find((info) => info.projectId === projectId);\n return project ? project.projectName : projectId;\n },\n [projectInfo],\n );\n\n const getIsActive: (label: string) => boolean = useCallback(\n (label: string) => !selectedSidebarItem.projectId && label === selectedSidebarItem.label,\n [selectedSidebarItem],\n );\n\n return (\n \n \n \n \n {extensionsSidebarGroupLabel}\n \n \n \n {extensionLabels.map((label) => (\n \n handleSelectItem(label)}\n isActive={getIsActive(label)}\n >\n {label}\n \n \n ))}\n \n \n \n \n \n {projectsSidebarGroupLabel}\n \n \n info.projectId)}\n getOptionLabel={(projectId: ComboBoxOption) => {\n // This function expects a ComboBoxOption, but we know it is a string\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n return getProjectNameFromProjectId(projectId as string);\n }}\n buttonPlaceholder={buttonPlaceholderText}\n onChange={(projectId: string) => {\n const selectedProjectName = getProjectNameFromProjectId(projectId);\n handleSelectItem(selectedProjectName, projectId);\n }}\n value={selectedSidebarItem?.projectId ?? undefined}\n />\n \n \n \n \n );\n}\n","import { SidebarInset, SidebarProvider } from '@/components/shadcn-ui/sidebar';\nimport { PropsWithChildren } from 'react';\nimport SearchBar from '@/components/basics/search-bar.component';\nimport SettingsSidebar, { SettingsSidebarProps } from './settings-sidebar.component';\n\nexport type SettingsSidebarContentSearchProps = SettingsSidebarProps &\n PropsWithChildren & {\n /** Optional id for testing */\n id?: string;\n\n /** Handler to run when the value of the search bar changes */\n onSearch: (searchQuery: string) => void;\n };\n\nexport default function SettingsSidebarContentSearch({\n id,\n extensionLabels,\n projectInfo,\n children,\n handleSelectSidebarItem,\n selectedSidebarItem,\n onSearch,\n extensionsSidebarGroupLabel,\n projectsSidebarGroupLabel,\n buttonPlaceholderText,\n}: SettingsSidebarContentSearchProps) {\n return (\n
    \n
    \n \n
    \n \n \n {children}\n \n
    \n );\n}\n","import { Button } from '@/components/shadcn-ui/button';\nimport {\n Select,\n SelectContent,\n SelectGroup,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\nimport {\n Table,\n TableBody,\n TableCell,\n TableHead,\n TableHeader,\n TableRow,\n} from '@/components/shadcn-ui/table';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Canon } from '@sillsdev/scripture';\nimport {\n Cell,\n ColumnDef,\n flexRender,\n getCoreRowModel,\n getExpandedRowModel,\n getGroupedRowModel,\n getSortedRowModel,\n GroupingState,\n Row,\n RowSelectionState,\n SortingState,\n useReactTable,\n} from '@tanstack/react-table';\nimport '@/components/advanced/scripture-results-viewer/scripture-results-viewer.component.css';\nimport {\n compareScrRefs,\n formatScrRef,\n ScriptureSelection,\n scrRefToBBBCCCVVV,\n} from 'platform-bible-utils';\nimport { MouseEvent, useEffect, useMemo, useState } from 'react';\nimport { ChevronDown, ChevronLeft, ChevronRight } from 'lucide-react';\n\n/**\n * Information (e.g., a checking error or some other type of \"transient\" annotation) about something\n * noteworthy at a specific place in an instance of the Scriptures.\n */\nexport type ScriptureItemDetail = ScriptureSelection & {\n /**\n * Text of the error, note, etc. In the future, we might want to support something more than just\n * text so that a JSX element could be provided with a link or some other controls related to the\n * issue being reported.\n */\n detail: string;\n};\n\n/**\n * A uniquely identifiable source of results that can be displayed in the ScriptureResultsViewer.\n * Generally, the source will be a particular Scripture check, but there may be other types of\n * sources.\n */\nexport type ResultsSource = {\n /**\n * Uniquely identifies the source.\n *\n * @type {string}\n */\n id: string;\n\n /**\n * Name (potentially localized) of the source, suitable for display in the UI.\n *\n * @type {string}\n */\n displayName: string;\n};\n\nexport type ScriptureSrcItemDetail = ScriptureItemDetail & {\n /** Source/type of detail. Can be used for grouping. */\n source: ResultsSource;\n};\n\n/**\n * Represents a set of results keyed by Scripture reference. Generally, the source will be a\n * particular Scripture check, but this type also allows for other types of uniquely identifiable\n * sources.\n */\nexport type ResultsSet = {\n /**\n * The backing source associated with this set of results.\n *\n * @type {ResultsSource}\n */\n source: ResultsSource;\n\n /**\n * Array of Scripture item details (messages keyed by Scripture reference).\n *\n * @type {ScriptureItemDetail[]}\n */\n data: ScriptureItemDetail[];\n};\n\nconst scrBookColId = 'scrBook';\nconst scrRefColId = 'scrRef';\nconst typeColId = 'source';\nconst detailsColId = 'details';\n\nconst defaultScrRefColumnName = 'Scripture Reference';\nconst defaultScrBookGroupName = 'Scripture Book';\nconst defaultTypeColumnName = 'Type';\nconst defaultDetailsColumnName = 'Details';\n\nexport type ScriptureResultsViewerColumnInfo = {\n /** Optional header to display for the Reference column. Default value: 'Scripture Reference'. */\n scriptureReferenceColumnName?: string;\n\n /** Optional text to display to refer to the Scripture book group. Default value: 'Scripture Book'. */\n scriptureBookGroupName?: string;\n\n /** Optional header to display for the Type column. Default value: 'Type'. */\n typeColumnName?: string;\n\n /** Optional header to display for the Details column. Default value: 'Details' */\n detailsColumnName?: string;\n};\n\nexport type ScriptureResultsViewerProps = ScriptureResultsViewerColumnInfo & {\n /** Groups of ScriptureItemDetail objects from particular sources (e.g., Scripture checks) */\n sources: ResultsSet[];\n\n /** Flag indicating whether to display column headers. Default is false. */\n showColumnHeaders?: boolean;\n\n /** Flag indicating whether to display source column. Default is false. */\n showSourceColumn?: boolean;\n\n /** Callback function to notify when a row is selected */\n onRowSelected?: (selectedRow: ScriptureSrcItemDetail | undefined) => void;\n\n /** Text direction ltr or rtl */\n direction?: 'ltr' | 'rtl';\n};\n\nfunction getColumns(\n colInfo?: ScriptureResultsViewerColumnInfo,\n showSourceColumn?: boolean,\n): ColumnDef[] {\n const showSrcCol = showSourceColumn ?? false;\n return [\n {\n accessorFn: (row) =>\n `${Canon.bookNumberToId(row.start.bookNum)} ${row.start.chapterNum}:${row.start.verseNum}`,\n id: scrBookColId,\n header: colInfo?.scriptureReferenceColumnName ?? defaultScrRefColumnName,\n cell: (info) => {\n const row = info.row.original;\n if (info.row.getIsGrouped()) {\n return Canon.bookNumberToEnglishName(row.start.bookNum);\n }\n return info.row.groupingColumnId === scrBookColId ? formatScrRef(row.start) : undefined;\n },\n getGroupingValue: (row) => row.start.bookNum,\n sortingFn: (a, b) => {\n return compareScrRefs(a.original.start, b.original.start);\n },\n enableGrouping: true,\n },\n {\n accessorFn: (row) => formatScrRef(row.start),\n id: scrRefColId,\n header: undefined,\n cell: (info) => {\n const row = info.row.original;\n return info.row.getIsGrouped() ? undefined : formatScrRef(row.start);\n },\n sortingFn: (a, b) => {\n return compareScrRefs(a.original.start, b.original.start);\n },\n enableGrouping: false,\n },\n {\n accessorFn: (row) => row.source.displayName,\n id: typeColId,\n header: showSrcCol ? (colInfo?.typeColumnName ?? defaultTypeColumnName) : undefined,\n cell: (info) => (showSrcCol || info.row.getIsGrouped() ? info.getValue() : undefined),\n getGroupingValue: (row) => row.source.id,\n sortingFn: (a, b) =>\n a.original.source.displayName.localeCompare(b.original.source.displayName),\n enableGrouping: true,\n },\n {\n accessorFn: (row) => row.detail,\n id: detailsColId,\n header: colInfo?.detailsColumnName ?? defaultDetailsColumnName,\n cell: (info) => info.getValue(),\n enableGrouping: false,\n },\n ];\n}\n\nconst toRefOrRange = (scriptureSelection: ScriptureSelection) => {\n if (!('offset' in scriptureSelection.start))\n throw new Error('No offset available in range start');\n if (scriptureSelection.end && !('offset' in scriptureSelection.end))\n throw new Error('No offset available in range end');\n const { offset: offsetStart } = scriptureSelection.start;\n let offsetEnd: number = 0;\n if (scriptureSelection.end) ({ offset: offsetEnd } = scriptureSelection.end);\n if (\n !scriptureSelection.end ||\n compareScrRefs(scriptureSelection.start, scriptureSelection.end) === 0\n )\n return `${scrRefToBBBCCCVVV(scriptureSelection.start)}+${offsetStart}`;\n return `${scrRefToBBBCCCVVV(scriptureSelection.start)}+${offsetStart}-${scrRefToBBBCCCVVV(scriptureSelection.end)}+${offsetEnd}`;\n};\n\nconst getRowKey = (row: ScriptureSrcItemDetail) =>\n `${toRefOrRange({ start: row.start, end: row.end })} ${row.source.displayName} ${row.detail}`;\n\n/**\n * Component to display a combined list of detailed items from one or more sources, where the items\n * are keyed primarily by Scripture reference. This is particularly useful for displaying a list of\n * results from Scripture checks, but more generally could be used to display any \"results\" from any\n * source(s). The component allows for grouping by Scripture book, source, or both. By default, it\n * displays somewhat \"tree-like\" which allows it to be more horizontally compact and intuitive. But\n * it also has the option of displaying as a traditional table with column headings (with or without\n * the source column showing).\n */\nexport default function ScriptureResultsViewer({\n sources,\n showColumnHeaders = false,\n showSourceColumn = false,\n scriptureReferenceColumnName,\n scriptureBookGroupName,\n typeColumnName,\n detailsColumnName,\n onRowSelected,\n direction = 'ltr',\n}: ScriptureResultsViewerProps) {\n const [grouping, setGrouping] = useState([]);\n const [sorting, setSorting] = useState([{ id: scrBookColId, desc: false }]);\n const [rowSelection, setRowSelection] = useState({});\n\n const scriptureResults = useMemo(\n () =>\n sources.flatMap((source) => {\n return source.data.map((item) => ({\n ...item,\n source: source.source,\n }));\n }),\n [sources],\n );\n\n const columns = useMemo(\n () =>\n getColumns(\n {\n scriptureReferenceColumnName,\n typeColumnName,\n detailsColumnName,\n },\n showSourceColumn,\n ),\n [scriptureReferenceColumnName, typeColumnName, detailsColumnName, showSourceColumn],\n );\n\n useEffect(() => {\n // Ensure sorting is applied correctly when grouped by type\n if (grouping.includes(typeColId)) {\n setSorting([\n { id: typeColId, desc: false },\n { id: scrBookColId, desc: false },\n ]);\n } else {\n setSorting([{ id: scrBookColId, desc: false }]);\n }\n }, [grouping]);\n\n const table = useReactTable({\n data: scriptureResults,\n columns,\n state: {\n grouping,\n sorting,\n rowSelection,\n },\n onGroupingChange: setGrouping,\n onSortingChange: setSorting,\n onRowSelectionChange: setRowSelection,\n getExpandedRowModel: getExpandedRowModel(),\n getGroupedRowModel: getGroupedRowModel(),\n getCoreRowModel: getCoreRowModel(),\n getSortedRowModel: getSortedRowModel(),\n getRowId: getRowKey,\n autoResetExpanded: false,\n enableMultiRowSelection: false,\n enableSubRowSelection: false,\n });\n\n useEffect(() => {\n if (onRowSelected) {\n const selectedRows = table.getSelectedRowModel().rowsById;\n const keys = Object.keys(selectedRows);\n if (keys.length === 1) {\n const selectedRow = scriptureResults.find((row) => getRowKey(row) === keys[0]) || undefined;\n if (selectedRow) onRowSelected(selectedRow);\n }\n }\n }, [rowSelection, scriptureResults, onRowSelected, table]);\n\n // Define possible grouping options\n const scrBookGroupName = scriptureBookGroupName ?? defaultScrBookGroupName;\n const typeGroupName = typeColumnName ?? defaultTypeColumnName;\n\n const groupingOptions = [\n { label: 'No Grouping', value: [] },\n { label: `Group by ${scrBookGroupName}`, value: [scrBookColId] },\n { label: `Group by ${typeGroupName}`, value: [typeColId] },\n {\n label: `Group by ${scrBookGroupName} and ${typeGroupName}`,\n value: [scrBookColId, typeColId],\n },\n {\n label: `Group by ${typeGroupName} and ${scrBookGroupName}`,\n value: [typeColId, scrBookColId],\n },\n ];\n\n const handleSelectChange = (selectedGrouping: string) => {\n setGrouping(JSON.parse(selectedGrouping));\n };\n\n const handleRowClick = (row: Row, event: MouseEvent) => {\n if (!row.getIsGrouped() && !row.getIsSelected()) {\n row.getToggleSelectedHandler()(event);\n }\n };\n\n const getEvenOrOddBandingStyle = (row: Row, index: number) => {\n if (row.getIsGrouped()) return '';\n // UX has now said they don't think they want banding. I'm leaving in the code to\n // set even and odd styles, but there's nothing in the CSS to style them differently.\n // The \"even\" style used to also have tw-bg-neutral-300 (along with even) to create\n // a visual banding effect. That could be added back in if UX changes the decision.\n return cn('banded-row', index % 2 === 0 ? 'even' : 'odd');\n };\n\n const getIndent = (\n groupingState: GroupingState,\n row: Row,\n cell: Cell,\n ) => {\n if (groupingState?.length === 0 || row.depth < cell.column.getGroupedIndex()) return undefined;\n if (row.getIsGrouped()) {\n switch (row.depth) {\n case 1:\n return 'tw-ps-4';\n default:\n return undefined;\n }\n }\n switch (row.depth) {\n case 1:\n return 'tw-ps-8';\n case 2:\n return 'tw-ps-12';\n default:\n return undefined;\n }\n };\n\n return (\n
    \n {!showColumnHeaders && (\n {\n handleSelectChange(value);\n }}\n >\n \n \n \n \n \n {groupingOptions.map((option) => (\n \n {option.label}\n \n ))}\n \n \n \n )}\n \n {showColumnHeaders && (\n \n {table.getHeaderGroups().map((headerGroup) => (\n \n {headerGroup.headers\n .filter((h) => h.column.columnDef.header)\n .map((header) => (\n /* For sticky column headers to work, we probably need to change the default definition of the shadcn Table component. See https://github.com/shadcn-ui/ui/issues/1151 */\n \n {header.isPlaceholder ? undefined : (\n
    \n {header.column.getCanGroup() ? (\n \n {header.column.getIsGrouped() ? `🛑` : `👊 `}\n \n ) : undefined}{' '}\n {flexRender(header.column.columnDef.header, header.getContext())}\n
    \n )}\n
    \n ))}\n
    \n ))}\n
    \n )}\n \n {table.getRowModel().rows.map((row, rowIndex) => {\n return (\n handleRowClick(row, event)}\n >\n {row.getVisibleCells().map((cell) => {\n if (\n cell.getIsPlaceholder() ||\n (cell.column.columnDef.enableGrouping &&\n !cell.getIsGrouped() &&\n (cell.column.columnDef.id !== typeColId || !showSourceColumn))\n )\n return undefined;\n return (\n \n {(() => {\n if (cell.getIsGrouped()) {\n return (\n \n {row.getIsExpanded() && }\n {!row.getIsExpanded() &&\n (direction === 'ltr' ? : )}{' '}\n {flexRender(cell.column.columnDef.cell, cell.getContext())} (\n {row.subRows.length})\n \n );\n }\n\n // if (cell.getIsAggregated()) {\n // flexRender(\n // cell.column.columnDef.aggregatedCell ?? cell.column.columnDef.cell,\n // cell.getContext(),\n // );\n // }\n\n return flexRender(cell.column.columnDef.cell, cell.getContext());\n })()}\n \n );\n })}\n \n );\n })}\n \n
    \n
    \n );\n}\n","import {\n getLocalizeKeyForScrollGroupId,\n LanguageStrings,\n ScrollGroupId,\n} from 'platform-bible-utils';\nimport {\n Select,\n SelectContent,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\n\nconst DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS = {\n [getLocalizeKeyForScrollGroupId('undefined')]: 'Ø',\n [getLocalizeKeyForScrollGroupId(0)]: 'A',\n [getLocalizeKeyForScrollGroupId(1)]: 'B',\n [getLocalizeKeyForScrollGroupId(2)]: 'C',\n [getLocalizeKeyForScrollGroupId(3)]: 'D',\n [getLocalizeKeyForScrollGroupId(4)]: 'E',\n [getLocalizeKeyForScrollGroupId(5)]: 'F',\n [getLocalizeKeyForScrollGroupId(6)]: 'G',\n [getLocalizeKeyForScrollGroupId(7)]: 'H',\n [getLocalizeKeyForScrollGroupId(8)]: 'I',\n [getLocalizeKeyForScrollGroupId(9)]: 'J',\n [getLocalizeKeyForScrollGroupId(10)]: 'K',\n [getLocalizeKeyForScrollGroupId(11)]: 'L',\n [getLocalizeKeyForScrollGroupId(12)]: 'M',\n [getLocalizeKeyForScrollGroupId(13)]: 'N',\n [getLocalizeKeyForScrollGroupId(14)]: 'O',\n [getLocalizeKeyForScrollGroupId(15)]: 'P',\n [getLocalizeKeyForScrollGroupId(16)]: 'Q',\n [getLocalizeKeyForScrollGroupId(17)]: 'R',\n [getLocalizeKeyForScrollGroupId(18)]: 'S',\n [getLocalizeKeyForScrollGroupId(19)]: 'T',\n [getLocalizeKeyForScrollGroupId(20)]: 'U',\n [getLocalizeKeyForScrollGroupId(21)]: 'V',\n [getLocalizeKeyForScrollGroupId(22)]: 'W',\n [getLocalizeKeyForScrollGroupId(23)]: 'X',\n [getLocalizeKeyForScrollGroupId(24)]: 'Y',\n [getLocalizeKeyForScrollGroupId(25)]: 'Z',\n};\n\nexport type ScrollGroupSelectorProps = {\n /**\n * List of scroll group ids to show to the user. Either a {@link ScrollGroupId} or `undefined` for\n * no scroll group\n */\n availableScrollGroupIds: (ScrollGroupId | undefined)[];\n /** Currently selected scroll group id. `undefined` for no scroll group */\n scrollGroupId: ScrollGroupId | undefined;\n /** Callback function run when the user tries to change the scroll group id */\n onChangeScrollGroupId: (newScrollGroupId: ScrollGroupId | undefined) => void;\n /**\n * Localized strings to use for displaying scroll group ids. Must be an object whose keys are\n * `getLocalizeKeyForScrollGroupId(scrollGroupId)` for all scroll group ids (and `undefined` if\n * included) in {@link ScrollGroupSelectorProps.availableScrollGroupIds} and whose values are the\n * localized strings to use for those scroll group ids.\n *\n * Defaults to English localizations of English alphabet for scroll groups 0-25 (e.g. 0 is A) and\n * Ø for `undefined`. Will fill in any that are not provided with these English localizations.\n * Also, if any values match the keys, the English localization will be used. This is useful in\n * case you want to pass in a temporary version of the localized strings while your localized\n * strings load.\n *\n * @example\n *\n * ```typescript\n * const myScrollGroupIdLocalizedStrings = {\n * [getLocalizeKeyForScrollGroupId('undefined')]: 'Ø',\n * [getLocalizeKeyForScrollGroupId(0)]: 'A',\n * [getLocalizeKeyForScrollGroupId(1)]: 'B',\n * [getLocalizeKeyForScrollGroupId(2)]: 'C',\n * [getLocalizeKeyForScrollGroupId(3)]: 'D',\n * [getLocalizeKeyForScrollGroupId(4)]: 'E',\n * };\n * ```\n *\n * @example\n *\n * ```tsx\n * const availableScrollGroupIds = [undefined, 0, 1, 2, 3, 4];\n *\n * const localizeKeys = getLocalizeKeysForScrollGroupIds();\n *\n * const [localizedStrings] = useLocalizedStrings(localizeKeys);\n *\n * ...\n *\n * \n * ```\n */\n localizedStrings?: LanguageStrings;\n};\n\n/** Selector component for choosing a scroll group */\nexport default function ScrollGroupSelector({\n availableScrollGroupIds,\n scrollGroupId,\n onChangeScrollGroupId,\n localizedStrings = {},\n}: ScrollGroupSelectorProps) {\n const localizedStringsDefaulted = {\n ...DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS,\n ...Object.fromEntries(\n Object.entries(localizedStrings).map(\n ([localizedStringKey, localizedStringValue]: [string, string]) => [\n localizedStringKey,\n localizedStringKey === localizedStringValue &&\n localizedStringKey in DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS\n ? DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS[localizedStringKey]\n : localizedStringValue,\n ],\n ),\n ),\n };\n return (\n \n onChangeScrollGroupId(\n newScrollGroupString === 'undefined' ? undefined : parseInt(newScrollGroupString, 10),\n )\n }\n >\n \n \n \n \n {availableScrollGroupIds.map((scrollGroupOptionId) => (\n \n {localizedStringsDefaulted[getLocalizeKeyForScrollGroupId(scrollGroupOptionId)]}\n \n ))}\n \n \n );\n}\n","import { PropsWithChildren } from 'react';\nimport { Separator } from '@/components/shadcn-ui/separator';\n\n/** Props for the SettingsList component, currently just children */\ntype SettingsListProps = PropsWithChildren;\n\n/**\n * SettingsList component is a wrapper for list items. Rendered with a formatted div\n *\n * @param children To populate the list with\n * @returns Formatted div encompassing the children\n */\nexport function SettingsList({ children }: SettingsListProps) {\n return
    {children}
    ;\n}\n\n/** Props for SettingsListItem component */\ntype SettingsListItemProps = PropsWithChildren & {\n /** Primary text of the list item */\n primary: string;\n\n /** Optional text of the list item */\n secondary?: string | undefined;\n\n /** Optional boolean to display a message if the children aren't loaded yet. Defaults to false */\n isLoading?: boolean;\n\n /** Optional message to display if isLoading */\n loadingMessage?: string;\n};\n\n/**\n * SettingsListItem component is a common list item. Rendered with a formatted div\n *\n * @param primary Primary text of the list item\n * @param secondary Optional secondary text of the list item\n * @param isLoading Optional, to display a message if the action component isn't generated yet,\n * defaults to false\n * @param children The action component(s) to provide for this item\n * @param loadingMessage Optional, message to display if isLoading\n * @returns Formatted div encompassing the list item content\n */\nexport function SettingsListItem({\n primary,\n secondary,\n children,\n isLoading = false,\n loadingMessage,\n}: SettingsListItemProps) {\n return (\n
    \n
    \n

    {primary}

    \n

    \n {secondary}\n

    \n
    \n\n {isLoading ? (\n

    {loadingMessage}

    \n ) : (\n
    {children}
    \n )}\n
    \n );\n}\n\n/** Props for SettingsListHeader component */\ntype SettingsListHeaderProps = {\n /** The primary text of the list header */\n primary: string;\n\n /** Optional secondary text of the list header */\n secondary?: string | undefined;\n\n /** Optional boolean to include a separator underneath the secondary text. Defaults to false */\n includeSeparator?: boolean;\n};\n\n/**\n * SettingsListHeader component displays text above the list\n *\n * @param primary The primary text of the list header\n * @param secondary Optional secondary text of the list header\n * @param includeSeparator Optional boolean to include a separator underneath the secondary text.\n * Defaults to false\n * @returns Formatted div with list header content\n */\nexport function SettingsListHeader({\n primary,\n secondary,\n includeSeparator = false,\n}: SettingsListHeaderProps) {\n return (\n
    \n
    \n

    {primary}

    \n

    {secondary}

    \n
    \n {includeSeparator ? : ''}\n
    \n );\n}\n","import Checkbox from '@/components/shadcn-ui/checkbox';\nimport { Label } from '@/components/shadcn-ui/label';\n\nexport type ChecklistProps = {\n /** Optional string representing the id attribute of the Checklist */\n id?: string;\n /** Optional string representing CSS class name(s) for styling */\n className?: string;\n /** Array of strings representing the checkable items */\n listItems: string[];\n /** Array of strings representing the checked items */\n selectedListItems: string[];\n /**\n * Function that is called when a checkbox item is selected or deselected\n *\n * @param item The string description for this item\n * @param selected True if selected, false if not selected\n */\n handleSelectListItem: (item: string, selected: boolean) => void;\n\n /**\n * Optional function creates a label for a provided checkable item\n *\n * @param item The item for which a label is to be created\n * @returns A string representing the label text for the checkbox associated with that item\n */\n createLabel?: (item: string) => string;\n};\n\n/** Renders a list of checkboxes. Each checkbox corresponds to an item from the `listItems` array. */\nexport default function Checklist({\n id,\n className,\n listItems,\n selectedListItems,\n handleSelectListItem,\n createLabel,\n}: ChecklistProps) {\n return (\n
    \n {listItems.map((item) => (\n
    \n handleSelectListItem(item, value)}\n />\n \n
    \n ))}\n
    \n );\n}\n","function _interopRequireDefault(obj) {\n return obj && obj.__esModule ? obj : {\n \"default\": obj\n };\n}\nmodule.exports = _interopRequireDefault, module.exports.__esModule = true, module.exports[\"default\"] = module.exports;","export default function chainPropTypes(propType1, propType2) {\n if (process.env.NODE_ENV === 'production') {\n return () => null;\n }\n return function validate(...args) {\n return propType1(...args) || propType2(...args);\n };\n}","export default function _extends() {\n _extends = Object.assign ? Object.assign.bind() : function (target) {\n for (var i = 1; i < arguments.length; i++) {\n var source = arguments[i];\n for (var key in source) {\n if (Object.prototype.hasOwnProperty.call(source, key)) {\n target[key] = source[key];\n }\n }\n }\n return target;\n };\n return _extends.apply(this, arguments);\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\n// https://github.com/sindresorhus/is-plain-obj/blob/main/index.js\nexport function isPlainObject(item) {\n if (typeof item !== 'object' || item === null) {\n return false;\n }\n const prototype = Object.getPrototypeOf(item);\n return (prototype === null || prototype === Object.prototype || Object.getPrototypeOf(prototype) === null) && !(Symbol.toStringTag in item) && !(Symbol.iterator in item);\n}\nfunction deepClone(source) {\n if (!isPlainObject(source)) {\n return source;\n }\n const output = {};\n Object.keys(source).forEach(key => {\n output[key] = deepClone(source[key]);\n });\n return output;\n}\nexport default function deepmerge(target, source, options = {\n clone: true\n}) {\n const output = options.clone ? _extends({}, target) : target;\n if (isPlainObject(target) && isPlainObject(source)) {\n Object.keys(source).forEach(key => {\n // Avoid prototype pollution\n if (key === '__proto__') {\n return;\n }\n if (isPlainObject(source[key]) && key in target && isPlainObject(target[key])) {\n // Since `output` is a clone of `target` and we have narrowed `target` in this block we can cast to the same type.\n output[key] = deepmerge(target[key], source[key], options);\n } else if (options.clone) {\n output[key] = isPlainObject(source[key]) ? deepClone(source[key]) : source[key];\n } else {\n output[key] = source[key];\n }\n });\n }\n return output;\n}","/** @license React v16.13.1\n * react-is.production.min.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';var b=\"function\"===typeof Symbol&&Symbol.for,c=b?Symbol.for(\"react.element\"):60103,d=b?Symbol.for(\"react.portal\"):60106,e=b?Symbol.for(\"react.fragment\"):60107,f=b?Symbol.for(\"react.strict_mode\"):60108,g=b?Symbol.for(\"react.profiler\"):60114,h=b?Symbol.for(\"react.provider\"):60109,k=b?Symbol.for(\"react.context\"):60110,l=b?Symbol.for(\"react.async_mode\"):60111,m=b?Symbol.for(\"react.concurrent_mode\"):60111,n=b?Symbol.for(\"react.forward_ref\"):60112,p=b?Symbol.for(\"react.suspense\"):60113,q=b?\nSymbol.for(\"react.suspense_list\"):60120,r=b?Symbol.for(\"react.memo\"):60115,t=b?Symbol.for(\"react.lazy\"):60116,v=b?Symbol.for(\"react.block\"):60121,w=b?Symbol.for(\"react.fundamental\"):60117,x=b?Symbol.for(\"react.responder\"):60118,y=b?Symbol.for(\"react.scope\"):60119;\nfunction z(a){if(\"object\"===typeof a&&null!==a){var u=a.$$typeof;switch(u){case c:switch(a=a.type,a){case l:case m:case e:case g:case f:case p:return a;default:switch(a=a&&a.$$typeof,a){case k:case n:case t:case r:case h:return a;default:return u}}case d:return u}}}function A(a){return z(a)===m}exports.AsyncMode=l;exports.ConcurrentMode=m;exports.ContextConsumer=k;exports.ContextProvider=h;exports.Element=c;exports.ForwardRef=n;exports.Fragment=e;exports.Lazy=t;exports.Memo=r;exports.Portal=d;\nexports.Profiler=g;exports.StrictMode=f;exports.Suspense=p;exports.isAsyncMode=function(a){return A(a)||z(a)===l};exports.isConcurrentMode=A;exports.isContextConsumer=function(a){return z(a)===k};exports.isContextProvider=function(a){return z(a)===h};exports.isElement=function(a){return\"object\"===typeof a&&null!==a&&a.$$typeof===c};exports.isForwardRef=function(a){return z(a)===n};exports.isFragment=function(a){return z(a)===e};exports.isLazy=function(a){return z(a)===t};\nexports.isMemo=function(a){return z(a)===r};exports.isPortal=function(a){return z(a)===d};exports.isProfiler=function(a){return z(a)===g};exports.isStrictMode=function(a){return z(a)===f};exports.isSuspense=function(a){return z(a)===p};\nexports.isValidElementType=function(a){return\"string\"===typeof a||\"function\"===typeof a||a===e||a===m||a===g||a===f||a===p||a===q||\"object\"===typeof a&&null!==a&&(a.$$typeof===t||a.$$typeof===r||a.$$typeof===h||a.$$typeof===k||a.$$typeof===n||a.$$typeof===w||a.$$typeof===x||a.$$typeof===y||a.$$typeof===v)};exports.typeOf=z;\n","/** @license React v16.13.1\n * react-is.development.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\n\n\nif (process.env.NODE_ENV !== \"production\") {\n (function() {\n'use strict';\n\n// The Symbol used to tag the ReactElement-like types. If there is no native Symbol\n// nor polyfill, then a plain number is used for performance.\nvar hasSymbol = typeof Symbol === 'function' && Symbol.for;\nvar REACT_ELEMENT_TYPE = hasSymbol ? Symbol.for('react.element') : 0xeac7;\nvar REACT_PORTAL_TYPE = hasSymbol ? Symbol.for('react.portal') : 0xeaca;\nvar REACT_FRAGMENT_TYPE = hasSymbol ? Symbol.for('react.fragment') : 0xeacb;\nvar REACT_STRICT_MODE_TYPE = hasSymbol ? Symbol.for('react.strict_mode') : 0xeacc;\nvar REACT_PROFILER_TYPE = hasSymbol ? Symbol.for('react.profiler') : 0xead2;\nvar REACT_PROVIDER_TYPE = hasSymbol ? Symbol.for('react.provider') : 0xeacd;\nvar REACT_CONTEXT_TYPE = hasSymbol ? Symbol.for('react.context') : 0xeace; // TODO: We don't use AsyncMode or ConcurrentMode anymore. They were temporary\n// (unstable) APIs that have been removed. Can we remove the symbols?\n\nvar REACT_ASYNC_MODE_TYPE = hasSymbol ? Symbol.for('react.async_mode') : 0xeacf;\nvar REACT_CONCURRENT_MODE_TYPE = hasSymbol ? Symbol.for('react.concurrent_mode') : 0xeacf;\nvar REACT_FORWARD_REF_TYPE = hasSymbol ? Symbol.for('react.forward_ref') : 0xead0;\nvar REACT_SUSPENSE_TYPE = hasSymbol ? Symbol.for('react.suspense') : 0xead1;\nvar REACT_SUSPENSE_LIST_TYPE = hasSymbol ? Symbol.for('react.suspense_list') : 0xead8;\nvar REACT_MEMO_TYPE = hasSymbol ? Symbol.for('react.memo') : 0xead3;\nvar REACT_LAZY_TYPE = hasSymbol ? Symbol.for('react.lazy') : 0xead4;\nvar REACT_BLOCK_TYPE = hasSymbol ? Symbol.for('react.block') : 0xead9;\nvar REACT_FUNDAMENTAL_TYPE = hasSymbol ? Symbol.for('react.fundamental') : 0xead5;\nvar REACT_RESPONDER_TYPE = hasSymbol ? Symbol.for('react.responder') : 0xead6;\nvar REACT_SCOPE_TYPE = hasSymbol ? Symbol.for('react.scope') : 0xead7;\n\nfunction isValidElementType(type) {\n return typeof type === 'string' || typeof type === 'function' || // Note: its typeof might be other than 'symbol' or 'number' if it's a polyfill.\n type === REACT_FRAGMENT_TYPE || type === REACT_CONCURRENT_MODE_TYPE || type === REACT_PROFILER_TYPE || type === REACT_STRICT_MODE_TYPE || type === REACT_SUSPENSE_TYPE || type === REACT_SUSPENSE_LIST_TYPE || typeof type === 'object' && type !== null && (type.$$typeof === REACT_LAZY_TYPE || type.$$typeof === REACT_MEMO_TYPE || type.$$typeof === REACT_PROVIDER_TYPE || type.$$typeof === REACT_CONTEXT_TYPE || type.$$typeof === REACT_FORWARD_REF_TYPE || type.$$typeof === REACT_FUNDAMENTAL_TYPE || type.$$typeof === REACT_RESPONDER_TYPE || type.$$typeof === REACT_SCOPE_TYPE || type.$$typeof === REACT_BLOCK_TYPE);\n}\n\nfunction typeOf(object) {\n if (typeof object === 'object' && object !== null) {\n var $$typeof = object.$$typeof;\n\n switch ($$typeof) {\n case REACT_ELEMENT_TYPE:\n var type = object.type;\n\n switch (type) {\n case REACT_ASYNC_MODE_TYPE:\n case REACT_CONCURRENT_MODE_TYPE:\n case REACT_FRAGMENT_TYPE:\n case REACT_PROFILER_TYPE:\n case REACT_STRICT_MODE_TYPE:\n case REACT_SUSPENSE_TYPE:\n return type;\n\n default:\n var $$typeofType = type && type.$$typeof;\n\n switch ($$typeofType) {\n case REACT_CONTEXT_TYPE:\n case REACT_FORWARD_REF_TYPE:\n case REACT_LAZY_TYPE:\n case REACT_MEMO_TYPE:\n case REACT_PROVIDER_TYPE:\n return $$typeofType;\n\n default:\n return $$typeof;\n }\n\n }\n\n case REACT_PORTAL_TYPE:\n return $$typeof;\n }\n }\n\n return undefined;\n} // AsyncMode is deprecated along with isAsyncMode\n\nvar AsyncMode = REACT_ASYNC_MODE_TYPE;\nvar ConcurrentMode = REACT_CONCURRENT_MODE_TYPE;\nvar ContextConsumer = REACT_CONTEXT_TYPE;\nvar ContextProvider = REACT_PROVIDER_TYPE;\nvar Element = REACT_ELEMENT_TYPE;\nvar ForwardRef = REACT_FORWARD_REF_TYPE;\nvar Fragment = REACT_FRAGMENT_TYPE;\nvar Lazy = REACT_LAZY_TYPE;\nvar Memo = REACT_MEMO_TYPE;\nvar Portal = REACT_PORTAL_TYPE;\nvar Profiler = REACT_PROFILER_TYPE;\nvar StrictMode = REACT_STRICT_MODE_TYPE;\nvar Suspense = REACT_SUSPENSE_TYPE;\nvar hasWarnedAboutDeprecatedIsAsyncMode = false; // AsyncMode should be deprecated\n\nfunction isAsyncMode(object) {\n {\n if (!hasWarnedAboutDeprecatedIsAsyncMode) {\n hasWarnedAboutDeprecatedIsAsyncMode = true; // Using console['warn'] to evade Babel and ESLint\n\n console['warn']('The ReactIs.isAsyncMode() alias has been deprecated, ' + 'and will be removed in React 17+. Update your code to use ' + 'ReactIs.isConcurrentMode() instead. It has the exact same API.');\n }\n }\n\n return isConcurrentMode(object) || typeOf(object) === REACT_ASYNC_MODE_TYPE;\n}\nfunction isConcurrentMode(object) {\n return typeOf(object) === REACT_CONCURRENT_MODE_TYPE;\n}\nfunction isContextConsumer(object) {\n return typeOf(object) === REACT_CONTEXT_TYPE;\n}\nfunction isContextProvider(object) {\n return typeOf(object) === REACT_PROVIDER_TYPE;\n}\nfunction isElement(object) {\n return typeof object === 'object' && object !== null && object.$$typeof === REACT_ELEMENT_TYPE;\n}\nfunction isForwardRef(object) {\n return typeOf(object) === REACT_FORWARD_REF_TYPE;\n}\nfunction isFragment(object) {\n return typeOf(object) === REACT_FRAGMENT_TYPE;\n}\nfunction isLazy(object) {\n return typeOf(object) === REACT_LAZY_TYPE;\n}\nfunction isMemo(object) {\n return typeOf(object) === REACT_MEMO_TYPE;\n}\nfunction isPortal(object) {\n return typeOf(object) === REACT_PORTAL_TYPE;\n}\nfunction isProfiler(object) {\n return typeOf(object) === REACT_PROFILER_TYPE;\n}\nfunction isStrictMode(object) {\n return typeOf(object) === REACT_STRICT_MODE_TYPE;\n}\nfunction isSuspense(object) {\n return typeOf(object) === REACT_SUSPENSE_TYPE;\n}\n\nexports.AsyncMode = AsyncMode;\nexports.ConcurrentMode = ConcurrentMode;\nexports.ContextConsumer = ContextConsumer;\nexports.ContextProvider = ContextProvider;\nexports.Element = Element;\nexports.ForwardRef = ForwardRef;\nexports.Fragment = Fragment;\nexports.Lazy = Lazy;\nexports.Memo = Memo;\nexports.Portal = Portal;\nexports.Profiler = Profiler;\nexports.StrictMode = StrictMode;\nexports.Suspense = Suspense;\nexports.isAsyncMode = isAsyncMode;\nexports.isConcurrentMode = isConcurrentMode;\nexports.isContextConsumer = isContextConsumer;\nexports.isContextProvider = isContextProvider;\nexports.isElement = isElement;\nexports.isForwardRef = isForwardRef;\nexports.isFragment = isFragment;\nexports.isLazy = isLazy;\nexports.isMemo = isMemo;\nexports.isPortal = isPortal;\nexports.isProfiler = isProfiler;\nexports.isStrictMode = isStrictMode;\nexports.isSuspense = isSuspense;\nexports.isValidElementType = isValidElementType;\nexports.typeOf = typeOf;\n })();\n}\n","'use strict';\n\nif (process.env.NODE_ENV === 'production') {\n module.exports = require('./cjs/react-is.production.min.js');\n} else {\n module.exports = require('./cjs/react-is.development.js');\n}\n","/*\nobject-assign\n(c) Sindre Sorhus\n@license MIT\n*/\n\n'use strict';\n/* eslint-disable no-unused-vars */\nvar getOwnPropertySymbols = Object.getOwnPropertySymbols;\nvar hasOwnProperty = Object.prototype.hasOwnProperty;\nvar propIsEnumerable = Object.prototype.propertyIsEnumerable;\n\nfunction toObject(val) {\n\tif (val === null || val === undefined) {\n\t\tthrow new TypeError('Object.assign cannot be called with null or undefined');\n\t}\n\n\treturn Object(val);\n}\n\nfunction shouldUseNative() {\n\ttry {\n\t\tif (!Object.assign) {\n\t\t\treturn false;\n\t\t}\n\n\t\t// Detect buggy property enumeration order in older V8 versions.\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=4118\n\t\tvar test1 = new String('abc'); // eslint-disable-line no-new-wrappers\n\t\ttest1[5] = 'de';\n\t\tif (Object.getOwnPropertyNames(test1)[0] === '5') {\n\t\t\treturn false;\n\t\t}\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=3056\n\t\tvar test2 = {};\n\t\tfor (var i = 0; i < 10; i++) {\n\t\t\ttest2['_' + String.fromCharCode(i)] = i;\n\t\t}\n\t\tvar order2 = Object.getOwnPropertyNames(test2).map(function (n) {\n\t\t\treturn test2[n];\n\t\t});\n\t\tif (order2.join('') !== '0123456789') {\n\t\t\treturn false;\n\t\t}\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=3056\n\t\tvar test3 = {};\n\t\t'abcdefghijklmnopqrst'.split('').forEach(function (letter) {\n\t\t\ttest3[letter] = letter;\n\t\t});\n\t\tif (Object.keys(Object.assign({}, test3)).join('') !==\n\t\t\t\t'abcdefghijklmnopqrst') {\n\t\t\treturn false;\n\t\t}\n\n\t\treturn true;\n\t} catch (err) {\n\t\t// We don't expect any of the above to throw, but better to be safe.\n\t\treturn false;\n\t}\n}\n\nmodule.exports = shouldUseNative() ? Object.assign : function (target, source) {\n\tvar from;\n\tvar to = toObject(target);\n\tvar symbols;\n\n\tfor (var s = 1; s < arguments.length; s++) {\n\t\tfrom = Object(arguments[s]);\n\n\t\tfor (var key in from) {\n\t\t\tif (hasOwnProperty.call(from, key)) {\n\t\t\t\tto[key] = from[key];\n\t\t\t}\n\t\t}\n\n\t\tif (getOwnPropertySymbols) {\n\t\t\tsymbols = getOwnPropertySymbols(from);\n\t\t\tfor (var i = 0; i < symbols.length; i++) {\n\t\t\t\tif (propIsEnumerable.call(from, symbols[i])) {\n\t\t\t\t\tto[symbols[i]] = from[symbols[i]];\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\n\treturn to;\n};\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar ReactPropTypesSecret = 'SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED';\n\nmodule.exports = ReactPropTypesSecret;\n","module.exports = Function.call.bind(Object.prototype.hasOwnProperty);\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar printWarning = function() {};\n\nif (process.env.NODE_ENV !== 'production') {\n var ReactPropTypesSecret = require('./lib/ReactPropTypesSecret');\n var loggedTypeFailures = {};\n var has = require('./lib/has');\n\n printWarning = function(text) {\n var message = 'Warning: ' + text;\n if (typeof console !== 'undefined') {\n console.error(message);\n }\n try {\n // --- Welcome to debugging React ---\n // This error was thrown as a convenience so that you can use this stack\n // to find the callsite that caused this warning to fire.\n throw new Error(message);\n } catch (x) { /**/ }\n };\n}\n\n/**\n * Assert that the values match with the type specs.\n * Error messages are memorized and will only be shown once.\n *\n * @param {object} typeSpecs Map of name to a ReactPropType\n * @param {object} values Runtime values that need to be type-checked\n * @param {string} location e.g. \"prop\", \"context\", \"child context\"\n * @param {string} componentName Name of the component for error messages.\n * @param {?Function} getStack Returns the component stack.\n * @private\n */\nfunction checkPropTypes(typeSpecs, values, location, componentName, getStack) {\n if (process.env.NODE_ENV !== 'production') {\n for (var typeSpecName in typeSpecs) {\n if (has(typeSpecs, typeSpecName)) {\n var error;\n // Prop type validation may throw. In case they do, we don't want to\n // fail the render phase where it didn't fail before. So we log it.\n // After these have been cleaned up, we'll let them throw.\n try {\n // This is intentionally an invariant that gets caught. It's the same\n // behavior as without this statement except with a better message.\n if (typeof typeSpecs[typeSpecName] !== 'function') {\n var err = Error(\n (componentName || 'React class') + ': ' + location + ' type `' + typeSpecName + '` is invalid; ' +\n 'it must be a function, usually from the `prop-types` package, but received `' + typeof typeSpecs[typeSpecName] + '`.' +\n 'This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.'\n );\n err.name = 'Invariant Violation';\n throw err;\n }\n error = typeSpecs[typeSpecName](values, typeSpecName, componentName, location, null, ReactPropTypesSecret);\n } catch (ex) {\n error = ex;\n }\n if (error && !(error instanceof Error)) {\n printWarning(\n (componentName || 'React class') + ': type specification of ' +\n location + ' `' + typeSpecName + '` is invalid; the type checker ' +\n 'function must return `null` or an `Error` but returned a ' + typeof error + '. ' +\n 'You may have forgotten to pass an argument to the type checker ' +\n 'creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and ' +\n 'shape all require an argument).'\n );\n }\n if (error instanceof Error && !(error.message in loggedTypeFailures)) {\n // Only monitor this failure once because there tends to be a lot of the\n // same error.\n loggedTypeFailures[error.message] = true;\n\n var stack = getStack ? getStack() : '';\n\n printWarning(\n 'Failed ' + location + ' type: ' + error.message + (stack != null ? stack : '')\n );\n }\n }\n }\n }\n}\n\n/**\n * Resets warning cache when testing.\n *\n * @private\n */\ncheckPropTypes.resetWarningCache = function() {\n if (process.env.NODE_ENV !== 'production') {\n loggedTypeFailures = {};\n }\n}\n\nmodule.exports = checkPropTypes;\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar ReactIs = require('react-is');\nvar assign = require('object-assign');\n\nvar ReactPropTypesSecret = require('./lib/ReactPropTypesSecret');\nvar has = require('./lib/has');\nvar checkPropTypes = require('./checkPropTypes');\n\nvar printWarning = function() {};\n\nif (process.env.NODE_ENV !== 'production') {\n printWarning = function(text) {\n var message = 'Warning: ' + text;\n if (typeof console !== 'undefined') {\n console.error(message);\n }\n try {\n // --- Welcome to debugging React ---\n // This error was thrown as a convenience so that you can use this stack\n // to find the callsite that caused this warning to fire.\n throw new Error(message);\n } catch (x) {}\n };\n}\n\nfunction emptyFunctionThatReturnsNull() {\n return null;\n}\n\nmodule.exports = function(isValidElement, throwOnDirectAccess) {\n /* global Symbol */\n var ITERATOR_SYMBOL = typeof Symbol === 'function' && Symbol.iterator;\n var FAUX_ITERATOR_SYMBOL = '@@iterator'; // Before Symbol spec.\n\n /**\n * Returns the iterator method function contained on the iterable object.\n *\n * Be sure to invoke the function with the iterable as context:\n *\n * var iteratorFn = getIteratorFn(myIterable);\n * if (iteratorFn) {\n * var iterator = iteratorFn.call(myIterable);\n * ...\n * }\n *\n * @param {?object} maybeIterable\n * @return {?function}\n */\n function getIteratorFn(maybeIterable) {\n var iteratorFn = maybeIterable && (ITERATOR_SYMBOL && maybeIterable[ITERATOR_SYMBOL] || maybeIterable[FAUX_ITERATOR_SYMBOL]);\n if (typeof iteratorFn === 'function') {\n return iteratorFn;\n }\n }\n\n /**\n * Collection of methods that allow declaration and validation of props that are\n * supplied to React components. Example usage:\n *\n * var Props = require('ReactPropTypes');\n * var MyArticle = React.createClass({\n * propTypes: {\n * // An optional string prop named \"description\".\n * description: Props.string,\n *\n * // A required enum prop named \"category\".\n * category: Props.oneOf(['News','Photos']).isRequired,\n *\n * // A prop named \"dialog\" that requires an instance of Dialog.\n * dialog: Props.instanceOf(Dialog).isRequired\n * },\n * render: function() { ... }\n * });\n *\n * A more formal specification of how these methods are used:\n *\n * type := array|bool|func|object|number|string|oneOf([...])|instanceOf(...)\n * decl := ReactPropTypes.{type}(.isRequired)?\n *\n * Each and every declaration produces a function with the same signature. This\n * allows the creation of custom validation functions. For example:\n *\n * var MyLink = React.createClass({\n * propTypes: {\n * // An optional string or URI prop named \"href\".\n * href: function(props, propName, componentName) {\n * var propValue = props[propName];\n * if (propValue != null && typeof propValue !== 'string' &&\n * !(propValue instanceof URI)) {\n * return new Error(\n * 'Expected a string or an URI for ' + propName + ' in ' +\n * componentName\n * );\n * }\n * }\n * },\n * render: function() {...}\n * });\n *\n * @internal\n */\n\n var ANONYMOUS = '<>';\n\n // Important!\n // Keep this list in sync with production version in `./factoryWithThrowingShims.js`.\n var ReactPropTypes = {\n array: createPrimitiveTypeChecker('array'),\n bigint: createPrimitiveTypeChecker('bigint'),\n bool: createPrimitiveTypeChecker('boolean'),\n func: createPrimitiveTypeChecker('function'),\n number: createPrimitiveTypeChecker('number'),\n object: createPrimitiveTypeChecker('object'),\n string: createPrimitiveTypeChecker('string'),\n symbol: createPrimitiveTypeChecker('symbol'),\n\n any: createAnyTypeChecker(),\n arrayOf: createArrayOfTypeChecker,\n element: createElementTypeChecker(),\n elementType: createElementTypeTypeChecker(),\n instanceOf: createInstanceTypeChecker,\n node: createNodeChecker(),\n objectOf: createObjectOfTypeChecker,\n oneOf: createEnumTypeChecker,\n oneOfType: createUnionTypeChecker,\n shape: createShapeTypeChecker,\n exact: createStrictShapeTypeChecker,\n };\n\n /**\n * inlined Object.is polyfill to avoid requiring consumers ship their own\n * https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object/is\n */\n /*eslint-disable no-self-compare*/\n function is(x, y) {\n // SameValue algorithm\n if (x === y) {\n // Steps 1-5, 7-10\n // Steps 6.b-6.e: +0 != -0\n return x !== 0 || 1 / x === 1 / y;\n } else {\n // Step 6.a: NaN == NaN\n return x !== x && y !== y;\n }\n }\n /*eslint-enable no-self-compare*/\n\n /**\n * We use an Error-like object for backward compatibility as people may call\n * PropTypes directly and inspect their output. However, we don't use real\n * Errors anymore. We don't inspect their stack anyway, and creating them\n * is prohibitively expensive if they are created too often, such as what\n * happens in oneOfType() for any type before the one that matched.\n */\n function PropTypeError(message, data) {\n this.message = message;\n this.data = data && typeof data === 'object' ? data: {};\n this.stack = '';\n }\n // Make `instanceof Error` still work for returned errors.\n PropTypeError.prototype = Error.prototype;\n\n function createChainableTypeChecker(validate) {\n if (process.env.NODE_ENV !== 'production') {\n var manualPropTypeCallCache = {};\n var manualPropTypeWarningCount = 0;\n }\n function checkType(isRequired, props, propName, componentName, location, propFullName, secret) {\n componentName = componentName || ANONYMOUS;\n propFullName = propFullName || propName;\n\n if (secret !== ReactPropTypesSecret) {\n if (throwOnDirectAccess) {\n // New behavior only for users of `prop-types` package\n var err = new Error(\n 'Calling PropTypes validators directly is not supported by the `prop-types` package. ' +\n 'Use `PropTypes.checkPropTypes()` to call them. ' +\n 'Read more at http://fb.me/use-check-prop-types'\n );\n err.name = 'Invariant Violation';\n throw err;\n } else if (process.env.NODE_ENV !== 'production' && typeof console !== 'undefined') {\n // Old behavior for people using React.PropTypes\n var cacheKey = componentName + ':' + propName;\n if (\n !manualPropTypeCallCache[cacheKey] &&\n // Avoid spamming the console because they are often not actionable except for lib authors\n manualPropTypeWarningCount < 3\n ) {\n printWarning(\n 'You are manually calling a React.PropTypes validation ' +\n 'function for the `' + propFullName + '` prop on `' + componentName + '`. This is deprecated ' +\n 'and will throw in the standalone `prop-types` package. ' +\n 'You may be seeing this warning due to a third-party PropTypes ' +\n 'library. See https://fb.me/react-warning-dont-call-proptypes ' + 'for details.'\n );\n manualPropTypeCallCache[cacheKey] = true;\n manualPropTypeWarningCount++;\n }\n }\n }\n if (props[propName] == null) {\n if (isRequired) {\n if (props[propName] === null) {\n return new PropTypeError('The ' + location + ' `' + propFullName + '` is marked as required ' + ('in `' + componentName + '`, but its value is `null`.'));\n }\n return new PropTypeError('The ' + location + ' `' + propFullName + '` is marked as required in ' + ('`' + componentName + '`, but its value is `undefined`.'));\n }\n return null;\n } else {\n return validate(props, propName, componentName, location, propFullName);\n }\n }\n\n var chainedCheckType = checkType.bind(null, false);\n chainedCheckType.isRequired = checkType.bind(null, true);\n\n return chainedCheckType;\n }\n\n function createPrimitiveTypeChecker(expectedType) {\n function validate(props, propName, componentName, location, propFullName, secret) {\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== expectedType) {\n // `propValue` being instance of, say, date/regexp, pass the 'object'\n // check, but we can offer a more precise error message here rather than\n // 'of type `object`'.\n var preciseType = getPreciseType(propValue);\n\n return new PropTypeError(\n 'Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + preciseType + '` supplied to `' + componentName + '`, expected ') + ('`' + expectedType + '`.'),\n {expectedType: expectedType}\n );\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createAnyTypeChecker() {\n return createChainableTypeChecker(emptyFunctionThatReturnsNull);\n }\n\n function createArrayOfTypeChecker(typeChecker) {\n function validate(props, propName, componentName, location, propFullName) {\n if (typeof typeChecker !== 'function') {\n return new PropTypeError('Property `' + propFullName + '` of component `' + componentName + '` has invalid PropType notation inside arrayOf.');\n }\n var propValue = props[propName];\n if (!Array.isArray(propValue)) {\n var propType = getPropType(propValue);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected an array.'));\n }\n for (var i = 0; i < propValue.length; i++) {\n var error = typeChecker(propValue, i, componentName, location, propFullName + '[' + i + ']', ReactPropTypesSecret);\n if (error instanceof Error) {\n return error;\n }\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createElementTypeChecker() {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n if (!isValidElement(propValue)) {\n var propType = getPropType(propValue);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected a single ReactElement.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createElementTypeTypeChecker() {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n if (!ReactIs.isValidElementType(propValue)) {\n var propType = getPropType(propValue);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected a single ReactElement type.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createInstanceTypeChecker(expectedClass) {\n function validate(props, propName, componentName, location, propFullName) {\n if (!(props[propName] instanceof expectedClass)) {\n var expectedClassName = expectedClass.name || ANONYMOUS;\n var actualClassName = getClassName(props[propName]);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + actualClassName + '` supplied to `' + componentName + '`, expected ') + ('instance of `' + expectedClassName + '`.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createEnumTypeChecker(expectedValues) {\n if (!Array.isArray(expectedValues)) {\n if (process.env.NODE_ENV !== 'production') {\n if (arguments.length > 1) {\n printWarning(\n 'Invalid arguments supplied to oneOf, expected an array, got ' + arguments.length + ' arguments. ' +\n 'A common mistake is to write oneOf(x, y, z) instead of oneOf([x, y, z]).'\n );\n } else {\n printWarning('Invalid argument supplied to oneOf, expected an array.');\n }\n }\n return emptyFunctionThatReturnsNull;\n }\n\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n for (var i = 0; i < expectedValues.length; i++) {\n if (is(propValue, expectedValues[i])) {\n return null;\n }\n }\n\n var valuesString = JSON.stringify(expectedValues, function replacer(key, value) {\n var type = getPreciseType(value);\n if (type === 'symbol') {\n return String(value);\n }\n return value;\n });\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of value `' + String(propValue) + '` ' + ('supplied to `' + componentName + '`, expected one of ' + valuesString + '.'));\n }\n return createChainableTypeChecker(validate);\n }\n\n function createObjectOfTypeChecker(typeChecker) {\n function validate(props, propName, componentName, location, propFullName) {\n if (typeof typeChecker !== 'function') {\n return new PropTypeError('Property `' + propFullName + '` of component `' + componentName + '` has invalid PropType notation inside objectOf.');\n }\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== 'object') {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected an object.'));\n }\n for (var key in propValue) {\n if (has(propValue, key)) {\n var error = typeChecker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret);\n if (error instanceof Error) {\n return error;\n }\n }\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createUnionTypeChecker(arrayOfTypeCheckers) {\n if (!Array.isArray(arrayOfTypeCheckers)) {\n process.env.NODE_ENV !== 'production' ? printWarning('Invalid argument supplied to oneOfType, expected an instance of array.') : void 0;\n return emptyFunctionThatReturnsNull;\n }\n\n for (var i = 0; i < arrayOfTypeCheckers.length; i++) {\n var checker = arrayOfTypeCheckers[i];\n if (typeof checker !== 'function') {\n printWarning(\n 'Invalid argument supplied to oneOfType. Expected an array of check functions, but ' +\n 'received ' + getPostfixForTypeWarning(checker) + ' at index ' + i + '.'\n );\n return emptyFunctionThatReturnsNull;\n }\n }\n\n function validate(props, propName, componentName, location, propFullName) {\n var expectedTypes = [];\n for (var i = 0; i < arrayOfTypeCheckers.length; i++) {\n var checker = arrayOfTypeCheckers[i];\n var checkerResult = checker(props, propName, componentName, location, propFullName, ReactPropTypesSecret);\n if (checkerResult == null) {\n return null;\n }\n if (checkerResult.data && has(checkerResult.data, 'expectedType')) {\n expectedTypes.push(checkerResult.data.expectedType);\n }\n }\n var expectedTypesMessage = (expectedTypes.length > 0) ? ', expected one of type [' + expectedTypes.join(', ') + ']': '';\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` supplied to ' + ('`' + componentName + '`' + expectedTypesMessage + '.'));\n }\n return createChainableTypeChecker(validate);\n }\n\n function createNodeChecker() {\n function validate(props, propName, componentName, location, propFullName) {\n if (!isNode(props[propName])) {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` supplied to ' + ('`' + componentName + '`, expected a ReactNode.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function invalidValidatorError(componentName, location, propFullName, key, type) {\n return new PropTypeError(\n (componentName || 'React class') + ': ' + location + ' type `' + propFullName + '.' + key + '` is invalid; ' +\n 'it must be a function, usually from the `prop-types` package, but received `' + type + '`.'\n );\n }\n\n function createShapeTypeChecker(shapeTypes) {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== 'object') {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type `' + propType + '` ' + ('supplied to `' + componentName + '`, expected `object`.'));\n }\n for (var key in shapeTypes) {\n var checker = shapeTypes[key];\n if (typeof checker !== 'function') {\n return invalidValidatorError(componentName, location, propFullName, key, getPreciseType(checker));\n }\n var error = checker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret);\n if (error) {\n return error;\n }\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createStrictShapeTypeChecker(shapeTypes) {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== 'object') {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type `' + propType + '` ' + ('supplied to `' + componentName + '`, expected `object`.'));\n }\n // We need to check all keys in case some are required but missing from props.\n var allKeys = assign({}, props[propName], shapeTypes);\n for (var key in allKeys) {\n var checker = shapeTypes[key];\n if (has(shapeTypes, key) && typeof checker !== 'function') {\n return invalidValidatorError(componentName, location, propFullName, key, getPreciseType(checker));\n }\n if (!checker) {\n return new PropTypeError(\n 'Invalid ' + location + ' `' + propFullName + '` key `' + key + '` supplied to `' + componentName + '`.' +\n '\\nBad object: ' + JSON.stringify(props[propName], null, ' ') +\n '\\nValid keys: ' + JSON.stringify(Object.keys(shapeTypes), null, ' ')\n );\n }\n var error = checker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret);\n if (error) {\n return error;\n }\n }\n return null;\n }\n\n return createChainableTypeChecker(validate);\n }\n\n function isNode(propValue) {\n switch (typeof propValue) {\n case 'number':\n case 'string':\n case 'undefined':\n return true;\n case 'boolean':\n return !propValue;\n case 'object':\n if (Array.isArray(propValue)) {\n return propValue.every(isNode);\n }\n if (propValue === null || isValidElement(propValue)) {\n return true;\n }\n\n var iteratorFn = getIteratorFn(propValue);\n if (iteratorFn) {\n var iterator = iteratorFn.call(propValue);\n var step;\n if (iteratorFn !== propValue.entries) {\n while (!(step = iterator.next()).done) {\n if (!isNode(step.value)) {\n return false;\n }\n }\n } else {\n // Iterator will provide entry [k,v] tuples rather than values.\n while (!(step = iterator.next()).done) {\n var entry = step.value;\n if (entry) {\n if (!isNode(entry[1])) {\n return false;\n }\n }\n }\n }\n } else {\n return false;\n }\n\n return true;\n default:\n return false;\n }\n }\n\n function isSymbol(propType, propValue) {\n // Native Symbol.\n if (propType === 'symbol') {\n return true;\n }\n\n // falsy value can't be a Symbol\n if (!propValue) {\n return false;\n }\n\n // 19.4.3.5 Symbol.prototype[@@toStringTag] === 'Symbol'\n if (propValue['@@toStringTag'] === 'Symbol') {\n return true;\n }\n\n // Fallback for non-spec compliant Symbols which are polyfilled.\n if (typeof Symbol === 'function' && propValue instanceof Symbol) {\n return true;\n }\n\n return false;\n }\n\n // Equivalent of `typeof` but with special handling for array and regexp.\n function getPropType(propValue) {\n var propType = typeof propValue;\n if (Array.isArray(propValue)) {\n return 'array';\n }\n if (propValue instanceof RegExp) {\n // Old webkits (at least until Android 4.0) return 'function' rather than\n // 'object' for typeof a RegExp. We'll normalize this here so that /bla/\n // passes PropTypes.object.\n return 'object';\n }\n if (isSymbol(propType, propValue)) {\n return 'symbol';\n }\n return propType;\n }\n\n // This handles more types than `getPropType`. Only used for error messages.\n // See `createPrimitiveTypeChecker`.\n function getPreciseType(propValue) {\n if (typeof propValue === 'undefined' || propValue === null) {\n return '' + propValue;\n }\n var propType = getPropType(propValue);\n if (propType === 'object') {\n if (propValue instanceof Date) {\n return 'date';\n } else if (propValue instanceof RegExp) {\n return 'regexp';\n }\n }\n return propType;\n }\n\n // Returns a string that is postfixed to a warning about an invalid type.\n // For example, \"undefined\" or \"of type array\"\n function getPostfixForTypeWarning(value) {\n var type = getPreciseType(value);\n switch (type) {\n case 'array':\n case 'object':\n return 'an ' + type;\n case 'boolean':\n case 'date':\n case 'regexp':\n return 'a ' + type;\n default:\n return type;\n }\n }\n\n // Returns class name of the object, if any.\n function getClassName(propValue) {\n if (!propValue.constructor || !propValue.constructor.name) {\n return ANONYMOUS;\n }\n return propValue.constructor.name;\n }\n\n ReactPropTypes.checkPropTypes = checkPropTypes;\n ReactPropTypes.resetWarningCache = checkPropTypes.resetWarningCache;\n ReactPropTypes.PropTypes = ReactPropTypes;\n\n return ReactPropTypes;\n};\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar ReactPropTypesSecret = require('./lib/ReactPropTypesSecret');\n\nfunction emptyFunction() {}\nfunction emptyFunctionWithReset() {}\nemptyFunctionWithReset.resetWarningCache = emptyFunction;\n\nmodule.exports = function() {\n function shim(props, propName, componentName, location, propFullName, secret) {\n if (secret === ReactPropTypesSecret) {\n // It is still safe when called from React.\n return;\n }\n var err = new Error(\n 'Calling PropTypes validators directly is not supported by the `prop-types` package. ' +\n 'Use PropTypes.checkPropTypes() to call them. ' +\n 'Read more at http://fb.me/use-check-prop-types'\n );\n err.name = 'Invariant Violation';\n throw err;\n };\n shim.isRequired = shim;\n function getShim() {\n return shim;\n };\n // Important!\n // Keep this list in sync with production version in `./factoryWithTypeCheckers.js`.\n var ReactPropTypes = {\n array: shim,\n bigint: shim,\n bool: shim,\n func: shim,\n number: shim,\n object: shim,\n string: shim,\n symbol: shim,\n\n any: shim,\n arrayOf: getShim,\n element: shim,\n elementType: shim,\n instanceOf: getShim,\n node: shim,\n objectOf: getShim,\n oneOf: getShim,\n oneOfType: getShim,\n shape: getShim,\n exact: getShim,\n\n checkPropTypes: emptyFunctionWithReset,\n resetWarningCache: emptyFunction\n };\n\n ReactPropTypes.PropTypes = ReactPropTypes;\n\n return ReactPropTypes;\n};\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\nif (process.env.NODE_ENV !== 'production') {\n var ReactIs = require('react-is');\n\n // By explicitly using `prop-types` you are opting into new development behavior.\n // http://fb.me/prop-types-in-prod\n var throwOnDirectAccess = true;\n module.exports = require('./factoryWithTypeCheckers')(ReactIs.isElement, throwOnDirectAccess);\n} else {\n // By explicitly using `prop-types` you are opting into new production behavior.\n // http://fb.me/prop-types-in-prod\n module.exports = require('./factoryWithThrowingShims')();\n}\n","import PropTypes from 'prop-types';\nimport chainPropTypes from '../chainPropTypes';\nfunction isClassComponent(elementType) {\n // elementType.prototype?.isReactComponent\n const {\n prototype = {}\n } = elementType;\n return Boolean(prototype.isReactComponent);\n}\nfunction acceptingRef(props, propName, componentName, location, propFullName) {\n const element = props[propName];\n const safePropName = propFullName || propName;\n if (element == null ||\n // When server-side rendering React doesn't warn either.\n // This is not an accurate check for SSR.\n // This is only in place for Emotion compat.\n // TODO: Revisit once https://github.com/facebook/react/issues/20047 is resolved.\n typeof window === 'undefined') {\n return null;\n }\n let warningHint;\n const elementType = element.type;\n /**\n * Blacklisting instead of whitelisting\n *\n * Blacklisting will miss some components, such as React.Fragment. Those will at least\n * trigger a warning in React.\n * We can't whitelist because there is no safe way to detect React.forwardRef\n * or class components. \"Safe\" means there's no public API.\n *\n */\n if (typeof elementType === 'function' && !isClassComponent(elementType)) {\n warningHint = 'Did you accidentally use a plain function component for an element instead?';\n }\n if (warningHint !== undefined) {\n return new Error(`Invalid ${location} \\`${safePropName}\\` supplied to \\`${componentName}\\`. ` + `Expected an element that can hold a ref. ${warningHint} ` + 'For more information see https://mui.com/r/caveat-with-refs-guide');\n }\n return null;\n}\nconst elementAcceptingRef = chainPropTypes(PropTypes.element, acceptingRef);\nelementAcceptingRef.isRequired = chainPropTypes(PropTypes.element.isRequired, acceptingRef);\nexport default elementAcceptingRef;","import _extends from \"@babel/runtime/helpers/esm/extends\";\n// This module is based on https://github.com/airbnb/prop-types-exact repository.\n// However, in order to reduce the number of dependencies and to remove some extra safe checks\n// the module was forked.\n\nconst specialProperty = 'exact-prop: \\u200b';\nexport default function exactProp(propTypes) {\n if (process.env.NODE_ENV === 'production') {\n return propTypes;\n }\n return _extends({}, propTypes, {\n [specialProperty]: props => {\n const unsupportedProps = Object.keys(props).filter(prop => !propTypes.hasOwnProperty(prop));\n if (unsupportedProps.length > 0) {\n return new Error(`The following props are not supported: ${unsupportedProps.map(prop => `\\`${prop}\\``).join(', ')}. Please remove them.`);\n }\n return null;\n }\n });\n}","/**\n * WARNING: Don't import this directly.\n * Use `MuiError` from `@mui/internal-babel-macros/MuiError.macro` instead.\n * @param {number} code\n */\nexport default function formatMuiErrorMessage(code) {\n // Apply babel-plugin-transform-template-literals in loose mode\n // loose mode is safe if we're concatenating primitives\n // see https://babeljs.io/docs/en/babel-plugin-transform-template-literals#loose\n /* eslint-disable prefer-template */\n let url = 'https://mui.com/production-error/?code=' + code;\n for (let i = 1; i < arguments.length; i += 1) {\n // rest params over-transpile for this case\n // eslint-disable-next-line prefer-rest-params\n url += '&args[]=' + encodeURIComponent(arguments[i]);\n }\n return 'Minified MUI error #' + code + '; visit ' + url + ' for the full message.';\n /* eslint-enable prefer-template */\n}","/**\n * @license React\n * react-is.production.min.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n'use strict';var b=Symbol.for(\"react.element\"),c=Symbol.for(\"react.portal\"),d=Symbol.for(\"react.fragment\"),e=Symbol.for(\"react.strict_mode\"),f=Symbol.for(\"react.profiler\"),g=Symbol.for(\"react.provider\"),h=Symbol.for(\"react.context\"),k=Symbol.for(\"react.server_context\"),l=Symbol.for(\"react.forward_ref\"),m=Symbol.for(\"react.suspense\"),n=Symbol.for(\"react.suspense_list\"),p=Symbol.for(\"react.memo\"),q=Symbol.for(\"react.lazy\"),t=Symbol.for(\"react.offscreen\"),u;u=Symbol.for(\"react.module.reference\");\nfunction v(a){if(\"object\"===typeof a&&null!==a){var r=a.$$typeof;switch(r){case b:switch(a=a.type,a){case d:case f:case e:case m:case n:return a;default:switch(a=a&&a.$$typeof,a){case k:case h:case l:case q:case p:case g:return a;default:return r}}case c:return r}}}exports.ContextConsumer=h;exports.ContextProvider=g;exports.Element=b;exports.ForwardRef=l;exports.Fragment=d;exports.Lazy=q;exports.Memo=p;exports.Portal=c;exports.Profiler=f;exports.StrictMode=e;exports.Suspense=m;\nexports.SuspenseList=n;exports.isAsyncMode=function(){return!1};exports.isConcurrentMode=function(){return!1};exports.isContextConsumer=function(a){return v(a)===h};exports.isContextProvider=function(a){return v(a)===g};exports.isElement=function(a){return\"object\"===typeof a&&null!==a&&a.$$typeof===b};exports.isForwardRef=function(a){return v(a)===l};exports.isFragment=function(a){return v(a)===d};exports.isLazy=function(a){return v(a)===q};exports.isMemo=function(a){return v(a)===p};\nexports.isPortal=function(a){return v(a)===c};exports.isProfiler=function(a){return v(a)===f};exports.isStrictMode=function(a){return v(a)===e};exports.isSuspense=function(a){return v(a)===m};exports.isSuspenseList=function(a){return v(a)===n};\nexports.isValidElementType=function(a){return\"string\"===typeof a||\"function\"===typeof a||a===d||a===f||a===e||a===m||a===n||a===t||\"object\"===typeof a&&null!==a&&(a.$$typeof===q||a.$$typeof===p||a.$$typeof===g||a.$$typeof===h||a.$$typeof===l||a.$$typeof===u||void 0!==a.getModuleId)?!0:!1};exports.typeOf=v;\n","/**\n * @license React\n * react-is.development.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nif (process.env.NODE_ENV !== \"production\") {\n (function() {\n'use strict';\n\n// ATTENTION\n// When adding new symbols to this file,\n// Please consider also adding to 'react-devtools-shared/src/backend/ReactSymbols'\n// The Symbol used to tag the ReactElement-like types.\nvar REACT_ELEMENT_TYPE = Symbol.for('react.element');\nvar REACT_PORTAL_TYPE = Symbol.for('react.portal');\nvar REACT_FRAGMENT_TYPE = Symbol.for('react.fragment');\nvar REACT_STRICT_MODE_TYPE = Symbol.for('react.strict_mode');\nvar REACT_PROFILER_TYPE = Symbol.for('react.profiler');\nvar REACT_PROVIDER_TYPE = Symbol.for('react.provider');\nvar REACT_CONTEXT_TYPE = Symbol.for('react.context');\nvar REACT_SERVER_CONTEXT_TYPE = Symbol.for('react.server_context');\nvar REACT_FORWARD_REF_TYPE = Symbol.for('react.forward_ref');\nvar REACT_SUSPENSE_TYPE = Symbol.for('react.suspense');\nvar REACT_SUSPENSE_LIST_TYPE = Symbol.for('react.suspense_list');\nvar REACT_MEMO_TYPE = Symbol.for('react.memo');\nvar REACT_LAZY_TYPE = Symbol.for('react.lazy');\nvar REACT_OFFSCREEN_TYPE = Symbol.for('react.offscreen');\n\n// -----------------------------------------------------------------------------\n\nvar enableScopeAPI = false; // Experimental Create Event Handle API.\nvar enableCacheElement = false;\nvar enableTransitionTracing = false; // No known bugs, but needs performance testing\n\nvar enableLegacyHidden = false; // Enables unstable_avoidThisFallback feature in Fiber\n// stuff. Intended to enable React core members to more easily debug scheduling\n// issues in DEV builds.\n\nvar enableDebugTracing = false; // Track which Fiber(s) schedule render work.\n\nvar REACT_MODULE_REFERENCE;\n\n{\n REACT_MODULE_REFERENCE = Symbol.for('react.module.reference');\n}\n\nfunction isValidElementType(type) {\n if (typeof type === 'string' || typeof type === 'function') {\n return true;\n } // Note: typeof might be other than 'symbol' or 'number' (e.g. if it's a polyfill).\n\n\n if (type === REACT_FRAGMENT_TYPE || type === REACT_PROFILER_TYPE || enableDebugTracing || type === REACT_STRICT_MODE_TYPE || type === REACT_SUSPENSE_TYPE || type === REACT_SUSPENSE_LIST_TYPE || enableLegacyHidden || type === REACT_OFFSCREEN_TYPE || enableScopeAPI || enableCacheElement || enableTransitionTracing ) {\n return true;\n }\n\n if (typeof type === 'object' && type !== null) {\n if (type.$$typeof === REACT_LAZY_TYPE || type.$$typeof === REACT_MEMO_TYPE || type.$$typeof === REACT_PROVIDER_TYPE || type.$$typeof === REACT_CONTEXT_TYPE || type.$$typeof === REACT_FORWARD_REF_TYPE || // This needs to include all possible module reference object\n // types supported by any Flight configuration anywhere since\n // we don't know which Flight build this will end up being used\n // with.\n type.$$typeof === REACT_MODULE_REFERENCE || type.getModuleId !== undefined) {\n return true;\n }\n }\n\n return false;\n}\n\nfunction typeOf(object) {\n if (typeof object === 'object' && object !== null) {\n var $$typeof = object.$$typeof;\n\n switch ($$typeof) {\n case REACT_ELEMENT_TYPE:\n var type = object.type;\n\n switch (type) {\n case REACT_FRAGMENT_TYPE:\n case REACT_PROFILER_TYPE:\n case REACT_STRICT_MODE_TYPE:\n case REACT_SUSPENSE_TYPE:\n case REACT_SUSPENSE_LIST_TYPE:\n return type;\n\n default:\n var $$typeofType = type && type.$$typeof;\n\n switch ($$typeofType) {\n case REACT_SERVER_CONTEXT_TYPE:\n case REACT_CONTEXT_TYPE:\n case REACT_FORWARD_REF_TYPE:\n case REACT_LAZY_TYPE:\n case REACT_MEMO_TYPE:\n case REACT_PROVIDER_TYPE:\n return $$typeofType;\n\n default:\n return $$typeof;\n }\n\n }\n\n case REACT_PORTAL_TYPE:\n return $$typeof;\n }\n }\n\n return undefined;\n}\nvar ContextConsumer = REACT_CONTEXT_TYPE;\nvar ContextProvider = REACT_PROVIDER_TYPE;\nvar Element = REACT_ELEMENT_TYPE;\nvar ForwardRef = REACT_FORWARD_REF_TYPE;\nvar Fragment = REACT_FRAGMENT_TYPE;\nvar Lazy = REACT_LAZY_TYPE;\nvar Memo = REACT_MEMO_TYPE;\nvar Portal = REACT_PORTAL_TYPE;\nvar Profiler = REACT_PROFILER_TYPE;\nvar StrictMode = REACT_STRICT_MODE_TYPE;\nvar Suspense = REACT_SUSPENSE_TYPE;\nvar SuspenseList = REACT_SUSPENSE_LIST_TYPE;\nvar hasWarnedAboutDeprecatedIsAsyncMode = false;\nvar hasWarnedAboutDeprecatedIsConcurrentMode = false; // AsyncMode should be deprecated\n\nfunction isAsyncMode(object) {\n {\n if (!hasWarnedAboutDeprecatedIsAsyncMode) {\n hasWarnedAboutDeprecatedIsAsyncMode = true; // Using console['warn'] to evade Babel and ESLint\n\n console['warn']('The ReactIs.isAsyncMode() alias has been deprecated, ' + 'and will be removed in React 18+.');\n }\n }\n\n return false;\n}\nfunction isConcurrentMode(object) {\n {\n if (!hasWarnedAboutDeprecatedIsConcurrentMode) {\n hasWarnedAboutDeprecatedIsConcurrentMode = true; // Using console['warn'] to evade Babel and ESLint\n\n console['warn']('The ReactIs.isConcurrentMode() alias has been deprecated, ' + 'and will be removed in React 18+.');\n }\n }\n\n return false;\n}\nfunction isContextConsumer(object) {\n return typeOf(object) === REACT_CONTEXT_TYPE;\n}\nfunction isContextProvider(object) {\n return typeOf(object) === REACT_PROVIDER_TYPE;\n}\nfunction isElement(object) {\n return typeof object === 'object' && object !== null && object.$$typeof === REACT_ELEMENT_TYPE;\n}\nfunction isForwardRef(object) {\n return typeOf(object) === REACT_FORWARD_REF_TYPE;\n}\nfunction isFragment(object) {\n return typeOf(object) === REACT_FRAGMENT_TYPE;\n}\nfunction isLazy(object) {\n return typeOf(object) === REACT_LAZY_TYPE;\n}\nfunction isMemo(object) {\n return typeOf(object) === REACT_MEMO_TYPE;\n}\nfunction isPortal(object) {\n return typeOf(object) === REACT_PORTAL_TYPE;\n}\nfunction isProfiler(object) {\n return typeOf(object) === REACT_PROFILER_TYPE;\n}\nfunction isStrictMode(object) {\n return typeOf(object) === REACT_STRICT_MODE_TYPE;\n}\nfunction isSuspense(object) {\n return typeOf(object) === REACT_SUSPENSE_TYPE;\n}\nfunction isSuspenseList(object) {\n return typeOf(object) === REACT_SUSPENSE_LIST_TYPE;\n}\n\nexports.ContextConsumer = ContextConsumer;\nexports.ContextProvider = ContextProvider;\nexports.Element = Element;\nexports.ForwardRef = ForwardRef;\nexports.Fragment = Fragment;\nexports.Lazy = Lazy;\nexports.Memo = Memo;\nexports.Portal = Portal;\nexports.Profiler = Profiler;\nexports.StrictMode = StrictMode;\nexports.Suspense = Suspense;\nexports.SuspenseList = SuspenseList;\nexports.isAsyncMode = isAsyncMode;\nexports.isConcurrentMode = isConcurrentMode;\nexports.isContextConsumer = isContextConsumer;\nexports.isContextProvider = isContextProvider;\nexports.isElement = isElement;\nexports.isForwardRef = isForwardRef;\nexports.isFragment = isFragment;\nexports.isLazy = isLazy;\nexports.isMemo = isMemo;\nexports.isPortal = isPortal;\nexports.isProfiler = isProfiler;\nexports.isStrictMode = isStrictMode;\nexports.isSuspense = isSuspense;\nexports.isSuspenseList = isSuspenseList;\nexports.isValidElementType = isValidElementType;\nexports.typeOf = typeOf;\n })();\n}\n","'use strict';\n\nif (process.env.NODE_ENV === 'production') {\n module.exports = require('./cjs/react-is.production.min.js');\n} else {\n module.exports = require('./cjs/react-is.development.js');\n}\n","import { ForwardRef, Memo } from 'react-is';\n\n// Simplified polyfill for IE11 support\n// https://github.com/JamesMGreene/Function.name/blob/58b314d4a983110c3682f1228f845d39ccca1817/Function.name.js#L3\nconst fnNameMatchRegex = /^\\s*function(?:\\s|\\s*\\/\\*.*\\*\\/\\s*)+([^(\\s/]*)\\s*/;\nexport function getFunctionName(fn) {\n const match = `${fn}`.match(fnNameMatchRegex);\n const name = match && match[1];\n return name || '';\n}\nfunction getFunctionComponentName(Component, fallback = '') {\n return Component.displayName || Component.name || getFunctionName(Component) || fallback;\n}\nfunction getWrappedName(outerType, innerType, wrapperName) {\n const functionName = getFunctionComponentName(innerType);\n return outerType.displayName || (functionName !== '' ? `${wrapperName}(${functionName})` : wrapperName);\n}\n\n/**\n * cherry-pick from\n * https://github.com/facebook/react/blob/769b1f270e1251d9dbdce0fcbd9e92e502d059b8/packages/shared/getComponentName.js\n * originally forked from recompose/getDisplayName with added IE11 support\n */\nexport default function getDisplayName(Component) {\n if (Component == null) {\n return undefined;\n }\n if (typeof Component === 'string') {\n return Component;\n }\n if (typeof Component === 'function') {\n return getFunctionComponentName(Component, 'Component');\n }\n\n // TypeScript can't have components as objects but they exist in the form of `memo` or `Suspense`\n if (typeof Component === 'object') {\n switch (Component.$$typeof) {\n case ForwardRef:\n return getWrappedName(Component, Component.render, 'ForwardRef');\n case Memo:\n return getWrappedName(Component, Component.type, 'memo');\n default:\n return undefined;\n }\n }\n return undefined;\n}","export default function HTMLElementType(props, propName, componentName, location, propFullName) {\n if (process.env.NODE_ENV === 'production') {\n return null;\n }\n const propValue = props[propName];\n const safePropName = propFullName || propName;\n if (propValue == null) {\n return null;\n }\n if (propValue && propValue.nodeType !== 1) {\n return new Error(`Invalid ${location} \\`${safePropName}\\` supplied to \\`${componentName}\\`. ` + `Expected an HTMLElement.`);\n }\n return null;\n}","import PropTypes from 'prop-types';\nconst refType = PropTypes.oneOfType([PropTypes.func, PropTypes.object]);\nexport default refType;","import _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\n// It should to be noted that this function isn't equivalent to `text-transform: capitalize`.\n//\n// A strict capitalization should uppercase the first letter of each word in the sentence.\n// We only handle the first word.\nexport default function capitalize(string) {\n if (typeof string !== 'string') {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: \\`capitalize(string)\\` expects a string argument.` : _formatMuiErrorMessage(7));\n }\n return string.charAt(0).toUpperCase() + string.slice(1);\n}","/**\n * Safe chained function.\n *\n * Will only create a new function if needed,\n * otherwise will pass back existing functions or null.\n */\nexport default function createChainedFunction(...funcs) {\n return funcs.reduce((acc, func) => {\n if (func == null) {\n return acc;\n }\n return function chainedFunction(...args) {\n acc.apply(this, args);\n func.apply(this, args);\n };\n }, () => {});\n}","// Corresponds to 10 frames at 60 Hz.\n// A few bytes payload overhead when lodash/debounce is ~3 kB and debounce ~300 B.\nexport default function debounce(func, wait = 166) {\n let timeout;\n function debounced(...args) {\n const later = () => {\n // @ts-ignore\n func.apply(this, args);\n };\n clearTimeout(timeout);\n timeout = setTimeout(later, wait);\n }\n debounced.clear = () => {\n clearTimeout(timeout);\n };\n return debounced;\n}","export default function deprecatedPropType(validator, reason) {\n if (process.env.NODE_ENV === 'production') {\n return () => null;\n }\n return (props, propName, componentName, location, propFullName) => {\n const componentNameSafe = componentName || '<>';\n const propFullNameSafe = propFullName || propName;\n if (typeof props[propName] !== 'undefined') {\n return new Error(`The ${location} \\`${propFullNameSafe}\\` of ` + `\\`${componentNameSafe}\\` is deprecated. ${reason}`);\n }\n return null;\n };\n}","import * as React from 'react';\nexport default function isMuiElement(element, muiNames) {\n var _muiName, _element$type;\n return /*#__PURE__*/React.isValidElement(element) && muiNames.indexOf( // For server components `muiName` is avaialble in element.type._payload.value.muiName\n // relevant info - https://github.com/facebook/react/blob/2807d781a08db8e9873687fccc25c0f12b4fb3d4/packages/react/src/ReactLazy.js#L45\n // eslint-disable-next-line no-underscore-dangle\n (_muiName = element.type.muiName) != null ? _muiName : (_element$type = element.type) == null || (_element$type = _element$type._payload) == null || (_element$type = _element$type.value) == null ? void 0 : _element$type.muiName) !== -1;\n}","export default function ownerDocument(node) {\n return node && node.ownerDocument || document;\n}","import ownerDocument from '../ownerDocument';\nexport default function ownerWindow(node) {\n const doc = ownerDocument(node);\n return doc.defaultView || window;\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nexport default function requirePropFactory(componentNameInError, Component) {\n if (process.env.NODE_ENV === 'production') {\n return () => null;\n }\n\n // eslint-disable-next-line react/forbid-foreign-prop-types\n const prevPropTypes = Component ? _extends({}, Component.propTypes) : null;\n const requireProp = requiredProp => (props, propName, componentName, location, propFullName, ...args) => {\n const propFullNameSafe = propFullName || propName;\n const defaultTypeChecker = prevPropTypes == null ? void 0 : prevPropTypes[propFullNameSafe];\n if (defaultTypeChecker) {\n const typeCheckerResult = defaultTypeChecker(props, propName, componentName, location, propFullName, ...args);\n if (typeCheckerResult) {\n return typeCheckerResult;\n }\n }\n if (typeof props[propName] !== 'undefined' && !props[requiredProp]) {\n return new Error(`The prop \\`${propFullNameSafe}\\` of ` + `\\`${componentNameInError}\\` can only be used together with the \\`${requiredProp}\\` prop.`);\n }\n return null;\n };\n return requireProp;\n}","/**\n * TODO v5: consider making it private\n *\n * passes {value} to {ref}\n *\n * WARNING: Be sure to only call this inside a callback that is passed as a ref.\n * Otherwise, make sure to cleanup the previous {ref} if it changes. See\n * https://github.com/mui/material-ui/issues/13539\n *\n * Useful if you want to expose the ref of an inner component to the public API\n * while still using it inside the component.\n * @param ref A ref callback or ref object. If anything falsy, this is a no-op.\n */\nexport default function setRef(ref, value) {\n if (typeof ref === 'function') {\n ref(value);\n } else if (ref) {\n ref.current = value;\n }\n}","'use client';\n\nimport * as React from 'react';\n\n/**\n * A version of `React.useLayoutEffect` that does not show a warning when server-side rendering.\n * This is useful for effects that are only needed for client-side rendering but not for SSR.\n *\n * Before you use this hook, make sure to read https://gist.github.com/gaearon/e7d97cdf38a2907924ea12e4ebdf3c85\n * and confirm it doesn't apply to your use-case.\n */\nconst useEnhancedEffect = typeof window !== 'undefined' ? React.useLayoutEffect : React.useEffect;\nexport default useEnhancedEffect;","'use client';\n\nimport * as React from 'react';\nlet globalId = 0;\nfunction useGlobalId(idOverride) {\n const [defaultId, setDefaultId] = React.useState(idOverride);\n const id = idOverride || defaultId;\n React.useEffect(() => {\n if (defaultId == null) {\n // Fallback to this default id when possible.\n // Use the incrementing value for client-side rendering only.\n // We can't use it server-side.\n // If you want to use random values please consider the Birthday Problem: https://en.wikipedia.org/wiki/Birthday_problem\n globalId += 1;\n setDefaultId(`mui-${globalId}`);\n }\n }, [defaultId]);\n return id;\n}\n\n// downstream bundlers may remove unnecessary concatenation, but won't remove toString call -- Workaround for https://github.com/webpack/webpack/issues/14814\nconst maybeReactUseId = React['useId'.toString()];\n/**\n *\n * @example
    \n * @param idOverride\n * @returns {string}\n */\nexport default function useId(idOverride) {\n if (maybeReactUseId !== undefined) {\n const reactId = maybeReactUseId();\n return idOverride != null ? idOverride : reactId;\n }\n // eslint-disable-next-line react-hooks/rules-of-hooks -- `React.useId` is invariant at runtime.\n return useGlobalId(idOverride);\n}","export default function unsupportedProp(props, propName, componentName, location, propFullName) {\n if (process.env.NODE_ENV === 'production') {\n return null;\n }\n const propFullNameSafe = propFullName || propName;\n if (typeof props[propName] !== 'undefined') {\n return new Error(`The prop \\`${propFullNameSafe}\\` is not supported. Please remove it.`);\n }\n return null;\n}","'use client';\n\n/* eslint-disable react-hooks/rules-of-hooks, react-hooks/exhaustive-deps */\nimport * as React from 'react';\nexport default function useControlled({\n controlled,\n default: defaultProp,\n name,\n state = 'value'\n}) {\n // isControlled is ignored in the hook dependency lists as it should never change.\n const {\n current: isControlled\n } = React.useRef(controlled !== undefined);\n const [valueState, setValue] = React.useState(defaultProp);\n const value = isControlled ? controlled : valueState;\n if (process.env.NODE_ENV !== 'production') {\n React.useEffect(() => {\n if (isControlled !== (controlled !== undefined)) {\n console.error([`MUI: A component is changing the ${isControlled ? '' : 'un'}controlled ${state} state of ${name} to be ${isControlled ? 'un' : ''}controlled.`, 'Elements should not switch from uncontrolled to controlled (or vice versa).', `Decide between using a controlled or uncontrolled ${name} ` + 'element for the lifetime of the component.', \"The nature of the state is determined during the first render. It's considered controlled if the value is not `undefined`.\", 'More info: https://fb.me/react-controlled-components'].join('\\n'));\n }\n }, [state, name, controlled]);\n const {\n current: defaultValue\n } = React.useRef(defaultProp);\n React.useEffect(() => {\n if (!isControlled && defaultValue !== defaultProp) {\n console.error([`MUI: A component is changing the default ${state} state of an uncontrolled ${name} after being initialized. ` + `To suppress this warning opt to use a controlled ${name}.`].join('\\n'));\n }\n }, [JSON.stringify(defaultProp)]);\n }\n const setValueIfUncontrolled = React.useCallback(newValue => {\n if (!isControlled) {\n setValue(newValue);\n }\n }, []);\n return [value, setValueIfUncontrolled];\n}","'use client';\n\nimport * as React from 'react';\nimport useEnhancedEffect from '../useEnhancedEffect';\n\n/**\n * Inspired by https://github.com/facebook/react/issues/14099#issuecomment-440013892\n * See RFC in https://github.com/reactjs/rfcs/pull/220\n */\n\nfunction useEventCallback(fn) {\n const ref = React.useRef(fn);\n useEnhancedEffect(() => {\n ref.current = fn;\n });\n return React.useRef((...args) =>\n // @ts-expect-error hide `this`\n (0, ref.current)(...args)).current;\n}\nexport default useEventCallback;","'use client';\n\nimport * as React from 'react';\nimport setRef from '../setRef';\nexport default function useForkRef(...refs) {\n /**\n * This will create a new function if the refs passed to this hook change and are all defined.\n * This means react will call the old forkRef with `null` and the new forkRef\n * with the ref. Cleanup naturally emerges from this behavior.\n */\n return React.useMemo(() => {\n if (refs.every(ref => ref == null)) {\n return null;\n }\n return instance => {\n refs.forEach(ref => {\n setRef(ref, instance);\n });\n };\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, refs);\n}","'use client';\n\nimport * as React from 'react';\nconst UNINITIALIZED = {};\n\n/**\n * A React.useRef() that is initialized lazily with a function. Note that it accepts an optional\n * initialization argument, so the initialization function doesn't need to be an inline closure.\n *\n * @usage\n * const ref = useLazyRef(sortColumns, columns)\n */\nexport default function useLazyRef(init, initArg) {\n const ref = React.useRef(UNINITIALIZED);\n if (ref.current === UNINITIALIZED) {\n ref.current = init(initArg);\n }\n return ref;\n}","'use client';\n\nimport * as React from 'react';\nconst EMPTY = [];\n\n/**\n * A React.useEffect equivalent that runs once, when the component is mounted.\n */\nexport default function useOnMount(fn) {\n /* eslint-disable react-hooks/exhaustive-deps */\n React.useEffect(fn, EMPTY);\n /* eslint-enable react-hooks/exhaustive-deps */\n}","'use client';\n\nimport useLazyRef from '../useLazyRef/useLazyRef';\nimport useOnMount from '../useOnMount/useOnMount';\nexport class Timeout {\n constructor() {\n this.currentId = null;\n this.clear = () => {\n if (this.currentId !== null) {\n clearTimeout(this.currentId);\n this.currentId = null;\n }\n };\n this.disposeEffect = () => {\n return this.clear;\n };\n }\n static create() {\n return new Timeout();\n }\n /**\n * Executes `fn` after `delay`, clearing any previously scheduled call.\n */\n start(delay, fn) {\n this.clear();\n this.currentId = setTimeout(() => {\n this.currentId = null;\n fn();\n }, delay);\n }\n}\nexport default function useTimeout() {\n const timeout = useLazyRef(Timeout.create).current;\n useOnMount(timeout.disposeEffect);\n return timeout;\n}","'use client';\n\n// based on https://github.com/WICG/focus-visible/blob/v4.1.5/src/focus-visible.js\nimport * as React from 'react';\nimport { Timeout } from '../useTimeout/useTimeout';\nlet hadKeyboardEvent = true;\nlet hadFocusVisibleRecently = false;\nconst hadFocusVisibleRecentlyTimeout = new Timeout();\nconst inputTypesWhitelist = {\n text: true,\n search: true,\n url: true,\n tel: true,\n email: true,\n password: true,\n number: true,\n date: true,\n month: true,\n week: true,\n time: true,\n datetime: true,\n 'datetime-local': true\n};\n\n/**\n * Computes whether the given element should automatically trigger the\n * `focus-visible` class being added, i.e. whether it should always match\n * `:focus-visible` when focused.\n * @param {Element} node\n * @returns {boolean}\n */\nfunction focusTriggersKeyboardModality(node) {\n const {\n type,\n tagName\n } = node;\n if (tagName === 'INPUT' && inputTypesWhitelist[type] && !node.readOnly) {\n return true;\n }\n if (tagName === 'TEXTAREA' && !node.readOnly) {\n return true;\n }\n if (node.isContentEditable) {\n return true;\n }\n return false;\n}\n\n/**\n * Keep track of our keyboard modality state with `hadKeyboardEvent`.\n * If the most recent user interaction was via the keyboard;\n * and the key press did not include a meta, alt/option, or control key;\n * then the modality is keyboard. Otherwise, the modality is not keyboard.\n * @param {KeyboardEvent} event\n */\nfunction handleKeyDown(event) {\n if (event.metaKey || event.altKey || event.ctrlKey) {\n return;\n }\n hadKeyboardEvent = true;\n}\n\n/**\n * If at any point a user clicks with a pointing device, ensure that we change\n * the modality away from keyboard.\n * This avoids the situation where a user presses a key on an already focused\n * element, and then clicks on a different element, focusing it with a\n * pointing device, while we still think we're in keyboard modality.\n */\nfunction handlePointerDown() {\n hadKeyboardEvent = false;\n}\nfunction handleVisibilityChange() {\n if (this.visibilityState === 'hidden') {\n // If the tab becomes active again, the browser will handle calling focus\n // on the element (Safari actually calls it twice).\n // If this tab change caused a blur on an element with focus-visible,\n // re-apply the class when the user switches back to the tab.\n if (hadFocusVisibleRecently) {\n hadKeyboardEvent = true;\n }\n }\n}\nfunction prepare(doc) {\n doc.addEventListener('keydown', handleKeyDown, true);\n doc.addEventListener('mousedown', handlePointerDown, true);\n doc.addEventListener('pointerdown', handlePointerDown, true);\n doc.addEventListener('touchstart', handlePointerDown, true);\n doc.addEventListener('visibilitychange', handleVisibilityChange, true);\n}\nexport function teardown(doc) {\n doc.removeEventListener('keydown', handleKeyDown, true);\n doc.removeEventListener('mousedown', handlePointerDown, true);\n doc.removeEventListener('pointerdown', handlePointerDown, true);\n doc.removeEventListener('touchstart', handlePointerDown, true);\n doc.removeEventListener('visibilitychange', handleVisibilityChange, true);\n}\nfunction isFocusVisible(event) {\n const {\n target\n } = event;\n try {\n return target.matches(':focus-visible');\n } catch (error) {\n // Browsers not implementing :focus-visible will throw a SyntaxError.\n // We use our own heuristic for those browsers.\n // Rethrow might be better if it's not the expected error but do we really\n // want to crash if focus-visible malfunctioned?\n }\n\n // No need for validFocusTarget check. The user does that by attaching it to\n // focusable events only.\n return hadKeyboardEvent || focusTriggersKeyboardModality(target);\n}\nexport default function useIsFocusVisible() {\n const ref = React.useCallback(node => {\n if (node != null) {\n prepare(node.ownerDocument);\n }\n }, []);\n const isFocusVisibleRef = React.useRef(false);\n\n /**\n * Should be called if a blur event is fired\n */\n function handleBlurVisible() {\n // checking against potential state variable does not suffice if we focus and blur synchronously.\n // React wouldn't have time to trigger a re-render so `focusVisible` would be stale.\n // Ideally we would adjust `isFocusVisible(event)` to look at `relatedTarget` for blur events.\n // This doesn't work in IE11 due to https://github.com/facebook/react/issues/3751\n // TODO: check again if React releases their internal changes to focus event handling (https://github.com/facebook/react/pull/19186).\n if (isFocusVisibleRef.current) {\n // To detect a tab/window switch, we look for a blur event followed\n // rapidly by a visibility change.\n // If we don't see a visibility change within 100ms, it's probably a\n // regular focus change.\n hadFocusVisibleRecently = true;\n hadFocusVisibleRecentlyTimeout.start(100, () => {\n hadFocusVisibleRecently = false;\n });\n isFocusVisibleRef.current = false;\n return true;\n }\n return false;\n }\n\n /**\n * Should be called if a blur event is fired\n */\n function handleFocusVisible(event) {\n if (isFocusVisible(event)) {\n isFocusVisibleRef.current = true;\n return true;\n }\n return false;\n }\n return {\n isFocusVisibleRef,\n onFocus: handleFocusVisible,\n onBlur: handleBlurVisible,\n ref\n };\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\n/**\n * Add keys, values of `defaultProps` that does not exist in `props`\n * @param {object} defaultProps\n * @param {object} props\n * @returns {object} resolved props\n */\nexport default function resolveProps(defaultProps, props) {\n const output = _extends({}, props);\n Object.keys(defaultProps).forEach(propName => {\n if (propName.toString().match(/^(components|slots)$/)) {\n output[propName] = _extends({}, defaultProps[propName], output[propName]);\n } else if (propName.toString().match(/^(componentsProps|slotProps)$/)) {\n const defaultSlotProps = defaultProps[propName] || {};\n const slotProps = props[propName];\n output[propName] = {};\n if (!slotProps || !Object.keys(slotProps)) {\n // Reduce the iteration if the slot props is empty\n output[propName] = defaultSlotProps;\n } else if (!defaultSlotProps || !Object.keys(defaultSlotProps)) {\n // Reduce the iteration if the default slot props is empty\n output[propName] = slotProps;\n } else {\n output[propName] = _extends({}, slotProps);\n Object.keys(defaultSlotProps).forEach(slotPropName => {\n output[propName][slotPropName] = resolveProps(defaultSlotProps[slotPropName], slotProps[slotPropName]);\n });\n }\n } else if (output[propName] === undefined) {\n output[propName] = defaultProps[propName];\n }\n });\n return output;\n}","export default function composeClasses(slots, getUtilityClass, classes = undefined) {\n const output = {};\n Object.keys(slots).forEach(\n // `Object.keys(slots)` can't be wider than `T` because we infer `T` from `slots`.\n // @ts-expect-error https://github.com/microsoft/TypeScript/pull/12253#issuecomment-263132208\n slot => {\n output[slot] = slots[slot].reduce((acc, key) => {\n if (key) {\n const utilityClass = getUtilityClass(key);\n if (utilityClass !== '') {\n acc.push(utilityClass);\n }\n if (classes && classes[key]) {\n acc.push(classes[key]);\n }\n }\n return acc;\n }, []).join(' ');\n });\n return output;\n}","const defaultGenerator = componentName => componentName;\nconst createClassNameGenerator = () => {\n let generate = defaultGenerator;\n return {\n configure(generator) {\n generate = generator;\n },\n generate(componentName) {\n return generate(componentName);\n },\n reset() {\n generate = defaultGenerator;\n }\n };\n};\nconst ClassNameGenerator = createClassNameGenerator();\nexport default ClassNameGenerator;","import ClassNameGenerator from '../ClassNameGenerator';\nexport const globalStateClasses = {\n active: 'active',\n checked: 'checked',\n completed: 'completed',\n disabled: 'disabled',\n error: 'error',\n expanded: 'expanded',\n focused: 'focused',\n focusVisible: 'focusVisible',\n open: 'open',\n readOnly: 'readOnly',\n required: 'required',\n selected: 'selected'\n};\nexport default function generateUtilityClass(componentName, slot, globalStatePrefix = 'Mui') {\n const globalStateClass = globalStateClasses[slot];\n return globalStateClass ? `${globalStatePrefix}-${globalStateClass}` : `${ClassNameGenerator.generate(componentName)}-${slot}`;\n}\nexport function isGlobalState(slot) {\n return globalStateClasses[slot] !== undefined;\n}","import generateUtilityClass from '../generateUtilityClass';\nexport default function generateUtilityClasses(componentName, slots, globalStatePrefix = 'Mui') {\n const result = {};\n slots.forEach(slot => {\n result[slot] = generateUtilityClass(componentName, slot, globalStatePrefix);\n });\n return result;\n}","function clamp(val, min = Number.MIN_SAFE_INTEGER, max = Number.MAX_SAFE_INTEGER) {\n return Math.max(min, Math.min(val, max));\n}\nexport default clamp;","export default function _objectWithoutPropertiesLoose(source, excluded) {\n if (source == null) return {};\n var target = {};\n var sourceKeys = Object.keys(source);\n var key, i;\n for (i = 0; i < sourceKeys.length; i++) {\n key = sourceKeys[i];\n if (excluded.indexOf(key) >= 0) continue;\n target[key] = source[key];\n }\n return target;\n}","import _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nconst _excluded = [\"values\", \"unit\", \"step\"];\n// Sorted ASC by size. That's important.\n// It can't be configured as it's used statically for propTypes.\nexport const breakpointKeys = ['xs', 'sm', 'md', 'lg', 'xl'];\nconst sortBreakpointsValues = values => {\n const breakpointsAsArray = Object.keys(values).map(key => ({\n key,\n val: values[key]\n })) || [];\n // Sort in ascending order\n breakpointsAsArray.sort((breakpoint1, breakpoint2) => breakpoint1.val - breakpoint2.val);\n return breakpointsAsArray.reduce((acc, obj) => {\n return _extends({}, acc, {\n [obj.key]: obj.val\n });\n }, {});\n};\n\n// Keep in mind that @media is inclusive by the CSS specification.\nexport default function createBreakpoints(breakpoints) {\n const {\n // The breakpoint **start** at this value.\n // For instance with the first breakpoint xs: [xs, sm).\n values = {\n xs: 0,\n // phone\n sm: 600,\n // tablet\n md: 900,\n // small laptop\n lg: 1200,\n // desktop\n xl: 1536 // large screen\n },\n unit = 'px',\n step = 5\n } = breakpoints,\n other = _objectWithoutPropertiesLoose(breakpoints, _excluded);\n const sortedValues = sortBreakpointsValues(values);\n const keys = Object.keys(sortedValues);\n function up(key) {\n const value = typeof values[key] === 'number' ? values[key] : key;\n return `@media (min-width:${value}${unit})`;\n }\n function down(key) {\n const value = typeof values[key] === 'number' ? values[key] : key;\n return `@media (max-width:${value - step / 100}${unit})`;\n }\n function between(start, end) {\n const endIndex = keys.indexOf(end);\n return `@media (min-width:${typeof values[start] === 'number' ? values[start] : start}${unit}) and ` + `(max-width:${(endIndex !== -1 && typeof values[keys[endIndex]] === 'number' ? values[keys[endIndex]] : end) - step / 100}${unit})`;\n }\n function only(key) {\n if (keys.indexOf(key) + 1 < keys.length) {\n return between(key, keys[keys.indexOf(key) + 1]);\n }\n return up(key);\n }\n function not(key) {\n // handle first and last key separately, for better readability\n const keyIndex = keys.indexOf(key);\n if (keyIndex === 0) {\n return up(keys[1]);\n }\n if (keyIndex === keys.length - 1) {\n return down(keys[keyIndex]);\n }\n return between(key, keys[keys.indexOf(key) + 1]).replace('@media', '@media not all and');\n }\n return _extends({\n keys,\n values: sortedValues,\n up,\n down,\n between,\n only,\n not,\n unit\n }, other);\n}","const shape = {\n borderRadius: 4\n};\nexport default shape;","import PropTypes from 'prop-types';\nconst responsivePropType = process.env.NODE_ENV !== 'production' ? PropTypes.oneOfType([PropTypes.number, PropTypes.string, PropTypes.object, PropTypes.array]) : {};\nexport default responsivePropType;","import deepmerge from '@mui/utils/deepmerge';\nfunction merge(acc, item) {\n if (!item) {\n return acc;\n }\n return deepmerge(acc, item, {\n clone: false // No need to clone deep, it's way faster.\n });\n}\nexport default merge;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport PropTypes from 'prop-types';\nimport deepmerge from '@mui/utils/deepmerge';\nimport merge from './merge';\n\n// The breakpoint **start** at this value.\n// For instance with the first breakpoint xs: [xs, sm[.\nexport const values = {\n xs: 0,\n // phone\n sm: 600,\n // tablet\n md: 900,\n // small laptop\n lg: 1200,\n // desktop\n xl: 1536 // large screen\n};\nconst defaultBreakpoints = {\n // Sorted ASC by size. That's important.\n // It can't be configured as it's used statically for propTypes.\n keys: ['xs', 'sm', 'md', 'lg', 'xl'],\n up: key => `@media (min-width:${values[key]}px)`\n};\nexport function handleBreakpoints(props, propValue, styleFromPropValue) {\n const theme = props.theme || {};\n if (Array.isArray(propValue)) {\n const themeBreakpoints = theme.breakpoints || defaultBreakpoints;\n return propValue.reduce((acc, item, index) => {\n acc[themeBreakpoints.up(themeBreakpoints.keys[index])] = styleFromPropValue(propValue[index]);\n return acc;\n }, {});\n }\n if (typeof propValue === 'object') {\n const themeBreakpoints = theme.breakpoints || defaultBreakpoints;\n return Object.keys(propValue).reduce((acc, breakpoint) => {\n // key is breakpoint\n if (Object.keys(themeBreakpoints.values || values).indexOf(breakpoint) !== -1) {\n const mediaKey = themeBreakpoints.up(breakpoint);\n acc[mediaKey] = styleFromPropValue(propValue[breakpoint], breakpoint);\n } else {\n const cssKey = breakpoint;\n acc[cssKey] = propValue[cssKey];\n }\n return acc;\n }, {});\n }\n const output = styleFromPropValue(propValue);\n return output;\n}\nfunction breakpoints(styleFunction) {\n // false positive\n // eslint-disable-next-line react/function-component-definition\n const newStyleFunction = props => {\n const theme = props.theme || {};\n const base = styleFunction(props);\n const themeBreakpoints = theme.breakpoints || defaultBreakpoints;\n const extended = themeBreakpoints.keys.reduce((acc, key) => {\n if (props[key]) {\n acc = acc || {};\n acc[themeBreakpoints.up(key)] = styleFunction(_extends({\n theme\n }, props[key]));\n }\n return acc;\n }, null);\n return merge(base, extended);\n };\n newStyleFunction.propTypes = process.env.NODE_ENV !== 'production' ? _extends({}, styleFunction.propTypes, {\n xs: PropTypes.object,\n sm: PropTypes.object,\n md: PropTypes.object,\n lg: PropTypes.object,\n xl: PropTypes.object\n }) : {};\n newStyleFunction.filterProps = ['xs', 'sm', 'md', 'lg', 'xl', ...styleFunction.filterProps];\n return newStyleFunction;\n}\nexport function createEmptyBreakpointObject(breakpointsInput = {}) {\n var _breakpointsInput$key;\n const breakpointsInOrder = (_breakpointsInput$key = breakpointsInput.keys) == null ? void 0 : _breakpointsInput$key.reduce((acc, key) => {\n const breakpointStyleKey = breakpointsInput.up(key);\n acc[breakpointStyleKey] = {};\n return acc;\n }, {});\n return breakpointsInOrder || {};\n}\nexport function removeUnusedBreakpoints(breakpointKeys, style) {\n return breakpointKeys.reduce((acc, key) => {\n const breakpointOutput = acc[key];\n const isBreakpointUnused = !breakpointOutput || Object.keys(breakpointOutput).length === 0;\n if (isBreakpointUnused) {\n delete acc[key];\n }\n return acc;\n }, style);\n}\nexport function mergeBreakpointsInOrder(breakpointsInput, ...styles) {\n const emptyBreakpoints = createEmptyBreakpointObject(breakpointsInput);\n const mergedOutput = [emptyBreakpoints, ...styles].reduce((prev, next) => deepmerge(prev, next), {});\n return removeUnusedBreakpoints(Object.keys(emptyBreakpoints), mergedOutput);\n}\n\n// compute base for responsive values; e.g.,\n// [1,2,3] => {xs: true, sm: true, md: true}\n// {xs: 1, sm: 2, md: 3} => {xs: true, sm: true, md: true}\nexport function computeBreakpointsBase(breakpointValues, themeBreakpoints) {\n // fixed value\n if (typeof breakpointValues !== 'object') {\n return {};\n }\n const base = {};\n const breakpointsKeys = Object.keys(themeBreakpoints);\n if (Array.isArray(breakpointValues)) {\n breakpointsKeys.forEach((breakpoint, i) => {\n if (i < breakpointValues.length) {\n base[breakpoint] = true;\n }\n });\n } else {\n breakpointsKeys.forEach(breakpoint => {\n if (breakpointValues[breakpoint] != null) {\n base[breakpoint] = true;\n }\n });\n }\n return base;\n}\nexport function resolveBreakpointValues({\n values: breakpointValues,\n breakpoints: themeBreakpoints,\n base: customBase\n}) {\n const base = customBase || computeBreakpointsBase(breakpointValues, themeBreakpoints);\n const keys = Object.keys(base);\n if (keys.length === 0) {\n return breakpointValues;\n }\n let previous;\n return keys.reduce((acc, breakpoint, i) => {\n if (Array.isArray(breakpointValues)) {\n acc[breakpoint] = breakpointValues[i] != null ? breakpointValues[i] : breakpointValues[previous];\n previous = i;\n } else if (typeof breakpointValues === 'object') {\n acc[breakpoint] = breakpointValues[breakpoint] != null ? breakpointValues[breakpoint] : breakpointValues[previous];\n previous = breakpoint;\n } else {\n acc[breakpoint] = breakpointValues;\n }\n return acc;\n }, {});\n}\nexport default breakpoints;","import capitalize from '@mui/utils/capitalize';\nimport responsivePropType from './responsivePropType';\nimport { handleBreakpoints } from './breakpoints';\nexport function getPath(obj, path, checkVars = true) {\n if (!path || typeof path !== 'string') {\n return null;\n }\n\n // Check if CSS variables are used\n if (obj && obj.vars && checkVars) {\n const val = `vars.${path}`.split('.').reduce((acc, item) => acc && acc[item] ? acc[item] : null, obj);\n if (val != null) {\n return val;\n }\n }\n return path.split('.').reduce((acc, item) => {\n if (acc && acc[item] != null) {\n return acc[item];\n }\n return null;\n }, obj);\n}\nexport function getStyleValue(themeMapping, transform, propValueFinal, userValue = propValueFinal) {\n let value;\n if (typeof themeMapping === 'function') {\n value = themeMapping(propValueFinal);\n } else if (Array.isArray(themeMapping)) {\n value = themeMapping[propValueFinal] || userValue;\n } else {\n value = getPath(themeMapping, propValueFinal) || userValue;\n }\n if (transform) {\n value = transform(value, userValue, themeMapping);\n }\n return value;\n}\nfunction style(options) {\n const {\n prop,\n cssProperty = options.prop,\n themeKey,\n transform\n } = options;\n\n // false positive\n // eslint-disable-next-line react/function-component-definition\n const fn = props => {\n if (props[prop] == null) {\n return null;\n }\n const propValue = props[prop];\n const theme = props.theme;\n const themeMapping = getPath(theme, themeKey) || {};\n const styleFromPropValue = propValueFinal => {\n let value = getStyleValue(themeMapping, transform, propValueFinal);\n if (propValueFinal === value && typeof propValueFinal === 'string') {\n // Haven't found value\n value = getStyleValue(themeMapping, transform, `${prop}${propValueFinal === 'default' ? '' : capitalize(propValueFinal)}`, propValueFinal);\n }\n if (cssProperty === false) {\n return value;\n }\n return {\n [cssProperty]: value\n };\n };\n return handleBreakpoints(props, propValue, styleFromPropValue);\n };\n fn.propTypes = process.env.NODE_ENV !== 'production' ? {\n [prop]: responsivePropType\n } : {};\n fn.filterProps = [prop];\n return fn;\n}\nexport default style;","export default function memoize(fn) {\n const cache = {};\n return arg => {\n if (cache[arg] === undefined) {\n cache[arg] = fn(arg);\n }\n return cache[arg];\n };\n}","import responsivePropType from './responsivePropType';\nimport { handleBreakpoints } from './breakpoints';\nimport { getPath } from './style';\nimport merge from './merge';\nimport memoize from './memoize';\nconst properties = {\n m: 'margin',\n p: 'padding'\n};\nconst directions = {\n t: 'Top',\n r: 'Right',\n b: 'Bottom',\n l: 'Left',\n x: ['Left', 'Right'],\n y: ['Top', 'Bottom']\n};\nconst aliases = {\n marginX: 'mx',\n marginY: 'my',\n paddingX: 'px',\n paddingY: 'py'\n};\n\n// memoize() impact:\n// From 300,000 ops/sec\n// To 350,000 ops/sec\nconst getCssProperties = memoize(prop => {\n // It's not a shorthand notation.\n if (prop.length > 2) {\n if (aliases[prop]) {\n prop = aliases[prop];\n } else {\n return [prop];\n }\n }\n const [a, b] = prop.split('');\n const property = properties[a];\n const direction = directions[b] || '';\n return Array.isArray(direction) ? direction.map(dir => property + dir) : [property + direction];\n});\nexport const marginKeys = ['m', 'mt', 'mr', 'mb', 'ml', 'mx', 'my', 'margin', 'marginTop', 'marginRight', 'marginBottom', 'marginLeft', 'marginX', 'marginY', 'marginInline', 'marginInlineStart', 'marginInlineEnd', 'marginBlock', 'marginBlockStart', 'marginBlockEnd'];\nexport const paddingKeys = ['p', 'pt', 'pr', 'pb', 'pl', 'px', 'py', 'padding', 'paddingTop', 'paddingRight', 'paddingBottom', 'paddingLeft', 'paddingX', 'paddingY', 'paddingInline', 'paddingInlineStart', 'paddingInlineEnd', 'paddingBlock', 'paddingBlockStart', 'paddingBlockEnd'];\nconst spacingKeys = [...marginKeys, ...paddingKeys];\nexport function createUnaryUnit(theme, themeKey, defaultValue, propName) {\n var _getPath;\n const themeSpacing = (_getPath = getPath(theme, themeKey, false)) != null ? _getPath : defaultValue;\n if (typeof themeSpacing === 'number') {\n return abs => {\n if (typeof abs === 'string') {\n return abs;\n }\n if (process.env.NODE_ENV !== 'production') {\n if (typeof abs !== 'number') {\n console.error(`MUI: Expected ${propName} argument to be a number or a string, got ${abs}.`);\n }\n }\n return themeSpacing * abs;\n };\n }\n if (Array.isArray(themeSpacing)) {\n return abs => {\n if (typeof abs === 'string') {\n return abs;\n }\n if (process.env.NODE_ENV !== 'production') {\n if (!Number.isInteger(abs)) {\n console.error([`MUI: The \\`theme.${themeKey}\\` array type cannot be combined with non integer values.` + `You should either use an integer value that can be used as index, or define the \\`theme.${themeKey}\\` as a number.`].join('\\n'));\n } else if (abs > themeSpacing.length - 1) {\n console.error([`MUI: The value provided (${abs}) overflows.`, `The supported values are: ${JSON.stringify(themeSpacing)}.`, `${abs} > ${themeSpacing.length - 1}, you need to add the missing values.`].join('\\n'));\n }\n }\n return themeSpacing[abs];\n };\n }\n if (typeof themeSpacing === 'function') {\n return themeSpacing;\n }\n if (process.env.NODE_ENV !== 'production') {\n console.error([`MUI: The \\`theme.${themeKey}\\` value (${themeSpacing}) is invalid.`, 'It should be a number, an array or a function.'].join('\\n'));\n }\n return () => undefined;\n}\nexport function createUnarySpacing(theme) {\n return createUnaryUnit(theme, 'spacing', 8, 'spacing');\n}\nexport function getValue(transformer, propValue) {\n if (typeof propValue === 'string' || propValue == null) {\n return propValue;\n }\n const abs = Math.abs(propValue);\n const transformed = transformer(abs);\n if (propValue >= 0) {\n return transformed;\n }\n if (typeof transformed === 'number') {\n return -transformed;\n }\n return `-${transformed}`;\n}\nexport function getStyleFromPropValue(cssProperties, transformer) {\n return propValue => cssProperties.reduce((acc, cssProperty) => {\n acc[cssProperty] = getValue(transformer, propValue);\n return acc;\n }, {});\n}\nfunction resolveCssProperty(props, keys, prop, transformer) {\n // Using a hash computation over an array iteration could be faster, but with only 28 items,\n // it's doesn't worth the bundle size.\n if (keys.indexOf(prop) === -1) {\n return null;\n }\n const cssProperties = getCssProperties(prop);\n const styleFromPropValue = getStyleFromPropValue(cssProperties, transformer);\n const propValue = props[prop];\n return handleBreakpoints(props, propValue, styleFromPropValue);\n}\nfunction style(props, keys) {\n const transformer = createUnarySpacing(props.theme);\n return Object.keys(props).map(prop => resolveCssProperty(props, keys, prop, transformer)).reduce(merge, {});\n}\nexport function margin(props) {\n return style(props, marginKeys);\n}\nmargin.propTypes = process.env.NODE_ENV !== 'production' ? marginKeys.reduce((obj, key) => {\n obj[key] = responsivePropType;\n return obj;\n}, {}) : {};\nmargin.filterProps = marginKeys;\nexport function padding(props) {\n return style(props, paddingKeys);\n}\npadding.propTypes = process.env.NODE_ENV !== 'production' ? paddingKeys.reduce((obj, key) => {\n obj[key] = responsivePropType;\n return obj;\n}, {}) : {};\npadding.filterProps = paddingKeys;\nfunction spacing(props) {\n return style(props, spacingKeys);\n}\nspacing.propTypes = process.env.NODE_ENV !== 'production' ? spacingKeys.reduce((obj, key) => {\n obj[key] = responsivePropType;\n return obj;\n}, {}) : {};\nspacing.filterProps = spacingKeys;\nexport default spacing;","import { createUnarySpacing } from '../spacing';\n\n// The different signatures imply different meaning for their arguments that can't be expressed structurally.\n// We express the difference with variable names.\n\nexport default function createSpacing(spacingInput = 8) {\n // Already transformed.\n if (spacingInput.mui) {\n return spacingInput;\n }\n\n // Material Design layouts are visually balanced. Most measurements align to an 8dp grid, which aligns both spacing and the overall layout.\n // Smaller components, such as icons, can align to a 4dp grid.\n // https://m2.material.io/design/layout/understanding-layout.html\n const transform = createUnarySpacing({\n spacing: spacingInput\n });\n const spacing = (...argsInput) => {\n if (process.env.NODE_ENV !== 'production') {\n if (!(argsInput.length <= 4)) {\n console.error(`MUI: Too many arguments provided, expected between 0 and 4, got ${argsInput.length}`);\n }\n }\n const args = argsInput.length === 0 ? [1] : argsInput;\n return args.map(argument => {\n const output = transform(argument);\n return typeof output === 'number' ? `${output}px` : output;\n }).join(' ');\n };\n spacing.mui = true;\n return spacing;\n}","import merge from './merge';\nfunction compose(...styles) {\n const handlers = styles.reduce((acc, style) => {\n style.filterProps.forEach(prop => {\n acc[prop] = style;\n });\n return acc;\n }, {});\n\n // false positive\n // eslint-disable-next-line react/function-component-definition\n const fn = props => {\n return Object.keys(props).reduce((acc, prop) => {\n if (handlers[prop]) {\n return merge(acc, handlers[prop](props));\n }\n return acc;\n }, {});\n };\n fn.propTypes = process.env.NODE_ENV !== 'production' ? styles.reduce((acc, style) => Object.assign(acc, style.propTypes), {}) : {};\n fn.filterProps = styles.reduce((acc, style) => acc.concat(style.filterProps), []);\n return fn;\n}\nexport default compose;","import responsivePropType from './responsivePropType';\nimport style from './style';\nimport compose from './compose';\nimport { createUnaryUnit, getValue } from './spacing';\nimport { handleBreakpoints } from './breakpoints';\nexport function borderTransform(value) {\n if (typeof value !== 'number') {\n return value;\n }\n return `${value}px solid`;\n}\nfunction createBorderStyle(prop, transform) {\n return style({\n prop,\n themeKey: 'borders',\n transform\n });\n}\nexport const border = createBorderStyle('border', borderTransform);\nexport const borderTop = createBorderStyle('borderTop', borderTransform);\nexport const borderRight = createBorderStyle('borderRight', borderTransform);\nexport const borderBottom = createBorderStyle('borderBottom', borderTransform);\nexport const borderLeft = createBorderStyle('borderLeft', borderTransform);\nexport const borderColor = createBorderStyle('borderColor');\nexport const borderTopColor = createBorderStyle('borderTopColor');\nexport const borderRightColor = createBorderStyle('borderRightColor');\nexport const borderBottomColor = createBorderStyle('borderBottomColor');\nexport const borderLeftColor = createBorderStyle('borderLeftColor');\nexport const outline = createBorderStyle('outline', borderTransform);\nexport const outlineColor = createBorderStyle('outlineColor');\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const borderRadius = props => {\n if (props.borderRadius !== undefined && props.borderRadius !== null) {\n const transformer = createUnaryUnit(props.theme, 'shape.borderRadius', 4, 'borderRadius');\n const styleFromPropValue = propValue => ({\n borderRadius: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.borderRadius, styleFromPropValue);\n }\n return null;\n};\nborderRadius.propTypes = process.env.NODE_ENV !== 'production' ? {\n borderRadius: responsivePropType\n} : {};\nborderRadius.filterProps = ['borderRadius'];\nconst borders = compose(border, borderTop, borderRight, borderBottom, borderLeft, borderColor, borderTopColor, borderRightColor, borderBottomColor, borderLeftColor, borderRadius, outline, outlineColor);\nexport default borders;","import style from './style';\nimport compose from './compose';\nimport { createUnaryUnit, getValue } from './spacing';\nimport { handleBreakpoints } from './breakpoints';\nimport responsivePropType from './responsivePropType';\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const gap = props => {\n if (props.gap !== undefined && props.gap !== null) {\n const transformer = createUnaryUnit(props.theme, 'spacing', 8, 'gap');\n const styleFromPropValue = propValue => ({\n gap: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.gap, styleFromPropValue);\n }\n return null;\n};\ngap.propTypes = process.env.NODE_ENV !== 'production' ? {\n gap: responsivePropType\n} : {};\ngap.filterProps = ['gap'];\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const columnGap = props => {\n if (props.columnGap !== undefined && props.columnGap !== null) {\n const transformer = createUnaryUnit(props.theme, 'spacing', 8, 'columnGap');\n const styleFromPropValue = propValue => ({\n columnGap: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.columnGap, styleFromPropValue);\n }\n return null;\n};\ncolumnGap.propTypes = process.env.NODE_ENV !== 'production' ? {\n columnGap: responsivePropType\n} : {};\ncolumnGap.filterProps = ['columnGap'];\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const rowGap = props => {\n if (props.rowGap !== undefined && props.rowGap !== null) {\n const transformer = createUnaryUnit(props.theme, 'spacing', 8, 'rowGap');\n const styleFromPropValue = propValue => ({\n rowGap: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.rowGap, styleFromPropValue);\n }\n return null;\n};\nrowGap.propTypes = process.env.NODE_ENV !== 'production' ? {\n rowGap: responsivePropType\n} : {};\nrowGap.filterProps = ['rowGap'];\nexport const gridColumn = style({\n prop: 'gridColumn'\n});\nexport const gridRow = style({\n prop: 'gridRow'\n});\nexport const gridAutoFlow = style({\n prop: 'gridAutoFlow'\n});\nexport const gridAutoColumns = style({\n prop: 'gridAutoColumns'\n});\nexport const gridAutoRows = style({\n prop: 'gridAutoRows'\n});\nexport const gridTemplateColumns = style({\n prop: 'gridTemplateColumns'\n});\nexport const gridTemplateRows = style({\n prop: 'gridTemplateRows'\n});\nexport const gridTemplateAreas = style({\n prop: 'gridTemplateAreas'\n});\nexport const gridArea = style({\n prop: 'gridArea'\n});\nconst grid = compose(gap, columnGap, rowGap, gridColumn, gridRow, gridAutoFlow, gridAutoColumns, gridAutoRows, gridTemplateColumns, gridTemplateRows, gridTemplateAreas, gridArea);\nexport default grid;","import style from './style';\nimport compose from './compose';\nexport function paletteTransform(value, userValue) {\n if (userValue === 'grey') {\n return userValue;\n }\n return value;\n}\nexport const color = style({\n prop: 'color',\n themeKey: 'palette',\n transform: paletteTransform\n});\nexport const bgcolor = style({\n prop: 'bgcolor',\n cssProperty: 'backgroundColor',\n themeKey: 'palette',\n transform: paletteTransform\n});\nexport const backgroundColor = style({\n prop: 'backgroundColor',\n themeKey: 'palette',\n transform: paletteTransform\n});\nconst palette = compose(color, bgcolor, backgroundColor);\nexport default palette;","import style from './style';\nimport compose from './compose';\nimport { handleBreakpoints, values as breakpointsValues } from './breakpoints';\nexport function sizingTransform(value) {\n return value <= 1 && value !== 0 ? `${value * 100}%` : value;\n}\nexport const width = style({\n prop: 'width',\n transform: sizingTransform\n});\nexport const maxWidth = props => {\n if (props.maxWidth !== undefined && props.maxWidth !== null) {\n const styleFromPropValue = propValue => {\n var _props$theme, _props$theme2;\n const breakpoint = ((_props$theme = props.theme) == null || (_props$theme = _props$theme.breakpoints) == null || (_props$theme = _props$theme.values) == null ? void 0 : _props$theme[propValue]) || breakpointsValues[propValue];\n if (!breakpoint) {\n return {\n maxWidth: sizingTransform(propValue)\n };\n }\n if (((_props$theme2 = props.theme) == null || (_props$theme2 = _props$theme2.breakpoints) == null ? void 0 : _props$theme2.unit) !== 'px') {\n return {\n maxWidth: `${breakpoint}${props.theme.breakpoints.unit}`\n };\n }\n return {\n maxWidth: breakpoint\n };\n };\n return handleBreakpoints(props, props.maxWidth, styleFromPropValue);\n }\n return null;\n};\nmaxWidth.filterProps = ['maxWidth'];\nexport const minWidth = style({\n prop: 'minWidth',\n transform: sizingTransform\n});\nexport const height = style({\n prop: 'height',\n transform: sizingTransform\n});\nexport const maxHeight = style({\n prop: 'maxHeight',\n transform: sizingTransform\n});\nexport const minHeight = style({\n prop: 'minHeight',\n transform: sizingTransform\n});\nexport const sizeWidth = style({\n prop: 'size',\n cssProperty: 'width',\n transform: sizingTransform\n});\nexport const sizeHeight = style({\n prop: 'size',\n cssProperty: 'height',\n transform: sizingTransform\n});\nexport const boxSizing = style({\n prop: 'boxSizing'\n});\nconst sizing = compose(width, maxWidth, minWidth, height, maxHeight, minHeight, boxSizing);\nexport default sizing;","import { padding, margin } from '../spacing';\nimport { borderRadius, borderTransform } from '../borders';\nimport { gap, rowGap, columnGap } from '../cssGrid';\nimport { paletteTransform } from '../palette';\nimport { maxWidth, sizingTransform } from '../sizing';\nconst defaultSxConfig = {\n // borders\n border: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderTop: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderRight: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderBottom: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderLeft: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderColor: {\n themeKey: 'palette'\n },\n borderTopColor: {\n themeKey: 'palette'\n },\n borderRightColor: {\n themeKey: 'palette'\n },\n borderBottomColor: {\n themeKey: 'palette'\n },\n borderLeftColor: {\n themeKey: 'palette'\n },\n outline: {\n themeKey: 'borders',\n transform: borderTransform\n },\n outlineColor: {\n themeKey: 'palette'\n },\n borderRadius: {\n themeKey: 'shape.borderRadius',\n style: borderRadius\n },\n // palette\n color: {\n themeKey: 'palette',\n transform: paletteTransform\n },\n bgcolor: {\n themeKey: 'palette',\n cssProperty: 'backgroundColor',\n transform: paletteTransform\n },\n backgroundColor: {\n themeKey: 'palette',\n transform: paletteTransform\n },\n // spacing\n p: {\n style: padding\n },\n pt: {\n style: padding\n },\n pr: {\n style: padding\n },\n pb: {\n style: padding\n },\n pl: {\n style: padding\n },\n px: {\n style: padding\n },\n py: {\n style: padding\n },\n padding: {\n style: padding\n },\n paddingTop: {\n style: padding\n },\n paddingRight: {\n style: padding\n },\n paddingBottom: {\n style: padding\n },\n paddingLeft: {\n style: padding\n },\n paddingX: {\n style: padding\n },\n paddingY: {\n style: padding\n },\n paddingInline: {\n style: padding\n },\n paddingInlineStart: {\n style: padding\n },\n paddingInlineEnd: {\n style: padding\n },\n paddingBlock: {\n style: padding\n },\n paddingBlockStart: {\n style: padding\n },\n paddingBlockEnd: {\n style: padding\n },\n m: {\n style: margin\n },\n mt: {\n style: margin\n },\n mr: {\n style: margin\n },\n mb: {\n style: margin\n },\n ml: {\n style: margin\n },\n mx: {\n style: margin\n },\n my: {\n style: margin\n },\n margin: {\n style: margin\n },\n marginTop: {\n style: margin\n },\n marginRight: {\n style: margin\n },\n marginBottom: {\n style: margin\n },\n marginLeft: {\n style: margin\n },\n marginX: {\n style: margin\n },\n marginY: {\n style: margin\n },\n marginInline: {\n style: margin\n },\n marginInlineStart: {\n style: margin\n },\n marginInlineEnd: {\n style: margin\n },\n marginBlock: {\n style: margin\n },\n marginBlockStart: {\n style: margin\n },\n marginBlockEnd: {\n style: margin\n },\n // display\n displayPrint: {\n cssProperty: false,\n transform: value => ({\n '@media print': {\n display: value\n }\n })\n },\n display: {},\n overflow: {},\n textOverflow: {},\n visibility: {},\n whiteSpace: {},\n // flexbox\n flexBasis: {},\n flexDirection: {},\n flexWrap: {},\n justifyContent: {},\n alignItems: {},\n alignContent: {},\n order: {},\n flex: {},\n flexGrow: {},\n flexShrink: {},\n alignSelf: {},\n justifyItems: {},\n justifySelf: {},\n // grid\n gap: {\n style: gap\n },\n rowGap: {\n style: rowGap\n },\n columnGap: {\n style: columnGap\n },\n gridColumn: {},\n gridRow: {},\n gridAutoFlow: {},\n gridAutoColumns: {},\n gridAutoRows: {},\n gridTemplateColumns: {},\n gridTemplateRows: {},\n gridTemplateAreas: {},\n gridArea: {},\n // positions\n position: {},\n zIndex: {\n themeKey: 'zIndex'\n },\n top: {},\n right: {},\n bottom: {},\n left: {},\n // shadows\n boxShadow: {\n themeKey: 'shadows'\n },\n // sizing\n width: {\n transform: sizingTransform\n },\n maxWidth: {\n style: maxWidth\n },\n minWidth: {\n transform: sizingTransform\n },\n height: {\n transform: sizingTransform\n },\n maxHeight: {\n transform: sizingTransform\n },\n minHeight: {\n transform: sizingTransform\n },\n boxSizing: {},\n // typography\n fontFamily: {\n themeKey: 'typography'\n },\n fontSize: {\n themeKey: 'typography'\n },\n fontStyle: {\n themeKey: 'typography'\n },\n fontWeight: {\n themeKey: 'typography'\n },\n letterSpacing: {},\n textTransform: {},\n lineHeight: {},\n textAlign: {},\n typography: {\n cssProperty: false,\n themeKey: 'typography'\n }\n};\nexport default defaultSxConfig;","import capitalize from '@mui/utils/capitalize';\nimport merge from '../merge';\nimport { getPath, getStyleValue as getValue } from '../style';\nimport { handleBreakpoints, createEmptyBreakpointObject, removeUnusedBreakpoints } from '../breakpoints';\nimport defaultSxConfig from './defaultSxConfig';\nfunction objectsHaveSameKeys(...objects) {\n const allKeys = objects.reduce((keys, object) => keys.concat(Object.keys(object)), []);\n const union = new Set(allKeys);\n return objects.every(object => union.size === Object.keys(object).length);\n}\nfunction callIfFn(maybeFn, arg) {\n return typeof maybeFn === 'function' ? maybeFn(arg) : maybeFn;\n}\n\n// eslint-disable-next-line @typescript-eslint/naming-convention\nexport function unstable_createStyleFunctionSx() {\n function getThemeValue(prop, val, theme, config) {\n const props = {\n [prop]: val,\n theme\n };\n const options = config[prop];\n if (!options) {\n return {\n [prop]: val\n };\n }\n const {\n cssProperty = prop,\n themeKey,\n transform,\n style\n } = options;\n if (val == null) {\n return null;\n }\n\n // TODO v6: remove, see https://github.com/mui/material-ui/pull/38123\n if (themeKey === 'typography' && val === 'inherit') {\n return {\n [prop]: val\n };\n }\n const themeMapping = getPath(theme, themeKey) || {};\n if (style) {\n return style(props);\n }\n const styleFromPropValue = propValueFinal => {\n let value = getValue(themeMapping, transform, propValueFinal);\n if (propValueFinal === value && typeof propValueFinal === 'string') {\n // Haven't found value\n value = getValue(themeMapping, transform, `${prop}${propValueFinal === 'default' ? '' : capitalize(propValueFinal)}`, propValueFinal);\n }\n if (cssProperty === false) {\n return value;\n }\n return {\n [cssProperty]: value\n };\n };\n return handleBreakpoints(props, val, styleFromPropValue);\n }\n function styleFunctionSx(props) {\n var _theme$unstable_sxCon;\n const {\n sx,\n theme = {}\n } = props || {};\n if (!sx) {\n return null; // Emotion & styled-components will neglect null\n }\n const config = (_theme$unstable_sxCon = theme.unstable_sxConfig) != null ? _theme$unstable_sxCon : defaultSxConfig;\n\n /*\n * Receive `sxInput` as object or callback\n * and then recursively check keys & values to create media query object styles.\n * (the result will be used in `styled`)\n */\n function traverse(sxInput) {\n let sxObject = sxInput;\n if (typeof sxInput === 'function') {\n sxObject = sxInput(theme);\n } else if (typeof sxInput !== 'object') {\n // value\n return sxInput;\n }\n if (!sxObject) {\n return null;\n }\n const emptyBreakpoints = createEmptyBreakpointObject(theme.breakpoints);\n const breakpointsKeys = Object.keys(emptyBreakpoints);\n let css = emptyBreakpoints;\n Object.keys(sxObject).forEach(styleKey => {\n const value = callIfFn(sxObject[styleKey], theme);\n if (value !== null && value !== undefined) {\n if (typeof value === 'object') {\n if (config[styleKey]) {\n css = merge(css, getThemeValue(styleKey, value, theme, config));\n } else {\n const breakpointsValues = handleBreakpoints({\n theme\n }, value, x => ({\n [styleKey]: x\n }));\n if (objectsHaveSameKeys(breakpointsValues, value)) {\n css[styleKey] = styleFunctionSx({\n sx: value,\n theme\n });\n } else {\n css = merge(css, breakpointsValues);\n }\n }\n } else {\n css = merge(css, getThemeValue(styleKey, value, theme, config));\n }\n }\n });\n return removeUnusedBreakpoints(breakpointsKeys, css);\n }\n return Array.isArray(sx) ? sx.map(traverse) : traverse(sx);\n }\n return styleFunctionSx;\n}\nconst styleFunctionSx = unstable_createStyleFunctionSx();\nstyleFunctionSx.filterProps = ['sx'];\nexport default styleFunctionSx;","/**\n * A universal utility to style components with multiple color modes. Always use it from the theme object.\n * It works with:\n * - [Basic theme](https://mui.com/material-ui/customization/dark-mode/)\n * - [CSS theme variables](https://mui.com/material-ui/experimental-api/css-theme-variables/overview/)\n * - Zero-runtime engine\n *\n * Tips: Use an array over object spread and place `theme.applyStyles()` last.\n *\n * ✅ [{ background: '#e5e5e5' }, theme.applyStyles('dark', { background: '#1c1c1c' })]\n *\n * 🚫 { background: '#e5e5e5', ...theme.applyStyles('dark', { background: '#1c1c1c' })}\n *\n * @example\n * 1. using with `styled`:\n * ```jsx\n * const Component = styled('div')(({ theme }) => [\n * { background: '#e5e5e5' },\n * theme.applyStyles('dark', {\n * background: '#1c1c1c',\n * color: '#fff',\n * }),\n * ]);\n * ```\n *\n * @example\n * 2. using with `sx` prop:\n * ```jsx\n * [\n * { background: '#e5e5e5' },\n * theme.applyStyles('dark', {\n * background: '#1c1c1c',\n * color: '#fff',\n * }),\n * ]}\n * />\n * ```\n *\n * @example\n * 3. theming a component:\n * ```jsx\n * extendTheme({\n * components: {\n * MuiButton: {\n * styleOverrides: {\n * root: ({ theme }) => [\n * { background: '#e5e5e5' },\n * theme.applyStyles('dark', {\n * background: '#1c1c1c',\n * color: '#fff',\n * }),\n * ],\n * },\n * }\n * }\n * })\n *```\n */\nexport default function applyStyles(key, styles) {\n // @ts-expect-error this is 'any' type\n const theme = this;\n if (theme.vars && typeof theme.getColorSchemeSelector === 'function') {\n // If CssVarsProvider is used as a provider,\n // returns '* :where([data-mui-color-scheme=\"light|dark\"]) &'\n const selector = theme.getColorSchemeSelector(key).replace(/(\\[[^\\]]+\\])/, '*:where($1)');\n return {\n [selector]: styles\n };\n }\n if (theme.palette.mode === key) {\n return styles;\n }\n return {};\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"breakpoints\", \"palette\", \"spacing\", \"shape\"];\nimport deepmerge from '@mui/utils/deepmerge';\nimport createBreakpoints from './createBreakpoints';\nimport shape from './shape';\nimport createSpacing from './createSpacing';\nimport styleFunctionSx from '../styleFunctionSx/styleFunctionSx';\nimport defaultSxConfig from '../styleFunctionSx/defaultSxConfig';\nimport applyStyles from './applyStyles';\nfunction createTheme(options = {}, ...args) {\n const {\n breakpoints: breakpointsInput = {},\n palette: paletteInput = {},\n spacing: spacingInput,\n shape: shapeInput = {}\n } = options,\n other = _objectWithoutPropertiesLoose(options, _excluded);\n const breakpoints = createBreakpoints(breakpointsInput);\n const spacing = createSpacing(spacingInput);\n let muiTheme = deepmerge({\n breakpoints,\n direction: 'ltr',\n components: {},\n // Inject component definitions.\n palette: _extends({\n mode: 'light'\n }, paletteInput),\n spacing,\n shape: _extends({}, shape, shapeInput)\n }, other);\n muiTheme.applyStyles = applyStyles;\n muiTheme = args.reduce((acc, argument) => deepmerge(acc, argument), muiTheme);\n muiTheme.unstable_sxConfig = _extends({}, defaultSxConfig, other == null ? void 0 : other.unstable_sxConfig);\n muiTheme.unstable_sx = function sx(props) {\n return styleFunctionSx({\n sx: props,\n theme: this\n });\n };\n return muiTheme;\n}\nexport default createTheme;","'use client';\n\nimport * as React from 'react';\nimport { ThemeContext } from '@mui/styled-engine';\nfunction isObjectEmpty(obj) {\n return Object.keys(obj).length === 0;\n}\nfunction useTheme(defaultTheme = null) {\n const contextTheme = React.useContext(ThemeContext);\n return !contextTheme || isObjectEmpty(contextTheme) ? defaultTheme : contextTheme;\n}\nexport default useTheme;","'use client';\n\nimport createTheme from './createTheme';\nimport useThemeWithoutDefault from './useThemeWithoutDefault';\nexport const systemDefaultTheme = createTheme();\nfunction useTheme(defaultTheme = systemDefaultTheme) {\n return useThemeWithoutDefault(defaultTheme);\n}\nexport default useTheme;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"ownerState\"],\n _excluded2 = [\"variants\"],\n _excluded3 = [\"name\", \"slot\", \"skipVariantsResolver\", \"skipSx\", \"overridesResolver\"];\n/* eslint-disable no-underscore-dangle */\nimport styledEngineStyled, { internal_processStyles as processStyles } from '@mui/styled-engine';\nimport { isPlainObject } from '@mui/utils/deepmerge';\nimport capitalize from '@mui/utils/capitalize';\nimport getDisplayName from '@mui/utils/getDisplayName';\nimport createTheme from './createTheme';\nimport styleFunctionSx from './styleFunctionSx';\nfunction isEmpty(obj) {\n return Object.keys(obj).length === 0;\n}\n\n// https://github.com/emotion-js/emotion/blob/26ded6109fcd8ca9875cc2ce4564fee678a3f3c5/packages/styled/src/utils.js#L40\nfunction isStringTag(tag) {\n return typeof tag === 'string' &&\n // 96 is one less than the char code\n // for \"a\" so this is checking that\n // it's a lowercase character\n tag.charCodeAt(0) > 96;\n}\n\n// Update /system/styled/#api in case if this changes\nexport function shouldForwardProp(prop) {\n return prop !== 'ownerState' && prop !== 'theme' && prop !== 'sx' && prop !== 'as';\n}\nexport const systemDefaultTheme = createTheme();\nconst lowercaseFirstLetter = string => {\n if (!string) {\n return string;\n }\n return string.charAt(0).toLowerCase() + string.slice(1);\n};\nfunction resolveTheme({\n defaultTheme,\n theme,\n themeId\n}) {\n return isEmpty(theme) ? defaultTheme : theme[themeId] || theme;\n}\nfunction defaultOverridesResolver(slot) {\n if (!slot) {\n return null;\n }\n return (props, styles) => styles[slot];\n}\nfunction processStyleArg(callableStyle, _ref) {\n let {\n ownerState\n } = _ref,\n props = _objectWithoutPropertiesLoose(_ref, _excluded);\n const resolvedStylesArg = typeof callableStyle === 'function' ? callableStyle(_extends({\n ownerState\n }, props)) : callableStyle;\n if (Array.isArray(resolvedStylesArg)) {\n return resolvedStylesArg.flatMap(resolvedStyle => processStyleArg(resolvedStyle, _extends({\n ownerState\n }, props)));\n }\n if (!!resolvedStylesArg && typeof resolvedStylesArg === 'object' && Array.isArray(resolvedStylesArg.variants)) {\n const {\n variants = []\n } = resolvedStylesArg,\n otherStyles = _objectWithoutPropertiesLoose(resolvedStylesArg, _excluded2);\n let result = otherStyles;\n variants.forEach(variant => {\n let isMatch = true;\n if (typeof variant.props === 'function') {\n isMatch = variant.props(_extends({\n ownerState\n }, props, ownerState));\n } else {\n Object.keys(variant.props).forEach(key => {\n if ((ownerState == null ? void 0 : ownerState[key]) !== variant.props[key] && props[key] !== variant.props[key]) {\n isMatch = false;\n }\n });\n }\n if (isMatch) {\n if (!Array.isArray(result)) {\n result = [result];\n }\n result.push(typeof variant.style === 'function' ? variant.style(_extends({\n ownerState\n }, props, ownerState)) : variant.style);\n }\n });\n return result;\n }\n return resolvedStylesArg;\n}\nexport default function createStyled(input = {}) {\n const {\n themeId,\n defaultTheme = systemDefaultTheme,\n rootShouldForwardProp = shouldForwardProp,\n slotShouldForwardProp = shouldForwardProp\n } = input;\n const systemSx = props => {\n return styleFunctionSx(_extends({}, props, {\n theme: resolveTheme(_extends({}, props, {\n defaultTheme,\n themeId\n }))\n }));\n };\n systemSx.__mui_systemSx = true;\n return (tag, inputOptions = {}) => {\n // Filter out the `sx` style function from the previous styled component to prevent unnecessary styles generated by the composite components.\n processStyles(tag, styles => styles.filter(style => !(style != null && style.__mui_systemSx)));\n const {\n name: componentName,\n slot: componentSlot,\n skipVariantsResolver: inputSkipVariantsResolver,\n skipSx: inputSkipSx,\n // TODO v6: remove `lowercaseFirstLetter()` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n overridesResolver = defaultOverridesResolver(lowercaseFirstLetter(componentSlot))\n } = inputOptions,\n options = _objectWithoutPropertiesLoose(inputOptions, _excluded3);\n\n // if skipVariantsResolver option is defined, take the value, otherwise, true for root and false for other slots.\n const skipVariantsResolver = inputSkipVariantsResolver !== undefined ? inputSkipVariantsResolver :\n // TODO v6: remove `Root` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n componentSlot && componentSlot !== 'Root' && componentSlot !== 'root' || false;\n const skipSx = inputSkipSx || false;\n let label;\n if (process.env.NODE_ENV !== 'production') {\n if (componentName) {\n // TODO v6: remove `lowercaseFirstLetter()` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n label = `${componentName}-${lowercaseFirstLetter(componentSlot || 'Root')}`;\n }\n }\n let shouldForwardPropOption = shouldForwardProp;\n\n // TODO v6: remove `Root` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n if (componentSlot === 'Root' || componentSlot === 'root') {\n shouldForwardPropOption = rootShouldForwardProp;\n } else if (componentSlot) {\n // any other slot specified\n shouldForwardPropOption = slotShouldForwardProp;\n } else if (isStringTag(tag)) {\n // for string (html) tag, preserve the behavior in emotion & styled-components.\n shouldForwardPropOption = undefined;\n }\n const defaultStyledResolver = styledEngineStyled(tag, _extends({\n shouldForwardProp: shouldForwardPropOption,\n label\n }, options));\n const transformStyleArg = stylesArg => {\n // On the server Emotion doesn't use React.forwardRef for creating components, so the created\n // component stays as a function. This condition makes sure that we do not interpolate functions\n // which are basically components used as a selectors.\n if (typeof stylesArg === 'function' && stylesArg.__emotion_real !== stylesArg || isPlainObject(stylesArg)) {\n return props => processStyleArg(stylesArg, _extends({}, props, {\n theme: resolveTheme({\n theme: props.theme,\n defaultTheme,\n themeId\n })\n }));\n }\n return stylesArg;\n };\n const muiStyledResolver = (styleArg, ...expressions) => {\n let transformedStyleArg = transformStyleArg(styleArg);\n const expressionsWithDefaultTheme = expressions ? expressions.map(transformStyleArg) : [];\n if (componentName && overridesResolver) {\n expressionsWithDefaultTheme.push(props => {\n const theme = resolveTheme(_extends({}, props, {\n defaultTheme,\n themeId\n }));\n if (!theme.components || !theme.components[componentName] || !theme.components[componentName].styleOverrides) {\n return null;\n }\n const styleOverrides = theme.components[componentName].styleOverrides;\n const resolvedStyleOverrides = {};\n // TODO: v7 remove iteration and use `resolveStyleArg(styleOverrides[slot])` directly\n Object.entries(styleOverrides).forEach(([slotKey, slotStyle]) => {\n resolvedStyleOverrides[slotKey] = processStyleArg(slotStyle, _extends({}, props, {\n theme\n }));\n });\n return overridesResolver(props, resolvedStyleOverrides);\n });\n }\n if (componentName && !skipVariantsResolver) {\n expressionsWithDefaultTheme.push(props => {\n var _theme$components;\n const theme = resolveTheme(_extends({}, props, {\n defaultTheme,\n themeId\n }));\n const themeVariants = theme == null || (_theme$components = theme.components) == null || (_theme$components = _theme$components[componentName]) == null ? void 0 : _theme$components.variants;\n return processStyleArg({\n variants: themeVariants\n }, _extends({}, props, {\n theme\n }));\n });\n }\n if (!skipSx) {\n expressionsWithDefaultTheme.push(systemSx);\n }\n const numOfCustomFnsApplied = expressionsWithDefaultTheme.length - expressions.length;\n if (Array.isArray(styleArg) && numOfCustomFnsApplied > 0) {\n const placeholders = new Array(numOfCustomFnsApplied).fill('');\n // If the type is array, than we need to add placeholders in the template for the overrides, variants and the sx styles.\n transformedStyleArg = [...styleArg, ...placeholders];\n transformedStyleArg.raw = [...styleArg.raw, ...placeholders];\n }\n const Component = defaultStyledResolver(transformedStyleArg, ...expressionsWithDefaultTheme);\n if (process.env.NODE_ENV !== 'production') {\n let displayName;\n if (componentName) {\n displayName = `${componentName}${capitalize(componentSlot || '')}`;\n }\n if (displayName === undefined) {\n displayName = `Styled(${getDisplayName(tag)})`;\n }\n Component.displayName = displayName;\n }\n if (tag.muiName) {\n Component.muiName = tag.muiName;\n }\n return Component;\n };\n if (defaultStyledResolver.withConfig) {\n muiStyledResolver.withConfig = defaultStyledResolver.withConfig;\n }\n return muiStyledResolver;\n };\n}","import resolveProps from '@mui/utils/resolveProps';\nexport default function getThemeProps(params) {\n const {\n theme,\n name,\n props\n } = params;\n if (!theme || !theme.components || !theme.components[name] || !theme.components[name].defaultProps) {\n return props;\n }\n return resolveProps(theme.components[name].defaultProps, props);\n}","'use client';\n\nimport getThemeProps from './getThemeProps';\nimport useTheme from '../useTheme';\nexport default function useThemeProps({\n props,\n name,\n defaultTheme,\n themeId\n}) {\n let theme = useTheme(defaultTheme);\n if (themeId) {\n theme = theme[themeId] || theme;\n }\n const mergedProps = getThemeProps({\n theme,\n name,\n props\n });\n return mergedProps;\n}","import _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\n/* eslint-disable @typescript-eslint/naming-convention */\nimport clamp from '@mui/utils/clamp';\n/**\n * Returns a number whose value is limited to the given range.\n * @param {number} value The value to be clamped\n * @param {number} min The lower boundary of the output range\n * @param {number} max The upper boundary of the output range\n * @returns {number} A number in the range [min, max]\n */\nfunction clampWrapper(value, min = 0, max = 1) {\n if (process.env.NODE_ENV !== 'production') {\n if (value < min || value > max) {\n console.error(`MUI: The value provided ${value} is out of range [${min}, ${max}].`);\n }\n }\n return clamp(value, min, max);\n}\n\n/**\n * Converts a color from CSS hex format to CSS rgb format.\n * @param {string} color - Hex color, i.e. #nnn or #nnnnnn\n * @returns {string} A CSS rgb color string\n */\nexport function hexToRgb(color) {\n color = color.slice(1);\n const re = new RegExp(`.{1,${color.length >= 6 ? 2 : 1}}`, 'g');\n let colors = color.match(re);\n if (colors && colors[0].length === 1) {\n colors = colors.map(n => n + n);\n }\n return colors ? `rgb${colors.length === 4 ? 'a' : ''}(${colors.map((n, index) => {\n return index < 3 ? parseInt(n, 16) : Math.round(parseInt(n, 16) / 255 * 1000) / 1000;\n }).join(', ')})` : '';\n}\nfunction intToHex(int) {\n const hex = int.toString(16);\n return hex.length === 1 ? `0${hex}` : hex;\n}\n\n/**\n * Returns an object with the type and values of a color.\n *\n * Note: Does not support rgb % values.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @returns {object} - A MUI color object: {type: string, values: number[]}\n */\nexport function decomposeColor(color) {\n // Idempotent\n if (color.type) {\n return color;\n }\n if (color.charAt(0) === '#') {\n return decomposeColor(hexToRgb(color));\n }\n const marker = color.indexOf('(');\n const type = color.substring(0, marker);\n if (['rgb', 'rgba', 'hsl', 'hsla', 'color'].indexOf(type) === -1) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: Unsupported \\`${color}\\` color.\nThe following formats are supported: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color().` : _formatMuiErrorMessage(9, color));\n }\n let values = color.substring(marker + 1, color.length - 1);\n let colorSpace;\n if (type === 'color') {\n values = values.split(' ');\n colorSpace = values.shift();\n if (values.length === 4 && values[3].charAt(0) === '/') {\n values[3] = values[3].slice(1);\n }\n if (['srgb', 'display-p3', 'a98-rgb', 'prophoto-rgb', 'rec-2020'].indexOf(colorSpace) === -1) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: unsupported \\`${colorSpace}\\` color space.\nThe following color spaces are supported: srgb, display-p3, a98-rgb, prophoto-rgb, rec-2020.` : _formatMuiErrorMessage(10, colorSpace));\n }\n } else {\n values = values.split(',');\n }\n values = values.map(value => parseFloat(value));\n return {\n type,\n values,\n colorSpace\n };\n}\n\n/**\n * Returns a channel created from the input color.\n *\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @returns {string} - The channel for the color, that can be used in rgba or hsla colors\n */\nexport const colorChannel = color => {\n const decomposedColor = decomposeColor(color);\n return decomposedColor.values.slice(0, 3).map((val, idx) => decomposedColor.type.indexOf('hsl') !== -1 && idx !== 0 ? `${val}%` : val).join(' ');\n};\nexport const private_safeColorChannel = (color, warning) => {\n try {\n return colorChannel(color);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n};\n\n/**\n * Converts a color object with type and values to a string.\n * @param {object} color - Decomposed color\n * @param {string} color.type - One of: 'rgb', 'rgba', 'hsl', 'hsla', 'color'\n * @param {array} color.values - [n,n,n] or [n,n,n,n]\n * @returns {string} A CSS color string\n */\nexport function recomposeColor(color) {\n const {\n type,\n colorSpace\n } = color;\n let {\n values\n } = color;\n if (type.indexOf('rgb') !== -1) {\n // Only convert the first 3 values to int (i.e. not alpha)\n values = values.map((n, i) => i < 3 ? parseInt(n, 10) : n);\n } else if (type.indexOf('hsl') !== -1) {\n values[1] = `${values[1]}%`;\n values[2] = `${values[2]}%`;\n }\n if (type.indexOf('color') !== -1) {\n values = `${colorSpace} ${values.join(' ')}`;\n } else {\n values = `${values.join(', ')}`;\n }\n return `${type}(${values})`;\n}\n\n/**\n * Converts a color from CSS rgb format to CSS hex format.\n * @param {string} color - RGB color, i.e. rgb(n, n, n)\n * @returns {string} A CSS rgb color string, i.e. #nnnnnn\n */\nexport function rgbToHex(color) {\n // Idempotent\n if (color.indexOf('#') === 0) {\n return color;\n }\n const {\n values\n } = decomposeColor(color);\n return `#${values.map((n, i) => intToHex(i === 3 ? Math.round(255 * n) : n)).join('')}`;\n}\n\n/**\n * Converts a color from hsl format to rgb format.\n * @param {string} color - HSL color values\n * @returns {string} rgb color values\n */\nexport function hslToRgb(color) {\n color = decomposeColor(color);\n const {\n values\n } = color;\n const h = values[0];\n const s = values[1] / 100;\n const l = values[2] / 100;\n const a = s * Math.min(l, 1 - l);\n const f = (n, k = (n + h / 30) % 12) => l - a * Math.max(Math.min(k - 3, 9 - k, 1), -1);\n let type = 'rgb';\n const rgb = [Math.round(f(0) * 255), Math.round(f(8) * 255), Math.round(f(4) * 255)];\n if (color.type === 'hsla') {\n type += 'a';\n rgb.push(values[3]);\n }\n return recomposeColor({\n type,\n values: rgb\n });\n}\n/**\n * The relative brightness of any point in a color space,\n * normalized to 0 for darkest black and 1 for lightest white.\n *\n * Formula: https://www.w3.org/TR/WCAG20-TECHS/G17.html#G17-tests\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @returns {number} The relative brightness of the color in the range 0 - 1\n */\nexport function getLuminance(color) {\n color = decomposeColor(color);\n let rgb = color.type === 'hsl' || color.type === 'hsla' ? decomposeColor(hslToRgb(color)).values : color.values;\n rgb = rgb.map(val => {\n if (color.type !== 'color') {\n val /= 255; // normalized\n }\n return val <= 0.03928 ? val / 12.92 : ((val + 0.055) / 1.055) ** 2.4;\n });\n\n // Truncate at 3 digits\n return Number((0.2126 * rgb[0] + 0.7152 * rgb[1] + 0.0722 * rgb[2]).toFixed(3));\n}\n\n/**\n * Calculates the contrast ratio between two colors.\n *\n * Formula: https://www.w3.org/TR/WCAG20-TECHS/G17.html#G17-tests\n * @param {string} foreground - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla()\n * @param {string} background - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla()\n * @returns {number} A contrast ratio value in the range 0 - 21.\n */\nexport function getContrastRatio(foreground, background) {\n const lumA = getLuminance(foreground);\n const lumB = getLuminance(background);\n return (Math.max(lumA, lumB) + 0.05) / (Math.min(lumA, lumB) + 0.05);\n}\n\n/**\n * Sets the absolute transparency of a color.\n * Any existing alpha values are overwritten.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} value - value to set the alpha channel to in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function alpha(color, value) {\n color = decomposeColor(color);\n value = clampWrapper(value);\n if (color.type === 'rgb' || color.type === 'hsl') {\n color.type += 'a';\n }\n if (color.type === 'color') {\n color.values[3] = `/${value}`;\n } else {\n color.values[3] = value;\n }\n return recomposeColor(color);\n}\nexport function private_safeAlpha(color, value, warning) {\n try {\n return alpha(color, value);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Darkens a color.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} coefficient - multiplier in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function darken(color, coefficient) {\n color = decomposeColor(color);\n coefficient = clampWrapper(coefficient);\n if (color.type.indexOf('hsl') !== -1) {\n color.values[2] *= 1 - coefficient;\n } else if (color.type.indexOf('rgb') !== -1 || color.type.indexOf('color') !== -1) {\n for (let i = 0; i < 3; i += 1) {\n color.values[i] *= 1 - coefficient;\n }\n }\n return recomposeColor(color);\n}\nexport function private_safeDarken(color, coefficient, warning) {\n try {\n return darken(color, coefficient);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Lightens a color.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} coefficient - multiplier in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function lighten(color, coefficient) {\n color = decomposeColor(color);\n coefficient = clampWrapper(coefficient);\n if (color.type.indexOf('hsl') !== -1) {\n color.values[2] += (100 - color.values[2]) * coefficient;\n } else if (color.type.indexOf('rgb') !== -1) {\n for (let i = 0; i < 3; i += 1) {\n color.values[i] += (255 - color.values[i]) * coefficient;\n }\n } else if (color.type.indexOf('color') !== -1) {\n for (let i = 0; i < 3; i += 1) {\n color.values[i] += (1 - color.values[i]) * coefficient;\n }\n }\n return recomposeColor(color);\n}\nexport function private_safeLighten(color, coefficient, warning) {\n try {\n return lighten(color, coefficient);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Darken or lighten a color, depending on its luminance.\n * Light colors are darkened, dark colors are lightened.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} coefficient=0.15 - multiplier in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function emphasize(color, coefficient = 0.15) {\n return getLuminance(color) > 0.5 ? darken(color, coefficient) : lighten(color, coefficient);\n}\nexport function private_safeEmphasize(color, coefficient, warning) {\n try {\n return emphasize(color, coefficient);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Blend a transparent overlay color with a background color, resulting in a single\n * RGB color.\n * @param {string} background - CSS color\n * @param {string} overlay - CSS color\n * @param {number} opacity - Opacity multiplier in the range 0 - 1\n * @param {number} [gamma=1.0] - Gamma correction factor. For gamma-correct blending, 2.2 is usual.\n */\nexport function blend(background, overlay, opacity, gamma = 1.0) {\n const blendChannel = (b, o) => Math.round((b ** (1 / gamma) * (1 - opacity) + o ** (1 / gamma) * opacity) ** gamma);\n const backgroundColor = decomposeColor(background);\n const overlayColor = decomposeColor(overlay);\n const rgb = [blendChannel(backgroundColor.values[0], overlayColor.values[0]), blendChannel(backgroundColor.values[1], overlayColor.values[1]), blendChannel(backgroundColor.values[2], overlayColor.values[2])];\n return recomposeColor({\n type: 'rgb',\n values: rgb\n });\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nexport default function createMixins(breakpoints, mixins) {\n return _extends({\n toolbar: {\n minHeight: 56,\n [breakpoints.up('xs')]: {\n '@media (orientation: landscape)': {\n minHeight: 48\n }\n },\n [breakpoints.up('sm')]: {\n minHeight: 64\n }\n }\n }, mixins);\n}","const common = {\n black: '#000',\n white: '#fff'\n};\nexport default common;","const grey = {\n 50: '#fafafa',\n 100: '#f5f5f5',\n 200: '#eeeeee',\n 300: '#e0e0e0',\n 400: '#bdbdbd',\n 500: '#9e9e9e',\n 600: '#757575',\n 700: '#616161',\n 800: '#424242',\n 900: '#212121',\n A100: '#f5f5f5',\n A200: '#eeeeee',\n A400: '#bdbdbd',\n A700: '#616161'\n};\nexport default grey;","const purple = {\n 50: '#f3e5f5',\n 100: '#e1bee7',\n 200: '#ce93d8',\n 300: '#ba68c8',\n 400: '#ab47bc',\n 500: '#9c27b0',\n 600: '#8e24aa',\n 700: '#7b1fa2',\n 800: '#6a1b9a',\n 900: '#4a148c',\n A100: '#ea80fc',\n A200: '#e040fb',\n A400: '#d500f9',\n A700: '#aa00ff'\n};\nexport default purple;","const red = {\n 50: '#ffebee',\n 100: '#ffcdd2',\n 200: '#ef9a9a',\n 300: '#e57373',\n 400: '#ef5350',\n 500: '#f44336',\n 600: '#e53935',\n 700: '#d32f2f',\n 800: '#c62828',\n 900: '#b71c1c',\n A100: '#ff8a80',\n A200: '#ff5252',\n A400: '#ff1744',\n A700: '#d50000'\n};\nexport default red;","const orange = {\n 50: '#fff3e0',\n 100: '#ffe0b2',\n 200: '#ffcc80',\n 300: '#ffb74d',\n 400: '#ffa726',\n 500: '#ff9800',\n 600: '#fb8c00',\n 700: '#f57c00',\n 800: '#ef6c00',\n 900: '#e65100',\n A100: '#ffd180',\n A200: '#ffab40',\n A400: '#ff9100',\n A700: '#ff6d00'\n};\nexport default orange;","const blue = {\n 50: '#e3f2fd',\n 100: '#bbdefb',\n 200: '#90caf9',\n 300: '#64b5f6',\n 400: '#42a5f5',\n 500: '#2196f3',\n 600: '#1e88e5',\n 700: '#1976d2',\n 800: '#1565c0',\n 900: '#0d47a1',\n A100: '#82b1ff',\n A200: '#448aff',\n A400: '#2979ff',\n A700: '#2962ff'\n};\nexport default blue;","const lightBlue = {\n 50: '#e1f5fe',\n 100: '#b3e5fc',\n 200: '#81d4fa',\n 300: '#4fc3f7',\n 400: '#29b6f6',\n 500: '#03a9f4',\n 600: '#039be5',\n 700: '#0288d1',\n 800: '#0277bd',\n 900: '#01579b',\n A100: '#80d8ff',\n A200: '#40c4ff',\n A400: '#00b0ff',\n A700: '#0091ea'\n};\nexport default lightBlue;","const green = {\n 50: '#e8f5e9',\n 100: '#c8e6c9',\n 200: '#a5d6a7',\n 300: '#81c784',\n 400: '#66bb6a',\n 500: '#4caf50',\n 600: '#43a047',\n 700: '#388e3c',\n 800: '#2e7d32',\n 900: '#1b5e20',\n A100: '#b9f6ca',\n A200: '#69f0ae',\n A400: '#00e676',\n A700: '#00c853'\n};\nexport default green;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\nconst _excluded = [\"mode\", \"contrastThreshold\", \"tonalOffset\"];\nimport { deepmerge } from '@mui/utils';\nimport { darken, getContrastRatio, lighten } from '@mui/system';\nimport common from '../colors/common';\nimport grey from '../colors/grey';\nimport purple from '../colors/purple';\nimport red from '../colors/red';\nimport orange from '../colors/orange';\nimport blue from '../colors/blue';\nimport lightBlue from '../colors/lightBlue';\nimport green from '../colors/green';\nexport const light = {\n // The colors used to style the text.\n text: {\n // The most important text.\n primary: 'rgba(0, 0, 0, 0.87)',\n // Secondary text.\n secondary: 'rgba(0, 0, 0, 0.6)',\n // Disabled text have even lower visual prominence.\n disabled: 'rgba(0, 0, 0, 0.38)'\n },\n // The color used to divide different elements.\n divider: 'rgba(0, 0, 0, 0.12)',\n // The background colors used to style the surfaces.\n // Consistency between these values is important.\n background: {\n paper: common.white,\n default: common.white\n },\n // The colors used to style the action elements.\n action: {\n // The color of an active action like an icon button.\n active: 'rgba(0, 0, 0, 0.54)',\n // The color of an hovered action.\n hover: 'rgba(0, 0, 0, 0.04)',\n hoverOpacity: 0.04,\n // The color of a selected action.\n selected: 'rgba(0, 0, 0, 0.08)',\n selectedOpacity: 0.08,\n // The color of a disabled action.\n disabled: 'rgba(0, 0, 0, 0.26)',\n // The background color of a disabled action.\n disabledBackground: 'rgba(0, 0, 0, 0.12)',\n disabledOpacity: 0.38,\n focus: 'rgba(0, 0, 0, 0.12)',\n focusOpacity: 0.12,\n activatedOpacity: 0.12\n }\n};\nexport const dark = {\n text: {\n primary: common.white,\n secondary: 'rgba(255, 255, 255, 0.7)',\n disabled: 'rgba(255, 255, 255, 0.5)',\n icon: 'rgba(255, 255, 255, 0.5)'\n },\n divider: 'rgba(255, 255, 255, 0.12)',\n background: {\n paper: '#121212',\n default: '#121212'\n },\n action: {\n active: common.white,\n hover: 'rgba(255, 255, 255, 0.08)',\n hoverOpacity: 0.08,\n selected: 'rgba(255, 255, 255, 0.16)',\n selectedOpacity: 0.16,\n disabled: 'rgba(255, 255, 255, 0.3)',\n disabledBackground: 'rgba(255, 255, 255, 0.12)',\n disabledOpacity: 0.38,\n focus: 'rgba(255, 255, 255, 0.12)',\n focusOpacity: 0.12,\n activatedOpacity: 0.24\n }\n};\nfunction addLightOrDark(intent, direction, shade, tonalOffset) {\n const tonalOffsetLight = tonalOffset.light || tonalOffset;\n const tonalOffsetDark = tonalOffset.dark || tonalOffset * 1.5;\n if (!intent[direction]) {\n if (intent.hasOwnProperty(shade)) {\n intent[direction] = intent[shade];\n } else if (direction === 'light') {\n intent.light = lighten(intent.main, tonalOffsetLight);\n } else if (direction === 'dark') {\n intent.dark = darken(intent.main, tonalOffsetDark);\n }\n }\n}\nfunction getDefaultPrimary(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: blue[200],\n light: blue[50],\n dark: blue[400]\n };\n }\n return {\n main: blue[700],\n light: blue[400],\n dark: blue[800]\n };\n}\nfunction getDefaultSecondary(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: purple[200],\n light: purple[50],\n dark: purple[400]\n };\n }\n return {\n main: purple[500],\n light: purple[300],\n dark: purple[700]\n };\n}\nfunction getDefaultError(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: red[500],\n light: red[300],\n dark: red[700]\n };\n }\n return {\n main: red[700],\n light: red[400],\n dark: red[800]\n };\n}\nfunction getDefaultInfo(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: lightBlue[400],\n light: lightBlue[300],\n dark: lightBlue[700]\n };\n }\n return {\n main: lightBlue[700],\n light: lightBlue[500],\n dark: lightBlue[900]\n };\n}\nfunction getDefaultSuccess(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: green[400],\n light: green[300],\n dark: green[700]\n };\n }\n return {\n main: green[800],\n light: green[500],\n dark: green[900]\n };\n}\nfunction getDefaultWarning(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: orange[400],\n light: orange[300],\n dark: orange[700]\n };\n }\n return {\n main: '#ed6c02',\n // closest to orange[800] that pass 3:1.\n light: orange[500],\n dark: orange[900]\n };\n}\nexport default function createPalette(palette) {\n const {\n mode = 'light',\n contrastThreshold = 3,\n tonalOffset = 0.2\n } = palette,\n other = _objectWithoutPropertiesLoose(palette, _excluded);\n const primary = palette.primary || getDefaultPrimary(mode);\n const secondary = palette.secondary || getDefaultSecondary(mode);\n const error = palette.error || getDefaultError(mode);\n const info = palette.info || getDefaultInfo(mode);\n const success = palette.success || getDefaultSuccess(mode);\n const warning = palette.warning || getDefaultWarning(mode);\n\n // Use the same logic as\n // Bootstrap: https://github.com/twbs/bootstrap/blob/1d6e3710dd447de1a200f29e8fa521f8a0908f70/scss/_functions.scss#L59\n // and material-components-web https://github.com/material-components/material-components-web/blob/ac46b8863c4dab9fc22c4c662dc6bd1b65dd652f/packages/mdc-theme/_functions.scss#L54\n function getContrastText(background) {\n const contrastText = getContrastRatio(background, dark.text.primary) >= contrastThreshold ? dark.text.primary : light.text.primary;\n if (process.env.NODE_ENV !== 'production') {\n const contrast = getContrastRatio(background, contrastText);\n if (contrast < 3) {\n console.error([`MUI: The contrast ratio of ${contrast}:1 for ${contrastText} on ${background}`, 'falls below the WCAG recommended absolute minimum contrast ratio of 3:1.', 'https://www.w3.org/TR/2008/REC-WCAG20-20081211/#visual-audio-contrast-contrast'].join('\\n'));\n }\n }\n return contrastText;\n }\n const augmentColor = ({\n color,\n name,\n mainShade = 500,\n lightShade = 300,\n darkShade = 700\n }) => {\n color = _extends({}, color);\n if (!color.main && color[mainShade]) {\n color.main = color[mainShade];\n }\n if (!color.hasOwnProperty('main')) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: The color${name ? ` (${name})` : ''} provided to augmentColor(color) is invalid.\nThe color object needs to have a \\`main\\` property or a \\`${mainShade}\\` property.` : _formatMuiErrorMessage(11, name ? ` (${name})` : '', mainShade));\n }\n if (typeof color.main !== 'string') {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: The color${name ? ` (${name})` : ''} provided to augmentColor(color) is invalid.\n\\`color.main\\` should be a string, but \\`${JSON.stringify(color.main)}\\` was provided instead.\n\nDid you intend to use one of the following approaches?\n\nimport { green } from \"@mui/material/colors\";\n\nconst theme1 = createTheme({ palette: {\n primary: green,\n} });\n\nconst theme2 = createTheme({ palette: {\n primary: { main: green[500] },\n} });` : _formatMuiErrorMessage(12, name ? ` (${name})` : '', JSON.stringify(color.main)));\n }\n addLightOrDark(color, 'light', lightShade, tonalOffset);\n addLightOrDark(color, 'dark', darkShade, tonalOffset);\n if (!color.contrastText) {\n color.contrastText = getContrastText(color.main);\n }\n return color;\n };\n const modes = {\n dark,\n light\n };\n if (process.env.NODE_ENV !== 'production') {\n if (!modes[mode]) {\n console.error(`MUI: The palette mode \\`${mode}\\` is not supported.`);\n }\n }\n const paletteOutput = deepmerge(_extends({\n // A collection of common colors.\n common: _extends({}, common),\n // prevent mutable object.\n // The palette mode, can be light or dark.\n mode,\n // The colors used to represent primary interface elements for a user.\n primary: augmentColor({\n color: primary,\n name: 'primary'\n }),\n // The colors used to represent secondary interface elements for a user.\n secondary: augmentColor({\n color: secondary,\n name: 'secondary',\n mainShade: 'A400',\n lightShade: 'A200',\n darkShade: 'A700'\n }),\n // The colors used to represent interface elements that the user should be made aware of.\n error: augmentColor({\n color: error,\n name: 'error'\n }),\n // The colors used to represent potentially dangerous actions or important messages.\n warning: augmentColor({\n color: warning,\n name: 'warning'\n }),\n // The colors used to present information to the user that is neutral and not necessarily important.\n info: augmentColor({\n color: info,\n name: 'info'\n }),\n // The colors used to indicate the successful completion of an action that user triggered.\n success: augmentColor({\n color: success,\n name: 'success'\n }),\n // The grey colors.\n grey,\n // Used by `getContrastText()` to maximize the contrast between\n // the background and the text.\n contrastThreshold,\n // Takes a background color and returns the text color that maximizes the contrast.\n getContrastText,\n // Generate a rich color object.\n augmentColor,\n // Used by the functions below to shift a color's luminance by approximately\n // two indexes within its tonal palette.\n // E.g., shift from Red 500 to Red 300 or Red 700.\n tonalOffset\n }, modes[mode]), other);\n return paletteOutput;\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"fontFamily\", \"fontSize\", \"fontWeightLight\", \"fontWeightRegular\", \"fontWeightMedium\", \"fontWeightBold\", \"htmlFontSize\", \"allVariants\", \"pxToRem\"];\nimport { deepmerge } from '@mui/utils';\nfunction round(value) {\n return Math.round(value * 1e5) / 1e5;\n}\nconst caseAllCaps = {\n textTransform: 'uppercase'\n};\nconst defaultFontFamily = '\"Roboto\", \"Helvetica\", \"Arial\", sans-serif';\n\n/**\n * @see @link{https://m2.material.io/design/typography/the-type-system.html}\n * @see @link{https://m2.material.io/design/typography/understanding-typography.html}\n */\nexport default function createTypography(palette, typography) {\n const _ref = typeof typography === 'function' ? typography(palette) : typography,\n {\n fontFamily = defaultFontFamily,\n // The default font size of the Material Specification.\n fontSize = 14,\n // px\n fontWeightLight = 300,\n fontWeightRegular = 400,\n fontWeightMedium = 500,\n fontWeightBold = 700,\n // Tell MUI what's the font-size on the html element.\n // 16px is the default font-size used by browsers.\n htmlFontSize = 16,\n // Apply the CSS properties to all the variants.\n allVariants,\n pxToRem: pxToRem2\n } = _ref,\n other = _objectWithoutPropertiesLoose(_ref, _excluded);\n if (process.env.NODE_ENV !== 'production') {\n if (typeof fontSize !== 'number') {\n console.error('MUI: `fontSize` is required to be a number.');\n }\n if (typeof htmlFontSize !== 'number') {\n console.error('MUI: `htmlFontSize` is required to be a number.');\n }\n }\n const coef = fontSize / 14;\n const pxToRem = pxToRem2 || (size => `${size / htmlFontSize * coef}rem`);\n const buildVariant = (fontWeight, size, lineHeight, letterSpacing, casing) => _extends({\n fontFamily,\n fontWeight,\n fontSize: pxToRem(size),\n // Unitless following https://meyerweb.com/eric/thoughts/2006/02/08/unitless-line-heights/\n lineHeight\n }, fontFamily === defaultFontFamily ? {\n letterSpacing: `${round(letterSpacing / size)}em`\n } : {}, casing, allVariants);\n const variants = {\n h1: buildVariant(fontWeightLight, 96, 1.167, -1.5),\n h2: buildVariant(fontWeightLight, 60, 1.2, -0.5),\n h3: buildVariant(fontWeightRegular, 48, 1.167, 0),\n h4: buildVariant(fontWeightRegular, 34, 1.235, 0.25),\n h5: buildVariant(fontWeightRegular, 24, 1.334, 0),\n h6: buildVariant(fontWeightMedium, 20, 1.6, 0.15),\n subtitle1: buildVariant(fontWeightRegular, 16, 1.75, 0.15),\n subtitle2: buildVariant(fontWeightMedium, 14, 1.57, 0.1),\n body1: buildVariant(fontWeightRegular, 16, 1.5, 0.15),\n body2: buildVariant(fontWeightRegular, 14, 1.43, 0.15),\n button: buildVariant(fontWeightMedium, 14, 1.75, 0.4, caseAllCaps),\n caption: buildVariant(fontWeightRegular, 12, 1.66, 0.4),\n overline: buildVariant(fontWeightRegular, 12, 2.66, 1, caseAllCaps),\n // TODO v6: Remove handling of 'inherit' variant from the theme as it is already handled in Material UI's Typography component. Also, remember to remove the associated types.\n inherit: {\n fontFamily: 'inherit',\n fontWeight: 'inherit',\n fontSize: 'inherit',\n lineHeight: 'inherit',\n letterSpacing: 'inherit'\n }\n };\n return deepmerge(_extends({\n htmlFontSize,\n pxToRem,\n fontFamily,\n fontSize,\n fontWeightLight,\n fontWeightRegular,\n fontWeightMedium,\n fontWeightBold\n }, variants), other, {\n clone: false // No need to clone deep\n });\n}","const shadowKeyUmbraOpacity = 0.2;\nconst shadowKeyPenumbraOpacity = 0.14;\nconst shadowAmbientShadowOpacity = 0.12;\nfunction createShadow(...px) {\n return [`${px[0]}px ${px[1]}px ${px[2]}px ${px[3]}px rgba(0,0,0,${shadowKeyUmbraOpacity})`, `${px[4]}px ${px[5]}px ${px[6]}px ${px[7]}px rgba(0,0,0,${shadowKeyPenumbraOpacity})`, `${px[8]}px ${px[9]}px ${px[10]}px ${px[11]}px rgba(0,0,0,${shadowAmbientShadowOpacity})`].join(',');\n}\n\n// Values from https://github.com/material-components/material-components-web/blob/be8747f94574669cb5e7add1a7c54fa41a89cec7/packages/mdc-elevation/_variables.scss\nconst shadows = ['none', createShadow(0, 2, 1, -1, 0, 1, 1, 0, 0, 1, 3, 0), createShadow(0, 3, 1, -2, 0, 2, 2, 0, 0, 1, 5, 0), createShadow(0, 3, 3, -2, 0, 3, 4, 0, 0, 1, 8, 0), createShadow(0, 2, 4, -1, 0, 4, 5, 0, 0, 1, 10, 0), createShadow(0, 3, 5, -1, 0, 5, 8, 0, 0, 1, 14, 0), createShadow(0, 3, 5, -1, 0, 6, 10, 0, 0, 1, 18, 0), createShadow(0, 4, 5, -2, 0, 7, 10, 1, 0, 2, 16, 1), createShadow(0, 5, 5, -3, 0, 8, 10, 1, 0, 3, 14, 2), createShadow(0, 5, 6, -3, 0, 9, 12, 1, 0, 3, 16, 2), createShadow(0, 6, 6, -3, 0, 10, 14, 1, 0, 4, 18, 3), createShadow(0, 6, 7, -4, 0, 11, 15, 1, 0, 4, 20, 3), createShadow(0, 7, 8, -4, 0, 12, 17, 2, 0, 5, 22, 4), createShadow(0, 7, 8, -4, 0, 13, 19, 2, 0, 5, 24, 4), createShadow(0, 7, 9, -4, 0, 14, 21, 2, 0, 5, 26, 4), createShadow(0, 8, 9, -5, 0, 15, 22, 2, 0, 6, 28, 5), createShadow(0, 8, 10, -5, 0, 16, 24, 2, 0, 6, 30, 5), createShadow(0, 8, 11, -5, 0, 17, 26, 2, 0, 6, 32, 5), createShadow(0, 9, 11, -5, 0, 18, 28, 2, 0, 7, 34, 6), createShadow(0, 9, 12, -6, 0, 19, 29, 2, 0, 7, 36, 6), createShadow(0, 10, 13, -6, 0, 20, 31, 3, 0, 8, 38, 7), createShadow(0, 10, 13, -6, 0, 21, 33, 3, 0, 8, 40, 7), createShadow(0, 10, 14, -6, 0, 22, 35, 3, 0, 8, 42, 7), createShadow(0, 11, 14, -7, 0, 23, 36, 3, 0, 9, 44, 8), createShadow(0, 11, 15, -7, 0, 24, 38, 3, 0, 9, 46, 8)];\nexport default shadows;","import _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nconst _excluded = [\"duration\", \"easing\", \"delay\"];\n// Follow https://material.google.com/motion/duration-easing.html#duration-easing-natural-easing-curves\n// to learn the context in which each easing should be used.\nexport const easing = {\n // This is the most common easing curve.\n easeInOut: 'cubic-bezier(0.4, 0, 0.2, 1)',\n // Objects enter the screen at full velocity from off-screen and\n // slowly decelerate to a resting point.\n easeOut: 'cubic-bezier(0.0, 0, 0.2, 1)',\n // Objects leave the screen at full velocity. They do not decelerate when off-screen.\n easeIn: 'cubic-bezier(0.4, 0, 1, 1)',\n // The sharp curve is used by objects that may return to the screen at any time.\n sharp: 'cubic-bezier(0.4, 0, 0.6, 1)'\n};\n\n// Follow https://m2.material.io/guidelines/motion/duration-easing.html#duration-easing-common-durations\n// to learn when use what timing\nexport const duration = {\n shortest: 150,\n shorter: 200,\n short: 250,\n // most basic recommended timing\n standard: 300,\n // this is to be used in complex animations\n complex: 375,\n // recommended when something is entering screen\n enteringScreen: 225,\n // recommended when something is leaving screen\n leavingScreen: 195\n};\nfunction formatMs(milliseconds) {\n return `${Math.round(milliseconds)}ms`;\n}\nfunction getAutoHeightDuration(height) {\n if (!height) {\n return 0;\n }\n const constant = height / 36;\n\n // https://www.wolframalpha.com/input/?i=(4+%2B+15+*+(x+%2F+36+)+**+0.25+%2B+(x+%2F+36)+%2F+5)+*+10\n return Math.round((4 + 15 * constant ** 0.25 + constant / 5) * 10);\n}\nexport default function createTransitions(inputTransitions) {\n const mergedEasing = _extends({}, easing, inputTransitions.easing);\n const mergedDuration = _extends({}, duration, inputTransitions.duration);\n const create = (props = ['all'], options = {}) => {\n const {\n duration: durationOption = mergedDuration.standard,\n easing: easingOption = mergedEasing.easeInOut,\n delay = 0\n } = options,\n other = _objectWithoutPropertiesLoose(options, _excluded);\n if (process.env.NODE_ENV !== 'production') {\n const isString = value => typeof value === 'string';\n // IE11 support, replace with Number.isNaN\n // eslint-disable-next-line no-restricted-globals\n const isNumber = value => !isNaN(parseFloat(value));\n if (!isString(props) && !Array.isArray(props)) {\n console.error('MUI: Argument \"props\" must be a string or Array.');\n }\n if (!isNumber(durationOption) && !isString(durationOption)) {\n console.error(`MUI: Argument \"duration\" must be a number or a string but found ${durationOption}.`);\n }\n if (!isString(easingOption)) {\n console.error('MUI: Argument \"easing\" must be a string.');\n }\n if (!isNumber(delay) && !isString(delay)) {\n console.error('MUI: Argument \"delay\" must be a number or a string.');\n }\n if (typeof options !== 'object') {\n console.error(['MUI: Secong argument of transition.create must be an object.', \"Arguments should be either `create('prop1', options)` or `create(['prop1', 'prop2'], options)`\"].join('\\n'));\n }\n if (Object.keys(other).length !== 0) {\n console.error(`MUI: Unrecognized argument(s) [${Object.keys(other).join(',')}].`);\n }\n }\n return (Array.isArray(props) ? props : [props]).map(animatedProp => `${animatedProp} ${typeof durationOption === 'string' ? durationOption : formatMs(durationOption)} ${easingOption} ${typeof delay === 'string' ? delay : formatMs(delay)}`).join(',');\n };\n return _extends({\n getAutoHeightDuration,\n create\n }, inputTransitions, {\n easing: mergedEasing,\n duration: mergedDuration\n });\n}","// We need to centralize the zIndex definitions as they work\n// like global values in the browser.\nconst zIndex = {\n mobileStepper: 1000,\n fab: 1050,\n speedDial: 1050,\n appBar: 1100,\n drawer: 1200,\n modal: 1300,\n snackbar: 1400,\n tooltip: 1500\n};\nexport default zIndex;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\nconst _excluded = [\"breakpoints\", \"mixins\", \"spacing\", \"palette\", \"transitions\", \"typography\", \"shape\"];\nimport { deepmerge } from '@mui/utils';\nimport { createTheme as systemCreateTheme, unstable_defaultSxConfig as defaultSxConfig, unstable_styleFunctionSx as styleFunctionSx } from '@mui/system';\nimport generateUtilityClass from '@mui/utils/generateUtilityClass';\nimport createMixins from './createMixins';\nimport createPalette from './createPalette';\nimport createTypography from './createTypography';\nimport shadows from './shadows';\nimport createTransitions from './createTransitions';\nimport zIndex from './zIndex';\nfunction createTheme(options = {}, ...args) {\n const {\n mixins: mixinsInput = {},\n palette: paletteInput = {},\n transitions: transitionsInput = {},\n typography: typographyInput = {}\n } = options,\n other = _objectWithoutPropertiesLoose(options, _excluded);\n if (options.vars) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: \\`vars\\` is a private field used for CSS variables support.\nPlease use another name.` : _formatMuiErrorMessage(18));\n }\n const palette = createPalette(paletteInput);\n const systemTheme = systemCreateTheme(options);\n let muiTheme = deepmerge(systemTheme, {\n mixins: createMixins(systemTheme.breakpoints, mixinsInput),\n palette,\n // Don't use [...shadows] until you've verified its transpiled code is not invoking the iterator protocol.\n shadows: shadows.slice(),\n typography: createTypography(palette, typographyInput),\n transitions: createTransitions(transitionsInput),\n zIndex: _extends({}, zIndex)\n });\n muiTheme = deepmerge(muiTheme, other);\n muiTheme = args.reduce((acc, argument) => deepmerge(acc, argument), muiTheme);\n if (process.env.NODE_ENV !== 'production') {\n // TODO v6: Refactor to use globalStateClassesMapping from @mui/utils once `readOnly` state class is used in Rating component.\n const stateClasses = ['active', 'checked', 'completed', 'disabled', 'error', 'expanded', 'focused', 'focusVisible', 'required', 'selected'];\n const traverse = (node, component) => {\n let key;\n\n // eslint-disable-next-line guard-for-in, no-restricted-syntax\n for (key in node) {\n const child = node[key];\n if (stateClasses.indexOf(key) !== -1 && Object.keys(child).length > 0) {\n if (process.env.NODE_ENV !== 'production') {\n const stateClass = generateUtilityClass('', key);\n console.error([`MUI: The \\`${component}\\` component increases ` + `the CSS specificity of the \\`${key}\\` internal state.`, 'You can not override it like this: ', JSON.stringify(node, null, 2), '', `Instead, you need to use the '&.${stateClass}' syntax:`, JSON.stringify({\n root: {\n [`&.${stateClass}`]: child\n }\n }, null, 2), '', 'https://mui.com/r/state-classes-guide'].join('\\n'));\n }\n // Remove the style to prevent global conflicts.\n node[key] = {};\n }\n }\n };\n Object.keys(muiTheme.components).forEach(component => {\n const styleOverrides = muiTheme.components[component].styleOverrides;\n if (styleOverrides && component.indexOf('Mui') === 0) {\n traverse(styleOverrides, component);\n }\n });\n }\n muiTheme.unstable_sxConfig = _extends({}, defaultSxConfig, other == null ? void 0 : other.unstable_sxConfig);\n muiTheme.unstable_sx = function sx(props) {\n return styleFunctionSx({\n sx: props,\n theme: this\n });\n };\n return muiTheme;\n}\nlet warnedOnce = false;\nexport function createMuiTheme(...args) {\n if (process.env.NODE_ENV !== 'production') {\n if (!warnedOnce) {\n warnedOnce = true;\n console.error(['MUI: the createMuiTheme function was renamed to createTheme.', '', \"You should use `import { createTheme } from '@mui/material/styles'`\"].join('\\n'));\n }\n }\n return createTheme(...args);\n}\nexport default createTheme;","'use client';\n\nimport createTheme from './createTheme';\nconst defaultTheme = createTheme();\nexport default defaultTheme;","export default '$$material';","'use client';\n\nimport { useThemeProps as systemUseThemeProps } from '@mui/system';\nimport defaultTheme from './defaultTheme';\nimport THEME_ID from './identifier';\nexport default function useThemeProps({\n props,\n name\n}) {\n return systemUseThemeProps({\n props,\n name,\n defaultTheme,\n themeId: THEME_ID\n });\n}","'use client';\n\nimport { createStyled, shouldForwardProp } from '@mui/system';\nimport defaultTheme from './defaultTheme';\nimport THEME_ID from './identifier';\nexport const rootShouldForwardProp = prop => shouldForwardProp(prop) && prop !== 'classes';\nexport const slotShouldForwardProp = shouldForwardProp;\nconst styled = createStyled({\n themeId: THEME_ID,\n defaultTheme,\n rootShouldForwardProp\n});\nexport default styled;","import generateUtilityClasses from '@mui/utils/generateUtilityClasses';\nimport generateUtilityClass from '@mui/utils/generateUtilityClass';\nexport function getSvgIconUtilityClass(slot) {\n return generateUtilityClass('MuiSvgIcon', slot);\n}\nconst svgIconClasses = generateUtilityClasses('MuiSvgIcon', ['root', 'colorPrimary', 'colorSecondary', 'colorAction', 'colorError', 'colorDisabled', 'fontSizeInherit', 'fontSizeSmall', 'fontSizeMedium', 'fontSizeLarge']);\nexport default svgIconClasses;","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"children\", \"className\", \"color\", \"component\", \"fontSize\", \"htmlColor\", \"inheritViewBox\", \"titleAccess\", \"viewBox\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport clsx from 'clsx';\nimport { unstable_composeClasses as composeClasses } from '@mui/base/composeClasses';\nimport capitalize from '../utils/capitalize';\nimport useThemeProps from '../styles/useThemeProps';\nimport styled from '../styles/styled';\nimport { getSvgIconUtilityClass } from './svgIconClasses';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nimport { jsxs as _jsxs } from \"react/jsx-runtime\";\nconst useUtilityClasses = ownerState => {\n const {\n color,\n fontSize,\n classes\n } = ownerState;\n const slots = {\n root: ['root', color !== 'inherit' && `color${capitalize(color)}`, `fontSize${capitalize(fontSize)}`]\n };\n return composeClasses(slots, getSvgIconUtilityClass, classes);\n};\nconst SvgIconRoot = styled('svg', {\n name: 'MuiSvgIcon',\n slot: 'Root',\n overridesResolver: (props, styles) => {\n const {\n ownerState\n } = props;\n return [styles.root, ownerState.color !== 'inherit' && styles[`color${capitalize(ownerState.color)}`], styles[`fontSize${capitalize(ownerState.fontSize)}`]];\n }\n})(({\n theme,\n ownerState\n}) => {\n var _theme$transitions, _theme$transitions$cr, _theme$transitions2, _theme$typography, _theme$typography$pxT, _theme$typography2, _theme$typography2$px, _theme$typography3, _theme$typography3$px, _palette$ownerState$c, _palette, _palette2, _palette3;\n return {\n userSelect: 'none',\n width: '1em',\n height: '1em',\n display: 'inline-block',\n // the will define the property that has `currentColor`\n // e.g. heroicons uses fill=\"none\" and stroke=\"currentColor\"\n fill: ownerState.hasSvgAsChild ? undefined : 'currentColor',\n flexShrink: 0,\n transition: (_theme$transitions = theme.transitions) == null || (_theme$transitions$cr = _theme$transitions.create) == null ? void 0 : _theme$transitions$cr.call(_theme$transitions, 'fill', {\n duration: (_theme$transitions2 = theme.transitions) == null || (_theme$transitions2 = _theme$transitions2.duration) == null ? void 0 : _theme$transitions2.shorter\n }),\n fontSize: {\n inherit: 'inherit',\n small: ((_theme$typography = theme.typography) == null || (_theme$typography$pxT = _theme$typography.pxToRem) == null ? void 0 : _theme$typography$pxT.call(_theme$typography, 20)) || '1.25rem',\n medium: ((_theme$typography2 = theme.typography) == null || (_theme$typography2$px = _theme$typography2.pxToRem) == null ? void 0 : _theme$typography2$px.call(_theme$typography2, 24)) || '1.5rem',\n large: ((_theme$typography3 = theme.typography) == null || (_theme$typography3$px = _theme$typography3.pxToRem) == null ? void 0 : _theme$typography3$px.call(_theme$typography3, 35)) || '2.1875rem'\n }[ownerState.fontSize],\n // TODO v5 deprecate, v6 remove for sx\n color: (_palette$ownerState$c = (_palette = (theme.vars || theme).palette) == null || (_palette = _palette[ownerState.color]) == null ? void 0 : _palette.main) != null ? _palette$ownerState$c : {\n action: (_palette2 = (theme.vars || theme).palette) == null || (_palette2 = _palette2.action) == null ? void 0 : _palette2.active,\n disabled: (_palette3 = (theme.vars || theme).palette) == null || (_palette3 = _palette3.action) == null ? void 0 : _palette3.disabled,\n inherit: undefined\n }[ownerState.color]\n };\n});\nconst SvgIcon = /*#__PURE__*/React.forwardRef(function SvgIcon(inProps, ref) {\n const props = useThemeProps({\n props: inProps,\n name: 'MuiSvgIcon'\n });\n const {\n children,\n className,\n color = 'inherit',\n component = 'svg',\n fontSize = 'medium',\n htmlColor,\n inheritViewBox = false,\n titleAccess,\n viewBox = '0 0 24 24'\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const hasSvgAsChild = /*#__PURE__*/React.isValidElement(children) && children.type === 'svg';\n const ownerState = _extends({}, props, {\n color,\n component,\n fontSize,\n instanceFontSize: inProps.fontSize,\n inheritViewBox,\n viewBox,\n hasSvgAsChild\n });\n const more = {};\n if (!inheritViewBox) {\n more.viewBox = viewBox;\n }\n const classes = useUtilityClasses(ownerState);\n return /*#__PURE__*/_jsxs(SvgIconRoot, _extends({\n as: component,\n className: clsx(classes.root, className),\n focusable: \"false\",\n color: htmlColor,\n \"aria-hidden\": titleAccess ? undefined : true,\n role: titleAccess ? 'img' : undefined,\n ref: ref\n }, more, other, hasSvgAsChild && children.props, {\n ownerState: ownerState,\n children: [hasSvgAsChild ? children.props.children : children, titleAccess ? /*#__PURE__*/_jsx(\"title\", {\n children: titleAccess\n }) : null]\n }));\n});\nprocess.env.NODE_ENV !== \"production\" ? SvgIcon.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the d.ts file and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * Node passed into the SVG element.\n */\n children: PropTypes.node,\n /**\n * Override or extend the styles applied to the component.\n */\n classes: PropTypes.object,\n /**\n * @ignore\n */\n className: PropTypes.string,\n /**\n * The color of the component.\n * It supports both default and custom theme colors, which can be added as shown in the\n * [palette customization guide](https://mui.com/material-ui/customization/palette/#custom-colors).\n * You can use the `htmlColor` prop to apply a color attribute to the SVG element.\n * @default 'inherit'\n */\n color: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.oneOf(['inherit', 'action', 'disabled', 'primary', 'secondary', 'error', 'info', 'success', 'warning']), PropTypes.string]),\n /**\n * The component used for the root node.\n * Either a string to use a HTML element or a component.\n */\n component: PropTypes.elementType,\n /**\n * The fontSize applied to the icon. Defaults to 24px, but can be configure to inherit font size.\n * @default 'medium'\n */\n fontSize: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.oneOf(['inherit', 'large', 'medium', 'small']), PropTypes.string]),\n /**\n * Applies a color attribute to the SVG element.\n */\n htmlColor: PropTypes.string,\n /**\n * If `true`, the root node will inherit the custom `component`'s viewBox and the `viewBox`\n * prop will be ignored.\n * Useful when you want to reference a custom `component` and have `SvgIcon` pass that\n * `component`'s viewBox to the root node.\n * @default false\n */\n inheritViewBox: PropTypes.bool,\n /**\n * The shape-rendering attribute. The behavior of the different options is described on the\n * [MDN Web Docs](https://developer.mozilla.org/en-US/docs/Web/SVG/Attribute/shape-rendering).\n * If you are having issues with blurry icons you should investigate this prop.\n */\n shapeRendering: PropTypes.string,\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Provides a human-readable title for the element that contains it.\n * https://www.w3.org/TR/SVG-access/#Equivalent\n */\n titleAccess: PropTypes.string,\n /**\n * Allows you to redefine what the coordinates without units mean inside an SVG element.\n * For example, if the SVG element is 500 (width) by 200 (height),\n * and you pass viewBox=\"0 0 50 20\",\n * this means that the coordinates inside the SVG will go from the top left corner (0,0)\n * to bottom right (50,20) and each unit will be worth 10px.\n * @default '0 0 24 24'\n */\n viewBox: PropTypes.string\n} : void 0;\nSvgIcon.muiName = 'SvgIcon';\nexport default SvgIcon;","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport * as React from 'react';\nimport SvgIcon from '../SvgIcon';\n\n/**\n * Private module reserved for @mui packages.\n */\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nexport default function createSvgIcon(path, displayName) {\n function Component(props, ref) {\n return /*#__PURE__*/_jsx(SvgIcon, _extends({\n \"data-testid\": `${displayName}Icon`,\n ref: ref\n }, props, {\n children: path\n }));\n }\n if (process.env.NODE_ENV !== 'production') {\n // Need to set `displayName` on the inner component for React.memo.\n // React prior to 16.14 ignores `displayName` on the wrapper.\n Component.displayName = `${displayName}Icon`;\n }\n Component.muiName = SvgIcon.muiName;\n return /*#__PURE__*/React.memo( /*#__PURE__*/React.forwardRef(Component));\n}","'use client';\n\nimport { unstable_ClassNameGenerator as ClassNameGenerator } from '@mui/base/ClassNameGenerator';\nexport { default as capitalize } from './capitalize';\nexport { default as createChainedFunction } from './createChainedFunction';\nexport { default as createSvgIcon } from './createSvgIcon';\nexport { default as debounce } from './debounce';\nexport { default as deprecatedPropType } from './deprecatedPropType';\nexport { default as isMuiElement } from './isMuiElement';\nexport { default as ownerDocument } from './ownerDocument';\nexport { default as ownerWindow } from './ownerWindow';\nexport { default as requirePropFactory } from './requirePropFactory';\nexport { default as setRef } from './setRef';\nexport { default as unstable_useEnhancedEffect } from './useEnhancedEffect';\nexport { default as unstable_useId } from './useId';\nexport { default as unsupportedProp } from './unsupportedProp';\nexport { default as useControlled } from './useControlled';\nexport { default as useEventCallback } from './useEventCallback';\nexport { default as useForkRef } from './useForkRef';\nexport { default as useIsFocusVisible } from './useIsFocusVisible';\n// TODO: remove this export once ClassNameGenerator is stable\n// eslint-disable-next-line @typescript-eslint/naming-convention\nexport const unstable_ClassNameGenerator = {\n configure: generator => {\n if (process.env.NODE_ENV !== 'production') {\n console.warn(['MUI: `ClassNameGenerator` import from `@mui/material/utils` is outdated and might cause unexpected issues.', '', \"You should use `import { unstable_ClassNameGenerator } from '@mui/material/className'` instead\", '', 'The detail of the issue: https://github.com/mui/material-ui/issues/30011#issuecomment-1024993401', '', 'The updated documentation: https://mui.com/guides/classname-generator/'].join('\\n'));\n }\n ClassNameGenerator.configure(generator);\n }\n};","\"use strict\";\n'use client';\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nObject.defineProperty(exports, \"default\", {\n enumerable: true,\n get: function () {\n return _utils.createSvgIcon;\n }\n});\nvar _utils = require(\"@mui/material/utils\");","\"use strict\";\n\"use client\";\n\nvar _interopRequireDefault = require(\"@babel/runtime/helpers/interopRequireDefault\");\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = void 0;\nvar _createSvgIcon = _interopRequireDefault(require(\"./utils/createSvgIcon\"));\nvar _jsxRuntime = require(\"react/jsx-runtime\");\nvar _default = exports.default = (0, _createSvgIcon.default)( /*#__PURE__*/(0, _jsxRuntime.jsx)(\"path\", {\n d: \"m10 17 5-5-5-5z\"\n}), 'ArrowRight');","/**\n * Determines if a given element is a DOM element name (i.e. not a React component).\n */\nexport function isHostComponent(element) {\n return typeof element === 'string';\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport { isHostComponent } from './isHostComponent';\n\n/**\n * Type of the ownerState based on the type of an element it applies to.\n * This resolves to the provided OwnerState for React components and `undefined` for host components.\n * Falls back to `OwnerState | undefined` when the exact type can't be determined in development time.\n */\n\n/**\n * Appends the ownerState object to the props, merging with the existing one if necessary.\n *\n * @param elementType Type of the element that owns the `existingProps`. If the element is a DOM node or undefined, `ownerState` is not applied.\n * @param otherProps Props of the element.\n * @param ownerState\n */\nexport function appendOwnerState(elementType, otherProps, ownerState) {\n if (elementType === undefined || isHostComponent(elementType)) {\n return otherProps;\n }\n return _extends({}, otherProps, {\n ownerState: _extends({}, otherProps.ownerState, ownerState)\n });\n}","'use client';\n\nimport * as React from 'react';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nconst defaultContextValue = {\n disableDefaultClasses: false\n};\nconst ClassNameConfiguratorContext = /*#__PURE__*/React.createContext(defaultContextValue);\n/**\n * @ignore - internal hook.\n *\n * Wraps the `generateUtilityClass` function and controls how the classes are generated.\n * Currently it only affects whether the classes are applied or not.\n *\n * @returns Function to be called with the `generateUtilityClass` function specific to a component to generate the classes.\n */\nexport function useClassNamesOverride(generateUtilityClass) {\n const {\n disableDefaultClasses\n } = React.useContext(ClassNameConfiguratorContext);\n return slot => {\n if (disableDefaultClasses) {\n return '';\n }\n return generateUtilityClass(slot);\n };\n}\n\n/**\n * Allows to configure the components within to not apply any built-in classes.\n */\nexport function ClassNameConfigurator(props) {\n const {\n disableDefaultClasses,\n children\n } = props;\n const contextValue = React.useMemo(() => ({\n disableDefaultClasses: disableDefaultClasses != null ? disableDefaultClasses : false\n }), [disableDefaultClasses]);\n return /*#__PURE__*/_jsx(ClassNameConfiguratorContext.Provider, {\n value: contextValue,\n children: children\n });\n}","/**\n * Extracts event handlers from a given object.\n * A prop is considered an event handler if it is a function and its name starts with `on`.\n *\n * @param object An object to extract event handlers from.\n * @param excludeKeys An array of keys to exclude from the returned object.\n */\nexport function extractEventHandlers(object, excludeKeys = []) {\n if (object === undefined) {\n return {};\n }\n const result = {};\n Object.keys(object).filter(prop => prop.match(/^on[A-Z]/) && typeof object[prop] === 'function' && !excludeKeys.includes(prop)).forEach(prop => {\n result[prop] = object[prop];\n });\n return result;\n}","/**\n * If `componentProps` is a function, calls it with the provided `ownerState`.\n * Otherwise, just returns `componentProps`.\n */\nexport function resolveComponentProps(componentProps, ownerState, slotState) {\n if (typeof componentProps === 'function') {\n return componentProps(ownerState, slotState);\n }\n return componentProps;\n}","/**\n * Removes event handlers from the given object.\n * A field is considered an event handler if it is a function with a name beginning with `on`.\n *\n * @param object Object to remove event handlers from.\n * @returns Object with event handlers removed.\n */\nexport function omitEventHandlers(object) {\n if (object === undefined) {\n return {};\n }\n const result = {};\n Object.keys(object).filter(prop => !(prop.match(/^on[A-Z]/) && typeof object[prop] === 'function')).forEach(prop => {\n result[prop] = object[prop];\n });\n return result;\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport clsx from 'clsx';\nimport { extractEventHandlers } from './extractEventHandlers';\nimport { omitEventHandlers } from './omitEventHandlers';\n/**\n * Merges the slot component internal props (usually coming from a hook)\n * with the externally provided ones.\n *\n * The merge order is (the latter overrides the former):\n * 1. The internal props (specified as a getter function to work with get*Props hook result)\n * 2. Additional props (specified internally on a Base UI component)\n * 3. External props specified on the owner component. These should only be used on a root slot.\n * 4. External props specified in the `slotProps.*` prop.\n * 5. The `className` prop - combined from all the above.\n * @param parameters\n * @returns\n */\nexport function mergeSlotProps(parameters) {\n const {\n getSlotProps,\n additionalProps,\n externalSlotProps,\n externalForwardedProps,\n className\n } = parameters;\n if (!getSlotProps) {\n // The simpler case - getSlotProps is not defined, so no internal event handlers are defined,\n // so we can simply merge all the props without having to worry about extracting event handlers.\n const joinedClasses = clsx(additionalProps == null ? void 0 : additionalProps.className, className, externalForwardedProps == null ? void 0 : externalForwardedProps.className, externalSlotProps == null ? void 0 : externalSlotProps.className);\n const mergedStyle = _extends({}, additionalProps == null ? void 0 : additionalProps.style, externalForwardedProps == null ? void 0 : externalForwardedProps.style, externalSlotProps == null ? void 0 : externalSlotProps.style);\n const props = _extends({}, additionalProps, externalForwardedProps, externalSlotProps);\n if (joinedClasses.length > 0) {\n props.className = joinedClasses;\n }\n if (Object.keys(mergedStyle).length > 0) {\n props.style = mergedStyle;\n }\n return {\n props,\n internalRef: undefined\n };\n }\n\n // In this case, getSlotProps is responsible for calling the external event handlers.\n // We don't need to include them in the merged props because of this.\n\n const eventHandlers = extractEventHandlers(_extends({}, externalForwardedProps, externalSlotProps));\n const componentsPropsWithoutEventHandlers = omitEventHandlers(externalSlotProps);\n const otherPropsWithoutEventHandlers = omitEventHandlers(externalForwardedProps);\n const internalSlotProps = getSlotProps(eventHandlers);\n\n // The order of classes is important here.\n // Emotion (that we use in libraries consuming Base UI) depends on this order\n // to properly override style. It requires the most important classes to be last\n // (see https://github.com/mui/material-ui/pull/33205) for the related discussion.\n const joinedClasses = clsx(internalSlotProps == null ? void 0 : internalSlotProps.className, additionalProps == null ? void 0 : additionalProps.className, className, externalForwardedProps == null ? void 0 : externalForwardedProps.className, externalSlotProps == null ? void 0 : externalSlotProps.className);\n const mergedStyle = _extends({}, internalSlotProps == null ? void 0 : internalSlotProps.style, additionalProps == null ? void 0 : additionalProps.style, externalForwardedProps == null ? void 0 : externalForwardedProps.style, externalSlotProps == null ? void 0 : externalSlotProps.style);\n const props = _extends({}, internalSlotProps, additionalProps, otherPropsWithoutEventHandlers, componentsPropsWithoutEventHandlers);\n if (joinedClasses.length > 0) {\n props.className = joinedClasses;\n }\n if (Object.keys(mergedStyle).length > 0) {\n props.style = mergedStyle;\n }\n return {\n props,\n internalRef: internalSlotProps.ref\n };\n}","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"elementType\", \"externalSlotProps\", \"ownerState\", \"skipResolvingSlotProps\"];\nimport { unstable_useForkRef as useForkRef } from '@mui/utils';\nimport { appendOwnerState } from './appendOwnerState';\nimport { mergeSlotProps } from './mergeSlotProps';\nimport { resolveComponentProps } from './resolveComponentProps';\n/**\n * @ignore - do not document.\n * Builds the props to be passed into the slot of an unstyled component.\n * It merges the internal props of the component with the ones supplied by the user, allowing to customize the behavior.\n * If the slot component is not a host component, it also merges in the `ownerState`.\n *\n * @param parameters.getSlotProps - A function that returns the props to be passed to the slot component.\n */\nexport function useSlotProps(parameters) {\n var _parameters$additiona;\n const {\n elementType,\n externalSlotProps,\n ownerState,\n skipResolvingSlotProps = false\n } = parameters,\n rest = _objectWithoutPropertiesLoose(parameters, _excluded);\n const resolvedComponentsProps = skipResolvingSlotProps ? {} : resolveComponentProps(externalSlotProps, ownerState);\n const {\n props: mergedProps,\n internalRef\n } = mergeSlotProps(_extends({}, rest, {\n externalSlotProps: resolvedComponentsProps\n }));\n const ref = useForkRef(internalRef, resolvedComponentsProps == null ? void 0 : resolvedComponentsProps.ref, (_parameters$additiona = parameters.additionalProps) == null ? void 0 : _parameters$additiona.ref);\n const props = appendOwnerState(elementType, _extends({}, mergedProps, {\n ref\n }), ownerState);\n return props;\n}","import { globalStateClasses } from '@mui/utils/generateUtilityClass';\nconst GLOBAL_CLASS_PREFIX = 'base';\nfunction buildStateClass(state) {\n return `${GLOBAL_CLASS_PREFIX}--${state}`;\n}\nfunction buildSlotClass(componentName, slot) {\n return `${GLOBAL_CLASS_PREFIX}-${componentName}-${slot}`;\n}\nexport function generateUtilityClass(componentName, slot) {\n const globalStateClass = globalStateClasses[slot];\n return globalStateClass ? buildStateClass(globalStateClass) : buildSlotClass(componentName, slot);\n}\nexport function isGlobalState(slot) {\n return globalStateClasses[slot] !== undefined;\n}","import { generateUtilityClass } from '../generateUtilityClass';\nexport function generateUtilityClasses(componentName, slots) {\n const result = {};\n slots.forEach(slot => {\n result[slot] = generateUtilityClass(componentName, slot);\n });\n return result;\n}","'use client';\n\nimport * as React from 'react';\nimport * as ReactDOM from 'react-dom';\nimport PropTypes from 'prop-types';\nimport { exactProp, HTMLElementType, unstable_useEnhancedEffect as useEnhancedEffect, unstable_useForkRef as useForkRef, unstable_setRef as setRef } from '@mui/utils';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nfunction getContainer(container) {\n return typeof container === 'function' ? container() : container;\n}\n\n/**\n * Portals provide a first-class way to render children into a DOM node\n * that exists outside the DOM hierarchy of the parent component.\n *\n * Demos:\n *\n * - [Portal](https://mui.com/base-ui/react-portal/)\n *\n * API:\n *\n * - [Portal API](https://mui.com/base-ui/react-portal/components-api/#portal)\n */\nconst Portal = /*#__PURE__*/React.forwardRef(function Portal(props, forwardedRef) {\n const {\n children,\n container,\n disablePortal = false\n } = props;\n const [mountNode, setMountNode] = React.useState(null);\n // @ts-expect-error TODO upstream fix\n const handleRef = useForkRef( /*#__PURE__*/React.isValidElement(children) ? children.ref : null, forwardedRef);\n useEnhancedEffect(() => {\n if (!disablePortal) {\n setMountNode(getContainer(container) || document.body);\n }\n }, [container, disablePortal]);\n useEnhancedEffect(() => {\n if (mountNode && !disablePortal) {\n setRef(forwardedRef, mountNode);\n return () => {\n setRef(forwardedRef, null);\n };\n }\n return undefined;\n }, [forwardedRef, mountNode, disablePortal]);\n if (disablePortal) {\n if ( /*#__PURE__*/React.isValidElement(children)) {\n const newProps = {\n ref: handleRef\n };\n return /*#__PURE__*/React.cloneElement(children, newProps);\n }\n return /*#__PURE__*/_jsx(React.Fragment, {\n children: children\n });\n }\n return /*#__PURE__*/_jsx(React.Fragment, {\n children: mountNode ? /*#__PURE__*/ReactDOM.createPortal(children, mountNode) : mountNode\n });\n});\nprocess.env.NODE_ENV !== \"production\" ? Portal.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * The children to render into the `container`.\n */\n children: PropTypes.node,\n /**\n * An HTML element or function that returns one.\n * The `container` will have the portal children appended to it.\n *\n * You can also provide a callback, which is called in a React layout effect.\n * This lets you set the container from a ref, and also makes server-side rendering possible.\n *\n * By default, it uses the body of the top-level document object,\n * so it's simply `document.body` most of the time.\n */\n container: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.func]),\n /**\n * The `children` will be under the DOM hierarchy of the parent component.\n * @default false\n */\n disablePortal: PropTypes.bool\n} : void 0;\nif (process.env.NODE_ENV !== 'production') {\n // eslint-disable-next-line\n Portal['propTypes' + ''] = exactProp(Portal.propTypes);\n}\nexport { Portal };","export var top = 'top';\nexport var bottom = 'bottom';\nexport var right = 'right';\nexport var left = 'left';\nexport var auto = 'auto';\nexport var basePlacements = [top, bottom, right, left];\nexport var start = 'start';\nexport var end = 'end';\nexport var clippingParents = 'clippingParents';\nexport var viewport = 'viewport';\nexport var popper = 'popper';\nexport var reference = 'reference';\nexport var variationPlacements = /*#__PURE__*/basePlacements.reduce(function (acc, placement) {\n return acc.concat([placement + \"-\" + start, placement + \"-\" + end]);\n}, []);\nexport var placements = /*#__PURE__*/[].concat(basePlacements, [auto]).reduce(function (acc, placement) {\n return acc.concat([placement, placement + \"-\" + start, placement + \"-\" + end]);\n}, []); // modifiers that need to read the DOM\n\nexport var beforeRead = 'beforeRead';\nexport var read = 'read';\nexport var afterRead = 'afterRead'; // pure-logic modifiers\n\nexport var beforeMain = 'beforeMain';\nexport var main = 'main';\nexport var afterMain = 'afterMain'; // modifier with the purpose to write to the DOM (or write into a framework state)\n\nexport var beforeWrite = 'beforeWrite';\nexport var write = 'write';\nexport var afterWrite = 'afterWrite';\nexport var modifierPhases = [beforeRead, read, afterRead, beforeMain, main, afterMain, beforeWrite, write, afterWrite];","export default function getNodeName(element) {\n return element ? (element.nodeName || '').toLowerCase() : null;\n}","export default function getWindow(node) {\n if (node == null) {\n return window;\n }\n\n if (node.toString() !== '[object Window]') {\n var ownerDocument = node.ownerDocument;\n return ownerDocument ? ownerDocument.defaultView || window : window;\n }\n\n return node;\n}","import getWindow from \"./getWindow.js\";\n\nfunction isElement(node) {\n var OwnElement = getWindow(node).Element;\n return node instanceof OwnElement || node instanceof Element;\n}\n\nfunction isHTMLElement(node) {\n var OwnElement = getWindow(node).HTMLElement;\n return node instanceof OwnElement || node instanceof HTMLElement;\n}\n\nfunction isShadowRoot(node) {\n // IE 11 has no ShadowRoot\n if (typeof ShadowRoot === 'undefined') {\n return false;\n }\n\n var OwnElement = getWindow(node).ShadowRoot;\n return node instanceof OwnElement || node instanceof ShadowRoot;\n}\n\nexport { isElement, isHTMLElement, isShadowRoot };","import getNodeName from \"../dom-utils/getNodeName.js\";\nimport { isHTMLElement } from \"../dom-utils/instanceOf.js\"; // This modifier takes the styles prepared by the `computeStyles` modifier\n// and applies them to the HTMLElements such as popper and arrow\n\nfunction applyStyles(_ref) {\n var state = _ref.state;\n Object.keys(state.elements).forEach(function (name) {\n var style = state.styles[name] || {};\n var attributes = state.attributes[name] || {};\n var element = state.elements[name]; // arrow is optional + virtual elements\n\n if (!isHTMLElement(element) || !getNodeName(element)) {\n return;\n } // Flow doesn't support to extend this property, but it's the most\n // effective way to apply styles to an HTMLElement\n // $FlowFixMe[cannot-write]\n\n\n Object.assign(element.style, style);\n Object.keys(attributes).forEach(function (name) {\n var value = attributes[name];\n\n if (value === false) {\n element.removeAttribute(name);\n } else {\n element.setAttribute(name, value === true ? '' : value);\n }\n });\n });\n}\n\nfunction effect(_ref2) {\n var state = _ref2.state;\n var initialStyles = {\n popper: {\n position: state.options.strategy,\n left: '0',\n top: '0',\n margin: '0'\n },\n arrow: {\n position: 'absolute'\n },\n reference: {}\n };\n Object.assign(state.elements.popper.style, initialStyles.popper);\n state.styles = initialStyles;\n\n if (state.elements.arrow) {\n Object.assign(state.elements.arrow.style, initialStyles.arrow);\n }\n\n return function () {\n Object.keys(state.elements).forEach(function (name) {\n var element = state.elements[name];\n var attributes = state.attributes[name] || {};\n var styleProperties = Object.keys(state.styles.hasOwnProperty(name) ? state.styles[name] : initialStyles[name]); // Set all values to an empty string to unset them\n\n var style = styleProperties.reduce(function (style, property) {\n style[property] = '';\n return style;\n }, {}); // arrow is optional + virtual elements\n\n if (!isHTMLElement(element) || !getNodeName(element)) {\n return;\n }\n\n Object.assign(element.style, style);\n Object.keys(attributes).forEach(function (attribute) {\n element.removeAttribute(attribute);\n });\n });\n };\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'applyStyles',\n enabled: true,\n phase: 'write',\n fn: applyStyles,\n effect: effect,\n requires: ['computeStyles']\n};","import { auto } from \"../enums.js\";\nexport default function getBasePlacement(placement) {\n return placement.split('-')[0];\n}","export var max = Math.max;\nexport var min = Math.min;\nexport var round = Math.round;","export default function getUAString() {\n var uaData = navigator.userAgentData;\n\n if (uaData != null && uaData.brands && Array.isArray(uaData.brands)) {\n return uaData.brands.map(function (item) {\n return item.brand + \"/\" + item.version;\n }).join(' ');\n }\n\n return navigator.userAgent;\n}","import getUAString from \"../utils/userAgent.js\";\nexport default function isLayoutViewport() {\n return !/^((?!chrome|android).)*safari/i.test(getUAString());\n}","import { isElement, isHTMLElement } from \"./instanceOf.js\";\nimport { round } from \"../utils/math.js\";\nimport getWindow from \"./getWindow.js\";\nimport isLayoutViewport from \"./isLayoutViewport.js\";\nexport default function getBoundingClientRect(element, includeScale, isFixedStrategy) {\n if (includeScale === void 0) {\n includeScale = false;\n }\n\n if (isFixedStrategy === void 0) {\n isFixedStrategy = false;\n }\n\n var clientRect = element.getBoundingClientRect();\n var scaleX = 1;\n var scaleY = 1;\n\n if (includeScale && isHTMLElement(element)) {\n scaleX = element.offsetWidth > 0 ? round(clientRect.width) / element.offsetWidth || 1 : 1;\n scaleY = element.offsetHeight > 0 ? round(clientRect.height) / element.offsetHeight || 1 : 1;\n }\n\n var _ref = isElement(element) ? getWindow(element) : window,\n visualViewport = _ref.visualViewport;\n\n var addVisualOffsets = !isLayoutViewport() && isFixedStrategy;\n var x = (clientRect.left + (addVisualOffsets && visualViewport ? visualViewport.offsetLeft : 0)) / scaleX;\n var y = (clientRect.top + (addVisualOffsets && visualViewport ? visualViewport.offsetTop : 0)) / scaleY;\n var width = clientRect.width / scaleX;\n var height = clientRect.height / scaleY;\n return {\n width: width,\n height: height,\n top: y,\n right: x + width,\n bottom: y + height,\n left: x,\n x: x,\n y: y\n };\n}","import getBoundingClientRect from \"./getBoundingClientRect.js\"; // Returns the layout rect of an element relative to its offsetParent. Layout\n// means it doesn't take into account transforms.\n\nexport default function getLayoutRect(element) {\n var clientRect = getBoundingClientRect(element); // Use the clientRect sizes if it's not been transformed.\n // Fixes https://github.com/popperjs/popper-core/issues/1223\n\n var width = element.offsetWidth;\n var height = element.offsetHeight;\n\n if (Math.abs(clientRect.width - width) <= 1) {\n width = clientRect.width;\n }\n\n if (Math.abs(clientRect.height - height) <= 1) {\n height = clientRect.height;\n }\n\n return {\n x: element.offsetLeft,\n y: element.offsetTop,\n width: width,\n height: height\n };\n}","import { isShadowRoot } from \"./instanceOf.js\";\nexport default function contains(parent, child) {\n var rootNode = child.getRootNode && child.getRootNode(); // First, attempt with faster native method\n\n if (parent.contains(child)) {\n return true;\n } // then fallback to custom implementation with Shadow DOM support\n else if (rootNode && isShadowRoot(rootNode)) {\n var next = child;\n\n do {\n if (next && parent.isSameNode(next)) {\n return true;\n } // $FlowFixMe[prop-missing]: need a better way to handle this...\n\n\n next = next.parentNode || next.host;\n } while (next);\n } // Give up, the result is false\n\n\n return false;\n}","import getWindow from \"./getWindow.js\";\nexport default function getComputedStyle(element) {\n return getWindow(element).getComputedStyle(element);\n}","import getNodeName from \"./getNodeName.js\";\nexport default function isTableElement(element) {\n return ['table', 'td', 'th'].indexOf(getNodeName(element)) >= 0;\n}","import { isElement } from \"./instanceOf.js\";\nexport default function getDocumentElement(element) {\n // $FlowFixMe[incompatible-return]: assume body is always available\n return ((isElement(element) ? element.ownerDocument : // $FlowFixMe[prop-missing]\n element.document) || window.document).documentElement;\n}","import getNodeName from \"./getNodeName.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport { isShadowRoot } from \"./instanceOf.js\";\nexport default function getParentNode(element) {\n if (getNodeName(element) === 'html') {\n return element;\n }\n\n return (// this is a quicker (but less type safe) way to save quite some bytes from the bundle\n // $FlowFixMe[incompatible-return]\n // $FlowFixMe[prop-missing]\n element.assignedSlot || // step into the shadow DOM of the parent of a slotted node\n element.parentNode || ( // DOM Element detected\n isShadowRoot(element) ? element.host : null) || // ShadowRoot detected\n // $FlowFixMe[incompatible-call]: HTMLElement is a Node\n getDocumentElement(element) // fallback\n\n );\n}","import getWindow from \"./getWindow.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport getComputedStyle from \"./getComputedStyle.js\";\nimport { isHTMLElement, isShadowRoot } from \"./instanceOf.js\";\nimport isTableElement from \"./isTableElement.js\";\nimport getParentNode from \"./getParentNode.js\";\nimport getUAString from \"../utils/userAgent.js\";\n\nfunction getTrueOffsetParent(element) {\n if (!isHTMLElement(element) || // https://github.com/popperjs/popper-core/issues/837\n getComputedStyle(element).position === 'fixed') {\n return null;\n }\n\n return element.offsetParent;\n} // `.offsetParent` reports `null` for fixed elements, while absolute elements\n// return the containing block\n\n\nfunction getContainingBlock(element) {\n var isFirefox = /firefox/i.test(getUAString());\n var isIE = /Trident/i.test(getUAString());\n\n if (isIE && isHTMLElement(element)) {\n // In IE 9, 10 and 11 fixed elements containing block is always established by the viewport\n var elementCss = getComputedStyle(element);\n\n if (elementCss.position === 'fixed') {\n return null;\n }\n }\n\n var currentNode = getParentNode(element);\n\n if (isShadowRoot(currentNode)) {\n currentNode = currentNode.host;\n }\n\n while (isHTMLElement(currentNode) && ['html', 'body'].indexOf(getNodeName(currentNode)) < 0) {\n var css = getComputedStyle(currentNode); // This is non-exhaustive but covers the most common CSS properties that\n // create a containing block.\n // https://developer.mozilla.org/en-US/docs/Web/CSS/Containing_block#identifying_the_containing_block\n\n if (css.transform !== 'none' || css.perspective !== 'none' || css.contain === 'paint' || ['transform', 'perspective'].indexOf(css.willChange) !== -1 || isFirefox && css.willChange === 'filter' || isFirefox && css.filter && css.filter !== 'none') {\n return currentNode;\n } else {\n currentNode = currentNode.parentNode;\n }\n }\n\n return null;\n} // Gets the closest ancestor positioned element. Handles some edge cases,\n// such as table ancestors and cross browser bugs.\n\n\nexport default function getOffsetParent(element) {\n var window = getWindow(element);\n var offsetParent = getTrueOffsetParent(element);\n\n while (offsetParent && isTableElement(offsetParent) && getComputedStyle(offsetParent).position === 'static') {\n offsetParent = getTrueOffsetParent(offsetParent);\n }\n\n if (offsetParent && (getNodeName(offsetParent) === 'html' || getNodeName(offsetParent) === 'body' && getComputedStyle(offsetParent).position === 'static')) {\n return window;\n }\n\n return offsetParent || getContainingBlock(element) || window;\n}","export default function getMainAxisFromPlacement(placement) {\n return ['top', 'bottom'].indexOf(placement) >= 0 ? 'x' : 'y';\n}","import { max as mathMax, min as mathMin } from \"./math.js\";\nexport function within(min, value, max) {\n return mathMax(min, mathMin(value, max));\n}\nexport function withinMaxClamp(min, value, max) {\n var v = within(min, value, max);\n return v > max ? max : v;\n}","export default function getFreshSideObject() {\n return {\n top: 0,\n right: 0,\n bottom: 0,\n left: 0\n };\n}","import getFreshSideObject from \"./getFreshSideObject.js\";\nexport default function mergePaddingObject(paddingObject) {\n return Object.assign({}, getFreshSideObject(), paddingObject);\n}","export default function expandToHashMap(value, keys) {\n return keys.reduce(function (hashMap, key) {\n hashMap[key] = value;\n return hashMap;\n }, {});\n}","import getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getLayoutRect from \"../dom-utils/getLayoutRect.js\";\nimport contains from \"../dom-utils/contains.js\";\nimport getOffsetParent from \"../dom-utils/getOffsetParent.js\";\nimport getMainAxisFromPlacement from \"../utils/getMainAxisFromPlacement.js\";\nimport { within } from \"../utils/within.js\";\nimport mergePaddingObject from \"../utils/mergePaddingObject.js\";\nimport expandToHashMap from \"../utils/expandToHashMap.js\";\nimport { left, right, basePlacements, top, bottom } from \"../enums.js\"; // eslint-disable-next-line import/no-unused-modules\n\nvar toPaddingObject = function toPaddingObject(padding, state) {\n padding = typeof padding === 'function' ? padding(Object.assign({}, state.rects, {\n placement: state.placement\n })) : padding;\n return mergePaddingObject(typeof padding !== 'number' ? padding : expandToHashMap(padding, basePlacements));\n};\n\nfunction arrow(_ref) {\n var _state$modifiersData$;\n\n var state = _ref.state,\n name = _ref.name,\n options = _ref.options;\n var arrowElement = state.elements.arrow;\n var popperOffsets = state.modifiersData.popperOffsets;\n var basePlacement = getBasePlacement(state.placement);\n var axis = getMainAxisFromPlacement(basePlacement);\n var isVertical = [left, right].indexOf(basePlacement) >= 0;\n var len = isVertical ? 'height' : 'width';\n\n if (!arrowElement || !popperOffsets) {\n return;\n }\n\n var paddingObject = toPaddingObject(options.padding, state);\n var arrowRect = getLayoutRect(arrowElement);\n var minProp = axis === 'y' ? top : left;\n var maxProp = axis === 'y' ? bottom : right;\n var endDiff = state.rects.reference[len] + state.rects.reference[axis] - popperOffsets[axis] - state.rects.popper[len];\n var startDiff = popperOffsets[axis] - state.rects.reference[axis];\n var arrowOffsetParent = getOffsetParent(arrowElement);\n var clientSize = arrowOffsetParent ? axis === 'y' ? arrowOffsetParent.clientHeight || 0 : arrowOffsetParent.clientWidth || 0 : 0;\n var centerToReference = endDiff / 2 - startDiff / 2; // Make sure the arrow doesn't overflow the popper if the center point is\n // outside of the popper bounds\n\n var min = paddingObject[minProp];\n var max = clientSize - arrowRect[len] - paddingObject[maxProp];\n var center = clientSize / 2 - arrowRect[len] / 2 + centerToReference;\n var offset = within(min, center, max); // Prevents breaking syntax highlighting...\n\n var axisProp = axis;\n state.modifiersData[name] = (_state$modifiersData$ = {}, _state$modifiersData$[axisProp] = offset, _state$modifiersData$.centerOffset = offset - center, _state$modifiersData$);\n}\n\nfunction effect(_ref2) {\n var state = _ref2.state,\n options = _ref2.options;\n var _options$element = options.element,\n arrowElement = _options$element === void 0 ? '[data-popper-arrow]' : _options$element;\n\n if (arrowElement == null) {\n return;\n } // CSS selector\n\n\n if (typeof arrowElement === 'string') {\n arrowElement = state.elements.popper.querySelector(arrowElement);\n\n if (!arrowElement) {\n return;\n }\n }\n\n if (!contains(state.elements.popper, arrowElement)) {\n return;\n }\n\n state.elements.arrow = arrowElement;\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'arrow',\n enabled: true,\n phase: 'main',\n fn: arrow,\n effect: effect,\n requires: ['popperOffsets'],\n requiresIfExists: ['preventOverflow']\n};","export default function getVariation(placement) {\n return placement.split('-')[1];\n}","import { top, left, right, bottom, end } from \"../enums.js\";\nimport getOffsetParent from \"../dom-utils/getOffsetParent.js\";\nimport getWindow from \"../dom-utils/getWindow.js\";\nimport getDocumentElement from \"../dom-utils/getDocumentElement.js\";\nimport getComputedStyle from \"../dom-utils/getComputedStyle.js\";\nimport getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getVariation from \"../utils/getVariation.js\";\nimport { round } from \"../utils/math.js\"; // eslint-disable-next-line import/no-unused-modules\n\nvar unsetSides = {\n top: 'auto',\n right: 'auto',\n bottom: 'auto',\n left: 'auto'\n}; // Round the offsets to the nearest suitable subpixel based on the DPR.\n// Zooming can change the DPR, but it seems to report a value that will\n// cleanly divide the values into the appropriate subpixels.\n\nfunction roundOffsetsByDPR(_ref, win) {\n var x = _ref.x,\n y = _ref.y;\n var dpr = win.devicePixelRatio || 1;\n return {\n x: round(x * dpr) / dpr || 0,\n y: round(y * dpr) / dpr || 0\n };\n}\n\nexport function mapToStyles(_ref2) {\n var _Object$assign2;\n\n var popper = _ref2.popper,\n popperRect = _ref2.popperRect,\n placement = _ref2.placement,\n variation = _ref2.variation,\n offsets = _ref2.offsets,\n position = _ref2.position,\n gpuAcceleration = _ref2.gpuAcceleration,\n adaptive = _ref2.adaptive,\n roundOffsets = _ref2.roundOffsets,\n isFixed = _ref2.isFixed;\n var _offsets$x = offsets.x,\n x = _offsets$x === void 0 ? 0 : _offsets$x,\n _offsets$y = offsets.y,\n y = _offsets$y === void 0 ? 0 : _offsets$y;\n\n var _ref3 = typeof roundOffsets === 'function' ? roundOffsets({\n x: x,\n y: y\n }) : {\n x: x,\n y: y\n };\n\n x = _ref3.x;\n y = _ref3.y;\n var hasX = offsets.hasOwnProperty('x');\n var hasY = offsets.hasOwnProperty('y');\n var sideX = left;\n var sideY = top;\n var win = window;\n\n if (adaptive) {\n var offsetParent = getOffsetParent(popper);\n var heightProp = 'clientHeight';\n var widthProp = 'clientWidth';\n\n if (offsetParent === getWindow(popper)) {\n offsetParent = getDocumentElement(popper);\n\n if (getComputedStyle(offsetParent).position !== 'static' && position === 'absolute') {\n heightProp = 'scrollHeight';\n widthProp = 'scrollWidth';\n }\n } // $FlowFixMe[incompatible-cast]: force type refinement, we compare offsetParent with window above, but Flow doesn't detect it\n\n\n offsetParent = offsetParent;\n\n if (placement === top || (placement === left || placement === right) && variation === end) {\n sideY = bottom;\n var offsetY = isFixed && offsetParent === win && win.visualViewport ? win.visualViewport.height : // $FlowFixMe[prop-missing]\n offsetParent[heightProp];\n y -= offsetY - popperRect.height;\n y *= gpuAcceleration ? 1 : -1;\n }\n\n if (placement === left || (placement === top || placement === bottom) && variation === end) {\n sideX = right;\n var offsetX = isFixed && offsetParent === win && win.visualViewport ? win.visualViewport.width : // $FlowFixMe[prop-missing]\n offsetParent[widthProp];\n x -= offsetX - popperRect.width;\n x *= gpuAcceleration ? 1 : -1;\n }\n }\n\n var commonStyles = Object.assign({\n position: position\n }, adaptive && unsetSides);\n\n var _ref4 = roundOffsets === true ? roundOffsetsByDPR({\n x: x,\n y: y\n }, getWindow(popper)) : {\n x: x,\n y: y\n };\n\n x = _ref4.x;\n y = _ref4.y;\n\n if (gpuAcceleration) {\n var _Object$assign;\n\n return Object.assign({}, commonStyles, (_Object$assign = {}, _Object$assign[sideY] = hasY ? '0' : '', _Object$assign[sideX] = hasX ? '0' : '', _Object$assign.transform = (win.devicePixelRatio || 1) <= 1 ? \"translate(\" + x + \"px, \" + y + \"px)\" : \"translate3d(\" + x + \"px, \" + y + \"px, 0)\", _Object$assign));\n }\n\n return Object.assign({}, commonStyles, (_Object$assign2 = {}, _Object$assign2[sideY] = hasY ? y + \"px\" : '', _Object$assign2[sideX] = hasX ? x + \"px\" : '', _Object$assign2.transform = '', _Object$assign2));\n}\n\nfunction computeStyles(_ref5) {\n var state = _ref5.state,\n options = _ref5.options;\n var _options$gpuAccelerat = options.gpuAcceleration,\n gpuAcceleration = _options$gpuAccelerat === void 0 ? true : _options$gpuAccelerat,\n _options$adaptive = options.adaptive,\n adaptive = _options$adaptive === void 0 ? true : _options$adaptive,\n _options$roundOffsets = options.roundOffsets,\n roundOffsets = _options$roundOffsets === void 0 ? true : _options$roundOffsets;\n var commonStyles = {\n placement: getBasePlacement(state.placement),\n variation: getVariation(state.placement),\n popper: state.elements.popper,\n popperRect: state.rects.popper,\n gpuAcceleration: gpuAcceleration,\n isFixed: state.options.strategy === 'fixed'\n };\n\n if (state.modifiersData.popperOffsets != null) {\n state.styles.popper = Object.assign({}, state.styles.popper, mapToStyles(Object.assign({}, commonStyles, {\n offsets: state.modifiersData.popperOffsets,\n position: state.options.strategy,\n adaptive: adaptive,\n roundOffsets: roundOffsets\n })));\n }\n\n if (state.modifiersData.arrow != null) {\n state.styles.arrow = Object.assign({}, state.styles.arrow, mapToStyles(Object.assign({}, commonStyles, {\n offsets: state.modifiersData.arrow,\n position: 'absolute',\n adaptive: false,\n roundOffsets: roundOffsets\n })));\n }\n\n state.attributes.popper = Object.assign({}, state.attributes.popper, {\n 'data-popper-placement': state.placement\n });\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'computeStyles',\n enabled: true,\n phase: 'beforeWrite',\n fn: computeStyles,\n data: {}\n};","import getWindow from \"../dom-utils/getWindow.js\"; // eslint-disable-next-line import/no-unused-modules\n\nvar passive = {\n passive: true\n};\n\nfunction effect(_ref) {\n var state = _ref.state,\n instance = _ref.instance,\n options = _ref.options;\n var _options$scroll = options.scroll,\n scroll = _options$scroll === void 0 ? true : _options$scroll,\n _options$resize = options.resize,\n resize = _options$resize === void 0 ? true : _options$resize;\n var window = getWindow(state.elements.popper);\n var scrollParents = [].concat(state.scrollParents.reference, state.scrollParents.popper);\n\n if (scroll) {\n scrollParents.forEach(function (scrollParent) {\n scrollParent.addEventListener('scroll', instance.update, passive);\n });\n }\n\n if (resize) {\n window.addEventListener('resize', instance.update, passive);\n }\n\n return function () {\n if (scroll) {\n scrollParents.forEach(function (scrollParent) {\n scrollParent.removeEventListener('scroll', instance.update, passive);\n });\n }\n\n if (resize) {\n window.removeEventListener('resize', instance.update, passive);\n }\n };\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'eventListeners',\n enabled: true,\n phase: 'write',\n fn: function fn() {},\n effect: effect,\n data: {}\n};","var hash = {\n left: 'right',\n right: 'left',\n bottom: 'top',\n top: 'bottom'\n};\nexport default function getOppositePlacement(placement) {\n return placement.replace(/left|right|bottom|top/g, function (matched) {\n return hash[matched];\n });\n}","var hash = {\n start: 'end',\n end: 'start'\n};\nexport default function getOppositeVariationPlacement(placement) {\n return placement.replace(/start|end/g, function (matched) {\n return hash[matched];\n });\n}","import getWindow from \"./getWindow.js\";\nexport default function getWindowScroll(node) {\n var win = getWindow(node);\n var scrollLeft = win.pageXOffset;\n var scrollTop = win.pageYOffset;\n return {\n scrollLeft: scrollLeft,\n scrollTop: scrollTop\n };\n}","import getBoundingClientRect from \"./getBoundingClientRect.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport getWindowScroll from \"./getWindowScroll.js\";\nexport default function getWindowScrollBarX(element) {\n // If has a CSS width greater than the viewport, then this will be\n // incorrect for RTL.\n // Popper 1 is broken in this case and never had a bug report so let's assume\n // it's not an issue. I don't think anyone ever specifies width on \n // anyway.\n // Browsers where the left scrollbar doesn't cause an issue report `0` for\n // this (e.g. Edge 2019, IE11, Safari)\n return getBoundingClientRect(getDocumentElement(element)).left + getWindowScroll(element).scrollLeft;\n}","import getWindow from \"./getWindow.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport getWindowScrollBarX from \"./getWindowScrollBarX.js\";\nimport isLayoutViewport from \"./isLayoutViewport.js\";\nexport default function getViewportRect(element, strategy) {\n var win = getWindow(element);\n var html = getDocumentElement(element);\n var visualViewport = win.visualViewport;\n var width = html.clientWidth;\n var height = html.clientHeight;\n var x = 0;\n var y = 0;\n\n if (visualViewport) {\n width = visualViewport.width;\n height = visualViewport.height;\n var layoutViewport = isLayoutViewport();\n\n if (layoutViewport || !layoutViewport && strategy === 'fixed') {\n x = visualViewport.offsetLeft;\n y = visualViewport.offsetTop;\n }\n }\n\n return {\n width: width,\n height: height,\n x: x + getWindowScrollBarX(element),\n y: y\n };\n}","import getDocumentElement from \"./getDocumentElement.js\";\nimport getComputedStyle from \"./getComputedStyle.js\";\nimport getWindowScrollBarX from \"./getWindowScrollBarX.js\";\nimport getWindowScroll from \"./getWindowScroll.js\";\nimport { max } from \"../utils/math.js\"; // Gets the entire size of the scrollable document area, even extending outside\n// of the `` and `` rect bounds if horizontally scrollable\n\nexport default function getDocumentRect(element) {\n var _element$ownerDocumen;\n\n var html = getDocumentElement(element);\n var winScroll = getWindowScroll(element);\n var body = (_element$ownerDocumen = element.ownerDocument) == null ? void 0 : _element$ownerDocumen.body;\n var width = max(html.scrollWidth, html.clientWidth, body ? body.scrollWidth : 0, body ? body.clientWidth : 0);\n var height = max(html.scrollHeight, html.clientHeight, body ? body.scrollHeight : 0, body ? body.clientHeight : 0);\n var x = -winScroll.scrollLeft + getWindowScrollBarX(element);\n var y = -winScroll.scrollTop;\n\n if (getComputedStyle(body || html).direction === 'rtl') {\n x += max(html.clientWidth, body ? body.clientWidth : 0) - width;\n }\n\n return {\n width: width,\n height: height,\n x: x,\n y: y\n };\n}","import getComputedStyle from \"./getComputedStyle.js\";\nexport default function isScrollParent(element) {\n // Firefox wants us to check `-x` and `-y` variations as well\n var _getComputedStyle = getComputedStyle(element),\n overflow = _getComputedStyle.overflow,\n overflowX = _getComputedStyle.overflowX,\n overflowY = _getComputedStyle.overflowY;\n\n return /auto|scroll|overlay|hidden/.test(overflow + overflowY + overflowX);\n}","import getParentNode from \"./getParentNode.js\";\nimport isScrollParent from \"./isScrollParent.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport { isHTMLElement } from \"./instanceOf.js\";\nexport default function getScrollParent(node) {\n if (['html', 'body', '#document'].indexOf(getNodeName(node)) >= 0) {\n // $FlowFixMe[incompatible-return]: assume body is always available\n return node.ownerDocument.body;\n }\n\n if (isHTMLElement(node) && isScrollParent(node)) {\n return node;\n }\n\n return getScrollParent(getParentNode(node));\n}","import getScrollParent from \"./getScrollParent.js\";\nimport getParentNode from \"./getParentNode.js\";\nimport getWindow from \"./getWindow.js\";\nimport isScrollParent from \"./isScrollParent.js\";\n/*\ngiven a DOM element, return the list of all scroll parents, up the list of ancesors\nuntil we get to the top window object. This list is what we attach scroll listeners\nto, because if any of these parent elements scroll, we'll need to re-calculate the\nreference element's position.\n*/\n\nexport default function listScrollParents(element, list) {\n var _element$ownerDocumen;\n\n if (list === void 0) {\n list = [];\n }\n\n var scrollParent = getScrollParent(element);\n var isBody = scrollParent === ((_element$ownerDocumen = element.ownerDocument) == null ? void 0 : _element$ownerDocumen.body);\n var win = getWindow(scrollParent);\n var target = isBody ? [win].concat(win.visualViewport || [], isScrollParent(scrollParent) ? scrollParent : []) : scrollParent;\n var updatedList = list.concat(target);\n return isBody ? updatedList : // $FlowFixMe[incompatible-call]: isBody tells us target will be an HTMLElement here\n updatedList.concat(listScrollParents(getParentNode(target)));\n}","export default function rectToClientRect(rect) {\n return Object.assign({}, rect, {\n left: rect.x,\n top: rect.y,\n right: rect.x + rect.width,\n bottom: rect.y + rect.height\n });\n}","import { viewport } from \"../enums.js\";\nimport getViewportRect from \"./getViewportRect.js\";\nimport getDocumentRect from \"./getDocumentRect.js\";\nimport listScrollParents from \"./listScrollParents.js\";\nimport getOffsetParent from \"./getOffsetParent.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport getComputedStyle from \"./getComputedStyle.js\";\nimport { isElement, isHTMLElement } from \"./instanceOf.js\";\nimport getBoundingClientRect from \"./getBoundingClientRect.js\";\nimport getParentNode from \"./getParentNode.js\";\nimport contains from \"./contains.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport rectToClientRect from \"../utils/rectToClientRect.js\";\nimport { max, min } from \"../utils/math.js\";\n\nfunction getInnerBoundingClientRect(element, strategy) {\n var rect = getBoundingClientRect(element, false, strategy === 'fixed');\n rect.top = rect.top + element.clientTop;\n rect.left = rect.left + element.clientLeft;\n rect.bottom = rect.top + element.clientHeight;\n rect.right = rect.left + element.clientWidth;\n rect.width = element.clientWidth;\n rect.height = element.clientHeight;\n rect.x = rect.left;\n rect.y = rect.top;\n return rect;\n}\n\nfunction getClientRectFromMixedType(element, clippingParent, strategy) {\n return clippingParent === viewport ? rectToClientRect(getViewportRect(element, strategy)) : isElement(clippingParent) ? getInnerBoundingClientRect(clippingParent, strategy) : rectToClientRect(getDocumentRect(getDocumentElement(element)));\n} // A \"clipping parent\" is an overflowable container with the characteristic of\n// clipping (or hiding) overflowing elements with a position different from\n// `initial`\n\n\nfunction getClippingParents(element) {\n var clippingParents = listScrollParents(getParentNode(element));\n var canEscapeClipping = ['absolute', 'fixed'].indexOf(getComputedStyle(element).position) >= 0;\n var clipperElement = canEscapeClipping && isHTMLElement(element) ? getOffsetParent(element) : element;\n\n if (!isElement(clipperElement)) {\n return [];\n } // $FlowFixMe[incompatible-return]: https://github.com/facebook/flow/issues/1414\n\n\n return clippingParents.filter(function (clippingParent) {\n return isElement(clippingParent) && contains(clippingParent, clipperElement) && getNodeName(clippingParent) !== 'body';\n });\n} // Gets the maximum area that the element is visible in due to any number of\n// clipping parents\n\n\nexport default function getClippingRect(element, boundary, rootBoundary, strategy) {\n var mainClippingParents = boundary === 'clippingParents' ? getClippingParents(element) : [].concat(boundary);\n var clippingParents = [].concat(mainClippingParents, [rootBoundary]);\n var firstClippingParent = clippingParents[0];\n var clippingRect = clippingParents.reduce(function (accRect, clippingParent) {\n var rect = getClientRectFromMixedType(element, clippingParent, strategy);\n accRect.top = max(rect.top, accRect.top);\n accRect.right = min(rect.right, accRect.right);\n accRect.bottom = min(rect.bottom, accRect.bottom);\n accRect.left = max(rect.left, accRect.left);\n return accRect;\n }, getClientRectFromMixedType(element, firstClippingParent, strategy));\n clippingRect.width = clippingRect.right - clippingRect.left;\n clippingRect.height = clippingRect.bottom - clippingRect.top;\n clippingRect.x = clippingRect.left;\n clippingRect.y = clippingRect.top;\n return clippingRect;\n}","import getBasePlacement from \"./getBasePlacement.js\";\nimport getVariation from \"./getVariation.js\";\nimport getMainAxisFromPlacement from \"./getMainAxisFromPlacement.js\";\nimport { top, right, bottom, left, start, end } from \"../enums.js\";\nexport default function computeOffsets(_ref) {\n var reference = _ref.reference,\n element = _ref.element,\n placement = _ref.placement;\n var basePlacement = placement ? getBasePlacement(placement) : null;\n var variation = placement ? getVariation(placement) : null;\n var commonX = reference.x + reference.width / 2 - element.width / 2;\n var commonY = reference.y + reference.height / 2 - element.height / 2;\n var offsets;\n\n switch (basePlacement) {\n case top:\n offsets = {\n x: commonX,\n y: reference.y - element.height\n };\n break;\n\n case bottom:\n offsets = {\n x: commonX,\n y: reference.y + reference.height\n };\n break;\n\n case right:\n offsets = {\n x: reference.x + reference.width,\n y: commonY\n };\n break;\n\n case left:\n offsets = {\n x: reference.x - element.width,\n y: commonY\n };\n break;\n\n default:\n offsets = {\n x: reference.x,\n y: reference.y\n };\n }\n\n var mainAxis = basePlacement ? getMainAxisFromPlacement(basePlacement) : null;\n\n if (mainAxis != null) {\n var len = mainAxis === 'y' ? 'height' : 'width';\n\n switch (variation) {\n case start:\n offsets[mainAxis] = offsets[mainAxis] - (reference[len] / 2 - element[len] / 2);\n break;\n\n case end:\n offsets[mainAxis] = offsets[mainAxis] + (reference[len] / 2 - element[len] / 2);\n break;\n\n default:\n }\n }\n\n return offsets;\n}","import getClippingRect from \"../dom-utils/getClippingRect.js\";\nimport getDocumentElement from \"../dom-utils/getDocumentElement.js\";\nimport getBoundingClientRect from \"../dom-utils/getBoundingClientRect.js\";\nimport computeOffsets from \"./computeOffsets.js\";\nimport rectToClientRect from \"./rectToClientRect.js\";\nimport { clippingParents, reference, popper, bottom, top, right, basePlacements, viewport } from \"../enums.js\";\nimport { isElement } from \"../dom-utils/instanceOf.js\";\nimport mergePaddingObject from \"./mergePaddingObject.js\";\nimport expandToHashMap from \"./expandToHashMap.js\"; // eslint-disable-next-line import/no-unused-modules\n\nexport default function detectOverflow(state, options) {\n if (options === void 0) {\n options = {};\n }\n\n var _options = options,\n _options$placement = _options.placement,\n placement = _options$placement === void 0 ? state.placement : _options$placement,\n _options$strategy = _options.strategy,\n strategy = _options$strategy === void 0 ? state.strategy : _options$strategy,\n _options$boundary = _options.boundary,\n boundary = _options$boundary === void 0 ? clippingParents : _options$boundary,\n _options$rootBoundary = _options.rootBoundary,\n rootBoundary = _options$rootBoundary === void 0 ? viewport : _options$rootBoundary,\n _options$elementConte = _options.elementContext,\n elementContext = _options$elementConte === void 0 ? popper : _options$elementConte,\n _options$altBoundary = _options.altBoundary,\n altBoundary = _options$altBoundary === void 0 ? false : _options$altBoundary,\n _options$padding = _options.padding,\n padding = _options$padding === void 0 ? 0 : _options$padding;\n var paddingObject = mergePaddingObject(typeof padding !== 'number' ? padding : expandToHashMap(padding, basePlacements));\n var altContext = elementContext === popper ? reference : popper;\n var popperRect = state.rects.popper;\n var element = state.elements[altBoundary ? altContext : elementContext];\n var clippingClientRect = getClippingRect(isElement(element) ? element : element.contextElement || getDocumentElement(state.elements.popper), boundary, rootBoundary, strategy);\n var referenceClientRect = getBoundingClientRect(state.elements.reference);\n var popperOffsets = computeOffsets({\n reference: referenceClientRect,\n element: popperRect,\n strategy: 'absolute',\n placement: placement\n });\n var popperClientRect = rectToClientRect(Object.assign({}, popperRect, popperOffsets));\n var elementClientRect = elementContext === popper ? popperClientRect : referenceClientRect; // positive = overflowing the clipping rect\n // 0 or negative = within the clipping rect\n\n var overflowOffsets = {\n top: clippingClientRect.top - elementClientRect.top + paddingObject.top,\n bottom: elementClientRect.bottom - clippingClientRect.bottom + paddingObject.bottom,\n left: clippingClientRect.left - elementClientRect.left + paddingObject.left,\n right: elementClientRect.right - clippingClientRect.right + paddingObject.right\n };\n var offsetData = state.modifiersData.offset; // Offsets can be applied only to the popper element\n\n if (elementContext === popper && offsetData) {\n var offset = offsetData[placement];\n Object.keys(overflowOffsets).forEach(function (key) {\n var multiply = [right, bottom].indexOf(key) >= 0 ? 1 : -1;\n var axis = [top, bottom].indexOf(key) >= 0 ? 'y' : 'x';\n overflowOffsets[key] += offset[axis] * multiply;\n });\n }\n\n return overflowOffsets;\n}","import getVariation from \"./getVariation.js\";\nimport { variationPlacements, basePlacements, placements as allPlacements } from \"../enums.js\";\nimport detectOverflow from \"./detectOverflow.js\";\nimport getBasePlacement from \"./getBasePlacement.js\";\nexport default function computeAutoPlacement(state, options) {\n if (options === void 0) {\n options = {};\n }\n\n var _options = options,\n placement = _options.placement,\n boundary = _options.boundary,\n rootBoundary = _options.rootBoundary,\n padding = _options.padding,\n flipVariations = _options.flipVariations,\n _options$allowedAutoP = _options.allowedAutoPlacements,\n allowedAutoPlacements = _options$allowedAutoP === void 0 ? allPlacements : _options$allowedAutoP;\n var variation = getVariation(placement);\n var placements = variation ? flipVariations ? variationPlacements : variationPlacements.filter(function (placement) {\n return getVariation(placement) === variation;\n }) : basePlacements;\n var allowedPlacements = placements.filter(function (placement) {\n return allowedAutoPlacements.indexOf(placement) >= 0;\n });\n\n if (allowedPlacements.length === 0) {\n allowedPlacements = placements;\n } // $FlowFixMe[incompatible-type]: Flow seems to have problems with two array unions...\n\n\n var overflows = allowedPlacements.reduce(function (acc, placement) {\n acc[placement] = detectOverflow(state, {\n placement: placement,\n boundary: boundary,\n rootBoundary: rootBoundary,\n padding: padding\n })[getBasePlacement(placement)];\n return acc;\n }, {});\n return Object.keys(overflows).sort(function (a, b) {\n return overflows[a] - overflows[b];\n });\n}","import getOppositePlacement from \"../utils/getOppositePlacement.js\";\nimport getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getOppositeVariationPlacement from \"../utils/getOppositeVariationPlacement.js\";\nimport detectOverflow from \"../utils/detectOverflow.js\";\nimport computeAutoPlacement from \"../utils/computeAutoPlacement.js\";\nimport { bottom, top, start, right, left, auto } from \"../enums.js\";\nimport getVariation from \"../utils/getVariation.js\"; // eslint-disable-next-line import/no-unused-modules\n\nfunction getExpandedFallbackPlacements(placement) {\n if (getBasePlacement(placement) === auto) {\n return [];\n }\n\n var oppositePlacement = getOppositePlacement(placement);\n return [getOppositeVariationPlacement(placement), oppositePlacement, getOppositeVariationPlacement(oppositePlacement)];\n}\n\nfunction flip(_ref) {\n var state = _ref.state,\n options = _ref.options,\n name = _ref.name;\n\n if (state.modifiersData[name]._skip) {\n return;\n }\n\n var _options$mainAxis = options.mainAxis,\n checkMainAxis = _options$mainAxis === void 0 ? true : _options$mainAxis,\n _options$altAxis = options.altAxis,\n checkAltAxis = _options$altAxis === void 0 ? true : _options$altAxis,\n specifiedFallbackPlacements = options.fallbackPlacements,\n padding = options.padding,\n boundary = options.boundary,\n rootBoundary = options.rootBoundary,\n altBoundary = options.altBoundary,\n _options$flipVariatio = options.flipVariations,\n flipVariations = _options$flipVariatio === void 0 ? true : _options$flipVariatio,\n allowedAutoPlacements = options.allowedAutoPlacements;\n var preferredPlacement = state.options.placement;\n var basePlacement = getBasePlacement(preferredPlacement);\n var isBasePlacement = basePlacement === preferredPlacement;\n var fallbackPlacements = specifiedFallbackPlacements || (isBasePlacement || !flipVariations ? [getOppositePlacement(preferredPlacement)] : getExpandedFallbackPlacements(preferredPlacement));\n var placements = [preferredPlacement].concat(fallbackPlacements).reduce(function (acc, placement) {\n return acc.concat(getBasePlacement(placement) === auto ? computeAutoPlacement(state, {\n placement: placement,\n boundary: boundary,\n rootBoundary: rootBoundary,\n padding: padding,\n flipVariations: flipVariations,\n allowedAutoPlacements: allowedAutoPlacements\n }) : placement);\n }, []);\n var referenceRect = state.rects.reference;\n var popperRect = state.rects.popper;\n var checksMap = new Map();\n var makeFallbackChecks = true;\n var firstFittingPlacement = placements[0];\n\n for (var i = 0; i < placements.length; i++) {\n var placement = placements[i];\n\n var _basePlacement = getBasePlacement(placement);\n\n var isStartVariation = getVariation(placement) === start;\n var isVertical = [top, bottom].indexOf(_basePlacement) >= 0;\n var len = isVertical ? 'width' : 'height';\n var overflow = detectOverflow(state, {\n placement: placement,\n boundary: boundary,\n rootBoundary: rootBoundary,\n altBoundary: altBoundary,\n padding: padding\n });\n var mainVariationSide = isVertical ? isStartVariation ? right : left : isStartVariation ? bottom : top;\n\n if (referenceRect[len] > popperRect[len]) {\n mainVariationSide = getOppositePlacement(mainVariationSide);\n }\n\n var altVariationSide = getOppositePlacement(mainVariationSide);\n var checks = [];\n\n if (checkMainAxis) {\n checks.push(overflow[_basePlacement] <= 0);\n }\n\n if (checkAltAxis) {\n checks.push(overflow[mainVariationSide] <= 0, overflow[altVariationSide] <= 0);\n }\n\n if (checks.every(function (check) {\n return check;\n })) {\n firstFittingPlacement = placement;\n makeFallbackChecks = false;\n break;\n }\n\n checksMap.set(placement, checks);\n }\n\n if (makeFallbackChecks) {\n // `2` may be desired in some cases – research later\n var numberOfChecks = flipVariations ? 3 : 1;\n\n var _loop = function _loop(_i) {\n var fittingPlacement = placements.find(function (placement) {\n var checks = checksMap.get(placement);\n\n if (checks) {\n return checks.slice(0, _i).every(function (check) {\n return check;\n });\n }\n });\n\n if (fittingPlacement) {\n firstFittingPlacement = fittingPlacement;\n return \"break\";\n }\n };\n\n for (var _i = numberOfChecks; _i > 0; _i--) {\n var _ret = _loop(_i);\n\n if (_ret === \"break\") break;\n }\n }\n\n if (state.placement !== firstFittingPlacement) {\n state.modifiersData[name]._skip = true;\n state.placement = firstFittingPlacement;\n state.reset = true;\n }\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'flip',\n enabled: true,\n phase: 'main',\n fn: flip,\n requiresIfExists: ['offset'],\n data: {\n _skip: false\n }\n};","import { top, bottom, left, right } from \"../enums.js\";\nimport detectOverflow from \"../utils/detectOverflow.js\";\n\nfunction getSideOffsets(overflow, rect, preventedOffsets) {\n if (preventedOffsets === void 0) {\n preventedOffsets = {\n x: 0,\n y: 0\n };\n }\n\n return {\n top: overflow.top - rect.height - preventedOffsets.y,\n right: overflow.right - rect.width + preventedOffsets.x,\n bottom: overflow.bottom - rect.height + preventedOffsets.y,\n left: overflow.left - rect.width - preventedOffsets.x\n };\n}\n\nfunction isAnySideFullyClipped(overflow) {\n return [top, right, bottom, left].some(function (side) {\n return overflow[side] >= 0;\n });\n}\n\nfunction hide(_ref) {\n var state = _ref.state,\n name = _ref.name;\n var referenceRect = state.rects.reference;\n var popperRect = state.rects.popper;\n var preventedOffsets = state.modifiersData.preventOverflow;\n var referenceOverflow = detectOverflow(state, {\n elementContext: 'reference'\n });\n var popperAltOverflow = detectOverflow(state, {\n altBoundary: true\n });\n var referenceClippingOffsets = getSideOffsets(referenceOverflow, referenceRect);\n var popperEscapeOffsets = getSideOffsets(popperAltOverflow, popperRect, preventedOffsets);\n var isReferenceHidden = isAnySideFullyClipped(referenceClippingOffsets);\n var hasPopperEscaped = isAnySideFullyClipped(popperEscapeOffsets);\n state.modifiersData[name] = {\n referenceClippingOffsets: referenceClippingOffsets,\n popperEscapeOffsets: popperEscapeOffsets,\n isReferenceHidden: isReferenceHidden,\n hasPopperEscaped: hasPopperEscaped\n };\n state.attributes.popper = Object.assign({}, state.attributes.popper, {\n 'data-popper-reference-hidden': isReferenceHidden,\n 'data-popper-escaped': hasPopperEscaped\n });\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'hide',\n enabled: true,\n phase: 'main',\n requiresIfExists: ['preventOverflow'],\n fn: hide\n};","import getBasePlacement from \"../utils/getBasePlacement.js\";\nimport { top, left, right, placements } from \"../enums.js\"; // eslint-disable-next-line import/no-unused-modules\n\nexport function distanceAndSkiddingToXY(placement, rects, offset) {\n var basePlacement = getBasePlacement(placement);\n var invertDistance = [left, top].indexOf(basePlacement) >= 0 ? -1 : 1;\n\n var _ref = typeof offset === 'function' ? offset(Object.assign({}, rects, {\n placement: placement\n })) : offset,\n skidding = _ref[0],\n distance = _ref[1];\n\n skidding = skidding || 0;\n distance = (distance || 0) * invertDistance;\n return [left, right].indexOf(basePlacement) >= 0 ? {\n x: distance,\n y: skidding\n } : {\n x: skidding,\n y: distance\n };\n}\n\nfunction offset(_ref2) {\n var state = _ref2.state,\n options = _ref2.options,\n name = _ref2.name;\n var _options$offset = options.offset,\n offset = _options$offset === void 0 ? [0, 0] : _options$offset;\n var data = placements.reduce(function (acc, placement) {\n acc[placement] = distanceAndSkiddingToXY(placement, state.rects, offset);\n return acc;\n }, {});\n var _data$state$placement = data[state.placement],\n x = _data$state$placement.x,\n y = _data$state$placement.y;\n\n if (state.modifiersData.popperOffsets != null) {\n state.modifiersData.popperOffsets.x += x;\n state.modifiersData.popperOffsets.y += y;\n }\n\n state.modifiersData[name] = data;\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'offset',\n enabled: true,\n phase: 'main',\n requires: ['popperOffsets'],\n fn: offset\n};","import computeOffsets from \"../utils/computeOffsets.js\";\n\nfunction popperOffsets(_ref) {\n var state = _ref.state,\n name = _ref.name;\n // Offsets are the actual position the popper needs to have to be\n // properly positioned near its reference element\n // This is the most basic placement, and will be adjusted by\n // the modifiers in the next step\n state.modifiersData[name] = computeOffsets({\n reference: state.rects.reference,\n element: state.rects.popper,\n strategy: 'absolute',\n placement: state.placement\n });\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'popperOffsets',\n enabled: true,\n phase: 'read',\n fn: popperOffsets,\n data: {}\n};","export default function getAltAxis(axis) {\n return axis === 'x' ? 'y' : 'x';\n}","import { top, left, right, bottom, start } from \"../enums.js\";\nimport getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getMainAxisFromPlacement from \"../utils/getMainAxisFromPlacement.js\";\nimport getAltAxis from \"../utils/getAltAxis.js\";\nimport { within, withinMaxClamp } from \"../utils/within.js\";\nimport getLayoutRect from \"../dom-utils/getLayoutRect.js\";\nimport getOffsetParent from \"../dom-utils/getOffsetParent.js\";\nimport detectOverflow from \"../utils/detectOverflow.js\";\nimport getVariation from \"../utils/getVariation.js\";\nimport getFreshSideObject from \"../utils/getFreshSideObject.js\";\nimport { min as mathMin, max as mathMax } from \"../utils/math.js\";\n\nfunction preventOverflow(_ref) {\n var state = _ref.state,\n options = _ref.options,\n name = _ref.name;\n var _options$mainAxis = options.mainAxis,\n checkMainAxis = _options$mainAxis === void 0 ? true : _options$mainAxis,\n _options$altAxis = options.altAxis,\n checkAltAxis = _options$altAxis === void 0 ? false : _options$altAxis,\n boundary = options.boundary,\n rootBoundary = options.rootBoundary,\n altBoundary = options.altBoundary,\n padding = options.padding,\n _options$tether = options.tether,\n tether = _options$tether === void 0 ? true : _options$tether,\n _options$tetherOffset = options.tetherOffset,\n tetherOffset = _options$tetherOffset === void 0 ? 0 : _options$tetherOffset;\n var overflow = detectOverflow(state, {\n boundary: boundary,\n rootBoundary: rootBoundary,\n padding: padding,\n altBoundary: altBoundary\n });\n var basePlacement = getBasePlacement(state.placement);\n var variation = getVariation(state.placement);\n var isBasePlacement = !variation;\n var mainAxis = getMainAxisFromPlacement(basePlacement);\n var altAxis = getAltAxis(mainAxis);\n var popperOffsets = state.modifiersData.popperOffsets;\n var referenceRect = state.rects.reference;\n var popperRect = state.rects.popper;\n var tetherOffsetValue = typeof tetherOffset === 'function' ? tetherOffset(Object.assign({}, state.rects, {\n placement: state.placement\n })) : tetherOffset;\n var normalizedTetherOffsetValue = typeof tetherOffsetValue === 'number' ? {\n mainAxis: tetherOffsetValue,\n altAxis: tetherOffsetValue\n } : Object.assign({\n mainAxis: 0,\n altAxis: 0\n }, tetherOffsetValue);\n var offsetModifierState = state.modifiersData.offset ? state.modifiersData.offset[state.placement] : null;\n var data = {\n x: 0,\n y: 0\n };\n\n if (!popperOffsets) {\n return;\n }\n\n if (checkMainAxis) {\n var _offsetModifierState$;\n\n var mainSide = mainAxis === 'y' ? top : left;\n var altSide = mainAxis === 'y' ? bottom : right;\n var len = mainAxis === 'y' ? 'height' : 'width';\n var offset = popperOffsets[mainAxis];\n var min = offset + overflow[mainSide];\n var max = offset - overflow[altSide];\n var additive = tether ? -popperRect[len] / 2 : 0;\n var minLen = variation === start ? referenceRect[len] : popperRect[len];\n var maxLen = variation === start ? -popperRect[len] : -referenceRect[len]; // We need to include the arrow in the calculation so the arrow doesn't go\n // outside the reference bounds\n\n var arrowElement = state.elements.arrow;\n var arrowRect = tether && arrowElement ? getLayoutRect(arrowElement) : {\n width: 0,\n height: 0\n };\n var arrowPaddingObject = state.modifiersData['arrow#persistent'] ? state.modifiersData['arrow#persistent'].padding : getFreshSideObject();\n var arrowPaddingMin = arrowPaddingObject[mainSide];\n var arrowPaddingMax = arrowPaddingObject[altSide]; // If the reference length is smaller than the arrow length, we don't want\n // to include its full size in the calculation. If the reference is small\n // and near the edge of a boundary, the popper can overflow even if the\n // reference is not overflowing as well (e.g. virtual elements with no\n // width or height)\n\n var arrowLen = within(0, referenceRect[len], arrowRect[len]);\n var minOffset = isBasePlacement ? referenceRect[len] / 2 - additive - arrowLen - arrowPaddingMin - normalizedTetherOffsetValue.mainAxis : minLen - arrowLen - arrowPaddingMin - normalizedTetherOffsetValue.mainAxis;\n var maxOffset = isBasePlacement ? -referenceRect[len] / 2 + additive + arrowLen + arrowPaddingMax + normalizedTetherOffsetValue.mainAxis : maxLen + arrowLen + arrowPaddingMax + normalizedTetherOffsetValue.mainAxis;\n var arrowOffsetParent = state.elements.arrow && getOffsetParent(state.elements.arrow);\n var clientOffset = arrowOffsetParent ? mainAxis === 'y' ? arrowOffsetParent.clientTop || 0 : arrowOffsetParent.clientLeft || 0 : 0;\n var offsetModifierValue = (_offsetModifierState$ = offsetModifierState == null ? void 0 : offsetModifierState[mainAxis]) != null ? _offsetModifierState$ : 0;\n var tetherMin = offset + minOffset - offsetModifierValue - clientOffset;\n var tetherMax = offset + maxOffset - offsetModifierValue;\n var preventedOffset = within(tether ? mathMin(min, tetherMin) : min, offset, tether ? mathMax(max, tetherMax) : max);\n popperOffsets[mainAxis] = preventedOffset;\n data[mainAxis] = preventedOffset - offset;\n }\n\n if (checkAltAxis) {\n var _offsetModifierState$2;\n\n var _mainSide = mainAxis === 'x' ? top : left;\n\n var _altSide = mainAxis === 'x' ? bottom : right;\n\n var _offset = popperOffsets[altAxis];\n\n var _len = altAxis === 'y' ? 'height' : 'width';\n\n var _min = _offset + overflow[_mainSide];\n\n var _max = _offset - overflow[_altSide];\n\n var isOriginSide = [top, left].indexOf(basePlacement) !== -1;\n\n var _offsetModifierValue = (_offsetModifierState$2 = offsetModifierState == null ? void 0 : offsetModifierState[altAxis]) != null ? _offsetModifierState$2 : 0;\n\n var _tetherMin = isOriginSide ? _min : _offset - referenceRect[_len] - popperRect[_len] - _offsetModifierValue + normalizedTetherOffsetValue.altAxis;\n\n var _tetherMax = isOriginSide ? _offset + referenceRect[_len] + popperRect[_len] - _offsetModifierValue - normalizedTetherOffsetValue.altAxis : _max;\n\n var _preventedOffset = tether && isOriginSide ? withinMaxClamp(_tetherMin, _offset, _tetherMax) : within(tether ? _tetherMin : _min, _offset, tether ? _tetherMax : _max);\n\n popperOffsets[altAxis] = _preventedOffset;\n data[altAxis] = _preventedOffset - _offset;\n }\n\n state.modifiersData[name] = data;\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'preventOverflow',\n enabled: true,\n phase: 'main',\n fn: preventOverflow,\n requiresIfExists: ['offset']\n};","export default function getHTMLElementScroll(element) {\n return {\n scrollLeft: element.scrollLeft,\n scrollTop: element.scrollTop\n };\n}","import getWindowScroll from \"./getWindowScroll.js\";\nimport getWindow from \"./getWindow.js\";\nimport { isHTMLElement } from \"./instanceOf.js\";\nimport getHTMLElementScroll from \"./getHTMLElementScroll.js\";\nexport default function getNodeScroll(node) {\n if (node === getWindow(node) || !isHTMLElement(node)) {\n return getWindowScroll(node);\n } else {\n return getHTMLElementScroll(node);\n }\n}","import getBoundingClientRect from \"./getBoundingClientRect.js\";\nimport getNodeScroll from \"./getNodeScroll.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport { isHTMLElement } from \"./instanceOf.js\";\nimport getWindowScrollBarX from \"./getWindowScrollBarX.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport isScrollParent from \"./isScrollParent.js\";\nimport { round } from \"../utils/math.js\";\n\nfunction isElementScaled(element) {\n var rect = element.getBoundingClientRect();\n var scaleX = round(rect.width) / element.offsetWidth || 1;\n var scaleY = round(rect.height) / element.offsetHeight || 1;\n return scaleX !== 1 || scaleY !== 1;\n} // Returns the composite rect of an element relative to its offsetParent.\n// Composite means it takes into account transforms as well as layout.\n\n\nexport default function getCompositeRect(elementOrVirtualElement, offsetParent, isFixed) {\n if (isFixed === void 0) {\n isFixed = false;\n }\n\n var isOffsetParentAnElement = isHTMLElement(offsetParent);\n var offsetParentIsScaled = isHTMLElement(offsetParent) && isElementScaled(offsetParent);\n var documentElement = getDocumentElement(offsetParent);\n var rect = getBoundingClientRect(elementOrVirtualElement, offsetParentIsScaled, isFixed);\n var scroll = {\n scrollLeft: 0,\n scrollTop: 0\n };\n var offsets = {\n x: 0,\n y: 0\n };\n\n if (isOffsetParentAnElement || !isOffsetParentAnElement && !isFixed) {\n if (getNodeName(offsetParent) !== 'body' || // https://github.com/popperjs/popper-core/issues/1078\n isScrollParent(documentElement)) {\n scroll = getNodeScroll(offsetParent);\n }\n\n if (isHTMLElement(offsetParent)) {\n offsets = getBoundingClientRect(offsetParent, true);\n offsets.x += offsetParent.clientLeft;\n offsets.y += offsetParent.clientTop;\n } else if (documentElement) {\n offsets.x = getWindowScrollBarX(documentElement);\n }\n }\n\n return {\n x: rect.left + scroll.scrollLeft - offsets.x,\n y: rect.top + scroll.scrollTop - offsets.y,\n width: rect.width,\n height: rect.height\n };\n}","import { modifierPhases } from \"../enums.js\"; // source: https://stackoverflow.com/questions/49875255\n\nfunction order(modifiers) {\n var map = new Map();\n var visited = new Set();\n var result = [];\n modifiers.forEach(function (modifier) {\n map.set(modifier.name, modifier);\n }); // On visiting object, check for its dependencies and visit them recursively\n\n function sort(modifier) {\n visited.add(modifier.name);\n var requires = [].concat(modifier.requires || [], modifier.requiresIfExists || []);\n requires.forEach(function (dep) {\n if (!visited.has(dep)) {\n var depModifier = map.get(dep);\n\n if (depModifier) {\n sort(depModifier);\n }\n }\n });\n result.push(modifier);\n }\n\n modifiers.forEach(function (modifier) {\n if (!visited.has(modifier.name)) {\n // check for visited object\n sort(modifier);\n }\n });\n return result;\n}\n\nexport default function orderModifiers(modifiers) {\n // order based on dependencies\n var orderedModifiers = order(modifiers); // order based on phase\n\n return modifierPhases.reduce(function (acc, phase) {\n return acc.concat(orderedModifiers.filter(function (modifier) {\n return modifier.phase === phase;\n }));\n }, []);\n}","export default function debounce(fn) {\n var pending;\n return function () {\n if (!pending) {\n pending = new Promise(function (resolve) {\n Promise.resolve().then(function () {\n pending = undefined;\n resolve(fn());\n });\n });\n }\n\n return pending;\n };\n}","export default function mergeByName(modifiers) {\n var merged = modifiers.reduce(function (merged, current) {\n var existing = merged[current.name];\n merged[current.name] = existing ? Object.assign({}, existing, current, {\n options: Object.assign({}, existing.options, current.options),\n data: Object.assign({}, existing.data, current.data)\n }) : current;\n return merged;\n }, {}); // IE11 does not support Object.values\n\n return Object.keys(merged).map(function (key) {\n return merged[key];\n });\n}","import getCompositeRect from \"./dom-utils/getCompositeRect.js\";\nimport getLayoutRect from \"./dom-utils/getLayoutRect.js\";\nimport listScrollParents from \"./dom-utils/listScrollParents.js\";\nimport getOffsetParent from \"./dom-utils/getOffsetParent.js\";\nimport orderModifiers from \"./utils/orderModifiers.js\";\nimport debounce from \"./utils/debounce.js\";\nimport mergeByName from \"./utils/mergeByName.js\";\nimport detectOverflow from \"./utils/detectOverflow.js\";\nimport { isElement } from \"./dom-utils/instanceOf.js\";\nvar DEFAULT_OPTIONS = {\n placement: 'bottom',\n modifiers: [],\n strategy: 'absolute'\n};\n\nfunction areValidElements() {\n for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {\n args[_key] = arguments[_key];\n }\n\n return !args.some(function (element) {\n return !(element && typeof element.getBoundingClientRect === 'function');\n });\n}\n\nexport function popperGenerator(generatorOptions) {\n if (generatorOptions === void 0) {\n generatorOptions = {};\n }\n\n var _generatorOptions = generatorOptions,\n _generatorOptions$def = _generatorOptions.defaultModifiers,\n defaultModifiers = _generatorOptions$def === void 0 ? [] : _generatorOptions$def,\n _generatorOptions$def2 = _generatorOptions.defaultOptions,\n defaultOptions = _generatorOptions$def2 === void 0 ? DEFAULT_OPTIONS : _generatorOptions$def2;\n return function createPopper(reference, popper, options) {\n if (options === void 0) {\n options = defaultOptions;\n }\n\n var state = {\n placement: 'bottom',\n orderedModifiers: [],\n options: Object.assign({}, DEFAULT_OPTIONS, defaultOptions),\n modifiersData: {},\n elements: {\n reference: reference,\n popper: popper\n },\n attributes: {},\n styles: {}\n };\n var effectCleanupFns = [];\n var isDestroyed = false;\n var instance = {\n state: state,\n setOptions: function setOptions(setOptionsAction) {\n var options = typeof setOptionsAction === 'function' ? setOptionsAction(state.options) : setOptionsAction;\n cleanupModifierEffects();\n state.options = Object.assign({}, defaultOptions, state.options, options);\n state.scrollParents = {\n reference: isElement(reference) ? listScrollParents(reference) : reference.contextElement ? listScrollParents(reference.contextElement) : [],\n popper: listScrollParents(popper)\n }; // Orders the modifiers based on their dependencies and `phase`\n // properties\n\n var orderedModifiers = orderModifiers(mergeByName([].concat(defaultModifiers, state.options.modifiers))); // Strip out disabled modifiers\n\n state.orderedModifiers = orderedModifiers.filter(function (m) {\n return m.enabled;\n });\n runModifierEffects();\n return instance.update();\n },\n // Sync update – it will always be executed, even if not necessary. This\n // is useful for low frequency updates where sync behavior simplifies the\n // logic.\n // For high frequency updates (e.g. `resize` and `scroll` events), always\n // prefer the async Popper#update method\n forceUpdate: function forceUpdate() {\n if (isDestroyed) {\n return;\n }\n\n var _state$elements = state.elements,\n reference = _state$elements.reference,\n popper = _state$elements.popper; // Don't proceed if `reference` or `popper` are not valid elements\n // anymore\n\n if (!areValidElements(reference, popper)) {\n return;\n } // Store the reference and popper rects to be read by modifiers\n\n\n state.rects = {\n reference: getCompositeRect(reference, getOffsetParent(popper), state.options.strategy === 'fixed'),\n popper: getLayoutRect(popper)\n }; // Modifiers have the ability to reset the current update cycle. The\n // most common use case for this is the `flip` modifier changing the\n // placement, which then needs to re-run all the modifiers, because the\n // logic was previously ran for the previous placement and is therefore\n // stale/incorrect\n\n state.reset = false;\n state.placement = state.options.placement; // On each update cycle, the `modifiersData` property for each modifier\n // is filled with the initial data specified by the modifier. This means\n // it doesn't persist and is fresh on each update.\n // To ensure persistent data, use `${name}#persistent`\n\n state.orderedModifiers.forEach(function (modifier) {\n return state.modifiersData[modifier.name] = Object.assign({}, modifier.data);\n });\n\n for (var index = 0; index < state.orderedModifiers.length; index++) {\n if (state.reset === true) {\n state.reset = false;\n index = -1;\n continue;\n }\n\n var _state$orderedModifie = state.orderedModifiers[index],\n fn = _state$orderedModifie.fn,\n _state$orderedModifie2 = _state$orderedModifie.options,\n _options = _state$orderedModifie2 === void 0 ? {} : _state$orderedModifie2,\n name = _state$orderedModifie.name;\n\n if (typeof fn === 'function') {\n state = fn({\n state: state,\n options: _options,\n name: name,\n instance: instance\n }) || state;\n }\n }\n },\n // Async and optimistically optimized update – it will not be executed if\n // not necessary (debounced to run at most once-per-tick)\n update: debounce(function () {\n return new Promise(function (resolve) {\n instance.forceUpdate();\n resolve(state);\n });\n }),\n destroy: function destroy() {\n cleanupModifierEffects();\n isDestroyed = true;\n }\n };\n\n if (!areValidElements(reference, popper)) {\n return instance;\n }\n\n instance.setOptions(options).then(function (state) {\n if (!isDestroyed && options.onFirstUpdate) {\n options.onFirstUpdate(state);\n }\n }); // Modifiers have the ability to execute arbitrary code before the first\n // update cycle runs. They will be executed in the same order as the update\n // cycle. This is useful when a modifier adds some persistent data that\n // other modifiers need to use, but the modifier is run after the dependent\n // one.\n\n function runModifierEffects() {\n state.orderedModifiers.forEach(function (_ref) {\n var name = _ref.name,\n _ref$options = _ref.options,\n options = _ref$options === void 0 ? {} : _ref$options,\n effect = _ref.effect;\n\n if (typeof effect === 'function') {\n var cleanupFn = effect({\n state: state,\n name: name,\n instance: instance,\n options: options\n });\n\n var noopFn = function noopFn() {};\n\n effectCleanupFns.push(cleanupFn || noopFn);\n }\n });\n }\n\n function cleanupModifierEffects() {\n effectCleanupFns.forEach(function (fn) {\n return fn();\n });\n effectCleanupFns = [];\n }\n\n return instance;\n };\n}\nexport var createPopper = /*#__PURE__*/popperGenerator(); // eslint-disable-next-line import/no-unused-modules\n\nexport { detectOverflow };","import { popperGenerator, detectOverflow } from \"./createPopper.js\";\nimport eventListeners from \"./modifiers/eventListeners.js\";\nimport popperOffsets from \"./modifiers/popperOffsets.js\";\nimport computeStyles from \"./modifiers/computeStyles.js\";\nimport applyStyles from \"./modifiers/applyStyles.js\";\nimport offset from \"./modifiers/offset.js\";\nimport flip from \"./modifiers/flip.js\";\nimport preventOverflow from \"./modifiers/preventOverflow.js\";\nimport arrow from \"./modifiers/arrow.js\";\nimport hide from \"./modifiers/hide.js\";\nvar defaultModifiers = [eventListeners, popperOffsets, computeStyles, applyStyles, offset, flip, preventOverflow, arrow, hide];\nvar createPopper = /*#__PURE__*/popperGenerator({\n defaultModifiers: defaultModifiers\n}); // eslint-disable-next-line import/no-unused-modules\n\nexport { createPopper, popperGenerator, defaultModifiers, detectOverflow }; // eslint-disable-next-line import/no-unused-modules\n\nexport { createPopper as createPopperLite } from \"./popper-lite.js\"; // eslint-disable-next-line import/no-unused-modules\n\nexport * from \"./modifiers/index.js\";","import { generateUtilityClass } from '../generateUtilityClass';\nimport { generateUtilityClasses } from '../generateUtilityClasses';\nconst COMPONENT_NAME = 'Popper';\nexport function getPopperUtilityClass(slot) {\n return generateUtilityClass(COMPONENT_NAME, slot);\n}\nexport const popperClasses = generateUtilityClasses(COMPONENT_NAME, ['root']);","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"anchorEl\", \"children\", \"direction\", \"disablePortal\", \"modifiers\", \"open\", \"placement\", \"popperOptions\", \"popperRef\", \"slotProps\", \"slots\", \"TransitionProps\", \"ownerState\"],\n _excluded2 = [\"anchorEl\", \"children\", \"container\", \"direction\", \"disablePortal\", \"keepMounted\", \"modifiers\", \"open\", \"placement\", \"popperOptions\", \"popperRef\", \"style\", \"transition\", \"slotProps\", \"slots\"];\nimport * as React from 'react';\nimport { chainPropTypes, HTMLElementType, refType, unstable_ownerDocument as ownerDocument, unstable_useEnhancedEffect as useEnhancedEffect, unstable_useForkRef as useForkRef } from '@mui/utils';\nimport { createPopper } from '@popperjs/core';\nimport PropTypes from 'prop-types';\nimport { unstable_composeClasses as composeClasses } from '../composeClasses';\nimport { Portal } from '../Portal';\nimport { getPopperUtilityClass } from './popperClasses';\nimport { useSlotProps } from '../utils';\nimport { useClassNamesOverride } from '../utils/ClassNameConfigurator';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nfunction flipPlacement(placement, direction) {\n if (direction === 'ltr') {\n return placement;\n }\n switch (placement) {\n case 'bottom-end':\n return 'bottom-start';\n case 'bottom-start':\n return 'bottom-end';\n case 'top-end':\n return 'top-start';\n case 'top-start':\n return 'top-end';\n default:\n return placement;\n }\n}\nfunction resolveAnchorEl(anchorEl) {\n return typeof anchorEl === 'function' ? anchorEl() : anchorEl;\n}\nfunction isHTMLElement(element) {\n return element.nodeType !== undefined;\n}\nfunction isVirtualElement(element) {\n return !isHTMLElement(element);\n}\nconst useUtilityClasses = () => {\n const slots = {\n root: ['root']\n };\n return composeClasses(slots, useClassNamesOverride(getPopperUtilityClass));\n};\nconst defaultPopperOptions = {};\nconst PopperTooltip = /*#__PURE__*/React.forwardRef(function PopperTooltip(props, forwardedRef) {\n var _slots$root;\n const {\n anchorEl,\n children,\n direction,\n disablePortal,\n modifiers,\n open,\n placement: initialPlacement,\n popperOptions,\n popperRef: popperRefProp,\n slotProps = {},\n slots = {},\n TransitionProps\n // @ts-ignore internal logic\n // prevent from spreading to DOM, it can come from the parent component e.g. Select.\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const tooltipRef = React.useRef(null);\n const ownRef = useForkRef(tooltipRef, forwardedRef);\n const popperRef = React.useRef(null);\n const handlePopperRef = useForkRef(popperRef, popperRefProp);\n const handlePopperRefRef = React.useRef(handlePopperRef);\n useEnhancedEffect(() => {\n handlePopperRefRef.current = handlePopperRef;\n }, [handlePopperRef]);\n React.useImperativeHandle(popperRefProp, () => popperRef.current, []);\n const rtlPlacement = flipPlacement(initialPlacement, direction);\n /**\n * placement initialized from prop but can change during lifetime if modifiers.flip.\n * modifiers.flip is essentially a flip for controlled/uncontrolled behavior\n */\n const [placement, setPlacement] = React.useState(rtlPlacement);\n const [resolvedAnchorElement, setResolvedAnchorElement] = React.useState(resolveAnchorEl(anchorEl));\n React.useEffect(() => {\n if (popperRef.current) {\n popperRef.current.forceUpdate();\n }\n });\n React.useEffect(() => {\n if (anchorEl) {\n setResolvedAnchorElement(resolveAnchorEl(anchorEl));\n }\n }, [anchorEl]);\n useEnhancedEffect(() => {\n if (!resolvedAnchorElement || !open) {\n return undefined;\n }\n const handlePopperUpdate = data => {\n setPlacement(data.placement);\n };\n if (process.env.NODE_ENV !== 'production') {\n if (resolvedAnchorElement && isHTMLElement(resolvedAnchorElement) && resolvedAnchorElement.nodeType === 1) {\n const box = resolvedAnchorElement.getBoundingClientRect();\n if (process.env.NODE_ENV !== 'test' && box.top === 0 && box.left === 0 && box.right === 0 && box.bottom === 0) {\n console.warn(['MUI: The `anchorEl` prop provided to the component is invalid.', 'The anchor element should be part of the document layout.', \"Make sure the element is present in the document or that it's not display none.\"].join('\\n'));\n }\n }\n }\n let popperModifiers = [{\n name: 'preventOverflow',\n options: {\n altBoundary: disablePortal\n }\n }, {\n name: 'flip',\n options: {\n altBoundary: disablePortal\n }\n }, {\n name: 'onUpdate',\n enabled: true,\n phase: 'afterWrite',\n fn: ({\n state\n }) => {\n handlePopperUpdate(state);\n }\n }];\n if (modifiers != null) {\n popperModifiers = popperModifiers.concat(modifiers);\n }\n if (popperOptions && popperOptions.modifiers != null) {\n popperModifiers = popperModifiers.concat(popperOptions.modifiers);\n }\n const popper = createPopper(resolvedAnchorElement, tooltipRef.current, _extends({\n placement: rtlPlacement\n }, popperOptions, {\n modifiers: popperModifiers\n }));\n handlePopperRefRef.current(popper);\n return () => {\n popper.destroy();\n handlePopperRefRef.current(null);\n };\n }, [resolvedAnchorElement, disablePortal, modifiers, open, popperOptions, rtlPlacement]);\n const childProps = {\n placement: placement\n };\n if (TransitionProps !== null) {\n childProps.TransitionProps = TransitionProps;\n }\n const classes = useUtilityClasses();\n const Root = (_slots$root = slots.root) != null ? _slots$root : 'div';\n const rootProps = useSlotProps({\n elementType: Root,\n externalSlotProps: slotProps.root,\n externalForwardedProps: other,\n additionalProps: {\n role: 'tooltip',\n ref: ownRef\n },\n ownerState: props,\n className: classes.root\n });\n return /*#__PURE__*/_jsx(Root, _extends({}, rootProps, {\n children: typeof children === 'function' ? children(childProps) : children\n }));\n});\n\n/**\n * Poppers rely on the 3rd party library [Popper.js](https://popper.js.org/docs/v2/) for positioning.\n *\n * Demos:\n *\n * - [Popper](https://mui.com/base-ui/react-popper/)\n *\n * API:\n *\n * - [Popper API](https://mui.com/base-ui/react-popper/components-api/#popper)\n */\nconst Popper = /*#__PURE__*/React.forwardRef(function Popper(props, forwardedRef) {\n const {\n anchorEl,\n children,\n container: containerProp,\n direction = 'ltr',\n disablePortal = false,\n keepMounted = false,\n modifiers,\n open,\n placement = 'bottom',\n popperOptions = defaultPopperOptions,\n popperRef,\n style,\n transition = false,\n slotProps = {},\n slots = {}\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded2);\n const [exited, setExited] = React.useState(true);\n const handleEnter = () => {\n setExited(false);\n };\n const handleExited = () => {\n setExited(true);\n };\n if (!keepMounted && !open && (!transition || exited)) {\n return null;\n }\n\n // If the container prop is provided, use that\n // If the anchorEl prop is provided, use its parent body element as the container\n // If neither are provided let the Modal take care of choosing the container\n let container;\n if (containerProp) {\n container = containerProp;\n } else if (anchorEl) {\n const resolvedAnchorEl = resolveAnchorEl(anchorEl);\n container = resolvedAnchorEl && isHTMLElement(resolvedAnchorEl) ? ownerDocument(resolvedAnchorEl).body : ownerDocument(null).body;\n }\n const display = !open && keepMounted && (!transition || exited) ? 'none' : undefined;\n const transitionProps = transition ? {\n in: open,\n onEnter: handleEnter,\n onExited: handleExited\n } : undefined;\n return /*#__PURE__*/_jsx(Portal, {\n disablePortal: disablePortal,\n container: container,\n children: /*#__PURE__*/_jsx(PopperTooltip, _extends({\n anchorEl: anchorEl,\n direction: direction,\n disablePortal: disablePortal,\n modifiers: modifiers,\n ref: forwardedRef,\n open: transition ? !exited : open,\n placement: placement,\n popperOptions: popperOptions,\n popperRef: popperRef,\n slotProps: slotProps,\n slots: slots\n }, other, {\n style: _extends({\n // Prevents scroll issue, waiting for Popper.js to add this style once initiated.\n position: 'fixed',\n // Fix Popper.js display issue\n top: 0,\n left: 0,\n display\n }, style),\n TransitionProps: transitionProps,\n children: children\n }))\n });\n});\nprocess.env.NODE_ENV !== \"production\" ? Popper.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * An HTML element, [virtualElement](https://popper.js.org/docs/v2/virtual-elements/),\n * or a function that returns either.\n * It's used to set the position of the popper.\n * The return value will passed as the reference object of the Popper instance.\n */\n anchorEl: chainPropTypes(PropTypes.oneOfType([HTMLElementType, PropTypes.object, PropTypes.func]), props => {\n if (props.open) {\n const resolvedAnchorEl = resolveAnchorEl(props.anchorEl);\n if (resolvedAnchorEl && isHTMLElement(resolvedAnchorEl) && resolvedAnchorEl.nodeType === 1) {\n const box = resolvedAnchorEl.getBoundingClientRect();\n if (process.env.NODE_ENV !== 'test' && box.top === 0 && box.left === 0 && box.right === 0 && box.bottom === 0) {\n return new Error(['MUI: The `anchorEl` prop provided to the component is invalid.', 'The anchor element should be part of the document layout.', \"Make sure the element is present in the document or that it's not display none.\"].join('\\n'));\n }\n } else if (!resolvedAnchorEl || typeof resolvedAnchorEl.getBoundingClientRect !== 'function' || isVirtualElement(resolvedAnchorEl) && resolvedAnchorEl.contextElement != null && resolvedAnchorEl.contextElement.nodeType !== 1) {\n return new Error(['MUI: The `anchorEl` prop provided to the component is invalid.', 'It should be an HTML element instance or a virtualElement ', '(https://popper.js.org/docs/v2/virtual-elements/).'].join('\\n'));\n }\n }\n return null;\n }),\n /**\n * Popper render function or node.\n */\n children: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.node, PropTypes.func]),\n /**\n * An HTML element or function that returns one.\n * The `container` will have the portal children appended to it.\n *\n * You can also provide a callback, which is called in a React layout effect.\n * This lets you set the container from a ref, and also makes server-side rendering possible.\n *\n * By default, it uses the body of the top-level document object,\n * so it's simply `document.body` most of the time.\n */\n container: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.func]),\n /**\n * Direction of the text.\n * @default 'ltr'\n */\n direction: PropTypes.oneOf(['ltr', 'rtl']),\n /**\n * The `children` will be under the DOM hierarchy of the parent component.\n * @default false\n */\n disablePortal: PropTypes.bool,\n /**\n * Always keep the children in the DOM.\n * This prop can be useful in SEO situation or\n * when you want to maximize the responsiveness of the Popper.\n * @default false\n */\n keepMounted: PropTypes.bool,\n /**\n * Popper.js is based on a \"plugin-like\" architecture,\n * most of its features are fully encapsulated \"modifiers\".\n *\n * A modifier is a function that is called each time Popper.js needs to\n * compute the position of the popper.\n * For this reason, modifiers should be very performant to avoid bottlenecks.\n * To learn how to create a modifier, [read the modifiers documentation](https://popper.js.org/docs/v2/modifiers/).\n */\n modifiers: PropTypes.arrayOf(PropTypes.shape({\n data: PropTypes.object,\n effect: PropTypes.func,\n enabled: PropTypes.bool,\n fn: PropTypes.func,\n name: PropTypes.any,\n options: PropTypes.object,\n phase: PropTypes.oneOf(['afterMain', 'afterRead', 'afterWrite', 'beforeMain', 'beforeRead', 'beforeWrite', 'main', 'read', 'write']),\n requires: PropTypes.arrayOf(PropTypes.string),\n requiresIfExists: PropTypes.arrayOf(PropTypes.string)\n })),\n /**\n * If `true`, the component is shown.\n */\n open: PropTypes.bool.isRequired,\n /**\n * Popper placement.\n * @default 'bottom'\n */\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n /**\n * Options provided to the [`Popper.js`](https://popper.js.org/docs/v2/constructors/#options) instance.\n * @default {}\n */\n popperOptions: PropTypes.shape({\n modifiers: PropTypes.array,\n onFirstUpdate: PropTypes.func,\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n strategy: PropTypes.oneOf(['absolute', 'fixed'])\n }),\n /**\n * A ref that points to the used popper instance.\n */\n popperRef: refType,\n /**\n * The props used for each slot inside the Popper.\n * @default {}\n */\n slotProps: PropTypes.shape({\n root: PropTypes.oneOfType([PropTypes.func, PropTypes.object])\n }),\n /**\n * The components used for each slot inside the Popper.\n * Either a string to use a HTML element or a component.\n * @default {}\n */\n slots: PropTypes.shape({\n root: PropTypes.elementType\n }),\n /**\n * Help supporting a react-transition-group/Transition component.\n * @default false\n */\n transition: PropTypes.bool\n} : void 0;\nexport { Popper };","'use client';\n\nimport * as React from 'react';\nimport { useTheme as useThemeSystem } from '@mui/system';\nimport defaultTheme from './defaultTheme';\nimport THEME_ID from './identifier';\nexport default function useTheme() {\n const theme = useThemeSystem(defaultTheme);\n if (process.env.NODE_ENV !== 'production') {\n // eslint-disable-next-line react-hooks/rules-of-hooks\n React.useDebugValue(theme);\n }\n return theme[THEME_ID] || theme;\n}","export default function _setPrototypeOf(o, p) {\n _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function _setPrototypeOf(o, p) {\n o.__proto__ = p;\n return o;\n };\n return _setPrototypeOf(o, p);\n}","import setPrototypeOf from \"./setPrototypeOf.js\";\nexport default function _inheritsLoose(subClass, superClass) {\n subClass.prototype = Object.create(superClass.prototype);\n subClass.prototype.constructor = subClass;\n setPrototypeOf(subClass, superClass);\n}","export default {\n disabled: false\n};","import PropTypes from 'prop-types';\nexport var timeoutsShape = process.env.NODE_ENV !== 'production' ? PropTypes.oneOfType([PropTypes.number, PropTypes.shape({\n enter: PropTypes.number,\n exit: PropTypes.number,\n appear: PropTypes.number\n}).isRequired]) : null;\nexport var classNamesShape = process.env.NODE_ENV !== 'production' ? PropTypes.oneOfType([PropTypes.string, PropTypes.shape({\n enter: PropTypes.string,\n exit: PropTypes.string,\n active: PropTypes.string\n}), PropTypes.shape({\n enter: PropTypes.string,\n enterDone: PropTypes.string,\n enterActive: PropTypes.string,\n exit: PropTypes.string,\n exitDone: PropTypes.string,\n exitActive: PropTypes.string\n})]) : null;","import React from 'react';\nexport default React.createContext(null);","export var forceReflow = function forceReflow(node) {\n return node.scrollTop;\n};","import _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _inheritsLoose from \"@babel/runtime/helpers/esm/inheritsLoose\";\nimport PropTypes from 'prop-types';\nimport React from 'react';\nimport ReactDOM from 'react-dom';\nimport config from './config';\nimport { timeoutsShape } from './utils/PropTypes';\nimport TransitionGroupContext from './TransitionGroupContext';\nimport { forceReflow } from './utils/reflow';\nexport var UNMOUNTED = 'unmounted';\nexport var EXITED = 'exited';\nexport var ENTERING = 'entering';\nexport var ENTERED = 'entered';\nexport var EXITING = 'exiting';\n/**\n * The Transition component lets you describe a transition from one component\n * state to another _over time_ with a simple declarative API. Most commonly\n * it's used to animate the mounting and unmounting of a component, but can also\n * be used to describe in-place transition states as well.\n *\n * ---\n *\n * **Note**: `Transition` is a platform-agnostic base component. If you're using\n * transitions in CSS, you'll probably want to use\n * [`CSSTransition`](https://reactcommunity.org/react-transition-group/css-transition)\n * instead. It inherits all the features of `Transition`, but contains\n * additional features necessary to play nice with CSS transitions (hence the\n * name of the component).\n *\n * ---\n *\n * By default the `Transition` component does not alter the behavior of the\n * component it renders, it only tracks \"enter\" and \"exit\" states for the\n * components. It's up to you to give meaning and effect to those states. For\n * example we can add styles to a component when it enters or exits:\n *\n * ```jsx\n * import { Transition } from 'react-transition-group';\n *\n * const duration = 300;\n *\n * const defaultStyle = {\n * transition: `opacity ${duration}ms ease-in-out`,\n * opacity: 0,\n * }\n *\n * const transitionStyles = {\n * entering: { opacity: 1 },\n * entered: { opacity: 1 },\n * exiting: { opacity: 0 },\n * exited: { opacity: 0 },\n * };\n *\n * const Fade = ({ in: inProp }) => (\n * \n * {state => (\n *
    \n * I'm a fade Transition!\n *
    \n * )}\n *
    \n * );\n * ```\n *\n * There are 4 main states a Transition can be in:\n * - `'entering'`\n * - `'entered'`\n * - `'exiting'`\n * - `'exited'`\n *\n * Transition state is toggled via the `in` prop. When `true` the component\n * begins the \"Enter\" stage. During this stage, the component will shift from\n * its current transition state, to `'entering'` for the duration of the\n * transition and then to the `'entered'` stage once it's complete. Let's take\n * the following example (we'll use the\n * [useState](https://reactjs.org/docs/hooks-reference.html#usestate) hook):\n *\n * ```jsx\n * function App() {\n * const [inProp, setInProp] = useState(false);\n * return (\n *
    \n * \n * {state => (\n * // ...\n * )}\n * \n * \n *
    \n * );\n * }\n * ```\n *\n * When the button is clicked the component will shift to the `'entering'` state\n * and stay there for 500ms (the value of `timeout`) before it finally switches\n * to `'entered'`.\n *\n * When `in` is `false` the same thing happens except the state moves from\n * `'exiting'` to `'exited'`.\n */\n\nvar Transition = /*#__PURE__*/function (_React$Component) {\n _inheritsLoose(Transition, _React$Component);\n\n function Transition(props, context) {\n var _this;\n\n _this = _React$Component.call(this, props, context) || this;\n var parentGroup = context; // In the context of a TransitionGroup all enters are really appears\n\n var appear = parentGroup && !parentGroup.isMounting ? props.enter : props.appear;\n var initialStatus;\n _this.appearStatus = null;\n\n if (props.in) {\n if (appear) {\n initialStatus = EXITED;\n _this.appearStatus = ENTERING;\n } else {\n initialStatus = ENTERED;\n }\n } else {\n if (props.unmountOnExit || props.mountOnEnter) {\n initialStatus = UNMOUNTED;\n } else {\n initialStatus = EXITED;\n }\n }\n\n _this.state = {\n status: initialStatus\n };\n _this.nextCallback = null;\n return _this;\n }\n\n Transition.getDerivedStateFromProps = function getDerivedStateFromProps(_ref, prevState) {\n var nextIn = _ref.in;\n\n if (nextIn && prevState.status === UNMOUNTED) {\n return {\n status: EXITED\n };\n }\n\n return null;\n } // getSnapshotBeforeUpdate(prevProps) {\n // let nextStatus = null\n // if (prevProps !== this.props) {\n // const { status } = this.state\n // if (this.props.in) {\n // if (status !== ENTERING && status !== ENTERED) {\n // nextStatus = ENTERING\n // }\n // } else {\n // if (status === ENTERING || status === ENTERED) {\n // nextStatus = EXITING\n // }\n // }\n // }\n // return { nextStatus }\n // }\n ;\n\n var _proto = Transition.prototype;\n\n _proto.componentDidMount = function componentDidMount() {\n this.updateStatus(true, this.appearStatus);\n };\n\n _proto.componentDidUpdate = function componentDidUpdate(prevProps) {\n var nextStatus = null;\n\n if (prevProps !== this.props) {\n var status = this.state.status;\n\n if (this.props.in) {\n if (status !== ENTERING && status !== ENTERED) {\n nextStatus = ENTERING;\n }\n } else {\n if (status === ENTERING || status === ENTERED) {\n nextStatus = EXITING;\n }\n }\n }\n\n this.updateStatus(false, nextStatus);\n };\n\n _proto.componentWillUnmount = function componentWillUnmount() {\n this.cancelNextCallback();\n };\n\n _proto.getTimeouts = function getTimeouts() {\n var timeout = this.props.timeout;\n var exit, enter, appear;\n exit = enter = appear = timeout;\n\n if (timeout != null && typeof timeout !== 'number') {\n exit = timeout.exit;\n enter = timeout.enter; // TODO: remove fallback for next major\n\n appear = timeout.appear !== undefined ? timeout.appear : enter;\n }\n\n return {\n exit: exit,\n enter: enter,\n appear: appear\n };\n };\n\n _proto.updateStatus = function updateStatus(mounting, nextStatus) {\n if (mounting === void 0) {\n mounting = false;\n }\n\n if (nextStatus !== null) {\n // nextStatus will always be ENTERING or EXITING.\n this.cancelNextCallback();\n\n if (nextStatus === ENTERING) {\n if (this.props.unmountOnExit || this.props.mountOnEnter) {\n var node = this.props.nodeRef ? this.props.nodeRef.current : ReactDOM.findDOMNode(this); // https://github.com/reactjs/react-transition-group/pull/749\n // With unmountOnExit or mountOnEnter, the enter animation should happen at the transition between `exited` and `entering`.\n // To make the animation happen, we have to separate each rendering and avoid being processed as batched.\n\n if (node) forceReflow(node);\n }\n\n this.performEnter(mounting);\n } else {\n this.performExit();\n }\n } else if (this.props.unmountOnExit && this.state.status === EXITED) {\n this.setState({\n status: UNMOUNTED\n });\n }\n };\n\n _proto.performEnter = function performEnter(mounting) {\n var _this2 = this;\n\n var enter = this.props.enter;\n var appearing = this.context ? this.context.isMounting : mounting;\n\n var _ref2 = this.props.nodeRef ? [appearing] : [ReactDOM.findDOMNode(this), appearing],\n maybeNode = _ref2[0],\n maybeAppearing = _ref2[1];\n\n var timeouts = this.getTimeouts();\n var enterTimeout = appearing ? timeouts.appear : timeouts.enter; // no enter animation skip right to ENTERED\n // if we are mounting and running this it means appear _must_ be set\n\n if (!mounting && !enter || config.disabled) {\n this.safeSetState({\n status: ENTERED\n }, function () {\n _this2.props.onEntered(maybeNode);\n });\n return;\n }\n\n this.props.onEnter(maybeNode, maybeAppearing);\n this.safeSetState({\n status: ENTERING\n }, function () {\n _this2.props.onEntering(maybeNode, maybeAppearing);\n\n _this2.onTransitionEnd(enterTimeout, function () {\n _this2.safeSetState({\n status: ENTERED\n }, function () {\n _this2.props.onEntered(maybeNode, maybeAppearing);\n });\n });\n });\n };\n\n _proto.performExit = function performExit() {\n var _this3 = this;\n\n var exit = this.props.exit;\n var timeouts = this.getTimeouts();\n var maybeNode = this.props.nodeRef ? undefined : ReactDOM.findDOMNode(this); // no exit animation skip right to EXITED\n\n if (!exit || config.disabled) {\n this.safeSetState({\n status: EXITED\n }, function () {\n _this3.props.onExited(maybeNode);\n });\n return;\n }\n\n this.props.onExit(maybeNode);\n this.safeSetState({\n status: EXITING\n }, function () {\n _this3.props.onExiting(maybeNode);\n\n _this3.onTransitionEnd(timeouts.exit, function () {\n _this3.safeSetState({\n status: EXITED\n }, function () {\n _this3.props.onExited(maybeNode);\n });\n });\n });\n };\n\n _proto.cancelNextCallback = function cancelNextCallback() {\n if (this.nextCallback !== null) {\n this.nextCallback.cancel();\n this.nextCallback = null;\n }\n };\n\n _proto.safeSetState = function safeSetState(nextState, callback) {\n // This shouldn't be necessary, but there are weird race conditions with\n // setState callbacks and unmounting in testing, so always make sure that\n // we can cancel any pending setState callbacks after we unmount.\n callback = this.setNextCallback(callback);\n this.setState(nextState, callback);\n };\n\n _proto.setNextCallback = function setNextCallback(callback) {\n var _this4 = this;\n\n var active = true;\n\n this.nextCallback = function (event) {\n if (active) {\n active = false;\n _this4.nextCallback = null;\n callback(event);\n }\n };\n\n this.nextCallback.cancel = function () {\n active = false;\n };\n\n return this.nextCallback;\n };\n\n _proto.onTransitionEnd = function onTransitionEnd(timeout, handler) {\n this.setNextCallback(handler);\n var node = this.props.nodeRef ? this.props.nodeRef.current : ReactDOM.findDOMNode(this);\n var doesNotHaveTimeoutOrListener = timeout == null && !this.props.addEndListener;\n\n if (!node || doesNotHaveTimeoutOrListener) {\n setTimeout(this.nextCallback, 0);\n return;\n }\n\n if (this.props.addEndListener) {\n var _ref3 = this.props.nodeRef ? [this.nextCallback] : [node, this.nextCallback],\n maybeNode = _ref3[0],\n maybeNextCallback = _ref3[1];\n\n this.props.addEndListener(maybeNode, maybeNextCallback);\n }\n\n if (timeout != null) {\n setTimeout(this.nextCallback, timeout);\n }\n };\n\n _proto.render = function render() {\n var status = this.state.status;\n\n if (status === UNMOUNTED) {\n return null;\n }\n\n var _this$props = this.props,\n children = _this$props.children,\n _in = _this$props.in,\n _mountOnEnter = _this$props.mountOnEnter,\n _unmountOnExit = _this$props.unmountOnExit,\n _appear = _this$props.appear,\n _enter = _this$props.enter,\n _exit = _this$props.exit,\n _timeout = _this$props.timeout,\n _addEndListener = _this$props.addEndListener,\n _onEnter = _this$props.onEnter,\n _onEntering = _this$props.onEntering,\n _onEntered = _this$props.onEntered,\n _onExit = _this$props.onExit,\n _onExiting = _this$props.onExiting,\n _onExited = _this$props.onExited,\n _nodeRef = _this$props.nodeRef,\n childProps = _objectWithoutPropertiesLoose(_this$props, [\"children\", \"in\", \"mountOnEnter\", \"unmountOnExit\", \"appear\", \"enter\", \"exit\", \"timeout\", \"addEndListener\", \"onEnter\", \"onEntering\", \"onEntered\", \"onExit\", \"onExiting\", \"onExited\", \"nodeRef\"]);\n\n return (\n /*#__PURE__*/\n // allows for nested Transitions\n React.createElement(TransitionGroupContext.Provider, {\n value: null\n }, typeof children === 'function' ? children(status, childProps) : React.cloneElement(React.Children.only(children), childProps))\n );\n };\n\n return Transition;\n}(React.Component);\n\nTransition.contextType = TransitionGroupContext;\nTransition.propTypes = process.env.NODE_ENV !== \"production\" ? {\n /**\n * A React reference to DOM element that need to transition:\n * https://stackoverflow.com/a/51127130/4671932\n *\n * - When `nodeRef` prop is used, `node` is not passed to callback functions\n * (e.g. `onEnter`) because user already has direct access to the node.\n * - When changing `key` prop of `Transition` in a `TransitionGroup` a new\n * `nodeRef` need to be provided to `Transition` with changed `key` prop\n * (see\n * [test/CSSTransition-test.js](https://github.com/reactjs/react-transition-group/blob/13435f897b3ab71f6e19d724f145596f5910581c/test/CSSTransition-test.js#L362-L437)).\n */\n nodeRef: PropTypes.shape({\n current: typeof Element === 'undefined' ? PropTypes.any : function (propValue, key, componentName, location, propFullName, secret) {\n var value = propValue[key];\n return PropTypes.instanceOf(value && 'ownerDocument' in value ? value.ownerDocument.defaultView.Element : Element)(propValue, key, componentName, location, propFullName, secret);\n }\n }),\n\n /**\n * A `function` child can be used instead of a React element. This function is\n * called with the current transition status (`'entering'`, `'entered'`,\n * `'exiting'`, `'exited'`), which can be used to apply context\n * specific props to a component.\n *\n * ```jsx\n * \n * {state => (\n * \n * )}\n * \n * ```\n */\n children: PropTypes.oneOfType([PropTypes.func.isRequired, PropTypes.element.isRequired]).isRequired,\n\n /**\n * Show the component; triggers the enter or exit states\n */\n in: PropTypes.bool,\n\n /**\n * By default the child component is mounted immediately along with\n * the parent `Transition` component. If you want to \"lazy mount\" the component on the\n * first `in={true}` you can set `mountOnEnter`. After the first enter transition the component will stay\n * mounted, even on \"exited\", unless you also specify `unmountOnExit`.\n */\n mountOnEnter: PropTypes.bool,\n\n /**\n * By default the child component stays mounted after it reaches the `'exited'` state.\n * Set `unmountOnExit` if you'd prefer to unmount the component after it finishes exiting.\n */\n unmountOnExit: PropTypes.bool,\n\n /**\n * By default the child component does not perform the enter transition when\n * it first mounts, regardless of the value of `in`. If you want this\n * behavior, set both `appear` and `in` to `true`.\n *\n * > **Note**: there are no special appear states like `appearing`/`appeared`, this prop\n * > only adds an additional enter transition. However, in the\n * > `` component that first enter transition does result in\n * > additional `.appear-*` classes, that way you can choose to style it\n * > differently.\n */\n appear: PropTypes.bool,\n\n /**\n * Enable or disable enter transitions.\n */\n enter: PropTypes.bool,\n\n /**\n * Enable or disable exit transitions.\n */\n exit: PropTypes.bool,\n\n /**\n * The duration of the transition, in milliseconds.\n * Required unless `addEndListener` is provided.\n *\n * You may specify a single timeout for all transitions:\n *\n * ```jsx\n * timeout={500}\n * ```\n *\n * or individually:\n *\n * ```jsx\n * timeout={{\n * appear: 500,\n * enter: 300,\n * exit: 500,\n * }}\n * ```\n *\n * - `appear` defaults to the value of `enter`\n * - `enter` defaults to `0`\n * - `exit` defaults to `0`\n *\n * @type {number | { enter?: number, exit?: number, appear?: number }}\n */\n timeout: function timeout(props) {\n var pt = timeoutsShape;\n if (!props.addEndListener) pt = pt.isRequired;\n\n for (var _len = arguments.length, args = new Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) {\n args[_key - 1] = arguments[_key];\n }\n\n return pt.apply(void 0, [props].concat(args));\n },\n\n /**\n * Add a custom transition end trigger. Called with the transitioning\n * DOM node and a `done` callback. Allows for more fine grained transition end\n * logic. Timeouts are still used as a fallback if provided.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * ```jsx\n * addEndListener={(node, done) => {\n * // use the css transitionend event to mark the finish of a transition\n * node.addEventListener('transitionend', done, false);\n * }}\n * ```\n */\n addEndListener: PropTypes.func,\n\n /**\n * Callback fired before the \"entering\" status is applied. An extra parameter\n * `isAppearing` is supplied to indicate if the enter stage is occurring on the initial mount\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement, isAppearing: bool) -> void\n */\n onEnter: PropTypes.func,\n\n /**\n * Callback fired after the \"entering\" status is applied. An extra parameter\n * `isAppearing` is supplied to indicate if the enter stage is occurring on the initial mount\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement, isAppearing: bool)\n */\n onEntering: PropTypes.func,\n\n /**\n * Callback fired after the \"entered\" status is applied. An extra parameter\n * `isAppearing` is supplied to indicate if the enter stage is occurring on the initial mount\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement, isAppearing: bool) -> void\n */\n onEntered: PropTypes.func,\n\n /**\n * Callback fired before the \"exiting\" status is applied.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement) -> void\n */\n onExit: PropTypes.func,\n\n /**\n * Callback fired after the \"exiting\" status is applied.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement) -> void\n */\n onExiting: PropTypes.func,\n\n /**\n * Callback fired after the \"exited\" status is applied.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed\n *\n * @type Function(node: HtmlElement) -> void\n */\n onExited: PropTypes.func\n} : {}; // Name the function so it is clearer in the documentation\n\nfunction noop() {}\n\nTransition.defaultProps = {\n in: false,\n mountOnEnter: false,\n unmountOnExit: false,\n appear: false,\n enter: true,\n exit: true,\n onEnter: noop,\n onEntering: noop,\n onEntered: noop,\n onExit: noop,\n onExiting: noop,\n onExited: noop\n};\nTransition.UNMOUNTED = UNMOUNTED;\nTransition.EXITED = EXITED;\nTransition.ENTERING = ENTERING;\nTransition.ENTERED = ENTERED;\nTransition.EXITING = EXITING;\nexport default Transition;","export const reflow = node => node.scrollTop;\nexport function getTransitionProps(props, options) {\n var _style$transitionDura, _style$transitionTimi;\n const {\n timeout,\n easing,\n style = {}\n } = props;\n return {\n duration: (_style$transitionDura = style.transitionDuration) != null ? _style$transitionDura : typeof timeout === 'number' ? timeout : timeout[options.mode] || 0,\n easing: (_style$transitionTimi = style.transitionTimingFunction) != null ? _style$transitionTimi : typeof easing === 'object' ? easing[options.mode] : easing,\n delay: style.transitionDelay\n };\n}","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"addEndListener\", \"appear\", \"children\", \"easing\", \"in\", \"onEnter\", \"onEntered\", \"onEntering\", \"onExit\", \"onExited\", \"onExiting\", \"style\", \"timeout\", \"TransitionComponent\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport { elementAcceptingRef, unstable_useTimeout as useTimeout } from '@mui/utils';\nimport { Transition } from 'react-transition-group';\nimport useTheme from '../styles/useTheme';\nimport { getTransitionProps, reflow } from '../transitions/utils';\nimport useForkRef from '../utils/useForkRef';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nfunction getScale(value) {\n return `scale(${value}, ${value ** 2})`;\n}\nconst styles = {\n entering: {\n opacity: 1,\n transform: getScale(1)\n },\n entered: {\n opacity: 1,\n transform: 'none'\n }\n};\n\n/*\n TODO v6: remove\n Conditionally apply a workaround for the CSS transition bug in Safari 15.4 / WebKit browsers.\n */\nconst isWebKit154 = typeof navigator !== 'undefined' && /^((?!chrome|android).)*(safari|mobile)/i.test(navigator.userAgent) && /(os |version\\/)15(.|_)4/i.test(navigator.userAgent);\n\n/**\n * The Grow transition is used by the [Tooltip](/material-ui/react-tooltip/) and\n * [Popover](/material-ui/react-popover/) components.\n * It uses [react-transition-group](https://github.com/reactjs/react-transition-group) internally.\n */\nconst Grow = /*#__PURE__*/React.forwardRef(function Grow(props, ref) {\n const {\n addEndListener,\n appear = true,\n children,\n easing,\n in: inProp,\n onEnter,\n onEntered,\n onEntering,\n onExit,\n onExited,\n onExiting,\n style,\n timeout = 'auto',\n // eslint-disable-next-line react/prop-types\n TransitionComponent = Transition\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const timer = useTimeout();\n const autoTimeout = React.useRef();\n const theme = useTheme();\n const nodeRef = React.useRef(null);\n const handleRef = useForkRef(nodeRef, children.ref, ref);\n const normalizedTransitionCallback = callback => maybeIsAppearing => {\n if (callback) {\n const node = nodeRef.current;\n\n // onEnterXxx and onExitXxx callbacks have a different arguments.length value.\n if (maybeIsAppearing === undefined) {\n callback(node);\n } else {\n callback(node, maybeIsAppearing);\n }\n }\n };\n const handleEntering = normalizedTransitionCallback(onEntering);\n const handleEnter = normalizedTransitionCallback((node, isAppearing) => {\n reflow(node); // So the animation always start from the start.\n\n const {\n duration: transitionDuration,\n delay,\n easing: transitionTimingFunction\n } = getTransitionProps({\n style,\n timeout,\n easing\n }, {\n mode: 'enter'\n });\n let duration;\n if (timeout === 'auto') {\n duration = theme.transitions.getAutoHeightDuration(node.clientHeight);\n autoTimeout.current = duration;\n } else {\n duration = transitionDuration;\n }\n node.style.transition = [theme.transitions.create('opacity', {\n duration,\n delay\n }), theme.transitions.create('transform', {\n duration: isWebKit154 ? duration : duration * 0.666,\n delay,\n easing: transitionTimingFunction\n })].join(',');\n if (onEnter) {\n onEnter(node, isAppearing);\n }\n });\n const handleEntered = normalizedTransitionCallback(onEntered);\n const handleExiting = normalizedTransitionCallback(onExiting);\n const handleExit = normalizedTransitionCallback(node => {\n const {\n duration: transitionDuration,\n delay,\n easing: transitionTimingFunction\n } = getTransitionProps({\n style,\n timeout,\n easing\n }, {\n mode: 'exit'\n });\n let duration;\n if (timeout === 'auto') {\n duration = theme.transitions.getAutoHeightDuration(node.clientHeight);\n autoTimeout.current = duration;\n } else {\n duration = transitionDuration;\n }\n node.style.transition = [theme.transitions.create('opacity', {\n duration,\n delay\n }), theme.transitions.create('transform', {\n duration: isWebKit154 ? duration : duration * 0.666,\n delay: isWebKit154 ? delay : delay || duration * 0.333,\n easing: transitionTimingFunction\n })].join(',');\n node.style.opacity = 0;\n node.style.transform = getScale(0.75);\n if (onExit) {\n onExit(node);\n }\n });\n const handleExited = normalizedTransitionCallback(onExited);\n const handleAddEndListener = next => {\n if (timeout === 'auto') {\n timer.start(autoTimeout.current || 0, next);\n }\n if (addEndListener) {\n // Old call signature before `react-transition-group` implemented `nodeRef`\n addEndListener(nodeRef.current, next);\n }\n };\n return /*#__PURE__*/_jsx(TransitionComponent, _extends({\n appear: appear,\n in: inProp,\n nodeRef: nodeRef,\n onEnter: handleEnter,\n onEntered: handleEntered,\n onEntering: handleEntering,\n onExit: handleExit,\n onExited: handleExited,\n onExiting: handleExiting,\n addEndListener: handleAddEndListener,\n timeout: timeout === 'auto' ? null : timeout\n }, other, {\n children: (state, childProps) => {\n return /*#__PURE__*/React.cloneElement(children, _extends({\n style: _extends({\n opacity: 0,\n transform: getScale(0.75),\n visibility: state === 'exited' && !inProp ? 'hidden' : undefined\n }, styles[state], style, children.props.style),\n ref: handleRef\n }, childProps));\n }\n }));\n});\nprocess.env.NODE_ENV !== \"production\" ? Grow.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the d.ts file and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * Add a custom transition end trigger. Called with the transitioning DOM\n * node and a done callback. Allows for more fine grained transition end\n * logic. Note: Timeouts are still used as a fallback if provided.\n */\n addEndListener: PropTypes.func,\n /**\n * Perform the enter transition when it first mounts if `in` is also `true`.\n * Set this to `false` to disable this behavior.\n * @default true\n */\n appear: PropTypes.bool,\n /**\n * A single child content element.\n */\n children: elementAcceptingRef.isRequired,\n /**\n * The transition timing function.\n * You may specify a single easing or a object containing enter and exit values.\n */\n easing: PropTypes.oneOfType([PropTypes.shape({\n enter: PropTypes.string,\n exit: PropTypes.string\n }), PropTypes.string]),\n /**\n * If `true`, the component will transition in.\n */\n in: PropTypes.bool,\n /**\n * @ignore\n */\n onEnter: PropTypes.func,\n /**\n * @ignore\n */\n onEntered: PropTypes.func,\n /**\n * @ignore\n */\n onEntering: PropTypes.func,\n /**\n * @ignore\n */\n onExit: PropTypes.func,\n /**\n * @ignore\n */\n onExited: PropTypes.func,\n /**\n * @ignore\n */\n onExiting: PropTypes.func,\n /**\n * @ignore\n */\n style: PropTypes.object,\n /**\n * The duration for the transition, in milliseconds.\n * You may specify a single timeout for all transitions, or individually with an object.\n *\n * Set to 'auto' to automatically calculate transition time based on height.\n * @default 'auto'\n */\n timeout: PropTypes.oneOfType([PropTypes.oneOf(['auto']), PropTypes.number, PropTypes.shape({\n appear: PropTypes.number,\n enter: PropTypes.number,\n exit: PropTypes.number\n })])\n} : void 0;\nGrow.muiSupportAuto = true;\nexport default Grow;","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"anchorEl\", \"component\", \"components\", \"componentsProps\", \"container\", \"disablePortal\", \"keepMounted\", \"modifiers\", \"open\", \"placement\", \"popperOptions\", \"popperRef\", \"transition\", \"slots\", \"slotProps\"];\nimport { Popper as BasePopper } from '@mui/base/Popper';\nimport { useThemeWithoutDefault as useTheme } from '@mui/system';\nimport { HTMLElementType, refType } from '@mui/utils';\nimport PropTypes from 'prop-types';\nimport * as React from 'react';\nimport { styled, useThemeProps } from '../styles';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nconst PopperRoot = styled(BasePopper, {\n name: 'MuiPopper',\n slot: 'Root',\n overridesResolver: (props, styles) => styles.root\n})({});\n\n/**\n *\n * Demos:\n *\n * - [Autocomplete](https://mui.com/material-ui/react-autocomplete/)\n * - [Menu](https://mui.com/material-ui/react-menu/)\n * - [Popper](https://mui.com/material-ui/react-popper/)\n *\n * API:\n *\n * - [Popper API](https://mui.com/material-ui/api/popper/)\n */\nconst Popper = /*#__PURE__*/React.forwardRef(function Popper(inProps, ref) {\n var _slots$root;\n const theme = useTheme();\n const props = useThemeProps({\n props: inProps,\n name: 'MuiPopper'\n });\n const {\n anchorEl,\n component,\n components,\n componentsProps,\n container,\n disablePortal,\n keepMounted,\n modifiers,\n open,\n placement,\n popperOptions,\n popperRef,\n transition,\n slots,\n slotProps\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const RootComponent = (_slots$root = slots == null ? void 0 : slots.root) != null ? _slots$root : components == null ? void 0 : components.Root;\n const otherProps = _extends({\n anchorEl,\n container,\n disablePortal,\n keepMounted,\n modifiers,\n open,\n placement,\n popperOptions,\n popperRef,\n transition\n }, other);\n return /*#__PURE__*/_jsx(PopperRoot, _extends({\n as: component,\n direction: theme == null ? void 0 : theme.direction,\n slots: {\n root: RootComponent\n },\n slotProps: slotProps != null ? slotProps : componentsProps\n }, otherProps, {\n ref: ref\n }));\n});\nprocess.env.NODE_ENV !== \"production\" ? Popper.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * An HTML element, [virtualElement](https://popper.js.org/docs/v2/virtual-elements/),\n * or a function that returns either.\n * It's used to set the position of the popper.\n * The return value will passed as the reference object of the Popper instance.\n */\n anchorEl: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.object, PropTypes.func]),\n /**\n * Popper render function or node.\n */\n children: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.node, PropTypes.func]),\n /**\n * The component used for the root node.\n * Either a string to use a HTML element or a component.\n */\n component: PropTypes.elementType,\n /**\n * The components used for each slot inside the Popper.\n * Either a string to use a HTML element or a component.\n * @default {}\n */\n components: PropTypes.shape({\n Root: PropTypes.elementType\n }),\n /**\n * The props used for each slot inside the Popper.\n * @default {}\n */\n componentsProps: PropTypes.shape({\n root: PropTypes.oneOfType([PropTypes.func, PropTypes.object])\n }),\n /**\n * An HTML element or function that returns one.\n * The `container` will have the portal children appended to it.\n *\n * You can also provide a callback, which is called in a React layout effect.\n * This lets you set the container from a ref, and also makes server-side rendering possible.\n *\n * By default, it uses the body of the top-level document object,\n * so it's simply `document.body` most of the time.\n */\n container: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.func]),\n /**\n * The `children` will be under the DOM hierarchy of the parent component.\n * @default false\n */\n disablePortal: PropTypes.bool,\n /**\n * Always keep the children in the DOM.\n * This prop can be useful in SEO situation or\n * when you want to maximize the responsiveness of the Popper.\n * @default false\n */\n keepMounted: PropTypes.bool,\n /**\n * Popper.js is based on a \"plugin-like\" architecture,\n * most of its features are fully encapsulated \"modifiers\".\n *\n * A modifier is a function that is called each time Popper.js needs to\n * compute the position of the popper.\n * For this reason, modifiers should be very performant to avoid bottlenecks.\n * To learn how to create a modifier, [read the modifiers documentation](https://popper.js.org/docs/v2/modifiers/).\n */\n modifiers: PropTypes.arrayOf(PropTypes.shape({\n data: PropTypes.object,\n effect: PropTypes.func,\n enabled: PropTypes.bool,\n fn: PropTypes.func,\n name: PropTypes.any,\n options: PropTypes.object,\n phase: PropTypes.oneOf(['afterMain', 'afterRead', 'afterWrite', 'beforeMain', 'beforeRead', 'beforeWrite', 'main', 'read', 'write']),\n requires: PropTypes.arrayOf(PropTypes.string),\n requiresIfExists: PropTypes.arrayOf(PropTypes.string)\n })),\n /**\n * If `true`, the component is shown.\n */\n open: PropTypes.bool.isRequired,\n /**\n * Popper placement.\n * @default 'bottom'\n */\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n /**\n * Options provided to the [`Popper.js`](https://popper.js.org/docs/v2/constructors/#options) instance.\n * @default {}\n */\n popperOptions: PropTypes.shape({\n modifiers: PropTypes.array,\n onFirstUpdate: PropTypes.func,\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n strategy: PropTypes.oneOf(['absolute', 'fixed'])\n }),\n /**\n * A ref that points to the used popper instance.\n */\n popperRef: refType,\n /**\n * The props used for each slot inside the Popper.\n * @default {}\n */\n slotProps: PropTypes.shape({\n root: PropTypes.oneOfType([PropTypes.func, PropTypes.object])\n }),\n /**\n * The components used for each slot inside the Popper.\n * Either a string to use a HTML element or a component.\n * @default {}\n */\n slots: PropTypes.shape({\n root: PropTypes.elementType\n }),\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Help supporting a react-transition-group/Transition component.\n * @default false\n */\n transition: PropTypes.bool\n} : void 0;\nexport default Popper;","import generateUtilityClasses from '@mui/utils/generateUtilityClasses';\nimport generateUtilityClass from '@mui/utils/generateUtilityClass';\nexport function getTooltipUtilityClass(slot) {\n return generateUtilityClass('MuiTooltip', slot);\n}\nconst tooltipClasses = generateUtilityClasses('MuiTooltip', ['popper', 'popperInteractive', 'popperArrow', 'popperClose', 'tooltip', 'tooltipArrow', 'touch', 'tooltipPlacementLeft', 'tooltipPlacementRight', 'tooltipPlacementTop', 'tooltipPlacementBottom', 'arrow']);\nexport default tooltipClasses;","'use client';\n\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nconst _excluded = [\"arrow\", \"children\", \"classes\", \"components\", \"componentsProps\", \"describeChild\", \"disableFocusListener\", \"disableHoverListener\", \"disableInteractive\", \"disableTouchListener\", \"enterDelay\", \"enterNextDelay\", \"enterTouchDelay\", \"followCursor\", \"id\", \"leaveDelay\", \"leaveTouchDelay\", \"onClose\", \"onOpen\", \"open\", \"placement\", \"PopperComponent\", \"PopperProps\", \"slotProps\", \"slots\", \"title\", \"TransitionComponent\", \"TransitionProps\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport clsx from 'clsx';\nimport { elementAcceptingRef, unstable_useTimeout as useTimeout, unstable_Timeout as Timeout } from '@mui/utils';\nimport { unstable_composeClasses as composeClasses, appendOwnerState } from '@mui/base';\nimport { alpha } from '@mui/system';\nimport styled from '../styles/styled';\nimport useTheme from '../styles/useTheme';\nimport useThemeProps from '../styles/useThemeProps';\nimport capitalize from '../utils/capitalize';\nimport Grow from '../Grow';\nimport Popper from '../Popper';\nimport useEventCallback from '../utils/useEventCallback';\nimport useForkRef from '../utils/useForkRef';\nimport useId from '../utils/useId';\nimport useIsFocusVisible from '../utils/useIsFocusVisible';\nimport useControlled from '../utils/useControlled';\nimport tooltipClasses, { getTooltipUtilityClass } from './tooltipClasses';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nimport { jsxs as _jsxs } from \"react/jsx-runtime\";\nfunction round(value) {\n return Math.round(value * 1e5) / 1e5;\n}\nconst useUtilityClasses = ownerState => {\n const {\n classes,\n disableInteractive,\n arrow,\n touch,\n placement\n } = ownerState;\n const slots = {\n popper: ['popper', !disableInteractive && 'popperInteractive', arrow && 'popperArrow'],\n tooltip: ['tooltip', arrow && 'tooltipArrow', touch && 'touch', `tooltipPlacement${capitalize(placement.split('-')[0])}`],\n arrow: ['arrow']\n };\n return composeClasses(slots, getTooltipUtilityClass, classes);\n};\nconst TooltipPopper = styled(Popper, {\n name: 'MuiTooltip',\n slot: 'Popper',\n overridesResolver: (props, styles) => {\n const {\n ownerState\n } = props;\n return [styles.popper, !ownerState.disableInteractive && styles.popperInteractive, ownerState.arrow && styles.popperArrow, !ownerState.open && styles.popperClose];\n }\n})(({\n theme,\n ownerState,\n open\n}) => _extends({\n zIndex: (theme.vars || theme).zIndex.tooltip,\n pointerEvents: 'none'\n}, !ownerState.disableInteractive && {\n pointerEvents: 'auto'\n}, !open && {\n pointerEvents: 'none'\n}, ownerState.arrow && {\n [`&[data-popper-placement*=\"bottom\"] .${tooltipClasses.arrow}`]: {\n top: 0,\n marginTop: '-0.71em',\n '&::before': {\n transformOrigin: '0 100%'\n }\n },\n [`&[data-popper-placement*=\"top\"] .${tooltipClasses.arrow}`]: {\n bottom: 0,\n marginBottom: '-0.71em',\n '&::before': {\n transformOrigin: '100% 0'\n }\n },\n [`&[data-popper-placement*=\"right\"] .${tooltipClasses.arrow}`]: _extends({}, !ownerState.isRtl ? {\n left: 0,\n marginLeft: '-0.71em'\n } : {\n right: 0,\n marginRight: '-0.71em'\n }, {\n height: '1em',\n width: '0.71em',\n '&::before': {\n transformOrigin: '100% 100%'\n }\n }),\n [`&[data-popper-placement*=\"left\"] .${tooltipClasses.arrow}`]: _extends({}, !ownerState.isRtl ? {\n right: 0,\n marginRight: '-0.71em'\n } : {\n left: 0,\n marginLeft: '-0.71em'\n }, {\n height: '1em',\n width: '0.71em',\n '&::before': {\n transformOrigin: '0 0'\n }\n })\n}));\nconst TooltipTooltip = styled('div', {\n name: 'MuiTooltip',\n slot: 'Tooltip',\n overridesResolver: (props, styles) => {\n const {\n ownerState\n } = props;\n return [styles.tooltip, ownerState.touch && styles.touch, ownerState.arrow && styles.tooltipArrow, styles[`tooltipPlacement${capitalize(ownerState.placement.split('-')[0])}`]];\n }\n})(({\n theme,\n ownerState\n}) => _extends({\n backgroundColor: theme.vars ? theme.vars.palette.Tooltip.bg : alpha(theme.palette.grey[700], 0.92),\n borderRadius: (theme.vars || theme).shape.borderRadius,\n color: (theme.vars || theme).palette.common.white,\n fontFamily: theme.typography.fontFamily,\n padding: '4px 8px',\n fontSize: theme.typography.pxToRem(11),\n maxWidth: 300,\n margin: 2,\n wordWrap: 'break-word',\n fontWeight: theme.typography.fontWeightMedium\n}, ownerState.arrow && {\n position: 'relative',\n margin: 0\n}, ownerState.touch && {\n padding: '8px 16px',\n fontSize: theme.typography.pxToRem(14),\n lineHeight: `${round(16 / 14)}em`,\n fontWeight: theme.typography.fontWeightRegular\n}, {\n [`.${tooltipClasses.popper}[data-popper-placement*=\"left\"] &`]: _extends({\n transformOrigin: 'right center'\n }, !ownerState.isRtl ? _extends({\n marginRight: '14px'\n }, ownerState.touch && {\n marginRight: '24px'\n }) : _extends({\n marginLeft: '14px'\n }, ownerState.touch && {\n marginLeft: '24px'\n })),\n [`.${tooltipClasses.popper}[data-popper-placement*=\"right\"] &`]: _extends({\n transformOrigin: 'left center'\n }, !ownerState.isRtl ? _extends({\n marginLeft: '14px'\n }, ownerState.touch && {\n marginLeft: '24px'\n }) : _extends({\n marginRight: '14px'\n }, ownerState.touch && {\n marginRight: '24px'\n })),\n [`.${tooltipClasses.popper}[data-popper-placement*=\"top\"] &`]: _extends({\n transformOrigin: 'center bottom',\n marginBottom: '14px'\n }, ownerState.touch && {\n marginBottom: '24px'\n }),\n [`.${tooltipClasses.popper}[data-popper-placement*=\"bottom\"] &`]: _extends({\n transformOrigin: 'center top',\n marginTop: '14px'\n }, ownerState.touch && {\n marginTop: '24px'\n })\n}));\nconst TooltipArrow = styled('span', {\n name: 'MuiTooltip',\n slot: 'Arrow',\n overridesResolver: (props, styles) => styles.arrow\n})(({\n theme\n}) => ({\n overflow: 'hidden',\n position: 'absolute',\n width: '1em',\n height: '0.71em' /* = width / sqrt(2) = (length of the hypotenuse) */,\n boxSizing: 'border-box',\n color: theme.vars ? theme.vars.palette.Tooltip.bg : alpha(theme.palette.grey[700], 0.9),\n '&::before': {\n content: '\"\"',\n margin: 'auto',\n display: 'block',\n width: '100%',\n height: '100%',\n backgroundColor: 'currentColor',\n transform: 'rotate(45deg)'\n }\n}));\nlet hystersisOpen = false;\nconst hystersisTimer = new Timeout();\nlet cursorPosition = {\n x: 0,\n y: 0\n};\nexport function testReset() {\n hystersisOpen = false;\n hystersisTimer.clear();\n}\nfunction composeEventHandler(handler, eventHandler) {\n return event => {\n if (eventHandler) {\n eventHandler(event);\n }\n handler(event);\n };\n}\n\n// TODO v6: Remove PopperComponent, PopperProps, TransitionComponent and TransitionProps.\nconst Tooltip = /*#__PURE__*/React.forwardRef(function Tooltip(inProps, ref) {\n var _ref, _slots$popper, _ref2, _ref3, _slots$transition, _ref4, _slots$tooltip, _ref5, _slots$arrow, _slotProps$popper, _ref6, _slotProps$popper2, _slotProps$transition, _slotProps$tooltip, _ref7, _slotProps$tooltip2, _slotProps$arrow, _ref8, _slotProps$arrow2;\n const props = useThemeProps({\n props: inProps,\n name: 'MuiTooltip'\n });\n const {\n arrow = false,\n children: childrenProp,\n components = {},\n componentsProps = {},\n describeChild = false,\n disableFocusListener = false,\n disableHoverListener = false,\n disableInteractive: disableInteractiveProp = false,\n disableTouchListener = false,\n enterDelay = 100,\n enterNextDelay = 0,\n enterTouchDelay = 700,\n followCursor = false,\n id: idProp,\n leaveDelay = 0,\n leaveTouchDelay = 1500,\n onClose,\n onOpen,\n open: openProp,\n placement = 'bottom',\n PopperComponent: PopperComponentProp,\n PopperProps = {},\n slotProps = {},\n slots = {},\n title,\n TransitionComponent: TransitionComponentProp = Grow,\n TransitionProps\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n\n // to prevent runtime errors, developers will need to provide a child as a React element anyway.\n const children = /*#__PURE__*/React.isValidElement(childrenProp) ? childrenProp : /*#__PURE__*/_jsx(\"span\", {\n children: childrenProp\n });\n const theme = useTheme();\n const isRtl = theme.direction === 'rtl';\n const [childNode, setChildNode] = React.useState();\n const [arrowRef, setArrowRef] = React.useState(null);\n const ignoreNonTouchEvents = React.useRef(false);\n const disableInteractive = disableInteractiveProp || followCursor;\n const closeTimer = useTimeout();\n const enterTimer = useTimeout();\n const leaveTimer = useTimeout();\n const touchTimer = useTimeout();\n const [openState, setOpenState] = useControlled({\n controlled: openProp,\n default: false,\n name: 'Tooltip',\n state: 'open'\n });\n let open = openState;\n if (process.env.NODE_ENV !== 'production') {\n // eslint-disable-next-line react-hooks/rules-of-hooks\n const {\n current: isControlled\n } = React.useRef(openProp !== undefined);\n\n // eslint-disable-next-line react-hooks/rules-of-hooks\n React.useEffect(() => {\n if (childNode && childNode.disabled && !isControlled && title !== '' && childNode.tagName.toLowerCase() === 'button') {\n console.error(['MUI: You are providing a disabled `button` child to the Tooltip component.', 'A disabled element does not fire events.', \"Tooltip needs to listen to the child element's events to display the title.\", '', 'Add a simple wrapper element, such as a `span`.'].join('\\n'));\n }\n }, [title, childNode, isControlled]);\n }\n const id = useId(idProp);\n const prevUserSelect = React.useRef();\n const stopTouchInteraction = useEventCallback(() => {\n if (prevUserSelect.current !== undefined) {\n document.body.style.WebkitUserSelect = prevUserSelect.current;\n prevUserSelect.current = undefined;\n }\n touchTimer.clear();\n });\n React.useEffect(() => stopTouchInteraction, [stopTouchInteraction]);\n const handleOpen = event => {\n hystersisTimer.clear();\n hystersisOpen = true;\n\n // The mouseover event will trigger for every nested element in the tooltip.\n // We can skip rerendering when the tooltip is already open.\n // We are using the mouseover event instead of the mouseenter event to fix a hide/show issue.\n setOpenState(true);\n if (onOpen && !open) {\n onOpen(event);\n }\n };\n const handleClose = useEventCallback(\n /**\n * @param {React.SyntheticEvent | Event} event\n */\n event => {\n hystersisTimer.start(800 + leaveDelay, () => {\n hystersisOpen = false;\n });\n setOpenState(false);\n if (onClose && open) {\n onClose(event);\n }\n closeTimer.start(theme.transitions.duration.shortest, () => {\n ignoreNonTouchEvents.current = false;\n });\n });\n const handleEnter = event => {\n if (ignoreNonTouchEvents.current && event.type !== 'touchstart') {\n return;\n }\n\n // Remove the title ahead of time.\n // We don't want to wait for the next render commit.\n // We would risk displaying two tooltips at the same time (native + this one).\n if (childNode) {\n childNode.removeAttribute('title');\n }\n enterTimer.clear();\n leaveTimer.clear();\n if (enterDelay || hystersisOpen && enterNextDelay) {\n enterTimer.start(hystersisOpen ? enterNextDelay : enterDelay, () => {\n handleOpen(event);\n });\n } else {\n handleOpen(event);\n }\n };\n const handleLeave = event => {\n enterTimer.clear();\n leaveTimer.start(leaveDelay, () => {\n handleClose(event);\n });\n };\n const {\n isFocusVisibleRef,\n onBlur: handleBlurVisible,\n onFocus: handleFocusVisible,\n ref: focusVisibleRef\n } = useIsFocusVisible();\n // We don't necessarily care about the focusVisible state (which is safe to access via ref anyway).\n // We just need to re-render the Tooltip if the focus-visible state changes.\n const [, setChildIsFocusVisible] = React.useState(false);\n const handleBlur = event => {\n handleBlurVisible(event);\n if (isFocusVisibleRef.current === false) {\n setChildIsFocusVisible(false);\n handleLeave(event);\n }\n };\n const handleFocus = event => {\n // Workaround for https://github.com/facebook/react/issues/7769\n // The autoFocus of React might trigger the event before the componentDidMount.\n // We need to account for this eventuality.\n if (!childNode) {\n setChildNode(event.currentTarget);\n }\n handleFocusVisible(event);\n if (isFocusVisibleRef.current === true) {\n setChildIsFocusVisible(true);\n handleEnter(event);\n }\n };\n const detectTouchStart = event => {\n ignoreNonTouchEvents.current = true;\n const childrenProps = children.props;\n if (childrenProps.onTouchStart) {\n childrenProps.onTouchStart(event);\n }\n };\n const handleMouseOver = handleEnter;\n const handleMouseLeave = handleLeave;\n const handleTouchStart = event => {\n detectTouchStart(event);\n leaveTimer.clear();\n closeTimer.clear();\n stopTouchInteraction();\n prevUserSelect.current = document.body.style.WebkitUserSelect;\n // Prevent iOS text selection on long-tap.\n document.body.style.WebkitUserSelect = 'none';\n touchTimer.start(enterTouchDelay, () => {\n document.body.style.WebkitUserSelect = prevUserSelect.current;\n handleEnter(event);\n });\n };\n const handleTouchEnd = event => {\n if (children.props.onTouchEnd) {\n children.props.onTouchEnd(event);\n }\n stopTouchInteraction();\n leaveTimer.start(leaveTouchDelay, () => {\n handleClose(event);\n });\n };\n React.useEffect(() => {\n if (!open) {\n return undefined;\n }\n\n /**\n * @param {KeyboardEvent} nativeEvent\n */\n function handleKeyDown(nativeEvent) {\n // IE11, Edge (prior to using Bink?) use 'Esc'\n if (nativeEvent.key === 'Escape' || nativeEvent.key === 'Esc') {\n handleClose(nativeEvent);\n }\n }\n document.addEventListener('keydown', handleKeyDown);\n return () => {\n document.removeEventListener('keydown', handleKeyDown);\n };\n }, [handleClose, open]);\n const handleRef = useForkRef(children.ref, focusVisibleRef, setChildNode, ref);\n\n // There is no point in displaying an empty tooltip.\n // So we exclude all falsy values, except 0, which is valid.\n if (!title && title !== 0) {\n open = false;\n }\n const popperRef = React.useRef();\n const handleMouseMove = event => {\n const childrenProps = children.props;\n if (childrenProps.onMouseMove) {\n childrenProps.onMouseMove(event);\n }\n cursorPosition = {\n x: event.clientX,\n y: event.clientY\n };\n if (popperRef.current) {\n popperRef.current.update();\n }\n };\n const nameOrDescProps = {};\n const titleIsString = typeof title === 'string';\n if (describeChild) {\n nameOrDescProps.title = !open && titleIsString && !disableHoverListener ? title : null;\n nameOrDescProps['aria-describedby'] = open ? id : null;\n } else {\n nameOrDescProps['aria-label'] = titleIsString ? title : null;\n nameOrDescProps['aria-labelledby'] = open && !titleIsString ? id : null;\n }\n const childrenProps = _extends({}, nameOrDescProps, other, children.props, {\n className: clsx(other.className, children.props.className),\n onTouchStart: detectTouchStart,\n ref: handleRef\n }, followCursor ? {\n onMouseMove: handleMouseMove\n } : {});\n if (process.env.NODE_ENV !== 'production') {\n childrenProps['data-mui-internal-clone-element'] = true;\n\n // eslint-disable-next-line react-hooks/rules-of-hooks\n React.useEffect(() => {\n if (childNode && !childNode.getAttribute('data-mui-internal-clone-element')) {\n console.error(['MUI: The `children` component of the Tooltip is not forwarding its props correctly.', 'Please make sure that props are spread on the same element that the ref is applied to.'].join('\\n'));\n }\n }, [childNode]);\n }\n const interactiveWrapperListeners = {};\n if (!disableTouchListener) {\n childrenProps.onTouchStart = handleTouchStart;\n childrenProps.onTouchEnd = handleTouchEnd;\n }\n if (!disableHoverListener) {\n childrenProps.onMouseOver = composeEventHandler(handleMouseOver, childrenProps.onMouseOver);\n childrenProps.onMouseLeave = composeEventHandler(handleMouseLeave, childrenProps.onMouseLeave);\n if (!disableInteractive) {\n interactiveWrapperListeners.onMouseOver = handleMouseOver;\n interactiveWrapperListeners.onMouseLeave = handleMouseLeave;\n }\n }\n if (!disableFocusListener) {\n childrenProps.onFocus = composeEventHandler(handleFocus, childrenProps.onFocus);\n childrenProps.onBlur = composeEventHandler(handleBlur, childrenProps.onBlur);\n if (!disableInteractive) {\n interactiveWrapperListeners.onFocus = handleFocus;\n interactiveWrapperListeners.onBlur = handleBlur;\n }\n }\n if (process.env.NODE_ENV !== 'production') {\n if (children.props.title) {\n console.error(['MUI: You have provided a `title` prop to the child of .', `Remove this title prop \\`${children.props.title}\\` or the Tooltip component.`].join('\\n'));\n }\n }\n const popperOptions = React.useMemo(() => {\n var _PopperProps$popperOp;\n let tooltipModifiers = [{\n name: 'arrow',\n enabled: Boolean(arrowRef),\n options: {\n element: arrowRef,\n padding: 4\n }\n }];\n if ((_PopperProps$popperOp = PopperProps.popperOptions) != null && _PopperProps$popperOp.modifiers) {\n tooltipModifiers = tooltipModifiers.concat(PopperProps.popperOptions.modifiers);\n }\n return _extends({}, PopperProps.popperOptions, {\n modifiers: tooltipModifiers\n });\n }, [arrowRef, PopperProps]);\n const ownerState = _extends({}, props, {\n isRtl,\n arrow,\n disableInteractive,\n placement,\n PopperComponentProp,\n touch: ignoreNonTouchEvents.current\n });\n const classes = useUtilityClasses(ownerState);\n const PopperComponent = (_ref = (_slots$popper = slots.popper) != null ? _slots$popper : components.Popper) != null ? _ref : TooltipPopper;\n const TransitionComponent = (_ref2 = (_ref3 = (_slots$transition = slots.transition) != null ? _slots$transition : components.Transition) != null ? _ref3 : TransitionComponentProp) != null ? _ref2 : Grow;\n const TooltipComponent = (_ref4 = (_slots$tooltip = slots.tooltip) != null ? _slots$tooltip : components.Tooltip) != null ? _ref4 : TooltipTooltip;\n const ArrowComponent = (_ref5 = (_slots$arrow = slots.arrow) != null ? _slots$arrow : components.Arrow) != null ? _ref5 : TooltipArrow;\n const popperProps = appendOwnerState(PopperComponent, _extends({}, PopperProps, (_slotProps$popper = slotProps.popper) != null ? _slotProps$popper : componentsProps.popper, {\n className: clsx(classes.popper, PopperProps == null ? void 0 : PopperProps.className, (_ref6 = (_slotProps$popper2 = slotProps.popper) != null ? _slotProps$popper2 : componentsProps.popper) == null ? void 0 : _ref6.className)\n }), ownerState);\n const transitionProps = appendOwnerState(TransitionComponent, _extends({}, TransitionProps, (_slotProps$transition = slotProps.transition) != null ? _slotProps$transition : componentsProps.transition), ownerState);\n const tooltipProps = appendOwnerState(TooltipComponent, _extends({}, (_slotProps$tooltip = slotProps.tooltip) != null ? _slotProps$tooltip : componentsProps.tooltip, {\n className: clsx(classes.tooltip, (_ref7 = (_slotProps$tooltip2 = slotProps.tooltip) != null ? _slotProps$tooltip2 : componentsProps.tooltip) == null ? void 0 : _ref7.className)\n }), ownerState);\n const tooltipArrowProps = appendOwnerState(ArrowComponent, _extends({}, (_slotProps$arrow = slotProps.arrow) != null ? _slotProps$arrow : componentsProps.arrow, {\n className: clsx(classes.arrow, (_ref8 = (_slotProps$arrow2 = slotProps.arrow) != null ? _slotProps$arrow2 : componentsProps.arrow) == null ? void 0 : _ref8.className)\n }), ownerState);\n return /*#__PURE__*/_jsxs(React.Fragment, {\n children: [/*#__PURE__*/React.cloneElement(children, childrenProps), /*#__PURE__*/_jsx(PopperComponent, _extends({\n as: PopperComponentProp != null ? PopperComponentProp : Popper,\n placement: placement,\n anchorEl: followCursor ? {\n getBoundingClientRect: () => ({\n top: cursorPosition.y,\n left: cursorPosition.x,\n right: cursorPosition.x,\n bottom: cursorPosition.y,\n width: 0,\n height: 0\n })\n } : childNode,\n popperRef: popperRef,\n open: childNode ? open : false,\n id: id,\n transition: true\n }, interactiveWrapperListeners, popperProps, {\n popperOptions: popperOptions,\n children: ({\n TransitionProps: TransitionPropsInner\n }) => /*#__PURE__*/_jsx(TransitionComponent, _extends({\n timeout: theme.transitions.duration.shorter\n }, TransitionPropsInner, transitionProps, {\n children: /*#__PURE__*/_jsxs(TooltipComponent, _extends({}, tooltipProps, {\n children: [title, arrow ? /*#__PURE__*/_jsx(ArrowComponent, _extends({}, tooltipArrowProps, {\n ref: setArrowRef\n })) : null]\n }))\n }))\n }))]\n });\n});\nprocess.env.NODE_ENV !== \"production\" ? Tooltip.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the d.ts file and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * If `true`, adds an arrow to the tooltip.\n * @default false\n */\n arrow: PropTypes.bool,\n /**\n * Tooltip reference element.\n */\n children: elementAcceptingRef.isRequired,\n /**\n * Override or extend the styles applied to the component.\n */\n classes: PropTypes.object,\n /**\n * @ignore\n */\n className: PropTypes.string,\n /**\n * The components used for each slot inside.\n *\n * This prop is an alias for the `slots` prop.\n * It's recommended to use the `slots` prop instead.\n *\n * @default {}\n */\n components: PropTypes.shape({\n Arrow: PropTypes.elementType,\n Popper: PropTypes.elementType,\n Tooltip: PropTypes.elementType,\n Transition: PropTypes.elementType\n }),\n /**\n * The extra props for the slot components.\n * You can override the existing props or add new ones.\n *\n * This prop is an alias for the `slotProps` prop.\n * It's recommended to use the `slotProps` prop instead, as `componentsProps` will be deprecated in the future.\n *\n * @default {}\n */\n componentsProps: PropTypes.shape({\n arrow: PropTypes.object,\n popper: PropTypes.object,\n tooltip: PropTypes.object,\n transition: PropTypes.object\n }),\n /**\n * Set to `true` if the `title` acts as an accessible description.\n * By default the `title` acts as an accessible label for the child.\n * @default false\n */\n describeChild: PropTypes.bool,\n /**\n * Do not respond to focus-visible events.\n * @default false\n */\n disableFocusListener: PropTypes.bool,\n /**\n * Do not respond to hover events.\n * @default false\n */\n disableHoverListener: PropTypes.bool,\n /**\n * Makes a tooltip not interactive, i.e. it will close when the user\n * hovers over the tooltip before the `leaveDelay` is expired.\n * @default false\n */\n disableInteractive: PropTypes.bool,\n /**\n * Do not respond to long press touch events.\n * @default false\n */\n disableTouchListener: PropTypes.bool,\n /**\n * The number of milliseconds to wait before showing the tooltip.\n * This prop won't impact the enter touch delay (`enterTouchDelay`).\n * @default 100\n */\n enterDelay: PropTypes.number,\n /**\n * The number of milliseconds to wait before showing the tooltip when one was already recently opened.\n * @default 0\n */\n enterNextDelay: PropTypes.number,\n /**\n * The number of milliseconds a user must touch the element before showing the tooltip.\n * @default 700\n */\n enterTouchDelay: PropTypes.number,\n /**\n * If `true`, the tooltip follow the cursor over the wrapped element.\n * @default false\n */\n followCursor: PropTypes.bool,\n /**\n * This prop is used to help implement the accessibility logic.\n * If you don't provide this prop. It falls back to a randomly generated id.\n */\n id: PropTypes.string,\n /**\n * The number of milliseconds to wait before hiding the tooltip.\n * This prop won't impact the leave touch delay (`leaveTouchDelay`).\n * @default 0\n */\n leaveDelay: PropTypes.number,\n /**\n * The number of milliseconds after the user stops touching an element before hiding the tooltip.\n * @default 1500\n */\n leaveTouchDelay: PropTypes.number,\n /**\n * Callback fired when the component requests to be closed.\n *\n * @param {React.SyntheticEvent} event The event source of the callback.\n */\n onClose: PropTypes.func,\n /**\n * Callback fired when the component requests to be open.\n *\n * @param {React.SyntheticEvent} event The event source of the callback.\n */\n onOpen: PropTypes.func,\n /**\n * If `true`, the component is shown.\n */\n open: PropTypes.bool,\n /**\n * Tooltip placement.\n * @default 'bottom'\n */\n placement: PropTypes.oneOf(['bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n /**\n * The component used for the popper.\n * @default Popper\n */\n PopperComponent: PropTypes.elementType,\n /**\n * Props applied to the [`Popper`](/material-ui/api/popper/) element.\n * @default {}\n */\n PopperProps: PropTypes.object,\n /**\n * The extra props for the slot components.\n * You can override the existing props or add new ones.\n *\n * This prop is an alias for the `componentsProps` prop, which will be deprecated in the future.\n *\n * @default {}\n */\n slotProps: PropTypes.shape({\n arrow: PropTypes.object,\n popper: PropTypes.object,\n tooltip: PropTypes.object,\n transition: PropTypes.object\n }),\n /**\n * The components used for each slot inside.\n *\n * This prop is an alias for the `components` prop, which will be deprecated in the future.\n *\n * @default {}\n */\n slots: PropTypes.shape({\n arrow: PropTypes.elementType,\n popper: PropTypes.elementType,\n tooltip: PropTypes.elementType,\n transition: PropTypes.elementType\n }),\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Tooltip title. Zero-length titles string, undefined, null and false are never displayed.\n */\n title: PropTypes.node,\n /**\n * The component used for the transition.\n * [Follow this guide](/material-ui/transitions/#transitioncomponent-prop) to learn more about the requirements for this component.\n * @default Grow\n */\n TransitionComponent: PropTypes.elementType,\n /**\n * Props applied to the transition element.\n * By default, the element is based on this [`Transition`](http://reactcommunity.org/react-transition-group/transition/) component.\n */\n TransitionProps: PropTypes.object\n} : void 0;\nexport default Tooltip;","import '@/components/mui/menu-item.component.css';\nimport ArrowRightIcon from '@mui/icons-material/ArrowRight';\nimport {\n ListItemIcon as MuiListItemIcon,\n ListItemText as MuiListItemText,\n MenuItem as MuiMenuItem,\n} from '@mui/material';\nimport Tooltip from '@mui/material/Tooltip';\nimport { Localized, ReferencedItem, SingleColumnMenu } from 'platform-bible-utils';\nimport { MouseEvent, PropsWithChildren } from 'react';\n\ntype MenuItemInfoBase = {\n /** Text (displayable in the UI) as the name of the menu item */\n label: string;\n /** Text to display when the mouse hovers over the menu item */\n tooltip?: string;\n};\n\nexport type Command = MenuItemInfoBase & {\n /** Command to execute (string.string) */\n command: string;\n};\n\ntype SubMenu = MenuItemInfoBase & {\n /** Command to execute (string.string) */\n items: MenuItemInfo[];\n};\n\nexport interface CommandHandler {\n (command: Command): void;\n}\n\nexport type MenuPropsBase = {\n /*\n * The JSON defining the menu whose items are to be rendered. This will typically be one of the\n * menus in the \"defs\" in a Platform.Bible menu (see PlatformMenus). The schema for this is\n * menuDocumentSchema (at the end of menus.model.ts). Note that while this is a\n * \"SingleColumnMenu\", somewhat bizarrely, a MultiColumnMenu is a SingleColumnMenu, so it really\n * could be a MultiColumnMenu, in which case, column had better be defined so it can be used\n * to filter out the actual groups and items to display on the column.\n */\n menuDefinition: Localized;\n\n commandHandler: CommandHandler;\n\n /**\n * Additional action to perform when any menu item is clicked. Allows the caller to handle event\n * (e.g., to close the menu).\n */\n onClick?: (event: MouseEvent) => void;\n};\n\nexport type MenuItemListProps = MenuPropsBase & {\n /** Optional unique (column) identifier */\n columnId?: ReferencedItem;\n};\n\nexport type MenuItemProps = Omit &\n PropsWithChildren<{\n /** Optional unique identifier */\n id?: string;\n\n onClick: (event: MouseEvent) => void;\n }>;\n\ntype MenuItemInfo = (Command | SubMenu) & {\n /**\n * If specified, menu item will be inset if it does not have a leading icon.\n *\n * @default true\n */\n allowForLeadingIcons?: boolean;\n /**\n * If specified, the path to the icon image to display on the leading side of the menu text.\n *\n * @default undefined (no leading icon will be shown)\n */\n iconPathBefore?: string;\n /**\n * If specified, the path to the icon image to display on the trailing side of the menu text.\n *\n * @default undefined (no trailing icon will be shown)\n */\n iconPathAfter?: string;\n /**\n * If true, list item is focused during the first mount\n *\n * @default false\n */\n hasAutoFocus?: boolean;\n\n /** Additional css classes to help with unique styling of the menu item */\n className?: string;\n\n /**\n * If true, the menu item will appear disabled and it will not respond to clicks or mouse hovers.\n *\n * @default false\n */\n isDisabled?: boolean;\n\n /**\n * If true, compact vertical padding designed for keyboard and mouse input is used.\n *\n * @default true\n */\n isDense?: boolean;\n\n /**\n * If true, a right-arrow icon will be displayed (iconPathAfter, if specified, will be ignored).\n *\n * @default false\n */\n isSubMenuParent?: boolean;\n\n /**\n * If true, the left and right padding is removed\n *\n * @default false\n */\n hasDisabledGutters?: boolean;\n\n /**\n * If true, a 1px light border is added to bottom of menu item\n *\n * @default false\n */\n hasDivider?: boolean;\n\n /** Help identify which element has keyboard focus */\n focusVisibleClassName?: string;\n\n /** If it's a submenu, it should have the items property */\n items?: MenuItemInfo[];\n};\n\nfunction getIcon(icon: string | undefined, menuLabel: string, leading: boolean) {\n return icon ? (\n \n {`${leading\n \n ) : undefined;\n}\n\nexport default function MenuItem(props: MenuItemProps) {\n const {\n onClick,\n label,\n tooltip,\n allowForLeadingIcons = true,\n iconPathBefore = undefined,\n iconPathAfter = undefined,\n hasAutoFocus = false,\n className,\n isDisabled = false,\n isDense = true,\n isSubMenuParent = false,\n hasDisabledGutters = false,\n hasDivider = false,\n focusVisibleClassName,\n id,\n children,\n } = props;\n\n const menuItem = (\n \n {label ? (\n <>\n {getIcon(iconPathBefore, label, true)}\n \n {isSubMenuParent ? (\n \n \n \n ) : (\n getIcon(iconPathAfter, label, false)\n )}\n \n ) : (\n children\n )}\n \n );\n\n return tooltip ? (\n \n
    {menuItem}
    \n
    \n ) : (\n menuItem\n );\n}\n","import MenuItem, {\n MenuItemListProps,\n MenuItemProps,\n MenuPropsBase,\n} from '@/components/mui/menu-item.component';\nimport { Menu } from '@mui/material';\nimport {\n Localized,\n MenuGroupDetailsInSubMenu,\n MenuItemContainingCommand,\n MenuItemContainingSubmenu,\n OrderedExtensibleContainer,\n ReferencedItem,\n SingleColumnMenu,\n} from 'platform-bible-utils';\nimport { MouseEvent, useMemo, useState } from 'react';\n\n/**\n * All the exported types in this file should be regarded as \"internal\" (i.e., they should not be\n * exposed via index.ts).\n */\n\nexport type GroupedMenuPropsBase = MenuPropsBase & {\n /** Optional unique (column) identifier */\n columnId?: ReferencedItem;\n};\n\nexport type GroupedMenuItemListProps = MenuItemListProps & {\n /**\n * If the menuDefinition includes \"top-level\" groups (i.e., those that belong to a column as\n * opposed to those that belong to a submenu) that should not be included in the list, then this\n * array specifies which groups to include. Likewise, for a submenu, this list indicates which\n * groups are pertinent for that submenu. So then for a context menu this property need not be\n * specified since it is a top-level menu based on a \"true\" SingleColumnMenu (i.e., one that is\n * not a MultiColumnMenu).\n */\n includedGroups?: {\n id: string;\n group: Localized;\n }[];\n};\n\ninterface ItemInfo {\n item: Localized;\n isLastItemInGroup: boolean;\n}\n\ntype SubMenuProps = MenuPropsBase & {\n parentMenuItem: Localized;\n parentItemProps: Omit, 'iconPathAfter'>;\n};\n\nfunction getAllGroups(menuDefinition: Localized) {\n const groupEntries = Object.entries(menuDefinition.groups);\n // Convert array of entries to array of objects with id and group properties\n return groupEntries.map(([key, value]) => ({ id: key, group: value }));\n}\n\nfunction SubMenu(props: SubMenuProps) {\n const [anchorEl, setAnchorEl] = useState(undefined);\n\n const { parentMenuItem, parentItemProps, menuDefinition } = props;\n\n const handleParentMenuItemClick = (event: MouseEvent) => {\n setAnchorEl(event.currentTarget);\n };\n\n const handleClose = () => {\n setAnchorEl(undefined);\n };\n\n const renderSubMenuItems = () => {\n let includedGroups = getAllGroups(menuDefinition).filter((g) => 'menuItem' in g.group);\n\n // Ensure valid parent menu was provided. (If not, submenu will contain all groups!)\n if (!parentMenuItem?.id) throw new Error('A valid parent menu item is required for submenus.');\n\n // When laying out a submenu, only include groups associated with the provided parent menu.\n // Note: without the (annoying) redundant check that the included groups\n // have the menuItem field, TS doesn't think it exists.\n includedGroups = includedGroups.filter(\n (group) => 'menuItem' in group.group && group.group.menuItem === parentMenuItem.id,\n );\n\n return ;\n };\n\n return (\n <>\n \n \n {renderSubMenuItems()}\n \n \n );\n}\n\nconst getOrderedGroupItems = (\n groupId: string,\n allItems: Localized[],\n) => {\n // Filter items that belong to the specified group\n const itemsForGroup = allItems.filter((item) => item.group === groupId);\n // Sort items based on order\n const sortedItems = itemsForGroup.sort((a, b) => (a.order || 0) - (b.order || 0));\n return sortedItems;\n};\n\n/**\n * This component is internal; it does not need to be exposed to the outside world since it is not\n * useful on its own. It is used to generate and lay out the MenuItems that appear either on a\n * top-level menu (in a GridMenu or ContextMenu) or in a submenu.\n */\nexport default function GroupedMenuItemList(menuProps: GroupedMenuItemListProps) {\n const { menuDefinition, onClick, commandHandler, includedGroups } = menuProps;\n\n const { items, allowForLeadingIcons } = useMemo(() => {\n const groupsToInclude =\n includedGroups && includedGroups.length > 0\n ? includedGroups\n : // We're apparently laying out a single-column menu (presumably a context menu). In this\n // case, all groups should be included except ones that belong to a submenu.\n getAllGroups(menuDefinition).filter((g) => !('menuItem' in g.group));\n\n const sortedGroups = Object.values(groupsToInclude).sort(\n (a, b) => (a.group.order || 0) - (b.group.order || 0),\n );\n\n const itemArray: ItemInfo[] = [];\n\n sortedGroups.forEach((group) => {\n getOrderedGroupItems(group.id, menuDefinition.items).forEach((item) =>\n itemArray.push({ item, isLastItemInGroup: false }),\n );\n if (itemArray.length > 0) itemArray[itemArray.length - 1].isLastItemInGroup = true;\n });\n\n // No divider after last item in final group.\n if (itemArray.length > 0) itemArray[itemArray.length - 1].isLastItemInGroup = false;\n\n const allowSpaceForLeadingIcons = itemArray.some(\n (i) => 'iconPathBefore' in i.item && i.item.iconPathBefore,\n );\n\n return { items: itemArray, allowForLeadingIcons: allowSpaceForLeadingIcons };\n }, [includedGroups, menuDefinition]);\n\n // Create props for MenuItem component including setting hasDivider for the last item in a group\n const createMenuItemProps = ({ item, isLastItemInGroup }: ItemInfo) => {\n const menuItemProps = {\n className: 'papi-menu-item',\n label: item.label,\n tooltip: item.tooltip,\n iconPathBefore: 'iconPathBefore' in item ? item.iconPathBefore : undefined,\n iconPathAfter: 'iconPathAfter' in item ? item.iconPathAfter : undefined,\n hasDivider: isLastItemInGroup, // Set hasDivider to true for the last item in a group\n allowForLeadingIcons,\n };\n\n return menuItemProps;\n };\n\n const [firstItem] = items;\n\n if (!firstItem) return
    ;\n\n const divKey = firstItem.item.group;\n\n return (\n
    \n {items.map((itemInfo, index) => {\n const { item } = itemInfo;\n const menuItemProps = createMenuItemProps(itemInfo);\n if ('command' in item) {\n const key = item.group + index;\n return (\n ) => {\n onClick?.(event);\n commandHandler(item);\n }}\n {...menuItemProps}\n />\n );\n }\n return (\n \n );\n })}\n
    \n );\n}\n","import GroupedMenuItemList from '@/components/mui/grouped-menu-item-list.component';\nimport { MenuItemListProps } from '@/components/mui/menu-item.component';\nimport { MultiColumnMenu } from 'platform-bible-utils';\n\n/**\n * This component is internal; it does not need to be exposed to the outside world since it is not\n * useful on its own. Use either GridMenu or ContextMenu.\n */\nexport default function TopLevelMenu(props: MenuItemListProps) {\n const { menuDefinition, columnId } = props;\n\n const groupEntries = Object.entries(menuDefinition.groups);\n // Convert array of entries to array of objects with id and group properties\n const groups = groupEntries.map(([key, value]) => ({ id: key, group: value }));\n let includedGroups = groups.filter((g) => 'column' in g.group);\n\n // Check if column is provided and menuDefinition is a MultiColumnMenu\n if (\n columnId &&\n 'columns' in menuDefinition &&\n // Without this type assertion, TS doesn't know what columns is.\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n (menuDefinition as MultiColumnMenu).columns[columnId]\n ) {\n // When laying out a single column in a MultiColumnMenu, only include groups associated with\n // the provided column. Note: without the (annoying) redundant check that the included groups\n // have the colum field, TS doesn't think it exists.\n includedGroups = includedGroups.filter(\n (g) => 'column' in g.group && g.group.column === columnId,\n );\n }\n\n return ;\n}\n","import '@/components/mui/grid-menu.component.css';\nimport { GroupedMenuPropsBase } from '@/components/mui/grouped-menu-item-list.component';\nimport { CommandHandler } from '@/components/mui/menu-item.component';\nimport TopLevelMenu from '@/components/mui/top-level-menu.component';\nimport { Grid, List } from '@mui/material';\nimport {\n Localized,\n MenuColumnWithHeader,\n MultiColumnMenu,\n ReferencedItem,\n} from 'platform-bible-utils';\nimport { useMemo } from 'react';\n\ntype ColumnInfo = {\n /*\n * The ID (`${string}.${string}`) of a specific menu column.\n */\n id: ReferencedItem;\n\n /*\n * Metadata (label, order, etc.) for a specific menu column.\n */\n metadata: Localized;\n};\n\ntype MenuColumnProps = ColumnInfo &\n GroupedMenuPropsBase & {\n /** Additional css classes to help with unique styling of the menu column */\n className?: string;\n };\n\nexport type GridMenuInfo = {\n /** The menu object containing information about the columns, groups, and items to display. */\n multiColumnMenu: Localized;\n};\n\nexport type GridMenuProps = GridMenuInfo & {\n /** Optional unique identifier */\n id?: string;\n\n commandHandler: CommandHandler;\n\n /** Additional css classes to help with unique styling of the grid menu */\n className?: string;\n};\n\nfunction MenuColumn({\n commandHandler,\n menuDefinition,\n id,\n metadata,\n onClick,\n className,\n}: MenuColumnProps) {\n return (\n \n

    \n {metadata.label}\n

    \n {/* It would seem as though this List component were unnecessary, since it only contains one\n thing, but the \"dense\" property does affect the layout of the items (in a way I don't fully\n understand). There might be a better way. */}\n \n \n \n \n );\n}\n\nexport default function GridMenu({\n commandHandler,\n className,\n multiColumnMenu,\n id,\n}: GridMenuProps) {\n const { columns } = multiColumnMenu;\n\n const sortedColumns = useMemo(() => {\n const columnNumbers = new Map();\n Object.getOwnPropertyNames(columns).forEach((columnName: string) => {\n // We know for sure there is a (boolean) property 'isExtensible' that we are not interested in.\n if (columnName === 'isExtensible') return;\n // TS doesn't allow `columnName` above to be a ReferencedItem even though the type says it is\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const columnId = columnName as ReferencedItem;\n const column = columns[columnId];\n // As of right now (and hopefully forever after), all remaining properties of the\n // ColumnsWithHeaders object are columns whose property names are the IDs of the columns.\n // This is an additional (redundant) sanity check. Specifically we're interested in\n // MenuColumnWithHeader objects, which TypeScript now \"knows\" we have, but at runtime all we\n // can check for is that it's an object with a valid numeric order field. That's likely good\n // enough.\n if (\n typeof column === 'object' &&\n typeof column.order === 'number' &&\n !Number.isNaN(column.order)\n )\n columnNumbers.set(column.order, { id: columnId, metadata: column });\n else\n console.warn(\n `Property ${columnName} (${typeof column}) on menu ${id} is not a valid column and is being ignored. This might indicate data corruption`,\n );\n });\n\n // Extract values and sort them based on the 'order' property\n return Array.from(columnNumbers.values()).sort((a, b) => {\n return (a.metadata.order || 0) - (b.metadata.order || 0);\n });\n }, [columns, id]);\n\n // We might need something like this if we need to be able to prevent empty columns\n // sortedColumns.filter((c) => multiColumnMenu.groups.some((g) => 'column' in g && (g as .column)...\n\n return (\n \n {sortedColumns.map((col, index) => (\n \n ))}\n \n );\n}\n","import { useEffect, useRef, useState } from 'react';\n\nexport type UsePromiseOptions = {\n /**\n * Whether to leave the value as the most recent resolved promise value or set it back to\n * defaultValue while running the promise again. Defaults to true\n */\n preserveValue?: boolean;\n};\n\n/** Set up defaults for options for usePromise hook */\nfunction getUsePromiseOptionsDefaults(options: UsePromiseOptions): UsePromiseOptions {\n return {\n preserveValue: true,\n ...options,\n };\n}\n\n/**\n * Awaits a promise and returns a loading value while the promise is unresolved\n *\n * @param promiseFactoryCallback A function that returns the promise to await. If this callback is\n * undefined, the current value will be returned (defaultValue unless it was previously changed\n * and `options.preserveValue` is true), and there will be no loading.\n *\n * WARNING: MUST BE STABLE - const or wrapped in useCallback. The reference must not be updated\n * every render\n * @param defaultValue The initial value to return while first awaiting the promise. If\n * `options.preserveValue` is false, this value is also shown while awaiting the promise on\n * subsequent calls.\n *\n * Note: this parameter is internally assigned to a `ref`, so changing it will not cause any hooks\n * to re-run with its new value. This means that, if the `promiseFactoryCallback` changes and\n * `options.preserveValue` is `false`, the returned value will be set to the current\n * `defaultValue`. However, the returned value will not be updated if`defaultValue` changes.\n * @param options Various options for adjusting how this hook runs the `promiseFactoryCallback`\n *\n * Note: this parameter is internally assigned to a `ref`, so changing it will not cause any hooks\n * to re-run with its new value. However, the latest `options.preserveValue` will always be used\n * appropriately to determine whether to preserve the returned value when changing the\n * `promiseFactoryCallback`\n * @returns `[value, isLoading]`\n *\n * - `value`: the current value for the promise, either the defaultValue or the resolved promise value\n * - `isLoading`: whether the promise is waiting to be resolved\n */\nconst usePromise = (\n promiseFactoryCallback: (() => Promise) | undefined,\n defaultValue: T,\n options: UsePromiseOptions = {},\n): [value: T, isLoading: boolean] => {\n // Use defaultValue as a ref so it doesn't update dependency arrays\n const defaultValueRef = useRef(defaultValue);\n defaultValueRef.current = defaultValue;\n // Use options as a ref so it doesn't update dependency arrays\n const optionsDefaultedRef = useRef(options);\n optionsDefaultedRef.current = getUsePromiseOptionsDefaults(optionsDefaultedRef.current);\n\n const [value, setValue] = useState(() => defaultValueRef.current);\n const [isLoading, setIsLoading] = useState(true);\n useEffect(() => {\n let promiseIsCurrent = true;\n // If a promiseFactoryCallback was provided, we are loading. Otherwise, there is no loading to do\n setIsLoading(!!promiseFactoryCallback);\n (async () => {\n // If there is a callback to run, run it\n if (promiseFactoryCallback) {\n const result = await promiseFactoryCallback();\n // If the promise was not already replaced, update the value\n if (promiseIsCurrent) {\n setValue(() => result);\n setIsLoading(false);\n }\n }\n })();\n\n return () => {\n // Mark this promise as old and not to be used\n promiseIsCurrent = false;\n if (!optionsDefaultedRef.current.preserveValue) setValue(() => defaultValueRef.current);\n };\n }, [promiseFactoryCallback]);\n\n return [value, isLoading];\n};\nexport default usePromise;\n","\"use client\";\n\nimport createSvgIcon from './utils/createSvgIcon';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nexport default createSvgIcon( /*#__PURE__*/_jsx(\"path\", {\n d: \"M3 18h18v-2H3zm0-5h18v-2H3zm0-7v2h18V6z\"\n}), 'Menu');","import GridMenu from '@/components/mui/grid-menu.component';\nimport { Command, CommandHandler } from '@/components/mui/menu-item.component';\nimport usePromise from '@/hooks/use-promise.hook';\nimport { Menu as MenuIcon } from '@mui/icons-material';\nimport { Drawer, IconButton } from '@mui/material';\nimport { Localized, MultiColumnMenu } from 'platform-bible-utils';\nimport {\n MouseEvent,\n MutableRefObject,\n PropsWithChildren,\n useCallback,\n useEffect,\n useState,\n} from 'react';\n\nexport interface MultiColumnMenuProvider {\n (isSupportAndDevelopment: boolean): Promise>;\n}\n\nexport type HamburgerMenuButtonProps = PropsWithChildren & {\n /** The handler to use for menu commands (and eventually toolbar commands). */\n commandHandler: CommandHandler;\n\n /**\n * Optional reference to the \"div\" container that determines the where the menu should appear. If\n * not defined, then (1,1) used.\n */\n containerRef?: MutableRefObject;\n\n /**\n * The delegate to use to get the menu data. If not specified or if it returns undefined, the data\n * in normalMenu or fullMenu property will be used.\n */\n menuProvider?: MultiColumnMenuProvider;\n\n /**\n * The menu data to show when the menu is opened if the menuProvider property is not defined.\n * (This allows for a default or test-only static menu to be used.)\n */\n normalMenu?: Localized;\n\n /**\n * The menu data to show for \"full\" menu (when opened with the SHIFT key pressed) if the\n * menuProvider property is not defined. (This allows for a default or test-only static menu to be\n * used.)\n */\n fullMenu?: Localized;\n\n /** Additional css class(es) to help with unique styling of the sub-components */\n className?: string;\n\n /** Value to use as prefix for ARIA labels on interactive sub-components */\n ariaLabelPrefix?: string;\n};\n\nexport default function HamburgerMenuButton({\n menuProvider,\n normalMenu,\n fullMenu,\n commandHandler,\n containerRef,\n className,\n ariaLabelPrefix,\n children,\n}: HamburgerMenuButtonProps) {\n const [isMenuOpen, setMenuOpen] = useState(false);\n const [showFullMenu, setShowFullMenu] = useState(false);\n\n const handleMenuItemClick = useCallback(() => {\n if (isMenuOpen) setMenuOpen(false);\n setShowFullMenu(false);\n }, [isMenuOpen]);\n\n const handleMenuButtonClick = useCallback((e: MouseEvent) => {\n e.stopPropagation();\n setMenuOpen((prevIsOpen) => {\n const isOpening = !prevIsOpen;\n if (isOpening && e.shiftKey) setShowFullMenu(true);\n else if (!isOpening) setShowFullMenu(false);\n return isOpening;\n });\n }, []);\n\n const menuCommandHandler = useCallback(\n (command: Command) => {\n handleMenuItemClick();\n return commandHandler(command);\n },\n [commandHandler, handleMenuItemClick],\n );\n\n const [offset, setOffset] = useState({ top: 1, left: 1 });\n\n useEffect(() => {\n if (isMenuOpen) {\n const node = containerRef?.current;\n if (node) {\n const rect = node.getBoundingClientRect();\n const scrollTop = window.scrollY;\n const scrollLeft = window.scrollX;\n const top = rect.top + scrollTop + node.clientHeight;\n const left = rect.left + scrollLeft;\n setOffset({ top, left });\n }\n }\n }, [isMenuOpen, containerRef]);\n\n const [normalMenuData] = usePromise(\n useCallback(async () => {\n return menuProvider?.(false) ?? normalMenu;\n // isMenuOpen needs to be included for the menu contents to reevaluate when reopened\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [menuProvider, normalMenu, isMenuOpen]),\n normalMenu,\n );\n\n const [fullMenuData] = usePromise(\n useCallback(async () => {\n return menuProvider?.(true) ?? fullMenu ?? normalMenuData;\n // isMenuOpen needs to be included for the menu contents to reevaluate when reopened\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [menuProvider, fullMenu, normalMenuData, isMenuOpen]),\n fullMenu ?? normalMenuData,\n );\n\n const menu = showFullMenu && fullMenuData ? fullMenuData : normalMenuData;\n\n return (\n <>\n \n {children ?? }\n \n \n {menu ? (\n \n ) : undefined}\n \n \n );\n}\n","import '@/components/mui/icon-button.component.css';\nimport { IconButton as MuiIconButton } from '@mui/material';\nimport { MouseEventHandler, PropsWithChildren } from 'react';\n\nexport type IconButtonProps = PropsWithChildren<{\n /** Optional unique identifier */\n id?: string;\n /**\n * Required. Used as both the tooltip (aka, title) and the aria-label (used for accessibility,\n * testing, etc.), unless a distinct tooltip is supplied.\n */\n label: string;\n /**\n * Enabled status of button\n *\n * @default false\n */\n isDisabled?: boolean;\n /** Optional tooltip to display if different from the aria-label. */\n tooltip?: string;\n /** If true, no tooltip will be displayed. */\n isTooltipSuppressed?: boolean;\n /**\n * If given, uses a negative margin to counteract the padding on one side (this is often helpful\n * for aligning the left or right side of the icon with content above or below, without ruining\n * the border size and shape).\n *\n * @default false\n */\n adjustMarginToAlignToEdge?: 'end' | 'start' | false;\n /**\n * The size of the component. small is equivalent to the dense button styling.\n *\n * @default false\n */\n size: 'small' | 'medium' | 'large';\n /** Additional css classes to help with unique styling of the button */\n className?: string;\n /** Optional click handler */\n onClick?: MouseEventHandler;\n}>;\n\n/**\n * Iconic button a user can click to do something\n *\n * Thanks to MUI for heavy inspiration and documentation\n * https://mui.com/material-ui/getting-started/overview/\n */\nfunction IconButton({\n id,\n label,\n isDisabled = false,\n tooltip,\n isTooltipSuppressed = false,\n adjustMarginToAlignToEdge = false,\n size = 'medium',\n className,\n onClick,\n children,\n}: IconButtonProps) {\n return (\n \n {children /* the icon to display */}\n \n );\n}\n\nexport default IconButton;\n","import { cn } from '@/utils/shadcn-ui.util';\nimport { LoaderCircle, LucideProps } from 'lucide-react';\nimport { forwardRef } from 'react';\n\nexport type SpinnerProps = LucideProps;\n\nconst Spinner = forwardRef(({ className, ...props }, ref) => {\n return (\n \n );\n});\n\nSpinner.displayName = 'Spinner';\n\nexport default Spinner;\n","import { Input as ShadInput } from '@/components/shadcn-ui/input';\nimport { Label as ShadLabel } from '@/components/shadcn-ui/label';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { ChangeEventHandler, FocusEventHandler } from 'react';\n\nexport type TextFieldProps = {\n /** Optional unique identifier */\n id?: string;\n /**\n * If `true`, the component is disabled.\n *\n * @default false\n */\n isDisabled?: boolean;\n /**\n * If `true`, the label is displayed in an error state.\n *\n * @default false\n */\n hasError?: boolean;\n /**\n * If `true`, the input will take up the full width of its container.\n *\n * @default false\n */\n isFullWidth?: boolean;\n /** Text that gives the user instructions on what contents the TextField expects */\n helperText?: string;\n /** The title of the TextField */\n label?: string;\n /** The short hint displayed in the `input` before the user enters a value. */\n placeholder?: string;\n /**\n * If `true`, the label is displayed as required and the `input` element is required.\n *\n * @default false\n */\n isRequired?: boolean;\n /** Additional css classes to help with unique styling of the text field */\n className?: string;\n /** Starting value for the text field if it is not controlled */\n defaultValue?: string | number;\n /** Value of the text field if controlled */\n value?: string | number;\n /** Triggers when content of textfield is changed */\n onChange?: ChangeEventHandler;\n /** Triggers when textfield gets focus */\n onFocus?: FocusEventHandler;\n /** Triggers when textfield loses focus */\n onBlur?: FocusEventHandler;\n};\n\n/**\n * Text input field\n *\n * Thanks to Shadcn for heavy inspiration and documentation\n * https://ui.shadcn.com/docs/components/input#with-label\n */\nfunction TextField({\n id,\n isDisabled = false,\n hasError = false,\n isFullWidth = false,\n helperText,\n label,\n placeholder,\n isRequired = false,\n className,\n defaultValue,\n value,\n onChange,\n onFocus,\n onBlur,\n}: TextFieldProps) {\n return (\n
    \n {`${label}${isRequired ? '*' : ''}`}\n \n

    {helperText}

    \n
    \n );\n}\n\nexport default TextField;\n","import HamburgerMenuButton, {\n MultiColumnMenuProvider,\n} from '@/components/mui/hamburger-menu-button.component';\nimport { CommandHandler } from '@/components/mui/menu-item.component';\nimport '@/components/mui/toolbar.component.css';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { AppBar, Toolbar as MuiToolbar } from '@mui/material';\nimport { PropsWithChildren, useRef } from 'react';\n\nexport type ToolbarProps = PropsWithChildren<{\n /** The handler to use for menu commands (and eventually toolbar commands). */\n commandHandler: CommandHandler;\n\n /**\n * The optional delegate to use to get the menu data. If not specified, the \"hamburger\" menu will\n * not display.\n */\n menuProvider?: MultiColumnMenuProvider;\n\n /** Optional unique identifier */\n id?: string;\n\n /** Additional css classes to help with unique styling of the toolbar */\n className?: string;\n}>;\n\nexport default function Toolbar({\n menuProvider,\n commandHandler,\n className,\n id,\n children,\n}: ToolbarProps) {\n // This ref will always be defined\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const containerRef = useRef(undefined!);\n\n return (\n
    \n \n \n {menuProvider ? (\n \n ) : undefined}\n {children ?
    {children}
    : undefined}\n \n
    \n
    \n );\n}\n","import React from 'react';\nimport { cva, type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst alertVariants = cva(\n 'tw-relative tw-w-full tw-rounded-lg tw-border tw-p-4 [&>svg~*]:tw-pl-7 [&>svg+div]:tw-translate-y-[-3px] [&>svg]:tw-absolute [&>svg]:tw-left-4 [&>svg]:tw-top-4 [&>svg]:tw-text-foreground',\n {\n variants: {\n variant: {\n default: 'tw-bg-background tw-text-foreground',\n destructive:\n 'tw-border-destructive/50 tw-text-destructive dark:tw-border-destructive [&>svg]:tw-text-destructive',\n },\n },\n defaultVariants: {\n variant: 'default',\n },\n },\n);\n\nconst Alert = React.forwardRef<\n HTMLDivElement,\n React.HTMLAttributes & VariantProps\n>(({ className, variant, ...props }, ref) => (\n
    \n));\nAlert.displayName = 'Alert';\n\nconst AlertTitle = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n {/* added because of https://github.com/jsx-eslint/eslint-plugin-jsx-a11y/blob/main/docs/rules/heading-has-content.md */}\n {props.children}{' '}\n \n ),\n);\nAlertTitle.displayName = 'AlertTitle';\n\nconst AlertDescription = React.forwardRef<\n HTMLParagraphElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n
    \n));\nAlertDescription.displayName = 'AlertDescription';\n\nexport { Alert, AlertTitle, AlertDescription };\n","import React from 'react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Card = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nCard.displayName = 'Card';\n\nconst CardHeader = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nCardHeader.displayName = 'CardHeader';\n\nconst CardTitle = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n {/* added because of https://github.com/jsx-eslint/eslint-plugin-jsx-a11y/blob/main/docs/rules/heading-has-content.md */}\n {props.children}\n \n ),\n);\nCardTitle.displayName = 'CardTitle';\n\nconst CardDescription = React.forwardRef<\n HTMLParagraphElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n

    \n));\nCardDescription.displayName = 'CardDescription';\n\nconst CardContent = React.forwardRef>(\n ({ className, ...props }, ref) => (\n

    \n ),\n);\nCardContent.displayName = 'CardContent';\n\nconst CardFooter = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nCardFooter.displayName = 'CardFooter';\n\nexport { Card, CardHeader, CardFooter, CardTitle, CardDescription, CardContent };\n","import { ComponentProps } from 'react';\nimport { toast as sonner, Toaster } from 'sonner';\n\ntype SonnerProps = ComponentProps;\n\nfunction Sonner({ ...props }: SonnerProps) {\n return (\n \n );\n}\n\n// The re-export of the sonner function was added manually\nexport { Sonner, sonner };\n","import React from 'react';\nimport * as SliderPrimitive from '@radix-ui/react-slider';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Slider = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n \n \n \n));\nSlider.displayName = SliderPrimitive.Root.displayName;\n\nexport { Slider };\n","import React from 'react';\nimport * as SwitchPrimitives from '@radix-ui/react-switch';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Switch = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n));\nSwitch.displayName = SwitchPrimitives.Root.displayName;\n\nexport { Switch };\n","import React from 'react';\nimport * as TabsPrimitive from '@radix-ui/react-tabs';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport const Tabs = TabsPrimitive.Root;\n\nexport type TabsListProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport type TabsTriggerProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport type TabsContentProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport const TabsList = React.forwardRef<\n React.ElementRef,\n TabsListProps\n>(({ className, ...props }, ref) => (\n \n));\nTabsList.displayName = TabsPrimitive.List.displayName;\n\nexport const TabsTrigger = React.forwardRef<\n React.ElementRef,\n TabsTriggerProps\n>(({ className, ...props }, ref) => (\n \n));\nTabsTrigger.displayName = TabsPrimitive.Trigger.displayName;\n\nexport const TabsContent = React.forwardRef<\n React.ElementRef,\n TabsContentProps\n>(({ className, ...props }, ref) => (\n \n));\nTabsContent.displayName = TabsPrimitive.Content.displayName;\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Download } from 'lucide-react';\n\ntype InstallButtonProps = {\n /** The installing boolean value determines the state of the button. */\n isInstalling: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n /** Optional text for the button. */\n buttonText?: string;\n} & ButtonProps;\n\n/**\n * The InstallButton component is a button designed for initiating installs. It includes visuals for\n * active installing and idle states.\n *\n * @param isInstalling The installing boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @param buttonText Optional text for the button.\n * @returns A install button.\n */\nexport default function InstallButton({\n isInstalling,\n handleClick,\n buttonText,\n className,\n ...props\n}: InstallButtonProps) {\n return (\n \n {isInstalling ? (\n \n ) : (\n <>\n \n {buttonText}\n \n )}\n \n );\n}\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\n\ntype EnableButtonProps = {\n /** The enabling boolean value determines the state of the button. */\n isEnabling: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n} & ButtonProps;\n\n/**\n * The EnableButton component is a button designed for initiating enabling of downloads. It includes\n * visuals for active enabling and idle states.\n *\n * @param isEnabling The enabling boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @returns A button that can be used to enable.\n */\nexport default function EnableButton({\n isEnabling,\n handleClick,\n className,\n ...props\n}: EnableButtonProps) {\n return (\n \n {isEnabling ? (\n <>\n \n Enabling...\n \n ) : (\n 'Enable'\n )}\n \n );\n}\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\n\ntype DisableButtonProps = {\n /** The disabling boolean value determines the state of the button. */\n isDisabling: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n} & ButtonProps;\n\n/**\n * The DisableButton component is a button designed for initiating disabling of downloads. It\n * includes visuals for active disabling and idle states.\n *\n * @param isDisabling The disabling boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @returns A button that can be used to disable.\n */\nexport default function DisableButton({\n isDisabling,\n handleClick,\n className,\n ...props\n}: DisableButtonProps) {\n return (\n \n {isDisabling ? (\n <>\n \n Disabling...\n \n ) : (\n 'Disable'\n )}\n \n );\n}\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\n\ntype UpdateButtonProps = {\n /** The updating boolean value determines the state of the button. */\n isUpdating: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n} & ButtonProps;\n\n/**\n * The UpdateButton component is a button designed for initiating updates for downloaded extensions.\n * It includes visuals for active updating and idle states.\n *\n * @param isUpdating The updating boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @returns A button that can be used to update.\n */\nexport default function UpdateButton({\n isUpdating,\n handleClick,\n className,\n ...props\n}: UpdateButtonProps) {\n return (\n \n {isUpdating ? (\n <>\n \n Updating...\n \n ) : (\n 'Update'\n )}\n \n );\n}\n","import { cn } from '@/utils/shadcn-ui.util';\nimport Markdown, { MarkdownToJSX } from 'markdown-to-jsx';\nimport { useMemo } from 'react';\n\ninterface MarkdownRendererProps {\n /** Optional unique identifier */\n id?: string;\n /** The markdown string to render */\n markdown: string;\n className?: string;\n /**\n * The [`target` attribute for `a` html\n * tags](https://developer.mozilla.org/en-US/docs/Web/HTML/Element/a#target). Defaults to not\n * adding a `target` to `a` tags\n */\n anchorTarget?: string;\n}\n\n/**\n * This component renders markdown content given a markdown string. It uses typography styles from\n * the platform.\n *\n * @param markdown The markdown string to render.\n * @param id Optional unique identifier\n * @returns A div containing the rendered markdown content.\n */\nexport default function MarkdownRenderer({\n id,\n markdown,\n className,\n anchorTarget,\n}: MarkdownRendererProps) {\n const options: MarkdownToJSX.Options = useMemo(\n () => ({\n overrides: {\n a: {\n props: {\n target: anchorTarget,\n },\n },\n },\n }),\n [anchorTarget],\n );\n return (\n
    \n {markdown}\n
    \n );\n}\n","import { Filter, ChevronDown } from 'lucide-react';\nimport { forwardRef } from 'react';\nimport { Button } from '@/components/shadcn-ui/button';\n\n/**\n * The FilterButton component is a button designed for initiating filtering of data. It is designed\n * to be used with the dropdown menu. It uses forwardRef to pass the button to the dropdown trigger\n * asChild.\n *\n * @returns A button that can be used to filter.\n */\nconst FilterButton = forwardRef((props, ref) => {\n return (\n \n \n Filter\n \n \n );\n});\n\nexport default FilterButton;\n","import {\n DropdownMenu,\n DropdownMenuTrigger,\n DropdownMenuContent,\n DropdownMenuLabel,\n DropdownMenuGroup,\n DropdownMenuCheckboxItem,\n DropdownMenuRadioItem,\n DropdownMenuSeparator,\n} from '@/components/shadcn-ui/dropdown-menu';\nimport FilterButton from './buttons/filter-button.component';\n\nexport enum DropdownMenuItemType {\n Check,\n Radio,\n}\n\nexport type DropdownItem = {\n /** The label is the text that will be displayed on the dropdown item. */\n label: string;\n /** The itemType determines the DropdownMenuItemType type as either Check or Radio. */\n itemType: DropdownMenuItemType;\n /** The onClick function is called when the item is clicked. */\n onClick: () => void;\n};\n\nexport type DropdownGroup = {\n /**\n * The label is the text that will be displayed on the dropdown group. It is used to categorize\n * the items in the group.\n */\n label: string;\n /** The items array contains the items that will be displayed in the dropdown group */\n items: DropdownItem[];\n};\n\nexport type FilterDropdownProps = {\n /** Object unique identifier */\n id?: string;\n /** The groups array contains the groups that will be displayed in the dropdown */\n groups: DropdownGroup[];\n}; // TODO: extend the props later\n\n/**\n * The FilterDropdown component is a dropdown designed for filtering content. It includes groups of\n * items that can be checkboxes or radio items.\n *\n * @param id Optional unique identifier\n * @param groups The groups array contains the groups that will be displayed in the dropdown\n * @returns A filter dropdown.\n */\nexport default function FilterDropdown({ id, groups }: FilterDropdownProps) {\n return (\n
    \n {/* TODO: remove this once the DropDown Menu shadcn has an id prop */}\n \n \n \n \n \n {groups.map((group) => (\n
    \n {group.label}\n \n {group.items.map((item) => (\n
    \n {item.itemType === DropdownMenuItemType.Check ? (\n \n {item.label}\n \n ) : (\n \n {item.label}\n \n )}\n
    \n ))}\n
    \n \n
    \n ))}\n
    \n
    \n
    \n );\n}\n","interface NoExtensionsFoundProps {\n /** Optional unique identifier */\n id?: string;\n /** The message to display */\n message: string;\n}\n/**\n * This component displays a message to the user when no extensions are found in the marketplace.\n *\n * @param id Optional unique identifier\n * @param message The message to display.\n * @returns {JSX.Element} - Returns the message component that displays the message to the user.\n */\nexport default function NoExtensionsFound({ id, message }: NoExtensionsFoundProps) {\n return (\n
    \n
    \n

    {message}

    \n
    \n
    \n );\n}\n","import { CircleHelp, Link as LucideLink, User } from 'lucide-react';\nimport { NumberFormat } from 'platform-bible-utils';\n\n/** Interface that stores the parameters passed to the More Info component */\ninterface MoreInfoProps {\n /** Optional unique identifier */\n id?: string;\n /** The category of the extension */\n category: string;\n /** The number of downloads for the extension */\n downloads: Record;\n /** The languages supported by the extension */\n languages: string[];\n /** The URL to the more info page of the extension */\n moreInfoUrl: string;\n}\n/**\n * This component displays the more info section of the extension which includes the category,\n * number of downloads, languages, and links to the website and support\n *\n * @param id Optional unique identifier\n * @param category The category of the extension\n * @param downloads The number of downloads for the extension\n * @param languages The languages supported by the extension\n * @param moreInfoUrl The URL to the more info page of the extension\n * @returns {JSX.Element} - Returns the more info component that displays the category, number of\n * downloads, languages, and links to the website and support\n */\nexport default function MoreInfo({\n id,\n category,\n downloads,\n languages,\n moreInfoUrl,\n}: MoreInfoProps) {\n /**\n * This constant formats the number of downloads into a more readable format.\n *\n * @example 1000 -> 1K\n *\n * @example 1000000 -> 1M\n *\n * @returns The formatted number of downloads\n */\n const numberFormatted = new NumberFormat('en', {\n notation: 'compact',\n compactDisplay: 'short',\n }).format(Object.values(downloads).reduce((a: number, b: number) => a + b, 0));\n\n /** This function scrolls the window to the bottom of the page. */\n const handleScrollToBottom = () => {\n window.scrollTo(0, document.body.scrollHeight);\n };\n\n return (\n \n
    \n
    \n {category}\n
    \n CATEGORY\n
    \n
    \n
    \n
    \n \n {numberFormatted}\n
    \n USERS\n
    \n
    \n
    \n
    \n {languages.slice(0, 3).map((locale) => (\n \n {locale.toUpperCase()}\n \n ))}\n
    \n {languages.length > 3 && (\n handleScrollToBottom()}\n className=\"tw-text-xs tw-text-gray-500 tw-underline\"\n >\n +{languages.length - 3} more languages\n \n )}\n
    \n
    \n
    \n \n Website\n \n \n \n Support\n \n \n
    \n
    \n );\n}\n","import { useState } from 'react';\n\nexport type VersionInformation = {\n /** Date the version was published */\n date: string;\n /** Description of the changes in the version */\n description: string;\n};\n\n/** Type to store the version history information */\nexport type VersionHistoryType = Record;\n\n/** Interface that stores the parameters passed to the Version History component */\ninterface VersionHistoryProps {\n /** Optional unique identifier */\n id?: string;\n /** Object containing the versions mapped with their information */\n versionHistory: VersionHistoryType;\n}\n\n/**\n * Component to render the version history information shown in the footer component. Lists the 5\n * most recent versions, with the options to show all versions by pressing a button.\n *\n * @param versionHistory Object containing the versions mapped with their information\n * @param id Optional unique identifier\n * @returns Rendered version history for the Footer component\n */\nexport default function VersionHistory({ id, versionHistory }: VersionHistoryProps) {\n const [showAllVersions, setShowAllVersions] = useState(false);\n const currentDate = new Date();\n\n /**\n * Function to format the time string for the version history in the form of 'X year(s) ago'.\n *\n * @param dateString ISO Date string to determine the time string from\n * @returns Formatted time string\n */\n function formatTimeString(dateString: string) {\n const date = new Date(dateString);\n const dateDiff = new Date(currentDate.getTime() - date.getTime());\n const yearDiff = dateDiff.getUTCFullYear() - 1970;\n const monthDiff = dateDiff.getUTCMonth();\n const dayDiff = dateDiff.getUTCDate() - 1;\n\n // Determines how long ago the version was published\n let timeString = '';\n if (yearDiff > 0) {\n timeString = `${yearDiff.toString()} year${yearDiff === 1 ? '' : 's'} ago`;\n } else if (monthDiff > 0) {\n timeString = `${monthDiff.toString()} month${monthDiff === 1 ? '' : 's'} ago`;\n } else if (dayDiff === 0) {\n timeString = 'today';\n } else {\n timeString = `${dayDiff.toString()} day${dayDiff === 1 ? '' : 's'} ago`;\n }\n\n return timeString;\n }\n\n // Sorts the version history by version number\n const sortedEntries = Object.entries(versionHistory).sort((a, b) => b[0].localeCompare(a[0]));\n\n return (\n
    \n

    What`s New

    \n
      \n {(showAllVersions ? sortedEntries : sortedEntries.slice(0, 5)).map((entry) => (\n
      \n
      \n
    • \n {entry[1].description}\n
    • \n
      \n
      \n
      Version {entry[0]}
      \n
      {formatTimeString(entry[1].date)}
      \n
      \n
      \n ))}\n
    \n {sortedEntries.length > 5 && (\n setShowAllVersions(!showAllVersions)}\n className=\"tw-text-xs tw-text-gray-500 tw-underline\"\n >\n {showAllVersions ? 'Show Less Version History' : 'Show All Version History'}\n \n )}\n
    \n );\n}\n","import { useMemo } from 'react';\nimport { formatBytes } from 'platform-bible-utils';\nimport VersionHistory, { VersionHistoryType } from './version-history.component';\n\n/** Interface to store the parameters passed to the Footer component */\ninterface FooterProps {\n /** Optional unique identifier */\n id?: string;\n /** Name of the publisher */\n publisherDisplayName: string;\n /** Size of the extension file in bytes */\n fileSize: number;\n /** List of language codes supported by the extension */\n locales: string[];\n /** Object containing the version history mapped with their information */\n versionHistory: VersionHistoryType;\n}\n\n/**\n * Component to render the footer for the extension details which contains information on the\n * publisher, version history, languages, and file size.\n *\n * @param id Optional unique identifier\n * @param publisherDisplayName Name of the publisher\n * @param fileSize Size of the extension file in bytes\n * @param locales List of language codes supported by the extension\n * @param versionHistory Object containing the version history mapped with their information\n * @returns The rendered Footer component\n */\nexport default function Footer({\n id,\n publisherDisplayName,\n fileSize,\n locales,\n versionHistory,\n}: FooterProps) {\n /** Formats the file size into a human-readable format */\n const formattedFileSize = useMemo(() => formatBytes(fileSize), [fileSize]);\n\n /**\n * This function gets the display names of the languages based on the language codes.\n *\n * @param codes The list of language codes\n * @returns The list of language names\n */\n const getLanguageNames = (codes: string[]) => {\n const displayNames = new Intl.DisplayNames(navigator.language, { type: 'language' });\n return codes.map((code) => displayNames.of(code));\n };\n\n const languageNames = getLanguageNames(locales);\n\n return (\n
    \n
    \n \n
    \n
    \n

    Information

    \n
    \n

    \n Publisher\n {publisherDisplayName}\n Size\n {formattedFileSize}\n

    \n
    \n

    \n Languages\n {languageNames.join(', ')}\n

    \n
    \n
    \n
    \n
    \n
    \n );\n}\n","import { PlatformEvent, PlatformEventHandler } from 'platform-bible-utils';\nimport { useEffect } from 'react';\n\n/**\n * Adds an event handler to an event so the event handler runs when the event is emitted. Use\n * `papi.network.getNetworkEvent` to use a networked event with this hook.\n *\n * @param event The event to subscribe to.\n *\n * - If event is a `PlatformEvent`, that event will be used\n * - If event is undefined, the callback will not be subscribed. Useful if the event is not yet\n * available for example\n *\n * @param eventHandler The callback to run when the event is emitted\n *\n * WARNING: MUST BE STABLE - const or wrapped in useCallback. The reference must not be updated\n * every render\n */\nconst useEvent = (\n event: PlatformEvent | undefined,\n eventHandler: PlatformEventHandler,\n) => {\n useEffect(() => {\n // Do nothing if the event is not provided (in case the event is not yet available, for example)\n if (!event) return () => {};\n\n const unsubscriber = event(eventHandler);\n return () => {\n unsubscriber();\n };\n }, [event, eventHandler]);\n};\nexport default useEvent;\n","import { useCallback, useEffect } from 'react';\nimport { PlatformEvent, PlatformEventAsync, PlatformEventHandler } from 'platform-bible-utils';\nimport usePromise from './use-promise.hook';\n\nconst noopUnsubscriber = () => false;\n\n/**\n * Adds an event handler to an asynchronously subscribing/unsubscribing event so the event handler\n * runs when the event is emitted. Use `papi.network.getNetworkEvent` to use a networked event with\n * this hook.\n *\n * @param event The asynchronously (un)subscribing event to subscribe to.\n *\n * - If event is a `PlatformEvent` or `PlatformEventAsync`, that event will be used\n * - If event is undefined, the callback will not be subscribed. Useful if the event is not yet\n * available for example\n *\n * @param eventHandler The callback to run when the event is emitted\n *\n * WARNING: MUST BE STABLE - const or wrapped in useCallback. The reference must not be updated\n * every render\n */\nconst useEventAsync = (\n event: PlatformEvent | PlatformEventAsync | undefined,\n eventHandler: PlatformEventHandler,\n) => {\n // Subscribe to the event asynchronously\n const [unsubscribe] = usePromise(\n useCallback(async () => {\n // Do nothing if the event is not provided (in case the event is not yet available, for example)\n if (!event) return noopUnsubscriber;\n\n // Wrap subscribe and unsubscribe in promises to allow normal events to be used as well\n const unsub = await Promise.resolve(event(eventHandler));\n return async () => unsub();\n }, [eventHandler, event]),\n noopUnsubscriber,\n // We want the unsubscriber to return to default value immediately upon changing subscription\n // So the useEffect below will unsubscribe asap\n { preserveValue: false },\n );\n\n // Unsubscribe from the event asynchronously (but we aren't awaiting the unsub)\n useEffect(() => {\n return () => {\n if (unsubscribe !== noopUnsubscriber) {\n unsubscribe();\n }\n };\n }, [unsubscribe]);\n};\n\nexport default useEventAsync;\n"],"names":["twMergeCustom","extendTailwindMerge","cn","inputs","clsx","Input","React","className","type","props","ref","jsx","BookChapterInput","forwardRef","handleSearch","handleKeyDown","handleOnClick","handleSubmit","jsxs","ShadInput","event","e","History","P","R","t","s","n","N","B","O","S","K","g","k","x","T","X","V","w","L","G","A","H","C","I","y","q","U","m","l","h","c","E","D","i","a","o","u","v","f","d","b","p","J","DropdownMenu","DropdownMenuPrimitive","DropdownMenuTrigger","DropdownMenuGroup","DropdownMenuPortal","DropdownMenuSub","DropdownMenuRadioGroup","DropdownMenuSubTrigger","inset","children","ChevronRight","DropdownMenuSubContent","DropdownMenuContent","sideOffset","DropdownMenuItem","DropdownMenuCheckboxItem","checked","Check","DropdownMenuRadioItem","Circle","DropdownMenuLabel","DropdownMenuSeparator","DropdownMenuShortcut","BookMenuItem","bookId","handleSelectBook","isSelected","handleHighlightBook","bookType","ShadDropdownMenuItem","Canon","ChapterSelect","handleSelectChapter","endChapter","activeChapter","highlightedChapter","handleHighlightedChapter","chapters","_","handleMouse","useCallback","chapterNumber","chapter","GoToMenuItem","handleSort","handleLocationHistory","handleBookmarks","ShadDropdownMenuLabel","ArrowDownWideNarrow","Clock","Bookmark","ALL_BOOK_IDS","BOOK_TYPE_LABELS","BOOK_TYPE_ARRAY","SCROLL_OFFSET","SEARCH_QUERY_FORMATS","fetchGroupedBooks","fetchEndChapter","getChaptersForBook","getAllEnglishNames","isValidBookEnglishName","bookName","getBookIdFromEnglishName","formattedBookName","BookChapterControl","scrRef","searchQuery","setSearchQuery","useState","selectedBookId","setSelectedBookId","setHighlightedChapter","highlightedBookId","setHighlightedBookId","isContentOpen","setIsContentOpen","isContentOpenDelayed","setIsContentOpenDelayed","inputRef","useRef","contentRef","menuItemRef","fetchFilteredBooks","englishNameLowerCase","normalizedQuery","handleSearchInput","searchString","shouldPreventAutoClosing","controlMenuState","open","updateReference","shouldClose","verse","handleInputSubmit","format","matches","book","englishName","handleKeyDownInput","handleKeyDownContent","key","handleKeyDownMenuItem","chapterOffSet","useEffect","useLayoutEffect","scrollTimeout","scrollPosition","ShadDropdownMenu","ShadDropdownMenuTrigger","ShadDropdownMenuContent","bookTypeIndex","element","ShadDropdownMenuSeparator","buttonVariants","cva","Button","variant","size","asChild","Comp","Slot","labelVariants","Label","LabelPrimitive","RadioGroup","RadioGroupPrimitive","RadioGroupItem","Popover","PopoverPrimitive","PopoverTrigger","PopoverContent","align","DialogPortal","DialogPrimitive","DialogOverlay","DialogContent","DialogTitle","DialogDescription","Command","CommandPrimitive","CommandInput","Search","CommandList","CommandEmpty","CommandGroup","CommandSeparator","CommandItem","getOptionLabelDefault","option","ComboBox","id","options","buttonClassName","popoverContentClassName","value","onChange","getOptionLabel","buttonPlaceholder","textPlaceholder","commandEmptyMessage","buttonVariant","dir","isDisabled","setOpen","ChevronsUpDown","ChapterRangeSelector","startChapter","handleSelectStartChapter","handleSelectEndChapter","chapterCount","chapterOptions","useMemo","index","onChangeStartChapter","onChangeEndChapter","Fragment","BookSelectionMode","BOOK_SELECTOR_STRING_KEYS","localizeString","strings","BookSelector","handleBookSelectionModeChange","currentBookName","onSelectBooks","selectedBookIds","localizedStrings","currentBookText","chooseText","chooseBooksText","bookSelectionMode","setBookSelectionMode","onSelectionModeChange","newMode","DataTableViewOptions","table","FilterIcon","column","Select","SelectPrimitive","SelectGroup","SelectValue","SelectTrigger","ChevronDown","SelectScrollUpButton","ChevronUp","SelectScrollDownButton","SelectContent","position","SelectLabel","SelectItem","SelectSeparator","DataTablePagination","pageSize","ArrowLeftIcon","ChevronLeftIcon","ChevronRightIcon","ArrowRightIcon","Table","stickyHeader","TableHeader","TableBody","TableFooter","TableRow","TableHead","TableCell","TableCaption","DataTable","columns","data","enablePagination","showPaginationControls","showColumnVisibilityControls","onRowClickHandler","sorting","setSorting","columnFilters","setColumnFilters","columnVisibility","setColumnVisibility","rowSelection","setRowSelection","useReactTable","getCoreRowModel","getPaginationRowModel","getSortedRowModel","getFilteredRowModel","headerGroup","header","flexRender","_a","row","cell","OccurrencesTable","occurrenceData","setScriptureReference","referenceHeaderText","occurrenceHeaderText","occurrences","uniqueOccurrences","occurrence","uniqueOccurrence","deepEqual","Checkbox","CheckboxPrimitive","getLinesFromUSFM","text","getNumberFromUSFM","regex","match","getBookNumFromId","getStatusForItem","item","approvedItems","unapprovedItems","toggleVariants","Toggle","TogglePrimitive","ToggleGroupContext","ToggleGroup","ToggleGroupPrimitive","ToggleGroupItem","context","getSortingIcon","sortDirection","ArrowUpIcon","ArrowDownIcon","ArrowUpDownIcon","inventoryItemColumn","itemLabel","inventoryAdditionalItemColumn","additionalItemLabel","additionalItemIndex","inventoryCountColumn","countLabel","statusChangeHandler","changedItems","newStatus","onApprovedItemsChange","onUnapprovedItemsChange","newApprovedItems","validItem","newUnapprovedItems","unapprovedItem","inventoryStatusColumn","statusLabel","status","CircleCheckIcon","CircleXIcon","CircleHelpIcon","INVENTORY_STRING_KEYS","filterItemData","itemData","statusFilter","textFilter","filteredItemData","createTableData","scriptureRef","itemRegex","tableData","currentBook","currentChapter","currentVerse","line","items","itemIndex","existingItem","tableEntry","newReference","substring","newItem","Inventory","scriptureReference","extractItems","additionalItemsLabels","scope","onScopeChange","allItemsText","approvedItemsText","unapprovedItemsText","unknownItemsText","scopeBookText","scopeChapterText","scopeVerseText","filterText","showAdditionalItemsText","showAdditionalItems","setShowAdditionalItems","setStatusFilter","setTextFilter","selectedItem","setSelectedItem","reducedTableData","newTableData","firstItem","existingEntry","newTableEntry","filteredTableData","allColumns","numberOfAdditionalItems","additionalColumns","_b","rowClickHandler","newSelection","handleScopeChange","handleStatusFilterChange","SearchBar","onSearch","placeholder","isFullWidth","handleInputChange","VerticalTabs","TabsPrimitive","VerticalTabsList","VerticalTabsTrigger","VerticalTabsContent","TabNavigationContentSearch","tabList","searchPlaceholder","headerTitle","isSearchBarFullWidth","direction","tab","Separator","orientation","decorative","SeparatorPrimitive","Skeleton","TooltipProvider","TooltipPrimitive","Tooltip","TooltipTrigger","TooltipContent","SIDEBAR_WIDTH","SIDEBAR_WIDTH_ICON","SidebarContext","useSidebar","SidebarProvider","defaultOpen","openProp","setOpenProp","style","_open","_setOpen","isOpen","openState","toggleSidebar","state","contextValue","Sidebar","side","collapsible","SidebarTrigger","onClick","PanelLeft","SidebarRail","SidebarInset","SidebarInput","SidebarHeader","SidebarFooter","SidebarSeparator","SidebarContent","SidebarGroup","SidebarGroupLabel","SidebarGroupAction","SidebarGroupContent","SidebarMenu","SidebarMenuItem","sidebarMenuButtonVariants","SidebarMenuButton","isActive","tooltip","button","SidebarMenuAction","showOnHover","SidebarMenuBadge","SidebarMenuSkeleton","showIcon","width","SidebarMenuSub","SidebarMenuSubItem","SidebarMenuSubButton","SettingsSidebar","extensionLabels","projectInfo","handleSelectSidebarItem","selectedSidebarItem","extensionsSidebarGroupLabel","projectsSidebarGroupLabel","buttonPlaceholderText","handleSelectItem","projectId","getProjectNameFromProjectId","project","info","getIsActive","label","selectedProjectName","SettingsSidebarContentSearch","scrBookColId","scrRefColId","typeColId","detailsColId","defaultScrRefColumnName","defaultScrBookGroupName","defaultTypeColumnName","defaultDetailsColumnName","getColumns","colInfo","showSourceColumn","showSrcCol","formatScrRef","compareScrRefs","toRefOrRange","scriptureSelection","offsetStart","offsetEnd","scrRefToBBBCCCVVV","getRowKey","ScriptureResultsViewer","sources","showColumnHeaders","scriptureReferenceColumnName","scriptureBookGroupName","typeColumnName","detailsColumnName","onRowSelected","grouping","setGrouping","scriptureResults","source","getExpandedRowModel","getGroupedRowModel","selectedRows","keys","selectedRow","scrBookGroupName","typeGroupName","groupingOptions","handleSelectChange","selectedGrouping","handleRowClick","getEvenOrOddBandingStyle","getIndent","groupingState","rowIndex","ChevronLeft","DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS","getLocalizeKeyForScrollGroupId","ScrollGroupSelector","availableScrollGroupIds","scrollGroupId","onChangeScrollGroupId","localizedStringsDefaulted","localizedStringKey","localizedStringValue","newScrollGroupString","scrollGroupOptionId","SettingsList","SettingsListItem","primary","secondary","isLoading","loadingMessage","SettingsListHeader","includeSeparator","Checklist","listItems","selectedListItems","handleSelectListItem","createLabel","_interopRequireDefault","obj","module","chainPropTypes","propType1","propType2","args","_extends","target","isPlainObject","prototype","deepClone","output","deepmerge","r","z","reactIs_production_min","hasSymbol","REACT_ELEMENT_TYPE","REACT_PORTAL_TYPE","REACT_FRAGMENT_TYPE","REACT_STRICT_MODE_TYPE","REACT_PROFILER_TYPE","REACT_PROVIDER_TYPE","REACT_CONTEXT_TYPE","REACT_ASYNC_MODE_TYPE","REACT_CONCURRENT_MODE_TYPE","REACT_FORWARD_REF_TYPE","REACT_SUSPENSE_TYPE","REACT_SUSPENSE_LIST_TYPE","REACT_MEMO_TYPE","REACT_LAZY_TYPE","REACT_BLOCK_TYPE","REACT_FUNDAMENTAL_TYPE","REACT_RESPONDER_TYPE","REACT_SCOPE_TYPE","isValidElementType","typeOf","object","$$typeof","$$typeofType","AsyncMode","ConcurrentMode","ContextConsumer","ContextProvider","Element","ForwardRef","Lazy","Memo","Portal","Profiler","StrictMode","Suspense","hasWarnedAboutDeprecatedIsAsyncMode","isAsyncMode","isConcurrentMode","isContextConsumer","isContextProvider","isElement","isForwardRef","isFragment","isLazy","isMemo","isPortal","isProfiler","isStrictMode","isSuspense","reactIs_development","reactIsModule","require$$0","require$$1","getOwnPropertySymbols","hasOwnProperty","propIsEnumerable","toObject","val","shouldUseNative","test1","test2","order2","test3","letter","objectAssign","from","to","symbols","ReactPropTypesSecret","ReactPropTypesSecret_1","has","printWarning","loggedTypeFailures","message","checkPropTypes","typeSpecs","values","location","componentName","getStack","typeSpecName","error","err","ex","stack","checkPropTypes_1","ReactIs","assign","require$$2","require$$3","require$$4","emptyFunctionThatReturnsNull","factoryWithTypeCheckers","isValidElement","throwOnDirectAccess","ITERATOR_SYMBOL","FAUX_ITERATOR_SYMBOL","getIteratorFn","maybeIterable","iteratorFn","ANONYMOUS","ReactPropTypes","createPrimitiveTypeChecker","createAnyTypeChecker","createArrayOfTypeChecker","createElementTypeChecker","createElementTypeTypeChecker","createInstanceTypeChecker","createNodeChecker","createObjectOfTypeChecker","createEnumTypeChecker","createUnionTypeChecker","createShapeTypeChecker","createStrictShapeTypeChecker","is","PropTypeError","createChainableTypeChecker","validate","manualPropTypeCallCache","manualPropTypeWarningCount","checkType","isRequired","propName","propFullName","secret","cacheKey","chainedCheckType","expectedType","propValue","propType","getPropType","preciseType","getPreciseType","typeChecker","expectedClass","expectedClassName","actualClassName","getClassName","expectedValues","valuesString","arrayOfTypeCheckers","checker","getPostfixForTypeWarning","expectedTypes","checkerResult","expectedTypesMessage","isNode","invalidValidatorError","shapeTypes","allKeys","iterator","step","entry","isSymbol","emptyFunction","emptyFunctionWithReset","factoryWithThrowingShims","shim","getShim","propTypesModule","isClassComponent","elementType","acceptingRef","safePropName","warningHint","elementAcceptingRef","PropTypes","elementAcceptingRef$1","specialProperty","exactProp","propTypes","unsupportedProps","prop","formatMuiErrorMessage","code","url","REACT_SERVER_CONTEXT_TYPE","REACT_OFFSCREEN_TYPE","enableScopeAPI","enableCacheElement","enableTransitionTracing","enableLegacyHidden","enableDebugTracing","REACT_MODULE_REFERENCE","SuspenseList","hasWarnedAboutDeprecatedIsConcurrentMode","isSuspenseList","fnNameMatchRegex","getFunctionName","fn","getFunctionComponentName","Component","fallback","getWrappedName","outerType","innerType","wrapperName","functionName","getDisplayName","HTMLElementType","refType","refType$1","capitalize","string","_formatMuiErrorMessage","createChainedFunction","funcs","acc","func","debounce","wait","timeout","debounced","later","deprecatedPropType","validator","reason","componentNameSafe","propFullNameSafe","isMuiElement","muiNames","_muiName","_element$type","ownerDocument","node","ownerWindow","requirePropFactory","componentNameInError","prevPropTypes","requiredProp","defaultTypeChecker","typeCheckerResult","setRef","useEnhancedEffect","useEnhancedEffect$1","globalId","useGlobalId","idOverride","defaultId","setDefaultId","maybeReactUseId","useId","reactId","unsupportedProp","useControlled","controlled","defaultProp","name","isControlled","valueState","setValue","defaultValue","setValueIfUncontrolled","newValue","useEventCallback","useForkRef","refs","instance","UNINITIALIZED","useLazyRef","init","initArg","EMPTY","useOnMount","Timeout","delay","useTimeout","hadKeyboardEvent","hadFocusVisibleRecently","hadFocusVisibleRecentlyTimeout","inputTypesWhitelist","focusTriggersKeyboardModality","tagName","handlePointerDown","handleVisibilityChange","prepare","doc","isFocusVisible","useIsFocusVisible","isFocusVisibleRef","handleBlurVisible","handleFocusVisible","resolveProps","defaultProps","defaultSlotProps","slotProps","slotPropName","composeClasses","slots","getUtilityClass","classes","slot","utilityClass","defaultGenerator","createClassNameGenerator","generate","generator","ClassNameGenerator","ClassNameGenerator$1","globalStateClasses","generateUtilityClass","globalStatePrefix","globalStateClass","generateUtilityClasses","result","clamp","min","max","_objectWithoutPropertiesLoose","excluded","sourceKeys","_excluded","sortBreakpointsValues","breakpointsAsArray","breakpoint1","breakpoint2","createBreakpoints","breakpoints","unit","other","sortedValues","up","down","between","start","end","endIndex","only","not","keyIndex","shape","shape$1","responsivePropType","responsivePropType$1","merge","defaultBreakpoints","handleBreakpoints","styleFromPropValue","theme","themeBreakpoints","breakpoint","mediaKey","cssKey","createEmptyBreakpointObject","breakpointsInput","_breakpointsInput$key","breakpointStyleKey","removeUnusedBreakpoints","breakpointKeys","breakpointOutput","getPath","path","checkVars","getStyleValue","themeMapping","transform","propValueFinal","userValue","cssProperty","themeKey","memoize","cache","arg","properties","directions","aliases","getCssProperties","property","marginKeys","paddingKeys","spacingKeys","createUnaryUnit","_getPath","themeSpacing","abs","createUnarySpacing","getValue","transformer","transformed","getStyleFromPropValue","cssProperties","resolveCssProperty","margin","padding","createSpacing","spacingInput","spacing","argsInput","argument","compose","styles","handlers","borderTransform","createBorderStyle","border","borderTop","borderRight","borderBottom","borderLeft","borderColor","borderTopColor","borderRightColor","borderBottomColor","borderLeftColor","outline","outlineColor","borderRadius","gap","columnGap","rowGap","gridColumn","gridRow","gridAutoFlow","gridAutoColumns","gridAutoRows","gridTemplateColumns","gridTemplateRows","gridTemplateAreas","gridArea","paletteTransform","color","bgcolor","backgroundColor","sizingTransform","maxWidth","_props$theme","_props$theme2","breakpointsValues","minWidth","height","maxHeight","minHeight","boxSizing","defaultSxConfig","defaultSxConfig$1","objectsHaveSameKeys","objects","union","callIfFn","maybeFn","unstable_createStyleFunctionSx","getThemeValue","config","styleFunctionSx","_theme$unstable_sxCon","sx","traverse","sxInput","sxObject","emptyBreakpoints","breakpointsKeys","css","styleKey","styleFunctionSx$1","applyStyles","createTheme","paletteInput","shapeInput","muiTheme","isObjectEmpty","useTheme","defaultTheme","contextTheme","ThemeContext","systemDefaultTheme","useThemeWithoutDefault","_excluded2","_excluded3","isEmpty","isStringTag","tag","shouldForwardProp","lowercaseFirstLetter","resolveTheme","themeId","defaultOverridesResolver","processStyleArg","callableStyle","_ref","ownerState","resolvedStylesArg","resolvedStyle","variants","isMatch","createStyled","input","rootShouldForwardProp","slotShouldForwardProp","systemSx","inputOptions","processStyles","componentSlot","inputSkipVariantsResolver","inputSkipSx","overridesResolver","skipVariantsResolver","skipSx","shouldForwardPropOption","defaultStyledResolver","styledEngineStyled","transformStyleArg","stylesArg","muiStyledResolver","styleArg","expressions","transformedStyleArg","expressionsWithDefaultTheme","styleOverrides","resolvedStyleOverrides","slotKey","slotStyle","_theme$components","themeVariants","numOfCustomFnsApplied","placeholders","displayName","getThemeProps","params","useThemeProps","clampWrapper","hexToRgb","re","colors","decomposeColor","marker","colorSpace","recomposeColor","hslToRgb","rgb","getLuminance","getContrastRatio","foreground","background","lumA","lumB","alpha","darken","coefficient","lighten","createMixins","mixins","common","common$1","grey","grey$1","purple","purple$1","red","red$1","orange","orange$1","blue","blue$1","lightBlue","lightBlue$1","green","green$1","light","dark","addLightOrDark","intent","shade","tonalOffset","tonalOffsetLight","tonalOffsetDark","getDefaultPrimary","mode","getDefaultSecondary","getDefaultError","getDefaultInfo","getDefaultSuccess","getDefaultWarning","createPalette","palette","contrastThreshold","success","warning","getContrastText","contrastText","contrast","augmentColor","mainShade","lightShade","darkShade","modes","round","caseAllCaps","defaultFontFamily","createTypography","typography","fontFamily","fontSize","fontWeightLight","fontWeightRegular","fontWeightMedium","fontWeightBold","htmlFontSize","allVariants","pxToRem2","coef","pxToRem","buildVariant","fontWeight","lineHeight","letterSpacing","casing","shadowKeyUmbraOpacity","shadowKeyPenumbraOpacity","shadowAmbientShadowOpacity","createShadow","px","shadows","shadows$1","easing","duration","formatMs","milliseconds","getAutoHeightDuration","constant","createTransitions","inputTransitions","mergedEasing","mergedDuration","durationOption","easingOption","isString","isNumber","animatedProp","zIndex","zIndex$1","mixinsInput","transitionsInput","typographyInput","systemTheme","systemCreateTheme","stateClasses","component","child","stateClass","defaultTheme$1","THEME_ID","systemUseThemeProps","styled","styled$1","getSvgIconUtilityClass","useUtilityClasses","SvgIconRoot","_theme$transitions","_theme$transitions$cr","_theme$transitions2","_theme$typography","_theme$typography$pxT","_theme$typography2","_theme$typography2$px","_theme$typography3","_theme$typography3$px","_palette$ownerState$c","_palette","_palette2","_palette3","SvgIcon","inProps","htmlColor","inheritViewBox","titleAccess","viewBox","hasSvgAsChild","more","_jsxs","_jsx","SvgIcon$1","createSvgIcon","unstable_ClassNameGenerator","exports","_utils","ArrowRight","default_1","_createSvgIcon","_jsxRuntime","isHostComponent","appendOwnerState","otherProps","defaultContextValue","ClassNameConfiguratorContext","useClassNamesOverride","disableDefaultClasses","extractEventHandlers","excludeKeys","resolveComponentProps","componentProps","slotState","omitEventHandlers","mergeSlotProps","parameters","getSlotProps","additionalProps","externalSlotProps","externalForwardedProps","joinedClasses","mergedStyle","eventHandlers","componentsPropsWithoutEventHandlers","otherPropsWithoutEventHandlers","internalSlotProps","useSlotProps","_parameters$additiona","skipResolvingSlotProps","rest","resolvedComponentsProps","mergedProps","internalRef","GLOBAL_CLASS_PREFIX","buildStateClass","buildSlotClass","getContainer","container","forwardedRef","disablePortal","mountNode","setMountNode","handleRef","newProps","ReactDOM","top","bottom","right","left","auto","basePlacements","clippingParents","viewport","popper","reference","variationPlacements","placement","placements","beforeRead","read","afterRead","beforeMain","main","afterMain","beforeWrite","write","afterWrite","modifierPhases","getNodeName","getWindow","OwnElement","isHTMLElement","isShadowRoot","attributes","effect","_ref2","initialStyles","styleProperties","attribute","applyStyles$1","getBasePlacement","getUAString","uaData","isLayoutViewport","getBoundingClientRect","includeScale","isFixedStrategy","clientRect","scaleX","scaleY","visualViewport","addVisualOffsets","getLayoutRect","contains","parent","rootNode","next","getComputedStyle","isTableElement","getDocumentElement","getParentNode","getTrueOffsetParent","getContainingBlock","isFirefox","isIE","elementCss","currentNode","getOffsetParent","window","offsetParent","getMainAxisFromPlacement","within","mathMax","mathMin","withinMaxClamp","getFreshSideObject","mergePaddingObject","paddingObject","expandToHashMap","hashMap","toPaddingObject","arrow","_state$modifiersData$","arrowElement","popperOffsets","basePlacement","axis","isVertical","len","arrowRect","minProp","maxProp","endDiff","startDiff","arrowOffsetParent","clientSize","centerToReference","center","offset","axisProp","_options$element","arrow$1","getVariation","unsetSides","roundOffsetsByDPR","win","dpr","mapToStyles","_Object$assign2","popperRect","variation","offsets","gpuAcceleration","adaptive","roundOffsets","isFixed","_offsets$x","_offsets$y","_ref3","hasX","hasY","sideX","sideY","heightProp","widthProp","offsetY","offsetX","commonStyles","_ref4","_Object$assign","computeStyles","_ref5","_options$gpuAccelerat","_options$adaptive","_options$roundOffsets","computeStyles$1","passive","_options$scroll","scroll","_options$resize","resize","scrollParents","scrollParent","eventListeners","hash","getOppositePlacement","matched","getOppositeVariationPlacement","getWindowScroll","scrollLeft","scrollTop","getWindowScrollBarX","getViewportRect","strategy","html","layoutViewport","getDocumentRect","_element$ownerDocumen","winScroll","body","isScrollParent","_getComputedStyle","overflow","overflowX","overflowY","getScrollParent","listScrollParents","list","isBody","updatedList","rectToClientRect","rect","getInnerBoundingClientRect","getClientRectFromMixedType","clippingParent","getClippingParents","canEscapeClipping","clipperElement","getClippingRect","boundary","rootBoundary","mainClippingParents","firstClippingParent","clippingRect","accRect","computeOffsets","commonX","commonY","mainAxis","detectOverflow","_options","_options$placement","_options$strategy","_options$boundary","_options$rootBoundary","_options$elementConte","elementContext","_options$altBoundary","altBoundary","_options$padding","altContext","clippingClientRect","referenceClientRect","popperClientRect","elementClientRect","overflowOffsets","offsetData","multiply","computeAutoPlacement","flipVariations","_options$allowedAutoP","allowedAutoPlacements","allPlacements","allowedPlacements","overflows","getExpandedFallbackPlacements","oppositePlacement","flip","_options$mainAxis","checkMainAxis","_options$altAxis","checkAltAxis","specifiedFallbackPlacements","_options$flipVariatio","preferredPlacement","isBasePlacement","fallbackPlacements","referenceRect","checksMap","makeFallbackChecks","firstFittingPlacement","_basePlacement","isStartVariation","mainVariationSide","altVariationSide","checks","check","numberOfChecks","_loop","_i","fittingPlacement","_ret","flip$1","getSideOffsets","preventedOffsets","isAnySideFullyClipped","hide","referenceOverflow","popperAltOverflow","referenceClippingOffsets","popperEscapeOffsets","isReferenceHidden","hasPopperEscaped","hide$1","distanceAndSkiddingToXY","rects","invertDistance","skidding","distance","_options$offset","_data$state$placement","offset$1","popperOffsets$1","getAltAxis","preventOverflow","_options$tether","tether","_options$tetherOffset","tetherOffset","altAxis","tetherOffsetValue","normalizedTetherOffsetValue","offsetModifierState","_offsetModifierState$","mainSide","altSide","additive","minLen","maxLen","arrowPaddingObject","arrowPaddingMin","arrowPaddingMax","arrowLen","minOffset","maxOffset","clientOffset","offsetModifierValue","tetherMin","tetherMax","preventedOffset","_offsetModifierState$2","_mainSide","_altSide","_offset","_len","_min","_max","isOriginSide","_offsetModifierValue","_tetherMin","_tetherMax","_preventedOffset","preventOverflow$1","getHTMLElementScroll","getNodeScroll","isElementScaled","getCompositeRect","elementOrVirtualElement","isOffsetParentAnElement","offsetParentIsScaled","documentElement","order","modifiers","map","visited","modifier","sort","requires","dep","depModifier","orderModifiers","orderedModifiers","phase","pending","resolve","mergeByName","merged","current","existing","DEFAULT_OPTIONS","areValidElements","_key","popperGenerator","generatorOptions","_generatorOptions","_generatorOptions$def","defaultModifiers","_generatorOptions$def2","defaultOptions","effectCleanupFns","isDestroyed","setOptionsAction","cleanupModifierEffects","runModifierEffects","_state$elements","_state$orderedModifie","_state$orderedModifie2","_ref$options","cleanupFn","noopFn","createPopper","COMPONENT_NAME","getPopperUtilityClass","flipPlacement","resolveAnchorEl","anchorEl","isVirtualElement","defaultPopperOptions","PopperTooltip","_slots$root","initialPlacement","popperOptions","popperRefProp","TransitionProps","tooltipRef","ownRef","popperRef","handlePopperRef","handlePopperRefRef","rtlPlacement","setPlacement","resolvedAnchorElement","setResolvedAnchorElement","handlePopperUpdate","box","popperModifiers","childProps","Root","rootProps","Popper","containerProp","keepMounted","transition","exited","setExited","handleEnter","handleExited","resolvedAnchorEl","display","transitionProps","useThemeSystem","_setPrototypeOf","_inheritsLoose","subClass","superClass","setPrototypeOf","timeoutsShape","TransitionGroupContext","forceReflow","UNMOUNTED","EXITED","ENTERING","ENTERED","EXITING","Transition","_React$Component","_this","parentGroup","appear","initialStatus","prevState","nextIn","_proto","prevProps","nextStatus","exit","enter","mounting","_this2","appearing","maybeNode","maybeAppearing","timeouts","enterTimeout","_this3","nextState","callback","_this4","active","handler","doesNotHaveTimeoutOrListener","maybeNextCallback","_this$props","pt","noop","Transition$1","reflow","getTransitionProps","_style$transitionDura","_style$transitionTimi","getScale","isWebKit154","Grow","addEndListener","inProp","onEnter","onEntered","onEntering","onExit","onExited","onExiting","TransitionComponent","timer","autoTimeout","nodeRef","normalizedTransitionCallback","maybeIsAppearing","handleEntering","isAppearing","transitionDuration","transitionTimingFunction","handleEntered","handleExiting","handleExit","handleAddEndListener","Grow$1","PopperRoot","BasePopper","components","componentsProps","RootComponent","Popper$1","getTooltipUtilityClass","tooltipClasses","tooltipClasses$1","disableInteractive","touch","TooltipPopper","TooltipTooltip","TooltipArrow","hystersisOpen","hystersisTimer","cursorPosition","composeEventHandler","eventHandler","_slots$popper","_slots$transition","_slots$tooltip","_slots$arrow","_slotProps$popper","_ref6","_slotProps$popper2","_slotProps$transition","_slotProps$tooltip","_ref7","_slotProps$tooltip2","_slotProps$arrow","_ref8","_slotProps$arrow2","childrenProp","describeChild","disableFocusListener","disableHoverListener","disableInteractiveProp","disableTouchListener","enterDelay","enterNextDelay","enterTouchDelay","followCursor","idProp","leaveDelay","leaveTouchDelay","onClose","onOpen","PopperComponentProp","PopperProps","title","TransitionComponentProp","isRtl","childNode","setChildNode","arrowRef","setArrowRef","ignoreNonTouchEvents","closeTimer","enterTimer","leaveTimer","touchTimer","setOpenState","prevUserSelect","stopTouchInteraction","handleOpen","handleClose","handleLeave","focusVisibleRef","setChildIsFocusVisible","handleBlur","handleFocus","detectTouchStart","childrenProps","handleMouseOver","handleMouseLeave","handleTouchStart","handleTouchEnd","nativeEvent","handleMouseMove","nameOrDescProps","titleIsString","interactiveWrapperListeners","_PopperProps$popperOp","tooltipModifiers","PopperComponent","TooltipComponent","ArrowComponent","popperProps","tooltipProps","tooltipArrowProps","TransitionPropsInner","Tooltip$1","getIcon","icon","menuLabel","leading","MuiListItemIcon","MenuItem","allowForLeadingIcons","iconPathBefore","iconPathAfter","hasAutoFocus","isDense","isSubMenuParent","hasDisabledGutters","hasDivider","focusVisibleClassName","menuItem","MuiMenuItem","MuiListItemText","getAllGroups","menuDefinition","SubMenu","setAnchorEl","parentMenuItem","parentItemProps","handleParentMenuItemClick","renderSubMenuItems","includedGroups","group","GroupedMenuItemList","Menu","getOrderedGroupItems","groupId","allItems","menuProps","commandHandler","groupsToInclude","sortedGroups","itemArray","allowSpaceForLeadingIcons","createMenuItemProps","isLastItemInGroup","divKey","itemInfo","menuItemProps","TopLevelMenu","columnId","MenuColumn","metadata","Grid","List","GridMenu","multiColumnMenu","sortedColumns","columnNumbers","columnName","col","getUsePromiseOptionsDefaults","usePromise","promiseFactoryCallback","defaultValueRef","optionsDefaultedRef","setIsLoading","promiseIsCurrent","MenuIcon","HamburgerMenuButton","menuProvider","normalMenu","fullMenu","containerRef","ariaLabelPrefix","isMenuOpen","setMenuOpen","showFullMenu","setShowFullMenu","handleMenuItemClick","handleMenuButtonClick","prevIsOpen","isOpening","menuCommandHandler","command","setOffset","normalMenuData","fullMenuData","menu","IconButton","Drawer","isTooltipSuppressed","adjustMarginToAlignToEdge","MuiIconButton","Spinner","LoaderCircle","TextField","hasError","helperText","onFocus","onBlur","ShadLabel","Toolbar","AppBar","MuiToolbar","alertVariants","Alert","AlertTitle","AlertDescription","Card","CardHeader","CardTitle","CardDescription","CardContent","CardFooter","Sonner","Toaster","Slider","SliderPrimitive","Switch","SwitchPrimitives","Tabs","TabsList","TabsTrigger","TabsContent","InstallButton","isInstalling","handleClick","buttonText","Download","EnableButton","isEnabling","DisableButton","isDisabling","UpdateButton","isUpdating","MarkdownRenderer","markdown","anchorTarget","Markdown","FilterButton","Filter","DropdownMenuItemType","DropdownMenuItemType2","FilterDropdown","groups","NoExtensionsFound","MoreInfo","category","downloads","languages","moreInfoUrl","numberFormatted","NumberFormat","handleScrollToBottom","User","locale","LucideLink","CircleHelp","VersionHistory","versionHistory","showAllVersions","setShowAllVersions","currentDate","formatTimeString","dateString","date","dateDiff","yearDiff","monthDiff","dayDiff","timeString","sortedEntries","Footer","publisherDisplayName","fileSize","locales","formattedFileSize","formatBytes","languageNames","codes","displayNames","useEvent","unsubscriber","noopUnsubscriber","useEventAsync","unsubscribe","unsub"],"mappings":"48CAGA,MAAMA,GAAgBC,GAAAA,oBAAoB,CAAE,OAAQ,KAAO,CAAA,EAyDpD,SAASC,KAAMC,EAAsB,CACnC,OAAAH,GAAcI,GAAAA,KAAKD,CAAM,CAAC,CACnC,CCzDO,MAAME,GAAQC,EAAM,WACzB,CAAC,CAAE,UAAAC,EAAW,KAAAC,EAAM,GAAGC,CAAA,EAASC,IAE5BC,EAAA,IAAC,QAAA,CACC,KAAAH,EACA,UAAWN,EACT,sbACAK,CACF,EACA,IAAAG,EAEC,GAAGD,CAAA,CAAA,CAIZ,EACAJ,GAAM,YAAc,QCNpB,MAAMO,GAAmBC,EAAA,WACvB,CACE,CAAE,aAAAC,EAAc,cAAAC,EAAe,cAAAC,EAAe,aAAAC,EAAc,GAAGR,CAAM,EACrEC,IAGEQ,EAAA,KAAC,MAAI,CAAA,UAAU,cACb,SAAA,CAAAP,EAAA,IAACQ,GAAA,CACE,GAAGV,EACJ,KAAK,OACL,UAAU,0JACV,SAAWW,GAAUN,EAAaM,EAAM,OAAO,KAAK,EACpD,UAAYC,GAAM,CACZA,EAAE,MAAQ,SACCJ,IAEfF,EAAcM,CAAC,CACjB,EACA,QAASL,EACT,IAAAN,CAAA,CACF,EACAC,EAAA,IAACW,GAAA,QAAA,CACC,UAAU,8HACV,QAAS,IAAM,CAEb,QAAQ,IAAI,iBAAiB,CAC/B,CAAA,CACF,CACF,CAAA,CAAA,CAGN,EC9CA,IAAIC,GAAI,OAAO,eACXC,GAAI,CAACC,EAAGJ,EAAGK,IAAML,KAAKI,EAAIF,GAAEE,EAAGJ,EAAG,CAAE,WAAY,GAAI,aAAc,GAAI,SAAU,GAAI,MAAOK,CAAC,CAAE,EAAID,EAAEJ,CAAC,EAAIK,EACzGC,GAAI,CAACF,EAAGJ,EAAGK,IAAMF,GAAEC,EAAG,OAAOJ,GAAK,SAAWA,EAAI,GAAKA,EAAGK,CAAC,EAW9D,MAAME,GAAI,CACR,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MAEA,MAEA,MAEA,MAEA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,MAEA,MAEA,MAEA,MAEA,MACA,MACA,MACA,MAEA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MAEA,MACA,MACA,KACF,EAAGC,GAAI,CACL,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,MACA,KACF,EAAGC,GAAI,CACL,UACA,SACA,YACA,UACA,cACA,SACA,SACA,OACA,WACA,WACA,UACA,UACA,eACA,eACA,OACA,WACA,kBACA,MACA,SACA,WACA,eACA,gBACA,SACA,WACA,eACA,UACA,kBACA,QACA,OACA,OACA,UACA,QACA,QACA,QACA,WACA,YACA,SACA,YACA,UACA,UACA,OACA,OACA,OACA,OACA,SACA,gBACA,gBACA,YACA,YACA,cACA,aACA,kBACA,kBACA,YACA,YACA,QACA,WACA,UACA,QACA,UACA,UACA,SACA,SACA,SACA,OACA,aACA,QACA,SACA,eACA,oBACA,0BACA,SACA,qBACA,sBACA,UACA,qBACA,cACA,cACA,cACA,cACA,mBACA,mBACA,qBACA,YACA,OAC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,EACD,aAAc,CACZ,SAAU,SACX,EACD,aAAc,CACZ,SAAU,qBACV,MAAOc,EACR,EAED,MAAO,CACL,SAAU,UACV,UAAWa,EACZ,EACD,QAAS,CACP,SAAU,UACV,YAAa,kBACb,UAAWA,EACZ,EACD,gBAAiB,CACf,SAAU,UACV,UAAWA,EACZ,EAED,EAAG,CACD,MAAOpC,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,QAAS,CACP,MAAOA,EACR,EACD,WAAY,CACV,MAAOA,EACR,EACD,aAAc,CACZ,MAAOA,EACR,EACD,cAAe,CACb,MAAOA,EACR,EACD,YAAa,CACX,MAAOA,EACR,EACD,SAAU,CACR,MAAOA,EACR,EACD,SAAU,CACR,MAAOA,EACR,EACD,cAAe,CACb,MAAOA,EACR,EACD,mBAAoB,CAClB,MAAOA,EACR,EACD,iBAAkB,CAChB,MAAOA,EACR,EACD,aAAc,CACZ,MAAOA,EACR,EACD,kBAAmB,CACjB,MAAOA,EACR,EACD,gBAAiB,CACf,MAAOA,EACR,EACD,EAAG,CACD,MAAOD,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,GAAI,CACF,MAAOA,EACR,EACD,OAAQ,CACN,MAAOA,EACR,EACD,UAAW,CACT,MAAOA,EACR,EACD,YAAa,CACX,MAAOA,EACR,EACD,aAAc,CACZ,MAAOA,EACR,EACD,WAAY,CACV,MAAOA,EACR,EACD,QAAS,CACP,MAAOA,EACR,EACD,QAAS,CACP,MAAOA,EACR,EACD,aAAc,CACZ,MAAOA,EACR,EACD,kBAAmB,CACjB,MAAOA,EACR,EACD,gBA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;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","x_google_ignoreList":[3,43,44,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,83,84,85,86,87,88,89,90,91,92,93,94,95,96,97,98,99,100,101,102,103,104,105,106,107,108,109,110,111,112,113,114,115,116,117,118,119,120,121,122,123,124,125,126,127,128,129,130,131,132,133,134,135,136,137,138,139,140,141,142,143,144,145,146,147,148,149,150,151,152,153,154,155,156,157,158,159,160,161,162,163,164,165,166,167,168,169,170,171,172,173,174,175,176,177,178,179,180,181,182,183,184,185,186,187,188,189,190,191,192,193,194,195,196,197,198,199,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,226]} \ No newline at end of file diff --git a/lib/platform-bible-react/dist/index.d.ts b/lib/platform-bible-react/dist/index.d.ts index 19ca97bb39..4373e3d79b 100644 --- a/lib/platform-bible-react/dist/index.d.ts +++ b/lib/platform-bible-react/dist/index.d.ts @@ -735,7 +735,7 @@ export type Direction = "ltr" | "rtl"; * Thanks to Shadcn for heavy inspiration and documentation * https://ui.shadcn.com/docs/components/combobox */ -export declare function ComboBox({ id, options, buttonClassName, popoverContentClassName, value, onChange, getOptionLabel, buttonPlaceholder, textPlaceholder, commandEmptyMessage, buttonVariant, dir, isDisabled, ...props }: ComboBoxProps): import("react/jsx-runtime").JSX.Element; +export declare function ComboBox({ id, options, className, buttonClassName, popoverContentClassName, value, onChange, getOptionLabel, buttonPlaceholder, textPlaceholder, commandEmptyMessage, buttonVariant, dir, isDisabled, ...props }: ComboBoxProps): import("react/jsx-runtime").JSX.Element; export type MenuItemInfoBase = { /** Text (displayable in the UI) as the name of the menu item */ label: string; diff --git a/lib/platform-bible-react/dist/index.js b/lib/platform-bible-react/dist/index.js index 3a424088ac..d21f9c1474 100644 --- a/lib/platform-bible-react/dist/index.js +++ b/lib/platform-bible-react/dist/index.js @@ -1095,41 +1095,41 @@ function oh({ scrRef: t, handleSubmit: e }) { ot.bookNumberToId(t.bookNum) ), [i, l] = ut(t.chapterNum ?? 0), [c, d] = ut( ot.bookNumberToId(t.bookNum) - ), [p, f] = ut(!1), [w, g] = ut(p), v = ge(void 0), m = ge(void 0), h = ge(void 0), S = kt( - (k) => fc(k).filter((j) => { + ), [p, f] = ut(!1), [w, g] = ut(p), v = ge(void 0), m = ge(void 0), h = ge(void 0), k = kt( + (E) => fc(E).filter((j) => { const M = ot.bookIdToEnglishName(j).toLowerCase(), J = n.replace(/[^a-zA-Z]/g, "").toLowerCase(); return M.includes(J) || // Match book name j.toLowerCase().includes(J); }), [n] - ), A = (k) => { - r(k); - }, R = ge(!1), E = kt((k) => { + ), A = (E) => { + r(E); + }, R = ge(!1), S = kt((E) => { if (R.current) { R.current = !1; return; } - f(k); + f(E); }, []), b = kt( - (k, j, M, J) => { + (E, j, M, J) => { if (l( - ot.bookNumberToId(t.bookNum) !== k ? 1 : t.chapterNum - ), j || tn(k) === -1) { + ot.bookNumberToId(t.bookNum) !== E ? 1 : t.chapterNum + ), j || tn(E) === -1) { e({ - bookNum: ot.bookIdToNumber(k), + bookNum: ot.bookIdToNumber(E), chapterNum: M || 1, verseNum: J || 1 }), f(!1), r(""); return; } - a(o !== k ? k : ""), f(!j); + a(o !== E ? E : ""), f(!j); }, [e, t.bookNum, t.chapterNum, o] - ), $ = (k) => { - k <= 0 || k > tn(o) || b(o, !0, k); + ), $ = (E) => { + E <= 0 || E > tn(o) || b(o, !0, E); }, z = kt(() => { - wc.forEach((k) => { - const j = n.match(k); + wc.forEach((E) => { + const j = n.match(E); if (j) { const [M, J = void 0, q = void 0] = j.slice(1), U = gc(M); (ot.isBookIdValid(M) || U) && b( @@ -1141,22 +1141,22 @@ function oh({ scrRef: t, handleSubmit: e }) { } }); }, [b, n]), H = kt( - (k) => { - p ? (k.key === "ArrowDown" || k.key === "ArrowUp") && (typeof h < "u" && // Ref uses null + (E) => { + p ? (E.key === "ArrowDown" || E.key === "ArrowUp") && (typeof h < "u" && // Ref uses null // eslint-disable-next-line no-null/no-null h.current !== null ? h.current.focus() : typeof m < "u" && // Ref uses null // eslint-disable-next-line no-null/no-null - m.current !== null && m.current.focus(), k.preventDefault()) : f(!0); + m.current !== null && m.current.focus(), E.preventDefault()) : f(!0); }, [p] - ), C = (k) => { - const { key: j } = k; + ), C = (E) => { + const { key: j } = E; j === "ArrowRight" || j === "ArrowLeft" || j === "ArrowDown" || j === "ArrowUp" || j === "Enter" || (v.current.dispatchEvent(new KeyboardEvent("keydown", { key: j })), v.current.focus()); - }, P = (k) => { - const { key: j } = k; + }, P = (E) => { + const { key: j } = E; if (c === o) { if (j === "Enter") { - k.preventDefault(), b(o, !0, i); + E.preventDefault(), b(o, !0, i); return; } let M = 0; @@ -1164,19 +1164,19 @@ function oh({ scrRef: t, handleSubmit: e }) { if (i < tn(c)) M = 1; else { - k.preventDefault(); + E.preventDefault(); return; } else if (j === "ArrowLeft") if (i > 1) M = -1; else { - k.preventDefault(); + E.preventDefault(); return; } else j === "ArrowDown" ? M = 6 : j === "ArrowUp" && (M = -6); - i + M <= 0 || i + M > tn(c) ? l(0) : M !== 0 && (l(i + M), k.preventDefault()); + i + M <= 0 || i + M > tn(c) ? l(0) : M !== 0 && (l(i + M), E.preventDefault()); } }; return ae(() => { @@ -1184,16 +1184,16 @@ function oh({ scrRef: t, handleSubmit: e }) { }, [c, t.bookNum, t.chapterNum, o]), Qo(() => { g(p); }, [p]), Qo(() => { - const k = setTimeout(() => { + const E = setTimeout(() => { if (w && m.current && h.current) { const M = h.current.offsetTop - uc; m.current.scrollTo({ top: M, behavior: "instant" }); } }, 10); return () => { - clearTimeout(k); + clearTimeout(E); }; - }, [w]), /* @__PURE__ */ s("div", { className: "pr-twp tw-flex", children: /* @__PURE__ */ x(wo, { modal: !1, open: p, onOpenChange: E, children: [ + }, [w]), /* @__PURE__ */ s("div", { className: "pr-twp tw-flex", children: /* @__PURE__ */ x(wo, { modal: !1, open: p, onOpenChange: S, children: [ /* @__PURE__ */ s(wi, { asChild: !0, children: /* @__PURE__ */ s( Hl, { @@ -1229,9 +1229,9 @@ function oh({ scrRef: t, handleSubmit: e }) { } ), na.map( - (k, j) => S(k).length > 0 && /* @__PURE__ */ x("div", { children: [ - /* @__PURE__ */ s(Sn, { className: "tw-font-semibold tw-text-foreground/80", children: pc[k] }), - S(k).map((M) => /* @__PURE__ */ s("div", { children: /* @__PURE__ */ s( + (E, j) => k(E).length > 0 && /* @__PURE__ */ x("div", { children: [ + /* @__PURE__ */ s(Sn, { className: "tw-font-semibold tw-text-foreground/80", children: pc[E] }), + k(E).map((M) => /* @__PURE__ */ s("div", { children: /* @__PURE__ */ s( lc, { bookId: M, @@ -1239,7 +1239,7 @@ function oh({ scrRef: t, handleSubmit: e }) { isSelected: o === M, handleHighlightBook: () => d(M), handleKeyDown: P, - bookType: k, + bookType: E, ref: (J) => { o === M && (h.current = J); }, @@ -1258,7 +1258,7 @@ function oh({ scrRef: t, handleSubmit: e }) { } ) }, M)), na.length - 1 !== j ? /* @__PURE__ */ s(or, {}) : void 0 - ] }, k) + ] }, E) ) ] } @@ -1462,60 +1462,61 @@ function Oc(t) { function Wr({ id: t, options: e = [], - buttonClassName: n, - popoverContentClassName: r, - value: o, - onChange: a = () => { + className: n, + buttonClassName: r, + popoverContentClassName: o, + value: a, + onChange: i = () => { }, - getOptionLabel: i = Oc, - buttonPlaceholder: l = "", - textPlaceholder: c = "", - commandEmptyMessage: d = "No option found", - buttonVariant: p = "outline", - dir: f = "ltr", - isDisabled: w = !1, - ...g + getOptionLabel: l = Oc, + buttonPlaceholder: c = "", + textPlaceholder: d = "", + commandEmptyMessage: p = "No option found", + buttonVariant: f = "outline", + dir: w = "ltr", + isDisabled: g = !1, + ...v }) { - const [v, m] = ut(!1); - return /* @__PURE__ */ x(yc, { open: v, onOpenChange: m, ...g, children: [ + const [m, h] = ut(!1); + return /* @__PURE__ */ x(yc, { open: m, onOpenChange: h, ...v, children: [ /* @__PURE__ */ s(xc, { asChild: !0, children: /* @__PURE__ */ x( gt, { - variant: p, + variant: f, role: "combobox", - "aria-expanded": v, + "aria-expanded": m, id: t, - className: N("tw-w-[200px] tw-justify-between", n), - disabled: w, + className: N("tw-w-[200px] tw-justify-between", r ?? n), + disabled: g, children: [ - /* @__PURE__ */ s("span", { className: "tw-overflow-hidden tw-text-ellipsis tw-whitespace-nowrap", children: o ? i(o) : l }), + /* @__PURE__ */ s("span", { className: "tw-overflow-hidden tw-text-ellipsis tw-whitespace-nowrap", children: a ? l(a) : c }), /* @__PURE__ */ s(Qs, { className: "tw-ms-2 tw-h-4 tw-w-4 tw-shrink-0 tw-opacity-50" }) ] } ) }), - /* @__PURE__ */ s(gi, { className: N("tw-w-[200px] tw-p-0", r), dir: f, children: /* @__PURE__ */ x(vi, { children: [ - /* @__PURE__ */ s(yi, { dir: f, placeholder: c, className: "tw-text-inherit" }), - /* @__PURE__ */ s(Ni, { children: d }), - /* @__PURE__ */ s(xi, { children: e.map((h) => /* @__PURE__ */ x( + /* @__PURE__ */ s(gi, { className: N("tw-w-[200px] tw-p-0", o), dir: w, children: /* @__PURE__ */ x(vi, { children: [ + /* @__PURE__ */ s(yi, { dir: w, placeholder: d, className: "tw-text-inherit" }), + /* @__PURE__ */ s(Ni, { children: p }), + /* @__PURE__ */ s(xi, { children: e.map((k) => /* @__PURE__ */ x( ki, { - value: i(h), + value: l(k), onSelect: () => { - a(h), m(!1); + i(k), h(!1); }, children: [ /* @__PURE__ */ s( tr, { className: N("tw-me-2 tw-h-4 tw-w-4", { - "tw-opacity-0": !o || i(o) !== i(h) + "tw-opacity-0": !a || l(a) !== l(k) }) } ), - i(h) + l(k) ] }, - i(h) + l(k) )) }) ] }) }) ] }); @@ -1959,15 +1960,15 @@ function Bc({ return /* @__PURE__ */ x("div", { className: "pr-twp", children: [ o && /* @__PURE__ */ s(Pc, { table: m }), /* @__PURE__ */ x(ar, { stickyHeader: a, children: [ - /* @__PURE__ */ s(ir, { stickyHeader: a, children: m.getHeaderGroups().map((S) => /* @__PURE__ */ s(oe, { children: S.headers.map((A) => /* @__PURE__ */ s(bn, { children: A.isPlaceholder ? void 0 : cn(A.column.columnDef.header, A.getContext()) }, A.id)) }, S.id)) }), - /* @__PURE__ */ s(sr, { children: (h = m.getRowModel().rows) != null && h.length ? m.getRowModel().rows.map((S) => /* @__PURE__ */ s( + /* @__PURE__ */ s(ir, { stickyHeader: a, children: m.getHeaderGroups().map((k) => /* @__PURE__ */ s(oe, { children: k.headers.map((A) => /* @__PURE__ */ s(bn, { children: A.isPlaceholder ? void 0 : cn(A.column.columnDef.header, A.getContext()) }, A.id)) }, k.id)) }), + /* @__PURE__ */ s(sr, { children: (h = m.getRowModel().rows) != null && h.length ? m.getRowModel().rows.map((k) => /* @__PURE__ */ s( oe, { - onClick: () => i(S, m), - "data-state": S.getIsSelected() && "selected", - children: S.getVisibleCells().map((A) => /* @__PURE__ */ s(Be, { children: cn(A.column.columnDef.cell, A.getContext()) }, A.id)) + onClick: () => i(k, m), + "data-state": k.getIsSelected() && "selected", + children: k.getVisibleCells().map((A) => /* @__PURE__ */ s(Be, { children: cn(A.column.columnDef.cell, A.getContext()) }, A.id)) }, - S.id + k.id )) : /* @__PURE__ */ s(oe, { children: /* @__PURE__ */ s(Be, { colSpan: t.length, className: "tw-h-24 tw-text-center", children: "No results." }) }) }) ] }), n && /* @__PURE__ */ x("div", { className: "tw-flex tw-items-center tw-justify-end tw-space-x-2 tw-py-4", children: [ @@ -2268,17 +2269,17 @@ function ph({ onScopeChange: d, columns: p }) { - const f = Jt(n, "%webView_inventory_all%"), w = Jt(n, "%webView_inventory_approved%"), g = Jt(n, "%webView_inventory_unapproved%"), v = Jt(n, "%webView_inventory_unknown%"), m = Jt(n, "%webView_inventory_scope_currentBook%"), h = Jt(n, "%webView_inventory_scope_chapter%"), S = Jt(n, "%webView_inventory_scope_verse%"), A = Jt(n, "%webView_inventory_filter_text%"), R = Jt( + const f = Jt(n, "%webView_inventory_all%"), w = Jt(n, "%webView_inventory_approved%"), g = Jt(n, "%webView_inventory_unapproved%"), v = Jt(n, "%webView_inventory_unknown%"), m = Jt(n, "%webView_inventory_scope_currentBook%"), h = Jt(n, "%webView_inventory_scope_chapter%"), k = Jt(n, "%webView_inventory_scope_verse%"), A = Jt(n, "%webView_inventory_filter_text%"), R = Jt( n, "%webView_inventory_show_additional_items%" - ), [E, b] = ut(!1), [$, z] = ut("all"), [H, C] = ut(""), [P, k] = ut([]), j = $t(() => l ? r instanceof RegExp ? Xc( + ), [S, b] = ut(!1), [$, z] = ut("all"), [H, C] = ut(""), [P, E] = ut([]), j = $t(() => l ? r instanceof RegExp ? Xc( l, t, a, i, r ) : r(l, t, a, i) : [], [l, r, t, a, i]), M = $t(() => { - if (E) + if (S) return j; const y = []; return j.forEach((O) => { @@ -2292,9 +2293,9 @@ function ph({ status: O.status }); }), y; - }, [E, j]), J = $t(() => Hc(M, $, H), [M, $, H]), q = $t(() => { + }, [S, j]), J = $t(() => Hc(M, $, H), [M, $, H]), q = $t(() => { var L, F; - if (!E) + if (!S) return p; const y = (L = o == null ? void 0 : o.tableHeaders) == null ? void 0 : L.length; if (!y) @@ -2308,15 +2309,15 @@ function ph({ ) ); return [...O, ...p]; - }, [o == null ? void 0 : o.tableHeaders, p, E]); + }, [o == null ? void 0 : o.tableHeaders, p, S]); ae(() => { - k([]); + E([]); }, [J]); const U = (y, O) => { O.setRowSelection(() => { const L = {}; return L[y.index] = !0, L; - }), k(y.original.items); + }), E(y.original.items); }, tt = (y) => { if (y === "book" || y === "chapter" || y === "verse") d(y); @@ -2331,13 +2332,13 @@ function ph({ if (M.length === 0 || P.length === 0) return []; const y = M.filter((O) => lo( - E ? O.items : [O.items[0]], + S ? O.items : [O.items[0]], P )); if (y.length > 1) throw new Error("Selected item is not unique"); return y[0].occurrences; - }, [P, E, M]); + }, [P, S, M]); return /* @__PURE__ */ x("div", { className: "pr-twp tw-flex tw-h-full tw-flex-col", children: [ /* @__PURE__ */ x("div", { className: "tw-flex tw-items-stretch", children: [ /* @__PURE__ */ x( @@ -2361,7 +2362,7 @@ function ph({ /* @__PURE__ */ x(je, { children: [ /* @__PURE__ */ s(Ut, { value: "book", children: m }), /* @__PURE__ */ s(Ut, { value: "chapter", children: h }), - /* @__PURE__ */ s(Ut, { value: "verse", children: S }) + /* @__PURE__ */ s(Ut, { value: "verse", children: k }) ] }) ] }), /* @__PURE__ */ s( @@ -2380,9 +2381,9 @@ function ph({ mo, { className: "tw-m-1", - checked: E, + checked: S, onCheckedChange: (y) => { - k([]), b(y); + E([]), b(y); } } ), @@ -2584,7 +2585,7 @@ const Mi = T.forwardRef( ), className: N( // Removed tw-min-h-svh - "tw-group/sidebar-wrapper has-[[data-variant=inset]]:tw-bg-sidebar pr-twp tw-flex tw-w-full", + "tw-group/sidebar-wrapper pr-twp tw-flex tw-w-full has-[[data-variant=inset]]:tw-bg-sidebar", r ), ref: l, @@ -2609,7 +2610,7 @@ const Di = T.forwardRef( "div", { className: N( - "tw-bg-sidebar tw-text-sidebar-foreground tw-flex tw-h-full tw-w-[--sidebar-width] tw-flex-col", + "tw-flex tw-h-full tw-w-[--sidebar-width] tw-flex-col tw-bg-sidebar tw-text-sidebar-foreground", r ), ref: i, @@ -2620,7 +2621,7 @@ const Di = T.forwardRef( "div", { ref: i, - className: "tw-text-sidebar-foreground tw-group tw-peer tw-hidden md:tw-block", + className: "tw-group tw-peer tw-hidden tw-text-sidebar-foreground md:tw-block", "data-state": l, "data-collapsible": l === "collapsed" ? n : "", "data-variant": e, @@ -2653,7 +2654,7 @@ const Di = T.forwardRef( "div", { "data-sidebar": "sidebar", - className: "tw-bg-sidebar group-data-[variant=floating]:tw-border-sidebar-border tw-flex tw-h-full tw-w-full tw-flex-col group-data-[variant=floating]:tw-rounded-lg group-data-[variant=floating]:tw-border group-data-[variant=floating]:tw-shadow", + className: "tw-flex tw-h-full tw-w-full tw-flex-col tw-bg-sidebar group-data-[variant=floating]:tw-rounded-lg group-data-[variant=floating]:tw-border group-data-[variant=floating]:tw-border-sidebar-border group-data-[variant=floating]:tw-shadow", children: o } ) @@ -2701,10 +2702,10 @@ const td = T.forwardRef( onClick: r, title: "Toggle Sidebar", className: N( - "hover:after:tw-bg-sidebar-border tw-absolute tw-inset-y-0 tw-z-20 tw-hidden tw-w-4 tw--translate-x-1/2 tw-transition-all tw-ease-linear after:tw-absolute after:tw-inset-y-0 after:tw-left-1/2 after:tw-w-[2px] group-data-[side=left]:tw--right-4 group-data-[side=right]:tw-left-0 sm:tw-flex", + "tw-absolute tw-inset-y-0 tw-z-20 tw-hidden tw-w-4 tw--translate-x-1/2 tw-transition-all tw-ease-linear after:tw-absolute after:tw-inset-y-0 after:tw-left-1/2 after:tw-w-[2px] hover:after:tw-bg-sidebar-border group-data-[side=left]:tw--right-4 group-data-[side=right]:tw-left-0 sm:tw-flex", "[[data-side=left]_&]:tw-cursor-w-resize [[data-side=right]_&]:tw-cursor-e-resize", "[[data-side=left][data-state=collapsed]_&]:tw-cursor-e-resize [[data-side=right][data-state=collapsed]_&]:tw-cursor-w-resize", - "group-data-[collapsible=offcanvas]:hover:tw-bg-sidebar group-data-[collapsible=offcanvas]:tw-translate-x-0 group-data-[collapsible=offcanvas]:after:tw-left-full", + "group-data-[collapsible=offcanvas]:tw-translate-x-0 group-data-[collapsible=offcanvas]:after:tw-left-full group-data-[collapsible=offcanvas]:hover:tw-bg-sidebar", "[[data-side=left][data-collapsible=offcanvas]_&]:tw--right-2", "[[data-side=right][data-collapsible=offcanvas]_&]:tw--left-2", t @@ -2737,7 +2738,7 @@ const ed = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( ref: n, "data-sidebar": "input", className: N( - "focus-visible:tw-ring-sidebar-ring tw-h-8 tw-w-full tw-bg-background tw-shadow-none focus-visible:tw-ring-2", + "tw-h-8 tw-w-full tw-bg-background tw-shadow-none focus-visible:tw-ring-2 focus-visible:tw-ring-sidebar-ring", t ), ...e @@ -2773,7 +2774,7 @@ const od = T.forwardRef(({ className: t, ...e }, n) => /* @__PURE__ */ s( { ref: n, "data-sidebar": "separator", - className: N("tw-bg-sidebar-border tw-mx-2 tw-w-auto", t), + className: N("tw-mx-2 tw-w-auto tw-bg-sidebar-border", t), ...e } )); @@ -2811,7 +2812,7 @@ const Kr = T.forwardRef(({ className: t, asChild: e = !1, ...n }, r) => /* @__PU ref: r, "data-sidebar": "group-label", className: N( - "tw-text-sidebar-foreground/70 tw-ring-sidebar-ring tw-flex tw-h-8 tw-shrink-0 tw-items-center tw-rounded-md tw-px-2 tw-text-xs tw-font-medium tw-outline-none tw-transition-[margin,opa] tw-duration-200 tw-ease-linear focus-visible:tw-ring-2 [&>svg]:tw-size-4 [&>svg]:tw-shrink-0", + "tw-flex tw-h-8 tw-shrink-0 tw-items-center tw-rounded-md tw-px-2 tw-text-xs tw-font-medium tw-text-sidebar-foreground/70 tw-outline-none tw-ring-sidebar-ring tw-transition-[margin,opa] tw-duration-200 tw-ease-linear focus-visible:tw-ring-2 [&>svg]:tw-size-4 [&>svg]:tw-shrink-0", "group-data-[collapsible=icon]:tw--mt-8 group-data-[collapsible=icon]:tw-opacity-0", t ), @@ -2825,7 +2826,7 @@ const ad = T.forwardRef(({ className: t, asChild: e = !1, ...n }, r) => /* @__PU ref: r, "data-sidebar": "group-action", className: N( - "tw-text-sidebar-foreground tw-ring-sidebar-ring hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground tw-absolute tw-right-3 tw-top-3.5 tw-flex tw-aspect-square tw-w-5 tw-items-center tw-justify-center tw-rounded-md tw-p-0 tw-outline-none tw-transition-transform focus-visible:tw-ring-2 [&>svg]:tw-size-4 [&>svg]:tw-shrink-0", + "tw-absolute tw-right-3 tw-top-3.5 tw-flex tw-aspect-square tw-w-5 tw-items-center tw-justify-center tw-rounded-md tw-p-0 tw-text-sidebar-foreground tw-outline-none tw-ring-sidebar-ring tw-transition-transform hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground focus-visible:tw-ring-2 [&>svg]:tw-size-4 [&>svg]:tw-shrink-0", // Increases the hit area of the button on mobile. "after:tw-absolute after:tw--inset-2 after:md:tw-hidden", "group-data-[collapsible=icon]:tw-hidden", @@ -2927,7 +2928,7 @@ const sd = T.forwardRef(({ className: t, asChild: e = !1, showOnHover: n = !1, . ref: o, "data-sidebar": "menu-action", className: N( - "tw-peer-hover/menu-button:text-sidebar-accent-foreground tw-text-sidebar-foreground tw-ring-sidebar-ring hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground tw-absolute tw-right-1 tw-top-1.5 tw-flex tw-aspect-square tw-w-5 tw-items-center tw-justify-center tw-rounded-md tw-p-0 tw-outline-none tw-transition-transform focus-visible:tw-ring-2 [&>svg]:tw-size-4 [&>svg]:tw-shrink-0", + "tw-peer-hover/menu-button:text-sidebar-accent-foreground tw-absolute tw-right-1 tw-top-1.5 tw-flex tw-aspect-square tw-w-5 tw-items-center tw-justify-center tw-rounded-md tw-p-0 tw-text-sidebar-foreground tw-outline-none tw-ring-sidebar-ring tw-transition-transform hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground focus-visible:tw-ring-2 [&>svg]:tw-size-4 [&>svg]:tw-shrink-0", // Increases the hit area of the button on mobile. "after:tw-absolute after:tw--inset-2 after:md:tw-hidden", "tw-peer-data-[size=sm]/menu-button:top-1", @@ -2948,7 +2949,7 @@ const ld = T.forwardRef( ref: n, "data-sidebar": "menu-badge", className: N( - "tw-text-sidebar-foreground tw-pointer-events-none tw-absolute tw-right-1 tw-flex tw-h-5 tw-min-w-5 tw-select-none tw-items-center tw-justify-center tw-rounded-md tw-px-1 tw-text-xs tw-font-medium tw-tabular-nums", + "tw-pointer-events-none tw-absolute tw-right-1 tw-flex tw-h-5 tw-min-w-5 tw-select-none tw-items-center tw-justify-center tw-rounded-md tw-px-1 tw-text-xs tw-font-medium tw-tabular-nums tw-text-sidebar-foreground", "tw-peer-hover/menu-button:text-sidebar-accent-foreground tw-peer-data-[active=true]/menu-button:text-sidebar-accent-foreground", "tw-peer-data-[size=sm]/menu-button:top-1", "tw-peer-data-[size=default]/menu-button:top-1.5", @@ -2997,7 +2998,7 @@ const dd = T.forwardRef( ref: n, "data-sidebar": "menu-sub", className: N( - "tw-border-sidebar-border tw-mx-3.5 tw-flex tw-min-w-0 tw-translate-x-px tw-flex-col tw-gap-1 tw-border-l tw-px-2.5 tw-py-0.5", + "tw-mx-3.5 tw-flex tw-min-w-0 tw-translate-x-px tw-flex-col tw-gap-1 tw-border-l tw-border-sidebar-border tw-px-2.5 tw-py-0.5", "group-data-[collapsible=icon]:tw-hidden", t ), @@ -3018,7 +3019,7 @@ const ud = T.forwardRef(({ asChild: t = !1, size: e = "md", isActive: n, classNa "data-size": e, "data-active": n, className: N( - "tw-text-sidebar-foreground tw-ring-sidebar-ring hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground active:tw-bg-sidebar-accent active:tw-text-sidebar-accent-foreground [&>svg]:tw-text-sidebar-accent-foreground tw-flex tw-h-7 tw-min-w-0 tw--translate-x-px tw-items-center tw-gap-2 tw-overflow-hidden tw-rounded-md tw-px-2 tw-outline-none focus-visible:tw-ring-2 disabled:tw-pointer-events-none disabled:tw-opacity-50 aria-disabled:tw-pointer-events-none aria-disabled:tw-opacity-50 [&>span:last-child]:tw-truncate [&>svg]:tw-size-4 [&>svg]:tw-shrink-0", + "tw-flex tw-h-7 tw-min-w-0 tw--translate-x-px tw-items-center tw-gap-2 tw-overflow-hidden tw-rounded-md tw-px-2 tw-text-sidebar-foreground tw-outline-none tw-ring-sidebar-ring hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground focus-visible:tw-ring-2 active:tw-bg-sidebar-accent active:tw-text-sidebar-accent-foreground disabled:tw-pointer-events-none disabled:tw-opacity-50 aria-disabled:tw-pointer-events-none aria-disabled:tw-opacity-50 [&>span:last-child]:tw-truncate [&>svg]:tw-size-4 [&>svg]:tw-shrink-0 [&>svg]:tw-text-sidebar-accent-foreground", "data-[active=true]:tw-bg-sidebar-accent data-[active=true]:tw-text-sidebar-accent-foreground", e === "sm" && "tw-text-xs", e === "md" && "tw-text-sm", @@ -3224,7 +3225,7 @@ function fh({ { id: ne, desc: !1 } ]) : w([{ id: ne, desc: !1 }]); }, [d]); - const S = Qa({ + const k = Qa({ data: m, columns: h, state: { @@ -3246,14 +3247,14 @@ function fh({ }); ae(() => { if (l) { - const C = S.getSelectedRowModel().rowsById, P = Object.keys(C); + const C = k.getSelectedRowModel().rowsById, P = Object.keys(C); if (P.length === 1) { - const k = m.find((j) => aa(j) === P[0]) || void 0; - k && l(k); + const E = m.find((j) => aa(j) === P[0]) || void 0; + E && l(E); } } - }, [g, m, l, S]); - const A = o ?? gd, R = a ?? Fi, E = [ + }, [g, m, l, k]); + const A = o ?? gd, R = a ?? Fi, S = [ { label: "No Grouping", value: [] }, { label: `Group by ${A}`, value: [ne] }, { label: `Group by ${R}`, value: [we] }, @@ -3269,8 +3270,8 @@ function fh({ p(JSON.parse(C)); }, $ = (C, P) => { !C.getIsGrouped() && !C.getIsSelected() && C.getToggleSelectedHandler()(P); - }, z = (C, P) => C.getIsGrouped() ? "" : N("banded-row", P % 2 === 0 ? "even" : "odd"), H = (C, P, k) => { - if (!((C == null ? void 0 : C.length) === 0 || P.depth < k.column.getGroupedIndex())) { + }, z = (C, P) => C.getIsGrouped() ? "" : N("banded-row", P % 2 === 0 ? "even" : "odd"), H = (C, P, E) => { + if (!((C == null ? void 0 : C.length) === 0 || P.depth < E.column.getGroupedIndex())) { if (P.getIsGrouped()) switch (P.depth) { case 1: @@ -3298,12 +3299,12 @@ function fh({ }, children: [ /* @__PURE__ */ s(De, { className: "tw-mb-1 tw-mt-2", children: /* @__PURE__ */ s(gn, {}) }), - /* @__PURE__ */ s(je, { position: "item-aligned", children: /* @__PURE__ */ s($c, { children: E.map((C) => /* @__PURE__ */ s(Ut, { value: JSON.stringify(C.value), children: C.label }, C.label)) }) }) + /* @__PURE__ */ s(je, { position: "item-aligned", children: /* @__PURE__ */ s($c, { children: S.map((C) => /* @__PURE__ */ s(Ut, { value: JSON.stringify(C.value), children: C.label }, C.label)) }) }) ] } ), /* @__PURE__ */ x(ar, { className: "tw-relative tw-flex tw-flex-col tw-overflow-y-auto tw-p-0", children: [ - e && /* @__PURE__ */ s(ir, { children: S.getHeaderGroups().map((C) => /* @__PURE__ */ s(oe, { children: C.headers.filter((P) => P.column.columnDef.header).map((P) => ( + e && /* @__PURE__ */ s(ir, { children: k.getHeaderGroups().map((C) => /* @__PURE__ */ s(oe, { children: C.headers.filter((P) => P.column.columnDef.header).map((P) => ( /* For sticky column headers to work, we probably need to change the default definition of the shadcn Table component. See https://github.com/shadcn-ui/ui/issues/1151 */ /* @__PURE__ */ s(bn, { colSpan: P.colSpan, className: "top-0 tw-sticky", children: P.isPlaceholder ? void 0 : /* @__PURE__ */ x("div", { children: [ P.column.getCanGroup() ? /* @__PURE__ */ s( @@ -3320,23 +3321,23 @@ function fh({ cn(P.column.columnDef.header, P.getContext()) ] }) }, P.id) )) }, C.id)) }), - /* @__PURE__ */ s(sr, { children: S.getRowModel().rows.map((C, P) => /* @__PURE__ */ s( + /* @__PURE__ */ s(sr, { children: k.getRowModel().rows.map((C, P) => /* @__PURE__ */ s( oe, { "data-state": C.getIsSelected() ? "selected" : "", className: N(z(C, P)), - onClick: (k) => $(C, k), - children: C.getVisibleCells().map((k) => { - if (!(k.getIsPlaceholder() || k.column.columnDef.enableGrouping && !k.getIsGrouped() && (k.column.columnDef.id !== we || !n))) + onClick: (E) => $(C, E), + children: C.getVisibleCells().map((E) => { + if (!(E.getIsPlaceholder() || E.column.columnDef.enableGrouping && !E.getIsGrouped() && (E.column.columnDef.id !== we || !n))) return /* @__PURE__ */ s( Be, { className: N( - k.column.columnDef.id, + E.column.columnDef.id, "tw-p-[1px]", - H(d, C, k) + H(d, C, E) ), - children: (() => k.getIsGrouped() ? /* @__PURE__ */ x( + children: (() => E.getIsGrouped() ? /* @__PURE__ */ x( gt, { variant: "link", @@ -3346,15 +3347,15 @@ function fh({ C.getIsExpanded() && /* @__PURE__ */ s(er, {}), !C.getIsExpanded() && (c === "ltr" ? /* @__PURE__ */ s(Ka, {}) : /* @__PURE__ */ s(wl, {})), " ", - cn(k.column.columnDef.cell, k.getContext()), + cn(E.column.columnDef.cell, E.getContext()), " (", C.subRows.length, ")" ] } - ) : cn(k.column.columnDef.cell, k.getContext()))() + ) : cn(E.column.columnDef.cell, E.getContext()))() }, - k.id + E.id ); }) }, @@ -3570,7 +3571,7 @@ function Ed() { if (ia) return it; ia = 1; - var t = typeof Symbol == "function" && Symbol.for, e = t ? Symbol.for("react.element") : 60103, n = t ? Symbol.for("react.portal") : 60106, r = t ? Symbol.for("react.fragment") : 60107, o = t ? Symbol.for("react.strict_mode") : 60108, a = t ? Symbol.for("react.profiler") : 60114, i = t ? Symbol.for("react.provider") : 60109, l = t ? Symbol.for("react.context") : 60110, c = t ? Symbol.for("react.async_mode") : 60111, d = t ? Symbol.for("react.concurrent_mode") : 60111, p = t ? Symbol.for("react.forward_ref") : 60112, f = t ? Symbol.for("react.suspense") : 60113, w = t ? Symbol.for("react.suspense_list") : 60120, g = t ? Symbol.for("react.memo") : 60115, v = t ? Symbol.for("react.lazy") : 60116, m = t ? Symbol.for("react.block") : 60121, h = t ? Symbol.for("react.fundamental") : 60117, S = t ? Symbol.for("react.responder") : 60118, A = t ? Symbol.for("react.scope") : 60119; + var t = typeof Symbol == "function" && Symbol.for, e = t ? Symbol.for("react.element") : 60103, n = t ? Symbol.for("react.portal") : 60106, r = t ? Symbol.for("react.fragment") : 60107, o = t ? Symbol.for("react.strict_mode") : 60108, a = t ? Symbol.for("react.profiler") : 60114, i = t ? Symbol.for("react.provider") : 60109, l = t ? Symbol.for("react.context") : 60110, c = t ? Symbol.for("react.async_mode") : 60111, d = t ? Symbol.for("react.concurrent_mode") : 60111, p = t ? Symbol.for("react.forward_ref") : 60112, f = t ? Symbol.for("react.suspense") : 60113, w = t ? Symbol.for("react.suspense_list") : 60120, g = t ? Symbol.for("react.memo") : 60115, v = t ? Symbol.for("react.lazy") : 60116, m = t ? Symbol.for("react.block") : 60121, h = t ? Symbol.for("react.fundamental") : 60117, k = t ? Symbol.for("react.responder") : 60118, A = t ? Symbol.for("react.scope") : 60119; function R(b) { if (typeof b == "object" && b !== null) { var $ = b.$$typeof; @@ -3601,12 +3602,12 @@ function Ed() { } } } - function E(b) { + function S(b) { return R(b) === d; } return it.AsyncMode = c, it.ConcurrentMode = d, it.ContextConsumer = l, it.ContextProvider = i, it.Element = e, it.ForwardRef = p, it.Fragment = r, it.Lazy = v, it.Memo = g, it.Portal = n, it.Profiler = a, it.StrictMode = o, it.Suspense = f, it.isAsyncMode = function(b) { - return E(b) || R(b) === c; - }, it.isConcurrentMode = E, it.isContextConsumer = function(b) { + return S(b) || R(b) === c; + }, it.isConcurrentMode = S, it.isContextConsumer = function(b) { return R(b) === l; }, it.isContextProvider = function(b) { return R(b) === i; @@ -3629,7 +3630,7 @@ function Ed() { }, it.isSuspense = function(b) { return R(b) === f; }, it.isValidElementType = function(b) { - return typeof b == "string" || typeof b == "function" || b === r || b === d || b === a || b === o || b === f || b === w || typeof b == "object" && b !== null && (b.$$typeof === v || b.$$typeof === g || b.$$typeof === i || b.$$typeof === l || b.$$typeof === p || b.$$typeof === h || b.$$typeof === S || b.$$typeof === A || b.$$typeof === m); + return typeof b == "string" || typeof b == "function" || b === r || b === d || b === a || b === o || b === f || b === w || typeof b == "object" && b !== null && (b.$$typeof === v || b.$$typeof === g || b.$$typeof === i || b.$$typeof === l || b.$$typeof === p || b.$$typeof === h || b.$$typeof === k || b.$$typeof === A || b.$$typeof === m); }, it.typeOf = R, it; } var st = {}; @@ -3644,12 +3645,12 @@ var st = {}; var sa; function Sd() { return sa || (sa = 1, process.env.NODE_ENV !== "production" && function() { - var t = typeof Symbol == "function" && Symbol.for, e = t ? Symbol.for("react.element") : 60103, n = t ? Symbol.for("react.portal") : 60106, r = t ? Symbol.for("react.fragment") : 60107, o = t ? Symbol.for("react.strict_mode") : 60108, a = t ? Symbol.for("react.profiler") : 60114, i = t ? Symbol.for("react.provider") : 60109, l = t ? Symbol.for("react.context") : 60110, c = t ? Symbol.for("react.async_mode") : 60111, d = t ? Symbol.for("react.concurrent_mode") : 60111, p = t ? Symbol.for("react.forward_ref") : 60112, f = t ? Symbol.for("react.suspense") : 60113, w = t ? Symbol.for("react.suspense_list") : 60120, g = t ? Symbol.for("react.memo") : 60115, v = t ? Symbol.for("react.lazy") : 60116, m = t ? Symbol.for("react.block") : 60121, h = t ? Symbol.for("react.fundamental") : 60117, S = t ? Symbol.for("react.responder") : 60118, A = t ? Symbol.for("react.scope") : 60119; + var t = typeof Symbol == "function" && Symbol.for, e = t ? Symbol.for("react.element") : 60103, n = t ? Symbol.for("react.portal") : 60106, r = t ? Symbol.for("react.fragment") : 60107, o = t ? Symbol.for("react.strict_mode") : 60108, a = t ? Symbol.for("react.profiler") : 60114, i = t ? Symbol.for("react.provider") : 60109, l = t ? Symbol.for("react.context") : 60110, c = t ? Symbol.for("react.async_mode") : 60111, d = t ? Symbol.for("react.concurrent_mode") : 60111, p = t ? Symbol.for("react.forward_ref") : 60112, f = t ? Symbol.for("react.suspense") : 60113, w = t ? Symbol.for("react.suspense_list") : 60120, g = t ? Symbol.for("react.memo") : 60115, v = t ? Symbol.for("react.lazy") : 60116, m = t ? Symbol.for("react.block") : 60121, h = t ? Symbol.for("react.fundamental") : 60117, k = t ? Symbol.for("react.responder") : 60118, A = t ? Symbol.for("react.scope") : 60119; function R(I) { return typeof I == "string" || typeof I == "function" || // Note: its typeof might be other than 'symbol' or 'number' if it's a polyfill. - I === r || I === d || I === a || I === o || I === f || I === w || typeof I == "object" && I !== null && (I.$$typeof === v || I.$$typeof === g || I.$$typeof === i || I.$$typeof === l || I.$$typeof === p || I.$$typeof === h || I.$$typeof === S || I.$$typeof === A || I.$$typeof === m); + I === r || I === d || I === a || I === o || I === f || I === w || typeof I == "object" && I !== null && (I.$$typeof === v || I.$$typeof === g || I.$$typeof === i || I.$$typeof === l || I.$$typeof === p || I.$$typeof === h || I.$$typeof === k || I.$$typeof === A || I.$$typeof === m); } - function E(I) { + function S(I) { if (typeof I == "object" && I !== null) { var xt = I.$$typeof; switch (xt) { @@ -3681,47 +3682,47 @@ function Sd() { } } } - var b = c, $ = d, z = l, H = i, C = e, P = p, k = r, j = v, M = g, J = n, q = a, U = o, tt = f, at = !1; + var b = c, $ = d, z = l, H = i, C = e, P = p, E = r, j = v, M = g, J = n, q = a, U = o, tt = f, at = !1; function rt(I) { - return at || (at = !0, console.warn("The ReactIs.isAsyncMode() alias has been deprecated, and will be removed in React 17+. Update your code to use ReactIs.isConcurrentMode() instead. It has the exact same API.")), y(I) || E(I) === c; + return at || (at = !0, console.warn("The ReactIs.isAsyncMode() alias has been deprecated, and will be removed in React 17+. Update your code to use ReactIs.isConcurrentMode() instead. It has the exact same API.")), y(I) || S(I) === c; } function y(I) { - return E(I) === d; + return S(I) === d; } function O(I) { - return E(I) === l; + return S(I) === l; } function L(I) { - return E(I) === i; + return S(I) === i; } function F(I) { return typeof I == "object" && I !== null && I.$$typeof === e; } function V(I) { - return E(I) === p; + return S(I) === p; } function W(I) { - return E(I) === r; + return S(I) === r; } function X(I) { - return E(I) === v; + return S(I) === v; } function Y(I) { - return E(I) === g; + return S(I) === g; } function G(I) { - return E(I) === n; + return S(I) === n; } function K(I) { - return E(I) === a; + return S(I) === a; } function Z(I) { - return E(I) === o; + return S(I) === o; } function dt(I) { - return E(I) === f; + return S(I) === f; } - st.AsyncMode = b, st.ConcurrentMode = $, st.ContextConsumer = z, st.ContextProvider = H, st.Element = C, st.ForwardRef = P, st.Fragment = k, st.Lazy = j, st.Memo = M, st.Portal = J, st.Profiler = q, st.StrictMode = U, st.Suspense = tt, st.isAsyncMode = rt, st.isConcurrentMode = y, st.isContextConsumer = O, st.isContextProvider = L, st.isElement = F, st.isForwardRef = V, st.isFragment = W, st.isLazy = X, st.isMemo = Y, st.isPortal = G, st.isProfiler = K, st.isStrictMode = Z, st.isSuspense = dt, st.isValidElementType = R, st.typeOf = E; + st.AsyncMode = b, st.ConcurrentMode = $, st.ContextConsumer = z, st.ContextProvider = H, st.Element = C, st.ForwardRef = P, st.Fragment = E, st.Lazy = j, st.Memo = M, st.Portal = J, st.Profiler = q, st.StrictMode = U, st.Suspense = tt, st.isAsyncMode = rt, st.isConcurrentMode = y, st.isContextConsumer = O, st.isContextProvider = L, st.isElement = F, st.isForwardRef = V, st.isFragment = W, st.isLazy = X, st.isMemo = Y, st.isPortal = G, st.isProfiler = K, st.isStrictMode = Z, st.isSuspense = dt, st.isValidElementType = R, st.typeOf = S; }()), st; } var la; @@ -3868,17 +3869,17 @@ function Od() { return O; } var w = "<>", g = { - array: S("array"), - bigint: S("bigint"), - bool: S("boolean"), - func: S("function"), - number: S("number"), - object: S("object"), - string: S("string"), - symbol: S("symbol"), + array: k("array"), + bigint: k("bigint"), + bool: k("boolean"), + func: k("function"), + number: k("number"), + object: k("object"), + string: k("string"), + symbol: k("symbol"), any: A(), arrayOf: R, - element: E(), + element: S(), elementType: b(), instanceOf: $, node: P(), @@ -3918,7 +3919,7 @@ function Od() { var V = F.bind(null, !1); return V.isRequired = F.bind(null, !0), V; } - function S(y) { + function k(y) { function O(L, F, V, W, X, Y) { var G = L[F], K = U(G); if (K !== y) { @@ -3953,7 +3954,7 @@ function Od() { } return h(O); } - function E() { + function S() { function y(O, L, F, V, W) { var X = O[L]; if (!l(X)) { @@ -4047,7 +4048,7 @@ function Od() { } return h(y); } - function k(y, O, L, F, V) { + function E(y, O, L, F, V) { return new m( (y || "React class") + ": " + O + " type `" + L + "." + F + "` is invalid; it must be a function, usually from the `prop-types` package, but received `" + V + "`." ); @@ -4060,7 +4061,7 @@ function Od() { for (var K in y) { var Z = y[K]; if (typeof Z != "function") - return k(V, W, X, K, tt(Z)); + return E(V, W, X, K, tt(Z)); var dt = Z(Y, K, V, W, X + "." + K, n); if (dt) return dt; @@ -4078,7 +4079,7 @@ function Od() { for (var Z in K) { var dt = y[Z]; if (r(y, Z) && typeof dt != "function") - return k(V, W, X, Z, tt(dt)); + return E(V, W, X, Z, tt(dt)); if (!dt) return new m( "Invalid " + W + " `" + X + "` key `" + Z + "` supplied to `" + V + "`.\nBad object: " + JSON.stringify(L[F], null, " ") + ` @@ -4274,8 +4275,8 @@ function Dd() { v = Symbol.for("react.module.reference"); function m(h) { if (typeof h == "object" && h !== null) { - var S = h.$$typeof; - switch (S) { + var k = h.$$typeof; + switch (k) { case t: switch (h = h.type, h) { case n: @@ -4294,11 +4295,11 @@ function Dd() { case a: return h; default: - return S; + return k; } } case e: - return S; + return k; } } } @@ -4347,10 +4348,10 @@ var ct = {}; var ha; function jd() { return ha || (ha = 1, process.env.NODE_ENV !== "production" && function() { - var t = Symbol.for("react.element"), e = Symbol.for("react.portal"), n = Symbol.for("react.fragment"), r = Symbol.for("react.strict_mode"), o = Symbol.for("react.profiler"), a = Symbol.for("react.provider"), i = Symbol.for("react.context"), l = Symbol.for("react.server_context"), c = Symbol.for("react.forward_ref"), d = Symbol.for("react.suspense"), p = Symbol.for("react.suspense_list"), f = Symbol.for("react.memo"), w = Symbol.for("react.lazy"), g = Symbol.for("react.offscreen"), v = !1, m = !1, h = !1, S = !1, A = !1, R; + var t = Symbol.for("react.element"), e = Symbol.for("react.portal"), n = Symbol.for("react.fragment"), r = Symbol.for("react.strict_mode"), o = Symbol.for("react.profiler"), a = Symbol.for("react.provider"), i = Symbol.for("react.context"), l = Symbol.for("react.server_context"), c = Symbol.for("react.forward_ref"), d = Symbol.for("react.suspense"), p = Symbol.for("react.suspense_list"), f = Symbol.for("react.memo"), w = Symbol.for("react.lazy"), g = Symbol.for("react.offscreen"), v = !1, m = !1, h = !1, k = !1, A = !1, R; R = Symbol.for("react.module.reference"); - function E(B) { - return !!(typeof B == "string" || typeof B == "function" || B === n || B === o || A || B === r || B === d || B === p || S || B === g || v || m || h || typeof B == "object" && B !== null && (B.$$typeof === w || B.$$typeof === f || B.$$typeof === a || B.$$typeof === i || B.$$typeof === c || // This needs to include all possible module reference object + function S(B) { + return !!(typeof B == "string" || typeof B == "function" || B === n || B === o || A || B === r || B === d || B === p || k || B === g || v || m || h || typeof B == "object" && B !== null && (B.$$typeof === w || B.$$typeof === f || B.$$typeof === a || B.$$typeof === i || B.$$typeof === c || // This needs to include all possible module reference object // types supported by any Flight configuration anywhere since // we don't know which Flight build this will end up being used // with. @@ -4388,7 +4389,7 @@ function jd() { } } } - var $ = i, z = a, H = t, C = c, P = n, k = w, j = f, M = e, J = o, q = r, U = d, tt = p, at = !1, rt = !1; + var $ = i, z = a, H = t, C = c, P = n, E = w, j = f, M = e, J = o, q = r, U = d, tt = p, at = !1, rt = !1; function y(B) { return at || (at = !0, console.warn("The ReactIs.isAsyncMode() alias has been deprecated, and will be removed in React 18+.")), !1; } @@ -4431,7 +4432,7 @@ function jd() { function xt(B) { return b(B) === p; } - ct.ContextConsumer = $, ct.ContextProvider = z, ct.Element = H, ct.ForwardRef = C, ct.Fragment = P, ct.Lazy = k, ct.Memo = j, ct.Portal = M, ct.Profiler = J, ct.StrictMode = q, ct.Suspense = U, ct.SuspenseList = tt, ct.isAsyncMode = y, ct.isConcurrentMode = O, ct.isContextConsumer = L, ct.isContextProvider = F, ct.isElement = V, ct.isForwardRef = W, ct.isFragment = X, ct.isLazy = Y, ct.isMemo = G, ct.isPortal = K, ct.isProfiler = Z, ct.isStrictMode = dt, ct.isSuspense = I, ct.isSuspenseList = xt, ct.isValidElementType = E, ct.typeOf = b; + ct.ContextConsumer = $, ct.ContextProvider = z, ct.Element = H, ct.ForwardRef = C, ct.Fragment = P, ct.Lazy = E, ct.Memo = j, ct.Portal = M, ct.Profiler = J, ct.StrictMode = q, ct.Suspense = U, ct.SuspenseList = tt, ct.isAsyncMode = y, ct.isConcurrentMode = O, ct.isContextConsumer = L, ct.isContextProvider = F, ct.isElement = V, ct.isForwardRef = W, ct.isFragment = X, ct.isLazy = Y, ct.isMemo = G, ct.isPortal = K, ct.isProfiler = Z, ct.isStrictMode = dt, ct.isSuspense = I, ct.isSuspenseList = xt, ct.isValidElementType = S, ct.typeOf = b; }()), ct; } process.env.NODE_ENV === "production" ? Qr.exports = Dd() : Qr.exports = jd(); @@ -5655,10 +5656,10 @@ function gu(t = {}) { ), m = f || !1; let h; process.env.NODE_ENV !== "production" && c && (h = `${c}-${Sa(d || "Root")}`); - let S = Gn; - d === "Root" || d === "root" ? S = r : d ? S = o : fu(i) && (S = void 0); + let k = Gn; + d === "Root" || d === "root" ? k = r : d ? k = o : fu(i) && (k = void 0); const A = Pl(i, _({ - shouldForwardProp: S, + shouldForwardProp: k, label: h }, g)), R = (b) => typeof b == "function" && b.__emotion_real !== b || he(b) ? ($) => Hn(b, _({}, $, { theme: Vn({ @@ -5666,11 +5667,11 @@ function gu(t = {}) { defaultTheme: n, themeId: e }) - })) : b, E = (b, ...$) => { + })) : b, S = (b, ...$) => { let z = R(b); const H = $ ? $.map(R) : []; - c && w && H.push((k) => { - const j = Vn(_({}, k, { + c && w && H.push((E) => { + const j = Vn(_({}, E, { defaultTheme: n, themeId: e })); @@ -5678,35 +5679,35 @@ function gu(t = {}) { return null; const M = j.components[c].styleOverrides, J = {}; return Object.entries(M).forEach(([q, U]) => { - J[q] = Hn(U, _({}, k, { + J[q] = Hn(U, _({}, E, { theme: j })); - }), w(k, J); - }), c && !v && H.push((k) => { + }), w(E, J); + }), c && !v && H.push((E) => { var j; - const M = Vn(_({}, k, { + const M = Vn(_({}, E, { defaultTheme: n, themeId: e })), J = M == null || (j = M.components) == null || (j = j[c]) == null ? void 0 : j.variants; return Hn({ variants: J - }, _({}, k, { + }, _({}, E, { theme: M })); }), m || H.push(a); const C = H.length - $.length; if (Array.isArray(b) && C > 0) { - const k = new Array(C).fill(""); - z = [...b, ...k], z.raw = [...b.raw, ...k]; + const E = new Array(C).fill(""); + z = [...b, ...E], z.raw = [...b.raw, ...E]; } const P = A(z, ...H); if (process.env.NODE_ENV !== "production") { - let k; - c && (k = `${c}${Wt(d || "")}`), k === void 0 && (k = `Styled(${zd(i)})`), P.displayName = k; + let E; + c && (E = `${c}${Wt(d || "")}`), E === void 0 && (E = `Styled(${zd(i)})`), P.displayName = E; } return i.muiName && (P.muiName = i.muiName), P; }; - return A.withConfig && (E.withConfig = A.withConfig), E; + return A.withConfig && (S.withConfig = A.withConfig), S; }; } function bu(t) { @@ -6080,8 +6081,8 @@ function Lu(t) { function f(m) { const h = Ca(m, Lr.text.primary) >= n ? Lr.text.primary : Oa.text.primary; if (process.env.NODE_ENV !== "production") { - const S = Ca(m, h); - S < 3 && console.error([`MUI: The contrast ratio of ${S}:1 for ${h} on ${m}`, "falls below the WCAG recommended absolute minimum contrast ratio of 3:1.", "https://www.w3.org/TR/2008/REC-WCAG20-20081211/#visual-audio-contrast-contrast"].join(` + const k = Ca(m, h); + k < 3 && console.error([`MUI: The contrast ratio of ${k}:1 for ${h} on ${m}`, "falls below the WCAG recommended absolute minimum contrast ratio of 3:1.", "https://www.w3.org/TR/2008/REC-WCAG20-20081211/#visual-audio-contrast-contrast"].join(` `)); } return h; @@ -6089,13 +6090,13 @@ function Lu(t) { const w = ({ color: m, name: h, - mainShade: S = 500, + mainShade: k = 500, lightShade: A = 300, darkShade: R = 700 }) => { - if (m = _({}, m), !m.main && m[S] && (m.main = m[S]), !m.hasOwnProperty("main")) + if (m = _({}, m), !m.main && m[k] && (m.main = m[k]), !m.hasOwnProperty("main")) throw new Error(process.env.NODE_ENV !== "production" ? `MUI: The color${h ? ` (${h})` : ""} provided to augmentColor(color) is invalid. -The color object needs to have a \`main\` property or a \`${S}\` property.` : Ve(11, h ? ` (${h})` : "", S)); +The color object needs to have a \`main\` property or a \`${k}\` property.` : Ve(11, h ? ` (${h})` : "", k)); if (typeof m.main != "string") throw new Error(process.env.NODE_ENV !== "production" ? `MUI: The color${h ? ` (${h})` : ""} provided to augmentColor(color) is invalid. \`color.main\` should be a string, but \`${JSON.stringify(m.main)}\` was provided instead. @@ -6195,14 +6196,14 @@ function Gu(t, e) { pxToRem: f } = n, w = Nt(n, Fu); process.env.NODE_ENV !== "production" && (typeof o != "number" && console.error("MUI: `fontSize` is required to be a number."), typeof d != "number" && console.error("MUI: `htmlFontSize` is required to be a number.")); - const g = o / 14, v = f || ((S) => `${S / d * g}rem`), m = (S, A, R, E, b) => _({ + const g = o / 14, v = f || ((k) => `${k / d * g}rem`), m = (k, A, R, S, b) => _({ fontFamily: r, - fontWeight: S, + fontWeight: k, fontSize: v(A), // Unitless following https://meyerweb.com/eric/thoughts/2006/02/08/unitless-line-heights/ lineHeight: R }, r === Pa ? { - letterSpacing: `${Uu(E / A)}em` + letterSpacing: `${Uu(S / A)}em` } : {}, b, p), h = { h1: m(a, 96, 1.167, -1.5), h2: m(a, 60, 1.2, -0.5), @@ -6451,10 +6452,10 @@ const cw = ["children", "className", "color", "component", "fontSize", "htmlColo hasSvgAsChild: v }), h = {}; p || (h.viewBox = w); - const S = dw(m); + const k = dw(m); return /* @__PURE__ */ x(pw, _({ as: l, - className: be(S.root, a), + className: be(k.root, a), focusable: "false", color: d, "aria-hidden": f ? void 0 : !0, @@ -6959,7 +6960,7 @@ var Kw = function(e, n) { function Jw(t) { var e, n = t.state, r = t.name, o = t.options, a = n.elements.arrow, i = n.modifiersData.popperOffsets, l = Xt(n.placement), c = Ao(l), d = [Ct, Vt].indexOf(l) >= 0, p = d ? "height" : "width"; if (!(!a || !i)) { - var f = Kw(o.padding, n), w = Io(a), g = c === "y" ? Tt : Ct, v = c === "y" ? Bt : Vt, m = n.rects.reference[p] + n.rects.reference[c] - i[c] - n.rects.popper[p], h = i[c] - n.rects.reference[c], S = Pn(a), A = S ? c === "y" ? S.clientHeight || 0 : S.clientWidth || 0 : 0, R = m / 2 - h / 2, E = f[g], b = A - w[p] - f[v], $ = A / 2 - w[p] / 2 + R, z = un(E, $, b), H = c; + var f = Kw(o.padding, n), w = Io(a), g = c === "y" ? Tt : Ct, v = c === "y" ? Bt : Vt, m = n.rects.reference[p] + n.rects.reference[c] - i[c] - n.rects.popper[p], h = i[c] - n.rects.reference[c], k = Pn(a), A = k ? c === "y" ? k.clientHeight || 0 : k.clientWidth || 0 : 0, R = m / 2 - h / 2, S = f[g], b = A - w[p] - f[v], $ = A / 2 - w[p] / 2 + R, z = un(S, $, b), H = c; n.modifiersData[r] = (e = {}, e[H] = z, e.centerOffset = z - $, e); } } @@ -7001,11 +7002,11 @@ function Ba(t) { y: m }; g = h.x, m = h.y; - var S = i.hasOwnProperty("x"), A = i.hasOwnProperty("y"), R = Ct, E = Tt, b = window; + var k = i.hasOwnProperty("x"), A = i.hasOwnProperty("y"), R = Ct, S = Tt, b = window; if (d) { var $ = Pn(n), z = "clientHeight", H = "clientWidth"; if ($ === At(n) && ($ = le(n), te($).position !== "static" && l === "absolute" && (z = "scrollHeight", H = "scrollWidth")), $ = $, o === Tt || (o === Ct || o === Vt) && a === xn) { - E = Bt; + S = Bt; var C = f && $ === b && b.visualViewport ? b.visualViewport.height : ( // $FlowFixMe[prop-missing] $[z] @@ -7021,7 +7022,7 @@ function Ba(t) { g -= P - r.width, g *= c ? 1 : -1; } } - var k = Object.assign({ + var E = Object.assign({ position: l }, d && tf), j = p === !0 ? ef({ x: g, @@ -7032,9 +7033,9 @@ function Ba(t) { }; if (g = j.x, m = j.y, c) { var M; - return Object.assign({}, k, (M = {}, M[E] = A ? "0" : "", M[R] = S ? "0" : "", M.transform = (b.devicePixelRatio || 1) <= 1 ? "translate(" + g + "px, " + m + "px)" : "translate3d(" + g + "px, " + m + "px, 0)", M)); + return Object.assign({}, E, (M = {}, M[S] = A ? "0" : "", M[R] = k ? "0" : "", M.transform = (b.devicePixelRatio || 1) <= 1 ? "translate(" + g + "px, " + m + "px)" : "translate3d(" + g + "px, " + m + "px, 0)", M)); } - return Object.assign({}, k, (e = {}, e[E] = A ? m + "px" : "", e[R] = S ? g + "px" : "", e.transform = "", e)); + return Object.assign({}, E, (e = {}, e[S] = A ? m + "px" : "", e[R] = k ? g + "px" : "", e.transform = "", e)); } function nf(t) { var e = t.state, n = t.options, r = n.gpuAcceleration, o = r === void 0 ? !0 : r, a = n.adaptive, i = a === void 0 ? !0 : a, l = n.roundOffsets, c = l === void 0 ? !0 : l, d = { @@ -7234,19 +7235,19 @@ function ks(t) { } function Nn(t, e) { e === void 0 && (e = {}); - var n = e, r = n.placement, o = r === void 0 ? t.placement : r, a = n.strategy, i = a === void 0 ? t.strategy : a, l = n.boundary, c = l === void 0 ? $w : l, d = n.rootBoundary, p = d === void 0 ? ms : d, f = n.elementContext, w = f === void 0 ? nn : f, g = n.altBoundary, v = g === void 0 ? !1 : g, m = n.padding, h = m === void 0 ? 0 : m, S = ys(typeof h != "number" ? h : xs(h, _n)), A = w === nn ? Iw : nn, R = t.rects.popper, E = t.elements[v ? A : w], b = wf(ke(E) ? E : E.contextElement || le(t.elements.popper), c, p, i), $ = Ue(t.elements.reference), z = ks({ + var n = e, r = n.placement, o = r === void 0 ? t.placement : r, a = n.strategy, i = a === void 0 ? t.strategy : a, l = n.boundary, c = l === void 0 ? $w : l, d = n.rootBoundary, p = d === void 0 ? ms : d, f = n.elementContext, w = f === void 0 ? nn : f, g = n.altBoundary, v = g === void 0 ? !1 : g, m = n.padding, h = m === void 0 ? 0 : m, k = ys(typeof h != "number" ? h : xs(h, _n)), A = w === nn ? Iw : nn, R = t.rects.popper, S = t.elements[v ? A : w], b = wf(ke(S) ? S : S.contextElement || le(t.elements.popper), c, p, i), $ = Ue(t.elements.reference), z = ks({ reference: $, element: R, strategy: "absolute", placement: o }), H = ro(Object.assign({}, R, z)), C = w === nn ? H : $, P = { - top: b.top - C.top + S.top, - bottom: C.bottom - b.bottom + S.bottom, - left: b.left - C.left + S.left, - right: C.right - b.right + S.right - }, k = t.modifiersData.offset; - if (w === nn && k) { - var j = k[o]; + top: b.top - C.top + k.top, + bottom: C.bottom - b.bottom + k.bottom, + left: b.left - C.left + k.left, + right: C.right - b.right + k.right + }, E = t.modifiersData.offset; + if (w === nn && E) { + var j = E[o]; Object.keys(P).forEach(function(M) { var J = [Vt, Bt].indexOf(M) >= 0 ? 1 : -1, q = [Tt, Bt].indexOf(M) >= 0 ? "y" : "x"; P[M] += j[q] * J; @@ -7283,7 +7284,7 @@ function mf(t) { function hf(t) { var e = t.state, n = t.options, r = t.name; if (!e.modifiersData[r]._skip) { - for (var o = n.mainAxis, a = o === void 0 ? !0 : o, i = n.altAxis, l = i === void 0 ? !0 : i, c = n.fallbackPlacements, d = n.padding, p = n.boundary, f = n.rootBoundary, w = n.altBoundary, g = n.flipVariations, v = g === void 0 ? !0 : g, m = n.allowedAutoPlacements, h = e.options.placement, S = Xt(h), A = S === h, R = c || (A || !v ? [Xn(h)] : mf(h)), E = [h].concat(R).reduce(function(V, W) { + for (var o = n.mainAxis, a = o === void 0 ? !0 : o, i = n.altAxis, l = i === void 0 ? !0 : i, c = n.fallbackPlacements, d = n.padding, p = n.boundary, f = n.rootBoundary, w = n.altBoundary, g = n.flipVariations, v = g === void 0 ? !0 : g, m = n.allowedAutoPlacements, h = e.options.placement, k = Xt(h), A = k === h, R = c || (A || !v ? [Xn(h)] : mf(h)), S = [h].concat(R).reduce(function(V, W) { return V.concat(Xt(W) === Po ? ff(e, { placement: W, boundary: p, @@ -7292,9 +7293,9 @@ function hf(t) { flipVariations: v, allowedAutoPlacements: m }) : W); - }, []), b = e.rects.reference, $ = e.rects.popper, z = /* @__PURE__ */ new Map(), H = !0, C = E[0], P = 0; P < E.length; P++) { - var k = E[P], j = Xt(k), M = Ge(k) === Le, J = [Tt, Bt].indexOf(j) >= 0, q = J ? "width" : "height", U = Nn(e, { - placement: k, + }, []), b = e.rects.reference, $ = e.rects.popper, z = /* @__PURE__ */ new Map(), H = !0, C = S[0], P = 0; P < S.length; P++) { + var E = S[P], j = Xt(E), M = Ge(E) === Le, J = [Tt, Bt].indexOf(j) >= 0, q = J ? "width" : "height", U = Nn(e, { + placement: E, boundary: p, rootBoundary: f, altBoundary: w, @@ -7305,14 +7306,14 @@ function hf(t) { if (a && rt.push(U[j] <= 0), l && rt.push(U[tt] <= 0, U[at] <= 0), rt.every(function(V) { return V; })) { - C = k, H = !1; + C = E, H = !1; break; } - z.set(k, rt); + z.set(E, rt); } if (H) for (var y = v ? 3 : 1, O = function(W) { - var X = E.find(function(Y) { + var X = S.find(function(Y) { var G = z.get(Y); if (G) return G.slice(0, W).every(function(K) { @@ -7428,7 +7429,7 @@ function Tf(t) { rootBoundary: d, padding: f, altBoundary: p - }), S = Xt(e.placement), A = Ge(e.placement), R = !A, E = Ao(S), b = Sf(E), $ = e.modifiersData.popperOffsets, z = e.rects.reference, H = e.rects.popper, C = typeof m == "function" ? m(Object.assign({}, e.rects, { + }), k = Xt(e.placement), A = Ge(e.placement), R = !A, S = Ao(k), b = Sf(S), $ = e.modifiersData.popperOffsets, z = e.rects.reference, H = e.rects.popper, C = typeof m == "function" ? m(Object.assign({}, e.rects, { placement: e.placement })) : m, P = typeof C == "number" ? { mainAxis: C, @@ -7436,20 +7437,20 @@ function Tf(t) { } : Object.assign({ mainAxis: 0, altAxis: 0 - }, C), k = e.modifiersData.offset ? e.modifiersData.offset[e.placement] : null, j = { + }, C), E = e.modifiersData.offset ? e.modifiersData.offset[e.placement] : null, j = { x: 0, y: 0 }; if ($) { if (a) { - var M, J = E === "y" ? Tt : Ct, q = E === "y" ? Bt : Vt, U = E === "y" ? "height" : "width", tt = $[E], at = tt + h[J], rt = tt - h[q], y = g ? -H[U] / 2 : 0, O = A === Le ? z[U] : H[U], L = A === Le ? -H[U] : -z[U], F = e.elements.arrow, V = g && F ? Io(F) : { + var M, J = S === "y" ? Tt : Ct, q = S === "y" ? Bt : Vt, U = S === "y" ? "height" : "width", tt = $[S], at = tt + h[J], rt = tt - h[q], y = g ? -H[U] / 2 : 0, O = A === Le ? z[U] : H[U], L = A === Le ? -H[U] : -z[U], F = e.elements.arrow, V = g && F ? Io(F) : { width: 0, height: 0 - }, W = e.modifiersData["arrow#persistent"] ? e.modifiersData["arrow#persistent"].padding : vs(), X = W[J], Y = W[q], G = un(0, z[U], V[U]), K = R ? z[U] / 2 - y - G - X - P.mainAxis : O - G - X - P.mainAxis, Z = R ? -z[U] / 2 + y + G + Y + P.mainAxis : L + G + Y + P.mainAxis, dt = e.elements.arrow && Pn(e.elements.arrow), I = dt ? E === "y" ? dt.clientTop || 0 : dt.clientLeft || 0 : 0, xt = (M = k == null ? void 0 : k[E]) != null ? M : 0, B = tt + K - xt - I, yt = tt + Z - xt, Lt = un(g ? Jn(at, B) : at, tt, g ? ve(rt, yt) : rt); - $[E] = Lt, j[E] = Lt - tt; + }, W = e.modifiersData["arrow#persistent"] ? e.modifiersData["arrow#persistent"].padding : vs(), X = W[J], Y = W[q], G = un(0, z[U], V[U]), K = R ? z[U] / 2 - y - G - X - P.mainAxis : O - G - X - P.mainAxis, Z = R ? -z[U] / 2 + y + G + Y + P.mainAxis : L + G + Y + P.mainAxis, dt = e.elements.arrow && Pn(e.elements.arrow), I = dt ? S === "y" ? dt.clientTop || 0 : dt.clientLeft || 0 : 0, xt = (M = E == null ? void 0 : E[S]) != null ? M : 0, B = tt + K - xt - I, yt = tt + Z - xt, Lt = un(g ? Jn(at, B) : at, tt, g ? ve(rt, yt) : rt); + $[S] = Lt, j[S] = Lt - tt; } if (l) { - var ce, Et = E === "x" ? Tt : Ct, In = E === "x" ? Bt : Vt, Ft = $[b], Ee = b === "y" ? "height" : "width", de = Ft + h[Et], Se = Ft - h[In], Te = [Tt, Ct].indexOf(S) !== -1, Ce = (ce = k == null ? void 0 : k[b]) != null ? ce : 0, pe = Te ? de : Ft - z[Ee] - H[Ee] - Ce + P.altAxis, We = Te ? Ft + z[Ee] + H[Ee] - Ce - P.altAxis : Se, An = g && Te ? qw(pe, Ft, We) : un(g ? pe : de, Ft, g ? We : Se); + var ce, Et = S === "x" ? Tt : Ct, In = S === "x" ? Bt : Vt, Ft = $[b], Ee = b === "y" ? "height" : "width", de = Ft + h[Et], Se = Ft - h[In], Te = [Tt, Ct].indexOf(k) !== -1, Ce = (ce = E == null ? void 0 : E[b]) != null ? ce : 0, pe = Te ? de : Ft - z[Ee] - H[Ee] - Ce + P.altAxis, We = Te ? Ft + z[Ee] + H[Ee] - Ce - P.altAxis : Se, An = g && Te ? qw(pe, Ft, We) : un(g ? pe : de, Ft, g ? We : Se); $[b] = An, j[b] = An - Ft; } e.modifiersData[r] = j; @@ -7571,15 +7572,15 @@ function Df(t) { styles: {} }, f = [], w = !1, g = { state: p, - setOptions: function(S) { - var A = typeof S == "function" ? S(p.options) : S; + setOptions: function(k) { + var A = typeof k == "function" ? k(p.options) : k; m(), p.options = Object.assign({}, a, p.options, A), p.scrollParents = { reference: ke(l) ? wn(l) : l.contextElement ? wn(l.contextElement) : [], popper: wn(c) }; var R = If(Mf([].concat(r, p.options.modifiers))); - return p.orderedModifiers = R.filter(function(E) { - return E.enabled; + return p.orderedModifiers = R.filter(function(S) { + return S.enabled; }), v(), g.update(); }, // Sync update – it will always be executed, even if not necessary. This @@ -7589,7 +7590,7 @@ function Df(t) { // prefer the async Popper#update method forceUpdate: function() { if (!w) { - var S = p.elements, A = S.reference, R = S.popper; + var k = p.elements, A = k.reference, R = k.popper; if (Ga(A, R)) { p.rects = { reference: Pf(A, Pn(R), p.options.strategy === "fixed"), @@ -7597,12 +7598,12 @@ function Df(t) { }, p.reset = !1, p.placement = p.options.placement, p.orderedModifiers.forEach(function(P) { return p.modifiersData[P.name] = Object.assign({}, P.data); }); - for (var E = 0; E < p.orderedModifiers.length; E++) { + for (var S = 0; S < p.orderedModifiers.length; S++) { if (p.reset === !0) { - p.reset = !1, E = -1; + p.reset = !1, S = -1; continue; } - var b = p.orderedModifiers[E], $ = b.fn, z = b.options, H = z === void 0 ? {} : z, C = b.name; + var b = p.orderedModifiers[S], $ = b.fn, z = b.options, H = z === void 0 ? {} : z, C = b.name; typeof $ == "function" && (p = $({ state: p, options: H, @@ -7631,11 +7632,11 @@ function Df(t) { }); function v() { p.orderedModifiers.forEach(function(h) { - var S = h.name, A = h.options, R = A === void 0 ? {} : A, E = h.effect; - if (typeof E == "function") { - var b = E({ + var k = h.name, A = h.options, R = A === void 0 ? {} : A, S = h.effect; + if (typeof S == "function") { + var b = S({ state: p, - name: S, + name: k, instance: g, options: R }), $ = function() { @@ -7705,10 +7706,10 @@ const Gf = () => yo({ TransitionProps: m // @ts-ignore internal logic // prevent from spreading to DOM, it can come from the parent component e.g. Select. - } = e, h = Nt(e, zf), S = D.useRef(null), A = xe(S, n), R = D.useRef(null), E = xe(R, w), b = D.useRef(E); + } = e, h = Nt(e, zf), k = D.useRef(null), A = xe(k, n), R = D.useRef(null), S = xe(R, w), b = D.useRef(S); ze(() => { - b.current = E; - }, [E]), D.useImperativeHandle(w, () => R.current, []); + b.current = S; + }, [S]), D.useImperativeHandle(w, () => R.current, []); const $ = Ff(p, i), [z, H] = D.useState($), [C, P] = D.useState(Zn(o)); D.useEffect(() => { R.current && R.current.forceUpdate(); @@ -7746,7 +7747,7 @@ const Gf = () => yo({ } }]; c != null && (U = U.concat(c)), f && f.modifiers != null && (U = U.concat(f.modifiers)); - const tt = Bf(C, S.current, _({ + const tt = Bf(C, k.current, _({ placement: $ }, f, { modifiers: U @@ -7755,10 +7756,10 @@ const Gf = () => yo({ tt.destroy(), b.current(null); }; }, [C, l, c, d, f, $]); - const k = { + const E = { placement: z }; - m !== null && (k.TransitionProps = m); + m !== null && (E.TransitionProps = m); const j = Gf(), M = (r = v.root) != null ? r : "div", J = Cw({ elementType: M, externalSlotProps: g.root, @@ -7771,7 +7772,7 @@ const Gf = () => yo({ className: j.root }); return /* @__PURE__ */ s(M, _({}, J, { - children: typeof a == "function" ? a(k) : a + children: typeof a == "function" ? a(E) : a })); }), Ss = /* @__PURE__ */ D.forwardRef(function(e, n) { const { @@ -7789,11 +7790,11 @@ const Gf = () => yo({ style: v, transition: m = !1, slotProps: h = {}, - slots: S = {} - } = e, A = Nt(e, Lf), [R, E] = D.useState(!0), b = () => { - E(!1); + slots: k = {} + } = e, A = Nt(e, Lf), [R, S] = D.useState(!0), b = () => { + S(!1); }, $ = () => { - E(!0); + S(!0); }; if (!c && !p && (!m || R)) return null; @@ -7823,7 +7824,7 @@ const Gf = () => yo({ popperOptions: w, popperRef: g, slotProps: h, - slots: S + slots: k }, A, { style: _({ // Prevents scroll issue, waiting for Popper.js to add this style once initiated. @@ -8358,7 +8359,7 @@ const Qf = { timeout: m = "auto", // eslint-disable-next-line react/prop-types TransitionComponent: h = Kf - } = e, S = Nt(e, Zf), A = an(), R = D.useRef(), E = Ts(), b = D.useRef(null), $ = xe(b, a.ref, n), z = (q) => (U) => { + } = e, k = Nt(e, Zf), A = an(), R = D.useRef(), S = Ts(), b = D.useRef(null), $ = xe(b, a.ref, n), z = (q) => (U) => { if (q) { const tt = b.current; U === void 0 ? q(tt) : q(tt, U); @@ -8377,15 +8378,15 @@ const Qf = { mode: "enter" }); let y; - m === "auto" ? (y = E.transitions.getAutoHeightDuration(q.clientHeight), R.current = y) : y = tt, q.style.transition = [E.transitions.create("opacity", { + m === "auto" ? (y = S.transitions.getAutoHeightDuration(q.clientHeight), R.current = y) : y = tt, q.style.transition = [S.transitions.create("opacity", { duration: y, delay: at - }), E.transitions.create("transform", { + }), S.transitions.create("transform", { duration: Fr ? y : y * 0.666, delay: at, easing: rt })].join(","), c && c(q, U); - }), P = z(d), k = z(g), j = z((q) => { + }), P = z(d), E = z(g), j = z((q) => { const { duration: U, delay: tt, @@ -8398,10 +8399,10 @@ const Qf = { mode: "exit" }); let rt; - m === "auto" ? (rt = E.transitions.getAutoHeightDuration(q.clientHeight), R.current = rt) : rt = U, q.style.transition = [E.transitions.create("opacity", { + m === "auto" ? (rt = S.transitions.getAutoHeightDuration(q.clientHeight), R.current = rt) : rt = U, q.style.transition = [S.transitions.create("opacity", { duration: rt, delay: tt - }), E.transitions.create("transform", { + }), S.transitions.create("transform", { duration: Fr ? rt : rt * 0.666, delay: Fr ? tt : tt || rt * 0.333, easing: at @@ -8416,12 +8417,12 @@ const Qf = { onEntering: H, onExit: j, onExited: M, - onExiting: k, + onExiting: E, addEndListener: (q) => { m === "auto" && A.start(R.current || 0, q), r && r(b.current, q); }, timeout: m === "auto" ? null : m - }, S, { + }, k, { children: (q, U) => /* @__PURE__ */ D.cloneElement(a, _({ style: _({ opacity: 0, @@ -8528,10 +8529,10 @@ const Ya = Bo, tm = ["anchorEl", "component", "components", "componentsProps", " open: v, placement: m, popperOptions: h, - popperRef: S, + popperRef: k, transition: A, slots: R, - slotProps: E + slotProps: S } = a, b = Nt(a, tm), $ = (r = R == null ? void 0 : R.root) != null ? r : c == null ? void 0 : c.Root, z = _({ anchorEl: i, container: p, @@ -8541,7 +8542,7 @@ const Ya = Bo, tm = ["anchorEl", "component", "components", "componentsProps", " open: v, placement: m, popperOptions: h, - popperRef: S, + popperRef: k, transition: A }, b); return /* @__PURE__ */ s(em, _({ @@ -8550,7 +8551,7 @@ const Ya = Bo, tm = ["anchorEl", "component", "components", "componentsProps", " slots: { root: $ }, - slotProps: E ?? d + slotProps: S ?? d }, z, { ref: n })); @@ -8865,7 +8866,7 @@ function Fn(t, e) { }; } const _s = /* @__PURE__ */ D.forwardRef(function(e, n) { - var r, o, a, i, l, c, d, p, f, w, g, v, m, h, S, A, R, E, b; + var r, o, a, i, l, c, d, p, f, w, g, v, m, h, k, A, R, S, b; const $ = Ro({ props: e, name: "MuiTooltip" @@ -8874,7 +8875,7 @@ const _s = /* @__PURE__ */ D.forwardRef(function(e, n) { children: H, components: C = {}, componentsProps: P = {}, - describeChild: k = !1, + describeChild: E = !1, disableFocusListener: j = !1, disableHoverListener: M = !1, disableInteractive: J = !1, @@ -8981,7 +8982,7 @@ const _s = /* @__PURE__ */ D.forwardRef(function(e, n) { y: Q.clientY }, Sr.current && Sr.current.update(); }, Ke = {}, Tr = typeof dt == "string"; - k ? (Ke.title = !Kt && Tr && !M ? dt : null, Ke["aria-describedby"] = Kt ? kr : null) : (Ke["aria-label"] = Tr ? dt : null, Ke["aria-labelledby"] = Kt && !Tr ? kr : null); + E ? (Ke.title = !Kt && Tr && !M ? dt : null, Ke["aria-describedby"] = Kt ? kr : null) : (Ke["aria-label"] = Tr ? dt : null, Ke["aria-labelledby"] = Kt && !Tr ? kr : null); const Mt = _({}, Ke, B, yt.props, { className: be(B.className, yt.props.className), onTouchStart: Xo, @@ -9019,9 +9020,9 @@ const _s = /* @__PURE__ */ D.forwardRef(function(e, n) { }), Cr = im(Ze), qo = (r = (o = Z.popper) != null ? o : C.Popper) != null ? r : sm, Ko = (a = (i = (l = Z.transition) != null ? l : C.Transition) != null ? i : I) != null ? a : Ya, Jo = (c = (d = Z.tooltip) != null ? d : C.Tooltip) != null ? c : lm, Zo = (p = (f = Z.arrow) != null ? f : C.Arrow) != null ? p : cm, Fs = sn(qo, _({}, G, (w = K.popper) != null ? w : P.popper, { className: be(Cr.popper, G == null ? void 0 : G.className, (g = (v = K.popper) != null ? v : P.popper) == null ? void 0 : g.className) }), Ze), Us = sn(Ko, _({}, xt, (m = K.transition) != null ? m : P.transition), Ze), Gs = sn(Jo, _({}, (h = K.tooltip) != null ? h : P.tooltip, { - className: be(Cr.tooltip, (S = (A = K.tooltip) != null ? A : P.tooltip) == null ? void 0 : S.className) + className: be(Cr.tooltip, (k = (A = K.tooltip) != null ? A : P.tooltip) == null ? void 0 : k.className) }), Ze), Hs = sn(Zo, _({}, (R = K.arrow) != null ? R : P.arrow, { - className: be(Cr.arrow, (E = (b = K.arrow) != null ? b : P.arrow) == null ? void 0 : E.className) + className: be(Cr.arrow, (S = (b = K.arrow) != null ? b : P.arrow) == null ? void 0 : S.className) }), Ze); return /* @__PURE__ */ x(D.Fragment, { children: [/* @__PURE__ */ D.cloneElement(yt, Mt), /* @__PURE__ */ s(qo, _({ @@ -9272,7 +9273,7 @@ function Ps(t) { focusVisibleClassName: v, id: m, children: h - } = t, S = /* @__PURE__ */ s( + } = t, k = /* @__PURE__ */ s( Al, { sx: { lineHeight: 0.8 }, @@ -9292,7 +9293,7 @@ function Ps(t) { ] }) : h } ); - return r ? /* @__PURE__ */ s(dm, { title: r, placement: "right", children: /* @__PURE__ */ s("div", { children: S }) }) : S; + return r ? /* @__PURE__ */ s(dm, { title: r, placement: "right", children: /* @__PURE__ */ s("div", { children: k }) }) : k; } function $s(t) { return Object.entries(t.groups).map(([n, r]) => ({ id: n, group: r })); @@ -9509,31 +9510,31 @@ function bm({ }) { const [c, d] = ut(!1), [p, f] = ut(!1), w = kt(() => { c && d(!1), f(!1); - }, [c]), g = kt((E) => { - E.stopPropagation(), d((b) => { + }, [c]), g = kt((S) => { + S.stopPropagation(), d((b) => { const $ = !b; - return $ && E.shiftKey ? f(!0) : $ || f(!1), $; + return $ && S.shiftKey ? f(!0) : $ || f(!1), $; }); }, []), v = kt( - (E) => (w(), r(E)), + (S) => (w(), r(S)), [r, w] ), [m, h] = ut({ top: 1, left: 1 }); ae(() => { if (c) { - const E = o == null ? void 0 : o.current; - if (E) { - const b = E.getBoundingClientRect(), $ = window.scrollY, z = window.scrollX, H = b.top + $ + E.clientHeight, C = b.left + z; + const S = o == null ? void 0 : o.current; + if (S) { + const b = S.getBoundingClientRect(), $ = window.scrollY, z = window.scrollX, H = b.top + $ + S.clientHeight, C = b.left + z; h({ top: H, left: C }); } } }, [c, o]); - const [S] = so( + const [k] = so( kt(async () => (t == null ? void 0 : t(!1)) ?? e, [t, e, c]), e ), [A] = so( - kt(async () => (t == null ? void 0 : t(!0)) ?? n ?? S, [t, n, S, c]), - n ?? S - ), R = p && A ? A : S; + kt(async () => (t == null ? void 0 : t(!0)) ?? n ?? k, [t, n, k, c]), + n ?? k + ), R = p && A ? A : k; return /* @__PURE__ */ x(ie, { children: [ /* @__PURE__ */ s( ii, @@ -12654,7 +12655,7 @@ video:where(.pr-twp,.pr-twp *) { animation-timing-function: linear; } -/* #region shared with https://github.com/paranext/paranext-extension-template/blob/main/tailwind.css */ +/* #region shared with https://github.com/paranext/paranext-extension-template/blob/main/src/tailwind.css */ /* #endregion */ @@ -13650,12 +13651,31 @@ video:where(.pr-twp,.pr-twp *) { [data-side=right] .\\[\\[data-side\\=right\\]_\\&\\]\\:tw-cursor-e-resize { cursor: e-resize; } -.banded-row:hover { +.papi-icon-button { + border: 0; + border-radius: 3em; cursor: pointer; + display: inline-block; } -.banded-row[data-state='selected']:hover { - cursor: default; +.papi-icon-button.primary { + background-color: #1ea7fd; + color: white; +} + +.papi-icon-button.secondary { + background-color: transparent; + color: #333; +} + +.papi-icon-button.paratext { + background-color: darkgreen; + color: greenyellow; +} + +.papi-icon-button.paratext.bright { + background-color: greenyellow; + color: darkgreen; } .papi-multi-column-menu { background-color: rgb(222, 222, 222); @@ -13691,31 +13711,22 @@ video:where(.pr-twp,.pr-twp *) { color: rgb(76, 106, 76); background-color: rgb(214, 255, 152); } -.papi-icon-button { - border: 0; - border-radius: 3em; +.banded-row:hover { cursor: pointer; - display: inline-block; } -.papi-icon-button.primary { - background-color: #1ea7fd; - color: white; -} - -.papi-icon-button.secondary { - background-color: transparent; - color: #333; +.banded-row[data-state='selected']:hover { + cursor: default; } - -.papi-icon-button.paratext { - background-color: darkgreen; - color: greenyellow; +.papi-menu-drawer-paper { + height: fit-content !important; + position: absolute !important; } -.papi-icon-button.paratext.bright { - background-color: greenyellow; - color: darkgreen; +.papi-toolbar-children { + padding: 10px; + display: flex; + gap: 8px; } .papi-menu-item { background-color: transparent; @@ -13730,16 +13741,6 @@ video:where(.pr-twp,.pr-twp *) { max-width: 24px; max-height: 24px; } -.papi-menu-drawer-paper { - height: fit-content !important; - position: absolute !important; -} - -.papi-toolbar-children { - padding: 10px; - display: flex; - gap: 8px; -} `, "top"); export { ym as Alert, diff --git a/lib/platform-bible-react/dist/index.js.map b/lib/platform-bible-react/dist/index.js.map index 4ef8862605..a8fb0d8c95 100644 --- a/lib/platform-bible-react/dist/index.js.map +++ b/lib/platform-bible-react/dist/index.js.map @@ -1 +1 @@ -{"version":3,"file":"index.js","sources":["../src/utils/shadcn-ui.util.ts","../src/components/shadcn-ui/input.tsx","../src/components/advanced/book-chapter-control/book-chapter-input.component.tsx","../../../node_modules/@sillsdev/scripture/dist/index.es.js","../src/components/shadcn-ui/dropdown-menu.tsx","../src/components/advanced/book-chapter-control/book-menu-item.component.tsx","../src/components/advanced/book-chapter-control/chapter-select.component.tsx","../src/components/advanced/book-chapter-control/go-to-menu-item.component.tsx","../src/components/advanced/book-chapter-control/book-chapter-control.component.tsx","../src/components/shadcn-ui/button.tsx","../src/components/shadcn-ui/label.tsx","../src/components/shadcn-ui/radio-group.tsx","../src/components/shadcn-ui/popover.tsx","../src/components/shadcn-ui/dialog.tsx","../src/components/shadcn-ui/command.tsx","../src/components/basics/combo-box.component.tsx","../src/components/basics/chapter-range-selector.component.tsx","../src/components/advanced/book-selector.component.tsx","../src/components/advanced/data-table/data-table-column-toggle.component.tsx","../src/components/shadcn-ui/select.tsx","../src/components/advanced/data-table/data-table-pagination.component.tsx","../src/components/shadcn-ui/table.tsx","../src/components/advanced/data-table/data-table.component.tsx","../src/components/advanced/inventory/occurrences-table.component.tsx","../src/components/shadcn-ui/checkbox.tsx","../src/components/advanced/inventory/inventory-utils.ts","../src/components/shadcn-ui/toggle.tsx","../src/components/shadcn-ui/toggle-group.tsx","../src/components/advanced/inventory/inventory-columns.tsx","../src/components/advanced/inventory/inventory.component.tsx","../src/components/basics/search-bar.component.tsx","../src/components/basics/tabs-vertical.tsx","../src/components/advanced/tab-navigation-content-search.component.tsx","../src/components/shadcn-ui/separator.tsx","../src/components/shadcn-ui/skeleton.tsx","../src/components/shadcn-ui/tooltip.tsx","../src/components/shadcn-ui/sidebar.tsx","../src/components/advanced/settings-components/settings-sidebar.component.tsx","../src/components/advanced/settings-components/settings-sidebar-content-search.component.tsx","../src/components/advanced/scripture-results-viewer/scripture-results-viewer.component.tsx","../src/components/advanced/scroll-group-selector.component.tsx","../src/components/advanced/settings-components/settings-list.component.tsx","../src/components/basics/checklist.component.tsx","../../../node_modules/@babel/runtime/helpers/interopRequireDefault.js","../../../node_modules/@mui/utils/chainPropTypes/chainPropTypes.js","../../../node_modules/@babel/runtime/helpers/esm/extends.js","../../../node_modules/@mui/utils/deepmerge/deepmerge.js","../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.production.min.js","../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.development.js","../../../node_modules/prop-types/node_modules/react-is/index.js","../../../node_modules/object-assign/index.js","../../../node_modules/prop-types/lib/ReactPropTypesSecret.js","../../../node_modules/prop-types/lib/has.js","../../../node_modules/prop-types/checkPropTypes.js","../../../node_modules/prop-types/factoryWithTypeCheckers.js","../../../node_modules/prop-types/factoryWithThrowingShims.js","../../../node_modules/prop-types/index.js","../../../node_modules/@mui/utils/elementAcceptingRef/elementAcceptingRef.js","../../../node_modules/@mui/utils/exactProp/exactProp.js","../../../node_modules/@mui/utils/formatMuiErrorMessage/formatMuiErrorMessage.js","../../../node_modules/react-is/cjs/react-is.production.min.js","../../../node_modules/react-is/cjs/react-is.development.js","../../../node_modules/react-is/index.js","../../../node_modules/@mui/utils/getDisplayName/getDisplayName.js","../../../node_modules/@mui/utils/HTMLElementType/HTMLElementType.js","../../../node_modules/@mui/utils/refType/refType.js","../../../node_modules/@mui/utils/capitalize/capitalize.js","../../../node_modules/@mui/utils/createChainedFunction/createChainedFunction.js","../../../node_modules/@mui/utils/debounce/debounce.js","../../../node_modules/@mui/utils/deprecatedPropType/deprecatedPropType.js","../../../node_modules/@mui/utils/isMuiElement/isMuiElement.js","../../../node_modules/@mui/utils/ownerDocument/ownerDocument.js","../../../node_modules/@mui/utils/ownerWindow/ownerWindow.js","../../../node_modules/@mui/utils/requirePropFactory/requirePropFactory.js","../../../node_modules/@mui/utils/setRef/setRef.js","../../../node_modules/@mui/utils/useEnhancedEffect/useEnhancedEffect.js","../../../node_modules/@mui/utils/useId/useId.js","../../../node_modules/@mui/utils/unsupportedProp/unsupportedProp.js","../../../node_modules/@mui/utils/useControlled/useControlled.js","../../../node_modules/@mui/utils/useEventCallback/useEventCallback.js","../../../node_modules/@mui/utils/useForkRef/useForkRef.js","../../../node_modules/@mui/utils/useLazyRef/useLazyRef.js","../../../node_modules/@mui/utils/useOnMount/useOnMount.js","../../../node_modules/@mui/utils/useTimeout/useTimeout.js","../../../node_modules/@mui/utils/useIsFocusVisible/useIsFocusVisible.js","../../../node_modules/@mui/utils/resolveProps/resolveProps.js","../../../node_modules/@mui/utils/composeClasses/composeClasses.js","../../../node_modules/@mui/utils/ClassNameGenerator/ClassNameGenerator.js","../../../node_modules/@mui/utils/generateUtilityClass/generateUtilityClass.js","../../../node_modules/@mui/utils/generateUtilityClasses/generateUtilityClasses.js","../../../node_modules/@mui/utils/clamp/clamp.js","../../../node_modules/@babel/runtime/helpers/esm/objectWithoutPropertiesLoose.js","../../../node_modules/@mui/system/esm/createTheme/createBreakpoints.js","../../../node_modules/@mui/system/esm/createTheme/shape.js","../../../node_modules/@mui/system/esm/responsivePropType.js","../../../node_modules/@mui/system/esm/merge.js","../../../node_modules/@mui/system/esm/breakpoints.js","../../../node_modules/@mui/system/esm/style.js","../../../node_modules/@mui/system/esm/memoize.js","../../../node_modules/@mui/system/esm/spacing.js","../../../node_modules/@mui/system/esm/createTheme/createSpacing.js","../../../node_modules/@mui/system/esm/compose.js","../../../node_modules/@mui/system/esm/borders.js","../../../node_modules/@mui/system/esm/cssGrid.js","../../../node_modules/@mui/system/esm/palette.js","../../../node_modules/@mui/system/esm/sizing.js","../../../node_modules/@mui/system/esm/styleFunctionSx/defaultSxConfig.js","../../../node_modules/@mui/system/esm/styleFunctionSx/styleFunctionSx.js","../../../node_modules/@mui/system/esm/createTheme/applyStyles.js","../../../node_modules/@mui/system/esm/createTheme/createTheme.js","../../../node_modules/@mui/system/esm/useThemeWithoutDefault.js","../../../node_modules/@mui/system/esm/useTheme.js","../../../node_modules/@mui/system/esm/createStyled.js","../../../node_modules/@mui/system/esm/useThemeProps/getThemeProps.js","../../../node_modules/@mui/system/esm/useThemeProps/useThemeProps.js","../../../node_modules/@mui/system/esm/colorManipulator.js","../../../node_modules/@mui/material/styles/createMixins.js","../../../node_modules/@mui/material/colors/common.js","../../../node_modules/@mui/material/colors/grey.js","../../../node_modules/@mui/material/colors/purple.js","../../../node_modules/@mui/material/colors/red.js","../../../node_modules/@mui/material/colors/orange.js","../../../node_modules/@mui/material/colors/blue.js","../../../node_modules/@mui/material/colors/lightBlue.js","../../../node_modules/@mui/material/colors/green.js","../../../node_modules/@mui/material/styles/createPalette.js","../../../node_modules/@mui/material/styles/createTypography.js","../../../node_modules/@mui/material/styles/shadows.js","../../../node_modules/@mui/material/styles/createTransitions.js","../../../node_modules/@mui/material/styles/zIndex.js","../../../node_modules/@mui/material/styles/createTheme.js","../../../node_modules/@mui/material/styles/defaultTheme.js","../../../node_modules/@mui/material/styles/identifier.js","../../../node_modules/@mui/material/styles/useThemeProps.js","../../../node_modules/@mui/material/styles/styled.js","../../../node_modules/@mui/material/SvgIcon/svgIconClasses.js","../../../node_modules/@mui/material/SvgIcon/SvgIcon.js","../../../node_modules/@mui/material/utils/createSvgIcon.js","../../../node_modules/@mui/material/utils/index.js","../../../node_modules/@mui/icons-material/utils/createSvgIcon.js","../../../node_modules/@mui/icons-material/ArrowRight.js","../../../node_modules/@mui/base/utils/isHostComponent.js","../../../node_modules/@mui/base/utils/appendOwnerState.js","../../../node_modules/@mui/base/utils/ClassNameConfigurator.js","../../../node_modules/@mui/base/utils/extractEventHandlers.js","../../../node_modules/@mui/base/utils/resolveComponentProps.js","../../../node_modules/@mui/base/utils/omitEventHandlers.js","../../../node_modules/@mui/base/utils/mergeSlotProps.js","../../../node_modules/@mui/base/utils/useSlotProps.js","../../../node_modules/@mui/base/generateUtilityClass/index.js","../../../node_modules/@mui/base/generateUtilityClasses/index.js","../../../node_modules/@mui/base/Portal/Portal.js","../../../node_modules/@popperjs/core/lib/enums.js","../../../node_modules/@popperjs/core/lib/dom-utils/getNodeName.js","../../../node_modules/@popperjs/core/lib/dom-utils/getWindow.js","../../../node_modules/@popperjs/core/lib/dom-utils/instanceOf.js","../../../node_modules/@popperjs/core/lib/modifiers/applyStyles.js","../../../node_modules/@popperjs/core/lib/utils/getBasePlacement.js","../../../node_modules/@popperjs/core/lib/utils/math.js","../../../node_modules/@popperjs/core/lib/utils/userAgent.js","../../../node_modules/@popperjs/core/lib/dom-utils/isLayoutViewport.js","../../../node_modules/@popperjs/core/lib/dom-utils/getBoundingClientRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/getLayoutRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/contains.js","../../../node_modules/@popperjs/core/lib/dom-utils/getComputedStyle.js","../../../node_modules/@popperjs/core/lib/dom-utils/isTableElement.js","../../../node_modules/@popperjs/core/lib/dom-utils/getDocumentElement.js","../../../node_modules/@popperjs/core/lib/dom-utils/getParentNode.js","../../../node_modules/@popperjs/core/lib/dom-utils/getOffsetParent.js","../../../node_modules/@popperjs/core/lib/utils/getMainAxisFromPlacement.js","../../../node_modules/@popperjs/core/lib/utils/within.js","../../../node_modules/@popperjs/core/lib/utils/getFreshSideObject.js","../../../node_modules/@popperjs/core/lib/utils/mergePaddingObject.js","../../../node_modules/@popperjs/core/lib/utils/expandToHashMap.js","../../../node_modules/@popperjs/core/lib/modifiers/arrow.js","../../../node_modules/@popperjs/core/lib/utils/getVariation.js","../../../node_modules/@popperjs/core/lib/modifiers/computeStyles.js","../../../node_modules/@popperjs/core/lib/modifiers/eventListeners.js","../../../node_modules/@popperjs/core/lib/utils/getOppositePlacement.js","../../../node_modules/@popperjs/core/lib/utils/getOppositeVariationPlacement.js","../../../node_modules/@popperjs/core/lib/dom-utils/getWindowScroll.js","../../../node_modules/@popperjs/core/lib/dom-utils/getWindowScrollBarX.js","../../../node_modules/@popperjs/core/lib/dom-utils/getViewportRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/getDocumentRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/isScrollParent.js","../../../node_modules/@popperjs/core/lib/dom-utils/getScrollParent.js","../../../node_modules/@popperjs/core/lib/dom-utils/listScrollParents.js","../../../node_modules/@popperjs/core/lib/utils/rectToClientRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/getClippingRect.js","../../../node_modules/@popperjs/core/lib/utils/computeOffsets.js","../../../node_modules/@popperjs/core/lib/utils/detectOverflow.js","../../../node_modules/@popperjs/core/lib/utils/computeAutoPlacement.js","../../../node_modules/@popperjs/core/lib/modifiers/flip.js","../../../node_modules/@popperjs/core/lib/modifiers/hide.js","../../../node_modules/@popperjs/core/lib/modifiers/offset.js","../../../node_modules/@popperjs/core/lib/modifiers/popperOffsets.js","../../../node_modules/@popperjs/core/lib/utils/getAltAxis.js","../../../node_modules/@popperjs/core/lib/modifiers/preventOverflow.js","../../../node_modules/@popperjs/core/lib/dom-utils/getHTMLElementScroll.js","../../../node_modules/@popperjs/core/lib/dom-utils/getNodeScroll.js","../../../node_modules/@popperjs/core/lib/dom-utils/getCompositeRect.js","../../../node_modules/@popperjs/core/lib/utils/orderModifiers.js","../../../node_modules/@popperjs/core/lib/utils/debounce.js","../../../node_modules/@popperjs/core/lib/utils/mergeByName.js","../../../node_modules/@popperjs/core/lib/createPopper.js","../../../node_modules/@popperjs/core/lib/popper.js","../../../node_modules/@mui/base/Popper/popperClasses.js","../../../node_modules/@mui/base/Popper/Popper.js","../../../node_modules/@mui/material/styles/useTheme.js","../../../node_modules/@babel/runtime/helpers/esm/setPrototypeOf.js","../../../node_modules/@babel/runtime/helpers/esm/inheritsLoose.js","../../../node_modules/react-transition-group/esm/config.js","../../../node_modules/react-transition-group/esm/utils/PropTypes.js","../../../node_modules/react-transition-group/esm/TransitionGroupContext.js","../../../node_modules/react-transition-group/esm/utils/reflow.js","../../../node_modules/react-transition-group/esm/Transition.js","../../../node_modules/@mui/material/transitions/utils.js","../../../node_modules/@mui/material/Grow/Grow.js","../../../node_modules/@mui/material/Popper/Popper.js","../../../node_modules/@mui/material/Tooltip/tooltipClasses.js","../../../node_modules/@mui/material/Tooltip/Tooltip.js","../src/components/mui/menu-item.component.tsx","../src/components/mui/grouped-menu-item-list.component.tsx","../src/components/mui/top-level-menu.component.tsx","../src/components/mui/grid-menu.component.tsx","../src/hooks/use-promise.hook.ts","../../../node_modules/@mui/icons-material/esm/Menu.js","../src/components/mui/hamburger-menu-button.component.tsx","../src/components/mui/icon-button.component.tsx","../src/components/basics/spinner.component.tsx","../src/components/basics/text-field.component.tsx","../src/components/mui/toolbar.component.tsx","../src/components/shadcn-ui/alert.tsx","../src/components/shadcn-ui/card.tsx","../src/components/shadcn-ui/sonner.tsx","../src/components/shadcn-ui/slider.tsx","../src/components/shadcn-ui/switch.tsx","../src/components/shadcn-ui/tabs.tsx","../src/components/advanced/extension-marketplace/buttons/install-button.component.tsx","../src/components/advanced/extension-marketplace/buttons/enable-button.component.tsx","../src/components/advanced/extension-marketplace/buttons/disable-button.component.tsx","../src/components/advanced/extension-marketplace/buttons/update-button.component.tsx","../src/components/advanced/extension-marketplace/markdown-renderer.component.tsx","../src/components/advanced/extension-marketplace/buttons/filter-button.component.tsx","../src/components/advanced/extension-marketplace/filter-dropdown.component.tsx","../src/components/advanced/extension-marketplace/no-extensions-found.component.tsx","../src/components/advanced/extension-marketplace/more-info.component.tsx","../src/components/advanced/extension-marketplace/version-history.component.tsx","../src/components/advanced/extension-marketplace/footer.component.tsx","../src/hooks/use-event.hook.ts","../src/hooks/use-event-async.hook.ts"],"sourcesContent":["import { type ClassValue, clsx } from 'clsx';\nimport { extendTailwindMerge } from 'tailwind-merge';\n\nconst twMergeCustom = extendTailwindMerge({ prefix: 'tw-' });\n\n/**\n * Tailwind and CSS class application helper function. Uses\n * [`clsx`](https://www.npmjs.com/package/clsx) to make it easy to apply classes conditionally using\n * object syntax, and uses [`tailwind-merge`](https://www.npmjs.com/package/tailwind-merge) to make\n * it easy to merge/overwrite Tailwind classes in a programmer-logic-friendly way.\n *\n * Note: `tailwind-merge` is configured to use the prefix `tw-`, so you must use the same prefix\n * with any Tailwind classes you use with this function to successfully overwrite other Tailwind\n * classes. `platform-bible-react` is configured to use `tw-` as its Tailwind prefix, so any\n * Tailwind classes you pass into `platform-bible-react` components will be compared using the `tw-`\n * prefix.\n *\n * This function was popularized by\n * [shadcn/ui](https://ui.shadcn.com/docs/installation/manual#add-a-cn-helper). See [ByteGrad's\n * explanation video](https://www.youtube.com/watch?v=re2JFITR7TI) for more information.\n *\n * @example\n *\n * ```typescript\n * const borderShouldBeBlue = true;\n * const textShouldBeRed = true;\n * const heightShouldBe20 = false;\n * const classString = cn(\n * 'tw-bg-primary tw-h-10 tw-text-primary-foreground',\n * 'tw-bg-secondary',\n * {\n * 'tw-border-blue-500': borderShouldBeBlue,\n * 'tw-text-red-500': textShouldBeRed,\n * 'tw-h-20': heightShouldBe20,\n * },\n * 'some-class',\n * );\n * ```\n *\n * The resulting `classString` is `'tw-h-10 tw-bg-secondary tw-border-blue-500 tw-text-red-500\n * some-class'`\n *\n * - Notice that `'tw-bg-secondary'`, specified later, overwrote `'tw-bg-primary'`, specified earlier,\n * because they are Tailwind classes that affect the same css property\n * - Notice that `'tw-text-red-500'`, specified later, overwrote `'tw-text-primary-foreground'`,\n * specified earlier, because they are Tailwind classes that affect the same css property\n * - Notice that `'tw-h-20'`, specified later, did not overwrite `'tw-h-10'`, specified earlier,\n * because `'tw-h-20'` is part of a conditional class object and its value evaluated to `false`;\n * therefore it was not applied\n * - Notice that `'some-class'` was applied. This function is not limited only to Tailwind classes.\n *\n *\n * @param inputs Class strings or `clsx` conditional class objects to merge. Tailwind classes\n * specified later in the arguments overwrite similar Tailwind classes specified earlier in the\n * arguments\n * @returns Class string containing all applicable classes from the arguments based on the rules\n * described above\n */\n// shadcn/ui uses this export in its boilerplate code\n// eslint-disable-next-line import/prefer-default-export\nexport function cn(...inputs: ClassValue[]) {\n return twMergeCustom(clsx(inputs));\n}\n","import React from 'react';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport interface InputProps extends React.InputHTMLAttributes {}\n\nexport const Input = React.forwardRef(\n ({ className, type, ...props }, ref) => {\n return (\n \n );\n },\n);\nInput.displayName = 'Input';\n","import { FocusEventHandler, forwardRef, KeyboardEvent, MouseEventHandler } from 'react';\nimport { History } from 'lucide-react';\nimport { Input as ShadInput } from '@/components/shadcn-ui/input';\n\nexport type BookChapterInputProps = {\n handleSearch: (searchString: string) => void;\n handleKeyDown: (event: KeyboardEvent) => void;\n handleOnClick: MouseEventHandler;\n handleSubmit: () => void;\n onFocus?: FocusEventHandler;\n value: string;\n placeholder: string;\n};\n\n// Shadcn Input sets type to \"button\"- HAVE to prop spread before setting type\nconst BookChapterInput = forwardRef(\n (\n { handleSearch, handleKeyDown, handleOnClick, handleSubmit, ...props }: BookChapterInputProps,\n ref,\n ) => {\n return (\n
    \n handleSearch(event.target.value)}\n onKeyDown={(e) => {\n if (e.key === 'Enter') {\n handleSubmit();\n }\n handleKeyDown(e);\n }}\n onClick={handleOnClick}\n ref={ref}\n />\n {\n // eslint-disable-next-line no-console\n console.log('back in history');\n }}\n />\n
    \n );\n },\n);\n\nexport default BookChapterInput;\n","var P = Object.defineProperty;\nvar R = (t, e, s) => e in t ? P(t, e, { enumerable: !0, configurable: !0, writable: !0, value: s }) : t[e] = s;\nvar n = (t, e, s) => R(t, typeof e != \"symbol\" ? e + \"\" : e, s);\nclass _ {\n constructor() {\n n(this, \"books\");\n n(this, \"firstSelectedBookNum\");\n n(this, \"lastSelectedBookNum\");\n n(this, \"count\");\n n(this, \"selectedBookNumbers\");\n n(this, \"selectedBookIds\");\n }\n}\nconst N = [\n \"GEN\",\n \"EXO\",\n \"LEV\",\n \"NUM\",\n \"DEU\",\n \"JOS\",\n \"JDG\",\n \"RUT\",\n \"1SA\",\n \"2SA\",\n // 10\n \"1KI\",\n \"2KI\",\n \"1CH\",\n \"2CH\",\n \"EZR\",\n \"NEH\",\n \"EST\",\n \"JOB\",\n \"PSA\",\n \"PRO\",\n // 20\n \"ECC\",\n \"SNG\",\n \"ISA\",\n \"JER\",\n \"LAM\",\n \"EZK\",\n \"DAN\",\n \"HOS\",\n \"JOL\",\n \"AMO\",\n // 30\n \"OBA\",\n \"JON\",\n \"MIC\",\n \"NAM\",\n \"HAB\",\n \"ZEP\",\n \"HAG\",\n \"ZEC\",\n \"MAL\",\n \"MAT\",\n // 40\n \"MRK\",\n \"LUK\",\n \"JHN\",\n \"ACT\",\n \"ROM\",\n \"1CO\",\n \"2CO\",\n \"GAL\",\n \"EPH\",\n \"PHP\",\n // 50\n \"COL\",\n \"1TH\",\n \"2TH\",\n \"1TI\",\n \"2TI\",\n \"TIT\",\n \"PHM\",\n \"HEB\",\n \"JAS\",\n \"1PE\",\n // 60\n \"2PE\",\n \"1JN\",\n \"2JN\",\n \"3JN\",\n \"JUD\",\n \"REV\",\n \"TOB\",\n \"JDT\",\n \"ESG\",\n \"WIS\",\n // 70\n \"SIR\",\n \"BAR\",\n \"LJE\",\n \"S3Y\",\n \"SUS\",\n \"BEL\",\n \"1MA\",\n \"2MA\",\n \"3MA\",\n \"4MA\",\n // 80\n \"1ES\",\n \"2ES\",\n \"MAN\",\n \"PS2\",\n \"ODA\",\n \"PSS\",\n \"JSA\",\n // actual variant text for JOS, now in LXA text\n \"JDB\",\n // actual variant text for JDG, now in LXA text\n \"TBS\",\n // actual variant text for TOB, now in LXA text\n \"SST\",\n // actual variant text for SUS, now in LXA text // 90\n \"DNT\",\n // actual variant text for DAN, now in LXA text\n \"BLT\",\n // actual variant text for BEL, now in LXA text\n \"XXA\",\n \"XXB\",\n \"XXC\",\n \"XXD\",\n \"XXE\",\n \"XXF\",\n \"XXG\",\n \"FRT\",\n // 100\n \"BAK\",\n \"OTH\",\n \"3ES\",\n // Used previously but really should be 2ES\n \"EZA\",\n // Used to be called 4ES, but not actually in any known project\n \"5EZ\",\n // Used to be called 5ES, but not actually in any known project\n \"6EZ\",\n // Used to be called 6ES, but not actually in any known project\n \"INT\",\n \"CNC\",\n \"GLO\",\n \"TDX\",\n // 110\n \"NDX\",\n \"DAG\",\n \"PS3\",\n \"2BA\",\n \"LBA\",\n \"JUB\",\n \"ENO\",\n \"1MQ\",\n \"2MQ\",\n \"3MQ\",\n // 120\n \"REP\",\n \"4BA\",\n \"LAO\"\n], B = [\n \"XXA\",\n \"XXB\",\n \"XXC\",\n \"XXD\",\n \"XXE\",\n \"XXF\",\n \"XXG\",\n \"FRT\",\n \"BAK\",\n \"OTH\",\n \"INT\",\n \"CNC\",\n \"GLO\",\n \"TDX\",\n \"NDX\"\n], O = [\n \"Genesis\",\n \"Exodus\",\n \"Leviticus\",\n \"Numbers\",\n \"Deuteronomy\",\n \"Joshua\",\n \"Judges\",\n \"Ruth\",\n \"1 Samuel\",\n \"2 Samuel\",\n \"1 Kings\",\n \"2 Kings\",\n \"1 Chronicles\",\n \"2 Chronicles\",\n \"Ezra\",\n \"Nehemiah\",\n \"Esther (Hebrew)\",\n \"Job\",\n \"Psalms\",\n \"Proverbs\",\n \"Ecclesiastes\",\n \"Song of Songs\",\n \"Isaiah\",\n \"Jeremiah\",\n \"Lamentations\",\n \"Ezekiel\",\n \"Daniel (Hebrew)\",\n \"Hosea\",\n \"Joel\",\n \"Amos\",\n \"Obadiah\",\n \"Jonah\",\n \"Micah\",\n \"Nahum\",\n \"Habakkuk\",\n \"Zephaniah\",\n \"Haggai\",\n \"Zechariah\",\n \"Malachi\",\n \"Matthew\",\n \"Mark\",\n \"Luke\",\n \"John\",\n \"Acts\",\n \"Romans\",\n \"1 Corinthians\",\n \"2 Corinthians\",\n \"Galatians\",\n \"Ephesians\",\n \"Philippians\",\n \"Colossians\",\n \"1 Thessalonians\",\n \"2 Thessalonians\",\n \"1 Timothy\",\n \"2 Timothy\",\n \"Titus\",\n \"Philemon\",\n \"Hebrews\",\n \"James\",\n \"1 Peter\",\n \"2 Peter\",\n \"1 John\",\n \"2 John\",\n \"3 John\",\n \"Jude\",\n \"Revelation\",\n \"Tobit\",\n \"Judith\",\n \"Esther Greek\",\n \"Wisdom of Solomon\",\n \"Sirach (Ecclesiasticus)\",\n \"Baruch\",\n \"Letter of Jeremiah\",\n \"Song of 3 Young Men\",\n \"Susanna\",\n \"Bel and the Dragon\",\n \"1 Maccabees\",\n \"2 Maccabees\",\n \"3 Maccabees\",\n \"4 Maccabees\",\n \"1 Esdras (Greek)\",\n \"2 Esdras (Latin)\",\n \"Prayer of Manasseh\",\n \"Psalm 151\",\n \"Odes\",\n \"Psalms of Solomon\",\n // WARNING, if you change the spelling of the *obsolete* tag be sure to update\n // IsObsolete routine\n \"Joshua A. *obsolete*\",\n \"Judges B. *obsolete*\",\n \"Tobit S. *obsolete*\",\n \"Susanna Th. *obsolete*\",\n \"Daniel Th. *obsolete*\",\n \"Bel Th. *obsolete*\",\n \"Extra A\",\n \"Extra B\",\n \"Extra C\",\n \"Extra D\",\n \"Extra E\",\n \"Extra F\",\n \"Extra G\",\n \"Front Matter\",\n \"Back Matter\",\n \"Other Matter\",\n \"3 Ezra *obsolete*\",\n \"Apocalypse of Ezra\",\n \"5 Ezra (Latin Prologue)\",\n \"6 Ezra (Latin Epilogue)\",\n \"Introduction\",\n \"Concordance \",\n \"Glossary \",\n \"Topical Index\",\n \"Names Index\",\n \"Daniel Greek\",\n \"Psalms 152-155\",\n \"2 Baruch (Apocalypse)\",\n \"Letter of Baruch\",\n \"Jubilees\",\n \"Enoch\",\n \"1 Meqabyan\",\n \"2 Meqabyan\",\n \"3 Meqabyan\",\n \"Reproof (Proverbs 25-31)\",\n \"4 Baruch (Rest of Baruch)\",\n \"Laodiceans\"\n], S = K();\nfunction g(t, e = !0) {\n return e && (t = t.toUpperCase()), t in S ? S[t] : 0;\n}\nfunction k(t) {\n return g(t) > 0;\n}\nfunction x(t) {\n const e = typeof t == \"string\" ? g(t) : t;\n return e >= 40 && e <= 66;\n}\nfunction T(t) {\n return (typeof t == \"string\" ? g(t) : t) <= 39;\n}\nfunction X(t) {\n return t <= 66;\n}\nfunction V(t) {\n const e = typeof t == \"string\" ? g(t) : t;\n return w(e) && !X(e);\n}\nfunction* L() {\n for (let t = 1; t <= N.length; t++) yield t;\n}\nconst G = 1, A = N.length;\nfunction H() {\n return [\"XXA\", \"XXB\", \"XXC\", \"XXD\", \"XXE\", \"XXF\", \"XXG\"];\n}\nfunction C(t, e = \"***\") {\n const s = t - 1;\n return s < 0 || s >= N.length ? e : N[s];\n}\nfunction I(t) {\n return t <= 0 || t > A ? \"******\" : O[t - 1];\n}\nfunction y(t) {\n return I(g(t));\n}\nfunction w(t) {\n const e = typeof t == \"number\" ? C(t) : t;\n return k(e) && !B.includes(e);\n}\nfunction q(t) {\n const e = typeof t == \"number\" ? C(t) : t;\n return k(e) && B.includes(e);\n}\nfunction U(t) {\n return O[t - 1].includes(\"*obsolete*\");\n}\nfunction K() {\n const t = {};\n for (let e = 0; e < N.length; e++)\n t[N[e]] = e + 1;\n return t;\n}\nconst m = {\n allBookIds: N,\n nonCanonicalIds: B,\n bookIdToNumber: g,\n isBookIdValid: k,\n isBookNT: x,\n isBookOT: T,\n isBookOTNT: X,\n isBookDC: V,\n allBookNumbers: L,\n firstBook: G,\n lastBook: A,\n extraBooks: H,\n bookNumberToId: C,\n bookNumberToEnglishName: I,\n bookIdToEnglishName: y,\n isCanonical: w,\n isExtraMaterial: q,\n isObsolete: U\n};\nvar l = /* @__PURE__ */ ((t) => (t[t.Unknown = 0] = \"Unknown\", t[t.Original = 1] = \"Original\", t[t.Septuagint = 2] = \"Septuagint\", t[t.Vulgate = 3] = \"Vulgate\", t[t.English = 4] = \"English\", t[t.RussianProtestant = 5] = \"RussianProtestant\", t[t.RussianOrthodox = 6] = \"RussianOrthodox\", t))(l || {});\nconst h = class h {\n // private versInfo: Versification;\n constructor(e) {\n n(this, \"name\");\n n(this, \"fullPath\");\n n(this, \"isPresent\");\n n(this, \"hasVerseSegments\");\n n(this, \"isCustomized\");\n n(this, \"baseVersification\");\n n(this, \"scriptureBooks\");\n n(this, \"_type\");\n if (e == null)\n throw new Error(\"Argument undefined\");\n typeof e == \"string\" ? (this.name = e, this._type = l[e]) : (this._type = e, this.name = l[e]);\n }\n get type() {\n return this._type;\n }\n equals(e) {\n return !e.type || !this.type ? !1 : e.type === this.type;\n }\n};\nn(h, \"Original\", new h(l.Original)), n(h, \"Septuagint\", new h(l.Septuagint)), n(h, \"Vulgate\", new h(l.Vulgate)), n(h, \"English\", new h(l.English)), n(h, \"RussianProtestant\", new h(l.RussianProtestant)), n(h, \"RussianOrthodox\", new h(l.RussianOrthodox));\nlet c = h;\nfunction E(t, e) {\n const s = e[0];\n for (let r = 1; r < e.length; r++)\n t = t.split(e[r]).join(s);\n return t.split(s);\n}\nvar D = /* @__PURE__ */ ((t) => (t[t.Valid = 0] = \"Valid\", t[t.UnknownVersification = 1] = \"UnknownVersification\", t[t.OutOfRange = 2] = \"OutOfRange\", t[t.VerseOutOfOrder = 3] = \"VerseOutOfOrder\", t[t.VerseRepeated = 4] = \"VerseRepeated\", t))(D || {});\nconst i = class i {\n constructor(e, s, r, a) {\n /** Not yet implemented. */\n n(this, \"firstChapter\");\n /** Not yet implemented. */\n n(this, \"lastChapter\");\n /** Not yet implemented. */\n n(this, \"lastVerse\");\n /** Not yet implemented. */\n n(this, \"hasSegmentsDefined\");\n /** Not yet implemented. */\n n(this, \"text\");\n /** Not yet implemented. */\n n(this, \"BBBCCCVVVS\");\n /** Not yet implemented. */\n n(this, \"longHashCode\");\n /** The versification of the reference. */\n n(this, \"versification\");\n n(this, \"rtlMark\", \"‏\");\n n(this, \"_bookNum\", 0);\n n(this, \"_chapterNum\", 0);\n n(this, \"_verseNum\", 0);\n n(this, \"_verse\");\n if (r == null && a == null)\n if (e != null && typeof e == \"string\") {\n const o = e, u = s != null && s instanceof c ? s : void 0;\n this.setEmpty(u), this.parse(o);\n } else if (e != null && typeof e == \"number\") {\n const o = s != null && s instanceof c ? s : void 0;\n this.setEmpty(o), this._verseNum = e % i.chapterDigitShifter, this._chapterNum = Math.floor(\n e % i.bookDigitShifter / i.chapterDigitShifter\n ), this._bookNum = Math.floor(e / i.bookDigitShifter);\n } else if (s == null)\n if (e != null && e instanceof i) {\n const o = e;\n this._bookNum = o.bookNum, this._chapterNum = o.chapterNum, this._verseNum = o.verseNum, this._verse = o.verse, this.versification = o.versification;\n } else {\n if (e == null) return;\n const o = e instanceof c ? e : i.defaultVersification;\n this.setEmpty(o);\n }\n else\n throw new Error(\"VerseRef constructor not supported.\");\n else if (e != null && s != null && r != null)\n if (typeof e == \"string\" && typeof s == \"string\" && typeof r == \"string\")\n this.setEmpty(a), this.updateInternal(e, s, r);\n else if (typeof e == \"number\" && typeof s == \"number\" && typeof r == \"number\")\n this._bookNum = e, this._chapterNum = s, this._verseNum = r, this.versification = a ?? i.defaultVersification;\n else\n throw new Error(\"VerseRef constructor not supported.\");\n else\n throw new Error(\"VerseRef constructor not supported.\");\n }\n /**\n * Determines if the verse string is in a valid format (does not consider versification).\n */\n static isVerseParseable(e) {\n return e.length > 0 && \"0123456789\".includes(e[0]) && !e.endsWith(this.verseRangeSeparator) && !e.endsWith(this.verseSequenceIndicator);\n }\n /**\n * Tries to parse the specified string into a verse reference.\n * @param str - The string to attempt to parse.\n * @returns success: `true` if the specified string was successfully parsed, `false` otherwise.\n * @returns verseRef: The result of the parse if successful, or empty VerseRef if it failed\n */\n static tryParse(e) {\n let s;\n try {\n return s = new i(e), { success: !0, verseRef: s };\n } catch (r) {\n if (r instanceof v)\n return s = new i(), { success: !1, verseRef: s };\n throw r;\n }\n }\n /**\n * Gets the reference as a comparable integer where the book, chapter, and verse each occupy 3\n * digits.\n * @param bookNum - Book number (this is 1-based, not an index).\n * @param chapterNum - Chapter number.\n * @param verseNum - Verse number.\n * @returns The reference as a comparable integer where the book, chapter, and verse each occupy 3\n * digits.\n */\n static getBBBCCCVVV(e, s, r) {\n return e % i.bcvMaxValue * i.bookDigitShifter + (s >= 0 ? s % i.bcvMaxValue * i.chapterDigitShifter : 0) + (r >= 0 ? r % i.bcvMaxValue : 0);\n }\n /**\n * Deserializes a serialized VerseRef.\n * @param serializedVerseRef - Serialized VerseRef to create from.\n * @returns the deserialized VerseRef.\n */\n static fromJSON(e) {\n const { book: s, chapterNum: r, verseNum: a, verse: o, versificationStr: u } = e, f = o || a.toString();\n let d;\n return u && (d = new c(u)), s ? new i(s, r.toString(), f, d) : new i();\n }\n /**\n * Parses a verse string and gets the leading numeric portion as a number.\n * @param verseStr - verse string to parse\n * @returns true if the entire string could be parsed as a single, simple verse number (1-999);\n * false if the verse string represented a verse bridge, contained segment letters, or was invalid\n */\n static tryGetVerseNum(e) {\n let s;\n if (!e)\n return s = -1, { success: !0, vNum: s };\n s = 0;\n let r;\n for (let a = 0; a < e.length; a++) {\n if (r = e[a], r < \"0\" || r > \"9\")\n return a === 0 && (s = -1), { success: !1, vNum: s };\n if (s = s * 10 + +r - 0, s > i.bcvMaxValue)\n return s = -1, { success: !1, vNum: s };\n }\n return { success: !0, vNum: s };\n }\n /**\n * Checks to see if a VerseRef hasn't been set - all values are the default.\n */\n get isDefault() {\n return this.bookNum === 0 && this.chapterNum === 0 && this.verseNum === 0 && this.versification == null;\n }\n /**\n * Gets whether the verse contains multiple verses.\n */\n get hasMultiple() {\n return this._verse != null && (this._verse.includes(i.verseRangeSeparator) || this._verse.includes(i.verseSequenceIndicator));\n }\n /**\n * Gets or sets the book of the reference. Book is the 3-letter abbreviation in capital letters,\n * e.g. `'MAT'`.\n */\n get book() {\n return m.bookNumberToId(this.bookNum, \"\");\n }\n set book(e) {\n this.bookNum = m.bookIdToNumber(e);\n }\n /**\n * Gets or sets the chapter of the reference,. e.g. `'3'`.\n */\n get chapter() {\n return this.isDefault || this._chapterNum < 0 ? \"\" : this._chapterNum.toString();\n }\n set chapter(e) {\n const s = +e;\n this._chapterNum = Number.isInteger(s) ? s : -1;\n }\n /**\n * Gets or sets the verse of the reference, including range, segments, and sequences, e.g. `'4'`,\n * or `'4b-5a, 7'`.\n */\n get verse() {\n return this._verse != null ? this._verse : this.isDefault || this._verseNum < 0 ? \"\" : this._verseNum.toString();\n }\n set verse(e) {\n const { success: s, vNum: r } = i.tryGetVerseNum(e);\n this._verse = s ? void 0 : e.replace(this.rtlMark, \"\"), this._verseNum = r, !(this._verseNum >= 0) && ({ vNum: this._verseNum } = i.tryGetVerseNum(this._verse));\n }\n /**\n * Get or set Book based on book number, e.g. `42`.\n */\n get bookNum() {\n return this._bookNum;\n }\n set bookNum(e) {\n if (e <= 0 || e > m.lastBook)\n throw new v(\n \"BookNum must be greater than zero and less than or equal to last book\"\n );\n this._bookNum = e;\n }\n /**\n * Gets or sets the chapter number, e.g. `3`. `-1` if not valid.\n */\n get chapterNum() {\n return this._chapterNum;\n }\n set chapterNum(e) {\n this.chapterNum = e;\n }\n /**\n * Gets or sets verse start number, e.g. `4`. `-1` if not valid.\n */\n get verseNum() {\n return this._verseNum;\n }\n set verseNum(e) {\n this._verseNum = e;\n }\n /**\n * String representing the versification (should ONLY be used for serialization/deserialization).\n *\n * @remarks This is for backwards compatibility when ScrVers was an enumeration.\n */\n get versificationStr() {\n var e;\n return (e = this.versification) == null ? void 0 : e.name;\n }\n set versificationStr(e) {\n this.versification = this.versification != null ? new c(e) : void 0;\n }\n /**\n * Determines if the reference is valid.\n */\n get valid() {\n return this.validStatus === 0;\n }\n /**\n * Get the valid status for this reference.\n */\n get validStatus() {\n return this.validateVerse(i.verseRangeSeparators, i.verseSequenceIndicators);\n }\n /**\n * Gets the reference as a comparable integer where the book,\n * chapter, and verse each occupy three digits and the verse is 0.\n */\n get BBBCCC() {\n return i.getBBBCCCVVV(this._bookNum, this._chapterNum, 0);\n }\n /**\n * Gets the reference as a comparable integer where the book,\n * chapter, and verse each occupy three digits. If verse is not null\n * (i.e., this reference represents a complex reference with verse\n * segments or bridge) this cannot be used for an exact comparison.\n */\n get BBBCCCVVV() {\n return i.getBBBCCCVVV(this._bookNum, this._chapterNum, this._verseNum);\n }\n /**\n * Gets whether the verse is defined as an excluded verse in the versification.\n * Does not handle verse ranges.\n */\n // eslint-disable-next-line @typescript-eslint/class-literal-property-style\n get isExcluded() {\n return !1;\n }\n /**\n * Parses the reference in the specified string.\n * Optionally versification can follow reference as in GEN 3:11/4\n * Throw an exception if\n * - invalid book name\n * - chapter number is missing or not a number\n * - verse number is missing or does not start with a number\n * - versification is invalid\n * @param verseStr - string to parse e.g. 'MAT 3:11'\n */\n parse(e) {\n if (e = e.replace(this.rtlMark, \"\"), e.includes(\"/\")) {\n const o = e.split(\"/\");\n if (e = o[0], o.length > 1)\n try {\n const u = +o[1].trim();\n this.versification = new c(l[u]);\n } catch {\n throw new v(\"Invalid reference : \" + e);\n }\n }\n const s = e.trim().split(\" \");\n if (s.length !== 2)\n throw new v(\"Invalid reference : \" + e);\n const r = s[1].split(\":\"), a = +r[0];\n if (r.length !== 2 || m.bookIdToNumber(s[0]) === 0 || !Number.isInteger(a) || a < 0 || !i.isVerseParseable(r[1]))\n throw new v(\"Invalid reference : \" + e);\n this.updateInternal(s[0], r[0], r[1]);\n }\n /**\n * Simplifies this verse ref so that it has no bridging of verses or\n * verse segments like `'1a'`.\n */\n simplify() {\n this._verse = void 0;\n }\n /**\n * Makes a clone of the reference.\n *\n * @returns The cloned VerseRef.\n */\n clone() {\n return new i(this);\n }\n toString() {\n const e = this.book;\n return e === \"\" ? \"\" : `${e} ${this.chapter}:${this.verse}`;\n }\n toJSON() {\n let e = this.verse;\n (e === \"\" || e === this.verseNum.toString()) && (e = void 0);\n const s = {\n book: this.book,\n chapterNum: this.chapterNum,\n verseNum: this.verseNum,\n verse: e,\n versificationStr: this.versificationStr\n };\n return e || delete s.verse, s;\n }\n /**\n * Compares this `VerseRef` with supplied one.\n * @param verseRef - object to compare this one to.\n * @returns `true` if this `VerseRef` is equal to the supplied one, `false` otherwise.\n */\n equals(e) {\n return e instanceof i ? e._bookNum === this._bookNum && e._chapterNum === this._chapterNum && e._verseNum === this._verseNum && e.verse === this.verse && (e.versification == null && this.versification == null || e.versification != null && this.versification != null && e.versification.equals(this.versification)) : !1;\n }\n /**\n * Enumerate all individual verses contained in a VerseRef.\n * Verse ranges are indicated by \"-\" and consecutive verses by \",\"s.\n * Examples:\n * GEN 1:2 returns GEN 1:2\n * GEN 1:1a-3b,5 returns GEN 1:1a, GEN 1:2, GEN 1:3b, GEN 1:5\n * GEN 1:2a-2c returns //! ??????\n *\n * @param specifiedVersesOnly - if set to true return only verses that are\n * explicitly specified only, not verses within a range. Defaults to `false`.\n * @param verseRangeSeparators - Verse range separators.\n * Defaults to `VerseRef.verseRangeSeparators`.\n * @param verseSequenceSeparators - Verse sequence separators.\n * Defaults to `VerseRef.verseSequenceIndicators`.\n * @returns An array of all single verse references in this VerseRef.\n */\n allVerses(e = !1, s = i.verseRangeSeparators, r = i.verseSequenceIndicators) {\n if (this._verse == null || this.chapterNum <= 0)\n return [this.clone()];\n const a = [], o = E(this._verse, r);\n for (const u of o.map((f) => E(f, s))) {\n const f = this.clone();\n f.verse = u[0];\n const d = f.verseNum;\n if (a.push(f), u.length > 1) {\n const b = this.clone();\n if (b.verse = u[1], !e)\n for (let p = d + 1; p < b.verseNum; p++) {\n const J = new i(\n this._bookNum,\n this._chapterNum,\n p,\n this.versification\n );\n this.isExcluded || a.push(J);\n }\n a.push(b);\n }\n }\n return a;\n }\n /**\n * Validates a verse number using the supplied separators rather than the defaults.\n */\n validateVerse(e, s) {\n if (!this.verse)\n return this.internalValid;\n let r = 0;\n for (const a of this.allVerses(!0, e, s)) {\n const o = a.internalValid;\n if (o !== 0)\n return o;\n const u = a.BBBCCCVVV;\n if (r > u)\n return 3;\n if (r === u)\n return 4;\n r = u;\n }\n return 0;\n }\n /**\n * Gets whether a single verse reference is valid.\n */\n get internalValid() {\n return this.versification == null ? 1 : this._bookNum <= 0 || this._bookNum > m.lastBook ? 2 : (m.isCanonical(this._bookNum), 0);\n }\n setEmpty(e = i.defaultVersification) {\n this._bookNum = 0, this._chapterNum = -1, this._verse = void 0, this.versification = e;\n }\n updateInternal(e, s, r) {\n this.bookNum = m.bookIdToNumber(e), this.chapter = s, this.verse = r;\n }\n};\nn(i, \"defaultVersification\", c.English), n(i, \"verseRangeSeparator\", \"-\"), n(i, \"verseSequenceIndicator\", \",\"), n(i, \"verseRangeSeparators\", [i.verseRangeSeparator]), n(i, \"verseSequenceIndicators\", [i.verseSequenceIndicator]), n(i, \"chapterDigitShifter\", 1e3), n(i, \"bookDigitShifter\", i.chapterDigitShifter * i.chapterDigitShifter), n(i, \"bcvMaxValue\", i.chapterDigitShifter - 1), /**\n * The valid status of the VerseRef.\n */\nn(i, \"ValidStatusType\", D);\nlet M = i;\nclass v extends Error {\n}\nexport {\n _ as BookSet,\n m as Canon,\n c as ScrVers,\n l as ScrVersType,\n M as VerseRef,\n v as VerseRefException\n};\n//# sourceMappingURL=index.es.js.map\n","import React from 'react';\nimport * as DropdownMenuPrimitive from '@radix-ui/react-dropdown-menu';\nimport { Check, ChevronRight, Circle } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport const DropdownMenu = DropdownMenuPrimitive.Root;\n\nexport const DropdownMenuTrigger = DropdownMenuPrimitive.Trigger;\n\nexport const DropdownMenuGroup = DropdownMenuPrimitive.Group;\n\nexport const DropdownMenuPortal = DropdownMenuPrimitive.Portal;\n\nexport const DropdownMenuSub = DropdownMenuPrimitive.Sub;\n\nexport const DropdownMenuRadioGroup = DropdownMenuPrimitive.RadioGroup;\n\nexport type DropdownMenuSubTriggerProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.SubTrigger\n> & {\n className?: string;\n inset?: boolean;\n};\n\nexport type DropdownMenuSubContentProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.SubContent\n> & {\n className?: string;\n};\n\nexport type DropdownMenuContentProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Content\n> & {\n className?: string;\n sideOffset?: number;\n};\n\nexport type DropdownMenuItemProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Item\n> & {\n className?: string;\n inset?: boolean;\n};\n\nexport type DropdownMenuCheckboxItemProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.CheckboxItem\n> & {\n className?: string;\n checked?: boolean;\n};\n\nexport type DropdownMenuRadioItemProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.RadioItem\n> & {\n className?: string;\n};\n\nexport type DropdownMenuLabelProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Label\n> & {\n className?: string;\n inset?: boolean;\n};\n\nexport type DropdownMenuSeparatorProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Separator\n> & {\n className?: string;\n};\n\nexport type DropdownMenuShortcutProps = React.HTMLAttributes & {\n className?: string;\n};\n\nexport const DropdownMenuSubTrigger = React.forwardRef<\n React.ElementRef,\n DropdownMenuSubTriggerProps\n>(({ className, inset, children, ...props }, ref) => (\n \n {children}\n \n \n));\nDropdownMenuSubTrigger.displayName = DropdownMenuPrimitive.SubTrigger.displayName;\n\nexport const DropdownMenuSubContent = React.forwardRef<\n React.ElementRef,\n DropdownMenuSubContentProps\n>(({ className, ...props }, ref) => (\n \n));\nDropdownMenuSubContent.displayName = DropdownMenuPrimitive.SubContent.displayName;\n\nexport const DropdownMenuContent = React.forwardRef<\n React.ElementRef,\n DropdownMenuContentProps\n>(({ className, sideOffset = 4, ...props }, ref) => (\n \n \n \n));\nDropdownMenuContent.displayName = DropdownMenuPrimitive.Content.displayName;\n\n/**\n * TODO: fix: direction is not automatically handled by this component, so that shortcuts are\n * display always to the right\n */\nexport const DropdownMenuItem = React.forwardRef<\n React.ElementRef,\n DropdownMenuItemProps\n>(({ className, inset, ...props }, ref) => (\n \n));\nDropdownMenuItem.displayName = DropdownMenuPrimitive.Item.displayName;\n\nexport const DropdownMenuCheckboxItem = React.forwardRef<\n React.ElementRef,\n DropdownMenuCheckboxItemProps\n>(({ className, children, checked, ...props }, ref) => (\n \n \n \n \n \n \n {children}\n \n));\nDropdownMenuCheckboxItem.displayName = DropdownMenuPrimitive.CheckboxItem.displayName;\n\nexport const DropdownMenuRadioItem = React.forwardRef<\n React.ElementRef,\n DropdownMenuRadioItemProps\n>(({ className, children, ...props }, ref) => (\n \n \n \n \n \n \n {children}\n \n));\nDropdownMenuRadioItem.displayName = DropdownMenuPrimitive.RadioItem.displayName;\n\nexport const DropdownMenuLabel = React.forwardRef<\n React.ElementRef,\n DropdownMenuLabelProps\n>(({ className, inset, ...props }, ref) => (\n \n));\nDropdownMenuLabel.displayName = DropdownMenuPrimitive.Label.displayName;\n\nexport const DropdownMenuSeparator = React.forwardRef<\n React.ElementRef,\n DropdownMenuSeparatorProps\n>(({ className, ...props }, ref) => (\n \n));\nDropdownMenuSeparator.displayName = DropdownMenuPrimitive.Separator.displayName;\n\nexport function DropdownMenuShortcut({ className, ...props }: DropdownMenuShortcutProps) {\n return (\n \n );\n}\nDropdownMenuShortcut.displayName = 'DropdownMenuShortcut';\n","import { Canon } from '@sillsdev/scripture';\nimport { PropsWithChildren, KeyboardEvent, forwardRef } from 'react';\nimport { DropdownMenuItem as ShadDropdownMenuItem } from '@/components/shadcn-ui/dropdown-menu';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport type BookType = 'OT' | 'NT' | 'DC';\n\ntype BookMenuItemProps = PropsWithChildren<{\n /** String id of book */\n bookId: string;\n /** Callback to run when a book menu item is selected */\n handleSelectBook: () => void;\n /** Indicates if this menu item is currently selected */\n isSelected: boolean;\n /** Function that is called upon highlighting a book in the dropdown menu */\n handleHighlightBook: () => void;\n /**\n * Function that is called on pressing a key\n *\n * @param event Event that contains information about the key stroke\n */\n handleKeyDown: (event: KeyboardEvent) => void;\n /**\n * Type of book associated with this menu item, coordinates color labels ? Mock up has the labels\n * coordinated to genre\n */\n bookType: BookType;\n}>;\n\nconst BookMenuItem = forwardRef(\n (\n {\n bookId,\n handleSelectBook,\n isSelected,\n handleHighlightBook,\n handleKeyDown,\n bookType,\n children,\n }: BookMenuItemProps,\n ref,\n ) => {\n return (\n {\n // preventDefault() here prevents the entire dropdown menu from closing when selecting this item\n event.preventDefault();\n handleSelectBook();\n }}\n onKeyDown={(event: KeyboardEvent) => {\n handleKeyDown(event);\n }}\n onFocus={handleHighlightBook}\n onMouseMove={handleHighlightBook}\n >\n \n {Canon.bookIdToEnglishName(bookId)}\n \n {isSelected &&
    {children}
    }\n \n );\n },\n);\n\nexport default BookMenuItem;\n","import { cn } from '@/utils/shadcn-ui.util';\nimport { useCallback } from 'react';\n\nexport type ChapterSelectProps = {\n /**\n * Callback to run when a chapter div is selected\n *\n * @param chapterNumber Number of the chapter that has been selected\n */\n handleSelectChapter: (chapterNumber: number) => void;\n /** The highest chapter number in the book (of course equal to number of chapters in the book) */\n endChapter: number;\n /** The chapter number that is currently selected */\n activeChapter: number;\n /** The chapter number that is currently highlighted using keyboard or mouse navigation */\n highlightedChapter: number;\n /**\n * Callback to run when a chapter is highlighted by the user\n *\n * @param chapterNumber The chapter that is highlighted\n */\n handleHighlightedChapter: (chapterNumber: number) => void;\n};\n\nfunction ChapterSelect({\n handleSelectChapter,\n endChapter,\n activeChapter,\n highlightedChapter,\n handleHighlightedChapter,\n}: ChapterSelectProps) {\n const chapters = Array.from({ length: endChapter }, (_, i) => i + 1);\n\n const handleMouse = useCallback(\n (chapterNumber: number) => {\n handleHighlightedChapter(chapterNumber);\n },\n [handleHighlightedChapter],\n );\n\n return (\n
    \n {chapters.map((chapter) => (\n {\n event.preventDefault();\n event.stopPropagation();\n handleSelectChapter(chapter);\n }}\n role=\"button\"\n onKeyDown={(event) => {\n if (event.key === 'Enter') {\n handleSelectChapter(chapter);\n }\n }}\n tabIndex={0}\n onMouseMove={() => handleMouse(chapter)}\n >\n {chapter}\n
    \n ))}\n
    \n );\n}\n\nexport default ChapterSelect;\n","import { DropdownMenuLabel as ShadDropdownMenuLabel } from '@/components/shadcn-ui/dropdown-menu';\nimport { Bookmark, Clock, ArrowDownWideNarrow } from 'lucide-react';\n\nexport type GoToMenuItemProps = {\n handleSort: () => void;\n handleLocationHistory: () => void;\n handleBookmarks: () => void;\n};\n\nfunction GoToMenuItem({ handleSort, handleLocationHistory, handleBookmarks }: GoToMenuItemProps) {\n return (\n \n

    Go To

    \n
    \n \n \n \n
    \n
    \n );\n}\n\nexport default GoToMenuItem;\n","import BookChapterInput from '@/components/advanced/book-chapter-control/book-chapter-input.component';\nimport BookMenuItem, {\n BookType,\n} from '@/components/advanced/book-chapter-control/book-menu-item.component';\nimport ChapterSelect from '@/components/advanced/book-chapter-control/chapter-select.component';\nimport GoToMenuItem from '@/components/advanced/book-chapter-control/go-to-menu-item.component';\nimport {\n DropdownMenu as ShadDropdownMenu,\n DropdownMenuContent as ShadDropdownMenuContent,\n DropdownMenuLabel as ShadDropdownMenuLabel,\n DropdownMenuSeparator as ShadDropdownMenuSeparator,\n DropdownMenuTrigger as ShadDropdownMenuTrigger,\n} from '@/components/shadcn-ui/dropdown-menu';\nimport { Canon } from '@sillsdev/scripture';\nimport { ScriptureReference, getChaptersForBook } from 'platform-bible-utils';\nimport {\n KeyboardEvent as ReactKeyboardEvent,\n useCallback,\n useEffect,\n useLayoutEffect,\n useRef,\n useState,\n} from 'react';\n\ntype BookTypeLabels = {\n [bookType in BookType]: string;\n};\ntype BookChapterControlProps = {\n scrRef: ScriptureReference;\n handleSubmit: (scrRef: ScriptureReference) => void;\n};\n\nconst ALL_BOOK_IDS = Canon.allBookIds;\nconst BOOK_TYPE_LABELS: BookTypeLabels = {\n OT: 'Old Testament',\n NT: 'New Testament',\n DC: 'Deuterocanon',\n};\nconst BOOK_TYPE_ARRAY: BookType[] = ['OT', 'NT', 'DC'];\n// This is the height of three menu items to offset scrolling to the selected menu item\n// If you use menuItemRef.clientHeight- includes height of chapter div which is too big\nconst SCROLL_OFFSET = 32 + 32 + 32;\nconst SEARCH_QUERY_FORMATS = [\n /^(\\w+)$/i, // Matches a single word (book name or id)\n /^(\\w+)(?:\\s(\\d+))$/i, // Matches a word followed by a chapter number\n /^(\\w+)(?:\\s(\\d+):(\\d+))$/i, // Matches a word followed by a chapter and verse number\n];\nconst fetchGroupedBooks = (bookType: BookType) => {\n const groupedBooks = {\n OT: ALL_BOOK_IDS.filter((bookId) => Canon.isBookOT(bookId)),\n NT: ALL_BOOK_IDS.filter((bookId) => Canon.isBookNT(bookId)),\n DC: ALL_BOOK_IDS.filter((bookId) => Canon.isBookDC(bookId)),\n };\n return groupedBooks[bookType];\n};\nconst fetchEndChapter = (bookId: string) => {\n // getChaptersForBook returns -1 if not found in scrBookData\n // scrBookData only includes OT and NT, so all DC will return -1\n return getChaptersForBook(Canon.bookIdToNumber(bookId));\n};\n\n/**\n * Gets all of the English names from book ids\n *\n * @returns String[]\n */\nfunction getAllEnglishNames(): string[] {\n const allEnglishNames = ALL_BOOK_IDS.map((bookId) => {\n return Canon.bookIdToEnglishName(bookId);\n });\n return allEnglishNames;\n}\n\n/**\n * Determines if bookName is in allEnglishNames\n *\n * @param bookName Book English name\n * @returns True if bookName is included, false otherwise\n */\nfunction isValidBookEnglishName(bookName: string): boolean {\n return getAllEnglishNames().includes(bookName);\n}\n\n/**\n * Gets a bookId from given English name\n *\n * @param bookName Book English name\n * @returns BookId of provided bookName, undefined otherwise\n */\nfunction getBookIdFromEnglishName(bookName: string): string | undefined {\n // Convert bookName to lowercase and then capitalize the first letter\n const formattedBookName = bookName.toLowerCase().replace(/^\\w/, (c) => c.toUpperCase());\n\n if (isValidBookEnglishName(formattedBookName)) {\n const matchingBookId = ALL_BOOK_IDS.find((bookId) => {\n return Canon.bookIdToEnglishName(bookId) === formattedBookName;\n });\n return matchingBookId;\n }\n\n return undefined;\n}\n\nfunction BookChapterControl({ scrRef, handleSubmit }: BookChapterControlProps) {\n const [searchQuery, setSearchQuery] = useState('');\n const [selectedBookId, setSelectedBookId] = useState(\n Canon.bookNumberToId(scrRef.bookNum),\n );\n const [highlightedChapter, setHighlightedChapter] = useState(scrRef.chapterNum ?? 0);\n const [highlightedBookId, setHighlightedBookId] = useState(\n Canon.bookNumberToId(scrRef.bookNum),\n );\n const [isContentOpen, setIsContentOpen] = useState(false);\n const [isContentOpenDelayed, setIsContentOpenDelayed] = useState(isContentOpen);\n\n // This ref will always be defined\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const inputRef = useRef(undefined!);\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const contentRef = useRef(undefined!);\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const menuItemRef = useRef(undefined!);\n\n const fetchFilteredBooks = useCallback(\n (bookType: BookType) => {\n return fetchGroupedBooks(bookType).filter((bookId: string) => {\n const englishNameLowerCase = Canon.bookIdToEnglishName(bookId).toLowerCase();\n const normalizedQuery = searchQuery.replace(/[^a-zA-Z]/g, '').toLowerCase();\n return (\n englishNameLowerCase.includes(normalizedQuery) || // Match book name\n bookId.toLowerCase().includes(normalizedQuery) // Match book ID\n );\n });\n },\n [searchQuery],\n );\n\n const handleSearchInput = (searchString: string) => {\n setSearchQuery(searchString);\n };\n\n /**\n * Whether to prevent radix's logic from closing the dropdown. This is important because radix\n * tries to close the dropdown when the input first focuses, and we don't want it to do that. But\n * we don't want to prevent the dropdown from closing when we click away from the input, so we\n * don't want to just keep it open if the input is focused\n */\n const shouldPreventAutoClosing = useRef(false);\n\n const controlMenuState = useCallback((open: boolean) => {\n if (shouldPreventAutoClosing.current) {\n shouldPreventAutoClosing.current = false;\n return;\n }\n setIsContentOpen(open);\n }, []);\n\n const updateReference = useCallback(\n (bookId: string, shouldClose: boolean, chapter?: number, verse?: number) => {\n setHighlightedChapter(\n Canon.bookNumberToId(scrRef.bookNum) !== bookId ? 1 : scrRef.chapterNum,\n );\n\n if (shouldClose || fetchEndChapter(bookId) === -1) {\n handleSubmit({\n bookNum: Canon.bookIdToNumber(bookId),\n chapterNum: chapter || 1,\n verseNum: verse || 1,\n });\n\n setIsContentOpen(false);\n setSearchQuery('');\n return;\n }\n\n setSelectedBookId(selectedBookId !== bookId ? bookId : '');\n setIsContentOpen(!shouldClose);\n },\n [handleSubmit, scrRef.bookNum, scrRef.chapterNum, selectedBookId],\n );\n\n const handleSelectChapter = (chapterNumber: number) => {\n if (chapterNumber <= 0 || chapterNumber > fetchEndChapter(selectedBookId)) {\n return;\n }\n updateReference(selectedBookId, true, chapterNumber);\n };\n\n const handleInputSubmit = useCallback(() => {\n SEARCH_QUERY_FORMATS.forEach((format) => {\n const matches = searchQuery.match(format);\n if (matches) {\n // Book should be a bookId or an english name\n const [book, chapter = undefined, verse = undefined] = matches.slice(1);\n const englishName = getBookIdFromEnglishName(book);\n\n if (Canon.isBookIdValid(book) || englishName) {\n updateReference(\n englishName ?? book,\n true,\n chapter ? parseInt(chapter, 10) : 1,\n verse ? parseInt(verse, 10) : 1,\n );\n }\n }\n });\n }, [updateReference, searchQuery]);\n\n const handleKeyDownInput = useCallback(\n (event: ReactKeyboardEvent) => {\n if (!isContentOpen) {\n setIsContentOpen(true);\n } else if (event.key === 'ArrowDown' || event.key === 'ArrowUp') {\n if (\n typeof menuItemRef !== 'undefined' &&\n // Ref uses null\n // eslint-disable-next-line no-null/no-null\n menuItemRef.current !== null\n ) {\n menuItemRef.current.focus();\n } else if (\n typeof contentRef !== 'undefined' &&\n // Ref uses null\n // eslint-disable-next-line no-null/no-null\n contentRef.current !== null\n ) {\n contentRef.current.focus();\n }\n event.preventDefault();\n }\n },\n [isContentOpen],\n );\n\n const handleKeyDownContent = (event: ReactKeyboardEvent) => {\n // When the dropdown menu has focus, key strokes should give focus to the input component,\n // unless they're navigation keys (arrows and enter)\n const { key } = event;\n if (\n key === 'ArrowRight' ||\n key === 'ArrowLeft' ||\n key === 'ArrowDown' ||\n key === 'ArrowUp' ||\n key === 'Enter'\n ) {\n return;\n }\n\n inputRef.current.dispatchEvent(new KeyboardEvent('keydown', { key }));\n inputRef.current.focus();\n };\n\n const handleKeyDownMenuItem = (event: ReactKeyboardEvent) => {\n const { key } = event;\n if (highlightedBookId === selectedBookId) {\n if (key === 'Enter') {\n event.preventDefault();\n updateReference(selectedBookId, true, highlightedChapter);\n return;\n }\n\n let chapterOffSet = 0;\n if (key === 'ArrowRight') {\n if (highlightedChapter < fetchEndChapter(highlightedBookId)) {\n chapterOffSet = 1;\n } else {\n event.preventDefault();\n return;\n }\n } else if (key === 'ArrowLeft') {\n if (highlightedChapter > 1) {\n chapterOffSet = -1;\n } else {\n event.preventDefault();\n return;\n }\n } else if (key === 'ArrowDown') {\n chapterOffSet = 6;\n } else if (key === 'ArrowUp') {\n chapterOffSet = -6;\n }\n if (\n highlightedChapter + chapterOffSet <= 0 ||\n highlightedChapter + chapterOffSet > fetchEndChapter(highlightedBookId)\n ) {\n setHighlightedChapter(0);\n } else if (chapterOffSet !== 0) {\n setHighlightedChapter(highlightedChapter + chapterOffSet);\n event.preventDefault();\n }\n }\n };\n\n useEffect(() => {\n if (selectedBookId === highlightedBookId) {\n if (selectedBookId === Canon.bookNumberToId(scrRef.bookNum)) {\n setHighlightedChapter(scrRef.chapterNum);\n } else {\n setHighlightedChapter(1);\n }\n } else {\n setHighlightedChapter(0);\n }\n }, [highlightedBookId, scrRef.bookNum, scrRef.chapterNum, selectedBookId]);\n\n // The purpose of these useLayoutEffects and timeout is to delay the scroll just\n // enough so that the refs are defined and available when they are used after the timeout\n useLayoutEffect(() => {\n setIsContentOpenDelayed(isContentOpen);\n }, [isContentOpen]);\n\n useLayoutEffect(() => {\n const scrollTimeout = setTimeout(() => {\n if (isContentOpenDelayed && contentRef.current && menuItemRef.current) {\n const menuItemOffsetTop = menuItemRef.current.offsetTop;\n const scrollPosition = menuItemOffsetTop - SCROLL_OFFSET;\n contentRef.current.scrollTo({ top: scrollPosition, behavior: 'instant' });\n }\n }, 10);\n return () => {\n clearTimeout(scrollTimeout);\n };\n }, [isContentOpenDelayed]);\n\n return (\n
    \n \n \n {\n setSelectedBookId(Canon.bookNumberToId(scrRef.bookNum));\n setHighlightedBookId(Canon.bookNumberToId(scrRef.bookNum));\n setHighlightedChapter(scrRef.chapterNum > 0 ? scrRef.chapterNum : 0);\n setIsContentOpen(true);\n inputRef.current.focus();\n }}\n onFocus={() => {\n // Radix thinks we want to close because the input is being focused. Prevent that\n shouldPreventAutoClosing.current = true;\n }}\n handleSubmit={handleInputSubmit}\n placeholder={`${Canon.bookNumberToEnglishName(scrRef.bookNum)} ${scrRef.chapterNum}:${scrRef.verseNum}`}\n />\n \n \n console.log('sorting')}\n handleLocationHistory={() => console.log('location history')}\n handleBookmarks={() => console.log('bookmarks')}\n />\n {BOOK_TYPE_ARRAY.map(\n (bookType, bookTypeIndex) =>\n fetchFilteredBooks(bookType).length > 0 && (\n
    \n \n {BOOK_TYPE_LABELS[bookType]}\n \n\n {fetchFilteredBooks(bookType).map((bookId) => (\n
    \n updateReference(bookId, false)}\n isSelected={selectedBookId === bookId}\n handleHighlightBook={() => setHighlightedBookId(bookId)}\n handleKeyDown={handleKeyDownMenuItem}\n bookType={bookType}\n ref={(element: HTMLDivElement) => {\n if (selectedBookId === bookId) menuItemRef.current = element;\n }}\n >\n {\n setHighlightedChapter(chapterNumber);\n }}\n />\n \n
    \n ))}\n {BOOK_TYPE_ARRAY.length - 1 !== bookTypeIndex ? (\n \n ) : undefined}\n
    \n ),\n )}\n \n
    \n
    \n );\n}\n\nexport default BookChapterControl;\n","import React from 'react';\nimport { Slot } from '@radix-ui/react-slot';\nimport { cva, type VariantProps } from 'class-variance-authority';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport const buttonVariants = cva(\n 'pr-twp tw-inline-flex tw-items-center tw-justify-center tw-whitespace-nowrap tw-rounded-md tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-colors focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50',\n {\n variants: {\n variant: {\n default: 'tw-bg-primary tw-text-primary-foreground hover:tw-bg-primary/90',\n destructive: 'tw-bg-destructive tw-text-destructive-foreground hover:tw-bg-destructive/90',\n outline:\n 'tw-border tw-border-input tw-bg-background hover:tw-bg-accent hover:tw-text-accent-foreground',\n secondary: 'tw-bg-secondary tw-text-secondary-foreground hover:tw-bg-secondary/80',\n ghost: 'hover:tw-bg-accent hover:tw-text-accent-foreground',\n link: 'tw-text-primary tw-underline-offset-4 hover:tw-underline',\n },\n size: {\n default: 'tw-h-10 tw-px-4 tw-py-2',\n sm: 'tw-h-9 tw-rounded-md tw-px-3',\n lg: 'tw-h-11 tw-rounded-md tw-px-8',\n icon: 'tw-h-10 tw-w-10',\n },\n },\n defaultVariants: {\n variant: 'default',\n size: 'default',\n },\n },\n);\n\nexport interface ButtonProps\n extends React.ButtonHTMLAttributes,\n VariantProps {\n asChild?: boolean;\n}\n\nexport const Button = React.forwardRef(\n ({ className, variant, size, asChild = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'button';\n return (\n \n );\n },\n);\nButton.displayName = 'Button';\n","import React from 'react';\nimport * as LabelPrimitive from '@radix-ui/react-label';\nimport { cva, type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst labelVariants = cva(\n 'tw-text-sm tw-font-medium tw-leading-none peer-disabled:tw-cursor-not-allowed peer-disabled:tw-opacity-70',\n);\n\nexport const Label = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef & VariantProps\n>(({ className, ...props }, ref) => (\n \n));\nLabel.displayName = LabelPrimitive.Root.displayName;\n","import React from 'react';\nimport * as RadioGroupPrimitive from '@radix-ui/react-radio-group';\nimport { Circle } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst RadioGroup = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => {\n return (\n \n );\n});\nRadioGroup.displayName = RadioGroupPrimitive.Root.displayName;\n\nconst RadioGroupItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => {\n return (\n \n \n \n \n \n );\n});\nRadioGroupItem.displayName = RadioGroupPrimitive.Item.displayName;\n\nexport { RadioGroup, RadioGroupItem };\n","import React from 'react';\nimport * as PopoverPrimitive from '@radix-ui/react-popover';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Popover = PopoverPrimitive.Root;\n\nconst PopoverTrigger = PopoverPrimitive.Trigger;\n\nconst PopoverContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, align = 'center', sideOffset = 4, ...props }, ref) => (\n \n \n \n));\nPopoverContent.displayName = PopoverPrimitive.Content.displayName;\n\nexport { Popover, PopoverTrigger, PopoverContent };\n","import React from 'react';\nimport * as DialogPrimitive from '@radix-ui/react-dialog';\nimport { X } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Dialog = DialogPrimitive.Root;\n\nconst DialogTrigger = DialogPrimitive.Trigger;\n\nconst DialogPortal = DialogPrimitive.Portal;\n\nconst DialogClose = DialogPrimitive.Close;\n\nconst DialogOverlay = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nDialogOverlay.displayName = DialogPrimitive.Overlay.displayName;\n\nconst DialogContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, ...props }, ref) => (\n \n \n \n {children}\n \n \n Close\n \n \n \n));\nDialogContent.displayName = DialogPrimitive.Content.displayName;\n\nfunction DialogHeader({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nDialogHeader.displayName = 'DialogHeader';\n\nfunction DialogFooter({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nDialogFooter.displayName = 'DialogFooter';\n\nconst DialogTitle = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nDialogTitle.displayName = DialogPrimitive.Title.displayName;\n\nconst DialogDescription = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nDialogDescription.displayName = DialogPrimitive.Description.displayName;\n\nexport {\n Dialog,\n DialogPortal,\n DialogOverlay,\n DialogClose,\n DialogTrigger,\n DialogContent,\n DialogHeader,\n DialogFooter,\n DialogTitle,\n DialogDescription,\n};\n","import React from 'react';\nimport { type DialogProps } from '@radix-ui/react-dialog';\nimport { Command as CommandPrimitive } from 'cmdk';\nimport { Search } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Dialog, DialogContent } from '@/components/shadcn-ui/dialog';\n\nconst Command = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nCommand.displayName = CommandPrimitive.displayName;\n\ninterface CommandDialogProps extends DialogProps {}\n\nfunction CommandDialog({ children, ...props }: CommandDialogProps) {\n return (\n \n \n \n {children}\n \n \n \n );\n}\n\nconst CommandInput = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n
    \n \n \n
    \n));\n\nCommandInput.displayName = CommandPrimitive.Input.displayName;\n\nconst CommandList = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\n\nCommandList.displayName = CommandPrimitive.List.displayName;\n\nconst CommandEmpty = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>((props, ref) => (\n \n));\n\nCommandEmpty.displayName = CommandPrimitive.Empty.displayName;\n\nconst CommandGroup = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\n\nCommandGroup.displayName = CommandPrimitive.Group.displayName;\n\nconst CommandSeparator = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nCommandSeparator.displayName = CommandPrimitive.Separator.displayName;\n\nconst CommandItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\n\nCommandItem.displayName = CommandPrimitive.Item.displayName;\n\nfunction CommandShortcut({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nCommandShortcut.displayName = 'CommandShortcut';\n\nexport {\n Command,\n CommandDialog,\n CommandInput,\n CommandList,\n CommandEmpty,\n CommandGroup,\n CommandItem,\n CommandShortcut,\n CommandSeparator,\n};\n","import { useState } from 'react';\nimport { Check, ChevronsUpDown } from 'lucide-react';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport { Popover, PopoverContent, PopoverTrigger } from '@/components/shadcn-ui/popover';\nimport {\n Command,\n CommandEmpty,\n CommandInput,\n CommandItem,\n CommandList,\n} from '@/components/shadcn-ui/command';\nimport { PopoverProps } from '@radix-ui/react-popover';\n\nexport type ComboBoxLabelOption = { label: string };\nexport type ComboBoxOption = string | number | ComboBoxLabelOption;\n\nexport type ComboBoxProps = {\n /** Optional unique identifier */\n id?: string;\n /** Text label title for combobox */\n /** List of available options for the dropdown menu */\n options?: readonly T[];\n /** @deprecated 3 December 2024. Renamed to {@link buttonClassName} */\n className?: string;\n /** Additional css classes to help with unique styling of the combo box button */\n buttonClassName?: string;\n /** Additional css classes to help with unique styling of the combo box popover */\n popoverContentClassName?: string;\n /**\n * The selected value that the combo box currently holds. Must be shallow equal to one of the\n * options entries.\n */\n value?: T;\n /** Triggers when content of textfield is changed */\n onChange?: (newValue: T) => void;\n /** Used to determine the string value for a given option. */\n getOptionLabel?: (option: ComboBoxOption) => string;\n /** Text displayed on button if `value` is undefined */\n buttonPlaceholder?: string;\n /** Placeholder text for text field */\n textPlaceholder?: string;\n /** Text to display when no options match input */\n commandEmptyMessage?: string;\n /** Variant of button */\n buttonVariant?: ButtonProps['variant'];\n /** Text direction ltr or rtl */\n dir?: Direction;\n /** Optional boolean to set if trigger should be disabled */\n isDisabled?: boolean;\n} & PopoverProps;\n\ntype Direction = 'ltr' | 'rtl';\n\nfunction getOptionLabelDefault(option: ComboBoxOption): string {\n if (typeof option === 'string') {\n return option;\n }\n if (typeof option === 'number') {\n return option.toString();\n }\n return option.label;\n}\n\n/**\n * Autocomplete input and command palette with a list of suggestions.\n *\n * Thanks to Shadcn for heavy inspiration and documentation\n * https://ui.shadcn.com/docs/components/combobox\n */\nfunction ComboBox({\n id,\n options = [],\n buttonClassName,\n popoverContentClassName,\n value,\n onChange = () => {},\n getOptionLabel = getOptionLabelDefault,\n buttonPlaceholder = '',\n textPlaceholder = '',\n commandEmptyMessage = 'No option found',\n buttonVariant = 'outline',\n dir = 'ltr',\n isDisabled = false,\n ...props\n}: ComboBoxProps) {\n const [open, setOpen] = useState(false);\n\n return (\n \n \n \n \n {value ? getOptionLabel(value) : buttonPlaceholder}\n \n \n \n \n \n \n \n {commandEmptyMessage}\n \n {options.map((option) => (\n {\n onChange(option);\n setOpen(false);\n }}\n >\n \n {getOptionLabel(option)}\n \n ))}\n \n \n \n \n );\n}\n\nexport default ComboBox;\n","import { useMemo } from 'react';\nimport ComboBox from '@/components/basics/combo-box.component';\nimport { Label } from '@/components/shadcn-ui/label';\n\nexport type ChapterRangeSelectorProps = {\n startChapter: number;\n endChapter: number;\n handleSelectStartChapter: (chapter: number) => void;\n handleSelectEndChapter: (chapter: number) => void;\n isDisabled?: boolean;\n chapterCount: number;\n};\n\nexport default function ChapterRangeSelector({\n startChapter,\n endChapter,\n handleSelectStartChapter,\n handleSelectEndChapter,\n isDisabled = false,\n chapterCount,\n}: ChapterRangeSelectorProps) {\n const chapterOptions = useMemo(\n () => Array.from({ length: chapterCount }, (_, index) => index + 1),\n [chapterCount],\n );\n\n const onChangeStartChapter = (value: number) => {\n handleSelectStartChapter(value);\n if (value > endChapter) {\n handleSelectEndChapter(value);\n }\n };\n\n const onChangeEndChapter = (value: number) => {\n handleSelectEndChapter(value);\n if (value < startChapter) {\n handleSelectStartChapter(value);\n }\n };\n\n return (\n <>\n \n option.toString()}\n value={startChapter}\n />\n\n \n option.toString()}\n value={endChapter}\n />\n \n );\n}\n","import { Button } from '@/components/shadcn-ui/button';\nimport { Label } from '@/components/shadcn-ui/label';\nimport { RadioGroup, RadioGroupItem } from '@/components/shadcn-ui/radio-group';\nimport { Canon } from '@sillsdev/scripture';\nimport { LocalizedStringValue } from 'platform-bible-utils';\nimport { useState } from 'react';\nimport ChapterRangeSelector, {\n ChapterRangeSelectorProps,\n} from '../basics/chapter-range-selector.component';\n\nexport enum BookSelectionMode {\n CURRENT_BOOK = 'current book',\n CHOOSE_BOOKS = 'choose books',\n}\n\n/**\n * Object containing all keys used for localization in this component. If you're using this\n * component in an extension, you can pass it into the useLocalizedStrings hook to easily obtain the\n * localized strings and pass them into the localizedStrings prop of this component\n */\nexport const BOOK_SELECTOR_STRING_KEYS = Object.freeze([\n '%webView_bookSelector_currentBook%',\n '%webView_bookSelector_choose%',\n '%webView_bookSelector_chooseBooks%',\n] as const);\n\nexport type BookSelectorLocalizedStrings = {\n [localizedInventoryKey in (typeof BOOK_SELECTOR_STRING_KEYS)[number]]?: LocalizedStringValue;\n};\n\n/**\n * Gets the localized value for the provided key\n *\n * @param strings Object containing localized string\n * @param key Key for a localized string\n * @returns The localized value for the provided key, if available. Returns the key if no localized\n * value is available\n */\nconst localizeString = (\n strings: BookSelectorLocalizedStrings,\n key: keyof BookSelectorLocalizedStrings,\n) => {\n return strings[key] ?? key;\n};\n\ntype BookSelectorProps = ChapterRangeSelectorProps & {\n handleBookSelectionModeChange: (newMode: BookSelectionMode) => void;\n currentBookName: string;\n onSelectBooks: () => void;\n selectedBookIds: string[];\n localizedStrings: BookSelectorLocalizedStrings;\n};\n\nexport default function BookSelector({\n handleBookSelectionModeChange,\n currentBookName,\n onSelectBooks,\n selectedBookIds,\n chapterCount,\n endChapter,\n handleSelectEndChapter,\n startChapter,\n handleSelectStartChapter,\n localizedStrings,\n}: BookSelectorProps) {\n const currentBookText = localizeString(localizedStrings, '%webView_bookSelector_currentBook%');\n const chooseText = localizeString(localizedStrings, '%webView_bookSelector_choose%');\n const chooseBooksText = localizeString(localizedStrings, '%webView_bookSelector_chooseBooks%');\n\n const [bookSelectionMode, setBookSelectionMode] = useState(\n BookSelectionMode.CURRENT_BOOK,\n );\n\n const onSelectionModeChange = (newMode: BookSelectionMode) => {\n setBookSelectionMode(newMode);\n handleBookSelectionModeChange(newMode);\n };\n\n return (\n onSelectionModeChange(value as BookSelectionMode)}\n >\n
    \n
    \n
    \n \n \n
    \n \n
    \n \n
    \n
    \n
    \n
    \n \n \n
    \n \n onSelectBooks()}\n >\n {chooseText}\n \n
    \n
    \n \n );\n}\n","import { DropdownMenuTrigger } from '@radix-ui/react-dropdown-menu';\nimport { FilterIcon } from 'lucide-react';\nimport { Table } from '@tanstack/react-table';\n\nimport { Button } from '@/components/shadcn-ui/button';\nimport {\n DropdownMenu,\n DropdownMenuCheckboxItem,\n DropdownMenuContent,\n DropdownMenuLabel,\n DropdownMenuSeparator,\n} from '@/components/shadcn-ui/dropdown-menu';\n\ninterface DataTableViewOptionsProps {\n table: Table;\n}\n\nfunction DataTableViewOptions({ table }: DataTableViewOptionsProps) {\n return (\n \n \n \n \n \n Toggle columns\n \n {table\n .getAllColumns()\n .filter((column) => column.getCanHide())\n .map((column) => {\n return (\n column.toggleVisibility(!!value)}\n >\n {column.id}\n \n );\n })}\n \n \n );\n}\n\nexport default DataTableViewOptions;\n","import React from 'react';\nimport * as SelectPrimitive from '@radix-ui/react-select';\nimport { Check, ChevronDown, ChevronUp } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Select = SelectPrimitive.Root;\n\nconst SelectGroup = SelectPrimitive.Group;\n\nconst SelectValue = SelectPrimitive.Value;\n\nconst SelectTrigger = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, ...props }, ref) => (\n span]:tw-line-clamp-1',\n className,\n )}\n {...props}\n >\n {children}\n \n \n \n \n));\nSelectTrigger.displayName = SelectPrimitive.Trigger.displayName;\n\nconst SelectScrollUpButton = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n));\nSelectScrollUpButton.displayName = SelectPrimitive.ScrollUpButton.displayName;\n\nconst SelectScrollDownButton = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n));\nSelectScrollDownButton.displayName = SelectPrimitive.ScrollDownButton.displayName;\n\nconst SelectContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, position = 'popper', ...props }, ref) => (\n \n \n \n \n {children}\n \n \n \n \n));\nSelectContent.displayName = SelectPrimitive.Content.displayName;\n\nconst SelectLabel = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSelectLabel.displayName = SelectPrimitive.Label.displayName;\n\nconst SelectItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, ...props }, ref) => (\n \n \n \n \n \n \n\n {children}\n \n));\nSelectItem.displayName = SelectPrimitive.Item.displayName;\n\nconst SelectSeparator = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSelectSeparator.displayName = SelectPrimitive.Separator.displayName;\n\nexport {\n Select,\n SelectGroup,\n SelectValue,\n SelectTrigger,\n SelectContent,\n SelectLabel,\n SelectItem,\n SelectSeparator,\n SelectScrollUpButton,\n SelectScrollDownButton,\n};\n","import { ChevronLeftIcon, ChevronRightIcon, ArrowLeftIcon, ArrowRightIcon } from 'lucide-react';\nimport { Table } from '@tanstack/react-table';\n\nimport { Button } from '@/components/shadcn-ui/button';\nimport {\n Select,\n SelectContent,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\n\ninterface DataTablePaginationProps {\n table: Table;\n}\n\nfunction DataTablePagination({ table }: DataTablePaginationProps) {\n return (\n
    \n
    \n
    \n {table.getFilteredSelectedRowModel().rows.length} of{' '}\n {table.getFilteredRowModel().rows.length} row(s) selected\n
    \n
    \n

    Rows per page

    \n {\n table.setPageSize(Number(value));\n }}\n >\n \n \n \n \n {[10, 20, 30, 40, 50].map((pageSize) => (\n \n {pageSize}\n \n ))}\n \n \n
    \n
    \n Page {table.getState().pagination.pageIndex + 1} of {table.getPageCount()}\n
    \n
    \n table.setPageIndex(0)}\n disabled={!table.getCanPreviousPage()}\n >\n Go to first page\n \n \n table.previousPage()}\n disabled={!table.getCanPreviousPage()}\n >\n Go to previous page\n \n \n table.nextPage()}\n disabled={!table.getCanNextPage()}\n >\n Go to next page\n \n \n table.setPageIndex(table.getPageCount() - 1)}\n disabled={!table.getCanNextPage()}\n >\n Go to last page\n \n \n
    \n
    \n
    \n );\n}\n\nexport default DataTablePagination;\n","import React from 'react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Table = React.forwardRef<\n HTMLTableElement,\n React.HTMLAttributes & { stickyHeader?: boolean }\n>(({ className, stickyHeader, ...props }, ref) => (\n
    \n \n
    \n));\nTable.displayName = 'Table';\n\nconst TableHeader = React.forwardRef<\n HTMLTableSectionElement,\n React.HTMLAttributes & { stickyHeader?: boolean }\n>(({ className, stickyHeader, ...props }, ref) => (\n \n));\nTableHeader.displayName = 'TableHeader';\n\nconst TableBody = React.forwardRef<\n HTMLTableSectionElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableBody.displayName = 'TableBody';\n\nconst TableFooter = React.forwardRef<\n HTMLTableSectionElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n tr]:last:tw-border-b-0', className)}\n {...props}\n />\n));\nTableFooter.displayName = 'TableFooter';\n\nconst TableRow = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nTableRow.displayName = 'TableRow';\n\nconst TableHead = React.forwardRef<\n HTMLTableCellElement,\n React.ThHTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableHead.displayName = 'TableHead';\n\nconst TableCell = React.forwardRef<\n HTMLTableCellElement,\n React.TdHTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableCell.displayName = 'TableCell';\n\nconst TableCaption = React.forwardRef<\n HTMLTableCaptionElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableCaption.displayName = 'TableCaption';\n\nexport { Table, TableHeader, TableBody, TableFooter, TableHead, TableRow, TableCell, TableCaption };\n","import { useState } from 'react';\n\nimport {\n ColumnFiltersState,\n flexRender,\n getCoreRowModel,\n getFilteredRowModel,\n getPaginationRowModel,\n getSortedRowModel,\n SortingState,\n ColumnDef as TSColumnDef,\n Row as TSRow,\n RowSelectionState as TSRowSelectionState,\n SortDirection as TSSortDirection,\n Table as TSTable,\n useReactTable,\n VisibilityState,\n} from '@tanstack/react-table';\n\nimport DataTableViewOptions from '@/components/advanced/data-table/data-table-column-toggle.component';\nimport DataTablePagination from '@/components/advanced/data-table/data-table-pagination.component';\nimport { Button } from '@/components/shadcn-ui/button';\nimport {\n Table,\n TableBody,\n TableCell,\n TableHead,\n TableHeader,\n TableRow,\n} from '@/components/shadcn-ui/table';\n\nexport type ColumnDef = TSColumnDef;\nexport type RowContents = TSRow;\nexport type TableContents = TSTable;\nexport type SortDirection = TSSortDirection;\nexport type RowSelectionState = TSRowSelectionState;\n\ninterface DataTableProps {\n columns: ColumnDef[];\n data: TData[];\n enablePagination?: boolean;\n showPaginationControls?: boolean;\n showColumnVisibilityControls?: boolean;\n stickyHeader?: boolean;\n onRowClickHandler?: (row: RowContents, table: TableContents) => void;\n}\n\n/**\n * Feature-rich table component that infuses our basic shadcn-based Table component with features\n * from TanStack's React Table library\n */\nfunction DataTable({\n columns,\n data,\n enablePagination = false,\n showPaginationControls = false,\n showColumnVisibilityControls = false,\n stickyHeader = false,\n onRowClickHandler = () => {},\n}: DataTableProps) {\n const [sorting, setSorting] = useState([]);\n const [columnFilters, setColumnFilters] = useState([]);\n const [columnVisibility, setColumnVisibility] = useState({});\n const [rowSelection, setRowSelection] = useState({});\n\n const table = useReactTable({\n data,\n columns,\n getCoreRowModel: getCoreRowModel(),\n ...(enablePagination && { getPaginationRowModel: getPaginationRowModel() }),\n onSortingChange: setSorting,\n getSortedRowModel: getSortedRowModel(),\n onColumnFiltersChange: setColumnFilters,\n getFilteredRowModel: getFilteredRowModel(),\n onColumnVisibilityChange: setColumnVisibility,\n onRowSelectionChange: setRowSelection,\n state: {\n sorting,\n columnFilters,\n columnVisibility,\n rowSelection,\n },\n });\n\n return (\n
    \n {showColumnVisibilityControls && }\n \n \n {table.getHeaderGroups().map((headerGroup) => (\n \n {headerGroup.headers.map((header) => {\n return (\n \n {header.isPlaceholder\n ? undefined\n : flexRender(header.column.columnDef.header, header.getContext())}\n \n );\n })}\n \n ))}\n \n \n {table.getRowModel().rows?.length ? (\n table.getRowModel().rows.map((row) => (\n onRowClickHandler(row, table)}\n key={row.id}\n data-state={row.getIsSelected() && 'selected'}\n >\n {row.getVisibleCells().map((cell) => (\n \n {flexRender(cell.column.columnDef.cell, cell.getContext())}\n \n ))}\n \n ))\n ) : (\n \n \n No results.\n \n \n )}\n \n
    \n {enablePagination && (\n
    \n table.previousPage()}\n disabled={!table.getCanPreviousPage()}\n >\n Previous\n \n table.nextPage()}\n disabled={!table.getCanNextPage()}\n >\n Next\n \n
    \n )}\n {enablePagination && showPaginationControls && }\n
    \n );\n}\n\nexport default DataTable;\n","import {\n Table,\n TableBody,\n TableCell,\n TableHead,\n TableHeader,\n TableRow,\n} from '@/components/shadcn-ui/table';\nimport { Canon } from '@sillsdev/scripture';\nimport { deepEqual, LanguageStrings, ScriptureReference } from 'platform-bible-utils';\nimport { useMemo } from 'react';\nimport { InventoryItemOccurrence } from './inventory-utils';\n\n/** Props for the OccurrencesTable component */\ntype OccurrencesTableProps = {\n /** Data that contains scriptures references and snippets of scripture */\n occurrenceData: InventoryItemOccurrence[];\n /** Callback function that is executed when the scripture reference is changed */\n setScriptureReference: (scriptureReference: ScriptureReference) => void;\n /**\n * Object with all localized strings that the OccurrencesTable needs to work well across multiple\n * languages\n */\n localizedStrings: LanguageStrings;\n};\n\n/**\n * Table that shows occurrences of specified inventory item(s). The first column shows the related\n * scripture reference. The second column shows the snippet of scripture that contains the specified\n * inventory item\n */\nfunction OccurrencesTable({\n occurrenceData,\n setScriptureReference,\n localizedStrings,\n}: OccurrencesTableProps) {\n const referenceHeaderText =\n localizedStrings['%webView_inventory_occurrences_table_header_reference%'];\n const occurrenceHeaderText =\n localizedStrings['%webView_inventory_occurrences_table_header_occurrence%'];\n\n const occurrences: InventoryItemOccurrence[] = useMemo(() => {\n const uniqueOccurrences: InventoryItemOccurrence[] = [];\n\n occurrenceData.forEach((occurrence) => {\n if (!uniqueOccurrences.some((uniqueOccurrence) => deepEqual(uniqueOccurrence, occurrence))) {\n uniqueOccurrences.push(occurrence);\n }\n });\n\n return uniqueOccurrences;\n }, [occurrenceData]);\n\n return (\n \n \n \n {referenceHeaderText}\n {occurrenceHeaderText}\n \n \n \n {occurrences.length > 0 &&\n occurrences.map((occurrence) => (\n {\n setScriptureReference(occurrence.reference);\n }}\n >\n {`${Canon.bookNumberToEnglishName(occurrence.reference.bookNum)} ${occurrence.reference.chapterNum}:${occurrence.reference.verseNum}`}\n {occurrence.text}\n \n ))}\n \n
    \n );\n}\n\nexport default OccurrencesTable;\n","import React from 'react';\nimport * as CheckboxPrimitive from '@radix-ui/react-checkbox';\nimport { Check } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Checkbox = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n \n \n));\nCheckbox.displayName = CheckboxPrimitive.Root.displayName;\n\nexport default Checkbox;\n","import { Canon } from '@sillsdev/scripture';\nimport { ScriptureReference } from 'platform-bible-utils';\n\n/* #region Types */\n\n/**\n * Status of items that appear in inventories. 'approved' and 'unapproved' items are defined in the\n * project's `Settings.xml`. All other items are defined as 'unknown'\n */\nexport type Status = 'approved' | 'unapproved' | 'unknown';\n\n/** Occurrence of item in inventory. Primarily used by table that shows occurrences */\nexport type InventoryItemOccurrence = {\n /** Reference to scripture where the item appears */\n reference: ScriptureReference;\n /** Snippet of scripture that contains the occurrence */\n text: string;\n};\n\n/** Data structure that contains all information on an item that is shown in an inventory */\nexport type InventoryTableData = {\n /**\n * The item (e.g. a character in the characters inventory, a marker in the marker inventory) In\n * most cases the array will only have one element. In case of additional items (e.g. the\n * preceding marker in the markers check), the primary item should be stored in the first index.\n * To show additional items in the inventory, make sure to configure the `additionalItemsLabels`\n * prop for the Inventory component\n */\n items: string[];\n /** The number of times this item occurs in the selected scope */\n count: number;\n /** The status of this item (see documentation for `Status` type for more information) */\n status: Status;\n /** Occurrences of this item in the scripture text for the selected scope */\n occurrences: InventoryItemOccurrence[];\n};\n\n/* #endregion */\n\n/* #region Functions */\n\n/**\n * Splits USFM string into shorter line-like segments\n *\n * @param text A single (likely very large) USFM string\n * @returns An array containing the input text, split into shorter segments\n */\nexport const getLinesFromUSFM = (text: string) => {\n // Splits on (CR)LF, CR, \\v, \\c and \\id\n return text.split(/(?:\\r?\\n|\\r)|(?=(?:\\\\(?:v|c|id)))/g);\n};\n\n/**\n * Extracts chapter or verse number from USFM strings that start with a \\c or \\v marker\n *\n * @param text USFM string that is expected to start with \\c or \\v marker\n * @returns Chapter or verse number if one is found. Else returns 0.\n */\nexport const getNumberFromUSFM = (text: string): number | undefined => {\n // Captures all digits that follow \\v or \\c markers followed by whitespace located at the start of a string\n const regex = /^\\\\[vc]\\s+(\\d+)/;\n const match = text.match(regex);\n\n if (match) {\n return +match[1];\n }\n return undefined;\n};\n\n/**\n * Gets book ID from USFM string that starts with the \\id marker, and returns book number for it\n *\n * @param text USFM string that is expected to start with \\id marker\n * @returns Book number corresponding to the \\id marker in the input text. Returns 0 if no marker is\n * found or the marker is not valid\n */\nexport const getBookNumFromId = (text: string): number => {\n // Captures all digits that follow an \\id marker followed by whitespace located at the start of a string\n const match = text.match(/^\\\\id\\s+([A-Za-z]+)/);\n if (match) {\n return Canon.bookIdToNumber(match[1]);\n }\n return 0;\n};\n\n/**\n * Gets the status for an item, typically used in the Inventory component\n *\n * @param item The item for which the status is being requested\n * @param approvedItems Array of approved items, typically as defined in `Settings.xml`\n * @param unapprovedItems Array of unapproved items, typically as defined in `Settings.xml`\n * @returns The status for the specified item\n */\nexport const getStatusForItem = (\n item: string,\n approvedItems: string[],\n unapprovedItems: string[],\n): Status => {\n if (unapprovedItems.includes(item)) return 'unapproved';\n if (approvedItems.includes(item)) return 'approved';\n return 'unknown';\n};\n\n/* #endregion */\n","import React from 'react';\nimport * as TogglePrimitive from '@radix-ui/react-toggle';\nimport { cva, type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst toggleVariants = cva(\n 'pr-twp tw-inline-flex tw-items-center tw-justify-center tw-rounded-md tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-colors hover:tw-bg-muted hover:tw-text-muted-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50 data-[state=on]:tw-bg-accent data-[state=on]:tw-text-accent-foreground',\n {\n variants: {\n variant: {\n default: 'tw-bg-transparent',\n outline:\n 'tw-border tw-border-input tw-bg-transparent hover:tw-bg-accent hover:tw-text-accent-foreground',\n },\n size: {\n default: 'tw-h-10 tw-px-3',\n sm: 'tw-h-9 tw-px-2.5',\n lg: 'tw-h-11 tw-px-5',\n },\n },\n defaultVariants: {\n variant: 'default',\n size: 'default',\n },\n },\n);\n\nconst Toggle = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef & VariantProps\n>(({ className, variant, size, ...props }, ref) => (\n \n));\n\nToggle.displayName = TogglePrimitive.Root.displayName;\n\nexport { Toggle, toggleVariants };\n","import React from 'react';\nimport * as ToggleGroupPrimitive from '@radix-ui/react-toggle-group';\nimport { type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { toggleVariants } from '@/components/shadcn-ui/toggle';\n\nconst ToggleGroupContext = React.createContext>({\n size: 'default',\n variant: 'default',\n});\n\nconst ToggleGroup = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef &\n VariantProps\n>(({ className, variant, size, children, ...props }, ref) => (\n \n \n {children}\n \n \n));\n\nToggleGroup.displayName = ToggleGroupPrimitive.Root.displayName;\n\nconst ToggleGroupItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef &\n VariantProps\n>(({ className, children, variant, size, ...props }, ref) => {\n const context = React.useContext(ToggleGroupContext);\n\n return (\n \n {children}\n \n );\n});\n\nToggleGroupItem.displayName = ToggleGroupPrimitive.Item.displayName;\n\nexport { ToggleGroup, ToggleGroupItem };\n","import { ColumnDef, SortDirection } from '@/components/advanced/data-table/data-table.component';\nimport { Button } from '@/components/shadcn-ui/button';\nimport { ToggleGroup, ToggleGroupItem } from '@/components/shadcn-ui/toggle-group';\nimport {\n ArrowDownIcon,\n ArrowUpDownIcon,\n ArrowUpIcon,\n CircleCheckIcon,\n CircleHelpIcon,\n CircleXIcon,\n} from 'lucide-react';\nimport { ReactNode } from 'react';\nimport { InventoryTableData, Status } from './inventory-utils';\n\n/**\n * Gets an icon that indicates the current sorting direction based on the provided input\n *\n * @param sortDirection Sorting direction. Can be ascending ('asc'), descending ('desc') or false (\n * i.e. not sorted)\n * @returns The appropriate sorting icon for the provided sorting direction\n */\nconst getSortingIcon = (sortDirection: false | SortDirection): ReactNode => {\n if (sortDirection === 'asc') {\n return ;\n }\n if (sortDirection === 'desc') {\n return ;\n }\n return ;\n};\n\n/**\n * Function that creates the item column for inventories\n *\n * @param itemLabel Localized label for the item column (e.g. 'Character', 'Repeated Word', etc.)\n * @returns Column that shows the inventory items. Should be used with the DataTable component\n */\nexport const inventoryItemColumn = (itemLabel: string): ColumnDef => {\n return {\n accessorKey: 'item',\n accessorFn: (row: InventoryTableData) => row.items[0],\n header: ({ column }) => (\n \n ),\n };\n};\n\n/**\n * Function that creates the additional item columns for inventories\n *\n * @param additionalItemLabel Localized label for the additional item column (e.g. 'Preceding\n * Marker')\n * @param additionalItemIndex Index that locates the desired item in the items array of the\n * inventory\n * @returns Column that shows additional inventory items. Should be used with the DataTable\n * component\n */\nexport const inventoryAdditionalItemColumn = (\n additionalItemLabel: string,\n additionalItemIndex: number,\n): ColumnDef => {\n return {\n accessorKey: `item${additionalItemIndex}`,\n accessorFn: (row: InventoryTableData) => row.items[additionalItemIndex],\n header: ({ column }) => (\n \n ),\n };\n};\n\n/**\n * Function that creates the count column for inventories. Should be used with the DataTable\n * component.\n *\n * @param itemLabel Localized label for the count column\n * @returns Column that shows the number of occurrences of the related inventory items\n */\nexport const inventoryCountColumn = (countLabel: string): ColumnDef => {\n return {\n accessorKey: 'count',\n header: ({ column }) => (\n
    \n \n
    \n ),\n cell: ({ row }) =>
    {row.getValue('count')}
    ,\n };\n};\n\n/**\n * Function that updates project settings when status for item(s) changes\n *\n * @param changedItems Array of items for which the status is being updated\n * @param newStatus The status that the items are being given\n * @param approvedItems Array of currently approved items\n * @param onApprovedItemsChange Callback function that stores the updated list of approved items\n * @param unapprovedItems Array of currently unapproved items\n * @param onUnapprovedItemsChange Callback function that stores the updated list of unapproved items\n */\nconst statusChangeHandler = (\n changedItems: string[],\n newStatus: Status,\n approvedItems: string[],\n onApprovedItemsChange: (items: string[]) => void,\n unapprovedItems: string[],\n onUnapprovedItemsChange: (items: string[]) => void,\n) => {\n let newApprovedItems: string[] = [...approvedItems];\n changedItems.forEach((item) => {\n if (newStatus === 'approved') {\n if (!newApprovedItems.includes(item)) {\n newApprovedItems.push(item);\n }\n } else {\n newApprovedItems = newApprovedItems.filter((validItem) => validItem !== item);\n }\n });\n onApprovedItemsChange(newApprovedItems);\n\n let newUnapprovedItems: string[] = [...unapprovedItems];\n changedItems.forEach((item) => {\n if (newStatus === 'unapproved') {\n if (!newUnapprovedItems.includes(item)) {\n newUnapprovedItems.push(item);\n }\n } else {\n newUnapprovedItems = newUnapprovedItems.filter((unapprovedItem) => unapprovedItem !== item);\n }\n });\n onUnapprovedItemsChange(newUnapprovedItems);\n};\n\n/**\n * Function that creates the status column for inventories. Should be used with the DataTable\n * component.\n *\n * @param statusLabel Localized label for the status column\n * @param approvedItems Array of approved items, typically as defined in `Settings.xml`\n * @param onApprovedItemsChange Callback function that stores the updated list of approved items\n * @param unapprovedItems Array of unapproved items, typically as defined in `Settings.xml`\n * @param onUnapprovedItemsChange Callback function that stores the updated list of unapproved items\n * @returns Column that shows the status buttons for the related inventory item. The button for the\n * current status of the item is selected\n */\nexport const inventoryStatusColumn = (\n statusLabel: string,\n approvedItems: string[],\n onApprovedItemsChange: (items: string[]) => void,\n unapprovedItems: string[],\n onUnapprovedItemsChange: (items: string[]) => void,\n): ColumnDef => {\n return {\n accessorKey: 'status',\n header: ({ column }) => {\n return (\n
    \n \n
    \n );\n },\n cell: ({ row }) => {\n const status: Status = row.getValue('status');\n const item: string = row.getValue('item');\n return (\n \n \n statusChangeHandler(\n [item],\n 'approved',\n approvedItems,\n onApprovedItemsChange,\n unapprovedItems,\n onUnapprovedItemsChange,\n )\n }\n value=\"approved\"\n >\n \n \n \n statusChangeHandler(\n [item],\n 'unapproved',\n approvedItems,\n onApprovedItemsChange,\n unapprovedItems,\n onUnapprovedItemsChange,\n )\n }\n value=\"unapproved\"\n >\n \n \n \n statusChangeHandler(\n [item],\n 'unknown',\n approvedItems,\n onApprovedItemsChange,\n unapprovedItems,\n onUnapprovedItemsChange,\n )\n }\n value=\"unknown\"\n >\n \n \n \n );\n },\n };\n};\n","import DataTable, {\n ColumnDef,\n RowContents,\n RowSelectionState,\n TableContents,\n} from '@/components/advanced/data-table/data-table.component';\nimport OccurrencesTable from '@/components/advanced/inventory/occurrences-table.component';\nimport Checkbox from '@/components/shadcn-ui/checkbox';\nimport { Input } from '@/components/shadcn-ui/input';\nimport { Label } from '@/components/shadcn-ui/label';\nimport {\n Select,\n SelectContent,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\nimport {\n deepEqual,\n LocalizedStringValue,\n ScriptureReference,\n substring,\n} from 'platform-bible-utils';\nimport { useEffect, useMemo, useState } from 'react';\nimport {\n getBookNumFromId,\n getLinesFromUSFM,\n getNumberFromUSFM,\n getStatusForItem,\n InventoryItemOccurrence,\n InventoryTableData,\n Status,\n} from './inventory-utils';\nimport { inventoryAdditionalItemColumn } from './inventory-columns';\n\n/**\n * Object containing all keys used for localization in this component. If you're using this\n * component in an extension, you can pass it into the useLocalizedStrings hook to easily obtain the\n * localized strings and pass them into the localizedStrings prop of this component\n */\nexport const INVENTORY_STRING_KEYS = Object.freeze([\n '%webView_inventory_all%',\n '%webView_inventory_approved%',\n '%webView_inventory_unapproved%',\n '%webView_inventory_unknown%',\n '%webView_inventory_scope_currentBook%',\n '%webView_inventory_scope_chapter%',\n '%webView_inventory_scope_verse%',\n '%webView_inventory_filter_text%',\n '%webView_inventory_show_additional_items%',\n '%webView_inventory_occurrences_table_header_reference%',\n '%webView_inventory_occurrences_table_header_occurrence%',\n] as const);\n\nexport type InventoryLocalizedStrings = {\n [localizedInventoryKey in (typeof INVENTORY_STRING_KEYS)[number]]?: LocalizedStringValue;\n};\n\n/** Scope of scripture that the inventory can operate on */\nexport type Scope = 'book' | 'chapter' | 'verse';\n\n/** Status values that the status filter can select from */\ntype StatusFilter = Status | 'all';\n\n/** Text labels for the inventory columns and the control components of additional inventory items */\ntype AdditionalItemsLabels = {\n checkboxText?: string;\n tableHeaders?: string[];\n};\n\n/**\n * Filters data that is shown in the DataTable section of the Inventory\n *\n * @param itemData All inventory items and their related information\n * @param statusFilter Allows filtering by status (i.e. show all items, or only items that are\n * 'approved', 'unapproved' or 'unknown')\n * @param textFilter Allows filtering by text. All items that include the filter text will be\n * selected.\n * @returns Array of items and their related information that are matched by the specified filters\n */\nconst filterItemData = (\n itemData: InventoryTableData[],\n statusFilter: StatusFilter,\n textFilter: string,\n): InventoryTableData[] => {\n let filteredItemData: InventoryTableData[] = itemData;\n\n if (statusFilter !== 'all') {\n filteredItemData = filteredItemData.filter(\n (item) =>\n (statusFilter === 'approved' && item.status === 'approved') ||\n (statusFilter === 'unapproved' && item.status === 'unapproved') ||\n (statusFilter === 'unknown' && item.status === 'unknown'),\n );\n }\n\n if (textFilter !== '')\n filteredItemData = filteredItemData.filter((item) => item.items[0].includes(textFilter));\n\n return filteredItemData;\n};\n\n/**\n * Turns array of strings into array of inventory items, along with their count and status\n *\n * @param text The source scripture text that is searched for inventory items\n * @param scriptureRef The scripture reference that the application is currently set to\n * @param approvedItems Array of approved items, typically as defined in `Settings.xml`\n * @param unapprovedItems Array of unapproved items, typically as defined in `Settings.xml`\n * @param itemRegex Regular expression that describes what items this Inventory should extract from\n * the provided scripture text\n * @returns Array of inventory items, along with their count and status\n */\nconst createTableData = (\n text: string | undefined,\n scriptureRef: ScriptureReference,\n approvedItems: string[],\n unapprovedItems: string[],\n itemRegex: RegExp,\n): InventoryTableData[] => {\n if (!text) return [];\n\n const tableData: InventoryTableData[] = [];\n\n let currentBook: number | undefined = scriptureRef.bookNum;\n let currentChapter: number | undefined = scriptureRef.chapterNum;\n let currentVerse: number | undefined = scriptureRef.verseNum;\n\n const lines = getLinesFromUSFM(text);\n\n lines.forEach((line: string) => {\n if (line.startsWith('\\\\id')) {\n currentBook = getBookNumFromId(line);\n currentChapter = 0;\n currentVerse = 0;\n }\n if (line.startsWith('\\\\c')) {\n currentChapter = getNumberFromUSFM(line);\n currentVerse = 0;\n }\n if (line.startsWith('\\\\v')) {\n currentVerse = getNumberFromUSFM(line);\n if (currentChapter === 0) {\n currentChapter = scriptureRef.chapterNum;\n }\n }\n\n let match: RegExpExecArray | undefined = itemRegex.exec(line) ?? undefined;\n while (match) {\n const items: string[] = [];\n match.forEach((item) => items.push(item));\n const itemIndex = match.index;\n const existingItem = tableData.find((tableEntry) => deepEqual(tableEntry.items, items));\n const newReference: InventoryItemOccurrence = {\n reference: {\n bookNum: currentBook !== undefined ? currentBook : -1,\n chapterNum: currentChapter !== undefined ? currentChapter : -1,\n verseNum: currentVerse !== undefined ? currentVerse : -1,\n },\n text: substring(line, Math.max(0, itemIndex - 25), Math.min(itemIndex + 25, line.length)),\n };\n if (existingItem) {\n existingItem.count += 1;\n existingItem.occurrences.push(newReference);\n } else {\n const newItem: InventoryTableData = {\n items,\n count: 1,\n status: getStatusForItem(items[0], approvedItems, unapprovedItems),\n occurrences: [newReference],\n };\n tableData.push(newItem);\n }\n\n match = itemRegex.exec(line) ?? undefined;\n }\n });\n\n return tableData;\n};\n\n/**\n * Gets the localized value for the provided key\n *\n * @param strings Object containing localized string\n * @param key Key for a localized string\n * @returns The localized value for the provided key, if available. Returns the key if no localized\n * value is available\n */\nconst localizeString = (\n strings: InventoryLocalizedStrings,\n key: keyof InventoryLocalizedStrings,\n) => {\n return strings[key] ?? key;\n};\n\n/** Props for the Inventory component */\ntype InventoryProps = {\n /** The scripture reference that the application is currently set to */\n scriptureReference: ScriptureReference;\n /** Callback function that is executed when the scripture reference is changed */\n setScriptureReference: (scriptureReference: ScriptureReference) => void;\n /**\n * Object with all localized strings that the Inventory needs to work well across multiple\n * languages. When using this component with Platform.Bible, you can import\n * `INVENTORY_STRING_KEYS` from this library, pass it in to the Platform's localization hook, and\n * pass the localized keys that are returned by the hook into this prop.\n */\n localizedStrings: InventoryLocalizedStrings;\n /**\n * The logic that finds the desired items in the source text. This can either be a Regular\n * expression that captures one or multiple items (preferred), or a custom function that builds\n * and return an InventoryDataTable[] manually. Note: In case the logic captures more than one\n * item (i.e. InventoryTableData.items has a length greater than 1), you must provide text labels\n * for the related columns and control elements to show by setting the `additionalItemsLabels`\n * prop\n */\n extractItems:\n | RegExp\n | ((\n text: string | undefined,\n scriptureRef: ScriptureReference,\n approvedItems: string[],\n unapprovedItems: string[],\n ) => InventoryTableData[]);\n /**\n * Text labels for control elements and additional column headers in case your Inventory has more\n * than one item to show (e.g. The 'Preceding Marker' in the Markers Inventory)\n */\n additionalItemsLabels?: AdditionalItemsLabels;\n /** Array of approved items, typically as defined in `Settings.xml` */\n approvedItems: string[];\n /** Array of unapproved items, typically as defined in `Settings.xml` */\n unapprovedItems: string[];\n /** The source scripture text that is searched for in inventory items */\n text: string | undefined;\n /** Scope of scripture that the inventory will operate on */\n scope: Scope;\n /** Callback function that is executed when the scope is changed from the Inventory */\n onScopeChange: (scope: Scope) => void;\n /**\n * Column definitions for the Inventory data table. The most commonly used column definitions are\n * pre-configured for your convenience and can be imported (e.g. inventoryItemColumn,\n * inventoryAdditionalItemColumn inventoryCountColumn, and inventoryStatusColumn). If you need any\n * other columns you can add these yourself\n */\n columns: ColumnDef[];\n};\n\n/** Inventory component that is used to view and control the status of provided project settings */\nexport default function Inventory({\n scriptureReference,\n setScriptureReference,\n localizedStrings,\n extractItems,\n additionalItemsLabels,\n approvedItems,\n unapprovedItems,\n text,\n scope,\n onScopeChange,\n columns,\n}: InventoryProps) {\n const allItemsText = localizeString(localizedStrings, '%webView_inventory_all%');\n const approvedItemsText = localizeString(localizedStrings, '%webView_inventory_approved%');\n const unapprovedItemsText = localizeString(localizedStrings, '%webView_inventory_unapproved%');\n const unknownItemsText = localizeString(localizedStrings, '%webView_inventory_unknown%');\n const scopeBookText = localizeString(localizedStrings, '%webView_inventory_scope_currentBook%');\n const scopeChapterText = localizeString(localizedStrings, '%webView_inventory_scope_chapter%');\n const scopeVerseText = localizeString(localizedStrings, '%webView_inventory_scope_verse%');\n const filterText = localizeString(localizedStrings, '%webView_inventory_filter_text%');\n const showAdditionalItemsText = localizeString(\n localizedStrings,\n '%webView_inventory_show_additional_items%',\n );\n\n const [showAdditionalItems, setShowAdditionalItems] = useState(false);\n const [statusFilter, setStatusFilter] = useState('all');\n const [textFilter, setTextFilter] = useState('');\n const [selectedItem, setSelectedItem] = useState([]);\n\n const tableData: InventoryTableData[] = useMemo(() => {\n if (!text) return [];\n if (extractItems instanceof RegExp)\n return createTableData(\n text,\n scriptureReference,\n approvedItems,\n unapprovedItems,\n extractItems,\n );\n return extractItems(text, scriptureReference, approvedItems, unapprovedItems);\n }, [text, extractItems, scriptureReference, approvedItems, unapprovedItems]);\n\n const reducedTableData: InventoryTableData[] = useMemo(() => {\n if (showAdditionalItems) return tableData;\n\n const newTableData: InventoryTableData[] = [];\n\n tableData.forEach((tableEntry) => {\n const firstItem = tableEntry.items[0];\n\n const existingEntry = newTableData.find(\n (newTableEntry) => newTableEntry.items[0] === firstItem,\n );\n\n if (existingEntry) {\n existingEntry.count += tableEntry.count;\n existingEntry.occurrences = existingEntry.occurrences.concat(tableEntry.occurrences);\n } else {\n newTableData.push({\n items: [firstItem],\n count: tableEntry.count,\n occurrences: tableEntry.occurrences,\n status: tableEntry.status,\n });\n }\n });\n\n return newTableData;\n }, [showAdditionalItems, tableData]);\n\n const filteredTableData: InventoryTableData[] = useMemo(() => {\n return filterItemData(reducedTableData, statusFilter, textFilter);\n }, [reducedTableData, statusFilter, textFilter]);\n\n const allColumns: ColumnDef[] = useMemo(() => {\n if (!showAdditionalItems) return columns;\n\n const numberOfAdditionalItems = additionalItemsLabels?.tableHeaders?.length;\n if (!numberOfAdditionalItems) return columns;\n\n const additionalColumns: ColumnDef[] = [];\n\n for (let index = 0; index < numberOfAdditionalItems; index++) {\n additionalColumns.push(\n inventoryAdditionalItemColumn(\n additionalItemsLabels?.tableHeaders?.[index] || 'Additional Item',\n index + 1,\n ),\n );\n }\n\n return [...additionalColumns, ...columns];\n }, [additionalItemsLabels?.tableHeaders, columns, showAdditionalItems]);\n\n useEffect(() => {\n setSelectedItem([]);\n }, [filteredTableData]);\n\n const rowClickHandler = (\n row: RowContents,\n table: TableContents,\n ) => {\n table.setRowSelection(() => {\n const newSelection: RowSelectionState = {};\n newSelection[row.index] = true;\n return newSelection;\n });\n\n setSelectedItem(row.original.items);\n };\n\n const handleScopeChange = (value: string) => {\n if (value === 'book' || value === 'chapter' || value === 'verse') {\n onScopeChange(value);\n } else {\n throw new Error(`Invalid scope value: ${value}`);\n }\n };\n\n const handleStatusFilterChange = (value: string) => {\n if (value === 'all' || value === 'approved' || value === 'unapproved' || value === 'unknown') {\n setStatusFilter(value);\n } else {\n throw new Error(`Invalid status filter value: ${value}`);\n }\n };\n\n const occurrenceData: InventoryItemOccurrence[] = useMemo(() => {\n if (reducedTableData.length === 0 || selectedItem.length === 0) return [];\n const occurrence = reducedTableData.filter((tableEntry: InventoryTableData) => {\n return deepEqual(\n showAdditionalItems ? tableEntry.items : [tableEntry.items[0]],\n selectedItem,\n );\n });\n if (occurrence.length > 1) throw new Error('Selected item is not unique');\n return occurrence[0].occurrences;\n }, [selectedItem, showAdditionalItems, reducedTableData]);\n\n return (\n
    \n
    \n handleStatusFilterChange(value)}\n defaultValue={statusFilter}\n >\n \n \n \n \n {allItemsText}\n {approvedItemsText}\n {unapprovedItemsText}\n {unknownItemsText}\n \n \n \n {\n setTextFilter(event.target.value);\n }}\n />\n {additionalItemsLabels && (\n
    \n {\n setSelectedItem([]);\n setShowAdditionalItems(checked);\n }}\n />\n \n
    \n )}\n
    \n
    \n \n
    \n {occurrenceData.length > 0 && (\n
    \n \n
    \n )}\n
    \n );\n}\n","import { Input } from '@/components/shadcn-ui/input';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { useState } from 'react';\n\n/** Props for the SearchBar component. */\nexport type SearchBarProps = {\n /** Additional css classes to help with unique styling of the search bar */\n className?: string;\n /**\n * Callback fired to handle the search query when button pressed\n *\n * @param searchQuery\n */\n onSearch: (searchQuery: string) => void;\n\n /** Optional string that appears in the search bar without a search string */\n placeholder?: string;\n\n /** Optional boolean to set the input base to full width */\n isFullWidth?: boolean;\n};\n\nexport default function SearchBar({\n className,\n onSearch,\n placeholder,\n isFullWidth,\n}: SearchBarProps) {\n const [searchQuery, setSearchQuery] = useState('');\n\n const handleInputChange = (searchString: string) => {\n setSearchQuery(searchString);\n onSearch(searchString);\n };\n\n return (\n handleInputChange(e.target.value)}\n />\n );\n}\n","// adapted from: https://github.com/shadcn-ui/ui/discussions/752\n\n'use client';\n\nimport { TabsContentProps, TabsListProps, TabsTriggerProps } from '@/components/shadcn-ui/tabs';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport * as TabsPrimitive from '@radix-ui/react-tabs';\nimport React from 'react';\n\nexport type VerticalTabsProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport type LeftTabsTriggerProps = TabsTriggerProps & {\n value: string;\n ref?: React.Ref;\n};\n\nexport const VerticalTabs = React.forwardRef<\n React.ElementRef,\n VerticalTabsProps\n>(({ className, ...props }, ref) => (\n \n));\n\nVerticalTabs.displayName = TabsPrimitive.List.displayName;\n\nexport const VerticalTabsList = React.forwardRef<\n React.ElementRef,\n TabsListProps\n>(({ className, ...props }, ref) => (\n \n));\nVerticalTabsList.displayName = TabsPrimitive.List.displayName;\n\nexport const VerticalTabsTrigger = React.forwardRef<\n React.ElementRef,\n LeftTabsTriggerProps\n>(({ className, ...props }, ref) => (\n \n));\n\nexport const VerticalTabsContent = React.forwardRef<\n React.ElementRef,\n TabsContentProps\n>(({ className, ...props }, ref) => (\n \n));\nVerticalTabsContent.displayName = TabsPrimitive.Content.displayName;\n","import SearchBar from '@/components/basics/search-bar.component';\nimport {\n VerticalTabs,\n VerticalTabsContent,\n VerticalTabsList,\n VerticalTabsTrigger,\n} from '@/components/basics/tabs-vertical';\nimport { ReactNode } from 'react';\n\nexport type TabKeyValueContent = {\n key: string;\n value: string;\n content: ReactNode;\n};\n\nexport type TabNavigationContentSearchProps = {\n /** List of values and keys for each tab this component should provide */\n tabList: TabKeyValueContent[];\n\n /** Handler to run when the value of the search bar changes */\n onSearch: (searchQuery: string) => void;\n\n /** Optional placeholder for the search bar */\n searchPlaceholder?: string;\n\n /** Optional title to include in the header */\n headerTitle?: string;\n\n /** Optional flag to make the search bar appear full width */\n isSearchBarFullWidth?: boolean;\n\n /** Text direction ltr or rtl */\n direction?: 'ltr' | 'rtl';\n};\n\nexport default function TabNavigationContentSearch({\n tabList,\n onSearch,\n searchPlaceholder,\n headerTitle,\n isSearchBarFullWidth = false,\n direction = 'ltr',\n}: TabNavigationContentSearchProps) {\n return (\n
    \n
    \n {headerTitle ?

    {headerTitle}

    : ''}\n \n
    \n \n \n {tabList.map((tab) => (\n \n {tab.value}\n \n ))}\n \n {tabList.map((tab) => (\n \n {tab.content}\n \n ))}\n \n
    \n );\n}\n","import React from 'react';\nimport * as SeparatorPrimitive from '@radix-ui/react-separator';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Separator = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, orientation = 'horizontal', decorative = true, ...props }, ref) => (\n \n));\nSeparator.displayName = SeparatorPrimitive.Root.displayName;\n\nexport { Separator };\n","import React from 'react';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nfunction Skeleton({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\n\nexport { Skeleton };\n","import React from 'react';\nimport * as TooltipPrimitive from '@radix-ui/react-tooltip';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst TooltipProvider = TooltipPrimitive.Provider;\n\nconst Tooltip = TooltipPrimitive.Root;\n\nconst TooltipTrigger = TooltipPrimitive.Trigger;\n\nconst TooltipContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, sideOffset = 4, ...props }, ref) => (\n \n));\nTooltipContent.displayName = TooltipPrimitive.Content.displayName;\n\nexport { Tooltip, TooltipTrigger, TooltipContent, TooltipProvider };\n","import React from 'react';\nimport { Slot } from '@radix-ui/react-slot';\nimport { VariantProps, cva } from 'class-variance-authority';\nimport { PanelLeft } from 'lucide-react';\n\nimport { Button } from '@/components/shadcn-ui/button';\nimport { Input } from '@/components/shadcn-ui/input';\nimport { Separator } from '@/components/shadcn-ui/separator';\nimport { Skeleton } from '@/components/shadcn-ui/skeleton';\nimport {\n Tooltip,\n TooltipContent,\n TooltipProvider,\n TooltipTrigger,\n} from '@/components/shadcn-ui/tooltip';\nimport { cn } from '@/utils/shadcn-ui.util';\n\n/**\n * Changes from the original code from Shadcn- Removed uses of useIsMobile, Sheet, and SheetContent.\n * Also removed the parts setting COOKIES.\n */\n\nconst SIDEBAR_WIDTH = '16rem';\nconst SIDEBAR_WIDTH_ICON = '3rem';\n// Commented this out pending a discussion with UX about keyboard shortcuts\n// const SIDEBAR_KEYBOARD_SHORTCUT = 'b';\n\ntype SidebarContextProps = {\n state: 'expanded' | 'collapsed';\n open: boolean;\n setOpen: (open: boolean) => void;\n toggleSidebar: () => void;\n};\n\nconst SidebarContext = React.createContext(undefined);\n\nfunction useSidebar() {\n const context = React.useContext(SidebarContext);\n if (!context) {\n throw new Error('useSidebar must be used within a SidebarProvider.');\n }\n\n return context;\n}\n\nconst SidebarProvider = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & {\n defaultOpen?: boolean;\n open?: boolean;\n onOpenChange?: (open: boolean) => void;\n }\n>(\n (\n {\n defaultOpen = true,\n open: openProp,\n onOpenChange: setOpenProp,\n className,\n style,\n children,\n ...props\n },\n ref,\n ) => {\n // This is the internal state of the sidebar.\n // We use openProp and setOpenProp for control from outside the component.\n const [_open, _setOpen] = React.useState(defaultOpen);\n const isOpen = openProp ?? _open;\n const setOpen = React.useCallback(\n (value: boolean | ((value: boolean) => boolean)) => {\n const openState = typeof value === 'function' ? value(isOpen) : value;\n if (setOpenProp) {\n setOpenProp(openState);\n } else {\n _setOpen(openState);\n }\n },\n [setOpenProp, isOpen],\n );\n\n // Helper to toggle the sidebar.\n const toggleSidebar = React.useCallback(() => {\n return setOpen((open) => !open);\n }, [setOpen]);\n\n // Commented this out pending a discussion with UX about keyboard shortcuts\n // Adds a keyboard shortcut to toggle the sidebar.\n // React.useEffect(() => {\n // const handleKeyDown = (event: KeyboardEvent) => {\n // if (event.key === SIDEBAR_KEYBOARD_SHORTCUT && (event.metaKey || event.ctrlKey)) {\n // event.preventDefault();\n // toggleSidebar();\n // }\n // };\n\n // window.addEventListener('keydown', handleKeyDown);\n // return () => window.removeEventListener('keydown', handleKeyDown);\n // }, [toggleSidebar]);\n\n // We add a state so that we can do data-state=\"expanded\" or \"collapsed\".\n // This makes it easier to style the sidebar with Tailwind classes.\n const state = isOpen ? 'expanded' : 'collapsed';\n\n const contextValue = React.useMemo(\n () => ({\n state,\n open: isOpen,\n setOpen,\n toggleSidebar,\n }),\n [state, isOpen, setOpen, toggleSidebar],\n );\n\n return (\n \n \n \n {children}\n
    \n \n \n );\n },\n);\nSidebarProvider.displayName = 'SidebarProvider';\n\nconst Sidebar = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & {\n side?: 'left' | 'right';\n variant?: 'sidebar' | 'floating' | 'inset';\n collapsible?: 'offcanvas' | 'icon' | 'none';\n }\n>(\n (\n {\n side = 'left',\n variant = 'sidebar',\n collapsible = 'offcanvas',\n className,\n children,\n ...props\n },\n ref,\n ) => {\n const { state } = useSidebar();\n\n if (collapsible === 'none') {\n return (\n \n {children}\n
    \n );\n }\n\n return (\n \n {/* This is what handles the sidebar gap on desktop */}\n \n \n \n {children}\n
    \n
    \n
    \n );\n },\n);\nSidebar.displayName = 'Sidebar';\n\nconst SidebarTrigger = React.forwardRef<\n React.ElementRef,\n React.ComponentProps\n>(({ className, onClick, ...props }, ref) => {\n const { toggleSidebar } = useSidebar();\n\n return (\n {\n onClick?.(event);\n toggleSidebar();\n }}\n {...props}\n >\n \n Toggle Sidebar\n \n );\n});\nSidebarTrigger.displayName = 'SidebarTrigger';\n\nconst SidebarRail = React.forwardRef>(\n ({ className, ...props }, ref) => {\n const { toggleSidebar } = useSidebar();\n\n return (\n \n );\n },\n);\nSidebarRail.displayName = 'SidebarRail';\n\nconst SidebarInset = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarInset.displayName = 'SidebarInset';\n\nconst SidebarInput = React.forwardRef<\n React.ElementRef,\n React.ComponentProps\n>(({ className, ...props }, ref) => {\n return (\n \n );\n});\nSidebarInput.displayName = 'SidebarInput';\n\nconst SidebarHeader = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarHeader.displayName = 'SidebarHeader';\n\nconst SidebarFooter = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarFooter.displayName = 'SidebarFooter';\n\nconst SidebarSeparator = React.forwardRef<\n React.ElementRef,\n React.ComponentProps\n>(({ className, ...props }, ref) => {\n return (\n \n );\n});\nSidebarSeparator.displayName = 'SidebarSeparator';\n\nconst SidebarContent = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarContent.displayName = 'SidebarContent';\n\nconst SidebarGroup = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarGroup.displayName = 'SidebarGroup';\n\nconst SidebarGroupLabel = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & { asChild?: boolean }\n>(({ className, asChild = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'div';\n\n return (\n svg]:tw-size-4 [&>svg]:tw-shrink-0',\n 'group-data-[collapsible=icon]:tw--mt-8 group-data-[collapsible=icon]:tw-opacity-0',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarGroupLabel.displayName = 'SidebarGroupLabel';\n\nconst SidebarGroupAction = React.forwardRef<\n HTMLButtonElement,\n React.ComponentProps<'button'> & { asChild?: boolean }\n>(({ className, asChild = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'button';\n\n return (\n svg]:tw-size-4 [&>svg]:tw-shrink-0',\n // Increases the hit area of the button on mobile.\n 'after:tw-absolute after:tw--inset-2 after:md:tw-hidden',\n 'group-data-[collapsible=icon]:tw-hidden',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarGroupAction.displayName = 'SidebarGroupAction';\n\nconst SidebarGroupContent = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarGroupContent.displayName = 'SidebarGroupContent';\n\nconst SidebarMenu = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenu.displayName = 'SidebarMenu';\n\nconst SidebarMenuItem = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenuItem.displayName = 'SidebarMenuItem';\n\nconst sidebarMenuButtonVariants = cva(\n // Removed data-[active=true]:tw-bg-sidebar-accent\n 'tw-peer/menu-button tw-flex tw-w-full tw-items-center tw-gap-2 tw-overflow-hidden tw-rounded-md tw-p-2 tw-text-left tw-text-sm tw-outline-none tw-ring-sidebar-ring tw-transition-[width,height,padding] hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground focus-visible:tw-ring-2 active:tw-bg-sidebar-accent active:tw-text-sidebar-accent-foreground disabled:tw-pointer-events-none disabled:tw-opacity-50 tw-group-has-[[data-sidebar=menu-action]]/menu-item:pr-8 aria-disabled:tw-pointer-events-none aria-disabled:tw-opacity-50 data-[active=true]:tw-font-medium data-[active=true]:tw-text-sidebar-accent-foreground data-[state=open]:hover:tw-bg-sidebar-accent data-[state=open]:hover:tw-text-sidebar-accent-foreground group-data-[collapsible=icon]:tw-!size-8 group-data-[collapsible=icon]:tw-!p-2 [&>span:last-child]:tw-truncate [&>svg]:tw-size-4 [&>svg]:tw-shrink-0',\n {\n variants: {\n variant: {\n default: 'hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground',\n outline:\n 'tw-bg-background tw-shadow-[0_0_0_1px_hsl(var(--sidebar-border))] hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground hover:tw-shadow-[0_0_0_1px_hsl(var(--sidebar-accent))]',\n },\n size: {\n default: 'tw-h-8 tw-text-sm',\n sm: 'tw-h-7 tw-text-xs',\n lg: 'tw-h-12 tw-text-sm group-data-[collapsible=icon]:tw-!p-0',\n },\n },\n defaultVariants: {\n variant: 'default',\n size: 'default',\n },\n },\n);\n\nconst SidebarMenuButton = React.forwardRef<\n HTMLButtonElement,\n React.ComponentProps<'button'> & {\n asChild?: boolean;\n isActive?: boolean;\n tooltip?: string | React.ComponentProps;\n } & VariantProps\n>(\n (\n {\n asChild = false,\n isActive = false,\n variant = 'default',\n size = 'default',\n tooltip,\n className,\n ...props\n },\n ref,\n ) => {\n const Comp = asChild ? Slot : 'button';\n const { state } = useSidebar();\n\n const button = (\n \n );\n\n if (!tooltip) {\n return button;\n }\n\n if (typeof tooltip === 'string') {\n // eslint-disable-next-line no-param-reassign\n tooltip = {\n children: tooltip,\n };\n }\n\n return (\n \n {button}\n \n );\n },\n);\nSidebarMenuButton.displayName = 'SidebarMenuButton';\n\nconst SidebarMenuAction = React.forwardRef<\n HTMLButtonElement,\n React.ComponentProps<'button'> & {\n asChild?: boolean;\n showOnHover?: boolean;\n }\n>(({ className, asChild = false, showOnHover = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'button';\n\n return (\n svg]:tw-size-4 [&>svg]:tw-shrink-0',\n // Increases the hit area of the button on mobile.\n 'after:tw-absolute after:tw--inset-2 after:md:tw-hidden',\n 'tw-peer-data-[size=sm]/menu-button:top-1',\n 'tw-peer-data-[size=default]/menu-button:top-1.5',\n 'tw-peer-data-[size=lg]/menu-button:top-2.5',\n 'group-data-[collapsible=icon]:tw-hidden',\n showOnHover &&\n 'tw-group-focus-within/menu-item:opacity-100 tw-group-hover/menu-item:opacity-100 tw-peer-data-[active=true]/menu-button:text-sidebar-accent-foreground data-[state=open]:tw-opacity-100 md:tw-opacity-0',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarMenuAction.displayName = 'SidebarMenuAction';\n\nconst SidebarMenuBadge = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenuBadge.displayName = 'SidebarMenuBadge';\n\nconst SidebarMenuSkeleton = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & {\n showIcon?: boolean;\n }\n>(({ className, showIcon = false, ...props }, ref) => {\n // Random width between 50 to 90%.\n const width = React.useMemo(() => {\n return `${Math.floor(Math.random() * 40) + 50}%`;\n }, []);\n\n return (\n \n {showIcon && (\n \n )}\n \n
    \n );\n});\nSidebarMenuSkeleton.displayName = 'SidebarMenuSkeleton';\n\nconst SidebarMenuSub = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenuSub.displayName = 'SidebarMenuSub';\n\nconst SidebarMenuSubItem = React.forwardRef>(\n ({ ...props }, ref) =>
  • ,\n);\nSidebarMenuSubItem.displayName = 'SidebarMenuSubItem';\n\nconst SidebarMenuSubButton = React.forwardRef<\n HTMLAnchorElement,\n React.ComponentProps<'a'> & {\n asChild?: boolean;\n size?: 'sm' | 'md';\n isActive?: boolean;\n }\n>(({ asChild = false, size = 'md', isActive, className, ...props }, ref) => {\n const Comp = asChild ? Slot : 'a';\n\n return (\n svg]:tw-text-sidebar-accent-foreground tw-flex tw-h-7 tw-min-w-0 tw--translate-x-px tw-items-center tw-gap-2 tw-overflow-hidden tw-rounded-md tw-px-2 tw-outline-none focus-visible:tw-ring-2 disabled:tw-pointer-events-none disabled:tw-opacity-50 aria-disabled:tw-pointer-events-none aria-disabled:tw-opacity-50 [&>span:last-child]:tw-truncate [&>svg]:tw-size-4 [&>svg]:tw-shrink-0',\n 'data-[active=true]:tw-bg-sidebar-accent data-[active=true]:tw-text-sidebar-accent-foreground',\n size === 'sm' && 'tw-text-xs',\n size === 'md' && 'tw-text-sm',\n 'group-data-[collapsible=icon]:tw-hidden',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarMenuSubButton.displayName = 'SidebarMenuSubButton';\n\nexport {\n Sidebar,\n SidebarContent,\n SidebarFooter,\n SidebarGroup,\n SidebarGroupAction,\n SidebarGroupContent,\n SidebarGroupLabel,\n SidebarHeader,\n SidebarInput,\n SidebarInset,\n SidebarMenu,\n SidebarMenuAction,\n SidebarMenuBadge,\n SidebarMenuButton,\n SidebarMenuItem,\n SidebarMenuSkeleton,\n SidebarMenuSub,\n SidebarMenuSubButton,\n SidebarMenuSubItem,\n SidebarProvider,\n SidebarRail,\n SidebarSeparator,\n SidebarTrigger,\n useSidebar,\n};\n","import ComboBox, { ComboBoxOption } from '@/components/basics/combo-box.component';\nimport {\n Sidebar,\n SidebarContent,\n SidebarGroup,\n SidebarGroupLabel,\n SidebarGroupContent,\n SidebarMenu,\n SidebarMenuItem,\n SidebarMenuButton,\n} from '@/components/shadcn-ui/sidebar';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { useCallback } from 'react';\n\nexport type SelectedSettingsSidebarItem = {\n label: string;\n projectId?: string;\n};\n\nexport type ProjectInfo = { projectId: string; projectName: string };\n\nexport type SettingsSidebarProps = {\n /** Optional id for testing */\n id?: string;\n\n /** Extension labels from contribution */\n extensionLabels: string[];\n\n /** Project names and ids */\n projectInfo: ProjectInfo[];\n\n /** Handler for selecting a sidebar item */\n handleSelectSidebarItem: (key: string, projectId?: string) => void;\n\n /** The current selected value in the sidebar */\n selectedSidebarItem: SelectedSettingsSidebarItem;\n\n /** Label for the group of extensions setting groups */\n extensionsSidebarGroupLabel: string;\n\n /** Label for the group of projects settings */\n projectsSidebarGroupLabel: string;\n\n /** Placeholder text for the button */\n buttonPlaceholderText: string;\n};\n\nexport default function SettingsSidebar({\n id,\n extensionLabels,\n projectInfo,\n handleSelectSidebarItem,\n selectedSidebarItem,\n extensionsSidebarGroupLabel,\n projectsSidebarGroupLabel,\n buttonPlaceholderText,\n}: SettingsSidebarProps) {\n const handleSelectItem = useCallback(\n (item: string, projectId?: string) => {\n handleSelectSidebarItem(item, projectId);\n },\n [handleSelectSidebarItem],\n );\n\n const getProjectNameFromProjectId = useCallback(\n (projectId: string) => {\n const project = projectInfo.find((info) => info.projectId === projectId);\n return project ? project.projectName : projectId;\n },\n [projectInfo],\n );\n\n const getIsActive: (label: string) => boolean = useCallback(\n (label: string) => !selectedSidebarItem.projectId && label === selectedSidebarItem.label,\n [selectedSidebarItem],\n );\n\n return (\n \n \n \n \n {extensionsSidebarGroupLabel}\n \n \n \n {extensionLabels.map((label) => (\n \n handleSelectItem(label)}\n isActive={getIsActive(label)}\n >\n {label}\n \n \n ))}\n \n \n \n \n \n {projectsSidebarGroupLabel}\n \n \n info.projectId)}\n getOptionLabel={(projectId: ComboBoxOption) => {\n // This function expects a ComboBoxOption, but we know it is a string\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n return getProjectNameFromProjectId(projectId as string);\n }}\n buttonPlaceholder={buttonPlaceholderText}\n onChange={(projectId: string) => {\n const selectedProjectName = getProjectNameFromProjectId(projectId);\n handleSelectItem(selectedProjectName, projectId);\n }}\n value={selectedSidebarItem?.projectId ?? undefined}\n />\n \n \n \n \n );\n}\n","import { SidebarInset, SidebarProvider } from '@/components/shadcn-ui/sidebar';\nimport { PropsWithChildren } from 'react';\nimport SearchBar from '@/components/basics/search-bar.component';\nimport SettingsSidebar, { SettingsSidebarProps } from './settings-sidebar.component';\n\nexport type SettingsSidebarContentSearchProps = SettingsSidebarProps &\n PropsWithChildren & {\n /** Optional id for testing */\n id?: string;\n\n /** Handler to run when the value of the search bar changes */\n onSearch: (searchQuery: string) => void;\n };\n\nexport default function SettingsSidebarContentSearch({\n id,\n extensionLabels,\n projectInfo,\n children,\n handleSelectSidebarItem,\n selectedSidebarItem,\n onSearch,\n extensionsSidebarGroupLabel,\n projectsSidebarGroupLabel,\n buttonPlaceholderText,\n}: SettingsSidebarContentSearchProps) {\n return (\n
    \n
    \n \n
    \n \n \n {children}\n \n
    \n );\n}\n","import { Button } from '@/components/shadcn-ui/button';\nimport {\n Select,\n SelectContent,\n SelectGroup,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\nimport {\n Table,\n TableBody,\n TableCell,\n TableHead,\n TableHeader,\n TableRow,\n} from '@/components/shadcn-ui/table';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Canon } from '@sillsdev/scripture';\nimport {\n Cell,\n ColumnDef,\n flexRender,\n getCoreRowModel,\n getExpandedRowModel,\n getGroupedRowModel,\n getSortedRowModel,\n GroupingState,\n Row,\n RowSelectionState,\n SortingState,\n useReactTable,\n} from '@tanstack/react-table';\nimport '@/components/advanced/scripture-results-viewer/scripture-results-viewer.component.css';\nimport {\n compareScrRefs,\n formatScrRef,\n ScriptureSelection,\n scrRefToBBBCCCVVV,\n} from 'platform-bible-utils';\nimport { MouseEvent, useEffect, useMemo, useState } from 'react';\nimport { ChevronDown, ChevronLeft, ChevronRight } from 'lucide-react';\n\n/**\n * Information (e.g., a checking error or some other type of \"transient\" annotation) about something\n * noteworthy at a specific place in an instance of the Scriptures.\n */\nexport type ScriptureItemDetail = ScriptureSelection & {\n /**\n * Text of the error, note, etc. In the future, we might want to support something more than just\n * text so that a JSX element could be provided with a link or some other controls related to the\n * issue being reported.\n */\n detail: string;\n};\n\n/**\n * A uniquely identifiable source of results that can be displayed in the ScriptureResultsViewer.\n * Generally, the source will be a particular Scripture check, but there may be other types of\n * sources.\n */\nexport type ResultsSource = {\n /**\n * Uniquely identifies the source.\n *\n * @type {string}\n */\n id: string;\n\n /**\n * Name (potentially localized) of the source, suitable for display in the UI.\n *\n * @type {string}\n */\n displayName: string;\n};\n\nexport type ScriptureSrcItemDetail = ScriptureItemDetail & {\n /** Source/type of detail. Can be used for grouping. */\n source: ResultsSource;\n};\n\n/**\n * Represents a set of results keyed by Scripture reference. Generally, the source will be a\n * particular Scripture check, but this type also allows for other types of uniquely identifiable\n * sources.\n */\nexport type ResultsSet = {\n /**\n * The backing source associated with this set of results.\n *\n * @type {ResultsSource}\n */\n source: ResultsSource;\n\n /**\n * Array of Scripture item details (messages keyed by Scripture reference).\n *\n * @type {ScriptureItemDetail[]}\n */\n data: ScriptureItemDetail[];\n};\n\nconst scrBookColId = 'scrBook';\nconst scrRefColId = 'scrRef';\nconst typeColId = 'source';\nconst detailsColId = 'details';\n\nconst defaultScrRefColumnName = 'Scripture Reference';\nconst defaultScrBookGroupName = 'Scripture Book';\nconst defaultTypeColumnName = 'Type';\nconst defaultDetailsColumnName = 'Details';\n\nexport type ScriptureResultsViewerColumnInfo = {\n /** Optional header to display for the Reference column. Default value: 'Scripture Reference'. */\n scriptureReferenceColumnName?: string;\n\n /** Optional text to display to refer to the Scripture book group. Default value: 'Scripture Book'. */\n scriptureBookGroupName?: string;\n\n /** Optional header to display for the Type column. Default value: 'Type'. */\n typeColumnName?: string;\n\n /** Optional header to display for the Details column. Default value: 'Details' */\n detailsColumnName?: string;\n};\n\nexport type ScriptureResultsViewerProps = ScriptureResultsViewerColumnInfo & {\n /** Groups of ScriptureItemDetail objects from particular sources (e.g., Scripture checks) */\n sources: ResultsSet[];\n\n /** Flag indicating whether to display column headers. Default is false. */\n showColumnHeaders?: boolean;\n\n /** Flag indicating whether to display source column. Default is false. */\n showSourceColumn?: boolean;\n\n /** Callback function to notify when a row is selected */\n onRowSelected?: (selectedRow: ScriptureSrcItemDetail | undefined) => void;\n\n /** Text direction ltr or rtl */\n direction?: 'ltr' | 'rtl';\n};\n\nfunction getColumns(\n colInfo?: ScriptureResultsViewerColumnInfo,\n showSourceColumn?: boolean,\n): ColumnDef[] {\n const showSrcCol = showSourceColumn ?? false;\n return [\n {\n accessorFn: (row) =>\n `${Canon.bookNumberToId(row.start.bookNum)} ${row.start.chapterNum}:${row.start.verseNum}`,\n id: scrBookColId,\n header: colInfo?.scriptureReferenceColumnName ?? defaultScrRefColumnName,\n cell: (info) => {\n const row = info.row.original;\n if (info.row.getIsGrouped()) {\n return Canon.bookNumberToEnglishName(row.start.bookNum);\n }\n return info.row.groupingColumnId === scrBookColId ? formatScrRef(row.start) : undefined;\n },\n getGroupingValue: (row) => row.start.bookNum,\n sortingFn: (a, b) => {\n return compareScrRefs(a.original.start, b.original.start);\n },\n enableGrouping: true,\n },\n {\n accessorFn: (row) => formatScrRef(row.start),\n id: scrRefColId,\n header: undefined,\n cell: (info) => {\n const row = info.row.original;\n return info.row.getIsGrouped() ? undefined : formatScrRef(row.start);\n },\n sortingFn: (a, b) => {\n return compareScrRefs(a.original.start, b.original.start);\n },\n enableGrouping: false,\n },\n {\n accessorFn: (row) => row.source.displayName,\n id: typeColId,\n header: showSrcCol ? (colInfo?.typeColumnName ?? defaultTypeColumnName) : undefined,\n cell: (info) => (showSrcCol || info.row.getIsGrouped() ? info.getValue() : undefined),\n getGroupingValue: (row) => row.source.id,\n sortingFn: (a, b) =>\n a.original.source.displayName.localeCompare(b.original.source.displayName),\n enableGrouping: true,\n },\n {\n accessorFn: (row) => row.detail,\n id: detailsColId,\n header: colInfo?.detailsColumnName ?? defaultDetailsColumnName,\n cell: (info) => info.getValue(),\n enableGrouping: false,\n },\n ];\n}\n\nconst toRefOrRange = (scriptureSelection: ScriptureSelection) => {\n if (!('offset' in scriptureSelection.start))\n throw new Error('No offset available in range start');\n if (scriptureSelection.end && !('offset' in scriptureSelection.end))\n throw new Error('No offset available in range end');\n const { offset: offsetStart } = scriptureSelection.start;\n let offsetEnd: number = 0;\n if (scriptureSelection.end) ({ offset: offsetEnd } = scriptureSelection.end);\n if (\n !scriptureSelection.end ||\n compareScrRefs(scriptureSelection.start, scriptureSelection.end) === 0\n )\n return `${scrRefToBBBCCCVVV(scriptureSelection.start)}+${offsetStart}`;\n return `${scrRefToBBBCCCVVV(scriptureSelection.start)}+${offsetStart}-${scrRefToBBBCCCVVV(scriptureSelection.end)}+${offsetEnd}`;\n};\n\nconst getRowKey = (row: ScriptureSrcItemDetail) =>\n `${toRefOrRange({ start: row.start, end: row.end })} ${row.source.displayName} ${row.detail}`;\n\n/**\n * Component to display a combined list of detailed items from one or more sources, where the items\n * are keyed primarily by Scripture reference. This is particularly useful for displaying a list of\n * results from Scripture checks, but more generally could be used to display any \"results\" from any\n * source(s). The component allows for grouping by Scripture book, source, or both. By default, it\n * displays somewhat \"tree-like\" which allows it to be more horizontally compact and intuitive. But\n * it also has the option of displaying as a traditional table with column headings (with or without\n * the source column showing).\n */\nexport default function ScriptureResultsViewer({\n sources,\n showColumnHeaders = false,\n showSourceColumn = false,\n scriptureReferenceColumnName,\n scriptureBookGroupName,\n typeColumnName,\n detailsColumnName,\n onRowSelected,\n direction = 'ltr',\n}: ScriptureResultsViewerProps) {\n const [grouping, setGrouping] = useState([]);\n const [sorting, setSorting] = useState([{ id: scrBookColId, desc: false }]);\n const [rowSelection, setRowSelection] = useState({});\n\n const scriptureResults = useMemo(\n () =>\n sources.flatMap((source) => {\n return source.data.map((item) => ({\n ...item,\n source: source.source,\n }));\n }),\n [sources],\n );\n\n const columns = useMemo(\n () =>\n getColumns(\n {\n scriptureReferenceColumnName,\n typeColumnName,\n detailsColumnName,\n },\n showSourceColumn,\n ),\n [scriptureReferenceColumnName, typeColumnName, detailsColumnName, showSourceColumn],\n );\n\n useEffect(() => {\n // Ensure sorting is applied correctly when grouped by type\n if (grouping.includes(typeColId)) {\n setSorting([\n { id: typeColId, desc: false },\n { id: scrBookColId, desc: false },\n ]);\n } else {\n setSorting([{ id: scrBookColId, desc: false }]);\n }\n }, [grouping]);\n\n const table = useReactTable({\n data: scriptureResults,\n columns,\n state: {\n grouping,\n sorting,\n rowSelection,\n },\n onGroupingChange: setGrouping,\n onSortingChange: setSorting,\n onRowSelectionChange: setRowSelection,\n getExpandedRowModel: getExpandedRowModel(),\n getGroupedRowModel: getGroupedRowModel(),\n getCoreRowModel: getCoreRowModel(),\n getSortedRowModel: getSortedRowModel(),\n getRowId: getRowKey,\n autoResetExpanded: false,\n enableMultiRowSelection: false,\n enableSubRowSelection: false,\n });\n\n useEffect(() => {\n if (onRowSelected) {\n const selectedRows = table.getSelectedRowModel().rowsById;\n const keys = Object.keys(selectedRows);\n if (keys.length === 1) {\n const selectedRow = scriptureResults.find((row) => getRowKey(row) === keys[0]) || undefined;\n if (selectedRow) onRowSelected(selectedRow);\n }\n }\n }, [rowSelection, scriptureResults, onRowSelected, table]);\n\n // Define possible grouping options\n const scrBookGroupName = scriptureBookGroupName ?? defaultScrBookGroupName;\n const typeGroupName = typeColumnName ?? defaultTypeColumnName;\n\n const groupingOptions = [\n { label: 'No Grouping', value: [] },\n { label: `Group by ${scrBookGroupName}`, value: [scrBookColId] },\n { label: `Group by ${typeGroupName}`, value: [typeColId] },\n {\n label: `Group by ${scrBookGroupName} and ${typeGroupName}`,\n value: [scrBookColId, typeColId],\n },\n {\n label: `Group by ${typeGroupName} and ${scrBookGroupName}`,\n value: [typeColId, scrBookColId],\n },\n ];\n\n const handleSelectChange = (selectedGrouping: string) => {\n setGrouping(JSON.parse(selectedGrouping));\n };\n\n const handleRowClick = (row: Row, event: MouseEvent) => {\n if (!row.getIsGrouped() && !row.getIsSelected()) {\n row.getToggleSelectedHandler()(event);\n }\n };\n\n const getEvenOrOddBandingStyle = (row: Row, index: number) => {\n if (row.getIsGrouped()) return '';\n // UX has now said they don't think they want banding. I'm leaving in the code to\n // set even and odd styles, but there's nothing in the CSS to style them differently.\n // The \"even\" style used to also have tw-bg-neutral-300 (along with even) to create\n // a visual banding effect. That could be added back in if UX changes the decision.\n return cn('banded-row', index % 2 === 0 ? 'even' : 'odd');\n };\n\n const getIndent = (\n groupingState: GroupingState,\n row: Row,\n cell: Cell,\n ) => {\n if (groupingState?.length === 0 || row.depth < cell.column.getGroupedIndex()) return undefined;\n if (row.getIsGrouped()) {\n switch (row.depth) {\n case 1:\n return 'tw-ps-4';\n default:\n return undefined;\n }\n }\n switch (row.depth) {\n case 1:\n return 'tw-ps-8';\n case 2:\n return 'tw-ps-12';\n default:\n return undefined;\n }\n };\n\n return (\n
    \n {!showColumnHeaders && (\n {\n handleSelectChange(value);\n }}\n >\n \n \n \n \n \n {groupingOptions.map((option) => (\n \n {option.label}\n \n ))}\n \n \n \n )}\n \n {showColumnHeaders && (\n \n {table.getHeaderGroups().map((headerGroup) => (\n \n {headerGroup.headers\n .filter((h) => h.column.columnDef.header)\n .map((header) => (\n /* For sticky column headers to work, we probably need to change the default definition of the shadcn Table component. See https://github.com/shadcn-ui/ui/issues/1151 */\n \n {header.isPlaceholder ? undefined : (\n
    \n {header.column.getCanGroup() ? (\n \n {header.column.getIsGrouped() ? `🛑` : `👊 `}\n \n ) : undefined}{' '}\n {flexRender(header.column.columnDef.header, header.getContext())}\n
    \n )}\n
    \n ))}\n
    \n ))}\n
    \n )}\n \n {table.getRowModel().rows.map((row, rowIndex) => {\n return (\n handleRowClick(row, event)}\n >\n {row.getVisibleCells().map((cell) => {\n if (\n cell.getIsPlaceholder() ||\n (cell.column.columnDef.enableGrouping &&\n !cell.getIsGrouped() &&\n (cell.column.columnDef.id !== typeColId || !showSourceColumn))\n )\n return undefined;\n return (\n \n {(() => {\n if (cell.getIsGrouped()) {\n return (\n \n {row.getIsExpanded() && }\n {!row.getIsExpanded() &&\n (direction === 'ltr' ? : )}{' '}\n {flexRender(cell.column.columnDef.cell, cell.getContext())} (\n {row.subRows.length})\n \n );\n }\n\n // if (cell.getIsAggregated()) {\n // flexRender(\n // cell.column.columnDef.aggregatedCell ?? cell.column.columnDef.cell,\n // cell.getContext(),\n // );\n // }\n\n return flexRender(cell.column.columnDef.cell, cell.getContext());\n })()}\n \n );\n })}\n \n );\n })}\n \n
    \n
    \n );\n}\n","import {\n getLocalizeKeyForScrollGroupId,\n LanguageStrings,\n ScrollGroupId,\n} from 'platform-bible-utils';\nimport {\n Select,\n SelectContent,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\n\nconst DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS = {\n [getLocalizeKeyForScrollGroupId('undefined')]: 'Ø',\n [getLocalizeKeyForScrollGroupId(0)]: 'A',\n [getLocalizeKeyForScrollGroupId(1)]: 'B',\n [getLocalizeKeyForScrollGroupId(2)]: 'C',\n [getLocalizeKeyForScrollGroupId(3)]: 'D',\n [getLocalizeKeyForScrollGroupId(4)]: 'E',\n [getLocalizeKeyForScrollGroupId(5)]: 'F',\n [getLocalizeKeyForScrollGroupId(6)]: 'G',\n [getLocalizeKeyForScrollGroupId(7)]: 'H',\n [getLocalizeKeyForScrollGroupId(8)]: 'I',\n [getLocalizeKeyForScrollGroupId(9)]: 'J',\n [getLocalizeKeyForScrollGroupId(10)]: 'K',\n [getLocalizeKeyForScrollGroupId(11)]: 'L',\n [getLocalizeKeyForScrollGroupId(12)]: 'M',\n [getLocalizeKeyForScrollGroupId(13)]: 'N',\n [getLocalizeKeyForScrollGroupId(14)]: 'O',\n [getLocalizeKeyForScrollGroupId(15)]: 'P',\n [getLocalizeKeyForScrollGroupId(16)]: 'Q',\n [getLocalizeKeyForScrollGroupId(17)]: 'R',\n [getLocalizeKeyForScrollGroupId(18)]: 'S',\n [getLocalizeKeyForScrollGroupId(19)]: 'T',\n [getLocalizeKeyForScrollGroupId(20)]: 'U',\n [getLocalizeKeyForScrollGroupId(21)]: 'V',\n [getLocalizeKeyForScrollGroupId(22)]: 'W',\n [getLocalizeKeyForScrollGroupId(23)]: 'X',\n [getLocalizeKeyForScrollGroupId(24)]: 'Y',\n [getLocalizeKeyForScrollGroupId(25)]: 'Z',\n};\n\nexport type ScrollGroupSelectorProps = {\n /**\n * List of scroll group ids to show to the user. Either a {@link ScrollGroupId} or `undefined` for\n * no scroll group\n */\n availableScrollGroupIds: (ScrollGroupId | undefined)[];\n /** Currently selected scroll group id. `undefined` for no scroll group */\n scrollGroupId: ScrollGroupId | undefined;\n /** Callback function run when the user tries to change the scroll group id */\n onChangeScrollGroupId: (newScrollGroupId: ScrollGroupId | undefined) => void;\n /**\n * Localized strings to use for displaying scroll group ids. Must be an object whose keys are\n * `getLocalizeKeyForScrollGroupId(scrollGroupId)` for all scroll group ids (and `undefined` if\n * included) in {@link ScrollGroupSelectorProps.availableScrollGroupIds} and whose values are the\n * localized strings to use for those scroll group ids.\n *\n * Defaults to English localizations of English alphabet for scroll groups 0-25 (e.g. 0 is A) and\n * Ø for `undefined`. Will fill in any that are not provided with these English localizations.\n * Also, if any values match the keys, the English localization will be used. This is useful in\n * case you want to pass in a temporary version of the localized strings while your localized\n * strings load.\n *\n * @example\n *\n * ```typescript\n * const myScrollGroupIdLocalizedStrings = {\n * [getLocalizeKeyForScrollGroupId('undefined')]: 'Ø',\n * [getLocalizeKeyForScrollGroupId(0)]: 'A',\n * [getLocalizeKeyForScrollGroupId(1)]: 'B',\n * [getLocalizeKeyForScrollGroupId(2)]: 'C',\n * [getLocalizeKeyForScrollGroupId(3)]: 'D',\n * [getLocalizeKeyForScrollGroupId(4)]: 'E',\n * };\n * ```\n *\n * @example\n *\n * ```tsx\n * const availableScrollGroupIds = [undefined, 0, 1, 2, 3, 4];\n *\n * const localizeKeys = getLocalizeKeysForScrollGroupIds();\n *\n * const [localizedStrings] = useLocalizedStrings(localizeKeys);\n *\n * ...\n *\n * \n * ```\n */\n localizedStrings?: LanguageStrings;\n};\n\n/** Selector component for choosing a scroll group */\nexport default function ScrollGroupSelector({\n availableScrollGroupIds,\n scrollGroupId,\n onChangeScrollGroupId,\n localizedStrings = {},\n}: ScrollGroupSelectorProps) {\n const localizedStringsDefaulted = {\n ...DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS,\n ...Object.fromEntries(\n Object.entries(localizedStrings).map(\n ([localizedStringKey, localizedStringValue]: [string, string]) => [\n localizedStringKey,\n localizedStringKey === localizedStringValue &&\n localizedStringKey in DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS\n ? DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS[localizedStringKey]\n : localizedStringValue,\n ],\n ),\n ),\n };\n return (\n \n onChangeScrollGroupId(\n newScrollGroupString === 'undefined' ? undefined : parseInt(newScrollGroupString, 10),\n )\n }\n >\n \n \n \n \n {availableScrollGroupIds.map((scrollGroupOptionId) => (\n \n {localizedStringsDefaulted[getLocalizeKeyForScrollGroupId(scrollGroupOptionId)]}\n \n ))}\n \n \n );\n}\n","import { PropsWithChildren } from 'react';\nimport { Separator } from '@/components/shadcn-ui/separator';\n\n/** Props for the SettingsList component, currently just children */\ntype SettingsListProps = PropsWithChildren;\n\n/**\n * SettingsList component is a wrapper for list items. Rendered with a formatted div\n *\n * @param children To populate the list with\n * @returns Formatted div encompassing the children\n */\nexport function SettingsList({ children }: SettingsListProps) {\n return
    {children}
    ;\n}\n\n/** Props for SettingsListItem component */\ntype SettingsListItemProps = PropsWithChildren & {\n /** Primary text of the list item */\n primary: string;\n\n /** Optional text of the list item */\n secondary?: string | undefined;\n\n /** Optional boolean to display a message if the children aren't loaded yet. Defaults to false */\n isLoading?: boolean;\n\n /** Optional message to display if isLoading */\n loadingMessage?: string;\n};\n\n/**\n * SettingsListItem component is a common list item. Rendered with a formatted div\n *\n * @param primary Primary text of the list item\n * @param secondary Optional secondary text of the list item\n * @param isLoading Optional, to display a message if the action component isn't generated yet,\n * defaults to false\n * @param children The action component(s) to provide for this item\n * @param loadingMessage Optional, message to display if isLoading\n * @returns Formatted div encompassing the list item content\n */\nexport function SettingsListItem({\n primary,\n secondary,\n children,\n isLoading = false,\n loadingMessage,\n}: SettingsListItemProps) {\n return (\n
    \n
    \n

    {primary}

    \n

    \n {secondary}\n

    \n
    \n\n {isLoading ? (\n

    {loadingMessage}

    \n ) : (\n
    {children}
    \n )}\n
    \n );\n}\n\n/** Props for SettingsListHeader component */\ntype SettingsListHeaderProps = {\n /** The primary text of the list header */\n primary: string;\n\n /** Optional secondary text of the list header */\n secondary?: string | undefined;\n\n /** Optional boolean to include a separator underneath the secondary text. Defaults to false */\n includeSeparator?: boolean;\n};\n\n/**\n * SettingsListHeader component displays text above the list\n *\n * @param primary The primary text of the list header\n * @param secondary Optional secondary text of the list header\n * @param includeSeparator Optional boolean to include a separator underneath the secondary text.\n * Defaults to false\n * @returns Formatted div with list header content\n */\nexport function SettingsListHeader({\n primary,\n secondary,\n includeSeparator = false,\n}: SettingsListHeaderProps) {\n return (\n
    \n
    \n

    {primary}

    \n

    {secondary}

    \n
    \n {includeSeparator ? : ''}\n
    \n );\n}\n","import Checkbox from '@/components/shadcn-ui/checkbox';\nimport { Label } from '@/components/shadcn-ui/label';\n\nexport type ChecklistProps = {\n /** Optional string representing the id attribute of the Checklist */\n id?: string;\n /** Optional string representing CSS class name(s) for styling */\n className?: string;\n /** Array of strings representing the checkable items */\n listItems: string[];\n /** Array of strings representing the checked items */\n selectedListItems: string[];\n /**\n * Function that is called when a checkbox item is selected or deselected\n *\n * @param item The string description for this item\n * @param selected True if selected, false if not selected\n */\n handleSelectListItem: (item: string, selected: boolean) => void;\n\n /**\n * Optional function creates a label for a provided checkable item\n *\n * @param item The item for which a label is to be created\n * @returns A string representing the label text for the checkbox associated with that item\n */\n createLabel?: (item: string) => string;\n};\n\n/** Renders a list of checkboxes. Each checkbox corresponds to an item from the `listItems` array. */\nexport default function Checklist({\n id,\n className,\n listItems,\n selectedListItems,\n handleSelectListItem,\n createLabel,\n}: ChecklistProps) {\n return (\n
    \n {listItems.map((item) => (\n
    \n handleSelectListItem(item, value)}\n />\n \n
    \n ))}\n
    \n );\n}\n","function _interopRequireDefault(obj) {\n return obj && obj.__esModule ? obj : {\n \"default\": obj\n };\n}\nmodule.exports = _interopRequireDefault, module.exports.__esModule = true, module.exports[\"default\"] = module.exports;","export default function chainPropTypes(propType1, propType2) {\n if (process.env.NODE_ENV === 'production') {\n return () => null;\n }\n return function validate(...args) {\n return propType1(...args) || propType2(...args);\n };\n}","export default function _extends() {\n _extends = Object.assign ? Object.assign.bind() : function (target) {\n for (var i = 1; i < arguments.length; i++) {\n var source = arguments[i];\n for (var key in source) {\n if (Object.prototype.hasOwnProperty.call(source, key)) {\n target[key] = source[key];\n }\n }\n }\n return target;\n };\n return _extends.apply(this, arguments);\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\n// https://github.com/sindresorhus/is-plain-obj/blob/main/index.js\nexport function isPlainObject(item) {\n if (typeof item !== 'object' || item === null) {\n return false;\n }\n const prototype = Object.getPrototypeOf(item);\n return (prototype === null || prototype === Object.prototype || Object.getPrototypeOf(prototype) === null) && !(Symbol.toStringTag in item) && !(Symbol.iterator in item);\n}\nfunction deepClone(source) {\n if (!isPlainObject(source)) {\n return source;\n }\n const output = {};\n Object.keys(source).forEach(key => {\n output[key] = deepClone(source[key]);\n });\n return output;\n}\nexport default function deepmerge(target, source, options = {\n clone: true\n}) {\n const output = options.clone ? _extends({}, target) : target;\n if (isPlainObject(target) && isPlainObject(source)) {\n Object.keys(source).forEach(key => {\n // Avoid prototype pollution\n if (key === '__proto__') {\n return;\n }\n if (isPlainObject(source[key]) && key in target && isPlainObject(target[key])) {\n // Since `output` is a clone of `target` and we have narrowed `target` in this block we can cast to the same type.\n output[key] = deepmerge(target[key], source[key], options);\n } else if (options.clone) {\n output[key] = isPlainObject(source[key]) ? deepClone(source[key]) : source[key];\n } else {\n output[key] = source[key];\n }\n });\n }\n return output;\n}","/** @license React v16.13.1\n * react-is.production.min.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';var b=\"function\"===typeof Symbol&&Symbol.for,c=b?Symbol.for(\"react.element\"):60103,d=b?Symbol.for(\"react.portal\"):60106,e=b?Symbol.for(\"react.fragment\"):60107,f=b?Symbol.for(\"react.strict_mode\"):60108,g=b?Symbol.for(\"react.profiler\"):60114,h=b?Symbol.for(\"react.provider\"):60109,k=b?Symbol.for(\"react.context\"):60110,l=b?Symbol.for(\"react.async_mode\"):60111,m=b?Symbol.for(\"react.concurrent_mode\"):60111,n=b?Symbol.for(\"react.forward_ref\"):60112,p=b?Symbol.for(\"react.suspense\"):60113,q=b?\nSymbol.for(\"react.suspense_list\"):60120,r=b?Symbol.for(\"react.memo\"):60115,t=b?Symbol.for(\"react.lazy\"):60116,v=b?Symbol.for(\"react.block\"):60121,w=b?Symbol.for(\"react.fundamental\"):60117,x=b?Symbol.for(\"react.responder\"):60118,y=b?Symbol.for(\"react.scope\"):60119;\nfunction z(a){if(\"object\"===typeof a&&null!==a){var u=a.$$typeof;switch(u){case c:switch(a=a.type,a){case l:case m:case e:case g:case f:case p:return a;default:switch(a=a&&a.$$typeof,a){case k:case n:case t:case r:case h:return a;default:return u}}case d:return u}}}function A(a){return z(a)===m}exports.AsyncMode=l;exports.ConcurrentMode=m;exports.ContextConsumer=k;exports.ContextProvider=h;exports.Element=c;exports.ForwardRef=n;exports.Fragment=e;exports.Lazy=t;exports.Memo=r;exports.Portal=d;\nexports.Profiler=g;exports.StrictMode=f;exports.Suspense=p;exports.isAsyncMode=function(a){return A(a)||z(a)===l};exports.isConcurrentMode=A;exports.isContextConsumer=function(a){return z(a)===k};exports.isContextProvider=function(a){return z(a)===h};exports.isElement=function(a){return\"object\"===typeof a&&null!==a&&a.$$typeof===c};exports.isForwardRef=function(a){return z(a)===n};exports.isFragment=function(a){return z(a)===e};exports.isLazy=function(a){return z(a)===t};\nexports.isMemo=function(a){return z(a)===r};exports.isPortal=function(a){return z(a)===d};exports.isProfiler=function(a){return z(a)===g};exports.isStrictMode=function(a){return z(a)===f};exports.isSuspense=function(a){return z(a)===p};\nexports.isValidElementType=function(a){return\"string\"===typeof a||\"function\"===typeof a||a===e||a===m||a===g||a===f||a===p||a===q||\"object\"===typeof a&&null!==a&&(a.$$typeof===t||a.$$typeof===r||a.$$typeof===h||a.$$typeof===k||a.$$typeof===n||a.$$typeof===w||a.$$typeof===x||a.$$typeof===y||a.$$typeof===v)};exports.typeOf=z;\n","/** @license React v16.13.1\n * react-is.development.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\n\n\nif (process.env.NODE_ENV !== \"production\") {\n (function() {\n'use strict';\n\n// The Symbol used to tag the ReactElement-like types. If there is no native Symbol\n// nor polyfill, then a plain number is used for performance.\nvar hasSymbol = typeof Symbol === 'function' && Symbol.for;\nvar REACT_ELEMENT_TYPE = hasSymbol ? Symbol.for('react.element') : 0xeac7;\nvar REACT_PORTAL_TYPE = hasSymbol ? Symbol.for('react.portal') : 0xeaca;\nvar REACT_FRAGMENT_TYPE = hasSymbol ? Symbol.for('react.fragment') : 0xeacb;\nvar REACT_STRICT_MODE_TYPE = hasSymbol ? Symbol.for('react.strict_mode') : 0xeacc;\nvar REACT_PROFILER_TYPE = hasSymbol ? Symbol.for('react.profiler') : 0xead2;\nvar REACT_PROVIDER_TYPE = hasSymbol ? Symbol.for('react.provider') : 0xeacd;\nvar REACT_CONTEXT_TYPE = hasSymbol ? Symbol.for('react.context') : 0xeace; // TODO: We don't use AsyncMode or ConcurrentMode anymore. They were temporary\n// (unstable) APIs that have been removed. Can we remove the symbols?\n\nvar REACT_ASYNC_MODE_TYPE = hasSymbol ? Symbol.for('react.async_mode') : 0xeacf;\nvar REACT_CONCURRENT_MODE_TYPE = hasSymbol ? Symbol.for('react.concurrent_mode') : 0xeacf;\nvar REACT_FORWARD_REF_TYPE = hasSymbol ? Symbol.for('react.forward_ref') : 0xead0;\nvar REACT_SUSPENSE_TYPE = hasSymbol ? Symbol.for('react.suspense') : 0xead1;\nvar REACT_SUSPENSE_LIST_TYPE = hasSymbol ? Symbol.for('react.suspense_list') : 0xead8;\nvar REACT_MEMO_TYPE = hasSymbol ? Symbol.for('react.memo') : 0xead3;\nvar REACT_LAZY_TYPE = hasSymbol ? Symbol.for('react.lazy') : 0xead4;\nvar REACT_BLOCK_TYPE = hasSymbol ? Symbol.for('react.block') : 0xead9;\nvar REACT_FUNDAMENTAL_TYPE = hasSymbol ? Symbol.for('react.fundamental') : 0xead5;\nvar REACT_RESPONDER_TYPE = hasSymbol ? Symbol.for('react.responder') : 0xead6;\nvar REACT_SCOPE_TYPE = hasSymbol ? Symbol.for('react.scope') : 0xead7;\n\nfunction isValidElementType(type) {\n return typeof type === 'string' || typeof type === 'function' || // Note: its typeof might be other than 'symbol' or 'number' if it's a polyfill.\n type === REACT_FRAGMENT_TYPE || type === REACT_CONCURRENT_MODE_TYPE || type === REACT_PROFILER_TYPE || type === REACT_STRICT_MODE_TYPE || type === REACT_SUSPENSE_TYPE || type === REACT_SUSPENSE_LIST_TYPE || typeof type === 'object' && type !== null && (type.$$typeof === REACT_LAZY_TYPE || type.$$typeof === REACT_MEMO_TYPE || type.$$typeof === REACT_PROVIDER_TYPE || type.$$typeof === REACT_CONTEXT_TYPE || type.$$typeof === REACT_FORWARD_REF_TYPE || type.$$typeof === REACT_FUNDAMENTAL_TYPE || type.$$typeof === REACT_RESPONDER_TYPE || type.$$typeof === REACT_SCOPE_TYPE || type.$$typeof === REACT_BLOCK_TYPE);\n}\n\nfunction typeOf(object) {\n if (typeof object === 'object' && object !== null) {\n var $$typeof = object.$$typeof;\n\n switch ($$typeof) {\n case REACT_ELEMENT_TYPE:\n var type = object.type;\n\n switch (type) {\n case REACT_ASYNC_MODE_TYPE:\n case REACT_CONCURRENT_MODE_TYPE:\n case REACT_FRAGMENT_TYPE:\n case REACT_PROFILER_TYPE:\n case REACT_STRICT_MODE_TYPE:\n case REACT_SUSPENSE_TYPE:\n return type;\n\n default:\n var $$typeofType = type && type.$$typeof;\n\n switch ($$typeofType) {\n case REACT_CONTEXT_TYPE:\n case REACT_FORWARD_REF_TYPE:\n case REACT_LAZY_TYPE:\n case REACT_MEMO_TYPE:\n case REACT_PROVIDER_TYPE:\n return $$typeofType;\n\n default:\n return $$typeof;\n }\n\n }\n\n case REACT_PORTAL_TYPE:\n return $$typeof;\n }\n }\n\n return undefined;\n} // AsyncMode is deprecated along with isAsyncMode\n\nvar AsyncMode = REACT_ASYNC_MODE_TYPE;\nvar ConcurrentMode = REACT_CONCURRENT_MODE_TYPE;\nvar ContextConsumer = REACT_CONTEXT_TYPE;\nvar ContextProvider = REACT_PROVIDER_TYPE;\nvar Element = REACT_ELEMENT_TYPE;\nvar ForwardRef = REACT_FORWARD_REF_TYPE;\nvar Fragment = REACT_FRAGMENT_TYPE;\nvar Lazy = REACT_LAZY_TYPE;\nvar Memo = REACT_MEMO_TYPE;\nvar Portal = REACT_PORTAL_TYPE;\nvar Profiler = REACT_PROFILER_TYPE;\nvar StrictMode = REACT_STRICT_MODE_TYPE;\nvar Suspense = REACT_SUSPENSE_TYPE;\nvar hasWarnedAboutDeprecatedIsAsyncMode = false; // AsyncMode should be deprecated\n\nfunction isAsyncMode(object) {\n {\n if (!hasWarnedAboutDeprecatedIsAsyncMode) {\n hasWarnedAboutDeprecatedIsAsyncMode = true; // Using console['warn'] to evade Babel and ESLint\n\n console['warn']('The ReactIs.isAsyncMode() alias has been deprecated, ' + 'and will be removed in React 17+. Update your code to use ' + 'ReactIs.isConcurrentMode() instead. It has the exact same API.');\n }\n }\n\n return isConcurrentMode(object) || typeOf(object) === REACT_ASYNC_MODE_TYPE;\n}\nfunction isConcurrentMode(object) {\n return typeOf(object) === REACT_CONCURRENT_MODE_TYPE;\n}\nfunction isContextConsumer(object) {\n return typeOf(object) === REACT_CONTEXT_TYPE;\n}\nfunction isContextProvider(object) {\n return typeOf(object) === REACT_PROVIDER_TYPE;\n}\nfunction isElement(object) {\n return typeof object === 'object' && object !== null && object.$$typeof === REACT_ELEMENT_TYPE;\n}\nfunction isForwardRef(object) {\n return typeOf(object) === REACT_FORWARD_REF_TYPE;\n}\nfunction isFragment(object) {\n return typeOf(object) === REACT_FRAGMENT_TYPE;\n}\nfunction isLazy(object) {\n return typeOf(object) === REACT_LAZY_TYPE;\n}\nfunction isMemo(object) {\n return typeOf(object) === REACT_MEMO_TYPE;\n}\nfunction isPortal(object) {\n return typeOf(object) === REACT_PORTAL_TYPE;\n}\nfunction isProfiler(object) {\n return typeOf(object) === REACT_PROFILER_TYPE;\n}\nfunction isStrictMode(object) {\n return typeOf(object) === REACT_STRICT_MODE_TYPE;\n}\nfunction isSuspense(object) {\n return typeOf(object) === REACT_SUSPENSE_TYPE;\n}\n\nexports.AsyncMode = AsyncMode;\nexports.ConcurrentMode = ConcurrentMode;\nexports.ContextConsumer = ContextConsumer;\nexports.ContextProvider = ContextProvider;\nexports.Element = Element;\nexports.ForwardRef = ForwardRef;\nexports.Fragment = Fragment;\nexports.Lazy = Lazy;\nexports.Memo = Memo;\nexports.Portal = Portal;\nexports.Profiler = Profiler;\nexports.StrictMode = StrictMode;\nexports.Suspense = Suspense;\nexports.isAsyncMode = isAsyncMode;\nexports.isConcurrentMode = isConcurrentMode;\nexports.isContextConsumer = isContextConsumer;\nexports.isContextProvider = isContextProvider;\nexports.isElement = isElement;\nexports.isForwardRef = isForwardRef;\nexports.isFragment = isFragment;\nexports.isLazy = isLazy;\nexports.isMemo = isMemo;\nexports.isPortal = isPortal;\nexports.isProfiler = isProfiler;\nexports.isStrictMode = isStrictMode;\nexports.isSuspense = isSuspense;\nexports.isValidElementType = isValidElementType;\nexports.typeOf = typeOf;\n })();\n}\n","'use strict';\n\nif (process.env.NODE_ENV === 'production') {\n module.exports = require('./cjs/react-is.production.min.js');\n} else {\n module.exports = require('./cjs/react-is.development.js');\n}\n","/*\nobject-assign\n(c) Sindre Sorhus\n@license MIT\n*/\n\n'use strict';\n/* eslint-disable no-unused-vars */\nvar getOwnPropertySymbols = Object.getOwnPropertySymbols;\nvar hasOwnProperty = Object.prototype.hasOwnProperty;\nvar propIsEnumerable = Object.prototype.propertyIsEnumerable;\n\nfunction toObject(val) {\n\tif (val === null || val === undefined) {\n\t\tthrow new TypeError('Object.assign cannot be called with null or undefined');\n\t}\n\n\treturn Object(val);\n}\n\nfunction shouldUseNative() {\n\ttry {\n\t\tif (!Object.assign) {\n\t\t\treturn false;\n\t\t}\n\n\t\t// Detect buggy property enumeration order in older V8 versions.\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=4118\n\t\tvar test1 = new String('abc'); // eslint-disable-line no-new-wrappers\n\t\ttest1[5] = 'de';\n\t\tif (Object.getOwnPropertyNames(test1)[0] === '5') {\n\t\t\treturn false;\n\t\t}\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=3056\n\t\tvar test2 = {};\n\t\tfor (var i = 0; i < 10; i++) {\n\t\t\ttest2['_' + String.fromCharCode(i)] = i;\n\t\t}\n\t\tvar order2 = Object.getOwnPropertyNames(test2).map(function (n) {\n\t\t\treturn test2[n];\n\t\t});\n\t\tif (order2.join('') !== '0123456789') {\n\t\t\treturn false;\n\t\t}\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=3056\n\t\tvar test3 = {};\n\t\t'abcdefghijklmnopqrst'.split('').forEach(function (letter) {\n\t\t\ttest3[letter] = letter;\n\t\t});\n\t\tif (Object.keys(Object.assign({}, test3)).join('') !==\n\t\t\t\t'abcdefghijklmnopqrst') {\n\t\t\treturn false;\n\t\t}\n\n\t\treturn true;\n\t} catch (err) {\n\t\t// We don't expect any of the above to throw, but better to be safe.\n\t\treturn false;\n\t}\n}\n\nmodule.exports = shouldUseNative() ? Object.assign : function (target, source) {\n\tvar from;\n\tvar to = toObject(target);\n\tvar symbols;\n\n\tfor (var s = 1; s < arguments.length; s++) {\n\t\tfrom = Object(arguments[s]);\n\n\t\tfor (var key in from) {\n\t\t\tif (hasOwnProperty.call(from, key)) {\n\t\t\t\tto[key] = from[key];\n\t\t\t}\n\t\t}\n\n\t\tif (getOwnPropertySymbols) {\n\t\t\tsymbols = getOwnPropertySymbols(from);\n\t\t\tfor (var i = 0; i < symbols.length; i++) {\n\t\t\t\tif (propIsEnumerable.call(from, symbols[i])) {\n\t\t\t\t\tto[symbols[i]] = from[symbols[i]];\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\n\treturn to;\n};\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar ReactPropTypesSecret = 'SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED';\n\nmodule.exports = ReactPropTypesSecret;\n","module.exports = Function.call.bind(Object.prototype.hasOwnProperty);\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar printWarning = function() {};\n\nif (process.env.NODE_ENV !== 'production') {\n var ReactPropTypesSecret = require('./lib/ReactPropTypesSecret');\n var loggedTypeFailures = {};\n var has = require('./lib/has');\n\n printWarning = function(text) {\n var message = 'Warning: ' + text;\n if (typeof console !== 'undefined') {\n console.error(message);\n }\n try {\n // --- Welcome to debugging React ---\n // This error was thrown as a convenience so that you can use this stack\n // to find the callsite that caused this warning to fire.\n throw new Error(message);\n } catch (x) { /**/ }\n };\n}\n\n/**\n * Assert that the values match with the type specs.\n * Error messages are memorized and will only be shown once.\n *\n * @param {object} typeSpecs Map of name to a ReactPropType\n * @param {object} values Runtime values that need to be type-checked\n * @param {string} location e.g. \"prop\", \"context\", \"child context\"\n * @param {string} componentName Name of the component for error messages.\n * @param {?Function} getStack Returns the component stack.\n * @private\n */\nfunction checkPropTypes(typeSpecs, values, location, componentName, getStack) {\n if (process.env.NODE_ENV !== 'production') {\n for (var typeSpecName in typeSpecs) {\n if (has(typeSpecs, typeSpecName)) {\n var error;\n // Prop type validation may throw. In case they do, we don't want to\n // fail the render phase where it didn't fail before. So we log it.\n // After these have been cleaned up, we'll let them throw.\n try {\n // This is intentionally an invariant that gets caught. It's the same\n // behavior as without this statement except with a better message.\n if (typeof typeSpecs[typeSpecName] !== 'function') {\n var err = Error(\n (componentName || 'React class') + ': ' + location + ' type `' + typeSpecName + '` is invalid; ' +\n 'it must be a function, usually from the `prop-types` package, but received `' + typeof typeSpecs[typeSpecName] + '`.' +\n 'This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.'\n );\n err.name = 'Invariant Violation';\n throw err;\n }\n error = typeSpecs[typeSpecName](values, typeSpecName, componentName, location, null, ReactPropTypesSecret);\n } catch (ex) {\n error = ex;\n }\n if (error && !(error instanceof Error)) {\n printWarning(\n (componentName || 'React class') + ': type specification of ' +\n location + ' `' + typeSpecName + '` is invalid; the type checker ' +\n 'function must return `null` or an `Error` but returned a ' + typeof error + '. ' +\n 'You may have forgotten to pass an argument to the type checker ' +\n 'creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and ' +\n 'shape all require an argument).'\n );\n }\n if (error instanceof Error && !(error.message in loggedTypeFailures)) {\n // Only monitor this failure once because there tends to be a lot of the\n // same error.\n loggedTypeFailures[error.message] = true;\n\n var stack = getStack ? getStack() : '';\n\n printWarning(\n 'Failed ' + location + ' type: ' + error.message + (stack != null ? stack : '')\n );\n }\n }\n }\n }\n}\n\n/**\n * Resets warning cache when testing.\n *\n * @private\n */\ncheckPropTypes.resetWarningCache = function() {\n if (process.env.NODE_ENV !== 'production') {\n loggedTypeFailures = {};\n }\n}\n\nmodule.exports = checkPropTypes;\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar ReactIs = require('react-is');\nvar assign = require('object-assign');\n\nvar ReactPropTypesSecret = require('./lib/ReactPropTypesSecret');\nvar has = require('./lib/has');\nvar checkPropTypes = require('./checkPropTypes');\n\nvar printWarning = function() {};\n\nif (process.env.NODE_ENV !== 'production') {\n printWarning = function(text) {\n var message = 'Warning: ' + text;\n if (typeof console !== 'undefined') {\n console.error(message);\n }\n try {\n // --- Welcome to debugging React ---\n // This error was thrown as a convenience so that you can use this stack\n // to find the callsite that caused this warning to fire.\n throw new Error(message);\n } catch (x) {}\n };\n}\n\nfunction emptyFunctionThatReturnsNull() {\n return null;\n}\n\nmodule.exports = function(isValidElement, throwOnDirectAccess) {\n /* global Symbol */\n var ITERATOR_SYMBOL = typeof Symbol === 'function' && Symbol.iterator;\n var FAUX_ITERATOR_SYMBOL = '@@iterator'; // Before Symbol spec.\n\n /**\n * Returns the iterator method function contained on the iterable object.\n *\n * Be sure to invoke the function with the iterable as context:\n *\n * var iteratorFn = getIteratorFn(myIterable);\n * if (iteratorFn) {\n * var iterator = iteratorFn.call(myIterable);\n * ...\n * }\n *\n * @param {?object} maybeIterable\n * @return {?function}\n */\n function getIteratorFn(maybeIterable) {\n var iteratorFn = maybeIterable && (ITERATOR_SYMBOL && maybeIterable[ITERATOR_SYMBOL] || maybeIterable[FAUX_ITERATOR_SYMBOL]);\n if (typeof iteratorFn === 'function') {\n return iteratorFn;\n }\n }\n\n /**\n * Collection of methods that allow declaration and validation of props that are\n * supplied to React components. Example usage:\n *\n * var Props = require('ReactPropTypes');\n * var MyArticle = React.createClass({\n * propTypes: {\n * // An optional string prop named \"description\".\n * description: Props.string,\n *\n * // A required enum prop named \"category\".\n * category: Props.oneOf(['News','Photos']).isRequired,\n *\n * // A prop named \"dialog\" that requires an instance of Dialog.\n * dialog: Props.instanceOf(Dialog).isRequired\n * },\n * render: function() { ... }\n * });\n *\n * A more formal specification of how these methods are used:\n *\n * type := array|bool|func|object|number|string|oneOf([...])|instanceOf(...)\n * decl := ReactPropTypes.{type}(.isRequired)?\n *\n * Each and every declaration produces a function with the same signature. This\n * allows the creation of custom validation functions. For example:\n *\n * var MyLink = React.createClass({\n * propTypes: {\n * // An optional string or URI prop named \"href\".\n * href: function(props, propName, componentName) {\n * var propValue = props[propName];\n * if (propValue != null && typeof propValue !== 'string' &&\n * !(propValue instanceof URI)) {\n * return new Error(\n * 'Expected a string or an URI for ' + propName + ' in ' +\n * componentName\n * );\n * }\n * }\n * },\n * render: function() {...}\n * });\n *\n * @internal\n */\n\n var ANONYMOUS = '<>';\n\n // Important!\n // Keep this list in sync with production version in `./factoryWithThrowingShims.js`.\n var ReactPropTypes = {\n array: createPrimitiveTypeChecker('array'),\n bigint: createPrimitiveTypeChecker('bigint'),\n bool: createPrimitiveTypeChecker('boolean'),\n func: createPrimitiveTypeChecker('function'),\n number: createPrimitiveTypeChecker('number'),\n object: createPrimitiveTypeChecker('object'),\n string: createPrimitiveTypeChecker('string'),\n symbol: createPrimitiveTypeChecker('symbol'),\n\n any: createAnyTypeChecker(),\n arrayOf: createArrayOfTypeChecker,\n element: createElementTypeChecker(),\n elementType: createElementTypeTypeChecker(),\n instanceOf: createInstanceTypeChecker,\n node: createNodeChecker(),\n objectOf: createObjectOfTypeChecker,\n oneOf: createEnumTypeChecker,\n oneOfType: createUnionTypeChecker,\n shape: createShapeTypeChecker,\n exact: createStrictShapeTypeChecker,\n };\n\n /**\n * inlined Object.is polyfill to avoid requiring consumers ship their own\n * https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object/is\n */\n /*eslint-disable no-self-compare*/\n function is(x, y) {\n // SameValue algorithm\n if (x === y) {\n // Steps 1-5, 7-10\n // Steps 6.b-6.e: +0 != -0\n return x !== 0 || 1 / x === 1 / y;\n } else {\n // Step 6.a: NaN == NaN\n return x !== x && y !== y;\n }\n }\n /*eslint-enable no-self-compare*/\n\n /**\n * We use an Error-like object for backward compatibility as people may call\n * PropTypes directly and inspect their output. However, we don't use real\n * Errors anymore. We don't inspect their stack anyway, and creating them\n * is prohibitively expensive if they are created too often, such as what\n * happens in oneOfType() for any type before the one that matched.\n */\n function PropTypeError(message, data) {\n this.message = message;\n this.data = data && typeof data === 'object' ? data: {};\n this.stack = '';\n }\n // Make `instanceof Error` still work for returned errors.\n PropTypeError.prototype = Error.prototype;\n\n function createChainableTypeChecker(validate) {\n if (process.env.NODE_ENV !== 'production') {\n var manualPropTypeCallCache = {};\n var manualPropTypeWarningCount = 0;\n }\n function checkType(isRequired, props, propName, componentName, location, propFullName, secret) {\n componentName = componentName || ANONYMOUS;\n propFullName = propFullName || propName;\n\n if (secret !== ReactPropTypesSecret) {\n if (throwOnDirectAccess) {\n // New behavior only for users of `prop-types` package\n var err = new Error(\n 'Calling PropTypes validators directly is not supported by the `prop-types` package. ' +\n 'Use `PropTypes.checkPropTypes()` to call them. ' +\n 'Read more at http://fb.me/use-check-prop-types'\n );\n err.name = 'Invariant Violation';\n throw err;\n } else if (process.env.NODE_ENV !== 'production' && typeof console !== 'undefined') {\n // Old behavior for people using React.PropTypes\n var cacheKey = componentName + ':' + propName;\n if (\n !manualPropTypeCallCache[cacheKey] &&\n // Avoid spamming the console because they are often not actionable except for lib authors\n manualPropTypeWarningCount < 3\n ) {\n printWarning(\n 'You are manually calling a React.PropTypes validation ' +\n 'function for the `' + propFullName + '` prop on `' + componentName + '`. This is deprecated ' +\n 'and will throw in the standalone `prop-types` package. ' +\n 'You may be seeing this warning due to a third-party PropTypes ' +\n 'library. See https://fb.me/react-warning-dont-call-proptypes ' + 'for details.'\n );\n manualPropTypeCallCache[cacheKey] = true;\n manualPropTypeWarningCount++;\n }\n }\n }\n if (props[propName] == null) {\n if (isRequired) {\n if (props[propName] === null) {\n return new PropTypeError('The ' + location + ' `' + propFullName + '` is marked as required ' + ('in `' + componentName + '`, but its value is `null`.'));\n }\n return new PropTypeError('The ' + location + ' `' + propFullName + '` is marked as required in ' + ('`' + componentName + '`, but its value is `undefined`.'));\n }\n return null;\n } else {\n return validate(props, propName, componentName, location, propFullName);\n }\n }\n\n var chainedCheckType = checkType.bind(null, false);\n chainedCheckType.isRequired = checkType.bind(null, true);\n\n return chainedCheckType;\n }\n\n function createPrimitiveTypeChecker(expectedType) {\n function validate(props, propName, componentName, location, propFullName, secret) {\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== expectedType) {\n // `propValue` being instance of, say, date/regexp, pass the 'object'\n // check, but we can offer a more precise error message here rather than\n // 'of type `object`'.\n var preciseType = getPreciseType(propValue);\n\n return new PropTypeError(\n 'Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + preciseType + '` supplied to `' + componentName + '`, expected ') + ('`' + expectedType + '`.'),\n {expectedType: expectedType}\n );\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createAnyTypeChecker() {\n return createChainableTypeChecker(emptyFunctionThatReturnsNull);\n }\n\n function createArrayOfTypeChecker(typeChecker) {\n function validate(props, propName, componentName, location, propFullName) {\n if (typeof typeChecker !== 'function') {\n return new PropTypeError('Property `' + propFullName + '` of component `' + componentName + '` has invalid PropType notation inside arrayOf.');\n }\n var propValue = props[propName];\n if (!Array.isArray(propValue)) {\n var propType = getPropType(propValue);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected an array.'));\n }\n for (var i = 0; i < propValue.length; i++) {\n var error = typeChecker(propValue, i, componentName, location, propFullName + '[' + i + ']', ReactPropTypesSecret);\n if (error instanceof Error) {\n return error;\n }\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createElementTypeChecker() {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n if (!isValidElement(propValue)) {\n var propType = getPropType(propValue);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected a single ReactElement.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createElementTypeTypeChecker() {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n if (!ReactIs.isValidElementType(propValue)) {\n var propType = getPropType(propValue);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected a single ReactElement type.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createInstanceTypeChecker(expectedClass) {\n function validate(props, propName, componentName, location, propFullName) {\n if (!(props[propName] instanceof expectedClass)) {\n var expectedClassName = expectedClass.name || ANONYMOUS;\n var actualClassName = getClassName(props[propName]);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + actualClassName + '` supplied to `' + componentName + '`, expected ') + ('instance of `' + expectedClassName + '`.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createEnumTypeChecker(expectedValues) {\n if (!Array.isArray(expectedValues)) {\n if (process.env.NODE_ENV !== 'production') {\n if (arguments.length > 1) {\n printWarning(\n 'Invalid arguments supplied to oneOf, expected an array, got ' + arguments.length + ' arguments. ' +\n 'A common mistake is to write oneOf(x, y, z) instead of oneOf([x, y, z]).'\n );\n } else {\n printWarning('Invalid argument supplied to oneOf, expected an array.');\n }\n }\n return emptyFunctionThatReturnsNull;\n }\n\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n for (var i = 0; i < expectedValues.length; i++) {\n if (is(propValue, expectedValues[i])) {\n return null;\n }\n }\n\n var valuesString = JSON.stringify(expectedValues, function replacer(key, value) {\n var type = getPreciseType(value);\n if (type === 'symbol') {\n return String(value);\n }\n return value;\n });\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of value `' + String(propValue) + '` ' + ('supplied to `' + componentName + '`, expected one of ' + valuesString + '.'));\n }\n return createChainableTypeChecker(validate);\n }\n\n function createObjectOfTypeChecker(typeChecker) {\n function validate(props, propName, componentName, location, propFullName) {\n if (typeof typeChecker !== 'function') {\n return new PropTypeError('Property `' + propFullName + '` of component `' + componentName + '` has invalid PropType notation inside objectOf.');\n }\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== 'object') {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected an object.'));\n }\n for (var key in propValue) {\n if (has(propValue, key)) {\n var error = typeChecker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret);\n if (error instanceof Error) {\n return error;\n }\n }\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createUnionTypeChecker(arrayOfTypeCheckers) {\n if (!Array.isArray(arrayOfTypeCheckers)) {\n process.env.NODE_ENV !== 'production' ? printWarning('Invalid argument supplied to oneOfType, expected an instance of array.') : void 0;\n return emptyFunctionThatReturnsNull;\n }\n\n for (var i = 0; i < arrayOfTypeCheckers.length; i++) {\n var checker = arrayOfTypeCheckers[i];\n if (typeof checker !== 'function') {\n printWarning(\n 'Invalid argument supplied to oneOfType. Expected an array of check functions, but ' +\n 'received ' + getPostfixForTypeWarning(checker) + ' at index ' + i + '.'\n );\n return emptyFunctionThatReturnsNull;\n }\n }\n\n function validate(props, propName, componentName, location, propFullName) {\n var expectedTypes = [];\n for (var i = 0; i < arrayOfTypeCheckers.length; i++) {\n var checker = arrayOfTypeCheckers[i];\n var checkerResult = checker(props, propName, componentName, location, propFullName, ReactPropTypesSecret);\n if (checkerResult == null) {\n return null;\n }\n if (checkerResult.data && has(checkerResult.data, 'expectedType')) {\n expectedTypes.push(checkerResult.data.expectedType);\n }\n }\n var expectedTypesMessage = (expectedTypes.length > 0) ? ', expected one of type [' + expectedTypes.join(', ') + ']': '';\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` supplied to ' + ('`' + componentName + '`' + expectedTypesMessage + '.'));\n }\n return createChainableTypeChecker(validate);\n }\n\n function createNodeChecker() {\n function validate(props, propName, componentName, location, propFullName) {\n if (!isNode(props[propName])) {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` supplied to ' + ('`' + componentName + '`, expected a ReactNode.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function invalidValidatorError(componentName, location, propFullName, key, type) {\n return new PropTypeError(\n (componentName || 'React class') + ': ' + location + ' type `' + propFullName + '.' + key + '` is invalid; ' +\n 'it must be a function, usually from the `prop-types` package, but received `' + type + '`.'\n );\n }\n\n function createShapeTypeChecker(shapeTypes) {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== 'object') {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type `' + propType + '` ' + ('supplied to `' + componentName + '`, expected `object`.'));\n }\n for (var key in shapeTypes) {\n var checker = shapeTypes[key];\n if (typeof checker !== 'function') {\n return invalidValidatorError(componentName, location, propFullName, key, getPreciseType(checker));\n }\n var error = checker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret);\n if (error) {\n return error;\n }\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createStrictShapeTypeChecker(shapeTypes) {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== 'object') {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type `' + propType + '` ' + ('supplied to `' + componentName + '`, expected `object`.'));\n }\n // We need to check all keys in case some are required but missing from props.\n var allKeys = assign({}, props[propName], shapeTypes);\n for (var key in allKeys) {\n var checker = shapeTypes[key];\n if (has(shapeTypes, key) && typeof checker !== 'function') {\n return invalidValidatorError(componentName, location, propFullName, key, getPreciseType(checker));\n }\n if (!checker) {\n return new PropTypeError(\n 'Invalid ' + location + ' `' + propFullName + '` key `' + key + '` supplied to `' + componentName + '`.' +\n '\\nBad object: ' + JSON.stringify(props[propName], null, ' ') +\n '\\nValid keys: ' + JSON.stringify(Object.keys(shapeTypes), null, ' ')\n );\n }\n var error = checker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret);\n if (error) {\n return error;\n }\n }\n return null;\n }\n\n return createChainableTypeChecker(validate);\n }\n\n function isNode(propValue) {\n switch (typeof propValue) {\n case 'number':\n case 'string':\n case 'undefined':\n return true;\n case 'boolean':\n return !propValue;\n case 'object':\n if (Array.isArray(propValue)) {\n return propValue.every(isNode);\n }\n if (propValue === null || isValidElement(propValue)) {\n return true;\n }\n\n var iteratorFn = getIteratorFn(propValue);\n if (iteratorFn) {\n var iterator = iteratorFn.call(propValue);\n var step;\n if (iteratorFn !== propValue.entries) {\n while (!(step = iterator.next()).done) {\n if (!isNode(step.value)) {\n return false;\n }\n }\n } else {\n // Iterator will provide entry [k,v] tuples rather than values.\n while (!(step = iterator.next()).done) {\n var entry = step.value;\n if (entry) {\n if (!isNode(entry[1])) {\n return false;\n }\n }\n }\n }\n } else {\n return false;\n }\n\n return true;\n default:\n return false;\n }\n }\n\n function isSymbol(propType, propValue) {\n // Native Symbol.\n if (propType === 'symbol') {\n return true;\n }\n\n // falsy value can't be a Symbol\n if (!propValue) {\n return false;\n }\n\n // 19.4.3.5 Symbol.prototype[@@toStringTag] === 'Symbol'\n if (propValue['@@toStringTag'] === 'Symbol') {\n return true;\n }\n\n // Fallback for non-spec compliant Symbols which are polyfilled.\n if (typeof Symbol === 'function' && propValue instanceof Symbol) {\n return true;\n }\n\n return false;\n }\n\n // Equivalent of `typeof` but with special handling for array and regexp.\n function getPropType(propValue) {\n var propType = typeof propValue;\n if (Array.isArray(propValue)) {\n return 'array';\n }\n if (propValue instanceof RegExp) {\n // Old webkits (at least until Android 4.0) return 'function' rather than\n // 'object' for typeof a RegExp. We'll normalize this here so that /bla/\n // passes PropTypes.object.\n return 'object';\n }\n if (isSymbol(propType, propValue)) {\n return 'symbol';\n }\n return propType;\n }\n\n // This handles more types than `getPropType`. Only used for error messages.\n // See `createPrimitiveTypeChecker`.\n function getPreciseType(propValue) {\n if (typeof propValue === 'undefined' || propValue === null) {\n return '' + propValue;\n }\n var propType = getPropType(propValue);\n if (propType === 'object') {\n if (propValue instanceof Date) {\n return 'date';\n } else if (propValue instanceof RegExp) {\n return 'regexp';\n }\n }\n return propType;\n }\n\n // Returns a string that is postfixed to a warning about an invalid type.\n // For example, \"undefined\" or \"of type array\"\n function getPostfixForTypeWarning(value) {\n var type = getPreciseType(value);\n switch (type) {\n case 'array':\n case 'object':\n return 'an ' + type;\n case 'boolean':\n case 'date':\n case 'regexp':\n return 'a ' + type;\n default:\n return type;\n }\n }\n\n // Returns class name of the object, if any.\n function getClassName(propValue) {\n if (!propValue.constructor || !propValue.constructor.name) {\n return ANONYMOUS;\n }\n return propValue.constructor.name;\n }\n\n ReactPropTypes.checkPropTypes = checkPropTypes;\n ReactPropTypes.resetWarningCache = checkPropTypes.resetWarningCache;\n ReactPropTypes.PropTypes = ReactPropTypes;\n\n return ReactPropTypes;\n};\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar ReactPropTypesSecret = require('./lib/ReactPropTypesSecret');\n\nfunction emptyFunction() {}\nfunction emptyFunctionWithReset() {}\nemptyFunctionWithReset.resetWarningCache = emptyFunction;\n\nmodule.exports = function() {\n function shim(props, propName, componentName, location, propFullName, secret) {\n if (secret === ReactPropTypesSecret) {\n // It is still safe when called from React.\n return;\n }\n var err = new Error(\n 'Calling PropTypes validators directly is not supported by the `prop-types` package. ' +\n 'Use PropTypes.checkPropTypes() to call them. ' +\n 'Read more at http://fb.me/use-check-prop-types'\n );\n err.name = 'Invariant Violation';\n throw err;\n };\n shim.isRequired = shim;\n function getShim() {\n return shim;\n };\n // Important!\n // Keep this list in sync with production version in `./factoryWithTypeCheckers.js`.\n var ReactPropTypes = {\n array: shim,\n bigint: shim,\n bool: shim,\n func: shim,\n number: shim,\n object: shim,\n string: shim,\n symbol: shim,\n\n any: shim,\n arrayOf: getShim,\n element: shim,\n elementType: shim,\n instanceOf: getShim,\n node: shim,\n objectOf: getShim,\n oneOf: getShim,\n oneOfType: getShim,\n shape: getShim,\n exact: getShim,\n\n checkPropTypes: emptyFunctionWithReset,\n resetWarningCache: emptyFunction\n };\n\n ReactPropTypes.PropTypes = ReactPropTypes;\n\n return ReactPropTypes;\n};\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\nif (process.env.NODE_ENV !== 'production') {\n var ReactIs = require('react-is');\n\n // By explicitly using `prop-types` you are opting into new development behavior.\n // http://fb.me/prop-types-in-prod\n var throwOnDirectAccess = true;\n module.exports = require('./factoryWithTypeCheckers')(ReactIs.isElement, throwOnDirectAccess);\n} else {\n // By explicitly using `prop-types` you are opting into new production behavior.\n // http://fb.me/prop-types-in-prod\n module.exports = require('./factoryWithThrowingShims')();\n}\n","import PropTypes from 'prop-types';\nimport chainPropTypes from '../chainPropTypes';\nfunction isClassComponent(elementType) {\n // elementType.prototype?.isReactComponent\n const {\n prototype = {}\n } = elementType;\n return Boolean(prototype.isReactComponent);\n}\nfunction acceptingRef(props, propName, componentName, location, propFullName) {\n const element = props[propName];\n const safePropName = propFullName || propName;\n if (element == null ||\n // When server-side rendering React doesn't warn either.\n // This is not an accurate check for SSR.\n // This is only in place for Emotion compat.\n // TODO: Revisit once https://github.com/facebook/react/issues/20047 is resolved.\n typeof window === 'undefined') {\n return null;\n }\n let warningHint;\n const elementType = element.type;\n /**\n * Blacklisting instead of whitelisting\n *\n * Blacklisting will miss some components, such as React.Fragment. Those will at least\n * trigger a warning in React.\n * We can't whitelist because there is no safe way to detect React.forwardRef\n * or class components. \"Safe\" means there's no public API.\n *\n */\n if (typeof elementType === 'function' && !isClassComponent(elementType)) {\n warningHint = 'Did you accidentally use a plain function component for an element instead?';\n }\n if (warningHint !== undefined) {\n return new Error(`Invalid ${location} \\`${safePropName}\\` supplied to \\`${componentName}\\`. ` + `Expected an element that can hold a ref. ${warningHint} ` + 'For more information see https://mui.com/r/caveat-with-refs-guide');\n }\n return null;\n}\nconst elementAcceptingRef = chainPropTypes(PropTypes.element, acceptingRef);\nelementAcceptingRef.isRequired = chainPropTypes(PropTypes.element.isRequired, acceptingRef);\nexport default elementAcceptingRef;","import _extends from \"@babel/runtime/helpers/esm/extends\";\n// This module is based on https://github.com/airbnb/prop-types-exact repository.\n// However, in order to reduce the number of dependencies and to remove some extra safe checks\n// the module was forked.\n\nconst specialProperty = 'exact-prop: \\u200b';\nexport default function exactProp(propTypes) {\n if (process.env.NODE_ENV === 'production') {\n return propTypes;\n }\n return _extends({}, propTypes, {\n [specialProperty]: props => {\n const unsupportedProps = Object.keys(props).filter(prop => !propTypes.hasOwnProperty(prop));\n if (unsupportedProps.length > 0) {\n return new Error(`The following props are not supported: ${unsupportedProps.map(prop => `\\`${prop}\\``).join(', ')}. Please remove them.`);\n }\n return null;\n }\n });\n}","/**\n * WARNING: Don't import this directly.\n * Use `MuiError` from `@mui/internal-babel-macros/MuiError.macro` instead.\n * @param {number} code\n */\nexport default function formatMuiErrorMessage(code) {\n // Apply babel-plugin-transform-template-literals in loose mode\n // loose mode is safe if we're concatenating primitives\n // see https://babeljs.io/docs/en/babel-plugin-transform-template-literals#loose\n /* eslint-disable prefer-template */\n let url = 'https://mui.com/production-error/?code=' + code;\n for (let i = 1; i < arguments.length; i += 1) {\n // rest params over-transpile for this case\n // eslint-disable-next-line prefer-rest-params\n url += '&args[]=' + encodeURIComponent(arguments[i]);\n }\n return 'Minified MUI error #' + code + '; visit ' + url + ' for the full message.';\n /* eslint-enable prefer-template */\n}","/**\n * @license React\n * react-is.production.min.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n'use strict';var b=Symbol.for(\"react.element\"),c=Symbol.for(\"react.portal\"),d=Symbol.for(\"react.fragment\"),e=Symbol.for(\"react.strict_mode\"),f=Symbol.for(\"react.profiler\"),g=Symbol.for(\"react.provider\"),h=Symbol.for(\"react.context\"),k=Symbol.for(\"react.server_context\"),l=Symbol.for(\"react.forward_ref\"),m=Symbol.for(\"react.suspense\"),n=Symbol.for(\"react.suspense_list\"),p=Symbol.for(\"react.memo\"),q=Symbol.for(\"react.lazy\"),t=Symbol.for(\"react.offscreen\"),u;u=Symbol.for(\"react.module.reference\");\nfunction v(a){if(\"object\"===typeof a&&null!==a){var r=a.$$typeof;switch(r){case b:switch(a=a.type,a){case d:case f:case e:case m:case n:return a;default:switch(a=a&&a.$$typeof,a){case k:case h:case l:case q:case p:case g:return a;default:return r}}case c:return r}}}exports.ContextConsumer=h;exports.ContextProvider=g;exports.Element=b;exports.ForwardRef=l;exports.Fragment=d;exports.Lazy=q;exports.Memo=p;exports.Portal=c;exports.Profiler=f;exports.StrictMode=e;exports.Suspense=m;\nexports.SuspenseList=n;exports.isAsyncMode=function(){return!1};exports.isConcurrentMode=function(){return!1};exports.isContextConsumer=function(a){return v(a)===h};exports.isContextProvider=function(a){return v(a)===g};exports.isElement=function(a){return\"object\"===typeof a&&null!==a&&a.$$typeof===b};exports.isForwardRef=function(a){return v(a)===l};exports.isFragment=function(a){return v(a)===d};exports.isLazy=function(a){return v(a)===q};exports.isMemo=function(a){return v(a)===p};\nexports.isPortal=function(a){return v(a)===c};exports.isProfiler=function(a){return v(a)===f};exports.isStrictMode=function(a){return v(a)===e};exports.isSuspense=function(a){return v(a)===m};exports.isSuspenseList=function(a){return v(a)===n};\nexports.isValidElementType=function(a){return\"string\"===typeof a||\"function\"===typeof a||a===d||a===f||a===e||a===m||a===n||a===t||\"object\"===typeof a&&null!==a&&(a.$$typeof===q||a.$$typeof===p||a.$$typeof===g||a.$$typeof===h||a.$$typeof===l||a.$$typeof===u||void 0!==a.getModuleId)?!0:!1};exports.typeOf=v;\n","/**\n * @license React\n * react-is.development.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nif (process.env.NODE_ENV !== \"production\") {\n (function() {\n'use strict';\n\n// ATTENTION\n// When adding new symbols to this file,\n// Please consider also adding to 'react-devtools-shared/src/backend/ReactSymbols'\n// The Symbol used to tag the ReactElement-like types.\nvar REACT_ELEMENT_TYPE = Symbol.for('react.element');\nvar REACT_PORTAL_TYPE = Symbol.for('react.portal');\nvar REACT_FRAGMENT_TYPE = Symbol.for('react.fragment');\nvar REACT_STRICT_MODE_TYPE = Symbol.for('react.strict_mode');\nvar REACT_PROFILER_TYPE = Symbol.for('react.profiler');\nvar REACT_PROVIDER_TYPE = Symbol.for('react.provider');\nvar REACT_CONTEXT_TYPE = Symbol.for('react.context');\nvar REACT_SERVER_CONTEXT_TYPE = Symbol.for('react.server_context');\nvar REACT_FORWARD_REF_TYPE = Symbol.for('react.forward_ref');\nvar REACT_SUSPENSE_TYPE = Symbol.for('react.suspense');\nvar REACT_SUSPENSE_LIST_TYPE = Symbol.for('react.suspense_list');\nvar REACT_MEMO_TYPE = Symbol.for('react.memo');\nvar REACT_LAZY_TYPE = Symbol.for('react.lazy');\nvar REACT_OFFSCREEN_TYPE = Symbol.for('react.offscreen');\n\n// -----------------------------------------------------------------------------\n\nvar enableScopeAPI = false; // Experimental Create Event Handle API.\nvar enableCacheElement = false;\nvar enableTransitionTracing = false; // No known bugs, but needs performance testing\n\nvar enableLegacyHidden = false; // Enables unstable_avoidThisFallback feature in Fiber\n// stuff. Intended to enable React core members to more easily debug scheduling\n// issues in DEV builds.\n\nvar enableDebugTracing = false; // Track which Fiber(s) schedule render work.\n\nvar REACT_MODULE_REFERENCE;\n\n{\n REACT_MODULE_REFERENCE = Symbol.for('react.module.reference');\n}\n\nfunction isValidElementType(type) {\n if (typeof type === 'string' || typeof type === 'function') {\n return true;\n } // Note: typeof might be other than 'symbol' or 'number' (e.g. if it's a polyfill).\n\n\n if (type === REACT_FRAGMENT_TYPE || type === REACT_PROFILER_TYPE || enableDebugTracing || type === REACT_STRICT_MODE_TYPE || type === REACT_SUSPENSE_TYPE || type === REACT_SUSPENSE_LIST_TYPE || enableLegacyHidden || type === REACT_OFFSCREEN_TYPE || enableScopeAPI || enableCacheElement || enableTransitionTracing ) {\n return true;\n }\n\n if (typeof type === 'object' && type !== null) {\n if (type.$$typeof === REACT_LAZY_TYPE || type.$$typeof === REACT_MEMO_TYPE || type.$$typeof === REACT_PROVIDER_TYPE || type.$$typeof === REACT_CONTEXT_TYPE || type.$$typeof === REACT_FORWARD_REF_TYPE || // This needs to include all possible module reference object\n // types supported by any Flight configuration anywhere since\n // we don't know which Flight build this will end up being used\n // with.\n type.$$typeof === REACT_MODULE_REFERENCE || type.getModuleId !== undefined) {\n return true;\n }\n }\n\n return false;\n}\n\nfunction typeOf(object) {\n if (typeof object === 'object' && object !== null) {\n var $$typeof = object.$$typeof;\n\n switch ($$typeof) {\n case REACT_ELEMENT_TYPE:\n var type = object.type;\n\n switch (type) {\n case REACT_FRAGMENT_TYPE:\n case REACT_PROFILER_TYPE:\n case REACT_STRICT_MODE_TYPE:\n case REACT_SUSPENSE_TYPE:\n case REACT_SUSPENSE_LIST_TYPE:\n return type;\n\n default:\n var $$typeofType = type && type.$$typeof;\n\n switch ($$typeofType) {\n case REACT_SERVER_CONTEXT_TYPE:\n case REACT_CONTEXT_TYPE:\n case REACT_FORWARD_REF_TYPE:\n case REACT_LAZY_TYPE:\n case REACT_MEMO_TYPE:\n case REACT_PROVIDER_TYPE:\n return $$typeofType;\n\n default:\n return $$typeof;\n }\n\n }\n\n case REACT_PORTAL_TYPE:\n return $$typeof;\n }\n }\n\n return undefined;\n}\nvar ContextConsumer = REACT_CONTEXT_TYPE;\nvar ContextProvider = REACT_PROVIDER_TYPE;\nvar Element = REACT_ELEMENT_TYPE;\nvar ForwardRef = REACT_FORWARD_REF_TYPE;\nvar Fragment = REACT_FRAGMENT_TYPE;\nvar Lazy = REACT_LAZY_TYPE;\nvar Memo = REACT_MEMO_TYPE;\nvar Portal = REACT_PORTAL_TYPE;\nvar Profiler = REACT_PROFILER_TYPE;\nvar StrictMode = REACT_STRICT_MODE_TYPE;\nvar Suspense = REACT_SUSPENSE_TYPE;\nvar SuspenseList = REACT_SUSPENSE_LIST_TYPE;\nvar hasWarnedAboutDeprecatedIsAsyncMode = false;\nvar hasWarnedAboutDeprecatedIsConcurrentMode = false; // AsyncMode should be deprecated\n\nfunction isAsyncMode(object) {\n {\n if (!hasWarnedAboutDeprecatedIsAsyncMode) {\n hasWarnedAboutDeprecatedIsAsyncMode = true; // Using console['warn'] to evade Babel and ESLint\n\n console['warn']('The ReactIs.isAsyncMode() alias has been deprecated, ' + 'and will be removed in React 18+.');\n }\n }\n\n return false;\n}\nfunction isConcurrentMode(object) {\n {\n if (!hasWarnedAboutDeprecatedIsConcurrentMode) {\n hasWarnedAboutDeprecatedIsConcurrentMode = true; // Using console['warn'] to evade Babel and ESLint\n\n console['warn']('The ReactIs.isConcurrentMode() alias has been deprecated, ' + 'and will be removed in React 18+.');\n }\n }\n\n return false;\n}\nfunction isContextConsumer(object) {\n return typeOf(object) === REACT_CONTEXT_TYPE;\n}\nfunction isContextProvider(object) {\n return typeOf(object) === REACT_PROVIDER_TYPE;\n}\nfunction isElement(object) {\n return typeof object === 'object' && object !== null && object.$$typeof === REACT_ELEMENT_TYPE;\n}\nfunction isForwardRef(object) {\n return typeOf(object) === REACT_FORWARD_REF_TYPE;\n}\nfunction isFragment(object) {\n return typeOf(object) === REACT_FRAGMENT_TYPE;\n}\nfunction isLazy(object) {\n return typeOf(object) === REACT_LAZY_TYPE;\n}\nfunction isMemo(object) {\n return typeOf(object) === REACT_MEMO_TYPE;\n}\nfunction isPortal(object) {\n return typeOf(object) === REACT_PORTAL_TYPE;\n}\nfunction isProfiler(object) {\n return typeOf(object) === REACT_PROFILER_TYPE;\n}\nfunction isStrictMode(object) {\n return typeOf(object) === REACT_STRICT_MODE_TYPE;\n}\nfunction isSuspense(object) {\n return typeOf(object) === REACT_SUSPENSE_TYPE;\n}\nfunction isSuspenseList(object) {\n return typeOf(object) === REACT_SUSPENSE_LIST_TYPE;\n}\n\nexports.ContextConsumer = ContextConsumer;\nexports.ContextProvider = ContextProvider;\nexports.Element = Element;\nexports.ForwardRef = ForwardRef;\nexports.Fragment = Fragment;\nexports.Lazy = Lazy;\nexports.Memo = Memo;\nexports.Portal = Portal;\nexports.Profiler = Profiler;\nexports.StrictMode = StrictMode;\nexports.Suspense = Suspense;\nexports.SuspenseList = SuspenseList;\nexports.isAsyncMode = isAsyncMode;\nexports.isConcurrentMode = isConcurrentMode;\nexports.isContextConsumer = isContextConsumer;\nexports.isContextProvider = isContextProvider;\nexports.isElement = isElement;\nexports.isForwardRef = isForwardRef;\nexports.isFragment = isFragment;\nexports.isLazy = isLazy;\nexports.isMemo = isMemo;\nexports.isPortal = isPortal;\nexports.isProfiler = isProfiler;\nexports.isStrictMode = isStrictMode;\nexports.isSuspense = isSuspense;\nexports.isSuspenseList = isSuspenseList;\nexports.isValidElementType = isValidElementType;\nexports.typeOf = typeOf;\n })();\n}\n","'use strict';\n\nif (process.env.NODE_ENV === 'production') {\n module.exports = require('./cjs/react-is.production.min.js');\n} else {\n module.exports = require('./cjs/react-is.development.js');\n}\n","import { ForwardRef, Memo } from 'react-is';\n\n// Simplified polyfill for IE11 support\n// https://github.com/JamesMGreene/Function.name/blob/58b314d4a983110c3682f1228f845d39ccca1817/Function.name.js#L3\nconst fnNameMatchRegex = /^\\s*function(?:\\s|\\s*\\/\\*.*\\*\\/\\s*)+([^(\\s/]*)\\s*/;\nexport function getFunctionName(fn) {\n const match = `${fn}`.match(fnNameMatchRegex);\n const name = match && match[1];\n return name || '';\n}\nfunction getFunctionComponentName(Component, fallback = '') {\n return Component.displayName || Component.name || getFunctionName(Component) || fallback;\n}\nfunction getWrappedName(outerType, innerType, wrapperName) {\n const functionName = getFunctionComponentName(innerType);\n return outerType.displayName || (functionName !== '' ? `${wrapperName}(${functionName})` : wrapperName);\n}\n\n/**\n * cherry-pick from\n * https://github.com/facebook/react/blob/769b1f270e1251d9dbdce0fcbd9e92e502d059b8/packages/shared/getComponentName.js\n * originally forked from recompose/getDisplayName with added IE11 support\n */\nexport default function getDisplayName(Component) {\n if (Component == null) {\n return undefined;\n }\n if (typeof Component === 'string') {\n return Component;\n }\n if (typeof Component === 'function') {\n return getFunctionComponentName(Component, 'Component');\n }\n\n // TypeScript can't have components as objects but they exist in the form of `memo` or `Suspense`\n if (typeof Component === 'object') {\n switch (Component.$$typeof) {\n case ForwardRef:\n return getWrappedName(Component, Component.render, 'ForwardRef');\n case Memo:\n return getWrappedName(Component, Component.type, 'memo');\n default:\n return undefined;\n }\n }\n return undefined;\n}","export default function HTMLElementType(props, propName, componentName, location, propFullName) {\n if (process.env.NODE_ENV === 'production') {\n return null;\n }\n const propValue = props[propName];\n const safePropName = propFullName || propName;\n if (propValue == null) {\n return null;\n }\n if (propValue && propValue.nodeType !== 1) {\n return new Error(`Invalid ${location} \\`${safePropName}\\` supplied to \\`${componentName}\\`. ` + `Expected an HTMLElement.`);\n }\n return null;\n}","import PropTypes from 'prop-types';\nconst refType = PropTypes.oneOfType([PropTypes.func, PropTypes.object]);\nexport default refType;","import _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\n// It should to be noted that this function isn't equivalent to `text-transform: capitalize`.\n//\n// A strict capitalization should uppercase the first letter of each word in the sentence.\n// We only handle the first word.\nexport default function capitalize(string) {\n if (typeof string !== 'string') {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: \\`capitalize(string)\\` expects a string argument.` : _formatMuiErrorMessage(7));\n }\n return string.charAt(0).toUpperCase() + string.slice(1);\n}","/**\n * Safe chained function.\n *\n * Will only create a new function if needed,\n * otherwise will pass back existing functions or null.\n */\nexport default function createChainedFunction(...funcs) {\n return funcs.reduce((acc, func) => {\n if (func == null) {\n return acc;\n }\n return function chainedFunction(...args) {\n acc.apply(this, args);\n func.apply(this, args);\n };\n }, () => {});\n}","// Corresponds to 10 frames at 60 Hz.\n// A few bytes payload overhead when lodash/debounce is ~3 kB and debounce ~300 B.\nexport default function debounce(func, wait = 166) {\n let timeout;\n function debounced(...args) {\n const later = () => {\n // @ts-ignore\n func.apply(this, args);\n };\n clearTimeout(timeout);\n timeout = setTimeout(later, wait);\n }\n debounced.clear = () => {\n clearTimeout(timeout);\n };\n return debounced;\n}","export default function deprecatedPropType(validator, reason) {\n if (process.env.NODE_ENV === 'production') {\n return () => null;\n }\n return (props, propName, componentName, location, propFullName) => {\n const componentNameSafe = componentName || '<>';\n const propFullNameSafe = propFullName || propName;\n if (typeof props[propName] !== 'undefined') {\n return new Error(`The ${location} \\`${propFullNameSafe}\\` of ` + `\\`${componentNameSafe}\\` is deprecated. ${reason}`);\n }\n return null;\n };\n}","import * as React from 'react';\nexport default function isMuiElement(element, muiNames) {\n var _muiName, _element$type;\n return /*#__PURE__*/React.isValidElement(element) && muiNames.indexOf( // For server components `muiName` is avaialble in element.type._payload.value.muiName\n // relevant info - https://github.com/facebook/react/blob/2807d781a08db8e9873687fccc25c0f12b4fb3d4/packages/react/src/ReactLazy.js#L45\n // eslint-disable-next-line no-underscore-dangle\n (_muiName = element.type.muiName) != null ? _muiName : (_element$type = element.type) == null || (_element$type = _element$type._payload) == null || (_element$type = _element$type.value) == null ? void 0 : _element$type.muiName) !== -1;\n}","export default function ownerDocument(node) {\n return node && node.ownerDocument || document;\n}","import ownerDocument from '../ownerDocument';\nexport default function ownerWindow(node) {\n const doc = ownerDocument(node);\n return doc.defaultView || window;\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nexport default function requirePropFactory(componentNameInError, Component) {\n if (process.env.NODE_ENV === 'production') {\n return () => null;\n }\n\n // eslint-disable-next-line react/forbid-foreign-prop-types\n const prevPropTypes = Component ? _extends({}, Component.propTypes) : null;\n const requireProp = requiredProp => (props, propName, componentName, location, propFullName, ...args) => {\n const propFullNameSafe = propFullName || propName;\n const defaultTypeChecker = prevPropTypes == null ? void 0 : prevPropTypes[propFullNameSafe];\n if (defaultTypeChecker) {\n const typeCheckerResult = defaultTypeChecker(props, propName, componentName, location, propFullName, ...args);\n if (typeCheckerResult) {\n return typeCheckerResult;\n }\n }\n if (typeof props[propName] !== 'undefined' && !props[requiredProp]) {\n return new Error(`The prop \\`${propFullNameSafe}\\` of ` + `\\`${componentNameInError}\\` can only be used together with the \\`${requiredProp}\\` prop.`);\n }\n return null;\n };\n return requireProp;\n}","/**\n * TODO v5: consider making it private\n *\n * passes {value} to {ref}\n *\n * WARNING: Be sure to only call this inside a callback that is passed as a ref.\n * Otherwise, make sure to cleanup the previous {ref} if it changes. See\n * https://github.com/mui/material-ui/issues/13539\n *\n * Useful if you want to expose the ref of an inner component to the public API\n * while still using it inside the component.\n * @param ref A ref callback or ref object. If anything falsy, this is a no-op.\n */\nexport default function setRef(ref, value) {\n if (typeof ref === 'function') {\n ref(value);\n } else if (ref) {\n ref.current = value;\n }\n}","'use client';\n\nimport * as React from 'react';\n\n/**\n * A version of `React.useLayoutEffect` that does not show a warning when server-side rendering.\n * This is useful for effects that are only needed for client-side rendering but not for SSR.\n *\n * Before you use this hook, make sure to read https://gist.github.com/gaearon/e7d97cdf38a2907924ea12e4ebdf3c85\n * and confirm it doesn't apply to your use-case.\n */\nconst useEnhancedEffect = typeof window !== 'undefined' ? React.useLayoutEffect : React.useEffect;\nexport default useEnhancedEffect;","'use client';\n\nimport * as React from 'react';\nlet globalId = 0;\nfunction useGlobalId(idOverride) {\n const [defaultId, setDefaultId] = React.useState(idOverride);\n const id = idOverride || defaultId;\n React.useEffect(() => {\n if (defaultId == null) {\n // Fallback to this default id when possible.\n // Use the incrementing value for client-side rendering only.\n // We can't use it server-side.\n // If you want to use random values please consider the Birthday Problem: https://en.wikipedia.org/wiki/Birthday_problem\n globalId += 1;\n setDefaultId(`mui-${globalId}`);\n }\n }, [defaultId]);\n return id;\n}\n\n// downstream bundlers may remove unnecessary concatenation, but won't remove toString call -- Workaround for https://github.com/webpack/webpack/issues/14814\nconst maybeReactUseId = React['useId'.toString()];\n/**\n *\n * @example
    \n * @param idOverride\n * @returns {string}\n */\nexport default function useId(idOverride) {\n if (maybeReactUseId !== undefined) {\n const reactId = maybeReactUseId();\n return idOverride != null ? idOverride : reactId;\n }\n // eslint-disable-next-line react-hooks/rules-of-hooks -- `React.useId` is invariant at runtime.\n return useGlobalId(idOverride);\n}","export default function unsupportedProp(props, propName, componentName, location, propFullName) {\n if (process.env.NODE_ENV === 'production') {\n return null;\n }\n const propFullNameSafe = propFullName || propName;\n if (typeof props[propName] !== 'undefined') {\n return new Error(`The prop \\`${propFullNameSafe}\\` is not supported. Please remove it.`);\n }\n return null;\n}","'use client';\n\n/* eslint-disable react-hooks/rules-of-hooks, react-hooks/exhaustive-deps */\nimport * as React from 'react';\nexport default function useControlled({\n controlled,\n default: defaultProp,\n name,\n state = 'value'\n}) {\n // isControlled is ignored in the hook dependency lists as it should never change.\n const {\n current: isControlled\n } = React.useRef(controlled !== undefined);\n const [valueState, setValue] = React.useState(defaultProp);\n const value = isControlled ? controlled : valueState;\n if (process.env.NODE_ENV !== 'production') {\n React.useEffect(() => {\n if (isControlled !== (controlled !== undefined)) {\n console.error([`MUI: A component is changing the ${isControlled ? '' : 'un'}controlled ${state} state of ${name} to be ${isControlled ? 'un' : ''}controlled.`, 'Elements should not switch from uncontrolled to controlled (or vice versa).', `Decide between using a controlled or uncontrolled ${name} ` + 'element for the lifetime of the component.', \"The nature of the state is determined during the first render. It's considered controlled if the value is not `undefined`.\", 'More info: https://fb.me/react-controlled-components'].join('\\n'));\n }\n }, [state, name, controlled]);\n const {\n current: defaultValue\n } = React.useRef(defaultProp);\n React.useEffect(() => {\n if (!isControlled && defaultValue !== defaultProp) {\n console.error([`MUI: A component is changing the default ${state} state of an uncontrolled ${name} after being initialized. ` + `To suppress this warning opt to use a controlled ${name}.`].join('\\n'));\n }\n }, [JSON.stringify(defaultProp)]);\n }\n const setValueIfUncontrolled = React.useCallback(newValue => {\n if (!isControlled) {\n setValue(newValue);\n }\n }, []);\n return [value, setValueIfUncontrolled];\n}","'use client';\n\nimport * as React from 'react';\nimport useEnhancedEffect from '../useEnhancedEffect';\n\n/**\n * Inspired by https://github.com/facebook/react/issues/14099#issuecomment-440013892\n * See RFC in https://github.com/reactjs/rfcs/pull/220\n */\n\nfunction useEventCallback(fn) {\n const ref = React.useRef(fn);\n useEnhancedEffect(() => {\n ref.current = fn;\n });\n return React.useRef((...args) =>\n // @ts-expect-error hide `this`\n (0, ref.current)(...args)).current;\n}\nexport default useEventCallback;","'use client';\n\nimport * as React from 'react';\nimport setRef from '../setRef';\nexport default function useForkRef(...refs) {\n /**\n * This will create a new function if the refs passed to this hook change and are all defined.\n * This means react will call the old forkRef with `null` and the new forkRef\n * with the ref. Cleanup naturally emerges from this behavior.\n */\n return React.useMemo(() => {\n if (refs.every(ref => ref == null)) {\n return null;\n }\n return instance => {\n refs.forEach(ref => {\n setRef(ref, instance);\n });\n };\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, refs);\n}","'use client';\n\nimport * as React from 'react';\nconst UNINITIALIZED = {};\n\n/**\n * A React.useRef() that is initialized lazily with a function. Note that it accepts an optional\n * initialization argument, so the initialization function doesn't need to be an inline closure.\n *\n * @usage\n * const ref = useLazyRef(sortColumns, columns)\n */\nexport default function useLazyRef(init, initArg) {\n const ref = React.useRef(UNINITIALIZED);\n if (ref.current === UNINITIALIZED) {\n ref.current = init(initArg);\n }\n return ref;\n}","'use client';\n\nimport * as React from 'react';\nconst EMPTY = [];\n\n/**\n * A React.useEffect equivalent that runs once, when the component is mounted.\n */\nexport default function useOnMount(fn) {\n /* eslint-disable react-hooks/exhaustive-deps */\n React.useEffect(fn, EMPTY);\n /* eslint-enable react-hooks/exhaustive-deps */\n}","'use client';\n\nimport useLazyRef from '../useLazyRef/useLazyRef';\nimport useOnMount from '../useOnMount/useOnMount';\nexport class Timeout {\n constructor() {\n this.currentId = null;\n this.clear = () => {\n if (this.currentId !== null) {\n clearTimeout(this.currentId);\n this.currentId = null;\n }\n };\n this.disposeEffect = () => {\n return this.clear;\n };\n }\n static create() {\n return new Timeout();\n }\n /**\n * Executes `fn` after `delay`, clearing any previously scheduled call.\n */\n start(delay, fn) {\n this.clear();\n this.currentId = setTimeout(() => {\n this.currentId = null;\n fn();\n }, delay);\n }\n}\nexport default function useTimeout() {\n const timeout = useLazyRef(Timeout.create).current;\n useOnMount(timeout.disposeEffect);\n return timeout;\n}","'use client';\n\n// based on https://github.com/WICG/focus-visible/blob/v4.1.5/src/focus-visible.js\nimport * as React from 'react';\nimport { Timeout } from '../useTimeout/useTimeout';\nlet hadKeyboardEvent = true;\nlet hadFocusVisibleRecently = false;\nconst hadFocusVisibleRecentlyTimeout = new Timeout();\nconst inputTypesWhitelist = {\n text: true,\n search: true,\n url: true,\n tel: true,\n email: true,\n password: true,\n number: true,\n date: true,\n month: true,\n week: true,\n time: true,\n datetime: true,\n 'datetime-local': true\n};\n\n/**\n * Computes whether the given element should automatically trigger the\n * `focus-visible` class being added, i.e. whether it should always match\n * `:focus-visible` when focused.\n * @param {Element} node\n * @returns {boolean}\n */\nfunction focusTriggersKeyboardModality(node) {\n const {\n type,\n tagName\n } = node;\n if (tagName === 'INPUT' && inputTypesWhitelist[type] && !node.readOnly) {\n return true;\n }\n if (tagName === 'TEXTAREA' && !node.readOnly) {\n return true;\n }\n if (node.isContentEditable) {\n return true;\n }\n return false;\n}\n\n/**\n * Keep track of our keyboard modality state with `hadKeyboardEvent`.\n * If the most recent user interaction was via the keyboard;\n * and the key press did not include a meta, alt/option, or control key;\n * then the modality is keyboard. Otherwise, the modality is not keyboard.\n * @param {KeyboardEvent} event\n */\nfunction handleKeyDown(event) {\n if (event.metaKey || event.altKey || event.ctrlKey) {\n return;\n }\n hadKeyboardEvent = true;\n}\n\n/**\n * If at any point a user clicks with a pointing device, ensure that we change\n * the modality away from keyboard.\n * This avoids the situation where a user presses a key on an already focused\n * element, and then clicks on a different element, focusing it with a\n * pointing device, while we still think we're in keyboard modality.\n */\nfunction handlePointerDown() {\n hadKeyboardEvent = false;\n}\nfunction handleVisibilityChange() {\n if (this.visibilityState === 'hidden') {\n // If the tab becomes active again, the browser will handle calling focus\n // on the element (Safari actually calls it twice).\n // If this tab change caused a blur on an element with focus-visible,\n // re-apply the class when the user switches back to the tab.\n if (hadFocusVisibleRecently) {\n hadKeyboardEvent = true;\n }\n }\n}\nfunction prepare(doc) {\n doc.addEventListener('keydown', handleKeyDown, true);\n doc.addEventListener('mousedown', handlePointerDown, true);\n doc.addEventListener('pointerdown', handlePointerDown, true);\n doc.addEventListener('touchstart', handlePointerDown, true);\n doc.addEventListener('visibilitychange', handleVisibilityChange, true);\n}\nexport function teardown(doc) {\n doc.removeEventListener('keydown', handleKeyDown, true);\n doc.removeEventListener('mousedown', handlePointerDown, true);\n doc.removeEventListener('pointerdown', handlePointerDown, true);\n doc.removeEventListener('touchstart', handlePointerDown, true);\n doc.removeEventListener('visibilitychange', handleVisibilityChange, true);\n}\nfunction isFocusVisible(event) {\n const {\n target\n } = event;\n try {\n return target.matches(':focus-visible');\n } catch (error) {\n // Browsers not implementing :focus-visible will throw a SyntaxError.\n // We use our own heuristic for those browsers.\n // Rethrow might be better if it's not the expected error but do we really\n // want to crash if focus-visible malfunctioned?\n }\n\n // No need for validFocusTarget check. The user does that by attaching it to\n // focusable events only.\n return hadKeyboardEvent || focusTriggersKeyboardModality(target);\n}\nexport default function useIsFocusVisible() {\n const ref = React.useCallback(node => {\n if (node != null) {\n prepare(node.ownerDocument);\n }\n }, []);\n const isFocusVisibleRef = React.useRef(false);\n\n /**\n * Should be called if a blur event is fired\n */\n function handleBlurVisible() {\n // checking against potential state variable does not suffice if we focus and blur synchronously.\n // React wouldn't have time to trigger a re-render so `focusVisible` would be stale.\n // Ideally we would adjust `isFocusVisible(event)` to look at `relatedTarget` for blur events.\n // This doesn't work in IE11 due to https://github.com/facebook/react/issues/3751\n // TODO: check again if React releases their internal changes to focus event handling (https://github.com/facebook/react/pull/19186).\n if (isFocusVisibleRef.current) {\n // To detect a tab/window switch, we look for a blur event followed\n // rapidly by a visibility change.\n // If we don't see a visibility change within 100ms, it's probably a\n // regular focus change.\n hadFocusVisibleRecently = true;\n hadFocusVisibleRecentlyTimeout.start(100, () => {\n hadFocusVisibleRecently = false;\n });\n isFocusVisibleRef.current = false;\n return true;\n }\n return false;\n }\n\n /**\n * Should be called if a blur event is fired\n */\n function handleFocusVisible(event) {\n if (isFocusVisible(event)) {\n isFocusVisibleRef.current = true;\n return true;\n }\n return false;\n }\n return {\n isFocusVisibleRef,\n onFocus: handleFocusVisible,\n onBlur: handleBlurVisible,\n ref\n };\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\n/**\n * Add keys, values of `defaultProps` that does not exist in `props`\n * @param {object} defaultProps\n * @param {object} props\n * @returns {object} resolved props\n */\nexport default function resolveProps(defaultProps, props) {\n const output = _extends({}, props);\n Object.keys(defaultProps).forEach(propName => {\n if (propName.toString().match(/^(components|slots)$/)) {\n output[propName] = _extends({}, defaultProps[propName], output[propName]);\n } else if (propName.toString().match(/^(componentsProps|slotProps)$/)) {\n const defaultSlotProps = defaultProps[propName] || {};\n const slotProps = props[propName];\n output[propName] = {};\n if (!slotProps || !Object.keys(slotProps)) {\n // Reduce the iteration if the slot props is empty\n output[propName] = defaultSlotProps;\n } else if (!defaultSlotProps || !Object.keys(defaultSlotProps)) {\n // Reduce the iteration if the default slot props is empty\n output[propName] = slotProps;\n } else {\n output[propName] = _extends({}, slotProps);\n Object.keys(defaultSlotProps).forEach(slotPropName => {\n output[propName][slotPropName] = resolveProps(defaultSlotProps[slotPropName], slotProps[slotPropName]);\n });\n }\n } else if (output[propName] === undefined) {\n output[propName] = defaultProps[propName];\n }\n });\n return output;\n}","export default function composeClasses(slots, getUtilityClass, classes = undefined) {\n const output = {};\n Object.keys(slots).forEach(\n // `Object.keys(slots)` can't be wider than `T` because we infer `T` from `slots`.\n // @ts-expect-error https://github.com/microsoft/TypeScript/pull/12253#issuecomment-263132208\n slot => {\n output[slot] = slots[slot].reduce((acc, key) => {\n if (key) {\n const utilityClass = getUtilityClass(key);\n if (utilityClass !== '') {\n acc.push(utilityClass);\n }\n if (classes && classes[key]) {\n acc.push(classes[key]);\n }\n }\n return acc;\n }, []).join(' ');\n });\n return output;\n}","const defaultGenerator = componentName => componentName;\nconst createClassNameGenerator = () => {\n let generate = defaultGenerator;\n return {\n configure(generator) {\n generate = generator;\n },\n generate(componentName) {\n return generate(componentName);\n },\n reset() {\n generate = defaultGenerator;\n }\n };\n};\nconst ClassNameGenerator = createClassNameGenerator();\nexport default ClassNameGenerator;","import ClassNameGenerator from '../ClassNameGenerator';\nexport const globalStateClasses = {\n active: 'active',\n checked: 'checked',\n completed: 'completed',\n disabled: 'disabled',\n error: 'error',\n expanded: 'expanded',\n focused: 'focused',\n focusVisible: 'focusVisible',\n open: 'open',\n readOnly: 'readOnly',\n required: 'required',\n selected: 'selected'\n};\nexport default function generateUtilityClass(componentName, slot, globalStatePrefix = 'Mui') {\n const globalStateClass = globalStateClasses[slot];\n return globalStateClass ? `${globalStatePrefix}-${globalStateClass}` : `${ClassNameGenerator.generate(componentName)}-${slot}`;\n}\nexport function isGlobalState(slot) {\n return globalStateClasses[slot] !== undefined;\n}","import generateUtilityClass from '../generateUtilityClass';\nexport default function generateUtilityClasses(componentName, slots, globalStatePrefix = 'Mui') {\n const result = {};\n slots.forEach(slot => {\n result[slot] = generateUtilityClass(componentName, slot, globalStatePrefix);\n });\n return result;\n}","function clamp(val, min = Number.MIN_SAFE_INTEGER, max = Number.MAX_SAFE_INTEGER) {\n return Math.max(min, Math.min(val, max));\n}\nexport default clamp;","export default function _objectWithoutPropertiesLoose(source, excluded) {\n if (source == null) return {};\n var target = {};\n var sourceKeys = Object.keys(source);\n var key, i;\n for (i = 0; i < sourceKeys.length; i++) {\n key = sourceKeys[i];\n if (excluded.indexOf(key) >= 0) continue;\n target[key] = source[key];\n }\n return target;\n}","import _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nconst _excluded = [\"values\", \"unit\", \"step\"];\n// Sorted ASC by size. That's important.\n// It can't be configured as it's used statically for propTypes.\nexport const breakpointKeys = ['xs', 'sm', 'md', 'lg', 'xl'];\nconst sortBreakpointsValues = values => {\n const breakpointsAsArray = Object.keys(values).map(key => ({\n key,\n val: values[key]\n })) || [];\n // Sort in ascending order\n breakpointsAsArray.sort((breakpoint1, breakpoint2) => breakpoint1.val - breakpoint2.val);\n return breakpointsAsArray.reduce((acc, obj) => {\n return _extends({}, acc, {\n [obj.key]: obj.val\n });\n }, {});\n};\n\n// Keep in mind that @media is inclusive by the CSS specification.\nexport default function createBreakpoints(breakpoints) {\n const {\n // The breakpoint **start** at this value.\n // For instance with the first breakpoint xs: [xs, sm).\n values = {\n xs: 0,\n // phone\n sm: 600,\n // tablet\n md: 900,\n // small laptop\n lg: 1200,\n // desktop\n xl: 1536 // large screen\n },\n unit = 'px',\n step = 5\n } = breakpoints,\n other = _objectWithoutPropertiesLoose(breakpoints, _excluded);\n const sortedValues = sortBreakpointsValues(values);\n const keys = Object.keys(sortedValues);\n function up(key) {\n const value = typeof values[key] === 'number' ? values[key] : key;\n return `@media (min-width:${value}${unit})`;\n }\n function down(key) {\n const value = typeof values[key] === 'number' ? values[key] : key;\n return `@media (max-width:${value - step / 100}${unit})`;\n }\n function between(start, end) {\n const endIndex = keys.indexOf(end);\n return `@media (min-width:${typeof values[start] === 'number' ? values[start] : start}${unit}) and ` + `(max-width:${(endIndex !== -1 && typeof values[keys[endIndex]] === 'number' ? values[keys[endIndex]] : end) - step / 100}${unit})`;\n }\n function only(key) {\n if (keys.indexOf(key) + 1 < keys.length) {\n return between(key, keys[keys.indexOf(key) + 1]);\n }\n return up(key);\n }\n function not(key) {\n // handle first and last key separately, for better readability\n const keyIndex = keys.indexOf(key);\n if (keyIndex === 0) {\n return up(keys[1]);\n }\n if (keyIndex === keys.length - 1) {\n return down(keys[keyIndex]);\n }\n return between(key, keys[keys.indexOf(key) + 1]).replace('@media', '@media not all and');\n }\n return _extends({\n keys,\n values: sortedValues,\n up,\n down,\n between,\n only,\n not,\n unit\n }, other);\n}","const shape = {\n borderRadius: 4\n};\nexport default shape;","import PropTypes from 'prop-types';\nconst responsivePropType = process.env.NODE_ENV !== 'production' ? PropTypes.oneOfType([PropTypes.number, PropTypes.string, PropTypes.object, PropTypes.array]) : {};\nexport default responsivePropType;","import deepmerge from '@mui/utils/deepmerge';\nfunction merge(acc, item) {\n if (!item) {\n return acc;\n }\n return deepmerge(acc, item, {\n clone: false // No need to clone deep, it's way faster.\n });\n}\nexport default merge;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport PropTypes from 'prop-types';\nimport deepmerge from '@mui/utils/deepmerge';\nimport merge from './merge';\n\n// The breakpoint **start** at this value.\n// For instance with the first breakpoint xs: [xs, sm[.\nexport const values = {\n xs: 0,\n // phone\n sm: 600,\n // tablet\n md: 900,\n // small laptop\n lg: 1200,\n // desktop\n xl: 1536 // large screen\n};\nconst defaultBreakpoints = {\n // Sorted ASC by size. That's important.\n // It can't be configured as it's used statically for propTypes.\n keys: ['xs', 'sm', 'md', 'lg', 'xl'],\n up: key => `@media (min-width:${values[key]}px)`\n};\nexport function handleBreakpoints(props, propValue, styleFromPropValue) {\n const theme = props.theme || {};\n if (Array.isArray(propValue)) {\n const themeBreakpoints = theme.breakpoints || defaultBreakpoints;\n return propValue.reduce((acc, item, index) => {\n acc[themeBreakpoints.up(themeBreakpoints.keys[index])] = styleFromPropValue(propValue[index]);\n return acc;\n }, {});\n }\n if (typeof propValue === 'object') {\n const themeBreakpoints = theme.breakpoints || defaultBreakpoints;\n return Object.keys(propValue).reduce((acc, breakpoint) => {\n // key is breakpoint\n if (Object.keys(themeBreakpoints.values || values).indexOf(breakpoint) !== -1) {\n const mediaKey = themeBreakpoints.up(breakpoint);\n acc[mediaKey] = styleFromPropValue(propValue[breakpoint], breakpoint);\n } else {\n const cssKey = breakpoint;\n acc[cssKey] = propValue[cssKey];\n }\n return acc;\n }, {});\n }\n const output = styleFromPropValue(propValue);\n return output;\n}\nfunction breakpoints(styleFunction) {\n // false positive\n // eslint-disable-next-line react/function-component-definition\n const newStyleFunction = props => {\n const theme = props.theme || {};\n const base = styleFunction(props);\n const themeBreakpoints = theme.breakpoints || defaultBreakpoints;\n const extended = themeBreakpoints.keys.reduce((acc, key) => {\n if (props[key]) {\n acc = acc || {};\n acc[themeBreakpoints.up(key)] = styleFunction(_extends({\n theme\n }, props[key]));\n }\n return acc;\n }, null);\n return merge(base, extended);\n };\n newStyleFunction.propTypes = process.env.NODE_ENV !== 'production' ? _extends({}, styleFunction.propTypes, {\n xs: PropTypes.object,\n sm: PropTypes.object,\n md: PropTypes.object,\n lg: PropTypes.object,\n xl: PropTypes.object\n }) : {};\n newStyleFunction.filterProps = ['xs', 'sm', 'md', 'lg', 'xl', ...styleFunction.filterProps];\n return newStyleFunction;\n}\nexport function createEmptyBreakpointObject(breakpointsInput = {}) {\n var _breakpointsInput$key;\n const breakpointsInOrder = (_breakpointsInput$key = breakpointsInput.keys) == null ? void 0 : _breakpointsInput$key.reduce((acc, key) => {\n const breakpointStyleKey = breakpointsInput.up(key);\n acc[breakpointStyleKey] = {};\n return acc;\n }, {});\n return breakpointsInOrder || {};\n}\nexport function removeUnusedBreakpoints(breakpointKeys, style) {\n return breakpointKeys.reduce((acc, key) => {\n const breakpointOutput = acc[key];\n const isBreakpointUnused = !breakpointOutput || Object.keys(breakpointOutput).length === 0;\n if (isBreakpointUnused) {\n delete acc[key];\n }\n return acc;\n }, style);\n}\nexport function mergeBreakpointsInOrder(breakpointsInput, ...styles) {\n const emptyBreakpoints = createEmptyBreakpointObject(breakpointsInput);\n const mergedOutput = [emptyBreakpoints, ...styles].reduce((prev, next) => deepmerge(prev, next), {});\n return removeUnusedBreakpoints(Object.keys(emptyBreakpoints), mergedOutput);\n}\n\n// compute base for responsive values; e.g.,\n// [1,2,3] => {xs: true, sm: true, md: true}\n// {xs: 1, sm: 2, md: 3} => {xs: true, sm: true, md: true}\nexport function computeBreakpointsBase(breakpointValues, themeBreakpoints) {\n // fixed value\n if (typeof breakpointValues !== 'object') {\n return {};\n }\n const base = {};\n const breakpointsKeys = Object.keys(themeBreakpoints);\n if (Array.isArray(breakpointValues)) {\n breakpointsKeys.forEach((breakpoint, i) => {\n if (i < breakpointValues.length) {\n base[breakpoint] = true;\n }\n });\n } else {\n breakpointsKeys.forEach(breakpoint => {\n if (breakpointValues[breakpoint] != null) {\n base[breakpoint] = true;\n }\n });\n }\n return base;\n}\nexport function resolveBreakpointValues({\n values: breakpointValues,\n breakpoints: themeBreakpoints,\n base: customBase\n}) {\n const base = customBase || computeBreakpointsBase(breakpointValues, themeBreakpoints);\n const keys = Object.keys(base);\n if (keys.length === 0) {\n return breakpointValues;\n }\n let previous;\n return keys.reduce((acc, breakpoint, i) => {\n if (Array.isArray(breakpointValues)) {\n acc[breakpoint] = breakpointValues[i] != null ? breakpointValues[i] : breakpointValues[previous];\n previous = i;\n } else if (typeof breakpointValues === 'object') {\n acc[breakpoint] = breakpointValues[breakpoint] != null ? breakpointValues[breakpoint] : breakpointValues[previous];\n previous = breakpoint;\n } else {\n acc[breakpoint] = breakpointValues;\n }\n return acc;\n }, {});\n}\nexport default breakpoints;","import capitalize from '@mui/utils/capitalize';\nimport responsivePropType from './responsivePropType';\nimport { handleBreakpoints } from './breakpoints';\nexport function getPath(obj, path, checkVars = true) {\n if (!path || typeof path !== 'string') {\n return null;\n }\n\n // Check if CSS variables are used\n if (obj && obj.vars && checkVars) {\n const val = `vars.${path}`.split('.').reduce((acc, item) => acc && acc[item] ? acc[item] : null, obj);\n if (val != null) {\n return val;\n }\n }\n return path.split('.').reduce((acc, item) => {\n if (acc && acc[item] != null) {\n return acc[item];\n }\n return null;\n }, obj);\n}\nexport function getStyleValue(themeMapping, transform, propValueFinal, userValue = propValueFinal) {\n let value;\n if (typeof themeMapping === 'function') {\n value = themeMapping(propValueFinal);\n } else if (Array.isArray(themeMapping)) {\n value = themeMapping[propValueFinal] || userValue;\n } else {\n value = getPath(themeMapping, propValueFinal) || userValue;\n }\n if (transform) {\n value = transform(value, userValue, themeMapping);\n }\n return value;\n}\nfunction style(options) {\n const {\n prop,\n cssProperty = options.prop,\n themeKey,\n transform\n } = options;\n\n // false positive\n // eslint-disable-next-line react/function-component-definition\n const fn = props => {\n if (props[prop] == null) {\n return null;\n }\n const propValue = props[prop];\n const theme = props.theme;\n const themeMapping = getPath(theme, themeKey) || {};\n const styleFromPropValue = propValueFinal => {\n let value = getStyleValue(themeMapping, transform, propValueFinal);\n if (propValueFinal === value && typeof propValueFinal === 'string') {\n // Haven't found value\n value = getStyleValue(themeMapping, transform, `${prop}${propValueFinal === 'default' ? '' : capitalize(propValueFinal)}`, propValueFinal);\n }\n if (cssProperty === false) {\n return value;\n }\n return {\n [cssProperty]: value\n };\n };\n return handleBreakpoints(props, propValue, styleFromPropValue);\n };\n fn.propTypes = process.env.NODE_ENV !== 'production' ? {\n [prop]: responsivePropType\n } : {};\n fn.filterProps = [prop];\n return fn;\n}\nexport default style;","export default function memoize(fn) {\n const cache = {};\n return arg => {\n if (cache[arg] === undefined) {\n cache[arg] = fn(arg);\n }\n return cache[arg];\n };\n}","import responsivePropType from './responsivePropType';\nimport { handleBreakpoints } from './breakpoints';\nimport { getPath } from './style';\nimport merge from './merge';\nimport memoize from './memoize';\nconst properties = {\n m: 'margin',\n p: 'padding'\n};\nconst directions = {\n t: 'Top',\n r: 'Right',\n b: 'Bottom',\n l: 'Left',\n x: ['Left', 'Right'],\n y: ['Top', 'Bottom']\n};\nconst aliases = {\n marginX: 'mx',\n marginY: 'my',\n paddingX: 'px',\n paddingY: 'py'\n};\n\n// memoize() impact:\n// From 300,000 ops/sec\n// To 350,000 ops/sec\nconst getCssProperties = memoize(prop => {\n // It's not a shorthand notation.\n if (prop.length > 2) {\n if (aliases[prop]) {\n prop = aliases[prop];\n } else {\n return [prop];\n }\n }\n const [a, b] = prop.split('');\n const property = properties[a];\n const direction = directions[b] || '';\n return Array.isArray(direction) ? direction.map(dir => property + dir) : [property + direction];\n});\nexport const marginKeys = ['m', 'mt', 'mr', 'mb', 'ml', 'mx', 'my', 'margin', 'marginTop', 'marginRight', 'marginBottom', 'marginLeft', 'marginX', 'marginY', 'marginInline', 'marginInlineStart', 'marginInlineEnd', 'marginBlock', 'marginBlockStart', 'marginBlockEnd'];\nexport const paddingKeys = ['p', 'pt', 'pr', 'pb', 'pl', 'px', 'py', 'padding', 'paddingTop', 'paddingRight', 'paddingBottom', 'paddingLeft', 'paddingX', 'paddingY', 'paddingInline', 'paddingInlineStart', 'paddingInlineEnd', 'paddingBlock', 'paddingBlockStart', 'paddingBlockEnd'];\nconst spacingKeys = [...marginKeys, ...paddingKeys];\nexport function createUnaryUnit(theme, themeKey, defaultValue, propName) {\n var _getPath;\n const themeSpacing = (_getPath = getPath(theme, themeKey, false)) != null ? _getPath : defaultValue;\n if (typeof themeSpacing === 'number') {\n return abs => {\n if (typeof abs === 'string') {\n return abs;\n }\n if (process.env.NODE_ENV !== 'production') {\n if (typeof abs !== 'number') {\n console.error(`MUI: Expected ${propName} argument to be a number or a string, got ${abs}.`);\n }\n }\n return themeSpacing * abs;\n };\n }\n if (Array.isArray(themeSpacing)) {\n return abs => {\n if (typeof abs === 'string') {\n return abs;\n }\n if (process.env.NODE_ENV !== 'production') {\n if (!Number.isInteger(abs)) {\n console.error([`MUI: The \\`theme.${themeKey}\\` array type cannot be combined with non integer values.` + `You should either use an integer value that can be used as index, or define the \\`theme.${themeKey}\\` as a number.`].join('\\n'));\n } else if (abs > themeSpacing.length - 1) {\n console.error([`MUI: The value provided (${abs}) overflows.`, `The supported values are: ${JSON.stringify(themeSpacing)}.`, `${abs} > ${themeSpacing.length - 1}, you need to add the missing values.`].join('\\n'));\n }\n }\n return themeSpacing[abs];\n };\n }\n if (typeof themeSpacing === 'function') {\n return themeSpacing;\n }\n if (process.env.NODE_ENV !== 'production') {\n console.error([`MUI: The \\`theme.${themeKey}\\` value (${themeSpacing}) is invalid.`, 'It should be a number, an array or a function.'].join('\\n'));\n }\n return () => undefined;\n}\nexport function createUnarySpacing(theme) {\n return createUnaryUnit(theme, 'spacing', 8, 'spacing');\n}\nexport function getValue(transformer, propValue) {\n if (typeof propValue === 'string' || propValue == null) {\n return propValue;\n }\n const abs = Math.abs(propValue);\n const transformed = transformer(abs);\n if (propValue >= 0) {\n return transformed;\n }\n if (typeof transformed === 'number') {\n return -transformed;\n }\n return `-${transformed}`;\n}\nexport function getStyleFromPropValue(cssProperties, transformer) {\n return propValue => cssProperties.reduce((acc, cssProperty) => {\n acc[cssProperty] = getValue(transformer, propValue);\n return acc;\n }, {});\n}\nfunction resolveCssProperty(props, keys, prop, transformer) {\n // Using a hash computation over an array iteration could be faster, but with only 28 items,\n // it's doesn't worth the bundle size.\n if (keys.indexOf(prop) === -1) {\n return null;\n }\n const cssProperties = getCssProperties(prop);\n const styleFromPropValue = getStyleFromPropValue(cssProperties, transformer);\n const propValue = props[prop];\n return handleBreakpoints(props, propValue, styleFromPropValue);\n}\nfunction style(props, keys) {\n const transformer = createUnarySpacing(props.theme);\n return Object.keys(props).map(prop => resolveCssProperty(props, keys, prop, transformer)).reduce(merge, {});\n}\nexport function margin(props) {\n return style(props, marginKeys);\n}\nmargin.propTypes = process.env.NODE_ENV !== 'production' ? marginKeys.reduce((obj, key) => {\n obj[key] = responsivePropType;\n return obj;\n}, {}) : {};\nmargin.filterProps = marginKeys;\nexport function padding(props) {\n return style(props, paddingKeys);\n}\npadding.propTypes = process.env.NODE_ENV !== 'production' ? paddingKeys.reduce((obj, key) => {\n obj[key] = responsivePropType;\n return obj;\n}, {}) : {};\npadding.filterProps = paddingKeys;\nfunction spacing(props) {\n return style(props, spacingKeys);\n}\nspacing.propTypes = process.env.NODE_ENV !== 'production' ? spacingKeys.reduce((obj, key) => {\n obj[key] = responsivePropType;\n return obj;\n}, {}) : {};\nspacing.filterProps = spacingKeys;\nexport default spacing;","import { createUnarySpacing } from '../spacing';\n\n// The different signatures imply different meaning for their arguments that can't be expressed structurally.\n// We express the difference with variable names.\n\nexport default function createSpacing(spacingInput = 8) {\n // Already transformed.\n if (spacingInput.mui) {\n return spacingInput;\n }\n\n // Material Design layouts are visually balanced. Most measurements align to an 8dp grid, which aligns both spacing and the overall layout.\n // Smaller components, such as icons, can align to a 4dp grid.\n // https://m2.material.io/design/layout/understanding-layout.html\n const transform = createUnarySpacing({\n spacing: spacingInput\n });\n const spacing = (...argsInput) => {\n if (process.env.NODE_ENV !== 'production') {\n if (!(argsInput.length <= 4)) {\n console.error(`MUI: Too many arguments provided, expected between 0 and 4, got ${argsInput.length}`);\n }\n }\n const args = argsInput.length === 0 ? [1] : argsInput;\n return args.map(argument => {\n const output = transform(argument);\n return typeof output === 'number' ? `${output}px` : output;\n }).join(' ');\n };\n spacing.mui = true;\n return spacing;\n}","import merge from './merge';\nfunction compose(...styles) {\n const handlers = styles.reduce((acc, style) => {\n style.filterProps.forEach(prop => {\n acc[prop] = style;\n });\n return acc;\n }, {});\n\n // false positive\n // eslint-disable-next-line react/function-component-definition\n const fn = props => {\n return Object.keys(props).reduce((acc, prop) => {\n if (handlers[prop]) {\n return merge(acc, handlers[prop](props));\n }\n return acc;\n }, {});\n };\n fn.propTypes = process.env.NODE_ENV !== 'production' ? styles.reduce((acc, style) => Object.assign(acc, style.propTypes), {}) : {};\n fn.filterProps = styles.reduce((acc, style) => acc.concat(style.filterProps), []);\n return fn;\n}\nexport default compose;","import responsivePropType from './responsivePropType';\nimport style from './style';\nimport compose from './compose';\nimport { createUnaryUnit, getValue } from './spacing';\nimport { handleBreakpoints } from './breakpoints';\nexport function borderTransform(value) {\n if (typeof value !== 'number') {\n return value;\n }\n return `${value}px solid`;\n}\nfunction createBorderStyle(prop, transform) {\n return style({\n prop,\n themeKey: 'borders',\n transform\n });\n}\nexport const border = createBorderStyle('border', borderTransform);\nexport const borderTop = createBorderStyle('borderTop', borderTransform);\nexport const borderRight = createBorderStyle('borderRight', borderTransform);\nexport const borderBottom = createBorderStyle('borderBottom', borderTransform);\nexport const borderLeft = createBorderStyle('borderLeft', borderTransform);\nexport const borderColor = createBorderStyle('borderColor');\nexport const borderTopColor = createBorderStyle('borderTopColor');\nexport const borderRightColor = createBorderStyle('borderRightColor');\nexport const borderBottomColor = createBorderStyle('borderBottomColor');\nexport const borderLeftColor = createBorderStyle('borderLeftColor');\nexport const outline = createBorderStyle('outline', borderTransform);\nexport const outlineColor = createBorderStyle('outlineColor');\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const borderRadius = props => {\n if (props.borderRadius !== undefined && props.borderRadius !== null) {\n const transformer = createUnaryUnit(props.theme, 'shape.borderRadius', 4, 'borderRadius');\n const styleFromPropValue = propValue => ({\n borderRadius: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.borderRadius, styleFromPropValue);\n }\n return null;\n};\nborderRadius.propTypes = process.env.NODE_ENV !== 'production' ? {\n borderRadius: responsivePropType\n} : {};\nborderRadius.filterProps = ['borderRadius'];\nconst borders = compose(border, borderTop, borderRight, borderBottom, borderLeft, borderColor, borderTopColor, borderRightColor, borderBottomColor, borderLeftColor, borderRadius, outline, outlineColor);\nexport default borders;","import style from './style';\nimport compose from './compose';\nimport { createUnaryUnit, getValue } from './spacing';\nimport { handleBreakpoints } from './breakpoints';\nimport responsivePropType from './responsivePropType';\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const gap = props => {\n if (props.gap !== undefined && props.gap !== null) {\n const transformer = createUnaryUnit(props.theme, 'spacing', 8, 'gap');\n const styleFromPropValue = propValue => ({\n gap: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.gap, styleFromPropValue);\n }\n return null;\n};\ngap.propTypes = process.env.NODE_ENV !== 'production' ? {\n gap: responsivePropType\n} : {};\ngap.filterProps = ['gap'];\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const columnGap = props => {\n if (props.columnGap !== undefined && props.columnGap !== null) {\n const transformer = createUnaryUnit(props.theme, 'spacing', 8, 'columnGap');\n const styleFromPropValue = propValue => ({\n columnGap: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.columnGap, styleFromPropValue);\n }\n return null;\n};\ncolumnGap.propTypes = process.env.NODE_ENV !== 'production' ? {\n columnGap: responsivePropType\n} : {};\ncolumnGap.filterProps = ['columnGap'];\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const rowGap = props => {\n if (props.rowGap !== undefined && props.rowGap !== null) {\n const transformer = createUnaryUnit(props.theme, 'spacing', 8, 'rowGap');\n const styleFromPropValue = propValue => ({\n rowGap: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.rowGap, styleFromPropValue);\n }\n return null;\n};\nrowGap.propTypes = process.env.NODE_ENV !== 'production' ? {\n rowGap: responsivePropType\n} : {};\nrowGap.filterProps = ['rowGap'];\nexport const gridColumn = style({\n prop: 'gridColumn'\n});\nexport const gridRow = style({\n prop: 'gridRow'\n});\nexport const gridAutoFlow = style({\n prop: 'gridAutoFlow'\n});\nexport const gridAutoColumns = style({\n prop: 'gridAutoColumns'\n});\nexport const gridAutoRows = style({\n prop: 'gridAutoRows'\n});\nexport const gridTemplateColumns = style({\n prop: 'gridTemplateColumns'\n});\nexport const gridTemplateRows = style({\n prop: 'gridTemplateRows'\n});\nexport const gridTemplateAreas = style({\n prop: 'gridTemplateAreas'\n});\nexport const gridArea = style({\n prop: 'gridArea'\n});\nconst grid = compose(gap, columnGap, rowGap, gridColumn, gridRow, gridAutoFlow, gridAutoColumns, gridAutoRows, gridTemplateColumns, gridTemplateRows, gridTemplateAreas, gridArea);\nexport default grid;","import style from './style';\nimport compose from './compose';\nexport function paletteTransform(value, userValue) {\n if (userValue === 'grey') {\n return userValue;\n }\n return value;\n}\nexport const color = style({\n prop: 'color',\n themeKey: 'palette',\n transform: paletteTransform\n});\nexport const bgcolor = style({\n prop: 'bgcolor',\n cssProperty: 'backgroundColor',\n themeKey: 'palette',\n transform: paletteTransform\n});\nexport const backgroundColor = style({\n prop: 'backgroundColor',\n themeKey: 'palette',\n transform: paletteTransform\n});\nconst palette = compose(color, bgcolor, backgroundColor);\nexport default palette;","import style from './style';\nimport compose from './compose';\nimport { handleBreakpoints, values as breakpointsValues } from './breakpoints';\nexport function sizingTransform(value) {\n return value <= 1 && value !== 0 ? `${value * 100}%` : value;\n}\nexport const width = style({\n prop: 'width',\n transform: sizingTransform\n});\nexport const maxWidth = props => {\n if (props.maxWidth !== undefined && props.maxWidth !== null) {\n const styleFromPropValue = propValue => {\n var _props$theme, _props$theme2;\n const breakpoint = ((_props$theme = props.theme) == null || (_props$theme = _props$theme.breakpoints) == null || (_props$theme = _props$theme.values) == null ? void 0 : _props$theme[propValue]) || breakpointsValues[propValue];\n if (!breakpoint) {\n return {\n maxWidth: sizingTransform(propValue)\n };\n }\n if (((_props$theme2 = props.theme) == null || (_props$theme2 = _props$theme2.breakpoints) == null ? void 0 : _props$theme2.unit) !== 'px') {\n return {\n maxWidth: `${breakpoint}${props.theme.breakpoints.unit}`\n };\n }\n return {\n maxWidth: breakpoint\n };\n };\n return handleBreakpoints(props, props.maxWidth, styleFromPropValue);\n }\n return null;\n};\nmaxWidth.filterProps = ['maxWidth'];\nexport const minWidth = style({\n prop: 'minWidth',\n transform: sizingTransform\n});\nexport const height = style({\n prop: 'height',\n transform: sizingTransform\n});\nexport const maxHeight = style({\n prop: 'maxHeight',\n transform: sizingTransform\n});\nexport const minHeight = style({\n prop: 'minHeight',\n transform: sizingTransform\n});\nexport const sizeWidth = style({\n prop: 'size',\n cssProperty: 'width',\n transform: sizingTransform\n});\nexport const sizeHeight = style({\n prop: 'size',\n cssProperty: 'height',\n transform: sizingTransform\n});\nexport const boxSizing = style({\n prop: 'boxSizing'\n});\nconst sizing = compose(width, maxWidth, minWidth, height, maxHeight, minHeight, boxSizing);\nexport default sizing;","import { padding, margin } from '../spacing';\nimport { borderRadius, borderTransform } from '../borders';\nimport { gap, rowGap, columnGap } from '../cssGrid';\nimport { paletteTransform } from '../palette';\nimport { maxWidth, sizingTransform } from '../sizing';\nconst defaultSxConfig = {\n // borders\n border: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderTop: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderRight: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderBottom: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderLeft: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderColor: {\n themeKey: 'palette'\n },\n borderTopColor: {\n themeKey: 'palette'\n },\n borderRightColor: {\n themeKey: 'palette'\n },\n borderBottomColor: {\n themeKey: 'palette'\n },\n borderLeftColor: {\n themeKey: 'palette'\n },\n outline: {\n themeKey: 'borders',\n transform: borderTransform\n },\n outlineColor: {\n themeKey: 'palette'\n },\n borderRadius: {\n themeKey: 'shape.borderRadius',\n style: borderRadius\n },\n // palette\n color: {\n themeKey: 'palette',\n transform: paletteTransform\n },\n bgcolor: {\n themeKey: 'palette',\n cssProperty: 'backgroundColor',\n transform: paletteTransform\n },\n backgroundColor: {\n themeKey: 'palette',\n transform: paletteTransform\n },\n // spacing\n p: {\n style: padding\n },\n pt: {\n style: padding\n },\n pr: {\n style: padding\n },\n pb: {\n style: padding\n },\n pl: {\n style: padding\n },\n px: {\n style: padding\n },\n py: {\n style: padding\n },\n padding: {\n style: padding\n },\n paddingTop: {\n style: padding\n },\n paddingRight: {\n style: padding\n },\n paddingBottom: {\n style: padding\n },\n paddingLeft: {\n style: padding\n },\n paddingX: {\n style: padding\n },\n paddingY: {\n style: padding\n },\n paddingInline: {\n style: padding\n },\n paddingInlineStart: {\n style: padding\n },\n paddingInlineEnd: {\n style: padding\n },\n paddingBlock: {\n style: padding\n },\n paddingBlockStart: {\n style: padding\n },\n paddingBlockEnd: {\n style: padding\n },\n m: {\n style: margin\n },\n mt: {\n style: margin\n },\n mr: {\n style: margin\n },\n mb: {\n style: margin\n },\n ml: {\n style: margin\n },\n mx: {\n style: margin\n },\n my: {\n style: margin\n },\n margin: {\n style: margin\n },\n marginTop: {\n style: margin\n },\n marginRight: {\n style: margin\n },\n marginBottom: {\n style: margin\n },\n marginLeft: {\n style: margin\n },\n marginX: {\n style: margin\n },\n marginY: {\n style: margin\n },\n marginInline: {\n style: margin\n },\n marginInlineStart: {\n style: margin\n },\n marginInlineEnd: {\n style: margin\n },\n marginBlock: {\n style: margin\n },\n marginBlockStart: {\n style: margin\n },\n marginBlockEnd: {\n style: margin\n },\n // display\n displayPrint: {\n cssProperty: false,\n transform: value => ({\n '@media print': {\n display: value\n }\n })\n },\n display: {},\n overflow: {},\n textOverflow: {},\n visibility: {},\n whiteSpace: {},\n // flexbox\n flexBasis: {},\n flexDirection: {},\n flexWrap: {},\n justifyContent: {},\n alignItems: {},\n alignContent: {},\n order: {},\n flex: {},\n flexGrow: {},\n flexShrink: {},\n alignSelf: {},\n justifyItems: {},\n justifySelf: {},\n // grid\n gap: {\n style: gap\n },\n rowGap: {\n style: rowGap\n },\n columnGap: {\n style: columnGap\n },\n gridColumn: {},\n gridRow: {},\n gridAutoFlow: {},\n gridAutoColumns: {},\n gridAutoRows: {},\n gridTemplateColumns: {},\n gridTemplateRows: {},\n gridTemplateAreas: {},\n gridArea: {},\n // positions\n position: {},\n zIndex: {\n themeKey: 'zIndex'\n },\n top: {},\n right: {},\n bottom: {},\n left: {},\n // shadows\n boxShadow: {\n themeKey: 'shadows'\n },\n // sizing\n width: {\n transform: sizingTransform\n },\n maxWidth: {\n style: maxWidth\n },\n minWidth: {\n transform: sizingTransform\n },\n height: {\n transform: sizingTransform\n },\n maxHeight: {\n transform: sizingTransform\n },\n minHeight: {\n transform: sizingTransform\n },\n boxSizing: {},\n // typography\n fontFamily: {\n themeKey: 'typography'\n },\n fontSize: {\n themeKey: 'typography'\n },\n fontStyle: {\n themeKey: 'typography'\n },\n fontWeight: {\n themeKey: 'typography'\n },\n letterSpacing: {},\n textTransform: {},\n lineHeight: {},\n textAlign: {},\n typography: {\n cssProperty: false,\n themeKey: 'typography'\n }\n};\nexport default defaultSxConfig;","import capitalize from '@mui/utils/capitalize';\nimport merge from '../merge';\nimport { getPath, getStyleValue as getValue } from '../style';\nimport { handleBreakpoints, createEmptyBreakpointObject, removeUnusedBreakpoints } from '../breakpoints';\nimport defaultSxConfig from './defaultSxConfig';\nfunction objectsHaveSameKeys(...objects) {\n const allKeys = objects.reduce((keys, object) => keys.concat(Object.keys(object)), []);\n const union = new Set(allKeys);\n return objects.every(object => union.size === Object.keys(object).length);\n}\nfunction callIfFn(maybeFn, arg) {\n return typeof maybeFn === 'function' ? maybeFn(arg) : maybeFn;\n}\n\n// eslint-disable-next-line @typescript-eslint/naming-convention\nexport function unstable_createStyleFunctionSx() {\n function getThemeValue(prop, val, theme, config) {\n const props = {\n [prop]: val,\n theme\n };\n const options = config[prop];\n if (!options) {\n return {\n [prop]: val\n };\n }\n const {\n cssProperty = prop,\n themeKey,\n transform,\n style\n } = options;\n if (val == null) {\n return null;\n }\n\n // TODO v6: remove, see https://github.com/mui/material-ui/pull/38123\n if (themeKey === 'typography' && val === 'inherit') {\n return {\n [prop]: val\n };\n }\n const themeMapping = getPath(theme, themeKey) || {};\n if (style) {\n return style(props);\n }\n const styleFromPropValue = propValueFinal => {\n let value = getValue(themeMapping, transform, propValueFinal);\n if (propValueFinal === value && typeof propValueFinal === 'string') {\n // Haven't found value\n value = getValue(themeMapping, transform, `${prop}${propValueFinal === 'default' ? '' : capitalize(propValueFinal)}`, propValueFinal);\n }\n if (cssProperty === false) {\n return value;\n }\n return {\n [cssProperty]: value\n };\n };\n return handleBreakpoints(props, val, styleFromPropValue);\n }\n function styleFunctionSx(props) {\n var _theme$unstable_sxCon;\n const {\n sx,\n theme = {}\n } = props || {};\n if (!sx) {\n return null; // Emotion & styled-components will neglect null\n }\n const config = (_theme$unstable_sxCon = theme.unstable_sxConfig) != null ? _theme$unstable_sxCon : defaultSxConfig;\n\n /*\n * Receive `sxInput` as object or callback\n * and then recursively check keys & values to create media query object styles.\n * (the result will be used in `styled`)\n */\n function traverse(sxInput) {\n let sxObject = sxInput;\n if (typeof sxInput === 'function') {\n sxObject = sxInput(theme);\n } else if (typeof sxInput !== 'object') {\n // value\n return sxInput;\n }\n if (!sxObject) {\n return null;\n }\n const emptyBreakpoints = createEmptyBreakpointObject(theme.breakpoints);\n const breakpointsKeys = Object.keys(emptyBreakpoints);\n let css = emptyBreakpoints;\n Object.keys(sxObject).forEach(styleKey => {\n const value = callIfFn(sxObject[styleKey], theme);\n if (value !== null && value !== undefined) {\n if (typeof value === 'object') {\n if (config[styleKey]) {\n css = merge(css, getThemeValue(styleKey, value, theme, config));\n } else {\n const breakpointsValues = handleBreakpoints({\n theme\n }, value, x => ({\n [styleKey]: x\n }));\n if (objectsHaveSameKeys(breakpointsValues, value)) {\n css[styleKey] = styleFunctionSx({\n sx: value,\n theme\n });\n } else {\n css = merge(css, breakpointsValues);\n }\n }\n } else {\n css = merge(css, getThemeValue(styleKey, value, theme, config));\n }\n }\n });\n return removeUnusedBreakpoints(breakpointsKeys, css);\n }\n return Array.isArray(sx) ? sx.map(traverse) : traverse(sx);\n }\n return styleFunctionSx;\n}\nconst styleFunctionSx = unstable_createStyleFunctionSx();\nstyleFunctionSx.filterProps = ['sx'];\nexport default styleFunctionSx;","/**\n * A universal utility to style components with multiple color modes. Always use it from the theme object.\n * It works with:\n * - [Basic theme](https://mui.com/material-ui/customization/dark-mode/)\n * - [CSS theme variables](https://mui.com/material-ui/experimental-api/css-theme-variables/overview/)\n * - Zero-runtime engine\n *\n * Tips: Use an array over object spread and place `theme.applyStyles()` last.\n *\n * ✅ [{ background: '#e5e5e5' }, theme.applyStyles('dark', { background: '#1c1c1c' })]\n *\n * 🚫 { background: '#e5e5e5', ...theme.applyStyles('dark', { background: '#1c1c1c' })}\n *\n * @example\n * 1. using with `styled`:\n * ```jsx\n * const Component = styled('div')(({ theme }) => [\n * { background: '#e5e5e5' },\n * theme.applyStyles('dark', {\n * background: '#1c1c1c',\n * color: '#fff',\n * }),\n * ]);\n * ```\n *\n * @example\n * 2. using with `sx` prop:\n * ```jsx\n * [\n * { background: '#e5e5e5' },\n * theme.applyStyles('dark', {\n * background: '#1c1c1c',\n * color: '#fff',\n * }),\n * ]}\n * />\n * ```\n *\n * @example\n * 3. theming a component:\n * ```jsx\n * extendTheme({\n * components: {\n * MuiButton: {\n * styleOverrides: {\n * root: ({ theme }) => [\n * { background: '#e5e5e5' },\n * theme.applyStyles('dark', {\n * background: '#1c1c1c',\n * color: '#fff',\n * }),\n * ],\n * },\n * }\n * }\n * })\n *```\n */\nexport default function applyStyles(key, styles) {\n // @ts-expect-error this is 'any' type\n const theme = this;\n if (theme.vars && typeof theme.getColorSchemeSelector === 'function') {\n // If CssVarsProvider is used as a provider,\n // returns '* :where([data-mui-color-scheme=\"light|dark\"]) &'\n const selector = theme.getColorSchemeSelector(key).replace(/(\\[[^\\]]+\\])/, '*:where($1)');\n return {\n [selector]: styles\n };\n }\n if (theme.palette.mode === key) {\n return styles;\n }\n return {};\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"breakpoints\", \"palette\", \"spacing\", \"shape\"];\nimport deepmerge from '@mui/utils/deepmerge';\nimport createBreakpoints from './createBreakpoints';\nimport shape from './shape';\nimport createSpacing from './createSpacing';\nimport styleFunctionSx from '../styleFunctionSx/styleFunctionSx';\nimport defaultSxConfig from '../styleFunctionSx/defaultSxConfig';\nimport applyStyles from './applyStyles';\nfunction createTheme(options = {}, ...args) {\n const {\n breakpoints: breakpointsInput = {},\n palette: paletteInput = {},\n spacing: spacingInput,\n shape: shapeInput = {}\n } = options,\n other = _objectWithoutPropertiesLoose(options, _excluded);\n const breakpoints = createBreakpoints(breakpointsInput);\n const spacing = createSpacing(spacingInput);\n let muiTheme = deepmerge({\n breakpoints,\n direction: 'ltr',\n components: {},\n // Inject component definitions.\n palette: _extends({\n mode: 'light'\n }, paletteInput),\n spacing,\n shape: _extends({}, shape, shapeInput)\n }, other);\n muiTheme.applyStyles = applyStyles;\n muiTheme = args.reduce((acc, argument) => deepmerge(acc, argument), muiTheme);\n muiTheme.unstable_sxConfig = _extends({}, defaultSxConfig, other == null ? void 0 : other.unstable_sxConfig);\n muiTheme.unstable_sx = function sx(props) {\n return styleFunctionSx({\n sx: props,\n theme: this\n });\n };\n return muiTheme;\n}\nexport default createTheme;","'use client';\n\nimport * as React from 'react';\nimport { ThemeContext } from '@mui/styled-engine';\nfunction isObjectEmpty(obj) {\n return Object.keys(obj).length === 0;\n}\nfunction useTheme(defaultTheme = null) {\n const contextTheme = React.useContext(ThemeContext);\n return !contextTheme || isObjectEmpty(contextTheme) ? defaultTheme : contextTheme;\n}\nexport default useTheme;","'use client';\n\nimport createTheme from './createTheme';\nimport useThemeWithoutDefault from './useThemeWithoutDefault';\nexport const systemDefaultTheme = createTheme();\nfunction useTheme(defaultTheme = systemDefaultTheme) {\n return useThemeWithoutDefault(defaultTheme);\n}\nexport default useTheme;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"ownerState\"],\n _excluded2 = [\"variants\"],\n _excluded3 = [\"name\", \"slot\", \"skipVariantsResolver\", \"skipSx\", \"overridesResolver\"];\n/* eslint-disable no-underscore-dangle */\nimport styledEngineStyled, { internal_processStyles as processStyles } from '@mui/styled-engine';\nimport { isPlainObject } from '@mui/utils/deepmerge';\nimport capitalize from '@mui/utils/capitalize';\nimport getDisplayName from '@mui/utils/getDisplayName';\nimport createTheme from './createTheme';\nimport styleFunctionSx from './styleFunctionSx';\nfunction isEmpty(obj) {\n return Object.keys(obj).length === 0;\n}\n\n// https://github.com/emotion-js/emotion/blob/26ded6109fcd8ca9875cc2ce4564fee678a3f3c5/packages/styled/src/utils.js#L40\nfunction isStringTag(tag) {\n return typeof tag === 'string' &&\n // 96 is one less than the char code\n // for \"a\" so this is checking that\n // it's a lowercase character\n tag.charCodeAt(0) > 96;\n}\n\n// Update /system/styled/#api in case if this changes\nexport function shouldForwardProp(prop) {\n return prop !== 'ownerState' && prop !== 'theme' && prop !== 'sx' && prop !== 'as';\n}\nexport const systemDefaultTheme = createTheme();\nconst lowercaseFirstLetter = string => {\n if (!string) {\n return string;\n }\n return string.charAt(0).toLowerCase() + string.slice(1);\n};\nfunction resolveTheme({\n defaultTheme,\n theme,\n themeId\n}) {\n return isEmpty(theme) ? defaultTheme : theme[themeId] || theme;\n}\nfunction defaultOverridesResolver(slot) {\n if (!slot) {\n return null;\n }\n return (props, styles) => styles[slot];\n}\nfunction processStyleArg(callableStyle, _ref) {\n let {\n ownerState\n } = _ref,\n props = _objectWithoutPropertiesLoose(_ref, _excluded);\n const resolvedStylesArg = typeof callableStyle === 'function' ? callableStyle(_extends({\n ownerState\n }, props)) : callableStyle;\n if (Array.isArray(resolvedStylesArg)) {\n return resolvedStylesArg.flatMap(resolvedStyle => processStyleArg(resolvedStyle, _extends({\n ownerState\n }, props)));\n }\n if (!!resolvedStylesArg && typeof resolvedStylesArg === 'object' && Array.isArray(resolvedStylesArg.variants)) {\n const {\n variants = []\n } = resolvedStylesArg,\n otherStyles = _objectWithoutPropertiesLoose(resolvedStylesArg, _excluded2);\n let result = otherStyles;\n variants.forEach(variant => {\n let isMatch = true;\n if (typeof variant.props === 'function') {\n isMatch = variant.props(_extends({\n ownerState\n }, props, ownerState));\n } else {\n Object.keys(variant.props).forEach(key => {\n if ((ownerState == null ? void 0 : ownerState[key]) !== variant.props[key] && props[key] !== variant.props[key]) {\n isMatch = false;\n }\n });\n }\n if (isMatch) {\n if (!Array.isArray(result)) {\n result = [result];\n }\n result.push(typeof variant.style === 'function' ? variant.style(_extends({\n ownerState\n }, props, ownerState)) : variant.style);\n }\n });\n return result;\n }\n return resolvedStylesArg;\n}\nexport default function createStyled(input = {}) {\n const {\n themeId,\n defaultTheme = systemDefaultTheme,\n rootShouldForwardProp = shouldForwardProp,\n slotShouldForwardProp = shouldForwardProp\n } = input;\n const systemSx = props => {\n return styleFunctionSx(_extends({}, props, {\n theme: resolveTheme(_extends({}, props, {\n defaultTheme,\n themeId\n }))\n }));\n };\n systemSx.__mui_systemSx = true;\n return (tag, inputOptions = {}) => {\n // Filter out the `sx` style function from the previous styled component to prevent unnecessary styles generated by the composite components.\n processStyles(tag, styles => styles.filter(style => !(style != null && style.__mui_systemSx)));\n const {\n name: componentName,\n slot: componentSlot,\n skipVariantsResolver: inputSkipVariantsResolver,\n skipSx: inputSkipSx,\n // TODO v6: remove `lowercaseFirstLetter()` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n overridesResolver = defaultOverridesResolver(lowercaseFirstLetter(componentSlot))\n } = inputOptions,\n options = _objectWithoutPropertiesLoose(inputOptions, _excluded3);\n\n // if skipVariantsResolver option is defined, take the value, otherwise, true for root and false for other slots.\n const skipVariantsResolver = inputSkipVariantsResolver !== undefined ? inputSkipVariantsResolver :\n // TODO v6: remove `Root` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n componentSlot && componentSlot !== 'Root' && componentSlot !== 'root' || false;\n const skipSx = inputSkipSx || false;\n let label;\n if (process.env.NODE_ENV !== 'production') {\n if (componentName) {\n // TODO v6: remove `lowercaseFirstLetter()` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n label = `${componentName}-${lowercaseFirstLetter(componentSlot || 'Root')}`;\n }\n }\n let shouldForwardPropOption = shouldForwardProp;\n\n // TODO v6: remove `Root` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n if (componentSlot === 'Root' || componentSlot === 'root') {\n shouldForwardPropOption = rootShouldForwardProp;\n } else if (componentSlot) {\n // any other slot specified\n shouldForwardPropOption = slotShouldForwardProp;\n } else if (isStringTag(tag)) {\n // for string (html) tag, preserve the behavior in emotion & styled-components.\n shouldForwardPropOption = undefined;\n }\n const defaultStyledResolver = styledEngineStyled(tag, _extends({\n shouldForwardProp: shouldForwardPropOption,\n label\n }, options));\n const transformStyleArg = stylesArg => {\n // On the server Emotion doesn't use React.forwardRef for creating components, so the created\n // component stays as a function. This condition makes sure that we do not interpolate functions\n // which are basically components used as a selectors.\n if (typeof stylesArg === 'function' && stylesArg.__emotion_real !== stylesArg || isPlainObject(stylesArg)) {\n return props => processStyleArg(stylesArg, _extends({}, props, {\n theme: resolveTheme({\n theme: props.theme,\n defaultTheme,\n themeId\n })\n }));\n }\n return stylesArg;\n };\n const muiStyledResolver = (styleArg, ...expressions) => {\n let transformedStyleArg = transformStyleArg(styleArg);\n const expressionsWithDefaultTheme = expressions ? expressions.map(transformStyleArg) : [];\n if (componentName && overridesResolver) {\n expressionsWithDefaultTheme.push(props => {\n const theme = resolveTheme(_extends({}, props, {\n defaultTheme,\n themeId\n }));\n if (!theme.components || !theme.components[componentName] || !theme.components[componentName].styleOverrides) {\n return null;\n }\n const styleOverrides = theme.components[componentName].styleOverrides;\n const resolvedStyleOverrides = {};\n // TODO: v7 remove iteration and use `resolveStyleArg(styleOverrides[slot])` directly\n Object.entries(styleOverrides).forEach(([slotKey, slotStyle]) => {\n resolvedStyleOverrides[slotKey] = processStyleArg(slotStyle, _extends({}, props, {\n theme\n }));\n });\n return overridesResolver(props, resolvedStyleOverrides);\n });\n }\n if (componentName && !skipVariantsResolver) {\n expressionsWithDefaultTheme.push(props => {\n var _theme$components;\n const theme = resolveTheme(_extends({}, props, {\n defaultTheme,\n themeId\n }));\n const themeVariants = theme == null || (_theme$components = theme.components) == null || (_theme$components = _theme$components[componentName]) == null ? void 0 : _theme$components.variants;\n return processStyleArg({\n variants: themeVariants\n }, _extends({}, props, {\n theme\n }));\n });\n }\n if (!skipSx) {\n expressionsWithDefaultTheme.push(systemSx);\n }\n const numOfCustomFnsApplied = expressionsWithDefaultTheme.length - expressions.length;\n if (Array.isArray(styleArg) && numOfCustomFnsApplied > 0) {\n const placeholders = new Array(numOfCustomFnsApplied).fill('');\n // If the type is array, than we need to add placeholders in the template for the overrides, variants and the sx styles.\n transformedStyleArg = [...styleArg, ...placeholders];\n transformedStyleArg.raw = [...styleArg.raw, ...placeholders];\n }\n const Component = defaultStyledResolver(transformedStyleArg, ...expressionsWithDefaultTheme);\n if (process.env.NODE_ENV !== 'production') {\n let displayName;\n if (componentName) {\n displayName = `${componentName}${capitalize(componentSlot || '')}`;\n }\n if (displayName === undefined) {\n displayName = `Styled(${getDisplayName(tag)})`;\n }\n Component.displayName = displayName;\n }\n if (tag.muiName) {\n Component.muiName = tag.muiName;\n }\n return Component;\n };\n if (defaultStyledResolver.withConfig) {\n muiStyledResolver.withConfig = defaultStyledResolver.withConfig;\n }\n return muiStyledResolver;\n };\n}","import resolveProps from '@mui/utils/resolveProps';\nexport default function getThemeProps(params) {\n const {\n theme,\n name,\n props\n } = params;\n if (!theme || !theme.components || !theme.components[name] || !theme.components[name].defaultProps) {\n return props;\n }\n return resolveProps(theme.components[name].defaultProps, props);\n}","'use client';\n\nimport getThemeProps from './getThemeProps';\nimport useTheme from '../useTheme';\nexport default function useThemeProps({\n props,\n name,\n defaultTheme,\n themeId\n}) {\n let theme = useTheme(defaultTheme);\n if (themeId) {\n theme = theme[themeId] || theme;\n }\n const mergedProps = getThemeProps({\n theme,\n name,\n props\n });\n return mergedProps;\n}","import _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\n/* eslint-disable @typescript-eslint/naming-convention */\nimport clamp from '@mui/utils/clamp';\n/**\n * Returns a number whose value is limited to the given range.\n * @param {number} value The value to be clamped\n * @param {number} min The lower boundary of the output range\n * @param {number} max The upper boundary of the output range\n * @returns {number} A number in the range [min, max]\n */\nfunction clampWrapper(value, min = 0, max = 1) {\n if (process.env.NODE_ENV !== 'production') {\n if (value < min || value > max) {\n console.error(`MUI: The value provided ${value} is out of range [${min}, ${max}].`);\n }\n }\n return clamp(value, min, max);\n}\n\n/**\n * Converts a color from CSS hex format to CSS rgb format.\n * @param {string} color - Hex color, i.e. #nnn or #nnnnnn\n * @returns {string} A CSS rgb color string\n */\nexport function hexToRgb(color) {\n color = color.slice(1);\n const re = new RegExp(`.{1,${color.length >= 6 ? 2 : 1}}`, 'g');\n let colors = color.match(re);\n if (colors && colors[0].length === 1) {\n colors = colors.map(n => n + n);\n }\n return colors ? `rgb${colors.length === 4 ? 'a' : ''}(${colors.map((n, index) => {\n return index < 3 ? parseInt(n, 16) : Math.round(parseInt(n, 16) / 255 * 1000) / 1000;\n }).join(', ')})` : '';\n}\nfunction intToHex(int) {\n const hex = int.toString(16);\n return hex.length === 1 ? `0${hex}` : hex;\n}\n\n/**\n * Returns an object with the type and values of a color.\n *\n * Note: Does not support rgb % values.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @returns {object} - A MUI color object: {type: string, values: number[]}\n */\nexport function decomposeColor(color) {\n // Idempotent\n if (color.type) {\n return color;\n }\n if (color.charAt(0) === '#') {\n return decomposeColor(hexToRgb(color));\n }\n const marker = color.indexOf('(');\n const type = color.substring(0, marker);\n if (['rgb', 'rgba', 'hsl', 'hsla', 'color'].indexOf(type) === -1) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: Unsupported \\`${color}\\` color.\nThe following formats are supported: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color().` : _formatMuiErrorMessage(9, color));\n }\n let values = color.substring(marker + 1, color.length - 1);\n let colorSpace;\n if (type === 'color') {\n values = values.split(' ');\n colorSpace = values.shift();\n if (values.length === 4 && values[3].charAt(0) === '/') {\n values[3] = values[3].slice(1);\n }\n if (['srgb', 'display-p3', 'a98-rgb', 'prophoto-rgb', 'rec-2020'].indexOf(colorSpace) === -1) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: unsupported \\`${colorSpace}\\` color space.\nThe following color spaces are supported: srgb, display-p3, a98-rgb, prophoto-rgb, rec-2020.` : _formatMuiErrorMessage(10, colorSpace));\n }\n } else {\n values = values.split(',');\n }\n values = values.map(value => parseFloat(value));\n return {\n type,\n values,\n colorSpace\n };\n}\n\n/**\n * Returns a channel created from the input color.\n *\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @returns {string} - The channel for the color, that can be used in rgba or hsla colors\n */\nexport const colorChannel = color => {\n const decomposedColor = decomposeColor(color);\n return decomposedColor.values.slice(0, 3).map((val, idx) => decomposedColor.type.indexOf('hsl') !== -1 && idx !== 0 ? `${val}%` : val).join(' ');\n};\nexport const private_safeColorChannel = (color, warning) => {\n try {\n return colorChannel(color);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n};\n\n/**\n * Converts a color object with type and values to a string.\n * @param {object} color - Decomposed color\n * @param {string} color.type - One of: 'rgb', 'rgba', 'hsl', 'hsla', 'color'\n * @param {array} color.values - [n,n,n] or [n,n,n,n]\n * @returns {string} A CSS color string\n */\nexport function recomposeColor(color) {\n const {\n type,\n colorSpace\n } = color;\n let {\n values\n } = color;\n if (type.indexOf('rgb') !== -1) {\n // Only convert the first 3 values to int (i.e. not alpha)\n values = values.map((n, i) => i < 3 ? parseInt(n, 10) : n);\n } else if (type.indexOf('hsl') !== -1) {\n values[1] = `${values[1]}%`;\n values[2] = `${values[2]}%`;\n }\n if (type.indexOf('color') !== -1) {\n values = `${colorSpace} ${values.join(' ')}`;\n } else {\n values = `${values.join(', ')}`;\n }\n return `${type}(${values})`;\n}\n\n/**\n * Converts a color from CSS rgb format to CSS hex format.\n * @param {string} color - RGB color, i.e. rgb(n, n, n)\n * @returns {string} A CSS rgb color string, i.e. #nnnnnn\n */\nexport function rgbToHex(color) {\n // Idempotent\n if (color.indexOf('#') === 0) {\n return color;\n }\n const {\n values\n } = decomposeColor(color);\n return `#${values.map((n, i) => intToHex(i === 3 ? Math.round(255 * n) : n)).join('')}`;\n}\n\n/**\n * Converts a color from hsl format to rgb format.\n * @param {string} color - HSL color values\n * @returns {string} rgb color values\n */\nexport function hslToRgb(color) {\n color = decomposeColor(color);\n const {\n values\n } = color;\n const h = values[0];\n const s = values[1] / 100;\n const l = values[2] / 100;\n const a = s * Math.min(l, 1 - l);\n const f = (n, k = (n + h / 30) % 12) => l - a * Math.max(Math.min(k - 3, 9 - k, 1), -1);\n let type = 'rgb';\n const rgb = [Math.round(f(0) * 255), Math.round(f(8) * 255), Math.round(f(4) * 255)];\n if (color.type === 'hsla') {\n type += 'a';\n rgb.push(values[3]);\n }\n return recomposeColor({\n type,\n values: rgb\n });\n}\n/**\n * The relative brightness of any point in a color space,\n * normalized to 0 for darkest black and 1 for lightest white.\n *\n * Formula: https://www.w3.org/TR/WCAG20-TECHS/G17.html#G17-tests\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @returns {number} The relative brightness of the color in the range 0 - 1\n */\nexport function getLuminance(color) {\n color = decomposeColor(color);\n let rgb = color.type === 'hsl' || color.type === 'hsla' ? decomposeColor(hslToRgb(color)).values : color.values;\n rgb = rgb.map(val => {\n if (color.type !== 'color') {\n val /= 255; // normalized\n }\n return val <= 0.03928 ? val / 12.92 : ((val + 0.055) / 1.055) ** 2.4;\n });\n\n // Truncate at 3 digits\n return Number((0.2126 * rgb[0] + 0.7152 * rgb[1] + 0.0722 * rgb[2]).toFixed(3));\n}\n\n/**\n * Calculates the contrast ratio between two colors.\n *\n * Formula: https://www.w3.org/TR/WCAG20-TECHS/G17.html#G17-tests\n * @param {string} foreground - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla()\n * @param {string} background - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla()\n * @returns {number} A contrast ratio value in the range 0 - 21.\n */\nexport function getContrastRatio(foreground, background) {\n const lumA = getLuminance(foreground);\n const lumB = getLuminance(background);\n return (Math.max(lumA, lumB) + 0.05) / (Math.min(lumA, lumB) + 0.05);\n}\n\n/**\n * Sets the absolute transparency of a color.\n * Any existing alpha values are overwritten.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} value - value to set the alpha channel to in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function alpha(color, value) {\n color = decomposeColor(color);\n value = clampWrapper(value);\n if (color.type === 'rgb' || color.type === 'hsl') {\n color.type += 'a';\n }\n if (color.type === 'color') {\n color.values[3] = `/${value}`;\n } else {\n color.values[3] = value;\n }\n return recomposeColor(color);\n}\nexport function private_safeAlpha(color, value, warning) {\n try {\n return alpha(color, value);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Darkens a color.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} coefficient - multiplier in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function darken(color, coefficient) {\n color = decomposeColor(color);\n coefficient = clampWrapper(coefficient);\n if (color.type.indexOf('hsl') !== -1) {\n color.values[2] *= 1 - coefficient;\n } else if (color.type.indexOf('rgb') !== -1 || color.type.indexOf('color') !== -1) {\n for (let i = 0; i < 3; i += 1) {\n color.values[i] *= 1 - coefficient;\n }\n }\n return recomposeColor(color);\n}\nexport function private_safeDarken(color, coefficient, warning) {\n try {\n return darken(color, coefficient);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Lightens a color.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} coefficient - multiplier in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function lighten(color, coefficient) {\n color = decomposeColor(color);\n coefficient = clampWrapper(coefficient);\n if (color.type.indexOf('hsl') !== -1) {\n color.values[2] += (100 - color.values[2]) * coefficient;\n } else if (color.type.indexOf('rgb') !== -1) {\n for (let i = 0; i < 3; i += 1) {\n color.values[i] += (255 - color.values[i]) * coefficient;\n }\n } else if (color.type.indexOf('color') !== -1) {\n for (let i = 0; i < 3; i += 1) {\n color.values[i] += (1 - color.values[i]) * coefficient;\n }\n }\n return recomposeColor(color);\n}\nexport function private_safeLighten(color, coefficient, warning) {\n try {\n return lighten(color, coefficient);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Darken or lighten a color, depending on its luminance.\n * Light colors are darkened, dark colors are lightened.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} coefficient=0.15 - multiplier in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function emphasize(color, coefficient = 0.15) {\n return getLuminance(color) > 0.5 ? darken(color, coefficient) : lighten(color, coefficient);\n}\nexport function private_safeEmphasize(color, coefficient, warning) {\n try {\n return emphasize(color, coefficient);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Blend a transparent overlay color with a background color, resulting in a single\n * RGB color.\n * @param {string} background - CSS color\n * @param {string} overlay - CSS color\n * @param {number} opacity - Opacity multiplier in the range 0 - 1\n * @param {number} [gamma=1.0] - Gamma correction factor. For gamma-correct blending, 2.2 is usual.\n */\nexport function blend(background, overlay, opacity, gamma = 1.0) {\n const blendChannel = (b, o) => Math.round((b ** (1 / gamma) * (1 - opacity) + o ** (1 / gamma) * opacity) ** gamma);\n const backgroundColor = decomposeColor(background);\n const overlayColor = decomposeColor(overlay);\n const rgb = [blendChannel(backgroundColor.values[0], overlayColor.values[0]), blendChannel(backgroundColor.values[1], overlayColor.values[1]), blendChannel(backgroundColor.values[2], overlayColor.values[2])];\n return recomposeColor({\n type: 'rgb',\n values: rgb\n });\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nexport default function createMixins(breakpoints, mixins) {\n return _extends({\n toolbar: {\n minHeight: 56,\n [breakpoints.up('xs')]: {\n '@media (orientation: landscape)': {\n minHeight: 48\n }\n },\n [breakpoints.up('sm')]: {\n minHeight: 64\n }\n }\n }, mixins);\n}","const common = {\n black: '#000',\n white: '#fff'\n};\nexport default common;","const grey = {\n 50: '#fafafa',\n 100: '#f5f5f5',\n 200: '#eeeeee',\n 300: '#e0e0e0',\n 400: '#bdbdbd',\n 500: '#9e9e9e',\n 600: '#757575',\n 700: '#616161',\n 800: '#424242',\n 900: '#212121',\n A100: '#f5f5f5',\n A200: '#eeeeee',\n A400: '#bdbdbd',\n A700: '#616161'\n};\nexport default grey;","const purple = {\n 50: '#f3e5f5',\n 100: '#e1bee7',\n 200: '#ce93d8',\n 300: '#ba68c8',\n 400: '#ab47bc',\n 500: '#9c27b0',\n 600: '#8e24aa',\n 700: '#7b1fa2',\n 800: '#6a1b9a',\n 900: '#4a148c',\n A100: '#ea80fc',\n A200: '#e040fb',\n A400: '#d500f9',\n A700: '#aa00ff'\n};\nexport default purple;","const red = {\n 50: '#ffebee',\n 100: '#ffcdd2',\n 200: '#ef9a9a',\n 300: '#e57373',\n 400: '#ef5350',\n 500: '#f44336',\n 600: '#e53935',\n 700: '#d32f2f',\n 800: '#c62828',\n 900: '#b71c1c',\n A100: '#ff8a80',\n A200: '#ff5252',\n A400: '#ff1744',\n A700: '#d50000'\n};\nexport default red;","const orange = {\n 50: '#fff3e0',\n 100: '#ffe0b2',\n 200: '#ffcc80',\n 300: '#ffb74d',\n 400: '#ffa726',\n 500: '#ff9800',\n 600: '#fb8c00',\n 700: '#f57c00',\n 800: '#ef6c00',\n 900: '#e65100',\n A100: '#ffd180',\n A200: '#ffab40',\n A400: '#ff9100',\n A700: '#ff6d00'\n};\nexport default orange;","const blue = {\n 50: '#e3f2fd',\n 100: '#bbdefb',\n 200: '#90caf9',\n 300: '#64b5f6',\n 400: '#42a5f5',\n 500: '#2196f3',\n 600: '#1e88e5',\n 700: '#1976d2',\n 800: '#1565c0',\n 900: '#0d47a1',\n A100: '#82b1ff',\n A200: '#448aff',\n A400: '#2979ff',\n A700: '#2962ff'\n};\nexport default blue;","const lightBlue = {\n 50: '#e1f5fe',\n 100: '#b3e5fc',\n 200: '#81d4fa',\n 300: '#4fc3f7',\n 400: '#29b6f6',\n 500: '#03a9f4',\n 600: '#039be5',\n 700: '#0288d1',\n 800: '#0277bd',\n 900: '#01579b',\n A100: '#80d8ff',\n A200: '#40c4ff',\n A400: '#00b0ff',\n A700: '#0091ea'\n};\nexport default lightBlue;","const green = {\n 50: '#e8f5e9',\n 100: '#c8e6c9',\n 200: '#a5d6a7',\n 300: '#81c784',\n 400: '#66bb6a',\n 500: '#4caf50',\n 600: '#43a047',\n 700: '#388e3c',\n 800: '#2e7d32',\n 900: '#1b5e20',\n A100: '#b9f6ca',\n A200: '#69f0ae',\n A400: '#00e676',\n A700: '#00c853'\n};\nexport default green;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\nconst _excluded = [\"mode\", \"contrastThreshold\", \"tonalOffset\"];\nimport { deepmerge } from '@mui/utils';\nimport { darken, getContrastRatio, lighten } from '@mui/system';\nimport common from '../colors/common';\nimport grey from '../colors/grey';\nimport purple from '../colors/purple';\nimport red from '../colors/red';\nimport orange from '../colors/orange';\nimport blue from '../colors/blue';\nimport lightBlue from '../colors/lightBlue';\nimport green from '../colors/green';\nexport const light = {\n // The colors used to style the text.\n text: {\n // The most important text.\n primary: 'rgba(0, 0, 0, 0.87)',\n // Secondary text.\n secondary: 'rgba(0, 0, 0, 0.6)',\n // Disabled text have even lower visual prominence.\n disabled: 'rgba(0, 0, 0, 0.38)'\n },\n // The color used to divide different elements.\n divider: 'rgba(0, 0, 0, 0.12)',\n // The background colors used to style the surfaces.\n // Consistency between these values is important.\n background: {\n paper: common.white,\n default: common.white\n },\n // The colors used to style the action elements.\n action: {\n // The color of an active action like an icon button.\n active: 'rgba(0, 0, 0, 0.54)',\n // The color of an hovered action.\n hover: 'rgba(0, 0, 0, 0.04)',\n hoverOpacity: 0.04,\n // The color of a selected action.\n selected: 'rgba(0, 0, 0, 0.08)',\n selectedOpacity: 0.08,\n // The color of a disabled action.\n disabled: 'rgba(0, 0, 0, 0.26)',\n // The background color of a disabled action.\n disabledBackground: 'rgba(0, 0, 0, 0.12)',\n disabledOpacity: 0.38,\n focus: 'rgba(0, 0, 0, 0.12)',\n focusOpacity: 0.12,\n activatedOpacity: 0.12\n }\n};\nexport const dark = {\n text: {\n primary: common.white,\n secondary: 'rgba(255, 255, 255, 0.7)',\n disabled: 'rgba(255, 255, 255, 0.5)',\n icon: 'rgba(255, 255, 255, 0.5)'\n },\n divider: 'rgba(255, 255, 255, 0.12)',\n background: {\n paper: '#121212',\n default: '#121212'\n },\n action: {\n active: common.white,\n hover: 'rgba(255, 255, 255, 0.08)',\n hoverOpacity: 0.08,\n selected: 'rgba(255, 255, 255, 0.16)',\n selectedOpacity: 0.16,\n disabled: 'rgba(255, 255, 255, 0.3)',\n disabledBackground: 'rgba(255, 255, 255, 0.12)',\n disabledOpacity: 0.38,\n focus: 'rgba(255, 255, 255, 0.12)',\n focusOpacity: 0.12,\n activatedOpacity: 0.24\n }\n};\nfunction addLightOrDark(intent, direction, shade, tonalOffset) {\n const tonalOffsetLight = tonalOffset.light || tonalOffset;\n const tonalOffsetDark = tonalOffset.dark || tonalOffset * 1.5;\n if (!intent[direction]) {\n if (intent.hasOwnProperty(shade)) {\n intent[direction] = intent[shade];\n } else if (direction === 'light') {\n intent.light = lighten(intent.main, tonalOffsetLight);\n } else if (direction === 'dark') {\n intent.dark = darken(intent.main, tonalOffsetDark);\n }\n }\n}\nfunction getDefaultPrimary(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: blue[200],\n light: blue[50],\n dark: blue[400]\n };\n }\n return {\n main: blue[700],\n light: blue[400],\n dark: blue[800]\n };\n}\nfunction getDefaultSecondary(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: purple[200],\n light: purple[50],\n dark: purple[400]\n };\n }\n return {\n main: purple[500],\n light: purple[300],\n dark: purple[700]\n };\n}\nfunction getDefaultError(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: red[500],\n light: red[300],\n dark: red[700]\n };\n }\n return {\n main: red[700],\n light: red[400],\n dark: red[800]\n };\n}\nfunction getDefaultInfo(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: lightBlue[400],\n light: lightBlue[300],\n dark: lightBlue[700]\n };\n }\n return {\n main: lightBlue[700],\n light: lightBlue[500],\n dark: lightBlue[900]\n };\n}\nfunction getDefaultSuccess(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: green[400],\n light: green[300],\n dark: green[700]\n };\n }\n return {\n main: green[800],\n light: green[500],\n dark: green[900]\n };\n}\nfunction getDefaultWarning(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: orange[400],\n light: orange[300],\n dark: orange[700]\n };\n }\n return {\n main: '#ed6c02',\n // closest to orange[800] that pass 3:1.\n light: orange[500],\n dark: orange[900]\n };\n}\nexport default function createPalette(palette) {\n const {\n mode = 'light',\n contrastThreshold = 3,\n tonalOffset = 0.2\n } = palette,\n other = _objectWithoutPropertiesLoose(palette, _excluded);\n const primary = palette.primary || getDefaultPrimary(mode);\n const secondary = palette.secondary || getDefaultSecondary(mode);\n const error = palette.error || getDefaultError(mode);\n const info = palette.info || getDefaultInfo(mode);\n const success = palette.success || getDefaultSuccess(mode);\n const warning = palette.warning || getDefaultWarning(mode);\n\n // Use the same logic as\n // Bootstrap: https://github.com/twbs/bootstrap/blob/1d6e3710dd447de1a200f29e8fa521f8a0908f70/scss/_functions.scss#L59\n // and material-components-web https://github.com/material-components/material-components-web/blob/ac46b8863c4dab9fc22c4c662dc6bd1b65dd652f/packages/mdc-theme/_functions.scss#L54\n function getContrastText(background) {\n const contrastText = getContrastRatio(background, dark.text.primary) >= contrastThreshold ? dark.text.primary : light.text.primary;\n if (process.env.NODE_ENV !== 'production') {\n const contrast = getContrastRatio(background, contrastText);\n if (contrast < 3) {\n console.error([`MUI: The contrast ratio of ${contrast}:1 for ${contrastText} on ${background}`, 'falls below the WCAG recommended absolute minimum contrast ratio of 3:1.', 'https://www.w3.org/TR/2008/REC-WCAG20-20081211/#visual-audio-contrast-contrast'].join('\\n'));\n }\n }\n return contrastText;\n }\n const augmentColor = ({\n color,\n name,\n mainShade = 500,\n lightShade = 300,\n darkShade = 700\n }) => {\n color = _extends({}, color);\n if (!color.main && color[mainShade]) {\n color.main = color[mainShade];\n }\n if (!color.hasOwnProperty('main')) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: The color${name ? ` (${name})` : ''} provided to augmentColor(color) is invalid.\nThe color object needs to have a \\`main\\` property or a \\`${mainShade}\\` property.` : _formatMuiErrorMessage(11, name ? ` (${name})` : '', mainShade));\n }\n if (typeof color.main !== 'string') {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: The color${name ? ` (${name})` : ''} provided to augmentColor(color) is invalid.\n\\`color.main\\` should be a string, but \\`${JSON.stringify(color.main)}\\` was provided instead.\n\nDid you intend to use one of the following approaches?\n\nimport { green } from \"@mui/material/colors\";\n\nconst theme1 = createTheme({ palette: {\n primary: green,\n} });\n\nconst theme2 = createTheme({ palette: {\n primary: { main: green[500] },\n} });` : _formatMuiErrorMessage(12, name ? ` (${name})` : '', JSON.stringify(color.main)));\n }\n addLightOrDark(color, 'light', lightShade, tonalOffset);\n addLightOrDark(color, 'dark', darkShade, tonalOffset);\n if (!color.contrastText) {\n color.contrastText = getContrastText(color.main);\n }\n return color;\n };\n const modes = {\n dark,\n light\n };\n if (process.env.NODE_ENV !== 'production') {\n if (!modes[mode]) {\n console.error(`MUI: The palette mode \\`${mode}\\` is not supported.`);\n }\n }\n const paletteOutput = deepmerge(_extends({\n // A collection of common colors.\n common: _extends({}, common),\n // prevent mutable object.\n // The palette mode, can be light or dark.\n mode,\n // The colors used to represent primary interface elements for a user.\n primary: augmentColor({\n color: primary,\n name: 'primary'\n }),\n // The colors used to represent secondary interface elements for a user.\n secondary: augmentColor({\n color: secondary,\n name: 'secondary',\n mainShade: 'A400',\n lightShade: 'A200',\n darkShade: 'A700'\n }),\n // The colors used to represent interface elements that the user should be made aware of.\n error: augmentColor({\n color: error,\n name: 'error'\n }),\n // The colors used to represent potentially dangerous actions or important messages.\n warning: augmentColor({\n color: warning,\n name: 'warning'\n }),\n // The colors used to present information to the user that is neutral and not necessarily important.\n info: augmentColor({\n color: info,\n name: 'info'\n }),\n // The colors used to indicate the successful completion of an action that user triggered.\n success: augmentColor({\n color: success,\n name: 'success'\n }),\n // The grey colors.\n grey,\n // Used by `getContrastText()` to maximize the contrast between\n // the background and the text.\n contrastThreshold,\n // Takes a background color and returns the text color that maximizes the contrast.\n getContrastText,\n // Generate a rich color object.\n augmentColor,\n // Used by the functions below to shift a color's luminance by approximately\n // two indexes within its tonal palette.\n // E.g., shift from Red 500 to Red 300 or Red 700.\n tonalOffset\n }, modes[mode]), other);\n return paletteOutput;\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"fontFamily\", \"fontSize\", \"fontWeightLight\", \"fontWeightRegular\", \"fontWeightMedium\", \"fontWeightBold\", \"htmlFontSize\", \"allVariants\", \"pxToRem\"];\nimport { deepmerge } from '@mui/utils';\nfunction round(value) {\n return Math.round(value * 1e5) / 1e5;\n}\nconst caseAllCaps = {\n textTransform: 'uppercase'\n};\nconst defaultFontFamily = '\"Roboto\", \"Helvetica\", \"Arial\", sans-serif';\n\n/**\n * @see @link{https://m2.material.io/design/typography/the-type-system.html}\n * @see @link{https://m2.material.io/design/typography/understanding-typography.html}\n */\nexport default function createTypography(palette, typography) {\n const _ref = typeof typography === 'function' ? typography(palette) : typography,\n {\n fontFamily = defaultFontFamily,\n // The default font size of the Material Specification.\n fontSize = 14,\n // px\n fontWeightLight = 300,\n fontWeightRegular = 400,\n fontWeightMedium = 500,\n fontWeightBold = 700,\n // Tell MUI what's the font-size on the html element.\n // 16px is the default font-size used by browsers.\n htmlFontSize = 16,\n // Apply the CSS properties to all the variants.\n allVariants,\n pxToRem: pxToRem2\n } = _ref,\n other = _objectWithoutPropertiesLoose(_ref, _excluded);\n if (process.env.NODE_ENV !== 'production') {\n if (typeof fontSize !== 'number') {\n console.error('MUI: `fontSize` is required to be a number.');\n }\n if (typeof htmlFontSize !== 'number') {\n console.error('MUI: `htmlFontSize` is required to be a number.');\n }\n }\n const coef = fontSize / 14;\n const pxToRem = pxToRem2 || (size => `${size / htmlFontSize * coef}rem`);\n const buildVariant = (fontWeight, size, lineHeight, letterSpacing, casing) => _extends({\n fontFamily,\n fontWeight,\n fontSize: pxToRem(size),\n // Unitless following https://meyerweb.com/eric/thoughts/2006/02/08/unitless-line-heights/\n lineHeight\n }, fontFamily === defaultFontFamily ? {\n letterSpacing: `${round(letterSpacing / size)}em`\n } : {}, casing, allVariants);\n const variants = {\n h1: buildVariant(fontWeightLight, 96, 1.167, -1.5),\n h2: buildVariant(fontWeightLight, 60, 1.2, -0.5),\n h3: buildVariant(fontWeightRegular, 48, 1.167, 0),\n h4: buildVariant(fontWeightRegular, 34, 1.235, 0.25),\n h5: buildVariant(fontWeightRegular, 24, 1.334, 0),\n h6: buildVariant(fontWeightMedium, 20, 1.6, 0.15),\n subtitle1: buildVariant(fontWeightRegular, 16, 1.75, 0.15),\n subtitle2: buildVariant(fontWeightMedium, 14, 1.57, 0.1),\n body1: buildVariant(fontWeightRegular, 16, 1.5, 0.15),\n body2: buildVariant(fontWeightRegular, 14, 1.43, 0.15),\n button: buildVariant(fontWeightMedium, 14, 1.75, 0.4, caseAllCaps),\n caption: buildVariant(fontWeightRegular, 12, 1.66, 0.4),\n overline: buildVariant(fontWeightRegular, 12, 2.66, 1, caseAllCaps),\n // TODO v6: Remove handling of 'inherit' variant from the theme as it is already handled in Material UI's Typography component. Also, remember to remove the associated types.\n inherit: {\n fontFamily: 'inherit',\n fontWeight: 'inherit',\n fontSize: 'inherit',\n lineHeight: 'inherit',\n letterSpacing: 'inherit'\n }\n };\n return deepmerge(_extends({\n htmlFontSize,\n pxToRem,\n fontFamily,\n fontSize,\n fontWeightLight,\n fontWeightRegular,\n fontWeightMedium,\n fontWeightBold\n }, variants), other, {\n clone: false // No need to clone deep\n });\n}","const shadowKeyUmbraOpacity = 0.2;\nconst shadowKeyPenumbraOpacity = 0.14;\nconst shadowAmbientShadowOpacity = 0.12;\nfunction createShadow(...px) {\n return [`${px[0]}px ${px[1]}px ${px[2]}px ${px[3]}px rgba(0,0,0,${shadowKeyUmbraOpacity})`, `${px[4]}px ${px[5]}px ${px[6]}px ${px[7]}px rgba(0,0,0,${shadowKeyPenumbraOpacity})`, `${px[8]}px ${px[9]}px ${px[10]}px ${px[11]}px rgba(0,0,0,${shadowAmbientShadowOpacity})`].join(',');\n}\n\n// Values from https://github.com/material-components/material-components-web/blob/be8747f94574669cb5e7add1a7c54fa41a89cec7/packages/mdc-elevation/_variables.scss\nconst shadows = ['none', createShadow(0, 2, 1, -1, 0, 1, 1, 0, 0, 1, 3, 0), createShadow(0, 3, 1, -2, 0, 2, 2, 0, 0, 1, 5, 0), createShadow(0, 3, 3, -2, 0, 3, 4, 0, 0, 1, 8, 0), createShadow(0, 2, 4, -1, 0, 4, 5, 0, 0, 1, 10, 0), createShadow(0, 3, 5, -1, 0, 5, 8, 0, 0, 1, 14, 0), createShadow(0, 3, 5, -1, 0, 6, 10, 0, 0, 1, 18, 0), createShadow(0, 4, 5, -2, 0, 7, 10, 1, 0, 2, 16, 1), createShadow(0, 5, 5, -3, 0, 8, 10, 1, 0, 3, 14, 2), createShadow(0, 5, 6, -3, 0, 9, 12, 1, 0, 3, 16, 2), createShadow(0, 6, 6, -3, 0, 10, 14, 1, 0, 4, 18, 3), createShadow(0, 6, 7, -4, 0, 11, 15, 1, 0, 4, 20, 3), createShadow(0, 7, 8, -4, 0, 12, 17, 2, 0, 5, 22, 4), createShadow(0, 7, 8, -4, 0, 13, 19, 2, 0, 5, 24, 4), createShadow(0, 7, 9, -4, 0, 14, 21, 2, 0, 5, 26, 4), createShadow(0, 8, 9, -5, 0, 15, 22, 2, 0, 6, 28, 5), createShadow(0, 8, 10, -5, 0, 16, 24, 2, 0, 6, 30, 5), createShadow(0, 8, 11, -5, 0, 17, 26, 2, 0, 6, 32, 5), createShadow(0, 9, 11, -5, 0, 18, 28, 2, 0, 7, 34, 6), createShadow(0, 9, 12, -6, 0, 19, 29, 2, 0, 7, 36, 6), createShadow(0, 10, 13, -6, 0, 20, 31, 3, 0, 8, 38, 7), createShadow(0, 10, 13, -6, 0, 21, 33, 3, 0, 8, 40, 7), createShadow(0, 10, 14, -6, 0, 22, 35, 3, 0, 8, 42, 7), createShadow(0, 11, 14, -7, 0, 23, 36, 3, 0, 9, 44, 8), createShadow(0, 11, 15, -7, 0, 24, 38, 3, 0, 9, 46, 8)];\nexport default shadows;","import _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nconst _excluded = [\"duration\", \"easing\", \"delay\"];\n// Follow https://material.google.com/motion/duration-easing.html#duration-easing-natural-easing-curves\n// to learn the context in which each easing should be used.\nexport const easing = {\n // This is the most common easing curve.\n easeInOut: 'cubic-bezier(0.4, 0, 0.2, 1)',\n // Objects enter the screen at full velocity from off-screen and\n // slowly decelerate to a resting point.\n easeOut: 'cubic-bezier(0.0, 0, 0.2, 1)',\n // Objects leave the screen at full velocity. They do not decelerate when off-screen.\n easeIn: 'cubic-bezier(0.4, 0, 1, 1)',\n // The sharp curve is used by objects that may return to the screen at any time.\n sharp: 'cubic-bezier(0.4, 0, 0.6, 1)'\n};\n\n// Follow https://m2.material.io/guidelines/motion/duration-easing.html#duration-easing-common-durations\n// to learn when use what timing\nexport const duration = {\n shortest: 150,\n shorter: 200,\n short: 250,\n // most basic recommended timing\n standard: 300,\n // this is to be used in complex animations\n complex: 375,\n // recommended when something is entering screen\n enteringScreen: 225,\n // recommended when something is leaving screen\n leavingScreen: 195\n};\nfunction formatMs(milliseconds) {\n return `${Math.round(milliseconds)}ms`;\n}\nfunction getAutoHeightDuration(height) {\n if (!height) {\n return 0;\n }\n const constant = height / 36;\n\n // https://www.wolframalpha.com/input/?i=(4+%2B+15+*+(x+%2F+36+)+**+0.25+%2B+(x+%2F+36)+%2F+5)+*+10\n return Math.round((4 + 15 * constant ** 0.25 + constant / 5) * 10);\n}\nexport default function createTransitions(inputTransitions) {\n const mergedEasing = _extends({}, easing, inputTransitions.easing);\n const mergedDuration = _extends({}, duration, inputTransitions.duration);\n const create = (props = ['all'], options = {}) => {\n const {\n duration: durationOption = mergedDuration.standard,\n easing: easingOption = mergedEasing.easeInOut,\n delay = 0\n } = options,\n other = _objectWithoutPropertiesLoose(options, _excluded);\n if (process.env.NODE_ENV !== 'production') {\n const isString = value => typeof value === 'string';\n // IE11 support, replace with Number.isNaN\n // eslint-disable-next-line no-restricted-globals\n const isNumber = value => !isNaN(parseFloat(value));\n if (!isString(props) && !Array.isArray(props)) {\n console.error('MUI: Argument \"props\" must be a string or Array.');\n }\n if (!isNumber(durationOption) && !isString(durationOption)) {\n console.error(`MUI: Argument \"duration\" must be a number or a string but found ${durationOption}.`);\n }\n if (!isString(easingOption)) {\n console.error('MUI: Argument \"easing\" must be a string.');\n }\n if (!isNumber(delay) && !isString(delay)) {\n console.error('MUI: Argument \"delay\" must be a number or a string.');\n }\n if (typeof options !== 'object') {\n console.error(['MUI: Secong argument of transition.create must be an object.', \"Arguments should be either `create('prop1', options)` or `create(['prop1', 'prop2'], options)`\"].join('\\n'));\n }\n if (Object.keys(other).length !== 0) {\n console.error(`MUI: Unrecognized argument(s) [${Object.keys(other).join(',')}].`);\n }\n }\n return (Array.isArray(props) ? props : [props]).map(animatedProp => `${animatedProp} ${typeof durationOption === 'string' ? durationOption : formatMs(durationOption)} ${easingOption} ${typeof delay === 'string' ? delay : formatMs(delay)}`).join(',');\n };\n return _extends({\n getAutoHeightDuration,\n create\n }, inputTransitions, {\n easing: mergedEasing,\n duration: mergedDuration\n });\n}","// We need to centralize the zIndex definitions as they work\n// like global values in the browser.\nconst zIndex = {\n mobileStepper: 1000,\n fab: 1050,\n speedDial: 1050,\n appBar: 1100,\n drawer: 1200,\n modal: 1300,\n snackbar: 1400,\n tooltip: 1500\n};\nexport default zIndex;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\nconst _excluded = [\"breakpoints\", \"mixins\", \"spacing\", \"palette\", \"transitions\", \"typography\", \"shape\"];\nimport { deepmerge } from '@mui/utils';\nimport { createTheme as systemCreateTheme, unstable_defaultSxConfig as defaultSxConfig, unstable_styleFunctionSx as styleFunctionSx } from '@mui/system';\nimport generateUtilityClass from '@mui/utils/generateUtilityClass';\nimport createMixins from './createMixins';\nimport createPalette from './createPalette';\nimport createTypography from './createTypography';\nimport shadows from './shadows';\nimport createTransitions from './createTransitions';\nimport zIndex from './zIndex';\nfunction createTheme(options = {}, ...args) {\n const {\n mixins: mixinsInput = {},\n palette: paletteInput = {},\n transitions: transitionsInput = {},\n typography: typographyInput = {}\n } = options,\n other = _objectWithoutPropertiesLoose(options, _excluded);\n if (options.vars) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: \\`vars\\` is a private field used for CSS variables support.\nPlease use another name.` : _formatMuiErrorMessage(18));\n }\n const palette = createPalette(paletteInput);\n const systemTheme = systemCreateTheme(options);\n let muiTheme = deepmerge(systemTheme, {\n mixins: createMixins(systemTheme.breakpoints, mixinsInput),\n palette,\n // Don't use [...shadows] until you've verified its transpiled code is not invoking the iterator protocol.\n shadows: shadows.slice(),\n typography: createTypography(palette, typographyInput),\n transitions: createTransitions(transitionsInput),\n zIndex: _extends({}, zIndex)\n });\n muiTheme = deepmerge(muiTheme, other);\n muiTheme = args.reduce((acc, argument) => deepmerge(acc, argument), muiTheme);\n if (process.env.NODE_ENV !== 'production') {\n // TODO v6: Refactor to use globalStateClassesMapping from @mui/utils once `readOnly` state class is used in Rating component.\n const stateClasses = ['active', 'checked', 'completed', 'disabled', 'error', 'expanded', 'focused', 'focusVisible', 'required', 'selected'];\n const traverse = (node, component) => {\n let key;\n\n // eslint-disable-next-line guard-for-in, no-restricted-syntax\n for (key in node) {\n const child = node[key];\n if (stateClasses.indexOf(key) !== -1 && Object.keys(child).length > 0) {\n if (process.env.NODE_ENV !== 'production') {\n const stateClass = generateUtilityClass('', key);\n console.error([`MUI: The \\`${component}\\` component increases ` + `the CSS specificity of the \\`${key}\\` internal state.`, 'You can not override it like this: ', JSON.stringify(node, null, 2), '', `Instead, you need to use the '&.${stateClass}' syntax:`, JSON.stringify({\n root: {\n [`&.${stateClass}`]: child\n }\n }, null, 2), '', 'https://mui.com/r/state-classes-guide'].join('\\n'));\n }\n // Remove the style to prevent global conflicts.\n node[key] = {};\n }\n }\n };\n Object.keys(muiTheme.components).forEach(component => {\n const styleOverrides = muiTheme.components[component].styleOverrides;\n if (styleOverrides && component.indexOf('Mui') === 0) {\n traverse(styleOverrides, component);\n }\n });\n }\n muiTheme.unstable_sxConfig = _extends({}, defaultSxConfig, other == null ? void 0 : other.unstable_sxConfig);\n muiTheme.unstable_sx = function sx(props) {\n return styleFunctionSx({\n sx: props,\n theme: this\n });\n };\n return muiTheme;\n}\nlet warnedOnce = false;\nexport function createMuiTheme(...args) {\n if (process.env.NODE_ENV !== 'production') {\n if (!warnedOnce) {\n warnedOnce = true;\n console.error(['MUI: the createMuiTheme function was renamed to createTheme.', '', \"You should use `import { createTheme } from '@mui/material/styles'`\"].join('\\n'));\n }\n }\n return createTheme(...args);\n}\nexport default createTheme;","'use client';\n\nimport createTheme from './createTheme';\nconst defaultTheme = createTheme();\nexport default defaultTheme;","export default '$$material';","'use client';\n\nimport { useThemeProps as systemUseThemeProps } from '@mui/system';\nimport defaultTheme from './defaultTheme';\nimport THEME_ID from './identifier';\nexport default function useThemeProps({\n props,\n name\n}) {\n return systemUseThemeProps({\n props,\n name,\n defaultTheme,\n themeId: THEME_ID\n });\n}","'use client';\n\nimport { createStyled, shouldForwardProp } from '@mui/system';\nimport defaultTheme from './defaultTheme';\nimport THEME_ID from './identifier';\nexport const rootShouldForwardProp = prop => shouldForwardProp(prop) && prop !== 'classes';\nexport const slotShouldForwardProp = shouldForwardProp;\nconst styled = createStyled({\n themeId: THEME_ID,\n defaultTheme,\n rootShouldForwardProp\n});\nexport default styled;","import generateUtilityClasses from '@mui/utils/generateUtilityClasses';\nimport generateUtilityClass from '@mui/utils/generateUtilityClass';\nexport function getSvgIconUtilityClass(slot) {\n return generateUtilityClass('MuiSvgIcon', slot);\n}\nconst svgIconClasses = generateUtilityClasses('MuiSvgIcon', ['root', 'colorPrimary', 'colorSecondary', 'colorAction', 'colorError', 'colorDisabled', 'fontSizeInherit', 'fontSizeSmall', 'fontSizeMedium', 'fontSizeLarge']);\nexport default svgIconClasses;","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"children\", \"className\", \"color\", \"component\", \"fontSize\", \"htmlColor\", \"inheritViewBox\", \"titleAccess\", \"viewBox\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport clsx from 'clsx';\nimport { unstable_composeClasses as composeClasses } from '@mui/base/composeClasses';\nimport capitalize from '../utils/capitalize';\nimport useThemeProps from '../styles/useThemeProps';\nimport styled from '../styles/styled';\nimport { getSvgIconUtilityClass } from './svgIconClasses';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nimport { jsxs as _jsxs } from \"react/jsx-runtime\";\nconst useUtilityClasses = ownerState => {\n const {\n color,\n fontSize,\n classes\n } = ownerState;\n const slots = {\n root: ['root', color !== 'inherit' && `color${capitalize(color)}`, `fontSize${capitalize(fontSize)}`]\n };\n return composeClasses(slots, getSvgIconUtilityClass, classes);\n};\nconst SvgIconRoot = styled('svg', {\n name: 'MuiSvgIcon',\n slot: 'Root',\n overridesResolver: (props, styles) => {\n const {\n ownerState\n } = props;\n return [styles.root, ownerState.color !== 'inherit' && styles[`color${capitalize(ownerState.color)}`], styles[`fontSize${capitalize(ownerState.fontSize)}`]];\n }\n})(({\n theme,\n ownerState\n}) => {\n var _theme$transitions, _theme$transitions$cr, _theme$transitions2, _theme$typography, _theme$typography$pxT, _theme$typography2, _theme$typography2$px, _theme$typography3, _theme$typography3$px, _palette$ownerState$c, _palette, _palette2, _palette3;\n return {\n userSelect: 'none',\n width: '1em',\n height: '1em',\n display: 'inline-block',\n // the will define the property that has `currentColor`\n // e.g. heroicons uses fill=\"none\" and stroke=\"currentColor\"\n fill: ownerState.hasSvgAsChild ? undefined : 'currentColor',\n flexShrink: 0,\n transition: (_theme$transitions = theme.transitions) == null || (_theme$transitions$cr = _theme$transitions.create) == null ? void 0 : _theme$transitions$cr.call(_theme$transitions, 'fill', {\n duration: (_theme$transitions2 = theme.transitions) == null || (_theme$transitions2 = _theme$transitions2.duration) == null ? void 0 : _theme$transitions2.shorter\n }),\n fontSize: {\n inherit: 'inherit',\n small: ((_theme$typography = theme.typography) == null || (_theme$typography$pxT = _theme$typography.pxToRem) == null ? void 0 : _theme$typography$pxT.call(_theme$typography, 20)) || '1.25rem',\n medium: ((_theme$typography2 = theme.typography) == null || (_theme$typography2$px = _theme$typography2.pxToRem) == null ? void 0 : _theme$typography2$px.call(_theme$typography2, 24)) || '1.5rem',\n large: ((_theme$typography3 = theme.typography) == null || (_theme$typography3$px = _theme$typography3.pxToRem) == null ? void 0 : _theme$typography3$px.call(_theme$typography3, 35)) || '2.1875rem'\n }[ownerState.fontSize],\n // TODO v5 deprecate, v6 remove for sx\n color: (_palette$ownerState$c = (_palette = (theme.vars || theme).palette) == null || (_palette = _palette[ownerState.color]) == null ? void 0 : _palette.main) != null ? _palette$ownerState$c : {\n action: (_palette2 = (theme.vars || theme).palette) == null || (_palette2 = _palette2.action) == null ? void 0 : _palette2.active,\n disabled: (_palette3 = (theme.vars || theme).palette) == null || (_palette3 = _palette3.action) == null ? void 0 : _palette3.disabled,\n inherit: undefined\n }[ownerState.color]\n };\n});\nconst SvgIcon = /*#__PURE__*/React.forwardRef(function SvgIcon(inProps, ref) {\n const props = useThemeProps({\n props: inProps,\n name: 'MuiSvgIcon'\n });\n const {\n children,\n className,\n color = 'inherit',\n component = 'svg',\n fontSize = 'medium',\n htmlColor,\n inheritViewBox = false,\n titleAccess,\n viewBox = '0 0 24 24'\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const hasSvgAsChild = /*#__PURE__*/React.isValidElement(children) && children.type === 'svg';\n const ownerState = _extends({}, props, {\n color,\n component,\n fontSize,\n instanceFontSize: inProps.fontSize,\n inheritViewBox,\n viewBox,\n hasSvgAsChild\n });\n const more = {};\n if (!inheritViewBox) {\n more.viewBox = viewBox;\n }\n const classes = useUtilityClasses(ownerState);\n return /*#__PURE__*/_jsxs(SvgIconRoot, _extends({\n as: component,\n className: clsx(classes.root, className),\n focusable: \"false\",\n color: htmlColor,\n \"aria-hidden\": titleAccess ? undefined : true,\n role: titleAccess ? 'img' : undefined,\n ref: ref\n }, more, other, hasSvgAsChild && children.props, {\n ownerState: ownerState,\n children: [hasSvgAsChild ? children.props.children : children, titleAccess ? /*#__PURE__*/_jsx(\"title\", {\n children: titleAccess\n }) : null]\n }));\n});\nprocess.env.NODE_ENV !== \"production\" ? SvgIcon.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the d.ts file and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * Node passed into the SVG element.\n */\n children: PropTypes.node,\n /**\n * Override or extend the styles applied to the component.\n */\n classes: PropTypes.object,\n /**\n * @ignore\n */\n className: PropTypes.string,\n /**\n * The color of the component.\n * It supports both default and custom theme colors, which can be added as shown in the\n * [palette customization guide](https://mui.com/material-ui/customization/palette/#custom-colors).\n * You can use the `htmlColor` prop to apply a color attribute to the SVG element.\n * @default 'inherit'\n */\n color: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.oneOf(['inherit', 'action', 'disabled', 'primary', 'secondary', 'error', 'info', 'success', 'warning']), PropTypes.string]),\n /**\n * The component used for the root node.\n * Either a string to use a HTML element or a component.\n */\n component: PropTypes.elementType,\n /**\n * The fontSize applied to the icon. Defaults to 24px, but can be configure to inherit font size.\n * @default 'medium'\n */\n fontSize: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.oneOf(['inherit', 'large', 'medium', 'small']), PropTypes.string]),\n /**\n * Applies a color attribute to the SVG element.\n */\n htmlColor: PropTypes.string,\n /**\n * If `true`, the root node will inherit the custom `component`'s viewBox and the `viewBox`\n * prop will be ignored.\n * Useful when you want to reference a custom `component` and have `SvgIcon` pass that\n * `component`'s viewBox to the root node.\n * @default false\n */\n inheritViewBox: PropTypes.bool,\n /**\n * The shape-rendering attribute. The behavior of the different options is described on the\n * [MDN Web Docs](https://developer.mozilla.org/en-US/docs/Web/SVG/Attribute/shape-rendering).\n * If you are having issues with blurry icons you should investigate this prop.\n */\n shapeRendering: PropTypes.string,\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Provides a human-readable title for the element that contains it.\n * https://www.w3.org/TR/SVG-access/#Equivalent\n */\n titleAccess: PropTypes.string,\n /**\n * Allows you to redefine what the coordinates without units mean inside an SVG element.\n * For example, if the SVG element is 500 (width) by 200 (height),\n * and you pass viewBox=\"0 0 50 20\",\n * this means that the coordinates inside the SVG will go from the top left corner (0,0)\n * to bottom right (50,20) and each unit will be worth 10px.\n * @default '0 0 24 24'\n */\n viewBox: PropTypes.string\n} : void 0;\nSvgIcon.muiName = 'SvgIcon';\nexport default SvgIcon;","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport * as React from 'react';\nimport SvgIcon from '../SvgIcon';\n\n/**\n * Private module reserved for @mui packages.\n */\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nexport default function createSvgIcon(path, displayName) {\n function Component(props, ref) {\n return /*#__PURE__*/_jsx(SvgIcon, _extends({\n \"data-testid\": `${displayName}Icon`,\n ref: ref\n }, props, {\n children: path\n }));\n }\n if (process.env.NODE_ENV !== 'production') {\n // Need to set `displayName` on the inner component for React.memo.\n // React prior to 16.14 ignores `displayName` on the wrapper.\n Component.displayName = `${displayName}Icon`;\n }\n Component.muiName = SvgIcon.muiName;\n return /*#__PURE__*/React.memo( /*#__PURE__*/React.forwardRef(Component));\n}","'use client';\n\nimport { unstable_ClassNameGenerator as ClassNameGenerator } from '@mui/base/ClassNameGenerator';\nexport { default as capitalize } from './capitalize';\nexport { default as createChainedFunction } from './createChainedFunction';\nexport { default as createSvgIcon } from './createSvgIcon';\nexport { default as debounce } from './debounce';\nexport { default as deprecatedPropType } from './deprecatedPropType';\nexport { default as isMuiElement } from './isMuiElement';\nexport { default as ownerDocument } from './ownerDocument';\nexport { default as ownerWindow } from './ownerWindow';\nexport { default as requirePropFactory } from './requirePropFactory';\nexport { default as setRef } from './setRef';\nexport { default as unstable_useEnhancedEffect } from './useEnhancedEffect';\nexport { default as unstable_useId } from './useId';\nexport { default as unsupportedProp } from './unsupportedProp';\nexport { default as useControlled } from './useControlled';\nexport { default as useEventCallback } from './useEventCallback';\nexport { default as useForkRef } from './useForkRef';\nexport { default as useIsFocusVisible } from './useIsFocusVisible';\n// TODO: remove this export once ClassNameGenerator is stable\n// eslint-disable-next-line @typescript-eslint/naming-convention\nexport const unstable_ClassNameGenerator = {\n configure: generator => {\n if (process.env.NODE_ENV !== 'production') {\n console.warn(['MUI: `ClassNameGenerator` import from `@mui/material/utils` is outdated and might cause unexpected issues.', '', \"You should use `import { unstable_ClassNameGenerator } from '@mui/material/className'` instead\", '', 'The detail of the issue: https://github.com/mui/material-ui/issues/30011#issuecomment-1024993401', '', 'The updated documentation: https://mui.com/guides/classname-generator/'].join('\\n'));\n }\n ClassNameGenerator.configure(generator);\n }\n};","\"use strict\";\n'use client';\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nObject.defineProperty(exports, \"default\", {\n enumerable: true,\n get: function () {\n return _utils.createSvgIcon;\n }\n});\nvar _utils = require(\"@mui/material/utils\");","\"use strict\";\n\"use client\";\n\nvar _interopRequireDefault = require(\"@babel/runtime/helpers/interopRequireDefault\");\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = void 0;\nvar _createSvgIcon = _interopRequireDefault(require(\"./utils/createSvgIcon\"));\nvar _jsxRuntime = require(\"react/jsx-runtime\");\nvar _default = exports.default = (0, _createSvgIcon.default)( /*#__PURE__*/(0, _jsxRuntime.jsx)(\"path\", {\n d: \"m10 17 5-5-5-5z\"\n}), 'ArrowRight');","/**\n * Determines if a given element is a DOM element name (i.e. not a React component).\n */\nexport function isHostComponent(element) {\n return typeof element === 'string';\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport { isHostComponent } from './isHostComponent';\n\n/**\n * Type of the ownerState based on the type of an element it applies to.\n * This resolves to the provided OwnerState for React components and `undefined` for host components.\n * Falls back to `OwnerState | undefined` when the exact type can't be determined in development time.\n */\n\n/**\n * Appends the ownerState object to the props, merging with the existing one if necessary.\n *\n * @param elementType Type of the element that owns the `existingProps`. If the element is a DOM node or undefined, `ownerState` is not applied.\n * @param otherProps Props of the element.\n * @param ownerState\n */\nexport function appendOwnerState(elementType, otherProps, ownerState) {\n if (elementType === undefined || isHostComponent(elementType)) {\n return otherProps;\n }\n return _extends({}, otherProps, {\n ownerState: _extends({}, otherProps.ownerState, ownerState)\n });\n}","'use client';\n\nimport * as React from 'react';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nconst defaultContextValue = {\n disableDefaultClasses: false\n};\nconst ClassNameConfiguratorContext = /*#__PURE__*/React.createContext(defaultContextValue);\n/**\n * @ignore - internal hook.\n *\n * Wraps the `generateUtilityClass` function and controls how the classes are generated.\n * Currently it only affects whether the classes are applied or not.\n *\n * @returns Function to be called with the `generateUtilityClass` function specific to a component to generate the classes.\n */\nexport function useClassNamesOverride(generateUtilityClass) {\n const {\n disableDefaultClasses\n } = React.useContext(ClassNameConfiguratorContext);\n return slot => {\n if (disableDefaultClasses) {\n return '';\n }\n return generateUtilityClass(slot);\n };\n}\n\n/**\n * Allows to configure the components within to not apply any built-in classes.\n */\nexport function ClassNameConfigurator(props) {\n const {\n disableDefaultClasses,\n children\n } = props;\n const contextValue = React.useMemo(() => ({\n disableDefaultClasses: disableDefaultClasses != null ? disableDefaultClasses : false\n }), [disableDefaultClasses]);\n return /*#__PURE__*/_jsx(ClassNameConfiguratorContext.Provider, {\n value: contextValue,\n children: children\n });\n}","/**\n * Extracts event handlers from a given object.\n * A prop is considered an event handler if it is a function and its name starts with `on`.\n *\n * @param object An object to extract event handlers from.\n * @param excludeKeys An array of keys to exclude from the returned object.\n */\nexport function extractEventHandlers(object, excludeKeys = []) {\n if (object === undefined) {\n return {};\n }\n const result = {};\n Object.keys(object).filter(prop => prop.match(/^on[A-Z]/) && typeof object[prop] === 'function' && !excludeKeys.includes(prop)).forEach(prop => {\n result[prop] = object[prop];\n });\n return result;\n}","/**\n * If `componentProps` is a function, calls it with the provided `ownerState`.\n * Otherwise, just returns `componentProps`.\n */\nexport function resolveComponentProps(componentProps, ownerState, slotState) {\n if (typeof componentProps === 'function') {\n return componentProps(ownerState, slotState);\n }\n return componentProps;\n}","/**\n * Removes event handlers from the given object.\n * A field is considered an event handler if it is a function with a name beginning with `on`.\n *\n * @param object Object to remove event handlers from.\n * @returns Object with event handlers removed.\n */\nexport function omitEventHandlers(object) {\n if (object === undefined) {\n return {};\n }\n const result = {};\n Object.keys(object).filter(prop => !(prop.match(/^on[A-Z]/) && typeof object[prop] === 'function')).forEach(prop => {\n result[prop] = object[prop];\n });\n return result;\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport clsx from 'clsx';\nimport { extractEventHandlers } from './extractEventHandlers';\nimport { omitEventHandlers } from './omitEventHandlers';\n/**\n * Merges the slot component internal props (usually coming from a hook)\n * with the externally provided ones.\n *\n * The merge order is (the latter overrides the former):\n * 1. The internal props (specified as a getter function to work with get*Props hook result)\n * 2. Additional props (specified internally on a Base UI component)\n * 3. External props specified on the owner component. These should only be used on a root slot.\n * 4. External props specified in the `slotProps.*` prop.\n * 5. The `className` prop - combined from all the above.\n * @param parameters\n * @returns\n */\nexport function mergeSlotProps(parameters) {\n const {\n getSlotProps,\n additionalProps,\n externalSlotProps,\n externalForwardedProps,\n className\n } = parameters;\n if (!getSlotProps) {\n // The simpler case - getSlotProps is not defined, so no internal event handlers are defined,\n // so we can simply merge all the props without having to worry about extracting event handlers.\n const joinedClasses = clsx(additionalProps == null ? void 0 : additionalProps.className, className, externalForwardedProps == null ? void 0 : externalForwardedProps.className, externalSlotProps == null ? void 0 : externalSlotProps.className);\n const mergedStyle = _extends({}, additionalProps == null ? void 0 : additionalProps.style, externalForwardedProps == null ? void 0 : externalForwardedProps.style, externalSlotProps == null ? void 0 : externalSlotProps.style);\n const props = _extends({}, additionalProps, externalForwardedProps, externalSlotProps);\n if (joinedClasses.length > 0) {\n props.className = joinedClasses;\n }\n if (Object.keys(mergedStyle).length > 0) {\n props.style = mergedStyle;\n }\n return {\n props,\n internalRef: undefined\n };\n }\n\n // In this case, getSlotProps is responsible for calling the external event handlers.\n // We don't need to include them in the merged props because of this.\n\n const eventHandlers = extractEventHandlers(_extends({}, externalForwardedProps, externalSlotProps));\n const componentsPropsWithoutEventHandlers = omitEventHandlers(externalSlotProps);\n const otherPropsWithoutEventHandlers = omitEventHandlers(externalForwardedProps);\n const internalSlotProps = getSlotProps(eventHandlers);\n\n // The order of classes is important here.\n // Emotion (that we use in libraries consuming Base UI) depends on this order\n // to properly override style. It requires the most important classes to be last\n // (see https://github.com/mui/material-ui/pull/33205) for the related discussion.\n const joinedClasses = clsx(internalSlotProps == null ? void 0 : internalSlotProps.className, additionalProps == null ? void 0 : additionalProps.className, className, externalForwardedProps == null ? void 0 : externalForwardedProps.className, externalSlotProps == null ? void 0 : externalSlotProps.className);\n const mergedStyle = _extends({}, internalSlotProps == null ? void 0 : internalSlotProps.style, additionalProps == null ? void 0 : additionalProps.style, externalForwardedProps == null ? void 0 : externalForwardedProps.style, externalSlotProps == null ? void 0 : externalSlotProps.style);\n const props = _extends({}, internalSlotProps, additionalProps, otherPropsWithoutEventHandlers, componentsPropsWithoutEventHandlers);\n if (joinedClasses.length > 0) {\n props.className = joinedClasses;\n }\n if (Object.keys(mergedStyle).length > 0) {\n props.style = mergedStyle;\n }\n return {\n props,\n internalRef: internalSlotProps.ref\n };\n}","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"elementType\", \"externalSlotProps\", \"ownerState\", \"skipResolvingSlotProps\"];\nimport { unstable_useForkRef as useForkRef } from '@mui/utils';\nimport { appendOwnerState } from './appendOwnerState';\nimport { mergeSlotProps } from './mergeSlotProps';\nimport { resolveComponentProps } from './resolveComponentProps';\n/**\n * @ignore - do not document.\n * Builds the props to be passed into the slot of an unstyled component.\n * It merges the internal props of the component with the ones supplied by the user, allowing to customize the behavior.\n * If the slot component is not a host component, it also merges in the `ownerState`.\n *\n * @param parameters.getSlotProps - A function that returns the props to be passed to the slot component.\n */\nexport function useSlotProps(parameters) {\n var _parameters$additiona;\n const {\n elementType,\n externalSlotProps,\n ownerState,\n skipResolvingSlotProps = false\n } = parameters,\n rest = _objectWithoutPropertiesLoose(parameters, _excluded);\n const resolvedComponentsProps = skipResolvingSlotProps ? {} : resolveComponentProps(externalSlotProps, ownerState);\n const {\n props: mergedProps,\n internalRef\n } = mergeSlotProps(_extends({}, rest, {\n externalSlotProps: resolvedComponentsProps\n }));\n const ref = useForkRef(internalRef, resolvedComponentsProps == null ? void 0 : resolvedComponentsProps.ref, (_parameters$additiona = parameters.additionalProps) == null ? void 0 : _parameters$additiona.ref);\n const props = appendOwnerState(elementType, _extends({}, mergedProps, {\n ref\n }), ownerState);\n return props;\n}","import { globalStateClasses } from '@mui/utils/generateUtilityClass';\nconst GLOBAL_CLASS_PREFIX = 'base';\nfunction buildStateClass(state) {\n return `${GLOBAL_CLASS_PREFIX}--${state}`;\n}\nfunction buildSlotClass(componentName, slot) {\n return `${GLOBAL_CLASS_PREFIX}-${componentName}-${slot}`;\n}\nexport function generateUtilityClass(componentName, slot) {\n const globalStateClass = globalStateClasses[slot];\n return globalStateClass ? buildStateClass(globalStateClass) : buildSlotClass(componentName, slot);\n}\nexport function isGlobalState(slot) {\n return globalStateClasses[slot] !== undefined;\n}","import { generateUtilityClass } from '../generateUtilityClass';\nexport function generateUtilityClasses(componentName, slots) {\n const result = {};\n slots.forEach(slot => {\n result[slot] = generateUtilityClass(componentName, slot);\n });\n return result;\n}","'use client';\n\nimport * as React from 'react';\nimport * as ReactDOM from 'react-dom';\nimport PropTypes from 'prop-types';\nimport { exactProp, HTMLElementType, unstable_useEnhancedEffect as useEnhancedEffect, unstable_useForkRef as useForkRef, unstable_setRef as setRef } from '@mui/utils';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nfunction getContainer(container) {\n return typeof container === 'function' ? container() : container;\n}\n\n/**\n * Portals provide a first-class way to render children into a DOM node\n * that exists outside the DOM hierarchy of the parent component.\n *\n * Demos:\n *\n * - [Portal](https://mui.com/base-ui/react-portal/)\n *\n * API:\n *\n * - [Portal API](https://mui.com/base-ui/react-portal/components-api/#portal)\n */\nconst Portal = /*#__PURE__*/React.forwardRef(function Portal(props, forwardedRef) {\n const {\n children,\n container,\n disablePortal = false\n } = props;\n const [mountNode, setMountNode] = React.useState(null);\n // @ts-expect-error TODO upstream fix\n const handleRef = useForkRef( /*#__PURE__*/React.isValidElement(children) ? children.ref : null, forwardedRef);\n useEnhancedEffect(() => {\n if (!disablePortal) {\n setMountNode(getContainer(container) || document.body);\n }\n }, [container, disablePortal]);\n useEnhancedEffect(() => {\n if (mountNode && !disablePortal) {\n setRef(forwardedRef, mountNode);\n return () => {\n setRef(forwardedRef, null);\n };\n }\n return undefined;\n }, [forwardedRef, mountNode, disablePortal]);\n if (disablePortal) {\n if ( /*#__PURE__*/React.isValidElement(children)) {\n const newProps = {\n ref: handleRef\n };\n return /*#__PURE__*/React.cloneElement(children, newProps);\n }\n return /*#__PURE__*/_jsx(React.Fragment, {\n children: children\n });\n }\n return /*#__PURE__*/_jsx(React.Fragment, {\n children: mountNode ? /*#__PURE__*/ReactDOM.createPortal(children, mountNode) : mountNode\n });\n});\nprocess.env.NODE_ENV !== \"production\" ? Portal.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * The children to render into the `container`.\n */\n children: PropTypes.node,\n /**\n * An HTML element or function that returns one.\n * The `container` will have the portal children appended to it.\n *\n * You can also provide a callback, which is called in a React layout effect.\n * This lets you set the container from a ref, and also makes server-side rendering possible.\n *\n * By default, it uses the body of the top-level document object,\n * so it's simply `document.body` most of the time.\n */\n container: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.func]),\n /**\n * The `children` will be under the DOM hierarchy of the parent component.\n * @default false\n */\n disablePortal: PropTypes.bool\n} : void 0;\nif (process.env.NODE_ENV !== 'production') {\n // eslint-disable-next-line\n Portal['propTypes' + ''] = exactProp(Portal.propTypes);\n}\nexport { Portal };","export var top = 'top';\nexport var bottom = 'bottom';\nexport var right = 'right';\nexport var left = 'left';\nexport var auto = 'auto';\nexport var basePlacements = [top, bottom, right, left];\nexport var start = 'start';\nexport var end = 'end';\nexport var clippingParents = 'clippingParents';\nexport var viewport = 'viewport';\nexport var popper = 'popper';\nexport var reference = 'reference';\nexport var variationPlacements = /*#__PURE__*/basePlacements.reduce(function (acc, placement) {\n return acc.concat([placement + \"-\" + start, placement + \"-\" + end]);\n}, []);\nexport var placements = /*#__PURE__*/[].concat(basePlacements, [auto]).reduce(function (acc, placement) {\n return acc.concat([placement, placement + \"-\" + start, placement + \"-\" + end]);\n}, []); // modifiers that need to read the DOM\n\nexport var beforeRead = 'beforeRead';\nexport var read = 'read';\nexport var afterRead = 'afterRead'; // pure-logic modifiers\n\nexport var beforeMain = 'beforeMain';\nexport var main = 'main';\nexport var afterMain = 'afterMain'; // modifier with the purpose to write to the DOM (or write into a framework state)\n\nexport var beforeWrite = 'beforeWrite';\nexport var write = 'write';\nexport var afterWrite = 'afterWrite';\nexport var modifierPhases = [beforeRead, read, afterRead, beforeMain, main, afterMain, beforeWrite, write, afterWrite];","export default function getNodeName(element) {\n return element ? (element.nodeName || '').toLowerCase() : null;\n}","export default function getWindow(node) {\n if (node == null) {\n return window;\n }\n\n if (node.toString() !== '[object Window]') {\n var ownerDocument = node.ownerDocument;\n return ownerDocument ? ownerDocument.defaultView || window : window;\n }\n\n return node;\n}","import getWindow from \"./getWindow.js\";\n\nfunction isElement(node) {\n var OwnElement = getWindow(node).Element;\n return node instanceof OwnElement || node instanceof Element;\n}\n\nfunction isHTMLElement(node) {\n var OwnElement = getWindow(node).HTMLElement;\n return node instanceof OwnElement || node instanceof HTMLElement;\n}\n\nfunction isShadowRoot(node) {\n // IE 11 has no ShadowRoot\n if (typeof ShadowRoot === 'undefined') {\n return false;\n }\n\n var OwnElement = getWindow(node).ShadowRoot;\n return node instanceof OwnElement || node instanceof ShadowRoot;\n}\n\nexport { isElement, isHTMLElement, isShadowRoot };","import getNodeName from \"../dom-utils/getNodeName.js\";\nimport { isHTMLElement } from \"../dom-utils/instanceOf.js\"; // This modifier takes the styles prepared by the `computeStyles` modifier\n// and applies them to the HTMLElements such as popper and arrow\n\nfunction applyStyles(_ref) {\n var state = _ref.state;\n Object.keys(state.elements).forEach(function (name) {\n var style = state.styles[name] || {};\n var attributes = state.attributes[name] || {};\n var element = state.elements[name]; // arrow is optional + virtual elements\n\n if (!isHTMLElement(element) || !getNodeName(element)) {\n return;\n } // Flow doesn't support to extend this property, but it's the most\n // effective way to apply styles to an HTMLElement\n // $FlowFixMe[cannot-write]\n\n\n Object.assign(element.style, style);\n Object.keys(attributes).forEach(function (name) {\n var value = attributes[name];\n\n if (value === false) {\n element.removeAttribute(name);\n } else {\n element.setAttribute(name, value === true ? '' : value);\n }\n });\n });\n}\n\nfunction effect(_ref2) {\n var state = _ref2.state;\n var initialStyles = {\n popper: {\n position: state.options.strategy,\n left: '0',\n top: '0',\n margin: '0'\n },\n arrow: {\n position: 'absolute'\n },\n reference: {}\n };\n Object.assign(state.elements.popper.style, initialStyles.popper);\n state.styles = initialStyles;\n\n if (state.elements.arrow) {\n Object.assign(state.elements.arrow.style, initialStyles.arrow);\n }\n\n return function () {\n Object.keys(state.elements).forEach(function (name) {\n var element = state.elements[name];\n var attributes = state.attributes[name] || {};\n var styleProperties = Object.keys(state.styles.hasOwnProperty(name) ? state.styles[name] : initialStyles[name]); // Set all values to an empty string to unset them\n\n var style = styleProperties.reduce(function (style, property) {\n style[property] = '';\n return style;\n }, {}); // arrow is optional + virtual elements\n\n if (!isHTMLElement(element) || !getNodeName(element)) {\n return;\n }\n\n Object.assign(element.style, style);\n Object.keys(attributes).forEach(function (attribute) {\n element.removeAttribute(attribute);\n });\n });\n };\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'applyStyles',\n enabled: true,\n phase: 'write',\n fn: applyStyles,\n effect: effect,\n requires: ['computeStyles']\n};","import { auto } from \"../enums.js\";\nexport default function getBasePlacement(placement) {\n return placement.split('-')[0];\n}","export var max = Math.max;\nexport var min = Math.min;\nexport var round = Math.round;","export default function getUAString() {\n var uaData = navigator.userAgentData;\n\n if (uaData != null && uaData.brands && Array.isArray(uaData.brands)) {\n return uaData.brands.map(function (item) {\n return item.brand + \"/\" + item.version;\n }).join(' ');\n }\n\n return navigator.userAgent;\n}","import getUAString from \"../utils/userAgent.js\";\nexport default function isLayoutViewport() {\n return !/^((?!chrome|android).)*safari/i.test(getUAString());\n}","import { isElement, isHTMLElement } from \"./instanceOf.js\";\nimport { round } from \"../utils/math.js\";\nimport getWindow from \"./getWindow.js\";\nimport isLayoutViewport from \"./isLayoutViewport.js\";\nexport default function getBoundingClientRect(element, includeScale, isFixedStrategy) {\n if (includeScale === void 0) {\n includeScale = false;\n }\n\n if (isFixedStrategy === void 0) {\n isFixedStrategy = false;\n }\n\n var clientRect = element.getBoundingClientRect();\n var scaleX = 1;\n var scaleY = 1;\n\n if (includeScale && isHTMLElement(element)) {\n scaleX = element.offsetWidth > 0 ? round(clientRect.width) / element.offsetWidth || 1 : 1;\n scaleY = element.offsetHeight > 0 ? round(clientRect.height) / element.offsetHeight || 1 : 1;\n }\n\n var _ref = isElement(element) ? getWindow(element) : window,\n visualViewport = _ref.visualViewport;\n\n var addVisualOffsets = !isLayoutViewport() && isFixedStrategy;\n var x = (clientRect.left + (addVisualOffsets && visualViewport ? visualViewport.offsetLeft : 0)) / scaleX;\n var y = (clientRect.top + (addVisualOffsets && visualViewport ? visualViewport.offsetTop : 0)) / scaleY;\n var width = clientRect.width / scaleX;\n var height = clientRect.height / scaleY;\n return {\n width: width,\n height: height,\n top: y,\n right: x + width,\n bottom: y + height,\n left: x,\n x: x,\n y: y\n };\n}","import getBoundingClientRect from \"./getBoundingClientRect.js\"; // Returns the layout rect of an element relative to its offsetParent. Layout\n// means it doesn't take into account transforms.\n\nexport default function getLayoutRect(element) {\n var clientRect = getBoundingClientRect(element); // Use the clientRect sizes if it's not been transformed.\n // Fixes https://github.com/popperjs/popper-core/issues/1223\n\n var width = element.offsetWidth;\n var height = element.offsetHeight;\n\n if (Math.abs(clientRect.width - width) <= 1) {\n width = clientRect.width;\n }\n\n if (Math.abs(clientRect.height - height) <= 1) {\n height = clientRect.height;\n }\n\n return {\n x: element.offsetLeft,\n y: element.offsetTop,\n width: width,\n height: height\n };\n}","import { isShadowRoot } from \"./instanceOf.js\";\nexport default function contains(parent, child) {\n var rootNode = child.getRootNode && child.getRootNode(); // First, attempt with faster native method\n\n if (parent.contains(child)) {\n return true;\n } // then fallback to custom implementation with Shadow DOM support\n else if (rootNode && isShadowRoot(rootNode)) {\n var next = child;\n\n do {\n if (next && parent.isSameNode(next)) {\n return true;\n } // $FlowFixMe[prop-missing]: need a better way to handle this...\n\n\n next = next.parentNode || next.host;\n } while (next);\n } // Give up, the result is false\n\n\n return false;\n}","import getWindow from \"./getWindow.js\";\nexport default function getComputedStyle(element) {\n return getWindow(element).getComputedStyle(element);\n}","import getNodeName from \"./getNodeName.js\";\nexport default function isTableElement(element) {\n return ['table', 'td', 'th'].indexOf(getNodeName(element)) >= 0;\n}","import { isElement } from \"./instanceOf.js\";\nexport default function getDocumentElement(element) {\n // $FlowFixMe[incompatible-return]: assume body is always available\n return ((isElement(element) ? element.ownerDocument : // $FlowFixMe[prop-missing]\n element.document) || window.document).documentElement;\n}","import getNodeName from \"./getNodeName.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport { isShadowRoot } from \"./instanceOf.js\";\nexport default function getParentNode(element) {\n if (getNodeName(element) === 'html') {\n return element;\n }\n\n return (// this is a quicker (but less type safe) way to save quite some bytes from the bundle\n // $FlowFixMe[incompatible-return]\n // $FlowFixMe[prop-missing]\n element.assignedSlot || // step into the shadow DOM of the parent of a slotted node\n element.parentNode || ( // DOM Element detected\n isShadowRoot(element) ? element.host : null) || // ShadowRoot detected\n // $FlowFixMe[incompatible-call]: HTMLElement is a Node\n getDocumentElement(element) // fallback\n\n );\n}","import getWindow from \"./getWindow.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport getComputedStyle from \"./getComputedStyle.js\";\nimport { isHTMLElement, isShadowRoot } from \"./instanceOf.js\";\nimport isTableElement from \"./isTableElement.js\";\nimport getParentNode from \"./getParentNode.js\";\nimport getUAString from \"../utils/userAgent.js\";\n\nfunction getTrueOffsetParent(element) {\n if (!isHTMLElement(element) || // https://github.com/popperjs/popper-core/issues/837\n getComputedStyle(element).position === 'fixed') {\n return null;\n }\n\n return element.offsetParent;\n} // `.offsetParent` reports `null` for fixed elements, while absolute elements\n// return the containing block\n\n\nfunction getContainingBlock(element) {\n var isFirefox = /firefox/i.test(getUAString());\n var isIE = /Trident/i.test(getUAString());\n\n if (isIE && isHTMLElement(element)) {\n // In IE 9, 10 and 11 fixed elements containing block is always established by the viewport\n var elementCss = getComputedStyle(element);\n\n if (elementCss.position === 'fixed') {\n return null;\n }\n }\n\n var currentNode = getParentNode(element);\n\n if (isShadowRoot(currentNode)) {\n currentNode = currentNode.host;\n }\n\n while (isHTMLElement(currentNode) && ['html', 'body'].indexOf(getNodeName(currentNode)) < 0) {\n var css = getComputedStyle(currentNode); // This is non-exhaustive but covers the most common CSS properties that\n // create a containing block.\n // https://developer.mozilla.org/en-US/docs/Web/CSS/Containing_block#identifying_the_containing_block\n\n if (css.transform !== 'none' || css.perspective !== 'none' || css.contain === 'paint' || ['transform', 'perspective'].indexOf(css.willChange) !== -1 || isFirefox && css.willChange === 'filter' || isFirefox && css.filter && css.filter !== 'none') {\n return currentNode;\n } else {\n currentNode = currentNode.parentNode;\n }\n }\n\n return null;\n} // Gets the closest ancestor positioned element. Handles some edge cases,\n// such as table ancestors and cross browser bugs.\n\n\nexport default function getOffsetParent(element) {\n var window = getWindow(element);\n var offsetParent = getTrueOffsetParent(element);\n\n while (offsetParent && isTableElement(offsetParent) && getComputedStyle(offsetParent).position === 'static') {\n offsetParent = getTrueOffsetParent(offsetParent);\n }\n\n if (offsetParent && (getNodeName(offsetParent) === 'html' || getNodeName(offsetParent) === 'body' && getComputedStyle(offsetParent).position === 'static')) {\n return window;\n }\n\n return offsetParent || getContainingBlock(element) || window;\n}","export default function getMainAxisFromPlacement(placement) {\n return ['top', 'bottom'].indexOf(placement) >= 0 ? 'x' : 'y';\n}","import { max as mathMax, min as mathMin } from \"./math.js\";\nexport function within(min, value, max) {\n return mathMax(min, mathMin(value, max));\n}\nexport function withinMaxClamp(min, value, max) {\n var v = within(min, value, max);\n return v > max ? max : v;\n}","export default function getFreshSideObject() {\n return {\n top: 0,\n right: 0,\n bottom: 0,\n left: 0\n };\n}","import getFreshSideObject from \"./getFreshSideObject.js\";\nexport default function mergePaddingObject(paddingObject) {\n return Object.assign({}, getFreshSideObject(), paddingObject);\n}","export default function expandToHashMap(value, keys) {\n return keys.reduce(function (hashMap, key) {\n hashMap[key] = value;\n return hashMap;\n }, {});\n}","import getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getLayoutRect from \"../dom-utils/getLayoutRect.js\";\nimport contains from \"../dom-utils/contains.js\";\nimport getOffsetParent from \"../dom-utils/getOffsetParent.js\";\nimport getMainAxisFromPlacement from \"../utils/getMainAxisFromPlacement.js\";\nimport { within } from \"../utils/within.js\";\nimport mergePaddingObject from \"../utils/mergePaddingObject.js\";\nimport expandToHashMap from \"../utils/expandToHashMap.js\";\nimport { left, right, basePlacements, top, bottom } from \"../enums.js\"; // eslint-disable-next-line import/no-unused-modules\n\nvar toPaddingObject = function toPaddingObject(padding, state) {\n padding = typeof padding === 'function' ? padding(Object.assign({}, state.rects, {\n placement: state.placement\n })) : padding;\n return mergePaddingObject(typeof padding !== 'number' ? padding : expandToHashMap(padding, basePlacements));\n};\n\nfunction arrow(_ref) {\n var _state$modifiersData$;\n\n var state = _ref.state,\n name = _ref.name,\n options = _ref.options;\n var arrowElement = state.elements.arrow;\n var popperOffsets = state.modifiersData.popperOffsets;\n var basePlacement = getBasePlacement(state.placement);\n var axis = getMainAxisFromPlacement(basePlacement);\n var isVertical = [left, right].indexOf(basePlacement) >= 0;\n var len = isVertical ? 'height' : 'width';\n\n if (!arrowElement || !popperOffsets) {\n return;\n }\n\n var paddingObject = toPaddingObject(options.padding, state);\n var arrowRect = getLayoutRect(arrowElement);\n var minProp = axis === 'y' ? top : left;\n var maxProp = axis === 'y' ? bottom : right;\n var endDiff = state.rects.reference[len] + state.rects.reference[axis] - popperOffsets[axis] - state.rects.popper[len];\n var startDiff = popperOffsets[axis] - state.rects.reference[axis];\n var arrowOffsetParent = getOffsetParent(arrowElement);\n var clientSize = arrowOffsetParent ? axis === 'y' ? arrowOffsetParent.clientHeight || 0 : arrowOffsetParent.clientWidth || 0 : 0;\n var centerToReference = endDiff / 2 - startDiff / 2; // Make sure the arrow doesn't overflow the popper if the center point is\n // outside of the popper bounds\n\n var min = paddingObject[minProp];\n var max = clientSize - arrowRect[len] - paddingObject[maxProp];\n var center = clientSize / 2 - arrowRect[len] / 2 + centerToReference;\n var offset = within(min, center, max); // Prevents breaking syntax highlighting...\n\n var axisProp = axis;\n state.modifiersData[name] = (_state$modifiersData$ = {}, _state$modifiersData$[axisProp] = offset, _state$modifiersData$.centerOffset = offset - center, _state$modifiersData$);\n}\n\nfunction effect(_ref2) {\n var state = _ref2.state,\n options = _ref2.options;\n var _options$element = options.element,\n arrowElement = _options$element === void 0 ? '[data-popper-arrow]' : _options$element;\n\n if (arrowElement == null) {\n return;\n } // CSS selector\n\n\n if (typeof arrowElement === 'string') {\n arrowElement = state.elements.popper.querySelector(arrowElement);\n\n if (!arrowElement) {\n return;\n }\n }\n\n if (!contains(state.elements.popper, arrowElement)) {\n return;\n }\n\n state.elements.arrow = arrowElement;\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'arrow',\n enabled: true,\n phase: 'main',\n fn: arrow,\n effect: effect,\n requires: ['popperOffsets'],\n requiresIfExists: ['preventOverflow']\n};","export default function getVariation(placement) {\n return placement.split('-')[1];\n}","import { top, left, right, bottom, end } from \"../enums.js\";\nimport getOffsetParent from \"../dom-utils/getOffsetParent.js\";\nimport getWindow from \"../dom-utils/getWindow.js\";\nimport getDocumentElement from \"../dom-utils/getDocumentElement.js\";\nimport getComputedStyle from \"../dom-utils/getComputedStyle.js\";\nimport getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getVariation from \"../utils/getVariation.js\";\nimport { round } from \"../utils/math.js\"; // eslint-disable-next-line import/no-unused-modules\n\nvar unsetSides = {\n top: 'auto',\n right: 'auto',\n bottom: 'auto',\n left: 'auto'\n}; // Round the offsets to the nearest suitable subpixel based on the DPR.\n// Zooming can change the DPR, but it seems to report a value that will\n// cleanly divide the values into the appropriate subpixels.\n\nfunction roundOffsetsByDPR(_ref, win) {\n var x = _ref.x,\n y = _ref.y;\n var dpr = win.devicePixelRatio || 1;\n return {\n x: round(x * dpr) / dpr || 0,\n y: round(y * dpr) / dpr || 0\n };\n}\n\nexport function mapToStyles(_ref2) {\n var _Object$assign2;\n\n var popper = _ref2.popper,\n popperRect = _ref2.popperRect,\n placement = _ref2.placement,\n variation = _ref2.variation,\n offsets = _ref2.offsets,\n position = _ref2.position,\n gpuAcceleration = _ref2.gpuAcceleration,\n adaptive = _ref2.adaptive,\n roundOffsets = _ref2.roundOffsets,\n isFixed = _ref2.isFixed;\n var _offsets$x = offsets.x,\n x = _offsets$x === void 0 ? 0 : _offsets$x,\n _offsets$y = offsets.y,\n y = _offsets$y === void 0 ? 0 : _offsets$y;\n\n var _ref3 = typeof roundOffsets === 'function' ? roundOffsets({\n x: x,\n y: y\n }) : {\n x: x,\n y: y\n };\n\n x = _ref3.x;\n y = _ref3.y;\n var hasX = offsets.hasOwnProperty('x');\n var hasY = offsets.hasOwnProperty('y');\n var sideX = left;\n var sideY = top;\n var win = window;\n\n if (adaptive) {\n var offsetParent = getOffsetParent(popper);\n var heightProp = 'clientHeight';\n var widthProp = 'clientWidth';\n\n if (offsetParent === getWindow(popper)) {\n offsetParent = getDocumentElement(popper);\n\n if (getComputedStyle(offsetParent).position !== 'static' && position === 'absolute') {\n heightProp = 'scrollHeight';\n widthProp = 'scrollWidth';\n }\n } // $FlowFixMe[incompatible-cast]: force type refinement, we compare offsetParent with window above, but Flow doesn't detect it\n\n\n offsetParent = offsetParent;\n\n if (placement === top || (placement === left || placement === right) && variation === end) {\n sideY = bottom;\n var offsetY = isFixed && offsetParent === win && win.visualViewport ? win.visualViewport.height : // $FlowFixMe[prop-missing]\n offsetParent[heightProp];\n y -= offsetY - popperRect.height;\n y *= gpuAcceleration ? 1 : -1;\n }\n\n if (placement === left || (placement === top || placement === bottom) && variation === end) {\n sideX = right;\n var offsetX = isFixed && offsetParent === win && win.visualViewport ? win.visualViewport.width : // $FlowFixMe[prop-missing]\n offsetParent[widthProp];\n x -= offsetX - popperRect.width;\n x *= gpuAcceleration ? 1 : -1;\n }\n }\n\n var commonStyles = Object.assign({\n position: position\n }, adaptive && unsetSides);\n\n var _ref4 = roundOffsets === true ? roundOffsetsByDPR({\n x: x,\n y: y\n }, getWindow(popper)) : {\n x: x,\n y: y\n };\n\n x = _ref4.x;\n y = _ref4.y;\n\n if (gpuAcceleration) {\n var _Object$assign;\n\n return Object.assign({}, commonStyles, (_Object$assign = {}, _Object$assign[sideY] = hasY ? '0' : '', _Object$assign[sideX] = hasX ? '0' : '', _Object$assign.transform = (win.devicePixelRatio || 1) <= 1 ? \"translate(\" + x + \"px, \" + y + \"px)\" : \"translate3d(\" + x + \"px, \" + y + \"px, 0)\", _Object$assign));\n }\n\n return Object.assign({}, commonStyles, (_Object$assign2 = {}, _Object$assign2[sideY] = hasY ? y + \"px\" : '', _Object$assign2[sideX] = hasX ? x + \"px\" : '', _Object$assign2.transform = '', _Object$assign2));\n}\n\nfunction computeStyles(_ref5) {\n var state = _ref5.state,\n options = _ref5.options;\n var _options$gpuAccelerat = options.gpuAcceleration,\n gpuAcceleration = _options$gpuAccelerat === void 0 ? true : _options$gpuAccelerat,\n _options$adaptive = options.adaptive,\n adaptive = _options$adaptive === void 0 ? true : _options$adaptive,\n _options$roundOffsets = options.roundOffsets,\n roundOffsets = _options$roundOffsets === void 0 ? true : _options$roundOffsets;\n var commonStyles = {\n placement: getBasePlacement(state.placement),\n variation: getVariation(state.placement),\n popper: state.elements.popper,\n popperRect: state.rects.popper,\n gpuAcceleration: gpuAcceleration,\n isFixed: state.options.strategy === 'fixed'\n };\n\n if (state.modifiersData.popperOffsets != null) {\n state.styles.popper = Object.assign({}, state.styles.popper, mapToStyles(Object.assign({}, commonStyles, {\n offsets: state.modifiersData.popperOffsets,\n position: state.options.strategy,\n adaptive: adaptive,\n roundOffsets: roundOffsets\n })));\n }\n\n if (state.modifiersData.arrow != null) {\n state.styles.arrow = Object.assign({}, state.styles.arrow, mapToStyles(Object.assign({}, commonStyles, {\n offsets: state.modifiersData.arrow,\n position: 'absolute',\n adaptive: false,\n roundOffsets: roundOffsets\n })));\n }\n\n state.attributes.popper = Object.assign({}, state.attributes.popper, {\n 'data-popper-placement': state.placement\n });\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'computeStyles',\n enabled: true,\n phase: 'beforeWrite',\n fn: computeStyles,\n data: {}\n};","import getWindow from \"../dom-utils/getWindow.js\"; // eslint-disable-next-line import/no-unused-modules\n\nvar passive = {\n passive: true\n};\n\nfunction effect(_ref) {\n var state = _ref.state,\n instance = _ref.instance,\n options = _ref.options;\n var _options$scroll = options.scroll,\n scroll = _options$scroll === void 0 ? true : _options$scroll,\n _options$resize = options.resize,\n resize = _options$resize === void 0 ? true : _options$resize;\n var window = getWindow(state.elements.popper);\n var scrollParents = [].concat(state.scrollParents.reference, state.scrollParents.popper);\n\n if (scroll) {\n scrollParents.forEach(function (scrollParent) {\n scrollParent.addEventListener('scroll', instance.update, passive);\n });\n }\n\n if (resize) {\n window.addEventListener('resize', instance.update, passive);\n }\n\n return function () {\n if (scroll) {\n scrollParents.forEach(function (scrollParent) {\n scrollParent.removeEventListener('scroll', instance.update, passive);\n });\n }\n\n if (resize) {\n window.removeEventListener('resize', instance.update, passive);\n }\n };\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'eventListeners',\n enabled: true,\n phase: 'write',\n fn: function fn() {},\n effect: effect,\n data: {}\n};","var hash = {\n left: 'right',\n right: 'left',\n bottom: 'top',\n top: 'bottom'\n};\nexport default function getOppositePlacement(placement) {\n return placement.replace(/left|right|bottom|top/g, function (matched) {\n return hash[matched];\n });\n}","var hash = {\n start: 'end',\n end: 'start'\n};\nexport default function getOppositeVariationPlacement(placement) {\n return placement.replace(/start|end/g, function (matched) {\n return hash[matched];\n });\n}","import getWindow from \"./getWindow.js\";\nexport default function getWindowScroll(node) {\n var win = getWindow(node);\n var scrollLeft = win.pageXOffset;\n var scrollTop = win.pageYOffset;\n return {\n scrollLeft: scrollLeft,\n scrollTop: scrollTop\n };\n}","import getBoundingClientRect from \"./getBoundingClientRect.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport getWindowScroll from \"./getWindowScroll.js\";\nexport default function getWindowScrollBarX(element) {\n // If has a CSS width greater than the viewport, then this will be\n // incorrect for RTL.\n // Popper 1 is broken in this case and never had a bug report so let's assume\n // it's not an issue. I don't think anyone ever specifies width on \n // anyway.\n // Browsers where the left scrollbar doesn't cause an issue report `0` for\n // this (e.g. Edge 2019, IE11, Safari)\n return getBoundingClientRect(getDocumentElement(element)).left + getWindowScroll(element).scrollLeft;\n}","import getWindow from \"./getWindow.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport getWindowScrollBarX from \"./getWindowScrollBarX.js\";\nimport isLayoutViewport from \"./isLayoutViewport.js\";\nexport default function getViewportRect(element, strategy) {\n var win = getWindow(element);\n var html = getDocumentElement(element);\n var visualViewport = win.visualViewport;\n var width = html.clientWidth;\n var height = html.clientHeight;\n var x = 0;\n var y = 0;\n\n if (visualViewport) {\n width = visualViewport.width;\n height = visualViewport.height;\n var layoutViewport = isLayoutViewport();\n\n if (layoutViewport || !layoutViewport && strategy === 'fixed') {\n x = visualViewport.offsetLeft;\n y = visualViewport.offsetTop;\n }\n }\n\n return {\n width: width,\n height: height,\n x: x + getWindowScrollBarX(element),\n y: y\n };\n}","import getDocumentElement from \"./getDocumentElement.js\";\nimport getComputedStyle from \"./getComputedStyle.js\";\nimport getWindowScrollBarX from \"./getWindowScrollBarX.js\";\nimport getWindowScroll from \"./getWindowScroll.js\";\nimport { max } from \"../utils/math.js\"; // Gets the entire size of the scrollable document area, even extending outside\n// of the `` and `` rect bounds if horizontally scrollable\n\nexport default function getDocumentRect(element) {\n var _element$ownerDocumen;\n\n var html = getDocumentElement(element);\n var winScroll = getWindowScroll(element);\n var body = (_element$ownerDocumen = element.ownerDocument) == null ? void 0 : _element$ownerDocumen.body;\n var width = max(html.scrollWidth, html.clientWidth, body ? body.scrollWidth : 0, body ? body.clientWidth : 0);\n var height = max(html.scrollHeight, html.clientHeight, body ? body.scrollHeight : 0, body ? body.clientHeight : 0);\n var x = -winScroll.scrollLeft + getWindowScrollBarX(element);\n var y = -winScroll.scrollTop;\n\n if (getComputedStyle(body || html).direction === 'rtl') {\n x += max(html.clientWidth, body ? body.clientWidth : 0) - width;\n }\n\n return {\n width: width,\n height: height,\n x: x,\n y: y\n };\n}","import getComputedStyle from \"./getComputedStyle.js\";\nexport default function isScrollParent(element) {\n // Firefox wants us to check `-x` and `-y` variations as well\n var _getComputedStyle = getComputedStyle(element),\n overflow = _getComputedStyle.overflow,\n overflowX = _getComputedStyle.overflowX,\n overflowY = _getComputedStyle.overflowY;\n\n return /auto|scroll|overlay|hidden/.test(overflow + overflowY + overflowX);\n}","import getParentNode from \"./getParentNode.js\";\nimport isScrollParent from \"./isScrollParent.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport { isHTMLElement } from \"./instanceOf.js\";\nexport default function getScrollParent(node) {\n if (['html', 'body', '#document'].indexOf(getNodeName(node)) >= 0) {\n // $FlowFixMe[incompatible-return]: assume body is always available\n return node.ownerDocument.body;\n }\n\n if (isHTMLElement(node) && isScrollParent(node)) {\n return node;\n }\n\n return getScrollParent(getParentNode(node));\n}","import getScrollParent from \"./getScrollParent.js\";\nimport getParentNode from \"./getParentNode.js\";\nimport getWindow from \"./getWindow.js\";\nimport isScrollParent from \"./isScrollParent.js\";\n/*\ngiven a DOM element, return the list of all scroll parents, up the list of ancesors\nuntil we get to the top window object. This list is what we attach scroll listeners\nto, because if any of these parent elements scroll, we'll need to re-calculate the\nreference element's position.\n*/\n\nexport default function listScrollParents(element, list) {\n var _element$ownerDocumen;\n\n if (list === void 0) {\n list = [];\n }\n\n var scrollParent = getScrollParent(element);\n var isBody = scrollParent === ((_element$ownerDocumen = element.ownerDocument) == null ? void 0 : _element$ownerDocumen.body);\n var win = getWindow(scrollParent);\n var target = isBody ? [win].concat(win.visualViewport || [], isScrollParent(scrollParent) ? scrollParent : []) : scrollParent;\n var updatedList = list.concat(target);\n return isBody ? updatedList : // $FlowFixMe[incompatible-call]: isBody tells us target will be an HTMLElement here\n updatedList.concat(listScrollParents(getParentNode(target)));\n}","export default function rectToClientRect(rect) {\n return Object.assign({}, rect, {\n left: rect.x,\n top: rect.y,\n right: rect.x + rect.width,\n bottom: rect.y + rect.height\n });\n}","import { viewport } from \"../enums.js\";\nimport getViewportRect from \"./getViewportRect.js\";\nimport getDocumentRect from \"./getDocumentRect.js\";\nimport listScrollParents from \"./listScrollParents.js\";\nimport getOffsetParent from \"./getOffsetParent.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport getComputedStyle from \"./getComputedStyle.js\";\nimport { isElement, isHTMLElement } from \"./instanceOf.js\";\nimport getBoundingClientRect from \"./getBoundingClientRect.js\";\nimport getParentNode from \"./getParentNode.js\";\nimport contains from \"./contains.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport rectToClientRect from \"../utils/rectToClientRect.js\";\nimport { max, min } from \"../utils/math.js\";\n\nfunction getInnerBoundingClientRect(element, strategy) {\n var rect = getBoundingClientRect(element, false, strategy === 'fixed');\n rect.top = rect.top + element.clientTop;\n rect.left = rect.left + element.clientLeft;\n rect.bottom = rect.top + element.clientHeight;\n rect.right = rect.left + element.clientWidth;\n rect.width = element.clientWidth;\n rect.height = element.clientHeight;\n rect.x = rect.left;\n rect.y = rect.top;\n return rect;\n}\n\nfunction getClientRectFromMixedType(element, clippingParent, strategy) {\n return clippingParent === viewport ? rectToClientRect(getViewportRect(element, strategy)) : isElement(clippingParent) ? getInnerBoundingClientRect(clippingParent, strategy) : rectToClientRect(getDocumentRect(getDocumentElement(element)));\n} // A \"clipping parent\" is an overflowable container with the characteristic of\n// clipping (or hiding) overflowing elements with a position different from\n// `initial`\n\n\nfunction getClippingParents(element) {\n var clippingParents = listScrollParents(getParentNode(element));\n var canEscapeClipping = ['absolute', 'fixed'].indexOf(getComputedStyle(element).position) >= 0;\n var clipperElement = canEscapeClipping && isHTMLElement(element) ? getOffsetParent(element) : element;\n\n if (!isElement(clipperElement)) {\n return [];\n } // $FlowFixMe[incompatible-return]: https://github.com/facebook/flow/issues/1414\n\n\n return clippingParents.filter(function (clippingParent) {\n return isElement(clippingParent) && contains(clippingParent, clipperElement) && getNodeName(clippingParent) !== 'body';\n });\n} // Gets the maximum area that the element is visible in due to any number of\n// clipping parents\n\n\nexport default function getClippingRect(element, boundary, rootBoundary, strategy) {\n var mainClippingParents = boundary === 'clippingParents' ? getClippingParents(element) : [].concat(boundary);\n var clippingParents = [].concat(mainClippingParents, [rootBoundary]);\n var firstClippingParent = clippingParents[0];\n var clippingRect = clippingParents.reduce(function (accRect, clippingParent) {\n var rect = getClientRectFromMixedType(element, clippingParent, strategy);\n accRect.top = max(rect.top, accRect.top);\n accRect.right = min(rect.right, accRect.right);\n accRect.bottom = min(rect.bottom, accRect.bottom);\n accRect.left = max(rect.left, accRect.left);\n return accRect;\n }, getClientRectFromMixedType(element, firstClippingParent, strategy));\n clippingRect.width = clippingRect.right - clippingRect.left;\n clippingRect.height = clippingRect.bottom - clippingRect.top;\n clippingRect.x = clippingRect.left;\n clippingRect.y = clippingRect.top;\n return clippingRect;\n}","import getBasePlacement from \"./getBasePlacement.js\";\nimport getVariation from \"./getVariation.js\";\nimport getMainAxisFromPlacement from \"./getMainAxisFromPlacement.js\";\nimport { top, right, bottom, left, start, end } from \"../enums.js\";\nexport default function computeOffsets(_ref) {\n var reference = _ref.reference,\n element = _ref.element,\n placement = _ref.placement;\n var basePlacement = placement ? getBasePlacement(placement) : null;\n var variation = placement ? getVariation(placement) : null;\n var commonX = reference.x + reference.width / 2 - element.width / 2;\n var commonY = reference.y + reference.height / 2 - element.height / 2;\n var offsets;\n\n switch (basePlacement) {\n case top:\n offsets = {\n x: commonX,\n y: reference.y - element.height\n };\n break;\n\n case bottom:\n offsets = {\n x: commonX,\n y: reference.y + reference.height\n };\n break;\n\n case right:\n offsets = {\n x: reference.x + reference.width,\n y: commonY\n };\n break;\n\n case left:\n offsets = {\n x: reference.x - element.width,\n y: commonY\n };\n break;\n\n default:\n offsets = {\n x: reference.x,\n y: reference.y\n };\n }\n\n var mainAxis = basePlacement ? getMainAxisFromPlacement(basePlacement) : null;\n\n if (mainAxis != null) {\n var len = mainAxis === 'y' ? 'height' : 'width';\n\n switch (variation) {\n case start:\n offsets[mainAxis] = offsets[mainAxis] - (reference[len] / 2 - element[len] / 2);\n break;\n\n case end:\n offsets[mainAxis] = offsets[mainAxis] + (reference[len] / 2 - element[len] / 2);\n break;\n\n default:\n }\n }\n\n return offsets;\n}","import getClippingRect from \"../dom-utils/getClippingRect.js\";\nimport getDocumentElement from \"../dom-utils/getDocumentElement.js\";\nimport getBoundingClientRect from \"../dom-utils/getBoundingClientRect.js\";\nimport computeOffsets from \"./computeOffsets.js\";\nimport rectToClientRect from \"./rectToClientRect.js\";\nimport { clippingParents, reference, popper, bottom, top, right, basePlacements, viewport } from \"../enums.js\";\nimport { isElement } from \"../dom-utils/instanceOf.js\";\nimport mergePaddingObject from \"./mergePaddingObject.js\";\nimport expandToHashMap from \"./expandToHashMap.js\"; // eslint-disable-next-line import/no-unused-modules\n\nexport default function detectOverflow(state, options) {\n if (options === void 0) {\n options = {};\n }\n\n var _options = options,\n _options$placement = _options.placement,\n placement = _options$placement === void 0 ? state.placement : _options$placement,\n _options$strategy = _options.strategy,\n strategy = _options$strategy === void 0 ? state.strategy : _options$strategy,\n _options$boundary = _options.boundary,\n boundary = _options$boundary === void 0 ? clippingParents : _options$boundary,\n _options$rootBoundary = _options.rootBoundary,\n rootBoundary = _options$rootBoundary === void 0 ? viewport : _options$rootBoundary,\n _options$elementConte = _options.elementContext,\n elementContext = _options$elementConte === void 0 ? popper : _options$elementConte,\n _options$altBoundary = _options.altBoundary,\n altBoundary = _options$altBoundary === void 0 ? false : _options$altBoundary,\n _options$padding = _options.padding,\n padding = _options$padding === void 0 ? 0 : _options$padding;\n var paddingObject = mergePaddingObject(typeof padding !== 'number' ? padding : expandToHashMap(padding, basePlacements));\n var altContext = elementContext === popper ? reference : popper;\n var popperRect = state.rects.popper;\n var element = state.elements[altBoundary ? altContext : elementContext];\n var clippingClientRect = getClippingRect(isElement(element) ? element : element.contextElement || getDocumentElement(state.elements.popper), boundary, rootBoundary, strategy);\n var referenceClientRect = getBoundingClientRect(state.elements.reference);\n var popperOffsets = computeOffsets({\n reference: referenceClientRect,\n element: popperRect,\n strategy: 'absolute',\n placement: placement\n });\n var popperClientRect = rectToClientRect(Object.assign({}, popperRect, popperOffsets));\n var elementClientRect = elementContext === popper ? popperClientRect : referenceClientRect; // positive = overflowing the clipping rect\n // 0 or negative = within the clipping rect\n\n var overflowOffsets = {\n top: clippingClientRect.top - elementClientRect.top + paddingObject.top,\n bottom: elementClientRect.bottom - clippingClientRect.bottom + paddingObject.bottom,\n left: clippingClientRect.left - elementClientRect.left + paddingObject.left,\n right: elementClientRect.right - clippingClientRect.right + paddingObject.right\n };\n var offsetData = state.modifiersData.offset; // Offsets can be applied only to the popper element\n\n if (elementContext === popper && offsetData) {\n var offset = offsetData[placement];\n Object.keys(overflowOffsets).forEach(function (key) {\n var multiply = [right, bottom].indexOf(key) >= 0 ? 1 : -1;\n var axis = [top, bottom].indexOf(key) >= 0 ? 'y' : 'x';\n overflowOffsets[key] += offset[axis] * multiply;\n });\n }\n\n return overflowOffsets;\n}","import getVariation from \"./getVariation.js\";\nimport { variationPlacements, basePlacements, placements as allPlacements } from \"../enums.js\";\nimport detectOverflow from \"./detectOverflow.js\";\nimport getBasePlacement from \"./getBasePlacement.js\";\nexport default function computeAutoPlacement(state, options) {\n if (options === void 0) {\n options = {};\n }\n\n var _options = options,\n placement = _options.placement,\n boundary = _options.boundary,\n rootBoundary = _options.rootBoundary,\n padding = _options.padding,\n flipVariations = _options.flipVariations,\n _options$allowedAutoP = _options.allowedAutoPlacements,\n allowedAutoPlacements = _options$allowedAutoP === void 0 ? allPlacements : _options$allowedAutoP;\n var variation = getVariation(placement);\n var placements = variation ? flipVariations ? variationPlacements : variationPlacements.filter(function (placement) {\n return getVariation(placement) === variation;\n }) : basePlacements;\n var allowedPlacements = placements.filter(function (placement) {\n return allowedAutoPlacements.indexOf(placement) >= 0;\n });\n\n if (allowedPlacements.length === 0) {\n allowedPlacements = placements;\n } // $FlowFixMe[incompatible-type]: Flow seems to have problems with two array unions...\n\n\n var overflows = allowedPlacements.reduce(function (acc, placement) {\n acc[placement] = detectOverflow(state, {\n placement: placement,\n boundary: boundary,\n rootBoundary: rootBoundary,\n padding: padding\n })[getBasePlacement(placement)];\n return acc;\n }, {});\n return Object.keys(overflows).sort(function (a, b) {\n return overflows[a] - overflows[b];\n });\n}","import getOppositePlacement from \"../utils/getOppositePlacement.js\";\nimport getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getOppositeVariationPlacement from \"../utils/getOppositeVariationPlacement.js\";\nimport detectOverflow from \"../utils/detectOverflow.js\";\nimport computeAutoPlacement from \"../utils/computeAutoPlacement.js\";\nimport { bottom, top, start, right, left, auto } from \"../enums.js\";\nimport getVariation from \"../utils/getVariation.js\"; // eslint-disable-next-line import/no-unused-modules\n\nfunction getExpandedFallbackPlacements(placement) {\n if (getBasePlacement(placement) === auto) {\n return [];\n }\n\n var oppositePlacement = getOppositePlacement(placement);\n return [getOppositeVariationPlacement(placement), oppositePlacement, getOppositeVariationPlacement(oppositePlacement)];\n}\n\nfunction flip(_ref) {\n var state = _ref.state,\n options = _ref.options,\n name = _ref.name;\n\n if (state.modifiersData[name]._skip) {\n return;\n }\n\n var _options$mainAxis = options.mainAxis,\n checkMainAxis = _options$mainAxis === void 0 ? true : _options$mainAxis,\n _options$altAxis = options.altAxis,\n checkAltAxis = _options$altAxis === void 0 ? true : _options$altAxis,\n specifiedFallbackPlacements = options.fallbackPlacements,\n padding = options.padding,\n boundary = options.boundary,\n rootBoundary = options.rootBoundary,\n altBoundary = options.altBoundary,\n _options$flipVariatio = options.flipVariations,\n flipVariations = _options$flipVariatio === void 0 ? true : _options$flipVariatio,\n allowedAutoPlacements = options.allowedAutoPlacements;\n var preferredPlacement = state.options.placement;\n var basePlacement = getBasePlacement(preferredPlacement);\n var isBasePlacement = basePlacement === preferredPlacement;\n var fallbackPlacements = specifiedFallbackPlacements || (isBasePlacement || !flipVariations ? [getOppositePlacement(preferredPlacement)] : getExpandedFallbackPlacements(preferredPlacement));\n var placements = [preferredPlacement].concat(fallbackPlacements).reduce(function (acc, placement) {\n return acc.concat(getBasePlacement(placement) === auto ? computeAutoPlacement(state, {\n placement: placement,\n boundary: boundary,\n rootBoundary: rootBoundary,\n padding: padding,\n flipVariations: flipVariations,\n allowedAutoPlacements: allowedAutoPlacements\n }) : placement);\n }, []);\n var referenceRect = state.rects.reference;\n var popperRect = state.rects.popper;\n var checksMap = new Map();\n var makeFallbackChecks = true;\n var firstFittingPlacement = placements[0];\n\n for (var i = 0; i < placements.length; i++) {\n var placement = placements[i];\n\n var _basePlacement = getBasePlacement(placement);\n\n var isStartVariation = getVariation(placement) === start;\n var isVertical = [top, bottom].indexOf(_basePlacement) >= 0;\n var len = isVertical ? 'width' : 'height';\n var overflow = detectOverflow(state, {\n placement: placement,\n boundary: boundary,\n rootBoundary: rootBoundary,\n altBoundary: altBoundary,\n padding: padding\n });\n var mainVariationSide = isVertical ? isStartVariation ? right : left : isStartVariation ? bottom : top;\n\n if (referenceRect[len] > popperRect[len]) {\n mainVariationSide = getOppositePlacement(mainVariationSide);\n }\n\n var altVariationSide = getOppositePlacement(mainVariationSide);\n var checks = [];\n\n if (checkMainAxis) {\n checks.push(overflow[_basePlacement] <= 0);\n }\n\n if (checkAltAxis) {\n checks.push(overflow[mainVariationSide] <= 0, overflow[altVariationSide] <= 0);\n }\n\n if (checks.every(function (check) {\n return check;\n })) {\n firstFittingPlacement = placement;\n makeFallbackChecks = false;\n break;\n }\n\n checksMap.set(placement, checks);\n }\n\n if (makeFallbackChecks) {\n // `2` may be desired in some cases – research later\n var numberOfChecks = flipVariations ? 3 : 1;\n\n var _loop = function _loop(_i) {\n var fittingPlacement = placements.find(function (placement) {\n var checks = checksMap.get(placement);\n\n if (checks) {\n return checks.slice(0, _i).every(function (check) {\n return check;\n });\n }\n });\n\n if (fittingPlacement) {\n firstFittingPlacement = fittingPlacement;\n return \"break\";\n }\n };\n\n for (var _i = numberOfChecks; _i > 0; _i--) {\n var _ret = _loop(_i);\n\n if (_ret === \"break\") break;\n }\n }\n\n if (state.placement !== firstFittingPlacement) {\n state.modifiersData[name]._skip = true;\n state.placement = firstFittingPlacement;\n state.reset = true;\n }\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'flip',\n enabled: true,\n phase: 'main',\n fn: flip,\n requiresIfExists: ['offset'],\n data: {\n _skip: false\n }\n};","import { top, bottom, left, right } from \"../enums.js\";\nimport detectOverflow from \"../utils/detectOverflow.js\";\n\nfunction getSideOffsets(overflow, rect, preventedOffsets) {\n if (preventedOffsets === void 0) {\n preventedOffsets = {\n x: 0,\n y: 0\n };\n }\n\n return {\n top: overflow.top - rect.height - preventedOffsets.y,\n right: overflow.right - rect.width + preventedOffsets.x,\n bottom: overflow.bottom - rect.height + preventedOffsets.y,\n left: overflow.left - rect.width - preventedOffsets.x\n };\n}\n\nfunction isAnySideFullyClipped(overflow) {\n return [top, right, bottom, left].some(function (side) {\n return overflow[side] >= 0;\n });\n}\n\nfunction hide(_ref) {\n var state = _ref.state,\n name = _ref.name;\n var referenceRect = state.rects.reference;\n var popperRect = state.rects.popper;\n var preventedOffsets = state.modifiersData.preventOverflow;\n var referenceOverflow = detectOverflow(state, {\n elementContext: 'reference'\n });\n var popperAltOverflow = detectOverflow(state, {\n altBoundary: true\n });\n var referenceClippingOffsets = getSideOffsets(referenceOverflow, referenceRect);\n var popperEscapeOffsets = getSideOffsets(popperAltOverflow, popperRect, preventedOffsets);\n var isReferenceHidden = isAnySideFullyClipped(referenceClippingOffsets);\n var hasPopperEscaped = isAnySideFullyClipped(popperEscapeOffsets);\n state.modifiersData[name] = {\n referenceClippingOffsets: referenceClippingOffsets,\n popperEscapeOffsets: popperEscapeOffsets,\n isReferenceHidden: isReferenceHidden,\n hasPopperEscaped: hasPopperEscaped\n };\n state.attributes.popper = Object.assign({}, state.attributes.popper, {\n 'data-popper-reference-hidden': isReferenceHidden,\n 'data-popper-escaped': hasPopperEscaped\n });\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'hide',\n enabled: true,\n phase: 'main',\n requiresIfExists: ['preventOverflow'],\n fn: hide\n};","import getBasePlacement from \"../utils/getBasePlacement.js\";\nimport { top, left, right, placements } from \"../enums.js\"; // eslint-disable-next-line import/no-unused-modules\n\nexport function distanceAndSkiddingToXY(placement, rects, offset) {\n var basePlacement = getBasePlacement(placement);\n var invertDistance = [left, top].indexOf(basePlacement) >= 0 ? -1 : 1;\n\n var _ref = typeof offset === 'function' ? offset(Object.assign({}, rects, {\n placement: placement\n })) : offset,\n skidding = _ref[0],\n distance = _ref[1];\n\n skidding = skidding || 0;\n distance = (distance || 0) * invertDistance;\n return [left, right].indexOf(basePlacement) >= 0 ? {\n x: distance,\n y: skidding\n } : {\n x: skidding,\n y: distance\n };\n}\n\nfunction offset(_ref2) {\n var state = _ref2.state,\n options = _ref2.options,\n name = _ref2.name;\n var _options$offset = options.offset,\n offset = _options$offset === void 0 ? [0, 0] : _options$offset;\n var data = placements.reduce(function (acc, placement) {\n acc[placement] = distanceAndSkiddingToXY(placement, state.rects, offset);\n return acc;\n }, {});\n var _data$state$placement = data[state.placement],\n x = _data$state$placement.x,\n y = _data$state$placement.y;\n\n if (state.modifiersData.popperOffsets != null) {\n state.modifiersData.popperOffsets.x += x;\n state.modifiersData.popperOffsets.y += y;\n }\n\n state.modifiersData[name] = data;\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'offset',\n enabled: true,\n phase: 'main',\n requires: ['popperOffsets'],\n fn: offset\n};","import computeOffsets from \"../utils/computeOffsets.js\";\n\nfunction popperOffsets(_ref) {\n var state = _ref.state,\n name = _ref.name;\n // Offsets are the actual position the popper needs to have to be\n // properly positioned near its reference element\n // This is the most basic placement, and will be adjusted by\n // the modifiers in the next step\n state.modifiersData[name] = computeOffsets({\n reference: state.rects.reference,\n element: state.rects.popper,\n strategy: 'absolute',\n placement: state.placement\n });\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'popperOffsets',\n enabled: true,\n phase: 'read',\n fn: popperOffsets,\n data: {}\n};","export default function getAltAxis(axis) {\n return axis === 'x' ? 'y' : 'x';\n}","import { top, left, right, bottom, start } from \"../enums.js\";\nimport getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getMainAxisFromPlacement from \"../utils/getMainAxisFromPlacement.js\";\nimport getAltAxis from \"../utils/getAltAxis.js\";\nimport { within, withinMaxClamp } from \"../utils/within.js\";\nimport getLayoutRect from \"../dom-utils/getLayoutRect.js\";\nimport getOffsetParent from \"../dom-utils/getOffsetParent.js\";\nimport detectOverflow from \"../utils/detectOverflow.js\";\nimport getVariation from \"../utils/getVariation.js\";\nimport getFreshSideObject from \"../utils/getFreshSideObject.js\";\nimport { min as mathMin, max as mathMax } from \"../utils/math.js\";\n\nfunction preventOverflow(_ref) {\n var state = _ref.state,\n options = _ref.options,\n name = _ref.name;\n var _options$mainAxis = options.mainAxis,\n checkMainAxis = _options$mainAxis === void 0 ? true : _options$mainAxis,\n _options$altAxis = options.altAxis,\n checkAltAxis = _options$altAxis === void 0 ? false : _options$altAxis,\n boundary = options.boundary,\n rootBoundary = options.rootBoundary,\n altBoundary = options.altBoundary,\n padding = options.padding,\n _options$tether = options.tether,\n tether = _options$tether === void 0 ? true : _options$tether,\n _options$tetherOffset = options.tetherOffset,\n tetherOffset = _options$tetherOffset === void 0 ? 0 : _options$tetherOffset;\n var overflow = detectOverflow(state, {\n boundary: boundary,\n rootBoundary: rootBoundary,\n padding: padding,\n altBoundary: altBoundary\n });\n var basePlacement = getBasePlacement(state.placement);\n var variation = getVariation(state.placement);\n var isBasePlacement = !variation;\n var mainAxis = getMainAxisFromPlacement(basePlacement);\n var altAxis = getAltAxis(mainAxis);\n var popperOffsets = state.modifiersData.popperOffsets;\n var referenceRect = state.rects.reference;\n var popperRect = state.rects.popper;\n var tetherOffsetValue = typeof tetherOffset === 'function' ? tetherOffset(Object.assign({}, state.rects, {\n placement: state.placement\n })) : tetherOffset;\n var normalizedTetherOffsetValue = typeof tetherOffsetValue === 'number' ? {\n mainAxis: tetherOffsetValue,\n altAxis: tetherOffsetValue\n } : Object.assign({\n mainAxis: 0,\n altAxis: 0\n }, tetherOffsetValue);\n var offsetModifierState = state.modifiersData.offset ? state.modifiersData.offset[state.placement] : null;\n var data = {\n x: 0,\n y: 0\n };\n\n if (!popperOffsets) {\n return;\n }\n\n if (checkMainAxis) {\n var _offsetModifierState$;\n\n var mainSide = mainAxis === 'y' ? top : left;\n var altSide = mainAxis === 'y' ? bottom : right;\n var len = mainAxis === 'y' ? 'height' : 'width';\n var offset = popperOffsets[mainAxis];\n var min = offset + overflow[mainSide];\n var max = offset - overflow[altSide];\n var additive = tether ? -popperRect[len] / 2 : 0;\n var minLen = variation === start ? referenceRect[len] : popperRect[len];\n var maxLen = variation === start ? -popperRect[len] : -referenceRect[len]; // We need to include the arrow in the calculation so the arrow doesn't go\n // outside the reference bounds\n\n var arrowElement = state.elements.arrow;\n var arrowRect = tether && arrowElement ? getLayoutRect(arrowElement) : {\n width: 0,\n height: 0\n };\n var arrowPaddingObject = state.modifiersData['arrow#persistent'] ? state.modifiersData['arrow#persistent'].padding : getFreshSideObject();\n var arrowPaddingMin = arrowPaddingObject[mainSide];\n var arrowPaddingMax = arrowPaddingObject[altSide]; // If the reference length is smaller than the arrow length, we don't want\n // to include its full size in the calculation. If the reference is small\n // and near the edge of a boundary, the popper can overflow even if the\n // reference is not overflowing as well (e.g. virtual elements with no\n // width or height)\n\n var arrowLen = within(0, referenceRect[len], arrowRect[len]);\n var minOffset = isBasePlacement ? referenceRect[len] / 2 - additive - arrowLen - arrowPaddingMin - normalizedTetherOffsetValue.mainAxis : minLen - arrowLen - arrowPaddingMin - normalizedTetherOffsetValue.mainAxis;\n var maxOffset = isBasePlacement ? -referenceRect[len] / 2 + additive + arrowLen + arrowPaddingMax + normalizedTetherOffsetValue.mainAxis : maxLen + arrowLen + arrowPaddingMax + normalizedTetherOffsetValue.mainAxis;\n var arrowOffsetParent = state.elements.arrow && getOffsetParent(state.elements.arrow);\n var clientOffset = arrowOffsetParent ? mainAxis === 'y' ? arrowOffsetParent.clientTop || 0 : arrowOffsetParent.clientLeft || 0 : 0;\n var offsetModifierValue = (_offsetModifierState$ = offsetModifierState == null ? void 0 : offsetModifierState[mainAxis]) != null ? _offsetModifierState$ : 0;\n var tetherMin = offset + minOffset - offsetModifierValue - clientOffset;\n var tetherMax = offset + maxOffset - offsetModifierValue;\n var preventedOffset = within(tether ? mathMin(min, tetherMin) : min, offset, tether ? mathMax(max, tetherMax) : max);\n popperOffsets[mainAxis] = preventedOffset;\n data[mainAxis] = preventedOffset - offset;\n }\n\n if (checkAltAxis) {\n var _offsetModifierState$2;\n\n var _mainSide = mainAxis === 'x' ? top : left;\n\n var _altSide = mainAxis === 'x' ? bottom : right;\n\n var _offset = popperOffsets[altAxis];\n\n var _len = altAxis === 'y' ? 'height' : 'width';\n\n var _min = _offset + overflow[_mainSide];\n\n var _max = _offset - overflow[_altSide];\n\n var isOriginSide = [top, left].indexOf(basePlacement) !== -1;\n\n var _offsetModifierValue = (_offsetModifierState$2 = offsetModifierState == null ? void 0 : offsetModifierState[altAxis]) != null ? _offsetModifierState$2 : 0;\n\n var _tetherMin = isOriginSide ? _min : _offset - referenceRect[_len] - popperRect[_len] - _offsetModifierValue + normalizedTetherOffsetValue.altAxis;\n\n var _tetherMax = isOriginSide ? _offset + referenceRect[_len] + popperRect[_len] - _offsetModifierValue - normalizedTetherOffsetValue.altAxis : _max;\n\n var _preventedOffset = tether && isOriginSide ? withinMaxClamp(_tetherMin, _offset, _tetherMax) : within(tether ? _tetherMin : _min, _offset, tether ? _tetherMax : _max);\n\n popperOffsets[altAxis] = _preventedOffset;\n data[altAxis] = _preventedOffset - _offset;\n }\n\n state.modifiersData[name] = data;\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'preventOverflow',\n enabled: true,\n phase: 'main',\n fn: preventOverflow,\n requiresIfExists: ['offset']\n};","export default function getHTMLElementScroll(element) {\n return {\n scrollLeft: element.scrollLeft,\n scrollTop: element.scrollTop\n };\n}","import getWindowScroll from \"./getWindowScroll.js\";\nimport getWindow from \"./getWindow.js\";\nimport { isHTMLElement } from \"./instanceOf.js\";\nimport getHTMLElementScroll from \"./getHTMLElementScroll.js\";\nexport default function getNodeScroll(node) {\n if (node === getWindow(node) || !isHTMLElement(node)) {\n return getWindowScroll(node);\n } else {\n return getHTMLElementScroll(node);\n }\n}","import getBoundingClientRect from \"./getBoundingClientRect.js\";\nimport getNodeScroll from \"./getNodeScroll.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport { isHTMLElement } from \"./instanceOf.js\";\nimport getWindowScrollBarX from \"./getWindowScrollBarX.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport isScrollParent from \"./isScrollParent.js\";\nimport { round } from \"../utils/math.js\";\n\nfunction isElementScaled(element) {\n var rect = element.getBoundingClientRect();\n var scaleX = round(rect.width) / element.offsetWidth || 1;\n var scaleY = round(rect.height) / element.offsetHeight || 1;\n return scaleX !== 1 || scaleY !== 1;\n} // Returns the composite rect of an element relative to its offsetParent.\n// Composite means it takes into account transforms as well as layout.\n\n\nexport default function getCompositeRect(elementOrVirtualElement, offsetParent, isFixed) {\n if (isFixed === void 0) {\n isFixed = false;\n }\n\n var isOffsetParentAnElement = isHTMLElement(offsetParent);\n var offsetParentIsScaled = isHTMLElement(offsetParent) && isElementScaled(offsetParent);\n var documentElement = getDocumentElement(offsetParent);\n var rect = getBoundingClientRect(elementOrVirtualElement, offsetParentIsScaled, isFixed);\n var scroll = {\n scrollLeft: 0,\n scrollTop: 0\n };\n var offsets = {\n x: 0,\n y: 0\n };\n\n if (isOffsetParentAnElement || !isOffsetParentAnElement && !isFixed) {\n if (getNodeName(offsetParent) !== 'body' || // https://github.com/popperjs/popper-core/issues/1078\n isScrollParent(documentElement)) {\n scroll = getNodeScroll(offsetParent);\n }\n\n if (isHTMLElement(offsetParent)) {\n offsets = getBoundingClientRect(offsetParent, true);\n offsets.x += offsetParent.clientLeft;\n offsets.y += offsetParent.clientTop;\n } else if (documentElement) {\n offsets.x = getWindowScrollBarX(documentElement);\n }\n }\n\n return {\n x: rect.left + scroll.scrollLeft - offsets.x,\n y: rect.top + scroll.scrollTop - offsets.y,\n width: rect.width,\n height: rect.height\n };\n}","import { modifierPhases } from \"../enums.js\"; // source: https://stackoverflow.com/questions/49875255\n\nfunction order(modifiers) {\n var map = new Map();\n var visited = new Set();\n var result = [];\n modifiers.forEach(function (modifier) {\n map.set(modifier.name, modifier);\n }); // On visiting object, check for its dependencies and visit them recursively\n\n function sort(modifier) {\n visited.add(modifier.name);\n var requires = [].concat(modifier.requires || [], modifier.requiresIfExists || []);\n requires.forEach(function (dep) {\n if (!visited.has(dep)) {\n var depModifier = map.get(dep);\n\n if (depModifier) {\n sort(depModifier);\n }\n }\n });\n result.push(modifier);\n }\n\n modifiers.forEach(function (modifier) {\n if (!visited.has(modifier.name)) {\n // check for visited object\n sort(modifier);\n }\n });\n return result;\n}\n\nexport default function orderModifiers(modifiers) {\n // order based on dependencies\n var orderedModifiers = order(modifiers); // order based on phase\n\n return modifierPhases.reduce(function (acc, phase) {\n return acc.concat(orderedModifiers.filter(function (modifier) {\n return modifier.phase === phase;\n }));\n }, []);\n}","export default function debounce(fn) {\n var pending;\n return function () {\n if (!pending) {\n pending = new Promise(function (resolve) {\n Promise.resolve().then(function () {\n pending = undefined;\n resolve(fn());\n });\n });\n }\n\n return pending;\n };\n}","export default function mergeByName(modifiers) {\n var merged = modifiers.reduce(function (merged, current) {\n var existing = merged[current.name];\n merged[current.name] = existing ? Object.assign({}, existing, current, {\n options: Object.assign({}, existing.options, current.options),\n data: Object.assign({}, existing.data, current.data)\n }) : current;\n return merged;\n }, {}); // IE11 does not support Object.values\n\n return Object.keys(merged).map(function (key) {\n return merged[key];\n });\n}","import getCompositeRect from \"./dom-utils/getCompositeRect.js\";\nimport getLayoutRect from \"./dom-utils/getLayoutRect.js\";\nimport listScrollParents from \"./dom-utils/listScrollParents.js\";\nimport getOffsetParent from \"./dom-utils/getOffsetParent.js\";\nimport orderModifiers from \"./utils/orderModifiers.js\";\nimport debounce from \"./utils/debounce.js\";\nimport mergeByName from \"./utils/mergeByName.js\";\nimport detectOverflow from \"./utils/detectOverflow.js\";\nimport { isElement } from \"./dom-utils/instanceOf.js\";\nvar DEFAULT_OPTIONS = {\n placement: 'bottom',\n modifiers: [],\n strategy: 'absolute'\n};\n\nfunction areValidElements() {\n for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {\n args[_key] = arguments[_key];\n }\n\n return !args.some(function (element) {\n return !(element && typeof element.getBoundingClientRect === 'function');\n });\n}\n\nexport function popperGenerator(generatorOptions) {\n if (generatorOptions === void 0) {\n generatorOptions = {};\n }\n\n var _generatorOptions = generatorOptions,\n _generatorOptions$def = _generatorOptions.defaultModifiers,\n defaultModifiers = _generatorOptions$def === void 0 ? [] : _generatorOptions$def,\n _generatorOptions$def2 = _generatorOptions.defaultOptions,\n defaultOptions = _generatorOptions$def2 === void 0 ? DEFAULT_OPTIONS : _generatorOptions$def2;\n return function createPopper(reference, popper, options) {\n if (options === void 0) {\n options = defaultOptions;\n }\n\n var state = {\n placement: 'bottom',\n orderedModifiers: [],\n options: Object.assign({}, DEFAULT_OPTIONS, defaultOptions),\n modifiersData: {},\n elements: {\n reference: reference,\n popper: popper\n },\n attributes: {},\n styles: {}\n };\n var effectCleanupFns = [];\n var isDestroyed = false;\n var instance = {\n state: state,\n setOptions: function setOptions(setOptionsAction) {\n var options = typeof setOptionsAction === 'function' ? setOptionsAction(state.options) : setOptionsAction;\n cleanupModifierEffects();\n state.options = Object.assign({}, defaultOptions, state.options, options);\n state.scrollParents = {\n reference: isElement(reference) ? listScrollParents(reference) : reference.contextElement ? listScrollParents(reference.contextElement) : [],\n popper: listScrollParents(popper)\n }; // Orders the modifiers based on their dependencies and `phase`\n // properties\n\n var orderedModifiers = orderModifiers(mergeByName([].concat(defaultModifiers, state.options.modifiers))); // Strip out disabled modifiers\n\n state.orderedModifiers = orderedModifiers.filter(function (m) {\n return m.enabled;\n });\n runModifierEffects();\n return instance.update();\n },\n // Sync update – it will always be executed, even if not necessary. This\n // is useful for low frequency updates where sync behavior simplifies the\n // logic.\n // For high frequency updates (e.g. `resize` and `scroll` events), always\n // prefer the async Popper#update method\n forceUpdate: function forceUpdate() {\n if (isDestroyed) {\n return;\n }\n\n var _state$elements = state.elements,\n reference = _state$elements.reference,\n popper = _state$elements.popper; // Don't proceed if `reference` or `popper` are not valid elements\n // anymore\n\n if (!areValidElements(reference, popper)) {\n return;\n } // Store the reference and popper rects to be read by modifiers\n\n\n state.rects = {\n reference: getCompositeRect(reference, getOffsetParent(popper), state.options.strategy === 'fixed'),\n popper: getLayoutRect(popper)\n }; // Modifiers have the ability to reset the current update cycle. The\n // most common use case for this is the `flip` modifier changing the\n // placement, which then needs to re-run all the modifiers, because the\n // logic was previously ran for the previous placement and is therefore\n // stale/incorrect\n\n state.reset = false;\n state.placement = state.options.placement; // On each update cycle, the `modifiersData` property for each modifier\n // is filled with the initial data specified by the modifier. This means\n // it doesn't persist and is fresh on each update.\n // To ensure persistent data, use `${name}#persistent`\n\n state.orderedModifiers.forEach(function (modifier) {\n return state.modifiersData[modifier.name] = Object.assign({}, modifier.data);\n });\n\n for (var index = 0; index < state.orderedModifiers.length; index++) {\n if (state.reset === true) {\n state.reset = false;\n index = -1;\n continue;\n }\n\n var _state$orderedModifie = state.orderedModifiers[index],\n fn = _state$orderedModifie.fn,\n _state$orderedModifie2 = _state$orderedModifie.options,\n _options = _state$orderedModifie2 === void 0 ? {} : _state$orderedModifie2,\n name = _state$orderedModifie.name;\n\n if (typeof fn === 'function') {\n state = fn({\n state: state,\n options: _options,\n name: name,\n instance: instance\n }) || state;\n }\n }\n },\n // Async and optimistically optimized update – it will not be executed if\n // not necessary (debounced to run at most once-per-tick)\n update: debounce(function () {\n return new Promise(function (resolve) {\n instance.forceUpdate();\n resolve(state);\n });\n }),\n destroy: function destroy() {\n cleanupModifierEffects();\n isDestroyed = true;\n }\n };\n\n if (!areValidElements(reference, popper)) {\n return instance;\n }\n\n instance.setOptions(options).then(function (state) {\n if (!isDestroyed && options.onFirstUpdate) {\n options.onFirstUpdate(state);\n }\n }); // Modifiers have the ability to execute arbitrary code before the first\n // update cycle runs. They will be executed in the same order as the update\n // cycle. This is useful when a modifier adds some persistent data that\n // other modifiers need to use, but the modifier is run after the dependent\n // one.\n\n function runModifierEffects() {\n state.orderedModifiers.forEach(function (_ref) {\n var name = _ref.name,\n _ref$options = _ref.options,\n options = _ref$options === void 0 ? {} : _ref$options,\n effect = _ref.effect;\n\n if (typeof effect === 'function') {\n var cleanupFn = effect({\n state: state,\n name: name,\n instance: instance,\n options: options\n });\n\n var noopFn = function noopFn() {};\n\n effectCleanupFns.push(cleanupFn || noopFn);\n }\n });\n }\n\n function cleanupModifierEffects() {\n effectCleanupFns.forEach(function (fn) {\n return fn();\n });\n effectCleanupFns = [];\n }\n\n return instance;\n };\n}\nexport var createPopper = /*#__PURE__*/popperGenerator(); // eslint-disable-next-line import/no-unused-modules\n\nexport { detectOverflow };","import { popperGenerator, detectOverflow } from \"./createPopper.js\";\nimport eventListeners from \"./modifiers/eventListeners.js\";\nimport popperOffsets from \"./modifiers/popperOffsets.js\";\nimport computeStyles from \"./modifiers/computeStyles.js\";\nimport applyStyles from \"./modifiers/applyStyles.js\";\nimport offset from \"./modifiers/offset.js\";\nimport flip from \"./modifiers/flip.js\";\nimport preventOverflow from \"./modifiers/preventOverflow.js\";\nimport arrow from \"./modifiers/arrow.js\";\nimport hide from \"./modifiers/hide.js\";\nvar defaultModifiers = [eventListeners, popperOffsets, computeStyles, applyStyles, offset, flip, preventOverflow, arrow, hide];\nvar createPopper = /*#__PURE__*/popperGenerator({\n defaultModifiers: defaultModifiers\n}); // eslint-disable-next-line import/no-unused-modules\n\nexport { createPopper, popperGenerator, defaultModifiers, detectOverflow }; // eslint-disable-next-line import/no-unused-modules\n\nexport { createPopper as createPopperLite } from \"./popper-lite.js\"; // eslint-disable-next-line import/no-unused-modules\n\nexport * from \"./modifiers/index.js\";","import { generateUtilityClass } from '../generateUtilityClass';\nimport { generateUtilityClasses } from '../generateUtilityClasses';\nconst COMPONENT_NAME = 'Popper';\nexport function getPopperUtilityClass(slot) {\n return generateUtilityClass(COMPONENT_NAME, slot);\n}\nexport const popperClasses = generateUtilityClasses(COMPONENT_NAME, ['root']);","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"anchorEl\", \"children\", \"direction\", \"disablePortal\", \"modifiers\", \"open\", \"placement\", \"popperOptions\", \"popperRef\", \"slotProps\", \"slots\", \"TransitionProps\", \"ownerState\"],\n _excluded2 = [\"anchorEl\", \"children\", \"container\", \"direction\", \"disablePortal\", \"keepMounted\", \"modifiers\", \"open\", \"placement\", \"popperOptions\", \"popperRef\", \"style\", \"transition\", \"slotProps\", \"slots\"];\nimport * as React from 'react';\nimport { chainPropTypes, HTMLElementType, refType, unstable_ownerDocument as ownerDocument, unstable_useEnhancedEffect as useEnhancedEffect, unstable_useForkRef as useForkRef } from '@mui/utils';\nimport { createPopper } from '@popperjs/core';\nimport PropTypes from 'prop-types';\nimport { unstable_composeClasses as composeClasses } from '../composeClasses';\nimport { Portal } from '../Portal';\nimport { getPopperUtilityClass } from './popperClasses';\nimport { useSlotProps } from '../utils';\nimport { useClassNamesOverride } from '../utils/ClassNameConfigurator';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nfunction flipPlacement(placement, direction) {\n if (direction === 'ltr') {\n return placement;\n }\n switch (placement) {\n case 'bottom-end':\n return 'bottom-start';\n case 'bottom-start':\n return 'bottom-end';\n case 'top-end':\n return 'top-start';\n case 'top-start':\n return 'top-end';\n default:\n return placement;\n }\n}\nfunction resolveAnchorEl(anchorEl) {\n return typeof anchorEl === 'function' ? anchorEl() : anchorEl;\n}\nfunction isHTMLElement(element) {\n return element.nodeType !== undefined;\n}\nfunction isVirtualElement(element) {\n return !isHTMLElement(element);\n}\nconst useUtilityClasses = () => {\n const slots = {\n root: ['root']\n };\n return composeClasses(slots, useClassNamesOverride(getPopperUtilityClass));\n};\nconst defaultPopperOptions = {};\nconst PopperTooltip = /*#__PURE__*/React.forwardRef(function PopperTooltip(props, forwardedRef) {\n var _slots$root;\n const {\n anchorEl,\n children,\n direction,\n disablePortal,\n modifiers,\n open,\n placement: initialPlacement,\n popperOptions,\n popperRef: popperRefProp,\n slotProps = {},\n slots = {},\n TransitionProps\n // @ts-ignore internal logic\n // prevent from spreading to DOM, it can come from the parent component e.g. Select.\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const tooltipRef = React.useRef(null);\n const ownRef = useForkRef(tooltipRef, forwardedRef);\n const popperRef = React.useRef(null);\n const handlePopperRef = useForkRef(popperRef, popperRefProp);\n const handlePopperRefRef = React.useRef(handlePopperRef);\n useEnhancedEffect(() => {\n handlePopperRefRef.current = handlePopperRef;\n }, [handlePopperRef]);\n React.useImperativeHandle(popperRefProp, () => popperRef.current, []);\n const rtlPlacement = flipPlacement(initialPlacement, direction);\n /**\n * placement initialized from prop but can change during lifetime if modifiers.flip.\n * modifiers.flip is essentially a flip for controlled/uncontrolled behavior\n */\n const [placement, setPlacement] = React.useState(rtlPlacement);\n const [resolvedAnchorElement, setResolvedAnchorElement] = React.useState(resolveAnchorEl(anchorEl));\n React.useEffect(() => {\n if (popperRef.current) {\n popperRef.current.forceUpdate();\n }\n });\n React.useEffect(() => {\n if (anchorEl) {\n setResolvedAnchorElement(resolveAnchorEl(anchorEl));\n }\n }, [anchorEl]);\n useEnhancedEffect(() => {\n if (!resolvedAnchorElement || !open) {\n return undefined;\n }\n const handlePopperUpdate = data => {\n setPlacement(data.placement);\n };\n if (process.env.NODE_ENV !== 'production') {\n if (resolvedAnchorElement && isHTMLElement(resolvedAnchorElement) && resolvedAnchorElement.nodeType === 1) {\n const box = resolvedAnchorElement.getBoundingClientRect();\n if (process.env.NODE_ENV !== 'test' && box.top === 0 && box.left === 0 && box.right === 0 && box.bottom === 0) {\n console.warn(['MUI: The `anchorEl` prop provided to the component is invalid.', 'The anchor element should be part of the document layout.', \"Make sure the element is present in the document or that it's not display none.\"].join('\\n'));\n }\n }\n }\n let popperModifiers = [{\n name: 'preventOverflow',\n options: {\n altBoundary: disablePortal\n }\n }, {\n name: 'flip',\n options: {\n altBoundary: disablePortal\n }\n }, {\n name: 'onUpdate',\n enabled: true,\n phase: 'afterWrite',\n fn: ({\n state\n }) => {\n handlePopperUpdate(state);\n }\n }];\n if (modifiers != null) {\n popperModifiers = popperModifiers.concat(modifiers);\n }\n if (popperOptions && popperOptions.modifiers != null) {\n popperModifiers = popperModifiers.concat(popperOptions.modifiers);\n }\n const popper = createPopper(resolvedAnchorElement, tooltipRef.current, _extends({\n placement: rtlPlacement\n }, popperOptions, {\n modifiers: popperModifiers\n }));\n handlePopperRefRef.current(popper);\n return () => {\n popper.destroy();\n handlePopperRefRef.current(null);\n };\n }, [resolvedAnchorElement, disablePortal, modifiers, open, popperOptions, rtlPlacement]);\n const childProps = {\n placement: placement\n };\n if (TransitionProps !== null) {\n childProps.TransitionProps = TransitionProps;\n }\n const classes = useUtilityClasses();\n const Root = (_slots$root = slots.root) != null ? _slots$root : 'div';\n const rootProps = useSlotProps({\n elementType: Root,\n externalSlotProps: slotProps.root,\n externalForwardedProps: other,\n additionalProps: {\n role: 'tooltip',\n ref: ownRef\n },\n ownerState: props,\n className: classes.root\n });\n return /*#__PURE__*/_jsx(Root, _extends({}, rootProps, {\n children: typeof children === 'function' ? children(childProps) : children\n }));\n});\n\n/**\n * Poppers rely on the 3rd party library [Popper.js](https://popper.js.org/docs/v2/) for positioning.\n *\n * Demos:\n *\n * - [Popper](https://mui.com/base-ui/react-popper/)\n *\n * API:\n *\n * - [Popper API](https://mui.com/base-ui/react-popper/components-api/#popper)\n */\nconst Popper = /*#__PURE__*/React.forwardRef(function Popper(props, forwardedRef) {\n const {\n anchorEl,\n children,\n container: containerProp,\n direction = 'ltr',\n disablePortal = false,\n keepMounted = false,\n modifiers,\n open,\n placement = 'bottom',\n popperOptions = defaultPopperOptions,\n popperRef,\n style,\n transition = false,\n slotProps = {},\n slots = {}\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded2);\n const [exited, setExited] = React.useState(true);\n const handleEnter = () => {\n setExited(false);\n };\n const handleExited = () => {\n setExited(true);\n };\n if (!keepMounted && !open && (!transition || exited)) {\n return null;\n }\n\n // If the container prop is provided, use that\n // If the anchorEl prop is provided, use its parent body element as the container\n // If neither are provided let the Modal take care of choosing the container\n let container;\n if (containerProp) {\n container = containerProp;\n } else if (anchorEl) {\n const resolvedAnchorEl = resolveAnchorEl(anchorEl);\n container = resolvedAnchorEl && isHTMLElement(resolvedAnchorEl) ? ownerDocument(resolvedAnchorEl).body : ownerDocument(null).body;\n }\n const display = !open && keepMounted && (!transition || exited) ? 'none' : undefined;\n const transitionProps = transition ? {\n in: open,\n onEnter: handleEnter,\n onExited: handleExited\n } : undefined;\n return /*#__PURE__*/_jsx(Portal, {\n disablePortal: disablePortal,\n container: container,\n children: /*#__PURE__*/_jsx(PopperTooltip, _extends({\n anchorEl: anchorEl,\n direction: direction,\n disablePortal: disablePortal,\n modifiers: modifiers,\n ref: forwardedRef,\n open: transition ? !exited : open,\n placement: placement,\n popperOptions: popperOptions,\n popperRef: popperRef,\n slotProps: slotProps,\n slots: slots\n }, other, {\n style: _extends({\n // Prevents scroll issue, waiting for Popper.js to add this style once initiated.\n position: 'fixed',\n // Fix Popper.js display issue\n top: 0,\n left: 0,\n display\n }, style),\n TransitionProps: transitionProps,\n children: children\n }))\n });\n});\nprocess.env.NODE_ENV !== \"production\" ? Popper.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * An HTML element, [virtualElement](https://popper.js.org/docs/v2/virtual-elements/),\n * or a function that returns either.\n * It's used to set the position of the popper.\n * The return value will passed as the reference object of the Popper instance.\n */\n anchorEl: chainPropTypes(PropTypes.oneOfType([HTMLElementType, PropTypes.object, PropTypes.func]), props => {\n if (props.open) {\n const resolvedAnchorEl = resolveAnchorEl(props.anchorEl);\n if (resolvedAnchorEl && isHTMLElement(resolvedAnchorEl) && resolvedAnchorEl.nodeType === 1) {\n const box = resolvedAnchorEl.getBoundingClientRect();\n if (process.env.NODE_ENV !== 'test' && box.top === 0 && box.left === 0 && box.right === 0 && box.bottom === 0) {\n return new Error(['MUI: The `anchorEl` prop provided to the component is invalid.', 'The anchor element should be part of the document layout.', \"Make sure the element is present in the document or that it's not display none.\"].join('\\n'));\n }\n } else if (!resolvedAnchorEl || typeof resolvedAnchorEl.getBoundingClientRect !== 'function' || isVirtualElement(resolvedAnchorEl) && resolvedAnchorEl.contextElement != null && resolvedAnchorEl.contextElement.nodeType !== 1) {\n return new Error(['MUI: The `anchorEl` prop provided to the component is invalid.', 'It should be an HTML element instance or a virtualElement ', '(https://popper.js.org/docs/v2/virtual-elements/).'].join('\\n'));\n }\n }\n return null;\n }),\n /**\n * Popper render function or node.\n */\n children: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.node, PropTypes.func]),\n /**\n * An HTML element or function that returns one.\n * The `container` will have the portal children appended to it.\n *\n * You can also provide a callback, which is called in a React layout effect.\n * This lets you set the container from a ref, and also makes server-side rendering possible.\n *\n * By default, it uses the body of the top-level document object,\n * so it's simply `document.body` most of the time.\n */\n container: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.func]),\n /**\n * Direction of the text.\n * @default 'ltr'\n */\n direction: PropTypes.oneOf(['ltr', 'rtl']),\n /**\n * The `children` will be under the DOM hierarchy of the parent component.\n * @default false\n */\n disablePortal: PropTypes.bool,\n /**\n * Always keep the children in the DOM.\n * This prop can be useful in SEO situation or\n * when you want to maximize the responsiveness of the Popper.\n * @default false\n */\n keepMounted: PropTypes.bool,\n /**\n * Popper.js is based on a \"plugin-like\" architecture,\n * most of its features are fully encapsulated \"modifiers\".\n *\n * A modifier is a function that is called each time Popper.js needs to\n * compute the position of the popper.\n * For this reason, modifiers should be very performant to avoid bottlenecks.\n * To learn how to create a modifier, [read the modifiers documentation](https://popper.js.org/docs/v2/modifiers/).\n */\n modifiers: PropTypes.arrayOf(PropTypes.shape({\n data: PropTypes.object,\n effect: PropTypes.func,\n enabled: PropTypes.bool,\n fn: PropTypes.func,\n name: PropTypes.any,\n options: PropTypes.object,\n phase: PropTypes.oneOf(['afterMain', 'afterRead', 'afterWrite', 'beforeMain', 'beforeRead', 'beforeWrite', 'main', 'read', 'write']),\n requires: PropTypes.arrayOf(PropTypes.string),\n requiresIfExists: PropTypes.arrayOf(PropTypes.string)\n })),\n /**\n * If `true`, the component is shown.\n */\n open: PropTypes.bool.isRequired,\n /**\n * Popper placement.\n * @default 'bottom'\n */\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n /**\n * Options provided to the [`Popper.js`](https://popper.js.org/docs/v2/constructors/#options) instance.\n * @default {}\n */\n popperOptions: PropTypes.shape({\n modifiers: PropTypes.array,\n onFirstUpdate: PropTypes.func,\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n strategy: PropTypes.oneOf(['absolute', 'fixed'])\n }),\n /**\n * A ref that points to the used popper instance.\n */\n popperRef: refType,\n /**\n * The props used for each slot inside the Popper.\n * @default {}\n */\n slotProps: PropTypes.shape({\n root: PropTypes.oneOfType([PropTypes.func, PropTypes.object])\n }),\n /**\n * The components used for each slot inside the Popper.\n * Either a string to use a HTML element or a component.\n * @default {}\n */\n slots: PropTypes.shape({\n root: PropTypes.elementType\n }),\n /**\n * Help supporting a react-transition-group/Transition component.\n * @default false\n */\n transition: PropTypes.bool\n} : void 0;\nexport { Popper };","'use client';\n\nimport * as React from 'react';\nimport { useTheme as useThemeSystem } from '@mui/system';\nimport defaultTheme from './defaultTheme';\nimport THEME_ID from './identifier';\nexport default function useTheme() {\n const theme = useThemeSystem(defaultTheme);\n if (process.env.NODE_ENV !== 'production') {\n // eslint-disable-next-line react-hooks/rules-of-hooks\n React.useDebugValue(theme);\n }\n return theme[THEME_ID] || theme;\n}","export default function _setPrototypeOf(o, p) {\n _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function _setPrototypeOf(o, p) {\n o.__proto__ = p;\n return o;\n };\n return _setPrototypeOf(o, p);\n}","import setPrototypeOf from \"./setPrototypeOf.js\";\nexport default function _inheritsLoose(subClass, superClass) {\n subClass.prototype = Object.create(superClass.prototype);\n subClass.prototype.constructor = subClass;\n setPrototypeOf(subClass, superClass);\n}","export default {\n disabled: false\n};","import PropTypes from 'prop-types';\nexport var timeoutsShape = process.env.NODE_ENV !== 'production' ? PropTypes.oneOfType([PropTypes.number, PropTypes.shape({\n enter: PropTypes.number,\n exit: PropTypes.number,\n appear: PropTypes.number\n}).isRequired]) : null;\nexport var classNamesShape = process.env.NODE_ENV !== 'production' ? PropTypes.oneOfType([PropTypes.string, PropTypes.shape({\n enter: PropTypes.string,\n exit: PropTypes.string,\n active: PropTypes.string\n}), PropTypes.shape({\n enter: PropTypes.string,\n enterDone: PropTypes.string,\n enterActive: PropTypes.string,\n exit: PropTypes.string,\n exitDone: PropTypes.string,\n exitActive: PropTypes.string\n})]) : null;","import React from 'react';\nexport default React.createContext(null);","export var forceReflow = function forceReflow(node) {\n return node.scrollTop;\n};","import _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _inheritsLoose from \"@babel/runtime/helpers/esm/inheritsLoose\";\nimport PropTypes from 'prop-types';\nimport React from 'react';\nimport ReactDOM from 'react-dom';\nimport config from './config';\nimport { timeoutsShape } from './utils/PropTypes';\nimport TransitionGroupContext from './TransitionGroupContext';\nimport { forceReflow } from './utils/reflow';\nexport var UNMOUNTED = 'unmounted';\nexport var EXITED = 'exited';\nexport var ENTERING = 'entering';\nexport var ENTERED = 'entered';\nexport var EXITING = 'exiting';\n/**\n * The Transition component lets you describe a transition from one component\n * state to another _over time_ with a simple declarative API. Most commonly\n * it's used to animate the mounting and unmounting of a component, but can also\n * be used to describe in-place transition states as well.\n *\n * ---\n *\n * **Note**: `Transition` is a platform-agnostic base component. If you're using\n * transitions in CSS, you'll probably want to use\n * [`CSSTransition`](https://reactcommunity.org/react-transition-group/css-transition)\n * instead. It inherits all the features of `Transition`, but contains\n * additional features necessary to play nice with CSS transitions (hence the\n * name of the component).\n *\n * ---\n *\n * By default the `Transition` component does not alter the behavior of the\n * component it renders, it only tracks \"enter\" and \"exit\" states for the\n * components. It's up to you to give meaning and effect to those states. For\n * example we can add styles to a component when it enters or exits:\n *\n * ```jsx\n * import { Transition } from 'react-transition-group';\n *\n * const duration = 300;\n *\n * const defaultStyle = {\n * transition: `opacity ${duration}ms ease-in-out`,\n * opacity: 0,\n * }\n *\n * const transitionStyles = {\n * entering: { opacity: 1 },\n * entered: { opacity: 1 },\n * exiting: { opacity: 0 },\n * exited: { opacity: 0 },\n * };\n *\n * const Fade = ({ in: inProp }) => (\n * \n * {state => (\n *
    \n * I'm a fade Transition!\n *
    \n * )}\n *
    \n * );\n * ```\n *\n * There are 4 main states a Transition can be in:\n * - `'entering'`\n * - `'entered'`\n * - `'exiting'`\n * - `'exited'`\n *\n * Transition state is toggled via the `in` prop. When `true` the component\n * begins the \"Enter\" stage. During this stage, the component will shift from\n * its current transition state, to `'entering'` for the duration of the\n * transition and then to the `'entered'` stage once it's complete. Let's take\n * the following example (we'll use the\n * [useState](https://reactjs.org/docs/hooks-reference.html#usestate) hook):\n *\n * ```jsx\n * function App() {\n * const [inProp, setInProp] = useState(false);\n * return (\n *
    \n * \n * {state => (\n * // ...\n * )}\n * \n * \n *
    \n * );\n * }\n * ```\n *\n * When the button is clicked the component will shift to the `'entering'` state\n * and stay there for 500ms (the value of `timeout`) before it finally switches\n * to `'entered'`.\n *\n * When `in` is `false` the same thing happens except the state moves from\n * `'exiting'` to `'exited'`.\n */\n\nvar Transition = /*#__PURE__*/function (_React$Component) {\n _inheritsLoose(Transition, _React$Component);\n\n function Transition(props, context) {\n var _this;\n\n _this = _React$Component.call(this, props, context) || this;\n var parentGroup = context; // In the context of a TransitionGroup all enters are really appears\n\n var appear = parentGroup && !parentGroup.isMounting ? props.enter : props.appear;\n var initialStatus;\n _this.appearStatus = null;\n\n if (props.in) {\n if (appear) {\n initialStatus = EXITED;\n _this.appearStatus = ENTERING;\n } else {\n initialStatus = ENTERED;\n }\n } else {\n if (props.unmountOnExit || props.mountOnEnter) {\n initialStatus = UNMOUNTED;\n } else {\n initialStatus = EXITED;\n }\n }\n\n _this.state = {\n status: initialStatus\n };\n _this.nextCallback = null;\n return _this;\n }\n\n Transition.getDerivedStateFromProps = function getDerivedStateFromProps(_ref, prevState) {\n var nextIn = _ref.in;\n\n if (nextIn && prevState.status === UNMOUNTED) {\n return {\n status: EXITED\n };\n }\n\n return null;\n } // getSnapshotBeforeUpdate(prevProps) {\n // let nextStatus = null\n // if (prevProps !== this.props) {\n // const { status } = this.state\n // if (this.props.in) {\n // if (status !== ENTERING && status !== ENTERED) {\n // nextStatus = ENTERING\n // }\n // } else {\n // if (status === ENTERING || status === ENTERED) {\n // nextStatus = EXITING\n // }\n // }\n // }\n // return { nextStatus }\n // }\n ;\n\n var _proto = Transition.prototype;\n\n _proto.componentDidMount = function componentDidMount() {\n this.updateStatus(true, this.appearStatus);\n };\n\n _proto.componentDidUpdate = function componentDidUpdate(prevProps) {\n var nextStatus = null;\n\n if (prevProps !== this.props) {\n var status = this.state.status;\n\n if (this.props.in) {\n if (status !== ENTERING && status !== ENTERED) {\n nextStatus = ENTERING;\n }\n } else {\n if (status === ENTERING || status === ENTERED) {\n nextStatus = EXITING;\n }\n }\n }\n\n this.updateStatus(false, nextStatus);\n };\n\n _proto.componentWillUnmount = function componentWillUnmount() {\n this.cancelNextCallback();\n };\n\n _proto.getTimeouts = function getTimeouts() {\n var timeout = this.props.timeout;\n var exit, enter, appear;\n exit = enter = appear = timeout;\n\n if (timeout != null && typeof timeout !== 'number') {\n exit = timeout.exit;\n enter = timeout.enter; // TODO: remove fallback for next major\n\n appear = timeout.appear !== undefined ? timeout.appear : enter;\n }\n\n return {\n exit: exit,\n enter: enter,\n appear: appear\n };\n };\n\n _proto.updateStatus = function updateStatus(mounting, nextStatus) {\n if (mounting === void 0) {\n mounting = false;\n }\n\n if (nextStatus !== null) {\n // nextStatus will always be ENTERING or EXITING.\n this.cancelNextCallback();\n\n if (nextStatus === ENTERING) {\n if (this.props.unmountOnExit || this.props.mountOnEnter) {\n var node = this.props.nodeRef ? this.props.nodeRef.current : ReactDOM.findDOMNode(this); // https://github.com/reactjs/react-transition-group/pull/749\n // With unmountOnExit or mountOnEnter, the enter animation should happen at the transition between `exited` and `entering`.\n // To make the animation happen, we have to separate each rendering and avoid being processed as batched.\n\n if (node) forceReflow(node);\n }\n\n this.performEnter(mounting);\n } else {\n this.performExit();\n }\n } else if (this.props.unmountOnExit && this.state.status === EXITED) {\n this.setState({\n status: UNMOUNTED\n });\n }\n };\n\n _proto.performEnter = function performEnter(mounting) {\n var _this2 = this;\n\n var enter = this.props.enter;\n var appearing = this.context ? this.context.isMounting : mounting;\n\n var _ref2 = this.props.nodeRef ? [appearing] : [ReactDOM.findDOMNode(this), appearing],\n maybeNode = _ref2[0],\n maybeAppearing = _ref2[1];\n\n var timeouts = this.getTimeouts();\n var enterTimeout = appearing ? timeouts.appear : timeouts.enter; // no enter animation skip right to ENTERED\n // if we are mounting and running this it means appear _must_ be set\n\n if (!mounting && !enter || config.disabled) {\n this.safeSetState({\n status: ENTERED\n }, function () {\n _this2.props.onEntered(maybeNode);\n });\n return;\n }\n\n this.props.onEnter(maybeNode, maybeAppearing);\n this.safeSetState({\n status: ENTERING\n }, function () {\n _this2.props.onEntering(maybeNode, maybeAppearing);\n\n _this2.onTransitionEnd(enterTimeout, function () {\n _this2.safeSetState({\n status: ENTERED\n }, function () {\n _this2.props.onEntered(maybeNode, maybeAppearing);\n });\n });\n });\n };\n\n _proto.performExit = function performExit() {\n var _this3 = this;\n\n var exit = this.props.exit;\n var timeouts = this.getTimeouts();\n var maybeNode = this.props.nodeRef ? undefined : ReactDOM.findDOMNode(this); // no exit animation skip right to EXITED\n\n if (!exit || config.disabled) {\n this.safeSetState({\n status: EXITED\n }, function () {\n _this3.props.onExited(maybeNode);\n });\n return;\n }\n\n this.props.onExit(maybeNode);\n this.safeSetState({\n status: EXITING\n }, function () {\n _this3.props.onExiting(maybeNode);\n\n _this3.onTransitionEnd(timeouts.exit, function () {\n _this3.safeSetState({\n status: EXITED\n }, function () {\n _this3.props.onExited(maybeNode);\n });\n });\n });\n };\n\n _proto.cancelNextCallback = function cancelNextCallback() {\n if (this.nextCallback !== null) {\n this.nextCallback.cancel();\n this.nextCallback = null;\n }\n };\n\n _proto.safeSetState = function safeSetState(nextState, callback) {\n // This shouldn't be necessary, but there are weird race conditions with\n // setState callbacks and unmounting in testing, so always make sure that\n // we can cancel any pending setState callbacks after we unmount.\n callback = this.setNextCallback(callback);\n this.setState(nextState, callback);\n };\n\n _proto.setNextCallback = function setNextCallback(callback) {\n var _this4 = this;\n\n var active = true;\n\n this.nextCallback = function (event) {\n if (active) {\n active = false;\n _this4.nextCallback = null;\n callback(event);\n }\n };\n\n this.nextCallback.cancel = function () {\n active = false;\n };\n\n return this.nextCallback;\n };\n\n _proto.onTransitionEnd = function onTransitionEnd(timeout, handler) {\n this.setNextCallback(handler);\n var node = this.props.nodeRef ? this.props.nodeRef.current : ReactDOM.findDOMNode(this);\n var doesNotHaveTimeoutOrListener = timeout == null && !this.props.addEndListener;\n\n if (!node || doesNotHaveTimeoutOrListener) {\n setTimeout(this.nextCallback, 0);\n return;\n }\n\n if (this.props.addEndListener) {\n var _ref3 = this.props.nodeRef ? [this.nextCallback] : [node, this.nextCallback],\n maybeNode = _ref3[0],\n maybeNextCallback = _ref3[1];\n\n this.props.addEndListener(maybeNode, maybeNextCallback);\n }\n\n if (timeout != null) {\n setTimeout(this.nextCallback, timeout);\n }\n };\n\n _proto.render = function render() {\n var status = this.state.status;\n\n if (status === UNMOUNTED) {\n return null;\n }\n\n var _this$props = this.props,\n children = _this$props.children,\n _in = _this$props.in,\n _mountOnEnter = _this$props.mountOnEnter,\n _unmountOnExit = _this$props.unmountOnExit,\n _appear = _this$props.appear,\n _enter = _this$props.enter,\n _exit = _this$props.exit,\n _timeout = _this$props.timeout,\n _addEndListener = _this$props.addEndListener,\n _onEnter = _this$props.onEnter,\n _onEntering = _this$props.onEntering,\n _onEntered = _this$props.onEntered,\n _onExit = _this$props.onExit,\n _onExiting = _this$props.onExiting,\n _onExited = _this$props.onExited,\n _nodeRef = _this$props.nodeRef,\n childProps = _objectWithoutPropertiesLoose(_this$props, [\"children\", \"in\", \"mountOnEnter\", \"unmountOnExit\", \"appear\", \"enter\", \"exit\", \"timeout\", \"addEndListener\", \"onEnter\", \"onEntering\", \"onEntered\", \"onExit\", \"onExiting\", \"onExited\", \"nodeRef\"]);\n\n return (\n /*#__PURE__*/\n // allows for nested Transitions\n React.createElement(TransitionGroupContext.Provider, {\n value: null\n }, typeof children === 'function' ? children(status, childProps) : React.cloneElement(React.Children.only(children), childProps))\n );\n };\n\n return Transition;\n}(React.Component);\n\nTransition.contextType = TransitionGroupContext;\nTransition.propTypes = process.env.NODE_ENV !== \"production\" ? {\n /**\n * A React reference to DOM element that need to transition:\n * https://stackoverflow.com/a/51127130/4671932\n *\n * - When `nodeRef` prop is used, `node` is not passed to callback functions\n * (e.g. `onEnter`) because user already has direct access to the node.\n * - When changing `key` prop of `Transition` in a `TransitionGroup` a new\n * `nodeRef` need to be provided to `Transition` with changed `key` prop\n * (see\n * [test/CSSTransition-test.js](https://github.com/reactjs/react-transition-group/blob/13435f897b3ab71f6e19d724f145596f5910581c/test/CSSTransition-test.js#L362-L437)).\n */\n nodeRef: PropTypes.shape({\n current: typeof Element === 'undefined' ? PropTypes.any : function (propValue, key, componentName, location, propFullName, secret) {\n var value = propValue[key];\n return PropTypes.instanceOf(value && 'ownerDocument' in value ? value.ownerDocument.defaultView.Element : Element)(propValue, key, componentName, location, propFullName, secret);\n }\n }),\n\n /**\n * A `function` child can be used instead of a React element. This function is\n * called with the current transition status (`'entering'`, `'entered'`,\n * `'exiting'`, `'exited'`), which can be used to apply context\n * specific props to a component.\n *\n * ```jsx\n * \n * {state => (\n * \n * )}\n * \n * ```\n */\n children: PropTypes.oneOfType([PropTypes.func.isRequired, PropTypes.element.isRequired]).isRequired,\n\n /**\n * Show the component; triggers the enter or exit states\n */\n in: PropTypes.bool,\n\n /**\n * By default the child component is mounted immediately along with\n * the parent `Transition` component. If you want to \"lazy mount\" the component on the\n * first `in={true}` you can set `mountOnEnter`. After the first enter transition the component will stay\n * mounted, even on \"exited\", unless you also specify `unmountOnExit`.\n */\n mountOnEnter: PropTypes.bool,\n\n /**\n * By default the child component stays mounted after it reaches the `'exited'` state.\n * Set `unmountOnExit` if you'd prefer to unmount the component after it finishes exiting.\n */\n unmountOnExit: PropTypes.bool,\n\n /**\n * By default the child component does not perform the enter transition when\n * it first mounts, regardless of the value of `in`. If you want this\n * behavior, set both `appear` and `in` to `true`.\n *\n * > **Note**: there are no special appear states like `appearing`/`appeared`, this prop\n * > only adds an additional enter transition. However, in the\n * > `` component that first enter transition does result in\n * > additional `.appear-*` classes, that way you can choose to style it\n * > differently.\n */\n appear: PropTypes.bool,\n\n /**\n * Enable or disable enter transitions.\n */\n enter: PropTypes.bool,\n\n /**\n * Enable or disable exit transitions.\n */\n exit: PropTypes.bool,\n\n /**\n * The duration of the transition, in milliseconds.\n * Required unless `addEndListener` is provided.\n *\n * You may specify a single timeout for all transitions:\n *\n * ```jsx\n * timeout={500}\n * ```\n *\n * or individually:\n *\n * ```jsx\n * timeout={{\n * appear: 500,\n * enter: 300,\n * exit: 500,\n * }}\n * ```\n *\n * - `appear` defaults to the value of `enter`\n * - `enter` defaults to `0`\n * - `exit` defaults to `0`\n *\n * @type {number | { enter?: number, exit?: number, appear?: number }}\n */\n timeout: function timeout(props) {\n var pt = timeoutsShape;\n if (!props.addEndListener) pt = pt.isRequired;\n\n for (var _len = arguments.length, args = new Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) {\n args[_key - 1] = arguments[_key];\n }\n\n return pt.apply(void 0, [props].concat(args));\n },\n\n /**\n * Add a custom transition end trigger. Called with the transitioning\n * DOM node and a `done` callback. Allows for more fine grained transition end\n * logic. Timeouts are still used as a fallback if provided.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * ```jsx\n * addEndListener={(node, done) => {\n * // use the css transitionend event to mark the finish of a transition\n * node.addEventListener('transitionend', done, false);\n * }}\n * ```\n */\n addEndListener: PropTypes.func,\n\n /**\n * Callback fired before the \"entering\" status is applied. An extra parameter\n * `isAppearing` is supplied to indicate if the enter stage is occurring on the initial mount\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement, isAppearing: bool) -> void\n */\n onEnter: PropTypes.func,\n\n /**\n * Callback fired after the \"entering\" status is applied. An extra parameter\n * `isAppearing` is supplied to indicate if the enter stage is occurring on the initial mount\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement, isAppearing: bool)\n */\n onEntering: PropTypes.func,\n\n /**\n * Callback fired after the \"entered\" status is applied. An extra parameter\n * `isAppearing` is supplied to indicate if the enter stage is occurring on the initial mount\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement, isAppearing: bool) -> void\n */\n onEntered: PropTypes.func,\n\n /**\n * Callback fired before the \"exiting\" status is applied.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement) -> void\n */\n onExit: PropTypes.func,\n\n /**\n * Callback fired after the \"exiting\" status is applied.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement) -> void\n */\n onExiting: PropTypes.func,\n\n /**\n * Callback fired after the \"exited\" status is applied.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed\n *\n * @type Function(node: HtmlElement) -> void\n */\n onExited: PropTypes.func\n} : {}; // Name the function so it is clearer in the documentation\n\nfunction noop() {}\n\nTransition.defaultProps = {\n in: false,\n mountOnEnter: false,\n unmountOnExit: false,\n appear: false,\n enter: true,\n exit: true,\n onEnter: noop,\n onEntering: noop,\n onEntered: noop,\n onExit: noop,\n onExiting: noop,\n onExited: noop\n};\nTransition.UNMOUNTED = UNMOUNTED;\nTransition.EXITED = EXITED;\nTransition.ENTERING = ENTERING;\nTransition.ENTERED = ENTERED;\nTransition.EXITING = EXITING;\nexport default Transition;","export const reflow = node => node.scrollTop;\nexport function getTransitionProps(props, options) {\n var _style$transitionDura, _style$transitionTimi;\n const {\n timeout,\n easing,\n style = {}\n } = props;\n return {\n duration: (_style$transitionDura = style.transitionDuration) != null ? _style$transitionDura : typeof timeout === 'number' ? timeout : timeout[options.mode] || 0,\n easing: (_style$transitionTimi = style.transitionTimingFunction) != null ? _style$transitionTimi : typeof easing === 'object' ? easing[options.mode] : easing,\n delay: style.transitionDelay\n };\n}","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"addEndListener\", \"appear\", \"children\", \"easing\", \"in\", \"onEnter\", \"onEntered\", \"onEntering\", \"onExit\", \"onExited\", \"onExiting\", \"style\", \"timeout\", \"TransitionComponent\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport { elementAcceptingRef, unstable_useTimeout as useTimeout } from '@mui/utils';\nimport { Transition } from 'react-transition-group';\nimport useTheme from '../styles/useTheme';\nimport { getTransitionProps, reflow } from '../transitions/utils';\nimport useForkRef from '../utils/useForkRef';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nfunction getScale(value) {\n return `scale(${value}, ${value ** 2})`;\n}\nconst styles = {\n entering: {\n opacity: 1,\n transform: getScale(1)\n },\n entered: {\n opacity: 1,\n transform: 'none'\n }\n};\n\n/*\n TODO v6: remove\n Conditionally apply a workaround for the CSS transition bug in Safari 15.4 / WebKit browsers.\n */\nconst isWebKit154 = typeof navigator !== 'undefined' && /^((?!chrome|android).)*(safari|mobile)/i.test(navigator.userAgent) && /(os |version\\/)15(.|_)4/i.test(navigator.userAgent);\n\n/**\n * The Grow transition is used by the [Tooltip](/material-ui/react-tooltip/) and\n * [Popover](/material-ui/react-popover/) components.\n * It uses [react-transition-group](https://github.com/reactjs/react-transition-group) internally.\n */\nconst Grow = /*#__PURE__*/React.forwardRef(function Grow(props, ref) {\n const {\n addEndListener,\n appear = true,\n children,\n easing,\n in: inProp,\n onEnter,\n onEntered,\n onEntering,\n onExit,\n onExited,\n onExiting,\n style,\n timeout = 'auto',\n // eslint-disable-next-line react/prop-types\n TransitionComponent = Transition\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const timer = useTimeout();\n const autoTimeout = React.useRef();\n const theme = useTheme();\n const nodeRef = React.useRef(null);\n const handleRef = useForkRef(nodeRef, children.ref, ref);\n const normalizedTransitionCallback = callback => maybeIsAppearing => {\n if (callback) {\n const node = nodeRef.current;\n\n // onEnterXxx and onExitXxx callbacks have a different arguments.length value.\n if (maybeIsAppearing === undefined) {\n callback(node);\n } else {\n callback(node, maybeIsAppearing);\n }\n }\n };\n const handleEntering = normalizedTransitionCallback(onEntering);\n const handleEnter = normalizedTransitionCallback((node, isAppearing) => {\n reflow(node); // So the animation always start from the start.\n\n const {\n duration: transitionDuration,\n delay,\n easing: transitionTimingFunction\n } = getTransitionProps({\n style,\n timeout,\n easing\n }, {\n mode: 'enter'\n });\n let duration;\n if (timeout === 'auto') {\n duration = theme.transitions.getAutoHeightDuration(node.clientHeight);\n autoTimeout.current = duration;\n } else {\n duration = transitionDuration;\n }\n node.style.transition = [theme.transitions.create('opacity', {\n duration,\n delay\n }), theme.transitions.create('transform', {\n duration: isWebKit154 ? duration : duration * 0.666,\n delay,\n easing: transitionTimingFunction\n })].join(',');\n if (onEnter) {\n onEnter(node, isAppearing);\n }\n });\n const handleEntered = normalizedTransitionCallback(onEntered);\n const handleExiting = normalizedTransitionCallback(onExiting);\n const handleExit = normalizedTransitionCallback(node => {\n const {\n duration: transitionDuration,\n delay,\n easing: transitionTimingFunction\n } = getTransitionProps({\n style,\n timeout,\n easing\n }, {\n mode: 'exit'\n });\n let duration;\n if (timeout === 'auto') {\n duration = theme.transitions.getAutoHeightDuration(node.clientHeight);\n autoTimeout.current = duration;\n } else {\n duration = transitionDuration;\n }\n node.style.transition = [theme.transitions.create('opacity', {\n duration,\n delay\n }), theme.transitions.create('transform', {\n duration: isWebKit154 ? duration : duration * 0.666,\n delay: isWebKit154 ? delay : delay || duration * 0.333,\n easing: transitionTimingFunction\n })].join(',');\n node.style.opacity = 0;\n node.style.transform = getScale(0.75);\n if (onExit) {\n onExit(node);\n }\n });\n const handleExited = normalizedTransitionCallback(onExited);\n const handleAddEndListener = next => {\n if (timeout === 'auto') {\n timer.start(autoTimeout.current || 0, next);\n }\n if (addEndListener) {\n // Old call signature before `react-transition-group` implemented `nodeRef`\n addEndListener(nodeRef.current, next);\n }\n };\n return /*#__PURE__*/_jsx(TransitionComponent, _extends({\n appear: appear,\n in: inProp,\n nodeRef: nodeRef,\n onEnter: handleEnter,\n onEntered: handleEntered,\n onEntering: handleEntering,\n onExit: handleExit,\n onExited: handleExited,\n onExiting: handleExiting,\n addEndListener: handleAddEndListener,\n timeout: timeout === 'auto' ? null : timeout\n }, other, {\n children: (state, childProps) => {\n return /*#__PURE__*/React.cloneElement(children, _extends({\n style: _extends({\n opacity: 0,\n transform: getScale(0.75),\n visibility: state === 'exited' && !inProp ? 'hidden' : undefined\n }, styles[state], style, children.props.style),\n ref: handleRef\n }, childProps));\n }\n }));\n});\nprocess.env.NODE_ENV !== \"production\" ? Grow.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the d.ts file and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * Add a custom transition end trigger. Called with the transitioning DOM\n * node and a done callback. Allows for more fine grained transition end\n * logic. Note: Timeouts are still used as a fallback if provided.\n */\n addEndListener: PropTypes.func,\n /**\n * Perform the enter transition when it first mounts if `in` is also `true`.\n * Set this to `false` to disable this behavior.\n * @default true\n */\n appear: PropTypes.bool,\n /**\n * A single child content element.\n */\n children: elementAcceptingRef.isRequired,\n /**\n * The transition timing function.\n * You may specify a single easing or a object containing enter and exit values.\n */\n easing: PropTypes.oneOfType([PropTypes.shape({\n enter: PropTypes.string,\n exit: PropTypes.string\n }), PropTypes.string]),\n /**\n * If `true`, the component will transition in.\n */\n in: PropTypes.bool,\n /**\n * @ignore\n */\n onEnter: PropTypes.func,\n /**\n * @ignore\n */\n onEntered: PropTypes.func,\n /**\n * @ignore\n */\n onEntering: PropTypes.func,\n /**\n * @ignore\n */\n onExit: PropTypes.func,\n /**\n * @ignore\n */\n onExited: PropTypes.func,\n /**\n * @ignore\n */\n onExiting: PropTypes.func,\n /**\n * @ignore\n */\n style: PropTypes.object,\n /**\n * The duration for the transition, in milliseconds.\n * You may specify a single timeout for all transitions, or individually with an object.\n *\n * Set to 'auto' to automatically calculate transition time based on height.\n * @default 'auto'\n */\n timeout: PropTypes.oneOfType([PropTypes.oneOf(['auto']), PropTypes.number, PropTypes.shape({\n appear: PropTypes.number,\n enter: PropTypes.number,\n exit: PropTypes.number\n })])\n} : void 0;\nGrow.muiSupportAuto = true;\nexport default Grow;","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"anchorEl\", \"component\", \"components\", \"componentsProps\", \"container\", \"disablePortal\", \"keepMounted\", \"modifiers\", \"open\", \"placement\", \"popperOptions\", \"popperRef\", \"transition\", \"slots\", \"slotProps\"];\nimport { Popper as BasePopper } from '@mui/base/Popper';\nimport { useThemeWithoutDefault as useTheme } from '@mui/system';\nimport { HTMLElementType, refType } from '@mui/utils';\nimport PropTypes from 'prop-types';\nimport * as React from 'react';\nimport { styled, useThemeProps } from '../styles';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nconst PopperRoot = styled(BasePopper, {\n name: 'MuiPopper',\n slot: 'Root',\n overridesResolver: (props, styles) => styles.root\n})({});\n\n/**\n *\n * Demos:\n *\n * - [Autocomplete](https://mui.com/material-ui/react-autocomplete/)\n * - [Menu](https://mui.com/material-ui/react-menu/)\n * - [Popper](https://mui.com/material-ui/react-popper/)\n *\n * API:\n *\n * - [Popper API](https://mui.com/material-ui/api/popper/)\n */\nconst Popper = /*#__PURE__*/React.forwardRef(function Popper(inProps, ref) {\n var _slots$root;\n const theme = useTheme();\n const props = useThemeProps({\n props: inProps,\n name: 'MuiPopper'\n });\n const {\n anchorEl,\n component,\n components,\n componentsProps,\n container,\n disablePortal,\n keepMounted,\n modifiers,\n open,\n placement,\n popperOptions,\n popperRef,\n transition,\n slots,\n slotProps\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const RootComponent = (_slots$root = slots == null ? void 0 : slots.root) != null ? _slots$root : components == null ? void 0 : components.Root;\n const otherProps = _extends({\n anchorEl,\n container,\n disablePortal,\n keepMounted,\n modifiers,\n open,\n placement,\n popperOptions,\n popperRef,\n transition\n }, other);\n return /*#__PURE__*/_jsx(PopperRoot, _extends({\n as: component,\n direction: theme == null ? void 0 : theme.direction,\n slots: {\n root: RootComponent\n },\n slotProps: slotProps != null ? slotProps : componentsProps\n }, otherProps, {\n ref: ref\n }));\n});\nprocess.env.NODE_ENV !== \"production\" ? Popper.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * An HTML element, [virtualElement](https://popper.js.org/docs/v2/virtual-elements/),\n * or a function that returns either.\n * It's used to set the position of the popper.\n * The return value will passed as the reference object of the Popper instance.\n */\n anchorEl: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.object, PropTypes.func]),\n /**\n * Popper render function or node.\n */\n children: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.node, PropTypes.func]),\n /**\n * The component used for the root node.\n * Either a string to use a HTML element or a component.\n */\n component: PropTypes.elementType,\n /**\n * The components used for each slot inside the Popper.\n * Either a string to use a HTML element or a component.\n * @default {}\n */\n components: PropTypes.shape({\n Root: PropTypes.elementType\n }),\n /**\n * The props used for each slot inside the Popper.\n * @default {}\n */\n componentsProps: PropTypes.shape({\n root: PropTypes.oneOfType([PropTypes.func, PropTypes.object])\n }),\n /**\n * An HTML element or function that returns one.\n * The `container` will have the portal children appended to it.\n *\n * You can also provide a callback, which is called in a React layout effect.\n * This lets you set the container from a ref, and also makes server-side rendering possible.\n *\n * By default, it uses the body of the top-level document object,\n * so it's simply `document.body` most of the time.\n */\n container: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.func]),\n /**\n * The `children` will be under the DOM hierarchy of the parent component.\n * @default false\n */\n disablePortal: PropTypes.bool,\n /**\n * Always keep the children in the DOM.\n * This prop can be useful in SEO situation or\n * when you want to maximize the responsiveness of the Popper.\n * @default false\n */\n keepMounted: PropTypes.bool,\n /**\n * Popper.js is based on a \"plugin-like\" architecture,\n * most of its features are fully encapsulated \"modifiers\".\n *\n * A modifier is a function that is called each time Popper.js needs to\n * compute the position of the popper.\n * For this reason, modifiers should be very performant to avoid bottlenecks.\n * To learn how to create a modifier, [read the modifiers documentation](https://popper.js.org/docs/v2/modifiers/).\n */\n modifiers: PropTypes.arrayOf(PropTypes.shape({\n data: PropTypes.object,\n effect: PropTypes.func,\n enabled: PropTypes.bool,\n fn: PropTypes.func,\n name: PropTypes.any,\n options: PropTypes.object,\n phase: PropTypes.oneOf(['afterMain', 'afterRead', 'afterWrite', 'beforeMain', 'beforeRead', 'beforeWrite', 'main', 'read', 'write']),\n requires: PropTypes.arrayOf(PropTypes.string),\n requiresIfExists: PropTypes.arrayOf(PropTypes.string)\n })),\n /**\n * If `true`, the component is shown.\n */\n open: PropTypes.bool.isRequired,\n /**\n * Popper placement.\n * @default 'bottom'\n */\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n /**\n * Options provided to the [`Popper.js`](https://popper.js.org/docs/v2/constructors/#options) instance.\n * @default {}\n */\n popperOptions: PropTypes.shape({\n modifiers: PropTypes.array,\n onFirstUpdate: PropTypes.func,\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n strategy: PropTypes.oneOf(['absolute', 'fixed'])\n }),\n /**\n * A ref that points to the used popper instance.\n */\n popperRef: refType,\n /**\n * The props used for each slot inside the Popper.\n * @default {}\n */\n slotProps: PropTypes.shape({\n root: PropTypes.oneOfType([PropTypes.func, PropTypes.object])\n }),\n /**\n * The components used for each slot inside the Popper.\n * Either a string to use a HTML element or a component.\n * @default {}\n */\n slots: PropTypes.shape({\n root: PropTypes.elementType\n }),\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Help supporting a react-transition-group/Transition component.\n * @default false\n */\n transition: PropTypes.bool\n} : void 0;\nexport default Popper;","import generateUtilityClasses from '@mui/utils/generateUtilityClasses';\nimport generateUtilityClass from '@mui/utils/generateUtilityClass';\nexport function getTooltipUtilityClass(slot) {\n return generateUtilityClass('MuiTooltip', slot);\n}\nconst tooltipClasses = generateUtilityClasses('MuiTooltip', ['popper', 'popperInteractive', 'popperArrow', 'popperClose', 'tooltip', 'tooltipArrow', 'touch', 'tooltipPlacementLeft', 'tooltipPlacementRight', 'tooltipPlacementTop', 'tooltipPlacementBottom', 'arrow']);\nexport default tooltipClasses;","'use client';\n\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nconst _excluded = [\"arrow\", \"children\", \"classes\", \"components\", \"componentsProps\", \"describeChild\", \"disableFocusListener\", \"disableHoverListener\", \"disableInteractive\", \"disableTouchListener\", \"enterDelay\", \"enterNextDelay\", \"enterTouchDelay\", \"followCursor\", \"id\", \"leaveDelay\", \"leaveTouchDelay\", \"onClose\", \"onOpen\", \"open\", \"placement\", \"PopperComponent\", \"PopperProps\", \"slotProps\", \"slots\", \"title\", \"TransitionComponent\", \"TransitionProps\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport clsx from 'clsx';\nimport { elementAcceptingRef, unstable_useTimeout as useTimeout, unstable_Timeout as Timeout } from '@mui/utils';\nimport { unstable_composeClasses as composeClasses, appendOwnerState } from '@mui/base';\nimport { alpha } from '@mui/system';\nimport styled from '../styles/styled';\nimport useTheme from '../styles/useTheme';\nimport useThemeProps from '../styles/useThemeProps';\nimport capitalize from '../utils/capitalize';\nimport Grow from '../Grow';\nimport Popper from '../Popper';\nimport useEventCallback from '../utils/useEventCallback';\nimport useForkRef from '../utils/useForkRef';\nimport useId from '../utils/useId';\nimport useIsFocusVisible from '../utils/useIsFocusVisible';\nimport useControlled from '../utils/useControlled';\nimport tooltipClasses, { getTooltipUtilityClass } from './tooltipClasses';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nimport { jsxs as _jsxs } from \"react/jsx-runtime\";\nfunction round(value) {\n return Math.round(value * 1e5) / 1e5;\n}\nconst useUtilityClasses = ownerState => {\n const {\n classes,\n disableInteractive,\n arrow,\n touch,\n placement\n } = ownerState;\n const slots = {\n popper: ['popper', !disableInteractive && 'popperInteractive', arrow && 'popperArrow'],\n tooltip: ['tooltip', arrow && 'tooltipArrow', touch && 'touch', `tooltipPlacement${capitalize(placement.split('-')[0])}`],\n arrow: ['arrow']\n };\n return composeClasses(slots, getTooltipUtilityClass, classes);\n};\nconst TooltipPopper = styled(Popper, {\n name: 'MuiTooltip',\n slot: 'Popper',\n overridesResolver: (props, styles) => {\n const {\n ownerState\n } = props;\n return [styles.popper, !ownerState.disableInteractive && styles.popperInteractive, ownerState.arrow && styles.popperArrow, !ownerState.open && styles.popperClose];\n }\n})(({\n theme,\n ownerState,\n open\n}) => _extends({\n zIndex: (theme.vars || theme).zIndex.tooltip,\n pointerEvents: 'none'\n}, !ownerState.disableInteractive && {\n pointerEvents: 'auto'\n}, !open && {\n pointerEvents: 'none'\n}, ownerState.arrow && {\n [`&[data-popper-placement*=\"bottom\"] .${tooltipClasses.arrow}`]: {\n top: 0,\n marginTop: '-0.71em',\n '&::before': {\n transformOrigin: '0 100%'\n }\n },\n [`&[data-popper-placement*=\"top\"] .${tooltipClasses.arrow}`]: {\n bottom: 0,\n marginBottom: '-0.71em',\n '&::before': {\n transformOrigin: '100% 0'\n }\n },\n [`&[data-popper-placement*=\"right\"] .${tooltipClasses.arrow}`]: _extends({}, !ownerState.isRtl ? {\n left: 0,\n marginLeft: '-0.71em'\n } : {\n right: 0,\n marginRight: '-0.71em'\n }, {\n height: '1em',\n width: '0.71em',\n '&::before': {\n transformOrigin: '100% 100%'\n }\n }),\n [`&[data-popper-placement*=\"left\"] .${tooltipClasses.arrow}`]: _extends({}, !ownerState.isRtl ? {\n right: 0,\n marginRight: '-0.71em'\n } : {\n left: 0,\n marginLeft: '-0.71em'\n }, {\n height: '1em',\n width: '0.71em',\n '&::before': {\n transformOrigin: '0 0'\n }\n })\n}));\nconst TooltipTooltip = styled('div', {\n name: 'MuiTooltip',\n slot: 'Tooltip',\n overridesResolver: (props, styles) => {\n const {\n ownerState\n } = props;\n return [styles.tooltip, ownerState.touch && styles.touch, ownerState.arrow && styles.tooltipArrow, styles[`tooltipPlacement${capitalize(ownerState.placement.split('-')[0])}`]];\n }\n})(({\n theme,\n ownerState\n}) => _extends({\n backgroundColor: theme.vars ? theme.vars.palette.Tooltip.bg : alpha(theme.palette.grey[700], 0.92),\n borderRadius: (theme.vars || theme).shape.borderRadius,\n color: (theme.vars || theme).palette.common.white,\n fontFamily: theme.typography.fontFamily,\n padding: '4px 8px',\n fontSize: theme.typography.pxToRem(11),\n maxWidth: 300,\n margin: 2,\n wordWrap: 'break-word',\n fontWeight: theme.typography.fontWeightMedium\n}, ownerState.arrow && {\n position: 'relative',\n margin: 0\n}, ownerState.touch && {\n padding: '8px 16px',\n fontSize: theme.typography.pxToRem(14),\n lineHeight: `${round(16 / 14)}em`,\n fontWeight: theme.typography.fontWeightRegular\n}, {\n [`.${tooltipClasses.popper}[data-popper-placement*=\"left\"] &`]: _extends({\n transformOrigin: 'right center'\n }, !ownerState.isRtl ? _extends({\n marginRight: '14px'\n }, ownerState.touch && {\n marginRight: '24px'\n }) : _extends({\n marginLeft: '14px'\n }, ownerState.touch && {\n marginLeft: '24px'\n })),\n [`.${tooltipClasses.popper}[data-popper-placement*=\"right\"] &`]: _extends({\n transformOrigin: 'left center'\n }, !ownerState.isRtl ? _extends({\n marginLeft: '14px'\n }, ownerState.touch && {\n marginLeft: '24px'\n }) : _extends({\n marginRight: '14px'\n }, ownerState.touch && {\n marginRight: '24px'\n })),\n [`.${tooltipClasses.popper}[data-popper-placement*=\"top\"] &`]: _extends({\n transformOrigin: 'center bottom',\n marginBottom: '14px'\n }, ownerState.touch && {\n marginBottom: '24px'\n }),\n [`.${tooltipClasses.popper}[data-popper-placement*=\"bottom\"] &`]: _extends({\n transformOrigin: 'center top',\n marginTop: '14px'\n }, ownerState.touch && {\n marginTop: '24px'\n })\n}));\nconst TooltipArrow = styled('span', {\n name: 'MuiTooltip',\n slot: 'Arrow',\n overridesResolver: (props, styles) => styles.arrow\n})(({\n theme\n}) => ({\n overflow: 'hidden',\n position: 'absolute',\n width: '1em',\n height: '0.71em' /* = width / sqrt(2) = (length of the hypotenuse) */,\n boxSizing: 'border-box',\n color: theme.vars ? theme.vars.palette.Tooltip.bg : alpha(theme.palette.grey[700], 0.9),\n '&::before': {\n content: '\"\"',\n margin: 'auto',\n display: 'block',\n width: '100%',\n height: '100%',\n backgroundColor: 'currentColor',\n transform: 'rotate(45deg)'\n }\n}));\nlet hystersisOpen = false;\nconst hystersisTimer = new Timeout();\nlet cursorPosition = {\n x: 0,\n y: 0\n};\nexport function testReset() {\n hystersisOpen = false;\n hystersisTimer.clear();\n}\nfunction composeEventHandler(handler, eventHandler) {\n return event => {\n if (eventHandler) {\n eventHandler(event);\n }\n handler(event);\n };\n}\n\n// TODO v6: Remove PopperComponent, PopperProps, TransitionComponent and TransitionProps.\nconst Tooltip = /*#__PURE__*/React.forwardRef(function Tooltip(inProps, ref) {\n var _ref, _slots$popper, _ref2, _ref3, _slots$transition, _ref4, _slots$tooltip, _ref5, _slots$arrow, _slotProps$popper, _ref6, _slotProps$popper2, _slotProps$transition, _slotProps$tooltip, _ref7, _slotProps$tooltip2, _slotProps$arrow, _ref8, _slotProps$arrow2;\n const props = useThemeProps({\n props: inProps,\n name: 'MuiTooltip'\n });\n const {\n arrow = false,\n children: childrenProp,\n components = {},\n componentsProps = {},\n describeChild = false,\n disableFocusListener = false,\n disableHoverListener = false,\n disableInteractive: disableInteractiveProp = false,\n disableTouchListener = false,\n enterDelay = 100,\n enterNextDelay = 0,\n enterTouchDelay = 700,\n followCursor = false,\n id: idProp,\n leaveDelay = 0,\n leaveTouchDelay = 1500,\n onClose,\n onOpen,\n open: openProp,\n placement = 'bottom',\n PopperComponent: PopperComponentProp,\n PopperProps = {},\n slotProps = {},\n slots = {},\n title,\n TransitionComponent: TransitionComponentProp = Grow,\n TransitionProps\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n\n // to prevent runtime errors, developers will need to provide a child as a React element anyway.\n const children = /*#__PURE__*/React.isValidElement(childrenProp) ? childrenProp : /*#__PURE__*/_jsx(\"span\", {\n children: childrenProp\n });\n const theme = useTheme();\n const isRtl = theme.direction === 'rtl';\n const [childNode, setChildNode] = React.useState();\n const [arrowRef, setArrowRef] = React.useState(null);\n const ignoreNonTouchEvents = React.useRef(false);\n const disableInteractive = disableInteractiveProp || followCursor;\n const closeTimer = useTimeout();\n const enterTimer = useTimeout();\n const leaveTimer = useTimeout();\n const touchTimer = useTimeout();\n const [openState, setOpenState] = useControlled({\n controlled: openProp,\n default: false,\n name: 'Tooltip',\n state: 'open'\n });\n let open = openState;\n if (process.env.NODE_ENV !== 'production') {\n // eslint-disable-next-line react-hooks/rules-of-hooks\n const {\n current: isControlled\n } = React.useRef(openProp !== undefined);\n\n // eslint-disable-next-line react-hooks/rules-of-hooks\n React.useEffect(() => {\n if (childNode && childNode.disabled && !isControlled && title !== '' && childNode.tagName.toLowerCase() === 'button') {\n console.error(['MUI: You are providing a disabled `button` child to the Tooltip component.', 'A disabled element does not fire events.', \"Tooltip needs to listen to the child element's events to display the title.\", '', 'Add a simple wrapper element, such as a `span`.'].join('\\n'));\n }\n }, [title, childNode, isControlled]);\n }\n const id = useId(idProp);\n const prevUserSelect = React.useRef();\n const stopTouchInteraction = useEventCallback(() => {\n if (prevUserSelect.current !== undefined) {\n document.body.style.WebkitUserSelect = prevUserSelect.current;\n prevUserSelect.current = undefined;\n }\n touchTimer.clear();\n });\n React.useEffect(() => stopTouchInteraction, [stopTouchInteraction]);\n const handleOpen = event => {\n hystersisTimer.clear();\n hystersisOpen = true;\n\n // The mouseover event will trigger for every nested element in the tooltip.\n // We can skip rerendering when the tooltip is already open.\n // We are using the mouseover event instead of the mouseenter event to fix a hide/show issue.\n setOpenState(true);\n if (onOpen && !open) {\n onOpen(event);\n }\n };\n const handleClose = useEventCallback(\n /**\n * @param {React.SyntheticEvent | Event} event\n */\n event => {\n hystersisTimer.start(800 + leaveDelay, () => {\n hystersisOpen = false;\n });\n setOpenState(false);\n if (onClose && open) {\n onClose(event);\n }\n closeTimer.start(theme.transitions.duration.shortest, () => {\n ignoreNonTouchEvents.current = false;\n });\n });\n const handleEnter = event => {\n if (ignoreNonTouchEvents.current && event.type !== 'touchstart') {\n return;\n }\n\n // Remove the title ahead of time.\n // We don't want to wait for the next render commit.\n // We would risk displaying two tooltips at the same time (native + this one).\n if (childNode) {\n childNode.removeAttribute('title');\n }\n enterTimer.clear();\n leaveTimer.clear();\n if (enterDelay || hystersisOpen && enterNextDelay) {\n enterTimer.start(hystersisOpen ? enterNextDelay : enterDelay, () => {\n handleOpen(event);\n });\n } else {\n handleOpen(event);\n }\n };\n const handleLeave = event => {\n enterTimer.clear();\n leaveTimer.start(leaveDelay, () => {\n handleClose(event);\n });\n };\n const {\n isFocusVisibleRef,\n onBlur: handleBlurVisible,\n onFocus: handleFocusVisible,\n ref: focusVisibleRef\n } = useIsFocusVisible();\n // We don't necessarily care about the focusVisible state (which is safe to access via ref anyway).\n // We just need to re-render the Tooltip if the focus-visible state changes.\n const [, setChildIsFocusVisible] = React.useState(false);\n const handleBlur = event => {\n handleBlurVisible(event);\n if (isFocusVisibleRef.current === false) {\n setChildIsFocusVisible(false);\n handleLeave(event);\n }\n };\n const handleFocus = event => {\n // Workaround for https://github.com/facebook/react/issues/7769\n // The autoFocus of React might trigger the event before the componentDidMount.\n // We need to account for this eventuality.\n if (!childNode) {\n setChildNode(event.currentTarget);\n }\n handleFocusVisible(event);\n if (isFocusVisibleRef.current === true) {\n setChildIsFocusVisible(true);\n handleEnter(event);\n }\n };\n const detectTouchStart = event => {\n ignoreNonTouchEvents.current = true;\n const childrenProps = children.props;\n if (childrenProps.onTouchStart) {\n childrenProps.onTouchStart(event);\n }\n };\n const handleMouseOver = handleEnter;\n const handleMouseLeave = handleLeave;\n const handleTouchStart = event => {\n detectTouchStart(event);\n leaveTimer.clear();\n closeTimer.clear();\n stopTouchInteraction();\n prevUserSelect.current = document.body.style.WebkitUserSelect;\n // Prevent iOS text selection on long-tap.\n document.body.style.WebkitUserSelect = 'none';\n touchTimer.start(enterTouchDelay, () => {\n document.body.style.WebkitUserSelect = prevUserSelect.current;\n handleEnter(event);\n });\n };\n const handleTouchEnd = event => {\n if (children.props.onTouchEnd) {\n children.props.onTouchEnd(event);\n }\n stopTouchInteraction();\n leaveTimer.start(leaveTouchDelay, () => {\n handleClose(event);\n });\n };\n React.useEffect(() => {\n if (!open) {\n return undefined;\n }\n\n /**\n * @param {KeyboardEvent} nativeEvent\n */\n function handleKeyDown(nativeEvent) {\n // IE11, Edge (prior to using Bink?) use 'Esc'\n if (nativeEvent.key === 'Escape' || nativeEvent.key === 'Esc') {\n handleClose(nativeEvent);\n }\n }\n document.addEventListener('keydown', handleKeyDown);\n return () => {\n document.removeEventListener('keydown', handleKeyDown);\n };\n }, [handleClose, open]);\n const handleRef = useForkRef(children.ref, focusVisibleRef, setChildNode, ref);\n\n // There is no point in displaying an empty tooltip.\n // So we exclude all falsy values, except 0, which is valid.\n if (!title && title !== 0) {\n open = false;\n }\n const popperRef = React.useRef();\n const handleMouseMove = event => {\n const childrenProps = children.props;\n if (childrenProps.onMouseMove) {\n childrenProps.onMouseMove(event);\n }\n cursorPosition = {\n x: event.clientX,\n y: event.clientY\n };\n if (popperRef.current) {\n popperRef.current.update();\n }\n };\n const nameOrDescProps = {};\n const titleIsString = typeof title === 'string';\n if (describeChild) {\n nameOrDescProps.title = !open && titleIsString && !disableHoverListener ? title : null;\n nameOrDescProps['aria-describedby'] = open ? id : null;\n } else {\n nameOrDescProps['aria-label'] = titleIsString ? title : null;\n nameOrDescProps['aria-labelledby'] = open && !titleIsString ? id : null;\n }\n const childrenProps = _extends({}, nameOrDescProps, other, children.props, {\n className: clsx(other.className, children.props.className),\n onTouchStart: detectTouchStart,\n ref: handleRef\n }, followCursor ? {\n onMouseMove: handleMouseMove\n } : {});\n if (process.env.NODE_ENV !== 'production') {\n childrenProps['data-mui-internal-clone-element'] = true;\n\n // eslint-disable-next-line react-hooks/rules-of-hooks\n React.useEffect(() => {\n if (childNode && !childNode.getAttribute('data-mui-internal-clone-element')) {\n console.error(['MUI: The `children` component of the Tooltip is not forwarding its props correctly.', 'Please make sure that props are spread on the same element that the ref is applied to.'].join('\\n'));\n }\n }, [childNode]);\n }\n const interactiveWrapperListeners = {};\n if (!disableTouchListener) {\n childrenProps.onTouchStart = handleTouchStart;\n childrenProps.onTouchEnd = handleTouchEnd;\n }\n if (!disableHoverListener) {\n childrenProps.onMouseOver = composeEventHandler(handleMouseOver, childrenProps.onMouseOver);\n childrenProps.onMouseLeave = composeEventHandler(handleMouseLeave, childrenProps.onMouseLeave);\n if (!disableInteractive) {\n interactiveWrapperListeners.onMouseOver = handleMouseOver;\n interactiveWrapperListeners.onMouseLeave = handleMouseLeave;\n }\n }\n if (!disableFocusListener) {\n childrenProps.onFocus = composeEventHandler(handleFocus, childrenProps.onFocus);\n childrenProps.onBlur = composeEventHandler(handleBlur, childrenProps.onBlur);\n if (!disableInteractive) {\n interactiveWrapperListeners.onFocus = handleFocus;\n interactiveWrapperListeners.onBlur = handleBlur;\n }\n }\n if (process.env.NODE_ENV !== 'production') {\n if (children.props.title) {\n console.error(['MUI: You have provided a `title` prop to the child of .', `Remove this title prop \\`${children.props.title}\\` or the Tooltip component.`].join('\\n'));\n }\n }\n const popperOptions = React.useMemo(() => {\n var _PopperProps$popperOp;\n let tooltipModifiers = [{\n name: 'arrow',\n enabled: Boolean(arrowRef),\n options: {\n element: arrowRef,\n padding: 4\n }\n }];\n if ((_PopperProps$popperOp = PopperProps.popperOptions) != null && _PopperProps$popperOp.modifiers) {\n tooltipModifiers = tooltipModifiers.concat(PopperProps.popperOptions.modifiers);\n }\n return _extends({}, PopperProps.popperOptions, {\n modifiers: tooltipModifiers\n });\n }, [arrowRef, PopperProps]);\n const ownerState = _extends({}, props, {\n isRtl,\n arrow,\n disableInteractive,\n placement,\n PopperComponentProp,\n touch: ignoreNonTouchEvents.current\n });\n const classes = useUtilityClasses(ownerState);\n const PopperComponent = (_ref = (_slots$popper = slots.popper) != null ? _slots$popper : components.Popper) != null ? _ref : TooltipPopper;\n const TransitionComponent = (_ref2 = (_ref3 = (_slots$transition = slots.transition) != null ? _slots$transition : components.Transition) != null ? _ref3 : TransitionComponentProp) != null ? _ref2 : Grow;\n const TooltipComponent = (_ref4 = (_slots$tooltip = slots.tooltip) != null ? _slots$tooltip : components.Tooltip) != null ? _ref4 : TooltipTooltip;\n const ArrowComponent = (_ref5 = (_slots$arrow = slots.arrow) != null ? _slots$arrow : components.Arrow) != null ? _ref5 : TooltipArrow;\n const popperProps = appendOwnerState(PopperComponent, _extends({}, PopperProps, (_slotProps$popper = slotProps.popper) != null ? _slotProps$popper : componentsProps.popper, {\n className: clsx(classes.popper, PopperProps == null ? void 0 : PopperProps.className, (_ref6 = (_slotProps$popper2 = slotProps.popper) != null ? _slotProps$popper2 : componentsProps.popper) == null ? void 0 : _ref6.className)\n }), ownerState);\n const transitionProps = appendOwnerState(TransitionComponent, _extends({}, TransitionProps, (_slotProps$transition = slotProps.transition) != null ? _slotProps$transition : componentsProps.transition), ownerState);\n const tooltipProps = appendOwnerState(TooltipComponent, _extends({}, (_slotProps$tooltip = slotProps.tooltip) != null ? _slotProps$tooltip : componentsProps.tooltip, {\n className: clsx(classes.tooltip, (_ref7 = (_slotProps$tooltip2 = slotProps.tooltip) != null ? _slotProps$tooltip2 : componentsProps.tooltip) == null ? void 0 : _ref7.className)\n }), ownerState);\n const tooltipArrowProps = appendOwnerState(ArrowComponent, _extends({}, (_slotProps$arrow = slotProps.arrow) != null ? _slotProps$arrow : componentsProps.arrow, {\n className: clsx(classes.arrow, (_ref8 = (_slotProps$arrow2 = slotProps.arrow) != null ? _slotProps$arrow2 : componentsProps.arrow) == null ? void 0 : _ref8.className)\n }), ownerState);\n return /*#__PURE__*/_jsxs(React.Fragment, {\n children: [/*#__PURE__*/React.cloneElement(children, childrenProps), /*#__PURE__*/_jsx(PopperComponent, _extends({\n as: PopperComponentProp != null ? PopperComponentProp : Popper,\n placement: placement,\n anchorEl: followCursor ? {\n getBoundingClientRect: () => ({\n top: cursorPosition.y,\n left: cursorPosition.x,\n right: cursorPosition.x,\n bottom: cursorPosition.y,\n width: 0,\n height: 0\n })\n } : childNode,\n popperRef: popperRef,\n open: childNode ? open : false,\n id: id,\n transition: true\n }, interactiveWrapperListeners, popperProps, {\n popperOptions: popperOptions,\n children: ({\n TransitionProps: TransitionPropsInner\n }) => /*#__PURE__*/_jsx(TransitionComponent, _extends({\n timeout: theme.transitions.duration.shorter\n }, TransitionPropsInner, transitionProps, {\n children: /*#__PURE__*/_jsxs(TooltipComponent, _extends({}, tooltipProps, {\n children: [title, arrow ? /*#__PURE__*/_jsx(ArrowComponent, _extends({}, tooltipArrowProps, {\n ref: setArrowRef\n })) : null]\n }))\n }))\n }))]\n });\n});\nprocess.env.NODE_ENV !== \"production\" ? Tooltip.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the d.ts file and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * If `true`, adds an arrow to the tooltip.\n * @default false\n */\n arrow: PropTypes.bool,\n /**\n * Tooltip reference element.\n */\n children: elementAcceptingRef.isRequired,\n /**\n * Override or extend the styles applied to the component.\n */\n classes: PropTypes.object,\n /**\n * @ignore\n */\n className: PropTypes.string,\n /**\n * The components used for each slot inside.\n *\n * This prop is an alias for the `slots` prop.\n * It's recommended to use the `slots` prop instead.\n *\n * @default {}\n */\n components: PropTypes.shape({\n Arrow: PropTypes.elementType,\n Popper: PropTypes.elementType,\n Tooltip: PropTypes.elementType,\n Transition: PropTypes.elementType\n }),\n /**\n * The extra props for the slot components.\n * You can override the existing props or add new ones.\n *\n * This prop is an alias for the `slotProps` prop.\n * It's recommended to use the `slotProps` prop instead, as `componentsProps` will be deprecated in the future.\n *\n * @default {}\n */\n componentsProps: PropTypes.shape({\n arrow: PropTypes.object,\n popper: PropTypes.object,\n tooltip: PropTypes.object,\n transition: PropTypes.object\n }),\n /**\n * Set to `true` if the `title` acts as an accessible description.\n * By default the `title` acts as an accessible label for the child.\n * @default false\n */\n describeChild: PropTypes.bool,\n /**\n * Do not respond to focus-visible events.\n * @default false\n */\n disableFocusListener: PropTypes.bool,\n /**\n * Do not respond to hover events.\n * @default false\n */\n disableHoverListener: PropTypes.bool,\n /**\n * Makes a tooltip not interactive, i.e. it will close when the user\n * hovers over the tooltip before the `leaveDelay` is expired.\n * @default false\n */\n disableInteractive: PropTypes.bool,\n /**\n * Do not respond to long press touch events.\n * @default false\n */\n disableTouchListener: PropTypes.bool,\n /**\n * The number of milliseconds to wait before showing the tooltip.\n * This prop won't impact the enter touch delay (`enterTouchDelay`).\n * @default 100\n */\n enterDelay: PropTypes.number,\n /**\n * The number of milliseconds to wait before showing the tooltip when one was already recently opened.\n * @default 0\n */\n enterNextDelay: PropTypes.number,\n /**\n * The number of milliseconds a user must touch the element before showing the tooltip.\n * @default 700\n */\n enterTouchDelay: PropTypes.number,\n /**\n * If `true`, the tooltip follow the cursor over the wrapped element.\n * @default false\n */\n followCursor: PropTypes.bool,\n /**\n * This prop is used to help implement the accessibility logic.\n * If you don't provide this prop. It falls back to a randomly generated id.\n */\n id: PropTypes.string,\n /**\n * The number of milliseconds to wait before hiding the tooltip.\n * This prop won't impact the leave touch delay (`leaveTouchDelay`).\n * @default 0\n */\n leaveDelay: PropTypes.number,\n /**\n * The number of milliseconds after the user stops touching an element before hiding the tooltip.\n * @default 1500\n */\n leaveTouchDelay: PropTypes.number,\n /**\n * Callback fired when the component requests to be closed.\n *\n * @param {React.SyntheticEvent} event The event source of the callback.\n */\n onClose: PropTypes.func,\n /**\n * Callback fired when the component requests to be open.\n *\n * @param {React.SyntheticEvent} event The event source of the callback.\n */\n onOpen: PropTypes.func,\n /**\n * If `true`, the component is shown.\n */\n open: PropTypes.bool,\n /**\n * Tooltip placement.\n * @default 'bottom'\n */\n placement: PropTypes.oneOf(['bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n /**\n * The component used for the popper.\n * @default Popper\n */\n PopperComponent: PropTypes.elementType,\n /**\n * Props applied to the [`Popper`](/material-ui/api/popper/) element.\n * @default {}\n */\n PopperProps: PropTypes.object,\n /**\n * The extra props for the slot components.\n * You can override the existing props or add new ones.\n *\n * This prop is an alias for the `componentsProps` prop, which will be deprecated in the future.\n *\n * @default {}\n */\n slotProps: PropTypes.shape({\n arrow: PropTypes.object,\n popper: PropTypes.object,\n tooltip: PropTypes.object,\n transition: PropTypes.object\n }),\n /**\n * The components used for each slot inside.\n *\n * This prop is an alias for the `components` prop, which will be deprecated in the future.\n *\n * @default {}\n */\n slots: PropTypes.shape({\n arrow: PropTypes.elementType,\n popper: PropTypes.elementType,\n tooltip: PropTypes.elementType,\n transition: PropTypes.elementType\n }),\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Tooltip title. Zero-length titles string, undefined, null and false are never displayed.\n */\n title: PropTypes.node,\n /**\n * The component used for the transition.\n * [Follow this guide](/material-ui/transitions/#transitioncomponent-prop) to learn more about the requirements for this component.\n * @default Grow\n */\n TransitionComponent: PropTypes.elementType,\n /**\n * Props applied to the transition element.\n * By default, the element is based on this [`Transition`](http://reactcommunity.org/react-transition-group/transition/) component.\n */\n TransitionProps: PropTypes.object\n} : void 0;\nexport default Tooltip;","import '@/components/mui/menu-item.component.css';\nimport ArrowRightIcon from '@mui/icons-material/ArrowRight';\nimport {\n ListItemIcon as MuiListItemIcon,\n ListItemText as MuiListItemText,\n MenuItem as MuiMenuItem,\n} from '@mui/material';\nimport Tooltip from '@mui/material/Tooltip';\nimport { Localized, ReferencedItem, SingleColumnMenu } from 'platform-bible-utils';\nimport { MouseEvent, PropsWithChildren } from 'react';\n\ntype MenuItemInfoBase = {\n /** Text (displayable in the UI) as the name of the menu item */\n label: string;\n /** Text to display when the mouse hovers over the menu item */\n tooltip?: string;\n};\n\nexport type Command = MenuItemInfoBase & {\n /** Command to execute (string.string) */\n command: string;\n};\n\ntype SubMenu = MenuItemInfoBase & {\n /** Command to execute (string.string) */\n items: MenuItemInfo[];\n};\n\nexport interface CommandHandler {\n (command: Command): void;\n}\n\nexport type MenuPropsBase = {\n /*\n * The JSON defining the menu whose items are to be rendered. This will typically be one of the\n * menus in the \"defs\" in a Platform.Bible menu (see PlatformMenus). The schema for this is\n * menuDocumentSchema (at the end of menus.model.ts). Note that while this is a\n * \"SingleColumnMenu\", somewhat bizarrely, a MultiColumnMenu is a SingleColumnMenu, so it really\n * could be a MultiColumnMenu, in which case, column had better be defined so it can be used\n * to filter out the actual groups and items to display on the column.\n */\n menuDefinition: Localized;\n\n commandHandler: CommandHandler;\n\n /**\n * Additional action to perform when any menu item is clicked. Allows the caller to handle event\n * (e.g., to close the menu).\n */\n onClick?: (event: MouseEvent) => void;\n};\n\nexport type MenuItemListProps = MenuPropsBase & {\n /** Optional unique (column) identifier */\n columnId?: ReferencedItem;\n};\n\nexport type MenuItemProps = Omit &\n PropsWithChildren<{\n /** Optional unique identifier */\n id?: string;\n\n onClick: (event: MouseEvent) => void;\n }>;\n\ntype MenuItemInfo = (Command | SubMenu) & {\n /**\n * If specified, menu item will be inset if it does not have a leading icon.\n *\n * @default true\n */\n allowForLeadingIcons?: boolean;\n /**\n * If specified, the path to the icon image to display on the leading side of the menu text.\n *\n * @default undefined (no leading icon will be shown)\n */\n iconPathBefore?: string;\n /**\n * If specified, the path to the icon image to display on the trailing side of the menu text.\n *\n * @default undefined (no trailing icon will be shown)\n */\n iconPathAfter?: string;\n /**\n * If true, list item is focused during the first mount\n *\n * @default false\n */\n hasAutoFocus?: boolean;\n\n /** Additional css classes to help with unique styling of the menu item */\n className?: string;\n\n /**\n * If true, the menu item will appear disabled and it will not respond to clicks or mouse hovers.\n *\n * @default false\n */\n isDisabled?: boolean;\n\n /**\n * If true, compact vertical padding designed for keyboard and mouse input is used.\n *\n * @default true\n */\n isDense?: boolean;\n\n /**\n * If true, a right-arrow icon will be displayed (iconPathAfter, if specified, will be ignored).\n *\n * @default false\n */\n isSubMenuParent?: boolean;\n\n /**\n * If true, the left and right padding is removed\n *\n * @default false\n */\n hasDisabledGutters?: boolean;\n\n /**\n * If true, a 1px light border is added to bottom of menu item\n *\n * @default false\n */\n hasDivider?: boolean;\n\n /** Help identify which element has keyboard focus */\n focusVisibleClassName?: string;\n\n /** If it's a submenu, it should have the items property */\n items?: MenuItemInfo[];\n};\n\nfunction getIcon(icon: string | undefined, menuLabel: string, leading: boolean) {\n return icon ? (\n \n {`${leading\n \n ) : undefined;\n}\n\nexport default function MenuItem(props: MenuItemProps) {\n const {\n onClick,\n label,\n tooltip,\n allowForLeadingIcons = true,\n iconPathBefore = undefined,\n iconPathAfter = undefined,\n hasAutoFocus = false,\n className,\n isDisabled = false,\n isDense = true,\n isSubMenuParent = false,\n hasDisabledGutters = false,\n hasDivider = false,\n focusVisibleClassName,\n id,\n children,\n } = props;\n\n const menuItem = (\n \n {label ? (\n <>\n {getIcon(iconPathBefore, label, true)}\n \n {isSubMenuParent ? (\n \n \n \n ) : (\n getIcon(iconPathAfter, label, false)\n )}\n \n ) : (\n children\n )}\n \n );\n\n return tooltip ? (\n \n
    {menuItem}
    \n
    \n ) : (\n menuItem\n );\n}\n","import MenuItem, {\n MenuItemListProps,\n MenuItemProps,\n MenuPropsBase,\n} from '@/components/mui/menu-item.component';\nimport { Menu } from '@mui/material';\nimport {\n Localized,\n MenuGroupDetailsInSubMenu,\n MenuItemContainingCommand,\n MenuItemContainingSubmenu,\n OrderedExtensibleContainer,\n ReferencedItem,\n SingleColumnMenu,\n} from 'platform-bible-utils';\nimport { MouseEvent, useMemo, useState } from 'react';\n\n/**\n * All the exported types in this file should be regarded as \"internal\" (i.e., they should not be\n * exposed via index.ts).\n */\n\nexport type GroupedMenuPropsBase = MenuPropsBase & {\n /** Optional unique (column) identifier */\n columnId?: ReferencedItem;\n};\n\nexport type GroupedMenuItemListProps = MenuItemListProps & {\n /**\n * If the menuDefinition includes \"top-level\" groups (i.e., those that belong to a column as\n * opposed to those that belong to a submenu) that should not be included in the list, then this\n * array specifies which groups to include. Likewise, for a submenu, this list indicates which\n * groups are pertinent for that submenu. So then for a context menu this property need not be\n * specified since it is a top-level menu based on a \"true\" SingleColumnMenu (i.e., one that is\n * not a MultiColumnMenu).\n */\n includedGroups?: {\n id: string;\n group: Localized;\n }[];\n};\n\ninterface ItemInfo {\n item: Localized;\n isLastItemInGroup: boolean;\n}\n\ntype SubMenuProps = MenuPropsBase & {\n parentMenuItem: Localized;\n parentItemProps: Omit, 'iconPathAfter'>;\n};\n\nfunction getAllGroups(menuDefinition: Localized) {\n const groupEntries = Object.entries(menuDefinition.groups);\n // Convert array of entries to array of objects with id and group properties\n return groupEntries.map(([key, value]) => ({ id: key, group: value }));\n}\n\nfunction SubMenu(props: SubMenuProps) {\n const [anchorEl, setAnchorEl] = useState(undefined);\n\n const { parentMenuItem, parentItemProps, menuDefinition } = props;\n\n const handleParentMenuItemClick = (event: MouseEvent) => {\n setAnchorEl(event.currentTarget);\n };\n\n const handleClose = () => {\n setAnchorEl(undefined);\n };\n\n const renderSubMenuItems = () => {\n let includedGroups = getAllGroups(menuDefinition).filter((g) => 'menuItem' in g.group);\n\n // Ensure valid parent menu was provided. (If not, submenu will contain all groups!)\n if (!parentMenuItem?.id) throw new Error('A valid parent menu item is required for submenus.');\n\n // When laying out a submenu, only include groups associated with the provided parent menu.\n // Note: without the (annoying) redundant check that the included groups\n // have the menuItem field, TS doesn't think it exists.\n includedGroups = includedGroups.filter(\n (group) => 'menuItem' in group.group && group.group.menuItem === parentMenuItem.id,\n );\n\n return ;\n };\n\n return (\n <>\n \n \n {renderSubMenuItems()}\n \n \n );\n}\n\nconst getOrderedGroupItems = (\n groupId: string,\n allItems: Localized[],\n) => {\n // Filter items that belong to the specified group\n const itemsForGroup = allItems.filter((item) => item.group === groupId);\n // Sort items based on order\n const sortedItems = itemsForGroup.sort((a, b) => (a.order || 0) - (b.order || 0));\n return sortedItems;\n};\n\n/**\n * This component is internal; it does not need to be exposed to the outside world since it is not\n * useful on its own. It is used to generate and lay out the MenuItems that appear either on a\n * top-level menu (in a GridMenu or ContextMenu) or in a submenu.\n */\nexport default function GroupedMenuItemList(menuProps: GroupedMenuItemListProps) {\n const { menuDefinition, onClick, commandHandler, includedGroups } = menuProps;\n\n const { items, allowForLeadingIcons } = useMemo(() => {\n const groupsToInclude =\n includedGroups && includedGroups.length > 0\n ? includedGroups\n : // We're apparently laying out a single-column menu (presumably a context menu). In this\n // case, all groups should be included except ones that belong to a submenu.\n getAllGroups(menuDefinition).filter((g) => !('menuItem' in g.group));\n\n const sortedGroups = Object.values(groupsToInclude).sort(\n (a, b) => (a.group.order || 0) - (b.group.order || 0),\n );\n\n const itemArray: ItemInfo[] = [];\n\n sortedGroups.forEach((group) => {\n getOrderedGroupItems(group.id, menuDefinition.items).forEach((item) =>\n itemArray.push({ item, isLastItemInGroup: false }),\n );\n if (itemArray.length > 0) itemArray[itemArray.length - 1].isLastItemInGroup = true;\n });\n\n // No divider after last item in final group.\n if (itemArray.length > 0) itemArray[itemArray.length - 1].isLastItemInGroup = false;\n\n const allowSpaceForLeadingIcons = itemArray.some(\n (i) => 'iconPathBefore' in i.item && i.item.iconPathBefore,\n );\n\n return { items: itemArray, allowForLeadingIcons: allowSpaceForLeadingIcons };\n }, [includedGroups, menuDefinition]);\n\n // Create props for MenuItem component including setting hasDivider for the last item in a group\n const createMenuItemProps = ({ item, isLastItemInGroup }: ItemInfo) => {\n const menuItemProps = {\n className: 'papi-menu-item',\n label: item.label,\n tooltip: item.tooltip,\n iconPathBefore: 'iconPathBefore' in item ? item.iconPathBefore : undefined,\n iconPathAfter: 'iconPathAfter' in item ? item.iconPathAfter : undefined,\n hasDivider: isLastItemInGroup, // Set hasDivider to true for the last item in a group\n allowForLeadingIcons,\n };\n\n return menuItemProps;\n };\n\n const [firstItem] = items;\n\n if (!firstItem) return
    ;\n\n const divKey = firstItem.item.group;\n\n return (\n
    \n {items.map((itemInfo, index) => {\n const { item } = itemInfo;\n const menuItemProps = createMenuItemProps(itemInfo);\n if ('command' in item) {\n const key = item.group + index;\n return (\n ) => {\n onClick?.(event);\n commandHandler(item);\n }}\n {...menuItemProps}\n />\n );\n }\n return (\n \n );\n })}\n
    \n );\n}\n","import GroupedMenuItemList from '@/components/mui/grouped-menu-item-list.component';\nimport { MenuItemListProps } from '@/components/mui/menu-item.component';\nimport { MultiColumnMenu } from 'platform-bible-utils';\n\n/**\n * This component is internal; it does not need to be exposed to the outside world since it is not\n * useful on its own. Use either GridMenu or ContextMenu.\n */\nexport default function TopLevelMenu(props: MenuItemListProps) {\n const { menuDefinition, columnId } = props;\n\n const groupEntries = Object.entries(menuDefinition.groups);\n // Convert array of entries to array of objects with id and group properties\n const groups = groupEntries.map(([key, value]) => ({ id: key, group: value }));\n let includedGroups = groups.filter((g) => 'column' in g.group);\n\n // Check if column is provided and menuDefinition is a MultiColumnMenu\n if (\n columnId &&\n 'columns' in menuDefinition &&\n // Without this type assertion, TS doesn't know what columns is.\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n (menuDefinition as MultiColumnMenu).columns[columnId]\n ) {\n // When laying out a single column in a MultiColumnMenu, only include groups associated with\n // the provided column. Note: without the (annoying) redundant check that the included groups\n // have the colum field, TS doesn't think it exists.\n includedGroups = includedGroups.filter(\n (g) => 'column' in g.group && g.group.column === columnId,\n );\n }\n\n return ;\n}\n","import '@/components/mui/grid-menu.component.css';\nimport { GroupedMenuPropsBase } from '@/components/mui/grouped-menu-item-list.component';\nimport { CommandHandler } from '@/components/mui/menu-item.component';\nimport TopLevelMenu from '@/components/mui/top-level-menu.component';\nimport { Grid, List } from '@mui/material';\nimport {\n Localized,\n MenuColumnWithHeader,\n MultiColumnMenu,\n ReferencedItem,\n} from 'platform-bible-utils';\nimport { useMemo } from 'react';\n\ntype ColumnInfo = {\n /*\n * The ID (`${string}.${string}`) of a specific menu column.\n */\n id: ReferencedItem;\n\n /*\n * Metadata (label, order, etc.) for a specific menu column.\n */\n metadata: Localized;\n};\n\ntype MenuColumnProps = ColumnInfo &\n GroupedMenuPropsBase & {\n /** Additional css classes to help with unique styling of the menu column */\n className?: string;\n };\n\nexport type GridMenuInfo = {\n /** The menu object containing information about the columns, groups, and items to display. */\n multiColumnMenu: Localized;\n};\n\nexport type GridMenuProps = GridMenuInfo & {\n /** Optional unique identifier */\n id?: string;\n\n commandHandler: CommandHandler;\n\n /** Additional css classes to help with unique styling of the grid menu */\n className?: string;\n};\n\nfunction MenuColumn({\n commandHandler,\n menuDefinition,\n id,\n metadata,\n onClick,\n className,\n}: MenuColumnProps) {\n return (\n \n

    \n {metadata.label}\n

    \n {/* It would seem as though this List component were unnecessary, since it only contains one\n thing, but the \"dense\" property does affect the layout of the items (in a way I don't fully\n understand). There might be a better way. */}\n \n \n \n \n );\n}\n\nexport default function GridMenu({\n commandHandler,\n className,\n multiColumnMenu,\n id,\n}: GridMenuProps) {\n const { columns } = multiColumnMenu;\n\n const sortedColumns = useMemo(() => {\n const columnNumbers = new Map();\n Object.getOwnPropertyNames(columns).forEach((columnName: string) => {\n // We know for sure there is a (boolean) property 'isExtensible' that we are not interested in.\n if (columnName === 'isExtensible') return;\n // TS doesn't allow `columnName` above to be a ReferencedItem even though the type says it is\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const columnId = columnName as ReferencedItem;\n const column = columns[columnId];\n // As of right now (and hopefully forever after), all remaining properties of the\n // ColumnsWithHeaders object are columns whose property names are the IDs of the columns.\n // This is an additional (redundant) sanity check. Specifically we're interested in\n // MenuColumnWithHeader objects, which TypeScript now \"knows\" we have, but at runtime all we\n // can check for is that it's an object with a valid numeric order field. That's likely good\n // enough.\n if (\n typeof column === 'object' &&\n typeof column.order === 'number' &&\n !Number.isNaN(column.order)\n )\n columnNumbers.set(column.order, { id: columnId, metadata: column });\n else\n console.warn(\n `Property ${columnName} (${typeof column}) on menu ${id} is not a valid column and is being ignored. This might indicate data corruption`,\n );\n });\n\n // Extract values and sort them based on the 'order' property\n return Array.from(columnNumbers.values()).sort((a, b) => {\n return (a.metadata.order || 0) - (b.metadata.order || 0);\n });\n }, [columns, id]);\n\n // We might need something like this if we need to be able to prevent empty columns\n // sortedColumns.filter((c) => multiColumnMenu.groups.some((g) => 'column' in g && (g as .column)...\n\n return (\n \n {sortedColumns.map((col, index) => (\n \n ))}\n \n );\n}\n","import { useEffect, useRef, useState } from 'react';\n\nexport type UsePromiseOptions = {\n /**\n * Whether to leave the value as the most recent resolved promise value or set it back to\n * defaultValue while running the promise again. Defaults to true\n */\n preserveValue?: boolean;\n};\n\n/** Set up defaults for options for usePromise hook */\nfunction getUsePromiseOptionsDefaults(options: UsePromiseOptions): UsePromiseOptions {\n return {\n preserveValue: true,\n ...options,\n };\n}\n\n/**\n * Awaits a promise and returns a loading value while the promise is unresolved\n *\n * @param promiseFactoryCallback A function that returns the promise to await. If this callback is\n * undefined, the current value will be returned (defaultValue unless it was previously changed\n * and `options.preserveValue` is true), and there will be no loading.\n *\n * WARNING: MUST BE STABLE - const or wrapped in useCallback. The reference must not be updated\n * every render\n * @param defaultValue The initial value to return while first awaiting the promise. If\n * `options.preserveValue` is false, this value is also shown while awaiting the promise on\n * subsequent calls.\n *\n * Note: this parameter is internally assigned to a `ref`, so changing it will not cause any hooks\n * to re-run with its new value. This means that, if the `promiseFactoryCallback` changes and\n * `options.preserveValue` is `false`, the returned value will be set to the current\n * `defaultValue`. However, the returned value will not be updated if`defaultValue` changes.\n * @param options Various options for adjusting how this hook runs the `promiseFactoryCallback`\n *\n * Note: this parameter is internally assigned to a `ref`, so changing it will not cause any hooks\n * to re-run with its new value. However, the latest `options.preserveValue` will always be used\n * appropriately to determine whether to preserve the returned value when changing the\n * `promiseFactoryCallback`\n * @returns `[value, isLoading]`\n *\n * - `value`: the current value for the promise, either the defaultValue or the resolved promise value\n * - `isLoading`: whether the promise is waiting to be resolved\n */\nconst usePromise = (\n promiseFactoryCallback: (() => Promise) | undefined,\n defaultValue: T,\n options: UsePromiseOptions = {},\n): [value: T, isLoading: boolean] => {\n // Use defaultValue as a ref so it doesn't update dependency arrays\n const defaultValueRef = useRef(defaultValue);\n defaultValueRef.current = defaultValue;\n // Use options as a ref so it doesn't update dependency arrays\n const optionsDefaultedRef = useRef(options);\n optionsDefaultedRef.current = getUsePromiseOptionsDefaults(optionsDefaultedRef.current);\n\n const [value, setValue] = useState(() => defaultValueRef.current);\n const [isLoading, setIsLoading] = useState(true);\n useEffect(() => {\n let promiseIsCurrent = true;\n // If a promiseFactoryCallback was provided, we are loading. Otherwise, there is no loading to do\n setIsLoading(!!promiseFactoryCallback);\n (async () => {\n // If there is a callback to run, run it\n if (promiseFactoryCallback) {\n const result = await promiseFactoryCallback();\n // If the promise was not already replaced, update the value\n if (promiseIsCurrent) {\n setValue(() => result);\n setIsLoading(false);\n }\n }\n })();\n\n return () => {\n // Mark this promise as old and not to be used\n promiseIsCurrent = false;\n if (!optionsDefaultedRef.current.preserveValue) setValue(() => defaultValueRef.current);\n };\n }, [promiseFactoryCallback]);\n\n return [value, isLoading];\n};\nexport default usePromise;\n","\"use client\";\n\nimport createSvgIcon from './utils/createSvgIcon';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nexport default createSvgIcon( /*#__PURE__*/_jsx(\"path\", {\n d: \"M3 18h18v-2H3zm0-5h18v-2H3zm0-7v2h18V6z\"\n}), 'Menu');","import GridMenu from '@/components/mui/grid-menu.component';\nimport { Command, CommandHandler } from '@/components/mui/menu-item.component';\nimport usePromise from '@/hooks/use-promise.hook';\nimport { Menu as MenuIcon } from '@mui/icons-material';\nimport { Drawer, IconButton } from '@mui/material';\nimport { Localized, MultiColumnMenu } from 'platform-bible-utils';\nimport {\n MouseEvent,\n MutableRefObject,\n PropsWithChildren,\n useCallback,\n useEffect,\n useState,\n} from 'react';\n\nexport interface MultiColumnMenuProvider {\n (isSupportAndDevelopment: boolean): Promise>;\n}\n\nexport type HamburgerMenuButtonProps = PropsWithChildren & {\n /** The handler to use for menu commands (and eventually toolbar commands). */\n commandHandler: CommandHandler;\n\n /**\n * Optional reference to the \"div\" container that determines the where the menu should appear. If\n * not defined, then (1,1) used.\n */\n containerRef?: MutableRefObject;\n\n /**\n * The delegate to use to get the menu data. If not specified or if it returns undefined, the data\n * in normalMenu or fullMenu property will be used.\n */\n menuProvider?: MultiColumnMenuProvider;\n\n /**\n * The menu data to show when the menu is opened if the menuProvider property is not defined.\n * (This allows for a default or test-only static menu to be used.)\n */\n normalMenu?: Localized;\n\n /**\n * The menu data to show for \"full\" menu (when opened with the SHIFT key pressed) if the\n * menuProvider property is not defined. (This allows for a default or test-only static menu to be\n * used.)\n */\n fullMenu?: Localized;\n\n /** Additional css class(es) to help with unique styling of the sub-components */\n className?: string;\n\n /** Value to use as prefix for ARIA labels on interactive sub-components */\n ariaLabelPrefix?: string;\n};\n\nexport default function HamburgerMenuButton({\n menuProvider,\n normalMenu,\n fullMenu,\n commandHandler,\n containerRef,\n className,\n ariaLabelPrefix,\n children,\n}: HamburgerMenuButtonProps) {\n const [isMenuOpen, setMenuOpen] = useState(false);\n const [showFullMenu, setShowFullMenu] = useState(false);\n\n const handleMenuItemClick = useCallback(() => {\n if (isMenuOpen) setMenuOpen(false);\n setShowFullMenu(false);\n }, [isMenuOpen]);\n\n const handleMenuButtonClick = useCallback((e: MouseEvent) => {\n e.stopPropagation();\n setMenuOpen((prevIsOpen) => {\n const isOpening = !prevIsOpen;\n if (isOpening && e.shiftKey) setShowFullMenu(true);\n else if (!isOpening) setShowFullMenu(false);\n return isOpening;\n });\n }, []);\n\n const menuCommandHandler = useCallback(\n (command: Command) => {\n handleMenuItemClick();\n return commandHandler(command);\n },\n [commandHandler, handleMenuItemClick],\n );\n\n const [offset, setOffset] = useState({ top: 1, left: 1 });\n\n useEffect(() => {\n if (isMenuOpen) {\n const node = containerRef?.current;\n if (node) {\n const rect = node.getBoundingClientRect();\n const scrollTop = window.scrollY;\n const scrollLeft = window.scrollX;\n const top = rect.top + scrollTop + node.clientHeight;\n const left = rect.left + scrollLeft;\n setOffset({ top, left });\n }\n }\n }, [isMenuOpen, containerRef]);\n\n const [normalMenuData] = usePromise(\n useCallback(async () => {\n return menuProvider?.(false) ?? normalMenu;\n // isMenuOpen needs to be included for the menu contents to reevaluate when reopened\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [menuProvider, normalMenu, isMenuOpen]),\n normalMenu,\n );\n\n const [fullMenuData] = usePromise(\n useCallback(async () => {\n return menuProvider?.(true) ?? fullMenu ?? normalMenuData;\n // isMenuOpen needs to be included for the menu contents to reevaluate when reopened\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [menuProvider, fullMenu, normalMenuData, isMenuOpen]),\n fullMenu ?? normalMenuData,\n );\n\n const menu = showFullMenu && fullMenuData ? fullMenuData : normalMenuData;\n\n return (\n <>\n \n {children ?? }\n \n \n {menu ? (\n \n ) : undefined}\n \n \n );\n}\n","import '@/components/mui/icon-button.component.css';\nimport { IconButton as MuiIconButton } from '@mui/material';\nimport { MouseEventHandler, PropsWithChildren } from 'react';\n\nexport type IconButtonProps = PropsWithChildren<{\n /** Optional unique identifier */\n id?: string;\n /**\n * Required. Used as both the tooltip (aka, title) and the aria-label (used for accessibility,\n * testing, etc.), unless a distinct tooltip is supplied.\n */\n label: string;\n /**\n * Enabled status of button\n *\n * @default false\n */\n isDisabled?: boolean;\n /** Optional tooltip to display if different from the aria-label. */\n tooltip?: string;\n /** If true, no tooltip will be displayed. */\n isTooltipSuppressed?: boolean;\n /**\n * If given, uses a negative margin to counteract the padding on one side (this is often helpful\n * for aligning the left or right side of the icon with content above or below, without ruining\n * the border size and shape).\n *\n * @default false\n */\n adjustMarginToAlignToEdge?: 'end' | 'start' | false;\n /**\n * The size of the component. small is equivalent to the dense button styling.\n *\n * @default false\n */\n size: 'small' | 'medium' | 'large';\n /** Additional css classes to help with unique styling of the button */\n className?: string;\n /** Optional click handler */\n onClick?: MouseEventHandler;\n}>;\n\n/**\n * Iconic button a user can click to do something\n *\n * Thanks to MUI for heavy inspiration and documentation\n * https://mui.com/material-ui/getting-started/overview/\n */\nfunction IconButton({\n id,\n label,\n isDisabled = false,\n tooltip,\n isTooltipSuppressed = false,\n adjustMarginToAlignToEdge = false,\n size = 'medium',\n className,\n onClick,\n children,\n}: IconButtonProps) {\n return (\n \n {children /* the icon to display */}\n \n );\n}\n\nexport default IconButton;\n","import { cn } from '@/utils/shadcn-ui.util';\nimport { LoaderCircle, LucideProps } from 'lucide-react';\nimport { forwardRef } from 'react';\n\nexport type SpinnerProps = LucideProps;\n\nconst Spinner = forwardRef(({ className, ...props }, ref) => {\n return (\n \n );\n});\n\nSpinner.displayName = 'Spinner';\n\nexport default Spinner;\n","import { Input as ShadInput } from '@/components/shadcn-ui/input';\nimport { Label as ShadLabel } from '@/components/shadcn-ui/label';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { ChangeEventHandler, FocusEventHandler } from 'react';\n\nexport type TextFieldProps = {\n /** Optional unique identifier */\n id?: string;\n /**\n * If `true`, the component is disabled.\n *\n * @default false\n */\n isDisabled?: boolean;\n /**\n * If `true`, the label is displayed in an error state.\n *\n * @default false\n */\n hasError?: boolean;\n /**\n * If `true`, the input will take up the full width of its container.\n *\n * @default false\n */\n isFullWidth?: boolean;\n /** Text that gives the user instructions on what contents the TextField expects */\n helperText?: string;\n /** The title of the TextField */\n label?: string;\n /** The short hint displayed in the `input` before the user enters a value. */\n placeholder?: string;\n /**\n * If `true`, the label is displayed as required and the `input` element is required.\n *\n * @default false\n */\n isRequired?: boolean;\n /** Additional css classes to help with unique styling of the text field */\n className?: string;\n /** Starting value for the text field if it is not controlled */\n defaultValue?: string | number;\n /** Value of the text field if controlled */\n value?: string | number;\n /** Triggers when content of textfield is changed */\n onChange?: ChangeEventHandler;\n /** Triggers when textfield gets focus */\n onFocus?: FocusEventHandler;\n /** Triggers when textfield loses focus */\n onBlur?: FocusEventHandler;\n};\n\n/**\n * Text input field\n *\n * Thanks to Shadcn for heavy inspiration and documentation\n * https://ui.shadcn.com/docs/components/input#with-label\n */\nfunction TextField({\n id,\n isDisabled = false,\n hasError = false,\n isFullWidth = false,\n helperText,\n label,\n placeholder,\n isRequired = false,\n className,\n defaultValue,\n value,\n onChange,\n onFocus,\n onBlur,\n}: TextFieldProps) {\n return (\n
    \n {`${label}${isRequired ? '*' : ''}`}\n \n

    {helperText}

    \n
    \n );\n}\n\nexport default TextField;\n","import HamburgerMenuButton, {\n MultiColumnMenuProvider,\n} from '@/components/mui/hamburger-menu-button.component';\nimport { CommandHandler } from '@/components/mui/menu-item.component';\nimport '@/components/mui/toolbar.component.css';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { AppBar, Toolbar as MuiToolbar } from '@mui/material';\nimport { PropsWithChildren, useRef } from 'react';\n\nexport type ToolbarProps = PropsWithChildren<{\n /** The handler to use for menu commands (and eventually toolbar commands). */\n commandHandler: CommandHandler;\n\n /**\n * The optional delegate to use to get the menu data. If not specified, the \"hamburger\" menu will\n * not display.\n */\n menuProvider?: MultiColumnMenuProvider;\n\n /** Optional unique identifier */\n id?: string;\n\n /** Additional css classes to help with unique styling of the toolbar */\n className?: string;\n}>;\n\nexport default function Toolbar({\n menuProvider,\n commandHandler,\n className,\n id,\n children,\n}: ToolbarProps) {\n // This ref will always be defined\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const containerRef = useRef(undefined!);\n\n return (\n
    \n \n \n {menuProvider ? (\n \n ) : undefined}\n {children ?
    {children}
    : undefined}\n \n
    \n
    \n );\n}\n","import React from 'react';\nimport { cva, type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst alertVariants = cva(\n 'tw-relative tw-w-full tw-rounded-lg tw-border tw-p-4 [&>svg~*]:tw-pl-7 [&>svg+div]:tw-translate-y-[-3px] [&>svg]:tw-absolute [&>svg]:tw-left-4 [&>svg]:tw-top-4 [&>svg]:tw-text-foreground',\n {\n variants: {\n variant: {\n default: 'tw-bg-background tw-text-foreground',\n destructive:\n 'tw-border-destructive/50 tw-text-destructive dark:tw-border-destructive [&>svg]:tw-text-destructive',\n },\n },\n defaultVariants: {\n variant: 'default',\n },\n },\n);\n\nconst Alert = React.forwardRef<\n HTMLDivElement,\n React.HTMLAttributes & VariantProps\n>(({ className, variant, ...props }, ref) => (\n
    \n));\nAlert.displayName = 'Alert';\n\nconst AlertTitle = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n {/* added because of https://github.com/jsx-eslint/eslint-plugin-jsx-a11y/blob/main/docs/rules/heading-has-content.md */}\n {props.children}{' '}\n \n ),\n);\nAlertTitle.displayName = 'AlertTitle';\n\nconst AlertDescription = React.forwardRef<\n HTMLParagraphElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n
    \n));\nAlertDescription.displayName = 'AlertDescription';\n\nexport { Alert, AlertTitle, AlertDescription };\n","import React from 'react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Card = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nCard.displayName = 'Card';\n\nconst CardHeader = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nCardHeader.displayName = 'CardHeader';\n\nconst CardTitle = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n {/* added because of https://github.com/jsx-eslint/eslint-plugin-jsx-a11y/blob/main/docs/rules/heading-has-content.md */}\n {props.children}\n \n ),\n);\nCardTitle.displayName = 'CardTitle';\n\nconst CardDescription = React.forwardRef<\n HTMLParagraphElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n

    \n));\nCardDescription.displayName = 'CardDescription';\n\nconst CardContent = React.forwardRef>(\n ({ className, ...props }, ref) => (\n

    \n ),\n);\nCardContent.displayName = 'CardContent';\n\nconst CardFooter = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nCardFooter.displayName = 'CardFooter';\n\nexport { Card, CardHeader, CardFooter, CardTitle, CardDescription, CardContent };\n","import { ComponentProps } from 'react';\nimport { toast as sonner, Toaster } from 'sonner';\n\ntype SonnerProps = ComponentProps;\n\nfunction Sonner({ ...props }: SonnerProps) {\n return (\n \n );\n}\n\n// The re-export of the sonner function was added manually\nexport { Sonner, sonner };\n","import React from 'react';\nimport * as SliderPrimitive from '@radix-ui/react-slider';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Slider = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n \n \n \n));\nSlider.displayName = SliderPrimitive.Root.displayName;\n\nexport { Slider };\n","import React from 'react';\nimport * as SwitchPrimitives from '@radix-ui/react-switch';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Switch = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n));\nSwitch.displayName = SwitchPrimitives.Root.displayName;\n\nexport { Switch };\n","import React from 'react';\nimport * as TabsPrimitive from '@radix-ui/react-tabs';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport const Tabs = TabsPrimitive.Root;\n\nexport type TabsListProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport type TabsTriggerProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport type TabsContentProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport const TabsList = React.forwardRef<\n React.ElementRef,\n TabsListProps\n>(({ className, ...props }, ref) => (\n \n));\nTabsList.displayName = TabsPrimitive.List.displayName;\n\nexport const TabsTrigger = React.forwardRef<\n React.ElementRef,\n TabsTriggerProps\n>(({ className, ...props }, ref) => (\n \n));\nTabsTrigger.displayName = TabsPrimitive.Trigger.displayName;\n\nexport const TabsContent = React.forwardRef<\n React.ElementRef,\n TabsContentProps\n>(({ className, ...props }, ref) => (\n \n));\nTabsContent.displayName = TabsPrimitive.Content.displayName;\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Download } from 'lucide-react';\n\ntype InstallButtonProps = {\n /** The installing boolean value determines the state of the button. */\n isInstalling: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n /** Optional text for the button. */\n buttonText?: string;\n} & ButtonProps;\n\n/**\n * The InstallButton component is a button designed for initiating installs. It includes visuals for\n * active installing and idle states.\n *\n * @param isInstalling The installing boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @param buttonText Optional text for the button.\n * @returns A install button.\n */\nexport default function InstallButton({\n isInstalling,\n handleClick,\n buttonText,\n className,\n ...props\n}: InstallButtonProps) {\n return (\n \n {isInstalling ? (\n \n ) : (\n <>\n \n {buttonText}\n \n )}\n \n );\n}\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\n\ntype EnableButtonProps = {\n /** The enabling boolean value determines the state of the button. */\n isEnabling: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n} & ButtonProps;\n\n/**\n * The EnableButton component is a button designed for initiating enabling of downloads. It includes\n * visuals for active enabling and idle states.\n *\n * @param isEnabling The enabling boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @returns A button that can be used to enable.\n */\nexport default function EnableButton({\n isEnabling,\n handleClick,\n className,\n ...props\n}: EnableButtonProps) {\n return (\n \n {isEnabling ? (\n <>\n \n Enabling...\n \n ) : (\n 'Enable'\n )}\n \n );\n}\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\n\ntype DisableButtonProps = {\n /** The disabling boolean value determines the state of the button. */\n isDisabling: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n} & ButtonProps;\n\n/**\n * The DisableButton component is a button designed for initiating disabling of downloads. It\n * includes visuals for active disabling and idle states.\n *\n * @param isDisabling The disabling boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @returns A button that can be used to disable.\n */\nexport default function DisableButton({\n isDisabling,\n handleClick,\n className,\n ...props\n}: DisableButtonProps) {\n return (\n \n {isDisabling ? (\n <>\n \n Disabling...\n \n ) : (\n 'Disable'\n )}\n \n );\n}\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\n\ntype UpdateButtonProps = {\n /** The updating boolean value determines the state of the button. */\n isUpdating: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n} & ButtonProps;\n\n/**\n * The UpdateButton component is a button designed for initiating updates for downloaded extensions.\n * It includes visuals for active updating and idle states.\n *\n * @param isUpdating The updating boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @returns A button that can be used to update.\n */\nexport default function UpdateButton({\n isUpdating,\n handleClick,\n className,\n ...props\n}: UpdateButtonProps) {\n return (\n \n {isUpdating ? (\n <>\n \n Updating...\n \n ) : (\n 'Update'\n )}\n \n );\n}\n","import { cn } from '@/utils/shadcn-ui.util';\nimport Markdown, { MarkdownToJSX } from 'markdown-to-jsx';\nimport { useMemo } from 'react';\n\ninterface MarkdownRendererProps {\n /** Optional unique identifier */\n id?: string;\n /** The markdown string to render */\n markdown: string;\n className?: string;\n /**\n * The [`target` attribute for `a` html\n * tags](https://developer.mozilla.org/en-US/docs/Web/HTML/Element/a#target). Defaults to not\n * adding a `target` to `a` tags\n */\n anchorTarget?: string;\n}\n\n/**\n * This component renders markdown content given a markdown string. It uses typography styles from\n * the platform.\n *\n * @param markdown The markdown string to render.\n * @param id Optional unique identifier\n * @returns A div containing the rendered markdown content.\n */\nexport default function MarkdownRenderer({\n id,\n markdown,\n className,\n anchorTarget,\n}: MarkdownRendererProps) {\n const options: MarkdownToJSX.Options = useMemo(\n () => ({\n overrides: {\n a: {\n props: {\n target: anchorTarget,\n },\n },\n },\n }),\n [anchorTarget],\n );\n return (\n
    \n {markdown}\n
    \n );\n}\n","import { Filter, ChevronDown } from 'lucide-react';\nimport { forwardRef } from 'react';\nimport { Button } from '@/components/shadcn-ui/button';\n\n/**\n * The FilterButton component is a button designed for initiating filtering of data. It is designed\n * to be used with the dropdown menu. It uses forwardRef to pass the button to the dropdown trigger\n * asChild.\n *\n * @returns A button that can be used to filter.\n */\nconst FilterButton = forwardRef((props, ref) => {\n return (\n \n \n Filter\n \n \n );\n});\n\nexport default FilterButton;\n","import {\n DropdownMenu,\n DropdownMenuTrigger,\n DropdownMenuContent,\n DropdownMenuLabel,\n DropdownMenuGroup,\n DropdownMenuCheckboxItem,\n DropdownMenuRadioItem,\n DropdownMenuSeparator,\n} from '@/components/shadcn-ui/dropdown-menu';\nimport FilterButton from './buttons/filter-button.component';\n\nexport enum DropdownMenuItemType {\n Check,\n Radio,\n}\n\nexport type DropdownItem = {\n /** The label is the text that will be displayed on the dropdown item. */\n label: string;\n /** The itemType determines the DropdownMenuItemType type as either Check or Radio. */\n itemType: DropdownMenuItemType;\n /** The onClick function is called when the item is clicked. */\n onClick: () => void;\n};\n\nexport type DropdownGroup = {\n /**\n * The label is the text that will be displayed on the dropdown group. It is used to categorize\n * the items in the group.\n */\n label: string;\n /** The items array contains the items that will be displayed in the dropdown group */\n items: DropdownItem[];\n};\n\nexport type FilterDropdownProps = {\n /** Object unique identifier */\n id?: string;\n /** The groups array contains the groups that will be displayed in the dropdown */\n groups: DropdownGroup[];\n}; // TODO: extend the props later\n\n/**\n * The FilterDropdown component is a dropdown designed for filtering content. It includes groups of\n * items that can be checkboxes or radio items.\n *\n * @param id Optional unique identifier\n * @param groups The groups array contains the groups that will be displayed in the dropdown\n * @returns A filter dropdown.\n */\nexport default function FilterDropdown({ id, groups }: FilterDropdownProps) {\n return (\n
    \n {/* TODO: remove this once the DropDown Menu shadcn has an id prop */}\n \n \n \n \n \n {groups.map((group) => (\n
    \n {group.label}\n \n {group.items.map((item) => (\n
    \n {item.itemType === DropdownMenuItemType.Check ? (\n \n {item.label}\n \n ) : (\n \n {item.label}\n \n )}\n
    \n ))}\n
    \n \n
    \n ))}\n
    \n
    \n
    \n );\n}\n","interface NoExtensionsFoundProps {\n /** Optional unique identifier */\n id?: string;\n /** The message to display */\n message: string;\n}\n/**\n * This component displays a message to the user when no extensions are found in the marketplace.\n *\n * @param id Optional unique identifier\n * @param message The message to display.\n * @returns {JSX.Element} - Returns the message component that displays the message to the user.\n */\nexport default function NoExtensionsFound({ id, message }: NoExtensionsFoundProps) {\n return (\n
    \n
    \n

    {message}

    \n
    \n
    \n );\n}\n","import { CircleHelp, Link as LucideLink, User } from 'lucide-react';\nimport { NumberFormat } from 'platform-bible-utils';\n\n/** Interface that stores the parameters passed to the More Info component */\ninterface MoreInfoProps {\n /** Optional unique identifier */\n id?: string;\n /** The category of the extension */\n category: string;\n /** The number of downloads for the extension */\n downloads: Record;\n /** The languages supported by the extension */\n languages: string[];\n /** The URL to the more info page of the extension */\n moreInfoUrl: string;\n}\n/**\n * This component displays the more info section of the extension which includes the category,\n * number of downloads, languages, and links to the website and support\n *\n * @param id Optional unique identifier\n * @param category The category of the extension\n * @param downloads The number of downloads for the extension\n * @param languages The languages supported by the extension\n * @param moreInfoUrl The URL to the more info page of the extension\n * @returns {JSX.Element} - Returns the more info component that displays the category, number of\n * downloads, languages, and links to the website and support\n */\nexport default function MoreInfo({\n id,\n category,\n downloads,\n languages,\n moreInfoUrl,\n}: MoreInfoProps) {\n /**\n * This constant formats the number of downloads into a more readable format.\n *\n * @example 1000 -> 1K\n *\n * @example 1000000 -> 1M\n *\n * @returns The formatted number of downloads\n */\n const numberFormatted = new NumberFormat('en', {\n notation: 'compact',\n compactDisplay: 'short',\n }).format(Object.values(downloads).reduce((a: number, b: number) => a + b, 0));\n\n /** This function scrolls the window to the bottom of the page. */\n const handleScrollToBottom = () => {\n window.scrollTo(0, document.body.scrollHeight);\n };\n\n return (\n \n
    \n
    \n {category}\n
    \n CATEGORY\n
    \n
    \n
    \n
    \n \n {numberFormatted}\n
    \n USERS\n
    \n
    \n
    \n
    \n {languages.slice(0, 3).map((locale) => (\n \n {locale.toUpperCase()}\n \n ))}\n
    \n {languages.length > 3 && (\n handleScrollToBottom()}\n className=\"tw-text-xs tw-text-gray-500 tw-underline\"\n >\n +{languages.length - 3} more languages\n \n )}\n
    \n
    \n
    \n \n Website\n \n \n \n Support\n \n \n
    \n
    \n );\n}\n","import { useState } from 'react';\n\nexport type VersionInformation = {\n /** Date the version was published */\n date: string;\n /** Description of the changes in the version */\n description: string;\n};\n\n/** Type to store the version history information */\nexport type VersionHistoryType = Record;\n\n/** Interface that stores the parameters passed to the Version History component */\ninterface VersionHistoryProps {\n /** Optional unique identifier */\n id?: string;\n /** Object containing the versions mapped with their information */\n versionHistory: VersionHistoryType;\n}\n\n/**\n * Component to render the version history information shown in the footer component. Lists the 5\n * most recent versions, with the options to show all versions by pressing a button.\n *\n * @param versionHistory Object containing the versions mapped with their information\n * @param id Optional unique identifier\n * @returns Rendered version history for the Footer component\n */\nexport default function VersionHistory({ id, versionHistory }: VersionHistoryProps) {\n const [showAllVersions, setShowAllVersions] = useState(false);\n const currentDate = new Date();\n\n /**\n * Function to format the time string for the version history in the form of 'X year(s) ago'.\n *\n * @param dateString ISO Date string to determine the time string from\n * @returns Formatted time string\n */\n function formatTimeString(dateString: string) {\n const date = new Date(dateString);\n const dateDiff = new Date(currentDate.getTime() - date.getTime());\n const yearDiff = dateDiff.getUTCFullYear() - 1970;\n const monthDiff = dateDiff.getUTCMonth();\n const dayDiff = dateDiff.getUTCDate() - 1;\n\n // Determines how long ago the version was published\n let timeString = '';\n if (yearDiff > 0) {\n timeString = `${yearDiff.toString()} year${yearDiff === 1 ? '' : 's'} ago`;\n } else if (monthDiff > 0) {\n timeString = `${monthDiff.toString()} month${monthDiff === 1 ? '' : 's'} ago`;\n } else if (dayDiff === 0) {\n timeString = 'today';\n } else {\n timeString = `${dayDiff.toString()} day${dayDiff === 1 ? '' : 's'} ago`;\n }\n\n return timeString;\n }\n\n // Sorts the version history by version number\n const sortedEntries = Object.entries(versionHistory).sort((a, b) => b[0].localeCompare(a[0]));\n\n return (\n
    \n

    What`s New

    \n
      \n {(showAllVersions ? sortedEntries : sortedEntries.slice(0, 5)).map((entry) => (\n
      \n
      \n
    • \n {entry[1].description}\n
    • \n
      \n
      \n
      Version {entry[0]}
      \n
      {formatTimeString(entry[1].date)}
      \n
      \n
      \n ))}\n
    \n {sortedEntries.length > 5 && (\n setShowAllVersions(!showAllVersions)}\n className=\"tw-text-xs tw-text-gray-500 tw-underline\"\n >\n {showAllVersions ? 'Show Less Version History' : 'Show All Version History'}\n \n )}\n
    \n );\n}\n","import { useMemo } from 'react';\nimport { formatBytes } from 'platform-bible-utils';\nimport VersionHistory, { VersionHistoryType } from './version-history.component';\n\n/** Interface to store the parameters passed to the Footer component */\ninterface FooterProps {\n /** Optional unique identifier */\n id?: string;\n /** Name of the publisher */\n publisherDisplayName: string;\n /** Size of the extension file in bytes */\n fileSize: number;\n /** List of language codes supported by the extension */\n locales: string[];\n /** Object containing the version history mapped with their information */\n versionHistory: VersionHistoryType;\n}\n\n/**\n * Component to render the footer for the extension details which contains information on the\n * publisher, version history, languages, and file size.\n *\n * @param id Optional unique identifier\n * @param publisherDisplayName Name of the publisher\n * @param fileSize Size of the extension file in bytes\n * @param locales List of language codes supported by the extension\n * @param versionHistory Object containing the version history mapped with their information\n * @returns The rendered Footer component\n */\nexport default function Footer({\n id,\n publisherDisplayName,\n fileSize,\n locales,\n versionHistory,\n}: FooterProps) {\n /** Formats the file size into a human-readable format */\n const formattedFileSize = useMemo(() => formatBytes(fileSize), [fileSize]);\n\n /**\n * This function gets the display names of the languages based on the language codes.\n *\n * @param codes The list of language codes\n * @returns The list of language names\n */\n const getLanguageNames = (codes: string[]) => {\n const displayNames = new Intl.DisplayNames(navigator.language, { type: 'language' });\n return codes.map((code) => displayNames.of(code));\n };\n\n const languageNames = getLanguageNames(locales);\n\n return (\n
    \n
    \n \n
    \n
    \n

    Information

    \n
    \n

    \n Publisher\n {publisherDisplayName}\n Size\n {formattedFileSize}\n

    \n
    \n

    \n Languages\n {languageNames.join(', ')}\n

    \n
    \n
    \n
    \n
    \n
    \n );\n}\n","import { PlatformEvent, PlatformEventHandler } from 'platform-bible-utils';\nimport { useEffect } from 'react';\n\n/**\n * Adds an event handler to an event so the event handler runs when the event is emitted. Use\n * `papi.network.getNetworkEvent` to use a networked event with this hook.\n *\n * @param event The event to subscribe to.\n *\n * - If event is a `PlatformEvent`, that event will be used\n * - If event is undefined, the callback will not be subscribed. Useful if the event is not yet\n * available for example\n *\n * @param eventHandler The callback to run when the event is emitted\n *\n * WARNING: MUST BE STABLE - const or wrapped in useCallback. The reference must not be updated\n * every render\n */\nconst useEvent = (\n event: PlatformEvent | undefined,\n eventHandler: PlatformEventHandler,\n) => {\n useEffect(() => {\n // Do nothing if the event is not provided (in case the event is not yet available, for example)\n if (!event) return () => {};\n\n const unsubscriber = event(eventHandler);\n return () => {\n unsubscriber();\n };\n }, [event, eventHandler]);\n};\nexport default useEvent;\n","import { useCallback, useEffect } from 'react';\nimport { PlatformEvent, PlatformEventAsync, PlatformEventHandler } from 'platform-bible-utils';\nimport usePromise from './use-promise.hook';\n\nconst noopUnsubscriber = () => false;\n\n/**\n * Adds an event handler to an asynchronously subscribing/unsubscribing event so the event handler\n * runs when the event is emitted. Use `papi.network.getNetworkEvent` to use a networked event with\n * this hook.\n *\n * @param event The asynchronously (un)subscribing event to subscribe to.\n *\n * - If event is a `PlatformEvent` or `PlatformEventAsync`, that event will be used\n * - If event is undefined, the callback will not be subscribed. Useful if the event is not yet\n * available for example\n *\n * @param eventHandler The callback to run when the event is emitted\n *\n * WARNING: MUST BE STABLE - const or wrapped in useCallback. The reference must not be updated\n * every render\n */\nconst useEventAsync = (\n event: PlatformEvent | PlatformEventAsync | undefined,\n eventHandler: PlatformEventHandler,\n) => {\n // Subscribe to the event asynchronously\n const [unsubscribe] = usePromise(\n useCallback(async () => {\n // Do nothing if the event is not provided (in case the event is not yet available, for example)\n if (!event) return noopUnsubscriber;\n\n // Wrap subscribe and unsubscribe in promises to allow normal events to be used as well\n const unsub = await Promise.resolve(event(eventHandler));\n return async () => unsub();\n }, [eventHandler, event]),\n noopUnsubscriber,\n // We want the unsubscriber to return to default value immediately upon changing subscription\n // So the useEffect below will unsubscribe asap\n { preserveValue: false },\n );\n\n // Unsubscribe from the event asynchronously (but we aren't awaiting the unsub)\n useEffect(() => {\n return () => {\n if (unsubscribe !== noopUnsubscriber) {\n unsubscribe();\n }\n };\n }, [unsubscribe]);\n};\n\nexport default useEventAsync;\n"],"names":["twMergeCustom","extendTailwindMerge","cn","inputs","clsx","Input","React","className","type","props","ref","jsx","BookChapterInput","forwardRef","handleSearch","handleKeyDown","handleOnClick","handleSubmit","jsxs","ShadInput","event","e","History","P","R","s","n","N","B","O","S","K","g","k","x","T","X","V","w","L","G","A","H","C","I","y","q","U","m","l","h","c","E","D","i","a","o","u","v","f","d","b","J","DropdownMenu","DropdownMenuPrimitive","DropdownMenuTrigger","DropdownMenuGroup","DropdownMenuPortal","DropdownMenuSub","DropdownMenuRadioGroup","DropdownMenuSubTrigger","inset","children","ChevronRight","DropdownMenuSubContent","DropdownMenuContent","sideOffset","DropdownMenuItem","DropdownMenuCheckboxItem","checked","Check","DropdownMenuRadioItem","Circle","DropdownMenuLabel","DropdownMenuSeparator","DropdownMenuShortcut","BookMenuItem","bookId","handleSelectBook","isSelected","handleHighlightBook","bookType","ShadDropdownMenuItem","Canon","ChapterSelect","handleSelectChapter","endChapter","activeChapter","highlightedChapter","handleHighlightedChapter","chapters","_","handleMouse","useCallback","chapterNumber","chapter","GoToMenuItem","handleSort","handleLocationHistory","handleBookmarks","ShadDropdownMenuLabel","ArrowDownWideNarrow","Clock","Bookmark","ALL_BOOK_IDS","BOOK_TYPE_LABELS","BOOK_TYPE_ARRAY","SCROLL_OFFSET","SEARCH_QUERY_FORMATS","fetchGroupedBooks","fetchEndChapter","getChaptersForBook","getAllEnglishNames","isValidBookEnglishName","bookName","getBookIdFromEnglishName","formattedBookName","BookChapterControl","scrRef","searchQuery","setSearchQuery","useState","selectedBookId","setSelectedBookId","setHighlightedChapter","highlightedBookId","setHighlightedBookId","isContentOpen","setIsContentOpen","isContentOpenDelayed","setIsContentOpenDelayed","inputRef","useRef","contentRef","menuItemRef","fetchFilteredBooks","englishNameLowerCase","normalizedQuery","handleSearchInput","searchString","shouldPreventAutoClosing","controlMenuState","open","updateReference","shouldClose","verse","handleInputSubmit","format","matches","book","englishName","handleKeyDownInput","handleKeyDownContent","key","handleKeyDownMenuItem","chapterOffSet","useEffect","useLayoutEffect","scrollTimeout","scrollPosition","ShadDropdownMenu","ShadDropdownMenuTrigger","ShadDropdownMenuContent","bookTypeIndex","element","ShadDropdownMenuSeparator","buttonVariants","cva","Button","variant","size","asChild","Slot","labelVariants","Label","LabelPrimitive","RadioGroup","RadioGroupPrimitive","RadioGroupItem","Popover","PopoverPrimitive","PopoverTrigger","PopoverContent","align","DialogPortal","DialogPrimitive","DialogOverlay","DialogContent","DialogTitle","DialogDescription","Command","CommandPrimitive","CommandInput","Search","CommandList","CommandEmpty","CommandGroup","CommandSeparator","CommandItem","getOptionLabelDefault","option","ComboBox","id","options","buttonClassName","popoverContentClassName","value","onChange","getOptionLabel","buttonPlaceholder","textPlaceholder","commandEmptyMessage","buttonVariant","dir","isDisabled","setOpen","ChevronsUpDown","ChapterRangeSelector","startChapter","handleSelectStartChapter","handleSelectEndChapter","chapterCount","chapterOptions","useMemo","index","Fragment","BookSelectionMode","BOOK_SELECTOR_STRING_KEYS","localizeString","strings","BookSelector","handleBookSelectionModeChange","currentBookName","onSelectBooks","selectedBookIds","localizedStrings","currentBookText","chooseText","chooseBooksText","bookSelectionMode","setBookSelectionMode","onSelectionModeChange","newMode","DataTableViewOptions","table","FilterIcon","column","Select","SelectPrimitive","SelectGroup","SelectValue","SelectTrigger","ChevronDown","SelectScrollUpButton","ChevronUp","SelectScrollDownButton","SelectContent","position","SelectLabel","SelectItem","SelectSeparator","DataTablePagination","pageSize","ArrowLeftIcon","ChevronLeftIcon","ChevronRightIcon","ArrowRightIcon","Table","stickyHeader","TableHeader","TableBody","TableFooter","TableRow","TableHead","TableCell","TableCaption","DataTable","columns","data","enablePagination","showPaginationControls","showColumnVisibilityControls","onRowClickHandler","sorting","setSorting","columnFilters","setColumnFilters","columnVisibility","setColumnVisibility","rowSelection","setRowSelection","useReactTable","getCoreRowModel","getPaginationRowModel","getSortedRowModel","getFilteredRowModel","headerGroup","header","flexRender","_a","row","cell","OccurrencesTable","occurrenceData","setScriptureReference","referenceHeaderText","occurrenceHeaderText","occurrences","uniqueOccurrences","occurrence","uniqueOccurrence","deepEqual","Checkbox","CheckboxPrimitive","getLinesFromUSFM","text","getNumberFromUSFM","regex","match","getBookNumFromId","getStatusForItem","item","approvedItems","unapprovedItems","toggleVariants","Toggle","TogglePrimitive","ToggleGroupContext","ToggleGroup","ToggleGroupPrimitive","ToggleGroupItem","context","getSortingIcon","sortDirection","ArrowUpIcon","ArrowDownIcon","ArrowUpDownIcon","inventoryItemColumn","itemLabel","inventoryAdditionalItemColumn","additionalItemLabel","additionalItemIndex","inventoryCountColumn","countLabel","statusChangeHandler","changedItems","newStatus","onApprovedItemsChange","onUnapprovedItemsChange","newApprovedItems","validItem","newUnapprovedItems","unapprovedItem","inventoryStatusColumn","statusLabel","status","CircleCheckIcon","CircleXIcon","CircleHelpIcon","INVENTORY_STRING_KEYS","filterItemData","itemData","statusFilter","textFilter","filteredItemData","createTableData","scriptureRef","itemRegex","tableData","currentBook","currentChapter","currentVerse","line","items","itemIndex","existingItem","tableEntry","newReference","substring","newItem","Inventory","scriptureReference","extractItems","additionalItemsLabels","scope","onScopeChange","allItemsText","approvedItemsText","unapprovedItemsText","unknownItemsText","scopeBookText","scopeChapterText","scopeVerseText","filterText","showAdditionalItemsText","showAdditionalItems","setShowAdditionalItems","setStatusFilter","setTextFilter","selectedItem","setSelectedItem","reducedTableData","newTableData","firstItem","existingEntry","newTableEntry","filteredTableData","allColumns","numberOfAdditionalItems","additionalColumns","_b","rowClickHandler","newSelection","handleScopeChange","handleStatusFilterChange","SearchBar","onSearch","placeholder","isFullWidth","handleInputChange","VerticalTabs","TabsPrimitive","VerticalTabsList","VerticalTabsTrigger","VerticalTabsContent","TabNavigationContentSearch","tabList","searchPlaceholder","headerTitle","isSearchBarFullWidth","direction","tab","Separator","orientation","decorative","SeparatorPrimitive","Skeleton","TooltipProvider","TooltipPrimitive","Tooltip","TooltipTrigger","TooltipContent","SIDEBAR_WIDTH","SIDEBAR_WIDTH_ICON","SidebarContext","useSidebar","SidebarProvider","defaultOpen","openProp","setOpenProp","style","_open","_setOpen","isOpen","openState","toggleSidebar","state","contextValue","Sidebar","side","collapsible","SidebarTrigger","onClick","PanelLeft","SidebarRail","SidebarInset","SidebarInput","SidebarHeader","SidebarFooter","SidebarSeparator","SidebarContent","SidebarGroup","SidebarGroupLabel","SidebarGroupAction","SidebarGroupContent","SidebarMenu","SidebarMenuItem","sidebarMenuButtonVariants","SidebarMenuButton","isActive","tooltip","Comp","button","SidebarMenuAction","showOnHover","SidebarMenuBadge","SidebarMenuSkeleton","showIcon","width","SidebarMenuSub","SidebarMenuSubItem","SidebarMenuSubButton","SettingsSidebar","extensionLabels","projectInfo","handleSelectSidebarItem","selectedSidebarItem","extensionsSidebarGroupLabel","projectsSidebarGroupLabel","buttonPlaceholderText","handleSelectItem","projectId","getProjectNameFromProjectId","project","info","getIsActive","label","selectedProjectName","SettingsSidebarContentSearch","scrBookColId","scrRefColId","typeColId","detailsColId","defaultScrRefColumnName","defaultScrBookGroupName","defaultTypeColumnName","defaultDetailsColumnName","getColumns","colInfo","showSourceColumn","showSrcCol","formatScrRef","compareScrRefs","toRefOrRange","scriptureSelection","offsetStart","offsetEnd","scrRefToBBBCCCVVV","getRowKey","ScriptureResultsViewer","sources","showColumnHeaders","scriptureReferenceColumnName","scriptureBookGroupName","typeColumnName","detailsColumnName","onRowSelected","grouping","setGrouping","scriptureResults","source","getExpandedRowModel","getGroupedRowModel","selectedRows","keys","selectedRow","scrBookGroupName","typeGroupName","groupingOptions","handleSelectChange","selectedGrouping","handleRowClick","getEvenOrOddBandingStyle","getIndent","groupingState","rowIndex","ChevronLeft","DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS","getLocalizeKeyForScrollGroupId","ScrollGroupSelector","availableScrollGroupIds","scrollGroupId","onChangeScrollGroupId","localizedStringsDefaulted","localizedStringKey","localizedStringValue","newScrollGroupString","scrollGroupOptionId","SettingsList","SettingsListItem","primary","secondary","isLoading","loadingMessage","SettingsListHeader","includeSeparator","Checklist","listItems","selectedListItems","handleSelectListItem","createLabel","_interopRequireDefault","obj","module","chainPropTypes","propType1","propType2","args","_extends","target","isPlainObject","prototype","deepClone","output","deepmerge","p","r","t","z","reactIs_production_min","hasSymbol","REACT_ELEMENT_TYPE","REACT_PORTAL_TYPE","REACT_FRAGMENT_TYPE","REACT_STRICT_MODE_TYPE","REACT_PROFILER_TYPE","REACT_PROVIDER_TYPE","REACT_CONTEXT_TYPE","REACT_ASYNC_MODE_TYPE","REACT_CONCURRENT_MODE_TYPE","REACT_FORWARD_REF_TYPE","REACT_SUSPENSE_TYPE","REACT_SUSPENSE_LIST_TYPE","REACT_MEMO_TYPE","REACT_LAZY_TYPE","REACT_BLOCK_TYPE","REACT_FUNDAMENTAL_TYPE","REACT_RESPONDER_TYPE","REACT_SCOPE_TYPE","isValidElementType","typeOf","object","$$typeof","$$typeofType","AsyncMode","ConcurrentMode","ContextConsumer","ContextProvider","Element","ForwardRef","Lazy","Memo","Portal","Profiler","StrictMode","Suspense","hasWarnedAboutDeprecatedIsAsyncMode","isAsyncMode","isConcurrentMode","isContextConsumer","isContextProvider","isElement","isForwardRef","isFragment","isLazy","isMemo","isPortal","isProfiler","isStrictMode","isSuspense","reactIs_development","reactIsModule","require$$0","require$$1","getOwnPropertySymbols","hasOwnProperty","propIsEnumerable","toObject","val","shouldUseNative","test1","test2","order2","test3","letter","objectAssign","from","to","symbols","ReactPropTypesSecret","ReactPropTypesSecret_1","has","printWarning","loggedTypeFailures","message","checkPropTypes","typeSpecs","values","location","componentName","getStack","typeSpecName","error","err","ex","stack","checkPropTypes_1","ReactIs","assign","require$$2","require$$3","require$$4","emptyFunctionThatReturnsNull","factoryWithTypeCheckers","isValidElement","throwOnDirectAccess","ITERATOR_SYMBOL","FAUX_ITERATOR_SYMBOL","getIteratorFn","maybeIterable","iteratorFn","ANONYMOUS","ReactPropTypes","createPrimitiveTypeChecker","createAnyTypeChecker","createArrayOfTypeChecker","createElementTypeChecker","createElementTypeTypeChecker","createInstanceTypeChecker","createNodeChecker","createObjectOfTypeChecker","createEnumTypeChecker","createUnionTypeChecker","createShapeTypeChecker","createStrictShapeTypeChecker","is","PropTypeError","createChainableTypeChecker","validate","manualPropTypeCallCache","manualPropTypeWarningCount","checkType","isRequired","propName","propFullName","secret","cacheKey","chainedCheckType","expectedType","propValue","propType","getPropType","preciseType","getPreciseType","typeChecker","expectedClass","expectedClassName","actualClassName","getClassName","expectedValues","valuesString","arrayOfTypeCheckers","checker","getPostfixForTypeWarning","expectedTypes","checkerResult","expectedTypesMessage","isNode","invalidValidatorError","shapeTypes","allKeys","iterator","step","entry","isSymbol","emptyFunction","emptyFunctionWithReset","factoryWithThrowingShims","shim","getShim","propTypesModule","isClassComponent","elementType","acceptingRef","safePropName","warningHint","elementAcceptingRef","PropTypes","elementAcceptingRef$1","specialProperty","exactProp","propTypes","unsupportedProps","prop","formatMuiErrorMessage","code","url","REACT_SERVER_CONTEXT_TYPE","REACT_OFFSCREEN_TYPE","enableScopeAPI","enableCacheElement","enableTransitionTracing","enableLegacyHidden","enableDebugTracing","REACT_MODULE_REFERENCE","SuspenseList","hasWarnedAboutDeprecatedIsConcurrentMode","isSuspenseList","fnNameMatchRegex","getFunctionName","fn","getFunctionComponentName","Component","fallback","getWrappedName","outerType","innerType","wrapperName","functionName","getDisplayName","HTMLElementType","refType","refType$1","capitalize","string","_formatMuiErrorMessage","createChainedFunction","funcs","acc","func","debounce","wait","timeout","debounced","later","deprecatedPropType","validator","reason","componentNameSafe","propFullNameSafe","isMuiElement","muiNames","_muiName","_element$type","ownerDocument","node","ownerWindow","requirePropFactory","componentNameInError","prevPropTypes","requiredProp","defaultTypeChecker","typeCheckerResult","setRef","useEnhancedEffect","useEnhancedEffect$1","globalId","useGlobalId","idOverride","defaultId","setDefaultId","maybeReactUseId","useId","reactId","unsupportedProp","useControlled","controlled","defaultProp","name","isControlled","valueState","setValue","defaultValue","setValueIfUncontrolled","newValue","useEventCallback","useForkRef","refs","instance","UNINITIALIZED","useLazyRef","init","initArg","EMPTY","useOnMount","Timeout","delay","useTimeout","hadKeyboardEvent","hadFocusVisibleRecently","hadFocusVisibleRecentlyTimeout","inputTypesWhitelist","focusTriggersKeyboardModality","tagName","handlePointerDown","handleVisibilityChange","prepare","doc","isFocusVisible","useIsFocusVisible","isFocusVisibleRef","handleBlurVisible","handleFocusVisible","resolveProps","defaultProps","defaultSlotProps","slotProps","slotPropName","composeClasses","slots","getUtilityClass","classes","slot","utilityClass","defaultGenerator","createClassNameGenerator","generate","generator","ClassNameGenerator","ClassNameGenerator$1","globalStateClasses","generateUtilityClass","globalStatePrefix","globalStateClass","generateUtilityClasses","result","clamp","min","max","_objectWithoutPropertiesLoose","excluded","sourceKeys","_excluded","sortBreakpointsValues","breakpointsAsArray","breakpoint1","breakpoint2","createBreakpoints","breakpoints","unit","other","sortedValues","up","down","between","start","end","endIndex","only","not","keyIndex","shape","shape$1","responsivePropType","responsivePropType$1","merge","defaultBreakpoints","handleBreakpoints","styleFromPropValue","theme","themeBreakpoints","breakpoint","mediaKey","cssKey","createEmptyBreakpointObject","breakpointsInput","_breakpointsInput$key","breakpointStyleKey","removeUnusedBreakpoints","breakpointKeys","breakpointOutput","getPath","path","checkVars","getStyleValue","themeMapping","transform","propValueFinal","userValue","cssProperty","themeKey","memoize","cache","arg","properties","directions","aliases","getCssProperties","property","marginKeys","paddingKeys","spacingKeys","createUnaryUnit","_getPath","themeSpacing","abs","createUnarySpacing","getValue","transformer","transformed","getStyleFromPropValue","cssProperties","resolveCssProperty","margin","padding","createSpacing","spacingInput","spacing","argsInput","argument","compose","styles","handlers","borderTransform","createBorderStyle","border","borderTop","borderRight","borderBottom","borderLeft","borderColor","borderTopColor","borderRightColor","borderBottomColor","borderLeftColor","outline","outlineColor","borderRadius","gap","columnGap","rowGap","gridColumn","gridRow","gridAutoFlow","gridAutoColumns","gridAutoRows","gridTemplateColumns","gridTemplateRows","gridTemplateAreas","gridArea","paletteTransform","color","bgcolor","backgroundColor","sizingTransform","maxWidth","_props$theme","_props$theme2","breakpointsValues","minWidth","height","maxHeight","minHeight","boxSizing","defaultSxConfig","defaultSxConfig$1","objectsHaveSameKeys","objects","union","callIfFn","maybeFn","unstable_createStyleFunctionSx","getThemeValue","config","styleFunctionSx","_theme$unstable_sxCon","sx","traverse","sxInput","sxObject","emptyBreakpoints","breakpointsKeys","css","styleKey","styleFunctionSx$1","applyStyles","createTheme","paletteInput","shapeInput","muiTheme","isObjectEmpty","useTheme","defaultTheme","contextTheme","ThemeContext","systemDefaultTheme","useThemeWithoutDefault","_excluded2","_excluded3","isEmpty","isStringTag","tag","shouldForwardProp","lowercaseFirstLetter","resolveTheme","themeId","defaultOverridesResolver","processStyleArg","callableStyle","_ref","ownerState","resolvedStylesArg","resolvedStyle","variants","isMatch","createStyled","input","rootShouldForwardProp","slotShouldForwardProp","systemSx","inputOptions","processStyles","componentSlot","inputSkipVariantsResolver","inputSkipSx","overridesResolver","skipVariantsResolver","skipSx","shouldForwardPropOption","defaultStyledResolver","styledEngineStyled","transformStyleArg","stylesArg","muiStyledResolver","styleArg","expressions","transformedStyleArg","expressionsWithDefaultTheme","styleOverrides","resolvedStyleOverrides","slotKey","slotStyle","_theme$components","themeVariants","numOfCustomFnsApplied","placeholders","displayName","getThemeProps","params","useThemeProps","clampWrapper","hexToRgb","re","colors","decomposeColor","marker","colorSpace","recomposeColor","hslToRgb","rgb","getLuminance","getContrastRatio","foreground","background","lumA","lumB","alpha","darken","coefficient","lighten","createMixins","mixins","common","common$1","grey","grey$1","purple","purple$1","red","red$1","orange","orange$1","blue","blue$1","lightBlue","lightBlue$1","green","green$1","light","dark","addLightOrDark","intent","shade","tonalOffset","tonalOffsetLight","tonalOffsetDark","getDefaultPrimary","mode","getDefaultSecondary","getDefaultError","getDefaultInfo","getDefaultSuccess","getDefaultWarning","createPalette","palette","contrastThreshold","success","warning","getContrastText","contrastText","contrast","augmentColor","mainShade","lightShade","darkShade","modes","round","caseAllCaps","defaultFontFamily","createTypography","typography","fontFamily","fontSize","fontWeightLight","fontWeightRegular","fontWeightMedium","fontWeightBold","htmlFontSize","allVariants","pxToRem2","coef","pxToRem","buildVariant","fontWeight","lineHeight","letterSpacing","casing","shadowKeyUmbraOpacity","shadowKeyPenumbraOpacity","shadowAmbientShadowOpacity","createShadow","px","shadows","shadows$1","easing","duration","formatMs","milliseconds","getAutoHeightDuration","constant","createTransitions","inputTransitions","mergedEasing","mergedDuration","durationOption","easingOption","isString","isNumber","animatedProp","zIndex","zIndex$1","mixinsInput","transitionsInput","typographyInput","systemTheme","systemCreateTheme","stateClasses","component","child","stateClass","defaultTheme$1","THEME_ID","systemUseThemeProps","styled","styled$1","getSvgIconUtilityClass","useUtilityClasses","SvgIconRoot","_theme$transitions","_theme$transitions$cr","_theme$transitions2","_theme$typography","_theme$typography$pxT","_theme$typography2","_theme$typography2$px","_theme$typography3","_theme$typography3$px","_palette$ownerState$c","_palette","_palette2","_palette3","SvgIcon","inProps","htmlColor","inheritViewBox","titleAccess","viewBox","hasSvgAsChild","more","_jsxs","_jsx","SvgIcon$1","createSvgIcon","unstable_ClassNameGenerator","exports","_utils","ArrowRight","default_1","_createSvgIcon","_jsxRuntime","isHostComponent","appendOwnerState","otherProps","defaultContextValue","ClassNameConfiguratorContext","useClassNamesOverride","disableDefaultClasses","extractEventHandlers","excludeKeys","resolveComponentProps","componentProps","slotState","omitEventHandlers","mergeSlotProps","parameters","getSlotProps","additionalProps","externalSlotProps","externalForwardedProps","joinedClasses","mergedStyle","eventHandlers","componentsPropsWithoutEventHandlers","otherPropsWithoutEventHandlers","internalSlotProps","useSlotProps","_parameters$additiona","skipResolvingSlotProps","rest","resolvedComponentsProps","mergedProps","internalRef","GLOBAL_CLASS_PREFIX","buildStateClass","buildSlotClass","getContainer","container","forwardedRef","disablePortal","mountNode","setMountNode","handleRef","newProps","ReactDOM","top","bottom","right","left","auto","basePlacements","clippingParents","viewport","popper","reference","variationPlacements","placement","placements","beforeRead","read","afterRead","beforeMain","main","afterMain","beforeWrite","write","afterWrite","modifierPhases","getNodeName","getWindow","OwnElement","isHTMLElement","isShadowRoot","attributes","effect","_ref2","initialStyles","styleProperties","attribute","applyStyles$1","getBasePlacement","getUAString","uaData","isLayoutViewport","getBoundingClientRect","includeScale","isFixedStrategy","clientRect","scaleX","scaleY","visualViewport","addVisualOffsets","getLayoutRect","contains","parent","rootNode","next","getComputedStyle","isTableElement","getDocumentElement","getParentNode","getTrueOffsetParent","getContainingBlock","isFirefox","isIE","elementCss","currentNode","getOffsetParent","window","offsetParent","getMainAxisFromPlacement","within","mathMax","mathMin","withinMaxClamp","getFreshSideObject","mergePaddingObject","paddingObject","expandToHashMap","hashMap","toPaddingObject","arrow","_state$modifiersData$","arrowElement","popperOffsets","basePlacement","axis","isVertical","len","arrowRect","minProp","maxProp","endDiff","startDiff","arrowOffsetParent","clientSize","centerToReference","center","offset","axisProp","_options$element","arrow$1","getVariation","unsetSides","roundOffsetsByDPR","win","dpr","mapToStyles","_Object$assign2","popperRect","variation","offsets","gpuAcceleration","adaptive","roundOffsets","isFixed","_offsets$x","_offsets$y","_ref3","hasX","hasY","sideX","sideY","heightProp","widthProp","offsetY","offsetX","commonStyles","_ref4","_Object$assign","computeStyles","_ref5","_options$gpuAccelerat","_options$adaptive","_options$roundOffsets","computeStyles$1","passive","_options$scroll","scroll","_options$resize","resize","scrollParents","scrollParent","eventListeners","hash","getOppositePlacement","matched","getOppositeVariationPlacement","getWindowScroll","scrollLeft","scrollTop","getWindowScrollBarX","getViewportRect","strategy","html","layoutViewport","getDocumentRect","_element$ownerDocumen","winScroll","body","isScrollParent","_getComputedStyle","overflow","overflowX","overflowY","getScrollParent","listScrollParents","list","isBody","updatedList","rectToClientRect","rect","getInnerBoundingClientRect","getClientRectFromMixedType","clippingParent","getClippingParents","canEscapeClipping","clipperElement","getClippingRect","boundary","rootBoundary","mainClippingParents","firstClippingParent","clippingRect","accRect","computeOffsets","commonX","commonY","mainAxis","detectOverflow","_options","_options$placement","_options$strategy","_options$boundary","_options$rootBoundary","_options$elementConte","elementContext","_options$altBoundary","altBoundary","_options$padding","altContext","clippingClientRect","referenceClientRect","popperClientRect","elementClientRect","overflowOffsets","offsetData","multiply","computeAutoPlacement","flipVariations","_options$allowedAutoP","allowedAutoPlacements","allPlacements","allowedPlacements","overflows","getExpandedFallbackPlacements","oppositePlacement","flip","_options$mainAxis","checkMainAxis","_options$altAxis","checkAltAxis","specifiedFallbackPlacements","_options$flipVariatio","preferredPlacement","isBasePlacement","fallbackPlacements","referenceRect","checksMap","makeFallbackChecks","firstFittingPlacement","_basePlacement","isStartVariation","mainVariationSide","altVariationSide","checks","check","numberOfChecks","_loop","_i","fittingPlacement","_ret","flip$1","getSideOffsets","preventedOffsets","isAnySideFullyClipped","hide","referenceOverflow","popperAltOverflow","referenceClippingOffsets","popperEscapeOffsets","isReferenceHidden","hasPopperEscaped","hide$1","distanceAndSkiddingToXY","rects","invertDistance","skidding","distance","_options$offset","_data$state$placement","offset$1","popperOffsets$1","getAltAxis","preventOverflow","_options$tether","tether","_options$tetherOffset","tetherOffset","altAxis","tetherOffsetValue","normalizedTetherOffsetValue","offsetModifierState","_offsetModifierState$","mainSide","altSide","additive","minLen","maxLen","arrowPaddingObject","arrowPaddingMin","arrowPaddingMax","arrowLen","minOffset","maxOffset","clientOffset","offsetModifierValue","tetherMin","tetherMax","preventedOffset","_offsetModifierState$2","_mainSide","_altSide","_offset","_len","_min","_max","isOriginSide","_offsetModifierValue","_tetherMin","_tetherMax","_preventedOffset","preventOverflow$1","getHTMLElementScroll","getNodeScroll","isElementScaled","getCompositeRect","elementOrVirtualElement","isOffsetParentAnElement","offsetParentIsScaled","documentElement","order","modifiers","map","visited","modifier","sort","requires","dep","depModifier","orderModifiers","orderedModifiers","phase","pending","resolve","mergeByName","merged","current","existing","DEFAULT_OPTIONS","areValidElements","_key","popperGenerator","generatorOptions","_generatorOptions","_generatorOptions$def","defaultModifiers","_generatorOptions$def2","defaultOptions","effectCleanupFns","isDestroyed","setOptionsAction","cleanupModifierEffects","runModifierEffects","_state$elements","_state$orderedModifie","_state$orderedModifie2","_ref$options","cleanupFn","noopFn","createPopper","COMPONENT_NAME","getPopperUtilityClass","flipPlacement","resolveAnchorEl","anchorEl","isVirtualElement","defaultPopperOptions","PopperTooltip","_slots$root","initialPlacement","popperOptions","popperRefProp","TransitionProps","tooltipRef","ownRef","popperRef","handlePopperRef","handlePopperRefRef","rtlPlacement","setPlacement","resolvedAnchorElement","setResolvedAnchorElement","handlePopperUpdate","box","popperModifiers","childProps","Root","rootProps","Popper","containerProp","keepMounted","transition","exited","setExited","handleEnter","handleExited","resolvedAnchorEl","display","transitionProps","useThemeSystem","_setPrototypeOf","_inheritsLoose","subClass","superClass","setPrototypeOf","timeoutsShape","TransitionGroupContext","forceReflow","UNMOUNTED","EXITED","ENTERING","ENTERED","EXITING","Transition","_React$Component","_this","parentGroup","appear","initialStatus","prevState","nextIn","_proto","prevProps","nextStatus","exit","enter","mounting","_this2","appearing","maybeNode","maybeAppearing","timeouts","enterTimeout","_this3","nextState","callback","_this4","active","handler","doesNotHaveTimeoutOrListener","maybeNextCallback","_this$props","pt","noop","Transition$1","reflow","getTransitionProps","_style$transitionDura","_style$transitionTimi","getScale","isWebKit154","Grow","addEndListener","inProp","onEnter","onEntered","onEntering","onExit","onExited","onExiting","TransitionComponent","timer","autoTimeout","nodeRef","normalizedTransitionCallback","maybeIsAppearing","handleEntering","isAppearing","transitionDuration","transitionTimingFunction","handleEntered","handleExiting","handleExit","Grow$1","PopperRoot","BasePopper","components","componentsProps","RootComponent","Popper$1","getTooltipUtilityClass","tooltipClasses","tooltipClasses$1","disableInteractive","touch","TooltipPopper","TooltipTooltip","TooltipArrow","hystersisOpen","hystersisTimer","cursorPosition","composeEventHandler","eventHandler","_slots$popper","_slots$transition","_slots$tooltip","_slots$arrow","_slotProps$popper","_ref6","_slotProps$popper2","_slotProps$transition","_slotProps$tooltip","_ref7","_slotProps$tooltip2","_slotProps$arrow","_ref8","_slotProps$arrow2","childrenProp","describeChild","disableFocusListener","disableHoverListener","disableInteractiveProp","disableTouchListener","enterDelay","enterNextDelay","enterTouchDelay","followCursor","idProp","leaveDelay","leaveTouchDelay","onClose","onOpen","PopperComponentProp","PopperProps","title","TransitionComponentProp","isRtl","childNode","setChildNode","arrowRef","setArrowRef","ignoreNonTouchEvents","closeTimer","enterTimer","leaveTimer","touchTimer","setOpenState","prevUserSelect","stopTouchInteraction","handleOpen","handleClose","handleLeave","focusVisibleRef","setChildIsFocusVisible","handleBlur","handleFocus","detectTouchStart","childrenProps","handleMouseOver","handleMouseLeave","handleTouchStart","handleTouchEnd","nativeEvent","handleMouseMove","nameOrDescProps","titleIsString","interactiveWrapperListeners","_PopperProps$popperOp","tooltipModifiers","PopperComponent","TooltipComponent","ArrowComponent","popperProps","tooltipProps","tooltipArrowProps","TransitionPropsInner","Tooltip$1","getIcon","icon","menuLabel","leading","MuiListItemIcon","MenuItem","allowForLeadingIcons","iconPathBefore","iconPathAfter","hasAutoFocus","isDense","isSubMenuParent","hasDisabledGutters","hasDivider","focusVisibleClassName","menuItem","MuiMenuItem","MuiListItemText","getAllGroups","menuDefinition","SubMenu","setAnchorEl","parentMenuItem","parentItemProps","handleParentMenuItemClick","renderSubMenuItems","includedGroups","group","GroupedMenuItemList","Menu","getOrderedGroupItems","groupId","allItems","menuProps","commandHandler","groupsToInclude","sortedGroups","itemArray","allowSpaceForLeadingIcons","createMenuItemProps","isLastItemInGroup","divKey","itemInfo","menuItemProps","TopLevelMenu","columnId","MenuColumn","metadata","Grid","List","GridMenu","multiColumnMenu","sortedColumns","columnNumbers","columnName","col","getUsePromiseOptionsDefaults","usePromise","promiseFactoryCallback","defaultValueRef","optionsDefaultedRef","setIsLoading","promiseIsCurrent","MenuIcon","HamburgerMenuButton","menuProvider","normalMenu","fullMenu","containerRef","ariaLabelPrefix","isMenuOpen","setMenuOpen","showFullMenu","setShowFullMenu","handleMenuItemClick","handleMenuButtonClick","prevIsOpen","isOpening","menuCommandHandler","command","setOffset","normalMenuData","fullMenuData","menu","IconButton","Drawer","isTooltipSuppressed","adjustMarginToAlignToEdge","MuiIconButton","Spinner","LoaderCircle","TextField","hasError","helperText","onFocus","onBlur","ShadLabel","Toolbar","AppBar","MuiToolbar","alertVariants","Alert","AlertTitle","AlertDescription","Card","CardHeader","CardTitle","CardDescription","CardContent","CardFooter","Sonner","Toaster","Slider","SliderPrimitive","Switch","SwitchPrimitives","Tabs","TabsList","TabsTrigger","TabsContent","InstallButton","isInstalling","handleClick","buttonText","Download","EnableButton","isEnabling","DisableButton","isDisabling","UpdateButton","isUpdating","MarkdownRenderer","markdown","anchorTarget","Markdown","FilterButton","Filter","DropdownMenuItemType","DropdownMenuItemType2","FilterDropdown","groups","NoExtensionsFound","MoreInfo","category","downloads","languages","moreInfoUrl","numberFormatted","NumberFormat","handleScrollToBottom","User","locale","LucideLink","CircleHelp","VersionHistory","versionHistory","showAllVersions","setShowAllVersions","currentDate","formatTimeString","dateString","date","dateDiff","yearDiff","monthDiff","dayDiff","timeString","sortedEntries","Footer","publisherDisplayName","fileSize","locales","formattedFileSize","formatBytes","languageNames","codes","displayNames","useEvent","unsubscriber","noopUnsubscriber","useEventAsync","unsubscribe","unsub"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAGA,MAAMA,KAAgBC,GAAoB,EAAE,QAAQ,MAAO,CAAA;AAyDpD,SAASC,KAAMC,GAAsB;AACnC,SAAAH,GAAcI,GAAKD,CAAM,CAAC;AACnC;ACzDO,MAAME,KAAQC,EAAM;AAAA,EACzB,CAAC,EAAE,WAAAC,GAAW,MAAAC,GAAM,GAAGC,EAAA,GAASC,MAE5B,gBAAAC;AAAA,IAAC;AAAA,IAAA;AAAA,MACC,MAAAH;AAAA,MACA,WAAWN;AAAA,QACT;AAAA,QACAK;AAAA,MACF;AAAA,MACA,KAAAG;AAAA,MAEC,GAAGD;AAAA,IAAA;AAAA,EAAA;AAIZ;AACAJ,GAAM,cAAc;ACNpB,MAAMO,KAAmBC;AAAA,EACvB,CACE,EAA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;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AACF,GAAGC,KAAI;AAAA,EACL;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA;AAAA;AAAA,EAGA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EAC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;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","x_google_ignoreList":[3,43,44,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,83,84,85,86,87,88,89,90,91,92,93,94,95,96,97,98,99,100,101,102,103,104,105,106,107,108,109,110,111,112,113,114,115,116,117,118,119,120,121,122,123,124,125,126,127,128,129,130,131,132,133,134,135,136,137,138,139,140,141,142,143,144,145,146,147,148,149,150,151,152,153,154,155,156,157,158,159,160,161,162,163,164,165,166,167,168,169,170,171,172,173,174,175,176,177,178,179,180,181,182,183,184,185,186,187,188,189,190,191,192,193,194,195,196,197,198,199,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,226]} \ No newline at end of file +{"version":3,"file":"index.js","sources":["../src/utils/shadcn-ui.util.ts","../src/components/shadcn-ui/input.tsx","../src/components/advanced/book-chapter-control/book-chapter-input.component.tsx","../../../node_modules/@sillsdev/scripture/dist/index.es.js","../src/components/shadcn-ui/dropdown-menu.tsx","../src/components/advanced/book-chapter-control/book-menu-item.component.tsx","../src/components/advanced/book-chapter-control/chapter-select.component.tsx","../src/components/advanced/book-chapter-control/go-to-menu-item.component.tsx","../src/components/advanced/book-chapter-control/book-chapter-control.component.tsx","../src/components/shadcn-ui/button.tsx","../src/components/shadcn-ui/label.tsx","../src/components/shadcn-ui/radio-group.tsx","../src/components/shadcn-ui/popover.tsx","../src/components/shadcn-ui/dialog.tsx","../src/components/shadcn-ui/command.tsx","../src/components/basics/combo-box.component.tsx","../src/components/basics/chapter-range-selector.component.tsx","../src/components/advanced/book-selector.component.tsx","../src/components/advanced/data-table/data-table-column-toggle.component.tsx","../src/components/shadcn-ui/select.tsx","../src/components/advanced/data-table/data-table-pagination.component.tsx","../src/components/shadcn-ui/table.tsx","../src/components/advanced/data-table/data-table.component.tsx","../src/components/advanced/inventory/occurrences-table.component.tsx","../src/components/shadcn-ui/checkbox.tsx","../src/components/advanced/inventory/inventory-utils.ts","../src/components/shadcn-ui/toggle.tsx","../src/components/shadcn-ui/toggle-group.tsx","../src/components/advanced/inventory/inventory-columns.tsx","../src/components/advanced/inventory/inventory.component.tsx","../src/components/basics/search-bar.component.tsx","../src/components/basics/tabs-vertical.tsx","../src/components/advanced/tab-navigation-content-search.component.tsx","../src/components/shadcn-ui/separator.tsx","../src/components/shadcn-ui/skeleton.tsx","../src/components/shadcn-ui/tooltip.tsx","../src/components/shadcn-ui/sidebar.tsx","../src/components/advanced/settings-components/settings-sidebar.component.tsx","../src/components/advanced/settings-components/settings-sidebar-content-search.component.tsx","../src/components/advanced/scripture-results-viewer/scripture-results-viewer.component.tsx","../src/components/advanced/scroll-group-selector.component.tsx","../src/components/advanced/settings-components/settings-list.component.tsx","../src/components/basics/checklist.component.tsx","../../../node_modules/@babel/runtime/helpers/interopRequireDefault.js","../../../node_modules/@mui/utils/chainPropTypes/chainPropTypes.js","../../../node_modules/@babel/runtime/helpers/esm/extends.js","../../../node_modules/@mui/utils/deepmerge/deepmerge.js","../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.production.min.js","../../../node_modules/prop-types/node_modules/react-is/cjs/react-is.development.js","../../../node_modules/prop-types/node_modules/react-is/index.js","../../../node_modules/object-assign/index.js","../../../node_modules/prop-types/lib/ReactPropTypesSecret.js","../../../node_modules/prop-types/lib/has.js","../../../node_modules/prop-types/checkPropTypes.js","../../../node_modules/prop-types/factoryWithTypeCheckers.js","../../../node_modules/prop-types/factoryWithThrowingShims.js","../../../node_modules/prop-types/index.js","../../../node_modules/@mui/utils/elementAcceptingRef/elementAcceptingRef.js","../../../node_modules/@mui/utils/exactProp/exactProp.js","../../../node_modules/@mui/utils/formatMuiErrorMessage/formatMuiErrorMessage.js","../../../node_modules/react-is/cjs/react-is.production.min.js","../../../node_modules/react-is/cjs/react-is.development.js","../../../node_modules/react-is/index.js","../../../node_modules/@mui/utils/getDisplayName/getDisplayName.js","../../../node_modules/@mui/utils/HTMLElementType/HTMLElementType.js","../../../node_modules/@mui/utils/refType/refType.js","../../../node_modules/@mui/utils/capitalize/capitalize.js","../../../node_modules/@mui/utils/createChainedFunction/createChainedFunction.js","../../../node_modules/@mui/utils/debounce/debounce.js","../../../node_modules/@mui/utils/deprecatedPropType/deprecatedPropType.js","../../../node_modules/@mui/utils/isMuiElement/isMuiElement.js","../../../node_modules/@mui/utils/ownerDocument/ownerDocument.js","../../../node_modules/@mui/utils/ownerWindow/ownerWindow.js","../../../node_modules/@mui/utils/requirePropFactory/requirePropFactory.js","../../../node_modules/@mui/utils/setRef/setRef.js","../../../node_modules/@mui/utils/useEnhancedEffect/useEnhancedEffect.js","../../../node_modules/@mui/utils/useId/useId.js","../../../node_modules/@mui/utils/unsupportedProp/unsupportedProp.js","../../../node_modules/@mui/utils/useControlled/useControlled.js","../../../node_modules/@mui/utils/useEventCallback/useEventCallback.js","../../../node_modules/@mui/utils/useForkRef/useForkRef.js","../../../node_modules/@mui/utils/useLazyRef/useLazyRef.js","../../../node_modules/@mui/utils/useOnMount/useOnMount.js","../../../node_modules/@mui/utils/useTimeout/useTimeout.js","../../../node_modules/@mui/utils/useIsFocusVisible/useIsFocusVisible.js","../../../node_modules/@mui/utils/resolveProps/resolveProps.js","../../../node_modules/@mui/utils/composeClasses/composeClasses.js","../../../node_modules/@mui/utils/ClassNameGenerator/ClassNameGenerator.js","../../../node_modules/@mui/utils/generateUtilityClass/generateUtilityClass.js","../../../node_modules/@mui/utils/generateUtilityClasses/generateUtilityClasses.js","../../../node_modules/@mui/utils/clamp/clamp.js","../../../node_modules/@babel/runtime/helpers/esm/objectWithoutPropertiesLoose.js","../../../node_modules/@mui/system/esm/createTheme/createBreakpoints.js","../../../node_modules/@mui/system/esm/createTheme/shape.js","../../../node_modules/@mui/system/esm/responsivePropType.js","../../../node_modules/@mui/system/esm/merge.js","../../../node_modules/@mui/system/esm/breakpoints.js","../../../node_modules/@mui/system/esm/style.js","../../../node_modules/@mui/system/esm/memoize.js","../../../node_modules/@mui/system/esm/spacing.js","../../../node_modules/@mui/system/esm/createTheme/createSpacing.js","../../../node_modules/@mui/system/esm/compose.js","../../../node_modules/@mui/system/esm/borders.js","../../../node_modules/@mui/system/esm/cssGrid.js","../../../node_modules/@mui/system/esm/palette.js","../../../node_modules/@mui/system/esm/sizing.js","../../../node_modules/@mui/system/esm/styleFunctionSx/defaultSxConfig.js","../../../node_modules/@mui/system/esm/styleFunctionSx/styleFunctionSx.js","../../../node_modules/@mui/system/esm/createTheme/applyStyles.js","../../../node_modules/@mui/system/esm/createTheme/createTheme.js","../../../node_modules/@mui/system/esm/useThemeWithoutDefault.js","../../../node_modules/@mui/system/esm/useTheme.js","../../../node_modules/@mui/system/esm/createStyled.js","../../../node_modules/@mui/system/esm/useThemeProps/getThemeProps.js","../../../node_modules/@mui/system/esm/useThemeProps/useThemeProps.js","../../../node_modules/@mui/system/esm/colorManipulator.js","../../../node_modules/@mui/material/styles/createMixins.js","../../../node_modules/@mui/material/colors/common.js","../../../node_modules/@mui/material/colors/grey.js","../../../node_modules/@mui/material/colors/purple.js","../../../node_modules/@mui/material/colors/red.js","../../../node_modules/@mui/material/colors/orange.js","../../../node_modules/@mui/material/colors/blue.js","../../../node_modules/@mui/material/colors/lightBlue.js","../../../node_modules/@mui/material/colors/green.js","../../../node_modules/@mui/material/styles/createPalette.js","../../../node_modules/@mui/material/styles/createTypography.js","../../../node_modules/@mui/material/styles/shadows.js","../../../node_modules/@mui/material/styles/createTransitions.js","../../../node_modules/@mui/material/styles/zIndex.js","../../../node_modules/@mui/material/styles/createTheme.js","../../../node_modules/@mui/material/styles/defaultTheme.js","../../../node_modules/@mui/material/styles/identifier.js","../../../node_modules/@mui/material/styles/useThemeProps.js","../../../node_modules/@mui/material/styles/styled.js","../../../node_modules/@mui/material/SvgIcon/svgIconClasses.js","../../../node_modules/@mui/material/SvgIcon/SvgIcon.js","../../../node_modules/@mui/material/utils/createSvgIcon.js","../../../node_modules/@mui/material/utils/index.js","../../../node_modules/@mui/icons-material/utils/createSvgIcon.js","../../../node_modules/@mui/icons-material/ArrowRight.js","../../../node_modules/@mui/base/utils/isHostComponent.js","../../../node_modules/@mui/base/utils/appendOwnerState.js","../../../node_modules/@mui/base/utils/ClassNameConfigurator.js","../../../node_modules/@mui/base/utils/extractEventHandlers.js","../../../node_modules/@mui/base/utils/resolveComponentProps.js","../../../node_modules/@mui/base/utils/omitEventHandlers.js","../../../node_modules/@mui/base/utils/mergeSlotProps.js","../../../node_modules/@mui/base/utils/useSlotProps.js","../../../node_modules/@mui/base/generateUtilityClass/index.js","../../../node_modules/@mui/base/generateUtilityClasses/index.js","../../../node_modules/@mui/base/Portal/Portal.js","../../../node_modules/@popperjs/core/lib/enums.js","../../../node_modules/@popperjs/core/lib/dom-utils/getNodeName.js","../../../node_modules/@popperjs/core/lib/dom-utils/getWindow.js","../../../node_modules/@popperjs/core/lib/dom-utils/instanceOf.js","../../../node_modules/@popperjs/core/lib/modifiers/applyStyles.js","../../../node_modules/@popperjs/core/lib/utils/getBasePlacement.js","../../../node_modules/@popperjs/core/lib/utils/math.js","../../../node_modules/@popperjs/core/lib/utils/userAgent.js","../../../node_modules/@popperjs/core/lib/dom-utils/isLayoutViewport.js","../../../node_modules/@popperjs/core/lib/dom-utils/getBoundingClientRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/getLayoutRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/contains.js","../../../node_modules/@popperjs/core/lib/dom-utils/getComputedStyle.js","../../../node_modules/@popperjs/core/lib/dom-utils/isTableElement.js","../../../node_modules/@popperjs/core/lib/dom-utils/getDocumentElement.js","../../../node_modules/@popperjs/core/lib/dom-utils/getParentNode.js","../../../node_modules/@popperjs/core/lib/dom-utils/getOffsetParent.js","../../../node_modules/@popperjs/core/lib/utils/getMainAxisFromPlacement.js","../../../node_modules/@popperjs/core/lib/utils/within.js","../../../node_modules/@popperjs/core/lib/utils/getFreshSideObject.js","../../../node_modules/@popperjs/core/lib/utils/mergePaddingObject.js","../../../node_modules/@popperjs/core/lib/utils/expandToHashMap.js","../../../node_modules/@popperjs/core/lib/modifiers/arrow.js","../../../node_modules/@popperjs/core/lib/utils/getVariation.js","../../../node_modules/@popperjs/core/lib/modifiers/computeStyles.js","../../../node_modules/@popperjs/core/lib/modifiers/eventListeners.js","../../../node_modules/@popperjs/core/lib/utils/getOppositePlacement.js","../../../node_modules/@popperjs/core/lib/utils/getOppositeVariationPlacement.js","../../../node_modules/@popperjs/core/lib/dom-utils/getWindowScroll.js","../../../node_modules/@popperjs/core/lib/dom-utils/getWindowScrollBarX.js","../../../node_modules/@popperjs/core/lib/dom-utils/getViewportRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/getDocumentRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/isScrollParent.js","../../../node_modules/@popperjs/core/lib/dom-utils/getScrollParent.js","../../../node_modules/@popperjs/core/lib/dom-utils/listScrollParents.js","../../../node_modules/@popperjs/core/lib/utils/rectToClientRect.js","../../../node_modules/@popperjs/core/lib/dom-utils/getClippingRect.js","../../../node_modules/@popperjs/core/lib/utils/computeOffsets.js","../../../node_modules/@popperjs/core/lib/utils/detectOverflow.js","../../../node_modules/@popperjs/core/lib/utils/computeAutoPlacement.js","../../../node_modules/@popperjs/core/lib/modifiers/flip.js","../../../node_modules/@popperjs/core/lib/modifiers/hide.js","../../../node_modules/@popperjs/core/lib/modifiers/offset.js","../../../node_modules/@popperjs/core/lib/modifiers/popperOffsets.js","../../../node_modules/@popperjs/core/lib/utils/getAltAxis.js","../../../node_modules/@popperjs/core/lib/modifiers/preventOverflow.js","../../../node_modules/@popperjs/core/lib/dom-utils/getHTMLElementScroll.js","../../../node_modules/@popperjs/core/lib/dom-utils/getNodeScroll.js","../../../node_modules/@popperjs/core/lib/dom-utils/getCompositeRect.js","../../../node_modules/@popperjs/core/lib/utils/orderModifiers.js","../../../node_modules/@popperjs/core/lib/utils/debounce.js","../../../node_modules/@popperjs/core/lib/utils/mergeByName.js","../../../node_modules/@popperjs/core/lib/createPopper.js","../../../node_modules/@popperjs/core/lib/popper.js","../../../node_modules/@mui/base/Popper/popperClasses.js","../../../node_modules/@mui/base/Popper/Popper.js","../../../node_modules/@mui/material/styles/useTheme.js","../../../node_modules/@babel/runtime/helpers/esm/setPrototypeOf.js","../../../node_modules/@babel/runtime/helpers/esm/inheritsLoose.js","../../../node_modules/react-transition-group/esm/config.js","../../../node_modules/react-transition-group/esm/utils/PropTypes.js","../../../node_modules/react-transition-group/esm/TransitionGroupContext.js","../../../node_modules/react-transition-group/esm/utils/reflow.js","../../../node_modules/react-transition-group/esm/Transition.js","../../../node_modules/@mui/material/transitions/utils.js","../../../node_modules/@mui/material/Grow/Grow.js","../../../node_modules/@mui/material/Popper/Popper.js","../../../node_modules/@mui/material/Tooltip/tooltipClasses.js","../../../node_modules/@mui/material/Tooltip/Tooltip.js","../src/components/mui/menu-item.component.tsx","../src/components/mui/grouped-menu-item-list.component.tsx","../src/components/mui/top-level-menu.component.tsx","../src/components/mui/grid-menu.component.tsx","../src/hooks/use-promise.hook.ts","../../../node_modules/@mui/icons-material/esm/Menu.js","../src/components/mui/hamburger-menu-button.component.tsx","../src/components/mui/icon-button.component.tsx","../src/components/basics/spinner.component.tsx","../src/components/basics/text-field.component.tsx","../src/components/mui/toolbar.component.tsx","../src/components/shadcn-ui/alert.tsx","../src/components/shadcn-ui/card.tsx","../src/components/shadcn-ui/sonner.tsx","../src/components/shadcn-ui/slider.tsx","../src/components/shadcn-ui/switch.tsx","../src/components/shadcn-ui/tabs.tsx","../src/components/advanced/extension-marketplace/buttons/install-button.component.tsx","../src/components/advanced/extension-marketplace/buttons/enable-button.component.tsx","../src/components/advanced/extension-marketplace/buttons/disable-button.component.tsx","../src/components/advanced/extension-marketplace/buttons/update-button.component.tsx","../src/components/advanced/extension-marketplace/markdown-renderer.component.tsx","../src/components/advanced/extension-marketplace/buttons/filter-button.component.tsx","../src/components/advanced/extension-marketplace/filter-dropdown.component.tsx","../src/components/advanced/extension-marketplace/no-extensions-found.component.tsx","../src/components/advanced/extension-marketplace/more-info.component.tsx","../src/components/advanced/extension-marketplace/version-history.component.tsx","../src/components/advanced/extension-marketplace/footer.component.tsx","../src/hooks/use-event.hook.ts","../src/hooks/use-event-async.hook.ts"],"sourcesContent":["import { type ClassValue, clsx } from 'clsx';\nimport { extendTailwindMerge } from 'tailwind-merge';\n\nconst twMergeCustom = extendTailwindMerge({ prefix: 'tw-' });\n\n/**\n * Tailwind and CSS class application helper function. Uses\n * [`clsx`](https://www.npmjs.com/package/clsx) to make it easy to apply classes conditionally using\n * object syntax, and uses [`tailwind-merge`](https://www.npmjs.com/package/tailwind-merge) to make\n * it easy to merge/overwrite Tailwind classes in a programmer-logic-friendly way.\n *\n * Note: `tailwind-merge` is configured to use the prefix `tw-`, so you must use the same prefix\n * with any Tailwind classes you use with this function to successfully overwrite other Tailwind\n * classes. `platform-bible-react` is configured to use `tw-` as its Tailwind prefix, so any\n * Tailwind classes you pass into `platform-bible-react` components will be compared using the `tw-`\n * prefix.\n *\n * This function was popularized by\n * [shadcn/ui](https://ui.shadcn.com/docs/installation/manual#add-a-cn-helper). See [ByteGrad's\n * explanation video](https://www.youtube.com/watch?v=re2JFITR7TI) for more information.\n *\n * @example\n *\n * ```typescript\n * const borderShouldBeBlue = true;\n * const textShouldBeRed = true;\n * const heightShouldBe20 = false;\n * const classString = cn(\n * 'tw-bg-primary tw-h-10 tw-text-primary-foreground',\n * 'tw-bg-secondary',\n * {\n * 'tw-border-blue-500': borderShouldBeBlue,\n * 'tw-text-red-500': textShouldBeRed,\n * 'tw-h-20': heightShouldBe20,\n * },\n * 'some-class',\n * );\n * ```\n *\n * The resulting `classString` is `'tw-h-10 tw-bg-secondary tw-border-blue-500 tw-text-red-500\n * some-class'`\n *\n * - Notice that `'tw-bg-secondary'`, specified later, overwrote `'tw-bg-primary'`, specified earlier,\n * because they are Tailwind classes that affect the same css property\n * - Notice that `'tw-text-red-500'`, specified later, overwrote `'tw-text-primary-foreground'`,\n * specified earlier, because they are Tailwind classes that affect the same css property\n * - Notice that `'tw-h-20'`, specified later, did not overwrite `'tw-h-10'`, specified earlier,\n * because `'tw-h-20'` is part of a conditional class object and its value evaluated to `false`;\n * therefore it was not applied\n * - Notice that `'some-class'` was applied. This function is not limited only to Tailwind classes.\n *\n *\n * @param inputs Class strings or `clsx` conditional class objects to merge. Tailwind classes\n * specified later in the arguments overwrite similar Tailwind classes specified earlier in the\n * arguments\n * @returns Class string containing all applicable classes from the arguments based on the rules\n * described above\n */\n// shadcn/ui uses this export in its boilerplate code\n// eslint-disable-next-line import/prefer-default-export\nexport function cn(...inputs: ClassValue[]) {\n return twMergeCustom(clsx(inputs));\n}\n","import React from 'react';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport interface InputProps extends React.InputHTMLAttributes {}\n\nexport const Input = React.forwardRef(\n ({ className, type, ...props }, ref) => {\n return (\n \n );\n },\n);\nInput.displayName = 'Input';\n","import { FocusEventHandler, forwardRef, KeyboardEvent, MouseEventHandler } from 'react';\nimport { History } from 'lucide-react';\nimport { Input as ShadInput } from '@/components/shadcn-ui/input';\n\nexport type BookChapterInputProps = {\n handleSearch: (searchString: string) => void;\n handleKeyDown: (event: KeyboardEvent) => void;\n handleOnClick: MouseEventHandler;\n handleSubmit: () => void;\n onFocus?: FocusEventHandler;\n value: string;\n placeholder: string;\n};\n\n// Shadcn Input sets type to \"button\"- HAVE to prop spread before setting type\nconst BookChapterInput = forwardRef(\n (\n { handleSearch, handleKeyDown, handleOnClick, handleSubmit, ...props }: BookChapterInputProps,\n ref,\n ) => {\n return (\n
    \n handleSearch(event.target.value)}\n onKeyDown={(e) => {\n if (e.key === 'Enter') {\n handleSubmit();\n }\n handleKeyDown(e);\n }}\n onClick={handleOnClick}\n ref={ref}\n />\n {\n // eslint-disable-next-line no-console\n console.log('back in history');\n }}\n />\n
    \n );\n },\n);\n\nexport default BookChapterInput;\n","var P = Object.defineProperty;\nvar R = (t, e, s) => e in t ? P(t, e, { enumerable: !0, configurable: !0, writable: !0, value: s }) : t[e] = s;\nvar n = (t, e, s) => R(t, typeof e != \"symbol\" ? e + \"\" : e, s);\nclass _ {\n constructor() {\n n(this, \"books\");\n n(this, \"firstSelectedBookNum\");\n n(this, \"lastSelectedBookNum\");\n n(this, \"count\");\n n(this, \"selectedBookNumbers\");\n n(this, \"selectedBookIds\");\n }\n}\nconst N = [\n \"GEN\",\n \"EXO\",\n \"LEV\",\n \"NUM\",\n \"DEU\",\n \"JOS\",\n \"JDG\",\n \"RUT\",\n \"1SA\",\n \"2SA\",\n // 10\n \"1KI\",\n \"2KI\",\n \"1CH\",\n \"2CH\",\n \"EZR\",\n \"NEH\",\n \"EST\",\n \"JOB\",\n \"PSA\",\n \"PRO\",\n // 20\n \"ECC\",\n \"SNG\",\n \"ISA\",\n \"JER\",\n \"LAM\",\n \"EZK\",\n \"DAN\",\n \"HOS\",\n \"JOL\",\n \"AMO\",\n // 30\n \"OBA\",\n \"JON\",\n \"MIC\",\n \"NAM\",\n \"HAB\",\n \"ZEP\",\n \"HAG\",\n \"ZEC\",\n \"MAL\",\n \"MAT\",\n // 40\n \"MRK\",\n \"LUK\",\n \"JHN\",\n \"ACT\",\n \"ROM\",\n \"1CO\",\n \"2CO\",\n \"GAL\",\n \"EPH\",\n \"PHP\",\n // 50\n \"COL\",\n \"1TH\",\n \"2TH\",\n \"1TI\",\n \"2TI\",\n \"TIT\",\n \"PHM\",\n \"HEB\",\n \"JAS\",\n \"1PE\",\n // 60\n \"2PE\",\n \"1JN\",\n \"2JN\",\n \"3JN\",\n \"JUD\",\n \"REV\",\n \"TOB\",\n \"JDT\",\n \"ESG\",\n \"WIS\",\n // 70\n \"SIR\",\n \"BAR\",\n \"LJE\",\n \"S3Y\",\n \"SUS\",\n \"BEL\",\n \"1MA\",\n \"2MA\",\n \"3MA\",\n \"4MA\",\n // 80\n \"1ES\",\n \"2ES\",\n \"MAN\",\n \"PS2\",\n \"ODA\",\n \"PSS\",\n \"JSA\",\n // actual variant text for JOS, now in LXA text\n \"JDB\",\n // actual variant text for JDG, now in LXA text\n \"TBS\",\n // actual variant text for TOB, now in LXA text\n \"SST\",\n // actual variant text for SUS, now in LXA text // 90\n \"DNT\",\n // actual variant text for DAN, now in LXA text\n \"BLT\",\n // actual variant text for BEL, now in LXA text\n \"XXA\",\n \"XXB\",\n \"XXC\",\n \"XXD\",\n \"XXE\",\n \"XXF\",\n \"XXG\",\n \"FRT\",\n // 100\n \"BAK\",\n \"OTH\",\n \"3ES\",\n // Used previously but really should be 2ES\n \"EZA\",\n // Used to be called 4ES, but not actually in any known project\n \"5EZ\",\n // Used to be called 5ES, but not actually in any known project\n \"6EZ\",\n // Used to be called 6ES, but not actually in any known project\n \"INT\",\n \"CNC\",\n \"GLO\",\n \"TDX\",\n // 110\n \"NDX\",\n \"DAG\",\n \"PS3\",\n \"2BA\",\n \"LBA\",\n \"JUB\",\n \"ENO\",\n \"1MQ\",\n \"2MQ\",\n \"3MQ\",\n // 120\n \"REP\",\n \"4BA\",\n \"LAO\"\n], B = [\n \"XXA\",\n \"XXB\",\n \"XXC\",\n \"XXD\",\n \"XXE\",\n \"XXF\",\n \"XXG\",\n \"FRT\",\n \"BAK\",\n \"OTH\",\n \"INT\",\n \"CNC\",\n \"GLO\",\n \"TDX\",\n \"NDX\"\n], O = [\n \"Genesis\",\n \"Exodus\",\n \"Leviticus\",\n \"Numbers\",\n \"Deuteronomy\",\n \"Joshua\",\n \"Judges\",\n \"Ruth\",\n \"1 Samuel\",\n \"2 Samuel\",\n \"1 Kings\",\n \"2 Kings\",\n \"1 Chronicles\",\n \"2 Chronicles\",\n \"Ezra\",\n \"Nehemiah\",\n \"Esther (Hebrew)\",\n \"Job\",\n \"Psalms\",\n \"Proverbs\",\n \"Ecclesiastes\",\n \"Song of Songs\",\n \"Isaiah\",\n \"Jeremiah\",\n \"Lamentations\",\n \"Ezekiel\",\n \"Daniel (Hebrew)\",\n \"Hosea\",\n \"Joel\",\n \"Amos\",\n \"Obadiah\",\n \"Jonah\",\n \"Micah\",\n \"Nahum\",\n \"Habakkuk\",\n \"Zephaniah\",\n \"Haggai\",\n \"Zechariah\",\n \"Malachi\",\n \"Matthew\",\n \"Mark\",\n \"Luke\",\n \"John\",\n \"Acts\",\n \"Romans\",\n \"1 Corinthians\",\n \"2 Corinthians\",\n \"Galatians\",\n \"Ephesians\",\n \"Philippians\",\n \"Colossians\",\n \"1 Thessalonians\",\n \"2 Thessalonians\",\n \"1 Timothy\",\n \"2 Timothy\",\n \"Titus\",\n \"Philemon\",\n \"Hebrews\",\n \"James\",\n \"1 Peter\",\n \"2 Peter\",\n \"1 John\",\n \"2 John\",\n \"3 John\",\n \"Jude\",\n \"Revelation\",\n \"Tobit\",\n \"Judith\",\n \"Esther Greek\",\n \"Wisdom of Solomon\",\n \"Sirach (Ecclesiasticus)\",\n \"Baruch\",\n \"Letter of Jeremiah\",\n \"Song of 3 Young Men\",\n \"Susanna\",\n \"Bel and the Dragon\",\n \"1 Maccabees\",\n \"2 Maccabees\",\n \"3 Maccabees\",\n \"4 Maccabees\",\n \"1 Esdras (Greek)\",\n \"2 Esdras (Latin)\",\n \"Prayer of Manasseh\",\n \"Psalm 151\",\n \"Odes\",\n \"Psalms of Solomon\",\n // WARNING, if you change the spelling of the *obsolete* tag be sure to update\n // IsObsolete routine\n \"Joshua A. *obsolete*\",\n \"Judges B. *obsolete*\",\n \"Tobit S. *obsolete*\",\n \"Susanna Th. *obsolete*\",\n \"Daniel Th. *obsolete*\",\n \"Bel Th. *obsolete*\",\n \"Extra A\",\n \"Extra B\",\n \"Extra C\",\n \"Extra D\",\n \"Extra E\",\n \"Extra F\",\n \"Extra G\",\n \"Front Matter\",\n \"Back Matter\",\n \"Other Matter\",\n \"3 Ezra *obsolete*\",\n \"Apocalypse of Ezra\",\n \"5 Ezra (Latin Prologue)\",\n \"6 Ezra (Latin Epilogue)\",\n \"Introduction\",\n \"Concordance \",\n \"Glossary \",\n \"Topical Index\",\n \"Names Index\",\n \"Daniel Greek\",\n \"Psalms 152-155\",\n \"2 Baruch (Apocalypse)\",\n \"Letter of Baruch\",\n \"Jubilees\",\n \"Enoch\",\n \"1 Meqabyan\",\n \"2 Meqabyan\",\n \"3 Meqabyan\",\n \"Reproof (Proverbs 25-31)\",\n \"4 Baruch (Rest of Baruch)\",\n \"Laodiceans\"\n], S = K();\nfunction g(t, e = !0) {\n return e && (t = t.toUpperCase()), t in S ? S[t] : 0;\n}\nfunction k(t) {\n return g(t) > 0;\n}\nfunction x(t) {\n const e = typeof t == \"string\" ? g(t) : t;\n return e >= 40 && e <= 66;\n}\nfunction T(t) {\n return (typeof t == \"string\" ? g(t) : t) <= 39;\n}\nfunction X(t) {\n return t <= 66;\n}\nfunction V(t) {\n const e = typeof t == \"string\" ? g(t) : t;\n return w(e) && !X(e);\n}\nfunction* L() {\n for (let t = 1; t <= N.length; t++) yield t;\n}\nconst G = 1, A = N.length;\nfunction H() {\n return [\"XXA\", \"XXB\", \"XXC\", \"XXD\", \"XXE\", \"XXF\", \"XXG\"];\n}\nfunction C(t, e = \"***\") {\n const s = t - 1;\n return s < 0 || s >= N.length ? e : N[s];\n}\nfunction I(t) {\n return t <= 0 || t > A ? \"******\" : O[t - 1];\n}\nfunction y(t) {\n return I(g(t));\n}\nfunction w(t) {\n const e = typeof t == \"number\" ? C(t) : t;\n return k(e) && !B.includes(e);\n}\nfunction q(t) {\n const e = typeof t == \"number\" ? C(t) : t;\n return k(e) && B.includes(e);\n}\nfunction U(t) {\n return O[t - 1].includes(\"*obsolete*\");\n}\nfunction K() {\n const t = {};\n for (let e = 0; e < N.length; e++)\n t[N[e]] = e + 1;\n return t;\n}\nconst m = {\n allBookIds: N,\n nonCanonicalIds: B,\n bookIdToNumber: g,\n isBookIdValid: k,\n isBookNT: x,\n isBookOT: T,\n isBookOTNT: X,\n isBookDC: V,\n allBookNumbers: L,\n firstBook: G,\n lastBook: A,\n extraBooks: H,\n bookNumberToId: C,\n bookNumberToEnglishName: I,\n bookIdToEnglishName: y,\n isCanonical: w,\n isExtraMaterial: q,\n isObsolete: U\n};\nvar l = /* @__PURE__ */ ((t) => (t[t.Unknown = 0] = \"Unknown\", t[t.Original = 1] = \"Original\", t[t.Septuagint = 2] = \"Septuagint\", t[t.Vulgate = 3] = \"Vulgate\", t[t.English = 4] = \"English\", t[t.RussianProtestant = 5] = \"RussianProtestant\", t[t.RussianOrthodox = 6] = \"RussianOrthodox\", t))(l || {});\nconst h = class h {\n // private versInfo: Versification;\n constructor(e) {\n n(this, \"name\");\n n(this, \"fullPath\");\n n(this, \"isPresent\");\n n(this, \"hasVerseSegments\");\n n(this, \"isCustomized\");\n n(this, \"baseVersification\");\n n(this, \"scriptureBooks\");\n n(this, \"_type\");\n if (e == null)\n throw new Error(\"Argument undefined\");\n typeof e == \"string\" ? (this.name = e, this._type = l[e]) : (this._type = e, this.name = l[e]);\n }\n get type() {\n return this._type;\n }\n equals(e) {\n return !e.type || !this.type ? !1 : e.type === this.type;\n }\n};\nn(h, \"Original\", new h(l.Original)), n(h, \"Septuagint\", new h(l.Septuagint)), n(h, \"Vulgate\", new h(l.Vulgate)), n(h, \"English\", new h(l.English)), n(h, \"RussianProtestant\", new h(l.RussianProtestant)), n(h, \"RussianOrthodox\", new h(l.RussianOrthodox));\nlet c = h;\nfunction E(t, e) {\n const s = e[0];\n for (let r = 1; r < e.length; r++)\n t = t.split(e[r]).join(s);\n return t.split(s);\n}\nvar D = /* @__PURE__ */ ((t) => (t[t.Valid = 0] = \"Valid\", t[t.UnknownVersification = 1] = \"UnknownVersification\", t[t.OutOfRange = 2] = \"OutOfRange\", t[t.VerseOutOfOrder = 3] = \"VerseOutOfOrder\", t[t.VerseRepeated = 4] = \"VerseRepeated\", t))(D || {});\nconst i = class i {\n constructor(e, s, r, a) {\n /** Not yet implemented. */\n n(this, \"firstChapter\");\n /** Not yet implemented. */\n n(this, \"lastChapter\");\n /** Not yet implemented. */\n n(this, \"lastVerse\");\n /** Not yet implemented. */\n n(this, \"hasSegmentsDefined\");\n /** Not yet implemented. */\n n(this, \"text\");\n /** Not yet implemented. */\n n(this, \"BBBCCCVVVS\");\n /** Not yet implemented. */\n n(this, \"longHashCode\");\n /** The versification of the reference. */\n n(this, \"versification\");\n n(this, \"rtlMark\", \"‏\");\n n(this, \"_bookNum\", 0);\n n(this, \"_chapterNum\", 0);\n n(this, \"_verseNum\", 0);\n n(this, \"_verse\");\n if (r == null && a == null)\n if (e != null && typeof e == \"string\") {\n const o = e, u = s != null && s instanceof c ? s : void 0;\n this.setEmpty(u), this.parse(o);\n } else if (e != null && typeof e == \"number\") {\n const o = s != null && s instanceof c ? s : void 0;\n this.setEmpty(o), this._verseNum = e % i.chapterDigitShifter, this._chapterNum = Math.floor(\n e % i.bookDigitShifter / i.chapterDigitShifter\n ), this._bookNum = Math.floor(e / i.bookDigitShifter);\n } else if (s == null)\n if (e != null && e instanceof i) {\n const o = e;\n this._bookNum = o.bookNum, this._chapterNum = o.chapterNum, this._verseNum = o.verseNum, this._verse = o.verse, this.versification = o.versification;\n } else {\n if (e == null) return;\n const o = e instanceof c ? e : i.defaultVersification;\n this.setEmpty(o);\n }\n else\n throw new Error(\"VerseRef constructor not supported.\");\n else if (e != null && s != null && r != null)\n if (typeof e == \"string\" && typeof s == \"string\" && typeof r == \"string\")\n this.setEmpty(a), this.updateInternal(e, s, r);\n else if (typeof e == \"number\" && typeof s == \"number\" && typeof r == \"number\")\n this._bookNum = e, this._chapterNum = s, this._verseNum = r, this.versification = a ?? i.defaultVersification;\n else\n throw new Error(\"VerseRef constructor not supported.\");\n else\n throw new Error(\"VerseRef constructor not supported.\");\n }\n /**\n * Determines if the verse string is in a valid format (does not consider versification).\n */\n static isVerseParseable(e) {\n return e.length > 0 && \"0123456789\".includes(e[0]) && !e.endsWith(this.verseRangeSeparator) && !e.endsWith(this.verseSequenceIndicator);\n }\n /**\n * Tries to parse the specified string into a verse reference.\n * @param str - The string to attempt to parse.\n * @returns success: `true` if the specified string was successfully parsed, `false` otherwise.\n * @returns verseRef: The result of the parse if successful, or empty VerseRef if it failed\n */\n static tryParse(e) {\n let s;\n try {\n return s = new i(e), { success: !0, verseRef: s };\n } catch (r) {\n if (r instanceof v)\n return s = new i(), { success: !1, verseRef: s };\n throw r;\n }\n }\n /**\n * Gets the reference as a comparable integer where the book, chapter, and verse each occupy 3\n * digits.\n * @param bookNum - Book number (this is 1-based, not an index).\n * @param chapterNum - Chapter number.\n * @param verseNum - Verse number.\n * @returns The reference as a comparable integer where the book, chapter, and verse each occupy 3\n * digits.\n */\n static getBBBCCCVVV(e, s, r) {\n return e % i.bcvMaxValue * i.bookDigitShifter + (s >= 0 ? s % i.bcvMaxValue * i.chapterDigitShifter : 0) + (r >= 0 ? r % i.bcvMaxValue : 0);\n }\n /**\n * Deserializes a serialized VerseRef.\n * @param serializedVerseRef - Serialized VerseRef to create from.\n * @returns the deserialized VerseRef.\n */\n static fromJSON(e) {\n const { book: s, chapterNum: r, verseNum: a, verse: o, versificationStr: u } = e, f = o || a.toString();\n let d;\n return u && (d = new c(u)), s ? new i(s, r.toString(), f, d) : new i();\n }\n /**\n * Parses a verse string and gets the leading numeric portion as a number.\n * @param verseStr - verse string to parse\n * @returns true if the entire string could be parsed as a single, simple verse number (1-999);\n * false if the verse string represented a verse bridge, contained segment letters, or was invalid\n */\n static tryGetVerseNum(e) {\n let s;\n if (!e)\n return s = -1, { success: !0, vNum: s };\n s = 0;\n let r;\n for (let a = 0; a < e.length; a++) {\n if (r = e[a], r < \"0\" || r > \"9\")\n return a === 0 && (s = -1), { success: !1, vNum: s };\n if (s = s * 10 + +r - 0, s > i.bcvMaxValue)\n return s = -1, { success: !1, vNum: s };\n }\n return { success: !0, vNum: s };\n }\n /**\n * Checks to see if a VerseRef hasn't been set - all values are the default.\n */\n get isDefault() {\n return this.bookNum === 0 && this.chapterNum === 0 && this.verseNum === 0 && this.versification == null;\n }\n /**\n * Gets whether the verse contains multiple verses.\n */\n get hasMultiple() {\n return this._verse != null && (this._verse.includes(i.verseRangeSeparator) || this._verse.includes(i.verseSequenceIndicator));\n }\n /**\n * Gets or sets the book of the reference. Book is the 3-letter abbreviation in capital letters,\n * e.g. `'MAT'`.\n */\n get book() {\n return m.bookNumberToId(this.bookNum, \"\");\n }\n set book(e) {\n this.bookNum = m.bookIdToNumber(e);\n }\n /**\n * Gets or sets the chapter of the reference,. e.g. `'3'`.\n */\n get chapter() {\n return this.isDefault || this._chapterNum < 0 ? \"\" : this._chapterNum.toString();\n }\n set chapter(e) {\n const s = +e;\n this._chapterNum = Number.isInteger(s) ? s : -1;\n }\n /**\n * Gets or sets the verse of the reference, including range, segments, and sequences, e.g. `'4'`,\n * or `'4b-5a, 7'`.\n */\n get verse() {\n return this._verse != null ? this._verse : this.isDefault || this._verseNum < 0 ? \"\" : this._verseNum.toString();\n }\n set verse(e) {\n const { success: s, vNum: r } = i.tryGetVerseNum(e);\n this._verse = s ? void 0 : e.replace(this.rtlMark, \"\"), this._verseNum = r, !(this._verseNum >= 0) && ({ vNum: this._verseNum } = i.tryGetVerseNum(this._verse));\n }\n /**\n * Get or set Book based on book number, e.g. `42`.\n */\n get bookNum() {\n return this._bookNum;\n }\n set bookNum(e) {\n if (e <= 0 || e > m.lastBook)\n throw new v(\n \"BookNum must be greater than zero and less than or equal to last book\"\n );\n this._bookNum = e;\n }\n /**\n * Gets or sets the chapter number, e.g. `3`. `-1` if not valid.\n */\n get chapterNum() {\n return this._chapterNum;\n }\n set chapterNum(e) {\n this.chapterNum = e;\n }\n /**\n * Gets or sets verse start number, e.g. `4`. `-1` if not valid.\n */\n get verseNum() {\n return this._verseNum;\n }\n set verseNum(e) {\n this._verseNum = e;\n }\n /**\n * String representing the versification (should ONLY be used for serialization/deserialization).\n *\n * @remarks This is for backwards compatibility when ScrVers was an enumeration.\n */\n get versificationStr() {\n var e;\n return (e = this.versification) == null ? void 0 : e.name;\n }\n set versificationStr(e) {\n this.versification = this.versification != null ? new c(e) : void 0;\n }\n /**\n * Determines if the reference is valid.\n */\n get valid() {\n return this.validStatus === 0;\n }\n /**\n * Get the valid status for this reference.\n */\n get validStatus() {\n return this.validateVerse(i.verseRangeSeparators, i.verseSequenceIndicators);\n }\n /**\n * Gets the reference as a comparable integer where the book,\n * chapter, and verse each occupy three digits and the verse is 0.\n */\n get BBBCCC() {\n return i.getBBBCCCVVV(this._bookNum, this._chapterNum, 0);\n }\n /**\n * Gets the reference as a comparable integer where the book,\n * chapter, and verse each occupy three digits. If verse is not null\n * (i.e., this reference represents a complex reference with verse\n * segments or bridge) this cannot be used for an exact comparison.\n */\n get BBBCCCVVV() {\n return i.getBBBCCCVVV(this._bookNum, this._chapterNum, this._verseNum);\n }\n /**\n * Gets whether the verse is defined as an excluded verse in the versification.\n * Does not handle verse ranges.\n */\n // eslint-disable-next-line @typescript-eslint/class-literal-property-style\n get isExcluded() {\n return !1;\n }\n /**\n * Parses the reference in the specified string.\n * Optionally versification can follow reference as in GEN 3:11/4\n * Throw an exception if\n * - invalid book name\n * - chapter number is missing or not a number\n * - verse number is missing or does not start with a number\n * - versification is invalid\n * @param verseStr - string to parse e.g. 'MAT 3:11'\n */\n parse(e) {\n if (e = e.replace(this.rtlMark, \"\"), e.includes(\"/\")) {\n const o = e.split(\"/\");\n if (e = o[0], o.length > 1)\n try {\n const u = +o[1].trim();\n this.versification = new c(l[u]);\n } catch {\n throw new v(\"Invalid reference : \" + e);\n }\n }\n const s = e.trim().split(\" \");\n if (s.length !== 2)\n throw new v(\"Invalid reference : \" + e);\n const r = s[1].split(\":\"), a = +r[0];\n if (r.length !== 2 || m.bookIdToNumber(s[0]) === 0 || !Number.isInteger(a) || a < 0 || !i.isVerseParseable(r[1]))\n throw new v(\"Invalid reference : \" + e);\n this.updateInternal(s[0], r[0], r[1]);\n }\n /**\n * Simplifies this verse ref so that it has no bridging of verses or\n * verse segments like `'1a'`.\n */\n simplify() {\n this._verse = void 0;\n }\n /**\n * Makes a clone of the reference.\n *\n * @returns The cloned VerseRef.\n */\n clone() {\n return new i(this);\n }\n toString() {\n const e = this.book;\n return e === \"\" ? \"\" : `${e} ${this.chapter}:${this.verse}`;\n }\n toJSON() {\n let e = this.verse;\n (e === \"\" || e === this.verseNum.toString()) && (e = void 0);\n const s = {\n book: this.book,\n chapterNum: this.chapterNum,\n verseNum: this.verseNum,\n verse: e,\n versificationStr: this.versificationStr\n };\n return e || delete s.verse, s;\n }\n /**\n * Compares this `VerseRef` with supplied one.\n * @param verseRef - object to compare this one to.\n * @returns `true` if this `VerseRef` is equal to the supplied one, `false` otherwise.\n */\n equals(e) {\n return e instanceof i ? e._bookNum === this._bookNum && e._chapterNum === this._chapterNum && e._verseNum === this._verseNum && e.verse === this.verse && (e.versification == null && this.versification == null || e.versification != null && this.versification != null && e.versification.equals(this.versification)) : !1;\n }\n /**\n * Enumerate all individual verses contained in a VerseRef.\n * Verse ranges are indicated by \"-\" and consecutive verses by \",\"s.\n * Examples:\n * GEN 1:2 returns GEN 1:2\n * GEN 1:1a-3b,5 returns GEN 1:1a, GEN 1:2, GEN 1:3b, GEN 1:5\n * GEN 1:2a-2c returns //! ??????\n *\n * @param specifiedVersesOnly - if set to true return only verses that are\n * explicitly specified only, not verses within a range. Defaults to `false`.\n * @param verseRangeSeparators - Verse range separators.\n * Defaults to `VerseRef.verseRangeSeparators`.\n * @param verseSequenceSeparators - Verse sequence separators.\n * Defaults to `VerseRef.verseSequenceIndicators`.\n * @returns An array of all single verse references in this VerseRef.\n */\n allVerses(e = !1, s = i.verseRangeSeparators, r = i.verseSequenceIndicators) {\n if (this._verse == null || this.chapterNum <= 0)\n return [this.clone()];\n const a = [], o = E(this._verse, r);\n for (const u of o.map((f) => E(f, s))) {\n const f = this.clone();\n f.verse = u[0];\n const d = f.verseNum;\n if (a.push(f), u.length > 1) {\n const b = this.clone();\n if (b.verse = u[1], !e)\n for (let p = d + 1; p < b.verseNum; p++) {\n const J = new i(\n this._bookNum,\n this._chapterNum,\n p,\n this.versification\n );\n this.isExcluded || a.push(J);\n }\n a.push(b);\n }\n }\n return a;\n }\n /**\n * Validates a verse number using the supplied separators rather than the defaults.\n */\n validateVerse(e, s) {\n if (!this.verse)\n return this.internalValid;\n let r = 0;\n for (const a of this.allVerses(!0, e, s)) {\n const o = a.internalValid;\n if (o !== 0)\n return o;\n const u = a.BBBCCCVVV;\n if (r > u)\n return 3;\n if (r === u)\n return 4;\n r = u;\n }\n return 0;\n }\n /**\n * Gets whether a single verse reference is valid.\n */\n get internalValid() {\n return this.versification == null ? 1 : this._bookNum <= 0 || this._bookNum > m.lastBook ? 2 : (m.isCanonical(this._bookNum), 0);\n }\n setEmpty(e = i.defaultVersification) {\n this._bookNum = 0, this._chapterNum = -1, this._verse = void 0, this.versification = e;\n }\n updateInternal(e, s, r) {\n this.bookNum = m.bookIdToNumber(e), this.chapter = s, this.verse = r;\n }\n};\nn(i, \"defaultVersification\", c.English), n(i, \"verseRangeSeparator\", \"-\"), n(i, \"verseSequenceIndicator\", \",\"), n(i, \"verseRangeSeparators\", [i.verseRangeSeparator]), n(i, \"verseSequenceIndicators\", [i.verseSequenceIndicator]), n(i, \"chapterDigitShifter\", 1e3), n(i, \"bookDigitShifter\", i.chapterDigitShifter * i.chapterDigitShifter), n(i, \"bcvMaxValue\", i.chapterDigitShifter - 1), /**\n * The valid status of the VerseRef.\n */\nn(i, \"ValidStatusType\", D);\nlet M = i;\nclass v extends Error {\n}\nexport {\n _ as BookSet,\n m as Canon,\n c as ScrVers,\n l as ScrVersType,\n M as VerseRef,\n v as VerseRefException\n};\n//# sourceMappingURL=index.es.js.map\n","import React from 'react';\nimport * as DropdownMenuPrimitive from '@radix-ui/react-dropdown-menu';\nimport { Check, ChevronRight, Circle } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport const DropdownMenu = DropdownMenuPrimitive.Root;\n\nexport const DropdownMenuTrigger = DropdownMenuPrimitive.Trigger;\n\nexport const DropdownMenuGroup = DropdownMenuPrimitive.Group;\n\nexport const DropdownMenuPortal = DropdownMenuPrimitive.Portal;\n\nexport const DropdownMenuSub = DropdownMenuPrimitive.Sub;\n\nexport const DropdownMenuRadioGroup = DropdownMenuPrimitive.RadioGroup;\n\nexport type DropdownMenuSubTriggerProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.SubTrigger\n> & {\n className?: string;\n inset?: boolean;\n};\n\nexport type DropdownMenuSubContentProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.SubContent\n> & {\n className?: string;\n};\n\nexport type DropdownMenuContentProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Content\n> & {\n className?: string;\n sideOffset?: number;\n};\n\nexport type DropdownMenuItemProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Item\n> & {\n className?: string;\n inset?: boolean;\n};\n\nexport type DropdownMenuCheckboxItemProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.CheckboxItem\n> & {\n className?: string;\n checked?: boolean;\n};\n\nexport type DropdownMenuRadioItemProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.RadioItem\n> & {\n className?: string;\n};\n\nexport type DropdownMenuLabelProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Label\n> & {\n className?: string;\n inset?: boolean;\n};\n\nexport type DropdownMenuSeparatorProps = React.ComponentPropsWithoutRef<\n typeof DropdownMenuPrimitive.Separator\n> & {\n className?: string;\n};\n\nexport type DropdownMenuShortcutProps = React.HTMLAttributes & {\n className?: string;\n};\n\nexport const DropdownMenuSubTrigger = React.forwardRef<\n React.ElementRef,\n DropdownMenuSubTriggerProps\n>(({ className, inset, children, ...props }, ref) => (\n \n {children}\n \n \n));\nDropdownMenuSubTrigger.displayName = DropdownMenuPrimitive.SubTrigger.displayName;\n\nexport const DropdownMenuSubContent = React.forwardRef<\n React.ElementRef,\n DropdownMenuSubContentProps\n>(({ className, ...props }, ref) => (\n \n));\nDropdownMenuSubContent.displayName = DropdownMenuPrimitive.SubContent.displayName;\n\nexport const DropdownMenuContent = React.forwardRef<\n React.ElementRef,\n DropdownMenuContentProps\n>(({ className, sideOffset = 4, ...props }, ref) => (\n \n \n \n));\nDropdownMenuContent.displayName = DropdownMenuPrimitive.Content.displayName;\n\n/**\n * TODO: fix: direction is not automatically handled by this component, so that shortcuts are\n * display always to the right\n */\nexport const DropdownMenuItem = React.forwardRef<\n React.ElementRef,\n DropdownMenuItemProps\n>(({ className, inset, ...props }, ref) => (\n \n));\nDropdownMenuItem.displayName = DropdownMenuPrimitive.Item.displayName;\n\nexport const DropdownMenuCheckboxItem = React.forwardRef<\n React.ElementRef,\n DropdownMenuCheckboxItemProps\n>(({ className, children, checked, ...props }, ref) => (\n \n \n \n \n \n \n {children}\n \n));\nDropdownMenuCheckboxItem.displayName = DropdownMenuPrimitive.CheckboxItem.displayName;\n\nexport const DropdownMenuRadioItem = React.forwardRef<\n React.ElementRef,\n DropdownMenuRadioItemProps\n>(({ className, children, ...props }, ref) => (\n \n \n \n \n \n \n {children}\n \n));\nDropdownMenuRadioItem.displayName = DropdownMenuPrimitive.RadioItem.displayName;\n\nexport const DropdownMenuLabel = React.forwardRef<\n React.ElementRef,\n DropdownMenuLabelProps\n>(({ className, inset, ...props }, ref) => (\n \n));\nDropdownMenuLabel.displayName = DropdownMenuPrimitive.Label.displayName;\n\nexport const DropdownMenuSeparator = React.forwardRef<\n React.ElementRef,\n DropdownMenuSeparatorProps\n>(({ className, ...props }, ref) => (\n \n));\nDropdownMenuSeparator.displayName = DropdownMenuPrimitive.Separator.displayName;\n\nexport function DropdownMenuShortcut({ className, ...props }: DropdownMenuShortcutProps) {\n return (\n \n );\n}\nDropdownMenuShortcut.displayName = 'DropdownMenuShortcut';\n","import { Canon } from '@sillsdev/scripture';\nimport { PropsWithChildren, KeyboardEvent, forwardRef } from 'react';\nimport { DropdownMenuItem as ShadDropdownMenuItem } from '@/components/shadcn-ui/dropdown-menu';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport type BookType = 'OT' | 'NT' | 'DC';\n\ntype BookMenuItemProps = PropsWithChildren<{\n /** String id of book */\n bookId: string;\n /** Callback to run when a book menu item is selected */\n handleSelectBook: () => void;\n /** Indicates if this menu item is currently selected */\n isSelected: boolean;\n /** Function that is called upon highlighting a book in the dropdown menu */\n handleHighlightBook: () => void;\n /**\n * Function that is called on pressing a key\n *\n * @param event Event that contains information about the key stroke\n */\n handleKeyDown: (event: KeyboardEvent) => void;\n /**\n * Type of book associated with this menu item, coordinates color labels ? Mock up has the labels\n * coordinated to genre\n */\n bookType: BookType;\n}>;\n\nconst BookMenuItem = forwardRef(\n (\n {\n bookId,\n handleSelectBook,\n isSelected,\n handleHighlightBook,\n handleKeyDown,\n bookType,\n children,\n }: BookMenuItemProps,\n ref,\n ) => {\n return (\n {\n // preventDefault() here prevents the entire dropdown menu from closing when selecting this item\n event.preventDefault();\n handleSelectBook();\n }}\n onKeyDown={(event: KeyboardEvent) => {\n handleKeyDown(event);\n }}\n onFocus={handleHighlightBook}\n onMouseMove={handleHighlightBook}\n >\n \n {Canon.bookIdToEnglishName(bookId)}\n \n {isSelected &&
    {children}
    }\n \n );\n },\n);\n\nexport default BookMenuItem;\n","import { cn } from '@/utils/shadcn-ui.util';\nimport { useCallback } from 'react';\n\nexport type ChapterSelectProps = {\n /**\n * Callback to run when a chapter div is selected\n *\n * @param chapterNumber Number of the chapter that has been selected\n */\n handleSelectChapter: (chapterNumber: number) => void;\n /** The highest chapter number in the book (of course equal to number of chapters in the book) */\n endChapter: number;\n /** The chapter number that is currently selected */\n activeChapter: number;\n /** The chapter number that is currently highlighted using keyboard or mouse navigation */\n highlightedChapter: number;\n /**\n * Callback to run when a chapter is highlighted by the user\n *\n * @param chapterNumber The chapter that is highlighted\n */\n handleHighlightedChapter: (chapterNumber: number) => void;\n};\n\nfunction ChapterSelect({\n handleSelectChapter,\n endChapter,\n activeChapter,\n highlightedChapter,\n handleHighlightedChapter,\n}: ChapterSelectProps) {\n const chapters = Array.from({ length: endChapter }, (_, i) => i + 1);\n\n const handleMouse = useCallback(\n (chapterNumber: number) => {\n handleHighlightedChapter(chapterNumber);\n },\n [handleHighlightedChapter],\n );\n\n return (\n
    \n {chapters.map((chapter) => (\n {\n event.preventDefault();\n event.stopPropagation();\n handleSelectChapter(chapter);\n }}\n role=\"button\"\n onKeyDown={(event) => {\n if (event.key === 'Enter') {\n handleSelectChapter(chapter);\n }\n }}\n tabIndex={0}\n onMouseMove={() => handleMouse(chapter)}\n >\n {chapter}\n
    \n ))}\n
    \n );\n}\n\nexport default ChapterSelect;\n","import { DropdownMenuLabel as ShadDropdownMenuLabel } from '@/components/shadcn-ui/dropdown-menu';\nimport { Bookmark, Clock, ArrowDownWideNarrow } from 'lucide-react';\n\nexport type GoToMenuItemProps = {\n handleSort: () => void;\n handleLocationHistory: () => void;\n handleBookmarks: () => void;\n};\n\nfunction GoToMenuItem({ handleSort, handleLocationHistory, handleBookmarks }: GoToMenuItemProps) {\n return (\n \n

    Go To

    \n
    \n \n \n \n
    \n
    \n );\n}\n\nexport default GoToMenuItem;\n","import BookChapterInput from '@/components/advanced/book-chapter-control/book-chapter-input.component';\nimport BookMenuItem, {\n BookType,\n} from '@/components/advanced/book-chapter-control/book-menu-item.component';\nimport ChapterSelect from '@/components/advanced/book-chapter-control/chapter-select.component';\nimport GoToMenuItem from '@/components/advanced/book-chapter-control/go-to-menu-item.component';\nimport {\n DropdownMenu as ShadDropdownMenu,\n DropdownMenuContent as ShadDropdownMenuContent,\n DropdownMenuLabel as ShadDropdownMenuLabel,\n DropdownMenuSeparator as ShadDropdownMenuSeparator,\n DropdownMenuTrigger as ShadDropdownMenuTrigger,\n} from '@/components/shadcn-ui/dropdown-menu';\nimport { Canon } from '@sillsdev/scripture';\nimport { ScriptureReference, getChaptersForBook } from 'platform-bible-utils';\nimport {\n KeyboardEvent as ReactKeyboardEvent,\n useCallback,\n useEffect,\n useLayoutEffect,\n useRef,\n useState,\n} from 'react';\n\ntype BookTypeLabels = {\n [bookType in BookType]: string;\n};\ntype BookChapterControlProps = {\n scrRef: ScriptureReference;\n handleSubmit: (scrRef: ScriptureReference) => void;\n};\n\nconst ALL_BOOK_IDS = Canon.allBookIds;\nconst BOOK_TYPE_LABELS: BookTypeLabels = {\n OT: 'Old Testament',\n NT: 'New Testament',\n DC: 'Deuterocanon',\n};\nconst BOOK_TYPE_ARRAY: BookType[] = ['OT', 'NT', 'DC'];\n// This is the height of three menu items to offset scrolling to the selected menu item\n// If you use menuItemRef.clientHeight- includes height of chapter div which is too big\nconst SCROLL_OFFSET = 32 + 32 + 32;\nconst SEARCH_QUERY_FORMATS = [\n /^(\\w+)$/i, // Matches a single word (book name or id)\n /^(\\w+)(?:\\s(\\d+))$/i, // Matches a word followed by a chapter number\n /^(\\w+)(?:\\s(\\d+):(\\d+))$/i, // Matches a word followed by a chapter and verse number\n];\nconst fetchGroupedBooks = (bookType: BookType) => {\n const groupedBooks = {\n OT: ALL_BOOK_IDS.filter((bookId) => Canon.isBookOT(bookId)),\n NT: ALL_BOOK_IDS.filter((bookId) => Canon.isBookNT(bookId)),\n DC: ALL_BOOK_IDS.filter((bookId) => Canon.isBookDC(bookId)),\n };\n return groupedBooks[bookType];\n};\nconst fetchEndChapter = (bookId: string) => {\n // getChaptersForBook returns -1 if not found in scrBookData\n // scrBookData only includes OT and NT, so all DC will return -1\n return getChaptersForBook(Canon.bookIdToNumber(bookId));\n};\n\n/**\n * Gets all of the English names from book ids\n *\n * @returns String[]\n */\nfunction getAllEnglishNames(): string[] {\n const allEnglishNames = ALL_BOOK_IDS.map((bookId) => {\n return Canon.bookIdToEnglishName(bookId);\n });\n return allEnglishNames;\n}\n\n/**\n * Determines if bookName is in allEnglishNames\n *\n * @param bookName Book English name\n * @returns True if bookName is included, false otherwise\n */\nfunction isValidBookEnglishName(bookName: string): boolean {\n return getAllEnglishNames().includes(bookName);\n}\n\n/**\n * Gets a bookId from given English name\n *\n * @param bookName Book English name\n * @returns BookId of provided bookName, undefined otherwise\n */\nfunction getBookIdFromEnglishName(bookName: string): string | undefined {\n // Convert bookName to lowercase and then capitalize the first letter\n const formattedBookName = bookName.toLowerCase().replace(/^\\w/, (c) => c.toUpperCase());\n\n if (isValidBookEnglishName(formattedBookName)) {\n const matchingBookId = ALL_BOOK_IDS.find((bookId) => {\n return Canon.bookIdToEnglishName(bookId) === formattedBookName;\n });\n return matchingBookId;\n }\n\n return undefined;\n}\n\nfunction BookChapterControl({ scrRef, handleSubmit }: BookChapterControlProps) {\n const [searchQuery, setSearchQuery] = useState('');\n const [selectedBookId, setSelectedBookId] = useState(\n Canon.bookNumberToId(scrRef.bookNum),\n );\n const [highlightedChapter, setHighlightedChapter] = useState(scrRef.chapterNum ?? 0);\n const [highlightedBookId, setHighlightedBookId] = useState(\n Canon.bookNumberToId(scrRef.bookNum),\n );\n const [isContentOpen, setIsContentOpen] = useState(false);\n const [isContentOpenDelayed, setIsContentOpenDelayed] = useState(isContentOpen);\n\n // This ref will always be defined\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const inputRef = useRef(undefined!);\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const contentRef = useRef(undefined!);\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const menuItemRef = useRef(undefined!);\n\n const fetchFilteredBooks = useCallback(\n (bookType: BookType) => {\n return fetchGroupedBooks(bookType).filter((bookId: string) => {\n const englishNameLowerCase = Canon.bookIdToEnglishName(bookId).toLowerCase();\n const normalizedQuery = searchQuery.replace(/[^a-zA-Z]/g, '').toLowerCase();\n return (\n englishNameLowerCase.includes(normalizedQuery) || // Match book name\n bookId.toLowerCase().includes(normalizedQuery) // Match book ID\n );\n });\n },\n [searchQuery],\n );\n\n const handleSearchInput = (searchString: string) => {\n setSearchQuery(searchString);\n };\n\n /**\n * Whether to prevent radix's logic from closing the dropdown. This is important because radix\n * tries to close the dropdown when the input first focuses, and we don't want it to do that. But\n * we don't want to prevent the dropdown from closing when we click away from the input, so we\n * don't want to just keep it open if the input is focused\n */\n const shouldPreventAutoClosing = useRef(false);\n\n const controlMenuState = useCallback((open: boolean) => {\n if (shouldPreventAutoClosing.current) {\n shouldPreventAutoClosing.current = false;\n return;\n }\n setIsContentOpen(open);\n }, []);\n\n const updateReference = useCallback(\n (bookId: string, shouldClose: boolean, chapter?: number, verse?: number) => {\n setHighlightedChapter(\n Canon.bookNumberToId(scrRef.bookNum) !== bookId ? 1 : scrRef.chapterNum,\n );\n\n if (shouldClose || fetchEndChapter(bookId) === -1) {\n handleSubmit({\n bookNum: Canon.bookIdToNumber(bookId),\n chapterNum: chapter || 1,\n verseNum: verse || 1,\n });\n\n setIsContentOpen(false);\n setSearchQuery('');\n return;\n }\n\n setSelectedBookId(selectedBookId !== bookId ? bookId : '');\n setIsContentOpen(!shouldClose);\n },\n [handleSubmit, scrRef.bookNum, scrRef.chapterNum, selectedBookId],\n );\n\n const handleSelectChapter = (chapterNumber: number) => {\n if (chapterNumber <= 0 || chapterNumber > fetchEndChapter(selectedBookId)) {\n return;\n }\n updateReference(selectedBookId, true, chapterNumber);\n };\n\n const handleInputSubmit = useCallback(() => {\n SEARCH_QUERY_FORMATS.forEach((format) => {\n const matches = searchQuery.match(format);\n if (matches) {\n // Book should be a bookId or an english name\n const [book, chapter = undefined, verse = undefined] = matches.slice(1);\n const englishName = getBookIdFromEnglishName(book);\n\n if (Canon.isBookIdValid(book) || englishName) {\n updateReference(\n englishName ?? book,\n true,\n chapter ? parseInt(chapter, 10) : 1,\n verse ? parseInt(verse, 10) : 1,\n );\n }\n }\n });\n }, [updateReference, searchQuery]);\n\n const handleKeyDownInput = useCallback(\n (event: ReactKeyboardEvent) => {\n if (!isContentOpen) {\n setIsContentOpen(true);\n } else if (event.key === 'ArrowDown' || event.key === 'ArrowUp') {\n if (\n typeof menuItemRef !== 'undefined' &&\n // Ref uses null\n // eslint-disable-next-line no-null/no-null\n menuItemRef.current !== null\n ) {\n menuItemRef.current.focus();\n } else if (\n typeof contentRef !== 'undefined' &&\n // Ref uses null\n // eslint-disable-next-line no-null/no-null\n contentRef.current !== null\n ) {\n contentRef.current.focus();\n }\n event.preventDefault();\n }\n },\n [isContentOpen],\n );\n\n const handleKeyDownContent = (event: ReactKeyboardEvent) => {\n // When the dropdown menu has focus, key strokes should give focus to the input component,\n // unless they're navigation keys (arrows and enter)\n const { key } = event;\n if (\n key === 'ArrowRight' ||\n key === 'ArrowLeft' ||\n key === 'ArrowDown' ||\n key === 'ArrowUp' ||\n key === 'Enter'\n ) {\n return;\n }\n\n inputRef.current.dispatchEvent(new KeyboardEvent('keydown', { key }));\n inputRef.current.focus();\n };\n\n const handleKeyDownMenuItem = (event: ReactKeyboardEvent) => {\n const { key } = event;\n if (highlightedBookId === selectedBookId) {\n if (key === 'Enter') {\n event.preventDefault();\n updateReference(selectedBookId, true, highlightedChapter);\n return;\n }\n\n let chapterOffSet = 0;\n if (key === 'ArrowRight') {\n if (highlightedChapter < fetchEndChapter(highlightedBookId)) {\n chapterOffSet = 1;\n } else {\n event.preventDefault();\n return;\n }\n } else if (key === 'ArrowLeft') {\n if (highlightedChapter > 1) {\n chapterOffSet = -1;\n } else {\n event.preventDefault();\n return;\n }\n } else if (key === 'ArrowDown') {\n chapterOffSet = 6;\n } else if (key === 'ArrowUp') {\n chapterOffSet = -6;\n }\n if (\n highlightedChapter + chapterOffSet <= 0 ||\n highlightedChapter + chapterOffSet > fetchEndChapter(highlightedBookId)\n ) {\n setHighlightedChapter(0);\n } else if (chapterOffSet !== 0) {\n setHighlightedChapter(highlightedChapter + chapterOffSet);\n event.preventDefault();\n }\n }\n };\n\n useEffect(() => {\n if (selectedBookId === highlightedBookId) {\n if (selectedBookId === Canon.bookNumberToId(scrRef.bookNum)) {\n setHighlightedChapter(scrRef.chapterNum);\n } else {\n setHighlightedChapter(1);\n }\n } else {\n setHighlightedChapter(0);\n }\n }, [highlightedBookId, scrRef.bookNum, scrRef.chapterNum, selectedBookId]);\n\n // The purpose of these useLayoutEffects and timeout is to delay the scroll just\n // enough so that the refs are defined and available when they are used after the timeout\n useLayoutEffect(() => {\n setIsContentOpenDelayed(isContentOpen);\n }, [isContentOpen]);\n\n useLayoutEffect(() => {\n const scrollTimeout = setTimeout(() => {\n if (isContentOpenDelayed && contentRef.current && menuItemRef.current) {\n const menuItemOffsetTop = menuItemRef.current.offsetTop;\n const scrollPosition = menuItemOffsetTop - SCROLL_OFFSET;\n contentRef.current.scrollTo({ top: scrollPosition, behavior: 'instant' });\n }\n }, 10);\n return () => {\n clearTimeout(scrollTimeout);\n };\n }, [isContentOpenDelayed]);\n\n return (\n
    \n \n \n {\n setSelectedBookId(Canon.bookNumberToId(scrRef.bookNum));\n setHighlightedBookId(Canon.bookNumberToId(scrRef.bookNum));\n setHighlightedChapter(scrRef.chapterNum > 0 ? scrRef.chapterNum : 0);\n setIsContentOpen(true);\n inputRef.current.focus();\n }}\n onFocus={() => {\n // Radix thinks we want to close because the input is being focused. Prevent that\n shouldPreventAutoClosing.current = true;\n }}\n handleSubmit={handleInputSubmit}\n placeholder={`${Canon.bookNumberToEnglishName(scrRef.bookNum)} ${scrRef.chapterNum}:${scrRef.verseNum}`}\n />\n \n \n console.log('sorting')}\n handleLocationHistory={() => console.log('location history')}\n handleBookmarks={() => console.log('bookmarks')}\n />\n {BOOK_TYPE_ARRAY.map(\n (bookType, bookTypeIndex) =>\n fetchFilteredBooks(bookType).length > 0 && (\n
    \n \n {BOOK_TYPE_LABELS[bookType]}\n \n\n {fetchFilteredBooks(bookType).map((bookId) => (\n
    \n updateReference(bookId, false)}\n isSelected={selectedBookId === bookId}\n handleHighlightBook={() => setHighlightedBookId(bookId)}\n handleKeyDown={handleKeyDownMenuItem}\n bookType={bookType}\n ref={(element: HTMLDivElement) => {\n if (selectedBookId === bookId) menuItemRef.current = element;\n }}\n >\n {\n setHighlightedChapter(chapterNumber);\n }}\n />\n \n
    \n ))}\n {BOOK_TYPE_ARRAY.length - 1 !== bookTypeIndex ? (\n \n ) : undefined}\n
    \n ),\n )}\n \n
    \n
    \n );\n}\n\nexport default BookChapterControl;\n","import React from 'react';\nimport { Slot } from '@radix-ui/react-slot';\nimport { cva, type VariantProps } from 'class-variance-authority';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport const buttonVariants = cva(\n 'pr-twp tw-inline-flex tw-items-center tw-justify-center tw-whitespace-nowrap tw-rounded-md tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-colors focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50',\n {\n variants: {\n variant: {\n default: 'tw-bg-primary tw-text-primary-foreground hover:tw-bg-primary/90',\n destructive: 'tw-bg-destructive tw-text-destructive-foreground hover:tw-bg-destructive/90',\n outline:\n 'tw-border tw-border-input tw-bg-background hover:tw-bg-accent hover:tw-text-accent-foreground',\n secondary: 'tw-bg-secondary tw-text-secondary-foreground hover:tw-bg-secondary/80',\n ghost: 'hover:tw-bg-accent hover:tw-text-accent-foreground',\n link: 'tw-text-primary tw-underline-offset-4 hover:tw-underline',\n },\n size: {\n default: 'tw-h-10 tw-px-4 tw-py-2',\n sm: 'tw-h-9 tw-rounded-md tw-px-3',\n lg: 'tw-h-11 tw-rounded-md tw-px-8',\n icon: 'tw-h-10 tw-w-10',\n },\n },\n defaultVariants: {\n variant: 'default',\n size: 'default',\n },\n },\n);\n\nexport interface ButtonProps\n extends React.ButtonHTMLAttributes,\n VariantProps {\n asChild?: boolean;\n}\n\nexport const Button = React.forwardRef(\n ({ className, variant, size, asChild = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'button';\n return (\n \n );\n },\n);\nButton.displayName = 'Button';\n","import React from 'react';\nimport * as LabelPrimitive from '@radix-ui/react-label';\nimport { cva, type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst labelVariants = cva(\n 'tw-text-sm tw-font-medium tw-leading-none peer-disabled:tw-cursor-not-allowed peer-disabled:tw-opacity-70',\n);\n\nexport const Label = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef & VariantProps\n>(({ className, ...props }, ref) => (\n \n));\nLabel.displayName = LabelPrimitive.Root.displayName;\n","import React from 'react';\nimport * as RadioGroupPrimitive from '@radix-ui/react-radio-group';\nimport { Circle } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst RadioGroup = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => {\n return (\n \n );\n});\nRadioGroup.displayName = RadioGroupPrimitive.Root.displayName;\n\nconst RadioGroupItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => {\n return (\n \n \n \n \n \n );\n});\nRadioGroupItem.displayName = RadioGroupPrimitive.Item.displayName;\n\nexport { RadioGroup, RadioGroupItem };\n","import React from 'react';\nimport * as PopoverPrimitive from '@radix-ui/react-popover';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Popover = PopoverPrimitive.Root;\n\nconst PopoverTrigger = PopoverPrimitive.Trigger;\n\nconst PopoverContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, align = 'center', sideOffset = 4, ...props }, ref) => (\n \n \n \n));\nPopoverContent.displayName = PopoverPrimitive.Content.displayName;\n\nexport { Popover, PopoverTrigger, PopoverContent };\n","import React from 'react';\nimport * as DialogPrimitive from '@radix-ui/react-dialog';\nimport { X } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Dialog = DialogPrimitive.Root;\n\nconst DialogTrigger = DialogPrimitive.Trigger;\n\nconst DialogPortal = DialogPrimitive.Portal;\n\nconst DialogClose = DialogPrimitive.Close;\n\nconst DialogOverlay = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nDialogOverlay.displayName = DialogPrimitive.Overlay.displayName;\n\nconst DialogContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, ...props }, ref) => (\n \n \n \n {children}\n \n \n Close\n \n \n \n));\nDialogContent.displayName = DialogPrimitive.Content.displayName;\n\nfunction DialogHeader({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nDialogHeader.displayName = 'DialogHeader';\n\nfunction DialogFooter({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nDialogFooter.displayName = 'DialogFooter';\n\nconst DialogTitle = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nDialogTitle.displayName = DialogPrimitive.Title.displayName;\n\nconst DialogDescription = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nDialogDescription.displayName = DialogPrimitive.Description.displayName;\n\nexport {\n Dialog,\n DialogPortal,\n DialogOverlay,\n DialogClose,\n DialogTrigger,\n DialogContent,\n DialogHeader,\n DialogFooter,\n DialogTitle,\n DialogDescription,\n};\n","import React from 'react';\nimport { type DialogProps } from '@radix-ui/react-dialog';\nimport { Command as CommandPrimitive } from 'cmdk';\nimport { Search } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Dialog, DialogContent } from '@/components/shadcn-ui/dialog';\n\nconst Command = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nCommand.displayName = CommandPrimitive.displayName;\n\ninterface CommandDialogProps extends DialogProps {}\n\nfunction CommandDialog({ children, ...props }: CommandDialogProps) {\n return (\n \n \n \n {children}\n \n \n \n );\n}\n\nconst CommandInput = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n
    \n \n \n
    \n));\n\nCommandInput.displayName = CommandPrimitive.Input.displayName;\n\nconst CommandList = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\n\nCommandList.displayName = CommandPrimitive.List.displayName;\n\nconst CommandEmpty = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>((props, ref) => (\n \n));\n\nCommandEmpty.displayName = CommandPrimitive.Empty.displayName;\n\nconst CommandGroup = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\n\nCommandGroup.displayName = CommandPrimitive.Group.displayName;\n\nconst CommandSeparator = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nCommandSeparator.displayName = CommandPrimitive.Separator.displayName;\n\nconst CommandItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\n\nCommandItem.displayName = CommandPrimitive.Item.displayName;\n\nfunction CommandShortcut({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\nCommandShortcut.displayName = 'CommandShortcut';\n\nexport {\n Command,\n CommandDialog,\n CommandInput,\n CommandList,\n CommandEmpty,\n CommandGroup,\n CommandItem,\n CommandShortcut,\n CommandSeparator,\n};\n","import { useState } from 'react';\nimport { Check, ChevronsUpDown } from 'lucide-react';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport { Popover, PopoverContent, PopoverTrigger } from '@/components/shadcn-ui/popover';\nimport {\n Command,\n CommandEmpty,\n CommandInput,\n CommandItem,\n CommandList,\n} from '@/components/shadcn-ui/command';\nimport { PopoverProps } from '@radix-ui/react-popover';\n\nexport type ComboBoxLabelOption = { label: string };\nexport type ComboBoxOption = string | number | ComboBoxLabelOption;\n\nexport type ComboBoxProps = {\n /** Optional unique identifier */\n id?: string;\n /** Text label title for combobox */\n /** List of available options for the dropdown menu */\n options?: readonly T[];\n /** @deprecated 3 December 2024. Renamed to {@link buttonClassName} */\n className?: string;\n /** Additional css classes to help with unique styling of the combo box button */\n buttonClassName?: string;\n /** Additional css classes to help with unique styling of the combo box popover */\n popoverContentClassName?: string;\n /**\n * The selected value that the combo box currently holds. Must be shallow equal to one of the\n * options entries.\n */\n value?: T;\n /** Triggers when content of textfield is changed */\n onChange?: (newValue: T) => void;\n /** Used to determine the string value for a given option. */\n getOptionLabel?: (option: ComboBoxOption) => string;\n /** Text displayed on button if `value` is undefined */\n buttonPlaceholder?: string;\n /** Placeholder text for text field */\n textPlaceholder?: string;\n /** Text to display when no options match input */\n commandEmptyMessage?: string;\n /** Variant of button */\n buttonVariant?: ButtonProps['variant'];\n /** Text direction ltr or rtl */\n dir?: Direction;\n /** Optional boolean to set if trigger should be disabled */\n isDisabled?: boolean;\n} & PopoverProps;\n\ntype Direction = 'ltr' | 'rtl';\n\nfunction getOptionLabelDefault(option: ComboBoxOption): string {\n if (typeof option === 'string') {\n return option;\n }\n if (typeof option === 'number') {\n return option.toString();\n }\n return option.label;\n}\n\n/**\n * Autocomplete input and command palette with a list of suggestions.\n *\n * Thanks to Shadcn for heavy inspiration and documentation\n * https://ui.shadcn.com/docs/components/combobox\n */\nfunction ComboBox({\n id,\n options = [],\n className,\n buttonClassName,\n popoverContentClassName,\n value,\n onChange = () => {},\n getOptionLabel = getOptionLabelDefault,\n buttonPlaceholder = '',\n textPlaceholder = '',\n commandEmptyMessage = 'No option found',\n buttonVariant = 'outline',\n dir = 'ltr',\n isDisabled = false,\n ...props\n}: ComboBoxProps) {\n const [open, setOpen] = useState(false);\n\n return (\n \n \n \n \n {value ? getOptionLabel(value) : buttonPlaceholder}\n \n \n \n \n \n \n \n {commandEmptyMessage}\n \n {options.map((option) => (\n {\n onChange(option);\n setOpen(false);\n }}\n >\n \n {getOptionLabel(option)}\n \n ))}\n \n \n \n \n );\n}\n\nexport default ComboBox;\n","import { useMemo } from 'react';\nimport ComboBox from '@/components/basics/combo-box.component';\nimport { Label } from '@/components/shadcn-ui/label';\n\nexport type ChapterRangeSelectorProps = {\n startChapter: number;\n endChapter: number;\n handleSelectStartChapter: (chapter: number) => void;\n handleSelectEndChapter: (chapter: number) => void;\n isDisabled?: boolean;\n chapterCount: number;\n};\n\nexport default function ChapterRangeSelector({\n startChapter,\n endChapter,\n handleSelectStartChapter,\n handleSelectEndChapter,\n isDisabled = false,\n chapterCount,\n}: ChapterRangeSelectorProps) {\n const chapterOptions = useMemo(\n () => Array.from({ length: chapterCount }, (_, index) => index + 1),\n [chapterCount],\n );\n\n const onChangeStartChapter = (value: number) => {\n handleSelectStartChapter(value);\n if (value > endChapter) {\n handleSelectEndChapter(value);\n }\n };\n\n const onChangeEndChapter = (value: number) => {\n handleSelectEndChapter(value);\n if (value < startChapter) {\n handleSelectStartChapter(value);\n }\n };\n\n return (\n <>\n \n option.toString()}\n value={startChapter}\n />\n\n \n option.toString()}\n value={endChapter}\n />\n \n );\n}\n","import { Button } from '@/components/shadcn-ui/button';\nimport { Label } from '@/components/shadcn-ui/label';\nimport { RadioGroup, RadioGroupItem } from '@/components/shadcn-ui/radio-group';\nimport { Canon } from '@sillsdev/scripture';\nimport { LocalizedStringValue } from 'platform-bible-utils';\nimport { useState } from 'react';\nimport ChapterRangeSelector, {\n ChapterRangeSelectorProps,\n} from '../basics/chapter-range-selector.component';\n\nexport enum BookSelectionMode {\n CURRENT_BOOK = 'current book',\n CHOOSE_BOOKS = 'choose books',\n}\n\n/**\n * Object containing all keys used for localization in this component. If you're using this\n * component in an extension, you can pass it into the useLocalizedStrings hook to easily obtain the\n * localized strings and pass them into the localizedStrings prop of this component\n */\nexport const BOOK_SELECTOR_STRING_KEYS = Object.freeze([\n '%webView_bookSelector_currentBook%',\n '%webView_bookSelector_choose%',\n '%webView_bookSelector_chooseBooks%',\n] as const);\n\nexport type BookSelectorLocalizedStrings = {\n [localizedInventoryKey in (typeof BOOK_SELECTOR_STRING_KEYS)[number]]?: LocalizedStringValue;\n};\n\n/**\n * Gets the localized value for the provided key\n *\n * @param strings Object containing localized string\n * @param key Key for a localized string\n * @returns The localized value for the provided key, if available. Returns the key if no localized\n * value is available\n */\nconst localizeString = (\n strings: BookSelectorLocalizedStrings,\n key: keyof BookSelectorLocalizedStrings,\n) => {\n return strings[key] ?? key;\n};\n\ntype BookSelectorProps = ChapterRangeSelectorProps & {\n handleBookSelectionModeChange: (newMode: BookSelectionMode) => void;\n currentBookName: string;\n onSelectBooks: () => void;\n selectedBookIds: string[];\n localizedStrings: BookSelectorLocalizedStrings;\n};\n\nexport default function BookSelector({\n handleBookSelectionModeChange,\n currentBookName,\n onSelectBooks,\n selectedBookIds,\n chapterCount,\n endChapter,\n handleSelectEndChapter,\n startChapter,\n handleSelectStartChapter,\n localizedStrings,\n}: BookSelectorProps) {\n const currentBookText = localizeString(localizedStrings, '%webView_bookSelector_currentBook%');\n const chooseText = localizeString(localizedStrings, '%webView_bookSelector_choose%');\n const chooseBooksText = localizeString(localizedStrings, '%webView_bookSelector_chooseBooks%');\n\n const [bookSelectionMode, setBookSelectionMode] = useState(\n BookSelectionMode.CURRENT_BOOK,\n );\n\n const onSelectionModeChange = (newMode: BookSelectionMode) => {\n setBookSelectionMode(newMode);\n handleBookSelectionModeChange(newMode);\n };\n\n return (\n onSelectionModeChange(value as BookSelectionMode)}\n >\n
    \n
    \n
    \n \n \n
    \n \n
    \n \n
    \n
    \n
    \n
    \n \n \n
    \n \n onSelectBooks()}\n >\n {chooseText}\n \n
    \n
    \n \n );\n}\n","import { DropdownMenuTrigger } from '@radix-ui/react-dropdown-menu';\nimport { FilterIcon } from 'lucide-react';\nimport { Table } from '@tanstack/react-table';\n\nimport { Button } from '@/components/shadcn-ui/button';\nimport {\n DropdownMenu,\n DropdownMenuCheckboxItem,\n DropdownMenuContent,\n DropdownMenuLabel,\n DropdownMenuSeparator,\n} from '@/components/shadcn-ui/dropdown-menu';\n\ninterface DataTableViewOptionsProps {\n table: Table;\n}\n\nfunction DataTableViewOptions({ table }: DataTableViewOptionsProps) {\n return (\n \n \n \n \n \n Toggle columns\n \n {table\n .getAllColumns()\n .filter((column) => column.getCanHide())\n .map((column) => {\n return (\n column.toggleVisibility(!!value)}\n >\n {column.id}\n \n );\n })}\n \n \n );\n}\n\nexport default DataTableViewOptions;\n","import React from 'react';\nimport * as SelectPrimitive from '@radix-ui/react-select';\nimport { Check, ChevronDown, ChevronUp } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Select = SelectPrimitive.Root;\n\nconst SelectGroup = SelectPrimitive.Group;\n\nconst SelectValue = SelectPrimitive.Value;\n\nconst SelectTrigger = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, ...props }, ref) => (\n span]:tw-line-clamp-1',\n className,\n )}\n {...props}\n >\n {children}\n \n \n \n \n));\nSelectTrigger.displayName = SelectPrimitive.Trigger.displayName;\n\nconst SelectScrollUpButton = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n));\nSelectScrollUpButton.displayName = SelectPrimitive.ScrollUpButton.displayName;\n\nconst SelectScrollDownButton = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n));\nSelectScrollDownButton.displayName = SelectPrimitive.ScrollDownButton.displayName;\n\nconst SelectContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, position = 'popper', ...props }, ref) => (\n \n \n \n \n {children}\n \n \n \n \n));\nSelectContent.displayName = SelectPrimitive.Content.displayName;\n\nconst SelectLabel = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSelectLabel.displayName = SelectPrimitive.Label.displayName;\n\nconst SelectItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, children, ...props }, ref) => (\n \n \n \n \n \n \n\n {children}\n \n));\nSelectItem.displayName = SelectPrimitive.Item.displayName;\n\nconst SelectSeparator = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n));\nSelectSeparator.displayName = SelectPrimitive.Separator.displayName;\n\nexport {\n Select,\n SelectGroup,\n SelectValue,\n SelectTrigger,\n SelectContent,\n SelectLabel,\n SelectItem,\n SelectSeparator,\n SelectScrollUpButton,\n SelectScrollDownButton,\n};\n","import { ChevronLeftIcon, ChevronRightIcon, ArrowLeftIcon, ArrowRightIcon } from 'lucide-react';\nimport { Table } from '@tanstack/react-table';\n\nimport { Button } from '@/components/shadcn-ui/button';\nimport {\n Select,\n SelectContent,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\n\ninterface DataTablePaginationProps {\n table: Table;\n}\n\nfunction DataTablePagination({ table }: DataTablePaginationProps) {\n return (\n
    \n
    \n
    \n {table.getFilteredSelectedRowModel().rows.length} of{' '}\n {table.getFilteredRowModel().rows.length} row(s) selected\n
    \n
    \n

    Rows per page

    \n {\n table.setPageSize(Number(value));\n }}\n >\n \n \n \n \n {[10, 20, 30, 40, 50].map((pageSize) => (\n \n {pageSize}\n \n ))}\n \n \n
    \n
    \n Page {table.getState().pagination.pageIndex + 1} of {table.getPageCount()}\n
    \n
    \n table.setPageIndex(0)}\n disabled={!table.getCanPreviousPage()}\n >\n Go to first page\n \n \n table.previousPage()}\n disabled={!table.getCanPreviousPage()}\n >\n Go to previous page\n \n \n table.nextPage()}\n disabled={!table.getCanNextPage()}\n >\n Go to next page\n \n \n table.setPageIndex(table.getPageCount() - 1)}\n disabled={!table.getCanNextPage()}\n >\n Go to last page\n \n \n
    \n
    \n
    \n );\n}\n\nexport default DataTablePagination;\n","import React from 'react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Table = React.forwardRef<\n HTMLTableElement,\n React.HTMLAttributes & { stickyHeader?: boolean }\n>(({ className, stickyHeader, ...props }, ref) => (\n
    \n \n
    \n));\nTable.displayName = 'Table';\n\nconst TableHeader = React.forwardRef<\n HTMLTableSectionElement,\n React.HTMLAttributes & { stickyHeader?: boolean }\n>(({ className, stickyHeader, ...props }, ref) => (\n \n));\nTableHeader.displayName = 'TableHeader';\n\nconst TableBody = React.forwardRef<\n HTMLTableSectionElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableBody.displayName = 'TableBody';\n\nconst TableFooter = React.forwardRef<\n HTMLTableSectionElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n tr]:last:tw-border-b-0', className)}\n {...props}\n />\n));\nTableFooter.displayName = 'TableFooter';\n\nconst TableRow = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nTableRow.displayName = 'TableRow';\n\nconst TableHead = React.forwardRef<\n HTMLTableCellElement,\n React.ThHTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableHead.displayName = 'TableHead';\n\nconst TableCell = React.forwardRef<\n HTMLTableCellElement,\n React.TdHTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableCell.displayName = 'TableCell';\n\nconst TableCaption = React.forwardRef<\n HTMLTableCaptionElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n \n));\nTableCaption.displayName = 'TableCaption';\n\nexport { Table, TableHeader, TableBody, TableFooter, TableHead, TableRow, TableCell, TableCaption };\n","import { useState } from 'react';\n\nimport {\n ColumnFiltersState,\n flexRender,\n getCoreRowModel,\n getFilteredRowModel,\n getPaginationRowModel,\n getSortedRowModel,\n SortingState,\n ColumnDef as TSColumnDef,\n Row as TSRow,\n RowSelectionState as TSRowSelectionState,\n SortDirection as TSSortDirection,\n Table as TSTable,\n useReactTable,\n VisibilityState,\n} from '@tanstack/react-table';\n\nimport DataTableViewOptions from '@/components/advanced/data-table/data-table-column-toggle.component';\nimport DataTablePagination from '@/components/advanced/data-table/data-table-pagination.component';\nimport { Button } from '@/components/shadcn-ui/button';\nimport {\n Table,\n TableBody,\n TableCell,\n TableHead,\n TableHeader,\n TableRow,\n} from '@/components/shadcn-ui/table';\n\nexport type ColumnDef = TSColumnDef;\nexport type RowContents = TSRow;\nexport type TableContents = TSTable;\nexport type SortDirection = TSSortDirection;\nexport type RowSelectionState = TSRowSelectionState;\n\ninterface DataTableProps {\n columns: ColumnDef[];\n data: TData[];\n enablePagination?: boolean;\n showPaginationControls?: boolean;\n showColumnVisibilityControls?: boolean;\n stickyHeader?: boolean;\n onRowClickHandler?: (row: RowContents, table: TableContents) => void;\n}\n\n/**\n * Feature-rich table component that infuses our basic shadcn-based Table component with features\n * from TanStack's React Table library\n */\nfunction DataTable({\n columns,\n data,\n enablePagination = false,\n showPaginationControls = false,\n showColumnVisibilityControls = false,\n stickyHeader = false,\n onRowClickHandler = () => {},\n}: DataTableProps) {\n const [sorting, setSorting] = useState([]);\n const [columnFilters, setColumnFilters] = useState([]);\n const [columnVisibility, setColumnVisibility] = useState({});\n const [rowSelection, setRowSelection] = useState({});\n\n const table = useReactTable({\n data,\n columns,\n getCoreRowModel: getCoreRowModel(),\n ...(enablePagination && { getPaginationRowModel: getPaginationRowModel() }),\n onSortingChange: setSorting,\n getSortedRowModel: getSortedRowModel(),\n onColumnFiltersChange: setColumnFilters,\n getFilteredRowModel: getFilteredRowModel(),\n onColumnVisibilityChange: setColumnVisibility,\n onRowSelectionChange: setRowSelection,\n state: {\n sorting,\n columnFilters,\n columnVisibility,\n rowSelection,\n },\n });\n\n return (\n
    \n {showColumnVisibilityControls && }\n \n \n {table.getHeaderGroups().map((headerGroup) => (\n \n {headerGroup.headers.map((header) => {\n return (\n \n {header.isPlaceholder\n ? undefined\n : flexRender(header.column.columnDef.header, header.getContext())}\n \n );\n })}\n \n ))}\n \n \n {table.getRowModel().rows?.length ? (\n table.getRowModel().rows.map((row) => (\n onRowClickHandler(row, table)}\n key={row.id}\n data-state={row.getIsSelected() && 'selected'}\n >\n {row.getVisibleCells().map((cell) => (\n \n {flexRender(cell.column.columnDef.cell, cell.getContext())}\n \n ))}\n \n ))\n ) : (\n \n \n No results.\n \n \n )}\n \n
    \n {enablePagination && (\n
    \n table.previousPage()}\n disabled={!table.getCanPreviousPage()}\n >\n Previous\n \n table.nextPage()}\n disabled={!table.getCanNextPage()}\n >\n Next\n \n
    \n )}\n {enablePagination && showPaginationControls && }\n
    \n );\n}\n\nexport default DataTable;\n","import {\n Table,\n TableBody,\n TableCell,\n TableHead,\n TableHeader,\n TableRow,\n} from '@/components/shadcn-ui/table';\nimport { Canon } from '@sillsdev/scripture';\nimport { deepEqual, LanguageStrings, ScriptureReference } from 'platform-bible-utils';\nimport { useMemo } from 'react';\nimport { InventoryItemOccurrence } from './inventory-utils';\n\n/** Props for the OccurrencesTable component */\ntype OccurrencesTableProps = {\n /** Data that contains scriptures references and snippets of scripture */\n occurrenceData: InventoryItemOccurrence[];\n /** Callback function that is executed when the scripture reference is changed */\n setScriptureReference: (scriptureReference: ScriptureReference) => void;\n /**\n * Object with all localized strings that the OccurrencesTable needs to work well across multiple\n * languages\n */\n localizedStrings: LanguageStrings;\n};\n\n/**\n * Table that shows occurrences of specified inventory item(s). The first column shows the related\n * scripture reference. The second column shows the snippet of scripture that contains the specified\n * inventory item\n */\nfunction OccurrencesTable({\n occurrenceData,\n setScriptureReference,\n localizedStrings,\n}: OccurrencesTableProps) {\n const referenceHeaderText =\n localizedStrings['%webView_inventory_occurrences_table_header_reference%'];\n const occurrenceHeaderText =\n localizedStrings['%webView_inventory_occurrences_table_header_occurrence%'];\n\n const occurrences: InventoryItemOccurrence[] = useMemo(() => {\n const uniqueOccurrences: InventoryItemOccurrence[] = [];\n\n occurrenceData.forEach((occurrence) => {\n if (!uniqueOccurrences.some((uniqueOccurrence) => deepEqual(uniqueOccurrence, occurrence))) {\n uniqueOccurrences.push(occurrence);\n }\n });\n\n return uniqueOccurrences;\n }, [occurrenceData]);\n\n return (\n \n \n \n {referenceHeaderText}\n {occurrenceHeaderText}\n \n \n \n {occurrences.length > 0 &&\n occurrences.map((occurrence) => (\n {\n setScriptureReference(occurrence.reference);\n }}\n >\n {`${Canon.bookNumberToEnglishName(occurrence.reference.bookNum)} ${occurrence.reference.chapterNum}:${occurrence.reference.verseNum}`}\n {occurrence.text}\n \n ))}\n \n
    \n );\n}\n\nexport default OccurrencesTable;\n","import React from 'react';\nimport * as CheckboxPrimitive from '@radix-ui/react-checkbox';\nimport { Check } from 'lucide-react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Checkbox = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n \n \n));\nCheckbox.displayName = CheckboxPrimitive.Root.displayName;\n\nexport default Checkbox;\n","import { Canon } from '@sillsdev/scripture';\nimport { ScriptureReference } from 'platform-bible-utils';\n\n/* #region Types */\n\n/**\n * Status of items that appear in inventories. 'approved' and 'unapproved' items are defined in the\n * project's `Settings.xml`. All other items are defined as 'unknown'\n */\nexport type Status = 'approved' | 'unapproved' | 'unknown';\n\n/** Occurrence of item in inventory. Primarily used by table that shows occurrences */\nexport type InventoryItemOccurrence = {\n /** Reference to scripture where the item appears */\n reference: ScriptureReference;\n /** Snippet of scripture that contains the occurrence */\n text: string;\n};\n\n/** Data structure that contains all information on an item that is shown in an inventory */\nexport type InventoryTableData = {\n /**\n * The item (e.g. a character in the characters inventory, a marker in the marker inventory) In\n * most cases the array will only have one element. In case of additional items (e.g. the\n * preceding marker in the markers check), the primary item should be stored in the first index.\n * To show additional items in the inventory, make sure to configure the `additionalItemsLabels`\n * prop for the Inventory component\n */\n items: string[];\n /** The number of times this item occurs in the selected scope */\n count: number;\n /** The status of this item (see documentation for `Status` type for more information) */\n status: Status;\n /** Occurrences of this item in the scripture text for the selected scope */\n occurrences: InventoryItemOccurrence[];\n};\n\n/* #endregion */\n\n/* #region Functions */\n\n/**\n * Splits USFM string into shorter line-like segments\n *\n * @param text A single (likely very large) USFM string\n * @returns An array containing the input text, split into shorter segments\n */\nexport const getLinesFromUSFM = (text: string) => {\n // Splits on (CR)LF, CR, \\v, \\c and \\id\n return text.split(/(?:\\r?\\n|\\r)|(?=(?:\\\\(?:v|c|id)))/g);\n};\n\n/**\n * Extracts chapter or verse number from USFM strings that start with a \\c or \\v marker\n *\n * @param text USFM string that is expected to start with \\c or \\v marker\n * @returns Chapter or verse number if one is found. Else returns 0.\n */\nexport const getNumberFromUSFM = (text: string): number | undefined => {\n // Captures all digits that follow \\v or \\c markers followed by whitespace located at the start of a string\n const regex = /^\\\\[vc]\\s+(\\d+)/;\n const match = text.match(regex);\n\n if (match) {\n return +match[1];\n }\n return undefined;\n};\n\n/**\n * Gets book ID from USFM string that starts with the \\id marker, and returns book number for it\n *\n * @param text USFM string that is expected to start with \\id marker\n * @returns Book number corresponding to the \\id marker in the input text. Returns 0 if no marker is\n * found or the marker is not valid\n */\nexport const getBookNumFromId = (text: string): number => {\n // Captures all digits that follow an \\id marker followed by whitespace located at the start of a string\n const match = text.match(/^\\\\id\\s+([A-Za-z]+)/);\n if (match) {\n return Canon.bookIdToNumber(match[1]);\n }\n return 0;\n};\n\n/**\n * Gets the status for an item, typically used in the Inventory component\n *\n * @param item The item for which the status is being requested\n * @param approvedItems Array of approved items, typically as defined in `Settings.xml`\n * @param unapprovedItems Array of unapproved items, typically as defined in `Settings.xml`\n * @returns The status for the specified item\n */\nexport const getStatusForItem = (\n item: string,\n approvedItems: string[],\n unapprovedItems: string[],\n): Status => {\n if (unapprovedItems.includes(item)) return 'unapproved';\n if (approvedItems.includes(item)) return 'approved';\n return 'unknown';\n};\n\n/* #endregion */\n","import React from 'react';\nimport * as TogglePrimitive from '@radix-ui/react-toggle';\nimport { cva, type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst toggleVariants = cva(\n 'pr-twp tw-inline-flex tw-items-center tw-justify-center tw-rounded-md tw-text-sm tw-font-medium tw-ring-offset-background tw-transition-colors hover:tw-bg-muted hover:tw-text-muted-foreground focus-visible:tw-outline-none focus-visible:tw-ring-2 focus-visible:tw-ring-ring focus-visible:tw-ring-offset-2 disabled:tw-pointer-events-none disabled:tw-opacity-50 data-[state=on]:tw-bg-accent data-[state=on]:tw-text-accent-foreground',\n {\n variants: {\n variant: {\n default: 'tw-bg-transparent',\n outline:\n 'tw-border tw-border-input tw-bg-transparent hover:tw-bg-accent hover:tw-text-accent-foreground',\n },\n size: {\n default: 'tw-h-10 tw-px-3',\n sm: 'tw-h-9 tw-px-2.5',\n lg: 'tw-h-11 tw-px-5',\n },\n },\n defaultVariants: {\n variant: 'default',\n size: 'default',\n },\n },\n);\n\nconst Toggle = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef & VariantProps\n>(({ className, variant, size, ...props }, ref) => (\n \n));\n\nToggle.displayName = TogglePrimitive.Root.displayName;\n\nexport { Toggle, toggleVariants };\n","import React from 'react';\nimport * as ToggleGroupPrimitive from '@radix-ui/react-toggle-group';\nimport { type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { toggleVariants } from '@/components/shadcn-ui/toggle';\n\nconst ToggleGroupContext = React.createContext>({\n size: 'default',\n variant: 'default',\n});\n\nconst ToggleGroup = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef &\n VariantProps\n>(({ className, variant, size, children, ...props }, ref) => (\n \n \n {children}\n \n \n));\n\nToggleGroup.displayName = ToggleGroupPrimitive.Root.displayName;\n\nconst ToggleGroupItem = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef &\n VariantProps\n>(({ className, children, variant, size, ...props }, ref) => {\n const context = React.useContext(ToggleGroupContext);\n\n return (\n \n {children}\n \n );\n});\n\nToggleGroupItem.displayName = ToggleGroupPrimitive.Item.displayName;\n\nexport { ToggleGroup, ToggleGroupItem };\n","import { ColumnDef, SortDirection } from '@/components/advanced/data-table/data-table.component';\nimport { Button } from '@/components/shadcn-ui/button';\nimport { ToggleGroup, ToggleGroupItem } from '@/components/shadcn-ui/toggle-group';\nimport {\n ArrowDownIcon,\n ArrowUpDownIcon,\n ArrowUpIcon,\n CircleCheckIcon,\n CircleHelpIcon,\n CircleXIcon,\n} from 'lucide-react';\nimport { ReactNode } from 'react';\nimport { InventoryTableData, Status } from './inventory-utils';\n\n/**\n * Gets an icon that indicates the current sorting direction based on the provided input\n *\n * @param sortDirection Sorting direction. Can be ascending ('asc'), descending ('desc') or false (\n * i.e. not sorted)\n * @returns The appropriate sorting icon for the provided sorting direction\n */\nconst getSortingIcon = (sortDirection: false | SortDirection): ReactNode => {\n if (sortDirection === 'asc') {\n return ;\n }\n if (sortDirection === 'desc') {\n return ;\n }\n return ;\n};\n\n/**\n * Function that creates the item column for inventories\n *\n * @param itemLabel Localized label for the item column (e.g. 'Character', 'Repeated Word', etc.)\n * @returns Column that shows the inventory items. Should be used with the DataTable component\n */\nexport const inventoryItemColumn = (itemLabel: string): ColumnDef => {\n return {\n accessorKey: 'item',\n accessorFn: (row: InventoryTableData) => row.items[0],\n header: ({ column }) => (\n \n ),\n };\n};\n\n/**\n * Function that creates the additional item columns for inventories\n *\n * @param additionalItemLabel Localized label for the additional item column (e.g. 'Preceding\n * Marker')\n * @param additionalItemIndex Index that locates the desired item in the items array of the\n * inventory\n * @returns Column that shows additional inventory items. Should be used with the DataTable\n * component\n */\nexport const inventoryAdditionalItemColumn = (\n additionalItemLabel: string,\n additionalItemIndex: number,\n): ColumnDef => {\n return {\n accessorKey: `item${additionalItemIndex}`,\n accessorFn: (row: InventoryTableData) => row.items[additionalItemIndex],\n header: ({ column }) => (\n \n ),\n };\n};\n\n/**\n * Function that creates the count column for inventories. Should be used with the DataTable\n * component.\n *\n * @param itemLabel Localized label for the count column\n * @returns Column that shows the number of occurrences of the related inventory items\n */\nexport const inventoryCountColumn = (countLabel: string): ColumnDef => {\n return {\n accessorKey: 'count',\n header: ({ column }) => (\n
    \n \n
    \n ),\n cell: ({ row }) =>
    {row.getValue('count')}
    ,\n };\n};\n\n/**\n * Function that updates project settings when status for item(s) changes\n *\n * @param changedItems Array of items for which the status is being updated\n * @param newStatus The status that the items are being given\n * @param approvedItems Array of currently approved items\n * @param onApprovedItemsChange Callback function that stores the updated list of approved items\n * @param unapprovedItems Array of currently unapproved items\n * @param onUnapprovedItemsChange Callback function that stores the updated list of unapproved items\n */\nconst statusChangeHandler = (\n changedItems: string[],\n newStatus: Status,\n approvedItems: string[],\n onApprovedItemsChange: (items: string[]) => void,\n unapprovedItems: string[],\n onUnapprovedItemsChange: (items: string[]) => void,\n) => {\n let newApprovedItems: string[] = [...approvedItems];\n changedItems.forEach((item) => {\n if (newStatus === 'approved') {\n if (!newApprovedItems.includes(item)) {\n newApprovedItems.push(item);\n }\n } else {\n newApprovedItems = newApprovedItems.filter((validItem) => validItem !== item);\n }\n });\n onApprovedItemsChange(newApprovedItems);\n\n let newUnapprovedItems: string[] = [...unapprovedItems];\n changedItems.forEach((item) => {\n if (newStatus === 'unapproved') {\n if (!newUnapprovedItems.includes(item)) {\n newUnapprovedItems.push(item);\n }\n } else {\n newUnapprovedItems = newUnapprovedItems.filter((unapprovedItem) => unapprovedItem !== item);\n }\n });\n onUnapprovedItemsChange(newUnapprovedItems);\n};\n\n/**\n * Function that creates the status column for inventories. Should be used with the DataTable\n * component.\n *\n * @param statusLabel Localized label for the status column\n * @param approvedItems Array of approved items, typically as defined in `Settings.xml`\n * @param onApprovedItemsChange Callback function that stores the updated list of approved items\n * @param unapprovedItems Array of unapproved items, typically as defined in `Settings.xml`\n * @param onUnapprovedItemsChange Callback function that stores the updated list of unapproved items\n * @returns Column that shows the status buttons for the related inventory item. The button for the\n * current status of the item is selected\n */\nexport const inventoryStatusColumn = (\n statusLabel: string,\n approvedItems: string[],\n onApprovedItemsChange: (items: string[]) => void,\n unapprovedItems: string[],\n onUnapprovedItemsChange: (items: string[]) => void,\n): ColumnDef => {\n return {\n accessorKey: 'status',\n header: ({ column }) => {\n return (\n
    \n \n
    \n );\n },\n cell: ({ row }) => {\n const status: Status = row.getValue('status');\n const item: string = row.getValue('item');\n return (\n \n \n statusChangeHandler(\n [item],\n 'approved',\n approvedItems,\n onApprovedItemsChange,\n unapprovedItems,\n onUnapprovedItemsChange,\n )\n }\n value=\"approved\"\n >\n \n \n \n statusChangeHandler(\n [item],\n 'unapproved',\n approvedItems,\n onApprovedItemsChange,\n unapprovedItems,\n onUnapprovedItemsChange,\n )\n }\n value=\"unapproved\"\n >\n \n \n \n statusChangeHandler(\n [item],\n 'unknown',\n approvedItems,\n onApprovedItemsChange,\n unapprovedItems,\n onUnapprovedItemsChange,\n )\n }\n value=\"unknown\"\n >\n \n \n \n );\n },\n };\n};\n","import DataTable, {\n ColumnDef,\n RowContents,\n RowSelectionState,\n TableContents,\n} from '@/components/advanced/data-table/data-table.component';\nimport OccurrencesTable from '@/components/advanced/inventory/occurrences-table.component';\nimport Checkbox from '@/components/shadcn-ui/checkbox';\nimport { Input } from '@/components/shadcn-ui/input';\nimport { Label } from '@/components/shadcn-ui/label';\nimport {\n Select,\n SelectContent,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\nimport {\n deepEqual,\n LocalizedStringValue,\n ScriptureReference,\n substring,\n} from 'platform-bible-utils';\nimport { useEffect, useMemo, useState } from 'react';\nimport {\n getBookNumFromId,\n getLinesFromUSFM,\n getNumberFromUSFM,\n getStatusForItem,\n InventoryItemOccurrence,\n InventoryTableData,\n Status,\n} from './inventory-utils';\nimport { inventoryAdditionalItemColumn } from './inventory-columns';\n\n/**\n * Object containing all keys used for localization in this component. If you're using this\n * component in an extension, you can pass it into the useLocalizedStrings hook to easily obtain the\n * localized strings and pass them into the localizedStrings prop of this component\n */\nexport const INVENTORY_STRING_KEYS = Object.freeze([\n '%webView_inventory_all%',\n '%webView_inventory_approved%',\n '%webView_inventory_unapproved%',\n '%webView_inventory_unknown%',\n '%webView_inventory_scope_currentBook%',\n '%webView_inventory_scope_chapter%',\n '%webView_inventory_scope_verse%',\n '%webView_inventory_filter_text%',\n '%webView_inventory_show_additional_items%',\n '%webView_inventory_occurrences_table_header_reference%',\n '%webView_inventory_occurrences_table_header_occurrence%',\n] as const);\n\nexport type InventoryLocalizedStrings = {\n [localizedInventoryKey in (typeof INVENTORY_STRING_KEYS)[number]]?: LocalizedStringValue;\n};\n\n/** Scope of scripture that the inventory can operate on */\nexport type Scope = 'book' | 'chapter' | 'verse';\n\n/** Status values that the status filter can select from */\ntype StatusFilter = Status | 'all';\n\n/** Text labels for the inventory columns and the control components of additional inventory items */\ntype AdditionalItemsLabels = {\n checkboxText?: string;\n tableHeaders?: string[];\n};\n\n/**\n * Filters data that is shown in the DataTable section of the Inventory\n *\n * @param itemData All inventory items and their related information\n * @param statusFilter Allows filtering by status (i.e. show all items, or only items that are\n * 'approved', 'unapproved' or 'unknown')\n * @param textFilter Allows filtering by text. All items that include the filter text will be\n * selected.\n * @returns Array of items and their related information that are matched by the specified filters\n */\nconst filterItemData = (\n itemData: InventoryTableData[],\n statusFilter: StatusFilter,\n textFilter: string,\n): InventoryTableData[] => {\n let filteredItemData: InventoryTableData[] = itemData;\n\n if (statusFilter !== 'all') {\n filteredItemData = filteredItemData.filter(\n (item) =>\n (statusFilter === 'approved' && item.status === 'approved') ||\n (statusFilter === 'unapproved' && item.status === 'unapproved') ||\n (statusFilter === 'unknown' && item.status === 'unknown'),\n );\n }\n\n if (textFilter !== '')\n filteredItemData = filteredItemData.filter((item) => item.items[0].includes(textFilter));\n\n return filteredItemData;\n};\n\n/**\n * Turns array of strings into array of inventory items, along with their count and status\n *\n * @param text The source scripture text that is searched for inventory items\n * @param scriptureRef The scripture reference that the application is currently set to\n * @param approvedItems Array of approved items, typically as defined in `Settings.xml`\n * @param unapprovedItems Array of unapproved items, typically as defined in `Settings.xml`\n * @param itemRegex Regular expression that describes what items this Inventory should extract from\n * the provided scripture text\n * @returns Array of inventory items, along with their count and status\n */\nconst createTableData = (\n text: string | undefined,\n scriptureRef: ScriptureReference,\n approvedItems: string[],\n unapprovedItems: string[],\n itemRegex: RegExp,\n): InventoryTableData[] => {\n if (!text) return [];\n\n const tableData: InventoryTableData[] = [];\n\n let currentBook: number | undefined = scriptureRef.bookNum;\n let currentChapter: number | undefined = scriptureRef.chapterNum;\n let currentVerse: number | undefined = scriptureRef.verseNum;\n\n const lines = getLinesFromUSFM(text);\n\n lines.forEach((line: string) => {\n if (line.startsWith('\\\\id')) {\n currentBook = getBookNumFromId(line);\n currentChapter = 0;\n currentVerse = 0;\n }\n if (line.startsWith('\\\\c')) {\n currentChapter = getNumberFromUSFM(line);\n currentVerse = 0;\n }\n if (line.startsWith('\\\\v')) {\n currentVerse = getNumberFromUSFM(line);\n if (currentChapter === 0) {\n currentChapter = scriptureRef.chapterNum;\n }\n }\n\n let match: RegExpExecArray | undefined = itemRegex.exec(line) ?? undefined;\n while (match) {\n const items: string[] = [];\n match.forEach((item) => items.push(item));\n const itemIndex = match.index;\n const existingItem = tableData.find((tableEntry) => deepEqual(tableEntry.items, items));\n const newReference: InventoryItemOccurrence = {\n reference: {\n bookNum: currentBook !== undefined ? currentBook : -1,\n chapterNum: currentChapter !== undefined ? currentChapter : -1,\n verseNum: currentVerse !== undefined ? currentVerse : -1,\n },\n text: substring(line, Math.max(0, itemIndex - 25), Math.min(itemIndex + 25, line.length)),\n };\n if (existingItem) {\n existingItem.count += 1;\n existingItem.occurrences.push(newReference);\n } else {\n const newItem: InventoryTableData = {\n items,\n count: 1,\n status: getStatusForItem(items[0], approvedItems, unapprovedItems),\n occurrences: [newReference],\n };\n tableData.push(newItem);\n }\n\n match = itemRegex.exec(line) ?? undefined;\n }\n });\n\n return tableData;\n};\n\n/**\n * Gets the localized value for the provided key\n *\n * @param strings Object containing localized string\n * @param key Key for a localized string\n * @returns The localized value for the provided key, if available. Returns the key if no localized\n * value is available\n */\nconst localizeString = (\n strings: InventoryLocalizedStrings,\n key: keyof InventoryLocalizedStrings,\n) => {\n return strings[key] ?? key;\n};\n\n/** Props for the Inventory component */\ntype InventoryProps = {\n /** The scripture reference that the application is currently set to */\n scriptureReference: ScriptureReference;\n /** Callback function that is executed when the scripture reference is changed */\n setScriptureReference: (scriptureReference: ScriptureReference) => void;\n /**\n * Object with all localized strings that the Inventory needs to work well across multiple\n * languages. When using this component with Platform.Bible, you can import\n * `INVENTORY_STRING_KEYS` from this library, pass it in to the Platform's localization hook, and\n * pass the localized keys that are returned by the hook into this prop.\n */\n localizedStrings: InventoryLocalizedStrings;\n /**\n * The logic that finds the desired items in the source text. This can either be a Regular\n * expression that captures one or multiple items (preferred), or a custom function that builds\n * and return an InventoryDataTable[] manually. Note: In case the logic captures more than one\n * item (i.e. InventoryTableData.items has a length greater than 1), you must provide text labels\n * for the related columns and control elements to show by setting the `additionalItemsLabels`\n * prop\n */\n extractItems:\n | RegExp\n | ((\n text: string | undefined,\n scriptureRef: ScriptureReference,\n approvedItems: string[],\n unapprovedItems: string[],\n ) => InventoryTableData[]);\n /**\n * Text labels for control elements and additional column headers in case your Inventory has more\n * than one item to show (e.g. The 'Preceding Marker' in the Markers Inventory)\n */\n additionalItemsLabels?: AdditionalItemsLabels;\n /** Array of approved items, typically as defined in `Settings.xml` */\n approvedItems: string[];\n /** Array of unapproved items, typically as defined in `Settings.xml` */\n unapprovedItems: string[];\n /** The source scripture text that is searched for in inventory items */\n text: string | undefined;\n /** Scope of scripture that the inventory will operate on */\n scope: Scope;\n /** Callback function that is executed when the scope is changed from the Inventory */\n onScopeChange: (scope: Scope) => void;\n /**\n * Column definitions for the Inventory data table. The most commonly used column definitions are\n * pre-configured for your convenience and can be imported (e.g. inventoryItemColumn,\n * inventoryAdditionalItemColumn inventoryCountColumn, and inventoryStatusColumn). If you need any\n * other columns you can add these yourself\n */\n columns: ColumnDef[];\n};\n\n/** Inventory component that is used to view and control the status of provided project settings */\nexport default function Inventory({\n scriptureReference,\n setScriptureReference,\n localizedStrings,\n extractItems,\n additionalItemsLabels,\n approvedItems,\n unapprovedItems,\n text,\n scope,\n onScopeChange,\n columns,\n}: InventoryProps) {\n const allItemsText = localizeString(localizedStrings, '%webView_inventory_all%');\n const approvedItemsText = localizeString(localizedStrings, '%webView_inventory_approved%');\n const unapprovedItemsText = localizeString(localizedStrings, '%webView_inventory_unapproved%');\n const unknownItemsText = localizeString(localizedStrings, '%webView_inventory_unknown%');\n const scopeBookText = localizeString(localizedStrings, '%webView_inventory_scope_currentBook%');\n const scopeChapterText = localizeString(localizedStrings, '%webView_inventory_scope_chapter%');\n const scopeVerseText = localizeString(localizedStrings, '%webView_inventory_scope_verse%');\n const filterText = localizeString(localizedStrings, '%webView_inventory_filter_text%');\n const showAdditionalItemsText = localizeString(\n localizedStrings,\n '%webView_inventory_show_additional_items%',\n );\n\n const [showAdditionalItems, setShowAdditionalItems] = useState(false);\n const [statusFilter, setStatusFilter] = useState('all');\n const [textFilter, setTextFilter] = useState('');\n const [selectedItem, setSelectedItem] = useState([]);\n\n const tableData: InventoryTableData[] = useMemo(() => {\n if (!text) return [];\n if (extractItems instanceof RegExp)\n return createTableData(\n text,\n scriptureReference,\n approvedItems,\n unapprovedItems,\n extractItems,\n );\n return extractItems(text, scriptureReference, approvedItems, unapprovedItems);\n }, [text, extractItems, scriptureReference, approvedItems, unapprovedItems]);\n\n const reducedTableData: InventoryTableData[] = useMemo(() => {\n if (showAdditionalItems) return tableData;\n\n const newTableData: InventoryTableData[] = [];\n\n tableData.forEach((tableEntry) => {\n const firstItem = tableEntry.items[0];\n\n const existingEntry = newTableData.find(\n (newTableEntry) => newTableEntry.items[0] === firstItem,\n );\n\n if (existingEntry) {\n existingEntry.count += tableEntry.count;\n existingEntry.occurrences = existingEntry.occurrences.concat(tableEntry.occurrences);\n } else {\n newTableData.push({\n items: [firstItem],\n count: tableEntry.count,\n occurrences: tableEntry.occurrences,\n status: tableEntry.status,\n });\n }\n });\n\n return newTableData;\n }, [showAdditionalItems, tableData]);\n\n const filteredTableData: InventoryTableData[] = useMemo(() => {\n return filterItemData(reducedTableData, statusFilter, textFilter);\n }, [reducedTableData, statusFilter, textFilter]);\n\n const allColumns: ColumnDef[] = useMemo(() => {\n if (!showAdditionalItems) return columns;\n\n const numberOfAdditionalItems = additionalItemsLabels?.tableHeaders?.length;\n if (!numberOfAdditionalItems) return columns;\n\n const additionalColumns: ColumnDef[] = [];\n\n for (let index = 0; index < numberOfAdditionalItems; index++) {\n additionalColumns.push(\n inventoryAdditionalItemColumn(\n additionalItemsLabels?.tableHeaders?.[index] || 'Additional Item',\n index + 1,\n ),\n );\n }\n\n return [...additionalColumns, ...columns];\n }, [additionalItemsLabels?.tableHeaders, columns, showAdditionalItems]);\n\n useEffect(() => {\n setSelectedItem([]);\n }, [filteredTableData]);\n\n const rowClickHandler = (\n row: RowContents,\n table: TableContents,\n ) => {\n table.setRowSelection(() => {\n const newSelection: RowSelectionState = {};\n newSelection[row.index] = true;\n return newSelection;\n });\n\n setSelectedItem(row.original.items);\n };\n\n const handleScopeChange = (value: string) => {\n if (value === 'book' || value === 'chapter' || value === 'verse') {\n onScopeChange(value);\n } else {\n throw new Error(`Invalid scope value: ${value}`);\n }\n };\n\n const handleStatusFilterChange = (value: string) => {\n if (value === 'all' || value === 'approved' || value === 'unapproved' || value === 'unknown') {\n setStatusFilter(value);\n } else {\n throw new Error(`Invalid status filter value: ${value}`);\n }\n };\n\n const occurrenceData: InventoryItemOccurrence[] = useMemo(() => {\n if (reducedTableData.length === 0 || selectedItem.length === 0) return [];\n const occurrence = reducedTableData.filter((tableEntry: InventoryTableData) => {\n return deepEqual(\n showAdditionalItems ? tableEntry.items : [tableEntry.items[0]],\n selectedItem,\n );\n });\n if (occurrence.length > 1) throw new Error('Selected item is not unique');\n return occurrence[0].occurrences;\n }, [selectedItem, showAdditionalItems, reducedTableData]);\n\n return (\n
    \n
    \n handleStatusFilterChange(value)}\n defaultValue={statusFilter}\n >\n \n \n \n \n {allItemsText}\n {approvedItemsText}\n {unapprovedItemsText}\n {unknownItemsText}\n \n \n \n {\n setTextFilter(event.target.value);\n }}\n />\n {additionalItemsLabels && (\n
    \n {\n setSelectedItem([]);\n setShowAdditionalItems(checked);\n }}\n />\n \n
    \n )}\n
    \n
    \n \n
    \n {occurrenceData.length > 0 && (\n
    \n \n
    \n )}\n
    \n );\n}\n","import { Input } from '@/components/shadcn-ui/input';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { useState } from 'react';\n\n/** Props for the SearchBar component. */\nexport type SearchBarProps = {\n /** Additional css classes to help with unique styling of the search bar */\n className?: string;\n /**\n * Callback fired to handle the search query when button pressed\n *\n * @param searchQuery\n */\n onSearch: (searchQuery: string) => void;\n\n /** Optional string that appears in the search bar without a search string */\n placeholder?: string;\n\n /** Optional boolean to set the input base to full width */\n isFullWidth?: boolean;\n};\n\nexport default function SearchBar({\n className,\n onSearch,\n placeholder,\n isFullWidth,\n}: SearchBarProps) {\n const [searchQuery, setSearchQuery] = useState('');\n\n const handleInputChange = (searchString: string) => {\n setSearchQuery(searchString);\n onSearch(searchString);\n };\n\n return (\n handleInputChange(e.target.value)}\n />\n );\n}\n","// adapted from: https://github.com/shadcn-ui/ui/discussions/752\n\n'use client';\n\nimport { TabsContentProps, TabsListProps, TabsTriggerProps } from '@/components/shadcn-ui/tabs';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport * as TabsPrimitive from '@radix-ui/react-tabs';\nimport React from 'react';\n\nexport type VerticalTabsProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport type LeftTabsTriggerProps = TabsTriggerProps & {\n value: string;\n ref?: React.Ref;\n};\n\nexport const VerticalTabs = React.forwardRef<\n React.ElementRef,\n VerticalTabsProps\n>(({ className, ...props }, ref) => (\n \n));\n\nVerticalTabs.displayName = TabsPrimitive.List.displayName;\n\nexport const VerticalTabsList = React.forwardRef<\n React.ElementRef,\n TabsListProps\n>(({ className, ...props }, ref) => (\n \n));\nVerticalTabsList.displayName = TabsPrimitive.List.displayName;\n\nexport const VerticalTabsTrigger = React.forwardRef<\n React.ElementRef,\n LeftTabsTriggerProps\n>(({ className, ...props }, ref) => (\n \n));\n\nexport const VerticalTabsContent = React.forwardRef<\n React.ElementRef,\n TabsContentProps\n>(({ className, ...props }, ref) => (\n \n));\nVerticalTabsContent.displayName = TabsPrimitive.Content.displayName;\n","import SearchBar from '@/components/basics/search-bar.component';\nimport {\n VerticalTabs,\n VerticalTabsContent,\n VerticalTabsList,\n VerticalTabsTrigger,\n} from '@/components/basics/tabs-vertical';\nimport { ReactNode } from 'react';\n\nexport type TabKeyValueContent = {\n key: string;\n value: string;\n content: ReactNode;\n};\n\nexport type TabNavigationContentSearchProps = {\n /** List of values and keys for each tab this component should provide */\n tabList: TabKeyValueContent[];\n\n /** Handler to run when the value of the search bar changes */\n onSearch: (searchQuery: string) => void;\n\n /** Optional placeholder for the search bar */\n searchPlaceholder?: string;\n\n /** Optional title to include in the header */\n headerTitle?: string;\n\n /** Optional flag to make the search bar appear full width */\n isSearchBarFullWidth?: boolean;\n\n /** Text direction ltr or rtl */\n direction?: 'ltr' | 'rtl';\n};\n\nexport default function TabNavigationContentSearch({\n tabList,\n onSearch,\n searchPlaceholder,\n headerTitle,\n isSearchBarFullWidth = false,\n direction = 'ltr',\n}: TabNavigationContentSearchProps) {\n return (\n
    \n
    \n {headerTitle ?

    {headerTitle}

    : ''}\n \n
    \n \n \n {tabList.map((tab) => (\n \n {tab.value}\n \n ))}\n \n {tabList.map((tab) => (\n \n {tab.content}\n \n ))}\n \n
    \n );\n}\n","import React from 'react';\nimport * as SeparatorPrimitive from '@radix-ui/react-separator';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Separator = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, orientation = 'horizontal', decorative = true, ...props }, ref) => (\n \n));\nSeparator.displayName = SeparatorPrimitive.Root.displayName;\n\nexport { Separator };\n","import React from 'react';\nimport { cn } from '@/utils/shadcn-ui.util';\n\nfunction Skeleton({ className, ...props }: React.HTMLAttributes) {\n return (\n \n );\n}\n\nexport { Skeleton };\n","import React from 'react';\nimport * as TooltipPrimitive from '@radix-ui/react-tooltip';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst TooltipProvider = TooltipPrimitive.Provider;\n\nconst Tooltip = TooltipPrimitive.Root;\n\nconst TooltipTrigger = TooltipPrimitive.Trigger;\n\nconst TooltipContent = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, sideOffset = 4, ...props }, ref) => (\n \n));\nTooltipContent.displayName = TooltipPrimitive.Content.displayName;\n\nexport { Tooltip, TooltipTrigger, TooltipContent, TooltipProvider };\n","import React from 'react';\nimport { Slot } from '@radix-ui/react-slot';\nimport { VariantProps, cva } from 'class-variance-authority';\nimport { PanelLeft } from 'lucide-react';\n\nimport { Button } from '@/components/shadcn-ui/button';\nimport { Input } from '@/components/shadcn-ui/input';\nimport { Separator } from '@/components/shadcn-ui/separator';\nimport { Skeleton } from '@/components/shadcn-ui/skeleton';\nimport {\n Tooltip,\n TooltipContent,\n TooltipProvider,\n TooltipTrigger,\n} from '@/components/shadcn-ui/tooltip';\nimport { cn } from '@/utils/shadcn-ui.util';\n\n/**\n * Changes from the original code from Shadcn- Removed uses of useIsMobile, Sheet, and SheetContent.\n * Also removed the parts setting COOKIES.\n */\n\nconst SIDEBAR_WIDTH = '16rem';\nconst SIDEBAR_WIDTH_ICON = '3rem';\n// Commented this out pending a discussion with UX about keyboard shortcuts\n// const SIDEBAR_KEYBOARD_SHORTCUT = 'b';\n\ntype SidebarContextProps = {\n state: 'expanded' | 'collapsed';\n open: boolean;\n setOpen: (open: boolean) => void;\n toggleSidebar: () => void;\n};\n\nconst SidebarContext = React.createContext(undefined);\n\nfunction useSidebar() {\n const context = React.useContext(SidebarContext);\n if (!context) {\n throw new Error('useSidebar must be used within a SidebarProvider.');\n }\n\n return context;\n}\n\nconst SidebarProvider = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & {\n defaultOpen?: boolean;\n open?: boolean;\n onOpenChange?: (open: boolean) => void;\n }\n>(\n (\n {\n defaultOpen = true,\n open: openProp,\n onOpenChange: setOpenProp,\n className,\n style,\n children,\n ...props\n },\n ref,\n ) => {\n // This is the internal state of the sidebar.\n // We use openProp and setOpenProp for control from outside the component.\n const [_open, _setOpen] = React.useState(defaultOpen);\n const isOpen = openProp ?? _open;\n const setOpen = React.useCallback(\n (value: boolean | ((value: boolean) => boolean)) => {\n const openState = typeof value === 'function' ? value(isOpen) : value;\n if (setOpenProp) {\n setOpenProp(openState);\n } else {\n _setOpen(openState);\n }\n },\n [setOpenProp, isOpen],\n );\n\n // Helper to toggle the sidebar.\n const toggleSidebar = React.useCallback(() => {\n return setOpen((open) => !open);\n }, [setOpen]);\n\n // Commented this out pending a discussion with UX about keyboard shortcuts\n // Adds a keyboard shortcut to toggle the sidebar.\n // React.useEffect(() => {\n // const handleKeyDown = (event: KeyboardEvent) => {\n // if (event.key === SIDEBAR_KEYBOARD_SHORTCUT && (event.metaKey || event.ctrlKey)) {\n // event.preventDefault();\n // toggleSidebar();\n // }\n // };\n\n // window.addEventListener('keydown', handleKeyDown);\n // return () => window.removeEventListener('keydown', handleKeyDown);\n // }, [toggleSidebar]);\n\n // We add a state so that we can do data-state=\"expanded\" or \"collapsed\".\n // This makes it easier to style the sidebar with Tailwind classes.\n const state = isOpen ? 'expanded' : 'collapsed';\n\n const contextValue = React.useMemo(\n () => ({\n state,\n open: isOpen,\n setOpen,\n toggleSidebar,\n }),\n [state, isOpen, setOpen, toggleSidebar],\n );\n\n return (\n \n \n \n {children}\n
    \n \n \n );\n },\n);\nSidebarProvider.displayName = 'SidebarProvider';\n\nconst Sidebar = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & {\n side?: 'left' | 'right';\n variant?: 'sidebar' | 'floating' | 'inset';\n collapsible?: 'offcanvas' | 'icon' | 'none';\n }\n>(\n (\n {\n side = 'left',\n variant = 'sidebar',\n collapsible = 'offcanvas',\n className,\n children,\n ...props\n },\n ref,\n ) => {\n const { state } = useSidebar();\n\n if (collapsible === 'none') {\n return (\n \n {children}\n
    \n );\n }\n\n return (\n \n {/* This is what handles the sidebar gap on desktop */}\n \n \n \n {children}\n
    \n
    \n
    \n );\n },\n);\nSidebar.displayName = 'Sidebar';\n\nconst SidebarTrigger = React.forwardRef<\n React.ElementRef,\n React.ComponentProps\n>(({ className, onClick, ...props }, ref) => {\n const { toggleSidebar } = useSidebar();\n\n return (\n {\n onClick?.(event);\n toggleSidebar();\n }}\n {...props}\n >\n \n Toggle Sidebar\n \n );\n});\nSidebarTrigger.displayName = 'SidebarTrigger';\n\nconst SidebarRail = React.forwardRef>(\n ({ className, ...props }, ref) => {\n const { toggleSidebar } = useSidebar();\n\n return (\n \n );\n },\n);\nSidebarRail.displayName = 'SidebarRail';\n\nconst SidebarInset = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarInset.displayName = 'SidebarInset';\n\nconst SidebarInput = React.forwardRef<\n React.ElementRef,\n React.ComponentProps\n>(({ className, ...props }, ref) => {\n return (\n \n );\n});\nSidebarInput.displayName = 'SidebarInput';\n\nconst SidebarHeader = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarHeader.displayName = 'SidebarHeader';\n\nconst SidebarFooter = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarFooter.displayName = 'SidebarFooter';\n\nconst SidebarSeparator = React.forwardRef<\n React.ElementRef,\n React.ComponentProps\n>(({ className, ...props }, ref) => {\n return (\n \n );\n});\nSidebarSeparator.displayName = 'SidebarSeparator';\n\nconst SidebarContent = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarContent.displayName = 'SidebarContent';\n\nconst SidebarGroup = React.forwardRef>(\n ({ className, ...props }, ref) => {\n return (\n \n );\n },\n);\nSidebarGroup.displayName = 'SidebarGroup';\n\nconst SidebarGroupLabel = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & { asChild?: boolean }\n>(({ className, asChild = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'div';\n\n return (\n svg]:tw-size-4 [&>svg]:tw-shrink-0',\n 'group-data-[collapsible=icon]:tw--mt-8 group-data-[collapsible=icon]:tw-opacity-0',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarGroupLabel.displayName = 'SidebarGroupLabel';\n\nconst SidebarGroupAction = React.forwardRef<\n HTMLButtonElement,\n React.ComponentProps<'button'> & { asChild?: boolean }\n>(({ className, asChild = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'button';\n\n return (\n svg]:tw-size-4 [&>svg]:tw-shrink-0',\n // Increases the hit area of the button on mobile.\n 'after:tw-absolute after:tw--inset-2 after:md:tw-hidden',\n 'group-data-[collapsible=icon]:tw-hidden',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarGroupAction.displayName = 'SidebarGroupAction';\n\nconst SidebarGroupContent = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarGroupContent.displayName = 'SidebarGroupContent';\n\nconst SidebarMenu = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenu.displayName = 'SidebarMenu';\n\nconst SidebarMenuItem = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenuItem.displayName = 'SidebarMenuItem';\n\nconst sidebarMenuButtonVariants = cva(\n // Removed data-[active=true]:tw-bg-sidebar-accent\n 'tw-peer/menu-button tw-flex tw-w-full tw-items-center tw-gap-2 tw-overflow-hidden tw-rounded-md tw-p-2 tw-text-left tw-text-sm tw-outline-none tw-ring-sidebar-ring tw-transition-[width,height,padding] hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground focus-visible:tw-ring-2 active:tw-bg-sidebar-accent active:tw-text-sidebar-accent-foreground disabled:tw-pointer-events-none disabled:tw-opacity-50 tw-group-has-[[data-sidebar=menu-action]]/menu-item:pr-8 aria-disabled:tw-pointer-events-none aria-disabled:tw-opacity-50 data-[active=true]:tw-font-medium data-[active=true]:tw-text-sidebar-accent-foreground data-[state=open]:hover:tw-bg-sidebar-accent data-[state=open]:hover:tw-text-sidebar-accent-foreground group-data-[collapsible=icon]:tw-!size-8 group-data-[collapsible=icon]:tw-!p-2 [&>span:last-child]:tw-truncate [&>svg]:tw-size-4 [&>svg]:tw-shrink-0',\n {\n variants: {\n variant: {\n default: 'hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground',\n outline:\n 'tw-bg-background tw-shadow-[0_0_0_1px_hsl(var(--sidebar-border))] hover:tw-bg-sidebar-accent hover:tw-text-sidebar-accent-foreground hover:tw-shadow-[0_0_0_1px_hsl(var(--sidebar-accent))]',\n },\n size: {\n default: 'tw-h-8 tw-text-sm',\n sm: 'tw-h-7 tw-text-xs',\n lg: 'tw-h-12 tw-text-sm group-data-[collapsible=icon]:tw-!p-0',\n },\n },\n defaultVariants: {\n variant: 'default',\n size: 'default',\n },\n },\n);\n\nconst SidebarMenuButton = React.forwardRef<\n HTMLButtonElement,\n React.ComponentProps<'button'> & {\n asChild?: boolean;\n isActive?: boolean;\n tooltip?: string | React.ComponentProps;\n } & VariantProps\n>(\n (\n {\n asChild = false,\n isActive = false,\n variant = 'default',\n size = 'default',\n tooltip,\n className,\n ...props\n },\n ref,\n ) => {\n const Comp = asChild ? Slot : 'button';\n const { state } = useSidebar();\n\n const button = (\n \n );\n\n if (!tooltip) {\n return button;\n }\n\n if (typeof tooltip === 'string') {\n // eslint-disable-next-line no-param-reassign\n tooltip = {\n children: tooltip,\n };\n }\n\n return (\n \n {button}\n \n );\n },\n);\nSidebarMenuButton.displayName = 'SidebarMenuButton';\n\nconst SidebarMenuAction = React.forwardRef<\n HTMLButtonElement,\n React.ComponentProps<'button'> & {\n asChild?: boolean;\n showOnHover?: boolean;\n }\n>(({ className, asChild = false, showOnHover = false, ...props }, ref) => {\n const Comp = asChild ? Slot : 'button';\n\n return (\n svg]:tw-size-4 [&>svg]:tw-shrink-0',\n // Increases the hit area of the button on mobile.\n 'after:tw-absolute after:tw--inset-2 after:md:tw-hidden',\n 'tw-peer-data-[size=sm]/menu-button:top-1',\n 'tw-peer-data-[size=default]/menu-button:top-1.5',\n 'tw-peer-data-[size=lg]/menu-button:top-2.5',\n 'group-data-[collapsible=icon]:tw-hidden',\n showOnHover &&\n 'tw-group-focus-within/menu-item:opacity-100 tw-group-hover/menu-item:opacity-100 tw-peer-data-[active=true]/menu-button:text-sidebar-accent-foreground data-[state=open]:tw-opacity-100 md:tw-opacity-0',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarMenuAction.displayName = 'SidebarMenuAction';\n\nconst SidebarMenuBadge = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenuBadge.displayName = 'SidebarMenuBadge';\n\nconst SidebarMenuSkeleton = React.forwardRef<\n HTMLDivElement,\n React.ComponentProps<'div'> & {\n showIcon?: boolean;\n }\n>(({ className, showIcon = false, ...props }, ref) => {\n // Random width between 50 to 90%.\n const width = React.useMemo(() => {\n return `${Math.floor(Math.random() * 40) + 50}%`;\n }, []);\n\n return (\n \n {showIcon && (\n \n )}\n \n
    \n );\n});\nSidebarMenuSkeleton.displayName = 'SidebarMenuSkeleton';\n\nconst SidebarMenuSub = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nSidebarMenuSub.displayName = 'SidebarMenuSub';\n\nconst SidebarMenuSubItem = React.forwardRef>(\n ({ ...props }, ref) =>
  • ,\n);\nSidebarMenuSubItem.displayName = 'SidebarMenuSubItem';\n\nconst SidebarMenuSubButton = React.forwardRef<\n HTMLAnchorElement,\n React.ComponentProps<'a'> & {\n asChild?: boolean;\n size?: 'sm' | 'md';\n isActive?: boolean;\n }\n>(({ asChild = false, size = 'md', isActive, className, ...props }, ref) => {\n const Comp = asChild ? Slot : 'a';\n\n return (\n span:last-child]:tw-truncate [&>svg]:tw-size-4 [&>svg]:tw-shrink-0 [&>svg]:tw-text-sidebar-accent-foreground',\n 'data-[active=true]:tw-bg-sidebar-accent data-[active=true]:tw-text-sidebar-accent-foreground',\n size === 'sm' && 'tw-text-xs',\n size === 'md' && 'tw-text-sm',\n 'group-data-[collapsible=icon]:tw-hidden',\n className,\n )}\n {...props}\n />\n );\n});\nSidebarMenuSubButton.displayName = 'SidebarMenuSubButton';\n\nexport {\n Sidebar,\n SidebarContent,\n SidebarFooter,\n SidebarGroup,\n SidebarGroupAction,\n SidebarGroupContent,\n SidebarGroupLabel,\n SidebarHeader,\n SidebarInput,\n SidebarInset,\n SidebarMenu,\n SidebarMenuAction,\n SidebarMenuBadge,\n SidebarMenuButton,\n SidebarMenuItem,\n SidebarMenuSkeleton,\n SidebarMenuSub,\n SidebarMenuSubButton,\n SidebarMenuSubItem,\n SidebarProvider,\n SidebarRail,\n SidebarSeparator,\n SidebarTrigger,\n useSidebar,\n};\n","import ComboBox, { ComboBoxOption } from '@/components/basics/combo-box.component';\nimport {\n Sidebar,\n SidebarContent,\n SidebarGroup,\n SidebarGroupLabel,\n SidebarGroupContent,\n SidebarMenu,\n SidebarMenuItem,\n SidebarMenuButton,\n} from '@/components/shadcn-ui/sidebar';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { useCallback } from 'react';\n\nexport type SelectedSettingsSidebarItem = {\n label: string;\n projectId?: string;\n};\n\nexport type ProjectInfo = { projectId: string; projectName: string };\n\nexport type SettingsSidebarProps = {\n /** Optional id for testing */\n id?: string;\n\n /** Extension labels from contribution */\n extensionLabels: string[];\n\n /** Project names and ids */\n projectInfo: ProjectInfo[];\n\n /** Handler for selecting a sidebar item */\n handleSelectSidebarItem: (key: string, projectId?: string) => void;\n\n /** The current selected value in the sidebar */\n selectedSidebarItem: SelectedSettingsSidebarItem;\n\n /** Label for the group of extensions setting groups */\n extensionsSidebarGroupLabel: string;\n\n /** Label for the group of projects settings */\n projectsSidebarGroupLabel: string;\n\n /** Placeholder text for the button */\n buttonPlaceholderText: string;\n};\n\nexport default function SettingsSidebar({\n id,\n extensionLabels,\n projectInfo,\n handleSelectSidebarItem,\n selectedSidebarItem,\n extensionsSidebarGroupLabel,\n projectsSidebarGroupLabel,\n buttonPlaceholderText,\n}: SettingsSidebarProps) {\n const handleSelectItem = useCallback(\n (item: string, projectId?: string) => {\n handleSelectSidebarItem(item, projectId);\n },\n [handleSelectSidebarItem],\n );\n\n const getProjectNameFromProjectId = useCallback(\n (projectId: string) => {\n const project = projectInfo.find((info) => info.projectId === projectId);\n return project ? project.projectName : projectId;\n },\n [projectInfo],\n );\n\n const getIsActive: (label: string) => boolean = useCallback(\n (label: string) => !selectedSidebarItem.projectId && label === selectedSidebarItem.label,\n [selectedSidebarItem],\n );\n\n return (\n \n \n \n \n {extensionsSidebarGroupLabel}\n \n \n \n {extensionLabels.map((label) => (\n \n handleSelectItem(label)}\n isActive={getIsActive(label)}\n >\n {label}\n \n \n ))}\n \n \n \n \n \n {projectsSidebarGroupLabel}\n \n \n info.projectId)}\n getOptionLabel={(projectId: ComboBoxOption) => {\n // This function expects a ComboBoxOption, but we know it is a string\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n return getProjectNameFromProjectId(projectId as string);\n }}\n buttonPlaceholder={buttonPlaceholderText}\n onChange={(projectId: string) => {\n const selectedProjectName = getProjectNameFromProjectId(projectId);\n handleSelectItem(selectedProjectName, projectId);\n }}\n value={selectedSidebarItem?.projectId ?? undefined}\n />\n \n \n \n \n );\n}\n","import { SidebarInset, SidebarProvider } from '@/components/shadcn-ui/sidebar';\nimport { PropsWithChildren } from 'react';\nimport SearchBar from '@/components/basics/search-bar.component';\nimport SettingsSidebar, { SettingsSidebarProps } from './settings-sidebar.component';\n\nexport type SettingsSidebarContentSearchProps = SettingsSidebarProps &\n PropsWithChildren & {\n /** Optional id for testing */\n id?: string;\n\n /** Handler to run when the value of the search bar changes */\n onSearch: (searchQuery: string) => void;\n };\n\nexport default function SettingsSidebarContentSearch({\n id,\n extensionLabels,\n projectInfo,\n children,\n handleSelectSidebarItem,\n selectedSidebarItem,\n onSearch,\n extensionsSidebarGroupLabel,\n projectsSidebarGroupLabel,\n buttonPlaceholderText,\n}: SettingsSidebarContentSearchProps) {\n return (\n
    \n
    \n \n
    \n \n \n {children}\n \n
    \n );\n}\n","import { Button } from '@/components/shadcn-ui/button';\nimport {\n Select,\n SelectContent,\n SelectGroup,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\nimport {\n Table,\n TableBody,\n TableCell,\n TableHead,\n TableHeader,\n TableRow,\n} from '@/components/shadcn-ui/table';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Canon } from '@sillsdev/scripture';\nimport {\n Cell,\n ColumnDef,\n flexRender,\n getCoreRowModel,\n getExpandedRowModel,\n getGroupedRowModel,\n getSortedRowModel,\n GroupingState,\n Row,\n RowSelectionState,\n SortingState,\n useReactTable,\n} from '@tanstack/react-table';\nimport '@/components/advanced/scripture-results-viewer/scripture-results-viewer.component.css';\nimport {\n compareScrRefs,\n formatScrRef,\n ScriptureSelection,\n scrRefToBBBCCCVVV,\n} from 'platform-bible-utils';\nimport { MouseEvent, useEffect, useMemo, useState } from 'react';\nimport { ChevronDown, ChevronLeft, ChevronRight } from 'lucide-react';\n\n/**\n * Information (e.g., a checking error or some other type of \"transient\" annotation) about something\n * noteworthy at a specific place in an instance of the Scriptures.\n */\nexport type ScriptureItemDetail = ScriptureSelection & {\n /**\n * Text of the error, note, etc. In the future, we might want to support something more than just\n * text so that a JSX element could be provided with a link or some other controls related to the\n * issue being reported.\n */\n detail: string;\n};\n\n/**\n * A uniquely identifiable source of results that can be displayed in the ScriptureResultsViewer.\n * Generally, the source will be a particular Scripture check, but there may be other types of\n * sources.\n */\nexport type ResultsSource = {\n /**\n * Uniquely identifies the source.\n *\n * @type {string}\n */\n id: string;\n\n /**\n * Name (potentially localized) of the source, suitable for display in the UI.\n *\n * @type {string}\n */\n displayName: string;\n};\n\nexport type ScriptureSrcItemDetail = ScriptureItemDetail & {\n /** Source/type of detail. Can be used for grouping. */\n source: ResultsSource;\n};\n\n/**\n * Represents a set of results keyed by Scripture reference. Generally, the source will be a\n * particular Scripture check, but this type also allows for other types of uniquely identifiable\n * sources.\n */\nexport type ResultsSet = {\n /**\n * The backing source associated with this set of results.\n *\n * @type {ResultsSource}\n */\n source: ResultsSource;\n\n /**\n * Array of Scripture item details (messages keyed by Scripture reference).\n *\n * @type {ScriptureItemDetail[]}\n */\n data: ScriptureItemDetail[];\n};\n\nconst scrBookColId = 'scrBook';\nconst scrRefColId = 'scrRef';\nconst typeColId = 'source';\nconst detailsColId = 'details';\n\nconst defaultScrRefColumnName = 'Scripture Reference';\nconst defaultScrBookGroupName = 'Scripture Book';\nconst defaultTypeColumnName = 'Type';\nconst defaultDetailsColumnName = 'Details';\n\nexport type ScriptureResultsViewerColumnInfo = {\n /** Optional header to display for the Reference column. Default value: 'Scripture Reference'. */\n scriptureReferenceColumnName?: string;\n\n /** Optional text to display to refer to the Scripture book group. Default value: 'Scripture Book'. */\n scriptureBookGroupName?: string;\n\n /** Optional header to display for the Type column. Default value: 'Type'. */\n typeColumnName?: string;\n\n /** Optional header to display for the Details column. Default value: 'Details' */\n detailsColumnName?: string;\n};\n\nexport type ScriptureResultsViewerProps = ScriptureResultsViewerColumnInfo & {\n /** Groups of ScriptureItemDetail objects from particular sources (e.g., Scripture checks) */\n sources: ResultsSet[];\n\n /** Flag indicating whether to display column headers. Default is false. */\n showColumnHeaders?: boolean;\n\n /** Flag indicating whether to display source column. Default is false. */\n showSourceColumn?: boolean;\n\n /** Callback function to notify when a row is selected */\n onRowSelected?: (selectedRow: ScriptureSrcItemDetail | undefined) => void;\n\n /** Text direction ltr or rtl */\n direction?: 'ltr' | 'rtl';\n};\n\nfunction getColumns(\n colInfo?: ScriptureResultsViewerColumnInfo,\n showSourceColumn?: boolean,\n): ColumnDef[] {\n const showSrcCol = showSourceColumn ?? false;\n return [\n {\n accessorFn: (row) =>\n `${Canon.bookNumberToId(row.start.bookNum)} ${row.start.chapterNum}:${row.start.verseNum}`,\n id: scrBookColId,\n header: colInfo?.scriptureReferenceColumnName ?? defaultScrRefColumnName,\n cell: (info) => {\n const row = info.row.original;\n if (info.row.getIsGrouped()) {\n return Canon.bookNumberToEnglishName(row.start.bookNum);\n }\n return info.row.groupingColumnId === scrBookColId ? formatScrRef(row.start) : undefined;\n },\n getGroupingValue: (row) => row.start.bookNum,\n sortingFn: (a, b) => {\n return compareScrRefs(a.original.start, b.original.start);\n },\n enableGrouping: true,\n },\n {\n accessorFn: (row) => formatScrRef(row.start),\n id: scrRefColId,\n header: undefined,\n cell: (info) => {\n const row = info.row.original;\n return info.row.getIsGrouped() ? undefined : formatScrRef(row.start);\n },\n sortingFn: (a, b) => {\n return compareScrRefs(a.original.start, b.original.start);\n },\n enableGrouping: false,\n },\n {\n accessorFn: (row) => row.source.displayName,\n id: typeColId,\n header: showSrcCol ? (colInfo?.typeColumnName ?? defaultTypeColumnName) : undefined,\n cell: (info) => (showSrcCol || info.row.getIsGrouped() ? info.getValue() : undefined),\n getGroupingValue: (row) => row.source.id,\n sortingFn: (a, b) =>\n a.original.source.displayName.localeCompare(b.original.source.displayName),\n enableGrouping: true,\n },\n {\n accessorFn: (row) => row.detail,\n id: detailsColId,\n header: colInfo?.detailsColumnName ?? defaultDetailsColumnName,\n cell: (info) => info.getValue(),\n enableGrouping: false,\n },\n ];\n}\n\nconst toRefOrRange = (scriptureSelection: ScriptureSelection) => {\n if (!('offset' in scriptureSelection.start))\n throw new Error('No offset available in range start');\n if (scriptureSelection.end && !('offset' in scriptureSelection.end))\n throw new Error('No offset available in range end');\n const { offset: offsetStart } = scriptureSelection.start;\n let offsetEnd: number = 0;\n if (scriptureSelection.end) ({ offset: offsetEnd } = scriptureSelection.end);\n if (\n !scriptureSelection.end ||\n compareScrRefs(scriptureSelection.start, scriptureSelection.end) === 0\n )\n return `${scrRefToBBBCCCVVV(scriptureSelection.start)}+${offsetStart}`;\n return `${scrRefToBBBCCCVVV(scriptureSelection.start)}+${offsetStart}-${scrRefToBBBCCCVVV(scriptureSelection.end)}+${offsetEnd}`;\n};\n\nconst getRowKey = (row: ScriptureSrcItemDetail) =>\n `${toRefOrRange({ start: row.start, end: row.end })} ${row.source.displayName} ${row.detail}`;\n\n/**\n * Component to display a combined list of detailed items from one or more sources, where the items\n * are keyed primarily by Scripture reference. This is particularly useful for displaying a list of\n * results from Scripture checks, but more generally could be used to display any \"results\" from any\n * source(s). The component allows for grouping by Scripture book, source, or both. By default, it\n * displays somewhat \"tree-like\" which allows it to be more horizontally compact and intuitive. But\n * it also has the option of displaying as a traditional table with column headings (with or without\n * the source column showing).\n */\nexport default function ScriptureResultsViewer({\n sources,\n showColumnHeaders = false,\n showSourceColumn = false,\n scriptureReferenceColumnName,\n scriptureBookGroupName,\n typeColumnName,\n detailsColumnName,\n onRowSelected,\n direction = 'ltr',\n}: ScriptureResultsViewerProps) {\n const [grouping, setGrouping] = useState([]);\n const [sorting, setSorting] = useState([{ id: scrBookColId, desc: false }]);\n const [rowSelection, setRowSelection] = useState({});\n\n const scriptureResults = useMemo(\n () =>\n sources.flatMap((source) => {\n return source.data.map((item) => ({\n ...item,\n source: source.source,\n }));\n }),\n [sources],\n );\n\n const columns = useMemo(\n () =>\n getColumns(\n {\n scriptureReferenceColumnName,\n typeColumnName,\n detailsColumnName,\n },\n showSourceColumn,\n ),\n [scriptureReferenceColumnName, typeColumnName, detailsColumnName, showSourceColumn],\n );\n\n useEffect(() => {\n // Ensure sorting is applied correctly when grouped by type\n if (grouping.includes(typeColId)) {\n setSorting([\n { id: typeColId, desc: false },\n { id: scrBookColId, desc: false },\n ]);\n } else {\n setSorting([{ id: scrBookColId, desc: false }]);\n }\n }, [grouping]);\n\n const table = useReactTable({\n data: scriptureResults,\n columns,\n state: {\n grouping,\n sorting,\n rowSelection,\n },\n onGroupingChange: setGrouping,\n onSortingChange: setSorting,\n onRowSelectionChange: setRowSelection,\n getExpandedRowModel: getExpandedRowModel(),\n getGroupedRowModel: getGroupedRowModel(),\n getCoreRowModel: getCoreRowModel(),\n getSortedRowModel: getSortedRowModel(),\n getRowId: getRowKey,\n autoResetExpanded: false,\n enableMultiRowSelection: false,\n enableSubRowSelection: false,\n });\n\n useEffect(() => {\n if (onRowSelected) {\n const selectedRows = table.getSelectedRowModel().rowsById;\n const keys = Object.keys(selectedRows);\n if (keys.length === 1) {\n const selectedRow = scriptureResults.find((row) => getRowKey(row) === keys[0]) || undefined;\n if (selectedRow) onRowSelected(selectedRow);\n }\n }\n }, [rowSelection, scriptureResults, onRowSelected, table]);\n\n // Define possible grouping options\n const scrBookGroupName = scriptureBookGroupName ?? defaultScrBookGroupName;\n const typeGroupName = typeColumnName ?? defaultTypeColumnName;\n\n const groupingOptions = [\n { label: 'No Grouping', value: [] },\n { label: `Group by ${scrBookGroupName}`, value: [scrBookColId] },\n { label: `Group by ${typeGroupName}`, value: [typeColId] },\n {\n label: `Group by ${scrBookGroupName} and ${typeGroupName}`,\n value: [scrBookColId, typeColId],\n },\n {\n label: `Group by ${typeGroupName} and ${scrBookGroupName}`,\n value: [typeColId, scrBookColId],\n },\n ];\n\n const handleSelectChange = (selectedGrouping: string) => {\n setGrouping(JSON.parse(selectedGrouping));\n };\n\n const handleRowClick = (row: Row, event: MouseEvent) => {\n if (!row.getIsGrouped() && !row.getIsSelected()) {\n row.getToggleSelectedHandler()(event);\n }\n };\n\n const getEvenOrOddBandingStyle = (row: Row, index: number) => {\n if (row.getIsGrouped()) return '';\n // UX has now said they don't think they want banding. I'm leaving in the code to\n // set even and odd styles, but there's nothing in the CSS to style them differently.\n // The \"even\" style used to also have tw-bg-neutral-300 (along with even) to create\n // a visual banding effect. That could be added back in if UX changes the decision.\n return cn('banded-row', index % 2 === 0 ? 'even' : 'odd');\n };\n\n const getIndent = (\n groupingState: GroupingState,\n row: Row,\n cell: Cell,\n ) => {\n if (groupingState?.length === 0 || row.depth < cell.column.getGroupedIndex()) return undefined;\n if (row.getIsGrouped()) {\n switch (row.depth) {\n case 1:\n return 'tw-ps-4';\n default:\n return undefined;\n }\n }\n switch (row.depth) {\n case 1:\n return 'tw-ps-8';\n case 2:\n return 'tw-ps-12';\n default:\n return undefined;\n }\n };\n\n return (\n
    \n {!showColumnHeaders && (\n {\n handleSelectChange(value);\n }}\n >\n \n \n \n \n \n {groupingOptions.map((option) => (\n \n {option.label}\n \n ))}\n \n \n \n )}\n \n {showColumnHeaders && (\n \n {table.getHeaderGroups().map((headerGroup) => (\n \n {headerGroup.headers\n .filter((h) => h.column.columnDef.header)\n .map((header) => (\n /* For sticky column headers to work, we probably need to change the default definition of the shadcn Table component. See https://github.com/shadcn-ui/ui/issues/1151 */\n \n {header.isPlaceholder ? undefined : (\n
    \n {header.column.getCanGroup() ? (\n \n {header.column.getIsGrouped() ? `🛑` : `👊 `}\n \n ) : undefined}{' '}\n {flexRender(header.column.columnDef.header, header.getContext())}\n
    \n )}\n
    \n ))}\n
    \n ))}\n
    \n )}\n \n {table.getRowModel().rows.map((row, rowIndex) => {\n return (\n handleRowClick(row, event)}\n >\n {row.getVisibleCells().map((cell) => {\n if (\n cell.getIsPlaceholder() ||\n (cell.column.columnDef.enableGrouping &&\n !cell.getIsGrouped() &&\n (cell.column.columnDef.id !== typeColId || !showSourceColumn))\n )\n return undefined;\n return (\n \n {(() => {\n if (cell.getIsGrouped()) {\n return (\n \n {row.getIsExpanded() && }\n {!row.getIsExpanded() &&\n (direction === 'ltr' ? : )}{' '}\n {flexRender(cell.column.columnDef.cell, cell.getContext())} (\n {row.subRows.length})\n \n );\n }\n\n // if (cell.getIsAggregated()) {\n // flexRender(\n // cell.column.columnDef.aggregatedCell ?? cell.column.columnDef.cell,\n // cell.getContext(),\n // );\n // }\n\n return flexRender(cell.column.columnDef.cell, cell.getContext());\n })()}\n \n );\n })}\n \n );\n })}\n \n
    \n
    \n );\n}\n","import {\n getLocalizeKeyForScrollGroupId,\n LanguageStrings,\n ScrollGroupId,\n} from 'platform-bible-utils';\nimport {\n Select,\n SelectContent,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from '@/components/shadcn-ui/select';\n\nconst DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS = {\n [getLocalizeKeyForScrollGroupId('undefined')]: 'Ø',\n [getLocalizeKeyForScrollGroupId(0)]: 'A',\n [getLocalizeKeyForScrollGroupId(1)]: 'B',\n [getLocalizeKeyForScrollGroupId(2)]: 'C',\n [getLocalizeKeyForScrollGroupId(3)]: 'D',\n [getLocalizeKeyForScrollGroupId(4)]: 'E',\n [getLocalizeKeyForScrollGroupId(5)]: 'F',\n [getLocalizeKeyForScrollGroupId(6)]: 'G',\n [getLocalizeKeyForScrollGroupId(7)]: 'H',\n [getLocalizeKeyForScrollGroupId(8)]: 'I',\n [getLocalizeKeyForScrollGroupId(9)]: 'J',\n [getLocalizeKeyForScrollGroupId(10)]: 'K',\n [getLocalizeKeyForScrollGroupId(11)]: 'L',\n [getLocalizeKeyForScrollGroupId(12)]: 'M',\n [getLocalizeKeyForScrollGroupId(13)]: 'N',\n [getLocalizeKeyForScrollGroupId(14)]: 'O',\n [getLocalizeKeyForScrollGroupId(15)]: 'P',\n [getLocalizeKeyForScrollGroupId(16)]: 'Q',\n [getLocalizeKeyForScrollGroupId(17)]: 'R',\n [getLocalizeKeyForScrollGroupId(18)]: 'S',\n [getLocalizeKeyForScrollGroupId(19)]: 'T',\n [getLocalizeKeyForScrollGroupId(20)]: 'U',\n [getLocalizeKeyForScrollGroupId(21)]: 'V',\n [getLocalizeKeyForScrollGroupId(22)]: 'W',\n [getLocalizeKeyForScrollGroupId(23)]: 'X',\n [getLocalizeKeyForScrollGroupId(24)]: 'Y',\n [getLocalizeKeyForScrollGroupId(25)]: 'Z',\n};\n\nexport type ScrollGroupSelectorProps = {\n /**\n * List of scroll group ids to show to the user. Either a {@link ScrollGroupId} or `undefined` for\n * no scroll group\n */\n availableScrollGroupIds: (ScrollGroupId | undefined)[];\n /** Currently selected scroll group id. `undefined` for no scroll group */\n scrollGroupId: ScrollGroupId | undefined;\n /** Callback function run when the user tries to change the scroll group id */\n onChangeScrollGroupId: (newScrollGroupId: ScrollGroupId | undefined) => void;\n /**\n * Localized strings to use for displaying scroll group ids. Must be an object whose keys are\n * `getLocalizeKeyForScrollGroupId(scrollGroupId)` for all scroll group ids (and `undefined` if\n * included) in {@link ScrollGroupSelectorProps.availableScrollGroupIds} and whose values are the\n * localized strings to use for those scroll group ids.\n *\n * Defaults to English localizations of English alphabet for scroll groups 0-25 (e.g. 0 is A) and\n * Ø for `undefined`. Will fill in any that are not provided with these English localizations.\n * Also, if any values match the keys, the English localization will be used. This is useful in\n * case you want to pass in a temporary version of the localized strings while your localized\n * strings load.\n *\n * @example\n *\n * ```typescript\n * const myScrollGroupIdLocalizedStrings = {\n * [getLocalizeKeyForScrollGroupId('undefined')]: 'Ø',\n * [getLocalizeKeyForScrollGroupId(0)]: 'A',\n * [getLocalizeKeyForScrollGroupId(1)]: 'B',\n * [getLocalizeKeyForScrollGroupId(2)]: 'C',\n * [getLocalizeKeyForScrollGroupId(3)]: 'D',\n * [getLocalizeKeyForScrollGroupId(4)]: 'E',\n * };\n * ```\n *\n * @example\n *\n * ```tsx\n * const availableScrollGroupIds = [undefined, 0, 1, 2, 3, 4];\n *\n * const localizeKeys = getLocalizeKeysForScrollGroupIds();\n *\n * const [localizedStrings] = useLocalizedStrings(localizeKeys);\n *\n * ...\n *\n * \n * ```\n */\n localizedStrings?: LanguageStrings;\n};\n\n/** Selector component for choosing a scroll group */\nexport default function ScrollGroupSelector({\n availableScrollGroupIds,\n scrollGroupId,\n onChangeScrollGroupId,\n localizedStrings = {},\n}: ScrollGroupSelectorProps) {\n const localizedStringsDefaulted = {\n ...DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS,\n ...Object.fromEntries(\n Object.entries(localizedStrings).map(\n ([localizedStringKey, localizedStringValue]: [string, string]) => [\n localizedStringKey,\n localizedStringKey === localizedStringValue &&\n localizedStringKey in DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS\n ? DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS[localizedStringKey]\n : localizedStringValue,\n ],\n ),\n ),\n };\n return (\n \n onChangeScrollGroupId(\n newScrollGroupString === 'undefined' ? undefined : parseInt(newScrollGroupString, 10),\n )\n }\n >\n \n \n \n \n {availableScrollGroupIds.map((scrollGroupOptionId) => (\n \n {localizedStringsDefaulted[getLocalizeKeyForScrollGroupId(scrollGroupOptionId)]}\n \n ))}\n \n \n );\n}\n","import { PropsWithChildren } from 'react';\nimport { Separator } from '@/components/shadcn-ui/separator';\n\n/** Props for the SettingsList component, currently just children */\ntype SettingsListProps = PropsWithChildren;\n\n/**\n * SettingsList component is a wrapper for list items. Rendered with a formatted div\n *\n * @param children To populate the list with\n * @returns Formatted div encompassing the children\n */\nexport function SettingsList({ children }: SettingsListProps) {\n return
    {children}
    ;\n}\n\n/** Props for SettingsListItem component */\ntype SettingsListItemProps = PropsWithChildren & {\n /** Primary text of the list item */\n primary: string;\n\n /** Optional text of the list item */\n secondary?: string | undefined;\n\n /** Optional boolean to display a message if the children aren't loaded yet. Defaults to false */\n isLoading?: boolean;\n\n /** Optional message to display if isLoading */\n loadingMessage?: string;\n};\n\n/**\n * SettingsListItem component is a common list item. Rendered with a formatted div\n *\n * @param primary Primary text of the list item\n * @param secondary Optional secondary text of the list item\n * @param isLoading Optional, to display a message if the action component isn't generated yet,\n * defaults to false\n * @param children The action component(s) to provide for this item\n * @param loadingMessage Optional, message to display if isLoading\n * @returns Formatted div encompassing the list item content\n */\nexport function SettingsListItem({\n primary,\n secondary,\n children,\n isLoading = false,\n loadingMessage,\n}: SettingsListItemProps) {\n return (\n
    \n
    \n

    {primary}

    \n

    \n {secondary}\n

    \n
    \n\n {isLoading ? (\n

    {loadingMessage}

    \n ) : (\n
    {children}
    \n )}\n
    \n );\n}\n\n/** Props for SettingsListHeader component */\ntype SettingsListHeaderProps = {\n /** The primary text of the list header */\n primary: string;\n\n /** Optional secondary text of the list header */\n secondary?: string | undefined;\n\n /** Optional boolean to include a separator underneath the secondary text. Defaults to false */\n includeSeparator?: boolean;\n};\n\n/**\n * SettingsListHeader component displays text above the list\n *\n * @param primary The primary text of the list header\n * @param secondary Optional secondary text of the list header\n * @param includeSeparator Optional boolean to include a separator underneath the secondary text.\n * Defaults to false\n * @returns Formatted div with list header content\n */\nexport function SettingsListHeader({\n primary,\n secondary,\n includeSeparator = false,\n}: SettingsListHeaderProps) {\n return (\n
    \n
    \n

    {primary}

    \n

    {secondary}

    \n
    \n {includeSeparator ? : ''}\n
    \n );\n}\n","import Checkbox from '@/components/shadcn-ui/checkbox';\nimport { Label } from '@/components/shadcn-ui/label';\n\nexport type ChecklistProps = {\n /** Optional string representing the id attribute of the Checklist */\n id?: string;\n /** Optional string representing CSS class name(s) for styling */\n className?: string;\n /** Array of strings representing the checkable items */\n listItems: string[];\n /** Array of strings representing the checked items */\n selectedListItems: string[];\n /**\n * Function that is called when a checkbox item is selected or deselected\n *\n * @param item The string description for this item\n * @param selected True if selected, false if not selected\n */\n handleSelectListItem: (item: string, selected: boolean) => void;\n\n /**\n * Optional function creates a label for a provided checkable item\n *\n * @param item The item for which a label is to be created\n * @returns A string representing the label text for the checkbox associated with that item\n */\n createLabel?: (item: string) => string;\n};\n\n/** Renders a list of checkboxes. Each checkbox corresponds to an item from the `listItems` array. */\nexport default function Checklist({\n id,\n className,\n listItems,\n selectedListItems,\n handleSelectListItem,\n createLabel,\n}: ChecklistProps) {\n return (\n
    \n {listItems.map((item) => (\n
    \n handleSelectListItem(item, value)}\n />\n \n
    \n ))}\n
    \n );\n}\n","function _interopRequireDefault(obj) {\n return obj && obj.__esModule ? obj : {\n \"default\": obj\n };\n}\nmodule.exports = _interopRequireDefault, module.exports.__esModule = true, module.exports[\"default\"] = module.exports;","export default function chainPropTypes(propType1, propType2) {\n if (process.env.NODE_ENV === 'production') {\n return () => null;\n }\n return function validate(...args) {\n return propType1(...args) || propType2(...args);\n };\n}","export default function _extends() {\n _extends = Object.assign ? Object.assign.bind() : function (target) {\n for (var i = 1; i < arguments.length; i++) {\n var source = arguments[i];\n for (var key in source) {\n if (Object.prototype.hasOwnProperty.call(source, key)) {\n target[key] = source[key];\n }\n }\n }\n return target;\n };\n return _extends.apply(this, arguments);\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\n// https://github.com/sindresorhus/is-plain-obj/blob/main/index.js\nexport function isPlainObject(item) {\n if (typeof item !== 'object' || item === null) {\n return false;\n }\n const prototype = Object.getPrototypeOf(item);\n return (prototype === null || prototype === Object.prototype || Object.getPrototypeOf(prototype) === null) && !(Symbol.toStringTag in item) && !(Symbol.iterator in item);\n}\nfunction deepClone(source) {\n if (!isPlainObject(source)) {\n return source;\n }\n const output = {};\n Object.keys(source).forEach(key => {\n output[key] = deepClone(source[key]);\n });\n return output;\n}\nexport default function deepmerge(target, source, options = {\n clone: true\n}) {\n const output = options.clone ? _extends({}, target) : target;\n if (isPlainObject(target) && isPlainObject(source)) {\n Object.keys(source).forEach(key => {\n // Avoid prototype pollution\n if (key === '__proto__') {\n return;\n }\n if (isPlainObject(source[key]) && key in target && isPlainObject(target[key])) {\n // Since `output` is a clone of `target` and we have narrowed `target` in this block we can cast to the same type.\n output[key] = deepmerge(target[key], source[key], options);\n } else if (options.clone) {\n output[key] = isPlainObject(source[key]) ? deepClone(source[key]) : source[key];\n } else {\n output[key] = source[key];\n }\n });\n }\n return output;\n}","/** @license React v16.13.1\n * react-is.production.min.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';var b=\"function\"===typeof Symbol&&Symbol.for,c=b?Symbol.for(\"react.element\"):60103,d=b?Symbol.for(\"react.portal\"):60106,e=b?Symbol.for(\"react.fragment\"):60107,f=b?Symbol.for(\"react.strict_mode\"):60108,g=b?Symbol.for(\"react.profiler\"):60114,h=b?Symbol.for(\"react.provider\"):60109,k=b?Symbol.for(\"react.context\"):60110,l=b?Symbol.for(\"react.async_mode\"):60111,m=b?Symbol.for(\"react.concurrent_mode\"):60111,n=b?Symbol.for(\"react.forward_ref\"):60112,p=b?Symbol.for(\"react.suspense\"):60113,q=b?\nSymbol.for(\"react.suspense_list\"):60120,r=b?Symbol.for(\"react.memo\"):60115,t=b?Symbol.for(\"react.lazy\"):60116,v=b?Symbol.for(\"react.block\"):60121,w=b?Symbol.for(\"react.fundamental\"):60117,x=b?Symbol.for(\"react.responder\"):60118,y=b?Symbol.for(\"react.scope\"):60119;\nfunction z(a){if(\"object\"===typeof a&&null!==a){var u=a.$$typeof;switch(u){case c:switch(a=a.type,a){case l:case m:case e:case g:case f:case p:return a;default:switch(a=a&&a.$$typeof,a){case k:case n:case t:case r:case h:return a;default:return u}}case d:return u}}}function A(a){return z(a)===m}exports.AsyncMode=l;exports.ConcurrentMode=m;exports.ContextConsumer=k;exports.ContextProvider=h;exports.Element=c;exports.ForwardRef=n;exports.Fragment=e;exports.Lazy=t;exports.Memo=r;exports.Portal=d;\nexports.Profiler=g;exports.StrictMode=f;exports.Suspense=p;exports.isAsyncMode=function(a){return A(a)||z(a)===l};exports.isConcurrentMode=A;exports.isContextConsumer=function(a){return z(a)===k};exports.isContextProvider=function(a){return z(a)===h};exports.isElement=function(a){return\"object\"===typeof a&&null!==a&&a.$$typeof===c};exports.isForwardRef=function(a){return z(a)===n};exports.isFragment=function(a){return z(a)===e};exports.isLazy=function(a){return z(a)===t};\nexports.isMemo=function(a){return z(a)===r};exports.isPortal=function(a){return z(a)===d};exports.isProfiler=function(a){return z(a)===g};exports.isStrictMode=function(a){return z(a)===f};exports.isSuspense=function(a){return z(a)===p};\nexports.isValidElementType=function(a){return\"string\"===typeof a||\"function\"===typeof a||a===e||a===m||a===g||a===f||a===p||a===q||\"object\"===typeof a&&null!==a&&(a.$$typeof===t||a.$$typeof===r||a.$$typeof===h||a.$$typeof===k||a.$$typeof===n||a.$$typeof===w||a.$$typeof===x||a.$$typeof===y||a.$$typeof===v)};exports.typeOf=z;\n","/** @license React v16.13.1\n * react-is.development.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\n\n\nif (process.env.NODE_ENV !== \"production\") {\n (function() {\n'use strict';\n\n// The Symbol used to tag the ReactElement-like types. If there is no native Symbol\n// nor polyfill, then a plain number is used for performance.\nvar hasSymbol = typeof Symbol === 'function' && Symbol.for;\nvar REACT_ELEMENT_TYPE = hasSymbol ? Symbol.for('react.element') : 0xeac7;\nvar REACT_PORTAL_TYPE = hasSymbol ? Symbol.for('react.portal') : 0xeaca;\nvar REACT_FRAGMENT_TYPE = hasSymbol ? Symbol.for('react.fragment') : 0xeacb;\nvar REACT_STRICT_MODE_TYPE = hasSymbol ? Symbol.for('react.strict_mode') : 0xeacc;\nvar REACT_PROFILER_TYPE = hasSymbol ? Symbol.for('react.profiler') : 0xead2;\nvar REACT_PROVIDER_TYPE = hasSymbol ? Symbol.for('react.provider') : 0xeacd;\nvar REACT_CONTEXT_TYPE = hasSymbol ? Symbol.for('react.context') : 0xeace; // TODO: We don't use AsyncMode or ConcurrentMode anymore. They were temporary\n// (unstable) APIs that have been removed. Can we remove the symbols?\n\nvar REACT_ASYNC_MODE_TYPE = hasSymbol ? Symbol.for('react.async_mode') : 0xeacf;\nvar REACT_CONCURRENT_MODE_TYPE = hasSymbol ? Symbol.for('react.concurrent_mode') : 0xeacf;\nvar REACT_FORWARD_REF_TYPE = hasSymbol ? Symbol.for('react.forward_ref') : 0xead0;\nvar REACT_SUSPENSE_TYPE = hasSymbol ? Symbol.for('react.suspense') : 0xead1;\nvar REACT_SUSPENSE_LIST_TYPE = hasSymbol ? Symbol.for('react.suspense_list') : 0xead8;\nvar REACT_MEMO_TYPE = hasSymbol ? Symbol.for('react.memo') : 0xead3;\nvar REACT_LAZY_TYPE = hasSymbol ? Symbol.for('react.lazy') : 0xead4;\nvar REACT_BLOCK_TYPE = hasSymbol ? Symbol.for('react.block') : 0xead9;\nvar REACT_FUNDAMENTAL_TYPE = hasSymbol ? Symbol.for('react.fundamental') : 0xead5;\nvar REACT_RESPONDER_TYPE = hasSymbol ? Symbol.for('react.responder') : 0xead6;\nvar REACT_SCOPE_TYPE = hasSymbol ? Symbol.for('react.scope') : 0xead7;\n\nfunction isValidElementType(type) {\n return typeof type === 'string' || typeof type === 'function' || // Note: its typeof might be other than 'symbol' or 'number' if it's a polyfill.\n type === REACT_FRAGMENT_TYPE || type === REACT_CONCURRENT_MODE_TYPE || type === REACT_PROFILER_TYPE || type === REACT_STRICT_MODE_TYPE || type === REACT_SUSPENSE_TYPE || type === REACT_SUSPENSE_LIST_TYPE || typeof type === 'object' && type !== null && (type.$$typeof === REACT_LAZY_TYPE || type.$$typeof === REACT_MEMO_TYPE || type.$$typeof === REACT_PROVIDER_TYPE || type.$$typeof === REACT_CONTEXT_TYPE || type.$$typeof === REACT_FORWARD_REF_TYPE || type.$$typeof === REACT_FUNDAMENTAL_TYPE || type.$$typeof === REACT_RESPONDER_TYPE || type.$$typeof === REACT_SCOPE_TYPE || type.$$typeof === REACT_BLOCK_TYPE);\n}\n\nfunction typeOf(object) {\n if (typeof object === 'object' && object !== null) {\n var $$typeof = object.$$typeof;\n\n switch ($$typeof) {\n case REACT_ELEMENT_TYPE:\n var type = object.type;\n\n switch (type) {\n case REACT_ASYNC_MODE_TYPE:\n case REACT_CONCURRENT_MODE_TYPE:\n case REACT_FRAGMENT_TYPE:\n case REACT_PROFILER_TYPE:\n case REACT_STRICT_MODE_TYPE:\n case REACT_SUSPENSE_TYPE:\n return type;\n\n default:\n var $$typeofType = type && type.$$typeof;\n\n switch ($$typeofType) {\n case REACT_CONTEXT_TYPE:\n case REACT_FORWARD_REF_TYPE:\n case REACT_LAZY_TYPE:\n case REACT_MEMO_TYPE:\n case REACT_PROVIDER_TYPE:\n return $$typeofType;\n\n default:\n return $$typeof;\n }\n\n }\n\n case REACT_PORTAL_TYPE:\n return $$typeof;\n }\n }\n\n return undefined;\n} // AsyncMode is deprecated along with isAsyncMode\n\nvar AsyncMode = REACT_ASYNC_MODE_TYPE;\nvar ConcurrentMode = REACT_CONCURRENT_MODE_TYPE;\nvar ContextConsumer = REACT_CONTEXT_TYPE;\nvar ContextProvider = REACT_PROVIDER_TYPE;\nvar Element = REACT_ELEMENT_TYPE;\nvar ForwardRef = REACT_FORWARD_REF_TYPE;\nvar Fragment = REACT_FRAGMENT_TYPE;\nvar Lazy = REACT_LAZY_TYPE;\nvar Memo = REACT_MEMO_TYPE;\nvar Portal = REACT_PORTAL_TYPE;\nvar Profiler = REACT_PROFILER_TYPE;\nvar StrictMode = REACT_STRICT_MODE_TYPE;\nvar Suspense = REACT_SUSPENSE_TYPE;\nvar hasWarnedAboutDeprecatedIsAsyncMode = false; // AsyncMode should be deprecated\n\nfunction isAsyncMode(object) {\n {\n if (!hasWarnedAboutDeprecatedIsAsyncMode) {\n hasWarnedAboutDeprecatedIsAsyncMode = true; // Using console['warn'] to evade Babel and ESLint\n\n console['warn']('The ReactIs.isAsyncMode() alias has been deprecated, ' + 'and will be removed in React 17+. Update your code to use ' + 'ReactIs.isConcurrentMode() instead. It has the exact same API.');\n }\n }\n\n return isConcurrentMode(object) || typeOf(object) === REACT_ASYNC_MODE_TYPE;\n}\nfunction isConcurrentMode(object) {\n return typeOf(object) === REACT_CONCURRENT_MODE_TYPE;\n}\nfunction isContextConsumer(object) {\n return typeOf(object) === REACT_CONTEXT_TYPE;\n}\nfunction isContextProvider(object) {\n return typeOf(object) === REACT_PROVIDER_TYPE;\n}\nfunction isElement(object) {\n return typeof object === 'object' && object !== null && object.$$typeof === REACT_ELEMENT_TYPE;\n}\nfunction isForwardRef(object) {\n return typeOf(object) === REACT_FORWARD_REF_TYPE;\n}\nfunction isFragment(object) {\n return typeOf(object) === REACT_FRAGMENT_TYPE;\n}\nfunction isLazy(object) {\n return typeOf(object) === REACT_LAZY_TYPE;\n}\nfunction isMemo(object) {\n return typeOf(object) === REACT_MEMO_TYPE;\n}\nfunction isPortal(object) {\n return typeOf(object) === REACT_PORTAL_TYPE;\n}\nfunction isProfiler(object) {\n return typeOf(object) === REACT_PROFILER_TYPE;\n}\nfunction isStrictMode(object) {\n return typeOf(object) === REACT_STRICT_MODE_TYPE;\n}\nfunction isSuspense(object) {\n return typeOf(object) === REACT_SUSPENSE_TYPE;\n}\n\nexports.AsyncMode = AsyncMode;\nexports.ConcurrentMode = ConcurrentMode;\nexports.ContextConsumer = ContextConsumer;\nexports.ContextProvider = ContextProvider;\nexports.Element = Element;\nexports.ForwardRef = ForwardRef;\nexports.Fragment = Fragment;\nexports.Lazy = Lazy;\nexports.Memo = Memo;\nexports.Portal = Portal;\nexports.Profiler = Profiler;\nexports.StrictMode = StrictMode;\nexports.Suspense = Suspense;\nexports.isAsyncMode = isAsyncMode;\nexports.isConcurrentMode = isConcurrentMode;\nexports.isContextConsumer = isContextConsumer;\nexports.isContextProvider = isContextProvider;\nexports.isElement = isElement;\nexports.isForwardRef = isForwardRef;\nexports.isFragment = isFragment;\nexports.isLazy = isLazy;\nexports.isMemo = isMemo;\nexports.isPortal = isPortal;\nexports.isProfiler = isProfiler;\nexports.isStrictMode = isStrictMode;\nexports.isSuspense = isSuspense;\nexports.isValidElementType = isValidElementType;\nexports.typeOf = typeOf;\n })();\n}\n","'use strict';\n\nif (process.env.NODE_ENV === 'production') {\n module.exports = require('./cjs/react-is.production.min.js');\n} else {\n module.exports = require('./cjs/react-is.development.js');\n}\n","/*\nobject-assign\n(c) Sindre Sorhus\n@license MIT\n*/\n\n'use strict';\n/* eslint-disable no-unused-vars */\nvar getOwnPropertySymbols = Object.getOwnPropertySymbols;\nvar hasOwnProperty = Object.prototype.hasOwnProperty;\nvar propIsEnumerable = Object.prototype.propertyIsEnumerable;\n\nfunction toObject(val) {\n\tif (val === null || val === undefined) {\n\t\tthrow new TypeError('Object.assign cannot be called with null or undefined');\n\t}\n\n\treturn Object(val);\n}\n\nfunction shouldUseNative() {\n\ttry {\n\t\tif (!Object.assign) {\n\t\t\treturn false;\n\t\t}\n\n\t\t// Detect buggy property enumeration order in older V8 versions.\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=4118\n\t\tvar test1 = new String('abc'); // eslint-disable-line no-new-wrappers\n\t\ttest1[5] = 'de';\n\t\tif (Object.getOwnPropertyNames(test1)[0] === '5') {\n\t\t\treturn false;\n\t\t}\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=3056\n\t\tvar test2 = {};\n\t\tfor (var i = 0; i < 10; i++) {\n\t\t\ttest2['_' + String.fromCharCode(i)] = i;\n\t\t}\n\t\tvar order2 = Object.getOwnPropertyNames(test2).map(function (n) {\n\t\t\treturn test2[n];\n\t\t});\n\t\tif (order2.join('') !== '0123456789') {\n\t\t\treturn false;\n\t\t}\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=3056\n\t\tvar test3 = {};\n\t\t'abcdefghijklmnopqrst'.split('').forEach(function (letter) {\n\t\t\ttest3[letter] = letter;\n\t\t});\n\t\tif (Object.keys(Object.assign({}, test3)).join('') !==\n\t\t\t\t'abcdefghijklmnopqrst') {\n\t\t\treturn false;\n\t\t}\n\n\t\treturn true;\n\t} catch (err) {\n\t\t// We don't expect any of the above to throw, but better to be safe.\n\t\treturn false;\n\t}\n}\n\nmodule.exports = shouldUseNative() ? Object.assign : function (target, source) {\n\tvar from;\n\tvar to = toObject(target);\n\tvar symbols;\n\n\tfor (var s = 1; s < arguments.length; s++) {\n\t\tfrom = Object(arguments[s]);\n\n\t\tfor (var key in from) {\n\t\t\tif (hasOwnProperty.call(from, key)) {\n\t\t\t\tto[key] = from[key];\n\t\t\t}\n\t\t}\n\n\t\tif (getOwnPropertySymbols) {\n\t\t\tsymbols = getOwnPropertySymbols(from);\n\t\t\tfor (var i = 0; i < symbols.length; i++) {\n\t\t\t\tif (propIsEnumerable.call(from, symbols[i])) {\n\t\t\t\t\tto[symbols[i]] = from[symbols[i]];\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\n\treturn to;\n};\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar ReactPropTypesSecret = 'SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED';\n\nmodule.exports = ReactPropTypesSecret;\n","module.exports = Function.call.bind(Object.prototype.hasOwnProperty);\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar printWarning = function() {};\n\nif (process.env.NODE_ENV !== 'production') {\n var ReactPropTypesSecret = require('./lib/ReactPropTypesSecret');\n var loggedTypeFailures = {};\n var has = require('./lib/has');\n\n printWarning = function(text) {\n var message = 'Warning: ' + text;\n if (typeof console !== 'undefined') {\n console.error(message);\n }\n try {\n // --- Welcome to debugging React ---\n // This error was thrown as a convenience so that you can use this stack\n // to find the callsite that caused this warning to fire.\n throw new Error(message);\n } catch (x) { /**/ }\n };\n}\n\n/**\n * Assert that the values match with the type specs.\n * Error messages are memorized and will only be shown once.\n *\n * @param {object} typeSpecs Map of name to a ReactPropType\n * @param {object} values Runtime values that need to be type-checked\n * @param {string} location e.g. \"prop\", \"context\", \"child context\"\n * @param {string} componentName Name of the component for error messages.\n * @param {?Function} getStack Returns the component stack.\n * @private\n */\nfunction checkPropTypes(typeSpecs, values, location, componentName, getStack) {\n if (process.env.NODE_ENV !== 'production') {\n for (var typeSpecName in typeSpecs) {\n if (has(typeSpecs, typeSpecName)) {\n var error;\n // Prop type validation may throw. In case they do, we don't want to\n // fail the render phase where it didn't fail before. So we log it.\n // After these have been cleaned up, we'll let them throw.\n try {\n // This is intentionally an invariant that gets caught. It's the same\n // behavior as without this statement except with a better message.\n if (typeof typeSpecs[typeSpecName] !== 'function') {\n var err = Error(\n (componentName || 'React class') + ': ' + location + ' type `' + typeSpecName + '` is invalid; ' +\n 'it must be a function, usually from the `prop-types` package, but received `' + typeof typeSpecs[typeSpecName] + '`.' +\n 'This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.'\n );\n err.name = 'Invariant Violation';\n throw err;\n }\n error = typeSpecs[typeSpecName](values, typeSpecName, componentName, location, null, ReactPropTypesSecret);\n } catch (ex) {\n error = ex;\n }\n if (error && !(error instanceof Error)) {\n printWarning(\n (componentName || 'React class') + ': type specification of ' +\n location + ' `' + typeSpecName + '` is invalid; the type checker ' +\n 'function must return `null` or an `Error` but returned a ' + typeof error + '. ' +\n 'You may have forgotten to pass an argument to the type checker ' +\n 'creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and ' +\n 'shape all require an argument).'\n );\n }\n if (error instanceof Error && !(error.message in loggedTypeFailures)) {\n // Only monitor this failure once because there tends to be a lot of the\n // same error.\n loggedTypeFailures[error.message] = true;\n\n var stack = getStack ? getStack() : '';\n\n printWarning(\n 'Failed ' + location + ' type: ' + error.message + (stack != null ? stack : '')\n );\n }\n }\n }\n }\n}\n\n/**\n * Resets warning cache when testing.\n *\n * @private\n */\ncheckPropTypes.resetWarningCache = function() {\n if (process.env.NODE_ENV !== 'production') {\n loggedTypeFailures = {};\n }\n}\n\nmodule.exports = checkPropTypes;\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar ReactIs = require('react-is');\nvar assign = require('object-assign');\n\nvar ReactPropTypesSecret = require('./lib/ReactPropTypesSecret');\nvar has = require('./lib/has');\nvar checkPropTypes = require('./checkPropTypes');\n\nvar printWarning = function() {};\n\nif (process.env.NODE_ENV !== 'production') {\n printWarning = function(text) {\n var message = 'Warning: ' + text;\n if (typeof console !== 'undefined') {\n console.error(message);\n }\n try {\n // --- Welcome to debugging React ---\n // This error was thrown as a convenience so that you can use this stack\n // to find the callsite that caused this warning to fire.\n throw new Error(message);\n } catch (x) {}\n };\n}\n\nfunction emptyFunctionThatReturnsNull() {\n return null;\n}\n\nmodule.exports = function(isValidElement, throwOnDirectAccess) {\n /* global Symbol */\n var ITERATOR_SYMBOL = typeof Symbol === 'function' && Symbol.iterator;\n var FAUX_ITERATOR_SYMBOL = '@@iterator'; // Before Symbol spec.\n\n /**\n * Returns the iterator method function contained on the iterable object.\n *\n * Be sure to invoke the function with the iterable as context:\n *\n * var iteratorFn = getIteratorFn(myIterable);\n * if (iteratorFn) {\n * var iterator = iteratorFn.call(myIterable);\n * ...\n * }\n *\n * @param {?object} maybeIterable\n * @return {?function}\n */\n function getIteratorFn(maybeIterable) {\n var iteratorFn = maybeIterable && (ITERATOR_SYMBOL && maybeIterable[ITERATOR_SYMBOL] || maybeIterable[FAUX_ITERATOR_SYMBOL]);\n if (typeof iteratorFn === 'function') {\n return iteratorFn;\n }\n }\n\n /**\n * Collection of methods that allow declaration and validation of props that are\n * supplied to React components. Example usage:\n *\n * var Props = require('ReactPropTypes');\n * var MyArticle = React.createClass({\n * propTypes: {\n * // An optional string prop named \"description\".\n * description: Props.string,\n *\n * // A required enum prop named \"category\".\n * category: Props.oneOf(['News','Photos']).isRequired,\n *\n * // A prop named \"dialog\" that requires an instance of Dialog.\n * dialog: Props.instanceOf(Dialog).isRequired\n * },\n * render: function() { ... }\n * });\n *\n * A more formal specification of how these methods are used:\n *\n * type := array|bool|func|object|number|string|oneOf([...])|instanceOf(...)\n * decl := ReactPropTypes.{type}(.isRequired)?\n *\n * Each and every declaration produces a function with the same signature. This\n * allows the creation of custom validation functions. For example:\n *\n * var MyLink = React.createClass({\n * propTypes: {\n * // An optional string or URI prop named \"href\".\n * href: function(props, propName, componentName) {\n * var propValue = props[propName];\n * if (propValue != null && typeof propValue !== 'string' &&\n * !(propValue instanceof URI)) {\n * return new Error(\n * 'Expected a string or an URI for ' + propName + ' in ' +\n * componentName\n * );\n * }\n * }\n * },\n * render: function() {...}\n * });\n *\n * @internal\n */\n\n var ANONYMOUS = '<>';\n\n // Important!\n // Keep this list in sync with production version in `./factoryWithThrowingShims.js`.\n var ReactPropTypes = {\n array: createPrimitiveTypeChecker('array'),\n bigint: createPrimitiveTypeChecker('bigint'),\n bool: createPrimitiveTypeChecker('boolean'),\n func: createPrimitiveTypeChecker('function'),\n number: createPrimitiveTypeChecker('number'),\n object: createPrimitiveTypeChecker('object'),\n string: createPrimitiveTypeChecker('string'),\n symbol: createPrimitiveTypeChecker('symbol'),\n\n any: createAnyTypeChecker(),\n arrayOf: createArrayOfTypeChecker,\n element: createElementTypeChecker(),\n elementType: createElementTypeTypeChecker(),\n instanceOf: createInstanceTypeChecker,\n node: createNodeChecker(),\n objectOf: createObjectOfTypeChecker,\n oneOf: createEnumTypeChecker,\n oneOfType: createUnionTypeChecker,\n shape: createShapeTypeChecker,\n exact: createStrictShapeTypeChecker,\n };\n\n /**\n * inlined Object.is polyfill to avoid requiring consumers ship their own\n * https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object/is\n */\n /*eslint-disable no-self-compare*/\n function is(x, y) {\n // SameValue algorithm\n if (x === y) {\n // Steps 1-5, 7-10\n // Steps 6.b-6.e: +0 != -0\n return x !== 0 || 1 / x === 1 / y;\n } else {\n // Step 6.a: NaN == NaN\n return x !== x && y !== y;\n }\n }\n /*eslint-enable no-self-compare*/\n\n /**\n * We use an Error-like object for backward compatibility as people may call\n * PropTypes directly and inspect their output. However, we don't use real\n * Errors anymore. We don't inspect their stack anyway, and creating them\n * is prohibitively expensive if they are created too often, such as what\n * happens in oneOfType() for any type before the one that matched.\n */\n function PropTypeError(message, data) {\n this.message = message;\n this.data = data && typeof data === 'object' ? data: {};\n this.stack = '';\n }\n // Make `instanceof Error` still work for returned errors.\n PropTypeError.prototype = Error.prototype;\n\n function createChainableTypeChecker(validate) {\n if (process.env.NODE_ENV !== 'production') {\n var manualPropTypeCallCache = {};\n var manualPropTypeWarningCount = 0;\n }\n function checkType(isRequired, props, propName, componentName, location, propFullName, secret) {\n componentName = componentName || ANONYMOUS;\n propFullName = propFullName || propName;\n\n if (secret !== ReactPropTypesSecret) {\n if (throwOnDirectAccess) {\n // New behavior only for users of `prop-types` package\n var err = new Error(\n 'Calling PropTypes validators directly is not supported by the `prop-types` package. ' +\n 'Use `PropTypes.checkPropTypes()` to call them. ' +\n 'Read more at http://fb.me/use-check-prop-types'\n );\n err.name = 'Invariant Violation';\n throw err;\n } else if (process.env.NODE_ENV !== 'production' && typeof console !== 'undefined') {\n // Old behavior for people using React.PropTypes\n var cacheKey = componentName + ':' + propName;\n if (\n !manualPropTypeCallCache[cacheKey] &&\n // Avoid spamming the console because they are often not actionable except for lib authors\n manualPropTypeWarningCount < 3\n ) {\n printWarning(\n 'You are manually calling a React.PropTypes validation ' +\n 'function for the `' + propFullName + '` prop on `' + componentName + '`. This is deprecated ' +\n 'and will throw in the standalone `prop-types` package. ' +\n 'You may be seeing this warning due to a third-party PropTypes ' +\n 'library. See https://fb.me/react-warning-dont-call-proptypes ' + 'for details.'\n );\n manualPropTypeCallCache[cacheKey] = true;\n manualPropTypeWarningCount++;\n }\n }\n }\n if (props[propName] == null) {\n if (isRequired) {\n if (props[propName] === null) {\n return new PropTypeError('The ' + location + ' `' + propFullName + '` is marked as required ' + ('in `' + componentName + '`, but its value is `null`.'));\n }\n return new PropTypeError('The ' + location + ' `' + propFullName + '` is marked as required in ' + ('`' + componentName + '`, but its value is `undefined`.'));\n }\n return null;\n } else {\n return validate(props, propName, componentName, location, propFullName);\n }\n }\n\n var chainedCheckType = checkType.bind(null, false);\n chainedCheckType.isRequired = checkType.bind(null, true);\n\n return chainedCheckType;\n }\n\n function createPrimitiveTypeChecker(expectedType) {\n function validate(props, propName, componentName, location, propFullName, secret) {\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== expectedType) {\n // `propValue` being instance of, say, date/regexp, pass the 'object'\n // check, but we can offer a more precise error message here rather than\n // 'of type `object`'.\n var preciseType = getPreciseType(propValue);\n\n return new PropTypeError(\n 'Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + preciseType + '` supplied to `' + componentName + '`, expected ') + ('`' + expectedType + '`.'),\n {expectedType: expectedType}\n );\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createAnyTypeChecker() {\n return createChainableTypeChecker(emptyFunctionThatReturnsNull);\n }\n\n function createArrayOfTypeChecker(typeChecker) {\n function validate(props, propName, componentName, location, propFullName) {\n if (typeof typeChecker !== 'function') {\n return new PropTypeError('Property `' + propFullName + '` of component `' + componentName + '` has invalid PropType notation inside arrayOf.');\n }\n var propValue = props[propName];\n if (!Array.isArray(propValue)) {\n var propType = getPropType(propValue);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected an array.'));\n }\n for (var i = 0; i < propValue.length; i++) {\n var error = typeChecker(propValue, i, componentName, location, propFullName + '[' + i + ']', ReactPropTypesSecret);\n if (error instanceof Error) {\n return error;\n }\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createElementTypeChecker() {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n if (!isValidElement(propValue)) {\n var propType = getPropType(propValue);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected a single ReactElement.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createElementTypeTypeChecker() {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n if (!ReactIs.isValidElementType(propValue)) {\n var propType = getPropType(propValue);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected a single ReactElement type.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createInstanceTypeChecker(expectedClass) {\n function validate(props, propName, componentName, location, propFullName) {\n if (!(props[propName] instanceof expectedClass)) {\n var expectedClassName = expectedClass.name || ANONYMOUS;\n var actualClassName = getClassName(props[propName]);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + actualClassName + '` supplied to `' + componentName + '`, expected ') + ('instance of `' + expectedClassName + '`.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createEnumTypeChecker(expectedValues) {\n if (!Array.isArray(expectedValues)) {\n if (process.env.NODE_ENV !== 'production') {\n if (arguments.length > 1) {\n printWarning(\n 'Invalid arguments supplied to oneOf, expected an array, got ' + arguments.length + ' arguments. ' +\n 'A common mistake is to write oneOf(x, y, z) instead of oneOf([x, y, z]).'\n );\n } else {\n printWarning('Invalid argument supplied to oneOf, expected an array.');\n }\n }\n return emptyFunctionThatReturnsNull;\n }\n\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n for (var i = 0; i < expectedValues.length; i++) {\n if (is(propValue, expectedValues[i])) {\n return null;\n }\n }\n\n var valuesString = JSON.stringify(expectedValues, function replacer(key, value) {\n var type = getPreciseType(value);\n if (type === 'symbol') {\n return String(value);\n }\n return value;\n });\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of value `' + String(propValue) + '` ' + ('supplied to `' + componentName + '`, expected one of ' + valuesString + '.'));\n }\n return createChainableTypeChecker(validate);\n }\n\n function createObjectOfTypeChecker(typeChecker) {\n function validate(props, propName, componentName, location, propFullName) {\n if (typeof typeChecker !== 'function') {\n return new PropTypeError('Property `' + propFullName + '` of component `' + componentName + '` has invalid PropType notation inside objectOf.');\n }\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== 'object') {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected an object.'));\n }\n for (var key in propValue) {\n if (has(propValue, key)) {\n var error = typeChecker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret);\n if (error instanceof Error) {\n return error;\n }\n }\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createUnionTypeChecker(arrayOfTypeCheckers) {\n if (!Array.isArray(arrayOfTypeCheckers)) {\n process.env.NODE_ENV !== 'production' ? printWarning('Invalid argument supplied to oneOfType, expected an instance of array.') : void 0;\n return emptyFunctionThatReturnsNull;\n }\n\n for (var i = 0; i < arrayOfTypeCheckers.length; i++) {\n var checker = arrayOfTypeCheckers[i];\n if (typeof checker !== 'function') {\n printWarning(\n 'Invalid argument supplied to oneOfType. Expected an array of check functions, but ' +\n 'received ' + getPostfixForTypeWarning(checker) + ' at index ' + i + '.'\n );\n return emptyFunctionThatReturnsNull;\n }\n }\n\n function validate(props, propName, componentName, location, propFullName) {\n var expectedTypes = [];\n for (var i = 0; i < arrayOfTypeCheckers.length; i++) {\n var checker = arrayOfTypeCheckers[i];\n var checkerResult = checker(props, propName, componentName, location, propFullName, ReactPropTypesSecret);\n if (checkerResult == null) {\n return null;\n }\n if (checkerResult.data && has(checkerResult.data, 'expectedType')) {\n expectedTypes.push(checkerResult.data.expectedType);\n }\n }\n var expectedTypesMessage = (expectedTypes.length > 0) ? ', expected one of type [' + expectedTypes.join(', ') + ']': '';\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` supplied to ' + ('`' + componentName + '`' + expectedTypesMessage + '.'));\n }\n return createChainableTypeChecker(validate);\n }\n\n function createNodeChecker() {\n function validate(props, propName, componentName, location, propFullName) {\n if (!isNode(props[propName])) {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` supplied to ' + ('`' + componentName + '`, expected a ReactNode.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function invalidValidatorError(componentName, location, propFullName, key, type) {\n return new PropTypeError(\n (componentName || 'React class') + ': ' + location + ' type `' + propFullName + '.' + key + '` is invalid; ' +\n 'it must be a function, usually from the `prop-types` package, but received `' + type + '`.'\n );\n }\n\n function createShapeTypeChecker(shapeTypes) {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== 'object') {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type `' + propType + '` ' + ('supplied to `' + componentName + '`, expected `object`.'));\n }\n for (var key in shapeTypes) {\n var checker = shapeTypes[key];\n if (typeof checker !== 'function') {\n return invalidValidatorError(componentName, location, propFullName, key, getPreciseType(checker));\n }\n var error = checker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret);\n if (error) {\n return error;\n }\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createStrictShapeTypeChecker(shapeTypes) {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== 'object') {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type `' + propType + '` ' + ('supplied to `' + componentName + '`, expected `object`.'));\n }\n // We need to check all keys in case some are required but missing from props.\n var allKeys = assign({}, props[propName], shapeTypes);\n for (var key in allKeys) {\n var checker = shapeTypes[key];\n if (has(shapeTypes, key) && typeof checker !== 'function') {\n return invalidValidatorError(componentName, location, propFullName, key, getPreciseType(checker));\n }\n if (!checker) {\n return new PropTypeError(\n 'Invalid ' + location + ' `' + propFullName + '` key `' + key + '` supplied to `' + componentName + '`.' +\n '\\nBad object: ' + JSON.stringify(props[propName], null, ' ') +\n '\\nValid keys: ' + JSON.stringify(Object.keys(shapeTypes), null, ' ')\n );\n }\n var error = checker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret);\n if (error) {\n return error;\n }\n }\n return null;\n }\n\n return createChainableTypeChecker(validate);\n }\n\n function isNode(propValue) {\n switch (typeof propValue) {\n case 'number':\n case 'string':\n case 'undefined':\n return true;\n case 'boolean':\n return !propValue;\n case 'object':\n if (Array.isArray(propValue)) {\n return propValue.every(isNode);\n }\n if (propValue === null || isValidElement(propValue)) {\n return true;\n }\n\n var iteratorFn = getIteratorFn(propValue);\n if (iteratorFn) {\n var iterator = iteratorFn.call(propValue);\n var step;\n if (iteratorFn !== propValue.entries) {\n while (!(step = iterator.next()).done) {\n if (!isNode(step.value)) {\n return false;\n }\n }\n } else {\n // Iterator will provide entry [k,v] tuples rather than values.\n while (!(step = iterator.next()).done) {\n var entry = step.value;\n if (entry) {\n if (!isNode(entry[1])) {\n return false;\n }\n }\n }\n }\n } else {\n return false;\n }\n\n return true;\n default:\n return false;\n }\n }\n\n function isSymbol(propType, propValue) {\n // Native Symbol.\n if (propType === 'symbol') {\n return true;\n }\n\n // falsy value can't be a Symbol\n if (!propValue) {\n return false;\n }\n\n // 19.4.3.5 Symbol.prototype[@@toStringTag] === 'Symbol'\n if (propValue['@@toStringTag'] === 'Symbol') {\n return true;\n }\n\n // Fallback for non-spec compliant Symbols which are polyfilled.\n if (typeof Symbol === 'function' && propValue instanceof Symbol) {\n return true;\n }\n\n return false;\n }\n\n // Equivalent of `typeof` but with special handling for array and regexp.\n function getPropType(propValue) {\n var propType = typeof propValue;\n if (Array.isArray(propValue)) {\n return 'array';\n }\n if (propValue instanceof RegExp) {\n // Old webkits (at least until Android 4.0) return 'function' rather than\n // 'object' for typeof a RegExp. We'll normalize this here so that /bla/\n // passes PropTypes.object.\n return 'object';\n }\n if (isSymbol(propType, propValue)) {\n return 'symbol';\n }\n return propType;\n }\n\n // This handles more types than `getPropType`. Only used for error messages.\n // See `createPrimitiveTypeChecker`.\n function getPreciseType(propValue) {\n if (typeof propValue === 'undefined' || propValue === null) {\n return '' + propValue;\n }\n var propType = getPropType(propValue);\n if (propType === 'object') {\n if (propValue instanceof Date) {\n return 'date';\n } else if (propValue instanceof RegExp) {\n return 'regexp';\n }\n }\n return propType;\n }\n\n // Returns a string that is postfixed to a warning about an invalid type.\n // For example, \"undefined\" or \"of type array\"\n function getPostfixForTypeWarning(value) {\n var type = getPreciseType(value);\n switch (type) {\n case 'array':\n case 'object':\n return 'an ' + type;\n case 'boolean':\n case 'date':\n case 'regexp':\n return 'a ' + type;\n default:\n return type;\n }\n }\n\n // Returns class name of the object, if any.\n function getClassName(propValue) {\n if (!propValue.constructor || !propValue.constructor.name) {\n return ANONYMOUS;\n }\n return propValue.constructor.name;\n }\n\n ReactPropTypes.checkPropTypes = checkPropTypes;\n ReactPropTypes.resetWarningCache = checkPropTypes.resetWarningCache;\n ReactPropTypes.PropTypes = ReactPropTypes;\n\n return ReactPropTypes;\n};\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar ReactPropTypesSecret = require('./lib/ReactPropTypesSecret');\n\nfunction emptyFunction() {}\nfunction emptyFunctionWithReset() {}\nemptyFunctionWithReset.resetWarningCache = emptyFunction;\n\nmodule.exports = function() {\n function shim(props, propName, componentName, location, propFullName, secret) {\n if (secret === ReactPropTypesSecret) {\n // It is still safe when called from React.\n return;\n }\n var err = new Error(\n 'Calling PropTypes validators directly is not supported by the `prop-types` package. ' +\n 'Use PropTypes.checkPropTypes() to call them. ' +\n 'Read more at http://fb.me/use-check-prop-types'\n );\n err.name = 'Invariant Violation';\n throw err;\n };\n shim.isRequired = shim;\n function getShim() {\n return shim;\n };\n // Important!\n // Keep this list in sync with production version in `./factoryWithTypeCheckers.js`.\n var ReactPropTypes = {\n array: shim,\n bigint: shim,\n bool: shim,\n func: shim,\n number: shim,\n object: shim,\n string: shim,\n symbol: shim,\n\n any: shim,\n arrayOf: getShim,\n element: shim,\n elementType: shim,\n instanceOf: getShim,\n node: shim,\n objectOf: getShim,\n oneOf: getShim,\n oneOfType: getShim,\n shape: getShim,\n exact: getShim,\n\n checkPropTypes: emptyFunctionWithReset,\n resetWarningCache: emptyFunction\n };\n\n ReactPropTypes.PropTypes = ReactPropTypes;\n\n return ReactPropTypes;\n};\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\nif (process.env.NODE_ENV !== 'production') {\n var ReactIs = require('react-is');\n\n // By explicitly using `prop-types` you are opting into new development behavior.\n // http://fb.me/prop-types-in-prod\n var throwOnDirectAccess = true;\n module.exports = require('./factoryWithTypeCheckers')(ReactIs.isElement, throwOnDirectAccess);\n} else {\n // By explicitly using `prop-types` you are opting into new production behavior.\n // http://fb.me/prop-types-in-prod\n module.exports = require('./factoryWithThrowingShims')();\n}\n","import PropTypes from 'prop-types';\nimport chainPropTypes from '../chainPropTypes';\nfunction isClassComponent(elementType) {\n // elementType.prototype?.isReactComponent\n const {\n prototype = {}\n } = elementType;\n return Boolean(prototype.isReactComponent);\n}\nfunction acceptingRef(props, propName, componentName, location, propFullName) {\n const element = props[propName];\n const safePropName = propFullName || propName;\n if (element == null ||\n // When server-side rendering React doesn't warn either.\n // This is not an accurate check for SSR.\n // This is only in place for Emotion compat.\n // TODO: Revisit once https://github.com/facebook/react/issues/20047 is resolved.\n typeof window === 'undefined') {\n return null;\n }\n let warningHint;\n const elementType = element.type;\n /**\n * Blacklisting instead of whitelisting\n *\n * Blacklisting will miss some components, such as React.Fragment. Those will at least\n * trigger a warning in React.\n * We can't whitelist because there is no safe way to detect React.forwardRef\n * or class components. \"Safe\" means there's no public API.\n *\n */\n if (typeof elementType === 'function' && !isClassComponent(elementType)) {\n warningHint = 'Did you accidentally use a plain function component for an element instead?';\n }\n if (warningHint !== undefined) {\n return new Error(`Invalid ${location} \\`${safePropName}\\` supplied to \\`${componentName}\\`. ` + `Expected an element that can hold a ref. ${warningHint} ` + 'For more information see https://mui.com/r/caveat-with-refs-guide');\n }\n return null;\n}\nconst elementAcceptingRef = chainPropTypes(PropTypes.element, acceptingRef);\nelementAcceptingRef.isRequired = chainPropTypes(PropTypes.element.isRequired, acceptingRef);\nexport default elementAcceptingRef;","import _extends from \"@babel/runtime/helpers/esm/extends\";\n// This module is based on https://github.com/airbnb/prop-types-exact repository.\n// However, in order to reduce the number of dependencies and to remove some extra safe checks\n// the module was forked.\n\nconst specialProperty = 'exact-prop: \\u200b';\nexport default function exactProp(propTypes) {\n if (process.env.NODE_ENV === 'production') {\n return propTypes;\n }\n return _extends({}, propTypes, {\n [specialProperty]: props => {\n const unsupportedProps = Object.keys(props).filter(prop => !propTypes.hasOwnProperty(prop));\n if (unsupportedProps.length > 0) {\n return new Error(`The following props are not supported: ${unsupportedProps.map(prop => `\\`${prop}\\``).join(', ')}. Please remove them.`);\n }\n return null;\n }\n });\n}","/**\n * WARNING: Don't import this directly.\n * Use `MuiError` from `@mui/internal-babel-macros/MuiError.macro` instead.\n * @param {number} code\n */\nexport default function formatMuiErrorMessage(code) {\n // Apply babel-plugin-transform-template-literals in loose mode\n // loose mode is safe if we're concatenating primitives\n // see https://babeljs.io/docs/en/babel-plugin-transform-template-literals#loose\n /* eslint-disable prefer-template */\n let url = 'https://mui.com/production-error/?code=' + code;\n for (let i = 1; i < arguments.length; i += 1) {\n // rest params over-transpile for this case\n // eslint-disable-next-line prefer-rest-params\n url += '&args[]=' + encodeURIComponent(arguments[i]);\n }\n return 'Minified MUI error #' + code + '; visit ' + url + ' for the full message.';\n /* eslint-enable prefer-template */\n}","/**\n * @license React\n * react-is.production.min.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n'use strict';var b=Symbol.for(\"react.element\"),c=Symbol.for(\"react.portal\"),d=Symbol.for(\"react.fragment\"),e=Symbol.for(\"react.strict_mode\"),f=Symbol.for(\"react.profiler\"),g=Symbol.for(\"react.provider\"),h=Symbol.for(\"react.context\"),k=Symbol.for(\"react.server_context\"),l=Symbol.for(\"react.forward_ref\"),m=Symbol.for(\"react.suspense\"),n=Symbol.for(\"react.suspense_list\"),p=Symbol.for(\"react.memo\"),q=Symbol.for(\"react.lazy\"),t=Symbol.for(\"react.offscreen\"),u;u=Symbol.for(\"react.module.reference\");\nfunction v(a){if(\"object\"===typeof a&&null!==a){var r=a.$$typeof;switch(r){case b:switch(a=a.type,a){case d:case f:case e:case m:case n:return a;default:switch(a=a&&a.$$typeof,a){case k:case h:case l:case q:case p:case g:return a;default:return r}}case c:return r}}}exports.ContextConsumer=h;exports.ContextProvider=g;exports.Element=b;exports.ForwardRef=l;exports.Fragment=d;exports.Lazy=q;exports.Memo=p;exports.Portal=c;exports.Profiler=f;exports.StrictMode=e;exports.Suspense=m;\nexports.SuspenseList=n;exports.isAsyncMode=function(){return!1};exports.isConcurrentMode=function(){return!1};exports.isContextConsumer=function(a){return v(a)===h};exports.isContextProvider=function(a){return v(a)===g};exports.isElement=function(a){return\"object\"===typeof a&&null!==a&&a.$$typeof===b};exports.isForwardRef=function(a){return v(a)===l};exports.isFragment=function(a){return v(a)===d};exports.isLazy=function(a){return v(a)===q};exports.isMemo=function(a){return v(a)===p};\nexports.isPortal=function(a){return v(a)===c};exports.isProfiler=function(a){return v(a)===f};exports.isStrictMode=function(a){return v(a)===e};exports.isSuspense=function(a){return v(a)===m};exports.isSuspenseList=function(a){return v(a)===n};\nexports.isValidElementType=function(a){return\"string\"===typeof a||\"function\"===typeof a||a===d||a===f||a===e||a===m||a===n||a===t||\"object\"===typeof a&&null!==a&&(a.$$typeof===q||a.$$typeof===p||a.$$typeof===g||a.$$typeof===h||a.$$typeof===l||a.$$typeof===u||void 0!==a.getModuleId)?!0:!1};exports.typeOf=v;\n","/**\n * @license React\n * react-is.development.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nif (process.env.NODE_ENV !== \"production\") {\n (function() {\n'use strict';\n\n// ATTENTION\n// When adding new symbols to this file,\n// Please consider also adding to 'react-devtools-shared/src/backend/ReactSymbols'\n// The Symbol used to tag the ReactElement-like types.\nvar REACT_ELEMENT_TYPE = Symbol.for('react.element');\nvar REACT_PORTAL_TYPE = Symbol.for('react.portal');\nvar REACT_FRAGMENT_TYPE = Symbol.for('react.fragment');\nvar REACT_STRICT_MODE_TYPE = Symbol.for('react.strict_mode');\nvar REACT_PROFILER_TYPE = Symbol.for('react.profiler');\nvar REACT_PROVIDER_TYPE = Symbol.for('react.provider');\nvar REACT_CONTEXT_TYPE = Symbol.for('react.context');\nvar REACT_SERVER_CONTEXT_TYPE = Symbol.for('react.server_context');\nvar REACT_FORWARD_REF_TYPE = Symbol.for('react.forward_ref');\nvar REACT_SUSPENSE_TYPE = Symbol.for('react.suspense');\nvar REACT_SUSPENSE_LIST_TYPE = Symbol.for('react.suspense_list');\nvar REACT_MEMO_TYPE = Symbol.for('react.memo');\nvar REACT_LAZY_TYPE = Symbol.for('react.lazy');\nvar REACT_OFFSCREEN_TYPE = Symbol.for('react.offscreen');\n\n// -----------------------------------------------------------------------------\n\nvar enableScopeAPI = false; // Experimental Create Event Handle API.\nvar enableCacheElement = false;\nvar enableTransitionTracing = false; // No known bugs, but needs performance testing\n\nvar enableLegacyHidden = false; // Enables unstable_avoidThisFallback feature in Fiber\n// stuff. Intended to enable React core members to more easily debug scheduling\n// issues in DEV builds.\n\nvar enableDebugTracing = false; // Track which Fiber(s) schedule render work.\n\nvar REACT_MODULE_REFERENCE;\n\n{\n REACT_MODULE_REFERENCE = Symbol.for('react.module.reference');\n}\n\nfunction isValidElementType(type) {\n if (typeof type === 'string' || typeof type === 'function') {\n return true;\n } // Note: typeof might be other than 'symbol' or 'number' (e.g. if it's a polyfill).\n\n\n if (type === REACT_FRAGMENT_TYPE || type === REACT_PROFILER_TYPE || enableDebugTracing || type === REACT_STRICT_MODE_TYPE || type === REACT_SUSPENSE_TYPE || type === REACT_SUSPENSE_LIST_TYPE || enableLegacyHidden || type === REACT_OFFSCREEN_TYPE || enableScopeAPI || enableCacheElement || enableTransitionTracing ) {\n return true;\n }\n\n if (typeof type === 'object' && type !== null) {\n if (type.$$typeof === REACT_LAZY_TYPE || type.$$typeof === REACT_MEMO_TYPE || type.$$typeof === REACT_PROVIDER_TYPE || type.$$typeof === REACT_CONTEXT_TYPE || type.$$typeof === REACT_FORWARD_REF_TYPE || // This needs to include all possible module reference object\n // types supported by any Flight configuration anywhere since\n // we don't know which Flight build this will end up being used\n // with.\n type.$$typeof === REACT_MODULE_REFERENCE || type.getModuleId !== undefined) {\n return true;\n }\n }\n\n return false;\n}\n\nfunction typeOf(object) {\n if (typeof object === 'object' && object !== null) {\n var $$typeof = object.$$typeof;\n\n switch ($$typeof) {\n case REACT_ELEMENT_TYPE:\n var type = object.type;\n\n switch (type) {\n case REACT_FRAGMENT_TYPE:\n case REACT_PROFILER_TYPE:\n case REACT_STRICT_MODE_TYPE:\n case REACT_SUSPENSE_TYPE:\n case REACT_SUSPENSE_LIST_TYPE:\n return type;\n\n default:\n var $$typeofType = type && type.$$typeof;\n\n switch ($$typeofType) {\n case REACT_SERVER_CONTEXT_TYPE:\n case REACT_CONTEXT_TYPE:\n case REACT_FORWARD_REF_TYPE:\n case REACT_LAZY_TYPE:\n case REACT_MEMO_TYPE:\n case REACT_PROVIDER_TYPE:\n return $$typeofType;\n\n default:\n return $$typeof;\n }\n\n }\n\n case REACT_PORTAL_TYPE:\n return $$typeof;\n }\n }\n\n return undefined;\n}\nvar ContextConsumer = REACT_CONTEXT_TYPE;\nvar ContextProvider = REACT_PROVIDER_TYPE;\nvar Element = REACT_ELEMENT_TYPE;\nvar ForwardRef = REACT_FORWARD_REF_TYPE;\nvar Fragment = REACT_FRAGMENT_TYPE;\nvar Lazy = REACT_LAZY_TYPE;\nvar Memo = REACT_MEMO_TYPE;\nvar Portal = REACT_PORTAL_TYPE;\nvar Profiler = REACT_PROFILER_TYPE;\nvar StrictMode = REACT_STRICT_MODE_TYPE;\nvar Suspense = REACT_SUSPENSE_TYPE;\nvar SuspenseList = REACT_SUSPENSE_LIST_TYPE;\nvar hasWarnedAboutDeprecatedIsAsyncMode = false;\nvar hasWarnedAboutDeprecatedIsConcurrentMode = false; // AsyncMode should be deprecated\n\nfunction isAsyncMode(object) {\n {\n if (!hasWarnedAboutDeprecatedIsAsyncMode) {\n hasWarnedAboutDeprecatedIsAsyncMode = true; // Using console['warn'] to evade Babel and ESLint\n\n console['warn']('The ReactIs.isAsyncMode() alias has been deprecated, ' + 'and will be removed in React 18+.');\n }\n }\n\n return false;\n}\nfunction isConcurrentMode(object) {\n {\n if (!hasWarnedAboutDeprecatedIsConcurrentMode) {\n hasWarnedAboutDeprecatedIsConcurrentMode = true; // Using console['warn'] to evade Babel and ESLint\n\n console['warn']('The ReactIs.isConcurrentMode() alias has been deprecated, ' + 'and will be removed in React 18+.');\n }\n }\n\n return false;\n}\nfunction isContextConsumer(object) {\n return typeOf(object) === REACT_CONTEXT_TYPE;\n}\nfunction isContextProvider(object) {\n return typeOf(object) === REACT_PROVIDER_TYPE;\n}\nfunction isElement(object) {\n return typeof object === 'object' && object !== null && object.$$typeof === REACT_ELEMENT_TYPE;\n}\nfunction isForwardRef(object) {\n return typeOf(object) === REACT_FORWARD_REF_TYPE;\n}\nfunction isFragment(object) {\n return typeOf(object) === REACT_FRAGMENT_TYPE;\n}\nfunction isLazy(object) {\n return typeOf(object) === REACT_LAZY_TYPE;\n}\nfunction isMemo(object) {\n return typeOf(object) === REACT_MEMO_TYPE;\n}\nfunction isPortal(object) {\n return typeOf(object) === REACT_PORTAL_TYPE;\n}\nfunction isProfiler(object) {\n return typeOf(object) === REACT_PROFILER_TYPE;\n}\nfunction isStrictMode(object) {\n return typeOf(object) === REACT_STRICT_MODE_TYPE;\n}\nfunction isSuspense(object) {\n return typeOf(object) === REACT_SUSPENSE_TYPE;\n}\nfunction isSuspenseList(object) {\n return typeOf(object) === REACT_SUSPENSE_LIST_TYPE;\n}\n\nexports.ContextConsumer = ContextConsumer;\nexports.ContextProvider = ContextProvider;\nexports.Element = Element;\nexports.ForwardRef = ForwardRef;\nexports.Fragment = Fragment;\nexports.Lazy = Lazy;\nexports.Memo = Memo;\nexports.Portal = Portal;\nexports.Profiler = Profiler;\nexports.StrictMode = StrictMode;\nexports.Suspense = Suspense;\nexports.SuspenseList = SuspenseList;\nexports.isAsyncMode = isAsyncMode;\nexports.isConcurrentMode = isConcurrentMode;\nexports.isContextConsumer = isContextConsumer;\nexports.isContextProvider = isContextProvider;\nexports.isElement = isElement;\nexports.isForwardRef = isForwardRef;\nexports.isFragment = isFragment;\nexports.isLazy = isLazy;\nexports.isMemo = isMemo;\nexports.isPortal = isPortal;\nexports.isProfiler = isProfiler;\nexports.isStrictMode = isStrictMode;\nexports.isSuspense = isSuspense;\nexports.isSuspenseList = isSuspenseList;\nexports.isValidElementType = isValidElementType;\nexports.typeOf = typeOf;\n })();\n}\n","'use strict';\n\nif (process.env.NODE_ENV === 'production') {\n module.exports = require('./cjs/react-is.production.min.js');\n} else {\n module.exports = require('./cjs/react-is.development.js');\n}\n","import { ForwardRef, Memo } from 'react-is';\n\n// Simplified polyfill for IE11 support\n// https://github.com/JamesMGreene/Function.name/blob/58b314d4a983110c3682f1228f845d39ccca1817/Function.name.js#L3\nconst fnNameMatchRegex = /^\\s*function(?:\\s|\\s*\\/\\*.*\\*\\/\\s*)+([^(\\s/]*)\\s*/;\nexport function getFunctionName(fn) {\n const match = `${fn}`.match(fnNameMatchRegex);\n const name = match && match[1];\n return name || '';\n}\nfunction getFunctionComponentName(Component, fallback = '') {\n return Component.displayName || Component.name || getFunctionName(Component) || fallback;\n}\nfunction getWrappedName(outerType, innerType, wrapperName) {\n const functionName = getFunctionComponentName(innerType);\n return outerType.displayName || (functionName !== '' ? `${wrapperName}(${functionName})` : wrapperName);\n}\n\n/**\n * cherry-pick from\n * https://github.com/facebook/react/blob/769b1f270e1251d9dbdce0fcbd9e92e502d059b8/packages/shared/getComponentName.js\n * originally forked from recompose/getDisplayName with added IE11 support\n */\nexport default function getDisplayName(Component) {\n if (Component == null) {\n return undefined;\n }\n if (typeof Component === 'string') {\n return Component;\n }\n if (typeof Component === 'function') {\n return getFunctionComponentName(Component, 'Component');\n }\n\n // TypeScript can't have components as objects but they exist in the form of `memo` or `Suspense`\n if (typeof Component === 'object') {\n switch (Component.$$typeof) {\n case ForwardRef:\n return getWrappedName(Component, Component.render, 'ForwardRef');\n case Memo:\n return getWrappedName(Component, Component.type, 'memo');\n default:\n return undefined;\n }\n }\n return undefined;\n}","export default function HTMLElementType(props, propName, componentName, location, propFullName) {\n if (process.env.NODE_ENV === 'production') {\n return null;\n }\n const propValue = props[propName];\n const safePropName = propFullName || propName;\n if (propValue == null) {\n return null;\n }\n if (propValue && propValue.nodeType !== 1) {\n return new Error(`Invalid ${location} \\`${safePropName}\\` supplied to \\`${componentName}\\`. ` + `Expected an HTMLElement.`);\n }\n return null;\n}","import PropTypes from 'prop-types';\nconst refType = PropTypes.oneOfType([PropTypes.func, PropTypes.object]);\nexport default refType;","import _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\n// It should to be noted that this function isn't equivalent to `text-transform: capitalize`.\n//\n// A strict capitalization should uppercase the first letter of each word in the sentence.\n// We only handle the first word.\nexport default function capitalize(string) {\n if (typeof string !== 'string') {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: \\`capitalize(string)\\` expects a string argument.` : _formatMuiErrorMessage(7));\n }\n return string.charAt(0).toUpperCase() + string.slice(1);\n}","/**\n * Safe chained function.\n *\n * Will only create a new function if needed,\n * otherwise will pass back existing functions or null.\n */\nexport default function createChainedFunction(...funcs) {\n return funcs.reduce((acc, func) => {\n if (func == null) {\n return acc;\n }\n return function chainedFunction(...args) {\n acc.apply(this, args);\n func.apply(this, args);\n };\n }, () => {});\n}","// Corresponds to 10 frames at 60 Hz.\n// A few bytes payload overhead when lodash/debounce is ~3 kB and debounce ~300 B.\nexport default function debounce(func, wait = 166) {\n let timeout;\n function debounced(...args) {\n const later = () => {\n // @ts-ignore\n func.apply(this, args);\n };\n clearTimeout(timeout);\n timeout = setTimeout(later, wait);\n }\n debounced.clear = () => {\n clearTimeout(timeout);\n };\n return debounced;\n}","export default function deprecatedPropType(validator, reason) {\n if (process.env.NODE_ENV === 'production') {\n return () => null;\n }\n return (props, propName, componentName, location, propFullName) => {\n const componentNameSafe = componentName || '<>';\n const propFullNameSafe = propFullName || propName;\n if (typeof props[propName] !== 'undefined') {\n return new Error(`The ${location} \\`${propFullNameSafe}\\` of ` + `\\`${componentNameSafe}\\` is deprecated. ${reason}`);\n }\n return null;\n };\n}","import * as React from 'react';\nexport default function isMuiElement(element, muiNames) {\n var _muiName, _element$type;\n return /*#__PURE__*/React.isValidElement(element) && muiNames.indexOf( // For server components `muiName` is avaialble in element.type._payload.value.muiName\n // relevant info - https://github.com/facebook/react/blob/2807d781a08db8e9873687fccc25c0f12b4fb3d4/packages/react/src/ReactLazy.js#L45\n // eslint-disable-next-line no-underscore-dangle\n (_muiName = element.type.muiName) != null ? _muiName : (_element$type = element.type) == null || (_element$type = _element$type._payload) == null || (_element$type = _element$type.value) == null ? void 0 : _element$type.muiName) !== -1;\n}","export default function ownerDocument(node) {\n return node && node.ownerDocument || document;\n}","import ownerDocument from '../ownerDocument';\nexport default function ownerWindow(node) {\n const doc = ownerDocument(node);\n return doc.defaultView || window;\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nexport default function requirePropFactory(componentNameInError, Component) {\n if (process.env.NODE_ENV === 'production') {\n return () => null;\n }\n\n // eslint-disable-next-line react/forbid-foreign-prop-types\n const prevPropTypes = Component ? _extends({}, Component.propTypes) : null;\n const requireProp = requiredProp => (props, propName, componentName, location, propFullName, ...args) => {\n const propFullNameSafe = propFullName || propName;\n const defaultTypeChecker = prevPropTypes == null ? void 0 : prevPropTypes[propFullNameSafe];\n if (defaultTypeChecker) {\n const typeCheckerResult = defaultTypeChecker(props, propName, componentName, location, propFullName, ...args);\n if (typeCheckerResult) {\n return typeCheckerResult;\n }\n }\n if (typeof props[propName] !== 'undefined' && !props[requiredProp]) {\n return new Error(`The prop \\`${propFullNameSafe}\\` of ` + `\\`${componentNameInError}\\` can only be used together with the \\`${requiredProp}\\` prop.`);\n }\n return null;\n };\n return requireProp;\n}","/**\n * TODO v5: consider making it private\n *\n * passes {value} to {ref}\n *\n * WARNING: Be sure to only call this inside a callback that is passed as a ref.\n * Otherwise, make sure to cleanup the previous {ref} if it changes. See\n * https://github.com/mui/material-ui/issues/13539\n *\n * Useful if you want to expose the ref of an inner component to the public API\n * while still using it inside the component.\n * @param ref A ref callback or ref object. If anything falsy, this is a no-op.\n */\nexport default function setRef(ref, value) {\n if (typeof ref === 'function') {\n ref(value);\n } else if (ref) {\n ref.current = value;\n }\n}","'use client';\n\nimport * as React from 'react';\n\n/**\n * A version of `React.useLayoutEffect` that does not show a warning when server-side rendering.\n * This is useful for effects that are only needed for client-side rendering but not for SSR.\n *\n * Before you use this hook, make sure to read https://gist.github.com/gaearon/e7d97cdf38a2907924ea12e4ebdf3c85\n * and confirm it doesn't apply to your use-case.\n */\nconst useEnhancedEffect = typeof window !== 'undefined' ? React.useLayoutEffect : React.useEffect;\nexport default useEnhancedEffect;","'use client';\n\nimport * as React from 'react';\nlet globalId = 0;\nfunction useGlobalId(idOverride) {\n const [defaultId, setDefaultId] = React.useState(idOverride);\n const id = idOverride || defaultId;\n React.useEffect(() => {\n if (defaultId == null) {\n // Fallback to this default id when possible.\n // Use the incrementing value for client-side rendering only.\n // We can't use it server-side.\n // If you want to use random values please consider the Birthday Problem: https://en.wikipedia.org/wiki/Birthday_problem\n globalId += 1;\n setDefaultId(`mui-${globalId}`);\n }\n }, [defaultId]);\n return id;\n}\n\n// downstream bundlers may remove unnecessary concatenation, but won't remove toString call -- Workaround for https://github.com/webpack/webpack/issues/14814\nconst maybeReactUseId = React['useId'.toString()];\n/**\n *\n * @example
    \n * @param idOverride\n * @returns {string}\n */\nexport default function useId(idOverride) {\n if (maybeReactUseId !== undefined) {\n const reactId = maybeReactUseId();\n return idOverride != null ? idOverride : reactId;\n }\n // eslint-disable-next-line react-hooks/rules-of-hooks -- `React.useId` is invariant at runtime.\n return useGlobalId(idOverride);\n}","export default function unsupportedProp(props, propName, componentName, location, propFullName) {\n if (process.env.NODE_ENV === 'production') {\n return null;\n }\n const propFullNameSafe = propFullName || propName;\n if (typeof props[propName] !== 'undefined') {\n return new Error(`The prop \\`${propFullNameSafe}\\` is not supported. Please remove it.`);\n }\n return null;\n}","'use client';\n\n/* eslint-disable react-hooks/rules-of-hooks, react-hooks/exhaustive-deps */\nimport * as React from 'react';\nexport default function useControlled({\n controlled,\n default: defaultProp,\n name,\n state = 'value'\n}) {\n // isControlled is ignored in the hook dependency lists as it should never change.\n const {\n current: isControlled\n } = React.useRef(controlled !== undefined);\n const [valueState, setValue] = React.useState(defaultProp);\n const value = isControlled ? controlled : valueState;\n if (process.env.NODE_ENV !== 'production') {\n React.useEffect(() => {\n if (isControlled !== (controlled !== undefined)) {\n console.error([`MUI: A component is changing the ${isControlled ? '' : 'un'}controlled ${state} state of ${name} to be ${isControlled ? 'un' : ''}controlled.`, 'Elements should not switch from uncontrolled to controlled (or vice versa).', `Decide between using a controlled or uncontrolled ${name} ` + 'element for the lifetime of the component.', \"The nature of the state is determined during the first render. It's considered controlled if the value is not `undefined`.\", 'More info: https://fb.me/react-controlled-components'].join('\\n'));\n }\n }, [state, name, controlled]);\n const {\n current: defaultValue\n } = React.useRef(defaultProp);\n React.useEffect(() => {\n if (!isControlled && defaultValue !== defaultProp) {\n console.error([`MUI: A component is changing the default ${state} state of an uncontrolled ${name} after being initialized. ` + `To suppress this warning opt to use a controlled ${name}.`].join('\\n'));\n }\n }, [JSON.stringify(defaultProp)]);\n }\n const setValueIfUncontrolled = React.useCallback(newValue => {\n if (!isControlled) {\n setValue(newValue);\n }\n }, []);\n return [value, setValueIfUncontrolled];\n}","'use client';\n\nimport * as React from 'react';\nimport useEnhancedEffect from '../useEnhancedEffect';\n\n/**\n * Inspired by https://github.com/facebook/react/issues/14099#issuecomment-440013892\n * See RFC in https://github.com/reactjs/rfcs/pull/220\n */\n\nfunction useEventCallback(fn) {\n const ref = React.useRef(fn);\n useEnhancedEffect(() => {\n ref.current = fn;\n });\n return React.useRef((...args) =>\n // @ts-expect-error hide `this`\n (0, ref.current)(...args)).current;\n}\nexport default useEventCallback;","'use client';\n\nimport * as React from 'react';\nimport setRef from '../setRef';\nexport default function useForkRef(...refs) {\n /**\n * This will create a new function if the refs passed to this hook change and are all defined.\n * This means react will call the old forkRef with `null` and the new forkRef\n * with the ref. Cleanup naturally emerges from this behavior.\n */\n return React.useMemo(() => {\n if (refs.every(ref => ref == null)) {\n return null;\n }\n return instance => {\n refs.forEach(ref => {\n setRef(ref, instance);\n });\n };\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, refs);\n}","'use client';\n\nimport * as React from 'react';\nconst UNINITIALIZED = {};\n\n/**\n * A React.useRef() that is initialized lazily with a function. Note that it accepts an optional\n * initialization argument, so the initialization function doesn't need to be an inline closure.\n *\n * @usage\n * const ref = useLazyRef(sortColumns, columns)\n */\nexport default function useLazyRef(init, initArg) {\n const ref = React.useRef(UNINITIALIZED);\n if (ref.current === UNINITIALIZED) {\n ref.current = init(initArg);\n }\n return ref;\n}","'use client';\n\nimport * as React from 'react';\nconst EMPTY = [];\n\n/**\n * A React.useEffect equivalent that runs once, when the component is mounted.\n */\nexport default function useOnMount(fn) {\n /* eslint-disable react-hooks/exhaustive-deps */\n React.useEffect(fn, EMPTY);\n /* eslint-enable react-hooks/exhaustive-deps */\n}","'use client';\n\nimport useLazyRef from '../useLazyRef/useLazyRef';\nimport useOnMount from '../useOnMount/useOnMount';\nexport class Timeout {\n constructor() {\n this.currentId = null;\n this.clear = () => {\n if (this.currentId !== null) {\n clearTimeout(this.currentId);\n this.currentId = null;\n }\n };\n this.disposeEffect = () => {\n return this.clear;\n };\n }\n static create() {\n return new Timeout();\n }\n /**\n * Executes `fn` after `delay`, clearing any previously scheduled call.\n */\n start(delay, fn) {\n this.clear();\n this.currentId = setTimeout(() => {\n this.currentId = null;\n fn();\n }, delay);\n }\n}\nexport default function useTimeout() {\n const timeout = useLazyRef(Timeout.create).current;\n useOnMount(timeout.disposeEffect);\n return timeout;\n}","'use client';\n\n// based on https://github.com/WICG/focus-visible/blob/v4.1.5/src/focus-visible.js\nimport * as React from 'react';\nimport { Timeout } from '../useTimeout/useTimeout';\nlet hadKeyboardEvent = true;\nlet hadFocusVisibleRecently = false;\nconst hadFocusVisibleRecentlyTimeout = new Timeout();\nconst inputTypesWhitelist = {\n text: true,\n search: true,\n url: true,\n tel: true,\n email: true,\n password: true,\n number: true,\n date: true,\n month: true,\n week: true,\n time: true,\n datetime: true,\n 'datetime-local': true\n};\n\n/**\n * Computes whether the given element should automatically trigger the\n * `focus-visible` class being added, i.e. whether it should always match\n * `:focus-visible` when focused.\n * @param {Element} node\n * @returns {boolean}\n */\nfunction focusTriggersKeyboardModality(node) {\n const {\n type,\n tagName\n } = node;\n if (tagName === 'INPUT' && inputTypesWhitelist[type] && !node.readOnly) {\n return true;\n }\n if (tagName === 'TEXTAREA' && !node.readOnly) {\n return true;\n }\n if (node.isContentEditable) {\n return true;\n }\n return false;\n}\n\n/**\n * Keep track of our keyboard modality state with `hadKeyboardEvent`.\n * If the most recent user interaction was via the keyboard;\n * and the key press did not include a meta, alt/option, or control key;\n * then the modality is keyboard. Otherwise, the modality is not keyboard.\n * @param {KeyboardEvent} event\n */\nfunction handleKeyDown(event) {\n if (event.metaKey || event.altKey || event.ctrlKey) {\n return;\n }\n hadKeyboardEvent = true;\n}\n\n/**\n * If at any point a user clicks with a pointing device, ensure that we change\n * the modality away from keyboard.\n * This avoids the situation where a user presses a key on an already focused\n * element, and then clicks on a different element, focusing it with a\n * pointing device, while we still think we're in keyboard modality.\n */\nfunction handlePointerDown() {\n hadKeyboardEvent = false;\n}\nfunction handleVisibilityChange() {\n if (this.visibilityState === 'hidden') {\n // If the tab becomes active again, the browser will handle calling focus\n // on the element (Safari actually calls it twice).\n // If this tab change caused a blur on an element with focus-visible,\n // re-apply the class when the user switches back to the tab.\n if (hadFocusVisibleRecently) {\n hadKeyboardEvent = true;\n }\n }\n}\nfunction prepare(doc) {\n doc.addEventListener('keydown', handleKeyDown, true);\n doc.addEventListener('mousedown', handlePointerDown, true);\n doc.addEventListener('pointerdown', handlePointerDown, true);\n doc.addEventListener('touchstart', handlePointerDown, true);\n doc.addEventListener('visibilitychange', handleVisibilityChange, true);\n}\nexport function teardown(doc) {\n doc.removeEventListener('keydown', handleKeyDown, true);\n doc.removeEventListener('mousedown', handlePointerDown, true);\n doc.removeEventListener('pointerdown', handlePointerDown, true);\n doc.removeEventListener('touchstart', handlePointerDown, true);\n doc.removeEventListener('visibilitychange', handleVisibilityChange, true);\n}\nfunction isFocusVisible(event) {\n const {\n target\n } = event;\n try {\n return target.matches(':focus-visible');\n } catch (error) {\n // Browsers not implementing :focus-visible will throw a SyntaxError.\n // We use our own heuristic for those browsers.\n // Rethrow might be better if it's not the expected error but do we really\n // want to crash if focus-visible malfunctioned?\n }\n\n // No need for validFocusTarget check. The user does that by attaching it to\n // focusable events only.\n return hadKeyboardEvent || focusTriggersKeyboardModality(target);\n}\nexport default function useIsFocusVisible() {\n const ref = React.useCallback(node => {\n if (node != null) {\n prepare(node.ownerDocument);\n }\n }, []);\n const isFocusVisibleRef = React.useRef(false);\n\n /**\n * Should be called if a blur event is fired\n */\n function handleBlurVisible() {\n // checking against potential state variable does not suffice if we focus and blur synchronously.\n // React wouldn't have time to trigger a re-render so `focusVisible` would be stale.\n // Ideally we would adjust `isFocusVisible(event)` to look at `relatedTarget` for blur events.\n // This doesn't work in IE11 due to https://github.com/facebook/react/issues/3751\n // TODO: check again if React releases their internal changes to focus event handling (https://github.com/facebook/react/pull/19186).\n if (isFocusVisibleRef.current) {\n // To detect a tab/window switch, we look for a blur event followed\n // rapidly by a visibility change.\n // If we don't see a visibility change within 100ms, it's probably a\n // regular focus change.\n hadFocusVisibleRecently = true;\n hadFocusVisibleRecentlyTimeout.start(100, () => {\n hadFocusVisibleRecently = false;\n });\n isFocusVisibleRef.current = false;\n return true;\n }\n return false;\n }\n\n /**\n * Should be called if a blur event is fired\n */\n function handleFocusVisible(event) {\n if (isFocusVisible(event)) {\n isFocusVisibleRef.current = true;\n return true;\n }\n return false;\n }\n return {\n isFocusVisibleRef,\n onFocus: handleFocusVisible,\n onBlur: handleBlurVisible,\n ref\n };\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\n/**\n * Add keys, values of `defaultProps` that does not exist in `props`\n * @param {object} defaultProps\n * @param {object} props\n * @returns {object} resolved props\n */\nexport default function resolveProps(defaultProps, props) {\n const output = _extends({}, props);\n Object.keys(defaultProps).forEach(propName => {\n if (propName.toString().match(/^(components|slots)$/)) {\n output[propName] = _extends({}, defaultProps[propName], output[propName]);\n } else if (propName.toString().match(/^(componentsProps|slotProps)$/)) {\n const defaultSlotProps = defaultProps[propName] || {};\n const slotProps = props[propName];\n output[propName] = {};\n if (!slotProps || !Object.keys(slotProps)) {\n // Reduce the iteration if the slot props is empty\n output[propName] = defaultSlotProps;\n } else if (!defaultSlotProps || !Object.keys(defaultSlotProps)) {\n // Reduce the iteration if the default slot props is empty\n output[propName] = slotProps;\n } else {\n output[propName] = _extends({}, slotProps);\n Object.keys(defaultSlotProps).forEach(slotPropName => {\n output[propName][slotPropName] = resolveProps(defaultSlotProps[slotPropName], slotProps[slotPropName]);\n });\n }\n } else if (output[propName] === undefined) {\n output[propName] = defaultProps[propName];\n }\n });\n return output;\n}","export default function composeClasses(slots, getUtilityClass, classes = undefined) {\n const output = {};\n Object.keys(slots).forEach(\n // `Object.keys(slots)` can't be wider than `T` because we infer `T` from `slots`.\n // @ts-expect-error https://github.com/microsoft/TypeScript/pull/12253#issuecomment-263132208\n slot => {\n output[slot] = slots[slot].reduce((acc, key) => {\n if (key) {\n const utilityClass = getUtilityClass(key);\n if (utilityClass !== '') {\n acc.push(utilityClass);\n }\n if (classes && classes[key]) {\n acc.push(classes[key]);\n }\n }\n return acc;\n }, []).join(' ');\n });\n return output;\n}","const defaultGenerator = componentName => componentName;\nconst createClassNameGenerator = () => {\n let generate = defaultGenerator;\n return {\n configure(generator) {\n generate = generator;\n },\n generate(componentName) {\n return generate(componentName);\n },\n reset() {\n generate = defaultGenerator;\n }\n };\n};\nconst ClassNameGenerator = createClassNameGenerator();\nexport default ClassNameGenerator;","import ClassNameGenerator from '../ClassNameGenerator';\nexport const globalStateClasses = {\n active: 'active',\n checked: 'checked',\n completed: 'completed',\n disabled: 'disabled',\n error: 'error',\n expanded: 'expanded',\n focused: 'focused',\n focusVisible: 'focusVisible',\n open: 'open',\n readOnly: 'readOnly',\n required: 'required',\n selected: 'selected'\n};\nexport default function generateUtilityClass(componentName, slot, globalStatePrefix = 'Mui') {\n const globalStateClass = globalStateClasses[slot];\n return globalStateClass ? `${globalStatePrefix}-${globalStateClass}` : `${ClassNameGenerator.generate(componentName)}-${slot}`;\n}\nexport function isGlobalState(slot) {\n return globalStateClasses[slot] !== undefined;\n}","import generateUtilityClass from '../generateUtilityClass';\nexport default function generateUtilityClasses(componentName, slots, globalStatePrefix = 'Mui') {\n const result = {};\n slots.forEach(slot => {\n result[slot] = generateUtilityClass(componentName, slot, globalStatePrefix);\n });\n return result;\n}","function clamp(val, min = Number.MIN_SAFE_INTEGER, max = Number.MAX_SAFE_INTEGER) {\n return Math.max(min, Math.min(val, max));\n}\nexport default clamp;","export default function _objectWithoutPropertiesLoose(source, excluded) {\n if (source == null) return {};\n var target = {};\n var sourceKeys = Object.keys(source);\n var key, i;\n for (i = 0; i < sourceKeys.length; i++) {\n key = sourceKeys[i];\n if (excluded.indexOf(key) >= 0) continue;\n target[key] = source[key];\n }\n return target;\n}","import _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nconst _excluded = [\"values\", \"unit\", \"step\"];\n// Sorted ASC by size. That's important.\n// It can't be configured as it's used statically for propTypes.\nexport const breakpointKeys = ['xs', 'sm', 'md', 'lg', 'xl'];\nconst sortBreakpointsValues = values => {\n const breakpointsAsArray = Object.keys(values).map(key => ({\n key,\n val: values[key]\n })) || [];\n // Sort in ascending order\n breakpointsAsArray.sort((breakpoint1, breakpoint2) => breakpoint1.val - breakpoint2.val);\n return breakpointsAsArray.reduce((acc, obj) => {\n return _extends({}, acc, {\n [obj.key]: obj.val\n });\n }, {});\n};\n\n// Keep in mind that @media is inclusive by the CSS specification.\nexport default function createBreakpoints(breakpoints) {\n const {\n // The breakpoint **start** at this value.\n // For instance with the first breakpoint xs: [xs, sm).\n values = {\n xs: 0,\n // phone\n sm: 600,\n // tablet\n md: 900,\n // small laptop\n lg: 1200,\n // desktop\n xl: 1536 // large screen\n },\n unit = 'px',\n step = 5\n } = breakpoints,\n other = _objectWithoutPropertiesLoose(breakpoints, _excluded);\n const sortedValues = sortBreakpointsValues(values);\n const keys = Object.keys(sortedValues);\n function up(key) {\n const value = typeof values[key] === 'number' ? values[key] : key;\n return `@media (min-width:${value}${unit})`;\n }\n function down(key) {\n const value = typeof values[key] === 'number' ? values[key] : key;\n return `@media (max-width:${value - step / 100}${unit})`;\n }\n function between(start, end) {\n const endIndex = keys.indexOf(end);\n return `@media (min-width:${typeof values[start] === 'number' ? values[start] : start}${unit}) and ` + `(max-width:${(endIndex !== -1 && typeof values[keys[endIndex]] === 'number' ? values[keys[endIndex]] : end) - step / 100}${unit})`;\n }\n function only(key) {\n if (keys.indexOf(key) + 1 < keys.length) {\n return between(key, keys[keys.indexOf(key) + 1]);\n }\n return up(key);\n }\n function not(key) {\n // handle first and last key separately, for better readability\n const keyIndex = keys.indexOf(key);\n if (keyIndex === 0) {\n return up(keys[1]);\n }\n if (keyIndex === keys.length - 1) {\n return down(keys[keyIndex]);\n }\n return between(key, keys[keys.indexOf(key) + 1]).replace('@media', '@media not all and');\n }\n return _extends({\n keys,\n values: sortedValues,\n up,\n down,\n between,\n only,\n not,\n unit\n }, other);\n}","const shape = {\n borderRadius: 4\n};\nexport default shape;","import PropTypes from 'prop-types';\nconst responsivePropType = process.env.NODE_ENV !== 'production' ? PropTypes.oneOfType([PropTypes.number, PropTypes.string, PropTypes.object, PropTypes.array]) : {};\nexport default responsivePropType;","import deepmerge from '@mui/utils/deepmerge';\nfunction merge(acc, item) {\n if (!item) {\n return acc;\n }\n return deepmerge(acc, item, {\n clone: false // No need to clone deep, it's way faster.\n });\n}\nexport default merge;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport PropTypes from 'prop-types';\nimport deepmerge from '@mui/utils/deepmerge';\nimport merge from './merge';\n\n// The breakpoint **start** at this value.\n// For instance with the first breakpoint xs: [xs, sm[.\nexport const values = {\n xs: 0,\n // phone\n sm: 600,\n // tablet\n md: 900,\n // small laptop\n lg: 1200,\n // desktop\n xl: 1536 // large screen\n};\nconst defaultBreakpoints = {\n // Sorted ASC by size. That's important.\n // It can't be configured as it's used statically for propTypes.\n keys: ['xs', 'sm', 'md', 'lg', 'xl'],\n up: key => `@media (min-width:${values[key]}px)`\n};\nexport function handleBreakpoints(props, propValue, styleFromPropValue) {\n const theme = props.theme || {};\n if (Array.isArray(propValue)) {\n const themeBreakpoints = theme.breakpoints || defaultBreakpoints;\n return propValue.reduce((acc, item, index) => {\n acc[themeBreakpoints.up(themeBreakpoints.keys[index])] = styleFromPropValue(propValue[index]);\n return acc;\n }, {});\n }\n if (typeof propValue === 'object') {\n const themeBreakpoints = theme.breakpoints || defaultBreakpoints;\n return Object.keys(propValue).reduce((acc, breakpoint) => {\n // key is breakpoint\n if (Object.keys(themeBreakpoints.values || values).indexOf(breakpoint) !== -1) {\n const mediaKey = themeBreakpoints.up(breakpoint);\n acc[mediaKey] = styleFromPropValue(propValue[breakpoint], breakpoint);\n } else {\n const cssKey = breakpoint;\n acc[cssKey] = propValue[cssKey];\n }\n return acc;\n }, {});\n }\n const output = styleFromPropValue(propValue);\n return output;\n}\nfunction breakpoints(styleFunction) {\n // false positive\n // eslint-disable-next-line react/function-component-definition\n const newStyleFunction = props => {\n const theme = props.theme || {};\n const base = styleFunction(props);\n const themeBreakpoints = theme.breakpoints || defaultBreakpoints;\n const extended = themeBreakpoints.keys.reduce((acc, key) => {\n if (props[key]) {\n acc = acc || {};\n acc[themeBreakpoints.up(key)] = styleFunction(_extends({\n theme\n }, props[key]));\n }\n return acc;\n }, null);\n return merge(base, extended);\n };\n newStyleFunction.propTypes = process.env.NODE_ENV !== 'production' ? _extends({}, styleFunction.propTypes, {\n xs: PropTypes.object,\n sm: PropTypes.object,\n md: PropTypes.object,\n lg: PropTypes.object,\n xl: PropTypes.object\n }) : {};\n newStyleFunction.filterProps = ['xs', 'sm', 'md', 'lg', 'xl', ...styleFunction.filterProps];\n return newStyleFunction;\n}\nexport function createEmptyBreakpointObject(breakpointsInput = {}) {\n var _breakpointsInput$key;\n const breakpointsInOrder = (_breakpointsInput$key = breakpointsInput.keys) == null ? void 0 : _breakpointsInput$key.reduce((acc, key) => {\n const breakpointStyleKey = breakpointsInput.up(key);\n acc[breakpointStyleKey] = {};\n return acc;\n }, {});\n return breakpointsInOrder || {};\n}\nexport function removeUnusedBreakpoints(breakpointKeys, style) {\n return breakpointKeys.reduce((acc, key) => {\n const breakpointOutput = acc[key];\n const isBreakpointUnused = !breakpointOutput || Object.keys(breakpointOutput).length === 0;\n if (isBreakpointUnused) {\n delete acc[key];\n }\n return acc;\n }, style);\n}\nexport function mergeBreakpointsInOrder(breakpointsInput, ...styles) {\n const emptyBreakpoints = createEmptyBreakpointObject(breakpointsInput);\n const mergedOutput = [emptyBreakpoints, ...styles].reduce((prev, next) => deepmerge(prev, next), {});\n return removeUnusedBreakpoints(Object.keys(emptyBreakpoints), mergedOutput);\n}\n\n// compute base for responsive values; e.g.,\n// [1,2,3] => {xs: true, sm: true, md: true}\n// {xs: 1, sm: 2, md: 3} => {xs: true, sm: true, md: true}\nexport function computeBreakpointsBase(breakpointValues, themeBreakpoints) {\n // fixed value\n if (typeof breakpointValues !== 'object') {\n return {};\n }\n const base = {};\n const breakpointsKeys = Object.keys(themeBreakpoints);\n if (Array.isArray(breakpointValues)) {\n breakpointsKeys.forEach((breakpoint, i) => {\n if (i < breakpointValues.length) {\n base[breakpoint] = true;\n }\n });\n } else {\n breakpointsKeys.forEach(breakpoint => {\n if (breakpointValues[breakpoint] != null) {\n base[breakpoint] = true;\n }\n });\n }\n return base;\n}\nexport function resolveBreakpointValues({\n values: breakpointValues,\n breakpoints: themeBreakpoints,\n base: customBase\n}) {\n const base = customBase || computeBreakpointsBase(breakpointValues, themeBreakpoints);\n const keys = Object.keys(base);\n if (keys.length === 0) {\n return breakpointValues;\n }\n let previous;\n return keys.reduce((acc, breakpoint, i) => {\n if (Array.isArray(breakpointValues)) {\n acc[breakpoint] = breakpointValues[i] != null ? breakpointValues[i] : breakpointValues[previous];\n previous = i;\n } else if (typeof breakpointValues === 'object') {\n acc[breakpoint] = breakpointValues[breakpoint] != null ? breakpointValues[breakpoint] : breakpointValues[previous];\n previous = breakpoint;\n } else {\n acc[breakpoint] = breakpointValues;\n }\n return acc;\n }, {});\n}\nexport default breakpoints;","import capitalize from '@mui/utils/capitalize';\nimport responsivePropType from './responsivePropType';\nimport { handleBreakpoints } from './breakpoints';\nexport function getPath(obj, path, checkVars = true) {\n if (!path || typeof path !== 'string') {\n return null;\n }\n\n // Check if CSS variables are used\n if (obj && obj.vars && checkVars) {\n const val = `vars.${path}`.split('.').reduce((acc, item) => acc && acc[item] ? acc[item] : null, obj);\n if (val != null) {\n return val;\n }\n }\n return path.split('.').reduce((acc, item) => {\n if (acc && acc[item] != null) {\n return acc[item];\n }\n return null;\n }, obj);\n}\nexport function getStyleValue(themeMapping, transform, propValueFinal, userValue = propValueFinal) {\n let value;\n if (typeof themeMapping === 'function') {\n value = themeMapping(propValueFinal);\n } else if (Array.isArray(themeMapping)) {\n value = themeMapping[propValueFinal] || userValue;\n } else {\n value = getPath(themeMapping, propValueFinal) || userValue;\n }\n if (transform) {\n value = transform(value, userValue, themeMapping);\n }\n return value;\n}\nfunction style(options) {\n const {\n prop,\n cssProperty = options.prop,\n themeKey,\n transform\n } = options;\n\n // false positive\n // eslint-disable-next-line react/function-component-definition\n const fn = props => {\n if (props[prop] == null) {\n return null;\n }\n const propValue = props[prop];\n const theme = props.theme;\n const themeMapping = getPath(theme, themeKey) || {};\n const styleFromPropValue = propValueFinal => {\n let value = getStyleValue(themeMapping, transform, propValueFinal);\n if (propValueFinal === value && typeof propValueFinal === 'string') {\n // Haven't found value\n value = getStyleValue(themeMapping, transform, `${prop}${propValueFinal === 'default' ? '' : capitalize(propValueFinal)}`, propValueFinal);\n }\n if (cssProperty === false) {\n return value;\n }\n return {\n [cssProperty]: value\n };\n };\n return handleBreakpoints(props, propValue, styleFromPropValue);\n };\n fn.propTypes = process.env.NODE_ENV !== 'production' ? {\n [prop]: responsivePropType\n } : {};\n fn.filterProps = [prop];\n return fn;\n}\nexport default style;","export default function memoize(fn) {\n const cache = {};\n return arg => {\n if (cache[arg] === undefined) {\n cache[arg] = fn(arg);\n }\n return cache[arg];\n };\n}","import responsivePropType from './responsivePropType';\nimport { handleBreakpoints } from './breakpoints';\nimport { getPath } from './style';\nimport merge from './merge';\nimport memoize from './memoize';\nconst properties = {\n m: 'margin',\n p: 'padding'\n};\nconst directions = {\n t: 'Top',\n r: 'Right',\n b: 'Bottom',\n l: 'Left',\n x: ['Left', 'Right'],\n y: ['Top', 'Bottom']\n};\nconst aliases = {\n marginX: 'mx',\n marginY: 'my',\n paddingX: 'px',\n paddingY: 'py'\n};\n\n// memoize() impact:\n// From 300,000 ops/sec\n// To 350,000 ops/sec\nconst getCssProperties = memoize(prop => {\n // It's not a shorthand notation.\n if (prop.length > 2) {\n if (aliases[prop]) {\n prop = aliases[prop];\n } else {\n return [prop];\n }\n }\n const [a, b] = prop.split('');\n const property = properties[a];\n const direction = directions[b] || '';\n return Array.isArray(direction) ? direction.map(dir => property + dir) : [property + direction];\n});\nexport const marginKeys = ['m', 'mt', 'mr', 'mb', 'ml', 'mx', 'my', 'margin', 'marginTop', 'marginRight', 'marginBottom', 'marginLeft', 'marginX', 'marginY', 'marginInline', 'marginInlineStart', 'marginInlineEnd', 'marginBlock', 'marginBlockStart', 'marginBlockEnd'];\nexport const paddingKeys = ['p', 'pt', 'pr', 'pb', 'pl', 'px', 'py', 'padding', 'paddingTop', 'paddingRight', 'paddingBottom', 'paddingLeft', 'paddingX', 'paddingY', 'paddingInline', 'paddingInlineStart', 'paddingInlineEnd', 'paddingBlock', 'paddingBlockStart', 'paddingBlockEnd'];\nconst spacingKeys = [...marginKeys, ...paddingKeys];\nexport function createUnaryUnit(theme, themeKey, defaultValue, propName) {\n var _getPath;\n const themeSpacing = (_getPath = getPath(theme, themeKey, false)) != null ? _getPath : defaultValue;\n if (typeof themeSpacing === 'number') {\n return abs => {\n if (typeof abs === 'string') {\n return abs;\n }\n if (process.env.NODE_ENV !== 'production') {\n if (typeof abs !== 'number') {\n console.error(`MUI: Expected ${propName} argument to be a number or a string, got ${abs}.`);\n }\n }\n return themeSpacing * abs;\n };\n }\n if (Array.isArray(themeSpacing)) {\n return abs => {\n if (typeof abs === 'string') {\n return abs;\n }\n if (process.env.NODE_ENV !== 'production') {\n if (!Number.isInteger(abs)) {\n console.error([`MUI: The \\`theme.${themeKey}\\` array type cannot be combined with non integer values.` + `You should either use an integer value that can be used as index, or define the \\`theme.${themeKey}\\` as a number.`].join('\\n'));\n } else if (abs > themeSpacing.length - 1) {\n console.error([`MUI: The value provided (${abs}) overflows.`, `The supported values are: ${JSON.stringify(themeSpacing)}.`, `${abs} > ${themeSpacing.length - 1}, you need to add the missing values.`].join('\\n'));\n }\n }\n return themeSpacing[abs];\n };\n }\n if (typeof themeSpacing === 'function') {\n return themeSpacing;\n }\n if (process.env.NODE_ENV !== 'production') {\n console.error([`MUI: The \\`theme.${themeKey}\\` value (${themeSpacing}) is invalid.`, 'It should be a number, an array or a function.'].join('\\n'));\n }\n return () => undefined;\n}\nexport function createUnarySpacing(theme) {\n return createUnaryUnit(theme, 'spacing', 8, 'spacing');\n}\nexport function getValue(transformer, propValue) {\n if (typeof propValue === 'string' || propValue == null) {\n return propValue;\n }\n const abs = Math.abs(propValue);\n const transformed = transformer(abs);\n if (propValue >= 0) {\n return transformed;\n }\n if (typeof transformed === 'number') {\n return -transformed;\n }\n return `-${transformed}`;\n}\nexport function getStyleFromPropValue(cssProperties, transformer) {\n return propValue => cssProperties.reduce((acc, cssProperty) => {\n acc[cssProperty] = getValue(transformer, propValue);\n return acc;\n }, {});\n}\nfunction resolveCssProperty(props, keys, prop, transformer) {\n // Using a hash computation over an array iteration could be faster, but with only 28 items,\n // it's doesn't worth the bundle size.\n if (keys.indexOf(prop) === -1) {\n return null;\n }\n const cssProperties = getCssProperties(prop);\n const styleFromPropValue = getStyleFromPropValue(cssProperties, transformer);\n const propValue = props[prop];\n return handleBreakpoints(props, propValue, styleFromPropValue);\n}\nfunction style(props, keys) {\n const transformer = createUnarySpacing(props.theme);\n return Object.keys(props).map(prop => resolveCssProperty(props, keys, prop, transformer)).reduce(merge, {});\n}\nexport function margin(props) {\n return style(props, marginKeys);\n}\nmargin.propTypes = process.env.NODE_ENV !== 'production' ? marginKeys.reduce((obj, key) => {\n obj[key] = responsivePropType;\n return obj;\n}, {}) : {};\nmargin.filterProps = marginKeys;\nexport function padding(props) {\n return style(props, paddingKeys);\n}\npadding.propTypes = process.env.NODE_ENV !== 'production' ? paddingKeys.reduce((obj, key) => {\n obj[key] = responsivePropType;\n return obj;\n}, {}) : {};\npadding.filterProps = paddingKeys;\nfunction spacing(props) {\n return style(props, spacingKeys);\n}\nspacing.propTypes = process.env.NODE_ENV !== 'production' ? spacingKeys.reduce((obj, key) => {\n obj[key] = responsivePropType;\n return obj;\n}, {}) : {};\nspacing.filterProps = spacingKeys;\nexport default spacing;","import { createUnarySpacing } from '../spacing';\n\n// The different signatures imply different meaning for their arguments that can't be expressed structurally.\n// We express the difference with variable names.\n\nexport default function createSpacing(spacingInput = 8) {\n // Already transformed.\n if (spacingInput.mui) {\n return spacingInput;\n }\n\n // Material Design layouts are visually balanced. Most measurements align to an 8dp grid, which aligns both spacing and the overall layout.\n // Smaller components, such as icons, can align to a 4dp grid.\n // https://m2.material.io/design/layout/understanding-layout.html\n const transform = createUnarySpacing({\n spacing: spacingInput\n });\n const spacing = (...argsInput) => {\n if (process.env.NODE_ENV !== 'production') {\n if (!(argsInput.length <= 4)) {\n console.error(`MUI: Too many arguments provided, expected between 0 and 4, got ${argsInput.length}`);\n }\n }\n const args = argsInput.length === 0 ? [1] : argsInput;\n return args.map(argument => {\n const output = transform(argument);\n return typeof output === 'number' ? `${output}px` : output;\n }).join(' ');\n };\n spacing.mui = true;\n return spacing;\n}","import merge from './merge';\nfunction compose(...styles) {\n const handlers = styles.reduce((acc, style) => {\n style.filterProps.forEach(prop => {\n acc[prop] = style;\n });\n return acc;\n }, {});\n\n // false positive\n // eslint-disable-next-line react/function-component-definition\n const fn = props => {\n return Object.keys(props).reduce((acc, prop) => {\n if (handlers[prop]) {\n return merge(acc, handlers[prop](props));\n }\n return acc;\n }, {});\n };\n fn.propTypes = process.env.NODE_ENV !== 'production' ? styles.reduce((acc, style) => Object.assign(acc, style.propTypes), {}) : {};\n fn.filterProps = styles.reduce((acc, style) => acc.concat(style.filterProps), []);\n return fn;\n}\nexport default compose;","import responsivePropType from './responsivePropType';\nimport style from './style';\nimport compose from './compose';\nimport { createUnaryUnit, getValue } from './spacing';\nimport { handleBreakpoints } from './breakpoints';\nexport function borderTransform(value) {\n if (typeof value !== 'number') {\n return value;\n }\n return `${value}px solid`;\n}\nfunction createBorderStyle(prop, transform) {\n return style({\n prop,\n themeKey: 'borders',\n transform\n });\n}\nexport const border = createBorderStyle('border', borderTransform);\nexport const borderTop = createBorderStyle('borderTop', borderTransform);\nexport const borderRight = createBorderStyle('borderRight', borderTransform);\nexport const borderBottom = createBorderStyle('borderBottom', borderTransform);\nexport const borderLeft = createBorderStyle('borderLeft', borderTransform);\nexport const borderColor = createBorderStyle('borderColor');\nexport const borderTopColor = createBorderStyle('borderTopColor');\nexport const borderRightColor = createBorderStyle('borderRightColor');\nexport const borderBottomColor = createBorderStyle('borderBottomColor');\nexport const borderLeftColor = createBorderStyle('borderLeftColor');\nexport const outline = createBorderStyle('outline', borderTransform);\nexport const outlineColor = createBorderStyle('outlineColor');\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const borderRadius = props => {\n if (props.borderRadius !== undefined && props.borderRadius !== null) {\n const transformer = createUnaryUnit(props.theme, 'shape.borderRadius', 4, 'borderRadius');\n const styleFromPropValue = propValue => ({\n borderRadius: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.borderRadius, styleFromPropValue);\n }\n return null;\n};\nborderRadius.propTypes = process.env.NODE_ENV !== 'production' ? {\n borderRadius: responsivePropType\n} : {};\nborderRadius.filterProps = ['borderRadius'];\nconst borders = compose(border, borderTop, borderRight, borderBottom, borderLeft, borderColor, borderTopColor, borderRightColor, borderBottomColor, borderLeftColor, borderRadius, outline, outlineColor);\nexport default borders;","import style from './style';\nimport compose from './compose';\nimport { createUnaryUnit, getValue } from './spacing';\nimport { handleBreakpoints } from './breakpoints';\nimport responsivePropType from './responsivePropType';\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const gap = props => {\n if (props.gap !== undefined && props.gap !== null) {\n const transformer = createUnaryUnit(props.theme, 'spacing', 8, 'gap');\n const styleFromPropValue = propValue => ({\n gap: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.gap, styleFromPropValue);\n }\n return null;\n};\ngap.propTypes = process.env.NODE_ENV !== 'production' ? {\n gap: responsivePropType\n} : {};\ngap.filterProps = ['gap'];\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const columnGap = props => {\n if (props.columnGap !== undefined && props.columnGap !== null) {\n const transformer = createUnaryUnit(props.theme, 'spacing', 8, 'columnGap');\n const styleFromPropValue = propValue => ({\n columnGap: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.columnGap, styleFromPropValue);\n }\n return null;\n};\ncolumnGap.propTypes = process.env.NODE_ENV !== 'production' ? {\n columnGap: responsivePropType\n} : {};\ncolumnGap.filterProps = ['columnGap'];\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const rowGap = props => {\n if (props.rowGap !== undefined && props.rowGap !== null) {\n const transformer = createUnaryUnit(props.theme, 'spacing', 8, 'rowGap');\n const styleFromPropValue = propValue => ({\n rowGap: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.rowGap, styleFromPropValue);\n }\n return null;\n};\nrowGap.propTypes = process.env.NODE_ENV !== 'production' ? {\n rowGap: responsivePropType\n} : {};\nrowGap.filterProps = ['rowGap'];\nexport const gridColumn = style({\n prop: 'gridColumn'\n});\nexport const gridRow = style({\n prop: 'gridRow'\n});\nexport const gridAutoFlow = style({\n prop: 'gridAutoFlow'\n});\nexport const gridAutoColumns = style({\n prop: 'gridAutoColumns'\n});\nexport const gridAutoRows = style({\n prop: 'gridAutoRows'\n});\nexport const gridTemplateColumns = style({\n prop: 'gridTemplateColumns'\n});\nexport const gridTemplateRows = style({\n prop: 'gridTemplateRows'\n});\nexport const gridTemplateAreas = style({\n prop: 'gridTemplateAreas'\n});\nexport const gridArea = style({\n prop: 'gridArea'\n});\nconst grid = compose(gap, columnGap, rowGap, gridColumn, gridRow, gridAutoFlow, gridAutoColumns, gridAutoRows, gridTemplateColumns, gridTemplateRows, gridTemplateAreas, gridArea);\nexport default grid;","import style from './style';\nimport compose from './compose';\nexport function paletteTransform(value, userValue) {\n if (userValue === 'grey') {\n return userValue;\n }\n return value;\n}\nexport const color = style({\n prop: 'color',\n themeKey: 'palette',\n transform: paletteTransform\n});\nexport const bgcolor = style({\n prop: 'bgcolor',\n cssProperty: 'backgroundColor',\n themeKey: 'palette',\n transform: paletteTransform\n});\nexport const backgroundColor = style({\n prop: 'backgroundColor',\n themeKey: 'palette',\n transform: paletteTransform\n});\nconst palette = compose(color, bgcolor, backgroundColor);\nexport default palette;","import style from './style';\nimport compose from './compose';\nimport { handleBreakpoints, values as breakpointsValues } from './breakpoints';\nexport function sizingTransform(value) {\n return value <= 1 && value !== 0 ? `${value * 100}%` : value;\n}\nexport const width = style({\n prop: 'width',\n transform: sizingTransform\n});\nexport const maxWidth = props => {\n if (props.maxWidth !== undefined && props.maxWidth !== null) {\n const styleFromPropValue = propValue => {\n var _props$theme, _props$theme2;\n const breakpoint = ((_props$theme = props.theme) == null || (_props$theme = _props$theme.breakpoints) == null || (_props$theme = _props$theme.values) == null ? void 0 : _props$theme[propValue]) || breakpointsValues[propValue];\n if (!breakpoint) {\n return {\n maxWidth: sizingTransform(propValue)\n };\n }\n if (((_props$theme2 = props.theme) == null || (_props$theme2 = _props$theme2.breakpoints) == null ? void 0 : _props$theme2.unit) !== 'px') {\n return {\n maxWidth: `${breakpoint}${props.theme.breakpoints.unit}`\n };\n }\n return {\n maxWidth: breakpoint\n };\n };\n return handleBreakpoints(props, props.maxWidth, styleFromPropValue);\n }\n return null;\n};\nmaxWidth.filterProps = ['maxWidth'];\nexport const minWidth = style({\n prop: 'minWidth',\n transform: sizingTransform\n});\nexport const height = style({\n prop: 'height',\n transform: sizingTransform\n});\nexport const maxHeight = style({\n prop: 'maxHeight',\n transform: sizingTransform\n});\nexport const minHeight = style({\n prop: 'minHeight',\n transform: sizingTransform\n});\nexport const sizeWidth = style({\n prop: 'size',\n cssProperty: 'width',\n transform: sizingTransform\n});\nexport const sizeHeight = style({\n prop: 'size',\n cssProperty: 'height',\n transform: sizingTransform\n});\nexport const boxSizing = style({\n prop: 'boxSizing'\n});\nconst sizing = compose(width, maxWidth, minWidth, height, maxHeight, minHeight, boxSizing);\nexport default sizing;","import { padding, margin } from '../spacing';\nimport { borderRadius, borderTransform } from '../borders';\nimport { gap, rowGap, columnGap } from '../cssGrid';\nimport { paletteTransform } from '../palette';\nimport { maxWidth, sizingTransform } from '../sizing';\nconst defaultSxConfig = {\n // borders\n border: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderTop: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderRight: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderBottom: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderLeft: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderColor: {\n themeKey: 'palette'\n },\n borderTopColor: {\n themeKey: 'palette'\n },\n borderRightColor: {\n themeKey: 'palette'\n },\n borderBottomColor: {\n themeKey: 'palette'\n },\n borderLeftColor: {\n themeKey: 'palette'\n },\n outline: {\n themeKey: 'borders',\n transform: borderTransform\n },\n outlineColor: {\n themeKey: 'palette'\n },\n borderRadius: {\n themeKey: 'shape.borderRadius',\n style: borderRadius\n },\n // palette\n color: {\n themeKey: 'palette',\n transform: paletteTransform\n },\n bgcolor: {\n themeKey: 'palette',\n cssProperty: 'backgroundColor',\n transform: paletteTransform\n },\n backgroundColor: {\n themeKey: 'palette',\n transform: paletteTransform\n },\n // spacing\n p: {\n style: padding\n },\n pt: {\n style: padding\n },\n pr: {\n style: padding\n },\n pb: {\n style: padding\n },\n pl: {\n style: padding\n },\n px: {\n style: padding\n },\n py: {\n style: padding\n },\n padding: {\n style: padding\n },\n paddingTop: {\n style: padding\n },\n paddingRight: {\n style: padding\n },\n paddingBottom: {\n style: padding\n },\n paddingLeft: {\n style: padding\n },\n paddingX: {\n style: padding\n },\n paddingY: {\n style: padding\n },\n paddingInline: {\n style: padding\n },\n paddingInlineStart: {\n style: padding\n },\n paddingInlineEnd: {\n style: padding\n },\n paddingBlock: {\n style: padding\n },\n paddingBlockStart: {\n style: padding\n },\n paddingBlockEnd: {\n style: padding\n },\n m: {\n style: margin\n },\n mt: {\n style: margin\n },\n mr: {\n style: margin\n },\n mb: {\n style: margin\n },\n ml: {\n style: margin\n },\n mx: {\n style: margin\n },\n my: {\n style: margin\n },\n margin: {\n style: margin\n },\n marginTop: {\n style: margin\n },\n marginRight: {\n style: margin\n },\n marginBottom: {\n style: margin\n },\n marginLeft: {\n style: margin\n },\n marginX: {\n style: margin\n },\n marginY: {\n style: margin\n },\n marginInline: {\n style: margin\n },\n marginInlineStart: {\n style: margin\n },\n marginInlineEnd: {\n style: margin\n },\n marginBlock: {\n style: margin\n },\n marginBlockStart: {\n style: margin\n },\n marginBlockEnd: {\n style: margin\n },\n // display\n displayPrint: {\n cssProperty: false,\n transform: value => ({\n '@media print': {\n display: value\n }\n })\n },\n display: {},\n overflow: {},\n textOverflow: {},\n visibility: {},\n whiteSpace: {},\n // flexbox\n flexBasis: {},\n flexDirection: {},\n flexWrap: {},\n justifyContent: {},\n alignItems: {},\n alignContent: {},\n order: {},\n flex: {},\n flexGrow: {},\n flexShrink: {},\n alignSelf: {},\n justifyItems: {},\n justifySelf: {},\n // grid\n gap: {\n style: gap\n },\n rowGap: {\n style: rowGap\n },\n columnGap: {\n style: columnGap\n },\n gridColumn: {},\n gridRow: {},\n gridAutoFlow: {},\n gridAutoColumns: {},\n gridAutoRows: {},\n gridTemplateColumns: {},\n gridTemplateRows: {},\n gridTemplateAreas: {},\n gridArea: {},\n // positions\n position: {},\n zIndex: {\n themeKey: 'zIndex'\n },\n top: {},\n right: {},\n bottom: {},\n left: {},\n // shadows\n boxShadow: {\n themeKey: 'shadows'\n },\n // sizing\n width: {\n transform: sizingTransform\n },\n maxWidth: {\n style: maxWidth\n },\n minWidth: {\n transform: sizingTransform\n },\n height: {\n transform: sizingTransform\n },\n maxHeight: {\n transform: sizingTransform\n },\n minHeight: {\n transform: sizingTransform\n },\n boxSizing: {},\n // typography\n fontFamily: {\n themeKey: 'typography'\n },\n fontSize: {\n themeKey: 'typography'\n },\n fontStyle: {\n themeKey: 'typography'\n },\n fontWeight: {\n themeKey: 'typography'\n },\n letterSpacing: {},\n textTransform: {},\n lineHeight: {},\n textAlign: {},\n typography: {\n cssProperty: false,\n themeKey: 'typography'\n }\n};\nexport default defaultSxConfig;","import capitalize from '@mui/utils/capitalize';\nimport merge from '../merge';\nimport { getPath, getStyleValue as getValue } from '../style';\nimport { handleBreakpoints, createEmptyBreakpointObject, removeUnusedBreakpoints } from '../breakpoints';\nimport defaultSxConfig from './defaultSxConfig';\nfunction objectsHaveSameKeys(...objects) {\n const allKeys = objects.reduce((keys, object) => keys.concat(Object.keys(object)), []);\n const union = new Set(allKeys);\n return objects.every(object => union.size === Object.keys(object).length);\n}\nfunction callIfFn(maybeFn, arg) {\n return typeof maybeFn === 'function' ? maybeFn(arg) : maybeFn;\n}\n\n// eslint-disable-next-line @typescript-eslint/naming-convention\nexport function unstable_createStyleFunctionSx() {\n function getThemeValue(prop, val, theme, config) {\n const props = {\n [prop]: val,\n theme\n };\n const options = config[prop];\n if (!options) {\n return {\n [prop]: val\n };\n }\n const {\n cssProperty = prop,\n themeKey,\n transform,\n style\n } = options;\n if (val == null) {\n return null;\n }\n\n // TODO v6: remove, see https://github.com/mui/material-ui/pull/38123\n if (themeKey === 'typography' && val === 'inherit') {\n return {\n [prop]: val\n };\n }\n const themeMapping = getPath(theme, themeKey) || {};\n if (style) {\n return style(props);\n }\n const styleFromPropValue = propValueFinal => {\n let value = getValue(themeMapping, transform, propValueFinal);\n if (propValueFinal === value && typeof propValueFinal === 'string') {\n // Haven't found value\n value = getValue(themeMapping, transform, `${prop}${propValueFinal === 'default' ? '' : capitalize(propValueFinal)}`, propValueFinal);\n }\n if (cssProperty === false) {\n return value;\n }\n return {\n [cssProperty]: value\n };\n };\n return handleBreakpoints(props, val, styleFromPropValue);\n }\n function styleFunctionSx(props) {\n var _theme$unstable_sxCon;\n const {\n sx,\n theme = {}\n } = props || {};\n if (!sx) {\n return null; // Emotion & styled-components will neglect null\n }\n const config = (_theme$unstable_sxCon = theme.unstable_sxConfig) != null ? _theme$unstable_sxCon : defaultSxConfig;\n\n /*\n * Receive `sxInput` as object or callback\n * and then recursively check keys & values to create media query object styles.\n * (the result will be used in `styled`)\n */\n function traverse(sxInput) {\n let sxObject = sxInput;\n if (typeof sxInput === 'function') {\n sxObject = sxInput(theme);\n } else if (typeof sxInput !== 'object') {\n // value\n return sxInput;\n }\n if (!sxObject) {\n return null;\n }\n const emptyBreakpoints = createEmptyBreakpointObject(theme.breakpoints);\n const breakpointsKeys = Object.keys(emptyBreakpoints);\n let css = emptyBreakpoints;\n Object.keys(sxObject).forEach(styleKey => {\n const value = callIfFn(sxObject[styleKey], theme);\n if (value !== null && value !== undefined) {\n if (typeof value === 'object') {\n if (config[styleKey]) {\n css = merge(css, getThemeValue(styleKey, value, theme, config));\n } else {\n const breakpointsValues = handleBreakpoints({\n theme\n }, value, x => ({\n [styleKey]: x\n }));\n if (objectsHaveSameKeys(breakpointsValues, value)) {\n css[styleKey] = styleFunctionSx({\n sx: value,\n theme\n });\n } else {\n css = merge(css, breakpointsValues);\n }\n }\n } else {\n css = merge(css, getThemeValue(styleKey, value, theme, config));\n }\n }\n });\n return removeUnusedBreakpoints(breakpointsKeys, css);\n }\n return Array.isArray(sx) ? sx.map(traverse) : traverse(sx);\n }\n return styleFunctionSx;\n}\nconst styleFunctionSx = unstable_createStyleFunctionSx();\nstyleFunctionSx.filterProps = ['sx'];\nexport default styleFunctionSx;","/**\n * A universal utility to style components with multiple color modes. Always use it from the theme object.\n * It works with:\n * - [Basic theme](https://mui.com/material-ui/customization/dark-mode/)\n * - [CSS theme variables](https://mui.com/material-ui/experimental-api/css-theme-variables/overview/)\n * - Zero-runtime engine\n *\n * Tips: Use an array over object spread and place `theme.applyStyles()` last.\n *\n * ✅ [{ background: '#e5e5e5' }, theme.applyStyles('dark', { background: '#1c1c1c' })]\n *\n * 🚫 { background: '#e5e5e5', ...theme.applyStyles('dark', { background: '#1c1c1c' })}\n *\n * @example\n * 1. using with `styled`:\n * ```jsx\n * const Component = styled('div')(({ theme }) => [\n * { background: '#e5e5e5' },\n * theme.applyStyles('dark', {\n * background: '#1c1c1c',\n * color: '#fff',\n * }),\n * ]);\n * ```\n *\n * @example\n * 2. using with `sx` prop:\n * ```jsx\n * [\n * { background: '#e5e5e5' },\n * theme.applyStyles('dark', {\n * background: '#1c1c1c',\n * color: '#fff',\n * }),\n * ]}\n * />\n * ```\n *\n * @example\n * 3. theming a component:\n * ```jsx\n * extendTheme({\n * components: {\n * MuiButton: {\n * styleOverrides: {\n * root: ({ theme }) => [\n * { background: '#e5e5e5' },\n * theme.applyStyles('dark', {\n * background: '#1c1c1c',\n * color: '#fff',\n * }),\n * ],\n * },\n * }\n * }\n * })\n *```\n */\nexport default function applyStyles(key, styles) {\n // @ts-expect-error this is 'any' type\n const theme = this;\n if (theme.vars && typeof theme.getColorSchemeSelector === 'function') {\n // If CssVarsProvider is used as a provider,\n // returns '* :where([data-mui-color-scheme=\"light|dark\"]) &'\n const selector = theme.getColorSchemeSelector(key).replace(/(\\[[^\\]]+\\])/, '*:where($1)');\n return {\n [selector]: styles\n };\n }\n if (theme.palette.mode === key) {\n return styles;\n }\n return {};\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"breakpoints\", \"palette\", \"spacing\", \"shape\"];\nimport deepmerge from '@mui/utils/deepmerge';\nimport createBreakpoints from './createBreakpoints';\nimport shape from './shape';\nimport createSpacing from './createSpacing';\nimport styleFunctionSx from '../styleFunctionSx/styleFunctionSx';\nimport defaultSxConfig from '../styleFunctionSx/defaultSxConfig';\nimport applyStyles from './applyStyles';\nfunction createTheme(options = {}, ...args) {\n const {\n breakpoints: breakpointsInput = {},\n palette: paletteInput = {},\n spacing: spacingInput,\n shape: shapeInput = {}\n } = options,\n other = _objectWithoutPropertiesLoose(options, _excluded);\n const breakpoints = createBreakpoints(breakpointsInput);\n const spacing = createSpacing(spacingInput);\n let muiTheme = deepmerge({\n breakpoints,\n direction: 'ltr',\n components: {},\n // Inject component definitions.\n palette: _extends({\n mode: 'light'\n }, paletteInput),\n spacing,\n shape: _extends({}, shape, shapeInput)\n }, other);\n muiTheme.applyStyles = applyStyles;\n muiTheme = args.reduce((acc, argument) => deepmerge(acc, argument), muiTheme);\n muiTheme.unstable_sxConfig = _extends({}, defaultSxConfig, other == null ? void 0 : other.unstable_sxConfig);\n muiTheme.unstable_sx = function sx(props) {\n return styleFunctionSx({\n sx: props,\n theme: this\n });\n };\n return muiTheme;\n}\nexport default createTheme;","'use client';\n\nimport * as React from 'react';\nimport { ThemeContext } from '@mui/styled-engine';\nfunction isObjectEmpty(obj) {\n return Object.keys(obj).length === 0;\n}\nfunction useTheme(defaultTheme = null) {\n const contextTheme = React.useContext(ThemeContext);\n return !contextTheme || isObjectEmpty(contextTheme) ? defaultTheme : contextTheme;\n}\nexport default useTheme;","'use client';\n\nimport createTheme from './createTheme';\nimport useThemeWithoutDefault from './useThemeWithoutDefault';\nexport const systemDefaultTheme = createTheme();\nfunction useTheme(defaultTheme = systemDefaultTheme) {\n return useThemeWithoutDefault(defaultTheme);\n}\nexport default useTheme;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"ownerState\"],\n _excluded2 = [\"variants\"],\n _excluded3 = [\"name\", \"slot\", \"skipVariantsResolver\", \"skipSx\", \"overridesResolver\"];\n/* eslint-disable no-underscore-dangle */\nimport styledEngineStyled, { internal_processStyles as processStyles } from '@mui/styled-engine';\nimport { isPlainObject } from '@mui/utils/deepmerge';\nimport capitalize from '@mui/utils/capitalize';\nimport getDisplayName from '@mui/utils/getDisplayName';\nimport createTheme from './createTheme';\nimport styleFunctionSx from './styleFunctionSx';\nfunction isEmpty(obj) {\n return Object.keys(obj).length === 0;\n}\n\n// https://github.com/emotion-js/emotion/blob/26ded6109fcd8ca9875cc2ce4564fee678a3f3c5/packages/styled/src/utils.js#L40\nfunction isStringTag(tag) {\n return typeof tag === 'string' &&\n // 96 is one less than the char code\n // for \"a\" so this is checking that\n // it's a lowercase character\n tag.charCodeAt(0) > 96;\n}\n\n// Update /system/styled/#api in case if this changes\nexport function shouldForwardProp(prop) {\n return prop !== 'ownerState' && prop !== 'theme' && prop !== 'sx' && prop !== 'as';\n}\nexport const systemDefaultTheme = createTheme();\nconst lowercaseFirstLetter = string => {\n if (!string) {\n return string;\n }\n return string.charAt(0).toLowerCase() + string.slice(1);\n};\nfunction resolveTheme({\n defaultTheme,\n theme,\n themeId\n}) {\n return isEmpty(theme) ? defaultTheme : theme[themeId] || theme;\n}\nfunction defaultOverridesResolver(slot) {\n if (!slot) {\n return null;\n }\n return (props, styles) => styles[slot];\n}\nfunction processStyleArg(callableStyle, _ref) {\n let {\n ownerState\n } = _ref,\n props = _objectWithoutPropertiesLoose(_ref, _excluded);\n const resolvedStylesArg = typeof callableStyle === 'function' ? callableStyle(_extends({\n ownerState\n }, props)) : callableStyle;\n if (Array.isArray(resolvedStylesArg)) {\n return resolvedStylesArg.flatMap(resolvedStyle => processStyleArg(resolvedStyle, _extends({\n ownerState\n }, props)));\n }\n if (!!resolvedStylesArg && typeof resolvedStylesArg === 'object' && Array.isArray(resolvedStylesArg.variants)) {\n const {\n variants = []\n } = resolvedStylesArg,\n otherStyles = _objectWithoutPropertiesLoose(resolvedStylesArg, _excluded2);\n let result = otherStyles;\n variants.forEach(variant => {\n let isMatch = true;\n if (typeof variant.props === 'function') {\n isMatch = variant.props(_extends({\n ownerState\n }, props, ownerState));\n } else {\n Object.keys(variant.props).forEach(key => {\n if ((ownerState == null ? void 0 : ownerState[key]) !== variant.props[key] && props[key] !== variant.props[key]) {\n isMatch = false;\n }\n });\n }\n if (isMatch) {\n if (!Array.isArray(result)) {\n result = [result];\n }\n result.push(typeof variant.style === 'function' ? variant.style(_extends({\n ownerState\n }, props, ownerState)) : variant.style);\n }\n });\n return result;\n }\n return resolvedStylesArg;\n}\nexport default function createStyled(input = {}) {\n const {\n themeId,\n defaultTheme = systemDefaultTheme,\n rootShouldForwardProp = shouldForwardProp,\n slotShouldForwardProp = shouldForwardProp\n } = input;\n const systemSx = props => {\n return styleFunctionSx(_extends({}, props, {\n theme: resolveTheme(_extends({}, props, {\n defaultTheme,\n themeId\n }))\n }));\n };\n systemSx.__mui_systemSx = true;\n return (tag, inputOptions = {}) => {\n // Filter out the `sx` style function from the previous styled component to prevent unnecessary styles generated by the composite components.\n processStyles(tag, styles => styles.filter(style => !(style != null && style.__mui_systemSx)));\n const {\n name: componentName,\n slot: componentSlot,\n skipVariantsResolver: inputSkipVariantsResolver,\n skipSx: inputSkipSx,\n // TODO v6: remove `lowercaseFirstLetter()` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n overridesResolver = defaultOverridesResolver(lowercaseFirstLetter(componentSlot))\n } = inputOptions,\n options = _objectWithoutPropertiesLoose(inputOptions, _excluded3);\n\n // if skipVariantsResolver option is defined, take the value, otherwise, true for root and false for other slots.\n const skipVariantsResolver = inputSkipVariantsResolver !== undefined ? inputSkipVariantsResolver :\n // TODO v6: remove `Root` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n componentSlot && componentSlot !== 'Root' && componentSlot !== 'root' || false;\n const skipSx = inputSkipSx || false;\n let label;\n if (process.env.NODE_ENV !== 'production') {\n if (componentName) {\n // TODO v6: remove `lowercaseFirstLetter()` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n label = `${componentName}-${lowercaseFirstLetter(componentSlot || 'Root')}`;\n }\n }\n let shouldForwardPropOption = shouldForwardProp;\n\n // TODO v6: remove `Root` in the next major release\n // For more details: https://github.com/mui/material-ui/pull/37908\n if (componentSlot === 'Root' || componentSlot === 'root') {\n shouldForwardPropOption = rootShouldForwardProp;\n } else if (componentSlot) {\n // any other slot specified\n shouldForwardPropOption = slotShouldForwardProp;\n } else if (isStringTag(tag)) {\n // for string (html) tag, preserve the behavior in emotion & styled-components.\n shouldForwardPropOption = undefined;\n }\n const defaultStyledResolver = styledEngineStyled(tag, _extends({\n shouldForwardProp: shouldForwardPropOption,\n label\n }, options));\n const transformStyleArg = stylesArg => {\n // On the server Emotion doesn't use React.forwardRef for creating components, so the created\n // component stays as a function. This condition makes sure that we do not interpolate functions\n // which are basically components used as a selectors.\n if (typeof stylesArg === 'function' && stylesArg.__emotion_real !== stylesArg || isPlainObject(stylesArg)) {\n return props => processStyleArg(stylesArg, _extends({}, props, {\n theme: resolveTheme({\n theme: props.theme,\n defaultTheme,\n themeId\n })\n }));\n }\n return stylesArg;\n };\n const muiStyledResolver = (styleArg, ...expressions) => {\n let transformedStyleArg = transformStyleArg(styleArg);\n const expressionsWithDefaultTheme = expressions ? expressions.map(transformStyleArg) : [];\n if (componentName && overridesResolver) {\n expressionsWithDefaultTheme.push(props => {\n const theme = resolveTheme(_extends({}, props, {\n defaultTheme,\n themeId\n }));\n if (!theme.components || !theme.components[componentName] || !theme.components[componentName].styleOverrides) {\n return null;\n }\n const styleOverrides = theme.components[componentName].styleOverrides;\n const resolvedStyleOverrides = {};\n // TODO: v7 remove iteration and use `resolveStyleArg(styleOverrides[slot])` directly\n Object.entries(styleOverrides).forEach(([slotKey, slotStyle]) => {\n resolvedStyleOverrides[slotKey] = processStyleArg(slotStyle, _extends({}, props, {\n theme\n }));\n });\n return overridesResolver(props, resolvedStyleOverrides);\n });\n }\n if (componentName && !skipVariantsResolver) {\n expressionsWithDefaultTheme.push(props => {\n var _theme$components;\n const theme = resolveTheme(_extends({}, props, {\n defaultTheme,\n themeId\n }));\n const themeVariants = theme == null || (_theme$components = theme.components) == null || (_theme$components = _theme$components[componentName]) == null ? void 0 : _theme$components.variants;\n return processStyleArg({\n variants: themeVariants\n }, _extends({}, props, {\n theme\n }));\n });\n }\n if (!skipSx) {\n expressionsWithDefaultTheme.push(systemSx);\n }\n const numOfCustomFnsApplied = expressionsWithDefaultTheme.length - expressions.length;\n if (Array.isArray(styleArg) && numOfCustomFnsApplied > 0) {\n const placeholders = new Array(numOfCustomFnsApplied).fill('');\n // If the type is array, than we need to add placeholders in the template for the overrides, variants and the sx styles.\n transformedStyleArg = [...styleArg, ...placeholders];\n transformedStyleArg.raw = [...styleArg.raw, ...placeholders];\n }\n const Component = defaultStyledResolver(transformedStyleArg, ...expressionsWithDefaultTheme);\n if (process.env.NODE_ENV !== 'production') {\n let displayName;\n if (componentName) {\n displayName = `${componentName}${capitalize(componentSlot || '')}`;\n }\n if (displayName === undefined) {\n displayName = `Styled(${getDisplayName(tag)})`;\n }\n Component.displayName = displayName;\n }\n if (tag.muiName) {\n Component.muiName = tag.muiName;\n }\n return Component;\n };\n if (defaultStyledResolver.withConfig) {\n muiStyledResolver.withConfig = defaultStyledResolver.withConfig;\n }\n return muiStyledResolver;\n };\n}","import resolveProps from '@mui/utils/resolveProps';\nexport default function getThemeProps(params) {\n const {\n theme,\n name,\n props\n } = params;\n if (!theme || !theme.components || !theme.components[name] || !theme.components[name].defaultProps) {\n return props;\n }\n return resolveProps(theme.components[name].defaultProps, props);\n}","'use client';\n\nimport getThemeProps from './getThemeProps';\nimport useTheme from '../useTheme';\nexport default function useThemeProps({\n props,\n name,\n defaultTheme,\n themeId\n}) {\n let theme = useTheme(defaultTheme);\n if (themeId) {\n theme = theme[themeId] || theme;\n }\n const mergedProps = getThemeProps({\n theme,\n name,\n props\n });\n return mergedProps;\n}","import _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\n/* eslint-disable @typescript-eslint/naming-convention */\nimport clamp from '@mui/utils/clamp';\n/**\n * Returns a number whose value is limited to the given range.\n * @param {number} value The value to be clamped\n * @param {number} min The lower boundary of the output range\n * @param {number} max The upper boundary of the output range\n * @returns {number} A number in the range [min, max]\n */\nfunction clampWrapper(value, min = 0, max = 1) {\n if (process.env.NODE_ENV !== 'production') {\n if (value < min || value > max) {\n console.error(`MUI: The value provided ${value} is out of range [${min}, ${max}].`);\n }\n }\n return clamp(value, min, max);\n}\n\n/**\n * Converts a color from CSS hex format to CSS rgb format.\n * @param {string} color - Hex color, i.e. #nnn or #nnnnnn\n * @returns {string} A CSS rgb color string\n */\nexport function hexToRgb(color) {\n color = color.slice(1);\n const re = new RegExp(`.{1,${color.length >= 6 ? 2 : 1}}`, 'g');\n let colors = color.match(re);\n if (colors && colors[0].length === 1) {\n colors = colors.map(n => n + n);\n }\n return colors ? `rgb${colors.length === 4 ? 'a' : ''}(${colors.map((n, index) => {\n return index < 3 ? parseInt(n, 16) : Math.round(parseInt(n, 16) / 255 * 1000) / 1000;\n }).join(', ')})` : '';\n}\nfunction intToHex(int) {\n const hex = int.toString(16);\n return hex.length === 1 ? `0${hex}` : hex;\n}\n\n/**\n * Returns an object with the type and values of a color.\n *\n * Note: Does not support rgb % values.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @returns {object} - A MUI color object: {type: string, values: number[]}\n */\nexport function decomposeColor(color) {\n // Idempotent\n if (color.type) {\n return color;\n }\n if (color.charAt(0) === '#') {\n return decomposeColor(hexToRgb(color));\n }\n const marker = color.indexOf('(');\n const type = color.substring(0, marker);\n if (['rgb', 'rgba', 'hsl', 'hsla', 'color'].indexOf(type) === -1) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: Unsupported \\`${color}\\` color.\nThe following formats are supported: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color().` : _formatMuiErrorMessage(9, color));\n }\n let values = color.substring(marker + 1, color.length - 1);\n let colorSpace;\n if (type === 'color') {\n values = values.split(' ');\n colorSpace = values.shift();\n if (values.length === 4 && values[3].charAt(0) === '/') {\n values[3] = values[3].slice(1);\n }\n if (['srgb', 'display-p3', 'a98-rgb', 'prophoto-rgb', 'rec-2020'].indexOf(colorSpace) === -1) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: unsupported \\`${colorSpace}\\` color space.\nThe following color spaces are supported: srgb, display-p3, a98-rgb, prophoto-rgb, rec-2020.` : _formatMuiErrorMessage(10, colorSpace));\n }\n } else {\n values = values.split(',');\n }\n values = values.map(value => parseFloat(value));\n return {\n type,\n values,\n colorSpace\n };\n}\n\n/**\n * Returns a channel created from the input color.\n *\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @returns {string} - The channel for the color, that can be used in rgba or hsla colors\n */\nexport const colorChannel = color => {\n const decomposedColor = decomposeColor(color);\n return decomposedColor.values.slice(0, 3).map((val, idx) => decomposedColor.type.indexOf('hsl') !== -1 && idx !== 0 ? `${val}%` : val).join(' ');\n};\nexport const private_safeColorChannel = (color, warning) => {\n try {\n return colorChannel(color);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n};\n\n/**\n * Converts a color object with type and values to a string.\n * @param {object} color - Decomposed color\n * @param {string} color.type - One of: 'rgb', 'rgba', 'hsl', 'hsla', 'color'\n * @param {array} color.values - [n,n,n] or [n,n,n,n]\n * @returns {string} A CSS color string\n */\nexport function recomposeColor(color) {\n const {\n type,\n colorSpace\n } = color;\n let {\n values\n } = color;\n if (type.indexOf('rgb') !== -1) {\n // Only convert the first 3 values to int (i.e. not alpha)\n values = values.map((n, i) => i < 3 ? parseInt(n, 10) : n);\n } else if (type.indexOf('hsl') !== -1) {\n values[1] = `${values[1]}%`;\n values[2] = `${values[2]}%`;\n }\n if (type.indexOf('color') !== -1) {\n values = `${colorSpace} ${values.join(' ')}`;\n } else {\n values = `${values.join(', ')}`;\n }\n return `${type}(${values})`;\n}\n\n/**\n * Converts a color from CSS rgb format to CSS hex format.\n * @param {string} color - RGB color, i.e. rgb(n, n, n)\n * @returns {string} A CSS rgb color string, i.e. #nnnnnn\n */\nexport function rgbToHex(color) {\n // Idempotent\n if (color.indexOf('#') === 0) {\n return color;\n }\n const {\n values\n } = decomposeColor(color);\n return `#${values.map((n, i) => intToHex(i === 3 ? Math.round(255 * n) : n)).join('')}`;\n}\n\n/**\n * Converts a color from hsl format to rgb format.\n * @param {string} color - HSL color values\n * @returns {string} rgb color values\n */\nexport function hslToRgb(color) {\n color = decomposeColor(color);\n const {\n values\n } = color;\n const h = values[0];\n const s = values[1] / 100;\n const l = values[2] / 100;\n const a = s * Math.min(l, 1 - l);\n const f = (n, k = (n + h / 30) % 12) => l - a * Math.max(Math.min(k - 3, 9 - k, 1), -1);\n let type = 'rgb';\n const rgb = [Math.round(f(0) * 255), Math.round(f(8) * 255), Math.round(f(4) * 255)];\n if (color.type === 'hsla') {\n type += 'a';\n rgb.push(values[3]);\n }\n return recomposeColor({\n type,\n values: rgb\n });\n}\n/**\n * The relative brightness of any point in a color space,\n * normalized to 0 for darkest black and 1 for lightest white.\n *\n * Formula: https://www.w3.org/TR/WCAG20-TECHS/G17.html#G17-tests\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @returns {number} The relative brightness of the color in the range 0 - 1\n */\nexport function getLuminance(color) {\n color = decomposeColor(color);\n let rgb = color.type === 'hsl' || color.type === 'hsla' ? decomposeColor(hslToRgb(color)).values : color.values;\n rgb = rgb.map(val => {\n if (color.type !== 'color') {\n val /= 255; // normalized\n }\n return val <= 0.03928 ? val / 12.92 : ((val + 0.055) / 1.055) ** 2.4;\n });\n\n // Truncate at 3 digits\n return Number((0.2126 * rgb[0] + 0.7152 * rgb[1] + 0.0722 * rgb[2]).toFixed(3));\n}\n\n/**\n * Calculates the contrast ratio between two colors.\n *\n * Formula: https://www.w3.org/TR/WCAG20-TECHS/G17.html#G17-tests\n * @param {string} foreground - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla()\n * @param {string} background - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla()\n * @returns {number} A contrast ratio value in the range 0 - 21.\n */\nexport function getContrastRatio(foreground, background) {\n const lumA = getLuminance(foreground);\n const lumB = getLuminance(background);\n return (Math.max(lumA, lumB) + 0.05) / (Math.min(lumA, lumB) + 0.05);\n}\n\n/**\n * Sets the absolute transparency of a color.\n * Any existing alpha values are overwritten.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} value - value to set the alpha channel to in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function alpha(color, value) {\n color = decomposeColor(color);\n value = clampWrapper(value);\n if (color.type === 'rgb' || color.type === 'hsl') {\n color.type += 'a';\n }\n if (color.type === 'color') {\n color.values[3] = `/${value}`;\n } else {\n color.values[3] = value;\n }\n return recomposeColor(color);\n}\nexport function private_safeAlpha(color, value, warning) {\n try {\n return alpha(color, value);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Darkens a color.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} coefficient - multiplier in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function darken(color, coefficient) {\n color = decomposeColor(color);\n coefficient = clampWrapper(coefficient);\n if (color.type.indexOf('hsl') !== -1) {\n color.values[2] *= 1 - coefficient;\n } else if (color.type.indexOf('rgb') !== -1 || color.type.indexOf('color') !== -1) {\n for (let i = 0; i < 3; i += 1) {\n color.values[i] *= 1 - coefficient;\n }\n }\n return recomposeColor(color);\n}\nexport function private_safeDarken(color, coefficient, warning) {\n try {\n return darken(color, coefficient);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Lightens a color.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} coefficient - multiplier in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function lighten(color, coefficient) {\n color = decomposeColor(color);\n coefficient = clampWrapper(coefficient);\n if (color.type.indexOf('hsl') !== -1) {\n color.values[2] += (100 - color.values[2]) * coefficient;\n } else if (color.type.indexOf('rgb') !== -1) {\n for (let i = 0; i < 3; i += 1) {\n color.values[i] += (255 - color.values[i]) * coefficient;\n }\n } else if (color.type.indexOf('color') !== -1) {\n for (let i = 0; i < 3; i += 1) {\n color.values[i] += (1 - color.values[i]) * coefficient;\n }\n }\n return recomposeColor(color);\n}\nexport function private_safeLighten(color, coefficient, warning) {\n try {\n return lighten(color, coefficient);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Darken or lighten a color, depending on its luminance.\n * Light colors are darkened, dark colors are lightened.\n * @param {string} color - CSS color, i.e. one of: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color()\n * @param {number} coefficient=0.15 - multiplier in the range 0 - 1\n * @returns {string} A CSS color string. Hex input values are returned as rgb\n */\nexport function emphasize(color, coefficient = 0.15) {\n return getLuminance(color) > 0.5 ? darken(color, coefficient) : lighten(color, coefficient);\n}\nexport function private_safeEmphasize(color, coefficient, warning) {\n try {\n return emphasize(color, coefficient);\n } catch (error) {\n if (warning && process.env.NODE_ENV !== 'production') {\n console.warn(warning);\n }\n return color;\n }\n}\n\n/**\n * Blend a transparent overlay color with a background color, resulting in a single\n * RGB color.\n * @param {string} background - CSS color\n * @param {string} overlay - CSS color\n * @param {number} opacity - Opacity multiplier in the range 0 - 1\n * @param {number} [gamma=1.0] - Gamma correction factor. For gamma-correct blending, 2.2 is usual.\n */\nexport function blend(background, overlay, opacity, gamma = 1.0) {\n const blendChannel = (b, o) => Math.round((b ** (1 / gamma) * (1 - opacity) + o ** (1 / gamma) * opacity) ** gamma);\n const backgroundColor = decomposeColor(background);\n const overlayColor = decomposeColor(overlay);\n const rgb = [blendChannel(backgroundColor.values[0], overlayColor.values[0]), blendChannel(backgroundColor.values[1], overlayColor.values[1]), blendChannel(backgroundColor.values[2], overlayColor.values[2])];\n return recomposeColor({\n type: 'rgb',\n values: rgb\n });\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nexport default function createMixins(breakpoints, mixins) {\n return _extends({\n toolbar: {\n minHeight: 56,\n [breakpoints.up('xs')]: {\n '@media (orientation: landscape)': {\n minHeight: 48\n }\n },\n [breakpoints.up('sm')]: {\n minHeight: 64\n }\n }\n }, mixins);\n}","const common = {\n black: '#000',\n white: '#fff'\n};\nexport default common;","const grey = {\n 50: '#fafafa',\n 100: '#f5f5f5',\n 200: '#eeeeee',\n 300: '#e0e0e0',\n 400: '#bdbdbd',\n 500: '#9e9e9e',\n 600: '#757575',\n 700: '#616161',\n 800: '#424242',\n 900: '#212121',\n A100: '#f5f5f5',\n A200: '#eeeeee',\n A400: '#bdbdbd',\n A700: '#616161'\n};\nexport default grey;","const purple = {\n 50: '#f3e5f5',\n 100: '#e1bee7',\n 200: '#ce93d8',\n 300: '#ba68c8',\n 400: '#ab47bc',\n 500: '#9c27b0',\n 600: '#8e24aa',\n 700: '#7b1fa2',\n 800: '#6a1b9a',\n 900: '#4a148c',\n A100: '#ea80fc',\n A200: '#e040fb',\n A400: '#d500f9',\n A700: '#aa00ff'\n};\nexport default purple;","const red = {\n 50: '#ffebee',\n 100: '#ffcdd2',\n 200: '#ef9a9a',\n 300: '#e57373',\n 400: '#ef5350',\n 500: '#f44336',\n 600: '#e53935',\n 700: '#d32f2f',\n 800: '#c62828',\n 900: '#b71c1c',\n A100: '#ff8a80',\n A200: '#ff5252',\n A400: '#ff1744',\n A700: '#d50000'\n};\nexport default red;","const orange = {\n 50: '#fff3e0',\n 100: '#ffe0b2',\n 200: '#ffcc80',\n 300: '#ffb74d',\n 400: '#ffa726',\n 500: '#ff9800',\n 600: '#fb8c00',\n 700: '#f57c00',\n 800: '#ef6c00',\n 900: '#e65100',\n A100: '#ffd180',\n A200: '#ffab40',\n A400: '#ff9100',\n A700: '#ff6d00'\n};\nexport default orange;","const blue = {\n 50: '#e3f2fd',\n 100: '#bbdefb',\n 200: '#90caf9',\n 300: '#64b5f6',\n 400: '#42a5f5',\n 500: '#2196f3',\n 600: '#1e88e5',\n 700: '#1976d2',\n 800: '#1565c0',\n 900: '#0d47a1',\n A100: '#82b1ff',\n A200: '#448aff',\n A400: '#2979ff',\n A700: '#2962ff'\n};\nexport default blue;","const lightBlue = {\n 50: '#e1f5fe',\n 100: '#b3e5fc',\n 200: '#81d4fa',\n 300: '#4fc3f7',\n 400: '#29b6f6',\n 500: '#03a9f4',\n 600: '#039be5',\n 700: '#0288d1',\n 800: '#0277bd',\n 900: '#01579b',\n A100: '#80d8ff',\n A200: '#40c4ff',\n A400: '#00b0ff',\n A700: '#0091ea'\n};\nexport default lightBlue;","const green = {\n 50: '#e8f5e9',\n 100: '#c8e6c9',\n 200: '#a5d6a7',\n 300: '#81c784',\n 400: '#66bb6a',\n 500: '#4caf50',\n 600: '#43a047',\n 700: '#388e3c',\n 800: '#2e7d32',\n 900: '#1b5e20',\n A100: '#b9f6ca',\n A200: '#69f0ae',\n A400: '#00e676',\n A700: '#00c853'\n};\nexport default green;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\nconst _excluded = [\"mode\", \"contrastThreshold\", \"tonalOffset\"];\nimport { deepmerge } from '@mui/utils';\nimport { darken, getContrastRatio, lighten } from '@mui/system';\nimport common from '../colors/common';\nimport grey from '../colors/grey';\nimport purple from '../colors/purple';\nimport red from '../colors/red';\nimport orange from '../colors/orange';\nimport blue from '../colors/blue';\nimport lightBlue from '../colors/lightBlue';\nimport green from '../colors/green';\nexport const light = {\n // The colors used to style the text.\n text: {\n // The most important text.\n primary: 'rgba(0, 0, 0, 0.87)',\n // Secondary text.\n secondary: 'rgba(0, 0, 0, 0.6)',\n // Disabled text have even lower visual prominence.\n disabled: 'rgba(0, 0, 0, 0.38)'\n },\n // The color used to divide different elements.\n divider: 'rgba(0, 0, 0, 0.12)',\n // The background colors used to style the surfaces.\n // Consistency between these values is important.\n background: {\n paper: common.white,\n default: common.white\n },\n // The colors used to style the action elements.\n action: {\n // The color of an active action like an icon button.\n active: 'rgba(0, 0, 0, 0.54)',\n // The color of an hovered action.\n hover: 'rgba(0, 0, 0, 0.04)',\n hoverOpacity: 0.04,\n // The color of a selected action.\n selected: 'rgba(0, 0, 0, 0.08)',\n selectedOpacity: 0.08,\n // The color of a disabled action.\n disabled: 'rgba(0, 0, 0, 0.26)',\n // The background color of a disabled action.\n disabledBackground: 'rgba(0, 0, 0, 0.12)',\n disabledOpacity: 0.38,\n focus: 'rgba(0, 0, 0, 0.12)',\n focusOpacity: 0.12,\n activatedOpacity: 0.12\n }\n};\nexport const dark = {\n text: {\n primary: common.white,\n secondary: 'rgba(255, 255, 255, 0.7)',\n disabled: 'rgba(255, 255, 255, 0.5)',\n icon: 'rgba(255, 255, 255, 0.5)'\n },\n divider: 'rgba(255, 255, 255, 0.12)',\n background: {\n paper: '#121212',\n default: '#121212'\n },\n action: {\n active: common.white,\n hover: 'rgba(255, 255, 255, 0.08)',\n hoverOpacity: 0.08,\n selected: 'rgba(255, 255, 255, 0.16)',\n selectedOpacity: 0.16,\n disabled: 'rgba(255, 255, 255, 0.3)',\n disabledBackground: 'rgba(255, 255, 255, 0.12)',\n disabledOpacity: 0.38,\n focus: 'rgba(255, 255, 255, 0.12)',\n focusOpacity: 0.12,\n activatedOpacity: 0.24\n }\n};\nfunction addLightOrDark(intent, direction, shade, tonalOffset) {\n const tonalOffsetLight = tonalOffset.light || tonalOffset;\n const tonalOffsetDark = tonalOffset.dark || tonalOffset * 1.5;\n if (!intent[direction]) {\n if (intent.hasOwnProperty(shade)) {\n intent[direction] = intent[shade];\n } else if (direction === 'light') {\n intent.light = lighten(intent.main, tonalOffsetLight);\n } else if (direction === 'dark') {\n intent.dark = darken(intent.main, tonalOffsetDark);\n }\n }\n}\nfunction getDefaultPrimary(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: blue[200],\n light: blue[50],\n dark: blue[400]\n };\n }\n return {\n main: blue[700],\n light: blue[400],\n dark: blue[800]\n };\n}\nfunction getDefaultSecondary(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: purple[200],\n light: purple[50],\n dark: purple[400]\n };\n }\n return {\n main: purple[500],\n light: purple[300],\n dark: purple[700]\n };\n}\nfunction getDefaultError(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: red[500],\n light: red[300],\n dark: red[700]\n };\n }\n return {\n main: red[700],\n light: red[400],\n dark: red[800]\n };\n}\nfunction getDefaultInfo(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: lightBlue[400],\n light: lightBlue[300],\n dark: lightBlue[700]\n };\n }\n return {\n main: lightBlue[700],\n light: lightBlue[500],\n dark: lightBlue[900]\n };\n}\nfunction getDefaultSuccess(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: green[400],\n light: green[300],\n dark: green[700]\n };\n }\n return {\n main: green[800],\n light: green[500],\n dark: green[900]\n };\n}\nfunction getDefaultWarning(mode = 'light') {\n if (mode === 'dark') {\n return {\n main: orange[400],\n light: orange[300],\n dark: orange[700]\n };\n }\n return {\n main: '#ed6c02',\n // closest to orange[800] that pass 3:1.\n light: orange[500],\n dark: orange[900]\n };\n}\nexport default function createPalette(palette) {\n const {\n mode = 'light',\n contrastThreshold = 3,\n tonalOffset = 0.2\n } = palette,\n other = _objectWithoutPropertiesLoose(palette, _excluded);\n const primary = palette.primary || getDefaultPrimary(mode);\n const secondary = palette.secondary || getDefaultSecondary(mode);\n const error = palette.error || getDefaultError(mode);\n const info = palette.info || getDefaultInfo(mode);\n const success = palette.success || getDefaultSuccess(mode);\n const warning = palette.warning || getDefaultWarning(mode);\n\n // Use the same logic as\n // Bootstrap: https://github.com/twbs/bootstrap/blob/1d6e3710dd447de1a200f29e8fa521f8a0908f70/scss/_functions.scss#L59\n // and material-components-web https://github.com/material-components/material-components-web/blob/ac46b8863c4dab9fc22c4c662dc6bd1b65dd652f/packages/mdc-theme/_functions.scss#L54\n function getContrastText(background) {\n const contrastText = getContrastRatio(background, dark.text.primary) >= contrastThreshold ? dark.text.primary : light.text.primary;\n if (process.env.NODE_ENV !== 'production') {\n const contrast = getContrastRatio(background, contrastText);\n if (contrast < 3) {\n console.error([`MUI: The contrast ratio of ${contrast}:1 for ${contrastText} on ${background}`, 'falls below the WCAG recommended absolute minimum contrast ratio of 3:1.', 'https://www.w3.org/TR/2008/REC-WCAG20-20081211/#visual-audio-contrast-contrast'].join('\\n'));\n }\n }\n return contrastText;\n }\n const augmentColor = ({\n color,\n name,\n mainShade = 500,\n lightShade = 300,\n darkShade = 700\n }) => {\n color = _extends({}, color);\n if (!color.main && color[mainShade]) {\n color.main = color[mainShade];\n }\n if (!color.hasOwnProperty('main')) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: The color${name ? ` (${name})` : ''} provided to augmentColor(color) is invalid.\nThe color object needs to have a \\`main\\` property or a \\`${mainShade}\\` property.` : _formatMuiErrorMessage(11, name ? ` (${name})` : '', mainShade));\n }\n if (typeof color.main !== 'string') {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: The color${name ? ` (${name})` : ''} provided to augmentColor(color) is invalid.\n\\`color.main\\` should be a string, but \\`${JSON.stringify(color.main)}\\` was provided instead.\n\nDid you intend to use one of the following approaches?\n\nimport { green } from \"@mui/material/colors\";\n\nconst theme1 = createTheme({ palette: {\n primary: green,\n} });\n\nconst theme2 = createTheme({ palette: {\n primary: { main: green[500] },\n} });` : _formatMuiErrorMessage(12, name ? ` (${name})` : '', JSON.stringify(color.main)));\n }\n addLightOrDark(color, 'light', lightShade, tonalOffset);\n addLightOrDark(color, 'dark', darkShade, tonalOffset);\n if (!color.contrastText) {\n color.contrastText = getContrastText(color.main);\n }\n return color;\n };\n const modes = {\n dark,\n light\n };\n if (process.env.NODE_ENV !== 'production') {\n if (!modes[mode]) {\n console.error(`MUI: The palette mode \\`${mode}\\` is not supported.`);\n }\n }\n const paletteOutput = deepmerge(_extends({\n // A collection of common colors.\n common: _extends({}, common),\n // prevent mutable object.\n // The palette mode, can be light or dark.\n mode,\n // The colors used to represent primary interface elements for a user.\n primary: augmentColor({\n color: primary,\n name: 'primary'\n }),\n // The colors used to represent secondary interface elements for a user.\n secondary: augmentColor({\n color: secondary,\n name: 'secondary',\n mainShade: 'A400',\n lightShade: 'A200',\n darkShade: 'A700'\n }),\n // The colors used to represent interface elements that the user should be made aware of.\n error: augmentColor({\n color: error,\n name: 'error'\n }),\n // The colors used to represent potentially dangerous actions or important messages.\n warning: augmentColor({\n color: warning,\n name: 'warning'\n }),\n // The colors used to present information to the user that is neutral and not necessarily important.\n info: augmentColor({\n color: info,\n name: 'info'\n }),\n // The colors used to indicate the successful completion of an action that user triggered.\n success: augmentColor({\n color: success,\n name: 'success'\n }),\n // The grey colors.\n grey,\n // Used by `getContrastText()` to maximize the contrast between\n // the background and the text.\n contrastThreshold,\n // Takes a background color and returns the text color that maximizes the contrast.\n getContrastText,\n // Generate a rich color object.\n augmentColor,\n // Used by the functions below to shift a color's luminance by approximately\n // two indexes within its tonal palette.\n // E.g., shift from Red 500 to Red 300 or Red 700.\n tonalOffset\n }, modes[mode]), other);\n return paletteOutput;\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"fontFamily\", \"fontSize\", \"fontWeightLight\", \"fontWeightRegular\", \"fontWeightMedium\", \"fontWeightBold\", \"htmlFontSize\", \"allVariants\", \"pxToRem\"];\nimport { deepmerge } from '@mui/utils';\nfunction round(value) {\n return Math.round(value * 1e5) / 1e5;\n}\nconst caseAllCaps = {\n textTransform: 'uppercase'\n};\nconst defaultFontFamily = '\"Roboto\", \"Helvetica\", \"Arial\", sans-serif';\n\n/**\n * @see @link{https://m2.material.io/design/typography/the-type-system.html}\n * @see @link{https://m2.material.io/design/typography/understanding-typography.html}\n */\nexport default function createTypography(palette, typography) {\n const _ref = typeof typography === 'function' ? typography(palette) : typography,\n {\n fontFamily = defaultFontFamily,\n // The default font size of the Material Specification.\n fontSize = 14,\n // px\n fontWeightLight = 300,\n fontWeightRegular = 400,\n fontWeightMedium = 500,\n fontWeightBold = 700,\n // Tell MUI what's the font-size on the html element.\n // 16px is the default font-size used by browsers.\n htmlFontSize = 16,\n // Apply the CSS properties to all the variants.\n allVariants,\n pxToRem: pxToRem2\n } = _ref,\n other = _objectWithoutPropertiesLoose(_ref, _excluded);\n if (process.env.NODE_ENV !== 'production') {\n if (typeof fontSize !== 'number') {\n console.error('MUI: `fontSize` is required to be a number.');\n }\n if (typeof htmlFontSize !== 'number') {\n console.error('MUI: `htmlFontSize` is required to be a number.');\n }\n }\n const coef = fontSize / 14;\n const pxToRem = pxToRem2 || (size => `${size / htmlFontSize * coef}rem`);\n const buildVariant = (fontWeight, size, lineHeight, letterSpacing, casing) => _extends({\n fontFamily,\n fontWeight,\n fontSize: pxToRem(size),\n // Unitless following https://meyerweb.com/eric/thoughts/2006/02/08/unitless-line-heights/\n lineHeight\n }, fontFamily === defaultFontFamily ? {\n letterSpacing: `${round(letterSpacing / size)}em`\n } : {}, casing, allVariants);\n const variants = {\n h1: buildVariant(fontWeightLight, 96, 1.167, -1.5),\n h2: buildVariant(fontWeightLight, 60, 1.2, -0.5),\n h3: buildVariant(fontWeightRegular, 48, 1.167, 0),\n h4: buildVariant(fontWeightRegular, 34, 1.235, 0.25),\n h5: buildVariant(fontWeightRegular, 24, 1.334, 0),\n h6: buildVariant(fontWeightMedium, 20, 1.6, 0.15),\n subtitle1: buildVariant(fontWeightRegular, 16, 1.75, 0.15),\n subtitle2: buildVariant(fontWeightMedium, 14, 1.57, 0.1),\n body1: buildVariant(fontWeightRegular, 16, 1.5, 0.15),\n body2: buildVariant(fontWeightRegular, 14, 1.43, 0.15),\n button: buildVariant(fontWeightMedium, 14, 1.75, 0.4, caseAllCaps),\n caption: buildVariant(fontWeightRegular, 12, 1.66, 0.4),\n overline: buildVariant(fontWeightRegular, 12, 2.66, 1, caseAllCaps),\n // TODO v6: Remove handling of 'inherit' variant from the theme as it is already handled in Material UI's Typography component. Also, remember to remove the associated types.\n inherit: {\n fontFamily: 'inherit',\n fontWeight: 'inherit',\n fontSize: 'inherit',\n lineHeight: 'inherit',\n letterSpacing: 'inherit'\n }\n };\n return deepmerge(_extends({\n htmlFontSize,\n pxToRem,\n fontFamily,\n fontSize,\n fontWeightLight,\n fontWeightRegular,\n fontWeightMedium,\n fontWeightBold\n }, variants), other, {\n clone: false // No need to clone deep\n });\n}","const shadowKeyUmbraOpacity = 0.2;\nconst shadowKeyPenumbraOpacity = 0.14;\nconst shadowAmbientShadowOpacity = 0.12;\nfunction createShadow(...px) {\n return [`${px[0]}px ${px[1]}px ${px[2]}px ${px[3]}px rgba(0,0,0,${shadowKeyUmbraOpacity})`, `${px[4]}px ${px[5]}px ${px[6]}px ${px[7]}px rgba(0,0,0,${shadowKeyPenumbraOpacity})`, `${px[8]}px ${px[9]}px ${px[10]}px ${px[11]}px rgba(0,0,0,${shadowAmbientShadowOpacity})`].join(',');\n}\n\n// Values from https://github.com/material-components/material-components-web/blob/be8747f94574669cb5e7add1a7c54fa41a89cec7/packages/mdc-elevation/_variables.scss\nconst shadows = ['none', createShadow(0, 2, 1, -1, 0, 1, 1, 0, 0, 1, 3, 0), createShadow(0, 3, 1, -2, 0, 2, 2, 0, 0, 1, 5, 0), createShadow(0, 3, 3, -2, 0, 3, 4, 0, 0, 1, 8, 0), createShadow(0, 2, 4, -1, 0, 4, 5, 0, 0, 1, 10, 0), createShadow(0, 3, 5, -1, 0, 5, 8, 0, 0, 1, 14, 0), createShadow(0, 3, 5, -1, 0, 6, 10, 0, 0, 1, 18, 0), createShadow(0, 4, 5, -2, 0, 7, 10, 1, 0, 2, 16, 1), createShadow(0, 5, 5, -3, 0, 8, 10, 1, 0, 3, 14, 2), createShadow(0, 5, 6, -3, 0, 9, 12, 1, 0, 3, 16, 2), createShadow(0, 6, 6, -3, 0, 10, 14, 1, 0, 4, 18, 3), createShadow(0, 6, 7, -4, 0, 11, 15, 1, 0, 4, 20, 3), createShadow(0, 7, 8, -4, 0, 12, 17, 2, 0, 5, 22, 4), createShadow(0, 7, 8, -4, 0, 13, 19, 2, 0, 5, 24, 4), createShadow(0, 7, 9, -4, 0, 14, 21, 2, 0, 5, 26, 4), createShadow(0, 8, 9, -5, 0, 15, 22, 2, 0, 6, 28, 5), createShadow(0, 8, 10, -5, 0, 16, 24, 2, 0, 6, 30, 5), createShadow(0, 8, 11, -5, 0, 17, 26, 2, 0, 6, 32, 5), createShadow(0, 9, 11, -5, 0, 18, 28, 2, 0, 7, 34, 6), createShadow(0, 9, 12, -6, 0, 19, 29, 2, 0, 7, 36, 6), createShadow(0, 10, 13, -6, 0, 20, 31, 3, 0, 8, 38, 7), createShadow(0, 10, 13, -6, 0, 21, 33, 3, 0, 8, 40, 7), createShadow(0, 10, 14, -6, 0, 22, 35, 3, 0, 8, 42, 7), createShadow(0, 11, 14, -7, 0, 23, 36, 3, 0, 9, 44, 8), createShadow(0, 11, 15, -7, 0, 24, 38, 3, 0, 9, 46, 8)];\nexport default shadows;","import _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nconst _excluded = [\"duration\", \"easing\", \"delay\"];\n// Follow https://material.google.com/motion/duration-easing.html#duration-easing-natural-easing-curves\n// to learn the context in which each easing should be used.\nexport const easing = {\n // This is the most common easing curve.\n easeInOut: 'cubic-bezier(0.4, 0, 0.2, 1)',\n // Objects enter the screen at full velocity from off-screen and\n // slowly decelerate to a resting point.\n easeOut: 'cubic-bezier(0.0, 0, 0.2, 1)',\n // Objects leave the screen at full velocity. They do not decelerate when off-screen.\n easeIn: 'cubic-bezier(0.4, 0, 1, 1)',\n // The sharp curve is used by objects that may return to the screen at any time.\n sharp: 'cubic-bezier(0.4, 0, 0.6, 1)'\n};\n\n// Follow https://m2.material.io/guidelines/motion/duration-easing.html#duration-easing-common-durations\n// to learn when use what timing\nexport const duration = {\n shortest: 150,\n shorter: 200,\n short: 250,\n // most basic recommended timing\n standard: 300,\n // this is to be used in complex animations\n complex: 375,\n // recommended when something is entering screen\n enteringScreen: 225,\n // recommended when something is leaving screen\n leavingScreen: 195\n};\nfunction formatMs(milliseconds) {\n return `${Math.round(milliseconds)}ms`;\n}\nfunction getAutoHeightDuration(height) {\n if (!height) {\n return 0;\n }\n const constant = height / 36;\n\n // https://www.wolframalpha.com/input/?i=(4+%2B+15+*+(x+%2F+36+)+**+0.25+%2B+(x+%2F+36)+%2F+5)+*+10\n return Math.round((4 + 15 * constant ** 0.25 + constant / 5) * 10);\n}\nexport default function createTransitions(inputTransitions) {\n const mergedEasing = _extends({}, easing, inputTransitions.easing);\n const mergedDuration = _extends({}, duration, inputTransitions.duration);\n const create = (props = ['all'], options = {}) => {\n const {\n duration: durationOption = mergedDuration.standard,\n easing: easingOption = mergedEasing.easeInOut,\n delay = 0\n } = options,\n other = _objectWithoutPropertiesLoose(options, _excluded);\n if (process.env.NODE_ENV !== 'production') {\n const isString = value => typeof value === 'string';\n // IE11 support, replace with Number.isNaN\n // eslint-disable-next-line no-restricted-globals\n const isNumber = value => !isNaN(parseFloat(value));\n if (!isString(props) && !Array.isArray(props)) {\n console.error('MUI: Argument \"props\" must be a string or Array.');\n }\n if (!isNumber(durationOption) && !isString(durationOption)) {\n console.error(`MUI: Argument \"duration\" must be a number or a string but found ${durationOption}.`);\n }\n if (!isString(easingOption)) {\n console.error('MUI: Argument \"easing\" must be a string.');\n }\n if (!isNumber(delay) && !isString(delay)) {\n console.error('MUI: Argument \"delay\" must be a number or a string.');\n }\n if (typeof options !== 'object') {\n console.error(['MUI: Secong argument of transition.create must be an object.', \"Arguments should be either `create('prop1', options)` or `create(['prop1', 'prop2'], options)`\"].join('\\n'));\n }\n if (Object.keys(other).length !== 0) {\n console.error(`MUI: Unrecognized argument(s) [${Object.keys(other).join(',')}].`);\n }\n }\n return (Array.isArray(props) ? props : [props]).map(animatedProp => `${animatedProp} ${typeof durationOption === 'string' ? durationOption : formatMs(durationOption)} ${easingOption} ${typeof delay === 'string' ? delay : formatMs(delay)}`).join(',');\n };\n return _extends({\n getAutoHeightDuration,\n create\n }, inputTransitions, {\n easing: mergedEasing,\n duration: mergedDuration\n });\n}","// We need to centralize the zIndex definitions as they work\n// like global values in the browser.\nconst zIndex = {\n mobileStepper: 1000,\n fab: 1050,\n speedDial: 1050,\n appBar: 1100,\n drawer: 1200,\n modal: 1300,\n snackbar: 1400,\n tooltip: 1500\n};\nexport default zIndex;","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\nconst _excluded = [\"breakpoints\", \"mixins\", \"spacing\", \"palette\", \"transitions\", \"typography\", \"shape\"];\nimport { deepmerge } from '@mui/utils';\nimport { createTheme as systemCreateTheme, unstable_defaultSxConfig as defaultSxConfig, unstable_styleFunctionSx as styleFunctionSx } from '@mui/system';\nimport generateUtilityClass from '@mui/utils/generateUtilityClass';\nimport createMixins from './createMixins';\nimport createPalette from './createPalette';\nimport createTypography from './createTypography';\nimport shadows from './shadows';\nimport createTransitions from './createTransitions';\nimport zIndex from './zIndex';\nfunction createTheme(options = {}, ...args) {\n const {\n mixins: mixinsInput = {},\n palette: paletteInput = {},\n transitions: transitionsInput = {},\n typography: typographyInput = {}\n } = options,\n other = _objectWithoutPropertiesLoose(options, _excluded);\n if (options.vars) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: \\`vars\\` is a private field used for CSS variables support.\nPlease use another name.` : _formatMuiErrorMessage(18));\n }\n const palette = createPalette(paletteInput);\n const systemTheme = systemCreateTheme(options);\n let muiTheme = deepmerge(systemTheme, {\n mixins: createMixins(systemTheme.breakpoints, mixinsInput),\n palette,\n // Don't use [...shadows] until you've verified its transpiled code is not invoking the iterator protocol.\n shadows: shadows.slice(),\n typography: createTypography(palette, typographyInput),\n transitions: createTransitions(transitionsInput),\n zIndex: _extends({}, zIndex)\n });\n muiTheme = deepmerge(muiTheme, other);\n muiTheme = args.reduce((acc, argument) => deepmerge(acc, argument), muiTheme);\n if (process.env.NODE_ENV !== 'production') {\n // TODO v6: Refactor to use globalStateClassesMapping from @mui/utils once `readOnly` state class is used in Rating component.\n const stateClasses = ['active', 'checked', 'completed', 'disabled', 'error', 'expanded', 'focused', 'focusVisible', 'required', 'selected'];\n const traverse = (node, component) => {\n let key;\n\n // eslint-disable-next-line guard-for-in, no-restricted-syntax\n for (key in node) {\n const child = node[key];\n if (stateClasses.indexOf(key) !== -1 && Object.keys(child).length > 0) {\n if (process.env.NODE_ENV !== 'production') {\n const stateClass = generateUtilityClass('', key);\n console.error([`MUI: The \\`${component}\\` component increases ` + `the CSS specificity of the \\`${key}\\` internal state.`, 'You can not override it like this: ', JSON.stringify(node, null, 2), '', `Instead, you need to use the '&.${stateClass}' syntax:`, JSON.stringify({\n root: {\n [`&.${stateClass}`]: child\n }\n }, null, 2), '', 'https://mui.com/r/state-classes-guide'].join('\\n'));\n }\n // Remove the style to prevent global conflicts.\n node[key] = {};\n }\n }\n };\n Object.keys(muiTheme.components).forEach(component => {\n const styleOverrides = muiTheme.components[component].styleOverrides;\n if (styleOverrides && component.indexOf('Mui') === 0) {\n traverse(styleOverrides, component);\n }\n });\n }\n muiTheme.unstable_sxConfig = _extends({}, defaultSxConfig, other == null ? void 0 : other.unstable_sxConfig);\n muiTheme.unstable_sx = function sx(props) {\n return styleFunctionSx({\n sx: props,\n theme: this\n });\n };\n return muiTheme;\n}\nlet warnedOnce = false;\nexport function createMuiTheme(...args) {\n if (process.env.NODE_ENV !== 'production') {\n if (!warnedOnce) {\n warnedOnce = true;\n console.error(['MUI: the createMuiTheme function was renamed to createTheme.', '', \"You should use `import { createTheme } from '@mui/material/styles'`\"].join('\\n'));\n }\n }\n return createTheme(...args);\n}\nexport default createTheme;","'use client';\n\nimport createTheme from './createTheme';\nconst defaultTheme = createTheme();\nexport default defaultTheme;","export default '$$material';","'use client';\n\nimport { useThemeProps as systemUseThemeProps } from '@mui/system';\nimport defaultTheme from './defaultTheme';\nimport THEME_ID from './identifier';\nexport default function useThemeProps({\n props,\n name\n}) {\n return systemUseThemeProps({\n props,\n name,\n defaultTheme,\n themeId: THEME_ID\n });\n}","'use client';\n\nimport { createStyled, shouldForwardProp } from '@mui/system';\nimport defaultTheme from './defaultTheme';\nimport THEME_ID from './identifier';\nexport const rootShouldForwardProp = prop => shouldForwardProp(prop) && prop !== 'classes';\nexport const slotShouldForwardProp = shouldForwardProp;\nconst styled = createStyled({\n themeId: THEME_ID,\n defaultTheme,\n rootShouldForwardProp\n});\nexport default styled;","import generateUtilityClasses from '@mui/utils/generateUtilityClasses';\nimport generateUtilityClass from '@mui/utils/generateUtilityClass';\nexport function getSvgIconUtilityClass(slot) {\n return generateUtilityClass('MuiSvgIcon', slot);\n}\nconst svgIconClasses = generateUtilityClasses('MuiSvgIcon', ['root', 'colorPrimary', 'colorSecondary', 'colorAction', 'colorError', 'colorDisabled', 'fontSizeInherit', 'fontSizeSmall', 'fontSizeMedium', 'fontSizeLarge']);\nexport default svgIconClasses;","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"children\", \"className\", \"color\", \"component\", \"fontSize\", \"htmlColor\", \"inheritViewBox\", \"titleAccess\", \"viewBox\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport clsx from 'clsx';\nimport { unstable_composeClasses as composeClasses } from '@mui/base/composeClasses';\nimport capitalize from '../utils/capitalize';\nimport useThemeProps from '../styles/useThemeProps';\nimport styled from '../styles/styled';\nimport { getSvgIconUtilityClass } from './svgIconClasses';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nimport { jsxs as _jsxs } from \"react/jsx-runtime\";\nconst useUtilityClasses = ownerState => {\n const {\n color,\n fontSize,\n classes\n } = ownerState;\n const slots = {\n root: ['root', color !== 'inherit' && `color${capitalize(color)}`, `fontSize${capitalize(fontSize)}`]\n };\n return composeClasses(slots, getSvgIconUtilityClass, classes);\n};\nconst SvgIconRoot = styled('svg', {\n name: 'MuiSvgIcon',\n slot: 'Root',\n overridesResolver: (props, styles) => {\n const {\n ownerState\n } = props;\n return [styles.root, ownerState.color !== 'inherit' && styles[`color${capitalize(ownerState.color)}`], styles[`fontSize${capitalize(ownerState.fontSize)}`]];\n }\n})(({\n theme,\n ownerState\n}) => {\n var _theme$transitions, _theme$transitions$cr, _theme$transitions2, _theme$typography, _theme$typography$pxT, _theme$typography2, _theme$typography2$px, _theme$typography3, _theme$typography3$px, _palette$ownerState$c, _palette, _palette2, _palette3;\n return {\n userSelect: 'none',\n width: '1em',\n height: '1em',\n display: 'inline-block',\n // the will define the property that has `currentColor`\n // e.g. heroicons uses fill=\"none\" and stroke=\"currentColor\"\n fill: ownerState.hasSvgAsChild ? undefined : 'currentColor',\n flexShrink: 0,\n transition: (_theme$transitions = theme.transitions) == null || (_theme$transitions$cr = _theme$transitions.create) == null ? void 0 : _theme$transitions$cr.call(_theme$transitions, 'fill', {\n duration: (_theme$transitions2 = theme.transitions) == null || (_theme$transitions2 = _theme$transitions2.duration) == null ? void 0 : _theme$transitions2.shorter\n }),\n fontSize: {\n inherit: 'inherit',\n small: ((_theme$typography = theme.typography) == null || (_theme$typography$pxT = _theme$typography.pxToRem) == null ? void 0 : _theme$typography$pxT.call(_theme$typography, 20)) || '1.25rem',\n medium: ((_theme$typography2 = theme.typography) == null || (_theme$typography2$px = _theme$typography2.pxToRem) == null ? void 0 : _theme$typography2$px.call(_theme$typography2, 24)) || '1.5rem',\n large: ((_theme$typography3 = theme.typography) == null || (_theme$typography3$px = _theme$typography3.pxToRem) == null ? void 0 : _theme$typography3$px.call(_theme$typography3, 35)) || '2.1875rem'\n }[ownerState.fontSize],\n // TODO v5 deprecate, v6 remove for sx\n color: (_palette$ownerState$c = (_palette = (theme.vars || theme).palette) == null || (_palette = _palette[ownerState.color]) == null ? void 0 : _palette.main) != null ? _palette$ownerState$c : {\n action: (_palette2 = (theme.vars || theme).palette) == null || (_palette2 = _palette2.action) == null ? void 0 : _palette2.active,\n disabled: (_palette3 = (theme.vars || theme).palette) == null || (_palette3 = _palette3.action) == null ? void 0 : _palette3.disabled,\n inherit: undefined\n }[ownerState.color]\n };\n});\nconst SvgIcon = /*#__PURE__*/React.forwardRef(function SvgIcon(inProps, ref) {\n const props = useThemeProps({\n props: inProps,\n name: 'MuiSvgIcon'\n });\n const {\n children,\n className,\n color = 'inherit',\n component = 'svg',\n fontSize = 'medium',\n htmlColor,\n inheritViewBox = false,\n titleAccess,\n viewBox = '0 0 24 24'\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const hasSvgAsChild = /*#__PURE__*/React.isValidElement(children) && children.type === 'svg';\n const ownerState = _extends({}, props, {\n color,\n component,\n fontSize,\n instanceFontSize: inProps.fontSize,\n inheritViewBox,\n viewBox,\n hasSvgAsChild\n });\n const more = {};\n if (!inheritViewBox) {\n more.viewBox = viewBox;\n }\n const classes = useUtilityClasses(ownerState);\n return /*#__PURE__*/_jsxs(SvgIconRoot, _extends({\n as: component,\n className: clsx(classes.root, className),\n focusable: \"false\",\n color: htmlColor,\n \"aria-hidden\": titleAccess ? undefined : true,\n role: titleAccess ? 'img' : undefined,\n ref: ref\n }, more, other, hasSvgAsChild && children.props, {\n ownerState: ownerState,\n children: [hasSvgAsChild ? children.props.children : children, titleAccess ? /*#__PURE__*/_jsx(\"title\", {\n children: titleAccess\n }) : null]\n }));\n});\nprocess.env.NODE_ENV !== \"production\" ? SvgIcon.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the d.ts file and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * Node passed into the SVG element.\n */\n children: PropTypes.node,\n /**\n * Override or extend the styles applied to the component.\n */\n classes: PropTypes.object,\n /**\n * @ignore\n */\n className: PropTypes.string,\n /**\n * The color of the component.\n * It supports both default and custom theme colors, which can be added as shown in the\n * [palette customization guide](https://mui.com/material-ui/customization/palette/#custom-colors).\n * You can use the `htmlColor` prop to apply a color attribute to the SVG element.\n * @default 'inherit'\n */\n color: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.oneOf(['inherit', 'action', 'disabled', 'primary', 'secondary', 'error', 'info', 'success', 'warning']), PropTypes.string]),\n /**\n * The component used for the root node.\n * Either a string to use a HTML element or a component.\n */\n component: PropTypes.elementType,\n /**\n * The fontSize applied to the icon. Defaults to 24px, but can be configure to inherit font size.\n * @default 'medium'\n */\n fontSize: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.oneOf(['inherit', 'large', 'medium', 'small']), PropTypes.string]),\n /**\n * Applies a color attribute to the SVG element.\n */\n htmlColor: PropTypes.string,\n /**\n * If `true`, the root node will inherit the custom `component`'s viewBox and the `viewBox`\n * prop will be ignored.\n * Useful when you want to reference a custom `component` and have `SvgIcon` pass that\n * `component`'s viewBox to the root node.\n * @default false\n */\n inheritViewBox: PropTypes.bool,\n /**\n * The shape-rendering attribute. The behavior of the different options is described on the\n * [MDN Web Docs](https://developer.mozilla.org/en-US/docs/Web/SVG/Attribute/shape-rendering).\n * If you are having issues with blurry icons you should investigate this prop.\n */\n shapeRendering: PropTypes.string,\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Provides a human-readable title for the element that contains it.\n * https://www.w3.org/TR/SVG-access/#Equivalent\n */\n titleAccess: PropTypes.string,\n /**\n * Allows you to redefine what the coordinates without units mean inside an SVG element.\n * For example, if the SVG element is 500 (width) by 200 (height),\n * and you pass viewBox=\"0 0 50 20\",\n * this means that the coordinates inside the SVG will go from the top left corner (0,0)\n * to bottom right (50,20) and each unit will be worth 10px.\n * @default '0 0 24 24'\n */\n viewBox: PropTypes.string\n} : void 0;\nSvgIcon.muiName = 'SvgIcon';\nexport default SvgIcon;","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport * as React from 'react';\nimport SvgIcon from '../SvgIcon';\n\n/**\n * Private module reserved for @mui packages.\n */\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nexport default function createSvgIcon(path, displayName) {\n function Component(props, ref) {\n return /*#__PURE__*/_jsx(SvgIcon, _extends({\n \"data-testid\": `${displayName}Icon`,\n ref: ref\n }, props, {\n children: path\n }));\n }\n if (process.env.NODE_ENV !== 'production') {\n // Need to set `displayName` on the inner component for React.memo.\n // React prior to 16.14 ignores `displayName` on the wrapper.\n Component.displayName = `${displayName}Icon`;\n }\n Component.muiName = SvgIcon.muiName;\n return /*#__PURE__*/React.memo( /*#__PURE__*/React.forwardRef(Component));\n}","'use client';\n\nimport { unstable_ClassNameGenerator as ClassNameGenerator } from '@mui/base/ClassNameGenerator';\nexport { default as capitalize } from './capitalize';\nexport { default as createChainedFunction } from './createChainedFunction';\nexport { default as createSvgIcon } from './createSvgIcon';\nexport { default as debounce } from './debounce';\nexport { default as deprecatedPropType } from './deprecatedPropType';\nexport { default as isMuiElement } from './isMuiElement';\nexport { default as ownerDocument } from './ownerDocument';\nexport { default as ownerWindow } from './ownerWindow';\nexport { default as requirePropFactory } from './requirePropFactory';\nexport { default as setRef } from './setRef';\nexport { default as unstable_useEnhancedEffect } from './useEnhancedEffect';\nexport { default as unstable_useId } from './useId';\nexport { default as unsupportedProp } from './unsupportedProp';\nexport { default as useControlled } from './useControlled';\nexport { default as useEventCallback } from './useEventCallback';\nexport { default as useForkRef } from './useForkRef';\nexport { default as useIsFocusVisible } from './useIsFocusVisible';\n// TODO: remove this export once ClassNameGenerator is stable\n// eslint-disable-next-line @typescript-eslint/naming-convention\nexport const unstable_ClassNameGenerator = {\n configure: generator => {\n if (process.env.NODE_ENV !== 'production') {\n console.warn(['MUI: `ClassNameGenerator` import from `@mui/material/utils` is outdated and might cause unexpected issues.', '', \"You should use `import { unstable_ClassNameGenerator } from '@mui/material/className'` instead\", '', 'The detail of the issue: https://github.com/mui/material-ui/issues/30011#issuecomment-1024993401', '', 'The updated documentation: https://mui.com/guides/classname-generator/'].join('\\n'));\n }\n ClassNameGenerator.configure(generator);\n }\n};","\"use strict\";\n'use client';\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nObject.defineProperty(exports, \"default\", {\n enumerable: true,\n get: function () {\n return _utils.createSvgIcon;\n }\n});\nvar _utils = require(\"@mui/material/utils\");","\"use strict\";\n\"use client\";\n\nvar _interopRequireDefault = require(\"@babel/runtime/helpers/interopRequireDefault\");\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = void 0;\nvar _createSvgIcon = _interopRequireDefault(require(\"./utils/createSvgIcon\"));\nvar _jsxRuntime = require(\"react/jsx-runtime\");\nvar _default = exports.default = (0, _createSvgIcon.default)( /*#__PURE__*/(0, _jsxRuntime.jsx)(\"path\", {\n d: \"m10 17 5-5-5-5z\"\n}), 'ArrowRight');","/**\n * Determines if a given element is a DOM element name (i.e. not a React component).\n */\nexport function isHostComponent(element) {\n return typeof element === 'string';\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport { isHostComponent } from './isHostComponent';\n\n/**\n * Type of the ownerState based on the type of an element it applies to.\n * This resolves to the provided OwnerState for React components and `undefined` for host components.\n * Falls back to `OwnerState | undefined` when the exact type can't be determined in development time.\n */\n\n/**\n * Appends the ownerState object to the props, merging with the existing one if necessary.\n *\n * @param elementType Type of the element that owns the `existingProps`. If the element is a DOM node or undefined, `ownerState` is not applied.\n * @param otherProps Props of the element.\n * @param ownerState\n */\nexport function appendOwnerState(elementType, otherProps, ownerState) {\n if (elementType === undefined || isHostComponent(elementType)) {\n return otherProps;\n }\n return _extends({}, otherProps, {\n ownerState: _extends({}, otherProps.ownerState, ownerState)\n });\n}","'use client';\n\nimport * as React from 'react';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nconst defaultContextValue = {\n disableDefaultClasses: false\n};\nconst ClassNameConfiguratorContext = /*#__PURE__*/React.createContext(defaultContextValue);\n/**\n * @ignore - internal hook.\n *\n * Wraps the `generateUtilityClass` function and controls how the classes are generated.\n * Currently it only affects whether the classes are applied or not.\n *\n * @returns Function to be called with the `generateUtilityClass` function specific to a component to generate the classes.\n */\nexport function useClassNamesOverride(generateUtilityClass) {\n const {\n disableDefaultClasses\n } = React.useContext(ClassNameConfiguratorContext);\n return slot => {\n if (disableDefaultClasses) {\n return '';\n }\n return generateUtilityClass(slot);\n };\n}\n\n/**\n * Allows to configure the components within to not apply any built-in classes.\n */\nexport function ClassNameConfigurator(props) {\n const {\n disableDefaultClasses,\n children\n } = props;\n const contextValue = React.useMemo(() => ({\n disableDefaultClasses: disableDefaultClasses != null ? disableDefaultClasses : false\n }), [disableDefaultClasses]);\n return /*#__PURE__*/_jsx(ClassNameConfiguratorContext.Provider, {\n value: contextValue,\n children: children\n });\n}","/**\n * Extracts event handlers from a given object.\n * A prop is considered an event handler if it is a function and its name starts with `on`.\n *\n * @param object An object to extract event handlers from.\n * @param excludeKeys An array of keys to exclude from the returned object.\n */\nexport function extractEventHandlers(object, excludeKeys = []) {\n if (object === undefined) {\n return {};\n }\n const result = {};\n Object.keys(object).filter(prop => prop.match(/^on[A-Z]/) && typeof object[prop] === 'function' && !excludeKeys.includes(prop)).forEach(prop => {\n result[prop] = object[prop];\n });\n return result;\n}","/**\n * If `componentProps` is a function, calls it with the provided `ownerState`.\n * Otherwise, just returns `componentProps`.\n */\nexport function resolveComponentProps(componentProps, ownerState, slotState) {\n if (typeof componentProps === 'function') {\n return componentProps(ownerState, slotState);\n }\n return componentProps;\n}","/**\n * Removes event handlers from the given object.\n * A field is considered an event handler if it is a function with a name beginning with `on`.\n *\n * @param object Object to remove event handlers from.\n * @returns Object with event handlers removed.\n */\nexport function omitEventHandlers(object) {\n if (object === undefined) {\n return {};\n }\n const result = {};\n Object.keys(object).filter(prop => !(prop.match(/^on[A-Z]/) && typeof object[prop] === 'function')).forEach(prop => {\n result[prop] = object[prop];\n });\n return result;\n}","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport clsx from 'clsx';\nimport { extractEventHandlers } from './extractEventHandlers';\nimport { omitEventHandlers } from './omitEventHandlers';\n/**\n * Merges the slot component internal props (usually coming from a hook)\n * with the externally provided ones.\n *\n * The merge order is (the latter overrides the former):\n * 1. The internal props (specified as a getter function to work with get*Props hook result)\n * 2. Additional props (specified internally on a Base UI component)\n * 3. External props specified on the owner component. These should only be used on a root slot.\n * 4. External props specified in the `slotProps.*` prop.\n * 5. The `className` prop - combined from all the above.\n * @param parameters\n * @returns\n */\nexport function mergeSlotProps(parameters) {\n const {\n getSlotProps,\n additionalProps,\n externalSlotProps,\n externalForwardedProps,\n className\n } = parameters;\n if (!getSlotProps) {\n // The simpler case - getSlotProps is not defined, so no internal event handlers are defined,\n // so we can simply merge all the props without having to worry about extracting event handlers.\n const joinedClasses = clsx(additionalProps == null ? void 0 : additionalProps.className, className, externalForwardedProps == null ? void 0 : externalForwardedProps.className, externalSlotProps == null ? void 0 : externalSlotProps.className);\n const mergedStyle = _extends({}, additionalProps == null ? void 0 : additionalProps.style, externalForwardedProps == null ? void 0 : externalForwardedProps.style, externalSlotProps == null ? void 0 : externalSlotProps.style);\n const props = _extends({}, additionalProps, externalForwardedProps, externalSlotProps);\n if (joinedClasses.length > 0) {\n props.className = joinedClasses;\n }\n if (Object.keys(mergedStyle).length > 0) {\n props.style = mergedStyle;\n }\n return {\n props,\n internalRef: undefined\n };\n }\n\n // In this case, getSlotProps is responsible for calling the external event handlers.\n // We don't need to include them in the merged props because of this.\n\n const eventHandlers = extractEventHandlers(_extends({}, externalForwardedProps, externalSlotProps));\n const componentsPropsWithoutEventHandlers = omitEventHandlers(externalSlotProps);\n const otherPropsWithoutEventHandlers = omitEventHandlers(externalForwardedProps);\n const internalSlotProps = getSlotProps(eventHandlers);\n\n // The order of classes is important here.\n // Emotion (that we use in libraries consuming Base UI) depends on this order\n // to properly override style. It requires the most important classes to be last\n // (see https://github.com/mui/material-ui/pull/33205) for the related discussion.\n const joinedClasses = clsx(internalSlotProps == null ? void 0 : internalSlotProps.className, additionalProps == null ? void 0 : additionalProps.className, className, externalForwardedProps == null ? void 0 : externalForwardedProps.className, externalSlotProps == null ? void 0 : externalSlotProps.className);\n const mergedStyle = _extends({}, internalSlotProps == null ? void 0 : internalSlotProps.style, additionalProps == null ? void 0 : additionalProps.style, externalForwardedProps == null ? void 0 : externalForwardedProps.style, externalSlotProps == null ? void 0 : externalSlotProps.style);\n const props = _extends({}, internalSlotProps, additionalProps, otherPropsWithoutEventHandlers, componentsPropsWithoutEventHandlers);\n if (joinedClasses.length > 0) {\n props.className = joinedClasses;\n }\n if (Object.keys(mergedStyle).length > 0) {\n props.style = mergedStyle;\n }\n return {\n props,\n internalRef: internalSlotProps.ref\n };\n}","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"elementType\", \"externalSlotProps\", \"ownerState\", \"skipResolvingSlotProps\"];\nimport { unstable_useForkRef as useForkRef } from '@mui/utils';\nimport { appendOwnerState } from './appendOwnerState';\nimport { mergeSlotProps } from './mergeSlotProps';\nimport { resolveComponentProps } from './resolveComponentProps';\n/**\n * @ignore - do not document.\n * Builds the props to be passed into the slot of an unstyled component.\n * It merges the internal props of the component with the ones supplied by the user, allowing to customize the behavior.\n * If the slot component is not a host component, it also merges in the `ownerState`.\n *\n * @param parameters.getSlotProps - A function that returns the props to be passed to the slot component.\n */\nexport function useSlotProps(parameters) {\n var _parameters$additiona;\n const {\n elementType,\n externalSlotProps,\n ownerState,\n skipResolvingSlotProps = false\n } = parameters,\n rest = _objectWithoutPropertiesLoose(parameters, _excluded);\n const resolvedComponentsProps = skipResolvingSlotProps ? {} : resolveComponentProps(externalSlotProps, ownerState);\n const {\n props: mergedProps,\n internalRef\n } = mergeSlotProps(_extends({}, rest, {\n externalSlotProps: resolvedComponentsProps\n }));\n const ref = useForkRef(internalRef, resolvedComponentsProps == null ? void 0 : resolvedComponentsProps.ref, (_parameters$additiona = parameters.additionalProps) == null ? void 0 : _parameters$additiona.ref);\n const props = appendOwnerState(elementType, _extends({}, mergedProps, {\n ref\n }), ownerState);\n return props;\n}","import { globalStateClasses } from '@mui/utils/generateUtilityClass';\nconst GLOBAL_CLASS_PREFIX = 'base';\nfunction buildStateClass(state) {\n return `${GLOBAL_CLASS_PREFIX}--${state}`;\n}\nfunction buildSlotClass(componentName, slot) {\n return `${GLOBAL_CLASS_PREFIX}-${componentName}-${slot}`;\n}\nexport function generateUtilityClass(componentName, slot) {\n const globalStateClass = globalStateClasses[slot];\n return globalStateClass ? buildStateClass(globalStateClass) : buildSlotClass(componentName, slot);\n}\nexport function isGlobalState(slot) {\n return globalStateClasses[slot] !== undefined;\n}","import { generateUtilityClass } from '../generateUtilityClass';\nexport function generateUtilityClasses(componentName, slots) {\n const result = {};\n slots.forEach(slot => {\n result[slot] = generateUtilityClass(componentName, slot);\n });\n return result;\n}","'use client';\n\nimport * as React from 'react';\nimport * as ReactDOM from 'react-dom';\nimport PropTypes from 'prop-types';\nimport { exactProp, HTMLElementType, unstable_useEnhancedEffect as useEnhancedEffect, unstable_useForkRef as useForkRef, unstable_setRef as setRef } from '@mui/utils';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nfunction getContainer(container) {\n return typeof container === 'function' ? container() : container;\n}\n\n/**\n * Portals provide a first-class way to render children into a DOM node\n * that exists outside the DOM hierarchy of the parent component.\n *\n * Demos:\n *\n * - [Portal](https://mui.com/base-ui/react-portal/)\n *\n * API:\n *\n * - [Portal API](https://mui.com/base-ui/react-portal/components-api/#portal)\n */\nconst Portal = /*#__PURE__*/React.forwardRef(function Portal(props, forwardedRef) {\n const {\n children,\n container,\n disablePortal = false\n } = props;\n const [mountNode, setMountNode] = React.useState(null);\n // @ts-expect-error TODO upstream fix\n const handleRef = useForkRef( /*#__PURE__*/React.isValidElement(children) ? children.ref : null, forwardedRef);\n useEnhancedEffect(() => {\n if (!disablePortal) {\n setMountNode(getContainer(container) || document.body);\n }\n }, [container, disablePortal]);\n useEnhancedEffect(() => {\n if (mountNode && !disablePortal) {\n setRef(forwardedRef, mountNode);\n return () => {\n setRef(forwardedRef, null);\n };\n }\n return undefined;\n }, [forwardedRef, mountNode, disablePortal]);\n if (disablePortal) {\n if ( /*#__PURE__*/React.isValidElement(children)) {\n const newProps = {\n ref: handleRef\n };\n return /*#__PURE__*/React.cloneElement(children, newProps);\n }\n return /*#__PURE__*/_jsx(React.Fragment, {\n children: children\n });\n }\n return /*#__PURE__*/_jsx(React.Fragment, {\n children: mountNode ? /*#__PURE__*/ReactDOM.createPortal(children, mountNode) : mountNode\n });\n});\nprocess.env.NODE_ENV !== \"production\" ? Portal.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * The children to render into the `container`.\n */\n children: PropTypes.node,\n /**\n * An HTML element or function that returns one.\n * The `container` will have the portal children appended to it.\n *\n * You can also provide a callback, which is called in a React layout effect.\n * This lets you set the container from a ref, and also makes server-side rendering possible.\n *\n * By default, it uses the body of the top-level document object,\n * so it's simply `document.body` most of the time.\n */\n container: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.func]),\n /**\n * The `children` will be under the DOM hierarchy of the parent component.\n * @default false\n */\n disablePortal: PropTypes.bool\n} : void 0;\nif (process.env.NODE_ENV !== 'production') {\n // eslint-disable-next-line\n Portal['propTypes' + ''] = exactProp(Portal.propTypes);\n}\nexport { Portal };","export var top = 'top';\nexport var bottom = 'bottom';\nexport var right = 'right';\nexport var left = 'left';\nexport var auto = 'auto';\nexport var basePlacements = [top, bottom, right, left];\nexport var start = 'start';\nexport var end = 'end';\nexport var clippingParents = 'clippingParents';\nexport var viewport = 'viewport';\nexport var popper = 'popper';\nexport var reference = 'reference';\nexport var variationPlacements = /*#__PURE__*/basePlacements.reduce(function (acc, placement) {\n return acc.concat([placement + \"-\" + start, placement + \"-\" + end]);\n}, []);\nexport var placements = /*#__PURE__*/[].concat(basePlacements, [auto]).reduce(function (acc, placement) {\n return acc.concat([placement, placement + \"-\" + start, placement + \"-\" + end]);\n}, []); // modifiers that need to read the DOM\n\nexport var beforeRead = 'beforeRead';\nexport var read = 'read';\nexport var afterRead = 'afterRead'; // pure-logic modifiers\n\nexport var beforeMain = 'beforeMain';\nexport var main = 'main';\nexport var afterMain = 'afterMain'; // modifier with the purpose to write to the DOM (or write into a framework state)\n\nexport var beforeWrite = 'beforeWrite';\nexport var write = 'write';\nexport var afterWrite = 'afterWrite';\nexport var modifierPhases = [beforeRead, read, afterRead, beforeMain, main, afterMain, beforeWrite, write, afterWrite];","export default function getNodeName(element) {\n return element ? (element.nodeName || '').toLowerCase() : null;\n}","export default function getWindow(node) {\n if (node == null) {\n return window;\n }\n\n if (node.toString() !== '[object Window]') {\n var ownerDocument = node.ownerDocument;\n return ownerDocument ? ownerDocument.defaultView || window : window;\n }\n\n return node;\n}","import getWindow from \"./getWindow.js\";\n\nfunction isElement(node) {\n var OwnElement = getWindow(node).Element;\n return node instanceof OwnElement || node instanceof Element;\n}\n\nfunction isHTMLElement(node) {\n var OwnElement = getWindow(node).HTMLElement;\n return node instanceof OwnElement || node instanceof HTMLElement;\n}\n\nfunction isShadowRoot(node) {\n // IE 11 has no ShadowRoot\n if (typeof ShadowRoot === 'undefined') {\n return false;\n }\n\n var OwnElement = getWindow(node).ShadowRoot;\n return node instanceof OwnElement || node instanceof ShadowRoot;\n}\n\nexport { isElement, isHTMLElement, isShadowRoot };","import getNodeName from \"../dom-utils/getNodeName.js\";\nimport { isHTMLElement } from \"../dom-utils/instanceOf.js\"; // This modifier takes the styles prepared by the `computeStyles` modifier\n// and applies them to the HTMLElements such as popper and arrow\n\nfunction applyStyles(_ref) {\n var state = _ref.state;\n Object.keys(state.elements).forEach(function (name) {\n var style = state.styles[name] || {};\n var attributes = state.attributes[name] || {};\n var element = state.elements[name]; // arrow is optional + virtual elements\n\n if (!isHTMLElement(element) || !getNodeName(element)) {\n return;\n } // Flow doesn't support to extend this property, but it's the most\n // effective way to apply styles to an HTMLElement\n // $FlowFixMe[cannot-write]\n\n\n Object.assign(element.style, style);\n Object.keys(attributes).forEach(function (name) {\n var value = attributes[name];\n\n if (value === false) {\n element.removeAttribute(name);\n } else {\n element.setAttribute(name, value === true ? '' : value);\n }\n });\n });\n}\n\nfunction effect(_ref2) {\n var state = _ref2.state;\n var initialStyles = {\n popper: {\n position: state.options.strategy,\n left: '0',\n top: '0',\n margin: '0'\n },\n arrow: {\n position: 'absolute'\n },\n reference: {}\n };\n Object.assign(state.elements.popper.style, initialStyles.popper);\n state.styles = initialStyles;\n\n if (state.elements.arrow) {\n Object.assign(state.elements.arrow.style, initialStyles.arrow);\n }\n\n return function () {\n Object.keys(state.elements).forEach(function (name) {\n var element = state.elements[name];\n var attributes = state.attributes[name] || {};\n var styleProperties = Object.keys(state.styles.hasOwnProperty(name) ? state.styles[name] : initialStyles[name]); // Set all values to an empty string to unset them\n\n var style = styleProperties.reduce(function (style, property) {\n style[property] = '';\n return style;\n }, {}); // arrow is optional + virtual elements\n\n if (!isHTMLElement(element) || !getNodeName(element)) {\n return;\n }\n\n Object.assign(element.style, style);\n Object.keys(attributes).forEach(function (attribute) {\n element.removeAttribute(attribute);\n });\n });\n };\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'applyStyles',\n enabled: true,\n phase: 'write',\n fn: applyStyles,\n effect: effect,\n requires: ['computeStyles']\n};","import { auto } from \"../enums.js\";\nexport default function getBasePlacement(placement) {\n return placement.split('-')[0];\n}","export var max = Math.max;\nexport var min = Math.min;\nexport var round = Math.round;","export default function getUAString() {\n var uaData = navigator.userAgentData;\n\n if (uaData != null && uaData.brands && Array.isArray(uaData.brands)) {\n return uaData.brands.map(function (item) {\n return item.brand + \"/\" + item.version;\n }).join(' ');\n }\n\n return navigator.userAgent;\n}","import getUAString from \"../utils/userAgent.js\";\nexport default function isLayoutViewport() {\n return !/^((?!chrome|android).)*safari/i.test(getUAString());\n}","import { isElement, isHTMLElement } from \"./instanceOf.js\";\nimport { round } from \"../utils/math.js\";\nimport getWindow from \"./getWindow.js\";\nimport isLayoutViewport from \"./isLayoutViewport.js\";\nexport default function getBoundingClientRect(element, includeScale, isFixedStrategy) {\n if (includeScale === void 0) {\n includeScale = false;\n }\n\n if (isFixedStrategy === void 0) {\n isFixedStrategy = false;\n }\n\n var clientRect = element.getBoundingClientRect();\n var scaleX = 1;\n var scaleY = 1;\n\n if (includeScale && isHTMLElement(element)) {\n scaleX = element.offsetWidth > 0 ? round(clientRect.width) / element.offsetWidth || 1 : 1;\n scaleY = element.offsetHeight > 0 ? round(clientRect.height) / element.offsetHeight || 1 : 1;\n }\n\n var _ref = isElement(element) ? getWindow(element) : window,\n visualViewport = _ref.visualViewport;\n\n var addVisualOffsets = !isLayoutViewport() && isFixedStrategy;\n var x = (clientRect.left + (addVisualOffsets && visualViewport ? visualViewport.offsetLeft : 0)) / scaleX;\n var y = (clientRect.top + (addVisualOffsets && visualViewport ? visualViewport.offsetTop : 0)) / scaleY;\n var width = clientRect.width / scaleX;\n var height = clientRect.height / scaleY;\n return {\n width: width,\n height: height,\n top: y,\n right: x + width,\n bottom: y + height,\n left: x,\n x: x,\n y: y\n };\n}","import getBoundingClientRect from \"./getBoundingClientRect.js\"; // Returns the layout rect of an element relative to its offsetParent. Layout\n// means it doesn't take into account transforms.\n\nexport default function getLayoutRect(element) {\n var clientRect = getBoundingClientRect(element); // Use the clientRect sizes if it's not been transformed.\n // Fixes https://github.com/popperjs/popper-core/issues/1223\n\n var width = element.offsetWidth;\n var height = element.offsetHeight;\n\n if (Math.abs(clientRect.width - width) <= 1) {\n width = clientRect.width;\n }\n\n if (Math.abs(clientRect.height - height) <= 1) {\n height = clientRect.height;\n }\n\n return {\n x: element.offsetLeft,\n y: element.offsetTop,\n width: width,\n height: height\n };\n}","import { isShadowRoot } from \"./instanceOf.js\";\nexport default function contains(parent, child) {\n var rootNode = child.getRootNode && child.getRootNode(); // First, attempt with faster native method\n\n if (parent.contains(child)) {\n return true;\n } // then fallback to custom implementation with Shadow DOM support\n else if (rootNode && isShadowRoot(rootNode)) {\n var next = child;\n\n do {\n if (next && parent.isSameNode(next)) {\n return true;\n } // $FlowFixMe[prop-missing]: need a better way to handle this...\n\n\n next = next.parentNode || next.host;\n } while (next);\n } // Give up, the result is false\n\n\n return false;\n}","import getWindow from \"./getWindow.js\";\nexport default function getComputedStyle(element) {\n return getWindow(element).getComputedStyle(element);\n}","import getNodeName from \"./getNodeName.js\";\nexport default function isTableElement(element) {\n return ['table', 'td', 'th'].indexOf(getNodeName(element)) >= 0;\n}","import { isElement } from \"./instanceOf.js\";\nexport default function getDocumentElement(element) {\n // $FlowFixMe[incompatible-return]: assume body is always available\n return ((isElement(element) ? element.ownerDocument : // $FlowFixMe[prop-missing]\n element.document) || window.document).documentElement;\n}","import getNodeName from \"./getNodeName.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport { isShadowRoot } from \"./instanceOf.js\";\nexport default function getParentNode(element) {\n if (getNodeName(element) === 'html') {\n return element;\n }\n\n return (// this is a quicker (but less type safe) way to save quite some bytes from the bundle\n // $FlowFixMe[incompatible-return]\n // $FlowFixMe[prop-missing]\n element.assignedSlot || // step into the shadow DOM of the parent of a slotted node\n element.parentNode || ( // DOM Element detected\n isShadowRoot(element) ? element.host : null) || // ShadowRoot detected\n // $FlowFixMe[incompatible-call]: HTMLElement is a Node\n getDocumentElement(element) // fallback\n\n );\n}","import getWindow from \"./getWindow.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport getComputedStyle from \"./getComputedStyle.js\";\nimport { isHTMLElement, isShadowRoot } from \"./instanceOf.js\";\nimport isTableElement from \"./isTableElement.js\";\nimport getParentNode from \"./getParentNode.js\";\nimport getUAString from \"../utils/userAgent.js\";\n\nfunction getTrueOffsetParent(element) {\n if (!isHTMLElement(element) || // https://github.com/popperjs/popper-core/issues/837\n getComputedStyle(element).position === 'fixed') {\n return null;\n }\n\n return element.offsetParent;\n} // `.offsetParent` reports `null` for fixed elements, while absolute elements\n// return the containing block\n\n\nfunction getContainingBlock(element) {\n var isFirefox = /firefox/i.test(getUAString());\n var isIE = /Trident/i.test(getUAString());\n\n if (isIE && isHTMLElement(element)) {\n // In IE 9, 10 and 11 fixed elements containing block is always established by the viewport\n var elementCss = getComputedStyle(element);\n\n if (elementCss.position === 'fixed') {\n return null;\n }\n }\n\n var currentNode = getParentNode(element);\n\n if (isShadowRoot(currentNode)) {\n currentNode = currentNode.host;\n }\n\n while (isHTMLElement(currentNode) && ['html', 'body'].indexOf(getNodeName(currentNode)) < 0) {\n var css = getComputedStyle(currentNode); // This is non-exhaustive but covers the most common CSS properties that\n // create a containing block.\n // https://developer.mozilla.org/en-US/docs/Web/CSS/Containing_block#identifying_the_containing_block\n\n if (css.transform !== 'none' || css.perspective !== 'none' || css.contain === 'paint' || ['transform', 'perspective'].indexOf(css.willChange) !== -1 || isFirefox && css.willChange === 'filter' || isFirefox && css.filter && css.filter !== 'none') {\n return currentNode;\n } else {\n currentNode = currentNode.parentNode;\n }\n }\n\n return null;\n} // Gets the closest ancestor positioned element. Handles some edge cases,\n// such as table ancestors and cross browser bugs.\n\n\nexport default function getOffsetParent(element) {\n var window = getWindow(element);\n var offsetParent = getTrueOffsetParent(element);\n\n while (offsetParent && isTableElement(offsetParent) && getComputedStyle(offsetParent).position === 'static') {\n offsetParent = getTrueOffsetParent(offsetParent);\n }\n\n if (offsetParent && (getNodeName(offsetParent) === 'html' || getNodeName(offsetParent) === 'body' && getComputedStyle(offsetParent).position === 'static')) {\n return window;\n }\n\n return offsetParent || getContainingBlock(element) || window;\n}","export default function getMainAxisFromPlacement(placement) {\n return ['top', 'bottom'].indexOf(placement) >= 0 ? 'x' : 'y';\n}","import { max as mathMax, min as mathMin } from \"./math.js\";\nexport function within(min, value, max) {\n return mathMax(min, mathMin(value, max));\n}\nexport function withinMaxClamp(min, value, max) {\n var v = within(min, value, max);\n return v > max ? max : v;\n}","export default function getFreshSideObject() {\n return {\n top: 0,\n right: 0,\n bottom: 0,\n left: 0\n };\n}","import getFreshSideObject from \"./getFreshSideObject.js\";\nexport default function mergePaddingObject(paddingObject) {\n return Object.assign({}, getFreshSideObject(), paddingObject);\n}","export default function expandToHashMap(value, keys) {\n return keys.reduce(function (hashMap, key) {\n hashMap[key] = value;\n return hashMap;\n }, {});\n}","import getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getLayoutRect from \"../dom-utils/getLayoutRect.js\";\nimport contains from \"../dom-utils/contains.js\";\nimport getOffsetParent from \"../dom-utils/getOffsetParent.js\";\nimport getMainAxisFromPlacement from \"../utils/getMainAxisFromPlacement.js\";\nimport { within } from \"../utils/within.js\";\nimport mergePaddingObject from \"../utils/mergePaddingObject.js\";\nimport expandToHashMap from \"../utils/expandToHashMap.js\";\nimport { left, right, basePlacements, top, bottom } from \"../enums.js\"; // eslint-disable-next-line import/no-unused-modules\n\nvar toPaddingObject = function toPaddingObject(padding, state) {\n padding = typeof padding === 'function' ? padding(Object.assign({}, state.rects, {\n placement: state.placement\n })) : padding;\n return mergePaddingObject(typeof padding !== 'number' ? padding : expandToHashMap(padding, basePlacements));\n};\n\nfunction arrow(_ref) {\n var _state$modifiersData$;\n\n var state = _ref.state,\n name = _ref.name,\n options = _ref.options;\n var arrowElement = state.elements.arrow;\n var popperOffsets = state.modifiersData.popperOffsets;\n var basePlacement = getBasePlacement(state.placement);\n var axis = getMainAxisFromPlacement(basePlacement);\n var isVertical = [left, right].indexOf(basePlacement) >= 0;\n var len = isVertical ? 'height' : 'width';\n\n if (!arrowElement || !popperOffsets) {\n return;\n }\n\n var paddingObject = toPaddingObject(options.padding, state);\n var arrowRect = getLayoutRect(arrowElement);\n var minProp = axis === 'y' ? top : left;\n var maxProp = axis === 'y' ? bottom : right;\n var endDiff = state.rects.reference[len] + state.rects.reference[axis] - popperOffsets[axis] - state.rects.popper[len];\n var startDiff = popperOffsets[axis] - state.rects.reference[axis];\n var arrowOffsetParent = getOffsetParent(arrowElement);\n var clientSize = arrowOffsetParent ? axis === 'y' ? arrowOffsetParent.clientHeight || 0 : arrowOffsetParent.clientWidth || 0 : 0;\n var centerToReference = endDiff / 2 - startDiff / 2; // Make sure the arrow doesn't overflow the popper if the center point is\n // outside of the popper bounds\n\n var min = paddingObject[minProp];\n var max = clientSize - arrowRect[len] - paddingObject[maxProp];\n var center = clientSize / 2 - arrowRect[len] / 2 + centerToReference;\n var offset = within(min, center, max); // Prevents breaking syntax highlighting...\n\n var axisProp = axis;\n state.modifiersData[name] = (_state$modifiersData$ = {}, _state$modifiersData$[axisProp] = offset, _state$modifiersData$.centerOffset = offset - center, _state$modifiersData$);\n}\n\nfunction effect(_ref2) {\n var state = _ref2.state,\n options = _ref2.options;\n var _options$element = options.element,\n arrowElement = _options$element === void 0 ? '[data-popper-arrow]' : _options$element;\n\n if (arrowElement == null) {\n return;\n } // CSS selector\n\n\n if (typeof arrowElement === 'string') {\n arrowElement = state.elements.popper.querySelector(arrowElement);\n\n if (!arrowElement) {\n return;\n }\n }\n\n if (!contains(state.elements.popper, arrowElement)) {\n return;\n }\n\n state.elements.arrow = arrowElement;\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'arrow',\n enabled: true,\n phase: 'main',\n fn: arrow,\n effect: effect,\n requires: ['popperOffsets'],\n requiresIfExists: ['preventOverflow']\n};","export default function getVariation(placement) {\n return placement.split('-')[1];\n}","import { top, left, right, bottom, end } from \"../enums.js\";\nimport getOffsetParent from \"../dom-utils/getOffsetParent.js\";\nimport getWindow from \"../dom-utils/getWindow.js\";\nimport getDocumentElement from \"../dom-utils/getDocumentElement.js\";\nimport getComputedStyle from \"../dom-utils/getComputedStyle.js\";\nimport getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getVariation from \"../utils/getVariation.js\";\nimport { round } from \"../utils/math.js\"; // eslint-disable-next-line import/no-unused-modules\n\nvar unsetSides = {\n top: 'auto',\n right: 'auto',\n bottom: 'auto',\n left: 'auto'\n}; // Round the offsets to the nearest suitable subpixel based on the DPR.\n// Zooming can change the DPR, but it seems to report a value that will\n// cleanly divide the values into the appropriate subpixels.\n\nfunction roundOffsetsByDPR(_ref, win) {\n var x = _ref.x,\n y = _ref.y;\n var dpr = win.devicePixelRatio || 1;\n return {\n x: round(x * dpr) / dpr || 0,\n y: round(y * dpr) / dpr || 0\n };\n}\n\nexport function mapToStyles(_ref2) {\n var _Object$assign2;\n\n var popper = _ref2.popper,\n popperRect = _ref2.popperRect,\n placement = _ref2.placement,\n variation = _ref2.variation,\n offsets = _ref2.offsets,\n position = _ref2.position,\n gpuAcceleration = _ref2.gpuAcceleration,\n adaptive = _ref2.adaptive,\n roundOffsets = _ref2.roundOffsets,\n isFixed = _ref2.isFixed;\n var _offsets$x = offsets.x,\n x = _offsets$x === void 0 ? 0 : _offsets$x,\n _offsets$y = offsets.y,\n y = _offsets$y === void 0 ? 0 : _offsets$y;\n\n var _ref3 = typeof roundOffsets === 'function' ? roundOffsets({\n x: x,\n y: y\n }) : {\n x: x,\n y: y\n };\n\n x = _ref3.x;\n y = _ref3.y;\n var hasX = offsets.hasOwnProperty('x');\n var hasY = offsets.hasOwnProperty('y');\n var sideX = left;\n var sideY = top;\n var win = window;\n\n if (adaptive) {\n var offsetParent = getOffsetParent(popper);\n var heightProp = 'clientHeight';\n var widthProp = 'clientWidth';\n\n if (offsetParent === getWindow(popper)) {\n offsetParent = getDocumentElement(popper);\n\n if (getComputedStyle(offsetParent).position !== 'static' && position === 'absolute') {\n heightProp = 'scrollHeight';\n widthProp = 'scrollWidth';\n }\n } // $FlowFixMe[incompatible-cast]: force type refinement, we compare offsetParent with window above, but Flow doesn't detect it\n\n\n offsetParent = offsetParent;\n\n if (placement === top || (placement === left || placement === right) && variation === end) {\n sideY = bottom;\n var offsetY = isFixed && offsetParent === win && win.visualViewport ? win.visualViewport.height : // $FlowFixMe[prop-missing]\n offsetParent[heightProp];\n y -= offsetY - popperRect.height;\n y *= gpuAcceleration ? 1 : -1;\n }\n\n if (placement === left || (placement === top || placement === bottom) && variation === end) {\n sideX = right;\n var offsetX = isFixed && offsetParent === win && win.visualViewport ? win.visualViewport.width : // $FlowFixMe[prop-missing]\n offsetParent[widthProp];\n x -= offsetX - popperRect.width;\n x *= gpuAcceleration ? 1 : -1;\n }\n }\n\n var commonStyles = Object.assign({\n position: position\n }, adaptive && unsetSides);\n\n var _ref4 = roundOffsets === true ? roundOffsetsByDPR({\n x: x,\n y: y\n }, getWindow(popper)) : {\n x: x,\n y: y\n };\n\n x = _ref4.x;\n y = _ref4.y;\n\n if (gpuAcceleration) {\n var _Object$assign;\n\n return Object.assign({}, commonStyles, (_Object$assign = {}, _Object$assign[sideY] = hasY ? '0' : '', _Object$assign[sideX] = hasX ? '0' : '', _Object$assign.transform = (win.devicePixelRatio || 1) <= 1 ? \"translate(\" + x + \"px, \" + y + \"px)\" : \"translate3d(\" + x + \"px, \" + y + \"px, 0)\", _Object$assign));\n }\n\n return Object.assign({}, commonStyles, (_Object$assign2 = {}, _Object$assign2[sideY] = hasY ? y + \"px\" : '', _Object$assign2[sideX] = hasX ? x + \"px\" : '', _Object$assign2.transform = '', _Object$assign2));\n}\n\nfunction computeStyles(_ref5) {\n var state = _ref5.state,\n options = _ref5.options;\n var _options$gpuAccelerat = options.gpuAcceleration,\n gpuAcceleration = _options$gpuAccelerat === void 0 ? true : _options$gpuAccelerat,\n _options$adaptive = options.adaptive,\n adaptive = _options$adaptive === void 0 ? true : _options$adaptive,\n _options$roundOffsets = options.roundOffsets,\n roundOffsets = _options$roundOffsets === void 0 ? true : _options$roundOffsets;\n var commonStyles = {\n placement: getBasePlacement(state.placement),\n variation: getVariation(state.placement),\n popper: state.elements.popper,\n popperRect: state.rects.popper,\n gpuAcceleration: gpuAcceleration,\n isFixed: state.options.strategy === 'fixed'\n };\n\n if (state.modifiersData.popperOffsets != null) {\n state.styles.popper = Object.assign({}, state.styles.popper, mapToStyles(Object.assign({}, commonStyles, {\n offsets: state.modifiersData.popperOffsets,\n position: state.options.strategy,\n adaptive: adaptive,\n roundOffsets: roundOffsets\n })));\n }\n\n if (state.modifiersData.arrow != null) {\n state.styles.arrow = Object.assign({}, state.styles.arrow, mapToStyles(Object.assign({}, commonStyles, {\n offsets: state.modifiersData.arrow,\n position: 'absolute',\n adaptive: false,\n roundOffsets: roundOffsets\n })));\n }\n\n state.attributes.popper = Object.assign({}, state.attributes.popper, {\n 'data-popper-placement': state.placement\n });\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'computeStyles',\n enabled: true,\n phase: 'beforeWrite',\n fn: computeStyles,\n data: {}\n};","import getWindow from \"../dom-utils/getWindow.js\"; // eslint-disable-next-line import/no-unused-modules\n\nvar passive = {\n passive: true\n};\n\nfunction effect(_ref) {\n var state = _ref.state,\n instance = _ref.instance,\n options = _ref.options;\n var _options$scroll = options.scroll,\n scroll = _options$scroll === void 0 ? true : _options$scroll,\n _options$resize = options.resize,\n resize = _options$resize === void 0 ? true : _options$resize;\n var window = getWindow(state.elements.popper);\n var scrollParents = [].concat(state.scrollParents.reference, state.scrollParents.popper);\n\n if (scroll) {\n scrollParents.forEach(function (scrollParent) {\n scrollParent.addEventListener('scroll', instance.update, passive);\n });\n }\n\n if (resize) {\n window.addEventListener('resize', instance.update, passive);\n }\n\n return function () {\n if (scroll) {\n scrollParents.forEach(function (scrollParent) {\n scrollParent.removeEventListener('scroll', instance.update, passive);\n });\n }\n\n if (resize) {\n window.removeEventListener('resize', instance.update, passive);\n }\n };\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'eventListeners',\n enabled: true,\n phase: 'write',\n fn: function fn() {},\n effect: effect,\n data: {}\n};","var hash = {\n left: 'right',\n right: 'left',\n bottom: 'top',\n top: 'bottom'\n};\nexport default function getOppositePlacement(placement) {\n return placement.replace(/left|right|bottom|top/g, function (matched) {\n return hash[matched];\n });\n}","var hash = {\n start: 'end',\n end: 'start'\n};\nexport default function getOppositeVariationPlacement(placement) {\n return placement.replace(/start|end/g, function (matched) {\n return hash[matched];\n });\n}","import getWindow from \"./getWindow.js\";\nexport default function getWindowScroll(node) {\n var win = getWindow(node);\n var scrollLeft = win.pageXOffset;\n var scrollTop = win.pageYOffset;\n return {\n scrollLeft: scrollLeft,\n scrollTop: scrollTop\n };\n}","import getBoundingClientRect from \"./getBoundingClientRect.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport getWindowScroll from \"./getWindowScroll.js\";\nexport default function getWindowScrollBarX(element) {\n // If has a CSS width greater than the viewport, then this will be\n // incorrect for RTL.\n // Popper 1 is broken in this case and never had a bug report so let's assume\n // it's not an issue. I don't think anyone ever specifies width on \n // anyway.\n // Browsers where the left scrollbar doesn't cause an issue report `0` for\n // this (e.g. Edge 2019, IE11, Safari)\n return getBoundingClientRect(getDocumentElement(element)).left + getWindowScroll(element).scrollLeft;\n}","import getWindow from \"./getWindow.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport getWindowScrollBarX from \"./getWindowScrollBarX.js\";\nimport isLayoutViewport from \"./isLayoutViewport.js\";\nexport default function getViewportRect(element, strategy) {\n var win = getWindow(element);\n var html = getDocumentElement(element);\n var visualViewport = win.visualViewport;\n var width = html.clientWidth;\n var height = html.clientHeight;\n var x = 0;\n var y = 0;\n\n if (visualViewport) {\n width = visualViewport.width;\n height = visualViewport.height;\n var layoutViewport = isLayoutViewport();\n\n if (layoutViewport || !layoutViewport && strategy === 'fixed') {\n x = visualViewport.offsetLeft;\n y = visualViewport.offsetTop;\n }\n }\n\n return {\n width: width,\n height: height,\n x: x + getWindowScrollBarX(element),\n y: y\n };\n}","import getDocumentElement from \"./getDocumentElement.js\";\nimport getComputedStyle from \"./getComputedStyle.js\";\nimport getWindowScrollBarX from \"./getWindowScrollBarX.js\";\nimport getWindowScroll from \"./getWindowScroll.js\";\nimport { max } from \"../utils/math.js\"; // Gets the entire size of the scrollable document area, even extending outside\n// of the `` and `` rect bounds if horizontally scrollable\n\nexport default function getDocumentRect(element) {\n var _element$ownerDocumen;\n\n var html = getDocumentElement(element);\n var winScroll = getWindowScroll(element);\n var body = (_element$ownerDocumen = element.ownerDocument) == null ? void 0 : _element$ownerDocumen.body;\n var width = max(html.scrollWidth, html.clientWidth, body ? body.scrollWidth : 0, body ? body.clientWidth : 0);\n var height = max(html.scrollHeight, html.clientHeight, body ? body.scrollHeight : 0, body ? body.clientHeight : 0);\n var x = -winScroll.scrollLeft + getWindowScrollBarX(element);\n var y = -winScroll.scrollTop;\n\n if (getComputedStyle(body || html).direction === 'rtl') {\n x += max(html.clientWidth, body ? body.clientWidth : 0) - width;\n }\n\n return {\n width: width,\n height: height,\n x: x,\n y: y\n };\n}","import getComputedStyle from \"./getComputedStyle.js\";\nexport default function isScrollParent(element) {\n // Firefox wants us to check `-x` and `-y` variations as well\n var _getComputedStyle = getComputedStyle(element),\n overflow = _getComputedStyle.overflow,\n overflowX = _getComputedStyle.overflowX,\n overflowY = _getComputedStyle.overflowY;\n\n return /auto|scroll|overlay|hidden/.test(overflow + overflowY + overflowX);\n}","import getParentNode from \"./getParentNode.js\";\nimport isScrollParent from \"./isScrollParent.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport { isHTMLElement } from \"./instanceOf.js\";\nexport default function getScrollParent(node) {\n if (['html', 'body', '#document'].indexOf(getNodeName(node)) >= 0) {\n // $FlowFixMe[incompatible-return]: assume body is always available\n return node.ownerDocument.body;\n }\n\n if (isHTMLElement(node) && isScrollParent(node)) {\n return node;\n }\n\n return getScrollParent(getParentNode(node));\n}","import getScrollParent from \"./getScrollParent.js\";\nimport getParentNode from \"./getParentNode.js\";\nimport getWindow from \"./getWindow.js\";\nimport isScrollParent from \"./isScrollParent.js\";\n/*\ngiven a DOM element, return the list of all scroll parents, up the list of ancesors\nuntil we get to the top window object. This list is what we attach scroll listeners\nto, because if any of these parent elements scroll, we'll need to re-calculate the\nreference element's position.\n*/\n\nexport default function listScrollParents(element, list) {\n var _element$ownerDocumen;\n\n if (list === void 0) {\n list = [];\n }\n\n var scrollParent = getScrollParent(element);\n var isBody = scrollParent === ((_element$ownerDocumen = element.ownerDocument) == null ? void 0 : _element$ownerDocumen.body);\n var win = getWindow(scrollParent);\n var target = isBody ? [win].concat(win.visualViewport || [], isScrollParent(scrollParent) ? scrollParent : []) : scrollParent;\n var updatedList = list.concat(target);\n return isBody ? updatedList : // $FlowFixMe[incompatible-call]: isBody tells us target will be an HTMLElement here\n updatedList.concat(listScrollParents(getParentNode(target)));\n}","export default function rectToClientRect(rect) {\n return Object.assign({}, rect, {\n left: rect.x,\n top: rect.y,\n right: rect.x + rect.width,\n bottom: rect.y + rect.height\n });\n}","import { viewport } from \"../enums.js\";\nimport getViewportRect from \"./getViewportRect.js\";\nimport getDocumentRect from \"./getDocumentRect.js\";\nimport listScrollParents from \"./listScrollParents.js\";\nimport getOffsetParent from \"./getOffsetParent.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport getComputedStyle from \"./getComputedStyle.js\";\nimport { isElement, isHTMLElement } from \"./instanceOf.js\";\nimport getBoundingClientRect from \"./getBoundingClientRect.js\";\nimport getParentNode from \"./getParentNode.js\";\nimport contains from \"./contains.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport rectToClientRect from \"../utils/rectToClientRect.js\";\nimport { max, min } from \"../utils/math.js\";\n\nfunction getInnerBoundingClientRect(element, strategy) {\n var rect = getBoundingClientRect(element, false, strategy === 'fixed');\n rect.top = rect.top + element.clientTop;\n rect.left = rect.left + element.clientLeft;\n rect.bottom = rect.top + element.clientHeight;\n rect.right = rect.left + element.clientWidth;\n rect.width = element.clientWidth;\n rect.height = element.clientHeight;\n rect.x = rect.left;\n rect.y = rect.top;\n return rect;\n}\n\nfunction getClientRectFromMixedType(element, clippingParent, strategy) {\n return clippingParent === viewport ? rectToClientRect(getViewportRect(element, strategy)) : isElement(clippingParent) ? getInnerBoundingClientRect(clippingParent, strategy) : rectToClientRect(getDocumentRect(getDocumentElement(element)));\n} // A \"clipping parent\" is an overflowable container with the characteristic of\n// clipping (or hiding) overflowing elements with a position different from\n// `initial`\n\n\nfunction getClippingParents(element) {\n var clippingParents = listScrollParents(getParentNode(element));\n var canEscapeClipping = ['absolute', 'fixed'].indexOf(getComputedStyle(element).position) >= 0;\n var clipperElement = canEscapeClipping && isHTMLElement(element) ? getOffsetParent(element) : element;\n\n if (!isElement(clipperElement)) {\n return [];\n } // $FlowFixMe[incompatible-return]: https://github.com/facebook/flow/issues/1414\n\n\n return clippingParents.filter(function (clippingParent) {\n return isElement(clippingParent) && contains(clippingParent, clipperElement) && getNodeName(clippingParent) !== 'body';\n });\n} // Gets the maximum area that the element is visible in due to any number of\n// clipping parents\n\n\nexport default function getClippingRect(element, boundary, rootBoundary, strategy) {\n var mainClippingParents = boundary === 'clippingParents' ? getClippingParents(element) : [].concat(boundary);\n var clippingParents = [].concat(mainClippingParents, [rootBoundary]);\n var firstClippingParent = clippingParents[0];\n var clippingRect = clippingParents.reduce(function (accRect, clippingParent) {\n var rect = getClientRectFromMixedType(element, clippingParent, strategy);\n accRect.top = max(rect.top, accRect.top);\n accRect.right = min(rect.right, accRect.right);\n accRect.bottom = min(rect.bottom, accRect.bottom);\n accRect.left = max(rect.left, accRect.left);\n return accRect;\n }, getClientRectFromMixedType(element, firstClippingParent, strategy));\n clippingRect.width = clippingRect.right - clippingRect.left;\n clippingRect.height = clippingRect.bottom - clippingRect.top;\n clippingRect.x = clippingRect.left;\n clippingRect.y = clippingRect.top;\n return clippingRect;\n}","import getBasePlacement from \"./getBasePlacement.js\";\nimport getVariation from \"./getVariation.js\";\nimport getMainAxisFromPlacement from \"./getMainAxisFromPlacement.js\";\nimport { top, right, bottom, left, start, end } from \"../enums.js\";\nexport default function computeOffsets(_ref) {\n var reference = _ref.reference,\n element = _ref.element,\n placement = _ref.placement;\n var basePlacement = placement ? getBasePlacement(placement) : null;\n var variation = placement ? getVariation(placement) : null;\n var commonX = reference.x + reference.width / 2 - element.width / 2;\n var commonY = reference.y + reference.height / 2 - element.height / 2;\n var offsets;\n\n switch (basePlacement) {\n case top:\n offsets = {\n x: commonX,\n y: reference.y - element.height\n };\n break;\n\n case bottom:\n offsets = {\n x: commonX,\n y: reference.y + reference.height\n };\n break;\n\n case right:\n offsets = {\n x: reference.x + reference.width,\n y: commonY\n };\n break;\n\n case left:\n offsets = {\n x: reference.x - element.width,\n y: commonY\n };\n break;\n\n default:\n offsets = {\n x: reference.x,\n y: reference.y\n };\n }\n\n var mainAxis = basePlacement ? getMainAxisFromPlacement(basePlacement) : null;\n\n if (mainAxis != null) {\n var len = mainAxis === 'y' ? 'height' : 'width';\n\n switch (variation) {\n case start:\n offsets[mainAxis] = offsets[mainAxis] - (reference[len] / 2 - element[len] / 2);\n break;\n\n case end:\n offsets[mainAxis] = offsets[mainAxis] + (reference[len] / 2 - element[len] / 2);\n break;\n\n default:\n }\n }\n\n return offsets;\n}","import getClippingRect from \"../dom-utils/getClippingRect.js\";\nimport getDocumentElement from \"../dom-utils/getDocumentElement.js\";\nimport getBoundingClientRect from \"../dom-utils/getBoundingClientRect.js\";\nimport computeOffsets from \"./computeOffsets.js\";\nimport rectToClientRect from \"./rectToClientRect.js\";\nimport { clippingParents, reference, popper, bottom, top, right, basePlacements, viewport } from \"../enums.js\";\nimport { isElement } from \"../dom-utils/instanceOf.js\";\nimport mergePaddingObject from \"./mergePaddingObject.js\";\nimport expandToHashMap from \"./expandToHashMap.js\"; // eslint-disable-next-line import/no-unused-modules\n\nexport default function detectOverflow(state, options) {\n if (options === void 0) {\n options = {};\n }\n\n var _options = options,\n _options$placement = _options.placement,\n placement = _options$placement === void 0 ? state.placement : _options$placement,\n _options$strategy = _options.strategy,\n strategy = _options$strategy === void 0 ? state.strategy : _options$strategy,\n _options$boundary = _options.boundary,\n boundary = _options$boundary === void 0 ? clippingParents : _options$boundary,\n _options$rootBoundary = _options.rootBoundary,\n rootBoundary = _options$rootBoundary === void 0 ? viewport : _options$rootBoundary,\n _options$elementConte = _options.elementContext,\n elementContext = _options$elementConte === void 0 ? popper : _options$elementConte,\n _options$altBoundary = _options.altBoundary,\n altBoundary = _options$altBoundary === void 0 ? false : _options$altBoundary,\n _options$padding = _options.padding,\n padding = _options$padding === void 0 ? 0 : _options$padding;\n var paddingObject = mergePaddingObject(typeof padding !== 'number' ? padding : expandToHashMap(padding, basePlacements));\n var altContext = elementContext === popper ? reference : popper;\n var popperRect = state.rects.popper;\n var element = state.elements[altBoundary ? altContext : elementContext];\n var clippingClientRect = getClippingRect(isElement(element) ? element : element.contextElement || getDocumentElement(state.elements.popper), boundary, rootBoundary, strategy);\n var referenceClientRect = getBoundingClientRect(state.elements.reference);\n var popperOffsets = computeOffsets({\n reference: referenceClientRect,\n element: popperRect,\n strategy: 'absolute',\n placement: placement\n });\n var popperClientRect = rectToClientRect(Object.assign({}, popperRect, popperOffsets));\n var elementClientRect = elementContext === popper ? popperClientRect : referenceClientRect; // positive = overflowing the clipping rect\n // 0 or negative = within the clipping rect\n\n var overflowOffsets = {\n top: clippingClientRect.top - elementClientRect.top + paddingObject.top,\n bottom: elementClientRect.bottom - clippingClientRect.bottom + paddingObject.bottom,\n left: clippingClientRect.left - elementClientRect.left + paddingObject.left,\n right: elementClientRect.right - clippingClientRect.right + paddingObject.right\n };\n var offsetData = state.modifiersData.offset; // Offsets can be applied only to the popper element\n\n if (elementContext === popper && offsetData) {\n var offset = offsetData[placement];\n Object.keys(overflowOffsets).forEach(function (key) {\n var multiply = [right, bottom].indexOf(key) >= 0 ? 1 : -1;\n var axis = [top, bottom].indexOf(key) >= 0 ? 'y' : 'x';\n overflowOffsets[key] += offset[axis] * multiply;\n });\n }\n\n return overflowOffsets;\n}","import getVariation from \"./getVariation.js\";\nimport { variationPlacements, basePlacements, placements as allPlacements } from \"../enums.js\";\nimport detectOverflow from \"./detectOverflow.js\";\nimport getBasePlacement from \"./getBasePlacement.js\";\nexport default function computeAutoPlacement(state, options) {\n if (options === void 0) {\n options = {};\n }\n\n var _options = options,\n placement = _options.placement,\n boundary = _options.boundary,\n rootBoundary = _options.rootBoundary,\n padding = _options.padding,\n flipVariations = _options.flipVariations,\n _options$allowedAutoP = _options.allowedAutoPlacements,\n allowedAutoPlacements = _options$allowedAutoP === void 0 ? allPlacements : _options$allowedAutoP;\n var variation = getVariation(placement);\n var placements = variation ? flipVariations ? variationPlacements : variationPlacements.filter(function (placement) {\n return getVariation(placement) === variation;\n }) : basePlacements;\n var allowedPlacements = placements.filter(function (placement) {\n return allowedAutoPlacements.indexOf(placement) >= 0;\n });\n\n if (allowedPlacements.length === 0) {\n allowedPlacements = placements;\n } // $FlowFixMe[incompatible-type]: Flow seems to have problems with two array unions...\n\n\n var overflows = allowedPlacements.reduce(function (acc, placement) {\n acc[placement] = detectOverflow(state, {\n placement: placement,\n boundary: boundary,\n rootBoundary: rootBoundary,\n padding: padding\n })[getBasePlacement(placement)];\n return acc;\n }, {});\n return Object.keys(overflows).sort(function (a, b) {\n return overflows[a] - overflows[b];\n });\n}","import getOppositePlacement from \"../utils/getOppositePlacement.js\";\nimport getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getOppositeVariationPlacement from \"../utils/getOppositeVariationPlacement.js\";\nimport detectOverflow from \"../utils/detectOverflow.js\";\nimport computeAutoPlacement from \"../utils/computeAutoPlacement.js\";\nimport { bottom, top, start, right, left, auto } from \"../enums.js\";\nimport getVariation from \"../utils/getVariation.js\"; // eslint-disable-next-line import/no-unused-modules\n\nfunction getExpandedFallbackPlacements(placement) {\n if (getBasePlacement(placement) === auto) {\n return [];\n }\n\n var oppositePlacement = getOppositePlacement(placement);\n return [getOppositeVariationPlacement(placement), oppositePlacement, getOppositeVariationPlacement(oppositePlacement)];\n}\n\nfunction flip(_ref) {\n var state = _ref.state,\n options = _ref.options,\n name = _ref.name;\n\n if (state.modifiersData[name]._skip) {\n return;\n }\n\n var _options$mainAxis = options.mainAxis,\n checkMainAxis = _options$mainAxis === void 0 ? true : _options$mainAxis,\n _options$altAxis = options.altAxis,\n checkAltAxis = _options$altAxis === void 0 ? true : _options$altAxis,\n specifiedFallbackPlacements = options.fallbackPlacements,\n padding = options.padding,\n boundary = options.boundary,\n rootBoundary = options.rootBoundary,\n altBoundary = options.altBoundary,\n _options$flipVariatio = options.flipVariations,\n flipVariations = _options$flipVariatio === void 0 ? true : _options$flipVariatio,\n allowedAutoPlacements = options.allowedAutoPlacements;\n var preferredPlacement = state.options.placement;\n var basePlacement = getBasePlacement(preferredPlacement);\n var isBasePlacement = basePlacement === preferredPlacement;\n var fallbackPlacements = specifiedFallbackPlacements || (isBasePlacement || !flipVariations ? [getOppositePlacement(preferredPlacement)] : getExpandedFallbackPlacements(preferredPlacement));\n var placements = [preferredPlacement].concat(fallbackPlacements).reduce(function (acc, placement) {\n return acc.concat(getBasePlacement(placement) === auto ? computeAutoPlacement(state, {\n placement: placement,\n boundary: boundary,\n rootBoundary: rootBoundary,\n padding: padding,\n flipVariations: flipVariations,\n allowedAutoPlacements: allowedAutoPlacements\n }) : placement);\n }, []);\n var referenceRect = state.rects.reference;\n var popperRect = state.rects.popper;\n var checksMap = new Map();\n var makeFallbackChecks = true;\n var firstFittingPlacement = placements[0];\n\n for (var i = 0; i < placements.length; i++) {\n var placement = placements[i];\n\n var _basePlacement = getBasePlacement(placement);\n\n var isStartVariation = getVariation(placement) === start;\n var isVertical = [top, bottom].indexOf(_basePlacement) >= 0;\n var len = isVertical ? 'width' : 'height';\n var overflow = detectOverflow(state, {\n placement: placement,\n boundary: boundary,\n rootBoundary: rootBoundary,\n altBoundary: altBoundary,\n padding: padding\n });\n var mainVariationSide = isVertical ? isStartVariation ? right : left : isStartVariation ? bottom : top;\n\n if (referenceRect[len] > popperRect[len]) {\n mainVariationSide = getOppositePlacement(mainVariationSide);\n }\n\n var altVariationSide = getOppositePlacement(mainVariationSide);\n var checks = [];\n\n if (checkMainAxis) {\n checks.push(overflow[_basePlacement] <= 0);\n }\n\n if (checkAltAxis) {\n checks.push(overflow[mainVariationSide] <= 0, overflow[altVariationSide] <= 0);\n }\n\n if (checks.every(function (check) {\n return check;\n })) {\n firstFittingPlacement = placement;\n makeFallbackChecks = false;\n break;\n }\n\n checksMap.set(placement, checks);\n }\n\n if (makeFallbackChecks) {\n // `2` may be desired in some cases – research later\n var numberOfChecks = flipVariations ? 3 : 1;\n\n var _loop = function _loop(_i) {\n var fittingPlacement = placements.find(function (placement) {\n var checks = checksMap.get(placement);\n\n if (checks) {\n return checks.slice(0, _i).every(function (check) {\n return check;\n });\n }\n });\n\n if (fittingPlacement) {\n firstFittingPlacement = fittingPlacement;\n return \"break\";\n }\n };\n\n for (var _i = numberOfChecks; _i > 0; _i--) {\n var _ret = _loop(_i);\n\n if (_ret === \"break\") break;\n }\n }\n\n if (state.placement !== firstFittingPlacement) {\n state.modifiersData[name]._skip = true;\n state.placement = firstFittingPlacement;\n state.reset = true;\n }\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'flip',\n enabled: true,\n phase: 'main',\n fn: flip,\n requiresIfExists: ['offset'],\n data: {\n _skip: false\n }\n};","import { top, bottom, left, right } from \"../enums.js\";\nimport detectOverflow from \"../utils/detectOverflow.js\";\n\nfunction getSideOffsets(overflow, rect, preventedOffsets) {\n if (preventedOffsets === void 0) {\n preventedOffsets = {\n x: 0,\n y: 0\n };\n }\n\n return {\n top: overflow.top - rect.height - preventedOffsets.y,\n right: overflow.right - rect.width + preventedOffsets.x,\n bottom: overflow.bottom - rect.height + preventedOffsets.y,\n left: overflow.left - rect.width - preventedOffsets.x\n };\n}\n\nfunction isAnySideFullyClipped(overflow) {\n return [top, right, bottom, left].some(function (side) {\n return overflow[side] >= 0;\n });\n}\n\nfunction hide(_ref) {\n var state = _ref.state,\n name = _ref.name;\n var referenceRect = state.rects.reference;\n var popperRect = state.rects.popper;\n var preventedOffsets = state.modifiersData.preventOverflow;\n var referenceOverflow = detectOverflow(state, {\n elementContext: 'reference'\n });\n var popperAltOverflow = detectOverflow(state, {\n altBoundary: true\n });\n var referenceClippingOffsets = getSideOffsets(referenceOverflow, referenceRect);\n var popperEscapeOffsets = getSideOffsets(popperAltOverflow, popperRect, preventedOffsets);\n var isReferenceHidden = isAnySideFullyClipped(referenceClippingOffsets);\n var hasPopperEscaped = isAnySideFullyClipped(popperEscapeOffsets);\n state.modifiersData[name] = {\n referenceClippingOffsets: referenceClippingOffsets,\n popperEscapeOffsets: popperEscapeOffsets,\n isReferenceHidden: isReferenceHidden,\n hasPopperEscaped: hasPopperEscaped\n };\n state.attributes.popper = Object.assign({}, state.attributes.popper, {\n 'data-popper-reference-hidden': isReferenceHidden,\n 'data-popper-escaped': hasPopperEscaped\n });\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'hide',\n enabled: true,\n phase: 'main',\n requiresIfExists: ['preventOverflow'],\n fn: hide\n};","import getBasePlacement from \"../utils/getBasePlacement.js\";\nimport { top, left, right, placements } from \"../enums.js\"; // eslint-disable-next-line import/no-unused-modules\n\nexport function distanceAndSkiddingToXY(placement, rects, offset) {\n var basePlacement = getBasePlacement(placement);\n var invertDistance = [left, top].indexOf(basePlacement) >= 0 ? -1 : 1;\n\n var _ref = typeof offset === 'function' ? offset(Object.assign({}, rects, {\n placement: placement\n })) : offset,\n skidding = _ref[0],\n distance = _ref[1];\n\n skidding = skidding || 0;\n distance = (distance || 0) * invertDistance;\n return [left, right].indexOf(basePlacement) >= 0 ? {\n x: distance,\n y: skidding\n } : {\n x: skidding,\n y: distance\n };\n}\n\nfunction offset(_ref2) {\n var state = _ref2.state,\n options = _ref2.options,\n name = _ref2.name;\n var _options$offset = options.offset,\n offset = _options$offset === void 0 ? [0, 0] : _options$offset;\n var data = placements.reduce(function (acc, placement) {\n acc[placement] = distanceAndSkiddingToXY(placement, state.rects, offset);\n return acc;\n }, {});\n var _data$state$placement = data[state.placement],\n x = _data$state$placement.x,\n y = _data$state$placement.y;\n\n if (state.modifiersData.popperOffsets != null) {\n state.modifiersData.popperOffsets.x += x;\n state.modifiersData.popperOffsets.y += y;\n }\n\n state.modifiersData[name] = data;\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'offset',\n enabled: true,\n phase: 'main',\n requires: ['popperOffsets'],\n fn: offset\n};","import computeOffsets from \"../utils/computeOffsets.js\";\n\nfunction popperOffsets(_ref) {\n var state = _ref.state,\n name = _ref.name;\n // Offsets are the actual position the popper needs to have to be\n // properly positioned near its reference element\n // This is the most basic placement, and will be adjusted by\n // the modifiers in the next step\n state.modifiersData[name] = computeOffsets({\n reference: state.rects.reference,\n element: state.rects.popper,\n strategy: 'absolute',\n placement: state.placement\n });\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'popperOffsets',\n enabled: true,\n phase: 'read',\n fn: popperOffsets,\n data: {}\n};","export default function getAltAxis(axis) {\n return axis === 'x' ? 'y' : 'x';\n}","import { top, left, right, bottom, start } from \"../enums.js\";\nimport getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getMainAxisFromPlacement from \"../utils/getMainAxisFromPlacement.js\";\nimport getAltAxis from \"../utils/getAltAxis.js\";\nimport { within, withinMaxClamp } from \"../utils/within.js\";\nimport getLayoutRect from \"../dom-utils/getLayoutRect.js\";\nimport getOffsetParent from \"../dom-utils/getOffsetParent.js\";\nimport detectOverflow from \"../utils/detectOverflow.js\";\nimport getVariation from \"../utils/getVariation.js\";\nimport getFreshSideObject from \"../utils/getFreshSideObject.js\";\nimport { min as mathMin, max as mathMax } from \"../utils/math.js\";\n\nfunction preventOverflow(_ref) {\n var state = _ref.state,\n options = _ref.options,\n name = _ref.name;\n var _options$mainAxis = options.mainAxis,\n checkMainAxis = _options$mainAxis === void 0 ? true : _options$mainAxis,\n _options$altAxis = options.altAxis,\n checkAltAxis = _options$altAxis === void 0 ? false : _options$altAxis,\n boundary = options.boundary,\n rootBoundary = options.rootBoundary,\n altBoundary = options.altBoundary,\n padding = options.padding,\n _options$tether = options.tether,\n tether = _options$tether === void 0 ? true : _options$tether,\n _options$tetherOffset = options.tetherOffset,\n tetherOffset = _options$tetherOffset === void 0 ? 0 : _options$tetherOffset;\n var overflow = detectOverflow(state, {\n boundary: boundary,\n rootBoundary: rootBoundary,\n padding: padding,\n altBoundary: altBoundary\n });\n var basePlacement = getBasePlacement(state.placement);\n var variation = getVariation(state.placement);\n var isBasePlacement = !variation;\n var mainAxis = getMainAxisFromPlacement(basePlacement);\n var altAxis = getAltAxis(mainAxis);\n var popperOffsets = state.modifiersData.popperOffsets;\n var referenceRect = state.rects.reference;\n var popperRect = state.rects.popper;\n var tetherOffsetValue = typeof tetherOffset === 'function' ? tetherOffset(Object.assign({}, state.rects, {\n placement: state.placement\n })) : tetherOffset;\n var normalizedTetherOffsetValue = typeof tetherOffsetValue === 'number' ? {\n mainAxis: tetherOffsetValue,\n altAxis: tetherOffsetValue\n } : Object.assign({\n mainAxis: 0,\n altAxis: 0\n }, tetherOffsetValue);\n var offsetModifierState = state.modifiersData.offset ? state.modifiersData.offset[state.placement] : null;\n var data = {\n x: 0,\n y: 0\n };\n\n if (!popperOffsets) {\n return;\n }\n\n if (checkMainAxis) {\n var _offsetModifierState$;\n\n var mainSide = mainAxis === 'y' ? top : left;\n var altSide = mainAxis === 'y' ? bottom : right;\n var len = mainAxis === 'y' ? 'height' : 'width';\n var offset = popperOffsets[mainAxis];\n var min = offset + overflow[mainSide];\n var max = offset - overflow[altSide];\n var additive = tether ? -popperRect[len] / 2 : 0;\n var minLen = variation === start ? referenceRect[len] : popperRect[len];\n var maxLen = variation === start ? -popperRect[len] : -referenceRect[len]; // We need to include the arrow in the calculation so the arrow doesn't go\n // outside the reference bounds\n\n var arrowElement = state.elements.arrow;\n var arrowRect = tether && arrowElement ? getLayoutRect(arrowElement) : {\n width: 0,\n height: 0\n };\n var arrowPaddingObject = state.modifiersData['arrow#persistent'] ? state.modifiersData['arrow#persistent'].padding : getFreshSideObject();\n var arrowPaddingMin = arrowPaddingObject[mainSide];\n var arrowPaddingMax = arrowPaddingObject[altSide]; // If the reference length is smaller than the arrow length, we don't want\n // to include its full size in the calculation. If the reference is small\n // and near the edge of a boundary, the popper can overflow even if the\n // reference is not overflowing as well (e.g. virtual elements with no\n // width or height)\n\n var arrowLen = within(0, referenceRect[len], arrowRect[len]);\n var minOffset = isBasePlacement ? referenceRect[len] / 2 - additive - arrowLen - arrowPaddingMin - normalizedTetherOffsetValue.mainAxis : minLen - arrowLen - arrowPaddingMin - normalizedTetherOffsetValue.mainAxis;\n var maxOffset = isBasePlacement ? -referenceRect[len] / 2 + additive + arrowLen + arrowPaddingMax + normalizedTetherOffsetValue.mainAxis : maxLen + arrowLen + arrowPaddingMax + normalizedTetherOffsetValue.mainAxis;\n var arrowOffsetParent = state.elements.arrow && getOffsetParent(state.elements.arrow);\n var clientOffset = arrowOffsetParent ? mainAxis === 'y' ? arrowOffsetParent.clientTop || 0 : arrowOffsetParent.clientLeft || 0 : 0;\n var offsetModifierValue = (_offsetModifierState$ = offsetModifierState == null ? void 0 : offsetModifierState[mainAxis]) != null ? _offsetModifierState$ : 0;\n var tetherMin = offset + minOffset - offsetModifierValue - clientOffset;\n var tetherMax = offset + maxOffset - offsetModifierValue;\n var preventedOffset = within(tether ? mathMin(min, tetherMin) : min, offset, tether ? mathMax(max, tetherMax) : max);\n popperOffsets[mainAxis] = preventedOffset;\n data[mainAxis] = preventedOffset - offset;\n }\n\n if (checkAltAxis) {\n var _offsetModifierState$2;\n\n var _mainSide = mainAxis === 'x' ? top : left;\n\n var _altSide = mainAxis === 'x' ? bottom : right;\n\n var _offset = popperOffsets[altAxis];\n\n var _len = altAxis === 'y' ? 'height' : 'width';\n\n var _min = _offset + overflow[_mainSide];\n\n var _max = _offset - overflow[_altSide];\n\n var isOriginSide = [top, left].indexOf(basePlacement) !== -1;\n\n var _offsetModifierValue = (_offsetModifierState$2 = offsetModifierState == null ? void 0 : offsetModifierState[altAxis]) != null ? _offsetModifierState$2 : 0;\n\n var _tetherMin = isOriginSide ? _min : _offset - referenceRect[_len] - popperRect[_len] - _offsetModifierValue + normalizedTetherOffsetValue.altAxis;\n\n var _tetherMax = isOriginSide ? _offset + referenceRect[_len] + popperRect[_len] - _offsetModifierValue - normalizedTetherOffsetValue.altAxis : _max;\n\n var _preventedOffset = tether && isOriginSide ? withinMaxClamp(_tetherMin, _offset, _tetherMax) : within(tether ? _tetherMin : _min, _offset, tether ? _tetherMax : _max);\n\n popperOffsets[altAxis] = _preventedOffset;\n data[altAxis] = _preventedOffset - _offset;\n }\n\n state.modifiersData[name] = data;\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'preventOverflow',\n enabled: true,\n phase: 'main',\n fn: preventOverflow,\n requiresIfExists: ['offset']\n};","export default function getHTMLElementScroll(element) {\n return {\n scrollLeft: element.scrollLeft,\n scrollTop: element.scrollTop\n };\n}","import getWindowScroll from \"./getWindowScroll.js\";\nimport getWindow from \"./getWindow.js\";\nimport { isHTMLElement } from \"./instanceOf.js\";\nimport getHTMLElementScroll from \"./getHTMLElementScroll.js\";\nexport default function getNodeScroll(node) {\n if (node === getWindow(node) || !isHTMLElement(node)) {\n return getWindowScroll(node);\n } else {\n return getHTMLElementScroll(node);\n }\n}","import getBoundingClientRect from \"./getBoundingClientRect.js\";\nimport getNodeScroll from \"./getNodeScroll.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport { isHTMLElement } from \"./instanceOf.js\";\nimport getWindowScrollBarX from \"./getWindowScrollBarX.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport isScrollParent from \"./isScrollParent.js\";\nimport { round } from \"../utils/math.js\";\n\nfunction isElementScaled(element) {\n var rect = element.getBoundingClientRect();\n var scaleX = round(rect.width) / element.offsetWidth || 1;\n var scaleY = round(rect.height) / element.offsetHeight || 1;\n return scaleX !== 1 || scaleY !== 1;\n} // Returns the composite rect of an element relative to its offsetParent.\n// Composite means it takes into account transforms as well as layout.\n\n\nexport default function getCompositeRect(elementOrVirtualElement, offsetParent, isFixed) {\n if (isFixed === void 0) {\n isFixed = false;\n }\n\n var isOffsetParentAnElement = isHTMLElement(offsetParent);\n var offsetParentIsScaled = isHTMLElement(offsetParent) && isElementScaled(offsetParent);\n var documentElement = getDocumentElement(offsetParent);\n var rect = getBoundingClientRect(elementOrVirtualElement, offsetParentIsScaled, isFixed);\n var scroll = {\n scrollLeft: 0,\n scrollTop: 0\n };\n var offsets = {\n x: 0,\n y: 0\n };\n\n if (isOffsetParentAnElement || !isOffsetParentAnElement && !isFixed) {\n if (getNodeName(offsetParent) !== 'body' || // https://github.com/popperjs/popper-core/issues/1078\n isScrollParent(documentElement)) {\n scroll = getNodeScroll(offsetParent);\n }\n\n if (isHTMLElement(offsetParent)) {\n offsets = getBoundingClientRect(offsetParent, true);\n offsets.x += offsetParent.clientLeft;\n offsets.y += offsetParent.clientTop;\n } else if (documentElement) {\n offsets.x = getWindowScrollBarX(documentElement);\n }\n }\n\n return {\n x: rect.left + scroll.scrollLeft - offsets.x,\n y: rect.top + scroll.scrollTop - offsets.y,\n width: rect.width,\n height: rect.height\n };\n}","import { modifierPhases } from \"../enums.js\"; // source: https://stackoverflow.com/questions/49875255\n\nfunction order(modifiers) {\n var map = new Map();\n var visited = new Set();\n var result = [];\n modifiers.forEach(function (modifier) {\n map.set(modifier.name, modifier);\n }); // On visiting object, check for its dependencies and visit them recursively\n\n function sort(modifier) {\n visited.add(modifier.name);\n var requires = [].concat(modifier.requires || [], modifier.requiresIfExists || []);\n requires.forEach(function (dep) {\n if (!visited.has(dep)) {\n var depModifier = map.get(dep);\n\n if (depModifier) {\n sort(depModifier);\n }\n }\n });\n result.push(modifier);\n }\n\n modifiers.forEach(function (modifier) {\n if (!visited.has(modifier.name)) {\n // check for visited object\n sort(modifier);\n }\n });\n return result;\n}\n\nexport default function orderModifiers(modifiers) {\n // order based on dependencies\n var orderedModifiers = order(modifiers); // order based on phase\n\n return modifierPhases.reduce(function (acc, phase) {\n return acc.concat(orderedModifiers.filter(function (modifier) {\n return modifier.phase === phase;\n }));\n }, []);\n}","export default function debounce(fn) {\n var pending;\n return function () {\n if (!pending) {\n pending = new Promise(function (resolve) {\n Promise.resolve().then(function () {\n pending = undefined;\n resolve(fn());\n });\n });\n }\n\n return pending;\n };\n}","export default function mergeByName(modifiers) {\n var merged = modifiers.reduce(function (merged, current) {\n var existing = merged[current.name];\n merged[current.name] = existing ? Object.assign({}, existing, current, {\n options: Object.assign({}, existing.options, current.options),\n data: Object.assign({}, existing.data, current.data)\n }) : current;\n return merged;\n }, {}); // IE11 does not support Object.values\n\n return Object.keys(merged).map(function (key) {\n return merged[key];\n });\n}","import getCompositeRect from \"./dom-utils/getCompositeRect.js\";\nimport getLayoutRect from \"./dom-utils/getLayoutRect.js\";\nimport listScrollParents from \"./dom-utils/listScrollParents.js\";\nimport getOffsetParent from \"./dom-utils/getOffsetParent.js\";\nimport orderModifiers from \"./utils/orderModifiers.js\";\nimport debounce from \"./utils/debounce.js\";\nimport mergeByName from \"./utils/mergeByName.js\";\nimport detectOverflow from \"./utils/detectOverflow.js\";\nimport { isElement } from \"./dom-utils/instanceOf.js\";\nvar DEFAULT_OPTIONS = {\n placement: 'bottom',\n modifiers: [],\n strategy: 'absolute'\n};\n\nfunction areValidElements() {\n for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {\n args[_key] = arguments[_key];\n }\n\n return !args.some(function (element) {\n return !(element && typeof element.getBoundingClientRect === 'function');\n });\n}\n\nexport function popperGenerator(generatorOptions) {\n if (generatorOptions === void 0) {\n generatorOptions = {};\n }\n\n var _generatorOptions = generatorOptions,\n _generatorOptions$def = _generatorOptions.defaultModifiers,\n defaultModifiers = _generatorOptions$def === void 0 ? [] : _generatorOptions$def,\n _generatorOptions$def2 = _generatorOptions.defaultOptions,\n defaultOptions = _generatorOptions$def2 === void 0 ? DEFAULT_OPTIONS : _generatorOptions$def2;\n return function createPopper(reference, popper, options) {\n if (options === void 0) {\n options = defaultOptions;\n }\n\n var state = {\n placement: 'bottom',\n orderedModifiers: [],\n options: Object.assign({}, DEFAULT_OPTIONS, defaultOptions),\n modifiersData: {},\n elements: {\n reference: reference,\n popper: popper\n },\n attributes: {},\n styles: {}\n };\n var effectCleanupFns = [];\n var isDestroyed = false;\n var instance = {\n state: state,\n setOptions: function setOptions(setOptionsAction) {\n var options = typeof setOptionsAction === 'function' ? setOptionsAction(state.options) : setOptionsAction;\n cleanupModifierEffects();\n state.options = Object.assign({}, defaultOptions, state.options, options);\n state.scrollParents = {\n reference: isElement(reference) ? listScrollParents(reference) : reference.contextElement ? listScrollParents(reference.contextElement) : [],\n popper: listScrollParents(popper)\n }; // Orders the modifiers based on their dependencies and `phase`\n // properties\n\n var orderedModifiers = orderModifiers(mergeByName([].concat(defaultModifiers, state.options.modifiers))); // Strip out disabled modifiers\n\n state.orderedModifiers = orderedModifiers.filter(function (m) {\n return m.enabled;\n });\n runModifierEffects();\n return instance.update();\n },\n // Sync update – it will always be executed, even if not necessary. This\n // is useful for low frequency updates where sync behavior simplifies the\n // logic.\n // For high frequency updates (e.g. `resize` and `scroll` events), always\n // prefer the async Popper#update method\n forceUpdate: function forceUpdate() {\n if (isDestroyed) {\n return;\n }\n\n var _state$elements = state.elements,\n reference = _state$elements.reference,\n popper = _state$elements.popper; // Don't proceed if `reference` or `popper` are not valid elements\n // anymore\n\n if (!areValidElements(reference, popper)) {\n return;\n } // Store the reference and popper rects to be read by modifiers\n\n\n state.rects = {\n reference: getCompositeRect(reference, getOffsetParent(popper), state.options.strategy === 'fixed'),\n popper: getLayoutRect(popper)\n }; // Modifiers have the ability to reset the current update cycle. The\n // most common use case for this is the `flip` modifier changing the\n // placement, which then needs to re-run all the modifiers, because the\n // logic was previously ran for the previous placement and is therefore\n // stale/incorrect\n\n state.reset = false;\n state.placement = state.options.placement; // On each update cycle, the `modifiersData` property for each modifier\n // is filled with the initial data specified by the modifier. This means\n // it doesn't persist and is fresh on each update.\n // To ensure persistent data, use `${name}#persistent`\n\n state.orderedModifiers.forEach(function (modifier) {\n return state.modifiersData[modifier.name] = Object.assign({}, modifier.data);\n });\n\n for (var index = 0; index < state.orderedModifiers.length; index++) {\n if (state.reset === true) {\n state.reset = false;\n index = -1;\n continue;\n }\n\n var _state$orderedModifie = state.orderedModifiers[index],\n fn = _state$orderedModifie.fn,\n _state$orderedModifie2 = _state$orderedModifie.options,\n _options = _state$orderedModifie2 === void 0 ? {} : _state$orderedModifie2,\n name = _state$orderedModifie.name;\n\n if (typeof fn === 'function') {\n state = fn({\n state: state,\n options: _options,\n name: name,\n instance: instance\n }) || state;\n }\n }\n },\n // Async and optimistically optimized update – it will not be executed if\n // not necessary (debounced to run at most once-per-tick)\n update: debounce(function () {\n return new Promise(function (resolve) {\n instance.forceUpdate();\n resolve(state);\n });\n }),\n destroy: function destroy() {\n cleanupModifierEffects();\n isDestroyed = true;\n }\n };\n\n if (!areValidElements(reference, popper)) {\n return instance;\n }\n\n instance.setOptions(options).then(function (state) {\n if (!isDestroyed && options.onFirstUpdate) {\n options.onFirstUpdate(state);\n }\n }); // Modifiers have the ability to execute arbitrary code before the first\n // update cycle runs. They will be executed in the same order as the update\n // cycle. This is useful when a modifier adds some persistent data that\n // other modifiers need to use, but the modifier is run after the dependent\n // one.\n\n function runModifierEffects() {\n state.orderedModifiers.forEach(function (_ref) {\n var name = _ref.name,\n _ref$options = _ref.options,\n options = _ref$options === void 0 ? {} : _ref$options,\n effect = _ref.effect;\n\n if (typeof effect === 'function') {\n var cleanupFn = effect({\n state: state,\n name: name,\n instance: instance,\n options: options\n });\n\n var noopFn = function noopFn() {};\n\n effectCleanupFns.push(cleanupFn || noopFn);\n }\n });\n }\n\n function cleanupModifierEffects() {\n effectCleanupFns.forEach(function (fn) {\n return fn();\n });\n effectCleanupFns = [];\n }\n\n return instance;\n };\n}\nexport var createPopper = /*#__PURE__*/popperGenerator(); // eslint-disable-next-line import/no-unused-modules\n\nexport { detectOverflow };","import { popperGenerator, detectOverflow } from \"./createPopper.js\";\nimport eventListeners from \"./modifiers/eventListeners.js\";\nimport popperOffsets from \"./modifiers/popperOffsets.js\";\nimport computeStyles from \"./modifiers/computeStyles.js\";\nimport applyStyles from \"./modifiers/applyStyles.js\";\nimport offset from \"./modifiers/offset.js\";\nimport flip from \"./modifiers/flip.js\";\nimport preventOverflow from \"./modifiers/preventOverflow.js\";\nimport arrow from \"./modifiers/arrow.js\";\nimport hide from \"./modifiers/hide.js\";\nvar defaultModifiers = [eventListeners, popperOffsets, computeStyles, applyStyles, offset, flip, preventOverflow, arrow, hide];\nvar createPopper = /*#__PURE__*/popperGenerator({\n defaultModifiers: defaultModifiers\n}); // eslint-disable-next-line import/no-unused-modules\n\nexport { createPopper, popperGenerator, defaultModifiers, detectOverflow }; // eslint-disable-next-line import/no-unused-modules\n\nexport { createPopper as createPopperLite } from \"./popper-lite.js\"; // eslint-disable-next-line import/no-unused-modules\n\nexport * from \"./modifiers/index.js\";","import { generateUtilityClass } from '../generateUtilityClass';\nimport { generateUtilityClasses } from '../generateUtilityClasses';\nconst COMPONENT_NAME = 'Popper';\nexport function getPopperUtilityClass(slot) {\n return generateUtilityClass(COMPONENT_NAME, slot);\n}\nexport const popperClasses = generateUtilityClasses(COMPONENT_NAME, ['root']);","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"anchorEl\", \"children\", \"direction\", \"disablePortal\", \"modifiers\", \"open\", \"placement\", \"popperOptions\", \"popperRef\", \"slotProps\", \"slots\", \"TransitionProps\", \"ownerState\"],\n _excluded2 = [\"anchorEl\", \"children\", \"container\", \"direction\", \"disablePortal\", \"keepMounted\", \"modifiers\", \"open\", \"placement\", \"popperOptions\", \"popperRef\", \"style\", \"transition\", \"slotProps\", \"slots\"];\nimport * as React from 'react';\nimport { chainPropTypes, HTMLElementType, refType, unstable_ownerDocument as ownerDocument, unstable_useEnhancedEffect as useEnhancedEffect, unstable_useForkRef as useForkRef } from '@mui/utils';\nimport { createPopper } from '@popperjs/core';\nimport PropTypes from 'prop-types';\nimport { unstable_composeClasses as composeClasses } from '../composeClasses';\nimport { Portal } from '../Portal';\nimport { getPopperUtilityClass } from './popperClasses';\nimport { useSlotProps } from '../utils';\nimport { useClassNamesOverride } from '../utils/ClassNameConfigurator';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nfunction flipPlacement(placement, direction) {\n if (direction === 'ltr') {\n return placement;\n }\n switch (placement) {\n case 'bottom-end':\n return 'bottom-start';\n case 'bottom-start':\n return 'bottom-end';\n case 'top-end':\n return 'top-start';\n case 'top-start':\n return 'top-end';\n default:\n return placement;\n }\n}\nfunction resolveAnchorEl(anchorEl) {\n return typeof anchorEl === 'function' ? anchorEl() : anchorEl;\n}\nfunction isHTMLElement(element) {\n return element.nodeType !== undefined;\n}\nfunction isVirtualElement(element) {\n return !isHTMLElement(element);\n}\nconst useUtilityClasses = () => {\n const slots = {\n root: ['root']\n };\n return composeClasses(slots, useClassNamesOverride(getPopperUtilityClass));\n};\nconst defaultPopperOptions = {};\nconst PopperTooltip = /*#__PURE__*/React.forwardRef(function PopperTooltip(props, forwardedRef) {\n var _slots$root;\n const {\n anchorEl,\n children,\n direction,\n disablePortal,\n modifiers,\n open,\n placement: initialPlacement,\n popperOptions,\n popperRef: popperRefProp,\n slotProps = {},\n slots = {},\n TransitionProps\n // @ts-ignore internal logic\n // prevent from spreading to DOM, it can come from the parent component e.g. Select.\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const tooltipRef = React.useRef(null);\n const ownRef = useForkRef(tooltipRef, forwardedRef);\n const popperRef = React.useRef(null);\n const handlePopperRef = useForkRef(popperRef, popperRefProp);\n const handlePopperRefRef = React.useRef(handlePopperRef);\n useEnhancedEffect(() => {\n handlePopperRefRef.current = handlePopperRef;\n }, [handlePopperRef]);\n React.useImperativeHandle(popperRefProp, () => popperRef.current, []);\n const rtlPlacement = flipPlacement(initialPlacement, direction);\n /**\n * placement initialized from prop but can change during lifetime if modifiers.flip.\n * modifiers.flip is essentially a flip for controlled/uncontrolled behavior\n */\n const [placement, setPlacement] = React.useState(rtlPlacement);\n const [resolvedAnchorElement, setResolvedAnchorElement] = React.useState(resolveAnchorEl(anchorEl));\n React.useEffect(() => {\n if (popperRef.current) {\n popperRef.current.forceUpdate();\n }\n });\n React.useEffect(() => {\n if (anchorEl) {\n setResolvedAnchorElement(resolveAnchorEl(anchorEl));\n }\n }, [anchorEl]);\n useEnhancedEffect(() => {\n if (!resolvedAnchorElement || !open) {\n return undefined;\n }\n const handlePopperUpdate = data => {\n setPlacement(data.placement);\n };\n if (process.env.NODE_ENV !== 'production') {\n if (resolvedAnchorElement && isHTMLElement(resolvedAnchorElement) && resolvedAnchorElement.nodeType === 1) {\n const box = resolvedAnchorElement.getBoundingClientRect();\n if (process.env.NODE_ENV !== 'test' && box.top === 0 && box.left === 0 && box.right === 0 && box.bottom === 0) {\n console.warn(['MUI: The `anchorEl` prop provided to the component is invalid.', 'The anchor element should be part of the document layout.', \"Make sure the element is present in the document or that it's not display none.\"].join('\\n'));\n }\n }\n }\n let popperModifiers = [{\n name: 'preventOverflow',\n options: {\n altBoundary: disablePortal\n }\n }, {\n name: 'flip',\n options: {\n altBoundary: disablePortal\n }\n }, {\n name: 'onUpdate',\n enabled: true,\n phase: 'afterWrite',\n fn: ({\n state\n }) => {\n handlePopperUpdate(state);\n }\n }];\n if (modifiers != null) {\n popperModifiers = popperModifiers.concat(modifiers);\n }\n if (popperOptions && popperOptions.modifiers != null) {\n popperModifiers = popperModifiers.concat(popperOptions.modifiers);\n }\n const popper = createPopper(resolvedAnchorElement, tooltipRef.current, _extends({\n placement: rtlPlacement\n }, popperOptions, {\n modifiers: popperModifiers\n }));\n handlePopperRefRef.current(popper);\n return () => {\n popper.destroy();\n handlePopperRefRef.current(null);\n };\n }, [resolvedAnchorElement, disablePortal, modifiers, open, popperOptions, rtlPlacement]);\n const childProps = {\n placement: placement\n };\n if (TransitionProps !== null) {\n childProps.TransitionProps = TransitionProps;\n }\n const classes = useUtilityClasses();\n const Root = (_slots$root = slots.root) != null ? _slots$root : 'div';\n const rootProps = useSlotProps({\n elementType: Root,\n externalSlotProps: slotProps.root,\n externalForwardedProps: other,\n additionalProps: {\n role: 'tooltip',\n ref: ownRef\n },\n ownerState: props,\n className: classes.root\n });\n return /*#__PURE__*/_jsx(Root, _extends({}, rootProps, {\n children: typeof children === 'function' ? children(childProps) : children\n }));\n});\n\n/**\n * Poppers rely on the 3rd party library [Popper.js](https://popper.js.org/docs/v2/) for positioning.\n *\n * Demos:\n *\n * - [Popper](https://mui.com/base-ui/react-popper/)\n *\n * API:\n *\n * - [Popper API](https://mui.com/base-ui/react-popper/components-api/#popper)\n */\nconst Popper = /*#__PURE__*/React.forwardRef(function Popper(props, forwardedRef) {\n const {\n anchorEl,\n children,\n container: containerProp,\n direction = 'ltr',\n disablePortal = false,\n keepMounted = false,\n modifiers,\n open,\n placement = 'bottom',\n popperOptions = defaultPopperOptions,\n popperRef,\n style,\n transition = false,\n slotProps = {},\n slots = {}\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded2);\n const [exited, setExited] = React.useState(true);\n const handleEnter = () => {\n setExited(false);\n };\n const handleExited = () => {\n setExited(true);\n };\n if (!keepMounted && !open && (!transition || exited)) {\n return null;\n }\n\n // If the container prop is provided, use that\n // If the anchorEl prop is provided, use its parent body element as the container\n // If neither are provided let the Modal take care of choosing the container\n let container;\n if (containerProp) {\n container = containerProp;\n } else if (anchorEl) {\n const resolvedAnchorEl = resolveAnchorEl(anchorEl);\n container = resolvedAnchorEl && isHTMLElement(resolvedAnchorEl) ? ownerDocument(resolvedAnchorEl).body : ownerDocument(null).body;\n }\n const display = !open && keepMounted && (!transition || exited) ? 'none' : undefined;\n const transitionProps = transition ? {\n in: open,\n onEnter: handleEnter,\n onExited: handleExited\n } : undefined;\n return /*#__PURE__*/_jsx(Portal, {\n disablePortal: disablePortal,\n container: container,\n children: /*#__PURE__*/_jsx(PopperTooltip, _extends({\n anchorEl: anchorEl,\n direction: direction,\n disablePortal: disablePortal,\n modifiers: modifiers,\n ref: forwardedRef,\n open: transition ? !exited : open,\n placement: placement,\n popperOptions: popperOptions,\n popperRef: popperRef,\n slotProps: slotProps,\n slots: slots\n }, other, {\n style: _extends({\n // Prevents scroll issue, waiting for Popper.js to add this style once initiated.\n position: 'fixed',\n // Fix Popper.js display issue\n top: 0,\n left: 0,\n display\n }, style),\n TransitionProps: transitionProps,\n children: children\n }))\n });\n});\nprocess.env.NODE_ENV !== \"production\" ? Popper.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * An HTML element, [virtualElement](https://popper.js.org/docs/v2/virtual-elements/),\n * or a function that returns either.\n * It's used to set the position of the popper.\n * The return value will passed as the reference object of the Popper instance.\n */\n anchorEl: chainPropTypes(PropTypes.oneOfType([HTMLElementType, PropTypes.object, PropTypes.func]), props => {\n if (props.open) {\n const resolvedAnchorEl = resolveAnchorEl(props.anchorEl);\n if (resolvedAnchorEl && isHTMLElement(resolvedAnchorEl) && resolvedAnchorEl.nodeType === 1) {\n const box = resolvedAnchorEl.getBoundingClientRect();\n if (process.env.NODE_ENV !== 'test' && box.top === 0 && box.left === 0 && box.right === 0 && box.bottom === 0) {\n return new Error(['MUI: The `anchorEl` prop provided to the component is invalid.', 'The anchor element should be part of the document layout.', \"Make sure the element is present in the document or that it's not display none.\"].join('\\n'));\n }\n } else if (!resolvedAnchorEl || typeof resolvedAnchorEl.getBoundingClientRect !== 'function' || isVirtualElement(resolvedAnchorEl) && resolvedAnchorEl.contextElement != null && resolvedAnchorEl.contextElement.nodeType !== 1) {\n return new Error(['MUI: The `anchorEl` prop provided to the component is invalid.', 'It should be an HTML element instance or a virtualElement ', '(https://popper.js.org/docs/v2/virtual-elements/).'].join('\\n'));\n }\n }\n return null;\n }),\n /**\n * Popper render function or node.\n */\n children: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.node, PropTypes.func]),\n /**\n * An HTML element or function that returns one.\n * The `container` will have the portal children appended to it.\n *\n * You can also provide a callback, which is called in a React layout effect.\n * This lets you set the container from a ref, and also makes server-side rendering possible.\n *\n * By default, it uses the body of the top-level document object,\n * so it's simply `document.body` most of the time.\n */\n container: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.func]),\n /**\n * Direction of the text.\n * @default 'ltr'\n */\n direction: PropTypes.oneOf(['ltr', 'rtl']),\n /**\n * The `children` will be under the DOM hierarchy of the parent component.\n * @default false\n */\n disablePortal: PropTypes.bool,\n /**\n * Always keep the children in the DOM.\n * This prop can be useful in SEO situation or\n * when you want to maximize the responsiveness of the Popper.\n * @default false\n */\n keepMounted: PropTypes.bool,\n /**\n * Popper.js is based on a \"plugin-like\" architecture,\n * most of its features are fully encapsulated \"modifiers\".\n *\n * A modifier is a function that is called each time Popper.js needs to\n * compute the position of the popper.\n * For this reason, modifiers should be very performant to avoid bottlenecks.\n * To learn how to create a modifier, [read the modifiers documentation](https://popper.js.org/docs/v2/modifiers/).\n */\n modifiers: PropTypes.arrayOf(PropTypes.shape({\n data: PropTypes.object,\n effect: PropTypes.func,\n enabled: PropTypes.bool,\n fn: PropTypes.func,\n name: PropTypes.any,\n options: PropTypes.object,\n phase: PropTypes.oneOf(['afterMain', 'afterRead', 'afterWrite', 'beforeMain', 'beforeRead', 'beforeWrite', 'main', 'read', 'write']),\n requires: PropTypes.arrayOf(PropTypes.string),\n requiresIfExists: PropTypes.arrayOf(PropTypes.string)\n })),\n /**\n * If `true`, the component is shown.\n */\n open: PropTypes.bool.isRequired,\n /**\n * Popper placement.\n * @default 'bottom'\n */\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n /**\n * Options provided to the [`Popper.js`](https://popper.js.org/docs/v2/constructors/#options) instance.\n * @default {}\n */\n popperOptions: PropTypes.shape({\n modifiers: PropTypes.array,\n onFirstUpdate: PropTypes.func,\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n strategy: PropTypes.oneOf(['absolute', 'fixed'])\n }),\n /**\n * A ref that points to the used popper instance.\n */\n popperRef: refType,\n /**\n * The props used for each slot inside the Popper.\n * @default {}\n */\n slotProps: PropTypes.shape({\n root: PropTypes.oneOfType([PropTypes.func, PropTypes.object])\n }),\n /**\n * The components used for each slot inside the Popper.\n * Either a string to use a HTML element or a component.\n * @default {}\n */\n slots: PropTypes.shape({\n root: PropTypes.elementType\n }),\n /**\n * Help supporting a react-transition-group/Transition component.\n * @default false\n */\n transition: PropTypes.bool\n} : void 0;\nexport { Popper };","'use client';\n\nimport * as React from 'react';\nimport { useTheme as useThemeSystem } from '@mui/system';\nimport defaultTheme from './defaultTheme';\nimport THEME_ID from './identifier';\nexport default function useTheme() {\n const theme = useThemeSystem(defaultTheme);\n if (process.env.NODE_ENV !== 'production') {\n // eslint-disable-next-line react-hooks/rules-of-hooks\n React.useDebugValue(theme);\n }\n return theme[THEME_ID] || theme;\n}","export default function _setPrototypeOf(o, p) {\n _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function _setPrototypeOf(o, p) {\n o.__proto__ = p;\n return o;\n };\n return _setPrototypeOf(o, p);\n}","import setPrototypeOf from \"./setPrototypeOf.js\";\nexport default function _inheritsLoose(subClass, superClass) {\n subClass.prototype = Object.create(superClass.prototype);\n subClass.prototype.constructor = subClass;\n setPrototypeOf(subClass, superClass);\n}","export default {\n disabled: false\n};","import PropTypes from 'prop-types';\nexport var timeoutsShape = process.env.NODE_ENV !== 'production' ? PropTypes.oneOfType([PropTypes.number, PropTypes.shape({\n enter: PropTypes.number,\n exit: PropTypes.number,\n appear: PropTypes.number\n}).isRequired]) : null;\nexport var classNamesShape = process.env.NODE_ENV !== 'production' ? PropTypes.oneOfType([PropTypes.string, PropTypes.shape({\n enter: PropTypes.string,\n exit: PropTypes.string,\n active: PropTypes.string\n}), PropTypes.shape({\n enter: PropTypes.string,\n enterDone: PropTypes.string,\n enterActive: PropTypes.string,\n exit: PropTypes.string,\n exitDone: PropTypes.string,\n exitActive: PropTypes.string\n})]) : null;","import React from 'react';\nexport default React.createContext(null);","export var forceReflow = function forceReflow(node) {\n return node.scrollTop;\n};","import _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _inheritsLoose from \"@babel/runtime/helpers/esm/inheritsLoose\";\nimport PropTypes from 'prop-types';\nimport React from 'react';\nimport ReactDOM from 'react-dom';\nimport config from './config';\nimport { timeoutsShape } from './utils/PropTypes';\nimport TransitionGroupContext from './TransitionGroupContext';\nimport { forceReflow } from './utils/reflow';\nexport var UNMOUNTED = 'unmounted';\nexport var EXITED = 'exited';\nexport var ENTERING = 'entering';\nexport var ENTERED = 'entered';\nexport var EXITING = 'exiting';\n/**\n * The Transition component lets you describe a transition from one component\n * state to another _over time_ with a simple declarative API. Most commonly\n * it's used to animate the mounting and unmounting of a component, but can also\n * be used to describe in-place transition states as well.\n *\n * ---\n *\n * **Note**: `Transition` is a platform-agnostic base component. If you're using\n * transitions in CSS, you'll probably want to use\n * [`CSSTransition`](https://reactcommunity.org/react-transition-group/css-transition)\n * instead. It inherits all the features of `Transition`, but contains\n * additional features necessary to play nice with CSS transitions (hence the\n * name of the component).\n *\n * ---\n *\n * By default the `Transition` component does not alter the behavior of the\n * component it renders, it only tracks \"enter\" and \"exit\" states for the\n * components. It's up to you to give meaning and effect to those states. For\n * example we can add styles to a component when it enters or exits:\n *\n * ```jsx\n * import { Transition } from 'react-transition-group';\n *\n * const duration = 300;\n *\n * const defaultStyle = {\n * transition: `opacity ${duration}ms ease-in-out`,\n * opacity: 0,\n * }\n *\n * const transitionStyles = {\n * entering: { opacity: 1 },\n * entered: { opacity: 1 },\n * exiting: { opacity: 0 },\n * exited: { opacity: 0 },\n * };\n *\n * const Fade = ({ in: inProp }) => (\n * \n * {state => (\n *
    \n * I'm a fade Transition!\n *
    \n * )}\n *
    \n * );\n * ```\n *\n * There are 4 main states a Transition can be in:\n * - `'entering'`\n * - `'entered'`\n * - `'exiting'`\n * - `'exited'`\n *\n * Transition state is toggled via the `in` prop. When `true` the component\n * begins the \"Enter\" stage. During this stage, the component will shift from\n * its current transition state, to `'entering'` for the duration of the\n * transition and then to the `'entered'` stage once it's complete. Let's take\n * the following example (we'll use the\n * [useState](https://reactjs.org/docs/hooks-reference.html#usestate) hook):\n *\n * ```jsx\n * function App() {\n * const [inProp, setInProp] = useState(false);\n * return (\n *
    \n * \n * {state => (\n * // ...\n * )}\n * \n * \n *
    \n * );\n * }\n * ```\n *\n * When the button is clicked the component will shift to the `'entering'` state\n * and stay there for 500ms (the value of `timeout`) before it finally switches\n * to `'entered'`.\n *\n * When `in` is `false` the same thing happens except the state moves from\n * `'exiting'` to `'exited'`.\n */\n\nvar Transition = /*#__PURE__*/function (_React$Component) {\n _inheritsLoose(Transition, _React$Component);\n\n function Transition(props, context) {\n var _this;\n\n _this = _React$Component.call(this, props, context) || this;\n var parentGroup = context; // In the context of a TransitionGroup all enters are really appears\n\n var appear = parentGroup && !parentGroup.isMounting ? props.enter : props.appear;\n var initialStatus;\n _this.appearStatus = null;\n\n if (props.in) {\n if (appear) {\n initialStatus = EXITED;\n _this.appearStatus = ENTERING;\n } else {\n initialStatus = ENTERED;\n }\n } else {\n if (props.unmountOnExit || props.mountOnEnter) {\n initialStatus = UNMOUNTED;\n } else {\n initialStatus = EXITED;\n }\n }\n\n _this.state = {\n status: initialStatus\n };\n _this.nextCallback = null;\n return _this;\n }\n\n Transition.getDerivedStateFromProps = function getDerivedStateFromProps(_ref, prevState) {\n var nextIn = _ref.in;\n\n if (nextIn && prevState.status === UNMOUNTED) {\n return {\n status: EXITED\n };\n }\n\n return null;\n } // getSnapshotBeforeUpdate(prevProps) {\n // let nextStatus = null\n // if (prevProps !== this.props) {\n // const { status } = this.state\n // if (this.props.in) {\n // if (status !== ENTERING && status !== ENTERED) {\n // nextStatus = ENTERING\n // }\n // } else {\n // if (status === ENTERING || status === ENTERED) {\n // nextStatus = EXITING\n // }\n // }\n // }\n // return { nextStatus }\n // }\n ;\n\n var _proto = Transition.prototype;\n\n _proto.componentDidMount = function componentDidMount() {\n this.updateStatus(true, this.appearStatus);\n };\n\n _proto.componentDidUpdate = function componentDidUpdate(prevProps) {\n var nextStatus = null;\n\n if (prevProps !== this.props) {\n var status = this.state.status;\n\n if (this.props.in) {\n if (status !== ENTERING && status !== ENTERED) {\n nextStatus = ENTERING;\n }\n } else {\n if (status === ENTERING || status === ENTERED) {\n nextStatus = EXITING;\n }\n }\n }\n\n this.updateStatus(false, nextStatus);\n };\n\n _proto.componentWillUnmount = function componentWillUnmount() {\n this.cancelNextCallback();\n };\n\n _proto.getTimeouts = function getTimeouts() {\n var timeout = this.props.timeout;\n var exit, enter, appear;\n exit = enter = appear = timeout;\n\n if (timeout != null && typeof timeout !== 'number') {\n exit = timeout.exit;\n enter = timeout.enter; // TODO: remove fallback for next major\n\n appear = timeout.appear !== undefined ? timeout.appear : enter;\n }\n\n return {\n exit: exit,\n enter: enter,\n appear: appear\n };\n };\n\n _proto.updateStatus = function updateStatus(mounting, nextStatus) {\n if (mounting === void 0) {\n mounting = false;\n }\n\n if (nextStatus !== null) {\n // nextStatus will always be ENTERING or EXITING.\n this.cancelNextCallback();\n\n if (nextStatus === ENTERING) {\n if (this.props.unmountOnExit || this.props.mountOnEnter) {\n var node = this.props.nodeRef ? this.props.nodeRef.current : ReactDOM.findDOMNode(this); // https://github.com/reactjs/react-transition-group/pull/749\n // With unmountOnExit or mountOnEnter, the enter animation should happen at the transition between `exited` and `entering`.\n // To make the animation happen, we have to separate each rendering and avoid being processed as batched.\n\n if (node) forceReflow(node);\n }\n\n this.performEnter(mounting);\n } else {\n this.performExit();\n }\n } else if (this.props.unmountOnExit && this.state.status === EXITED) {\n this.setState({\n status: UNMOUNTED\n });\n }\n };\n\n _proto.performEnter = function performEnter(mounting) {\n var _this2 = this;\n\n var enter = this.props.enter;\n var appearing = this.context ? this.context.isMounting : mounting;\n\n var _ref2 = this.props.nodeRef ? [appearing] : [ReactDOM.findDOMNode(this), appearing],\n maybeNode = _ref2[0],\n maybeAppearing = _ref2[1];\n\n var timeouts = this.getTimeouts();\n var enterTimeout = appearing ? timeouts.appear : timeouts.enter; // no enter animation skip right to ENTERED\n // if we are mounting and running this it means appear _must_ be set\n\n if (!mounting && !enter || config.disabled) {\n this.safeSetState({\n status: ENTERED\n }, function () {\n _this2.props.onEntered(maybeNode);\n });\n return;\n }\n\n this.props.onEnter(maybeNode, maybeAppearing);\n this.safeSetState({\n status: ENTERING\n }, function () {\n _this2.props.onEntering(maybeNode, maybeAppearing);\n\n _this2.onTransitionEnd(enterTimeout, function () {\n _this2.safeSetState({\n status: ENTERED\n }, function () {\n _this2.props.onEntered(maybeNode, maybeAppearing);\n });\n });\n });\n };\n\n _proto.performExit = function performExit() {\n var _this3 = this;\n\n var exit = this.props.exit;\n var timeouts = this.getTimeouts();\n var maybeNode = this.props.nodeRef ? undefined : ReactDOM.findDOMNode(this); // no exit animation skip right to EXITED\n\n if (!exit || config.disabled) {\n this.safeSetState({\n status: EXITED\n }, function () {\n _this3.props.onExited(maybeNode);\n });\n return;\n }\n\n this.props.onExit(maybeNode);\n this.safeSetState({\n status: EXITING\n }, function () {\n _this3.props.onExiting(maybeNode);\n\n _this3.onTransitionEnd(timeouts.exit, function () {\n _this3.safeSetState({\n status: EXITED\n }, function () {\n _this3.props.onExited(maybeNode);\n });\n });\n });\n };\n\n _proto.cancelNextCallback = function cancelNextCallback() {\n if (this.nextCallback !== null) {\n this.nextCallback.cancel();\n this.nextCallback = null;\n }\n };\n\n _proto.safeSetState = function safeSetState(nextState, callback) {\n // This shouldn't be necessary, but there are weird race conditions with\n // setState callbacks and unmounting in testing, so always make sure that\n // we can cancel any pending setState callbacks after we unmount.\n callback = this.setNextCallback(callback);\n this.setState(nextState, callback);\n };\n\n _proto.setNextCallback = function setNextCallback(callback) {\n var _this4 = this;\n\n var active = true;\n\n this.nextCallback = function (event) {\n if (active) {\n active = false;\n _this4.nextCallback = null;\n callback(event);\n }\n };\n\n this.nextCallback.cancel = function () {\n active = false;\n };\n\n return this.nextCallback;\n };\n\n _proto.onTransitionEnd = function onTransitionEnd(timeout, handler) {\n this.setNextCallback(handler);\n var node = this.props.nodeRef ? this.props.nodeRef.current : ReactDOM.findDOMNode(this);\n var doesNotHaveTimeoutOrListener = timeout == null && !this.props.addEndListener;\n\n if (!node || doesNotHaveTimeoutOrListener) {\n setTimeout(this.nextCallback, 0);\n return;\n }\n\n if (this.props.addEndListener) {\n var _ref3 = this.props.nodeRef ? [this.nextCallback] : [node, this.nextCallback],\n maybeNode = _ref3[0],\n maybeNextCallback = _ref3[1];\n\n this.props.addEndListener(maybeNode, maybeNextCallback);\n }\n\n if (timeout != null) {\n setTimeout(this.nextCallback, timeout);\n }\n };\n\n _proto.render = function render() {\n var status = this.state.status;\n\n if (status === UNMOUNTED) {\n return null;\n }\n\n var _this$props = this.props,\n children = _this$props.children,\n _in = _this$props.in,\n _mountOnEnter = _this$props.mountOnEnter,\n _unmountOnExit = _this$props.unmountOnExit,\n _appear = _this$props.appear,\n _enter = _this$props.enter,\n _exit = _this$props.exit,\n _timeout = _this$props.timeout,\n _addEndListener = _this$props.addEndListener,\n _onEnter = _this$props.onEnter,\n _onEntering = _this$props.onEntering,\n _onEntered = _this$props.onEntered,\n _onExit = _this$props.onExit,\n _onExiting = _this$props.onExiting,\n _onExited = _this$props.onExited,\n _nodeRef = _this$props.nodeRef,\n childProps = _objectWithoutPropertiesLoose(_this$props, [\"children\", \"in\", \"mountOnEnter\", \"unmountOnExit\", \"appear\", \"enter\", \"exit\", \"timeout\", \"addEndListener\", \"onEnter\", \"onEntering\", \"onEntered\", \"onExit\", \"onExiting\", \"onExited\", \"nodeRef\"]);\n\n return (\n /*#__PURE__*/\n // allows for nested Transitions\n React.createElement(TransitionGroupContext.Provider, {\n value: null\n }, typeof children === 'function' ? children(status, childProps) : React.cloneElement(React.Children.only(children), childProps))\n );\n };\n\n return Transition;\n}(React.Component);\n\nTransition.contextType = TransitionGroupContext;\nTransition.propTypes = process.env.NODE_ENV !== \"production\" ? {\n /**\n * A React reference to DOM element that need to transition:\n * https://stackoverflow.com/a/51127130/4671932\n *\n * - When `nodeRef` prop is used, `node` is not passed to callback functions\n * (e.g. `onEnter`) because user already has direct access to the node.\n * - When changing `key` prop of `Transition` in a `TransitionGroup` a new\n * `nodeRef` need to be provided to `Transition` with changed `key` prop\n * (see\n * [test/CSSTransition-test.js](https://github.com/reactjs/react-transition-group/blob/13435f897b3ab71f6e19d724f145596f5910581c/test/CSSTransition-test.js#L362-L437)).\n */\n nodeRef: PropTypes.shape({\n current: typeof Element === 'undefined' ? PropTypes.any : function (propValue, key, componentName, location, propFullName, secret) {\n var value = propValue[key];\n return PropTypes.instanceOf(value && 'ownerDocument' in value ? value.ownerDocument.defaultView.Element : Element)(propValue, key, componentName, location, propFullName, secret);\n }\n }),\n\n /**\n * A `function` child can be used instead of a React element. This function is\n * called with the current transition status (`'entering'`, `'entered'`,\n * `'exiting'`, `'exited'`), which can be used to apply context\n * specific props to a component.\n *\n * ```jsx\n * \n * {state => (\n * \n * )}\n * \n * ```\n */\n children: PropTypes.oneOfType([PropTypes.func.isRequired, PropTypes.element.isRequired]).isRequired,\n\n /**\n * Show the component; triggers the enter or exit states\n */\n in: PropTypes.bool,\n\n /**\n * By default the child component is mounted immediately along with\n * the parent `Transition` component. If you want to \"lazy mount\" the component on the\n * first `in={true}` you can set `mountOnEnter`. After the first enter transition the component will stay\n * mounted, even on \"exited\", unless you also specify `unmountOnExit`.\n */\n mountOnEnter: PropTypes.bool,\n\n /**\n * By default the child component stays mounted after it reaches the `'exited'` state.\n * Set `unmountOnExit` if you'd prefer to unmount the component after it finishes exiting.\n */\n unmountOnExit: PropTypes.bool,\n\n /**\n * By default the child component does not perform the enter transition when\n * it first mounts, regardless of the value of `in`. If you want this\n * behavior, set both `appear` and `in` to `true`.\n *\n * > **Note**: there are no special appear states like `appearing`/`appeared`, this prop\n * > only adds an additional enter transition. However, in the\n * > `` component that first enter transition does result in\n * > additional `.appear-*` classes, that way you can choose to style it\n * > differently.\n */\n appear: PropTypes.bool,\n\n /**\n * Enable or disable enter transitions.\n */\n enter: PropTypes.bool,\n\n /**\n * Enable or disable exit transitions.\n */\n exit: PropTypes.bool,\n\n /**\n * The duration of the transition, in milliseconds.\n * Required unless `addEndListener` is provided.\n *\n * You may specify a single timeout for all transitions:\n *\n * ```jsx\n * timeout={500}\n * ```\n *\n * or individually:\n *\n * ```jsx\n * timeout={{\n * appear: 500,\n * enter: 300,\n * exit: 500,\n * }}\n * ```\n *\n * - `appear` defaults to the value of `enter`\n * - `enter` defaults to `0`\n * - `exit` defaults to `0`\n *\n * @type {number | { enter?: number, exit?: number, appear?: number }}\n */\n timeout: function timeout(props) {\n var pt = timeoutsShape;\n if (!props.addEndListener) pt = pt.isRequired;\n\n for (var _len = arguments.length, args = new Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) {\n args[_key - 1] = arguments[_key];\n }\n\n return pt.apply(void 0, [props].concat(args));\n },\n\n /**\n * Add a custom transition end trigger. Called with the transitioning\n * DOM node and a `done` callback. Allows for more fine grained transition end\n * logic. Timeouts are still used as a fallback if provided.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * ```jsx\n * addEndListener={(node, done) => {\n * // use the css transitionend event to mark the finish of a transition\n * node.addEventListener('transitionend', done, false);\n * }}\n * ```\n */\n addEndListener: PropTypes.func,\n\n /**\n * Callback fired before the \"entering\" status is applied. An extra parameter\n * `isAppearing` is supplied to indicate if the enter stage is occurring on the initial mount\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement, isAppearing: bool) -> void\n */\n onEnter: PropTypes.func,\n\n /**\n * Callback fired after the \"entering\" status is applied. An extra parameter\n * `isAppearing` is supplied to indicate if the enter stage is occurring on the initial mount\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement, isAppearing: bool)\n */\n onEntering: PropTypes.func,\n\n /**\n * Callback fired after the \"entered\" status is applied. An extra parameter\n * `isAppearing` is supplied to indicate if the enter stage is occurring on the initial mount\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement, isAppearing: bool) -> void\n */\n onEntered: PropTypes.func,\n\n /**\n * Callback fired before the \"exiting\" status is applied.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement) -> void\n */\n onExit: PropTypes.func,\n\n /**\n * Callback fired after the \"exiting\" status is applied.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed.\n *\n * @type Function(node: HtmlElement) -> void\n */\n onExiting: PropTypes.func,\n\n /**\n * Callback fired after the \"exited\" status is applied.\n *\n * **Note**: when `nodeRef` prop is passed, `node` is not passed\n *\n * @type Function(node: HtmlElement) -> void\n */\n onExited: PropTypes.func\n} : {}; // Name the function so it is clearer in the documentation\n\nfunction noop() {}\n\nTransition.defaultProps = {\n in: false,\n mountOnEnter: false,\n unmountOnExit: false,\n appear: false,\n enter: true,\n exit: true,\n onEnter: noop,\n onEntering: noop,\n onEntered: noop,\n onExit: noop,\n onExiting: noop,\n onExited: noop\n};\nTransition.UNMOUNTED = UNMOUNTED;\nTransition.EXITED = EXITED;\nTransition.ENTERING = ENTERING;\nTransition.ENTERED = ENTERED;\nTransition.EXITING = EXITING;\nexport default Transition;","export const reflow = node => node.scrollTop;\nexport function getTransitionProps(props, options) {\n var _style$transitionDura, _style$transitionTimi;\n const {\n timeout,\n easing,\n style = {}\n } = props;\n return {\n duration: (_style$transitionDura = style.transitionDuration) != null ? _style$transitionDura : typeof timeout === 'number' ? timeout : timeout[options.mode] || 0,\n easing: (_style$transitionTimi = style.transitionTimingFunction) != null ? _style$transitionTimi : typeof easing === 'object' ? easing[options.mode] : easing,\n delay: style.transitionDelay\n };\n}","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"addEndListener\", \"appear\", \"children\", \"easing\", \"in\", \"onEnter\", \"onEntered\", \"onEntering\", \"onExit\", \"onExited\", \"onExiting\", \"style\", \"timeout\", \"TransitionComponent\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport { elementAcceptingRef, unstable_useTimeout as useTimeout } from '@mui/utils';\nimport { Transition } from 'react-transition-group';\nimport useTheme from '../styles/useTheme';\nimport { getTransitionProps, reflow } from '../transitions/utils';\nimport useForkRef from '../utils/useForkRef';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nfunction getScale(value) {\n return `scale(${value}, ${value ** 2})`;\n}\nconst styles = {\n entering: {\n opacity: 1,\n transform: getScale(1)\n },\n entered: {\n opacity: 1,\n transform: 'none'\n }\n};\n\n/*\n TODO v6: remove\n Conditionally apply a workaround for the CSS transition bug in Safari 15.4 / WebKit browsers.\n */\nconst isWebKit154 = typeof navigator !== 'undefined' && /^((?!chrome|android).)*(safari|mobile)/i.test(navigator.userAgent) && /(os |version\\/)15(.|_)4/i.test(navigator.userAgent);\n\n/**\n * The Grow transition is used by the [Tooltip](/material-ui/react-tooltip/) and\n * [Popover](/material-ui/react-popover/) components.\n * It uses [react-transition-group](https://github.com/reactjs/react-transition-group) internally.\n */\nconst Grow = /*#__PURE__*/React.forwardRef(function Grow(props, ref) {\n const {\n addEndListener,\n appear = true,\n children,\n easing,\n in: inProp,\n onEnter,\n onEntered,\n onEntering,\n onExit,\n onExited,\n onExiting,\n style,\n timeout = 'auto',\n // eslint-disable-next-line react/prop-types\n TransitionComponent = Transition\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const timer = useTimeout();\n const autoTimeout = React.useRef();\n const theme = useTheme();\n const nodeRef = React.useRef(null);\n const handleRef = useForkRef(nodeRef, children.ref, ref);\n const normalizedTransitionCallback = callback => maybeIsAppearing => {\n if (callback) {\n const node = nodeRef.current;\n\n // onEnterXxx and onExitXxx callbacks have a different arguments.length value.\n if (maybeIsAppearing === undefined) {\n callback(node);\n } else {\n callback(node, maybeIsAppearing);\n }\n }\n };\n const handleEntering = normalizedTransitionCallback(onEntering);\n const handleEnter = normalizedTransitionCallback((node, isAppearing) => {\n reflow(node); // So the animation always start from the start.\n\n const {\n duration: transitionDuration,\n delay,\n easing: transitionTimingFunction\n } = getTransitionProps({\n style,\n timeout,\n easing\n }, {\n mode: 'enter'\n });\n let duration;\n if (timeout === 'auto') {\n duration = theme.transitions.getAutoHeightDuration(node.clientHeight);\n autoTimeout.current = duration;\n } else {\n duration = transitionDuration;\n }\n node.style.transition = [theme.transitions.create('opacity', {\n duration,\n delay\n }), theme.transitions.create('transform', {\n duration: isWebKit154 ? duration : duration * 0.666,\n delay,\n easing: transitionTimingFunction\n })].join(',');\n if (onEnter) {\n onEnter(node, isAppearing);\n }\n });\n const handleEntered = normalizedTransitionCallback(onEntered);\n const handleExiting = normalizedTransitionCallback(onExiting);\n const handleExit = normalizedTransitionCallback(node => {\n const {\n duration: transitionDuration,\n delay,\n easing: transitionTimingFunction\n } = getTransitionProps({\n style,\n timeout,\n easing\n }, {\n mode: 'exit'\n });\n let duration;\n if (timeout === 'auto') {\n duration = theme.transitions.getAutoHeightDuration(node.clientHeight);\n autoTimeout.current = duration;\n } else {\n duration = transitionDuration;\n }\n node.style.transition = [theme.transitions.create('opacity', {\n duration,\n delay\n }), theme.transitions.create('transform', {\n duration: isWebKit154 ? duration : duration * 0.666,\n delay: isWebKit154 ? delay : delay || duration * 0.333,\n easing: transitionTimingFunction\n })].join(',');\n node.style.opacity = 0;\n node.style.transform = getScale(0.75);\n if (onExit) {\n onExit(node);\n }\n });\n const handleExited = normalizedTransitionCallback(onExited);\n const handleAddEndListener = next => {\n if (timeout === 'auto') {\n timer.start(autoTimeout.current || 0, next);\n }\n if (addEndListener) {\n // Old call signature before `react-transition-group` implemented `nodeRef`\n addEndListener(nodeRef.current, next);\n }\n };\n return /*#__PURE__*/_jsx(TransitionComponent, _extends({\n appear: appear,\n in: inProp,\n nodeRef: nodeRef,\n onEnter: handleEnter,\n onEntered: handleEntered,\n onEntering: handleEntering,\n onExit: handleExit,\n onExited: handleExited,\n onExiting: handleExiting,\n addEndListener: handleAddEndListener,\n timeout: timeout === 'auto' ? null : timeout\n }, other, {\n children: (state, childProps) => {\n return /*#__PURE__*/React.cloneElement(children, _extends({\n style: _extends({\n opacity: 0,\n transform: getScale(0.75),\n visibility: state === 'exited' && !inProp ? 'hidden' : undefined\n }, styles[state], style, children.props.style),\n ref: handleRef\n }, childProps));\n }\n }));\n});\nprocess.env.NODE_ENV !== \"production\" ? Grow.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the d.ts file and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * Add a custom transition end trigger. Called with the transitioning DOM\n * node and a done callback. Allows for more fine grained transition end\n * logic. Note: Timeouts are still used as a fallback if provided.\n */\n addEndListener: PropTypes.func,\n /**\n * Perform the enter transition when it first mounts if `in` is also `true`.\n * Set this to `false` to disable this behavior.\n * @default true\n */\n appear: PropTypes.bool,\n /**\n * A single child content element.\n */\n children: elementAcceptingRef.isRequired,\n /**\n * The transition timing function.\n * You may specify a single easing or a object containing enter and exit values.\n */\n easing: PropTypes.oneOfType([PropTypes.shape({\n enter: PropTypes.string,\n exit: PropTypes.string\n }), PropTypes.string]),\n /**\n * If `true`, the component will transition in.\n */\n in: PropTypes.bool,\n /**\n * @ignore\n */\n onEnter: PropTypes.func,\n /**\n * @ignore\n */\n onEntered: PropTypes.func,\n /**\n * @ignore\n */\n onEntering: PropTypes.func,\n /**\n * @ignore\n */\n onExit: PropTypes.func,\n /**\n * @ignore\n */\n onExited: PropTypes.func,\n /**\n * @ignore\n */\n onExiting: PropTypes.func,\n /**\n * @ignore\n */\n style: PropTypes.object,\n /**\n * The duration for the transition, in milliseconds.\n * You may specify a single timeout for all transitions, or individually with an object.\n *\n * Set to 'auto' to automatically calculate transition time based on height.\n * @default 'auto'\n */\n timeout: PropTypes.oneOfType([PropTypes.oneOf(['auto']), PropTypes.number, PropTypes.shape({\n appear: PropTypes.number,\n enter: PropTypes.number,\n exit: PropTypes.number\n })])\n} : void 0;\nGrow.muiSupportAuto = true;\nexport default Grow;","'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"anchorEl\", \"component\", \"components\", \"componentsProps\", \"container\", \"disablePortal\", \"keepMounted\", \"modifiers\", \"open\", \"placement\", \"popperOptions\", \"popperRef\", \"transition\", \"slots\", \"slotProps\"];\nimport { Popper as BasePopper } from '@mui/base/Popper';\nimport { useThemeWithoutDefault as useTheme } from '@mui/system';\nimport { HTMLElementType, refType } from '@mui/utils';\nimport PropTypes from 'prop-types';\nimport * as React from 'react';\nimport { styled, useThemeProps } from '../styles';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nconst PopperRoot = styled(BasePopper, {\n name: 'MuiPopper',\n slot: 'Root',\n overridesResolver: (props, styles) => styles.root\n})({});\n\n/**\n *\n * Demos:\n *\n * - [Autocomplete](https://mui.com/material-ui/react-autocomplete/)\n * - [Menu](https://mui.com/material-ui/react-menu/)\n * - [Popper](https://mui.com/material-ui/react-popper/)\n *\n * API:\n *\n * - [Popper API](https://mui.com/material-ui/api/popper/)\n */\nconst Popper = /*#__PURE__*/React.forwardRef(function Popper(inProps, ref) {\n var _slots$root;\n const theme = useTheme();\n const props = useThemeProps({\n props: inProps,\n name: 'MuiPopper'\n });\n const {\n anchorEl,\n component,\n components,\n componentsProps,\n container,\n disablePortal,\n keepMounted,\n modifiers,\n open,\n placement,\n popperOptions,\n popperRef,\n transition,\n slots,\n slotProps\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n const RootComponent = (_slots$root = slots == null ? void 0 : slots.root) != null ? _slots$root : components == null ? void 0 : components.Root;\n const otherProps = _extends({\n anchorEl,\n container,\n disablePortal,\n keepMounted,\n modifiers,\n open,\n placement,\n popperOptions,\n popperRef,\n transition\n }, other);\n return /*#__PURE__*/_jsx(PopperRoot, _extends({\n as: component,\n direction: theme == null ? void 0 : theme.direction,\n slots: {\n root: RootComponent\n },\n slotProps: slotProps != null ? slotProps : componentsProps\n }, otherProps, {\n ref: ref\n }));\n});\nprocess.env.NODE_ENV !== \"production\" ? Popper.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * An HTML element, [virtualElement](https://popper.js.org/docs/v2/virtual-elements/),\n * or a function that returns either.\n * It's used to set the position of the popper.\n * The return value will passed as the reference object of the Popper instance.\n */\n anchorEl: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.object, PropTypes.func]),\n /**\n * Popper render function or node.\n */\n children: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.node, PropTypes.func]),\n /**\n * The component used for the root node.\n * Either a string to use a HTML element or a component.\n */\n component: PropTypes.elementType,\n /**\n * The components used for each slot inside the Popper.\n * Either a string to use a HTML element or a component.\n * @default {}\n */\n components: PropTypes.shape({\n Root: PropTypes.elementType\n }),\n /**\n * The props used for each slot inside the Popper.\n * @default {}\n */\n componentsProps: PropTypes.shape({\n root: PropTypes.oneOfType([PropTypes.func, PropTypes.object])\n }),\n /**\n * An HTML element or function that returns one.\n * The `container` will have the portal children appended to it.\n *\n * You can also provide a callback, which is called in a React layout effect.\n * This lets you set the container from a ref, and also makes server-side rendering possible.\n *\n * By default, it uses the body of the top-level document object,\n * so it's simply `document.body` most of the time.\n */\n container: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([HTMLElementType, PropTypes.func]),\n /**\n * The `children` will be under the DOM hierarchy of the parent component.\n * @default false\n */\n disablePortal: PropTypes.bool,\n /**\n * Always keep the children in the DOM.\n * This prop can be useful in SEO situation or\n * when you want to maximize the responsiveness of the Popper.\n * @default false\n */\n keepMounted: PropTypes.bool,\n /**\n * Popper.js is based on a \"plugin-like\" architecture,\n * most of its features are fully encapsulated \"modifiers\".\n *\n * A modifier is a function that is called each time Popper.js needs to\n * compute the position of the popper.\n * For this reason, modifiers should be very performant to avoid bottlenecks.\n * To learn how to create a modifier, [read the modifiers documentation](https://popper.js.org/docs/v2/modifiers/).\n */\n modifiers: PropTypes.arrayOf(PropTypes.shape({\n data: PropTypes.object,\n effect: PropTypes.func,\n enabled: PropTypes.bool,\n fn: PropTypes.func,\n name: PropTypes.any,\n options: PropTypes.object,\n phase: PropTypes.oneOf(['afterMain', 'afterRead', 'afterWrite', 'beforeMain', 'beforeRead', 'beforeWrite', 'main', 'read', 'write']),\n requires: PropTypes.arrayOf(PropTypes.string),\n requiresIfExists: PropTypes.arrayOf(PropTypes.string)\n })),\n /**\n * If `true`, the component is shown.\n */\n open: PropTypes.bool.isRequired,\n /**\n * Popper placement.\n * @default 'bottom'\n */\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n /**\n * Options provided to the [`Popper.js`](https://popper.js.org/docs/v2/constructors/#options) instance.\n * @default {}\n */\n popperOptions: PropTypes.shape({\n modifiers: PropTypes.array,\n onFirstUpdate: PropTypes.func,\n placement: PropTypes.oneOf(['auto-end', 'auto-start', 'auto', 'bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n strategy: PropTypes.oneOf(['absolute', 'fixed'])\n }),\n /**\n * A ref that points to the used popper instance.\n */\n popperRef: refType,\n /**\n * The props used for each slot inside the Popper.\n * @default {}\n */\n slotProps: PropTypes.shape({\n root: PropTypes.oneOfType([PropTypes.func, PropTypes.object])\n }),\n /**\n * The components used for each slot inside the Popper.\n * Either a string to use a HTML element or a component.\n * @default {}\n */\n slots: PropTypes.shape({\n root: PropTypes.elementType\n }),\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Help supporting a react-transition-group/Transition component.\n * @default false\n */\n transition: PropTypes.bool\n} : void 0;\nexport default Popper;","import generateUtilityClasses from '@mui/utils/generateUtilityClasses';\nimport generateUtilityClass from '@mui/utils/generateUtilityClass';\nexport function getTooltipUtilityClass(slot) {\n return generateUtilityClass('MuiTooltip', slot);\n}\nconst tooltipClasses = generateUtilityClasses('MuiTooltip', ['popper', 'popperInteractive', 'popperArrow', 'popperClose', 'tooltip', 'tooltipArrow', 'touch', 'tooltipPlacementLeft', 'tooltipPlacementRight', 'tooltipPlacementTop', 'tooltipPlacementBottom', 'arrow']);\nexport default tooltipClasses;","'use client';\n\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nconst _excluded = [\"arrow\", \"children\", \"classes\", \"components\", \"componentsProps\", \"describeChild\", \"disableFocusListener\", \"disableHoverListener\", \"disableInteractive\", \"disableTouchListener\", \"enterDelay\", \"enterNextDelay\", \"enterTouchDelay\", \"followCursor\", \"id\", \"leaveDelay\", \"leaveTouchDelay\", \"onClose\", \"onOpen\", \"open\", \"placement\", \"PopperComponent\", \"PopperProps\", \"slotProps\", \"slots\", \"title\", \"TransitionComponent\", \"TransitionProps\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport clsx from 'clsx';\nimport { elementAcceptingRef, unstable_useTimeout as useTimeout, unstable_Timeout as Timeout } from '@mui/utils';\nimport { unstable_composeClasses as composeClasses, appendOwnerState } from '@mui/base';\nimport { alpha } from '@mui/system';\nimport styled from '../styles/styled';\nimport useTheme from '../styles/useTheme';\nimport useThemeProps from '../styles/useThemeProps';\nimport capitalize from '../utils/capitalize';\nimport Grow from '../Grow';\nimport Popper from '../Popper';\nimport useEventCallback from '../utils/useEventCallback';\nimport useForkRef from '../utils/useForkRef';\nimport useId from '../utils/useId';\nimport useIsFocusVisible from '../utils/useIsFocusVisible';\nimport useControlled from '../utils/useControlled';\nimport tooltipClasses, { getTooltipUtilityClass } from './tooltipClasses';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nimport { jsxs as _jsxs } from \"react/jsx-runtime\";\nfunction round(value) {\n return Math.round(value * 1e5) / 1e5;\n}\nconst useUtilityClasses = ownerState => {\n const {\n classes,\n disableInteractive,\n arrow,\n touch,\n placement\n } = ownerState;\n const slots = {\n popper: ['popper', !disableInteractive && 'popperInteractive', arrow && 'popperArrow'],\n tooltip: ['tooltip', arrow && 'tooltipArrow', touch && 'touch', `tooltipPlacement${capitalize(placement.split('-')[0])}`],\n arrow: ['arrow']\n };\n return composeClasses(slots, getTooltipUtilityClass, classes);\n};\nconst TooltipPopper = styled(Popper, {\n name: 'MuiTooltip',\n slot: 'Popper',\n overridesResolver: (props, styles) => {\n const {\n ownerState\n } = props;\n return [styles.popper, !ownerState.disableInteractive && styles.popperInteractive, ownerState.arrow && styles.popperArrow, !ownerState.open && styles.popperClose];\n }\n})(({\n theme,\n ownerState,\n open\n}) => _extends({\n zIndex: (theme.vars || theme).zIndex.tooltip,\n pointerEvents: 'none'\n}, !ownerState.disableInteractive && {\n pointerEvents: 'auto'\n}, !open && {\n pointerEvents: 'none'\n}, ownerState.arrow && {\n [`&[data-popper-placement*=\"bottom\"] .${tooltipClasses.arrow}`]: {\n top: 0,\n marginTop: '-0.71em',\n '&::before': {\n transformOrigin: '0 100%'\n }\n },\n [`&[data-popper-placement*=\"top\"] .${tooltipClasses.arrow}`]: {\n bottom: 0,\n marginBottom: '-0.71em',\n '&::before': {\n transformOrigin: '100% 0'\n }\n },\n [`&[data-popper-placement*=\"right\"] .${tooltipClasses.arrow}`]: _extends({}, !ownerState.isRtl ? {\n left: 0,\n marginLeft: '-0.71em'\n } : {\n right: 0,\n marginRight: '-0.71em'\n }, {\n height: '1em',\n width: '0.71em',\n '&::before': {\n transformOrigin: '100% 100%'\n }\n }),\n [`&[data-popper-placement*=\"left\"] .${tooltipClasses.arrow}`]: _extends({}, !ownerState.isRtl ? {\n right: 0,\n marginRight: '-0.71em'\n } : {\n left: 0,\n marginLeft: '-0.71em'\n }, {\n height: '1em',\n width: '0.71em',\n '&::before': {\n transformOrigin: '0 0'\n }\n })\n}));\nconst TooltipTooltip = styled('div', {\n name: 'MuiTooltip',\n slot: 'Tooltip',\n overridesResolver: (props, styles) => {\n const {\n ownerState\n } = props;\n return [styles.tooltip, ownerState.touch && styles.touch, ownerState.arrow && styles.tooltipArrow, styles[`tooltipPlacement${capitalize(ownerState.placement.split('-')[0])}`]];\n }\n})(({\n theme,\n ownerState\n}) => _extends({\n backgroundColor: theme.vars ? theme.vars.palette.Tooltip.bg : alpha(theme.palette.grey[700], 0.92),\n borderRadius: (theme.vars || theme).shape.borderRadius,\n color: (theme.vars || theme).palette.common.white,\n fontFamily: theme.typography.fontFamily,\n padding: '4px 8px',\n fontSize: theme.typography.pxToRem(11),\n maxWidth: 300,\n margin: 2,\n wordWrap: 'break-word',\n fontWeight: theme.typography.fontWeightMedium\n}, ownerState.arrow && {\n position: 'relative',\n margin: 0\n}, ownerState.touch && {\n padding: '8px 16px',\n fontSize: theme.typography.pxToRem(14),\n lineHeight: `${round(16 / 14)}em`,\n fontWeight: theme.typography.fontWeightRegular\n}, {\n [`.${tooltipClasses.popper}[data-popper-placement*=\"left\"] &`]: _extends({\n transformOrigin: 'right center'\n }, !ownerState.isRtl ? _extends({\n marginRight: '14px'\n }, ownerState.touch && {\n marginRight: '24px'\n }) : _extends({\n marginLeft: '14px'\n }, ownerState.touch && {\n marginLeft: '24px'\n })),\n [`.${tooltipClasses.popper}[data-popper-placement*=\"right\"] &`]: _extends({\n transformOrigin: 'left center'\n }, !ownerState.isRtl ? _extends({\n marginLeft: '14px'\n }, ownerState.touch && {\n marginLeft: '24px'\n }) : _extends({\n marginRight: '14px'\n }, ownerState.touch && {\n marginRight: '24px'\n })),\n [`.${tooltipClasses.popper}[data-popper-placement*=\"top\"] &`]: _extends({\n transformOrigin: 'center bottom',\n marginBottom: '14px'\n }, ownerState.touch && {\n marginBottom: '24px'\n }),\n [`.${tooltipClasses.popper}[data-popper-placement*=\"bottom\"] &`]: _extends({\n transformOrigin: 'center top',\n marginTop: '14px'\n }, ownerState.touch && {\n marginTop: '24px'\n })\n}));\nconst TooltipArrow = styled('span', {\n name: 'MuiTooltip',\n slot: 'Arrow',\n overridesResolver: (props, styles) => styles.arrow\n})(({\n theme\n}) => ({\n overflow: 'hidden',\n position: 'absolute',\n width: '1em',\n height: '0.71em' /* = width / sqrt(2) = (length of the hypotenuse) */,\n boxSizing: 'border-box',\n color: theme.vars ? theme.vars.palette.Tooltip.bg : alpha(theme.palette.grey[700], 0.9),\n '&::before': {\n content: '\"\"',\n margin: 'auto',\n display: 'block',\n width: '100%',\n height: '100%',\n backgroundColor: 'currentColor',\n transform: 'rotate(45deg)'\n }\n}));\nlet hystersisOpen = false;\nconst hystersisTimer = new Timeout();\nlet cursorPosition = {\n x: 0,\n y: 0\n};\nexport function testReset() {\n hystersisOpen = false;\n hystersisTimer.clear();\n}\nfunction composeEventHandler(handler, eventHandler) {\n return event => {\n if (eventHandler) {\n eventHandler(event);\n }\n handler(event);\n };\n}\n\n// TODO v6: Remove PopperComponent, PopperProps, TransitionComponent and TransitionProps.\nconst Tooltip = /*#__PURE__*/React.forwardRef(function Tooltip(inProps, ref) {\n var _ref, _slots$popper, _ref2, _ref3, _slots$transition, _ref4, _slots$tooltip, _ref5, _slots$arrow, _slotProps$popper, _ref6, _slotProps$popper2, _slotProps$transition, _slotProps$tooltip, _ref7, _slotProps$tooltip2, _slotProps$arrow, _ref8, _slotProps$arrow2;\n const props = useThemeProps({\n props: inProps,\n name: 'MuiTooltip'\n });\n const {\n arrow = false,\n children: childrenProp,\n components = {},\n componentsProps = {},\n describeChild = false,\n disableFocusListener = false,\n disableHoverListener = false,\n disableInteractive: disableInteractiveProp = false,\n disableTouchListener = false,\n enterDelay = 100,\n enterNextDelay = 0,\n enterTouchDelay = 700,\n followCursor = false,\n id: idProp,\n leaveDelay = 0,\n leaveTouchDelay = 1500,\n onClose,\n onOpen,\n open: openProp,\n placement = 'bottom',\n PopperComponent: PopperComponentProp,\n PopperProps = {},\n slotProps = {},\n slots = {},\n title,\n TransitionComponent: TransitionComponentProp = Grow,\n TransitionProps\n } = props,\n other = _objectWithoutPropertiesLoose(props, _excluded);\n\n // to prevent runtime errors, developers will need to provide a child as a React element anyway.\n const children = /*#__PURE__*/React.isValidElement(childrenProp) ? childrenProp : /*#__PURE__*/_jsx(\"span\", {\n children: childrenProp\n });\n const theme = useTheme();\n const isRtl = theme.direction === 'rtl';\n const [childNode, setChildNode] = React.useState();\n const [arrowRef, setArrowRef] = React.useState(null);\n const ignoreNonTouchEvents = React.useRef(false);\n const disableInteractive = disableInteractiveProp || followCursor;\n const closeTimer = useTimeout();\n const enterTimer = useTimeout();\n const leaveTimer = useTimeout();\n const touchTimer = useTimeout();\n const [openState, setOpenState] = useControlled({\n controlled: openProp,\n default: false,\n name: 'Tooltip',\n state: 'open'\n });\n let open = openState;\n if (process.env.NODE_ENV !== 'production') {\n // eslint-disable-next-line react-hooks/rules-of-hooks\n const {\n current: isControlled\n } = React.useRef(openProp !== undefined);\n\n // eslint-disable-next-line react-hooks/rules-of-hooks\n React.useEffect(() => {\n if (childNode && childNode.disabled && !isControlled && title !== '' && childNode.tagName.toLowerCase() === 'button') {\n console.error(['MUI: You are providing a disabled `button` child to the Tooltip component.', 'A disabled element does not fire events.', \"Tooltip needs to listen to the child element's events to display the title.\", '', 'Add a simple wrapper element, such as a `span`.'].join('\\n'));\n }\n }, [title, childNode, isControlled]);\n }\n const id = useId(idProp);\n const prevUserSelect = React.useRef();\n const stopTouchInteraction = useEventCallback(() => {\n if (prevUserSelect.current !== undefined) {\n document.body.style.WebkitUserSelect = prevUserSelect.current;\n prevUserSelect.current = undefined;\n }\n touchTimer.clear();\n });\n React.useEffect(() => stopTouchInteraction, [stopTouchInteraction]);\n const handleOpen = event => {\n hystersisTimer.clear();\n hystersisOpen = true;\n\n // The mouseover event will trigger for every nested element in the tooltip.\n // We can skip rerendering when the tooltip is already open.\n // We are using the mouseover event instead of the mouseenter event to fix a hide/show issue.\n setOpenState(true);\n if (onOpen && !open) {\n onOpen(event);\n }\n };\n const handleClose = useEventCallback(\n /**\n * @param {React.SyntheticEvent | Event} event\n */\n event => {\n hystersisTimer.start(800 + leaveDelay, () => {\n hystersisOpen = false;\n });\n setOpenState(false);\n if (onClose && open) {\n onClose(event);\n }\n closeTimer.start(theme.transitions.duration.shortest, () => {\n ignoreNonTouchEvents.current = false;\n });\n });\n const handleEnter = event => {\n if (ignoreNonTouchEvents.current && event.type !== 'touchstart') {\n return;\n }\n\n // Remove the title ahead of time.\n // We don't want to wait for the next render commit.\n // We would risk displaying two tooltips at the same time (native + this one).\n if (childNode) {\n childNode.removeAttribute('title');\n }\n enterTimer.clear();\n leaveTimer.clear();\n if (enterDelay || hystersisOpen && enterNextDelay) {\n enterTimer.start(hystersisOpen ? enterNextDelay : enterDelay, () => {\n handleOpen(event);\n });\n } else {\n handleOpen(event);\n }\n };\n const handleLeave = event => {\n enterTimer.clear();\n leaveTimer.start(leaveDelay, () => {\n handleClose(event);\n });\n };\n const {\n isFocusVisibleRef,\n onBlur: handleBlurVisible,\n onFocus: handleFocusVisible,\n ref: focusVisibleRef\n } = useIsFocusVisible();\n // We don't necessarily care about the focusVisible state (which is safe to access via ref anyway).\n // We just need to re-render the Tooltip if the focus-visible state changes.\n const [, setChildIsFocusVisible] = React.useState(false);\n const handleBlur = event => {\n handleBlurVisible(event);\n if (isFocusVisibleRef.current === false) {\n setChildIsFocusVisible(false);\n handleLeave(event);\n }\n };\n const handleFocus = event => {\n // Workaround for https://github.com/facebook/react/issues/7769\n // The autoFocus of React might trigger the event before the componentDidMount.\n // We need to account for this eventuality.\n if (!childNode) {\n setChildNode(event.currentTarget);\n }\n handleFocusVisible(event);\n if (isFocusVisibleRef.current === true) {\n setChildIsFocusVisible(true);\n handleEnter(event);\n }\n };\n const detectTouchStart = event => {\n ignoreNonTouchEvents.current = true;\n const childrenProps = children.props;\n if (childrenProps.onTouchStart) {\n childrenProps.onTouchStart(event);\n }\n };\n const handleMouseOver = handleEnter;\n const handleMouseLeave = handleLeave;\n const handleTouchStart = event => {\n detectTouchStart(event);\n leaveTimer.clear();\n closeTimer.clear();\n stopTouchInteraction();\n prevUserSelect.current = document.body.style.WebkitUserSelect;\n // Prevent iOS text selection on long-tap.\n document.body.style.WebkitUserSelect = 'none';\n touchTimer.start(enterTouchDelay, () => {\n document.body.style.WebkitUserSelect = prevUserSelect.current;\n handleEnter(event);\n });\n };\n const handleTouchEnd = event => {\n if (children.props.onTouchEnd) {\n children.props.onTouchEnd(event);\n }\n stopTouchInteraction();\n leaveTimer.start(leaveTouchDelay, () => {\n handleClose(event);\n });\n };\n React.useEffect(() => {\n if (!open) {\n return undefined;\n }\n\n /**\n * @param {KeyboardEvent} nativeEvent\n */\n function handleKeyDown(nativeEvent) {\n // IE11, Edge (prior to using Bink?) use 'Esc'\n if (nativeEvent.key === 'Escape' || nativeEvent.key === 'Esc') {\n handleClose(nativeEvent);\n }\n }\n document.addEventListener('keydown', handleKeyDown);\n return () => {\n document.removeEventListener('keydown', handleKeyDown);\n };\n }, [handleClose, open]);\n const handleRef = useForkRef(children.ref, focusVisibleRef, setChildNode, ref);\n\n // There is no point in displaying an empty tooltip.\n // So we exclude all falsy values, except 0, which is valid.\n if (!title && title !== 0) {\n open = false;\n }\n const popperRef = React.useRef();\n const handleMouseMove = event => {\n const childrenProps = children.props;\n if (childrenProps.onMouseMove) {\n childrenProps.onMouseMove(event);\n }\n cursorPosition = {\n x: event.clientX,\n y: event.clientY\n };\n if (popperRef.current) {\n popperRef.current.update();\n }\n };\n const nameOrDescProps = {};\n const titleIsString = typeof title === 'string';\n if (describeChild) {\n nameOrDescProps.title = !open && titleIsString && !disableHoverListener ? title : null;\n nameOrDescProps['aria-describedby'] = open ? id : null;\n } else {\n nameOrDescProps['aria-label'] = titleIsString ? title : null;\n nameOrDescProps['aria-labelledby'] = open && !titleIsString ? id : null;\n }\n const childrenProps = _extends({}, nameOrDescProps, other, children.props, {\n className: clsx(other.className, children.props.className),\n onTouchStart: detectTouchStart,\n ref: handleRef\n }, followCursor ? {\n onMouseMove: handleMouseMove\n } : {});\n if (process.env.NODE_ENV !== 'production') {\n childrenProps['data-mui-internal-clone-element'] = true;\n\n // eslint-disable-next-line react-hooks/rules-of-hooks\n React.useEffect(() => {\n if (childNode && !childNode.getAttribute('data-mui-internal-clone-element')) {\n console.error(['MUI: The `children` component of the Tooltip is not forwarding its props correctly.', 'Please make sure that props are spread on the same element that the ref is applied to.'].join('\\n'));\n }\n }, [childNode]);\n }\n const interactiveWrapperListeners = {};\n if (!disableTouchListener) {\n childrenProps.onTouchStart = handleTouchStart;\n childrenProps.onTouchEnd = handleTouchEnd;\n }\n if (!disableHoverListener) {\n childrenProps.onMouseOver = composeEventHandler(handleMouseOver, childrenProps.onMouseOver);\n childrenProps.onMouseLeave = composeEventHandler(handleMouseLeave, childrenProps.onMouseLeave);\n if (!disableInteractive) {\n interactiveWrapperListeners.onMouseOver = handleMouseOver;\n interactiveWrapperListeners.onMouseLeave = handleMouseLeave;\n }\n }\n if (!disableFocusListener) {\n childrenProps.onFocus = composeEventHandler(handleFocus, childrenProps.onFocus);\n childrenProps.onBlur = composeEventHandler(handleBlur, childrenProps.onBlur);\n if (!disableInteractive) {\n interactiveWrapperListeners.onFocus = handleFocus;\n interactiveWrapperListeners.onBlur = handleBlur;\n }\n }\n if (process.env.NODE_ENV !== 'production') {\n if (children.props.title) {\n console.error(['MUI: You have provided a `title` prop to the child of .', `Remove this title prop \\`${children.props.title}\\` or the Tooltip component.`].join('\\n'));\n }\n }\n const popperOptions = React.useMemo(() => {\n var _PopperProps$popperOp;\n let tooltipModifiers = [{\n name: 'arrow',\n enabled: Boolean(arrowRef),\n options: {\n element: arrowRef,\n padding: 4\n }\n }];\n if ((_PopperProps$popperOp = PopperProps.popperOptions) != null && _PopperProps$popperOp.modifiers) {\n tooltipModifiers = tooltipModifiers.concat(PopperProps.popperOptions.modifiers);\n }\n return _extends({}, PopperProps.popperOptions, {\n modifiers: tooltipModifiers\n });\n }, [arrowRef, PopperProps]);\n const ownerState = _extends({}, props, {\n isRtl,\n arrow,\n disableInteractive,\n placement,\n PopperComponentProp,\n touch: ignoreNonTouchEvents.current\n });\n const classes = useUtilityClasses(ownerState);\n const PopperComponent = (_ref = (_slots$popper = slots.popper) != null ? _slots$popper : components.Popper) != null ? _ref : TooltipPopper;\n const TransitionComponent = (_ref2 = (_ref3 = (_slots$transition = slots.transition) != null ? _slots$transition : components.Transition) != null ? _ref3 : TransitionComponentProp) != null ? _ref2 : Grow;\n const TooltipComponent = (_ref4 = (_slots$tooltip = slots.tooltip) != null ? _slots$tooltip : components.Tooltip) != null ? _ref4 : TooltipTooltip;\n const ArrowComponent = (_ref5 = (_slots$arrow = slots.arrow) != null ? _slots$arrow : components.Arrow) != null ? _ref5 : TooltipArrow;\n const popperProps = appendOwnerState(PopperComponent, _extends({}, PopperProps, (_slotProps$popper = slotProps.popper) != null ? _slotProps$popper : componentsProps.popper, {\n className: clsx(classes.popper, PopperProps == null ? void 0 : PopperProps.className, (_ref6 = (_slotProps$popper2 = slotProps.popper) != null ? _slotProps$popper2 : componentsProps.popper) == null ? void 0 : _ref6.className)\n }), ownerState);\n const transitionProps = appendOwnerState(TransitionComponent, _extends({}, TransitionProps, (_slotProps$transition = slotProps.transition) != null ? _slotProps$transition : componentsProps.transition), ownerState);\n const tooltipProps = appendOwnerState(TooltipComponent, _extends({}, (_slotProps$tooltip = slotProps.tooltip) != null ? _slotProps$tooltip : componentsProps.tooltip, {\n className: clsx(classes.tooltip, (_ref7 = (_slotProps$tooltip2 = slotProps.tooltip) != null ? _slotProps$tooltip2 : componentsProps.tooltip) == null ? void 0 : _ref7.className)\n }), ownerState);\n const tooltipArrowProps = appendOwnerState(ArrowComponent, _extends({}, (_slotProps$arrow = slotProps.arrow) != null ? _slotProps$arrow : componentsProps.arrow, {\n className: clsx(classes.arrow, (_ref8 = (_slotProps$arrow2 = slotProps.arrow) != null ? _slotProps$arrow2 : componentsProps.arrow) == null ? void 0 : _ref8.className)\n }), ownerState);\n return /*#__PURE__*/_jsxs(React.Fragment, {\n children: [/*#__PURE__*/React.cloneElement(children, childrenProps), /*#__PURE__*/_jsx(PopperComponent, _extends({\n as: PopperComponentProp != null ? PopperComponentProp : Popper,\n placement: placement,\n anchorEl: followCursor ? {\n getBoundingClientRect: () => ({\n top: cursorPosition.y,\n left: cursorPosition.x,\n right: cursorPosition.x,\n bottom: cursorPosition.y,\n width: 0,\n height: 0\n })\n } : childNode,\n popperRef: popperRef,\n open: childNode ? open : false,\n id: id,\n transition: true\n }, interactiveWrapperListeners, popperProps, {\n popperOptions: popperOptions,\n children: ({\n TransitionProps: TransitionPropsInner\n }) => /*#__PURE__*/_jsx(TransitionComponent, _extends({\n timeout: theme.transitions.duration.shorter\n }, TransitionPropsInner, transitionProps, {\n children: /*#__PURE__*/_jsxs(TooltipComponent, _extends({}, tooltipProps, {\n children: [title, arrow ? /*#__PURE__*/_jsx(ArrowComponent, _extends({}, tooltipArrowProps, {\n ref: setArrowRef\n })) : null]\n }))\n }))\n }))]\n });\n});\nprocess.env.NODE_ENV !== \"production\" ? Tooltip.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the d.ts file and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * If `true`, adds an arrow to the tooltip.\n * @default false\n */\n arrow: PropTypes.bool,\n /**\n * Tooltip reference element.\n */\n children: elementAcceptingRef.isRequired,\n /**\n * Override or extend the styles applied to the component.\n */\n classes: PropTypes.object,\n /**\n * @ignore\n */\n className: PropTypes.string,\n /**\n * The components used for each slot inside.\n *\n * This prop is an alias for the `slots` prop.\n * It's recommended to use the `slots` prop instead.\n *\n * @default {}\n */\n components: PropTypes.shape({\n Arrow: PropTypes.elementType,\n Popper: PropTypes.elementType,\n Tooltip: PropTypes.elementType,\n Transition: PropTypes.elementType\n }),\n /**\n * The extra props for the slot components.\n * You can override the existing props or add new ones.\n *\n * This prop is an alias for the `slotProps` prop.\n * It's recommended to use the `slotProps` prop instead, as `componentsProps` will be deprecated in the future.\n *\n * @default {}\n */\n componentsProps: PropTypes.shape({\n arrow: PropTypes.object,\n popper: PropTypes.object,\n tooltip: PropTypes.object,\n transition: PropTypes.object\n }),\n /**\n * Set to `true` if the `title` acts as an accessible description.\n * By default the `title` acts as an accessible label for the child.\n * @default false\n */\n describeChild: PropTypes.bool,\n /**\n * Do not respond to focus-visible events.\n * @default false\n */\n disableFocusListener: PropTypes.bool,\n /**\n * Do not respond to hover events.\n * @default false\n */\n disableHoverListener: PropTypes.bool,\n /**\n * Makes a tooltip not interactive, i.e. it will close when the user\n * hovers over the tooltip before the `leaveDelay` is expired.\n * @default false\n */\n disableInteractive: PropTypes.bool,\n /**\n * Do not respond to long press touch events.\n * @default false\n */\n disableTouchListener: PropTypes.bool,\n /**\n * The number of milliseconds to wait before showing the tooltip.\n * This prop won't impact the enter touch delay (`enterTouchDelay`).\n * @default 100\n */\n enterDelay: PropTypes.number,\n /**\n * The number of milliseconds to wait before showing the tooltip when one was already recently opened.\n * @default 0\n */\n enterNextDelay: PropTypes.number,\n /**\n * The number of milliseconds a user must touch the element before showing the tooltip.\n * @default 700\n */\n enterTouchDelay: PropTypes.number,\n /**\n * If `true`, the tooltip follow the cursor over the wrapped element.\n * @default false\n */\n followCursor: PropTypes.bool,\n /**\n * This prop is used to help implement the accessibility logic.\n * If you don't provide this prop. It falls back to a randomly generated id.\n */\n id: PropTypes.string,\n /**\n * The number of milliseconds to wait before hiding the tooltip.\n * This prop won't impact the leave touch delay (`leaveTouchDelay`).\n * @default 0\n */\n leaveDelay: PropTypes.number,\n /**\n * The number of milliseconds after the user stops touching an element before hiding the tooltip.\n * @default 1500\n */\n leaveTouchDelay: PropTypes.number,\n /**\n * Callback fired when the component requests to be closed.\n *\n * @param {React.SyntheticEvent} event The event source of the callback.\n */\n onClose: PropTypes.func,\n /**\n * Callback fired when the component requests to be open.\n *\n * @param {React.SyntheticEvent} event The event source of the callback.\n */\n onOpen: PropTypes.func,\n /**\n * If `true`, the component is shown.\n */\n open: PropTypes.bool,\n /**\n * Tooltip placement.\n * @default 'bottom'\n */\n placement: PropTypes.oneOf(['bottom-end', 'bottom-start', 'bottom', 'left-end', 'left-start', 'left', 'right-end', 'right-start', 'right', 'top-end', 'top-start', 'top']),\n /**\n * The component used for the popper.\n * @default Popper\n */\n PopperComponent: PropTypes.elementType,\n /**\n * Props applied to the [`Popper`](/material-ui/api/popper/) element.\n * @default {}\n */\n PopperProps: PropTypes.object,\n /**\n * The extra props for the slot components.\n * You can override the existing props or add new ones.\n *\n * This prop is an alias for the `componentsProps` prop, which will be deprecated in the future.\n *\n * @default {}\n */\n slotProps: PropTypes.shape({\n arrow: PropTypes.object,\n popper: PropTypes.object,\n tooltip: PropTypes.object,\n transition: PropTypes.object\n }),\n /**\n * The components used for each slot inside.\n *\n * This prop is an alias for the `components` prop, which will be deprecated in the future.\n *\n * @default {}\n */\n slots: PropTypes.shape({\n arrow: PropTypes.elementType,\n popper: PropTypes.elementType,\n tooltip: PropTypes.elementType,\n transition: PropTypes.elementType\n }),\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),\n /**\n * Tooltip title. Zero-length titles string, undefined, null and false are never displayed.\n */\n title: PropTypes.node,\n /**\n * The component used for the transition.\n * [Follow this guide](/material-ui/transitions/#transitioncomponent-prop) to learn more about the requirements for this component.\n * @default Grow\n */\n TransitionComponent: PropTypes.elementType,\n /**\n * Props applied to the transition element.\n * By default, the element is based on this [`Transition`](http://reactcommunity.org/react-transition-group/transition/) component.\n */\n TransitionProps: PropTypes.object\n} : void 0;\nexport default Tooltip;","import '@/components/mui/menu-item.component.css';\nimport ArrowRightIcon from '@mui/icons-material/ArrowRight';\nimport {\n ListItemIcon as MuiListItemIcon,\n ListItemText as MuiListItemText,\n MenuItem as MuiMenuItem,\n} from '@mui/material';\nimport Tooltip from '@mui/material/Tooltip';\nimport { Localized, ReferencedItem, SingleColumnMenu } from 'platform-bible-utils';\nimport { MouseEvent, PropsWithChildren } from 'react';\n\ntype MenuItemInfoBase = {\n /** Text (displayable in the UI) as the name of the menu item */\n label: string;\n /** Text to display when the mouse hovers over the menu item */\n tooltip?: string;\n};\n\nexport type Command = MenuItemInfoBase & {\n /** Command to execute (string.string) */\n command: string;\n};\n\ntype SubMenu = MenuItemInfoBase & {\n /** Command to execute (string.string) */\n items: MenuItemInfo[];\n};\n\nexport interface CommandHandler {\n (command: Command): void;\n}\n\nexport type MenuPropsBase = {\n /*\n * The JSON defining the menu whose items are to be rendered. This will typically be one of the\n * menus in the \"defs\" in a Platform.Bible menu (see PlatformMenus). The schema for this is\n * menuDocumentSchema (at the end of menus.model.ts). Note that while this is a\n * \"SingleColumnMenu\", somewhat bizarrely, a MultiColumnMenu is a SingleColumnMenu, so it really\n * could be a MultiColumnMenu, in which case, column had better be defined so it can be used\n * to filter out the actual groups and items to display on the column.\n */\n menuDefinition: Localized;\n\n commandHandler: CommandHandler;\n\n /**\n * Additional action to perform when any menu item is clicked. Allows the caller to handle event\n * (e.g., to close the menu).\n */\n onClick?: (event: MouseEvent) => void;\n};\n\nexport type MenuItemListProps = MenuPropsBase & {\n /** Optional unique (column) identifier */\n columnId?: ReferencedItem;\n};\n\nexport type MenuItemProps = Omit &\n PropsWithChildren<{\n /** Optional unique identifier */\n id?: string;\n\n onClick: (event: MouseEvent) => void;\n }>;\n\ntype MenuItemInfo = (Command | SubMenu) & {\n /**\n * If specified, menu item will be inset if it does not have a leading icon.\n *\n * @default true\n */\n allowForLeadingIcons?: boolean;\n /**\n * If specified, the path to the icon image to display on the leading side of the menu text.\n *\n * @default undefined (no leading icon will be shown)\n */\n iconPathBefore?: string;\n /**\n * If specified, the path to the icon image to display on the trailing side of the menu text.\n *\n * @default undefined (no trailing icon will be shown)\n */\n iconPathAfter?: string;\n /**\n * If true, list item is focused during the first mount\n *\n * @default false\n */\n hasAutoFocus?: boolean;\n\n /** Additional css classes to help with unique styling of the menu item */\n className?: string;\n\n /**\n * If true, the menu item will appear disabled and it will not respond to clicks or mouse hovers.\n *\n * @default false\n */\n isDisabled?: boolean;\n\n /**\n * If true, compact vertical padding designed for keyboard and mouse input is used.\n *\n * @default true\n */\n isDense?: boolean;\n\n /**\n * If true, a right-arrow icon will be displayed (iconPathAfter, if specified, will be ignored).\n *\n * @default false\n */\n isSubMenuParent?: boolean;\n\n /**\n * If true, the left and right padding is removed\n *\n * @default false\n */\n hasDisabledGutters?: boolean;\n\n /**\n * If true, a 1px light border is added to bottom of menu item\n *\n * @default false\n */\n hasDivider?: boolean;\n\n /** Help identify which element has keyboard focus */\n focusVisibleClassName?: string;\n\n /** If it's a submenu, it should have the items property */\n items?: MenuItemInfo[];\n};\n\nfunction getIcon(icon: string | undefined, menuLabel: string, leading: boolean) {\n return icon ? (\n \n {`${leading\n \n ) : undefined;\n}\n\nexport default function MenuItem(props: MenuItemProps) {\n const {\n onClick,\n label,\n tooltip,\n allowForLeadingIcons = true,\n iconPathBefore = undefined,\n iconPathAfter = undefined,\n hasAutoFocus = false,\n className,\n isDisabled = false,\n isDense = true,\n isSubMenuParent = false,\n hasDisabledGutters = false,\n hasDivider = false,\n focusVisibleClassName,\n id,\n children,\n } = props;\n\n const menuItem = (\n \n {label ? (\n <>\n {getIcon(iconPathBefore, label, true)}\n \n {isSubMenuParent ? (\n \n \n \n ) : (\n getIcon(iconPathAfter, label, false)\n )}\n \n ) : (\n children\n )}\n \n );\n\n return tooltip ? (\n \n
    {menuItem}
    \n
    \n ) : (\n menuItem\n );\n}\n","import MenuItem, {\n MenuItemListProps,\n MenuItemProps,\n MenuPropsBase,\n} from '@/components/mui/menu-item.component';\nimport { Menu } from '@mui/material';\nimport {\n Localized,\n MenuGroupDetailsInSubMenu,\n MenuItemContainingCommand,\n MenuItemContainingSubmenu,\n OrderedExtensibleContainer,\n ReferencedItem,\n SingleColumnMenu,\n} from 'platform-bible-utils';\nimport { MouseEvent, useMemo, useState } from 'react';\n\n/**\n * All the exported types in this file should be regarded as \"internal\" (i.e., they should not be\n * exposed via index.ts).\n */\n\nexport type GroupedMenuPropsBase = MenuPropsBase & {\n /** Optional unique (column) identifier */\n columnId?: ReferencedItem;\n};\n\nexport type GroupedMenuItemListProps = MenuItemListProps & {\n /**\n * If the menuDefinition includes \"top-level\" groups (i.e., those that belong to a column as\n * opposed to those that belong to a submenu) that should not be included in the list, then this\n * array specifies which groups to include. Likewise, for a submenu, this list indicates which\n * groups are pertinent for that submenu. So then for a context menu this property need not be\n * specified since it is a top-level menu based on a \"true\" SingleColumnMenu (i.e., one that is\n * not a MultiColumnMenu).\n */\n includedGroups?: {\n id: string;\n group: Localized;\n }[];\n};\n\ninterface ItemInfo {\n item: Localized;\n isLastItemInGroup: boolean;\n}\n\ntype SubMenuProps = MenuPropsBase & {\n parentMenuItem: Localized;\n parentItemProps: Omit, 'iconPathAfter'>;\n};\n\nfunction getAllGroups(menuDefinition: Localized) {\n const groupEntries = Object.entries(menuDefinition.groups);\n // Convert array of entries to array of objects with id and group properties\n return groupEntries.map(([key, value]) => ({ id: key, group: value }));\n}\n\nfunction SubMenu(props: SubMenuProps) {\n const [anchorEl, setAnchorEl] = useState(undefined);\n\n const { parentMenuItem, parentItemProps, menuDefinition } = props;\n\n const handleParentMenuItemClick = (event: MouseEvent) => {\n setAnchorEl(event.currentTarget);\n };\n\n const handleClose = () => {\n setAnchorEl(undefined);\n };\n\n const renderSubMenuItems = () => {\n let includedGroups = getAllGroups(menuDefinition).filter((g) => 'menuItem' in g.group);\n\n // Ensure valid parent menu was provided. (If not, submenu will contain all groups!)\n if (!parentMenuItem?.id) throw new Error('A valid parent menu item is required for submenus.');\n\n // When laying out a submenu, only include groups associated with the provided parent menu.\n // Note: without the (annoying) redundant check that the included groups\n // have the menuItem field, TS doesn't think it exists.\n includedGroups = includedGroups.filter(\n (group) => 'menuItem' in group.group && group.group.menuItem === parentMenuItem.id,\n );\n\n return ;\n };\n\n return (\n <>\n \n \n {renderSubMenuItems()}\n \n \n );\n}\n\nconst getOrderedGroupItems = (\n groupId: string,\n allItems: Localized[],\n) => {\n // Filter items that belong to the specified group\n const itemsForGroup = allItems.filter((item) => item.group === groupId);\n // Sort items based on order\n const sortedItems = itemsForGroup.sort((a, b) => (a.order || 0) - (b.order || 0));\n return sortedItems;\n};\n\n/**\n * This component is internal; it does not need to be exposed to the outside world since it is not\n * useful on its own. It is used to generate and lay out the MenuItems that appear either on a\n * top-level menu (in a GridMenu or ContextMenu) or in a submenu.\n */\nexport default function GroupedMenuItemList(menuProps: GroupedMenuItemListProps) {\n const { menuDefinition, onClick, commandHandler, includedGroups } = menuProps;\n\n const { items, allowForLeadingIcons } = useMemo(() => {\n const groupsToInclude =\n includedGroups && includedGroups.length > 0\n ? includedGroups\n : // We're apparently laying out a single-column menu (presumably a context menu). In this\n // case, all groups should be included except ones that belong to a submenu.\n getAllGroups(menuDefinition).filter((g) => !('menuItem' in g.group));\n\n const sortedGroups = Object.values(groupsToInclude).sort(\n (a, b) => (a.group.order || 0) - (b.group.order || 0),\n );\n\n const itemArray: ItemInfo[] = [];\n\n sortedGroups.forEach((group) => {\n getOrderedGroupItems(group.id, menuDefinition.items).forEach((item) =>\n itemArray.push({ item, isLastItemInGroup: false }),\n );\n if (itemArray.length > 0) itemArray[itemArray.length - 1].isLastItemInGroup = true;\n });\n\n // No divider after last item in final group.\n if (itemArray.length > 0) itemArray[itemArray.length - 1].isLastItemInGroup = false;\n\n const allowSpaceForLeadingIcons = itemArray.some(\n (i) => 'iconPathBefore' in i.item && i.item.iconPathBefore,\n );\n\n return { items: itemArray, allowForLeadingIcons: allowSpaceForLeadingIcons };\n }, [includedGroups, menuDefinition]);\n\n // Create props for MenuItem component including setting hasDivider for the last item in a group\n const createMenuItemProps = ({ item, isLastItemInGroup }: ItemInfo) => {\n const menuItemProps = {\n className: 'papi-menu-item',\n label: item.label,\n tooltip: item.tooltip,\n iconPathBefore: 'iconPathBefore' in item ? item.iconPathBefore : undefined,\n iconPathAfter: 'iconPathAfter' in item ? item.iconPathAfter : undefined,\n hasDivider: isLastItemInGroup, // Set hasDivider to true for the last item in a group\n allowForLeadingIcons,\n };\n\n return menuItemProps;\n };\n\n const [firstItem] = items;\n\n if (!firstItem) return
    ;\n\n const divKey = firstItem.item.group;\n\n return (\n
    \n {items.map((itemInfo, index) => {\n const { item } = itemInfo;\n const menuItemProps = createMenuItemProps(itemInfo);\n if ('command' in item) {\n const key = item.group + index;\n return (\n ) => {\n onClick?.(event);\n commandHandler(item);\n }}\n {...menuItemProps}\n />\n );\n }\n return (\n \n );\n })}\n
    \n );\n}\n","import GroupedMenuItemList from '@/components/mui/grouped-menu-item-list.component';\nimport { MenuItemListProps } from '@/components/mui/menu-item.component';\nimport { MultiColumnMenu } from 'platform-bible-utils';\n\n/**\n * This component is internal; it does not need to be exposed to the outside world since it is not\n * useful on its own. Use either GridMenu or ContextMenu.\n */\nexport default function TopLevelMenu(props: MenuItemListProps) {\n const { menuDefinition, columnId } = props;\n\n const groupEntries = Object.entries(menuDefinition.groups);\n // Convert array of entries to array of objects with id and group properties\n const groups = groupEntries.map(([key, value]) => ({ id: key, group: value }));\n let includedGroups = groups.filter((g) => 'column' in g.group);\n\n // Check if column is provided and menuDefinition is a MultiColumnMenu\n if (\n columnId &&\n 'columns' in menuDefinition &&\n // Without this type assertion, TS doesn't know what columns is.\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n (menuDefinition as MultiColumnMenu).columns[columnId]\n ) {\n // When laying out a single column in a MultiColumnMenu, only include groups associated with\n // the provided column. Note: without the (annoying) redundant check that the included groups\n // have the colum field, TS doesn't think it exists.\n includedGroups = includedGroups.filter(\n (g) => 'column' in g.group && g.group.column === columnId,\n );\n }\n\n return ;\n}\n","import '@/components/mui/grid-menu.component.css';\nimport { GroupedMenuPropsBase } from '@/components/mui/grouped-menu-item-list.component';\nimport { CommandHandler } from '@/components/mui/menu-item.component';\nimport TopLevelMenu from '@/components/mui/top-level-menu.component';\nimport { Grid, List } from '@mui/material';\nimport {\n Localized,\n MenuColumnWithHeader,\n MultiColumnMenu,\n ReferencedItem,\n} from 'platform-bible-utils';\nimport { useMemo } from 'react';\n\ntype ColumnInfo = {\n /*\n * The ID (`${string}.${string}`) of a specific menu column.\n */\n id: ReferencedItem;\n\n /*\n * Metadata (label, order, etc.) for a specific menu column.\n */\n metadata: Localized;\n};\n\ntype MenuColumnProps = ColumnInfo &\n GroupedMenuPropsBase & {\n /** Additional css classes to help with unique styling of the menu column */\n className?: string;\n };\n\nexport type GridMenuInfo = {\n /** The menu object containing information about the columns, groups, and items to display. */\n multiColumnMenu: Localized;\n};\n\nexport type GridMenuProps = GridMenuInfo & {\n /** Optional unique identifier */\n id?: string;\n\n commandHandler: CommandHandler;\n\n /** Additional css classes to help with unique styling of the grid menu */\n className?: string;\n};\n\nfunction MenuColumn({\n commandHandler,\n menuDefinition,\n id,\n metadata,\n onClick,\n className,\n}: MenuColumnProps) {\n return (\n \n

    \n {metadata.label}\n

    \n {/* It would seem as though this List component were unnecessary, since it only contains one\n thing, but the \"dense\" property does affect the layout of the items (in a way I don't fully\n understand). There might be a better way. */}\n \n \n \n \n );\n}\n\nexport default function GridMenu({\n commandHandler,\n className,\n multiColumnMenu,\n id,\n}: GridMenuProps) {\n const { columns } = multiColumnMenu;\n\n const sortedColumns = useMemo(() => {\n const columnNumbers = new Map();\n Object.getOwnPropertyNames(columns).forEach((columnName: string) => {\n // We know for sure there is a (boolean) property 'isExtensible' that we are not interested in.\n if (columnName === 'isExtensible') return;\n // TS doesn't allow `columnName` above to be a ReferencedItem even though the type says it is\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const columnId = columnName as ReferencedItem;\n const column = columns[columnId];\n // As of right now (and hopefully forever after), all remaining properties of the\n // ColumnsWithHeaders object are columns whose property names are the IDs of the columns.\n // This is an additional (redundant) sanity check. Specifically we're interested in\n // MenuColumnWithHeader objects, which TypeScript now \"knows\" we have, but at runtime all we\n // can check for is that it's an object with a valid numeric order field. That's likely good\n // enough.\n if (\n typeof column === 'object' &&\n typeof column.order === 'number' &&\n !Number.isNaN(column.order)\n )\n columnNumbers.set(column.order, { id: columnId, metadata: column });\n else\n console.warn(\n `Property ${columnName} (${typeof column}) on menu ${id} is not a valid column and is being ignored. This might indicate data corruption`,\n );\n });\n\n // Extract values and sort them based on the 'order' property\n return Array.from(columnNumbers.values()).sort((a, b) => {\n return (a.metadata.order || 0) - (b.metadata.order || 0);\n });\n }, [columns, id]);\n\n // We might need something like this if we need to be able to prevent empty columns\n // sortedColumns.filter((c) => multiColumnMenu.groups.some((g) => 'column' in g && (g as .column)...\n\n return (\n \n {sortedColumns.map((col, index) => (\n \n ))}\n \n );\n}\n","import { useEffect, useRef, useState } from 'react';\n\nexport type UsePromiseOptions = {\n /**\n * Whether to leave the value as the most recent resolved promise value or set it back to\n * defaultValue while running the promise again. Defaults to true\n */\n preserveValue?: boolean;\n};\n\n/** Set up defaults for options for usePromise hook */\nfunction getUsePromiseOptionsDefaults(options: UsePromiseOptions): UsePromiseOptions {\n return {\n preserveValue: true,\n ...options,\n };\n}\n\n/**\n * Awaits a promise and returns a loading value while the promise is unresolved\n *\n * @param promiseFactoryCallback A function that returns the promise to await. If this callback is\n * undefined, the current value will be returned (defaultValue unless it was previously changed\n * and `options.preserveValue` is true), and there will be no loading.\n *\n * WARNING: MUST BE STABLE - const or wrapped in useCallback. The reference must not be updated\n * every render\n * @param defaultValue The initial value to return while first awaiting the promise. If\n * `options.preserveValue` is false, this value is also shown while awaiting the promise on\n * subsequent calls.\n *\n * Note: this parameter is internally assigned to a `ref`, so changing it will not cause any hooks\n * to re-run with its new value. This means that, if the `promiseFactoryCallback` changes and\n * `options.preserveValue` is `false`, the returned value will be set to the current\n * `defaultValue`. However, the returned value will not be updated if`defaultValue` changes.\n * @param options Various options for adjusting how this hook runs the `promiseFactoryCallback`\n *\n * Note: this parameter is internally assigned to a `ref`, so changing it will not cause any hooks\n * to re-run with its new value. However, the latest `options.preserveValue` will always be used\n * appropriately to determine whether to preserve the returned value when changing the\n * `promiseFactoryCallback`\n * @returns `[value, isLoading]`\n *\n * - `value`: the current value for the promise, either the defaultValue or the resolved promise value\n * - `isLoading`: whether the promise is waiting to be resolved\n */\nconst usePromise = (\n promiseFactoryCallback: (() => Promise) | undefined,\n defaultValue: T,\n options: UsePromiseOptions = {},\n): [value: T, isLoading: boolean] => {\n // Use defaultValue as a ref so it doesn't update dependency arrays\n const defaultValueRef = useRef(defaultValue);\n defaultValueRef.current = defaultValue;\n // Use options as a ref so it doesn't update dependency arrays\n const optionsDefaultedRef = useRef(options);\n optionsDefaultedRef.current = getUsePromiseOptionsDefaults(optionsDefaultedRef.current);\n\n const [value, setValue] = useState(() => defaultValueRef.current);\n const [isLoading, setIsLoading] = useState(true);\n useEffect(() => {\n let promiseIsCurrent = true;\n // If a promiseFactoryCallback was provided, we are loading. Otherwise, there is no loading to do\n setIsLoading(!!promiseFactoryCallback);\n (async () => {\n // If there is a callback to run, run it\n if (promiseFactoryCallback) {\n const result = await promiseFactoryCallback();\n // If the promise was not already replaced, update the value\n if (promiseIsCurrent) {\n setValue(() => result);\n setIsLoading(false);\n }\n }\n })();\n\n return () => {\n // Mark this promise as old and not to be used\n promiseIsCurrent = false;\n if (!optionsDefaultedRef.current.preserveValue) setValue(() => defaultValueRef.current);\n };\n }, [promiseFactoryCallback]);\n\n return [value, isLoading];\n};\nexport default usePromise;\n","\"use client\";\n\nimport createSvgIcon from './utils/createSvgIcon';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nexport default createSvgIcon( /*#__PURE__*/_jsx(\"path\", {\n d: \"M3 18h18v-2H3zm0-5h18v-2H3zm0-7v2h18V6z\"\n}), 'Menu');","import GridMenu from '@/components/mui/grid-menu.component';\nimport { Command, CommandHandler } from '@/components/mui/menu-item.component';\nimport usePromise from '@/hooks/use-promise.hook';\nimport { Menu as MenuIcon } from '@mui/icons-material';\nimport { Drawer, IconButton } from '@mui/material';\nimport { Localized, MultiColumnMenu } from 'platform-bible-utils';\nimport {\n MouseEvent,\n MutableRefObject,\n PropsWithChildren,\n useCallback,\n useEffect,\n useState,\n} from 'react';\n\nexport interface MultiColumnMenuProvider {\n (isSupportAndDevelopment: boolean): Promise>;\n}\n\nexport type HamburgerMenuButtonProps = PropsWithChildren & {\n /** The handler to use for menu commands (and eventually toolbar commands). */\n commandHandler: CommandHandler;\n\n /**\n * Optional reference to the \"div\" container that determines the where the menu should appear. If\n * not defined, then (1,1) used.\n */\n containerRef?: MutableRefObject;\n\n /**\n * The delegate to use to get the menu data. If not specified or if it returns undefined, the data\n * in normalMenu or fullMenu property will be used.\n */\n menuProvider?: MultiColumnMenuProvider;\n\n /**\n * The menu data to show when the menu is opened if the menuProvider property is not defined.\n * (This allows for a default or test-only static menu to be used.)\n */\n normalMenu?: Localized;\n\n /**\n * The menu data to show for \"full\" menu (when opened with the SHIFT key pressed) if the\n * menuProvider property is not defined. (This allows for a default or test-only static menu to be\n * used.)\n */\n fullMenu?: Localized;\n\n /** Additional css class(es) to help with unique styling of the sub-components */\n className?: string;\n\n /** Value to use as prefix for ARIA labels on interactive sub-components */\n ariaLabelPrefix?: string;\n};\n\nexport default function HamburgerMenuButton({\n menuProvider,\n normalMenu,\n fullMenu,\n commandHandler,\n containerRef,\n className,\n ariaLabelPrefix,\n children,\n}: HamburgerMenuButtonProps) {\n const [isMenuOpen, setMenuOpen] = useState(false);\n const [showFullMenu, setShowFullMenu] = useState(false);\n\n const handleMenuItemClick = useCallback(() => {\n if (isMenuOpen) setMenuOpen(false);\n setShowFullMenu(false);\n }, [isMenuOpen]);\n\n const handleMenuButtonClick = useCallback((e: MouseEvent) => {\n e.stopPropagation();\n setMenuOpen((prevIsOpen) => {\n const isOpening = !prevIsOpen;\n if (isOpening && e.shiftKey) setShowFullMenu(true);\n else if (!isOpening) setShowFullMenu(false);\n return isOpening;\n });\n }, []);\n\n const menuCommandHandler = useCallback(\n (command: Command) => {\n handleMenuItemClick();\n return commandHandler(command);\n },\n [commandHandler, handleMenuItemClick],\n );\n\n const [offset, setOffset] = useState({ top: 1, left: 1 });\n\n useEffect(() => {\n if (isMenuOpen) {\n const node = containerRef?.current;\n if (node) {\n const rect = node.getBoundingClientRect();\n const scrollTop = window.scrollY;\n const scrollLeft = window.scrollX;\n const top = rect.top + scrollTop + node.clientHeight;\n const left = rect.left + scrollLeft;\n setOffset({ top, left });\n }\n }\n }, [isMenuOpen, containerRef]);\n\n const [normalMenuData] = usePromise(\n useCallback(async () => {\n return menuProvider?.(false) ?? normalMenu;\n // isMenuOpen needs to be included for the menu contents to reevaluate when reopened\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [menuProvider, normalMenu, isMenuOpen]),\n normalMenu,\n );\n\n const [fullMenuData] = usePromise(\n useCallback(async () => {\n return menuProvider?.(true) ?? fullMenu ?? normalMenuData;\n // isMenuOpen needs to be included for the menu contents to reevaluate when reopened\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [menuProvider, fullMenu, normalMenuData, isMenuOpen]),\n fullMenu ?? normalMenuData,\n );\n\n const menu = showFullMenu && fullMenuData ? fullMenuData : normalMenuData;\n\n return (\n <>\n \n {children ?? }\n \n \n {menu ? (\n \n ) : undefined}\n \n \n );\n}\n","import '@/components/mui/icon-button.component.css';\nimport { IconButton as MuiIconButton } from '@mui/material';\nimport { MouseEventHandler, PropsWithChildren } from 'react';\n\nexport type IconButtonProps = PropsWithChildren<{\n /** Optional unique identifier */\n id?: string;\n /**\n * Required. Used as both the tooltip (aka, title) and the aria-label (used for accessibility,\n * testing, etc.), unless a distinct tooltip is supplied.\n */\n label: string;\n /**\n * Enabled status of button\n *\n * @default false\n */\n isDisabled?: boolean;\n /** Optional tooltip to display if different from the aria-label. */\n tooltip?: string;\n /** If true, no tooltip will be displayed. */\n isTooltipSuppressed?: boolean;\n /**\n * If given, uses a negative margin to counteract the padding on one side (this is often helpful\n * for aligning the left or right side of the icon with content above or below, without ruining\n * the border size and shape).\n *\n * @default false\n */\n adjustMarginToAlignToEdge?: 'end' | 'start' | false;\n /**\n * The size of the component. small is equivalent to the dense button styling.\n *\n * @default false\n */\n size: 'small' | 'medium' | 'large';\n /** Additional css classes to help with unique styling of the button */\n className?: string;\n /** Optional click handler */\n onClick?: MouseEventHandler;\n}>;\n\n/**\n * Iconic button a user can click to do something\n *\n * Thanks to MUI for heavy inspiration and documentation\n * https://mui.com/material-ui/getting-started/overview/\n */\nfunction IconButton({\n id,\n label,\n isDisabled = false,\n tooltip,\n isTooltipSuppressed = false,\n adjustMarginToAlignToEdge = false,\n size = 'medium',\n className,\n onClick,\n children,\n}: IconButtonProps) {\n return (\n \n {children /* the icon to display */}\n \n );\n}\n\nexport default IconButton;\n","import { cn } from '@/utils/shadcn-ui.util';\nimport { LoaderCircle, LucideProps } from 'lucide-react';\nimport { forwardRef } from 'react';\n\nexport type SpinnerProps = LucideProps;\n\nconst Spinner = forwardRef(({ className, ...props }, ref) => {\n return (\n \n );\n});\n\nSpinner.displayName = 'Spinner';\n\nexport default Spinner;\n","import { Input as ShadInput } from '@/components/shadcn-ui/input';\nimport { Label as ShadLabel } from '@/components/shadcn-ui/label';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { ChangeEventHandler, FocusEventHandler } from 'react';\n\nexport type TextFieldProps = {\n /** Optional unique identifier */\n id?: string;\n /**\n * If `true`, the component is disabled.\n *\n * @default false\n */\n isDisabled?: boolean;\n /**\n * If `true`, the label is displayed in an error state.\n *\n * @default false\n */\n hasError?: boolean;\n /**\n * If `true`, the input will take up the full width of its container.\n *\n * @default false\n */\n isFullWidth?: boolean;\n /** Text that gives the user instructions on what contents the TextField expects */\n helperText?: string;\n /** The title of the TextField */\n label?: string;\n /** The short hint displayed in the `input` before the user enters a value. */\n placeholder?: string;\n /**\n * If `true`, the label is displayed as required and the `input` element is required.\n *\n * @default false\n */\n isRequired?: boolean;\n /** Additional css classes to help with unique styling of the text field */\n className?: string;\n /** Starting value for the text field if it is not controlled */\n defaultValue?: string | number;\n /** Value of the text field if controlled */\n value?: string | number;\n /** Triggers when content of textfield is changed */\n onChange?: ChangeEventHandler;\n /** Triggers when textfield gets focus */\n onFocus?: FocusEventHandler;\n /** Triggers when textfield loses focus */\n onBlur?: FocusEventHandler;\n};\n\n/**\n * Text input field\n *\n * Thanks to Shadcn for heavy inspiration and documentation\n * https://ui.shadcn.com/docs/components/input#with-label\n */\nfunction TextField({\n id,\n isDisabled = false,\n hasError = false,\n isFullWidth = false,\n helperText,\n label,\n placeholder,\n isRequired = false,\n className,\n defaultValue,\n value,\n onChange,\n onFocus,\n onBlur,\n}: TextFieldProps) {\n return (\n
    \n {`${label}${isRequired ? '*' : ''}`}\n \n

    {helperText}

    \n
    \n );\n}\n\nexport default TextField;\n","import HamburgerMenuButton, {\n MultiColumnMenuProvider,\n} from '@/components/mui/hamburger-menu-button.component';\nimport { CommandHandler } from '@/components/mui/menu-item.component';\nimport '@/components/mui/toolbar.component.css';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { AppBar, Toolbar as MuiToolbar } from '@mui/material';\nimport { PropsWithChildren, useRef } from 'react';\n\nexport type ToolbarProps = PropsWithChildren<{\n /** The handler to use for menu commands (and eventually toolbar commands). */\n commandHandler: CommandHandler;\n\n /**\n * The optional delegate to use to get the menu data. If not specified, the \"hamburger\" menu will\n * not display.\n */\n menuProvider?: MultiColumnMenuProvider;\n\n /** Optional unique identifier */\n id?: string;\n\n /** Additional css classes to help with unique styling of the toolbar */\n className?: string;\n}>;\n\nexport default function Toolbar({\n menuProvider,\n commandHandler,\n className,\n id,\n children,\n}: ToolbarProps) {\n // This ref will always be defined\n // eslint-disable-next-line no-type-assertion/no-type-assertion\n const containerRef = useRef(undefined!);\n\n return (\n
    \n \n \n {menuProvider ? (\n \n ) : undefined}\n {children ?
    {children}
    : undefined}\n \n
    \n
    \n );\n}\n","import React from 'react';\nimport { cva, type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst alertVariants = cva(\n 'tw-relative tw-w-full tw-rounded-lg tw-border tw-p-4 [&>svg~*]:tw-pl-7 [&>svg+div]:tw-translate-y-[-3px] [&>svg]:tw-absolute [&>svg]:tw-left-4 [&>svg]:tw-top-4 [&>svg]:tw-text-foreground',\n {\n variants: {\n variant: {\n default: 'tw-bg-background tw-text-foreground',\n destructive:\n 'tw-border-destructive/50 tw-text-destructive dark:tw-border-destructive [&>svg]:tw-text-destructive',\n },\n },\n defaultVariants: {\n variant: 'default',\n },\n },\n);\n\nconst Alert = React.forwardRef<\n HTMLDivElement,\n React.HTMLAttributes & VariantProps\n>(({ className, variant, ...props }, ref) => (\n
    \n));\nAlert.displayName = 'Alert';\n\nconst AlertTitle = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n {/* added because of https://github.com/jsx-eslint/eslint-plugin-jsx-a11y/blob/main/docs/rules/heading-has-content.md */}\n {props.children}{' '}\n \n ),\n);\nAlertTitle.displayName = 'AlertTitle';\n\nconst AlertDescription = React.forwardRef<\n HTMLParagraphElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n
    \n));\nAlertDescription.displayName = 'AlertDescription';\n\nexport { Alert, AlertTitle, AlertDescription };\n","import React from 'react';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Card = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nCard.displayName = 'Card';\n\nconst CardHeader = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nCardHeader.displayName = 'CardHeader';\n\nconst CardTitle = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n {/* added because of https://github.com/jsx-eslint/eslint-plugin-jsx-a11y/blob/main/docs/rules/heading-has-content.md */}\n {props.children}\n \n ),\n);\nCardTitle.displayName = 'CardTitle';\n\nconst CardDescription = React.forwardRef<\n HTMLParagraphElement,\n React.HTMLAttributes\n>(({ className, ...props }, ref) => (\n

    \n));\nCardDescription.displayName = 'CardDescription';\n\nconst CardContent = React.forwardRef>(\n ({ className, ...props }, ref) => (\n

    \n ),\n);\nCardContent.displayName = 'CardContent';\n\nconst CardFooter = React.forwardRef>(\n ({ className, ...props }, ref) => (\n \n ),\n);\nCardFooter.displayName = 'CardFooter';\n\nexport { Card, CardHeader, CardFooter, CardTitle, CardDescription, CardContent };\n","import { ComponentProps } from 'react';\nimport { toast as sonner, Toaster } from 'sonner';\n\ntype SonnerProps = ComponentProps;\n\nfunction Sonner({ ...props }: SonnerProps) {\n return (\n \n );\n}\n\n// The re-export of the sonner function was added manually\nexport { Sonner, sonner };\n","import React from 'react';\nimport * as SliderPrimitive from '@radix-ui/react-slider';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Slider = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n \n \n \n));\nSlider.displayName = SliderPrimitive.Root.displayName;\n\nexport { Slider };\n","import React from 'react';\nimport * as SwitchPrimitives from '@radix-ui/react-switch';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nconst Switch = React.forwardRef<\n React.ElementRef,\n React.ComponentPropsWithoutRef\n>(({ className, ...props }, ref) => (\n \n \n \n));\nSwitch.displayName = SwitchPrimitives.Root.displayName;\n\nexport { Switch };\n","import React from 'react';\nimport * as TabsPrimitive from '@radix-ui/react-tabs';\n\nimport { cn } from '@/utils/shadcn-ui.util';\n\nexport const Tabs = TabsPrimitive.Root;\n\nexport type TabsListProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport type TabsTriggerProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport type TabsContentProps = React.ComponentPropsWithoutRef & {\n className?: string;\n};\n\nexport const TabsList = React.forwardRef<\n React.ElementRef,\n TabsListProps\n>(({ className, ...props }, ref) => (\n \n));\nTabsList.displayName = TabsPrimitive.List.displayName;\n\nexport const TabsTrigger = React.forwardRef<\n React.ElementRef,\n TabsTriggerProps\n>(({ className, ...props }, ref) => (\n \n));\nTabsTrigger.displayName = TabsPrimitive.Trigger.displayName;\n\nexport const TabsContent = React.forwardRef<\n React.ElementRef,\n TabsContentProps\n>(({ className, ...props }, ref) => (\n \n));\nTabsContent.displayName = TabsPrimitive.Content.displayName;\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\nimport { Download } from 'lucide-react';\n\ntype InstallButtonProps = {\n /** The installing boolean value determines the state of the button. */\n isInstalling: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n /** Optional text for the button. */\n buttonText?: string;\n} & ButtonProps;\n\n/**\n * The InstallButton component is a button designed for initiating installs. It includes visuals for\n * active installing and idle states.\n *\n * @param isInstalling The installing boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @param buttonText Optional text for the button.\n * @returns A install button.\n */\nexport default function InstallButton({\n isInstalling,\n handleClick,\n buttonText,\n className,\n ...props\n}: InstallButtonProps) {\n return (\n \n {isInstalling ? (\n \n ) : (\n <>\n \n {buttonText}\n \n )}\n \n );\n}\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\n\ntype EnableButtonProps = {\n /** The enabling boolean value determines the state of the button. */\n isEnabling: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n} & ButtonProps;\n\n/**\n * The EnableButton component is a button designed for initiating enabling of downloads. It includes\n * visuals for active enabling and idle states.\n *\n * @param isEnabling The enabling boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @returns A button that can be used to enable.\n */\nexport default function EnableButton({\n isEnabling,\n handleClick,\n className,\n ...props\n}: EnableButtonProps) {\n return (\n \n {isEnabling ? (\n <>\n \n Enabling...\n \n ) : (\n 'Enable'\n )}\n \n );\n}\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\n\ntype DisableButtonProps = {\n /** The disabling boolean value determines the state of the button. */\n isDisabling: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n} & ButtonProps;\n\n/**\n * The DisableButton component is a button designed for initiating disabling of downloads. It\n * includes visuals for active disabling and idle states.\n *\n * @param isDisabling The disabling boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @returns A button that can be used to disable.\n */\nexport default function DisableButton({\n isDisabling,\n handleClick,\n className,\n ...props\n}: DisableButtonProps) {\n return (\n \n {isDisabling ? (\n <>\n \n Disabling...\n \n ) : (\n 'Disable'\n )}\n \n );\n}\n","import { Button, ButtonProps } from '@/components/shadcn-ui/button';\nimport Spinner from '@/components/basics/spinner.component';\nimport { cn } from '@/utils/shadcn-ui.util';\n\ntype UpdateButtonProps = {\n /** The updating boolean value determines the state of the button. */\n isUpdating: boolean;\n /** The handleClick function is called when the button is clicked. */\n handleClick: () => void;\n} & ButtonProps;\n\n/**\n * The UpdateButton component is a button designed for initiating updates for downloaded extensions.\n * It includes visuals for active updating and idle states.\n *\n * @param isUpdating The updating boolean value determines the state of the button.\n * @param handleClick The handleClick function is called when the button is clicked.\n * @returns A button that can be used to update.\n */\nexport default function UpdateButton({\n isUpdating,\n handleClick,\n className,\n ...props\n}: UpdateButtonProps) {\n return (\n \n {isUpdating ? (\n <>\n \n Updating...\n \n ) : (\n 'Update'\n )}\n \n );\n}\n","import { cn } from '@/utils/shadcn-ui.util';\nimport Markdown, { MarkdownToJSX } from 'markdown-to-jsx';\nimport { useMemo } from 'react';\n\ninterface MarkdownRendererProps {\n /** Optional unique identifier */\n id?: string;\n /** The markdown string to render */\n markdown: string;\n className?: string;\n /**\n * The [`target` attribute for `a` html\n * tags](https://developer.mozilla.org/en-US/docs/Web/HTML/Element/a#target). Defaults to not\n * adding a `target` to `a` tags\n */\n anchorTarget?: string;\n}\n\n/**\n * This component renders markdown content given a markdown string. It uses typography styles from\n * the platform.\n *\n * @param markdown The markdown string to render.\n * @param id Optional unique identifier\n * @returns A div containing the rendered markdown content.\n */\nexport default function MarkdownRenderer({\n id,\n markdown,\n className,\n anchorTarget,\n}: MarkdownRendererProps) {\n const options: MarkdownToJSX.Options = useMemo(\n () => ({\n overrides: {\n a: {\n props: {\n target: anchorTarget,\n },\n },\n },\n }),\n [anchorTarget],\n );\n return (\n
    \n {markdown}\n
    \n );\n}\n","import { Filter, ChevronDown } from 'lucide-react';\nimport { forwardRef } from 'react';\nimport { Button } from '@/components/shadcn-ui/button';\n\n/**\n * The FilterButton component is a button designed for initiating filtering of data. It is designed\n * to be used with the dropdown menu. It uses forwardRef to pass the button to the dropdown trigger\n * asChild.\n *\n * @returns A button that can be used to filter.\n */\nconst FilterButton = forwardRef((props, ref) => {\n return (\n \n \n Filter\n \n \n );\n});\n\nexport default FilterButton;\n","import {\n DropdownMenu,\n DropdownMenuTrigger,\n DropdownMenuContent,\n DropdownMenuLabel,\n DropdownMenuGroup,\n DropdownMenuCheckboxItem,\n DropdownMenuRadioItem,\n DropdownMenuSeparator,\n} from '@/components/shadcn-ui/dropdown-menu';\nimport FilterButton from './buttons/filter-button.component';\n\nexport enum DropdownMenuItemType {\n Check,\n Radio,\n}\n\nexport type DropdownItem = {\n /** The label is the text that will be displayed on the dropdown item. */\n label: string;\n /** The itemType determines the DropdownMenuItemType type as either Check or Radio. */\n itemType: DropdownMenuItemType;\n /** The onClick function is called when the item is clicked. */\n onClick: () => void;\n};\n\nexport type DropdownGroup = {\n /**\n * The label is the text that will be displayed on the dropdown group. It is used to categorize\n * the items in the group.\n */\n label: string;\n /** The items array contains the items that will be displayed in the dropdown group */\n items: DropdownItem[];\n};\n\nexport type FilterDropdownProps = {\n /** Object unique identifier */\n id?: string;\n /** The groups array contains the groups that will be displayed in the dropdown */\n groups: DropdownGroup[];\n}; // TODO: extend the props later\n\n/**\n * The FilterDropdown component is a dropdown designed for filtering content. It includes groups of\n * items that can be checkboxes or radio items.\n *\n * @param id Optional unique identifier\n * @param groups The groups array contains the groups that will be displayed in the dropdown\n * @returns A filter dropdown.\n */\nexport default function FilterDropdown({ id, groups }: FilterDropdownProps) {\n return (\n
    \n {/* TODO: remove this once the DropDown Menu shadcn has an id prop */}\n \n \n \n \n \n {groups.map((group) => (\n
    \n {group.label}\n \n {group.items.map((item) => (\n
    \n {item.itemType === DropdownMenuItemType.Check ? (\n \n {item.label}\n \n ) : (\n \n {item.label}\n \n )}\n
    \n ))}\n
    \n \n
    \n ))}\n
    \n
    \n
    \n );\n}\n","interface NoExtensionsFoundProps {\n /** Optional unique identifier */\n id?: string;\n /** The message to display */\n message: string;\n}\n/**\n * This component displays a message to the user when no extensions are found in the marketplace.\n *\n * @param id Optional unique identifier\n * @param message The message to display.\n * @returns {JSX.Element} - Returns the message component that displays the message to the user.\n */\nexport default function NoExtensionsFound({ id, message }: NoExtensionsFoundProps) {\n return (\n
    \n
    \n

    {message}

    \n
    \n
    \n );\n}\n","import { CircleHelp, Link as LucideLink, User } from 'lucide-react';\nimport { NumberFormat } from 'platform-bible-utils';\n\n/** Interface that stores the parameters passed to the More Info component */\ninterface MoreInfoProps {\n /** Optional unique identifier */\n id?: string;\n /** The category of the extension */\n category: string;\n /** The number of downloads for the extension */\n downloads: Record;\n /** The languages supported by the extension */\n languages: string[];\n /** The URL to the more info page of the extension */\n moreInfoUrl: string;\n}\n/**\n * This component displays the more info section of the extension which includes the category,\n * number of downloads, languages, and links to the website and support\n *\n * @param id Optional unique identifier\n * @param category The category of the extension\n * @param downloads The number of downloads for the extension\n * @param languages The languages supported by the extension\n * @param moreInfoUrl The URL to the more info page of the extension\n * @returns {JSX.Element} - Returns the more info component that displays the category, number of\n * downloads, languages, and links to the website and support\n */\nexport default function MoreInfo({\n id,\n category,\n downloads,\n languages,\n moreInfoUrl,\n}: MoreInfoProps) {\n /**\n * This constant formats the number of downloads into a more readable format.\n *\n * @example 1000 -> 1K\n *\n * @example 1000000 -> 1M\n *\n * @returns The formatted number of downloads\n */\n const numberFormatted = new NumberFormat('en', {\n notation: 'compact',\n compactDisplay: 'short',\n }).format(Object.values(downloads).reduce((a: number, b: number) => a + b, 0));\n\n /** This function scrolls the window to the bottom of the page. */\n const handleScrollToBottom = () => {\n window.scrollTo(0, document.body.scrollHeight);\n };\n\n return (\n \n
    \n
    \n {category}\n
    \n CATEGORY\n
    \n
    \n
    \n
    \n \n {numberFormatted}\n
    \n USERS\n
    \n
    \n
    \n
    \n {languages.slice(0, 3).map((locale) => (\n \n {locale.toUpperCase()}\n \n ))}\n
    \n {languages.length > 3 && (\n handleScrollToBottom()}\n className=\"tw-text-xs tw-text-gray-500 tw-underline\"\n >\n +{languages.length - 3} more languages\n \n )}\n
    \n
    \n
    \n \n Website\n \n \n \n Support\n \n \n
    \n
    \n );\n}\n","import { useState } from 'react';\n\nexport type VersionInformation = {\n /** Date the version was published */\n date: string;\n /** Description of the changes in the version */\n description: string;\n};\n\n/** Type to store the version history information */\nexport type VersionHistoryType = Record;\n\n/** Interface that stores the parameters passed to the Version History component */\ninterface VersionHistoryProps {\n /** Optional unique identifier */\n id?: string;\n /** Object containing the versions mapped with their information */\n versionHistory: VersionHistoryType;\n}\n\n/**\n * Component to render the version history information shown in the footer component. Lists the 5\n * most recent versions, with the options to show all versions by pressing a button.\n *\n * @param versionHistory Object containing the versions mapped with their information\n * @param id Optional unique identifier\n * @returns Rendered version history for the Footer component\n */\nexport default function VersionHistory({ id, versionHistory }: VersionHistoryProps) {\n const [showAllVersions, setShowAllVersions] = useState(false);\n const currentDate = new Date();\n\n /**\n * Function to format the time string for the version history in the form of 'X year(s) ago'.\n *\n * @param dateString ISO Date string to determine the time string from\n * @returns Formatted time string\n */\n function formatTimeString(dateString: string) {\n const date = new Date(dateString);\n const dateDiff = new Date(currentDate.getTime() - date.getTime());\n const yearDiff = dateDiff.getUTCFullYear() - 1970;\n const monthDiff = dateDiff.getUTCMonth();\n const dayDiff = dateDiff.getUTCDate() - 1;\n\n // Determines how long ago the version was published\n let timeString = '';\n if (yearDiff > 0) {\n timeString = `${yearDiff.toString()} year${yearDiff === 1 ? '' : 's'} ago`;\n } else if (monthDiff > 0) {\n timeString = `${monthDiff.toString()} month${monthDiff === 1 ? '' : 's'} ago`;\n } else if (dayDiff === 0) {\n timeString = 'today';\n } else {\n timeString = `${dayDiff.toString()} day${dayDiff === 1 ? '' : 's'} ago`;\n }\n\n return timeString;\n }\n\n // Sorts the version history by version number\n const sortedEntries = Object.entries(versionHistory).sort((a, b) => b[0].localeCompare(a[0]));\n\n return (\n
    \n

    What`s New

    \n
      \n {(showAllVersions ? sortedEntries : sortedEntries.slice(0, 5)).map((entry) => (\n
      \n
      \n
    • \n {entry[1].description}\n
    • \n
      \n
      \n
      Version {entry[0]}
      \n
      {formatTimeString(entry[1].date)}
      \n
      \n
      \n ))}\n
    \n {sortedEntries.length > 5 && (\n setShowAllVersions(!showAllVersions)}\n className=\"tw-text-xs tw-text-gray-500 tw-underline\"\n >\n {showAllVersions ? 'Show Less Version History' : 'Show All Version History'}\n \n )}\n
    \n );\n}\n","import { useMemo } from 'react';\nimport { formatBytes } from 'platform-bible-utils';\nimport VersionHistory, { VersionHistoryType } from './version-history.component';\n\n/** Interface to store the parameters passed to the Footer component */\ninterface FooterProps {\n /** Optional unique identifier */\n id?: string;\n /** Name of the publisher */\n publisherDisplayName: string;\n /** Size of the extension file in bytes */\n fileSize: number;\n /** List of language codes supported by the extension */\n locales: string[];\n /** Object containing the version history mapped with their information */\n versionHistory: VersionHistoryType;\n}\n\n/**\n * Component to render the footer for the extension details which contains information on the\n * publisher, version history, languages, and file size.\n *\n * @param id Optional unique identifier\n * @param publisherDisplayName Name of the publisher\n * @param fileSize Size of the extension file in bytes\n * @param locales List of language codes supported by the extension\n * @param versionHistory Object containing the version history mapped with their information\n * @returns The rendered Footer component\n */\nexport default function Footer({\n id,\n publisherDisplayName,\n fileSize,\n locales,\n versionHistory,\n}: FooterProps) {\n /** Formats the file size into a human-readable format */\n const formattedFileSize = useMemo(() => formatBytes(fileSize), [fileSize]);\n\n /**\n * This function gets the display names of the languages based on the language codes.\n *\n * @param codes The list of language codes\n * @returns The list of language names\n */\n const getLanguageNames = (codes: string[]) => {\n const displayNames = new Intl.DisplayNames(navigator.language, { type: 'language' });\n return codes.map((code) => displayNames.of(code));\n };\n\n const languageNames = getLanguageNames(locales);\n\n return (\n
    \n
    \n \n
    \n
    \n

    Information

    \n
    \n

    \n Publisher\n {publisherDisplayName}\n Size\n {formattedFileSize}\n

    \n
    \n

    \n Languages\n {languageNames.join(', ')}\n

    \n
    \n
    \n
    \n
    \n
    \n );\n}\n","import { PlatformEvent, PlatformEventHandler } from 'platform-bible-utils';\nimport { useEffect } from 'react';\n\n/**\n * Adds an event handler to an event so the event handler runs when the event is emitted. Use\n * `papi.network.getNetworkEvent` to use a networked event with this hook.\n *\n * @param event The event to subscribe to.\n *\n * - If event is a `PlatformEvent`, that event will be used\n * - If event is undefined, the callback will not be subscribed. Useful if the event is not yet\n * available for example\n *\n * @param eventHandler The callback to run when the event is emitted\n *\n * WARNING: MUST BE STABLE - const or wrapped in useCallback. The reference must not be updated\n * every render\n */\nconst useEvent = (\n event: PlatformEvent | undefined,\n eventHandler: PlatformEventHandler,\n) => {\n useEffect(() => {\n // Do nothing if the event is not provided (in case the event is not yet available, for example)\n if (!event) return () => {};\n\n const unsubscriber = event(eventHandler);\n return () => {\n unsubscriber();\n };\n }, [event, eventHandler]);\n};\nexport default useEvent;\n","import { useCallback, useEffect } from 'react';\nimport { PlatformEvent, PlatformEventAsync, PlatformEventHandler } from 'platform-bible-utils';\nimport usePromise from './use-promise.hook';\n\nconst noopUnsubscriber = () => false;\n\n/**\n * Adds an event handler to an asynchronously subscribing/unsubscribing event so the event handler\n * runs when the event is emitted. Use `papi.network.getNetworkEvent` to use a networked event with\n * this hook.\n *\n * @param event The asynchronously (un)subscribing event to subscribe to.\n *\n * - If event is a `PlatformEvent` or `PlatformEventAsync`, that event will be used\n * - If event is undefined, the callback will not be subscribed. Useful if the event is not yet\n * available for example\n *\n * @param eventHandler The callback to run when the event is emitted\n *\n * WARNING: MUST BE STABLE - const or wrapped in useCallback. The reference must not be updated\n * every render\n */\nconst useEventAsync = (\n event: PlatformEvent | PlatformEventAsync | undefined,\n eventHandler: PlatformEventHandler,\n) => {\n // Subscribe to the event asynchronously\n const [unsubscribe] = usePromise(\n useCallback(async () => {\n // Do nothing if the event is not provided (in case the event is not yet available, for example)\n if (!event) return noopUnsubscriber;\n\n // Wrap subscribe and unsubscribe in promises to allow normal events to be used as well\n const unsub = await Promise.resolve(event(eventHandler));\n return async () => unsub();\n }, [eventHandler, event]),\n noopUnsubscriber,\n // We want the unsubscriber to return to default value immediately upon changing subscription\n // So the useEffect below will unsubscribe asap\n { preserveValue: false },\n );\n\n // Unsubscribe from the event asynchronously (but we aren't awaiting the unsub)\n useEffect(() => {\n return () => {\n if (unsubscribe !== noopUnsubscriber) {\n unsubscribe();\n }\n };\n }, [unsubscribe]);\n};\n\nexport default useEventAsync;\n"],"names":["twMergeCustom","extendTailwindMerge","cn","inputs","clsx","Input","React","className","type","props","ref","jsx","BookChapterInput","forwardRef","handleSearch","handleKeyDown","handleOnClick","handleSubmit","jsxs","ShadInput","event","e","History","P","R","s","n","N","B","O","S","K","g","k","x","T","X","V","w","L","G","A","H","C","I","y","q","U","m","l","h","c","E","D","i","a","o","u","v","f","d","b","J","DropdownMenu","DropdownMenuPrimitive","DropdownMenuTrigger","DropdownMenuGroup","DropdownMenuPortal","DropdownMenuSub","DropdownMenuRadioGroup","DropdownMenuSubTrigger","inset","children","ChevronRight","DropdownMenuSubContent","DropdownMenuContent","sideOffset","DropdownMenuItem","DropdownMenuCheckboxItem","checked","Check","DropdownMenuRadioItem","Circle","DropdownMenuLabel","DropdownMenuSeparator","DropdownMenuShortcut","BookMenuItem","bookId","handleSelectBook","isSelected","handleHighlightBook","bookType","ShadDropdownMenuItem","Canon","ChapterSelect","handleSelectChapter","endChapter","activeChapter","highlightedChapter","handleHighlightedChapter","chapters","_","handleMouse","useCallback","chapterNumber","chapter","GoToMenuItem","handleSort","handleLocationHistory","handleBookmarks","ShadDropdownMenuLabel","ArrowDownWideNarrow","Clock","Bookmark","ALL_BOOK_IDS","BOOK_TYPE_LABELS","BOOK_TYPE_ARRAY","SCROLL_OFFSET","SEARCH_QUERY_FORMATS","fetchGroupedBooks","fetchEndChapter","getChaptersForBook","getAllEnglishNames","isValidBookEnglishName","bookName","getBookIdFromEnglishName","formattedBookName","BookChapterControl","scrRef","searchQuery","setSearchQuery","useState","selectedBookId","setSelectedBookId","setHighlightedChapter","highlightedBookId","setHighlightedBookId","isContentOpen","setIsContentOpen","isContentOpenDelayed","setIsContentOpenDelayed","inputRef","useRef","contentRef","menuItemRef","fetchFilteredBooks","englishNameLowerCase","normalizedQuery","handleSearchInput","searchString","shouldPreventAutoClosing","controlMenuState","open","updateReference","shouldClose","verse","handleInputSubmit","format","matches","book","englishName","handleKeyDownInput","handleKeyDownContent","key","handleKeyDownMenuItem","chapterOffSet","useEffect","useLayoutEffect","scrollTimeout","scrollPosition","ShadDropdownMenu","ShadDropdownMenuTrigger","ShadDropdownMenuContent","bookTypeIndex","element","ShadDropdownMenuSeparator","buttonVariants","cva","Button","variant","size","asChild","Slot","labelVariants","Label","LabelPrimitive","RadioGroup","RadioGroupPrimitive","RadioGroupItem","Popover","PopoverPrimitive","PopoverTrigger","PopoverContent","align","DialogPortal","DialogPrimitive","DialogOverlay","DialogContent","DialogTitle","DialogDescription","Command","CommandPrimitive","CommandInput","Search","CommandList","CommandEmpty","CommandGroup","CommandSeparator","CommandItem","getOptionLabelDefault","option","ComboBox","id","options","buttonClassName","popoverContentClassName","value","onChange","getOptionLabel","buttonPlaceholder","textPlaceholder","commandEmptyMessage","buttonVariant","dir","isDisabled","setOpen","ChevronsUpDown","ChapterRangeSelector","startChapter","handleSelectStartChapter","handleSelectEndChapter","chapterCount","chapterOptions","useMemo","index","Fragment","BookSelectionMode","BOOK_SELECTOR_STRING_KEYS","localizeString","strings","BookSelector","handleBookSelectionModeChange","currentBookName","onSelectBooks","selectedBookIds","localizedStrings","currentBookText","chooseText","chooseBooksText","bookSelectionMode","setBookSelectionMode","onSelectionModeChange","newMode","DataTableViewOptions","table","FilterIcon","column","Select","SelectPrimitive","SelectGroup","SelectValue","SelectTrigger","ChevronDown","SelectScrollUpButton","ChevronUp","SelectScrollDownButton","SelectContent","position","SelectLabel","SelectItem","SelectSeparator","DataTablePagination","pageSize","ArrowLeftIcon","ChevronLeftIcon","ChevronRightIcon","ArrowRightIcon","Table","stickyHeader","TableHeader","TableBody","TableFooter","TableRow","TableHead","TableCell","TableCaption","DataTable","columns","data","enablePagination","showPaginationControls","showColumnVisibilityControls","onRowClickHandler","sorting","setSorting","columnFilters","setColumnFilters","columnVisibility","setColumnVisibility","rowSelection","setRowSelection","useReactTable","getCoreRowModel","getPaginationRowModel","getSortedRowModel","getFilteredRowModel","headerGroup","header","flexRender","_a","row","cell","OccurrencesTable","occurrenceData","setScriptureReference","referenceHeaderText","occurrenceHeaderText","occurrences","uniqueOccurrences","occurrence","uniqueOccurrence","deepEqual","Checkbox","CheckboxPrimitive","getLinesFromUSFM","text","getNumberFromUSFM","regex","match","getBookNumFromId","getStatusForItem","item","approvedItems","unapprovedItems","toggleVariants","Toggle","TogglePrimitive","ToggleGroupContext","ToggleGroup","ToggleGroupPrimitive","ToggleGroupItem","context","getSortingIcon","sortDirection","ArrowUpIcon","ArrowDownIcon","ArrowUpDownIcon","inventoryItemColumn","itemLabel","inventoryAdditionalItemColumn","additionalItemLabel","additionalItemIndex","inventoryCountColumn","countLabel","statusChangeHandler","changedItems","newStatus","onApprovedItemsChange","onUnapprovedItemsChange","newApprovedItems","validItem","newUnapprovedItems","unapprovedItem","inventoryStatusColumn","statusLabel","status","CircleCheckIcon","CircleXIcon","CircleHelpIcon","INVENTORY_STRING_KEYS","filterItemData","itemData","statusFilter","textFilter","filteredItemData","createTableData","scriptureRef","itemRegex","tableData","currentBook","currentChapter","currentVerse","line","items","itemIndex","existingItem","tableEntry","newReference","substring","newItem","Inventory","scriptureReference","extractItems","additionalItemsLabels","scope","onScopeChange","allItemsText","approvedItemsText","unapprovedItemsText","unknownItemsText","scopeBookText","scopeChapterText","scopeVerseText","filterText","showAdditionalItemsText","showAdditionalItems","setShowAdditionalItems","setStatusFilter","setTextFilter","selectedItem","setSelectedItem","reducedTableData","newTableData","firstItem","existingEntry","newTableEntry","filteredTableData","allColumns","numberOfAdditionalItems","additionalColumns","_b","rowClickHandler","newSelection","handleScopeChange","handleStatusFilterChange","SearchBar","onSearch","placeholder","isFullWidth","handleInputChange","VerticalTabs","TabsPrimitive","VerticalTabsList","VerticalTabsTrigger","VerticalTabsContent","TabNavigationContentSearch","tabList","searchPlaceholder","headerTitle","isSearchBarFullWidth","direction","tab","Separator","orientation","decorative","SeparatorPrimitive","Skeleton","TooltipProvider","TooltipPrimitive","Tooltip","TooltipTrigger","TooltipContent","SIDEBAR_WIDTH","SIDEBAR_WIDTH_ICON","SidebarContext","useSidebar","SidebarProvider","defaultOpen","openProp","setOpenProp","style","_open","_setOpen","isOpen","openState","toggleSidebar","state","contextValue","Sidebar","side","collapsible","SidebarTrigger","onClick","PanelLeft","SidebarRail","SidebarInset","SidebarInput","SidebarHeader","SidebarFooter","SidebarSeparator","SidebarContent","SidebarGroup","SidebarGroupLabel","SidebarGroupAction","SidebarGroupContent","SidebarMenu","SidebarMenuItem","sidebarMenuButtonVariants","SidebarMenuButton","isActive","tooltip","Comp","button","SidebarMenuAction","showOnHover","SidebarMenuBadge","SidebarMenuSkeleton","showIcon","width","SidebarMenuSub","SidebarMenuSubItem","SidebarMenuSubButton","SettingsSidebar","extensionLabels","projectInfo","handleSelectSidebarItem","selectedSidebarItem","extensionsSidebarGroupLabel","projectsSidebarGroupLabel","buttonPlaceholderText","handleSelectItem","projectId","getProjectNameFromProjectId","project","info","getIsActive","label","selectedProjectName","SettingsSidebarContentSearch","scrBookColId","scrRefColId","typeColId","detailsColId","defaultScrRefColumnName","defaultScrBookGroupName","defaultTypeColumnName","defaultDetailsColumnName","getColumns","colInfo","showSourceColumn","showSrcCol","formatScrRef","compareScrRefs","toRefOrRange","scriptureSelection","offsetStart","offsetEnd","scrRefToBBBCCCVVV","getRowKey","ScriptureResultsViewer","sources","showColumnHeaders","scriptureReferenceColumnName","scriptureBookGroupName","typeColumnName","detailsColumnName","onRowSelected","grouping","setGrouping","scriptureResults","source","getExpandedRowModel","getGroupedRowModel","selectedRows","keys","selectedRow","scrBookGroupName","typeGroupName","groupingOptions","handleSelectChange","selectedGrouping","handleRowClick","getEvenOrOddBandingStyle","getIndent","groupingState","rowIndex","ChevronLeft","DEFAULT_SCROLL_GROUP_LOCALIZED_STRINGS","getLocalizeKeyForScrollGroupId","ScrollGroupSelector","availableScrollGroupIds","scrollGroupId","onChangeScrollGroupId","localizedStringsDefaulted","localizedStringKey","localizedStringValue","newScrollGroupString","scrollGroupOptionId","SettingsList","SettingsListItem","primary","secondary","isLoading","loadingMessage","SettingsListHeader","includeSeparator","Checklist","listItems","selectedListItems","handleSelectListItem","createLabel","_interopRequireDefault","obj","module","chainPropTypes","propType1","propType2","args","_extends","target","isPlainObject","prototype","deepClone","output","deepmerge","p","r","t","z","reactIs_production_min","hasSymbol","REACT_ELEMENT_TYPE","REACT_PORTAL_TYPE","REACT_FRAGMENT_TYPE","REACT_STRICT_MODE_TYPE","REACT_PROFILER_TYPE","REACT_PROVIDER_TYPE","REACT_CONTEXT_TYPE","REACT_ASYNC_MODE_TYPE","REACT_CONCURRENT_MODE_TYPE","REACT_FORWARD_REF_TYPE","REACT_SUSPENSE_TYPE","REACT_SUSPENSE_LIST_TYPE","REACT_MEMO_TYPE","REACT_LAZY_TYPE","REACT_BLOCK_TYPE","REACT_FUNDAMENTAL_TYPE","REACT_RESPONDER_TYPE","REACT_SCOPE_TYPE","isValidElementType","typeOf","object","$$typeof","$$typeofType","AsyncMode","ConcurrentMode","ContextConsumer","ContextProvider","Element","ForwardRef","Lazy","Memo","Portal","Profiler","StrictMode","Suspense","hasWarnedAboutDeprecatedIsAsyncMode","isAsyncMode","isConcurrentMode","isContextConsumer","isContextProvider","isElement","isForwardRef","isFragment","isLazy","isMemo","isPortal","isProfiler","isStrictMode","isSuspense","reactIs_development","reactIsModule","require$$0","require$$1","getOwnPropertySymbols","hasOwnProperty","propIsEnumerable","toObject","val","shouldUseNative","test1","test2","order2","test3","letter","objectAssign","from","to","symbols","ReactPropTypesSecret","ReactPropTypesSecret_1","has","printWarning","loggedTypeFailures","message","checkPropTypes","typeSpecs","values","location","componentName","getStack","typeSpecName","error","err","ex","stack","checkPropTypes_1","ReactIs","assign","require$$2","require$$3","require$$4","emptyFunctionThatReturnsNull","factoryWithTypeCheckers","isValidElement","throwOnDirectAccess","ITERATOR_SYMBOL","FAUX_ITERATOR_SYMBOL","getIteratorFn","maybeIterable","iteratorFn","ANONYMOUS","ReactPropTypes","createPrimitiveTypeChecker","createAnyTypeChecker","createArrayOfTypeChecker","createElementTypeChecker","createElementTypeTypeChecker","createInstanceTypeChecker","createNodeChecker","createObjectOfTypeChecker","createEnumTypeChecker","createUnionTypeChecker","createShapeTypeChecker","createStrictShapeTypeChecker","is","PropTypeError","createChainableTypeChecker","validate","manualPropTypeCallCache","manualPropTypeWarningCount","checkType","isRequired","propName","propFullName","secret","cacheKey","chainedCheckType","expectedType","propValue","propType","getPropType","preciseType","getPreciseType","typeChecker","expectedClass","expectedClassName","actualClassName","getClassName","expectedValues","valuesString","arrayOfTypeCheckers","checker","getPostfixForTypeWarning","expectedTypes","checkerResult","expectedTypesMessage","isNode","invalidValidatorError","shapeTypes","allKeys","iterator","step","entry","isSymbol","emptyFunction","emptyFunctionWithReset","factoryWithThrowingShims","shim","getShim","propTypesModule","isClassComponent","elementType","acceptingRef","safePropName","warningHint","elementAcceptingRef","PropTypes","elementAcceptingRef$1","specialProperty","exactProp","propTypes","unsupportedProps","prop","formatMuiErrorMessage","code","url","REACT_SERVER_CONTEXT_TYPE","REACT_OFFSCREEN_TYPE","enableScopeAPI","enableCacheElement","enableTransitionTracing","enableLegacyHidden","enableDebugTracing","REACT_MODULE_REFERENCE","SuspenseList","hasWarnedAboutDeprecatedIsConcurrentMode","isSuspenseList","fnNameMatchRegex","getFunctionName","fn","getFunctionComponentName","Component","fallback","getWrappedName","outerType","innerType","wrapperName","functionName","getDisplayName","HTMLElementType","refType","refType$1","capitalize","string","_formatMuiErrorMessage","createChainedFunction","funcs","acc","func","debounce","wait","timeout","debounced","later","deprecatedPropType","validator","reason","componentNameSafe","propFullNameSafe","isMuiElement","muiNames","_muiName","_element$type","ownerDocument","node","ownerWindow","requirePropFactory","componentNameInError","prevPropTypes","requiredProp","defaultTypeChecker","typeCheckerResult","setRef","useEnhancedEffect","useEnhancedEffect$1","globalId","useGlobalId","idOverride","defaultId","setDefaultId","maybeReactUseId","useId","reactId","unsupportedProp","useControlled","controlled","defaultProp","name","isControlled","valueState","setValue","defaultValue","setValueIfUncontrolled","newValue","useEventCallback","useForkRef","refs","instance","UNINITIALIZED","useLazyRef","init","initArg","EMPTY","useOnMount","Timeout","delay","useTimeout","hadKeyboardEvent","hadFocusVisibleRecently","hadFocusVisibleRecentlyTimeout","inputTypesWhitelist","focusTriggersKeyboardModality","tagName","handlePointerDown","handleVisibilityChange","prepare","doc","isFocusVisible","useIsFocusVisible","isFocusVisibleRef","handleBlurVisible","handleFocusVisible","resolveProps","defaultProps","defaultSlotProps","slotProps","slotPropName","composeClasses","slots","getUtilityClass","classes","slot","utilityClass","defaultGenerator","createClassNameGenerator","generate","generator","ClassNameGenerator","ClassNameGenerator$1","globalStateClasses","generateUtilityClass","globalStatePrefix","globalStateClass","generateUtilityClasses","result","clamp","min","max","_objectWithoutPropertiesLoose","excluded","sourceKeys","_excluded","sortBreakpointsValues","breakpointsAsArray","breakpoint1","breakpoint2","createBreakpoints","breakpoints","unit","other","sortedValues","up","down","between","start","end","endIndex","only","not","keyIndex","shape","shape$1","responsivePropType","responsivePropType$1","merge","defaultBreakpoints","handleBreakpoints","styleFromPropValue","theme","themeBreakpoints","breakpoint","mediaKey","cssKey","createEmptyBreakpointObject","breakpointsInput","_breakpointsInput$key","breakpointStyleKey","removeUnusedBreakpoints","breakpointKeys","breakpointOutput","getPath","path","checkVars","getStyleValue","themeMapping","transform","propValueFinal","userValue","cssProperty","themeKey","memoize","cache","arg","properties","directions","aliases","getCssProperties","property","marginKeys","paddingKeys","spacingKeys","createUnaryUnit","_getPath","themeSpacing","abs","createUnarySpacing","getValue","transformer","transformed","getStyleFromPropValue","cssProperties","resolveCssProperty","margin","padding","createSpacing","spacingInput","spacing","argsInput","argument","compose","styles","handlers","borderTransform","createBorderStyle","border","borderTop","borderRight","borderBottom","borderLeft","borderColor","borderTopColor","borderRightColor","borderBottomColor","borderLeftColor","outline","outlineColor","borderRadius","gap","columnGap","rowGap","gridColumn","gridRow","gridAutoFlow","gridAutoColumns","gridAutoRows","gridTemplateColumns","gridTemplateRows","gridTemplateAreas","gridArea","paletteTransform","color","bgcolor","backgroundColor","sizingTransform","maxWidth","_props$theme","_props$theme2","breakpointsValues","minWidth","height","maxHeight","minHeight","boxSizing","defaultSxConfig","defaultSxConfig$1","objectsHaveSameKeys","objects","union","callIfFn","maybeFn","unstable_createStyleFunctionSx","getThemeValue","config","styleFunctionSx","_theme$unstable_sxCon","sx","traverse","sxInput","sxObject","emptyBreakpoints","breakpointsKeys","css","styleKey","styleFunctionSx$1","applyStyles","createTheme","paletteInput","shapeInput","muiTheme","isObjectEmpty","useTheme","defaultTheme","contextTheme","ThemeContext","systemDefaultTheme","useThemeWithoutDefault","_excluded2","_excluded3","isEmpty","isStringTag","tag","shouldForwardProp","lowercaseFirstLetter","resolveTheme","themeId","defaultOverridesResolver","processStyleArg","callableStyle","_ref","ownerState","resolvedStylesArg","resolvedStyle","variants","isMatch","createStyled","input","rootShouldForwardProp","slotShouldForwardProp","systemSx","inputOptions","processStyles","componentSlot","inputSkipVariantsResolver","inputSkipSx","overridesResolver","skipVariantsResolver","skipSx","shouldForwardPropOption","defaultStyledResolver","styledEngineStyled","transformStyleArg","stylesArg","muiStyledResolver","styleArg","expressions","transformedStyleArg","expressionsWithDefaultTheme","styleOverrides","resolvedStyleOverrides","slotKey","slotStyle","_theme$components","themeVariants","numOfCustomFnsApplied","placeholders","displayName","getThemeProps","params","useThemeProps","clampWrapper","hexToRgb","re","colors","decomposeColor","marker","colorSpace","recomposeColor","hslToRgb","rgb","getLuminance","getContrastRatio","foreground","background","lumA","lumB","alpha","darken","coefficient","lighten","createMixins","mixins","common","common$1","grey","grey$1","purple","purple$1","red","red$1","orange","orange$1","blue","blue$1","lightBlue","lightBlue$1","green","green$1","light","dark","addLightOrDark","intent","shade","tonalOffset","tonalOffsetLight","tonalOffsetDark","getDefaultPrimary","mode","getDefaultSecondary","getDefaultError","getDefaultInfo","getDefaultSuccess","getDefaultWarning","createPalette","palette","contrastThreshold","success","warning","getContrastText","contrastText","contrast","augmentColor","mainShade","lightShade","darkShade","modes","round","caseAllCaps","defaultFontFamily","createTypography","typography","fontFamily","fontSize","fontWeightLight","fontWeightRegular","fontWeightMedium","fontWeightBold","htmlFontSize","allVariants","pxToRem2","coef","pxToRem","buildVariant","fontWeight","lineHeight","letterSpacing","casing","shadowKeyUmbraOpacity","shadowKeyPenumbraOpacity","shadowAmbientShadowOpacity","createShadow","px","shadows","shadows$1","easing","duration","formatMs","milliseconds","getAutoHeightDuration","constant","createTransitions","inputTransitions","mergedEasing","mergedDuration","durationOption","easingOption","isString","isNumber","animatedProp","zIndex","zIndex$1","mixinsInput","transitionsInput","typographyInput","systemTheme","systemCreateTheme","stateClasses","component","child","stateClass","defaultTheme$1","THEME_ID","systemUseThemeProps","styled","styled$1","getSvgIconUtilityClass","useUtilityClasses","SvgIconRoot","_theme$transitions","_theme$transitions$cr","_theme$transitions2","_theme$typography","_theme$typography$pxT","_theme$typography2","_theme$typography2$px","_theme$typography3","_theme$typography3$px","_palette$ownerState$c","_palette","_palette2","_palette3","SvgIcon","inProps","htmlColor","inheritViewBox","titleAccess","viewBox","hasSvgAsChild","more","_jsxs","_jsx","SvgIcon$1","createSvgIcon","unstable_ClassNameGenerator","exports","_utils","ArrowRight","default_1","_createSvgIcon","_jsxRuntime","isHostComponent","appendOwnerState","otherProps","defaultContextValue","ClassNameConfiguratorContext","useClassNamesOverride","disableDefaultClasses","extractEventHandlers","excludeKeys","resolveComponentProps","componentProps","slotState","omitEventHandlers","mergeSlotProps","parameters","getSlotProps","additionalProps","externalSlotProps","externalForwardedProps","joinedClasses","mergedStyle","eventHandlers","componentsPropsWithoutEventHandlers","otherPropsWithoutEventHandlers","internalSlotProps","useSlotProps","_parameters$additiona","skipResolvingSlotProps","rest","resolvedComponentsProps","mergedProps","internalRef","GLOBAL_CLASS_PREFIX","buildStateClass","buildSlotClass","getContainer","container","forwardedRef","disablePortal","mountNode","setMountNode","handleRef","newProps","ReactDOM","top","bottom","right","left","auto","basePlacements","clippingParents","viewport","popper","reference","variationPlacements","placement","placements","beforeRead","read","afterRead","beforeMain","main","afterMain","beforeWrite","write","afterWrite","modifierPhases","getNodeName","getWindow","OwnElement","isHTMLElement","isShadowRoot","attributes","effect","_ref2","initialStyles","styleProperties","attribute","applyStyles$1","getBasePlacement","getUAString","uaData","isLayoutViewport","getBoundingClientRect","includeScale","isFixedStrategy","clientRect","scaleX","scaleY","visualViewport","addVisualOffsets","getLayoutRect","contains","parent","rootNode","next","getComputedStyle","isTableElement","getDocumentElement","getParentNode","getTrueOffsetParent","getContainingBlock","isFirefox","isIE","elementCss","currentNode","getOffsetParent","window","offsetParent","getMainAxisFromPlacement","within","mathMax","mathMin","withinMaxClamp","getFreshSideObject","mergePaddingObject","paddingObject","expandToHashMap","hashMap","toPaddingObject","arrow","_state$modifiersData$","arrowElement","popperOffsets","basePlacement","axis","isVertical","len","arrowRect","minProp","maxProp","endDiff","startDiff","arrowOffsetParent","clientSize","centerToReference","center","offset","axisProp","_options$element","arrow$1","getVariation","unsetSides","roundOffsetsByDPR","win","dpr","mapToStyles","_Object$assign2","popperRect","variation","offsets","gpuAcceleration","adaptive","roundOffsets","isFixed","_offsets$x","_offsets$y","_ref3","hasX","hasY","sideX","sideY","heightProp","widthProp","offsetY","offsetX","commonStyles","_ref4","_Object$assign","computeStyles","_ref5","_options$gpuAccelerat","_options$adaptive","_options$roundOffsets","computeStyles$1","passive","_options$scroll","scroll","_options$resize","resize","scrollParents","scrollParent","eventListeners","hash","getOppositePlacement","matched","getOppositeVariationPlacement","getWindowScroll","scrollLeft","scrollTop","getWindowScrollBarX","getViewportRect","strategy","html","layoutViewport","getDocumentRect","_element$ownerDocumen","winScroll","body","isScrollParent","_getComputedStyle","overflow","overflowX","overflowY","getScrollParent","listScrollParents","list","isBody","updatedList","rectToClientRect","rect","getInnerBoundingClientRect","getClientRectFromMixedType","clippingParent","getClippingParents","canEscapeClipping","clipperElement","getClippingRect","boundary","rootBoundary","mainClippingParents","firstClippingParent","clippingRect","accRect","computeOffsets","commonX","commonY","mainAxis","detectOverflow","_options","_options$placement","_options$strategy","_options$boundary","_options$rootBoundary","_options$elementConte","elementContext","_options$altBoundary","altBoundary","_options$padding","altContext","clippingClientRect","referenceClientRect","popperClientRect","elementClientRect","overflowOffsets","offsetData","multiply","computeAutoPlacement","flipVariations","_options$allowedAutoP","allowedAutoPlacements","allPlacements","allowedPlacements","overflows","getExpandedFallbackPlacements","oppositePlacement","flip","_options$mainAxis","checkMainAxis","_options$altAxis","checkAltAxis","specifiedFallbackPlacements","_options$flipVariatio","preferredPlacement","isBasePlacement","fallbackPlacements","referenceRect","checksMap","makeFallbackChecks","firstFittingPlacement","_basePlacement","isStartVariation","mainVariationSide","altVariationSide","checks","check","numberOfChecks","_loop","_i","fittingPlacement","_ret","flip$1","getSideOffsets","preventedOffsets","isAnySideFullyClipped","hide","referenceOverflow","popperAltOverflow","referenceClippingOffsets","popperEscapeOffsets","isReferenceHidden","hasPopperEscaped","hide$1","distanceAndSkiddingToXY","rects","invertDistance","skidding","distance","_options$offset","_data$state$placement","offset$1","popperOffsets$1","getAltAxis","preventOverflow","_options$tether","tether","_options$tetherOffset","tetherOffset","altAxis","tetherOffsetValue","normalizedTetherOffsetValue","offsetModifierState","_offsetModifierState$","mainSide","altSide","additive","minLen","maxLen","arrowPaddingObject","arrowPaddingMin","arrowPaddingMax","arrowLen","minOffset","maxOffset","clientOffset","offsetModifierValue","tetherMin","tetherMax","preventedOffset","_offsetModifierState$2","_mainSide","_altSide","_offset","_len","_min","_max","isOriginSide","_offsetModifierValue","_tetherMin","_tetherMax","_preventedOffset","preventOverflow$1","getHTMLElementScroll","getNodeScroll","isElementScaled","getCompositeRect","elementOrVirtualElement","isOffsetParentAnElement","offsetParentIsScaled","documentElement","order","modifiers","map","visited","modifier","sort","requires","dep","depModifier","orderModifiers","orderedModifiers","phase","pending","resolve","mergeByName","merged","current","existing","DEFAULT_OPTIONS","areValidElements","_key","popperGenerator","generatorOptions","_generatorOptions","_generatorOptions$def","defaultModifiers","_generatorOptions$def2","defaultOptions","effectCleanupFns","isDestroyed","setOptionsAction","cleanupModifierEffects","runModifierEffects","_state$elements","_state$orderedModifie","_state$orderedModifie2","_ref$options","cleanupFn","noopFn","createPopper","COMPONENT_NAME","getPopperUtilityClass","flipPlacement","resolveAnchorEl","anchorEl","isVirtualElement","defaultPopperOptions","PopperTooltip","_slots$root","initialPlacement","popperOptions","popperRefProp","TransitionProps","tooltipRef","ownRef","popperRef","handlePopperRef","handlePopperRefRef","rtlPlacement","setPlacement","resolvedAnchorElement","setResolvedAnchorElement","handlePopperUpdate","box","popperModifiers","childProps","Root","rootProps","Popper","containerProp","keepMounted","transition","exited","setExited","handleEnter","handleExited","resolvedAnchorEl","display","transitionProps","useThemeSystem","_setPrototypeOf","_inheritsLoose","subClass","superClass","setPrototypeOf","timeoutsShape","TransitionGroupContext","forceReflow","UNMOUNTED","EXITED","ENTERING","ENTERED","EXITING","Transition","_React$Component","_this","parentGroup","appear","initialStatus","prevState","nextIn","_proto","prevProps","nextStatus","exit","enter","mounting","_this2","appearing","maybeNode","maybeAppearing","timeouts","enterTimeout","_this3","nextState","callback","_this4","active","handler","doesNotHaveTimeoutOrListener","maybeNextCallback","_this$props","pt","noop","Transition$1","reflow","getTransitionProps","_style$transitionDura","_style$transitionTimi","getScale","isWebKit154","Grow","addEndListener","inProp","onEnter","onEntered","onEntering","onExit","onExited","onExiting","TransitionComponent","timer","autoTimeout","nodeRef","normalizedTransitionCallback","maybeIsAppearing","handleEntering","isAppearing","transitionDuration","transitionTimingFunction","handleEntered","handleExiting","handleExit","Grow$1","PopperRoot","BasePopper","components","componentsProps","RootComponent","Popper$1","getTooltipUtilityClass","tooltipClasses","tooltipClasses$1","disableInteractive","touch","TooltipPopper","TooltipTooltip","TooltipArrow","hystersisOpen","hystersisTimer","cursorPosition","composeEventHandler","eventHandler","_slots$popper","_slots$transition","_slots$tooltip","_slots$arrow","_slotProps$popper","_ref6","_slotProps$popper2","_slotProps$transition","_slotProps$tooltip","_ref7","_slotProps$tooltip2","_slotProps$arrow","_ref8","_slotProps$arrow2","childrenProp","describeChild","disableFocusListener","disableHoverListener","disableInteractiveProp","disableTouchListener","enterDelay","enterNextDelay","enterTouchDelay","followCursor","idProp","leaveDelay","leaveTouchDelay","onClose","onOpen","PopperComponentProp","PopperProps","title","TransitionComponentProp","isRtl","childNode","setChildNode","arrowRef","setArrowRef","ignoreNonTouchEvents","closeTimer","enterTimer","leaveTimer","touchTimer","setOpenState","prevUserSelect","stopTouchInteraction","handleOpen","handleClose","handleLeave","focusVisibleRef","setChildIsFocusVisible","handleBlur","handleFocus","detectTouchStart","childrenProps","handleMouseOver","handleMouseLeave","handleTouchStart","handleTouchEnd","nativeEvent","handleMouseMove","nameOrDescProps","titleIsString","interactiveWrapperListeners","_PopperProps$popperOp","tooltipModifiers","PopperComponent","TooltipComponent","ArrowComponent","popperProps","tooltipProps","tooltipArrowProps","TransitionPropsInner","Tooltip$1","getIcon","icon","menuLabel","leading","MuiListItemIcon","MenuItem","allowForLeadingIcons","iconPathBefore","iconPathAfter","hasAutoFocus","isDense","isSubMenuParent","hasDisabledGutters","hasDivider","focusVisibleClassName","menuItem","MuiMenuItem","MuiListItemText","getAllGroups","menuDefinition","SubMenu","setAnchorEl","parentMenuItem","parentItemProps","handleParentMenuItemClick","renderSubMenuItems","includedGroups","group","GroupedMenuItemList","Menu","getOrderedGroupItems","groupId","allItems","menuProps","commandHandler","groupsToInclude","sortedGroups","itemArray","allowSpaceForLeadingIcons","createMenuItemProps","isLastItemInGroup","divKey","itemInfo","menuItemProps","TopLevelMenu","columnId","MenuColumn","metadata","Grid","List","GridMenu","multiColumnMenu","sortedColumns","columnNumbers","columnName","col","getUsePromiseOptionsDefaults","usePromise","promiseFactoryCallback","defaultValueRef","optionsDefaultedRef","setIsLoading","promiseIsCurrent","MenuIcon","HamburgerMenuButton","menuProvider","normalMenu","fullMenu","containerRef","ariaLabelPrefix","isMenuOpen","setMenuOpen","showFullMenu","setShowFullMenu","handleMenuItemClick","handleMenuButtonClick","prevIsOpen","isOpening","menuCommandHandler","command","setOffset","normalMenuData","fullMenuData","menu","IconButton","Drawer","isTooltipSuppressed","adjustMarginToAlignToEdge","MuiIconButton","Spinner","LoaderCircle","TextField","hasError","helperText","onFocus","onBlur","ShadLabel","Toolbar","AppBar","MuiToolbar","alertVariants","Alert","AlertTitle","AlertDescription","Card","CardHeader","CardTitle","CardDescription","CardContent","CardFooter","Sonner","Toaster","Slider","SliderPrimitive","Switch","SwitchPrimitives","Tabs","TabsList","TabsTrigger","TabsContent","InstallButton","isInstalling","handleClick","buttonText","Download","EnableButton","isEnabling","DisableButton","isDisabling","UpdateButton","isUpdating","MarkdownRenderer","markdown","anchorTarget","Markdown","FilterButton","Filter","DropdownMenuItemType","DropdownMenuItemType2","FilterDropdown","groups","NoExtensionsFound","MoreInfo","category","downloads","languages","moreInfoUrl","numberFormatted","NumberFormat","handleScrollToBottom","User","locale","LucideLink","CircleHelp","VersionHistory","versionHistory","showAllVersions","setShowAllVersions","currentDate","formatTimeString","dateString","date","dateDiff","yearDiff","monthDiff","dayDiff","timeString","sortedEntries","Footer","publisherDisplayName","fileSize","locales","formattedFileSize","formatBytes","languageNames","codes","displayNames","useEvent","unsubscriber","noopUnsubscriber","useEventAsync","unsubscribe","unsub"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAGA,MAAMA,KAAgBC,GAAoB,EAAE,QAAQ,MAAO,CAAA;AAyDpD,SAASC,KAAMC,GAAsB;AACnC,SAAAH,GAAcI,GAAKD,CAAM,CAAC;AACnC;ACzDO,MAAME,KAAQC,EAAM;AAAA,EACzB,CAAC,EAAE,WAAAC,GAAW,MAAAC,GAAM,GAAGC,EAAA,GAASC,MAE5B,gBAAAC;AAAA,IAAC;AAAA,IAAA;AAAA,MACC,MAAAH;AAAA,MACA,WAAWN;AAAA,QACT;AAAA,QACAK;AAAA,MACF;AAAA,MACA,KAAAG;AAAA,MAEC,GAAGD;AAAA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A,EACA;AAAA,EACA;AACF,GAAGC,KAAI;AAAA,EACL;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AACF,GAAGC,KAAI;AAAA,EACL;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA;AAAA;AAAA,EAGA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,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;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","x_google_ignoreList":[3,43,44,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,83,84,85,86,87,88,89,90,91,92,93,94,95,96,97,98,99,100,101,102,103,104,105,106,107,108,109,110,111,112,113,114,115,116,117,118,119,120,121,122,123,124,125,126,127,128,129,130,131,132,133,134,135,136,137,138,139,140,141,142,143,144,145,146,147,148,149,150,151,152,153,154,155,156,157,158,159,160,161,162,163,164,165,166,167,168,169,170,171,172,173,174,175,176,177,178,179,180,181,182,183,184,185,186,187,188,189,190,191,192,193,194,195,196,197,198,199,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,226]} \ No newline at end of file diff --git a/lib/platform-bible-react/src/components/basics/combo-box.component.tsx b/lib/platform-bible-react/src/components/basics/combo-box.component.tsx index 75078a2096..51653a697d 100644 --- a/lib/platform-bible-react/src/components/basics/combo-box.component.tsx +++ b/lib/platform-bible-react/src/components/basics/combo-box.component.tsx @@ -71,6 +71,7 @@ function getOptionLabelDefault(option: ComboBoxOption): string { function ComboBox({ id, options = [], + className, buttonClassName, popoverContentClassName, value, @@ -94,7 +95,7 @@ function ComboBox({ role="combobox" aria-expanded={open} id={id} - className={cn('tw-w-[200px] tw-justify-between', buttonClassName)} + className={cn('tw-w-[200px] tw-justify-between', buttonClassName ?? className)} disabled={isDisabled} > diff --git a/src/declarations/papi-shared-types.ts b/src/declarations/papi-shared-types.ts index 60474d29ec..dff93ba0a4 100644 --- a/src/declarations/papi-shared-types.ts +++ b/src/declarations/papi-shared-types.ts @@ -60,6 +60,8 @@ declare module 'papi-shared-types' { 'platform.restart': () => Promise; /** @deprecated 3 December 2024. Renamed to `platform.openSettings` */ 'platform.openProjectSettings': (webViewId: string) => Promise; + /** @deprecated 3 December 2024. Renamed to `platform.openSettings` */ + 'platform.openUserSettings': () => Promise; 'platform.openSettings': (webViewId?: WebViewId) => Promise; // These commands are provided in `extension-host.ts`. They are only here because I needed them to // use in other places, but building `papi-dts` wasn't working because it didn't see diff --git a/src/renderer/services/web-view.service-host.ts b/src/renderer/services/web-view.service-host.ts index c77bd13968..46ee9e0d83 100644 --- a/src/renderer/services/web-view.service-host.ts +++ b/src/renderer/services/web-view.service-host.ts @@ -1454,6 +1454,8 @@ export async function startWebViewService(): Promise { // eslint-disable-next-line @typescript-eslint/no-explicit-any const commandHandlers: { [commandName: string]: (...args: any[]) => any } = { 'platform.openSettings': openSettingsTab, + 'platform.openProjectSettings': openSettingsTab, + 'platform.openUserSettings': openSettingsTab, }; Object.entries(commandHandlers).forEach(([commandName, handler]) => { From 2b5871a29c77ecd0834b5f7c0a4dbaabdebc5394 Mon Sep 17 00:00:00 2001 From: Jolie Rabideau Date: Thu, 5 Dec 2024 12:46:08 -0500 Subject: [PATCH 18/18] build types --- lib/papi-dts/papi.d.ts | 2 ++ 1 file changed, 2 insertions(+) diff --git a/lib/papi-dts/papi.d.ts b/lib/papi-dts/papi.d.ts index e4f9108618..417ed4c854 100644 --- a/lib/papi-dts/papi.d.ts +++ b/lib/papi-dts/papi.d.ts @@ -2901,6 +2901,8 @@ declare module 'papi-shared-types' { 'platform.restart': () => Promise; /** @deprecated 3 December 2024. Renamed to `platform.openSettings` */ 'platform.openProjectSettings': (webViewId: string) => Promise; + /** @deprecated 3 December 2024. Renamed to `platform.openSettings` */ + 'platform.openUserSettings': () => Promise; 'platform.openSettings': (webViewId?: WebViewId) => Promise; 'test.addMany': (...nums: number[]) => number; 'test.throwErrorExtensionHost': (message: string) => void;